@codingame/monaco-vscode-xterm-addons-common 36.2.7 → 37.2.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 (20) hide show
  1. package/package.json +10 -10
  2. package/vscode/src/vs/base/browser/htmlToMarkdown.js +24 -6
  3. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContext.d.ts +27 -0
  4. package/vscode/src/vs/workbench/contrib/chat/browser/actions/chatContext.js +158 -24
  5. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/attachInstructionsAction.js +8 -16
  6. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/newPromptFileActions.js +15 -15
  7. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/pickers/askForPromptName.js +9 -9
  8. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/pickers/askForPromptSourceFolder.js +30 -29
  9. package/vscode/src/vs/workbench/contrib/chat/browser/promptSyntax/pickers/promptFilePickers.js +42 -38
  10. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatPasteProviders.d.ts +22 -6
  11. package/vscode/src/vs/workbench/contrib/chat/browser/widget/input/editor/chatPasteProviders.js +254 -132
  12. package/vscode/src/vs/workbench/contrib/git/common/utils.d.ts +8 -0
  13. package/vscode/src/vs/workbench/contrib/git/common/utils.js +105 -0
  14. package/vscode/src/vs/workbench/contrib/terminal/browser/xterm/decorationAddon.d.ts +1 -2
  15. package/vscode/src/vs/workbench/contrib/terminal/browser/xterm/decorationAddon.js +27 -22
  16. package/vscode/src/vs/workbench/contrib/terminal/browser/xterm/markNavigationAddon.js +1 -11
  17. package/vscode/src/vs/workbench/contrib/terminal/browser/xterm/xtermTerminal.d.ts +16 -1
  18. package/vscode/src/vs/workbench/contrib/terminal/browser/xterm/xtermTerminal.js +75 -17
  19. package/vscode/src/vs/workbench/contrib/chat/browser/copilotCliEventsUri.d.ts +0 -82
  20. package/vscode/src/vs/workbench/contrib/chat/browser/copilotCliEventsUri.js +0 -114
@@ -5,7 +5,7 @@ import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
5
5
  import { IInstantiationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation';
6
6
  import { ILabelService } from '@codingame/monaco-vscode-api/vscode/vs/platform/label/common/label.service';
7
7
  import { IOpenerService } from '@codingame/monaco-vscode-api/vscode/vs/platform/opener/common/opener.service';
8
- import { getSourceDescription, PromptsType, PROMPT_DOCUMENTATION_URL } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/promptSyntax/promptTypes';
8
+ import { getSourceDescription, PromptsType, getDocumentationUrl } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/promptSyntax/promptTypes';
9
9
  import { IQuickInputService } from '@codingame/monaco-vscode-api/vscode/vs/platform/quickinput/common/quickInput.service';
10
10
  import { PromptsStorage } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/promptSyntax/service/promptsService';
11
11
  import { IPromptsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/promptSyntax/service/promptsService.service';
@@ -36,13 +36,13 @@ async function askForPromptSourceFolder(accessor, type, existingFolder, isMove =
36
36
  const folderUri = resolved.searchRoot;
37
37
  const isDefault = defaultFolder && isEqual(folderUri, defaultFolder.searchRoot);
38
38
  const sourceDescription = getSourceDescription(resolved.source);
39
- const detail = (existingFolder && isEqual(folderUri, existingFolder)) ? ( localize(7542, "Current Location")) : undefined;
39
+ const detail = (existingFolder && isEqual(folderUri, existingFolder)) ? ( localize(8920, "Current Location")) : undefined;
40
40
  const basePath = (isMultiRoot && resolved.storage === PromptsStorage.local) ? labelService.getUriLabel(folderUri, {
41
41
  relative: true
42
42
  }) : resolved.displayPath ?? labelService.getUriLabel(folderUri, {
43
43
  relative: resolved.storage === PromptsStorage.local
44
44
  });
45
- const label = isDefault ? ( localize(7543, "{0} (default)", basePath)) : basePath;
45
+ const label = isDefault ? ( localize(8921, "{0} (default)", basePath)) : basePath;
46
46
  const folder = {
47
47
  uri: folderUri,
48
48
  storage: resolved.storage,
@@ -81,15 +81,15 @@ async function askForPromptSourceFolder(accessor, type, existingFolder, isMove =
81
81
  function getPlaceholderStringforNew(type) {
82
82
  switch (type) {
83
83
  case PromptsType.instructions:
84
- return localize(7544, "Select a location to create the instructions file");
84
+ return localize(8922, "Select a location to create the instructions file");
85
85
  case PromptsType.prompt:
86
- return localize(7545, "Select a location to create the prompt file");
86
+ return localize(8923, "Select a location to create the prompt file");
87
87
  case PromptsType.agent:
88
- return localize(7546, "Select a location to create the agent file");
88
+ return localize(8924, "Select a location to create the agent file");
89
89
  case PromptsType.skill:
90
- return localize(7547, "Select a location to create the skill");
90
+ return localize(8925, "Select a location to create the skill");
91
91
  case PromptsType.hook:
92
- return localize(7548, "Select a location to create the hook file");
92
+ return localize(8926, "Select a location to create the hook file");
93
93
  default:
94
94
  throw ( new Error("Unknown prompt type"));
95
95
  }
@@ -98,13 +98,13 @@ function getPlaceholderStringforMove(type, isMove) {
98
98
  if (isMove) {
99
99
  switch (type) {
100
100
  case PromptsType.instructions:
101
- return localize(7549, "Select a location to move the instructions file to");
101
+ return localize(8927, "Select a location to move the instructions file to");
102
102
  case PromptsType.prompt:
103
- return localize(7550, "Select a location to move the prompt file to");
103
+ return localize(8928, "Select a location to move the prompt file to");
104
104
  case PromptsType.agent:
105
- return localize(7551, "Select a location to move the agent file to");
105
+ return localize(8929, "Select a location to move the agent file to");
106
106
  case PromptsType.skill:
107
- return localize(7552, "Select a location to move the skill to");
107
+ return localize(8930, "Select a location to move the skill to");
108
108
  case PromptsType.hook:
109
109
  throw ( new Error("Hooks cannot be moved"));
110
110
  default:
@@ -113,13 +113,13 @@ function getPlaceholderStringforMove(type, isMove) {
113
113
  }
114
114
  switch (type) {
115
115
  case PromptsType.instructions:
116
- return localize(7553, "Select a location to copy the instructions file to");
116
+ return localize(8931, "Select a location to copy the instructions file to");
117
117
  case PromptsType.prompt:
118
- return localize(7554, "Select a location to copy the prompt file to");
118
+ return localize(8932, "Select a location to copy the prompt file to");
119
119
  case PromptsType.agent:
120
- return localize(7555, "Select a location to copy the agent file to");
120
+ return localize(8933, "Select a location to copy the agent file to");
121
121
  case PromptsType.skill:
122
- return localize(7556, "Select a location to copy the skill to");
122
+ return localize(8934, "Select a location to copy the skill to");
123
123
  case PromptsType.hook:
124
124
  throw ( new Error("Hooks cannot be copied"));
125
125
  default:
@@ -129,12 +129,13 @@ function getPlaceholderStringforMove(type, isMove) {
129
129
  async function showNoFoldersDialog(accessor, type) {
130
130
  const quickInputService = accessor.get(IQuickInputService);
131
131
  const openerService = accessor.get(IOpenerService);
132
+ const documentationUrl = getDocumentationUrl(type);
132
133
  const docsQuickPick = {
133
134
  type: "item",
134
135
  label: getLearnLabel(type),
135
- description: PROMPT_DOCUMENTATION_URL,
136
- tooltip: PROMPT_DOCUMENTATION_URL,
137
- value: ( URI.parse(PROMPT_DOCUMENTATION_URL))
136
+ description: documentationUrl,
137
+ tooltip: documentationUrl,
138
+ value: ( URI.parse(documentationUrl))
138
139
  };
139
140
  const result = await quickInputService.pick([docsQuickPick], {
140
141
  placeHolder: getMissingSourceFolderString(type),
@@ -147,15 +148,15 @@ async function showNoFoldersDialog(accessor, type) {
147
148
  function getLearnLabel(type) {
148
149
  switch (type) {
149
150
  case PromptsType.prompt:
150
- return localize(7557, "Learn how to configure reusable prompts");
151
+ return localize(8935, "Learn how to configure reusable prompts");
151
152
  case PromptsType.instructions:
152
- return localize(7558, "Learn how to configure reusable instructions");
153
+ return localize(8936, "Learn how to configure reusable instructions");
153
154
  case PromptsType.agent:
154
- return localize(7559, "Learn how to configure custom agents");
155
+ return localize(8937, "Learn how to configure custom agents");
155
156
  case PromptsType.skill:
156
- return localize(7560, "Learn how to configure skills");
157
+ return localize(8938, "Learn how to configure skills");
157
158
  case PromptsType.hook:
158
- return localize(7561, "Learn how to configure hooks");
159
+ return localize(8939, "Learn how to configure hooks");
159
160
  default:
160
161
  throw ( new Error("Unknown prompt type"));
161
162
  }
@@ -163,15 +164,15 @@ function getLearnLabel(type) {
163
164
  function getMissingSourceFolderString(type) {
164
165
  switch (type) {
165
166
  case PromptsType.instructions:
166
- return localize(7562, "No instruction source folders found.");
167
+ return localize(8940, "No instruction source folders found.");
167
168
  case PromptsType.prompt:
168
- return localize(7563, "No prompt source folders found.");
169
+ return localize(8941, "No prompt source folders found.");
169
170
  case PromptsType.agent:
170
- return localize(7564, "No agent source folders found.");
171
+ return localize(8942, "No agent source folders found.");
171
172
  case PromptsType.skill:
172
- return localize(7565, "No skill source folders found.");
173
+ return localize(8943, "No skill source folders found.");
173
174
  case PromptsType.hook:
174
- return localize(7566, "No hook source folders found.");
175
+ return localize(8944, "No hook source folders found.");
175
176
  default:
176
177
  throw ( new Error("Unknown prompt type"));
177
178
  }
@@ -13,7 +13,7 @@ import { IOpenerService } from '@codingame/monaco-vscode-api/vscode/vs/platform/
13
13
  import { IDialogService } from '@codingame/monaco-vscode-api/vscode/vs/platform/dialogs/common/dialogs.service';
14
14
  import { ICommandService } from '@codingame/monaco-vscode-api/vscode/vs/platform/commands/common/commands.service';
15
15
  import { getSkillFolderName, getCleanPromptName } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/promptSyntax/config/promptFileLocations';
16
- import { PromptsType, HOOK_DOCUMENTATION_URL, SKILL_DOCUMENTATION_URL, AGENT_DOCUMENTATION_URL, INSTRUCTIONS_DOCUMENTATION_URL, PROMPT_DOCUMENTATION_URL } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/promptSyntax/promptTypes';
16
+ import { getDocumentationUrl, PromptsType } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/promptSyntax/promptTypes';
17
17
  import { NEW_PROMPT_COMMAND_ID, NEW_INSTRUCTIONS_COMMAND_ID, NEW_AGENT_COMMAND_ID, NEW_SKILL_COMMAND_ID } from '../newPromptFileActions.js';
18
18
  import { GENERATE_AGENT_INSTRUCTIONS_COMMAND_ID, GENERATE_ON_DEMAND_INSTRUCTIONS_COMMAND_ID, GENERATE_PROMPT_COMMAND_ID, GENERATE_SKILL_COMMAND_ID, GENERATE_AGENT_COMMAND_ID } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/actions/chatActions';
19
19
  import { IQuickInputService } from '@codingame/monaco-vscode-api/vscode/vs/platform/quickinput/common/quickInput.service';
@@ -29,35 +29,36 @@ import { assertNever } from '@codingame/monaco-vscode-api/vscode/vs/base/common/
29
29
 
30
30
  function newHelpButton(type) {
31
31
  const iconClass = ThemeIcon.asClassName(Codicon.question);
32
+ const helpURI = ( URI.parse(getDocumentationUrl(type)));
32
33
  switch (type) {
33
34
  case PromptsType.prompt:
34
35
  return {
35
- tooltip: ( localize(7567, "Show help on prompt files")),
36
- helpURI: ( URI.parse(PROMPT_DOCUMENTATION_URL)),
36
+ tooltip: ( localize(8945, "Show help on prompt files")),
37
+ helpURI,
37
38
  iconClass
38
39
  };
39
40
  case PromptsType.instructions:
40
41
  return {
41
- tooltip: ( localize(7568, "Show help on instruction files")),
42
- helpURI: ( URI.parse(INSTRUCTIONS_DOCUMENTATION_URL)),
42
+ tooltip: ( localize(8946, "Show help on instruction files")),
43
+ helpURI,
43
44
  iconClass
44
45
  };
45
46
  case PromptsType.agent:
46
47
  return {
47
- tooltip: ( localize(7569, "Show help on custom agent files")),
48
- helpURI: ( URI.parse(AGENT_DOCUMENTATION_URL)),
48
+ tooltip: ( localize(8947, "Show help on custom agent files")),
49
+ helpURI,
49
50
  iconClass
50
51
  };
51
52
  case PromptsType.skill:
52
53
  return {
53
- tooltip: ( localize(7570, "Show help on skill files")),
54
- helpURI: ( URI.parse(SKILL_DOCUMENTATION_URL)),
54
+ tooltip: ( localize(8948, "Show help on skill files")),
55
+ helpURI,
55
56
  iconClass
56
57
  };
57
58
  case PromptsType.hook:
58
59
  return {
59
- tooltip: ( localize(7571, "Show help on hook files")),
60
- helpURI: ( URI.parse(HOOK_DOCUMENTATION_URL)),
60
+ tooltip: ( localize(8949, "Show help on hook files")),
61
+ helpURI,
61
62
  iconClass
62
63
  };
63
64
  }
@@ -73,7 +74,7 @@ function isExtensionPromptPath(prompt) {
73
74
  }
74
75
  const NEW_PROMPT_FILE_OPTION = {
75
76
  type: "item",
76
- label: `$(plus) ${( localize(7572, "New prompt file..."))}`,
77
+ label: `$(plus) ${( localize(8950, "New prompt file..."))}`,
77
78
  pickable: false,
78
79
  alwaysShow: true,
79
80
  buttons: [newHelpButton(PromptsType.prompt)],
@@ -81,7 +82,7 @@ const NEW_PROMPT_FILE_OPTION = {
81
82
  };
82
83
  const NEW_INSTRUCTIONS_FILE_OPTION = {
83
84
  type: "item",
84
- label: `$(plus) ${( localize(7573, "New instruction file..."))}`,
85
+ label: `$(plus) ${( localize(8951, "New instruction file..."))}`,
85
86
  pickable: false,
86
87
  alwaysShow: true,
87
88
  buttons: [newHelpButton(PromptsType.instructions)],
@@ -89,7 +90,7 @@ const NEW_INSTRUCTIONS_FILE_OPTION = {
89
90
  };
90
91
  const GENERATE_AGENT_INSTRUCTIONS_OPTION = {
91
92
  type: "item",
92
- label: `$(sparkle) ${( localize(7574, "Generate agent instructions..."))}`,
93
+ label: `$(sparkle) ${( localize(8952, "Generate agent instructions..."))}`,
93
94
  pickable: false,
94
95
  alwaysShow: true,
95
96
  buttons: [newHelpButton(PromptsType.instructions)],
@@ -97,7 +98,7 @@ const GENERATE_AGENT_INSTRUCTIONS_OPTION = {
97
98
  };
98
99
  const GENERATE_ON_DEMAND_INSTRUCTIONS_OPTION = {
99
100
  type: "item",
100
- label: `$(sparkle) ${( localize(7575, "Generate on-demand instructions..."))}`,
101
+ label: `$(sparkle) ${( localize(8953, "Generate on-demand instructions..."))}`,
101
102
  pickable: false,
102
103
  alwaysShow: true,
103
104
  buttons: [newHelpButton(PromptsType.instructions)],
@@ -105,7 +106,7 @@ const GENERATE_ON_DEMAND_INSTRUCTIONS_OPTION = {
105
106
  };
106
107
  const NEW_AGENT_FILE_OPTION = {
107
108
  type: "item",
108
- label: `$(plus) ${( localize(7576, "Create new custom agent..."))}`,
109
+ label: `$(plus) ${( localize(8954, "Create new custom agent..."))}`,
109
110
  pickable: false,
110
111
  alwaysShow: true,
111
112
  buttons: [newHelpButton(PromptsType.agent)],
@@ -113,7 +114,7 @@ const NEW_AGENT_FILE_OPTION = {
113
114
  };
114
115
  const NEW_SKILL_FILE_OPTION = {
115
116
  type: "item",
116
- label: `$(plus) ${( localize(7577, "New skill..."))}`,
117
+ label: `$(plus) ${( localize(8955, "New skill..."))}`,
117
118
  pickable: false,
118
119
  alwaysShow: true,
119
120
  buttons: [newHelpButton(PromptsType.skill)],
@@ -121,7 +122,7 @@ const NEW_SKILL_FILE_OPTION = {
121
122
  };
122
123
  const GENERATE_PROMPT_OPTION = {
123
124
  type: "item",
124
- label: `$(sparkle) ${( localize(7578, "Generate prompt..."))}`,
125
+ label: `$(sparkle) ${( localize(8956, "Generate prompt..."))}`,
125
126
  pickable: false,
126
127
  alwaysShow: true,
127
128
  buttons: [newHelpButton(PromptsType.prompt)],
@@ -129,7 +130,7 @@ const GENERATE_PROMPT_OPTION = {
129
130
  };
130
131
  const GENERATE_SKILL_OPTION = {
131
132
  type: "item",
132
- label: `$(sparkle) ${( localize(7579, "Generate skill..."))}`,
133
+ label: `$(sparkle) ${( localize(8957, "Generate skill..."))}`,
133
134
  pickable: false,
134
135
  alwaysShow: true,
135
136
  buttons: [newHelpButton(PromptsType.skill)],
@@ -137,39 +138,39 @@ const GENERATE_SKILL_OPTION = {
137
138
  };
138
139
  const GENERATE_AGENT_OPTION = {
139
140
  type: "item",
140
- label: `$(sparkle) ${( localize(7580, "Generate agent..."))}`,
141
+ label: `$(sparkle) ${( localize(8958, "Generate agent..."))}`,
141
142
  pickable: false,
142
143
  alwaysShow: true,
143
144
  buttons: [newHelpButton(PromptsType.agent)],
144
145
  commandId: GENERATE_AGENT_COMMAND_ID
145
146
  };
146
147
  const EDIT_BUTTON = {
147
- tooltip: ( localize(7581, "Open in Editor")),
148
+ tooltip: ( localize(8959, "Open in Editor")),
148
149
  iconClass: ThemeIcon.asClassName(Codicon.fileCode)
149
150
  };
150
151
  const DELETE_BUTTON = {
151
- tooltip: ( localize(7582, "Delete")),
152
+ tooltip: ( localize(8960, "Delete")),
152
153
  iconClass: ThemeIcon.asClassName(Codicon.trash)
153
154
  };
154
155
  const RENAME_BUTTON = {
155
- tooltip: ( localize(7583, "Move and/or Rename")),
156
+ tooltip: ( localize(8961, "Move and/or Rename")),
156
157
  iconClass: ThemeIcon.asClassName(Codicon.replace)
157
158
  };
158
159
  const COPY_BUTTON = {
159
- tooltip: ( localize(7584, "Make a Copy")),
160
+ tooltip: ( localize(8962, "Make a Copy")),
160
161
  iconClass: ThemeIcon.asClassName(Codicon.copy)
161
162
  };
162
163
  const MAKE_VISIBLE_BUTTON = {
163
- tooltip: ( localize(7585, "Hidden from chat view agent picker. Click to show.")),
164
+ tooltip: ( localize(8963, "Hidden from chat view agent picker. Click to show.")),
164
165
  iconClass: ThemeIcon.asClassName(Codicon.eyeClosed),
165
166
  alwaysVisible: true
166
167
  };
167
168
  const MAKE_INVISIBLE_BUTTON = {
168
- tooltip: ( localize(7586, "Shown in chat view agent picker. Click to hide.")),
169
+ tooltip: ( localize(8964, "Shown in chat view agent picker. Click to hide.")),
169
170
  iconClass: ThemeIcon.asClassName(Codicon.eye)
170
171
  };
171
172
  const RUN_IN_CHAT_BUTTON = {
172
- tooltip: ( localize(7587, "Run in Chat View")),
173
+ tooltip: ( localize(8965, "Run in Chat View")),
173
174
  iconClass: ThemeIcon.asClassName(Codicon.play)
174
175
  };
175
176
  let PromptFilePickers = class PromptFilePickers {
@@ -200,7 +201,7 @@ let PromptFilePickers = class PromptFilePickers {
200
201
  useSeparators: true
201
202
  });
202
203
  quickPick.busy = true;
203
- quickPick.placeholder = ( localize(7588, "Searching file system..."));
204
+ quickPick.placeholder = ( localize(8966, "Searching file system..."));
204
205
  try {
205
206
  const fileOptions = await this._createPromptPickItems(options, cts.token);
206
207
  const activeItem = options.resource && fileOptions.find(
@@ -301,7 +302,7 @@ let PromptFilePickers = class PromptFilePickers {
301
302
  if (locals.length) {
302
303
  result.push({
303
304
  type: "separator",
304
- label: ( localize(7589, "Workspace"))
305
+ label: ( localize(8967, "Workspace"))
305
306
  });
306
307
  result.push(...sortByLabel(await Promise.all(( locals.map(l => this._createPromptPickItem(l, buttons, getVisibility(l), token))))));
307
308
  }
@@ -324,7 +325,7 @@ let PromptFilePickers = class PromptFilePickers {
324
325
  const agentButtons = buttons.filter(b => b !== RENAME_BUTTON);
325
326
  result.push({
326
327
  type: "separator",
327
- label: ( localize(7590, "Agent Instructions"))
328
+ label: ( localize(8968, "Agent Instructions"))
328
329
  });
329
330
  result.push(...sortByLabel(await Promise.all(( agentInstructionFiles.map(l => this._createPromptPickItem(l, agentButtons, getVisibility(l), token))))));
330
331
  }
@@ -361,7 +362,7 @@ let PromptFilePickers = class PromptFilePickers {
361
362
  if (users.length) {
362
363
  result.push({
363
364
  type: "separator",
364
- label: ( localize(7591, "User Data"))
365
+ label: ( localize(8969, "User Data"))
365
366
  });
366
367
  result.push(...sortByLabel(await Promise.all(( users.map(u => this._createPromptPickItem(u, buttons, getVisibility(u), token))))));
367
368
  }
@@ -373,7 +374,7 @@ let PromptFilePickers = class PromptFilePickers {
373
374
  }
374
375
  result.push({
375
376
  type: "separator",
376
- label: ( localize(7592, "Plugins"))
377
+ label: ( localize(8970, "Plugins"))
377
378
  });
378
379
  result.push(...sortByLabel(await Promise.all(( plugins.map(p => this._createPromptPickItem(p, pluginButtons, getVisibility(p), token))))));
379
380
  }
@@ -381,9 +382,9 @@ let PromptFilePickers = class PromptFilePickers {
381
382
  }
382
383
  _getExtensionGroupLabel(extPath) {
383
384
  if (isOrganizationPromptFile(extPath.uri, extPath.extension.identifier, this._productService)) {
384
- return localize(7593, "Organization");
385
+ return localize(8971, "Organization");
385
386
  }
386
- return localize(7594, "Extensions");
387
+ return localize(8972, "Extensions");
387
388
  }
388
389
  _getNewItems(type) {
389
390
  switch (type) {
@@ -423,14 +424,17 @@ let PromptFilePickers = class PromptFilePickers {
423
424
  case PromptsStorage.plugin:
424
425
  tooltip = promptFile.name;
425
426
  break;
427
+ case PromptsStorage.builtIn:
428
+ tooltip = undefined;
429
+ break;
426
430
  default:
427
431
  assertNever();
428
432
  }
429
433
  let iconClass;
430
434
  if (visibility === false) {
431
435
  buttons = (buttons ?? []).concat(MAKE_VISIBLE_BUTTON);
432
- promptName = ( localize(7595, "{0} (hidden)", promptName));
433
- tooltip = ( localize(7596, "Hidden from chat view agent picker"));
436
+ promptName = ( localize(8973, "{0} (hidden)", promptName));
437
+ tooltip = ( localize(8974, "Hidden from chat view agent picker"));
434
438
  } else if (visibility === true) {
435
439
  buttons = (buttons ?? []).concat(MAKE_INVISIBLE_BUTTON);
436
440
  }
@@ -506,10 +510,10 @@ let PromptFilePickers = class PromptFilePickers {
506
510
  const isSkill = options.type === PromptsType.skill;
507
511
  const filename = isSkill ? basename(dirname(value)) : item.label;
508
512
  const message = isSkill ? ( localize(
509
- 7597,
513
+ 8975,
510
514
  "Are you sure you want to delete skill '{0}' and its folder?",
511
515
  filename
512
- )) : ( localize(7598, "Are you sure you want to delete '{0}'?", filename));
516
+ )) : ( localize(8976, "Are you sure you want to delete '{0}'?", filename));
513
517
  const {
514
518
  confirmed
515
519
  } = await this._dialogService.confirm({
@@ -11,11 +11,15 @@ import { IOutlineModelService } from "@codingame/monaco-vscode-api/vscode/vs/edi
11
11
  import { IEnvironmentService } from "@codingame/monaco-vscode-api/vscode/vs/platform/environment/common/environment.service";
12
12
  import { IFileService } from "@codingame/monaco-vscode-api/vscode/vs/platform/files/common/files.service";
13
13
  import { IInstantiationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation";
14
+ import { IConfigurationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/configuration/common/configuration.service";
14
15
  import { ILogService } from "@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service";
15
16
  import { IExtensionService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions.service";
16
- import { IChatWidgetService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chat.service";
17
+ import { IChatRequestPasteVariableEntry, IChatRequestVariableEntry } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/attachments/chatVariableEntries";
18
+ import { IChatPasteTargetService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chat.service";
19
+ export declare const pastedTextArtifactDefaultMinLength = 10000;
20
+ export declare const CHAT_ATTACHMENT_MIME_TYPE = "application/vnd.chat.attachment+json";
17
21
  export declare class PasteImageProvider implements DocumentPasteEditProvider {
18
- private readonly chatWidgetService;
22
+ private readonly pasteTargetService;
19
23
  private readonly extensionService;
20
24
  private readonly fileService;
21
25
  private readonly environmentService;
@@ -25,7 +29,7 @@ export declare class PasteImageProvider implements DocumentPasteEditProvider {
25
29
  readonly providedPasteEditKinds: HierarchicalKind[];
26
30
  readonly copyMimeTypes: never[];
27
31
  readonly pasteMimeTypes: string[];
28
- constructor(chatWidgetService: IChatWidgetService, extensionService: IExtensionService, fileService: IFileService, environmentService: IEnvironmentService, logService: ILogService);
32
+ constructor(pasteTargetService: IChatPasteTargetService, extensionService: IExtensionService, fileService: IFileService, environmentService: IEnvironmentService, logService: ILogService);
29
33
  provideDocumentPasteEdits(model: ITextModel, ranges: readonly IRange[], dataTransfer: IReadonlyVSDataTransfer, context: DocumentPasteContext, token: CancellationToken): Promise<DocumentPasteEditsSession | undefined>;
30
34
  }
31
35
  export declare function isImage(array: Uint8Array): boolean;
@@ -40,16 +44,28 @@ export declare class CopyTextProvider implements DocumentPasteEditProvider {
40
44
  prepareDocumentPaste(model: ITextModel, ranges: readonly IRange[], dataTransfer: IReadonlyVSDataTransfer, token: CancellationToken): Promise<undefined | IReadonlyVSDataTransfer>;
41
45
  private primeSymbolReferenceCache;
42
46
  }
47
+ export declare function getGitHubIssueOrPullRequestAttachments(input: string, metadata?: Record<string, unknown>): readonly IChatRequestVariableEntry[];
43
48
  export declare class PasteTextProvider implements DocumentPasteEditProvider {
44
- private readonly chatWidgetService;
49
+ private readonly pasteTargetService;
45
50
  private readonly modelService;
51
+ private readonly logService;
52
+ private readonly configurationService;
46
53
  readonly kind: HierarchicalKind;
47
54
  readonly providedPasteEditKinds: HierarchicalKind[];
48
55
  readonly copyMimeTypes: never[];
49
56
  readonly pasteMimeTypes: string[];
50
- constructor(chatWidgetService: IChatWidgetService, modelService: IModelService);
57
+ constructor(pasteTargetService: IChatPasteTargetService, modelService: IModelService, logService: ILogService, configurationService: IConfigurationService);
51
58
  provideDocumentPasteEdits(model: ITextModel, ranges: readonly IRange[], dataTransfer: IReadonlyVSDataTransfer, _context: DocumentPasteContext, token: CancellationToken): Promise<DocumentPasteEditsSession | undefined>;
52
59
  }
60
+ export declare function createPastedTextArtifact(text: string, existingAttachments: readonly IChatRequestVariableEntry[], options?: {
61
+ /** Richer representation to store instead of `text`, e.g. Markdown from pasted HTML. */
62
+ readonly content?: string;
63
+ /** Character count the paste must exceed to become an attachment. */
64
+ readonly minLength?: number;
65
+ }): {
66
+ readonly attachment: IChatRequestPasteVariableEntry;
67
+ readonly referenceText: string;
68
+ } | undefined;
53
69
  export declare class ChatPasteProvidersFeature extends Disposable {
54
- constructor(instaService: IInstantiationService, languageFeaturesService: ILanguageFeaturesService, chatWidgetService: IChatWidgetService, extensionService: IExtensionService, fileService: IFileService, modelService: IModelService, environmentService: IEnvironmentService, logService: ILogService);
70
+ constructor(instaService: IInstantiationService, languageFeaturesService: ILanguageFeaturesService, pasteTargetService: IChatPasteTargetService, extensionService: IExtensionService, fileService: IFileService, modelService: IModelService, environmentService: IEnvironmentService, logService: ILogService, configurationService: IConfigurationService);
55
71
  }