@codingame/monaco-vscode-view-common-service-override 22.1.8 → 23.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.js +5 -5
- package/package.json +41 -41
- package/vscode/src/vs/platform/actions/browser/actionViewItemService.d.ts +1 -1
- package/vscode/src/vs/workbench/api/browser/viewsExtensionPoint.js +92 -69
- package/vscode/src/vs/workbench/browser/actions/listCommands.js +4 -4
- package/vscode/src/vs/workbench/browser/actions/navigationActions.js +6 -6
- package/vscode/src/vs/workbench/browser/parts/editor/editor.contribution.js +175 -175
- package/vscode/src/vs/workbench/browser/parts/editor/editorConfiguration.js +8 -8
- package/vscode/src/vs/workbench/contrib/callHierarchy/browser/callHierarchy.contribution.js +12 -12
- package/vscode/src/vs/workbench/contrib/callHierarchy/browser/callHierarchyPeek.js +5 -5
- package/vscode/src/vs/workbench/contrib/callHierarchy/browser/callHierarchyTree.js +3 -3
- package/vscode/src/vs/workbench/contrib/customEditor/browser/customEditorInputFactory.d.ts +6 -1
- package/vscode/src/vs/workbench/contrib/customEditor/browser/customEditorInputFactory.js +18 -5
- package/vscode/src/vs/workbench/contrib/customEditor/browser/customEditors.js +6 -6
- package/vscode/src/vs/workbench/contrib/customEditor/common/contributedCustomEditors.js +8 -7
- package/vscode/src/vs/workbench/contrib/customEditor/common/customEditor.js +1 -1
- package/vscode/src/vs/workbench/contrib/customEditor/common/extensionPoint.d.ts +64 -14
- package/vscode/src/vs/workbench/contrib/customEditor/common/extensionPoint.js +79 -77
- package/vscode/src/vs/workbench/contrib/languageStatus/browser/languageStatus.js +7 -7
- package/vscode/src/vs/workbench/contrib/limitIndicator/browser/limitIndicator.contribution.js +8 -8
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/commands/commands.d.ts +3 -3
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/commands/commands.js +30 -30
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/commands/devCommands.js +14 -14
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/mergeEditor.contribution.js +3 -3
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/mergeEditorAccessibilityHelp.js +5 -5
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/colors.js +13 -13
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/editorGutter.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/editorGutter.js +1 -1
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/editors/baseCodeEditorView.js +3 -3
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/editors/inputCodeEditorView.d.ts +2 -2
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/editors/inputCodeEditorView.js +12 -12
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/editors/resultCodeEditorView.js +6 -6
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/lineAlignment.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/lineAlignment.js +2 -2
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/mergeEditor.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/mergeEditor.js +3 -3
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/scrollSynchronizer.js +1 -1
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/viewModel.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/viewModel.js +2 -2
- package/vscode/src/vs/workbench/contrib/mergeEditor/browser/view/viewZones.js +2 -2
- package/vscode/src/vs/workbench/contrib/preferences/browser/keyboardLayoutPicker.js +12 -12
- package/vscode/src/vs/workbench/contrib/sash/browser/sash.contribution.js +2 -2
- package/vscode/src/vs/workbench/contrib/scrollLocking/browser/scrollLocking.js +8 -8
- package/vscode/src/vs/workbench/contrib/typeHierarchy/browser/typeHierarchy.contribution.js +10 -10
- package/vscode/src/vs/workbench/contrib/typeHierarchy/browser/typeHierarchyPeek.js +5 -5
- package/vscode/src/vs/workbench/contrib/typeHierarchy/browser/typeHierarchyTree.js +3 -3
- package/vscode/src/vs/workbench/contrib/webview/browser/overlayWebview.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/webview/browser/overlayWebview.js +1 -1
- package/vscode/src/vs/workbench/contrib/webview/browser/themeing.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/webview/browser/themeing.js +2 -1
- package/vscode/src/vs/workbench/contrib/webview/browser/webviewElement.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/webview/browser/webviewElement.js +2 -2
- package/vscode/src/vs/workbench/contrib/webview/browser/webviewFindWidget.js +1 -1
- package/vscode/src/vs/workbench/contrib/webview/browser/webviewService.d.ts +1 -1
- package/vscode/src/vs/workbench/contrib/webviewPanel/browser/webviewCommands.js +7 -7
- package/vscode/src/vs/workbench/contrib/webviewPanel/browser/webviewEditorInputSerializer.d.ts +2 -3
- package/vscode/src/vs/workbench/contrib/webviewPanel/browser/webviewEditorInputSerializer.js +2 -2
- package/vscode/src/vs/workbench/contrib/webviewPanel/browser/webviewPanel.contribution.js +2 -2
- package/vscode/src/vs/workbench/contrib/webviewView/browser/webviewViewPane.js +3 -3
- package/vscode/src/vs/workbench/contrib/webviewView/browser/webviewViewService.d.ts +1 -1
- package/vscode/src/vs/workbench/services/editor/browser/editorResolverService.js +12 -12
- package/vscode/src/vs/workbench/services/history/browser/historyService.js +10 -10
- package/vscode/src/vs/workbench/services/progress/browser/progressService.js +10 -10
- package/vscode/src/vs/workbench/services/untitled/common/untitledTextEditorHandler.d.ts +2 -2
- package/vscode/src/vs/workbench/services/untitled/common/untitledTextEditorHandler.js +2 -2
- package/vscode/src/vs/workbench/services/views/browser/viewDescriptorService.js +5 -5
|
@@ -1,49 +1,51 @@
|
|
|
1
1
|
|
|
2
2
|
import { __decorate, __param } from '@codingame/monaco-vscode-api/external/tslib/tslib.es6';
|
|
3
|
+
import { MarkdownString } from '@codingame/monaco-vscode-api/vscode/vs/base/common/htmlContent';
|
|
4
|
+
import { Disposable } from '@codingame/monaco-vscode-api/vscode/vs/base/common/lifecycle';
|
|
3
5
|
import { joinPath } from '@codingame/monaco-vscode-api/vscode/vs/base/common/resources';
|
|
4
6
|
import { isFalsyOrWhitespace } from '@codingame/monaco-vscode-api/vscode/vs/base/common/strings';
|
|
7
|
+
import { ThemeIcon } from '@codingame/monaco-vscode-api/vscode/vs/base/common/themables';
|
|
5
8
|
import { localize } from '@codingame/monaco-vscode-api/vscode/vs/nls';
|
|
6
9
|
import { ContextKeyExpr } from '@codingame/monaco-vscode-api/vscode/vs/platform/contextkey/common/contextkey';
|
|
7
10
|
import { ExtensionIdentifierSet, ExtensionIdentifier } from '@codingame/monaco-vscode-api/vscode/vs/platform/extensions/common/extensions';
|
|
8
11
|
import { SyncDescriptor } from '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/descriptors';
|
|
9
12
|
import { IInstantiationService } from '@codingame/monaco-vscode-api/vscode/vs/platform/instantiation/common/instantiation';
|
|
13
|
+
import { ILogService } from '@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service';
|
|
10
14
|
import { Registry } from '@codingame/monaco-vscode-api/vscode/vs/platform/registry/common/platform';
|
|
11
|
-
import { ThemeIcon } from '@codingame/monaco-vscode-api/vscode/vs/base/common/themables';
|
|
12
15
|
import { Extensions as Extensions$1 } from '@codingame/monaco-vscode-9efc1f50-c7de-55d6-8b28-bcc88bd49b5a-common/vscode/vs/workbench/browser/panecomposite';
|
|
13
16
|
import { CustomTreeView, TreeViewPane } from '@codingame/monaco-vscode-4a316137-39d1-5d77-8b53-112db3547c1e-common/vscode/vs/workbench/browser/parts/views/treeView';
|
|
14
17
|
import { ViewPaneContainer } from '@codingame/monaco-vscode-a8d3bd74-e63e-5327-96e8-4f931661e329-common/vscode/vs/workbench/browser/parts/views/viewPaneContainer';
|
|
15
18
|
import { registerWorkbenchContribution2, WorkbenchPhase } from '@codingame/monaco-vscode-api/vscode/vs/workbench/common/contributions';
|
|
16
19
|
import { Extensions, ViewContainerLocation } from '@codingame/monaco-vscode-api/vscode/vs/workbench/common/views';
|
|
20
|
+
import { ChatContextKeyExprs } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/chatContextKeys';
|
|
21
|
+
import { AGENT_SESSIONS_VIEWLET_ID } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/chat/common/constants';
|
|
17
22
|
import { VIEWLET_ID as VIEWLET_ID$3 } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/debug/common/debug';
|
|
18
23
|
import { VIEWLET_ID as VIEWLET_ID$1 } from '@codingame/monaco-vscode-f24e325c-2ce0-5bba-8236-bfc4f53180ab-common/vscode/vs/workbench/contrib/files/common/files';
|
|
19
24
|
import { VIEWLET_ID } from '@codingame/monaco-vscode-1b4486de-4fe4-59c4-9e6d-34f265ff6625-common/vscode/vs/workbench/contrib/remote/browser/remoteExplorer';
|
|
20
|
-
import { VIEWLET_ID as VIEWLET_ID$2 } from '@codingame/monaco-vscode-
|
|
25
|
+
import { VIEWLET_ID as VIEWLET_ID$2 } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/scm/common/scm';
|
|
21
26
|
import { WebviewViewPane } from '../../contrib/webviewView/browser/webviewViewPane.js';
|
|
22
|
-
import { checkProposedApiEnabled, isProposedApiEnabled } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions';
|
|
23
|
-
import { ExtensionsRegistry } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionsRegistry';
|
|
24
|
-
import { ILogService } from '@codingame/monaco-vscode-api/vscode/vs/platform/log/common/log.service';
|
|
25
27
|
import { Extensions as Extensions$2 } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensionManagement/common/extensionFeatures';
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
+
import { isProposedApiEnabled } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensions';
|
|
29
|
+
import { ExtensionsRegistry } from '@codingame/monaco-vscode-api/vscode/vs/workbench/services/extensions/common/extensionsRegistry';
|
|
28
30
|
|
|
29
31
|
const viewsContainerSchema = {
|
|
30
32
|
type: 'object',
|
|
31
33
|
properties: {
|
|
32
34
|
id: {
|
|
33
35
|
description: ( localize(
|
|
34
|
-
|
|
36
|
+
2543,
|
|
35
37
|
"Unique id used to identify the container in which views can be contributed using 'views' contribution point"
|
|
36
38
|
)),
|
|
37
39
|
type: 'string',
|
|
38
40
|
pattern: '^[a-zA-Z0-9_-]+$'
|
|
39
41
|
},
|
|
40
42
|
title: {
|
|
41
|
-
description: ( localize(
|
|
43
|
+
description: ( localize(2544, 'Human readable string used to render the container')),
|
|
42
44
|
type: 'string'
|
|
43
45
|
},
|
|
44
46
|
icon: {
|
|
45
47
|
description: ( localize(
|
|
46
|
-
|
|
48
|
+
2545,
|
|
47
49
|
"Path to the container icon. Icons are 24x24 centered on a 50x40 block and have a fill color of 'rgb(215, 218, 224)' or '#d7dae0'. It is recommended that icons be in SVG, though any image file type is accepted."
|
|
48
50
|
)),
|
|
49
51
|
type: 'string'
|
|
@@ -52,21 +54,21 @@ const viewsContainerSchema = {
|
|
|
52
54
|
required: ['id', 'title', 'icon']
|
|
53
55
|
};
|
|
54
56
|
const viewsContainersContribution = {
|
|
55
|
-
description: ( localize(
|
|
57
|
+
description: ( localize(2546, 'Contributes views containers to the editor')),
|
|
56
58
|
type: 'object',
|
|
57
59
|
properties: {
|
|
58
60
|
'activitybar': {
|
|
59
|
-
description: ( localize(
|
|
61
|
+
description: ( localize(2547, "Contribute views containers to Activity Bar")),
|
|
60
62
|
type: 'array',
|
|
61
63
|
items: viewsContainerSchema
|
|
62
64
|
},
|
|
63
65
|
'panel': {
|
|
64
|
-
description: ( localize(
|
|
66
|
+
description: ( localize(2548, "Contribute views containers to Panel")),
|
|
65
67
|
type: 'array',
|
|
66
68
|
items: viewsContainerSchema
|
|
67
69
|
},
|
|
68
70
|
'secondarySidebar': {
|
|
69
|
-
description: ( localize(
|
|
71
|
+
description: ( localize(2549, "Contribute views containers to Secondary Side Bar")),
|
|
70
72
|
type: 'array',
|
|
71
73
|
items: viewsContainerSchema
|
|
72
74
|
}
|
|
@@ -91,7 +93,7 @@ const viewDescriptor = {
|
|
|
91
93
|
properties: {
|
|
92
94
|
type: {
|
|
93
95
|
markdownDescription: ( localize(
|
|
94
|
-
|
|
96
|
+
2550,
|
|
95
97
|
"Type of the view. This can either be `tree` for a tree view based view or `webview` for a webview based view. The default is `tree`."
|
|
96
98
|
)),
|
|
97
99
|
type: 'string',
|
|
@@ -100,45 +102,45 @@ const viewDescriptor = {
|
|
|
100
102
|
'webview',
|
|
101
103
|
],
|
|
102
104
|
markdownEnumDescriptions: [
|
|
103
|
-
( localize(
|
|
105
|
+
( localize(2551, "The view is backed by a `TreeView` created by `createTreeView`.")),
|
|
104
106
|
( localize(
|
|
105
|
-
|
|
107
|
+
2552,
|
|
106
108
|
"The view is backed by a `WebviewView` registered by `registerWebviewViewProvider`."
|
|
107
109
|
)),
|
|
108
110
|
]
|
|
109
111
|
},
|
|
110
112
|
id: {
|
|
111
113
|
markdownDescription: ( localize(
|
|
112
|
-
|
|
114
|
+
2553,
|
|
113
115
|
'Identifier of the view. This should be unique across all views. It is recommended to include your extension id as part of the view id. Use this to register a data provider through `vscode.window.registerTreeDataProviderForView` API. Also to trigger activating your extension by registering `onView:${id}` event to `activationEvents`.'
|
|
114
116
|
)),
|
|
115
117
|
type: 'string'
|
|
116
118
|
},
|
|
117
119
|
name: {
|
|
118
|
-
description: ( localize(
|
|
120
|
+
description: ( localize(2554, 'The human-readable name of the view. Will be shown')),
|
|
119
121
|
type: 'string'
|
|
120
122
|
},
|
|
121
123
|
when: {
|
|
122
|
-
description: ( localize(
|
|
124
|
+
description: ( localize(2555, 'Condition which must be true to show this view')),
|
|
123
125
|
type: 'string'
|
|
124
126
|
},
|
|
125
127
|
icon: {
|
|
126
128
|
description: ( localize(
|
|
127
|
-
|
|
129
|
+
2556,
|
|
128
130
|
"Path to the view icon. View icons are displayed when the name of the view cannot be shown. It is recommended that icons be in SVG, though any image file type is accepted."
|
|
129
131
|
)),
|
|
130
132
|
type: 'string'
|
|
131
133
|
},
|
|
132
134
|
contextualTitle: {
|
|
133
135
|
description: ( localize(
|
|
134
|
-
|
|
136
|
+
2557,
|
|
135
137
|
"Human-readable context for when the view is moved out of its original location. By default, the view's container name will be used."
|
|
136
138
|
)),
|
|
137
139
|
type: 'string'
|
|
138
140
|
},
|
|
139
141
|
visibility: {
|
|
140
142
|
description: ( localize(
|
|
141
|
-
|
|
143
|
+
2558,
|
|
142
144
|
"Initial state of the view when the extension is first installed. Once the user has changed the view state by collapsing, moving, or hiding the view, the initial state will not be used again."
|
|
143
145
|
)),
|
|
144
146
|
type: 'string',
|
|
@@ -150,27 +152,27 @@ const viewDescriptor = {
|
|
|
150
152
|
default: 'visible',
|
|
151
153
|
enumDescriptions: [
|
|
152
154
|
( localize(
|
|
153
|
-
|
|
155
|
+
2559,
|
|
154
156
|
"The default initial state for the view. In most containers the view will be expanded, however; some built-in containers (explorer, scm, and debug) show all contributed views collapsed regardless of the `visibility`."
|
|
155
157
|
)),
|
|
156
158
|
( localize(
|
|
157
|
-
|
|
159
|
+
2560,
|
|
158
160
|
"The view will not be shown in the view container, but will be discoverable through the views menu and other view entry points and can be un-hidden by the user."
|
|
159
161
|
)),
|
|
160
|
-
( localize(
|
|
162
|
+
( localize(2561, "The view will show in the view container, but will be collapsed."))
|
|
161
163
|
]
|
|
162
164
|
},
|
|
163
165
|
initialSize: {
|
|
164
166
|
type: 'number',
|
|
165
167
|
description: ( localize(
|
|
166
|
-
|
|
168
|
+
2562,
|
|
167
169
|
"The initial size of the view. The size will behave like the css 'flex' property, and will set the initial size when the view is first shown. In the side bar, this is the height of the view. This value is only respected when the same extension owns both the view and the view container."
|
|
168
170
|
)),
|
|
169
171
|
},
|
|
170
172
|
accessibilityHelpContent: {
|
|
171
173
|
type: 'string',
|
|
172
174
|
markdownDescription: ( localize(
|
|
173
|
-
|
|
175
|
+
2563,
|
|
174
176
|
"When the accessibility help dialog is invoked in this view, this content will be presented to the user as a markdown string. Keybindings will be resolved when provided in the format of <keybinding:commandId>. If there is no keybinding, that will be indicated and this command will be included in a quickpick for easy configuration."
|
|
175
177
|
))
|
|
176
178
|
}
|
|
@@ -182,25 +184,25 @@ const remoteViewDescriptor = {
|
|
|
182
184
|
properties: {
|
|
183
185
|
id: {
|
|
184
186
|
description: ( localize(
|
|
185
|
-
|
|
187
|
+
2553,
|
|
186
188
|
'Identifier of the view. This should be unique across all views. It is recommended to include your extension id as part of the view id. Use this to register a data provider through `vscode.window.registerTreeDataProviderForView` API. Also to trigger activating your extension by registering `onView:${id}` event to `activationEvents`.'
|
|
187
189
|
)),
|
|
188
190
|
type: 'string'
|
|
189
191
|
},
|
|
190
192
|
name: {
|
|
191
|
-
description: ( localize(
|
|
193
|
+
description: ( localize(2554, 'The human-readable name of the view. Will be shown')),
|
|
192
194
|
type: 'string'
|
|
193
195
|
},
|
|
194
196
|
when: {
|
|
195
|
-
description: ( localize(
|
|
197
|
+
description: ( localize(2555, 'Condition which must be true to show this view')),
|
|
196
198
|
type: 'string'
|
|
197
199
|
},
|
|
198
200
|
group: {
|
|
199
|
-
description: ( localize(
|
|
201
|
+
description: ( localize(2564, 'Nested group in the viewlet')),
|
|
200
202
|
type: 'string'
|
|
201
203
|
},
|
|
202
204
|
remoteName: {
|
|
203
|
-
description: ( localize(
|
|
205
|
+
description: ( localize(2565, 'The name of the remote type associated with this view')),
|
|
204
206
|
type: ['string', 'array'],
|
|
205
207
|
items: {
|
|
206
208
|
type: 'string'
|
|
@@ -209,45 +211,54 @@ const remoteViewDescriptor = {
|
|
|
209
211
|
}
|
|
210
212
|
};
|
|
211
213
|
const viewsContribution = {
|
|
212
|
-
description: ( localize(
|
|
214
|
+
description: ( localize(2566, "Contributes views to the editor")),
|
|
213
215
|
type: 'object',
|
|
214
216
|
properties: {
|
|
215
217
|
'explorer': {
|
|
216
|
-
description: ( localize(
|
|
218
|
+
description: ( localize(2567, "Contributes views to Explorer container in the Activity bar")),
|
|
217
219
|
type: 'array',
|
|
218
220
|
items: viewDescriptor,
|
|
219
221
|
default: []
|
|
220
222
|
},
|
|
221
223
|
'debug': {
|
|
222
|
-
description: ( localize(
|
|
224
|
+
description: ( localize(2568, "Contributes views to Debug container in the Activity bar")),
|
|
223
225
|
type: 'array',
|
|
224
226
|
items: viewDescriptor,
|
|
225
227
|
default: []
|
|
226
228
|
},
|
|
227
229
|
'scm': {
|
|
228
|
-
description: ( localize(
|
|
230
|
+
description: ( localize(2569, "Contributes views to SCM container in the Activity bar")),
|
|
229
231
|
type: 'array',
|
|
230
232
|
items: viewDescriptor,
|
|
231
233
|
default: []
|
|
232
234
|
},
|
|
233
235
|
'test': {
|
|
234
|
-
description: ( localize(
|
|
236
|
+
description: ( localize(2570, "Contributes views to Test container in the Activity bar")),
|
|
235
237
|
type: 'array',
|
|
236
238
|
items: viewDescriptor,
|
|
237
239
|
default: []
|
|
238
240
|
},
|
|
239
241
|
'remote': {
|
|
240
242
|
description: ( localize(
|
|
241
|
-
|
|
242
|
-
"Contributes views to Remote container in the Activity bar. To contribute to this container,
|
|
243
|
+
2571,
|
|
244
|
+
"Contributes views to Remote container in the Activity bar. To contribute to this container, the 'contribViewsRemote' API proposal must be enabled."
|
|
243
245
|
)),
|
|
244
246
|
type: 'array',
|
|
245
247
|
items: remoteViewDescriptor,
|
|
246
248
|
default: []
|
|
249
|
+
},
|
|
250
|
+
'agentSessions': {
|
|
251
|
+
description: ( localize(
|
|
252
|
+
2572,
|
|
253
|
+
"Contributes views to Agent Sessions container in the Activity bar. To contribute to this container, the 'chatSessionsProvider' API proposal must be enabled."
|
|
254
|
+
)),
|
|
255
|
+
type: 'array',
|
|
256
|
+
items: viewDescriptor,
|
|
257
|
+
default: []
|
|
247
258
|
}
|
|
248
259
|
},
|
|
249
260
|
additionalProperties: {
|
|
250
|
-
description: ( localize(
|
|
261
|
+
description: ( localize(2573, "Contributes views to contributed views container")),
|
|
251
262
|
type: 'array',
|
|
252
263
|
items: viewDescriptor,
|
|
253
264
|
default: []
|
|
@@ -312,7 +323,6 @@ let ViewsExtensionHandler = class ViewsExtensionHandler {
|
|
|
312
323
|
panelOrder = this.registerCustomViewContainers(value, description, panelOrder, existingViewContainers, ViewContainerLocation.Panel);
|
|
313
324
|
break;
|
|
314
325
|
case 'secondarySidebar':
|
|
315
|
-
checkProposedApiEnabled(description, 'contribSecondarySidebar');
|
|
316
326
|
auxiliaryBarOrder = this.registerCustomViewContainers(value, description, auxiliaryBarOrder, existingViewContainers, ViewContainerLocation.AuxiliaryBar);
|
|
317
327
|
break;
|
|
318
328
|
}
|
|
@@ -334,13 +344,13 @@ let ViewsExtensionHandler = class ViewsExtensionHandler {
|
|
|
334
344
|
}
|
|
335
345
|
isValidViewsContainer(viewsContainersDescriptors, collector) {
|
|
336
346
|
if (!Array.isArray(viewsContainersDescriptors)) {
|
|
337
|
-
collector.error(( localize(
|
|
347
|
+
collector.error(( localize(2574, "views containers must be an array")));
|
|
338
348
|
return false;
|
|
339
349
|
}
|
|
340
350
|
for (const descriptor of viewsContainersDescriptors) {
|
|
341
351
|
if (typeof descriptor.id !== 'string' && isFalsyOrWhitespace(descriptor.id)) {
|
|
342
352
|
collector.error(( localize(
|
|
343
|
-
|
|
353
|
+
2575,
|
|
344
354
|
"property `{0}` is mandatory and must be of type `string` with non-empty value. Only alphanumeric characters, '_', and '-' are allowed.",
|
|
345
355
|
'id'
|
|
346
356
|
)));
|
|
@@ -348,23 +358,23 @@ let ViewsExtensionHandler = class ViewsExtensionHandler {
|
|
|
348
358
|
}
|
|
349
359
|
if (!(/^[a-z0-9_-]+$/i.test(descriptor.id))) {
|
|
350
360
|
collector.error(( localize(
|
|
351
|
-
|
|
361
|
+
2575,
|
|
352
362
|
"property `{0}` is mandatory and must be of type `string` with non-empty value. Only alphanumeric characters, '_', and '-' are allowed.",
|
|
353
363
|
'id'
|
|
354
364
|
)));
|
|
355
365
|
return false;
|
|
356
366
|
}
|
|
357
367
|
if (typeof descriptor.title !== 'string') {
|
|
358
|
-
collector.error(( localize(
|
|
368
|
+
collector.error(( localize(2576, "property `{0}` is mandatory and must be of type `string`", 'title')));
|
|
359
369
|
return false;
|
|
360
370
|
}
|
|
361
371
|
if (typeof descriptor.icon !== 'string') {
|
|
362
|
-
collector.error(( localize(
|
|
372
|
+
collector.error(( localize(2576, "property `{0}` is mandatory and must be of type `string`", 'icon')));
|
|
363
373
|
return false;
|
|
364
374
|
}
|
|
365
375
|
if (isFalsyOrWhitespace(descriptor.title)) {
|
|
366
376
|
collector.warn(( localize(
|
|
367
|
-
|
|
377
|
+
2577,
|
|
368
378
|
"property `{0}` is mandatory and must be of type `string` with non-empty value",
|
|
369
379
|
'title'
|
|
370
380
|
)));
|
|
@@ -434,16 +444,24 @@ let ViewsExtensionHandler = class ViewsExtensionHandler {
|
|
|
434
444
|
}
|
|
435
445
|
if (key === 'remote' && !isProposedApiEnabled(extension.description, 'contribViewsRemote')) {
|
|
436
446
|
collector.warn(( localize(
|
|
437
|
-
|
|
447
|
+
2578,
|
|
438
448
|
"View container '{0}' requires 'enabledApiProposals: [\"contribViewsRemote\"]' to be added to 'Remote'.",
|
|
439
449
|
key
|
|
440
450
|
)));
|
|
441
451
|
return;
|
|
442
452
|
}
|
|
453
|
+
if (key === 'agentSessions' && !isProposedApiEnabled(extension.description, 'chatSessionsProvider')) {
|
|
454
|
+
collector.warn(( localize(
|
|
455
|
+
2579,
|
|
456
|
+
"View container '{0}' requires 'enabledApiProposals: [\"chatSessionsProvider\"]'.",
|
|
457
|
+
key
|
|
458
|
+
)));
|
|
459
|
+
return;
|
|
460
|
+
}
|
|
443
461
|
const viewContainer = this.getViewContainer(key);
|
|
444
462
|
if (!viewContainer) {
|
|
445
463
|
collector.warn(( localize(
|
|
446
|
-
|
|
464
|
+
2580,
|
|
447
465
|
"View container '{0}' does not exist and all views registered to it will be added to 'Explorer'.",
|
|
448
466
|
key
|
|
449
467
|
)));
|
|
@@ -453,11 +471,11 @@ let ViewsExtensionHandler = class ViewsExtensionHandler {
|
|
|
453
471
|
for (let index = 0; index < value.length; index++) {
|
|
454
472
|
const item = value[index];
|
|
455
473
|
if (( viewIds.has(item.id))) {
|
|
456
|
-
collector.error(( localize(
|
|
474
|
+
collector.error(( localize(2581, "Cannot register multiple views with same id `{0}`", item.id)));
|
|
457
475
|
continue;
|
|
458
476
|
}
|
|
459
477
|
if (this.viewsRegistry.getView(item.id) !== null) {
|
|
460
|
-
collector.error(( localize(
|
|
478
|
+
collector.error(( localize(2582, "A view with id `{0}` is already registered.", item.id)));
|
|
461
479
|
continue;
|
|
462
480
|
}
|
|
463
481
|
const order = ExtensionIdentifier.equals(extension.description.identifier, container.extensionId)
|
|
@@ -472,7 +490,7 @@ let ViewsExtensionHandler = class ViewsExtensionHandler {
|
|
|
472
490
|
const initialVisibility = this.convertInitialVisibility(item.visibility);
|
|
473
491
|
const type = this.getViewType(item.type);
|
|
474
492
|
if (!type) {
|
|
475
|
-
collector.error(( localize(
|
|
493
|
+
collector.error(( localize(2583, "Unknown view type `{0}`.", item.type)));
|
|
476
494
|
continue;
|
|
477
495
|
}
|
|
478
496
|
let weight = undefined;
|
|
@@ -488,12 +506,16 @@ let ViewsExtensionHandler = class ViewsExtensionHandler {
|
|
|
488
506
|
if (isProposedApiEnabled(extension.description, 'contribAccessibilityHelpContent') && item.accessibilityHelpContent) {
|
|
489
507
|
accessibilityHelpContent = ( new MarkdownString(item.accessibilityHelpContent));
|
|
490
508
|
}
|
|
509
|
+
let when = ContextKeyExpr.deserialize(item.when);
|
|
510
|
+
if (key === 'agentSessions') {
|
|
511
|
+
when = ( ContextKeyExpr.and(when, ChatContextKeyExprs.agentViewWhen));
|
|
512
|
+
}
|
|
491
513
|
const viewDescriptor = {
|
|
492
514
|
type: type,
|
|
493
515
|
ctorDescriptor: type === ViewType.Tree ? ( new SyncDescriptor(TreeViewPane)) : ( new SyncDescriptor(WebviewViewPane)),
|
|
494
516
|
id: item.id,
|
|
495
517
|
name: { value: item.name, original: item.name },
|
|
496
|
-
when
|
|
518
|
+
when,
|
|
497
519
|
containerIcon: icon || viewContainer?.icon,
|
|
498
520
|
containerTitle: item.contextualTitle || (viewContainer && (typeof viewContainer.title === 'string' ? viewContainer.title : viewContainer.title.value)),
|
|
499
521
|
canToggleVisibility: true,
|
|
@@ -554,29 +576,29 @@ let ViewsExtensionHandler = class ViewsExtensionHandler {
|
|
|
554
576
|
}
|
|
555
577
|
isValidViewDescriptors(viewDescriptors, collector) {
|
|
556
578
|
if (!Array.isArray(viewDescriptors)) {
|
|
557
|
-
collector.error(( localize(
|
|
579
|
+
collector.error(( localize(2584, "views must be an array")));
|
|
558
580
|
return false;
|
|
559
581
|
}
|
|
560
582
|
for (const descriptor of viewDescriptors) {
|
|
561
583
|
if (typeof descriptor.id !== 'string') {
|
|
562
|
-
collector.error(( localize(
|
|
584
|
+
collector.error(( localize(2576, "property `{0}` is mandatory and must be of type `string`", 'id')));
|
|
563
585
|
return false;
|
|
564
586
|
}
|
|
565
587
|
if (typeof descriptor.name !== 'string') {
|
|
566
|
-
collector.error(( localize(
|
|
588
|
+
collector.error(( localize(2576, "property `{0}` is mandatory and must be of type `string`", 'name')));
|
|
567
589
|
return false;
|
|
568
590
|
}
|
|
569
591
|
if (descriptor.when && typeof descriptor.when !== 'string') {
|
|
570
|
-
collector.error(( localize(
|
|
592
|
+
collector.error(( localize(2585, "property `{0}` can be omitted or must be of type `string`", 'when')));
|
|
571
593
|
return false;
|
|
572
594
|
}
|
|
573
595
|
if (descriptor.icon && typeof descriptor.icon !== 'string') {
|
|
574
|
-
collector.error(( localize(
|
|
596
|
+
collector.error(( localize(2585, "property `{0}` can be omitted or must be of type `string`", 'icon')));
|
|
575
597
|
return false;
|
|
576
598
|
}
|
|
577
599
|
if (descriptor.contextualTitle && typeof descriptor.contextualTitle !== 'string') {
|
|
578
600
|
collector.error(( localize(
|
|
579
|
-
|
|
601
|
+
2585,
|
|
580
602
|
"property `{0}` can be omitted or must be of type `string`",
|
|
581
603
|
'contextualTitle'
|
|
582
604
|
)));
|
|
@@ -584,7 +606,7 @@ let ViewsExtensionHandler = class ViewsExtensionHandler {
|
|
|
584
606
|
}
|
|
585
607
|
if (descriptor.visibility && !this.convertInitialVisibility(descriptor.visibility)) {
|
|
586
608
|
collector.error(( localize(
|
|
587
|
-
|
|
609
|
+
2586,
|
|
588
610
|
"property `{0}` can be omitted or must be one of {1}",
|
|
589
611
|
'visibility',
|
|
590
612
|
( Object.values(InitialVisibility)).join(', ')
|
|
@@ -600,6 +622,7 @@ let ViewsExtensionHandler = class ViewsExtensionHandler {
|
|
|
600
622
|
case 'debug': return this.viewContainersRegistry.get(VIEWLET_ID$3);
|
|
601
623
|
case 'scm': return this.viewContainersRegistry.get(VIEWLET_ID$2);
|
|
602
624
|
case 'remote': return this.viewContainersRegistry.get(VIEWLET_ID);
|
|
625
|
+
case 'agentSessions': return this.viewContainersRegistry.get(AGENT_SESSIONS_VIEWLET_ID);
|
|
603
626
|
default: return this.viewContainersRegistry.get(`workbench.view.extension.${value}`);
|
|
604
627
|
}
|
|
605
628
|
}
|
|
@@ -636,9 +659,9 @@ class ViewContainersDataRenderer extends Disposable {
|
|
|
636
659
|
return { data: { headers: [], rows: [] }, dispose: () => { } };
|
|
637
660
|
}
|
|
638
661
|
const headers = [
|
|
639
|
-
( localize(
|
|
640
|
-
( localize(
|
|
641
|
-
( localize(
|
|
662
|
+
( localize(2587, "ID")),
|
|
663
|
+
( localize(2588, "Title")),
|
|
664
|
+
( localize(2589, "Where")),
|
|
642
665
|
];
|
|
643
666
|
const rows = ( viewContainers
|
|
644
667
|
.sort((a, b) => a.id.localeCompare(b.id))
|
|
@@ -677,9 +700,9 @@ class ViewsDataRenderer extends Disposable {
|
|
|
677
700
|
return { data: { headers: [], rows: [] }, dispose: () => { } };
|
|
678
701
|
}
|
|
679
702
|
const headers = [
|
|
680
|
-
( localize(
|
|
681
|
-
( localize(
|
|
682
|
-
( localize(
|
|
703
|
+
( localize(2590, "ID")),
|
|
704
|
+
( localize(2591, "Name")),
|
|
705
|
+
( localize(2589, "Where")),
|
|
683
706
|
];
|
|
684
707
|
const rows = ( views
|
|
685
708
|
.sort((a, b) => a.id.localeCompare(b.id))
|
|
@@ -701,7 +724,7 @@ class ViewsDataRenderer extends Disposable {
|
|
|
701
724
|
}
|
|
702
725
|
( Registry.as(Extensions$2.ExtensionFeaturesRegistry)).registerExtensionFeature({
|
|
703
726
|
id: 'viewsContainers',
|
|
704
|
-
label: ( localize(
|
|
727
|
+
label: ( localize(2592, "View Containers")),
|
|
705
728
|
access: {
|
|
706
729
|
canToggle: false
|
|
707
730
|
},
|
|
@@ -709,7 +732,7 @@ class ViewsDataRenderer extends Disposable {
|
|
|
709
732
|
});
|
|
710
733
|
( Registry.as(Extensions$2.ExtensionFeaturesRegistry)).registerExtensionFeature({
|
|
711
734
|
id: 'views',
|
|
712
|
-
label: ( localize(
|
|
735
|
+
label: ( localize(2593, "Views")),
|
|
713
736
|
access: {
|
|
714
737
|
canToggle: false
|
|
715
738
|
},
|
|
@@ -574,7 +574,7 @@ KeybindingsRegistry.registerCommandAndKeybindingRule({
|
|
|
574
574
|
weight: KeybindingWeight.WorkbenchContrib,
|
|
575
575
|
primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KeyK, KeyMod.CtrlCmd | KeyCode.KeyI),
|
|
576
576
|
when: WorkbenchListFocusContextKey,
|
|
577
|
-
handler: async (accessor
|
|
577
|
+
handler: async (accessor) => {
|
|
578
578
|
const listService = accessor.get(IListService);
|
|
579
579
|
const lastFocusedList = listService.lastFocusedList;
|
|
580
580
|
if (!lastFocusedList) {
|
|
@@ -782,12 +782,12 @@ registerAction2(class ToggleStickyScroll extends Action2 {
|
|
|
782
782
|
super({
|
|
783
783
|
id: 'tree.toggleStickyScroll',
|
|
784
784
|
title: {
|
|
785
|
-
...( localize2(
|
|
786
|
-
mnemonicTitle: ( localize(
|
|
785
|
+
...( localize2(2848, "Toggle Tree Sticky Scroll")),
|
|
786
|
+
mnemonicTitle: ( localize(2849, "&&Toggle Tree Sticky Scroll")),
|
|
787
787
|
},
|
|
788
788
|
category: 'View',
|
|
789
789
|
metadata: { description: ( localize(
|
|
790
|
-
|
|
790
|
+
2850,
|
|
791
791
|
"Toggles Sticky Scroll widget at the top of tree structures such as the File Explorer and Debug variables View."
|
|
792
792
|
)) },
|
|
793
793
|
f1: true
|
|
@@ -149,7 +149,7 @@ registerAction2(class extends BaseNavigationAction {
|
|
|
149
149
|
constructor() {
|
|
150
150
|
super({
|
|
151
151
|
id: 'workbench.action.navigateLeft',
|
|
152
|
-
title: ( localize2(
|
|
152
|
+
title: ( localize2(2851, 'Navigate to the View on the Left')),
|
|
153
153
|
category: Categories.View,
|
|
154
154
|
f1: true
|
|
155
155
|
}, Direction.Left);
|
|
@@ -159,7 +159,7 @@ registerAction2(class extends BaseNavigationAction {
|
|
|
159
159
|
constructor() {
|
|
160
160
|
super({
|
|
161
161
|
id: 'workbench.action.navigateRight',
|
|
162
|
-
title: ( localize2(
|
|
162
|
+
title: ( localize2(2852, 'Navigate to the View on the Right')),
|
|
163
163
|
category: Categories.View,
|
|
164
164
|
f1: true
|
|
165
165
|
}, Direction.Right);
|
|
@@ -169,7 +169,7 @@ registerAction2(class extends BaseNavigationAction {
|
|
|
169
169
|
constructor() {
|
|
170
170
|
super({
|
|
171
171
|
id: 'workbench.action.navigateUp',
|
|
172
|
-
title: ( localize2(
|
|
172
|
+
title: ( localize2(2853, 'Navigate to the View Above')),
|
|
173
173
|
category: Categories.View,
|
|
174
174
|
f1: true
|
|
175
175
|
}, Direction.Up);
|
|
@@ -179,7 +179,7 @@ registerAction2(class extends BaseNavigationAction {
|
|
|
179
179
|
constructor() {
|
|
180
180
|
super({
|
|
181
181
|
id: 'workbench.action.navigateDown',
|
|
182
|
-
title: ( localize2(
|
|
182
|
+
title: ( localize2(2854, 'Navigate to the View Below')),
|
|
183
183
|
category: Categories.View,
|
|
184
184
|
f1: true
|
|
185
185
|
}, Direction.Down);
|
|
@@ -264,7 +264,7 @@ registerAction2(class extends BaseFocusAction {
|
|
|
264
264
|
constructor() {
|
|
265
265
|
super({
|
|
266
266
|
id: 'workbench.action.focusNextPart',
|
|
267
|
-
title: ( localize2(
|
|
267
|
+
title: ( localize2(2855, 'Focus Next Part')),
|
|
268
268
|
category: Categories.View,
|
|
269
269
|
f1: true,
|
|
270
270
|
keybinding: {
|
|
@@ -278,7 +278,7 @@ registerAction2(class extends BaseFocusAction {
|
|
|
278
278
|
constructor() {
|
|
279
279
|
super({
|
|
280
280
|
id: 'workbench.action.focusPreviousPart',
|
|
281
|
-
title: ( localize2(
|
|
281
|
+
title: ( localize2(2856, 'Focus Previous Part')),
|
|
282
282
|
category: Categories.View,
|
|
283
283
|
f1: true,
|
|
284
284
|
keybinding: {
|