Commit da5fed19 authored by jyx's avatar jyx

优化样式

parent 7d089bb1
......@@ -59,8 +59,8 @@
<style lang="scss">
.container {
margin-top: -200rpx;
width: 600rpx;
height: 800rpx;
position: relative;
display: flex;
flex-direction: column;
......
......@@ -14,7 +14,7 @@
<text class="title">恭喜你,获得免费看剧名额</text>
<text class="button-ad" @click="handleAd">看视频免费解锁1集</text>
<text class="button-vip" @click="handleVip">免广告解锁</text>
<text class="downtext">{{countDown}}s后自动进入广告,观看完成解锁第{{vedioIndex+1}}集剧情</text>
<text v-show="showTime" class="downtext">{{countDown}}s后自动进入广告,观看完成解锁第{{vedioIndex+1}}集剧情</text>
</view>
</view>
</uni-popup>
......@@ -42,7 +42,8 @@
return {
adUnitId: EXPRESS_ID,
countDown: 3,
timer: ''
timer: '',
showTime: false
};
},
methods: {
......@@ -52,7 +53,7 @@
},
startCountdown() {
let that = this;
that.showTime = true
var countDownSeconds = 3
that.countDown = countDownSeconds
this.timer = setInterval(() => {
......@@ -65,17 +66,20 @@
}
}, 1000)
},
handleAd() {
handleAd() {
this.showTime = false
clearInterval(this.timer)
// this.$refs.adPop.close('center');
this.$emit('handleAd');
},
handleVip() {
handleVip() {
this.showTime = false
clearInterval(this.timer)
this.$refs.adPop.close();
this.$emit('handleVip');
},
onClose() {
onClose() {
this.showTime = false
clearInterval(this.timer)
this.$refs.adPop.close();
this.$emit('handleClose');
......@@ -95,7 +99,7 @@
handler: function(newVal, oldVal) {
if (newVal) {
this.handleShow();
} else {
} else {
try {
clearInterval(this.timer)
this.$refs.adPop.close();
......@@ -111,9 +115,9 @@
</script>
<style lang="scss">
.container {
.container {
margin-top: -200rpx;
width: 600rpx;
height: 800rpx;
position: relative;
display: flex;
flex-direction: column;
......
......@@ -624,10 +624,10 @@
} else {
message.notify("未观看完整视频")
that.$nextTick(() => {
// 延迟渲染,否则位置错乱
that.showCoinPop = true
})
// that.$nextTick(() => {
// // 延迟渲染,否则位置错乱
// that.showCoinPop = true
// })
}
});
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment