@codingame/monaco-vscode-katex-common 32.0.2 → 33.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +2 -2
- package/vscode/src/vs/platform/actions/browser/buttonbar.js +2 -2
- package/vscode/src/vs/platform/agentHost/common/claudeSessionConfigKeys.d.ts +30 -0
- package/vscode/src/vs/platform/agentHost/common/claudeSessionConfigKeys.js +8 -0
- package/vscode/src/vs/platform/agentHost/common/sessionConfigKeys.d.ts +32 -0
- package/vscode/src/vs/platform/agentHost/common/sessionConfigKeys.js +13 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/accessibility/chatAccessibilityProvider.js +16 -16
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContinueInAction.js +9 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatElicitationActions.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatExecuteActions.js +56 -36
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatTitleActions.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolActions.js +11 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatToolPicker.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostChatInputPicker.contribution.d.ts +45 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostChatInputPicker.contribution.js +114 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostChatInputPicker.d.ts +87 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostChatInputPicker.js +502 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostGenericConfigChips.d.ts +45 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/agentHostGenericConfigChips.js +188 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentHost/media/agentHostChatInputPicker.css +153 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionHoverWidget.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter.js +9 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsOpener.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer.js +30 -30
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/chatAttachmentWidgets.js +52 -52
- package/vscode/src/vs/workbench/contrib/chat/browser/attachments/implicitContextAttachment.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/chatEditing/chatEditingActions.js +34 -34
- package/vscode/src/vs/workbench/contrib/chat/browser/chatSessions/chatSessionPickerActionItem.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/chatToolRiskAssessmentService.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/tools/toolSetsContribution.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatAgentHover.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatArtifactsWidget.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentMarkdownRenderer.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentMarkdownRenderer.js +23 -20
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAgentCommandContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatAnonymousRateLimitedPart.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatChangesSummaryPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCodeCitationContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatCommandContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationContentPart.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationWidget.d.ts +13 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatConfirmationWidget.js +40 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatDisabledClaudeHooksContentPart.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatExtensionsContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatHookContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatInlineAnchorWidget.js +13 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMarkdownContentPart.d.ts +4 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMarkdownContentPart.js +217 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMcpServersInteractionContentPart.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatMultiDiffContentPart.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatPlanReviewPart.js +30 -30
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatProgressContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuestionCarouselPart.js +44 -44
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatQuotaExceededPart.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatReferencesContentPart.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatResourceGroupWidget.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSubagentContentPart.js +10 -10
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatSuggestNextWidget.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTextEditContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatThinkingContentPart.d.ts +2 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatThinkingContentPart.js +36 -23
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTipContentPart.js +12 -9
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTodoListWidget.js +17 -17
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolInputOutputContentPart.d.ts +1 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatToolInputOutputContentPart.js +8 -13
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatTreeContentPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/chatWorkspaceEditContentPart.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/codeBlockPart.js +14 -14
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/media/chatTerminalToolProgressPart.css +16 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/abstractToolConfirmationSubPart.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatExtensionsInstallToolSubPart.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppModel.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMcpAppSubPart.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatMissingSandboxDepsConfirmationSubPart.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatModifiedFilesConfirmationSubPart.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolConfirmationSubPart.js +24 -21
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolProgressPart.d.ts +6 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatTerminalToolProgressPart.js +72 -23
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolConfirmationCarouselPart.js +8 -8
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolConfirmationSubPart.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolOutputPart.d.ts +2 -4
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolOutputPart.js +7 -22
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPartUtilities.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolPostExecuteConfirmationPart.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/chatToolProgressPart.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/media/toolRiskBadge.css +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/toolRiskBadgeWidget.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatContentParts/toolInvocationParts/toolRiskBadgeWidget.js +25 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatDragAndDrop.js +11 -11
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.d.ts +9 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatListRenderer.js +41 -27
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/chatWidget.js +31 -25
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatFollowups.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputNotificationWidget.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPart.d.ts +4 -0
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatInputPart.js +89 -27
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelPicker.d.ts +4 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelPicker.js +203 -107
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelSelectionLogic.d.ts +6 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatModelSelectionLogic.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/chatPhoneInputPresenter.js +2 -2
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/delegationSessionPickerActionItem.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modePickerActionItem.js +5 -5
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/modelPickerActionItem.js +1 -1
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/permissionPickerActionItem.js +18 -18
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/sessionTargetPickerActionItem.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/workspacePickerActionItem.js +3 -3
- package/vscode/src/vs/workbench/contrib/chat/browser/widget/media/chat.css +32 -81
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageDetails.js +7 -7
- package/vscode/src/vs/workbench/contrib/chat/browser/widgetHosts/viewPane/chatContextUsageWidget.js +4 -4
- package/vscode/src/vs/workbench/contrib/chat/common/chatImageExtraction.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/common/chatPermissionWarnings.js +6 -6
- package/vscode/src/vs/workbench/contrib/chat/common/widget/chatColors.js +18 -18
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatController.js +3 -3
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatWidget.js +5 -5
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/inlineChatZoneWidget.js +1 -1
- package/vscode/src/vs/workbench/contrib/inlineChat/browser/media/inlineChat.css +2 -2
- package/vscode/src/vs/workbench/contrib/inlineChat/common/inlineChat.js +30 -30
- package/vscode/src/vs/workbench/contrib/interactive/browser/replInputHintContentWidget.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/cellStatusBar/executionStatusBarItemController.js +7 -7
- package/vscode/src/vs/workbench/contrib/notebook/browser/contrib/find/notebookFindWidget.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/cellOperations.js +2 -2
- package/vscode/src/vs/workbench/contrib/notebook/browser/controller/insertCellActions.js +24 -24
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffComponents.js +3 -3
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/diffElementOutputs.js +7 -7
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditor.js +1 -1
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffEditorBrowser.js +5 -5
- package/vscode/src/vs/workbench/contrib/notebook/browser/diff/notebookDiffList.js +1 -1
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditor.js +1 -1
- package/vscode/src/vs/workbench/contrib/replNotebook/browser/replEditorInput.js +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/runInTerminalHelpers.js +6 -6
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/toolTerminalCreator.js +4 -0
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/autoApprove/npmScriptAutoApprover.js +1 -1
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineAutoApproveAnalyzer.js +12 -12
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/commandLineAnalyzer/commandLineFileWriteAnalyzer.js +4 -4
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.d.ts +29 -7
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/monitoring/outputMonitor.js +27 -8
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.d.ts +17 -8
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/browser/tools/runInTerminalTool.js +150 -69
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxService.d.ts +1 -2
- package/vscode/src/vs/workbench/contrib/terminalContrib/chatAgentTools/common/terminalSandboxService.js +9 -14
|
@@ -142,7 +142,7 @@ let AbstractChatAttachmentWidget = class AbstractChatAttachmentWidget extends Di
|
|
|
142
142
|
if (!this._hasClearButton) {
|
|
143
143
|
return ariaLabel;
|
|
144
144
|
}
|
|
145
|
-
return localize(
|
|
145
|
+
return localize(5742, "{0} (Delete)", ariaLabel);
|
|
146
146
|
}
|
|
147
147
|
attachClearButton() {
|
|
148
148
|
if (this.attachment.range || !this.options.supportsDeletion) {
|
|
@@ -152,7 +152,7 @@ let AbstractChatAttachmentWidget = class AbstractChatAttachmentWidget extends Di
|
|
|
152
152
|
const clearButton = ( new Button(this.element, {
|
|
153
153
|
supportIcons: true,
|
|
154
154
|
hoverDelegate: createInstantHoverDelegate(),
|
|
155
|
-
title: ( localize(
|
|
155
|
+
title: ( localize(5743, "Remove from context"))
|
|
156
156
|
}));
|
|
157
157
|
clearButton.element.tabIndex = -1;
|
|
158
158
|
clearButton.icon = Codicon.close;
|
|
@@ -245,14 +245,14 @@ let FileAttachmentWidget = class FileAttachmentWidget extends AbstractChatAttach
|
|
|
245
245
|
const fileDirname = dirname(resource.path);
|
|
246
246
|
const friendlyName = `${fileBasename} ${fileDirname}`;
|
|
247
247
|
let ariaLabel = range ? ( localize(
|
|
248
|
-
|
|
248
|
+
5744,
|
|
249
249
|
"Attached file, {0}, line {1} to line {2}",
|
|
250
250
|
friendlyName,
|
|
251
251
|
range.startLineNumber,
|
|
252
252
|
range.endLineNumber
|
|
253
|
-
)) : ( localize(
|
|
253
|
+
)) : ( localize(5745, "Attached file, {0}", friendlyName));
|
|
254
254
|
if (attachment.omittedState === OmittedState.Full) {
|
|
255
|
-
ariaLabel = ( localize(
|
|
255
|
+
ariaLabel = ( localize(5746, "Omitted this file: {0}", attachment.name));
|
|
256
256
|
this.renderOmittedWarning(friendlyName, ariaLabel);
|
|
257
257
|
} else {
|
|
258
258
|
const fileOptions = {
|
|
@@ -296,7 +296,7 @@ let FileAttachmentWidget = class FileAttachmentWidget extends AbstractChatAttach
|
|
|
296
296
|
hoverElement.setAttribute("aria-label", ariaLabel);
|
|
297
297
|
this.element.classList.add("warning");
|
|
298
298
|
hoverElement.textContent = ( localize(
|
|
299
|
-
|
|
299
|
+
5747,
|
|
300
300
|
"{0} does not support this file type.",
|
|
301
301
|
this.currentLanguageModel ? this.languageModelsService.lookupLanguageModel(this.currentLanguageModel.identifier)?.name : this.currentLanguageModel ?? "This model"
|
|
302
302
|
));
|
|
@@ -309,7 +309,7 @@ let FileAttachmentWidget = class FileAttachmentWidget extends AbstractChatAttach
|
|
|
309
309
|
this.element.classList.add("warning");
|
|
310
310
|
const hoverElement = $("div.chat-attached-context-hover");
|
|
311
311
|
hoverElement.textContent = ( localize(
|
|
312
|
-
|
|
312
|
+
5748,
|
|
313
313
|
"This folder contains {0} images, which exceeds the maximum of {1} images per request. Older images will not be sent.",
|
|
314
314
|
imageCount,
|
|
315
315
|
limit
|
|
@@ -347,7 +347,7 @@ let TerminalCommandAttachmentWidget = class TerminalCommandAttachmentWidget exte
|
|
|
347
347
|
);
|
|
348
348
|
this.hoverService = hoverService;
|
|
349
349
|
this.terminalService = terminalService;
|
|
350
|
-
const ariaLabel = ( localize(
|
|
350
|
+
const ariaLabel = ( localize(5749, "Terminal command, {0}", attachment.command));
|
|
351
351
|
const clickHandler = () => this.openResource(attachment.resource, {
|
|
352
352
|
editorOptions: {
|
|
353
353
|
preserveFocus: true
|
|
@@ -401,16 +401,16 @@ function getHoverContent(ariaLabel, attachment) {
|
|
|
401
401
|
const hoverElement = $("div.chat-attached-context-hover");
|
|
402
402
|
hoverElement.setAttribute("aria-label", ariaLabel);
|
|
403
403
|
const commandTitle = $("div", {}, typeof attachment.exitCode === "number" ? ( localize(
|
|
404
|
-
|
|
404
|
+
5750,
|
|
405
405
|
"Command: {0}, exit code: {1}",
|
|
406
406
|
attachment.command,
|
|
407
407
|
attachment.exitCode
|
|
408
|
-
)) : ( localize(
|
|
408
|
+
)) : ( localize(5751, "Command")));
|
|
409
409
|
commandTitle.classList.add("attachment-additional-info");
|
|
410
410
|
const commandBlock = $("pre.chat-terminal-command-block");
|
|
411
411
|
hoverElement.append(commandTitle, commandBlock);
|
|
412
412
|
if (attachment.output && attachment.output.trim().length > 0) {
|
|
413
|
-
const outputTitle = $("div", {}, ( localize(
|
|
413
|
+
const outputTitle = $("div", {}, ( localize(5752, "Output:")));
|
|
414
414
|
outputTitle.classList.add("attachment-additional-info");
|
|
415
415
|
const outputBlock = $("pre.chat-terminal-command-output");
|
|
416
416
|
const fullOutputLines = attachment.output.split("\n");
|
|
@@ -474,13 +474,13 @@ let ImageAttachmentWidget = class ImageAttachmentWidget extends AbstractChatAtta
|
|
|
474
474
|
this.chatImageCarouselService = chatImageCarouselService;
|
|
475
475
|
let ariaLabel;
|
|
476
476
|
if (attachment.omittedState === OmittedState.Full) {
|
|
477
|
-
ariaLabel = ( localize(
|
|
477
|
+
ariaLabel = ( localize(5753, "Omitted this image: {0}", attachment.name));
|
|
478
478
|
} else if (attachment.omittedState === OmittedState.Partial) {
|
|
479
|
-
ariaLabel = ( localize(
|
|
479
|
+
ariaLabel = ( localize(5754, "Partially omitted this image: {0}", attachment.name));
|
|
480
480
|
} else if (attachment.omittedState === OmittedState.ImageLimitExceeded) {
|
|
481
|
-
ariaLabel = ( localize(
|
|
481
|
+
ariaLabel = ( localize(5755, "Image not sent due to limit: {0}", attachment.name));
|
|
482
482
|
} else {
|
|
483
|
-
ariaLabel = ( localize(
|
|
483
|
+
ariaLabel = ( localize(5756, "Attached image, {0}", attachment.name));
|
|
484
484
|
}
|
|
485
485
|
const ref = attachment.references?.[0]?.reference;
|
|
486
486
|
resource = ref && URI.isUri(ref) ? ref : undefined;
|
|
@@ -571,7 +571,7 @@ function createImageElements(
|
|
|
571
571
|
hoverElement.setAttribute("aria-label", ariaLabel);
|
|
572
572
|
if (previewFeaturesDisabled) {
|
|
573
573
|
element.classList.add("warning");
|
|
574
|
-
hoverElement.textContent = ( localize(
|
|
574
|
+
hoverElement.textContent = ( localize(5757, "Vision is disabled by your organization."));
|
|
575
575
|
disposable.add(hoverService.setupDelayedHover(element, {
|
|
576
576
|
content: hoverElement,
|
|
577
577
|
style: HoverStyle.Pointer
|
|
@@ -579,7 +579,7 @@ function createImageElements(
|
|
|
579
579
|
} else if ((!supportsVision && currentLanguageModel) || omittedState === OmittedState.Full) {
|
|
580
580
|
element.classList.add("warning");
|
|
581
581
|
hoverElement.textContent = ( localize(
|
|
582
|
-
|
|
582
|
+
5758,
|
|
583
583
|
"{0} does not support images.",
|
|
584
584
|
currentLanguageModelName ?? "This model"
|
|
585
585
|
));
|
|
@@ -591,11 +591,11 @@ function createImageElements(
|
|
|
591
591
|
element.classList.add("warning");
|
|
592
592
|
const maxImagesPerRequest = getImageAttachmentLimit(currentLanguageModel?.metadata);
|
|
593
593
|
hoverElement.textContent = maxImagesPerRequest !== undefined ? ( localize(
|
|
594
|
-
|
|
594
|
+
5759,
|
|
595
595
|
"This image was not sent because the maximum of {0} images per request was exceeded.",
|
|
596
596
|
maxImagesPerRequest
|
|
597
597
|
)) : ( localize(
|
|
598
|
-
|
|
598
|
+
5760,
|
|
599
599
|
"This image was not sent because this model's image limit was exceeded."
|
|
600
600
|
));
|
|
601
601
|
disposable.add(hoverService.setupDelayedHover(element, {
|
|
@@ -630,7 +630,7 @@ function createImageElements(
|
|
|
630
630
|
const urlContainer = $(
|
|
631
631
|
"a.chat-attached-context-url",
|
|
632
632
|
{},
|
|
633
|
-
omittedState === OmittedState.Partial ? ( localize(
|
|
633
|
+
omittedState === OmittedState.Partial ? ( localize(5761, "This GIF was partially omitted - current frame will be sent.")) : fullName
|
|
634
634
|
);
|
|
635
635
|
const separator = $("div.chat-attached-context-url-separator");
|
|
636
636
|
disposable.add(addDisposableListener(urlContainer, "click", () => clickHandler()));
|
|
@@ -679,7 +679,7 @@ let PasteAttachmentWidget = class PasteAttachmentWidget extends AbstractChatAtta
|
|
|
679
679
|
);
|
|
680
680
|
this.hoverService = hoverService;
|
|
681
681
|
this.instantiationService = instantiationService;
|
|
682
|
-
const ariaLabel = ( localize(
|
|
682
|
+
const ariaLabel = ( localize(5762, "Attached context, {0}", attachment.name));
|
|
683
683
|
this.element.ariaLabel = this.appendDeletionHint(ariaLabel);
|
|
684
684
|
const classNames = ["file-icon", `${attachment.language}-lang-file-icon`];
|
|
685
685
|
let resource;
|
|
@@ -772,7 +772,7 @@ let DefaultChatAttachmentWidget = class DefaultChatAttachmentWidget extends Abst
|
|
|
772
772
|
const withIcon = attachment.icon?.id ? `$(${attachment.icon.id})\u00A0${attachmentLabel}` : attachmentLabel;
|
|
773
773
|
this.label.setLabel(withIcon, correspondingContentReference?.options?.status?.description);
|
|
774
774
|
}
|
|
775
|
-
this.element.ariaLabel = this.appendDeletionHint(( localize(
|
|
775
|
+
this.element.ariaLabel = this.appendDeletionHint(( localize(5762, "Attached context, {0}", attachment.name)));
|
|
776
776
|
if (attachment.kind === "diagnostic") {
|
|
777
777
|
if (attachment.filterUri) {
|
|
778
778
|
resource = attachment.filterUri ? URI.revive(attachment.filterUri) : undefined;
|
|
@@ -873,8 +873,8 @@ let PromptFileAttachmentWidget = class PromptFileAttachmentWidget extends Abstra
|
|
|
873
873
|
const fileDirname = dirname(resource.path);
|
|
874
874
|
const friendlyName = `${fileBasename} ${fileDirname}`;
|
|
875
875
|
const isPrompt = attachment.id.startsWith(PromptFileVariableKind.PromptFile);
|
|
876
|
-
const ariaLabel = isPrompt ? ( localize(
|
|
877
|
-
const typeLabel = isPrompt ? ( localize(
|
|
876
|
+
const ariaLabel = isPrompt ? ( localize(5763, "Prompt file, {0}", friendlyName)) : ( localize(5764, "Instructions attachment, {0}", friendlyName));
|
|
877
|
+
const typeLabel = isPrompt ? ( localize(5765, "Prompt")) : ( localize(5766, "Instructions"));
|
|
878
878
|
const title = this.labelService.getUriLabel(resource) + (attachment.originLabel ? `\n${attachment.originLabel}` : "");
|
|
879
879
|
this.element.classList.remove("warning", "error");
|
|
880
880
|
const fileWithoutExtension = getCleanPromptName(resource);
|
|
@@ -934,8 +934,8 @@ let PromptTextAttachmentWidget = class PromptTextAttachmentWidget extends Abstra
|
|
|
934
934
|
})
|
|
935
935
|
);
|
|
936
936
|
}
|
|
937
|
-
this.label.setLabel(( localize(
|
|
938
|
-
this.element.ariaLabel = this.appendDeletionHint(( localize(
|
|
937
|
+
this.label.setLabel(( localize(5767, "Additional Instructions")), undefined, undefined);
|
|
938
|
+
this.element.ariaLabel = this.appendDeletionHint(( localize(5762, "Attached context, {0}", attachment.name)));
|
|
939
939
|
this._register(hoverService.setupDelayedHover(this.element, {
|
|
940
940
|
...commonHoverOptions,
|
|
941
941
|
content: attachment.value
|
|
@@ -982,18 +982,18 @@ let ToolSetOrToolItemAttachmentWidget = class ToolSetOrToolItemAttachmentWidget
|
|
|
982
982
|
}
|
|
983
983
|
this.label.setLabel(`$(${icon.id})\u00A0${name}`, undefined);
|
|
984
984
|
this.element.style.cursor = "pointer";
|
|
985
|
-
this.element.ariaLabel = this.appendDeletionHint(( localize(
|
|
985
|
+
this.element.ariaLabel = this.appendDeletionHint(( localize(5762, "Attached context, {0}", name)));
|
|
986
986
|
let hoverContent;
|
|
987
987
|
if (isToolSet(toolOrToolSet)) {
|
|
988
988
|
hoverContent = ( localize(
|
|
989
|
-
|
|
989
|
+
5768,
|
|
990
990
|
"{0} - {1}",
|
|
991
991
|
toolOrToolSet.description ?? toolOrToolSet.referenceName,
|
|
992
992
|
toolOrToolSet.source.label
|
|
993
993
|
));
|
|
994
994
|
} else if (toolOrToolSet) {
|
|
995
995
|
hoverContent = ( localize(
|
|
996
|
-
|
|
996
|
+
5769,
|
|
997
997
|
"{0} - {1}",
|
|
998
998
|
toolOrToolSet.userDescription ?? toolOrToolSet.modelDescription,
|
|
999
999
|
toolOrToolSet.source.label
|
|
@@ -1066,7 +1066,7 @@ let NotebookCellOutputChatAttachmentWidget = class NotebookCellOutputChatAttachm
|
|
|
1066
1066
|
this.addResourceOpenHandlers(resource, undefined);
|
|
1067
1067
|
}
|
|
1068
1068
|
getAriaLabel(attachment) {
|
|
1069
|
-
return localize(
|
|
1069
|
+
return localize(5770, "Attached Notebook output, {0}", attachment.name);
|
|
1070
1070
|
}
|
|
1071
1071
|
renderErrorOutput(resource, attachment) {
|
|
1072
1072
|
const attachmentLabel = attachment.name;
|
|
@@ -1094,9 +1094,9 @@ let NotebookCellOutputChatAttachmentWidget = class NotebookCellOutputChatAttachm
|
|
|
1094
1094
|
renderImageOutput(resource, attachment) {
|
|
1095
1095
|
let ariaLabel;
|
|
1096
1096
|
if (attachment.omittedState === OmittedState.Full) {
|
|
1097
|
-
ariaLabel = ( localize(
|
|
1097
|
+
ariaLabel = ( localize(5771, "Omitted this Notebook ouput: {0}", attachment.name));
|
|
1098
1098
|
} else if (attachment.omittedState === OmittedState.Partial) {
|
|
1099
|
-
ariaLabel = ( localize(
|
|
1099
|
+
ariaLabel = ( localize(5772, "Partially omitted this Notebook output: {0}", attachment.name));
|
|
1100
1100
|
} else {
|
|
1101
1101
|
ariaLabel = this.getAriaLabel(attachment);
|
|
1102
1102
|
}
|
|
@@ -1166,14 +1166,14 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
|
|
|
1166
1166
|
);
|
|
1167
1167
|
this.editorService = editorService;
|
|
1168
1168
|
this.hoverService = hoverService;
|
|
1169
|
-
const ariaLabel = ( localize(
|
|
1169
|
+
const ariaLabel = ( localize(5773, "Attached element, {0}", attachment.name));
|
|
1170
1170
|
this.element.ariaLabel = this.appendDeletionHint(ariaLabel);
|
|
1171
1171
|
this.element.style.position = "relative";
|
|
1172
1172
|
this.element.style.cursor = "pointer";
|
|
1173
1173
|
const attachmentLabel = attachment.name;
|
|
1174
1174
|
const withIcon = attachment.icon?.id ? `$(${attachment.icon.id})\u00A0${attachmentLabel}` : attachmentLabel;
|
|
1175
1175
|
this.label.setLabel(withIcon, undefined, {
|
|
1176
|
-
title: ( localize(
|
|
1176
|
+
title: ( localize(5774, "Click to view the contents of: {0}", attachmentLabel))
|
|
1177
1177
|
});
|
|
1178
1178
|
this._register(this.hoverService.setupDelayedHover(
|
|
1179
1179
|
this.element,
|
|
@@ -1193,7 +1193,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
|
|
|
1193
1193
|
const innerScrollables = [];
|
|
1194
1194
|
{
|
|
1195
1195
|
const section = $("div.chat-element-hover-section");
|
|
1196
|
-
const header = $("div.chat-element-hover-header", {}, ( localize(
|
|
1196
|
+
const header = $("div.chat-element-hover-header", {}, ( localize(5775, "ELEMENT")));
|
|
1197
1197
|
section.appendChild(header);
|
|
1198
1198
|
const elementPre = $("pre.chat-element-hover-code");
|
|
1199
1199
|
const elementCode = $("code");
|
|
@@ -1211,7 +1211,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
|
|
|
1211
1211
|
const computedStyleEntries = this.getComputedStyleEntriesForHover(attachment.computedStyles);
|
|
1212
1212
|
if (computedStyleEntries.length > 0) {
|
|
1213
1213
|
const section = $("div.chat-element-hover-section");
|
|
1214
|
-
const header = $("div.chat-element-hover-header", {}, ( localize(
|
|
1214
|
+
const header = $("div.chat-element-hover-header", {}, ( localize(5776, "KEY COMPUTED STYLES")));
|
|
1215
1215
|
section.appendChild(header);
|
|
1216
1216
|
const table = $("div.chat-element-hover-table");
|
|
1217
1217
|
for (const [name, value] of computedStyleEntries) {
|
|
@@ -1230,7 +1230,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
|
|
|
1230
1230
|
section.appendChild(table);
|
|
1231
1231
|
const showMoreButton = $("button.chat-element-hover-show-more", {
|
|
1232
1232
|
type: "button"
|
|
1233
|
-
}, ( localize(
|
|
1233
|
+
}, ( localize(5777, "Show More...")));
|
|
1234
1234
|
this._register(
|
|
1235
1235
|
addDisposableListener(showMoreButton, EventType.CLICK, async e => {
|
|
1236
1236
|
EventHelper.stop(e, true);
|
|
@@ -1242,7 +1242,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
|
|
|
1242
1242
|
}
|
|
1243
1243
|
if (attachment.ancestors && attachment.ancestors.length > 1) {
|
|
1244
1244
|
const section = $("div.chat-element-hover-section");
|
|
1245
|
-
const header = $("div.chat-element-hover-header", {}, ( localize(
|
|
1245
|
+
const header = $("div.chat-element-hover-header", {}, ( localize(5778, "HTML PATH")));
|
|
1246
1246
|
section.appendChild(header);
|
|
1247
1247
|
const lines = [];
|
|
1248
1248
|
for (let i = 0; i < attachment.ancestors.length; i++) {
|
|
@@ -1265,7 +1265,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
|
|
|
1265
1265
|
}
|
|
1266
1266
|
if (attachment.attributes && ( Object.keys(attachment.attributes)).length > 0) {
|
|
1267
1267
|
const section = $("div.chat-element-hover-section");
|
|
1268
|
-
const header = $("div.chat-element-hover-header", {}, ( localize(
|
|
1268
|
+
const header = $("div.chat-element-hover-header", {}, ( localize(5779, "ATTRIBUTES")));
|
|
1269
1269
|
section.appendChild(header);
|
|
1270
1270
|
const table = $("div.chat-element-hover-table");
|
|
1271
1271
|
for (const [name, value] of Object.entries(attachment.attributes)) {
|
|
@@ -1279,7 +1279,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
|
|
|
1279
1279
|
}
|
|
1280
1280
|
if (attachment.dimensions) {
|
|
1281
1281
|
const section = $("div.chat-element-hover-section");
|
|
1282
|
-
const header = $("div.chat-element-hover-header", {}, ( localize(
|
|
1282
|
+
const header = $("div.chat-element-hover-header", {}, ( localize(5780, "POSITION & SIZE")));
|
|
1283
1283
|
section.appendChild(header);
|
|
1284
1284
|
const table = $("div.chat-element-hover-table");
|
|
1285
1285
|
const dims = [
|
|
@@ -1299,7 +1299,7 @@ let ElementChatAttachmentWidget = class ElementChatAttachmentWidget extends Abst
|
|
|
1299
1299
|
}
|
|
1300
1300
|
if (attachment.innerText) {
|
|
1301
1301
|
const section = $("div.chat-element-hover-section");
|
|
1302
|
-
const header = $("div.chat-element-hover-header", {}, ( localize(
|
|
1302
|
+
const header = $("div.chat-element-hover-header", {}, ( localize(5781, "INNER TEXT")));
|
|
1303
1303
|
section.appendChild(header);
|
|
1304
1304
|
section.appendChild($("div.chat-element-hover-text", {}, attachment.innerText));
|
|
1305
1305
|
scrollableContent.appendChild(section);
|
|
@@ -1445,7 +1445,7 @@ let SCMHistoryItemAttachmentWidget = class SCMHistoryItemAttachmentWidget extend
|
|
|
1445
1445
|
);
|
|
1446
1446
|
this.label.setLabel(attachment.name, undefined);
|
|
1447
1447
|
this.element.style.cursor = "pointer";
|
|
1448
|
-
this.element.ariaLabel = this.appendDeletionHint(( localize(
|
|
1448
|
+
this.element.ariaLabel = this.appendDeletionHint(( localize(5762, "Attached context, {0}", attachment.name)));
|
|
1449
1449
|
const {
|
|
1450
1450
|
content,
|
|
1451
1451
|
disposables
|
|
@@ -1507,7 +1507,7 @@ let SCMHistoryItemChangeAttachmentWidget = class SCMHistoryItemChangeAttachmentW
|
|
|
1507
1507
|
hidePath: true,
|
|
1508
1508
|
nameSuffix
|
|
1509
1509
|
});
|
|
1510
|
-
this.element.ariaLabel = this.appendDeletionHint(( localize(
|
|
1510
|
+
this.element.ariaLabel = this.appendDeletionHint(( localize(5762, "Attached context, {0}", attachment.name)));
|
|
1511
1511
|
const {
|
|
1512
1512
|
content,
|
|
1513
1513
|
disposables
|
|
@@ -1563,7 +1563,7 @@ let SCMHistoryItemChangeRangeAttachmentWidget = class SCMHistoryItemChangeRangeA
|
|
|
1563
1563
|
hidePath: true,
|
|
1564
1564
|
nameSuffix
|
|
1565
1565
|
});
|
|
1566
|
-
this.element.ariaLabel = this.appendDeletionHint(( localize(
|
|
1566
|
+
this.element.ariaLabel = this.appendDeletionHint(( localize(5762, "Attached context, {0}", attachment.name)));
|
|
1567
1567
|
this.addResourceOpenHandlers(attachment.value, undefined);
|
|
1568
1568
|
}
|
|
1569
1569
|
async openResource(resource, options, isDirectory, range) {
|
|
@@ -1630,9 +1630,9 @@ let BrowserViewAttachmentWidget = class BrowserViewAttachmentWidget extends Abst
|
|
|
1630
1630
|
...commonHoverOptions,
|
|
1631
1631
|
content: this._input ? {
|
|
1632
1632
|
[BrowserViewSharingState.Shared]: this._input.getTitle() ?? "",
|
|
1633
|
-
[BrowserViewSharingState.NotShared]: ( localize(
|
|
1634
|
-
[BrowserViewSharingState.Unavailable]: ( localize(
|
|
1635
|
-
}[this._input.model?.sharingState ?? BrowserViewSharingState.Shared] : ( localize(
|
|
1633
|
+
[BrowserViewSharingState.NotShared]: ( localize(5782, "This browser page is not shared with the agent.")),
|
|
1634
|
+
[BrowserViewSharingState.Unavailable]: ( localize(5783, "Browser tools are not enabled."))
|
|
1635
|
+
}[this._input.model?.sharingState ?? BrowserViewSharingState.Shared] : ( localize(5784, "This browser page is no longer open."))
|
|
1636
1636
|
}), commonHoverLifecycleOptions));
|
|
1637
1637
|
this._instantiationService.invokeFunction(accessor => {
|
|
1638
1638
|
this._register(
|
|
@@ -1678,10 +1678,10 @@ let BrowserViewAttachmentWidget = class BrowserViewAttachmentWidget extends Abst
|
|
|
1678
1678
|
strikethrough: !isAvailable
|
|
1679
1679
|
});
|
|
1680
1680
|
this.element.ariaLabel = this.appendDeletionHint(this._input ? {
|
|
1681
|
-
[BrowserViewSharingState.Shared]: ( localize(
|
|
1682
|
-
[BrowserViewSharingState.NotShared]: ( localize(
|
|
1683
|
-
[BrowserViewSharingState.Unavailable]: ( localize(
|
|
1684
|
-
}[sharingState] : ( localize(
|
|
1681
|
+
[BrowserViewSharingState.Shared]: ( localize(5785, "Attached browser page, {0}", name)),
|
|
1682
|
+
[BrowserViewSharingState.NotShared]: ( localize(5786, "Browser page not shared with agent, {0}", name)),
|
|
1683
|
+
[BrowserViewSharingState.Unavailable]: ( localize(5787, "Browser tools are not enabled, {0}", name))
|
|
1684
|
+
}[sharingState] : ( localize(5788, "Browser page unavailable, {0}", name)));
|
|
1685
1685
|
}
|
|
1686
1686
|
async openResource(_resource, options, _isDirectory, _range) {
|
|
1687
1687
|
if (this._input) {
|
|
@@ -1832,7 +1832,7 @@ function addBasicContextMenu(accessor, widget, scopedContextKeyService, menuId,
|
|
|
1832
1832
|
const chatAttachmentResourceContextKey = ( new RawContextKey("chatAttachmentResource", undefined, {
|
|
1833
1833
|
type: "URI",
|
|
1834
1834
|
description: ( localize(
|
|
1835
|
-
|
|
1835
|
+
5789,
|
|
1836
1836
|
"The full value of the chat attachment resource, including scheme and path"
|
|
1837
1837
|
))
|
|
1838
1838
|
}));
|
package/vscode/src/vs/workbench/contrib/chat/browser/attachments/implicitContextAttachment.js
CHANGED
|
@@ -97,12 +97,12 @@ let ImplicitContextAttachmentWidget = class ImplicitContextAttachmentWidget exte
|
|
|
97
97
|
contextNode.tabIndex = 0;
|
|
98
98
|
contextNode.classList.toggle("disabled", !context.enabled);
|
|
99
99
|
const file = context.uri;
|
|
100
|
-
const attachmentTypeName = file?.scheme === Schemas.vscodeNotebookCell ? ( localize(
|
|
101
|
-
const contextLabel = context.name ?? (file ? basename(file) : ( localize(
|
|
100
|
+
const attachmentTypeName = file?.scheme === Schemas.vscodeNotebookCell ? ( localize(5791, "cell")) : ( localize(5792, "file"));
|
|
101
|
+
const contextLabel = context.name ?? (file ? basename(file) : ( localize(5793, "context")));
|
|
102
102
|
const isSuggestedEnabled = this.configService.getValue("chat.implicitContext.suggestedContext");
|
|
103
103
|
if (isSuggestedEnabled) {
|
|
104
104
|
if (!isSelection) {
|
|
105
|
-
const buttonMsg = context.enabled ? ( localize(
|
|
105
|
+
const buttonMsg = context.enabled ? ( localize(5794, "Disable {0} context {1}", attachmentTypeName, contextLabel)) : ( localize(5795, "Add {0} to context", contextLabel));
|
|
106
106
|
const toggleButton = this.renderDisposables.add(( new Button(contextNode, {
|
|
107
107
|
supportIcons: true,
|
|
108
108
|
title: buttonMsg
|
|
@@ -117,7 +117,7 @@ let ImplicitContextAttachmentWidget = class ImplicitContextAttachmentWidget exte
|
|
|
117
117
|
context.enabled = false;
|
|
118
118
|
}));
|
|
119
119
|
} else {
|
|
120
|
-
const pinButtonMsg = ( localize(
|
|
120
|
+
const pinButtonMsg = ( localize(5796, "Pin selection"));
|
|
121
121
|
const pinButton = this.renderDisposables.add(( new Button(contextNode, {
|
|
122
122
|
supportIcons: true,
|
|
123
123
|
title: pinButtonMsg
|
|
@@ -150,7 +150,7 @@ let ImplicitContextAttachmentWidget = class ImplicitContextAttachmentWidget exte
|
|
|
150
150
|
})
|
|
151
151
|
);
|
|
152
152
|
} else {
|
|
153
|
-
const buttonMsg = context.enabled ? ( localize(
|
|
153
|
+
const buttonMsg = context.enabled ? ( localize(5797, "Disable current {0} context", attachmentTypeName)) : ( localize(5798, "Enable current {0} context", attachmentTypeName));
|
|
154
154
|
const toggleButton = this.renderDisposables.add(( new Button(contextNode, {
|
|
155
155
|
supportIcons: true,
|
|
156
156
|
title: buttonMsg
|
|
@@ -174,9 +174,9 @@ let ImplicitContextAttachmentWidget = class ImplicitContextAttachmentWidget exte
|
|
|
174
174
|
context.icon,
|
|
175
175
|
context.value.resourceUri,
|
|
176
176
|
markdownTooltip,
|
|
177
|
-
( localize(
|
|
177
|
+
( localize(5799, "Current file context"))
|
|
178
178
|
);
|
|
179
|
-
contextNode.ariaLabel = ( localize(
|
|
179
|
+
contextNode.ariaLabel = ( localize(5800, "Suggested context, {0}", context.name));
|
|
180
180
|
} else {
|
|
181
181
|
title = this.renderResource(context.value, context.isSelection, context.enabled, label, contextNode);
|
|
182
182
|
}
|
|
@@ -236,23 +236,23 @@ let ImplicitContextAttachmentWidget = class ImplicitContextAttachmentWidget exte
|
|
|
236
236
|
if (file.scheme === Schemas.vscodeBrowser) {
|
|
237
237
|
return this.renderBrowserResource(file, label, contextNode);
|
|
238
238
|
}
|
|
239
|
-
const attachmentTypeName = file.scheme === Schemas.vscodeNotebookCell ? ( localize(
|
|
239
|
+
const attachmentTypeName = file.scheme === Schemas.vscodeNotebookCell ? ( localize(5791, "cell")) : ( localize(5792, "file"));
|
|
240
240
|
const fileBasename = basename(file);
|
|
241
241
|
const fileDirname = dirname(file);
|
|
242
242
|
const friendlyName = `${fileBasename} ${fileDirname}`;
|
|
243
243
|
const ariaLabel = range ? ( localize(
|
|
244
|
-
|
|
244
|
+
5801,
|
|
245
245
|
"Suggested context, {0}, {1}, line {2} to line {3}",
|
|
246
246
|
attachmentTypeName,
|
|
247
247
|
friendlyName,
|
|
248
248
|
range.startLineNumber,
|
|
249
249
|
range.endLineNumber
|
|
250
|
-
)) : ( localize(
|
|
250
|
+
)) : ( localize(5802, "Suggested context, {0}, {1}", attachmentTypeName, friendlyName));
|
|
251
251
|
const uriLabel = this.labelService.getUriLabel(file, {
|
|
252
252
|
relative: true
|
|
253
253
|
});
|
|
254
|
-
const currentFile = ( localize(
|
|
255
|
-
const inactive = ( localize(
|
|
254
|
+
const currentFile = ( localize(5803, "Current {0} context", attachmentTypeName));
|
|
255
|
+
const inactive = ( localize(5804, "Enable current {0} context", attachmentTypeName));
|
|
256
256
|
const currentFileHint = enabled || isSelection ? currentFile : inactive;
|
|
257
257
|
const title = `${currentFileHint}\n${uriLabel}`;
|
|
258
258
|
label.setFile(file, {
|
|
@@ -274,7 +274,7 @@ let ImplicitContextAttachmentWidget = class ImplicitContextAttachmentWidget exte
|
|
|
274
274
|
label.setLabel(input.getName(), undefined, {
|
|
275
275
|
iconPath: Codicon.globe
|
|
276
276
|
});
|
|
277
|
-
contextNode.ariaLabel = ( localize(
|
|
277
|
+
contextNode.ariaLabel = ( localize(5805, "Suggested browser context, {0}", input.getName()));
|
|
278
278
|
};
|
|
279
279
|
update();
|
|
280
280
|
this.renderDisposables.add(input.onDidChangeLabel(() => update()));
|