mirror of
https://github.com/stablyai/orca.git
synced 2026-10-23 00:03:52 +00:00
feat(native-chat): drop the standalone Chat session launcher
The QuickLaunch "Chat session" entry ("Start Codex without a terminal") was
scaffolding for testing the structured path, not a product surface. Shipping it
would introduce a second way to reach chat alongside the existing terminal
toggle, and then take it away again once the toggle routes codex to the
structured path — a surface that appears and disappears for exactly the
experimental users who would notice.
Structured chat now ships dormant: the store, journal, lease and app-server
transport are all present and exercised at startup, with no user-facing entry
point. The toggle users already know (right-click a codex tab -> Switch to chat
view, plus the pane menu, the pane shortcut, and the source-control surfaces)
becomes the single door in a follow-up, once a running CLI session can be
adopted into a structured one.
`useStructuredAgentSessionCreate` stays — adoption will call agentSession.create
through it. Only the menu entry and its now-unused imports go.
Verified: 1198 renderer tests, web typecheck, oxlint clean.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import React, { useCallback } from 'react'
|
||||
import { MessageSquare, Settings as SettingsIcon } from 'lucide-react'
|
||||
import { Settings as SettingsIcon } from 'lucide-react'
|
||||
import { toast } from 'sonner'
|
||||
import { DropdownMenuItem, DropdownMenuShortcut } from '@/components/ui/dropdown-menu'
|
||||
import { getAgentCatalog, AgentIcon } from '@/lib/agent-catalog'
|
||||
@@ -15,7 +15,6 @@ import {
|
||||
filterEnabledTuiAgents
|
||||
} from '../../../../shared/tui-agent-selection'
|
||||
import { translate } from '@/i18n/i18n'
|
||||
import { useStructuredAgentSessionCreate } from '../native-chat/use-structured-agent-session-create'
|
||||
|
||||
export type QuickLaunchAgentMenuItemsProps = {
|
||||
worktreeId: string
|
||||
@@ -117,7 +116,6 @@ function QuickLaunchAgentMenuItemsInner({
|
||||
const openSettingsPage = useAppStore((s) => s.openSettingsPage)
|
||||
const openSettingsTarget = useAppStore((s) => s.openSettingsTarget)
|
||||
const newAgentShortcut = useOptionalShortcutLabel('tab.newAgent')
|
||||
const structuredSession = useStructuredAgentSessionCreate(worktreeId)
|
||||
|
||||
const openAgentSettings = useCallback(() => {
|
||||
openSettingsTarget({ pane: 'agents', repoId: null })
|
||||
@@ -218,35 +216,6 @@ function QuickLaunchAgentMenuItemsInner({
|
||||
<DropdownMenuShortcut>{newAgentShortcut}</DropdownMenuShortcut>
|
||||
) : null}
|
||||
</DropdownMenuItem>
|
||||
{agent === 'codex' && structuredSession.supported ? (
|
||||
<DropdownMenuItem
|
||||
disabled={structuredSession.creating}
|
||||
onSelect={() => {
|
||||
void structuredSession.create().catch((error) => {
|
||||
toast.error(
|
||||
translate(
|
||||
'auto.components.tab.bar.QuickLaunchButton.f378201fbd',
|
||||
'Could not create chat session'
|
||||
),
|
||||
{ description: error instanceof Error ? error.message : String(error) }
|
||||
)
|
||||
})
|
||||
}}
|
||||
className="gap-2 rounded-[7px] px-2 py-1.5 pl-6 text-[12px] leading-5 font-medium"
|
||||
title={translate(
|
||||
'auto.components.tab.bar.QuickLaunchButton.a847779775',
|
||||
'Start Codex without a terminal'
|
||||
)}
|
||||
>
|
||||
<MessageSquare className="size-3.5 text-muted-foreground" />
|
||||
<span className="flex-1">
|
||||
{translate(
|
||||
'auto.components.tab.bar.QuickLaunchButton.0ea6a78efb',
|
||||
'Chat session'
|
||||
)}
|
||||
</span>
|
||||
</DropdownMenuItem>
|
||||
) : null}
|
||||
</React.Fragment>
|
||||
)
|
||||
})}
|
||||
|
||||
Reference in New Issue
Block a user