@codingame/monaco-vscode-chat-service-override 26.1.1 → 26.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCopyActions.js +4 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCustomizationDiagnosticsAction.d.ts +19 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatCustomizationDiagnosticsAction.js +209 -57
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatDeveloperActions.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatFileTreeActions.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatImportExport.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatLanguageModelActions.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatMoveActions.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatNewActions.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatPromptNavigationActions.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQueueActions.d.ts +33 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQueueActions.js +255 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatQuickInputActions.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolActions.js +11 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolPicker.js +12 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/codeBlockOperations.js +18 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.contribution.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsActions.js +51 -51
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsPicker.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsQuickAccess.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjection.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjectionActions.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionProjectionService.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentSessionsExperiments.contribution.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/agentTitleBarStatusWidget.js +24 -24
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/unifiedQuickAccess.js +17 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/experiments/unifiedQuickAccessActions.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentResolveService.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/simpleBrowserEditorOverlay.js +19 -19
- package/vscode/src/vs/workbench/contrib/chat/browser/chat.contribution.js +329 -145
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingCodeEditorIntegration.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingExplanationModelManager.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedDocumentEntry.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedFileEntry.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingModifiedNotebookEntry.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingServiceImpl.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingSession.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/notebook/chatEditingNotebookEditorIntegration.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagement.contribution.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditor.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatManagementEditorInput.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsViewModel.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.js +51 -51
- package/vscode/src/vs/workbench/contrib/chat/browser/chatManagement/chatUsageWidget.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/chatOutputItemRenderer.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/chatParticipant.contribution.js +30 -30
- package/vscode/src/vs/workbench/contrib/chat/browser/chatRepoInfo.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupContributions.js +16 -16
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupController.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupProviders.js +24 -24
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSetup/chatSetupRunner.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusDashboard.js +58 -58
- package/vscode/src/vs/workbench/contrib/chat/browser/chatStatus/chatStatusEntry.js +12 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/chatTipService.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/chatWindowNotifier.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/chatModeActions.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookActions.d.ts +10 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookActions.js +591 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookUtils.d.ts +48 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/hookUtils.js +162 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptCodingAgentActionOverlay.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptFileActions.js +2 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptToolsCodeLensProvider.js +30 -15
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/promptUrlHandler.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/runPromptAction.js +7 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/saveAsPromptFileActions.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/skillActions.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsConfirmationService.js +31 -31
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsService.d.ts +24 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/languageModelToolsService.js +251 -72
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolSetsContribution.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewsWelcomeHandler.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatQueuePickerActionItem.d.ts +45 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatQueuePickerActionItem.js +191 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatStatusWidget.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputCompletions.js +13 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputEditorHover.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/chatQuick.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/editor/chatEditor.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewPane.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatViewTitleControl.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceImpl.d.ts +19 -3
- package/vscode/src/vs/workbench/contrib/chat/common/chatService/chatServiceImpl.js +203 -25
- package/vscode/src/vs/workbench/contrib/chat/common/model/chatProgressTypes/chatToolInvocation.d.ts +18 -2
- package/vscode/src/vs/workbench/contrib/chat/common/model/chatProgressTypes/chatToolInvocation.js +50 -6
- package/vscode/src/vs/workbench/contrib/chat/common/model/chatSessionOperationLog.js +11 -1
- package/vscode/src/vs/workbench/contrib/chat/common/model/chatSessionStore.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/chatPromptFilesContribution.js +23 -17
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/hookClaudeCompat.d.ts +63 -0
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/hookClaudeCompat.js +121 -0
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/hookCompatibility.d.ts +76 -0
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/hookCompatibility.js +120 -0
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/hookCopilotCliCompat.d.ts +15 -0
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/hookCopilotCliCompat.js +27 -0
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptCodeActions.js +22 -11
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptDocumentSemanticTokensProvider.js +3 -2
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHeaderAutocompletion.js +135 -54
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptHovers.js +64 -43
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/promptFileContributions.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.d.ts +24 -5
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/service/promptsServiceImpl.js +341 -24
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.d.ts +12 -5
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/utils/promptFilesLocator.js +95 -26
- package/vscode/src/vs/workbench/contrib/chat/common/voiceChatService.js +1 -1
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChat.contribution.js +4 -4
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatActions.js +8 -8
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatDefaultModel.js +6 -6
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionServiceImpl.js +8 -8
- package/vscode/src/vs/workbench/contrib/mcp/browser/mcpPromptArgumentPick.js +14 -14
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/chat/notebookChatUtils.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/cellChatActions.js +10 -10
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebook.chat.contribution.js +5 -5
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/chat/notebookChatContext.js +1 -1
- package/vscode/src/vs/workbench/contrib/remoteCodingAgents/browser/remoteCodingAgents.contribution.js +7 -7
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatAccessibilityHelp.js +16 -16
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatActions.js +20 -20
- package/vscode/src/vs/workbench/contrib/terminalContrib/chat/browser/terminalChatWidget.js +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.js +6 -6
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/terminal.chatAgentTools.contribution.js +3 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/awaitTerminalTool.js +3 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/autoApprove/npmScriptAutoApprover.js +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.js +12 -12
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineFileWriteAnalyzer.js +2 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalLastCommandTool.js +3 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalOutputTool.js +3 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/getTerminalSelectionTool.js +3 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/killTerminalTool.js +3 -3
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.js +8 -8
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalConfirmationTool.js +2 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.js +14 -13
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/createAndRunTaskTool.js +14 -14
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/getTaskOutputTool.js +7 -7
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/runTaskTool.js +14 -14
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/task/taskHelpers.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.d.ts +0 -63
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/languageProviders/promptValidator.js +0 -955
|
@@ -78,7 +78,7 @@ function createToolSetTreeItem(toolset, checked, editorService) {
|
|
|
78
78
|
const resource = toolset.source.file;
|
|
79
79
|
buttons.push({
|
|
80
80
|
iconClass: ThemeIcon.asClassName(Codicon.edit),
|
|
81
|
-
tooltip: ( localize(
|
|
81
|
+
tooltip: ( localize(4878, "Edit Tool Set")),
|
|
82
82
|
action: () => editorService.openEditor({
|
|
83
83
|
resource
|
|
84
84
|
})
|
|
@@ -164,7 +164,7 @@ async function showToolsPicker(accessor, placeHolder, source, description, getTo
|
|
|
164
164
|
if (collection?.source) {
|
|
165
165
|
buttons.push({
|
|
166
166
|
iconClass: ThemeIcon.asClassName(Codicon.settingsGear),
|
|
167
|
-
tooltip: ( localize(
|
|
167
|
+
tooltip: ( localize(4879, "Configure {0}", collection.label)),
|
|
168
168
|
action: () => collection.source ? collection.source instanceof ExtensionIdentifier ? extensionsWorkbenchService.open(collection.source.value, {
|
|
169
169
|
tab: ExtensionEditorTab.Features,
|
|
170
170
|
feature: "mcp"
|
|
@@ -175,7 +175,7 @@ async function showToolsPicker(accessor, placeHolder, source, description, getTo
|
|
|
175
175
|
} else if (collection?.presentation?.origin) {
|
|
176
176
|
buttons.push({
|
|
177
177
|
iconClass: ThemeIcon.asClassName(Codicon.settingsGear),
|
|
178
|
-
tooltip: ( localize(
|
|
178
|
+
tooltip: ( localize(4879, "Configure {0}", collection.label)),
|
|
179
179
|
action: () => editorService.openEditor({
|
|
180
180
|
resource: collection.presentation.origin
|
|
181
181
|
})
|
|
@@ -184,7 +184,7 @@ async function showToolsPicker(accessor, placeHolder, source, description, getTo
|
|
|
184
184
|
if (mcpServer.connectionState.get().state === McpConnectionState.Kind.Error) {
|
|
185
185
|
buttons.push({
|
|
186
186
|
iconClass: ThemeIcon.asClassName(Codicon.warning),
|
|
187
|
-
tooltip: ( localize(
|
|
187
|
+
tooltip: ( localize(4880, "Show Output")),
|
|
188
188
|
action: () => mcpServer.showOutput()
|
|
189
189
|
});
|
|
190
190
|
}
|
|
@@ -196,7 +196,7 @@ async function showToolsPicker(accessor, placeHolder, source, description, getTo
|
|
|
196
196
|
children.push({
|
|
197
197
|
itemType: "callback",
|
|
198
198
|
iconClass: ThemeIcon.asClassName(Codicon.sync),
|
|
199
|
-
label: ( localize(
|
|
199
|
+
label: ( localize(4881, "Update Tools")),
|
|
200
200
|
pickable: false,
|
|
201
201
|
run: () => {
|
|
202
202
|
treePicker.busy = true;
|
|
@@ -252,7 +252,7 @@ async function showToolsPicker(accessor, placeHolder, source, description, getTo
|
|
|
252
252
|
itemType: "bucket",
|
|
253
253
|
ordinal: BucketOrdinal.BuiltIn,
|
|
254
254
|
id: key,
|
|
255
|
-
label: ( localize(
|
|
255
|
+
label: ( localize(4882, "Built-In")),
|
|
256
256
|
checked: undefined,
|
|
257
257
|
children: [],
|
|
258
258
|
buttons: [],
|
|
@@ -264,7 +264,7 @@ async function showToolsPicker(accessor, placeHolder, source, description, getTo
|
|
|
264
264
|
itemType: "bucket",
|
|
265
265
|
ordinal: BucketOrdinal.User,
|
|
266
266
|
id: key,
|
|
267
|
-
label: ( localize(
|
|
267
|
+
label: ( localize(4883, "User Defined Tool Sets")),
|
|
268
268
|
checked: undefined,
|
|
269
269
|
children: [],
|
|
270
270
|
buttons: [],
|
|
@@ -356,7 +356,7 @@ async function showToolsPicker(accessor, placeHolder, source, description, getTo
|
|
|
356
356
|
}
|
|
357
357
|
}
|
|
358
358
|
if (treeItems.length === 0) {
|
|
359
|
-
treePicker.placeholder = ( localize(
|
|
359
|
+
treePicker.placeholder = ( localize(4884, "Add tools to chat"));
|
|
360
360
|
} else {
|
|
361
361
|
treePicker.placeholder = placeHolder;
|
|
362
362
|
}
|
|
@@ -416,17 +416,17 @@ async function showToolsPicker(accessor, placeHolder, source, description, getTo
|
|
|
416
416
|
}));
|
|
417
417
|
const addMcpServerButton = {
|
|
418
418
|
iconClass: ThemeIcon.asClassName(Codicon.mcp),
|
|
419
|
-
tooltip: ( localize(
|
|
419
|
+
tooltip: ( localize(4885, "Add MCP Server..."))
|
|
420
420
|
};
|
|
421
421
|
const installExtension = {
|
|
422
422
|
iconClass: ThemeIcon.asClassName(Codicon.extensions),
|
|
423
|
-
tooltip: ( localize(
|
|
423
|
+
tooltip: ( localize(4886, "Install Extension..."))
|
|
424
424
|
};
|
|
425
425
|
const configureToolSets = {
|
|
426
426
|
iconClass: ThemeIcon.asClassName(Codicon.gear),
|
|
427
|
-
tooltip: ( localize(
|
|
427
|
+
tooltip: ( localize(4887, "Configure Tool Sets..."))
|
|
428
428
|
};
|
|
429
|
-
treePicker.title = ( localize(
|
|
429
|
+
treePicker.title = ( localize(4888, "Configure Tools"));
|
|
430
430
|
treePicker.buttons = [addMcpServerButton, installExtension, configureToolSets];
|
|
431
431
|
store.add(treePicker.onDidTriggerButton(button => {
|
|
432
432
|
if (button === addMcpServerButton) {
|
|
@@ -65,7 +65,7 @@ let InsertCodeBlockOperation = class InsertCodeBlockOperation {
|
|
|
65
65
|
await this.handleNotebookEditor(activeNotebookEditor, context);
|
|
66
66
|
} else {
|
|
67
67
|
this.notify(( localize(
|
|
68
|
-
|
|
68
|
+
4889,
|
|
69
69
|
"To insert the code block, open a code editor or notebook editor and set the cursor at the location where to insert the code block."
|
|
70
70
|
)));
|
|
71
71
|
}
|
|
@@ -98,7 +98,7 @@ let InsertCodeBlockOperation = class InsertCodeBlockOperation {
|
|
|
98
98
|
}
|
|
99
99
|
async handleNotebookEditor(notebookEditor, codeBlockContext) {
|
|
100
100
|
if (notebookEditor.isReadOnly) {
|
|
101
|
-
this.notify(( localize(
|
|
101
|
+
this.notify(( localize(4890, "Cannot insert the code block to read-only notebook editor.")));
|
|
102
102
|
return false;
|
|
103
103
|
}
|
|
104
104
|
const focusRange = notebookEditor.getFocus();
|
|
@@ -117,7 +117,7 @@ let InsertCodeBlockOperation = class InsertCodeBlockOperation {
|
|
|
117
117
|
async handleTextEditor(codeEditor, codeBlockContext) {
|
|
118
118
|
const activeModel = codeEditor.getModel();
|
|
119
119
|
if (isReadOnly(activeModel, this.textFileService)) {
|
|
120
|
-
this.notify(( localize(
|
|
120
|
+
this.notify(( localize(4891, "Cannot insert the code block to read-only code editor.")));
|
|
121
121
|
return false;
|
|
122
122
|
}
|
|
123
123
|
const range = codeEditor.getSelection() ?? ( new Range(activeModel.getLineCount(), 1, activeModel.getLineCount(), 1));
|
|
@@ -179,7 +179,7 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
179
179
|
this.tryToRevealCodeBlock(codeEditor, context.code);
|
|
180
180
|
activeEditorControl = codeEditor;
|
|
181
181
|
} else {
|
|
182
|
-
this.notify(( localize(
|
|
182
|
+
this.notify(( localize(4892, "Failed to open {0} in a code editor.", (codemapperUri.toString()))));
|
|
183
183
|
return;
|
|
184
184
|
}
|
|
185
185
|
} catch (e) {
|
|
@@ -211,7 +211,7 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
211
211
|
if (activeNotebookEditor) {
|
|
212
212
|
result = await this.handleNotebookEditor(activeNotebookEditor, context.chatSessionResource, context.code);
|
|
213
213
|
} else {
|
|
214
|
-
this.notify(( localize(
|
|
214
|
+
this.notify(( localize(4893, "To apply this code block, open a code or notebook editor.")));
|
|
215
215
|
}
|
|
216
216
|
}
|
|
217
217
|
if (isResponseVM(context.element)) {
|
|
@@ -235,7 +235,7 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
235
235
|
}
|
|
236
236
|
const activeEditorOption = activeEditorControl?.getModel().uri ? {
|
|
237
237
|
label: ( localize(
|
|
238
|
-
|
|
238
|
+
4894,
|
|
239
239
|
"Active editor '{0}'",
|
|
240
240
|
this.labelService.getUriLabel(activeEditorControl.getModel().uri, {
|
|
241
241
|
relative: true
|
|
@@ -244,13 +244,13 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
244
244
|
id: "activeEditor"
|
|
245
245
|
} : undefined;
|
|
246
246
|
const untitledEditorOption = {
|
|
247
|
-
label: ( localize(
|
|
247
|
+
label: ( localize(4895, "New untitled editor")),
|
|
248
248
|
id: "newUntitledFile"
|
|
249
249
|
};
|
|
250
250
|
const options = [];
|
|
251
251
|
if (resource) {
|
|
252
252
|
options.push({
|
|
253
|
-
label: ( localize(
|
|
253
|
+
label: ( localize(4896, "New file '{0}'", this.labelService.getUriLabel(resource, {
|
|
254
254
|
relative: true
|
|
255
255
|
}))),
|
|
256
256
|
id: "createFile"
|
|
@@ -266,7 +266,7 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
266
266
|
options.push(untitledEditorOption);
|
|
267
267
|
}
|
|
268
268
|
const selected = options.length > 1 ? await this.quickInputService.pick(options, {
|
|
269
|
-
placeHolder: ( localize(
|
|
269
|
+
placeHolder: ( localize(4897, "Select where to apply the code block"))
|
|
270
270
|
}) : options[0];
|
|
271
271
|
if (selected) {
|
|
272
272
|
switch (selected.id) {
|
|
@@ -275,7 +275,7 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
275
275
|
try {
|
|
276
276
|
await this.fileService.writeFile(resource, VSBuffer.fromString(""));
|
|
277
277
|
} catch (error) {
|
|
278
|
-
this.notify(( localize(
|
|
278
|
+
this.notify(( localize(4898, "Failed to create file: {0}", error.message)));
|
|
279
279
|
return ( URI.from({
|
|
280
280
|
scheme: "untitled",
|
|
281
281
|
path: resource.path
|
|
@@ -296,7 +296,7 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
296
296
|
}
|
|
297
297
|
async handleNotebookEditor(notebookEditor, chatSessionResource, code) {
|
|
298
298
|
if (notebookEditor.isReadOnly) {
|
|
299
|
-
this.notify(( localize(
|
|
299
|
+
this.notify(( localize(4899, "Cannot apply code block to read-only notebook editor.")));
|
|
300
300
|
return undefined;
|
|
301
301
|
}
|
|
302
302
|
const uri = notebookEditor.textModel.uri;
|
|
@@ -307,7 +307,7 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
307
307
|
};
|
|
308
308
|
const codeMapper = this.codeMapperService.providers[0]?.displayName;
|
|
309
309
|
if (!codeMapper) {
|
|
310
|
-
this.notify(( localize(
|
|
310
|
+
this.notify(( localize(4900, "No code mapper available.")));
|
|
311
311
|
return undefined;
|
|
312
312
|
}
|
|
313
313
|
let editsProposed = false;
|
|
@@ -320,7 +320,7 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
320
320
|
cancellable: true
|
|
321
321
|
}, async progress => {
|
|
322
322
|
progress.report({
|
|
323
|
-
message: ( localize(
|
|
323
|
+
message: ( localize(4901, "Applying code block using {0}...", codeMapper))
|
|
324
324
|
});
|
|
325
325
|
const editsIterable = this.getNotebookEdits(codeBlock, chatSessionResource, cancellationTokenSource.token);
|
|
326
326
|
return await this.waitForFirstElement(editsIterable);
|
|
@@ -328,7 +328,7 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
328
328
|
editsProposed = await this.applyNotebookEditsWithInlinePreview(iterable, uri, cancellationTokenSource);
|
|
329
329
|
} catch (e) {
|
|
330
330
|
if (!isCancellationError(e)) {
|
|
331
|
-
this.notify(( localize(
|
|
331
|
+
this.notify(( localize(4902, "Failed to apply code block: {0}", e.message)));
|
|
332
332
|
}
|
|
333
333
|
} finally {
|
|
334
334
|
cancellationTokenSource.dispose();
|
|
@@ -341,7 +341,7 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
341
341
|
async handleTextEditor(codeEditor, chatSessionResource, code, applyCodeBlockSuggestionId) {
|
|
342
342
|
const activeModel = codeEditor.getModel();
|
|
343
343
|
if (isReadOnly(activeModel, this.textFileService)) {
|
|
344
|
-
this.notify(( localize(
|
|
344
|
+
this.notify(( localize(4903, "Cannot apply code block to read-only file.")));
|
|
345
345
|
return undefined;
|
|
346
346
|
}
|
|
347
347
|
const codeBlock = {
|
|
@@ -352,7 +352,7 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
352
352
|
};
|
|
353
353
|
const codeMapper = this.codeMapperService.providers[0]?.displayName;
|
|
354
354
|
if (!codeMapper) {
|
|
355
|
-
this.notify(( localize(
|
|
355
|
+
this.notify(( localize(4900, "No code mapper available.")));
|
|
356
356
|
return undefined;
|
|
357
357
|
}
|
|
358
358
|
let editsProposed = false;
|
|
@@ -365,7 +365,7 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
365
365
|
cancellable: true
|
|
366
366
|
}, async progress => {
|
|
367
367
|
progress.report({
|
|
368
|
-
message: ( localize(
|
|
368
|
+
message: ( localize(4901, "Applying code block using {0}...", codeMapper))
|
|
369
369
|
});
|
|
370
370
|
const editsIterable = this.getTextEdits(codeBlock, chatSessionResource, cancellationTokenSource.token);
|
|
371
371
|
return await this.waitForFirstElement(editsIterable);
|
|
@@ -373,7 +373,7 @@ let ApplyCodeBlockOperation = class ApplyCodeBlockOperation {
|
|
|
373
373
|
editsProposed = await this.applyWithInlinePreview(iterable, codeEditor, cancellationTokenSource, applyCodeBlockSuggestionId);
|
|
374
374
|
} catch (e) {
|
|
375
375
|
if (!isCancellationError(e)) {
|
|
376
|
-
this.notify(( localize(
|
|
376
|
+
this.notify(( localize(4902, "Failed to apply code block: {0}", e.message)));
|
|
377
377
|
}
|
|
378
378
|
} finally {
|
|
379
379
|
cancellationTokenSource.dispose();
|
package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessions.contribution.js
CHANGED
|
@@ -44,7 +44,7 @@ registerAction2(SetAgentSessionsOrientationStackedAction);
|
|
|
44
44
|
registerAction2(SetAgentSessionsOrientationSideBySideAction);
|
|
45
45
|
MenuRegistry.appendMenuItem(MenuId.AgentSessionsToolbar, {
|
|
46
46
|
submenu: MenuId.AgentSessionsViewerFilterSubMenu,
|
|
47
|
-
title: ( localize2(
|
|
47
|
+
title: ( localize2(4911, "Filter Agent Sessions")),
|
|
48
48
|
group: "navigation",
|
|
49
49
|
order: 3,
|
|
50
50
|
icon: Codicon.filter
|
|
@@ -114,9 +114,9 @@ MenuRegistry.appendMenuItem(MenuId.ChatViewSessionTitleToolbar, {
|
|
|
114
114
|
prefix: AGENT_SESSIONS_QUICK_ACCESS_PREFIX,
|
|
115
115
|
contextKey: "inAgentSessionsPicker",
|
|
116
116
|
when: ChatContextKeys.enabled,
|
|
117
|
-
placeholder: ( localize(
|
|
117
|
+
placeholder: ( localize(4912, "Search agent sessions by name")),
|
|
118
118
|
helpEntries: [{
|
|
119
|
-
description: ( localize(
|
|
119
|
+
description: ( localize(4913, "Show All Agent Sessions")),
|
|
120
120
|
commandId: "workbench.action.chat.history"
|
|
121
121
|
}]
|
|
122
122
|
});
|
|
@@ -33,12 +33,12 @@ import { coalesce } from '@codingame/monaco-vscode-api/vscode/vs/base/common/arr
|
|
|
33
33
|
import { StorageScope, StorageTarget } from '@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage';
|
|
34
34
|
import { IStorageService } from '@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service';
|
|
35
35
|
|
|
36
|
-
const AGENT_SESSIONS_CATEGORY = ( localize2(
|
|
36
|
+
const AGENT_SESSIONS_CATEGORY = ( localize2(4925, "Chat Agent Sessions"));
|
|
37
37
|
class ToggleShowAgentSessionsAction extends Action2 {
|
|
38
38
|
constructor() {
|
|
39
39
|
super({
|
|
40
40
|
id: "workbench.action.chat.toggleShowAgentSessions",
|
|
41
|
-
title: ( localize2(
|
|
41
|
+
title: ( localize2(4926, "Show Sessions")),
|
|
42
42
|
toggled: ( ContextKeyExpr.equals(`config.${ChatConfiguration.ChatViewSessionsEnabled}`, true)),
|
|
43
43
|
menu: {
|
|
44
44
|
id: MenuId.ChatWelcomeContext,
|
|
@@ -57,7 +57,7 @@ class ToggleShowAgentSessionsAction extends Action2 {
|
|
|
57
57
|
const agentSessionsOrientationSubmenu = ( new MenuId("chatAgentSessionsOrientationSubmenu"));
|
|
58
58
|
MenuRegistry.appendMenuItem(MenuId.ChatWelcomeContext, {
|
|
59
59
|
submenu: agentSessionsOrientationSubmenu,
|
|
60
|
-
title: ( localize2(
|
|
60
|
+
title: ( localize2(4927, "Sessions Orientation")),
|
|
61
61
|
group: "0_sessions",
|
|
62
62
|
order: 1,
|
|
63
63
|
when: ( ChatContextKeys.inChatEditor.negate())
|
|
@@ -66,7 +66,7 @@ class SetAgentSessionsOrientationStackedAction extends Action2 {
|
|
|
66
66
|
constructor() {
|
|
67
67
|
super({
|
|
68
68
|
id: "workbench.action.chat.setAgentSessionsOrientationStacked",
|
|
69
|
-
title: ( localize2(
|
|
69
|
+
title: ( localize2(4928, "Stacked")),
|
|
70
70
|
toggled: ( ContextKeyExpr.equals(`config.${ChatConfiguration.ChatViewSessionsOrientation}`, "stacked")),
|
|
71
71
|
precondition: ( ContextKeyExpr.and(( ContextKeyExpr.equals(`config.${ChatConfiguration.ChatViewSessionsEnabled}`, true)), ( AuxiliaryBarMaximizedContext.negate()))),
|
|
72
72
|
menu: {
|
|
@@ -85,7 +85,7 @@ class SetAgentSessionsOrientationSideBySideAction extends Action2 {
|
|
|
85
85
|
constructor() {
|
|
86
86
|
super({
|
|
87
87
|
id: "workbench.action.chat.setAgentSessionsOrientationSideBySide",
|
|
88
|
-
title: ( localize2(
|
|
88
|
+
title: ( localize2(4929, "Side by Side")),
|
|
89
89
|
toggled: ( ContextKeyExpr.notEquals(`config.${ChatConfiguration.ChatViewSessionsOrientation}`, "stacked")),
|
|
90
90
|
precondition: ( ContextKeyExpr.and(( ContextKeyExpr.equals(`config.${ChatConfiguration.ChatViewSessionsEnabled}`, true)), ( AuxiliaryBarMaximizedContext.negate()))),
|
|
91
91
|
menu: {
|
|
@@ -104,7 +104,7 @@ class PickAgentSessionAction extends Action2 {
|
|
|
104
104
|
constructor() {
|
|
105
105
|
super({
|
|
106
106
|
id: `workbench.action.chat.history`,
|
|
107
|
-
title: ( localize2(
|
|
107
|
+
title: ( localize2(4930, "Open Agent Session...")),
|
|
108
108
|
menu: [{
|
|
109
109
|
id: MenuId.ViewTitle,
|
|
110
110
|
when: ( ContextKeyExpr.and(( ContextKeyExpr.equals("view", ChatViewId)), ( ContextKeyExpr.equals(`config.${ChatConfiguration.ChatViewSessionsEnabled}`, false)))),
|
|
@@ -130,7 +130,7 @@ class ArchiveAllAgentSessionsAction extends Action2 {
|
|
|
130
130
|
constructor() {
|
|
131
131
|
super({
|
|
132
132
|
id: "workbench.action.chat.archiveAllAgentSessions",
|
|
133
|
-
title: ( localize2(
|
|
133
|
+
title: ( localize2(4931, "Archive All Workspace Agent Sessions")),
|
|
134
134
|
precondition: ChatContextKeys.enabled,
|
|
135
135
|
category: AGENT_SESSIONS_CATEGORY,
|
|
136
136
|
f1: true
|
|
@@ -144,13 +144,13 @@ class ArchiveAllAgentSessionsAction extends Action2 {
|
|
|
144
144
|
return;
|
|
145
145
|
}
|
|
146
146
|
const confirmed = await dialogService.confirm({
|
|
147
|
-
message: sessionsToArchive.length === 1 ? ( localize(
|
|
148
|
-
|
|
147
|
+
message: sessionsToArchive.length === 1 ? ( localize(4932, "Are you sure you want to archive 1 agent session?")) : ( localize(
|
|
148
|
+
4933,
|
|
149
149
|
"Are you sure you want to archive {0} agent sessions?",
|
|
150
150
|
sessionsToArchive.length
|
|
151
151
|
)),
|
|
152
|
-
detail: ( localize(
|
|
153
|
-
primaryButton: ( localize(
|
|
152
|
+
detail: ( localize(4934, "You can unarchive sessions later if needed from the Chat view.")),
|
|
153
|
+
primaryButton: ( localize(4935, "Archive"))
|
|
154
154
|
});
|
|
155
155
|
if (!confirmed.confirmed) {
|
|
156
156
|
return;
|
|
@@ -164,7 +164,7 @@ class MarkAllAgentSessionsReadAction extends Action2 {
|
|
|
164
164
|
constructor() {
|
|
165
165
|
super({
|
|
166
166
|
id: "workbench.action.chat.markAllAgentSessionsRead",
|
|
167
|
-
title: ( localize2(
|
|
167
|
+
title: ( localize2(4936, "Mark All as Read")),
|
|
168
168
|
precondition: ChatContextKeys.enabled,
|
|
169
169
|
category: AGENT_SESSIONS_CATEGORY,
|
|
170
170
|
f1: true,
|
|
@@ -192,7 +192,7 @@ class ArchiveAgentSessionSectionAction extends Action2 {
|
|
|
192
192
|
constructor() {
|
|
193
193
|
super({
|
|
194
194
|
id: "agentSessionSection.archive",
|
|
195
|
-
title: ( localize2(
|
|
195
|
+
title: ( localize2(4937, "Archive All")),
|
|
196
196
|
icon: Codicon.archive,
|
|
197
197
|
menu: [{
|
|
198
198
|
id: MenuId.AgentSessionSectionToolbar,
|
|
@@ -217,19 +217,19 @@ class ArchiveAgentSessionSectionAction extends Action2 {
|
|
|
217
217
|
if (!skipConfirmation) {
|
|
218
218
|
const confirmed = await dialogService.confirm({
|
|
219
219
|
message: context.sessions.length === 1 ? ( localize(
|
|
220
|
-
|
|
220
|
+
4938,
|
|
221
221
|
"Are you sure you want to archive 1 agent session from '{0}'?",
|
|
222
222
|
context.label
|
|
223
223
|
)) : ( localize(
|
|
224
|
-
|
|
224
|
+
4939,
|
|
225
225
|
"Are you sure you want to archive {0} agent sessions from '{1}'?",
|
|
226
226
|
context.sessions.length,
|
|
227
227
|
context.label
|
|
228
228
|
)),
|
|
229
|
-
detail: ( localize(
|
|
230
|
-
primaryButton: ( localize(
|
|
229
|
+
detail: ( localize(4940, "You can unarchive sessions later if needed from the sessions view.")),
|
|
230
|
+
primaryButton: ( localize(4941, "Archive All")),
|
|
231
231
|
checkbox: {
|
|
232
|
-
label: ( localize(
|
|
232
|
+
label: ( localize(4942, "Do not ask me again"))
|
|
233
233
|
}
|
|
234
234
|
});
|
|
235
235
|
if (!confirmed.confirmed) {
|
|
@@ -248,7 +248,7 @@ class UnarchiveAgentSessionSectionAction extends Action2 {
|
|
|
248
248
|
constructor() {
|
|
249
249
|
super({
|
|
250
250
|
id: "agentSessionSection.unarchive",
|
|
251
|
-
title: ( localize2(
|
|
251
|
+
title: ( localize2(4943, "Unarchive All")),
|
|
252
252
|
icon: Codicon.unarchive,
|
|
253
253
|
menu: [{
|
|
254
254
|
id: MenuId.AgentSessionSectionToolbar,
|
|
@@ -272,14 +272,14 @@ class UnarchiveAgentSessionSectionAction extends Action2 {
|
|
|
272
272
|
const skipConfirmation = storageService.getBoolean(ConfirmArchiveStorageKey, StorageScope.PROFILE, false);
|
|
273
273
|
if (!skipConfirmation) {
|
|
274
274
|
const confirmed = await dialogService.confirm({
|
|
275
|
-
message: context.sessions.length === 1 ? ( localize(
|
|
276
|
-
|
|
275
|
+
message: context.sessions.length === 1 ? ( localize(4944, "Are you sure you want to unarchive 1 agent session?")) : ( localize(
|
|
276
|
+
4945,
|
|
277
277
|
"Are you sure you want to unarchive {0} agent sessions?",
|
|
278
278
|
context.sessions.length
|
|
279
279
|
)),
|
|
280
|
-
primaryButton: ( localize(
|
|
280
|
+
primaryButton: ( localize(4946, "Unarchive All")),
|
|
281
281
|
checkbox: {
|
|
282
|
-
label: ( localize(
|
|
282
|
+
label: ( localize(4942, "Do not ask me again"))
|
|
283
283
|
}
|
|
284
284
|
});
|
|
285
285
|
if (!confirmed.confirmed) {
|
|
@@ -298,7 +298,7 @@ class MarkAgentSessionSectionReadAction extends Action2 {
|
|
|
298
298
|
constructor() {
|
|
299
299
|
super({
|
|
300
300
|
id: "agentSessionSection.markRead",
|
|
301
|
-
title: ( localize2(
|
|
301
|
+
title: ( localize2(4947, "Mark All as Read")),
|
|
302
302
|
menu: [{
|
|
303
303
|
id: MenuId.AgentSessionSectionContext,
|
|
304
304
|
group: "1_edit",
|
|
@@ -342,7 +342,7 @@ class MarkAgentSessionUnreadAction extends BaseAgentSessionAction {
|
|
|
342
342
|
constructor() {
|
|
343
343
|
super({
|
|
344
344
|
id: "agentSession.markUnread",
|
|
345
|
-
title: ( localize2(
|
|
345
|
+
title: ( localize2(4948, "Mark as Unread")),
|
|
346
346
|
menu: {
|
|
347
347
|
id: MenuId.AgentSessionsContext,
|
|
348
348
|
group: "0_read",
|
|
@@ -362,7 +362,7 @@ class MarkAgentSessionReadAction extends BaseAgentSessionAction {
|
|
|
362
362
|
constructor() {
|
|
363
363
|
super({
|
|
364
364
|
id: "agentSession.markRead",
|
|
365
|
-
title: ( localize2(
|
|
365
|
+
title: ( localize2(4949, "Mark as Read")),
|
|
366
366
|
menu: {
|
|
367
367
|
id: MenuId.AgentSessionsContext,
|
|
368
368
|
group: "0_read",
|
|
@@ -382,7 +382,7 @@ class ArchiveAgentSessionAction extends BaseAgentSessionAction {
|
|
|
382
382
|
constructor() {
|
|
383
383
|
super({
|
|
384
384
|
id: "agentSession.archive",
|
|
385
|
-
title: ( localize2(
|
|
385
|
+
title: ( localize2(4950, "Archive")),
|
|
386
386
|
icon: Codicon.archive,
|
|
387
387
|
keybinding: {
|
|
388
388
|
primary: KeyCode.Delete,
|
|
@@ -412,8 +412,8 @@ class ArchiveAgentSessionAction extends BaseAgentSessionAction {
|
|
|
412
412
|
const chatModel = chatService.getSession(session.resource);
|
|
413
413
|
if (chatModel && !(await showClearEditingSessionConfirmation(chatModel, dialogService, {
|
|
414
414
|
isArchiveAction: true,
|
|
415
|
-
titleOverride: ( localize(
|
|
416
|
-
messageOverride: ( localize(
|
|
415
|
+
titleOverride: ( localize(4951, "Archive chat with pending edits?")),
|
|
416
|
+
messageOverride: ( localize(4952, "You have pending changes in this chat session."))
|
|
417
417
|
}))) {
|
|
418
418
|
return;
|
|
419
419
|
}
|
|
@@ -425,7 +425,7 @@ class UnarchiveAgentSessionAction extends BaseAgentSessionAction {
|
|
|
425
425
|
constructor() {
|
|
426
426
|
super({
|
|
427
427
|
id: "agentSession.unarchive",
|
|
428
|
-
title: ( localize2(
|
|
428
|
+
title: ( localize2(4953, "Unarchive")),
|
|
429
429
|
icon: Codicon.unarchive,
|
|
430
430
|
keybinding: {
|
|
431
431
|
primary: KeyMod.Shift | KeyCode.Delete,
|
|
@@ -461,7 +461,7 @@ class RenameAgentSessionAction extends BaseAgentSessionAction {
|
|
|
461
461
|
constructor() {
|
|
462
462
|
super({
|
|
463
463
|
id: AGENT_SESSION_RENAME_ACTION_ID,
|
|
464
|
-
title: ( localize2(
|
|
464
|
+
title: ( localize2(4954, "Rename...")),
|
|
465
465
|
precondition: ( ChatContextKeys.hasMultipleAgentSessionsSelected.negate()),
|
|
466
466
|
keybinding: {
|
|
467
467
|
primary: KeyCode.F2,
|
|
@@ -487,7 +487,7 @@ class RenameAgentSessionAction extends BaseAgentSessionAction {
|
|
|
487
487
|
const quickInputService = accessor.get(IQuickInputService);
|
|
488
488
|
const chatService = accessor.get(IChatService);
|
|
489
489
|
const title = await quickInputService.input({
|
|
490
|
-
prompt: ( localize(
|
|
490
|
+
prompt: ( localize(4955, "New agent session title")),
|
|
491
491
|
value: session.label
|
|
492
492
|
});
|
|
493
493
|
if (title) {
|
|
@@ -499,7 +499,7 @@ class DeleteAgentSessionAction extends BaseAgentSessionAction {
|
|
|
499
499
|
constructor() {
|
|
500
500
|
super({
|
|
501
501
|
id: AGENT_SESSION_DELETE_ACTION_ID,
|
|
502
|
-
title: ( localize2(
|
|
502
|
+
title: ( localize2(4956, "Delete...")),
|
|
503
503
|
menu: {
|
|
504
504
|
id: MenuId.AgentSessionsContext,
|
|
505
505
|
group: "1_edit",
|
|
@@ -516,13 +516,13 @@ class DeleteAgentSessionAction extends BaseAgentSessionAction {
|
|
|
516
516
|
const dialogService = accessor.get(IDialogService);
|
|
517
517
|
const widgetService = accessor.get(IChatWidgetService);
|
|
518
518
|
const confirmed = await dialogService.confirm({
|
|
519
|
-
message: sessions.length === 1 ? ( localize(
|
|
520
|
-
|
|
519
|
+
message: sessions.length === 1 ? ( localize(4957, "Are you sure you want to delete this chat session?")) : ( localize(
|
|
520
|
+
4958,
|
|
521
521
|
"Are you sure you want to delete {0} chat sessions?",
|
|
522
522
|
sessions.length
|
|
523
523
|
)),
|
|
524
|
-
detail: ( localize(
|
|
525
|
-
primaryButton: ( localize(
|
|
524
|
+
detail: ( localize(4959, "This action cannot be undone.")),
|
|
525
|
+
primaryButton: ( localize(4960, "Delete"))
|
|
526
526
|
});
|
|
527
527
|
if (!confirmed.confirmed) {
|
|
528
528
|
return;
|
|
@@ -537,7 +537,7 @@ class DeleteAllLocalSessionsAction extends Action2 {
|
|
|
537
537
|
constructor() {
|
|
538
538
|
super({
|
|
539
539
|
id: "workbench.action.chat.clearHistory",
|
|
540
|
-
title: ( localize2(
|
|
540
|
+
title: ( localize2(4961, "Delete All Local Workspace Chat Sessions")),
|
|
541
541
|
precondition: ChatContextKeys.enabled,
|
|
542
542
|
category: AGENT_SESSIONS_CATEGORY,
|
|
543
543
|
f1: true
|
|
@@ -553,13 +553,13 @@ class DeleteAllLocalSessionsAction extends Action2 {
|
|
|
553
553
|
return;
|
|
554
554
|
}
|
|
555
555
|
const confirmed = await dialogService.confirm({
|
|
556
|
-
message: localSessionsCount === 1 ? ( localize(
|
|
557
|
-
|
|
556
|
+
message: localSessionsCount === 1 ? ( localize(4962, "Are you sure you want to delete 1 local workspace chat session?")) : ( localize(
|
|
557
|
+
4963,
|
|
558
558
|
"Are you sure you want to delete {0} local workspace chat sessions?",
|
|
559
559
|
localSessionsCount
|
|
560
560
|
)),
|
|
561
|
-
detail: ( localize(
|
|
562
|
-
primaryButton: ( localize(
|
|
561
|
+
detail: ( localize(4964, "This action cannot be undone.")),
|
|
562
|
+
primaryButton: ( localize(4965, "Delete All"))
|
|
563
563
|
});
|
|
564
564
|
if (!confirmed.confirmed) {
|
|
565
565
|
return;
|
|
@@ -588,7 +588,7 @@ class OpenAgentSessionInEditorGroupAction extends BaseOpenAgentSessionAction {
|
|
|
588
588
|
constructor() {
|
|
589
589
|
super({
|
|
590
590
|
id: OpenAgentSessionInEditorGroupAction.id,
|
|
591
|
-
title: ( localize2(
|
|
591
|
+
title: ( localize2(4966, "Open as Editor")),
|
|
592
592
|
keybinding: {
|
|
593
593
|
primary: KeyMod.CtrlCmd | KeyCode.Enter,
|
|
594
594
|
mac: {
|
|
@@ -618,7 +618,7 @@ class OpenAgentSessionInNewEditorGroupAction extends BaseOpenAgentSessionAction
|
|
|
618
618
|
constructor() {
|
|
619
619
|
super({
|
|
620
620
|
id: OpenAgentSessionInNewEditorGroupAction.id,
|
|
621
|
-
title: ( localize2(
|
|
621
|
+
title: ( localize2(4967, "Open to the Side")),
|
|
622
622
|
keybinding: {
|
|
623
623
|
primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.Enter,
|
|
624
624
|
mac: {
|
|
@@ -648,7 +648,7 @@ class OpenAgentSessionInNewWindowAction extends BaseOpenAgentSessionAction {
|
|
|
648
648
|
constructor() {
|
|
649
649
|
super({
|
|
650
650
|
id: OpenAgentSessionInNewWindowAction.id,
|
|
651
|
-
title: ( localize2(
|
|
651
|
+
title: ( localize2(4968, "Open in New Window")),
|
|
652
652
|
menu: {
|
|
653
653
|
id: MenuId.AgentSessionsContext,
|
|
654
654
|
order: 3,
|
|
@@ -675,7 +675,7 @@ class RefreshAgentSessionsViewerAction extends Action2 {
|
|
|
675
675
|
constructor() {
|
|
676
676
|
super({
|
|
677
677
|
id: "agentSessionsViewer.refresh",
|
|
678
|
-
title: ( localize2(
|
|
678
|
+
title: ( localize2(4969, "Refresh Agent Sessions")),
|
|
679
679
|
icon: Codicon.refresh,
|
|
680
680
|
menu: {
|
|
681
681
|
id: MenuId.AgentSessionsToolbar,
|
|
@@ -692,7 +692,7 @@ class FindAgentSessionInViewerAction extends Action2 {
|
|
|
692
692
|
constructor() {
|
|
693
693
|
super({
|
|
694
694
|
id: "agentSessionsViewer.find",
|
|
695
|
-
title: ( localize2(
|
|
695
|
+
title: ( localize2(4970, "Find Agent Session")),
|
|
696
696
|
icon: Codicon.search,
|
|
697
697
|
menu: {
|
|
698
698
|
id: MenuId.AgentSessionsToolbar,
|
|
@@ -783,7 +783,7 @@ class ShowAgentSessionsSidebar extends UpdateChatViewWidthAction {
|
|
|
783
783
|
this.ID = "agentSessions.showAgentSessionsSidebar";
|
|
784
784
|
}
|
|
785
785
|
static {
|
|
786
|
-
this.TITLE = ( localize2(
|
|
786
|
+
this.TITLE = ( localize2(4971, "Show Agent Sessions Sidebar"));
|
|
787
787
|
}
|
|
788
788
|
constructor() {
|
|
789
789
|
super({
|
|
@@ -803,7 +803,7 @@ class HideAgentSessionsSidebar extends UpdateChatViewWidthAction {
|
|
|
803
803
|
this.ID = "agentSessions.hideAgentSessionsSidebar";
|
|
804
804
|
}
|
|
805
805
|
static {
|
|
806
|
-
this.TITLE = ( localize2(
|
|
806
|
+
this.TITLE = ( localize2(4972, "Hide Agent Sessions Sidebar"));
|
|
807
807
|
}
|
|
808
808
|
constructor() {
|
|
809
809
|
super({
|
|
@@ -823,7 +823,7 @@ class ToggleAgentSessionsSidebar extends Action2 {
|
|
|
823
823
|
this.ID = "agentSessions.toggleAgentSessionsSidebar";
|
|
824
824
|
}
|
|
825
825
|
static {
|
|
826
|
-
this.TITLE = ( localize2(
|
|
826
|
+
this.TITLE = ( localize2(4973, "Toggle Agent Sessions Sidebar"));
|
|
827
827
|
}
|
|
828
828
|
constructor() {
|
|
829
829
|
super({
|
|
@@ -853,7 +853,7 @@ class FocusAgentSessionsAction extends Action2 {
|
|
|
853
853
|
constructor() {
|
|
854
854
|
super({
|
|
855
855
|
id: FocusAgentSessionsAction.id,
|
|
856
|
-
title: ( localize2(
|
|
856
|
+
title: ( localize2(4974, "Focus Agent Sessions")),
|
|
857
857
|
precondition: ( ContextKeyExpr.and(ChatContextKeys.enabled, ( ContextKeyExpr.equals(`config.${ChatConfiguration.ChatViewSessionsEnabled}`, true)))),
|
|
858
858
|
category: AGENT_SESSIONS_CATEGORY,
|
|
859
859
|
f1: true
|
|
@@ -17,19 +17,19 @@ import { AGENT_SESSION_RENAME_ACTION_ID, AGENT_SESSION_DELETE_ACTION_ID } from '
|
|
|
17
17
|
|
|
18
18
|
const archiveButton = {
|
|
19
19
|
iconClass: ThemeIcon.asClassName(Codicon.archive),
|
|
20
|
-
tooltip: ( localize(
|
|
20
|
+
tooltip: ( localize(4984, "Archive"))
|
|
21
21
|
};
|
|
22
22
|
const unarchiveButton = {
|
|
23
23
|
iconClass: ThemeIcon.asClassName(Codicon.inbox),
|
|
24
|
-
tooltip: ( localize(
|
|
24
|
+
tooltip: ( localize(4985, "Unarchive"))
|
|
25
25
|
};
|
|
26
26
|
const renameButton = {
|
|
27
27
|
iconClass: ThemeIcon.asClassName(Codicon.edit),
|
|
28
|
-
tooltip: ( localize(
|
|
28
|
+
tooltip: ( localize(4986, "Rename"))
|
|
29
29
|
};
|
|
30
30
|
const deleteButton = {
|
|
31
31
|
iconClass: ThemeIcon.asClassName(Codicon.trash),
|
|
32
|
-
tooltip: ( localize(
|
|
32
|
+
tooltip: ( localize(4987, "Delete"))
|
|
33
33
|
};
|
|
34
34
|
function getSessionDescription(session) {
|
|
35
35
|
const descriptionText = typeof session.description === "string" ? session.description : session.description ? renderAsPlaintext(session.description) : undefined;
|
|
@@ -68,7 +68,7 @@ let AgentSessionsPicker = class AgentSessionsPicker {
|
|
|
68
68
|
}));
|
|
69
69
|
picker.items = this.createPickerItems();
|
|
70
70
|
picker.canAcceptInBackground = true;
|
|
71
|
-
picker.placeholder = ( localize(
|
|
71
|
+
picker.placeholder = ( localize(4988, "Search agent sessions by name"));
|
|
72
72
|
disposables.add(picker.onDidAccept(e => {
|
|
73
73
|
const pick = picker.selectedItems[0];
|
|
74
74
|
if (pick) {
|