Single dispatch point for opening, hiding, and toggling every panel and tool surfaced by Studio. Replaces the ~40 openX/hideX/ toggleX methods that used to live directly on Studio.

Add a new panel by:

  1. Module-augmenting PanelMap with its id, panel type, params type.
  2. Calling register with a PanelProvider. Studio code never has to change.

Constructors

Methods

Constructors

Methods

  • Locate the live instance for id without mounting one. Returns undefined when nothing is mounted.

    Type Parameters

    Parameters

    • id: K
    • Optionalparams: PanelEntry<K>["params"]

    Returns PanelEntry<K>["panel"]

  • Hide (without destroying) the panel registered under id, if one is currently mounted. No-op when nothing is mounted.

    Type Parameters

    Parameters

    • id: K
    • Optionalparams: PanelEntry<K>["params"]

    Returns void

  • Open (or reveal) the panel registered under id.

    Behaviour mirrors the legacy openX methods: if the panel is already mounted, ensures it's visible and runs the provider's onReveal hook; otherwise constructs a new one via the provider's create. Returns undefined when a provider's preconditions reject construction.

    Type Parameters

    Parameters

    • id: K
    • Optionalparams: PanelEntry<K>["params"]

    Returns PanelEntry<K>["panel"]

  • Toggle the panel registered under id. Constructs the panel on first call (matching legacy toggleX behaviour).

    Type Parameters

    Parameters

    • id: K
    • Optionalparams: PanelEntry<K>["params"]

    Returns PanelEntry<K>["panel"]