feat(web): persistent workspace terminal across tab switches
This commit is contained in:
@@ -26,6 +26,7 @@ import {
|
||||
AlertDialogTitle,
|
||||
AlertDialogTrigger,
|
||||
Button,
|
||||
cn,
|
||||
Tabs,
|
||||
TabsContent,
|
||||
TabsList,
|
||||
@@ -681,11 +682,19 @@ export const AgentWorkspaceShell = ({ jobId }: { jobId: Id<'agentJobs'> }) => {
|
||||
</TabsContent>
|
||||
<TabsContent
|
||||
value='terminal'
|
||||
className='m-0 min-h-0 flex-1 overflow-hidden'
|
||||
forceMount
|
||||
className={cn(
|
||||
'm-0 min-h-0 flex-1 overflow-hidden',
|
||||
activeWorkspaceTab !== 'terminal' && 'hidden',
|
||||
)}
|
||||
>
|
||||
<WorkspaceTerminal
|
||||
jobId={jobId}
|
||||
active={activeWorkspaceTab === 'terminal' && workspaceReady}
|
||||
active={workspaceReady}
|
||||
visible={activeWorkspaceTab === 'terminal'}
|
||||
waitingLabel={
|
||||
workspacePending ? 'Waiting for workspace…' : undefined
|
||||
}
|
||||
/>
|
||||
</TabsContent>
|
||||
<TabsContent value='diff' className='m-0 min-h-0 flex-1'>
|
||||
|
||||
Reference in New Issue
Block a user