From a6bc6941d4ed23a49c0f7b66d5c45fdc1d142574 Mon Sep 17 00:00:00 2001 From: chenhang Date: Thu, 11 Jun 2026 15:58:48 +0800 Subject: [PATCH] refactor(splash): convert Skip to explicit guest login flow - Splash Skip button now dispatches `AuthGuestLoginSubmitted` instead of direct routing, keeping guest auth under the state machine - Update PWA install dialog copy ("Add to Home Screen") and drop favicon entry from manifest icons - Add debug logging and routing sequence docs to splash-button --- public/manifest.json | 6 -- .../chat/components/pwa-install-dialog.tsx | 6 +- src/app/splash/components/splash-button.tsx | 43 ++++++++---- src/app/splash/components/splash-screen.tsx | 50 ++++++++++++++ src/router/proxy.ts | 29 +++++++- src/stores/auth/auth-context.tsx | 5 +- src/stores/auth/auth-events.ts | 4 +- src/stores/auth/auth-machine.ts | 69 +++++++++++++------ src/stores/auth/oauth-session-sync.tsx | 24 +++++-- 9 files changed, 183 insertions(+), 53 deletions(-) diff --git a/public/manifest.json b/public/manifest.json index c5125b40..6f6ff9cd 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -10,12 +10,6 @@ "theme_color": "#f84d96", "lang": "en", "icons": [ - { - "src": "/favicon.ico", - "sizes": "any", - "type": "image/x-icon", - "purpose": "any" - }, { "src": "/images/splash/Icon-192.png", "sizes": "192x192", diff --git a/src/app/chat/components/pwa-install-dialog.tsx b/src/app/chat/components/pwa-install-dialog.tsx index 277f1028..afb32c1e 100644 --- a/src/app/chat/components/pwa-install-dialog.tsx +++ b/src/app/chat/components/pwa-install-dialog.tsx @@ -9,8 +9,6 @@ */ import Image from "next/image"; -import { AppConstants } from "@/core/constants/app_constants"; - import styles from "./pwa-install-dialog.module.css"; export interface PwaInstallDialogProps { @@ -48,10 +46,10 @@ export function PwaInstallDialog({ onClose, onInstall }: PwaInstallDialogProps) priority />

- Install {AppConstants.appTitle} + Add to Home Screen

- {AppConstants.appTitle} can be installed on your device for a faster, full-screen experience. + Add CozSweet to Home Screen{"\n"}for the best experience