@codingame/monaco-vscode-walkthrough-service-override 9.0.2 → 10.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 +2 -2
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/gettingStarted.contribution.js +50 -39
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/gettingStarted.js +84 -62
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/gettingStartedAccessibleView.js +101 -0
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/gettingStartedColors.js +7 -7
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/gettingStartedExtensionPoint.js +37 -37
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/gettingStartedIcons.js +2 -2
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/gettingStartedInput.js +2 -1
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/gettingStartedService._contribution.js +6 -7
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/gettingStartedService.js +5 -7
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/media/gettingStarted.css.js +1 -1
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/browser/startupPage.js +21 -17
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/common/gettingStartedContent.js +182 -150
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/common/media/notebookProfile.js +3 -3
- package/vscode/src/vs/workbench/contrib/welcomeGettingStarted/common/media/theme_picker.js +5 -5
- package/vscode/src/vs/workbench/contrib/welcomeWalkthrough/browser/editor/editorWalkThrough.js +3 -3
- package/vscode/src/vs/workbench/contrib/welcomeWalkthrough/browser/editor/vs_code_editor_walkthrough.js +1 -1
- package/vscode/src/vs/workbench/contrib/welcomeWalkthrough/browser/walkThrough.contribution.js +2 -2
- package/vscode/src/vs/workbench/contrib/welcomeWalkthrough/browser/walkThroughActions.js +8 -10
- package/vscode/src/vs/workbench/contrib/welcomeWalkthrough/browser/walkThroughInput.js +9 -8
- package/vscode/src/vs/workbench/contrib/welcomeWalkthrough/browser/walkThroughPart.js +10 -12
- package/vscode/src/vs/workbench/contrib/welcomeWalkthrough/common/walkThroughContentProvider.js +2 -3
- package/vscode/src/vs/workbench/contrib/welcomeWalkthrough/common/walkThroughUtils.js +1 -1
|
@@ -4,28 +4,25 @@ import { coalesce } from 'vscode/vscode/vs/base/common/arrays';
|
|
|
4
4
|
import { IInstantiationService } from 'vscode/vscode/vs/platform/instantiation/common/instantiation';
|
|
5
5
|
import { IEditorService } from 'vscode/vscode/vs/workbench/services/editor/common/editorService.service';
|
|
6
6
|
import { onUnexpectedError } from 'vscode/vscode/vs/base/common/errors';
|
|
7
|
-
import { UNKNOWN_EMPTY_WINDOW_WORKSPACE
|
|
7
|
+
import { UNKNOWN_EMPTY_WINDOW_WORKSPACE } from 'vscode/vscode/vs/platform/workspace/common/workspace';
|
|
8
8
|
import { IWorkspaceContextService } from 'vscode/vscode/vs/platform/workspace/common/workspace.service';
|
|
9
9
|
import { IConfigurationService } from 'vscode/vscode/vs/platform/configuration/common/configuration.service';
|
|
10
10
|
import { IWorkingCopyBackupService } from 'vscode/vscode/vs/workbench/services/workingCopy/common/workingCopyBackup.service';
|
|
11
|
-
import { LifecyclePhase, StartupKind } from 'vscode/vscode/vs/workbench/services/lifecycle/common/lifecycle';
|
|
12
11
|
import { ILifecycleService } from 'vscode/vscode/vs/workbench/services/lifecycle/common/lifecycle.service';
|
|
12
|
+
import { Disposable } from 'vscode/vscode/vs/base/common/lifecycle';
|
|
13
13
|
import { IFileService } from 'vscode/vscode/vs/platform/files/common/files.service';
|
|
14
14
|
import { joinPath } from 'vscode/vscode/vs/base/common/resources';
|
|
15
15
|
import { IWorkbenchLayoutService } from 'vscode/vscode/vs/workbench/services/layout/browser/layoutService.service';
|
|
16
16
|
import { GettingStartedInput, gettingStartedInputTypeId } from './gettingStartedInput.js';
|
|
17
17
|
import { IWorkbenchEnvironmentService } from 'vscode/vscode/vs/workbench/services/environment/common/environmentService.service';
|
|
18
|
-
import { StorageScope, StorageTarget } from 'vscode/vscode/vs/platform/storage/common/storage';
|
|
19
18
|
import { IStorageService } from 'vscode/vscode/vs/platform/storage/common/storage.service';
|
|
20
19
|
import { getTelemetryLevel } from 'vscode/vscode/vs/platform/telemetry/common/telemetryUtils';
|
|
21
|
-
import { TelemetryLevel } from 'vscode/vscode/vs/platform/telemetry/common/telemetry';
|
|
22
20
|
import { IProductService } from 'vscode/vscode/vs/platform/product/common/productService.service';
|
|
23
21
|
import { ILogService } from 'vscode/vscode/vs/platform/log/common/log.service';
|
|
24
22
|
import { INotificationService } from 'vscode/vscode/vs/platform/notification/common/notification.service';
|
|
25
23
|
import { localize } from 'vscode/vscode/vs/nls';
|
|
26
24
|
import { RegisteredEditorPriority } from 'vscode/vscode/vs/workbench/services/editor/common/editorResolverService';
|
|
27
25
|
import { IEditorResolverService } from 'vscode/vscode/vs/workbench/services/editor/common/editorResolverService.service';
|
|
28
|
-
import { TerminalCommandId } from 'vscode/vscode/vs/workbench/contrib/terminal/common/terminal';
|
|
29
26
|
|
|
30
27
|
const restoreWalkthroughsConfigurationKey = 'workbench.welcomePage.restorableWalkthroughs';
|
|
31
28
|
const configurationKey = 'workbench.startupEditor';
|
|
@@ -37,7 +34,7 @@ let StartupPageEditorResolverContribution = class StartupPageEditorResolverContr
|
|
|
37
34
|
this.instantiationService = instantiationService;
|
|
38
35
|
editorResolverService.registerEditor(`${GettingStartedInput.RESOURCE.scheme}:/**`, {
|
|
39
36
|
id: GettingStartedInput.ID,
|
|
40
|
-
label: ( localize(
|
|
37
|
+
label: ( localize(7577, "Welcome Page")),
|
|
41
38
|
priority: RegisteredEditorPriority.builtin,
|
|
42
39
|
}, {
|
|
43
40
|
singlePerResource: false,
|
|
@@ -59,9 +56,10 @@ StartupPageEditorResolverContribution = ( (__decorate([
|
|
|
59
56
|
( (__param(0, IInstantiationService))),
|
|
60
57
|
( (__param(1, IEditorResolverService)))
|
|
61
58
|
], StartupPageEditorResolverContribution)));
|
|
62
|
-
let StartupPageRunnerContribution = class StartupPageRunnerContribution {
|
|
59
|
+
let StartupPageRunnerContribution = class StartupPageRunnerContribution extends Disposable {
|
|
63
60
|
static { this.ID = 'workbench.contrib.startupPageRunner'; }
|
|
64
61
|
constructor(configurationService, editorService, workingCopyBackupService, fileService, contextService, lifecycleService, layoutService, productService, commandService, environmentService, storageService, logService, notificationService) {
|
|
62
|
+
super();
|
|
65
63
|
this.configurationService = configurationService;
|
|
66
64
|
this.editorService = editorService;
|
|
67
65
|
this.workingCopyBackupService = workingCopyBackupService;
|
|
@@ -76,15 +74,21 @@ let StartupPageRunnerContribution = class StartupPageRunnerContribution {
|
|
|
76
74
|
this.logService = logService;
|
|
77
75
|
this.notificationService = notificationService;
|
|
78
76
|
this.run().then(undefined, onUnexpectedError);
|
|
77
|
+
this._register(this.editorService.onDidCloseEditor((e) => {
|
|
78
|
+
if (e.editor instanceof GettingStartedInput) {
|
|
79
|
+
e.editor.selectedCategory = undefined;
|
|
80
|
+
e.editor.selectedStep = undefined;
|
|
81
|
+
}
|
|
82
|
+
}));
|
|
79
83
|
}
|
|
80
84
|
async run() {
|
|
81
|
-
await this.lifecycleService.when(
|
|
85
|
+
await this.lifecycleService.when(3 );
|
|
82
86
|
if (this.productService.enableTelemetry
|
|
83
87
|
&& this.productService.showTelemetryOptOut
|
|
84
|
-
&& getTelemetryLevel(this.configurationService) !==
|
|
88
|
+
&& getTelemetryLevel(this.configurationService) !== 0
|
|
85
89
|
&& !this.environmentService.skipWelcome
|
|
86
|
-
&& !this.storageService.get(telemetryOptOutStorageKey,
|
|
87
|
-
this.storageService.store(telemetryOptOutStorageKey, true,
|
|
90
|
+
&& !this.storageService.get(telemetryOptOutStorageKey, 0 )) {
|
|
91
|
+
this.storageService.store(telemetryOptOutStorageKey, true, 0 , 0 );
|
|
88
92
|
await this.openGettingStarted(true);
|
|
89
93
|
return;
|
|
90
94
|
}
|
|
@@ -92,7 +96,7 @@ let StartupPageRunnerContribution = class StartupPageRunnerContribution {
|
|
|
92
96
|
return;
|
|
93
97
|
}
|
|
94
98
|
const enabled = isStartupPageEnabled(this.configurationService, this.contextService, this.environmentService);
|
|
95
|
-
if (enabled && this.lifecycleService.startupKind !==
|
|
99
|
+
if (enabled && this.lifecycleService.startupKind !== 3 ) {
|
|
96
100
|
const hasBackups = await this.workingCopyBackupService.hasBackups();
|
|
97
101
|
if (hasBackups) {
|
|
98
102
|
return;
|
|
@@ -113,13 +117,13 @@ let StartupPageRunnerContribution = class StartupPageRunnerContribution {
|
|
|
113
117
|
await this.openGettingStarted();
|
|
114
118
|
}
|
|
115
119
|
else if (startupEditorSetting.value === 'terminal') {
|
|
116
|
-
this.commandService.executeCommand(
|
|
120
|
+
this.commandService.executeCommand("workbench.action.createTerminalEditor" );
|
|
117
121
|
}
|
|
118
122
|
}
|
|
119
123
|
}
|
|
120
124
|
}
|
|
121
125
|
tryOpenWalkthroughForFolder() {
|
|
122
|
-
const toRestore = this.storageService.get(restoreWalkthroughsConfigurationKey,
|
|
126
|
+
const toRestore = this.storageService.get(restoreWalkthroughsConfigurationKey, 0 );
|
|
123
127
|
if (!toRestore) {
|
|
124
128
|
return false;
|
|
125
129
|
}
|
|
@@ -132,7 +136,7 @@ let StartupPageRunnerContribution = class StartupPageRunnerContribution {
|
|
|
132
136
|
resource: GettingStartedInput.RESOURCE,
|
|
133
137
|
options
|
|
134
138
|
});
|
|
135
|
-
this.storageService.remove(restoreWalkthroughsConfigurationKey,
|
|
139
|
+
this.storageService.remove(restoreWalkthroughsConfigurationKey, 0 );
|
|
136
140
|
return true;
|
|
137
141
|
}
|
|
138
142
|
}
|
|
@@ -157,7 +161,7 @@ let StartupPageRunnerContribution = class StartupPageRunnerContribution {
|
|
|
157
161
|
await Promise.all([
|
|
158
162
|
this.commandService.executeCommand('markdown.showPreview', null, readmes.filter(isMarkDown), { locked: true }).catch(error => {
|
|
159
163
|
this.notificationService.error(( localize(
|
|
160
|
-
|
|
164
|
+
7578,
|
|
161
165
|
'Could not open markdown preview: {0}.\n\nPlease make sure the markdown extension is enabled.',
|
|
162
166
|
error.message
|
|
163
167
|
)));
|
|
@@ -213,7 +217,7 @@ function isStartupPageEnabled(configurationService, contextService, environmentS
|
|
|
213
217
|
}
|
|
214
218
|
return startupEditor.value === 'welcomePage'
|
|
215
219
|
|| startupEditor.value === 'readme' && (startupEditor.userValue === 'readme' || startupEditor.defaultValue === 'readme')
|
|
216
|
-
|| (contextService.getWorkbenchState() ===
|
|
220
|
+
|| (contextService.getWorkbenchState() === 1 && startupEditor.value === 'welcomePageInEmptyWorkbench')
|
|
217
221
|
|| startupEditor.value === 'terminal';
|
|
218
222
|
}
|
|
219
223
|
|