Skip to content

react-dockable-desktop


react-dockable-desktop

Hooks

WindowActions

Defined in: components/WindowManagerContext.tsx:176

All layout mutation methods, event bus handles, and serialization methods exposed by the WindowManagerProvider.

Obtain this object via useWindowManagerActions inside a component, or via WorkspaceClient methods from outside the React tree.

Example

tsx
function MyToolbar() {
  const actions = useWindowManagerActions();
  return <button onClick={() => actions.openPanel('map-1', 'map')}>Open Map</button>;
}

Properties

PropertyTypeDescriptionDefined in
closeLeafGroup(leafId) => voidCloses an empty leaf group (removes it from the grid tree).components/WindowManagerContext.tsx:325
closePanel(id) => voidCloses a panel immediately, bypassing dirty-state close guards. For guarded close, use requestClosePanel.components/WindowManagerContext.tsx:197
dockPanel(id, targetLeafId?) => voidReturns a floating window to a docked grid tab group.components/WindowManagerContext.tsx:220
dockPanelToGroup(id, targetLeafId, position) => voidSplits an existing leaf group and docks a panel to the given side.components/WindowManagerContext.tsx:313
dockPanelToWorkspaceEdge(id, position) => voidDocks a floating panel to a workspace edge, creating a full-width or full-height column/row.components/WindowManagerContext.tsx:363
floatPanel(id, rect?, anchor?) => voidDetaches a docked panel, converting it to a resizable floating window.components/WindowManagerContext.tsx:214
focusPanel(id) => voidActivates the given panel regardless of its current state. - Floating panel: raises z-index so the window appears on top of others. - Docked panel: selects the tab within its leaf group. Example // Ensure a panel is visible before updating its content: if (actions.isOpen('map-1')) actions.focusPanel('map-1');components/WindowManagerContext.tsx:249
getOpenPanelIds() => string[]Returns the IDs of all currently open panels (docked, floating, and minimized). Uses a synchronous stateRef read — safe to call outside of render.components/WindowManagerContext.tsx:270
isOpen(id) => booleanReturns true if a panel with the given ID is currently open (docked, floating, or minimized). Uses a synchronous stateRef read — safe to call outside of render. Example if (!actions.isOpen('map-1')) { actions.openPanel('map-1', 'map'); } else { actions.focusPanel('map-1'); }components/WindowManagerContext.tsx:264
loadLayout(layoutJson) => booleanRestores a previously serialized workspace from a JSON string. Replaces the entire current layout — all panels not in the snapshot are closed.components/WindowManagerContext.tsx:287
maximizePanel(id) => voidMaximizes a floating window to cover the entire workspace viewport.components/WindowManagerContext.tsx:225
minimizePanel(id) => voidMinimizes a panel to the bottom taskbar dock, preserving its layout position.components/WindowManagerContext.tsx:202
movePanelOrder(panelId, targetLeafId, targetIndex) => voidReorders a panel's tab index within a docked leaf group.components/WindowManagerContext.tsx:320
openPanel(id, component, options?) => voidOpens a registered panel into the workspace. If the panel ID is already open, the panel is focused instead of duplicated. Example // Open floating and pin to the top-right corner: actions.openPanel('layers', 'layertree', { initialTarget: 'floating', anchor: 'top-right' });components/WindowManagerContext.tsx:191
publish(event, data) => voidPublishes an event to the inter-panel pub/sub event bus.components/WindowManagerContext.tsx:293
registerCloseGuard(id, guard) => voidRegisters a close guard that can intercept and cancel panel close requests.components/WindowManagerContext.tsx:331
requestClosePanel(id, options?) => Promise<void>Closes a panel, first running any registered close guards. If the panel is dirty, shows the built-in unsaved-changes confirmation dialog.components/WindowManagerContext.tsx:357
restorePanel(id) => voidRestores a minimized panel back to its last docked or floating position.components/WindowManagerContext.tsx:207
saveLayout() => stringSerializes the entire workspace state to a JSON string. Includes grid layout, floating window positions, minimized panels, and panel metadata. Example localStorage.setItem('layout', actions.saveLayout());components/WindowManagerContext.tsx:280
setDirection(dir) => voidOverrides the workspace layout direction.components/WindowManagerContext.tsx:368
setDraggedPanelId(id) => voidInternal Stores reference to the active tab ID being dragged.components/WindowManagerContext.tsx:306
setPanelDirty(id, dirty, options?) => voidMarks a panel as dirty (has unsaved changes). Dirty panels show a visual indicator and the built-in close guard prompts the user before closing.components/WindowManagerContext.tsx:344
subscribe(event, callback) => () => voidSubscribes a callback to the inter-panel pub/sub event bus. Example useEffect(() => actions.subscribe('map:zoom', ({ level }) => setZoom(level)), []);components/WindowManagerContext.tsx:304
unregisterCloseGuard(id) => voidRemoves a previously registered close guard.components/WindowManagerContext.tsx:336
updateFloatingPosition(id, updates) => voidUpdates the position or size of a floating window.components/WindowManagerContext.tsx:237
updatePanelTitle(id, title) => voidUpdates the display title of an open panel.components/WindowManagerContext.tsx:350
updateSplitSizes(path, sizes) => voidResizes the flex split proportions of a branch node's children.components/WindowManagerContext.tsx:231

usePanelId()

ts
function usePanelId(): string;

Defined in: components/WindowManagerContext.tsx:1667

React hook to retrieve the panel instance ID for the component currently rendered inside the dockable desktop. Works for docked, floating, modal, and side-panel containers. Opt-in — components that don't need the ID require no changes.

Returns

string

The unique panel instance ID string.

Example

tsx
function MyPanel() {
  const panelId = usePanelId();
  const { closePanel } = useWindowManagerActions();
  return <button onClick={() => closePanel(panelId)}>Close</button>;
}

useRegistry()

ts
function useRegistry(): PanelRegistryClass;

Defined in: components/WindowManagerContext.tsx:431

React hook to read the scoped PanelRegistryClass for the current provider. When the provider was created with a WorkspaceClient, this returns the client's private registry. Otherwise it returns the global PanelRegistry singleton.

Returns

PanelRegistryClass

The panel registry instance in scope.

Example

tsx
function MyComponent() {
  const registry = useRegistry();
  const entry = registry.get('map');
  return entry ? <entry.Component panelId="preview" /> : null;
}

useWindowManagerActions()

ts
function useWindowManagerActions(): WindowActions;

Defined in: components/WindowManagerContext.tsx:1592

React hook to retrieve all layout mutation actions. Returns the public WindowActions interface.

Returns

WindowActions

The full set of workspace mutation methods.

Throws

Error if used outside of a WindowManagerProvider.

Example

tsx
function Toolbar() {
  const actions = useWindowManagerActions();
  return (
    <button onClick={() => actions.openPanel('map-1', 'map')}>Open Map</button>
  );
}

Classes

PanelRegistryClass

Defined in: components/PanelRegistry.ts:40

Registry mapping catalog entries to allow programmatic panel instantiation inside dynamic layout cells or floating windows. Exported so WorkspaceClient can create scoped, per-instance registries.

Constructors

Constructor
ts
new PanelRegistryClass(): PanelRegistryClass;
Returns

PanelRegistryClass

Methods

get()
ts
get(id): PanelRegistryEntry | undefined;

Defined in: components/PanelRegistry.ts:63

Retrieve a registered panel configuration by identifier.

Parameters
ParameterType
idstring
Returns

PanelRegistryEntry | undefined

getRegisteredIds()
ts
getRegisteredIds(): string[];

Defined in: components/PanelRegistry.ts:70

Returns a list of all registered panel entry identifiers.

Returns

string[]

register()
ts
register<P>(
   id, 
   Component, 
   defaultOptions?): void;

Defined in: components/PanelRegistry.ts:49

Register a new component to the panel catalog registry.

Type Parameters
Type Parameter
P extends object
Parameters
ParameterTypeDescription
idstringUnique string identifier.
ComponentComponentType<P>React component instance template.
defaultOptions?{ canClose?: boolean; canDrag?: boolean; canMinimize?: boolean; defaultAnchor?: FloatAnchor; disableLivePreview?: boolean; favoritePosition?: { height: string | number; width: string | number; x: string | number; y: string | number; }; icon?: ReactNode; initialTarget?: "docked" | "floating" | "tabbed"; renderHeaderActions?: (panelId) => ReactNode; title?: | string | { defaultMessage?: string; id: string; values?: Record<string, string | number>; }; }Custom default settings configuration.
defaultOptions.canClose?booleanEnables/disables closing actions for the tab/window.
defaultOptions.canDrag?booleanEnables/disables window drag interactions.
defaultOptions.canMinimize?booleanEnables/disables minimizing of the panel instance.
defaultOptions.defaultAnchor?FloatAnchorCorner of the workspace to anchor newly-opened floating windows to.
defaultOptions.disableLivePreview?booleanDisables live WebGL rendering canvas thumbnails inside the taskbar hover popup previews.
defaultOptions.favoritePosition?{ height: string | number; width: string | number; x: string | number; y: string | number; }Custom default bounds applied when the container is floated.
defaultOptions.favoritePosition.height?string | number-
defaultOptions.favoritePosition.width?string | number-
defaultOptions.favoritePosition.x?string | number-
defaultOptions.favoritePosition.y?string | number-
defaultOptions.icon?ReactNodeIcon placed next to title tags.
defaultOptions.initialTarget?"docked" | "floating" | "tabbed"Initial mounting state inside the desktop layout grid.
defaultOptions.renderHeaderActions?(panelId) => ReactNodeCustom header actions renderer, placing custom components in the window/tab titlebar.
defaultOptions.title?| string | { defaultMessage?: string; id: string; values?: Record<string, string | number>; }Tab and window headers text — plain string or i18n descriptor.
Returns

void


WorkspaceClient

Defined in: WorkspaceClient.ts:82

WorkspaceClient is the central configuration and imperative API object for react-dockable-desktop. Create one instance outside the React tree and pass it to <WindowManagerProvider client={client}>.

Pattern: TanStack QueryClient / Redux store — configuration and imperative access live on the client; rendering is delegated to the thin React provider.

Remarks

Calls made before the provider mounts are queued and replayed automatically in order once _connect() fires. Duplicate openPanel calls for the same ID are deduplicated while queued. Subscriptions made before mount are buffered and re-registered on each connect/reconnect.

Example

ts
const workspace = new WorkspaceClient<MyEvents>({
  panels: {
    map:    { component: MapPanel },
    editor: { component: EditorPanel, defaultOptions: { title: 'Code Editor' } },
  },
  initialState: localStorage.getItem('layout'),
});

<WindowManagerProvider client={workspace}>
  <WindowManager />
</WindowManagerProvider>

// Imperative access from anywhere:
workspace.saveLayout();
workspace.openPanel('map-1', 'map');
workspace.focusPanel('map-1');

Type Parameters

Type ParameterDefault type
TUserEvents extends Record<string, unknown>Record<string, unknown>

Accessors

isConnected
Get Signature
ts
get isConnected(): boolean;

Defined in: WorkspaceClient.ts:158

True while the provider is mounted and React state is accessible.

Returns

boolean

Constructors

Constructor
ts
new WorkspaceClient<TUserEvents>(config?): WorkspaceClient<TUserEvents>;

Defined in: WorkspaceClient.ts:111

Parameters
ParameterType
configWorkspaceClientConfig
Returns

WorkspaceClient<TUserEvents>

Methods

_connect()
ts
_connect(actions): void;

Defined in: WorkspaceClient.ts:132

Internal

Called by WindowManagerProvider after mount.

Parameters
ParameterType
actionsWindowActions
Returns

void

_disconnect()
ts
_disconnect(): void;

Defined in: WorkspaceClient.ts:149

Internal

Called by WindowManagerProvider on unmount.

Returns

void

closePanel()
ts
closePanel(id): void;

Defined in: WorkspaceClient.ts:217

Parameters
ParameterType
idstring
Returns

void

dockPanel()
ts
dockPanel(...args): void;

Defined in: WorkspaceClient.ts:227

Parameters
ParameterType
...args[string, string]
Returns

void

floatPanel()
ts
floatPanel(...args): void;

Defined in: WorkspaceClient.ts:223

Parameters
ParameterType
...args[string, { height: number; width: number; x: number; y: number; }, FloatAnchor | null]
Returns

void

focusPanel()
ts
focusPanel(id): void;

Defined in: WorkspaceClient.ts:238

Activates the given panel regardless of its current state. For floating panels: raises z-index so the window appears on top. For docked panels: selects the tab within its leaf group.

Parameters
ParameterType
idstring
Returns

void

getOpenPanelIds()
ts
getOpenPanelIds(): string[];

Defined in: WorkspaceClient.ts:244

Returns the IDs of all currently open panels.

Returns

string[]

isOpen()
ts
isOpen(id): boolean;

Defined in: WorkspaceClient.ts:241

Returns true if a panel with this ID is currently open.

Parameters
ParameterType
idstring
Returns

boolean

loadLayout()
ts
loadLayout(json): boolean;

Defined in: WorkspaceClient.ts:248

Parameters
ParameterType
jsonstring
Returns

boolean

maximizePanel()
ts
maximizePanel(id): void;

Defined in: WorkspaceClient.ts:231

Parameters
ParameterType
idstring
Returns

void

minimizePanel()
ts
minimizePanel(id): void;

Defined in: WorkspaceClient.ts:219

Parameters
ParameterType
idstring
Returns

void

onPanelClose()
ts
onPanelClose(callback): () => void;

Defined in: WorkspaceClient.ts:283

Subscribe to panel close events.

Parameters
ParameterType
callback(id) => void
Returns

() => void

onPanelMinimize()
ts
onPanelMinimize(callback): () => void;

Defined in: WorkspaceClient.ts:290

Subscribe to panel minimize events.

Parameters
ParameterType
callback(id) => void
Returns

() => void

onPanelOpen()
ts
onPanelOpen(callback): () => void;

Defined in: WorkspaceClient.ts:275

Subscribe to panel open events. Fires only for newly created panels.

Parameters
ParameterType
callback(id, component) => void
Returns

() => void

onPanelRestore()
ts
onPanelRestore(callback): () => void;

Defined in: WorkspaceClient.ts:297

Subscribe to panel restore events.

Parameters
ParameterType
callback(id) => void
Returns

() => void

openPanel()
ts
openPanel(...args): void;

Defined in: WorkspaceClient.ts:201

Parameters
ParameterType
...args[string, string, { anchor?: FloatAnchor | null; initialTarget?: "docked" | "floating" | "tabbed"; title?: | string | ContextMenuPredefinedMessage; }]
Returns

void

publish()
ts
publish<K>(event, data): void;

Defined in: WorkspaceClient.ts:258

Type Parameters
Type Parameter
K extends string | number | symbol
Parameters
ParameterType
eventK
dataTUserEvents & BuiltInPanelEvents[K]
Returns

void

restorePanel()
ts
restorePanel(id): void;

Defined in: WorkspaceClient.ts:221

Parameters
ParameterType
idstring
Returns

void

saveLayout()
ts
saveLayout(): string;

Defined in: WorkspaceClient.ts:246

Returns

string

setDirection()
ts
setDirection(dir): void;

Defined in: WorkspaceClient.ts:254

Parameters
ParameterType
dir"rtl" | "ltr"
Returns

void

subscribe()
ts
subscribe<K>(event, callback): () => void;

Defined in: WorkspaceClient.ts:265

Type Parameters
Type Parameter
K extends string | number | symbol
Parameters
ParameterType
eventK
callback(data) => void
Returns

() => void

Properties

PropertyModifierTypeDescriptionDefined in
configreadonlyPick<WorkspaceClientConfig, | "formatMessage" | "predefinedMessages" | "dir" | "defaultSplitRatio" | "defaultEdgeSplitRatio">Non-rendering configuration forwarded to the provider.WorkspaceClient.ts:90
initialStatereadonlystring | nullSerialised layout to restore on mount, or null to start with an empty canvas.WorkspaceClient.ts:87
registryreadonlyPanelRegistryClassScoped panel registry — fully independent from the global singleton.WorkspaceClient.ts:84

Functions

formatLabel()

ts
function formatLabel(label, formatter): string;

Defined in: components/WindowManagerContext.tsx:1627

Helper to resolve dynamic label strings or localizable descriptor objects into text.

Parameters

ParameterType
label| string | ContextMenuPredefinedMessage | undefined
formatterMessageFormatter

Returns

string


PanelFloatingWindow()

ts
function PanelFloatingWindow(props): 
  | ReactElement<unknown, string | JSXElementConstructor<any>>
  | null;

Defined in: components/PanelOverlay.tsx:694

Declarative floating window anchored inside a PanelOverlayRoot. Supports 8-direction resize, drag-to-free, and drag-to-dock at any corner. Multiple windows docked to the same corner stack vertically with animated offsets.

Parameters

ParameterType
propsPanelFloatingWindowProps

Returns

| ReactElement<unknown, string | JSXElementConstructor<any>> | null

Example

ts
const info = usePanelFloatingWindow();
<PanelFloatingWindow
  id="layer-info" title="Layer Info"
  open={info.isOpen} onClose={info.close}
  defaultAnchor="top-right" defaultWidth={300} defaultHeight={200}
>
  <LayerInfoContent />
</PanelFloatingWindow>

PanelOverlayRoot()

ts
function PanelOverlayRoot(__namedParameters): ReactElement;

Defined in: components/PanelOverlay.tsx:124

Context provider and layout root for the Panel Overlay system. Wrap your panel content with this to enable PanelToolbar, PanelFloatingWindow, and usePanelFloatingWindowManager.

Parameters

ParameterType
__namedParametersPanelOverlayRootProps

Returns

ReactElement

Example

ts
function MyPanel() {
  return (
    <PanelOverlayRoot style={{ position: 'relative', width: '100%', height: '100%' }}>
      <PanelToolbar position="top">...</PanelToolbar>
      <div className="panel-body">content</div>
    </PanelOverlayRoot>
  );
}

PanelToolbar()

ts
function PanelToolbar(__namedParameters): ReactElement;

Defined in: components/PanelOverlay.tsx:319

Toolbar strip that attaches to any edge of a PanelOverlayRoot. Left/right toolbars inset automatically to avoid overlapping top/bottom toolbars. RTL layouts are detected and handled automatically.

Parameters

ParameterType
__namedParametersPanelToolbarProps

Returns

ReactElement

Example

ts
<PanelToolbar position="top" variant="frosted">
  <ToolbarButton icon={<SaveIcon />} title="Save" onClick={save} />
  <ToolbarToggle icon={<GridIcon />} title="Grid" active={grid} onToggle={() => setGrid(v => !v)} />
</PanelToolbar>

PanelToolbarItem()

ts
function PanelToolbarItem(__namedParameters): ReactElement;

Defined in: components/PanelOverlay.tsx:463

Wrapper for a custom non-button control (e.g. a dropdown or input) inside a PanelToolbar.

Parameters

ParameterType
__namedParameters{ children: ReactNode; }
__namedParameters.childrenReactNode

Returns

ReactElement


PanelToolbarSeparator()

ts
function PanelToolbarSeparator(): ReactElement;

Defined in: components/PanelOverlay.tsx:449

Vertical (or horizontal) divider line between groups of toolbar items.

Returns

ReactElement


ToastContainer()

ts
function ToastContainer(__namedParameters): 
  | ReactElement<unknown, string | JSXElementConstructor<any>>
  | null;

Defined in: components/Toast.tsx:420

Portal-rendered notification host. Mount once at your app root, outside the workspace container. All toast.* calls are routed here automatically via the internal event emitter.

Parameters

ParameterType
__namedParametersToastContainerProps

Returns

| ReactElement<unknown, string | JSXElementConstructor<any>> | null

Example

ts
<ToastContainer position="top-right" progressBar />

ToolbarButton()

ts
function ToolbarButton(__namedParameters): ReactElement;

Defined in: components/PanelOverlay.tsx:395

Icon button for use inside a PanelToolbar.

Parameters

ParameterType
__namedParametersToolbarButtonProps

Returns

ReactElement


ToolbarCenter()

ts
function ToolbarCenter(__namedParameters): ReactElement;

Defined in: components/PanelOverlay.tsx:470

Centers its children within the toolbar using absolute positioning.

Parameters

ParameterType
__namedParameters{ children: ReactNode; }
__namedParameters.childrenReactNode

Returns

ReactElement


ToolbarSearchInput()

ts
function ToolbarSearchInput(__namedParameters): ReactElement;

Defined in: components/PanelOverlay.tsx:515

Debounced async search field for use inside a PanelToolbar. Renders as a compact icon button that expands into a text input on activation. Results appear in a portal-rendered dropdown below the input.

Parameters

ParameterType
__namedParametersToolbarSearchInputProps

Returns

ReactElement

Example

ts
<ToolbarSearchInput
  placeholder="Find layer…"
  onSearch={(q, signal) => fetchLayers(q, { signal })}
  onSelect={result => workspace.focusLayer(result.id)}
/>

ToolbarSpacer()

ts
function ToolbarSpacer(): ReactElement;

Defined in: components/PanelOverlay.tsx:456

Flex-grow spacer that pushes subsequent toolbar items to the far edge.

Returns

ReactElement


ToolbarToggle()

ts
function ToolbarToggle(__namedParameters): ReactElement;

Defined in: components/PanelOverlay.tsx:429

Two-state icon toggle button for use inside a PanelToolbar. Sets aria-pressed automatically.

Parameters

ParameterType
__namedParametersToolbarToggleProps

Returns

ReactElement


useFormatMessage()

ts
function useFormatMessage(): MessageFormatter;

Defined in: components/WindowManagerContext.tsx:1611

React hook to retrieve the active i18n formatter.

Returns

MessageFormatter


useFormContainer()

ts
function useFormContainer(): FormContainerContract;

Defined in: components/FormContainerContext.ts:106

React hook to retrieve the current FormContainerContract from context. Enables sub-forms to trigger close/minimize requests, mark themselves dirty, rename their tabs, query dimensions, or subscribe to lifecycle events (resize, close, minimize, restore, activate, deactivate, container-type changes).

Returns

FormContainerContract


usePanelActions()

ts
function usePanelActions(): PanelActions;

Defined in: components/PanelProviderContext.tsx:314

React hook to retrieve actions enabling drawer toggles and modal push actions.

Returns

PanelActions

Throws

Error if used outside of a PanelProvider.


usePanelContext()

ts
function usePanelContext(): Pick<WindowActions, "publish" | "subscribe">;

Defined in: components/WindowManagerContext.tsx:1639

React hook providing pub-sub helper methods for inter-panel event messaging.

Returns

Pick<WindowActions, "publish" | "subscribe">


usePanelContextMenu()

ts
function usePanelContextMenu(items): void;

Defined in: components/WindowManagerContext.tsx:1689

React hook for injecting custom context menu items into a panel's context menu from inside the panel component. Items are dynamic — the array is re-read each time the menu opens, so state-driven changes (enable/disable, add/remove) work automatically. The hook reads the panel ID internally via usePanelId — no prop needed.

Parameters

ParameterTypeDescription
itemsContextMenuItem[]Array of ContextMenuItem entries (simple items, separators, submenus).

Returns

void

Example

tsx
import { usePanelContextMenu } from 'dockable-windows';

function MyPanel() {
  const [dirty, setDirty] = useState(false);
  usePanelContextMenu([
    { label: 'Save', action: () => save() },
    { label: 'Revert', action: () => revert() },
  ]);
  return <Editor onChange={() => setDirty(true)} />;
}

usePanelFloatingWindow()

ts
function usePanelFloatingWindow(): UsePanelFloatingWindowReturn;

Defined in: components/PanelOverlay.tsx:989

Manages the open/close boolean state for a single PanelFloatingWindow. Pass isOpen to open, close to onClose on the component directly.

Returns

UsePanelFloatingWindowReturn

A stable UsePanelFloatingWindowReturn object.

Example

ts
const info = usePanelFloatingWindow();
<PanelFloatingWindow id="info" open={info.isOpen} onClose={info.close} ... />

usePanelFloatingWindowManager()

ts
function usePanelFloatingWindowManager(): PanelFloatingWindowManagerHandle;

Defined in: components/PanelOverlay.tsx:1027

Imperative hook for spawning N named floating windows at runtime from data or event handlers. All windows share z-ordering, drag, and corner-docking infrastructure of the PanelOverlayRoot.

Must be called inside a descendant of PanelOverlayRoot, not in the component that renders the root.

Returns

PanelFloatingWindowManagerHandle

A stable PanelFloatingWindowManagerHandle.

Example

ts
const manager = usePanelFloatingWindowManager();
manager.open('feature-42', { title: 'Feature 42', content: <FeatureDetail id={42} />, anchor: 'top-right' });

usePanelState()

ts
function usePanelState(): PanelState;

Defined in: components/PanelProviderContext.tsx:304

React hook to retrieve the active floating/drawer panels state.

Returns

PanelState

Throws

Error if used outside of a PanelProvider.


usePredefinedMessages()

ts
function usePredefinedMessages(): Record<PredefinedMessageKey, ContextMenuPredefinedMessage>;

Defined in: components/WindowManagerContext.tsx:1647

React hook to fetch the localizable predefined message map catalog.

Returns

Record<PredefinedMessageKey, ContextMenuPredefinedMessage>


useSidebar()

ts
function useSidebar(): SidebarContextValue;

Defined in: components/Sidebar.tsx:537

Returns sidebar control functions from anywhere inside a <Sidebar> tree, including floating panels rendered via {children}.

Returns a no-op object with a console warning when called outside a Sidebar.

Returns

SidebarContextValue


useSidebarTab()

ts
function useSidebarTab(): SidebarTabContextValue;

Defined in: components/Sidebar.tsx:552

Returns tab-specific control functions for components rendered inside a sidebar tab's renderContent tree.

Returns a no-op object with a console warning when called outside tab content.

Returns

SidebarTabContextValue


useStyleClasses()

ts
function useStyleClasses(): StyleClasses;

Defined in: components/WindowManagerContext.tsx:411

Custom hook to read configured style class contexts.

Returns

StyleClasses


useToolbar()

ts
function useToolbar(): ToolbarContextValue;

Defined in: components/ToolbarContext.tsx:45

Returns toolbar state and control functions from anywhere inside a <DockableDesktopProvider> tree.

Returns a no-op object with a console warning when called outside the provider.

Returns

ToolbarContextValue


useWindowManagerState()

Call Signature

ts
function useWindowManagerState(): WindowState;

Defined in: components/WindowManagerContext.tsx:1550

Returns

WindowState

Call Signature

ts
function useWindowManagerState<T>(selector): T;

Defined in: components/WindowManagerContext.tsx:1551

Type Parameters
Type Parameter
T
Parameters
ParameterType
selector(state) => T
Returns

T

Interfaces

BuiltInPanelEvents

Defined in: WorkspaceClient.ts:7

Built-in lifecycle events always available on the WorkspaceClient event bus.

Properties

PropertyTypeDefined in
panel:closed{ id: string; }WorkspaceClient.ts:9
panel:closed.idstringWorkspaceClient.ts:9
panel:minimized{ id: string; }WorkspaceClient.ts:10
panel:minimized.idstringWorkspaceClient.ts:10
panel:opened{ component: string; id: string; }WorkspaceClient.ts:8
panel:opened.componentstringWorkspaceClient.ts:8
panel:opened.idstringWorkspaceClient.ts:8
panel:restored{ id: string; }WorkspaceClient.ts:11
panel:restored.idstringWorkspaceClient.ts:11

CloseOptions

Defined in: components/FormContainerContext.ts:7

Options used when requesting to close a container.

Properties

PropertyTypeDescriptionDefined in
force?booleanIf true, bypasses any dirty state warnings or custom close guards.components/FormContainerContext.ts:9

ConfirmationFormProps

Defined in: forms/ConfirmationForm.tsx:8

Props for the ConfirmationForm component.

Properties

PropertyTypeDescriptionDefined in
alert?stringOptional auxiliary top alert notification text.forms/ConfirmationForm.tsx:14
alertType?"info" | "warning" | "success" | "danger"Type style classification for the alert notice banner.forms/ConfirmationForm.tsx:16
message| string | { defaultMessage?: string; id: string; values?: any; }Main message text or localizable descriptor to display.forms/ConfirmationForm.tsx:12
onCancel?() => voidCallback fired when the user selects the cancel button.forms/ConfirmationForm.tsx:22
onOK?() => voidCallback fired when the user selects the confirm button.forms/ConfirmationForm.tsx:20
title?| string | { defaultMessage?: string; id: string; values?: any; }Optional custom title text or localizable descriptor for the dialog container.forms/ConfirmationForm.tsx:10
useYesNoTitles?booleanIf true, changes action button labels to 'Yes' and 'No' instead of 'OK' and 'Cancel'.forms/ConfirmationForm.tsx:18

ContextMenuAdapter

Defined in: components/ContextMenu.tsx:76

Properties

PropertyTypeDefined in
ComponentForwardRefExoticComponent<ContextMenuProps & RefAttributes<ContextMenuHandle>>components/ContextMenu.tsx:77

ContextMenuCheckbox

Defined in: components/ContextMenu.tsx:17

Properties

PropertyTypeDescriptionDefined in
active?booleanWhether the checkbox column renders at all (default: true).components/ContextMenu.tsx:19
enabled?booleanWhether the item is interactive (default: true). Prefer top-level disabled on the item instead.components/ContextMenu.tsx:21
valuebooleanCurrent checked state.components/ContextMenu.tsx:23

ContextMenuHandle

Defined in: components/ContextMenu.tsx:57

Methods

show()
ts
show(options): void;

Defined in: components/ContextMenu.tsx:58

Parameters
ParameterType
optionsShowContextMenuOptions
Returns

void


ContextMenuPredefinedMessage

Defined in: components/WindowManagerContext.tsx:16

Structure representing localizable message descriptors used in context menus.

Properties

PropertyTypeDescriptionDefined in
defaultMessage?stringFallback label text if translation key is missing.components/WindowManagerContext.tsx:20
idstringTranslation dictionary key.components/WindowManagerContext.tsx:18
values?Record<string, string | number>Values injected into the translated text placeholder.components/WindowManagerContext.tsx:22

ContextMenuProps

Defined in: components/ContextMenu.tsx:63

Properties

PropertyTypeDefined in
animation?stringcomponents/ContextMenu.tsx:65
className?stringcomponents/ContextMenu.tsx:70
formatMessageProvider?MessageFormattercomponents/ContextMenu.tsx:66
onHide?() => voidcomponents/ContextMenu.tsx:68
onOpenChange?(open) => voidcomponents/ContextMenu.tsx:69
onShow?() => voidcomponents/ContextMenu.tsx:67
style?CSSPropertiescomponents/ContextMenu.tsx:71
theme?stringcomponents/ContextMenu.tsx:64

ContextMenuSeparator

Defined in: components/ContextMenu.tsx:36

Properties

PropertyTypeDefined in
separatortruecomponents/ContextMenu.tsx:37

ContextMenuSimpleItem

Defined in: components/ContextMenu.tsx:26

Properties

PropertyTypeDefined in
action?MenuItemActioncomponents/ContextMenu.tsx:31
checkbox?ContextMenuCheckboxcomponents/ContextMenu.tsx:30
cyAction?stringcomponents/ContextMenu.tsx:32
disabled?booleancomponents/ContextMenu.tsx:33
icon?ReactNodecomponents/ContextMenu.tsx:28
labelContextMenuLabelcomponents/ContextMenu.tsx:27
title?ContextMenuLabelcomponents/ContextMenu.tsx:29

ContextMenuSubMenu

Defined in: components/ContextMenu.tsx:40

Properties

PropertyTypeDefined in
items?ContextMenuItem[]components/ContextMenu.tsx:43
labelContextMenuLabelcomponents/ContextMenu.tsx:41
title?ContextMenuLabelcomponents/ContextMenu.tsx:42

DropTarget

Defined in: components/WindowManagerContext.tsx:38

The target leaf and position for a drag-and-drop dock operation.

Properties

PropertyTypeDefined in
leafIdstringcomponents/WindowManagerContext.tsx:39
positionDropPositioncomponents/WindowManagerContext.tsx:40

FloatingWindow

Defined in: components/WindowManagerContext.tsx:91

Bounds and depth metadata for floated panel windows.

Properties

PropertyTypeDescriptionDefined in
anchor?FloatAnchor | nullCorner of the workspace this window is pinned to, or null when free-floating.components/WindowManagerContext.tsx:107
heightstring | numberCSS height value.components/WindowManagerContext.tsx:101
idstringUnique ID of the floating window.components/WindowManagerContext.tsx:93
maximized?booleanTrue if the window is currently maximized to full workspace bounds.components/WindowManagerContext.tsx:105
widthstring | numberCSS width value.components/WindowManagerContext.tsx:99
xstring | numberCSS left position offset (supports number/px or percentage strings).components/WindowManagerContext.tsx:95
ystring | numberCSS top position offset.components/WindowManagerContext.tsx:97
znumberRendering depth stack index layer.components/WindowManagerContext.tsx:103

FormContainerContract

Defined in: components/FormContainerContext.ts:25

Contract interface exposed by a container (like a tab, window, modal, or side-panel) to its children forms, enabling them to control or listen to container events.

Properties

PropertyTypeDescriptionDefined in
containerType?ContainerTypeThe type of container the panel is mounted in. Reflects the state at mount time; subscribe to onContainerTypeChange for live updates.components/FormContainerContext.ts:37
getDimensions?() => | { height: number; width: number; } | nullReturns the current rendered dimensions of this panel, or null if the panel has not been laid out yet.components/FormContainerContext.ts:51
instanceIdstringUnique identifier of the panel or window instance.components/FormContainerContext.ts:39
onActivate?(handler) => () => voidSubscribe to this panel becoming the globally active panel. Fires when activePanelId transitions to this panel's id. Returns an unsubscribe function.components/FormContainerContext.ts:57
onClose?(handler) => () => voidSubscribe to the container's close event. Returns an unsubscribe function.components/FormContainerContext.ts:41
onCloseRequested(handler) => () => voidRegister a custom close guard handler. Returning false or a promise resolving to false blocks closing.components/FormContainerContext.ts:31
onContainerTypeChange?(handler) => () => voidSubscribe to changes in the panel's container type (e.g. docked ↔ floating). Does not fire for minimize/restore cycles — use onMinimize / onRestore for those. Returns an unsubscribe function.components/FormContainerContext.ts:70
onDeactivate?(handler) => () => voidSubscribe to this panel losing active status. Fires when activePanelId transitions away from this panel's id, and also fires if the panel is destroyed while it is active. Returns an unsubscribe function.components/FormContainerContext.ts:64
onMinimize?(handler) => () => voidSubscribe to the container's minimize event. Returns an unsubscribe function.components/FormContainerContext.ts:43
onResize?(handler) => () => voidSubscribe to the container's window resize event, returning width and height. Returns an unsubscribe function.components/FormContainerContext.ts:47
onRestore?(handler) => () => voidSubscribe to the container's restore event. Returns an unsubscribe function.components/FormContainerContext.ts:45
requestClose(options?) => voidRequest the container to close itself. Bypassed by default unless options.force is true.components/FormContainerContext.ts:27
requestMinimize?() => voidRequest the container to minimize itself to the taskbar. No-op if the container type does not support minimize.components/FormContainerContext.ts:49
setDirty(dirty, options?) => voidMark the form's content as dirty (having unsaved changes), triggering alert dialogs on close.components/FormContainerContext.ts:29
setIcon?(icon) => voidChange the tab or window icon dynamically.components/FormContainerContext.ts:35
setTitle(title) => voidChange the display title of the containing tab or window dynamically.components/FormContainerContext.ts:33

LayoutGridNode

Defined in: components/WindowManagerContext.tsx:46

Grid layout branch node containing nested splits and relative flex sizes.

Properties

PropertyTypeDescriptionDefined in
childrenLayoutNode[]Children branches or leaf panels.components/WindowManagerContext.tsx:51
orientationSplitOrientationSplit orientation orientation indicator.components/WindowManagerContext.tsx:49
sizesnumber[]Relative percentage sizes of each child layout block.components/WindowManagerContext.tsx:53
type"branch"-components/WindowManagerContext.tsx:47

LayoutLeafNode

Defined in: components/WindowManagerContext.tsx:59

Grid layout leaf node containing active tab groups and panel arrays.

Properties

PropertyTypeDescriptionDefined in
activePanelIdstring | nullThe currently active panel tab ID.components/WindowManagerContext.tsx:66
canClose?booleanIf false, close menu buttons are disabled for this group's tabs.components/WindowManagerContext.tsx:68
idstringUnique leaf identifier.components/WindowManagerContext.tsx:62
keepOnEmpty?booleanWhen true, the group persists in the layout even after its last panel is closed.components/WindowManagerContext.tsx:70
panelsstring[]Array of panel IDs mounted inside this group.components/WindowManagerContext.tsx:64
type"leaf"-components/WindowManagerContext.tsx:60

ManagedWindowConfig

Defined in: components/PanelOverlay.tsx:29

Configuration for a window spawned imperatively via usePanelFloatingWindowManager().open().

See

usePanelFloatingWindowManager

Properties

PropertyTypeDescriptionDefined in
anchor?FloatAnchorCorner of the panel to dock to on first render. Default 'top-right'components/PanelOverlay.tsx:37
contentReactNodeWindow body content.components/PanelOverlay.tsx:35
height?numberInitial height in pixels.components/PanelOverlay.tsx:41
icon?ReactNodeOptional icon shown to the left of the title in the header.components/PanelOverlay.tsx:33
titlestringText shown in the window's header bar.components/PanelOverlay.tsx:31
width?numberInitial width in pixels.components/PanelOverlay.tsx:39

ModalOptions

Defined in: components/PanelProviderContext.tsx:35

Configuration options applied when opening a Modal.

Properties

PropertyTypeDescriptionDefined in
closable?booleanIf false, hides the modal backdrop exit click and header close button.components/PanelProviderContext.tsx:43
icon?ReactNodeIcon displayed in the modal title bar.components/PanelProviderContext.tsx:39
size?"small" | "auto" | "medium" | "large" | "fullscreen"Size modifier affecting CSS max-width rules.components/PanelProviderContext.tsx:41
title?PanelTitleDisplay title for the modal header.components/PanelProviderContext.tsx:37

PanelActions

Defined in: components/PanelProviderContext.tsx:77

Exposes methods to trigger state actions on drawers and modals.

Properties

PropertyTypeDescriptionDefined in
close(id) => voidCloses an instance by ID.components/PanelProviderContext.tsx:85
closeAll() => voidCloses all drawers and modals in a single action.components/PanelProviderContext.tsx:87
closeAllModals() => voidCloses all open modals.components/PanelProviderContext.tsx:89
getInstance(id) => PanelInstance | undefinedRetrieves metadata for an active instance by ID.components/PanelProviderContext.tsx:91
openLeftPanel<P>(Component, props, options?) => Promise<string | null>Mounts a panel in the left-side container drawer.components/PanelProviderContext.tsx:79
openModal<P>(Component, props, options?) => stringPushes a new modal component instance to the top of the stack.components/PanelProviderContext.tsx:83
openRightPanel<P>(Component, props, options?) => Promise<string | null>Mounts a panel in the right-side container drawer.components/PanelProviderContext.tsx:81
registerCloseHandler(id, handler) => voidSubscribes a custom close confirmation intercept handler.components/PanelProviderContext.tsx:97
setDirty(id, dirty, options?) => voidFlags an instance as dirty (contains unsaved changes).components/PanelProviderContext.tsx:95
unregisterCloseHandler(id) => voidUnsubscribes close confirmation handler.components/PanelProviderContext.tsx:99
updateInstance(id, updates) => voidUpdates the props, configuration options, or dirty flag of an active panel.components/PanelProviderContext.tsx:93

PanelDefinition

Defined in: WorkspaceClient.ts:15

Per-panel definition supplied to WorkspaceClient constructor.

Properties

PropertyTypeDescriptionDefined in
componentComponentType<any>-WorkspaceClient.ts:16
defaultOptions?{ canClose?: boolean; canDrag?: boolean; canMinimize?: boolean; defaultAnchor?: FloatAnchor; disableLivePreview?: boolean; favoritePosition?: { height: string | number; width: string | number; x: string | number; y: string | number; }; icon?: ReactNode; initialTarget?: "docked" | "floating" | "tabbed"; renderHeaderActions?: (panelId) => ReactNode; title?: | string | { defaultMessage?: string; id: string; values?: Record<string, string | number>; }; }-WorkspaceClient.ts:17
defaultOptions.canClose?booleanEnables/disables closing actions for the tab/window.components/PanelRegistry.ts:25
defaultOptions.canDrag?booleanEnables/disables window drag interactions.components/PanelRegistry.ts:21
defaultOptions.canMinimize?booleanEnables/disables minimizing of the panel instance.components/PanelRegistry.ts:23
defaultOptions.defaultAnchor?FloatAnchorCorner of the workspace to anchor newly-opened floating windows to.components/PanelRegistry.ts:27
defaultOptions.disableLivePreview?booleanDisables live WebGL rendering canvas thumbnails inside the taskbar hover popup previews.components/PanelRegistry.ts:29
defaultOptions.favoritePosition?{ height: string | number; width: string | number; x: string | number; y: string | number; }Custom default bounds applied when the container is floated.components/PanelRegistry.ts:19
defaultOptions.favoritePosition.heightstring | number-components/PanelRegistry.ts:19
defaultOptions.favoritePosition.widthstring | number-components/PanelRegistry.ts:19
defaultOptions.favoritePosition.xstring | number-components/PanelRegistry.ts:19
defaultOptions.favoritePosition.ystring | number-components/PanelRegistry.ts:19
defaultOptions.icon?ReactNodeIcon placed next to title tags.components/PanelRegistry.ts:15
defaultOptions.initialTarget?"docked" | "floating" | "tabbed"Initial mounting state inside the desktop layout grid.components/PanelRegistry.ts:17
defaultOptions.renderHeaderActions?(panelId) => ReactNodeCustom header actions renderer, placing custom components in the window/tab titlebar.components/PanelRegistry.ts:31
defaultOptions.title?| string | { defaultMessage?: string; id: string; values?: Record<string, string | number>; }Tab and window headers text — plain string or i18n descriptor.components/PanelRegistry.ts:13

PanelFloatingWindowManagerHandle

Defined in: components/PanelOverlay.tsx:1004

Imperative handle returned by usePanelFloatingWindowManager.

See

usePanelFloatingWindowManager

Methods

close()
ts
close(id): void;

Defined in: components/PanelOverlay.tsx:1008

Close a named window by ID. No-op if the window is not open.

Parameters
ParameterType
idstring
Returns

void

closeAll()
ts
closeAll(): void;

Defined in: components/PanelOverlay.tsx:1010

Close all managed windows.

Returns

void

isOpen()
ts
isOpen(id): boolean;

Defined in: components/PanelOverlay.tsx:1012

Returns true if the named window is currently open.

Parameters
ParameterType
idstring
Returns

boolean

open()
ts
open(id, config): void;

Defined in: components/PanelOverlay.tsx:1006

Spawn or reconfigure a named window. Safe to call with an already-open ID to update config.

Parameters
ParameterType
idstring
configManagedWindowConfig
Returns

void

Properties

PropertyTypeDescriptionDefined in
openIdsstring[]IDs of all currently open managed windows. Changes to this array trigger re-renders.components/PanelOverlay.tsx:1014

PanelFloatingWindowProps

Defined in: components/PanelOverlay.tsx:660

Props for <PanelFloatingWindow>.

Methods

onClose()
ts
onClose(): void;

Defined in: components/PanelOverlay.tsx:670

Called when the user clicks the × button. Set open to false in response.

Returns

void

Properties

PropertyTypeDescriptionDefined in
children?ReactNode-components/PanelOverlay.tsx:677
defaultAnchorFloatAnchorCorner of the panel to dock to on first render. See FloatAnchorcomponents/PanelOverlay.tsx:672
defaultHeightnumberInitial height in pixels.components/PanelOverlay.tsx:676
defaultWidthnumberInitial width in pixels.components/PanelOverlay.tsx:674
icon?ReactNodeOptional icon shown to the left of the title in the header.components/PanelOverlay.tsx:666
idstringUnique identifier within the panel overlay. Used for z-order and stack tracking.components/PanelOverlay.tsx:662
openbooleanWhether the window is mounted and visible. Set to false to close/unmount it.components/PanelOverlay.tsx:668
titlestringText shown in the window's header bar.components/PanelOverlay.tsx:664

PanelInfo

Defined in: components/WindowManagerContext.tsx:113

Stores active runtime properties and status metadata for individual panel instances.

Properties

PropertyTypeDescriptionDefined in
componentstringString matching the component registration ID in the PanelRegistry.components/WindowManagerContext.tsx:119
dirty?booleanTrue if the panel contains unsaved user edits.components/WindowManagerContext.tsx:129
dirtyOptions?DirtyStateOptionsCustom options applied to the automatic unsaved changes modal.components/WindowManagerContext.tsx:131
idstringUnique panel identifier.components/WindowManagerContext.tsx:115
lastFloatingRect?{ anchor?: FloatAnchor | null; height: number; width: number; x: number; y: number; }Saved position boundaries used when returning the panel to a floating state.components/WindowManagerContext.tsx:125
lastFloatingRect.anchor?FloatAnchor | null-components/WindowManagerContext.tsx:125
lastFloatingRect.heightnumber-components/WindowManagerContext.tsx:125
lastFloatingRect.widthnumber-components/WindowManagerContext.tsx:125
lastFloatingRect.xnumber-components/WindowManagerContext.tsx:125
lastFloatingRect.ynumber-components/WindowManagerContext.tsx:125
lastLeafId?stringThe leaf group ID this panel was docked in prior to being floated.components/WindowManagerContext.tsx:127
previousState?"docked" | "floating"Last state held before panel was minimized.components/WindowManagerContext.tsx:123
state"docked" | "floating" | "minimized"Current workspace placement mode.components/WindowManagerContext.tsx:121
title| string | ContextMenuPredefinedMessagePlain text label or localizable message descriptor.components/WindowManagerContext.tsx:117

PanelInstance

Defined in: components/PanelProviderContext.tsx:49

Represents a rendered instance of a panel or modal in the layout.

Properties

PropertyTypeDescriptionDefined in
ComponentComponentType<any>React Component to mount inside the panel.components/PanelProviderContext.tsx:53
containerType"left-panel" | "right-panel" | "modal"The target rendering layout zone.components/PanelProviderContext.tsx:57
dirty?booleanTrue if the form container has unsaved user edits.components/PanelProviderContext.tsx:61
dirtyOptions?DirtyStateOptionsCustom warning options applied to the automatic unsaved changes modal.components/PanelProviderContext.tsx:63
idstringUnique ID generated for this instance.components/PanelProviderContext.tsx:51
optionsSidePanelOptions | ModalOptionsConfiguration metadata settings.components/PanelProviderContext.tsx:59
propsRecord<string, any>Property props passed to the Component.components/PanelProviderContext.tsx:55

PanelOverlayRootProps

Defined in: components/PanelOverlay.tsx:105

Props for <PanelOverlayRoot>.

Properties

PropertyTypeDefined in
childrenReactNodecomponents/PanelOverlay.tsx:106
className?stringcomponents/PanelOverlay.tsx:107
style?CSSPropertiescomponents/PanelOverlay.tsx:108

PanelRegistryEntry

Defined in: components/PanelRegistry.ts:7

Represents a registered component configuration template inside the panel catalog registry.

Properties

PropertyTypeDescriptionDefined in
ComponentComponentType<any>The React component type registered.components/PanelRegistry.ts:9
defaultOptions?{ canClose?: boolean; canDrag?: boolean; canMinimize?: boolean; defaultAnchor?: FloatAnchor; disableLivePreview?: boolean; favoritePosition?: { height: string | number; width: string | number; x: string | number; y: string | number; }; icon?: ReactNode; initialTarget?: "docked" | "floating" | "tabbed"; renderHeaderActions?: (panelId) => ReactNode; title?: | string | { defaultMessage?: string; id: string; values?: Record<string, string | number>; }; }Default metadata settings configuration applied on instantiation.components/PanelRegistry.ts:11
defaultOptions.canClose?booleanEnables/disables closing actions for the tab/window.components/PanelRegistry.ts:25
defaultOptions.canDrag?booleanEnables/disables window drag interactions.components/PanelRegistry.ts:21
defaultOptions.canMinimize?booleanEnables/disables minimizing of the panel instance.components/PanelRegistry.ts:23
defaultOptions.defaultAnchor?FloatAnchorCorner of the workspace to anchor newly-opened floating windows to.components/PanelRegistry.ts:27
defaultOptions.disableLivePreview?booleanDisables live WebGL rendering canvas thumbnails inside the taskbar hover popup previews.components/PanelRegistry.ts:29
defaultOptions.favoritePosition?{ height: string | number; width: string | number; x: string | number; y: string | number; }Custom default bounds applied when the container is floated.components/PanelRegistry.ts:19
defaultOptions.favoritePosition.heightstring | number-components/PanelRegistry.ts:19
defaultOptions.favoritePosition.widthstring | number-components/PanelRegistry.ts:19
defaultOptions.favoritePosition.xstring | number-components/PanelRegistry.ts:19
defaultOptions.favoritePosition.ystring | number-components/PanelRegistry.ts:19
defaultOptions.icon?ReactNodeIcon placed next to title tags.components/PanelRegistry.ts:15
defaultOptions.initialTarget?"docked" | "floating" | "tabbed"Initial mounting state inside the desktop layout grid.components/PanelRegistry.ts:17
defaultOptions.renderHeaderActions?(panelId) => ReactNodeCustom header actions renderer, placing custom components in the window/tab titlebar.components/PanelRegistry.ts:31
defaultOptions.title?| string | { defaultMessage?: string; id: string; values?: Record<string, string | number>; }Tab and window headers text — plain string or i18n descriptor.components/PanelRegistry.ts:13

PanelState

Defined in: components/PanelProviderContext.tsx:67

Stores the active layout structures for floating overlays.

Properties

PropertyTypeDescriptionDefined in
leftPanelPanelInstance | nullThe currently open left drawer panel instance, or null.components/PanelProviderContext.tsx:69
modalsPanelInstance[]Stack containing all active floating modal instances.components/PanelProviderContext.tsx:73
rightPanelPanelInstance | nullThe currently open right drawer panel instance, or null.components/PanelProviderContext.tsx:71

PanelToolbarProps

Defined in: components/PanelOverlay.tsx:295

Props for <PanelToolbar>.

Properties

PropertyTypeDescriptionDefined in
buttonSize?numberIcon size in pixels for all buttons in this toolbar. Falls back to CSS default when unset.components/PanelOverlay.tsx:303
buttonVariant?ButtonVariantDefault button style inherited by ToolbarButton and ToolbarToggle children. Default 'ghost'components/PanelOverlay.tsx:301
children?ReactNode-components/PanelOverlay.tsx:306
className?string-components/PanelOverlay.tsx:305
positionToolbarPositionEdge of the panel overlay to attach to. See ToolbarPositioncomponents/PanelOverlay.tsx:297
style?CSSProperties-components/PanelOverlay.tsx:304
variant?ToolbarVariantBackground style of the toolbar strip. Default 'transparent'components/PanelOverlay.tsx:299

ResolvedToastOptions

Defined in: components/Toast.tsx:37

Fully-resolved options passed to ToastAdapter.show() and ToastAdapter.update(). All optional ToastOptions fields are resolved against the container defaults.

Properties

PropertyTypeDefined in
closablebooleancomponents/Toast.tsx:41
content?ReactNodecomponents/Toast.tsx:43
durationnumbercomponents/Toast.tsx:40
icon?ReactNodecomponents/Toast.tsx:42
idstringcomponents/Toast.tsx:38
onClose?() => voidcomponents/Toast.tsx:44
typeToastTypecomponents/Toast.tsx:39

SearchResult

Defined in: components/PanelOverlay.tsx:477

A single result item returned by ToolbarSearchInputProps.onSearch.

Properties

PropertyTypeDescriptionDefined in
description?stringOptional secondary text shown below the label in the dropdown.components/PanelOverlay.tsx:483
group?stringOptional group header used to bucket results visually.components/PanelOverlay.tsx:485
icon?ReactNodeOptional icon shown to the left of the label.components/PanelOverlay.tsx:487
idstringUnique identifier for this result — passed to onSelect.components/PanelOverlay.tsx:479
labelstringPrimary display text.components/PanelOverlay.tsx:481

ShowContextMenuOptions

Defined in: components/ContextMenu.tsx:50

Properties

PropertyTypeDefined in
event?| MouseEvent | MouseEvent<Element, MouseEvent> | TouchEvent<Element> | TouchEventcomponents/ContextMenu.tsx:51
itemsContextMenuItem[]components/ContextMenu.tsx:54
x?numbercomponents/ContextMenu.tsx:52
y?numbercomponents/ContextMenu.tsx:53

SidebarContextValue

Defined in: components/Sidebar.tsx:104

Value provided by useSidebar(). Available to any component inside the <Sidebar> React tree, including panels rendered via {children}.

Properties

PropertyTypeDefined in
closeDrawer() => voidcomponents/Sidebar.tsx:106
getActiveTab() => string | nullcomponents/Sidebar.tsx:107
openTab(tabId) => voidcomponents/Sidebar.tsx:105

SidebarHandle

Defined in: components/Sidebar.tsx:87

Imperative handle exposed by <Sidebar ref={...}>.

Properties

PropertyTypeDefined in
closeDrawer() => voidcomponents/Sidebar.tsx:89
getActiveTab() => string | nullcomponents/Sidebar.tsx:90
getWidth() => numbercomponents/Sidebar.tsx:97
hide() => voidcomponents/Sidebar.tsx:92
hideStrip() => voidcomponents/Sidebar.tsx:95
openTab(tabId) => voidcomponents/Sidebar.tsx:88
setWidth(px) => voidcomponents/Sidebar.tsx:96
show() => voidcomponents/Sidebar.tsx:91
showStrip() => voidcomponents/Sidebar.tsx:94
toggle() => voidcomponents/Sidebar.tsx:93

SidebarProps

Defined in: components/Sidebar.tsx:54

Properties

PropertyTypeDescriptionDefined in
activeTabId?string | nullControlled active tab id. Omit to use internal state.components/Sidebar.tsx:67
children?ReactNodeMain workspace content rendered alongside the sidebar.components/Sidebar.tsx:79
defaultWidth?numberInitial drawer width in pixels. Default: 220components/Sidebar.tsx:59
drawerWidth?stringDeprecated Use defaultWidth (number, pixels) instead.components/Sidebar.tsx:81
maxWidth?numberMaximum drawer width in pixels during drag-resize. Default: 600components/Sidebar.tsx:63
minWidth?numberMinimum drawer width in pixels during drag-resize. Default: 150components/Sidebar.tsx:61
onActiveTabChange?(tabId) => voidCalled when the active tab changes.components/Sidebar.tsx:69
onStripVisibilityChange?(visible) => voidCalled when showStrip/hideStrip is invoked on the imperative handle.components/Sidebar.tsx:77
onVisibilityChange?(visible) => voidCalled when show/hide/toggle is invoked on the imperative handle.components/Sidebar.tsx:73
onWidthChange?(px) => voidCalled during drag resize and on setWidth() with the new pixel width.components/Sidebar.tsx:65
position?"left" | "right"Which side the activity bar and drawer appear on. Default: 'right'components/Sidebar.tsx:56
stripVisible?booleanCollapse only the activity bar strip, leaving the drawer unaffected. Default: truecomponents/Sidebar.tsx:75
tabsSidebarTab[]-components/Sidebar.tsx:57
visible?booleanCollapse the entire sidebar (strip + drawer). Default: truecomponents/Sidebar.tsx:71

SidebarTab

Defined in: components/Sidebar.tsx:29

Per-tab configuration supplied by the consuming application.

Properties

PropertyTypeDescriptionDefined in
eagerMount?booleanMount immediately when the Sidebar first renders, not on first user click. Implies preserveState: true. Default: falsecomponents/Sidebar.tsx:38
iconReactNode-components/Sidebar.tsx:32
idstring-components/Sidebar.tsx:30
labelstring-components/Sidebar.tsx:31
preserveState?booleanKeep the component alive behind display: none when closed instead of unmounting it. Use for panels with expensive local state. Default: falsecomponents/Sidebar.tsx:44
renderContent(tabId, onClose, onOpen) => ReactNodeCalled to obtain the drawer content for this tab.components/Sidebar.tsx:51

SidebarTabContextValue

Defined in: components/Sidebar.tsx:114

Value provided by useSidebarTab(). Available only to components rendered inside a sidebar tab's renderContent tree.

Properties

PropertyTypeDefined in
onClose() => voidcomponents/Sidebar.tsx:117
onOpen() => voidcomponents/Sidebar.tsx:116
openTab(tabId) => voidcomponents/Sidebar.tsx:118
tabIdstringcomponents/Sidebar.tsx:115

SidePanelOptions

Defined in: components/PanelProviderContext.tsx:25

Configuration options applied when opening a SidePanel.

Properties

PropertyTypeDescriptionDefined in
icon?ReactNodeIcon displayed next to the panel title.components/PanelProviderContext.tsx:29
title?PanelTitleDisplay title for the side-panel header.components/PanelProviderContext.tsx:27
width?string | numberSpecific CSS width (e.g. 300, '40%') for the panel container.components/PanelProviderContext.tsx:31

SidePanelRendererProps

Defined in: components/SidePanelRenderer.tsx:154

Properties

PropertyTypeDescriptionDefined in
defaultWidth?string | numberDefault panel width applied when openLeftPanel/openRightPanel do not specify one. Accepts a number (treated as px) or any CSS width string (e.g. '40vw'). Falls back to 400px if omitted.components/SidePanelRenderer.tsx:160

StyleClasses

Defined in: components/WindowManagerContext.tsx:399

Represents custom CSS classes injected into layout parts.

Properties

PropertyTypeDefined in
modalBodyClass?stringcomponents/WindowManagerContext.tsx:401
modalClass?stringcomponents/WindowManagerContext.tsx:400
sidePanelBodyClass?stringcomponents/WindowManagerContext.tsx:403
sidePanelClass?stringcomponents/WindowManagerContext.tsx:402
windowBodyClass?stringcomponents/WindowManagerContext.tsx:405
windowClass?stringcomponents/WindowManagerContext.tsx:404

ToastAdapter

Defined in: components/Toast.tsx:95

Strategy interface for replacing the built-in toast renderer with an external library. Pass an instance via <ToastContainer adapter={...} /> to redirect all toast.* calls without changing any call sites in your application.

See

ToastContainerProps.adapter

Methods

dismiss()
ts
dismiss(id?): void;

Defined in: components/Toast.tsx:101

Called to dismiss one notification (id provided) or all active notifications (no id).

Parameters
ParameterType
id?string
Returns

void

show()
ts
show(
   id, 
   message, 
   options): void;

Defined in: components/Toast.tsx:97

Called when a new notification is requested.

Parameters
ParameterType
idstring
messageReactNode
optionsResolvedToastOptions
Returns

void

update()
ts
update(
   id, 
   message, 
   options): void;

Defined in: components/Toast.tsx:99

Called when an existing notification is updated (e.g. after toast.promise() resolves).

Parameters
ParameterType
idstring
messageReactNode
optionsPartial<ResolvedToastOptions>
Returns

void

Properties

PropertyTypeDescriptionDefined in
Container| ComponentType<{ position: ToastPosition; }> | nullnull means the adapter manages its own DOM and <ToastContainer> renders nothing. A component causes <ToastContainer> to portal-render it with a position prop.components/Toast.tsx:106

ToastContainerProps

Defined in: components/Toast.tsx:52

Props for <ToastContainer>. Mount one instance at your app root alongside ModalStackRenderer.

Example

ts
<ToastContainer position="top-right" progressBar />

Properties

PropertyTypeDescriptionDefined in
adapter?ToastAdapterDelegate all toast.* calls to a custom renderer (Ant Design, MUI, Sonner, etc.).components/Toast.tsx:72
animation?"none" | "slide" | "fade"Entry/exit animation style. Default 'slide'components/Toast.tsx:64
defaultClosable?booleanShow the × close button on all notifications unless overridden per-toast. Default truecomponents/Toast.tsx:60
defaultDuration?numberDefault auto-dismiss delay in ms. 0 = all notifications sticky. Default 5000components/Toast.tsx:58
maxVisible?numberMaximum number of notifications shown simultaneously. Extras are queued. Default 3components/Toast.tsx:56
newestOnTop?booleanWhen true, newest notification appears at the top of the stack. Default falsecomponents/Toast.tsx:66
pauseOnHover?booleanPause the auto-dismiss timer while the cursor is over a notification. Default truecomponents/Toast.tsx:62
position?ToastPositionWhere notifications appear in the viewport. Default 'top-right'components/Toast.tsx:54
progressBar?booleanShow a countdown progress bar at the bottom of each notification. Default falsecomponents/Toast.tsx:68
width?numberWidth of each notification card in pixels. Default 320components/Toast.tsx:70

ToastFunction()

Defined in: components/Toast.tsx:157

Type of the toast singleton. Callable directly or via named shorthand methods. Import this type to annotate variables or props that accept the toast object.

Example

ts
function notify(fn: ToastFunction) { fn.success('Done!'); }
ts
ToastFunction(msg, opts?): string;

Defined in: components/Toast.tsx:159

Show a notification. opts.type defaults to 'info'. Returns the notification ID.

Parameters

ParameterType
msgReactNode
opts?ToastOptions

Returns

string

Properties

PropertyTypeDescriptionDefined in
dismiss(id?) => voidDismiss a notification by ID, or all active notifications when called with no argument.components/Toast.tsx:169
error(msg, opts?) => stringShow an error notification. Returns the notification ID.components/Toast.tsx:167
info(msg, opts?) => stringShow an info notification. Returns the notification ID.components/Toast.tsx:161
promise<T>(promise, messages, opts?) => Promise<T>Track a promise through pending → success/error states. Shows a sticky pending notification immediately, then transitions it on settlement.components/Toast.tsx:175
success(msg, opts?) => stringShow a success notification. Returns the notification ID.components/Toast.tsx:163
warning(msg, opts?) => stringShow a warning notification. Returns the notification ID.components/Toast.tsx:165

ToastOptions

Defined in: components/Toast.tsx:16

Per-notification options passed to toast(), toast.info(), etc. All fields are optional and fall back to <ToastContainer> defaults when unset.

Properties

PropertyTypeDescriptionDefined in
closable?booleanShow the × close button on this notification. Default from containercomponents/Toast.tsx:24
content?ReactNodeReplace the string message with arbitrary JSX.components/Toast.tsx:28
duration?numberAuto-dismiss delay in ms. 0 = sticky (never auto-dismisses). Default from containercomponents/Toast.tsx:20
icon?ReactNodeOverride the built-in type icon with arbitrary content.components/Toast.tsx:26
id?stringExplicit ID for dedup — calling toast.* with the same id updates the existing card in-place.components/Toast.tsx:22
onClose?() => voidCalled when the notification is dismissed by timer, close button, or toast.dismiss().components/Toast.tsx:30
type?ToastTypeVisual type. Overridden by the toast.info/success/warning/error shorthands. Default 'info'components/Toast.tsx:18

ToastPromiseMessages

Defined in: components/Toast.tsx:80

Message set for toast.promise(). Each field may be static content or a function that receives the resolved/rejected value and returns renderable content.

Type Parameters

Type ParameterDescription
TThe resolved value type of the tracked promise.

Properties

PropertyTypeDescriptionDefined in
errorReactNode | ((err) => ReactNode)Shown on rejection. Pass a function to include the error reason.components/Toast.tsx:86
pendingReactNodeShown while the promise is pending.components/Toast.tsx:82
successReactNode | ((result) => ReactNode)Shown on fulfillment. Pass a function to include the resolved value.components/Toast.tsx:84

ToolbarActionItem

Defined in: components/Toolbar.tsx:19

A one-shot action button.

Properties

PropertyTypeDefined in
disabled?booleancomponents/Toolbar.tsx:25
iconReactNodecomponents/Toolbar.tsx:23
idstringcomponents/Toolbar.tsx:21
labelstringcomponents/Toolbar.tsx:22
onClick() => voidcomponents/Toolbar.tsx:24
type"action"components/Toolbar.tsx:20

ToolbarButtonProps

Defined in: components/PanelOverlay.tsx:382

Props for <ToolbarButton>.

Methods

onClick()
ts
onClick(): void;

Defined in: components/PanelOverlay.tsx:386

Click handler.

Returns

void

Properties

PropertyTypeDescriptionDefined in
disabled?boolean-components/PanelOverlay.tsx:387
iconReactNodeButton icon — typically a small SVG component.components/PanelOverlay.tsx:384
title?stringTooltip text and accessible aria-label.components/PanelOverlay.tsx:389
variant?ButtonVariantVisual style override. Falls back to the parent PanelToolbar's buttonVariant.components/PanelOverlay.tsx:391

ToolbarContextValue

Defined in: components/ToolbarContext.tsx:9

Properties

PropertyTypeDescriptionDefined in
getActiveInGroup(group) => string | nullReturns the active item id in a radio group, or null if none.components/ToolbarContext.tsx:11
isModifierActive(id) => booleanReturns whether a toggle modifier is currently active.components/ToolbarContext.tsx:15
setActiveInGroup(group, id) => voidSet the active item in a radio group (pass null to deselect all).components/ToolbarContext.tsx:13
setModifierActive(id, active) => voidExplicitly set a toggle modifier's active state.components/ToolbarContext.tsx:17
toggleModifier(id) => voidFlip a toggle modifier between active and inactive.components/ToolbarContext.tsx:19

ToolbarGroupItem

Defined in: components/Toolbar.tsx:93

A collapsed tool-family button that opens a flyout panel listing all sub-tools. Only one sub-tool may be active at a time (radio semantics). The parent button's icon morphs to show the currently active sub-tool.

Supports both uncontrolled mode (omit activeItemId — state lives in ToolbarContext) and controlled mode (provide activeItemId — the caller is the single source of truth and must update the prop in response to onActiveItemChange).

Properties

PropertyTypeDescriptionDefined in
activeItemId?string | nullControlled active sub-item id. When provided (even as null), the component reads this prop instead of ToolbarContext and fires onActiveItemChange on click instead of updating context. Omit (undefined) for uncontrolled behaviour.components/Toolbar.tsx:109
defaultIconReactNodeIcon shown when no sub-item is active.components/Toolbar.tsx:100
disabled?boolean-components/Toolbar.tsx:102
idstringServes as both the button ID and the radio group key in ToolbarContext.components/Toolbar.tsx:96
itemsToolbarGroupEntry[]-components/Toolbar.tsx:101
labelstringTooltip / aria-label shown when no sub-item is active.components/Toolbar.tsx:98
onActiveItemChange?(id) => voidCalled when the user selects a sub-item in controlled mode. The toolbar does not update itself — the caller must update activeItemId.components/Toolbar.tsx:114
type"group"-components/Toolbar.tsx:94

ToolbarGroupSubItem

Defined in: components/Toolbar.tsx:69

A single selectable sub-tool inside a group flyout. All sub-items in the same ToolbarGroupItem share one radio group keyed by the parent ToolbarGroupItem's id.

Properties

PropertyTypeDescriptionDefined in
disabled?boolean-components/Toolbar.tsx:75
iconReactNode-components/Toolbar.tsx:72
idstring-components/Toolbar.tsx:70
labelstring-components/Toolbar.tsx:71
onActivate?(id) => voidCalled when this sub-item is selected.components/Toolbar.tsx:77
shortcut?stringKeyboard shortcut displayed in the flyout panel.components/Toolbar.tsx:74

ToolbarHandle

Defined in: components/Toolbar.tsx:141

Methods

hide()
ts
hide(): void;

Defined in: components/Toolbar.tsx:143

Returns

void

show()
ts
show(): void;

Defined in: components/Toolbar.tsx:142

Returns

void

toggle()
ts
toggle(): void;

Defined in: components/Toolbar.tsx:144

Returns

void


ToolbarProps

Defined in: components/Toolbar.tsx:128

Properties

PropertyTypeDescriptionDefined in
className?string-components/Toolbar.tsx:137
itemsToolbarItem[]Ordered list of items to render.components/Toolbar.tsx:132
onVisibilityChange?(visible) => voidCalled when show/hide/toggle is invoked on the imperative handle.components/Toolbar.tsx:136
position?"left" | "top" | "right" | "bottom"Side the strip is attached to. Controls strip orientation. Default: 'left'components/Toolbar.tsx:130
style?CSSProperties-components/Toolbar.tsx:138
visible?booleanCollapse the strip to zero width/height. State is preserved — no unmount.components/Toolbar.tsx:134

ToolbarRadioItem

Defined in: components/Toolbar.tsx:29

A mutually-exclusive radio button within a named group.

Properties

PropertyTypeDescriptionDefined in
disabled?boolean-components/Toolbar.tsx:39
groupstring-components/Toolbar.tsx:32
iconReactNode-components/Toolbar.tsx:34
idstring-components/Toolbar.tsx:31
labelstring-components/Toolbar.tsx:33
onActivate?(id) => voidCalled when this item becomes active.components/Toolbar.tsx:38
shortcut?stringKeyboard shortcut hint — displayed in the group flyout; reserved for future custom tooltip.components/Toolbar.tsx:36
type"radio"-components/Toolbar.tsx:30

ToolbarSearchInputProps

Defined in: components/PanelOverlay.tsx:491

Props for <ToolbarSearchInput>.

Methods

onSearch()
ts
onSearch(query, signal): 
  | SearchResult[]
| Promise<SearchResult[]>;

Defined in: components/PanelOverlay.tsx:499

Called with the current query and an AbortSignal each time the input changes (debounced). Return SearchResult[] directly for synchronous sources, or Promise<SearchResult[]> for async. Abort in-flight requests when the signal fires to prevent stale result races.

Parameters
ParameterType
querystring
signalAbortSignal
Returns

| SearchResult[] | Promise<SearchResult[]>

onSelect()
ts
onSelect(result): void;

Defined in: components/PanelOverlay.tsx:501

Called when the user selects a result from the dropdown.

Parameters
ParameterType
resultSearchResult
Returns

void

Properties

PropertyTypeDescriptionDefined in
placeholder?stringPlaceholder text shown in the expanded input field. Default 'Search…'components/PanelOverlay.tsx:493

ToolbarSeparator

Defined in: components/Toolbar.tsx:56

A visual divider between button groups.

Properties

PropertyTypeDefined in
type"separator"components/Toolbar.tsx:57

ToolbarToggleItem

Defined in: components/Toolbar.tsx:43

An independent on/off toggle modifier (e.g. snap-to-grid).

Properties

PropertyTypeDescriptionDefined in
disabled?boolean-components/Toolbar.tsx:52
iconReactNode-components/Toolbar.tsx:47
idstring-components/Toolbar.tsx:45
labelstring-components/Toolbar.tsx:46
onToggle?(active) => voidCalled after the toggle flips; receives the new active state.components/Toolbar.tsx:51
shortcut?stringKeyboard shortcut hint — reserved for future custom tooltip.components/Toolbar.tsx:49
type"toggle"-components/Toolbar.tsx:44

ToolbarToggleProps

Defined in: components/PanelOverlay.tsx:414

Props for <ToolbarToggle>.

Methods

onToggle()
ts
onToggle(): void;

Defined in: components/PanelOverlay.tsx:420

Called when the button is clicked. Toggle active in response.

Returns

void

Properties

PropertyTypeDescriptionDefined in
activebooleanWhether the toggle is in the active/pressed state. Sets aria-pressed automatically.components/PanelOverlay.tsx:418
disabled?boolean-components/PanelOverlay.tsx:421
iconReactNodeButton icon — typically a small SVG component.components/PanelOverlay.tsx:416
title?stringTooltip text and accessible aria-label.components/PanelOverlay.tsx:423
variant?ButtonVariantVisual style override. Falls back to the parent PanelToolbar's buttonVariant.components/PanelOverlay.tsx:425

UsePanelFloatingWindowReturn

Defined in: components/PanelOverlay.tsx:972

Return type of usePanelFloatingWindow.

See

usePanelFloatingWindow

Methods

close()
ts
close(): void;

Defined in: components/PanelOverlay.tsx:978

Close the floating window.

Returns

void

open()
ts
open(): void;

Defined in: components/PanelOverlay.tsx:976

Open the floating window.

Returns

void

Properties

PropertyTypeDescriptionDefined in
isOpenbooleanWhether the floating window is currently open.components/PanelOverlay.tsx:974

WindowManagerProps

Defined in: components/WindowManager.tsx:810

Props for <WindowManager>.

Properties

PropertyTypeDescriptionDefined in
contextMenuAdapter?ContextMenuAdapterCustom context menu renderer. Defaults to the built-in DefaultContextMenuAdapter.components/WindowManager.tsx:824
defaultPanelIcon?ReactNodeFallback icon shown in panel tabs when no panel-specific icon is provided.components/WindowManager.tsx:814
skin?stringBuilt-in skin name or a custom skin key registered via CSS. Default 'vscode'components/WindowManager.tsx:812
taskbarVisibility?TaskbarVisibilityControls taskbar visibility. - 'always' — permanent bar at the bottom (default) - 'compact' — only visible when minimized panels exist - 'autohide' — overlay bar with 8 px peek strip Default 'always'components/WindowManager.tsx:822

WindowManagerProviderProps

Defined in: components/WindowManagerContext.tsx:487

Props for <DockableDesktopProvider> and <WindowManagerProvider>. Also exported as DockableDesktopProviderProps for consumers who use the composite provider.

See

DockableDesktopProviderProps

Properties

PropertyTypeDescriptionDefined in
childrenReactNode-components/WindowManagerContext.tsx:488
client?WorkspaceClient<Record<string, unknown>>WorkspaceClient instance created outside the React tree. When provided, its panel registry and config take precedence over the individual props below.components/WindowManagerContext.tsx:491
dir?"rtl" | "ltr"Layout direction. 'rtl' mirrors all controls, tab order, and drop zones. Can also be changed at runtime via WorkspaceClient.setDirection(). Default 'ltr'components/WindowManagerContext.tsx:500
formatMessage?MessageFormatterCustom i18n formatter. Receives a { id, defaultMessage } descriptor and returns the translated string. When omitted, defaultMessage is used as-is.components/WindowManagerContext.tsx:494
modalBodyClass?stringCSS class applied to the inner content area of every modal overlay.components/WindowManagerContext.tsx:504
modalClass?stringCSS class applied to the outer wrapper element of every modal overlay.components/WindowManagerContext.tsx:502
predefinedMessages?Record<string, ContextMenuPredefinedMessage>Override the built-in predefined UI strings (confirm button labels, close tooltips, etc.). Merge with or replace defaultPredefinedMessages to localise system strings.components/WindowManagerContext.tsx:497
sidePanelBodyClass?stringCSS class applied to the inner content area of side-panel drawers.components/WindowManagerContext.tsx:508
sidePanelClass?stringCSS class applied to the outer wrapper of left/right side-panel drawers.components/WindowManagerContext.tsx:506
windowBodyClass?stringCSS class applied to the inner content area of floating panel windows.components/WindowManagerContext.tsx:512
windowClass?stringCSS class applied to the outer wrapper of floating panel windows.components/WindowManagerContext.tsx:510

WindowState

Defined in: components/WindowManagerContext.tsx:137

Global window manager state tree representing grid nodes, windows, and panels.

Properties

PropertyTypeDescriptionDefined in
activePanelIdstring | nullThe ID of the active/focused panel.components/WindowManagerContext.tsx:149
dir"rtl" | "ltr"Current layout direction ('ltr' or 'rtl')components/WindowManagerContext.tsx:151
draggedPanelIdstring | nullThe ID of the panel tab currently being dragged.components/WindowManagerContext.tsx:147
edgeSplitRationumberSplit ratio for workspace outer-edge drops (0.1–0.9). Default 0.2.components/WindowManagerContext.tsx:157
floatingFloatingWindow[]Array of active floated windows.components/WindowManagerContext.tsx:141
gridRootLayoutNodeRoot branch node representing the grid.components/WindowManagerContext.tsx:139
isRtlbooleanConvenient boolean flag indicating RTL directioncomponents/WindowManagerContext.tsx:153
minimized{ component: string; id: string; title: | string | ContextMenuPredefinedMessage; }[]Array of minimized panels waiting in the taskbar dock.components/WindowManagerContext.tsx:143
panelsRecord<string, PanelInfo>Map indexing panel metadata descriptors.components/WindowManagerContext.tsx:145
splitRationumberSplit ratio for panel cross-target drops (0.1–0.9). Default 0.5.components/WindowManagerContext.tsx:155

WorkspaceClientConfig

Defined in: WorkspaceClient.ts:21

Configuration object accepted by the WorkspaceClient constructor.

Properties

PropertyTypeDescriptionDefined in
defaultEdgeSplitRatio?numberFraction of the workspace the new panel takes when dropped on the workspace outer edge. Range 0.1–0.9. Default: 0.2.WorkspaceClient.ts:47
defaultSplitRatio?numberFraction of the target panel the new panel takes when dropped on a panel's top/bottom/left/right cross target. Range 0.1–0.9. Default: 0.5.WorkspaceClient.ts:42
dir?"rtl" | "ltr"Initial layout direction.WorkspaceClient.ts:37
formatMessage?MessageFormatterCustom i18n formatter for all internal strings.WorkspaceClient.ts:33
initialState?string | nullSerialised layout produced by a previous saveLayout() call. Pass null or omit to start with an empty canvas.WorkspaceClient.ts:31
panels?Record<string, PanelDefinition>Declarative panel catalog. Replaces imperative PanelRegistry.register() calls. Keys are the component identifiers used in openPanel() and serialised layouts.WorkspaceClient.ts:26
predefinedMessages?Record<string, ContextMenuPredefinedMessage>Override any subset of the built-in predefined message catalog.WorkspaceClient.ts:35

Type Aliases

ButtonVariant

ts
type ButtonVariant = "ghost" | "soft" | "outlined" | "filled";

Defined in: components/PanelOverlay.tsx:292

Visual style applied to ToolbarButton and ToolbarToggle components.


ContextMenuItem

ts
type ContextMenuItem = 
  | ContextMenuSimpleItem
  | ContextMenuSeparator
  | ContextMenuSubMenu;

Defined in: components/ContextMenu.tsx:46


ContextMenuLabel

ts
type ContextMenuLabel = string | ContextMenuPredefinedMessage;

Defined in: components/contextMenuTypes.ts:8


DockableDesktopProviderProps

ts
type DockableDesktopProviderProps = WindowManagerProviderProps;

Defined in: components/DockableDesktopProvider.tsx:11

Props for <DockableDesktopProvider>. Alias of WindowManagerProviderProps.

See

WindowManagerProviderProps


DropPosition

ts
type DropPosition = SplitDirection | "center";

Defined in: components/WindowManagerContext.tsx:35

All possible drop positions — cardinal directions plus center (same group).


FloatAnchor

ts
type FloatAnchor = "top-left" | "top-right" | "bottom-left" | "bottom-right";

Defined in: components/WindowManagerContext.tsx:86

Corner of the workspace a floating window can be pinned to.

When anchor is set on a FloatingWindow, the window is positioned relative to that corner using CSS right/left + top/bottom and stacks with other windows sharing the same anchor (8 px gap, uncapped). Dragging a window away from its corner clears the anchor and returns it to free-float mode. The value is RTL-aware — 'top-left' always means the logical start corner regardless of document direction.


LayoutNode

ts
type LayoutNode = LayoutGridNode | LayoutLeafNode;

Defined in: components/WindowManagerContext.tsx:74

Union type representing either a branch or a leaf node in the layout grid.


ts
type MenuItemAction = () => void;

Defined in: components/contextMenuTypes.ts:9

Returns

void


MessageFormatter

ts
type MessageFormatter = (msg) => string;

Defined in: components/WindowManagerContext.tsx:26

Function type interface responsible for resolving localizable messages to flat strings.

Parameters

ParameterType
msgContextMenuPredefinedMessage

Returns

string


PanelInstanceId

ts
type PanelInstanceId = string;

Defined in: components/PanelProviderContext.tsx:7

Unique string identifier for panel/modal instances.


PanelTitle

ts
type PanelTitle = string | PanelTitleDescriptor;

Defined in: components/PanelProviderContext.tsx:22

Union type representing either a plain string or a localizable title descriptor.


PredefinedMessageKey

ts
type PredefinedMessageKey = keyof typeof defaultPredefinedMessages;

Defined in: components/predefinedMessages.ts:47

Union of every key in defaultPredefinedMessages.

Import this type in your i18n message tables to get a compile-time guarantee that all keys are present and no typos exist:

import type { PredefinedMessageKey } from 'react-dockable-desktop';

const myMessages: Record<PredefinedMessageKey, string> = { ... };


SplitDirection

ts
type SplitDirection = "left" | "right" | "top" | "bottom";

Defined in: components/WindowManagerContext.tsx:32

The four cardinal directions a panel can be docked relative to another.


SplitOrientation

ts
type SplitOrientation = "horizontal" | "vertical";

Defined in: components/WindowManagerContext.tsx:29

Orientation modifier indicating split directions.


TaskbarVisibility

ts
type TaskbarVisibility = "always" | "compact" | "autohide";

Defined in: components/WindowManager.tsx:807

Controls when the minimized-panel taskbar is visible.


ToastPosition

ts
type ToastPosition = "top-left" | "top-right" | "bottom-left" | "bottom-right";

Defined in: components/Toast.tsx:10

Corner position of the <ToastContainer> relative to the viewport.


ToastType

ts
type ToastType = "info" | "success" | "warning" | "error";

Defined in: components/Toast.tsx:7

Visual type of a toast notification. Determines the icon and accent color.


ToolbarGroupEntry

ts
type ToolbarGroupEntry = 
  | ToolbarGroupSubItem
  | {
  type: "separator";
};

Defined in: components/Toolbar.tsx:81

An entry inside a group flyout — either a sub-item or a separator.


ToolbarItem

ts
type ToolbarItem = 
  | ToolbarActionItem
  | ToolbarRadioItem
  | ToolbarToggleItem
  | ToolbarGroupItem
  | ToolbarSeparator;

Defined in: components/Toolbar.tsx:117


ToolbarPosition

ts
type ToolbarPosition = "top" | "bottom" | "left" | "right";

Defined in: components/PanelOverlay.tsx:19

Edge of a panel to which a PanelToolbar attaches.


ToolbarVariant

ts
type ToolbarVariant = "transparent" | "frosted" | "solid";

Defined in: components/PanelOverlay.tsx:289

Background style of a PanelToolbar.

Variables

ConfirmationForm

ts
const ConfirmationForm: React.FC<ConfirmationFormProps>;

Defined in: forms/ConfirmationForm.tsx:29

ConfirmationForm component renders a standard dialog content layout, allowing users to confirm actions or abort them. Exposes action callbacks.


ContextMenu

ts
const ContextMenu: React.ForwardRefExoticComponent<ContextMenuProps & React.RefAttributes<ContextMenuHandle>>;

Defined in: components/ContextMenu.tsx:208


DefaultContextMenuAdapter

ts
const DefaultContextMenuAdapter: ContextMenuAdapter;

Defined in: components/ContextMenu.tsx:442


defaultPredefinedMessages

ts
const defaultPredefinedMessages: {
  cancel: {
     defaultMessage: "Cancel";
     id: "dockable-desktop-cancel";
  };
  close: {
     defaultMessage: "Close";
     id: "dockable-desktop-close";
  };
  closeEmptyGroup: {
     defaultMessage: "Close empty split group";
     id: "dockable-desktop-closeEmptyGroup";
  };
  closePanel: {
     defaultMessage: "Close Panel";
     id: "dockable-desktop-closePanel";
  };
  closePanelTooltip: {
     defaultMessage: "Close panel";
     id: "dockable-desktop-closePanelTooltip";
  };
  closeTab: {
     defaultMessage: "Close Tab";
     id: "dockable-desktop-closeTab";
  };
  closeTooltip: {
     defaultMessage: "Close";
     id: "dockable-desktop-closeTooltip";
  };
  discardChanges: {
     defaultMessage: "Discard Changes";
     id: "dockable-desktop-discardChanges";
  };
  dockWindow: {
     defaultMessage: "Dock Window";
     id: "dockable-desktop-dockWindow";
  };
  floatWindow: {
     defaultMessage: "Float Window";
     id: "dockable-desktop-floatWindow";
  };
  maximize: {
     defaultMessage: "Maximize";
     id: "dockable-desktop-maximize";
  };
  maximizePanel: {
     defaultMessage: "Maximize Panel";
     id: "dockable-desktop-maximizePanel";
  };
  minimize: {
     defaultMessage: "Minimize";
     id: "dockable-desktop-minimize";
  };
  minimizePanel: {
     defaultMessage: "Minimize Panel";
     id: "dockable-desktop-minimizePanel";
  };
  no: {
     defaultMessage: "No";
     id: "dockable-desktop-no";
  };
  ok: {
     defaultMessage: "OK";
     id: "dockable-desktop-ok";
  };
  restorePanel: {
     defaultMessage: "Restore Panel";
     id: "dockable-desktop-restorePanel";
  };
  restoreSize: {
     defaultMessage: "Restore Size";
     id: "dockable-desktop-restoreSize";
  };
  unsavedChangesMessage: {
     defaultMessage: "\"{title}\" has unsaved changes. Do you want to discard your changes and close?";
     id: "dockable-desktop-unsavedChangesMessage";
  };
  unsavedChangesTitle: {
     defaultMessage: "Unsaved Changes";
     id: "dockable-desktop-unsavedChangesTitle";
  };
  yes: {
     defaultMessage: "Yes";
     id: "dockable-desktop-yes";
  };
};

Defined in: components/predefinedMessages.ts:13

Type Declaration

NameTypeDefault valueDefined in
cancel{ defaultMessage: "Cancel"; id: "dockable-desktop-cancel"; }-components/predefinedMessages.ts:29
cancel.defaultMessage"Cancel"'Cancel'components/predefinedMessages.ts:29
cancel.id"dockable-desktop-cancel"'dockable-desktop-cancel'components/predefinedMessages.ts:29
close{ defaultMessage: "Close"; id: "dockable-desktop-close"; }-components/predefinedMessages.ts:24
close.defaultMessage"Close"'Close'components/predefinedMessages.ts:24
close.id"dockable-desktop-close"'dockable-desktop-close'components/predefinedMessages.ts:24
closeEmptyGroup{ defaultMessage: "Close empty split group"; id: "dockable-desktop-closeEmptyGroup"; }-components/predefinedMessages.ts:25
closeEmptyGroup.defaultMessage"Close empty split group"'Close empty split group'components/predefinedMessages.ts:25
closeEmptyGroup.id"dockable-desktop-closeEmptyGroup"'dockable-desktop-closeEmptyGroup'components/predefinedMessages.ts:25
closePanel{ defaultMessage: "Close Panel"; id: "dockable-desktop-closePanel"; }-components/predefinedMessages.ts:19
closePanel.defaultMessage"Close Panel"'Close Panel'components/predefinedMessages.ts:19
closePanel.id"dockable-desktop-closePanel"'dockable-desktop-closePanel'components/predefinedMessages.ts:19
closePanelTooltip{ defaultMessage: "Close panel"; id: "dockable-desktop-closePanelTooltip"; }-components/predefinedMessages.ts:33
closePanelTooltip.defaultMessage"Close panel"'Close panel'components/predefinedMessages.ts:33
closePanelTooltip.id"dockable-desktop-closePanelTooltip"'dockable-desktop-closePanelTooltip'components/predefinedMessages.ts:33
closeTab{ defaultMessage: "Close Tab"; id: "dockable-desktop-closeTab"; }-components/predefinedMessages.ts:16
closeTab.defaultMessage"Close Tab"'Close Tab'components/predefinedMessages.ts:16
closeTab.id"dockable-desktop-closeTab"'dockable-desktop-closeTab'components/predefinedMessages.ts:16
closeTooltip{ defaultMessage: "Close"; id: "dockable-desktop-closeTooltip"; }-components/predefinedMessages.ts:34
closeTooltip.defaultMessage"Close"'Close'components/predefinedMessages.ts:34
closeTooltip.id"dockable-desktop-closeTooltip"'dockable-desktop-closeTooltip'components/predefinedMessages.ts:34
discardChanges{ defaultMessage: "Discard Changes"; id: "dockable-desktop-discardChanges"; }-components/predefinedMessages.ts:28
discardChanges.defaultMessage"Discard Changes"'Discard Changes'components/predefinedMessages.ts:28
discardChanges.id"dockable-desktop-discardChanges"'dockable-desktop-discardChanges'components/predefinedMessages.ts:28
dockWindow{ defaultMessage: "Dock Window"; id: "dockable-desktop-dockWindow"; }-components/predefinedMessages.ts:20
dockWindow.defaultMessage"Dock Window"'Dock Window'components/predefinedMessages.ts:20
dockWindow.id"dockable-desktop-dockWindow"'dockable-desktop-dockWindow'components/predefinedMessages.ts:20
floatWindow{ defaultMessage: "Float Window"; id: "dockable-desktop-floatWindow"; }-components/predefinedMessages.ts:14
floatWindow.defaultMessage"Float Window"'Float Window'components/predefinedMessages.ts:14
floatWindow.id"dockable-desktop-floatWindow"'dockable-desktop-floatWindow'components/predefinedMessages.ts:14
maximize{ defaultMessage: "Maximize"; id: "dockable-desktop-maximize"; }-components/predefinedMessages.ts:22
maximize.defaultMessage"Maximize"'Maximize'components/predefinedMessages.ts:22
maximize.id"dockable-desktop-maximize"'dockable-desktop-maximize'components/predefinedMessages.ts:22
maximizePanel{ defaultMessage: "Maximize Panel"; id: "dockable-desktop-maximizePanel"; }-components/predefinedMessages.ts:18
maximizePanel.defaultMessage"Maximize Panel"'Maximize Panel'components/predefinedMessages.ts:18
maximizePanel.id"dockable-desktop-maximizePanel"'dockable-desktop-maximizePanel'components/predefinedMessages.ts:18
minimize{ defaultMessage: "Minimize"; id: "dockable-desktop-minimize"; }-components/predefinedMessages.ts:21
minimize.defaultMessage"Minimize"'Minimize'components/predefinedMessages.ts:21
minimize.id"dockable-desktop-minimize"'dockable-desktop-minimize'components/predefinedMessages.ts:21
minimizePanel{ defaultMessage: "Minimize Panel"; id: "dockable-desktop-minimizePanel"; }-components/predefinedMessages.ts:15
minimizePanel.defaultMessage"Minimize Panel"'Minimize Panel'components/predefinedMessages.ts:15
minimizePanel.id"dockable-desktop-minimizePanel"'dockable-desktop-minimizePanel'components/predefinedMessages.ts:15
no{ defaultMessage: "No"; id: "dockable-desktop-no"; }-components/predefinedMessages.ts:31
no.defaultMessage"No"'No'components/predefinedMessages.ts:31
no.id"dockable-desktop-no"'dockable-desktop-no'components/predefinedMessages.ts:31
ok{ defaultMessage: "OK"; id: "dockable-desktop-ok"; }-components/predefinedMessages.ts:32
ok.defaultMessage"OK"'OK'components/predefinedMessages.ts:32
ok.id"dockable-desktop-ok"'dockable-desktop-ok'components/predefinedMessages.ts:32
restorePanel{ defaultMessage: "Restore Panel"; id: "dockable-desktop-restorePanel"; }-components/predefinedMessages.ts:17
restorePanel.defaultMessage"Restore Panel"'Restore Panel'components/predefinedMessages.ts:17
restorePanel.id"dockable-desktop-restorePanel"'dockable-desktop-restorePanel'components/predefinedMessages.ts:17
restoreSize{ defaultMessage: "Restore Size"; id: "dockable-desktop-restoreSize"; }-components/predefinedMessages.ts:23
restoreSize.defaultMessage"Restore Size"'Restore Size'components/predefinedMessages.ts:23
restoreSize.id"dockable-desktop-restoreSize"'dockable-desktop-restoreSize'components/predefinedMessages.ts:23
unsavedChangesMessage{ defaultMessage: ""{title}" has unsaved changes. Do you want to discard your changes and close?"; id: "dockable-desktop-unsavedChangesMessage"; }-components/predefinedMessages.ts:27
unsavedChangesMessage.defaultMessage""{title}" has unsaved changes. Do you want to discard your changes and close?"'"{title}" has unsaved changes. Do you want to discard your changes and close?'components/predefinedMessages.ts:27
unsavedChangesMessage.id"dockable-desktop-unsavedChangesMessage"'dockable-desktop-unsavedChangesMessage'components/predefinedMessages.ts:27
unsavedChangesTitle{ defaultMessage: "Unsaved Changes"; id: "dockable-desktop-unsavedChangesTitle"; }-components/predefinedMessages.ts:26
unsavedChangesTitle.defaultMessage"Unsaved Changes"'Unsaved Changes'components/predefinedMessages.ts:26
unsavedChangesTitle.id"dockable-desktop-unsavedChangesTitle"'dockable-desktop-unsavedChangesTitle'components/predefinedMessages.ts:26
yes{ defaultMessage: "Yes"; id: "dockable-desktop-yes"; }-components/predefinedMessages.ts:30
yes.defaultMessage"Yes"'Yes'components/predefinedMessages.ts:30
yes.id"dockable-desktop-yes"'dockable-desktop-yes'components/predefinedMessages.ts:30

File

predefinedMessages.ts

Description

Provides the default localizable message catalogs and translation keys utilized by Dockable Desktop's context menus, headers, and tooltips.

Each value's id is the react-intl message ID that the consumer should define in their IntlProvider messages table. The defaultMessage is used as a fallback when no external formatter is provided.

Pass a partial or full override to <WindowManagerProvider predefinedMessages={…} /> to customise labels without replacing the whole table.


DockableDesktopProvider

ts
const DockableDesktopProvider: React.FC<WindowManagerProviderProps>;

Defined in: components/DockableDesktopProvider.tsx:28

Composite provider that wraps both WindowManagerProvider and PanelProvider in the correct order. Drop-in replacement for manually nesting both providers.

WindowManagerProvider and PanelProvider remain independently exported for cases that require custom nesting or separate configuration.

Example

tsx
<DockableDesktopProvider client={workspace}>
  <WindowManager />
  <ModalStackRenderer />
</DockableDesktopProvider>

FormContainerContext

ts
const FormContainerContext: Context<FormContainerContract>;

Defined in: components/FormContainerContext.ts:97

Context that supplies the FormContainerContract to panels inside the Window Manager.


FormContainerProvider

ts
const FormContainerProvider: Provider<FormContainerContract> = FormContainerContext.Provider;

Defined in: components/FormContainerContext.ts:98


LeftPanelRenderer

ts
const LeftPanelRenderer: React.FC<SidePanelRendererProps>;

Defined in: components/SidePanelRenderer.tsx:180

LeftPanelRenderer component renders ONLY the left side drawer if it is currently active.


ModalStackRenderer

ts
const ModalStackRenderer: React.FC;

Defined in: components/ModalStackRenderer.tsx:151

ModalStackRenderer component acts as the global container rendering all active stacked modal windows in the workspace.


PanelProvider

ts
const PanelProvider: React.FC<{
  children: ReactNode;
}>;

Defined in: components/PanelProviderContext.tsx:120

PanelProvider component manages the state and action handlers for drawers (left/right) and active stacked modal overlays.


PanelRegistry

ts
const PanelRegistry: PanelRegistryClass;

Defined in: components/PanelRegistry.ts:76

Global singleton instance of the Panel Registry.


RightPanelRenderer

ts
const RightPanelRenderer: React.FC<SidePanelRendererProps>;

Defined in: components/SidePanelRenderer.tsx:189

RightPanelRenderer component renders ONLY the right side drawer if it is currently active.


ts
const Sidebar: React.ForwardRefExoticComponent<SidebarProps & React.RefAttributes<SidebarHandle>>;

Defined in: components/Sidebar.tsx:282


SidePanelRenderer

ts
const SidePanelRenderer: React.FC<SidePanelRendererProps>;

Defined in: components/SidePanelRenderer.tsx:167

SidePanelRenderer component acts as the global container rendering both left and right side drawers if they are currently active.


toast

ts
const toast: ToastFunction;

Defined in: components/Toast.tsx:186

Imperative notification singleton. Call from anywhere — inside or outside React. Mount <ToastContainer> once at your app root to activate the renderer.

Example

ts
toast.success('File saved.');
toast.error('Upload failed.', { duration: 0 }); // sticky
toast.promise(saveFile(), { pending: 'Saving…', success: 'Saved!', error: 'Failed.' });

Toolbar

ts
const Toolbar: React.ForwardRefExoticComponent<ToolbarProps & React.RefAttributes<ToolbarHandle>>;

Defined in: components/Toolbar.tsx:403


ToolbarProvider

ts
const ToolbarProvider: React.FC<{
  children: React.ReactNode;
}>;

Defined in: components/ToolbarContext.tsx:24


WindowManager

ts
const WindowManager: React.FC<WindowManagerProps>;

Defined in: components/WindowManager.tsx:827

File

index.ts

Description

Core entry point for react-dockable-desktop. Exports public window manager components, contexts, hooks, type definitions, sidebar layouts, and overlay renderers.


WindowManagerProvider

ts
const WindowManagerProvider: React.FC<WindowManagerProviderProps>;

Defined in: components/WindowManagerContext.tsx:515

Released under the MIT License.