更新Readme

This commit is contained in:
Julyp
2020-02-07 21:25:22 +08:00
parent 5ac634ea05
commit 31b9f7289a
2 changed files with 17 additions and 11 deletions

View File

@@ -22,6 +22,7 @@
- 多级表头 - 多级表头
- 排序 - 排序
- 树形数据 - 树形数据
- 单选、多选
## 体验 ## 体验
可直接访问https://peng92055.github.io/smart-table 可直接访问https://peng92055.github.io/smart-table
@@ -65,7 +66,9 @@
hoverBgColor: '#C5DFFF', hoverBgColor: '#C5DFFF',
height: 300, height: 300,
align: 'left', align: 'left',
size: 'middle' size: 'middle',
selection: 'checkbox',
selectionKey: 1,
}) })
``` ```
@@ -83,15 +86,18 @@
### Table Options ### Table Options
| Property | Type | Required | Description | Default | | Property | Type | Required | Description | Default |
| :---------------------| :----------------- | :---------- | :------------------------------------------ | :------------ | | :---------------------| :----------------- | :---------- | :------------------------------------------------------------- | :------------ |
| selector | string | yes | 需要初始化的表格元素 | | | selector | string | yes | 需要初始化的表格元素 | |
| height | number or function | no | 可指定表格的高度 | | | height | number or function | no | 可指定表格的高度 | |
| align | string | no | 表格文本的水平排列方式(left、center、right) | center | | align | string | no | 表格文本的水平排列方式(left、center、right) | center |
| size | string | no | 每一行的垂直高度风格(large、middle、small) | small | | size | string | no | 每一行的垂直高度风格(large、middle、small) | small |
| hoverBgColor | string | no | body中每行hover时的背景色 | '#EFF8FF' | | hoverBgColor | string | no | body中每行hover时的背景色 | '#EFF8FF' |
| expand | boolean | no | 是否开启树形结构(树形结构会忽略排序及固定列) | false | | expand | boolean | no | 是否开启树形结构(树形结构会忽略排序及固定列) | false |
| defaultExpandAll | boolean | no | 是否默认展开所有树形结构 | false | | defaultExpandAll | boolean | no | 是否默认展开所有树形结构 | false |
| selection | string | no | 单选或多选radio、checkbox),选中值会存储在根节点selected属性上 | false |
| selectionKey | string or number | no | 单选或多选时选中取值对应的tbody中有效列的角标角标从0开始 | 0 |

File diff suppressed because one or more lines are too long