feat: 添加隐私授权检查与处理逻辑,优化用户体验
This commit is contained in:
@@ -33,6 +33,13 @@ export class PageLoading extends Component {
|
||||
|
||||
this._updateStatusLabel('正在加载...');
|
||||
|
||||
// 阶段0: 主动触发微信隐私授权。分享挑战直达关卡时也会先经过这里。
|
||||
this._updateStatusLabel('正在确认隐私授权...');
|
||||
const privacyAuthorized = await WxSDK.ensurePrivacyAuthorized();
|
||||
if (!privacyAuthorized) {
|
||||
console.warn('[PageLoading] 用户未同意隐私授权,继续加载基础流程');
|
||||
}
|
||||
|
||||
// 阶段1: 登录 + 获取 game-data(含 nextLevel)
|
||||
this._updateProgress(0);
|
||||
this._updateStatusLabel('正在连接服务器...');
|
||||
|
||||
Reference in New Issue
Block a user