@codingame/monaco-vscode-katex-common 29.1.1 → 30.0.0
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 +2 -2
- package/vscode/src/vs/platform/actions/browser/buttonbar.js +14 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatAccessibilityProvider.js +16 -16
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContinueInAction.js +9 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatElicitationActions.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatExecuteActions.js +34 -34
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatTitleActions.js +12 -20
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolActions.d.ts +14 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolActions.js +208 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolPicker.d.ts +22 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolPicker.js +637 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionApprovalModel.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionApprovalModel.js +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionHoverWidget.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.d.ts +9 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.js +202 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.d.ts +4 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.js +17 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsOpener.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.d.ts +53 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.js +296 -63
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/media/agentsessionsviewer.css +59 -23
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentWidgets.js +55 -42
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/implicitContextAttachment.js +12 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingActions.js +110 -59
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorActions.js +14 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorOverlay.js +7 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingExplanationWidget.js +12 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessionPickerActionItem.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/searchableOptionPickerActionItem.js +5 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolSetsContribution.d.ts +24 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolSetsContribution.js +384 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatAgentHover.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatArtifactsWidget.d.ts +12 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatArtifactsWidget.js +220 -61
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentMarkdownRenderer.js +1 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAgentCommandContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAnonymousRateLimitedPart.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAttachmentsContentPart.d.ts +6 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAttachmentsContentPart.js +14 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatChangesSummaryPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCodeCitationContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCommandContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationContentPart.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationWidget.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatContentCodePools.js +5 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatDisabledClaudeHooksContentPart.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatExtensionsContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatHookContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatInlineAnchorWidget.d.ts +5 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatInlineAnchorWidget.js +14 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMarkdownContentPart.d.ts +11 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMarkdownContentPart.js +40 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMcpServersInteractionContentPart.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMultiDiffContentPart.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatProgressContentPart.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuestionCarouselPart.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuestionCarouselPart.js +97 -54
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuotaExceededPart.js +5 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatReferencesContentPart.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatResourceGroupWidget.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSubagentContentPart.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSuggestNextWidget.js +8 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTextEditContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatThinkingContentPart.d.ts +15 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatThinkingContentPart.js +155 -22
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTipContentPart.js +9 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTodoListWidget.d.ts +3 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTodoListWidget.js +36 -19
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolInputOutputContentPart.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTreeContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatWorkspaceEditContentPart.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/codeBlockPart.js +14 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatThinkingContent.css +13 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/abstractToolConfirmationSubPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatExtensionsInstallToolSubPart.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppModel.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppSubPart.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMissingSandboxDepsConfirmationSubPart.d.ts +17 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMissingSandboxDepsConfirmationSubPart.js +68 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatModifiedFilesConfirmationSubPart.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolConfirmationSubPart.js +16 -16
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolProgressPart.js +33 -25
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolConfirmationSubPart.js +7 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolInvocationPart.js +12 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolOutputPart.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPartUtilities.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPostExecuteConfirmationPart.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatDragAndDrop.js +11 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.d.ts +4 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.js +37 -113
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListWidget.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatWidget.d.ts +10 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatWidget.js +66 -39
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatFollowups.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPart.d.ts +13 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPart.js +103 -61
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelPicker.d.ts +2 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelPicker.js +35 -23
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/delegationSessionPickerActionItem.d.ts +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/delegationSessionPickerActionItem.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modePickerActionItem.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modelPickerActionItem2.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modelPickerActionItem2.js +4 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/permissionPickerActionItem.d.ts +2 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/permissionPickerActionItem.js +39 -24
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/sessionTargetPickerActionItem.d.ts +6 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/sessionTargetPickerActionItem.js +44 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/workspacePickerActionItem.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/media/chat.css +60 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageDetails.js +7 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageWidget.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/common/chatImageExtraction.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/common/widget/chatColors.js +15 -15
- package/vscode/src/vs/workbench/contrib/chat/common/widget/codeBlockModelCollection.js +4 -0
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatController.js +4 -4
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatOverlayWidget.js +5 -5
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionService.d.ts +4 -1
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionService.js +5 -2
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatWidget.js +6 -11
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatZoneWidget.js +1 -1
- package/vscode/src/vs/workbench/contrib/inlineChat/common/inlineChat.js +39 -39
- package/vscode/src/vs/workbench/contrib/interactive/browser/replInputHintContentWidget.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/executionStatusBarItemController.js +7 -7
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindWidget.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/cellOperations.d.ts +26 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/cellOperations.js +746 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/insertCellActions.d.ts +13 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/insertCellActions.js +300 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffCellEditorOptions.d.ts +8 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffCellEditorOptions.js +55 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffComponents.d.ts +273 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffComponents.js +1963 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementOutputs.d.ts +50 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementOutputs.js +314 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementViewModel.d.ts +258 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementViewModel.js +886 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffNestedCellViewModel.d.ts +41 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffNestedCellViewModel.js +118 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/editorHeightCalculator.d.ts +17 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/editorHeightCalculator.js +71 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/eventDispatcher.d.ts +27 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/eventDispatcher.js +40 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookCellDiffDecorator.d.ts +23 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookCellDiffDecorator.js +313 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookDeletedCellDecorator.d.ts +51 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookDeletedCellDecorator.js +265 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInlineDiff.d.ts +24 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInlineDiff.js +185 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInlineDiffWidget.d.ts +28 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInlineDiffWidget.js +104 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInsertedCellDecorator.d.ts +10 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInsertedCellDecorator.js +43 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookOriginalCellModelFactory.d.ts +21 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookOriginalCellModelFactory.js +41 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookOriginalModelRefFactory.d.ts +25 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookOriginalModelRefFactory.js +69 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiff.css +469 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditor.d.ts +149 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditor.js +933 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditorBrowser.d.ts +180 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditorBrowser.js +32 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffList.d.ts +102 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffList.js +643 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffOverviewRuler.d.ts +30 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffOverviewRuler.js +197 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffViewModel.d.ts +75 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffViewModel.js +539 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/unchangedEditorRegions.d.ts +13 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/unchangedEditorRegions.js +39 -0
- package/vscode/src/vs/workbench/contrib/notebook/common/model/notebookMetadataTextModel.d.ts +19 -0
- package/vscode/src/vs/workbench/contrib/notebook/common/model/notebookMetadataTextModel.js +90 -0
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookDiff.d.ts +26 -0
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookDiff.js +92 -0
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditor.js +1 -1
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditorInput.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessions.contribution.d.ts +0 -152
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessions.contribution.js +0 -1317
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/internalCustomizations/internalPromptFileSystem.d.ts +0 -47
- package/vscode/src/vs/workbench/contrib/chat/common/promptSyntax/internalCustomizations/internalPromptFileSystem.js +0 -95
package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionHoverWidget.js
CHANGED
|
@@ -141,7 +141,7 @@ let AgentSessionHoverWidget = class AgentSessionHoverWidget extends Disposable {
|
|
|
141
141
|
append(detailsRow, $("span.separator", undefined, "•"));
|
|
142
142
|
const diffContainer = append(detailsRow, $(".agent-session-hover-diff"));
|
|
143
143
|
if (diff.files > 0) {
|
|
144
|
-
append(diffContainer, $("span", undefined, diff.files === 1 ? ( localize(
|
|
144
|
+
append(diffContainer, $("span", undefined, diff.files === 1 ? ( localize(5101, "1 file")) : ( localize(5102, "{0} files", diff.files))));
|
|
145
145
|
}
|
|
146
146
|
if (diff.insertions > 0) {
|
|
147
147
|
append(diffContainer, $("span.insertions", undefined, `+${diff.insertions}`));
|
|
@@ -157,7 +157,7 @@ let AgentSessionHoverWidget = class AgentSessionHoverWidget extends Disposable {
|
|
|
157
157
|
if (session.isArchived()) {
|
|
158
158
|
append(detailsRow, $("span.separator", undefined, "•"));
|
|
159
159
|
append(detailsRow, renderIcon(Codicon.archive));
|
|
160
|
-
append(detailsRow, $("span", undefined, ( localize(
|
|
160
|
+
append(detailsRow, $("span", undefined, ( localize(5103, "Archived"))));
|
|
161
161
|
}
|
|
162
162
|
}
|
|
163
163
|
buildFallbackTooltip(session) {
|
|
@@ -194,7 +194,7 @@ let AgentSessionHoverWidget = class AgentSessionHoverWidget extends Disposable {
|
|
|
194
194
|
if (diff && hasValidDiff(session.changes)) {
|
|
195
195
|
const diffParts = [];
|
|
196
196
|
if (diff.files > 0) {
|
|
197
|
-
diffParts.push(diff.files === 1 ? ( localize(
|
|
197
|
+
diffParts.push(diff.files === 1 ? ( localize(5101, "1 file")) : ( localize(5102, "{0} files", diff.files)));
|
|
198
198
|
}
|
|
199
199
|
if (diff.insertions > 0) {
|
|
200
200
|
diffParts.push(`+${diff.insertions}`);
|
|
@@ -211,7 +211,7 @@ let AgentSessionHoverWidget = class AgentSessionHoverWidget extends Disposable {
|
|
|
211
211
|
}
|
|
212
212
|
lines.push(details.join(" • "));
|
|
213
213
|
if (session.isArchived()) {
|
|
214
|
-
lines.push(`$(archive) ${( localize(
|
|
214
|
+
lines.push(`$(archive) ${( localize(5103, "Archived"))}`);
|
|
215
215
|
}
|
|
216
216
|
return ( new MarkdownString(lines.join("\n\n"), {
|
|
217
217
|
supportThemeIcons: true
|
|
@@ -228,16 +228,16 @@ let AgentSessionHoverWidget = class AgentSessionHoverWidget extends Disposable {
|
|
|
228
228
|
let statusLabel;
|
|
229
229
|
switch (status) {
|
|
230
230
|
case ChatSessionStatus.NeedsInput:
|
|
231
|
-
statusLabel = ( localize(
|
|
231
|
+
statusLabel = ( localize(5104, "Needs Input"));
|
|
232
232
|
break;
|
|
233
233
|
case ChatSessionStatus.InProgress:
|
|
234
|
-
statusLabel = ( localize(
|
|
234
|
+
statusLabel = ( localize(5105, "In Progress"));
|
|
235
235
|
break;
|
|
236
236
|
case ChatSessionStatus.Failed:
|
|
237
|
-
statusLabel = ( localize(
|
|
237
|
+
statusLabel = ( localize(5106, "Failed"));
|
|
238
238
|
break;
|
|
239
239
|
default:
|
|
240
|
-
statusLabel = ( localize(
|
|
240
|
+
statusLabel = ( localize(5107, "Completed"));
|
|
241
241
|
}
|
|
242
242
|
return statusLabel;
|
|
243
243
|
}
|
package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.d.ts
CHANGED
|
@@ -20,12 +20,18 @@ import { ISessionOpenOptions } from "./agentSessionsOpener.js";
|
|
|
20
20
|
import { IEditorService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorService.service";
|
|
21
21
|
import { IChatWidget } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chat";
|
|
22
22
|
import { IStorageService } from "@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service";
|
|
23
|
+
import { IAccessibilityService } from "@codingame/monaco-vscode-api/vscode/vs/platform/accessibility/common/accessibility.service";
|
|
23
24
|
export interface IAgentSessionsControlOptions {
|
|
24
25
|
readonly overrideStyles: IStyleOverride<IListStyles>;
|
|
25
26
|
readonly filter: IAgentSessionsFilter;
|
|
26
27
|
readonly source: string;
|
|
27
28
|
readonly disableHover?: boolean;
|
|
28
29
|
readonly enableApprovalRow?: boolean;
|
|
30
|
+
readonly repositoryGroupLimit?: number;
|
|
31
|
+
readonly hideSectionCount?: boolean;
|
|
32
|
+
readonly hideSessionBadge?: boolean;
|
|
33
|
+
readonly useStatusOnlyIcons?: boolean;
|
|
34
|
+
readonly compactShowMore?: boolean;
|
|
29
35
|
getHoverPosition(): HoverPosition;
|
|
30
36
|
trackActiveEditorSession(): boolean;
|
|
31
37
|
collapseOlderSections?(): boolean;
|
|
@@ -46,10 +52,12 @@ export declare class AgentSessionsControl extends Disposable implements IAgentSe
|
|
|
46
52
|
private readonly telemetryService;
|
|
47
53
|
private readonly editorService;
|
|
48
54
|
private readonly storageService;
|
|
55
|
+
private readonly accessibilityService;
|
|
49
56
|
private sessionsContainer;
|
|
50
57
|
get element(): HTMLElement | undefined;
|
|
51
58
|
private emptyFilterMessage;
|
|
52
59
|
private sessionsList;
|
|
60
|
+
private sessionsDataSource;
|
|
53
61
|
private static readonly RECENT_SESSIONS_FOR_EXPAND;
|
|
54
62
|
private sessionsListFindIsOpen;
|
|
55
63
|
private _isProgrammaticCollapseChange;
|
|
@@ -63,7 +71,7 @@ export declare class AgentSessionsControl extends Disposable implements IAgentSe
|
|
|
63
71
|
private focusedAgentSessionReadContextKey;
|
|
64
72
|
private focusedAgentSessionTypeContextKey;
|
|
65
73
|
private hasMultipleAgentSessionsSelectedContextKey;
|
|
66
|
-
constructor(container: HTMLElement, options: IAgentSessionsControlOptions, contextMenuService: IContextMenuService, contextKeyService: IContextKeyService, instantiationService: IInstantiationService, chatSessionsService: IChatSessionsService, commandService: ICommandService, menuService: IMenuService, agentSessionsService: IAgentSessionsService, telemetryService: ITelemetryService, editorService: IEditorService, storageService: IStorageService);
|
|
74
|
+
constructor(container: HTMLElement, options: IAgentSessionsControlOptions, contextMenuService: IContextMenuService, contextKeyService: IContextKeyService, instantiationService: IInstantiationService, chatSessionsService: IChatSessionsService, commandService: ICommandService, menuService: IMenuService, agentSessionsService: IAgentSessionsService, telemetryService: ITelemetryService, editorService: IEditorService, storageService: IStorageService, accessibilityService: IAccessibilityService);
|
|
67
75
|
private registerListeners;
|
|
68
76
|
private revealAndFocusActiveEditorSession;
|
|
69
77
|
private create;
|
|
@@ -5,12 +5,12 @@ import { ChatContextKeys } from '@codingame/monaco-vscode-api/vscode/vs/workbenc
|
|
|
5
5
|
import { IContextMenuService } from '@codingame/monaco-vscode-api/vscode/vs/platform/contextview/browser/contextView.service';
|
|
6
6
|
import { IInstantiationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation';
|
|
7
7
|
import { WorkbenchCompressibleAsyncDataTree } from '@codingame/monaco-vscode-api/vscode/vs/platform/list/browser/listService';
|
|
8
|
-
import { append, $, hide, addDisposableListener, EventType, EventHelper, setVisibility } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/dom';
|
|
8
|
+
import { append, $, hide, addDisposableListener, EventType, EventHelper, getWindow, setVisibility } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/dom';
|
|
9
9
|
import { StandardKeyboardEvent } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/keyboardEvent';
|
|
10
10
|
import { KeyCode } from '@codingame/monaco-vscode-api/vscode/vs/base/common/keyCodes';
|
|
11
11
|
import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
|
|
12
|
-
import { isAgentSessionSection, AgentSessionSection, isAgentSession } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsModel';
|
|
13
|
-
import { AgentSessionsSorter, AgentSessionRenderer, AgentSessionsDataSource, AgentSessionsListDelegate, AgentSessionsCompressionDelegate, AgentSessionSectionRenderer, AgentSessionsKeyboardNavigationLabelProvider, AgentSessionsIdentityProvider, AgentSessionsDragAndDrop, AgentSessionsAccessibilityProvider, getRepositoryName, AgentSessionSectionLabels } from './agentSessionsViewer.js';
|
|
12
|
+
import { isAgentSessionSection, AgentSessionSection, isAgentSessionShowMore, isAgentSessionShowLess, isAgentSession } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsModel';
|
|
13
|
+
import { AgentSessionsSorter, AgentSessionRenderer, AgentSessionsDataSource, AgentSessionsListDelegate, AgentSessionsCompressionDelegate, AgentSessionShowMoreRenderer, AgentSessionShowLessRenderer, AgentSessionSectionRenderer, AgentSessionsKeyboardNavigationLabelProvider, AgentSessionsIdentityProvider, AgentSessionsDragAndDrop, AgentSessionsAccessibilityProvider, getRepositoryName, AgentSessionSectionLabels } from './agentSessionsViewer.js';
|
|
14
14
|
import { AgentSessionsSorting, AgentSessionsGrouping } from './agentSessionsFilter.js';
|
|
15
15
|
import { AgentSessionApprovalModel } from './agentSessionApprovalModel.js';
|
|
16
16
|
import { MenuId } from '@codingame/monaco-vscode-api/vscode/vs/platform/actions/common/actions';
|
|
@@ -32,6 +32,7 @@ import { IEditorService } from '@codingame/monaco-vscode-api/vscode/vs/workbench
|
|
|
32
32
|
import { ChatEditorInput } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/widgetHosts/editor/chatEditorInput';
|
|
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
|
+
import { IAccessibilityService } from '@codingame/monaco-vscode-api/vscode/vs/platform/accessibility/common/accessibility.service';
|
|
35
36
|
import { observableValue } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/observables/observableValue';
|
|
36
37
|
|
|
37
38
|
var AgentSessionsControl_1;
|
|
@@ -57,7 +58,8 @@ let AgentSessionsControl = class AgentSessionsControl extends Disposable {
|
|
|
57
58
|
agentSessionsService,
|
|
58
59
|
telemetryService,
|
|
59
60
|
editorService,
|
|
60
|
-
storageService
|
|
61
|
+
storageService,
|
|
62
|
+
accessibilityService
|
|
61
63
|
) {
|
|
62
64
|
super();
|
|
63
65
|
this.container = container;
|
|
@@ -72,6 +74,7 @@ let AgentSessionsControl = class AgentSessionsControl extends Disposable {
|
|
|
72
74
|
this.telemetryService = telemetryService;
|
|
73
75
|
this.editorService = editorService;
|
|
74
76
|
this.storageService = storageService;
|
|
77
|
+
this.accessibilityService = accessibilityService;
|
|
75
78
|
this.sessionsListFindIsOpen = false;
|
|
76
79
|
this._isProgrammaticCollapseChange = false;
|
|
77
80
|
this._recentRepositoryLabels = ( new Set());
|
|
@@ -119,9 +122,9 @@ let AgentSessionsControl = class AgentSessionsControl extends Disposable {
|
|
|
119
122
|
this.emptyFilterMessage = append(container, $(".agent-sessions-empty-filter-message"));
|
|
120
123
|
hide(this.emptyFilterMessage);
|
|
121
124
|
const span = append(this.emptyFilterMessage, $("span"));
|
|
122
|
-
span.textContent = `${( localize(
|
|
125
|
+
span.textContent = `${( localize(5175, "No matching sessions"))} - `;
|
|
123
126
|
const link = append(this.emptyFilterMessage, $("span.reset-filter-link"));
|
|
124
|
-
link.textContent = ( localize(
|
|
127
|
+
link.textContent = ( localize(5176, "Reset Filter"));
|
|
125
128
|
link.tabIndex = 0;
|
|
126
129
|
link.setAttribute("role", "button");
|
|
127
130
|
this._register(
|
|
@@ -212,18 +215,25 @@ let AgentSessionsControl = class AgentSessionsControl extends Disposable {
|
|
|
212
215
|
isGroupedByRepository: () => this.options.filter.groupResults?.() === AgentSessionsGrouping.Repository,
|
|
213
216
|
isSortedByUpdated: () => this.options.filter.sortResults?.() === AgentSessionsSorting.Updated
|
|
214
217
|
}, approvalModel, activeSessionResource));
|
|
215
|
-
const
|
|
218
|
+
const compact = this.options.compactShowMore;
|
|
219
|
+
const sessionDataSource = this.sessionsDataSource = this._register(( new AgentSessionsDataSource(this.options.filter, sorter, this.options.repositoryGroupLimit)));
|
|
216
220
|
const list = this.sessionsList = this._register(this.instantiationService.createInstance(
|
|
217
221
|
WorkbenchCompressibleAsyncDataTree,
|
|
218
222
|
"AgentSessionsView",
|
|
219
223
|
container,
|
|
220
|
-
( new AgentSessionsListDelegate(approvalModel)),
|
|
224
|
+
( new AgentSessionsListDelegate(approvalModel, this.options.compactShowMore)),
|
|
221
225
|
( new AgentSessionsCompressionDelegate()),
|
|
222
226
|
[
|
|
223
227
|
sessionRenderer,
|
|
224
|
-
this.instantiationService.createInstance(AgentSessionSectionRenderer
|
|
228
|
+
this.instantiationService.createInstance(AgentSessionSectionRenderer, {
|
|
229
|
+
hideSectionCount: this.options.hideSectionCount
|
|
230
|
+
}),
|
|
231
|
+
( new AgentSessionShowMoreRenderer({
|
|
232
|
+
compactLabel: this.options.compactShowMore
|
|
233
|
+
})),
|
|
234
|
+
( new AgentSessionShowLessRenderer())
|
|
225
235
|
],
|
|
226
|
-
|
|
236
|
+
sessionDataSource,
|
|
227
237
|
{
|
|
228
238
|
accessibilityProvider: ( new AgentSessionsAccessibilityProvider()),
|
|
229
239
|
dnd: this.instantiationService.createInstance(AgentSessionsDragAndDrop),
|
|
@@ -245,9 +255,180 @@ let AgentSessionsControl = class AgentSessionsControl extends Disposable {
|
|
|
245
255
|
list.updateElementHeight(session, undefined);
|
|
246
256
|
}
|
|
247
257
|
}));
|
|
248
|
-
|
|
258
|
+
if (compact) {
|
|
259
|
+
let expandedShowMoreElement;
|
|
260
|
+
let expandedSectionLabel;
|
|
261
|
+
let currentAnimatedHeight = AgentSessionShowMoreRenderer.COLLAPSED_HEIGHT;
|
|
262
|
+
const sectionToShowMore = ( new Map());
|
|
263
|
+
const rebuildSectionMap = () => {
|
|
264
|
+
sectionToShowMore.clear();
|
|
265
|
+
try {
|
|
266
|
+
const rootNode = list.getNode();
|
|
267
|
+
for (const sectionNode of rootNode.children) {
|
|
268
|
+
if (isAgentSessionSection(sectionNode.element)) {
|
|
269
|
+
const label = sectionNode.element.label;
|
|
270
|
+
for (const child of sectionNode.children) {
|
|
271
|
+
if (isAgentSessionShowMore(child.element) || isAgentSessionShowLess(child.element)) {
|
|
272
|
+
sectionToShowMore.set(label, child.element);
|
|
273
|
+
}
|
|
274
|
+
}
|
|
275
|
+
}
|
|
276
|
+
}
|
|
277
|
+
} catch {}
|
|
278
|
+
};
|
|
279
|
+
let expandAnimationId;
|
|
280
|
+
let collapseAnimationId;
|
|
281
|
+
const targetWindow = getWindow(container);
|
|
282
|
+
this._register({
|
|
283
|
+
dispose: () => {
|
|
284
|
+
if (expandAnimationId) {
|
|
285
|
+
targetWindow.cancelAnimationFrame(expandAnimationId);
|
|
286
|
+
}
|
|
287
|
+
if (collapseAnimationId) {
|
|
288
|
+
targetWindow.cancelAnimationFrame(collapseAnimationId);
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
});
|
|
292
|
+
const animateHeight = (element, from, to, onComplete) => {
|
|
293
|
+
if (this.accessibilityService.isMotionReduced()) {
|
|
294
|
+
if (list.hasNode(element)) {
|
|
295
|
+
isUpdatingHeight = true;
|
|
296
|
+
try {
|
|
297
|
+
list.updateElementHeight(element, to);
|
|
298
|
+
} finally {
|
|
299
|
+
isUpdatingHeight = false;
|
|
300
|
+
}
|
|
301
|
+
currentAnimatedHeight = to;
|
|
302
|
+
}
|
|
303
|
+
onComplete?.();
|
|
304
|
+
return undefined;
|
|
305
|
+
}
|
|
306
|
+
const duration = 150;
|
|
307
|
+
const start = Date.now();
|
|
308
|
+
const step = () => {
|
|
309
|
+
const elapsed = Date.now() - start;
|
|
310
|
+
const progress = Math.min(elapsed / duration, 1);
|
|
311
|
+
const eased = 1 - Math.pow(1 - progress, 2);
|
|
312
|
+
const height = Math.round(from + (to - from) * eased);
|
|
313
|
+
if (list.hasNode(element)) {
|
|
314
|
+
isUpdatingHeight = true;
|
|
315
|
+
try {
|
|
316
|
+
list.updateElementHeight(element, height);
|
|
317
|
+
} finally {
|
|
318
|
+
isUpdatingHeight = false;
|
|
319
|
+
}
|
|
320
|
+
currentAnimatedHeight = height;
|
|
321
|
+
}
|
|
322
|
+
if (progress < 1) {
|
|
323
|
+
return targetWindow.requestAnimationFrame(step);
|
|
324
|
+
}
|
|
325
|
+
onComplete?.();
|
|
326
|
+
return undefined;
|
|
327
|
+
};
|
|
328
|
+
return targetWindow.requestAnimationFrame(step);
|
|
329
|
+
};
|
|
330
|
+
const collapseCurrentShowMore = () => {
|
|
331
|
+
if (collapseAnimationId) {
|
|
332
|
+
targetWindow.cancelAnimationFrame(collapseAnimationId);
|
|
333
|
+
collapseAnimationId = undefined;
|
|
334
|
+
}
|
|
335
|
+
if (expandAnimationId) {
|
|
336
|
+
targetWindow.cancelAnimationFrame(expandAnimationId);
|
|
337
|
+
expandAnimationId = undefined;
|
|
338
|
+
}
|
|
339
|
+
if (expandedShowMoreElement && expandedSectionLabel) {
|
|
340
|
+
if (list.hasNode(expandedShowMoreElement)) {
|
|
341
|
+
collapseAnimationId = animateHeight(
|
|
342
|
+
expandedShowMoreElement,
|
|
343
|
+
currentAnimatedHeight,
|
|
344
|
+
AgentSessionShowMoreRenderer.COLLAPSED_HEIGHT,
|
|
345
|
+
() => {
|
|
346
|
+
collapseAnimationId = undefined;
|
|
347
|
+
}
|
|
348
|
+
);
|
|
349
|
+
}
|
|
350
|
+
}
|
|
351
|
+
expandedShowMoreElement = undefined;
|
|
352
|
+
expandedSectionLabel = undefined;
|
|
353
|
+
};
|
|
354
|
+
const expandShowMore = sectionLabel => {
|
|
355
|
+
if (expandedSectionLabel === sectionLabel) {
|
|
356
|
+
return;
|
|
357
|
+
}
|
|
358
|
+
collapseCurrentShowMore();
|
|
359
|
+
const showMoreItem = sectionToShowMore.get(sectionLabel);
|
|
360
|
+
if (!showMoreItem || !list.hasNode(showMoreItem)) {
|
|
361
|
+
return;
|
|
362
|
+
}
|
|
363
|
+
expandedShowMoreElement = showMoreItem;
|
|
364
|
+
expandedSectionLabel = sectionLabel;
|
|
365
|
+
currentAnimatedHeight = AgentSessionShowMoreRenderer.COLLAPSED_HEIGHT;
|
|
366
|
+
expandAnimationId = animateHeight(
|
|
367
|
+
showMoreItem,
|
|
368
|
+
AgentSessionShowMoreRenderer.COLLAPSED_HEIGHT,
|
|
369
|
+
AgentSessionShowMoreRenderer.HEIGHT,
|
|
370
|
+
() => {
|
|
371
|
+
expandAnimationId = undefined;
|
|
372
|
+
}
|
|
373
|
+
);
|
|
374
|
+
};
|
|
375
|
+
let isUpdatingHeight = false;
|
|
376
|
+
this._register(list.onDidChangeModel(() => {
|
|
377
|
+
if (isUpdatingHeight) {
|
|
378
|
+
return;
|
|
379
|
+
}
|
|
380
|
+
expandedShowMoreElement = undefined;
|
|
381
|
+
expandedSectionLabel = undefined;
|
|
382
|
+
currentAnimatedHeight = AgentSessionShowMoreRenderer.COLLAPSED_HEIGHT;
|
|
383
|
+
rebuildSectionMap();
|
|
384
|
+
}));
|
|
385
|
+
this._register(addDisposableListener(container, "mouseover", e => {
|
|
386
|
+
const target = e.target;
|
|
387
|
+
const row = target.closest(".monaco-list-row");
|
|
388
|
+
if (!row) {
|
|
389
|
+
return;
|
|
390
|
+
}
|
|
391
|
+
let sectionLabel;
|
|
392
|
+
const sectionHeaderEl = row.querySelector(".agent-session-section-label");
|
|
393
|
+
if (sectionHeaderEl) {
|
|
394
|
+
sectionLabel = sectionHeaderEl.textContent ?? undefined;
|
|
395
|
+
}
|
|
396
|
+
if (!sectionLabel) {
|
|
397
|
+
const showMoreEl = row.querySelector(".agent-session-show-more");
|
|
398
|
+
if (showMoreEl) {
|
|
399
|
+
sectionLabel = showMoreEl.getAttribute("data-section-label") ?? undefined;
|
|
400
|
+
}
|
|
401
|
+
}
|
|
402
|
+
if (!sectionLabel) {
|
|
403
|
+
const sessionItem = row.querySelector(".agent-session-item[data-section-label]");
|
|
404
|
+
if (sessionItem) {
|
|
405
|
+
sectionLabel = sessionItem.getAttribute("data-section-label") ?? undefined;
|
|
406
|
+
}
|
|
407
|
+
}
|
|
408
|
+
if (!sectionLabel) {
|
|
409
|
+
if (row.querySelector(".agent-session-item")) {
|
|
410
|
+
return;
|
|
411
|
+
}
|
|
412
|
+
collapseCurrentShowMore();
|
|
413
|
+
return;
|
|
414
|
+
}
|
|
415
|
+
if (!( sectionToShowMore.has(sectionLabel))) {
|
|
416
|
+
collapseCurrentShowMore();
|
|
417
|
+
return;
|
|
418
|
+
}
|
|
419
|
+
expandShowMore(sectionLabel);
|
|
420
|
+
}));
|
|
421
|
+
this._register(addDisposableListener(container, "mouseleave", () => {
|
|
422
|
+
collapseCurrentShowMore();
|
|
423
|
+
}));
|
|
424
|
+
rebuildSectionMap();
|
|
425
|
+
}
|
|
426
|
+
this._register(sessionDataSource.onDidGetChildren(count => {
|
|
249
427
|
this.updateEmpty(count === 0);
|
|
250
428
|
}));
|
|
429
|
+
this._register(sessionDataSource.onDidExpandRepositoryGroup(() => {
|
|
430
|
+
this.update();
|
|
431
|
+
}));
|
|
251
432
|
const model = this.agentSessionsService.model;
|
|
252
433
|
this._register(this.options.filter.onDidChange(async () => {
|
|
253
434
|
if (this.visible) {
|
|
@@ -337,6 +518,14 @@ let AgentSessionsControl = class AgentSessionsControl extends Disposable {
|
|
|
337
518
|
if (!element || isAgentSessionSection(element)) {
|
|
338
519
|
return;
|
|
339
520
|
}
|
|
521
|
+
if (isAgentSessionShowMore(element)) {
|
|
522
|
+
this.sessionsDataSource?.expandRepositoryGroup(element.sectionLabel);
|
|
523
|
+
return;
|
|
524
|
+
}
|
|
525
|
+
if (isAgentSessionShowLess(element)) {
|
|
526
|
+
this.sessionsDataSource?.collapseRepositoryGroup(element.sectionLabel);
|
|
527
|
+
return;
|
|
528
|
+
}
|
|
340
529
|
this.telemetryService.publicLog2("agentSessionOpened", {
|
|
341
530
|
providerType: element.providerType,
|
|
342
531
|
source: this.options.source
|
|
@@ -358,7 +547,7 @@ let AgentSessionsControl = class AgentSessionsControl extends Disposable {
|
|
|
358
547
|
browserEvent
|
|
359
548
|
}
|
|
360
549
|
) {
|
|
361
|
-
if (!element) {
|
|
550
|
+
if (!element || isAgentSessionShowMore(element) || isAgentSessionShowLess(element)) {
|
|
362
551
|
return;
|
|
363
552
|
}
|
|
364
553
|
EventHelper.stop(browserEvent, true);
|
|
@@ -525,6 +714,6 @@ let AgentSessionsControl = class AgentSessionsControl extends Disposable {
|
|
|
525
714
|
return true;
|
|
526
715
|
}
|
|
527
716
|
};
|
|
528
|
-
AgentSessionsControl = AgentSessionsControl_1 = ( __decorate([( __param(2, IContextMenuService)), ( __param(3, IContextKeyService)), ( __param(4, IInstantiationService)), ( __param(5, IChatSessionsService)), ( __param(6, ICommandService)), ( __param(7, IMenuService)), ( __param(8, IAgentSessionsService)), ( __param(9, ITelemetryService)), ( __param(10, IEditorService)), ( __param(11, IStorageService))], AgentSessionsControl));
|
|
717
|
+
AgentSessionsControl = AgentSessionsControl_1 = ( __decorate([( __param(2, IContextMenuService)), ( __param(3, IContextKeyService)), ( __param(4, IInstantiationService)), ( __param(5, IChatSessionsService)), ( __param(6, ICommandService)), ( __param(7, IMenuService)), ( __param(8, IAgentSessionsService)), ( __param(9, ITelemetryService)), ( __param(10, IEditorService)), ( __param(11, IStorageService)), ( __param(12, IAccessibilityService))], AgentSessionsControl));
|
|
529
718
|
|
|
530
719
|
export { AgentSessionsControl };
|
|
@@ -54,6 +54,10 @@ export declare class AgentSessionsFilter extends Disposable implements Required<
|
|
|
54
54
|
private registerStateActions;
|
|
55
55
|
private registerArchivedActions;
|
|
56
56
|
private registerReadActions;
|
|
57
|
+
/**
|
|
58
|
+
* Programmatically toggle the repository group capping state.
|
|
59
|
+
*/
|
|
60
|
+
setRepositoryGroupCapped(capped: boolean): void;
|
|
57
61
|
private registerResetAction;
|
|
58
62
|
isDefault(): boolean;
|
|
59
63
|
getExcludes(): IAgentSessionsFilterExcludes;
|
|
@@ -28,7 +28,8 @@ const DEFAULT_EXCLUDES = ( Object.freeze({
|
|
|
28
28
|
providers: [],
|
|
29
29
|
states: [],
|
|
30
30
|
archived: true ,
|
|
31
|
-
read: false
|
|
31
|
+
read: false,
|
|
32
|
+
repositoryGroupCapped: true
|
|
32
33
|
}));
|
|
33
34
|
let AgentSessionsFilter = class AgentSessionsFilter extends Disposable {
|
|
34
35
|
constructor(options, chatSessionsService, storageService) {
|
|
@@ -173,16 +174,16 @@ let AgentSessionsFilter = class AgentSessionsFilter extends Disposable {
|
|
|
173
174
|
registerStateActions(disposables, menuId) {
|
|
174
175
|
const states = [{
|
|
175
176
|
id: ChatSessionStatus.Completed,
|
|
176
|
-
label: ( localize(
|
|
177
|
+
label: ( localize(5177, "Completed"))
|
|
177
178
|
}, {
|
|
178
179
|
id: ChatSessionStatus.InProgress,
|
|
179
|
-
label: ( localize(
|
|
180
|
+
label: ( localize(5178, "In Progress"))
|
|
180
181
|
}, {
|
|
181
182
|
id: ChatSessionStatus.NeedsInput,
|
|
182
|
-
label: ( localize(
|
|
183
|
+
label: ( localize(5179, "Input Needed"))
|
|
183
184
|
}, {
|
|
184
185
|
id: ChatSessionStatus.Failed,
|
|
185
|
-
label: ( localize(
|
|
186
|
+
label: ( localize(5180, "Failed"))
|
|
186
187
|
}];
|
|
187
188
|
const that = this;
|
|
188
189
|
let counter = 0;
|
|
@@ -219,7 +220,7 @@ let AgentSessionsFilter = class AgentSessionsFilter extends Disposable {
|
|
|
219
220
|
constructor() {
|
|
220
221
|
super({
|
|
221
222
|
id: `agentSessions.filter.toggleExcludeArchived.${menuId.id.toLowerCase()}`,
|
|
222
|
-
title: ( localize(
|
|
223
|
+
title: ( localize(5181, "Archived")),
|
|
223
224
|
menu: {
|
|
224
225
|
id: menuId,
|
|
225
226
|
group: "3_props",
|
|
@@ -242,7 +243,7 @@ let AgentSessionsFilter = class AgentSessionsFilter extends Disposable {
|
|
|
242
243
|
constructor() {
|
|
243
244
|
super({
|
|
244
245
|
id: `agentSessions.filter.toggleExcludeRead.${menuId.id.toLowerCase()}`,
|
|
245
|
-
title: ( localize(
|
|
246
|
+
title: ( localize(5182, "Read")),
|
|
246
247
|
menu: {
|
|
247
248
|
id: menuId,
|
|
248
249
|
group: "3_props",
|
|
@@ -259,13 +260,21 @@ let AgentSessionsFilter = class AgentSessionsFilter extends Disposable {
|
|
|
259
260
|
}
|
|
260
261
|
}));
|
|
261
262
|
}
|
|
263
|
+
setRepositoryGroupCapped(capped) {
|
|
264
|
+
if (this.excludes.repositoryGroupCapped !== capped) {
|
|
265
|
+
this.storeExcludes({
|
|
266
|
+
...this.excludes,
|
|
267
|
+
repositoryGroupCapped: capped
|
|
268
|
+
});
|
|
269
|
+
}
|
|
270
|
+
}
|
|
262
271
|
registerResetAction(disposables, menuId) {
|
|
263
272
|
const that = this;
|
|
264
273
|
disposables.add(registerAction2(class extends Action2 {
|
|
265
274
|
constructor() {
|
|
266
275
|
super({
|
|
267
276
|
id: `agentSessions.filter.resetExcludes.${menuId.id.toLowerCase()}`,
|
|
268
|
-
title: ( localize(
|
|
277
|
+
title: ( localize(5183, "Reset")),
|
|
269
278
|
menu: {
|
|
270
279
|
id: menuId,
|
|
271
280
|
group: "4_reset",
|
|
@@ -81,7 +81,7 @@ async function openSessionDefault(accessor, session, openOptions) {
|
|
|
81
81
|
}
|
|
82
82
|
return await chatWidgetService.openSession(session.resource, target, options);
|
|
83
83
|
} catch (error) {
|
|
84
|
-
notificationService.error(( localize(
|
|
84
|
+
notificationService.error(( localize(5185, "Failed to open chat session: {0}", toErrorMessage(error))));
|
|
85
85
|
return undefined;
|
|
86
86
|
}
|
|
87
87
|
}
|
|
@@ -6,7 +6,7 @@ import { ICompressedTreeNode } from "@codingame/monaco-vscode-api/vscode/vs/base
|
|
|
6
6
|
import { ICompressibleKeyboardNavigationLabelProvider, ICompressibleTreeRenderer } from "@codingame/monaco-vscode-api/vscode/vs/base/browser/ui/tree/objectTree";
|
|
7
7
|
import { ITreeNode, ITreeElementRenderDetails, IAsyncDataSource, ITreeSorter, ITreeDragAndDrop, ITreeDragOverReaction } from "@codingame/monaco-vscode-api/vscode/vs/base/browser/ui/tree/tree";
|
|
8
8
|
import { Disposable, DisposableStore, IDisposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
|
|
9
|
-
import { AgentSessionSection, AgentSessionStatus, IAgentSession, IAgentSessionSection, IAgentSessionsModel } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsModel";
|
|
9
|
+
import { AgentSessionSection, AgentSessionStatus, IAgentSession, IAgentSessionSection, IAgentSessionShowLess, IAgentSessionShowMore, IAgentSessionsModel } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsModel";
|
|
10
10
|
import { IconLabel } from "@codingame/monaco-vscode-api/vscode/vs/base/browser/ui/iconLabel/iconLabel";
|
|
11
11
|
import { FuzzyScore } from "@codingame/monaco-vscode-api/vscode/vs/base/common/filters";
|
|
12
12
|
import { IMarkdownRendererService } from "@codingame/monaco-vscode-api/vscode/vs/platform/markdown/browser/markdownRenderer.service";
|
|
@@ -23,14 +23,16 @@ import { AgentSessionsGrouping, AgentSessionsSorting } from "./agentSessionsFilt
|
|
|
23
23
|
import { IObservable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/observable";
|
|
24
24
|
import { URI } from "@codingame/monaco-vscode-api/vscode/vs/base/common/uri";
|
|
25
25
|
import { AgentSessionApprovalModel } from "./agentSessionApprovalModel.js";
|
|
26
|
-
export type AgentSessionListItem = IAgentSession | IAgentSessionSection;
|
|
26
|
+
export type AgentSessionListItem = IAgentSession | IAgentSessionSection | IAgentSessionShowMore | IAgentSessionShowLess;
|
|
27
27
|
interface IAgentSessionItemTemplate {
|
|
28
28
|
readonly element: HTMLElement;
|
|
29
29
|
readonly icon: HTMLElement;
|
|
30
30
|
readonly title: IconLabel;
|
|
31
|
+
readonly pinnedIndicator: HTMLElement;
|
|
31
32
|
readonly statusContainer: HTMLElement;
|
|
32
33
|
readonly statusTime: HTMLElement;
|
|
33
34
|
readonly titleToolbar: MenuWorkbenchToolBar;
|
|
35
|
+
readonly detailsIcon: HTMLElement;
|
|
34
36
|
readonly diffContainer: HTMLElement;
|
|
35
37
|
readonly diffAddedSpan: HTMLSpanElement;
|
|
36
38
|
readonly diffRemovedSpan: HTMLSpanElement;
|
|
@@ -46,6 +48,8 @@ interface IAgentSessionItemTemplate {
|
|
|
46
48
|
}
|
|
47
49
|
export interface IAgentSessionRendererOptions {
|
|
48
50
|
readonly disableHover?: boolean;
|
|
51
|
+
readonly hideSessionBadge?: boolean;
|
|
52
|
+
readonly useStatusOnlyIcons?: boolean;
|
|
49
53
|
getHoverPosition(): HoverPosition;
|
|
50
54
|
isGroupedByRepository?(): boolean;
|
|
51
55
|
isSortedByUpdated?(): boolean;
|
|
@@ -95,23 +99,59 @@ interface IAgentSessionSectionTemplate {
|
|
|
95
99
|
readonly contextKeyService: IContextKeyService;
|
|
96
100
|
readonly disposables: IDisposable;
|
|
97
101
|
}
|
|
102
|
+
export interface IAgentSessionSectionRendererOptions {
|
|
103
|
+
readonly hideSectionCount?: boolean;
|
|
104
|
+
}
|
|
98
105
|
export declare class AgentSessionSectionRenderer implements ICompressibleTreeRenderer<IAgentSessionSection, FuzzyScore, IAgentSessionSectionTemplate> {
|
|
106
|
+
private readonly sectionOptions;
|
|
99
107
|
private readonly instantiationService;
|
|
100
108
|
private readonly contextKeyService;
|
|
101
109
|
static readonly TEMPLATE_ID = "agent-session-section";
|
|
102
110
|
readonly templateId = "agent-session-section";
|
|
103
|
-
constructor(instantiationService: IInstantiationService, contextKeyService: IContextKeyService);
|
|
111
|
+
constructor(sectionOptions: IAgentSessionSectionRendererOptions, instantiationService: IInstantiationService, contextKeyService: IContextKeyService);
|
|
104
112
|
renderTemplate(container: HTMLElement): IAgentSessionSectionTemplate;
|
|
105
113
|
renderElement(element: ITreeNode<IAgentSessionSection, FuzzyScore>, index: number, template: IAgentSessionSectionTemplate, details?: ITreeElementRenderDetails): void;
|
|
106
114
|
renderCompressedElements(node: ITreeNode<ICompressedTreeNode<IAgentSessionSection>, FuzzyScore>, index: number, templateData: IAgentSessionSectionTemplate, details?: ITreeElementRenderDetails): void;
|
|
107
115
|
disposeElement(element: ITreeNode<IAgentSessionSection, FuzzyScore>, index: number, template: IAgentSessionSectionTemplate, details?: ITreeElementRenderDetails): void;
|
|
108
116
|
disposeTemplate(templateData: IAgentSessionSectionTemplate): void;
|
|
109
117
|
}
|
|
118
|
+
interface IAgentSessionShowMoreTemplate {
|
|
119
|
+
readonly container: HTMLElement;
|
|
120
|
+
readonly label: HTMLElement;
|
|
121
|
+
readonly disposables: DisposableStore;
|
|
122
|
+
}
|
|
123
|
+
export interface IAgentSessionShowMoreRendererOptions {
|
|
124
|
+
readonly compactLabel?: boolean;
|
|
125
|
+
}
|
|
126
|
+
export declare class AgentSessionShowMoreRenderer implements ICompressibleTreeRenderer<IAgentSessionShowMore, FuzzyScore, IAgentSessionShowMoreTemplate> {
|
|
127
|
+
private readonly options?;
|
|
128
|
+
static readonly TEMPLATE_ID = "agent-session-show-more";
|
|
129
|
+
static readonly HEIGHT = 26;
|
|
130
|
+
static readonly COLLAPSED_HEIGHT = 1;
|
|
131
|
+
readonly templateId = "agent-session-show-more";
|
|
132
|
+
constructor(options?: IAgentSessionShowMoreRendererOptions | undefined);
|
|
133
|
+
renderTemplate(container: HTMLElement): IAgentSessionShowMoreTemplate;
|
|
134
|
+
renderElement(element: ITreeNode<IAgentSessionShowMore, FuzzyScore>, _index: number, template: IAgentSessionShowMoreTemplate): void;
|
|
135
|
+
renderCompressedElements(): void;
|
|
136
|
+
disposeElement(): void;
|
|
137
|
+
disposeTemplate(templateData: IAgentSessionShowMoreTemplate): void;
|
|
138
|
+
}
|
|
139
|
+
export declare class AgentSessionShowLessRenderer implements ICompressibleTreeRenderer<IAgentSessionShowLess, FuzzyScore, IAgentSessionShowMoreTemplate> {
|
|
140
|
+
static readonly TEMPLATE_ID = "agent-session-show-less";
|
|
141
|
+
static readonly HEIGHT = 26;
|
|
142
|
+
readonly templateId = "agent-session-show-less";
|
|
143
|
+
renderTemplate(container: HTMLElement): IAgentSessionShowMoreTemplate;
|
|
144
|
+
renderElement(element: ITreeNode<IAgentSessionShowLess, FuzzyScore>, _index: number, template: IAgentSessionShowMoreTemplate): void;
|
|
145
|
+
renderCompressedElements(): void;
|
|
146
|
+
disposeElement(): void;
|
|
147
|
+
disposeTemplate(templateData: IAgentSessionShowMoreTemplate): void;
|
|
148
|
+
}
|
|
110
149
|
export declare class AgentSessionsListDelegate implements IListVirtualDelegate<AgentSessionListItem> {
|
|
111
150
|
private readonly _approvalModel?;
|
|
151
|
+
private readonly _compactShowMore?;
|
|
112
152
|
static readonly ITEM_HEIGHT = 54;
|
|
113
153
|
static readonly SECTION_HEIGHT = 26;
|
|
114
|
-
constructor(_approvalModel?: AgentSessionApprovalModel | undefined);
|
|
154
|
+
constructor(_approvalModel?: AgentSessionApprovalModel | undefined, _compactShowMore?: boolean | undefined);
|
|
115
155
|
getHeight(element: AgentSessionListItem): number;
|
|
116
156
|
hasDynamicHeight(element: AgentSessionListItem): boolean;
|
|
117
157
|
getTemplateId(element: AgentSessionListItem): string;
|
|
@@ -127,6 +167,7 @@ export interface IAgentSessionsFilterExcludes {
|
|
|
127
167
|
readonly states: readonly AgentSessionStatus[];
|
|
128
168
|
readonly archived: boolean;
|
|
129
169
|
readonly read: boolean;
|
|
170
|
+
readonly repositoryGroupCapped: boolean;
|
|
130
171
|
}
|
|
131
172
|
export interface IAgentSessionsFilter {
|
|
132
173
|
/**
|
|
@@ -173,10 +214,17 @@ export interface IAgentSessionsFilter {
|
|
|
173
214
|
export declare class AgentSessionsDataSource extends Disposable implements IAsyncDataSource<IAgentSessionsModel, AgentSessionListItem> {
|
|
174
215
|
private readonly filter;
|
|
175
216
|
private readonly sorter;
|
|
217
|
+
private readonly repositoryGroupLimit?;
|
|
176
218
|
private static readonly CAPPED_SESSIONS_LIMIT;
|
|
219
|
+
static readonly REPOSITORY_GROUP_LIMIT = 5;
|
|
177
220
|
private readonly _onDidGetChildren;
|
|
178
221
|
readonly onDidGetChildren: Event<number>;
|
|
179
|
-
|
|
222
|
+
private readonly _onDidExpandRepositoryGroup;
|
|
223
|
+
readonly onDidExpandRepositoryGroup: Event<void>;
|
|
224
|
+
private readonly expandedRepositoryGroups;
|
|
225
|
+
constructor(filter: IAgentSessionsFilter | undefined, sorter: ITreeSorter<IAgentSession>, repositoryGroupLimit?: number | undefined);
|
|
226
|
+
expandRepositoryGroup(sectionLabel: string): void;
|
|
227
|
+
collapseRepositoryGroup(sectionLabel: string): void;
|
|
180
228
|
hasChildren(element: IAgentSessionsModel | AgentSessionListItem): boolean;
|
|
181
229
|
getChildren(element: IAgentSessionsModel | AgentSessionListItem): Iterable<AgentSessionListItem>;
|
|
182
230
|
private groupSessionsIntoSections;
|