@codingame/monaco-vscode-katex-common 31.0.0 → 32.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 (220) hide show
  1. package/package.json +2 -2
  2. package/vscode/src/vs/platform/actionWidget/browser/actionWidgetDropdown.d.ts +15 -3
  3. package/vscode/src/vs/platform/actionWidget/browser/actionWidgetDropdown.js +6 -5
  4. package/vscode/src/vs/platform/actions/browser/buttonbar.d.ts +5 -1
  5. package/vscode/src/vs/platform/actions/browser/buttonbar.js +45 -14
  6. package/vscode/src/vs/platform/sandbox/common/terminalSandboxService.d.ts +15 -1
  7. package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatAccessibilityProvider.js +16 -16
  8. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContinueInAction.js +15 -10
  9. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatElicitationActions.js +1 -1
  10. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatExecuteActions.js +51 -54
  11. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatTitleActions.js +10 -10
  12. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolActions.js +11 -11
  13. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolPicker.js +13 -13
  14. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionHoverWidget.d.ts +3 -1
  15. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionHoverWidget.js +45 -23
  16. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.js +13 -7
  17. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.js +9 -9
  18. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsOpener.js +5 -3
  19. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.d.ts +4 -1
  20. package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.js +46 -32
  21. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentModel.js +8 -0
  22. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentWidgets.d.ts +23 -1
  23. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentWidgets.js +155 -46
  24. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatImplicitContext.d.ts +1 -0
  25. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatImplicitContext.js +20 -1
  26. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/implicitContextAttachment.d.ts +4 -1
  27. package/vscode/src/vs/workbench/contrib/chat/browser/attachments/implicitContextAttachment.js +37 -14
  28. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingActions.js +34 -34
  29. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessionPickerActionItem.js +1 -1
  30. package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/media/chatSessionPickerActionItem.css +1 -0
  31. package/vscode/src/vs/workbench/contrib/chat/browser/tools/chatToolRiskAssessmentService.d.ts +28 -0
  32. package/vscode/src/vs/workbench/contrib/chat/browser/tools/chatToolRiskAssessmentService.js +250 -0
  33. package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolSetsContribution.js +13 -13
  34. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatAgentHover.js +14 -11
  35. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatArtifactsWidget.js +10 -10
  36. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAgentCommandContentPart.js +1 -1
  37. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAnonymousRateLimitedPart.js +2 -2
  38. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAttachmentsContentPart.js +7 -2
  39. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatChangesSummaryPart.js +1 -1
  40. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCodeCitationContentPart.js +1 -1
  41. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCommandContentPart.js +1 -1
  42. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationContentPart.js +7 -3
  43. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationWidget.d.ts +12 -2
  44. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationWidget.js +51 -20
  45. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatDisabledClaudeHooksContentPart.js +3 -3
  46. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatElicitationContentPart.d.ts +6 -1
  47. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatElicitationContentPart.js +56 -3
  48. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatExtensionsContentPart.js +1 -1
  49. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatHookContentPart.js +1 -1
  50. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatIncrementalRendering/buffers/paragraphBuffer.d.ts +1 -1
  51. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatIncrementalRendering/buffers/paragraphBuffer.js +2 -2
  52. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatIncrementalRendering/chatIncrementalRendering.d.ts +3 -1
  53. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatIncrementalRendering/chatIncrementalRendering.js +4 -0
  54. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatInlineAnchorWidget.js +13 -13
  55. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMarkdownContentPart.js +68 -10
  56. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMcpServersInteractionContentPart.js +8 -8
  57. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMultiDiffContentPart.js +4 -4
  58. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatPlanReviewPart.d.ts +58 -2
  59. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatPlanReviewPart.js +653 -75
  60. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatProgressContentPart.js +28 -10
  61. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuestionCarouselPart.d.ts +5 -1
  62. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuestionCarouselPart.js +91 -54
  63. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuotaExceededPart.js +7 -5
  64. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatReferencesContentPart.js +53 -51
  65. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatResourceGroupWidget.js +5 -5
  66. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSubagentContentPart.js +11 -11
  67. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSuggestNextWidget.js +6 -6
  68. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTextEditContentPart.js +1 -1
  69. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatThinkingContentPart.d.ts +4 -1
  70. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatThinkingContentPart.js +42 -22
  71. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTipContentPart.js +9 -9
  72. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTodoListWidget.js +17 -17
  73. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolInputOutputContentPart.js +2 -2
  74. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTreeContentPart.js +1 -1
  75. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatWorkspaceEditContentPart.js +3 -3
  76. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/codeBlockPart.d.ts +6 -2
  77. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/codeBlockPart.js +93 -35
  78. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatConfirmationWidget.css +5 -0
  79. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatPlanReview.css +169 -27
  80. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatQuestionCarousel.css +13 -4
  81. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatThinkingContent.css +1 -1
  82. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatToolConfirmationCarousel.css +29 -0
  83. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/abstractToolConfirmationSubPart.d.ts +1 -0
  84. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/abstractToolConfirmationSubPart.js +60 -15
  85. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatExtensionsInstallToolSubPart.js +13 -6
  86. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppModel.js +1 -1
  87. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppSubPart.js +3 -3
  88. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMissingSandboxDepsConfirmationSubPart.js +2 -2
  89. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatModifiedFilesConfirmationSubPart.js +15 -8
  90. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolConfirmationSubPart.d.ts +6 -1
  91. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolConfirmationSubPart.js +125 -26
  92. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolProgressPart.d.ts +2 -1
  93. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolProgressPart.js +29 -23
  94. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolConfirmationCarouselPart.d.ts +14 -0
  95. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolConfirmationCarouselPart.js +119 -10
  96. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolConfirmationSubPart.js +6 -6
  97. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolInvocationPart.js +1 -1
  98. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolOutputPart.js +2 -2
  99. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPartUtilities.js +5 -5
  100. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPostExecuteConfirmationPart.js +5 -5
  101. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/media/toolRiskBadge.css +77 -0
  102. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/toolRiskBadgeWidget.d.ts +38 -0
  103. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/toolRiskBadgeWidget.js +125 -0
  104. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatDragAndDrop.js +11 -11
  105. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.d.ts +1 -0
  106. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.js +132 -59
  107. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatWidget.d.ts +16 -3
  108. package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatWidget.js +156 -67
  109. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatFollowups.js +1 -1
  110. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputNotificationService.d.ts +55 -0
  111. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputNotificationService.js +93 -0
  112. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputNotificationWidget.d.ts +21 -0
  113. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputNotificationWidget.js +133 -0
  114. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPart.d.ts +53 -8
  115. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPart.js +288 -125
  116. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelPicker.d.ts +23 -2
  117. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelPicker.js +699 -145
  118. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelSelectionLogic.d.ts +12 -8
  119. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelSelectionLogic.js +12 -11
  120. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatPhoneInputPresenter.d.ts +62 -0
  121. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatPhoneInputPresenter.js +120 -0
  122. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/delegationSessionPickerActionItem.js +5 -5
  123. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/media/chatInputNotificationWidget.css +191 -0
  124. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/media/chatPhoneInputPresenter.css +22 -0
  125. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modePickerActionItem.d.ts +3 -3
  126. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modePickerActionItem.js +9 -25
  127. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modelPickerActionItem.js +4 -3
  128. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/permissionPickerActionItem.d.ts +20 -1
  129. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/permissionPickerActionItem.js +89 -108
  130. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/sessionTargetPickerActionItem.js +3 -3
  131. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/workspacePickerActionItem.js +3 -3
  132. package/vscode/src/vs/workbench/contrib/chat/browser/widget/media/chat.css +521 -9
  133. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageDetails.js +7 -7
  134. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageWidget.js +2 -2
  135. package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/media/chatContextUsageDetails.css +19 -19
  136. package/vscode/src/vs/workbench/contrib/chat/common/chatImageExtraction.js +6 -6
  137. package/vscode/src/vs/workbench/contrib/chat/common/chatPermissionStorageKeys.d.ts +2 -0
  138. package/vscode/src/vs/workbench/contrib/chat/common/chatPermissionStorageKeys.js +6 -0
  139. package/vscode/src/vs/workbench/contrib/chat/common/chatPermissionWarnings.d.ts +27 -0
  140. package/vscode/src/vs/workbench/contrib/chat/common/chatPermissionWarnings.js +82 -0
  141. package/vscode/src/vs/workbench/contrib/chat/common/widget/chatColors.d.ts +3 -0
  142. package/vscode/src/vs/workbench/contrib/chat/common/widget/chatColors.js +44 -17
  143. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatAffordance.d.ts +1 -3
  144. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatAffordance.js +3 -46
  145. package/vscode/src/vs/workbench/contrib/inlineChat/browser/{inlineChatEditorAffordance.d.ts → inlineChatAffordanceWidget.d.ts} +1 -1
  146. package/vscode/src/vs/workbench/contrib/inlineChat/browser/{inlineChatEditorAffordance.js → inlineChatAffordanceWidget.js} +6 -6
  147. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatController.d.ts +2 -18
  148. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatController.js +19 -400
  149. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionService.d.ts +4 -9
  150. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatSessionService.js +1 -1
  151. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatWidget.d.ts +5 -19
  152. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatWidget.js +47 -133
  153. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatZoneWidget.d.ts +3 -1
  154. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatZoneWidget.js +103 -25
  155. package/vscode/src/vs/workbench/contrib/inlineChat/browser/media/inlineChat.css +29 -0
  156. package/vscode/src/vs/workbench/contrib/inlineChat/common/inlineChat.d.ts +3 -32
  157. package/vscode/src/vs/workbench/contrib/inlineChat/common/inlineChat.js +39 -92
  158. package/vscode/src/vs/workbench/contrib/interactive/browser/replInputHintContentWidget.js +3 -3
  159. package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/executionStatusBarItemController.js +7 -7
  160. package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindWidget.js +2 -2
  161. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/cellOperations.js +2 -2
  162. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/insertCellActions.js +24 -24
  163. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffComponents.js +3 -3
  164. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementOutputs.js +7 -7
  165. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditor.js +1 -1
  166. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditorBrowser.js +5 -5
  167. package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffList.js +1 -1
  168. package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditor.js +1 -1
  169. package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditorInput.js +1 -1
  170. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/basicExecuteStrategy.d.ts +7 -0
  171. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/basicExecuteStrategy.js +99 -32
  172. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/executeStrategy.d.ts +13 -1
  173. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/executeStrategy.js +76 -14
  174. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/noneExecuteStrategy.js +4 -3
  175. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/richExecuteStrategy.d.ts +9 -1
  176. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/executeStrategy/richExecuteStrategy.js +89 -28
  177. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/outputHelpers.js +1 -1
  178. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.d.ts +11 -1
  179. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.js +11 -7
  180. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalToolTelemetry.d.ts +3 -1
  181. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalToolTelemetry.js +7 -3
  182. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/autoApprove/commandLineAutoApprover.js +1 -1
  183. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/autoApprove/npmScriptAutoApprover.js +1 -1
  184. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAnalyzer.d.ts +1 -0
  185. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.js +12 -12
  186. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineFileWriteAnalyzer.d.ts +8 -0
  187. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineFileWriteAnalyzer.js +11 -2
  188. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLineBackgroundDetachRewriter.d.ts +20 -0
  189. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLineBackgroundDetachRewriter.js +59 -4
  190. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLineSandboxRewriter.d.ts +8 -1
  191. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineRewriter/commandLineSandboxRewriter.js +24 -3
  192. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.d.ts +47 -0
  193. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.js +111 -30
  194. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.d.ts +60 -3
  195. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.js +455 -171
  196. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/treeSitterCommandParser.d.ts +33 -0
  197. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/treeSitterCommandParser.js +82 -0
  198. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxCommandRules.d.ts +31 -0
  199. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxCommandRules.js +49 -0
  200. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxReadAllowList.d.ts +18 -0
  201. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxReadAllowList.js +302 -0
  202. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxRuntimeConfigurationPerOperation.d.ts +7 -0
  203. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxRuntimeConfigurationPerOperation.js +118 -0
  204. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxService.d.ts +34 -4
  205. package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxService.js +233 -48
  206. package/vscode/src/vs/platform/actions/browser/actionbar.d.ts +0 -16
  207. package/vscode/src/vs/platform/actions/browser/actionbar.js +0 -22
  208. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorActions.d.ts +0 -46
  209. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorActions.js +0 -539
  210. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorOverlay.d.ts +0 -29
  211. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingEditorOverlay.js +0 -386
  212. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingExplanationWidget.d.ts +0 -101
  213. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingExplanationWidget.js +0 -509
  214. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/media/chatEditingEditorOverlay.css +0 -130
  215. package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/media/chatEditingExplanationWidget.css +0 -276
  216. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPartWidgets.d.ts +0 -45
  217. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPartWidgets.js +0 -93
  218. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatOverlayWidget.d.ts +0 -39
  219. package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatOverlayWidget.js +0 -617
  220. package/vscode/src/vs/workbench/contrib/inlineChat/browser/media/inlineChatOverlayWidget.css +0 -231
@@ -56,6 +56,8 @@ import { INotebookService } from '@codingame/monaco-vscode-api/vscode/vs/workben
56
56
  import { toHistoryItemHoverContent } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/scm/browser/scmHistory';
57
57
  import { getHistoryItemEditorTitle } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/scm/browser/util';
58
58
  import { ITerminalService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/terminal/browser/terminal.service';
59
+ import { BrowserViewSharingState } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/browserView/common/browserView';
60
+ import { IBrowserViewWorkbenchService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/browserView/common/browserView.service';
59
61
  import { coerceImageBuffer } from '../../common/chatImageExtraction.js';
60
62
  import { ChatConfiguration } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/constants';
61
63
  import { OmittedState, getImageAttachmentLimit, isStringVariableEntry, PromptFileVariableKind } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/attachments/chatVariableEntries';
@@ -140,7 +142,7 @@ let AbstractChatAttachmentWidget = class AbstractChatAttachmentWidget extends Di
140
142
  if (!this._hasClearButton) {
141
143
  return ariaLabel;
142
144
  }
143
- return localize(5577, "{0} (Delete)", ariaLabel);
145
+ return localize(5681, "{0} (Delete)", ariaLabel);
144
146
  }
145
147
  attachClearButton() {
146
148
  if (this.attachment.range || !this.options.supportsDeletion) {
@@ -150,7 +152,7 @@ let AbstractChatAttachmentWidget = class AbstractChatAttachmentWidget extends Di
150
152
  const clearButton = ( new Button(this.element, {
151
153
  supportIcons: true,
152
154
  hoverDelegate: createInstantHoverDelegate(),
153
- title: ( localize(5578, "Remove from context"))
155
+ title: ( localize(5682, "Remove from context"))
154
156
  }));
155
157
  clearButton.element.tabIndex = -1;
156
158
  clearButton.icon = Codicon.close;
@@ -243,14 +245,14 @@ let FileAttachmentWidget = class FileAttachmentWidget extends AbstractChatAttach
243
245
  const fileDirname = dirname(resource.path);
244
246
  const friendlyName = `${fileBasename} ${fileDirname}`;
245
247
  let ariaLabel = range ? ( localize(
246
- 5579,
248
+ 5683,
247
249
  "Attached file, {0}, line {1} to line {2}",
248
250
  friendlyName,
249
251
  range.startLineNumber,
250
252
  range.endLineNumber
251
- )) : ( localize(5580, "Attached file, {0}", friendlyName));
253
+ )) : ( localize(5684, "Attached file, {0}", friendlyName));
252
254
  if (attachment.omittedState === OmittedState.Full) {
253
- ariaLabel = ( localize(5581, "Omitted this file: {0}", attachment.name));
255
+ ariaLabel = ( localize(5685, "Omitted this file: {0}", attachment.name));
254
256
  this.renderOmittedWarning(friendlyName, ariaLabel);
255
257
  } else {
256
258
  const fileOptions = {
@@ -294,7 +296,7 @@ let FileAttachmentWidget = class FileAttachmentWidget extends AbstractChatAttach
294
296
  hoverElement.setAttribute("aria-label", ariaLabel);
295
297
  this.element.classList.add("warning");
296
298
  hoverElement.textContent = ( localize(
297
- 5582,
299
+ 5686,
298
300
  "{0} does not support this file type.",
299
301
  this.currentLanguageModel ? this.languageModelsService.lookupLanguageModel(this.currentLanguageModel.identifier)?.name : this.currentLanguageModel ?? "This model"
300
302
  ));
@@ -307,7 +309,7 @@ let FileAttachmentWidget = class FileAttachmentWidget extends AbstractChatAttach
307
309
  this.element.classList.add("warning");
308
310
  const hoverElement = $("div.chat-attached-context-hover");
309
311
  hoverElement.textContent = ( localize(
310
- 5583,
312
+ 5687,
311
313
  "This folder contains {0} images, which exceeds the maximum of {1} images per request. Older images will not be sent.",
312
314
  imageCount,
313
315
  limit
@@ -345,7 +347,7 @@ let TerminalCommandAttachmentWidget = class TerminalCommandAttachmentWidget exte
345
347
  );
346
348
  this.hoverService = hoverService;
347
349
  this.terminalService = terminalService;
348
- const ariaLabel = ( localize(5584, "Terminal command, {0}", attachment.command));
350
+ const ariaLabel = ( localize(5688, "Terminal command, {0}", attachment.command));
349
351
  const clickHandler = () => this.openResource(attachment.resource, {
350
352
  editorOptions: {
351
353
  preserveFocus: true
@@ -399,16 +401,16 @@ function getHoverContent(ariaLabel, attachment) {
399
401
  const hoverElement = $("div.chat-attached-context-hover");
400
402
  hoverElement.setAttribute("aria-label", ariaLabel);
401
403
  const commandTitle = $("div", {}, typeof attachment.exitCode === "number" ? ( localize(
402
- 5585,
404
+ 5689,
403
405
  "Command: {0}, exit code: {1}",
404
406
  attachment.command,
405
407
  attachment.exitCode
406
- )) : ( localize(5586, "Command")));
408
+ )) : ( localize(5690, "Command")));
407
409
  commandTitle.classList.add("attachment-additional-info");
408
410
  const commandBlock = $("pre.chat-terminal-command-block");
409
411
  hoverElement.append(commandTitle, commandBlock);
410
412
  if (attachment.output && attachment.output.trim().length > 0) {
411
- const outputTitle = $("div", {}, ( localize(5587, "Output:")));
413
+ const outputTitle = $("div", {}, ( localize(5691, "Output:")));
412
414
  outputTitle.classList.add("attachment-additional-info");
413
415
  const outputBlock = $("pre.chat-terminal-command-output");
414
416
  const fullOutputLines = attachment.output.split("\n");
@@ -472,13 +474,13 @@ let ImageAttachmentWidget = class ImageAttachmentWidget extends AbstractChatAtta
472
474
  this.chatImageCarouselService = chatImageCarouselService;
473
475
  let ariaLabel;
474
476
  if (attachment.omittedState === OmittedState.Full) {
475
- ariaLabel = ( localize(5588, "Omitted this image: {0}", attachment.name));
477
+ ariaLabel = ( localize(5692, "Omitted this image: {0}", attachment.name));
476
478
  } else if (attachment.omittedState === OmittedState.Partial) {
477
- ariaLabel = ( localize(5589, "Partially omitted this image: {0}", attachment.name));
479
+ ariaLabel = ( localize(5693, "Partially omitted this image: {0}", attachment.name));
478
480
  } else if (attachment.omittedState === OmittedState.ImageLimitExceeded) {
479
- ariaLabel = ( localize(5590, "Image not sent due to limit: {0}", attachment.name));
481
+ ariaLabel = ( localize(5694, "Image not sent due to limit: {0}", attachment.name));
480
482
  } else {
481
- ariaLabel = ( localize(5591, "Attached image, {0}", attachment.name));
483
+ ariaLabel = ( localize(5695, "Attached image, {0}", attachment.name));
482
484
  }
483
485
  const ref = attachment.references?.[0]?.reference;
484
486
  resource = ref && URI.isUri(ref) ? ref : undefined;
@@ -569,7 +571,7 @@ function createImageElements(
569
571
  hoverElement.setAttribute("aria-label", ariaLabel);
570
572
  if (previewFeaturesDisabled) {
571
573
  element.classList.add("warning");
572
- hoverElement.textContent = ( localize(5592, "Vision is disabled by your organization."));
574
+ hoverElement.textContent = ( localize(5696, "Vision is disabled by your organization."));
573
575
  disposable.add(hoverService.setupDelayedHover(element, {
574
576
  content: hoverElement,
575
577
  style: HoverStyle.Pointer
@@ -577,7 +579,7 @@ function createImageElements(
577
579
  } else if ((!supportsVision && currentLanguageModel) || omittedState === OmittedState.Full) {
578
580
  element.classList.add("warning");
579
581
  hoverElement.textContent = ( localize(
580
- 5593,
582
+ 5697,
581
583
  "{0} does not support images.",
582
584
  currentLanguageModelName ?? "This model"
583
585
  ));
@@ -589,11 +591,11 @@ function createImageElements(
589
591
  element.classList.add("warning");
590
592
  const maxImagesPerRequest = getImageAttachmentLimit(currentLanguageModel?.metadata);
591
593
  hoverElement.textContent = maxImagesPerRequest !== undefined ? ( localize(
592
- 5594,
594
+ 5698,
593
595
  "This image was not sent because the maximum of {0} images per request was exceeded.",
594
596
  maxImagesPerRequest
595
597
  )) : ( localize(
596
- 5595,
598
+ 5699,
597
599
  "This image was not sent because this model's image limit was exceeded."
598
600
  ));
599
601
  disposable.add(hoverService.setupDelayedHover(element, {
@@ -628,7 +630,7 @@ function createImageElements(
628
630
  const urlContainer = $(
629
631
  "a.chat-attached-context-url",
630
632
  {},
631
- omittedState === OmittedState.Partial ? ( localize(5596, "This GIF was partially omitted - current frame will be sent.")) : fullName
633
+ omittedState === OmittedState.Partial ? ( localize(5700, "This GIF was partially omitted - current frame will be sent.")) : fullName
632
634
  );
633
635
  const separator = $("div.chat-attached-context-url-separator");
634
636
  disposable.add(addDisposableListener(urlContainer, "click", () => clickHandler()));
@@ -677,7 +679,7 @@ let PasteAttachmentWidget = class PasteAttachmentWidget extends AbstractChatAtta
677
679
  );
678
680
  this.hoverService = hoverService;
679
681
  this.instantiationService = instantiationService;
680
- const ariaLabel = ( localize(5597, "Attached context, {0}", attachment.name));
682
+ const ariaLabel = ( localize(5701, "Attached context, {0}", attachment.name));
681
683
  this.element.ariaLabel = this.appendDeletionHint(ariaLabel);
682
684
  const classNames = ["file-icon", `${attachment.language}-lang-file-icon`];
683
685
  let resource;
@@ -770,7 +772,7 @@ let DefaultChatAttachmentWidget = class DefaultChatAttachmentWidget extends Abst
770
772
  const withIcon = attachment.icon?.id ? `$(${attachment.icon.id})\u00A0${attachmentLabel}` : attachmentLabel;
771
773
  this.label.setLabel(withIcon, correspondingContentReference?.options?.status?.description);
772
774
  }
773
- this.element.ariaLabel = this.appendDeletionHint(( localize(5597, "Attached context, {0}", attachment.name)));
775
+ this.element.ariaLabel = this.appendDeletionHint(( localize(5701, "Attached context, {0}", attachment.name)));
774
776
  if (attachment.kind === "diagnostic") {
775
777
  if (attachment.filterUri) {
776
778
  resource = attachment.filterUri ? URI.revive(attachment.filterUri) : undefined;
@@ -871,8 +873,8 @@ let PromptFileAttachmentWidget = class PromptFileAttachmentWidget extends Abstra
871
873
  const fileDirname = dirname(resource.path);
872
874
  const friendlyName = `${fileBasename} ${fileDirname}`;
873
875
  const isPrompt = attachment.id.startsWith(PromptFileVariableKind.PromptFile);
874
- const ariaLabel = isPrompt ? ( localize(5598, "Prompt file, {0}", friendlyName)) : ( localize(5599, "Instructions attachment, {0}", friendlyName));
875
- const typeLabel = isPrompt ? ( localize(5600, "Prompt")) : ( localize(5601, "Instructions"));
876
+ const ariaLabel = isPrompt ? ( localize(5702, "Prompt file, {0}", friendlyName)) : ( localize(5703, "Instructions attachment, {0}", friendlyName));
877
+ const typeLabel = isPrompt ? ( localize(5704, "Prompt")) : ( localize(5705, "Instructions"));
876
878
  const title = this.labelService.getUriLabel(resource) + (attachment.originLabel ? `\n${attachment.originLabel}` : "");
877
879
  this.element.classList.remove("warning", "error");
878
880
  const fileWithoutExtension = getCleanPromptName(resource);
@@ -932,8 +934,8 @@ let PromptTextAttachmentWidget = class PromptTextAttachmentWidget extends Abstra
932
934
  })
933
935
  );
934
936
  }
935
- this.label.setLabel(( localize(5602, "Additional Instructions")), undefined, undefined);
936
- this.element.ariaLabel = this.appendDeletionHint(( localize(5597, "Attached context, {0}", attachment.name)));
937
+ this.label.setLabel(( localize(5706, "Additional Instructions")), undefined, undefined);
938
+ this.element.ariaLabel = this.appendDeletionHint(( localize(5701, "Attached context, {0}", attachment.name)));
937
939
  this._register(hoverService.setupDelayedHover(this.element, {
938
940
  ...commonHoverOptions,
939
941
  content: attachment.value
@@ -980,18 +982,18 @@ let ToolSetOrToolItemAttachmentWidget = class ToolSetOrToolItemAttachmentWidget
980
982
  }
981
983
  this.label.setLabel(`$(${icon.id})\u00A0${name}`, undefined);
982
984
  this.element.style.cursor = "pointer";
983
- this.element.ariaLabel = this.appendDeletionHint(( localize(5597, "Attached context, {0}", name)));
985
+ this.element.ariaLabel = this.appendDeletionHint(( localize(5701, "Attached context, {0}", name)));
984
986
  let hoverContent;
985
987
  if (isToolSet(toolOrToolSet)) {
986
988
  hoverContent = ( localize(
987
- 5603,
989
+ 5707,
988
990
  "{0} - {1}",
989
991
  toolOrToolSet.description ?? toolOrToolSet.referenceName,
990
992
  toolOrToolSet.source.label
991
993
  ));
992
994
  } else if (toolOrToolSet) {
993
995
  hoverContent = ( localize(
994
- 5604,
996
+ 5708,
995
997
  "{0} - {1}",
996
998
  toolOrToolSet.userDescription ?? toolOrToolSet.modelDescription,
997
999
  toolOrToolSet.source.label
@@ -1064,7 +1066,7 @@ let NotebookCellOutputChatAttachmentWidget = class NotebookCellOutputChatAttachm
1064
1066
  this.addResourceOpenHandlers(resource, undefined);
1065
1067
  }
1066
1068
  getAriaLabel(attachment) {
1067
- return localize(5605, "Attached Notebook output, {0}", attachment.name);
1069
+ return localize(5709, "Attached Notebook output, {0}", attachment.name);
1068
1070
  }
1069
1071
  renderErrorOutput(resource, attachment) {
1070
1072
  const attachmentLabel = attachment.name;
@@ -1092,9 +1094,9 @@ let NotebookCellOutputChatAttachmentWidget = class NotebookCellOutputChatAttachm
1092
1094
  renderImageOutput(resource, attachment) {
1093
1095
  let ariaLabel;
1094
1096
  if (attachment.omittedState === OmittedState.Full) {
1095
- ariaLabel = ( localize(5606, "Omitted this Notebook ouput: {0}", attachment.name));
1097
+ ariaLabel = ( localize(5710, "Omitted this Notebook ouput: {0}", attachment.name));
1096
1098
  } else if (attachment.omittedState === OmittedState.Partial) {
1097
- ariaLabel = ( localize(5607, "Partially omitted this Notebook output: {0}", attachment.name));
1099
+ ariaLabel = ( localize(5711, "Partially omitted this Notebook output: {0}", attachment.name));
1098
1100
  } else {
1099
1101
  ariaLabel = this.getAriaLabel(attachment);
1100
1102
  }
@@ -1164,14 +1166,14 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
1164
1166
  );
1165
1167
  this.editorService = editorService;
1166
1168
  this.hoverService = hoverService;
1167
- const ariaLabel = ( localize(5608, "Attached element, {0}", attachment.name));
1169
+ const ariaLabel = ( localize(5712, "Attached element, {0}", attachment.name));
1168
1170
  this.element.ariaLabel = this.appendDeletionHint(ariaLabel);
1169
1171
  this.element.style.position = "relative";
1170
1172
  this.element.style.cursor = "pointer";
1171
1173
  const attachmentLabel = attachment.name;
1172
1174
  const withIcon = attachment.icon?.id ? `$(${attachment.icon.id})\u00A0${attachmentLabel}` : attachmentLabel;
1173
1175
  this.label.setLabel(withIcon, undefined, {
1174
- title: ( localize(5609, "Click to view the contents of: {0}", attachmentLabel))
1176
+ title: ( localize(5713, "Click to view the contents of: {0}", attachmentLabel))
1175
1177
  });
1176
1178
  this._register(this.hoverService.setupDelayedHover(
1177
1179
  this.element,
@@ -1191,7 +1193,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
1191
1193
  const innerScrollables = [];
1192
1194
  {
1193
1195
  const section = $("div.chat-element-hover-section");
1194
- const header = $("div.chat-element-hover-header", {}, ( localize(5610, "ELEMENT")));
1196
+ const header = $("div.chat-element-hover-header", {}, ( localize(5714, "ELEMENT")));
1195
1197
  section.appendChild(header);
1196
1198
  const elementPre = $("pre.chat-element-hover-code");
1197
1199
  const elementCode = $("code");
@@ -1209,7 +1211,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
1209
1211
  const computedStyleEntries = this.getComputedStyleEntriesForHover(attachment.computedStyles);
1210
1212
  if (computedStyleEntries.length > 0) {
1211
1213
  const section = $("div.chat-element-hover-section");
1212
- const header = $("div.chat-element-hover-header", {}, ( localize(5611, "KEY COMPUTED STYLES")));
1214
+ const header = $("div.chat-element-hover-header", {}, ( localize(5715, "KEY COMPUTED STYLES")));
1213
1215
  section.appendChild(header);
1214
1216
  const table = $("div.chat-element-hover-table");
1215
1217
  for (const [name, value] of computedStyleEntries) {
@@ -1228,7 +1230,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
1228
1230
  section.appendChild(table);
1229
1231
  const showMoreButton = $("button.chat-element-hover-show-more", {
1230
1232
  type: "button"
1231
- }, ( localize(5612, "Show More...")));
1233
+ }, ( localize(5716, "Show More...")));
1232
1234
  this._register(
1233
1235
  addDisposableListener(showMoreButton, EventType.CLICK, async e => {
1234
1236
  EventHelper.stop(e, true);
@@ -1240,7 +1242,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
1240
1242
  }
1241
1243
  if (attachment.ancestors && attachment.ancestors.length > 1) {
1242
1244
  const section = $("div.chat-element-hover-section");
1243
- const header = $("div.chat-element-hover-header", {}, ( localize(5613, "HTML PATH")));
1245
+ const header = $("div.chat-element-hover-header", {}, ( localize(5717, "HTML PATH")));
1244
1246
  section.appendChild(header);
1245
1247
  const lines = [];
1246
1248
  for (let i = 0; i < attachment.ancestors.length; i++) {
@@ -1263,7 +1265,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
1263
1265
  }
1264
1266
  if (attachment.attributes && ( Object.keys(attachment.attributes)).length > 0) {
1265
1267
  const section = $("div.chat-element-hover-section");
1266
- const header = $("div.chat-element-hover-header", {}, ( localize(5614, "ATTRIBUTES")));
1268
+ const header = $("div.chat-element-hover-header", {}, ( localize(5718, "ATTRIBUTES")));
1267
1269
  section.appendChild(header);
1268
1270
  const table = $("div.chat-element-hover-table");
1269
1271
  for (const [name, value] of Object.entries(attachment.attributes)) {
@@ -1277,7 +1279,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
1277
1279
  }
1278
1280
  if (attachment.dimensions) {
1279
1281
  const section = $("div.chat-element-hover-section");
1280
- const header = $("div.chat-element-hover-header", {}, ( localize(5615, "POSITION & SIZE")));
1282
+ const header = $("div.chat-element-hover-header", {}, ( localize(5719, "POSITION & SIZE")));
1281
1283
  section.appendChild(header);
1282
1284
  const table = $("div.chat-element-hover-table");
1283
1285
  const dims = [
@@ -1297,7 +1299,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
1297
1299
  }
1298
1300
  if (attachment.innerText) {
1299
1301
  const section = $("div.chat-element-hover-section");
1300
- const header = $("div.chat-element-hover-header", {}, ( localize(5616, "INNER TEXT")));
1302
+ const header = $("div.chat-element-hover-header", {}, ( localize(5720, "INNER TEXT")));
1301
1303
  section.appendChild(header);
1302
1304
  section.appendChild($("div.chat-element-hover-text", {}, attachment.innerText));
1303
1305
  scrollableContent.appendChild(section);
@@ -1443,7 +1445,7 @@ let SCMHistoryItemAttachmentWidget = class SCMHistoryItemAttachmentWidget extend
1443
1445
  );
1444
1446
  this.label.setLabel(attachment.name, undefined);
1445
1447
  this.element.style.cursor = "pointer";
1446
- this.element.ariaLabel = this.appendDeletionHint(( localize(5597, "Attached context, {0}", attachment.name)));
1448
+ this.element.ariaLabel = this.appendDeletionHint(( localize(5701, "Attached context, {0}", attachment.name)));
1447
1449
  const {
1448
1450
  content,
1449
1451
  disposables
@@ -1505,7 +1507,7 @@ let SCMHistoryItemChangeAttachmentWidget = class SCMHistoryItemChangeAttachmentW
1505
1507
  hidePath: true,
1506
1508
  nameSuffix
1507
1509
  });
1508
- this.element.ariaLabel = this.appendDeletionHint(( localize(5597, "Attached context, {0}", attachment.name)));
1510
+ this.element.ariaLabel = this.appendDeletionHint(( localize(5701, "Attached context, {0}", attachment.name)));
1509
1511
  const {
1510
1512
  content,
1511
1513
  disposables
@@ -1561,7 +1563,7 @@ let SCMHistoryItemChangeRangeAttachmentWidget = class SCMHistoryItemChangeRangeA
1561
1563
  hidePath: true,
1562
1564
  nameSuffix
1563
1565
  });
1564
- this.element.ariaLabel = this.appendDeletionHint(( localize(5597, "Attached context, {0}", attachment.name)));
1566
+ this.element.ariaLabel = this.appendDeletionHint(( localize(5701, "Attached context, {0}", attachment.name)));
1565
1567
  this.addResourceOpenHandlers(attachment.value, undefined);
1566
1568
  }
1567
1569
  async openResource(resource, options, isDirectory, range) {
@@ -1585,6 +1587,113 @@ let SCMHistoryItemChangeRangeAttachmentWidget = class SCMHistoryItemChangeRangeA
1585
1587
  }
1586
1588
  };
1587
1589
  SCMHistoryItemChangeRangeAttachmentWidget = ( __decorate([( __param(5, ICommandService)), ( __param(6, IOpenerService)), ( __param(7, IConfigurationService)), ( __param(8, IEditorService))], SCMHistoryItemChangeRangeAttachmentWidget));
1590
+ let BrowserViewAttachmentWidget = class BrowserViewAttachmentWidget extends AbstractChatAttachmentWidget {
1591
+ constructor(
1592
+ _attachment,
1593
+ currentLanguageModel,
1594
+ _options,
1595
+ container,
1596
+ contextResourceLabels,
1597
+ commandService,
1598
+ openerService,
1599
+ configurationService,
1600
+ _browserViewService,
1601
+ _hoverService,
1602
+ _editorService,
1603
+ _instantiationService
1604
+ ) {
1605
+ super(
1606
+ _attachment,
1607
+ _options,
1608
+ container,
1609
+ contextResourceLabels,
1610
+ currentLanguageModel,
1611
+ commandService,
1612
+ openerService,
1613
+ configurationService
1614
+ );
1615
+ this._attachment = _attachment;
1616
+ this._options = _options;
1617
+ this._browserViewService = _browserViewService;
1618
+ this._hoverService = _hoverService;
1619
+ this._editorService = _editorService;
1620
+ this._instantiationService = _instantiationService;
1621
+ this._inputListeners = this._register(( new DisposableStore()));
1622
+ this._resolveInput();
1623
+ this._register(
1624
+ this._browserViewService.onDidChangeBrowserViews(() => this._resolveInput())
1625
+ );
1626
+ this._register(
1627
+ this._browserViewService.onDidChangeSharingAvailable(() => this._updateLabel())
1628
+ );
1629
+ this._register(this._hoverService.setupDelayedHover(this.element, () => ({
1630
+ ...commonHoverOptions,
1631
+ content: this._input ? {
1632
+ [BrowserViewSharingState.Shared]: this._input.getTitle() ?? "",
1633
+ [BrowserViewSharingState.NotShared]: ( localize(5721, "This browser page is not shared with the agent.")),
1634
+ [BrowserViewSharingState.Unavailable]: ( localize(5722, "Browser tools are not enabled."))
1635
+ }[this._input.model?.sharingState ?? BrowserViewSharingState.Shared] : ( localize(5723, "This browser page is no longer open."))
1636
+ }), commonHoverLifecycleOptions));
1637
+ this._instantiationService.invokeFunction(accessor => {
1638
+ this._register(
1639
+ hookUpResourceAttachmentDragAndContextMenu(accessor, this.element, _attachment.value)
1640
+ );
1641
+ });
1642
+ this.addResourceOpenHandlers(_attachment.value, undefined);
1643
+ }
1644
+ _resolveInput() {
1645
+ const input = this._browserViewService.getKnownBrowserViews().get(this._attachment.browserId);
1646
+ if (this._input === input) {
1647
+ return;
1648
+ }
1649
+ this._inputListeners.clear();
1650
+ this._input = input;
1651
+ if (input) {
1652
+ this._inputListeners.add(input.onWillDispose(() => {
1653
+ this._input = undefined;
1654
+ this._inputListeners.clear();
1655
+ this._updateLabel();
1656
+ }));
1657
+ if (this._options.supportsDeletion) {
1658
+ this._inputListeners.add(input.onDidChangeLabel(() => this._updateLabel()));
1659
+ }
1660
+ if (input.model) {
1661
+ this._inputListeners.add(input.model.onDidChangeSharingState(() => this._updateLabel()));
1662
+ } else {
1663
+ this._inputListeners.add(input.onDidResolveModel(() => {
1664
+ this._inputListeners.add(input.model.onDidChangeSharingState(() => this._updateLabel()));
1665
+ this._updateLabel();
1666
+ }));
1667
+ }
1668
+ }
1669
+ this._updateLabel();
1670
+ }
1671
+ _updateLabel() {
1672
+ const name = this._input?.getName() ?? this._attachment.name;
1673
+ const sharingState = this._input?.model?.sharingState ?? BrowserViewSharingState.Shared;
1674
+ const isAvailable = !!this._input && sharingState === BrowserViewSharingState.Shared;
1675
+ this.element.classList.toggle("warning", !isAvailable);
1676
+ this.label.setLabel(name, undefined, {
1677
+ iconPath: Codicon.globe,
1678
+ strikethrough: !isAvailable
1679
+ });
1680
+ this.element.ariaLabel = this.appendDeletionHint(this._input ? {
1681
+ [BrowserViewSharingState.Shared]: ( localize(5724, "Attached browser page, {0}", name)),
1682
+ [BrowserViewSharingState.NotShared]: ( localize(5725, "Browser page not shared with agent, {0}", name)),
1683
+ [BrowserViewSharingState.Unavailable]: ( localize(5726, "Browser tools are not enabled, {0}", name))
1684
+ }[sharingState] : ( localize(5727, "Browser page unavailable, {0}", name)));
1685
+ }
1686
+ async openResource(_resource, options, _isDirectory, _range) {
1687
+ if (this._input) {
1688
+ await this._editorService.openEditor(
1689
+ this._input,
1690
+ options.editorOptions,
1691
+ options.openToSide ? SIDE_GROUP : undefined
1692
+ );
1693
+ }
1694
+ }
1695
+ };
1696
+ BrowserViewAttachmentWidget = ( __decorate([( __param(5, ICommandService)), ( __param(6, IOpenerService)), ( __param(7, IConfigurationService)), ( __param(8, IBrowserViewWorkbenchService)), ( __param(9, IHoverService)), ( __param(10, IEditorService)), ( __param(11, IInstantiationService))], BrowserViewAttachmentWidget));
1588
1697
  function hookUpResourceAttachmentDragAndContextMenu(accessor, widget, resource) {
1589
1698
  const contextKeyService = accessor.get(IContextKeyService);
1590
1699
  const instantiationService = accessor.get(IInstantiationService);
@@ -1723,9 +1832,9 @@ function addBasicContextMenu(accessor, widget, scopedContextKeyService, menuId,
1723
1832
  const chatAttachmentResourceContextKey = ( new RawContextKey("chatAttachmentResource", undefined, {
1724
1833
  type: "URI",
1725
1834
  description: ( localize(
1726
- 5617,
1835
+ 5728,
1727
1836
  "The full value of the chat attachment resource, including scheme and path"
1728
1837
  ))
1729
1838
  }));
1730
1839
 
1731
- export { DefaultChatAttachmentWidget, ElementChatAttachmentWidget, FileAttachmentWidget, ImageAttachmentWidget, NotebookCellOutputChatAttachmentWidget, PasteAttachmentWidget, PromptFileAttachmentWidget, PromptTextAttachmentWidget, SCMHistoryItemAttachmentWidget, SCMHistoryItemChangeAttachmentWidget, SCMHistoryItemChangeRangeAttachmentWidget, TerminalCommandAttachmentWidget, ToolSetOrToolItemAttachmentWidget, chatAttachmentResourceContextKey, hookUpResourceAttachmentDragAndContextMenu, hookUpSymbolAttachmentDragAndContextMenu };
1840
+ export { BrowserViewAttachmentWidget, DefaultChatAttachmentWidget, ElementChatAttachmentWidget, FileAttachmentWidget, ImageAttachmentWidget, NotebookCellOutputChatAttachmentWidget, PasteAttachmentWidget, PromptFileAttachmentWidget, PromptTextAttachmentWidget, SCMHistoryItemAttachmentWidget, SCMHistoryItemChangeAttachmentWidget, SCMHistoryItemChangeRangeAttachmentWidget, TerminalCommandAttachmentWidget, ToolSetOrToolItemAttachmentWidget, chatAttachmentResourceContextKey, hookUpResourceAttachmentDragAndContextMenu, hookUpSymbolAttachmentDragAndContextMenu };
@@ -28,6 +28,7 @@ export declare class ChatImplicitContextContribution extends Disposable implemen
28
28
  constructor(codeEditorService: ICodeEditorService, editorService: IEditorService, chatWidgetService: IChatWidgetService, chatService: IChatService, chatEditingService: IChatEditingService, configurationService: IConfigurationService, ignoredFilesService: ILanguageModelIgnoredFilesService, chatContextService: IChatContextService);
29
29
  private findActiveCodeEditor;
30
30
  private findActiveWebviewEditor;
31
+ private findActiveBrowserEditor;
31
32
  private findActiveNotebookEditor;
32
33
  private updateImplicitContext;
33
34
  }
@@ -22,6 +22,7 @@ import { ChatAgentLocation } from '@codingame/monaco-vscode-api/vscode/vs/workbe
22
22
  import { ILanguageModelIgnoredFilesService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/ignoredFiles.service';
23
23
  import { IChatWidgetService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chat.service';
24
24
  import { IChatContextService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/contextContrib/chatContextService.service';
25
+ import { BrowserEditorInput } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/browserView/common/browserEditorInput';
25
26
  import { autorun } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/reactions/autorun';
26
27
 
27
28
  let ChatImplicitContextContribution = class ChatImplicitContextContribution extends Disposable {
@@ -148,6 +149,13 @@ let ChatImplicitContextContribution = class ChatImplicitContextContribution exte
148
149
  }
149
150
  return undefined;
150
151
  }
152
+ findActiveBrowserEditor() {
153
+ const activeEditorPane = this.editorService.activeEditorPane;
154
+ if (activeEditorPane?.input instanceof BrowserEditorInput) {
155
+ return activeEditorPane.input;
156
+ }
157
+ return undefined;
158
+ }
151
159
  findActiveNotebookEditor() {
152
160
  return getNotebookEditorFromEditorPane(this.editorService.activeEditorPane);
153
161
  }
@@ -156,6 +164,7 @@ let ChatImplicitContextContribution = class ChatImplicitContextContribution exte
156
164
  const codeEditor = this.findActiveCodeEditor();
157
165
  const model = codeEditor?.getModel();
158
166
  const selection = codeEditor?.getSelection();
167
+ const useSuggestedContext = this.configurationService.getValue("chat.implicitContext.suggestedContext");
159
168
  let newValue;
160
169
  let isSelection = false;
161
170
  let languageId;
@@ -169,7 +178,7 @@ let ChatImplicitContextContribution = class ChatImplicitContextContribution exte
169
178
  };
170
179
  isSelection = true;
171
180
  } else {
172
- if (this.configurationService.getValue("chat.implicitContext.suggestedContext")) {
181
+ if (useSuggestedContext) {
173
182
  newValue = model.uri;
174
183
  } else {
175
184
  const visibleRanges = codeEditor?.getVisibleRanges();
@@ -231,6 +240,10 @@ let ChatImplicitContextContribution = class ChatImplicitContextContribution exte
231
240
  newValue = webviewContext;
232
241
  }
233
242
  }
243
+ const browser = this.findActiveBrowserEditor();
244
+ if (browser?.isSharingAvailable && useSuggestedContext) {
245
+ newValue = browser.resource;
246
+ }
234
247
  const uri = newValue instanceof URI ? newValue : (isStringImplicitContextValue(newValue) ? undefined : newValue?.uri);
235
248
  if (uri && ((await this.ignoredFilesService.fileIsIgnored(uri, cancelTokenSource.token)) || uri.path.endsWith(".copilotmd"))) {
236
249
  newValue = undefined;
@@ -365,6 +378,9 @@ class ChatImplicitContext extends Disposable {
365
378
  }
366
379
  get name() {
367
380
  if (URI.isUri(this.value)) {
381
+ if (this.value.scheme === Schemas.vscodeBrowser) {
382
+ return `browser`;
383
+ }
368
384
  return `file:${basename(this.value)}`;
369
385
  }
370
386
  if (isLocation(this.value)) {
@@ -432,6 +448,9 @@ class ChatImplicitContext extends Disposable {
432
448
  if (!this.value) {
433
449
  return [];
434
450
  }
451
+ if (URI.isUri(this.value) && this.value.scheme === Schemas.vscodeBrowser) {
452
+ return [];
453
+ }
435
454
  if (isStringImplicitContextValue(this.value)) {
436
455
  return [{
437
456
  kind: "string",
@@ -15,6 +15,7 @@ import { ChatAttachmentModel } from "./chatAttachmentModel.js";
15
15
  import { IChatContextService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/contextContrib/chatContextService.service";
16
16
  import { ChatImplicitContexts } from "./chatImplicitContext.js";
17
17
  import { IRange } from "@codingame/monaco-vscode-api/vscode/vs/editor/common/core/range";
18
+ import { IBrowserViewWorkbenchService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/browserView/common/browserView.service";
18
19
  export declare class ImplicitContextAttachmentWidget extends Disposable {
19
20
  private readonly widgetRef;
20
21
  private readonly isAttachmentAlreadyAttached;
@@ -32,14 +33,16 @@ export declare class ImplicitContextAttachmentWidget extends Disposable {
32
33
  private readonly hoverService;
33
34
  private readonly configService;
34
35
  private readonly chatContextService;
36
+ private readonly browserViewService;
35
37
  private readonly renderDisposables;
36
38
  private renderedCount;
37
- constructor(widgetRef: () => IChatWidget | undefined, isAttachmentAlreadyAttached: (targetUri: URI | undefined, targetRange: IRange | undefined, targetHandle: number | undefined) => boolean, attachment: ChatImplicitContexts, resourceLabels: ResourceLabels, attachmentModel: ChatAttachmentModel, domNode: HTMLElement, contextKeyService: IContextKeyService, contextMenuService: IContextMenuService, labelService: ILabelService, menuService: IMenuService, fileService: IFileService, languageService: ILanguageService, modelService: IModelService, hoverService: IHoverService, configService: IConfigurationService, chatContextService: IChatContextService);
39
+ constructor(widgetRef: () => IChatWidget | undefined, isAttachmentAlreadyAttached: (targetUri: URI | undefined, targetRange: IRange | undefined, targetHandle: number | undefined) => boolean, attachment: ChatImplicitContexts, resourceLabels: ResourceLabels, attachmentModel: ChatAttachmentModel, domNode: HTMLElement, contextKeyService: IContextKeyService, contextMenuService: IContextMenuService, labelService: ILabelService, menuService: IMenuService, fileService: IFileService, languageService: ILanguageService, modelService: IModelService, hoverService: IHoverService, configService: IConfigurationService, chatContextService: IChatContextService, browserViewService: IBrowserViewWorkbenchService);
38
40
  private render;
39
41
  get hasRenderedContexts(): boolean;
40
42
  private renderMainContext;
41
43
  private renderString;
42
44
  private renderResource;
45
+ private renderBrowserResource;
43
46
  private convertToRegularAttachment;
44
47
  private pinSelection;
45
48
  }