@codingame/monaco-vscode-welcome-service-override 37.2.0 → 37.3.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/common.d.ts +2 -0
- package/common.js +15 -0
- package/index.js +3 -7
- package/package.json +11 -3
- package/session.d.ts +2 -0
- package/session.js +10 -0
- package/vscode/src/vs/workbench/contrib/onboarding/browser/onboarding.contribution.js +8 -8
- package/vscode/src/vs/workbench/contrib/onboarding/browser/onboardingService.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/onboarding/browser/onboardingService.js +5 -5
- package/vscode/src/vs/workbench/contrib/onboarding/browser/sequence/sequencePresentation.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/onboarding/browser/sequence/sequencePresentation.js +2 -2
- package/vscode/src/vs/workbench/contrib/onboarding/browser/spotlight/spotlightOverlay.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/onboarding/browser/spotlight/spotlightOverlay.js +9 -9
- package/vscode/src/vs/workbench/contrib/onboarding/browser/spotlight/spotlightPresentation.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/onboarding/browser/spotlight/spotlightPresentation.js +7 -4
- package/vscode/src/vs/workbench/contrib/onboarding/common/onboardingPresentation.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/welcomeAgentSessions/browser/agentSessionsWelcome.contribution.js +3 -3
- package/vscode/src/vs/workbench/contrib/welcomeAgentSessions/browser/agentSessionsWelcome.js +21 -21
- package/vscode/src/vs/workbench/contrib/welcomeOnboarding/browser/onboardingVariationA.js +55 -55
- package/vscode/src/vs/workbench/contrib/welcomeOnboarding/browser/welcomeOnboarding.contribution.js +2 -2
- package/vscode/src/vs/workbench/contrib/welcomeViews/common/newFile.contribution.js +10 -10
- package/vscode/src/vs/workbench/contrib/welcomeViews/common/viewsWelcomeContribution.js +1 -1
- package/vscode/src/vs/workbench/contrib/welcomeViews/common/viewsWelcomeExtensionPoint.js +8 -8
- package/vscode/src/vs/workbench/contrib/onboarding/browser/media/onboardingTarget.css +0 -28
- package/vscode/src/vs/workbench/contrib/onboarding/browser/sequence/runOnboardingStep.d.ts +0 -17
- package/vscode/src/vs/workbench/contrib/onboarding/browser/sequence/runOnboardingStep.js +0 -32
- package/vscode/src/vs/workbench/contrib/onboarding/browser/spotlight/onboardingTarget.d.ts +0 -37
- package/vscode/src/vs/workbench/contrib/onboarding/browser/spotlight/onboardingTarget.js +0 -29
- package/vscode/src/vs/workbench/contrib/onboarding/browser/spotlight/spotlightTypes.d.ts +0 -67
- package/vscode/src/vs/workbench/contrib/onboarding/browser/spotlight/spotlightTypes.js +0 -5
- package/vscode/src/vs/workbench/contrib/onboarding/common/onboardingRegistry.d.ts +0 -21
- package/vscode/src/vs/workbench/contrib/onboarding/common/onboardingRegistry.js +0 -35
- package/vscode/src/vs/workbench/contrib/onboarding/common/onboardingScenario.d.ts +0 -172
- package/vscode/src/vs/workbench/contrib/onboarding/common/onboardingScenario.js +0 -20
- package/vscode/src/vs/workbench/contrib/onboarding/common/onboardingScenarioService.d.ts +0 -48
- package/vscode/src/vs/workbench/contrib/onboarding/common/onboardingScenarioService.js +0 -11
- package/vscode/src/vs/workbench/contrib/onboarding/common/onboardingSequence.d.ts +0 -45
- package/vscode/src/vs/workbench/contrib/onboarding/common/onboardingSequence.js +0 -29
package/common.d.ts
ADDED
package/common.js
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
|
|
2
|
+
import { SyncDescriptor } from '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/descriptors';
|
|
3
|
+
import { IOnboardingScenarioService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenarioService.service';
|
|
4
|
+
import { OnboardingScenarioService } from './vscode/src/vs/workbench/contrib/onboarding/browser/onboardingService.js';
|
|
5
|
+
import './vscode/src/vs/workbench/contrib/onboarding/browser/onboarding.contribution.js';
|
|
6
|
+
import './vscode/src/vs/workbench/contrib/welcomeViews/common/viewsWelcome.contribution.js';
|
|
7
|
+
import './vscode/src/vs/workbench/contrib/welcomeViews/common/newFile.contribution.js';
|
|
8
|
+
|
|
9
|
+
function getServiceOverride() {
|
|
10
|
+
return {
|
|
11
|
+
[IOnboardingScenarioService.toString()]: new SyncDescriptor(OnboardingScenarioService, [], true)
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export { getServiceOverride as default };
|
package/index.js
CHANGED
|
@@ -1,19 +1,15 @@
|
|
|
1
1
|
|
|
2
2
|
import { SyncDescriptor } from '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/descriptors';
|
|
3
|
-
import { IOnboardingScenarioService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenarioService.service';
|
|
4
|
-
import { OnboardingScenarioService } from './vscode/src/vs/workbench/contrib/onboarding/browser/onboardingService.js';
|
|
5
3
|
import { IOnboardingService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/welcomeOnboarding/common/onboardingService.service';
|
|
6
4
|
import { OnboardingVariationA } from './vscode/src/vs/workbench/contrib/welcomeOnboarding/browser/onboardingVariationA.js';
|
|
7
|
-
import './
|
|
8
|
-
import './vscode/src/vs/workbench/contrib/welcomeViews/common/viewsWelcome.contribution.js';
|
|
9
|
-
import './vscode/src/vs/workbench/contrib/welcomeViews/common/newFile.contribution.js';
|
|
5
|
+
import getServiceOverride$1 from './common.js';
|
|
10
6
|
import './vscode/src/vs/workbench/contrib/welcomeOnboarding/browser/welcomeOnboarding.contribution.js';
|
|
11
7
|
import './vscode/src/vs/workbench/contrib/welcomeAgentSessions/browser/agentSessionsWelcome.contribution.js';
|
|
12
8
|
|
|
13
9
|
function getServiceOverride() {
|
|
14
10
|
return {
|
|
15
|
-
|
|
16
|
-
[
|
|
11
|
+
...getServiceOverride$1(),
|
|
12
|
+
[IOnboardingService.toString()]: new SyncDescriptor(OnboardingVariationA, [], true)
|
|
17
13
|
};
|
|
18
14
|
}
|
|
19
15
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-welcome-service-override",
|
|
3
|
-
"version": "37.
|
|
3
|
+
"version": "37.3.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "VSCode public API plugged on the monaco editor - welcome service-override",
|
|
6
6
|
"keywords": [],
|
|
@@ -15,8 +15,8 @@
|
|
|
15
15
|
},
|
|
16
16
|
"type": "module",
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@codingame/monaco-vscode-api": "37.
|
|
19
|
-
"@codingame/monaco-vscode-katex-common": "37.
|
|
18
|
+
"@codingame/monaco-vscode-api": "37.3.1",
|
|
19
|
+
"@codingame/monaco-vscode-katex-common": "37.3.1"
|
|
20
20
|
},
|
|
21
21
|
"main": "index.js",
|
|
22
22
|
"module": "index.js",
|
|
@@ -32,6 +32,14 @@
|
|
|
32
32
|
"types": "./vscode/src/*.d.ts",
|
|
33
33
|
"default": "./vscode/src/*.js"
|
|
34
34
|
},
|
|
35
|
+
"./session": {
|
|
36
|
+
"types": "./session.d.ts",
|
|
37
|
+
"default": "./session.js"
|
|
38
|
+
},
|
|
39
|
+
"./common": {
|
|
40
|
+
"types": "./common.d.ts",
|
|
41
|
+
"default": "./common.js"
|
|
42
|
+
},
|
|
35
43
|
"./*": {
|
|
36
44
|
"types": "./*.d.ts",
|
|
37
45
|
"default": "./*.js"
|
package/session.d.ts
ADDED
package/session.js
ADDED
|
@@ -11,12 +11,12 @@ import { Registry } from '@codingame/monaco-vscode-api/vscode/vs/platform/regist
|
|
|
11
11
|
import { workbenchConfigurationNodeBase } from '@codingame/monaco-vscode-api/vscode/vs/workbench/common/configuration';
|
|
12
12
|
import { registerWorkbenchContribution2, WorkbenchPhase } from '@codingame/monaco-vscode-api/vscode/vs/workbench/common/contributions';
|
|
13
13
|
import { onboardingPresentationRegistry } from '../common/onboardingPresentation.js';
|
|
14
|
-
import { onboardingScenarioRegistry } from '
|
|
15
|
-
import { onboardingSequenceStepPresentationRegistry } from '
|
|
16
|
-
import { ONBOARDING_DEVELOPER_MODE_VARIATIONS_CONFIG, ONBOARDING_DEVELOPER_MODE_CONFIG, ONBOARDING_ENABLED_CONFIG } from '
|
|
14
|
+
import { onboardingScenarioRegistry } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingRegistry';
|
|
15
|
+
import { onboardingSequenceStepPresentationRegistry } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingSequence';
|
|
16
|
+
import { ONBOARDING_DEVELOPER_MODE_VARIATIONS_CONFIG, ONBOARDING_DEVELOPER_MODE_CONFIG, ONBOARDING_ENABLED_CONFIG } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenarioService';
|
|
17
17
|
import { IOnboardingScenarioService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenarioService.service';
|
|
18
18
|
import './onboardingService.js';
|
|
19
|
-
import { RunOnboardingStepPresentation } from '
|
|
19
|
+
import { RunOnboardingStepPresentation } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/browser/sequence/runOnboardingStep';
|
|
20
20
|
import { OnboardingSequencePresentation } from './sequence/sequencePresentation.js';
|
|
21
21
|
import { SpotlightPresentation } from './spotlight/spotlightPresentation.js';
|
|
22
22
|
|
|
@@ -53,7 +53,7 @@ function buildDeveloperModeConfigurationNode() {
|
|
|
53
53
|
},
|
|
54
54
|
tags: ["experimental"],
|
|
55
55
|
description: ( localize(
|
|
56
|
-
|
|
56
|
+
17007,
|
|
57
57
|
"Map of onboarding scenario/tour id to whether developer mode is enabled for it. When enabled for a scenario, that onboarding tour ignores usage-based eligibility checks (such as how many sessions you have started), previously persisted shown state, and any linked experiment (so it is shown even if the experiment is not running or you are in the control group). It does not override the {0} setting. The tour is still shown at most once per window session, so reload the window to show it again.",
|
|
58
58
|
`\`#${ONBOARDING_ENABLED_CONFIG}#\``
|
|
59
59
|
))
|
|
@@ -67,7 +67,7 @@ function buildDeveloperModeConfigurationNode() {
|
|
|
67
67
|
},
|
|
68
68
|
tags: ["experimental"],
|
|
69
69
|
description: ( localize(
|
|
70
|
-
|
|
70
|
+
17008,
|
|
71
71
|
"Map of onboarding scenario/tour id to the variation used while developer mode is enabled for that scenario. An empty value uses the experiment-selected or default variation."
|
|
72
72
|
))
|
|
73
73
|
}
|
|
@@ -82,7 +82,7 @@ configurationRegistry.registerConfiguration({
|
|
|
82
82
|
type: "boolean",
|
|
83
83
|
default: true,
|
|
84
84
|
description: ( localize(
|
|
85
|
-
|
|
85
|
+
17009,
|
|
86
86
|
"When enabled, onboarding tours and hints may appear automatically to highlight features. Disabling this does not affect tours you start manually."
|
|
87
87
|
))
|
|
88
88
|
}
|
|
@@ -126,7 +126,7 @@ registerAction2(class extends Action2 {
|
|
|
126
126
|
constructor() {
|
|
127
127
|
super({
|
|
128
128
|
id: "workbench.action.onboarding.resetShownState",
|
|
129
|
-
title: ( localize2(
|
|
129
|
+
title: ( localize2(17010, "Reset Onboarding Shown State")),
|
|
130
130
|
category: Categories.Developer,
|
|
131
131
|
f1: true
|
|
132
132
|
});
|
|
@@ -5,7 +5,7 @@ import { ITelemetryService } from "@codingame/monaco-vscode-api/vscode/vs/platfo
|
|
|
5
5
|
import { ILifecycleService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/lifecycle/common/lifecycle.service";
|
|
6
6
|
import { IStorageService } from "@codingame/monaco-vscode-api/vscode/vs/platform/storage/common/storage.service";
|
|
7
7
|
import { IWorkbenchAssignmentService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/assignment/common/assignmentService.service";
|
|
8
|
-
import { IOnboardingScenario, OnboardingOutcome } from "
|
|
8
|
+
import { IOnboardingScenario, OnboardingOutcome } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenario";
|
|
9
9
|
import { IOnboardingScenarioService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenarioService.service";
|
|
10
10
|
export declare class OnboardingScenarioService extends Disposable implements IOnboardingScenarioService {
|
|
11
11
|
private readonly storageService;
|
|
@@ -15,9 +15,9 @@ import { IStorageService } from '@codingame/monaco-vscode-api/vscode/vs/platform
|
|
|
15
15
|
import { IWorkbenchAssignmentService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/assignment/common/assignmentService.service';
|
|
16
16
|
import { Memento } from '@codingame/monaco-vscode-api/vscode/vs/workbench/common/memento';
|
|
17
17
|
import { onboardingPresentationRegistry } from '../common/onboardingPresentation.js';
|
|
18
|
-
import { onboardingScenarioRegistry } from '
|
|
19
|
-
import { ONBOARDING_ASSIGNMENT_CONTEXT_PREFIX, OnboardingOutcome } from '
|
|
20
|
-
import { ONBOARDING_ENABLED_CONFIG, ONBOARDING_DEVELOPER_MODE_CONFIG, isOnboardingDeveloperModeEnabled } from '
|
|
18
|
+
import { onboardingScenarioRegistry } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingRegistry';
|
|
19
|
+
import { ONBOARDING_ASSIGNMENT_CONTEXT_PREFIX, OnboardingOutcome } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenario';
|
|
20
|
+
import { ONBOARDING_ENABLED_CONFIG, ONBOARDING_DEVELOPER_MODE_CONFIG, isOnboardingDeveloperModeEnabled } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenarioService';
|
|
21
21
|
import { autorun } from '@codingame/monaco-vscode-api/vscode/vs/base/common/observableInternal/reactions/autorun';
|
|
22
22
|
|
|
23
23
|
var OnboardingScenarioService_1;
|
|
@@ -139,10 +139,10 @@ let OnboardingScenarioService = class OnboardingScenarioService extends Disposab
|
|
|
139
139
|
claimedSeenKeys.add(this._seenKey(scenario));
|
|
140
140
|
}
|
|
141
141
|
}
|
|
142
|
-
const eligibleScenarios =
|
|
142
|
+
const eligibleScenarios = onboardingScenarioRegistry.getScenarios().map((scenario, registrationIndex) => ({
|
|
143
143
|
scenario,
|
|
144
144
|
registrationIndex
|
|
145
|
-
}))
|
|
145
|
+
})).filter((
|
|
146
146
|
{
|
|
147
147
|
scenario
|
|
148
148
|
}
|
package/vscode/src/vs/workbench/contrib/onboarding/browser/sequence/sequencePresentation.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Disposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
|
|
2
2
|
import { IOnboardingPresentation, IOnboardingRunContext } from "../../common/onboardingPresentation.js";
|
|
3
|
-
import { IOnboardingRunResult, IOnboardingScenario } from "
|
|
3
|
+
import { IOnboardingRunResult, IOnboardingScenario } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenario";
|
|
4
4
|
/** Runs a heterogeneous sequence while leaving each step's rendering to its registered kind. */
|
|
5
5
|
export declare class OnboardingSequencePresentation extends Disposable implements IOnboardingPresentation {
|
|
6
6
|
readonly kind = "sequence";
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
import { CancellationTokenSource } from '@codingame/monaco-vscode-api/vscode/vs/base/common/cancellation';
|
|
3
3
|
import { onUnexpectedError } from '@codingame/monaco-vscode-api/vscode/vs/base/common/errors';
|
|
4
4
|
import { Disposable, DisposableStore } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
|
|
5
|
-
import { OnboardingDismissReason, OnboardingOutcome } from '
|
|
6
|
-
import { ONBOARDING_SEQUENCE_PRESENTATION_KIND, onboardingSequenceStepPresentationRegistry } from '
|
|
5
|
+
import { OnboardingDismissReason, OnboardingOutcome } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenario';
|
|
6
|
+
import { ONBOARDING_SEQUENCE_PRESENTATION_KIND, onboardingSequenceStepPresentationRegistry } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingSequence';
|
|
7
7
|
|
|
8
8
|
class OnboardingSequencePresentation extends Disposable {
|
|
9
9
|
constructor() {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Disposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
|
|
2
2
|
import { Event } from "@codingame/monaco-vscode-api/vscode/vs/base/common/event";
|
|
3
3
|
import { IMarkdownString } from "@codingame/monaco-vscode-api/vscode/vs/base/common/htmlContent";
|
|
4
|
-
import { SpotlightPlacement, SpotlightTargetClickBehavior } from "
|
|
5
|
-
import { OnboardingDismissReason } from "
|
|
4
|
+
import { SpotlightPlacement, SpotlightTargetClickBehavior } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/browser/spotlight/spotlightTypes";
|
|
5
|
+
import { OnboardingDismissReason } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenario";
|
|
6
6
|
/** How the user advanced to the next step. */
|
|
7
7
|
export type SpotlightAdvanceSource = "button" | "target";
|
|
8
8
|
/** Why a step ended in a skip: the Skip button or the Escape key. */
|
|
@@ -11,10 +11,10 @@ import { layout2d, AnchorAxisAlignment, AnchorAlignment, AnchorPosition } from '
|
|
|
11
11
|
import { renderMarkdown } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/markdownRenderer';
|
|
12
12
|
import { defaultButtonStyles } from '@codingame/monaco-vscode-api/vscode/vs/platform/theme/browser/defaultStyles';
|
|
13
13
|
import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
|
|
14
|
-
import { OnboardingDismissReason } from '
|
|
14
|
+
import { OnboardingDismissReason } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenario';
|
|
15
15
|
import * as spotlight from '../media/spotlight.css';
|
|
16
16
|
|
|
17
|
-
registerCss(spotlight);
|
|
17
|
+
registerCss(spotlight, 1);
|
|
18
18
|
const DEFAULT_HOLE_PADDING = 6;
|
|
19
19
|
const POINTER_SIZE = 10;
|
|
20
20
|
const POINTER_GAP = POINTER_SIZE;
|
|
@@ -64,8 +64,8 @@ class SpotlightOverlay extends Disposable {
|
|
|
64
64
|
...defaultButtonStyles,
|
|
65
65
|
secondary: true
|
|
66
66
|
})));
|
|
67
|
-
this._skipButton.label = ( localize(
|
|
68
|
-
this._skipButton.setTitle(( localize(
|
|
67
|
+
this._skipButton.label = ( localize(17011, "End Tour"));
|
|
68
|
+
this._skipButton.setTitle(( localize(17012, "End Tour (Esc)")));
|
|
69
69
|
this._register(
|
|
70
70
|
this._skipButton.onDidClick(() => this._onDidSkip.fire(OnboardingDismissReason.SkipButton))
|
|
71
71
|
);
|
|
@@ -73,12 +73,12 @@ class SpotlightOverlay extends Disposable {
|
|
|
73
73
|
...defaultButtonStyles,
|
|
74
74
|
secondary: true
|
|
75
75
|
})));
|
|
76
|
-
this._backButton.label = ( localize(
|
|
76
|
+
this._backButton.label = ( localize(17013, "Back"));
|
|
77
77
|
this._register(this._backButton.onDidClick(() => this._onDidClickPrevious.fire()));
|
|
78
78
|
this._nextButton = this._register(( new Button(actions, {
|
|
79
79
|
...defaultButtonStyles
|
|
80
80
|
})));
|
|
81
|
-
this._nextButton.label = ( localize(
|
|
81
|
+
this._nextButton.label = ( localize(17014, "Next"));
|
|
82
82
|
this._register(this._nextButton.onDidClick(() => this._onDidClickNext.fire("button")));
|
|
83
83
|
for (const button of [this._skipButton, this._backButton, this._nextButton]) {
|
|
84
84
|
this._register(
|
|
@@ -345,10 +345,10 @@ class SpotlightOverlay extends Disposable {
|
|
|
345
345
|
} else {
|
|
346
346
|
this._description.textContent = content.description;
|
|
347
347
|
}
|
|
348
|
-
this._counter.textContent = content.stepCount > 1 ? ( localize(
|
|
348
|
+
this._counter.textContent = content.stepCount > 1 ? ( localize(17015, "{0} of {1}", content.stepIndex + 1, content.stepCount)) : "";
|
|
349
349
|
this._skipButton.element.style.display = content.isLastStep ? "none" : "";
|
|
350
350
|
this._backButton.element.style.display = content.canGoBack ? "" : "none";
|
|
351
|
-
this._nextButton.label = content.nextButtonLabel ?? (content.isLastStep ? ( localize(
|
|
351
|
+
this._nextButton.label = content.nextButtonLabel ?? (content.isLastStep ? ( localize(17016, "Done")) : ( localize(17014, "Next")));
|
|
352
352
|
}
|
|
353
353
|
_onKeyDown(e) {
|
|
354
354
|
const event = ( new StandardKeyboardEvent(e));
|
|
@@ -390,7 +390,7 @@ class SpotlightOverlay extends Disposable {
|
|
|
390
390
|
"a[href], button, input, select, textarea, [tabindex]:not([tabindex=\"-1\"])"
|
|
391
391
|
)
|
|
392
392
|
);
|
|
393
|
-
const buttons =
|
|
393
|
+
const buttons = [this._skipButton, this._backButton, this._nextButton].filter(button => button.element.style.display !== "none").map(button => button.element);
|
|
394
394
|
return [...targetFocusables, ...descriptionFocusables, ...buttons].filter(element => this._isTabbable(element));
|
|
395
395
|
}
|
|
396
396
|
_isTabbable(element) {
|
package/vscode/src/vs/workbench/contrib/onboarding/browser/spotlight/spotlightPresentation.d.ts
CHANGED
|
@@ -3,8 +3,8 @@ import { IContextKeyService } from "@codingame/monaco-vscode-api/vscode/vs/platf
|
|
|
3
3
|
import { IWorkbenchLayoutService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/layout/browser/layoutService.service";
|
|
4
4
|
import { IHostService } from "@codingame/monaco-vscode-api/vscode/vs/workbench/services/host/browser/host.service";
|
|
5
5
|
import { IOnboardingPresentation, IOnboardingRunContext } from "../../common/onboardingPresentation.js";
|
|
6
|
-
import { IOnboardingRunResult, IOnboardingScenario } from "
|
|
7
|
-
import { IOnboardingSequenceStep, IOnboardingSequenceStepContext, IOnboardingSequenceStepPresentation, IOnboardingSequenceStepResult } from "
|
|
6
|
+
import { IOnboardingRunResult, IOnboardingScenario } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenario";
|
|
7
|
+
import { IOnboardingSequenceStep, IOnboardingSequenceStepContext, IOnboardingSequenceStepPresentation, IOnboardingSequenceStepResult } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingSequence";
|
|
8
8
|
/**
|
|
9
9
|
* Renders {@link ISpotlightPayload} scenarios: it dims the window (including the
|
|
10
10
|
* native window controls), walks the steps, and shows an anchored callout for
|
package/vscode/src/vs/workbench/contrib/onboarding/browser/spotlight/spotlightPresentation.js
CHANGED
|
@@ -7,10 +7,10 @@ import { Disposable, DisposableStore, toDisposable } from '@codingame/monaco-vsc
|
|
|
7
7
|
import { IContextKeyService } from '@codingame/monaco-vscode-api/vscode/vs/platform/contextkey/common/contextkey.service';
|
|
8
8
|
import { IWorkbenchLayoutService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/layout/browser/layoutService.service';
|
|
9
9
|
import { IHostService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/host/browser/host.service';
|
|
10
|
-
import { OnboardingDismissReason, OnboardingOutcome } from '
|
|
11
|
-
import { findOnboardingTarget, openOnboardingTarget } from '
|
|
10
|
+
import { OnboardingDismissReason, OnboardingOutcome } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenario';
|
|
11
|
+
import { findOnboardingTarget, openOnboardingTarget } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/browser/spotlight/onboardingTarget';
|
|
12
12
|
import { SpotlightOverlay } from './spotlightOverlay.js';
|
|
13
|
-
import { SPOTLIGHT_PRESENTATION_KIND } from '
|
|
13
|
+
import { SPOTLIGHT_PRESENTATION_KIND } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/browser/spotlight/spotlightTypes';
|
|
14
14
|
|
|
15
15
|
const TARGET_RESOLVE_TIMEOUT = 2000;
|
|
16
16
|
const TARGET_POLL_INTERVAL = 50;
|
|
@@ -277,7 +277,10 @@ let SpotlightPresentation = class SpotlightPresentation extends Disposable {
|
|
|
277
277
|
async _waitForTargetReady(targetWindow, target) {
|
|
278
278
|
const animations = this._getActiveFiniteAnimations(target);
|
|
279
279
|
if (animations.length > 0) {
|
|
280
|
-
await Promise.race([
|
|
280
|
+
await Promise.race([
|
|
281
|
+
Promise.allSettled(animations.map(animation => animation.finished.catch(() => undefined))),
|
|
282
|
+
timeout(TARGET_ANIMATION_SETTLE_TIMEOUT)
|
|
283
|
+
]);
|
|
281
284
|
}
|
|
282
285
|
await ( new Promise(resolve => targetWindow.requestAnimationFrame(() => resolve())));
|
|
283
286
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Event } from "@codingame/monaco-vscode-api/vscode/vs/base/common/event";
|
|
2
2
|
import { IDisposable } from "@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle";
|
|
3
|
-
import { IOnboardingRunResult, IOnboardingScenario } from "
|
|
3
|
+
import { IOnboardingRunResult, IOnboardingScenario } from "@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/onboarding/common/onboardingScenario";
|
|
4
4
|
/**
|
|
5
5
|
* Context handed to a presentation for a single scenario run. Exposes only what
|
|
6
6
|
* a presentation needs without leaking engine internals.
|
|
@@ -28,7 +28,7 @@ import { IChatEntitlementService } from '@codingame/monaco-vscode-api/vscode/vs/
|
|
|
28
28
|
const agentSessionsWelcomeInputTypeId = "workbench.editors.agentSessionsWelcomeInput";
|
|
29
29
|
( Registry.as(EditorExtensions.EditorFactory)).registerEditorSerializer(agentSessionsWelcomeInputTypeId, AgentSessionsWelcomeInputSerializer);
|
|
30
30
|
( Registry.as(EditorExtensions.EditorPane)).registerEditorPane(
|
|
31
|
-
EditorPaneDescriptor.create(AgentSessionsWelcomePage, AgentSessionsWelcomePage.ID, ( localize(
|
|
31
|
+
EditorPaneDescriptor.create(AgentSessionsWelcomePage, AgentSessionsWelcomePage.ID, ( localize(20895, "Agent Sessions Welcome"))),
|
|
32
32
|
[( new SyncDescriptor(AgentSessionsWelcomeInput))]
|
|
33
33
|
);
|
|
34
34
|
const getWorkspaceKind = workspaceContextService => {
|
|
@@ -54,7 +54,7 @@ let AgentSessionsWelcomeEditorResolverContribution = class AgentSessionsWelcomeE
|
|
|
54
54
|
`${AgentSessionsWelcomeInput.RESOURCE.scheme}:${AgentSessionsWelcomeInput.RESOURCE.authority}/**`,
|
|
55
55
|
{
|
|
56
56
|
id: AgentSessionsWelcomePage.ID,
|
|
57
|
-
label: ( localize(
|
|
57
|
+
label: ( localize(20896, "Agent Sessions Welcome")),
|
|
58
58
|
priority: RegisteredEditorPriority.builtin
|
|
59
59
|
},
|
|
60
60
|
{
|
|
@@ -78,7 +78,7 @@ registerAction2(class OpenAgentSessionsWelcomeAction extends Action2 {
|
|
|
78
78
|
constructor() {
|
|
79
79
|
super({
|
|
80
80
|
id: AgentSessionsWelcomePage.COMMAND_ID,
|
|
81
|
-
title: ( localize(
|
|
81
|
+
title: ( localize(20897, "Open Agent Sessions Welcome")),
|
|
82
82
|
precondition: ChatContextKeys.enabled
|
|
83
83
|
});
|
|
84
84
|
}
|
package/vscode/src/vs/workbench/contrib/welcomeAgentSessions/browser/agentSessionsWelcome.js
CHANGED
|
@@ -50,10 +50,10 @@ import { agentSessionsWelcomeCommandId, AgentSessionsWelcomeInput } from '@codin
|
|
|
50
50
|
import { IChatService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatService/chatService.service';
|
|
51
51
|
import { ChatViewId } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chat';
|
|
52
52
|
import { IChatWidgetService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chat.service';
|
|
53
|
-
import { getResourceForNewChatSession, ChatSessionPosition } from '@codingame/monaco-vscode-
|
|
53
|
+
import { getResourceForNewChatSession, ChatSessionPosition } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/chatSessions/chatSessions.contribution';
|
|
54
54
|
import { IChatEntitlementService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/chat/common/chatEntitlementService.service';
|
|
55
55
|
import { AgentSessionsControl } from '@codingame/monaco-vscode-katex-common/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsControl';
|
|
56
|
-
import { AgentSessionsFilter } from '@codingame/monaco-vscode-
|
|
56
|
+
import { AgentSessionsFilter } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsFilter';
|
|
57
57
|
import { AgentSessionsListDelegate } from '@codingame/monaco-vscode-katex-common/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsViewer';
|
|
58
58
|
import { HoverPosition } from '@codingame/monaco-vscode-api/vscode/vs/base/browser/ui/hover/hoverWidget';
|
|
59
59
|
import { IWalkthroughsService } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/welcomeGettingStarted/browser/gettingStartedService.service';
|
|
@@ -73,7 +73,7 @@ import { ILogService } from '@codingame/monaco-vscode-api/vscode/vs/platform/log
|
|
|
73
73
|
import { canShowAgentsBanner, createAgentsBanner } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/browser/agentSessions/agentSessionsBanner';
|
|
74
74
|
|
|
75
75
|
var AgentSessionsWelcomePage_1;
|
|
76
|
-
registerCss(agentSessionsWelcome);
|
|
76
|
+
registerCss(agentSessionsWelcome, 1);
|
|
77
77
|
const configurationKey = "workbench.startupEditor";
|
|
78
78
|
const MAX_SESSIONS = 6;
|
|
79
79
|
const MAX_REPO_PICKS = 10;
|
|
@@ -155,7 +155,7 @@ let AgentSessionsWelcomePage = class AgentSessionsWelcomePage extends EditorPane
|
|
|
155
155
|
this.container = $(".agentSessionsWelcome", {
|
|
156
156
|
role: "document",
|
|
157
157
|
tabindex: 0,
|
|
158
|
-
"aria-label": ( localize(
|
|
158
|
+
"aria-label": ( localize(20898, "Overview of agent sessions and how to get started."))
|
|
159
159
|
});
|
|
160
160
|
this.contextService = this._register(contextKeyService.createScoped(this.container));
|
|
161
161
|
ChatContextKeys.inAgentSessionsWelcome.bindTo(this.contextService).set(true);
|
|
@@ -232,20 +232,20 @@ let AgentSessionsWelcomePage = class AgentSessionsWelcomePage extends EditorPane
|
|
|
232
232
|
const workspaces = await this.getRecentlyOpenedWorkspaces(false);
|
|
233
233
|
const openEntry = workspaces.length > 0 ? {
|
|
234
234
|
icon: Codicon.folderOpened,
|
|
235
|
-
label: ( localize(
|
|
235
|
+
label: ( localize(20899, "Open Recent...")),
|
|
236
236
|
command: "workbench.action.openRecent"
|
|
237
237
|
} : {
|
|
238
238
|
icon: Codicon.folderOpened,
|
|
239
|
-
label: ( localize(
|
|
239
|
+
label: ( localize(20900, "Open Folder...")),
|
|
240
240
|
command: "workbench.action.files.openFolder"
|
|
241
241
|
};
|
|
242
242
|
const entries = [openEntry, {
|
|
243
243
|
icon: Codicon.newFile,
|
|
244
|
-
label: ( localize(
|
|
244
|
+
label: ( localize(20901, "New file...")),
|
|
245
245
|
command: "welcome.showNewFileEntries"
|
|
246
246
|
}, {
|
|
247
247
|
icon: Codicon.repoClone,
|
|
248
|
-
label: ( localize(
|
|
248
|
+
label: ( localize(20902, "Clone Git Repository...")),
|
|
249
249
|
command: "git.clone"
|
|
250
250
|
}];
|
|
251
251
|
for (const entry of entries) {
|
|
@@ -298,11 +298,11 @@ let AgentSessionsWelcomePage = class AgentSessionsWelcomePage extends EditorPane
|
|
|
298
298
|
const onDidChangeSelectedWorkspace = this.contentDisposables.add(( new Emitter()));
|
|
299
299
|
const onDidChangeWorkspaces = this.contentDisposables.add(( new Emitter()));
|
|
300
300
|
const workspacePickerDelegate = this._isEmptyWorkspace ? {
|
|
301
|
-
getWorkspaces: () =>
|
|
301
|
+
getWorkspaces: () => this._recentTrustedWorkspaces.map(w => ({
|
|
302
302
|
uri: this.getWorkspaceUri(w),
|
|
303
303
|
label: this.getWorkspaceLabel(w),
|
|
304
304
|
isFolder: isRecentFolder(w)
|
|
305
|
-
}))
|
|
305
|
+
})),
|
|
306
306
|
getSelectedWorkspace: () => this._selectedWorkspace,
|
|
307
307
|
setSelectedWorkspace: workspace => {
|
|
308
308
|
this._selectedWorkspace = workspace;
|
|
@@ -504,7 +504,7 @@ let AgentSessionsWelcomePage = class AgentSessionsWelcomePage extends EditorPane
|
|
|
504
504
|
const agentsBanner = createAgentsBanner({
|
|
505
505
|
cssClass: "agentSessionsWelcome-agentsBanner",
|
|
506
506
|
source: "agentSessionsWelcome",
|
|
507
|
-
label: ( localize(
|
|
507
|
+
label: ( localize(20903, "View All Sessions")),
|
|
508
508
|
onButtonClick: () => {
|
|
509
509
|
this._closedBy = "viewAllSessions";
|
|
510
510
|
}
|
|
@@ -527,10 +527,10 @@ let AgentSessionsWelcomePage = class AgentSessionsWelcomePage extends EditorPane
|
|
|
527
527
|
const navContainer = append(card, $(".agentSessionsWelcome-walkthroughCard-nav"));
|
|
528
528
|
const prevButton = append(navContainer, $("button.nav-button"));
|
|
529
529
|
prevButton.appendChild(renderIcon(Codicon.chevronLeft));
|
|
530
|
-
prevButton.title = ( localize(
|
|
530
|
+
prevButton.title = ( localize(20904, "Previous"));
|
|
531
531
|
const nextButton = append(navContainer, $("button.nav-button"));
|
|
532
532
|
nextButton.appendChild(renderIcon(Codicon.chevronRight));
|
|
533
|
-
nextButton.title = ( localize(
|
|
533
|
+
nextButton.title = ( localize(20905, "Next"));
|
|
534
534
|
const updateContent = () => {
|
|
535
535
|
const walkthrough = activeWalkthroughs[currentIndex];
|
|
536
536
|
clearNode(iconContainer);
|
|
@@ -610,10 +610,10 @@ let AgentSessionsWelcomePage = class AgentSessionsWelcomePage extends EditorPane
|
|
|
610
610
|
iconContainer.appendChild(renderIcon(Codicon.chatSparkle));
|
|
611
611
|
const content = append(tosCard, $(".agentSessionsWelcome-walkthroughCard-content"));
|
|
612
612
|
const title = append(content, $(".agentSessionsWelcome-walkthroughCard-title"));
|
|
613
|
-
title.textContent = ( localize(
|
|
613
|
+
title.textContent = ( localize(20906, "Try GitHub Copilot for free, no sign-in required!"));
|
|
614
614
|
const desc = append(content, $(".agentSessionsWelcome-walkthroughCard-description"));
|
|
615
615
|
const descriptionMarkdown = ( new MarkdownString(( localize(
|
|
616
|
-
|
|
616
|
+
20907,
|
|
617
617
|
"By continuing, you agree to {0}'s [Terms]({1}) and [Privacy Statement]({2}).",
|
|
618
618
|
providers.default.name,
|
|
619
619
|
this.productService.defaultChatAgent.termsStatementUrl,
|
|
@@ -625,7 +625,7 @@ let AgentSessionsWelcomePage = class AgentSessionsWelcomePage extends EditorPane
|
|
|
625
625
|
desc.appendChild(renderedMarkdown.element);
|
|
626
626
|
const dismissButton = append(tosCard, $("button.agentSessionsWelcome-tosCard-dismiss"));
|
|
627
627
|
dismissButton.appendChild(renderIcon(Codicon.close));
|
|
628
|
-
dismissButton.title = ( localize(
|
|
628
|
+
dismissButton.title = ( localize(20908, "Dismiss"));
|
|
629
629
|
dismissButton.onclick = e => {
|
|
630
630
|
e.stopPropagation();
|
|
631
631
|
dismissNotice();
|
|
@@ -638,7 +638,7 @@ let AgentSessionsWelcomePage = class AgentSessionsWelcomePage extends EditorPane
|
|
|
638
638
|
icon: Codicon.check,
|
|
639
639
|
actionClassName: "agentSessionsWelcome-checkbox",
|
|
640
640
|
isChecked: this.configurationService.getValue(configurationKey) === "agentSessionsWelcomePage",
|
|
641
|
-
title: ( localize(
|
|
641
|
+
title: ( localize(20909, "When checked, this page will be shown on startup.")),
|
|
642
642
|
...getToggleStyles({
|
|
643
643
|
inputActiveOptionBackground: "var(--vscode-descriptionForeground)",
|
|
644
644
|
inputActiveOptionForeground: "var(--vscode-editor-background)",
|
|
@@ -648,7 +648,7 @@ let AgentSessionsWelcomePage = class AgentSessionsWelcomePage extends EditorPane
|
|
|
648
648
|
showOnStartupCheckbox.domNode.id = "showOnStartup";
|
|
649
649
|
const showOnStartupLabel = $("label.caption", {
|
|
650
650
|
for: "showOnStartup"
|
|
651
|
-
}, ( localize(
|
|
651
|
+
}, ( localize(20910, "Show welcome page on startup")));
|
|
652
652
|
const onShowOnStartupChanged = () => {
|
|
653
653
|
if (showOnStartupCheckbox.checked) {
|
|
654
654
|
this.configurationService.updateValue(configurationKey, "agentSessionsWelcomePage");
|
|
@@ -736,16 +736,16 @@ let AgentSessionsWelcomePage = class AgentSessionsWelcomePage extends EditorPane
|
|
|
736
736
|
}
|
|
737
737
|
async getRecentlyOpenedWorkspaces(onlyTrusted = false) {
|
|
738
738
|
const workspaces = await this.workspacesService.getRecentlyOpened();
|
|
739
|
-
const trustInfoPromises =
|
|
739
|
+
const trustInfoPromises = workspaces.workspaces.map(async ws => {
|
|
740
740
|
const uri = isRecentWorkspace(ws) ? ws.workspace.configPath : ws.folderUri;
|
|
741
741
|
const trustInfo = await this.workspaceTrustManagementService.getUriTrustInfo(uri);
|
|
742
742
|
return {
|
|
743
743
|
workspace: ws,
|
|
744
744
|
trusted: trustInfo.trusted
|
|
745
745
|
};
|
|
746
|
-
})
|
|
746
|
+
});
|
|
747
747
|
const trustInfoResults = await Promise.all(trustInfoPromises);
|
|
748
|
-
const filteredWorkspaces =
|
|
748
|
+
const filteredWorkspaces = trustInfoResults.filter(result => onlyTrusted ? result.trusted : true).map(result => result.workspace);
|
|
749
749
|
return filteredWorkspaces;
|
|
750
750
|
}
|
|
751
751
|
};
|