@pstdio/workbench 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 CHANGED
@@ -50,13 +50,13 @@ Tab labels resolve from explicit tab presentation, then resource label, then vie
50
50
 
51
51
  Use `shell.setRegionOpen("side" | "secondary" | "sidenav", open)` to hide or show a region. Hiding retains its instances. Mode `regionSettings` owns size, collapsibility, headers, and tab visibility. `mountStrategy: "keep-mounted"` keeps an inactive tab's content mounted; removing its owner disposes it.
52
52
 
53
- The side-panel controller owns attached, floating, or closed presentation. `floatingPanels: "hidden"` prevents floating and reattaches an already floating panel. Per-view menu preferences belong to `panelMenuState`; they do not duplicate region visibility.
53
+ The layout's `side` region stores the Side Panel presentation: `visible` says whether it is open, and `presentation` says attached or floating. The side-panel controller reads and changes it under the active mode's floating policy. `floatingPanels: "hidden"` prevents floating and shows a floating choice attached until floating is allowed again. Per-view menu preferences belong to `panelMenuState`; they do not duplicate region visibility.
54
54
 
55
55
  ## Persistence
56
56
 
57
57
  The browser owns Back/Forward history. Page locations remain version 1. Existing resource locations and stored product data stay valid.
58
58
 
59
- Layout cache version 4 records resource identity keys and the new Main collection model. Old layout entries are ignored. This revision does not invalidate tree state, menu preferences, side-panel presentation, or page locations. Collection page state uses the existing location key to separate workspaces.
59
+ Layout cache version 5 makes the `side` region's visibility the Side Panel's open state; older entries saved a side visibility that never meant open. Old layout entries are ignored, so the Side Panel presentation resets with them. This revision does not invalidate tree state, menu preferences, or page locations. Collection page state uses the existing location key to separate workspaces.
60
60
 
61
61
  Shared mode placements have one cache entry per project and mode. Page cache entries exclude them. Closing a shared panel therefore remains closed when another page is restored; switching projects does not restore another project's mode panels.
62
62
 
@@ -1,5 +1,5 @@
1
- import { Bn as TreeNode, Jn as MenuPath, Ln as TreeContext, O as WorkbenchCore, Sr as FileRendererRefreshEnvelope, Ti as Command, Ur as WorkbenchPanelRenderInput, Vt as WorkbenchOwnedPlacementItem, Zr as WorkbenchPanelInstance, Zt as WorkbenchTerminalController, bn as WorkbenchPageContribution, fr as KanbanRendererCreateSubmission, j as WorkbenchModuleContext, ji as WorkbenchCommandExecutionContext, kt as RegisteredWorkbenchNotification, qn as MenuItem, sa as Disposable, vi as NavigationTarget$1, xn as WorkbenchPlacementPresentation, xt as PreferenceValue, yi as NavigationTargetCommand, zi as ResourceRef$1 } from "./index-Cl3NI1pb.js";
2
- import { i as ReactKanbanRendererContribution, t as ReactAttributeDescriptor } from "./kanban-presentation-Mb9rbE48.js";
1
+ import { $r as WorkbenchPanelInstance, At as RegisteredWorkbenchNotification, Hi as ResourceRef$1, Hr as MenuItem, Kn as KanbanRendererCreateSubmission, Lt as WorkbenchOwnedPlacementItem, M as WorkbenchModuleContext, Oi as Command, Pi as WorkbenchCommandExecutionContext, Pr as TreeNode, Si as NavigationTargetCommand, St as PreferenceValue, Ur as MenuPath, Vr as WorkbenchPanelRenderInput, Zn as KanbanRendererViewsProvider, gn as WorkbenchPlacementPresentation, hn as WorkbenchPageContribution, ir as FileRendererRefreshEnvelope, jr as TreeContext, k as WorkbenchCore, qt as WorkbenchTerminalController, ua as Disposable, xi as NavigationTarget$1 } from "./index-DLh_fcGT.js";
2
+ import { i as ReactKanbanRendererContribution, t as ReactAttributeDescriptor } from "./kanban-presentation-Ds4FpmbS.js";
3
3
  import { Localizable, NavigationTarget, ResourceRef, WebviewHostCapability } from "@pstdio/sdk/extensions";
4
4
  import { CommandExecuteRequest, CommandExecuteResponse, ExtensionCommandPaletteContribution, ExtensionMenuContribution, WorkbenchExtensionCommandPaletteResourceRecord, WorkbenchExtensionMetadata, WorkbenchExtensionMetadata as WorkbenchExtensionMetadata$1 } from "@pstdio/sdk/api";
5
5
  import { z } from "zod";
@@ -265,6 +265,26 @@ declare const extensionDataTableRendererRecordSchema: z.ZodObject<{
265
265
  $l10n: z.ZodString;
266
266
  default: z.ZodOptional<z.ZodString>;
267
267
  }, z.core.$strip>]>>;
268
+ toolbarActions: z.ZodOptional<z.ZodArray<z.ZodObject<{
269
+ id: z.ZodString;
270
+ label: z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
271
+ $l10n: z.ZodString;
272
+ default: z.ZodOptional<z.ZodString>;
273
+ }, z.core.$strip>]>;
274
+ icon: z.ZodOptional<z.ZodString>;
275
+ presentation: z.ZodOptional<z.ZodEnum<{
276
+ secondary: "secondary";
277
+ primary: "primary";
278
+ }>>;
279
+ params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
280
+ input: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
281
+ type: z.ZodString;
282
+ }, z.core.$catchall<z.ZodUnknown>>>>;
283
+ submitLabel: z.ZodOptional<z.ZodString>;
284
+ when: z.ZodOptional<z.ZodString>;
285
+ disabled: z.ZodOptional<z.ZodBoolean>;
286
+ commandId: z.ZodString;
287
+ }, z.core.$strip>>>;
268
288
  columns: z.ZodOptional<z.ZodArray<z.ZodObject<{
269
289
  id: z.ZodString;
270
290
  label: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
@@ -367,6 +387,26 @@ declare const extensionKanbanRendererRecordSchema: z.ZodObject<{
367
387
  $l10n: z.ZodString;
368
388
  default: z.ZodOptional<z.ZodString>;
369
389
  }, z.core.$strip>]>>;
390
+ toolbarActions: z.ZodOptional<z.ZodArray<z.ZodObject<{
391
+ id: z.ZodString;
392
+ label: z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
393
+ $l10n: z.ZodString;
394
+ default: z.ZodOptional<z.ZodString>;
395
+ }, z.core.$strip>]>;
396
+ icon: z.ZodOptional<z.ZodString>;
397
+ presentation: z.ZodOptional<z.ZodEnum<{
398
+ secondary: "secondary";
399
+ primary: "primary";
400
+ }>>;
401
+ params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
402
+ input: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
403
+ type: z.ZodString;
404
+ }, z.core.$catchall<z.ZodUnknown>>>>;
405
+ submitLabel: z.ZodOptional<z.ZodString>;
406
+ when: z.ZodOptional<z.ZodString>;
407
+ disabled: z.ZodOptional<z.ZodBoolean>;
408
+ commandId: z.ZodString;
409
+ }, z.core.$strip>>>;
370
410
  extensionInstanceId: z.ZodOptional<z.ZodString>;
371
411
  attributes: z.ZodOptional<z.ZodArray<z.ZodObject<{
372
412
  id: z.ZodString;
@@ -957,6 +997,7 @@ type Localizer = (value: unknown, fallback?: string) => string;
957
997
  //#endregion
958
998
  //#region src/extensions/contributions/kanban-renderer-contributions.d.ts
959
999
  interface WorkbenchExtensionKanbanRendererAdapter {
1000
+ createViewsProvider?: (record: WorkbenchExtensionKanbanRendererRecord) => KanbanRendererViewsProvider;
960
1001
  /** Override label resolution. Defaults to workbench's `text(value, fallback)`. */
961
1002
  resolveLabel?: Localizer;
962
1003
  /** Post-process an attribute descriptor (after localization). Defaults to identity. */