@codingame/monaco-vscode-view-common-service-override 15.0.2 → 16.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. package/assets/{index-no-csp.html → webview/index-no-csp.html} +1 -1
  2. package/assets/{index.html → webview/index.html} +2 -2
  3. package/index.js +5 -5
  4. package/package.json +42 -40
  5. package/vscode/src/vs/platform/webview/common/webviewPortMapping.d.ts +1 -1
  6. package/vscode/src/vs/workbench/api/browser/viewsExtensionPoint.js +60 -60
  7. package/vscode/src/vs/workbench/browser/actions/listCommands.js +3 -3
  8. package/vscode/src/vs/workbench/browser/actions/navigationActions.js +7 -7
  9. package/vscode/src/vs/workbench/browser/parts/editor/editor.contribution.js +162 -159
  10. package/vscode/src/vs/workbench/browser/parts/editor/editorConfiguration.js +10 -9
  11. package/vscode/src/vs/workbench/contrib/callHierarchy/browser/callHierarchy.contribution.js +12 -12
  12. package/vscode/src/vs/workbench/contrib/callHierarchy/browser/callHierarchyPeek.js +7 -7
  13. package/vscode/src/vs/workbench/contrib/callHierarchy/browser/callHierarchyTree.js +3 -3
  14. package/vscode/src/vs/workbench/contrib/callHierarchy/browser/media/callHierarchy.css +47 -0
  15. package/vscode/src/vs/workbench/contrib/customEditor/browser/customEditors.js +1 -1
  16. package/vscode/src/vs/workbench/contrib/customEditor/browser/media/customEditor.css +3 -0
  17. package/vscode/src/vs/workbench/contrib/customEditor/common/contributedCustomEditors.js +1 -1
  18. package/vscode/src/vs/workbench/contrib/customEditor/common/customEditor.js +1 -1
  19. package/vscode/src/vs/workbench/contrib/customEditor/common/extensionPoint.js +12 -12
  20. package/vscode/src/vs/workbench/contrib/externalUriOpener/common/externalUriOpener.contribution.js +1 -1
  21. package/vscode/src/vs/workbench/contrib/languageStatus/browser/languageStatus.js +8 -8
  22. package/vscode/src/vs/workbench/contrib/languageStatus/browser/media/languageStatus.css +90 -0
  23. package/vscode/src/vs/workbench/contrib/limitIndicator/browser/limitIndicator.contribution.js +8 -8
  24. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/commands/commands.js +27 -27
  25. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/commands/devCommands.js +14 -14
  26. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/mergeEditor.contribution.js +6 -3
  27. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/mergeEditorAccessibilityHelp.d.ts +10 -0
  28. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/mergeEditorAccessibilityHelp.js +46 -0
  29. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/colors.js +13 -13
  30. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/editors/baseCodeEditorView.js +3 -3
  31. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/editors/inputCodeEditorView.js +11 -11
  32. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/editors/resultCodeEditorView.js +5 -5
  33. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/media/mergeEditor.css +235 -0
  34. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/mergeEditor.d.ts +1 -6
  35. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/mergeEditor.js +18 -25
  36. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/viewModel.js +1 -1
  37. package/vscode/src/vs/workbench/contrib/preferences/browser/keyboardLayoutPicker.js +12 -12
  38. package/vscode/src/vs/workbench/contrib/sash/browser/sash.contribution.js +2 -2
  39. package/vscode/src/vs/workbench/contrib/typeHierarchy/browser/media/typeHierarchy.css +47 -0
  40. package/vscode/src/vs/workbench/contrib/typeHierarchy/browser/typeHierarchy.contribution.js +10 -10
  41. package/vscode/src/vs/workbench/contrib/typeHierarchy/browser/typeHierarchyPeek.js +7 -7
  42. package/vscode/src/vs/workbench/contrib/typeHierarchy/browser/typeHierarchyTree.js +3 -3
  43. package/vscode/src/vs/workbench/contrib/webview/browser/overlayWebview.d.ts +1 -1
  44. package/{assets → vscode/src/vs/workbench/contrib/webview/browser/pre}/service-worker.js +34 -3
  45. package/vscode/src/vs/workbench/contrib/webview/browser/webviewElement.js +1 -1
  46. package/vscode/src/vs/workbench/contrib/webview/browser/webviewFindWidget.d.ts +1 -1
  47. package/vscode/src/vs/workbench/contrib/webview/browser/webviewFindWidget.js +1 -1
  48. package/vscode/src/vs/workbench/contrib/webviewPanel/browser/webviewCommands.js +5 -5
  49. package/vscode/src/vs/workbench/contrib/webviewPanel/browser/webviewPanel.contribution.js +1 -1
  50. package/vscode/src/vs/workbench/contrib/webviewView/browser/webviewViewPane.d.ts +1 -1
  51. package/vscode/src/vs/workbench/services/editor/browser/editorResolverService.d.ts +1 -4
  52. package/vscode/src/vs/workbench/services/editor/browser/editorResolverService.js +13 -22
  53. package/vscode/src/vs/workbench/services/history/browser/historyService.d.ts +0 -1
  54. package/vscode/src/vs/workbench/services/history/browser/historyService.js +29 -30
  55. package/vscode/src/vs/workbench/services/progress/browser/media/progressService.css +15 -0
  56. package/vscode/src/vs/workbench/services/progress/browser/progressService.js +29 -42
  57. package/vscode/src/vs/workbench/services/views/browser/viewDescriptorService.js +6 -6
  58. package/vscode/src/vs/workbench/contrib/callHierarchy/browser/media/callHierarchy.css.js +0 -6
  59. package/vscode/src/vs/workbench/contrib/customEditor/browser/media/customEditor.css.js +0 -6
  60. package/vscode/src/vs/workbench/contrib/languageStatus/browser/media/languageStatus.css.js +0 -6
  61. package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/media/mergeEditor.css.js +0 -6
  62. package/vscode/src/vs/workbench/contrib/typeHierarchy/browser/media/typeHierarchy.css.js +0 -6
  63. package/vscode/src/vs/workbench/services/progress/browser/media/progressService.css.js +0 -6
  64. /package/{assets → vscode/src/vs/workbench/contrib/webview/browser/pre}/fake.html +0 -0
@@ -105,14 +105,14 @@ class AccessibilityProvider {
105
105
  this.getDirection = getDirection;
106
106
  }
107
107
  getWidgetAriaLabel() {
108
- return localize(10744, "Type Hierarchy");
108
+ return localize(11066, "Type Hierarchy");
109
109
  }
110
110
  getAriaLabel(element) {
111
111
  if (this.getDirection() === TypeHierarchyDirection.Supertypes) {
112
- return localize(10745, "supertypes of {0}", element.item.name);
112
+ return localize(11067, "supertypes of {0}", element.item.name);
113
113
  }
114
114
  else {
115
- return localize(10746, "subtypes of {0}", element.item.name);
115
+ return localize(11068, "subtypes of {0}", element.item.name);
116
116
  }
117
117
  }
118
118
  }
@@ -37,7 +37,7 @@ export declare class OverlayWebview extends Disposable implements IOverlayWebvie
37
37
  get isFocused(): boolean;
38
38
  private _isDisposed;
39
39
  private readonly _onDidDispose;
40
- onDidDispose: import("@codingame/monaco-vscode-api/vscode/vs/base/common/event").Event<void>;
40
+ readonly onDidDispose: import("@codingame/monaco-vscode-api/vscode/vs/base/common/event").Event<void>;
41
41
  dispose(): void;
42
42
  get container(): HTMLElement;
43
43
  claim(owner: any, targetWindow: CodeWindow, scopedContextKeyService: IContextKeyService | undefined): void;
@@ -18,6 +18,8 @@ const searchParams = new URL(location.toString()).searchParams;
18
18
 
19
19
  const remoteAuthority = searchParams.get('remoteAuthority');
20
20
 
21
+ const ID = searchParams.get('id');
22
+
21
23
  /**
22
24
  * Origin used for resources
23
25
  */
@@ -233,12 +235,19 @@ sw.addEventListener('activate', (event) => {
233
235
  */
234
236
  async function processResourceRequest(event, requestUrlComponents) {
235
237
  const client = await sw.clients.get(event.clientId);
238
+ let webviewId;
236
239
  if (!client) {
237
- console.error('Could not find inner client for request');
238
- return notFound();
240
+ const workerClient = await getWorkerClientForId(event.clientId);
241
+ if (!workerClient) {
242
+ console.error('Could not find inner client for request');
243
+ return notFound();
244
+ } else {
245
+ webviewId = getWebviewIdForClient(workerClient);
246
+ }
247
+ } else {
248
+ webviewId = getWebviewIdForClient(client);
239
249
  }
240
250
 
241
- const webviewId = getWebviewIdForClient(client);
242
251
  if (!webviewId) {
243
252
  console.error('Could not resolve webview id');
244
253
  return notFound();
@@ -439,6 +448,15 @@ async function processLocalhostRequest(event, requestUrl) {
439
448
  * @returns {string | null}
440
449
  */
441
450
  function getWebviewIdForClient(client) {
451
+ // Refs https://github.com/microsoft/vscode/issues/244143
452
+ // With PlzDedicatedWorker, worker subresources and blob wokers
453
+ // will use clients different from the window client.
454
+ // Since we cannot different a worker main resource from a worker subresource
455
+ // we will use the global webview ID passed in at the time of
456
+ // service worker registration.
457
+ if (client.type === 'worker' || client.type === 'sharedworker') {
458
+ return ID;
459
+ }
442
460
  const requesterClientUrl = new URL(client.url);
443
461
  return requesterClientUrl.searchParams.get('id');
444
462
  }
@@ -454,3 +472,16 @@ async function getOuterIframeClient(webviewId) {
454
472
  return clientUrl.searchParams.get('id') === webviewId;
455
473
  });
456
474
  }
475
+
476
+ /**
477
+ * @param {string} clientId
478
+ * @returns {Promise<Client|undefined>}
479
+ */
480
+ async function getWorkerClientForId(clientId) {
481
+ const allDedicatedWorkerClients = await sw.clients.matchAll({ type: 'worker' });
482
+ const allSharedWorkerClients = await sw.clients.matchAll({ type: 'sharedworker' });
483
+ const allWorkerClients = [...allDedicatedWorkerClients, ...allSharedWorkerClients];
484
+ return allWorkerClients.find(client => {
485
+ return client.id === clientId;
486
+ });
487
+ }
@@ -157,7 +157,7 @@ let WebviewElement = class WebviewElement extends Disposable {
157
157
  this._hasFindResult.fire(didFind);
158
158
  }));
159
159
  this._register(this.on('fatal-error', (e) => {
160
- notificationService.error(( localize(11045, "Error loading webview: {0}", e.message)));
160
+ notificationService.error(( localize(11367, "Error loading webview: {0}", e.message)));
161
161
  this._onFatalError.fire({ message: e.message });
162
162
  }));
163
163
  this._register(this.on('did-keydown', (data) => {
@@ -4,7 +4,7 @@ import { IContextKeyService } from "@codingame/monaco-vscode-api/vscode/vs/platf
4
4
  import { IContextViewService } from "@codingame/monaco-vscode-api/vscode/vs/platform/contextview/browser/contextView.service";
5
5
  import { IHoverService } from "@codingame/monaco-vscode-api/vscode/vs/platform/hover/browser/hover.service";
6
6
  import { IKeybindingService } from "@codingame/monaco-vscode-api/vscode/vs/platform/keybinding/common/keybinding.service";
7
- import { SimpleFindWidget } from "@codingame/monaco-vscode-55ed5668-e8ca-5335-a587-790bcf1200c0-common/vscode/vs/workbench/contrib/codeEditor/browser/find/simpleFindWidget";
7
+ import { SimpleFindWidget } from "@codingame/monaco-vscode-2a94c04a-b85b-5669-b06b-89c1bfa11cb9-common/vscode/vs/workbench/contrib/codeEditor/browser/find/simpleFindWidget";
8
8
  export interface WebviewFindDelegate {
9
9
  readonly hasFindResult: Event<boolean>;
10
10
  readonly onDidStopFind: Event<void>;
@@ -4,7 +4,7 @@ import { IContextKeyService } from '@codingame/monaco-vscode-api/vscode/vs/platf
4
4
  import { IContextViewService } from '@codingame/monaco-vscode-api/vscode/vs/platform/contextview/browser/contextView.service';
5
5
  import { IHoverService } from '@codingame/monaco-vscode-api/vscode/vs/platform/hover/browser/hover.service';
6
6
  import { IKeybindingService } from '@codingame/monaco-vscode-api/vscode/vs/platform/keybinding/common/keybinding.service';
7
- import { SimpleFindWidget } from '@codingame/monaco-vscode-55ed5668-e8ca-5335-a587-790bcf1200c0-common/vscode/vs/workbench/contrib/codeEditor/browser/find/simpleFindWidget';
7
+ import { SimpleFindWidget } from '@codingame/monaco-vscode-2a94c04a-b85b-5669-b06b-89c1bfa11cb9-common/vscode/vs/workbench/contrib/codeEditor/browser/find/simpleFindWidget';
8
8
  import { KEYBINDING_CONTEXT_WEBVIEW_FIND_WIDGET_FOCUSED } from '@codingame/monaco-vscode-7ba0af96-90c2-5e11-ad7f-befdbbf246c8-common/vscode/vs/workbench/contrib/webview/browser/webview';
9
9
 
10
10
  let WebviewFindWidget = class WebviewFindWidget extends SimpleFindWidget {
@@ -15,7 +15,7 @@ import { IEditorService } from '@codingame/monaco-vscode-api/vscode/vs/workbench
15
15
  const webviewActiveContextKeyExpr = ( ContextKeyExpr.and(( ContextKeyExpr.equals('activeEditor', WebviewEditor.ID)), ( EditorContextKeys.focus.toNegated() )));
16
16
  class ShowWebViewEditorFindWidgetAction extends Action2 {
17
17
  static { this.ID = 'editor.action.webvieweditor.showFind'; }
18
- static { this.LABEL = ( localize(11046, "Show find")); }
18
+ static { this.LABEL = ( localize(11368, "Show find")); }
19
19
  constructor() {
20
20
  super({
21
21
  id: ShowWebViewEditorFindWidgetAction.ID,
@@ -36,7 +36,7 @@ class ShowWebViewEditorFindWidgetAction extends Action2 {
36
36
  }
37
37
  class HideWebViewEditorFindCommand extends Action2 {
38
38
  static { this.ID = 'editor.action.webvieweditor.hideFind'; }
39
- static { this.LABEL = ( localize(11047, "Stop find")); }
39
+ static { this.LABEL = ( localize(11369, "Stop find")); }
40
40
  constructor() {
41
41
  super({
42
42
  id: HideWebViewEditorFindCommand.ID,
@@ -57,7 +57,7 @@ class HideWebViewEditorFindCommand extends Action2 {
57
57
  }
58
58
  class WebViewEditorFindNextCommand extends Action2 {
59
59
  static { this.ID = 'editor.action.webvieweditor.findNext'; }
60
- static { this.LABEL = ( localize(11048, 'Find next')); }
60
+ static { this.LABEL = ( localize(11370, 'Find next')); }
61
61
  constructor() {
62
62
  super({
63
63
  id: WebViewEditorFindNextCommand.ID,
@@ -78,7 +78,7 @@ class WebViewEditorFindNextCommand extends Action2 {
78
78
  }
79
79
  class WebViewEditorFindPreviousCommand extends Action2 {
80
80
  static { this.ID = 'editor.action.webvieweditor.findPrevious'; }
81
- static { this.LABEL = ( localize(11049, 'Find previous')); }
81
+ static { this.LABEL = ( localize(11371, 'Find previous')); }
82
82
  constructor() {
83
83
  super({
84
84
  id: WebViewEditorFindPreviousCommand.ID,
@@ -99,7 +99,7 @@ class WebViewEditorFindPreviousCommand extends Action2 {
99
99
  }
100
100
  class ReloadWebviewAction extends Action2 {
101
101
  static { this.ID = 'workbench.action.webview.reloadWebviewAction'; }
102
- static { this.LABEL = ( localize2(11050, "Reload Webviews")); }
102
+ static { this.LABEL = ( localize2(11372, "Reload Webviews")); }
103
103
  constructor() {
104
104
  super({
105
105
  id: ReloadWebviewAction.ID,
@@ -18,7 +18,7 @@ import '@codingame/monaco-vscode-7f39b6f1-3542-5430-8760-0f404d7a7cee-common/vsc
18
18
  import '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation';
19
19
  import { IEditorService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorService.service';
20
20
 
21
- (( Registry.as(EditorExtensions.EditorPane))).registerEditorPane(EditorPaneDescriptor.create(WebviewEditor, WebviewEditor.ID, ( localize(11052, "webview editor"))), [( new SyncDescriptor(WebviewInput))]);
21
+ (( Registry.as(EditorExtensions.EditorPane))).registerEditorPane(EditorPaneDescriptor.create(WebviewEditor, WebviewEditor.ID, ( localize(11374, "webview editor"))), [( new SyncDescriptor(WebviewInput))]);
22
22
  let WebviewPanelContribution = class WebviewPanelContribution extends Disposable {
23
23
  static { this.ID = 'workbench.contrib.webviewPanel'; }
24
24
  constructor(editorService, editorGroupService) {
@@ -8,7 +8,7 @@ import { IProgressService } from "@codingame/monaco-vscode-api/vscode/vs/platfor
8
8
  import { IStorageService } from "@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service";
9
9
  import { IThemeService } from "@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/themeService.service";
10
10
  import { ViewPane } from "@codingame/monaco-vscode-65619f8f-0eab-5d8b-855a-43b6353fe527-common/vscode/vs/workbench/browser/parts/views/viewPane";
11
- import { IViewletViewOptions } from "@codingame/monaco-vscode-55ed5668-e8ca-5335-a587-790bcf1200c0-common/vscode/vs/workbench/browser/parts/views/viewsViewlet";
11
+ import { IViewletViewOptions } from "@codingame/monaco-vscode-2a94c04a-b85b-5669-b06b-89c1bfa11cb9-common/vscode/vs/workbench/browser/parts/views/viewsViewlet";
12
12
  import { IViewBadge } from "@codingame/monaco-vscode-api/vscode/vs/workbench/common/views";
13
13
  import { IViewDescriptorService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/common/views.service";
14
14
  import { IViewsService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/views/common/viewsService.service";
@@ -8,7 +8,6 @@ import { RegisteredEditorInfo, RegisteredEditorOptions, EditorAssociations, Reso
8
8
  import { IEditorResolverService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/editor/common/editorResolverService.service";
9
9
  import { IQuickInputService } from "@codingame/monaco-vscode-api/vscode/vs/platform/quickinput/common/quickInput.service";
10
10
  import { INotificationService } from "@codingame/monaco-vscode-api/vscode/vs/platform/notification/common/notification.service";
11
- import { ITelemetryService } from "@codingame/monaco-vscode-api/vscode/vs/platform/telemetry/common/telemetry.service";
12
11
  import { IStorageService } from "@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service";
13
12
  import { IExtensionService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions.service";
14
13
  import { ILogService } from "@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service";
@@ -20,7 +19,6 @@ export declare class EditorResolverService extends Disposable implements IEditor
20
19
  private readonly configurationService;
21
20
  private readonly quickInputService;
22
21
  private readonly notificationService;
23
- private readonly telemetryService;
24
22
  private readonly storageService;
25
23
  private readonly extensionService;
26
24
  private readonly logService;
@@ -34,7 +32,7 @@ export declare class EditorResolverService extends Disposable implements IEditor
34
32
  private _flattenedEditors;
35
33
  private _shouldReFlattenEditors;
36
34
  private cache;
37
- constructor(editorGroupService: IEditorGroupsService, instantiationService: IInstantiationService, configurationService: IConfigurationService, quickInputService: IQuickInputService, notificationService: INotificationService, telemetryService: ITelemetryService, storageService: IStorageService, extensionService: IExtensionService, logService: ILogService);
35
+ constructor(editorGroupService: IEditorGroupsService, instantiationService: IInstantiationService, configurationService: IConfigurationService, quickInputService: IQuickInputService, notificationService: INotificationService, storageService: IStorageService, extensionService: IExtensionService, logService: ILogService);
38
36
  private resolveUntypedInputAndGroup;
39
37
  resolveEditor(editor: IUntypedEditorInput, preferredGroup: PreferredGroup | undefined): Promise<ResolvedEditor>;
40
38
  private doResolveSideBySideEditor;
@@ -54,7 +52,6 @@ export declare class EditorResolverService extends Disposable implements IEditor
54
52
  private doHandleConflictingDefaults;
55
53
  private mapEditorsToQuickPickEntry;
56
54
  private doPickEditor;
57
- private sendEditorResolutionTelemetry;
58
55
  private cacheEditors;
59
56
  private resourceMatchesCache;
60
57
  }
@@ -16,7 +16,6 @@ import { IQuickInputService } from '@codingame/monaco-vscode-api/vscode/vs/platf
16
16
  import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
17
17
  import '@codingame/monaco-vscode-api/vscode/vs/platform/notification/common/notification';
18
18
  import { INotificationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/notification/common/notification.service';
19
- import { ITelemetryService } from '@codingame/monaco-vscode-api/vscode/vs/platform/telemetry/common/telemetry.service';
20
19
  import '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/extensions';
21
20
  import { StorageScope, StorageTarget } from '@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage';
22
21
  import { IStorageService } from '@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service';
@@ -33,14 +32,13 @@ let EditorResolverService = class EditorResolverService extends Disposable {
33
32
  static { this.configureDefaultID = 'promptOpenWith.configureDefault'; }
34
33
  static { this.cacheStorageID = 'editorOverrideService.cache'; }
35
34
  static { this.conflictingDefaultsStorageID = 'editorOverrideService.conflictingDefaults'; }
36
- constructor(editorGroupService, instantiationService, configurationService, quickInputService, notificationService, telemetryService, storageService, extensionService, logService) {
35
+ constructor(editorGroupService, instantiationService, configurationService, quickInputService, notificationService, storageService, extensionService, logService) {
37
36
  super();
38
37
  this.editorGroupService = editorGroupService;
39
38
  this.instantiationService = instantiationService;
40
39
  this.configurationService = configurationService;
41
40
  this.quickInputService = quickInputService;
42
41
  this.notificationService = notificationService;
43
- this.telemetryService = telemetryService;
44
42
  this.storageService = storageService;
45
43
  this.extensionService = extensionService;
46
44
  this.logService = logService;
@@ -144,7 +142,6 @@ let EditorResolverService = class EditorResolverService extends Disposable {
144
142
  await this.doHandleConflictingDefaults(resource, selectedEditor.editorInfo.label, untypedEditor, input.editor, group);
145
143
  }
146
144
  if (input) {
147
- this.sendEditorResolutionTelemetry(input.editor);
148
145
  if (input.editor.editorId !== selectedEditor.editorInfo.id) {
149
146
  this.logService.warn(`Editor ID Mismatch: ${input.editor.editorId} !== ${selectedEditor.editorInfo.id}. This will cause bugs. Please ensure editorInput.editorId matches the registered id`);
150
147
  }
@@ -449,8 +446,8 @@ let EditorResolverService = class EditorResolverService extends Disposable {
449
446
  if (storedChoices[globForResource] && storedChoices[globForResource].find(editorID => editorID === currentEditor.editorId)) {
450
447
  return;
451
448
  }
452
- const handle = this.notificationService.prompt(Severity.Warning, ( localize(11722, 'There are multiple default editors available for the resource.')), [{
453
- label: ( localize(11723, 'Configure Default')),
449
+ const handle = this.notificationService.prompt(Severity.Warning, ( localize(12053, 'There are multiple default editors available for the resource.')), [{
450
+ label: ( localize(12054, 'Configure Default')),
454
451
  run: async () => {
455
452
  const picked = await this.doPickEditor(untypedInput, true);
456
453
  if (!picked) {
@@ -471,7 +468,7 @@ let EditorResolverService = class EditorResolverService extends Disposable {
471
468
  }
472
469
  },
473
470
  {
474
- label: ( localize(11724, 'Keep {0}', editorName)),
471
+ label: ( localize(12055, 'Keep {0}', editorName)),
475
472
  run: writeCurrentEditorsToStorage
476
473
  }
477
474
  ]);
@@ -497,9 +494,9 @@ let EditorResolverService = class EditorResolverService extends Disposable {
497
494
  }
498
495
  });
499
496
  const quickPickEntries = [];
500
- const currentlyActiveLabel = ( localize(11725, "Active"));
501
- const currentDefaultLabel = ( localize(11726, "Default"));
502
- const currentDefaultAndActiveLabel = ( localize(11727, "Active and Default"));
497
+ const currentlyActiveLabel = ( localize(12056, "Active"));
498
+ const currentDefaultLabel = ( localize(12057, "Default"));
499
+ const currentDefaultAndActiveLabel = ( localize(12058, "Active and Default"));
503
500
  let defaultViewType = defaultSetting;
504
501
  if (!defaultViewType && registeredEditors.length > 2 && registeredEditors[1]?.editorInfo.priority !== RegisteredEditorPriority.option) {
505
502
  defaultViewType = registeredEditors[1]?.editorInfo.id;
@@ -524,7 +521,7 @@ let EditorResolverService = class EditorResolverService extends Disposable {
524
521
  quickPickEntries.push(separator);
525
522
  const configureDefaultEntry = {
526
523
  id: EditorResolverService_1.configureDefaultID,
527
- label: ( localize(11728, "Configure default editor for '{0}'...", `*${extname(resource)}`)),
524
+ label: ( localize(12059, "Configure default editor for '{0}'...", `*${extname(resource)}`)),
528
525
  };
529
526
  quickPickEntries.push(configureDefaultEntry);
530
527
  }
@@ -539,8 +536,8 @@ let EditorResolverService = class EditorResolverService extends Disposable {
539
536
  const disposables = ( new DisposableStore());
540
537
  const editorPicker = disposables.add(this.quickInputService.createQuickPick({ useSeparators: true }));
541
538
  const placeHolderMessage = showDefaultPicker ?
542
- ( localize(11729, "Select new default editor for '{0}'", `*${extname(resource)}`)) :
543
- ( localize(11730, "Select editor for '{0}'", basename(resource)));
539
+ ( localize(12060, "Select new default editor for '{0}'", `*${extname(resource)}`)) :
540
+ ( localize(12061, "Select editor for '{0}'", basename(resource)));
544
541
  editorPicker.placeholder = placeHolderMessage;
545
542
  editorPicker.canAcceptInBackground = true;
546
543
  editorPicker.items = editorPicks;
@@ -589,11 +586,6 @@ let EditorResolverService = class EditorResolverService extends Disposable {
589
586
  }
590
587
  return undefined;
591
588
  }
592
- sendEditorResolutionTelemetry(chosenInput) {
593
- if (chosenInput.editorId) {
594
- this.telemetryService.publicLog2('override.viewType', { viewType: chosenInput.editorId });
595
- }
596
- }
597
589
  cacheEditors() {
598
590
  const cacheStorage = ( new Set());
599
591
  for (const [globPattern, contribPoint] of this._flattenedEditors) {
@@ -634,10 +626,9 @@ EditorResolverService = EditorResolverService_1 = ( __decorate([
634
626
  ( __param(2, IConfigurationService)),
635
627
  ( __param(3, IQuickInputService)),
636
628
  ( __param(4, INotificationService)),
637
- ( __param(5, ITelemetryService)),
638
- ( __param(6, IStorageService)),
639
- ( __param(7, IExtensionService)),
640
- ( __param(8, ILogService))
629
+ ( __param(5, IStorageService)),
630
+ ( __param(6, IExtensionService)),
631
+ ( __param(7, ILogService))
641
632
  ], EditorResolverService));
642
633
 
643
634
  export { EditorResolverService };
@@ -131,7 +131,6 @@ interface IEditorNavigationStackEntry {
131
131
  export declare class EditorNavigationStack extends Disposable {
132
132
  private readonly filter;
133
133
  private readonly scope;
134
- private readonly instantiationService;
135
134
  private readonly editorService;
136
135
  private readonly editorGroupService;
137
136
  private readonly logService;
@@ -55,34 +55,6 @@ let HistoryService = class HistoryService extends Disposable {
55
55
  this.logService = logService;
56
56
  this.activeEditorListeners = this._register(( new DisposableStore()));
57
57
  this.lastActiveEditor = undefined;
58
- this.editorHelper = this.instantiationService.createInstance(EditorHelper);
59
- this.canNavigateBackContextKey = (( new RawContextKey('canNavigateBack', false, ( localize(11937, "Whether it is possible to navigate back in editor history"))))).bindTo(this.contextKeyService);
60
- this.canNavigateForwardContextKey = (( new RawContextKey('canNavigateForward', false, ( localize(11938, "Whether it is possible to navigate forward in editor history"))))).bindTo(this.contextKeyService);
61
- this.canNavigateBackInNavigationsContextKey = (( new RawContextKey('canNavigateBackInNavigationLocations', false, ( localize(
62
- 11939,
63
- "Whether it is possible to navigate back in editor navigation locations history"
64
- ))))).bindTo(this.contextKeyService);
65
- this.canNavigateForwardInNavigationsContextKey = (( new RawContextKey('canNavigateForwardInNavigationLocations', false, ( localize(
66
- 11940,
67
- "Whether it is possible to navigate forward in editor navigation locations history"
68
- ))))).bindTo(this.contextKeyService);
69
- this.canNavigateToLastNavigationLocationContextKey = (( new RawContextKey('canNavigateToLastNavigationLocation', false, ( localize(
70
- 11941,
71
- "Whether it is possible to navigate to the last editor navigation location"
72
- ))))).bindTo(this.contextKeyService);
73
- this.canNavigateBackInEditsContextKey = (( new RawContextKey('canNavigateBackInEditLocations', false, ( localize(
74
- 11942,
75
- "Whether it is possible to navigate back in editor edit locations history"
76
- ))))).bindTo(this.contextKeyService);
77
- this.canNavigateForwardInEditsContextKey = (( new RawContextKey('canNavigateForwardInEditLocations', false, ( localize(
78
- 11943,
79
- "Whether it is possible to navigate forward in editor edit locations history"
80
- ))))).bindTo(this.contextKeyService);
81
- this.canNavigateToLastEditLocationContextKey = (( new RawContextKey('canNavigateToLastEditLocation', false, ( localize(
82
- 11944,
83
- "Whether it is possible to navigate to the last editor edit location"
84
- ))))).bindTo(this.contextKeyService);
85
- this.canReopenClosedEditorContextKey = (( new RawContextKey('canReopenClosedEditor', false, ( localize(11945, "Whether it is possible to reopen the last closed editor"))))).bindTo(this.contextKeyService);
86
58
  this._onDidChangeEditorNavigationStack = this._register(( new Emitter()));
87
59
  this.onDidChangeEditorNavigationStack = this._onDidChangeEditorNavigationStack.event;
88
60
  this.defaultScopedEditorNavigationStack = undefined;
@@ -104,6 +76,34 @@ let HistoryService = class HistoryService extends Disposable {
104
76
  this._register(matcher.onExpressionChange(() => this.removeExcludedFromHistory()));
105
77
  return matcher;
106
78
  })));
79
+ this.editorHelper = this.instantiationService.createInstance(EditorHelper);
80
+ this.canNavigateBackContextKey = (( new RawContextKey('canNavigateBack', false, ( localize(12270, "Whether it is possible to navigate back in editor history"))))).bindTo(this.contextKeyService);
81
+ this.canNavigateForwardContextKey = (( new RawContextKey('canNavigateForward', false, ( localize(12271, "Whether it is possible to navigate forward in editor history"))))).bindTo(this.contextKeyService);
82
+ this.canNavigateBackInNavigationsContextKey = (( new RawContextKey('canNavigateBackInNavigationLocations', false, ( localize(
83
+ 12272,
84
+ "Whether it is possible to navigate back in editor navigation locations history"
85
+ ))))).bindTo(this.contextKeyService);
86
+ this.canNavigateForwardInNavigationsContextKey = (( new RawContextKey('canNavigateForwardInNavigationLocations', false, ( localize(
87
+ 12273,
88
+ "Whether it is possible to navigate forward in editor navigation locations history"
89
+ ))))).bindTo(this.contextKeyService);
90
+ this.canNavigateToLastNavigationLocationContextKey = (( new RawContextKey('canNavigateToLastNavigationLocation', false, ( localize(
91
+ 12274,
92
+ "Whether it is possible to navigate to the last editor navigation location"
93
+ ))))).bindTo(this.contextKeyService);
94
+ this.canNavigateBackInEditsContextKey = (( new RawContextKey('canNavigateBackInEditLocations', false, ( localize(
95
+ 12275,
96
+ "Whether it is possible to navigate back in editor edit locations history"
97
+ ))))).bindTo(this.contextKeyService);
98
+ this.canNavigateForwardInEditsContextKey = (( new RawContextKey('canNavigateForwardInEditLocations', false, ( localize(
99
+ 12276,
100
+ "Whether it is possible to navigate forward in editor edit locations history"
101
+ ))))).bindTo(this.contextKeyService);
102
+ this.canNavigateToLastEditLocationContextKey = (( new RawContextKey('canNavigateToLastEditLocation', false, ( localize(
103
+ 12277,
104
+ "Whether it is possible to navigate to the last editor edit location"
105
+ ))))).bindTo(this.contextKeyService);
106
+ this.canReopenClosedEditorContextKey = (( new RawContextKey('canReopenClosedEditor', false, ( localize(12278, "Whether it is possible to reopen the last closed editor"))))).bindTo(this.contextKeyService);
107
107
  this.registerListeners();
108
108
  if (this.editorService.activeEditorPane) {
109
109
  this.onDidActiveEditorChange();
@@ -983,7 +983,6 @@ let EditorNavigationStack = class EditorNavigationStack extends Disposable {
983
983
  super();
984
984
  this.filter = filter;
985
985
  this.scope = scope;
986
- this.instantiationService = instantiationService;
987
986
  this.editorService = editorService;
988
987
  this.editorGroupService = editorGroupService;
989
988
  this.logService = logService;
@@ -991,12 +990,12 @@ let EditorNavigationStack = class EditorNavigationStack extends Disposable {
991
990
  this.onDidChange = this._onDidChange.event;
992
991
  this.mapEditorToDisposable = ( new Map());
993
992
  this.mapGroupToDisposable = ( new Map());
994
- this.editorHelper = this.instantiationService.createInstance(EditorHelper);
995
993
  this.stack = [];
996
994
  this.index = -1;
997
995
  this.previousIndex = -1;
998
996
  this.navigating = false;
999
997
  this.currentSelectionState = undefined;
998
+ this.editorHelper = instantiationService.createInstance(EditorHelper);
1000
999
  this.registerListeners();
1001
1000
  }
1002
1001
  registerListeners() {
@@ -0,0 +1,15 @@
1
+ .monaco-workbench .progress-badge > .badge-content::before {
2
+ mask: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxNCIgaGVpZ2h0PSIxNCIgdmlld0JveD0iMiAyIDE0IDE0IiBlbmFibGUtYmFja2dyb3VuZD0ibmV3IDIgMiAxNCAxNCI+PHBhdGggZmlsbD0iI2ZmZiIgZD0iTTkgMTZjLTMuODYgMC03LTMuMTQtNy03czMuMTQtNyA3LTdjMy44NTkgMCA3IDMuMTQxIDcgN3MtMy4xNDEgNy03IDd6bTAtMTIuNmMtMy4wODggMC01LjYgMi41MTMtNS42IDUuNnMyLjUxMiA1LjYgNS42IDUuNiA1LjYtMi41MTIgNS42LTUuNi0yLjUxMi01LjYtNS42LTUuNnptMy44NiA3LjFsLTMuMTYtMS44OTZ2LTMuODA0aC0xLjR2NC41OTZsMy44NCAyLjMwNS43Mi0xLjIwMXoiLz48L3N2Zz4=") no-repeat;
3
+ -webkit-mask: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxNCIgaGVpZ2h0PSIxNCIgdmlld0JveD0iMiAyIDE0IDE0IiBlbmFibGUtYmFja2dyb3VuZD0ibmV3IDIgMiAxNCAxNCI+PHBhdGggZmlsbD0iI2ZmZiIgZD0iTTkgMTZjLTMuODYgMC03LTMuMTQtNy03czMuMTQtNyA3LTdjMy44NTkgMCA3IDMuMTQxIDcgN3MtMy4xNDEgNy03IDd6bTAtMTIuNmMtMy4wODggMC01LjYgMi41MTMtNS42IDUuNnMyLjUxMiA1LjYgNS42IDUuNiA1LjYtMi41MTIgNS42LTUuNi0yLjUxMi01LjYtNS42LTUuNnptMy44NiA3LjFsLTMuMTYtMS44OTZ2LTMuODA0aC0xLjR2NC41OTZsMy44NCAyLjMwNS43Mi0xLjIwMXoiLz48L3N2Zz4=") no-repeat;
4
+ width: 14px;
5
+ height: 14px;
6
+ position: absolute;
7
+ top: 0;
8
+ right: 0;
9
+ bottom: 0;
10
+ left: 0;
11
+ margin: auto;
12
+ background-color: currentColor;
13
+ content: '';
14
+ background-repeat: no-repeat;
15
+ }
@@ -1,6 +1,6 @@
1
1
 
2
2
  import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
3
- import './media/progressService.css.js';
3
+ import './media/progressService.css';
4
4
  import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
5
5
  import { Disposable, toDisposable, DisposableStore, dispose } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
6
6
  import { ProgressLocation, Progress } from '@codingame/monaco-vscode-api/vscode/vs/platform/progress/common/progress';
@@ -16,18 +16,16 @@ import { Action } from '@codingame/monaco-vscode-api/vscode/vs/base/common/actio
16
16
  import { Emitter, Event } from '@codingame/monaco-vscode-api/vscode/vs/base/common/event';
17
17
  import '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/extensions';
18
18
  import { ILayoutService } from '@codingame/monaco-vscode-api/vscode/vs/platform/layout/browser/layoutService.service';
19
- import { Dialog } from '@codingame/monaco-vscode-44b92f80-48ea-5562-a8d0-18a015f8d845-common/vscode/vs/base/browser/ui/dialog/dialog';
19
+ import { Dialog } from '@codingame/monaco-vscode-f1bbc6d3-6129-583c-a2ba-c80b832993d2-common/vscode/vs/base/browser/ui/dialog/dialog';
20
20
  import { IKeybindingService } from '@codingame/monaco-vscode-api/vscode/vs/platform/keybinding/common/keybinding.service';
21
- import { EventHelper } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/dom';
22
21
  import { parseLinkedText } from '@codingame/monaco-vscode-api/vscode/vs/base/common/linkedText';
23
22
  import { ViewContainerLocation } from '@codingame/monaco-vscode-api/vscode/vs/workbench/common/views';
24
23
  import { IViewDescriptorService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/common/views.service';
25
24
  import { IViewsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/views/common/viewsService.service';
26
25
  import { IPaneCompositePartService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/panecomposite/browser/panecomposite.service';
27
26
  import { stripIcons } from '@codingame/monaco-vscode-api/vscode/vs/base/common/iconLabels';
28
- import { defaultDialogStyles, defaultInputBoxStyles, defaultCheckboxStyles, defaultButtonStyles } from '@codingame/monaco-vscode-api/vscode/vs/platform/theme/browser/defaultStyles';
29
- import { ResultKind } from '@codingame/monaco-vscode-api/vscode/vs/platform/keybinding/common/keybindingResolver';
30
27
  import { IUserActivityService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/userActivity/common/userActivityService.service';
28
+ import { createWorkbenchDialogOptions } from '@codingame/monaco-vscode-f1bbc6d3-6129-583c-a2ba-c80b832993d2-common/vscode/vs/platform/dialogs/browser/dialog';
31
29
  import Severity from '@codingame/monaco-vscode-api/vscode/vs/base/common/severity';
32
30
 
33
31
  let ProgressService = class ProgressService extends Disposable {
@@ -132,23 +130,23 @@ let ProgressService = class ProgressService extends Disposable {
132
130
  let title;
133
131
  const source = options.source && typeof options.source !== 'string' ? options.source.label : options.source;
134
132
  if (progressTitle && progressMessage) {
135
- text = ( localize(12068, "{0}: {1}", progressTitle, progressMessage));
136
- title = source ? ( localize(12069, "[{0}] {1}: {2}", source, progressTitle, progressMessage)) : text;
133
+ text = ( localize(12401, "{0}: {1}", progressTitle, progressMessage));
134
+ title = source ? ( localize(12402, "[{0}] {1}: {2}", source, progressTitle, progressMessage)) : text;
137
135
  }
138
136
  else if (progressTitle) {
139
137
  text = progressTitle;
140
- title = source ? ( localize(12070, "[{0}]: {1}", source, progressTitle)) : text;
138
+ title = source ? ( localize(12403, "[{0}]: {1}", source, progressTitle)) : text;
141
139
  }
142
140
  else if (progressMessage) {
143
141
  text = progressMessage;
144
- title = source ? ( localize(12070, "[{0}]: {1}", source, progressMessage)) : text;
142
+ title = source ? ( localize(12403, "[{0}]: {1}", source, progressMessage)) : text;
145
143
  }
146
144
  else {
147
145
  this.updateWindowProgress(idx + 1);
148
146
  return;
149
147
  }
150
148
  const statusEntryProperties = {
151
- name: ( localize(12071, "Progress Message")),
149
+ name: ( localize(12404, "Progress Message")),
152
150
  text,
153
151
  showProgress: options.type || true,
154
152
  ariaLabel: text,
@@ -244,7 +242,7 @@ let ProgressService = class ProgressService extends Disposable {
244
242
  if (options.cancellable) {
245
243
  const cancelAction = new (class extends Action {
246
244
  constructor() {
247
- super('progress.cancel', typeof options.cancellable === 'string' ? options.cancellable : ( localize(12072, "Cancel")), undefined, true);
245
+ super('progress.cancel', typeof options.cancellable === 'string' ? options.cancellable : ( localize(12405, "Cancel")), undefined, true);
248
246
  }
249
247
  async run() {
250
248
  progressStateModel.cancel();
@@ -416,44 +414,32 @@ let ProgressService = class ProgressService extends Disposable {
416
414
  }
417
415
  withDialogProgress(options, task, onDidCancel) {
418
416
  const disposables = ( new DisposableStore());
419
- const allowableCommands = [
420
- 'workbench.action.quit',
421
- 'workbench.action.reloadWindow',
422
- 'copy',
423
- 'cut',
424
- 'editor.action.clipboardCopyAction',
425
- 'editor.action.clipboardCutAction'
426
- ];
427
417
  let dialog;
418
+ let taskCompleted = false;
428
419
  const createDialog = (message) => {
429
420
  const buttons = options.buttons || [];
430
421
  if (!options.sticky) {
431
422
  buttons.push(options.cancellable
432
- ? (typeof options.cancellable === 'boolean' ? ( localize(12072, "Cancel")) : options.cancellable)
433
- : ( localize(12073, "Dismiss")));
434
- }
435
- dialog = ( new Dialog(this.layoutService.activeContainer, message, buttons, {
436
- type: 'pending',
437
- detail: options.detail,
438
- cancelId: buttons.length - 1,
439
- disableCloseAction: options.sticky,
440
- disableDefaultAction: options.sticky,
441
- keyEventProcessor: (event) => {
442
- const resolved = this.keybindingService.softDispatch(event, this.layoutService.activeContainer);
443
- if (resolved.kind === ResultKind.KbFound && resolved.commandId) {
444
- if (!allowableCommands.includes(resolved.commandId)) {
445
- EventHelper.stop(event, true);
446
- }
447
- }
448
- },
449
- buttonStyles: defaultButtonStyles,
450
- checkboxStyles: defaultCheckboxStyles,
451
- inputBoxStyles: defaultInputBoxStyles,
452
- dialogStyles: defaultDialogStyles
453
- }));
423
+ ? (typeof options.cancellable === 'boolean' ? ( localize(12405, "Cancel")) : options.cancellable)
424
+ : ( localize(12406, "Dismiss")));
425
+ }
426
+ dialog = ( new Dialog(
427
+ this.layoutService.activeContainer,
428
+ message,
429
+ buttons,
430
+ createWorkbenchDialogOptions({
431
+ type: 'pending',
432
+ detail: options.detail,
433
+ cancelId: buttons.length - 1,
434
+ disableCloseAction: options.sticky,
435
+ disableDefaultAction: options.sticky
436
+ }, this.keybindingService, this.layoutService)
437
+ ));
454
438
  disposables.add(dialog);
455
439
  dialog.show().then(dialogResult => {
456
- onDidCancel?.(dialogResult.button);
440
+ if (!taskCompleted) {
441
+ onDidCancel?.(dialogResult.button);
442
+ }
457
443
  dispose(dialog);
458
444
  });
459
445
  return dialog;
@@ -481,6 +467,7 @@ let ProgressService = class ProgressService extends Disposable {
481
467
  }
482
468
  });
483
469
  promise.finally(() => {
470
+ taskCompleted = true;
484
471
  dispose(disposables);
485
472
  });
486
473
  if (options.title) {