@codingame/monaco-vscode-katex-common 25.1.1 → 26.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/actionWidget/browser/actionWidgetDropdown.d.ts +23 -2
- package/vscode/src/vs/platform/actionWidget/browser/actionWidgetDropdown.js +64 -27
- package/vscode/src/vs/platform/actions/browser/actionWidgetDropdownActionViewItem.d.ts +3 -1
- package/vscode/src/vs/platform/actions/browser/actionWidgetDropdownActionViewItem.js +31 -28
- package/vscode/src/vs/platform/actions/browser/buttonbar.d.ts +2 -0
- package/vscode/src/vs/platform/actions/browser/buttonbar.js +71 -50
- package/vscode/src/vs/platform/editor/browser/editor.js +17 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatAccessibilityProvider.js +112 -129
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContinueInAction.d.ts +10 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContinueInAction.js +110 -85
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatElicitationActions.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatExecuteActions.d.ts +21 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatExecuteActions.js +308 -216
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatTitleActions.js +153 -148
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionHoverWidget.d.ts +27 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionHoverWidget.js +247 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.d.ts +71 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.js +347 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.d.ts +44 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.js +287 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsOpener.d.ts +20 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsOpener.js +89 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.d.ts +188 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.js +677 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/media/agentSessionHoverWidget.css +98 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/media/agentsessionsviewer.css +263 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentModel.js +34 -25
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentWidgets.d.ts +19 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentWidgets.js +762 -359
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatImplicitContext.d.ts +22 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatImplicitContext.js +188 -99
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/implicitContextAttachment.d.ts +9 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/implicitContextAttachment.js +166 -113
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingActions.d.ts +12 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingActions.js +279 -213
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorActions.d.ts +46 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorActions.js +533 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorOverlay.d.ts +28 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorOverlay.js +382 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingExplanationWidget.d.ts +101 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingExplanationWidget.js +509 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/media/chatEditingEditorOverlay.css +130 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/media/chatEditingExplanationWidget.css +276 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessionPickerActionItem.d.ts +24 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessionPickerActionItem.js +128 -52
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessions.contribution.d.ts +153 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessions.contribution.js +1218 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/media/chatSessionPickerActionItem.css +14 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/searchableOptionPickerActionItem.d.ts +39 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/searchableOptionPickerActionItem.js +193 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewWelcomeController.d.ts +2 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewWelcomeController.js +93 -89
- package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewsWelcome.js +5 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatAgentHover.js +42 -47
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentMarkdownRenderer.js +58 -56
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAgentCommandContentPart.js +18 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAnonymousRateLimitedPart.js +17 -15
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAttachmentsContentPart.d.ts +6 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAttachmentsContentPart.js +132 -68
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatChangesSummaryPart.d.ts +0 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatChangesSummaryPart.js +68 -47
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCodeCitationContentPart.js +14 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCollapsibleContentPart.d.ts +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCollapsibleContentPart.js +36 -24
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCollapsibleMarkdownContentPart.d.ts +18 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCollapsibleMarkdownContentPart.js +32 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCollections.d.ts +7 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCollections.js +15 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCommandContentPart.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCommandContentPart.js +22 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationContentPart.d.ts +0 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationContentPart.js +34 -27
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationWidget.d.ts +1 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationWidget.js +198 -135
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatContentCodePools.d.ts +2 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatContentCodePools.js +38 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatDiffBlockPart.js +29 -27
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatElicitationContentPart.d.ts +0 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatElicitationContentPart.js +41 -36
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatErrorConfirmationPart.d.ts +0 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatErrorConfirmationPart.js +23 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatErrorContentPart.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatExtensionsContentPart.d.ts +0 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatExtensionsContentPart.js +20 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatInlineAnchorWidget.d.ts +11 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatInlineAnchorWidget.js +291 -152
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMarkdownContentPart.d.ts +2 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMarkdownContentPart.js +227 -162
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMarkdownDecorationsRenderer.js +68 -72
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMcpServersInteractionContentPart.d.ts +2 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMcpServersInteractionContentPart.js +76 -75
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMultiDiffContentPart.d.ts +2 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMultiDiffContentPart.js +96 -76
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatProgressContentPart.d.ts +4 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatProgressContentPart.js +74 -38
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatPullRequestContentPart.d.ts +0 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatPullRequestContentPart.js +11 -25
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuestionCarouselPart.d.ts +107 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuestionCarouselPart.js +814 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuotaExceededPart.d.ts +0 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuotaExceededPart.js +34 -29
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatReferencesContentPart.d.ts +8 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatReferencesContentPart.js +236 -197
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSubagentContentPart.d.ts +123 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSubagentContentPart.js +492 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSuggestNextWidget.js +75 -47
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTaskContentPart.d.ts +2 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTaskContentPart.js +31 -20
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTextEditContentPart.d.ts +0 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTextEditContentPart.js +42 -36
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatThinkingContentPart.d.ts +55 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatThinkingContentPart.js +714 -148
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTipContentPart.d.ts +7 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTipContentPart.js +21 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTodoListWidget.d.ts +2 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTodoListWidget.js +143 -153
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolInputOutputContentPart.d.ts +14 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolInputOutputContentPart.js +79 -61
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolOutputContentSubPart.d.ts +10 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolOutputContentSubPart.js +209 -77
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTreeContentPart.d.ts +9 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTreeContentPart.js +71 -54
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatWorkspaceEditContentPart.d.ts +18 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatWorkspaceEditContentPart.js +83 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/codeBlockPart.d.ts +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/codeBlockPart.js +248 -190
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatConfirmationWidget.css +1 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatInlineAnchorWidget.css +23 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatPullRequestContent.css +5 -41
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatQuestionCarousel.css +493 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatSubagentContent.css +63 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatTerminalToolProgressPart.css +9 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatThinkingContent.css +121 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatTipContent.css +37 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/abstractToolConfirmationSubPart.js +51 -45
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatExtensionsInstallToolSubPart.js +46 -42
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatInputOutputMarkdownProgressPart.d.ts +4 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatInputOutputMarkdownProgressPart.js +99 -67
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppModel.d.ts +112 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppModel.js +634 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppSubPart.d.ts +49 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppSubPart.js +132 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatResultListSubPart.js +15 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolConfirmationSubPart.js +196 -149
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolProgressPart.d.ts +17 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolProgressPart.js +577 -193
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolConfirmationSubPart.js +119 -86
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolInvocationPart.d.ts +10 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolInvocationPart.js +165 -36
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolInvocationSubPart.d.ts +0 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolInvocationSubPart.js +5 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolOutputPart.d.ts +5 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolOutputPart.js +75 -65
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPartUtilities.js +30 -28
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPostExecuteConfirmationPart.d.ts +1 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPostExecuteConfirmationPart.js +102 -106
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolProgressPart.js +44 -20
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolStreamingSubPart.d.ts +19 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolStreamingSubPart.js +67 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/terminalToolAutoExpand.d.ts +57 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/terminalToolAutoExpand.js +69 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatDragAndDrop.js +122 -82
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.d.ts +39 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.js +1110 -597
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListWidget.d.ts +291 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListWidget.js +485 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatOptions.js +38 -28
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatWidget.d.ts +9 -20
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatWidget.js +650 -689
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatFollowups.js +21 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPart.d.ts +102 -36
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPart.js +1253 -790
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPartWidgets.d.ts +0 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPartWidgets.js +11 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPickerActionItem.d.ts +34 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPickerActionItem.js +55 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatSelectedTools.d.ts +6 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatSelectedTools.js +51 -35
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/delegationSessionPickerActionItem.d.ts +22 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/delegationSessionPickerActionItem.js +102 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modePickerActionItem.d.ts +16 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modePickerActionItem.js +192 -44
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modelPickerActionItem.d.ts +11 -12
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modelPickerActionItem.js +99 -66
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/sessionTargetPickerActionItem.d.ts +47 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/sessionTargetPickerActionItem.js +188 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/workspacePickerActionItem.d.ts +20 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/workspacePickerActionItem.js +115 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/media/chat.css +129 -167
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/media/chatViewWelcome.css +16 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageDetails.d.ts +37 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageDetails.js +143 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageWidget.d.ts +56 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageWidget.js +206 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/media/chatContextUsageDetails.css +152 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/media/chatContextUsageWidget.css +67 -0
- package/vscode/src/vs/workbench/contrib/chat/common/widget/annotations.d.ts +22 -0
- package/vscode/src/vs/workbench/contrib/chat/common/widget/annotations.js +170 -0
- package/vscode/src/vs/workbench/contrib/chat/common/widget/chatColors.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/common/widget/chatColors.js +80 -19
- package/vscode/src/vs/workbench/contrib/chat/common/widget/chatWidgetHistoryService.js +20 -28
- package/vscode/src/vs/workbench/contrib/chat/common/widget/codeBlockModelCollection.d.ts +2 -1
- package/vscode/src/vs/workbench/contrib/chat/common/widget/codeBlockModelCollection.js +22 -19
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatAffordance.d.ts +15 -0
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatAffordance.js +122 -0
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatController.d.ts +19 -104
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatController.js +316 -1040
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatEditorAffordance.d.ts +28 -0
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatEditorAffordance.js +162 -0
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatGutterAffordance.d.ts +21 -0
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatGutterAffordance.js +98 -0
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatOverlayWidget.d.ts +68 -0
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatOverlayWidget.js +416 -0
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatWidget.d.ts +1 -6
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatWidget.js +194 -215
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatZoneWidget.d.ts +0 -1
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatZoneWidget.js +74 -104
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/media/inlineChat.css +45 -91
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/media/inlineChatEditorAffordance.css +22 -0
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/media/inlineChatOverlayWidget.css +98 -0
- package/vscode/src/vs/workbench/contrib/inlineChat/common/inlineChat.d.ts +5 -2
- package/vscode/src/vs/workbench/contrib/inlineChat/common/inlineChat.js +96 -68
- package/vscode/src/vs/workbench/contrib/interactive/browser/interactiveCommon.d.ts +7 -0
- package/vscode/src/vs/workbench/contrib/interactive/browser/interactiveCommon.js +11 -0
- package/vscode/src/vs/workbench/contrib/interactive/browser/replInputHintContentWidget.d.ts +20 -0
- package/vscode/src/vs/workbench/contrib/interactive/browser/replInputHintContentWidget.js +150 -0
- package/vscode/src/vs/workbench/contrib/markdown/browser/markedKatexSupport.js +141 -147
- package/vscode/src/vs/workbench/contrib/mcp/browser/mcpToolCallUI.d.ts +64 -0
- package/vscode/src/vs/workbench/contrib/mcp/browser/mcpToolCallUI.js +200 -0
- package/vscode/src/vs/workbench/contrib/mcp/common/modelContextProtocolApps.d.ts +548 -0
- package/vscode/src/vs/workbench/contrib/mcp/common/modelContextProtocolApps.js +23 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/executionStatusBarItemController.d.ts +22 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/executionStatusBarItemController.js +338 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/notebookVisibleCellObserver.d.ts +18 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/notebookVisibleCellObserver.js +58 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindWidget.d.ts +75 -0
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindWidget.js +364 -0
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/interactiveEditor.css +21 -0
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/media/interactive.css +36 -0
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditor.d.ts +110 -0
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditor.js +692 -0
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditorInput.d.ts +40 -0
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditorInput.js +158 -0
- package/vscode/src/vs/workbench/contrib/terminal/browser/chatTerminalCommandMirror.d.ts +80 -21
- package/vscode/src/vs/workbench/contrib/terminal/browser/chatTerminalCommandMirror.js +440 -82
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatInputRelatedFilesContrib.d.ts +0 -34
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatInputRelatedFilesContrib.js +0 -139
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputCompletions.d.ts +0 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputCompletions.js +0 -1081
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSession.d.ts +0 -199
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSession.js +0 -482
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionService.d.ts +0 -28
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionService.js +0 -37
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionServiceImpl.d.ts +0 -94
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionServiceImpl.js +0 -495
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatStrategies.d.ts +0 -72
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatStrategies.js +0 -454
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/utils.d.ts +0 -13
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/utils.js +0 -66
- package/vscode/src/vs/workbench/contrib/mcp/browser/mcpPromptArgumentPick.d.ts +0 -41
- package/vscode/src/vs/workbench/contrib/mcp/browser/mcpPromptArgumentPick.js +0 -372
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/chat/notebookChatUtils.d.ts +0 -4
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/chat/notebookChatUtils.js +0 -58
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/cellOperations.d.ts +0 -26
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/cellOperations.js +0 -594
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffCellEditorOptions.d.ts +0 -8
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffCellEditorOptions.js +0 -55
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffComponents.d.ts +0 -273
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffComponents.js +0 -1746
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementOutputs.d.ts +0 -50
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementOutputs.js +0 -269
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementViewModel.d.ts +0 -258
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementViewModel.js +0 -806
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffNestedCellViewModel.d.ts +0 -41
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffNestedCellViewModel.js +0 -116
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/editorHeightCalculator.d.ts +0 -17
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/editorHeightCalculator.js +0 -62
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/eventDispatcher.d.ts +0 -27
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/eventDispatcher.js +0 -40
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookCellDiffDecorator.d.ts +0 -23
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookCellDiffDecorator.js +0 -295
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookDeletedCellDecorator.d.ts +0 -51
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookDeletedCellDecorator.js +0 -241
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInlineDiff.d.ts +0 -24
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInlineDiff.js +0 -146
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInlineDiffWidget.d.ts +0 -28
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInlineDiffWidget.js +0 -90
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInsertedCellDecorator.d.ts +0 -10
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInsertedCellDecorator.js +0 -41
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookOriginalCellModelFactory.d.ts +0 -21
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookOriginalCellModelFactory.js +0 -42
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookOriginalModelRefFactory.d.ts +0 -25
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookOriginalModelRefFactory.js +0 -77
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiff.css +0 -469
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditor.d.ts +0 -149
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditor.js +0 -823
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditorBrowser.d.ts +0 -180
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditorBrowser.js +0 -29
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffList.d.ts +0 -102
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffList.js +0 -567
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffOverviewRuler.d.ts +0 -30
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffOverviewRuler.js +0 -189
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffViewModel.d.ts +0 -75
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffViewModel.js +0 -439
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookMultiDiffEditor.d.ts +0 -57
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookMultiDiffEditor.js +0 -263
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookMultiDiffEditorInput.d.ts +0 -22
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookMultiDiffEditorInput.js +0 -48
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/unchangedEditorRegions.d.ts +0 -13
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/unchangedEditorRegions.js +0 -39
- package/vscode/src/vs/workbench/contrib/notebook/common/model/notebookMetadataTextModel.d.ts +0 -19
- package/vscode/src/vs/workbench/contrib/notebook/common/model/notebookMetadataTextModel.js +0 -89
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookDiff.d.ts +0 -26
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookDiff.js +0 -92
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookDiffEditorInput.d.ts +0 -33
- package/vscode/src/vs/workbench/contrib/notebook/common/notebookDiffEditorInput.js +0 -108
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { Event } from "@codingame/monaco-vscode-api/vscode/vs/base/common/event";
|
|
2
1
|
import { Disposable, IDisposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
|
|
3
2
|
import { ContextKeyExpression } from "@codingame/monaco-vscode-api/vscode/vs/platform/contextkey/common/contextkey";
|
|
4
3
|
import { IContextKeyService } from "@codingame/monaco-vscode-api/vscode/vs/platform/contextkey/common/contextkey.service";
|
|
@@ -11,10 +10,6 @@ export interface IChatInputPartWidget extends IDisposable {
|
|
|
11
10
|
* The DOM node of the widget.
|
|
12
11
|
*/
|
|
13
12
|
readonly domNode: HTMLElement;
|
|
14
|
-
/**
|
|
15
|
-
* Fired when the height of the widget changes.
|
|
16
|
-
*/
|
|
17
|
-
readonly onDidChangeHeight: Event<void>;
|
|
18
13
|
/**
|
|
19
14
|
* The current height of the widget in pixels.
|
|
20
15
|
*/
|
|
@@ -42,8 +37,6 @@ export declare class ChatInputPartWidgetController extends Disposable {
|
|
|
42
37
|
private readonly container;
|
|
43
38
|
private readonly contextKeyService;
|
|
44
39
|
private readonly instantiationService;
|
|
45
|
-
private readonly _onDidChangeHeight;
|
|
46
|
-
readonly onDidChangeHeight: Event<void>;
|
|
47
40
|
private readonly renderedWidgets;
|
|
48
41
|
constructor(container: HTMLElement, contextKeyService: IContextKeyService, instantiationService: IInstantiationService);
|
|
49
42
|
private update;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
|
|
2
2
|
import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
|
|
3
|
-
import { Emitter } from '@codingame/monaco-vscode-api/vscode/vs/base/common/event';
|
|
4
3
|
import { Disposable, DisposableStore } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
|
|
5
4
|
import { IContextKeyService } from '@codingame/monaco-vscode-api/vscode/vs/platform/contextkey/common/contextkey.service';
|
|
6
5
|
import { IInstantiationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation';
|
|
@@ -10,7 +9,11 @@ const ChatInputPartWidgetsRegistry = new (class {
|
|
|
10
9
|
this.widgets = [];
|
|
11
10
|
}
|
|
12
11
|
register(id, ctor, when) {
|
|
13
|
-
this.widgets.push({
|
|
12
|
+
this.widgets.push({
|
|
13
|
+
id,
|
|
14
|
+
ctor: ctor,
|
|
15
|
+
when
|
|
16
|
+
});
|
|
14
17
|
}
|
|
15
18
|
getWidgets() {
|
|
16
19
|
return this.widgets;
|
|
@@ -22,8 +25,6 @@ let ChatInputPartWidgetController = class ChatInputPartWidgetController extends
|
|
|
22
25
|
this.container = container;
|
|
23
26
|
this.contextKeyService = contextKeyService;
|
|
24
27
|
this.instantiationService = instantiationService;
|
|
25
|
-
this._onDidChangeHeight = this._register(( new Emitter()));
|
|
26
|
-
this.onDidChangeHeight = this._onDidChangeHeight.event;
|
|
27
28
|
this.renderedWidgets = ( new Map());
|
|
28
29
|
this.update();
|
|
29
30
|
this._register(this.contextKeyService.onDidChangeContext(e => {
|
|
@@ -62,12 +63,14 @@ let ChatInputPartWidgetController = class ChatInputPartWidgetController extends
|
|
|
62
63
|
const disposables = ( new DisposableStore());
|
|
63
64
|
const widget = this.instantiationService.createInstance(descriptor.ctor);
|
|
64
65
|
disposables.add(widget);
|
|
65
|
-
|
|
66
|
-
|
|
66
|
+
this.renderedWidgets.set(descriptor.id, {
|
|
67
|
+
descriptor,
|
|
68
|
+
widget,
|
|
69
|
+
disposables
|
|
70
|
+
});
|
|
67
71
|
this.container.appendChild(widget.domNode);
|
|
68
72
|
}
|
|
69
73
|
}
|
|
70
|
-
this._onDidChangeHeight.fire();
|
|
71
74
|
}
|
|
72
75
|
get height() {
|
|
73
76
|
let total = 0;
|
|
@@ -85,9 +88,6 @@ let ChatInputPartWidgetController = class ChatInputPartWidgetController extends
|
|
|
85
88
|
super.dispose();
|
|
86
89
|
}
|
|
87
90
|
};
|
|
88
|
-
ChatInputPartWidgetController = ( __decorate([
|
|
89
|
-
( __param(1, IContextKeyService)),
|
|
90
|
-
( __param(2, IInstantiationService))
|
|
91
|
-
], ChatInputPartWidgetController));
|
|
91
|
+
ChatInputPartWidgetController = ( __decorate([( __param(1, IContextKeyService)), ( __param(2, IInstantiationService))], ChatInputPartWidgetController));
|
|
92
92
|
|
|
93
93
|
export { ChatInputPartWidgetController, ChatInputPartWidgetsRegistry };
|
package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPickerActionItem.d.ts
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { IHoverPositionOptions } from "@codingame/monaco-vscode-api/vscode/vs/base/browser/ui/hover/hover";
|
|
2
|
+
import { IAction } from "@codingame/monaco-vscode-api/vscode/vs/base/common/actions";
|
|
3
|
+
import { IObservable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/observable";
|
|
4
|
+
import { ActionWidgetDropdownActionViewItem } from "../../../../../../platform/actions/browser/actionWidgetDropdownActionViewItem.js";
|
|
5
|
+
import { IActionWidgetService } from "@codingame/monaco-vscode-api/vscode/vs/platform/actionWidget/browser/actionWidget.service";
|
|
6
|
+
import { IActionWidgetDropdownOptions } from "../../../../../../platform/actionWidget/browser/actionWidgetDropdown.js";
|
|
7
|
+
import { IContextKeyService } from "@codingame/monaco-vscode-api/vscode/vs/platform/contextkey/common/contextkey.service";
|
|
8
|
+
import { IKeybindingService } from "@codingame/monaco-vscode-api/vscode/vs/platform/keybinding/common/keybinding.service";
|
|
9
|
+
import { ITelemetryService } from "@codingame/monaco-vscode-api/vscode/vs/platform/telemetry/common/telemetry.service";
|
|
10
|
+
import { IChatExecuteActionContext } from "../../actions/chatExecuteActions.js";
|
|
11
|
+
export interface IChatInputPickerOptions {
|
|
12
|
+
/**
|
|
13
|
+
* Provides a fallback anchor element when the picker's own element
|
|
14
|
+
* is not available in the DOM (e.g., when inside an overflow menu).
|
|
15
|
+
*/
|
|
16
|
+
readonly getOverflowAnchor?: () => HTMLElement | undefined;
|
|
17
|
+
readonly actionContext?: IChatExecuteActionContext;
|
|
18
|
+
readonly onlyShowIconsForDefaultActions: IObservable<boolean>;
|
|
19
|
+
readonly hoverPosition?: IHoverPositionOptions;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Base class for chat input picker action items (model picker, mode picker, session target picker).
|
|
23
|
+
* Provides common anchor resolution logic for dropdown positioning.
|
|
24
|
+
*/
|
|
25
|
+
export declare abstract class ChatInputPickerActionViewItem extends ActionWidgetDropdownActionViewItem {
|
|
26
|
+
protected readonly pickerOptions: IChatInputPickerOptions;
|
|
27
|
+
constructor(action: IAction, actionWidgetOptions: Omit<IActionWidgetDropdownOptions, "label" | "labelRenderer">, pickerOptions: IChatInputPickerOptions, actionWidgetService: IActionWidgetService, keybindingService: IKeybindingService, contextKeyService: IContextKeyService, telemetryService: ITelemetryService);
|
|
28
|
+
/**
|
|
29
|
+
* Returns the anchor element for the dropdown.
|
|
30
|
+
* Falls back to the overflow anchor if this element is not in the DOM.
|
|
31
|
+
*/
|
|
32
|
+
protected getAnchorElement(): HTMLElement;
|
|
33
|
+
render(container: HTMLElement): void;
|
|
34
|
+
}
|
package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPickerActionItem.js
ADDED
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
|
|
2
|
+
import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
|
|
3
|
+
import { getActiveWindow } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/dom';
|
|
4
|
+
import '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/index';
|
|
5
|
+
import { ActionWidgetDropdownActionViewItem } from '../../../../../../platform/actions/browser/actionWidgetDropdownActionViewItem.js';
|
|
6
|
+
import { IActionWidgetService } from '@codingame/monaco-vscode-api/vscode/vs/platform/actionWidget/browser/actionWidget.service';
|
|
7
|
+
import { IContextKeyService } from '@codingame/monaco-vscode-api/vscode/vs/platform/contextkey/common/contextkey.service';
|
|
8
|
+
import { IKeybindingService } from '@codingame/monaco-vscode-api/vscode/vs/platform/keybinding/common/keybinding.service';
|
|
9
|
+
import { ITelemetryService } from '@codingame/monaco-vscode-api/vscode/vs/platform/telemetry/common/telemetry.service';
|
|
10
|
+
import { autorun } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/reactions/autorun';
|
|
11
|
+
|
|
12
|
+
let ChatInputPickerActionViewItem = class ChatInputPickerActionViewItem extends ActionWidgetDropdownActionViewItem {
|
|
13
|
+
constructor(
|
|
14
|
+
action,
|
|
15
|
+
actionWidgetOptions,
|
|
16
|
+
pickerOptions,
|
|
17
|
+
actionWidgetService,
|
|
18
|
+
keybindingService,
|
|
19
|
+
contextKeyService,
|
|
20
|
+
telemetryService
|
|
21
|
+
) {
|
|
22
|
+
const optionsWithAnchor = {
|
|
23
|
+
...actionWidgetOptions,
|
|
24
|
+
getAnchor: () => this.getAnchorElement()
|
|
25
|
+
};
|
|
26
|
+
super(
|
|
27
|
+
action,
|
|
28
|
+
optionsWithAnchor,
|
|
29
|
+
actionWidgetService,
|
|
30
|
+
keybindingService,
|
|
31
|
+
contextKeyService,
|
|
32
|
+
telemetryService
|
|
33
|
+
);
|
|
34
|
+
this.pickerOptions = pickerOptions;
|
|
35
|
+
this._register(autorun(reader => {
|
|
36
|
+
this.pickerOptions.onlyShowIconsForDefaultActions.read(reader);
|
|
37
|
+
if (this.element) {
|
|
38
|
+
this.renderLabel(this.element);
|
|
39
|
+
}
|
|
40
|
+
}));
|
|
41
|
+
}
|
|
42
|
+
getAnchorElement() {
|
|
43
|
+
if (this.element && getActiveWindow().document.contains(this.element)) {
|
|
44
|
+
return this.element;
|
|
45
|
+
}
|
|
46
|
+
return this.pickerOptions.getOverflowAnchor?.() ?? this.element;
|
|
47
|
+
}
|
|
48
|
+
render(container) {
|
|
49
|
+
super.render(container);
|
|
50
|
+
container.classList.add("chat-input-picker-item");
|
|
51
|
+
}
|
|
52
|
+
};
|
|
53
|
+
ChatInputPickerActionViewItem = ( __decorate([( __param(3, IActionWidgetService)), ( __param(4, IKeybindingService)), ( __param(5, IContextKeyService)), ( __param(6, ITelemetryService))], ChatInputPickerActionViewItem));
|
|
54
|
+
|
|
55
|
+
export { ChatInputPickerActionViewItem };
|
|
@@ -2,8 +2,9 @@ import { Disposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/l
|
|
|
2
2
|
import { IObservable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/observable";
|
|
3
3
|
import { IInstantiationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation";
|
|
4
4
|
import { IStorageService } from "@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service";
|
|
5
|
-
import { UserSelectedTools } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/participants/chatAgents";
|
|
6
5
|
import { IChatMode } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatModes";
|
|
6
|
+
import { ILanguageModelChatMetadataAndIdentifier } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/languageModels";
|
|
7
|
+
import { UserSelectedTools } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/participants/chatAgents";
|
|
7
8
|
import { IToolAndToolSetEnablementMap } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsService";
|
|
8
9
|
import { ILanguageModelToolsService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsService.service";
|
|
9
10
|
export declare enum ToolsScope {
|
|
@@ -14,13 +15,16 @@ export declare enum ToolsScope {
|
|
|
14
15
|
}
|
|
15
16
|
export declare class ChatSelectedTools extends Disposable {
|
|
16
17
|
private readonly _mode;
|
|
18
|
+
private readonly languageModel;
|
|
17
19
|
private readonly _toolsService;
|
|
18
20
|
private readonly _instantiationService;
|
|
19
21
|
private readonly _globalState;
|
|
20
22
|
private readonly _sessionStates;
|
|
21
|
-
|
|
23
|
+
private readonly _currentTools;
|
|
24
|
+
constructor(_mode: IObservable<IChatMode>, languageModel: IObservable<ILanguageModelChatMetadataAndIdentifier | undefined>, _toolsService: ILanguageModelToolsService, _storageService: IStorageService, _instantiationService: IInstantiationService);
|
|
22
25
|
/**
|
|
23
26
|
* All tools and tool sets with their enabled state.
|
|
27
|
+
* Tools are filtered based on the current model context.
|
|
24
28
|
*/
|
|
25
29
|
readonly entriesMap: IObservable<IToolAndToolSetEnablementMap>;
|
|
26
30
|
readonly userSelectedTools: IObservable<UserSelectedTools>;
|
|
@@ -9,32 +9,33 @@ import { observableMemento } from '@codingame/monaco-vscode-api/vscode/vs/platfo
|
|
|
9
9
|
import { StorageScope, StorageTarget } from '@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage';
|
|
10
10
|
import { IStorageService } from '@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service';
|
|
11
11
|
import { ChatModeKind } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/constants';
|
|
12
|
-
import { ToolSet } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsService';
|
|
13
|
-
import { ILanguageModelToolsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsService.service';
|
|
14
12
|
import { PromptsStorage } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/promptSyntax/service/promptsService';
|
|
13
|
+
import { isToolSet } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsService';
|
|
14
|
+
import { ILanguageModelToolsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/tools/languageModelToolsService.service';
|
|
15
15
|
import { PromptFileRewriter } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/promptSyntax/promptFileRewriter';
|
|
16
16
|
import { ObservableMap } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/map';
|
|
17
17
|
import { derived } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/observables/derived';
|
|
18
18
|
|
|
19
19
|
var ToolEnablementStates;
|
|
20
|
-
(function
|
|
20
|
+
(function(ToolEnablementStates) {
|
|
21
21
|
function fromMap(map) {
|
|
22
|
-
const toolSets = ( new Map()),
|
|
22
|
+
const toolSets = ( new Map()),
|
|
23
|
+
tools = ( new Map());
|
|
23
24
|
for (const [entry, enabled] of map.entries()) {
|
|
24
|
-
if (entry
|
|
25
|
+
if (isToolSet(entry)) {
|
|
25
26
|
toolSets.set(entry.id, enabled);
|
|
26
|
-
}
|
|
27
|
-
else {
|
|
27
|
+
} else {
|
|
28
28
|
tools.set(entry.id, enabled);
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
|
-
return {
|
|
31
|
+
return {
|
|
32
|
+
toolSets,
|
|
33
|
+
tools
|
|
34
|
+
};
|
|
32
35
|
}
|
|
33
36
|
ToolEnablementStates.fromMap = fromMap;
|
|
34
37
|
function isStoredDataV1(data) {
|
|
35
|
-
return isObject(data) && data.version === undefined
|
|
36
|
-
&& (data.disabledTools === undefined || Array.isArray(data.disabledTools))
|
|
37
|
-
&& (data.disabledToolSets === undefined || Array.isArray(data.disabledToolSets));
|
|
38
|
+
return isObject(data) && data.version === undefined && (data.disabledTools === undefined || Array.isArray(data.disabledTools)) && (data.disabledToolSets === undefined || Array.isArray(data.disabledToolSets));
|
|
38
39
|
}
|
|
39
40
|
function isStoredDataV2(data) {
|
|
40
41
|
return isObject(data) && data.version === 2 && Array.isArray(data.toolSetEntries) && Array.isArray(data.toolEntries);
|
|
@@ -43,17 +44,23 @@ var ToolEnablementStates;
|
|
|
43
44
|
try {
|
|
44
45
|
const parsed = JSON.parse(storage);
|
|
45
46
|
if (isStoredDataV2(parsed)) {
|
|
46
|
-
return {
|
|
47
|
-
|
|
48
|
-
|
|
47
|
+
return {
|
|
48
|
+
toolSets: ( new Map(parsed.toolSetEntries)),
|
|
49
|
+
tools: ( new Map(parsed.toolEntries))
|
|
50
|
+
};
|
|
51
|
+
} else if (isStoredDataV1(parsed)) {
|
|
49
52
|
const toolSetEntries = parsed.disabledToolSets?.map(id => [id, false]);
|
|
50
53
|
const toolEntries = parsed.disabledTools?.map(id => [id, false]);
|
|
51
|
-
return {
|
|
54
|
+
return {
|
|
55
|
+
toolSets: ( new Map(toolSetEntries)),
|
|
56
|
+
tools: ( new Map(toolEntries))
|
|
57
|
+
};
|
|
52
58
|
}
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
59
|
+
} catch {}
|
|
60
|
+
return {
|
|
61
|
+
toolSets: ( new Map()),
|
|
62
|
+
tools: ( new Map())
|
|
63
|
+
};
|
|
57
64
|
}
|
|
58
65
|
ToolEnablementStates.fromStorage = fromStorage;
|
|
59
66
|
function toStorage(state) {
|
|
@@ -67,39 +74,47 @@ var ToolEnablementStates;
|
|
|
67
74
|
ToolEnablementStates.toStorage = toStorage;
|
|
68
75
|
})(ToolEnablementStates || (ToolEnablementStates = {}));
|
|
69
76
|
var ToolsScope;
|
|
70
|
-
(function
|
|
77
|
+
(function(ToolsScope) {
|
|
71
78
|
ToolsScope[ToolsScope["Global"] = 0] = "Global";
|
|
72
79
|
ToolsScope[ToolsScope["Session"] = 1] = "Session";
|
|
73
80
|
ToolsScope[ToolsScope["Agent"] = 2] = "Agent";
|
|
74
81
|
ToolsScope[ToolsScope["Agent_ReadOnly"] = 3] = "Agent_ReadOnly";
|
|
75
82
|
})(ToolsScope || (ToolsScope = {}));
|
|
76
83
|
let ChatSelectedTools = class ChatSelectedTools extends Disposable {
|
|
77
|
-
constructor(
|
|
84
|
+
constructor(
|
|
85
|
+
_mode,
|
|
86
|
+
languageModel,
|
|
87
|
+
_toolsService,
|
|
88
|
+
_storageService,
|
|
89
|
+
_instantiationService
|
|
90
|
+
) {
|
|
78
91
|
super();
|
|
79
92
|
this._mode = _mode;
|
|
93
|
+
this.languageModel = languageModel;
|
|
80
94
|
this._toolsService = _toolsService;
|
|
81
95
|
this._instantiationService = _instantiationService;
|
|
82
96
|
this._sessionStates = ( new ObservableMap());
|
|
83
97
|
this.entriesMap = derived(r => {
|
|
84
98
|
const map = ( new Map());
|
|
99
|
+
const lm = this.languageModel.read(r)?.metadata;
|
|
85
100
|
const currentMode = this._mode.read(r);
|
|
86
101
|
let currentMap = this._sessionStates.observable.read(r).get(currentMode.id);
|
|
87
102
|
if (!currentMap && currentMode.kind === ChatModeKind.Agent) {
|
|
88
103
|
const modeTools = currentMode.customTools?.read(r);
|
|
89
104
|
if (modeTools) {
|
|
90
105
|
const target = currentMode.target?.read(r);
|
|
91
|
-
currentMap = ToolEnablementStates.fromMap(this._toolsService.toToolAndToolSetEnablementMap(modeTools, target));
|
|
106
|
+
currentMap = ToolEnablementStates.fromMap(this._toolsService.toToolAndToolSetEnablementMap(modeTools, target, lm));
|
|
92
107
|
}
|
|
93
108
|
}
|
|
94
109
|
if (!currentMap) {
|
|
95
110
|
currentMap = this._globalState.read(r);
|
|
96
111
|
}
|
|
97
|
-
for (const tool of this.
|
|
112
|
+
for (const tool of this._currentTools.read(r)) {
|
|
98
113
|
if (tool.canBeReferencedInPrompt) {
|
|
99
114
|
map.set(tool, currentMap.tools.get(tool.id) !== false);
|
|
100
115
|
}
|
|
101
116
|
}
|
|
102
|
-
for (const toolSet of this._toolsService.
|
|
117
|
+
for (const toolSet of this._toolsService.getToolSetsForModel(lm, r)) {
|
|
103
118
|
const toolSetEnabled = currentMap.toolSets.get(toolSet.id) !== false;
|
|
104
119
|
map.set(toolSet, toolSetEnabled);
|
|
105
120
|
for (const tool of toolSet.getTools(r)) {
|
|
@@ -112,19 +127,25 @@ let ChatSelectedTools = class ChatSelectedTools extends Disposable {
|
|
|
112
127
|
const result = {};
|
|
113
128
|
const map = this.entriesMap.read(r);
|
|
114
129
|
for (const [item, enabled] of map) {
|
|
115
|
-
if (!(item
|
|
130
|
+
if (!isToolSet(item)) {
|
|
116
131
|
result[item.id] = enabled;
|
|
117
132
|
}
|
|
118
133
|
}
|
|
119
134
|
return result;
|
|
120
135
|
});
|
|
121
136
|
const globalStateMemento = observableMemento({
|
|
122
|
-
key:
|
|
123
|
-
defaultValue: {
|
|
137
|
+
key: "chat/selectedTools",
|
|
138
|
+
defaultValue: {
|
|
139
|
+
toolSets: ( new Map()),
|
|
140
|
+
tools: ( new Map())
|
|
141
|
+
},
|
|
124
142
|
fromStorage: ToolEnablementStates.fromStorage,
|
|
125
143
|
toStorage: ToolEnablementStates.toStorage
|
|
126
144
|
});
|
|
127
|
-
this._globalState = this._store.add(
|
|
145
|
+
this._globalState = this._store.add(
|
|
146
|
+
globalStateMemento(StorageScope.PROFILE, StorageTarget.MACHINE, _storageService)
|
|
147
|
+
);
|
|
148
|
+
this._currentTools = ( ( languageModel.map(lm => _toolsService.observeTools(lm?.metadata))).map((o, r) => o.read(r)));
|
|
128
149
|
}
|
|
129
150
|
get entriesScope() {
|
|
130
151
|
const mode = this._mode.get();
|
|
@@ -153,8 +174,7 @@ let ChatSelectedTools = class ChatSelectedTools extends Disposable {
|
|
|
153
174
|
if (mode.source?.storage !== PromptsStorage.extension) {
|
|
154
175
|
this.updateCustomModeTools(mode.uri.get(), enablementMap);
|
|
155
176
|
return;
|
|
156
|
-
}
|
|
157
|
-
else {
|
|
177
|
+
} else {
|
|
158
178
|
this._sessionStates.set(mode.id, ToolEnablementStates.fromMap(enablementMap));
|
|
159
179
|
return;
|
|
160
180
|
}
|
|
@@ -165,10 +185,6 @@ let ChatSelectedTools = class ChatSelectedTools extends Disposable {
|
|
|
165
185
|
await this._instantiationService.createInstance(PromptFileRewriter).openAndRewriteTools(uri, enablementMap, CancellationToken.None);
|
|
166
186
|
}
|
|
167
187
|
};
|
|
168
|
-
ChatSelectedTools = ( __decorate([
|
|
169
|
-
( __param(1, ILanguageModelToolsService)),
|
|
170
|
-
( __param(2, IStorageService)),
|
|
171
|
-
( __param(3, IInstantiationService))
|
|
172
|
-
], ChatSelectedTools));
|
|
188
|
+
ChatSelectedTools = ( __decorate([( __param(2, ILanguageModelToolsService)), ( __param(3, IStorageService)), ( __param(4, IInstantiationService))], ChatSelectedTools));
|
|
173
189
|
|
|
174
190
|
export { ChatSelectedTools, ToolsScope };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { IAction } from "@codingame/monaco-vscode-api/vscode/vs/base/common/actions";
|
|
2
|
+
import { IActionWidgetDropdownAction } from "../../../../../../platform/actionWidget/browser/actionWidgetDropdown.js";
|
|
3
|
+
import { AgentSessionProviders } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessions";
|
|
4
|
+
import { ISessionTypeItem, SessionTypePickerActionItem } from "./sessionTargetPickerActionItem.js";
|
|
5
|
+
/**
|
|
6
|
+
* Action view item for delegating to a remote session (Background or Cloud).
|
|
7
|
+
* This picker allows switching to remote execution providers when the session is not empty.
|
|
8
|
+
*/
|
|
9
|
+
export declare class DelegationSessionPickerActionItem extends SessionTypePickerActionItem {
|
|
10
|
+
protected _run(sessionTypeItem: ISessionTypeItem): void;
|
|
11
|
+
protected _getSelectedSessionType(): AgentSessionProviders | undefined;
|
|
12
|
+
protected _isSessionTypeEnabled(type: AgentSessionProviders): boolean;
|
|
13
|
+
protected _isVisible(type: AgentSessionProviders): boolean;
|
|
14
|
+
protected _getSessionCategory(sessionTypeItem: ISessionTypeItem): {
|
|
15
|
+
label: string;
|
|
16
|
+
order: number;
|
|
17
|
+
showHeader: boolean;
|
|
18
|
+
};
|
|
19
|
+
protected _getSessionDescription(sessionTypeItem: ISessionTypeItem): string | undefined;
|
|
20
|
+
protected _getLearnMore(): IAction;
|
|
21
|
+
protected _getAdditionalActions(): IActionWidgetDropdownAction[];
|
|
22
|
+
}
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
|
|
2
|
+
import { Codicon } from '@codingame/monaco-vscode-api/vscode/vs/base/common/codicons';
|
|
3
|
+
import { URI } from '@codingame/monaco-vscode-api/vscode/vs/base/common/uri';
|
|
4
|
+
import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
|
|
5
|
+
import { ACTION_ID_NEW_CHAT } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/actions/chatActions';
|
|
6
|
+
import { getAgentSessionProvider, AgentSessionProviders, getAgentCanContinueIn, isFirstPartyAgentSessionProvider } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessions';
|
|
7
|
+
import { SessionTypePickerActionItem } from './sessionTargetPickerActionItem.js';
|
|
8
|
+
|
|
9
|
+
class DelegationSessionPickerActionItem extends SessionTypePickerActionItem {
|
|
10
|
+
_run(sessionTypeItem) {
|
|
11
|
+
if (this.delegate.setPendingDelegationTarget) {
|
|
12
|
+
this.delegate.setPendingDelegationTarget(sessionTypeItem.type);
|
|
13
|
+
}
|
|
14
|
+
if (this.element) {
|
|
15
|
+
this.renderLabel(this.element);
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
_getSelectedSessionType() {
|
|
19
|
+
const delegationTarget = this.delegate.getPendingDelegationTarget ? this.delegate.getPendingDelegationTarget() : undefined;
|
|
20
|
+
if (delegationTarget) {
|
|
21
|
+
return delegationTarget;
|
|
22
|
+
}
|
|
23
|
+
return this.delegate.getActiveSessionProvider();
|
|
24
|
+
}
|
|
25
|
+
_isSessionTypeEnabled(type) {
|
|
26
|
+
const allContributions = this.chatSessionsService.getAllChatSessionContributions();
|
|
27
|
+
const contribution = allContributions.find(contribution => getAgentSessionProvider(contribution.type) === type);
|
|
28
|
+
if (this.delegate.getActiveSessionProvider() !== AgentSessionProviders.Local) {
|
|
29
|
+
return false;
|
|
30
|
+
}
|
|
31
|
+
if (contribution && !contribution.canDelegate && this.delegate.getActiveSessionProvider() !== type ) {
|
|
32
|
+
return false;
|
|
33
|
+
}
|
|
34
|
+
return this._getSelectedSessionType() !== type;
|
|
35
|
+
}
|
|
36
|
+
_isVisible(type) {
|
|
37
|
+
if (this.delegate.getActiveSessionProvider() === type) {
|
|
38
|
+
return true;
|
|
39
|
+
}
|
|
40
|
+
return getAgentCanContinueIn(type);
|
|
41
|
+
}
|
|
42
|
+
_getSessionCategory(sessionTypeItem) {
|
|
43
|
+
if (isFirstPartyAgentSessionProvider(sessionTypeItem.type)) {
|
|
44
|
+
return {
|
|
45
|
+
label: ( localize(6086, "Continue In")),
|
|
46
|
+
order: 1,
|
|
47
|
+
showHeader: true
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
return {
|
|
51
|
+
label: ( localize(6087, "Continue In (Third Party)")),
|
|
52
|
+
order: 2,
|
|
53
|
+
showHeader: false
|
|
54
|
+
};
|
|
55
|
+
}
|
|
56
|
+
_getSessionDescription(sessionTypeItem) {
|
|
57
|
+
const allContributions = this.chatSessionsService.getAllChatSessionContributions();
|
|
58
|
+
const contribution = allContributions.find(
|
|
59
|
+
contribution => getAgentSessionProvider(contribution.type) === sessionTypeItem.type
|
|
60
|
+
);
|
|
61
|
+
return contribution?.name ? `@${contribution.name}` : undefined;
|
|
62
|
+
}
|
|
63
|
+
_getLearnMore() {
|
|
64
|
+
const learnMoreUrl = "https://aka.ms/vscode-continue-chat-in";
|
|
65
|
+
return {
|
|
66
|
+
id: "workbench.action.chat.agentOverview.learnMoreHandOff",
|
|
67
|
+
label: ( localize(6088, "Learn about agent handoff...")),
|
|
68
|
+
tooltip: learnMoreUrl,
|
|
69
|
+
class: undefined,
|
|
70
|
+
enabled: true,
|
|
71
|
+
run: async () => {
|
|
72
|
+
await this.openerService.open(( URI.parse(learnMoreUrl)));
|
|
73
|
+
}
|
|
74
|
+
};
|
|
75
|
+
}
|
|
76
|
+
_getAdditionalActions() {
|
|
77
|
+
return [{
|
|
78
|
+
id: "newChatSession",
|
|
79
|
+
class: undefined,
|
|
80
|
+
label: ( localize(6089, "New Chat Session")),
|
|
81
|
+
tooltip: "",
|
|
82
|
+
hover: {
|
|
83
|
+
content: "",
|
|
84
|
+
position: this.pickerOptions.hoverPosition
|
|
85
|
+
},
|
|
86
|
+
checked: false,
|
|
87
|
+
icon: Codicon.plus,
|
|
88
|
+
enabled: true,
|
|
89
|
+
category: {
|
|
90
|
+
label: ( localize(6090, "New Chat Session")),
|
|
91
|
+
order: 0,
|
|
92
|
+
showHeader: false
|
|
93
|
+
},
|
|
94
|
+
description: this.keybindingService.lookupKeybinding(ACTION_ID_NEW_CHAT)?.getLabel() || undefined,
|
|
95
|
+
run: async () => {
|
|
96
|
+
this.commandService.executeCommand(ACTION_ID_NEW_CHAT, this.chatSessionPosition);
|
|
97
|
+
}
|
|
98
|
+
}];
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
export { DelegationSessionPickerActionItem };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { IDisposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
|
|
2
2
|
import { IObservable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/observable";
|
|
3
3
|
import { URI } from "@codingame/monaco-vscode-api/vscode/vs/base/common/uri";
|
|
4
|
-
import { ActionWidgetDropdownActionViewItem } from "../../../../../../platform/actions/browser/actionWidgetDropdownActionViewItem.js";
|
|
5
4
|
import { MenuItemAction } from "@codingame/monaco-vscode-api/vscode/vs/platform/actions/common/actions";
|
|
6
5
|
import { IMenuService } from "@codingame/monaco-vscode-api/vscode/vs/platform/actions/common/actions.service";
|
|
7
6
|
import { IActionWidgetService } from "@codingame/monaco-vscode-api/vscode/vs/platform/actionWidget/browser/actionWidget.service";
|
|
@@ -10,19 +9,32 @@ import { IConfigurationService } from "@codingame/monaco-vscode-api/vscode/vs/pl
|
|
|
10
9
|
import { IContextKeyService } from "@codingame/monaco-vscode-api/vscode/vs/platform/contextkey/common/contextkey.service";
|
|
11
10
|
import { IKeybindingService } from "@codingame/monaco-vscode-api/vscode/vs/platform/keybinding/common/keybinding.service";
|
|
12
11
|
import { IProductService } from "@codingame/monaco-vscode-api/vscode/vs/platform/product/common/productService.service";
|
|
12
|
+
import { ITelemetryService } from "@codingame/monaco-vscode-api/vscode/vs/platform/telemetry/common/telemetry.service";
|
|
13
13
|
import { IChatAgentService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/participants/chatAgents.service";
|
|
14
14
|
import { IChatMode } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatModes";
|
|
15
15
|
import { IChatModeService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatModes.service";
|
|
16
|
+
import { ChatInputPickerActionViewItem, IChatInputPickerOptions } from "./chatInputPickerActionItem.js";
|
|
17
|
+
import { IOpenerService } from "@codingame/monaco-vscode-api/vscode/vs/platform/opener/common/opener.service";
|
|
16
18
|
export interface IModePickerDelegate {
|
|
17
19
|
readonly currentMode: IObservable<IChatMode>;
|
|
18
20
|
readonly sessionResource: () => URI | undefined;
|
|
21
|
+
/**
|
|
22
|
+
* When set, the mode picker will show custom agents whose target matches this value.
|
|
23
|
+
* Custom agents without a target are always shown in all session types. If no agents match the target, shows a default "Agent" option.
|
|
24
|
+
*/
|
|
25
|
+
readonly customAgentTarget?: () => string | undefined;
|
|
19
26
|
}
|
|
20
|
-
export declare class ModePickerActionItem extends
|
|
27
|
+
export declare class ModePickerActionItem extends ChatInputPickerActionViewItem {
|
|
21
28
|
private readonly delegate;
|
|
22
29
|
private readonly contextKeyService;
|
|
23
30
|
private readonly menuService;
|
|
24
|
-
|
|
31
|
+
private readonly _productService;
|
|
32
|
+
constructor(action: MenuItemAction, delegate: IModePickerDelegate, pickerOptions: IChatInputPickerOptions, actionWidgetService: IActionWidgetService, chatAgentService: IChatAgentService, keybindingService: IKeybindingService, configurationService: IConfigurationService, contextKeyService: IContextKeyService, chatModeService: IChatModeService, menuService: IMenuService, commandService: ICommandService, _productService: IProductService, telemetryService: ITelemetryService, openerService: IOpenerService);
|
|
25
33
|
private getModePickerActionBarActions;
|
|
26
34
|
protected renderLabel(element: HTMLElement): IDisposable | null;
|
|
27
|
-
render(container: HTMLElement): void;
|
|
28
35
|
}
|
|
36
|
+
/**
|
|
37
|
+
* Returns true if the mode is the built-in 'implement' mode from the chat extension.
|
|
38
|
+
* This mode is hidden from the mode picker but available for handoffs.
|
|
39
|
+
*/
|
|
40
|
+
export declare function isBuiltinImplementMode(mode: IChatMode, productService: IProductService): boolean;
|