diff --git a/dist/fixed-data-table-base.css b/dist/fixed-data-table-base.css index c623bffd..1d731db1 100644 --- a/dist/fixed-data-table-base.css +++ b/dist/fixed-data-table-base.css @@ -1,5 +1,5 @@ /** - * FixedDataTable v1.0.0-beta.16 + * FixedDataTable v1.0.0-beta.17 * * Copyright Schrodinger, LLC * All rights reserved. diff --git a/dist/fixed-data-table-base.min.css b/dist/fixed-data-table-base.min.css index c623bffd..1d731db1 100644 --- a/dist/fixed-data-table-base.min.css +++ b/dist/fixed-data-table-base.min.css @@ -1,5 +1,5 @@ /** - * FixedDataTable v1.0.0-beta.16 + * FixedDataTable v1.0.0-beta.17 * * Copyright Schrodinger, LLC * All rights reserved. diff --git a/dist/fixed-data-table-style.css b/dist/fixed-data-table-style.css index fa307d92..201d8ee5 100644 --- a/dist/fixed-data-table-style.css +++ b/dist/fixed-data-table-style.css @@ -1,5 +1,5 @@ /** - * FixedDataTable v1.0.0-beta.16 + * FixedDataTable v1.0.0-beta.17 * * Copyright Schrodinger, LLC * All rights reserved. diff --git a/dist/fixed-data-table-style.min.css b/dist/fixed-data-table-style.min.css index fa307d92..201d8ee5 100644 --- a/dist/fixed-data-table-style.min.css +++ b/dist/fixed-data-table-style.min.css @@ -1,5 +1,5 @@ /** - * FixedDataTable v1.0.0-beta.16 + * FixedDataTable v1.0.0-beta.17 * * Copyright Schrodinger, LLC * All rights reserved. diff --git a/dist/fixed-data-table.css b/dist/fixed-data-table.css index bcd4145f..c608aa87 100644 --- a/dist/fixed-data-table.css +++ b/dist/fixed-data-table.css @@ -1,5 +1,5 @@ /** - * FixedDataTable v1.0.0-beta.16 + * FixedDataTable v1.0.0-beta.17 * * Copyright Schrodinger, LLC * All rights reserved. diff --git a/dist/fixed-data-table.js b/dist/fixed-data-table.js index dd5eecc2..08c3ab8c 100644 --- a/dist/fixed-data-table.js +++ b/dist/fixed-data-table.js @@ -1,5 +1,5 @@ /** - * FixedDataTable v1.0.0-beta.16 + * FixedDataTable v1.0.0-beta.17 * * Copyright Schrodinger, LLC * All rights reserved. @@ -954,7 +954,6 @@ var Scrollbar = function (_React$PureComponent) { onTouchEnd: this._onTouchEnd, onTouchMove: this._onTouchMove, onTouchStart: this._onTouchStart, - onWheel: this._wheelHandler.onWheel, className: mainClassName, style: mainStyle, ref: this._onRefRoot }, @@ -979,6 +978,7 @@ var Scrollbar = function (_React$PureComponent) { }, { key: 'componentDidMount', value: function componentDidMount() { + this._rootRef && this._rootRef.addEventListener('wheel', this._wheelHandler.onWheel, { passive: false }); this._mouseMoveTracker = new _DOMMouseMoveTracker2.default(this._onMouseMove, this._onMouseMoveEnd, document.documentElement, this.props.touchEnabled); if (this.props.position !== undefined && this.state.position !== this.props.position) { @@ -989,6 +989,7 @@ var Scrollbar = function (_React$PureComponent) { }, { key: 'componentWillUnmount', value: function componentWillUnmount() { + this._rootRef && this._rootRef.removeEventListener('wheel', this._wheelHandler.onWheel, { passive: false }); this._nextState = null; this._mouseMoveTracker.releaseMouseMoves(); if (_lastScrolledScrollbar === this) { @@ -5609,7 +5610,7 @@ var FixedDataTableRoot = { Table: _FixedDataTableContainer2.default }; -FixedDataTableRoot.version = '1.0.0-beta.16'; +FixedDataTableRoot.version = '1.0.0-beta.17'; module.exports = FixedDataTableRoot; /***/ }), diff --git a/dist/fixed-data-table.min.css b/dist/fixed-data-table.min.css index bcd4145f..c608aa87 100644 --- a/dist/fixed-data-table.min.css +++ b/dist/fixed-data-table.min.css @@ -1,5 +1,5 @@ /** - * FixedDataTable v1.0.0-beta.16 + * FixedDataTable v1.0.0-beta.17 * * Copyright Schrodinger, LLC * All rights reserved. diff --git a/dist/fixed-data-table.min.js b/dist/fixed-data-table.min.js index cf5f4406..54323108 100644 --- a/dist/fixed-data-table.min.js +++ b/dist/fixed-data-table.min.js @@ -1,5 +1,5 @@ /** - * FixedDataTable v1.0.0-beta.16 + * FixedDataTable v1.0.0-beta.17 * * Copyright Schrodinger, LLC * All rights reserved. @@ -9,4 +9,4 @@ * of patent rights can be found in the PATENTS file in the same directory. */ -!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("react-dom")):"function"==typeof define&&define.amd?define(["react","react-dom"],t):"object"==typeof exports?exports.FixedDataTable=t(require("react"),require("react-dom")):e.FixedDataTable=t(e.React,e.ReactDOM)}("undefined"!=typeof self?self:this,function(e,t){return function(e){function t(o){if(n[o])return n[o].exports;var r=n[o]={i:o,l:!1,exports:{}};return e[o].call(r.exports,r,r.exports,t),r.l=!0,r.exports}var n={};return t.m=e,t.c=n,t.d=function(e,n,o){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:o})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=99)}([function(e,t,n){"use strict";e.exports=n(106)},function(e,t){var n=Array.isArray;e.exports=n},function(e,t,n){(function(t){if("production"!==t.env.NODE_ENV){var o="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,r=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===o};e.exports=n(107)(r,!0)}else e.exports=n(110)()}).call(t,n(10))},function(e,t,n){"use strict";function o(e){return a[e]?a[e]:(a[e]=e.replace(u,"_"),a[e])}function r(e){var t;return t="object"==(void 0===e?"undefined":i(e))?Object.keys(e).filter(function(t){return e[t]}):Array.prototype.slice.call(arguments),t.map(o).join(" ")}var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},u=/\//g,a={};e.exports=r},function(e,t,n){var o=n(68),r="object"==typeof self&&self&&self.Object===Object&&self,i=o||r||Function("return this")();e.exports=i},function(e,t){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";function o(e){return function(){return e}}function r(){}r.thatReturns=o,r.thatReturnsFalse=o(!1),r.thatReturnsTrue=o(!0),r.thatReturnsNull=o(null),r.thatReturnsThis=function(){return this},r.thatReturnsArgument=function(e){return e},e.exports=r},function(e,t,n){function o(e,t){var n=i(e,t);return r(n)?n:void 0}var r=n(149),i=n(152);e.exports=o},function(e,t,n){function o(e){return null==e?void 0===e?l:a:s&&s in Object(e)?i(e):u(e)}var r=n(13),i=n(126),u=n(127),a="[object Null]",l="[object Undefined]",s=r?r.toStringTag:void 0;e.exports=o},function(e,t){function n(e){return null!=e&&"object"==typeof e}e.exports=n},function(e,t){function n(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function r(e){if(c===setTimeout)return setTimeout(e,0);if((c===n||!c)&&setTimeout)return c=setTimeout,setTimeout(e,0);try{return c(e,0)}catch(t){try{return c.call(null,e,0)}catch(t){return c.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===o||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function u(){v&&p&&(v=!1,p.length?h=p.concat(h):m=-1,h.length&&a())}function a(){if(!v){var e=r(u);v=!0;for(var t=h.length;t;){for(p=h,h=[];++m1)for(var n=1;n1)for(var o=1;oc&&(t=c);var f=!!e._mouseMoveTracker&&e._mouseMoveTracker.isDragging(),d={faceSize:s,isDragging:f,isHorizontal:a,position:t,scale:l,scrollable:!0};return e._stateKey=u,e._stateForKey=d,d},this._onWheelY=function(t,n){e._onWheel(n)},this._onWheelX=function(t,n){e._onWheel(t)},this._onWheel=function(t){var n=e.props;e._setNextState(e._calculateState(e.state.position+t,n.size,n.contentSize,n.orientation))},this._onMouseDown=function(t){var n;if(t.target!==e._faceRef){var o=t.nativeEvent,r=e.state.isHorizontal?o.offsetX||o.layerX||e.getTouchX(o):o.offsetY||o.layerY||e.getTouchY(o),i=e.props;r/=e.state.scale,n=e._calculateState(r-.5*e.state.faceSize/e.state.scale,i.size,i.contentSize,i.orientation)}else n={};n.focused=!0,e._setNextState(n),e._mouseMoveTracker.captureMouseMoves(t),e._rootRef.focus()},this._onTouchCancel=function(e){e.stopPropagation()},this._onTouchEnd=function(e){e.stopPropagation()},this._onTouchMove=function(e){e.stopPropagation()},this._onTouchStart=function(t){t.stopPropagation(),e._onMouseDown(t)},this._onMouseMove=function(t,n){var o=e.props,r=e.state.isHorizontal?t:n;r/=e.state.scale,e._setNextState(e._calculateState(e.state.position+r,o.size,o.contentSize,o.orientation))},this._onMouseMoveEnd=function(){e._nextState=null,e._mouseMoveTracker.releaseMouseMoves(),e.setState({isDragging:!1})},this._onKeyDown=function(t){var n=t.keyCode;if(n!==f.default.TAB){var o=40,r=0;if(e.state.isHorizontal)switch(n){case f.default.HOME:r=-1,o=e.props.contentSize;break;case f.default.LEFT:r=-1;break;case f.default.RIGHT:r=1;break;default:return}if(!e.state.isHorizontal)switch(n){case f.default.SPACE:r=t.shiftKey?-1:1;break;case f.default.HOME:r=-1,o=e.props.contentSize;break;case f.default.UP:r=-1;break;case f.default.DOWN:r=1;break;case f.default.PAGE_UP:r=-1,o=e.props.size;break;case f.default.PAGE_DOWN:r=1,o=e.props.size;break;default:return}t.preventDefault();var i=e.props;e._setNextState(e._calculateState(e.state.position+o*r,i.size,i.contentSize,i.orientation))}},this._onFocus=function(){e.setState({focused:!0})},this._onBlur=function(){e.setState({focused:!1})},this._blur=function(){var t=b.default.findDOMNode(e);if(t)try{e._onBlur(),t.blur()}catch(e){}},this.getTouchX=function(e){return Math.round(e.targetTouches[0].pageX-e.target.getBoundingClientRect().x)},this.getTouchY=function(e){return Math.round(e.targetTouches[0].pageY-e.target.getBoundingClientRect().y)},this._setNextState=function(t,n){n=n||e.props;var o=n.position,r=e.state.position!==t.position;if(void 0===o){var i=r?e._didScroll:void 0;e.setState(t,i)}else{if(o!==t.position)return void(void 0!==t.position&&t.position!==e.state.position&&e.props.onScroll(t.position));e.setState(t)}r&&k!==e&&(k&&k._blur(),k=e)},this._didScroll=function(){e.props.onScroll(e.state.position)}};j.KEYBOARD_SCROLL_AMOUNT=40,j.SIZE=parseInt((0,w.default)("scrollbar-size"),10),j.OFFSET=1,e.exports=j},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t,n){var o=n.overflowY,r=n.showScrollbarY,u="hidden"!==o&&!1!==r,a=e.minAvailableHeight,l=e.maxAvailableHeight,s=e.scrollStateX,c=!1,f=!1;s===i.ScrollbarState.VISIBLE&&(f=!0),u&&t>l&&(c=!0),c&&s===i.ScrollbarState.JOINT_SCROLLBARS&&(f=!0);var d=l;return f&&(d=a),{availableHeight:d,scrollEnabledX:f,scrollEnabledY:c}}Object.defineProperty(t,"__esModule",{value:!0});var i=n(61),u=o(i),a=n(18),l=o(a);t.default=(0,l.default)([u.default,function(e){return e.scrollContentHeight},function(e){return e.scrollFlags}],r)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(216),r=n(45),i=function(e){return e&&e.__esModule?e:{default:e}}(r);t.default=(0,o.createSelectorCreator)(o.defaultMemoize,i.default)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.COLUMN_REORDER_START="COLUMN_REORDER_START",t.COLUMN_REORDER_END="COLUMN_REORDER_END",t.COLUMN_REORDER_MOVE="COLUMN_REORDER_MOVE",t.COLUMN_RESIZE="COLUMN_RESIZE",t.INITIALIZE="INITIALIZE",t.PROP_CHANGE="PROP_CHANGE",t.SCROLL_START="SCROLL_START",t.SCROLL_END="SCROLL_END",t.SCROLL_TO_X="SCROLL_TO_X",t.SCROLL_TO_Y="SCROLL_TO_Y"},function(e,t,n){"use strict";function o(e,t,n){return en?n:e}e.exports=o},function(e,t,n){"use strict";function o(e){return(0,a.default)(e,function(e,t){return e+t.props.width},0)}function r(e){return(0,a.default)(e,function(e,t){return e+t.width},0)}function i(e){return(0,a.default)(e,function(e,t){return e+(t.flexGrow||0)},0)}Object.defineProperty(t,"__esModule",{value:!0}),t.sumPropWidths=o,t.getTotalWidth=r,t.getTotalFlexGrow=i;var u=n(118),a=function(e){return e&&e.__esModule?e:{default:e}}(u)},function(e,t,n){function o(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t0){var o=e.touches[0];t=o.clientX,n=o.clientY}return{x:t,y:n}}var r={getCoordinatesFromEvent:o};e.exports=r},function(e,t,n){"use strict";var o={isRTL:function(){return!1},getDirection:function(){return"LTR"}};e.exports=o},function(e,t,n){"use strict";function o(e,t){if(e===t)return!0;if("object"!==(void 0===e?"undefined":r(e))||null===e||"object"!==(void 0===t?"undefined":r(t))||null===t)return!1;var n=Object.keys(e),o=Object.keys(t);if(n.length!==o.length)return!1;for(var i=Object.prototype.hasOwnProperty.bind(t),u=0;u3&&void 0!==arguments[3]&&arguments[3];"none"!==e.display&&(o?(e.left=t+"px",e.top=n+"px"):(0,i.default)(e,t,n))}var r=n(115),i=function(e){return e&&e.__esModule?e:{default:e}}(r);e.exports=o},function(e,t,n){var o=n(120),r=n(136),i=r(o);e.exports=i},function(e,t,n){function o(e){return u(e)?r(e):i(e)}var r=n(123),i=n(132),u=n(52);e.exports=o},function(e,t,n){var o=n(125),r=n(9),i=Object.prototype,u=i.hasOwnProperty,a=i.propertyIsEnumerable,l=o(function(){return arguments}())?o:function(e){return r(e)&&u.call(e,"callee")&&!a.call(e,"callee")};e.exports=l},function(e,t){function n(e,t){var n=typeof e;return!!(t=null==t?o:t)&&("number"==n||"symbol"!=n&&r.test(e))&&e>-1&&e%1==0&&e-1&&e%1==0&&e<=o}var o=9007199254740991;e.exports=n},function(e,t,n){function o(e){return null!=e&&i(e.length)&&!r(e)}var r=n(72),i=n(51);e.exports=o},function(e,t){function n(e,t){return e===t||e!==e&&t!==t}e.exports=n},function(e,t,n){var o=n(7),r=n(4),i=o(r,"Map");e.exports=i},function(e,t,n){function o(e){var t=-1,n=null==e?0:e.length;for(this.clear();++tn?b.VISIBLE:i>n-(s.default.SIZE+s.default.OFFSET)?b.JOINT_SCROLLBARS:b.HIDDEN}function u(e,t){var n=t.bufferRowCount,o=t.rowHeight,r=t.subRowHeight;if(void 0!==n)return console.log("buffer set: "+n),n;var i=o+r,u=Math.ceil(e/i)+1;return(0,f.default)(Math.floor(u/2),v,m)}Object.defineProperty(t,"__esModule",{value:!0}),t.ScrollbarState=void 0;var a=n(21),l=n(16),s=o(l),c=n(20),f=o(c),d=n(18),p=o(d),h=1,v=3,m=6,b=t.ScrollbarState={HIDDEN:"hidden",JOINT_SCROLLBARS:"JOINT_SCROLLBARS",VISIBLE:"visible"};t.default=(0,p.default)([function(e){return e.columnProps},function(e){return e.elementHeights},function(e){return e.rowSettings},function(e){return e.scrollFlags},function(e){return e.tableSize}],r)},function(e,t,n){var o=n(234),r=n(236),i=r(function(e,t){return null==e?{}:o(e,t)});e.exports=i},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t){var n={};for(var o in e)t.indexOf(o)>=0||Object.prototype.hasOwnProperty.call(e,o)&&(n[o]=e[o]);return n}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var l=function(){function e(e,t){for(var n=0;n0,"fixedDataTableRowLayout/columnsShadow":o.props.scrollLeft>0,"public/fixedDataTableRow/fixedColumnsDivider":e>0,"public/fixedDataTableRow/columnsShadow":o.props.scrollLeft>0}),n=o.props.cellGroupWrapperHeight?o.props.cellGroupWrapperHeight-T:o.props.height,r={left:e,height:n};return m.default.createElement("div",{className:t,style:r})},o._renderFixedRightColumnsShadow=function(e){var t=(0,g.default)("fixedDataTableRowLayout/columnsShadow","fixedDataTableRowLayout/columnsRightShadow","fixedDataTableRowLayout/fixedColumnsDivider","public/fixedDataTableRow/columnsShadow","public/fixedDataTableRow/columnsRightShadow","public/fixedDataTableRow/fixedColumnsDivider"),n={height:o.props.height,left:e};return m.default.createElement("div",{className:t,style:n})},o._renderColumnsRightShadow=function(e){if(Math.ceil(o.props.scrollLeft+o.props.width)=0||Object.prototype.hasOwnProperty.call(e,o)&&(n[o]=e[o]);return n}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var l=Object.assign||function(e){for(var t=1;td))return!1;var h=c.get(e);if(h&&c.get(t))return h==t;var v=-1,m=!0,b=n&l?new r:void 0;for(c.set(e,t),c.set(t,e);++v0||e>=0&&i0||e>=0&&iMath.abs(e)&&"hidden"!==p)v+=t,v=v<0?0:v,v=v>i?i:v,a&&!a(v)||l.scrollToY(v);else if(e&&"hidden"!==d){h+=e,h=h<0?0:h,h=h>r?r:h;var m=Math.round(h);u&&!u(m)||l.scrollToX(m)}},o._onHorizontalScroll=function(e){var t=o.props,n=t.onHorizontalScroll,r=t.scrollActions,i=t.scrollX;t.scrolling;if(e!==i){var u=Math.round(e);n&&!n(u)||r.scrollToX(u)}},o._onVerticalScroll=function(e){var t=o.props,n=t.onVerticalScroll,r=t.scrollActions;e!==t.scrollY&&(n&&!n(e)||r.scrollToY(e))},o._didScroll=function(e){var t=e.onScrollStart,n=e.scrollX,r=e.scrollY,i=e.onHorizontalScroll,u=e.onVerticalScroll,a=e.tableSize.ownerHeight,l=o.props,s=l.firstRowIndex,c=l.scrollX,f=l.scrollY,d=l.tableSize.ownerHeight,p=a!==d&&!((0,I.default)(a)&&(0,I.default)(d)),h=n!==c,v=r!==f;(p||h||v)&&(!o.props.scrolling&&t&&t(c,f,s),h&&i&&i(n),v&&u&&u(r),o._didScrollStop())},o._didScrollStopSync=function(){var e=o.props,t=e.firstRowIndex,n=e.onScrollEnd,r=e.scrollActions,i=e.scrollX,u=e.scrollY;e.scrolling&&(r.stopScroll(),n&&n(i,u,t))},u=n,i(o,u)}return u(t,e),l(t,[{key:"componentWillMount",value:function(){this._didScrollStop=(0,j.default)(this._didScrollStopSync,200,this),this._onKeyDown=this._onKeyDown.bind(this),this._wheelHandler=new T.default(this._onScroll,this._shouldHandleWheelX,this._shouldHandleWheelY,this.props.stopScrollDefaultHandling,this.props.stopScrollPropagation),this._touchHandler=new x.default(this._onScroll,this._shouldHandleTouchX,this._shouldHandleTouchY,this.props.stopScrollDefaultHandling,this.props.stopScrollPropagation)}},{key:"componentWillUnmount",value:function(){this._divRef&&this._divRef.removeEventListener("wheel",this._wheelHandler.onWheel,{passive:!1}),this._divRef&&this._divRef.removeEventListener("touchmove",this._touchHandler.onTouchMove,{passive:!1}),this._wheelHandler=null,this._touchHandler=null,this._didScrollStop.reset(),this._didScrollStopSync()}},{key:"_onKeyDown",value:function(e){var t=(0,W.default)(this.props),n=t.scrollbarYHeight;if(this.props.keyboardPageEnabled)switch(e.key){case"PageDown":this._onScroll(0,n),e.preventDefault();break;case"PageUp":this._onScroll(0,-1*n),e.preventDefault()}if(this.props.keyboardScrollEnabled)switch(e.key){case"ArrowDown":this._onScroll(0,25),e.preventDefault();break;case"ArrowUp":this._onScroll(0,-25),e.preventDefault();break;case"ArrowRight":this._onScroll(25,0),e.preventDefault();break;case"ArrowLeft":this._onScroll(-25,0),e.preventDefault()}}},{key:"componentDidMount",value:function(){this._divRef&&this._divRef.addEventListener("wheel",this._wheelHandler.onWheel,{passive:!1}),this._divRef&&this._divRef.addEventListener("touchmove",this._touchHandler.onTouchMove,{passive:!1}),this._reportContentHeight()}},{key:"componentWillReceiveProps",value:function(e){this._didScroll(e)}},{key:"componentDidUpdate",value:function(){this._reportContentHeight()}},{key:"render",value:function(){var e=(0,E.default)(this.props),t=e.fixedColumnGroups,n=e.fixedColumns,o=e.fixedRightColumnGroups,r=e.fixedRightColumns,i=e.scrollableColumnGroups,u=e.scrollableColumns,a=(0,W.default)(this.props),l=a.bodyHeight,s=a.bodyOffsetTop,c=a.componentHeight,f=a.footOffsetTop,p=a.scrollbarXOffsetTop,h=a.visibleRowsHeight,v=this.props,b=v.className,y=v.columnReorderingData,g=v.columnResizingData,w=v.elementHeights,x=v.isColumnReordering,R=v.isColumnResizing,T=v.maxScrollX,S=v.maxScrollY,O=v.onColumnReorderEndCallback,M=v.onColumnResizeEndCallback,k=v.scrollContentHeight,j=v.scrollX,P=v.scrollY,I=v.scrolling,H=v.tableSize,L=v.touchScrollEnabled,N=H.ownerHeight,Y=H.width,F=w.cellGroupWrapperHeight,V=w.footerHeight,G=w.groupHeaderHeight,U=w.headerHeight,q=(0,A.default)(this.props),B=q.scrollEnabledX,K=q.scrollEnabledY,Z=O?this._onColumnReorder:null,$=void 0;G>0&&($=_.default.createElement(m.default,{key:"group_header",isScrolling:I,className:(0,z.default)((0,D.default)("fixedDataTableLayout/header"),(0,D.default)("public/fixedDataTable/header")),width:Y,height:G,cellGroupWrapperHeight:F,index:0,zIndex:1,offsetTop:0,scrollLeft:j,fixedColumns:t,fixedRightColumns:o,scrollableColumns:i,visible:!0,onColumnResize:this._onColumnResize,onColumnReorder:Z,onColumnReorderMove:this._onColumnReorderMove,showScrollbarY:K}));var J=void 0;K&&(J=_.default.createElement(C.default,{size:h,contentSize:k,onScroll:this._onVerticalScroll,verticalTop:s,position:P,touchEnabled:L}));var Q=void 0;B&&(Q=_.default.createElement(X,{contentSize:Y+T,offset:p,onScroll:this._onHorizontalScroll,position:j,size:Y,touchEnabled:L}));var ee=_.default.createElement(d.default,{height:c,initialWidth:g.width||0,minWidth:g.minWidth||0,maxWidth:g.maxWidth||Number.MAX_VALUE,visible:!!R,leftOffset:g.left||0,knobHeight:U,initialEvent:g.initialEvent,onColumnResizeEnd:M,columnKey:g.key,touchEnabled:L}),te=null;V&&(te=_.default.createElement(m.default,{key:"footer",isScrolling:I,className:(0,z.default)((0,D.default)("fixedDataTableLayout/footer"),(0,D.default)("public/fixedDataTable/footer")),width:Y,height:V,index:-1,zIndex:1,offsetTop:f,visible:!0,fixedColumns:n.footer,fixedRightColumns:r.footer,scrollableColumns:u.footer,scrollLeft:j,showScrollbarY:K}));var ne=this._renderRows(s,n.cell,r.cell,u.cell,l),oe=_.default.createElement(m.default,{key:"header",isScrolling:I,className:(0,z.default)((0,D.default)("fixedDataTableLayout/header"),(0,D.default)("public/fixedDataTable/header")),width:Y,height:U,cellGroupWrapperHeight:F,index:-1,zIndex:1,offsetTop:G,scrollLeft:j,visible:!0,fixedColumns:n.header,fixedRightColumns:r.header,scrollableColumns:u.header,touchEnabled:L,onColumnResize:this._onColumnResize,onColumnReorder:Z,onColumnReorderMove:this._onColumnReorderMove,onColumnReorderEnd:this._onColumnReorderEnd,isColumnReordering:!!x,columnReorderingData:y,showScrollbarY:K}),re=void 0;P&&(re=_.default.createElement("div",{className:(0,z.default)((0,D.default)("fixedDataTableLayout/topShadow"),(0,D.default)("public/fixedDataTable/topShadow")),style:{top:s}}));var ie=N&&Nh,ue=void 0;(ie||P=0||Object.prototype.hasOwnProperty.call(e,o)&&(n[o]=e[o]);return n}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var l=Object.assign||function(e){for(var t=1;t=0){var c=l.columnKey||"cell_"+u;n[u]=this._renderCell(e.rowIndex,e.rowHeight,l,s,i,c,o,r)}i+=l.width}var f={height:e.height,position:"absolute",width:o,zIndex:e.zIndex};return(0,v.default)(f,-1*R*e.left,0,this._initialRender),y.default.createElement("div",{className:(0,w.default)("fixedDataTableCellGroupLayout/cellGroup"),style:f},n)}}]),t}(y.default.Component);T.propTypes_DISABLED_FOR_PERFORMANCE={columns:b.default.array.isRequired,isScrolling:b.default.bool,left:b.default.number,onColumnResize:b.default.func,onColumnReorder:b.default.func,onColumnReorderMove:b.default.func,onColumnReorderEnd:b.default.func,height:b.default.number.isRequired,cellGroupWrapperHeight:b.default.number,rowHeight:b.default.number.isRequired,rowIndex:b.default.number.isRequired,width:b.default.number.isRequired,zIndex:b.default.number.isRequired,touchEnabled:b.default.bool};var S=function(e){function t(){var e,n,o,r;i(this,t);for(var a=arguments.length,l=Array(a),s=0;s=0||Object.prototype.hasOwnProperty.call(e,o)&&(n[o]=e[o]);return n}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var l=Object.assign||function(e){for(var t=1;tl,c=o>e.left,f=!1;s?rl&&(f=!0,n.displacement=c?0:-1*e.columnReorderingData.columnWidth),f?s?e.columnReorderingData.columnAfter||(e.columnReorderingData.columnAfter=e.columnKey):e.columnReorderingData.columnBefore=e.columnKey:s?e.columnReorderingData.columnBefore=e.columnKey:e.columnReorderingData.columnAfter||(e.columnReorderingData.columnAfter=e.columnKey)}}else n.displacement=0;this.setState(n)}},{key:"render",value:function(){var e=this.props,t=e.height,n=e.width,o=e.columnKey,i=r(e,["height","width","columnKey"]),u={height:t,width:n};1===C?u.left=i.left:u.right=i.left,this.state.isReorderingThisColumn&&(u.transform="translateX("+this.state.displacement+"px) translateZ(0)",u.zIndex=1);var a,s=(0,R.default)((0,w.default)({"fixedDataTableCellLayout/main":!0,"fixedDataTableCellLayout/lastChild":i.lastChild,"fixedDataTableCellLayout/alignRight":"right"===i.align,"fixedDataTableCellLayout/alignCenter":"center"===i.align,"public/fixedDataTableCell/alignRight":"right"===i.align,"public/fixedDataTableCell/highlighted":i.highlighted,"public/fixedDataTableCell/main":!0,"public/fixedDataTableCell/hasReorderHandle":!!i.onColumnReorder,"public/fixedDataTableCell/reordering":this.state.isReorderingThisColumn}),i.className);if(i.onColumnResize){var c={height:t};a=b.default.createElement("div",{className:(0,w.default)("fixedDataTableCellLayout/columnResizerContainer"),style:c,onMouseDown:this._onColumnResizerMouseDown,onTouchStart:this.props.touchEnabled?this._onColumnResizerMouseDown:null,onTouchEnd:this.props.touchEnabled?this._suppressEvent:null,onTouchMove:this.props.touchEnabled?this._suppressEvent:null},b.default.createElement("div",{className:(0,R.default)((0,w.default)("fixedDataTableCellLayout/columnResizerKnob"),(0,w.default)("public/fixedDataTableCell/columnResizerKnob")),style:c}))}var d;i.onColumnReorder&&(d=b.default.createElement(p.default,l({columnKey:this.columnKey,touchEnabled:this.props.touchEnabled,onMouseDown:this._onColumnReorderMouseDown,onTouchStart:this._onColumnReorderMouseDown,height:t},this.props)));var h={columnKey:o,height:t,width:n};i.rowIndex>=0&&(h.rowIndex=i.rowIndex);var v;return v=b.default.isValidElement(i.cell)?b.default.cloneElement(i.cell,h):"function"==typeof i.cell?i.cell(h):b.default.createElement(f.default,h,i.cell),b.default.createElement("div",{className:s,style:u},a,d,v)}}]),t}(b.default.Component);O.propTypes_DISABLED_FOR_PERFORMANCE={isScrolling:y.default.bool,align:y.default.oneOf(["left","center","right"]),className:y.default.string,highlighted:y.default.bool,width:y.default.number.isRequired,minWidth:y.default.number,maxWidth:y.default.number,height:y.default.number.isRequired,cell:y.default.oneOfType([y.default.string,y.default.element,y.default.func]),columnKey:y.default.oneOfType([y.default.string,y.default.number]),rowIndex:y.default.number.isRequired,onColumnResize:y.default.func,onColumnReorder:y.default.func,left:y.default.number,pureRendering:y.default.bool,touchEnabled:y.default.bool},O.defaultProps={align:"left",highlighted:!1},e.exports=O},function(t,n){t.exports=e},function(e,t,n){"use strict";(function(t){function o(){return null}var r=n(108),i=n(40),u=n(109),a=function(){};"production"!==t.env.NODE_ENV&&(a=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),e.exports=function(e,n){function l(e){var t=e&&(C&&e[C]||e[O]);if("function"==typeof t)return t}function s(e,t){return e===t?0!==e||1/e==1/t:e!==e&&t!==t}function c(e){this.message=e,this.stack=""}function f(e){function o(o,l,s,f,d,p,h){if(f=f||E,p=p||s,h!==i){if(n){var v=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw v.name="Invariant Violation",v}if("production"!==t.env.NODE_ENV&&"undefined"!=typeof console){var m=f+":"+s;!r[m]&&u<3&&(a("You are manually calling a React.PropTypes validation function for the `"+p+"` prop on `"+f+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),r[m]=!0,u++)}}return null==l[s]?o?new c(null===l[s]?"The "+d+" `"+p+"` is marked as required in `"+f+"`, but its value is `null`.":"The "+d+" `"+p+"` is marked as required in `"+f+"`, but its value is `undefined`."):null:e(l,s,f,d,p)}if("production"!==t.env.NODE_ENV)var r={},u=0;var l=o.bind(null,!1);return l.isRequired=o.bind(null,!0),l}function d(e){function t(t,n,o,r,i,u){var a=t[n];if(x(a)!==e)return new c("Invalid "+r+" `"+i+"` of type `"+R(a)+"` supplied to `"+o+"`, expected `"+e+"`.");return null}return f(t)}function p(e){function t(t,n,o,r,u){if("function"!=typeof e)return new c("Property `"+u+"` of component `"+o+"` has invalid PropType notation inside arrayOf.");var a=t[n];if(!Array.isArray(a)){return new c("Invalid "+r+" `"+u+"` of type `"+x(a)+"` supplied to `"+o+"`, expected an array.")}for(var l=0;l-1}var r=n(23);e.exports=o},function(e,t,n){function o(e,t){var n=this.__data__,o=r(n,e);return o<0?(++this.size,n.push([e,t])):n[o][1]=t,this}var r=n(23);e.exports=o},function(e,t,n){function o(){this.__data__=new r,this.size=0}var r=n(22);e.exports=o},function(e,t){function n(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}e.exports=n},function(e,t){function n(e){return this.__data__.get(e)}e.exports=n},function(e,t){function n(e){return this.__data__.has(e)}e.exports=n},function(e,t,n){function o(e,t){var n=this.__data__;if(n instanceof r){var o=n.__data__;if(!i||o.lengthr},ie64:function(){return g.ie()&&h},firefox:function(){return o()||i},opera:function(){return o()||u},webkit:function(){return o()||a},safari:function(){return g.webkit()},chrome:function(){return o()||l},windows:function(){return o()||f},osx:function(){return o()||c},linux:function(){return o()||d},iphone:function(){return o()||v},mobile:function(){return o()||v||m||p||_},nativeApp:function(){return o()||b},android:function(){return o()||p},ipad:function(){return o()||m}};e.exports=g},function(e,t,n){"use strict";function o(e,t){if(!u.default.canUseDOM||t&&!("addEventListener"in document))return!1;var n="on"+e,o=n in document;if(!o){var i=document.createElement("div");i.setAttribute(n,"return;"),o="function"==typeof i[n]}return!o&&r&&"wheel"===e&&(o=document.implementation.hasFeature("Events.wheel","3.0")),o}var r,i=n(67),u=function(e){return e&&e.__esModule?e:{default:e}}(i);u.default.canUseDOM&&(r=document.implementation&&document.implementation.hasFeature&&!0!==document.implementation.hasFeature("","")),e.exports=o},function(e,t,n){"use strict";function o(e){if(r.hasOwnProperty(e))return r[e];throw new Error('cssVar("'+e+'"): Unexpected class transformation.')}var r={"scrollbar-face-active-color":"#7d7d7d","scrollbar-face-color":"#c2c2c2","scrollbar-face-margin":"4px","scrollbar-face-radius":"6px","scrollbar-size":"15px","scrollbar-size-large":"17px","scrollbar-track-color":"#fff","border-color":"#d3d3d3","fbui-white":"#fff","fbui-desktop-background-light":"#f6f7f8"};o.CSS_VARS=r,e.exports=o},function(e,t,n){function o(e,t,n){return t=i(t),void 0===n?(n=t,t=0):n=i(n),e=u(e),r(e,t,n)}var r=n(208),i=n(209),u=n(59);e.exports=o},function(e,t){function n(e,t,n){return e>=r(t,n)&&e2||Math.abs(this._deltaY)>2)&&(this._stopPropagation&&e.stopPropagation(),i=!0),!0===i&&null===this._dragAnimationId&&(this._dragAnimationId=(0,s.default)(this._didTouchMove))}}},{key:"_didTouchMove",value:function(){this._dragAnimationId=null,this._onTouchScrollCallback(this._deltaX,this._deltaY),this._accumulatedDeltaX+=this._deltaX,this._accumulatedDeltaY+=this._deltaY,this._deltaX=0,this._deltaY=0}},{key:"_track",value:function(){var e=Date.now(),t=e-this._lastFrameTimestamp,n=this._velocityX,o=this._velocityY,r=.8;t<100&&(r*=t/100),0===n&&0===o&&(r=1),this._velocityX=r*(100*this._accumulatedDeltaX/(1+t)),r<1&&(this._velocityX+=(1-r)*n),this._velocityY=r*(100*this._accumulatedDeltaY/(1+t)),r<1&&(this._velocityY+=(1-r)*o),this._accumulatedDeltaX=0,this._accumulatedDeltaY=0,this._lastFrameTimestamp=e}},{key:"_startAutoScroll",value:function(){this._autoScrollTimestamp=Date.now(),(this._deltaX>0||this.deltaY>0)&&this._didTouchMove(),this._track(),this._autoScroll()}},{key:"_autoScroll",value:function(){var e=Date.now()-this._autoScrollTimestamp,t=1.6*Math.exp(-e/325),n=t*this._velocityX,o=t*this._velocityY;(Math.abs(n)<=5||!this._handleScrollX(n,o))&&(n=0),(Math.abs(o)<=5||!this._handleScrollY(o,n))&&(o=0),0===n&&0===o||(this._onTouchScrollCallback(n,o),(0,s.default)(this._autoScroll))}}]),e}();e.exports=c},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t){var n=e.columnGroupProps,o=e.columnProps,r=[],i=[],u=[];(0,l.default)(n,function(e,n){var o={props:e,template:t.groupHeader[n]};e.fixed?r.push(o):e.fixedRight?i.push(o):u.push(o)});var a={cell:[],header:[],footer:[]},s={cell:[],header:[],footer:[]},c={cell:[],header:[],footer:[]};return(0,l.default)(o,function(e,n){var o=c;e.fixed?o=a:e.fixedRight&&(o=s),o.cell.push({props:e,template:t.cell[n]}),o.header.push({props:e,template:t.header[n]}),o.footer.push({props:e,template:t.footer[n]})}),{fixedColumnGroups:r,fixedColumns:a,fixedRightColumnGroups:i,fixedRightColumns:s,scrollableColumnGroups:u,scrollableColumns:c}}Object.defineProperty(t,"__esModule",{value:!0});var i=n(84),u=o(i),a=n(60),l=o(a),s=n(18),c=o(s);t.default=(0,c.default)([function(e){return(0,u.default)(e)},function(e){return e.elementTemplates}],r)},function(e,t){function n(e,t){for(var n=-1,o=null==e?0:e.length;++n1&&void 0!==arguments[1]?arguments[1]:o,n=null,i=null;return function(){return r(t,n,arguments)||(i=e.apply(null,arguments)),n=arguments,i}}function u(e){var t=Array.isArray(e[0])?e[0]:e;if(!t.every(function(e){return"function"==typeof e})){var n=t.map(function(e){return typeof e}).join(", ");throw new Error("Selector creators expect all input-selectors to be functions, instead received the following types: ["+n+"]")}return t}function a(e){for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;o1&&void 0!==arguments[1]?arguments[1]:s;if("object"!=typeof e)throw new Error("createStructuredSelector expects first argument to be an object where each property is a selector, instead received a "+typeof e);var n=Object.keys(e);return t(n.map(function(t){return e[t]}),function(){for(var e=arguments.length,t=Array(e),o=0;o0&&void 0!==arguments[0]?arguments[0]:r(),t=arguments[1];switch(t.type){case f.INITIALIZE:var n=t.props,o=a(e,n);o=u(o);var i=(0,s.getScrollAnchor)(o,n);return o=(0,y.default)(o,i),b.default.initialize(o,n,{});case f.PROP_CHANGE:var c=t.newProps,d=t.oldProps,h=a(e,c);d.rowsCount===c.rowsCount&&d.rowHeight===c.rowHeight&&d.subRowHeight===c.subRowHeight||(h=u(h)),d.rowsCount!==c.rowsCount&&(h.rowBufferSet=new p.default);var v=(0,s.getScrollAnchor)(h,c,d);return(0,S.default)(e,h)&&!v.changed||(h=(0,y.default)(h,v)),h=b.default.initialize(h,c,d),h.scrollX===e.scrollX&&h.scrollY===e.scrollY||(h.scrolling=h.scrolling||!0),h;case f.SCROLL_END:var m=l({},e,{scrolling:!1}),_={firstIndex:e.firstRowIndex,firstOffset:e.firstRowOffset,lastIndex:e.lastIndex};return(0,y.default)(m,_);case f.SCROLL_TO_Y:var g=t.scrollY,w=l({},e,{scrolling:!0}),x=(0,s.scrollTo)(w,g);return(0,y.default)(w,x);case f.COLUMN_RESIZE:var R=t.resizeData;return b.default.resizeColumn(e,R);case f.COLUMN_REORDER_START:var T=t.reorderData;return b.default.reorderColumn(e,T);case f.COLUMN_REORDER_END:return l({},e,{isColumnReordering:!1,columnReorderingData:{}});case f.COLUMN_REORDER_MOVE:var C=t.deltaX;return b.default.reorderColumnMove(e,C);case f.SCROLL_TO_X:var O=t.scrollX;return l({},e,{scrolling:!0,scrollX:O});default:return e}}function u(e){for(var t=e.rowSettings,n=t.rowHeight,o=t.rowsCount,r=t.subRowHeight,i=n+r,u=v.default.uniform(o,i),a=o*i,s=new Array(o),c=0;c=u-o)s=void 0,f=a-1;else{var d=r.greatestLowerBound(t);s=(0,l.default)(d,0,Math.max(a-1,0));var h=r.sumUntil(s);c=h-t}return{firstIndex:s,firstOffset:c,lastIndex:f,changed:!0}}function u(e,t){var n=(0,p.default)(e),o=n.availableHeight,r=e.rowOffsetIntervalTree,i=e.rowSettings,u=e.storedHeights,a=e.scrollY,s=i.rowsCount;if(0===s)return{firstIndex:0,firstOffset:0,lastIndex:void 0,changed:0!==e.firstRowIndex||0!==e.firstRowOffset};t=(0,l.default)(t,0,Math.max(s-1,0)),(0,f.default)(e,t);var c=r.sumUntil(t),d=c+u[t],h=t,v=void 0;if(c=e&&r<=t)return null;var i;e-o>r-t?(i=o,this._smallValues.pop()):(i=r,this._largeValues.pop());var u=this._valueToPositionMap[i];return delete this._valueToPositionMap[i],this._valueToPositionMap[n]=u,this._pushToHeaps(u,n),u}},{key:"_pushToHeaps",value:function(e,t){var n={position:e,value:t};this._smallValues.push(n),this._largeValues.push(n)}},{key:"_cleanHeaps",value:function(){this._cleanHeap(this._smallValues),this._cleanHeap(this._largeValues);var e=Math.min(this._smallValues.size(),this._largeValues.size());Math.max(this._smallValues.size(),this._largeValues.size())>10*e&&this._recreateHeaps()}},{key:"_recreateHeaps",value:function(){for(var e=this._smallValues.size()t.value}}]),e}();e.exports=c},function(e,t,n){"use strict";function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){return e0&&(this._items[0]=t,this._sinkDown(0)),e}}},{key:"push",value:function(e){this._items[this._size++]=e,this._bubbleUp(this._size-1)}},{key:"size",value:function(){return this._size}},{key:"peek",value:function(){if(0!==this._size)return this._items[0]}},{key:"_heapify",value:function(){for(var e=Math.floor((this._size+1)/2);e>=0;e--)this._sinkDown(e)}},{key:"_bubbleUp",value:function(e){for(var t=this._items[e];e>0;){var n=Math.floor((e+1)/2)-1,o=this._items[n];if(this._comparator(o,t))return;this._items[n]=t,this._items[e]=o,e=n}}},{key:"_sinkDown",value:function(e){for(var t=this._items[e];;){var n=2*(e+1)-1,o=2*(e+1),r=-1;if(n=0;--n)t[n]=0;return t},c=function(){function e(t){o(this,e),this._size=t.length,this._half=r(this._size),this._heap=new s(2*this._half);var n;for(n=0;n0;--n)this._heap[n]=this._heap[2*n]+this._heap[2*n+1]}return i(e,[{key:"set",value:function(e,t){(0,a.default)(0<=e&&e=0;--r)o[r]=n;return new e(o)}},{key:"empty",value:function(t){return e.uniform(t,0)}}]),e}();e.exports=c}).call(t,n(5))},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t,n){var o=t.scrollLeft,r=(t.scrollToColumn,e.columnResizingData),u=e.isColumnResizing,a=e.scrollX;void 0===o||n&&o===n.scrollLeft||(a=o),a=i(e,t,n.scrollToColumn,a);var l=(0,v.default)(e),c=l.maxScrollX;return a=(0,b.default)(a,0,c),u=void 0!==t.isColumnResizing?t.isColumnResizing:u,r=u?r:{},s({},e,{columnResizingData:r,isColumnResizing:u,maxScrollX:c,scrollX:a})}function i(e,t,n,o){var r=t.scrollToColumn;if((0,p.default)(r))return o;var i=(0,v.default)(e),u=i.availableScrollWidth,a=i.fixedColumns,l=i.scrollableColumns,s=a.length,c=l.length,f=0===c,d=r===n,h=r=s+c;if(d||h||m||f)return o;for(var b=Math.min(r-s,l.length-1),_=0,y=0;y_?_:o}function u(e,t){var n=t.cellMinWidth,o=t.cellMaxWidth,r=t.cellWidth,i=t.columnKey,u=t.combinedWidth,a=t.clientX,l=t.clientY,c=t.leftOffset;return s({},e,{isColumnResizing:!0,columnResizingData:{left:c+u-r,width:r,minWidth:n,maxWidth:o,initialEvent:{clientX:a,clientY:l,preventDefault:f.default},key:i}})}function a(e,t){var n=t.columnKey,o=t.left,r=t.scrollStart,i=t.width,u=(0,v.default)(e),a=u.fixedColumns,l=a.some(function(e){return e.columnKey===n});return s({},e,{isColumnReordering:!0,columnReorderingData:{cancelReorder:!1,dragDistance:0,isFixed:l,scrollStart:r,columnKey:n,columnWidth:i,originalLeft:o,columnBefore:void 0,columnAfter:void 0}})}function l(e,t){var n=e.columnReorderingData,o=n.isFixed,r=n.originalLeft,i=n.scrollStart,u=e.maxScrollX,a=e.scrollX;if(!o){var l=r-i+t,c=(0,v.default)(e),f=c.availableScrollWidth;t+=a-i,l>f-y?a=Math.min(a+_,u):l<=y&&(a=Math.max(a-_,0))}var d=s({},e.columnReorderingData,{dragDistance:t,columnBefore:void 0,columnAfter:void 0});return s({},e,{scrollX:a,columnReorderingData:d})}var s=Object.assign||function(e){for(var t=1;t=t?e:t)),e}e.exports=n},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t){var n=l({},e),o=i(n,t),r=n.rowSettings,a=n.scrollContentHeight,s=r.rowsCount,f=(0,_.default)(n),d=f.bodyHeight,p=a-d;0===p&&(o.firstViewportIdx>0&&(o=i(n,{firstOffset:0,lastIndex:s-1})),n.firstRowOffset=0),u(n,o,e.scrolling);var h=0;return s>0&&(h=n.rowOffsets[o.firstViewportIdx]-n.firstRowOffset),h=(0,c.default)(h,0,p),l(n,{maxScrollY:p,scrollY:h})}function i(e,t){var n=(0,h.default)(e),o=n.bufferRowCount,r=n.maxAvailableHeight,i=e.rowSettings.rowsCount;if(0===i)return{endBufferIdx:0,endViewportIdx:0,firstBufferIdx:0,firstViewportIdx:0};var u=t.firstIndex,a=t.firstOffset,l=t.lastIndex;(u>=i||l>=i)&&(l=i-1);var s=1,c=u,f=a;void 0!==l&&(s=-1,c=l,f=0);for(var p=c,v=p;p=0&&f=R[b]&&(b+=1,a+=R[b])}return e.firstRowIndex=b,e.endRowIndex=y,e.firstRowOffset=a,{endBufferIdx:g,endViewportIdx:y,firstBufferIdx:_,firstViewportIdx:b}}function u(e,t,n){var o=e.rowBufferSet,r=e.rowOffsetIntervalTree,i=e.storedHeights,u=t.endBufferIdx,l=t.endViewportIdx,s=t.firstBufferIdx,c=t.firstViewportIdx,f=u-s;if(0===f)return e.rowOffsets={},void(e.rows=[]);for(var d=n?c:s,p=n?l:u,h=[],v={},m=r.sumUntil(d),b=d;b=r&&(i=t.replaceFurthestValuePosition(n,o-1,e)),null===i&&(i=t.getNewPositionForValue(e)),i}Object.defineProperty(t,"__esModule",{value:!0});var l=Object.assign||function(e){for(var t=1;t or "),t.push(e))});var n={cell:[],footer:[],groupHeader:[],header:[]},o=[];if(t.length&&t[0].type.__TableColumnGroup__){var u=(0,h.default)(t,r);return(0,c.default)(t,function(e,t){n.groupHeader.push(e.props.header),l.default.Children.forEach(e.props.children,function(e){var u=r(e);u.groupIdx=t,o.push(u),i(n,e)})}),{columnGroupProps:u,columnProps:o,elementTemplates:n,useGroupHeader:!0}}return(0,c.default)(t,function(e){o.push(r(e)),i(n,e)}),{columnGroupProps:[],columnProps:o,elementTemplates:n,useGroupHeader:!1}}Object.defineProperty(t,"__esModule",{value:!0});var a=n(0),l=o(a),s=n(60),c=o(s),f=n(12),d=o(f),p=n(85),h=o(p),v=n(62),m=o(v);t.default=u},function(e,t,n){function o(e,t){return r(e,t,function(t,n){return i(e,n)})}var r=n(235),i=n(82);e.exports=o},function(e,t,n){function o(e,t,n){for(var o=-1,a=t.length,l={};++o0&&n(c)?t>1?o(c,t-1,n,u,a):r(a,c):u||(a[a.length]=c)}return a}var r=n(78),i=n(239);e.exports=o},function(e,t,n){function o(e){return u(e)||i(e)||!!(a&&e&&e[a])}var r=n(13),i=n(49),u=n(1),a=r?r.isConcatSpreadable:void 0;e.exports=o},function(e,t,n){function o(e,t,n){return t=i(void 0===t?e.length-1:t,0),function(){for(var o=arguments,u=-1,a=i(o.length-t,0),l=Array(a);++u0){if(++t>=o)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var o=800,r=16,i=Date.now;e.exports=n},function(e,t,n){"use strict";function o(e){return null==e?void 0===e?l:a:s&&s in Object(e)?Object(i.a)(e):Object(u.a)(e)}var r=n(94),i=n(249),u=n(250),a="[object Null]",l="[object Undefined]",s=r.a?r.a.toStringTag:void 0;t.a=o},function(e,t,n){"use strict";var o=n(248),r="object"==typeof self&&self&&self.Object===Object&&self,i=o.a||r||Function("return this")();t.a=i},function(e,t,n){"use strict";(function(e){var n="object"==typeof e&&e&&e.Object===Object&&e;t.a=n}).call(t,n(5))},function(e,t,n){"use strict";function o(e){var t=u.call(e,l),n=e[l];try{e[l]=void 0;var o=!0}catch(e){}var r=a.call(e);return o&&(t?e[l]=n:delete e[l]),r}var r=n(94),i=Object.prototype,u=i.hasOwnProperty,a=i.toString,l=r.a?r.a.toStringTag:void 0;t.a=o},function(e,t,n){"use strict";function o(e){return i.call(e)}var r=Object.prototype,i=r.toString;t.a=o},function(e,t,n){"use strict";var o=n(252),r=Object(o.a)(Object.getPrototypeOf,Object);t.a=r},function(e,t,n){"use strict";function o(e,t){return function(n){return e(t(n))}}t.a=o},function(e,t,n){"use strict";function o(e){return null!=e&&"object"==typeof e}t.a=o},function(e,t,n){"use strict";(function(e,o){var r,i=n(256);r="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==e?e:o;var u=Object(i.a)(r);t.a=u}).call(t,n(5),n(255)(e))},function(e,t){e.exports=function(e){if(!e.webpackPolyfill){var t=Object.create(e);t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),Object.defineProperty(t,"exports",{enumerable:!0}),t.webpackPolyfill=1}return t}},function(e,t,n){"use strict";function o(e){var t,n=e.Symbol;return"function"==typeof n?n.observable?t=n.observable:(t=n("observable"),n.observable=t):t="@@observable",t}t.a=o},function(e,t,n){"use strict";(function(e){function o(e,t){var n=t&&t.type;return"Given action "+(n&&'"'+n.toString()+'"'||"an action")+', reducer "'+e+'" returned undefined. To ignore an action, you must explicitly return the previous state. If you want this reducer to hold no value, you can return null instead of undefined.'}function r(e,t,n,o){var r=Object.keys(t),i=n&&n.type===a.a.INIT?"preloadedState argument passed to createStore":"previous state received by the reducer";if(0===r.length)return"Store does not have a valid reducer. Make sure the argument passed to combineReducers is an object whose values are reducers.";if(!Object(l.a)(e))return"The "+i+' has unexpected type of "'+{}.toString.call(e).match(/\s([a-z|A-Z]+)/)[1]+'". Expected argument to be an object with the following keys: "'+r.join('", "')+'"';var u=Object.keys(e).filter(function(e){return!t.hasOwnProperty(e)&&!o[e]});return u.forEach(function(e){o[e]=!0}),u.length>0?"Unexpected "+(u.length>1?"keys":"key")+' "'+u.join('", "')+'" found in '+i+'. Expected to find one of the known reducer keys instead: "'+r.join('", "')+'". Unexpected keys will be ignored.':void 0}function i(e){Object.keys(e).forEach(function(t){var n=e[t];if(void 0===n(void 0,{type:a.a.INIT}))throw new Error('Reducer "'+t+"\" returned undefined during initialization. If the state passed to the reducer is undefined, you must explicitly return the initial state. The initial state may not be undefined. If you don't want to set a value for this reducer, you can use null instead of undefined.");if(void 0===n(void 0,{type:"@@redux/PROBE_UNKNOWN_ACTION_"+Math.random().toString(36).substring(7).split("").join(".")}))throw new Error('Reducer "'+t+"\" returned undefined when probed with a random type. Don't try to handle "+a.a.INIT+' or other actions in "redux/*" namespace. They are considered private. Instead, you must return the current state for any unknown actions, unless it is undefined, in which case you must return the initial state, regardless of the action type. The initial state may not be undefined, but can be null.')})}function u(t){for(var n=Object.keys(t),u={},a=0;a0&&void 0!==arguments[0]?arguments[0]:{},n=arguments[1];if(d)throw d;if("production"!==e.env.NODE_ENV){var i=r(t,u,n,f);i&&Object(s.a)(i)}for(var a=!1,l={},p=0;p should never render")}}]),t}(s.default.Component);d.__TableColumn__=!0,d.propTypes={align:f.default.oneOf(["left","center","right"]),fixed:f.default.bool,fixedRight:f.default.bool,header:f.default.oneOfType([f.default.node,f.default.func]),cell:f.default.oneOfType([f.default.node,f.default.func]),footer:f.default.oneOfType([f.default.node,f.default.func]),columnKey:f.default.oneOfType([f.default.string,f.default.number]),width:f.default.number.isRequired,minWidth:f.default.number,maxWidth:f.default.number,flexGrow:f.default.number,isResizable:f.default.bool,isReorderable:f.default.bool,allowCellsRecycling:f.default.bool,pureRendering:f.default.bool},d.defaultProps={allowCellsRecycling:!1,fixed:!1,fixedRight:!1},e.exports=d},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var a=function(){function e(e,t){for(var n=0;n should never render")}}]),t}(s.default.Component);d.__TableColumnGroup__=!0,d.propTypes={align:f.default.oneOf(["left","center","right"]),fixed:f.default.bool,header:f.default.oneOfType([f.default.node,f.default.func])},d.defaultProps={fixed:!1},e.exports=d}])}); \ No newline at end of file +!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("react-dom")):"function"==typeof define&&define.amd?define(["react","react-dom"],t):"object"==typeof exports?exports.FixedDataTable=t(require("react"),require("react-dom")):e.FixedDataTable=t(e.React,e.ReactDOM)}("undefined"!=typeof self?self:this,function(e,t){return function(e){function t(o){if(n[o])return n[o].exports;var r=n[o]={i:o,l:!1,exports:{}};return e[o].call(r.exports,r,r.exports,t),r.l=!0,r.exports}var n={};return t.m=e,t.c=n,t.d=function(e,n,o){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:o})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=99)}([function(e,t,n){"use strict";e.exports=n(106)},function(e,t){var n=Array.isArray;e.exports=n},function(e,t,n){(function(t){if("production"!==t.env.NODE_ENV){var o="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,r=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===o};e.exports=n(107)(r,!0)}else e.exports=n(110)()}).call(t,n(10))},function(e,t,n){"use strict";function o(e){return a[e]?a[e]:(a[e]=e.replace(u,"_"),a[e])}function r(e){var t;return t="object"==(void 0===e?"undefined":i(e))?Object.keys(e).filter(function(t){return e[t]}):Array.prototype.slice.call(arguments),t.map(o).join(" ")}var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},u=/\//g,a={};e.exports=r},function(e,t,n){var o=n(68),r="object"==typeof self&&self&&self.Object===Object&&self,i=o||r||Function("return this")();e.exports=i},function(e,t){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";function o(e){return function(){return e}}function r(){}r.thatReturns=o,r.thatReturnsFalse=o(!1),r.thatReturnsTrue=o(!0),r.thatReturnsNull=o(null),r.thatReturnsThis=function(){return this},r.thatReturnsArgument=function(e){return e},e.exports=r},function(e,t,n){function o(e,t){var n=i(e,t);return r(n)?n:void 0}var r=n(149),i=n(152);e.exports=o},function(e,t,n){function o(e){return null==e?void 0===e?l:a:s&&s in Object(e)?i(e):u(e)}var r=n(13),i=n(126),u=n(127),a="[object Null]",l="[object Undefined]",s=r?r.toStringTag:void 0;e.exports=o},function(e,t){function n(e){return null!=e&&"object"==typeof e}e.exports=n},function(e,t){function n(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function r(e){if(c===setTimeout)return setTimeout(e,0);if((c===n||!c)&&setTimeout)return c=setTimeout,setTimeout(e,0);try{return c(e,0)}catch(t){try{return c.call(null,e,0)}catch(t){return c.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===o||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function u(){v&&p&&(v=!1,p.length?h=p.concat(h):m=-1,h.length&&a())}function a(){if(!v){var e=r(u);v=!0;for(var t=h.length;t;){for(p=h,h=[];++m1)for(var n=1;n1)for(var o=1;oc&&(t=c);var f=!!e._mouseMoveTracker&&e._mouseMoveTracker.isDragging(),d={faceSize:s,isDragging:f,isHorizontal:a,position:t,scale:l,scrollable:!0};return e._stateKey=u,e._stateForKey=d,d},this._onWheelY=function(t,n){e._onWheel(n)},this._onWheelX=function(t,n){e._onWheel(t)},this._onWheel=function(t){var n=e.props;e._setNextState(e._calculateState(e.state.position+t,n.size,n.contentSize,n.orientation))},this._onMouseDown=function(t){var n;if(t.target!==e._faceRef){var o=t.nativeEvent,r=e.state.isHorizontal?o.offsetX||o.layerX||e.getTouchX(o):o.offsetY||o.layerY||e.getTouchY(o),i=e.props;r/=e.state.scale,n=e._calculateState(r-.5*e.state.faceSize/e.state.scale,i.size,i.contentSize,i.orientation)}else n={};n.focused=!0,e._setNextState(n),e._mouseMoveTracker.captureMouseMoves(t),e._rootRef.focus()},this._onTouchCancel=function(e){e.stopPropagation()},this._onTouchEnd=function(e){e.stopPropagation()},this._onTouchMove=function(e){e.stopPropagation()},this._onTouchStart=function(t){t.stopPropagation(),e._onMouseDown(t)},this._onMouseMove=function(t,n){var o=e.props,r=e.state.isHorizontal?t:n;r/=e.state.scale,e._setNextState(e._calculateState(e.state.position+r,o.size,o.contentSize,o.orientation))},this._onMouseMoveEnd=function(){e._nextState=null,e._mouseMoveTracker.releaseMouseMoves(),e.setState({isDragging:!1})},this._onKeyDown=function(t){var n=t.keyCode;if(n!==f.default.TAB){var o=40,r=0;if(e.state.isHorizontal)switch(n){case f.default.HOME:r=-1,o=e.props.contentSize;break;case f.default.LEFT:r=-1;break;case f.default.RIGHT:r=1;break;default:return}if(!e.state.isHorizontal)switch(n){case f.default.SPACE:r=t.shiftKey?-1:1;break;case f.default.HOME:r=-1,o=e.props.contentSize;break;case f.default.UP:r=-1;break;case f.default.DOWN:r=1;break;case f.default.PAGE_UP:r=-1,o=e.props.size;break;case f.default.PAGE_DOWN:r=1,o=e.props.size;break;default:return}t.preventDefault();var i=e.props;e._setNextState(e._calculateState(e.state.position+o*r,i.size,i.contentSize,i.orientation))}},this._onFocus=function(){e.setState({focused:!0})},this._onBlur=function(){e.setState({focused:!1})},this._blur=function(){var t=b.default.findDOMNode(e);if(t)try{e._onBlur(),t.blur()}catch(e){}},this.getTouchX=function(e){return Math.round(e.targetTouches[0].pageX-e.target.getBoundingClientRect().x)},this.getTouchY=function(e){return Math.round(e.targetTouches[0].pageY-e.target.getBoundingClientRect().y)},this._setNextState=function(t,n){n=n||e.props;var o=n.position,r=e.state.position!==t.position;if(void 0===o){var i=r?e._didScroll:void 0;e.setState(t,i)}else{if(o!==t.position)return void(void 0!==t.position&&t.position!==e.state.position&&e.props.onScroll(t.position));e.setState(t)}r&&k!==e&&(k&&k._blur(),k=e)},this._didScroll=function(){e.props.onScroll(e.state.position)}};j.KEYBOARD_SCROLL_AMOUNT=40,j.SIZE=parseInt((0,w.default)("scrollbar-size"),10),j.OFFSET=1,e.exports=j},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t,n){var o=n.overflowY,r=n.showScrollbarY,u="hidden"!==o&&!1!==r,a=e.minAvailableHeight,l=e.maxAvailableHeight,s=e.scrollStateX,c=!1,f=!1;s===i.ScrollbarState.VISIBLE&&(f=!0),u&&t>l&&(c=!0),c&&s===i.ScrollbarState.JOINT_SCROLLBARS&&(f=!0);var d=l;return f&&(d=a),{availableHeight:d,scrollEnabledX:f,scrollEnabledY:c}}Object.defineProperty(t,"__esModule",{value:!0});var i=n(61),u=o(i),a=n(18),l=o(a);t.default=(0,l.default)([u.default,function(e){return e.scrollContentHeight},function(e){return e.scrollFlags}],r)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=n(216),r=n(45),i=function(e){return e&&e.__esModule?e:{default:e}}(r);t.default=(0,o.createSelectorCreator)(o.defaultMemoize,i.default)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.COLUMN_REORDER_START="COLUMN_REORDER_START",t.COLUMN_REORDER_END="COLUMN_REORDER_END",t.COLUMN_REORDER_MOVE="COLUMN_REORDER_MOVE",t.COLUMN_RESIZE="COLUMN_RESIZE",t.INITIALIZE="INITIALIZE",t.PROP_CHANGE="PROP_CHANGE",t.SCROLL_START="SCROLL_START",t.SCROLL_END="SCROLL_END",t.SCROLL_TO_X="SCROLL_TO_X",t.SCROLL_TO_Y="SCROLL_TO_Y"},function(e,t,n){"use strict";function o(e,t,n){return en?n:e}e.exports=o},function(e,t,n){"use strict";function o(e){return(0,a.default)(e,function(e,t){return e+t.props.width},0)}function r(e){return(0,a.default)(e,function(e,t){return e+t.width},0)}function i(e){return(0,a.default)(e,function(e,t){return e+(t.flexGrow||0)},0)}Object.defineProperty(t,"__esModule",{value:!0}),t.sumPropWidths=o,t.getTotalWidth=r,t.getTotalFlexGrow=i;var u=n(118),a=function(e){return e&&e.__esModule?e:{default:e}}(u)},function(e,t,n){function o(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t0){var o=e.touches[0];t=o.clientX,n=o.clientY}return{x:t,y:n}}var r={getCoordinatesFromEvent:o};e.exports=r},function(e,t,n){"use strict";var o={isRTL:function(){return!1},getDirection:function(){return"LTR"}};e.exports=o},function(e,t,n){"use strict";function o(e,t){if(e===t)return!0;if("object"!==(void 0===e?"undefined":r(e))||null===e||"object"!==(void 0===t?"undefined":r(t))||null===t)return!1;var n=Object.keys(e),o=Object.keys(t);if(n.length!==o.length)return!1;for(var i=Object.prototype.hasOwnProperty.bind(t),u=0;u3&&void 0!==arguments[3]&&arguments[3];"none"!==e.display&&(o?(e.left=t+"px",e.top=n+"px"):(0,i.default)(e,t,n))}var r=n(115),i=function(e){return e&&e.__esModule?e:{default:e}}(r);e.exports=o},function(e,t,n){var o=n(120),r=n(136),i=r(o);e.exports=i},function(e,t,n){function o(e){return u(e)?r(e):i(e)}var r=n(123),i=n(132),u=n(52);e.exports=o},function(e,t,n){var o=n(125),r=n(9),i=Object.prototype,u=i.hasOwnProperty,a=i.propertyIsEnumerable,l=o(function(){return arguments}())?o:function(e){return r(e)&&u.call(e,"callee")&&!a.call(e,"callee")};e.exports=l},function(e,t){function n(e,t){var n=typeof e;return!!(t=null==t?o:t)&&("number"==n||"symbol"!=n&&r.test(e))&&e>-1&&e%1==0&&e-1&&e%1==0&&e<=o}var o=9007199254740991;e.exports=n},function(e,t,n){function o(e){return null!=e&&i(e.length)&&!r(e)}var r=n(72),i=n(51);e.exports=o},function(e,t){function n(e,t){return e===t||e!==e&&t!==t}e.exports=n},function(e,t,n){var o=n(7),r=n(4),i=o(r,"Map");e.exports=i},function(e,t,n){function o(e){var t=-1,n=null==e?0:e.length;for(this.clear();++tn?b.VISIBLE:i>n-(s.default.SIZE+s.default.OFFSET)?b.JOINT_SCROLLBARS:b.HIDDEN}function u(e,t){var n=t.bufferRowCount,o=t.rowHeight,r=t.subRowHeight;if(void 0!==n)return console.log("buffer set: "+n),n;var i=o+r,u=Math.ceil(e/i)+1;return(0,f.default)(Math.floor(u/2),v,m)}Object.defineProperty(t,"__esModule",{value:!0}),t.ScrollbarState=void 0;var a=n(21),l=n(16),s=o(l),c=n(20),f=o(c),d=n(18),p=o(d),h=1,v=3,m=6,b=t.ScrollbarState={HIDDEN:"hidden",JOINT_SCROLLBARS:"JOINT_SCROLLBARS",VISIBLE:"visible"};t.default=(0,p.default)([function(e){return e.columnProps},function(e){return e.elementHeights},function(e){return e.rowSettings},function(e){return e.scrollFlags},function(e){return e.tableSize}],r)},function(e,t,n){var o=n(234),r=n(236),i=r(function(e,t){return null==e?{}:o(e,t)});e.exports=i},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t){var n={};for(var o in e)t.indexOf(o)>=0||Object.prototype.hasOwnProperty.call(e,o)&&(n[o]=e[o]);return n}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var l=function(){function e(e,t){for(var n=0;n0,"fixedDataTableRowLayout/columnsShadow":o.props.scrollLeft>0,"public/fixedDataTableRow/fixedColumnsDivider":e>0,"public/fixedDataTableRow/columnsShadow":o.props.scrollLeft>0}),n=o.props.cellGroupWrapperHeight?o.props.cellGroupWrapperHeight-T:o.props.height,r={left:e,height:n};return m.default.createElement("div",{className:t,style:r})},o._renderFixedRightColumnsShadow=function(e){var t=(0,g.default)("fixedDataTableRowLayout/columnsShadow","fixedDataTableRowLayout/columnsRightShadow","fixedDataTableRowLayout/fixedColumnsDivider","public/fixedDataTableRow/columnsShadow","public/fixedDataTableRow/columnsRightShadow","public/fixedDataTableRow/fixedColumnsDivider"),n={height:o.props.height,left:e};return m.default.createElement("div",{className:t,style:n})},o._renderColumnsRightShadow=function(e){if(Math.ceil(o.props.scrollLeft+o.props.width)=0||Object.prototype.hasOwnProperty.call(e,o)&&(n[o]=e[o]);return n}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var l=Object.assign||function(e){for(var t=1;td))return!1;var h=c.get(e);if(h&&c.get(t))return h==t;var v=-1,m=!0,b=n&l?new r:void 0;for(c.set(e,t),c.set(t,e);++v0||e>=0&&i0||e>=0&&iMath.abs(e)&&"hidden"!==p)v+=t,v=v<0?0:v,v=v>i?i:v,a&&!a(v)||l.scrollToY(v);else if(e&&"hidden"!==d){h+=e,h=h<0?0:h,h=h>r?r:h;var m=Math.round(h);u&&!u(m)||l.scrollToX(m)}},o._onHorizontalScroll=function(e){var t=o.props,n=t.onHorizontalScroll,r=t.scrollActions,i=t.scrollX;t.scrolling;if(e!==i){var u=Math.round(e);n&&!n(u)||r.scrollToX(u)}},o._onVerticalScroll=function(e){var t=o.props,n=t.onVerticalScroll,r=t.scrollActions;e!==t.scrollY&&(n&&!n(e)||r.scrollToY(e))},o._didScroll=function(e){var t=e.onScrollStart,n=e.scrollX,r=e.scrollY,i=e.onHorizontalScroll,u=e.onVerticalScroll,a=e.tableSize.ownerHeight,l=o.props,s=l.firstRowIndex,c=l.scrollX,f=l.scrollY,d=l.tableSize.ownerHeight,p=a!==d&&!((0,I.default)(a)&&(0,I.default)(d)),h=n!==c,v=r!==f;(p||h||v)&&(!o.props.scrolling&&t&&t(c,f,s),h&&i&&i(n),v&&u&&u(r),o._didScrollStop())},o._didScrollStopSync=function(){var e=o.props,t=e.firstRowIndex,n=e.onScrollEnd,r=e.scrollActions,i=e.scrollX,u=e.scrollY;e.scrolling&&(r.stopScroll(),n&&n(i,u,t))},u=n,i(o,u)}return u(t,e),l(t,[{key:"componentWillMount",value:function(){this._didScrollStop=(0,j.default)(this._didScrollStopSync,200,this),this._onKeyDown=this._onKeyDown.bind(this),this._wheelHandler=new T.default(this._onScroll,this._shouldHandleWheelX,this._shouldHandleWheelY,this.props.stopScrollDefaultHandling,this.props.stopScrollPropagation),this._touchHandler=new x.default(this._onScroll,this._shouldHandleTouchX,this._shouldHandleTouchY,this.props.stopScrollDefaultHandling,this.props.stopScrollPropagation)}},{key:"componentWillUnmount",value:function(){this._divRef&&this._divRef.removeEventListener("wheel",this._wheelHandler.onWheel,{passive:!1}),this._divRef&&this._divRef.removeEventListener("touchmove",this._touchHandler.onTouchMove,{passive:!1}),this._wheelHandler=null,this._touchHandler=null,this._didScrollStop.reset(),this._didScrollStopSync()}},{key:"_onKeyDown",value:function(e){var t=(0,W.default)(this.props),n=t.scrollbarYHeight;if(this.props.keyboardPageEnabled)switch(e.key){case"PageDown":this._onScroll(0,n),e.preventDefault();break;case"PageUp":this._onScroll(0,-1*n),e.preventDefault()}if(this.props.keyboardScrollEnabled)switch(e.key){case"ArrowDown":this._onScroll(0,25),e.preventDefault();break;case"ArrowUp":this._onScroll(0,-25),e.preventDefault();break;case"ArrowRight":this._onScroll(25,0),e.preventDefault();break;case"ArrowLeft":this._onScroll(-25,0),e.preventDefault()}}},{key:"componentDidMount",value:function(){this._divRef&&this._divRef.addEventListener("wheel",this._wheelHandler.onWheel,{passive:!1}),this._divRef&&this._divRef.addEventListener("touchmove",this._touchHandler.onTouchMove,{passive:!1}),this._reportContentHeight()}},{key:"componentWillReceiveProps",value:function(e){this._didScroll(e)}},{key:"componentDidUpdate",value:function(){this._reportContentHeight()}},{key:"render",value:function(){var e=(0,E.default)(this.props),t=e.fixedColumnGroups,n=e.fixedColumns,o=e.fixedRightColumnGroups,r=e.fixedRightColumns,i=e.scrollableColumnGroups,u=e.scrollableColumns,a=(0,W.default)(this.props),l=a.bodyHeight,s=a.bodyOffsetTop,c=a.componentHeight,f=a.footOffsetTop,p=a.scrollbarXOffsetTop,h=a.visibleRowsHeight,v=this.props,b=v.className,y=v.columnReorderingData,g=v.columnResizingData,w=v.elementHeights,x=v.isColumnReordering,R=v.isColumnResizing,T=v.maxScrollX,S=v.maxScrollY,O=v.onColumnReorderEndCallback,M=v.onColumnResizeEndCallback,k=v.scrollContentHeight,j=v.scrollX,P=v.scrollY,I=v.scrolling,H=v.tableSize,L=v.touchScrollEnabled,N=H.ownerHeight,Y=H.width,F=w.cellGroupWrapperHeight,V=w.footerHeight,G=w.groupHeaderHeight,U=w.headerHeight,q=(0,A.default)(this.props),B=q.scrollEnabledX,K=q.scrollEnabledY,Z=O?this._onColumnReorder:null,$=void 0;G>0&&($=_.default.createElement(m.default,{key:"group_header",isScrolling:I,className:(0,z.default)((0,D.default)("fixedDataTableLayout/header"),(0,D.default)("public/fixedDataTable/header")),width:Y,height:G,cellGroupWrapperHeight:F,index:0,zIndex:1,offsetTop:0,scrollLeft:j,fixedColumns:t,fixedRightColumns:o,scrollableColumns:i,visible:!0,onColumnResize:this._onColumnResize,onColumnReorder:Z,onColumnReorderMove:this._onColumnReorderMove,showScrollbarY:K}));var J=void 0;K&&(J=_.default.createElement(C.default,{size:h,contentSize:k,onScroll:this._onVerticalScroll,verticalTop:s,position:P,touchEnabled:L}));var Q=void 0;B&&(Q=_.default.createElement(X,{contentSize:Y+T,offset:p,onScroll:this._onHorizontalScroll,position:j,size:Y,touchEnabled:L}));var ee=_.default.createElement(d.default,{height:c,initialWidth:g.width||0,minWidth:g.minWidth||0,maxWidth:g.maxWidth||Number.MAX_VALUE,visible:!!R,leftOffset:g.left||0,knobHeight:U,initialEvent:g.initialEvent,onColumnResizeEnd:M,columnKey:g.key,touchEnabled:L}),te=null;V&&(te=_.default.createElement(m.default,{key:"footer",isScrolling:I,className:(0,z.default)((0,D.default)("fixedDataTableLayout/footer"),(0,D.default)("public/fixedDataTable/footer")),width:Y,height:V,index:-1,zIndex:1,offsetTop:f,visible:!0,fixedColumns:n.footer,fixedRightColumns:r.footer,scrollableColumns:u.footer,scrollLeft:j,showScrollbarY:K}));var ne=this._renderRows(s,n.cell,r.cell,u.cell,l),oe=_.default.createElement(m.default,{key:"header",isScrolling:I,className:(0,z.default)((0,D.default)("fixedDataTableLayout/header"),(0,D.default)("public/fixedDataTable/header")),width:Y,height:U,cellGroupWrapperHeight:F,index:-1,zIndex:1,offsetTop:G,scrollLeft:j,visible:!0,fixedColumns:n.header,fixedRightColumns:r.header,scrollableColumns:u.header,touchEnabled:L,onColumnResize:this._onColumnResize,onColumnReorder:Z,onColumnReorderMove:this._onColumnReorderMove,onColumnReorderEnd:this._onColumnReorderEnd,isColumnReordering:!!x,columnReorderingData:y,showScrollbarY:K}),re=void 0;P&&(re=_.default.createElement("div",{className:(0,z.default)((0,D.default)("fixedDataTableLayout/topShadow"),(0,D.default)("public/fixedDataTable/topShadow")),style:{top:s}}));var ie=N&&Nh,ue=void 0;(ie||P=0||Object.prototype.hasOwnProperty.call(e,o)&&(n[o]=e[o]);return n}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var l=Object.assign||function(e){for(var t=1;t=0){var c=l.columnKey||"cell_"+u;n[u]=this._renderCell(e.rowIndex,e.rowHeight,l,s,i,c,o,r)}i+=l.width}var f={height:e.height,position:"absolute",width:o,zIndex:e.zIndex};return(0,v.default)(f,-1*R*e.left,0,this._initialRender),y.default.createElement("div",{className:(0,w.default)("fixedDataTableCellGroupLayout/cellGroup"),style:f},n)}}]),t}(y.default.Component);T.propTypes_DISABLED_FOR_PERFORMANCE={columns:b.default.array.isRequired,isScrolling:b.default.bool,left:b.default.number,onColumnResize:b.default.func,onColumnReorder:b.default.func,onColumnReorderMove:b.default.func,onColumnReorderEnd:b.default.func,height:b.default.number.isRequired,cellGroupWrapperHeight:b.default.number,rowHeight:b.default.number.isRequired,rowIndex:b.default.number.isRequired,width:b.default.number.isRequired,zIndex:b.default.number.isRequired,touchEnabled:b.default.bool};var S=function(e){function t(){var e,n,o,r;i(this,t);for(var a=arguments.length,l=Array(a),s=0;s=0||Object.prototype.hasOwnProperty.call(e,o)&&(n[o]=e[o]);return n}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var l=Object.assign||function(e){for(var t=1;tl,c=o>e.left,f=!1;s?rl&&(f=!0,n.displacement=c?0:-1*e.columnReorderingData.columnWidth),f?s?e.columnReorderingData.columnAfter||(e.columnReorderingData.columnAfter=e.columnKey):e.columnReorderingData.columnBefore=e.columnKey:s?e.columnReorderingData.columnBefore=e.columnKey:e.columnReorderingData.columnAfter||(e.columnReorderingData.columnAfter=e.columnKey)}}else n.displacement=0;this.setState(n)}},{key:"render",value:function(){var e=this.props,t=e.height,n=e.width,o=e.columnKey,i=r(e,["height","width","columnKey"]),u={height:t,width:n};1===C?u.left=i.left:u.right=i.left,this.state.isReorderingThisColumn&&(u.transform="translateX("+this.state.displacement+"px) translateZ(0)",u.zIndex=1);var a,s=(0,R.default)((0,w.default)({"fixedDataTableCellLayout/main":!0,"fixedDataTableCellLayout/lastChild":i.lastChild,"fixedDataTableCellLayout/alignRight":"right"===i.align,"fixedDataTableCellLayout/alignCenter":"center"===i.align,"public/fixedDataTableCell/alignRight":"right"===i.align,"public/fixedDataTableCell/highlighted":i.highlighted,"public/fixedDataTableCell/main":!0,"public/fixedDataTableCell/hasReorderHandle":!!i.onColumnReorder,"public/fixedDataTableCell/reordering":this.state.isReorderingThisColumn}),i.className);if(i.onColumnResize){var c={height:t};a=b.default.createElement("div",{className:(0,w.default)("fixedDataTableCellLayout/columnResizerContainer"),style:c,onMouseDown:this._onColumnResizerMouseDown,onTouchStart:this.props.touchEnabled?this._onColumnResizerMouseDown:null,onTouchEnd:this.props.touchEnabled?this._suppressEvent:null,onTouchMove:this.props.touchEnabled?this._suppressEvent:null},b.default.createElement("div",{className:(0,R.default)((0,w.default)("fixedDataTableCellLayout/columnResizerKnob"),(0,w.default)("public/fixedDataTableCell/columnResizerKnob")),style:c}))}var d;i.onColumnReorder&&(d=b.default.createElement(p.default,l({columnKey:this.columnKey,touchEnabled:this.props.touchEnabled,onMouseDown:this._onColumnReorderMouseDown,onTouchStart:this._onColumnReorderMouseDown,height:t},this.props)));var h={columnKey:o,height:t,width:n};i.rowIndex>=0&&(h.rowIndex=i.rowIndex);var v;return v=b.default.isValidElement(i.cell)?b.default.cloneElement(i.cell,h):"function"==typeof i.cell?i.cell(h):b.default.createElement(f.default,h,i.cell),b.default.createElement("div",{className:s,style:u},a,d,v)}}]),t}(b.default.Component);O.propTypes_DISABLED_FOR_PERFORMANCE={isScrolling:y.default.bool,align:y.default.oneOf(["left","center","right"]),className:y.default.string,highlighted:y.default.bool,width:y.default.number.isRequired,minWidth:y.default.number,maxWidth:y.default.number,height:y.default.number.isRequired,cell:y.default.oneOfType([y.default.string,y.default.element,y.default.func]),columnKey:y.default.oneOfType([y.default.string,y.default.number]),rowIndex:y.default.number.isRequired,onColumnResize:y.default.func,onColumnReorder:y.default.func,left:y.default.number,pureRendering:y.default.bool,touchEnabled:y.default.bool},O.defaultProps={align:"left",highlighted:!1},e.exports=O},function(t,n){t.exports=e},function(e,t,n){"use strict";(function(t){function o(){return null}var r=n(108),i=n(40),u=n(109),a=function(){};"production"!==t.env.NODE_ENV&&(a=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),e.exports=function(e,n){function l(e){var t=e&&(C&&e[C]||e[O]);if("function"==typeof t)return t}function s(e,t){return e===t?0!==e||1/e==1/t:e!==e&&t!==t}function c(e){this.message=e,this.stack=""}function f(e){function o(o,l,s,f,d,p,h){if(f=f||E,p=p||s,h!==i){if(n){var v=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw v.name="Invariant Violation",v}if("production"!==t.env.NODE_ENV&&"undefined"!=typeof console){var m=f+":"+s;!r[m]&&u<3&&(a("You are manually calling a React.PropTypes validation function for the `"+p+"` prop on `"+f+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),r[m]=!0,u++)}}return null==l[s]?o?new c(null===l[s]?"The "+d+" `"+p+"` is marked as required in `"+f+"`, but its value is `null`.":"The "+d+" `"+p+"` is marked as required in `"+f+"`, but its value is `undefined`."):null:e(l,s,f,d,p)}if("production"!==t.env.NODE_ENV)var r={},u=0;var l=o.bind(null,!1);return l.isRequired=o.bind(null,!0),l}function d(e){function t(t,n,o,r,i,u){var a=t[n];if(x(a)!==e)return new c("Invalid "+r+" `"+i+"` of type `"+R(a)+"` supplied to `"+o+"`, expected `"+e+"`.");return null}return f(t)}function p(e){function t(t,n,o,r,u){if("function"!=typeof e)return new c("Property `"+u+"` of component `"+o+"` has invalid PropType notation inside arrayOf.");var a=t[n];if(!Array.isArray(a)){return new c("Invalid "+r+" `"+u+"` of type `"+x(a)+"` supplied to `"+o+"`, expected an array.")}for(var l=0;l-1}var r=n(23);e.exports=o},function(e,t,n){function o(e,t){var n=this.__data__,o=r(n,e);return o<0?(++this.size,n.push([e,t])):n[o][1]=t,this}var r=n(23);e.exports=o},function(e,t,n){function o(){this.__data__=new r,this.size=0}var r=n(22);e.exports=o},function(e,t){function n(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}e.exports=n},function(e,t){function n(e){return this.__data__.get(e)}e.exports=n},function(e,t){function n(e){return this.__data__.has(e)}e.exports=n},function(e,t,n){function o(e,t){var n=this.__data__;if(n instanceof r){var o=n.__data__;if(!i||o.lengthr},ie64:function(){return g.ie()&&h},firefox:function(){return o()||i},opera:function(){return o()||u},webkit:function(){return o()||a},safari:function(){return g.webkit()},chrome:function(){return o()||l},windows:function(){return o()||f},osx:function(){return o()||c},linux:function(){return o()||d},iphone:function(){return o()||v},mobile:function(){return o()||v||m||p||_},nativeApp:function(){return o()||b},android:function(){return o()||p},ipad:function(){return o()||m}};e.exports=g},function(e,t,n){"use strict";function o(e,t){if(!u.default.canUseDOM||t&&!("addEventListener"in document))return!1;var n="on"+e,o=n in document;if(!o){var i=document.createElement("div");i.setAttribute(n,"return;"),o="function"==typeof i[n]}return!o&&r&&"wheel"===e&&(o=document.implementation.hasFeature("Events.wheel","3.0")),o}var r,i=n(67),u=function(e){return e&&e.__esModule?e:{default:e}}(i);u.default.canUseDOM&&(r=document.implementation&&document.implementation.hasFeature&&!0!==document.implementation.hasFeature("","")),e.exports=o},function(e,t,n){"use strict";function o(e){if(r.hasOwnProperty(e))return r[e];throw new Error('cssVar("'+e+'"): Unexpected class transformation.')}var r={"scrollbar-face-active-color":"#7d7d7d","scrollbar-face-color":"#c2c2c2","scrollbar-face-margin":"4px","scrollbar-face-radius":"6px","scrollbar-size":"15px","scrollbar-size-large":"17px","scrollbar-track-color":"#fff","border-color":"#d3d3d3","fbui-white":"#fff","fbui-desktop-background-light":"#f6f7f8"};o.CSS_VARS=r,e.exports=o},function(e,t,n){function o(e,t,n){return t=i(t),void 0===n?(n=t,t=0):n=i(n),e=u(e),r(e,t,n)}var r=n(208),i=n(209),u=n(59);e.exports=o},function(e,t){function n(e,t,n){return e>=r(t,n)&&e2||Math.abs(this._deltaY)>2)&&(this._stopPropagation&&e.stopPropagation(),i=!0),!0===i&&null===this._dragAnimationId&&(this._dragAnimationId=(0,s.default)(this._didTouchMove))}}},{key:"_didTouchMove",value:function(){this._dragAnimationId=null,this._onTouchScrollCallback(this._deltaX,this._deltaY),this._accumulatedDeltaX+=this._deltaX,this._accumulatedDeltaY+=this._deltaY,this._deltaX=0,this._deltaY=0}},{key:"_track",value:function(){var e=Date.now(),t=e-this._lastFrameTimestamp,n=this._velocityX,o=this._velocityY,r=.8;t<100&&(r*=t/100),0===n&&0===o&&(r=1),this._velocityX=r*(100*this._accumulatedDeltaX/(1+t)),r<1&&(this._velocityX+=(1-r)*n),this._velocityY=r*(100*this._accumulatedDeltaY/(1+t)),r<1&&(this._velocityY+=(1-r)*o),this._accumulatedDeltaX=0,this._accumulatedDeltaY=0,this._lastFrameTimestamp=e}},{key:"_startAutoScroll",value:function(){this._autoScrollTimestamp=Date.now(),(this._deltaX>0||this.deltaY>0)&&this._didTouchMove(),this._track(),this._autoScroll()}},{key:"_autoScroll",value:function(){var e=Date.now()-this._autoScrollTimestamp,t=1.6*Math.exp(-e/325),n=t*this._velocityX,o=t*this._velocityY;(Math.abs(n)<=5||!this._handleScrollX(n,o))&&(n=0),(Math.abs(o)<=5||!this._handleScrollY(o,n))&&(o=0),0===n&&0===o||(this._onTouchScrollCallback(n,o),(0,s.default)(this._autoScroll))}}]),e}();e.exports=c},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t){var n=e.columnGroupProps,o=e.columnProps,r=[],i=[],u=[];(0,l.default)(n,function(e,n){var o={props:e,template:t.groupHeader[n]};e.fixed?r.push(o):e.fixedRight?i.push(o):u.push(o)});var a={cell:[],header:[],footer:[]},s={cell:[],header:[],footer:[]},c={cell:[],header:[],footer:[]};return(0,l.default)(o,function(e,n){var o=c;e.fixed?o=a:e.fixedRight&&(o=s),o.cell.push({props:e,template:t.cell[n]}),o.header.push({props:e,template:t.header[n]}),o.footer.push({props:e,template:t.footer[n]})}),{fixedColumnGroups:r,fixedColumns:a,fixedRightColumnGroups:i,fixedRightColumns:s,scrollableColumnGroups:u,scrollableColumns:c}}Object.defineProperty(t,"__esModule",{value:!0});var i=n(84),u=o(i),a=n(60),l=o(a),s=n(18),c=o(s);t.default=(0,c.default)([function(e){return(0,u.default)(e)},function(e){return e.elementTemplates}],r)},function(e,t){function n(e,t){for(var n=-1,o=null==e?0:e.length;++n1&&void 0!==arguments[1]?arguments[1]:o,n=null,i=null;return function(){return r(t,n,arguments)||(i=e.apply(null,arguments)),n=arguments,i}}function u(e){var t=Array.isArray(e[0])?e[0]:e;if(!t.every(function(e){return"function"==typeof e})){var n=t.map(function(e){return typeof e}).join(", ");throw new Error("Selector creators expect all input-selectors to be functions, instead received the following types: ["+n+"]")}return t}function a(e){for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;o1&&void 0!==arguments[1]?arguments[1]:s;if("object"!=typeof e)throw new Error("createStructuredSelector expects first argument to be an object where each property is a selector, instead received a "+typeof e);var n=Object.keys(e);return t(n.map(function(t){return e[t]}),function(){for(var e=arguments.length,t=Array(e),o=0;o0&&void 0!==arguments[0]?arguments[0]:r(),t=arguments[1];switch(t.type){case f.INITIALIZE:var n=t.props,o=a(e,n);o=u(o);var i=(0,s.getScrollAnchor)(o,n);return o=(0,y.default)(o,i),b.default.initialize(o,n,{});case f.PROP_CHANGE:var c=t.newProps,d=t.oldProps,h=a(e,c);d.rowsCount===c.rowsCount&&d.rowHeight===c.rowHeight&&d.subRowHeight===c.subRowHeight||(h=u(h)),d.rowsCount!==c.rowsCount&&(h.rowBufferSet=new p.default);var v=(0,s.getScrollAnchor)(h,c,d);return(0,S.default)(e,h)&&!v.changed||(h=(0,y.default)(h,v)),h=b.default.initialize(h,c,d),h.scrollX===e.scrollX&&h.scrollY===e.scrollY||(h.scrolling=h.scrolling||!0),h;case f.SCROLL_END:var m=l({},e,{scrolling:!1}),_={firstIndex:e.firstRowIndex,firstOffset:e.firstRowOffset,lastIndex:e.lastIndex};return(0,y.default)(m,_);case f.SCROLL_TO_Y:var g=t.scrollY,w=l({},e,{scrolling:!0}),x=(0,s.scrollTo)(w,g);return(0,y.default)(w,x);case f.COLUMN_RESIZE:var R=t.resizeData;return b.default.resizeColumn(e,R);case f.COLUMN_REORDER_START:var T=t.reorderData;return b.default.reorderColumn(e,T);case f.COLUMN_REORDER_END:return l({},e,{isColumnReordering:!1,columnReorderingData:{}});case f.COLUMN_REORDER_MOVE:var C=t.deltaX;return b.default.reorderColumnMove(e,C);case f.SCROLL_TO_X:var O=t.scrollX;return l({},e,{scrolling:!0,scrollX:O});default:return e}}function u(e){for(var t=e.rowSettings,n=t.rowHeight,o=t.rowsCount,r=t.subRowHeight,i=n+r,u=v.default.uniform(o,i),a=o*i,s=new Array(o),c=0;c=u-o)s=void 0,f=a-1;else{var d=r.greatestLowerBound(t);s=(0,l.default)(d,0,Math.max(a-1,0));var h=r.sumUntil(s);c=h-t}return{firstIndex:s,firstOffset:c,lastIndex:f,changed:!0}}function u(e,t){var n=(0,p.default)(e),o=n.availableHeight,r=e.rowOffsetIntervalTree,i=e.rowSettings,u=e.storedHeights,a=e.scrollY,s=i.rowsCount;if(0===s)return{firstIndex:0,firstOffset:0,lastIndex:void 0,changed:0!==e.firstRowIndex||0!==e.firstRowOffset};t=(0,l.default)(t,0,Math.max(s-1,0)),(0,f.default)(e,t);var c=r.sumUntil(t),d=c+u[t],h=t,v=void 0;if(c=e&&r<=t)return null;var i;e-o>r-t?(i=o,this._smallValues.pop()):(i=r,this._largeValues.pop());var u=this._valueToPositionMap[i];return delete this._valueToPositionMap[i],this._valueToPositionMap[n]=u,this._pushToHeaps(u,n),u}},{key:"_pushToHeaps",value:function(e,t){var n={position:e,value:t};this._smallValues.push(n),this._largeValues.push(n)}},{key:"_cleanHeaps",value:function(){this._cleanHeap(this._smallValues),this._cleanHeap(this._largeValues);var e=Math.min(this._smallValues.size(),this._largeValues.size());Math.max(this._smallValues.size(),this._largeValues.size())>10*e&&this._recreateHeaps()}},{key:"_recreateHeaps",value:function(){for(var e=this._smallValues.size()t.value}}]),e}();e.exports=c},function(e,t,n){"use strict";function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){return e0&&(this._items[0]=t,this._sinkDown(0)),e}}},{key:"push",value:function(e){this._items[this._size++]=e,this._bubbleUp(this._size-1)}},{key:"size",value:function(){return this._size}},{key:"peek",value:function(){if(0!==this._size)return this._items[0]}},{key:"_heapify",value:function(){for(var e=Math.floor((this._size+1)/2);e>=0;e--)this._sinkDown(e)}},{key:"_bubbleUp",value:function(e){for(var t=this._items[e];e>0;){var n=Math.floor((e+1)/2)-1,o=this._items[n];if(this._comparator(o,t))return;this._items[n]=t,this._items[e]=o,e=n}}},{key:"_sinkDown",value:function(e){for(var t=this._items[e];;){var n=2*(e+1)-1,o=2*(e+1),r=-1;if(n=0;--n)t[n]=0;return t},c=function(){function e(t){o(this,e),this._size=t.length,this._half=r(this._size),this._heap=new s(2*this._half);var n;for(n=0;n0;--n)this._heap[n]=this._heap[2*n]+this._heap[2*n+1]}return i(e,[{key:"set",value:function(e,t){(0,a.default)(0<=e&&e=0;--r)o[r]=n;return new e(o)}},{key:"empty",value:function(t){return e.uniform(t,0)}}]),e}();e.exports=c}).call(t,n(5))},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t,n){var o=t.scrollLeft,r=(t.scrollToColumn,e.columnResizingData),u=e.isColumnResizing,a=e.scrollX;void 0===o||n&&o===n.scrollLeft||(a=o),a=i(e,t,n.scrollToColumn,a);var l=(0,v.default)(e),c=l.maxScrollX;return a=(0,b.default)(a,0,c),u=void 0!==t.isColumnResizing?t.isColumnResizing:u,r=u?r:{},s({},e,{columnResizingData:r,isColumnResizing:u,maxScrollX:c,scrollX:a})}function i(e,t,n,o){var r=t.scrollToColumn;if((0,p.default)(r))return o;var i=(0,v.default)(e),u=i.availableScrollWidth,a=i.fixedColumns,l=i.scrollableColumns,s=a.length,c=l.length,f=0===c,d=r===n,h=r=s+c;if(d||h||m||f)return o;for(var b=Math.min(r-s,l.length-1),_=0,y=0;y_?_:o}function u(e,t){var n=t.cellMinWidth,o=t.cellMaxWidth,r=t.cellWidth,i=t.columnKey,u=t.combinedWidth,a=t.clientX,l=t.clientY,c=t.leftOffset;return s({},e,{isColumnResizing:!0,columnResizingData:{left:c+u-r,width:r,minWidth:n,maxWidth:o,initialEvent:{clientX:a,clientY:l,preventDefault:f.default},key:i}})}function a(e,t){var n=t.columnKey,o=t.left,r=t.scrollStart,i=t.width,u=(0,v.default)(e),a=u.fixedColumns,l=a.some(function(e){return e.columnKey===n});return s({},e,{isColumnReordering:!0,columnReorderingData:{cancelReorder:!1,dragDistance:0,isFixed:l,scrollStart:r,columnKey:n,columnWidth:i,originalLeft:o,columnBefore:void 0,columnAfter:void 0}})}function l(e,t){var n=e.columnReorderingData,o=n.isFixed,r=n.originalLeft,i=n.scrollStart,u=e.maxScrollX,a=e.scrollX;if(!o){var l=r-i+t,c=(0,v.default)(e),f=c.availableScrollWidth;t+=a-i,l>f-y?a=Math.min(a+_,u):l<=y&&(a=Math.max(a-_,0))}var d=s({},e.columnReorderingData,{dragDistance:t,columnBefore:void 0,columnAfter:void 0});return s({},e,{scrollX:a,columnReorderingData:d})}var s=Object.assign||function(e){for(var t=1;t=t?e:t)),e}e.exports=n},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t){var n=l({},e),o=i(n,t),r=n.rowSettings,a=n.scrollContentHeight,s=r.rowsCount,f=(0,_.default)(n),d=f.bodyHeight,p=a-d;0===p&&(o.firstViewportIdx>0&&(o=i(n,{firstOffset:0,lastIndex:s-1})),n.firstRowOffset=0),u(n,o,e.scrolling);var h=0;return s>0&&(h=n.rowOffsets[o.firstViewportIdx]-n.firstRowOffset),h=(0,c.default)(h,0,p),l(n,{maxScrollY:p,scrollY:h})}function i(e,t){var n=(0,h.default)(e),o=n.bufferRowCount,r=n.maxAvailableHeight,i=e.rowSettings.rowsCount;if(0===i)return{endBufferIdx:0,endViewportIdx:0,firstBufferIdx:0,firstViewportIdx:0};var u=t.firstIndex,a=t.firstOffset,l=t.lastIndex;(u>=i||l>=i)&&(l=i-1);var s=1,c=u,f=a;void 0!==l&&(s=-1,c=l,f=0);for(var p=c,v=p;p=0&&f=R[b]&&(b+=1,a+=R[b])}return e.firstRowIndex=b,e.endRowIndex=y,e.firstRowOffset=a,{endBufferIdx:g,endViewportIdx:y,firstBufferIdx:_,firstViewportIdx:b}}function u(e,t,n){var o=e.rowBufferSet,r=e.rowOffsetIntervalTree,i=e.storedHeights,u=t.endBufferIdx,l=t.endViewportIdx,s=t.firstBufferIdx,c=t.firstViewportIdx,f=u-s;if(0===f)return e.rowOffsets={},void(e.rows=[]);for(var d=n?c:s,p=n?l:u,h=[],v={},m=r.sumUntil(d),b=d;b=r&&(i=t.replaceFurthestValuePosition(n,o-1,e)),null===i&&(i=t.getNewPositionForValue(e)),i}Object.defineProperty(t,"__esModule",{value:!0});var l=Object.assign||function(e){for(var t=1;t or "),t.push(e))});var n={cell:[],footer:[],groupHeader:[],header:[]},o=[];if(t.length&&t[0].type.__TableColumnGroup__){var u=(0,h.default)(t,r);return(0,c.default)(t,function(e,t){n.groupHeader.push(e.props.header),l.default.Children.forEach(e.props.children,function(e){var u=r(e);u.groupIdx=t,o.push(u),i(n,e)})}),{columnGroupProps:u,columnProps:o,elementTemplates:n,useGroupHeader:!0}}return(0,c.default)(t,function(e){o.push(r(e)),i(n,e)}),{columnGroupProps:[],columnProps:o,elementTemplates:n,useGroupHeader:!1}}Object.defineProperty(t,"__esModule",{value:!0});var a=n(0),l=o(a),s=n(60),c=o(s),f=n(12),d=o(f),p=n(85),h=o(p),v=n(62),m=o(v);t.default=u},function(e,t,n){function o(e,t){return r(e,t,function(t,n){return i(e,n)})}var r=n(235),i=n(82);e.exports=o},function(e,t,n){function o(e,t,n){for(var o=-1,a=t.length,l={};++o0&&n(c)?t>1?o(c,t-1,n,u,a):r(a,c):u||(a[a.length]=c)}return a}var r=n(78),i=n(239);e.exports=o},function(e,t,n){function o(e){return u(e)||i(e)||!!(a&&e&&e[a])}var r=n(13),i=n(49),u=n(1),a=r?r.isConcatSpreadable:void 0;e.exports=o},function(e,t,n){function o(e,t,n){return t=i(void 0===t?e.length-1:t,0),function(){for(var o=arguments,u=-1,a=i(o.length-t,0),l=Array(a);++u0){if(++t>=o)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var o=800,r=16,i=Date.now;e.exports=n},function(e,t,n){"use strict";function o(e){return null==e?void 0===e?l:a:s&&s in Object(e)?Object(i.a)(e):Object(u.a)(e)}var r=n(94),i=n(249),u=n(250),a="[object Null]",l="[object Undefined]",s=r.a?r.a.toStringTag:void 0;t.a=o},function(e,t,n){"use strict";var o=n(248),r="object"==typeof self&&self&&self.Object===Object&&self,i=o.a||r||Function("return this")();t.a=i},function(e,t,n){"use strict";(function(e){var n="object"==typeof e&&e&&e.Object===Object&&e;t.a=n}).call(t,n(5))},function(e,t,n){"use strict";function o(e){var t=u.call(e,l),n=e[l];try{e[l]=void 0;var o=!0}catch(e){}var r=a.call(e);return o&&(t?e[l]=n:delete e[l]),r}var r=n(94),i=Object.prototype,u=i.hasOwnProperty,a=i.toString,l=r.a?r.a.toStringTag:void 0;t.a=o},function(e,t,n){"use strict";function o(e){return i.call(e)}var r=Object.prototype,i=r.toString;t.a=o},function(e,t,n){"use strict";var o=n(252),r=Object(o.a)(Object.getPrototypeOf,Object);t.a=r},function(e,t,n){"use strict";function o(e,t){return function(n){return e(t(n))}}t.a=o},function(e,t,n){"use strict";function o(e){return null!=e&&"object"==typeof e}t.a=o},function(e,t,n){"use strict";(function(e,o){var r,i=n(256);r="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==e?e:o;var u=Object(i.a)(r);t.a=u}).call(t,n(5),n(255)(e))},function(e,t){e.exports=function(e){if(!e.webpackPolyfill){var t=Object.create(e);t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),Object.defineProperty(t,"exports",{enumerable:!0}),t.webpackPolyfill=1}return t}},function(e,t,n){"use strict";function o(e){var t,n=e.Symbol;return"function"==typeof n?n.observable?t=n.observable:(t=n("observable"),n.observable=t):t="@@observable",t}t.a=o},function(e,t,n){"use strict";(function(e){function o(e,t){var n=t&&t.type;return"Given action "+(n&&'"'+n.toString()+'"'||"an action")+', reducer "'+e+'" returned undefined. To ignore an action, you must explicitly return the previous state. If you want this reducer to hold no value, you can return null instead of undefined.'}function r(e,t,n,o){var r=Object.keys(t),i=n&&n.type===a.a.INIT?"preloadedState argument passed to createStore":"previous state received by the reducer";if(0===r.length)return"Store does not have a valid reducer. Make sure the argument passed to combineReducers is an object whose values are reducers.";if(!Object(l.a)(e))return"The "+i+' has unexpected type of "'+{}.toString.call(e).match(/\s([a-z|A-Z]+)/)[1]+'". Expected argument to be an object with the following keys: "'+r.join('", "')+'"';var u=Object.keys(e).filter(function(e){return!t.hasOwnProperty(e)&&!o[e]});return u.forEach(function(e){o[e]=!0}),u.length>0?"Unexpected "+(u.length>1?"keys":"key")+' "'+u.join('", "')+'" found in '+i+'. Expected to find one of the known reducer keys instead: "'+r.join('", "')+'". Unexpected keys will be ignored.':void 0}function i(e){Object.keys(e).forEach(function(t){var n=e[t];if(void 0===n(void 0,{type:a.a.INIT}))throw new Error('Reducer "'+t+"\" returned undefined during initialization. If the state passed to the reducer is undefined, you must explicitly return the initial state. The initial state may not be undefined. If you don't want to set a value for this reducer, you can use null instead of undefined.");if(void 0===n(void 0,{type:"@@redux/PROBE_UNKNOWN_ACTION_"+Math.random().toString(36).substring(7).split("").join(".")}))throw new Error('Reducer "'+t+"\" returned undefined when probed with a random type. Don't try to handle "+a.a.INIT+' or other actions in "redux/*" namespace. They are considered private. Instead, you must return the current state for any unknown actions, unless it is undefined, in which case you must return the initial state, regardless of the action type. The initial state may not be undefined, but can be null.')})}function u(t){for(var n=Object.keys(t),u={},a=0;a0&&void 0!==arguments[0]?arguments[0]:{},n=arguments[1];if(d)throw d;if("production"!==e.env.NODE_ENV){var i=r(t,u,n,f);i&&Object(s.a)(i)}for(var a=!1,l={},p=0;p should never render")}}]),t}(s.default.Component);d.__TableColumn__=!0,d.propTypes={align:f.default.oneOf(["left","center","right"]),fixed:f.default.bool,fixedRight:f.default.bool,header:f.default.oneOfType([f.default.node,f.default.func]),cell:f.default.oneOfType([f.default.node,f.default.func]),footer:f.default.oneOfType([f.default.node,f.default.func]),columnKey:f.default.oneOfType([f.default.string,f.default.number]),width:f.default.number.isRequired,minWidth:f.default.number,maxWidth:f.default.number,flexGrow:f.default.number,isResizable:f.default.bool,isReorderable:f.default.bool,allowCellsRecycling:f.default.bool,pureRendering:f.default.bool},d.defaultProps={allowCellsRecycling:!1,fixed:!1,fixedRight:!1},e.exports=d},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var a=function(){function e(e,t){for(var n=0;n should never render")}}]),t}(s.default.Component);d.__TableColumnGroup__=!0,d.propTypes={align:f.default.oneOf(["left","center","right"]),fixed:f.default.bool,header:f.default.oneOfType([f.default.node,f.default.func])},d.defaultProps={fixed:!1},e.exports=d}])}); \ No newline at end of file diff --git a/package.json b/package.json index 6afb7a8e..07974b86 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "fixed-data-table-2", - "version": "1.0.0-beta.16", + "version": "1.0.0-beta.17", "description": "A React table component designed to allow presenting thousands of rows of data.", "main": "main.js", "peerDependencies": { diff --git a/src/FixedDataTableRoot.js b/src/FixedDataTableRoot.js index f9f77e4c..ec43db3f 100644 --- a/src/FixedDataTableRoot.js +++ b/src/FixedDataTableRoot.js @@ -23,5 +23,5 @@ var FixedDataTableRoot = { Table: FixedDataTableContainer, }; -FixedDataTableRoot.version = '1.0.0-beta.16'; +FixedDataTableRoot.version = '1.0.0-beta.17'; module.exports = FixedDataTableRoot;