// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually. import type { DerivedTableConfig } from "./DerivedTableConfig.d.ts"; import type { Filter } from "./Filter.d.ts"; import type { Layout } from "./Layout.d.ts"; import type { PanelViewerConfig } from "./PanelViewerConfig.d.ts"; /** * The workspace config format (`{version, active?, layout, panels}`) — * the multi-panel counterpart of the single-panel [`ViewerConfig`] — as * emitted by `saveWorkspace()`. * * - `panels` entries are [`PanelViewerConfig`]s: per-panel state only, no * `settings` key (element-level state). * - `active` names the panel targeted by the *open* settings sidebar; it is * omitted when the sidebar is closed. * * [`ViewerConfig`]: super::ViewerConfig */ export type WorkspaceConfig = { /** * The `@perspective-dev/viewer` version that wrote this workspace. */ version: string, /** * The panel targeted by the open settings sidebar. */ active?: string, /** * The panel arrangement. */ layout: Layout | null, /** * `BTreeMap` (not `HashMap`) so `save()` serializes panels in a * DETERMINISTIC (sorted) key order — a fresh `HashMap` per call * iterates in a per-instance random order, which made consecutive * `save()` outputs byte-unstable. */ panels: { [key in string]?: PanelViewerConfig }, /** * Named derived `Table`s, each a `View` of its `table` promoted to a * `Table`. A `BTreeMap` for the same determinism reason as `panels`. */ derived_tables?: { [key in string]?: DerivedTableConfig }, /** * The element-level global (master/detail cross-) filters. A transient * overlay on every detail panel's view — persisted here, never in a * per-panel entry. Omitted when empty. */ global_filters?: Array, /** * The MASTER (filter-source) panels' ids, referencing `panels` keys. * Roles are layout state (like the panel arrangement), so they persist; * which master contributed which clause does not — restored * `global_filters` are one unattributed bucket. Omitted when empty. */ masters?: Array, /** * Named color-scale definitions shared by every panel: CSS custom * property name (`--psp-user---`) → canonical CSS * value. */ palette?: { [key in string]?: string }, };