From 466345b79de83c82d30ce0cb357e5acc0bace21d Mon Sep 17 00:00:00 2001 From: haorwen Date: Sun, 21 Jun 2026 17:53:04 +0800 Subject: [PATCH] fix: defer wizard mount until version and tunnel info are both resolved --- package.json | 2 +- src/routes/onboarding/index.tsx | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 1fb23ead..15266a93 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vocechat-web", - "version": "0.9.84", + "version": "0.9.85", "homepage": "https://voce.chat", "dependencies": { "@metamask/onboarding": "^1.0.1", diff --git a/src/routes/onboarding/index.tsx b/src/routes/onboarding/index.tsx index c88fc2f0..5400daa3 100644 --- a/src/routes/onboarding/index.tsx +++ b/src/routes/onboarding/index.tsx @@ -64,8 +64,10 @@ export default function OnboardingPage() { const { data: autoInfo, isLoading: autoInfoLoading } = useGetAutoTunnelInfoQuery(undefined, { skip: !versionOk }); const showTunnelStep = versionOk && !!autoInfo && !autoInfo.auto_cftunnel; - // Wait for autoInfo before rendering Wizard so step count is stable from mount - if (versionOk && autoInfoLoading) return null; + // Wait until we know whether to show the tunnel step before mounting Wizard + // so step count is stable from mount + const ready = currentVersion && (!versionOk || autoInfo !== undefined); + if (!ready) return null; return ( <>