This commit is contained in:
AllenFang 2019-08-24 14:59:58 +08:00
parent 056957b0b5
commit c25192145f

View File

@ -18,6 +18,7 @@
* [expandColumnPosition](#expandColumnPosition)
* [expandColumnRenderer](#expandColumnRenderer)
* [expandHeaderColumnRenderer](#expandHeaderColumnRenderer)
* [className](#className)
* [parentClassName](#parentClassName)
### <a name="renderer">expandRow.renderer - [Function]</a>
@ -168,6 +169,27 @@ const expandRow = {
};
```
### <a name='className'>expandRow.className - [String | Function]</a>
Apply the custom class name on the expanding row. For example:
```js
const expandRow = {
renderer: (row) => ...,
className: 'foo'
};
```
following usage is more flexible way for customing the class name:
```js
const expandRow = {
renderer: (row) => ...,
className: (isExpanded, row, rowIndex) => {
if (rowIndex > 2) return 'foo';
return 'bar';
}
};
```
### <a name='parentClassName'>expandRow.parentClassName - [String | Function]</a>
Apply the custom class name on parent row of expanded row. For example: