Skip to content

react-dockable-desktop


react-dockable-desktop

Hooks

WindowActions

Defined in: components/WindowManagerContext.tsx:223

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:395
closePanel(id) => voidCloses a panel immediately, bypassing dirty-state close guards. For guarded close, use requestClosePanel.components/WindowManagerContext.tsx:258
dockPanel(id, targetLeafId?) => voidReturns a floating window to a docked grid tab group.components/WindowManagerContext.tsx:281
dockPanelToGroup(id, targetLeafId, position) => voidSplits an existing leaf group and docks a panel to the given side.components/WindowManagerContext.tsx:383
dockPanelToWorkspaceEdge(id, position) => voidDocks a floating panel to a workspace edge, creating a full-width or full-height column/row.components/WindowManagerContext.tsx:450
findPanelId(component, dedupeKey) => string | nullFinds the ID of an already-open panel of the given component with a matching dedupeKey (set via openPanel's dedupeKey option). Uses a synchronous stateRef read — safe to call outside of render.components/WindowManagerContext.tsx:340
floatPanel(id, rect?, anchor?) => voidDetaches a docked panel, converting it to a resizable floating window.components/WindowManagerContext.tsx:275
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:310
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:331
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:325
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:357
maximizePanel(id) => voidMaximizes a floating window to cover the entire workspace viewport.components/WindowManagerContext.tsx:286
minimizePanel(id) => voidMinimizes a panel to the bottom taskbar dock, preserving its layout position.components/WindowManagerContext.tsx:263
movePanelOrder(panelId, targetLeafId, targetIndex) => voidReorders a panel's tab index within a docked leaf group.components/WindowManagerContext.tsx:390
openPanel<P>(id, component, options?) => voidOpens a registered panel into the workspace. If the panel ID is already open, the panel is focused instead of duplicated. Becomes state.activePanelId by default — pass options.focus: false to open without stealing focus from whatever is currently active. Default true Example // Open floating and pin to the top-right corner: actions.openPanel('layers', 'layertree', { initialTarget: 'floating', anchor: 'top-right' }); // Open in the background without stealing focus: actions.openPanel('prefetch', 'report', { focus: false }); // Open with per-instance data, deduped by document path: actions.openPanel(crypto.randomUUID(), 'document', { props: { path: '/notes/todo.md' }, dedupeKey: '/notes/todo.md', });components/WindowManagerContext.tsx:252
publish(event, data) => voidPublishes an event to the inter-panel pub/sub event bus.components/WindowManagerContext.tsx:363
registerCloseGuard(id, guard) => voidRegisters a close guard that can intercept and cancel panel close requests.components/WindowManagerContext.tsx:401
registerStateProvider(id, provider) => voidRegisters a callback reporting a docked/floating panel's current restorable state, pulled fresh every saveLayout() call — for panels whose props alone can't capture state they accumulate after opening (scroll position, an in-progress edit, a view-mode toggle). A panel that registers nothing keeps its static open-time props (or none). The returned value goes through the same isSerializable check as static props, re-evaluated on every save — a provider-backed panel's serializability can flip over its lifetime.components/WindowManagerContext.tsx:418
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:444
restorePanel(id) => voidRestores a minimized panel back to its last docked or floating position.components/WindowManagerContext.tsx:268
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:350
setDirection(dir) => voidOverrides the workspace layout direction.components/WindowManagerContext.tsx:455
setDraggedPanelId(id) => voidInternal Stores reference to the active tab ID being dragged.components/WindowManagerContext.tsx:376
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:431
showContextMenu(options) => voidImperatively shows the workspace context menu at the given position. Delegates to the active ContextMenuProvider, so custom adapters and externally-placed providers are respected automatically.components/WindowManagerContext.tsx:461
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:374
unregisterCloseGuard(id) => voidRemoves a previously registered close guard.components/WindowManagerContext.tsx:406
unregisterStateProvider(id) => voidRemoves a previously registered state provider.components/WindowManagerContext.tsx:423
updateFloatingPosition(id, updates) => voidUpdates the position or size of a floating window.components/WindowManagerContext.tsx:298
updatePanelTitle(id, title) => voidUpdates the display title of an open panel.components/WindowManagerContext.tsx:437
updateSplitSizes(path, sizes) => voidResizes the flex split proportions of a branch node's children.components/WindowManagerContext.tsx:292

usePanelId()

ts
function usePanelId(): string;

Defined in: components/WindowManagerContext.tsx:1926

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:526

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:1851

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:117

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:194

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:146

Parameters
ParameterType
configWorkspaceClientConfig
Returns

WorkspaceClient<TUserEvents>

Methods

_connect()
ts
_connect(actions): void;

Defined in: WorkspaceClient.ts:168

Internal

Called by WindowManagerProvider after mount.

Parameters
ParameterType
actionsWindowActions
Returns

void

_disconnect()
ts
_disconnect(): void;

Defined in: WorkspaceClient.ts:185

Internal

Called by WindowManagerProvider on unmount.

Returns

void

closeLeafGroup()
ts
closeLeafGroup(leafId): void;

Defined in: WorkspaceClient.ts:322

Closes an entire leaf group (all of its tabs) at once.

Parameters
ParameterType
leafIdstring
Returns

void

closePanel()
ts
closePanel(id): void;

Defined in: WorkspaceClient.ts:253

Parameters
ParameterType
idstring
Returns

void

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

Defined in: WorkspaceClient.ts:263

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

void

dockPanelToGroup()
ts
dockPanelToGroup(
   id, 
   targetLeafId, 
   position): void;

Defined in: WorkspaceClient.ts:312

Docks a panel into an existing leaf group at the given drop position.

Parameters
ParameterType
idstring
targetLeafIdstring
positionDropPosition
Returns

void

dockPanelToWorkspaceEdge()
ts
dockPanelToWorkspaceEdge(id, position): void;

Defined in: WorkspaceClient.ts:367

Docks a panel to one of the workspace's outer edges.

Parameters
ParameterType
idstring
positionSplitDirection
Returns

void

findPanelId()
ts
findPanelId(component, dedupeKey): string | null;

Defined in: WorkspaceClient.ts:284

Finds an already-open panel of the given component with a matching dedupeKey (set via openPanel's dedupeKey option). Returns null if none is open.

Parameters
ParameterType
componentstring
dedupeKeystring
Returns

string | null

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

Defined in: WorkspaceClient.ts:259

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:274

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:280

Returns the IDs of all currently open panels.

Returns

string[]

isOpen()
ts
isOpen(id): boolean;

Defined in: WorkspaceClient.ts:277

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:290

Parameters
ParameterType
jsonstring
Returns

boolean

maximizePanel()
ts
maximizePanel(id): void;

Defined in: WorkspaceClient.ts:267

Parameters
ParameterType
idstring
Returns

void

minimizePanel()
ts
minimizePanel(id): void;

Defined in: WorkspaceClient.ts:255

Parameters
ParameterType
idstring
Returns

void

movePanelOrder()
ts
movePanelOrder(
   panelId, 
   targetLeafId, 
   targetIndex): void;

Defined in: WorkspaceClient.ts:317

Reorders a panel's tab within its leaf group.

Parameters
ParameterType
panelIdstring
targetLeafIdstring
targetIndexnumber
Returns

void

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

Defined in: WorkspaceClient.ts:423

Subscribe to the coalesced layout-change signal — see BuiltInPanelEvents's 'layout:changed' doc for exactly what it covers (and doesn't).

Parameters
ParameterType
callback() => void
Returns

() => void

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

Defined in: WorkspaceClient.ts:401

Subscribe to panel close events.

Parameters
ParameterType
callback(id) => void
Returns

() => void

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

Defined in: WorkspaceClient.ts:408

Subscribe to panel minimize events.

Parameters
ParameterType
callback(id) => void
Returns

() => void

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

Defined in: WorkspaceClient.ts:393

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:415

Subscribe to panel restore events.

Parameters
ParameterType
callback(id) => void
Returns

() => void

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

Defined in: WorkspaceClient.ts:430

Subscribe to notification that a saveLayout() call excluded one or more panels because their current props weren't serializable — see BuiltInPanelEvents's 'layout:panels-excluded' doc.

Parameters
ParameterType
callback(panels) => void
Returns

() => void

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

Defined in: WorkspaceClient.ts:237

Parameters
ParameterType
...args[string, string, OpenPanelOptions<object>]
Returns

void

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

Defined in: WorkspaceClient.ts:376

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

void

registerCloseGuard()
ts
registerCloseGuard(id, guard): void;

Defined in: WorkspaceClient.ts:325

Registers a guard that can veto closing the given panel.

Parameters
ParameterType
idstring
guard() => boolean | Promise<boolean>
Returns

void

registerStateProvider()
ts
registerStateProvider(id, provider): void;

Defined in: WorkspaceClient.ts:335

Registers a callback reporting a panel's current restorable state, pulled fresh on every saveLayout() call — see BuiltInPanelEvents's 'layout:panels-excluded' doc and FormContainerContract.registerStateProvider.

Parameters
ParameterType
idstring
provider() => unknown
Returns

void

requestClosePanel()
ts
requestClosePanel(id, options?): Promise<void>;

Defined in: WorkspaceClient.ts:360

Requests that a panel close, honoring its dirty flag and any registered close guard. Resolves once the close (or user cancellation) has been resolved.

Parameters
ParameterType
idstring
options?{ force?: boolean; onConfirm?: (opts?) => Promise<boolean>; }
options.force?boolean
options.onConfirm?(opts?) => Promise<boolean>
Returns

Promise<void>

Remarks

If called before the provider mounts, the request is queued and this returns an already-resolved promise immediately — the caller can't observe the eventual outcome of a queued call, only that the request was accepted.

restorePanel()
ts
restorePanel(id): void;

Defined in: WorkspaceClient.ts:257

Parameters
ParameterType
idstring
Returns

void

saveLayout()
ts
saveLayout(): string;

Defined in: WorkspaceClient.ts:288

Returns

string

setDirection()
ts
setDirection(dir): void;

Defined in: WorkspaceClient.ts:296

Parameters
ParameterType
dir"rtl" | "ltr"
Returns

void

setDraggedPanelId()
ts
setDraggedPanelId(id): void;

Defined in: WorkspaceClient.ts:309

Internal

Drives the drag-in-progress visual state; normally only the library's own drag UI calls this.

Parameters
ParameterType
idstring | null
Returns

void

setPanelDirty()
ts
setPanelDirty(
   id, 
   dirty, 
   options?): void;

Defined in: WorkspaceClient.ts:343

Sets/clears a panel's dirty (unsaved changes) flag.

Parameters
ParameterType
idstring
dirtyboolean
options?DirtyStateOptions
Returns

void

showContextMenu()
ts
showContextMenu(options): void;

Defined in: WorkspaceClient.ts:372

Shows a context menu using the app's configured ContextMenuAdapter.

Parameters
ParameterType
optionsShowContextMenuOptions
Returns

void

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

Defined in: WorkspaceClient.ts:383

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

() => void

unregisterCloseGuard()
ts
unregisterCloseGuard(id): void;

Defined in: WorkspaceClient.ts:330

Removes a previously registered close guard.

Parameters
ParameterType
idstring
Returns

void

unregisterStateProvider()
ts
unregisterStateProvider(id): void;

Defined in: WorkspaceClient.ts:340

Removes a previously registered state provider.

Parameters
ParameterType
idstring
Returns

void

updateFloatingPosition()
ts
updateFloatingPosition(id, updates): void;

Defined in: WorkspaceClient.ts:304

Updates position/size/anchor of a floating panel.

Parameters
ParameterType
idstring
updatesPartial<Pick<FloatingWindow, "x" | "y" | "width" | "height" | "anchor">>
Returns

void

updatePanelTitle()
ts
updatePanelTitle(id, title): void;

Defined in: WorkspaceClient.ts:348

Updates a panel's displayed title.

Parameters
ParameterType
idstring
title| string | ContextMenuPredefinedMessage
Returns

void

updateSplitSizes()
ts
updateSplitSizes(path, sizes): void;

Defined in: WorkspaceClient.ts:299

Updates the split-size fractions at the given grid path.

Parameters
ParameterType
pathnumber[]
sizesnumber[]
Returns

void

Properties

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

Functions

computeResizedRect()

ts
function computeResizedRect(
   dir, 
   dx, 
   dy, 
   start, 
   constraints): ResizeRect;

Defined in: components/dragResize.ts:96

Pure function computing the new rect for an 8-directional resize handle drag.

maxW/maxH and minX/minY are independent, direction-scoped constraints rather than one "container bound" — a resize toward the fixed edge (e/s) is naturally bounded by a maximum dimension, while a resize toward the moving edge (w/n) is naturally bounded by a minimum position, and the two calling sites this was extracted from need different subsets of these (see WindowManager.tsx's startResize, which omits all four and lets a window grow unbounded and be dragged fully off-screen, vs. PanelOverlay.tsx's handleResizePointerDown, which supplies all four to keep windows within their container).

Parameters

ParameterType
dirResizeDir
dxnumber
dynumber
startResizeRect
constraintsResizeConstraints

Returns

ResizeRect


formatLabel()

ts
function formatLabel(label, formatter): string;

Defined in: components/WindowManagerContext.tsx:1886

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

Parameters

ParameterType
label| string | ContextMenuPredefinedMessage | undefined
formatterMessageFormatter

Returns

string


isSerializable()

ts
function isSerializable(value): boolean;

Defined in: components/serializable.ts:21

Recursively checks whether a value can round-trip through JSON.stringify/JSON.parse without silently losing information.

Deliberately not a JSON.stringify try/catch — that call doesn't throw for the actual failure case this guards against: a function-valued property is simply dropped by JSON.stringify, not rejected. This walks the value tree instead, returning false as soon as it finds a function, symbol, undefined, React element, or any non-plain object (a class instance, Map, Set, RegExp, etc.).

Date is treated as an explicit exception — serializable-enough, matching JSON.stringify's own behavior — even though it doesn't round-trip back to a Date instance on parse. That's a smaller, more tolerable gotcha than a silently-vanishing function, so it's documented rather than treated as a disqualifying case.

Used to decide whether a docked/floating panel's props can be included in WorkspaceClient.saveLayout()'s output — see PanelInfo.serializable.

Parameters

ParameterType
valueunknown

Returns

boolean


PanelFloatingWindow()

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

Defined in: components/PanelOverlay.tsx:701

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:120

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:315

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:470

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:456

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

Returns

ReactElement


sidebarSectionToTab()

ts
function sidebarSectionToTab(section, fallbackIcon?): SidebarTab;

Defined in: components/PanelContributionContext.tsx:151

Converts a contributed sidebar section into a SidebarTab for <Sidebar tabs={...}>. SidebarTab.icon is required, so supply fallbackIcon for sections that omit one. eagerMount/preserveState have no contribution-side equivalent — a contribution only exists while its owning panel is mounted and active, so both are left unset.

Parameters

ParameterTypeDefault value
sectionPanelSidebarSectionundefined
fallbackIconReactNodenull

Returns

SidebarTab


startPointerDrag()

ts
function startPointerDrag<TStart>(config): void;

Defined in: components/dragResize.ts:36

Starts a pointer-capture-based drag: captures the pointer on element, tracks movement via listeners scoped to that element's own lifetime (not window), and cleans up automatically on release or cancel.

Type Parameters

Type Parameter
TStart

Parameters

ParameterType
configPointerDragConfig<TStart>

Returns

void


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:402

Icon button for use inside a PanelToolbar.

Parameters

ParameterType
__namedParametersToolbarButtonProps

Returns

ReactElement


ToolbarCenter()

ts
function ToolbarCenter(__namedParameters): ReactElement;

Defined in: components/PanelOverlay.tsx:477

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:522

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:463

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:436

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

Parameters

ParameterType
__namedParametersToolbarToggleProps

Returns

ReactElement


useActivePanelContribution()

ts
function useActivePanelContribution(): PanelContribution | null;

Defined in: components/PanelContributionContext.tsx:130

Returns whatever the currently active panel (state.activePanelId) has published via usePanelContribution(), or null if no panel is active or the active panel hasn't contributed anything. Intended for the app shell to merge into its own <Toolbar items={...}> / <Sidebar tabs={...}> calls.

Returns

PanelContribution | null

Throws

Error if used outside of a PanelContributionProvider.


useColorScheme()

ts
function useColorScheme(): "dark" | "light";

Defined in: hooks/useColorScheme.ts:12

Reactively reads the workspace's current data-color-scheme attribute (set on document.documentElement by <WindowManager />), returning 'dark' or 'light' and re-rendering whenever it changes.

Useful for panel content that needs to react to the same scheme the workspace itself is using — e.g. swapping a map's tile layer or an embedded editor's theme to match.

Returns

"dark" | "light"


useFormatMessage()

ts
function useFormatMessage(): MessageFormatter;

Defined in: components/WindowManagerContext.tsx:1870

React hook to retrieve the active i18n formatter.

Returns

MessageFormatter


useFormContainer()

ts
function useFormContainer(): FormContainerContract;

Defined in: components/FormContainerContext.ts:118

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


useMergedSidebarTabs()

ts
function useMergedSidebarTabs(staticTabs, fallbackIcon?): SidebarTab[];

Defined in: components/PanelContributionContext.tsx:180

Convenience wrapper around useActivePanelContribution() for the common case: append the active panel's contributed sidebar sections (via sidebarSectionToTab) to a static tab list, as dynamic tabs that appear only while their panel is active. Returns staticTabs unchanged when there's nothing to add.

Parameters

ParameterTypeDefault value
staticTabsSidebarTab[]undefined
fallbackIconReactNodenull

Returns

SidebarTab[]


useMergedToolbarItems()

ts
function useMergedToolbarItems(staticItems): ToolbarItem[];

Defined in: components/PanelContributionContext.tsx:167

Convenience wrapper around useActivePanelContribution() for the common case: append the active panel's contributed toolbar items (behind a separator) to a static list. Returns staticItems unchanged when there's nothing to add. For manual control (a different merge position, no separator, etc.), call useActivePanelContribution() directly instead.

Parameters

ParameterType
staticItemsToolbarItem[]

Returns

ToolbarItem[]


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:1898

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:1948

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)} />;
}

usePanelContribution()

ts
function usePanelContribution(contribution): void;

Defined in: components/PanelContributionContext.tsx:104

Publish this panel's toolbar items and/or sidebar sections. Call on every render — republishes automatically whenever contribution changes, and is cleared when the panel unmounts. Memoize the object (and its array/callback contents, e.g. with useMemo/useCallback) to avoid republishing on every unrelated re-render.

Contributions are only ever surfaced while this panel is state.activePanelId — see useActivePanelContribution().

Parameters

ParameterType
contributionPanelContribution

Returns

void

Throws

Error if used outside of a PanelContributionProvider.

Example

ts
function MapPanel() {
  const [controller, setController] = useState<'pan' | 'draw' | 'measure'>('pan');
  usePanelContribution({
    toolbarItems: (['pan', 'draw', 'measure'] as const).map(id => ({
      type: 'toggle', id, label: id, icon: icons[id],
      active: controller === id, onToggle: () => setController(id),
    })),
    sidebarSections: [{ id: 'layers', label: 'Layers', content: <LayerList /> }],
  });
  // ...
}

usePanelFloatingWindow()

ts
function usePanelFloatingWindow(): UsePanelFloatingWindowReturn;

Defined in: components/PanelOverlay.tsx:995

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:1033

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' });

usePanelSize()

ts
function usePanelSize(): 
  | {
  height: number;
  width: number;
}
  | null;

Defined in: components/FormContainerContext.ts:129

Reactive alternative to calling FormContainerContract.getDimensions yourself. Returns the panel's current { width, height }, or null before it has been laid out, and re-renders whenever the panel's rendered box changes — including resizes caused by the workspace itself (a grid split being dragged, docking, floating, or tab activation), not just resizes of an element the panel created.

Returns

| { height: number; width: number; } | null


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:1906

React hook to fetch the localizable predefined message map catalog.

Returns

Record<PredefinedMessageKey, ContextMenuPredefinedMessage>


useShowContextMenu()

ts
function useShowContextMenu(): (options) => void;

Defined in: components/ContextMenu.tsx:488

Returns

(options) => void


useSidebar()

ts
function useSidebar(): SidebarContextValue;

Defined in: components/Sidebar.tsx:703

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

Returns

SidebarContextValue

Throws

Error if used outside of a Sidebar.


useSidebarTab()

ts
function useSidebarTab(): SidebarTabContextValue;

Defined in: components/Sidebar.tsx:715

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

Returns

SidebarTabContextValue

Throws

Error if used outside of a Sidebar tab's renderContent tree.


useStyleClasses()

ts
function useStyleClasses(): StyleClasses;

Defined in: components/WindowManagerContext.tsx:506

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

ToolbarContextValue

Throws

Error if used outside of a DockableDesktopProvider.


useWindowManagerState()

Call Signature

ts
function useWindowManagerState(): WindowState;

Defined in: components/WindowManagerContext.tsx:1809

Returns

WindowState

Call Signature

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

Defined in: components/WindowManagerContext.tsx:1810

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

T

Interfaces

BuiltInPanelEvents

Defined in: WorkspaceClient.ts:16

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

Properties

PropertyTypeDescriptionDefined in
layout:changedRecord<string, never>Fires whenever something saveLayout() would capture changes — open/close/minimize/restore, and an openPanel dedupeKey redirect. Coalesces those into one signal for autosave-style consumers, so they don't need to subscribe to four separate events. Does not cover a registerStateProvider callback's return value changing on its own — that's a pull, there's no way to observe it changing without the panel separately notifying — nor resize/split-ratio drag/dock-rearrange, which have no hooks yet.WorkspaceClient.ts:29
layout:panels-excluded{ panels: { component: string; id: string; }[]; }Fires from inside saveLayout() itself, only when that specific call excluded at least one panel (a panel whose current props — static or from a registerStateProvider — failed isSerializable). A passive PanelInfo.serializable flag alone isn't enough for this: nobody may be polling it at the exact moment a save happens and something silently drops out (e.g. a floating window rendering data from a live class instance). This is deliberately just a signal, not a UI opinion — decide for yourself whether that becomes a toast, a console warning, or nothing.WorkspaceClient.ts:39
layout:panels-excluded.panels{ component: string; id: string; }[]-WorkspaceClient.ts:39
panel:closed{ id: string; }-WorkspaceClient.ts:18
panel:closed.idstring-WorkspaceClient.ts:18
panel:minimized{ id: string; }-WorkspaceClient.ts:19
panel:minimized.idstring-WorkspaceClient.ts:19
panel:opened{ component: string; id: string; }-WorkspaceClient.ts:17
panel:opened.componentstring-WorkspaceClient.ts:17
panel:opened.idstring-WorkspaceClient.ts:17
panel:restored{ id: string; }-WorkspaceClient.ts:20
panel:restored.idstring-WorkspaceClient.ts:20

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:17

Structure representing localizable message descriptors used in context menus.

Properties

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

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

DockableDesktopProviderProps

Defined in: components/DockableDesktopProvider.tsx:14

Props for <DockableDesktopProvider>. Extends WindowManagerProviderProps with workspace-level context menu configuration.

Extends

Properties

PropertyTypeDescriptionInherited fromDefined in
childrenReactNode-WindowManagerProviderProps.childrencomponents/WindowManagerContext.tsx:620
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.WindowManagerProviderProps.clientcomponents/WindowManagerContext.tsx:623
contextMenuAdapter?ContextMenuAdapterContext menu adapter for the workspace-level ContextMenuProvider. Defaults to DefaultContextMenuAdapter. Ignored if a <ContextMenuProvider> already exists above <DockableDesktopProvider> in the tree.-components/DockableDesktopProvider.tsx:20
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'WindowManagerProviderProps.dircomponents/WindowManagerContext.tsx:632
formatMessage?MessageFormatterCustom i18n formatter. Receives a { id, defaultMessage } descriptor and returns the translated string. When omitted, defaultMessage is used as-is.WindowManagerProviderProps.formatMessagecomponents/WindowManagerContext.tsx:626
modalBodyClass?stringCSS class applied to the inner content area of every modal overlay.WindowManagerProviderProps.modalBodyClasscomponents/WindowManagerContext.tsx:636
modalClass?stringCSS class applied to the outer wrapper element of every modal overlay.WindowManagerProviderProps.modalClasscomponents/WindowManagerContext.tsx:634
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.WindowManagerProviderProps.predefinedMessagescomponents/WindowManagerContext.tsx:629
sidePanelBodyClass?stringCSS class applied to the inner content area of side-panel drawers.WindowManagerProviderProps.sidePanelBodyClasscomponents/WindowManagerContext.tsx:640
sidePanelClass?stringCSS class applied to the outer wrapper of left/right side-panel drawers.WindowManagerProviderProps.sidePanelClasscomponents/WindowManagerContext.tsx:638
windowBodyClass?stringCSS class applied to the inner content area of floating panel windows.WindowManagerProviderProps.windowBodyClasscomponents/WindowManagerContext.tsx:644
windowClass?stringCSS class applied to the outer wrapper of floating panel windows.WindowManagerProviderProps.windowClasscomponents/WindowManagerContext.tsx:642
zIndexBase?numberStarting z-index for floating windows and the library's own chrome overlays (context menu, toolbar flyout, modal stack, toast, workspace edge zones), all of which shift together via --rdd-z-base. Set this above/below a host app's own modal z-index range to control stacking against it. Default 1000WindowManagerProviderProps.zIndexBasecomponents/WindowManagerContext.tsx:651

DropTarget

Defined in: components/WindowManagerContext.tsx:39

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

Properties

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

FloatingWindow

Defined in: components/WindowManagerContext.tsx:92

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:108
heightstring | numberCSS height value.components/WindowManagerContext.tsx:102
idstringUnique ID of the floating window.components/WindowManagerContext.tsx:94
maximized?booleanTrue if the window is currently maximized to full workspace bounds.components/WindowManagerContext.tsx:106
widthstring | numberCSS width value.components/WindowManagerContext.tsx:100
xstring | numberCSS left position offset (supports number/px or percentage strings).components/WindowManagerContext.tsx:96
ystring | numberCSS top position offset.components/WindowManagerContext.tsx:98
znumberRendering depth stack index layer.components/WindowManagerContext.tsx:104

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:48
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:62
instanceIdstringUnique identifier of the panel or window instance.components/FormContainerContext.ts:50
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:68
onClose?(handler) => () => voidSubscribe to the container's close event. Returns an unsubscribe function.components/FormContainerContext.ts:52
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:81
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:75
onMinimize?(handler) => () => voidSubscribe to the container's minimize event. Returns an unsubscribe function.components/FormContainerContext.ts:54
onResize?(handler) => () => voidSubscribe to the container's window resize event, returning width and height. Returns an unsubscribe function.components/FormContainerContext.ts:58
onRestore?(handler) => () => voidSubscribe to the container's restore event. Returns an unsubscribe function.components/FormContainerContext.ts:56
registerStateProvider?(getState) => () => voidRegisters a callback reporting this panel's current restorable state, pulled fresh by WorkspaceClient.saveLayout() every time it's called — for panels whose static open-time props can't capture state accumulated after opening (scroll position, an in-progress edit, a view-mode toggle). Only meaningful for docked/floating panels — left/right side panels and modals already have a complete answer to this via openLeftPanel/openRightPanel/ openModal's own props argument plus updateInstance, so this is undefined there. The returned value must be synchronous — saveLayout() itself never returns a Promise. Return undefined to fall back to the static props this panel was opened with.components/FormContainerContext.ts:42
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:60
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:46
setTitle(title) => voidChange the display title of the containing tab or window dynamically.components/FormContainerContext.ts:44

LayoutGridNode

Defined in: components/WindowManagerContext.tsx:47

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

Properties

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

LayoutLeafNode

Defined in: components/WindowManagerContext.tsx:60

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

Properties

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

ManagedWindowConfig

Defined in: components/PanelOverlay.tsx:32

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:40
contentReactNodeWindow body content.components/PanelOverlay.tsx:38
height?numberInitial height in pixels.components/PanelOverlay.tsx:44
icon?ReactNodeOptional icon shown to the left of the title in the header.components/PanelOverlay.tsx:36
titlestringText shown in the window's header bar.components/PanelOverlay.tsx:34
width?numberInitial width in pixels.components/PanelOverlay.tsx:42

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

OpenPanelOptions

Defined in: components/WindowManagerContext.tsx:152

Options accepted by WindowActions.openPanel.

Type Parameters

Type ParameterDefault type
P extends objectRecord<string, unknown>

Properties

PropertyTypeDescriptionDefined in
anchor?FloatAnchor | nullPin the new floating window to a workspace corner on creation. Has no effect when initialTarget is 'docked' or 'tabbed'.components/WindowManagerContext.tsx:159
dedupeKey?stringIf set, and another currently-open panel of the same component already has this exact dedupeKey, that existing panel is focused instead of opening a new one — the id/props passed to this call are ignored in that case, the same way re-opening an already-open exact id already focuses it instead of duplicating it. Use this when multiple call sites might not agree on the same literal id for what is semantically the same entity (e.g. "the panel for the document at this path"). See also WindowActions.findPanelId.components/WindowManagerContext.tsx:178
focus?booleanSet state.activePanelId to this panel. Default truecomponents/WindowManagerContext.tsx:161
initialTarget?"docked" | "floating" | "tabbed"Initial placement: 'floating', 'docked' (default when a grid exists), or 'tabbed'.components/WindowManagerContext.tsx:156
props?PCustom per-instance data spread onto the panel component alongside panelId, matching openModal/openLeftPanel/openRightPanel's already-unconstrained props argument — no type restriction here either. Whether a specific value round-trips through saveLayout() is a runtime fact, not a type-level guarantee: see PanelInfo.serializable and the 'layout:panels-excluded' event.components/WindowManagerContext.tsx:169
title?| string | ContextMenuPredefinedMessageOverride the panel tab/window title. Accepts a plain string or an i18n message descriptor.components/WindowManagerContext.tsx:154

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

PanelContribution

Defined in: components/PanelContributionContext.tsx:29

What a panel publishes via usePanelContribution(). Both fields are optional and independent — a panel may contribute only toolbar items, only sidebar sections, both, or neither. The app decides what "toolbar items" and "sidebar sections" mean for its own domain (map controls, document formatting, anything else).

Properties

PropertyTypeDefined in
sidebarSections?PanelSidebarSection[]components/PanelContributionContext.tsx:31
toolbarItems?ToolbarItem[]components/PanelContributionContext.tsx:30

PanelDefinition

Defined in: WorkspaceClient.ts:43

Per-panel definition supplied to WorkspaceClient constructor.

Properties

PropertyTypeDescriptionDefined in
componentComponentType<any>-WorkspaceClient.ts:44
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:45
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:1010

Imperative handle returned by usePanelFloatingWindowManager.

See

usePanelFloatingWindowManager

Methods

close()
ts
close(id): void;

Defined in: components/PanelOverlay.tsx:1014

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:1016

Close all managed windows.

Returns

void

isOpen()
ts
isOpen(id): boolean;

Defined in: components/PanelOverlay.tsx:1018

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:1012

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:1020

PanelFloatingWindowProps

Defined in: components/PanelOverlay.tsx:667

Props for <PanelFloatingWindow>.

Methods

onClose()
ts
onClose(): void;

Defined in: components/PanelOverlay.tsx:677

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

Returns

void

Properties

PropertyTypeDescriptionDefined in
children?ReactNode-components/PanelOverlay.tsx:684
defaultAnchorFloatAnchorCorner of the panel to dock to on first render. See FloatAnchorcomponents/PanelOverlay.tsx:679
defaultHeightnumberInitial height in pixels.components/PanelOverlay.tsx:683
defaultWidthnumberInitial width in pixels.components/PanelOverlay.tsx:681
icon?ReactNodeOptional icon shown to the left of the title in the header.components/PanelOverlay.tsx:673
idstringUnique identifier within the panel overlay. Used for z-order and stack tracking.components/PanelOverlay.tsx:669
openbooleanWhether the window is mounted and visible. Set to false to close/unmount it.components/PanelOverlay.tsx:675
titlestringText shown in the window's header bar.components/PanelOverlay.tsx:671

PanelInfo

Defined in: components/WindowManagerContext.tsx:114

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:120
dedupeKey?stringOptional dedup key. If another open panel of the same component already has this exact key, openPanel focuses that existing panel instead of creating a new one — see WindowActions.openPanel's dedupeKey option and WindowActions.findPanelId.components/WindowManagerContext.tsx:146
dirty?booleanTrue if the panel contains unsaved user edits.components/WindowManagerContext.tsx:130
dirtyOptions?DirtyStateOptionsCustom options applied to the automatic unsaved changes modal.components/WindowManagerContext.tsx:132
idstringUnique panel identifier.components/WindowManagerContext.tsx:116
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:126
lastFloatingRect.anchor?FloatAnchor | null-components/WindowManagerContext.tsx:126
lastFloatingRect.heightnumber-components/WindowManagerContext.tsx:126
lastFloatingRect.widthnumber-components/WindowManagerContext.tsx:126
lastFloatingRect.xnumber-components/WindowManagerContext.tsx:126
lastFloatingRect.ynumber-components/WindowManagerContext.tsx:126
lastLeafId?stringThe leaf group ID this panel was docked in prior to being floated.components/WindowManagerContext.tsx:128
previousState?"docked" | "floating"Last state held before panel was minimized.components/WindowManagerContext.tsx:124
props?Record<string, unknown>Custom per-instance data passed via openPanel(id, component, { props }). Unconstrained — any value is accepted, but only a value that passes isSerializable is actually included in WindowActions.saveLayout's output. See PanelInfo.serializable.components/WindowManagerContext.tsx:136
serializablebooleanWhether this panel's current props can round-trip through saveLayout()/loadLayout(). Computed automatically — true when no props were passed, or when they were and passed isSerializable. A panel with serializable: false still renders and works normally; it's simply excluded from the next saveLayout() call (and pruned from gridRoot/ floating/minimized in that saved snapshot) rather than corrupting or throwing.components/WindowManagerContext.tsx:142
state"docked" | "floating" | "minimized"Current workspace placement mode.components/WindowManagerContext.tsx:122
title| string | ContextMenuPredefinedMessagePlain text label or localizable message descriptor.components/WindowManagerContext.tsx:118

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:101

Props for <PanelOverlayRoot>.

Properties

PropertyTypeDefined in
childrenReactNodecomponents/PanelOverlay.tsx:102
className?stringcomponents/PanelOverlay.tsx:103
style?CSSPropertiescomponents/PanelOverlay.tsx:104

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

PanelSidebarSection

Defined in: components/PanelContributionContext.tsx:16

A single named, labeled slot of content a panel contributes to the app's Sidebar while active.

Properties

PropertyTypeDefined in
contentReactNodecomponents/PanelContributionContext.tsx:20
icon?ReactNodecomponents/PanelContributionContext.tsx:19
idstringcomponents/PanelContributionContext.tsx:17
labelstringcomponents/PanelContributionContext.tsx:18

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:291

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:299
buttonVariant?ButtonVariantDefault button style inherited by ToolbarButton and ToolbarToggle children. Default 'ghost'components/PanelOverlay.tsx:297
children?ReactNode-components/PanelOverlay.tsx:302
className?string-components/PanelOverlay.tsx:301
positionToolbarPositionEdge of the panel overlay to attach to. See ToolbarPositioncomponents/PanelOverlay.tsx:293
style?CSSProperties-components/PanelOverlay.tsx:300
variant?ToolbarVariantBackground style of the toolbar strip. Default 'transparent'components/PanelOverlay.tsx:295

PointerDragConfig

Defined in: components/dragResize.ts:14

Shared pointer-drag-resize primitives.

Extracted from four previously-independent implementations (the workspace grid split resizer, the sidebar drawer resizer, and two floating-window resize-handle implementations) that had quietly drifted apart in exactly the kind of detail (an inline-style property present in one and missing in the other) that once caused a real, user-visible bug. This file is the single place that mechanic now lives, so it can't drift again.

Type Parameters

Type Parameter
TStart

Properties

PropertyTypeDescriptionDefined in
activeClasses?{ classes: string[]; el: HTMLElement; }[]Classes toggled on the given elements for the duration of the drag.components/dragResize.ts:28
captureStart() => TStartSnapshot whatever state the caller needs at drag start (sizes, positions, ...).components/dragResize.ts:22
elementHTMLElementThe element to capture the pointer on — normally the handle the user grabbed.components/dragResize.ts:16
onEnd?(start) => voidCalled once when the drag ends (pointerup or pointercancel).components/dragResize.ts:26
onMove(dx, dy, start) => voidCalled on every pointermove with the delta from the drag's start position.components/dragResize.ts:24
pointerIdnumber-components/dragResize.ts:17
startClientXnumberThe pointerdown event's clientX/clientY, used as the delta origin.components/dragResize.ts:19
startClientYnumber-components/dragResize.ts:20

ResizeConstraints

Defined in: components/dragResize.ts:71

Properties

PropertyTypeDescriptionDefined in
maxH?numberUpper bound on height — only applies to southward growth (dir includes 's').components/dragResize.ts:77
maxW?numberUpper bound on width — only applies to eastward growth (dir includes 'e').components/dragResize.ts:75
minHnumber-components/dragResize.ts:73
minWnumber-components/dragResize.ts:72
minX?numberLower bound on the resulting x — only applies to westward growth (dir includes 'w').components/dragResize.ts:79
minY?numberLower bound on the resulting y — only applies to northward growth (dir includes 'n').components/dragResize.ts:81

ResizeRect

Defined in: components/dragResize.ts:64

Properties

PropertyTypeDefined in
hnumbercomponents/dragResize.ts:68
wnumbercomponents/dragResize.ts:67
xnumbercomponents/dragResize.ts:65
ynumbercomponents/dragResize.ts:66

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:484

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:490
group?stringOptional group header used to bucket results visually.components/PanelOverlay.tsx:492
icon?ReactNodeOptional icon shown to the left of the label.components/PanelOverlay.tsx:494
idstringUnique identifier for this result — passed to onSelect.components/PanelOverlay.tsx:486
labelstringPrimary display text.components/PanelOverlay.tsx:488

SerializedLayout

Defined in: components/WindowManagerContext.tsx:557

The on-disk shape produced by saveLayout() and accepted by loadLayout()/initialState.

Properties

PropertyTypeDescriptionDefined in
floatingFloatingWindow[]-components/WindowManagerContext.tsx:561
gridRootLayoutNode-components/WindowManagerContext.tsx:560
minimized{ component: string; id: string; title: | string | ContextMenuPredefinedMessage; }[]-components/WindowManagerContext.tsx:562
panelsRecord<string, PanelInfo>-components/WindowManagerContext.tsx:563
version?numberSchema version — absent on layouts saved before this field was introduced (treated as 0).components/WindowManagerContext.tsx:559

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:181

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:183
getActiveTab() => string | nullcomponents/Sidebar.tsx:184
openTab(tabId) => voidcomponents/Sidebar.tsx:182

SidebarHandle

Defined in: components/Sidebar.tsx:164

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

Properties

PropertyTypeDefined in
closeDrawer() => voidcomponents/Sidebar.tsx:166
getActiveTab() => string | nullcomponents/Sidebar.tsx:167
getWidth() => numbercomponents/Sidebar.tsx:174
hide() => voidcomponents/Sidebar.tsx:169
hideStrip() => voidcomponents/Sidebar.tsx:172
openTab(tabId) => voidcomponents/Sidebar.tsx:165
setWidth(px) => voidcomponents/Sidebar.tsx:173
show() => voidcomponents/Sidebar.tsx:168
showStrip() => voidcomponents/Sidebar.tsx:171
toggle() => voidcomponents/Sidebar.tsx:170

SidebarHeaderActionButton

Defined in: components/Sidebar.tsx:60

Simple case for SidebarProps.headerAction/footerAction: the library renders a default-styled icon button (visually consistent with the regular tab buttons) and forwards the click.

Properties

PropertyTypeDescriptionDefined in
disabled?boolean-components/Sidebar.tsx:67
iconReactNode-components/Sidebar.tsx:63
id?stringOnly needed when used inside a SidebarRailEntry[] array, for the React key.components/Sidebar.tsx:62
labelstringTooltip and aria-label — same convention as SidebarTab.label.components/Sidebar.tsx:65
onClick() => void-components/Sidebar.tsx:66

SidebarHeaderActionCustom

Defined in: components/Sidebar.tsx:76

Full-control case for SidebarProps.headerAction/footerAction: the consumer supplies their own markup (a Material UI IconButton, a Bootstrap Button, a Tailwind-styled <button>, or anything else) wholesale. The library renders exactly what this returns, unwrapped, so the consumer's own hover/active/focus/ripple behavior and click handling are untouched.

Properties

PropertyTypeDescriptionDefined in
id?stringOnly needed when used inside a SidebarRailEntry[] array, for the React key.components/Sidebar.tsx:78
render() => ReactNode-components/Sidebar.tsx:79

SidebarProps

Defined in: components/Sidebar.tsx:111

Properties

PropertyTypeDescriptionDefined in
activeTabId?string | nullControlled active tab id. Omit to use internal state.components/Sidebar.tsx:141
children?ReactNodeMain workspace content rendered alongside the sidebar.components/Sidebar.tsx:158
defaultWidth?numberInitial drawer width in pixels. Default: 280components/Sidebar.tsx:133
footerAction?SidebarRailEntry | SidebarRailEntry[]Mirror of headerAction, pinned to the bottom of the tab strip via its own .rdd-sidebar-footer-area — e.g. a "Settings" tab that should always sit at the bottom regardless of tab count. Override --rdd-sidebar-footer-area-padding-top/ --rdd-sidebar-footer-area-padding-bottom (both default 8px) to control its spacing.components/Sidebar.tsx:131
headerAction?SidebarRailEntry | SidebarRailEntry[]One or more non-toggling action buttons and/or real tabs shown above the tabs, in their own .rdd-sidebar-header-area — independent of the tabs' own inter-item gap. Pass a single { icon, label, onClick }/{ render } object (the common case), or an array mixing action buttons, custom renders, and SidebarTab entries — a tab entry here behaves exactly like a main-list tab (mounts, activates, closes through the same lifecycle). Override --rdd-sidebar-header-area-padding-top/--rdd-sidebar-header-area-padding-bottom (both default 8px) to control its spacing/effective height.components/Sidebar.tsx:124
maxWidth?numberMaximum drawer width in pixels during drag-resize. Default: 600components/Sidebar.tsx:137
minWidth?numberMinimum drawer width in pixels during drag-resize. Default: 150components/Sidebar.tsx:135
onActiveTabChange?(tabId) => voidCalled when the active tab changes.components/Sidebar.tsx:143
onStripVisibilityChange?(visible) => voidCalled when showStrip/hideStrip is invoked on the imperative handle.components/Sidebar.tsx:151
onVisibilityChange?(visible) => voidCalled when show/hide/toggle is invoked on the imperative handle.components/Sidebar.tsx:147
onWidthChange?(px) => voidCalled during drag resize and on setWidth() with the new pixel width.components/Sidebar.tsx:139
position?"left" | "right"Which side the activity bar and drawer appear on. Default: 'right'components/Sidebar.tsx:113
showCloseButton?booleanShow an "X" close button in the expanded drawer's header, as an additional way to collapse the sidebar (equivalent to clicking the active tab's own icon again). Opt-in. Default: falsecomponents/Sidebar.tsx:156
stripVisible?booleanCollapse only the activity bar strip, leaving the drawer unaffected. Default: truecomponents/Sidebar.tsx:149
tabsSidebarTab[]-components/Sidebar.tsx:114
visible?booleanCollapse the entire sidebar (strip + drawer). Default: truecomponents/Sidebar.tsx:145

SidebarTab

Defined in: components/Sidebar.tsx:30

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:39
iconReactNode-components/Sidebar.tsx:33
idstring-components/Sidebar.tsx:31
labelstring-components/Sidebar.tsx:32
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:45
renderContent(tabId, onClose, onOpen) => ReactNodeCalled to obtain the drawer content for this tab.components/Sidebar.tsx:52

SidebarTabContextValue

Defined in: components/Sidebar.tsx:191

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

Properties

PropertyTypeDefined in
onClose() => voidcomponents/Sidebar.tsx:194
onOpen() => voidcomponents/Sidebar.tsx:193
openTab(tabId) => voidcomponents/Sidebar.tsx:195
tabIdstringcomponents/Sidebar.tsx:192

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:155

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:161

StyleClasses

Defined in: components/WindowManagerContext.tsx:494

Represents custom CSS classes injected into layout parts.

Properties

PropertyTypeDefined in
modalBodyClass?stringcomponents/WindowManagerContext.tsx:496
modalClass?stringcomponents/WindowManagerContext.tsx:495
sidePanelBodyClass?stringcomponents/WindowManagerContext.tsx:498
sidePanelClass?stringcomponents/WindowManagerContext.tsx:497
windowBodyClass?stringcomponents/WindowManagerContext.tsx:500
windowClass?stringcomponents/WindowManagerContext.tsx:499

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:389

Props for <ToolbarButton>.

Methods

onClick()
ts
onClick(): void;

Defined in: components/PanelOverlay.tsx:393

Click handler.

Returns

void

Properties

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

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:108

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:124
defaultIconReactNodeIcon shown when no sub-item is active.components/Toolbar.tsx:115
disabled?boolean-components/Toolbar.tsx:117
idstringServes as both the button ID and the radio group key in ToolbarContext.components/Toolbar.tsx:111
itemsToolbarGroupEntry[]-components/Toolbar.tsx:116
labelstringTooltip / aria-label shown when no sub-item is active.components/Toolbar.tsx:113
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:129
type"group"-components/Toolbar.tsx:109

ToolbarGroupSubItem

Defined in: components/Toolbar.tsx:84

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:90
iconReactNode-components/Toolbar.tsx:87
idstring-components/Toolbar.tsx:85
labelstring-components/Toolbar.tsx:86
onActivate?(id) => voidCalled when this sub-item is selected.components/Toolbar.tsx:92
shortcut?stringKeyboard shortcut displayed in the flyout panel.components/Toolbar.tsx:89

ToolbarHandle

Defined in: components/Toolbar.tsx:156

Methods

hide()
ts
hide(): void;

Defined in: components/Toolbar.tsx:158

Returns

void

show()
ts
show(): void;

Defined in: components/Toolbar.tsx:157

Returns

void

toggle()
ts
toggle(): void;

Defined in: components/Toolbar.tsx:159

Returns

void


ToolbarProps

Defined in: components/Toolbar.tsx:143

Properties

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

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:498

Props for <ToolbarSearchInput>.

Methods

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

Defined in: components/PanelOverlay.tsx:506

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:508

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:500

ToolbarSeparator

Defined in: components/Toolbar.tsx:71

A visual divider between button groups.

Properties

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

ToolbarToggleItem

Defined in: components/Toolbar.tsx:52

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

Supports both uncontrolled mode (omit rdd-active — state lives in ToolbarContext, keyed by id) and controlled mode (provide rdd-active — the caller is the single source of truth and must update the prop in response to onToggle). Controlled mode is what lets independent instances of the same panel type report independent active state instead of colliding on a shared id.

Properties

PropertyTypeDescriptionDefined in
active?booleanControlled active state. When provided (even as false), the component reads this prop instead of ToolbarContext and does not update context on click. Omit (undefined) for uncontrolled behaviour.components/Toolbar.tsx:64
disabled?boolean-components/Toolbar.tsx:67
iconReactNode-components/Toolbar.tsx:56
idstring-components/Toolbar.tsx:54
labelstring-components/Toolbar.tsx:55
onToggle?(active) => voidCalled after the toggle flips; receives the new active state.components/Toolbar.tsx:66
shortcut?stringKeyboard shortcut hint — reserved for future custom tooltip.components/Toolbar.tsx:58
type"toggle"-components/Toolbar.tsx:53

ToolbarToggleProps

Defined in: components/PanelOverlay.tsx:421

Props for <ToolbarToggle>.

Methods

onToggle()
ts
onToggle(): void;

Defined in: components/PanelOverlay.tsx:427

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:425
disabled?boolean-components/PanelOverlay.tsx:428
iconReactNodeButton icon — typically a small SVG component.components/PanelOverlay.tsx:423
title?stringTooltip text and accessible aria-label.components/PanelOverlay.tsx:430
variant?ButtonVariantVisual style override. Falls back to the parent PanelToolbar's buttonVariant.components/PanelOverlay.tsx:432

UsePanelFloatingWindowReturn

Defined in: components/PanelOverlay.tsx:978

Return type of usePanelFloatingWindow.

See

usePanelFloatingWindow

Methods

close()
ts
close(): void;

Defined in: components/PanelOverlay.tsx:984

Close the floating window.

Returns

void

open()
ts
open(): void;

Defined in: components/PanelOverlay.tsx:982

Open the floating window.

Returns

void

Properties

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

WindowManagerProps

Defined in: components/WindowManager.tsx:817

Props for <WindowManager>.

Properties

PropertyTypeDescriptionDefined in
animations?booleanEnables the library's own transitions/animations (tab hover, dock preview, etc.). Never affects the consumer's own page. Default truecomponents/WindowManager.tsx:833
contextMenuAdapter?ContextMenuAdapterCustom context menu renderer. Defaults to the built-in DefaultContextMenuAdapter.components/WindowManager.tsx:831
defaultPanelIcon?ReactNodeFallback icon shown in panel tabs when no panel-specific icon is provided.components/WindowManager.tsx:821
skin?stringBuilt-in skin name or a custom skin key registered via CSS. Default 'vscode'components/WindowManager.tsx:819
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:829

WindowManagerProviderProps

Defined in: components/WindowManagerContext.tsx:619

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

See

DockableDesktopProviderProps

Extended by

Properties

PropertyTypeDescriptionDefined in
childrenReactNode-components/WindowManagerContext.tsx:620
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:623
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:632
formatMessage?MessageFormatterCustom i18n formatter. Receives a { id, defaultMessage } descriptor and returns the translated string. When omitted, defaultMessage is used as-is.components/WindowManagerContext.tsx:626
modalBodyClass?stringCSS class applied to the inner content area of every modal overlay.components/WindowManagerContext.tsx:636
modalClass?stringCSS class applied to the outer wrapper element of every modal overlay.components/WindowManagerContext.tsx:634
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:629
sidePanelBodyClass?stringCSS class applied to the inner content area of side-panel drawers.components/WindowManagerContext.tsx:640
sidePanelClass?stringCSS class applied to the outer wrapper of left/right side-panel drawers.components/WindowManagerContext.tsx:638
windowBodyClass?stringCSS class applied to the inner content area of floating panel windows.components/WindowManagerContext.tsx:644
windowClass?stringCSS class applied to the outer wrapper of floating panel windows.components/WindowManagerContext.tsx:642
zIndexBase?numberStarting z-index for floating windows and the library's own chrome overlays (context menu, toolbar flyout, modal stack, toast, workspace edge zones), all of which shift together via --rdd-z-base. Set this above/below a host app's own modal z-index range to control stacking against it. Default 1000components/WindowManagerContext.tsx:651

WindowState

Defined in: components/WindowManagerContext.tsx:184

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:196
dir"rtl" | "ltr"Current layout direction ('ltr' or 'rtl')components/WindowManagerContext.tsx:198
draggedPanelIdstring | nullThe ID of the panel tab currently being dragged.components/WindowManagerContext.tsx:194
edgeSplitRationumberSplit ratio for workspace outer-edge drops (0.1–0.9). Default 0.2.components/WindowManagerContext.tsx:204
floatingFloatingWindow[]Array of active floated windows.components/WindowManagerContext.tsx:188
gridRootLayoutNodeRoot branch node representing the grid.components/WindowManagerContext.tsx:186
isRtlbooleanConvenient boolean flag indicating RTL directioncomponents/WindowManagerContext.tsx:200
minimized{ component: string; id: string; title: | string | ContextMenuPredefinedMessage; }[]Array of minimized panels waiting in the taskbar dock.components/WindowManagerContext.tsx:190
panelsRecord<string, PanelInfo>Map indexing panel metadata descriptors.components/WindowManagerContext.tsx:192
splitRationumberSplit ratio for panel cross-target drops (0.1–0.9). Default 0.5.components/WindowManagerContext.tsx:202

WorkspaceClientConfig

Defined in: WorkspaceClient.ts:49

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:75
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:70
dir?"rtl" | "ltr"Initial layout direction.WorkspaceClient.ts:65
formatMessage?MessageFormatterCustom i18n formatter for all internal strings.WorkspaceClient.ts:61
initialState?string | nullSerialised layout produced by a previous saveLayout() call. Pass null or omit to start with an empty canvas.WorkspaceClient.ts:59
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:54
predefinedMessages?Record<string, ContextMenuPredefinedMessage>Override any subset of the built-in predefined message catalog.WorkspaceClient.ts:63
zIndexBase?numberStarting z-index for floating windows and the library's own chrome overlays (context menu, toolbar flyout, modal stack, toast, workspace edge zones), all of which shift together via --rdd-z-base. Set this above/below a host app's own modal z-index range to control stacking against it. Default: 1000.WorkspaceClient.ts:82

Type Aliases

ButtonVariant

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

Defined in: components/PanelOverlay.tsx:288

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


DropPosition

ts
type DropPosition = SplitDirection | "center";

Defined in: components/WindowManagerContext.tsx:36

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:87

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:75

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:27

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> = { ... };


ResizeDir

ts
type ResizeDir = "n" | "ne" | "e" | "se" | "s" | "sw" | "w" | "nw";

Defined in: components/dragResize.ts:62


SidebarHeaderAction

ts
type SidebarHeaderAction = 
  | SidebarHeaderActionButton
  | SidebarHeaderActionCustom;

Defined in: components/Sidebar.tsx:88

A single, non-toggling action button shown above the tab strip (e.g. a hamburger menu). Unlike SidebarTab, it never affects activeTabId or the drawer — the library only renders it and forwards the click; what happens next (opening a side panel, a modal, anything else) is entirely up to the consumer.


SplitDirection

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

Defined in: components/WindowManagerContext.tsx:33

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


SplitOrientation

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

Defined in: components/WindowManagerContext.tsx:30

Orientation modifier indicating split directions.


TaskbarVisibility

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

Defined in: components/WindowManager.tsx:814

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:96

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:132


ToolbarPosition

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

Defined in: components/PanelOverlay.tsx:22

Edge of a panel to which a PanelToolbar attaches.


ToolbarVariant

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

Defined in: components/PanelOverlay.tsx:285

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


ContextMenuProvider

ts
const ContextMenuProvider: React.FC<{
  adapter?: ContextMenuAdapter;
  children: React.ReactNode;
} & ContextMenuProps>;

Defined in: components/ContextMenu.tsx:466


DefaultContextMenuAdapter

ts
const DefaultContextMenuAdapter: ContextMenuAdapter;

Defined in: components/ContextMenu.tsx:450


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<DockableDesktopProviderProps>;

Defined in: components/DockableDesktopProvider.tsx:47

Composite provider that wraps WindowManagerProvider, PanelProvider, ToolbarProvider, and PanelContributionProvider in the correct order, and mounts the workspace-level ContextMenuProvider so that showContextMenu() and useShowContextMenu() work from any component in the tree — including siblings of <WindowManager> such as <Sidebar>, <SidePanelRenderer>, and <ModalStackRenderer>.

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}>
  <Sidebar>
    <WindowManager />
  </Sidebar>
  <SidePanelRenderer />
  <ModalStackRenderer />
</DockableDesktopProvider>

FormContainerContext

ts
const FormContainerContext: Context<FormContainerContract>;

Defined in: components/FormContainerContext.ts:109

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


FormContainerProvider

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

Defined in: components/FormContainerContext.ts:110


LeftPanelRenderer

ts
const LeftPanelRenderer: React.FC<SidePanelRendererProps>;

Defined in: components/SidePanelRenderer.tsx:181

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


ModalStackRenderer

ts
const ModalStackRenderer: React.FC;

Defined in: components/ModalStackRenderer.tsx:154

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


PanelContributionProvider

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

Defined in: components/PanelContributionContext.tsx:76

Provider enabling usePanelContribution() / useActivePanelContribution(). Mounted automatically by DockableDesktopProvider — only needed manually when composing WindowManagerProvider directly without it.


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:190

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:415


SidePanelRenderer

ts
const SidePanelRenderer: React.FC<SidePanelRendererProps>;

Defined in: components/SidePanelRenderer.tsx:168

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:419


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:836

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:654

Released under the MIT License.