Skip to content
This repository has been archived by the owner on Jun 3, 2021. It is now read-only.

[!] bugfix when with only two sliders #248

Merged
merged 1 commit into from
Apr 22, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/wxc-ep-slider/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@
let currentCardScale = 1;
let rightCardScale = this.cardS.scale;
let leftCardScale = this.cardS.scale;
const duration = (selectIndex === 0 && originIndex === this.cardLength - 1) ? 0.00001 : 300;
const duration = (selectIndex === 0 && originIndex === this.cardLength - 1 && this.cardLength !== 2) ? 0.00001 : 300;
this.$emit('wxcEpSliderCurrentIndexSelected', { currentIndex: selectIndex });
if (originIndex < selectIndex) {
currentCardScale = this.cardS.scale;
Expand Down