mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
[Doc] Swipe: update custom indicator document (#1978)
This commit is contained in:
parent
a4b71aa402
commit
5564fbf624
@ -51,11 +51,9 @@
|
||||
<van-swipe-item>3</van-swipe-item>
|
||||
<van-swipe-item>4</van-swipe-item>
|
||||
|
||||
<template slot="indicator">
|
||||
<div class="custom-indicator">
|
||||
{{ this.current + 1 }}/4
|
||||
</div>
|
||||
</template>
|
||||
<div class="custom-indicator" slot="indicator">
|
||||
{{ current + 1 }}/4
|
||||
</div>
|
||||
</van-swipe>
|
||||
</demo-block>
|
||||
</demo-section>
|
||||
|
@ -97,11 +97,9 @@ export default {
|
||||
<van-swipe-item>3</van-swipe-item>
|
||||
<van-swipe-item>4</van-swipe-item>
|
||||
|
||||
<template slot="indicator">
|
||||
<div class="custom-indicator">
|
||||
{{ this.current + 1 }}/4
|
||||
</div>
|
||||
</template>
|
||||
<div class="custom-indicator" slot="indicator">
|
||||
{{ current + 1 }}/4
|
||||
</div>
|
||||
</van-swipe>
|
||||
```
|
||||
|
||||
@ -113,6 +111,7 @@ export default {
|
||||
current: 0
|
||||
}
|
||||
},
|
||||
|
||||
onChange(index) {
|
||||
this.current = index;
|
||||
}
|
||||
|
@ -22,7 +22,6 @@
|
||||
/>
|
||||
</div>
|
||||
</slot>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
@ -97,11 +97,9 @@ export default {
|
||||
<van-swipe-item>3</van-swipe-item>
|
||||
<van-swipe-item>4</van-swipe-item>
|
||||
|
||||
<template slot="indicator">
|
||||
<div class="custom-indicator">
|
||||
{{ this.current + 1 }}/4
|
||||
</div>
|
||||
</template>
|
||||
<div class="custom-indicator" slot="indicator">
|
||||
{{ current + 1 }}/4
|
||||
</div>
|
||||
</van-swipe>
|
||||
```
|
||||
|
||||
@ -113,6 +111,7 @@ export default {
|
||||
current: 0
|
||||
}
|
||||
},
|
||||
|
||||
onChange(index) {
|
||||
this.current = index;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user