@hostwebhook/node-types 1.6.0 → 1.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -45,7 +45,7 @@ exports.NODE_CONNECTIONS = {
45
45
  code: { acceptsInputFrom: STANDARD_INPUTS, canOutputTo: PROCESSING_OUTPUTS },
46
46
  ai: { acceptsInputFrom: [...ACTION_INPUTS], canOutputTo: PROCESSING_OUTPUTS },
47
47
  // ── Flow control nodes ──
48
- split: { acceptsInputFrom: STANDARD_INPUTS, canOutputTo: PROCESSING_OUTPUTS, special: { hasBranches: true } },
48
+ split: { acceptsInputFrom: STANDARD_INPUTS, canOutputTo: PROCESSING_OUTPUTS },
49
49
  merge: { acceptsInputFrom: ['endpoint', 'filter', 'transform', 'cache', 'rateLimiter', 'aggregator', 'conditional', 'delay', 'schemaValidator', 'split'], canOutputTo: PROCESSING_OUTPUTS },
50
50
  approval: { acceptsInputFrom: ['endpoint', 'filter', 'transform'], canOutputTo: ['endpoint', 'filter', 'transform', 'emailAction', 'httpAction', 'mongoAction', 'notificationAction', 'sheetsAction'], special: { hasRejectionOutputNodes: true } },
51
51
  // ── Routing nodes ──
package/dist/types.d.ts CHANGED
@@ -29,8 +29,25 @@ export interface NodeUIConfig {
29
29
  rejectionEndpoints?: string;
30
30
  hasBranches?: boolean;
31
31
  isTerminal?: boolean;
32
- connectModal?: 'branch' | 'rule';
32
+ connectModal?: 'branch' | 'rule' | 'output-group';
33
33
  routerTargetLabel?: string;
34
+ /**
35
+ * Generic named output groups — used by connectModal: 'output-group'.
36
+ * The modal reads entity[outputGroupsField] as an array of groups,
37
+ * each with a name (outputGroupNameField), a summary (outputGroupSummaryField),
38
+ * and its own outputNodes[].
39
+ * Works for Split (outputs[]), Conditional (branches[]), or any future branching node.
40
+ */
41
+ outputGroups?: {
42
+ /** Entity field containing the array of groups (e.g. 'outputs', 'branches') */
43
+ field: string;
44
+ /** Field within each group for display name (e.g. 'name') */
45
+ nameField: string;
46
+ /** Field within each group for summary/description (e.g. 'field', 'filterMode') */
47
+ summaryField?: string;
48
+ /** Label shown in the modal (e.g. 'output', 'branch') */
49
+ label: string;
50
+ };
34
51
  };
35
52
  }
36
53
  /** API dispatch config — how the event pipeline processes each node */
package/dist/ui.js CHANGED
@@ -22,7 +22,7 @@ exports.NODE_UI = {
22
22
  code: { fromNodes: true, toNodes: true },
23
23
  ai: { fromNodes: true, toNodes: true },
24
24
  // ── Flow control nodes ──
25
- split: { fromNodes: true, toNodes: true, outputHandles: ['right', 'bottom'], special: { hasBranches: true, connectModal: 'branch' } },
25
+ split: { fromNodes: true, toNodes: true, outputHandles: ['right', 'bottom'], special: { connectModal: 'output-group', outputGroups: { field: 'outputs', nameField: 'name', summaryField: 'field', label: 'output' } } },
26
26
  merge: { fromNodes: true, toNodes: true, inputHandles: ['left', 'top'] },
27
27
  approval: { fromNodes: true, toNodes: true, outputHandles: ['right', 'bottom'], special: { rejectionEndpoints: 'rejectionEndpointIds' } },
28
28
  // ── Routing nodes ──
@@ -56,14 +56,14 @@ exports.PREFIX_TO_TYPE = [
56
56
  { prefix: 'delay-', type: 'delay', canvasType: 'delay-node' },
57
57
  { prefix: 'sheet-', type: 'sheetsAction', canvasType: 'sheets-action' },
58
58
  { prefix: 'appr-', type: 'approval', canvasType: 'approval-node' },
59
- { prefix: 'merge-', type: 'merge', canvasType: 'merge-node' },
59
+ { prefix: 'merge-', type: 'merge', canvasType: 'merge' },
60
60
  { prefix: 'cond-', type: 'conditional', canvasType: 'conditional-node' },
61
61
  { prefix: 'rl-', type: 'rateLimiter', canvasType: 'rate-limiter-node' },
62
62
  { prefix: 'agg-', type: 'aggregator', canvasType: 'aggregator-node' },
63
63
  { prefix: 'cache-', type: 'cache', canvasType: 'cache-node' },
64
64
  { prefix: 'code-', type: 'code', canvasType: 'code-node' },
65
65
  { prefix: 'ai-', type: 'ai', canvasType: 'ai-node' },
66
- { prefix: 'split-', type: 'split', canvasType: 'split-node' },
66
+ { prefix: 'split-', type: 'split', canvasType: 'split' },
67
67
  { prefix: 'note-', type: 'stickyNote', canvasType: 'sticky-note' },
68
68
  ];
69
69
  /** Resolve canvas node ID to { type, entityId } */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hostwebhook/node-types",
3
- "version": "1.6.0",
3
+ "version": "1.8.0",
4
4
  "description": "Shared node type definitions, connection rules, and dispatch config for HostWebhook",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",