在学习使用WeUI时,使用mp-loading设置type为dot-gray和dot-white时,页面展示的高度太小,和案例上给出的不一样
wxml:
<view>
<mp-loading animated="{{animated}}" duration="900" ext-class="demo0" type="dot-gray" show="{{loading_show}}" ></mp-loading>
<mp-loading type="dot-white" ext-class="demo1"></mp-loading>
</view>
js:
data:{
tips: '请稍后',
loading_show: true,
animated: true
},
onShow() {
this.timer = setInterval(() => {
this.setData({
loading_show: !this.data.loading_show,
})
}, 2000)
},
onUnload() {
clearInterval(this.timer)
}
还有就是设置了animated,动画也不显示,只是每隔2秒瞬间消失这样,这是怎么回事?
使用的版本是2.4.0
网友回复
社区技术运营专员-CJiang:
你好,先自行参考下文档:
https://developers.weixin.qq.com/miniprogram/dev/extended/weui/loading.html