feat: enable WeChat share/forward on all pages via onShareAppMessage + onShareTimeline

This commit is contained in:
yuzhiran
2026-06-21 18:51:35 +08:00
parent 214571688c
commit d8fb8e3bba
13 changed files with 118 additions and 0 deletions
+10
View File
@@ -166,9 +166,19 @@
<script setup>
import { ref, computed, onMounted } from 'vue'
// #ifdef MP-WEIXIN
import { onShow, onShareAppMessage, onShareTimeline } from '@dcloudio/uni-app'
// #endif
// #ifndef MP-WEIXIN
import { onShow } from '@dcloudio/uni-app'
// #endif
import { api } from '../../config'
// #ifdef MP-WEIXIN
onShareAppMessage(() => ({ title: '职引 - 个人中心 | AI模拟面试', path: '/pages/user/user' }))
onShareTimeline(() => ({ title: '职引 - 个人中心 | AI模拟面试' }))
// #endif
const userInfo = ref({})
const isAdmin = ref(false)
const stats = ref({ interviewCount: 0, avgScore: '--', completedCount: 0 })