diff --git a/dist/fixed-data-table.js b/dist/fixed-data-table.js
index d0fabb4b..604f9981 100644
--- a/dist/fixed-data-table.js
+++ b/dist/fixed-data-table.js
@@ -2109,21 +2109,21 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ function(module, exports, __webpack_require__) {
/* WEBPACK VAR INJECTION */(function(process) {/**
- * Copyright 2013-2014, Facebook, Inc.
+ * Copyright 2013-2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
- * @typechecks
+ * @typechecks static-only
* @providesModule cloneWithProps
*/
- "use strict";
+ 'use strict';
var ReactElement = __webpack_require__(29);
- var ReactPropTransferer = __webpack_require__(35);
+ var ReactPropTransferer = __webpack_require__(36);
var keyOf = __webpack_require__(38);
var warning = __webpack_require__(33);
@@ -2134,10 +2134,10 @@ return /******/ (function(modules) { // webpackBootstrap
* Sometimes you want to change the props of a child passed to you. Usually
* this is to add a CSS class.
*
- * @param {object} child child component you'd like to clone
- * @param {object} props props you'd like to modify. They will be merged
- * as if you used `transferPropsTo()`.
- * @return {object} a clone of child with props merged in.
+ * @param {ReactElement} child child element you'd like to clone
+ * @param {object} props props you'd like to modify. className and style will be
+ * merged automatically.
+ * @return {ReactElement} a clone of child with props merged in.
*/
function cloneWithProps(child, props) {
if ("production" !== process.env.NODE_ENV) {
@@ -2267,7 +2267,7 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ function(module, exports, __webpack_require__) {
/* WEBPACK VAR INJECTION */(function(process) {/**
- * Copyright 2014, Facebook, Inc.
+ * Copyright 2014-2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
@@ -2277,11 +2277,12 @@ return /******/ (function(modules) { // webpackBootstrap
* @providesModule ReactElement
*/
- "use strict";
+ 'use strict';
var ReactContext = __webpack_require__(30);
- var ReactCurrentOwner = __webpack_require__(32);
+ var ReactCurrentOwner = __webpack_require__(35);
+ var assign = __webpack_require__(31);
var warning = __webpack_require__(33);
var RESERVED_PROPS = {
@@ -2312,8 +2313,9 @@ return /******/ (function(modules) { // webpackBootstrap
set: function(value) {
("production" !== process.env.NODE_ENV ? warning(
false,
- 'Don\'t set the ' + key + ' property of the component. ' +
- 'Mutate the existing props object instead.'
+ 'Don\'t set the %s property of the React element. Instead, ' +
+ 'specify the correct value when initially creating the element.',
+ key
) : null);
this._store[key] = value;
}
@@ -2374,7 +2376,21 @@ return /******/ (function(modules) { // webpackBootstrap
// an external backing store so that we can freeze the whole object.
// This can be replaced with a WeakMap once they are implemented in
// commonly used development environments.
- this._store = { validated: false, props: props };
+ this._store = {props: props, originalProps: assign({}, props)};
+
+ // To make comparing ReactElements easier for testing purposes, we make
+ // the validation flag non-enumerable (where possible, which should
+ // include every environment we run tests in), so the test framework
+ // ignores it.
+ try {
+ Object.defineProperty(this._store, 'validated', {
+ configurable: false,
+ enumerable: false,
+ writable: true
+ });
+ } catch (x) {
+ }
+ this._store.validated = false;
// We're not allowed to set props directly on the object so we early
// return and rely on the prototype membrane to forward to the backing
@@ -2409,16 +2425,7 @@ return /******/ (function(modules) { // webpackBootstrap
if (config != null) {
ref = config.ref === undefined ? null : config.ref;
- if ("production" !== process.env.NODE_ENV) {
- ("production" !== process.env.NODE_ENV ? warning(
- config.key !== null,
- 'createElement(...): Encountered component with a `key` of null. In ' +
- 'a future version, this will be treated as equivalent to the string ' +
- '\'null\'; instead, provide an explicit key or use undefined.'
- ) : null);
- }
- // TODO: Change this back to `config.key === undefined`
- key = config.key == null ? null : '' + config.key;
+ key = config.key === undefined ? null : '' + config.key;
// Remaining properties are added to a new props object
for (propName in config) {
if (config.hasOwnProperty(propName) &&
@@ -2467,6 +2474,7 @@ return /******/ (function(modules) { // webpackBootstrap
// easily accessed on elements. E.g. .type === Foo.type.
// This should not be named `constructor` since this may not be the function
// that created the element, and it may not even be a constructor.
+ // Legacy hook TODO: Warn if this is accessed
factory.type = type;
return factory;
};
@@ -2488,6 +2496,60 @@ return /******/ (function(modules) { // webpackBootstrap
return newElement;
};
+ ReactElement.cloneElement = function(element, config, children) {
+ var propName;
+
+ // Original props are copied
+ var props = assign({}, element.props);
+
+ // Reserved names are extracted
+ var key = element.key;
+ var ref = element.ref;
+
+ // Owner will be preserved, unless ref is overridden
+ var owner = element._owner;
+
+ if (config != null) {
+ if (config.ref !== undefined) {
+ // Silently steal the ref from the parent.
+ ref = config.ref;
+ owner = ReactCurrentOwner.current;
+ }
+ if (config.key !== undefined) {
+ key = '' + config.key;
+ }
+ // Remaining properties override existing props
+ for (propName in config) {
+ if (config.hasOwnProperty(propName) &&
+ !RESERVED_PROPS.hasOwnProperty(propName)) {
+ props[propName] = config[propName];
+ }
+ }
+ }
+
+ // Children can be more than one argument, and those are transferred onto
+ // the newly allocated props object.
+ var childrenLength = arguments.length - 2;
+ if (childrenLength === 1) {
+ props.children = children;
+ } else if (childrenLength > 1) {
+ var childArray = Array(childrenLength);
+ for (var i = 0; i < childrenLength; i++) {
+ childArray[i] = arguments[i + 2];
+ }
+ props.children = childArray;
+ }
+
+ return new ReactElement(
+ element.type,
+ key,
+ ref,
+ owner,
+ element._context,
+ props
+ );
+ };
+
/**
* @param {?object} object
* @return {boolean} True if `object` is a valid component.
@@ -2515,8 +2577,8 @@ return /******/ (function(modules) { // webpackBootstrap
/* 30 */
/***/ function(module, exports, __webpack_require__) {
- /**
- * Copyright 2013-2014, Facebook, Inc.
+ /* WEBPACK VAR INJECTION */(function(process) {/**
+ * Copyright 2013-2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
@@ -2526,9 +2588,13 @@ return /******/ (function(modules) { // webpackBootstrap
* @providesModule ReactContext
*/
- "use strict";
+ 'use strict';
var assign = __webpack_require__(31);
+ var emptyObject = __webpack_require__(32);
+ var warning = __webpack_require__(33);
+
+ var didWarn = false;
/**
* Keeps track of the current context.
@@ -2542,7 +2608,7 @@ return /******/ (function(modules) { // webpackBootstrap
* @internal
* @type {object}
*/
- current: {},
+ current: emptyObject,
/**
* Temporarily extends the current context while executing scopedCallback.
@@ -2561,6 +2627,16 @@ return /******/ (function(modules) { // webpackBootstrap
* @return {ReactComponent|array}
*/
withContext: function(newContext, scopedCallback) {
+ if ("production" !== process.env.NODE_ENV) {
+ ("production" !== process.env.NODE_ENV ? warning(
+ didWarn,
+ 'withContext is deprecated and will be removed in a future version. ' +
+ 'Use a wrapper component with getChildContext instead.'
+ ) : null);
+
+ didWarn = true;
+ }
+
var result;
var previousContext = ReactContext.current;
ReactContext.current = assign({}, previousContext, newContext);
@@ -2576,13 +2652,14 @@ return /******/ (function(modules) { // webpackBootstrap
module.exports = ReactContext;
+ /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(28)))
/***/ },
/* 31 */
/***/ function(module, exports, __webpack_require__) {
/**
- * Copyright 2014, Facebook, Inc.
+ * Copyright 2014-2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
@@ -2594,6 +2671,8 @@ return /******/ (function(modules) { // webpackBootstrap
// https://people.mozilla.org/~jorendorff/es6-draft.html#sec-object.assign
+ 'use strict';
+
function assign(target, sources) {
if (target == null) {
throw new TypeError('Object.assign target cannot be null or undefined');
@@ -2623,7 +2702,7 @@ return /******/ (function(modules) { // webpackBootstrap
}
return to;
- };
+ }
module.exports = assign;
@@ -2632,46 +2711,35 @@ return /******/ (function(modules) { // webpackBootstrap
/* 32 */
/***/ function(module, exports, __webpack_require__) {
- /**
- * Copyright 2013-2014, Facebook, Inc.
+ /* WEBPACK VAR INJECTION */(function(process) {/**
+ * Copyright 2013-2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
- * @providesModule ReactCurrentOwner
+ * @providesModule emptyObject
*/
"use strict";
- /**
- * Keeps track of the current owner.
- *
- * The current owner is the component who should own any components that are
- * currently being constructed.
- *
- * The depth indicate how many composite components are above this render level.
- */
- var ReactCurrentOwner = {
+ var emptyObject = {};
- /**
- * @internal
- * @type {ReactComponent}
- */
- current: null
-
- };
+ if ("production" !== process.env.NODE_ENV) {
+ Object.freeze(emptyObject);
+ }
- module.exports = ReactCurrentOwner;
+ module.exports = emptyObject;
+ /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(28)))
/***/ },
/* 33 */
/***/ function(module, exports, __webpack_require__) {
/* WEBPACK VAR INJECTION */(function(process) {/**
- * Copyright 2014, Facebook, Inc.
+ * Copyright 2014-2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
@@ -2703,9 +2771,27 @@ return /******/ (function(modules) { // webpackBootstrap
);
}
+ if (format.length < 10 || /^[s\W]*$/.test(format)) {
+ throw new Error(
+ 'The warning format should be able to uniquely identify this ' +
+ 'warning. Please, use a more descriptive format than: ' + format
+ );
+ }
+
+ if (format.indexOf('Failed Composite propType: ') === 0) {
+ return; // Ignore CompositeComponent proptype check.
+ }
+
if (!condition) {
var argIndex = 0;
- console.warn('Warning: ' + format.replace(/%s/g, function() {return args[argIndex++];}));
+ var message = 'Warning: ' + format.replace(/%s/g, function() {return args[argIndex++];});
+ console.warn(message);
+ try {
+ // --- Welcome to debugging React ---
+ // This error was thrown as a convenience so that you can use this stack
+ // to find the callsite that caused this warning to fire.
+ throw new Error(message);
+ } catch(x) {}
}
};
}
@@ -2719,7 +2805,7 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ function(module, exports, __webpack_require__) {
/**
- * Copyright 2013-2014, Facebook, Inc.
+ * Copyright 2013-2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
@@ -2756,8 +2842,46 @@ return /******/ (function(modules) { // webpackBootstrap
/* 35 */
/***/ function(module, exports, __webpack_require__) {
- /* WEBPACK VAR INJECTION */(function(process) {/**
- * Copyright 2013-2014, Facebook, Inc.
+ /**
+ * Copyright 2013-2015, Facebook, Inc.
+ * All rights reserved.
+ *
+ * This source code is licensed under the BSD-style license found in the
+ * LICENSE file in the root directory of this source tree. An additional grant
+ * of patent rights can be found in the PATENTS file in the same directory.
+ *
+ * @providesModule ReactCurrentOwner
+ */
+
+ 'use strict';
+
+ /**
+ * Keeps track of the current owner.
+ *
+ * The current owner is the component who should own any components that are
+ * currently being constructed.
+ *
+ * The depth indicate how many composite components are above this render level.
+ */
+ var ReactCurrentOwner = {
+
+ /**
+ * @internal
+ * @type {ReactComponent}
+ */
+ current: null
+
+ };
+
+ module.exports = ReactCurrentOwner;
+
+
+/***/ },
+/* 36 */
+/***/ function(module, exports, __webpack_require__) {
+
+ /**
+ * Copyright 2013-2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
@@ -2767,15 +2891,11 @@ return /******/ (function(modules) { // webpackBootstrap
* @providesModule ReactPropTransferer
*/
- "use strict";
+ 'use strict';
var assign = __webpack_require__(31);
var emptyFunction = __webpack_require__(34);
- var invariant = __webpack_require__(36);
var joinClasses = __webpack_require__(37);
- var warning = __webpack_require__(33);
-
- var didWarn = false;
/**
* Creates a transfer strategy that will merge prop values using the supplied
@@ -2854,8 +2974,6 @@ return /******/ (function(modules) { // webpackBootstrap
*/
var ReactPropTransferer = {
- TransferStrategies: TransferStrategies,
-
/**
* Merge two props objects using TransferStrategies.
*
@@ -2865,129 +2983,19 @@ return /******/ (function(modules) { // webpackBootstrap
*/
mergeProps: function(oldProps, newProps) {
return transferInto(assign({}, oldProps), newProps);
- },
-
- /**
- * @lends {ReactPropTransferer.prototype}
- */
- Mixin: {
-
- /**
- * Transfer props from this component to a target component.
- *
- * Props that do not have an explicit transfer strategy will be transferred
- * only if the target component does not already have the prop set.
- *
- * This is usually used to pass down props to a returned root component.
- *
- * @param {ReactElement} element Component receiving the properties.
- * @return {ReactElement} The supplied `component`.
- * @final
- * @protected
- */
- transferPropsTo: function(element) {
- ("production" !== process.env.NODE_ENV ? invariant(
- element._owner === this,
- '%s: You can\'t call transferPropsTo() on a component that you ' +
- 'don\'t own, %s. This usually means you are calling ' +
- 'transferPropsTo() on a component passed in as props or children.',
- this.constructor.displayName,
- typeof element.type === 'string' ?
- element.type :
- element.type.displayName
- ) : invariant(element._owner === this));
-
- if ("production" !== process.env.NODE_ENV) {
- if (!didWarn) {
- didWarn = true;
- ("production" !== process.env.NODE_ENV ? warning(
- false,
- 'transferPropsTo is deprecated. ' +
- 'See http://fb.me/react-transferpropsto for more information.'
- ) : null);
- }
- }
-
- // Because elements are immutable we have to merge into the existing
- // props object rather than clone it.
- transferInto(element.props, this.props);
-
- return element;
- }
-
- }
- };
-
- module.exports = ReactPropTransferer;
-
- /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(28)))
-
-/***/ },
-/* 36 */
-/***/ function(module, exports, __webpack_require__) {
-
- /* WEBPACK VAR INJECTION */(function(process) {/**
- * Copyright 2013-2014, Facebook, Inc.
- * All rights reserved.
- *
- * This source code is licensed under the BSD-style license found in the
- * LICENSE file in the root directory of this source tree. An additional grant
- * of patent rights can be found in the PATENTS file in the same directory.
- *
- * @providesModule invariant
- */
-
- "use strict";
-
- /**
- * Use invariant() to assert state which your program assumes to be true.
- *
- * Provide sprintf-style format (only %s is supported) and arguments
- * to provide information about what broke and what you were
- * expecting.
- *
- * The invariant message will be stripped in production, but the invariant
- * will remain to ensure logic does not differ in production.
- */
-
- var invariant = function(condition, format, a, b, c, d, e, f) {
- if ("production" !== process.env.NODE_ENV) {
- if (format === undefined) {
- throw new Error('invariant requires an error message argument');
- }
}
- if (!condition) {
- var error;
- if (format === undefined) {
- error = new Error(
- 'Minified exception occurred; use the non-minified dev environment ' +
- 'for the full error message and additional helpful warnings.'
- );
- } else {
- var args = [a, b, c, d, e, f];
- var argIndex = 0;
- error = new Error(
- 'Invariant Violation: ' +
- format.replace(/%s/g, function() { return args[argIndex++]; })
- );
- }
-
- error.framesToPop = 1; // we don't care about invariant's own frame
- throw error;
- }
};
- module.exports = invariant;
+ module.exports = ReactPropTransferer;
- /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(28)))
/***/ },
/* 37 */
/***/ function(module, exports, __webpack_require__) {
/**
- * Copyright 2013-2014, Facebook, Inc.
+ * Copyright 2013-2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
@@ -2998,7 +3006,7 @@ return /******/ (function(modules) { // webpackBootstrap
* @typechecks static-only
*/
- "use strict";
+ 'use strict';
/**
* Combines multiple className strings into one.
@@ -3032,7 +3040,7 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ function(module, exports, __webpack_require__) {
/**
- * Copyright 2013-2014, Facebook, Inc.
+ * Copyright 2013-2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
@@ -3091,7 +3099,7 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ function(module, exports, __webpack_require__) {
/**
- * Copyright 2013-2014, Facebook, Inc.
+ * Copyright 2013-2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
@@ -3101,7 +3109,7 @@ return /******/ (function(modules) { // webpackBootstrap
* @providesModule ReactComponentWithPureRenderMixin
*/
- "use strict";
+ 'use strict';
var shallowEqual = __webpack_require__(41);
@@ -3144,7 +3152,7 @@ return /******/ (function(modules) { // webpackBootstrap
/***/ function(module, exports, __webpack_require__) {
/**
- * Copyright 2013-2014, Facebook, Inc.
+ * Copyright 2013-2015, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
@@ -3154,7 +3162,7 @@ return /******/ (function(modules) { // webpackBootstrap
* @providesModule shallowEqual
*/
- "use strict";
+ 'use strict';
/**
* Performs equality by iterating through keys on an object and returning
diff --git a/dist/fixed-data-table.min.js b/dist/fixed-data-table.min.js
index 5542f305..d522120d 100644
--- a/dist/fixed-data-table.min.js
+++ b/dist/fixed-data-table.min.js
@@ -9,6 +9,6 @@
* 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")):"function"==typeof define&&define.amd?define(["react"],t):"object"==typeof exports?exports.FixedDataTable=t(require("react")):e.FixedDataTable=t(e.React)}(this,function(e){return function(e){function t(i){if(o[i])return o[i].exports;var n=o[i]={exports:{},id:i,loaded:!1};return e[i].call(n.exports,n,n.exports,t),n.loaded=!0,n.exports}var o={};return t.m=e,t.c=o,t.p="",t(0)}([function(e,t,o){o(1),o(5),o(7),o(9),o(11),o(13),e.exports=o(15)},function(e,t,o){},,,,function(e,t,o){},,function(e,t,o){},,function(e,t,o){},,function(e,t,o){},,function(e,t,o){},,function(e,t,o){"use strict";var i=o(16),n=o(25),r=o(24),s={Column:n,ColumnGroup:r,Table:i};s.version="0.3.0",e.exports=s},function(e,t,o){"use strict";var i=Object.assign||function(e){for(var t=1;te&&this.state.scrollX>0||e>=0&&this.state.scrollXe&&this.state.scrollY>0||e>=0&&this.state.scrollYi?i:this.state.height>i&&this.props.ownerHeight?Math.max(i,this.props.ownerHeight):this.state.height+this.state.maxScrollY,e!==this._contentHeight&&this.props.onContentHeightChange&&this.props.onContentHeightChange(e),this._contentHeight=e},componentDidMount:function(){this._reportContentHeight()},componentWillReceiveProps:function(e){var t=e.scrollToRow;void 0!==t&&null!==t&&(this._rowToScrollTo=t);var o=e.scrollToColumn;void 0!==o&&null!==o&&(this._columnToScrollTo=o);var i=e.overflowX,n=e.overflowY;(i!==this.props.overflowX||n!==this.props.overflowY)&&(this._wheelHandler=new l(this._onWheel,"hidden"!==i,"hidden"!==n)),this.setState(this._calculateState(e,this.state))},componentDidUpdate:function(){this._reportContentHeight()},render:function(){var e,t=this.state,o=this.props;t.useGroupHeader&&(e=s.createElement(f,{key:"group_header",className:v("public/fixedDataTable/header"),data:t.groupHeaderData,width:t.width,height:t.groupHeaderHeight,index:0,zIndex:1,offsetTop:0,scrollLeft:t.scrollX,fixedColumns:t.groupHeaderFixedColumns,scrollableColumns:t.groupHeaderScrollableColumns}));var i=this.state.maxScrollY,n=t.maxScrollX>0&&"hidden"!==t.overflowX,r=i>0&&"hidden"!==t.overflowY,a=n?u.SIZE:0,l=t.height-a-2*H,h=t.useGroupHeader?t.groupHeaderHeight:0,p=h+t.headerHeight,d=0,m=null!=o.maxHeight?p+t.bodyHeight:l-o.footerHeight,g=m+t.footerHeight;void 0!==o.ownerHeight&&o.ownerHeightt.ownerHeight||t.scrollY or "),o.push(e))});var n=!1;o.length&&o[0].type.__TableColumnGroup__&&(n=!0);var r,s,a=t&&t.firstRowIndex||0,l=t&&t.firstRowOffset||0;r=t&&"hidden"!==e.overflowX?t.scrollX:e.scrollLeft,t&&"hidden"!==e.overflowY?s=t.scrollY:(f=this._scrollHelper.scrollTo(e.scrollTop),a=f.index,l=f.offset,s=f.position),void 0!==this._rowToScrollTo&&(f=this._scrollHelper.scrollRowIntoView(this._rowToScrollTo),a=f.index,l=f.offset,s=f.position,delete this._rowToScrollTo);var h=n?e.groupHeaderHeight:0;if(t&&e.rowsCount!==t.rowsCount){var c=e.height-e.headerHeight-e.footerHeight-h;this._scrollHelper=new p(e.rowsCount,e.rowHeight,c,e.rowHeightGetter);var f=this._scrollHelper.scrollToRow(a,l);a=f.index,l=f.offset,s=f.position}else t&&e.rowHeightGetter!==t.rowHeightGetter&&this._scrollHelper.setRowHeightGetter(e.rowHeightGetter);var m;m=e.isColumnResizing?t&&t.columnResizingData:T;var v,g;if(n){var _=d.adjustColumnGroupWidths(o,e.width);v=_.columns,g=_.columnGroups}else v=d.adjustColumnWidths(o,e.width);var y=this._populateColumnsAndColumnData(v,g,t);if(void 0!==this._columnToScrollTo){var C=y.bodyFixedColumns.length;if(this._columnToScrollTo>=C){var R,D,S=0;for(R=0;RR;++R)D=y.bodyScrollableColumns[R],M+=D.props.width;var k=e.width-S,O=y.bodyScrollableColumns[this._columnToScrollTo-C].props.width,z=M+O-k;z>r&&(r=z),r>M&&(r=M)}delete this._columnToScrollTo}var N=void 0===e.height,P=N?e.maxHeight:e.height,I=e.footerHeight+e.headerHeight+h+2*H,F=P-I,A=this._scrollHelper.getContentHeight(),W=A+I,G=d.getTotalWidth(v),V=G>e.width&&"hidden"!==e.overflowX;V&&(F-=u.SIZE,W+=u.SIZE,I+=u.SIZE);var L=Math.max(0,G-e.width),j=Math.max(0,A-F);r=Math.min(r,L),s=Math.min(s,j),j||(N&&(P=W),F=W-I),this._scrollHelper.setViewportHeight(F);var q=i({isColumnResizing:t&&t.isColumnResizing},y,e,{columns:v,columnGroups:g,columnResizingData:m,firstRowIndex:a,firstRowOffset:l,horizontalScrollbarVisible:V,maxScrollX:L,maxScrollY:j,reservedHeight:I,scrollContentHeight:A,scrollX:r,scrollY:s,bodyHeight:F,height:P,groupHeaderHeight:h,useGroupHeader:n});return t&&(t.headData&&q.headData&&b(t.headData,q.headData)&&(q.headData=t.headData),t.groupHeaderData&&q.groupHeaderData&&b(t.groupHeaderData,q.groupHeaderData)&&(q.groupHeaderData=t.groupHeaderData)),q},_createGroupHeaderColumns:function(e){for(var t=[],o=0;oMath.abs(e)&&"hidden"!==this.props.overflowY){var i=this._scrollHelper.scrollBy(Math.round(t)),n=Math.max(0,i.contentHeight-this.state.bodyHeight);this.setState({firstRowIndex:i.index,firstRowOffset:i.offset,scrollY:i.position,scrollContentHeight:i.contentHeight,maxScrollY:n})}else e&&"hidden"!==this.props.overflowX&&(o+=e,o=0>o?0:o,o=o>this.state.maxScrollX?this.state.maxScrollX:o,this.setState({scrollX:o}));this._didScrollStop()}},_onHorizontalScroll:function(e){this.isMounted()&&e!==this.state.scrollX&&(this.setState({scrollX:e}),this._didScrollStop())},_onVerticalScroll:function(e){if(this.isMounted()&&e!==this.state.scrollY){var t=this._scrollHelper.scrollTo(Math.round(e));this.setState({firstRowIndex:t.index,firstRowOffset:t.offset,scrollY:t.position,scrollContentHeight:t.contentHeight}),this._didScrollStop()}},_didScrollStop:function(){this.isMounted()&&this.props.onScrollEnd&&this.props.onScrollEnd(this.state.scrollX,this.state.scrollY)}}),S=s.createClass({displayName:"HorizontalScrollbar",mixins:[a],propTypes:{contentSize:C.number.isRequired,offset:C.number.isRequired,onScroll:C.func.isRequired,position:C.number.isRequired,size:C.number.isRequired},render:function(){var e={height:u.SIZE,width:this.props.size},t={height:u.SIZE,position:"absolute",overflow:"hidden",width:this.props.size};return y(t,0,this.props.offset),s.createElement("div",{className:v("fixedDataTable/horizontalScrollbar"),style:e},s.createElement("div",{style:t},s.createElement(u,i({},this.props,{isOpaque:!0,orientation:"horizontal",offset:void 0}))))}});e.exports=D},function(e,t,o){"use strict";function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var n=function(){function e(e,t){for(var o=0;oa;++a)this._storedHeights[a]=o;this._rowCount=t,this._position=0,this._contentHeight=t*o,this._defaultRowHeight=o,this._rowHeightGetter=s?s:function(){return o},this._viewportHeight=n,this.scrollRowIntoView=this.scrollRowIntoView.bind(this),this.setViewportHeight=this.setViewportHeight.bind(this),this.scrollBy=this.scrollBy.bind(this),this.scrollTo=this.scrollTo.bind(this),this.scrollToRow=this.scrollToRow.bind(this),this.setRowHeightGetter=this.setRowHeightGetter.bind(this),this.getContentHeight=this.getContentHeight.bind(this),this.getRowPosition=this.getRowPosition.bind(this),this._updateHeightsInViewport(0,0)}return n(e,[{key:"setRowHeightGetter",value:function(e){this._rowHeightGetter=e}},{key:"setViewportHeight",value:function(e){this._viewportHeight=e}},{key:"getContentHeight",value:function(){return this._contentHeight}},{key:"_updateHeightsInViewport",value:function(e,t){for(var o=t,i=e;o<=this._viewportHeight&&i=0&&t>=e-a;){var o=this._updateRowHeight(t);this._position+=o,t--}}},{key:"_updateRowHeight",value:function(e){if(0>e||e>=this._rowCount)return 0;var t=this._rowHeightGetter(e);if(t!==this._storedHeights[e]){var o=t-this._storedHeights[e];return this._rowOffsets.set(e,t),this._storedHeights[e]=t,this._contentHeight+=o,o}return 0}},{key:"getRowPosition",value:function(e){return this._updateRowHeight(e),this._rowOffsets.get(e).value-this._rowHeightGetter(e)}},{key:"scrollBy",value:function(e){var t=this._rowOffsets.upperBound(this._position),o=t.value-this._storedHeights[t.index],i=t.index,n=this._position,r=this._updateRowHeight(i);0!==o&&(n+=r);var a=this._storedHeights[i]-(n-o);if(e>=0)for(;e>0&&ie?(n+=e,e=0):(e-=a,n+=a,i++),ie){e=-e;for(var l=this._storedHeights[i]-a;e>0&&i>=0;)if(l>e?(n-=e,e=0):(n-=l,e-=l,i--),i>=0){var u=this._updateRowHeight(i);l=this._storedHeights[i],n+=u}}var h=this._contentHeight-this._viewportHeight;n=s(0,n,h),this._position=n;var c=this._rowOffsets.upperBound(n),f=c.index;o=c.value-this._rowHeightGetter(f);var p=o-n;return this._updateHeightsInViewport(f,p),this._updateHeightsAboveViewport(f),{index:f,offset:p,position:this._position,contentHeight:this._contentHeight}}},{key:"_getRowAtEndPosition",value:function(e){this._updateRowHeight(e);for(var t=e,o=this._storedHeights[t];o=0;)t--,t>=0&&(this._updateRowHeight(t),o+=this._storedHeights[t]);var i=this._rowOffsets.get(e).value-this._viewportHeight;return 0>i&&(i=0),i}},{key:"scrollTo",value:function(e){if(0>=e)return this._position=0,this._updateHeightsInViewport(0,0),{index:0,offset:0,position:this._position,contentHeight:this._contentHeight};if(e>=this._contentHeight-this._viewportHeight){var t=this._rowCount-1;e=this._getRowAtEndPosition(t)}this._position=e;var o=this._rowOffsets.upperBound(e),i=Math.max(o.index,0),n=o.value-this._rowHeightGetter(i),r=n-e;return this._updateHeightsInViewport(i,r),this._updateHeightsAboveViewport(i),{index:i,offset:r,position:this._position,contentHeight:this._contentHeight}}},{key:"scrollToRow",value:function(e,t){e=s(0,e,this._rowCount-1),t=s(-this._storedHeights[e],t,0);var o=this._rowOffsets.get(e);return this.scrollTo(o.value-this._storedHeights[e]-t)}},{key:"scrollRowIntoView",value:function(e){e=s(0,e,this._rowCount-1);var t=this._rowOffsets.get(e).value,o=t-this._storedHeights[e];if(othis._position+this._viewportHeight){var i=this._getRowAtEndPosition(e);return this.scrollTo(i)}return this.scrollTo(this._position)}}]),e}();e.exports=l},function(e,t,o){(function(t){"use strict";function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=function(){function e(e,t){for(var o=0;ot;)t*=2;return t}},{key:"_initArray",value:function(e){for(var t=[];e>0;)e--,t[e]=0;return t}},{key:"_initTables",value:function(e){var t,o=this._internalLeafCount,i=this._internalLeafCount+this._leafCount-1;for(t=o;i>=t;++t)this._value[t]=e;var n=this._internalLeafCount-1;for(t=n;t>0;--t)this._value[t]=this._value[2*t]+this._value[2*t+1]}},{key:"set",value:function(e,t){var o=e+this._internalLeafCount;for(this._value[o]=t,o=Math.floor(o/2);0!==o;)this._value[o]=this._value[2*o]+this._value[2*o+1],o=Math.floor(o/2)}},{key:"get",value:function(e){e=Math.min(e,this._leafCount);for(var t=e+this._internalLeafCount,o=this._value[t];t>1;)t%2===1&&(o=this._value[t-1]+o),t=Math.floor(t/2);return{index:e,value:o}}},{key:"upperBound",value:function(e){var t=this._upperBoundImpl(1,0,this._internalLeafCount-1,e);return t.index>this._leafCount-1&&(t.index=this._leafCount-1),t}},{key:"lowerBound",value:function(e){var t=this.upperBound(e);if(t.value>e&&t.index>0){var o=t.value-this._value[this._internalLeafCount+t.index];o===e&&(t.value=o,t.index--)}return t}},{key:"_upperBoundImpl",value:function(e,t,o,i){if(t===o)return{index:e-this._internalLeafCount,value:this._value[e]};var n=Math.floor((t+o+1)/2);if(it?e:t>o?o:t}e.exports=i},function(e,t,o){"use strict";function i(e){return null===e||void 0===e?"":String(e)}function n(e,t){a.Children.forEach(e,function(e){e.type===l?n(e.props.children,t):e.type===u&&t(e)})}function r(e,t){var o=[];return a.Children.forEach(e,function(e){var i=e;if(e.type===l){var r=!1,s=[];n(e.props.children,function(e){var o=t(e);o!==e&&(r=!0),s.push(o)}),r&&(i=h(e,{key:e.key,children:s}))}else e.type===u&&(i=t(e));o.push(i)}),o}var s=o(21),a=o(22),l=o(24),u=o(25),h=o(26),c=s.isRTL()?-1:1,f=5,p={DIR_SIGN:c,CELL_VISIBILITY_TOLERANCE:f,renderToString:i,forEachColumn:n,mapColumns:r};e.exports=p},function(e,t,o){"use strict";var i={isRTL:function(){return!1},getDirection:function(){return"LTR"}};e.exports=i},function(e,t,o){"use strict";e.exports=o(23)},function(t,o,i){t.exports=e},function(e,t,o){"use strict";var i=o(22),n=i.PropTypes,r=i.createClass({displayName:"FixedDataTableColumnGroup",statics:{__TableColumnGroup__:!0},propTypes:{align:n.oneOf(["left","center","right"]),fixed:n.bool,columnGroupData:n.object,label:n.string,groupHeaderRenderer:n.func},getDefaultProps:function(){return{fixed:!1}},render:function(){throw new Error("Component should never render")}});e.exports=r},function(e,t,o){"use strict";var i=o(22),n=i.PropTypes,r=i.createClass({displayName:"FixedDataTableColumn",statics:{__TableColumn__:!0},propTypes:{align:n.oneOf(["left","center","right"]),cellClassName:n.string,cellRenderer:n.func,cellDataGetter:n.func,dataKey:n.oneOfType([n.string,n.number]).isRequired,fixed:n.bool,headerRenderer:n.func,footerRenderer:n.func,columnData:n.object,label:n.string,width:n.number.isRequired,minWidth:n.number,maxWidth:n.number,flexGrow:n.number,isResizable:n.bool,allowCellsRecycling:n.bool},getDefaultProps:function(){return{allowCellsRecycling:!1,fixed:!1}},render:function(){throw new Error("Component should never render")}});e.exports=r},function(e,t,o){"use strict";e.exports=o(27)},function(e,t,o){(function(t){"use strict";function i(e,o){"production"!==t.env.NODE_ENV&&("production"!==t.env.NODE_ENV?a(!e.ref,"You are calling cloneWithProps() on a child with a ref. This is dangerous because you're creating a new child which will not be added as a ref to its parent."):null);var i=r.mergeProps(o,e.props);return!i.hasOwnProperty(l)&&e.props.hasOwnProperty(l)&&(i.children=e.props.children),n.createElement(e.type,i)}var n=o(29),r=o(35),s=o(38),a=o(33),l=s({children:null});e.exports=i}).call(t,o(28))},function(e,t,o){function i(){h=!1,a.length?u=a.concat(u):c=-1,u.length&&n()}function n(){if(!h){var e=setTimeout(i);h=!0;for(var t=u.length;t;){for(a=u,u=[];++c1)for(var o=1;o1){for(var d=Array(p),m=0;p>m;m++)d[m]=arguments[m+2];u.children=d}if(e&&e.defaultProps){var v=e.defaultProps;for(n in v)"undefined"==typeof u[n]&&(u[n]=v[n])}return new h(e,c,f,s.current,r.current,u)},h.createFactory=function(e){var t=h.createElement.bind(null,e);return t.type=e,t},h.cloneAndReplaceProps=function(e,o){var i=new h(e.type,e.key,e.ref,e._owner,e._context,o);return"production"!==t.env.NODE_ENV&&(i._store.validated=e._store.validated),i},h.isValidElement=function(e){var t=!(!e||!e._isReactElement);return t},e.exports=h}).call(t,o(28))},function(e,t,o){"use strict";var i=o(31),n={current:{},withContext:function(e,t){var o,r=n.current;n.current=i({},r,e);try{o=t()}finally{n.current=r}return o}};e.exports=n},function(e,t,o){function i(e,t){if(null==e)throw new TypeError("Object.assign target cannot be null or undefined");for(var o=Object(e),i=Object.prototype.hasOwnProperty,n=1;ni;i++)o.push(arguments[i]);if(void 0===t)throw new Error("`warning(condition, format, ...args)` requires a warning message argument");if(!e){var r=0;console.warn("Warning: "+t.replace(/%s/g,function(){return o[r++]}))}}),e.exports=n}).call(t,o(28))},function(e,t,o){function i(e){return function(){return e}}function n(){}n.thatReturns=i,n.thatReturnsFalse=i(!1),n.thatReturnsTrue=i(!0),n.thatReturnsNull=i(null),n.thatReturnsThis=function(){return this},n.thatReturnsArgument=function(e){return e},e.exports=n},function(e,t,o){(function(t){"use strict";function i(e){return function(t,o,i){t.hasOwnProperty(o)?t[o]=e(t[o],i):t[o]=i}}function n(e,t){for(var o in t)if(t.hasOwnProperty(o)){var i=f[o];i&&f.hasOwnProperty(o)?i(e,o,t[o]):e.hasOwnProperty(o)||(e[o]=t[o])}return e}var r=o(31),s=o(34),a=o(36),l=o(37),u=o(33),h=!1,c=i(function(e,t){return r({},t,e)}),f={children:s,className:i(l),style:c},p={TransferStrategies:f,mergeProps:function(e,t){return n(r({},e),t)},Mixin:{transferPropsTo:function(e){return"production"!==t.env.NODE_ENV?a(e._owner===this,"%s: You can't call transferPropsTo() on a component that you don't own, %s. This usually means you are calling transferPropsTo() on a component passed in as props or children.",this.constructor.displayName,"string"==typeof e.type?e.type:e.type.displayName):a(e._owner===this),"production"!==t.env.NODE_ENV&&(h||(h=!0,"production"!==t.env.NODE_ENV?u(!1,"transferPropsTo is deprecated. See http://fb.me/react-transferpropsto for more information."):null)),n(e.props,this.props),e}}};e.exports=p}).call(t,o(28))},function(e,t,o){(function(t){"use strict";var o=function(e,o,i,n,r,s,a,l){if("production"!==t.env.NODE_ENV&&void 0===o)throw new Error("invariant requires an error message argument");if(!e){var u;if(void 0===o)u=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var h=[i,n,r,s,a,l],c=0;u=new Error("Invariant Violation: "+o.replace(/%s/g,function(){return h[c++]}))}throw u.framesToPop=1,u}};e.exports=o}).call(t,o(28))},function(e,t,o){"use strict";function i(e){e||(e="");var t,o=arguments.length;if(o>1)for(var i=1;o>i;i++)t=arguments[i],t&&(e=(e?e+" ":"")+t);return e}e.exports=i},function(e,t,o){var i=function(e){var t;for(t in e)if(e.hasOwnProperty(t))return t;return null};e.exports=i},function(e,t,o){"use strict";e.exports=o(40)},function(e,t,o){"use strict";var i=o(41),n={shouldComponentUpdate:function(e,t){return!i(this.props,e)||!i(this.state,t)}};e.exports=n},function(e,t,o){"use strict";function i(e,t){if(e===t)return!0;var o;for(o in e)if(e.hasOwnProperty(o)&&(!t.hasOwnProperty(o)||e[o]!==t[o]))return!1;for(o in t)if(t.hasOwnProperty(o)&&!e.hasOwnProperty(o))return!1;return!0}e.exports=i},function(e,t,o){"use strict";function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var n=function(){function e(e,t){for(var o=0;oi?-1:1),n&&!o&&(o=1>n?-1:1),{spinX:t,spinY:o,pixelX:i,pixelY:n}}var n=o(45),r=o(46),s=10,a=40,l=800;i.getEventType=function(){return n.firefox()?"DOMMouseScroll":r("wheel")?"wheel":"mousewheel"},e.exports=i},function(e,t,o){"use strict";function i(){if(!w){w=!0;var e=navigator.userAgent,t=/(?:MSIE.(\d+\.\d+))|(?:(?:Firefox|GranParadiso|Iceweasel).(\d+\.\d+))|(?:Opera(?:.+Version.|.)(\d+\.\d+))|(?:AppleWebKit.(\d+(?:\.\d+)?))|(?:Trident\/\d+\.\d+.*rv:(\d+\.\d+))/.exec(e),o=/(Mac OS X)|(Windows)|(Linux)/.exec(e);
-if(m=/\b(iPhone|iP[ao]d)/.exec(e),v=/\b(iP[ao]d)/.exec(e),p=/Android/i.exec(e),g=/FBAN\/\w+;/i.exec(e),_=/Mobile/i.exec(e),d=!!/Win64/.exec(e),t){n=t[1]?parseFloat(t[1]):t[5]?parseFloat(t[5]):NaN,n&&document&&document.documentMode&&(n=document.documentMode);var i=/(?:Trident\/(\d+.\d+))/.exec(e);u=i?parseFloat(i[1])+4:n,r=t[2]?parseFloat(t[2]):NaN,s=t[3]?parseFloat(t[3]):NaN,a=t[4]?parseFloat(t[4]):NaN,a?(t=/(?:Chrome\/(\d+\.\d+))/.exec(e),l=t&&t[1]?parseFloat(t[1]):NaN):l=NaN}else n=r=s=l=a=NaN;if(o){if(o[1]){var b=/(?:Mac OS X (\d+(?:[._]\d+)?))/.exec(e);h=b?parseFloat(b[1].replace("_",".")):!0}else h=!1;c=!!o[2],f=!!o[3]}else h=c=f=!1}}var n,r,s,a,l,u,h,c,f,p,d,m,v,g,_,w=!1,b={ie:function(){return i()||n},ieCompatibilityMode:function(){return i()||u>n},ie64:function(){return b.ie()&&d},firefox:function(){return i()||r},opera:function(){return i()||s},webkit:function(){return i()||a},safari:function(){return b.webkit()},chrome:function(){return i()||l},windows:function(){return i()||c},osx:function(){return i()||h},linux:function(){return i()||f},iphone:function(){return i()||m},mobile:function(){return i()||m||v||p||_},nativeApp:function(){return i()||g},android:function(){return i()||p},ipad:function(){return i()||v}};e.exports=b},function(e,t,o){"use strict";function i(e,t){if(!r.canUseDOM||t&&!("addEventListener"in document))return!1;var o="on"+e,i=o in document;if(!i){var s=document.createElement("div");s.setAttribute(o,"return;"),i="function"==typeof s[o]}return!i&&n&&"wheel"===e&&(i=document.implementation.hasFeature("Events.wheel","3.0")),i}var n,r=o(47);r.canUseDOM&&(n=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0),e.exports=i},function(e,t,o){"use strict";var i=!("undefined"==typeof window||!window.document||!window.document.createElement),n={canUseDOM:i,canUseWorkers:"undefined"!=typeof Worker,canUseEventListeners:i&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:i&&!!window.screen,isInWorker:!i};e.exports=n},function(e,t,o){(function(t){"use strict";var i=o(43),n=o(49),r=0,s=n||function(e){var o=Date.now(),i=Math.max(0,16-(o-r));return r=o+i,t.setTimeout(function(){e(Date.now())},i)};s(i),e.exports=s}).call(t,function(){return this}())},function(e,t,o){(function(t){"use strict";var o=t.requestAnimationFrame||t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.oRequestAnimationFrame||t.msRequestAnimationFrame;e.exports=o}).call(t,function(){return this}())},function(e,t,o){"use strict";var i=o(51),n=o(54),r=o(22),s=o(39),a=o(42),l=o(55),u=o(56),h=o(43),c=o(57),f=r.PropTypes,p={position:0,scrollable:!1},d=parseInt(l("scrollbar-face-margin"),10),m=2*d,v=30,g=40,_=null,w=r.createClass({displayName:"Scrollbar",mixins:[s],propTypes:{contentSize:f.number.isRequired,defaultPosition:f.number,isOpaque:f.bool,orientation:f.oneOf(["vertical","horizontal"]),onScroll:f.func,position:f.number,size:f.number.isRequired,trackColor:f.oneOf(["gray"]),zIndex:f.number},getInitialState:function(){var e=this.props;return this._calculateState(e.position||e.defaultPosition||0,e.size,e.contentSize,e.orientation)},componentWillReceiveProps:function(e){var t=e.position;void 0===t?this._setNextState(this._calculateState(this.state.position,e.size,e.contentSize,e.orientation)):this._setNextState(this._calculateState(t,e.size,e.contentSize,e.orientation),e)},getDefaultProps:function(){return{defaultPosition:0,isOpaque:!1,onScroll:h,orientation:"vertical",zIndex:99}},render:function(){if(!this.state.scrollable)return null;var e,t,o=this.props.size,i=this.state.isHorizontal,n=!i,s=this.state.focused||this.state.isDragging,a=this.state.faceSize,h=this.props.isOpaque,f=u({"public/Scrollbar/main":!0,"public/Scrollbar/mainHorizontal":i,"public/Scrollbar/mainVertical":n,"Scrollbar/mainActive":s,"Scrollbar/mainOpaque":h}),p=u({"Scrollbar/face":!0,"Scrollbar/faceHorizontal":i,"Scrollbar/faceVertical":n,"Scrollbar/faceActive":s}),v=this.state.position*this.state.scale+d;return i?(e={width:o},t={width:a-m},c(t,v,0)):(e={height:o},t={height:a-m},c(t,0,v)),e.zIndex=this.props.zIndex,"gray"===this.props.trackColor&&(e.backgroundColor=l("fbui-desktop-background-light")),r.createElement("div",{onFocus:this._onFocus,onBlur:this._onBlur,onKeyDown:this._onKeyDown,onMouseDown:this._onMouseDown,onWheel:this._wheelHandler.onWheel,className:f,style:e,tabIndex:0},r.createElement("div",{ref:"face",className:p,style:t}))},componentWillMount:function(){var e="horizontal"===this.props.orientation,t=e?this._onWheelX:this._onWheelY;this._wheelHandler=new a(t,this._shouldHandleX,this._shouldHandleY)},componentDidMount:function(){this._mouseMoveTracker=new i(this._onMouseMove,this._onMouseMoveEnd,document.documentElement),void 0!==this.props.position&&this.state.position!==this.props.position&&this._didScroll()},componentWillUnmount:function(){this._nextState=null,this._mouseMoveTracker.releaseMouseMoves(),_===this&&(_=null),delete this._mouseMoveTracker},scrollBy:function(e){this._onWheel(e)},_shouldHandleX:function(e){return"horizontal"===this.props.orientation?this._shouldHandleChange(e):!1},_shouldHandleY:function(e){return"horizontal"!==this.props.orientation?this._shouldHandleChange(e):!1},_shouldHandleChange:function(e){var t=this._calculateState(this.state.position+e,this.props.size,this.props.contentSize,this.props.orientation);return t.position!==this.state.position},_calculateState:function(e,t,o,i){if(1>t||t>=o)return p;var n=""+e+"_"+t+"_"+o+"_"+i;if(this._stateKey===n)return this._stateForKey;var r="horizontal"===i,s=t/o,a=Math.round(t*s);v>a&&(s=(t-v)/(o-v),a=v);var l=!0,u=o-t;0>e?e=0:e>u&&(e=u);var h=this._mouseMoveTracker?this._mouseMoveTracker.isDragging():!1;e=Math.round(e),a=Math.round(a);var c={faceSize:a,isDragging:h,isHorizontal:r,position:e,scale:s,scrollable:l};return this._stateKey=n,this._stateForKey=c,c},_onWheelY:function(e,t){this._onWheel(t)},_onWheelX:function(e,t){this._onWheel(e)},_onWheel:function(e){var t=this.props;this._setNextState(this._calculateState(this.state.position+e,t.size,t.contentSize,t.orientation))},_onMouseDown:function(e){var t;if(e.target!==r.findDOMNode(this.refs.face)){var o=e.nativeEvent,i=this.state.isHorizontal?o.offsetX||o.layerX:o.offsetY||o.layerY,n=this.props;i/=this.state.scale,t=this._calculateState(i-.5*this.state.faceSize/this.state.scale,n.size,n.contentSize,n.orientation)}else t={};t.focused=!0,this._setNextState(t),this._mouseMoveTracker.captureMouseMoves(e),r.findDOMNode(this).focus()},_onMouseMove:function(e,t){var o=this.props,i=this.state.isHorizontal?e:t;i/=this.state.scale,this._setNextState(this._calculateState(this.state.position+i,o.size,o.contentSize,o.orientation))},_onMouseMoveEnd:function(){this._nextState=null,this._mouseMoveTracker.releaseMouseMoves(),this.setState({isDragging:!1})},_onKeyDown:function(e){var t=e.keyCode;if(t!==n.TAB){var o=g,i=0;if(this.state.isHorizontal)switch(t){case n.HOME:i=-1,o=this.props.contentSize;break;case n.LEFT:i=-1;break;case n.RIGHT:i=1;break;default:return}if(!this.state.isHorizontal)switch(t){case n.SPACE:i=e.shiftKey?-1:1;break;case n.HOME:i=-1,o=this.props.contentSize;break;case n.UP:i=-1;break;case n.DOWN:i=1;break;case n.PAGE_UP:i=-1,o=this.props.size;break;case n.PAGE_DOWN:i=1,o=this.props.size;break;default:return}e.preventDefault();var r=this.props;this._setNextState(this._calculateState(this.state.position+o*i,r.size,r.contentSize,r.orientation))}},_onFocus:function(){this.setState({focused:!0})},_onBlur:function(){this.setState({focused:!1})},_blur:function(){if(this.isMounted())try{this._onBlur(),r.findDOMNode(this).blur()}catch(e){}},_setNextState:function(e,t){t=t||this.props;var o=t.position,i=this.state.position!==e.position;if(void 0===o){var n=i?this._didScroll:void 0;this.setState(e,n)}else{if(o!==e.position)return void(void 0!==e.position&&e.position!==this.state.position&&this.props.onScroll(e.position));this.setState(e)}i&&_!==this&&(_&&_._blur(),_=this)},_didScroll:function(){this.props.onScroll(this.state.position)}});w.KEYBOARD_SCROLL_AMOUNT=g,w.SIZE=parseInt(l("scrollbar-size"),10),e.exports=w},function(e,t,o){"use strict";function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var n=function(){function e(e,t){for(var o=0;o0;)this._addRowToBuffer(t,this._viewportRowsBegin,this._viewportRowsEnd-1),t++,e--;return this._rows}},{key:"getRows",value:function(e,t){var o=t,i=o,n=e,r=Math.min(e+this._maxVisibleRowCount,this._rowsCount);for(this._viewportRowsBegin=e;r>n||i=r&&(i=this._bufferSet.replaceFurthestValuePosition(t,o,e)),null===i?(i=this._bufferSet.getNewPositionForValue(e),this._rows[i]=e):this._rows[i]=e}}]),e}();e.exports=h},function(e,t,o){"use strict";function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var n=function(){function e(e,t){for(var o=0;o=e&&t>=n)return null;var r;e-i>n-t?(r=i,this._smallValues.pop()):(r=n,this._largeValues.pop());var a=this._valueToPositionMap[r];return delete this._valueToPositionMap[r],this._valueToPositionMap[o]=a,this._pushToHeaps(a,o),a}},{key:"_pushToHeaps",value:function(e,t){var o={position:e,value:t};this._smallValues.push(o),this._largeValues.push(o)}},{key:"_cleanHeaps",value:function(){this._cleanHeap(this._smallValues),this._cleanHeap(this._largeValues);var e=Math.min(this._smallValues.size(),this._largeValues.size()),t=Math.max(this._smallValues.size(),this._largeValues.size());t>10*e&&this._recreateHeaps()}},{key:"_recreateHeaps",value:function(){for(var e=this._smallValues.size()t.value}}]),e}();e.exports=a},function(e,t,o){"use strict";function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(e,t){return t>e}var r=function(){function e(e,t){for(var o=0;o0&&(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(){return 0!==this._size?this._items[0]:void 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 o=Math.floor((e+1)/2)-1,i=this._items[o];if(this._comparator(i,t))return;this._items[o]=t,this._items[e]=i,e=o}}},{key:"_sinkDown",value:function(e){for(var t=this._items[e];;){var o=2*(e+1)-1,i=2*(e+1),n=-1;if(o0){var t=l({"fixedDataTableRow/fixedColumnsDivider":!0,"fixedDataTableRow/columnsShadow":this.props.scrollLeft>0}),o={left:e,height:this.props.height};return r.createElement("div",{className:t,style:o})}},_onClick:function(e){this.props.onClick(e,this.props.index,this.props.data)},_onDoubleClick:function(e){this.props.onDoubleClick(e,this.props.index,this.props.data)},_onMouseDown:function(e){this.props.onMouseDown(e,this.props.index,this.props.data)},_onMouseEnter:function(e){this.props.onMouseEnter(e,this.props.index,this.props.data)},_onMouseLeave:function(e){this.props.onMouseLeave(e,this.props.index,this.props.data)}}),d=r.createClass({displayName:"FixedDataTableRow",mixins:[s],propTypes:{height:f.number.isRequired,zIndex:f.number,offsetTop:f.number.isRequired,width:f.number.isRequired},render:function(){var e={width:this.props.width,height:this.props.height,zIndex:this.props.zIndex?this.props.zIndex:0};return h(e,0,this.props.offsetTop),r.createElement("div",{style:e,className:l("fixedDataTableRow/rowWrapper")},r.createElement(p,i({},this.props,{offsetTop:void 0,zIndex:void 0})))}});e.exports=d},function(e,t,o){"use strict";function i(e,t){var o={};for(var i in e)t.indexOf(i)>=0||Object.prototype.hasOwnProperty.call(e,i)&&(o[i]=e[i]);return o}var n=Object.assign||function(e){for(var t=1;tn;n++){var s=t[n].props;if(!s.allowCellsRecycling||i-e.left<=e.width&&i-e.left+s.width>=0){var l="cell_"+n;o[n]=this._renderCell(e.data,e.rowIndex,e.rowHeight,s,i,l)}i+=s.width}var u=this._getColumnsWidth(t),c={height:e.height,position:"absolute",width:u,zIndex:e.zIndex};return f(c,-1*e.left,0),a.createElement("div",{className:h("fixedDataTableCellGroup/cellGroup"),style:c},o)},_renderCell:function(e,t,o,i,n,r){var s,l=i.cellRenderer||c,h=i.columnData||d,f=i.dataKey,p=i.isFooterCell,m=i.isHeaderCell;if(m||p)s=e[f];else{var v=i.cellDataGetter;s=v?v(f,e):e[f]}var g=i.isResizable&&this.props.onColumnResize,_=g?this.props.onColumnResize:null;return a.createElement(u,{align:i.align,cellData:s,cellDataKey:f,cellRenderer:l,className:i.cellClassName,columnData:h,height:o,isFooterCell:p,isHeaderCell:m,key:r,maxWidth:i.maxWidth,minWidth:i.minWidth,onColumnResize:_,rowData:e,rowIndex:t,width:i.width,left:n})},_getColumnsWidth:function(e){for(var t=0,o=0;oi;i++)r(e,t[i])}},{key:"deepFreezeRootNode",value:function(t){if(!a(t)){Object.freeze(t);for(var o in t)t.hasOwnProperty(o)&&e.recurseDeepFreeze(t[o]);Object.seal(t)}}},{key:"recurseDeepFreeze",value:function(t){if(!a(t)&&e.shouldRecurseFreeze(t)){
-Object.freeze(t);for(var o in t)t.hasOwnProperty(o)&&e.recurseDeepFreeze(t[o]);Object.seal(t)}}},{key:"shouldRecurseFreeze",value:function(t){return"object"==typeof t&&!(t instanceof e)&&null!==t}}]),e}();h._DONT_EVER_TYPE_THIS_SECRET_KEY=Math.random(),e.exports=h},function(e,t,o){"use strict";function i(e){return!(!e||!("function"==typeof Node?e instanceof Node:"object"==typeof e&&"number"==typeof e.nodeType&&"string"==typeof e.nodeName))}e.exports=i},function(e,t,o){"use strict";var i=function(e){var t;for(t in e)if(e.hasOwnProperty(t))return t;return null};e.exports=i},function(e,t,o){"use strict";var i=o(61),n=o(73),r=36,s=function(e){return"object"!=typeof e||e instanceof Date||null===e},a={MAX_MERGE_DEPTH:r,isTerminal:s,normalizeMergeArg:function(e){return void 0===e||null===e?{}:e},checkMergeArrayArgs:function(e,t){i(Array.isArray(e)&&Array.isArray(t),"Tried to merge arrays, instead got %s and %s.",e,t)},checkMergeObjectArgs:function(e,t){a.checkMergeObjectArg(e),a.checkMergeObjectArg(t)},checkMergeObjectArg:function(e){i(!s(e)&&!Array.isArray(e),"Tried to merge an object, instead got %s.",e)},checkMergeIntoObjectArg:function(e){i(!(s(e)&&"function"!=typeof e||Array.isArray(e)),"Tried to merge into an object, instead got %s.",e)},checkMergeLevel:function(e){i(r>e,"Maximum deep merge depth exceeded. You may be attempting to merge circular structures in an unsupported way.")},checkArrayStrategy:function(e){i(void 0===e||e in a.ArrayStrategies,"You must provide an array strategy to deep merge functions to instruct the deep merge how to resolve merging two arrays.")},ArrayStrategies:n({Clobber:!0,IndexByIndex:!0})};e.exports=a},function(e,t,o){"use strict";var i=o(61),n=function(e){var t,o={};i(e instanceof Object&&!Array.isArray(e),"keyMirror(...): Argument must be an object.");for(t in e)e.hasOwnProperty(t)&&(o[t]=t);return o};e.exports=n},function(e,t,o){"use strict";var i=o(68),n=o(22),r=o(39),s=o(26),a=o(56),l=o(75),u=n.PropTypes,h=new i({align:"left",highlighted:!1,isFooterCell:!1,isHeaderCell:!1}),c=n.createClass({displayName:"FixedDataTableCell",mixins:[r],propTypes:{align:u.oneOf(["left","center","right"]),className:u.string,highlighted:u.bool,isFooterCell:u.bool,isHeaderCell:u.bool,width:u.number.isRequired,minWidth:u.number,maxWidth:u.number,height:u.number.isRequired,cellData:u.any,cellDataKey:u.oneOfType([u.string.isRequired,u.number.isRequired]),cellRenderer:u.func.isRequired,columnData:u.any,rowData:u.oneOfType([u.object.isRequired,u.array.isRequired]),rowIndex:u.number.isRequired,onColumnResize:u.func,left:u.number},getDefaultProps:function(){return h},render:function(){var e,t=this.props,o={height:t.height,left:t.left,width:t.width},i=l(a({"public/fixedDataTableCell/main":!0,"public/fixedDataTableCell/highlighted":t.highlighted,"public/fixedDataTableCell/lastChild":t.lastChild,"public/fixedDataTableCell/alignRight":"right"===t.align,"public/fixedDataTableCell/alignCenter":"center"===t.align}),t.className);e=t.isHeaderCell||t.isFooterCell?t.cellRenderer(t.cellData,t.cellDataKey,t.columnData,t.rowData,t.width):t.cellRenderer(t.cellData,t.cellDataKey,t.rowData,t.rowIndex,t.columnData,t.width);var r=a("public/fixedDataTableCell/cellContent");e=n.isValidElement(e)?s(e,{key:e.key,className:r}):n.createElement("div",{className:r},e);var u;if(t.onColumnResize){var h={height:t.height};u=n.createElement("div",{className:a("fixedDataTableCell/columnResizerContainer"),style:h,onMouseDown:this._onColumnResizerMouseDown},n.createElement("div",{className:a("fixedDataTableCell/columnResizerKnob"),style:h}))}var c={height:t.height,width:t.width};return n.createElement("div",{className:i,style:o},u,n.createElement("div",{className:a("public/fixedDataTableCell/wrap1"),style:c},n.createElement("div",{className:a("public/fixedDataTableCell/wrap2")},n.createElement("div",{className:a("public/fixedDataTableCell/wrap3")},e))))},_onColumnResizerMouseDown:function(e){this.props.onColumnResize(this.props.left,this.props.width,this.props.minWidth,this.props.maxWidth,this.props.cellDataKey,e)}});e.exports=c},function(e,t,o){"use strict";function i(e){e||(e="");var t,o=arguments.length;if(o>1)for(var i=1;o>i;i++)t=arguments[i],t&&(e=(e?e+" ":"")+t);return e}e.exports=i},function(e,t,o){"use strict";var i=o(51),n=o(21),r=o(22),s=o(39),a=o(19),l=o(56),u=r.PropTypes,h=r.createClass({displayName:"FixedDataTableColumnResizeHandle",mixins:[s],propTypes:{visible:u.bool.isRequired,height:u.number.isRequired,leftOffset:u.number.isRequired,knobHeight:u.number.isRequired,initialWidth:u.number,minWidth:u.number,maxWidth:u.number,initialEvent:u.object,onColumnResizeEnd:u.func,columnKey:u.oneOfType([u.string,u.number])},getInitialState:function(){return{width:0,cursorDelta:0}},componentWillReceiveProps:function(e){e.initialEvent&&!this._mouseMoveTracker.isDragging()&&(this._mouseMoveTracker.captureMouseMoves(e.initialEvent),this.setState({width:e.initialWidth,cursorDelta:e.initialWidth}))},componentDidMount:function(){this._mouseMoveTracker=new i(this._onMove,this._onColumnResizeEnd,document.body)},componentWillUnmount:function(){this._mouseMoveTracker.releaseMouseMoves(),this._mouseMoveTracker=null},render:function(){var e={width:this.state.width,height:this.props.height};return n.isRTL()?e.right=this.props.leftOffset:e.left=this.props.leftOffset,r.createElement("div",{className:l({"fixedDataTableColumnResizerLine/main":!0,"fixedDataTableColumnResizerLine/hiddenElem":!this.props.visible}),style:e},r.createElement("div",{className:l("fixedDataTableColumnResizerLine/mouseArea"),style:{height:this.props.height}}))},_onMove:function(e){n.isRTL()&&(e=-e);var t=this.state.cursorDelta+e,o=a(this.props.minWidth,t,this.props.maxWidth);this.setState({width:o,cursorDelta:t})},_onColumnResizeEnd:function(){this._mouseMoveTracker.releaseMouseMoves(),this.props.onColumnResizeEnd(this.state.width,this.props.columnKey)}});e.exports=h},function(e,t,o){"use strict";function i(e){for(var t=0,o=0;o=t)return{columns:e,width:i(e)};for(var o=n(e),r=t,s=[],a=0,l=0;lo?r(e,t-o).columns:e}var l=o(22),u=o(26),h={getTotalWidth:i,getTotalFlexGrow:n,distributeFlexWidth:r,adjustColumnWidths:a,adjustColumnGroupWidths:s};e.exports=h},function(e,t,o){"use strict";function i(e,t,o,i,n){function r(){for(var n=arguments.length,a=Array(n),l=0;n>l;l++)a[l]=arguments[l];r.reset();var u=function(){e.apply(o,a)};u.__SMmeta=e.__SMmeta,s=i(u,t)}i=i||setTimeout,n=n||clearTimeout;var s;return r.reset=function(){n(s)},r}e.exports=i},function(e,t,o){"use strict";function i(e,t){if(e===t)return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var o=Object.keys(e),i=Object.keys(t);if(o.length!==i.length)return!1;for(var n=Object.prototype.hasOwnProperty.bind(t),r=0;re&&this.state.scrollX>0||e>=0&&this.state.scrollXe&&this.state.scrollY>0||e>=0&&this.state.scrollYo?o:this.state.height>o&&this.props.ownerHeight?Math.max(o,this.props.ownerHeight):this.state.height+this.state.maxScrollY,e!==this._contentHeight&&this.props.onContentHeightChange&&this.props.onContentHeightChange(e),this._contentHeight=e},componentDidMount:function(){this._reportContentHeight()},componentWillReceiveProps:function(e){var t=e.scrollToRow;void 0!==t&&null!==t&&(this._rowToScrollTo=t);var i=e.scrollToColumn;void 0!==i&&null!==i&&(this._columnToScrollTo=i);var o=e.overflowX,n=e.overflowY;(o!==this.props.overflowX||n!==this.props.overflowY)&&(this._wheelHandler=new l(this._onWheel,"hidden"!==o,"hidden"!==n)),this.setState(this._calculateState(e,this.state))},componentDidUpdate:function(){this._reportContentHeight()},render:function(){var e,t=this.state,i=this.props;t.useGroupHeader&&(e=s.createElement(f,{key:"group_header",className:v("public/fixedDataTable/header"),data:t.groupHeaderData,width:t.width,height:t.groupHeaderHeight,index:0,zIndex:1,offsetTop:0,scrollLeft:t.scrollX,fixedColumns:t.groupHeaderFixedColumns,scrollableColumns:t.groupHeaderScrollableColumns}));var o=this.state.maxScrollY,n=t.maxScrollX>0&&"hidden"!==t.overflowX,r=o>0&&"hidden"!==t.overflowY,a=n?u.SIZE:0,l=t.height-a-2*H,h=t.useGroupHeader?t.groupHeaderHeight:0,p=h+t.headerHeight,d=0,m=null!=i.maxHeight?p+t.bodyHeight:l-i.footerHeight,g=m+t.footerHeight;void 0!==i.ownerHeight&&i.ownerHeightt.ownerHeight||t.scrollY or "),i.push(e))});var n=!1;i.length&&i[0].type.__TableColumnGroup__&&(n=!0);var r,s,a=t&&t.firstRowIndex||0,l=t&&t.firstRowOffset||0;r=t&&"hidden"!==e.overflowX?t.scrollX:e.scrollLeft,t&&"hidden"!==e.overflowY?s=t.scrollY:(f=this._scrollHelper.scrollTo(e.scrollTop),a=f.index,l=f.offset,s=f.position),void 0!==this._rowToScrollTo&&(f=this._scrollHelper.scrollRowIntoView(this._rowToScrollTo),a=f.index,l=f.offset,s=f.position,delete this._rowToScrollTo);var h=n?e.groupHeaderHeight:0;if(t&&e.rowsCount!==t.rowsCount){var c=e.height-e.headerHeight-e.footerHeight-h;this._scrollHelper=new p(e.rowsCount,e.rowHeight,c,e.rowHeightGetter);var f=this._scrollHelper.scrollToRow(a,l);a=f.index,l=f.offset,s=f.position}else t&&e.rowHeightGetter!==t.rowHeightGetter&&this._scrollHelper.setRowHeightGetter(e.rowHeightGetter);var m;m=e.isColumnResizing?t&&t.columnResizingData:T;var v,g;if(n){var _=d.adjustColumnGroupWidths(i,e.width);v=_.columns,g=_.columnGroups}else v=d.adjustColumnWidths(i,e.width);var y=this._populateColumnsAndColumnData(v,g,t);if(void 0!==this._columnToScrollTo){var C=y.bodyFixedColumns.length;if(this._columnToScrollTo>=C){var R,D,S=0;for(R=0;RR;++R)D=y.bodyScrollableColumns[R],E+=D.props.width;var k=e.width-S,O=y.bodyScrollableColumns[this._columnToScrollTo-C].props.width,z=E+O-k;z>r&&(r=z),r>E&&(r=E)}delete this._columnToScrollTo}var P=void 0===e.height,N=P?e.maxHeight:e.height,I=e.footerHeight+e.headerHeight+h+2*H,F=N-I,A=this._scrollHelper.getContentHeight(),W=A+I,G=d.getTotalWidth(v),V=G>e.width&&"hidden"!==e.overflowX;V&&(F-=u.SIZE,W+=u.SIZE,I+=u.SIZE);var j=Math.max(0,G-e.width),L=Math.max(0,A-F);r=Math.min(r,j),s=Math.min(s,L),L||(P&&(N=W),F=W-I),this._scrollHelper.setViewportHeight(F);var q=o({isColumnResizing:t&&t.isColumnResizing},y,e,{columns:v,columnGroups:g,columnResizingData:m,firstRowIndex:a,firstRowOffset:l,horizontalScrollbarVisible:V,maxScrollX:j,maxScrollY:L,reservedHeight:I,scrollContentHeight:A,scrollX:r,scrollY:s,bodyHeight:F,height:N,groupHeaderHeight:h,useGroupHeader:n});return t&&(t.headData&&q.headData&&b(t.headData,q.headData)&&(q.headData=t.headData),t.groupHeaderData&&q.groupHeaderData&&b(t.groupHeaderData,q.groupHeaderData)&&(q.groupHeaderData=t.groupHeaderData)),q},_createGroupHeaderColumns:function(e){for(var t=[],i=0;iMath.abs(e)&&"hidden"!==this.props.overflowY){var o=this._scrollHelper.scrollBy(Math.round(t)),n=Math.max(0,o.contentHeight-this.state.bodyHeight);this.setState({firstRowIndex:o.index,firstRowOffset:o.offset,scrollY:o.position,scrollContentHeight:o.contentHeight,maxScrollY:n})}else e&&"hidden"!==this.props.overflowX&&(i+=e,i=0>i?0:i,i=i>this.state.maxScrollX?this.state.maxScrollX:i,this.setState({scrollX:i}));this._didScrollStop()}},_onHorizontalScroll:function(e){this.isMounted()&&e!==this.state.scrollX&&(this.setState({scrollX:e}),this._didScrollStop())},_onVerticalScroll:function(e){if(this.isMounted()&&e!==this.state.scrollY){var t=this._scrollHelper.scrollTo(Math.round(e));this.setState({firstRowIndex:t.index,firstRowOffset:t.offset,scrollY:t.position,scrollContentHeight:t.contentHeight}),this._didScrollStop()}},_didScrollStop:function(){this.isMounted()&&this.props.onScrollEnd&&this.props.onScrollEnd(this.state.scrollX,this.state.scrollY)}}),S=s.createClass({displayName:"HorizontalScrollbar",mixins:[a],propTypes:{contentSize:C.number.isRequired,offset:C.number.isRequired,onScroll:C.func.isRequired,position:C.number.isRequired,size:C.number.isRequired},render:function(){var e={height:u.SIZE,width:this.props.size},t={height:u.SIZE,position:"absolute",overflow:"hidden",width:this.props.size};return y(t,0,this.props.offset),s.createElement("div",{className:v("fixedDataTable/horizontalScrollbar"),style:e},s.createElement("div",{style:t},s.createElement(u,o({},this.props,{isOpaque:!0,orientation:"horizontal",offset:void 0}))))}});e.exports=D},function(e,t,i){"use strict";function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var n=function(){function e(e,t){for(var i=0;ia;++a)this._storedHeights[a]=i;this._rowCount=t,this._position=0,this._contentHeight=t*i,this._defaultRowHeight=i,this._rowHeightGetter=s?s:function(){return i},this._viewportHeight=n,this.scrollRowIntoView=this.scrollRowIntoView.bind(this),this.setViewportHeight=this.setViewportHeight.bind(this),this.scrollBy=this.scrollBy.bind(this),this.scrollTo=this.scrollTo.bind(this),this.scrollToRow=this.scrollToRow.bind(this),this.setRowHeightGetter=this.setRowHeightGetter.bind(this),this.getContentHeight=this.getContentHeight.bind(this),this.getRowPosition=this.getRowPosition.bind(this),this._updateHeightsInViewport(0,0)}return n(e,[{key:"setRowHeightGetter",value:function(e){this._rowHeightGetter=e}},{key:"setViewportHeight",value:function(e){this._viewportHeight=e}},{key:"getContentHeight",value:function(){return this._contentHeight}},{key:"_updateHeightsInViewport",value:function(e,t){for(var i=t,o=e;i<=this._viewportHeight&&o=0&&t>=e-a;){var i=this._updateRowHeight(t);this._position+=i,t--}}},{key:"_updateRowHeight",value:function(e){if(0>e||e>=this._rowCount)return 0;var t=this._rowHeightGetter(e);if(t!==this._storedHeights[e]){var i=t-this._storedHeights[e];return this._rowOffsets.set(e,t),this._storedHeights[e]=t,this._contentHeight+=i,i}return 0}},{key:"getRowPosition",value:function(e){return this._updateRowHeight(e),this._rowOffsets.get(e).value-this._rowHeightGetter(e)}},{key:"scrollBy",value:function(e){var t=this._rowOffsets.upperBound(this._position),i=t.value-this._storedHeights[t.index],o=t.index,n=this._position,r=this._updateRowHeight(o);0!==i&&(n+=r);var a=this._storedHeights[o]-(n-i);if(e>=0)for(;e>0&&oe?(n+=e,e=0):(e-=a,n+=a,o++),oe){e=-e;for(var l=this._storedHeights[o]-a;e>0&&o>=0;)if(l>e?(n-=e,e=0):(n-=l,e-=l,o--),o>=0){var u=this._updateRowHeight(o);l=this._storedHeights[o],n+=u}}var h=this._contentHeight-this._viewportHeight;n=s(0,n,h),this._position=n;var c=this._rowOffsets.upperBound(n),f=c.index;i=c.value-this._rowHeightGetter(f);var p=i-n;return this._updateHeightsInViewport(f,p),this._updateHeightsAboveViewport(f),{index:f,offset:p,position:this._position,contentHeight:this._contentHeight}}},{key:"_getRowAtEndPosition",value:function(e){this._updateRowHeight(e);for(var t=e,i=this._storedHeights[t];i=0;)t--,t>=0&&(this._updateRowHeight(t),i+=this._storedHeights[t]);var o=this._rowOffsets.get(e).value-this._viewportHeight;return 0>o&&(o=0),o}},{key:"scrollTo",value:function(e){if(0>=e)return this._position=0,this._updateHeightsInViewport(0,0),{index:0,offset:0,position:this._position,contentHeight:this._contentHeight};if(e>=this._contentHeight-this._viewportHeight){var t=this._rowCount-1;e=this._getRowAtEndPosition(t)}this._position=e;var i=this._rowOffsets.upperBound(e),o=Math.max(i.index,0),n=i.value-this._rowHeightGetter(o),r=n-e;return this._updateHeightsInViewport(o,r),this._updateHeightsAboveViewport(o),{index:o,offset:r,position:this._position,contentHeight:this._contentHeight}}},{key:"scrollToRow",value:function(e,t){e=s(0,e,this._rowCount-1),t=s(-this._storedHeights[e],t,0);var i=this._rowOffsets.get(e);return this.scrollTo(i.value-this._storedHeights[e]-t)}},{key:"scrollRowIntoView",value:function(e){e=s(0,e,this._rowCount-1);var t=this._rowOffsets.get(e).value,i=t-this._storedHeights[e];if(ithis._position+this._viewportHeight){var o=this._getRowAtEndPosition(e);return this.scrollTo(o)}return this.scrollTo(this._position)}}]),e}();e.exports=l},function(e,t,i){(function(t){"use strict";function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=function(){function e(e,t){for(var i=0;it;)t*=2;return t}},{key:"_initArray",value:function(e){for(var t=[];e>0;)e--,t[e]=0;return t}},{key:"_initTables",value:function(e){var t,i=this._internalLeafCount,o=this._internalLeafCount+this._leafCount-1;for(t=i;o>=t;++t)this._value[t]=e;var n=this._internalLeafCount-1;for(t=n;t>0;--t)this._value[t]=this._value[2*t]+this._value[2*t+1]}},{key:"set",value:function(e,t){var i=e+this._internalLeafCount;for(this._value[i]=t,i=Math.floor(i/2);0!==i;)this._value[i]=this._value[2*i]+this._value[2*i+1],i=Math.floor(i/2)}},{key:"get",value:function(e){e=Math.min(e,this._leafCount);for(var t=e+this._internalLeafCount,i=this._value[t];t>1;)t%2===1&&(i=this._value[t-1]+i),t=Math.floor(t/2);return{index:e,value:i}}},{key:"upperBound",value:function(e){var t=this._upperBoundImpl(1,0,this._internalLeafCount-1,e);return t.index>this._leafCount-1&&(t.index=this._leafCount-1),t}},{key:"lowerBound",value:function(e){var t=this.upperBound(e);if(t.value>e&&t.index>0){var i=t.value-this._value[this._internalLeafCount+t.index];i===e&&(t.value=i,t.index--)}return t}},{key:"_upperBoundImpl",value:function(e,t,i,o){if(t===i)return{index:e-this._internalLeafCount,value:this._value[e]};var n=Math.floor((t+i+1)/2);if(ot?e:t>i?i:t}e.exports=o},function(e,t,i){"use strict";function o(e){return null===e||void 0===e?"":String(e)}function n(e,t){a.Children.forEach(e,function(e){e.type===l?n(e.props.children,t):e.type===u&&t(e)})}function r(e,t){var i=[];return a.Children.forEach(e,function(e){var o=e;if(e.type===l){var r=!1,s=[];n(e.props.children,function(e){var i=t(e);i!==e&&(r=!0),s.push(i)}),r&&(o=h(e,{key:e.key,children:s}))}else e.type===u&&(o=t(e));i.push(o)}),i}var s=i(21),a=i(22),l=i(24),u=i(25),h=i(26),c=s.isRTL()?-1:1,f=5,p={DIR_SIGN:c,CELL_VISIBILITY_TOLERANCE:f,renderToString:o,forEachColumn:n,mapColumns:r};e.exports=p},function(e,t,i){"use strict";var o={isRTL:function(){return!1},getDirection:function(){return"LTR"}};e.exports=o},function(e,t,i){"use strict";e.exports=i(23)},function(t,i,o){t.exports=e},function(e,t,i){"use strict";var o=i(22),n=o.PropTypes,r=o.createClass({displayName:"FixedDataTableColumnGroup",statics:{__TableColumnGroup__:!0},propTypes:{align:n.oneOf(["left","center","right"]),fixed:n.bool,columnGroupData:n.object,label:n.string,groupHeaderRenderer:n.func},getDefaultProps:function(){return{fixed:!1}},render:function(){throw new Error("Component should never render")}});e.exports=r},function(e,t,i){"use strict";var o=i(22),n=o.PropTypes,r=o.createClass({displayName:"FixedDataTableColumn",statics:{__TableColumn__:!0},propTypes:{align:n.oneOf(["left","center","right"]),cellClassName:n.string,cellRenderer:n.func,cellDataGetter:n.func,dataKey:n.oneOfType([n.string,n.number]).isRequired,fixed:n.bool,headerRenderer:n.func,footerRenderer:n.func,columnData:n.object,label:n.string,width:n.number.isRequired,minWidth:n.number,maxWidth:n.number,flexGrow:n.number,isResizable:n.bool,allowCellsRecycling:n.bool},getDefaultProps:function(){return{allowCellsRecycling:!1,fixed:!1}},render:function(){throw new Error("Component should never render")}});e.exports=r},function(e,t,i){"use strict";e.exports=i(27)},function(e,t,i){(function(t){"use strict";function o(e,i){"production"!==t.env.NODE_ENV&&("production"!==t.env.NODE_ENV?a(!e.ref,"You are calling cloneWithProps() on a child with a ref. This is dangerous because you're creating a new child which will not be added as a ref to its parent."):null);var o=r.mergeProps(i,e.props);return!o.hasOwnProperty(l)&&e.props.hasOwnProperty(l)&&(o.children=e.props.children),n.createElement(e.type,o)}var n=i(29),r=i(36),s=i(38),a=i(33),l=s({children:null});e.exports=o}).call(t,i(28))},function(e,t,i){function o(){h=!1,a.length?u=a.concat(u):c=-1,u.length&&n()}function n(){if(!h){var e=setTimeout(o);h=!0;for(var t=u.length;t;){for(a=u,u=[];++c1)for(var i=1;i1){for(var f=Array(h),p=0;h>p;p++)f[p]=arguments[p+2];n.children=f}if(e&&e.defaultProps){var d=e.defaultProps;for(o in d)"undefined"==typeof n[o]&&(n[o]=d[o])}return new c(e,a,l,s.current,r.current,n)},c.createFactory=function(e){var t=c.createElement.bind(null,e);return t.type=e,t},c.cloneAndReplaceProps=function(e,i){var o=new c(e.type,e.key,e.ref,e._owner,e._context,i);return"production"!==t.env.NODE_ENV&&(o._store.validated=e._store.validated),o},c.cloneElement=function(e,t,i){var o,n=a({},e.props),r=e.key,l=e.ref,h=e._owner;if(null!=t){void 0!==t.ref&&(l=t.ref,h=s.current),void 0!==t.key&&(r=""+t.key);for(o in t)t.hasOwnProperty(o)&&!u.hasOwnProperty(o)&&(n[o]=t[o])}var f=arguments.length-2;if(1===f)n.children=i;else if(f>1){for(var p=Array(f),d=0;f>d;d++)p[d]=arguments[d+2];n.children=p}return new c(e.type,r,l,h,e._context,n)},c.isValidElement=function(e){var t=!(!e||!e._isReactElement);return t},e.exports=c}).call(t,i(28))},function(e,t,i){(function(t){"use strict";var o=i(31),n=i(32),r=i(33),s=!1,a={current:n,withContext:function(e,i){"production"!==t.env.NODE_ENV&&("production"!==t.env.NODE_ENV?r(s,"withContext is deprecated and will be removed in a future version. Use a wrapper component with getChildContext instead."):null,s=!0);var n,l=a.current;a.current=o({},l,e);try{n=i()}finally{a.current=l}return n}};e.exports=a}).call(t,i(28))},function(e,t,i){"use strict";function o(e,t){if(null==e)throw new TypeError("Object.assign target cannot be null or undefined");for(var i=Object(e),o=Object.prototype.hasOwnProperty,n=1;no;o++)i.push(arguments[o]);if(void 0===t)throw new Error("`warning(condition, format, ...args)` requires a warning message argument");if(t.length<10||/^[s\W]*$/.test(t))throw new Error("The warning format should be able to uniquely identify this warning. Please, use a more descriptive format than: "+t);if(0!==t.indexOf("Failed Composite propType: ")&&!e){var r=0,s="Warning: "+t.replace(/%s/g,function(){return i[r++]});console.warn(s);try{throw new Error(s)}catch(a){}}}),e.exports=n}).call(t,i(28))},function(e,t,i){function o(e){return function(){return e}}function n(){}n.thatReturns=o,n.thatReturnsFalse=o(!1),n.thatReturnsTrue=o(!0),n.thatReturnsNull=o(null),n.thatReturnsThis=function(){return this},n.thatReturnsArgument=function(e){return e},e.exports=n},function(e,t,i){"use strict";var o={current:null};e.exports=o},function(e,t,i){"use strict";function o(e){return function(t,i,o){t.hasOwnProperty(i)?t[i]=e(t[i],o):t[i]=o}}function n(e,t){for(var i in t)if(t.hasOwnProperty(i)){var o=u[i];o&&u.hasOwnProperty(i)?o(e,i,t[i]):e.hasOwnProperty(i)||(e[i]=t[i])}return e}var r=i(31),s=i(34),a=i(37),l=o(function(e,t){return r({},t,e)}),u={children:s,className:o(a),style:l},h={mergeProps:function(e,t){return n(r({},e),t)}};e.exports=h},function(e,t,i){"use strict";function o(e){e||(e="");var t,i=arguments.length;if(i>1)for(var o=1;i>o;o++)t=arguments[o],t&&(e=(e?e+" ":"")+t);return e}e.exports=o},function(e,t,i){var o=function(e){var t;for(t in e)if(e.hasOwnProperty(t))return t;return null};e.exports=o},function(e,t,i){"use strict";e.exports=i(40)},function(e,t,i){"use strict";var o=i(41),n={shouldComponentUpdate:function(e,t){return!o(this.props,e)||!o(this.state,t)}};e.exports=n},function(e,t,i){"use strict";function o(e,t){if(e===t)return!0;var i;for(i in e)if(e.hasOwnProperty(i)&&(!t.hasOwnProperty(i)||e[i]!==t[i]))return!1;for(i in t)if(t.hasOwnProperty(i)&&!e.hasOwnProperty(i))return!1;return!0}e.exports=o},function(e,t,i){"use strict";function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var n=function(){function e(e,t){for(var i=0;io?-1:1),n&&!i&&(i=1>n?-1:1),{spinX:t,spinY:i,pixelX:o,pixelY:n}}var n=i(45),r=i(46),s=10,a=40,l=800;o.getEventType=function(){return n.firefox()?"DOMMouseScroll":r("wheel")?"wheel":"mousewheel"},e.exports=o},function(e,t,i){"use strict";function o(){if(!w){w=!0;var e=navigator.userAgent,t=/(?:MSIE.(\d+\.\d+))|(?:(?:Firefox|GranParadiso|Iceweasel).(\d+\.\d+))|(?:Opera(?:.+Version.|.)(\d+\.\d+))|(?:AppleWebKit.(\d+(?:\.\d+)?))|(?:Trident\/\d+\.\d+.*rv:(\d+\.\d+))/.exec(e),i=/(Mac OS X)|(Windows)|(Linux)/.exec(e);if(m=/\b(iPhone|iP[ao]d)/.exec(e),v=/\b(iP[ao]d)/.exec(e),p=/Android/i.exec(e),g=/FBAN\/\w+;/i.exec(e),
+_=/Mobile/i.exec(e),d=!!/Win64/.exec(e),t){n=t[1]?parseFloat(t[1]):t[5]?parseFloat(t[5]):NaN,n&&document&&document.documentMode&&(n=document.documentMode);var o=/(?:Trident\/(\d+.\d+))/.exec(e);u=o?parseFloat(o[1])+4:n,r=t[2]?parseFloat(t[2]):NaN,s=t[3]?parseFloat(t[3]):NaN,a=t[4]?parseFloat(t[4]):NaN,a?(t=/(?:Chrome\/(\d+\.\d+))/.exec(e),l=t&&t[1]?parseFloat(t[1]):NaN):l=NaN}else n=r=s=l=a=NaN;if(i){if(i[1]){var b=/(?:Mac OS X (\d+(?:[._]\d+)?))/.exec(e);h=b?parseFloat(b[1].replace("_",".")):!0}else h=!1;c=!!i[2],f=!!i[3]}else h=c=f=!1}}var n,r,s,a,l,u,h,c,f,p,d,m,v,g,_,w=!1,b={ie:function(){return o()||n},ieCompatibilityMode:function(){return o()||u>n},ie64:function(){return b.ie()&&d},firefox:function(){return o()||r},opera:function(){return o()||s},webkit:function(){return o()||a},safari:function(){return b.webkit()},chrome:function(){return o()||l},windows:function(){return o()||c},osx:function(){return o()||h},linux:function(){return o()||f},iphone:function(){return o()||m},mobile:function(){return o()||m||v||p||_},nativeApp:function(){return o()||g},android:function(){return o()||p},ipad:function(){return o()||v}};e.exports=b},function(e,t,i){"use strict";function o(e,t){if(!r.canUseDOM||t&&!("addEventListener"in document))return!1;var i="on"+e,o=i in document;if(!o){var s=document.createElement("div");s.setAttribute(i,"return;"),o="function"==typeof s[i]}return!o&&n&&"wheel"===e&&(o=document.implementation.hasFeature("Events.wheel","3.0")),o}var n,r=i(47);r.canUseDOM&&(n=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0),e.exports=o},function(e,t,i){"use strict";var o=!("undefined"==typeof window||!window.document||!window.document.createElement),n={canUseDOM:o,canUseWorkers:"undefined"!=typeof Worker,canUseEventListeners:o&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:o&&!!window.screen,isInWorker:!o};e.exports=n},function(e,t,i){(function(t){"use strict";var o=i(43),n=i(49),r=0,s=n||function(e){var i=Date.now(),o=Math.max(0,16-(i-r));return r=i+o,t.setTimeout(function(){e(Date.now())},o)};s(o),e.exports=s}).call(t,function(){return this}())},function(e,t,i){(function(t){"use strict";var i=t.requestAnimationFrame||t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.oRequestAnimationFrame||t.msRequestAnimationFrame;e.exports=i}).call(t,function(){return this}())},function(e,t,i){"use strict";var o=i(51),n=i(54),r=i(22),s=i(39),a=i(42),l=i(55),u=i(56),h=i(43),c=i(57),f=r.PropTypes,p={position:0,scrollable:!1},d=parseInt(l("scrollbar-face-margin"),10),m=2*d,v=30,g=40,_=null,w=r.createClass({displayName:"Scrollbar",mixins:[s],propTypes:{contentSize:f.number.isRequired,defaultPosition:f.number,isOpaque:f.bool,orientation:f.oneOf(["vertical","horizontal"]),onScroll:f.func,position:f.number,size:f.number.isRequired,trackColor:f.oneOf(["gray"]),zIndex:f.number},getInitialState:function(){var e=this.props;return this._calculateState(e.position||e.defaultPosition||0,e.size,e.contentSize,e.orientation)},componentWillReceiveProps:function(e){var t=e.position;void 0===t?this._setNextState(this._calculateState(this.state.position,e.size,e.contentSize,e.orientation)):this._setNextState(this._calculateState(t,e.size,e.contentSize,e.orientation),e)},getDefaultProps:function(){return{defaultPosition:0,isOpaque:!1,onScroll:h,orientation:"vertical",zIndex:99}},render:function(){if(!this.state.scrollable)return null;var e,t,i=this.props.size,o=this.state.isHorizontal,n=!o,s=this.state.focused||this.state.isDragging,a=this.state.faceSize,h=this.props.isOpaque,f=u({"public/Scrollbar/main":!0,"public/Scrollbar/mainHorizontal":o,"public/Scrollbar/mainVertical":n,"Scrollbar/mainActive":s,"Scrollbar/mainOpaque":h}),p=u({"Scrollbar/face":!0,"Scrollbar/faceHorizontal":o,"Scrollbar/faceVertical":n,"Scrollbar/faceActive":s}),v=this.state.position*this.state.scale+d;return o?(e={width:i},t={width:a-m},c(t,v,0)):(e={height:i},t={height:a-m},c(t,0,v)),e.zIndex=this.props.zIndex,"gray"===this.props.trackColor&&(e.backgroundColor=l("fbui-desktop-background-light")),r.createElement("div",{onFocus:this._onFocus,onBlur:this._onBlur,onKeyDown:this._onKeyDown,onMouseDown:this._onMouseDown,onWheel:this._wheelHandler.onWheel,className:f,style:e,tabIndex:0},r.createElement("div",{ref:"face",className:p,style:t}))},componentWillMount:function(){var e="horizontal"===this.props.orientation,t=e?this._onWheelX:this._onWheelY;this._wheelHandler=new a(t,this._shouldHandleX,this._shouldHandleY)},componentDidMount:function(){this._mouseMoveTracker=new o(this._onMouseMove,this._onMouseMoveEnd,document.documentElement),void 0!==this.props.position&&this.state.position!==this.props.position&&this._didScroll()},componentWillUnmount:function(){this._nextState=null,this._mouseMoveTracker.releaseMouseMoves(),_===this&&(_=null),delete this._mouseMoveTracker},scrollBy:function(e){this._onWheel(e)},_shouldHandleX:function(e){return"horizontal"===this.props.orientation?this._shouldHandleChange(e):!1},_shouldHandleY:function(e){return"horizontal"!==this.props.orientation?this._shouldHandleChange(e):!1},_shouldHandleChange:function(e){var t=this._calculateState(this.state.position+e,this.props.size,this.props.contentSize,this.props.orientation);return t.position!==this.state.position},_calculateState:function(e,t,i,o){if(1>t||t>=i)return p;var n=""+e+"_"+t+"_"+i+"_"+o;if(this._stateKey===n)return this._stateForKey;var r="horizontal"===o,s=t/i,a=Math.round(t*s);v>a&&(s=(t-v)/(i-v),a=v);var l=!0,u=i-t;0>e?e=0:e>u&&(e=u);var h=this._mouseMoveTracker?this._mouseMoveTracker.isDragging():!1;e=Math.round(e),a=Math.round(a);var c={faceSize:a,isDragging:h,isHorizontal:r,position:e,scale:s,scrollable:l};return this._stateKey=n,this._stateForKey=c,c},_onWheelY:function(e,t){this._onWheel(t)},_onWheelX:function(e,t){this._onWheel(e)},_onWheel:function(e){var t=this.props;this._setNextState(this._calculateState(this.state.position+e,t.size,t.contentSize,t.orientation))},_onMouseDown:function(e){var t;if(e.target!==r.findDOMNode(this.refs.face)){var i=e.nativeEvent,o=this.state.isHorizontal?i.offsetX||i.layerX:i.offsetY||i.layerY,n=this.props;o/=this.state.scale,t=this._calculateState(o-.5*this.state.faceSize/this.state.scale,n.size,n.contentSize,n.orientation)}else t={};t.focused=!0,this._setNextState(t),this._mouseMoveTracker.captureMouseMoves(e),r.findDOMNode(this).focus()},_onMouseMove:function(e,t){var i=this.props,o=this.state.isHorizontal?e:t;o/=this.state.scale,this._setNextState(this._calculateState(this.state.position+o,i.size,i.contentSize,i.orientation))},_onMouseMoveEnd:function(){this._nextState=null,this._mouseMoveTracker.releaseMouseMoves(),this.setState({isDragging:!1})},_onKeyDown:function(e){var t=e.keyCode;if(t!==n.TAB){var i=g,o=0;if(this.state.isHorizontal)switch(t){case n.HOME:o=-1,i=this.props.contentSize;break;case n.LEFT:o=-1;break;case n.RIGHT:o=1;break;default:return}if(!this.state.isHorizontal)switch(t){case n.SPACE:o=e.shiftKey?-1:1;break;case n.HOME:o=-1,i=this.props.contentSize;break;case n.UP:o=-1;break;case n.DOWN:o=1;break;case n.PAGE_UP:o=-1,i=this.props.size;break;case n.PAGE_DOWN:o=1,i=this.props.size;break;default:return}e.preventDefault();var r=this.props;this._setNextState(this._calculateState(this.state.position+i*o,r.size,r.contentSize,r.orientation))}},_onFocus:function(){this.setState({focused:!0})},_onBlur:function(){this.setState({focused:!1})},_blur:function(){if(this.isMounted())try{this._onBlur(),r.findDOMNode(this).blur()}catch(e){}},_setNextState:function(e,t){t=t||this.props;var i=t.position,o=this.state.position!==e.position;if(void 0===i){var n=o?this._didScroll:void 0;this.setState(e,n)}else{if(i!==e.position)return void(void 0!==e.position&&e.position!==this.state.position&&this.props.onScroll(e.position));this.setState(e)}o&&_!==this&&(_&&_._blur(),_=this)},_didScroll:function(){this.props.onScroll(this.state.position)}});w.KEYBOARD_SCROLL_AMOUNT=g,w.SIZE=parseInt(l("scrollbar-size"),10),e.exports=w},function(e,t,i){"use strict";function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var n=function(){function e(e,t){for(var i=0;i0;)this._addRowToBuffer(t,this._viewportRowsBegin,this._viewportRowsEnd-1),t++,e--;return this._rows}},{key:"getRows",value:function(e,t){var i=t,o=i,n=e,r=Math.min(e+this._maxVisibleRowCount,this._rowsCount);for(this._viewportRowsBegin=e;r>n||o=r&&(o=this._bufferSet.replaceFurthestValuePosition(t,i,e)),null===o?(o=this._bufferSet.getNewPositionForValue(e),this._rows[o]=e):this._rows[o]=e}}]),e}();e.exports=h},function(e,t,i){"use strict";function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var n=function(){function e(e,t){for(var i=0;i=e&&t>=n)return null;var r;e-o>n-t?(r=o,this._smallValues.pop()):(r=n,this._largeValues.pop());var a=this._valueToPositionMap[r];return delete this._valueToPositionMap[r],this._valueToPositionMap[i]=a,this._pushToHeaps(a,i),a}},{key:"_pushToHeaps",value:function(e,t){var i={position:e,value:t};this._smallValues.push(i),this._largeValues.push(i)}},{key:"_cleanHeaps",value:function(){this._cleanHeap(this._smallValues),this._cleanHeap(this._largeValues);var e=Math.min(this._smallValues.size(),this._largeValues.size()),t=Math.max(this._smallValues.size(),this._largeValues.size());t>10*e&&this._recreateHeaps()}},{key:"_recreateHeaps",value:function(){for(var e=this._smallValues.size()t.value}}]),e}();e.exports=a},function(e,t,i){"use strict";function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(e,t){return t>e}var r=function(){function e(e,t){for(var i=0;i0&&(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(){return 0!==this._size?this._items[0]:void 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 i=Math.floor((e+1)/2)-1,o=this._items[i];if(this._comparator(o,t))return;this._items[i]=t,this._items[e]=o,e=i}}},{key:"_sinkDown",value:function(e){for(var t=this._items[e];;){var i=2*(e+1)-1,o=2*(e+1),n=-1;if(i0){var t=l({"fixedDataTableRow/fixedColumnsDivider":!0,"fixedDataTableRow/columnsShadow":this.props.scrollLeft>0}),i={left:e,height:this.props.height};return r.createElement("div",{className:t,style:i})}},_onClick:function(e){this.props.onClick(e,this.props.index,this.props.data)},_onDoubleClick:function(e){this.props.onDoubleClick(e,this.props.index,this.props.data)},_onMouseDown:function(e){this.props.onMouseDown(e,this.props.index,this.props.data)},_onMouseEnter:function(e){this.props.onMouseEnter(e,this.props.index,this.props.data)},_onMouseLeave:function(e){this.props.onMouseLeave(e,this.props.index,this.props.data)}}),d=r.createClass({displayName:"FixedDataTableRow",mixins:[s],propTypes:{height:f.number.isRequired,zIndex:f.number,offsetTop:f.number.isRequired,width:f.number.isRequired},render:function(){var e={width:this.props.width,height:this.props.height,zIndex:this.props.zIndex?this.props.zIndex:0};return h(e,0,this.props.offsetTop),r.createElement("div",{style:e,className:l("fixedDataTableRow/rowWrapper")},r.createElement(p,o({},this.props,{offsetTop:void 0,zIndex:void 0})))}});e.exports=d},function(e,t,i){"use strict";function o(e,t){var i={};for(var o in e)t.indexOf(o)>=0||Object.prototype.hasOwnProperty.call(e,o)&&(i[o]=e[o]);return i}var n=Object.assign||function(e){for(var t=1;tn;n++){var s=t[n].props;if(!s.allowCellsRecycling||o-e.left<=e.width&&o-e.left+s.width>=0){var l="cell_"+n;i[n]=this._renderCell(e.data,e.rowIndex,e.rowHeight,s,o,l)}o+=s.width}var u=this._getColumnsWidth(t),c={height:e.height,position:"absolute",width:u,zIndex:e.zIndex};return f(c,-1*e.left,0),a.createElement("div",{className:h("fixedDataTableCellGroup/cellGroup"),style:c},i)},_renderCell:function(e,t,i,o,n,r){var s,l=o.cellRenderer||c,h=o.columnData||d,f=o.dataKey,p=o.isFooterCell,m=o.isHeaderCell;if(m||p)s=e[f];else{var v=o.cellDataGetter;s=v?v(f,e):e[f]}var g=o.isResizable&&this.props.onColumnResize,_=g?this.props.onColumnResize:null;return a.createElement(u,{align:o.align,cellData:s,cellDataKey:f,cellRenderer:l,className:o.cellClassName,columnData:h,height:i,isFooterCell:p,isHeaderCell:m,key:r,maxWidth:o.maxWidth,minWidth:o.minWidth,onColumnResize:_,rowData:e,rowIndex:t,width:o.width,left:n})},_getColumnsWidth:function(e){for(var t=0,i=0;io;o++)r(e,t[o])}},{key:"deepFreezeRootNode",value:function(t){if(!a(t)){Object.freeze(t);for(var i in t)t.hasOwnProperty(i)&&e.recurseDeepFreeze(t[i]);Object.seal(t)}}},{key:"recurseDeepFreeze",value:function(t){if(!a(t)&&e.shouldRecurseFreeze(t)){Object.freeze(t);for(var i in t)t.hasOwnProperty(i)&&e.recurseDeepFreeze(t[i]);Object.seal(t)}
+}},{key:"shouldRecurseFreeze",value:function(t){return"object"==typeof t&&!(t instanceof e)&&null!==t}}]),e}();h._DONT_EVER_TYPE_THIS_SECRET_KEY=Math.random(),e.exports=h},function(e,t,i){"use strict";function o(e){return!(!e||!("function"==typeof Node?e instanceof Node:"object"==typeof e&&"number"==typeof e.nodeType&&"string"==typeof e.nodeName))}e.exports=o},function(e,t,i){"use strict";var o=function(e){var t;for(t in e)if(e.hasOwnProperty(t))return t;return null};e.exports=o},function(e,t,i){"use strict";var o=i(61),n=i(73),r=36,s=function(e){return"object"!=typeof e||e instanceof Date||null===e},a={MAX_MERGE_DEPTH:r,isTerminal:s,normalizeMergeArg:function(e){return void 0===e||null===e?{}:e},checkMergeArrayArgs:function(e,t){o(Array.isArray(e)&&Array.isArray(t),"Tried to merge arrays, instead got %s and %s.",e,t)},checkMergeObjectArgs:function(e,t){a.checkMergeObjectArg(e),a.checkMergeObjectArg(t)},checkMergeObjectArg:function(e){o(!s(e)&&!Array.isArray(e),"Tried to merge an object, instead got %s.",e)},checkMergeIntoObjectArg:function(e){o(!(s(e)&&"function"!=typeof e||Array.isArray(e)),"Tried to merge into an object, instead got %s.",e)},checkMergeLevel:function(e){o(r>e,"Maximum deep merge depth exceeded. You may be attempting to merge circular structures in an unsupported way.")},checkArrayStrategy:function(e){o(void 0===e||e in a.ArrayStrategies,"You must provide an array strategy to deep merge functions to instruct the deep merge how to resolve merging two arrays.")},ArrayStrategies:n({Clobber:!0,IndexByIndex:!0})};e.exports=a},function(e,t,i){"use strict";var o=i(61),n=function(e){var t,i={};o(e instanceof Object&&!Array.isArray(e),"keyMirror(...): Argument must be an object.");for(t in e)e.hasOwnProperty(t)&&(i[t]=t);return i};e.exports=n},function(e,t,i){"use strict";var o=i(68),n=i(22),r=i(39),s=i(26),a=i(56),l=i(75),u=n.PropTypes,h=new o({align:"left",highlighted:!1,isFooterCell:!1,isHeaderCell:!1}),c=n.createClass({displayName:"FixedDataTableCell",mixins:[r],propTypes:{align:u.oneOf(["left","center","right"]),className:u.string,highlighted:u.bool,isFooterCell:u.bool,isHeaderCell:u.bool,width:u.number.isRequired,minWidth:u.number,maxWidth:u.number,height:u.number.isRequired,cellData:u.any,cellDataKey:u.oneOfType([u.string.isRequired,u.number.isRequired]),cellRenderer:u.func.isRequired,columnData:u.any,rowData:u.oneOfType([u.object.isRequired,u.array.isRequired]),rowIndex:u.number.isRequired,onColumnResize:u.func,left:u.number},getDefaultProps:function(){return h},render:function(){var e,t=this.props,i={height:t.height,left:t.left,width:t.width},o=l(a({"public/fixedDataTableCell/main":!0,"public/fixedDataTableCell/highlighted":t.highlighted,"public/fixedDataTableCell/lastChild":t.lastChild,"public/fixedDataTableCell/alignRight":"right"===t.align,"public/fixedDataTableCell/alignCenter":"center"===t.align}),t.className);e=t.isHeaderCell||t.isFooterCell?t.cellRenderer(t.cellData,t.cellDataKey,t.columnData,t.rowData,t.width):t.cellRenderer(t.cellData,t.cellDataKey,t.rowData,t.rowIndex,t.columnData,t.width);var r=a("public/fixedDataTableCell/cellContent");e=n.isValidElement(e)?s(e,{key:e.key,className:r}):n.createElement("div",{className:r},e);var u;if(t.onColumnResize){var h={height:t.height};u=n.createElement("div",{className:a("fixedDataTableCell/columnResizerContainer"),style:h,onMouseDown:this._onColumnResizerMouseDown},n.createElement("div",{className:a("fixedDataTableCell/columnResizerKnob"),style:h}))}var c={height:t.height,width:t.width};return n.createElement("div",{className:o,style:i},u,n.createElement("div",{className:a("public/fixedDataTableCell/wrap1"),style:c},n.createElement("div",{className:a("public/fixedDataTableCell/wrap2")},n.createElement("div",{className:a("public/fixedDataTableCell/wrap3")},e))))},_onColumnResizerMouseDown:function(e){this.props.onColumnResize(this.props.left,this.props.width,this.props.minWidth,this.props.maxWidth,this.props.cellDataKey,e)}});e.exports=c},function(e,t,i){"use strict";function o(e){e||(e="");var t,i=arguments.length;if(i>1)for(var o=1;i>o;o++)t=arguments[o],t&&(e=(e?e+" ":"")+t);return e}e.exports=o},function(e,t,i){"use strict";var o=i(51),n=i(21),r=i(22),s=i(39),a=i(19),l=i(56),u=r.PropTypes,h=r.createClass({displayName:"FixedDataTableColumnResizeHandle",mixins:[s],propTypes:{visible:u.bool.isRequired,height:u.number.isRequired,leftOffset:u.number.isRequired,knobHeight:u.number.isRequired,initialWidth:u.number,minWidth:u.number,maxWidth:u.number,initialEvent:u.object,onColumnResizeEnd:u.func,columnKey:u.oneOfType([u.string,u.number])},getInitialState:function(){return{width:0,cursorDelta:0}},componentWillReceiveProps:function(e){e.initialEvent&&!this._mouseMoveTracker.isDragging()&&(this._mouseMoveTracker.captureMouseMoves(e.initialEvent),this.setState({width:e.initialWidth,cursorDelta:e.initialWidth}))},componentDidMount:function(){this._mouseMoveTracker=new o(this._onMove,this._onColumnResizeEnd,document.body)},componentWillUnmount:function(){this._mouseMoveTracker.releaseMouseMoves(),this._mouseMoveTracker=null},render:function(){var e={width:this.state.width,height:this.props.height};return n.isRTL()?e.right=this.props.leftOffset:e.left=this.props.leftOffset,r.createElement("div",{className:l({"fixedDataTableColumnResizerLine/main":!0,"fixedDataTableColumnResizerLine/hiddenElem":!this.props.visible}),style:e},r.createElement("div",{className:l("fixedDataTableColumnResizerLine/mouseArea"),style:{height:this.props.height}}))},_onMove:function(e){n.isRTL()&&(e=-e);var t=this.state.cursorDelta+e,i=a(this.props.minWidth,t,this.props.maxWidth);this.setState({width:i,cursorDelta:t})},_onColumnResizeEnd:function(){this._mouseMoveTracker.releaseMouseMoves(),this.props.onColumnResizeEnd(this.state.width,this.props.columnKey)}});e.exports=h},function(e,t,i){"use strict";function o(e){for(var t=0,i=0;i=t)return{columns:e,width:o(e)};for(var i=n(e),r=t,s=[],a=0,l=0;li?r(e,t-i).columns:e}var l=i(22),u=i(26),h={getTotalWidth:o,getTotalFlexGrow:n,distributeFlexWidth:r,adjustColumnWidths:a,adjustColumnGroupWidths:s};e.exports=h},function(e,t,i){"use strict";function o(e,t,i,o,n){function r(){for(var n=arguments.length,a=Array(n),l=0;n>l;l++)a[l]=arguments[l];r.reset();var u=function(){e.apply(i,a)};u.__SMmeta=e.__SMmeta,s=o(u,t)}o=o||setTimeout,n=n||clearTimeout;var s;return r.reset=function(){n(s)},r}e.exports=o},function(e,t,i){"use strict";function o(e,t){if(e===t)return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var i=Object.keys(e),o=Object.keys(t);if(i.length!==o.length)return!1;for(var n=Object.prototype.hasOwnProperty.bind(t),r=0;r