@wandelbots/wandelbots-js-react-components 2.54.5 → 3.0.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.
Files changed (109) hide show
  1. package/README.md +1 -1
  2. package/dist/auth0-spa-js.production.esm-Bb4L9JDU.js +1423 -0
  3. package/dist/auth0-spa-js.production.esm-Bb4L9JDU.js.map +1 -0
  4. package/dist/auth0-spa-js.production.esm-CEI5Uihg.cjs +5 -0
  5. package/dist/auth0-spa-js.production.esm-CEI5Uihg.cjs.map +1 -0
  6. package/dist/components/3d-viewport/CoordinateSystemTransform.d.ts +1 -1
  7. package/dist/components/3d-viewport/CoordinateSystemTransform.d.ts.map +1 -1
  8. package/dist/components/3d-viewport/SafetyZonesRenderer.d.ts.map +1 -1
  9. package/dist/components/3d-viewport/collider/ColliderCollection.d.ts +1 -1
  10. package/dist/components/3d-viewport/collider/ColliderCollection.d.ts.map +1 -1
  11. package/dist/components/3d-viewport/collider/ColliderElement.d.ts +1 -1
  12. package/dist/components/3d-viewport/collider/ColliderElement.d.ts.map +1 -1
  13. package/dist/components/3d-viewport/collider/CollisionSceneRenderer.d.ts +1 -1
  14. package/dist/components/3d-viewport/collider/CollisionSceneRenderer.d.ts.map +1 -1
  15. package/dist/components/3d-viewport/collider/colliderShapeToBufferGeometry.d.ts +1 -1
  16. package/dist/components/3d-viewport/collider/colliderShapeToBufferGeometry.d.ts.map +1 -1
  17. package/dist/components/ProgramStateIndicator.d.ts +3 -3
  18. package/dist/components/ProgramStateIndicator.d.ts.map +1 -1
  19. package/dist/components/RobotCard.d.ts +4 -3
  20. package/dist/components/RobotCard.d.ts.map +1 -1
  21. package/dist/components/jogging/JoggingBlocked.d.ts +7 -0
  22. package/dist/components/jogging/JoggingBlocked.d.ts.map +1 -0
  23. package/dist/components/jogging/JoggingCartesianTab.d.ts.map +1 -1
  24. package/dist/components/jogging/JoggingJointTab.d.ts.map +1 -1
  25. package/dist/components/jogging/JoggingPanel.d.ts +1 -1
  26. package/dist/components/jogging/JoggingPanel.d.ts.map +1 -1
  27. package/dist/components/jogging/JoggingStore.d.ts +10 -5
  28. package/dist/components/jogging/JoggingStore.d.ts.map +1 -1
  29. package/dist/components/jogging/PoseCartesianValues.d.ts +2 -2
  30. package/dist/components/jogging/PoseCartesianValues.d.ts.map +1 -1
  31. package/dist/components/jogging/PoseJointValues.d.ts +1 -2
  32. package/dist/components/jogging/PoseJointValues.d.ts.map +1 -1
  33. package/dist/components/robots/DHRobot.d.ts.map +1 -1
  34. package/dist/components/robots/Robot.d.ts +1 -1
  35. package/dist/components/robots/Robot.d.ts.map +1 -1
  36. package/dist/components/robots/RobotAnimator.d.ts +2 -2
  37. package/dist/components/robots/RobotAnimator.d.ts.map +1 -1
  38. package/dist/components/robots/SupportedRobot.d.ts +3 -3
  39. package/dist/components/robots/SupportedRobot.d.ts.map +1 -1
  40. package/dist/components/robots/manufacturerHomePositions.d.ts +1 -1
  41. package/dist/components/robots/manufacturerHomePositions.d.ts.map +1 -1
  42. package/dist/components/safetyBar/OperationModeIndicator.d.ts +2 -2
  43. package/dist/components/safetyBar/OperationModeIndicator.d.ts.map +1 -1
  44. package/dist/components/safetyBar/SafetyBar.d.ts +3 -3
  45. package/dist/components/safetyBar/SafetyBar.d.ts.map +1 -1
  46. package/dist/components/safetyBar/SafetyStateIndicator.d.ts +2 -2
  47. package/dist/components/safetyBar/SafetyStateIndicator.d.ts.map +1 -1
  48. package/dist/components/utils/errorHandling.d.ts.map +1 -1
  49. package/dist/components/utils/errorHandling.test.d.ts +2 -0
  50. package/dist/components/utils/errorHandling.test.d.ts.map +1 -0
  51. package/dist/index.cjs +48 -50
  52. package/dist/index.cjs.map +1 -1
  53. package/dist/index.js +14058 -18706
  54. package/dist/index.js.map +1 -1
  55. package/dist/lib/ConnectedMotionGroup.d.ts +90 -0
  56. package/dist/lib/ConnectedMotionGroup.d.ts.map +1 -0
  57. package/dist/lib/JoggerConnection.d.ts +113 -0
  58. package/dist/lib/JoggerConnection.d.ts.map +1 -0
  59. package/dist/lib/JoggerConnection.test.d.ts +2 -0
  60. package/dist/lib/JoggerConnection.test.d.ts.map +1 -0
  61. package/dist/lib/MotionStreamConnection.d.ts +24 -0
  62. package/dist/lib/MotionStreamConnection.d.ts.map +1 -0
  63. package/dist/lib/MotionStreamConnection.test.d.ts +2 -0
  64. package/dist/lib/MotionStreamConnection.test.d.ts.map +1 -0
  65. package/dist/lib/motionStateUpdate.d.ts +7 -0
  66. package/dist/lib/motionStateUpdate.d.ts.map +1 -0
  67. package/dist/lib/motionStateUpdate.test.d.ts +2 -0
  68. package/dist/lib/motionStateUpdate.test.d.ts.map +1 -0
  69. package/package.json +2 -2
  70. package/src/components/3d-viewport/CoordinateSystemTransform.tsx +1 -1
  71. package/src/components/3d-viewport/SafetyZonesRenderer.tsx +1 -2
  72. package/src/components/3d-viewport/collider/ColliderCollection.tsx +1 -1
  73. package/src/components/3d-viewport/collider/ColliderElement.tsx +1 -1
  74. package/src/components/3d-viewport/collider/CollisionSceneRenderer.tsx +1 -1
  75. package/src/components/3d-viewport/collider/colliderShapeToBufferGeometry.ts +1 -1
  76. package/src/components/ProgramStateIndicator.tsx +3 -6
  77. package/src/components/RobotCard.tsx +4 -7
  78. package/src/components/jogging/JoggingBlocked.tsx +37 -0
  79. package/src/components/jogging/JoggingCartesianTab.tsx +13 -11
  80. package/src/components/jogging/JoggingJointLimitDetector.tsx +2 -2
  81. package/src/components/jogging/JoggingJointTab.tsx +4 -3
  82. package/src/components/jogging/JoggingPanel.tsx +6 -3
  83. package/src/components/jogging/JoggingStore.ts +66 -39
  84. package/src/components/jogging/PoseCartesianValues.tsx +3 -4
  85. package/src/components/jogging/PoseJointValues.tsx +3 -4
  86. package/src/components/robots/DHRobot.tsx +2 -3
  87. package/src/components/robots/Robot.tsx +1 -1
  88. package/src/components/robots/RobotAnimator.test.tsx +7 -22
  89. package/src/components/robots/RobotAnimator.tsx +8 -13
  90. package/src/components/robots/SupportedRobot.tsx +3 -6
  91. package/src/components/robots/manufacturerHomePositions.ts +1 -1
  92. package/src/components/safetyBar/OperationModeIndicator.tsx +2 -2
  93. package/src/components/safetyBar/SafetyBar.tsx +3 -6
  94. package/src/components/safetyBar/SafetyStateIndicator.tsx +2 -2
  95. package/src/components/utils/errorHandling.test.ts +41 -0
  96. package/src/components/utils/errorHandling.ts +4 -0
  97. package/src/i18n/locales/de/translations.json +3 -0
  98. package/src/i18n/locales/en/translations.json +3 -0
  99. package/src/lib/ConnectedMotionGroup.ts +444 -0
  100. package/src/lib/JoggerConnection.test.ts +120 -0
  101. package/src/lib/JoggerConnection.ts +674 -0
  102. package/src/lib/MotionStreamConnection.test.ts +23 -0
  103. package/src/lib/MotionStreamConnection.ts +186 -0
  104. package/src/lib/motionStateUpdate.test.ts +28 -0
  105. package/src/lib/motionStateUpdate.ts +117 -0
  106. package/dist/auth0-spa-js.production.esm-1QXzndwB.js +0 -950
  107. package/dist/auth0-spa-js.production.esm-1QXzndwB.js.map +0 -1
  108. package/dist/auth0-spa-js.production.esm-BLRAk7Yh.cjs +0 -5
  109. package/dist/auth0-spa-js.production.esm-BLRAk7Yh.cjs.map +0 -1
@@ -0,0 +1,90 @@
1
+ import { type AutoReconnectingWebsocket } from "@wandelbots/nova-js";
2
+ import type { MotionGroupDescription, MotionGroupState, NovaClient, RobotControllerState } from "@wandelbots/nova-js/v2";
3
+ import * as THREE from "three";
4
+ import type { Vector3Simple } from "./JoggerConnection";
5
+ export type RobotTcpLike = {
6
+ id: string;
7
+ readable_name: string;
8
+ position: Vector3Simple;
9
+ orientation: Vector3Simple;
10
+ };
11
+ export type MotionGroupOption = {
12
+ selectionId: string;
13
+ };
14
+ /**
15
+ * Store representing the current state of a connected motion group.
16
+ * API v2 version, not used yet in the components.
17
+ */
18
+ export declare class ConnectedMotionGroup {
19
+ readonly nova: NovaClient;
20
+ readonly controller: RobotControllerState;
21
+ readonly motionGroup: MotionGroupState;
22
+ readonly initialMotionState: MotionGroupState;
23
+ readonly motionStateSocket: AutoReconnectingWebsocket;
24
+ readonly isVirtual: boolean;
25
+ readonly tcps: RobotTcpLike[];
26
+ readonly description: MotionGroupDescription;
27
+ readonly initialControllerState: RobotControllerState;
28
+ readonly controllerStateSocket: AutoReconnectingWebsocket;
29
+ static connectMultiple(nova: NovaClient, motionGroupIds: string[]): Promise<ConnectedMotionGroup[]>;
30
+ static connect(nova: NovaClient, motionGroupId: string): Promise<ConnectedMotionGroup>;
31
+ connectedJoggingSocket: WebSocket | null;
32
+ planData: any | null;
33
+ joggingVelocity: number;
34
+ rapidlyChangingMotionState: MotionGroupState;
35
+ controllerState: RobotControllerState;
36
+ /**
37
+ * Reflects activation state of the motion group / robot servos. The
38
+ * movement controls in the UI should only be enabled in the "active" state
39
+ */
40
+ activationState: "inactive" | "activating" | "deactivating" | "active";
41
+ constructor(nova: NovaClient, controller: RobotControllerState, motionGroup: MotionGroupState, initialMotionState: MotionGroupState, motionStateSocket: AutoReconnectingWebsocket, isVirtual: boolean, tcps: RobotTcpLike[], description: MotionGroupDescription, initialControllerState: RobotControllerState, controllerStateSocket: AutoReconnectingWebsocket);
42
+ get motionGroupId(): string;
43
+ get controllerId(): string;
44
+ get modelFromController(): string;
45
+ get wandelscriptIdentifier(): string;
46
+ /** Jogging velocity in radians for rotation and joint movement */
47
+ get joggingVelocityRads(): number;
48
+ get joints(): {
49
+ index: number;
50
+ }[];
51
+ get dhParameters(): {
52
+ alpha?: number;
53
+ theta?: number;
54
+ a?: number;
55
+ d?: number;
56
+ reverse_rotation_direction?: boolean;
57
+ }[] | undefined;
58
+ get safetyZones(): {
59
+ [key: string]: import("@wandelbots/nova-api/v2").Collider;
60
+ } | undefined;
61
+ /** Gets the robot mounting position offset in 3D viz coordinates */
62
+ get mountingPosition(): [number, number, number];
63
+ /** Gets the robot mounting position rotation in 3D viz coordinates */
64
+ get mountingQuaternion(): THREE.Quaternion;
65
+ /**
66
+ * Whether the controller is currently in a safety state
67
+ * corresponding to an emergency stop
68
+ */
69
+ get isEstopActive(): boolean;
70
+ /**
71
+ * Whether the controller is in a safety state
72
+ * that may be non-functional for robot pad purposes
73
+ */
74
+ get isMoveableSafetyState(): boolean;
75
+ /**
76
+ * Whether the controller is in an operation mode that allows movement
77
+ */
78
+ get isMoveableOperationMode(): boolean;
79
+ /**
80
+ * Whether the robot is currently active and can be moved, based on the
81
+ * safety state, operation mode and servo toggle activation state.
82
+ */
83
+ get canBeMoved(): boolean;
84
+ deactivate(): Promise<void>;
85
+ activate(): Promise<void>;
86
+ toggleActivation(): void;
87
+ dispose(): void;
88
+ setJoggingVelocity(velocity: number): void;
89
+ }
90
+ //# sourceMappingURL=ConnectedMotionGroup.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ConnectedMotionGroup.d.ts","sourceRoot":"","sources":["../../src/lib/ConnectedMotionGroup.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,yBAAyB,EAC/B,MAAM,qBAAqB,CAAA;AAC5B,OAAO,KAAK,EAEV,sBAAsB,EACtB,gBAAgB,EAChB,UAAU,EAEV,oBAAoB,EAErB,MAAM,wBAAwB,CAAA;AAE/B,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAA;AAKvD,MAAM,MAAM,YAAY,GAAG;IACzB,EAAE,EAAE,MAAM,CAAA;IACV,aAAa,EAAE,MAAM,CAAA;IACrB,QAAQ,EAAE,aAAa,CAAA;IACvB,WAAW,EAAE,aAAa,CAAA;CAC3B,CAAA;AAED,MAAM,MAAM,iBAAiB,GAAG;IAC9B,WAAW,EAAE,MAAM,CAAA;CACpB,CAAA;AAUD;;;GAGG;AACH,qBAAa,oBAAoB;IA8H7B,QAAQ,CAAC,IAAI,EAAE,UAAU;IACzB,QAAQ,CAAC,UAAU,EAAE,oBAAoB;IACzC,QAAQ,CAAC,WAAW,EAAE,gBAAgB;IACtC,QAAQ,CAAC,kBAAkB,EAAE,g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E,MAAM,CAAC,CAU/C;IAED,sEAAsE;IACtE,IAAI,kBAAkB,qBAWrB;IAED;;;OAGG;IACH,IAAI,aAAa,YAOhB;IAED;;;OAGG;IACH,IAAI,qBAAqB,YAOxB;IAED;;OAEG;IACH,IAAI,uBAAuB,YAS1B;IAED;;;OAGG;IACH,IAAI,UAAU,YAMb;IAEK,UAAU;IA2BV,QAAQ;IA2Bd,gBAAgB;IAQhB,OAAO;IAKP,kBAAkB,CAAC,QAAQ,EAAE,MAAM;CAGpC"}
@@ -0,0 +1,113 @@
1
+ import { AutoReconnectingWebsocket } from "@wandelbots/nova-js";
2
+ import type { NovaClient, Pose } from "@wandelbots/nova-js/v2";
3
+ import { MotionStreamConnection } from "./MotionStreamConnection";
4
+ export type Vector3Simple = [number, number, number];
5
+ export type JoggerConnectionOptions = {
6
+ mode?: JoggerMode;
7
+ timeout?: number;
8
+ /**
9
+ * When an error message is received from the jogging websocket, it
10
+ * will be passed here. If this handler is not provided, the error will
11
+ * instead be thrown as an unhandled error.
12
+ */
13
+ onError?: (err: unknown) => void;
14
+ tcp?: string;
15
+ orientation?: JoggerOrientation;
16
+ };
17
+ export type JoggerMode = "jogging" | "trajectory" | "off";
18
+ export type JoggerOrientation = "coordsys" | "tool";
19
+ export declare class JoggerConnection {
20
+ readonly motionStream: MotionStreamConnection;
21
+ readonly options: JoggerConnectionOptions | undefined;
22
+ ENDPOINT_JOGGING: string;
23
+ ENDPOINT_TRAJECTORY: string;
24
+ DEFAULT_MODE: JoggerMode;
25
+ DEFAULT_TCP: string;
26
+ DEFAULT_INIT_TIMEOUT: number;
27
+ DEFAULT_ORIENTATION: JoggerOrientation;
28
+ mode: JoggerMode;
29
+ joggingSocket: AutoReconnectingWebsocket | null;
30
+ trajectorySocket: AutoReconnectingWebsocket | null;
31
+ timeout: number;
32
+ tcp: string;
33
+ orientation: JoggerOrientation;
34
+ onError?: (err: unknown) => void;
35
+ onBlocked?: () => void;
36
+ /**
37
+ * Initialize the jogging connection using jogging endpoint or trajectory endpoint depending on the selected mode.
38
+ *
39
+ * @param nova - The Nova client instance
40
+ * @param motionGroupId - The ID of the motion group to connect to
41
+ * @param options - Configuration options for the jogger connection
42
+ * @param options.mode - The jogging mode to initialize:
43
+ * - "jogging": Continuous jogging mode with persistent websocket for real-time velocity commands
44
+ * - "trajectory": Incremental jogging mode for fixed-distance motions via trajectory planning
45
+ * - "off": No jogging enabled, all websockets closed (default)
46
+ * @param options.timeout - Timeout in milliseconds for websocket initialization (default: 5000ms)
47
+ * @param options.tcp - TCP frame to use for motions (default: from motion group)
48
+ * //param options.coordinateSystem - Coordinate system for jogging commands (default: "world"). Please note: Currently not implemented
49
+ * @param options.orientation - If set to "tool", jogging TcpVelocityRequest will use `use_tool_coordinate_system` option (default: "coordsys")
50
+ * @param options.onError - Error handler for websocket errors
51
+ * @returns Promise resolving to initialized JoggerConnection instance
52
+ */
53
+ static open(nova: NovaClient, motionGroupId: string, options?: JoggerConnectionOptions): Promise<JoggerConnection>;
54
+ constructor(motionStream: MotionStreamConnection, options?: JoggerConnectionOptions | undefined);
55
+ setOptions(options: Partial<JoggerConnectionOptions>): Promise<void>;
56
+ get motionGroupId(): string;
57
+ get nova(): NovaClient;
58
+ get numJoints(): number;
59
+ stop(): Promise<void>;
60
+ dispose(): Promise<void[]>;
61
+ setJoggingMode(mode: JoggerMode, skipReinitializeIfSameMode?: boolean): Promise<void>;
62
+ initializeJoggingWebsocket(): Promise<void>;
63
+ /**
64
+ * Jogging: Start rotation of a single robot joint at the specified velocity
65
+ */
66
+ rotateJoints({ joint, direction, velocityRadsPerSec, }: {
67
+ /** Index of the joint to rotate */
68
+ joint: number;
69
+ /** Direction of rotation ("+" or "-") */
70
+ direction: "+" | "-";
71
+ /** Speed of the rotation in radians per second */
72
+ velocityRadsPerSec: number;
73
+ }): Promise<void>;
74
+ /**
75
+ * Jogging: Start the TCP moving along a specified axis at a given velocity
76
+ */
77
+ translateTCP({ axis, direction, velocityMmPerSec, }: {
78
+ axis: "x" | "y" | "z";
79
+ direction: "-" | "+";
80
+ velocityMmPerSec: number;
81
+ }): Promise<void>;
82
+ /**
83
+ * Jogging: Start the TCP rotating around a specified axis at a given velocity
84
+ */
85
+ rotateTCP({ axis, direction, velocityRadsPerSec, }: {
86
+ axis: "x" | "y" | "z";
87
+ direction: "-" | "+";
88
+ velocityRadsPerSec: number;
89
+ }): Promise<void>;
90
+ /**
91
+ * Trajectory jogging:
92
+ *
93
+ * Move the robot by a fixed distance in a single cartesian
94
+ * axis, either rotating or translating relative to the TCP.
95
+ * Promise resolves only after the motion has completed.
96
+ */
97
+ runIncrementalCartesianMotion({ currentTcpPose, currentJoints, velocityInRelevantUnits, axis, direction, motion, }: {
98
+ currentTcpPose: Pose;
99
+ currentJoints: Vector3Simple;
100
+ coordSystemId: string;
101
+ velocityInRelevantUnits: number;
102
+ axis: "x" | "y" | "z";
103
+ direction: "-" | "+";
104
+ motion: {
105
+ type: "rotate";
106
+ distanceRads: number;
107
+ } | {
108
+ type: "translate";
109
+ distanceMm: number;
110
+ };
111
+ }): Promise<void>;
112
+ }
113
+ //# sourceMappingURL=JoggerConnection.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"JoggerConnection.d.ts","sourceRoot":"","sources":["../../src/lib/JoggerConnection.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,yBAAyB,EAG1B,MAAM,qBAAqB,CAAA;AAC5B,OAAO,KAAK,EAGV,UAAU,EACV,IAAI,EAEL,MAAM,wBAAwB,CAAA;AAG/B,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AAEjE,MAAM,MAAM,aAAa,GAAG,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,CAAA;AAIpD,MAAM,MAAM,uBAAuB,GAAG;IAEpC,IAAI,CAAC,EAAE,UAAU,CAAA;IAGjB,OAAO,CAAC,EAAE,MAAM,CAAA;IAEhB;;;;OAIG;IACH,OAAO,CAAC,EAAE,CAAC,GAAG,EAAE,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//# sourceMappingURL=JoggerConnection.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"JoggerConnection.test.d.ts","sourceRoot":"","sources":["../../src/lib/JoggerConnection.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,24 @@
1
+ import { AutoReconnectingWebsocket } from "@wandelbots/nova-js";
2
+ import type { MotionGroupDescription, MotionGroupState, NovaClient, RobotControllerState } from "@wandelbots/nova-js/v2";
3
+ /**
4
+ * Store representing the current state of a connected motion group.
5
+ */
6
+ export declare class MotionStreamConnection {
7
+ readonly nova: NovaClient;
8
+ readonly controller: RobotControllerState;
9
+ readonly motionGroup: MotionGroupState;
10
+ readonly description: MotionGroupDescription;
11
+ readonly initialMotionState: MotionGroupState;
12
+ readonly motionStateSocket: AutoReconnectingWebsocket;
13
+ static open(nova: NovaClient, motionGroupId: string): Promise<MotionStreamConnection>;
14
+ rapidlyChangingMotionState: MotionGroupState;
15
+ constructor(nova: NovaClient, controller: RobotControllerState, motionGroup: MotionGroupState, description: MotionGroupDescription, initialMotionState: MotionGroupState, motionStateSocket: AutoReconnectingWebsocket);
16
+ get motionGroupId(): string;
17
+ get controllerId(): string;
18
+ get wandelscriptIdentifier(): string;
19
+ get joints(): {
20
+ index: number;
21
+ }[];
22
+ dispose(): void;
23
+ }
24
+ //# sourceMappingURL=MotionStreamConnection.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MotionStreamConnection.d.ts","sourceRoot":"","sources":["../../src/lib/MotionStreamConnection.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAgB,MAAM,qBAAqB,CAAA;AAC7E,OAAO,KAAK,EACV,sBAAsB,EACtB,gBAAgB,EAChB,UAAU,EACV,oBAAoB,EACrB,MAAM,wBAAwB,CAAA;AAW/B;;GAEG;AACH,qBAAa,sBAAsB;IA2D/B,QAAQ,CAAC,IAAI,EAAE,UAAU;IACzB,QAAQ,CAAC,UAAU,EAAE,oBAAoB;IACzC,QAAQ,CAAC,WAAW,EAAE,gBAAgB;IACtC,QAAQ,CAAC,WAAW,EAAE,sBAAsB;IAC5C,QAAQ,CAAC,kBAAkB,EAAE,gBAAgB;IAC7C,QAAQ,CAAC,iBAAiB,EAAE,yBAAyB;WA/D1C,IAAI,CAAC,IAAI,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM;IAuDzD,0BAA0B,EAAE,gBAAgB,CAAA;gBAGjC,IAAI,EAAE,UAAU,EAChB,UAAU,EAAE,oBAAoB,EAChC,WAAW,EAAE,gBAAgB,EAC7B,WAAW,EAAE,sBAAsB,EACnC,kBAAkB,EAAE,gBAAgB,EACpC,iBAAiB,EAAE,yBAAyB;IA6EvD,IAAI,aAAa,WAEhB;IAED,IAAI,YAAY,WAEf;IAED,IAAI,sBAAsB,WAGzB;IAED,IAAI,MAAM;;QAMT;IAED,OAAO;CAGR"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=MotionStreamConnection.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MotionStreamConnection.test.d.ts","sourceRoot":"","sources":["../../src/lib/MotionStreamConnection.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,7 @@
1
+ import type { MotionGroupState, Pose } from "@wandelbots/nova-js/v2";
2
+ import type { Vector3Simple } from "./JoggerConnection";
3
+ export declare function jointValuesEqual(oldJointValues: number[], newJointValues: number[], changeDeltaThreshold: number): boolean;
4
+ export declare function poseEqual(oldTcp: Pose | undefined, newTcp: Pose | undefined, changeDeltaThreshold: number): boolean;
5
+ export declare function tcpMotionEqual(oldMotionState: MotionGroupState, newMotionState: MotionGroupState, changeDeltaThreshold: number): boolean;
6
+ export declare function unwrapRotationVector(newRotationVectorApi: Vector3Simple, currentRotationVectorApi: Vector3Simple): Vector3Simple;
7
+ //# sourceMappingURL=motionStateUpdate.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"motionStateUpdate.d.ts","sourceRoot":"","sources":["../../src/lib/motionStateUpdate.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,IAAI,EAAE,MAAM,wBAAwB,CAAA;AACpE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAA;AAGvD,wBAAgB,gBAAgB,CAC9B,cAAc,EAAE,MAAM,EAAE,EACxB,cAAc,EAAE,MAAM,EAAE,EACxB,oBAAoB,EAAE,MAAM,GAC3B,OAAO,CAgBT;AAED,wBAAgB,SAAS,CACvB,MAAM,EAAE,IAAI,GAAG,SAAS,EACxB,MAAM,EAAE,IAAI,GAAG,SAAS,EACxB,oBAAoB,EAAE,MAAM,GAC3B,OAAO,CA8BT;AAGD,wBAAgB,cAAc,CAC5B,cAAc,EAAE,gBAAgB,EAChC,cAAc,EAAE,gBAAgB,EAChC,oBAAoB,EAAE,MAAM,GAC3B,OAAO,CAUT;AAED,wBAAgB,oBAAoB,CAClC,oBAAoB,EAAE,aAAa,EACnC,wBAAwB,EAAE,aAAa,GACtC,aAAa,CAkCf"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=motionStateUpdate.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"motionStateUpdate.test.d.ts","sourceRoot":"","sources":["../../src/lib/motionStateUpdate.test.ts"],"names":[],"mappings":""}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wandelbots/wandelbots-js-react-components",
3
- "version": "2.54.5",
3
+ "version": "3.0.0",
4
4
  "description": "React UI toolkit for building applications on top of the Wandelbots platform",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -70,7 +70,7 @@
70
70
  "@types/react": "^19.1.8",
71
71
  "@types/three": "^0.174.0",
72
72
  "@vitejs/plugin-react": "^4.3.4",
73
- "@wandelbots/nova-js": "^2.1.0",
73
+ "@wandelbots/nova-js": "3.3.1",
74
74
  "add": "^2.0.6",
75
75
  "eslint-plugin-storybook": "^10.0.1",
76
76
  "glob": "^11.0.1",
@@ -1,4 +1,4 @@
1
- import type { CoordinateSystem } from "@wandelbots/nova-api/v1"
1
+ import type { CoordinateSystem } from "@wandelbots/nova-js/v1"
2
2
  import type { ReactNode } from "react"
3
3
  import { Quaternion, Vector3 } from "three"
4
4
 
@@ -1,6 +1,5 @@
1
1
  import { type ThreeElements } from "@react-three/fiber"
2
- import type { Geometry } from "@wandelbots/nova-api/v1"
3
- import type { SafetySetupSafetyZone } from "@wandelbots/nova-js/v1"
2
+ import type { Geometry, SafetySetupSafetyZone } from "@wandelbots/nova-js/v1"
4
3
  import * as THREE from "three"
5
4
  import { ConvexGeometry } from "three-stdlib"
6
5
 
@@ -1,5 +1,5 @@
1
1
  import type { ThreeElements } from "@react-three/fiber"
2
- import type { Collider } from "@wandelbots/nova-api/v1"
2
+ import type { Collider } from "@wandelbots/nova-js/v1"
3
3
  import ColliderElement from "./ColliderElement"
4
4
 
5
5
  export type MeshChildrenProvider = (
@@ -1,4 +1,4 @@
1
- import type { Collider } from "@wandelbots/nova-api/v1"
1
+ import type { Collider } from "@wandelbots/nova-js/v1"
2
2
  import type React from "react"
3
3
  import * as THREE from "three"
4
4
  import { colliderShapeToBufferGeometry } from "./colliderShapeToBufferGeometry"
@@ -1,4 +1,4 @@
1
- import type { CollisionScene } from "@wandelbots/nova-api/v1"
1
+ import type { CollisionScene } from "@wandelbots/nova-js/v1"
2
2
  import ColliderCollection, {
3
3
  type MeshChildrenProvider,
4
4
  } from "./ColliderCollection"
@@ -1,4 +1,4 @@
1
- import type { ColliderShape } from "@wandelbots/nova-api/v1"
1
+ import type { ColliderShape } from "@wandelbots/nova-js/v1"
2
2
  import * as THREE from "three"
3
3
  import { ConvexGeometry } from "three-stdlib"
4
4
 
@@ -1,8 +1,5 @@
1
1
  import { Chip, Typography, useTheme } from "@mui/material"
2
- import type {
3
- RobotControllerStateOperationModeEnum,
4
- RobotControllerStateSafetyStateEnum,
5
- } from "@wandelbots/nova-js/v1"
2
+ import type { OperationMode, SafetyStateType } from "@wandelbots/nova-js/v2"
6
3
  import { observer } from "mobx-react-lite"
7
4
  import { useTranslation } from "react-i18next"
8
5
  import { externalizeComponent } from "../externalizeComponent"
@@ -12,9 +9,9 @@ export interface ProgramStateIndicatorProps {
12
9
  /** The current state of the program */
13
10
  programState: ProgramState
14
11
  /** The current safety state of the robot controller */
15
- safetyState: RobotControllerStateSafetyStateEnum
12
+ safetyState: SafetyStateType
16
13
  /** The current operation mode of the robot controller */
17
- operationMode: RobotControllerStateOperationModeEnum
14
+ operationMode: OperationMode
18
15
  /** Additional CSS class name */
19
16
  className?: string
20
17
  }
@@ -1,16 +1,13 @@
1
1
  import { Box, Button, Card, Divider, Typography, useTheme } from "@mui/material"
2
2
  import { Bounds } from "@react-three/drei"
3
3
  import { Canvas } from "@react-three/fiber"
4
- import type {
5
- ConnectedMotionGroup,
6
- RobotControllerStateOperationModeEnum,
7
- RobotControllerStateSafetyStateEnum,
8
- } from "@wandelbots/nova-js/v1"
4
+ import type { OperationMode, SafetyStateType } from "@wandelbots/nova-js/v2"
9
5
  import { observer } from "mobx-react-lite"
10
6
  import { useCallback, useEffect, useRef, useState } from "react"
11
7
  import { useTranslation } from "react-i18next"
12
8
  import type { Group } from "three"
13
9
  import { externalizeComponent } from "../externalizeComponent"
10
+ import type { ConnectedMotionGroup } from "../lib/ConnectedMotionGroup"
14
11
  import { PresetEnvironment } from "./3d-viewport/PresetEnvironment"
15
12
  import type { ProgramState } from "./ProgramControl"
16
13
  import { ProgramStateIndicator } from "./ProgramStateIndicator"
@@ -22,9 +19,9 @@ export interface RobotCardProps {
22
19
  /** Current program state */
23
20
  programState: ProgramState
24
21
  /** Current safety state of the robot controller */
25
- safetyState: RobotControllerStateSafetyStateEnum
22
+ safetyState: SafetyStateType
26
23
  /** Current operation mode of the robot controller */
27
- operationMode: RobotControllerStateOperationModeEnum
24
+ operationMode: OperationMode
28
25
  /** Whether the "Drive to Home" button should be enabled */
29
26
  driveToHomeEnabled?: boolean
30
27
  /** Callback fired when "Drive to Home" button is pressed */
@@ -0,0 +1,37 @@
1
+ import { Alert, AlertTitle, Backdrop, Button, Stack } from "@mui/material"
2
+ import { observer } from "mobx-react-lite"
3
+ import { useTranslation } from "react-i18next"
4
+ import { type JoggingStore } from "./JoggingStore"
5
+
6
+ export const JoggingBlocked = observer(({ store }: { store: JoggingStore }) => {
7
+ const { t } = useTranslation()
8
+
9
+ return (
10
+ <Backdrop
11
+ open={true}
12
+ sx={{
13
+ position: "absolute",
14
+ zIndex: (theme) => theme.zIndex.drawer + 1,
15
+ color: "#fff",
16
+ background: "rgba(15, 15, 15, 0.88)",
17
+ justifyContent: "flex-start",
18
+ alignItems: "flex-start",
19
+ }}
20
+ >
21
+ <Stack sx={{ m: 2, width: "100%" }}>
22
+ <Alert severity="error" sx={{ mb: 2 }}>
23
+ <AlertTitle>{t("Jogging.Blocked.ti")}</AlertTitle>
24
+ {t("Jogging.Blocked.lb")}
25
+ </Alert>
26
+
27
+ <Button
28
+ variant="contained"
29
+ color="secondary"
30
+ onClick={() => store.unblock()}
31
+ >
32
+ {t("Jogging.Blocked.Reenable.bt")}
33
+ </Button>
34
+ </Stack>
35
+ </Backdrop>
36
+ )
37
+ })
@@ -6,13 +6,18 @@ import {
6
6
  useTheme,
7
7
  type Theme,
8
8
  } from "@mui/material"
9
- import { degreesToRadians, radiansToDegrees } from "@wandelbots/nova-js"
9
+ import {
10
+ degreesToRadians,
11
+ radiansToDegrees,
12
+ XYZ_TO_VECTOR,
13
+ } from "@wandelbots/nova-js"
10
14
  import { observer } from "mobx-react-lite"
11
15
  import { useTranslation } from "react-i18next"
12
16
  import XAxisIcon from "../../icons/axis-x.svg"
13
17
  import YAxisIcon from "../../icons/axis-y.svg"
14
18
  import ZAxisIcon from "../../icons/axis-z.svg"
15
19
  import RotationIcon from "../../icons/rotation.svg"
20
+ import type { Vector3Simple } from "../../lib/JoggerConnection"
16
21
  import { useReaction } from "../utils/hooks"
17
22
  import { JoggingCartesianAxisControl } from "./JoggingCartesianAxisControl"
18
23
  import { JoggingJointLimitDetector } from "./JoggingJointLimitDetector"
@@ -56,7 +61,7 @@ export const JoggingCartesianTab = observer(
56
61
  () => {
57
62
  store.jogger.motionStream.motionStateSocket.changeUrl(
58
63
  store.jogger.nova.makeWebsocketURL(
59
- `/motion-groups/${store.jogger.motionGroupId}/state-stream?tcp=${store.selectedTcpId}&response_coordinate_system=${store.selectedCoordSystemId}`,
64
+ `/controllers/${store.jogger.motionStream.controllerId}/motion-groups/${store.jogger.motionGroupId}/state-stream?tcp=${store.selectedTcpId}`,
60
65
  ),
61
66
  )
62
67
  },
@@ -70,8 +75,8 @@ export const JoggingCartesianTab = observer(
70
75
  const jogger = await store.activate()
71
76
 
72
77
  const tcpPose = jogger.motionStream.rapidlyChangingMotionState.tcp_pose
73
- const jointPosition =
74
- jogger.motionStream.rapidlyChangingMotionState.state.joint_position
78
+ const jointPosition = jogger.motionStream.rapidlyChangingMotionState
79
+ .joint_position as Vector3Simple
75
80
  if (!tcpPose) return
76
81
 
77
82
  await store.withMotionLock(async () => {
@@ -117,13 +122,13 @@ export const JoggingCartesianTab = observer(
117
122
  }
118
123
 
119
124
  if (opts.motionType === "translate") {
120
- await store.jogger.startTCPTranslation({
125
+ await store.jogger.translateTCP({
121
126
  axis: opts.axis,
122
127
  direction: opts.direction,
123
128
  velocityMmPerSec: store.translationVelocityMmPerSec,
124
129
  })
125
130
  } else {
126
- await store.jogger.startTCPRotation({
131
+ await store.jogger.rotateTCP({
127
132
  axis: opts.axis,
128
133
  direction: opts.direction,
129
134
  velocityRadsPerSec: store.rotationVelocityRadsPerSec,
@@ -189,10 +194,7 @@ export const JoggingCartesianTab = observer(
189
194
  return (
190
195
  <Stack flexGrow={1} gap={2} sx={{ padding: "18px 24px" }}>
191
196
  <Stack gap={2}>
192
- {/* Jogging options */}
193
197
  <JoggingOptions store={store} />
194
-
195
- {/* Velocity slider */}
196
198
  <JoggingVelocitySlider store={store} />
197
199
  <Divider />
198
200
  </Stack>
@@ -257,7 +259,7 @@ export const JoggingCartesianTab = observer(
257
259
  getDisplayedValue={() =>
258
260
  formatMM(
259
261
  store.jogger.motionStream.rapidlyChangingMotionState
260
- .tcp_pose?.position[axis.id] || 0,
262
+ .tcp_pose?.position?.[XYZ_TO_VECTOR[axis.id]] || 0,
261
263
  )
262
264
  }
263
265
  startJogging={(direction: "-" | "+") =>
@@ -301,7 +303,7 @@ export const JoggingCartesianTab = observer(
301
303
  getDisplayedValue={() =>
302
304
  formatDegrees(
303
305
  store.jogger.motionStream.rapidlyChangingMotionState
304
- .tcp_pose?.orientation?.[axis.id] || 0,
306
+ .tcp_pose?.orientation?.[XYZ_TO_VECTOR[axis.id]] || 0,
305
307
  )
306
308
  }
307
309
  startJogging={(direction: "-" | "+") =>
@@ -17,14 +17,14 @@ export const JoggingJointLimitDetector = ({
17
17
  const { t } = useTranslation()
18
18
 
19
19
  const [jointLimitsReached, setJointLimitsReached] = useState(
20
- store.jogger.motionStream.rapidlyChangingMotionState.state
20
+ store.jogger.motionStream.rapidlyChangingMotionState
21
21
  .joint_limit_reached.limit_reached,
22
22
  )
23
23
  const jointLimitsReachedRef = useRef(jointLimitsReached)
24
24
 
25
25
  useAnimationFrame(() => {
26
26
  const newLimitsReached =
27
- store.jogger.motionStream.rapidlyChangingMotionState.state
27
+ store.jogger.motionStream.rapidlyChangingMotionState
28
28
  .joint_limit_reached.limit_reached
29
29
 
30
30
  if (!isEqual(jointLimitsReachedRef.current, newLimitsReached)) {
@@ -16,7 +16,7 @@ export const JoggingJointTab = observer(
16
16
  }) {
17
17
  await store.activate()
18
18
 
19
- await store.jogger.startJointRotation({
19
+ await store.jogger.rotateJoints({
20
20
  joint: opts.joint,
21
21
  direction: opts.direction,
22
22
  velocityRadsPerSec: store.rotationVelocityRadsPerSec,
@@ -42,7 +42,8 @@ export const JoggingJointTab = observer(
42
42
  <Stack alignItems="center" gap="24px">
43
43
  {store.jogger.motionStream.joints.map((joint) => {
44
44
  const jointLimits =
45
- store.motionGroupSpec.mechanical_joint_limits?.[joint.index]
45
+ store.motionGroupDescription.operation_limits.auto_limits
46
+ ?.joints?.[joint.index]?.position
46
47
  const lowerLimitDegs =
47
48
  jointLimits?.lower_limit !== undefined
48
49
  ? radiansToDegrees(jointLimits.lower_limit)
@@ -80,7 +81,7 @@ export const JoggingJointTab = observer(
80
81
  getValueDegs={() => {
81
82
  const value =
82
83
  store.jogger.motionStream.rapidlyChangingMotionState
83
- .state.joint_position.joints[joint.index]
84
+ .joint_position[joint.index]
84
85
  return value !== undefined
85
86
  ? radiansToDegrees(value)
86
87
  : undefined
@@ -1,14 +1,16 @@
1
1
  import MoveIcon from "@mui/icons-material/OpenWith"
2
2
  import ShareIcon from "@mui/icons-material/Share"
3
3
  import { Stack, Tab, Tabs, type SxProps } from "@mui/material"
4
- import { NovaClient } from "@wandelbots/nova-js/v1"
4
+ import { NovaClient } from "@wandelbots/nova-js/v2"
5
5
  import { isString } from "lodash-es"
6
6
  import { runInAction } from "mobx"
7
7
  import { observer, useLocalObservable } from "mobx-react-lite"
8
8
  import { useEffect } from "react"
9
9
  import { useTranslation } from "react-i18next"
10
10
  import { externalizeComponent } from "../../externalizeComponent"
11
+ import { JoggerConnection } from "../../lib/JoggerConnection"
11
12
  import { LoadingCover } from "../LoadingCover"
13
+ import { JoggingBlocked } from "./JoggingBlocked"
12
14
  import { JoggingCartesianTab } from "./JoggingCartesianTab"
13
15
  import { JoggingJointTab } from "./JoggingJointTab"
14
16
  import { JoggingStore } from "./JoggingStore"
@@ -58,7 +60,7 @@ export const JoggingPanel = externalizeComponent(
58
60
  try {
59
61
  let joggingStore = props.store
60
62
  if (!joggingStore) {
61
- const jogger = await nova.connectJogger(props.motionGroupId)
63
+ const jogger = await JoggerConnection.open(nova, props.motionGroupId)
62
64
  joggingStore = await JoggingStore.loadFor(jogger)
63
65
  }
64
66
  runInAction(() => {
@@ -181,7 +183,6 @@ const JoggingPanelInner = observer(
181
183
  )
182
184
  })}
183
185
  </Tabs>
184
-
185
186
  {/* Current tab content */}
186
187
  <Stack
187
188
  flexGrow={1}
@@ -190,6 +191,8 @@ const JoggingPanelInner = observer(
190
191
  >
191
192
  {renderTabContent()}
192
193
  </Stack>
194
+ {/* Overlay when jogging connection is blocked */}
195
+ {store.blocked && <JoggingBlocked store={store} />}
193
196
  </Stack>
194
197
  )
195
198
  },