Compare commits

..
Author SHA1 Message Date
Aaron SchwartzandGitHub 44db30fe73 Fix source code in FixedHeader example 2017-06-26 10:51:52 -07:00
Tanner Linsley b76f9c956d 6.4.0 2017-06-19 11:34:29 -06:00
Tanner Linsley 2e3743b75f Feature: PadRowComponent prop 2017-06-19 11:34:21 -06:00
6 changed files with 12 additions and 4 deletions
+4
View File
@@ -1,3 +1,7 @@
## 6.4.0
##### New Features
- `PadRowComponent` - the content rendered inside of a padding row. Defaults to a react component that renders ` `
## 6.3.0
##### New Features
- `defaultSortDesc` - allows you to set the default sorting direction for all columns to descending.
+1
View File
@@ -195,6 +195,7 @@ These are all of the available props (and their default values) for the main `<R
// returning 0, undefined or any falsey value will use subsequent sorts or the index as a tiebreaker
return 0
},
PadRowComponent: () => <span>&nbsp;</span>, // the content rendered inside of a padding row
// Controlled State Overrides (see Fully Controlled Component section)
page: undefined,
+1 -1
View File
@@ -71,7 +71,7 @@ class Story extends React.PureComponent {
}
const CodeHighlight = require('./components/codeHighlight').default
const source = require('!raw!./Simple')
const source = require('!raw!./FixedHeader')
export default () => (
<div>
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "react-table",
"version": "6.3.0",
"version": "6.4.0",
"description": "A fast, lightweight, opinionated table and datagrid built on React",
"license": "MIT",
"homepage": "https://github.com/tannerlinsley/react-table#readme",
+1
View File
@@ -231,4 +231,5 @@ export default {
</div>,
NoDataComponent: _.makeTemplateComponent('rt-noData'),
ResizerComponent: _.makeTemplateComponent('rt-resizer'),
PadRowComponent: () => <span>&nbsp;</span>,
}
+4 -2
View File
@@ -118,6 +118,7 @@ export default class ReactTable extends Methods(Lifecycle(Component)) {
PivotComponent,
AggregatedComponent,
FilterComponent,
PadRowComponent,
// Data model
resolvedData,
allVisibleColumns,
@@ -159,7 +160,6 @@ export default class ReactTable extends Methods(Lifecycle(Component)) {
index
]
}
;[pageRows] = recurseRowsViewIndex(pageRows)
const canPrevious = page > 0
@@ -804,7 +804,9 @@ export default class ReactTable extends Methods(Lifecycle(Component)) {
maxWidth: `${maxWidth}px`
}}
{...tdProps.rest}
/>
>
{_.normalizeComponent(PadRowComponent)}
</TdComponent>
)
}