refactor(chat): launch external browser without dialog
This commit is contained in:
@@ -17,7 +17,6 @@ import {
|
||||
ChatInputBar,
|
||||
ChatInsufficientCreditsBanner,
|
||||
ChatUnlockDialogs,
|
||||
ExternalBrowserDialog,
|
||||
FirstRechargeOfferBanner,
|
||||
FullscreenImageViewer,
|
||||
PwaInstallOverlay,
|
||||
@@ -92,7 +91,7 @@ export function ChatScreen() {
|
||||
loginStatus: authState.loginStatus,
|
||||
});
|
||||
const shouldShowPwaInstall = state.historyLoaded && state.messages.length >= 10;
|
||||
const externalBrowserPrompt = useExternalBrowserPrompt({
|
||||
useExternalBrowserPrompt({
|
||||
hasInitialized: authState.hasInitialized,
|
||||
isLoading: authState.isLoading,
|
||||
loginStatus: authState.loginStatus,
|
||||
@@ -198,12 +197,6 @@ export function ChatScreen() {
|
||||
{/* PWA 安装提示触发器(聊天消息数量达到阈值后才允许弹出) */}
|
||||
<PwaInstallOverlay enabled={shouldShowPwaInstall} />
|
||||
|
||||
<ExternalBrowserDialog
|
||||
open={externalBrowserPrompt.open}
|
||||
onClose={externalBrowserPrompt.close}
|
||||
onConfirm={() => void externalBrowserPrompt.confirm()}
|
||||
/>
|
||||
|
||||
<ChatUnlockDialogs
|
||||
unlockPaywallRequest={unlockPaywallRequest}
|
||||
onCloseInsufficientCreditsDialog={closeInsufficientCreditsDialog}
|
||||
|
||||
Reference in New Issue
Block a user