Skip to content

Commit 7153d9b

Browse files
author
云淇淋
authored
Merge pull request #1181 from CicholGricenchos/bugfix
修复Loadmore的transform样式导致的Popup定位错误
2 parents d8bb349 + c7cb534 commit 7153d9b

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

packages/loadmore/src/loadmore.vue

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<template>
22
<div class="mint-loadmore">
3-
<div class="mint-loadmore-content" :class="{ 'is-dropped': topDropped || bottomDropped}" :style="{ 'transform': 'translate3d(0, ' + translate + 'px, 0)' }">
3+
<div class="mint-loadmore-content" :class="{ 'is-dropped': topDropped || bottomDropped}" :style="{ 'transform': transform }">
44
<slot name="top">
55
<div class="mint-loadmore-top" v-if="topMethod">
66
<spinner v-if="topStatus === 'loading'" class="mint-loadmore-spinner" :size="20" type="fading-circle"></spinner>
@@ -140,6 +140,12 @@
140140
};
141141
},
142142
143+
computed: {
144+
transform() {
145+
return this.translate === 0 ? null : 'translate3d(0, ' + this.translate + 'px, 0)';
146+
}
147+
},
148+
143149
watch: {
144150
topStatus(val) {
145151
this.$emit('top-status-change', val);

0 commit comments

Comments
 (0)