feat: added tooltip and patched potential breaking point in mode toggle for the new node

ref: N25B-433
This commit is contained in:
JGerla
2026-01-14 13:57:58 +01:00
parent 33f520d310
commit f99ad7ad2e
2 changed files with 7 additions and 4 deletions

View File

@@ -81,8 +81,9 @@ export function InferredBeliefDisconnectionSource(_thisNode: Node, _targetNodeId
// no additional connection logic exists yet
}
export const InferredBeliefTooltip = `
Combines two beliefs into a single belief using logical inference,
the node can be toggled between using "AND" and "OR" mode for inference`;
/**
* Defines how an InferredBelief node should be rendered
* @param {NodeProps<InferredBeliefNode>} props - Node properties provided by React Flow, including `id` and `data`.
@@ -96,7 +97,8 @@ export default function InferredBeliefNode(props: NodeProps<InferredBeliefNode>)
// used to toggle operator
function onToggle() {
setEnforceAllBeliefs(!enforceAllBeliefs);
const newOperator = !enforceAllBeliefs; // compute the new value
setEnforceAllBeliefs(newOperator);
updateNodeData(props.id, {
...data,