@hitachivantara/uikit-react-lab 5.26.3 → 5.27.1

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.
Files changed (46) hide show
  1. package/dist/cjs/Flow/Controls/Controls.cjs +2 -1
  2. package/dist/cjs/Flow/Controls/Controls.cjs.map +1 -1
  3. package/dist/cjs/Flow/DroppableFlow.cjs +2 -1
  4. package/dist/cjs/Flow/DroppableFlow.cjs.map +1 -1
  5. package/dist/cjs/Flow/Flow.styles.cjs +0 -6
  6. package/dist/cjs/Flow/Flow.styles.cjs.map +1 -1
  7. package/dist/cjs/Flow/Node/BaseNode.cjs +11 -12
  8. package/dist/cjs/Flow/Node/BaseNode.cjs.map +1 -1
  9. package/dist/cjs/Flow/Node/BaseNode.styles.cjs +11 -1
  10. package/dist/cjs/Flow/Node/BaseNode.styles.cjs.map +1 -1
  11. package/dist/cjs/Flow/Node/Node.cjs +1 -1
  12. package/dist/cjs/Flow/Node/Node.cjs.map +1 -1
  13. package/dist/cjs/Flow/hooks/useFlowInstance.cjs +8 -0
  14. package/dist/cjs/Flow/hooks/useFlowInstance.cjs.map +1 -0
  15. package/dist/cjs/Flow/hooks/useFlowNode.cjs +25 -15
  16. package/dist/cjs/Flow/hooks/useFlowNode.cjs.map +1 -1
  17. package/dist/cjs/Flow/hooks/useFlowNodeMeta.cjs +5 -1
  18. package/dist/cjs/Flow/hooks/useFlowNodeMeta.cjs.map +1 -1
  19. package/dist/cjs/Flow/hooks/useNodeId.cjs +9 -0
  20. package/dist/cjs/Flow/hooks/useNodeId.cjs.map +1 -0
  21. package/dist/cjs/index.cjs +2 -0
  22. package/dist/cjs/index.cjs.map +1 -1
  23. package/dist/esm/Flow/Controls/Controls.js +3 -2
  24. package/dist/esm/Flow/Controls/Controls.js.map +1 -1
  25. package/dist/esm/Flow/DroppableFlow.js +3 -2
  26. package/dist/esm/Flow/DroppableFlow.js.map +1 -1
  27. package/dist/esm/Flow/Flow.styles.js +0 -6
  28. package/dist/esm/Flow/Flow.styles.js.map +1 -1
  29. package/dist/esm/Flow/Node/BaseNode.js +12 -13
  30. package/dist/esm/Flow/Node/BaseNode.js.map +1 -1
  31. package/dist/esm/Flow/Node/BaseNode.styles.js +11 -1
  32. package/dist/esm/Flow/Node/BaseNode.styles.js.map +1 -1
  33. package/dist/esm/Flow/Node/Node.js +1 -1
  34. package/dist/esm/Flow/Node/Node.js.map +1 -1
  35. package/dist/esm/Flow/hooks/useFlowInstance.js +8 -0
  36. package/dist/esm/Flow/hooks/useFlowInstance.js.map +1 -0
  37. package/dist/esm/Flow/hooks/useFlowNode.js +26 -16
  38. package/dist/esm/Flow/hooks/useFlowNode.js.map +1 -1
  39. package/dist/esm/Flow/hooks/useFlowNodeMeta.js +5 -1
  40. package/dist/esm/Flow/hooks/useFlowNodeMeta.js.map +1 -1
  41. package/dist/esm/Flow/hooks/useNodeId.js +9 -0
  42. package/dist/esm/Flow/hooks/useNodeId.js.map +1 -0
  43. package/dist/esm/index.js +2 -0
  44. package/dist/esm/index.js.map +1 -1
  45. package/dist/types/index.d.ts +22 -9
  46. package/package.json +3 -3
@@ -30,6 +30,7 @@ import { Node as Node_2 } from 'reactflow';
30
30
  import { NodeProps } from 'reactflow';
31
31
  import { PanelPosition } from 'reactflow';
32
32
  import { default as React_2 } from 'react';
33
+ import { ReactFlowInstance } from 'reactflow';
33
34
  import { ReactFlowProps } from 'reactflow';
34
35
  import { ReactGridLayoutProps } from 'react-grid-layout';
35
36
  import { ResponsiveProps } from 'react-grid-layout';
@@ -461,6 +462,8 @@ export declare const HvFlowEmpty: ({ className, ...others }: HvFlowEmptyProps) =
461
462
  export declare interface HvFlowEmptyProps extends HvEmptyStateProps {
462
463
  }
463
464
 
465
+ export declare type HvFlowInstance<NodeData = any, EdgeData = any> = ReactFlowInstance<NodeData, EdgeData>;
466
+
464
467
  export declare const HvFlowMinimap: ({ nodeColor, maskColor, maskStrokeColor, nodeStrokeColor, classes: classesProp, className, ...others }: HvFlowMinimapProps) => JSX_2.Element;
465
468
 
466
469
  export declare type HvFlowMinimapClasses = ExtractNames<typeof useClasses_5>;
@@ -1133,26 +1136,36 @@ declare const useClasses_9: (classesProp?: Partial<Record<"root" | "title" | "ti
1133
1136
 
1134
1137
  export declare const useFlowContext: () => HvFlowContextValue<string>;
1135
1138
 
1136
- export declare function useFlowInputNodes<T = any>(id: string): Node_2<T, string | undefined>[];
1139
+ /** Retrieves the nodes connected to the inputs of the node */
1140
+ export declare function useFlowInputNodes<T = any>(id?: string): Node_2<T, string | undefined>[];
1141
+
1142
+ /** Retrieves the React Flow instance */
1143
+ export declare function useFlowInstance<NodeData = any, EdgeData = any>(): HvFlowInstance<NodeData, EdgeData>;
1137
1144
 
1138
- export declare function useFlowNode<T extends Node_2 = Node_2>(id: string): T | undefined;
1145
+ /** Retrieves the node instance */
1146
+ export declare function useFlowNode<T extends Node_2 = Node_2>(id?: string): T | undefined;
1139
1147
 
1140
- export declare function useFlowNodeEdges(id: string): Edge<any>[];
1148
+ /** Offers both input and output edges of the node */
1149
+ export declare function useFlowNodeEdges(id?: string): Edge<any>[];
1141
1150
 
1142
- export declare function useFlowNodeInputEdges(id: string): Edge<any>[];
1151
+ /** Provides the input edges connected to the node */
1152
+ export declare function useFlowNodeInputEdges(id?: string): Edge<any>[];
1143
1153
 
1144
- export declare function useFlowNodeMeta(id: string): HvFlowNodeMeta;
1154
+ export declare function useFlowNodeMeta(id?: string): HvFlowNodeMeta | undefined;
1145
1155
 
1146
- export declare function useFlowNodeOutputEdges(id: string): Edge<any>[];
1156
+ /** Gives the output edges connected from the node */
1157
+ export declare function useFlowNodeOutputEdges(id?: string): Edge<any>[];
1147
1158
 
1148
- export declare function useFlowNodeParents(id: string): Node_2<any, string | undefined>[];
1159
+ /** Gets the parent nodes of a specified node (nodes that have an output connected to one of the inputs of the node) */
1160
+ export declare function useFlowNodeParents(id?: string): Node_2<any, string | undefined>[];
1149
1161
 
1150
1162
  /** Utilities to manipulate a node in the flow */
1151
- export declare function useFlowNodeUtils<NodeData = any>(): {
1163
+ export declare function useFlowNodeUtils<NodeData = any>(id?: string): {
1152
1164
  setNodeData: (setNewData: (newData?: NodeData) => NodeData) => void;
1153
1165
  };
1154
1166
 
1155
- export declare function useFlowOutputNodes<T = any>(id: string): Node_2<T, string | undefined>[];
1167
+ /** Retrieves the nodes connected to the outputs of the node */
1168
+ export declare function useFlowOutputNodes<T = any>(id?: string): Node_2<T, string | undefined>[];
1156
1169
 
1157
1170
  export declare const wizardActionsClasses: {
1158
1171
  actionsContainer: "HvWizardActions-actionsContainer";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hitachivantara/uikit-react-lab",
3
- "version": "5.26.3",
3
+ "version": "5.27.1",
4
4
  "private": false,
5
5
  "author": "Hitachi Vantara UI Kit Team",
6
6
  "description": "Contributed React components for the NEXT UI Kit.",
@@ -32,7 +32,7 @@
32
32
  "@dnd-kit/core": "^6.1.0",
33
33
  "@dnd-kit/modifiers": "^6.0.1",
34
34
  "@emotion/css": "^11.11.0",
35
- "@hitachivantara/uikit-react-core": "^5.46.0",
35
+ "@hitachivantara/uikit-react-core": "^5.46.1",
36
36
  "@hitachivantara/uikit-react-icons": "^5.8.2",
37
37
  "@hitachivantara/uikit-styles": "^5.18.0",
38
38
  "@types/react-grid-layout": "^1.3.5",
@@ -50,7 +50,7 @@
50
50
  "access": "public",
51
51
  "directory": "package"
52
52
  },
53
- "gitHead": "a2562049d702de7c20373efd6785fb8f84e9a20a",
53
+ "gitHead": "9cfeb1c73fd98690c4e8f2c91ce67b27b7bf90f1",
54
54
  "main": "dist/cjs/index.cjs",
55
55
  "exports": {
56
56
  ".": {