修复小程序讲解内部返回控件
Some checks failed
CI / verify (push) Has been cancelled

This commit is contained in:
lyf
2026-07-28 14:42:02 +08:00
parent 2fb70fa1e3
commit 06ad609e1f
5 changed files with 19 additions and 9 deletions

View File

@@ -35,7 +35,7 @@
/>
<view class="hero-image-shade"></view>
<button
v-if="!shouldUseHostNavigation"
v-if="shouldShowDetailBack"
class="hero-back"
aria-label="返回上级"
@tap.stop="handleBack"
@@ -253,6 +253,9 @@ const detailTextLoadedByLanguage = ref<Record<AudioLanguage, boolean>>({
'en-US': false
})
const shouldUseHostNavigation = computed(() => isEmbeddedInWechatMiniProgram())
const shouldShowDetailBack = computed(() => (
!shouldUseHostNavigation.value || detailEntryRequest.value?.returnToGuideStopList === true
))
const isAudioLanguage = (value: unknown): value is AudioLanguage => (
value === 'zh-CN' || value === 'yue-HK' || value === 'en-US'