Skip to content

rune-langium / visual-editor/src / ExpressionBuilderProps

Interface: ExpressionBuilderProps ​

Defined in: packages/visual-editor/src/components/editors/expression-builder/ExpressionBuilder.tsx:31

Props provided to the expression editor render-prop slot.

packages/visual-editor is editor-agnostic — the host app provides the actual editor implementation (e.g. CodeMirror, Monaco) via a renderExpressionEditor prop on FunctionForm.

Extends ​

Properties ​

PropertyTypeDescriptionOverridesInherited fromDefined in
defaultMode?"text" | "builder"---packages/visual-editor/src/components/editors/expression-builder/ExpressionBuilder.tsx:33
draftCondition?{ kind: "precondition" | "postcondition"; nodeId: string; }Scope for a new condition draft; no expression source region exists yet.-ExpressionEditorSlotProps.draftConditionpackages/visual-editor/src/types.ts:159
draftCondition.kind"precondition" | "postcondition"---packages/visual-editor/src/types.ts:159
draftCondition.nodeIdstring---packages/visual-editor/src/types.ts:159
error?string | nullValidation error message (null when valid).-ExpressionEditorSlotProps.errorpackages/visual-editor/src/types.ts:151
expressionAst?unknownOptional raw AST expression object — when provided, used directly instead of parsing value text.ExpressionEditorSlotProps.expressionAst-packages/visual-editor/src/components/editors/expression-builder/ExpressionBuilder.tsx:37
onBlur() => voidCalled when the editor loses focus — triggers validation & commit.-ExpressionEditorSlotProps.onBlurpackages/visual-editor/src/types.ts:149
onChange(value) => voidCalled on every keystroke / change.-ExpressionEditorSlotProps.onChangepackages/visual-editor/src/types.ts:147
onDragNode?(draggedNodeId, targetNodeId) => voidCallback when a node is dragged to a placeholder target.--packages/visual-editor/src/components/editors/expression-builder/ExpressionBuilder.tsx:35
placeholder?stringPlaceholder text shown when the editor is empty.-ExpressionEditorSlotProps.placeholderpackages/visual-editor/src/types.ts:153
readOnly?boolean--ExpressionEditorSlotProps.readOnlypackages/visual-editor/src/types.ts:156
renderTextEditor?(props) => ReactNodeHost text surface; the standalone embedder retains its textarea fallback.--packages/visual-editor/src/components/editors/expression-builder/ExpressionBuilder.tsx:39
scopeFunctionScope---packages/visual-editor/src/components/editors/expression-builder/ExpressionBuilder.tsx:32
target?{ index: number; kind: "precondition" | "postcondition"; nodeId: string; }--ExpressionEditorSlotProps.targetpackages/visual-editor/src/types.ts:157
target.indexnumber---packages/visual-editor/src/types.ts:157
target.kind"precondition" | "postcondition"---packages/visual-editor/src/types.ts:157
target.nodeIdstring---packages/visual-editor/src/types.ts:157
valuestringCurrent expression text.-ExpressionEditorSlotProps.valuepackages/visual-editor/src/types.ts:145

Core packages released under MIT. Studio app released under FSL-1.1-ALv2.