windease API reference - v0.6.0
    Preparing search index...

    Interface ContainerProps

    interface ContainerProps {
        affordanceHitPad?: number;
        affordances?: boolean | AffordanceRenderer;
        children?: ReactNode;
        chrome?: Chrome;
        className?: string;
        overlay?: ReactNode | OverlayRenderer;
        parentId: NodeId;
        settleMs?: number;
        style?: CSSProperties;
        viewport?: { h: number; w: number };
    }
    Index

    Properties

    affordanceHitPad?: number

    When affordances={true}, pad the hit area by this many pixels in the perpendicular direction so a 4px gutter becomes a wider grab target. Visual placement (via data-affordance styling) is not affected. Default 4.

    affordances?: boolean | AffordanceRenderer

    Render the strategy's affordances (e.g. splitStrategy's gutter) as interactive elements. true ships the default rect renderer with a widened hit area and auto-suppresses the settle animation during drag.

    Pass a function to fully replace it per affordance — see AffordanceRenderArgs. Custom renderers handle their own pointer events; if you also want settle suppressed during your gestures, set settleMs={0} (or condition it via overlay's draggingAffordanceId by managing a parallel state).

    Default false.

    children?: ReactNode

    When provided, Container renders these directly and skips the chrome dispatch. Use this for declarative trees built with //. When omitted, Container reads children from the store and renders each via chrome.

    chrome?: Chrome

    A (args) => ReactNode handler, or a role-keyed map (see Chrome). Optional when children is provided.

    className?: string
    overlay?: ReactNode | OverlayRenderer

    Rendered after children + affordances. Pass a function to read the live layout (placements, affordances, viewport, draggingAffordanceId) — useful for drop indicators, debug overlays, or readouts during resize.

    parentId: NodeId

    The container node whose children to render.

    settleMs?: number

    Settle animation duration in ms for children moving between placements. Set to 0 to disable. Default 150. The library only animates position (left/top/width/height); chrome handlers can layer their own.

    style?: CSSProperties
    viewport?: { h: number; w: number }

    Fixed viewport; omit to auto-measure via ResizeObserver.