@codingame/monaco-vscode-scm-service-override 25.1.2 → 26.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@codingame/monaco-vscode-scm-service-override",
3
- "version": "25.1.2",
3
+ "version": "26.0.0",
4
4
  "private": false,
5
5
  "description": "VSCode public API plugged on the monaco editor - scm service-override",
6
6
  "keywords": [],
@@ -15,7 +15,7 @@
15
15
  },
16
16
  "type": "module",
17
17
  "dependencies": {
18
- "@codingame/monaco-vscode-api": "25.1.2"
18
+ "@codingame/monaco-vscode-api": "26.0.0"
19
19
  },
20
20
  "main": "index.js",
21
21
  "module": "index.js",
@@ -26,11 +26,19 @@ import { derived } from '@codingame/monaco-vscode-api/vscode/vs/base/common/obse
26
26
  import { autorun } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/reactions/autorun';
27
27
 
28
28
  const ActiveRepositoryContextKeys = {
29
- ActiveRepositoryName: ( new RawContextKey('scmActiveRepositoryName', '')),
30
- ActiveRepositoryBranchName: ( new RawContextKey('scmActiveRepositoryBranchName', '')),
29
+ ActiveRepositoryName: ( new RawContextKey("scmActiveRepositoryName", "")),
30
+ ActiveRepositoryBranchName: ( new RawContextKey("scmActiveRepositoryBranchName", ""))
31
31
  };
32
32
  let SCMActiveRepositoryController = class SCMActiveRepositoryController extends Disposable {
33
- constructor(activityService, configurationService, contextKeyService, scmService, scmViewService, statusbarService, titleService) {
33
+ constructor(
34
+ activityService,
35
+ configurationService,
36
+ contextKeyService,
37
+ scmService,
38
+ scmViewService,
39
+ statusbarService,
40
+ titleService
41
+ ) {
34
42
  super();
35
43
  this.activityService = activityService;
36
44
  this.configurationService = configurationService;
@@ -41,12 +49,19 @@ let SCMActiveRepositoryController = class SCMActiveRepositoryController extends
41
49
  this.titleService = titleService;
42
50
  this._activeRepositoryNameContextKey = ActiveRepositoryContextKeys.ActiveRepositoryName.bindTo(this.contextKeyService);
43
51
  this._activeRepositoryBranchNameContextKey = ActiveRepositoryContextKeys.ActiveRepositoryBranchName.bindTo(this.contextKeyService);
44
- this.titleService.registerVariables([
45
- { name: 'activeRepositoryName', contextKey: ActiveRepositoryContextKeys.ActiveRepositoryName.key },
46
- { name: 'activeRepositoryBranchName', contextKey: ActiveRepositoryContextKeys.ActiveRepositoryBranchName.key, }
47
- ]);
48
- this._countBadgeConfig = observableConfigValue('scm.countBadge', 'all', this.configurationService);
49
- this._repositories = observableFromEvent(this, Event.any(this.scmService.onDidAddRepository, this.scmService.onDidRemoveRepository), () => Iterable.filter(this.scmService.repositories, r => r.provider.isHidden !== true));
52
+ this.titleService.registerVariables([{
53
+ name: "activeRepositoryName",
54
+ contextKey: ActiveRepositoryContextKeys.ActiveRepositoryName.key
55
+ }, {
56
+ name: "activeRepositoryBranchName",
57
+ contextKey: ActiveRepositoryContextKeys.ActiveRepositoryBranchName.key
58
+ }]);
59
+ this._countBadgeConfig = observableConfigValue("scm.countBadge", "all", this.configurationService);
60
+ this._repositories = observableFromEvent(
61
+ this,
62
+ Event.any(this.scmService.onDidAddRepository, this.scmService.onDidRemoveRepository),
63
+ () => Iterable.filter(this.scmService.repositories, r => r.provider.isHidden !== true)
64
+ );
50
65
  this._activeRepositoryHistoryItemRefName = derived(reader => {
51
66
  const activeRepository = this.scmViewService.activeRepository.read(reader);
52
67
  const historyProvider = activeRepository?.repository.provider.historyProvider.read(reader);
@@ -55,21 +70,26 @@ let SCMActiveRepositoryController = class SCMActiveRepositoryController extends
55
70
  });
56
71
  this._countBadgeRepositories = derived(this, reader => {
57
72
  switch (this._countBadgeConfig.read(reader)) {
58
- case 'all': {
73
+ case "all":
74
+ {
59
75
  const repositories = this._repositories.read(reader);
60
- return [...( Iterable.map(
61
- repositories,
62
- r => ({ provider: r.provider, resourceCount: this._getRepositoryResourceCount(r) })
63
- ))];
76
+ return [...( Iterable.map(repositories, r => ({
77
+ provider: r.provider,
78
+ resourceCount: this._getRepositoryResourceCount(r)
79
+ })))];
64
80
  }
65
- case 'focused': {
81
+ case "focused":
82
+ {
66
83
  const activeRepository = this.scmViewService.activeRepository.read(reader);
67
- return activeRepository ? [{ provider: activeRepository.repository.provider, resourceCount: this._getRepositoryResourceCount(activeRepository.repository) }] : [];
84
+ return activeRepository ? [{
85
+ provider: activeRepository.repository.provider,
86
+ resourceCount: this._getRepositoryResourceCount(activeRepository.repository)
87
+ }] : [];
68
88
  }
69
- case 'off':
70
- return [];
71
- default:
72
- throw ( new Error('Invalid countBadge setting'));
89
+ case "off":
90
+ return [];
91
+ default:
92
+ throw ( new Error("Invalid countBadge setting"));
73
93
  }
74
94
  });
75
95
  this._countBadge = derived(this, reader => {
@@ -97,73 +117,100 @@ let SCMActiveRepositoryController = class SCMActiveRepositoryController extends
97
117
  }));
98
118
  }
99
119
  _getRepositoryResourceCount(repository) {
100
- return observableFromEvent(this, repository.provider.onDidChangeResources, () => getRepositoryResourceCount(repository.provider));
120
+ return observableFromEvent(
121
+ this,
122
+ repository.provider.onDidChangeResources,
123
+ () => getRepositoryResourceCount(repository.provider)
124
+ );
101
125
  }
102
126
  _updateActivityCountBadge(count, store) {
103
127
  if (count === 0) {
104
128
  return;
105
129
  }
106
- const badge = ( new NumberBadge(count, num => ( localize(10436, '{0} pending changes', num))));
107
- store.add(this.activityService.showViewActivity(VIEW_PANE_ID, { badge }));
130
+ const badge = ( new NumberBadge(count, num => ( localize(10754, "{0} pending changes", num))));
131
+ store.add(this.activityService.showViewActivity(VIEW_PANE_ID, {
132
+ badge
133
+ }));
108
134
  }
109
135
  _updateStatusBar(activeRepository, commands, store) {
110
136
  if (!activeRepository) {
111
137
  return;
112
138
  }
113
- const label = activeRepository.repository.provider.rootUri
114
- ? `${basename(activeRepository.repository.provider.rootUri)} (${activeRepository.repository.provider.label})`
115
- : activeRepository.repository.provider.label;
139
+ const label = activeRepository.repository.provider.rootUri ? `${basename(activeRepository.repository.provider.rootUri)} (${activeRepository.repository.provider.label})` : activeRepository.repository.provider.label;
116
140
  for (let index = 0; index < commands.length; index++) {
117
141
  const command = commands[index];
118
- const tooltip = `${label}${command.tooltip ? ` - ${command.tooltip}` : ''}`;
142
+ const tooltip = `${label}${command.tooltip ? ` - ${command.tooltip}` : ""}`;
119
143
  const genericCommandName = getStatusBarCommandGenericName(command);
120
144
  const statusbarEntry = {
121
- name: ( localize(10437, "Source Control")) + (genericCommandName ? ` ${genericCommandName}` : ''),
145
+ name: ( localize(10755, "Source Control")) + (genericCommandName ? ` ${genericCommandName}` : ""),
122
146
  text: command.title,
123
147
  ariaLabel: tooltip,
124
148
  tooltip,
125
149
  command: command.id ? command : undefined
126
150
  };
127
- store.add(index === 0 ?
128
- this.statusbarService.addEntry(statusbarEntry, `status.scm.${index}`, StatusbarAlignment.LEFT, 10000) :
129
- this.statusbarService.addEntry(statusbarEntry, `status.scm.${index}`, StatusbarAlignment.LEFT, { location: { id: `status.scm.${index - 1}`, priority: 10000 }, alignment: StatusbarAlignment.RIGHT, compact: true }));
151
+ store.add(index === 0 ? this.statusbarService.addEntry(
152
+ statusbarEntry,
153
+ `status.scm.${index}`,
154
+ StatusbarAlignment.LEFT,
155
+ 10000
156
+ ) : this.statusbarService.addEntry(
157
+ statusbarEntry,
158
+ `status.scm.${index}`,
159
+ StatusbarAlignment.LEFT,
160
+ {
161
+ location: {
162
+ id: `status.scm.${index - 1}`,
163
+ priority: 10000
164
+ },
165
+ alignment: StatusbarAlignment.RIGHT,
166
+ compact: true
167
+ }
168
+ ));
130
169
  }
131
170
  if (this.scmViewService.repositories.length > 1) {
132
171
  const icon = getSCMRepositoryIcon(activeRepository, activeRepository.repository);
133
172
  const repositoryStatusbarEntry = {
134
- name: ( localize(10438, "Source Control Provider")),
173
+ name: ( localize(10756, "Source Control Provider")),
135
174
  text: `$(${icon.id}) ${activeRepository.repository.provider.name}`,
136
175
  ariaLabel: label,
137
176
  tooltip: label,
138
- command: 'scm.setActiveProvider'
177
+ command: "scm.setActiveProvider"
139
178
  };
140
- store.add(this.statusbarService.addEntry(repositoryStatusbarEntry, 'status.scm.provider', StatusbarAlignment.LEFT, { location: { id: `status.scm.0`, priority: 10000 }, alignment: StatusbarAlignment.LEFT, compact: true }));
179
+ store.add(this.statusbarService.addEntry(
180
+ repositoryStatusbarEntry,
181
+ "status.scm.provider",
182
+ StatusbarAlignment.LEFT,
183
+ {
184
+ location: {
185
+ id: `status.scm.0`,
186
+ priority: 10000
187
+ },
188
+ alignment: StatusbarAlignment.LEFT,
189
+ compact: true
190
+ }
191
+ ));
141
192
  }
142
193
  }
143
194
  _updateActiveRepositoryContextKeys(repositoryName, branchName) {
144
- this._activeRepositoryNameContextKey.set(repositoryName ?? '');
145
- this._activeRepositoryBranchNameContextKey.set(branchName ?? '');
195
+ this._activeRepositoryNameContextKey.set(repositoryName ?? "");
196
+ this._activeRepositoryBranchNameContextKey.set(branchName ?? "");
146
197
  }
147
198
  };
148
- SCMActiveRepositoryController = ( __decorate([
149
- ( __param(0, IActivityService)),
150
- ( __param(1, IConfigurationService)),
151
- ( __param(2, IContextKeyService)),
152
- ( __param(3, ISCMService)),
153
- ( __param(4, ISCMViewService)),
154
- ( __param(5, IStatusbarService)),
155
- ( __param(6, ITitleService))
156
- ], SCMActiveRepositoryController));
199
+ SCMActiveRepositoryController = ( __decorate([( __param(0, IActivityService)), ( __param(1, IConfigurationService)), ( __param(2, IContextKeyService)), ( __param(3, ISCMService)), ( __param(4, ISCMViewService)), ( __param(5, IStatusbarService)), ( __param(6, ITitleService))], SCMActiveRepositoryController));
157
200
  let SCMActiveResourceContextKeyController = class SCMActiveResourceContextKeyController extends Disposable {
158
201
  constructor(editorGroupsService, scmService, uriIdentityService) {
159
202
  super();
160
203
  this.scmService = scmService;
161
204
  this.uriIdentityService = uriIdentityService;
162
205
  this._onDidRepositoryChange = ( new Emitter());
163
- const activeResourceHasChangesContextKey = ( new RawContextKey('scmActiveResourceHasChanges', false, ( localize(10439, "Whether the active resource has changes"))));
164
- const activeResourceRepositoryContextKey = ( new RawContextKey('scmActiveResourceRepository', undefined, ( localize(10440, "The active resource's repository"))));
165
- this._repositories = observableFromEvent(this, Event.any(this.scmService.onDidAddRepository, this.scmService.onDidRemoveRepository), () => this.scmService.repositories);
166
- this._register(autorun((reader) => {
206
+ const activeResourceHasChangesContextKey = ( new RawContextKey("scmActiveResourceHasChanges", false, ( localize(10757, "Whether the active resource has changes"))));
207
+ const activeResourceRepositoryContextKey = ( new RawContextKey("scmActiveResourceRepository", undefined, ( localize(10758, "The active resource's repository"))));
208
+ this._repositories = observableFromEvent(
209
+ this,
210
+ Event.any(this.scmService.onDidAddRepository, this.scmService.onDidRemoveRepository),
211
+ () => this.scmService.repositories
212
+ );
213
+ this._register(autorun(reader => {
167
214
  for (const repository of this._repositories.read(reader)) {
168
215
  reader.store.add(Event.runAndSubscribe(repository.provider.onDidChangeResources, () => {
169
216
  this._onDidRepositoryChange.fire();
@@ -172,16 +219,20 @@ let SCMActiveResourceContextKeyController = class SCMActiveResourceContextKeyCon
172
219
  }));
173
220
  const hasChangesContextKeyProvider = {
174
221
  contextKey: activeResourceHasChangesContextKey,
175
- getGroupContextKeyValue: (group) => this._getEditorHasChanges(group.activeEditor),
222
+ getGroupContextKeyValue: group => this._getEditorHasChanges(group.activeEditor),
176
223
  onDidChange: this._onDidRepositoryChange.event
177
224
  };
178
225
  const repositoryContextKeyProvider = {
179
226
  contextKey: activeResourceRepositoryContextKey,
180
- getGroupContextKeyValue: (group) => this._getEditorRepositoryId(group.activeEditor),
227
+ getGroupContextKeyValue: group => this._getEditorRepositoryId(group.activeEditor),
181
228
  onDidChange: this._onDidRepositoryChange.event
182
229
  };
183
- this._store.add(editorGroupsService.registerContextKeyProvider(hasChangesContextKeyProvider));
184
- this._store.add(editorGroupsService.registerContextKeyProvider(repositoryContextKeyProvider));
230
+ this._store.add(
231
+ editorGroupsService.registerContextKeyProvider(hasChangesContextKeyProvider)
232
+ );
233
+ this._store.add(
234
+ editorGroupsService.registerContextKeyProvider(repositoryContextKeyProvider)
235
+ );
185
236
  }
186
237
  _getEditorHasChanges(activeEditor) {
187
238
  const activeResource = EditorResourceAccessor.getOriginalUri(activeEditor);
@@ -190,8 +241,7 @@ let SCMActiveResourceContextKeyController = class SCMActiveResourceContextKeyCon
190
241
  }
191
242
  const activeResourceRepository = this.scmService.getRepository(activeResource);
192
243
  for (const resourceGroup of activeResourceRepository?.provider.groups ?? []) {
193
- if (( resourceGroup.resources
194
- .some(
244
+ if (( resourceGroup.resources.some(
195
245
  scmResource => this.uriIdentityService.extUri.isEqual(activeResource, scmResource.sourceUri)
196
246
  ))) {
197
247
  return true;
@@ -212,10 +262,6 @@ let SCMActiveResourceContextKeyController = class SCMActiveResourceContextKeyCon
212
262
  super.dispose();
213
263
  }
214
264
  };
215
- SCMActiveResourceContextKeyController = ( __decorate([
216
- ( __param(0, IEditorGroupsService)),
217
- ( __param(1, ISCMService)),
218
- ( __param(2, IUriIdentityService))
219
- ], SCMActiveResourceContextKeyController));
265
+ SCMActiveResourceContextKeyController = ( __decorate([( __param(0, IEditorGroupsService)), ( __param(1, ISCMService)), ( __param(2, IUriIdentityService))], SCMActiveResourceContextKeyController));
220
266
 
221
267
  export { SCMActiveRepositoryController, SCMActiveResourceContextKeyController };
@@ -378,7 +378,11 @@
378
378
  }
379
379
 
380
380
  .scm-view .scm-editor-container .monaco-editor {
381
- border-radius: 2px;
381
+ border-radius: 4px;
382
+ }
383
+
384
+ .scm-view .scm-editor-container .monaco-editor .overflow-guard {
385
+ border-radius: 4px;
382
386
  }
383
387
 
384
388
  .scm-view .scm-editor {
@@ -389,7 +393,7 @@
389
393
  box-sizing: border-box;
390
394
  border: 1px solid var(--vscode-input-border, transparent);
391
395
  background-color: var(--vscode-input-background);
392
- border-radius: 2px;
396
+ border-radius: 4px;
393
397
  }
394
398
 
395
399
  .scm-view .button-container {
@@ -19,8 +19,12 @@ function actionEquals(a, b) {
19
19
  return a.id === b.id;
20
20
  }
21
21
  let SCMTitleMenu = class SCMTitleMenu {
22
- get actions() { return this._actions; }
23
- get secondaryActions() { return this._secondaryActions; }
22
+ get actions() {
23
+ return this._actions;
24
+ }
25
+ get secondaryActions() {
26
+ return this._secondaryActions;
27
+ }
24
28
  constructor(menuService, contextKeyService) {
25
29
  this._actions = [];
26
30
  this._secondaryActions = [];
@@ -33,7 +37,12 @@ let SCMTitleMenu = class SCMTitleMenu {
33
37
  this.updateTitleActions();
34
38
  }
35
39
  updateTitleActions() {
36
- const { primary, secondary } = getActionBarActions(this.menu.getActions({ shouldForwardArgs: true }));
40
+ const {
41
+ primary,
42
+ secondary
43
+ } = getActionBarActions(this.menu.getActions({
44
+ shouldForwardArgs: true
45
+ }));
37
46
  if (equals(primary, this._actions, actionEquals) && equals(secondary, this._secondaryActions, actionEquals)) {
38
47
  return;
39
48
  }
@@ -45,10 +54,7 @@ let SCMTitleMenu = class SCMTitleMenu {
45
54
  this.disposables.dispose();
46
55
  }
47
56
  };
48
- SCMTitleMenu = ( __decorate([
49
- ( __param(0, IMenuService)),
50
- ( __param(1, IContextKeyService))
51
- ], SCMTitleMenu));
57
+ SCMTitleMenu = ( __decorate([( __param(0, IMenuService)), ( __param(1, IContextKeyService))], SCMTitleMenu));
52
58
  class SCMMenusItem {
53
59
  get resourceFolderMenu() {
54
60
  if (!this._resourceFolderMenu) {
@@ -61,7 +67,7 @@ class SCMMenusItem {
61
67
  this.menuService = menuService;
62
68
  }
63
69
  getResourceGroupMenu(resourceGroup) {
64
- if (typeof resourceGroup.contextValue === 'undefined') {
70
+ if (typeof resourceGroup.contextValue === "undefined") {
65
71
  if (!this.genericResourceGroupMenu) {
66
72
  this.genericResourceGroupMenu = this.menuService.createMenu(MenuId.SCMResourceGroupContext, this.contextKeyService);
67
73
  }
@@ -72,10 +78,11 @@ class SCMMenusItem {
72
78
  }
73
79
  let item = this.contextualResourceGroupMenus.get(resourceGroup.contextValue);
74
80
  if (!item) {
75
- const contextKeyService = this.contextKeyService.createOverlay([['scmResourceGroupState', resourceGroup.contextValue]]);
81
+ const contextKeyService = this.contextKeyService.createOverlay([["scmResourceGroupState", resourceGroup.contextValue]]);
76
82
  const menu = this.menuService.createMenu(MenuId.SCMResourceGroupContext, contextKeyService);
77
83
  item = {
78
- menu, dispose() {
84
+ menu,
85
+ dispose() {
79
86
  menu.dispose();
80
87
  }
81
88
  };
@@ -84,7 +91,7 @@ class SCMMenusItem {
84
91
  return item.menu;
85
92
  }
86
93
  getResourceMenu(resource) {
87
- if (typeof resource.contextValue === 'undefined') {
94
+ if (typeof resource.contextValue === "undefined") {
88
95
  if (!this.genericResourceMenu) {
89
96
  this.genericResourceMenu = this.menuService.createMenu(MenuId.SCMResourceContext, this.contextKeyService);
90
97
  }
@@ -95,10 +102,11 @@ class SCMMenusItem {
95
102
  }
96
103
  let item = this.contextualResourceMenus.get(resource.contextValue);
97
104
  if (!item) {
98
- const contextKeyService = this.contextKeyService.createOverlay([['scmResourceState', resource.contextValue]]);
105
+ const contextKeyService = this.contextKeyService.createOverlay([["scmResourceState", resource.contextValue]]);
99
106
  const menu = this.menuService.createMenu(MenuId.SCMResourceContext, contextKeyService);
100
107
  item = {
101
- menu, dispose() {
108
+ menu,
109
+ dispose() {
102
110
  menu.dispose();
103
111
  }
104
112
  };
@@ -131,9 +139,9 @@ let SCMRepositoryMenus = class SCMRepositoryMenus {
131
139
  this.resourceGroupMenusItems = ( new Map());
132
140
  this.disposables = ( new DisposableStore());
133
141
  this.contextKeyService = contextKeyService.createOverlay([
134
- ['scmProvider', provider.providerId],
135
- ['scmProviderRootUri', provider.rootUri?.toString()],
136
- ['scmProviderHasRootUri', !!provider.rootUri],
142
+ ["scmProvider", provider.providerId],
143
+ ["scmProviderRootUri", provider.rootUri?.toString()],
144
+ ["scmProviderHasRootUri", !!provider.rootUri]
137
145
  ]);
138
146
  const serviceCollection = ( new ServiceCollection([IContextKeyService, this.contextKeyService]));
139
147
  instantiationService = instantiationService.createChild(serviceCollection, this.disposables);
@@ -145,10 +153,11 @@ let SCMRepositoryMenus = class SCMRepositoryMenus {
145
153
  getArtifactGroupMenu(artifactGroup) {
146
154
  let item = this.artifactGroupMenus.get(artifactGroup.id);
147
155
  if (!item) {
148
- const contextKeyService = this.contextKeyService.createOverlay([['scmArtifactGroup', artifactGroup.id]]);
156
+ const contextKeyService = this.contextKeyService.createOverlay([["scmArtifactGroup", artifactGroup.id]]);
149
157
  const menu = this.menuService.createMenu(MenuId.SCMArtifactGroupContext, contextKeyService);
150
158
  item = {
151
- menu, dispose() {
159
+ menu,
160
+ dispose() {
152
161
  menu.dispose();
153
162
  }
154
163
  };
@@ -164,12 +173,13 @@ let SCMRepositoryMenus = class SCMRepositoryMenus {
164
173
  let item = this.artifactMenus.get(key);
165
174
  if (!item) {
166
175
  const contextKeyService = this.contextKeyService.createOverlay([
167
- ['scmArtifactGroupId', artifactGroup.id],
168
- ['scmArtifactIsHistoryItemRef', isHistoryItemRef]
176
+ ["scmArtifactGroupId", artifactGroup.id],
177
+ ["scmArtifactIsHistoryItemRef", isHistoryItemRef]
169
178
  ]);
170
179
  const menu = this.menuService.createMenu(MenuId.SCMArtifactContext, contextKeyService);
171
180
  item = {
172
- menu, dispose() {
181
+ menu,
182
+ dispose() {
173
183
  menu.dispose();
174
184
  }
175
185
  };
@@ -179,7 +189,7 @@ let SCMRepositoryMenus = class SCMRepositoryMenus {
179
189
  }
180
190
  getRepositoryMenu(repository) {
181
191
  const contextValue = repository.provider.contextValue.get();
182
- if (typeof contextValue === 'undefined') {
192
+ if (typeof contextValue === "undefined") {
183
193
  if (!this.genericRepositoryMenu) {
184
194
  this.genericRepositoryMenu = this.menuService.createMenu(MenuId.SCMSourceControlInline, this.contextKeyService);
185
195
  }
@@ -190,10 +200,11 @@ let SCMRepositoryMenus = class SCMRepositoryMenus {
190
200
  }
191
201
  let item = this.contextualRepositoryMenus.get(contextValue);
192
202
  if (!item) {
193
- const contextKeyService = this.contextKeyService.createOverlay([['scmProviderContext', contextValue]]);
203
+ const contextKeyService = this.contextKeyService.createOverlay([["scmProviderContext", contextValue]]);
194
204
  const menu = this.menuService.createMenu(MenuId.SCMSourceControlInline, contextKeyService);
195
205
  item = {
196
- menu, dispose() {
206
+ menu,
207
+ dispose() {
197
208
  menu.dispose();
198
209
  }
199
210
  };
@@ -203,7 +214,7 @@ let SCMRepositoryMenus = class SCMRepositoryMenus {
203
214
  }
204
215
  getRepositoryContextMenu(repository) {
205
216
  const contextValue = repository.provider.contextValue.get();
206
- if (typeof contextValue === 'undefined') {
217
+ if (typeof contextValue === "undefined") {
207
218
  if (!this.genericRepositoryContextMenu) {
208
219
  this.genericRepositoryContextMenu = this.menuService.createMenu(MenuId.SCMSourceControl, this.contextKeyService);
209
220
  }
@@ -214,10 +225,11 @@ let SCMRepositoryMenus = class SCMRepositoryMenus {
214
225
  }
215
226
  let item = this.contextualRepositoryContextMenus.get(contextValue);
216
227
  if (!item) {
217
- const contextKeyService = this.contextKeyService.createOverlay([['scmProviderContext', contextValue]]);
228
+ const contextKeyService = this.contextKeyService.createOverlay([["scmProviderContext", contextValue]]);
218
229
  const menu = this.menuService.createMenu(MenuId.SCMSourceControl, contextKeyService);
219
230
  item = {
220
- menu, dispose() {
231
+ menu,
232
+ dispose() {
221
233
  menu.dispose();
222
234
  }
223
235
  };
@@ -238,8 +250,8 @@ let SCMRepositoryMenus = class SCMRepositoryMenus {
238
250
  let result = this.resourceGroupMenusItems.get(group);
239
251
  if (!result) {
240
252
  const contextKeyService = this.contextKeyService.createOverlay([
241
- ['scmResourceGroup', group.id],
242
- ['multiDiffEditorEnableViewChanges', group.multiDiffEditorEnableViewChanges],
253
+ ["scmResourceGroup", group.id],
254
+ ["multiDiffEditorEnableViewChanges", group.multiDiffEditorEnableViewChanges]
243
255
  ]);
244
256
  result = ( new SCMMenusItem(contextKeyService, this.menuService));
245
257
  this.resourceGroupMenusItems.set(group, result);
@@ -265,11 +277,7 @@ let SCMRepositoryMenus = class SCMRepositoryMenus {
265
277
  this.disposables.dispose();
266
278
  }
267
279
  };
268
- SCMRepositoryMenus = ( __decorate([
269
- ( __param(1, IContextKeyService)),
270
- ( __param(2, IInstantiationService)),
271
- ( __param(3, IMenuService))
272
- ], SCMRepositoryMenus));
280
+ SCMRepositoryMenus = ( __decorate([( __param(1, IContextKeyService)), ( __param(2, IInstantiationService)), ( __param(3, IMenuService))], SCMRepositoryMenus));
273
281
  let SCMMenus = class SCMMenus {
274
282
  constructor(scmService, instantiationService) {
275
283
  this.instantiationService = instantiationService;
@@ -291,7 +299,10 @@ let SCMMenus = class SCMMenus {
291
299
  menus.dispose();
292
300
  this.menus.delete(provider);
293
301
  };
294
- result = { menus, dispose };
302
+ result = {
303
+ menus,
304
+ dispose
305
+ };
295
306
  this.menus.set(provider, result);
296
307
  }
297
308
  return result.menus;
@@ -300,15 +311,12 @@ let SCMMenus = class SCMMenus {
300
311
  this.disposables.dispose();
301
312
  }
302
313
  };
303
- SCMMenus = ( __decorate([
304
- ( __param(0, ISCMService)),
305
- ( __param(1, IInstantiationService))
306
- ], SCMMenus));
314
+ SCMMenus = ( __decorate([( __param(0, ISCMService)), ( __param(1, IInstantiationService))], SCMMenus));
307
315
  MenuRegistry.appendMenuItem(MenuId.SCMResourceContext, {
308
- title: ( localize(10441, "Share")),
316
+ title: ( localize(10759, "Share")),
309
317
  submenu: MenuId.SCMResourceContextShare,
310
- group: '45_share',
311
- order: 3,
318
+ group: "45_share",
319
+ order: 3
312
320
  });
313
321
 
314
322
  export { SCMMenus, SCMRepositoryMenus, SCMTitleMenu };