[improvement] Picker: update document and fix snapshot

This commit is contained in:
陈嘉涵
2019-06-09 09:53:09 +08:00
parent 04b88583c2
commit 3a4b434b4c
9 changed files with 40 additions and 0 deletions
+1
View File
@@ -187,6 +187,7 @@ When Picker columns data is acquired asynchronously, use `loading` prop to show
|------|------|------|------|
| columns | Columns data | `Array` | `[]` |
| show-toolbar | Whether to show toolbar | `Boolean` | `false` |
| toolbar-position | Toolbar position, cat be set to `bottom` | `String` | `top` |
| title | Toolbar title | `String` | `''` |
| loading | Whether to show loading prompt | `Boolean` | `false` |
| value-key | Key of option text | `String` | `text` |
@@ -18,6 +18,7 @@ exports[`renders demo correctly 1`] = `
<div class="van-picker__mask" style="background-size: 100% 88px;"></div>
<div class="van-hairline--top-bottom van-picker__frame" style="height: 44px;"></div>
</div>
<!---->
</div>
</div>
<div>
@@ -36,6 +37,7 @@ exports[`renders demo correctly 1`] = `
<div class="van-picker__mask" style="background-size: 100% 88px;"></div>
<div class="van-hairline--top-bottom van-picker__frame" style="height: 44px;"></div>
</div>
<!---->
</div>
</div>
<div>
@@ -59,6 +61,7 @@ exports[`renders demo correctly 1`] = `
<div class="van-picker__mask" style="background-size: 100% 88px;"></div>
<div class="van-hairline--top-bottom van-picker__frame" style="height: 44px;"></div>
</div>
<!---->
</div>
</div>
<div>
@@ -84,6 +87,7 @@ exports[`renders demo correctly 1`] = `
<div class="van-picker__mask" style="background-size: 100% 88px;"></div>
<div class="van-hairline--top-bottom van-picker__frame" style="height: 44px;"></div>
</div>
<!---->
</div>
</div>
<div>
@@ -108,6 +112,7 @@ exports[`renders demo correctly 1`] = `
<div class="van-picker__mask" style="background-size: 100% 88px;"></div>
<div class="van-hairline--top-bottom van-picker__frame" style="height: 44px;"></div>
</div>
<!---->
</div>
</div>
<div>
@@ -132,6 +137,7 @@ exports[`renders demo correctly 1`] = `
<div class="van-picker__mask" style="background-size: 100% 88px;"></div>
<div class="van-hairline--top-bottom van-picker__frame" style="height: 44px;"></div>
</div>
<!---->
</div>
</div>
</div>
@@ -38,5 +38,6 @@ exports[`render title slot 1`] = `
<div class="van-picker__mask" style="background-size: 100% 88px;"></div>
<div class="van-hairline--top-bottom van-picker__frame" style="height: 44px;"></div>
</div>
<!---->
</div>
`;
+1
View File
@@ -195,6 +195,7 @@ export default {
|------|------|------|------|------|
| columns | 对象数组,配置每一列显示的数据 | `Array` | `[]` | - |
| show-toolbar | 是否显示顶部栏 | `Boolean` | `false` | - |
| toolbar-position | 顶部栏位置,可选值为`bottom` | `String` | `top` | 2.0.0 |
| title | 顶部栏标题 | `String` | `''` | - |
| loading | 是否显示加载状态 | `Boolean` | `false` | - |
| value-key | 选项对象中,文字对应的 key | `String` | `text` | - |