@pstdio/sdk 0.38.0 → 0.40.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/README.md +5 -5
- package/dist/api/index.js +64 -8
- package/dist/api.d.ts +4 -4
- package/dist/client/index.js +179 -83
- package/dist/client.d.ts +2 -2
- package/dist/data.d.ts +1 -1
- package/dist/extensions/index.js +5 -8
- package/dist/extensions.d.ts +2 -2
- package/dist/hooks.d.ts +4 -4
- package/dist/{index-C-BhIXyz.d.ts → index-1twOhV2h.d.ts} +178 -7
- package/dist/{index-CPqTwJbg.d.ts → index-BU8PNmuX.d.ts} +1 -1
- package/dist/{index-BCK94Mon.d.ts → index-Cbt2YiR-.d.ts} +2328 -1933
- package/dist/resources/index.js +64 -8
- package/dist/resources.d.ts +2 -2
- package/dist/sessions-46B897Gi.d.ts +2 -0
- package/dist/skills-46B897Gi.d.ts +2 -0
- package/dist/testing.d.ts +1 -1
- package/package.json +1 -1
- package/dist/sessions-DIT92e3v.d.ts +0 -2
- package/dist/skills-DIT92e3v.d.ts +0 -2
|
@@ -17,8 +17,8 @@ declare const listActivityResponseSchema: z.ZodObject<{
|
|
|
17
17
|
source_extension_id: z.ZodNullable<z.ZodString>;
|
|
18
18
|
event_type: z.ZodString;
|
|
19
19
|
actor_type: z.ZodEnum<{
|
|
20
|
-
agent: "agent";
|
|
21
20
|
user: "user";
|
|
21
|
+
agent: "agent";
|
|
22
22
|
system: "system";
|
|
23
23
|
}>;
|
|
24
24
|
actor_id: z.ZodNullable<z.ZodString>;
|
|
@@ -139,8 +139,12 @@ type AgentSkillsLayout = z.infer<typeof agentSkillsLayoutSchema>;
|
|
|
139
139
|
declare const harnessLocalId: (id: string) => string;
|
|
140
140
|
//#endregion
|
|
141
141
|
//#region ../pstdio-api-contracts/src/extension-kernel/api-versions.d.ts
|
|
142
|
-
/**
|
|
143
|
-
|
|
142
|
+
/**
|
|
143
|
+
* Only caret terms are accepted because each one stops below the next breaking version, so a
|
|
144
|
+
* declaration can never claim support for a breaking API that did not exist when it was written.
|
|
145
|
+
* Returns the minimum API version of each term.
|
|
146
|
+
*/
|
|
147
|
+
declare const parseExtensionApiDeclaration: (declaration: string) => string[] | null;
|
|
144
148
|
declare const supportsExtensionApiVersion: (declaration: string, hostVersion: string) => boolean;
|
|
145
149
|
//#endregion
|
|
146
150
|
//#region ../pstdio-api-contracts/src/extension-kernel/l10n.d.ts
|
|
@@ -155,6 +159,54 @@ declare const l10n: (key: string, defaultValue?: string) => {
|
|
|
155
159
|
};
|
|
156
160
|
declare const isLocalizedString: (value: unknown) => value is LocalizedString;
|
|
157
161
|
//#endregion
|
|
162
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/workbench-targets.d.ts
|
|
163
|
+
declare const workbenchMenuTargets: readonly ["workbench.nav.actions", "workbench.nav.overflow"];
|
|
164
|
+
declare const workbenchTreeTargets: readonly ["workbench.left.tree", "workbench.main.left.tree", "workbench.main.right.tree"];
|
|
165
|
+
declare const workbenchViewTargets: readonly ["workbench.main", "workbench.main.left", "workbench.main.right", "workbench.secondary"];
|
|
166
|
+
declare const workbenchSettingsTargets: readonly ["workbench.settings"];
|
|
167
|
+
type WorkbenchMenuTarget = (typeof workbenchMenuTargets)[number];
|
|
168
|
+
type WorkbenchTreeTarget = (typeof workbenchTreeTargets)[number];
|
|
169
|
+
type WorkbenchViewTarget = (typeof workbenchViewTargets)[number];
|
|
170
|
+
type WorkbenchSettingsTarget = (typeof workbenchSettingsTargets)[number];
|
|
171
|
+
type WorkbenchAttachmentTarget = WorkbenchMenuTarget | WorkbenchTreeTarget | WorkbenchViewTarget | WorkbenchSettingsTarget;
|
|
172
|
+
//#endregion
|
|
173
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/contribution-identity.d.ts
|
|
174
|
+
type ContributionKind = "activity-item" | "artifact-mount" | "command" | "command-palette-resource" | "connection" | "file-icon-theme" | "harness" | "hook" | "keybinding" | "middleware" | "mode" | "navigation-item" | "navigation-tree" | "page" | "placement" | "resource-hierarchy-provider" | "resource-kind" | "schedule" | "settings-panel" | "settings-section" | "skill" | "status" | "status-bar-item" | "template" | "template-type" | "theme" | "view" | "view-menu" | "workspace-type";
|
|
175
|
+
interface ContributionRef<Kind extends ContributionKind> {
|
|
176
|
+
readonly extensionId?: string;
|
|
177
|
+
readonly kind: Kind;
|
|
178
|
+
readonly id: string;
|
|
179
|
+
}
|
|
180
|
+
interface ContributionDefinition<Kind extends ContributionKind> {
|
|
181
|
+
readonly id: string;
|
|
182
|
+
readonly ref: ContributionRef<Kind>;
|
|
183
|
+
}
|
|
184
|
+
type ContributionInput<Kind extends ContributionKind> = Omit<ContributionDefinition<Kind>, "ref">;
|
|
185
|
+
type ConnectionRef = ContributionRef<"connection">;
|
|
186
|
+
type ThemeRef = ContributionRef<"theme">;
|
|
187
|
+
type ModeRef = ContributionRef<"mode">;
|
|
188
|
+
type PageRef = ContributionRef<"page">;
|
|
189
|
+
type PlacementRef = ContributionRef<"placement">;
|
|
190
|
+
type ResourceKindRef = ContributionRef<"resource-kind">;
|
|
191
|
+
type SettingsSectionRef = ContributionRef<"settings-section">;
|
|
192
|
+
interface SettingsSlotRef {
|
|
193
|
+
readonly id: string;
|
|
194
|
+
}
|
|
195
|
+
interface StatusBarSlotRef {
|
|
196
|
+
readonly id: string;
|
|
197
|
+
}
|
|
198
|
+
type StatusRef = ContributionRef<"status">;
|
|
199
|
+
type ViewRef = ContributionRef<"view">;
|
|
200
|
+
//#endregion
|
|
201
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/json.d.ts
|
|
202
|
+
type JsonPrimitive = string | number | boolean | null;
|
|
203
|
+
type JsonValue = JsonPrimitive | JsonValue[] | JsonObject;
|
|
204
|
+
type JsonObject = {
|
|
205
|
+
[key: string]: JsonValue;
|
|
206
|
+
};
|
|
207
|
+
type MaybePromise<T> = T | Promise<T>;
|
|
208
|
+
type Struct = object;
|
|
209
|
+
//#endregion
|
|
158
210
|
//#region ../pstdio-api-contracts/src/extensions.terminal.d.ts
|
|
159
211
|
interface TerminalSessionRequest$1 {
|
|
160
212
|
/** Command + args to run; defaults to the user's login shell when omitted. */
|
|
@@ -226,78 +278,6 @@ type TerminalSessionResult$1 = {
|
|
|
226
278
|
accepted: true;
|
|
227
279
|
};
|
|
228
280
|
//#endregion
|
|
229
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/workbench-targets.d.ts
|
|
230
|
-
declare const workbenchMenuTargets: readonly ["workbench.nav.actions", "workbench.nav.overflow"];
|
|
231
|
-
declare const workbenchTreeTargets: readonly ["workbench.left.tree", "workbench.main.left.tree", "workbench.main.right.tree"];
|
|
232
|
-
declare const workbenchViewTargets: readonly ["workbench.main", "workbench.main.left", "workbench.main.right", "workbench.secondary"];
|
|
233
|
-
declare const workbenchSettingsTargets: readonly ["workbench.settings"];
|
|
234
|
-
type WorkbenchMenuTarget = (typeof workbenchMenuTargets)[number];
|
|
235
|
-
type WorkbenchTreeTarget = (typeof workbenchTreeTargets)[number];
|
|
236
|
-
type WorkbenchViewTarget = (typeof workbenchViewTargets)[number];
|
|
237
|
-
type WorkbenchSettingsTarget = (typeof workbenchSettingsTargets)[number];
|
|
238
|
-
type WorkbenchAttachmentTarget = WorkbenchMenuTarget | WorkbenchTreeTarget | WorkbenchViewTarget | WorkbenchSettingsTarget;
|
|
239
|
-
//#endregion
|
|
240
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/contribution-identity.d.ts
|
|
241
|
-
type ContributionKind = "activity-item" | "artifact-mount" | "command" | "command-palette-resource" | "connection" | "file-icon-theme" | "harness" | "hook" | "keybinding" | "middleware" | "mode" | "navigation-item" | "navigation-tree" | "page" | "placement" | "resource-hierarchy-provider" | "resource-kind" | "schedule" | "settings-panel" | "settings-section" | "skill" | "status" | "status-bar-item" | "template" | "template-type" | "theme" | "view" | "view-menu" | "workspace-type";
|
|
242
|
-
interface ContributionRef<Kind extends ContributionKind> {
|
|
243
|
-
readonly extensionId?: string;
|
|
244
|
-
readonly kind: Kind;
|
|
245
|
-
readonly id: string;
|
|
246
|
-
}
|
|
247
|
-
interface ContributionDefinition<Kind extends ContributionKind> {
|
|
248
|
-
readonly id: string;
|
|
249
|
-
readonly ref: ContributionRef<Kind>;
|
|
250
|
-
}
|
|
251
|
-
type ContributionInput<Kind extends ContributionKind> = Omit<ContributionDefinition<Kind>, "ref">;
|
|
252
|
-
type ConnectionRef = ContributionRef<"connection">;
|
|
253
|
-
type ThemeRef = ContributionRef<"theme">;
|
|
254
|
-
type ModeRef = ContributionRef<"mode">;
|
|
255
|
-
type PageRef = ContributionRef<"page">;
|
|
256
|
-
type PlacementRef = ContributionRef<"placement">;
|
|
257
|
-
type ResourceKindRef = ContributionRef<"resource-kind">;
|
|
258
|
-
type SettingsSectionRef = ContributionRef<"settings-section">;
|
|
259
|
-
interface SettingsSlotRef {
|
|
260
|
-
readonly id: string;
|
|
261
|
-
}
|
|
262
|
-
interface StatusBarSlotRef {
|
|
263
|
-
readonly id: string;
|
|
264
|
-
}
|
|
265
|
-
type StatusRef = ContributionRef<"status">;
|
|
266
|
-
type ViewRef = ContributionRef<"view">;
|
|
267
|
-
//#endregion
|
|
268
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/json.d.ts
|
|
269
|
-
type JsonPrimitive = string | number | boolean | null;
|
|
270
|
-
type JsonValue = JsonPrimitive | JsonValue[] | JsonObject;
|
|
271
|
-
type JsonObject = {
|
|
272
|
-
[key: string]: JsonValue;
|
|
273
|
-
};
|
|
274
|
-
type MaybePromise<T> = T | Promise<T>;
|
|
275
|
-
type Struct = object;
|
|
276
|
-
//#endregion
|
|
277
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/events.d.ts
|
|
278
|
-
interface EventRef<TPayload extends Struct = Struct> {
|
|
279
|
-
readonly extensionId?: string;
|
|
280
|
-
readonly kind: "event";
|
|
281
|
-
readonly id: string;
|
|
282
|
-
payload?: TPayload;
|
|
283
|
-
}
|
|
284
|
-
interface EventDeliveryResult {
|
|
285
|
-
delivered: number;
|
|
286
|
-
diagnostics?: CommandDiagnostic[];
|
|
287
|
-
}
|
|
288
|
-
//#endregion
|
|
289
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/renderer-base.d.ts
|
|
290
|
-
/** A raw cross-extension id must be namespaced. Local events use an EventRef. */
|
|
291
|
-
type RendererEventReference = EventRef | `${string}.${string}`;
|
|
292
|
-
interface RendererContributionBase {
|
|
293
|
-
title: Localizable<string>;
|
|
294
|
-
icon?: string;
|
|
295
|
-
resourceKind?: string;
|
|
296
|
-
refreshEvents?: readonly RendererEventReference[];
|
|
297
|
-
emptyTitle?: Localizable<string>;
|
|
298
|
-
emptyDescription?: Localizable<string>;
|
|
299
|
-
}
|
|
300
|
-
//#endregion
|
|
301
281
|
//#region ../pstdio-api-contracts/src/extension-kernel/types/resources.d.ts
|
|
302
282
|
type ResourceRole = "primary" | "context" | "source" | "result";
|
|
303
283
|
interface ResourceRef {
|
|
@@ -347,1467 +327,89 @@ interface PackageAssetDescriptor {
|
|
|
347
327
|
baseUrl: string;
|
|
348
328
|
}
|
|
349
329
|
//#endregion
|
|
350
|
-
//#region ../pstdio-api-contracts/src/
|
|
351
|
-
type
|
|
352
|
-
|
|
353
|
-
|
|
330
|
+
//#region ../pstdio-api-contracts/src/notifications/types.d.ts
|
|
331
|
+
type NotificationKind = "needs_review" | "ready_to_merge" | "blocked" | "approval_required" | "failed" | "info";
|
|
332
|
+
type NotificationStatus = "open" | "read" | "snoozed" | "done" | "dismissed" | "expired";
|
|
333
|
+
type NotificationPriority = "low" | "normal" | "high" | "urgent";
|
|
334
|
+
type NotificationActorType = "user" | "agent" | "system";
|
|
335
|
+
type NotificationOrigin = "core" | "extension" | "agent";
|
|
336
|
+
type NotificationAction = {
|
|
354
337
|
id: string;
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
}
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
338
|
+
label: string;
|
|
339
|
+
kind: "navigate";
|
|
340
|
+
target: NavigationTarget;
|
|
341
|
+
primary?: boolean;
|
|
342
|
+
} | {
|
|
343
|
+
id: string;
|
|
344
|
+
label: string;
|
|
345
|
+
kind: "command";
|
|
346
|
+
command: string;
|
|
347
|
+
params?: JsonObject;
|
|
348
|
+
primary?: boolean;
|
|
349
|
+
destructive?: boolean;
|
|
350
|
+
} | {
|
|
351
|
+
id: string;
|
|
352
|
+
label: string;
|
|
353
|
+
kind: "url";
|
|
354
|
+
href: string;
|
|
355
|
+
primary?: boolean;
|
|
356
|
+
};
|
|
357
|
+
interface Notification {
|
|
358
|
+
id: string;
|
|
359
|
+
projectId: string;
|
|
360
|
+
title: string;
|
|
361
|
+
body?: string | null;
|
|
362
|
+
kind: NotificationKind;
|
|
363
|
+
status: NotificationStatus;
|
|
364
|
+
priority: NotificationPriority;
|
|
365
|
+
source: CommandSource;
|
|
366
|
+
origin: NotificationOrigin;
|
|
367
|
+
sourceExtensionId?: string | null;
|
|
368
|
+
actorType?: NotificationActorType | null;
|
|
369
|
+
actorId?: string | null;
|
|
370
|
+
target?: ResourceRef | null;
|
|
371
|
+
related: ResourceRef[];
|
|
372
|
+
actions: NotificationAction[];
|
|
373
|
+
dedupeKey?: string | null;
|
|
374
|
+
metadata?: JsonObject | null;
|
|
375
|
+
createdAt: string;
|
|
376
|
+
updatedAt: string;
|
|
377
|
+
readAt?: string | null;
|
|
378
|
+
resolvedAt?: string | null;
|
|
379
|
+
snoozedUntil?: string | null;
|
|
380
|
+
expiresAt?: string | null;
|
|
382
381
|
}
|
|
383
|
-
interface
|
|
384
|
-
|
|
385
|
-
|
|
382
|
+
interface CreateNotificationInput {
|
|
383
|
+
projectId: string;
|
|
384
|
+
title: string;
|
|
385
|
+
body?: string;
|
|
386
|
+
kind: NotificationKind;
|
|
387
|
+
priority?: NotificationPriority;
|
|
388
|
+
target?: ResourceRef;
|
|
389
|
+
related?: ResourceRef[];
|
|
390
|
+
actions?: NotificationAction[];
|
|
391
|
+
dedupeKey?: string;
|
|
392
|
+
expiresAt?: string;
|
|
393
|
+
snoozedUntil?: string;
|
|
394
|
+
metadata?: JsonObject;
|
|
386
395
|
}
|
|
387
|
-
interface
|
|
388
|
-
|
|
389
|
-
|
|
396
|
+
interface UpdateNotificationInput {
|
|
397
|
+
priority?: NotificationPriority;
|
|
398
|
+
snoozedUntil?: string | null;
|
|
399
|
+
metadata?: JsonObject;
|
|
390
400
|
}
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
401
|
+
interface ListNotificationsQuery {
|
|
402
|
+
status?: NotificationStatus | NotificationStatus[];
|
|
403
|
+
priority?: NotificationPriority | NotificationPriority[];
|
|
404
|
+
sourceExtensionId?: string;
|
|
405
|
+
resourceType?: string;
|
|
406
|
+
resourceId?: string;
|
|
407
|
+
cursor?: string;
|
|
408
|
+
limit?: number;
|
|
395
409
|
}
|
|
396
|
-
interface
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
readonly add?: NavigationTarget;
|
|
400
|
-
}
|
|
401
|
-
//#endregion
|
|
402
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/slots.d.ts
|
|
403
|
-
type UiSlotKind = "menu" | "panel" | "settings" | "renderer" | "kanbanRenderer" | "dataTableRenderer";
|
|
404
|
-
interface SlotOptions<TKind extends UiSlotKind = UiSlotKind> {
|
|
405
|
-
kind: TKind;
|
|
406
|
-
label?: string;
|
|
407
|
-
description?: string;
|
|
408
|
-
metadata?: JsonObject;
|
|
409
|
-
}
|
|
410
|
-
interface SlotRef<TContext extends Struct = Struct, TKind extends UiSlotKind = UiSlotKind> {
|
|
411
|
-
id: string;
|
|
412
|
-
kind: TKind;
|
|
413
|
-
label?: string;
|
|
414
|
-
description?: string;
|
|
415
|
-
metadata?: JsonObject;
|
|
416
|
-
/** Phantom field used to constrain compatible contributions; never populated at runtime. */
|
|
417
|
-
context?: TContext;
|
|
418
|
-
}
|
|
419
|
-
interface SlotInvocationContext<TContext extends Struct = Struct> {
|
|
420
|
-
id: string;
|
|
421
|
-
kind: UiSlotKind;
|
|
422
|
-
context: TContext;
|
|
423
|
-
}
|
|
424
|
-
//#endregion
|
|
425
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/webview-capabilities.d.ts
|
|
426
|
-
declare const WEBVIEW_HOST_CAPABILITY_VERSION = 1;
|
|
427
|
-
declare const WEBVIEW_DECLARABLE_CAPABILITIES: readonly ["clipboard.write", "commands.execute", "navigation.open", "placement.close", "notification.show", "notification.action", "notification.resolve", "notification.dismiss", "preferences.get", "preferences.set", "extension.settings.all", "extension.settings.get", "extension.settings.set", "extension.settings.delete", "terminal.session", "files.upload", "files.list", "files.delete"];
|
|
428
|
-
declare const WEBVIEW_SCOPED_DECLARABLE_CAPABILITIES: readonly ["artifacts.read"];
|
|
429
|
-
declare const ALWAYS_AVAILABLE_WEBVIEW_CAPABILITIES: readonly ["host.dispatchKeyboardEvent"];
|
|
430
|
-
declare const WEBVIEW_HOST_CAPABILITIES: readonly [...("commands.execute" | "navigation.open" | "placement.close" | "notification.show" | "notification.action" | "notification.resolve" | "notification.dismiss" | "preferences.get" | "preferences.set" | "extension.settings.all" | "extension.settings.get" | "extension.settings.set" | "extension.settings.delete" | "terminal.session" | "files.upload" | "files.list" | "files.delete")[], "artifacts.read", "host.dispatchKeyboardEvent"];
|
|
431
|
-
type WebviewHostCapability = (typeof WEBVIEW_HOST_CAPABILITIES)[number];
|
|
432
|
-
type WebviewDeclarableCapability = (typeof WEBVIEW_DECLARABLE_CAPABILITIES)[number];
|
|
433
|
-
type WebviewScopedDeclarableCapability = (typeof WEBVIEW_SCOPED_DECLARABLE_CAPABILITIES)[number];
|
|
434
|
-
type WebviewCapabilityDeclaration = WebviewDeclarableCapability | `${WebviewDeclarableCapability}@${typeof WEBVIEW_HOST_CAPABILITY_VERSION}` | `${WebviewScopedDeclarableCapability}:${string}`;
|
|
435
|
-
interface WebviewCommandsExecuteParams {
|
|
436
|
-
commandId: string;
|
|
437
|
-
params?: JsonObject;
|
|
438
|
-
workspaceId?: string;
|
|
439
|
-
resource?: ResourceRef;
|
|
440
|
-
metadata?: JsonObject;
|
|
441
|
-
}
|
|
442
|
-
interface WebviewNavigationOpenParams {
|
|
443
|
-
target: NavigationTarget;
|
|
444
|
-
}
|
|
445
|
-
interface WebviewNotificationShowParams {
|
|
446
|
-
level: "info" | "success" | "warning" | "error";
|
|
447
|
-
title: string;
|
|
448
|
-
message?: string;
|
|
449
|
-
}
|
|
450
|
-
type WebviewNotificationActionParams = Omit<CreateNotificationInput, "projectId">;
|
|
451
|
-
interface WebviewNotificationResolveParams {
|
|
452
|
-
id?: string;
|
|
453
|
-
dedupeKey?: string;
|
|
454
|
-
status?: Extract<NotificationStatus, "done" | "dismissed" | "expired">;
|
|
455
|
-
}
|
|
456
|
-
type WebviewNotificationDismissParams = Pick<WebviewNotificationResolveParams, "id" | "dedupeKey">;
|
|
457
|
-
interface WebviewPreferencesGetParams {
|
|
458
|
-
name: string;
|
|
459
|
-
scope?: {
|
|
460
|
-
scope: "default" | "user" | "project" | "workspace" | "extension" | "session";
|
|
461
|
-
scopeId?: string;
|
|
462
|
-
};
|
|
463
|
-
}
|
|
464
|
-
interface WebviewPreferencesSetParams extends WebviewPreferencesGetParams {
|
|
465
|
-
value: boolean | number | string | string[] | number[] | boolean[] | Record<string, unknown>;
|
|
466
|
-
}
|
|
467
|
-
interface WebviewExtensionSettingKeyParams {
|
|
468
|
-
key: string;
|
|
469
|
-
}
|
|
470
|
-
interface WebviewExtensionSettingSetParams extends WebviewExtensionSettingKeyParams {
|
|
471
|
-
value: unknown;
|
|
472
|
-
}
|
|
473
|
-
type WebviewFileScope = {
|
|
474
|
-
type: "project";
|
|
475
|
-
} | {
|
|
476
|
-
type: "resource";
|
|
477
|
-
id: string;
|
|
478
|
-
} | {
|
|
479
|
-
type: string;
|
|
480
|
-
id?: string;
|
|
481
|
-
};
|
|
482
|
-
interface WebviewFilesUploadParams {
|
|
483
|
-
name: string;
|
|
484
|
-
data: Uint8Array | ArrayBuffer;
|
|
485
|
-
mimeType?: string;
|
|
486
|
-
scope?: WebviewFileScope;
|
|
487
|
-
}
|
|
488
|
-
interface WebviewFilesListParams {
|
|
489
|
-
scope?: WebviewFileScope;
|
|
490
|
-
}
|
|
491
|
-
interface WebviewFilesDeleteParams {
|
|
492
|
-
id: string;
|
|
493
|
-
}
|
|
494
|
-
type WebviewArtifactsReadParams = {
|
|
495
|
-
op: "list";
|
|
496
|
-
mount: string;
|
|
497
|
-
prefix?: string;
|
|
498
|
-
} | {
|
|
499
|
-
op: "readText";
|
|
500
|
-
mount: string;
|
|
501
|
-
path: string;
|
|
502
|
-
} | {
|
|
503
|
-
op: "imageUrl";
|
|
504
|
-
mount: string;
|
|
505
|
-
path: string;
|
|
506
|
-
};
|
|
507
|
-
interface WebviewArtifactFile {
|
|
508
|
-
path: string;
|
|
509
|
-
size: number;
|
|
510
|
-
mediaType: string;
|
|
511
|
-
}
|
|
512
|
-
interface WebviewKeyboardEventParams {
|
|
513
|
-
key?: string;
|
|
514
|
-
code?: string;
|
|
515
|
-
ctrlKey?: boolean;
|
|
516
|
-
metaKey?: boolean;
|
|
517
|
-
altKey?: boolean;
|
|
518
|
-
shiftKey?: boolean;
|
|
519
|
-
repeat?: boolean;
|
|
520
|
-
}
|
|
521
|
-
interface WebviewHostCapabilityParams {
|
|
522
|
-
"commands.execute": WebviewCommandsExecuteParams;
|
|
523
|
-
"navigation.open": WebviewNavigationOpenParams;
|
|
524
|
-
"placement.close": Record<string, never>;
|
|
525
|
-
"notification.show": WebviewNotificationShowParams;
|
|
526
|
-
"notification.action": WebviewNotificationActionParams;
|
|
527
|
-
"notification.resolve": WebviewNotificationResolveParams;
|
|
528
|
-
"notification.dismiss": WebviewNotificationDismissParams;
|
|
529
|
-
"preferences.get": WebviewPreferencesGetParams;
|
|
530
|
-
"preferences.set": WebviewPreferencesSetParams;
|
|
531
|
-
"extension.settings.all": Record<string, never>;
|
|
532
|
-
"extension.settings.get": WebviewExtensionSettingKeyParams;
|
|
533
|
-
"extension.settings.set": WebviewExtensionSettingSetParams;
|
|
534
|
-
"extension.settings.delete": WebviewExtensionSettingKeyParams;
|
|
535
|
-
"terminal.session": TerminalSessionOperation$1;
|
|
536
|
-
"files.upload": WebviewFilesUploadParams;
|
|
537
|
-
"files.list": WebviewFilesListParams;
|
|
538
|
-
"files.delete": WebviewFilesDeleteParams;
|
|
539
|
-
"artifacts.read": WebviewArtifactsReadParams;
|
|
540
|
-
"host.dispatchKeyboardEvent": WebviewKeyboardEventParams;
|
|
541
|
-
}
|
|
542
|
-
interface WebviewHostCapabilityResults {
|
|
543
|
-
"commands.execute": {
|
|
544
|
-
outcome: CommandOutcome;
|
|
545
|
-
};
|
|
546
|
-
"navigation.open": void;
|
|
547
|
-
"placement.close": void;
|
|
548
|
-
"notification.show": void;
|
|
549
|
-
"notification.action": Notification;
|
|
550
|
-
"notification.resolve": Notification | {
|
|
551
|
-
resolved: number;
|
|
552
|
-
notifications: Notification[];
|
|
553
|
-
};
|
|
554
|
-
"notification.dismiss": Notification | {
|
|
555
|
-
resolved: number;
|
|
556
|
-
notifications: Notification[];
|
|
557
|
-
};
|
|
558
|
-
"preferences.get": WebviewPreferencesSetParams["value"] | undefined;
|
|
559
|
-
"preferences.set": {
|
|
560
|
-
name: string;
|
|
561
|
-
value: WebviewPreferencesSetParams["value"];
|
|
562
|
-
};
|
|
563
|
-
"extension.settings.all": Record<string, unknown>;
|
|
564
|
-
"extension.settings.get": unknown;
|
|
565
|
-
"extension.settings.set": void;
|
|
566
|
-
"extension.settings.delete": void;
|
|
567
|
-
"terminal.session": TerminalSessionResult$1;
|
|
568
|
-
"files.upload": ExtensionBlobRef;
|
|
569
|
-
"files.list": {
|
|
570
|
-
files: ExtensionBlobRef[];
|
|
571
|
-
};
|
|
572
|
-
"files.delete": void;
|
|
573
|
-
"artifacts.read": WebviewArtifactFile[] | string;
|
|
574
|
-
"host.dispatchKeyboardEvent": void;
|
|
575
|
-
}
|
|
576
|
-
type WebviewHostCapabilityResult<Capability extends WebviewHostCapability, Params extends WebviewHostCapabilityParams[Capability] = WebviewHostCapabilityParams[Capability]> = Capability extends "artifacts.read" ? Params extends {
|
|
577
|
-
op: "list";
|
|
578
|
-
} ? WebviewArtifactFile[] : Params extends {
|
|
579
|
-
op: "readText" | "imageUrl";
|
|
580
|
-
} ? string : WebviewHostCapabilityResults[Capability] : Capability extends "terminal.session" ? Params extends {
|
|
581
|
-
operation: "open";
|
|
582
|
-
} ? Extract<TerminalSessionResult$1, {
|
|
583
|
-
operation: "open";
|
|
584
|
-
}> : Params extends {
|
|
585
|
-
operation: "write" | "resize" | "kill" | "subscribe";
|
|
586
|
-
} ? Exclude<TerminalSessionResult$1, {
|
|
587
|
-
operation: "open";
|
|
588
|
-
}> : TerminalSessionResult$1 : WebviewHostCapabilityResults[Capability];
|
|
589
|
-
//#endregion
|
|
590
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/params.d.ts
|
|
591
|
-
type ParamType = "text" | "longtext" | "markdown" | "number" | "boolean" | "select" | "multi-select" | "files" | "harness" | "template" | "resource" | "workspace" | "json" | "list";
|
|
592
|
-
type ParamRequired<TRequired extends boolean | undefined> = TRequired extends true ? {
|
|
593
|
-
required: true;
|
|
594
|
-
} : TRequired extends false ? {
|
|
595
|
-
required: false;
|
|
596
|
-
} : {
|
|
597
|
-
required?: boolean;
|
|
598
|
-
};
|
|
599
|
-
type ParamBase<TValue, TRequired extends boolean | undefined = boolean | undefined> = {
|
|
600
|
-
label?: Localizable<string>;
|
|
601
|
-
description?: Localizable<string>;
|
|
602
|
-
defaultValue?: TValue;
|
|
603
|
-
metadata?: JsonObject;
|
|
604
|
-
resolvedFrom?: "resource";
|
|
605
|
-
} & ParamRequired<TRequired>;
|
|
606
|
-
type TextParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string, TRequired> & {
|
|
607
|
-
type: "text";
|
|
608
|
-
};
|
|
609
|
-
type LongTextParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string, TRequired> & {
|
|
610
|
-
type: "longtext";
|
|
611
|
-
};
|
|
612
|
-
type MarkdownParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string, TRequired> & {
|
|
613
|
-
type: "markdown";
|
|
614
|
-
placeholder?: Localizable<string>;
|
|
615
|
-
};
|
|
616
|
-
type NumberParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<number, TRequired> & {
|
|
617
|
-
type: "number";
|
|
618
|
-
};
|
|
619
|
-
type FilesParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string[], TRequired> & {
|
|
620
|
-
type: "files";
|
|
621
|
-
multiple?: boolean;
|
|
622
|
-
/** Passed through to the picker, e.g. "image/*". */
|
|
623
|
-
accept?: string;
|
|
624
|
-
};
|
|
625
|
-
type BooleanParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<boolean, TRequired> & {
|
|
626
|
-
type: "boolean";
|
|
627
|
-
};
|
|
628
|
-
type ParamOption = {
|
|
629
|
-
label: string;
|
|
630
|
-
value: string;
|
|
631
|
-
icon?: string;
|
|
632
|
-
};
|
|
633
|
-
type SelectParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string, TRequired> & {
|
|
634
|
-
type: "select";
|
|
635
|
-
options: ParamOption[];
|
|
636
|
-
};
|
|
637
|
-
type MultiSelectParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string[], TRequired> & {
|
|
638
|
-
type: "multi-select";
|
|
639
|
-
options: ParamOption[];
|
|
640
|
-
};
|
|
641
|
-
type HarnessParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<{
|
|
642
|
-
harnessId: string;
|
|
643
|
-
model?: string;
|
|
644
|
-
params?: Record<string, string | boolean>;
|
|
645
|
-
}, TRequired> & {
|
|
646
|
-
type: "harness";
|
|
647
|
-
};
|
|
648
|
-
type TemplateParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string, TRequired> & {
|
|
649
|
-
type: "template";
|
|
650
|
-
templateType: string;
|
|
651
|
-
};
|
|
652
|
-
type ResourceParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<ResourceRef, TRequired> & {
|
|
653
|
-
type: "resource";
|
|
654
|
-
resourceType: string;
|
|
655
|
-
};
|
|
656
|
-
type WorkspaceParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<{
|
|
657
|
-
providerId: string;
|
|
658
|
-
params?: JsonObject;
|
|
659
|
-
}, TRequired> & {
|
|
660
|
-
type: "workspace";
|
|
661
|
-
/** Provider ids the user may choose from. Omit to offer every provider. */
|
|
662
|
-
providers?: string[];
|
|
663
|
-
};
|
|
664
|
-
type JsonParam<T = unknown, TRequired extends boolean | undefined = boolean | undefined> = ParamBase<T, TRequired> & {
|
|
665
|
-
type: "json";
|
|
666
|
-
};
|
|
667
|
-
type ListParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string[], TRequired> & {
|
|
668
|
-
type: "list";
|
|
669
|
-
};
|
|
670
|
-
type ParamDescriptor<TValue = unknown, TRequired extends boolean | undefined = boolean | undefined> = TextParam<TRequired> | LongTextParam<TRequired> | MarkdownParam<TRequired> | NumberParam<TRequired> | BooleanParam<TRequired> | SelectParam<TRequired> | MultiSelectParam<TRequired> | FilesParam<TRequired> | HarnessParam<TRequired> | TemplateParam<TRequired> | ResourceParam<TRequired> | WorkspaceParam<TRequired> | JsonParam<TValue, TRequired> | ListParam<TRequired>;
|
|
671
|
-
type ParamObjectSchema = Record<string, ParamDescriptor>;
|
|
672
|
-
type ParamValue<TDescriptor extends ParamDescriptor> = TDescriptor extends ParamDescriptor<infer V> ? V : never;
|
|
673
|
-
type RequiredParamKeys<TSchema extends ParamObjectSchema> = { [K in keyof TSchema]: TSchema[K] extends {
|
|
674
|
-
required: true;
|
|
675
|
-
} ? K : never; }[keyof TSchema];
|
|
676
|
-
type OptionalParamKeys<TSchema extends ParamObjectSchema> = Exclude<keyof TSchema, RequiredParamKeys<TSchema>>;
|
|
677
|
-
type ParamsOf<TSchema extends ParamObjectSchema> = { [K in RequiredParamKeys<TSchema>]: ParamValue<TSchema[K]>; } & { [K in OptionalParamKeys<TSchema>]?: ParamValue<TSchema[K]>; };
|
|
678
|
-
//#endregion
|
|
679
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/kanban-renderer.d.ts
|
|
680
|
-
type KanbanRendererViewMode = "board" | "list";
|
|
681
|
-
type KanbanRendererSortDirection = "asc" | "desc";
|
|
682
|
-
interface KanbanRendererEnumOption {
|
|
683
|
-
value: string;
|
|
684
|
-
label: Localizable<string>;
|
|
685
|
-
color?: string;
|
|
686
|
-
icon?: string | null;
|
|
687
|
-
}
|
|
688
|
-
type KanbanRendererAttributeType = {
|
|
689
|
-
kind: "enum";
|
|
690
|
-
options: KanbanRendererEnumOption[];
|
|
691
|
-
} | {
|
|
692
|
-
kind: "enum-multi";
|
|
693
|
-
options: KanbanRendererEnumOption[];
|
|
694
|
-
} | {
|
|
695
|
-
kind: "status";
|
|
696
|
-
statuses: StatusRef;
|
|
697
|
-
} | {
|
|
698
|
-
kind: "string";
|
|
699
|
-
} | {
|
|
700
|
-
kind: "date";
|
|
701
|
-
} | {
|
|
702
|
-
kind: "number";
|
|
703
|
-
} | {
|
|
704
|
-
kind: "user";
|
|
705
|
-
};
|
|
706
|
-
interface CollectionBadgeItem {
|
|
707
|
-
id: string;
|
|
708
|
-
label: string;
|
|
709
|
-
icon?: string;
|
|
710
|
-
resource?: ResourceRef;
|
|
711
|
-
}
|
|
712
|
-
type KanbanRendererAttributeDisplay = {
|
|
713
|
-
kind: "badge-list";
|
|
714
|
-
itemsAttributeId: string;
|
|
715
|
-
};
|
|
716
|
-
interface KanbanRendererAttributeDescriptor {
|
|
717
|
-
id: string;
|
|
718
|
-
label: Localizable<string>;
|
|
719
|
-
type: KanbanRendererAttributeType;
|
|
720
|
-
filterable?: boolean;
|
|
721
|
-
groupable?: boolean;
|
|
722
|
-
sortable?: boolean;
|
|
723
|
-
displayable?: boolean;
|
|
724
|
-
editable?: boolean;
|
|
725
|
-
display?: KanbanRendererAttributeDisplay;
|
|
726
|
-
}
|
|
727
|
-
interface KanbanRendererSettings {
|
|
728
|
-
viewMode: KanbanRendererViewMode;
|
|
729
|
-
columnGrouping: string;
|
|
730
|
-
rowGrouping: string;
|
|
731
|
-
ordering: {
|
|
732
|
-
attributeId: string;
|
|
733
|
-
direction: KanbanRendererSortDirection;
|
|
734
|
-
};
|
|
735
|
-
displayProperties: string[];
|
|
736
|
-
}
|
|
737
|
-
type KanbanRendererFilterState = Record<string, string[]>;
|
|
738
|
-
interface KanbanRendererSavedView {
|
|
739
|
-
id: string;
|
|
740
|
-
title: Localizable<string>;
|
|
741
|
-
settings: KanbanRendererSettings;
|
|
742
|
-
filters: KanbanRendererFilterState;
|
|
743
|
-
isDefault?: boolean;
|
|
744
|
-
}
|
|
745
|
-
interface KanbanRendererQueryParams {
|
|
746
|
-
renderer: RendererContext;
|
|
747
|
-
settings: KanbanRendererSettings;
|
|
748
|
-
filters: KanbanRendererFilterState;
|
|
749
|
-
}
|
|
750
|
-
type KanbanRendererResourceRef = ResourceRef;
|
|
751
|
-
interface KanbanRendererRow {
|
|
752
|
-
id: string;
|
|
753
|
-
title: string;
|
|
754
|
-
resource?: KanbanRendererResourceRef;
|
|
755
|
-
attributes: Record<string, unknown>;
|
|
756
|
-
}
|
|
757
|
-
interface KanbanRendererColumnAction {
|
|
758
|
-
id: string;
|
|
759
|
-
label: Localizable<string>;
|
|
760
|
-
icon?: string;
|
|
761
|
-
}
|
|
762
|
-
interface KanbanRendererBoardColumnConfig {
|
|
763
|
-
color?: string;
|
|
764
|
-
canDragIn?: boolean;
|
|
765
|
-
canDragOut?: boolean;
|
|
766
|
-
canCreate?: boolean;
|
|
767
|
-
actions?: KanbanRendererColumnAction[];
|
|
768
|
-
}
|
|
769
|
-
interface KanbanRendererQueryResult {
|
|
770
|
-
rows: KanbanRendererRow[];
|
|
771
|
-
attributes?: KanbanRendererAttributeDescriptor[];
|
|
772
|
-
boardColumnConfigs?: Record<string, KanbanRendererBoardColumnConfig>;
|
|
773
|
-
}
|
|
774
|
-
interface KanbanRendererCreateRowContribution<TParams extends ParamObjectSchema = ParamObjectSchema> {
|
|
775
|
-
command: CommandRef<Struct, unknown>;
|
|
776
|
-
title?: Localizable<string>;
|
|
777
|
-
submitLabel?: Localizable<string>;
|
|
778
|
-
columnParam?: string;
|
|
779
|
-
params?: TParams;
|
|
780
|
-
attributesParam?: string;
|
|
781
|
-
attachments?: {
|
|
782
|
-
command: CommandRef<Struct, unknown>;
|
|
783
|
-
resourceParam: string;
|
|
784
|
-
fileParam: string;
|
|
785
|
-
};
|
|
786
|
-
labels?: {
|
|
787
|
-
cancel?: Localizable<string>;
|
|
788
|
-
properties?: Localizable<string>;
|
|
789
|
-
submitError?: Localizable<string>;
|
|
790
|
-
removeFile?: Localizable<string>;
|
|
791
|
-
};
|
|
792
|
-
}
|
|
793
|
-
interface KanbanRendererRowAction<TParams extends Struct = Struct> {
|
|
794
|
-
id: string;
|
|
795
|
-
label: Localizable<string>;
|
|
796
|
-
icon?: string;
|
|
797
|
-
command: CommandRef<TParams, unknown>;
|
|
798
|
-
destructive?: boolean;
|
|
799
|
-
}
|
|
800
|
-
type KanbanRendererRowActivationHandler = RendererCallback<{
|
|
801
|
-
row: KanbanRendererRow;
|
|
802
|
-
}, void>;
|
|
803
|
-
interface KanbanRendererContribution extends RendererContributionBase {
|
|
804
|
-
attributes?: KanbanRendererAttributeDescriptor[];
|
|
805
|
-
query: RendererCallback<KanbanRendererQueryParams, KanbanRendererQueryResult>;
|
|
806
|
-
onAttributeChange?: RendererCallback<{
|
|
807
|
-
rowId: string;
|
|
808
|
-
attributeId: string;
|
|
809
|
-
value: unknown;
|
|
810
|
-
}, unknown>;
|
|
811
|
-
onReorder?: RendererCallback<{
|
|
812
|
-
rowId: string;
|
|
813
|
-
beforeRowId?: string;
|
|
814
|
-
}, unknown>;
|
|
815
|
-
onColumnAction?: RendererCallback<{
|
|
816
|
-
columnId: string;
|
|
817
|
-
actionId: string;
|
|
818
|
-
}, unknown>;
|
|
819
|
-
createRow?: KanbanRendererCreateRowContribution;
|
|
820
|
-
rowActions?: KanbanRendererRowAction[];
|
|
821
|
-
onRowActivate?: KanbanRendererRowActivationHandler;
|
|
822
|
-
defaultSettings?: Partial<KanbanRendererSettings>;
|
|
823
|
-
defaultFilters?: KanbanRendererFilterState;
|
|
824
|
-
defaultViews?: KanbanRendererSavedView[];
|
|
825
|
-
defaultActiveViewId?: string;
|
|
826
|
-
hideToolbar?: boolean;
|
|
827
|
-
}
|
|
828
|
-
//#endregion
|
|
829
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/contributions.d.ts
|
|
830
|
-
interface CliContribution {
|
|
831
|
-
path?: string[];
|
|
832
|
-
globalAliases?: string[][];
|
|
833
|
-
description?: Localizable<string>;
|
|
834
|
-
examples?: string[];
|
|
835
|
-
hidden?: boolean;
|
|
836
|
-
}
|
|
837
|
-
interface WhenExpression {
|
|
838
|
-
mode?: ModeRef | readonly ModeRef[];
|
|
839
|
-
source?: CommandSource[];
|
|
840
|
-
view?: ViewRef | readonly ViewRef[];
|
|
841
|
-
resourceType?: readonly ResourceKindRef[];
|
|
842
|
-
metadata?: JsonObject;
|
|
843
|
-
}
|
|
844
|
-
interface MenuContribution<TSlotContext extends Struct = Struct, TParams extends Struct = Struct> {
|
|
845
|
-
slot: SlotRef<TSlotContext, "menu">;
|
|
846
|
-
label?: Localizable<string>;
|
|
847
|
-
group?: string;
|
|
848
|
-
placement?: "first" | "default" | "last";
|
|
849
|
-
icon?: string;
|
|
850
|
-
when?: WhenExpression;
|
|
851
|
-
params?: Partial<TParams>;
|
|
852
|
-
presentation?: "menu-item" | "button" | "icon-button";
|
|
853
|
-
}
|
|
854
|
-
interface CommandPaletteContribution<TParams extends Struct = Struct> {
|
|
855
|
-
label?: Localizable<string>;
|
|
856
|
-
group?: string;
|
|
857
|
-
placement?: "first" | "default" | "last";
|
|
858
|
-
icon?: string;
|
|
859
|
-
when?: WhenExpression;
|
|
860
|
-
params?: Partial<TParams>;
|
|
861
|
-
}
|
|
862
|
-
interface ActivityItemContribution<TParams extends Struct = Struct> extends ContributionDefinition<"activity-item"> {
|
|
863
|
-
title: Localizable<string>;
|
|
864
|
-
icon: string;
|
|
865
|
-
/** Mode ids whose activity rail shows this item. */
|
|
866
|
-
modes: readonly ModeRef[];
|
|
867
|
-
placement?: "first" | "default" | "last";
|
|
868
|
-
command: CommandRef<TParams, unknown>;
|
|
869
|
-
params?: Partial<TParams>;
|
|
870
|
-
}
|
|
871
|
-
interface ModeRegionSettings {
|
|
872
|
-
/** Hide the panel header when the mode supplies its own controls. */
|
|
873
|
-
readonly showHeader?: boolean;
|
|
874
|
-
readonly size?: RegionSize;
|
|
875
|
-
/** Allow dragging this region closed. Explicit hide/show is always available. */
|
|
876
|
-
readonly collapsible?: boolean;
|
|
877
|
-
/** Keep a tab visible when this region has only one visible item. */
|
|
878
|
-
readonly alwaysShowTabs?: boolean;
|
|
879
|
-
}
|
|
880
|
-
interface ModeContribution extends ContributionDefinition<"mode"> {
|
|
881
|
-
label: Localizable<string>;
|
|
882
|
-
icon?: string;
|
|
883
|
-
regions: readonly ExtensionPanelRegion[];
|
|
884
|
-
/** Default theme for this mode. An explicit user choice for the mode takes precedence. */
|
|
885
|
-
defaultTheme?: ThemeRef;
|
|
886
|
-
/** Whether side panels may float while this mode is active. Defaults to visible. */
|
|
887
|
-
floatingPanels?: "visible" | "hidden";
|
|
888
|
-
/** Replace host chrome with a view, or hide it with false, while the mode is active. */
|
|
889
|
-
chrome?: Partial<Record<"nav" | "sidenav" | "activity" | "status", ViewRef | false>>;
|
|
890
|
-
/** Region-level layout policy. The mode owns it; placements cannot set it. */
|
|
891
|
-
regionSettings?: Readonly<Partial<Record<DockedWorkbenchRegion, ModeRegionSettings>>>;
|
|
892
|
-
}
|
|
893
|
-
interface WebviewContribution {
|
|
894
|
-
entry: PackageAssetDescriptor;
|
|
895
|
-
title?: Localizable<string>;
|
|
896
|
-
capabilities?: WebviewCapabilityDeclaration[];
|
|
897
|
-
}
|
|
898
|
-
interface SettingsPanelContribution extends ContributionDefinition<"settings-panel"> {
|
|
899
|
-
view: ViewRef;
|
|
900
|
-
slot: SettingsSlotRef;
|
|
901
|
-
section?: SettingsSectionRef;
|
|
902
|
-
}
|
|
903
|
-
/** A named group in the settings navigation that an extension's panels can sit under. */
|
|
904
|
-
interface SettingsSectionContribution extends ContributionDefinition<"settings-section"> {
|
|
905
|
-
title: Localizable<string>;
|
|
906
|
-
/** Lower sorts first among sibling sections. */
|
|
907
|
-
order?: number;
|
|
908
|
-
}
|
|
909
|
-
/**
|
|
910
|
-
* Command palette resource providers contribute dynamic, searchable palette results
|
|
911
|
-
* (e.g. slides in a presentation) backed by a private query callback. The host queries
|
|
912
|
-
* matching providers as the user types and refreshes results when a declared event fires.
|
|
913
|
-
*/
|
|
914
|
-
interface CommandPaletteResourceQueryParams {
|
|
915
|
-
projectId?: string;
|
|
916
|
-
modeId?: string;
|
|
917
|
-
activeResource?: ResourceRef;
|
|
918
|
-
providerId: string;
|
|
919
|
-
query: string;
|
|
920
|
-
limit: number;
|
|
921
|
-
}
|
|
922
|
-
type CommandPaletteResourceTarget = NavigationTarget;
|
|
923
|
-
interface CommandPaletteResourceItem {
|
|
924
|
-
id: string;
|
|
925
|
-
label: string;
|
|
926
|
-
description?: string;
|
|
927
|
-
icon?: string;
|
|
928
|
-
keywords?: string[];
|
|
929
|
-
target: CommandPaletteResourceTarget;
|
|
930
|
-
}
|
|
931
|
-
interface CommandPaletteResourceQueryResult {
|
|
932
|
-
items: CommandPaletteResourceItem[];
|
|
933
|
-
}
|
|
934
|
-
interface CommandPaletteResourceContribution extends ContributionDefinition<"command-palette-resource"> {
|
|
935
|
-
title: Localizable<string>;
|
|
936
|
-
resourceKind?: ResourceKindRef;
|
|
937
|
-
query: RendererCallback<CommandPaletteResourceQueryParams, CommandPaletteResourceQueryResult>;
|
|
938
|
-
refreshEvents?: readonly RendererEventReference[];
|
|
939
|
-
}
|
|
940
|
-
type ExtensionSettingScope = "global" | "project";
|
|
941
|
-
type ExtensionSettingValueType = "boolean" | "number" | "string" | "array" | "object";
|
|
942
|
-
type ExtensionSettingValueForType<TType extends ExtensionSettingValueType> = TType extends "boolean" ? boolean : TType extends "number" ? number : TType extends "string" ? string : TType extends "array" ? JsonValue[] : JsonObject;
|
|
943
|
-
type ExtensionSettingProperty<TType extends ExtensionSettingValueType = ExtensionSettingValueType> = { [TSettingType in TType]: {
|
|
944
|
-
type: TSettingType;
|
|
945
|
-
scope: ExtensionSettingScope;
|
|
946
|
-
default?: ExtensionSettingValueForType<TSettingType>;
|
|
947
|
-
enum?: ExtensionSettingValueForType<TSettingType>[];
|
|
948
|
-
title?: Localizable<string>;
|
|
949
|
-
description?: Localizable<string>;
|
|
950
|
-
}; }[TType];
|
|
951
|
-
interface ExtensionSettingsContribution<TProperties extends Record<string, ExtensionSettingProperty> = Record<string, ExtensionSettingProperty>> {
|
|
952
|
-
properties: TProperties;
|
|
953
|
-
}
|
|
954
|
-
interface ArtifactMountContribution extends ContributionDefinition<"artifact-mount"> {
|
|
955
|
-
/** Relative path under .pstdio/<extension.name>/. */
|
|
956
|
-
path: string;
|
|
957
|
-
label: Localizable<string>;
|
|
958
|
-
}
|
|
959
|
-
interface TemplateTypeContribution extends ContributionDefinition<"template-type"> {
|
|
960
|
-
label: Localizable<string>;
|
|
961
|
-
description?: Localizable<string>;
|
|
962
|
-
order?: number;
|
|
963
|
-
commands?: {
|
|
964
|
-
list: CommandRef;
|
|
965
|
-
read: CommandRef;
|
|
966
|
-
save: CommandRef;
|
|
967
|
-
delete: CommandRef;
|
|
968
|
-
};
|
|
969
|
-
}
|
|
970
|
-
interface TemplateContribution extends ContributionDefinition<"template"> {
|
|
971
|
-
title: Localizable<string>;
|
|
972
|
-
type: string;
|
|
973
|
-
source: PackageAssetDescriptor;
|
|
974
|
-
description?: Localizable<string>;
|
|
975
|
-
}
|
|
976
|
-
interface SkillContribution extends ContributionDefinition<"skill"> {
|
|
977
|
-
title: Localizable<string>;
|
|
978
|
-
source: PackageAssetDescriptor;
|
|
979
|
-
description?: Localizable<string>;
|
|
980
|
-
}
|
|
981
|
-
type ThemeMode = "light" | "dark";
|
|
982
|
-
interface ThemeContribution extends ContributionDefinition<"theme"> {
|
|
983
|
-
title: Localizable<string>;
|
|
984
|
-
source: PackageAssetDescriptor;
|
|
985
|
-
format: "vscode-color-theme";
|
|
986
|
-
mode?: ThemeMode;
|
|
987
|
-
description?: Localizable<string>;
|
|
988
|
-
}
|
|
989
|
-
interface FileIconThemeContribution extends ContributionDefinition<"file-icon-theme"> {
|
|
990
|
-
title: Localizable<string>;
|
|
991
|
-
source: PackageAssetDescriptor;
|
|
992
|
-
format: "vscode-file-icon-theme";
|
|
993
|
-
description?: Localizable<string>;
|
|
994
|
-
}
|
|
995
|
-
/**
|
|
996
|
-
* Chord string in TanStack Hotkeys syntax (e.g. "mod+shift+p"). `mod` is
|
|
997
|
-
* Cmd on macOS and Ctrl elsewhere. Parsing, validation, canonicalization,
|
|
998
|
-
* and display labels are all delegated to `@tanstack/hotkeys`.
|
|
999
|
-
*/
|
|
1000
|
-
type KeybindingChord = string;
|
|
1001
|
-
interface KeybindingContribution extends ContributionDefinition<"keybinding"> {
|
|
1002
|
-
/** Default chord. Used on every platform unless an override is provided. */
|
|
1003
|
-
key: KeybindingChord;
|
|
1004
|
-
/** macOS override. */
|
|
1005
|
-
mac?: KeybindingChord;
|
|
1006
|
-
/** Linux override. */
|
|
1007
|
-
linux?: KeybindingChord;
|
|
1008
|
-
/** Windows override. */
|
|
1009
|
-
win?: KeybindingChord;
|
|
1010
|
-
/** Action this chord executes through the shared navigation executor. */
|
|
1011
|
-
action: NavigationTarget;
|
|
1012
|
-
/** Optional gating predicate. The host evaluates it at dispatch time. */
|
|
1013
|
-
when?: WhenExpression;
|
|
1014
|
-
}
|
|
1015
|
-
//#endregion
|
|
1016
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/control-declarations.d.ts
|
|
1017
|
-
interface BaseControl {
|
|
1018
|
-
id: string;
|
|
1019
|
-
name: string;
|
|
1020
|
-
description?: string;
|
|
1021
|
-
/** Locks this one param while the rest of the editor stays editable. */
|
|
1022
|
-
readOnly?: boolean;
|
|
1023
|
-
}
|
|
1024
|
-
interface NumberControl extends BaseControl {
|
|
1025
|
-
type: "number";
|
|
1026
|
-
defaultValue: number;
|
|
1027
|
-
min?: number;
|
|
1028
|
-
max?: number;
|
|
1029
|
-
step?: number;
|
|
1030
|
-
}
|
|
1031
|
-
interface BooleanControl extends BaseControl {
|
|
1032
|
-
type: "boolean";
|
|
1033
|
-
defaultValue: boolean;
|
|
1034
|
-
}
|
|
1035
|
-
interface TextControl extends BaseControl {
|
|
1036
|
-
type: "text";
|
|
1037
|
-
defaultValue: string;
|
|
1038
|
-
singleLine?: boolean;
|
|
1039
|
-
}
|
|
1040
|
-
interface MarkdownControl extends BaseControl {
|
|
1041
|
-
type: "markdown";
|
|
1042
|
-
defaultValue: string;
|
|
1043
|
-
placeholder?: string;
|
|
1044
|
-
}
|
|
1045
|
-
interface SelectionOption {
|
|
1046
|
-
id: string;
|
|
1047
|
-
name: string;
|
|
1048
|
-
icon?: string;
|
|
1049
|
-
/** Palette key (e.g. "blue") applied to the option's icon. */
|
|
1050
|
-
color?: string;
|
|
1051
|
-
description?: string;
|
|
1052
|
-
disabled?: boolean;
|
|
1053
|
-
}
|
|
1054
|
-
/** Parent selector used to swap the option set of a grouped selection. */
|
|
1055
|
-
interface SelectionGroup {
|
|
1056
|
-
id: string;
|
|
1057
|
-
name: string;
|
|
1058
|
-
defaultValue: string;
|
|
1059
|
-
options: SelectionOption[];
|
|
1060
|
-
placeholder?: string;
|
|
1061
|
-
searchable?: boolean;
|
|
1062
|
-
searchPlaceholder?: string;
|
|
1063
|
-
emptyText?: string;
|
|
1064
|
-
disabled?: boolean;
|
|
1065
|
-
}
|
|
1066
|
-
interface SelectionControl extends BaseControl {
|
|
1067
|
-
type: "selection";
|
|
1068
|
-
defaultValue: string | string[];
|
|
1069
|
-
options: SelectionOption[];
|
|
1070
|
-
multiSelect?: boolean;
|
|
1071
|
-
placeholder?: string;
|
|
1072
|
-
searchable?: boolean;
|
|
1073
|
-
searchPlaceholder?: string;
|
|
1074
|
-
emptyText?: string;
|
|
1075
|
-
group?: SelectionGroup;
|
|
1076
|
-
/** Adds a "clear" row so a single-select can be returned to unset. */
|
|
1077
|
-
clearable?: boolean;
|
|
1078
|
-
/**
|
|
1079
|
-
* Renders the control inert but still as a control — unlike `readOnly`, which
|
|
1080
|
-
* collapses it to plain text and drops the option's icon.
|
|
1081
|
-
*/
|
|
1082
|
-
disabled?: boolean;
|
|
1083
|
-
}
|
|
1084
|
-
interface DateControl extends BaseControl {
|
|
1085
|
-
type: "date";
|
|
1086
|
-
defaultValue: string;
|
|
1087
|
-
min?: string;
|
|
1088
|
-
max?: string;
|
|
1089
|
-
}
|
|
1090
|
-
interface ColorControl extends BaseControl {
|
|
1091
|
-
type: "color";
|
|
1092
|
-
defaultValue: string;
|
|
1093
|
-
}
|
|
1094
|
-
interface ParamEditorReadOnlyImage {
|
|
1095
|
-
src: string;
|
|
1096
|
-
alt: string;
|
|
1097
|
-
}
|
|
1098
|
-
type ParamEditorReadOnlyContent = string | number | boolean | null | Array<string | number | boolean | null> | {
|
|
1099
|
-
type: "image";
|
|
1100
|
-
src: string;
|
|
1101
|
-
alt: string;
|
|
1102
|
-
} | {
|
|
1103
|
-
type: "image-gallery";
|
|
1104
|
-
images: ParamEditorReadOnlyImage[];
|
|
1105
|
-
};
|
|
1106
|
-
/** Serializable display-only value rendered by the read-only Param Editor. */
|
|
1107
|
-
interface ReadOnlyControl extends BaseControl {
|
|
1108
|
-
type: "readOnly";
|
|
1109
|
-
value: ParamEditorReadOnlyContent;
|
|
1110
|
-
}
|
|
1111
|
-
/** A reference the host can open (e.g. another resource tab). */
|
|
1112
|
-
type ResourceRefValue = ResourceRef;
|
|
1113
|
-
/**
|
|
1114
|
-
* Serializable resource chip. Clicking it opens `href` externally, opens `ref` via
|
|
1115
|
-
* `onOpenResource`, or copies `copyText` to the clipboard — whichever is set.
|
|
1116
|
-
*/
|
|
1117
|
-
interface ResourceOption {
|
|
1118
|
-
id: string;
|
|
1119
|
-
name: string;
|
|
1120
|
-
icon?: string;
|
|
1121
|
-
color?: string;
|
|
1122
|
-
description?: string;
|
|
1123
|
-
href?: string;
|
|
1124
|
-
ref?: ResourceRefValue;
|
|
1125
|
-
copyText?: string;
|
|
1126
|
-
}
|
|
1127
|
-
/**
|
|
1128
|
-
* Resource references rendered as tags/chips. View-only by default; set `editable`
|
|
1129
|
-
* to pick from `options` via a dropdown. Value is the selected option id(s), mirroring
|
|
1130
|
-
* {@link SelectionControl}, so it stays JSON-safe across the controls-command boundary.
|
|
1131
|
-
*/
|
|
1132
|
-
interface ResourceControl extends BaseControl {
|
|
1133
|
-
type: "resource";
|
|
1134
|
-
defaultValue: string | string[];
|
|
1135
|
-
options: ResourceOption[];
|
|
1136
|
-
multiSelect?: boolean;
|
|
1137
|
-
editable?: boolean;
|
|
1138
|
-
placeholder?: string;
|
|
1139
|
-
emptyText?: string;
|
|
1140
|
-
}
|
|
1141
|
-
type RangeValue = [number, number];
|
|
1142
|
-
/** Two-handle numeric range control. Values normalize to ordered `[start, end]`. */
|
|
1143
|
-
interface RangeControl extends BaseControl {
|
|
1144
|
-
type: "range";
|
|
1145
|
-
defaultValue: RangeValue;
|
|
1146
|
-
min: number;
|
|
1147
|
-
max: number;
|
|
1148
|
-
step?: number;
|
|
1149
|
-
unit?: string;
|
|
1150
|
-
markerCount?: number;
|
|
1151
|
-
}
|
|
1152
|
-
interface SegmentedOption {
|
|
1153
|
-
id: string;
|
|
1154
|
-
name: string;
|
|
1155
|
-
icon?: string;
|
|
1156
|
-
indicatorColor?: string;
|
|
1157
|
-
}
|
|
1158
|
-
/** Mutually-exclusive mode control rendered as a segmented button group. */
|
|
1159
|
-
interface SegmentedControl extends BaseControl {
|
|
1160
|
-
type: "segmented";
|
|
1161
|
-
defaultValue: string;
|
|
1162
|
-
options: SegmentedOption[];
|
|
1163
|
-
variant?: "default" | "dots";
|
|
1164
|
-
}
|
|
1165
|
-
interface ActionOption {
|
|
1166
|
-
id: string;
|
|
1167
|
-
name: string;
|
|
1168
|
-
icon?: string;
|
|
1169
|
-
disabled?: boolean;
|
|
1170
|
-
}
|
|
1171
|
-
/** Compact command set rendered as an action button row. */
|
|
1172
|
-
interface ActionsControl extends BaseControl {
|
|
1173
|
-
type: "actions";
|
|
1174
|
-
defaultValue?: string;
|
|
1175
|
-
options: ActionOption[];
|
|
1176
|
-
}
|
|
1177
|
-
type AnchorGridValue = "top-left" | "top" | "top-right" | "left" | "center" | "right" | "bottom-left" | "bottom" | "bottom-right";
|
|
1178
|
-
/** Nine-point alignment picker. */
|
|
1179
|
-
interface AnchorGridControl extends BaseControl {
|
|
1180
|
-
type: "anchorGrid";
|
|
1181
|
-
defaultValue: AnchorGridValue;
|
|
1182
|
-
}
|
|
1183
|
-
type VectorValue = {
|
|
1184
|
-
x: number;
|
|
1185
|
-
y: number;
|
|
1186
|
-
};
|
|
1187
|
-
/** Paired x/y numeric control. */
|
|
1188
|
-
interface VectorControl extends BaseControl {
|
|
1189
|
-
type: "vector";
|
|
1190
|
-
defaultValue: VectorValue;
|
|
1191
|
-
coordinateMode?: "cartesian" | "screen";
|
|
1192
|
-
xLabel?: string;
|
|
1193
|
-
yLabel?: string;
|
|
1194
|
-
min?: number;
|
|
1195
|
-
max?: number;
|
|
1196
|
-
step?: number;
|
|
1197
|
-
}
|
|
1198
|
-
type ControlParam = NumberControl | BooleanControl | TextControl | MarkdownControl | SelectionControl | DateControl | ColorControl | ReadOnlyControl | ResourceControl | RangeControl | SegmentedControl | ActionsControl | AnchorGridControl | VectorControl;
|
|
1199
|
-
interface ControlGroup {
|
|
1200
|
-
id: string;
|
|
1201
|
-
title: string;
|
|
1202
|
-
description?: string;
|
|
1203
|
-
params: ControlParam[];
|
|
1204
|
-
collapsible?: boolean;
|
|
1205
|
-
defaultCollapsed?: boolean;
|
|
1206
|
-
}
|
|
1207
|
-
type ControlValue = number | string | boolean | null | string[] | RangeValue | VectorValue;
|
|
1208
|
-
type ControlValueMap = Record<string, ControlValue>;
|
|
1209
|
-
//#endregion
|
|
1210
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/controls.d.ts
|
|
1211
|
-
type ControlsResourceRef = ResourceRef;
|
|
1212
|
-
interface ControlsQueryParams {
|
|
1213
|
-
renderer: RendererContext;
|
|
1214
|
-
}
|
|
1215
|
-
interface ControlsQueryResult {
|
|
1216
|
-
params?: ControlParam[];
|
|
1217
|
-
groups?: ControlGroup[];
|
|
1218
|
-
values?: ControlValueMap;
|
|
1219
|
-
readOnly?: boolean;
|
|
1220
|
-
}
|
|
1221
|
-
interface ControlsUpdateValueInput {
|
|
1222
|
-
renderer: RendererContext;
|
|
1223
|
-
controlId: string;
|
|
1224
|
-
value: ControlValue;
|
|
1225
|
-
values: ControlValueMap;
|
|
1226
|
-
}
|
|
1227
|
-
interface ControlsApplyInput {
|
|
1228
|
-
renderer: RendererContext;
|
|
1229
|
-
values: ControlValueMap;
|
|
1230
|
-
}
|
|
1231
|
-
interface ControlsResetInput {
|
|
1232
|
-
renderer: RendererContext;
|
|
1233
|
-
controlIds?: string[];
|
|
1234
|
-
}
|
|
1235
|
-
/** A native controls view. Its query supplies serializable fields and their current values. */
|
|
1236
|
-
interface ControlsRendererContribution extends RendererContributionBase {
|
|
1237
|
-
query: RendererCallback<ControlsQueryParams, ControlsQueryResult>;
|
|
1238
|
-
onValueChange?: RendererCallback<ControlsUpdateValueInput, unknown>;
|
|
1239
|
-
onApply?: RendererCallback<ControlsApplyInput, unknown>;
|
|
1240
|
-
onReset?: RendererCallback<ControlsResetInput, unknown>;
|
|
1241
|
-
defaultValues?: ControlValueMap;
|
|
1242
|
-
}
|
|
1243
|
-
//#endregion
|
|
1244
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/data-table-renderer.d.ts
|
|
1245
|
-
type DataTableRendererResourceRef = ResourceRef;
|
|
1246
|
-
interface DataTableRendererQueryParams {
|
|
1247
|
-
renderer: RendererContext;
|
|
1248
|
-
}
|
|
1249
|
-
interface DataTableRendererThemeColor {
|
|
1250
|
-
light: string;
|
|
1251
|
-
dark: string;
|
|
1252
|
-
foreground?: {
|
|
1253
|
-
light: string;
|
|
1254
|
-
dark: string;
|
|
1255
|
-
};
|
|
1256
|
-
}
|
|
1257
|
-
type DataTableRendererColumnStat = {
|
|
1258
|
-
type: "unique";
|
|
1259
|
-
} | {
|
|
1260
|
-
type: "histogram";
|
|
1261
|
-
bins?: number;
|
|
1262
|
-
} | {
|
|
1263
|
-
type: "top-values";
|
|
1264
|
-
limit?: number;
|
|
1265
|
-
};
|
|
1266
|
-
type DataTableRendererColumnRenderer = {
|
|
1267
|
-
type: "json";
|
|
1268
|
-
} | {
|
|
1269
|
-
type: "color-scale";
|
|
1270
|
-
stops: Array<{
|
|
1271
|
-
value: number;
|
|
1272
|
-
color: DataTableRendererThemeColor;
|
|
1273
|
-
}>;
|
|
1274
|
-
} | {
|
|
1275
|
-
type: "categorical-color";
|
|
1276
|
-
categories: Array<{
|
|
1277
|
-
value: string | number | boolean | null;
|
|
1278
|
-
color: DataTableRendererThemeColor;
|
|
1279
|
-
}>;
|
|
1280
|
-
};
|
|
1281
|
-
interface DataTableRendererColumn {
|
|
1282
|
-
id: string;
|
|
1283
|
-
label?: Localizable<string>;
|
|
1284
|
-
description?: Localizable<string>;
|
|
1285
|
-
icon?: string;
|
|
1286
|
-
hidden?: boolean;
|
|
1287
|
-
stat?: DataTableRendererColumnStat;
|
|
1288
|
-
renderer?: DataTableRendererColumnRenderer;
|
|
1289
|
-
}
|
|
1290
|
-
interface DataTableRendererRow {
|
|
1291
|
-
id: string;
|
|
1292
|
-
values: Record<string, JsonValue>;
|
|
1293
|
-
resource?: DataTableRendererResourceRef;
|
|
1294
|
-
}
|
|
1295
|
-
interface DataTableRendererQueryResult {
|
|
1296
|
-
rows: DataTableRendererRow[];
|
|
1297
|
-
columns?: DataTableRendererColumn[];
|
|
1298
|
-
}
|
|
1299
|
-
interface DataTableRendererRowAction<TParams extends Struct = Struct> {
|
|
1300
|
-
id: string;
|
|
1301
|
-
label: Localizable<string>;
|
|
1302
|
-
icon?: string;
|
|
1303
|
-
destructive?: boolean;
|
|
1304
|
-
command: CommandRef<TParams, unknown>;
|
|
1305
|
-
}
|
|
1306
|
-
interface DataTableRendererSelectionAction<TParams extends Struct = Struct> {
|
|
1307
|
-
id: string;
|
|
1308
|
-
label: Localizable<string>;
|
|
1309
|
-
icon?: string;
|
|
1310
|
-
destructive?: boolean;
|
|
1311
|
-
command: CommandRef<TParams, unknown>;
|
|
1312
|
-
}
|
|
1313
|
-
type DataTableRendererRowActivationHandler = RendererCallback<{
|
|
1314
|
-
row: DataTableRendererRow;
|
|
1315
|
-
}, void>;
|
|
1316
|
-
interface DataTableRendererContribution extends RendererContributionBase {
|
|
1317
|
-
columns?: DataTableRendererColumn[];
|
|
1318
|
-
query: RendererCallback<DataTableRendererQueryParams, DataTableRendererQueryResult>;
|
|
1319
|
-
selectionMode?: "none" | "multiple";
|
|
1320
|
-
selectionActions?: DataTableRendererSelectionAction[];
|
|
1321
|
-
rowActions?: DataTableRendererRowAction[];
|
|
1322
|
-
onRowActivate?: DataTableRendererRowActivationHandler;
|
|
1323
|
-
initialPageSize?: number;
|
|
1324
|
-
pageSizeOptions?: number[];
|
|
1325
|
-
}
|
|
1326
|
-
//#endregion
|
|
1327
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/tree-renderer.d.ts
|
|
1328
|
-
type TreeRendererResourceRef = ResourceRef;
|
|
1329
|
-
interface TreeRendererState {
|
|
1330
|
-
expandedNodeIds: string[];
|
|
1331
|
-
expandedSectionIds: string[];
|
|
1332
|
-
selectedNodeId?: string;
|
|
1333
|
-
}
|
|
1334
|
-
interface TreeRendererQueryParams {
|
|
1335
|
-
renderer: RendererContext;
|
|
1336
|
-
state?: TreeRendererState;
|
|
1337
|
-
filter?: string;
|
|
1338
|
-
}
|
|
1339
|
-
interface TreeRendererChildrenParams extends TreeRendererQueryParams {
|
|
1340
|
-
node: TreeNode;
|
|
1341
|
-
}
|
|
1342
|
-
interface TreeRendererActionParams extends TreeRendererQueryParams {
|
|
1343
|
-
actionId: string;
|
|
1344
|
-
node?: TreeNode;
|
|
1345
|
-
}
|
|
1346
|
-
type TreeNodeTarget = NavigationTarget;
|
|
1347
|
-
interface TreeAction {
|
|
1348
|
-
id: string;
|
|
1349
|
-
label?: Localizable<string>;
|
|
1350
|
-
icon?: string;
|
|
1351
|
-
command?: CommandRef<Struct, unknown>;
|
|
1352
|
-
params?: Struct;
|
|
1353
|
-
input?: ParamObjectSchema;
|
|
1354
|
-
submitLabel?: string;
|
|
1355
|
-
when?: string;
|
|
1356
|
-
disabled?: boolean;
|
|
1357
|
-
}
|
|
1358
|
-
interface TreeSectionEmptyState {
|
|
1359
|
-
title: Localizable<string>;
|
|
1360
|
-
description?: Localizable<string>;
|
|
1361
|
-
icon?: string;
|
|
1362
|
-
}
|
|
1363
|
-
type TreeNodeRowVariant = "empty-state";
|
|
1364
|
-
interface TreeNode {
|
|
1365
|
-
id: string;
|
|
1366
|
-
label: Localizable<string>;
|
|
1367
|
-
icon?: string;
|
|
1368
|
-
iconColor?: string;
|
|
1369
|
-
iconTooltip?: string;
|
|
1370
|
-
resource?: TreeRendererResourceRef;
|
|
1371
|
-
target?: TreeNodeTarget;
|
|
1372
|
-
/** Visual row variant for non-data rows such as placeholders. */
|
|
1373
|
-
rowVariant?: TreeNodeRowVariant;
|
|
1374
|
-
actions?: TreeAction[];
|
|
1375
|
-
contextMenuActions?: TreeAction[];
|
|
1376
|
-
collapsible?: boolean;
|
|
1377
|
-
disabled?: boolean;
|
|
1378
|
-
selected?: boolean;
|
|
1379
|
-
children?: TreeNode[];
|
|
1380
|
-
description?: string;
|
|
1381
|
-
contextValue?: string;
|
|
1382
|
-
hiddenByDefault?: boolean;
|
|
1383
|
-
/** Opt in to the tree's hide/show customization menu (header/footer rows). Off by default. */
|
|
1384
|
-
canHide?: boolean;
|
|
1385
|
-
metadata?: JsonObject;
|
|
1386
|
-
}
|
|
1387
|
-
interface TreeViewSection {
|
|
1388
|
-
id: string;
|
|
1389
|
-
label?: Localizable<string>;
|
|
1390
|
-
actions?: TreeAction[];
|
|
1391
|
-
collapsible?: boolean;
|
|
1392
|
-
emptyState?: TreeSectionEmptyState;
|
|
1393
|
-
nodes: TreeNode[];
|
|
1394
|
-
hiddenByDefault?: boolean;
|
|
1395
|
-
/** Opt in to the tree's hide/show customization menu (a category). Off by default. */
|
|
1396
|
-
canHide?: boolean;
|
|
1397
|
-
}
|
|
1398
|
-
interface TreeRendererContribution extends RendererContributionBase {
|
|
1399
|
-
searchable?: boolean;
|
|
1400
|
-
searchPlaceholder?: Localizable<string>;
|
|
1401
|
-
header?: RendererCallback<TreeRendererQueryParams, TreeViewSection[]>;
|
|
1402
|
-
body: RendererCallback<TreeRendererQueryParams, TreeViewSection[]>;
|
|
1403
|
-
children?: RendererCallback<TreeRendererChildrenParams, TreeNode[]>;
|
|
1404
|
-
footer?: RendererCallback<TreeRendererQueryParams, TreeViewSection[]>;
|
|
1405
|
-
defaultExpandedSectionIds?: string[];
|
|
1406
|
-
defaultExpandedNodeIds?: string[];
|
|
1407
|
-
}
|
|
1408
|
-
type TreeRendererCommandResult = TreeViewSection[] | TreeNode[] | JsonValue;
|
|
1409
|
-
//#endregion
|
|
1410
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/views.d.ts
|
|
1411
|
-
type NativeViewBody<Kind extends string, Definition> = {
|
|
1412
|
-
readonly kind: Kind;
|
|
1413
|
-
} & Omit<Definition, "title" | "icon" | "resourceKind">;
|
|
1414
|
-
type WebviewViewBody = {
|
|
1415
|
-
readonly kind: "webview";
|
|
1416
|
-
} & WebviewContribution;
|
|
1417
|
-
type TreeViewBody = NativeViewBody<"tree", TreeRendererContribution>;
|
|
1418
|
-
type FileViewBody = NativeViewBody<"file", FileRendererContribution>;
|
|
1419
|
-
type ControlsViewBody = NativeViewBody<"controls", ControlsRendererContribution>;
|
|
1420
|
-
type KanbanViewBody = NativeViewBody<"kanban", KanbanRendererContribution>;
|
|
1421
|
-
type DataTableViewBody = NativeViewBody<"dataTable", DataTableRendererContribution>;
|
|
1422
|
-
type ViewBody = WebviewViewBody | TreeViewBody | FileViewBody | ControlsViewBody | KanbanViewBody | DataTableViewBody;
|
|
1423
|
-
interface ViewContribution extends ContributionDefinition<"view"> {
|
|
1424
|
-
readonly title: Localizable<string>;
|
|
1425
|
-
readonly icon?: string;
|
|
1426
|
-
readonly body: ViewBody;
|
|
1427
|
-
}
|
|
1428
|
-
type NavigationOwnerRef = ModeRef | PageRef;
|
|
1429
|
-
type NavigationTreeSlot = "header" | "content" | "footer";
|
|
1430
|
-
interface NavigationItemContribution extends ContributionDefinition<"navigation-item"> {
|
|
1431
|
-
readonly owner: NavigationOwnerRef;
|
|
1432
|
-
readonly slot?: NavigationTreeSlot;
|
|
1433
|
-
readonly label: Localizable<string>;
|
|
1434
|
-
readonly icon?: string;
|
|
1435
|
-
readonly group?: string;
|
|
1436
|
-
readonly when?: WhenExpression;
|
|
1437
|
-
readonly action: NavigationTarget;
|
|
1438
|
-
}
|
|
1439
|
-
interface NavigationTreeContribution extends ContributionDefinition<"navigation-tree"> {
|
|
1440
|
-
readonly owner: NavigationOwnerRef;
|
|
1441
|
-
readonly slot?: NavigationTreeSlot;
|
|
1442
|
-
readonly view: ViewRef;
|
|
1443
|
-
/** Project-scoped trees read without a selected resource. Defaults to selection. */
|
|
1444
|
-
readonly resourceScope?: "project" | "selection";
|
|
1445
|
-
}
|
|
1446
|
-
/**
|
|
1447
|
-
* Initial presence of a static placement inside its owner scope.
|
|
1448
|
-
* - "fixed": always open while the owner is active; the user cannot close it.
|
|
1449
|
-
* - "open": open when the owner has no saved state; the user may close it.
|
|
1450
|
-
* - "closed": closed until the user opens it (for example through the Add panel).
|
|
1451
|
-
* A saved user choice wins over "open" and "closed" on the next visit.
|
|
1452
|
-
*/
|
|
1453
|
-
type PlacementPresence = "fixed" | "open" | "closed";
|
|
1454
|
-
type PlacementItem = {
|
|
1455
|
-
readonly kind: "view";
|
|
1456
|
-
readonly view: ViewRef;
|
|
1457
|
-
readonly presence: PlacementPresence;
|
|
1458
|
-
} | {
|
|
1459
|
-
readonly kind: "binding";
|
|
1460
|
-
readonly binding: ResourceBinding;
|
|
1461
|
-
};
|
|
1462
|
-
type PlacementMountStrategy = "active" | "keep-mounted";
|
|
1463
|
-
interface PlacementTabMenuRow {
|
|
1464
|
-
readonly id: string;
|
|
1465
|
-
readonly label: Localizable<string>;
|
|
1466
|
-
readonly icon?: string;
|
|
1467
|
-
readonly iconColor?: string;
|
|
1468
|
-
readonly selected?: boolean;
|
|
1469
|
-
readonly disabled?: boolean;
|
|
1470
|
-
readonly action?: NavigationTarget;
|
|
1471
|
-
}
|
|
1472
|
-
interface PlacementTabMenuGroup {
|
|
1473
|
-
readonly id: string;
|
|
1474
|
-
readonly rows: readonly PlacementTabMenuRow[];
|
|
1475
|
-
}
|
|
1476
|
-
interface PlacementTabSnapshot extends Struct {
|
|
1477
|
-
readonly label?: Localizable<string>;
|
|
1478
|
-
readonly icon?: string;
|
|
1479
|
-
readonly indicator?: {
|
|
1480
|
-
readonly icon: string;
|
|
1481
|
-
readonly color?: string;
|
|
1482
|
-
readonly label?: Localizable<string>;
|
|
1483
|
-
};
|
|
1484
|
-
readonly menu?: readonly PlacementTabMenuGroup[];
|
|
1485
|
-
}
|
|
1486
|
-
interface PlacementTabPresentation {
|
|
1487
|
-
readonly query: RendererCallback<JsonObject, PlacementTabSnapshot>;
|
|
1488
|
-
readonly refreshEvents?: readonly RendererEventReference[];
|
|
1489
|
-
}
|
|
1490
|
-
interface PlacementPresentation {
|
|
1491
|
-
readonly mountStrategy?: PlacementMountStrategy;
|
|
1492
|
-
readonly hiddenByDefault?: boolean;
|
|
1493
|
-
readonly headerBorderBottom?: boolean;
|
|
1494
|
-
readonly tab?: PlacementTabPresentation;
|
|
1495
|
-
}
|
|
1496
|
-
interface PlacementContribution extends ContributionDefinition<"placement">, PlacementPresentation {
|
|
1497
|
-
readonly mode: ModeRef;
|
|
1498
|
-
readonly item: PlacementItem;
|
|
1499
|
-
readonly region: ExtensionPanelRegion;
|
|
1500
|
-
readonly order?: number;
|
|
1501
|
-
readonly movableTo?: readonly ExtensionPanelRegion[];
|
|
1502
|
-
}
|
|
1503
|
-
interface ViewMenuContribution extends ContributionDefinition<"view-menu"> {
|
|
1504
|
-
readonly owner: ViewRef;
|
|
1505
|
-
readonly view: ViewRef;
|
|
1506
|
-
readonly side: "left" | "right";
|
|
1507
|
-
readonly group?: string;
|
|
1508
|
-
readonly placement?: "first" | "default" | "last";
|
|
1509
|
-
readonly hostTreeHeader?: "default" | "none";
|
|
1510
|
-
readonly hostTreeFooter?: "default" | "none";
|
|
1511
|
-
}
|
|
1512
|
-
//#endregion
|
|
1513
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/pages.d.ts
|
|
1514
|
-
type PageSlotRole = "primary" | "auxiliary";
|
|
1515
|
-
type PageSlotCardinality = "one" | "many";
|
|
1516
|
-
type PageOpenIntent = "preview" | "pin";
|
|
1517
|
-
type PageSlotRegion = ExtensionPanelRegion;
|
|
1518
|
-
interface PageMainView extends PlacementPresentation {
|
|
1519
|
-
readonly kind: "view";
|
|
1520
|
-
readonly view: ViewRef;
|
|
1521
|
-
readonly cardinality: PageSlotCardinality;
|
|
1522
|
-
}
|
|
1523
|
-
interface PageMainPanels {
|
|
1524
|
-
readonly kind: "panels";
|
|
1525
|
-
readonly empty: ViewRef;
|
|
1526
|
-
}
|
|
1527
|
-
type PageMain = PageMainView | PageMainPanels;
|
|
1528
|
-
/** A page-owned panel. Main presentation and routed context belong to the page. */
|
|
1529
|
-
interface PageSlot extends PlacementPresentation {
|
|
1530
|
-
readonly id: string;
|
|
1531
|
-
readonly region: PageSlotRegion;
|
|
1532
|
-
readonly order?: number;
|
|
1533
|
-
readonly item: PlacementItem;
|
|
1534
|
-
readonly openOn?: "page-resource";
|
|
1535
|
-
}
|
|
1536
|
-
interface PageSlotRef {
|
|
1537
|
-
readonly kind: "page-slot";
|
|
1538
|
-
readonly page: PageRef;
|
|
1539
|
-
readonly id: string;
|
|
1540
|
-
}
|
|
1541
|
-
type PanelRef = PlacementRef | PageSlotRef;
|
|
1542
|
-
interface PageContribution extends ContributionDefinition<"page"> {
|
|
1543
|
-
readonly title: Localizable<string>;
|
|
1544
|
-
readonly icon?: string;
|
|
1545
|
-
readonly path: string;
|
|
1546
|
-
readonly mode: ModeRef;
|
|
1547
|
-
readonly parent?: PageRef;
|
|
1548
|
-
readonly resource?: ResourceConstraint;
|
|
1549
|
-
readonly main: PageMain;
|
|
1550
|
-
readonly slots: readonly PageSlot[];
|
|
1551
|
-
readonly panels: Readonly<Record<string, PageSlotRef>>;
|
|
1552
|
-
}
|
|
1553
|
-
type PlacementOwner = {
|
|
1554
|
-
readonly kind: "shell";
|
|
1555
|
-
readonly placementId: string;
|
|
1556
|
-
} | {
|
|
1557
|
-
readonly kind: "mode";
|
|
1558
|
-
readonly modeId: string;
|
|
1559
|
-
readonly placementId: string;
|
|
1560
|
-
} | {
|
|
1561
|
-
readonly kind: "page";
|
|
1562
|
-
readonly pageId: string;
|
|
1563
|
-
readonly slotId: string;
|
|
1564
|
-
};
|
|
1565
|
-
type PlacementIdentity = PlacementOwner & {
|
|
1566
|
-
readonly instanceKey: string;
|
|
1567
|
-
};
|
|
1568
|
-
interface PageLocation {
|
|
1569
|
-
readonly page: PageRef;
|
|
1570
|
-
readonly resource?: ResourceRef;
|
|
1571
|
-
readonly section?: FileRendererSectionTarget;
|
|
1572
|
-
readonly parent?: PageLocation;
|
|
1573
|
-
}
|
|
1574
|
-
//#endregion
|
|
1575
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/navigation-target.d.ts
|
|
1576
|
-
interface NavigationTargetPage {
|
|
1577
|
-
kind: "page";
|
|
1578
|
-
page: PageRef;
|
|
1579
|
-
resource?: ResourceRef;
|
|
1580
|
-
section?: FileRendererSectionTarget;
|
|
1581
|
-
open?: PageOpenIntent;
|
|
1582
|
-
parent?: NavigationTargetPage;
|
|
1583
|
-
}
|
|
1584
|
-
interface NavigationTargetPanel {
|
|
1585
|
-
kind: "panel";
|
|
1586
|
-
panel: PanelRef;
|
|
1587
|
-
resource?: ResourceRef;
|
|
1588
|
-
open?: PageOpenIntent;
|
|
1589
|
-
}
|
|
1590
|
-
interface NavigationTargetCommand {
|
|
1591
|
-
kind: "command";
|
|
1592
|
-
target: CommandTarget<JsonObject>;
|
|
1593
|
-
}
|
|
1594
|
-
interface NavigationTargetHref {
|
|
1595
|
-
kind: "href";
|
|
1596
|
-
href: string;
|
|
1597
|
-
}
|
|
1598
|
-
type NavigationTargetItem = NavigationTargetPage | NavigationTargetPanel | NavigationTargetCommand | NavigationTargetHref;
|
|
1599
|
-
interface NavigationTargetCompound {
|
|
1600
|
-
kind: "compound";
|
|
1601
|
-
targets: readonly (NavigationTargetPage | NavigationTargetPanel)[];
|
|
1602
|
-
}
|
|
1603
|
-
type NavigationTarget = NavigationTargetItem | NavigationTargetCompound;
|
|
1604
|
-
//#endregion
|
|
1605
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/commands.d.ts
|
|
1606
|
-
type CommandSource = "cli" | "dashboard" | "api" | "schedule" | "event" | "automation" | "command-panel";
|
|
1607
|
-
interface CommandRef<TParams extends Struct = Struct, TResult = unknown> extends ContributionRef<"command"> {
|
|
1608
|
-
params?: TParams;
|
|
1609
|
-
result?: TResult;
|
|
1610
|
-
}
|
|
1611
|
-
interface CommandTarget<TParams extends Struct = Struct> {
|
|
1612
|
-
command: CommandRef<TParams, unknown>;
|
|
1613
|
-
params?: TParams;
|
|
1614
|
-
}
|
|
1615
|
-
interface SerializedError {
|
|
1616
|
-
name?: string;
|
|
1617
|
-
message: string;
|
|
1618
|
-
stack?: string;
|
|
1619
|
-
cause?: JsonValue;
|
|
1620
|
-
}
|
|
1621
|
-
interface WorkbenchAttachmentInvocationContext {
|
|
1622
|
-
target: WorkbenchAttachmentTarget;
|
|
1623
|
-
mode?: string;
|
|
1624
|
-
projectId?: string;
|
|
1625
|
-
resource?: ResourceRef;
|
|
1626
|
-
}
|
|
1627
|
-
interface CommandInvocation<TParams extends Struct = Struct> {
|
|
1628
|
-
params: TParams;
|
|
1629
|
-
resource?: ResourceRef;
|
|
1630
|
-
attachment?: WorkbenchAttachmentInvocationContext;
|
|
1631
|
-
slot?: SlotInvocationContext;
|
|
1632
|
-
metadata?: JsonObject;
|
|
1633
|
-
}
|
|
1634
|
-
interface CommandContinue {
|
|
1635
|
-
type: "continue";
|
|
1636
|
-
}
|
|
1637
|
-
interface CommandPatchParams<TParams extends Struct = Struct> {
|
|
1638
|
-
type: "patchParams";
|
|
1639
|
-
params: Partial<TParams>;
|
|
1640
|
-
}
|
|
1641
|
-
interface CommandReplaceParams<TParams extends Struct = Struct> {
|
|
1642
|
-
type: "replaceParams";
|
|
1643
|
-
params: TParams;
|
|
1644
|
-
}
|
|
1645
|
-
interface CommandReplaceInvocation<TParams extends Struct = Struct> {
|
|
1646
|
-
type: "replaceInvocation";
|
|
1647
|
-
invocation: CommandInvocation<TParams>;
|
|
1648
|
-
}
|
|
1649
|
-
interface CommandReject {
|
|
1650
|
-
type: "reject";
|
|
1651
|
-
code?: string;
|
|
1652
|
-
reason: string;
|
|
1653
|
-
data?: JsonObject;
|
|
1654
|
-
}
|
|
1655
|
-
type CommandMiddlewareResult<TParams extends Struct = Struct> = void | CommandContinue | CommandPatchParams<TParams> | CommandReplaceParams<TParams> | CommandReplaceInvocation<TParams> | CommandReject;
|
|
1656
|
-
interface CommandNotice {
|
|
1657
|
-
type: "info" | "success" | "warning" | "error";
|
|
1658
|
-
title?: string;
|
|
1659
|
-
message: string;
|
|
1660
|
-
metadata?: JsonObject;
|
|
1661
|
-
}
|
|
1662
|
-
interface CommandDiagnostic {
|
|
1663
|
-
code: string;
|
|
1664
|
-
message: string;
|
|
1665
|
-
severity: "info" | "warning" | "error";
|
|
1666
|
-
extensionId?: string;
|
|
1667
|
-
commandId?: string;
|
|
1668
|
-
metadata?: JsonObject;
|
|
1669
|
-
}
|
|
1670
|
-
type CommandOutcome<TResult = unknown> = {
|
|
1671
|
-
ok: true;
|
|
1672
|
-
status: "success";
|
|
1673
|
-
value: TResult;
|
|
1674
|
-
navigationRequests?: NavigationTarget[];
|
|
1675
|
-
notices?: CommandNotice[];
|
|
1676
|
-
diagnostics?: CommandDiagnostic[];
|
|
1677
|
-
} | {
|
|
1678
|
-
ok: false;
|
|
1679
|
-
status: "rejected";
|
|
1680
|
-
code?: string;
|
|
1681
|
-
reason: string;
|
|
1682
|
-
data?: JsonObject;
|
|
1683
|
-
notices?: CommandNotice[];
|
|
1684
|
-
diagnostics?: CommandDiagnostic[];
|
|
1685
|
-
} | {
|
|
1686
|
-
ok: false;
|
|
1687
|
-
status: "error";
|
|
1688
|
-
code?: string;
|
|
1689
|
-
reason: string;
|
|
1690
|
-
error?: SerializedError;
|
|
1691
|
-
notices?: CommandNotice[];
|
|
1692
|
-
diagnostics?: CommandDiagnostic[];
|
|
1693
|
-
};
|
|
1694
|
-
interface CommandHelpersApi {
|
|
1695
|
-
execute<TParams extends Struct = Struct, TResult = unknown>(command: CommandRef<TParams, TResult>, invocation: CommandInvocation<TParams>): Promise<CommandOutcome<TResult>>;
|
|
1696
|
-
continue(): CommandContinue;
|
|
1697
|
-
patchParams<TParams extends Struct = Struct>(params: Partial<TParams>): CommandPatchParams<TParams>;
|
|
1698
|
-
replaceParams<TParams extends Struct = Struct>(params: TParams): CommandReplaceParams<TParams>;
|
|
1699
|
-
replaceInvocation<TParams extends Struct = Struct>(invocation: CommandInvocation<TParams>): CommandReplaceInvocation<TParams>;
|
|
1700
|
-
reject(input: Omit<CommandReject, "type">): CommandReject;
|
|
1701
|
-
}
|
|
1702
|
-
interface CommandRequestedEvent<TParams extends Struct = Struct> {
|
|
1703
|
-
commandId: string;
|
|
1704
|
-
invocationId: string;
|
|
1705
|
-
source?: CommandSource;
|
|
1706
|
-
params: TParams;
|
|
1707
|
-
resource?: ResourceRef;
|
|
1708
|
-
}
|
|
1709
|
-
interface CommandStartedEvent<TParams extends Struct = Struct> extends CommandRequestedEvent<TParams> {}
|
|
1710
|
-
interface CommandCompletedEvent<TParams extends Struct = Struct, TResult = unknown> extends CommandStartedEvent<TParams> {
|
|
1711
|
-
result: TResult;
|
|
1712
|
-
elapsedMs: number;
|
|
1713
|
-
}
|
|
1714
|
-
interface CommandRejectedEvent<TParams extends Struct = Struct> extends CommandRequestedEvent<TParams> {
|
|
1715
|
-
code?: string;
|
|
1716
|
-
reason: string;
|
|
1717
|
-
data?: JsonObject;
|
|
1718
|
-
}
|
|
1719
|
-
interface CommandFailedEvent<TParams extends Struct = Struct> extends CommandRequestedEvent<TParams> {
|
|
1720
|
-
code?: string;
|
|
1721
|
-
reason: string;
|
|
1722
|
-
error?: SerializedError;
|
|
1723
|
-
elapsedMs: number;
|
|
1724
|
-
}
|
|
1725
|
-
type CommandLifecyclePhase = "requested" | "started" | "completed" | "rejected" | "failed";
|
|
1726
|
-
type CommandLifecycleEventPayload<TPhase extends CommandLifecyclePhase, TParams extends Struct = Struct, TResult = unknown> = TPhase extends "requested" ? CommandRequestedEvent<TParams> : TPhase extends "started" ? CommandStartedEvent<TParams> : TPhase extends "completed" ? CommandCompletedEvent<TParams, TResult> : TPhase extends "rejected" ? CommandRejectedEvent<TParams> : CommandFailedEvent<TParams>;
|
|
1727
|
-
//#endregion
|
|
1728
|
-
//#region ../pstdio-api-contracts/src/notifications/types.d.ts
|
|
1729
|
-
type NotificationKind = "needs_review" | "ready_to_merge" | "blocked" | "approval_required" | "failed" | "info";
|
|
1730
|
-
type NotificationStatus = "open" | "read" | "snoozed" | "done" | "dismissed" | "expired";
|
|
1731
|
-
type NotificationPriority = "low" | "normal" | "high" | "urgent";
|
|
1732
|
-
type NotificationActorType = "user" | "agent" | "system";
|
|
1733
|
-
type NotificationOrigin = "core" | "extension" | "agent";
|
|
1734
|
-
type NotificationAction = {
|
|
1735
|
-
id: string;
|
|
1736
|
-
label: string;
|
|
1737
|
-
kind: "navigate";
|
|
1738
|
-
target: NavigationTarget;
|
|
1739
|
-
primary?: boolean;
|
|
1740
|
-
} | {
|
|
1741
|
-
id: string;
|
|
1742
|
-
label: string;
|
|
1743
|
-
kind: "command";
|
|
1744
|
-
command: string;
|
|
1745
|
-
params?: JsonObject;
|
|
1746
|
-
primary?: boolean;
|
|
1747
|
-
destructive?: boolean;
|
|
1748
|
-
} | {
|
|
1749
|
-
id: string;
|
|
1750
|
-
label: string;
|
|
1751
|
-
kind: "url";
|
|
1752
|
-
href: string;
|
|
1753
|
-
primary?: boolean;
|
|
1754
|
-
};
|
|
1755
|
-
interface Notification {
|
|
1756
|
-
id: string;
|
|
1757
|
-
projectId: string;
|
|
1758
|
-
title: string;
|
|
1759
|
-
body?: string | null;
|
|
1760
|
-
kind: NotificationKind;
|
|
1761
|
-
status: NotificationStatus;
|
|
1762
|
-
priority: NotificationPriority;
|
|
1763
|
-
source: CommandSource;
|
|
1764
|
-
origin: NotificationOrigin;
|
|
1765
|
-
sourceExtensionId?: string | null;
|
|
1766
|
-
actorType?: NotificationActorType | null;
|
|
1767
|
-
actorId?: string | null;
|
|
1768
|
-
target?: ResourceRef | null;
|
|
1769
|
-
related: ResourceRef[];
|
|
1770
|
-
actions: NotificationAction[];
|
|
1771
|
-
dedupeKey?: string | null;
|
|
1772
|
-
metadata?: JsonObject | null;
|
|
1773
|
-
createdAt: string;
|
|
1774
|
-
updatedAt: string;
|
|
1775
|
-
readAt?: string | null;
|
|
1776
|
-
resolvedAt?: string | null;
|
|
1777
|
-
snoozedUntil?: string | null;
|
|
1778
|
-
expiresAt?: string | null;
|
|
1779
|
-
}
|
|
1780
|
-
interface CreateNotificationInput {
|
|
1781
|
-
projectId: string;
|
|
1782
|
-
title: string;
|
|
1783
|
-
body?: string;
|
|
1784
|
-
kind: NotificationKind;
|
|
1785
|
-
priority?: NotificationPriority;
|
|
1786
|
-
target?: ResourceRef;
|
|
1787
|
-
related?: ResourceRef[];
|
|
1788
|
-
actions?: NotificationAction[];
|
|
1789
|
-
dedupeKey?: string;
|
|
1790
|
-
expiresAt?: string;
|
|
1791
|
-
snoozedUntil?: string;
|
|
1792
|
-
metadata?: JsonObject;
|
|
1793
|
-
}
|
|
1794
|
-
interface UpdateNotificationInput {
|
|
1795
|
-
priority?: NotificationPriority;
|
|
1796
|
-
snoozedUntil?: string | null;
|
|
1797
|
-
metadata?: JsonObject;
|
|
1798
|
-
}
|
|
1799
|
-
interface ListNotificationsQuery {
|
|
1800
|
-
status?: NotificationStatus | NotificationStatus[];
|
|
1801
|
-
priority?: NotificationPriority | NotificationPriority[];
|
|
1802
|
-
sourceExtensionId?: string;
|
|
1803
|
-
resourceType?: string;
|
|
1804
|
-
resourceId?: string;
|
|
1805
|
-
cursor?: string;
|
|
1806
|
-
limit?: number;
|
|
1807
|
-
}
|
|
1808
|
-
interface ListNotificationsResponse {
|
|
1809
|
-
items: Notification[];
|
|
1810
|
-
nextCursor?: string | null;
|
|
410
|
+
interface ListNotificationsResponse {
|
|
411
|
+
items: Notification[];
|
|
412
|
+
nextCursor?: string | null;
|
|
1811
413
|
}
|
|
1812
414
|
//#endregion
|
|
1813
415
|
//#region ../pstdio-api-contracts/src/sessions.d.ts
|
|
@@ -1898,6 +500,7 @@ declare const followUpInputSchema: z.ZodObject<{
|
|
|
1898
500
|
model: z.ZodOptional<z.ZodString>;
|
|
1899
501
|
question_response: z.ZodOptional<z.ZodObject<{
|
|
1900
502
|
answers: z.ZodArray<z.ZodArray<z.ZodString>>;
|
|
503
|
+
callId: z.ZodOptional<z.ZodString>;
|
|
1901
504
|
}, z.core.$strip>>;
|
|
1902
505
|
params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodBoolean]>>>;
|
|
1903
506
|
summary_from_session_id: z.ZodOptional<z.ZodString>;
|
|
@@ -1966,8 +569,8 @@ declare const sessionQueuedMessagesResponseSchema: z.ZodObject<{
|
|
|
1966
569
|
messages: z.ZodArray<z.ZodObject<{
|
|
1967
570
|
id: z.ZodString;
|
|
1968
571
|
role: z.ZodEnum<{
|
|
1969
|
-
assistant: "assistant";
|
|
1970
572
|
user: "user";
|
|
573
|
+
assistant: "assistant";
|
|
1971
574
|
tool: "tool";
|
|
1972
575
|
system: "system";
|
|
1973
576
|
developer: "developer";
|
|
@@ -2061,8 +664,8 @@ declare const sessionConversationSourcesSchema: z.ZodObject<{
|
|
|
2061
664
|
checkpoint: z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
2062
665
|
id: z.ZodString;
|
|
2063
666
|
role: z.ZodEnum<{
|
|
2064
|
-
assistant: "assistant";
|
|
2065
667
|
user: "user";
|
|
668
|
+
assistant: "assistant";
|
|
2066
669
|
tool: "tool";
|
|
2067
670
|
system: "system";
|
|
2068
671
|
developer: "developer";
|
|
@@ -2153,8 +756,8 @@ declare const sessionConversationSourcesSchema: z.ZodObject<{
|
|
|
2153
756
|
native: z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
2154
757
|
id: z.ZodString;
|
|
2155
758
|
role: z.ZodEnum<{
|
|
2156
|
-
assistant: "assistant";
|
|
2157
759
|
user: "user";
|
|
760
|
+
assistant: "assistant";
|
|
2158
761
|
tool: "tool";
|
|
2159
762
|
system: "system";
|
|
2160
763
|
developer: "developer";
|
|
@@ -2286,8 +889,8 @@ declare const sessionConversationResponseSchema: z.ZodObject<{
|
|
|
2286
889
|
messages: z.ZodArray<z.ZodObject<{
|
|
2287
890
|
id: z.ZodString;
|
|
2288
891
|
role: z.ZodEnum<{
|
|
2289
|
-
assistant: "assistant";
|
|
2290
892
|
user: "user";
|
|
893
|
+
assistant: "assistant";
|
|
2291
894
|
tool: "tool";
|
|
2292
895
|
system: "system";
|
|
2293
896
|
developer: "developer";
|
|
@@ -2400,8 +1003,8 @@ declare const listSessionActivityResponseSchema: z.ZodObject<{
|
|
|
2400
1003
|
source_extension_id: z.ZodNullable<z.ZodString>;
|
|
2401
1004
|
event_type: z.ZodString;
|
|
2402
1005
|
actor_type: z.ZodEnum<{
|
|
2403
|
-
agent: "agent";
|
|
2404
1006
|
user: "user";
|
|
1007
|
+
agent: "agent";
|
|
2405
1008
|
system: "system";
|
|
2406
1009
|
}>;
|
|
2407
1010
|
actor_id: z.ZodNullable<z.ZodString>;
|
|
@@ -2432,395 +1035,1685 @@ type ListSessionActivityInput = z.infer<typeof listSessionActivityInputSchema>;
|
|
|
2432
1035
|
type ListSessionActivityResponse = z.infer<typeof listSessionActivityResponseSchema>;
|
|
2433
1036
|
type FollowUpResponse = z.infer<typeof followUpResponseSchema>;
|
|
2434
1037
|
//#endregion
|
|
2435
|
-
//#region ../pstdio-api-contracts/src/skills.d.ts
|
|
2436
|
-
declare const skillFileSchema: z.ZodObject<{
|
|
2437
|
-
path: z.ZodString;
|
|
2438
|
-
content: z.ZodString;
|
|
2439
|
-
encoding: z.ZodLiteral<"utf8">;
|
|
2440
|
-
}, z.core.$strip>;
|
|
2441
|
-
declare const skillSchema: z.ZodObject<{
|
|
2442
|
-
id: z.ZodString;
|
|
2443
|
-
project_id: z.ZodString;
|
|
2444
|
-
name: z.ZodString;
|
|
2445
|
-
title: z.ZodString;
|
|
2446
|
-
description: z.ZodString;
|
|
2447
|
-
source_kind: z.ZodEnum<{
|
|
2448
|
-
project: "project";
|
|
2449
|
-
extension: "extension";
|
|
2450
|
-
}>;
|
|
2451
|
-
files: z.ZodArray<z.ZodObject<{
|
|
2452
|
-
path: z.ZodString;
|
|
2453
|
-
content: z.ZodString;
|
|
2454
|
-
encoding: z.ZodLiteral<"utf8">;
|
|
2455
|
-
}, z.core.$strip>>;
|
|
2456
|
-
editable: z.ZodBoolean;
|
|
2457
|
-
extension_instance_id: z.ZodOptional<z.ZodString>;
|
|
2458
|
-
extension_id: z.ZodOptional<z.ZodString>;
|
|
2459
|
-
installed_extension_id: z.ZodOptional<z.ZodString>;
|
|
2460
|
-
install_name: z.ZodOptional<z.ZodString>;
|
|
2461
|
-
key: z.ZodOptional<z.ZodString>;
|
|
2462
|
-
source: z.ZodOptional<z.ZodObject<{
|
|
2463
|
-
kind: z.ZodLiteral<"package-asset">;
|
|
2464
|
-
path: z.ZodString;
|
|
2465
|
-
baseUrl: z.ZodString;
|
|
2466
|
-
}, z.core.$strip>>;
|
|
2467
|
-
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
2468
|
-
created_at: z.ZodString;
|
|
2469
|
-
updated_at: z.ZodString;
|
|
2470
|
-
deleted_at: z.ZodNullable<z.ZodString>;
|
|
2471
|
-
}, z.core.$strip>;
|
|
2472
|
-
declare const skillWithContentSchema: z.ZodObject<{
|
|
2473
|
-
id: z.ZodString;
|
|
2474
|
-
project_id: z.ZodString;
|
|
2475
|
-
name: z.ZodString;
|
|
2476
|
-
title: z.ZodString;
|
|
2477
|
-
description: z.ZodString;
|
|
2478
|
-
source_kind: z.ZodEnum<{
|
|
2479
|
-
project: "project";
|
|
2480
|
-
extension: "extension";
|
|
2481
|
-
}>;
|
|
2482
|
-
files: z.ZodArray<z.ZodObject<{
|
|
2483
|
-
path: z.ZodString;
|
|
2484
|
-
content: z.ZodString;
|
|
2485
|
-
encoding: z.ZodLiteral<"utf8">;
|
|
2486
|
-
}, z.core.$strip>>;
|
|
2487
|
-
editable: z.ZodBoolean;
|
|
2488
|
-
extension_instance_id: z.ZodOptional<z.ZodString>;
|
|
2489
|
-
extension_id: z.ZodOptional<z.ZodString>;
|
|
2490
|
-
installed_extension_id: z.ZodOptional<z.ZodString>;
|
|
2491
|
-
install_name: z.ZodOptional<z.ZodString>;
|
|
2492
|
-
key: z.ZodOptional<z.ZodString>;
|
|
2493
|
-
source: z.ZodOptional<z.ZodObject<{
|
|
2494
|
-
kind: z.ZodLiteral<"package-asset">;
|
|
2495
|
-
path: z.ZodString;
|
|
2496
|
-
baseUrl: z.ZodString;
|
|
2497
|
-
}, z.core.$strip>>;
|
|
2498
|
-
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
2499
|
-
created_at: z.ZodString;
|
|
2500
|
-
updated_at: z.ZodString;
|
|
2501
|
-
deleted_at: z.ZodNullable<z.ZodString>;
|
|
2502
|
-
installed_agents: z.ZodArray<z.ZodString>;
|
|
2503
|
-
outdated_agents: z.ZodArray<z.ZodString>;
|
|
2504
|
-
agent_installations: z.ZodArray<z.ZodObject<{
|
|
2505
|
-
agent_id: z.ZodString;
|
|
2506
|
-
agent_name: z.ZodString;
|
|
2507
|
-
installed_version: z.ZodNullable<z.ZodString>;
|
|
2508
|
-
outdated: z.ZodBoolean;
|
|
2509
|
-
}, z.core.$strip>>;
|
|
2510
|
-
}, z.core.$strip>;
|
|
2511
|
-
declare const updateSkillInputSchema: z.ZodObject<{
|
|
2512
|
-
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
2513
|
-
title: z.ZodOptional<z.ZodString>;
|
|
2514
|
-
description: z.ZodOptional<z.ZodString>;
|
|
2515
|
-
}, z.core.$strip>;
|
|
2516
|
-
type Skill = z.infer<typeof skillSchema>;
|
|
2517
|
-
type SkillWithContent = z.infer<typeof skillWithContentSchema>;
|
|
2518
|
-
type SkillFile = z.infer<typeof skillFileSchema>;
|
|
2519
|
-
type UpdateSkillInput = z.infer<typeof updateSkillInputSchema>;
|
|
1038
|
+
//#region ../pstdio-api-contracts/src/skills.d.ts
|
|
1039
|
+
declare const skillFileSchema: z.ZodObject<{
|
|
1040
|
+
path: z.ZodString;
|
|
1041
|
+
content: z.ZodString;
|
|
1042
|
+
encoding: z.ZodLiteral<"utf8">;
|
|
1043
|
+
}, z.core.$strip>;
|
|
1044
|
+
declare const skillSchema: z.ZodObject<{
|
|
1045
|
+
id: z.ZodString;
|
|
1046
|
+
project_id: z.ZodString;
|
|
1047
|
+
name: z.ZodString;
|
|
1048
|
+
title: z.ZodString;
|
|
1049
|
+
description: z.ZodString;
|
|
1050
|
+
source_kind: z.ZodEnum<{
|
|
1051
|
+
project: "project";
|
|
1052
|
+
extension: "extension";
|
|
1053
|
+
}>;
|
|
1054
|
+
files: z.ZodArray<z.ZodObject<{
|
|
1055
|
+
path: z.ZodString;
|
|
1056
|
+
content: z.ZodString;
|
|
1057
|
+
encoding: z.ZodLiteral<"utf8">;
|
|
1058
|
+
}, z.core.$strip>>;
|
|
1059
|
+
editable: z.ZodBoolean;
|
|
1060
|
+
extension_instance_id: z.ZodOptional<z.ZodString>;
|
|
1061
|
+
extension_id: z.ZodOptional<z.ZodString>;
|
|
1062
|
+
installed_extension_id: z.ZodOptional<z.ZodString>;
|
|
1063
|
+
install_name: z.ZodOptional<z.ZodString>;
|
|
1064
|
+
key: z.ZodOptional<z.ZodString>;
|
|
1065
|
+
source: z.ZodOptional<z.ZodObject<{
|
|
1066
|
+
kind: z.ZodLiteral<"package-asset">;
|
|
1067
|
+
path: z.ZodString;
|
|
1068
|
+
baseUrl: z.ZodString;
|
|
1069
|
+
}, z.core.$strip>>;
|
|
1070
|
+
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
1071
|
+
created_at: z.ZodString;
|
|
1072
|
+
updated_at: z.ZodString;
|
|
1073
|
+
deleted_at: z.ZodNullable<z.ZodString>;
|
|
1074
|
+
}, z.core.$strip>;
|
|
1075
|
+
declare const skillWithContentSchema: z.ZodObject<{
|
|
1076
|
+
id: z.ZodString;
|
|
1077
|
+
project_id: z.ZodString;
|
|
1078
|
+
name: z.ZodString;
|
|
1079
|
+
title: z.ZodString;
|
|
1080
|
+
description: z.ZodString;
|
|
1081
|
+
source_kind: z.ZodEnum<{
|
|
1082
|
+
project: "project";
|
|
1083
|
+
extension: "extension";
|
|
1084
|
+
}>;
|
|
1085
|
+
files: z.ZodArray<z.ZodObject<{
|
|
1086
|
+
path: z.ZodString;
|
|
1087
|
+
content: z.ZodString;
|
|
1088
|
+
encoding: z.ZodLiteral<"utf8">;
|
|
1089
|
+
}, z.core.$strip>>;
|
|
1090
|
+
editable: z.ZodBoolean;
|
|
1091
|
+
extension_instance_id: z.ZodOptional<z.ZodString>;
|
|
1092
|
+
extension_id: z.ZodOptional<z.ZodString>;
|
|
1093
|
+
installed_extension_id: z.ZodOptional<z.ZodString>;
|
|
1094
|
+
install_name: z.ZodOptional<z.ZodString>;
|
|
1095
|
+
key: z.ZodOptional<z.ZodString>;
|
|
1096
|
+
source: z.ZodOptional<z.ZodObject<{
|
|
1097
|
+
kind: z.ZodLiteral<"package-asset">;
|
|
1098
|
+
path: z.ZodString;
|
|
1099
|
+
baseUrl: z.ZodString;
|
|
1100
|
+
}, z.core.$strip>>;
|
|
1101
|
+
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
1102
|
+
created_at: z.ZodString;
|
|
1103
|
+
updated_at: z.ZodString;
|
|
1104
|
+
deleted_at: z.ZodNullable<z.ZodString>;
|
|
1105
|
+
installed_agents: z.ZodArray<z.ZodString>;
|
|
1106
|
+
outdated_agents: z.ZodArray<z.ZodString>;
|
|
1107
|
+
agent_installations: z.ZodArray<z.ZodObject<{
|
|
1108
|
+
agent_id: z.ZodString;
|
|
1109
|
+
agent_name: z.ZodString;
|
|
1110
|
+
installed_version: z.ZodNullable<z.ZodString>;
|
|
1111
|
+
outdated: z.ZodBoolean;
|
|
1112
|
+
}, z.core.$strip>>;
|
|
1113
|
+
}, z.core.$strip>;
|
|
1114
|
+
declare const updateSkillInputSchema: z.ZodObject<{
|
|
1115
|
+
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
1116
|
+
title: z.ZodOptional<z.ZodString>;
|
|
1117
|
+
description: z.ZodOptional<z.ZodString>;
|
|
1118
|
+
}, z.core.$strip>;
|
|
1119
|
+
type Skill = z.infer<typeof skillSchema>;
|
|
1120
|
+
type SkillWithContent = z.infer<typeof skillWithContentSchema>;
|
|
1121
|
+
type SkillFile = z.infer<typeof skillFileSchema>;
|
|
1122
|
+
type UpdateSkillInput = z.infer<typeof updateSkillInputSchema>;
|
|
1123
|
+
//#endregion
|
|
1124
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/automation.d.ts
|
|
1125
|
+
interface ExtensionAutomationApi {
|
|
1126
|
+
/** Enqueue a command owned by this extension and declared automation: true. */
|
|
1127
|
+
enqueue(input: {
|
|
1128
|
+
command: CommandRef | string;
|
|
1129
|
+
input: CreateAutomationRunInput["input"];
|
|
1130
|
+
/** Required idempotency key, at most 200 characters. */
|
|
1131
|
+
key: string;
|
|
1132
|
+
}): Promise<AutomationRun>;
|
|
1133
|
+
get(runId: string): Promise<AutomationRun | undefined>;
|
|
1134
|
+
list(filter?: {
|
|
1135
|
+
status?: AutomationRunStatus[];
|
|
1136
|
+
}): Promise<AutomationRun[]>;
|
|
1137
|
+
cancel(runId: string): Promise<AutomationRun>;
|
|
1138
|
+
}
|
|
1139
|
+
//#endregion
|
|
1140
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/connections.d.ts
|
|
1141
|
+
type ExtensionConnectionMethod = "GET" | "POST" | "PUT" | "PATCH" | "DELETE";
|
|
1142
|
+
interface ExtensionConnectionRequest {
|
|
1143
|
+
method: ExtensionConnectionMethod;
|
|
1144
|
+
path: string;
|
|
1145
|
+
headers?: Record<string, string>;
|
|
1146
|
+
body?: JsonValue;
|
|
1147
|
+
timeoutMs?: number;
|
|
1148
|
+
signal?: AbortSignal;
|
|
1149
|
+
}
|
|
1150
|
+
interface ExtensionConnectionResponse<TBody = JsonValue> {
|
|
1151
|
+
status: number;
|
|
1152
|
+
headers: Record<string, string>;
|
|
1153
|
+
body: TBody;
|
|
1154
|
+
}
|
|
1155
|
+
type ExtensionConnectionStreamEvent = {
|
|
1156
|
+
type: "response";
|
|
1157
|
+
status: number;
|
|
1158
|
+
headers: Record<string, string>;
|
|
1159
|
+
} | {
|
|
1160
|
+
type: "data";
|
|
1161
|
+
data: Uint8Array;
|
|
1162
|
+
} | {
|
|
1163
|
+
type: "end";
|
|
1164
|
+
};
|
|
1165
|
+
interface ExtensionConnectionsApi {
|
|
1166
|
+
request<TBody = JsonValue>(connectionId: string, input: ExtensionConnectionRequest): Promise<ExtensionConnectionResponse<TBody>>;
|
|
1167
|
+
stream(connectionId: string, input: ExtensionConnectionRequest): AsyncIterable<ExtensionConnectionStreamEvent>;
|
|
1168
|
+
}
|
|
1169
|
+
interface ExtensionLoggerApi {
|
|
1170
|
+
info(message: string, metadata?: JsonObject): void;
|
|
1171
|
+
warn(message: string, metadata?: JsonObject): void;
|
|
1172
|
+
error(message: string, metadata?: JsonObject): void;
|
|
1173
|
+
}
|
|
1174
|
+
//#endregion
|
|
1175
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/events.d.ts
|
|
1176
|
+
interface EventRef<TPayload extends Struct = Struct> {
|
|
1177
|
+
readonly extensionId?: string;
|
|
1178
|
+
readonly kind: "event";
|
|
1179
|
+
readonly id: string;
|
|
1180
|
+
payload?: TPayload;
|
|
1181
|
+
}
|
|
1182
|
+
interface EventDeliveryResult {
|
|
1183
|
+
delivered: number;
|
|
1184
|
+
diagnostics?: CommandDiagnostic[];
|
|
1185
|
+
}
|
|
1186
|
+
//#endregion
|
|
1187
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/slots.d.ts
|
|
1188
|
+
type UiSlotKind = "menu" | "panel" | "settings" | "renderer" | "kanbanRenderer" | "dataTableRenderer";
|
|
1189
|
+
interface SlotOptions<TKind extends UiSlotKind = UiSlotKind> {
|
|
1190
|
+
kind: TKind;
|
|
1191
|
+
label?: string;
|
|
1192
|
+
description?: string;
|
|
1193
|
+
metadata?: JsonObject;
|
|
1194
|
+
}
|
|
1195
|
+
interface SlotRef<TContext extends Struct = Struct, TKind extends UiSlotKind = UiSlotKind> {
|
|
1196
|
+
id: string;
|
|
1197
|
+
kind: TKind;
|
|
1198
|
+
label?: string;
|
|
1199
|
+
description?: string;
|
|
1200
|
+
metadata?: JsonObject;
|
|
1201
|
+
/** Phantom field used to constrain compatible contributions; never populated at runtime. */
|
|
1202
|
+
context?: TContext;
|
|
1203
|
+
}
|
|
1204
|
+
interface SlotInvocationContext<TContext extends Struct = Struct> {
|
|
1205
|
+
id: string;
|
|
1206
|
+
kind: UiSlotKind;
|
|
1207
|
+
context: TContext;
|
|
1208
|
+
}
|
|
1209
|
+
//#endregion
|
|
1210
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/renderer-base.d.ts
|
|
1211
|
+
/** A raw cross-extension id must be namespaced. Local events use an EventRef. */
|
|
1212
|
+
type RendererEventReference = EventRef | `${string}.${string}`;
|
|
1213
|
+
interface RendererContributionBase {
|
|
1214
|
+
title: Localizable<string>;
|
|
1215
|
+
icon?: string;
|
|
1216
|
+
resourceKind?: string;
|
|
1217
|
+
refreshEvents?: readonly RendererEventReference[];
|
|
1218
|
+
emptyTitle?: Localizable<string>;
|
|
1219
|
+
emptyDescription?: Localizable<string>;
|
|
1220
|
+
}
|
|
1221
|
+
//#endregion
|
|
1222
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/webview-capabilities.d.ts
|
|
1223
|
+
declare const WEBVIEW_HOST_CAPABILITY_VERSION = 1;
|
|
1224
|
+
declare const WEBVIEW_DECLARABLE_CAPABILITIES: readonly ["clipboard.write", "commands.execute", "navigation.open", "placement.close", "notification.show", "notification.action", "notification.resolve", "notification.dismiss", "preferences.get", "preferences.set", "extension.settings.all", "extension.settings.get", "extension.settings.set", "extension.settings.delete", "terminal.session", "files.upload", "files.list", "files.delete"];
|
|
1225
|
+
declare const WEBVIEW_SCOPED_DECLARABLE_CAPABILITIES: readonly ["artifacts.read"];
|
|
1226
|
+
declare const ALWAYS_AVAILABLE_WEBVIEW_CAPABILITIES: readonly ["host.dispatchKeyboardEvent"];
|
|
1227
|
+
declare const WEBVIEW_HOST_CAPABILITIES: readonly [...("commands.execute" | "navigation.open" | "placement.close" | "notification.show" | "notification.action" | "notification.resolve" | "notification.dismiss" | "preferences.get" | "preferences.set" | "extension.settings.all" | "extension.settings.get" | "extension.settings.set" | "extension.settings.delete" | "terminal.session" | "files.upload" | "files.list" | "files.delete")[], "artifacts.read", "host.dispatchKeyboardEvent"];
|
|
1228
|
+
type WebviewHostCapability = (typeof WEBVIEW_HOST_CAPABILITIES)[number];
|
|
1229
|
+
type WebviewDeclarableCapability = (typeof WEBVIEW_DECLARABLE_CAPABILITIES)[number];
|
|
1230
|
+
type WebviewScopedDeclarableCapability = (typeof WEBVIEW_SCOPED_DECLARABLE_CAPABILITIES)[number];
|
|
1231
|
+
type WebviewCapabilityDeclaration = WebviewDeclarableCapability | `${WebviewDeclarableCapability}@${typeof WEBVIEW_HOST_CAPABILITY_VERSION}` | `${WebviewScopedDeclarableCapability}:${string}`;
|
|
1232
|
+
interface WebviewCommandsExecuteParams {
|
|
1233
|
+
commandId: string;
|
|
1234
|
+
params?: JsonObject;
|
|
1235
|
+
workspaceId?: string;
|
|
1236
|
+
resource?: ResourceRef;
|
|
1237
|
+
metadata?: JsonObject;
|
|
1238
|
+
}
|
|
1239
|
+
interface WebviewNavigationOpenParams {
|
|
1240
|
+
target: NavigationTarget;
|
|
1241
|
+
}
|
|
1242
|
+
interface WebviewNotificationShowParams {
|
|
1243
|
+
level: "info" | "success" | "warning" | "error";
|
|
1244
|
+
title: string;
|
|
1245
|
+
message?: string;
|
|
1246
|
+
}
|
|
1247
|
+
type WebviewNotificationActionParams = Omit<CreateNotificationInput, "projectId">;
|
|
1248
|
+
interface WebviewNotificationResolveParams {
|
|
1249
|
+
id?: string;
|
|
1250
|
+
dedupeKey?: string;
|
|
1251
|
+
status?: Extract<NotificationStatus, "done" | "dismissed" | "expired">;
|
|
1252
|
+
}
|
|
1253
|
+
type WebviewNotificationDismissParams = Pick<WebviewNotificationResolveParams, "id" | "dedupeKey">;
|
|
1254
|
+
interface WebviewPreferencesGetParams {
|
|
1255
|
+
name: string;
|
|
1256
|
+
scope?: {
|
|
1257
|
+
scope: "default" | "user" | "project" | "workspace" | "extension" | "session";
|
|
1258
|
+
scopeId?: string;
|
|
1259
|
+
};
|
|
1260
|
+
}
|
|
1261
|
+
interface WebviewPreferencesSetParams extends WebviewPreferencesGetParams {
|
|
1262
|
+
value: boolean | number | string | string[] | number[] | boolean[] | Record<string, unknown>;
|
|
1263
|
+
}
|
|
1264
|
+
interface WebviewExtensionSettingKeyParams {
|
|
1265
|
+
key: string;
|
|
1266
|
+
}
|
|
1267
|
+
interface WebviewExtensionSettingSetParams extends WebviewExtensionSettingKeyParams {
|
|
1268
|
+
value: unknown;
|
|
1269
|
+
}
|
|
1270
|
+
type WebviewFileScope = {
|
|
1271
|
+
type: "project";
|
|
1272
|
+
} | {
|
|
1273
|
+
type: "resource";
|
|
1274
|
+
id: string;
|
|
1275
|
+
} | {
|
|
1276
|
+
type: string;
|
|
1277
|
+
id?: string;
|
|
1278
|
+
};
|
|
1279
|
+
interface WebviewFilesUploadParams {
|
|
1280
|
+
name: string;
|
|
1281
|
+
data: Uint8Array | ArrayBuffer;
|
|
1282
|
+
mimeType?: string;
|
|
1283
|
+
scope?: WebviewFileScope;
|
|
1284
|
+
}
|
|
1285
|
+
interface WebviewFilesListParams {
|
|
1286
|
+
scope?: WebviewFileScope;
|
|
1287
|
+
}
|
|
1288
|
+
interface WebviewFilesDeleteParams {
|
|
1289
|
+
id: string;
|
|
1290
|
+
}
|
|
1291
|
+
type WebviewArtifactsReadParams = {
|
|
1292
|
+
op: "list";
|
|
1293
|
+
mount: string;
|
|
1294
|
+
prefix?: string;
|
|
1295
|
+
} | {
|
|
1296
|
+
op: "readText";
|
|
1297
|
+
mount: string;
|
|
1298
|
+
path: string;
|
|
1299
|
+
} | {
|
|
1300
|
+
op: "imageUrl";
|
|
1301
|
+
mount: string;
|
|
1302
|
+
path: string;
|
|
1303
|
+
};
|
|
1304
|
+
interface WebviewArtifactFile {
|
|
1305
|
+
path: string;
|
|
1306
|
+
size: number;
|
|
1307
|
+
mediaType: string;
|
|
1308
|
+
}
|
|
1309
|
+
interface WebviewKeyboardEventParams {
|
|
1310
|
+
key?: string;
|
|
1311
|
+
code?: string;
|
|
1312
|
+
ctrlKey?: boolean;
|
|
1313
|
+
metaKey?: boolean;
|
|
1314
|
+
altKey?: boolean;
|
|
1315
|
+
shiftKey?: boolean;
|
|
1316
|
+
repeat?: boolean;
|
|
1317
|
+
}
|
|
1318
|
+
interface WebviewHostCapabilityParams {
|
|
1319
|
+
"commands.execute": WebviewCommandsExecuteParams;
|
|
1320
|
+
"navigation.open": WebviewNavigationOpenParams;
|
|
1321
|
+
"placement.close": Record<string, never>;
|
|
1322
|
+
"notification.show": WebviewNotificationShowParams;
|
|
1323
|
+
"notification.action": WebviewNotificationActionParams;
|
|
1324
|
+
"notification.resolve": WebviewNotificationResolveParams;
|
|
1325
|
+
"notification.dismiss": WebviewNotificationDismissParams;
|
|
1326
|
+
"preferences.get": WebviewPreferencesGetParams;
|
|
1327
|
+
"preferences.set": WebviewPreferencesSetParams;
|
|
1328
|
+
"extension.settings.all": Record<string, never>;
|
|
1329
|
+
"extension.settings.get": WebviewExtensionSettingKeyParams;
|
|
1330
|
+
"extension.settings.set": WebviewExtensionSettingSetParams;
|
|
1331
|
+
"extension.settings.delete": WebviewExtensionSettingKeyParams;
|
|
1332
|
+
"terminal.session": TerminalSessionOperation$1;
|
|
1333
|
+
"files.upload": WebviewFilesUploadParams;
|
|
1334
|
+
"files.list": WebviewFilesListParams;
|
|
1335
|
+
"files.delete": WebviewFilesDeleteParams;
|
|
1336
|
+
"artifacts.read": WebviewArtifactsReadParams;
|
|
1337
|
+
"host.dispatchKeyboardEvent": WebviewKeyboardEventParams;
|
|
1338
|
+
}
|
|
1339
|
+
interface WebviewHostCapabilityResults {
|
|
1340
|
+
"commands.execute": {
|
|
1341
|
+
outcome: CommandOutcome;
|
|
1342
|
+
};
|
|
1343
|
+
"navigation.open": void;
|
|
1344
|
+
"placement.close": void;
|
|
1345
|
+
"notification.show": void;
|
|
1346
|
+
"notification.action": Notification;
|
|
1347
|
+
"notification.resolve": Notification | {
|
|
1348
|
+
resolved: number;
|
|
1349
|
+
notifications: Notification[];
|
|
1350
|
+
};
|
|
1351
|
+
"notification.dismiss": Notification | {
|
|
1352
|
+
resolved: number;
|
|
1353
|
+
notifications: Notification[];
|
|
1354
|
+
};
|
|
1355
|
+
"preferences.get": WebviewPreferencesSetParams["value"] | undefined;
|
|
1356
|
+
"preferences.set": {
|
|
1357
|
+
name: string;
|
|
1358
|
+
value: WebviewPreferencesSetParams["value"];
|
|
1359
|
+
};
|
|
1360
|
+
"extension.settings.all": Record<string, unknown>;
|
|
1361
|
+
"extension.settings.get": unknown;
|
|
1362
|
+
"extension.settings.set": void;
|
|
1363
|
+
"extension.settings.delete": void;
|
|
1364
|
+
"terminal.session": TerminalSessionResult$1;
|
|
1365
|
+
"files.upload": ExtensionBlobRef;
|
|
1366
|
+
"files.list": {
|
|
1367
|
+
files: ExtensionBlobRef[];
|
|
1368
|
+
};
|
|
1369
|
+
"files.delete": void;
|
|
1370
|
+
"artifacts.read": WebviewArtifactFile[] | string;
|
|
1371
|
+
"host.dispatchKeyboardEvent": void;
|
|
1372
|
+
}
|
|
1373
|
+
type WebviewHostCapabilityResult<Capability extends WebviewHostCapability, Params extends WebviewHostCapabilityParams[Capability] = WebviewHostCapabilityParams[Capability]> = Capability extends "artifacts.read" ? Params extends {
|
|
1374
|
+
op: "list";
|
|
1375
|
+
} ? WebviewArtifactFile[] : Params extends {
|
|
1376
|
+
op: "readText" | "imageUrl";
|
|
1377
|
+
} ? string : WebviewHostCapabilityResults[Capability] : Capability extends "terminal.session" ? Params extends {
|
|
1378
|
+
operation: "open";
|
|
1379
|
+
} ? Extract<TerminalSessionResult$1, {
|
|
1380
|
+
operation: "open";
|
|
1381
|
+
}> : Params extends {
|
|
1382
|
+
operation: "write" | "resize" | "kill" | "subscribe";
|
|
1383
|
+
} ? Exclude<TerminalSessionResult$1, {
|
|
1384
|
+
operation: "open";
|
|
1385
|
+
}> : TerminalSessionResult$1 : WebviewHostCapabilityResults[Capability];
|
|
1386
|
+
//#endregion
|
|
1387
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/params.d.ts
|
|
1388
|
+
type ParamType = "text" | "longtext" | "markdown" | "number" | "boolean" | "select" | "multi-select" | "files" | "harness" | "template" | "resource" | "workspace" | "json" | "list";
|
|
1389
|
+
type ParamRequired<TRequired extends boolean | undefined> = TRequired extends true ? {
|
|
1390
|
+
required: true;
|
|
1391
|
+
} : TRequired extends false ? {
|
|
1392
|
+
required: false;
|
|
1393
|
+
} : {
|
|
1394
|
+
required?: boolean;
|
|
1395
|
+
};
|
|
1396
|
+
type ParamBase<TValue, TRequired extends boolean | undefined = boolean | undefined> = {
|
|
1397
|
+
label?: Localizable<string>;
|
|
1398
|
+
description?: Localizable<string>;
|
|
1399
|
+
defaultValue?: TValue;
|
|
1400
|
+
metadata?: JsonObject;
|
|
1401
|
+
resolvedFrom?: "resource";
|
|
1402
|
+
} & ParamRequired<TRequired>;
|
|
1403
|
+
type TextParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string, TRequired> & {
|
|
1404
|
+
type: "text";
|
|
1405
|
+
};
|
|
1406
|
+
type LongTextParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string, TRequired> & {
|
|
1407
|
+
type: "longtext";
|
|
1408
|
+
};
|
|
1409
|
+
type MarkdownParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string, TRequired> & {
|
|
1410
|
+
type: "markdown";
|
|
1411
|
+
placeholder?: Localizable<string>;
|
|
1412
|
+
};
|
|
1413
|
+
type NumberParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<number, TRequired> & {
|
|
1414
|
+
type: "number";
|
|
1415
|
+
};
|
|
1416
|
+
type FilesParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string[], TRequired> & {
|
|
1417
|
+
type: "files";
|
|
1418
|
+
multiple?: boolean;
|
|
1419
|
+
/** Passed through to the picker, e.g. "image/*". */
|
|
1420
|
+
accept?: string;
|
|
1421
|
+
};
|
|
1422
|
+
type BooleanParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<boolean, TRequired> & {
|
|
1423
|
+
type: "boolean";
|
|
1424
|
+
};
|
|
1425
|
+
type ParamValueRef = {
|
|
1426
|
+
kind: "param-value";
|
|
1427
|
+
key: string;
|
|
1428
|
+
};
|
|
1429
|
+
interface ParamOptionSource {
|
|
1430
|
+
command: CommandRef;
|
|
1431
|
+
valueField: string;
|
|
1432
|
+
labelField: string;
|
|
1433
|
+
params?: Record<string, unknown | ParamValueRef>;
|
|
1434
|
+
}
|
|
1435
|
+
type ParamOption = {
|
|
1436
|
+
label: string;
|
|
1437
|
+
value: string;
|
|
1438
|
+
icon?: string;
|
|
1439
|
+
};
|
|
1440
|
+
type SelectParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string, TRequired> & {
|
|
1441
|
+
type: "select";
|
|
1442
|
+
options: ParamOption[] | ParamOptionSource;
|
|
1443
|
+
allowCustomValues?: boolean;
|
|
1444
|
+
};
|
|
1445
|
+
type MultiSelectParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string[], TRequired> & {
|
|
1446
|
+
type: "multi-select";
|
|
1447
|
+
options: ParamOption[] | ParamOptionSource;
|
|
1448
|
+
allowCustomValues?: boolean;
|
|
1449
|
+
};
|
|
1450
|
+
type HarnessParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<{
|
|
1451
|
+
harnessId: string;
|
|
1452
|
+
model?: string;
|
|
1453
|
+
params?: Record<string, string | boolean>;
|
|
1454
|
+
}, TRequired> & {
|
|
1455
|
+
type: "harness";
|
|
1456
|
+
};
|
|
1457
|
+
type TemplateParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string, TRequired> & {
|
|
1458
|
+
type: "template";
|
|
1459
|
+
templateType: string;
|
|
1460
|
+
};
|
|
1461
|
+
type ResourceParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<ResourceRef, TRequired> & {
|
|
1462
|
+
type: "resource";
|
|
1463
|
+
resourceType: string;
|
|
1464
|
+
};
|
|
1465
|
+
type WorkspaceParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<{
|
|
1466
|
+
providerId: string;
|
|
1467
|
+
params?: JsonObject;
|
|
1468
|
+
}, TRequired> & {
|
|
1469
|
+
type: "workspace";
|
|
1470
|
+
/** Provider ids the user may choose from. Omit to offer every provider. */
|
|
1471
|
+
providers?: string[];
|
|
1472
|
+
};
|
|
1473
|
+
type JsonParam<T = unknown, TRequired extends boolean | undefined = boolean | undefined> = ParamBase<T, TRequired> & {
|
|
1474
|
+
type: "json";
|
|
1475
|
+
};
|
|
1476
|
+
type ListParam<TRequired extends boolean | undefined = boolean | undefined> = ParamBase<string[], TRequired> & {
|
|
1477
|
+
type: "list";
|
|
1478
|
+
};
|
|
1479
|
+
type ParamDescriptor<TValue = unknown, TRequired extends boolean | undefined = boolean | undefined> = TextParam<TRequired> | LongTextParam<TRequired> | MarkdownParam<TRequired> | NumberParam<TRequired> | BooleanParam<TRequired> | SelectParam<TRequired> | MultiSelectParam<TRequired> | FilesParam<TRequired> | HarnessParam<TRequired> | TemplateParam<TRequired> | ResourceParam<TRequired> | WorkspaceParam<TRequired> | JsonParam<TValue, TRequired> | ListParam<TRequired>;
|
|
1480
|
+
type ParamObjectSchema = Record<string, ParamDescriptor>;
|
|
1481
|
+
type ParamValue<TDescriptor extends ParamDescriptor> = TDescriptor extends ParamDescriptor<infer V> ? V : never;
|
|
1482
|
+
type RequiredParamKeys<TSchema extends ParamObjectSchema> = { [K in keyof TSchema]: TSchema[K] extends {
|
|
1483
|
+
required: true;
|
|
1484
|
+
} ? K : never; }[keyof TSchema];
|
|
1485
|
+
type OptionalParamKeys<TSchema extends ParamObjectSchema> = Exclude<keyof TSchema, RequiredParamKeys<TSchema>>;
|
|
1486
|
+
type ParamsOf<TSchema extends ParamObjectSchema> = { [K in RequiredParamKeys<TSchema>]: ParamValue<TSchema[K]>; } & { [K in OptionalParamKeys<TSchema>]?: ParamValue<TSchema[K]>; };
|
|
1487
|
+
//#endregion
|
|
1488
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/view-toolbar-action.d.ts
|
|
1489
|
+
interface ViewToolbarAction<TParams extends Struct = Struct> {
|
|
1490
|
+
id: string;
|
|
1491
|
+
label: Localizable<string>;
|
|
1492
|
+
icon?: string;
|
|
1493
|
+
presentation?: "primary" | "secondary";
|
|
1494
|
+
command: CommandRef<TParams, unknown>;
|
|
1495
|
+
params?: Record<string, unknown>;
|
|
1496
|
+
input?: ParamObjectSchema;
|
|
1497
|
+
submitLabel?: string;
|
|
1498
|
+
when?: string;
|
|
1499
|
+
disabled?: boolean;
|
|
1500
|
+
}
|
|
1501
|
+
//#endregion
|
|
1502
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/kanban-renderer.d.ts
|
|
1503
|
+
type KanbanRendererViewMode = "board" | "list";
|
|
1504
|
+
type KanbanRendererSortDirection = "asc" | "desc";
|
|
1505
|
+
interface KanbanRendererEnumOption {
|
|
1506
|
+
value: string;
|
|
1507
|
+
label: Localizable<string>;
|
|
1508
|
+
color?: string;
|
|
1509
|
+
icon?: string | null;
|
|
1510
|
+
}
|
|
1511
|
+
type KanbanRendererAttributeType = {
|
|
1512
|
+
kind: "enum";
|
|
1513
|
+
options: KanbanRendererEnumOption[];
|
|
1514
|
+
} | {
|
|
1515
|
+
kind: "enum-multi";
|
|
1516
|
+
options: KanbanRendererEnumOption[];
|
|
1517
|
+
} | {
|
|
1518
|
+
kind: "status";
|
|
1519
|
+
statuses: StatusRef;
|
|
1520
|
+
} | {
|
|
1521
|
+
kind: "string";
|
|
1522
|
+
} | {
|
|
1523
|
+
kind: "date";
|
|
1524
|
+
} | {
|
|
1525
|
+
kind: "number";
|
|
1526
|
+
} | {
|
|
1527
|
+
kind: "user";
|
|
1528
|
+
};
|
|
1529
|
+
interface CollectionBadgeItem {
|
|
1530
|
+
id: string;
|
|
1531
|
+
label: string;
|
|
1532
|
+
icon?: string;
|
|
1533
|
+
resource?: ResourceRef;
|
|
1534
|
+
}
|
|
1535
|
+
type KanbanRendererAttributeDisplay = {
|
|
1536
|
+
kind: "badge-list";
|
|
1537
|
+
itemsAttributeId: string;
|
|
1538
|
+
};
|
|
1539
|
+
interface KanbanRendererAttributeDescriptor {
|
|
1540
|
+
id: string;
|
|
1541
|
+
label: Localizable<string>;
|
|
1542
|
+
type: KanbanRendererAttributeType;
|
|
1543
|
+
filterable?: boolean;
|
|
1544
|
+
groupable?: boolean;
|
|
1545
|
+
sortable?: boolean;
|
|
1546
|
+
displayable?: boolean;
|
|
1547
|
+
editable?: boolean;
|
|
1548
|
+
display?: KanbanRendererAttributeDisplay;
|
|
1549
|
+
}
|
|
1550
|
+
interface KanbanRendererSettings {
|
|
1551
|
+
viewMode: KanbanRendererViewMode;
|
|
1552
|
+
columnGrouping: string;
|
|
1553
|
+
rowGrouping: string;
|
|
1554
|
+
ordering: {
|
|
1555
|
+
attributeId: string;
|
|
1556
|
+
direction: KanbanRendererSortDirection;
|
|
1557
|
+
};
|
|
1558
|
+
displayProperties: string[];
|
|
1559
|
+
}
|
|
1560
|
+
type KanbanRendererFilterState = Record<string, string[]>;
|
|
1561
|
+
interface KanbanRendererSavedView {
|
|
1562
|
+
id: string;
|
|
1563
|
+
title: Localizable<string>;
|
|
1564
|
+
settings: KanbanRendererSettings;
|
|
1565
|
+
filters: KanbanRendererFilterState;
|
|
1566
|
+
/** @deprecated Use the renderer's defaultActiveViewId instead. */
|
|
1567
|
+
isDefault?: boolean;
|
|
1568
|
+
}
|
|
1569
|
+
interface KanbanRendererQueryParams {
|
|
1570
|
+
renderer: RendererContext;
|
|
1571
|
+
settings: KanbanRendererSettings;
|
|
1572
|
+
filters: KanbanRendererFilterState;
|
|
1573
|
+
}
|
|
1574
|
+
type KanbanRendererResourceRef = ResourceRef;
|
|
1575
|
+
interface KanbanRendererRow {
|
|
1576
|
+
id: string;
|
|
1577
|
+
title: string;
|
|
1578
|
+
resource?: KanbanRendererResourceRef;
|
|
1579
|
+
attributes: Record<string, unknown>;
|
|
1580
|
+
}
|
|
1581
|
+
interface KanbanRendererColumnAction {
|
|
1582
|
+
id: string;
|
|
1583
|
+
label: Localizable<string>;
|
|
1584
|
+
icon?: string;
|
|
1585
|
+
}
|
|
1586
|
+
interface KanbanRendererBoardColumnConfig {
|
|
1587
|
+
color?: string;
|
|
1588
|
+
canDragIn?: boolean;
|
|
1589
|
+
canDragOut?: boolean;
|
|
1590
|
+
canCreate?: boolean;
|
|
1591
|
+
actions?: KanbanRendererColumnAction[];
|
|
1592
|
+
}
|
|
1593
|
+
interface KanbanRendererQueryResult {
|
|
1594
|
+
rows: KanbanRendererRow[];
|
|
1595
|
+
attributes?: KanbanRendererAttributeDescriptor[];
|
|
1596
|
+
boardColumnConfigs?: Record<string, KanbanRendererBoardColumnConfig>;
|
|
1597
|
+
}
|
|
1598
|
+
interface KanbanRendererCreateRowContribution<TParams extends ParamObjectSchema = ParamObjectSchema> {
|
|
1599
|
+
command: CommandRef<Struct, unknown>;
|
|
1600
|
+
title?: Localizable<string>;
|
|
1601
|
+
submitLabel?: Localizable<string>;
|
|
1602
|
+
columnParam?: string;
|
|
1603
|
+
params?: TParams;
|
|
1604
|
+
attributesParam?: string;
|
|
1605
|
+
attachments?: {
|
|
1606
|
+
command: CommandRef<Struct, unknown>;
|
|
1607
|
+
resourceParam: string;
|
|
1608
|
+
fileParam: string;
|
|
1609
|
+
};
|
|
1610
|
+
labels?: {
|
|
1611
|
+
cancel?: Localizable<string>;
|
|
1612
|
+
properties?: Localizable<string>;
|
|
1613
|
+
submitError?: Localizable<string>;
|
|
1614
|
+
removeFile?: Localizable<string>;
|
|
1615
|
+
};
|
|
1616
|
+
}
|
|
1617
|
+
interface KanbanRendererRowAction<TParams extends Struct = Struct> {
|
|
1618
|
+
id: string;
|
|
1619
|
+
label: Localizable<string>;
|
|
1620
|
+
icon?: string;
|
|
1621
|
+
command: CommandRef<TParams, unknown>;
|
|
1622
|
+
destructive?: boolean;
|
|
1623
|
+
}
|
|
1624
|
+
type KanbanRendererRowActivationHandler = RendererCallback<{
|
|
1625
|
+
row: KanbanRendererRow;
|
|
1626
|
+
}, void>;
|
|
1627
|
+
interface KanbanRendererContribution extends RendererContributionBase {
|
|
1628
|
+
toolbarActions?: ViewToolbarAction[];
|
|
1629
|
+
attributes?: KanbanRendererAttributeDescriptor[];
|
|
1630
|
+
query: RendererCallback<KanbanRendererQueryParams, KanbanRendererQueryResult>;
|
|
1631
|
+
onAttributeChange?: RendererCallback<{
|
|
1632
|
+
rowId: string;
|
|
1633
|
+
attributeId: string;
|
|
1634
|
+
value: unknown;
|
|
1635
|
+
}, unknown>;
|
|
1636
|
+
onReorder?: RendererCallback<{
|
|
1637
|
+
rowId: string;
|
|
1638
|
+
beforeRowId?: string;
|
|
1639
|
+
}, unknown>;
|
|
1640
|
+
onColumnAction?: RendererCallback<{
|
|
1641
|
+
columnId: string;
|
|
1642
|
+
actionId: string;
|
|
1643
|
+
}, unknown>;
|
|
1644
|
+
createRow?: KanbanRendererCreateRowContribution;
|
|
1645
|
+
rowActions?: KanbanRendererRowAction[];
|
|
1646
|
+
onRowActivate?: KanbanRendererRowActivationHandler;
|
|
1647
|
+
defaultSettings?: Partial<KanbanRendererSettings>;
|
|
1648
|
+
defaultFilters?: KanbanRendererFilterState;
|
|
1649
|
+
defaultViews?: KanbanRendererSavedView[];
|
|
1650
|
+
defaultActiveViewId?: string;
|
|
1651
|
+
hideToolbar?: boolean;
|
|
1652
|
+
}
|
|
1653
|
+
//#endregion
|
|
1654
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/contributions.d.ts
|
|
1655
|
+
interface CliContribution {
|
|
1656
|
+
path?: string[];
|
|
1657
|
+
globalAliases?: string[][];
|
|
1658
|
+
description?: Localizable<string>;
|
|
1659
|
+
examples?: string[];
|
|
1660
|
+
hidden?: boolean;
|
|
1661
|
+
}
|
|
1662
|
+
interface WhenExpression {
|
|
1663
|
+
mode?: ModeRef | readonly ModeRef[];
|
|
1664
|
+
source?: CommandSource[];
|
|
1665
|
+
view?: ViewRef | readonly ViewRef[];
|
|
1666
|
+
resourceType?: readonly ResourceKindRef[];
|
|
1667
|
+
metadata?: JsonObject;
|
|
1668
|
+
}
|
|
1669
|
+
interface MenuContribution<TSlotContext extends Struct = Struct, TParams extends Struct = Struct> {
|
|
1670
|
+
slot: SlotRef<TSlotContext, "menu">;
|
|
1671
|
+
label?: Localizable<string>;
|
|
1672
|
+
group?: string;
|
|
1673
|
+
placement?: "first" | "default" | "last";
|
|
1674
|
+
icon?: string;
|
|
1675
|
+
when?: WhenExpression;
|
|
1676
|
+
params?: Partial<TParams>;
|
|
1677
|
+
presentation?: "menu-item" | "button" | "icon-button";
|
|
1678
|
+
}
|
|
1679
|
+
interface CommandPaletteContribution<TParams extends Struct = Struct> {
|
|
1680
|
+
label?: Localizable<string>;
|
|
1681
|
+
group?: string;
|
|
1682
|
+
placement?: "first" | "default" | "last";
|
|
1683
|
+
icon?: string;
|
|
1684
|
+
when?: WhenExpression;
|
|
1685
|
+
params?: Partial<TParams>;
|
|
1686
|
+
}
|
|
1687
|
+
interface ActivityItemContribution<TParams extends Struct = Struct> extends ContributionDefinition<"activity-item"> {
|
|
1688
|
+
title: Localizable<string>;
|
|
1689
|
+
icon: string;
|
|
1690
|
+
/** Mode ids whose activity rail shows this item. */
|
|
1691
|
+
modes: readonly ModeRef[];
|
|
1692
|
+
placement?: "first" | "default" | "last";
|
|
1693
|
+
command: CommandRef<TParams, unknown>;
|
|
1694
|
+
params?: Partial<TParams>;
|
|
1695
|
+
}
|
|
1696
|
+
interface ModeRegionSettings {
|
|
1697
|
+
/** Hide the panel header when the mode supplies its own controls. */
|
|
1698
|
+
readonly showHeader?: boolean;
|
|
1699
|
+
readonly size?: RegionSize;
|
|
1700
|
+
/** Allow dragging this region closed. Explicit hide/show is always available. */
|
|
1701
|
+
readonly collapsible?: boolean;
|
|
1702
|
+
/** Keep a tab visible when this region has only one visible item. */
|
|
1703
|
+
readonly alwaysShowTabs?: boolean;
|
|
1704
|
+
}
|
|
1705
|
+
interface ModeContribution extends ContributionDefinition<"mode"> {
|
|
1706
|
+
label: Localizable<string>;
|
|
1707
|
+
icon?: string;
|
|
1708
|
+
regions: readonly ExtensionPanelRegion[];
|
|
1709
|
+
/** Default theme for this mode. An explicit user choice for the mode takes precedence. */
|
|
1710
|
+
defaultTheme?: ThemeRef;
|
|
1711
|
+
/** Whether side panels may float while this mode is active. Defaults to visible. */
|
|
1712
|
+
floatingPanels?: "visible" | "hidden";
|
|
1713
|
+
/** Replace host chrome with a view, or hide it with false, while the mode is active. */
|
|
1714
|
+
chrome?: Partial<Record<"nav" | "sidenav" | "activity" | "status", ViewRef | false>>;
|
|
1715
|
+
/** Region-level layout policy. The mode owns it; placements cannot set it. */
|
|
1716
|
+
regionSettings?: Readonly<Partial<Record<DockedWorkbenchRegion, ModeRegionSettings>>>;
|
|
1717
|
+
}
|
|
1718
|
+
interface WebviewContribution {
|
|
1719
|
+
entry: PackageAssetDescriptor;
|
|
1720
|
+
title?: Localizable<string>;
|
|
1721
|
+
capabilities?: WebviewCapabilityDeclaration[];
|
|
1722
|
+
}
|
|
1723
|
+
interface SettingsPanelContribution extends ContributionDefinition<"settings-panel"> {
|
|
1724
|
+
view: ViewRef;
|
|
1725
|
+
slot: SettingsSlotRef;
|
|
1726
|
+
section?: SettingsSectionRef;
|
|
1727
|
+
}
|
|
1728
|
+
/** A named group in the settings navigation that an extension's panels can sit under. */
|
|
1729
|
+
interface SettingsSectionContribution extends ContributionDefinition<"settings-section"> {
|
|
1730
|
+
title: Localizable<string>;
|
|
1731
|
+
/** Lower sorts first among sibling sections. */
|
|
1732
|
+
order?: number;
|
|
1733
|
+
}
|
|
1734
|
+
/**
|
|
1735
|
+
* Command palette resource providers contribute dynamic, searchable palette results
|
|
1736
|
+
* (e.g. slides in a presentation) backed by a private query callback. The host queries
|
|
1737
|
+
* matching providers as the user types and refreshes results when a declared event fires.
|
|
1738
|
+
*/
|
|
1739
|
+
interface CommandPaletteResourceQueryParams {
|
|
1740
|
+
projectId?: string;
|
|
1741
|
+
modeId?: string;
|
|
1742
|
+
activeResource?: ResourceRef;
|
|
1743
|
+
providerId: string;
|
|
1744
|
+
query: string;
|
|
1745
|
+
limit: number;
|
|
1746
|
+
}
|
|
1747
|
+
type CommandPaletteResourceTarget = NavigationTarget;
|
|
1748
|
+
interface CommandPaletteResourceItem {
|
|
1749
|
+
id: string;
|
|
1750
|
+
label: string;
|
|
1751
|
+
description?: string;
|
|
1752
|
+
icon?: string;
|
|
1753
|
+
keywords?: string[];
|
|
1754
|
+
target: CommandPaletteResourceTarget;
|
|
1755
|
+
}
|
|
1756
|
+
interface CommandPaletteResourceQueryResult {
|
|
1757
|
+
items: CommandPaletteResourceItem[];
|
|
1758
|
+
}
|
|
1759
|
+
interface CommandPaletteResourceContribution extends ContributionDefinition<"command-palette-resource"> {
|
|
1760
|
+
title: Localizable<string>;
|
|
1761
|
+
resourceKind?: ResourceKindRef;
|
|
1762
|
+
query: RendererCallback<CommandPaletteResourceQueryParams, CommandPaletteResourceQueryResult>;
|
|
1763
|
+
refreshEvents?: readonly RendererEventReference[];
|
|
1764
|
+
}
|
|
1765
|
+
type ExtensionSettingScope = "global" | "project";
|
|
1766
|
+
type ExtensionSettingValueType = "boolean" | "number" | "string" | "array" | "object";
|
|
1767
|
+
type ExtensionSettingValueForType<TType extends ExtensionSettingValueType> = TType extends "boolean" ? boolean : TType extends "number" ? number : TType extends "string" ? string : TType extends "array" ? JsonValue[] : JsonObject;
|
|
1768
|
+
type ExtensionSettingProperty<TType extends ExtensionSettingValueType = ExtensionSettingValueType> = { [TSettingType in TType]: {
|
|
1769
|
+
type: TSettingType;
|
|
1770
|
+
scope: ExtensionSettingScope;
|
|
1771
|
+
default?: ExtensionSettingValueForType<TSettingType>;
|
|
1772
|
+
enum?: ExtensionSettingValueForType<TSettingType>[];
|
|
1773
|
+
title?: Localizable<string>;
|
|
1774
|
+
description?: Localizable<string>;
|
|
1775
|
+
}; }[TType];
|
|
1776
|
+
interface ExtensionSettingsContribution<TProperties extends Record<string, ExtensionSettingProperty> = Record<string, ExtensionSettingProperty>> {
|
|
1777
|
+
properties: TProperties;
|
|
1778
|
+
}
|
|
1779
|
+
interface ArtifactMountContribution extends ContributionDefinition<"artifact-mount"> {
|
|
1780
|
+
/** Relative path under .pstdio/<extension.name>/. */
|
|
1781
|
+
path: string;
|
|
1782
|
+
label: Localizable<string>;
|
|
1783
|
+
}
|
|
1784
|
+
interface TemplateTypeContribution extends ContributionDefinition<"template-type"> {
|
|
1785
|
+
label: Localizable<string>;
|
|
1786
|
+
description?: Localizable<string>;
|
|
1787
|
+
order?: number;
|
|
1788
|
+
commands?: {
|
|
1789
|
+
list: CommandRef;
|
|
1790
|
+
read: CommandRef;
|
|
1791
|
+
save: CommandRef;
|
|
1792
|
+
delete: CommandRef;
|
|
1793
|
+
};
|
|
1794
|
+
}
|
|
1795
|
+
interface TemplateContribution extends ContributionDefinition<"template"> {
|
|
1796
|
+
title: Localizable<string>;
|
|
1797
|
+
type: string;
|
|
1798
|
+
source: PackageAssetDescriptor;
|
|
1799
|
+
description?: Localizable<string>;
|
|
1800
|
+
}
|
|
1801
|
+
interface SkillContribution extends ContributionDefinition<"skill"> {
|
|
1802
|
+
title: Localizable<string>;
|
|
1803
|
+
source: PackageAssetDescriptor;
|
|
1804
|
+
description?: Localizable<string>;
|
|
1805
|
+
}
|
|
1806
|
+
type ThemeMode = "light" | "dark";
|
|
1807
|
+
interface ThemeContribution extends ContributionDefinition<"theme"> {
|
|
1808
|
+
title: Localizable<string>;
|
|
1809
|
+
source: PackageAssetDescriptor;
|
|
1810
|
+
format: "vscode-color-theme";
|
|
1811
|
+
mode?: ThemeMode;
|
|
1812
|
+
description?: Localizable<string>;
|
|
1813
|
+
}
|
|
1814
|
+
interface FileIconThemeContribution extends ContributionDefinition<"file-icon-theme"> {
|
|
1815
|
+
title: Localizable<string>;
|
|
1816
|
+
source: PackageAssetDescriptor;
|
|
1817
|
+
format: "vscode-file-icon-theme";
|
|
1818
|
+
description?: Localizable<string>;
|
|
1819
|
+
}
|
|
1820
|
+
/**
|
|
1821
|
+
* Chord string in TanStack Hotkeys syntax (e.g. "mod+shift+p"). `mod` is
|
|
1822
|
+
* Cmd on macOS and Ctrl elsewhere. Parsing, validation, canonicalization,
|
|
1823
|
+
* and display labels are all delegated to `@tanstack/hotkeys`.
|
|
1824
|
+
*/
|
|
1825
|
+
type KeybindingChord = string;
|
|
1826
|
+
interface KeybindingContribution extends ContributionDefinition<"keybinding"> {
|
|
1827
|
+
/** Default chord. Used on every platform unless an override is provided. */
|
|
1828
|
+
key: KeybindingChord;
|
|
1829
|
+
/** macOS override. */
|
|
1830
|
+
mac?: KeybindingChord;
|
|
1831
|
+
/** Linux override. */
|
|
1832
|
+
linux?: KeybindingChord;
|
|
1833
|
+
/** Windows override. */
|
|
1834
|
+
win?: KeybindingChord;
|
|
1835
|
+
/** Action this chord executes through the shared navigation executor. */
|
|
1836
|
+
action: NavigationTarget;
|
|
1837
|
+
/** Optional gating predicate. The host evaluates it at dispatch time. */
|
|
1838
|
+
when?: WhenExpression;
|
|
1839
|
+
}
|
|
1840
|
+
//#endregion
|
|
1841
|
+
//#region ../pstdio-api-contracts/src/session-messages.d.ts
|
|
1842
|
+
type SessionMessageRole = "user" | "assistant" | "tool" | "system" | "developer";
|
|
1843
|
+
type TextPart = {
|
|
1844
|
+
type: "text";
|
|
1845
|
+
text: string;
|
|
1846
|
+
};
|
|
1847
|
+
type ReasoningPart = {
|
|
1848
|
+
type: "reasoning";
|
|
1849
|
+
text: string;
|
|
1850
|
+
};
|
|
1851
|
+
type ToolPartActionType = "read" | "write" | "execute" | "network" | "other";
|
|
1852
|
+
type ToolPartStatus = "pending" | "running" | "completed" | "failed" | "denied";
|
|
1853
|
+
type ToolPart = {
|
|
1854
|
+
type: "tool";
|
|
1855
|
+
tool: string;
|
|
1856
|
+
callId?: string;
|
|
1857
|
+
actionType?: ToolPartActionType;
|
|
1858
|
+
status?: ToolPartStatus;
|
|
1859
|
+
state?: {
|
|
1860
|
+
status?: string;
|
|
1861
|
+
input?: unknown;
|
|
1862
|
+
output?: unknown;
|
|
1863
|
+
errorText?: string;
|
|
1864
|
+
metadata?: unknown;
|
|
1865
|
+
};
|
|
1866
|
+
};
|
|
1867
|
+
type StepStartPart = {
|
|
1868
|
+
type: "step-start";
|
|
1869
|
+
snapshot?: string;
|
|
1870
|
+
};
|
|
1871
|
+
type StepFinishPart = {
|
|
1872
|
+
type: "step-finish";
|
|
1873
|
+
reason?: string;
|
|
1874
|
+
snapshot?: string;
|
|
1875
|
+
cost?: number;
|
|
1876
|
+
tokens?: unknown;
|
|
1877
|
+
};
|
|
1878
|
+
type PatchPart = {
|
|
1879
|
+
type: "patch";
|
|
1880
|
+
hash?: string;
|
|
1881
|
+
files?: unknown;
|
|
1882
|
+
};
|
|
1883
|
+
type FilePart = {
|
|
1884
|
+
type: "file";
|
|
1885
|
+
fileId?: string;
|
|
1886
|
+
mediaType?: string;
|
|
1887
|
+
filename?: string;
|
|
1888
|
+
size?: number;
|
|
1889
|
+
url: string;
|
|
1890
|
+
};
|
|
1891
|
+
type LoadingPart = {
|
|
1892
|
+
type: "loading";
|
|
1893
|
+
};
|
|
1894
|
+
type ErrorPart = {
|
|
1895
|
+
type: "error";
|
|
1896
|
+
errorType: "timeout" | "crash" | "permission" | "other";
|
|
1897
|
+
message?: string;
|
|
1898
|
+
};
|
|
1899
|
+
type TokenUsagePart = {
|
|
1900
|
+
type: "token_usage";
|
|
1901
|
+
inputTokens: number;
|
|
1902
|
+
outputTokens: number;
|
|
1903
|
+
cacheReadTokens?: number;
|
|
1904
|
+
cacheWriteTokens?: number;
|
|
1905
|
+
};
|
|
1906
|
+
type SessionMessagePart = TextPart | ReasoningPart | ToolPart | StepStartPart | StepFinishPart | PatchPart | FilePart | LoadingPart | ErrorPart | TokenUsagePart;
|
|
1907
|
+
type SessionMessage = {
|
|
1908
|
+
id: string;
|
|
1909
|
+
role: SessionMessageRole;
|
|
1910
|
+
parts: SessionMessagePart[];
|
|
1911
|
+
index?: number;
|
|
1912
|
+
createdAt?: number;
|
|
1913
|
+
modelId?: string;
|
|
1914
|
+
providerId?: string;
|
|
1915
|
+
tokens?: {
|
|
1916
|
+
input?: number;
|
|
1917
|
+
output?: number;
|
|
1918
|
+
reasoning?: number;
|
|
1919
|
+
cache?: {
|
|
1920
|
+
read?: number;
|
|
1921
|
+
write?: number;
|
|
1922
|
+
};
|
|
1923
|
+
};
|
|
1924
|
+
};
|
|
1925
|
+
//#endregion
|
|
1926
|
+
//#region ../pstdio-api-contracts/src/harness.d.ts
|
|
1927
|
+
type JsonPatch = {
|
|
1928
|
+
op: "add" | "replace" | "remove";
|
|
1929
|
+
path: string;
|
|
1930
|
+
value?: unknown;
|
|
1931
|
+
};
|
|
1932
|
+
type AgentCapability = "SessionFork" | "ContextUsage" | "Approvals" | "SessionReattach";
|
|
1933
|
+
type QuestionResponse = {
|
|
1934
|
+
/**
|
|
1935
|
+
* One list of chosen labels per question, in the order the questions were asked. A label the
|
|
1936
|
+
* agent did not offer is the person's own typed answer, so a harness that validates answers
|
|
1937
|
+
* against its offered options has to add it to them before replying.
|
|
1938
|
+
*
|
|
1939
|
+
* An empty list means the person skipped the question rather than answering it. An answered
|
|
1940
|
+
* form always carries one entry per question, so the two can never be confused.
|
|
1941
|
+
*/
|
|
1942
|
+
answers: string[][];
|
|
1943
|
+
/** Shared question tool call being answered, when the caller has its identity. */
|
|
1944
|
+
callId?: string;
|
|
1945
|
+
};
|
|
1946
|
+
/** A stale or declined answer. Other harness failures remain server errors. */
|
|
1947
|
+
type HarnessQuestionReplyError = Error & {
|
|
1948
|
+
readonly questionRejected: true;
|
|
1949
|
+
};
|
|
1950
|
+
type HarnessQuestionOption = {
|
|
1951
|
+
label: string;
|
|
1952
|
+
description?: string;
|
|
1953
|
+
};
|
|
1954
|
+
type HarnessQuestion = {
|
|
1955
|
+
question: string;
|
|
1956
|
+
options?: HarnessQuestionOption[];
|
|
1957
|
+
/** The person may pick more than one option. */
|
|
1958
|
+
multiple?: boolean;
|
|
1959
|
+
};
|
|
1960
|
+
type HarnessQuestionRequest = {
|
|
1961
|
+
id: string;
|
|
1962
|
+
toolUseId: string;
|
|
1963
|
+
questions: HarnessQuestion[];
|
|
1964
|
+
};
|
|
1965
|
+
/**
|
|
1966
|
+
* Host channel a harness uses to ask the person something. The host sets the session to
|
|
1967
|
+
* `awaiting_input` while an ask is open, and resolves the ask with the answer. An ask has no
|
|
1968
|
+
* timeout; it rejects when the session ends.
|
|
1969
|
+
*/
|
|
1970
|
+
type HarnessQuestionChannel = {
|
|
1971
|
+
ask(request: HarnessQuestionRequest): Promise<QuestionResponse>;
|
|
1972
|
+
};
|
|
1973
|
+
type ApprovalRequest = {
|
|
1974
|
+
id: string;
|
|
1975
|
+
toolName: string;
|
|
1976
|
+
toolInput: unknown;
|
|
1977
|
+
toolUseId: string;
|
|
1978
|
+
};
|
|
1979
|
+
type ApprovalResponse = {
|
|
1980
|
+
id: string;
|
|
1981
|
+
decision: "approve" | "deny" | "timeout";
|
|
1982
|
+
};
|
|
1983
|
+
/** "activity": the host kills the session when no events arrive for a while; "provider": the provider self-terminates. */
|
|
1984
|
+
type TimeoutStrategy = "activity" | "provider";
|
|
1985
|
+
type HarnessEventSink = {
|
|
1986
|
+
push(patch: JsonPatch): void;
|
|
1987
|
+
getMessages(): readonly SessionMessage[];
|
|
1988
|
+
};
|
|
1989
|
+
type HarnessAttachment = {
|
|
1990
|
+
fileId: string;
|
|
1991
|
+
fileName: string;
|
|
1992
|
+
mimeType: string | null;
|
|
1993
|
+
sizeBytes: number;
|
|
1994
|
+
localPath: string;
|
|
1995
|
+
url: string;
|
|
1996
|
+
};
|
|
1997
|
+
type HarnessApprovalChannel = {
|
|
1998
|
+
requestApproval(request: ApprovalRequest): Promise<ApprovalResponse>;
|
|
1999
|
+
};
|
|
2000
|
+
type HarnessParamValue = string | boolean;
|
|
2001
|
+
type HarnessParams = Record<string, HarnessParamValue>;
|
|
2002
|
+
type HarnessWorkspaceContext = {
|
|
2003
|
+
workspaceId: string;
|
|
2004
|
+
executionTarget: WorkspaceExecutionTarget;
|
|
2005
|
+
};
|
|
2006
|
+
type HarnessExitStatus = "completed" | "failed" | "cancelled" | "disconnected";
|
|
2007
|
+
type HarnessExit = {
|
|
2008
|
+
status: HarnessExitStatus;
|
|
2009
|
+
};
|
|
2010
|
+
type HarnessSession = {
|
|
2011
|
+
/** Provider-side session id, used to resume/reattach later. */
|
|
2012
|
+
agentSessionId?: string;
|
|
2013
|
+
/** Settles exactly once; the host keys status transitions and persistence off it. */
|
|
2014
|
+
done: Promise<HarnessExit>;
|
|
2015
|
+
/** Called by the host on cancel or on its own activity timeout. */
|
|
2016
|
+
stop(): void | Promise<void>;
|
|
2017
|
+
/** Replies in place. Reject invalid answers with HarnessQuestionReplyError. */
|
|
2018
|
+
replyQuestion?(response: QuestionResponse): Promise<void>;
|
|
2019
|
+
timeoutStrategy?: TimeoutStrategy;
|
|
2020
|
+
/** Observability only. */
|
|
2021
|
+
pid?: number;
|
|
2022
|
+
};
|
|
2023
|
+
type HarnessStartInput = {
|
|
2024
|
+
prompt: string;
|
|
2025
|
+
/** Host session id (correlation / env injection). */
|
|
2026
|
+
sessionId: string;
|
|
2027
|
+
cwd?: string;
|
|
2028
|
+
workspace?: HarnessWorkspaceContext;
|
|
2029
|
+
model?: string | null;
|
|
2030
|
+
params?: HarnessParams;
|
|
2031
|
+
attachments?: HarnessAttachment[];
|
|
2032
|
+
events: HarnessEventSink;
|
|
2033
|
+
/** Channel for asking the person something. Present on start and on resume. */
|
|
2034
|
+
questions?: HarnessQuestionChannel;
|
|
2035
|
+
/** Aborted when the host cancels the request that started or resumed this session. */
|
|
2036
|
+
signal?: AbortSignal;
|
|
2037
|
+
};
|
|
2038
|
+
type HarnessResumeInput = HarnessStartInput & {
|
|
2039
|
+
agentSessionId: string;
|
|
2040
|
+
/** Index offset so resumed streams align message patches with existing history. */
|
|
2041
|
+
messageOffset?: number;
|
|
2042
|
+
questionResponse?: QuestionResponse;
|
|
2043
|
+
approvals?: HarnessApprovalChannel;
|
|
2044
|
+
};
|
|
2045
|
+
type HarnessReattachInput = {
|
|
2046
|
+
sessionId: string;
|
|
2047
|
+
agentSessionId: string;
|
|
2048
|
+
cwd?: string;
|
|
2049
|
+
workspace?: HarnessWorkspaceContext;
|
|
2050
|
+
events: HarnessEventSink;
|
|
2051
|
+
/** Aborted when the host stops orphan recovery, including during shutdown. */
|
|
2052
|
+
signal?: AbortSignal;
|
|
2053
|
+
};
|
|
2054
|
+
type HarnessMessagesInput = {
|
|
2055
|
+
agentSessionId: string;
|
|
2056
|
+
cwd?: string;
|
|
2057
|
+
workspace?: HarnessWorkspaceContext;
|
|
2058
|
+
};
|
|
2059
|
+
type HarnessRecoveryInput = {
|
|
2060
|
+
knownMessages: readonly SessionMessage[];
|
|
2061
|
+
nativeMessages: readonly SessionMessage[];
|
|
2062
|
+
cwd?: string;
|
|
2063
|
+
workspace?: HarnessWorkspaceContext;
|
|
2064
|
+
};
|
|
2065
|
+
type HarnessRecoveryResult = {
|
|
2066
|
+
kind: "recovered";
|
|
2067
|
+
messages: SessionMessage[];
|
|
2068
|
+
} | {
|
|
2069
|
+
kind: "conflict";
|
|
2070
|
+
category: string;
|
|
2071
|
+
};
|
|
2072
|
+
//#endregion
|
|
2073
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/harness.d.ts
|
|
2074
|
+
/**
|
|
2075
|
+
* Host context a harness runs against. A structural subset of ExtensionContextBase,
|
|
2076
|
+
* so richer host APIs can be passed without a contract change.
|
|
2077
|
+
*/
|
|
2078
|
+
interface HarnessContext {
|
|
2079
|
+
/** Present when the harness runs on behalf of a project session. */
|
|
2080
|
+
projectId?: string;
|
|
2081
|
+
extensionId: string;
|
|
2082
|
+
/** Extension package name. */
|
|
2083
|
+
name: string;
|
|
2084
|
+
process: ExtensionProcessApi;
|
|
2085
|
+
net: ExtensionNetApi;
|
|
2086
|
+
connections: ExtensionConnectionsApi;
|
|
2087
|
+
logger: ExtensionLoggerApi;
|
|
2088
|
+
state: HarnessStateApi;
|
|
2089
|
+
}
|
|
2090
|
+
interface HarnessStateApi {
|
|
2091
|
+
get<T = unknown>(key: string): Promise<T | undefined>;
|
|
2092
|
+
set<T = unknown>(key: string, value: T): Promise<void>;
|
|
2093
|
+
delete(key: string): Promise<void>;
|
|
2094
|
+
}
|
|
2095
|
+
interface HarnessDetectionResult {
|
|
2096
|
+
available: boolean;
|
|
2097
|
+
version?: string;
|
|
2098
|
+
reason?: string;
|
|
2099
|
+
}
|
|
2100
|
+
/** Where the harness's agent discovers skills. Paths are relative to the repo (dir) and home (globalDir). */
|
|
2101
|
+
interface HarnessSkillsLayout {
|
|
2102
|
+
dir: string;
|
|
2103
|
+
/** Defaults to `dir` when omitted. */
|
|
2104
|
+
globalDir?: string;
|
|
2105
|
+
}
|
|
2106
|
+
/** A reattach error is permanent unless the provider explicitly marks it retryable. */
|
|
2107
|
+
type RetryableHarnessReattachError = Error & {
|
|
2108
|
+
readonly retryable: true;
|
|
2109
|
+
};
|
|
2110
|
+
type HarnessParamDescriptor = (Omit<SelectParam, "options" | "allowCustomValues"> & {
|
|
2111
|
+
options: ParamOption[];
|
|
2112
|
+
}) | BooleanParam;
|
|
2113
|
+
type HarnessParamsSchema = Record<string, HarnessParamDescriptor>;
|
|
2114
|
+
/**
|
|
2115
|
+
* An agent harness contributed by an extension. The host injects the event sink
|
|
2116
|
+
* (and approval channel) and owns the session lifecycle: timeouts, persistence,
|
|
2117
|
+
* and status transitions are keyed off the returned HarnessSession.
|
|
2118
|
+
*/
|
|
2119
|
+
interface HarnessProvider extends ContributionDefinition<"harness"> {
|
|
2120
|
+
label: Localizable<string>;
|
|
2121
|
+
/** Declares skill directories so the host installs project skills for this agent. Absent = no skill setup. */
|
|
2122
|
+
skills?: HarnessSkillsLayout;
|
|
2123
|
+
/** Discrete run params the host can render, persist as defaults, validate, and pass to start/resume. */
|
|
2124
|
+
params?: HarnessParamsSchema;
|
|
2125
|
+
/** Defaults to required. Optional harnesses can run against remote workspace execution targets. */
|
|
2126
|
+
cwdRequirement?: "required" | "optional";
|
|
2127
|
+
capabilities(ctx: HarnessContext): MaybePromise<AgentCapability[]>;
|
|
2128
|
+
detect?(ctx: HarnessContext): MaybePromise<HarnessDetectionResult>;
|
|
2129
|
+
listModels?(ctx: HarnessContext): MaybePromise<AgentModel[]>;
|
|
2130
|
+
start(ctx: HarnessContext, input: HarnessStartInput): MaybePromise<HarnessSession>;
|
|
2131
|
+
resume(ctx: HarnessContext, input: HarnessResumeInput): MaybePromise<HarnessSession>;
|
|
2132
|
+
/** Re-bind after a host restart. Throw a `RetryableHarnessReattachError` only when another attempt may succeed. */
|
|
2133
|
+
reattach?(ctx: HarnessContext, input: HarnessReattachInput): MaybePromise<HarnessSession>;
|
|
2134
|
+
getMessages?(ctx: HarnessContext, input: HarnessMessagesInput): MaybePromise<SessionMessage[]>;
|
|
2135
|
+
recoverMessages?(ctx: HarnessContext, input: HarnessRecoveryInput): MaybePromise<HarnessRecoveryResult>;
|
|
2136
|
+
/**
|
|
2137
|
+
* Release workers and connections owned by this provider in ctx.projectId's scope
|
|
2138
|
+
* (or the host scope when projectId is absent). The host starts cleanup on source
|
|
2139
|
+
* reload, removal, and project disablement, and awaits it before replacement
|
|
2140
|
+
* workers or host shutdown. Turn completion does not
|
|
2141
|
+
* call this method. Stop pending startup and active runs, settle their done
|
|
2142
|
+
* promises, and await resource termination without deleting native history.
|
|
2143
|
+
* A later host lifecycle may use the provider again, so allow fresh resources.
|
|
2144
|
+
*/
|
|
2145
|
+
dispose?(ctx: HarnessContext): MaybePromise<void>;
|
|
2146
|
+
}
|
|
2520
2147
|
//#endregion
|
|
2521
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/
|
|
2522
|
-
interface
|
|
2523
|
-
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
|
|
2534
|
-
|
|
2148
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/resource-binding.d.ts
|
|
2149
|
+
interface ResourceConstraint {
|
|
2150
|
+
readonly kinds: readonly ResourceKindRef[];
|
|
2151
|
+
}
|
|
2152
|
+
interface ResourceBinding extends ResourceConstraint {
|
|
2153
|
+
readonly view: ViewRef;
|
|
2154
|
+
readonly cardinality: "one" | "many";
|
|
2155
|
+
readonly add?: NavigationTarget;
|
|
2156
|
+
}
|
|
2157
|
+
//#endregion
|
|
2158
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/control-declarations.d.ts
|
|
2159
|
+
interface BaseControl {
|
|
2160
|
+
id: string;
|
|
2161
|
+
name: string;
|
|
2162
|
+
description?: string;
|
|
2163
|
+
/** Locks this one param while the rest of the editor stays editable. */
|
|
2164
|
+
readOnly?: boolean;
|
|
2165
|
+
}
|
|
2166
|
+
interface NumberControl extends BaseControl {
|
|
2167
|
+
type: "number";
|
|
2168
|
+
defaultValue: number;
|
|
2169
|
+
min?: number;
|
|
2170
|
+
max?: number;
|
|
2171
|
+
step?: number;
|
|
2172
|
+
}
|
|
2173
|
+
interface BooleanControl extends BaseControl {
|
|
2174
|
+
type: "boolean";
|
|
2175
|
+
defaultValue: boolean;
|
|
2176
|
+
}
|
|
2177
|
+
interface TextControl extends BaseControl {
|
|
2178
|
+
type: "text";
|
|
2179
|
+
defaultValue: string;
|
|
2180
|
+
singleLine?: boolean;
|
|
2181
|
+
}
|
|
2182
|
+
interface MarkdownControl extends BaseControl {
|
|
2183
|
+
type: "markdown";
|
|
2184
|
+
defaultValue: string;
|
|
2185
|
+
placeholder?: string;
|
|
2186
|
+
}
|
|
2187
|
+
interface SelectionOption {
|
|
2188
|
+
id: string;
|
|
2189
|
+
name: string;
|
|
2190
|
+
icon?: string;
|
|
2191
|
+
/** Palette key (e.g. "blue") applied to the option's icon. */
|
|
2192
|
+
color?: string;
|
|
2193
|
+
description?: string;
|
|
2194
|
+
disabled?: boolean;
|
|
2195
|
+
}
|
|
2196
|
+
/** Parent selector used to swap the option set of a grouped selection. */
|
|
2197
|
+
interface SelectionGroup {
|
|
2198
|
+
id: string;
|
|
2199
|
+
name: string;
|
|
2200
|
+
defaultValue: string;
|
|
2201
|
+
options: SelectionOption[];
|
|
2202
|
+
placeholder?: string;
|
|
2203
|
+
searchable?: boolean;
|
|
2204
|
+
searchPlaceholder?: string;
|
|
2205
|
+
emptyText?: string;
|
|
2206
|
+
disabled?: boolean;
|
|
2207
|
+
}
|
|
2208
|
+
interface SelectionControl extends BaseControl {
|
|
2209
|
+
allowCustomValues?: boolean;
|
|
2210
|
+
type: "selection";
|
|
2211
|
+
defaultValue: string | string[];
|
|
2212
|
+
options: SelectionOption[];
|
|
2213
|
+
multiSelect?: boolean;
|
|
2214
|
+
placeholder?: string;
|
|
2215
|
+
searchable?: boolean;
|
|
2216
|
+
searchPlaceholder?: string;
|
|
2217
|
+
emptyText?: string;
|
|
2218
|
+
group?: SelectionGroup;
|
|
2219
|
+
/** Adds a "clear" row so a single-select can be returned to unset. */
|
|
2220
|
+
clearable?: boolean;
|
|
2221
|
+
/**
|
|
2222
|
+
* Renders the control inert but still as a control — unlike `readOnly`, which
|
|
2223
|
+
* collapses it to plain text and drops the option's icon.
|
|
2224
|
+
*/
|
|
2225
|
+
disabled?: boolean;
|
|
2226
|
+
}
|
|
2227
|
+
interface DateControl extends BaseControl {
|
|
2228
|
+
type: "date";
|
|
2229
|
+
defaultValue: string;
|
|
2230
|
+
min?: string;
|
|
2231
|
+
max?: string;
|
|
2232
|
+
}
|
|
2233
|
+
interface ColorControl extends BaseControl {
|
|
2234
|
+
type: "color";
|
|
2235
|
+
defaultValue: string;
|
|
2236
|
+
}
|
|
2237
|
+
interface ParamEditorReadOnlyImage {
|
|
2238
|
+
src: string;
|
|
2239
|
+
alt: string;
|
|
2240
|
+
}
|
|
2241
|
+
type ParamEditorReadOnlyContent = string | number | boolean | null | Array<string | number | boolean | null> | {
|
|
2242
|
+
type: "image";
|
|
2243
|
+
src: string;
|
|
2244
|
+
alt: string;
|
|
2245
|
+
} | {
|
|
2246
|
+
type: "image-gallery";
|
|
2247
|
+
images: ParamEditorReadOnlyImage[];
|
|
2248
|
+
};
|
|
2249
|
+
/** Serializable display-only value rendered by the read-only Param Editor. */
|
|
2250
|
+
interface ReadOnlyControl extends BaseControl {
|
|
2251
|
+
type: "readOnly";
|
|
2252
|
+
value: ParamEditorReadOnlyContent;
|
|
2253
|
+
}
|
|
2254
|
+
/** A reference the host can open (e.g. another resource tab). */
|
|
2255
|
+
type ResourceRefValue = ResourceRef;
|
|
2256
|
+
/**
|
|
2257
|
+
* Serializable resource chip. Clicking it opens `href` externally, opens `ref` via
|
|
2258
|
+
* `onOpenResource`, or copies `copyText` to the clipboard — whichever is set.
|
|
2259
|
+
*/
|
|
2260
|
+
interface ResourceOption {
|
|
2261
|
+
id: string;
|
|
2262
|
+
name: string;
|
|
2263
|
+
icon?: string;
|
|
2264
|
+
color?: string;
|
|
2265
|
+
description?: string;
|
|
2266
|
+
href?: string;
|
|
2267
|
+
ref?: ResourceRefValue;
|
|
2268
|
+
copyText?: string;
|
|
2269
|
+
}
|
|
2270
|
+
/**
|
|
2271
|
+
* Resource references rendered as tags/chips. View-only by default; set `editable`
|
|
2272
|
+
* to pick from `options` via a dropdown. Value is the selected option id(s), mirroring
|
|
2273
|
+
* {@link SelectionControl}, so it stays JSON-safe across the controls-command boundary.
|
|
2274
|
+
*/
|
|
2275
|
+
interface ResourceControl extends BaseControl {
|
|
2276
|
+
type: "resource";
|
|
2277
|
+
defaultValue: string | string[];
|
|
2278
|
+
options: ResourceOption[];
|
|
2279
|
+
multiSelect?: boolean;
|
|
2280
|
+
editable?: boolean;
|
|
2281
|
+
placeholder?: string;
|
|
2282
|
+
emptyText?: string;
|
|
2283
|
+
}
|
|
2284
|
+
type RangeValue = [number, number];
|
|
2285
|
+
/** Two-handle numeric range control. Values normalize to ordered `[start, end]`. */
|
|
2286
|
+
interface RangeControl extends BaseControl {
|
|
2287
|
+
type: "range";
|
|
2288
|
+
defaultValue: RangeValue;
|
|
2289
|
+
min: number;
|
|
2290
|
+
max: number;
|
|
2291
|
+
step?: number;
|
|
2292
|
+
unit?: string;
|
|
2293
|
+
markerCount?: number;
|
|
2294
|
+
}
|
|
2295
|
+
interface SegmentedOption {
|
|
2296
|
+
id: string;
|
|
2297
|
+
name: string;
|
|
2298
|
+
icon?: string;
|
|
2299
|
+
indicatorColor?: string;
|
|
2300
|
+
}
|
|
2301
|
+
/** Mutually-exclusive mode control rendered as a segmented button group. */
|
|
2302
|
+
interface SegmentedControl extends BaseControl {
|
|
2303
|
+
type: "segmented";
|
|
2304
|
+
defaultValue: string;
|
|
2305
|
+
options: SegmentedOption[];
|
|
2306
|
+
variant?: "default" | "dots";
|
|
2307
|
+
}
|
|
2308
|
+
interface ActionOption {
|
|
2309
|
+
id: string;
|
|
2310
|
+
name: string;
|
|
2311
|
+
icon?: string;
|
|
2312
|
+
disabled?: boolean;
|
|
2313
|
+
}
|
|
2314
|
+
/** Compact command set rendered as an action button row. */
|
|
2315
|
+
interface ActionsControl extends BaseControl {
|
|
2316
|
+
type: "actions";
|
|
2317
|
+
defaultValue?: string;
|
|
2318
|
+
options: ActionOption[];
|
|
2319
|
+
}
|
|
2320
|
+
type AnchorGridValue = "top-left" | "top" | "top-right" | "left" | "center" | "right" | "bottom-left" | "bottom" | "bottom-right";
|
|
2321
|
+
/** Nine-point alignment picker. */
|
|
2322
|
+
interface AnchorGridControl extends BaseControl {
|
|
2323
|
+
type: "anchorGrid";
|
|
2324
|
+
defaultValue: AnchorGridValue;
|
|
2325
|
+
}
|
|
2326
|
+
type VectorValue = {
|
|
2327
|
+
x: number;
|
|
2328
|
+
y: number;
|
|
2329
|
+
};
|
|
2330
|
+
/** Paired x/y numeric control. */
|
|
2331
|
+
interface VectorControl extends BaseControl {
|
|
2332
|
+
type: "vector";
|
|
2333
|
+
defaultValue: VectorValue;
|
|
2334
|
+
coordinateMode?: "cartesian" | "screen";
|
|
2335
|
+
xLabel?: string;
|
|
2336
|
+
yLabel?: string;
|
|
2337
|
+
min?: number;
|
|
2338
|
+
max?: number;
|
|
2339
|
+
step?: number;
|
|
2340
|
+
}
|
|
2341
|
+
type ControlParam = NumberControl | BooleanControl | TextControl | MarkdownControl | SelectionControl | DateControl | ColorControl | ReadOnlyControl | ResourceControl | RangeControl | SegmentedControl | ActionsControl | AnchorGridControl | VectorControl;
|
|
2342
|
+
interface ControlGroup {
|
|
2343
|
+
id: string;
|
|
2344
|
+
title: string;
|
|
2345
|
+
description?: string;
|
|
2346
|
+
params: ControlParam[];
|
|
2347
|
+
collapsible?: boolean;
|
|
2348
|
+
defaultCollapsed?: boolean;
|
|
2349
|
+
}
|
|
2350
|
+
type ControlValue = number | string | boolean | null | string[] | RangeValue | VectorValue;
|
|
2351
|
+
type ControlValueMap = Record<string, ControlValue>;
|
|
2352
|
+
//#endregion
|
|
2353
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/controls.d.ts
|
|
2354
|
+
type ControlsResourceRef = ResourceRef;
|
|
2355
|
+
interface ControlsQueryParams {
|
|
2356
|
+
renderer: RendererContext;
|
|
2357
|
+
}
|
|
2358
|
+
interface ControlsQueryResult {
|
|
2359
|
+
params?: ControlParam[];
|
|
2360
|
+
groups?: ControlGroup[];
|
|
2361
|
+
values?: ControlValueMap;
|
|
2362
|
+
readOnly?: boolean;
|
|
2363
|
+
}
|
|
2364
|
+
interface ControlsUpdateValueInput {
|
|
2365
|
+
renderer: RendererContext;
|
|
2366
|
+
controlId: string;
|
|
2367
|
+
value: ControlValue;
|
|
2368
|
+
values: ControlValueMap;
|
|
2369
|
+
}
|
|
2370
|
+
interface ControlsApplyInput {
|
|
2371
|
+
renderer: RendererContext;
|
|
2372
|
+
values: ControlValueMap;
|
|
2373
|
+
}
|
|
2374
|
+
interface ControlsResetInput {
|
|
2375
|
+
renderer: RendererContext;
|
|
2376
|
+
controlIds?: string[];
|
|
2377
|
+
}
|
|
2378
|
+
/** A native controls view. Its query supplies serializable fields and their current values. */
|
|
2379
|
+
interface ControlsRendererContribution extends RendererContributionBase {
|
|
2380
|
+
query: RendererCallback<ControlsQueryParams, ControlsQueryResult>;
|
|
2381
|
+
onValueChange?: RendererCallback<ControlsUpdateValueInput, unknown>;
|
|
2382
|
+
onApply?: RendererCallback<ControlsApplyInput, unknown>;
|
|
2383
|
+
onReset?: RendererCallback<ControlsResetInput, unknown>;
|
|
2384
|
+
defaultValues?: ControlValueMap;
|
|
2535
2385
|
}
|
|
2536
2386
|
//#endregion
|
|
2537
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/
|
|
2538
|
-
type
|
|
2539
|
-
interface
|
|
2540
|
-
|
|
2541
|
-
path: string;
|
|
2542
|
-
headers?: Record<string, string>;
|
|
2543
|
-
body?: JsonValue;
|
|
2544
|
-
timeoutMs?: number;
|
|
2545
|
-
signal?: AbortSignal;
|
|
2387
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/data-table-renderer.d.ts
|
|
2388
|
+
type DataTableRendererResourceRef = ResourceRef;
|
|
2389
|
+
interface DataTableRendererQueryParams {
|
|
2390
|
+
renderer: RendererContext;
|
|
2546
2391
|
}
|
|
2547
|
-
interface
|
|
2548
|
-
|
|
2549
|
-
|
|
2550
|
-
|
|
2392
|
+
interface DataTableRendererThemeColor {
|
|
2393
|
+
light: string;
|
|
2394
|
+
dark: string;
|
|
2395
|
+
foreground?: {
|
|
2396
|
+
light: string;
|
|
2397
|
+
dark: string;
|
|
2398
|
+
};
|
|
2551
2399
|
}
|
|
2552
|
-
type
|
|
2553
|
-
type: "
|
|
2554
|
-
status: number;
|
|
2555
|
-
headers: Record<string, string>;
|
|
2400
|
+
type DataTableRendererColumnStat = {
|
|
2401
|
+
type: "unique";
|
|
2556
2402
|
} | {
|
|
2557
|
-
type: "
|
|
2558
|
-
|
|
2403
|
+
type: "histogram";
|
|
2404
|
+
bins?: number;
|
|
2559
2405
|
} | {
|
|
2560
|
-
type: "
|
|
2406
|
+
type: "top-values";
|
|
2407
|
+
limit?: number;
|
|
2561
2408
|
};
|
|
2562
|
-
|
|
2563
|
-
|
|
2564
|
-
|
|
2409
|
+
type DataTableRendererColumnRenderer = {
|
|
2410
|
+
type: "json";
|
|
2411
|
+
} | {
|
|
2412
|
+
type: "color-scale";
|
|
2413
|
+
stops: Array<{
|
|
2414
|
+
value: number;
|
|
2415
|
+
color: DataTableRendererThemeColor;
|
|
2416
|
+
}>;
|
|
2417
|
+
} | {
|
|
2418
|
+
type: "categorical-color";
|
|
2419
|
+
categories: Array<{
|
|
2420
|
+
value: string | number | boolean | null;
|
|
2421
|
+
color: DataTableRendererThemeColor;
|
|
2422
|
+
}>;
|
|
2423
|
+
};
|
|
2424
|
+
interface DataTableRendererColumn {
|
|
2425
|
+
id: string;
|
|
2426
|
+
label?: Localizable<string>;
|
|
2427
|
+
description?: Localizable<string>;
|
|
2428
|
+
icon?: string;
|
|
2429
|
+
hidden?: boolean;
|
|
2430
|
+
stat?: DataTableRendererColumnStat;
|
|
2431
|
+
renderer?: DataTableRendererColumnRenderer;
|
|
2565
2432
|
}
|
|
2566
|
-
interface
|
|
2567
|
-
|
|
2568
|
-
|
|
2569
|
-
|
|
2433
|
+
interface DataTableRendererRow {
|
|
2434
|
+
id: string;
|
|
2435
|
+
values: Record<string, JsonValue>;
|
|
2436
|
+
resource?: DataTableRendererResourceRef;
|
|
2570
2437
|
}
|
|
2571
|
-
|
|
2572
|
-
|
|
2573
|
-
|
|
2574
|
-
|
|
2575
|
-
|
|
2576
|
-
text: string;
|
|
2577
|
-
};
|
|
2578
|
-
type ReasoningPart = {
|
|
2579
|
-
type: "reasoning";
|
|
2580
|
-
text: string;
|
|
2581
|
-
};
|
|
2582
|
-
type ToolPartActionType = "read" | "write" | "execute" | "network" | "other";
|
|
2583
|
-
type ToolPartStatus = "pending" | "running" | "completed" | "failed" | "denied";
|
|
2584
|
-
type ToolPart = {
|
|
2585
|
-
type: "tool";
|
|
2586
|
-
tool: string;
|
|
2587
|
-
callId?: string;
|
|
2588
|
-
actionType?: ToolPartActionType;
|
|
2589
|
-
status?: ToolPartStatus;
|
|
2590
|
-
state?: {
|
|
2591
|
-
status?: string;
|
|
2592
|
-
input?: unknown;
|
|
2593
|
-
output?: unknown;
|
|
2594
|
-
errorText?: string;
|
|
2595
|
-
metadata?: unknown;
|
|
2596
|
-
};
|
|
2597
|
-
};
|
|
2598
|
-
type StepStartPart = {
|
|
2599
|
-
type: "step-start";
|
|
2600
|
-
snapshot?: string;
|
|
2601
|
-
};
|
|
2602
|
-
type StepFinishPart = {
|
|
2603
|
-
type: "step-finish";
|
|
2604
|
-
reason?: string;
|
|
2605
|
-
snapshot?: string;
|
|
2606
|
-
cost?: number;
|
|
2607
|
-
tokens?: unknown;
|
|
2608
|
-
};
|
|
2609
|
-
type PatchPart = {
|
|
2610
|
-
type: "patch";
|
|
2611
|
-
hash?: string;
|
|
2612
|
-
files?: unknown;
|
|
2613
|
-
};
|
|
2614
|
-
type FilePart = {
|
|
2615
|
-
type: "file";
|
|
2616
|
-
fileId?: string;
|
|
2617
|
-
mediaType?: string;
|
|
2618
|
-
filename?: string;
|
|
2619
|
-
size?: number;
|
|
2620
|
-
url: string;
|
|
2621
|
-
};
|
|
2622
|
-
type LoadingPart = {
|
|
2623
|
-
type: "loading";
|
|
2624
|
-
};
|
|
2625
|
-
type ErrorPart = {
|
|
2626
|
-
type: "error";
|
|
2627
|
-
errorType: "timeout" | "crash" | "permission" | "other";
|
|
2628
|
-
message?: string;
|
|
2629
|
-
};
|
|
2630
|
-
type TokenUsagePart = {
|
|
2631
|
-
type: "token_usage";
|
|
2632
|
-
inputTokens: number;
|
|
2633
|
-
outputTokens: number;
|
|
2634
|
-
cacheReadTokens?: number;
|
|
2635
|
-
cacheWriteTokens?: number;
|
|
2636
|
-
};
|
|
2637
|
-
type SessionMessagePart = TextPart | ReasoningPart | ToolPart | StepStartPart | StepFinishPart | PatchPart | FilePart | LoadingPart | ErrorPart | TokenUsagePart;
|
|
2638
|
-
type SessionMessage = {
|
|
2438
|
+
interface DataTableRendererQueryResult {
|
|
2439
|
+
rows: DataTableRendererRow[];
|
|
2440
|
+
columns?: DataTableRendererColumn[];
|
|
2441
|
+
}
|
|
2442
|
+
interface DataTableRendererRowAction<TParams extends Struct = Struct> {
|
|
2639
2443
|
id: string;
|
|
2640
|
-
|
|
2641
|
-
|
|
2642
|
-
|
|
2643
|
-
|
|
2644
|
-
|
|
2645
|
-
|
|
2646
|
-
|
|
2647
|
-
|
|
2648
|
-
|
|
2649
|
-
|
|
2650
|
-
|
|
2651
|
-
|
|
2652
|
-
|
|
2653
|
-
|
|
2654
|
-
|
|
2655
|
-
|
|
2444
|
+
label: Localizable<string>;
|
|
2445
|
+
icon?: string;
|
|
2446
|
+
destructive?: boolean;
|
|
2447
|
+
command: CommandRef<TParams, unknown>;
|
|
2448
|
+
}
|
|
2449
|
+
interface DataTableRendererSelectionAction<TParams extends Struct = Struct> {
|
|
2450
|
+
id: string;
|
|
2451
|
+
label: Localizable<string>;
|
|
2452
|
+
icon?: string;
|
|
2453
|
+
destructive?: boolean;
|
|
2454
|
+
command: CommandRef<TParams, unknown>;
|
|
2455
|
+
}
|
|
2456
|
+
type DataTableRendererRowActivationHandler = RendererCallback<{
|
|
2457
|
+
row: DataTableRendererRow;
|
|
2458
|
+
}, void>;
|
|
2459
|
+
interface DataTableRendererContribution extends RendererContributionBase {
|
|
2460
|
+
toolbarActions?: ViewToolbarAction[];
|
|
2461
|
+
columns?: DataTableRendererColumn[];
|
|
2462
|
+
query: RendererCallback<DataTableRendererQueryParams, DataTableRendererQueryResult>;
|
|
2463
|
+
selectionMode?: "none" | "multiple";
|
|
2464
|
+
selectionActions?: DataTableRendererSelectionAction[];
|
|
2465
|
+
rowActions?: DataTableRendererRowAction[];
|
|
2466
|
+
onRowActivate?: DataTableRendererRowActivationHandler;
|
|
2467
|
+
initialPageSize?: number;
|
|
2468
|
+
pageSizeOptions?: number[];
|
|
2469
|
+
}
|
|
2656
2470
|
//#endregion
|
|
2657
|
-
//#region ../pstdio-api-contracts/src/
|
|
2658
|
-
type
|
|
2659
|
-
|
|
2660
|
-
|
|
2661
|
-
|
|
2662
|
-
|
|
2663
|
-
|
|
2664
|
-
|
|
2665
|
-
|
|
2666
|
-
|
|
2667
|
-
|
|
2471
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/tree-renderer.d.ts
|
|
2472
|
+
type TreeRendererResourceRef = ResourceRef;
|
|
2473
|
+
interface TreeRendererState {
|
|
2474
|
+
expandedNodeIds: string[];
|
|
2475
|
+
expandedSectionIds: string[];
|
|
2476
|
+
selectedNodeId?: string;
|
|
2477
|
+
}
|
|
2478
|
+
interface TreeRendererQueryParams {
|
|
2479
|
+
renderer: RendererContext;
|
|
2480
|
+
state?: TreeRendererState;
|
|
2481
|
+
filter?: string;
|
|
2482
|
+
}
|
|
2483
|
+
interface TreeRendererChildrenParams extends TreeRendererQueryParams {
|
|
2484
|
+
node: TreeNode;
|
|
2485
|
+
}
|
|
2486
|
+
interface TreeRendererActionParams extends TreeRendererQueryParams {
|
|
2487
|
+
actionId: string;
|
|
2488
|
+
node?: TreeNode;
|
|
2489
|
+
}
|
|
2490
|
+
type TreeNodeTarget = NavigationTarget;
|
|
2491
|
+
interface TreeAction {
|
|
2668
2492
|
id: string;
|
|
2669
|
-
|
|
2670
|
-
|
|
2671
|
-
|
|
2672
|
-
|
|
2673
|
-
|
|
2493
|
+
label?: Localizable<string>;
|
|
2494
|
+
icon?: string;
|
|
2495
|
+
command?: CommandRef<Struct, unknown>;
|
|
2496
|
+
params?: Struct;
|
|
2497
|
+
input?: ParamObjectSchema;
|
|
2498
|
+
submitLabel?: string;
|
|
2499
|
+
when?: string;
|
|
2500
|
+
disabled?: boolean;
|
|
2501
|
+
}
|
|
2502
|
+
interface TreeSectionEmptyState {
|
|
2503
|
+
title: Localizable<string>;
|
|
2504
|
+
description?: Localizable<string>;
|
|
2505
|
+
icon?: string;
|
|
2506
|
+
}
|
|
2507
|
+
type TreeNodeRowVariant = "empty-state";
|
|
2508
|
+
interface TreeNode {
|
|
2509
|
+
id: string;
|
|
2510
|
+
label: Localizable<string>;
|
|
2511
|
+
icon?: string;
|
|
2512
|
+
iconColor?: string;
|
|
2513
|
+
iconTooltip?: string;
|
|
2514
|
+
resource?: TreeRendererResourceRef;
|
|
2515
|
+
target?: TreeNodeTarget;
|
|
2516
|
+
/** Visual row variant for non-data rows such as placeholders. */
|
|
2517
|
+
rowVariant?: TreeNodeRowVariant;
|
|
2518
|
+
actions?: TreeAction[];
|
|
2519
|
+
contextMenuActions?: TreeAction[];
|
|
2520
|
+
collapsible?: boolean;
|
|
2521
|
+
disabled?: boolean;
|
|
2522
|
+
selected?: boolean;
|
|
2523
|
+
children?: TreeNode[];
|
|
2524
|
+
description?: string;
|
|
2525
|
+
contextValue?: string;
|
|
2526
|
+
hiddenByDefault?: boolean;
|
|
2527
|
+
/** Opt in to the tree's hide/show customization menu (header/footer rows). Off by default. */
|
|
2528
|
+
canHide?: boolean;
|
|
2529
|
+
metadata?: JsonObject;
|
|
2530
|
+
}
|
|
2531
|
+
interface TreeViewSection {
|
|
2674
2532
|
id: string;
|
|
2675
|
-
|
|
2676
|
-
|
|
2677
|
-
|
|
2678
|
-
|
|
2679
|
-
|
|
2680
|
-
|
|
2681
|
-
|
|
2682
|
-
|
|
2683
|
-
|
|
2684
|
-
|
|
2685
|
-
|
|
2686
|
-
|
|
2687
|
-
|
|
2688
|
-
|
|
2689
|
-
|
|
2690
|
-
|
|
2691
|
-
|
|
2692
|
-
|
|
2693
|
-
}
|
|
2694
|
-
type
|
|
2695
|
-
type HarnessParams = Record<string, HarnessParamValue>;
|
|
2696
|
-
type HarnessWorkspaceContext = {
|
|
2697
|
-
workspaceId: string;
|
|
2698
|
-
executionTarget: WorkspaceExecutionTarget;
|
|
2699
|
-
};
|
|
2700
|
-
type HarnessExitStatus = "completed" | "failed" | "cancelled" | "disconnected";
|
|
2701
|
-
type HarnessExit = {
|
|
2702
|
-
status: HarnessExitStatus;
|
|
2703
|
-
};
|
|
2704
|
-
type HarnessSession = {
|
|
2705
|
-
/** Provider-side session id, used to resume/reattach later. */
|
|
2706
|
-
agentSessionId?: string;
|
|
2707
|
-
/** Settles exactly once; the host keys status transitions and persistence off it. */
|
|
2708
|
-
done: Promise<HarnessExit>;
|
|
2709
|
-
/** Called by the host on cancel or on its own activity timeout. */
|
|
2710
|
-
stop(): void | Promise<void>;
|
|
2711
|
-
timeoutStrategy?: TimeoutStrategy;
|
|
2712
|
-
/** Observability only. */
|
|
2713
|
-
pid?: number;
|
|
2714
|
-
};
|
|
2715
|
-
type HarnessStartInput = {
|
|
2716
|
-
prompt: string;
|
|
2717
|
-
/** Host session id (correlation / env injection). */
|
|
2718
|
-
sessionId: string;
|
|
2719
|
-
cwd?: string;
|
|
2720
|
-
workspace?: HarnessWorkspaceContext;
|
|
2721
|
-
model?: string | null;
|
|
2722
|
-
params?: HarnessParams;
|
|
2723
|
-
attachments?: HarnessAttachment[];
|
|
2724
|
-
events: HarnessEventSink;
|
|
2725
|
-
/** Aborted when the host cancels the request that started or resumed this session. */
|
|
2726
|
-
signal?: AbortSignal;
|
|
2727
|
-
};
|
|
2728
|
-
type HarnessResumeInput = HarnessStartInput & {
|
|
2729
|
-
agentSessionId: string;
|
|
2730
|
-
/** Index offset so resumed streams align message patches with existing history. */
|
|
2731
|
-
messageOffset?: number;
|
|
2732
|
-
questionResponse?: QuestionResponse;
|
|
2733
|
-
approvals?: HarnessApprovalChannel;
|
|
2734
|
-
};
|
|
2735
|
-
type HarnessReattachInput = {
|
|
2736
|
-
sessionId: string;
|
|
2737
|
-
agentSessionId: string;
|
|
2738
|
-
cwd?: string;
|
|
2739
|
-
workspace?: HarnessWorkspaceContext;
|
|
2740
|
-
events: HarnessEventSink;
|
|
2741
|
-
/** Aborted when the host stops orphan recovery, including during shutdown. */
|
|
2742
|
-
signal?: AbortSignal;
|
|
2743
|
-
};
|
|
2744
|
-
type HarnessMessagesInput = {
|
|
2745
|
-
agentSessionId: string;
|
|
2746
|
-
cwd?: string;
|
|
2747
|
-
workspace?: HarnessWorkspaceContext;
|
|
2748
|
-
};
|
|
2749
|
-
type HarnessRecoveryInput = {
|
|
2750
|
-
knownMessages: readonly SessionMessage[];
|
|
2751
|
-
nativeMessages: readonly SessionMessage[];
|
|
2752
|
-
cwd?: string;
|
|
2753
|
-
workspace?: HarnessWorkspaceContext;
|
|
2754
|
-
};
|
|
2755
|
-
type HarnessRecoveryResult = {
|
|
2756
|
-
kind: "recovered";
|
|
2757
|
-
messages: SessionMessage[];
|
|
2758
|
-
} | {
|
|
2759
|
-
kind: "conflict";
|
|
2760
|
-
category: string;
|
|
2761
|
-
};
|
|
2533
|
+
label?: Localizable<string>;
|
|
2534
|
+
actions?: TreeAction[];
|
|
2535
|
+
collapsible?: boolean;
|
|
2536
|
+
emptyState?: TreeSectionEmptyState;
|
|
2537
|
+
nodes: TreeNode[];
|
|
2538
|
+
hiddenByDefault?: boolean;
|
|
2539
|
+
/** Opt in to the tree's hide/show customization menu (a category). Off by default. */
|
|
2540
|
+
canHide?: boolean;
|
|
2541
|
+
}
|
|
2542
|
+
interface TreeRendererContribution extends RendererContributionBase {
|
|
2543
|
+
searchable?: boolean;
|
|
2544
|
+
searchPlaceholder?: Localizable<string>;
|
|
2545
|
+
header?: RendererCallback<TreeRendererQueryParams, TreeViewSection[]>;
|
|
2546
|
+
body: RendererCallback<TreeRendererQueryParams, TreeViewSection[]>;
|
|
2547
|
+
children?: RendererCallback<TreeRendererChildrenParams, TreeNode[]>;
|
|
2548
|
+
footer?: RendererCallback<TreeRendererQueryParams, TreeViewSection[]>;
|
|
2549
|
+
defaultExpandedSectionIds?: string[];
|
|
2550
|
+
defaultExpandedNodeIds?: string[];
|
|
2551
|
+
}
|
|
2552
|
+
type TreeRendererCommandResult = TreeViewSection[] | TreeNode[] | JsonValue;
|
|
2762
2553
|
//#endregion
|
|
2763
|
-
//#region ../pstdio-api-contracts/src/extension-kernel/types/
|
|
2554
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/views.d.ts
|
|
2555
|
+
type NativeViewBody<Kind extends string, Definition> = {
|
|
2556
|
+
readonly kind: Kind;
|
|
2557
|
+
} & Omit<Definition, "title" | "icon" | "resourceKind">;
|
|
2558
|
+
type WebviewViewBody = {
|
|
2559
|
+
readonly kind: "webview";
|
|
2560
|
+
} & WebviewContribution;
|
|
2561
|
+
type TreeViewBody = NativeViewBody<"tree", TreeRendererContribution>;
|
|
2562
|
+
type FileViewBody = NativeViewBody<"file", FileRendererContribution>;
|
|
2563
|
+
type ControlsViewBody = NativeViewBody<"controls", ControlsRendererContribution>;
|
|
2564
|
+
type KanbanViewBody = NativeViewBody<"kanban", KanbanRendererContribution>;
|
|
2565
|
+
type DataTableViewBody = NativeViewBody<"dataTable", DataTableRendererContribution>;
|
|
2566
|
+
type ViewBody = WebviewViewBody | TreeViewBody | FileViewBody | ControlsViewBody | KanbanViewBody | DataTableViewBody;
|
|
2567
|
+
interface ViewContribution extends ContributionDefinition<"view"> {
|
|
2568
|
+
readonly title: Localizable<string>;
|
|
2569
|
+
readonly icon?: string;
|
|
2570
|
+
readonly body: ViewBody;
|
|
2571
|
+
}
|
|
2572
|
+
type NavigationOwnerRef = ModeRef | PageRef;
|
|
2573
|
+
type NavigationTreeSlot = "header" | "content" | "footer";
|
|
2574
|
+
interface NavigationItemContribution extends ContributionDefinition<"navigation-item"> {
|
|
2575
|
+
readonly owner: NavigationOwnerRef;
|
|
2576
|
+
readonly slot?: NavigationTreeSlot;
|
|
2577
|
+
readonly label: Localizable<string>;
|
|
2578
|
+
readonly icon?: string;
|
|
2579
|
+
readonly group?: string;
|
|
2580
|
+
readonly when?: WhenExpression;
|
|
2581
|
+
readonly action: NavigationTarget;
|
|
2582
|
+
}
|
|
2583
|
+
interface NavigationTreeContribution extends ContributionDefinition<"navigation-tree"> {
|
|
2584
|
+
readonly owner: NavigationOwnerRef;
|
|
2585
|
+
readonly slot?: NavigationTreeSlot;
|
|
2586
|
+
readonly view: ViewRef;
|
|
2587
|
+
/** Project-scoped trees read without a selected resource. Defaults to selection. */
|
|
2588
|
+
readonly resourceScope?: "project" | "selection";
|
|
2589
|
+
}
|
|
2764
2590
|
/**
|
|
2765
|
-
*
|
|
2766
|
-
*
|
|
2591
|
+
* Initial presence of a static placement inside its owner scope.
|
|
2592
|
+
* - "fixed": always open while the owner is active; the user cannot close it.
|
|
2593
|
+
* - "open": open when the owner has no saved state; the user may close it.
|
|
2594
|
+
* - "closed": closed until the user opens it (for example through the Add panel).
|
|
2595
|
+
* A saved user choice wins over "open" and "closed" on the next visit.
|
|
2767
2596
|
*/
|
|
2768
|
-
|
|
2769
|
-
|
|
2770
|
-
|
|
2771
|
-
|
|
2772
|
-
|
|
2773
|
-
|
|
2774
|
-
|
|
2775
|
-
|
|
2776
|
-
|
|
2777
|
-
|
|
2778
|
-
|
|
2597
|
+
type PlacementPresence = "fixed" | "open" | "closed";
|
|
2598
|
+
type PlacementItem = {
|
|
2599
|
+
readonly kind: "view";
|
|
2600
|
+
readonly view: ViewRef;
|
|
2601
|
+
readonly presence: PlacementPresence;
|
|
2602
|
+
} | {
|
|
2603
|
+
readonly kind: "binding";
|
|
2604
|
+
readonly binding: ResourceBinding;
|
|
2605
|
+
};
|
|
2606
|
+
type PlacementMountStrategy = "active" | "keep-mounted";
|
|
2607
|
+
interface PlacementTabMenuRow {
|
|
2608
|
+
readonly id: string;
|
|
2609
|
+
readonly label: Localizable<string>;
|
|
2610
|
+
readonly icon?: string;
|
|
2611
|
+
readonly iconColor?: string;
|
|
2612
|
+
readonly selected?: boolean;
|
|
2613
|
+
readonly disabled?: boolean;
|
|
2614
|
+
readonly action?: NavigationTarget;
|
|
2779
2615
|
}
|
|
2780
|
-
interface
|
|
2781
|
-
|
|
2782
|
-
|
|
2783
|
-
|
|
2616
|
+
interface PlacementTabMenuGroup {
|
|
2617
|
+
readonly id: string;
|
|
2618
|
+
readonly rows: readonly PlacementTabMenuRow[];
|
|
2619
|
+
}
|
|
2620
|
+
interface PlacementTabSnapshot extends Struct {
|
|
2621
|
+
readonly label?: Localizable<string>;
|
|
2622
|
+
readonly icon?: string;
|
|
2623
|
+
readonly indicator?: {
|
|
2624
|
+
readonly icon: string;
|
|
2625
|
+
readonly color?: string;
|
|
2626
|
+
readonly label?: Localizable<string>;
|
|
2627
|
+
};
|
|
2628
|
+
readonly menu?: readonly PlacementTabMenuGroup[];
|
|
2629
|
+
}
|
|
2630
|
+
interface PlacementTabPresentation {
|
|
2631
|
+
readonly query: RendererCallback<JsonObject, PlacementTabSnapshot>;
|
|
2632
|
+
readonly refreshEvents?: readonly RendererEventReference[];
|
|
2633
|
+
}
|
|
2634
|
+
interface PlacementPresentation {
|
|
2635
|
+
readonly mountStrategy?: PlacementMountStrategy;
|
|
2636
|
+
readonly hiddenByDefault?: boolean;
|
|
2637
|
+
readonly headerBorderBottom?: boolean;
|
|
2638
|
+
readonly tab?: PlacementTabPresentation;
|
|
2639
|
+
}
|
|
2640
|
+
interface PlacementContribution extends ContributionDefinition<"placement">, PlacementPresentation {
|
|
2641
|
+
readonly mode: ModeRef;
|
|
2642
|
+
readonly item: PlacementItem;
|
|
2643
|
+
readonly region: ExtensionPanelRegion;
|
|
2644
|
+
readonly order?: number;
|
|
2645
|
+
readonly movableTo?: readonly ExtensionPanelRegion[];
|
|
2646
|
+
}
|
|
2647
|
+
interface ViewMenuContribution extends ContributionDefinition<"view-menu"> {
|
|
2648
|
+
readonly owner: ViewRef;
|
|
2649
|
+
readonly view: ViewRef;
|
|
2650
|
+
readonly side: "left" | "right";
|
|
2651
|
+
readonly group?: string;
|
|
2652
|
+
readonly placement?: "first" | "default" | "last";
|
|
2653
|
+
readonly hostTreeHeader?: "default" | "none";
|
|
2654
|
+
readonly hostTreeFooter?: "default" | "none";
|
|
2655
|
+
}
|
|
2656
|
+
//#endregion
|
|
2657
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/pages.d.ts
|
|
2658
|
+
type PageSlotRole = "primary" | "auxiliary";
|
|
2659
|
+
type PageSlotCardinality = "one" | "many";
|
|
2660
|
+
type PageOpenIntent = "preview" | "pin";
|
|
2661
|
+
type PageSlotRegion = ExtensionPanelRegion;
|
|
2662
|
+
interface PageMainView extends PlacementPresentation {
|
|
2663
|
+
readonly kind: "view";
|
|
2664
|
+
readonly view: ViewRef;
|
|
2665
|
+
readonly cardinality: PageSlotCardinality;
|
|
2666
|
+
}
|
|
2667
|
+
interface PageMainPanels {
|
|
2668
|
+
readonly kind: "panels";
|
|
2669
|
+
readonly empty: ViewRef;
|
|
2670
|
+
}
|
|
2671
|
+
type PageMain = PageMainView | PageMainPanels;
|
|
2672
|
+
/** A page-owned panel. Main presentation and routed context belong to the page. */
|
|
2673
|
+
interface PageSlot extends PlacementPresentation {
|
|
2674
|
+
readonly id: string;
|
|
2675
|
+
readonly region: PageSlotRegion;
|
|
2676
|
+
readonly order?: number;
|
|
2677
|
+
readonly item: PlacementItem;
|
|
2678
|
+
readonly openOn?: "page-resource";
|
|
2784
2679
|
}
|
|
2785
|
-
interface
|
|
2786
|
-
|
|
2787
|
-
|
|
2788
|
-
|
|
2680
|
+
interface PageSlotRef {
|
|
2681
|
+
readonly kind: "page-slot";
|
|
2682
|
+
readonly page: PageRef;
|
|
2683
|
+
readonly id: string;
|
|
2789
2684
|
}
|
|
2790
|
-
|
|
2791
|
-
interface
|
|
2792
|
-
|
|
2793
|
-
|
|
2794
|
-
|
|
2685
|
+
type PanelRef = PlacementRef | PageSlotRef;
|
|
2686
|
+
interface PageContribution extends ContributionDefinition<"page"> {
|
|
2687
|
+
readonly title: Localizable<string>;
|
|
2688
|
+
readonly icon?: string;
|
|
2689
|
+
readonly path: string;
|
|
2690
|
+
readonly mode: ModeRef;
|
|
2691
|
+
readonly parent?: PageRef;
|
|
2692
|
+
readonly resource?: ResourceConstraint;
|
|
2693
|
+
readonly main: PageMain;
|
|
2694
|
+
readonly slots: readonly PageSlot[];
|
|
2695
|
+
readonly panels: Readonly<Record<string, PageSlotRef>>;
|
|
2795
2696
|
}
|
|
2796
|
-
|
|
2797
|
-
|
|
2798
|
-
readonly
|
|
2697
|
+
type PlacementOwner = {
|
|
2698
|
+
readonly kind: "shell";
|
|
2699
|
+
readonly placementId: string;
|
|
2700
|
+
} | {
|
|
2701
|
+
readonly kind: "mode";
|
|
2702
|
+
readonly modeId: string;
|
|
2703
|
+
readonly placementId: string;
|
|
2704
|
+
} | {
|
|
2705
|
+
readonly kind: "page";
|
|
2706
|
+
readonly pageId: string;
|
|
2707
|
+
readonly slotId: string;
|
|
2799
2708
|
};
|
|
2800
|
-
type
|
|
2801
|
-
|
|
2802
|
-
|
|
2803
|
-
|
|
2804
|
-
|
|
2805
|
-
|
|
2806
|
-
|
|
2807
|
-
|
|
2808
|
-
label: Localizable<string>;
|
|
2809
|
-
/** Declares skill directories so the host installs project skills for this agent. Absent = no skill setup. */
|
|
2810
|
-
skills?: HarnessSkillsLayout;
|
|
2811
|
-
/** Discrete run params the host can render, persist as defaults, validate, and pass to start/resume. */
|
|
2812
|
-
params?: HarnessParamsSchema;
|
|
2813
|
-
/** Defaults to required. Optional harnesses can run against remote workspace execution targets. */
|
|
2814
|
-
cwdRequirement?: "required" | "optional";
|
|
2815
|
-
capabilities(ctx: HarnessContext): MaybePromise<AgentCapability[]>;
|
|
2816
|
-
detect?(ctx: HarnessContext): MaybePromise<HarnessDetectionResult>;
|
|
2817
|
-
listModels?(ctx: HarnessContext): MaybePromise<AgentModel[]>;
|
|
2818
|
-
start(ctx: HarnessContext, input: HarnessStartInput): MaybePromise<HarnessSession>;
|
|
2819
|
-
resume(ctx: HarnessContext, input: HarnessResumeInput): MaybePromise<HarnessSession>;
|
|
2820
|
-
/** Re-bind after a host restart. Throw a `RetryableHarnessReattachError` only when another attempt may succeed. */
|
|
2821
|
-
reattach?(ctx: HarnessContext, input: HarnessReattachInput): MaybePromise<HarnessSession>;
|
|
2822
|
-
getMessages?(ctx: HarnessContext, input: HarnessMessagesInput): MaybePromise<SessionMessage[]>;
|
|
2823
|
-
recoverMessages?(ctx: HarnessContext, input: HarnessRecoveryInput): MaybePromise<HarnessRecoveryResult>;
|
|
2709
|
+
type PlacementIdentity = PlacementOwner & {
|
|
2710
|
+
readonly instanceKey: string;
|
|
2711
|
+
};
|
|
2712
|
+
interface PageLocation {
|
|
2713
|
+
readonly page: PageRef;
|
|
2714
|
+
readonly resource?: ResourceRef;
|
|
2715
|
+
readonly section?: FileRendererSectionTarget;
|
|
2716
|
+
readonly parent?: PageLocation;
|
|
2824
2717
|
}
|
|
2825
2718
|
//#endregion
|
|
2826
2719
|
//#region ../pstdio-api-contracts/src/extension-kernel/types/statuses.d.ts
|
|
@@ -2858,8 +2751,8 @@ interface StatusBarItemContribution extends ContributionDefinition<"status-bar-i
|
|
|
2858
2751
|
}
|
|
2859
2752
|
//#endregion
|
|
2860
2753
|
//#region ../pstdio-api-contracts/src/extension-kernel/types/extension.d.ts
|
|
2861
|
-
/** Current host extension API version. `engines.pstdio`
|
|
2862
|
-
declare const EXTENSION_API_VERSION = "
|
|
2754
|
+
/** Current host extension API version. `engines.pstdio` declares caret ranges, such as `^0.1.0`. */
|
|
2755
|
+
declare const EXTENSION_API_VERSION = "0.1.1";
|
|
2863
2756
|
type SchemaParams<TSchema extends ParamObjectSchema | undefined> = TSchema extends ParamObjectSchema ? ParamsOf<TSchema> : Record<string, never>;
|
|
2864
2757
|
interface WorkspaceProviderRef {
|
|
2865
2758
|
version: number;
|
|
@@ -3408,33 +3301,228 @@ interface ExtensionContextBase<TSettings extends Record<string, unknown> = Recor
|
|
|
3408
3301
|
logger: ExtensionLoggerApi;
|
|
3409
3302
|
settings: ExtensionSettingsApi<TSettings>;
|
|
3410
3303
|
}
|
|
3411
|
-
interface CommandContext<TSettings extends Record<string, unknown> = Record<string, unknown>> extends ExtensionContextBase<TSettings> {
|
|
3304
|
+
interface CommandContext<TSettings extends Record<string, unknown> = Record<string, unknown>> extends ExtensionContextBase<TSettings> {
|
|
3305
|
+
commandId: string;
|
|
3306
|
+
invocationId: string;
|
|
3307
|
+
/** Aborts when the host cancels this command run. Handlers must stop external side effects when it fires. */
|
|
3308
|
+
signal: AbortSignal;
|
|
3309
|
+
invocation: {
|
|
3310
|
+
readonly source?: CommandSource;
|
|
3311
|
+
readonly attachment?: WorkbenchAttachmentInvocationContext;
|
|
3312
|
+
readonly slot?: SlotInvocationContext;
|
|
3313
|
+
readonly metadata?: JsonObject;
|
|
3314
|
+
};
|
|
3315
|
+
resource?: ResourceRef;
|
|
3316
|
+
attachment?: WorkbenchAttachmentInvocationContext;
|
|
3317
|
+
slot?: SlotInvocationContext;
|
|
3318
|
+
}
|
|
3319
|
+
type CommandMiddlewareContext = CommandContext;
|
|
3320
|
+
type CommandMiddlewareHandler<TParams extends Struct = Struct> = (ctx: CommandMiddlewareContext, params: TParams) => MaybePromise<CommandMiddlewareResult<TParams>>;
|
|
3321
|
+
type CommandRunHandler<TParams extends Struct = Struct, TResult = unknown, TSettings extends Record<string, unknown> = Record<string, unknown>> = (ctx: CommandContext<TSettings>, params: TParams) => MaybePromise<TResult>;
|
|
3322
|
+
type RendererCallback<TInput extends Struct = Struct, TResult = unknown, TSettings extends Record<string, unknown> = Record<string, unknown>> = (ctx: ExtensionContextBase<TSettings>, input: TInput & {
|
|
3323
|
+
renderer: RendererContext;
|
|
3324
|
+
}) => MaybePromise<TResult>;
|
|
3325
|
+
interface EventContext extends ExtensionContextBase {
|
|
3326
|
+
eventId: string;
|
|
3327
|
+
deliveryId: string;
|
|
3328
|
+
}
|
|
3329
|
+
type SetupContext = ExtensionContextBase;
|
|
3330
|
+
type MigrationContext = ExtensionContextBase;
|
|
3331
|
+
//#endregion
|
|
3332
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/file-renderer.d.ts
|
|
3333
|
+
type FileRendererResourceRef = ResourceRef;
|
|
3334
|
+
interface FileRendererSectionAnchor {
|
|
3335
|
+
/** Stable extension-owned tree node id. */
|
|
3336
|
+
id: string;
|
|
3337
|
+
/** Plain heading text as it appears in the Markdown document. */
|
|
3338
|
+
heading: string;
|
|
3339
|
+
/** Zero-based occurrence when the document repeats the same heading text. */
|
|
3340
|
+
occurrence?: number;
|
|
3341
|
+
}
|
|
3342
|
+
interface FileRendererSectionTarget {
|
|
3343
|
+
/** The document outline used for deep-linking and active-heading sync. */
|
|
3344
|
+
anchors: FileRendererSectionAnchor[];
|
|
3345
|
+
}
|
|
3346
|
+
interface FileRendererLoadParams {
|
|
3347
|
+
renderer: RendererContext;
|
|
3348
|
+
}
|
|
3349
|
+
interface FileRendererLoadResult {
|
|
3350
|
+
fileName?: string;
|
|
3351
|
+
mimeType?: string;
|
|
3352
|
+
content?: string;
|
|
3353
|
+
dataUrl?: string;
|
|
3354
|
+
placeholder?: string;
|
|
3355
|
+
/** Override contribution-level save support for one loaded file. */
|
|
3356
|
+
editable?: boolean;
|
|
3357
|
+
/** Request Monaco for text that automatic dispatch would open as markdown. */
|
|
3358
|
+
textRenderer?: "automatic" | "monaco";
|
|
3359
|
+
/** Represent a deliberate no-file selection without an editable blank document. */
|
|
3360
|
+
emptyState?: {
|
|
3361
|
+
title: string;
|
|
3362
|
+
description?: string;
|
|
3363
|
+
};
|
|
3364
|
+
}
|
|
3365
|
+
interface FileRendererSaveParams {
|
|
3366
|
+
renderer: RendererContext;
|
|
3367
|
+
content: string;
|
|
3368
|
+
}
|
|
3369
|
+
interface FileRendererContribution extends RendererContributionBase {
|
|
3370
|
+
load: RendererCallback<FileRendererLoadParams, FileRendererLoadResult>;
|
|
3371
|
+
save?: RendererCallback<FileRendererSaveParams, unknown>;
|
|
3372
|
+
}
|
|
3373
|
+
//#endregion
|
|
3374
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/navigation-target.d.ts
|
|
3375
|
+
interface NavigationTargetPage {
|
|
3376
|
+
kind: "page";
|
|
3377
|
+
page: PageRef;
|
|
3378
|
+
resource?: ResourceRef;
|
|
3379
|
+
section?: FileRendererSectionTarget;
|
|
3380
|
+
open?: PageOpenIntent;
|
|
3381
|
+
parent?: NavigationTargetPage;
|
|
3382
|
+
}
|
|
3383
|
+
interface NavigationTargetPanel {
|
|
3384
|
+
kind: "panel";
|
|
3385
|
+
panel: PanelRef;
|
|
3386
|
+
resource?: ResourceRef;
|
|
3387
|
+
open?: PageOpenIntent;
|
|
3388
|
+
}
|
|
3389
|
+
interface NavigationTargetCommand {
|
|
3390
|
+
kind: "command";
|
|
3391
|
+
target: CommandTarget<JsonObject>;
|
|
3392
|
+
}
|
|
3393
|
+
interface NavigationTargetHref {
|
|
3394
|
+
kind: "href";
|
|
3395
|
+
href: string;
|
|
3396
|
+
}
|
|
3397
|
+
type NavigationTargetItem = NavigationTargetPage | NavigationTargetPanel | NavigationTargetCommand | NavigationTargetHref;
|
|
3398
|
+
interface NavigationTargetCompound {
|
|
3399
|
+
kind: "compound";
|
|
3400
|
+
targets: readonly (NavigationTargetPage | NavigationTargetPanel)[];
|
|
3401
|
+
}
|
|
3402
|
+
type NavigationTarget = NavigationTargetItem | NavigationTargetCompound;
|
|
3403
|
+
//#endregion
|
|
3404
|
+
//#region ../pstdio-api-contracts/src/extension-kernel/types/commands.d.ts
|
|
3405
|
+
type CommandSource = "cli" | "dashboard" | "api" | "schedule" | "event" | "automation" | "command-panel";
|
|
3406
|
+
interface CommandRef<TParams extends Struct = Struct, TResult = unknown> extends ContributionRef<"command"> {
|
|
3407
|
+
params?: TParams;
|
|
3408
|
+
result?: TResult;
|
|
3409
|
+
}
|
|
3410
|
+
interface CommandTarget<TParams extends Struct = Struct> {
|
|
3411
|
+
command: CommandRef<TParams, unknown>;
|
|
3412
|
+
params?: TParams;
|
|
3413
|
+
}
|
|
3414
|
+
interface SerializedError {
|
|
3415
|
+
name?: string;
|
|
3416
|
+
message: string;
|
|
3417
|
+
stack?: string;
|
|
3418
|
+
cause?: JsonValue;
|
|
3419
|
+
}
|
|
3420
|
+
interface WorkbenchAttachmentInvocationContext {
|
|
3421
|
+
target: WorkbenchAttachmentTarget;
|
|
3422
|
+
mode?: string;
|
|
3423
|
+
projectId?: string;
|
|
3424
|
+
resource?: ResourceRef;
|
|
3425
|
+
}
|
|
3426
|
+
interface CommandInvocation<TParams extends Struct = Struct> {
|
|
3427
|
+
params: TParams;
|
|
3428
|
+
resource?: ResourceRef;
|
|
3429
|
+
attachment?: WorkbenchAttachmentInvocationContext;
|
|
3430
|
+
slot?: SlotInvocationContext;
|
|
3431
|
+
metadata?: JsonObject;
|
|
3432
|
+
}
|
|
3433
|
+
interface CommandContinue {
|
|
3434
|
+
type: "continue";
|
|
3435
|
+
}
|
|
3436
|
+
interface CommandPatchParams<TParams extends Struct = Struct> {
|
|
3437
|
+
type: "patchParams";
|
|
3438
|
+
params: Partial<TParams>;
|
|
3439
|
+
}
|
|
3440
|
+
interface CommandReplaceParams<TParams extends Struct = Struct> {
|
|
3441
|
+
type: "replaceParams";
|
|
3442
|
+
params: TParams;
|
|
3443
|
+
}
|
|
3444
|
+
interface CommandReplaceInvocation<TParams extends Struct = Struct> {
|
|
3445
|
+
type: "replaceInvocation";
|
|
3446
|
+
invocation: CommandInvocation<TParams>;
|
|
3447
|
+
}
|
|
3448
|
+
interface CommandReject {
|
|
3449
|
+
type: "reject";
|
|
3450
|
+
code?: string;
|
|
3451
|
+
reason: string;
|
|
3452
|
+
data?: JsonObject;
|
|
3453
|
+
}
|
|
3454
|
+
type CommandMiddlewareResult<TParams extends Struct = Struct> = void | CommandContinue | CommandPatchParams<TParams> | CommandReplaceParams<TParams> | CommandReplaceInvocation<TParams> | CommandReject;
|
|
3455
|
+
interface CommandNotice {
|
|
3456
|
+
type: "info" | "success" | "warning" | "error";
|
|
3457
|
+
title?: string;
|
|
3458
|
+
message: string;
|
|
3459
|
+
metadata?: JsonObject;
|
|
3460
|
+
}
|
|
3461
|
+
interface CommandDiagnostic {
|
|
3462
|
+
code: string;
|
|
3463
|
+
message: string;
|
|
3464
|
+
severity: "info" | "warning" | "error";
|
|
3465
|
+
extensionId?: string;
|
|
3466
|
+
commandId?: string;
|
|
3467
|
+
metadata?: JsonObject;
|
|
3468
|
+
}
|
|
3469
|
+
type CommandOutcome<TResult = unknown> = {
|
|
3470
|
+
ok: true;
|
|
3471
|
+
status: "success";
|
|
3472
|
+
value: TResult;
|
|
3473
|
+
navigationRequests?: NavigationTarget[];
|
|
3474
|
+
notices?: CommandNotice[];
|
|
3475
|
+
diagnostics?: CommandDiagnostic[];
|
|
3476
|
+
} | {
|
|
3477
|
+
ok: false;
|
|
3478
|
+
status: "rejected";
|
|
3479
|
+
code?: string;
|
|
3480
|
+
reason: string;
|
|
3481
|
+
data?: JsonObject;
|
|
3482
|
+
notices?: CommandNotice[];
|
|
3483
|
+
diagnostics?: CommandDiagnostic[];
|
|
3484
|
+
} | {
|
|
3485
|
+
ok: false;
|
|
3486
|
+
status: "error";
|
|
3487
|
+
code?: string;
|
|
3488
|
+
reason: string;
|
|
3489
|
+
error?: SerializedError;
|
|
3490
|
+
notices?: CommandNotice[];
|
|
3491
|
+
diagnostics?: CommandDiagnostic[];
|
|
3492
|
+
};
|
|
3493
|
+
interface CommandHelpersApi {
|
|
3494
|
+
execute<TParams extends Struct = Struct, TResult = unknown>(command: CommandRef<TParams, TResult>, invocation: CommandInvocation<TParams>): Promise<CommandOutcome<TResult>>;
|
|
3495
|
+
continue(): CommandContinue;
|
|
3496
|
+
patchParams<TParams extends Struct = Struct>(params: Partial<TParams>): CommandPatchParams<TParams>;
|
|
3497
|
+
replaceParams<TParams extends Struct = Struct>(params: TParams): CommandReplaceParams<TParams>;
|
|
3498
|
+
replaceInvocation<TParams extends Struct = Struct>(invocation: CommandInvocation<TParams>): CommandReplaceInvocation<TParams>;
|
|
3499
|
+
reject(input: Omit<CommandReject, "type">): CommandReject;
|
|
3500
|
+
}
|
|
3501
|
+
interface CommandRequestedEvent<TParams extends Struct = Struct> {
|
|
3412
3502
|
commandId: string;
|
|
3413
3503
|
invocationId: string;
|
|
3414
|
-
|
|
3415
|
-
|
|
3416
|
-
invocation: {
|
|
3417
|
-
readonly source?: CommandSource;
|
|
3418
|
-
readonly attachment?: WorkbenchAttachmentInvocationContext;
|
|
3419
|
-
readonly slot?: SlotInvocationContext;
|
|
3420
|
-
readonly metadata?: JsonObject;
|
|
3421
|
-
};
|
|
3504
|
+
source?: CommandSource;
|
|
3505
|
+
params: TParams;
|
|
3422
3506
|
resource?: ResourceRef;
|
|
3423
|
-
attachment?: WorkbenchAttachmentInvocationContext;
|
|
3424
|
-
slot?: SlotInvocationContext;
|
|
3425
3507
|
}
|
|
3426
|
-
|
|
3427
|
-
|
|
3428
|
-
|
|
3429
|
-
|
|
3430
|
-
renderer: RendererContext;
|
|
3431
|
-
}) => MaybePromise<TResult>;
|
|
3432
|
-
interface EventContext extends ExtensionContextBase {
|
|
3433
|
-
eventId: string;
|
|
3434
|
-
deliveryId: string;
|
|
3508
|
+
interface CommandStartedEvent<TParams extends Struct = Struct> extends CommandRequestedEvent<TParams> {}
|
|
3509
|
+
interface CommandCompletedEvent<TParams extends Struct = Struct, TResult = unknown> extends CommandStartedEvent<TParams> {
|
|
3510
|
+
result: TResult;
|
|
3511
|
+
elapsedMs: number;
|
|
3435
3512
|
}
|
|
3436
|
-
|
|
3437
|
-
|
|
3513
|
+
interface CommandRejectedEvent<TParams extends Struct = Struct> extends CommandRequestedEvent<TParams> {
|
|
3514
|
+
code?: string;
|
|
3515
|
+
reason: string;
|
|
3516
|
+
data?: JsonObject;
|
|
3517
|
+
}
|
|
3518
|
+
interface CommandFailedEvent<TParams extends Struct = Struct> extends CommandRequestedEvent<TParams> {
|
|
3519
|
+
code?: string;
|
|
3520
|
+
reason: string;
|
|
3521
|
+
error?: SerializedError;
|
|
3522
|
+
elapsedMs: number;
|
|
3523
|
+
}
|
|
3524
|
+
type CommandLifecyclePhase = "requested" | "started" | "completed" | "rejected" | "failed";
|
|
3525
|
+
type CommandLifecycleEventPayload<TPhase extends CommandLifecyclePhase, TParams extends Struct = Struct, TResult = unknown> = TPhase extends "requested" ? CommandRequestedEvent<TParams> : TPhase extends "started" ? CommandStartedEvent<TParams> : TPhase extends "completed" ? CommandCompletedEvent<TParams, TResult> : TPhase extends "rejected" ? CommandRejectedEvent<TParams> : CommandFailedEvent<TParams>;
|
|
3438
3526
|
//#endregion
|
|
3439
3527
|
//#region ../pstdio-api-contracts/src/extension-kernel/types/composition.d.ts
|
|
3440
3528
|
declare const dockedWorkbenchRegions: readonly ["sidenav", "main", "secondary", "side"];
|
|
@@ -3460,6 +3548,14 @@ interface ResourceKindDefinition extends ContributionDefinition<"resource-kind">
|
|
|
3460
3548
|
readonly label?: Localizable<string>;
|
|
3461
3549
|
readonly icon?: string;
|
|
3462
3550
|
readonly menuSlots?: readonly ResourceMenuSlotDefinition[];
|
|
3551
|
+
/**
|
|
3552
|
+
* A command of this extension that returns the current reference for an open
|
|
3553
|
+
* resource, or null. The host runs it with `ctx.resource` set to the open
|
|
3554
|
+
* resource when the page opens and after the extension emits an event, and
|
|
3555
|
+
* shows the returned label, icon, and metadata. Keep metadata the page owns,
|
|
3556
|
+
* such as a selected document, from `ctx.resource`.
|
|
3557
|
+
*/
|
|
3558
|
+
readonly resolve?: CommandRef;
|
|
3463
3559
|
}
|
|
3464
3560
|
interface ResourceHierarchyProvider extends ContributionDefinition<"resource-hierarchy-provider"> {
|
|
3465
3561
|
resourceKind: ResourceKindRef;
|
|
@@ -4141,6 +4237,7 @@ type RequiredOf<TOptions> = TOptions extends {
|
|
|
4141
4237
|
type ParamOptions<TParam extends {
|
|
4142
4238
|
type: string;
|
|
4143
4239
|
}> = Omit<TParam, "type">;
|
|
4240
|
+
type SelectionOptions<TOptions> = TOptions extends ParamOption[] ? ParamOption[] : ParamOptionSource;
|
|
4144
4241
|
/**
|
|
4145
4242
|
* Builders for typed parameter descriptors. Each builder produces a discriminated
|
|
4146
4243
|
* `ParamDescriptor` so the runtime and editor only see fields valid for that type.
|
|
@@ -4152,14 +4249,22 @@ type ParamOptions<TParam extends {
|
|
|
4152
4249
|
* }
|
|
4153
4250
|
*/
|
|
4154
4251
|
declare const params: {
|
|
4252
|
+
valueOf: (key: string) => {
|
|
4253
|
+
kind: "param-value";
|
|
4254
|
+
key: string;
|
|
4255
|
+
};
|
|
4155
4256
|
text: <const TOptions extends ParamOptions<TextParam> | undefined = undefined>(options?: TOptions) => TextParam<RequiredOf<TOptions>>;
|
|
4156
4257
|
longText: <const TOptions extends ParamOptions<LongTextParam> | undefined = undefined>(options?: TOptions) => LongTextParam<RequiredOf<TOptions>>;
|
|
4157
4258
|
markdown: <const TOptions extends ParamOptions<MarkdownParam> | undefined = undefined>(options?: TOptions) => MarkdownParam<RequiredOf<TOptions>>;
|
|
4158
4259
|
files: <const TOptions extends ParamOptions<FilesParam> | undefined = undefined>(options?: TOptions) => FilesParam<RequiredOf<TOptions>>;
|
|
4159
4260
|
number: <const TOptions extends ParamOptions<NumberParam> | undefined = undefined>(options?: TOptions) => NumberParam<RequiredOf<TOptions>>;
|
|
4160
4261
|
boolean: <const TOptions extends ParamOptions<BooleanParam> | undefined = undefined>(options?: TOptions) => BooleanParam<RequiredOf<TOptions>>;
|
|
4161
|
-
select: <const TOptions extends ParamOptions<SelectParam>>(options: TOptions) => SelectParam<RequiredOf<TOptions
|
|
4162
|
-
|
|
4262
|
+
select: <const TOptions extends ParamOptions<SelectParam>>(options: TOptions) => Omit<SelectParam<RequiredOf<TOptions>>, "options"> & {
|
|
4263
|
+
options: SelectionOptions<TOptions["options"]>;
|
|
4264
|
+
};
|
|
4265
|
+
multiSelect: <const TOptions extends ParamOptions<MultiSelectParam>>(options: TOptions) => Omit<MultiSelectParam<RequiredOf<TOptions>>, "options"> & {
|
|
4266
|
+
options: SelectionOptions<TOptions["options"]>;
|
|
4267
|
+
};
|
|
4163
4268
|
harness: <const TOptions extends ParamOptions<HarnessParam> | undefined = undefined>(options?: TOptions) => HarnessParam<RequiredOf<TOptions>>;
|
|
4164
4269
|
workspace: <const TOptions extends ParamOptions<WorkspaceParam> | undefined = undefined>(options?: TOptions) => WorkspaceParam<RequiredOf<TOptions>>;
|
|
4165
4270
|
template: <const TOptions extends Omit<TemplateParam, "type" | "templateType"> & {
|
|
@@ -4374,8 +4479,8 @@ declare const automationRunStatusSchema: z.ZodEnum<{
|
|
|
4374
4479
|
failed: "failed";
|
|
4375
4480
|
cancelled: "cancelled";
|
|
4376
4481
|
running: "running";
|
|
4377
|
-
succeeded: "succeeded";
|
|
4378
4482
|
rejected: "rejected";
|
|
4483
|
+
succeeded: "succeeded";
|
|
4379
4484
|
}>;
|
|
4380
4485
|
declare const issueAutomationTokenInputSchema: z.ZodObject<{
|
|
4381
4486
|
name: z.ZodString;
|
|
@@ -4455,8 +4560,8 @@ declare const automationRunSchema: z.ZodObject<{
|
|
|
4455
4560
|
failed: "failed";
|
|
4456
4561
|
cancelled: "cancelled";
|
|
4457
4562
|
running: "running";
|
|
4458
|
-
succeeded: "succeeded";
|
|
4459
4563
|
rejected: "rejected";
|
|
4564
|
+
succeeded: "succeeded";
|
|
4460
4565
|
}>;
|
|
4461
4566
|
createdAt: z.ZodString;
|
|
4462
4567
|
startedAt: z.ZodNullable<z.ZodString>;
|
|
@@ -4495,6 +4600,151 @@ type AutomationRun = z.infer<typeof automationRunSchema>;
|
|
|
4495
4600
|
type AutomationRunEvent = z.infer<typeof automationRunEventSchema>;
|
|
4496
4601
|
type ListAutomationRunEventsResponse = z.infer<typeof listAutomationRunEventsResponseSchema>;
|
|
4497
4602
|
//#endregion
|
|
4603
|
+
//#region ../pstdio-api-contracts/src/board-views.d.ts
|
|
4604
|
+
declare const boardFieldSchema: z.ZodObject<{
|
|
4605
|
+
id: z.ZodString;
|
|
4606
|
+
label: z.ZodString;
|
|
4607
|
+
kind: z.ZodEnum<{
|
|
4608
|
+
string: "string";
|
|
4609
|
+
number: "number";
|
|
4610
|
+
status: "status";
|
|
4611
|
+
date: "date";
|
|
4612
|
+
enum: "enum";
|
|
4613
|
+
"enum-multi": "enum-multi";
|
|
4614
|
+
user: "user";
|
|
4615
|
+
}>;
|
|
4616
|
+
filterable: z.ZodBoolean;
|
|
4617
|
+
groupable: z.ZodBoolean;
|
|
4618
|
+
sortable: z.ZodBoolean;
|
|
4619
|
+
displayable: z.ZodBoolean;
|
|
4620
|
+
options: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
4621
|
+
value: z.ZodString;
|
|
4622
|
+
label: z.ZodString;
|
|
4623
|
+
}, z.core.$strip>>>;
|
|
4624
|
+
}, z.core.$strip>;
|
|
4625
|
+
declare const boardSummarySchema: z.ZodObject<{
|
|
4626
|
+
id: z.ZodString;
|
|
4627
|
+
title: z.ZodString;
|
|
4628
|
+
extensionId: z.ZodString;
|
|
4629
|
+
fields: z.ZodArray<z.ZodObject<{
|
|
4630
|
+
id: z.ZodString;
|
|
4631
|
+
label: z.ZodString;
|
|
4632
|
+
kind: z.ZodEnum<{
|
|
4633
|
+
string: "string";
|
|
4634
|
+
number: "number";
|
|
4635
|
+
status: "status";
|
|
4636
|
+
date: "date";
|
|
4637
|
+
enum: "enum";
|
|
4638
|
+
"enum-multi": "enum-multi";
|
|
4639
|
+
user: "user";
|
|
4640
|
+
}>;
|
|
4641
|
+
filterable: z.ZodBoolean;
|
|
4642
|
+
groupable: z.ZodBoolean;
|
|
4643
|
+
sortable: z.ZodBoolean;
|
|
4644
|
+
displayable: z.ZodBoolean;
|
|
4645
|
+
options: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
4646
|
+
value: z.ZodString;
|
|
4647
|
+
label: z.ZodString;
|
|
4648
|
+
}, z.core.$strip>>>;
|
|
4649
|
+
}, z.core.$strip>>;
|
|
4650
|
+
}, z.core.$strip>;
|
|
4651
|
+
declare const boardViewSchema: z.ZodObject<{
|
|
4652
|
+
id: z.ZodString;
|
|
4653
|
+
boardId: z.ZodString;
|
|
4654
|
+
title: z.ZodString;
|
|
4655
|
+
settings: z.ZodObject<{
|
|
4656
|
+
viewMode: z.ZodEnum<{
|
|
4657
|
+
board: "board";
|
|
4658
|
+
list: "list";
|
|
4659
|
+
}>;
|
|
4660
|
+
columnGrouping: z.ZodString;
|
|
4661
|
+
rowGrouping: z.ZodString;
|
|
4662
|
+
ordering: z.ZodObject<{
|
|
4663
|
+
attributeId: z.ZodString;
|
|
4664
|
+
direction: z.ZodEnum<{
|
|
4665
|
+
asc: "asc";
|
|
4666
|
+
desc: "desc";
|
|
4667
|
+
}>;
|
|
4668
|
+
}, z.core.$strip>;
|
|
4669
|
+
displayProperties: z.ZodArray<z.ZodString>;
|
|
4670
|
+
}, z.core.$strip>;
|
|
4671
|
+
filters: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>;
|
|
4672
|
+
builtIn: z.ZodBoolean;
|
|
4673
|
+
}, z.core.$strip>;
|
|
4674
|
+
declare const boardViewsSchema: z.ZodObject<{
|
|
4675
|
+
views: z.ZodArray<z.ZodObject<{
|
|
4676
|
+
id: z.ZodString;
|
|
4677
|
+
boardId: z.ZodString;
|
|
4678
|
+
title: z.ZodString;
|
|
4679
|
+
settings: z.ZodObject<{
|
|
4680
|
+
viewMode: z.ZodEnum<{
|
|
4681
|
+
board: "board";
|
|
4682
|
+
list: "list";
|
|
4683
|
+
}>;
|
|
4684
|
+
columnGrouping: z.ZodString;
|
|
4685
|
+
rowGrouping: z.ZodString;
|
|
4686
|
+
ordering: z.ZodObject<{
|
|
4687
|
+
attributeId: z.ZodString;
|
|
4688
|
+
direction: z.ZodEnum<{
|
|
4689
|
+
asc: "asc";
|
|
4690
|
+
desc: "desc";
|
|
4691
|
+
}>;
|
|
4692
|
+
}, z.core.$strip>;
|
|
4693
|
+
displayProperties: z.ZodArray<z.ZodString>;
|
|
4694
|
+
}, z.core.$strip>;
|
|
4695
|
+
filters: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>;
|
|
4696
|
+
builtIn: z.ZodBoolean;
|
|
4697
|
+
}, z.core.$strip>>;
|
|
4698
|
+
defaultViewId: z.ZodString;
|
|
4699
|
+
}, z.core.$strip>;
|
|
4700
|
+
declare const boardViewUpdateSchema: z.ZodObject<{
|
|
4701
|
+
title: z.ZodOptional<z.ZodString>;
|
|
4702
|
+
settings: z.ZodOptional<z.ZodObject<{
|
|
4703
|
+
viewMode: z.ZodOptional<z.ZodEnum<{
|
|
4704
|
+
board: "board";
|
|
4705
|
+
list: "list";
|
|
4706
|
+
}>>;
|
|
4707
|
+
columnGrouping: z.ZodOptional<z.ZodString>;
|
|
4708
|
+
rowGrouping: z.ZodOptional<z.ZodString>;
|
|
4709
|
+
ordering: z.ZodOptional<z.ZodObject<{
|
|
4710
|
+
attributeId: z.ZodString;
|
|
4711
|
+
direction: z.ZodEnum<{
|
|
4712
|
+
asc: "asc";
|
|
4713
|
+
desc: "desc";
|
|
4714
|
+
}>;
|
|
4715
|
+
}, z.core.$strip>>;
|
|
4716
|
+
displayProperties: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
4717
|
+
}, z.core.$strip>>;
|
|
4718
|
+
filters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>>;
|
|
4719
|
+
}, z.core.$strict>;
|
|
4720
|
+
declare const boardViewCreateSchema: z.ZodObject<{
|
|
4721
|
+
settings: z.ZodOptional<z.ZodObject<{
|
|
4722
|
+
viewMode: z.ZodOptional<z.ZodEnum<{
|
|
4723
|
+
board: "board";
|
|
4724
|
+
list: "list";
|
|
4725
|
+
}>>;
|
|
4726
|
+
columnGrouping: z.ZodOptional<z.ZodString>;
|
|
4727
|
+
rowGrouping: z.ZodOptional<z.ZodString>;
|
|
4728
|
+
ordering: z.ZodOptional<z.ZodObject<{
|
|
4729
|
+
attributeId: z.ZodString;
|
|
4730
|
+
direction: z.ZodEnum<{
|
|
4731
|
+
asc: "asc";
|
|
4732
|
+
desc: "desc";
|
|
4733
|
+
}>;
|
|
4734
|
+
}, z.core.$strip>>;
|
|
4735
|
+
displayProperties: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
4736
|
+
}, z.core.$strip>>;
|
|
4737
|
+
filters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>>;
|
|
4738
|
+
title: z.ZodString;
|
|
4739
|
+
copyFrom: z.ZodOptional<z.ZodString>;
|
|
4740
|
+
}, z.core.$strict>;
|
|
4741
|
+
type BoardSummary = z.infer<typeof boardSummarySchema>;
|
|
4742
|
+
type BoardField = z.infer<typeof boardFieldSchema>;
|
|
4743
|
+
type BoardView = z.infer<typeof boardViewSchema>;
|
|
4744
|
+
type BoardViews = z.infer<typeof boardViewsSchema>;
|
|
4745
|
+
type BoardViewCreate = z.infer<typeof boardViewCreateSchema>;
|
|
4746
|
+
type BoardViewUpdate = z.infer<typeof boardViewUpdateSchema>;
|
|
4747
|
+
//#endregion
|
|
4498
4748
|
//#region ../pstdio-api-contracts/src/extensions/resource-ref.d.ts
|
|
4499
4749
|
declare const extensionResourceRefSchema: z.ZodObject<{
|
|
4500
4750
|
shorthand: z.ZodOptional<z.ZodString>;
|
|
@@ -4779,6 +5029,30 @@ declare const workbenchExtensionViewBodySchema: z.ZodDiscriminatedUnion<[z.ZodOb
|
|
|
4779
5029
|
id: z.ZodString;
|
|
4780
5030
|
}, z.core.$strip>;
|
|
4781
5031
|
}, z.core.$strip>>>;
|
|
5032
|
+
toolbarActions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
5033
|
+
id: z.ZodString;
|
|
5034
|
+
label: z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
5035
|
+
$l10n: z.ZodString;
|
|
5036
|
+
default: z.ZodOptional<z.ZodString>;
|
|
5037
|
+
}, z.core.$strip>]>;
|
|
5038
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
5039
|
+
presentation: z.ZodOptional<z.ZodEnum<{
|
|
5040
|
+
secondary: "secondary";
|
|
5041
|
+
primary: "primary";
|
|
5042
|
+
}>>;
|
|
5043
|
+
params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
5044
|
+
input: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
5045
|
+
type: z.ZodString;
|
|
5046
|
+
}, z.core.$catchall<z.ZodUnknown>>>>;
|
|
5047
|
+
submitLabel: z.ZodOptional<z.ZodString>;
|
|
5048
|
+
when: z.ZodOptional<z.ZodString>;
|
|
5049
|
+
disabled: z.ZodOptional<z.ZodBoolean>;
|
|
5050
|
+
command: z.ZodObject<{
|
|
5051
|
+
extensionId: z.ZodString;
|
|
5052
|
+
kind: z.ZodLiteral<"command">;
|
|
5053
|
+
id: z.ZodString;
|
|
5054
|
+
}, z.core.$strip>;
|
|
5055
|
+
}, z.core.$strip>>>;
|
|
4782
5056
|
}, z.core.$strip>, z.ZodObject<{
|
|
4783
5057
|
queryHandlerId: z.ZodString;
|
|
4784
5058
|
refreshEventIds: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
@@ -4877,6 +5151,30 @@ declare const workbenchExtensionViewBodySchema: z.ZodDiscriminatedUnion<[z.ZodOb
|
|
|
4877
5151
|
id: z.ZodString;
|
|
4878
5152
|
}, z.core.$strip>;
|
|
4879
5153
|
}, z.core.$strip>>>;
|
|
5154
|
+
toolbarActions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
5155
|
+
id: z.ZodString;
|
|
5156
|
+
label: z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
5157
|
+
$l10n: z.ZodString;
|
|
5158
|
+
default: z.ZodOptional<z.ZodString>;
|
|
5159
|
+
}, z.core.$strip>]>;
|
|
5160
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
5161
|
+
presentation: z.ZodOptional<z.ZodEnum<{
|
|
5162
|
+
secondary: "secondary";
|
|
5163
|
+
primary: "primary";
|
|
5164
|
+
}>>;
|
|
5165
|
+
params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
5166
|
+
input: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
5167
|
+
type: z.ZodString;
|
|
5168
|
+
}, z.core.$catchall<z.ZodUnknown>>>>;
|
|
5169
|
+
submitLabel: z.ZodOptional<z.ZodString>;
|
|
5170
|
+
when: z.ZodOptional<z.ZodString>;
|
|
5171
|
+
disabled: z.ZodOptional<z.ZodBoolean>;
|
|
5172
|
+
command: z.ZodObject<{
|
|
5173
|
+
extensionId: z.ZodString;
|
|
5174
|
+
kind: z.ZodLiteral<"command">;
|
|
5175
|
+
id: z.ZodString;
|
|
5176
|
+
}, z.core.$strip>;
|
|
5177
|
+
}, z.core.$strip>>>;
|
|
4880
5178
|
}, z.core.$strip>], "kind">;
|
|
4881
5179
|
declare const workbenchExtensionViewRecordSchema: z.ZodObject<{
|
|
4882
5180
|
id: z.ZodString;
|
|
@@ -5134,6 +5432,30 @@ declare const workbenchExtensionViewRecordSchema: z.ZodObject<{
|
|
|
5134
5432
|
id: z.ZodString;
|
|
5135
5433
|
}, z.core.$strip>;
|
|
5136
5434
|
}, z.core.$strip>>>;
|
|
5435
|
+
toolbarActions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
5436
|
+
id: z.ZodString;
|
|
5437
|
+
label: z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
5438
|
+
$l10n: z.ZodString;
|
|
5439
|
+
default: z.ZodOptional<z.ZodString>;
|
|
5440
|
+
}, z.core.$strip>]>;
|
|
5441
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
5442
|
+
presentation: z.ZodOptional<z.ZodEnum<{
|
|
5443
|
+
secondary: "secondary";
|
|
5444
|
+
primary: "primary";
|
|
5445
|
+
}>>;
|
|
5446
|
+
params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
5447
|
+
input: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
5448
|
+
type: z.ZodString;
|
|
5449
|
+
}, z.core.$catchall<z.ZodUnknown>>>>;
|
|
5450
|
+
submitLabel: z.ZodOptional<z.ZodString>;
|
|
5451
|
+
when: z.ZodOptional<z.ZodString>;
|
|
5452
|
+
disabled: z.ZodOptional<z.ZodBoolean>;
|
|
5453
|
+
command: z.ZodObject<{
|
|
5454
|
+
extensionId: z.ZodString;
|
|
5455
|
+
kind: z.ZodLiteral<"command">;
|
|
5456
|
+
id: z.ZodString;
|
|
5457
|
+
}, z.core.$strip>;
|
|
5458
|
+
}, z.core.$strip>>>;
|
|
5137
5459
|
}, z.core.$strip>, z.ZodObject<{
|
|
5138
5460
|
queryHandlerId: z.ZodString;
|
|
5139
5461
|
refreshEventIds: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
@@ -5232,6 +5554,30 @@ declare const workbenchExtensionViewRecordSchema: z.ZodObject<{
|
|
|
5232
5554
|
id: z.ZodString;
|
|
5233
5555
|
}, z.core.$strip>;
|
|
5234
5556
|
}, z.core.$strip>>>;
|
|
5557
|
+
toolbarActions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
5558
|
+
id: z.ZodString;
|
|
5559
|
+
label: z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
5560
|
+
$l10n: z.ZodString;
|
|
5561
|
+
default: z.ZodOptional<z.ZodString>;
|
|
5562
|
+
}, z.core.$strip>]>;
|
|
5563
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
5564
|
+
presentation: z.ZodOptional<z.ZodEnum<{
|
|
5565
|
+
secondary: "secondary";
|
|
5566
|
+
primary: "primary";
|
|
5567
|
+
}>>;
|
|
5568
|
+
params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
5569
|
+
input: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
5570
|
+
type: z.ZodString;
|
|
5571
|
+
}, z.core.$catchall<z.ZodUnknown>>>>;
|
|
5572
|
+
submitLabel: z.ZodOptional<z.ZodString>;
|
|
5573
|
+
when: z.ZodOptional<z.ZodString>;
|
|
5574
|
+
disabled: z.ZodOptional<z.ZodBoolean>;
|
|
5575
|
+
command: z.ZodObject<{
|
|
5576
|
+
extensionId: z.ZodString;
|
|
5577
|
+
kind: z.ZodLiteral<"command">;
|
|
5578
|
+
id: z.ZodString;
|
|
5579
|
+
}, z.core.$strip>;
|
|
5580
|
+
}, z.core.$strip>>>;
|
|
5235
5581
|
}, z.core.$strip>], "kind">;
|
|
5236
5582
|
}, z.core.$strip>;
|
|
5237
5583
|
declare const workbenchExtensionMetadataSchema: z.ZodObject<{
|
|
@@ -5828,6 +6174,30 @@ declare const workbenchExtensionMetadataSchema: z.ZodObject<{
|
|
|
5828
6174
|
id: z.ZodString;
|
|
5829
6175
|
}, z.core.$strip>;
|
|
5830
6176
|
}, z.core.$strip>>>;
|
|
6177
|
+
toolbarActions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
6178
|
+
id: z.ZodString;
|
|
6179
|
+
label: z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
6180
|
+
$l10n: z.ZodString;
|
|
6181
|
+
default: z.ZodOptional<z.ZodString>;
|
|
6182
|
+
}, z.core.$strip>]>;
|
|
6183
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
6184
|
+
presentation: z.ZodOptional<z.ZodEnum<{
|
|
6185
|
+
secondary: "secondary";
|
|
6186
|
+
primary: "primary";
|
|
6187
|
+
}>>;
|
|
6188
|
+
params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
6189
|
+
input: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
6190
|
+
type: z.ZodString;
|
|
6191
|
+
}, z.core.$catchall<z.ZodUnknown>>>>;
|
|
6192
|
+
submitLabel: z.ZodOptional<z.ZodString>;
|
|
6193
|
+
when: z.ZodOptional<z.ZodString>;
|
|
6194
|
+
disabled: z.ZodOptional<z.ZodBoolean>;
|
|
6195
|
+
command: z.ZodObject<{
|
|
6196
|
+
extensionId: z.ZodString;
|
|
6197
|
+
kind: z.ZodLiteral<"command">;
|
|
6198
|
+
id: z.ZodString;
|
|
6199
|
+
}, z.core.$strip>;
|
|
6200
|
+
}, z.core.$strip>>>;
|
|
5831
6201
|
}, z.core.$strip>, z.ZodObject<{
|
|
5832
6202
|
queryHandlerId: z.ZodString;
|
|
5833
6203
|
refreshEventIds: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
@@ -5926,6 +6296,30 @@ declare const workbenchExtensionMetadataSchema: z.ZodObject<{
|
|
|
5926
6296
|
id: z.ZodString;
|
|
5927
6297
|
}, z.core.$strip>;
|
|
5928
6298
|
}, z.core.$strip>>>;
|
|
6299
|
+
toolbarActions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
6300
|
+
id: z.ZodString;
|
|
6301
|
+
label: z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
6302
|
+
$l10n: z.ZodString;
|
|
6303
|
+
default: z.ZodOptional<z.ZodString>;
|
|
6304
|
+
}, z.core.$strip>]>;
|
|
6305
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
6306
|
+
presentation: z.ZodOptional<z.ZodEnum<{
|
|
6307
|
+
secondary: "secondary";
|
|
6308
|
+
primary: "primary";
|
|
6309
|
+
}>>;
|
|
6310
|
+
params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
6311
|
+
input: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
6312
|
+
type: z.ZodString;
|
|
6313
|
+
}, z.core.$catchall<z.ZodUnknown>>>>;
|
|
6314
|
+
submitLabel: z.ZodOptional<z.ZodString>;
|
|
6315
|
+
when: z.ZodOptional<z.ZodString>;
|
|
6316
|
+
disabled: z.ZodOptional<z.ZodBoolean>;
|
|
6317
|
+
command: z.ZodObject<{
|
|
6318
|
+
extensionId: z.ZodString;
|
|
6319
|
+
kind: z.ZodLiteral<"command">;
|
|
6320
|
+
id: z.ZodString;
|
|
6321
|
+
}, z.core.$strip>;
|
|
6322
|
+
}, z.core.$strip>>>;
|
|
5929
6323
|
}, z.core.$strip>], "kind">;
|
|
5930
6324
|
}, z.core.$strip>>;
|
|
5931
6325
|
viewMenus: z.ZodArray<z.ZodObject<{
|
|
@@ -6106,6 +6500,7 @@ declare const workbenchExtensionMetadataSchema: z.ZodObject<{
|
|
|
6106
6500
|
default: z.ZodOptional<z.ZodString>;
|
|
6107
6501
|
}, z.core.$strip>]>>;
|
|
6108
6502
|
icon: z.ZodOptional<z.ZodString>;
|
|
6503
|
+
resolveCommand: z.ZodOptional<z.ZodString>;
|
|
6109
6504
|
menuSlots: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
6110
6505
|
id: z.ZodString;
|
|
6111
6506
|
placement: z.ZodEnum<{
|
|
@@ -7890,8 +8285,8 @@ declare const listWorkspaceActivityResponseSchema: z.ZodObject<{
|
|
|
7890
8285
|
source_extension_id: z.ZodNullable<z.ZodString>;
|
|
7891
8286
|
event_type: z.ZodString;
|
|
7892
8287
|
actor_type: z.ZodEnum<{
|
|
7893
|
-
agent: "agent";
|
|
7894
8288
|
user: "user";
|
|
8289
|
+
agent: "agent";
|
|
7895
8290
|
system: "system";
|
|
7896
8291
|
}>;
|
|
7897
8292
|
actor_id: z.ZodNullable<z.ZodString>;
|
|
@@ -7937,5 +8332,5 @@ declare const workspaceProviderDescriptorSchema: z.ZodObject<{
|
|
|
7937
8332
|
}, z.core.$strip>;
|
|
7938
8333
|
type WorkspaceProviderDescriptor = z.infer<typeof workspaceProviderDescriptorSchema>;
|
|
7939
8334
|
//#endregion
|
|
7940
|
-
export { WorkbenchExtensionMetadata as $, FollowUpInput as $a, ExtensionSettingScope as $c, HarnessParamDescriptor as $i, SelectParam as $l, ConflictPayload as $n, PageContribution as $o, ExtensionPackageFilesApi as $r, DataTableRendererQueryResult as $s, defineExtensionView as $t, ViewHierarchyParent as $u, EnableInstalledExtensionRequest as A, SessionMessage as Aa, RangeValue as Ac, l10n as Ad, HookDefinition as Ai, KanbanRendererResourceRef as Al, defineHook as An, CommandLifecyclePhase as Ao, ResourceHierarchyProvider as Ar, TreeViewBody as As, TerminalHostEvent as At, WebviewPreferencesSetParams as Au, ConfigureExtensionConnectionInput as B, ExtensionConnectionMethod as Ba, TextControl as Bc, WorkspaceProviderCreateInput as Bi, HarnessParam as Bl, historyValueKey as Bn, CommandRequestedEvent as Bo, CommandRunHandler as Br, TreeRendererChildrenParams as Bs, PageUrlDefinition as Bt, FileRendererLoadResult as Bu, ExtensionSettingsPanelRecord as C, QuestionResponse as Ca, ControlValueMap as Cc, ViewRef as Cd, BehaviourContributions as Ci, KanbanRendererColumnAction as Cl, defineTemplateType as Cn, CommandCompletedEvent as Co, workbenchPanels as Cr, PlacementMountStrategy as Cs, ArtifactMountKey as Ct, WebviewKeyboardEventParams as Cu, ExtensionCommandPaletteResourceRecord as D, LoadingPart as Da, ParamEditorReadOnlyContent as Dc, Localizable as Dd, ExtensionDefinition as Di, KanbanRendererFilterState as Dl, defineWorkspaceType as Dn, CommandHelpersApi as Do, DockedWorkbenchRegion as Dr, PlacementTabMenuRow as Ds, TerminalSessionBridge as Dt, WebviewNotificationResolveParams as Du, ExtensionKeybindingRecord as E, FilePart as Ea, NumberControl as Ec, TerminalSessionRequest$1 as Ed, ExtensionConnectionContribution as Ei, KanbanRendererEnumOption as El, defineViewMenu as En, CommandFailedEvent as Eo, workbenchSlots as Er, PlacementTabMenuGroup as Es, TerminalSessionAdapter as Et, WebviewNotificationDismissParams as Eu, ProjectExtensionInstance as F, TextPart as Fa, SegmentedControl as Fc, AgentModel as Fd, ScheduleContribution as Fi, KanbanRendererSettings as Fl, HistoryConflict as Fn, CommandRef as Fo, ArtifactFile as Fr, TreeAction as Fs, commandEvent as Ft, UiSlotKind as Fu, LocalizableString as G, ExtensionLoggerApi as Ga, CliContribution as Gc, WorkspaceProviderState as Gi, MultiSelectParam as Gl, mergeOrderedHistory as Gn, WorkbenchAttachmentInvocationContext as Go, ExtensionBlobRef as Gr, TreeRendererState as Gs, serializePageUrl as Gt, ExtensionResourcesApi as Gu, ListExtensionConnectionsResponse as H, ExtensionConnectionResponse as Ha, VectorValue as Hc, WorkspaceProviderRef as Hi, ListParam as Hl, reconcileMessageHistory as Hn, CommandStartedEvent as Ho, ExtensionActivityApi as Hr, TreeRendererContribution as Hs, isWorkbenchProjectUrl as Ht, FileRendererSaveParams as Hu, UpgradeProjectExtensionResponse as I, TokenUsagePart as Ia, SegmentedOption as Ic, AgentSkillsLayout as Id, ScheduleExpression as Ii, KanbanRendererSortDirection as Il, HistoryProjection as In, CommandReject as Io, ArtifactMount as Ir, TreeNode as Is, QualifiedRef as It, ResourceBinding as Iu, ExtensionMenuContribution as J, SkillFile as Ja, CommandPaletteResourceItem as Jc, StatusBarItemContribution as Ji, ParamObjectSchema as Jl, eventRef as Jn, NavigationTargetCompound as Jo, ExtensionEventsApi as Jr, DataTableRendererColumn as Js, ExtensionViewModule as Jt, RendererInvocationContext as Ju, ExtensionCommandPaletteContribution as K, ExtensionAutomationApi as Ka, CommandPaletteContribution as Kc, WorkspaceTypeProvider as Ki, NumberParam as Kl, defineSlot as Kn, NavigationTarget as Ko, ExtensionBlobsApi as Kr, TreeSectionEmptyState as Ks, serializeWorkbenchPageUrl as Kt, PackageAssetDescriptor as Ku, CommandExecuteRequest as L, ToolPart as La, SelectionControl as Lc, harnessLocalId as Ld, UiContributions as Li, KanbanRendererViewMode as Ll, HistoryRecoveryInput as Ln, CommandRejectedEvent as Lo, CommandContext as Lr, TreeNodeRowVariant as Ls, qualifyRef as Lt, ResourceConstraint as Lu, InstallMarketplaceExtensionResponse as M, SessionMessageRole as Ma, ResourceControl as Mc, supportsExtensionApiVersion as Md, MiddlewareDefinition as Mi, KanbanRendererRowAction as Ml, CommandResponse as Mn, CommandNotice as Mo, ResourceMenuSlotDefinition as Mr, ViewContribution as Ms, TerminalSessionRequest as Mt, SlotInvocationContext as Mu, ListProjectExtensionsResponse as N, StepFinishPart as Na, ResourceOption as Nc, AgentAvailabilityType as Nd, PackageManifest as Ni, KanbanRendererRowActivationHandler as Nl, unwrapCommandOutcome as Nn, CommandOutcome as No, dockedWorkbenchRegions as Nr, ViewMenuContribution as Ns, TerminalSessionResult as Nt, SlotOptions as Nu, WorkbenchExtensionCommandPaletteResourceRecord as O, PatchPart as Oa, ParamEditorReadOnlyImage as Oc, LocalizedString as Od, ExtensionLoadScope as Oi, KanbanRendererQueryParams as Ol, resourceMenuSlotRef as On, CommandInvocation as Oo, ExtensionPanelRegion as Or, PlacementTabPresentation as Os, TerminalSessionExit as Ot, WebviewNotificationShowParams as Ou, MarketplaceExtension as P, StepStartPart as Pa, ResourceRefValue as Pc, AgentInfo as Pd, ProviderContributions as Pi, KanbanRendererSavedView as Pl, SDK_VERSION as Pn, CommandPatchParams as Po, extensionPanelRegions as Pr, WebviewViewBody as Ps, resourceKey as Pt, SlotRef as Pu, WorkbenchExtensionHarnessRecord as Q, CreateSessionInput as Qa, ExtensionSettingProperty as Qc, HarnessDetectionResult as Qi, ResourceParam as Ql, CommitPayload as Qn, NavigationTargetPanel as Qo, ExtensionNotifyApi as Qr, DataTableRendererQueryParams as Qs, WebviewFilesClient as Qt, ResourceRole as Qu, CommandExecuteResponse as R, ToolPartActionType as Ra, SelectionGroup as Rc, ListActivityResponse as Rd, WorkspaceCapabilities as Ri, BooleanParam as Rl, HistoryRecoveryResult as Rn, CommandReplaceInvocation as Ro, CommandMiddlewareContext as Rr, TreeNodeTarget as Rs, params as Rt, FileRendererContribution as Ru, ExtensionSettingValueRecord as S, JsonPatch as Sa, ControlValue as Sc, ThemeRef as Sd, AssetContributions as Si, KanbanRendererBoardColumnConfig as Sl, defineTemplate as Sn, UpdateNotificationInput as So, workbenchPanelDefinitions as Sr, PlacementItem as Ss, WebviewExtensionEvent as St, WebviewHostCapabilityResults as Su, UpdateExtensionSettingRequest as T, ErrorPart as Ta, MarkdownControl as Tc, TerminalSessionHandle as Td, EXTENSION_API_VERSION as Ti, KanbanRendererCreateRowContribution as Tl, defineView as Tn, CommandDiagnostic as To, workbenchResourceKinds as Tr, PlacementPresentation as Ts, artifactsRead as Tt, WebviewNotificationActionParams as Tu, ExtensionDiagnostic as U, ExtensionConnectionStreamEvent as Ua, ActivityItemContribution as Uc, WorkspaceProviderResolveInput as Ui, LongTextParam as Ul, splitHistoryTurns as Un, CommandTarget as Uo, ExtensionArtifactApi as Ur, TreeRendererQueryParams as Us, parsePageUrl as Ut, FileRendererSectionAnchor as Uu, ExtensionConnectionRecord as V, ExtensionConnectionRequest as Va, VectorControl as Vc, WorkspaceProviderMutationInput as Vi, JsonParam as Vl, mergeHistoryMetadata as Vn, CommandSource as Vo, EventContext as Vr, TreeRendererCommandResult as Vs, ParsedWorkbenchPageUrl as Vt, FileRendererResourceRef as Vu, ExtensionRecord as W, ExtensionConnectionsApi as Wa, ArtifactMountContribution as Wc, WorkspaceProviderResult as Wi, MarkdownParam as Wl, submittedPrompt as Wn, SerializedError as Wo, ExtensionBlobInput as Wr, TreeRendererResourceRef as Ws, parseWorkbenchPageUrl as Wt, FileRendererSectionTarget as Wu, ListExtensionAppearanceResponse as X, UpdateSkillInput as Xa, CommandPaletteResourceQueryResult as Xc, WorkflowStatus as Xi, ParamValue as Xl, isNavigationTarget as Xn, NavigationTargetItem as Xo, ExtensionHarnessInput as Xr, DataTableRendererColumnStat as Xs, ExtensionViewRenderContext as Xt, ResourceRef as Xu, WorkbenchExtensionAutomationRecord as Y, SkillWithContent as Ya, CommandPaletteResourceQueryParams as Yc, StatusContribution as Yi, ParamType as Yl, packageAsset as Yn, NavigationTargetHref as Yo, ExtensionFilesApi as Yr, DataTableRendererColumnRenderer as Ys, ExtensionViewRender as Yt, ResourceAnchor as Yu, ListExtensionCommandsResponse as Z, ApprovalInput as Za, CommandPaletteResourceTarget as Zc, HarnessContext as Zi, ParamsOf as Zl, qualifyNavigationTarget as Zn, NavigationTargetPage as Zo, ExtensionNetApi as Zr, DataTableRendererContribution as Zs, PropsStore as Zt, ResourceRemovedEvent as Zu, CreateProjectInput as _, HarnessRecoveryInput as _a, BaseControl as _c, ResourceKindRef as _d, CreateExtensionWorkspaceInput as _i, WhenExpression as _l, defineSettingsPanel as _n, NotificationActorType as _o, localContributionIdPattern as _r, NavigationItemContribution as _s, WebviewCommandsClient as _t, WebviewFilesListParams as _u, RemoveWorktreeResponse as a, AgentCapability as aa, DataTableRendererThemeColor as ac, JsonPrimitive as ad, ExtensionSkillsApi as ai, KeybindingContribution as al, defineConnection as an, Session as ao, WorktreeRemovedPayload as ar, PageSlot as as, AutomationRunStatus as at, WEBVIEW_HOST_CAPABILITIES as au, FileRecord as b, HarnessSession as ba, ControlGroup as bc, StatusBarSlotRef as bd, ExtensionWorkspaceProvider as bi, KanbanRendererAttributeDisplay as bl, defineStatusBarItem as bn, NotificationPriority as bo, workbenchPageDefinitions as br, NavigationTreeSlot as bs, EXTENSION_EVENTS_SCOPE as bt, WebviewHostCapabilityParams as bu, WorkspaceFileContent as c, HarnessApprovalChannel as ca, ControlsQueryResult as cc, Struct as cd, ExtensionTerminalApi as ci, ModeRegionSettings as cl, defineKeybinding as cn, SessionConversationResponse as co, projectSlots as cr, PageSlotRegion as cs, IssueAutomationTokenInput as ct, WebviewArtifactFile as cu, WorkspaceListItem as d, HarnessExit as da, ControlsResourceRef as dc, ContributionInput as dd, ProcessRunResult as di, SkillContribution as dl, defineNavigationTree as dn, SessionStatus as do, viewDataEvents as dr, PlacementIdentity as ds, ListAutomationTokensResponse as dt, WebviewCommandsExecuteParams as du, HarnessParamsSchema as ea, DataTableRendererResourceRef as ec, RendererContributionBase as ed, ExtensionProcessApi as ei, ExtensionSettingValueForType as el, GuestHost as en, FollowUpResponse as eo, MergePayload as er, PageLocation as es, WorkbenchExtensionViewBody as et, TemplateParam as eu, WorkspaceProviderDescriptor as f, HarnessExitStatus as fa, ControlsUpdateValueInput as fc, ContributionKind as fd, RendererCallback as fi, TemplateContribution as fl, definePage as fn, CreateNotificationInput as fo, workspaceEvents as fr, PlacementOwner as fs, projectPrefix as ft, WebviewDeclarableCapability as fu, sessionAttachmentMimeTypesByExtension as g, HarnessReattachInput as ga, AnchorGridValue as gc, PlacementRef as gd, WorkspaceSyncFile as gi, WebviewContribution as gl, defineSchedule as gn, NotificationAction as go, localContributionIdGrammar as gr, KanbanViewBody as gs, WebviewClientOptions as gt, WebviewFilesDeleteParams as gu, UpdateSettingsInput as h, HarnessParams as ha, AnchorGridControl as hc, PageRef as hd, WorkspaceFilesMount as hi, ThemeMode as hl, defineResourceKind as hn, Notification as ho, isValidLocalContributionId as hr, FileViewBody as hs, WebviewClient as ht, WebviewFileScope as hu, ListWorkspaceFilesInput as i, RetryableHarnessReattachError as ia, DataTableRendererSelectionAction as ic, JsonObject as id, ExtensionSettingsApi as ii, KeybindingChord as il, defineCommandPaletteResource as in, ResolveSessionIdResponse as io, WorkspaceType as ir, PageOpenIntent as is, AutomationRunEvent as it, WEBVIEW_DECLARABLE_CAPABILITIES as iu, EnableInstalledExtensionResponse as j, SessionMessagePart as ja, ReadOnlyControl as jc, parseExtensionApiVersions as jd, LocalExtensionSource as ji, KanbanRendererRow as jl, defineMiddleware as jn, CommandMiddlewareResult as jo, ResourceKindDefinition as jr, ViewBody as js, TerminalSessionOperation as jt, WebviewScopedDeclarableCapability as ju, AddLocalExtensionFolderResponse as k, ReasoningPart as ka, RangeControl as kc, isLocalizedString as kd, ExtensionSourceKind as ki, KanbanRendererQueryResult as kl, defineCommand as kn, CommandLifecycleEventPayload as ko, RegionSize as kr, PlacementTabSnapshot as ks, createTerminalSessionBridge as kt, WebviewPreferencesGetParams as ku, WorkspaceFileEntry as l, HarnessAttachment as la, ControlsRendererContribution as lc, ConnectionRef as ld, MigrationContext as li, SettingsPanelContribution as ll, defineMode as ln, SessionConversationSources as lo, sessionEvents as lr, PageSlotRole as ls, IssueAutomationTokenResponse as lt, WebviewArtifactsReadParams as lu, Settings as m, HarnessParamValue as ma, ActionsControl as mc, ModeRef as md, StorageScope as mi, ThemeContribution as ml, defineResourceHierarchyProvider as mn, ListNotificationsResponse as mo, worktreeEvents as mr, DataTableViewBody as ms, WebviewArtifactsClient as mt, WebviewExtensionSettingSetParams as mu, ListWorkspaceActivityInput as n, HarnessSkillsLayout as na, DataTableRendererRowAction as nc, EventDeliveryResult as nd, ExtensionSessionResource as ni, ExtensionSettingsContribution as nl, defineActivityItem as nn, ListSessionActivityResponse as no, SessionLifecyclePayload as nr, PageMainPanels as ns, AutomationRun as nt, WorkspaceParam as nu, RenameWorkspaceInput as o, ApprovalRequest as oa, ControlsApplyInput as oc, JsonValue as od, ExtensionStorageApi as oi, MenuContribution as ol, defineFileIconTheme as on, SessionAttachment as oo, gitEvents as or, PageSlotCardinality as os, AutomationTokenRecord as ot, WEBVIEW_HOST_CAPABILITY_VERSION as ou, WriteWorkspaceFileInput as p, HarnessMessagesInput as pa, ActionOption as pc, ContributionRef as pd, SetupContext as pi, TemplateTypeContribution as pl, definePlacement as pn, ListNotificationsQuery as po, workspaceSlots as pr, ControlsViewBody as ps, matchesResourceWhen as pt, WebviewExtensionSettingKeyParams as pu, ExtensionCommandRecord as q, Skill as qa, CommandPaletteResourceContribution as qc, StatusActionDefinition as qi, ParamDescriptor as ql, commandRef as qn, NavigationTargetCommand as qo, ExtensionContextBase as qr, TreeViewSection as qs, resolveEventReferenceId as qt, RendererContext as qu, ListWorkspaceActivityResponse as r, HarnessStateApi as ra, DataTableRendererRowActivationHandler as rc, EventRef as rd, ExtensionSessionsApi as ri, FileIconThemeContribution as rl, defineArtifactMount as rn, ResolveSessionIdInput as ro, WorkspaceProvisionPayload as rr, PageMainView as rs, AutomationRunError as rt, ALWAYS_AVAILABLE_WEBVIEW_CAPABILITIES as ru, Workspace as s, ApprovalResponse as sa, ControlsQueryParams as sc, MaybePromise as sd, ExtensionStorageCollectionApi as si, ModeContribution as sl, defineHarness as sn, SessionAttachmentRef as so, projectEvents as sr, PageSlotRef as ss, CreateAutomationRunInput as st, WEBVIEW_SCOPED_DECLARABLE_CAPABILITIES as su, CreateWorkspaceInput as t, HarnessProvider as ta, DataTableRendererRow as tc, RendererEventReference as td, ExtensionProjectContext as ti, ExtensionSettingValueType as tl, defineExtension as tn, ListSessionActivityInput as to, RebasePayload as tr, PageMain as ts, WorkbenchExtensionViewRecord as tt, TextParam as tu, WorkspaceFilesResponse as u, HarnessEventSink as ua, ControlsResetInput as uc, ContributionDefinition as ud, ProcessRunInput as ui, SettingsSectionContribution as ul, defineNavigationItem as un, SessionQueuedMessagesResponse as uo, sessionSlots as ur, PanelRef as us, ListAutomationRunEventsResponse as ut, WebviewCapabilityDeclaration as uu, Project as v, HarnessRecoveryResult as va, BooleanControl as vc, SettingsSectionRef as vd, CreateWorkspaceCommandParams as vi, CollectionBadgeItem as vl, defineSettingsSection as vn, NotificationKind as vo, workbenchModeDefinitions as vr, NavigationOwnerRef as vs, WebviewSettingsClient as vt, WebviewFilesUploadParams as vu, ListExtensionSettingsResponse as w, TimeoutStrategy as wa, DateControl as wc, TerminalEvent as wd, CommandDefinition as wi, KanbanRendererContribution as wl, defineTheme as wn, CommandContinue as wo, workbenchResourceKindDefinitions as wr, PlacementPresence as ws, artifactMountId as wt, WebviewNavigationOpenParams as wu, ExtensionSettingDefinitionRecord as x, HarnessStartInput as xa, ControlParam as xc, StatusRef as xd, ExtensionWorkspacesApi as xi, KanbanRendererAttributeType as xl, defineStatuses as xn, NotificationStatus as xo, workbenchPages as xr, PlacementContribution as xs, WebviewEventsClient as xt, WebviewHostCapabilityResult as xu, UpdateProjectInput as y, HarnessResumeInput as ya, ColorControl as yc, SettingsSlotRef as yd, ExtensionWorkspace as yi, KanbanRendererAttributeDescriptor as yl, defineSkill as yn, NotificationOrigin as yo, workbenchModes as yr, NavigationTreeContribution as ys, createWebviewClient as yt, WebviewHostCapability as yu, DispatchExtensionEventInput as z, ToolPartStatus as za, SelectionOption as zc, ListProjectActivityInput as zd, WorkspaceExecutionTarget as zi, FilesParam as zl, historyMessageKey as zn, CommandReplaceParams as zo, CommandMiddlewareHandler as zr, TreeRendererActionParams as zs, defaultPageResourceCodec as zt, FileRendererLoadParams as zu };
|
|
8335
|
+
export { WorkbenchExtensionMetadata as $, PlacementOwner as $a, WebviewContribution as $c, ListActivityResponse as $d, ProcessRunInput as $i, WebviewDeclarableCapability as $l, commandRef as $n, ControlsUpdateValueInput as $o, CommandRef as $r, HarnessQuestionOption as $s, resolveEventReferenceId as $t, CreateNotificationInput as $u, EnableInstalledExtensionRequest as A, WorkspaceProviderMutationInput as Aa, CommandPaletteResourceContribution as Ac, ContributionKind as Ad, EventContext as Ai, NumberParam as Al, defineTheme as An, TreeRendererQueryParams as Ao, workbenchResourceKindDefinitions as Ar, ResourceBinding as As, artifactMountId as At, ExtensionConnectionStreamEvent as Au, ConfigureExtensionConnectionInput as B, PageContribution as Ba, FileIconThemeContribution as Bc, ThemeRef as Bd, ExtensionNetApi as Bi, SelectParam as Bl, SDK_VERSION as Bn, DataTableRendererQueryResult as Bo, extensionPanelRegions as Br, AgentCapability as Bs, resourceKey as Bt, FollowUpInput as Bu, ExtensionSettingsPanelRecord as C, ProviderContributions as Ca, ToolPart as Cc, JsonPrimitive as Cd, FileRendererSectionTarget as Ci, FilesParam as Cl, defineSettingsPanel as Cn, TreeNode as Co, localContributionIdPattern as Cr, SegmentedOption as Cs, WebviewCommandsClient as Ct, SlotRef as Cu, ExtensionCommandPaletteResourceRecord as D, WorkspaceCapabilities as Da, ArtifactMountContribution as Dc, ConnectionRef as Dd, CommandMiddlewareContext as Di, LongTextParam as Dl, defineStatuses as Dn, TreeRendererChildrenParams as Do, workbenchPages as Dr, TextControl as Ds, WebviewEventsClient as Dt, ExtensionConnectionMethod as Du, ExtensionKeybindingRecord as E, UiContributions as Ea, ActivityItemContribution as Ec, Struct as Ed, CommandContext as Ei, ListParam as El, defineStatusBarItem as En, TreeRendererActionParams as Eo, workbenchPageDefinitions as Er, SelectionOption as Es, EXTENSION_EVENTS_SCOPE as Et, EventRef as Eu, ProjectExtensionInstance as F, WorkspaceTypeProvider as Fa, ExtensionSettingProperty as Fc, ResourceKindRef as Fd, ExtensionBlobsApi as Fi, ParamType as Fl, defineCommand as Fn, DataTableRendererColumn as Fo, RegionSize as Fr, HarnessParamsSchema as Fs, createTerminalSessionBridge as Ft, SkillFile as Fu, LocalizableString as G, PageOpenIntent as Ga, ModeRegionSettings as Gc, l10n as Gd, ExtensionSessionResource as Gi, WEBVIEW_DECLARABLE_CAPABILITIES as Gl, historyMessageKey as Gn, DataTableRendererSelectionAction as Go, CommandHelpersApi as Gr, HarnessEventSink as Gs, defaultPageResourceCodec as Gt, ResolveSessionIdResponse as Gu, ListExtensionConnectionsResponse as H, PageMain as Ha, KeybindingContribution as Hc, Localizable as Hd, ExtensionPackageFilesApi as Hi, TextParam as Hl, HistoryProjection as Hn, DataTableRendererRow as Ho, CommandContinue as Hr, ApprovalResponse as Hs, QualifiedRef as Ht, ListSessionActivityInput as Hu, UpgradeProjectExtensionResponse as I, StatusActionDefinition as Ia, ExtensionSettingScope as Ic, SettingsSectionRef as Id, ExtensionContextBase as Ii, ParamValue as Il, defineHook as In, DataTableRendererColumnRenderer as Io, ResourceHierarchyProvider as Ir, HarnessProvider as Is, TerminalHostEvent as It, SkillWithContent as Iu, ExtensionMenuContribution as J, PageSlotRef as Ja, SkillContribution as Jc, AgentAvailabilityType as Jd, ExtensionSkillsApi as Ji, WEBVIEW_SCOPED_DECLARABLE_CAPABILITIES as Jl, reconcileMessageHistory as Jn, ControlsQueryParams as Jo, CommandLifecyclePhase as Jr, HarnessMessagesInput as Js, isWorkbenchProjectUrl as Jt, SessionAttachmentRef as Ju, ExtensionCommandPaletteContribution as K, PageSlot as Ka, SettingsPanelContribution as Kc, parseExtensionApiDeclaration as Kd, ExtensionSessionsApi as Ki, WEBVIEW_HOST_CAPABILITIES as Kl, historyValueKey as Kn, DataTableRendererThemeColor as Ko, CommandInvocation as Kr, HarnessExit as Ks, PageUrlDefinition as Kt, Session as Ku, CommandExecuteRequest as L, StatusBarItemContribution as La, ExtensionSettingValueForType as Lc, SettingsSlotRef as Ld, ExtensionEventsApi as Li, ParamValueRef as Ll, defineMiddleware as Ln, DataTableRendererColumnStat as Lo, ResourceKindDefinition as Lr, HarnessSkillsLayout as Ls, TerminalSessionOperation as Lt, UpdateSkillInput as Lu, InstallMarketplaceExtensionResponse as M, WorkspaceProviderResolveInput as Ma, CommandPaletteResourceQueryParams as Mc, ModeRef as Md, ExtensionArtifactApi as Mi, ParamObjectSchema as Ml, defineViewMenu as Mn, TreeRendererState as Mo, workbenchSlots as Mr, HarnessContext as Ms, TerminalSessionAdapter as Mt, ExtensionLoggerApi as Mu, ListProjectExtensionsResponse as N, WorkspaceProviderResult as Na, CommandPaletteResourceQueryResult as Nc, PageRef as Nd, ExtensionBlobInput as Ni, ParamOption as Nl, defineWorkspaceType as Nn, TreeSectionEmptyState as No, DockedWorkbenchRegion as Nr, HarnessDetectionResult as Ns, TerminalSessionBridge as Nt, ExtensionAutomationApi as Nu, WorkbenchExtensionCommandPaletteResourceRecord as O, WorkspaceExecutionTarget as Oa, CliContribution as Oc, ContributionDefinition as Od, CommandMiddlewareHandler as Oi, MarkdownParam as Ol, defineTemplate as On, TreeRendererCommandResult as Oo, workbenchPanelDefinitions as Or, VectorControl as Os, WebviewExtensionEvent as Ot, ExtensionConnectionRequest as Ou, MarketplaceExtension as P, WorkspaceProviderState as Pa, CommandPaletteResourceTarget as Pc, PlacementRef as Pd, ExtensionBlobRef as Pi, ParamOptionSource as Pl, resourceMenuSlotRef as Pn, TreeViewSection as Po, ExtensionPanelRegion as Pr, HarnessParamDescriptor as Ps, TerminalSessionExit as Pt, Skill as Pu, WorkbenchExtensionHarnessRecord as Q, PlacementIdentity as Qa, ThemeMode as Qc, harnessLocalId as Qd, MigrationContext as Qi, WebviewCommandsExecuteParams as Ql, defineSlot as Qn, ControlsResourceRef as Qo, CommandPatchParams as Qr, HarnessQuestionChannel as Qs, serializeWorkbenchPageUrl as Qt, SessionStatus as Qu, CommandExecuteResponse as R, StatusContribution as Ra, ExtensionSettingValueType as Rc, StatusBarSlotRef as Rd, ExtensionFilesApi as Ri, ParamsOf as Rl, CommandResponse as Rn, DataTableRendererContribution as Ro, ResourceMenuSlotDefinition as Rr, HarnessStateApi as Rs, TerminalSessionRequest as Rt, ApprovalInput as Ru, ExtensionSettingValueRecord as S, PackageManifest as Sa, TokenUsagePart as Sc, JsonObject as Sd, FileRendererSectionAnchor as Si, BooleanParam as Sl, defineSchedule as Sn, TreeAction as So, localContributionIdGrammar as Sr, SegmentedControl as Ss, WebviewClientOptions as St, SlotOptions as Su, UpdateExtensionSettingRequest as T, ScheduleExpression as Ta, ToolPartStatus as Tc, MaybePromise as Td, ArtifactMount as Ti, JsonParam as Tl, defineSkill as Tn, TreeNodeTarget as To, workbenchModes as Tr, SelectionGroup as Ts, createWebviewClient as Tt, EventDeliveryResult as Tu, ExtensionDiagnostic as U, PageMainPanels as Ua, MenuContribution as Uc, LocalizedString as Ud, ExtensionProcessApi as Ui, WorkspaceParam as Ul, HistoryRecoveryInput as Un, DataTableRendererRowAction as Uo, CommandDiagnostic as Ur, HarnessApprovalChannel as Us, qualifyRef as Ut, ListSessionActivityResponse as Uu, ExtensionConnectionRecord as V, PageLocation as Va, KeybindingChord as Vc, ViewRef as Vd, ExtensionNotifyApi as Vi, TemplateParam as Vl, HistoryConflict as Vn, DataTableRendererResourceRef as Vo, CommandCompletedEvent as Vr, ApprovalRequest as Vs, commandEvent as Vt, FollowUpResponse as Vu, ExtensionRecord as W, PageMainView as Wa, ModeContribution as Wc, isLocalizedString as Wd, ExtensionProjectContext as Wi, ALWAYS_AVAILABLE_WEBVIEW_CAPABILITIES as Wl, HistoryRecoveryResult as Wn, DataTableRendererRowActivationHandler as Wo, CommandFailedEvent as Wr, HarnessAttachment as Ws, params as Wt, ResolveSessionIdInput as Wu, ListExtensionAppearanceResponse as X, PageSlotRole as Xa, TemplateTypeContribution as Xc, AgentModel as Xd, ExtensionStorageCollectionApi as Xi, WebviewArtifactsReadParams as Xl, submittedPrompt as Xn, ControlsRendererContribution as Xo, CommandNotice as Xr, HarnessParams as Xs, parseWorkbenchPageUrl as Xt, SessionConversationSources as Xu, WorkbenchExtensionAutomationRecord as Y, PageSlotRegion as Ya, TemplateContribution as Yc, AgentInfo as Yd, ExtensionStorageApi as Yi, WebviewArtifactFile as Yl, splitHistoryTurns as Yn, ControlsQueryResult as Yo, CommandMiddlewareResult as Yr, HarnessParamValue as Ys, parsePageUrl as Yt, SessionConversationResponse as Yu, ListExtensionCommandsResponse as Z, PanelRef as Za, ThemeContribution as Zc, AgentSkillsLayout as Zd, ExtensionTerminalApi as Zi, WebviewCapabilityDeclaration as Zl, mergeOrderedHistory as Zn, ControlsResetInput as Zo, CommandOutcome as Zr, HarnessQuestion as Zs, serializePageUrl as Zt, SessionQueuedMessagesResponse as Zu, CreateProjectInput as _, ExtensionLoadScope as _a, SessionMessagePart as _c, ResourceRole as _d, FileRendererContribution as _i, KanbanRendererSavedView as _l, defineNavigationTree as _n, TreeViewBody as _o, viewDataEvents as _r, RangeValue as _s, ListAutomationTokensResponse as _t, WebviewPreferencesSetParams as _u, RemoveWorktreeResponse as a, WorkspaceSyncFile as aa, HarnessResumeInput as ac, NotificationKind as ad, CommandSource as ai, KanbanRendererBoardColumnConfig as al, defineExtensionView as an, NavigationOwnerRef as ao, ConflictPayload as ar, BooleanControl as as, BoardViewCreate as at, WebviewFilesUploadParams as au, FileRecord as b, LocalExtensionSource as ba, StepStartPart as bc, TerminalSessionHandle as bd, FileRendererResourceRef as bi, KanbanRendererViewMode as bl, defineResourceHierarchyProvider as bn, ViewMenuContribution as bo, worktreeEvents as br, ResourceOption as bs, WebviewArtifactsClient as bt, RendererEventReference as bu, WorkspaceFileContent as c, ExtensionWorkspace as ca, JsonPatch as cc, NotificationStatus as cd, SerializedError as ci, KanbanRendererCreateRowContribution as cl, defineActivityItem as cn, PlacementContribution as co, SessionLifecyclePayload as cr, ControlParam as cs, AutomationRun as ct, WebviewHostCapabilityResult as cu, WorkspaceListItem as d, AssetContributions as da, ErrorPart as dc, PackageAssetDescriptor as dd, NavigationTargetCommand as di, KanbanRendererQueryParams as dl, defineConnection as dn, PlacementPresence as do, WorktreeRemovedPayload as dr, DateControl as ds, AutomationRunStatus as dt, WebviewNavigationOpenParams as du, ProcessRunResult as ea, HarnessQuestionReplyError as ec, ListNotificationsQuery as ed, ListProjectActivityInput as ef, CommandReject as ei, WhenExpression as el, ExtensionViewModule as en, ControlsViewBody as eo, eventRef as er, ActionOption as es, WorkbenchExtensionViewBody as et, WebviewExtensionSettingKeyParams as eu, WorkspaceProviderDescriptor as f, BehaviourContributions as fa, FilePart as fc, RendererContext as fd, NavigationTargetCompound as fi, KanbanRendererQueryResult as fl, defineFileIconTheme as fn, PlacementPresentation as fo, gitEvents as fr, MarkdownControl as fs, AutomationTokenRecord as ft, WebviewNotificationActionParams as fu, sessionAttachmentMimeTypesByExtension as g, ExtensionDefinition as ga, SessionMessage as gc, ResourceRemovedEvent as gd, NavigationTargetPanel as gi, KanbanRendererRowActivationHandler as gl, defineNavigationItem as gn, PlacementTabSnapshot as go, sessionSlots as gr, RangeControl as gs, ListAutomationRunEventsResponse as gt, WebviewPreferencesGetParams as gu, UpdateSettingsInput as h, ExtensionConnectionContribution as ha, ReasoningPart as hc, ResourceRef as hd, NavigationTargetPage as hi, KanbanRendererRowAction as hl, defineMode as hn, PlacementTabPresentation as ho, sessionEvents as hr, ParamEditorReadOnlyImage as hs, IssueAutomationTokenResponse as ht, WebviewNotificationShowParams as hu, ListWorkspaceFilesInput as i, WorkspaceFilesMount as ia, HarnessRecoveryResult as ic, NotificationActorType as id, CommandRequestedEvent as ii, KanbanRendererAttributeType as il, WebviewFilesClient as in, NavigationItemContribution as io, CommitPayload as ir, BaseControl as is, BoardView as it, WebviewFilesListParams as iu, EnableInstalledExtensionResponse as j, WorkspaceProviderRef as ja, CommandPaletteResourceItem as jc, ContributionRef as jd, ExtensionActivityApi as ji, ParamDescriptor as jl, defineView as jn, TreeRendererResourceRef as jo, workbenchResourceKinds as jr, ResourceConstraint as js, artifactsRead as jt, ExtensionConnectionsApi as ju, AddLocalExtensionFolderResponse as k, WorkspaceProviderCreateInput as ka, CommandPaletteContribution as kc, ContributionInput as kd, CommandRunHandler as ki, MultiSelectParam as kl, defineTemplateType as kn, TreeRendererContribution as ko, workbenchPanels as kr, VectorValue as ks, ArtifactMountKey as kt, ExtensionConnectionResponse as ku, WorkspaceFileEntry as l, ExtensionWorkspaceProvider as la, QuestionResponse as lc, UpdateNotificationInput as ld, WorkbenchAttachmentInvocationContext as li, KanbanRendererEnumOption as ll, defineArtifactMount as ln, PlacementItem as lo, WorkspaceProvisionPayload as lr, ControlValue as ls, AutomationRunError as lt, WebviewHostCapabilityResults as lu, Settings as m, EXTENSION_API_VERSION as ma, PatchPart as mc, ResourceAnchor as md, NavigationTargetItem as mi, KanbanRendererRow as ml, defineKeybinding as mn, PlacementTabMenuRow as mo, projectSlots as mr, ParamEditorReadOnlyContent as ms, IssueAutomationTokenInput as mt, WebviewNotificationResolveParams as mu, ListWorkspaceActivityInput as n, SetupContext as na, HarnessReattachInput as nc, Notification as nd, CommandReplaceInvocation as ni, KanbanRendererAttributeDescriptor as nl, ExtensionViewRenderContext as nn, FileViewBody as no, isNavigationTarget as nr, AnchorGridControl as ns, BoardField as nt, WebviewFileScope as nu, RenameWorkspaceInput as o, CreateExtensionWorkspaceInput as oa, HarnessSession as oc, NotificationOrigin as od, CommandStartedEvent as oi, KanbanRendererColumnAction as ol, GuestHost as on, NavigationTreeContribution as oo, MergePayload as or, ColorControl as os, BoardViewUpdate as ot, WebviewHostCapability as ou, WriteWorkspaceFileInput as p, CommandDefinition as pa, LoadingPart as pc, RendererInvocationContext as pd, NavigationTargetHref as pi, KanbanRendererResourceRef as pl, defineHarness as pn, PlacementTabMenuGroup as po, projectEvents as pr, NumberControl as ps, CreateAutomationRunInput as pt, WebviewNotificationDismissParams as pu, ExtensionCommandRecord as q, PageSlotCardinality as qa, SettingsSectionContribution as qc, supportsExtensionApiVersion as qd, ExtensionSettingsApi as qi, WEBVIEW_HOST_CAPABILITY_VERSION as ql, mergeHistoryMetadata as qn, ControlsApplyInput as qo, CommandLifecycleEventPayload as qr, HarnessExitStatus as qs, ParsedWorkbenchPageUrl as qt, SessionAttachment as qu, ListWorkspaceActivityResponse as r, StorageScope as ra, HarnessRecoveryInput as rc, NotificationAction as rd, CommandReplaceParams as ri, KanbanRendererAttributeDisplay as rl, PropsStore as rn, KanbanViewBody as ro, qualifyNavigationTarget as rr, AnchorGridValue as rs, BoardSummary as rt, WebviewFilesDeleteParams as ru, Workspace as s, CreateWorkspaceCommandParams as sa, HarnessStartInput as sc, NotificationPriority as sd, CommandTarget as si, KanbanRendererContribution as sl, defineExtension as sn, NavigationTreeSlot as so, RebasePayload as sr, ControlGroup as ss, BoardViews as st, WebviewHostCapabilityParams as su, CreateWorkspaceInput as t, RendererCallback as ta, HarnessQuestionRequest as tc, ListNotificationsResponse as td, CommandRejectedEvent as ti, CollectionBadgeItem as tl, ExtensionViewRender as tn, DataTableViewBody as to, packageAsset as tr, ActionsControl as ts, WorkbenchExtensionViewRecord as tt, WebviewExtensionSettingSetParams as tu, WorkspaceFilesResponse as u, ExtensionWorkspacesApi as ua, TimeoutStrategy as uc, ExtensionResourcesApi as ud, NavigationTarget as ui, KanbanRendererFilterState as ul, defineCommandPaletteResource as un, PlacementMountStrategy as uo, WorkspaceType as ur, ControlValueMap as us, AutomationRunEvent as ut, WebviewKeyboardEventParams as uu, Project as v, ExtensionSourceKind as va, SessionMessageRole as vc, ViewHierarchyParent as vd, FileRendererLoadParams as vi, KanbanRendererSettings as vl, definePage as vn, ViewBody as vo, workspaceEvents as vr, ReadOnlyControl as vs, projectPrefix as vt, WebviewScopedDeclarableCapability as vu, ListExtensionSettingsResponse as w, ScheduleContribution as wa, ToolPartActionType as wc, JsonValue as wd, ArtifactFile as wi, HarnessParam as wl, defineSettingsSection as wn, TreeNodeRowVariant as wo, workbenchModeDefinitions as wr, SelectionControl as ws, WebviewSettingsClient as wt, UiSlotKind as wu, ExtensionSettingDefinitionRecord as x, MiddlewareDefinition as xa, TextPart as xc, TerminalSessionRequest$1 as xd, FileRendererSaveParams as xi, ViewToolbarAction as xl, defineResourceKind as xn, WebviewViewBody as xo, isValidLocalContributionId as xr, ResourceRefValue as xs, WebviewClient as xt, SlotInvocationContext as xu, UpdateProjectInput as y, HookDefinition as ya, StepFinishPart as yc, TerminalEvent as yd, FileRendererLoadResult as yi, KanbanRendererSortDirection as yl, definePlacement as yn, ViewContribution as yo, workspaceSlots as yr, ResourceControl as ys, matchesResourceWhen as yt, RendererContributionBase as yu, DispatchExtensionEventInput as z, WorkflowStatus as za, ExtensionSettingsContribution as zc, StatusRef as zd, ExtensionHarnessInput as zi, ResourceParam as zl, unwrapCommandOutcome as zn, DataTableRendererQueryParams as zo, dockedWorkbenchRegions as zr, RetryableHarnessReattachError as zs, TerminalSessionResult as zt, CreateSessionInput as zu };
|
|
7941
8336
|
export {};
|