新增用户教程;减短开屏动画耗时
|
Before Width: | Height: | Size: 18 KiB After Width: | Height: | Size: 17 KiB |
|
Before Width: | Height: | Size: 20 KiB After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 32 KiB |
@@ -67,6 +67,9 @@
|
||||
},
|
||||
"pages/search": {
|
||||
"component": "search"
|
||||
},
|
||||
"pages/introduction": {
|
||||
"component": "introduction"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,63 @@
|
||||
<template>
|
||||
<div class="page">
|
||||
<image style="position: absolute; width: 100%; height: 100%" src={{current_src}} @click="StepClick"></image>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import router from "@system.router"
|
||||
export default {
|
||||
private: {
|
||||
current_step: 0,
|
||||
current_src: "/common/guides/circle/1_welcome.png",
|
||||
current_device_step_count: 0,
|
||||
steps_map: {
|
||||
circle: [
|
||||
"/common/guides/circle/1_welcome.png",
|
||||
"/common/guides/circle/2_switchPage.png",
|
||||
"/common/guides/circle/3_enterSearch.png",
|
||||
"/common/guides/circle/4_videoDetailMoreFeatures.png",
|
||||
"/common/guides/circle/5_replyMoreFeatures.png",
|
||||
],
|
||||
"pill-shaped": [
|
||||
"/common/guides/pill-shaped/1_welcome.png",
|
||||
"/common/guides/pill-shaped/2_switchPage.png",
|
||||
"/common/guides/pill-shaped/3_videoDetailMoreFeatures.png",
|
||||
],
|
||||
rect: []
|
||||
}
|
||||
},
|
||||
StepClick(){
|
||||
this.current_step++;
|
||||
if (this.current_step >= this.current_device_step_count) {
|
||||
router.replace({
|
||||
uri: "pages/main"
|
||||
});
|
||||
} else {
|
||||
this.UpdateImage();
|
||||
}
|
||||
},
|
||||
async UpdateImage(){
|
||||
const deviceinfo = await this.$app.$def.tools.getDeviceInformation();
|
||||
const shape = deviceinfo.screenShape;
|
||||
|
||||
this.steps = this.steps_map[shape] || [];
|
||||
this.current_device_step_count = this.steps.length;
|
||||
this.current_src = this.steps[this.current_step] || "";
|
||||
},
|
||||
onInit(){
|
||||
this.UpdateImage();
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.page {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
height: 100%;
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
}
|
||||
</style>
|
||||
@@ -36,7 +36,7 @@ export default {
|
||||
if (result.success) {
|
||||
console.log("登录成功")
|
||||
prompt.showToast({message: "登录成功"})
|
||||
router.replace({uri: "pages/main"})
|
||||
router.replace({uri: "pages/introduction"})
|
||||
clearInterval(this.qrpoll_interval)
|
||||
} else if (result.message.includes("登录失败")) {
|
||||
prompt.showToast({message: result.message, duration: 5000})
|
||||
|
||||
@@ -66,7 +66,7 @@ export default {
|
||||
setTimeout(() => {
|
||||
this.JumpCheck()
|
||||
}, 500)
|
||||
}, 2000)
|
||||
}, 1000)
|
||||
},
|
||||
onDestroy() {
|
||||
this.$app.$def.animengine.clearPageAnims("splashPage")
|
||||
|
||||