interface CubeDefinitionFlowProps {
    colorMode?: "light" | "dark";
    flow: CubeDefinitionFlowReading;
    initiallyFolded?: readonly string[];
    onSelectStep?: (stepId: string) => void;
    onShowFunction?: (call: CubeDefinitionFunctionContainer) => void;
    onShowSql?: (island: CubeDefinitionSqlIsland) => void;
    selectedStepId?: string;
}

Properties

colorMode?: "light" | "dark"

The host's theme, for React Flow's own defaults; the canvas takes its colours from Cube's theme tokens, as its steps do

The definition's steps, as readCubeDefinition read them

initiallyFolded?: readonly string[]

The calls, and the SQL drawn as steps, folded to one box when the flow opens, by id; by default, the calls holding more than CUBE_DEFINITION_CALL_OPEN_STEPS steps and the SQL of more than CUBE_DEFINITION_SQL_OPEN_STEPS

onSelectStep?: (stepId: string) => void

Gets a step's id when it is clicked, or Enter or Space is pressed on it

onShowFunction?: (call: CubeDefinitionFunctionContainer) => void

Shows a user-defined function's Pure, from its container's header, its box, or a step whose expression calls it (PLAN §11.33)

onShowSql?: (island: CubeDefinitionSqlIsland) => void

Shows the SQL of an island, #SQL{…}#: when its box is clicked, or, for SQL drawn as steps, one of its clauses or its container's button

selectedStepId?: string

The step the host shows as picked, outlined