mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
[Improvement] PullRefresh: support trigger loading animation (#684)
This commit is contained in:
parent
c45cbb632f
commit
4006a86cec
@ -45,7 +45,7 @@ export default {
|
||||
.van-pull-refresh {
|
||||
&,
|
||||
&__track {
|
||||
height: 100%;
|
||||
height: calc(100vh - 50px);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -76,10 +76,8 @@ export default create({
|
||||
|
||||
watch: {
|
||||
value(val) {
|
||||
if (!val) {
|
||||
this.duration = this.animationDuration;
|
||||
this.getStatus(0);
|
||||
}
|
||||
this.getStatus(val ? this.headHeight : 0, val);
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -4,7 +4,6 @@ import Toast from 'packages/toast';
|
||||
import { mount } from 'avoriaz';
|
||||
import { DOMChecker } from '../utils';
|
||||
import skuMockData from '../../docs/demos/mock/sku';
|
||||
import repeat from 'lodash/repeat';
|
||||
|
||||
const data = skuMockData['zh-CN'];
|
||||
const { skuHelper } = Sku;
|
||||
@ -13,6 +12,13 @@ const initialSku = {
|
||||
s1: '30349',
|
||||
s2: '1193'
|
||||
};
|
||||
const repeat = (str, count) => {
|
||||
let result = '';
|
||||
for (let i = 0; i < count; i++) {
|
||||
result += str;
|
||||
}
|
||||
return result;
|
||||
};
|
||||
|
||||
const File = function() {
|
||||
this.name = 'test';
|
||||
|
Loading…
x
Reference in New Issue
Block a user