@codingame/monaco-vscode-quickaccess-service-override 11.1.1 → 12.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/index.d.ts +8 -1
- package/index.js +117 -1
- package/package.json +22 -7
- package/vscode/src/vs/editor/contrib/quickAccess/browser/commandsQuickAccess.d.ts +12 -0
- package/vscode/src/vs/editor/contrib/quickAccess/browser/commandsQuickAccess.js +1 -0
- package/vscode/src/vs/platform/quickinput/browser/commandsQuickAccess.d.ts +67 -0
- package/vscode/src/vs/platform/quickinput/browser/commandsQuickAccess.js +37 -36
- package/vscode/src/vs/platform/quickinput/browser/helpQuickAccess.d.ts +21 -0
- package/vscode/src/vs/platform/quickinput/browser/helpQuickAccess.js +19 -20
- package/vscode/src/vs/workbench/browser/actions/quickAccessActions.d.ts +1 -0
- package/vscode/src/vs/workbench/browser/actions/quickAccessActions.js +33 -31
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/quickaccess/gotoLineQuickAccess.d.ts +22 -0
- package/vscode/src/vs/workbench/contrib/codeEditor/browser/quickaccess/gotoLineQuickAccess.js +17 -14
- package/vscode/src/vs/workbench/contrib/quickaccess/browser/commandsQuickAccess.d.ts +55 -0
- package/vscode/src/vs/workbench/contrib/quickaccess/browser/commandsQuickAccess.js +53 -52
- package/vscode/src/vs/workbench/contrib/quickaccess/browser/quickAccess.contribution.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/quickaccess/browser/quickAccess.contribution.js +24 -25
- package/vscode/src/vs/workbench/contrib/quickaccess/browser/viewQuickAccess.d.ts +50 -0
- package/vscode/src/vs/workbench/contrib/quickaccess/browser/viewQuickAccess.js +35 -31
- package/vscode/src/vs/workbench/contrib/url/browser/externalUriResolver.d.ts +8 -0
- package/vscode/src/vs/workbench/contrib/url/browser/externalUriResolver.js +2 -1
- package/vscode/src/vs/workbench/contrib/url/browser/trustedDomainsFileSystemProvider.d.ts +29 -0
- package/vscode/src/vs/workbench/contrib/url/browser/trustedDomainsFileSystemProvider.js +9 -7
- package/vscode/src/vs/workbench/contrib/url/browser/trustedDomainsValidator.d.ts +31 -0
- package/vscode/src/vs/workbench/contrib/url/browser/trustedDomainsValidator.js +26 -25
- package/vscode/src/vs/workbench/contrib/url/browser/url.contribution.d.ts +1 -0
- package/vscode/src/vs/workbench/contrib/url/browser/url.contribution.js +18 -13
- package/vscode/src/vs/workbench/services/quickinput/browser/quickInputService.d.ts +15 -0
- package/vscode/src/vs/workbench/services/quickinput/browser/quickInputService.js +4 -2
- package/quickaccess.js +0 -115
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
|
|
1
2
|
import { localize } from 'vscode/vscode/vs/nls';
|
|
2
3
|
import { Extensions } from 'vscode/vscode/vs/platform/quickinput/common/quickAccess';
|
|
3
4
|
import { Registry } from 'vscode/vscode/vs/platform/registry/common/platform';
|
|
@@ -5,45 +6,46 @@ import { HelpQuickAccessProvider } from '../../../../platform/quickinput/browser
|
|
|
5
6
|
import { ViewQuickAccessProvider, OpenViewPickerAction, QuickAccessViewPickerAction } from './viewQuickAccess.js';
|
|
6
7
|
import { CommandsQuickAccessProvider, ShowAllCommandsAction, ClearCommandHistoryAction } from './commandsQuickAccess.js';
|
|
7
8
|
import { MenuRegistry, MenuId, registerAction2 } from 'vscode/vscode/vs/platform/actions/common/actions';
|
|
9
|
+
import { KeyMod } from 'vscode/vscode/vs/base/common/keyCodes';
|
|
8
10
|
import { ContextKeyExpr } from 'vscode/vscode/vs/platform/contextkey/common/contextkey';
|
|
9
|
-
import { inQuickPickContext, getQuickNavigateHandler } from 'vscode/vscode/vs/workbench/browser/quickaccess';
|
|
10
|
-
import { KeybindingsRegistry } from 'vscode/vscode/vs/platform/keybinding/common/keybindingsRegistry';
|
|
11
|
+
import { inQuickPickContext, getQuickNavigateHandler } from '@codingame/monaco-vscode-56402b83-4a60-5b15-86f9-71fe99c32744-common/vscode/vs/workbench/browser/quickaccess';
|
|
12
|
+
import { KeybindingsRegistry, KeybindingWeight } from 'vscode/vscode/vs/platform/keybinding/common/keybindingsRegistry';
|
|
11
13
|
import { EditorContextKeys } from 'vscode/vscode/vs/editor/common/editorContextKeys';
|
|
12
14
|
|
|
13
|
-
const quickAccessRegistry = (
|
|
15
|
+
const quickAccessRegistry = ( Registry.as(Extensions.Quickaccess));
|
|
14
16
|
quickAccessRegistry.registerQuickAccessProvider({
|
|
15
17
|
ctor: HelpQuickAccessProvider,
|
|
16
18
|
prefix: HelpQuickAccessProvider.PREFIX,
|
|
17
19
|
placeholder: ( localize(
|
|
18
|
-
|
|
20
|
+
8197,
|
|
19
21
|
"Type '{0}' to get help on the actions you can take from here.",
|
|
20
22
|
HelpQuickAccessProvider.PREFIX
|
|
21
23
|
)),
|
|
22
24
|
helpEntries: [{
|
|
23
|
-
description: ( localize(
|
|
25
|
+
description: ( localize(8198, "Show all Quick Access Providers")),
|
|
24
26
|
commandCenterOrder: 70,
|
|
25
|
-
commandCenterLabel: ( localize(
|
|
27
|
+
commandCenterLabel: ( localize(8199, 'More'))
|
|
26
28
|
}]
|
|
27
29
|
});
|
|
28
30
|
quickAccessRegistry.registerQuickAccessProvider({
|
|
29
31
|
ctor: ViewQuickAccessProvider,
|
|
30
32
|
prefix: ViewQuickAccessProvider.PREFIX,
|
|
31
33
|
contextKey: 'inViewsPicker',
|
|
32
|
-
placeholder: ( localize(
|
|
33
|
-
helpEntries: [{ description: ( localize(
|
|
34
|
+
placeholder: ( localize(8200, "Type the name of a view, output channel or terminal to open.")),
|
|
35
|
+
helpEntries: [{ description: ( localize(8201, "Open View")), commandId: OpenViewPickerAction.ID }]
|
|
34
36
|
});
|
|
35
37
|
quickAccessRegistry.registerQuickAccessProvider({
|
|
36
38
|
ctor: CommandsQuickAccessProvider,
|
|
37
39
|
prefix: CommandsQuickAccessProvider.PREFIX,
|
|
38
40
|
contextKey: 'inCommandsPicker',
|
|
39
|
-
placeholder: ( localize(
|
|
40
|
-
helpEntries: [{ description: ( localize(
|
|
41
|
+
placeholder: ( localize(8202, "Type the name of a command to run.")),
|
|
42
|
+
helpEntries: [{ description: ( localize(8203, "Show and Run Commands")), commandId: ShowAllCommandsAction.ID, commandCenterOrder: 20 }]
|
|
41
43
|
});
|
|
42
44
|
MenuRegistry.appendMenuItem(MenuId.MenubarViewMenu, {
|
|
43
45
|
group: '1_open',
|
|
44
46
|
command: {
|
|
45
47
|
id: ShowAllCommandsAction.ID,
|
|
46
|
-
title: ( localize(
|
|
48
|
+
title: ( localize(8204, "&&Command Palette..."))
|
|
47
49
|
},
|
|
48
50
|
order: 1
|
|
49
51
|
});
|
|
@@ -51,7 +53,7 @@ MenuRegistry.appendMenuItem(MenuId.MenubarHelpMenu, {
|
|
|
51
53
|
group: '1_welcome',
|
|
52
54
|
command: {
|
|
53
55
|
id: ShowAllCommandsAction.ID,
|
|
54
|
-
title: ( localize(
|
|
56
|
+
title: ( localize(8205, "Show All Commands"))
|
|
55
57
|
},
|
|
56
58
|
order: 2
|
|
57
59
|
});
|
|
@@ -59,7 +61,7 @@ MenuRegistry.appendMenuItem(MenuId.MenubarViewMenu, {
|
|
|
59
61
|
group: '1_open',
|
|
60
62
|
command: {
|
|
61
63
|
id: OpenViewPickerAction.ID,
|
|
62
|
-
title: ( localize(
|
|
64
|
+
title: ( localize(8206, "&&Open View..."))
|
|
63
65
|
},
|
|
64
66
|
order: 2
|
|
65
67
|
});
|
|
@@ -67,7 +69,7 @@ MenuRegistry.appendMenuItem(MenuId.MenubarGoMenu, {
|
|
|
67
69
|
group: '5_infile_nav',
|
|
68
70
|
command: {
|
|
69
71
|
id: 'workbench.action.gotoLine',
|
|
70
|
-
title: ( localize(
|
|
72
|
+
title: ( localize(8207, "Go to &&Line/Column..."))
|
|
71
73
|
},
|
|
72
74
|
order: 1
|
|
73
75
|
});
|
|
@@ -75,16 +77,16 @@ MenuRegistry.appendMenuItem(MenuId.GlobalActivity, {
|
|
|
75
77
|
group: '1_command',
|
|
76
78
|
command: {
|
|
77
79
|
id: ShowAllCommandsAction.ID,
|
|
78
|
-
title: ( localize(
|
|
80
|
+
title: ( localize(8208, "Command Palette..."))
|
|
79
81
|
},
|
|
80
82
|
order: 1
|
|
81
83
|
});
|
|
82
84
|
MenuRegistry.appendMenuItem(MenuId.EditorContext, {
|
|
83
85
|
group: 'z_commands',
|
|
84
|
-
when: (
|
|
86
|
+
when: ( EditorContextKeys.editorSimpleInput.toNegated()),
|
|
85
87
|
command: {
|
|
86
88
|
id: ShowAllCommandsAction.ID,
|
|
87
|
-
title: ( localize(
|
|
89
|
+
title: ( localize(8208, "Command Palette...")),
|
|
88
90
|
},
|
|
89
91
|
order: 1
|
|
90
92
|
});
|
|
@@ -93,15 +95,12 @@ registerAction2(ShowAllCommandsAction);
|
|
|
93
95
|
registerAction2(OpenViewPickerAction);
|
|
94
96
|
registerAction2(QuickAccessViewPickerAction);
|
|
95
97
|
const inViewsPickerContextKey = 'inViewsPicker';
|
|
96
|
-
const inViewsPickerContext = (
|
|
97
|
-
inQuickPickContext,
|
|
98
|
-
(ContextKeyExpr.has(inViewsPickerContextKey))
|
|
99
|
-
)));
|
|
98
|
+
const inViewsPickerContext = ( ContextKeyExpr.and(inQuickPickContext, ( ContextKeyExpr.has(inViewsPickerContextKey))));
|
|
100
99
|
const viewPickerKeybinding = QuickAccessViewPickerAction.KEYBINDING;
|
|
101
100
|
const quickAccessNavigateNextInViewPickerId = 'workbench.action.quickOpenNavigateNextInViewPicker';
|
|
102
101
|
KeybindingsRegistry.registerCommandAndKeybindingRule({
|
|
103
102
|
id: quickAccessNavigateNextInViewPickerId,
|
|
104
|
-
weight:
|
|
103
|
+
weight: KeybindingWeight.WorkbenchContrib + 50,
|
|
105
104
|
handler: getQuickNavigateHandler(quickAccessNavigateNextInViewPickerId, true),
|
|
106
105
|
when: inViewsPickerContext,
|
|
107
106
|
primary: viewPickerKeybinding.primary,
|
|
@@ -111,12 +110,12 @@ KeybindingsRegistry.registerCommandAndKeybindingRule({
|
|
|
111
110
|
const quickAccessNavigatePreviousInViewPickerId = 'workbench.action.quickOpenNavigatePreviousInViewPicker';
|
|
112
111
|
KeybindingsRegistry.registerCommandAndKeybindingRule({
|
|
113
112
|
id: quickAccessNavigatePreviousInViewPickerId,
|
|
114
|
-
weight:
|
|
113
|
+
weight: KeybindingWeight.WorkbenchContrib + 50,
|
|
115
114
|
handler: getQuickNavigateHandler(quickAccessNavigatePreviousInViewPickerId, false),
|
|
116
115
|
when: inViewsPickerContext,
|
|
117
|
-
primary: viewPickerKeybinding.primary |
|
|
116
|
+
primary: viewPickerKeybinding.primary | KeyMod.Shift,
|
|
118
117
|
linux: viewPickerKeybinding.linux,
|
|
119
118
|
mac: {
|
|
120
|
-
primary: viewPickerKeybinding.mac.primary |
|
|
119
|
+
primary: viewPickerKeybinding.mac.primary | KeyMod.Shift
|
|
121
120
|
}
|
|
122
121
|
});
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { IQuickPickSeparator } from "vscode/vscode/vs/platform/quickinput/common/quickInput";
|
|
2
|
+
import { IPickerQuickAccessItem, PickerQuickAccessProvider } from "@codingame/monaco-vscode-219d9a5f-b446-507b-a188-1178a0867c75-common/vscode/vs/platform/quickinput/browser/pickerQuickAccess";
|
|
3
|
+
import { IViewDescriptorService } from "vscode/vscode/vs/workbench/common/views.service";
|
|
4
|
+
import { IViewsService } from "vscode/vscode/vs/workbench/services/views/common/viewsService.service";
|
|
5
|
+
import { IOutputService } from "vscode/vscode/vs/workbench/services/output/common/output.service";
|
|
6
|
+
import { ITerminalGroupService } from "vscode/vscode/vs/workbench/contrib/terminal/browser/terminal.service";
|
|
7
|
+
import { ITerminalService } from "vscode/vscode/vs/workbench/contrib/terminal/browser/terminal.service";
|
|
8
|
+
import { IContextKeyService } from "vscode/vscode/vs/platform/contextkey/common/contextkey.service";
|
|
9
|
+
import { Action2 } from "vscode/vscode/vs/platform/actions/common/actions";
|
|
10
|
+
import { ServicesAccessor } from "vscode/vscode/vs/platform/instantiation/common/instantiation";
|
|
11
|
+
import { IPaneCompositePartService } from "vscode/vscode/vs/workbench/services/panecomposite/browser/panecomposite.service";
|
|
12
|
+
import { IDebugService } from "vscode/vscode/vs/workbench/contrib/debug/common/debug.service";
|
|
13
|
+
interface IViewQuickPickItem extends IPickerQuickAccessItem {
|
|
14
|
+
containerLabel: string;
|
|
15
|
+
}
|
|
16
|
+
export declare class ViewQuickAccessProvider extends PickerQuickAccessProvider<IViewQuickPickItem> {
|
|
17
|
+
private readonly viewDescriptorService;
|
|
18
|
+
private readonly viewsService;
|
|
19
|
+
private readonly outputService;
|
|
20
|
+
private readonly terminalService;
|
|
21
|
+
private readonly terminalGroupService;
|
|
22
|
+
private readonly debugService;
|
|
23
|
+
private readonly paneCompositeService;
|
|
24
|
+
private readonly contextKeyService;
|
|
25
|
+
static PREFIX: string;
|
|
26
|
+
constructor(viewDescriptorService: IViewDescriptorService, viewsService: IViewsService, outputService: IOutputService, terminalService: ITerminalService, terminalGroupService: ITerminalGroupService, debugService: IDebugService, paneCompositeService: IPaneCompositePartService, contextKeyService: IContextKeyService);
|
|
27
|
+
protected _getPicks(filter: string): Array<IViewQuickPickItem | IQuickPickSeparator>;
|
|
28
|
+
private doGetViewPickItems;
|
|
29
|
+
private includeViewContainer;
|
|
30
|
+
}
|
|
31
|
+
export declare class OpenViewPickerAction extends Action2 {
|
|
32
|
+
static readonly ID = "workbench.action.openView";
|
|
33
|
+
constructor();
|
|
34
|
+
run(accessor: ServicesAccessor): Promise<void>;
|
|
35
|
+
}
|
|
36
|
+
export declare class QuickAccessViewPickerAction extends Action2 {
|
|
37
|
+
static readonly ID = "workbench.action.quickOpenView";
|
|
38
|
+
static readonly KEYBINDING: {
|
|
39
|
+
primary: number;
|
|
40
|
+
mac: {
|
|
41
|
+
primary: number;
|
|
42
|
+
};
|
|
43
|
+
linux: {
|
|
44
|
+
primary: number;
|
|
45
|
+
};
|
|
46
|
+
};
|
|
47
|
+
constructor();
|
|
48
|
+
run(accessor: ServicesAccessor): Promise<void>;
|
|
49
|
+
}
|
|
50
|
+
export {};
|
|
@@ -1,8 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
|
|
2
|
+
import { __decorate, __param } from 'vscode/external/tslib/tslib.es6';
|
|
2
3
|
import { localize, localize2 } from 'vscode/vscode/vs/nls';
|
|
3
4
|
import { ItemActivation } from 'vscode/vscode/vs/platform/quickinput/common/quickInput';
|
|
4
5
|
import { IQuickInputService } from 'vscode/vscode/vs/platform/quickinput/common/quickInput.service';
|
|
5
|
-
import { PickerQuickAccessProvider } from 'vscode/vscode/vs/platform/quickinput/browser/pickerQuickAccess';
|
|
6
|
+
import { PickerQuickAccessProvider } from '@codingame/monaco-vscode-219d9a5f-b446-507b-a188-1178a0867c75-common/vscode/vs/platform/quickinput/browser/pickerQuickAccess';
|
|
7
|
+
import { ViewContainerLocation } from 'vscode/vscode/vs/workbench/common/views';
|
|
6
8
|
import { IViewDescriptorService } from 'vscode/vscode/vs/workbench/common/views.service';
|
|
7
9
|
import { IViewsService } from 'vscode/vscode/vs/workbench/services/views/common/viewsService.service';
|
|
8
10
|
import { IOutputService } from 'vscode/vscode/vs/workbench/services/output/common/output.service';
|
|
@@ -12,6 +14,8 @@ import { matchesFuzzy } from 'vscode/vscode/vs/base/common/filters';
|
|
|
12
14
|
import { fuzzyContains } from 'vscode/vscode/vs/base/common/strings';
|
|
13
15
|
import { IKeybindingService } from 'vscode/vscode/vs/platform/keybinding/common/keybinding.service';
|
|
14
16
|
import { Action2 } from 'vscode/vscode/vs/platform/actions/common/actions';
|
|
17
|
+
import { KeyMod, KeyCode } from 'vscode/vscode/vs/base/common/keyCodes';
|
|
18
|
+
import { KeybindingWeight } from 'vscode/vscode/vs/platform/keybinding/common/keybindingsRegistry';
|
|
15
19
|
import { Categories } from 'vscode/vscode/vs/platform/action/common/actionCommonCategories';
|
|
16
20
|
import { IPaneCompositePartService } from 'vscode/vscode/vs/workbench/services/panecomposite/browser/panecomposite.service';
|
|
17
21
|
import { REPL_VIEW_ID } from 'vscode/vscode/vs/workbench/contrib/debug/common/debug';
|
|
@@ -24,7 +28,7 @@ let ViewQuickAccessProvider = class ViewQuickAccessProvider extends PickerQuickA
|
|
|
24
28
|
constructor(viewDescriptorService, viewsService, outputService, terminalService, terminalGroupService, debugService, paneCompositeService, contextKeyService) {
|
|
25
29
|
super(ViewQuickAccessProvider_1.PREFIX, {
|
|
26
30
|
noResultsPick: {
|
|
27
|
-
label: ( localize(
|
|
31
|
+
label: ( localize(8209, "No matching views")),
|
|
28
32
|
containerLabel: ''
|
|
29
33
|
}
|
|
30
34
|
});
|
|
@@ -45,9 +49,9 @@ let ViewQuickAccessProvider = class ViewQuickAccessProvider extends PickerQuickA
|
|
|
45
49
|
entry.highlights = { label: matchesFuzzy(filter, entry.label, true) ?? undefined };
|
|
46
50
|
return entry.highlights.label || fuzzyContains(entry.containerLabel, filter);
|
|
47
51
|
});
|
|
48
|
-
const mapEntryToContainer = (
|
|
52
|
+
const mapEntryToContainer = ( new Map());
|
|
49
53
|
for (const entry of filteredViewEntries) {
|
|
50
|
-
if (!(
|
|
54
|
+
if (!( mapEntryToContainer.has(entry.label))) {
|
|
51
55
|
mapEntryToContainer.set(entry.label, entry.containerLabel);
|
|
52
56
|
}
|
|
53
57
|
}
|
|
@@ -57,7 +61,7 @@ let ViewQuickAccessProvider = class ViewQuickAccessProvider extends PickerQuickA
|
|
|
57
61
|
if (lastContainer !== entry.containerLabel) {
|
|
58
62
|
lastContainer = entry.containerLabel;
|
|
59
63
|
let separatorLabel;
|
|
60
|
-
if ((
|
|
64
|
+
if (( mapEntryToContainer.has(lastContainer))) {
|
|
61
65
|
separatorLabel = `${mapEntryToContainer.get(lastContainer)} / ${lastContainer}`;
|
|
62
66
|
}
|
|
63
67
|
else {
|
|
@@ -112,9 +116,9 @@ let ViewQuickAccessProvider = class ViewQuickAccessProvider extends PickerQuickA
|
|
|
112
116
|
}
|
|
113
117
|
}
|
|
114
118
|
};
|
|
115
|
-
addPaneComposites(
|
|
116
|
-
addPaneComposites(
|
|
117
|
-
addPaneComposites(
|
|
119
|
+
addPaneComposites(ViewContainerLocation.Sidebar, ( localize(8210, "Side Bar")));
|
|
120
|
+
addPaneComposites(ViewContainerLocation.Panel, ( localize(8211, "Panel")));
|
|
121
|
+
addPaneComposites(ViewContainerLocation.AuxiliaryBar, ( localize(8212, "Secondary Side Bar")));
|
|
118
122
|
const addPaneCompositeViews = (location) => {
|
|
119
123
|
const paneComposites = this.paneCompositeService.getPaneComposites(location);
|
|
120
124
|
for (const paneComposite of paneComposites) {
|
|
@@ -124,15 +128,15 @@ let ViewQuickAccessProvider = class ViewQuickAccessProvider extends PickerQuickA
|
|
|
124
128
|
}
|
|
125
129
|
}
|
|
126
130
|
};
|
|
127
|
-
addPaneCompositeViews(
|
|
128
|
-
addPaneCompositeViews(
|
|
129
|
-
addPaneCompositeViews(
|
|
131
|
+
addPaneCompositeViews(ViewContainerLocation.Sidebar);
|
|
132
|
+
addPaneCompositeViews(ViewContainerLocation.Panel);
|
|
133
|
+
addPaneCompositeViews(ViewContainerLocation.AuxiliaryBar);
|
|
130
134
|
this.terminalGroupService.groups.forEach((group, groupIndex) => {
|
|
131
135
|
group.terminalInstances.forEach((terminal, terminalIndex) => {
|
|
132
|
-
const label = ( localize(
|
|
136
|
+
const label = ( localize(8213, "{0}: {1}", `${groupIndex + 1}.${terminalIndex + 1}`, terminal.title));
|
|
133
137
|
viewEntries.push({
|
|
134
138
|
label,
|
|
135
|
-
containerLabel: ( localize(
|
|
139
|
+
containerLabel: ( localize(8214, "Terminal")),
|
|
136
140
|
accept: async () => {
|
|
137
141
|
await this.terminalGroupService.showPanel(true);
|
|
138
142
|
this.terminalService.setActiveInstance(terminal);
|
|
@@ -144,7 +148,7 @@ let ViewQuickAccessProvider = class ViewQuickAccessProvider extends PickerQuickA
|
|
|
144
148
|
const label = session.name;
|
|
145
149
|
viewEntries.push({
|
|
146
150
|
label,
|
|
147
|
-
containerLabel: ( localize(
|
|
151
|
+
containerLabel: ( localize(8215, "Debug Console")),
|
|
148
152
|
accept: async () => {
|
|
149
153
|
await this.debugService.focusStackFrame(undefined, undefined, session, { explicit: true });
|
|
150
154
|
if (!this.viewsService.isViewVisible(REPL_VIEW_ID)) {
|
|
@@ -157,7 +161,7 @@ let ViewQuickAccessProvider = class ViewQuickAccessProvider extends PickerQuickA
|
|
|
157
161
|
for (const channel of channels) {
|
|
158
162
|
viewEntries.push({
|
|
159
163
|
label: channel.label,
|
|
160
|
-
containerLabel: ( localize(
|
|
164
|
+
containerLabel: ( localize(8216, "Output")),
|
|
161
165
|
accept: () => this.outputService.showChannel(channel.id)
|
|
162
166
|
});
|
|
163
167
|
}
|
|
@@ -171,22 +175,22 @@ let ViewQuickAccessProvider = class ViewQuickAccessProvider extends PickerQuickA
|
|
|
171
175
|
return true;
|
|
172
176
|
}
|
|
173
177
|
};
|
|
174
|
-
ViewQuickAccessProvider = ViewQuickAccessProvider_1 = (
|
|
175
|
-
(
|
|
176
|
-
(
|
|
177
|
-
(
|
|
178
|
-
(
|
|
179
|
-
(
|
|
180
|
-
(
|
|
181
|
-
(
|
|
182
|
-
(
|
|
183
|
-
], ViewQuickAccessProvider))
|
|
178
|
+
ViewQuickAccessProvider = ViewQuickAccessProvider_1 = ( __decorate([
|
|
179
|
+
( __param(0, IViewDescriptorService)),
|
|
180
|
+
( __param(1, IViewsService)),
|
|
181
|
+
( __param(2, IOutputService)),
|
|
182
|
+
( __param(3, ITerminalService)),
|
|
183
|
+
( __param(4, ITerminalGroupService)),
|
|
184
|
+
( __param(5, IDebugService)),
|
|
185
|
+
( __param(6, IPaneCompositePartService)),
|
|
186
|
+
( __param(7, IContextKeyService))
|
|
187
|
+
], ViewQuickAccessProvider));
|
|
184
188
|
class OpenViewPickerAction extends Action2 {
|
|
185
189
|
static { this.ID = 'workbench.action.openView'; }
|
|
186
190
|
constructor() {
|
|
187
191
|
super({
|
|
188
192
|
id: OpenViewPickerAction.ID,
|
|
189
|
-
title: ( localize2(
|
|
193
|
+
title: ( localize2(8217, 'Open View')),
|
|
190
194
|
category: Categories.View,
|
|
191
195
|
f1: true
|
|
192
196
|
});
|
|
@@ -198,18 +202,18 @@ class OpenViewPickerAction extends Action2 {
|
|
|
198
202
|
class QuickAccessViewPickerAction extends Action2 {
|
|
199
203
|
static { this.ID = 'workbench.action.quickOpenView'; }
|
|
200
204
|
static { this.KEYBINDING = {
|
|
201
|
-
primary:
|
|
202
|
-
mac: { primary:
|
|
205
|
+
primary: KeyMod.CtrlCmd | KeyCode.KeyQ,
|
|
206
|
+
mac: { primary: KeyMod.WinCtrl | KeyCode.KeyQ },
|
|
203
207
|
linux: { primary: 0 }
|
|
204
208
|
}; }
|
|
205
209
|
constructor() {
|
|
206
210
|
super({
|
|
207
211
|
id: QuickAccessViewPickerAction.ID,
|
|
208
|
-
title: ( localize2(
|
|
212
|
+
title: ( localize2(8218, 'Quick Open View')),
|
|
209
213
|
category: Categories.View,
|
|
210
214
|
f1: false,
|
|
211
215
|
keybinding: {
|
|
212
|
-
weight:
|
|
216
|
+
weight: KeybindingWeight.WorkbenchContrib,
|
|
213
217
|
when: undefined,
|
|
214
218
|
...QuickAccessViewPickerAction.KEYBINDING
|
|
215
219
|
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Disposable } from "vscode/vscode/vs/base/common/lifecycle";
|
|
2
|
+
import { IOpenerService } from "vscode/vscode/vs/platform/opener/common/opener.service";
|
|
3
|
+
import { IWorkbenchContribution } from "vscode/vscode/vs/workbench/common/contributions";
|
|
4
|
+
import { IBrowserWorkbenchEnvironmentService } from "vscode/vscode/vs/workbench/services/environment/browser/environmentService.service";
|
|
5
|
+
export declare class ExternalUriResolverContribution extends Disposable implements IWorkbenchContribution {
|
|
6
|
+
static readonly ID = "workbench.contrib.externalUriResolver";
|
|
7
|
+
constructor(_openerService: IOpenerService, _workbenchEnvironmentService: IBrowserWorkbenchEnvironmentService);
|
|
8
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
|
|
2
|
+
import { __decorate, __param } from 'vscode/external/tslib/tslib.es6';
|
|
2
3
|
import { Disposable } from 'vscode/vscode/vs/base/common/lifecycle';
|
|
3
4
|
import { IOpenerService } from 'vscode/vscode/vs/platform/opener/common/opener.service';
|
|
4
5
|
import { IBrowserWorkbenchEnvironmentService } from 'vscode/vscode/vs/workbench/services/environment/browser/environmentService.service';
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { Event } from "vscode/vscode/vs/base/common/event";
|
|
2
|
+
import { IDisposable } from "vscode/vscode/vs/base/common/lifecycle";
|
|
3
|
+
import { URI } from "vscode/vscode/vs/base/common/uri";
|
|
4
|
+
import { IFileDeleteOptions, IFileOverwriteOptions, FileSystemProviderCapabilities, FileType, IFileWriteOptions, IStat, IWatchOptions, IFileSystemProviderWithFileReadWriteCapability } from "vscode/vscode/vs/platform/files/common/files";
|
|
5
|
+
import { IFileService } from "vscode/vscode/vs/platform/files/common/files.service";
|
|
6
|
+
import { IStorageService } from "vscode/vscode/vs/platform/storage/common/storage.service";
|
|
7
|
+
import { IWorkbenchContribution } from "vscode/vscode/vs/workbench/common/contributions";
|
|
8
|
+
import { IInstantiationService } from "vscode/vscode/vs/platform/instantiation/common/instantiation";
|
|
9
|
+
export declare class TrustedDomainsFileSystemProvider implements IFileSystemProviderWithFileReadWriteCapability, IWorkbenchContribution {
|
|
10
|
+
private readonly fileService;
|
|
11
|
+
private readonly storageService;
|
|
12
|
+
private readonly instantiationService;
|
|
13
|
+
static readonly ID = "workbench.contrib.trustedDomainsFileSystemProvider";
|
|
14
|
+
readonly capabilities = FileSystemProviderCapabilities.FileReadWrite;
|
|
15
|
+
readonly onDidChangeCapabilities: Event<any>;
|
|
16
|
+
readonly onDidChangeFile: Event<any>;
|
|
17
|
+
constructor(fileService: IFileService, storageService: IStorageService, instantiationService: IInstantiationService);
|
|
18
|
+
stat(resource: URI): Promise<IStat>;
|
|
19
|
+
readFile(resource: URI): Promise<Uint8Array>;
|
|
20
|
+
writeFile(resource: URI, content: Uint8Array, opts: IFileWriteOptions): Promise<void>;
|
|
21
|
+
watch(resource: URI, opts: IWatchOptions): IDisposable;
|
|
22
|
+
mkdir(resource: URI): Promise<void>;
|
|
23
|
+
readdir(resource: URI): Promise<[
|
|
24
|
+
string,
|
|
25
|
+
FileType
|
|
26
|
+
][]>;
|
|
27
|
+
delete(resource: URI, opts: IFileDeleteOptions): Promise<void>;
|
|
28
|
+
rename(from: URI, to: URI, opts: IFileOverwriteOptions): Promise<void>;
|
|
29
|
+
}
|
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
|
|
1
|
+
|
|
2
|
+
import { __decorate, __param } from 'vscode/external/tslib/tslib.es6';
|
|
2
3
|
import { Event } from 'vscode/vscode/vs/base/common/event';
|
|
3
4
|
import { parse } from 'vscode/vscode/vs/base/common/json';
|
|
4
|
-
import { FileType } from 'vscode/vscode/vs/platform/files/common/files';
|
|
5
|
+
import { FileType, FileSystemProviderCapabilities } from 'vscode/vscode/vs/platform/files/common/files';
|
|
5
6
|
import { IFileService } from 'vscode/vscode/vs/platform/files/common/files.service';
|
|
7
|
+
import { StorageScope, StorageTarget } from 'vscode/vscode/vs/platform/storage/common/storage';
|
|
6
8
|
import { IStorageService } from 'vscode/vscode/vs/platform/storage/common/storage.service';
|
|
7
9
|
import { VSBuffer } from 'vscode/vscode/vs/base/common/buffer';
|
|
8
|
-
import { TRUSTED_DOMAINS_CONTENT_STORAGE_KEY, readTrustedDomains, TRUSTED_DOMAINS_STORAGE_KEY } from 'vscode/vscode/vs/workbench/contrib/url/browser/trustedDomains';
|
|
10
|
+
import { TRUSTED_DOMAINS_CONTENT_STORAGE_KEY, readTrustedDomains, TRUSTED_DOMAINS_STORAGE_KEY } from '@codingame/monaco-vscode-9a1a5840-af83-5d07-a156-ba32a36c5c4b-common/vscode/vs/workbench/contrib/url/browser/trustedDomains';
|
|
9
11
|
import { assertIsDefined } from 'vscode/vscode/vs/base/common/types';
|
|
10
12
|
import { IInstantiationService } from 'vscode/vscode/vs/platform/instantiation/common/instantiation';
|
|
11
13
|
|
|
@@ -65,7 +67,7 @@ let TrustedDomainsFileSystemProvider = class TrustedDomainsFileSystemProvider {
|
|
|
65
67
|
this.fileService = fileService;
|
|
66
68
|
this.storageService = storageService;
|
|
67
69
|
this.instantiationService = instantiationService;
|
|
68
|
-
this.capabilities =
|
|
70
|
+
this.capabilities = FileSystemProviderCapabilities.FileReadWrite;
|
|
69
71
|
this.onDidChangeCapabilities = Event.None;
|
|
70
72
|
this.onDidChangeFile = Event.None;
|
|
71
73
|
this.fileService.registerProvider(TRUSTED_DOMAINS_SCHEMA, this);
|
|
@@ -74,7 +76,7 @@ let TrustedDomainsFileSystemProvider = class TrustedDomainsFileSystemProvider {
|
|
|
74
76
|
return Promise.resolve(TRUSTED_DOMAINS_STAT);
|
|
75
77
|
}
|
|
76
78
|
async readFile(resource) {
|
|
77
|
-
let trustedDomainsContent = this.storageService.get(TRUSTED_DOMAINS_CONTENT_STORAGE_KEY,
|
|
79
|
+
let trustedDomainsContent = this.storageService.get(TRUSTED_DOMAINS_CONTENT_STORAGE_KEY, StorageScope.APPLICATION);
|
|
78
80
|
const configuring = resource.fragment;
|
|
79
81
|
const { defaultTrustedDomains, trustedDomains } = await this.instantiationService.invokeFunction(readTrustedDomains);
|
|
80
82
|
if (!trustedDomainsContent ||
|
|
@@ -91,8 +93,8 @@ let TrustedDomainsFileSystemProvider = class TrustedDomainsFileSystemProvider {
|
|
|
91
93
|
try {
|
|
92
94
|
const trustedDomainsContent = ( VSBuffer.wrap(content).toString());
|
|
93
95
|
const trustedDomains = parse(trustedDomainsContent);
|
|
94
|
-
this.storageService.store(TRUSTED_DOMAINS_CONTENT_STORAGE_KEY, trustedDomainsContent,
|
|
95
|
-
this.storageService.store(TRUSTED_DOMAINS_STORAGE_KEY, JSON.stringify(trustedDomains) || '',
|
|
96
|
+
this.storageService.store(TRUSTED_DOMAINS_CONTENT_STORAGE_KEY, trustedDomainsContent, StorageScope.APPLICATION, StorageTarget.USER);
|
|
97
|
+
this.storageService.store(TRUSTED_DOMAINS_STORAGE_KEY, JSON.stringify(trustedDomains) || '', StorageScope.APPLICATION, StorageTarget.USER);
|
|
96
98
|
}
|
|
97
99
|
catch (err) { }
|
|
98
100
|
return Promise.resolve();
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { URI } from "vscode/vscode/vs/base/common/uri";
|
|
2
|
+
import { IClipboardService } from "vscode/vscode/vs/platform/clipboard/common/clipboardService.service";
|
|
3
|
+
import { IConfigurationService } from "vscode/vscode/vs/platform/configuration/common/configuration.service";
|
|
4
|
+
import { IDialogService } from "vscode/vscode/vs/platform/dialogs/common/dialogs.service";
|
|
5
|
+
import { IInstantiationService } from "vscode/vscode/vs/platform/instantiation/common/instantiation";
|
|
6
|
+
import { OpenOptions } from "vscode/vscode/vs/platform/opener/common/opener";
|
|
7
|
+
import { IOpenerService } from "vscode/vscode/vs/platform/opener/common/opener.service";
|
|
8
|
+
import { IProductService } from "vscode/vscode/vs/platform/product/common/productService.service";
|
|
9
|
+
import { IQuickInputService } from "vscode/vscode/vs/platform/quickinput/common/quickInput.service";
|
|
10
|
+
import { IStorageService } from "vscode/vscode/vs/platform/storage/common/storage.service";
|
|
11
|
+
import { ITelemetryService } from "vscode/vscode/vs/platform/telemetry/common/telemetry.service";
|
|
12
|
+
import { IWorkspaceTrustManagementService } from "vscode/vscode/vs/platform/workspace/common/workspaceTrust.service";
|
|
13
|
+
import { IWorkbenchContribution } from "vscode/vscode/vs/workbench/common/contributions";
|
|
14
|
+
import { ITrustedDomainService } from "vscode/vscode/vs/workbench/contrib/url/browser/trustedDomainService.service";
|
|
15
|
+
import { IEditorService } from "vscode/vscode/vs/workbench/services/editor/common/editorService.service";
|
|
16
|
+
export declare class OpenerValidatorContributions implements IWorkbenchContribution {
|
|
17
|
+
private readonly _openerService;
|
|
18
|
+
private readonly _storageService;
|
|
19
|
+
private readonly _dialogService;
|
|
20
|
+
private readonly _productService;
|
|
21
|
+
private readonly _quickInputService;
|
|
22
|
+
private readonly _editorService;
|
|
23
|
+
private readonly _clipboardService;
|
|
24
|
+
private readonly _telemetryService;
|
|
25
|
+
private readonly _instantiationService;
|
|
26
|
+
private readonly _configurationService;
|
|
27
|
+
private readonly _workspaceTrustService;
|
|
28
|
+
private readonly _trustedDomainService;
|
|
29
|
+
constructor(_openerService: IOpenerService, _storageService: IStorageService, _dialogService: IDialogService, _productService: IProductService, _quickInputService: IQuickInputService, _editorService: IEditorService, _clipboardService: IClipboardService, _telemetryService: ITelemetryService, _instantiationService: IInstantiationService, _configurationService: IConfigurationService, _workspaceTrustService: IWorkspaceTrustManagementService, _trustedDomainService: ITrustedDomainService);
|
|
30
|
+
validateLink(resource: URI | string, openOptions?: OpenOptions): Promise<boolean>;
|
|
31
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
|
|
2
|
+
import { __decorate, __param } from 'vscode/external/tslib/tslib.es6';
|
|
2
3
|
import { matchesScheme, Schemas } from 'vscode/vscode/vs/base/common/network';
|
|
3
|
-
import Severity
|
|
4
|
+
import Severity from 'vscode/vscode/vs/base/common/severity';
|
|
4
5
|
import { URI } from 'vscode/vscode/vs/base/common/uri';
|
|
5
6
|
import { localize } from 'vscode/vscode/vs/nls';
|
|
6
7
|
import { IClipboardService } from 'vscode/vscode/vs/platform/clipboard/common/clipboardService.service';
|
|
@@ -13,9 +14,9 @@ import { IQuickInputService } from 'vscode/vscode/vs/platform/quickinput/common/
|
|
|
13
14
|
import { IStorageService } from 'vscode/vscode/vs/platform/storage/common/storage.service';
|
|
14
15
|
import { ITelemetryService } from 'vscode/vscode/vs/platform/telemetry/common/telemetry.service';
|
|
15
16
|
import { IWorkspaceTrustManagementService } from 'vscode/vscode/vs/platform/workspace/common/workspaceTrust.service';
|
|
16
|
-
import { isURLDomainTrusted } from 'vscode/vscode/vs/workbench/contrib/url/browser/trustedDomainService';
|
|
17
|
+
import { isURLDomainTrusted } from '@codingame/monaco-vscode-9a1a5840-af83-5d07-a156-ba32a36c5c4b-common/vscode/vs/workbench/contrib/url/browser/trustedDomainService';
|
|
17
18
|
import { ITrustedDomainService } from 'vscode/vscode/vs/workbench/contrib/url/browser/trustedDomainService.service';
|
|
18
|
-
import { readStaticTrustedDomains, configureOpenerTrustedDomainsHandler } from 'vscode/vscode/vs/workbench/contrib/url/browser/trustedDomains';
|
|
19
|
+
import { readStaticTrustedDomains, configureOpenerTrustedDomainsHandler } from '@codingame/monaco-vscode-9a1a5840-af83-5d07-a156-ba32a36c5c4b-common/vscode/vs/workbench/contrib/url/browser/trustedDomains';
|
|
19
20
|
import { IEditorService } from 'vscode/vscode/vs/workbench/services/editor/common/editorService.service';
|
|
20
21
|
|
|
21
22
|
let OpenerValidatorContributions = class OpenerValidatorContributions {
|
|
@@ -44,7 +45,7 @@ let OpenerValidatorContributions = class OpenerValidatorContributions {
|
|
|
44
45
|
const originalResource = resource;
|
|
45
46
|
let resourceUri;
|
|
46
47
|
if (typeof resource === 'string') {
|
|
47
|
-
resourceUri = (
|
|
48
|
+
resourceUri = ( URI.parse(resource));
|
|
48
49
|
}
|
|
49
50
|
else {
|
|
50
51
|
resourceUri = resource;
|
|
@@ -65,27 +66,27 @@ let OpenerValidatorContributions = class OpenerValidatorContributions {
|
|
|
65
66
|
formattedLink += linkTail.charAt(0) + '...' + linkTail.substring(linkTail.length - linkTailLengthToKeep + 1);
|
|
66
67
|
}
|
|
67
68
|
const { result } = await this._dialogService.prompt({
|
|
68
|
-
type: Severity
|
|
69
|
+
type: Severity.Info,
|
|
69
70
|
message: ( localize(
|
|
70
|
-
|
|
71
|
+
10470,
|
|
71
72
|
'Do you want {0} to open the external website?',
|
|
72
73
|
this._productService.nameShort
|
|
73
74
|
)),
|
|
74
75
|
detail: typeof originalResource === 'string' ? originalResource : formattedLink,
|
|
75
76
|
buttons: [
|
|
76
77
|
{
|
|
77
|
-
label: ( localize(
|
|
78
|
+
label: ( localize(10471, '&&Open')),
|
|
78
79
|
run: () => true
|
|
79
80
|
},
|
|
80
81
|
{
|
|
81
|
-
label: ( localize(
|
|
82
|
+
label: ( localize(10472, '&&Copy')),
|
|
82
83
|
run: () => {
|
|
83
|
-
this._clipboardService.writeText(typeof originalResource === 'string' ? originalResource : (
|
|
84
|
+
this._clipboardService.writeText(typeof originalResource === 'string' ? originalResource : ( resourceUri.toString(true)));
|
|
84
85
|
return false;
|
|
85
86
|
}
|
|
86
87
|
},
|
|
87
88
|
{
|
|
88
|
-
label: ( localize(
|
|
89
|
+
label: ( localize(10473, 'Configure &&Trusted Domains')),
|
|
89
90
|
run: async () => {
|
|
90
91
|
const { trustedDomains, } = this._instantiationService.invokeFunction(readStaticTrustedDomains);
|
|
91
92
|
const domainToOpen = `${scheme}://${authority}`;
|
|
@@ -108,19 +109,19 @@ let OpenerValidatorContributions = class OpenerValidatorContributions {
|
|
|
108
109
|
}
|
|
109
110
|
}
|
|
110
111
|
};
|
|
111
|
-
OpenerValidatorContributions = (
|
|
112
|
-
(
|
|
113
|
-
(
|
|
114
|
-
(
|
|
115
|
-
(
|
|
116
|
-
(
|
|
117
|
-
(
|
|
118
|
-
(
|
|
119
|
-
(
|
|
120
|
-
(
|
|
121
|
-
(
|
|
122
|
-
(
|
|
123
|
-
(
|
|
124
|
-
], OpenerValidatorContributions))
|
|
112
|
+
OpenerValidatorContributions = ( __decorate([
|
|
113
|
+
( __param(0, IOpenerService)),
|
|
114
|
+
( __param(1, IStorageService)),
|
|
115
|
+
( __param(2, IDialogService)),
|
|
116
|
+
( __param(3, IProductService)),
|
|
117
|
+
( __param(4, IQuickInputService)),
|
|
118
|
+
( __param(5, IEditorService)),
|
|
119
|
+
( __param(6, IClipboardService)),
|
|
120
|
+
( __param(7, ITelemetryService)),
|
|
121
|
+
( __param(8, IInstantiationService)),
|
|
122
|
+
( __param(9, IConfigurationService)),
|
|
123
|
+
( __param(10, IWorkspaceTrustManagementService)),
|
|
124
|
+
( __param(11, ITrustedDomainService))
|
|
125
|
+
], OpenerValidatorContributions));
|
|
125
126
|
|
|
126
127
|
export { OpenerValidatorContributions };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|