@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
@@ -1,11 +1,14 @@
1
1
 
2
2
  import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
3
3
  import { $, h } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/dom';
4
+ import { disposableTimeout } from '@codingame/monaco-vscode-api/vscode/vs/base/common/async';
5
+ import { decodeBase64 } from '@codingame/monaco-vscode-api/vscode/vs/base/common/buffer';
4
6
  import { Codicon } from '@codingame/monaco-vscode-api/vscode/vs/base/common/codicons';
5
- import { Emitter } from '@codingame/monaco-vscode-api/vscode/vs/base/common/event';
6
7
  import { Disposable } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
7
8
  import { basename, joinPath } from '@codingame/monaco-vscode-api/vscode/vs/base/common/resources';
8
9
  import { generateUuid } from '@codingame/monaco-vscode-api/vscode/vs/base/common/uuid';
10
+ import { ILanguageService } from '@codingame/monaco-vscode-api/vscode/vs/editor/common/languages/language.service';
11
+ import { IModelService } from '@codingame/monaco-vscode-api/vscode/vs/editor/common/services/model.service';
9
12
  import { localize2, localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
10
13
  import { MenuWorkbenchToolBar } from '@codingame/monaco-vscode-api/vscode/vs/platform/actions/browser/toolbar';
11
14
  import { MenuId, Action2, registerAction2 } from '@codingame/monaco-vscode-api/vscode/vs/platform/actions/common/actions';
@@ -26,8 +29,22 @@ import { MarkdownString } from '@codingame/monaco-vscode-api/vscode/vs/base/comm
26
29
  import { IMarkdownRendererService } from '@codingame/monaco-vscode-api/vscode/vs/platform/markdown/browser/markdownRenderer.service';
27
30
  import { ChatAttachmentsContentPart } from './chatAttachmentsContentPart.js';
28
31
 
32
+ var ChatToolOutputContentSubPart_1;
29
33
  let ChatToolOutputContentSubPart = class ChatToolOutputContentSubPart extends Disposable {
30
- constructor(context, parts, _instantiationService, contextKeyService, _contextMenuService, _fileService, _markdownRendererService) {
34
+ static {
35
+ ChatToolOutputContentSubPart_1 = this;
36
+ }
37
+ constructor(
38
+ context,
39
+ parts,
40
+ _instantiationService,
41
+ contextKeyService,
42
+ _contextMenuService,
43
+ _fileService,
44
+ _markdownRendererService,
45
+ modelService,
46
+ languageService
47
+ ) {
31
48
  super();
32
49
  this.context = context;
33
50
  this.parts = parts;
@@ -36,32 +53,36 @@ let ChatToolOutputContentSubPart = class ChatToolOutputContentSubPart extends Di
36
53
  this._contextMenuService = _contextMenuService;
37
54
  this._fileService = _fileService;
38
55
  this._markdownRendererService = _markdownRendererService;
39
- this._onDidChangeHeight = this._register(( new Emitter()));
40
- this.onDidChangeHeight = this._onDidChangeHeight.event;
41
- this._currentWidth = 0;
56
+ this.modelService = modelService;
57
+ this.languageService = languageService;
42
58
  this._editorReferences = [];
43
59
  this.codeblocks = [];
44
60
  this.domNode = this.createOutputContents();
45
- this._currentWidth = context.currentWidth();
46
61
  }
47
62
  toMdString(value) {
48
- if (typeof value === 'string') {
49
- return ( new MarkdownString('')).appendText(value);
63
+ if (typeof value === "string") {
64
+ return ( new MarkdownString("")).appendText(value);
50
65
  }
51
- return ( new MarkdownString(value.value, { isTrusted: value.isTrusted }));
66
+ return ( new MarkdownString(value.value, {
67
+ isTrusted: value.isTrusted
68
+ }));
52
69
  }
53
70
  createOutputContents() {
54
- const container = $('div');
71
+ const container = $("div");
55
72
  for (let i = 0; i < this.parts.length; i++) {
56
73
  const part = this.parts[i];
57
- if (part.kind === 'code') {
58
- this.addCodeBlock(part, container);
74
+ if (part.kind === "code") {
75
+ const codeParts = [part];
76
+ while (i + 1 < this.parts.length && this.parts[i + 1].kind === "code") {
77
+ codeParts.push(this.parts[++i]);
78
+ }
79
+ this.addCodeBlock(codeParts, container);
59
80
  continue;
60
81
  }
61
82
  const group = [];
62
83
  for (let k = i; k < this.parts.length; k++) {
63
84
  const part = this.parts[k];
64
- if (part.kind !== 'data') {
85
+ if (part.kind !== "data") {
65
86
  break;
66
87
  }
67
88
  group.push(part);
@@ -72,24 +93,86 @@ let ChatToolOutputContentSubPart = class ChatToolOutputContentSubPart extends Di
72
93
  return container;
73
94
  }
74
95
  addResourceGroup(parts, container) {
75
- const el = h('.chat-collapsible-io-resource-group', [
76
- h('.chat-collapsible-io-resource-items@items'),
77
- h('.chat-collapsible-io-resource-actions@actions'),
96
+ const el = h(".chat-collapsible-io-resource-group", [
97
+ h(".chat-collapsible-io-resource-items@items"),
98
+ h(".chat-collapsible-io-resource-actions@actions")
78
99
  ]);
79
- this.fillInResourceGroup(parts, el.items, el.actions).then(() => this._onDidChangeHeight.fire());
100
+ this.fillInResourceGroup(parts, el.items, el.actions);
80
101
  container.appendChild(el.root);
81
102
  return el.root;
82
103
  }
104
+ static {
105
+ this.IMAGE_DECODE_DELAY_MS = 100;
106
+ }
83
107
  async fillInResourceGroup(parts, itemsContainer, actionsContainer) {
84
- const entries = await Promise.all(( parts.map(async (part) => {
108
+ const entries = [];
109
+ const deferredImageParts = [];
110
+ for (let i = 0; i < parts.length; i++) {
111
+ const part = parts[i];
85
112
  if (part.mimeType && getAttachableImageExtension(part.mimeType)) {
86
- const value = part.value ?? (await this._fileService.readFile(part.uri).then(f => f.value.buffer, () => undefined));
87
- return { kind: 'image', id: generateUuid(), name: basename(part.uri), value, mimeType: part.mimeType, isURL: false, references: [{ kind: 'reference', reference: part.uri }] };
88
- }
89
- else {
90
- return { kind: 'file', id: generateUuid(), name: basename(part.uri), fullName: part.uri.path, value: part.uri };
113
+ if (part.base64Value) {
114
+ entries.push({
115
+ kind: "file",
116
+ id: generateUuid(),
117
+ name: basename(part.uri),
118
+ fullName: part.uri.path,
119
+ value: part.uri
120
+ });
121
+ deferredImageParts.push({
122
+ index: i,
123
+ part
124
+ });
125
+ } else if (part.value) {
126
+ entries.push({
127
+ kind: "image",
128
+ id: generateUuid(),
129
+ name: basename(part.uri),
130
+ value: part.value,
131
+ mimeType: part.mimeType,
132
+ isURL: false,
133
+ references: [{
134
+ kind: "reference",
135
+ reference: part.uri
136
+ }]
137
+ });
138
+ } else {
139
+ const value = await this._fileService.readFile(part.uri).then(f => f.value.buffer, () => undefined);
140
+ if (!value) {
141
+ entries.push({
142
+ kind: "file",
143
+ id: generateUuid(),
144
+ name: basename(part.uri),
145
+ fullName: part.uri.path,
146
+ value: part.uri
147
+ });
148
+ } else {
149
+ entries.push({
150
+ kind: "image",
151
+ id: generateUuid(),
152
+ name: basename(part.uri),
153
+ value,
154
+ mimeType: part.mimeType,
155
+ isURL: false,
156
+ references: [{
157
+ kind: "reference",
158
+ reference: part.uri
159
+ }]
160
+ });
161
+ }
162
+ }
163
+ } else {
164
+ entries.push({
165
+ kind: "file",
166
+ id: generateUuid(),
167
+ name: basename(part.uri),
168
+ fullName: part.uri.path,
169
+ value: part.uri
170
+ });
91
171
  }
92
- })));
172
+ }
173
+ if (this._store.isDisposed) {
174
+ return;
175
+ }
93
176
  const attachments = this._register(this._instantiationService.createInstance(ChatAttachmentsContentPart, {
94
177
  variables: entries,
95
178
  limit: 5,
@@ -104,70 +187,120 @@ let ChatToolOutputContentSubPart = class ChatToolOutputContentSubPart extends Di
104
187
  event.stopPropagation();
105
188
  this._contextMenuService.showContextMenu({
106
189
  menuId: MenuId.ChatToolOutputResourceContext,
107
- menuActionOptions: { shouldForwardArgs: true },
108
- getAnchor: () => ({ x: event.pageX, y: event.pageY }),
109
- getActionsContext: () => ({ parts: [part] }),
190
+ menuActionOptions: {
191
+ shouldForwardArgs: true
192
+ },
193
+ getAnchor: () => ({
194
+ x: event.pageX,
195
+ y: event.pageY
196
+ }),
197
+ getActionsContext: () => ({
198
+ parts: [part]
199
+ })
110
200
  });
111
201
  }
112
202
  };
113
203
  itemsContainer.appendChild(attachments.domNode);
114
- const toolbar = this._register(this._instantiationService.createInstance(MenuWorkbenchToolBar, actionsContainer, MenuId.ChatToolOutputResourceToolbar, {
115
- menuOptions: {
116
- shouldForwardArgs: true,
117
- },
118
- }));
119
- toolbar.context = { parts };
204
+ const toolbar = this._register(this._instantiationService.createInstance(
205
+ MenuWorkbenchToolBar,
206
+ actionsContainer,
207
+ MenuId.ChatToolOutputResourceToolbar,
208
+ {
209
+ menuOptions: {
210
+ shouldForwardArgs: true
211
+ }
212
+ }
213
+ ));
214
+ toolbar.context = {
215
+ parts
216
+ };
217
+ if (deferredImageParts.length > 0) {
218
+ this._register(disposableTimeout(() => {
219
+ for (const {
220
+ index,
221
+ part
222
+ } of deferredImageParts) {
223
+ try {
224
+ const value = decodeBase64(part.base64Value).buffer;
225
+ entries[index] = {
226
+ kind: "image",
227
+ id: generateUuid(),
228
+ name: basename(part.uri),
229
+ value,
230
+ mimeType: part.mimeType,
231
+ isURL: false,
232
+ references: [{
233
+ kind: "reference",
234
+ reference: part.uri
235
+ }]
236
+ };
237
+ } catch {}
238
+ }
239
+ attachments.updateVariables(entries);
240
+ }, ChatToolOutputContentSubPart_1.IMAGE_DECODE_DELAY_MS));
241
+ }
120
242
  }
121
- addCodeBlock(part, container) {
122
- if (part.title) {
123
- const title = $('div.chat-confirmation-widget-title');
124
- const renderedTitle = this._register(this._markdownRendererService.render(this.toMdString(part.title)));
243
+ addCodeBlock(parts, container) {
244
+ const firstPart = parts[0];
245
+ if (firstPart.title) {
246
+ const title = $("div.chat-confirmation-widget-title");
247
+ const renderedTitle = this._register(this._markdownRendererService.render(this.toMdString(firstPart.title)));
125
248
  title.appendChild(renderedTitle.element);
126
249
  container.appendChild(title);
127
250
  }
251
+ const combinedText = ( parts.map(p => p.data)).join("\n");
252
+ const textModel = this._register(this.modelService.createModel(
253
+ combinedText,
254
+ this.languageService.createById(firstPart.languageId),
255
+ undefined,
256
+ true
257
+ ));
128
258
  const data = {
129
- languageId: part.languageId,
130
- textModel: Promise.resolve(part.textModel),
131
- codeBlockIndex: part.codeBlockInfo.codeBlockIndex,
259
+ languageId: firstPart.languageId,
260
+ textModel: Promise.resolve(textModel),
261
+ codeBlockIndex: firstPart.codeBlockIndex,
132
262
  codeBlockPartIndex: 0,
133
263
  element: this.context.element,
134
264
  parentContextKeyService: this.contextKeyService,
135
- renderOptions: part.options,
136
- chatSessionResource: this.context.element.sessionResource,
265
+ renderOptions: firstPart.options,
266
+ chatSessionResource: this.context.element.sessionResource
137
267
  };
138
268
  const editorReference = this._register(this.context.editorPool.get());
139
- editorReference.object.render(data, this._currentWidth || 300);
140
- this._register(editorReference.object.onDidChangeContentHeight(() => this._onDidChangeHeight.fire()));
269
+ editorReference.object.render(data, this.context.currentWidth.get());
141
270
  container.appendChild(editorReference.object.element);
142
271
  this._editorReferences.push(editorReference);
143
- this.codeblocks.push(part.codeBlockInfo);
272
+ this.codeblocks.push({
273
+ ownerMarkdownPartId: firstPart.ownerMarkdownPartId,
274
+ codeBlockIndex: firstPart.codeBlockIndex,
275
+ elementId: this.context.element.id,
276
+ uri: textModel.uri,
277
+ uriPromise: Promise.resolve(textModel.uri),
278
+ codemapperUri: undefined,
279
+ chatSessionResource: this.context.element.sessionResource,
280
+ focus: () => {}
281
+ });
144
282
  }
145
283
  layout(width) {
146
- this._currentWidth = width;
147
284
  this._editorReferences.forEach(r => r.object.layout(width));
148
285
  }
149
286
  };
150
- ChatToolOutputContentSubPart = ( __decorate([
151
- ( __param(2, IInstantiationService)),
152
- ( __param(3, IContextKeyService)),
153
- ( __param(4, IContextMenuService)),
154
- ( __param(5, IFileService)),
155
- ( __param(6, IMarkdownRendererService))
156
- ], ChatToolOutputContentSubPart));
287
+ ChatToolOutputContentSubPart = ChatToolOutputContentSubPart_1 = ( __decorate([( __param(2, IInstantiationService)), ( __param(3, IContextKeyService)), ( __param(4, IContextMenuService)), ( __param(5, IFileService)), ( __param(6, IMarkdownRendererService)), ( __param(7, IModelService)), ( __param(8, ILanguageService))], ChatToolOutputContentSubPart));
157
288
  class SaveResourcesAction extends Action2 {
158
- static { this.ID = 'chat.toolOutput.save'; }
289
+ static {
290
+ this.ID = "chat.toolOutput.save";
291
+ }
159
292
  constructor() {
160
293
  super({
161
294
  id: SaveResourcesAction.ID,
162
- title: ( localize2(5691, "Save As...")),
295
+ title: ( localize2(5937, "Save As...")),
163
296
  icon: Codicon.cloudDownload,
164
297
  menu: [{
165
- id: MenuId.ChatToolOutputResourceToolbar,
166
- group: 'navigation',
167
- order: 1
168
- }, {
169
- id: MenuId.ChatToolOutputResourceContext,
170
- }]
298
+ id: MenuId.ChatToolOutputResourceToolbar,
299
+ group: "navigation",
300
+ order: 1
301
+ }, {
302
+ id: MenuId.ChatToolOutputResourceContext
303
+ }]
171
304
  });
172
305
  }
173
306
  async run(accessor, context) {
@@ -182,34 +315,34 @@ class SaveResourcesAction extends Action2 {
182
315
  const savePart = async (part, isFolder, uri) => {
183
316
  const target = isFolder ? joinPath(uri, basename(part.uri)) : uri;
184
317
  try {
185
- if (part.kind === 'data') {
318
+ if (part.kind === "data") {
186
319
  await fileService.copy(part.uri, target, true);
187
- }
188
- else {
320
+ } else {
189
321
  const contents = await fileService.readFile(part.uri);
190
322
  await fileService.writeFile(target, contents.value);
191
323
  }
192
- }
193
- catch (e) {
194
- notificationService.error(( localize(5692, "Failed to save {0}: {1}", basename(part.uri), e)));
324
+ } catch (e) {
325
+ notificationService.error(( localize(5938, "Failed to save {0}: {1}", basename(part.uri), e)));
195
326
  }
196
327
  };
197
328
  const withProgress = async (thenReveal, todo) => {
198
329
  await progressService.withProgress({
199
330
  location: ProgressLocation.Notification,
200
331
  delay: 5_000,
201
- title: ( localize(5693, "Saving resources...")),
202
- }, async (report) => {
332
+ title: ( localize(5939, "Saving resources..."))
333
+ }, async report => {
203
334
  for (const task of todo) {
204
335
  await task();
205
- report.report({ increment: 1, total: todo.length });
336
+ report.report({
337
+ increment: 1,
338
+ total: todo.length
339
+ });
206
340
  }
207
341
  });
208
342
  if (workspaceContextService.isInsideWorkspace(thenReveal)) {
209
343
  commandService.executeCommand(REVEAL_IN_EXPLORER_COMMAND_ID, thenReveal);
210
- }
211
- else {
212
- notificationService.info(( localize(5694, "Saved resources to {0}", labelService.getUriLabel(thenReveal))));
344
+ } else {
345
+ notificationService.info(( localize(5940, "Saved resources to {0}", labelService.getUriLabel(thenReveal))));
213
346
  }
214
347
  };
215
348
  if (context.parts.length === 1) {
@@ -219,14 +352,13 @@ class SaveResourcesAction extends Action2 {
219
352
  return;
220
353
  }
221
354
  await withProgress(uri, [() => savePart(part, false, uri)]);
222
- }
223
- else {
355
+ } else {
224
356
  const uris = await fileDialog.showOpenDialog({
225
- title: ( localize(5695, "Pick folder to save resources")),
357
+ title: ( localize(5941, "Pick folder to save resources")),
226
358
  canSelectFiles: false,
227
359
  canSelectFolders: true,
228
360
  canSelectMany: false,
229
- defaultUri: workspaceContextService.getWorkspace().folders[0]?.uri,
361
+ defaultUri: workspaceContextService.getWorkspace().folders[0]?.uri
230
362
  });
231
363
  if (!uris?.length) {
232
364
  return;
@@ -5,31 +5,33 @@ import { IInstantiationService } from "@codingame/monaco-vscode-api/vscode/vs/pl
5
5
  import { WorkbenchCompressibleAsyncDataTree } from "@codingame/monaco-vscode-api/vscode/vs/platform/list/browser/listService";
6
6
  import { IOpenerService } from "@codingame/monaco-vscode-api/vscode/vs/platform/opener/common/opener.service";
7
7
  import { IThemeService } from "@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/themeService.service";
8
- import { ChatTreeItem } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chat";
8
+ import { IChatResponseProgressFileTreeData } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService/chatService";
9
+ import { IChatProgressRenderableResponseContent } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/model/chatModel";
9
10
  import { IDisposableReference } from "./chatCollections.js";
10
11
  import { IChatContentPart } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatContentParts";
11
- import { IChatProgressRenderableResponseContent } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/model/chatModel";
12
- import { IChatResponseProgressFileTreeData } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService/chatService";
13
12
  export declare class ChatTreeContentPart extends Disposable implements IChatContentPart {
14
13
  private readonly openerService;
15
14
  readonly domNode: HTMLElement;
16
- private readonly _onDidChangeHeight;
17
- readonly onDidChangeHeight: Event<void>;
18
15
  readonly onDidFocus: Event<void>;
19
16
  private tree;
20
- constructor(data: IChatResponseProgressFileTreeData, element: ChatTreeItem, treePool: TreePool, treeDataIndex: number, openerService: IOpenerService);
17
+ constructor(data: IChatResponseProgressFileTreeData, treePool: TreePool, openerService: IOpenerService);
21
18
  domFocus(): void;
22
19
  hasSameContent(other: IChatProgressRenderableResponseContent): boolean;
23
20
  addDisposable(disposable: IDisposable): void;
24
21
  }
22
+ interface ITreePoolWrapper extends IDisposable {
23
+ tree: WorkbenchCompressibleAsyncDataTree<IChatResponseProgressFileTreeData, IChatResponseProgressFileTreeData, void>;
24
+ }
25
25
  export declare class TreePool extends Disposable {
26
26
  private _onDidChangeVisibility;
27
27
  private readonly instantiationService;
28
28
  private readonly configService;
29
29
  private readonly themeService;
30
30
  private _pool;
31
- get inUse(): ReadonlySet<WorkbenchCompressibleAsyncDataTree<IChatResponseProgressFileTreeData, IChatResponseProgressFileTreeData, void>>;
31
+ get inUse(): ReadonlySet<ITreePoolWrapper>;
32
32
  constructor(_onDidChangeVisibility: Event<boolean>, instantiationService: IInstantiationService, configService: IConfigurationService, themeService: IThemeService);
33
33
  private treeFactory;
34
34
  get(): IDisposableReference<WorkbenchCompressibleAsyncDataTree<IChatResponseProgressFileTreeData, IChatResponseProgressFileTreeData, void>>;
35
+ clear(): void;
35
36
  }
37
+ export {};
@@ -1,7 +1,6 @@
1
1
 
2
2
  import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
3
3
  import { $ as $$1 } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/dom';
4
- import { Emitter } from '@codingame/monaco-vscode-api/vscode/vs/base/common/event';
5
4
  import { Disposable, DisposableStore } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
6
5
  import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
7
6
  import { IConfigurationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service';
@@ -11,35 +10,29 @@ import { WorkbenchCompressibleAsyncDataTree } from '@codingame/monaco-vscode-api
11
10
  import { IOpenerService } from '@codingame/monaco-vscode-api/vscode/vs/platform/opener/common/opener.service';
12
11
  import { IThemeService } from '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/themeService.service';
13
12
  import { ResourceLabels } from '@codingame/monaco-vscode-api/vscode/vs/workbench/browser/labels';
14
- import { ResourcePool } from './chatCollections.js';
15
13
  import { createFileIconThemableTreeContainerScope } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/files/browser/views/explorerView';
14
+ import { ResourcePool } from './chatCollections.js';
16
15
 
17
16
  const $ = $$1;
18
17
  let ChatTreeContentPart = class ChatTreeContentPart extends Disposable {
19
- constructor(data, element, treePool, treeDataIndex, openerService) {
18
+ constructor(data, treePool, openerService) {
20
19
  super();
21
20
  this.openerService = openerService;
22
- this._onDidChangeHeight = this._register(( new Emitter()));
23
- this.onDidChangeHeight = this._onDidChangeHeight.event;
24
21
  const ref = this._register(treePool.get());
25
22
  this.tree = ref.object;
26
23
  this.onDidFocus = this.tree.onDidFocus;
27
- this._register(this.tree.onDidOpen((e) => {
28
- if (e.element && !('children' in e.element)) {
24
+ this._register(this.tree.onDidOpen(e => {
25
+ if (e.element && !("children" in e.element)) {
29
26
  this.openerService.open(e.element.uri);
30
27
  }
31
28
  }));
32
- this._register(this.tree.onDidChangeCollapseState(() => {
33
- this._onDidChangeHeight.fire();
34
- }));
35
- this._register(this.tree.onContextMenu((e) => {
29
+ this._register(this.tree.onContextMenu(e => {
36
30
  e.browserEvent.preventDefault();
37
31
  e.browserEvent.stopPropagation();
38
32
  }));
39
33
  this.tree.setInput(data).then(() => {
40
34
  if (!ref.isStale()) {
41
35
  this.tree.layout();
42
- this._onDidChangeHeight.fire();
43
36
  }
44
37
  });
45
38
  this.domNode = this.tree.getHTMLElement().parentElement;
@@ -48,15 +41,13 @@ let ChatTreeContentPart = class ChatTreeContentPart extends Disposable {
48
41
  this.tree.domFocus();
49
42
  }
50
43
  hasSameContent(other) {
51
- return other.kind === 'treeData';
44
+ return other.kind === "treeData";
52
45
  }
53
46
  addDisposable(disposable) {
54
47
  this._register(disposable);
55
48
  }
56
49
  };
57
- ChatTreeContentPart = ( __decorate([
58
- ( __param(4, IOpenerService))
59
- ], ChatTreeContentPart));
50
+ ChatTreeContentPart = ( __decorate([( __param(2, IOpenerService))], ChatTreeContentPart));
60
51
  let TreePool = class TreePool extends Disposable {
61
52
  get inUse() {
62
53
  return this._pool.inUse;
@@ -70,48 +61,64 @@ let TreePool = class TreePool extends Disposable {
70
61
  this._pool = this._register(( new ResourcePool(() => this.treeFactory())));
71
62
  }
72
63
  treeFactory() {
73
- const resourceLabels = this._register(this.instantiationService.createInstance(ResourceLabels, { onDidChangeVisibility: this._onDidChangeVisibility }));
74
- const container = $('.interactive-response-progress-tree');
75
- this._register(createFileIconThemableTreeContainerScope(container, this.themeService));
76
- const tree = this.instantiationService.createInstance((WorkbenchCompressibleAsyncDataTree), 'ChatListRenderer', container, ( new ChatListTreeDelegate()), ( new ChatListTreeCompressionDelegate()), [( new ChatListTreeRenderer(resourceLabels, this.configService.getValue('explorer.decorations')))], ( new ChatListTreeDataSource()), {
77
- collapseByDefault: () => false,
78
- expandOnlyOnTwistieClick: () => false,
79
- identityProvider: {
80
- getId: (e) => ( e.uri.toString())
81
- },
82
- accessibilityProvider: {
83
- getAriaLabel: (element) => element.label,
84
- getWidgetAriaLabel: () => ( localize(5696, "File Tree"))
85
- },
86
- alwaysConsumeMouseWheel: false
87
- });
88
- return tree;
64
+ const store = ( new DisposableStore());
65
+ const resourceLabels = store.add(this.instantiationService.createInstance(ResourceLabels, {
66
+ onDidChangeVisibility: this._onDidChangeVisibility
67
+ }));
68
+ const container = $(".interactive-response-progress-tree");
69
+ store.add(createFileIconThemableTreeContainerScope(container, this.themeService));
70
+ const tree = this.instantiationService.createInstance(
71
+ WorkbenchCompressibleAsyncDataTree,
72
+ "ChatListRenderer",
73
+ container,
74
+ ( new ChatListTreeDelegate()),
75
+ ( new ChatListTreeCompressionDelegate()),
76
+ [( new ChatListTreeRenderer(resourceLabels, this.configService.getValue("explorer.decorations")))],
77
+ ( new ChatListTreeDataSource()),
78
+ {
79
+ collapseByDefault: () => false,
80
+ expandOnlyOnTwistieClick: () => false,
81
+ identityProvider: {
82
+ getId: e => ( e.uri.toString())
83
+ },
84
+ accessibilityProvider: {
85
+ getAriaLabel: element => element.label,
86
+ getWidgetAriaLabel: () => ( localize(5942, "File Tree"))
87
+ },
88
+ alwaysConsumeMouseWheel: false
89
+ }
90
+ );
91
+ return {
92
+ tree,
93
+ dispose: () => store.dispose()
94
+ };
89
95
  }
90
96
  get() {
91
- const object = this._pool.get();
97
+ const wrapper = this._pool.get();
92
98
  let stale = false;
93
99
  return {
94
- object,
100
+ object: wrapper.tree,
95
101
  isStale: () => stale,
96
102
  dispose: () => {
97
103
  stale = true;
98
- this._pool.release(object);
104
+ this._pool.release(wrapper);
99
105
  }
100
106
  };
101
107
  }
108
+ clear() {
109
+ this._pool.clear();
110
+ }
102
111
  };
103
- TreePool = ( __decorate([
104
- ( __param(1, IInstantiationService)),
105
- ( __param(2, IConfigurationService)),
106
- ( __param(3, IThemeService))
107
- ], TreePool));
112
+ TreePool = ( __decorate([( __param(1, IInstantiationService)), ( __param(2, IConfigurationService)), ( __param(3, IThemeService))], TreePool));
108
113
  class ChatListTreeDelegate {
109
- static { this.ITEM_HEIGHT = 22; }
114
+ static {
115
+ this.ITEM_HEIGHT = 22;
116
+ }
110
117
  getHeight(element) {
111
118
  return ChatListTreeDelegate.ITEM_HEIGHT;
112
119
  }
113
120
  getTemplateId(element) {
114
- return 'chatListTreeTemplate';
121
+ return "chatListTreeTemplate";
115
122
  }
116
123
  }
117
124
  class ChatListTreeCompressionDelegate {
@@ -123,34 +130,44 @@ class ChatListTreeRenderer {
123
130
  constructor(labels, decorations) {
124
131
  this.labels = labels;
125
132
  this.decorations = decorations;
126
- this.templateId = 'chatListTreeTemplate';
133
+ this.templateId = "chatListTreeTemplate";
127
134
  }
128
135
  renderCompressedElements(element, index, templateData) {
129
- templateData.label.element.style.display = 'flex';
130
- const label = ( element.element.elements.map((e) => e.label));
131
- templateData.label.setResource({ resource: element.element.elements[0].uri, name: label }, {
136
+ templateData.label.element.style.display = "flex";
137
+ const label = ( element.element.elements.map(e => e.label));
138
+ templateData.label.setResource({
139
+ resource: element.element.elements[0].uri,
140
+ name: label
141
+ }, {
132
142
  title: element.element.elements[0].label,
133
143
  fileKind: element.children ? FileKind.FOLDER : FileKind.FILE,
134
- extraClasses: ['explorer-item'],
144
+ extraClasses: ["explorer-item"],
135
145
  fileDecorations: this.decorations
136
146
  });
137
147
  }
138
148
  renderTemplate(container) {
139
149
  const templateDisposables = ( new DisposableStore());
140
- const label = templateDisposables.add(this.labels.create(container, { supportHighlights: true }));
141
- return { templateDisposables, label };
150
+ const label = templateDisposables.add(this.labels.create(container, {
151
+ supportHighlights: true
152
+ }));
153
+ return {
154
+ templateDisposables,
155
+ label
156
+ };
142
157
  }
143
158
  renderElement(element, index, templateData) {
144
- templateData.label.element.style.display = 'flex';
159
+ templateData.label.element.style.display = "flex";
145
160
  if (!element.children.length && element.element.type !== FileType.Directory) {
146
161
  templateData.label.setFile(element.element.uri, {
147
162
  fileKind: FileKind.FILE,
148
163
  hidePath: true,
149
- fileDecorations: this.decorations,
164
+ fileDecorations: this.decorations
150
165
  });
151
- }
152
- else {
153
- templateData.label.setResource({ resource: element.element.uri, name: element.element.label }, {
166
+ } else {
167
+ templateData.label.setResource({
168
+ resource: element.element.uri,
169
+ name: element.element.label
170
+ }, {
154
171
  title: element.element.label,
155
172
  fileKind: FileKind.FOLDER,
156
173
  fileDecorations: this.decorations