@codingame/monaco-vscode-log-service-override 7.0.11 → 7.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { localize } from 'vscode/vscode/vs/nls';
|
|
2
2
|
|
|
3
|
-
const
|
|
4
|
-
const rendererLogLabel = ( localizeWithPath(_moduleId, 0, 'Window'));
|
|
3
|
+
const rendererLogLabel = ( localize(3251, 'Window'));
|
|
5
4
|
|
|
6
5
|
export { rendererLogLabel };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-log-service-override",
|
|
3
|
-
"version": "7.
|
|
3
|
+
"version": "7.1.1",
|
|
4
4
|
"keywords": [],
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "CodinGame",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
}
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"vscode": "npm:@codingame/monaco-vscode-api@7.
|
|
30
|
-
"@codingame/monaco-vscode-environment-service-override": "7.
|
|
29
|
+
"vscode": "npm:@codingame/monaco-vscode-api@7.1.1",
|
|
30
|
+
"@codingame/monaco-vscode-environment-service-override": "7.1.1"
|
|
31
31
|
}
|
|
32
32
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { __decorate, __param } from 'vscode/external/tslib/tslib.es6.js';
|
|
2
|
-
import {
|
|
2
|
+
import { localize2, localize } from 'vscode/vscode/vs/nls';
|
|
3
3
|
import { Registry } from 'vscode/vscode/vs/platform/registry/common/platform';
|
|
4
4
|
import { Categories } from 'vscode/vscode/vs/platform/action/common/actionCommonCategories';
|
|
5
5
|
import { registerAction2, Action2 } from 'vscode/vscode/vs/platform/actions/common/actions';
|
|
@@ -25,7 +25,6 @@ import { CounterSet } from 'vscode/vscode/vs/base/common/map';
|
|
|
25
25
|
import { IUriIdentityService } from 'vscode/vscode/vs/platform/uriIdentity/common/uriIdentity.service';
|
|
26
26
|
import { Schemas } from 'vscode/vscode/vs/base/common/network';
|
|
27
27
|
|
|
28
|
-
const _moduleId = "vs/workbench/contrib/logs/common/logs.contribution";
|
|
29
28
|
registerAction2(class extends Action2 {
|
|
30
29
|
constructor() {
|
|
31
30
|
super({
|
|
@@ -43,7 +42,7 @@ registerAction2(class extends Action2 {
|
|
|
43
42
|
constructor() {
|
|
44
43
|
super({
|
|
45
44
|
id: 'workbench.action.setDefaultLogLevel',
|
|
46
|
-
title: (
|
|
45
|
+
title: ( localize2(3252, "Set Default Log Level")),
|
|
47
46
|
category: Categories.Developer,
|
|
48
47
|
});
|
|
49
48
|
}
|
|
@@ -149,7 +148,7 @@ let LogOutputChannels = class LogOutputChannels extends Disposable {
|
|
|
149
148
|
}
|
|
150
149
|
const hasToAppendRemote = existingChannel && logger.resource.scheme === Schemas.vscodeRemote;
|
|
151
150
|
const id = hasToAppendRemote ? `${logger.id}.remote` : logger.id;
|
|
152
|
-
const label = hasToAppendRemote ? (
|
|
151
|
+
const label = hasToAppendRemote ? ( localize(3253, "{0} (Remote)", logger.name ?? logger.id)) : logger.name ?? logger.id;
|
|
153
152
|
this.outputChannelRegistry.registerChannel({ id, label, file: logger.resource, log: true, extensionId: logger.extensionId });
|
|
154
153
|
disposables.add(toDisposable(() => this.outputChannelRegistry.removeChannel(id)));
|
|
155
154
|
if (remoteLogger) {
|
|
@@ -188,7 +187,7 @@ let LogOutputChannels = class LogOutputChannels extends Disposable {
|
|
|
188
187
|
constructor() {
|
|
189
188
|
super({
|
|
190
189
|
id: showWindowLogActionId,
|
|
191
|
-
title: (
|
|
190
|
+
title: ( localize2(3254, "Show Window Log")),
|
|
192
191
|
category: Categories.Developer,
|
|
193
192
|
f1: true
|
|
194
193
|
});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { __decorate, __param } from 'vscode/external/tslib/tslib.es6.js';
|
|
2
|
-
import {
|
|
2
|
+
import { localize2, localize } from 'vscode/vscode/vs/nls';
|
|
3
3
|
import { Action } from 'vscode/vscode/vs/base/common/actions';
|
|
4
4
|
import { isLogLevel, LogLevel, LogLevelToLocalizedString } from 'vscode/vscode/vs/platform/log/common/log';
|
|
5
5
|
import { ILoggerService } from 'vscode/vscode/vs/platform/log/common/log.service';
|
|
@@ -15,11 +15,10 @@ import { ThemeIcon } from 'vscode/vscode/vs/base/common/themables';
|
|
|
15
15
|
import { DisposableStore } from 'vscode/vscode/vs/base/common/lifecycle';
|
|
16
16
|
|
|
17
17
|
var SetLogLevelAction_1;
|
|
18
|
-
const _moduleId = "vs/workbench/contrib/logs/common/logsActions";
|
|
19
18
|
let SetLogLevelAction = class SetLogLevelAction extends Action {
|
|
20
19
|
static { SetLogLevelAction_1 = this; }
|
|
21
20
|
static { this.ID = 'workbench.action.setLogLevel'; }
|
|
22
|
-
static { this.TITLE = (
|
|
21
|
+
static { this.TITLE = ( localize2(6161, "Set Log Level...")); }
|
|
23
22
|
constructor(id, label, quickInputService, loggerService, outputService, defaultLogLevelsService) {
|
|
24
23
|
super(id, label);
|
|
25
24
|
this.quickInputService = quickInputService;
|
|
@@ -56,19 +55,19 @@ let SetLogLevelAction = class SetLogLevelAction extends Action {
|
|
|
56
55
|
}
|
|
57
56
|
}
|
|
58
57
|
const entries = [];
|
|
59
|
-
entries.push({ type: 'separator', label: (
|
|
58
|
+
entries.push({ type: 'separator', label: ( localize(6162, "All")) });
|
|
60
59
|
entries.push(...this.getLogLevelEntries(defaultLogLevels.default, this.loggerService.getLogLevel(), true));
|
|
61
60
|
if (extensionLogs.length) {
|
|
62
|
-
entries.push({ type: 'separator', label: (
|
|
61
|
+
entries.push({ type: 'separator', label: ( localize(6163, "Extension Logs")) });
|
|
63
62
|
entries.push(...extensionLogs.sort((a, b) => a.label.localeCompare(b.label)));
|
|
64
63
|
}
|
|
65
|
-
entries.push({ type: 'separator', label: (
|
|
64
|
+
entries.push({ type: 'separator', label: ( localize(6164, "Logs")) });
|
|
66
65
|
entries.push(...logs.sort((a, b) => a.label.localeCompare(b.label)));
|
|
67
66
|
return (
|
|
68
67
|
(new Promise((resolve, reject) => {
|
|
69
68
|
const disposables = ( (new DisposableStore()));
|
|
70
69
|
const quickPick = this.quickInputService.createQuickPick();
|
|
71
|
-
quickPick.placeholder = (
|
|
70
|
+
quickPick.placeholder = ( localize(6165, "Set Log Level"));
|
|
72
71
|
quickPick.items = entries;
|
|
73
72
|
let selectedItem;
|
|
74
73
|
disposables.add(quickPick.onDidTriggerItemButton(e => {
|
|
@@ -100,7 +99,7 @@ let SetLogLevelAction = class SetLogLevelAction extends Action {
|
|
|
100
99
|
(new Promise((resolve, reject) => {
|
|
101
100
|
const disposables = ( (new DisposableStore()));
|
|
102
101
|
const quickPick = this.quickInputService.createQuickPick();
|
|
103
|
-
quickPick.placeholder = logChannel ? (
|
|
102
|
+
quickPick.placeholder = logChannel ? ( localize(6166, " {0}: Select log level", logChannel?.label)) : ( localize(6167, "Select log level"));
|
|
104
103
|
quickPick.items = entries;
|
|
105
104
|
quickPick.activeItems = entries.filter((entry) => entry.level === this.loggerService.getLogLevel());
|
|
106
105
|
let selectedItem;
|
|
@@ -124,7 +123,7 @@ let SetLogLevelAction = class SetLogLevelAction extends Action {
|
|
|
124
123
|
);
|
|
125
124
|
}
|
|
126
125
|
getLogLevelEntries(defaultLogLevel, currentLogLevel, canSetDefaultLogLevel) {
|
|
127
|
-
const button = canSetDefaultLogLevel ? { iconClass: ThemeIcon.asClassName(Codicon.checkAll), tooltip: (
|
|
126
|
+
const button = canSetDefaultLogLevel ? { iconClass: ThemeIcon.asClassName(Codicon.checkAll), tooltip: ( localize(6168, "Set as Default Log Level")) } : undefined;
|
|
128
127
|
return [
|
|
129
128
|
{ label: this.getLabel(LogLevel.Trace, currentLogLevel), level: LogLevel.Trace, description: this.getDescription(LogLevel.Trace, defaultLogLevel), buttons: button && defaultLogLevel !== LogLevel.Trace ? [button] : undefined },
|
|
130
129
|
{ label: this.getLabel(LogLevel.Debug, currentLogLevel), level: LogLevel.Debug, description: this.getDescription(LogLevel.Debug, defaultLogLevel), buttons: button && defaultLogLevel !== LogLevel.Debug ? [button] : undefined },
|
|
@@ -139,7 +138,7 @@ let SetLogLevelAction = class SetLogLevelAction extends Action {
|
|
|
139
138
|
return level === current ? `$(check) ${label}` : label;
|
|
140
139
|
}
|
|
141
140
|
getDescription(level, defaultLogLevel) {
|
|
142
|
-
return defaultLogLevel === level ? (
|
|
141
|
+
return defaultLogLevel === level ? ( localize(6169, "Default")) : undefined;
|
|
143
142
|
}
|
|
144
143
|
};
|
|
145
144
|
SetLogLevelAction = SetLogLevelAction_1 = ( (__decorate([
|
|
@@ -150,7 +149,7 @@ SetLogLevelAction = SetLogLevelAction_1 = ( (__decorate([
|
|
|
150
149
|
], SetLogLevelAction)));
|
|
151
150
|
(class OpenWindowSessionLogFileAction extends Action {
|
|
152
151
|
static { this.ID = 'workbench.action.openSessionLogFile'; }
|
|
153
|
-
static { this.TITLE = (
|
|
152
|
+
static { this.TITLE = ( localize2(6170, "Open Window Log File (Session)...")); }
|
|
154
153
|
constructor(id, label, environmentService, fileService, quickInputService, editorService) {
|
|
155
154
|
super(id, label);
|
|
156
155
|
this.environmentService = environmentService;
|
|
@@ -162,10 +161,10 @@ SetLogLevelAction = SetLogLevelAction_1 = ( (__decorate([
|
|
|
162
161
|
const sessionResult = await this.quickInputService.pick(this.getSessions().then(sessions => ( (sessions.map((s, index) => ({
|
|
163
162
|
id: ( (s.toString())),
|
|
164
163
|
label: basename(s),
|
|
165
|
-
description: index === 0 ? (
|
|
164
|
+
description: index === 0 ? ( localize(6171, "Current")) : undefined
|
|
166
165
|
}))))), {
|
|
167
166
|
canPickMany: false,
|
|
168
|
-
placeHolder: (
|
|
167
|
+
placeHolder: ( localize(6172, "Select Session"))
|
|
169
168
|
});
|
|
170
169
|
if (sessionResult) {
|
|
171
170
|
const logFileResult = await this.quickInputService.pick(this.getLogFiles(( (URI.parse(sessionResult.id)))).then(logFiles => ( (logFiles.map((s) => ({
|
|
@@ -173,7 +172,7 @@ SetLogLevelAction = SetLogLevelAction_1 = ( (__decorate([
|
|
|
173
172
|
label: basename(s)
|
|
174
173
|
}))))), {
|
|
175
174
|
canPickMany: false,
|
|
176
|
-
placeHolder: (
|
|
175
|
+
placeHolder: ( localize(6173, "Select Log file"))
|
|
177
176
|
});
|
|
178
177
|
if (logFileResult) {
|
|
179
178
|
return this.editorService.openEditor({ resource: ( (URI.parse(logFileResult.id))), options: { pinned: true } }).then(() => undefined);
|