import type { StoryboardEnvironment } from './designImport.js'; import type { StoryboardEnvironmentState } from './storyboardEnvironment.js'; /** * One runtime the whole catalog can be seen under. * * Some products are not one product. The same build runs embedded in a host * application and on its own, and the difference is not a state inside a screen * — it decides which screens exist and what each one is allowed to show. A host * that declared such a runtime had nowhere to put it: an axis belongs to a * frame, and a preview control only dresses the live preview, so the catalog * could only ever be captured under whichever runtime happened to be the * default. The other one was invisible. * * A session preset is that choice, made once for everything. Selecting one * rewrites the storyboard baseline, which every frame's identity already folds * in, so the catalog re-resolves under the new runtime instead of showing * frames captured under the old one. */ export interface SessionPresetDef { /** * Stable key a screen names to say it exists in this runtime. Labels are for * reading and change; this does not. */ id: string; /** Button text. The panel column is narrow, so keep it short. */ label: string; /** * The runtime, as boot conditions. Merged UNDER each frame's own declared * environment: a screen that states a condition outright keeps it. */ environment?: StoryboardEnvironment; /** Tooltip text. */ description?: string; } /** One editor's declared session presets and the selected one, which sets the baseline environment. */ export declare function createSessionPresets(deps: Pick): { setSessionPresets: (next: readonly SessionPresetDef[]) => void; getSessionPresets: () => SessionPresetDef[]; getSelectedSessionPreset: () => number | null; selectSessionPreset: (index: number | null) => void; subscribeSessionPresets: (listener: () => void) => () => void; isInSelectedSessionPreset: (runtimes: readonly string[] | undefined) => boolean; }; export type SessionPresets = ReturnType;