@codingame/monaco-vscode-scm-service-override 20.5.0 → 21.0.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@codingame/monaco-vscode-scm-service-override",
3
- "version": "20.5.0",
3
+ "version": "21.0.1",
4
4
  "private": false,
5
5
  "description": "VSCode public API plugged on the monaco editor - scm service-override",
6
6
  "keywords": [],
@@ -15,18 +15,19 @@
15
15
  },
16
16
  "type": "module",
17
17
  "dependencies": {
18
- "@codingame/monaco-vscode-262ed59d-4f76-57cd-9e9f-1877f26ae049-common": "20.5.0",
19
- "@codingame/monaco-vscode-27663a0b-1249-58ba-9085-e52d706b50bc-common": "20.5.0",
20
- "@codingame/monaco-vscode-501b06ab-3f58-516b-8a1a-c29d375d3da4-common": "20.5.0",
21
- "@codingame/monaco-vscode-60014c9d-b815-501d-83a9-4b08725c2ec2-common": "20.5.0",
22
- "@codingame/monaco-vscode-a8d3bd74-e63e-5327-96e8-4f931661e329-common": "20.5.0",
23
- "@codingame/monaco-vscode-api": "20.5.0",
24
- "@codingame/monaco-vscode-bb83fe45-f4c7-5673-b9f1-5c409a63f19c-common": "20.5.0",
25
- "@codingame/monaco-vscode-c2deffc4-ad68-5e63-8f95-9b89e0fc6898-common": "20.5.0",
26
- "@codingame/monaco-vscode-d0569cfb-4706-5ad6-b0b0-5115ad8685db-common": "20.5.0",
27
- "@codingame/monaco-vscode-d941ac7b-412f-57e3-b1bf-f6b0eb253b21-common": "20.5.0",
28
- "@codingame/monaco-vscode-dbfe5f85-b426-55ed-a79b-5f811b395762-common": "20.5.0",
29
- "@codingame/monaco-vscode-ff9fa663-eae3-5274-8573-c2b918871e4b-common": "20.5.0"
18
+ "@codingame/monaco-vscode-09e9b2e8-42a8-5a68-864f-bfcdad0ca1df-common": "21.0.1",
19
+ "@codingame/monaco-vscode-23b6fb38-5e58-5886-b34b-27abc4f5df02-common": "21.0.1",
20
+ "@codingame/monaco-vscode-27663a0b-1249-58ba-9085-e52d706b50bc-common": "21.0.1",
21
+ "@codingame/monaco-vscode-4fad3647-b95d-5c19-bab1-bb9de627a5ec-common": "21.0.1",
22
+ "@codingame/monaco-vscode-71c8dbff-4c98-552f-aef0-e72b00fdcfc0-common": "21.0.1",
23
+ "@codingame/monaco-vscode-9a5ab9e7-d838-5831-9eb4-e79ea3764dcb-common": "21.0.1",
24
+ "@codingame/monaco-vscode-api": "21.0.1",
25
+ "@codingame/monaco-vscode-bb83fe45-f4c7-5673-b9f1-5c409a63f19c-common": "21.0.1",
26
+ "@codingame/monaco-vscode-c2deffc4-ad68-5e63-8f95-9b89e0fc6898-common": "21.0.1",
27
+ "@codingame/monaco-vscode-d0569cfb-4706-5ad6-b0b0-5115ad8685db-common": "21.0.1",
28
+ "@codingame/monaco-vscode-dbfe5f85-b426-55ed-a79b-5f811b395762-common": "21.0.1",
29
+ "@codingame/monaco-vscode-e39a1c8f-7892-5d9b-9987-7b10b79e1a0a-common": "21.0.1",
30
+ "@codingame/monaco-vscode-ff9fa663-eae3-5274-8573-c2b918871e4b-common": "21.0.1"
30
31
  },
31
32
  "main": "index.js",
32
33
  "module": "index.js",
@@ -6,7 +6,7 @@ import { Disposable } from '@codingame/monaco-vscode-api/vscode/vs/base/common/l
6
6
  import { Event, Emitter } from '@codingame/monaco-vscode-api/vscode/vs/base/common/event';
7
7
  import { VIEW_PANE_ID } from '@codingame/monaco-vscode-ff9fa663-eae3-5274-8573-c2b918871e4b-common/vscode/vs/workbench/contrib/scm/common/scm';
8
8
  import { ISCMService, ISCMViewService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/scm/common/scm.service';
9
- import { NumberBadge } from '@codingame/monaco-vscode-d941ac7b-412f-57e3-b1bf-f6b0eb253b21-common/vscode/vs/workbench/services/activity/common/activity';
9
+ import { NumberBadge } from '@codingame/monaco-vscode-9a5ab9e7-d838-5831-9eb4-e79ea3764dcb-common/vscode/vs/workbench/services/activity/common/activity';
10
10
  import { IActivityService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/activity/common/activity.service';
11
11
  import { RawContextKey } from '@codingame/monaco-vscode-api/vscode/vs/platform/contextkey/common/contextkey';
12
12
  import { IContextKeyService } from '@codingame/monaco-vscode-api/vscode/vs/platform/contextkey/common/contextkey.service';
@@ -87,7 +87,6 @@ let SCMActiveRepositoryController = class SCMActiveRepositoryController extends
87
87
  this._updateActivityCountBadge(countBadge, store);
88
88
  }));
89
89
  this._register(autorunWithStore((reader, store) => {
90
- this._repositories.read(reader);
91
90
  const repository = this.scmViewService.activeRepository.read(reader);
92
91
  const commands = repository?.provider.statusBarCommands.read(reader);
93
92
  this._updateStatusBar(repository, commands ?? [], store);
@@ -105,7 +104,7 @@ let SCMActiveRepositoryController = class SCMActiveRepositoryController extends
105
104
  if (count === 0) {
106
105
  return;
107
106
  }
108
- const badge = ( new NumberBadge(count, num => ( localize(9723, '{0} pending changes', num))));
107
+ const badge = ( new NumberBadge(count, num => ( localize(9885, '{0} pending changes', num))));
109
108
  store.add(this.activityService.showViewActivity(VIEW_PANE_ID, { badge }));
110
109
  }
111
110
  _updateStatusBar(repository, commands, store) {
@@ -122,7 +121,7 @@ let SCMActiveRepositoryController = class SCMActiveRepositoryController extends
122
121
  if (repoAgnosticActionName && typeof repoAgnosticActionName === 'string') {
123
122
  repoAgnosticActionName = repoAgnosticActionName
124
123
  .substring(0, repoAgnosticActionName.lastIndexOf('/'))
125
- .replace(/^git\./, '');
124
+ .replace(/^(?:git\.|remoteHub\.)/, '');
126
125
  if (repoAgnosticActionName.length > 1) {
127
126
  repoAgnosticActionName = repoAgnosticActionName[0].toLocaleUpperCase() + repoAgnosticActionName.slice(1);
128
127
  }
@@ -131,7 +130,7 @@ let SCMActiveRepositoryController = class SCMActiveRepositoryController extends
131
130
  repoAgnosticActionName = '';
132
131
  }
133
132
  const statusbarEntry = {
134
- name: ( localize(9724, "Source Control")) + (repoAgnosticActionName ? ` ${repoAgnosticActionName}` : ''),
133
+ name: ( localize(9886, "Source Control")) + (repoAgnosticActionName ? ` ${repoAgnosticActionName}` : ''),
135
134
  text: command.title,
136
135
  ariaLabel: tooltip,
137
136
  tooltip,
@@ -146,7 +145,7 @@ let SCMActiveRepositoryController = class SCMActiveRepositoryController extends
146
145
  ? `$(${repository.provider.iconPath.id})`
147
146
  : '$(repo)';
148
147
  const repositoryStatusbarEntry = {
149
- name: ( localize(9725, "Source Control Provider")),
148
+ name: ( localize(9887, "Source Control Provider")),
150
149
  text: `${icon} ${repository.provider.name}`,
151
150
  ariaLabel: label,
152
151
  tooltip: label,
@@ -175,8 +174,8 @@ let SCMActiveResourceContextKeyController = class SCMActiveResourceContextKeyCon
175
174
  this.scmService = scmService;
176
175
  this.uriIdentityService = uriIdentityService;
177
176
  this._onDidRepositoryChange = ( new Emitter());
178
- const activeResourceHasChangesContextKey = ( new RawContextKey('scmActiveResourceHasChanges', false, ( localize(9726, "Whether the active resource has changes"))));
179
- const activeResourceRepositoryContextKey = ( new RawContextKey('scmActiveResourceRepository', undefined, ( localize(9727, "The active resource's repository"))));
177
+ const activeResourceHasChangesContextKey = ( new RawContextKey('scmActiveResourceHasChanges', false, ( localize(9888, "Whether the active resource has changes"))));
178
+ const activeResourceRepositoryContextKey = ( new RawContextKey('scmActiveResourceRepository', undefined, ( localize(9889, "The active resource's repository"))));
180
179
  this._repositories = observableFromEvent(this, Event.any(this.scmService.onDidAddRepository, this.scmService.onDidRemoveRepository), () => this.scmService.repositories);
181
180
  this._store.add(autorunWithStore((reader, store) => {
182
181
  for (const repository of this._repositories.read(reader)) {
@@ -45,6 +45,10 @@
45
45
  display: none;
46
46
  }
47
47
 
48
+ .scm-view .scm-provider .monaco-icon-label-container {
49
+ display: flex;
50
+ }
51
+
48
52
  .scm-view .scm-provider > .monaco-icon-label {
49
53
  flex: 1;
50
54
  }
@@ -494,6 +498,10 @@
494
498
  font-weight: normal;
495
499
  }
496
500
 
501
+ .scm-view.scm-repositories-view .scm-provider .monaco-icon-label-container {
502
+ display: flex;
503
+ }
504
+
497
505
  /* History item hover */
498
506
 
499
507
  .monaco-hover.history-item-hover p:first-child {
@@ -278,7 +278,7 @@ SCMMenus = ( __decorate([
278
278
  ( __param(1, IInstantiationService))
279
279
  ], SCMMenus));
280
280
  MenuRegistry.appendMenuItem(MenuId.SCMResourceContext, {
281
- title: ( localize(9728, "Share")),
281
+ title: ( localize(9890, "Share")),
282
282
  submenu: MenuId.SCMResourceContextShare,
283
283
  group: '45_share',
284
284
  order: 3,
@@ -61,7 +61,7 @@ let QuickDiffDecorator = QuickDiffDecorator_1 = class QuickDiffDecorator extends
61
61
  const gutter = decorations === 'all' || decorations === 'gutter';
62
62
  const overview = decorations === 'all' || decorations === 'overview';
63
63
  const minimap = decorations === 'all' || decorations === 'minimap';
64
- const diffAdded = ( localize(9729, 'Added lines'));
64
+ const diffAdded = ( localize(9891, 'Added lines'));
65
65
  const diffAddedOptions = {
66
66
  gutter,
67
67
  overview: { active: overview, color: overviewRulerAddedForeground },
@@ -72,7 +72,7 @@ let QuickDiffDecorator = QuickDiffDecorator_1 = class QuickDiffDecorator extends
72
72
  this.addedPatternOptions = QuickDiffDecorator_1.createDecoration('dirty-diff-added primary pattern', diffAdded, diffAddedOptions);
73
73
  this.addedSecondaryOptions = QuickDiffDecorator_1.createDecoration('dirty-diff-added secondary', diffAdded, diffAddedOptions);
74
74
  this.addedSecondaryPatternOptions = QuickDiffDecorator_1.createDecoration('dirty-diff-added secondary pattern', diffAdded, diffAddedOptions);
75
- const diffModified = ( localize(9730, 'Changed lines'));
75
+ const diffModified = ( localize(9892, 'Changed lines'));
76
76
  const diffModifiedOptions = {
77
77
  gutter,
78
78
  overview: { active: overview, color: overviewRulerModifiedForeground },
@@ -83,7 +83,7 @@ let QuickDiffDecorator = QuickDiffDecorator_1 = class QuickDiffDecorator extends
83
83
  this.modifiedPatternOptions = QuickDiffDecorator_1.createDecoration('dirty-diff-modified primary pattern', diffModified, diffModifiedOptions);
84
84
  this.modifiedSecondaryOptions = QuickDiffDecorator_1.createDecoration('dirty-diff-modified secondary', diffModified, diffModifiedOptions);
85
85
  this.modifiedSecondaryPatternOptions = QuickDiffDecorator_1.createDecoration('dirty-diff-modified secondary pattern', diffModified, diffModifiedOptions);
86
- const diffDeleted = ( localize(9731, 'Removed lines'));
86
+ const diffDeleted = ( localize(9893, 'Removed lines'));
87
87
  const diffDeletedOptions = {
88
88
  gutter,
89
89
  overview: { active: overview, color: overviewRulerDeletedForeground },
@@ -88,7 +88,7 @@ let QuickDiffModel = class QuickDiffModel extends Disposable {
88
88
  this._originalEditorModelsDisposables = this._register(( new DisposableStore()));
89
89
  this._disposed = false;
90
90
  this._quickDiffs = [];
91
- this._diffDelayer = ( new ThrottledDelayer(200));
91
+ this._diffDelayer = this._register(( new ThrottledDelayer(200)));
92
92
  this._onDidChange = ( new Emitter());
93
93
  this.onDidChange = this._onDidChange.event;
94
94
  this._allChanges = [];
@@ -279,7 +279,7 @@ let QuickDiffModel = class QuickDiffModel extends Disposable {
279
279
  return [];
280
280
  }
281
281
  this._originalEditorModels.set(quickDiff.originalResource, ref.object);
282
- if (isTextFileEditorModel(ref.object)) {
282
+ if (isTextFileEditorModel(ref.object) && !ref.object.isDirty()) {
283
283
  const encoding = this._model.getEncoding();
284
284
  if (encoding) {
285
285
  ref.object.setEncoding(encoding, EncodingMode.Decode);
@@ -68,7 +68,7 @@ let QuickDiffPickerViewItem = class QuickDiffPickerViewItem extends SelectAction
68
68
  const peekTitleColor = theme.getColor(peekViewTitleBackground);
69
69
  const opaqueTitleColor = peekTitleColor?.makeOpaque(editorBackgroundColor) ?? editorBackgroundColor;
70
70
  styles.selectBackground = ( ( opaqueTitleColor.lighten(.6)).toString());
71
- super(null, action, [], 0, contextViewService, styles, { ariaLabel: ( localize(9732, 'Switch quick diff base')), useCustomDrawn: !hasNativeContextMenu(configurationService) });
71
+ super(null, action, [], 0, contextViewService, styles, { ariaLabel: ( localize(9894, 'Switch quick diff base')), useCustomDrawn: !hasNativeContextMenu(configurationService) });
72
72
  this.optionsItems = [];
73
73
  }
74
74
  setSelection(quickDiffs, providerId) {
@@ -91,7 +91,7 @@ QuickDiffPickerViewItem = ( __decorate([
91
91
  ], QuickDiffPickerViewItem));
92
92
  class QuickDiffPickerBaseAction extends Action {
93
93
  static { this.ID = 'quickDiff.base.switch'; }
94
- static { this.LABEL = ( localize(9733, "Switch Quick Diff Base")); }
94
+ static { this.LABEL = ( localize(9895, "Switch Quick Diff Base")); }
95
95
  constructor(callback) {
96
96
  super(QuickDiffPickerBaseAction.ID, QuickDiffPickerBaseAction.LABEL, undefined, undefined);
97
97
  this.callback = callback;
@@ -218,14 +218,14 @@ let QuickDiffWidget = class QuickDiffWidget extends PeekViewWidget {
218
218
  .find(quickDiff => quickDiff.id === this._providerId)?.label ?? '';
219
219
  detail = this.model.changes.length > 1
220
220
  ? ( localize(
221
- 9734,
221
+ 9896,
222
222
  "{0} - {1} of {2} changes",
223
223
  label,
224
224
  providerIndex + 1,
225
225
  providerChanges.length
226
226
  ))
227
227
  : ( localize(
228
- 9735,
228
+ 9897,
229
229
  "{0} - {1} of {2} change",
230
230
  label,
231
231
  providerIndex + 1,
@@ -235,8 +235,8 @@ let QuickDiffWidget = class QuickDiffWidget extends PeekViewWidget {
235
235
  }
236
236
  else {
237
237
  detail = this.model.changes.length > 1
238
- ? ( localize(9736, "{0} of {1} changes", providerIndex + 1, providerChanges.length))
239
- : ( localize(9737, "{0} of {1} change", providerIndex + 1, providerChanges.length));
238
+ ? ( localize(9898, "{0} of {1} changes", providerIndex + 1, providerChanges.length))
239
+ : ( localize(9899, "{0} of {1} change", providerIndex + 1, providerChanges.length));
240
240
  this.dropdownContainer.style.display = 'inherit';
241
241
  }
242
242
  this.setTitle(this.title, detail);
@@ -285,7 +285,7 @@ let QuickDiffWidget = class QuickDiffWidget extends PeekViewWidget {
285
285
  this._actionbarWidget.clear();
286
286
  this._actionbarWidget.push(actions.reverse(), { label: false, icon: true });
287
287
  this._actionbarWidget.push([next, previous], { label: false, icon: true });
288
- this._actionbarWidget.push(this._disposables.add(( new Action('peekview.close', ( localize(9738, "Close")), ThemeIcon.asClassName(Codicon.close), true, () => this.dispose()))), { label: false, icon: true });
288
+ this._actionbarWidget.push(this._disposables.add(( new Action('peekview.close', ( localize(9900, "Close")), ThemeIcon.asClassName(Codicon.close), true, () => this.dispose()))), { label: false, icon: true });
289
289
  }
290
290
  updateDropdown() {
291
291
  const quickDiffs = this.getQuickDiffsContainingChange();
@@ -636,7 +636,7 @@ class ShowPreviousChangeAction extends EditorAction {
636
636
  constructor(outerEditor) {
637
637
  super({
638
638
  id: 'editor.action.dirtydiff.previous',
639
- label: ( localize2(9739, "Show Previous Change")),
639
+ label: ( localize2(9901, "Show Previous Change")),
640
640
  precondition: ( TextCompareEditorActiveContext.toNegated()),
641
641
  kbOpts: { kbExpr: EditorContextKeys.editorTextFocus, primary: KeyMod.Shift | KeyMod.Alt | KeyCode.F3, weight: KeybindingWeight.EditorContrib }
642
642
  });
@@ -662,7 +662,7 @@ class ShowNextChangeAction extends EditorAction {
662
662
  constructor(outerEditor) {
663
663
  super({
664
664
  id: 'editor.action.dirtydiff.next',
665
- label: ( localize2(9740, "Show Next Change")),
665
+ label: ( localize2(9902, "Show Next Change")),
666
666
  precondition: ( TextCompareEditorActiveContext.toNegated()),
667
667
  kbOpts: { kbExpr: EditorContextKeys.editorTextFocus, primary: KeyMod.Alt | KeyCode.F3, weight: KeybindingWeight.EditorContrib }
668
668
  });
@@ -688,7 +688,7 @@ class GotoPreviousChangeAction extends EditorAction {
688
688
  constructor() {
689
689
  super({
690
690
  id: 'workbench.action.editor.previousChange',
691
- label: ( localize2(9741, "Go to Previous Change")),
691
+ label: ( localize2(9903, "Go to Previous Change")),
692
692
  precondition: ( ContextKeyExpr.and(( TextCompareEditorActiveContext.toNegated()), ( quickDiffDecorationCount.notEqualsTo(0)))),
693
693
  kbOpts: { kbExpr: EditorContextKeys.editorTextFocus, primary: KeyMod.Shift | KeyMod.Alt | KeyCode.F5, weight: KeybindingWeight.EditorContrib }
694
694
  });
@@ -723,7 +723,7 @@ class GotoNextChangeAction extends EditorAction {
723
723
  constructor() {
724
724
  super({
725
725
  id: 'workbench.action.editor.nextChange',
726
- label: ( localize2(9742, "Go to Next Change")),
726
+ label: ( localize2(9904, "Go to Next Change")),
727
727
  precondition: ( ContextKeyExpr.and(( TextCompareEditorActiveContext.toNegated()), ( quickDiffDecorationCount.notEqualsTo(0)))),
728
728
  kbOpts: { kbExpr: EditorContextKeys.editorTextFocus, primary: KeyMod.Alt | KeyCode.F5, weight: KeybindingWeight.EditorContrib }
729
729
  });
@@ -758,7 +758,7 @@ MenuRegistry.appendMenuItem(MenuId.MenubarGoMenu, {
758
758
  group: '7_change_nav',
759
759
  command: {
760
760
  id: 'editor.action.dirtydiff.next',
761
- title: ( localize(9743, "Next &&Change"))
761
+ title: ( localize(9905, "Next &&Change"))
762
762
  },
763
763
  order: 1
764
764
  });
@@ -766,7 +766,7 @@ MenuRegistry.appendMenuItem(MenuId.MenubarGoMenu, {
766
766
  group: '7_change_nav',
767
767
  command: {
768
768
  id: 'editor.action.dirtydiff.previous',
769
- title: ( localize(9744, "Previous &&Change"))
769
+ title: ( localize(9906, "Previous &&Change"))
770
770
  },
771
771
  order: 2
772
772
  });