react-virtualized
Advanced tools
Comparing version 4.6.6 to 4.7.0
Changelog | ||
------------ | ||
#### 4.7.0 | ||
Added `scrollToIndex` property to `FlexTable` to be passed through to inner `Grid`. | ||
#### 4.6.6 | ||
Better gaurd against NaN values for `clientWidth` and `offsetWidth` for test environments using PhantomJS. | ||
Better gaurd against `NaN` values for `clientWidth` and `offsetWidth` for test environments using `jsdom`. | ||
@@ -7,0 +10,0 @@ #### 4.6.5 |
@@ -26,2 +26,3 @@ FlexTable | ||
| rowsCount | Number | ✓ | Number of rows in table. | | ||
| scrollToIndex | Number | | Row index to ensure visible (by forcefully scrolling if necessary) | | ||
| sort | Function | | Sort function to be called if a sortable header is clicked. `(dataKey: string, sortDirection: SortDirection): void` | | ||
@@ -28,0 +29,0 @@ | sortBy | String | | Data is currently sorted by this `dataKey` (if it is sorted at all) | |
@@ -6,3 +6,3 @@ { | ||
"user": "bvaughn", | ||
"version": "4.6.6", | ||
"version": "4.7.0", | ||
"scripts": { | ||
@@ -9,0 +9,0 @@ "build": "npm run build:css && npm run build:dist && npm run build:demo", |
@@ -136,2 +136,3 @@ /** @flow */ | ||
rowsCount={rowsCount} | ||
scrollToIndex={scrollToIndex} | ||
sort={this._sort} | ||
@@ -200,4 +201,2 @@ sortBy={sortBy} | ||
this.setState({ scrollToIndex }) | ||
this.refs.Table.scrollToRow(scrollToIndex) | ||
} | ||
@@ -204,0 +203,0 @@ |
@@ -94,2 +94,4 @@ /** @flow */ | ||
rowsCount: PropTypes.number.isRequired, | ||
/** Row index to ensure visible (by forcefully scrolling if necessary) */ | ||
scrollToIndex: PropTypes.number, | ||
/** | ||
@@ -173,2 +175,3 @@ * Sort function to be called if a sortable header is clicked. | ||
rowsCount, | ||
scrollToIndex, | ||
verticalPadding | ||
@@ -213,2 +216,3 @@ } = this.props | ||
rowsCount={rowsCount} | ||
scrollToIndex={scrollToIndex} | ||
/> | ||
@@ -215,0 +219,0 @@ </div> |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
666712
8275