@vcp-dev/site-edit-engine 0.10.22 → 0.10.24

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.
@@ -1,4 +1,4 @@
1
- import type { SiteEditClassNameSourceStyleContext, SiteEditCompositionContext, SiteEditPageComposition, SiteEditProperties } from "@vcp-dev/contracts";
1
+ import type { SiteEditClassNameSourceStyleContext, SiteEditCompositionContext, SiteEditPageCompositionActionScope, SiteEditPageComposition, SiteEditProperties } from "@vcp-dev/contracts";
2
2
  import type { NodeCapabilitySnapshot } from "./capability.js";
3
3
  import type { BoundaryKind } from "./boundary.js";
4
4
  import type { OperationType } from "./operation.js";
@@ -31,6 +31,7 @@ export interface RenderEntry {
31
31
  parentKey: string | null;
32
32
  childKeys: string[];
33
33
  pageCompositionUnitKey?: string;
34
+ pageCompositionActionScope?: SiteEditPageCompositionActionScope;
34
35
  operationSummary: OperationSummary;
35
36
  dynamicDataSummary?: DynamicDataSummaryView;
36
37
  }
@@ -33,6 +33,14 @@ export declare class PreviewFileSystemSiteEditEngineRuntime implements PreviewSi
33
33
  };
34
34
  parentKey?: string | null | undefined;
35
35
  pageCompositionUnitKey?: string | undefined;
36
+ pageCompositionActionScope?: {
37
+ kind: "route-unit";
38
+ } | {
39
+ kind: "source-siblings";
40
+ siblingKeys: string[];
41
+ } | {
42
+ kind: "unavailable";
43
+ } | undefined;
36
44
  dynamicDataSummary?: {
37
45
  hasDynamicData: boolean;
38
46
  sourceKinds: ("vcp-cms-collection" | "vcp-cms-form" | "vcp-cms-settings" | "vcp-cms-navigation" | "site-api-route" | "external-api" | "unknown-api")[];
package/dist/runtime.d.ts CHANGED
@@ -26,6 +26,14 @@ export declare class SnapshotSiteEditEngineRuntime implements SiteEditEngineRunt
26
26
  };
27
27
  parentKey?: string | null | undefined;
28
28
  pageCompositionUnitKey?: string | undefined;
29
+ pageCompositionActionScope?: {
30
+ kind: "route-unit";
31
+ } | {
32
+ kind: "source-siblings";
33
+ siblingKeys: string[];
34
+ } | {
35
+ kind: "unavailable";
36
+ } | undefined;
29
37
  dynamicDataSummary?: {
30
38
  hasDynamicData: boolean;
31
39
  sourceKinds: ("vcp-cms-collection" | "vcp-cms-form" | "vcp-cms-settings" | "vcp-cms-navigation" | "site-api-route" | "external-api" | "unknown-api")[];
@@ -0,0 +1,24 @@
1
+ import type { File } from "@babel/types";
2
+ /** Public source parsing result; declaration files must not expose graph internals. */
3
+ export type SiteEditSourceModuleResult = {
4
+ ok: true;
5
+ module: {
6
+ readonly file: string;
7
+ readonly source: string;
8
+ readonly sourceHash: string;
9
+ readonly ast: File;
10
+ readonly imports: readonly {
11
+ readonly specifier: string;
12
+ }[];
13
+ };
14
+ } | {
15
+ ok: false;
16
+ diagnostic: {
17
+ path: string;
18
+ code: "parse-failed" | "import-resolve-failed" | "import-not-found" | "import-read-failed";
19
+ message: string;
20
+ details?: Record<string, unknown>;
21
+ };
22
+ };
23
+ export declare function parseSourceModule(file: string, source: string): SiteEditSourceModuleResult;
24
+ export declare function resolveImportBase(fromFile: string, specifier: string): string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vcp-dev/site-edit-engine",
3
- "version": "0.10.22",
3
+ "version": "0.10.24",
4
4
  "type": "module",
5
5
  "license": "UNLICENSED",
6
6
  "repository": {
@@ -60,7 +60,7 @@
60
60
  "@babel/parser": "^7.29.3",
61
61
  "@babel/traverse": "^7.29.0",
62
62
  "@babel/types": "^7.29.0",
63
- "@vcp-dev/contracts": "0.10.22",
63
+ "@vcp-dev/contracts": "0.10.24",
64
64
  "yaml": "^2.9.0"
65
65
  },
66
66
  "devDependencies": {