@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.
Files changed (317) hide show
  1. package/package.json +2 -2
  2. package/vscode/src/vs/platform/actionWidget/browser/actionWidgetDropdown.d.ts +23 -2
  3. package/vscode/src/vs/platform/actionWidget/browser/actionWidgetDropdown.js +64 -27
  4. package/vscode/src/vs/platform/actions/browser/actionWidgetDropdownActionViewItem.d.ts +3 -1
  5. package/vscode/src/vs/platform/actions/browser/actionWidgetDropdownActionViewItem.js +31 -28
  6. package/vscode/src/vs/platform/actions/browser/buttonbar.d.ts +2 -0
  7. package/vscode/src/vs/platform/actions/browser/buttonbar.js +71 -50
  8. package/vscode/src/vs/platform/editor/browser/editor.js +17 -7
  9. package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatAccessibilityProvider.js +112 -129
  10. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContinueInAction.d.ts +10 -1
  11. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContinueInAction.js +110 -85
  12. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatElicitationActions.js +5 -5
  13. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatExecuteActions.d.ts +21 -6
  14. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatExecuteActions.js +308 -216
  15. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatTitleActions.js +153 -148
  16. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionHoverWidget.d.ts +27 -0
  17. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionHoverWidget.js +247 -0
  18. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.d.ts +71 -0
  19. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.js +347 -0
  20. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.d.ts +44 -0
  21. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.js +287 -0
  22. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsOpener.d.ts +20 -0
  23. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsOpener.js +89 -0
  24. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.d.ts +188 -0
  25. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.js +677 -0
  26. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/media/agentSessionHoverWidget.css +98 -0
  27. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/media/agentsessionsviewer.css +263 -0
  28. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentModel.js +34 -25
  29. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentWidgets.d.ts +19 -14
  30. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentWidgets.js +762 -359
  31. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatImplicitContext.d.ts +22 -1
  32. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatImplicitContext.js +188 -99
  33. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/implicitContextAttachment.d.ts +9 -3
  34. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/implicitContextAttachment.js +166 -113
  35. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingActions.d.ts +12 -5
  36. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingActions.js +279 -213
  37. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorActions.d.ts +46 -0
  38. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorActions.js +533 -0
  39. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorOverlay.d.ts +28 -0
  40. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorOverlay.js +382 -0
  41. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingExplanationWidget.d.ts +101 -0
  42. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingExplanationWidget.js +509 -0
  43. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/media/chatEditingEditorOverlay.css +130 -0
  44. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/media/chatEditingExplanationWidget.css +276 -0
  45. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessionPickerActionItem.d.ts +24 -7
  46. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessionPickerActionItem.js +128 -52
  47. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessions.contribution.d.ts +153 -0
  48. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessions.contribution.js +1218 -0
  49. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/media/chatSessionPickerActionItem.css +14 -0
  50. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/searchableOptionPickerActionItem.d.ts +39 -0
  51. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/searchableOptionPickerActionItem.js +193 -0
  52. package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewWelcomeController.d.ts +2 -0
  53. package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewWelcomeController.js +93 -89
  54. package/vscode/src/vs/workbench/contrib/chat/browser/viewsWelcome/chatViewsWelcome.js +5 -2
  55. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatAgentHover.js +42 -47
  56. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentMarkdownRenderer.js +58 -56
  57. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAgentCommandContentPart.js +18 -14
  58. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAnonymousRateLimitedPart.js +17 -15
  59. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAttachmentsContentPart.d.ts +6 -2
  60. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAttachmentsContentPart.js +132 -68
  61. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatChangesSummaryPart.d.ts +0 -2
  62. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatChangesSummaryPart.js +68 -47
  63. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCodeCitationContentPart.js +14 -13
  64. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCollapsibleContentPart.d.ts +4 -4
  65. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCollapsibleContentPart.js +36 -24
  66. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCollapsibleMarkdownContentPart.d.ts +18 -0
  67. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCollapsibleMarkdownContentPart.js +32 -0
  68. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCollections.d.ts +7 -2
  69. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCollections.js +15 -4
  70. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCommandContentPart.d.ts +1 -0
  71. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCommandContentPart.js +22 -14
  72. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationContentPart.d.ts +0 -2
  73. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationContentPart.js +34 -27
  74. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationWidget.d.ts +1 -5
  75. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationWidget.js +198 -135
  76. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatContentCodePools.d.ts +2 -0
  77. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatContentCodePools.js +38 -10
  78. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatDiffBlockPart.js +29 -27
  79. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatElicitationContentPart.d.ts +0 -2
  80. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatElicitationContentPart.js +41 -36
  81. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatErrorConfirmationPart.d.ts +0 -2
  82. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatErrorConfirmationPart.js +23 -18
  83. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatErrorContentPart.js +13 -13
  84. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatExtensionsContentPart.d.ts +0 -3
  85. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatExtensionsContentPart.js +20 -14
  86. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatInlineAnchorWidget.d.ts +11 -1
  87. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatInlineAnchorWidget.js +291 -152
  88. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMarkdownContentPart.d.ts +2 -3
  89. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMarkdownContentPart.js +227 -162
  90. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMarkdownDecorationsRenderer.js +68 -72
  91. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMcpServersInteractionContentPart.d.ts +2 -4
  92. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMcpServersInteractionContentPart.js +76 -75
  93. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMultiDiffContentPart.d.ts +2 -5
  94. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMultiDiffContentPart.js +96 -76
  95. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatProgressContentPart.d.ts +4 -1
  96. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatProgressContentPart.js +74 -38
  97. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatPullRequestContentPart.d.ts +0 -2
  98. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatPullRequestContentPart.js +11 -25
  99. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuestionCarouselPart.d.ts +107 -0
  100. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuestionCarouselPart.js +814 -0
  101. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuotaExceededPart.d.ts +0 -2
  102. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuotaExceededPart.js +34 -29
  103. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatReferencesContentPart.d.ts +8 -10
  104. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatReferencesContentPart.js +236 -197
  105. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSubagentContentPart.d.ts +123 -0
  106. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSubagentContentPart.js +492 -0
  107. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSuggestNextWidget.js +75 -47
  108. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTaskContentPart.d.ts +2 -4
  109. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTaskContentPart.js +31 -20
  110. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTextEditContentPart.d.ts +0 -3
  111. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTextEditContentPart.js +42 -36
  112. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatThinkingContentPart.d.ts +55 -7
  113. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatThinkingContentPart.js +714 -148
  114. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTipContentPart.d.ts +7 -0
  115. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTipContentPart.js +21 -0
  116. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTodoListWidget.d.ts +2 -7
  117. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTodoListWidget.js +143 -153
  118. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolInputOutputContentPart.d.ts +14 -5
  119. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolInputOutputContentPart.js +79 -61
  120. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolOutputContentSubPart.d.ts +10 -4
  121. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolOutputContentSubPart.js +209 -77
  122. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTreeContentPart.d.ts +9 -7
  123. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTreeContentPart.js +71 -54
  124. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatWorkspaceEditContentPart.d.ts +18 -0
  125. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatWorkspaceEditContentPart.js +83 -0
  126. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/codeBlockPart.d.ts +4 -4
  127. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/codeBlockPart.js +248 -190
  128. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatConfirmationWidget.css +1 -14
  129. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatInlineAnchorWidget.css +23 -0
  130. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatPullRequestContent.css +5 -41
  131. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatQuestionCarousel.css +493 -0
  132. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatSubagentContent.css +63 -0
  133. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatTerminalToolProgressPart.css +9 -1
  134. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatThinkingContent.css +121 -5
  135. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatTipContent.css +37 -0
  136. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/abstractToolConfirmationSubPart.js +51 -45
  137. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatExtensionsInstallToolSubPart.js +46 -42
  138. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatInputOutputMarkdownProgressPart.d.ts +4 -2
  139. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatInputOutputMarkdownProgressPart.js +99 -67
  140. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppModel.d.ts +112 -0
  141. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppModel.js +634 -0
  142. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppSubPart.d.ts +49 -0
  143. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppSubPart.js +132 -0
  144. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatResultListSubPart.js +15 -9
  145. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolConfirmationSubPart.js +196 -149
  146. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolProgressPart.d.ts +17 -1
  147. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolProgressPart.js +577 -193
  148. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolConfirmationSubPart.js +119 -86
  149. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolInvocationPart.d.ts +10 -2
  150. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolInvocationPart.js +165 -36
  151. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolInvocationSubPart.d.ts +0 -2
  152. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolInvocationSubPart.js +5 -8
  153. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolOutputPart.d.ts +5 -3
  154. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolOutputPart.js +75 -65
  155. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPartUtilities.js +30 -28
  156. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPostExecuteConfirmationPart.d.ts +1 -5
  157. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPostExecuteConfirmationPart.js +102 -106
  158. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolProgressPart.js +44 -20
  159. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolStreamingSubPart.d.ts +19 -0
  160. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolStreamingSubPart.js +67 -0
  161. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/terminalToolAutoExpand.d.ts +57 -0
  162. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/terminalToolAutoExpand.js +69 -0
  163. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatDragAndDrop.js +122 -82
  164. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.d.ts +39 -12
  165. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.js +1110 -597
  166. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListWidget.d.ts +291 -0
  167. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListWidget.js +485 -0
  168. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatOptions.js +38 -28
  169. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatWidget.d.ts +9 -20
  170. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatWidget.js +650 -689
  171. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatFollowups.js +21 -18
  172. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPart.d.ts +102 -36
  173. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPart.js +1253 -790
  174. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPartWidgets.d.ts +0 -7
  175. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPartWidgets.js +11 -11
  176. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPickerActionItem.d.ts +34 -0
  177. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPickerActionItem.js +55 -0
  178. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatSelectedTools.d.ts +6 -2
  179. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatSelectedTools.js +51 -35
  180. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/delegationSessionPickerActionItem.d.ts +22 -0
  181. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/delegationSessionPickerActionItem.js +102 -0
  182. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modePickerActionItem.d.ts +16 -4
  183. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modePickerActionItem.js +192 -44
  184. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modelPickerActionItem.d.ts +11 -12
  185. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modelPickerActionItem.js +99 -66
  186. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/sessionTargetPickerActionItem.d.ts +47 -0
  187. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/sessionTargetPickerActionItem.js +188 -0
  188. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/workspacePickerActionItem.d.ts +20 -0
  189. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/workspacePickerActionItem.js +115 -0
  190. package/vscode/src/vs/workbench/contrib/chat/browser/widget/media/chat.css +129 -167
  191. package/vscode/src/vs/workbench/contrib/chat/browser/widget/media/chatViewWelcome.css +16 -3
  192. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageDetails.d.ts +37 -0
  193. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageDetails.js +143 -0
  194. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageWidget.d.ts +56 -0
  195. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageWidget.js +206 -0
  196. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/media/chatContextUsageDetails.css +152 -0
  197. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/media/chatContextUsageWidget.css +67 -0
  198. package/vscode/src/vs/workbench/contrib/chat/common/widget/annotations.d.ts +22 -0
  199. package/vscode/src/vs/workbench/contrib/chat/common/widget/annotations.js +170 -0
  200. package/vscode/src/vs/workbench/contrib/chat/common/widget/chatColors.d.ts +1 -0
  201. package/vscode/src/vs/workbench/contrib/chat/common/widget/chatColors.js +80 -19
  202. package/vscode/src/vs/workbench/contrib/chat/common/widget/chatWidgetHistoryService.js +20 -28
  203. package/vscode/src/vs/workbench/contrib/chat/common/widget/codeBlockModelCollection.d.ts +2 -1
  204. package/vscode/src/vs/workbench/contrib/chat/common/widget/codeBlockModelCollection.js +22 -19
  205. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatAffordance.d.ts +15 -0
  206. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatAffordance.js +122 -0
  207. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatController.d.ts +19 -104
  208. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatController.js +316 -1040
  209. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatEditorAffordance.d.ts +28 -0
  210. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatEditorAffordance.js +162 -0
  211. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatGutterAffordance.d.ts +21 -0
  212. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatGutterAffordance.js +98 -0
  213. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatOverlayWidget.d.ts +68 -0
  214. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatOverlayWidget.js +416 -0
  215. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatWidget.d.ts +1 -6
  216. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatWidget.js +194 -215
  217. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatZoneWidget.d.ts +0 -1
  218. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatZoneWidget.js +74 -104
  219. package/vscode/src/vs/workbench/contrib/inlineChat/browser/media/inlineChat.css +45 -91
  220. package/vscode/src/vs/workbench/contrib/inlineChat/browser/media/inlineChatEditorAffordance.css +22 -0
  221. package/vscode/src/vs/workbench/contrib/inlineChat/browser/media/inlineChatOverlayWidget.css +98 -0
  222. package/vscode/src/vs/workbench/contrib/inlineChat/common/inlineChat.d.ts +5 -2
  223. package/vscode/src/vs/workbench/contrib/inlineChat/common/inlineChat.js +96 -68
  224. package/vscode/src/vs/workbench/contrib/interactive/browser/interactiveCommon.d.ts +7 -0
  225. package/vscode/src/vs/workbench/contrib/interactive/browser/interactiveCommon.js +11 -0
  226. package/vscode/src/vs/workbench/contrib/interactive/browser/replInputHintContentWidget.d.ts +20 -0
  227. package/vscode/src/vs/workbench/contrib/interactive/browser/replInputHintContentWidget.js +150 -0
  228. package/vscode/src/vs/workbench/contrib/markdown/browser/markedKatexSupport.js +141 -147
  229. package/vscode/src/vs/workbench/contrib/mcp/browser/mcpToolCallUI.d.ts +64 -0
  230. package/vscode/src/vs/workbench/contrib/mcp/browser/mcpToolCallUI.js +200 -0
  231. package/vscode/src/vs/workbench/contrib/mcp/common/modelContextProtocolApps.d.ts +548 -0
  232. package/vscode/src/vs/workbench/contrib/mcp/common/modelContextProtocolApps.js +23 -0
  233. package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/executionStatusBarItemController.d.ts +22 -0
  234. package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/executionStatusBarItemController.js +338 -0
  235. package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/notebookVisibleCellObserver.d.ts +18 -0
  236. package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/notebookVisibleCellObserver.js +58 -0
  237. package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindWidget.d.ts +75 -0
  238. package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindWidget.js +364 -0
  239. package/vscode/src/vs/workbench/contrib/replNotebook/browser/interactiveEditor.css +21 -0
  240. package/vscode/src/vs/workbench/contrib/replNotebook/browser/media/interactive.css +36 -0
  241. package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditor.d.ts +110 -0
  242. package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditor.js +692 -0
  243. package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditorInput.d.ts +40 -0
  244. package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditorInput.js +158 -0
  245. package/vscode/src/vs/workbench/contrib/terminal/browser/chatTerminalCommandMirror.d.ts +80 -21
  246. package/vscode/src/vs/workbench/contrib/terminal/browser/chatTerminalCommandMirror.js +440 -82
  247. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatInputRelatedFilesContrib.d.ts +0 -34
  248. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatInputRelatedFilesContrib.js +0 -139
  249. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputCompletions.d.ts +0 -10
  250. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatInputCompletions.js +0 -1081
  251. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSession.d.ts +0 -199
  252. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSession.js +0 -482
  253. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionService.d.ts +0 -28
  254. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionService.js +0 -37
  255. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionServiceImpl.d.ts +0 -94
  256. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionServiceImpl.js +0 -495
  257. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatStrategies.d.ts +0 -72
  258. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatStrategies.js +0 -454
  259. package/vscode/src/vs/workbench/contrib/inlineChat/browser/utils.d.ts +0 -13
  260. package/vscode/src/vs/workbench/contrib/inlineChat/browser/utils.js +0 -66
  261. package/vscode/src/vs/workbench/contrib/mcp/browser/mcpPromptArgumentPick.d.ts +0 -41
  262. package/vscode/src/vs/workbench/contrib/mcp/browser/mcpPromptArgumentPick.js +0 -372
  263. package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/chat/notebookChatUtils.d.ts +0 -4
  264. package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/chat/notebookChatUtils.js +0 -58
  265. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/cellOperations.d.ts +0 -26
  266. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/cellOperations.js +0 -594
  267. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffCellEditorOptions.d.ts +0 -8
  268. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffCellEditorOptions.js +0 -55
  269. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffComponents.d.ts +0 -273
  270. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffComponents.js +0 -1746
  271. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementOutputs.d.ts +0 -50
  272. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementOutputs.js +0 -269
  273. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementViewModel.d.ts +0 -258
  274. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementViewModel.js +0 -806
  275. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffNestedCellViewModel.d.ts +0 -41
  276. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffNestedCellViewModel.js +0 -116
  277. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/editorHeightCalculator.d.ts +0 -17
  278. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/editorHeightCalculator.js +0 -62
  279. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/eventDispatcher.d.ts +0 -27
  280. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/eventDispatcher.js +0 -40
  281. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookCellDiffDecorator.d.ts +0 -23
  282. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookCellDiffDecorator.js +0 -295
  283. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookDeletedCellDecorator.d.ts +0 -51
  284. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookDeletedCellDecorator.js +0 -241
  285. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInlineDiff.d.ts +0 -24
  286. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInlineDiff.js +0 -146
  287. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInlineDiffWidget.d.ts +0 -28
  288. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInlineDiffWidget.js +0 -90
  289. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInsertedCellDecorator.d.ts +0 -10
  290. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookInsertedCellDecorator.js +0 -41
  291. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookOriginalCellModelFactory.d.ts +0 -21
  292. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookOriginalCellModelFactory.js +0 -42
  293. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookOriginalModelRefFactory.d.ts +0 -25
  294. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/inlineDiff/notebookOriginalModelRefFactory.js +0 -77
  295. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiff.css +0 -469
  296. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditor.d.ts +0 -149
  297. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditor.js +0 -823
  298. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditorBrowser.d.ts +0 -180
  299. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditorBrowser.js +0 -29
  300. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffList.d.ts +0 -102
  301. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffList.js +0 -567
  302. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffOverviewRuler.d.ts +0 -30
  303. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffOverviewRuler.js +0 -189
  304. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffViewModel.d.ts +0 -75
  305. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffViewModel.js +0 -439
  306. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookMultiDiffEditor.d.ts +0 -57
  307. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookMultiDiffEditor.js +0 -263
  308. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookMultiDiffEditorInput.d.ts +0 -22
  309. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookMultiDiffEditorInput.js +0 -48
  310. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/unchangedEditorRegions.d.ts +0 -13
  311. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/unchangedEditorRegions.js +0 -39
  312. package/vscode/src/vs/workbench/contrib/notebook/common/model/notebookMetadataTextModel.d.ts +0 -19
  313. package/vscode/src/vs/workbench/contrib/notebook/common/model/notebookMetadataTextModel.js +0 -89
  314. package/vscode/src/vs/workbench/contrib/notebook/common/notebookDiff.d.ts +0 -26
  315. package/vscode/src/vs/workbench/contrib/notebook/common/notebookDiff.js +0 -92
  316. package/vscode/src/vs/workbench/contrib/notebook/common/notebookDiffEditorInput.d.ts +0 -33
  317. package/vscode/src/vs/workbench/contrib/notebook/common/notebookDiffEditorInput.js +0 -108
@@ -30,6 +30,8 @@ import { isRequestVM, isResponseVM, isChatTreeItem } from '@codingame/monaco-vsc
30
30
  import { ChatAgentLocation, ChatConfiguration, ChatModeKind } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/constants';
31
31
  import { CHAT_CATEGORY } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/actions/chatActions';
32
32
  import { IChatWidgetService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chat.service';
33
+ import { isAgentSession } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsModel';
34
+ import { AgentSessionProviders } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessions';
33
35
 
34
36
  class EditingSessionAction extends Action2 {
35
37
  constructor(opts) {
@@ -59,15 +61,17 @@ function getEditingSessionContext(accessor, args) {
59
61
  return;
60
62
  }
61
63
  const editingSession = chatEditingService.getEditingSession(chatWidget.viewModel.model.sessionResource);
62
- return { editingSession, chatWidget };
64
+ return {
65
+ editingSession,
66
+ chatWidget
67
+ };
63
68
  }
64
69
  class WorkingSetAction extends EditingSessionAction {
65
70
  runEditingSessionAction(accessor, editingSession, chatWidget, ...args) {
66
71
  const uris = [];
67
72
  if (URI.isUri(args[0])) {
68
73
  uris.push(args[0]);
69
- }
70
- else if (chatWidget) {
74
+ } else if (chatWidget) {
71
75
  uris.push(...chatWidget.input.selectedElements);
72
76
  }
73
77
  if (!uris.length) {
@@ -79,15 +83,15 @@ class WorkingSetAction extends EditingSessionAction {
79
83
  registerAction2(class OpenFileInDiffAction extends WorkingSetAction {
80
84
  constructor() {
81
85
  super({
82
- id: 'chatEditing.openFileInDiff',
83
- title: ( localize2(5097, 'Open Changes in Diff Editor')),
86
+ id: "chatEditing.openFileInDiff",
87
+ title: ( localize2(5252, "Open Changes in Diff Editor")),
84
88
  icon: Codicon.diffSingle,
85
89
  menu: [{
86
- id: MenuId.ChatEditingWidgetModifiedFilesToolbar,
87
- when: ( ContextKeyExpr.equals(chatEditingWidgetFileStateContextKey.key, ModifiedFileEntryState.Modified)),
88
- order: 2,
89
- group: 'navigation'
90
- }],
90
+ id: MenuId.ChatEditingWidgetModifiedFilesToolbar,
91
+ when: ( ContextKeyExpr.equals(chatEditingWidgetFileStateContextKey.key, ModifiedFileEntryState.Modified)),
92
+ order: 2,
93
+ group: "navigation"
94
+ }]
91
95
  });
92
96
  }
93
97
  async runWorkingSetAction(accessor, currentEditingSession, _chatWidget, ...uris) {
@@ -95,7 +99,9 @@ registerAction2(class OpenFileInDiffAction extends WorkingSetAction {
95
99
  for (const uri of uris) {
96
100
  let pane = editorService.activeEditorPane;
97
101
  if (!pane) {
98
- pane = await editorService.openEditor({ resource: uri });
102
+ pane = await editorService.openEditor({
103
+ resource: uri
104
+ });
99
105
  }
100
106
  if (!pane) {
101
107
  return;
@@ -108,20 +114,23 @@ registerAction2(class OpenFileInDiffAction extends WorkingSetAction {
108
114
  registerAction2(class AcceptAction extends WorkingSetAction {
109
115
  constructor() {
110
116
  super({
111
- id: 'chatEditing.acceptFile',
112
- title: ( localize2(5098, 'Keep')),
117
+ id: "chatEditing.acceptFile",
118
+ title: ( localize2(5253, "Keep")),
113
119
  icon: Codicon.check,
114
120
  menu: [{
115
- when: ( ContextKeyExpr.and(( ContextKeyExpr.equals('resourceScheme', CHAT_EDITING_MULTI_DIFF_SOURCE_RESOLVER_SCHEME)), ContextKeyExpr.notIn(chatEditingResourceContextKey.key, decidedChatEditingResourceContextKey.key))),
116
- id: MenuId.MultiDiffEditorFileToolbar,
117
- order: 0,
118
- group: 'navigation',
119
- }, {
120
- id: MenuId.ChatEditingWidgetModifiedFilesToolbar,
121
- when: ( ContextKeyExpr.equals(chatEditingWidgetFileStateContextKey.key, ModifiedFileEntryState.Modified)),
122
- order: 0,
123
- group: 'navigation'
124
- }],
121
+ when: ( ContextKeyExpr.and(( ContextKeyExpr.equals("resourceScheme", CHAT_EDITING_MULTI_DIFF_SOURCE_RESOLVER_SCHEME)), ContextKeyExpr.notIn(
122
+ chatEditingResourceContextKey.key,
123
+ decidedChatEditingResourceContextKey.key
124
+ ))),
125
+ id: MenuId.MultiDiffEditorFileToolbar,
126
+ order: 0,
127
+ group: "navigation"
128
+ }, {
129
+ id: MenuId.ChatEditingWidgetModifiedFilesToolbar,
130
+ when: ( ContextKeyExpr.equals(chatEditingWidgetFileStateContextKey.key, ModifiedFileEntryState.Modified)),
131
+ order: 0,
132
+ group: "navigation"
133
+ }]
125
134
  });
126
135
  }
127
136
  async runWorkingSetAction(accessor, currentEditingSession, chatWidget, ...uris) {
@@ -131,20 +140,23 @@ registerAction2(class AcceptAction extends WorkingSetAction {
131
140
  registerAction2(class DiscardAction extends WorkingSetAction {
132
141
  constructor() {
133
142
  super({
134
- id: 'chatEditing.discardFile',
135
- title: ( localize2(5099, 'Undo')),
143
+ id: "chatEditing.discardFile",
144
+ title: ( localize2(5254, "Undo")),
136
145
  icon: Codicon.discard,
137
146
  menu: [{
138
- when: ( ContextKeyExpr.and(( ContextKeyExpr.equals('resourceScheme', CHAT_EDITING_MULTI_DIFF_SOURCE_RESOLVER_SCHEME)), ContextKeyExpr.notIn(chatEditingResourceContextKey.key, decidedChatEditingResourceContextKey.key))),
139
- id: MenuId.MultiDiffEditorFileToolbar,
140
- order: 2,
141
- group: 'navigation',
142
- }, {
143
- id: MenuId.ChatEditingWidgetModifiedFilesToolbar,
144
- when: ( ContextKeyExpr.equals(chatEditingWidgetFileStateContextKey.key, ModifiedFileEntryState.Modified)),
145
- order: 1,
146
- group: 'navigation'
147
- }],
147
+ when: ( ContextKeyExpr.and(( ContextKeyExpr.equals("resourceScheme", CHAT_EDITING_MULTI_DIFF_SOURCE_RESOLVER_SCHEME)), ContextKeyExpr.notIn(
148
+ chatEditingResourceContextKey.key,
149
+ decidedChatEditingResourceContextKey.key
150
+ ))),
151
+ id: MenuId.MultiDiffEditorFileToolbar,
152
+ order: 2,
153
+ group: "navigation"
154
+ }, {
155
+ id: MenuId.ChatEditingWidgetModifiedFilesToolbar,
156
+ when: ( ContextKeyExpr.equals(chatEditingWidgetFileStateContextKey.key, ModifiedFileEntryState.Modified)),
157
+ order: 1,
158
+ group: "navigation"
159
+ }]
148
160
  });
149
161
  }
150
162
  async runWorkingSetAction(accessor, currentEditingSession, chatWidget, ...uris) {
@@ -154,24 +166,22 @@ registerAction2(class DiscardAction extends WorkingSetAction {
154
166
  class ChatEditingAcceptAllAction extends EditingSessionAction {
155
167
  constructor() {
156
168
  super({
157
- id: 'chatEditing.acceptAllFiles',
158
- title: ( localize(5100, 'Keep')),
169
+ id: "chatEditing.acceptAllFiles",
170
+ title: ( localize(5255, "Keep")),
159
171
  icon: Codicon.check,
160
- tooltip: ( localize(5101, 'Keep All Edits')),
172
+ tooltip: ( localize(5256, "Keep All Edits")),
161
173
  precondition: hasUndecidedChatEditingResourceContextKey,
162
174
  keybinding: {
163
175
  primary: KeyMod.CtrlCmd | KeyCode.Enter,
164
176
  when: ( ContextKeyExpr.and(hasUndecidedChatEditingResourceContextKey, ChatContextKeys.inChatInput)),
165
- weight: KeybindingWeight.WorkbenchContrib,
177
+ weight: KeybindingWeight.WorkbenchContrib
166
178
  },
167
- menu: [
168
- {
169
- id: MenuId.ChatEditingWidgetToolbar,
170
- group: 'navigation',
171
- order: 0,
172
- when: ( ContextKeyExpr.and(( applyingChatEditsFailedContextKey.negate()), ( ContextKeyExpr.and(hasUndecidedChatEditingResourceContextKey))))
173
- }
174
- ]
179
+ menu: [{
180
+ id: MenuId.ChatEditingWidgetToolbar,
181
+ group: "navigation",
182
+ order: 0,
183
+ when: ( ContextKeyExpr.and(( applyingChatEditsFailedContextKey.negate()), ( ContextKeyExpr.and(hasUndecidedChatEditingResourceContextKey))))
184
+ }]
175
185
  });
176
186
  }
177
187
  async runEditingSessionAction(accessor, editingSession, chatWidget, ...args) {
@@ -182,19 +192,17 @@ registerAction2(ChatEditingAcceptAllAction);
182
192
  class ChatEditingDiscardAllAction extends EditingSessionAction {
183
193
  constructor() {
184
194
  super({
185
- id: 'chatEditing.discardAllFiles',
186
- title: ( localize(5102, 'Undo')),
195
+ id: "chatEditing.discardAllFiles",
196
+ title: ( localize(5257, "Undo")),
187
197
  icon: Codicon.discard,
188
- tooltip: ( localize(5103, 'Undo All Edits')),
198
+ tooltip: ( localize(5258, "Undo All Edits")),
189
199
  precondition: hasUndecidedChatEditingResourceContextKey,
190
- menu: [
191
- {
192
- id: MenuId.ChatEditingWidgetToolbar,
193
- group: 'navigation',
194
- order: 1,
195
- when: ( ContextKeyExpr.and(( applyingChatEditsFailedContextKey.negate()), hasUndecidedChatEditingResourceContextKey))
196
- }
197
- ],
200
+ menu: [{
201
+ id: MenuId.ChatEditingWidgetToolbar,
202
+ group: "navigation",
203
+ order: 1,
204
+ when: ( ContextKeyExpr.and(( applyingChatEditsFailedContextKey.negate()), hasUndecidedChatEditingResourceContextKey))
205
+ }],
198
206
  keybinding: {
199
207
  when: ( ContextKeyExpr.and(
200
208
  hasUndecidedChatEditingResourceContextKey,
@@ -202,8 +210,8 @@ class ChatEditingDiscardAllAction extends EditingSessionAction {
202
210
  ( ChatContextKeys.inputHasText.negate())
203
211
  )),
204
212
  weight: KeybindingWeight.WorkbenchContrib,
205
- primary: KeyMod.CtrlCmd | KeyCode.Backspace,
206
- },
213
+ primary: KeyMod.CtrlCmd | KeyCode.Backspace
214
+ }
207
215
  });
208
216
  }
209
217
  async runEditingSessionAction(accessor, editingSession, chatWidget, ...args) {
@@ -211,25 +219,50 @@ class ChatEditingDiscardAllAction extends EditingSessionAction {
211
219
  }
212
220
  }
213
221
  registerAction2(ChatEditingDiscardAllAction);
222
+ class ToggleExplanationWidgetAction extends EditingSessionAction {
223
+ static {
224
+ this.ID = "chatEditing.toggleExplanationWidget";
225
+ }
226
+ constructor() {
227
+ super({
228
+ id: ToggleExplanationWidgetAction.ID,
229
+ title: ( localize(5259, "Explain")),
230
+ tooltip: ( localize(5260, "Toggle Change Explanations")),
231
+ precondition: hasUndecidedChatEditingResourceContextKey,
232
+ menu: [{
233
+ id: MenuId.ChatEditingWidgetToolbar,
234
+ group: "navigation",
235
+ order: 2,
236
+ when: ( ContextKeyExpr.and(hasUndecidedChatEditingResourceContextKey, ( ContextKeyExpr.has(`config.${ChatConfiguration.ExplainChangesEnabled}`))))
237
+ }]
238
+ });
239
+ }
240
+ async runEditingSessionAction(accessor, editingSession, chatWidget, ...args) {
241
+ if (editingSession.hasExplanations()) {
242
+ editingSession.clearExplanations();
243
+ } else {
244
+ await editingSession.triggerExplanationGeneration();
245
+ }
246
+ }
247
+ }
248
+ registerAction2(ToggleExplanationWidgetAction);
214
249
  async function discardAllEditsWithConfirmation(accessor, currentEditingSession) {
215
250
  const dialogService = accessor.get(IDialogService);
216
251
  const entries = currentEditingSession.entries.get().filter(e => e.state.get() === ModifiedFileEntryState.Modified);
217
252
  if (entries.length > 0) {
218
253
  const confirmation = await dialogService.confirm({
219
- title: ( localize(5104, "Undo all edits?")),
220
- message: entries.length === 1
221
- ? ( localize(
222
- 5105,
254
+ title: ( localize(5261, "Undo all edits?")),
255
+ message: entries.length === 1 ? ( localize(
256
+ 5262,
223
257
  "This will undo changes made in {0}. Do you want to proceed?",
224
258
  basename(entries[0].modifiedURI)
225
- ))
226
- : ( localize(
227
- 5106,
259
+ )) : ( localize(
260
+ 5263,
228
261
  "This will undo changes made in {0} files. Do you want to proceed?",
229
262
  entries.length
230
263
  )),
231
- primaryButton: ( localize(5107, "Yes")),
232
- type: 'info'
264
+ primaryButton: ( localize(5264, "Yes")),
265
+ type: "info"
233
266
  });
234
267
  if (!confirmation.confirmed) {
235
268
  return false;
@@ -239,24 +272,29 @@ async function discardAllEditsWithConfirmation(accessor, currentEditingSession)
239
272
  return true;
240
273
  }
241
274
  class ChatEditingShowChangesAction extends EditingSessionAction {
242
- static { this.ID = 'chatEditing.viewChanges'; }
243
- static { this.LABEL = ( localize(5108, 'View All Edits')); }
275
+ static {
276
+ this.ID = "chatEditing.viewChanges";
277
+ }
278
+ static {
279
+ this.LABEL = ( localize(5265, "View All Edits"));
280
+ }
244
281
  constructor() {
245
282
  super({
246
283
  id: ChatEditingShowChangesAction.ID,
247
- title: { value: ChatEditingShowChangesAction.LABEL, original: ChatEditingShowChangesAction.LABEL },
284
+ title: {
285
+ value: ChatEditingShowChangesAction.LABEL,
286
+ original: ChatEditingShowChangesAction.LABEL
287
+ },
248
288
  tooltip: ChatEditingShowChangesAction.LABEL,
249
289
  f1: true,
250
290
  icon: Codicon.diffMultiple,
251
291
  precondition: hasUndecidedChatEditingResourceContextKey,
252
- menu: [
253
- {
254
- id: MenuId.ChatEditingWidgetToolbar,
255
- group: 'navigation',
256
- order: 4,
257
- when: ( ContextKeyExpr.and(( applyingChatEditsFailedContextKey.negate()), ( ContextKeyExpr.and(hasAppliedChatEditsContextKey, hasUndecidedChatEditingResourceContextKey))))
258
- }
259
- ],
292
+ menu: [{
293
+ id: MenuId.ChatEditingWidgetToolbar,
294
+ group: "navigation",
295
+ order: 4,
296
+ when: ( ContextKeyExpr.and(( applyingChatEditsFailedContextKey.negate()), ( ContextKeyExpr.and(hasAppliedChatEditsContextKey, hasUndecidedChatEditingResourceContextKey))))
297
+ }]
260
298
  });
261
299
  }
262
300
  async runEditingSessionAction(accessor, editingSession, chatWidget, ...args) {
@@ -265,45 +303,63 @@ class ChatEditingShowChangesAction extends EditingSessionAction {
265
303
  }
266
304
  registerAction2(ChatEditingShowChangesAction);
267
305
  class ViewAllSessionChangesAction extends Action2 {
268
- static { this.ID = 'chatEditing.viewAllSessionChanges'; }
306
+ static {
307
+ this.ID = "chatEditing.viewAllSessionChanges";
308
+ }
269
309
  constructor() {
270
310
  super({
271
311
  id: ViewAllSessionChangesAction.ID,
272
- title: ( localize2(5109, 'View All Changes')),
312
+ title: ( localize2(5266, "View All Changes")),
273
313
  icon: Codicon.diffMultiple,
274
314
  category: CHAT_CATEGORY,
275
315
  precondition: ChatContextKeys.hasAgentSessionChanges,
276
- menu: [
277
- {
278
- id: MenuId.ChatEditingSessionChangesToolbar,
279
- group: 'navigation',
280
- order: 10,
281
- when: ChatContextKeys.hasAgentSessionChanges
282
- }
283
- ],
316
+ menu: [{
317
+ id: MenuId.ChatEditingSessionChangesToolbar,
318
+ group: "navigation",
319
+ order: 10,
320
+ when: ChatContextKeys.hasAgentSessionChanges
321
+ }, {
322
+ id: MenuId.AgentSessionItemToolbar,
323
+ group: "navigation",
324
+ order: 0,
325
+ when: ChatContextKeys.hasAgentSessionChanges
326
+ }]
284
327
  });
285
328
  }
286
- async run(accessor, sessionResource) {
329
+ async run(accessor, sessionOrSessionResource) {
287
330
  const agentSessionsService = accessor.get(IAgentSessionsService);
288
331
  const commandService = accessor.get(ICommandService);
289
- if (!URI.isUri(sessionResource)) {
332
+ const chatEditingService = accessor.get(IChatEditingService);
333
+ if (!URI.isUri(sessionOrSessionResource) && !isAgentSession(sessionOrSessionResource)) {
290
334
  return;
291
335
  }
336
+ const sessionResource = URI.isUri(sessionOrSessionResource) ? sessionOrSessionResource : sessionOrSessionResource.resource;
292
337
  const session = agentSessionsService.getSession(sessionResource);
293
338
  const changes = session?.changes;
294
- if (!(changes instanceof Array)) {
339
+ if (!session || !changes) {
295
340
  return;
296
341
  }
297
- const resources = ( changes
298
- .filter(d => d.originalUri)
299
- .map(d => ({ originalUri: d.originalUri, modifiedUri: d.modifiedUri })));
300
- if (resources.length > 0) {
301
- await commandService.executeCommand('_workbench.openMultiDiffEditor', {
302
- multiDiffSourceUri: sessionResource.with({ scheme: sessionResource.scheme + '-worktree-changes' }),
303
- title: ( localize(5110, 'All Session Changes')),
304
- resources,
342
+ if (session.providerType === AgentSessionProviders.Background || session.providerType === AgentSessionProviders.Cloud) {
343
+ if (!Array.isArray(changes) || changes.length === 0) {
344
+ return;
345
+ }
346
+ const resources = ( changes.map(d => ({
347
+ originalUri: d.originalUri,
348
+ modifiedUri: d.modifiedUri
349
+ })));
350
+ await commandService.executeCommand("_workbench.openMultiDiffEditor", {
351
+ multiDiffSourceUri: sessionResource.with({
352
+ scheme: sessionResource.scheme + "-worktree-changes"
353
+ }),
354
+ title: ( localize(5267, "All Session Changes")),
355
+ resources
305
356
  });
357
+ session?.setRead(true);
358
+ return;
306
359
  }
360
+ const editingSession = chatEditingService.getEditingSession(sessionResource);
361
+ await editingSession?.show();
362
+ session?.setRead(true);
307
363
  }
308
364
  }
309
365
  registerAction2(ViewAllSessionChangesAction);
@@ -321,66 +377,63 @@ async function restoreSnapshotWithConfirmation(accessor, item) {
321
377
  if (!session) {
322
378
  return;
323
379
  }
324
- const requestId = isRequestVM(item) ? item.id :
325
- isResponseVM(item) ? item.requestId : undefined;
380
+ const requestId = isRequestVM(item) ? item.id : isResponseVM(item) ? item.requestId : undefined;
326
381
  if (requestId) {
327
382
  const chatRequests = chatModel.getRequests();
328
383
  const itemIndex = chatRequests.findIndex(request => request.id === requestId);
329
384
  const editsToUndo = chatRequests.length - itemIndex;
330
385
  const requestsToRemove = chatRequests.slice(itemIndex);
331
386
  const requestIdsToRemove = ( new Set(( requestsToRemove.map(request => request.id))));
332
- const entriesModifiedInRequestsToRemove = session.entries.get().filter((entry) => ( requestIdsToRemove.has(entry.lastModifyingRequestId))) ?? [];
333
- const shouldPrompt = entriesModifiedInRequestsToRemove.length > 0 && configurationService.getValue('chat.editing.confirmEditRequestRemoval') === true;
387
+ const entriesModifiedInRequestsToRemove = session.entries.get().filter(entry => ( requestIdsToRemove.has(entry.lastModifyingRequestId))) ?? [];
388
+ const shouldPrompt = entriesModifiedInRequestsToRemove.length > 0 && configurationService.getValue("chat.editing.confirmEditRequestRemoval") === true;
334
389
  let message;
335
390
  if (editsToUndo === 1) {
336
391
  if (entriesModifiedInRequestsToRemove.length === 1) {
337
392
  message = ( localize(
338
- 5111,
393
+ 5268,
339
394
  "This will remove your last request and undo the edits made to {0}. Do you want to proceed?",
340
395
  basename(entriesModifiedInRequestsToRemove[0].modifiedURI)
341
396
  ));
342
- }
343
- else {
397
+ } else {
344
398
  message = ( localize(
345
- 5112,
399
+ 5269,
346
400
  "This will remove your last request and undo edits made to {0} files in your working set. Do you want to proceed?",
347
401
  entriesModifiedInRequestsToRemove.length
348
402
  ));
349
403
  }
350
- }
351
- else {
404
+ } else {
352
405
  if (entriesModifiedInRequestsToRemove.length === 1) {
353
406
  message = ( localize(
354
- 5113,
407
+ 5270,
355
408
  "This will remove all subsequent requests and undo edits made to {0}. Do you want to proceed?",
356
409
  basename(entriesModifiedInRequestsToRemove[0].modifiedURI)
357
410
  ));
358
- }
359
- else {
411
+ } else {
360
412
  message = ( localize(
361
- 5114,
413
+ 5271,
362
414
  "This will remove all subsequent requests and undo edits made to {0} files in your working set. Do you want to proceed?",
363
415
  entriesModifiedInRequestsToRemove.length
364
416
  ));
365
417
  }
366
418
  }
367
- const confirmation = shouldPrompt
368
- ? await dialogService.confirm({
369
- title: editsToUndo === 1
370
- ? ( localize(5115, "Do you want to undo your last edit?"))
371
- : ( localize(5116, "Do you want to undo {0} edits?", editsToUndo)),
372
- message: message,
373
- primaryButton: ( localize(5117, "Yes")),
374
- checkbox: { label: ( localize(5118, "Don't ask again")), checked: false },
375
- type: 'info'
376
- })
377
- : { confirmed: true };
419
+ const confirmation = shouldPrompt ? await dialogService.confirm({
420
+ title: editsToUndo === 1 ? ( localize(5272, "Do you want to undo your last edit?")) : ( localize(5273, "Do you want to undo {0} edits?", editsToUndo)),
421
+ message: message,
422
+ primaryButton: ( localize(5274, "Yes")),
423
+ checkbox: {
424
+ label: ( localize(5275, "Don't ask again")),
425
+ checked: false
426
+ },
427
+ type: "info"
428
+ }) : {
429
+ confirmed: true
430
+ };
378
431
  if (!confirmation.confirmed) {
379
432
  widget?.viewModel?.model.setCheckpoint(undefined);
380
433
  return;
381
434
  }
382
435
  if (confirmation.checkboxChecked) {
383
- await configurationService.updateValue('chat.editing.confirmEditRequestRemoval', false);
436
+ await configurationService.updateValue("chat.editing.confirmEditRequestRemoval", false);
384
437
  }
385
438
  const snapshotRequestId = chatRequests[itemIndex].id;
386
439
  await session.restoreSnapshot(snapshotRequestId, undefined);
@@ -389,27 +442,25 @@ async function restoreSnapshotWithConfirmation(accessor, item) {
389
442
  registerAction2(class RemoveAction extends Action2 {
390
443
  constructor() {
391
444
  super({
392
- id: 'workbench.action.chat.undoEdits',
393
- title: ( localize2(5119, "Undo Requests")),
445
+ id: "workbench.action.chat.undoEdits",
446
+ title: ( localize2(5276, "Undo Requests")),
394
447
  f1: false,
395
448
  category: CHAT_CATEGORY,
396
449
  icon: Codicon.discard,
397
450
  keybinding: {
398
451
  primary: KeyCode.Delete,
399
452
  mac: {
400
- primary: KeyMod.CtrlCmd | KeyCode.Backspace,
453
+ primary: KeyMod.CtrlCmd | KeyCode.Backspace
401
454
  },
402
455
  when: ( ContextKeyExpr.and(ChatContextKeys.inChatSession, ( EditorContextKeys.textInputFocus.negate()))),
403
- weight: KeybindingWeight.WorkbenchContrib,
456
+ weight: KeybindingWeight.WorkbenchContrib
404
457
  },
405
- menu: [
406
- {
407
- id: MenuId.ChatMessageTitle,
408
- group: 'navigation',
409
- order: 2,
410
- when: ( ContextKeyExpr.and(( ( ContextKeyExpr.equals(`config.${ChatConfiguration.EditRequests}`, 'input')).negate()), ( ContextKeyExpr.equals(`config.${ChatConfiguration.CheckpointsEnabled}`, false)), ( ChatContextKeys.lockedToCodingAgent.negate()))),
411
- }
412
- ]
458
+ menu: [{
459
+ id: MenuId.ChatMessageTitle,
460
+ group: "navigation",
461
+ order: 2,
462
+ when: ( ContextKeyExpr.and(( ( ContextKeyExpr.equals(`config.${ChatConfiguration.EditRequests}`, "input")).negate()), ( ContextKeyExpr.equals(`config.${ChatConfiguration.CheckpointsEnabled}`, false)), ( ChatContextKeys.lockedToCodingAgent.negate())))
463
+ }]
413
464
  });
414
465
  }
415
466
  async run(accessor, ...args) {
@@ -424,7 +475,7 @@ registerAction2(class RemoveAction extends Action2 {
424
475
  return;
425
476
  }
426
477
  await restoreSnapshotWithConfirmation(accessor, item);
427
- if (isRequestVM(item) && configurationService.getValue('chat.undoRequests.restoreInput')) {
478
+ if (isRequestVM(item) && configurationService.getValue("chat.undoRequests.restoreInput")) {
428
479
  widget?.focusInput();
429
480
  widget?.input.setValue(item.messageText, false);
430
481
  }
@@ -433,27 +484,25 @@ registerAction2(class RemoveAction extends Action2 {
433
484
  registerAction2(class RestoreCheckpointAction extends Action2 {
434
485
  constructor() {
435
486
  super({
436
- id: 'workbench.action.chat.restoreCheckpoint',
437
- title: ( localize2(5120, "Restore Checkpoint")),
438
- tooltip: ( localize2(5121, "Restores workspace and chat to this point")),
487
+ id: "workbench.action.chat.restoreCheckpoint",
488
+ title: ( localize2(5277, "Restore Checkpoint")),
489
+ tooltip: ( localize2(5278, "Restores workspace and chat to this point")),
439
490
  f1: false,
440
491
  category: CHAT_CATEGORY,
441
492
  keybinding: {
442
493
  primary: KeyCode.Delete,
443
494
  mac: {
444
- primary: KeyMod.CtrlCmd | KeyCode.Backspace,
495
+ primary: KeyMod.CtrlCmd | KeyCode.Backspace
445
496
  },
446
497
  when: ( ContextKeyExpr.and(ChatContextKeys.inChatSession, ( EditorContextKeys.textInputFocus.negate()))),
447
- weight: KeybindingWeight.WorkbenchContrib,
498
+ weight: KeybindingWeight.WorkbenchContrib
448
499
  },
449
- menu: [
450
- {
451
- id: MenuId.ChatMessageCheckpoint,
452
- group: 'navigation',
453
- order: 2,
454
- when: ( ContextKeyExpr.and(ChatContextKeys.isRequest, ( ChatContextKeys.lockedToCodingAgent.negate())))
455
- }
456
- ]
500
+ menu: [{
501
+ id: MenuId.ChatMessageCheckpoint,
502
+ group: "navigation",
503
+ order: 2,
504
+ when: ( ContextKeyExpr.and(ChatContextKeys.isRequest, ( ChatContextKeys.lockedToCodingAgent.negate())))
505
+ }]
457
506
  });
458
507
  }
459
508
  async run(accessor, ...args) {
@@ -477,23 +526,21 @@ registerAction2(class RestoreCheckpointAction extends Action2 {
477
526
  registerAction2(class RestoreLastCheckpoint extends Action2 {
478
527
  constructor() {
479
528
  super({
480
- id: 'workbench.action.chat.restoreLastCheckpoint',
481
- title: ( localize2(5122, "Restore to Last Checkpoint")),
529
+ id: "workbench.action.chat.restoreLastCheckpoint",
530
+ title: ( localize2(5279, "Restore to Last Checkpoint")),
482
531
  f1: false,
483
532
  category: CHAT_CATEGORY,
484
533
  icon: Codicon.discard,
485
- menu: [
486
- {
487
- id: MenuId.ChatMessageFooter,
488
- group: 'navigation',
489
- order: 1,
490
- when: ( ContextKeyExpr.and(
491
- ContextKeyExpr.in(ChatContextKeys.itemId.key, ChatContextKeys.lastItemId.key),
492
- ( ContextKeyExpr.equals(`config.${ChatConfiguration.CheckpointsEnabled}`, true)),
493
- ( ChatContextKeys.lockedToCodingAgent.negate())
494
- )),
495
- }
496
- ]
534
+ menu: [{
535
+ id: MenuId.ChatMessageFooter,
536
+ group: "navigation",
537
+ order: 1,
538
+ when: ( ContextKeyExpr.and(
539
+ ContextKeyExpr.in(ChatContextKeys.itemId.key, ChatContextKeys.lastItemId.key),
540
+ ( ContextKeyExpr.equals(`config.${ChatConfiguration.CheckpointsEnabled}`, true)),
541
+ ( ChatContextKeys.lockedToCodingAgent.negate())
542
+ ))
543
+ }]
497
544
  });
498
545
  }
499
546
  async run(accessor, ...args) {
@@ -529,24 +576,22 @@ registerAction2(class RestoreLastCheckpoint extends Action2 {
529
576
  registerAction2(class EditAction extends Action2 {
530
577
  constructor() {
531
578
  super({
532
- id: 'workbench.action.chat.editRequests',
533
- title: ( localize2(5123, "Edit Request")),
579
+ id: "workbench.action.chat.editRequests",
580
+ title: ( localize2(5280, "Edit Request")),
534
581
  f1: false,
535
582
  category: CHAT_CATEGORY,
536
583
  icon: Codicon.edit,
537
584
  keybinding: {
538
585
  primary: KeyCode.Enter,
539
586
  when: ( ContextKeyExpr.and(ChatContextKeys.inChatSession, ( EditorContextKeys.textInputFocus.negate()))),
540
- weight: KeybindingWeight.WorkbenchContrib,
587
+ weight: KeybindingWeight.WorkbenchContrib
541
588
  },
542
- menu: [
543
- {
544
- id: MenuId.ChatMessageTitle,
545
- group: 'navigation',
546
- order: 2,
547
- when: ( ContextKeyExpr.and(( ContextKeyExpr.or(( ContextKeyExpr.equals(`config.${ChatConfiguration.EditRequests}`, 'hover')), ( ContextKeyExpr.equals(`config.${ChatConfiguration.EditRequests}`, 'input'))))))
548
- }
549
- ]
589
+ menu: [{
590
+ id: MenuId.ChatMessageTitle,
591
+ group: "navigation",
592
+ order: 2,
593
+ when: ( ContextKeyExpr.and(( ContextKeyExpr.or(( ContextKeyExpr.equals(`config.${ChatConfiguration.EditRequests}`, "hover")), ( ContextKeyExpr.equals(`config.${ChatConfiguration.EditRequests}`, "input"))))))
594
+ }]
550
595
  });
551
596
  }
552
597
  async run(accessor, ...args) {
@@ -565,16 +610,18 @@ registerAction2(class EditAction extends Action2 {
565
610
  }
566
611
  });
567
612
  registerAction2(class OpenWorkingSetHistoryAction extends Action2 {
568
- static { this.id = 'chat.openFileUpdatedBySnapshot'; }
613
+ static {
614
+ this.id = "chat.openFileUpdatedBySnapshot";
615
+ }
569
616
  constructor() {
570
617
  super({
571
618
  id: OpenWorkingSetHistoryAction.id,
572
- title: ( localize(5124, "Open File")),
619
+ title: ( localize(5281, "Open File")),
573
620
  menu: [{
574
- id: MenuId.ChatEditingCodeBlockContext,
575
- group: 'navigation',
576
- order: 0,
577
- },]
621
+ id: MenuId.ChatEditingCodeBlockContext,
622
+ group: "navigation",
623
+ order: 0
624
+ }]
578
625
  });
579
626
  }
580
627
  async run(accessor, ...args) {
@@ -583,20 +630,24 @@ registerAction2(class OpenWorkingSetHistoryAction extends Action2 {
583
630
  return;
584
631
  }
585
632
  const editorService = accessor.get(IEditorService);
586
- await editorService.openEditor({ resource: context.uri });
633
+ await editorService.openEditor({
634
+ resource: context.uri
635
+ });
587
636
  }
588
637
  });
589
638
  registerAction2(class OpenWorkingSetHistoryAction extends Action2 {
590
- static { this.id = 'chat.openFileSnapshot'; }
639
+ static {
640
+ this.id = "chat.openFileSnapshot";
641
+ }
591
642
  constructor() {
592
643
  super({
593
644
  id: OpenWorkingSetHistoryAction.id,
594
- title: ( localize(5125, "Open File Snapshot")),
645
+ title: ( localize(5282, "Open File Snapshot")),
595
646
  menu: [{
596
- id: MenuId.ChatEditingCodeBlockContext,
597
- group: 'navigation',
598
- order: 1,
599
- },]
647
+ id: MenuId.ChatEditingCodeBlockContext,
648
+ group: "navigation",
649
+ order: 1
650
+ }]
600
651
  });
601
652
  }
602
653
  async run(accessor, ...args) {
@@ -613,9 +664,17 @@ registerAction2(class OpenWorkingSetHistoryAction extends Action2 {
613
664
  }
614
665
  const snapshot = chatEditingService.getEditingSession(chatModel.sessionResource)?.getSnapshotUri(context.requestId, context.uri, context.stopId);
615
666
  if (snapshot) {
616
- const editor = await editorService.openEditor({ resource: snapshot, label: ( localize(5126, '{0} (Snapshot)', basename(context.uri))), options: { activation: EditorActivation.ACTIVATE } });
667
+ const editor = await editorService.openEditor({
668
+ resource: snapshot,
669
+ label: ( localize(5283, "{0} (Snapshot)", basename(context.uri))),
670
+ options: {
671
+ activation: EditorActivation.ACTIVATE
672
+ }
673
+ });
617
674
  if (isCodeEditor(editor)) {
618
- editor.updateOptions({ readOnly: true });
675
+ editor.updateOptions({
676
+ readOnly: true
677
+ });
619
678
  }
620
679
  }
621
680
  }
@@ -623,13 +682,13 @@ registerAction2(class OpenWorkingSetHistoryAction extends Action2 {
623
682
  registerAction2(class ResolveSymbolsContextAction extends EditingSessionAction {
624
683
  constructor() {
625
684
  super({
626
- id: 'workbench.action.edits.addFilesFromReferences',
627
- title: ( localize2(5127, "Add Files From References")),
685
+ id: "workbench.action.edits.addFilesFromReferences",
686
+ title: ( localize2(5284, "Add Files From References")),
628
687
  f1: false,
629
688
  category: CHAT_CATEGORY,
630
689
  menu: {
631
690
  id: MenuId.ChatInputSymbolAttachmentContext,
632
- group: 'navigation',
691
+ group: "navigation",
633
692
  order: 1,
634
693
  when: ( ContextKeyExpr.and(( ChatContextKeys.chatModeKind.isEqualTo(ChatModeKind.Ask)), EditorContextKeys.hasReferenceProvider))
635
694
  }
@@ -661,45 +720,52 @@ registerAction2(class ResolveSymbolsContextAction extends EditingSessionAction {
661
720
  }
662
721
  async getReferences(position, textModel, languageFeaturesService) {
663
722
  const referenceProviders = languageFeaturesService.referenceProvider.all(textModel);
664
- const references = await Promise.all(( referenceProviders.map(async (referenceProvider) => {
665
- return (await referenceProvider.provideReferences(textModel, position, { includeDeclaration: true }, CancellationToken.None)) ?? [];
723
+ const references = await Promise.all(( referenceProviders.map(async referenceProvider => {
724
+ return (await referenceProvider.provideReferences(textModel, position, {
725
+ includeDeclaration: true
726
+ }, CancellationToken.None)) ?? [];
666
727
  })));
667
728
  return references.flat();
668
729
  }
669
730
  async getDefinitions(position, textModel, languageFeaturesService) {
670
731
  const definitionProviders = languageFeaturesService.definitionProvider.all(textModel);
671
- const definitions = await Promise.all(( definitionProviders.map(async (definitionProvider) => {
732
+ const definitions = await Promise.all(( definitionProviders.map(async definitionProvider => {
672
733
  return (await definitionProvider.provideDefinition(textModel, position, CancellationToken.None)) ?? [];
673
734
  })));
674
735
  return definitions.flat();
675
736
  }
676
737
  async getImplementations(position, textModel, languageFeaturesService) {
677
738
  const implementationProviders = languageFeaturesService.implementationProvider.all(textModel);
678
- const implementations = await Promise.all(( implementationProviders.map(async (implementationProvider) => {
739
+ const implementations = await Promise.all(( implementationProviders.map(async implementationProvider => {
679
740
  return (await implementationProvider.provideImplementation(textModel, position, CancellationToken.None)) ?? [];
680
741
  })));
681
742
  return implementations.flat();
682
743
  }
683
744
  });
684
745
  class ViewPreviousEditsAction extends EditingSessionAction {
685
- static { this.Id = 'chatEditing.viewPreviousEdits'; }
686
- static { this.Label = ( localize(5128, 'View Previous Edits')); }
746
+ static {
747
+ this.Id = "chatEditing.viewPreviousEdits";
748
+ }
749
+ static {
750
+ this.Label = ( localize(5285, "View Previous Edits"));
751
+ }
687
752
  constructor() {
688
753
  super({
689
754
  id: ViewPreviousEditsAction.Id,
690
- title: { value: ViewPreviousEditsAction.Label, original: ViewPreviousEditsAction.Label },
755
+ title: {
756
+ value: ViewPreviousEditsAction.Label,
757
+ original: ViewPreviousEditsAction.Label
758
+ },
691
759
  tooltip: ViewPreviousEditsAction.Label,
692
760
  f1: true,
693
761
  icon: Codicon.diffMultiple,
694
762
  precondition: ( ContextKeyExpr.and(ChatContextKeys.enabled, ( hasUndecidedChatEditingResourceContextKey.negate()))),
695
- menu: [
696
- {
697
- id: MenuId.ChatEditingWidgetToolbar,
698
- group: 'navigation',
699
- order: 4,
700
- when: ( ContextKeyExpr.and(( applyingChatEditsFailedContextKey.negate()), ( ContextKeyExpr.and(hasAppliedChatEditsContextKey, ( hasUndecidedChatEditingResourceContextKey.negate())))))
701
- }
702
- ],
763
+ menu: [{
764
+ id: MenuId.ChatEditingWidgetToolbar,
765
+ group: "navigation",
766
+ order: 4,
767
+ when: ( ContextKeyExpr.and(( applyingChatEditsFailedContextKey.negate()), ( ContextKeyExpr.and(hasAppliedChatEditsContextKey, ( hasUndecidedChatEditingResourceContextKey.negate())))))
768
+ }]
703
769
  });
704
770
  }
705
771
  async runEditingSessionAction(accessor, editingSession, chatWidget, ...args) {
@@ -707,7 +773,7 @@ class ViewPreviousEditsAction extends EditingSessionAction {
707
773
  }
708
774
  }
709
775
  registerAction2(ViewPreviousEditsAction);
710
- CommandsRegistry.registerCommand('_chat.editSessions.accept', async (accessor, resources) => {
776
+ CommandsRegistry.registerCommand("_chat.editSessions.accept", async (accessor, resources) => {
711
777
  if (resources.length === 0) {
712
778
  return;
713
779
  }
@@ -718,4 +784,4 @@ CommandsRegistry.registerCommand('_chat.editSessions.accept', async (accessor, r
718
784
  }
719
785
  });
720
786
 
721
- export { ChatEditingAcceptAllAction, ChatEditingDiscardAllAction, ChatEditingShowChangesAction, EditingSessionAction, ViewAllSessionChangesAction, ViewPreviousEditsAction, discardAllEditsWithConfirmation, getEditingSessionContext };
787
+ export { ChatEditingAcceptAllAction, ChatEditingDiscardAllAction, ChatEditingShowChangesAction, EditingSessionAction, ToggleExplanationWidgetAction, ViewAllSessionChangesAction, ViewPreviousEditsAction, discardAllEditsWithConfirmation, getEditingSessionContext };