|
@@ -1,4 +1,4 @@
|
|
|
-import { defineComponent, reactive, watch } from "vue";
|
|
|
+import { defineComponent, nextTick, onMounted, reactive, watch } from "vue";
|
|
|
import styles from "./index.module.less";
|
|
|
import icons from "./icon/index.json";
|
|
|
import { headTopData } from "../../header-top";
|
|
@@ -18,20 +18,17 @@ export default defineComponent({
|
|
|
showPC: false,
|
|
|
showStudent: false,
|
|
|
showVip: false,
|
|
|
+ showTip: false,
|
|
|
});
|
|
|
const openGuid = () => {
|
|
|
// 加载后 判断 端口号 加载对应的引导
|
|
|
if (state.platform === IPlatform.PC) {
|
|
|
// PC
|
|
|
- setTimeout(() => {
|
|
|
- data.showPC = true;
|
|
|
- }, 500);
|
|
|
+ data.showPC = true;
|
|
|
} else {
|
|
|
if (storeData.user.vipMember) {
|
|
|
// 学生端
|
|
|
- setTimeout(() => {
|
|
|
- data.showStudent = true;
|
|
|
- }, 500);
|
|
|
+ data.showStudent = true;
|
|
|
} else {
|
|
|
// vip
|
|
|
data.showVip = true;
|
|
@@ -60,15 +57,20 @@ export default defineComponent({
|
|
|
}
|
|
|
}
|
|
|
);
|
|
|
-
|
|
|
- watch(
|
|
|
- () => headTopData.modeType,
|
|
|
- (val) => {
|
|
|
- if (val === "init") {
|
|
|
- openGuid();
|
|
|
- }
|
|
|
+ watch(() => headTopData.modeType, (val) => {
|
|
|
+ if (val === 'init'){
|
|
|
+ nextTick(() =>{
|
|
|
+ nextTick(() => {
|
|
|
+ setTimeout(() => {
|
|
|
+ data.showTip = true;
|
|
|
+ }, 500)
|
|
|
+ })
|
|
|
+ })
|
|
|
}
|
|
|
- );
|
|
|
+ })
|
|
|
+ onMounted(() => {
|
|
|
+ openGuid();
|
|
|
+ })
|
|
|
return () => (
|
|
|
<>
|
|
|
<div class={[styles.wrap, headTopData.modeType === "init" ? "" : styles.hidden]}>
|
|
@@ -89,9 +91,9 @@ export default defineComponent({
|
|
|
src={icons.icon_3}
|
|
|
/>
|
|
|
</div>
|
|
|
- {data.showPC && headTopData.modeType === "init" ? <TeacherBootom></TeacherBootom> : null}
|
|
|
- {data.showStudent && headTopData.modeType === "init" ? <StudentBottom></StudentBottom> : null}
|
|
|
- {data.showVip && headTopData.modeType === "init" && <TheVip />}
|
|
|
+ {data.showPC && data.showTip ? <TeacherBootom></TeacherBootom> : null}
|
|
|
+ {data.showStudent && data.showTip ? <StudentBottom></StudentBottom> : null}
|
|
|
+ {data.showVip && <TheVip />}
|
|
|
</div>
|
|
|
{headTopData.modeType === 'show' && state.modeType == 'practise' && state.fingeringInfo?.name && state.setting.displayFingering && <GuideIndex list={['detail']} />}
|
|
|
</>
|