feat: implement miniapp C-group pages with real API calls and design tokens

This commit is contained in:
Codex
2026-09-14 10:02:22 +08:00
parent bb380d40f6
commit 63cbbff2de
20 changed files with 300 additions and 23 deletions
+8 -1
View File
@@ -6,7 +6,14 @@
*/
const isDev = (function() {
try {
// 使用非废弃的 API(wx.getSystemInfoSync 在基础库 3.7.0+ 已废弃)
const accountInfo = typeof wx.getAccountInfoSync === 'function'
? wx.getAccountInfoSync()
: null;
if (accountInfo && accountInfo.miniProgram && accountInfo.miniProgram.envVersion === 'develop') {
return true;
}
// 兼容旧基础库与部分自动化运行环境。
const info = wx.getDeviceInfo ? wx.getDeviceInfo() : wx.getSystemInfoSync();
return info.platform === 'devtools';
} catch (e) {