@@ -25,8 +25,8 @@ import { IChatWidgetService } from 'vs/workbench/contrib/chat/browser/chat';
25
25
import { IChatEditorOptions } from 'vs/workbench/contrib/chat/browser/chatEditor' ;
26
26
import { ChatEditorInput } from 'vs/workbench/contrib/chat/browser/chatEditorInput' ;
27
27
import { ChatViewPane } from 'vs/workbench/contrib/chat/browser/chatViewPane' ;
28
- import { IChatAgentService } from 'vs/workbench/contrib/chat/common/chatAgents' ;
29
- import { CONTEXT_CHAT_INPUT_CURSOR_AT_TOP , CONTEXT_CHAT_INPUT_HAS_AGENT , CONTEXT_CHAT_INPUT_HAS_TEXT , CONTEXT_CHAT_REQUEST_IN_PROGRESS , CONTEXT_IN_CHAT_INPUT , CONTEXT_IN_CHAT_SESSION , CONTEXT_PROVIDER_EXISTS , CONTEXT_REQUEST , CONTEXT_RESPONSE } from 'vs/workbench/contrib/chat/common/chatContextKeys' ;
28
+ import { ChatAgentLocation , IChatAgentService } from 'vs/workbench/contrib/chat/common/chatAgents' ;
29
+ import { CONTEXT_CHAT_INPUT_CURSOR_AT_TOP , CONTEXT_CHAT_INPUT_HAS_AGENT , CONTEXT_CHAT_INPUT_HAS_TEXT , CONTEXT_CHAT_LOCATION , CONTEXT_CHAT_REQUEST_IN_PROGRESS , CONTEXT_IN_CHAT_INPUT , CONTEXT_IN_CHAT_SESSION , CONTEXT_PROVIDER_EXISTS , CONTEXT_REQUEST , CONTEXT_RESPONSE } from 'vs/workbench/contrib/chat/common/chatContextKeys' ;
30
30
import { IChatContributionService } from 'vs/workbench/contrib/chat/common/chatContributionService' ;
31
31
import { chatAgentLeader } from 'vs/workbench/contrib/chat/common/chatParserTypes' ;
32
32
import { IChatDetail , IChatService } from 'vs/workbench/contrib/chat/common/chatService' ;
@@ -211,7 +211,7 @@ export function registerChatActions() {
211
211
super ( {
212
212
id : 'chat.action.focus' ,
213
213
title : localize2 ( 'actions.interactiveSession.focus' , 'Focus Chat List' ) ,
214
- precondition : CONTEXT_IN_CHAT_INPUT ,
214
+ precondition : ContextKeyExpr . and ( CONTEXT_IN_CHAT_INPUT , CONTEXT_CHAT_LOCATION . isEqualTo ( ChatAgentLocation . Panel ) ) ,
215
215
category : CHAT_CATEGORY ,
216
216
keybinding : [
217
217
// On mac, require that the cursor is at the top of the input, to avoid stealing cmd+up to move the cursor to the top
0 commit comments