Skip to content

Commit

Permalink
Version 0.7.2
Browse files Browse the repository at this point in the history
  • Loading branch information
Kamran Asif committed Aug 3, 2016
1 parent 5e11477 commit 93890e8
Show file tree
Hide file tree
Showing 10 changed files with 32 additions and 20 deletions.
2 changes: 1 addition & 1 deletion dist/fixed-data-table-base.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* FixedDataTable v0.7.1
* FixedDataTable v0.7.2
*
* Copyright Schrodinger, LLC
* All rights reserved.
Expand Down
2 changes: 1 addition & 1 deletion dist/fixed-data-table-base.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/fixed-data-table-style.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* FixedDataTable v0.7.1
* FixedDataTable v0.7.2
*
* Copyright Schrodinger, LLC
* All rights reserved.
Expand Down
2 changes: 1 addition & 1 deletion dist/fixed-data-table-style.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/fixed-data-table.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* FixedDataTable v0.7.1
* FixedDataTable v0.7.2
*
* Copyright Schrodinger, LLC
* All rights reserved.
Expand Down
28 changes: 20 additions & 8 deletions dist/fixed-data-table.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* FixedDataTable v0.7.1
* FixedDataTable v0.7.2
*
* Copyright Schrodinger, LLC
* All rights reserved.
Expand Down Expand Up @@ -208,7 +208,7 @@ return /******/ (function(modules) { // webpackBootstrap
Table: _FixedDataTable2.default
};

FixedDataTableRoot.version = '0.7.1';
FixedDataTableRoot.version = '0.7.2';
module.exports = FixedDataTableRoot;

/***/ },
Expand Down Expand Up @@ -975,6 +975,11 @@ return /******/ (function(modules) { // webpackBootstrap
this.props.onColumnReorderEndCallback({
columnBefore: columnBefore, columnAfter: columnAfter, reorderColumn: reorderColumn
});

var onHorizontalScroll = this.props.onHorizontalScroll;
if (this.state.columnReorderingData.scrollStart !== this.state.scrollX && onHorizontalScroll) {
onHorizontalScroll(this.state.scrollX);
};
},
_areColumnSettingsIdentical: function _areColumnSettingsIdentical(oldColumns, newColumns) {
if (oldColumns.length !== newColumns.length) {
Expand Down Expand Up @@ -2441,7 +2446,7 @@ return /******/ (function(modules) { // webpackBootstrap
this._trackerId = null;

// Initialize decelerating autoscroll on drag stop
requestAnimationFrame(this._startAutoScroll);
(0, _requestAnimationFramePolyfill2.default)(this._startAutoScroll);

if (this._stopPropagation()) {
event.stopPropagation();
Expand Down Expand Up @@ -2601,7 +2606,7 @@ return /******/ (function(modules) { // webpackBootstrap

if (deltaX !== 0 || deltaY !== 0) {
this._onTouchScrollCallback(deltaX, deltaY);
requestAnimationFrame(this._autoScroll);
(0, _requestAnimationFramePolyfill2.default)(this._autoScroll);
}
}
}]);
Expand Down Expand Up @@ -4989,7 +4994,8 @@ return /******/ (function(modules) { // webpackBootstrap
var currentPosition = 0;
for (var i = 0, j = columns.length; i < j; i++) {
var columnProps = columns[i].props;
if (!columnProps.allowCellsRecycling || currentPosition - props.left <= props.width && currentPosition - props.left + columnProps.width >= 0) {
var recycable = columnProps.allowCellsRecycling && !isColumnReordering;
if (!recycable || currentPosition - props.left <= props.width && currentPosition - props.left + columnProps.width >= 0) {
var key = 'cell_' + i;
cells[i] = this._renderCell(props.rowIndex, props.rowHeight, columnProps, currentPosition, key, contentWidth, isColumnReordering);
}
Expand Down Expand Up @@ -5937,15 +5943,17 @@ return /******/ (function(modules) { // webpackBootstrap
},

render: function render() {
//Remove some props like columnKey and rowIndex so we don't pass it into the div
var _props = this.props;
var height = _props.height;
var width = _props.width;
var style = _props.style;
var className = _props.className;
var children = _props.children;
var columnKey = _props.columnKey;
var rowIndex = _props.rowIndex;

var props = _objectWithoutProperties(_props, ['height', 'width', 'style', 'className', 'children', 'columnKey']);
var props = _objectWithoutProperties(_props, ['height', 'width', 'style', 'className', 'children', 'columnKey', 'rowIndex']);

var innerStyle = _extends({
height: height,
Expand Down Expand Up @@ -6099,6 +6107,8 @@ return /******/ (function(modules) { // webpackBootstrap
componentWillReceiveProps: function componentWillReceiveProps( /*object*/newProps) {},
componentWillUnmount: function componentWillUnmount() {
if (this._mouseMoveTracker) {
cancelAnimationFrame(this.frameId);
this.frameId = null;
this._mouseMoveTracker.releaseMouseMoves();
this._mouseMoveTracker = null;
}
Expand Down Expand Up @@ -6137,19 +6147,21 @@ return /******/ (function(modules) { // webpackBootstrap

this._distance = 0;
this._animating = true;
requestAnimationFrame(this._updateState);
this.frameId = requestAnimationFrame(this._updateState);
},
_onMove: function _onMove( /*number*/deltaX) {
this._distance = this.state.dragDistance + deltaX;
},
_onColumnReorderEnd: function _onColumnReorderEnd() {
this._animating = false;
cancelAnimationFrame(this.frameId);
this.frameId = null;
this._mouseMoveTracker.releaseMouseMoves();
this.props.onColumnReorderEnd();
},
_updateState: function _updateState() {
if (this._animating) {
requestAnimationFrame(this._updateState);
this.frameId = requestAnimationFrame(this._updateState);
}
this.setState({
dragDistance: this._distance
Expand Down
2 changes: 1 addition & 1 deletion dist/fixed-data-table.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions dist/fixed-data-table.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "fixed-data-table-2",
"version": "0.7.1",
"version": "0.7.2",
"description": "A React table component designed to allow presenting thousands of rows of data.",
"main": "main.js",
"peerDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion src/FixedDataTableRoot.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,5 @@ var FixedDataTableRoot = {
Table: FixedDataTable,
};

FixedDataTableRoot.version = '0.7.1';
FixedDataTableRoot.version = '0.7.2';
module.exports = FixedDataTableRoot;

0 comments on commit 93890e8

Please sign in to comment.