Dock

An IDE-style docking workspace where panels are dragged by their tabs to re-dock as tabs or splits, detached into floating windows, maximized, pinned, and closed — the layout model familiar from Visual Studio and VS Code.

Default

Declare BbDockPanel components inside a BbDock and place each one with Region — panels sharing a region become tabs in the same group. Drag a tab onto another panel's center to group them as tabs, onto an edge to create a split, or outside the dock to float it in its own window. Right-click a tab for a context menu (pin, close others, close all), maximize a group from its tab bar, and use the overflow menu when tabs no longer fit. The dock requires an interactive render mode and loads its JavaScript module automatically; BbDockNode and BbDockTabGroup are internal — you only ever declare BbDock and BbDockPanel.
Loading example…

Locked and Non-Closable Panels

Use Locked to pin a panel in place entirely — it cannot be moved, floated, or closed, and it loses its close button. For finer control, Closable="false" keeps a panel draggable but removes its close button, while CanFloat="false" allows re-docking but prevents detaching into a floating window. Try dragging the locked Explorer (it stays put), closing the Editor (no close button), or floating the Output panel (it only re-docks).
Loading example…

Close and Reopen Panels

Closing a panel raises OnPanelClosed with the panel's Id — fired once per panel even when a context-menu action closes several tabs at once. Capture the dock with @ref and call OpenPanelAsync to bring a closed panel back into a default location. Close the Terminal, Output, or Properties tab below, then reopen it with the buttons above the dock.
Loading example…

Panel Size Constraints

Constrain a panel's dimensions in pixels with MinWidth, MinHeight, MaxWidth, and MaxHeight. Constraints apply while resizing splits between docked panels and while resizing a floating window. Here the Explorer will not shrink below 180px wide, the Terminal keeps at least 120px of height, and the Properties panel stays between 220px and 400px wide — drag the split handles or float a panel to see the limits enforced.
Loading example…

Empty State

When every panel has been closed the dock shows its empty state — by default the localized Dock.NoPanelsOpen text. Provide EmptyContent to replace it with custom markup, such as a restore action. When supplying EmptyContent alongside panels, wrap the panels in an explicit <ChildContent> tag. Close both tabs below, then use the restore button; GetClosedPanelIds returns the closed panels in registration order.
Loading example…

Public Methods

Use a component reference (@ref) on BbDock to access these methods programmatically.

Method Returns Description
OpenPanelAsync(string panelId) Task Reopens a previously closed panel, docking it into a sensible default location
GetClosedPanelIds() IReadOnlyList<string> Returns the ids of panels that are currently closed and can be reopened, in registration order