44 lines
709 B
Vue
44 lines
709 B
Vue
|
|
<template>
|
||
|
|
<section class="AiConsole">
|
||
|
|
<div class="vconsoleBtn" @click="$u.debounce(handleVConosle,500)"/>
|
||
|
|
</section>
|
||
|
|
</template>
|
||
|
|
|
||
|
|
<script>
|
||
|
|
export default {
|
||
|
|
name: "AiConsole",
|
||
|
|
data() {
|
||
|
|
return {
|
||
|
|
count: {},
|
||
|
|
}
|
||
|
|
},
|
||
|
|
methods: {
|
||
|
|
handleVConosle() {
|
||
|
|
if (this.count == 5) {
|
||
|
|
this.$injectLib("https://cdn.cunwuyun.cn/vconsole.min.js", () => {
|
||
|
|
new VConsole()
|
||
|
|
this.count++
|
||
|
|
})
|
||
|
|
} else {
|
||
|
|
this.count++
|
||
|
|
}
|
||
|
|
}
|
||
|
|
},
|
||
|
|
created() {
|
||
|
|
this.count = 0
|
||
|
|
}
|
||
|
|
}
|
||
|
|
</script>
|
||
|
|
|
||
|
|
<style lang="scss" scoped>
|
||
|
|
.AiConsole {
|
||
|
|
.vconsoleBtn {
|
||
|
|
position: fixed;
|
||
|
|
top: 0;
|
||
|
|
width: 60px;
|
||
|
|
height: 60px;
|
||
|
|
z-index: 202203181519;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
</style>
|