@codingame/monaco-vscode-views-service-override 1.83.2 → 1.83.3
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 +2 -2
- package/vscode/src/vs/base/browser/ui/tree/treeDefaults.js +1 -1
- package/vscode/src/vs/workbench/api/browser/viewsExtensionPoint.js +50 -179
- package/vscode/src/vs/workbench/browser/parts/activitybar/activitybarActions.js +44 -21
- package/vscode/src/vs/workbench/browser/parts/activitybar/activitybarPart.js +12 -12
- package/vscode/src/vs/workbench/browser/parts/auxiliarybar/auxiliaryBarPart.js +3 -3
- package/vscode/src/vs/workbench/browser/parts/compositeBar.js +2 -2
- package/vscode/src/vs/workbench/browser/parts/compositePart.js +4 -4
- package/vscode/src/vs/workbench/browser/parts/editor/breadcrumbsControl.js +24 -18
- package/vscode/src/vs/workbench/browser/parts/editor/breadcrumbsPicker.js +2 -2
- package/vscode/src/vs/workbench/browser/parts/editor/editorDropTarget.js +2 -6
- package/vscode/src/vs/workbench/browser/parts/editor/editorGroupView.js +5 -5
- package/vscode/src/vs/workbench/browser/parts/editor/editorGroupWatermark.js +12 -18
- package/vscode/src/vs/workbench/browser/parts/editor/editorPanes.js +3 -3
- package/vscode/src/vs/workbench/browser/parts/editor/editorTabsControl.js +3 -3
- package/vscode/src/vs/workbench/browser/parts/editor/multiEditorTabsControl.js +5 -2
- package/vscode/src/vs/workbench/browser/parts/panel/panelPart.js +16 -8
- package/vscode/src/vs/workbench/browser/parts/views/checkbox.js +2 -2
- package/vscode/src/vs/workbench/browser/parts/views/treeView.js +20 -28
- package/vscode/src/vs/workbench/contrib/callHierarchy/browser/callHierarchy.contribution.js +20 -24
- package/vscode/src/vs/workbench/contrib/callHierarchy/browser/callHierarchyPeek.js +6 -6
- package/vscode/src/vs/workbench/contrib/callHierarchy/browser/callHierarchyTree.js +4 -4
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/find/simpleFindWidget.js +10 -15
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/outline/documentSymbolsOutline.js +4 -2
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/outline/documentSymbolsTree.js +4 -9
- package/vscode/src/vs/workbench/contrib/customEditor/common/contributedCustomEditors.js +1 -1
- package/vscode/src/vs/workbench/contrib/customEditor/common/extensionPoint.js +8 -29
- package/vscode/src/vs/workbench/contrib/files/browser/editors/binaryFileEditor.js +2 -2
- package/vscode/src/vs/workbench/contrib/files/browser/editors/textFileEditor.js +12 -19
- package/vscode/src/vs/workbench/contrib/files/browser/editors/textFileSaveErrorHandler.js +17 -55
- package/vscode/src/vs/workbench/contrib/files/browser/fileActions.contribution.js +110 -38
- package/vscode/src/vs/workbench/contrib/files/browser/fileCommands.js +6 -11
- package/vscode/src/vs/workbench/contrib/files/browser/files.contribution2.js +463 -3
- package/vscode/src/vs/workbench/contrib/files/browser/workspaceWatcher.js +5 -11
- package/vscode/src/vs/workbench/contrib/files/common/dirtyFilesIndicator.js +4 -1
- package/vscode/src/vs/workbench/contrib/languageDetection/browser/languageDetection.contribution.js +6 -6
- package/vscode/src/vs/workbench/contrib/languageStatus/browser/languageStatus.contribution.js +31 -23
- package/vscode/src/vs/workbench/contrib/outline/browser/outline.contribution.js +37 -76
- package/vscode/src/vs/workbench/contrib/outline/browser/outlinePane.js +4 -4
- package/vscode/src/vs/workbench/contrib/remote/browser/remoteExplorer.js +5 -21
- package/vscode/src/vs/workbench/contrib/remote/browser/remoteIcons.js +17 -23
- package/vscode/src/vs/workbench/contrib/remote/browser/tunnelView.js +62 -117
- package/vscode/src/vs/workbench/contrib/typeHierarchy/browser/typeHierarchy.contribution.js +18 -16
- package/vscode/src/vs/workbench/contrib/typeHierarchy/browser/typeHierarchyPeek.js +6 -6
- package/vscode/src/vs/workbench/contrib/typeHierarchy/browser/typeHierarchyTree.js +4 -4
- package/vscode/src/vs/workbench/contrib/webview/browser/webviewElement.js +2 -2
- package/vscode/src/vs/workbench/contrib/webviewPanel/browser/webviewCommands.js +5 -5
- package/vscode/src/vs/workbench/contrib/webviewPanel/browser/webviewPanel.contribution.js +2 -2
- package/vscode/src/vs/workbench/services/editor/browser/editorResolverService.js +10 -25
- package/vscode/src/vs/workbench/services/history/browser/historyService.js +37 -28
- package/vscode/src/vs/workbench/services/hover/browser/hoverWidget.js +2 -2
- package/vscode/src/vs/workbench/services/userDataProfile/common/userDataProfileIcons.js +2 -2
- package/vscode/src/vs/workbench/services/views/browser/viewDescriptorService.js +3 -3
- package/vscode/src/vs/workbench/services/views/common/viewContainerModel.js +2 -2
|
@@ -84,11 +84,8 @@ class IconColumn {
|
|
|
84
84
|
}
|
|
85
85
|
class PortColumn {
|
|
86
86
|
constructor() {
|
|
87
|
-
this.label =
|
|
88
|
-
this.tooltip = (
|
|
89
|
-
'tunnel.portColumn.tooltip',
|
|
90
|
-
"The label and remote port number of the forwarded port."
|
|
91
|
-
));
|
|
87
|
+
this.label = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnel.portColumn.label', "Port");
|
|
88
|
+
this.tooltip = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnel.portColumn.tooltip', "The label and remote port number of the forwarded port.");
|
|
92
89
|
this.weight = 1;
|
|
93
90
|
this.templateId = 'actionbar';
|
|
94
91
|
}
|
|
@@ -110,11 +107,8 @@ class PortColumn {
|
|
|
110
107
|
}
|
|
111
108
|
class LocalAddressColumn {
|
|
112
109
|
constructor() {
|
|
113
|
-
this.label =
|
|
114
|
-
this.tooltip = (
|
|
115
|
-
'tunnel.addressColumn.tooltip',
|
|
116
|
-
"The address that the forwarded port is available at."
|
|
117
|
-
));
|
|
110
|
+
this.label = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnel.addressColumn.label', "Forwarded Address");
|
|
111
|
+
this.tooltip = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnel.addressColumn.tooltip', "The address that the forwarded port is available at.");
|
|
118
112
|
this.weight = 1;
|
|
119
113
|
this.templateId = 'actionbar';
|
|
120
114
|
}
|
|
@@ -142,18 +136,18 @@ class LocalAddressColumn {
|
|
|
142
136
|
let clickLabel = '';
|
|
143
137
|
if (editorConf.multiCursorModifier === 'ctrlCmd') {
|
|
144
138
|
if (isMacintosh) {
|
|
145
|
-
clickLabel =
|
|
139
|
+
clickLabel = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'portsLink.followLinkAlt.mac', "option + click");
|
|
146
140
|
}
|
|
147
141
|
else {
|
|
148
|
-
clickLabel =
|
|
142
|
+
clickLabel = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'portsLink.followLinkAlt', "alt + click");
|
|
149
143
|
}
|
|
150
144
|
}
|
|
151
145
|
else {
|
|
152
146
|
if (isMacintosh) {
|
|
153
|
-
clickLabel =
|
|
147
|
+
clickLabel = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'portsLink.followLinkCmd', "cmd + click");
|
|
154
148
|
}
|
|
155
149
|
else {
|
|
156
|
-
clickLabel =
|
|
150
|
+
clickLabel = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'portsLink.followLinkCtrl', "ctrl + click");
|
|
157
151
|
}
|
|
158
152
|
}
|
|
159
153
|
const markdown = ( new MarkdownString('', true));
|
|
@@ -164,11 +158,8 @@ class LocalAddressColumn {
|
|
|
164
158
|
}
|
|
165
159
|
class RunningProcessColumn {
|
|
166
160
|
constructor() {
|
|
167
|
-
this.label =
|
|
168
|
-
this.tooltip = (
|
|
169
|
-
'tunnel.processColumn.tooltip',
|
|
170
|
-
"The command line of the process that is using the port."
|
|
171
|
-
));
|
|
161
|
+
this.label = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnel.processColumn.label', "Running Process");
|
|
162
|
+
this.tooltip = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnel.processColumn.tooltip', "The command line of the process that is using the port.");
|
|
172
163
|
this.weight = 2;
|
|
173
164
|
this.templateId = 'actionbar';
|
|
174
165
|
}
|
|
@@ -182,11 +173,8 @@ class RunningProcessColumn {
|
|
|
182
173
|
}
|
|
183
174
|
class OriginColumn {
|
|
184
175
|
constructor() {
|
|
185
|
-
this.label =
|
|
186
|
-
this.tooltip = (
|
|
187
|
-
'tunnel.originColumn.tooltip',
|
|
188
|
-
"The source that a forwarded port originates from. Can be an extension, user forwarded, statically forwarded, or automatically forwarded."
|
|
189
|
-
));
|
|
176
|
+
this.label = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnel.originColumn.label', "Origin");
|
|
177
|
+
this.tooltip = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnel.originColumn.tooltip', "The source that a forwarded port originates from. Can be an extension, user forwarded, statically forwarded, or automatically forwarded.");
|
|
190
178
|
this.weight = 1;
|
|
191
179
|
this.templateId = 'actionbar';
|
|
192
180
|
}
|
|
@@ -201,8 +189,8 @@ class OriginColumn {
|
|
|
201
189
|
}
|
|
202
190
|
class PrivacyColumn {
|
|
203
191
|
constructor() {
|
|
204
|
-
this.label =
|
|
205
|
-
this.tooltip =
|
|
192
|
+
this.label = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnel.privacyColumn.label', "Visibility");
|
|
193
|
+
this.tooltip = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnel.privacyColumn.tooltip', "The availability of the forwarded port.");
|
|
206
194
|
this.weight = 1;
|
|
207
195
|
this.templateId = 'actionbar';
|
|
208
196
|
}
|
|
@@ -365,7 +353,7 @@ let ActionBarRenderer = class ActionBarRenderer extends Disposable {
|
|
|
365
353
|
container.style.paddingLeft = '5px';
|
|
366
354
|
const value = editableData.startingValue || '';
|
|
367
355
|
const inputBox = ( new InputBox(container, this.contextViewService, {
|
|
368
|
-
ariaLabel:
|
|
356
|
+
ariaLabel: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnelsView.input', "Press Enter to confirm or Escape to cancel."),
|
|
369
357
|
validationOptions: {
|
|
370
358
|
validation: (value) => {
|
|
371
359
|
const message = editableData.validationMessage(value);
|
|
@@ -531,36 +519,25 @@ class TunnelItem {
|
|
|
531
519
|
}
|
|
532
520
|
}
|
|
533
521
|
else if (this.hasRunningProcess) {
|
|
534
|
-
description =
|
|
522
|
+
description = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnelView.runningProcess.inacessable', "Process information unavailable");
|
|
535
523
|
}
|
|
536
524
|
return description;
|
|
537
525
|
}
|
|
538
526
|
get tooltipPostfix() {
|
|
539
527
|
let information;
|
|
540
528
|
if (this.localAddress) {
|
|
541
|
-
information = (
|
|
542
|
-
'remote.tunnel.tooltipForwarded',
|
|
543
|
-
"Remote port {0}:{1} forwarded to local address {2}. ",
|
|
544
|
-
this.remoteHost,
|
|
545
|
-
this.remotePort,
|
|
546
|
-
this.localAddress
|
|
547
|
-
));
|
|
529
|
+
information = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.tooltipForwarded', "Remote port {0}:{1} forwarded to local address {2}. ", this.remoteHost, this.remotePort, this.localAddress);
|
|
548
530
|
}
|
|
549
531
|
else {
|
|
550
|
-
information = (
|
|
551
|
-
'remote.tunnel.tooltipCandidate',
|
|
552
|
-
"Remote port {0}:{1} not forwarded. ",
|
|
553
|
-
this.remoteHost,
|
|
554
|
-
this.remotePort
|
|
555
|
-
));
|
|
532
|
+
information = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.tooltipCandidate', "Remote port {0}:{1} not forwarded. ", this.remoteHost, this.remotePort);
|
|
556
533
|
}
|
|
557
534
|
return information;
|
|
558
535
|
}
|
|
559
536
|
get iconTooltip() {
|
|
560
537
|
const isAdd = this.tunnelType === TunnelType.Add;
|
|
561
538
|
if (!isAdd) {
|
|
562
|
-
return `${this.processDescription ?
|
|
563
|
-
|
|
539
|
+
return `${this.processDescription ? nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnel.iconColumn.running', "Port has running process.") :
|
|
540
|
+
nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnel.iconColumn.notRunning', "No running process.")}`;
|
|
564
541
|
}
|
|
565
542
|
else {
|
|
566
543
|
return this.label;
|
|
@@ -569,7 +546,7 @@ class TunnelItem {
|
|
|
569
546
|
get portTooltip() {
|
|
570
547
|
const isAdd = this.tunnelType === TunnelType.Add;
|
|
571
548
|
if (!isAdd) {
|
|
572
|
-
return `${this.name ?
|
|
549
|
+
return `${this.name ? nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.tooltipName', "Port labeled {0}. ", this.name) : ''}`;
|
|
573
550
|
}
|
|
574
551
|
else {
|
|
575
552
|
return '';
|
|
@@ -587,14 +564,14 @@ class TunnelItem {
|
|
|
587
564
|
{
|
|
588
565
|
id: '',
|
|
589
566
|
themeIcon: Codicon.question.id,
|
|
590
|
-
label:
|
|
567
|
+
label: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnelPrivacy.unknown', "Unknown")
|
|
591
568
|
};
|
|
592
569
|
}
|
|
593
570
|
else {
|
|
594
571
|
return {
|
|
595
572
|
id: TunnelPrivacyId.Private,
|
|
596
573
|
themeIcon: privatePortIcon.id,
|
|
597
|
-
label:
|
|
574
|
+
label: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnelPrivacy.private', "Private")
|
|
598
575
|
};
|
|
599
576
|
}
|
|
600
577
|
}
|
|
@@ -604,7 +581,11 @@ const TunnelCloseableContextKey = ( new RawContextKey('tunnelCloseable', false,
|
|
|
604
581
|
const TunnelPrivacyContextKey = ( new RawContextKey('tunnelPrivacy', undefined, true));
|
|
605
582
|
const TunnelPrivacyEnabledContextKey = ( new RawContextKey('tunnelPrivacyEnabled', false, true));
|
|
606
583
|
const TunnelProtocolContextKey = ( new RawContextKey('tunnelProtocol', TunnelProtocol.Http, true));
|
|
607
|
-
const TunnelViewFocusContextKey = ( new RawContextKey(
|
|
584
|
+
const TunnelViewFocusContextKey = ( new RawContextKey(
|
|
585
|
+
'tunnelViewFocus',
|
|
586
|
+
false,
|
|
587
|
+
nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnel.focusContext', "Whether the Ports view has focus.")
|
|
588
|
+
));
|
|
608
589
|
const TunnelViewSelectionKeyName = 'tunnelViewSelection';
|
|
609
590
|
const TunnelViewSelectionContextKey = ( new RawContextKey(TunnelViewSelectionKeyName, undefined, true));
|
|
610
591
|
const TunnelViewMultiSelectionKeyName = 'tunnelViewMultiSelection';
|
|
@@ -613,7 +594,7 @@ const PortChangableContextKey = ( new RawContextKey('portChangable', false, true
|
|
|
613
594
|
let TunnelPanel = class TunnelPanel extends ViewPane {
|
|
614
595
|
static { TunnelPanel_1 = this; }
|
|
615
596
|
static { this.ID = TUNNEL_VIEW_ID; }
|
|
616
|
-
static { this.TITLE =
|
|
597
|
+
static { this.TITLE = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel', "Ports"); }
|
|
617
598
|
constructor(viewModel, options, keybindingService, contextMenuService, contextKeyService, configurationService, instantiationService, viewDescriptorService, openerService, quickInputService, commandService, menuService, themeService, remoteExplorerService, telemetryService, tunnelService, contextViewService, hoverService) {
|
|
618
599
|
super(options, keybindingService, contextMenuService, configurationService, contextKeyService, viewDescriptorService, instantiationService, openerService, themeService, telemetryService);
|
|
619
600
|
this.viewModel = viewModel;
|
|
@@ -720,7 +701,7 @@ let TunnelPanel = class TunnelPanel extends ViewPane {
|
|
|
720
701
|
return item.label;
|
|
721
702
|
}
|
|
722
703
|
},
|
|
723
|
-
getWidgetAriaLabel: () =>
|
|
704
|
+
getWidgetAriaLabel: () => nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnelView', "Tunnel View")
|
|
724
705
|
},
|
|
725
706
|
openOnSingleClick: true
|
|
726
707
|
});
|
|
@@ -921,7 +902,7 @@ function isITunnelItem(item) {
|
|
|
921
902
|
var LabelTunnelAction;
|
|
922
903
|
( (function(LabelTunnelAction) {
|
|
923
904
|
LabelTunnelAction.ID = 'remote.tunnel.label';
|
|
924
|
-
LabelTunnelAction.LABEL =
|
|
905
|
+
LabelTunnelAction.LABEL = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.label', "Set Port Label");
|
|
925
906
|
LabelTunnelAction.COMMAND_ID_KEYWORD = 'label';
|
|
926
907
|
function handler() {
|
|
927
908
|
return async (accessor, arg) => {
|
|
@@ -953,7 +934,7 @@ var LabelTunnelAction;
|
|
|
953
934
|
resolve(changed ? { port: tunnelItem.remotePort, label: value } : undefined);
|
|
954
935
|
},
|
|
955
936
|
validationMessage: () => null,
|
|
956
|
-
placeholder:
|
|
937
|
+
placeholder: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnelsView.labelPlaceholder', "Port label"),
|
|
957
938
|
startingValue
|
|
958
939
|
});
|
|
959
940
|
}));
|
|
@@ -963,28 +944,18 @@ var LabelTunnelAction;
|
|
|
963
944
|
}
|
|
964
945
|
LabelTunnelAction.handler = handler;
|
|
965
946
|
})(LabelTunnelAction || (LabelTunnelAction = {})));
|
|
966
|
-
const invalidPortString = (
|
|
967
|
-
'remote.tunnelsView.portNumberValid',
|
|
968
|
-
"Forwarded port should be a number or a host:port."
|
|
969
|
-
));
|
|
947
|
+
const invalidPortString = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnelsView.portNumberValid', "Forwarded port should be a number or a host:port.");
|
|
970
948
|
const maxPortNumber = 65536;
|
|
971
|
-
const invalidPortNumberString = (
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
maxPortNumber
|
|
975
|
-
));
|
|
976
|
-
const requiresSudoString = ( nls.localize('remote.tunnelView.inlineElevationMessage', "May Require Sudo"));
|
|
977
|
-
const alreadyForwarded = ( nls.localize('remote.tunnelView.alreadyForwarded', "Port is already forwarded"));
|
|
949
|
+
const invalidPortNumberString = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnelsView.portNumberToHigh', "Port number must be \u2265 0 and < {0}.", maxPortNumber);
|
|
950
|
+
const requiresSudoString = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnelView.inlineElevationMessage', "May Require Sudo");
|
|
951
|
+
const alreadyForwarded = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnelView.alreadyForwarded', "Port is already forwarded");
|
|
978
952
|
var ForwardPortAction;
|
|
979
953
|
( (function(ForwardPortAction) {
|
|
980
954
|
ForwardPortAction.INLINE_ID = 'remote.tunnel.forwardInline';
|
|
981
955
|
ForwardPortAction.COMMANDPALETTE_ID = 'remote.tunnel.forwardCommandPalette';
|
|
982
|
-
ForwardPortAction.LABEL = { value:
|
|
983
|
-
ForwardPortAction.TREEITEM_LABEL =
|
|
984
|
-
const forwardPrompt = (
|
|
985
|
-
'remote.tunnel.forwardPrompt',
|
|
986
|
-
"Port number or address (eg. 3000 or 10.10.10.10:2000)."
|
|
987
|
-
));
|
|
956
|
+
ForwardPortAction.LABEL = { value: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.forward', "Forward a Port"), original: 'Forward a Port' };
|
|
957
|
+
ForwardPortAction.TREEITEM_LABEL = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.forwardItem', "Forward Port");
|
|
958
|
+
const forwardPrompt = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.forwardPrompt', "Port number or address (eg. 3000 or 10.10.10.10:2000).");
|
|
988
959
|
function validateInput(remoteExplorerService, tunnelService, value, canElevate) {
|
|
989
960
|
const parsed = parseAddress(value);
|
|
990
961
|
if (!parsed) {
|
|
@@ -1003,21 +974,10 @@ var ForwardPortAction;
|
|
|
1003
974
|
}
|
|
1004
975
|
function error(notificationService, tunnelOrError, host, port) {
|
|
1005
976
|
if (!tunnelOrError) {
|
|
1006
|
-
notificationService.warn((
|
|
1007
|
-
'remote.tunnel.forwardError',
|
|
1008
|
-
"Unable to forward {0}:{1}. The host may not be available or that remote port may already be forwarded",
|
|
1009
|
-
host,
|
|
1010
|
-
port
|
|
1011
|
-
)));
|
|
977
|
+
notificationService.warn(nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.forwardError', "Unable to forward {0}:{1}. The host may not be available or that remote port may already be forwarded", host, port));
|
|
1012
978
|
}
|
|
1013
979
|
else if (typeof tunnelOrError === 'string') {
|
|
1014
|
-
notificationService.warn((
|
|
1015
|
-
'remote.tunnel.forwardErrorProvided',
|
|
1016
|
-
"Unable to forward {0}:{1}. {2}",
|
|
1017
|
-
host,
|
|
1018
|
-
port,
|
|
1019
|
-
tunnelOrError
|
|
1020
|
-
)));
|
|
980
|
+
notificationService.warn(nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.forwardErrorProvided', "Unable to forward {0}:{1}. {2}", host, port, tunnelOrError));
|
|
1021
981
|
}
|
|
1022
982
|
}
|
|
1023
983
|
function inlineHandler() {
|
|
@@ -1076,11 +1036,7 @@ function makeTunnelPicks(tunnels, remoteExplorerService, tunnelService) {
|
|
|
1076
1036
|
}));
|
|
1077
1037
|
if (picks.length === 0) {
|
|
1078
1038
|
picks.push({
|
|
1079
|
-
label: (
|
|
1080
|
-
'remote.tunnel.closeNoPorts',
|
|
1081
|
-
"No ports currently forwarded. Try running the {0} command",
|
|
1082
|
-
ForwardPortAction.LABEL.value
|
|
1083
|
-
))
|
|
1039
|
+
label: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.closeNoPorts', "No ports currently forwarded. Try running the {0} command", ForwardPortAction.LABEL.value)
|
|
1084
1040
|
});
|
|
1085
1041
|
}
|
|
1086
1042
|
return picks;
|
|
@@ -1089,7 +1045,7 @@ var ClosePortAction;
|
|
|
1089
1045
|
( (function(ClosePortAction) {
|
|
1090
1046
|
ClosePortAction.INLINE_ID = 'remote.tunnel.closeInline';
|
|
1091
1047
|
ClosePortAction.COMMANDPALETTE_ID = 'remote.tunnel.closeCommandPalette';
|
|
1092
|
-
ClosePortAction.LABEL = { value:
|
|
1048
|
+
ClosePortAction.LABEL = { value: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.close', "Stop Forwarding Port"), original: 'Stop Forwarding Port' };
|
|
1093
1049
|
function inlineHandler() {
|
|
1094
1050
|
return async (accessor, arg) => {
|
|
1095
1051
|
const contextKeyService = accessor.get(IContextKeyService);
|
|
@@ -1130,7 +1086,7 @@ var ClosePortAction;
|
|
|
1130
1086
|
const tunnelService = accessor.get(ITunnelService);
|
|
1131
1087
|
const commandService = accessor.get(ICommandService);
|
|
1132
1088
|
const picks = makeTunnelPicks(Array.from(( remoteExplorerService.tunnelModel.forwarded.values())).filter(tunnel => tunnel.closeable), remoteExplorerService, tunnelService);
|
|
1133
|
-
const result = await quickInputService.pick(picks, { placeHolder:
|
|
1089
|
+
const result = await quickInputService.pick(picks, { placeHolder: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.closePlaceholder', "Choose a port to stop forwarding") });
|
|
1134
1090
|
if (result && result.tunnel) {
|
|
1135
1091
|
await remoteExplorerService.close({ host: result.tunnel.remoteHost, port: result.tunnel.remotePort }, TunnelCloseReason.User);
|
|
1136
1092
|
}
|
|
@@ -1144,7 +1100,7 @@ var ClosePortAction;
|
|
|
1144
1100
|
var OpenPortInBrowserAction;
|
|
1145
1101
|
( (function(OpenPortInBrowserAction) {
|
|
1146
1102
|
OpenPortInBrowserAction.ID = 'remote.tunnel.open';
|
|
1147
|
-
OpenPortInBrowserAction.LABEL =
|
|
1103
|
+
OpenPortInBrowserAction.LABEL = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.open', "Open in Browser");
|
|
1148
1104
|
function handler() {
|
|
1149
1105
|
return async (accessor, arg) => {
|
|
1150
1106
|
let key;
|
|
@@ -1174,7 +1130,7 @@ var OpenPortInBrowserAction;
|
|
|
1174
1130
|
var OpenPortInPreviewAction;
|
|
1175
1131
|
( (function(OpenPortInPreviewAction) {
|
|
1176
1132
|
OpenPortInPreviewAction.ID = 'remote.tunnel.openPreview';
|
|
1177
|
-
OpenPortInPreviewAction.LABEL =
|
|
1133
|
+
OpenPortInPreviewAction.LABEL = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.openPreview', "Preview in Editor");
|
|
1178
1134
|
function handler() {
|
|
1179
1135
|
return async (accessor, arg) => {
|
|
1180
1136
|
let key;
|
|
@@ -1211,7 +1167,7 @@ var OpenPortInPreviewAction;
|
|
|
1211
1167
|
var OpenPortInBrowserCommandPaletteAction;
|
|
1212
1168
|
( (function(OpenPortInBrowserCommandPaletteAction) {
|
|
1213
1169
|
OpenPortInBrowserCommandPaletteAction.ID = 'remote.tunnel.openCommandPalette';
|
|
1214
|
-
OpenPortInBrowserCommandPaletteAction.LABEL =
|
|
1170
|
+
OpenPortInBrowserCommandPaletteAction.LABEL = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.openCommandPalette', "Open Port in Browser");
|
|
1215
1171
|
function handler() {
|
|
1216
1172
|
return async (accessor, arg) => {
|
|
1217
1173
|
const remoteExplorerService = accessor.get(IRemoteExplorerService);
|
|
@@ -1230,18 +1186,15 @@ var OpenPortInBrowserCommandPaletteAction;
|
|
|
1230
1186
|
}));
|
|
1231
1187
|
if (options.length === 0) {
|
|
1232
1188
|
options.push({
|
|
1233
|
-
label: (
|
|
1234
|
-
'remote.tunnel.openCommandPaletteNone',
|
|
1235
|
-
"No ports currently forwarded. Open the Ports view to get started."
|
|
1236
|
-
))
|
|
1189
|
+
label: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.openCommandPaletteNone', "No ports currently forwarded. Open the Ports view to get started.")
|
|
1237
1190
|
});
|
|
1238
1191
|
}
|
|
1239
1192
|
else {
|
|
1240
1193
|
options.push({
|
|
1241
|
-
label:
|
|
1194
|
+
label: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.openCommandPaletteView', "Open the Ports view...")
|
|
1242
1195
|
});
|
|
1243
1196
|
}
|
|
1244
|
-
const picked = await quickPickService.pick(options, { placeHolder:
|
|
1197
|
+
const picked = await quickPickService.pick(options, { placeHolder: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.openCommandPalettePick', "Choose the port to open") });
|
|
1245
1198
|
if (picked && picked.tunnel) {
|
|
1246
1199
|
return OpenPortInBrowserAction.run(model, openerService, makeAddress(picked.tunnel.remoteHost, picked.tunnel.remotePort));
|
|
1247
1200
|
}
|
|
@@ -1258,8 +1211,8 @@ var CopyAddressAction;
|
|
|
1258
1211
|
( (function(CopyAddressAction) {
|
|
1259
1212
|
CopyAddressAction.INLINE_ID = 'remote.tunnel.copyAddressInline';
|
|
1260
1213
|
CopyAddressAction.COMMANDPALETTE_ID = 'remote.tunnel.copyAddressCommandPalette';
|
|
1261
|
-
CopyAddressAction.INLINE_LABEL =
|
|
1262
|
-
CopyAddressAction.COMMANDPALETTE_LABEL =
|
|
1214
|
+
CopyAddressAction.INLINE_LABEL = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.copyAddressInline', "Copy Local Address");
|
|
1215
|
+
CopyAddressAction.COMMANDPALETTE_LABEL = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.copyAddressCommandPalette', "Copy Forwarded Port Address");
|
|
1263
1216
|
async function copyAddress(remoteExplorerService, clipboardService, tunnelItem) {
|
|
1264
1217
|
const address = remoteExplorerService.tunnelModel.address(tunnelItem.remoteHost, tunnelItem.remotePort);
|
|
1265
1218
|
if (address) {
|
|
@@ -1291,7 +1244,7 @@ var CopyAddressAction;
|
|
|
1291
1244
|
const commandService = accessor.get(ICommandService);
|
|
1292
1245
|
const clipboardService = accessor.get(IClipboardService);
|
|
1293
1246
|
const tunnels = Array.from(( remoteExplorerService.tunnelModel.forwarded.values())).concat(Array.from(( remoteExplorerService.tunnelModel.detected.values())));
|
|
1294
|
-
const result = await quickInputService.pick(makeTunnelPicks(tunnels, remoteExplorerService, tunnelService), { placeHolder:
|
|
1247
|
+
const result = await quickInputService.pick(makeTunnelPicks(tunnels, remoteExplorerService, tunnelService), { placeHolder: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.copyAddressPlaceholdter', "Choose a forwarded port") });
|
|
1295
1248
|
if (result && result.tunnel) {
|
|
1296
1249
|
await copyAddress(remoteExplorerService, clipboardService, result.tunnel);
|
|
1297
1250
|
}
|
|
@@ -1305,10 +1258,10 @@ var CopyAddressAction;
|
|
|
1305
1258
|
var ChangeLocalPortAction;
|
|
1306
1259
|
( (function(ChangeLocalPortAction) {
|
|
1307
1260
|
ChangeLocalPortAction.ID = 'remote.tunnel.changeLocalPort';
|
|
1308
|
-
ChangeLocalPortAction.LABEL =
|
|
1261
|
+
ChangeLocalPortAction.LABEL = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.changeLocalPort', "Change Local Address Port");
|
|
1309
1262
|
function validateInput(tunnelService, value, canElevate) {
|
|
1310
1263
|
if (!value.match(/^[0-9]+$/)) {
|
|
1311
|
-
return { content:
|
|
1264
|
+
return { content: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnelsView.portShouldBeNumber', "Local port should be a number."), severity: Severity.Error };
|
|
1312
1265
|
}
|
|
1313
1266
|
else if (Number(value) >= maxPortNumber) {
|
|
1314
1267
|
return { content: invalidPortNumberString, severity: Severity.Error };
|
|
@@ -1351,17 +1304,12 @@ var ChangeLocalPortAction;
|
|
|
1351
1304
|
source: tunnelItem.source
|
|
1352
1305
|
});
|
|
1353
1306
|
if (newForward && (typeof newForward !== 'string') && newForward.tunnelLocalPort !== numberValue) {
|
|
1354
|
-
notificationService.warn((
|
|
1355
|
-
'remote.tunnel.changeLocalPortNumber',
|
|
1356
|
-
"The local port {0} is not available. Port number {1} has been used instead",
|
|
1357
|
-
value,
|
|
1358
|
-
newForward.tunnelLocalPort ?? newForward.localAddress
|
|
1359
|
-
)));
|
|
1307
|
+
notificationService.warn(nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.changeLocalPortNumber', "The local port {0} is not available. Port number {1} has been used instead", value, newForward.tunnelLocalPort ?? newForward.localAddress));
|
|
1360
1308
|
}
|
|
1361
1309
|
}
|
|
1362
1310
|
},
|
|
1363
1311
|
validationMessage: (value) => validateInput(tunnelService, value, tunnelService.canElevate),
|
|
1364
|
-
placeholder:
|
|
1312
|
+
placeholder: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnelsView.changePort', "New local port")
|
|
1365
1313
|
});
|
|
1366
1314
|
}
|
|
1367
1315
|
};
|
|
@@ -1393,8 +1341,8 @@ var SetTunnelProtocolAction;
|
|
|
1393
1341
|
( (function(SetTunnelProtocolAction) {
|
|
1394
1342
|
SetTunnelProtocolAction.ID_HTTP = 'remote.tunnel.setProtocolHttp';
|
|
1395
1343
|
SetTunnelProtocolAction.ID_HTTPS = 'remote.tunnel.setProtocolHttps';
|
|
1396
|
-
SetTunnelProtocolAction.LABEL_HTTP =
|
|
1397
|
-
SetTunnelProtocolAction.LABEL_HTTPS =
|
|
1344
|
+
SetTunnelProtocolAction.LABEL_HTTP = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.protocolHttp', "HTTP");
|
|
1345
|
+
SetTunnelProtocolAction.LABEL_HTTPS = nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'remote.tunnel.protocolHttps', "HTTPS");
|
|
1398
1346
|
async function handler(arg, protocol, remoteExplorerService) {
|
|
1399
1347
|
if (isITunnelItem(arg)) {
|
|
1400
1348
|
const attributes = {
|
|
@@ -1540,14 +1488,14 @@ MenuRegistry.appendMenuItem(MenuId.TunnelContext, ({
|
|
|
1540
1488
|
group: '2_localaddress',
|
|
1541
1489
|
order: 2,
|
|
1542
1490
|
submenu: MenuId.TunnelPrivacy,
|
|
1543
|
-
title:
|
|
1491
|
+
title: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnelContext.privacyMenu', "Port Visibility"),
|
|
1544
1492
|
when: ( ContextKeyExpr.and(isForwardedExpr, TunnelPrivacyEnabledContextKey))
|
|
1545
1493
|
}));
|
|
1546
1494
|
MenuRegistry.appendMenuItem(MenuId.TunnelContext, ({
|
|
1547
1495
|
group: '2_localaddress',
|
|
1548
1496
|
order: 3,
|
|
1549
1497
|
submenu: MenuId.TunnelProtocol,
|
|
1550
|
-
title:
|
|
1498
|
+
title: nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'tunnelContext.protocolMenu', "Change Port Protocol"),
|
|
1551
1499
|
when: ( ContextKeyExpr.and(isForwardedExpr, isNotMultiSelectionExpr))
|
|
1552
1500
|
}));
|
|
1553
1501
|
MenuRegistry.appendMenuItem(MenuId.TunnelContext, ({
|
|
@@ -1645,9 +1593,6 @@ registerColor('ports.iconRunningProcessForeground', {
|
|
|
1645
1593
|
dark: STATUS_BAR_REMOTE_ITEM_BACKGROUND,
|
|
1646
1594
|
hcDark: STATUS_BAR_REMOTE_ITEM_BACKGROUND,
|
|
1647
1595
|
hcLight: STATUS_BAR_REMOTE_ITEM_BACKGROUND
|
|
1648
|
-
}, (
|
|
1649
|
-
'portWithRunningProcess.foreground',
|
|
1650
|
-
"The color of the icon for a port that has an associated running process."
|
|
1651
|
-
)));
|
|
1596
|
+
}, nls.localizeWithPath('vs/workbench/contrib/remote/browser/tunnelView', 'portWithRunningProcess.foreground', "The color of the icon for a port that has an associated running process."));
|
|
1652
1597
|
|
|
1653
1598
|
export { ForwardPortAction, OpenPortInBrowserAction, OpenPortInPreviewAction, TunnelPanel, openPreviewEnabledContext };
|
|
@@ -8,7 +8,7 @@ import { registerEditorContribution, EditorAction2 } from 'monaco-editor/esm/vs/
|
|
|
8
8
|
import { ICodeEditorService } from 'monaco-editor/esm/vs/editor/browser/services/codeEditorService.js';
|
|
9
9
|
import { Range } from 'monaco-editor/esm/vs/editor/common/core/range.js';
|
|
10
10
|
import { PeekContext } from 'monaco-editor/esm/vs/editor/contrib/peekView/browser/peekView.js';
|
|
11
|
-
import {
|
|
11
|
+
import { localizeWithPath } from 'monaco-editor/esm/vs/nls.js';
|
|
12
12
|
import { registerAction2, MenuId } from 'monaco-editor/esm/vs/platform/actions/common/actions.js';
|
|
13
13
|
import { RawContextKey, ContextKeyExpr, IContextKeyService } from 'monaco-editor/esm/vs/platform/contextkey/common/contextkey.js';
|
|
14
14
|
import { IInstantiationService } from 'monaco-editor/esm/vs/platform/instantiation/common/instantiation.js';
|
|
@@ -17,18 +17,20 @@ import { TypeHierarchyTreePeekWidget } from './typeHierarchyPeek.js';
|
|
|
17
17
|
import { TypeHierarchyProviderRegistry, TypeHierarchyModel } from 'vscode/vscode/vs/workbench/contrib/typeHierarchy/common/typeHierarchy';
|
|
18
18
|
|
|
19
19
|
var TypeHierarchyController_1;
|
|
20
|
-
const _ctxHasTypeHierarchyProvider = ( new RawContextKey(
|
|
20
|
+
const _ctxHasTypeHierarchyProvider = ( new RawContextKey(
|
|
21
21
|
'editorHasTypeHierarchyProvider',
|
|
22
|
-
|
|
23
|
-
)
|
|
24
|
-
|
|
22
|
+
false,
|
|
23
|
+
localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchy.contribution', 'editorHasTypeHierarchyProvider', 'Whether a type hierarchy provider is available')
|
|
24
|
+
));
|
|
25
|
+
const _ctxTypeHierarchyVisible = ( new RawContextKey(
|
|
26
|
+
'typeHierarchyVisible',
|
|
27
|
+
false,
|
|
28
|
+
localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchy.contribution', 'typeHierarchyVisible', 'Whether type hierarchy peek is currently showing')
|
|
29
|
+
));
|
|
25
30
|
const _ctxTypeHierarchyDirection = ( new RawContextKey(
|
|
26
31
|
'typeHierarchyDirection',
|
|
27
32
|
undefined,
|
|
28
|
-
{ type: 'string', description: (
|
|
29
|
-
'typeHierarchyDirection',
|
|
30
|
-
'whether type hierarchy shows super types or subtypes'
|
|
31
|
-
)) }
|
|
33
|
+
{ type: 'string', description: localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchy.contribution', 'typeHierarchyDirection', 'whether type hierarchy shows super types or subtypes') }
|
|
32
34
|
));
|
|
33
35
|
function sanitizedDirection(candidate) {
|
|
34
36
|
return candidate === "subtypes" || candidate === "supertypes"
|
|
@@ -97,14 +99,14 @@ let TypeHierarchyController = class TypeHierarchyController {
|
|
|
97
99
|
this._widget.showModel(model);
|
|
98
100
|
}
|
|
99
101
|
else {
|
|
100
|
-
this._widget.showMessage((
|
|
102
|
+
this._widget.showMessage(localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchy.contribution', 'no.item', "No results"));
|
|
101
103
|
}
|
|
102
104
|
}).catch(err => {
|
|
103
105
|
if (isCancellationError(err)) {
|
|
104
106
|
this.endTypeHierarchy();
|
|
105
107
|
return;
|
|
106
108
|
}
|
|
107
|
-
this._widget.showMessage((
|
|
109
|
+
this._widget.showMessage(localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchy.contribution', 'error', "Failed to show type hierarchy"));
|
|
108
110
|
});
|
|
109
111
|
}
|
|
110
112
|
async startTypeHierarchyFromTypeHierarchy() {
|
|
@@ -149,7 +151,7 @@ registerAction2(class PeekTypeHierarchyAction extends EditorAction2 {
|
|
|
149
151
|
constructor() {
|
|
150
152
|
super({
|
|
151
153
|
id: 'editor.showTypeHierarchy',
|
|
152
|
-
title: { value: (
|
|
154
|
+
title: { value: localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchy.contribution', 'title', "Peek Type Hierarchy"), original: 'Peek Type Hierarchy' },
|
|
153
155
|
menu: {
|
|
154
156
|
id: MenuId.EditorContextPeek,
|
|
155
157
|
group: 'navigation',
|
|
@@ -168,7 +170,7 @@ registerAction2(class extends EditorAction2 {
|
|
|
168
170
|
constructor() {
|
|
169
171
|
super({
|
|
170
172
|
id: 'editor.showSupertypes',
|
|
171
|
-
title: { value: (
|
|
173
|
+
title: { value: localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchy.contribution', 'title.supertypes', "Show Supertypes"), original: 'Show Supertypes' },
|
|
172
174
|
icon: Codicon.typeHierarchySuper,
|
|
173
175
|
precondition: ( ContextKeyExpr.and(_ctxTypeHierarchyVisible, ( _ctxTypeHierarchyDirection.isEqualTo("subtypes" )))),
|
|
174
176
|
keybinding: {
|
|
@@ -190,7 +192,7 @@ registerAction2(class extends EditorAction2 {
|
|
|
190
192
|
constructor() {
|
|
191
193
|
super({
|
|
192
194
|
id: 'editor.showSubtypes',
|
|
193
|
-
title: { value: (
|
|
195
|
+
title: { value: localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchy.contribution', 'title.subtypes', "Show Subtypes"), original: 'Show Subtypes' },
|
|
194
196
|
icon: Codicon.typeHierarchySub,
|
|
195
197
|
precondition: ( ContextKeyExpr.and(_ctxTypeHierarchyVisible, ( _ctxTypeHierarchyDirection.isEqualTo("supertypes" )))),
|
|
196
198
|
keybinding: {
|
|
@@ -212,7 +214,7 @@ registerAction2(class extends EditorAction2 {
|
|
|
212
214
|
constructor() {
|
|
213
215
|
super({
|
|
214
216
|
id: 'editor.refocusTypeHierarchy',
|
|
215
|
-
title: { value: (
|
|
217
|
+
title: { value: localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchy.contribution', 'title.refocusTypeHierarchy', "Refocus Type Hierarchy"), original: 'Refocus Type Hierarchy' },
|
|
216
218
|
precondition: _ctxTypeHierarchyVisible,
|
|
217
219
|
keybinding: {
|
|
218
220
|
weight: 200 ,
|
|
@@ -228,7 +230,7 @@ registerAction2(class extends EditorAction2 {
|
|
|
228
230
|
constructor() {
|
|
229
231
|
super({
|
|
230
232
|
id: 'editor.closeTypeHierarchy',
|
|
231
|
-
title: (
|
|
233
|
+
title: localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchy.contribution', 'close', 'Close'),
|
|
232
234
|
icon: Codicon.close,
|
|
233
235
|
precondition: _ctxTypeHierarchyVisible,
|
|
234
236
|
keybinding: {
|
|
@@ -11,7 +11,7 @@ import { Range } from 'monaco-editor/esm/vs/editor/common/core/range.js';
|
|
|
11
11
|
import { OverviewRulerLane } from 'monaco-editor/esm/vs/editor/common/model.js';
|
|
12
12
|
import { ITextModelService } from 'monaco-editor/esm/vs/editor/common/services/resolverService.js';
|
|
13
13
|
import * as peekView from 'monaco-editor/esm/vs/editor/contrib/peekView/browser/peekView.js';
|
|
14
|
-
import {
|
|
14
|
+
import { localizeWithPath } from 'monaco-editor/esm/vs/nls.js';
|
|
15
15
|
import { createAndFillInActionBarActions } from 'monaco-editor/esm/vs/platform/actions/browser/menuEntryActionViewItem.js';
|
|
16
16
|
import { MenuId, IMenuService } from 'monaco-editor/esm/vs/platform/actions/common/actions.js';
|
|
17
17
|
import { IContextKeyService } from 'monaco-editor/esm/vs/platform/contextkey/common/contextkey.js';
|
|
@@ -250,13 +250,13 @@ let TypeHierarchyTreePeekWidget = class TypeHierarchyTreePeekWidget extends peek
|
|
|
250
250
|
}
|
|
251
251
|
this._previewDisposable.add(value);
|
|
252
252
|
const title = this._direction === "supertypes"
|
|
253
|
-
? (
|
|
254
|
-
: (
|
|
253
|
+
? localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchyPeek', 'supertypes', "Supertypes of '{0}'", element.model.root.name)
|
|
254
|
+
: localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchyPeek', 'subtypes', "Subtypes of '{0}'", element.model.root.name);
|
|
255
255
|
this.setTitle(title);
|
|
256
256
|
}
|
|
257
257
|
showLoading() {
|
|
258
258
|
this._parent.dataset['state'] = "loading" ;
|
|
259
|
-
this.setTitle((
|
|
259
|
+
this.setTitle(localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchyPeek', 'title.loading', "Loading..."));
|
|
260
260
|
this._show();
|
|
261
261
|
}
|
|
262
262
|
showMessage(message) {
|
|
@@ -275,8 +275,8 @@ let TypeHierarchyTreePeekWidget = class TypeHierarchyTreePeekWidget extends peek
|
|
|
275
275
|
await this._tree.expand(root.element);
|
|
276
276
|
if (root.children.length === 0) {
|
|
277
277
|
this.showMessage(this._direction === "supertypes"
|
|
278
|
-
? (
|
|
279
|
-
: (
|
|
278
|
+
? localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchyPeek', 'empt.supertypes', "No supertypes of '{0}'", model.root.name)
|
|
279
|
+
: localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchyPeek', 'empt.subtypes', "No subtypes of '{0}'", model.root.name));
|
|
280
280
|
}
|
|
281
281
|
else {
|
|
282
282
|
this._parent.dataset['state'] = "data" ;
|
|
@@ -5,7 +5,7 @@ import { IconLabel } from 'monaco-editor/esm/vs/base/browser/ui/iconLabel/iconLa
|
|
|
5
5
|
import { SymbolKinds } from 'monaco-editor/esm/vs/editor/common/languages.js';
|
|
6
6
|
import { compare } from 'monaco-editor/esm/vs/base/common/strings.js';
|
|
7
7
|
import { Range } from 'monaco-editor/esm/vs/editor/common/core/range.js';
|
|
8
|
-
import {
|
|
8
|
+
import { localizeWithPath } from 'monaco-editor/esm/vs/nls.js';
|
|
9
9
|
import { ThemeIcon } from 'monaco-editor/esm/vs/base/common/themables.js';
|
|
10
10
|
|
|
11
11
|
class Type {
|
|
@@ -104,14 +104,14 @@ class AccessibilityProvider {
|
|
|
104
104
|
this.getDirection = getDirection;
|
|
105
105
|
}
|
|
106
106
|
getWidgetAriaLabel() {
|
|
107
|
-
return (
|
|
107
|
+
return localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchyTree', 'tree.aria', "Type Hierarchy");
|
|
108
108
|
}
|
|
109
109
|
getAriaLabel(element) {
|
|
110
110
|
if (this.getDirection() === "supertypes" ) {
|
|
111
|
-
return (
|
|
111
|
+
return localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchyTree', 'supertypes', "supertypes of {0}", element.item.name);
|
|
112
112
|
}
|
|
113
113
|
else {
|
|
114
|
-
return (
|
|
114
|
+
return localizeWithPath('vs/workbench/contrib/typeHierarchy/browser/typeHierarchyTree', 'subtypes', "subtypes of {0}", element.item.name);
|
|
115
115
|
}
|
|
116
116
|
}
|
|
117
117
|
}
|