@codingame/monaco-vscode-api 5.0.1 → 5.1.1

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 (30) hide show
  1. package/api.js +1 -1
  2. package/lifecycle.js +4 -2
  3. package/missing-services.js +8 -2
  4. package/package.json +8 -8
  5. package/service-override/files.d.ts +1 -0
  6. package/service-override/tools/editor.js +3 -3
  7. package/service-override/tools/views.d.ts +2 -1
  8. package/service-override/tools/views.js +8 -0
  9. package/services.js +2 -2
  10. package/vscode/src/vs/base/browser/dom.js +4 -4
  11. package/vscode/src/vs/base/common/date.js +4 -12
  12. package/vscode/src/vs/base/common/decorators.js +2 -6
  13. package/vscode/src/vs/base/common/extpath.js +2 -8
  14. package/vscode/src/vs/base/common/jsonEdit.js +1 -1
  15. package/vscode/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.js +1 -1
  16. package/vscode/src/vs/editor/common/core/lineRange.js +1 -1
  17. package/vscode/src/vs/editor/contrib/indentation/common/indentation.js +1 -13
  18. package/vscode/src/vs/platform/quickinput/browser/quickPickPin.js +3 -3
  19. package/vscode/src/vs/platform/workspace/common/workspace.js +1 -5
  20. package/vscode/src/vs/workbench/browser/parts/views/treeView.js +3 -0
  21. package/vscode/src/vs/workbench/contrib/comments/browser/commentNode.js +0 -3
  22. package/vscode/src/vs/workbench/contrib/comments/browser/commentsController.js +1 -1
  23. package/vscode/src/vs/workbench/contrib/debug/common/debugModel.js +1 -1
  24. package/vscode/src/vs/workbench/contrib/debug/common/debugUtils.js +0 -3
  25. package/vscode/src/vs/workbench/contrib/notebook/browser/controller/cellOperations.js +2 -14
  26. package/vscode/src/vs/workbench/contrib/notebook/browser/view/cellParts/cellToolbars.js +1 -1
  27. package/vscode/src/vs/workbench/contrib/notebook/browser/view/renderers/webviewPreloads.js +1 -56
  28. package/vscode/src/vs/workbench/contrib/notebook/browser/viewParts/notebookKernelQuickPickStrategy.js +2 -2
  29. package/vscode/src/vs/workbench/contrib/terminal/browser/terminalIcon.js +1 -5
  30. package/vscode/src/vs/workbench/services/extensionManagement/common/extensionManagement.service.d.ts +2 -1
package/api.js CHANGED
@@ -29,7 +29,7 @@ function createProxy(key) {
29
29
  });
30
30
  }
31
31
  const api = {
32
- version: "1.89.0",
32
+ version: "1.89.1",
33
33
  tasks: createProxy('tasks'),
34
34
  notebooks: createProxy('notebooks'),
35
35
  scm: createProxy('scm'),
package/lifecycle.js CHANGED
@@ -33,6 +33,10 @@ async function startup(instantiationService) {
33
33
  await instantiationService.invokeFunction(async (accessor) => {
34
34
  await Promise.all(( serviceInitializePreParticipants.map(participant => participant(accessor))));
35
35
  });
36
+ await instantiationService.invokeFunction(async (accessor) => {
37
+ setHoverDelegateFactory((placement, enableInstantHover) => instantiationService.createInstance(WorkbenchHoverDelegate, placement, enableInstantHover, {}));
38
+ setBaseLayerHoverDelegate(accessor.get(IHoverService));
39
+ });
36
40
  await instantiationService.invokeFunction(async (accessor) => {
37
41
  const lifecycleService = accessor.get(ILifecycleService);
38
42
  await Promise.all(( serviceInitializeParticipants.map(participant => participant(accessor))));
@@ -45,8 +49,6 @@ async function startup(instantiationService) {
45
49
  serviceInitializedEmitter.fire();
46
50
  void instantiationService.invokeFunction(async (accessor) => {
47
51
  const lifecycleService = accessor.get(ILifecycleService);
48
- setHoverDelegateFactory((placement, enableInstantHover) => instantiationService.createInstance(WorkbenchHoverDelegate, placement, enableInstantHover, {}));
49
- setBaseLayerHoverDelegate(accessor.get(IHoverService));
50
52
  ( Registry.as(Extensions.Workbench)).start(accessor);
51
53
  ( Registry.as(EditorExtensions.EditorFactory)).start(accessor);
52
54
  layoutEmitter.fire(accessor);
@@ -205,6 +205,7 @@ import { IWorkspaceIdentityService } from './vscode/src/vs/workbench/services/wo
205
205
  import { NullExtensionService } from './vscode/src/vs/workbench/services/extensions/common/extensions.js';
206
206
  import { toUserDataProfile } from './vscode/src/vs/platform/userDataProfile/common/userDataProfile.js';
207
207
  import { ILanguageModelStatsService } from './vscode/src/vs/workbench/contrib/chat/common/languageModelStats.service.js';
208
+ import { IAccessibleViewInformationService } from './vscode/src/vs/workbench/services/accessibility/common/accessibleViewInformationService.service.js';
208
209
  import { getExtensionIdProvidingCurrentLocale, getBuiltInExtensionTranslationsUris } from './l10n.js';
209
210
  import { unsupported } from './tools.js';
210
211
  var _a;
@@ -573,8 +574,8 @@ registerSingleton(IPathService, class PathService {
573
574
  registerSingleton(IProductService, class ProductService {
574
575
  constructor() {
575
576
  this._serviceBrand = undefined;
576
- this.version = "1.89.0";
577
- this.commit = "9645520c4ae4961f1e927dca9b291f786f11013e";
577
+ this.version = "1.89.1";
578
+ this.commit = "dc96b837cf6bb4af9cd736aa3af08cf8279f7685";
578
579
  this.quality = 'oss';
579
580
  this.nameShort = 'Code - OSS Dev';
580
581
  this.nameLong = 'Code - OSS Dev';
@@ -2201,6 +2202,11 @@ registerSingleton(IAccessibleViewService, class AccessibleViewService {
2201
2202
  this.getLastPosition = unsupported;
2202
2203
  }
2203
2204
  }, 1 );
2205
+ registerSingleton(IAccessibleViewInformationService, class AccessibleViewInformationService {
2206
+ constructor() {
2207
+ this.hasShownAccessibleView = () => false;
2208
+ }
2209
+ }, 1 );
2204
2210
  registerSingleton(IWorkbenchExtensionManagementService, class WorkbenchExtensionManagementService {
2205
2211
  constructor() {
2206
2212
  this.onDidEnableExtensions = Event.None;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@codingame/monaco-vscode-api",
3
- "version": "5.0.1",
3
+ "version": "5.1.1",
4
4
  "description": "VSCode public API plugged on the monaco editor",
5
5
  "keywords": [],
6
6
  "author": {
@@ -99,12 +99,12 @@
99
99
  "dependencies": {
100
100
  "@vscode/iconv-lite-umd": "0.7.0",
101
101
  "jschardet": "3.0.0",
102
- "@codingame/monaco-vscode-extensions-service-override": "5.0.1",
103
- "@codingame/monaco-vscode-files-service-override": "5.0.1",
104
- "@codingame/monaco-vscode-quickaccess-service-override": "5.0.1",
105
- "@codingame/monaco-vscode-environment-service-override": "5.0.1",
106
- "@codingame/monaco-vscode-layout-service-override": "5.0.1",
107
- "@codingame/monaco-vscode-host-service-override": "5.0.1",
108
- "@codingame/monaco-vscode-base-service-override": "5.0.1"
102
+ "@codingame/monaco-vscode-files-service-override": "5.1.1",
103
+ "@codingame/monaco-vscode-extensions-service-override": "5.1.1",
104
+ "@codingame/monaco-vscode-quickaccess-service-override": "5.1.1",
105
+ "@codingame/monaco-vscode-environment-service-override": "5.1.1",
106
+ "@codingame/monaco-vscode-layout-service-override": "5.1.1",
107
+ "@codingame/monaco-vscode-host-service-override": "5.1.1",
108
+ "@codingame/monaco-vscode-base-service-override": "5.1.1"
109
109
  }
110
110
  }
@@ -55,6 +55,7 @@ declare class RegisteredFileSystemProvider extends Disposable implements IFileSy
55
55
  onDidChangeCapabilities: Event<any>;
56
56
  _onDidChangeFile: Emitter<readonly IFileChange[]>;
57
57
  onDidChangeFile: Event<readonly IFileChange[]>;
58
+ private formatUri;
58
59
  registerFile(file: RegisteredFile): IDisposable;
59
60
  stat(resource: URI): Promise<IStat>;
60
61
  readdir(resource: URI): Promise<[string, FileType][]>;
@@ -499,7 +499,7 @@ let MonacoDelegateEditorGroupsService = class MonacoDelegateEditorGroupsService
499
499
  this._onDidChangeActiveGroup.fire(this.activeGroup);
500
500
  }
501
501
  };
502
- const remoteActiveGroup = (editor) => {
502
+ const removeActiveGroup = (editor) => {
503
503
  if (!emptyDelegate && this.activeGroupOverride === this.additionalGroups.find(group => group.editor === editor)) {
504
504
  updateActiveGroup(undefined);
505
505
  }
@@ -514,11 +514,11 @@ let MonacoDelegateEditorGroupsService = class MonacoDelegateEditorGroupsService
514
514
  window.clearTimeout(timeout);
515
515
  timeout = window.setTimeout(() => {
516
516
  timeout = undefined;
517
- remoteActiveGroup(editor);
517
+ removeActiveGroup(editor);
518
518
  }, 100);
519
519
  };
520
520
  editor.onDidDispose(() => {
521
- remoteActiveGroup(editor);
521
+ removeActiveGroup(editor);
522
522
  });
523
523
  editor.onDidFocusEditorText(onEditorFocused);
524
524
  editor.onDidFocusEditorWidget(onEditorFocused);
@@ -7,7 +7,7 @@ import { Event } from '../../vscode/src/vs/base/common/event.js';
7
7
  import { DomScrollableElement } from '../../vscode/src/vs/base/browser/ui/scrollbar/scrollableElement.js';
8
8
  import { CancellationToken } from '../../vscode/src/vs/base/common/cancellation.js';
9
9
  import { URI } from '../../vscode/src/vs/base/common/uri.js';
10
- import { IEditorOptions } from '../../vscode/src/vs/platform/editor/common/editor.js';
10
+ import { IEditorOptions, IResourceEditorInput } from '../../vscode/src/vs/platform/editor/common/editor.js';
11
11
  import { Parts, Position } from '../../vscode/src/vs/workbench/services/layout/browser/layoutService.js';
12
12
  import { Codicon } from '../../vscode/src/vs/base/common/codicons.js';
13
13
  import { RegisteredEditorInfo, RegisteredEditorOptions, EditorInputFactoryObject } from '../../vscode/src/vs/workbench/services/editor/common/editorResolverService.js';
@@ -61,6 +61,7 @@ declare abstract class SimpleEditorInput extends EditorInput {
61
61
  getDescription(verbosity?: Verbosity): string;
62
62
  isDirty(): boolean;
63
63
  setDirty(dirty: boolean): void;
64
+ toUntyped(): IResourceEditorInput | undefined;
64
65
  }
65
66
  declare function registerEditorPane<Services extends BrandedService[]>(typeId: string, name: string, ctor: new (group: IEditorGroup, ...services: Services) => EditorPane, inputCtors: (new (...args: any[]) => EditorInput)[]): IDisposable;
66
67
  declare function registerEditor(globPattern: string, editorInfo: RegisteredEditorInfo, editorOptions: RegisteredEditorOptions, factory: EditorInputFactoryObject): IDisposable;
@@ -144,6 +144,14 @@ class SimpleEditorInput extends EditorInput {
144
144
  this.dirty = dirty;
145
145
  this._onDidChangeDirty.fire();
146
146
  }
147
+ toUntyped() {
148
+ if (this.resource == null) {
149
+ return undefined;
150
+ }
151
+ return {
152
+ resource: this.resource
153
+ };
154
+ }
147
155
  }
148
156
  function registerEditorPane(typeId, name, ctor, inputCtors) {
149
157
  return ( Registry.as(EditorExtensions.EditorPane)).registerEditorPane(EditorPaneDescriptor.create(ctor, typeId, name), ( inputCtors.map(ctor => new SyncDescriptor(ctor))));
package/services.js CHANGED
@@ -183,9 +183,9 @@ async function initialize(overrides, container = document.body, configuration =
183
183
  initialize$1(container, configuration, env);
184
184
  const instantiationService = StandaloneServices.initialize({
185
185
  [( IProductService.toString())]: mixin({
186
- version: "1.89.0",
186
+ version: "1.89.1",
187
187
  quality: 'stable',
188
- commit: "9645520c4ae4961f1e927dca9b291f786f11013e",
188
+ commit: "dc96b837cf6bb4af9cd736aa3af08cf8279f7685",
189
189
  nameShort: 'Code - OSS',
190
190
  nameLong: 'Code - OSS',
191
191
  applicationName: 'code-oss',
@@ -427,16 +427,16 @@ function size(element, width, height) {
427
427
  }
428
428
  }
429
429
  function position(element, top, right, bottom, left, position = 'absolute') {
430
- if (typeof top === 'number') {
430
+ {
431
431
  element.style.top = `${top}px`;
432
432
  }
433
- if (typeof right === 'number') {
433
+ {
434
434
  element.style.right = `${right}px`;
435
435
  }
436
- if (typeof bottom === 'number') {
436
+ {
437
437
  element.style.bottom = `${bottom}px`;
438
438
  }
439
- if (typeof left === 'number') {
439
+ {
440
440
  element.style.left = `${left}px`;
441
441
  }
442
442
  element.style.position = position;
@@ -200,24 +200,16 @@ function fromNow(date, appendAgoLabel, useFullTimeWords, disallowNow) {
200
200
  function getDurationString(ms, useFullTimeWords) {
201
201
  const seconds = Math.abs(ms / 1000);
202
202
  if (seconds < 1) {
203
- return useFullTimeWords
204
- ? ( localizeWithPath(_moduleId, 54, '{0} milliseconds', ms))
205
- : ( localizeWithPath(_moduleId, 55, '{0}ms', ms));
203
+ return ( localizeWithPath(_moduleId, 55, '{0}ms', ms));
206
204
  }
207
205
  if (seconds < minute) {
208
- return useFullTimeWords
209
- ? ( localizeWithPath(_moduleId, 56, '{0} seconds', Math.round(ms) / 1000))
210
- : ( localizeWithPath(_moduleId, 57, '{0}s', Math.round(ms) / 1000));
206
+ return ( localizeWithPath(_moduleId, 57, '{0}s', Math.round(ms) / 1000));
211
207
  }
212
208
  if (seconds < hour) {
213
- return useFullTimeWords
214
- ? ( localizeWithPath(_moduleId, 58, '{0} minutes', Math.round(ms / (1000 * minute))))
215
- : ( localizeWithPath(_moduleId, 59, '{0} mins', Math.round(ms / (1000 * minute))));
209
+ return ( localizeWithPath(_moduleId, 59, '{0} mins', Math.round(ms / (1000 * minute))));
216
210
  }
217
211
  if (seconds < day) {
218
- return useFullTimeWords
219
- ? ( localizeWithPath(_moduleId, 60, '{0} hours', Math.round(ms / (1000 * hour))))
220
- : ( localizeWithPath(_moduleId, 61, '{0} hrs', Math.round(ms / (1000 * hour))));
212
+ return ( localizeWithPath(_moduleId, 61, '{0} hrs', Math.round(ms / (1000 * hour))));
221
213
  }
222
214
  return ( localizeWithPath(_moduleId, 62, '{0} days', Math.round(ms / (1000 * day))));
223
215
  }
@@ -52,16 +52,12 @@ function debounce(delay, reducer, initialValueProvider) {
52
52
  const resultKey = `$debounce$result$${key}`;
53
53
  return function (...args) {
54
54
  if (!this[resultKey]) {
55
- this[resultKey] = initialValueProvider ? initialValueProvider() : undefined;
55
+ this[resultKey] = undefined;
56
56
  }
57
57
  clearTimeout(this[timerKey]);
58
- if (reducer) {
59
- this[resultKey] = reducer(this[resultKey], ...args);
60
- args = [this[resultKey]];
61
- }
62
58
  this[timerKey] = setTimeout(() => {
63
59
  fn.apply(this, args);
64
- this[resultKey] = initialValueProvider ? initialValueProvider() : undefined;
60
+ this[resultKey] = undefined;
65
61
  }, delay);
66
62
  };
67
63
  }));
@@ -1,4 +1,4 @@
1
- import { join, posix, sep } from './path.js';
1
+ import { posix, sep } from './path.js';
2
2
  import { isWindows } from './platform.js';
3
3
  import { equalsIgnoreCase, startsWithIgnoreCase } from './strings.js';
4
4
  import { isNumber } from './types.js';
@@ -233,15 +233,9 @@ function randomPath(parent, prefix, randomLength = 8) {
233
233
  suffix += pathCharsTouse.charAt(Math.floor(Math.random() * pathCharsTouse.length));
234
234
  }
235
235
  let randomFileName;
236
- if (prefix) {
237
- randomFileName = `${prefix}-${suffix}`;
238
- }
239
- else {
236
+ {
240
237
  randomFileName = suffix;
241
238
  }
242
- if (parent) {
243
- return join(parent, randomFileName);
244
- }
245
239
  return randomFileName;
246
240
  }
247
241
  export { getDriveLetter, getRoot, hasDriveLetter, indexOfPath, isEqual, isEqualOrParent, isPathSeparator, isUNC, isValidBasename, isWindowsDriveLetter, parseLineAndColumnAware, randomPath, toPosixPath, toSlashes };
@@ -62,7 +62,7 @@ function setProperty(text, originalPath, value, formattingOptions, getInsertionI
62
62
  return [];
63
63
  }
64
64
  const newProperty = `${JSON.stringify(lastSegment)}: ${JSON.stringify(value)}`;
65
- const index = getInsertionIndex ? getInsertionIndex(( parent.children.map(p => p.children[0].value))) : parent.children.length;
65
+ const index = parent.children.length;
66
66
  let edit;
67
67
  if (index > 0) {
68
68
  const previous = parent.children[index - 1];
@@ -43,7 +43,7 @@ class EditorScrollbar extends ViewPart {
43
43
  this._setLayout();
44
44
  const onBrowserDesperateReveal = (domNode, lookAtScrollTop, lookAtScrollLeft) => {
45
45
  const newScrollPosition = {};
46
- if (lookAtScrollTop) {
46
+ {
47
47
  const deltaTop = domNode.scrollTop;
48
48
  if (deltaTop) {
49
49
  newScrollPosition.scrollTop = this._context.viewLayout.getCurrentScrollTop() + deltaTop;
@@ -1,7 +1,7 @@
1
1
  import { BugIndicatingError } from '../../../base/common/errors.js';
2
2
  import { OffsetRange } from './offsetRange.js';
3
3
  import { Range } from './range.js';
4
- import { findFirstIdxMonotonousOrArrLen, findLastIdxMonotonous, findLastMonotonous } from '../../../base/common/arraysFind.js';
4
+ import { findFirstIdxMonotonousOrArrLen, findLastMonotonous, findLastIdxMonotonous } from '../../../base/common/arraysFind.js';
5
5
  class LineRange {
6
6
  static fromRange(range) {
7
7
  return ( new LineRange(range.startLineNumber, range.endLineNumber));
@@ -38,19 +38,7 @@ function getReindentEditOperations(model, languageConfigurationService, startLin
38
38
  let globalIndent;
39
39
  const currentLineText = model.getLineContent(startLineNumber);
40
40
  let adjustedLineContent = currentLineText;
41
- if (inheritedIndent !== undefined && inheritedIndent !== null) {
42
- globalIndent = inheritedIndent;
43
- const oldIndentation = getLeadingWhitespace(currentLineText);
44
- adjustedLineContent = globalIndent + currentLineText.substring(oldIndentation.length);
45
- if (indentationRules.decreaseIndentPattern && indentationRules.decreaseIndentPattern.test(adjustedLineContent)) {
46
- globalIndent = unshiftIndent(globalIndent);
47
- adjustedLineContent = globalIndent + currentLineText.substring(oldIndentation.length);
48
- }
49
- if (currentLineText !== adjustedLineContent) {
50
- indentEdits.push(EditOperation.replaceMove(( new Selection(startLineNumber, 1, startLineNumber, oldIndentation.length + 1)), normalizeIndentation(globalIndent, indentSize, insertSpaces)));
51
- }
52
- }
53
- else {
41
+ {
54
42
  globalIndent = getLeadingWhitespace(currentLineText);
55
43
  }
56
44
  let idealIndentForNextLine = globalIndent;
@@ -7,12 +7,12 @@ const pinnedButtonClass = ThemeIcon.asClassName(Codicon.pinned);
7
7
  const buttonClasses = [pinButtonClass, pinnedButtonClass];
8
8
  async function showWithPinnedItems(storageService, storageKey, quickPick, filterDuplicates) {
9
9
  const itemsWithoutPinned = quickPick.items;
10
- let itemsWithPinned = _formatPinnedItems(storageKey, quickPick, storageService, undefined, filterDuplicates);
10
+ let itemsWithPinned = _formatPinnedItems(storageKey, quickPick, storageService, undefined);
11
11
  quickPick.onDidTriggerItemButton(async (buttonEvent) => {
12
12
  const expectedButton = buttonEvent.button.iconClass && buttonClasses.includes(buttonEvent.button.iconClass);
13
13
  if (expectedButton) {
14
14
  quickPick.items = itemsWithoutPinned;
15
- itemsWithPinned = _formatPinnedItems(storageKey, quickPick, storageService, buttonEvent.item, filterDuplicates);
15
+ itemsWithPinned = _formatPinnedItems(storageKey, quickPick, storageService, buttonEvent.item);
16
16
  quickPick.items = quickPick.value ? itemsWithoutPinned : itemsWithPinned;
17
17
  }
18
18
  });
@@ -45,7 +45,7 @@ function _formatPinnedItems(storageKey, quickPick, storageService, changedItem,
45
45
  if (itemToPin) {
46
46
  const pinnedItemId = getItemIdentifier(itemToPin);
47
47
  const pinnedItem = Object.assign({}, itemToPin);
48
- if (!filterDuplicates || !( (pinnedIds.has(pinnedItemId)))) {
48
+ if (!( (pinnedIds.has(pinnedItemId)))) {
49
49
  pinnedIds.add(pinnedItemId);
50
50
  updateButtons(pinnedItem, false);
51
51
  formattedItems.push(pinnedItem);
@@ -15,7 +15,6 @@ function isEmptyWorkspaceIdentifier(obj) {
15
15
  && !isSingleFolderWorkspaceIdentifier(obj)
16
16
  && !isWorkspaceIdentifier(obj);
17
17
  }
18
- const EXTENSION_DEVELOPMENT_EMPTY_WINDOW_WORKSPACE = { id: 'ext-dev' };
19
18
  const UNKNOWN_EMPTY_WINDOW_WORKSPACE = { id: 'empty-window' };
20
19
  function toWorkspaceIdentifier(arg0, isExtensionDevelopment) {
21
20
  if (typeof arg0 === 'string' || typeof arg0 === 'undefined') {
@@ -24,9 +23,6 @@ function toWorkspaceIdentifier(arg0, isExtensionDevelopment) {
24
23
  id: basename(arg0)
25
24
  };
26
25
  }
27
- if (isExtensionDevelopment) {
28
- return EXTENSION_DEVELOPMENT_EMPTY_WINDOW_WORKSPACE;
29
- }
30
26
  return UNKNOWN_EMPTY_WINDOW_WORKSPACE;
31
27
  }
32
28
  const workspace = arg0;
@@ -165,4 +161,4 @@ function hasWorkspaceFileExtension(path) {
165
161
  const ext = (typeof path === 'string') ? extname(path) : extname$1(path);
166
162
  return ext === WORKSPACE_SUFFIX;
167
163
  }
168
- export { EXTENSION_DEVELOPMENT_EMPTY_WINDOW_WORKSPACE, STANDALONE_EDITOR_WORKSPACE_ID, UNKNOWN_EMPTY_WINDOW_WORKSPACE, UNTITLED_WORKSPACE_NAME, WORKSPACE_EXTENSION, WORKSPACE_FILTER, WORKSPACE_SUFFIX, Workspace$1 as Workspace, WorkspaceFolder, hasWorkspaceFileExtension, isEmptyWorkspaceIdentifier, isSavedWorkspace, isSingleFolderWorkspaceIdentifier, isStandaloneEditorWorkspace, isTemporaryWorkspace, isUntitledWorkspace, isWorkspace, isWorkspaceFolder, isWorkspaceIdentifier, toWorkspaceFolder, toWorkspaceIdentifier };
164
+ export { STANDALONE_EDITOR_WORKSPACE_ID, UNKNOWN_EMPTY_WINDOW_WORKSPACE, UNTITLED_WORKSPACE_NAME, WORKSPACE_EXTENSION, WORKSPACE_FILTER, WORKSPACE_SUFFIX, Workspace$1 as Workspace, WorkspaceFolder, hasWorkspaceFileExtension, isEmptyWorkspaceIdentifier, isSavedWorkspace, isSingleFolderWorkspaceIdentifier, isStandaloneEditorWorkspace, isTemporaryWorkspace, isUntitledWorkspace, isWorkspace, isWorkspaceFolder, isWorkspaceIdentifier, toWorkspaceFolder, toWorkspaceIdentifier };
@@ -281,6 +281,9 @@ let AbstractTreeView = class AbstractTreeView extends Disposable {
281
281
  }
282
282
  set dataProvider(dataProvider) {
283
283
  if (dataProvider) {
284
+ if (this.visible) {
285
+ this.activate();
286
+ }
284
287
  const self = this;
285
288
  this._dataProvider = new (class {
286
289
  constructor() {
@@ -647,9 +647,6 @@ CommentNode = ( (__decorate([
647
647
  function fillInActions(groups, target, useAlternativeActions, isPrimaryGroup = group => group === 'navigation') {
648
648
  for (const tuple of groups) {
649
649
  let [group, actions] = tuple;
650
- if (useAlternativeActions) {
651
- actions = ( (actions.map(a => (a instanceof MenuItemAction) && !!a.alt ? a.alt : a)));
652
- }
653
650
  if (isPrimaryGroup(group)) {
654
651
  const to = Array.isArray(target) ? target : target.primary;
655
652
  to.unshift(...actions);
@@ -19,7 +19,7 @@ import { IQuickInputService } from '../../../../platform/quickinput/common/quick
19
19
  import { CommentGlyphWidget } from './commentGlyphWidget.js';
20
20
  import { ICommentService } from './commentService.service.js';
21
21
  import { CommentWidgetFocus, ReviewZoneWidget, parseMouseDownInfoFromEvent, isMouseUpEventDragFromMouseDown } from './commentThreadZoneWidget.js';
22
- import { SIDE_GROUP, ACTIVE_GROUP } from '../../../services/editor/common/editorService.js';
22
+ import { ACTIVE_GROUP, SIDE_GROUP } from '../../../services/editor/common/editorService.js';
23
23
  import { IEditorService } from '../../../services/editor/common/editorService.service.js';
24
24
  import { EmbeddedCodeEditorWidget } from '../../../../editor/browser/widget/codeEditor/embeddedCodeEditorWidget.js';
25
25
  import { IViewsService } from '../../../services/views/common/viewsService.service.js';
@@ -599,7 +599,7 @@ const getUriForDebugMemory = (sessionId, memoryReference, range, displayName = '
599
599
  scheme: DEBUG_MEMORY_SCHEME,
600
600
  authority: sessionId,
601
601
  path: '/' + encodeURIComponent(memoryReference) + `/${encodeURIComponent(displayName)}.bin`,
602
- query: range ? `?range=${range.fromOffset}:${range.toOffset}` : undefined,
602
+ query: undefined,
603
603
  }))
604
604
  );
605
605
  };
@@ -9,9 +9,6 @@ import { coalesce } from '../../../../base/common/arrays.js';
9
9
  const _formatPIIRegexp = /{([^}]+)}/g;
10
10
  function formatPII(value, excludePII, args) {
11
11
  return value.replace(_formatPIIRegexp, function (match, group) {
12
- if (excludePII && group.length > 0 && group[0] !== '_') {
13
- return match;
14
- }
15
12
  return args && args.hasOwnProperty(group) ?
16
13
  args[group] :
17
14
  match;
@@ -341,17 +341,8 @@ async function joinNotebookCells(editor, range, direction, constraint) {
341
341
  if (range.end === textModel.length && direction === 'below') {
342
342
  return null;
343
343
  }
344
- for (let i = 0; i < cells.length; i++) {
345
- const cell = cells[i];
346
- if (constraint && cell.cellKind !== constraint) {
347
- return null;
348
- }
349
- }
350
344
  if (direction === 'above') {
351
345
  const above = editor.cellAt(range.start - 1);
352
- if (constraint && above.cellKind !== constraint) {
353
- return null;
354
- }
355
346
  const insertContent = ( (cells.map(cell => (cell.textBuffer.getEOL() ?? '') + cell.getText()))).join('');
356
347
  const aboveCellLineCount = above.textBuffer.getLineCount();
357
348
  const aboveCellLastLineEndColumn = above.textBuffer.getLineLength(aboveCellLineCount);
@@ -377,9 +368,6 @@ async function joinNotebookCells(editor, range, direction, constraint) {
377
368
  }
378
369
  else {
379
370
  const below = editor.cellAt(range.end);
380
- if (constraint && below.cellKind !== constraint) {
381
- return null;
382
- }
383
371
  const cell = cells[0];
384
372
  const restCells = [...cells.slice(1), below];
385
373
  const insertContent = ( (restCells.map(cl => (cl.textBuffer.getEOL() ?? '') + cl.getText()))).join('');
@@ -560,7 +548,7 @@ function insertCell(languageService, editor, index, type, direction = 'above', i
560
548
  const insertIndex = cell ?
561
549
  (direction === 'above' ? index : nextIndex) :
562
550
  index;
563
- return insertCellAtIndex(viewModel, insertIndex, initialText, language, type, undefined, [], true, true);
551
+ return insertCellAtIndex(viewModel, insertIndex, initialText, language, type, undefined, [], true);
564
552
  }
565
553
  function insertCellAtIndex(viewModel, index, source, language, type, metadata, outputs, synchronous, pushUndoStop) {
566
554
  const endSelections = { kind: SelectionStateType.Index, focus: { start: index, end: index + 1 }, selections: [{ start: index, end: index + 1 }] };
@@ -580,7 +568,7 @@ function insertCellAtIndex(viewModel, index, source, language, type, metadata, o
580
568
  }
581
569
  ]
582
570
  }
583
- ], synchronous, { kind: SelectionStateType.Index, focus: viewModel.getFocus(), selections: viewModel.getSelections() }, () => endSelections, undefined, pushUndoStop && !viewModel.options.isReadOnly);
571
+ ], synchronous, { kind: SelectionStateType.Index, focus: viewModel.getFocus(), selections: viewModel.getSelections() }, () => endSelections, undefined, !viewModel.options.isReadOnly);
584
572
  return viewModel.cellAt(index);
585
573
  }
586
574
  export { changeCellToKind, computeCellLinesContents, copyCellRange, insertCell, insertCellAtIndex, joinCellsWithSurrounds, joinNotebookCells, joinSelectedCells, moveCellRange, runDeleteAction };
@@ -227,7 +227,7 @@ function createDeleteToolbar(accessor, container, hoverDelegate, elementClass) {
227
227
  renderDropdownAsChildElement: true,
228
228
  hoverDelegate
229
229
  }));
230
- if (elementClass) {
230
+ {
231
231
  toolbar.getElement().classList.add(elementClass);
232
232
  }
233
233
  return toolbar;
@@ -586,23 +586,8 @@ async function webviewPreloads(ctx) {
586
586
  update: updateHighlights
587
587
  };
588
588
  }
589
- function selectRange(_range) {
590
- const sel = window.getSelection();
591
- if (sel) {
592
- try {
593
- sel.removeAllRanges();
594
- const r = document.createRange();
595
- r.setStart(_range.startContainer, _range.startOffset);
596
- r.setEnd(_range.endContainer, _range.endOffset);
597
- sel.addRange(r);
598
- }
599
- catch (e) {
600
- console.log(e);
601
- }
602
- }
603
- }
604
589
  function highlightRange(range, useCustom, tagName = 'mark', attributes = {}) {
605
- if (useCustom) {
590
+ {
606
591
  const ret = _internalHighlightRange(range, tagName, attributes);
607
592
  return {
608
593
  range: range,
@@ -621,46 +606,6 @@ async function webviewPreloads(ctx) {
621
606
  }
622
607
  };
623
608
  }
624
- else {
625
- window.document.execCommand('hiliteColor', false, matchColor);
626
- const cloneRange = window.getSelection().getRangeAt(0).cloneRange();
627
- const _range = {
628
- collapsed: cloneRange.collapsed,
629
- commonAncestorContainer: cloneRange.commonAncestorContainer,
630
- endContainer: cloneRange.endContainer,
631
- endOffset: cloneRange.endOffset,
632
- startContainer: cloneRange.startContainer,
633
- startOffset: cloneRange.startOffset
634
- };
635
- return {
636
- range: _range,
637
- dispose: () => {
638
- selectRange(_range);
639
- try {
640
- document.designMode = 'On';
641
- window.document.execCommand('removeFormat', false, undefined);
642
- document.designMode = 'Off';
643
- window.getSelection()?.removeAllRanges();
644
- }
645
- catch (e) {
646
- console.log(e);
647
- }
648
- },
649
- update: (color, className) => {
650
- selectRange(_range);
651
- try {
652
- document.designMode = 'On';
653
- window.document.execCommand('removeFormat', false, undefined);
654
- window.document.execCommand('hiliteColor', false, color);
655
- document.designMode = 'Off';
656
- window.getSelection()?.removeAllRanges();
657
- }
658
- catch (e) {
659
- console.log(e);
660
- }
661
- }
662
- };
663
- }
664
609
  }
665
610
  function createEmitter(listenerChange = () => undefined) {
666
611
  const listeners = ( new Set());
@@ -554,12 +554,12 @@ let KernelPickerMRUStrategy = class KernelPickerMRUStrategy extends KernelPicker
554
554
  const runningActions = notebookKernelService.getRunningSourceActions(notebook);
555
555
  const updateActionFromSourceAction = (sourceAction, running) => {
556
556
  const sAction = sourceAction.action;
557
- action.class = running ? ThemeIcon.asClassName(ThemeIcon.modify(executingStateIcon, 'spin')) : ThemeIcon.asClassName(selectKernelIcon);
557
+ action.class = ThemeIcon.asClassName(ThemeIcon.modify(executingStateIcon, 'spin')) ;
558
558
  action.label = sAction.label;
559
559
  action.enabled = true;
560
560
  };
561
561
  if (runningActions.length) {
562
- return updateActionFromSourceAction(runningActions[0] , true);
562
+ return updateActionFromSourceAction(runningActions[0] );
563
563
  }
564
564
  const { selected } = notebookKernelHistoryService.getKernels(notebook);
565
565
  if (selected) {
@@ -56,15 +56,11 @@ function getColorStyleContent(colorTheme, editor) {
56
56
  const colorClass = getColorClass(colorKey);
57
57
  const color = colorTheme.getColor(colorKey);
58
58
  if (color) {
59
- if (editor) {
59
+ {
60
60
  css += (`.monaco-workbench .show-file-icons .predefined-file-icon.terminal-tab.${colorClass}::before,` +
61
61
  `.monaco-workbench .show-file-icons .file-icon.terminal-tab.${colorClass}::before` +
62
62
  `{ color: ${color} !important; }`);
63
63
  }
64
- else {
65
- css += (`.monaco-workbench .${colorClass} .codicon:first-child:not(.codicon-split-horizontal):not(.codicon-trashcan):not(.file-icon)` +
66
- `{ color: ${color} !important; }`);
67
- }
68
64
  }
69
65
  }
70
66
  return css;
@@ -4,7 +4,7 @@ import { IExtensionManagementService } from '../../../../platform/extensionManag
4
4
  import { InstallExtensionOnServerEvent, UninstallExtensionOnServerEvent, DidUninstallExtensionOnServerEvent, DidChangeProfileForServerEvent, IResourceExtension, EnablementState, ScanOptions, IScannedExtension, DidChangeProfileEvent } from './extensionManagement.js';
5
5
  import { IExtension, IExtensionManifest, ExtensionType } from '../../../../platform/extensions/common/extensions.js';
6
6
  import { URI } from '../../../../base/common/uri.js';
7
- import { InstallExtensionResult, ILocalExtension, InstallOptions, IGalleryExtension, Metadata } from '../../../../platform/extensionManagement/common/extensionManagement.js';
7
+ import { InstallExtensionResult, ILocalExtension, IGalleryExtension, InstallOptions, Metadata } from '../../../../platform/extensionManagement/common/extensionManagement.js';
8
8
 
9
9
  declare const IProfileAwareExtensionManagementService: ServiceIdentifier<IProfileAwareExtensionManagementService>;
10
10
  interface IProfileAwareExtensionManagementService extends IExtensionManagementService {
@@ -21,6 +21,7 @@ interface IWorkbenchExtensionManagementService extends IProfileAwareExtensionMan
21
21
  onDidEnableExtensions: Event<IExtension[]>;
22
22
  getExtensions(locations: URI[]): Promise<IResourceExtension[]>;
23
23
  getInstalledWorkspaceExtensions(includeInvalid: boolean): Promise<ILocalExtension[]>;
24
+ canInstall(extension: IGalleryExtension | IResourceExtension): Promise<boolean>;
24
25
  installVSIX(location: URI, manifest: IExtensionManifest, installOptions?: InstallOptions): Promise<ILocalExtension>;
25
26
  installFromLocation(location: URI): Promise<ILocalExtension>;
26
27
  installResourceExtension(extension: IResourceExtension, installOptions: InstallOptions): Promise<ILocalExtension>;