react-base-table
Advanced tools
Comparing version 1.3.1 to 1.3.2
@@ -5,2 +5,6 @@ # CHANGELOG | ||
- fix: resizing line rendered incorrectly when resizing the right frozen column | ||
# v1.3.1 (2019-06-06) | ||
- chore: upgrade `react-window` to silence the deprecation | ||
@@ -7,0 +11,0 @@ |
@@ -617,9 +617,18 @@ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; } | ||
}); | ||
var column = this.columnManager.getColumn(resizingKey); | ||
var left = this.columnManager.recomputeColumnsWidth(columns.slice(0, idx + 1)); | ||
var column = columns[idx]; | ||
var columnWidth = column.width, | ||
frozen = column.frozen; | ||
var leftWidth = this.columnManager.recomputeColumnsWidth(columns.slice(0, idx)); | ||
var left = leftWidth + columnWidth; | ||
if (!column.frozen) { | ||
if (!frozen) { | ||
left -= this._scroll.scrollLeft; | ||
} else if (column.frozen === FrozenDirection.RIGHT) { | ||
left = width - this._verticalScrollbarSize - this.columnManager.recomputeColumnsWidth(columns.slice(idx + 1)); | ||
} else if (frozen === FrozenDirection.RIGHT) { | ||
var rightWidth = this.columnManager.recomputeColumnsWidth(columns.slice(idx + 1)); | ||
if (rightWidth + columnWidth > width - this._verticalScrollbarSize) { | ||
left = columnWidth; | ||
} else { | ||
left = width - this._verticalScrollbarSize - rightWidth; | ||
} | ||
} | ||
@@ -626,0 +635,0 @@ |
@@ -673,9 +673,18 @@ "use strict"; | ||
}); | ||
var column = this.columnManager.getColumn(resizingKey); | ||
var left = this.columnManager.recomputeColumnsWidth(columns.slice(0, idx + 1)); | ||
var column = columns[idx]; | ||
var columnWidth = column.width, | ||
frozen = column.frozen; | ||
var leftWidth = this.columnManager.recomputeColumnsWidth(columns.slice(0, idx)); | ||
var left = leftWidth + columnWidth; | ||
if (!column.frozen) { | ||
if (!frozen) { | ||
left -= this._scroll.scrollLeft; | ||
} else if (column.frozen === _Column.FrozenDirection.RIGHT) { | ||
left = width - this._verticalScrollbarSize - this.columnManager.recomputeColumnsWidth(columns.slice(idx + 1)); | ||
} else if (frozen === _Column.FrozenDirection.RIGHT) { | ||
var rightWidth = this.columnManager.recomputeColumnsWidth(columns.slice(idx + 1)); | ||
if (rightWidth + columnWidth > width - this._verticalScrollbarSize) { | ||
left = columnWidth; | ||
} else { | ||
left = width - this._verticalScrollbarSize - rightWidth; | ||
} | ||
} | ||
@@ -682,0 +691,0 @@ |
{ | ||
"name": "react-base-table", | ||
"version": "1.3.1", | ||
"version": "1.3.2", | ||
"description": "a react table component to display large data set with high performance and flexibility", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -35,3 +35,3 @@ # react-base-table | ||
In the [examples](https://autodesk.github.io/react-base-table/examples) | ||
we are using a wrapper `const Table = props => <BaseTable width={720} height={400} {...props} />` to do that | ||
we are using a wrapper `const Table = props => <BaseTable width={700} height={400} {...props} />` to do that | ||
@@ -38,0 +38,0 @@ You can use the [`AutoResizer`](https://autodesk.github.io/react-base-table/api/autoresizer) to make the table fill the container, take the [playground](https://autodesk.github.io/react-base-table/playground) for example |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
806842
5910