DashboardThemeBuilder
Dashboard theme builder. Owns definitions, presets, observation and VSeed registration; components consume the resolved result.
Methods
constructor
Definition:
Parameters:
observe
Observes local, undo/redo and collaborative changes to theme names or definitions. Returns an unsubscribe function.
Definition:
Returns: () => void
Parameters:
setTheme
Selects a theme. An optional definition is saved and selected in one change, without prior registration or changes to chart resources.
Definition:
Returns: void
Parameters:
registerTheme
Registers or updates a document theme without selecting it. Definitions are saved and synchronized with the document.
Definition:
Returns: void
Parameters:
getThemeConfig
Returns a copy of the theme definition, checking the document before built-in presets. Returns undefined if absent.
Definition:
Returns: VBIDashboardThemeDefinition \| undefined
Parameters:
getThemeDefinitions
Returns copies of all document theme definitions. Use observe to subscribe to available themes.
Definition:
Returns: Record<string, VBIDashboardThemeDefinition>
getThemeOptions
Lists built-in and document theme names, modes and palettes. Document definitions take precedence for matching names.
Definition:
Returns: VBIDashboardThemeOption[]
resolveTheme
Resolves a theme and ensures VSeed registration with an isolated runtime name. Unknown names fall back to light-default without changing the document.
Definition:
Returns: VBIDashboardResolvedTheme
Parameters:
getTheme
Gets the theme name, defaulting to light-default.
Definition:
Returns: string
toJSON
Exports the theme name.
Definition:
Returns: string