@pygmalionjs/pygmalion 0.5.14 → 0.5.15
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/dist-lib/types/App.d.ts +5 -0
- package/dist-lib/types/canvas/CameraLayer.d.ts +9 -0
- package/dist-lib/types/canvas/Canvas.d.ts +19 -0
- package/dist-lib/types/canvas/FrameLabelBanner.d.ts +7 -0
- package/dist-lib/types/canvas/FrameView.d.ts +9 -0
- package/dist-lib/types/canvas/FrozenRoutePreview.d.ts +12 -0
- package/dist-lib/types/canvas/InspectOverlay.d.ts +10 -0
- package/dist-lib/types/canvas/LightweightCanvas.d.ts +10 -0
- package/dist-lib/types/canvas/ObjectControls.d.ts +22 -0
- package/dist-lib/types/canvas/Preview.d.ts +3 -0
- package/dist-lib/types/canvas/SectionBoxes.d.ts +24 -0
- package/dist-lib/types/canvas/ShadowRoutePreview.d.ts +14 -0
- package/dist-lib/types/canvas/StoryboardConnections.d.ts +31 -0
- package/dist-lib/types/canvas/cameraPlacement.d.ts +45 -0
- package/dist-lib/types/canvas/domTags.d.ts +10 -0
- package/dist-lib/types/canvas/layoutContext.d.ts +9 -0
- package/dist-lib/types/canvas/useFlowSession.d.ts +36 -0
- package/dist-lib/types/canvas/useFrameLod.d.ts +35 -0
- package/dist-lib/types/editor/adaptiveFrameLayout.d.ts +67 -0
- package/dist-lib/types/editor/assetEditing.d.ts +10 -0
- package/dist-lib/types/editor/bannerStyle.d.ts +18 -0
- package/dist-lib/types/editor/catalog.d.ts +101 -0
- package/dist-lib/types/editor/codegen.d.ts +11 -0
- package/dist-lib/types/editor/componentConnections.d.ts +63 -0
- package/dist-lib/types/editor/componentInstances.d.ts +27 -0
- package/dist-lib/types/editor/contentBounds.d.ts +34 -0
- package/dist-lib/types/editor/designCompiler.d.ts +100 -0
- package/dist-lib/types/editor/designImport.d.ts +448 -0
- package/dist-lib/types/editor/documentSync.d.ts +28 -0
- package/dist-lib/types/editor/domImport.d.ts +58 -0
- package/dist-lib/types/editor/editModePolicy.d.ts +17 -0
- package/dist-lib/types/editor/fiberMap.d.ts +16 -0
- package/dist-lib/types/editor/flowSessionScheduler.d.ts +97 -0
- package/dist-lib/types/editor/flowSessions.d.ts +137 -0
- package/dist-lib/types/editor/frameHeight.d.ts +14 -0
- package/dist-lib/types/editor/frameIdentity.d.ts +9 -0
- package/dist-lib/types/editor/frameLabels.d.ts +124 -0
- package/dist-lib/types/editor/frameLanes.d.ts +62 -0
- package/dist-lib/types/editor/frameLod.d.ts +123 -0
- package/dist-lib/types/editor/frameLodRuntime.d.ts +64 -0
- package/dist-lib/types/editor/framePointerHit.d.ts +67 -0
- package/dist-lib/types/editor/framePointerIntent.d.ts +53 -0
- package/dist-lib/types/editor/framePreviewChannels.d.ts +26 -0
- package/dist-lib/types/editor/framePreviewKeys.d.ts +21 -0
- package/dist-lib/types/editor/frameWheelRouting.d.ts +16 -0
- package/dist-lib/types/editor/frozenImport.d.ts +70 -0
- package/dist-lib/types/editor/host.d.ts +114 -0
- package/dist-lib/types/editor/inspect.d.ts +225 -0
- package/dist-lib/types/editor/interactiveStates.d.ts +103 -0
- package/dist-lib/types/editor/livePreviewInstances.d.ts +93 -0
- package/dist-lib/types/editor/liveScreens.d.ts +20 -0
- package/dist-lib/types/editor/nodeSelector.d.ts +20 -0
- package/dist-lib/types/editor/previewBootstrap.d.ts +189 -0
- package/dist-lib/types/editor/previewEnvironmentControls.d.ts +33 -0
- package/dist-lib/types/editor/previewHydration.d.ts +5 -0
- package/dist-lib/types/editor/previewIntent.d.ts +17 -0
- package/dist-lib/types/editor/previewSweep.d.ts +129 -0
- package/dist-lib/types/editor/previewWarmup.d.ts +77 -0
- package/dist-lib/types/editor/projectBootGate.d.ts +45 -0
- package/dist-lib/types/editor/projectRuntime.d.ts +138 -0
- package/dist-lib/types/editor/registry.d.ts +38 -0
- package/dist-lib/types/editor/routePreview.d.ts +285 -0
- package/dist-lib/types/editor/routePreviewArtifactV2.d.ts +34 -0
- package/dist-lib/types/editor/routePreviewArtifactV3.d.ts +64 -0
- package/dist-lib/types/editor/routePreviewPlacement.d.ts +9 -0
- package/dist-lib/types/editor/routePreviewStatus.d.ts +48 -0
- package/dist-lib/types/editor/scenarioCoverage.d.ts +167 -0
- package/dist-lib/types/editor/screenCards.d.ts +101 -0
- package/dist-lib/types/editor/screenDimensions.d.ts +63 -0
- package/dist-lib/types/editor/screenFlows.d.ts +47 -0
- package/dist-lib/types/editor/screenInteractions.d.ts +4 -0
- package/dist-lib/types/editor/screenLists.d.ts +40 -0
- package/dist-lib/types/editor/screenStateGroups.d.ts +36 -0
- package/dist-lib/types/editor/screenshotBitmaps.d.ts +20 -0
- package/dist-lib/types/editor/sectionHeaders.d.ts +117 -0
- package/dist-lib/types/editor/shadowPreview.d.ts +103 -0
- package/dist-lib/types/editor/sharedSource.d.ts +40 -0
- package/dist-lib/types/editor/sourceJournal.d.ts +27 -0
- package/dist-lib/types/editor/store.d.ts +838 -0
- package/dist-lib/types/editor/storyboardComposition.d.ts +116 -0
- package/dist-lib/types/editor/storyboardDiscovery.d.ts +105 -0
- package/dist-lib/types/editor/storyboardEnvironment.d.ts +22 -0
- package/dist-lib/types/editor/storyboardGraph.d.ts +120 -0
- package/dist-lib/types/editor/storyboardGraphRuntime.d.ts +12 -0
- package/dist-lib/types/editor/storyboardGraphView.d.ts +104 -0
- package/dist-lib/types/editor/surfaceDemands.d.ts +138 -0
- package/dist-lib/types/editor/tokens.d.ts +26 -0
- package/dist-lib/types/editor/useObserved.d.ts +1 -0
- package/dist-lib/types/editor/viewportPresets.d.ts +21 -0
- package/dist-lib/types/editor/visualQa.d.ts +50 -0
- package/dist-lib/types/lib.d.ts +345 -0
- package/dist-lib/types/shell/ApplyPanel.d.ts +1 -0
- package/dist-lib/types/shell/AssetsPanel.d.ts +3 -0
- package/dist-lib/types/shell/CanvasStatusProbe.d.ts +5 -0
- package/dist-lib/types/shell/CodePanel.d.ts +1 -0
- package/dist-lib/types/shell/ComponentStateControls.d.ts +108 -0
- package/dist-lib/types/shell/ContextMenu.d.ts +1 -0
- package/dist-lib/types/shell/LayerTree.d.ts +7 -0
- package/dist-lib/types/shell/PropsPanel.d.ts +1 -0
- package/dist-lib/types/shell/StoryboardGraphPanel.d.ts +23 -0
- package/dist-lib/types/shell/ZoomIndicator.d.ts +4 -0
- package/dist-lib/types/shell/qaPresentation.d.ts +9 -0
- package/dist-lib/types/testing.d.ts +8 -0
- package/dist-lib/types/ui/SourceRefControl.d.ts +38 -0
- package/dist-lib/types/ui/icons.d.ts +30 -0
- package/package.json +7 -8
- package/testing.d.ts +0 -26
- package/types.d.ts +0 -2675
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
/** Structural subset of an editor node; keeps this module store-free. */
|
|
2
|
+
export interface CompositionNodeLike {
|
|
3
|
+
componentName?: string;
|
|
4
|
+
sourceStyle?: string;
|
|
5
|
+
domAttributes?: Readonly<Record<string, string>>;
|
|
6
|
+
children?: readonly CompositionNodeLike[];
|
|
7
|
+
}
|
|
8
|
+
export interface CompositionFrameSignals {
|
|
9
|
+
frameId: string;
|
|
10
|
+
name: string;
|
|
11
|
+
/** Registry component this frame is a catalog sheet for, when declared. */
|
|
12
|
+
componentName?: string;
|
|
13
|
+
/** Files the host declared for this frame (page.sourcePaths). */
|
|
14
|
+
declaredFiles?: readonly string[];
|
|
15
|
+
/** Source files observed in the frame's imported tree. */
|
|
16
|
+
sourceFiles: readonly string[];
|
|
17
|
+
/** Registry component instances observed in the frame's imported tree. */
|
|
18
|
+
componentNames: readonly string[];
|
|
19
|
+
}
|
|
20
|
+
export interface CompositionUsedByFrame {
|
|
21
|
+
frameId: string;
|
|
22
|
+
name: string;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Usage answered by the source scan for one file.
|
|
26
|
+
*
|
|
27
|
+
* `direct` is symbol-level with barrels made transparent — the files that
|
|
28
|
+
* name this piece. `transitive` is the dependency closure, which a barrel
|
|
29
|
+
* inflates to roughly the whole app; it is kept only so a number that big can
|
|
30
|
+
* be labelled as what it is.
|
|
31
|
+
*/
|
|
32
|
+
export interface CompositionSourceUsage {
|
|
33
|
+
direct: readonly string[];
|
|
34
|
+
barrels?: readonly string[];
|
|
35
|
+
transitive?: number;
|
|
36
|
+
}
|
|
37
|
+
export type CompositionEvidence = 'observed' | 'direct' | 'transitive' | 'pending' | 'unused' | 'not-traced';
|
|
38
|
+
export interface CompositionEntryView {
|
|
39
|
+
frameId: string;
|
|
40
|
+
name: string;
|
|
41
|
+
/** File the entry is traced by, recovered from its own stamps. */
|
|
42
|
+
sourceFile?: string;
|
|
43
|
+
componentName?: string;
|
|
44
|
+
/** Frames observed rendering this piece. */
|
|
45
|
+
usedByFrames: readonly CompositionUsedByFrame[];
|
|
46
|
+
/** Files that name this piece, with barrels followed through. */
|
|
47
|
+
usedByFiles: readonly string[];
|
|
48
|
+
/** Size of the dependency closure, which is not a usage count. */
|
|
49
|
+
transitiveCount?: number;
|
|
50
|
+
evidence: CompositionEvidence;
|
|
51
|
+
}
|
|
52
|
+
export interface StoryboardCompositionModel {
|
|
53
|
+
entries: readonly CompositionEntryView[];
|
|
54
|
+
/** Entries still waiting for the source scan to answer. */
|
|
55
|
+
pendingCount: number;
|
|
56
|
+
/**
|
|
57
|
+
* Catalog frames with no traceable identity — no stamps yet and no declared
|
|
58
|
+
* component. They are listed so the index stays total; opening one gives it
|
|
59
|
+
* stamps and it moves into the entries on the next build.
|
|
60
|
+
*/
|
|
61
|
+
unplacedFrameIds: readonly string[];
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* Mirror of PYGMALION_SOURCE_USAGE_CONTROL in node/storyboard-environment.mjs;
|
|
65
|
+
* a test pins the pair so the browser cannot drift from the server.
|
|
66
|
+
*/
|
|
67
|
+
export declare const SOURCE_USAGE_CONTROL = "/__pygmalion-storyboard/source-usage";
|
|
68
|
+
/**
|
|
69
|
+
* Reads what a frame rendered out of its imported tree. Only frames that have
|
|
70
|
+
* been imported carry stamps, which is why the static graph still matters.
|
|
71
|
+
*/
|
|
72
|
+
export declare function collectCompositionSignals(root: CompositionNodeLike | undefined): {
|
|
73
|
+
sourceFiles: string[];
|
|
74
|
+
componentNames: string[];
|
|
75
|
+
};
|
|
76
|
+
/**
|
|
77
|
+
* The component a catalog sheet is about. A sheet built from one registry
|
|
78
|
+
* entry says so on its root or its only instance; a gallery listing several
|
|
79
|
+
* has no single subject, and traces by file instead.
|
|
80
|
+
*/
|
|
81
|
+
export declare function catalogComponentName(root: CompositionNodeLike | undefined): string | undefined;
|
|
82
|
+
/**
|
|
83
|
+
* The file a catalog frame is traced by.
|
|
84
|
+
*
|
|
85
|
+
* A declared path wins: the host names the module the sheet is for, while a
|
|
86
|
+
* sheet's tree stamps every file it touched, including the atoms nested
|
|
87
|
+
* inside it. Among several candidates the one whose filename matches the
|
|
88
|
+
* component wins, so a Badge sheet traces Badge.tsx and not the row it sits
|
|
89
|
+
* in.
|
|
90
|
+
*/
|
|
91
|
+
export declare function traceCatalogFile(frame: CompositionFrameSignals): string | undefined;
|
|
92
|
+
export declare function createStoryboardCompositionModel(input: {
|
|
93
|
+
/** Frames on the catalog canvas being indexed. */
|
|
94
|
+
catalog: readonly CompositionFrameSignals[];
|
|
95
|
+
/** Every other frame that could render them (screens and other sheets). */
|
|
96
|
+
consumers: readonly CompositionFrameSignals[];
|
|
97
|
+
/**
|
|
98
|
+
* Answers from the source scan, by traced file. A file absent from this
|
|
99
|
+
* map has not been answered yet — which is not the same as having no
|
|
100
|
+
* users, and must never be reported as one.
|
|
101
|
+
*/
|
|
102
|
+
usageByFile?: Readonly<Record<string, CompositionSourceUsage>>;
|
|
103
|
+
/** True once the scan has been attempted, so absence means pending. */
|
|
104
|
+
usageRequested?: boolean;
|
|
105
|
+
}): StoryboardCompositionModel;
|
|
106
|
+
/**
|
|
107
|
+
* The index invariant, composition side: every catalog frame is either an
|
|
108
|
+
* entry or explicitly unplaced.
|
|
109
|
+
*/
|
|
110
|
+
export declare function validateCompositionCoverage(model: StoryboardCompositionModel, catalog: readonly {
|
|
111
|
+
frameId: string;
|
|
112
|
+
}[]): {
|
|
113
|
+
severity: 'error';
|
|
114
|
+
frameId: string;
|
|
115
|
+
message: string;
|
|
116
|
+
}[];
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import type { DesignImportAsset, DesignImportKind, DesignScreenCase, StoryboardEnvironment } from './designImport';
|
|
2
|
+
import { type StoryboardGraph, type StoryboardDefinition } from './storyboardGraph';
|
|
3
|
+
export interface StoryboardDiscoveryScenario {
|
|
4
|
+
id?: string;
|
|
5
|
+
name?: string;
|
|
6
|
+
section?: string;
|
|
7
|
+
flow?: string;
|
|
8
|
+
sourcePath?: string;
|
|
9
|
+
description?: string;
|
|
10
|
+
environment?: StoryboardEnvironment;
|
|
11
|
+
}
|
|
12
|
+
export interface StoryboardDiscoveryCandidate {
|
|
13
|
+
id?: string;
|
|
14
|
+
route?: string;
|
|
15
|
+
scenarioId?: string;
|
|
16
|
+
environment?: StoryboardEnvironment;
|
|
17
|
+
}
|
|
18
|
+
export interface StoryboardDiscoveryEdge {
|
|
19
|
+
id?: string;
|
|
20
|
+
from?: string;
|
|
21
|
+
to?: string;
|
|
22
|
+
kind?: string;
|
|
23
|
+
label?: string;
|
|
24
|
+
unresolvedTarget?: boolean;
|
|
25
|
+
}
|
|
26
|
+
export interface StoryboardDiscoveryRoute {
|
|
27
|
+
id?: string;
|
|
28
|
+
path?: string;
|
|
29
|
+
}
|
|
30
|
+
export interface StoryboardDiscoveryManifest {
|
|
31
|
+
version?: number;
|
|
32
|
+
routes?: readonly StoryboardDiscoveryRoute[];
|
|
33
|
+
scenarios?: readonly StoryboardDiscoveryScenario[];
|
|
34
|
+
candidates?: readonly StoryboardDiscoveryCandidate[];
|
|
35
|
+
edges?: readonly StoryboardDiscoveryEdge[];
|
|
36
|
+
}
|
|
37
|
+
export interface StoryboardResolvedPage {
|
|
38
|
+
id: string;
|
|
39
|
+
name: string;
|
|
40
|
+
canvas?: string;
|
|
41
|
+
section?: string;
|
|
42
|
+
importKind?: DesignImportKind;
|
|
43
|
+
componentName?: string;
|
|
44
|
+
gallery?: string[];
|
|
45
|
+
route?: string;
|
|
46
|
+
path?: string;
|
|
47
|
+
publish?: boolean;
|
|
48
|
+
width?: number;
|
|
49
|
+
height?: number;
|
|
50
|
+
frameSizeMode?: DesignScreenCase['frameSizeMode'];
|
|
51
|
+
heightMode?: DesignScreenCase['heightMode'];
|
|
52
|
+
maxHeight?: number;
|
|
53
|
+
sourcePaths?: string[];
|
|
54
|
+
flow?: string;
|
|
55
|
+
scenario?: string;
|
|
56
|
+
state?: string;
|
|
57
|
+
scenarioId?: string;
|
|
58
|
+
interactions?: DesignScreenCase['interactions'];
|
|
59
|
+
environment?: StoryboardEnvironment;
|
|
60
|
+
preset?: DesignScreenCase['preset'];
|
|
61
|
+
assertions?: DesignScreenCase['assertions'];
|
|
62
|
+
}
|
|
63
|
+
export interface StoryboardDiscoveryGraphOptions {
|
|
64
|
+
manifest: StoryboardDiscoveryManifest;
|
|
65
|
+
pages: readonly StoryboardResolvedPage[];
|
|
66
|
+
assets?: readonly DesignImportAsset[];
|
|
67
|
+
/** Host-authored user journeys layered over source-inferred transitions. */
|
|
68
|
+
storyboard?: StoryboardDefinition;
|
|
69
|
+
}
|
|
70
|
+
export interface StoryboardDiscoveryResult {
|
|
71
|
+
manifest: StoryboardDiscoveryManifest;
|
|
72
|
+
baselineEnvironment?: StoryboardEnvironment;
|
|
73
|
+
graph: StoryboardGraph;
|
|
74
|
+
}
|
|
75
|
+
export interface StoryboardDiscoveryResponse {
|
|
76
|
+
ok: boolean;
|
|
77
|
+
status: number;
|
|
78
|
+
json(): Promise<unknown>;
|
|
79
|
+
}
|
|
80
|
+
export type StoryboardDiscoveryFetch = (endpoint: string, init: {
|
|
81
|
+
headers: {
|
|
82
|
+
accept: 'application/json';
|
|
83
|
+
};
|
|
84
|
+
cache: 'no-store';
|
|
85
|
+
signal?: AbortSignal;
|
|
86
|
+
}) => Promise<StoryboardDiscoveryResponse>;
|
|
87
|
+
export interface LoadStoryboardDiscoveryOptions extends Omit<StoryboardDiscoveryGraphOptions, 'manifest'> {
|
|
88
|
+
endpoint: string;
|
|
89
|
+
signal?: AbortSignal;
|
|
90
|
+
fetcher?: StoryboardDiscoveryFetch;
|
|
91
|
+
}
|
|
92
|
+
export declare function createStoryboardRouteScenarioId(route: string): string;
|
|
93
|
+
/**
|
|
94
|
+
* Converts the editor's resolved screen frames into graph screen cases.
|
|
95
|
+
* Explicit import kinds win; untyped hosts fall back to route-backed pages.
|
|
96
|
+
*/
|
|
97
|
+
export declare function resolveStoryboardScreenCases(pages: readonly StoryboardResolvedPage[], manifest: StoryboardDiscoveryManifest): DesignScreenCase[];
|
|
98
|
+
export declare function getStoryboardDiscoveryBaselineEnvironment(manifest: StoryboardDiscoveryManifest): StoryboardEnvironment | undefined;
|
|
99
|
+
export declare function createStoryboardGraphFromDiscovery(options: StoryboardDiscoveryGraphOptions): StoryboardGraph;
|
|
100
|
+
export declare function loadStoryboardDiscovery(options: LoadStoryboardDiscoveryOptions): Promise<StoryboardDiscoveryResult>;
|
|
101
|
+
/**
|
|
102
|
+
* Replaces the editor graph atomically from source discovery. A stale graph is
|
|
103
|
+
* cleared both before the request and after any transport or parsing failure.
|
|
104
|
+
*/
|
|
105
|
+
export declare function publishStoryboardDiscovery(options: LoadStoryboardDiscoveryOptions): Promise<StoryboardDiscoveryResult>;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { StoryboardEnvironment } from './designImport';
|
|
2
|
+
export declare function bumpPreviewIdentityEpoch(): void;
|
|
3
|
+
export declare function getPreviewIdentityEpoch(): number;
|
|
4
|
+
export declare const STORYBOARD_ENVIRONMENT_QUERY = "__pygmalion_environment";
|
|
5
|
+
export declare const STORYBOARD_ENVIRONMENT_CONTROL = "/__pygmalion-storyboard/environment";
|
|
6
|
+
export declare function setStoryboardBaselineEnvironment(environment?: StoryboardEnvironment): void;
|
|
7
|
+
export declare function getStoryboardBaselineEnvironment(): StoryboardEnvironment | undefined;
|
|
8
|
+
export declare function mergeStoryboardEnvironment(base?: StoryboardEnvironment, override?: StoryboardEnvironment): StoryboardEnvironment | undefined;
|
|
9
|
+
/**
|
|
10
|
+
* Boot-time environment derived from a screen preset — parity with the Node
|
|
11
|
+
* capture runtime's init script, which installs the preset global and seeds
|
|
12
|
+
* preset storage before any page script runs. Declared case environments
|
|
13
|
+
* still win: merge this layer UNDER the storyboard baseline.
|
|
14
|
+
*/
|
|
15
|
+
export declare function presetBootEnvironment(preset: Readonly<Record<string, unknown>> | undefined): StoryboardEnvironment | undefined;
|
|
16
|
+
/**
|
|
17
|
+
* Adds a declarative browser environment to a route URL.
|
|
18
|
+
*
|
|
19
|
+
* The Pygmalion Vite runtime consumes and removes the query parameter before
|
|
20
|
+
* application modules execute, so routers continue to see the original URL.
|
|
21
|
+
*/
|
|
22
|
+
export declare function createStoryboardRouteUrl(appOrigin: string, route: string, environment?: StoryboardEnvironment): string;
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
import type { DesignImportAsset, DesignScenarioSource, DesignScreenCase } from './designImport';
|
|
2
|
+
export type StoryboardGraphEdgeOrigin = 'explicit' | 'inferred';
|
|
3
|
+
export interface StoryboardGraphEdgeInput {
|
|
4
|
+
id?: string;
|
|
5
|
+
from: string;
|
|
6
|
+
to: string;
|
|
7
|
+
/** Screen or node identities that inherit this outgoing route connection. */
|
|
8
|
+
fromScope?: readonly string[];
|
|
9
|
+
/** Screen or node identities that inherit this incoming route connection. */
|
|
10
|
+
toScope?: readonly string[];
|
|
11
|
+
kind?: string;
|
|
12
|
+
label?: string;
|
|
13
|
+
}
|
|
14
|
+
export interface StoryboardPathInput {
|
|
15
|
+
/** Stable author-owned identity used as the edge id prefix. */
|
|
16
|
+
id: string;
|
|
17
|
+
/** Ordered screen ids visited by this path. */
|
|
18
|
+
screenIds: readonly string[];
|
|
19
|
+
kind?: string;
|
|
20
|
+
label?: string;
|
|
21
|
+
}
|
|
22
|
+
export interface StoryboardDefinition {
|
|
23
|
+
paths?: readonly StoryboardPathInput[];
|
|
24
|
+
edges?: readonly StoryboardGraphEdgeInput[];
|
|
25
|
+
startScreenIds?: readonly string[];
|
|
26
|
+
nonVisualScenarioIds?: readonly string[];
|
|
27
|
+
}
|
|
28
|
+
/** Expands readable authored paths into deterministic adjacent graph edges. */
|
|
29
|
+
export declare function createStoryboardPathEdges(paths: readonly StoryboardPathInput[]): StoryboardGraphEdgeInput[];
|
|
30
|
+
export interface StoryboardGraphBuildOptions {
|
|
31
|
+
screens: readonly DesignScreenCase[];
|
|
32
|
+
assets?: readonly DesignImportAsset[];
|
|
33
|
+
scenarios?: readonly DesignScenarioSource[];
|
|
34
|
+
explicitEdges?: readonly StoryboardGraphEdgeInput[];
|
|
35
|
+
inferredEdges?: readonly StoryboardGraphEdgeInput[];
|
|
36
|
+
startScreenIds?: readonly string[];
|
|
37
|
+
nonVisualScenarioIds?: readonly string[];
|
|
38
|
+
recipeKey?: (screen: DesignScreenCase) => string;
|
|
39
|
+
}
|
|
40
|
+
export interface StoryboardGraphNode {
|
|
41
|
+
id: string;
|
|
42
|
+
canonicalScreenId: string;
|
|
43
|
+
screenIds: readonly string[];
|
|
44
|
+
names: readonly string[];
|
|
45
|
+
recipeKey: string;
|
|
46
|
+
routes: readonly string[];
|
|
47
|
+
scenarioIds: readonly string[];
|
|
48
|
+
sourceKeys: readonly string[];
|
|
49
|
+
flows: readonly string[];
|
|
50
|
+
states: readonly string[];
|
|
51
|
+
}
|
|
52
|
+
export interface StoryboardGraphEdge {
|
|
53
|
+
id: string;
|
|
54
|
+
from: string;
|
|
55
|
+
to: string;
|
|
56
|
+
/** Canonical nodes that expose this edge as an outgoing connection. */
|
|
57
|
+
fromNodeIds?: readonly string[];
|
|
58
|
+
/** Canonical nodes that expose this edge as an incoming connection. */
|
|
59
|
+
toNodeIds?: readonly string[];
|
|
60
|
+
kind?: string;
|
|
61
|
+
label?: string;
|
|
62
|
+
origin: StoryboardGraphEdgeOrigin;
|
|
63
|
+
sourceEdgeIds: readonly string[];
|
|
64
|
+
}
|
|
65
|
+
export interface StoryboardGraphSourceGroup {
|
|
66
|
+
sourceKey: string;
|
|
67
|
+
nodeIds: readonly string[];
|
|
68
|
+
screenIds: readonly string[];
|
|
69
|
+
shared: boolean;
|
|
70
|
+
}
|
|
71
|
+
export interface StoryboardGraphBranch {
|
|
72
|
+
nodeId: string;
|
|
73
|
+
edgeIds: readonly string[];
|
|
74
|
+
targetNodeIds: readonly string[];
|
|
75
|
+
}
|
|
76
|
+
export type StoryboardGraphWarningCode = 'duplicate-screen-id' | 'invalid-recipe' | 'unknown-edge-source' | 'unknown-edge-target' | 'ambiguous-edge-source' | 'ambiguous-edge-target' | 'unknown-start-screen' | 'disconnected-screen' | 'missing-code-scenario';
|
|
77
|
+
export interface StoryboardGraphWarning {
|
|
78
|
+
code: StoryboardGraphWarningCode;
|
|
79
|
+
severity: 'warning' | 'error';
|
|
80
|
+
message: string;
|
|
81
|
+
screenId?: string;
|
|
82
|
+
nodeId?: string;
|
|
83
|
+
edgeId?: string;
|
|
84
|
+
scenarioId?: string;
|
|
85
|
+
}
|
|
86
|
+
export interface StoryboardGraphCoverage {
|
|
87
|
+
screens: number;
|
|
88
|
+
canonicalNodes: number;
|
|
89
|
+
mergedScreens: number;
|
|
90
|
+
edges: number;
|
|
91
|
+
connectedNodes: number;
|
|
92
|
+
disconnectedScreens: readonly string[];
|
|
93
|
+
codeScenarios: number;
|
|
94
|
+
representedScenarios: number;
|
|
95
|
+
missingScenarios: readonly string[];
|
|
96
|
+
complete: boolean;
|
|
97
|
+
}
|
|
98
|
+
export interface StoryboardGraph {
|
|
99
|
+
version: 1;
|
|
100
|
+
nodes: readonly StoryboardGraphNode[];
|
|
101
|
+
edges: readonly StoryboardGraphEdge[];
|
|
102
|
+
aliases: Readonly<Record<string, string>>;
|
|
103
|
+
sourceGroups: readonly StoryboardGraphSourceGroup[];
|
|
104
|
+
startNodeIds: readonly string[];
|
|
105
|
+
branches: readonly StoryboardGraphBranch[];
|
|
106
|
+
warnings: readonly StoryboardGraphWarning[];
|
|
107
|
+
coverage: StoryboardGraphCoverage;
|
|
108
|
+
}
|
|
109
|
+
/**
|
|
110
|
+
* Returns a portable identity for the authored reproduction recipe. Descriptive
|
|
111
|
+
* labels and scenario classification are intentionally excluded so aliases of
|
|
112
|
+
* the same rendered state collapse into one canonical graph node.
|
|
113
|
+
*/
|
|
114
|
+
export declare function storyboardScreenRecipeKey(screen: DesignScreenCase): string;
|
|
115
|
+
/**
|
|
116
|
+
* Builds a deterministic storyboard graph without executing application code.
|
|
117
|
+
* Explicit edges are processed before inferred edges and win when both describe
|
|
118
|
+
* the same canonical transition.
|
|
119
|
+
*/
|
|
120
|
+
export declare function createStoryboardGraph(options: StoryboardGraphBuildOptions): StoryboardGraph;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { StoryboardGraph } from './storyboardGraph';
|
|
2
|
+
type StoryboardGraphListener = () => void;
|
|
3
|
+
/**
|
|
4
|
+
* Publishes a project-owned storyboard graph to the editor shell.
|
|
5
|
+
*
|
|
6
|
+
* The runtime only stores the generic graph contract. Projects remain
|
|
7
|
+
* responsible for creating their manifest, meanings, presets, and assertions.
|
|
8
|
+
*/
|
|
9
|
+
export declare function setStoryboardGraph(graph: StoryboardGraph | null): void;
|
|
10
|
+
export declare function getStoryboardGraph(): StoryboardGraph | null;
|
|
11
|
+
export declare function subscribeStoryboardGraph(listener: StoryboardGraphListener): () => void;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import type { StoryboardGraph, StoryboardGraphEdgeOrigin, StoryboardGraphWarning } from './storyboardGraph';
|
|
2
|
+
export interface StoryboardFrameReference {
|
|
3
|
+
frameId: string;
|
|
4
|
+
screenId: string;
|
|
5
|
+
name: string;
|
|
6
|
+
}
|
|
7
|
+
export interface StoryboardGraphFrameView {
|
|
8
|
+
frameId: string;
|
|
9
|
+
screenId: string;
|
|
10
|
+
name: string;
|
|
11
|
+
nodeId: string;
|
|
12
|
+
canonicalScreenId: string;
|
|
13
|
+
canonicalFrameId?: string;
|
|
14
|
+
isCanonical: boolean;
|
|
15
|
+
isStart: boolean;
|
|
16
|
+
isBranch: boolean;
|
|
17
|
+
routes: readonly string[];
|
|
18
|
+
flows: readonly string[];
|
|
19
|
+
states: readonly string[];
|
|
20
|
+
/** Shortest directed distance from an authored storyboard start. */
|
|
21
|
+
depth?: number;
|
|
22
|
+
aliasScreenIds: readonly string[];
|
|
23
|
+
relatedFrameIds: readonly string[];
|
|
24
|
+
branchTargetFrameIds: readonly string[];
|
|
25
|
+
incomingTransitions: readonly StoryboardGraphTransitionView[];
|
|
26
|
+
outgoingTransitions: readonly StoryboardGraphTransitionView[];
|
|
27
|
+
warnings: readonly StoryboardGraphWarning[];
|
|
28
|
+
}
|
|
29
|
+
export interface StoryboardGraphTransitionView {
|
|
30
|
+
edgeId: string;
|
|
31
|
+
sourceFrameId: string;
|
|
32
|
+
targetFrameId: string;
|
|
33
|
+
label?: string;
|
|
34
|
+
kind?: string;
|
|
35
|
+
origin: StoryboardGraphEdgeOrigin;
|
|
36
|
+
}
|
|
37
|
+
export interface StoryboardGraphCanonicalView {
|
|
38
|
+
nodeId: string;
|
|
39
|
+
canonicalScreenId: string;
|
|
40
|
+
canonicalFrameId?: string;
|
|
41
|
+
aliasScreenIds: readonly string[];
|
|
42
|
+
aliasFrameIds: readonly string[];
|
|
43
|
+
}
|
|
44
|
+
export interface StoryboardGraphSourceView {
|
|
45
|
+
sourceKey: string;
|
|
46
|
+
frameIds: readonly string[];
|
|
47
|
+
nodeIds: readonly string[];
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* Why a frame is not listed by any structural section.
|
|
51
|
+
*
|
|
52
|
+
* `outside-graph` — the storyboard has no node for it at all (a frame with no
|
|
53
|
+
* route, so nothing authored or inferred could place it).
|
|
54
|
+
* `no-structure` — the graph knows it, but it is not a start, a branch, an
|
|
55
|
+
* alias, a shared source or a warning, so no section names it.
|
|
56
|
+
*/
|
|
57
|
+
export type StoryboardUnplacedReason = 'outside-graph' | 'no-structure';
|
|
58
|
+
export interface StoryboardUnplacedFrameView {
|
|
59
|
+
frameId: string;
|
|
60
|
+
screenId: string;
|
|
61
|
+
name: string;
|
|
62
|
+
reason: StoryboardUnplacedReason;
|
|
63
|
+
}
|
|
64
|
+
export interface StoryboardGraphViewModel {
|
|
65
|
+
frames: readonly StoryboardGraphFrameView[];
|
|
66
|
+
canonicalGroups: readonly StoryboardGraphCanonicalView[];
|
|
67
|
+
sharedSources: readonly StoryboardGraphSourceView[];
|
|
68
|
+
startFrameIds: readonly string[];
|
|
69
|
+
branchFrameIds: readonly string[];
|
|
70
|
+
warnings: readonly StoryboardGraphWarning[];
|
|
71
|
+
unresolvedWarnings: readonly StoryboardGraphWarning[];
|
|
72
|
+
coverage: StoryboardGraph['coverage'];
|
|
73
|
+
/**
|
|
74
|
+
* Frames the structure cannot place. An index that silently omits a frame
|
|
75
|
+
* is not an index, so these are carried through to be shown rather than
|
|
76
|
+
* dropped — which is what hid most of one section's frames and every
|
|
77
|
+
* catalog frame until now.
|
|
78
|
+
*/
|
|
79
|
+
unplacedFrames: readonly StoryboardUnplacedFrameView[];
|
|
80
|
+
}
|
|
81
|
+
/**
|
|
82
|
+
* An index with no journey in it. A canvas can have structure worth showing
|
|
83
|
+
* (composition) while no storyboard graph exists at all, and the panel still
|
|
84
|
+
* has to list its frames rather than render nothing.
|
|
85
|
+
*/
|
|
86
|
+
export declare function emptyStoryboardViewModel(frameReferences?: readonly StoryboardFrameReference[]): StoryboardGraphViewModel;
|
|
87
|
+
export interface StoryboardCoverageDiagnostic {
|
|
88
|
+
severity: 'error';
|
|
89
|
+
frameId: string;
|
|
90
|
+
message: string;
|
|
91
|
+
}
|
|
92
|
+
/**
|
|
93
|
+
* The index invariant: every frame handed to the view model is accounted for
|
|
94
|
+
* exactly once — either listed by a structural section or carried as
|
|
95
|
+
* unplaced. Hosts and tests assert this; the panel relies on it to promise
|
|
96
|
+
* that the storyboard reaches everything.
|
|
97
|
+
*/
|
|
98
|
+
export declare function validateStoryboardCoverage(model: StoryboardGraphViewModel, frameReferences: readonly StoryboardFrameReference[]): StoryboardCoverageDiagnostic[];
|
|
99
|
+
/**
|
|
100
|
+
* Maps canonical graph identities onto editor frame identities. The graph stays
|
|
101
|
+
* independent from MobX and canvas state; consumers can memoize this projection
|
|
102
|
+
* and wire frame ids to their existing focus action.
|
|
103
|
+
*/
|
|
104
|
+
export declare function createStoryboardGraphViewModel(graph: StoryboardGraph, frameReferences: readonly StoryboardFrameReference[]): StoryboardGraphViewModel;
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
export type SurfaceDemandKind = 'route' | 'control' | 'request';
|
|
2
|
+
export interface SurfaceCandidate {
|
|
3
|
+
kind: SurfaceDemandKind;
|
|
4
|
+
/** Stable identity — the same surface must produce the same id across runs. */
|
|
5
|
+
id: string;
|
|
6
|
+
/** Frame the candidate was found in. Absent for route candidates. */
|
|
7
|
+
frameId?: string;
|
|
8
|
+
/**
|
|
9
|
+
* Frame-independent form of the same surface, so one verdict can answer it
|
|
10
|
+
* everywhere it appears.
|
|
11
|
+
*
|
|
12
|
+
* An application shell repeats: the same send button, the same sidebar toggle,
|
|
13
|
+
* the same navigation tab are in most frames. Demanding a per-frame verdict
|
|
14
|
+
* for each would mean writing the same product fact tens of times over, which
|
|
15
|
+
* is the kind of tax that gets a gate switched off rather than answered. A
|
|
16
|
+
* frame-scoped verdict still wins when the answer genuinely differs there.
|
|
17
|
+
*/
|
|
18
|
+
matchId?: string;
|
|
19
|
+
/** Description of what was found, for the panel and the gate message. */
|
|
20
|
+
detail: string;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* The host's answer. `covered` names the declaration that handles the surface
|
|
24
|
+
* so a stale answer breaks loudly; `excluded` carries the reason instead.
|
|
25
|
+
*/
|
|
26
|
+
export type SurfaceVerdict = {
|
|
27
|
+
verdict: 'covered';
|
|
28
|
+
by: string;
|
|
29
|
+
} | {
|
|
30
|
+
verdict: 'excluded';
|
|
31
|
+
reason: string;
|
|
32
|
+
};
|
|
33
|
+
export type SurfaceClassification = SurfaceVerdict & {
|
|
34
|
+
id: string;
|
|
35
|
+
};
|
|
36
|
+
export interface SurfaceDemandDiagnostic {
|
|
37
|
+
severity: 'error' | 'warning';
|
|
38
|
+
kind: SurfaceDemandKind | 'unknown';
|
|
39
|
+
candidateId: string;
|
|
40
|
+
message: string;
|
|
41
|
+
}
|
|
42
|
+
/** Reasons must say something; the scenario ledger uses the same floor. */
|
|
43
|
+
export declare const MIN_SURFACE_REASON_LENGTH = 10;
|
|
44
|
+
/**
|
|
45
|
+
* Compares what the editor found against what the host answered.
|
|
46
|
+
*
|
|
47
|
+
* Errors, not warnings, on every branch: a warning would let the build stay
|
|
48
|
+
* green while a surface goes unreviewed, which is the state this module exists
|
|
49
|
+
* to end. Callers that need a migration window hold a baseline of known ids
|
|
50
|
+
* rather than downgrading the severity.
|
|
51
|
+
*/
|
|
52
|
+
export declare function validateSurfaceDemands(candidates: readonly SurfaceCandidate[], classifications: readonly SurfaceClassification[]): SurfaceDemandDiagnostic[];
|
|
53
|
+
/** Candidates with no verdict yet — what the panel shows on a frame. */
|
|
54
|
+
export declare function unclassifiedSurfaces(candidates: readonly SurfaceCandidate[], classifications: readonly SurfaceClassification[]): SurfaceCandidate[];
|
|
55
|
+
export interface RouteEnumerationInput {
|
|
56
|
+
/** Routes discovered in the codebase. */
|
|
57
|
+
routes: readonly {
|
|
58
|
+
path?: string;
|
|
59
|
+
id?: string;
|
|
60
|
+
}[];
|
|
61
|
+
/** Screen cases the host declared, with the route each one boots. */
|
|
62
|
+
declaredScreens: readonly {
|
|
63
|
+
id: string;
|
|
64
|
+
route?: string;
|
|
65
|
+
}[];
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* A discovered route with no screen case is the plainest hole there is: the
|
|
69
|
+
* codebase can render it and the storyboard never shows it. Resolution today
|
|
70
|
+
* is silent — `resolveStoryboardScreenCases` maps declared pages and never
|
|
71
|
+
* looks at the discovered route list.
|
|
72
|
+
*/
|
|
73
|
+
export declare function enumerateRouteCandidates(input: RouteEnumerationInput): SurfaceCandidate[];
|
|
74
|
+
export interface ControlNodeLike {
|
|
75
|
+
id: string;
|
|
76
|
+
domTag?: string;
|
|
77
|
+
domAttributes?: Readonly<Record<string, string>>;
|
|
78
|
+
hidden?: boolean;
|
|
79
|
+
}
|
|
80
|
+
/**
|
|
81
|
+
* Enumerates the operable elements of one frame's imported tree.
|
|
82
|
+
*
|
|
83
|
+
* The host declares the axes it thought of, which is why axis coverage has
|
|
84
|
+
* always been a memory exercise. The tree is already imported for editing, so
|
|
85
|
+
* the elements are right there — asking about each one makes a forgotten axis
|
|
86
|
+
* impossible rather than unlikely.
|
|
87
|
+
*
|
|
88
|
+
* Elements with no identifying attribute are skipped: there would be no stable
|
|
89
|
+
* id to attach a verdict to, and a positional id would churn on every layout
|
|
90
|
+
* edit. Hosts that want those asked about mark them.
|
|
91
|
+
*/
|
|
92
|
+
export declare function enumerateControlCandidates(frameId: string, nodes: readonly ControlNodeLike[]): SurfaceCandidate[];
|
|
93
|
+
export interface ObservedRequest {
|
|
94
|
+
/** Absolute or app-relative URL as the page requested it. */
|
|
95
|
+
url: string;
|
|
96
|
+
method?: string;
|
|
97
|
+
}
|
|
98
|
+
/**
|
|
99
|
+
* Collapses a URL to one endpoint shape.
|
|
100
|
+
*
|
|
101
|
+
* Numeric and uuid path segments become `:id` so a list of fixture rows asks
|
|
102
|
+
* one question instead of one per row, and the query string is dropped for the
|
|
103
|
+
* same reason.
|
|
104
|
+
*/
|
|
105
|
+
export declare function requestEndpointShape(url: string): string;
|
|
106
|
+
/**
|
|
107
|
+
* Every request a frame makes is a state the product can be in and usually is
|
|
108
|
+
* not shown: the failure, the empty result, the slow wait. Declaring one used
|
|
109
|
+
* to mean inventing a host flag and a mock branch per state, so hosts declared
|
|
110
|
+
* almost none. The core now supplies the mechanism
|
|
111
|
+
* (`StoryboardEnvironment.network`), which is what makes asking fair.
|
|
112
|
+
*/
|
|
113
|
+
export declare function enumerateRequestCandidates(frameId: string, requests: readonly ObservedRequest[]): SurfaceCandidate[];
|
|
114
|
+
export declare function setSurfaceClassifications(classifications: readonly SurfaceClassification[] | undefined): void;
|
|
115
|
+
export declare function getSurfaceClassifications(): readonly SurfaceClassification[];
|
|
116
|
+
/**
|
|
117
|
+
* Records what a frame asked for while booting.
|
|
118
|
+
*
|
|
119
|
+
* Replaces rather than appends: a re-supplied frame boots again, and appending
|
|
120
|
+
* would keep questions alive for endpoints the current recipe no longer calls.
|
|
121
|
+
*/
|
|
122
|
+
export declare function setObservedRequests(frameId: string, requests: readonly ObservedRequest[]): void;
|
|
123
|
+
export declare function getObservedRequests(frameId: string): readonly ObservedRequest[];
|
|
124
|
+
export interface FrameSurfaceDemands {
|
|
125
|
+
candidates: SurfaceCandidate[];
|
|
126
|
+
unclassified: SurfaceCandidate[];
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* The questions one frame owes an answer to.
|
|
130
|
+
*
|
|
131
|
+
* Controls come from the tree the editor already imported for editing, requests
|
|
132
|
+
* from what the frame asked for while booting. Both are facts about this frame,
|
|
133
|
+
* so the panel can show them next to the axes the host did declare — which is
|
|
134
|
+
* where a missing axis becomes visible instead of merely absent.
|
|
135
|
+
*/
|
|
136
|
+
export declare function frameSurfaceDemands(frameId: string, root?: (ControlNodeLike & {
|
|
137
|
+
children?: readonly ControlNodeLike[];
|
|
138
|
+
}) | null, classifications?: readonly SurfaceClassification[]): FrameSurfaceDemands;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
export interface TokenDef {
|
|
2
|
+
/** CSS variable name — e.g. `--app-color-surface-brand`. */
|
|
3
|
+
name: string;
|
|
4
|
+
/** Value for swatch display (hex, etc., light). The canvas is rendered with var(name) so it is for display only. */
|
|
5
|
+
value: string;
|
|
6
|
+
/** Dark mode value (if present, displays the swatch as half light/dark). */
|
|
7
|
+
dark?: string;
|
|
8
|
+
/** Optional group label. */
|
|
9
|
+
group?: string;
|
|
10
|
+
}
|
|
11
|
+
export declare function setTokens(t: TokenDef[]): void;
|
|
12
|
+
export declare function getTokens(): TokenDef[];
|
|
13
|
+
export declare function setOnTokensChange(cb: ((changed: {
|
|
14
|
+
name: string;
|
|
15
|
+
value: string;
|
|
16
|
+
}[]) => void) | null): void;
|
|
17
|
+
/** Value being edited (overridden) — if not present, injected raw value. */
|
|
18
|
+
export declare function getTokenValue(name: string): string;
|
|
19
|
+
export declare function getTokenOverrides(): {
|
|
20
|
+
name: string;
|
|
21
|
+
value: string;
|
|
22
|
+
}[];
|
|
23
|
+
/** Edit token value — Immediately override document root (live) + notify cumulative changes to host callback. */
|
|
24
|
+
export declare function applyTokenOverride(name: string, value: string): void;
|
|
25
|
+
/** Disable all overrides (return to original value). */
|
|
26
|
+
export declare function resetTokenOverrides(): void;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function useObserved<T>(render: () => T): T;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export interface ViewportPresetDef {
|
|
2
|
+
/** Button text. The panel column is narrow, so keep it to a few characters. */
|
|
3
|
+
label: string;
|
|
4
|
+
/** Frame width in CSS pixels. */
|
|
5
|
+
width: number;
|
|
6
|
+
/** Frame height. Omit to resize width only and leave the current height alone. */
|
|
7
|
+
height?: number;
|
|
8
|
+
/** Tooltip text. Defaults to the dimensions. */
|
|
9
|
+
description?: string;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Declares the preset list. A malformed entry throws here rather than producing a
|
|
13
|
+
* button that silently collapses a frame — the host configures this once at mount.
|
|
14
|
+
*/
|
|
15
|
+
export declare function setViewportPresets(next: readonly ViewportPresetDef[]): void;
|
|
16
|
+
export declare function getViewportPresets(): ViewportPresetDef[];
|
|
17
|
+
/** Whether a frame currently sits at the preset, so the button can read as active. */
|
|
18
|
+
export declare function matchesViewportPreset(preset: ViewportPresetDef, size: {
|
|
19
|
+
width: number;
|
|
20
|
+
height: number;
|
|
21
|
+
}): boolean;
|