feat: small fix to trigger node

ref: N25B-450
This commit is contained in:
JGerla
2026-01-27 13:33:52 +01:00
parent 0ac5a1973c
commit 4e99e7c6e5

View File

@@ -139,7 +139,7 @@ export default function TriggerNode(props: NodeProps<TriggerNode>) {
id="TriggerBeliefs"
style={{ left: '40%' }}
rules={[
allowOnlyConnectionsFromType(['basic_belief']),
allowOnlyConnectionsFromType(['basic_belief','inferred_belief']),
]}
title="Connect to a beliefNode or a set of beliefs combined using the AND/OR node"
/>
@@ -205,7 +205,7 @@ export function TriggerConnectionTarget(_thisNode: Node, _sourceNodeId: string)
const otherNode = nodes.find((x) => x.id === _sourceNodeId)
if (!otherNode) return;
if (otherNode.type === 'basic_belief' /* TODO: Add the option for an inferred belief */) {
if (['basic_belief', 'inferred_belief'].includes(otherNode.type!)) {
data.condition = _sourceNodeId;
}