mirror of
https://github.com/gosticks/react-bootstrap-table2.git
synced 2025-10-16 11:55:39 +00:00
20181221 release
This commit is contained in:
parent
587e456447
commit
4bd080adbd
@ -126,18 +126,21 @@ const expandRow = {
|
|||||||
```
|
```
|
||||||
|
|
||||||
## expandRow.expandColumnRenderer - [Function]
|
## expandRow.expandColumnRenderer - [Function]
|
||||||
Provide a callback function which allow you to custom the expand indicator. This callback only have one argument which is an object and contain one property `expanded` to indicate if current row is expanded
|
Provide a callback function which allow you to custom the expand indicator. This callback only have one argument which is an object and contain these properties:
|
||||||
|
* `expanded`: If current row is expanded or not
|
||||||
|
* `rowKey`: Current row key
|
||||||
|
* `expandable`: If currnet row is expandable or not
|
||||||
|
|
||||||
|
|
||||||
```js
|
```js
|
||||||
const expandRow = {
|
const expandRow = {
|
||||||
renderer: (row) => ...,
|
renderer: (row) => ...
|
||||||
showExpandColumn: true,
|
expandColumnRenderer: ({ expanded, rowKey, expandable }) => (
|
||||||
expandColumnRenderer: ({ expanded }) => (
|
|
||||||
// ....
|
// ....
|
||||||
)
|
)
|
||||||
};
|
};
|
||||||
```
|
```
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
## expandRow.expandHeaderColumnRenderer - [Function]
|
## expandRow.expandHeaderColumnRenderer - [Function]
|
||||||
|
|||||||
@ -28,6 +28,7 @@ title: BootstrapTable Props
|
|||||||
* [rowStyle](#rowstyle-object-function)
|
* [rowStyle](#rowstyle-object-function)
|
||||||
* [rowClasses](#rowclasses-string-function)
|
* [rowClasses](#rowclasses-string-function)
|
||||||
* [rowEvents](#rowevents-object)
|
* [rowEvents](#rowevents-object)
|
||||||
|
* [hiddenRows](#hiddenrows-array)
|
||||||
* [defaultSorted](#defaultsorted-array)
|
* [defaultSorted](#defaultsorted-array)
|
||||||
* [defaultSortDirection](#defaultSortDirection-string)
|
* [defaultSortDirection](#defaultSortDirection-string)
|
||||||
* [pagination](#pagination-object)
|
* [pagination](#pagination-object)
|
||||||
@ -183,6 +184,14 @@ const rowEvents = {
|
|||||||
<BootstrapTable data={ data } columns={ columns } rowEvents={ rowEvents } />
|
<BootstrapTable data={ data } columns={ columns } rowEvents={ rowEvents } />
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## hiddenRows - [Array]
|
||||||
|
Hide rows, this props accept an array of row keys:
|
||||||
|
|
||||||
|
```js
|
||||||
|
const hiddenRows = [1, 4];
|
||||||
|
<BootstrapTable data={ data } columns={ columns } hiddenRows={ hiddenRows } />
|
||||||
|
```
|
||||||
|
|
||||||
## defaultSorted - [Array]
|
## defaultSorted - [Array]
|
||||||
`defaultSorted` accept an object array which allow you to define the default sort columns when first render.
|
`defaultSorted` accept an object array which allow you to define the default sort columns when first render.
|
||||||
|
|
||||||
|
|||||||
24
website/blog/2018-12-21-version-bump.md
Normal file
24
website/blog/2018-12-21-version-bump.md
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
---
|
||||||
|
title: New Release (2018-12-21)
|
||||||
|
author: Allen Fang
|
||||||
|
authorURL: https://twitter.com/allenfang_tw
|
||||||
|
---
|
||||||
|
|
||||||
|
## Changed Packages
|
||||||
|
|
||||||
|
We got following package version bump in this release:
|
||||||
|
|
||||||
|
* `react-bootstrap-table-next@1.4.3`
|
||||||
|
|
||||||
|
|
||||||
|
## Changelog
|
||||||
|
|
||||||
|
### Bug fixes
|
||||||
|
* Fixed a non expandable row still expandable when `expandRow.showExpandColumn` is enable([#698](https://github.com/react-bootstrap-table/react-bootstrap-table2/pull/698))
|
||||||
|
|
||||||
|
### Features
|
||||||
|
N/A
|
||||||
|
|
||||||
|
### Enhancements
|
||||||
|
* Support hidden row([4ddbfd4](https://github.com/react-bootstrap-table/react-bootstrap-table2/pull/721/commits/4ddbfd4972f84606450b0e1ff87778423ccb49d0))
|
||||||
|
* Pass `rowKey` and `expandable` to `expandRow.expandColumnRenderer` callback function([bc4697b](https://github.com/react-bootstrap-table/react-bootstrap-table2/pull/721/commits/bc4697bf9598377c34abaa8c6ffd16b4174bcf5b))
|
||||||
Loading…
Reference in New Issue
Block a user