mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
[bugfix] Picker: misspelling of visibleItemCount (#549)
This commit is contained in:
parent
d8dc44a780
commit
838c34578e
@ -25,6 +25,7 @@
|
||||
<van-datetime-picker
|
||||
v-model="currentDate3"
|
||||
type="time"
|
||||
:visibleItemCount="3"
|
||||
:min-hour="minHour"
|
||||
:max-hour="maxHour"
|
||||
:min-date="minDate"
|
||||
|
@ -69,7 +69,7 @@ export default {
|
||||
| max-date | Max date | `Date` | Ten years later on December 31 | - |
|
||||
| min-hour | Min hour | `Number` | `0` | - |
|
||||
| max-hour | Max hour | `Number` | `23` | - |
|
||||
| visibile-column-count | Count of columns to show | `Number` | `5` | - |
|
||||
| visible-item-count | Count of columns to show | `Number` | `5` | - |
|
||||
|
||||
### Event
|
||||
|
||||
|
@ -124,7 +124,7 @@ export default {
|
||||
| confirm-button-text | Text of confirm button | `String` | `Confirm` | - |
|
||||
| cancel-button-text | Text of cancel button | `String` | `Cancel` | - |
|
||||
| item-height | Option height | `Number` | `44` | - |
|
||||
| visibile-column-count | Count of visible columns | `Number` | `5` | - |
|
||||
| visible-item-count | Count of visible columns | `Number` | `5` | - |
|
||||
| value-key | Key of option text | `String` | `text` | - |
|
||||
|
||||
### Event
|
||||
|
@ -69,7 +69,7 @@ export default {
|
||||
| max-date | 可选的最大日期 | `Date` | 十年后的 12 月 31 日 | - |
|
||||
| min-hour | 可选的最小小时 | `Number` | `0` | - |
|
||||
| max-hour | 可选的最大小时 | `Number` | `23` | - |
|
||||
| visibile-column-count | 每一列可见备选元素的个数 | `Number` | `5` | - |
|
||||
| visible-item-count | 每一列可见备选元素的个数 | `Number` | `5` | - |
|
||||
|
||||
### Event
|
||||
|
||||
|
@ -126,7 +126,7 @@ export default {
|
||||
| confirm-button-text | 确认按钮文字 | `String` | `完成` | - |
|
||||
| cancel-button-text | 取消按钮文字 | `String` | `取消` | - |
|
||||
| item-height | 选项高度 | `Number` | `44` | - |
|
||||
| visibile-column-count | 可见的选项个数 | `Number` | `5` | - |
|
||||
| visible-item-count | 可见的选项个数 | `Number` | `5` | - |
|
||||
| value-key | 选项对象中,文字对应的 key | `String` | `text` | - |
|
||||
|
||||
### Event
|
||||
|
@ -40,7 +40,7 @@ export default create({
|
||||
type: Array,
|
||||
default: () => []
|
||||
},
|
||||
visibileColumnCount: {
|
||||
visibleItemCount: {
|
||||
type: Number,
|
||||
default: 5
|
||||
},
|
||||
@ -90,12 +90,12 @@ export default create({
|
||||
},
|
||||
|
||||
baseOffset() {
|
||||
return this.itemHeight * (this.visibileColumnCount - 1) / 2;
|
||||
return this.itemHeight * (this.visibleItemCount - 1) / 2;
|
||||
},
|
||||
|
||||
columnStyle() {
|
||||
return {
|
||||
height: (this.itemHeight * this.visibileColumnCount) + 'px'
|
||||
height: (this.itemHeight * this.visibleItemCount) + 'px'
|
||||
};
|
||||
},
|
||||
|
||||
|
@ -16,7 +16,7 @@
|
||||
:class-name="item.className"
|
||||
:default-index="item.defaultIndex"
|
||||
:item-height="itemHeight"
|
||||
:visibile-column-count="visibileColumnCount"
|
||||
:visible-item-count="visibleItemCount"
|
||||
@change="onChange(index)"
|
||||
/>
|
||||
<div class="van-picker__frame van-hairline--top-bottom" :style="frameStyle" />
|
||||
@ -41,7 +41,7 @@ export default create({
|
||||
showToolbar: Boolean,
|
||||
confirmButtonText: String,
|
||||
cancelButtonText: String,
|
||||
visibileColumnCount: Number,
|
||||
visibleItemCount: Number,
|
||||
valueKey: {
|
||||
type: String,
|
||||
default: 'text'
|
||||
|
Loading…
x
Reference in New Issue
Block a user