feat: added tooltip and patched potential breaking point in mode toggle for the new node
ref: N25B-433
This commit is contained in:
@@ -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,
|
||||
|
||||
Reference in New Issue
Block a user