From e17a520599bb6f8df196a3e52b09ba6086013478 Mon Sep 17 00:00:00 2001 From: kuaifan Date: Sun, 14 Jun 2026 04:26:33 +0000 Subject: [PATCH] =?UTF-8?q?fix(micro-app):=20=E4=BF=AE=E5=A4=8D=20resolveT?= =?UTF-8?q?ype=20=E8=B0=83=E7=94=A8=E4=B8=8D=E5=AD=98=E5=9C=A8=E7=9A=84=20?= =?UTF-8?q?$A.platformType=20=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit $A 上从未定义 platformType 方法,resolveType 解析微应用类型时 必抛 "$A.platformType is not a function"。改用既有 $A.Platform 属性判断桌面端(web/mac/win),保持 desktop/mobile 语义不变。 Co-Authored-By: Claude Opus 4.8 (1M context) --- resources/assets/js/components/MicroApps/index.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/resources/assets/js/components/MicroApps/index.vue b/resources/assets/js/components/MicroApps/index.vue index 38da995e5..4d2d8e742 100644 --- a/resources/assets/js/components/MicroApps/index.vue +++ b/resources/assets/js/components/MicroApps/index.vue @@ -801,7 +801,8 @@ export default { ? type.mobile : (typeof type.app === 'string' ? type.app : defaultType) const desktopType = typeof type.desktop === 'string' ? type.desktop : defaultType - return $A.platformType() === 'desktop' ? desktopType : mobileType + const isDesktop = ['web', 'mac', 'win'].includes($A.Platform) + return isDesktop ? desktopType : mobileType } return 'inline' }