Skip to content

🤯 LobeHub - Super-Agents on Your Team. Add super-agents to the chats your team already uses.They take on work by themselves and get better every week.

🐛 fix: restore window resizable before hard reload in desktop onboarding (#11144)

Innei25168745c904
diff --git a/src/app/[variants]/(desktop)/desktop-onboarding/index.tsx b/src/app/[variants]/(desktop)/desktop-onboarding/index.tsx
index 7a9b05aee26..505f44adff8 100644
--- a/src/app/[variants]/(desktop)/desktop-onboarding/index.tsx
+++ b/src/app/[variants]/(desktop)/desktop-onboarding/index.tsx
@@ -117,8 +117,14 @@ const DesktopOnboardingPage = memo(() => {
case 4: {
// 如果是第4步(LoginStep),完成 onboarding
setDesktopOnboardingCompleted();
- // Use hard reload instead of SPA navigation to ensure the app boots with the new desktop state.
- window.location.replace('/');
+ // Restore window resizable before hard reload (cleanup won't run due to hard navigation)
+ electronSystemService
+ .setWindowResizable({ resizable: true })
+ .catch(console.error)
+ .finally(() => {
+ // Use hard reload instead of SPA navigation to ensure the app boots with the new desktop state.
+ window.location.replace('/');
+ });
return prev;
}
default: {