@wandelbots/wandelbots-js-react-components 4.7.1 → 4.7.2-pr.dev-RB-3348-v1-clean-up.560.cbf9c17

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 +11 -32
  2. package/dist/3d-BOCs0RwR.cjs +2 -0
  3. package/dist/3d-BOCs0RwR.cjs.map +1 -0
  4. package/dist/3d-BTtdSlR9.js +1206 -0
  5. package/dist/3d-BTtdSlR9.js.map +1 -0
  6. package/dist/3d.cjs.js +1 -2
  7. package/dist/3d.esm.js +2 -0
  8. package/dist/auth0-spa-js.production.esm-8ppNz0la.js +5007 -0
  9. package/dist/auth0-spa-js.production.esm-8ppNz0la.js.map +1 -0
  10. package/dist/auth0-spa-js.production.esm-cNFf2AtX.cjs +5 -0
  11. package/dist/auth0-spa-js.production.esm-cNFf2AtX.cjs.map +1 -0
  12. package/dist/components/3d-viewport/CoordinateSystemTransform.d.ts +1 -1
  13. package/dist/components/3d-viewport/CoordinateSystemTransform.d.ts.map +1 -1
  14. package/dist/components/3d-viewport/SafetyZonesRenderer.d.ts +1 -2
  15. package/dist/components/3d-viewport/SafetyZonesRenderer.d.ts.map +1 -1
  16. package/dist/components/3d-viewport/TrajectoryRenderer.d.ts +2 -2
  17. package/dist/components/3d-viewport/TrajectoryRenderer.d.ts.map +1 -1
  18. package/dist/components/3d-viewport/collider/ColliderCollection.d.ts +1 -1
  19. package/dist/components/3d-viewport/collider/ColliderElement.d.ts +1 -1
  20. package/dist/components/3d-viewport/collider/CollisionSceneRenderer.d.ts +2 -2
  21. package/dist/components/3d-viewport/collider/colliderShapeToBufferGeometry.d.ts +1 -1
  22. package/dist/components/jogging/JoggingStore.d.ts +5 -11
  23. package/dist/components/jogging/JoggingStore.d.ts.map +1 -1
  24. package/dist/core-DtLSGTAb.js +18258 -0
  25. package/dist/core-DtLSGTAb.js.map +1 -0
  26. package/dist/core-DufB-Zu5.cjs +52 -0
  27. package/dist/core-DufB-Zu5.cjs.map +1 -0
  28. package/dist/core.cjs.js +1 -2
  29. package/dist/core.esm.js +3 -0
  30. package/dist/index.cjs.js +1 -2
  31. package/dist/index.d.ts +0 -1
  32. package/dist/index.d.ts.map +1 -1
  33. package/dist/index.esm.js +4 -0
  34. package/dist/interpolation-BmgrXVQ7.js +5859 -0
  35. package/dist/interpolation-BmgrXVQ7.js.map +1 -0
  36. package/dist/interpolation-Cz29Pgpr.cjs +8 -0
  37. package/dist/interpolation-Cz29Pgpr.cjs.map +1 -0
  38. package/dist/lib/ConnectedMotionGroup.d.ts +2 -3
  39. package/dist/lib/ConnectedMotionGroup.d.ts.map +1 -1
  40. package/dist/lib/MotionStreamConnection.d.ts +0 -1
  41. package/dist/lib/MotionStreamConnection.d.ts.map +1 -1
  42. package/dist/themes/createDarkTheme.d.ts.map +1 -1
  43. package/dist/themes/themeTypes.d.ts +0 -4
  44. package/dist/themes/themeTypes.d.ts.map +1 -1
  45. package/package.json +21 -24
  46. package/src/components/3d-viewport/CoordinateSystemTransform.tsx +29 -18
  47. package/src/components/3d-viewport/SafetyZonesRenderer.tsx +13 -96
  48. package/src/components/3d-viewport/TrajectoryRenderer.tsx +8 -8
  49. package/src/components/3d-viewport/collider/ColliderCollection.tsx +1 -1
  50. package/src/components/3d-viewport/collider/ColliderElement.tsx +1 -1
  51. package/src/components/3d-viewport/collider/CollisionSceneRenderer.tsx +2 -2
  52. package/src/components/3d-viewport/collider/colliderShapeToBufferGeometry.ts +1 -1
  53. package/src/components/jogging/JoggingStore.ts +5 -5
  54. package/src/components/utils/interpolation.test.ts +3 -3
  55. package/src/index.ts +0 -1
  56. package/src/lib/ConnectedMotionGroup.ts +0 -5
  57. package/src/lib/MotionStreamConnection.ts +0 -5
  58. package/src/themes/createDarkTheme.ts +1 -22
  59. package/src/themes/themeTypes.ts +0 -5
  60. package/dist/3d.cjs.js.map +0 -1
  61. package/dist/3d.es.js +0 -19
  62. package/dist/3d.es.js.map +0 -1
  63. package/dist/LoadingCover-B3UN1lnU.js +0 -81
  64. package/dist/LoadingCover-B3UN1lnU.js.map +0 -1
  65. package/dist/LoadingCover-DXcsXWDy.cjs +0 -2
  66. package/dist/LoadingCover-DXcsXWDy.cjs.map +0 -1
  67. package/dist/MotionGroupVisualizer-7Mw9PINy.js +0 -1366
  68. package/dist/MotionGroupVisualizer-7Mw9PINy.js.map +0 -1
  69. package/dist/MotionGroupVisualizer-C0ll-LQF.cjs +0 -2
  70. package/dist/MotionGroupVisualizer-C0ll-LQF.cjs.map +0 -1
  71. package/dist/WandelscriptEditor-6sAoniLC.cjs +0 -2
  72. package/dist/WandelscriptEditor-6sAoniLC.cjs.map +0 -1
  73. package/dist/WandelscriptEditor-kWC2VyG_.js +0 -140
  74. package/dist/WandelscriptEditor-kWC2VyG_.js.map +0 -1
  75. package/dist/auth0-spa-js.production.esm-DNao6_S5.js +0 -4064
  76. package/dist/auth0-spa-js.production.esm-DNao6_S5.js.map +0 -1
  77. package/dist/auth0-spa-js.production.esm-DaBMfOV8.cjs +0 -5
  78. package/dist/auth0-spa-js.production.esm-DaBMfOV8.cjs.map +0 -1
  79. package/dist/components/wandelscript-editor/WandelscriptEditor.d.ts +0 -16
  80. package/dist/components/wandelscript-editor/WandelscriptEditor.d.ts.map +0 -1
  81. package/dist/components/wandelscript-editor/wandelscript.tmLanguage.d.ts +0 -45
  82. package/dist/components/wandelscript-editor/wandelscript.tmLanguage.d.ts.map +0 -1
  83. package/dist/core.cjs.js.map +0 -1
  84. package/dist/core.es.js +0 -54
  85. package/dist/core.es.js.map +0 -1
  86. package/dist/externalizeComponent-B98tgTPP.cjs +0 -24
  87. package/dist/externalizeComponent-B98tgTPP.cjs.map +0 -1
  88. package/dist/externalizeComponent-BOqKMZMc.js +0 -526
  89. package/dist/externalizeComponent-BOqKMZMc.js.map +0 -1
  90. package/dist/index.cjs.js.map +0 -1
  91. package/dist/index.es.js +0 -72
  92. package/dist/index.es.js.map +0 -1
  93. package/dist/interpolation-B8AcxfdD.js +0 -7167
  94. package/dist/interpolation-B8AcxfdD.js.map +0 -1
  95. package/dist/interpolation-SWzo5zr4.cjs +0 -20
  96. package/dist/interpolation-SWzo5zr4.cjs.map +0 -1
  97. package/dist/theming-BKpqgTRM.js +0 -22360
  98. package/dist/theming-BKpqgTRM.js.map +0 -1
  99. package/dist/theming-CatQaIl_.cjs +0 -115
  100. package/dist/theming-CatQaIl_.cjs.map +0 -1
  101. package/dist/wandelscript.cjs.js +0 -2
  102. package/dist/wandelscript.cjs.js.map +0 -1
  103. package/dist/wandelscript.d.ts +0 -2
  104. package/dist/wandelscript.d.ts.map +0 -1
  105. package/dist/wandelscript.es.js +0 -5
  106. package/dist/wandelscript.es.js.map +0 -1
  107. package/src/components/wandelscript-editor/WandelscriptEditor.tsx +0 -142
  108. package/src/components/wandelscript-editor/wandelscript.tmLanguage.ts +0 -62
  109. package/src/wandelscript.ts +0 -2
@@ -42,7 +42,6 @@ export declare class ConnectedMotionGroup {
42
42
  get motionGroupId(): string;
43
43
  get controllerId(): string;
44
44
  get modelFromController(): string;
45
- get wandelscriptIdentifier(): string;
46
45
  /** Jogging velocity in radians for rotation and joint movement */
47
46
  get joggingVelocityRads(): number;
48
47
  get joints(): {
@@ -54,10 +53,10 @@ export declare class ConnectedMotionGroup {
54
53
  a?: number;
55
54
  d?: number;
56
55
  reverse_rotation_direction?: boolean;
57
- type?: import("@wandelbots/nova-api/v2").JointTypeEnum;
56
+ type?: import("@wandelbots/nova-js/v2").JointTypeEnum;
58
57
  }[] | undefined;
59
58
  get safetyZones(): {
60
- [key: string]: import("@wandelbots/nova-api/v2").Collider;
59
+ [key: string]: import("@wandelbots/nova-js/v2").Collider;
61
60
  } | undefined;
62
61
  /** Gets the robot mounting position offset in 3D viz coordinates */
63
62
  get mountingPosition(): [number, number, number];
@@ -1 +1 @@
1
- {"version":3,"file":"ConnectedMotionGroup.d.ts","sourceRoot":"","sources":["../../src/lib/ConnectedMotionGroup.ts"],"names":[],"mappings":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AGD,IAAI,EAAE,UAAU,EAChB,UAAU,EAAE,oBAAoB,EAChC,WAAW,EAAE,gBAAgB,EAC7B,kBAAkB,EAAE,gBAAgB,EACpC,iBAAiB,EAAE,yBAAyB,EAC5C,SAAS,EAAE,OAAO,EAClB,IAAI,EAAE,YAAY,EAAE,EACpB,WAAW,EAAE,sBAAsB,EACnC,sBAAsB,EAAE,oBAAoB,EAC5C,qBAAqB,EAAE,yBAAyB;IAsE3D,IAAI,aAAa,WAEhB;IAED,IAAI,YAAY,WAEf;IAED,IAAI,mBAAmB,WAEtB;IAED,kEAAkE;IAClE,IAAI,mBAAmB,WAEtB;IAED,IAAI,MAAM;;QAMT;IAGD,IAAI,YAAY;;;;;;;oBASf;IAED,IAAI,WAAW;;kBAEd;IAED,oEAAoE;IACpE,IAAI,gBAAgB,IAAI,CAAC,MAAM,EAAE,MAAM,EAAE,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"}
@@ -15,7 +15,6 @@ export declare class MotionStreamConnection {
15
15
  constructor(nova: NovaClient, controller: RobotControllerState, motionGroup: MotionGroupState, description: MotionGroupDescription, initialMotionState: MotionGroupState, motionStateSocket: AutoReconnectingWebsocket);
16
16
  get motionGroupId(): string;
17
17
  get controllerId(): string;
18
- get wandelscriptIdentifier(): string;
19
18
  get joints(): {
20
19
  index: number;
21
20
  }[];
@@ -1 +1 @@
1
- {"version":3,"file":"MotionStreamConnection.d.ts","sourceRoot":"","sources":["../../src/lib/MotionStreamConnection.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,K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AAE,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,MAAM;;QAMT;IAED,OAAO;CAGR"}
@@ -1 +1 @@
1
- {"version":3,"file":"createDarkTheme.d.ts","sourceRoot":"","sources":["../../src/themes/createDarkTheme.ts"],"names":[],"mappings":"AAAA,OAAO,EAAyB,KAAK,KAAK,EAAE,MAAM,eAAe,CAAA;AAEjE,wBAAgB,eAAe,IAAI,KAAK,CA0WvC"}
1
+ {"version":3,"file":"createDarkTheme.d.ts","sourceRoot":"","sources":["../../src/themes/createDarkTheme.ts"],"names":[],"mappings":"AAAA,OAAO,EAAyB,KAAK,KAAK,EAAE,MAAM,eAAe,CAAA;AAEjE,wBAAgB,eAAe,IAAI,KAAK,CAqVvC"}
@@ -1,4 +1,3 @@
1
- import type { editor } from "monaco-editor";
2
1
  type NovaColorPaletteExtension = {
3
2
  paletteExt?: {
4
3
  primary?: {
@@ -45,9 +44,6 @@ interface NovaComponentsExtension {
45
44
  sliderLegendColor?: string;
46
45
  };
47
46
  };
48
- WandelscriptEditor?: {
49
- monacoTheme: editor.IStandaloneThemeData;
50
- };
51
47
  };
52
48
  }
53
49
  interface BackgroundPaperElevation {
@@ -1 +1 @@
1
- {"version":3,"file":"themeTypes.d.ts","sourceRoot":"","sources":["../../src/themes/themeTypes.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,E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,CAAC,EAAE,wBAAwB,CAAA;KACpD;IAED,UAAU,cAAc;QACtB,QAAQ,CAAC,EAAE,cAAc,CAAC,SAAS,CAAC,CAAA;QACpC,wBAAwB,CAAC,EAAE,wBAAwB,CAAA;KACpD;IAED,UAAU,KAAM,SAAQ,uBAAuB,EAAE,yBAAyB;KAAG;IAE7E,UAAU,YACR,SAAQ,uBAAuB,EAC7B,yBAAyB;KAAG;CACjC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wandelbots/wandelbots-js-react-components",
3
- "version": "4.7.1",
3
+ "version": "4.7.2-pr.dev-RB-3348-v1-clean-up.560.cbf9c17",
4
4
  "description": "React UI toolkit for building applications on top of the Wandelbots platform",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -26,19 +26,14 @@
26
26
  "types": "./dist/3d.d.ts",
27
27
  "import": "./dist/3d.es.js",
28
28
  "require": "./dist/3d.cjs.js"
29
- },
30
- "./wandelscript": {
31
- "types": "./dist/wandelscript.d.ts",
32
- "import": "./dist/wandelscript.es.js",
33
- "require": "./dist/wandelscript.cjs.js"
34
29
  }
35
30
  },
36
31
  "types": "./dist/index.d.ts",
37
32
  "scripts": {
38
33
  "dev": "storybook dev -p 6006 --no-open",
39
- "dev:pack": "nodemon -V -w src -e '*' -x \"npm run build && npm pack\"",
34
+ "dev:pack": "nodemon -V -w src -e '*' -x \"pnpm run build && pnpm pack\"",
40
35
  "dev:build": "nodemon -V -w src -e '*' -x \"vite build && tsc --declaration --emitDeclarationOnly\"",
41
- "dev:wbjs": "nodemon --watch $WBJS_PATH -e tgz --exec 'npm install file:$WBJS_PATH && storybook dev -p 6006 --no-open'",
36
+ "dev:wbjs": "nodemon --watch $WBJS_PATH -e tgz --exec 'pnpm install file:$WBJS_PATH && storybook dev -p 6006 --no-open'",
42
37
  "tsc": "tsc --pretty --noEmit -p stories/tsconfig.json",
43
38
  "test": "test-storybook --url http://127.0.0.1:6006 --index-json --browsers chromium",
44
39
  "test:unit": "vitest --workspace vitest.workspace.ts --project unit",
@@ -66,7 +61,7 @@
66
61
  "license": "Apache-2.0",
67
62
  "engines": {
68
63
  "node": ">=18.14.0",
69
- "npm": ">=8.0.0"
64
+ "pnpm": ">=10.0.0"
70
65
  },
71
66
  "devDependencies": {
72
67
  "@emotion/react": "^11.14.0",
@@ -79,10 +74,11 @@
79
74
  "@rollup/plugin-commonjs": "^29.0.0",
80
75
  "@rollup/plugin-json": "^6.1.0",
81
76
  "@rollup/plugin-node-resolve": "^16.0.0",
82
- "@rollup/plugin-terser": "^0.4.4",
77
+ "@rollup/plugin-terser": "^1.0.0",
83
78
  "@rollup/plugin-typescript": "^12.1.2",
84
- "@shikijs/monaco": "^3.1.0",
79
+ "@shikijs/monaco": "^4.0.2",
85
80
  "@storybook/addon-docs": "^10.2.3",
81
+ "@storybook/react": "^10.3.5",
86
82
  "@storybook/react-vite": "^10.2.3",
87
83
  "@storybook/test-runner": "^0.24.1",
88
84
  "@svgr/rollup": "^8.1.0",
@@ -92,19 +88,20 @@
92
88
  "@types/lodash-es": "^4.17.12",
93
89
  "@types/react": "^19.1.8",
94
90
  "@types/three": "^0.182.0",
95
- "@vitejs/plugin-react": "^4.3.4",
91
+ "@vitejs/plugin-react": "^6.0.1",
96
92
  "add": "^2.0.6",
97
93
  "eslint-plugin-storybook": "^10.1.10",
98
94
  "glob": "^13.0.0",
99
95
  "http-server": "^14.1.1",
100
96
  "husky": "^9.1.7",
101
- "i18next": "^25.7.4",
97
+ "i18next": "^26.0.3",
102
98
  "jest-simple-dot-reporter": "^1.0.5",
103
99
  "jest-summary-reporter": "^0.0.2",
104
- "jsdom": "^27.4.0",
100
+ "jsdom": "^29.0.1",
105
101
  "monaco-editor": "^0.55.1",
106
102
  "nodemon": "^3.1.9",
107
103
  "npm-run-all": "^4.1.5",
104
+ "playwright": "^1.59.1",
108
105
  "postcss": "^8.5.3",
109
106
  "prettier-eslint": "^16.3.0",
110
107
  "prop-types": "^15.8.1",
@@ -117,18 +114,18 @@
117
114
  "rollup-plugin-peer-deps-external": "^2.2.4",
118
115
  "rollup-plugin-postcss": "^4.0.2",
119
116
  "semantic-release": "^25.0.2",
120
- "shiki": "^3.1.0",
117
+ "shiki": "^4.0.2",
121
118
  "storybook": "^10.2.3",
122
119
  "storybook-preset-inline-svg": "^2.0.0",
123
- "three": "^0.182.0",
120
+ "three": "^0.183.2",
124
121
  "three-stdlib": "^2.35.14",
125
122
  "ts-dedent": "^2.2.0",
126
123
  "tsx": "^4.21.0",
127
- "typescript": "^5.8.2",
128
- "unplugin": "^1.15.0",
129
- "vite": "^6.2.0",
130
- "vite-plugin-svgr": "^4.3.0",
131
- "vitest": "^3.0.7",
124
+ "typescript": "^6.0.2",
125
+ "unplugin": "^3.0.0",
126
+ "vite": "^8.0.4",
127
+ "vite-plugin-svgr": "^5.2.0",
128
+ "vitest": "^4.1.2",
132
129
  "wait-on": "^9.0.3"
133
130
  },
134
131
  "peerDependencies": {
@@ -139,10 +136,10 @@
139
136
  "@mui/material": "^6 || ^7",
140
137
  "@react-three/drei": "^9.122.0 || ^10",
141
138
  "@react-three/fiber": "^8 || ^9",
142
- "@shikijs/monaco": "^3.1.0",
139
+ "@shikijs/monaco": "^4.0.2",
143
140
  "react": "^18.0.0 || ^19.0.0",
144
141
  "react-dom": "^18.0.0 || ^19.0.0",
145
- "shiki": "^3.1.0",
142
+ "shiki": "^4.0.2",
146
143
  "three": ">=0.182",
147
144
  "three-stdlib": ">=2"
148
145
  },
@@ -183,7 +180,7 @@
183
180
  "mobx": "^6.13.6",
184
181
  "mobx-react-lite": "^4.1.0",
185
182
  "react-error-boundary": "^6.0.3",
186
- "react-i18next": "^16.5.2",
183
+ "react-i18next": "^17.0.2",
187
184
  "username": "^7.0.0"
188
185
  },
189
186
  "overrides": {
@@ -1,4 +1,4 @@
1
- import type { CoordinateSystem } from "@wandelbots/nova-js/v1"
1
+ import type { CoordinateSystem } from "@wandelbots/nova-js/v2"
2
2
  import type { ReactNode } from "react"
3
3
  import { Quaternion, Vector3 } from "three"
4
4
 
@@ -14,28 +14,39 @@ export const CoordinateSystemTransform = ({
14
14
  children: ReactNode
15
15
  }) => {
16
16
  const position = new Vector3(
17
- (coordinateSystem?.position?.x ?? 0) / 1000,
18
- (coordinateSystem?.position?.y ?? 0) / 1000,
19
- (coordinateSystem?.position?.z ?? 0) / 1000,
17
+ (coordinateSystem?.position?.[0] ?? 0) / 1000,
18
+ (coordinateSystem?.position?.[1] ?? 0) / 1000,
19
+ (coordinateSystem?.position?.[2] ?? 0) / 1000,
20
20
  )
21
21
 
22
- let rotation = coordinateSystem?.rotation
23
- const rotationType = rotation?.type
24
- if (rotationType && rotationType !== "ROTATION_VECTOR") {
25
- console.warn(
26
- `Unsupported rotation type ${rotationType}. Only ROTATION_VECTOR is supported.`,
22
+ const orientationType = coordinateSystem?.orientation_type
23
+
24
+ let quaternion: Quaternion
25
+
26
+ if (orientationType === "QUATERNION") {
27
+ quaternion = new Quaternion(
28
+ coordinateSystem?.orientation?.[0] ?? 0,
29
+ coordinateSystem?.orientation?.[1] ?? 0,
30
+ coordinateSystem?.orientation?.[2] ?? 0,
31
+ coordinateSystem?.orientation?.[3] ?? 1,
27
32
  )
28
- rotation = { type: "ROTATION_VECTOR", angles: [0, 0, 0, 0] }
33
+ } else {
34
+ if (orientationType && orientationType !== "ROTATION_VECTOR") {
35
+ console.warn(
36
+ `Unsupported orientation type ${orientationType}. Only ROTATION_VECTOR and QUATERNION are supported.`,
37
+ )
38
+ }
39
+ // Default to ROTATION_VECTOR
40
+ const rotationVector = new Vector3(
41
+ coordinateSystem?.orientation?.[0] ?? 0,
42
+ coordinateSystem?.orientation?.[1] ?? 0,
43
+ coordinateSystem?.orientation?.[2] ?? 0,
44
+ )
45
+ const magnitude = rotationVector.length()
46
+ const axis = rotationVector.normalize()
47
+ quaternion = new Quaternion().setFromAxisAngle(axis, magnitude)
29
48
  }
30
49
 
31
- const rotationVector = new Vector3(
32
- rotation?.angles[0] ?? 0,
33
- rotation?.angles[1] ?? 0,
34
- rotation?.angles[2] ?? 0,
35
- )
36
- const magnitude = rotationVector.length()
37
- const axis = rotationVector.normalize()
38
- const quaternion = new Quaternion().setFromAxisAngle(axis, magnitude)
39
50
  return (
40
51
  <group position={position} quaternion={quaternion}>
41
52
  {children}
@@ -1,4 +1,4 @@
1
- import { useEffect, useMemo } from "react"
1
+ import { useMemo } from "react"
2
2
  import { type ThreeElements } from "@react-three/fiber"
3
3
  import * as THREE from "three"
4
4
  import { ConvexGeometry, RoundedBoxGeometry } from "three-stdlib"
@@ -12,12 +12,11 @@ import type {
12
12
  Capsule,
13
13
  RectangularCapsule,
14
14
  } from "@wandelbots/nova-js/v2"
15
- import type { Geometry, SafetySetupSafetyZone } from "@wandelbots/nova-js/v1"
16
15
 
17
16
  import { dhParametersToPlaneSize, orientationToQuaternion, verticesToCoplanarity } from "../utils/converters"
18
17
 
19
18
  export type SafetyZonesRendererProps = {
20
- safetyZones: SafetySetupSafetyZone[] | MotionGroupDescription["safety_zones"]
19
+ safetyZones: MotionGroupDescription["safety_zones"]
21
20
  dhParameters?: DHParameter[]
22
21
  } & ThreeElements["group"]
23
22
 
@@ -45,14 +44,6 @@ export function SafetyZonesRenderer({
45
44
  */
46
45
  const planeSize = dhParametersToPlaneSize(dhParameters ?? [])
47
46
 
48
- /**
49
- * Warning during runtime stating the deprecation of the V1 safety zones
50
- */
51
- useEffect(() => {
52
- Array.isArray(safetyZones) &&
53
- console.warn("SafetyZonesRenderer: The support of V1 safety zones is deprecated. Please migrate to V2 safety zones.")
54
- }, [safetyZones])
55
-
56
47
  /**
57
48
  * Helper function to render plane, sphere, and capsule meshes
58
49
  * @param id number
@@ -134,13 +125,18 @@ export function SafetyZonesRenderer({
134
125
  * Basically a rounded box with a rectangular cross-section.
135
126
  */
136
127
  case "rectangular_capsule": {
137
- const shape = (zone.shape as RectangularCapsule)
128
+ const shape = zone.shape as RectangularCapsule
138
129
  const rcRadius = shape.radius / 1000
139
130
  const width = shape.sphere_center_distance_x / 1000
140
131
  const height = shape.sphere_center_distance_y / 1000
141
132
  const depth = rcRadius * 2
142
133
 
143
- geometry = <primitive object={new RoundedBoxGeometry(width, height, depth, 2, rcRadius)} attach="geometry" />
134
+ geometry = (
135
+ <primitive
136
+ object={new RoundedBoxGeometry(width, height, depth, 2, rcRadius)}
137
+ attach="geometry"
138
+ />
139
+ )
144
140
  break
145
141
  }
146
142
 
@@ -158,98 +154,19 @@ export function SafetyZonesRenderer({
158
154
  quaternion={orientationToQuaternion(orientation)}
159
155
  >
160
156
  {geometry}
161
- <meshStandardMaterial
162
- {...materialProps}
163
- polygonOffsetFactor={-id}
164
- />
157
+ <meshStandardMaterial {...materialProps} polygonOffsetFactor={-id} />
165
158
  </mesh>
166
159
  )
167
160
  }
168
161
 
169
162
  /**
170
- * Helper function to render V2 safety zones
163
+ * Helper variable render safety zones
171
164
  */
172
- const renderV2SafetyZones = () => {
165
+ const renderedSafetyZones = useMemo(() => {
173
166
  return Object.values(safetyZones ?? {}).map((zone: Collider, index: number) => {
174
167
  return renderMesh(index, zone)
175
168
  })
176
- }
177
-
178
- /**
179
- * Helper function to V1 safety zones
180
- * @deprecated this render function is to be seen as a temporary measure, as the support
181
- * for the V1 safety zones is to be removed in the future
182
- */
183
- const renderV1SafetyZones = () => {
184
- if (Array.isArray(safetyZones)) {
185
- return (safetyZones as SafetySetupSafetyZone[]).map((zone: SafetySetupSafetyZone, index) => {
186
- let geometries: Geometry[] = []
187
- if (zone.geometry) {
188
- if (zone.geometry.compound) {
189
- geometries = zone.geometry.compound.child_geometries
190
- } else if (zone.geometry.convex_hull) {
191
- geometries = [zone.geometry]
192
- }
193
- }
194
-
195
- return geometries.map((geometry, i) => {
196
- if (!geometry.convex_hull) return null
197
-
198
- const vertices = geometry.convex_hull.vertices.map(
199
- (v) => new THREE.Vector3(v.x / 1000, v.y / 1000, v.z / 1000),
200
- )
201
-
202
- // Check if the vertices are on the same plane and only define a plane
203
- // Algorithm has troubles with vertices that are on the same plane so we
204
- // add a new vertex slightly moved along the normal direction
205
- const coplanarityResult = verticesToCoplanarity(vertices)
206
-
207
- if (coplanarityResult.isCoplanar && coplanarityResult.normal) {
208
- // Add a new vertex slightly moved along the normal direction
209
- const offset = 0.0001
210
- const newVertex = new THREE.Vector3().addVectors(
211
- vertices[0],
212
- coplanarityResult.normal.multiplyScalar(offset),
213
- )
214
- vertices.push(newVertex)
215
- }
216
-
217
- let convexGeometry
218
- try {
219
- convexGeometry = new ConvexGeometry(vertices)
220
- } catch (error) {
221
- console.log("Error creating ConvexGeometry:", error)
222
- return null
223
- }
224
- return (
225
- <mesh key={`${index}-${i}`} geometry={convexGeometry}>
226
- <meshStandardMaterial
227
- key={index}
228
- attach="material"
229
- color="#009f4d"
230
- opacity={0.2}
231
- depthTest={false}
232
- depthWrite={false}
233
- transparent
234
- polygonOffset
235
- polygonOffsetFactor={-i}
236
- />
237
- </mesh>
238
- )
239
- })
240
- })
241
- }
242
- return null
243
- }
244
-
245
- /**
246
- * Helper variable to render both api versions of safety zones
247
- */
248
- const renderedSafetyZones = useMemo(() => {
249
- return Array.isArray(safetyZones)
250
- ? renderV1SafetyZones()
251
- : renderV2SafetyZones()
252
- }, [safetyZones, renderV1SafetyZones, renderV2SafetyZones])
169
+ }, [safetyZones, planeSize])
253
170
 
254
171
  return (
255
172
  <group {...props}>
@@ -1,9 +1,9 @@
1
1
  import { Line } from "@react-three/drei"
2
- import type { GetTrajectoryResponse } from "@wandelbots/nova-js/v1"
2
+ import type { Pose } from "@wandelbots/nova-js/v2"
3
3
  import * as THREE from "three"
4
4
 
5
5
  export type TrajectoryRendererProps = {
6
- trajectory: GetTrajectoryResponse
6
+ trajectory: Pose[]
7
7
  } & React.JSX.IntrinsicElements["group"]
8
8
 
9
9
  export function TrajectoryRenderer({
@@ -11,13 +11,13 @@ export function TrajectoryRenderer({
11
11
  ...props
12
12
  }: TrajectoryRendererProps) {
13
13
  const points =
14
- trajectory.trajectory
15
- ?.map((point) => {
16
- if (point.tcp_pose) {
14
+ trajectory
15
+ ?.map((pose: Pose) => {
16
+ if (pose.position?.length) {
17
17
  return new THREE.Vector3(
18
- point.tcp_pose.position.x / 1000,
19
- point.tcp_pose.position.z / 1000,
20
- -point.tcp_pose.position.y / 1000,
18
+ pose.position[0] / 1000,
19
+ pose.position[2] / 1000,
20
+ -pose.position[1] / 1000,
21
21
  )
22
22
  }
23
23
  return null
@@ -1,5 +1,5 @@
1
1
  import type { ThreeElements } from "@react-three/fiber"
2
- import type { Collider } from "@wandelbots/nova-js/v1"
2
+ import type { Collider } from "@wandelbots/nova-js/v2"
3
3
  import ColliderElement from "./ColliderElement"
4
4
 
5
5
  export type MeshChildrenProvider = (
@@ -1,4 +1,4 @@
1
- import type { Collider } from "@wandelbots/nova-js/v1"
1
+ import type { Collider } from "@wandelbots/nova-js/v2"
2
2
  import type React from "react"
3
3
  import * as THREE from "three"
4
4
  import { colliderShapeToBufferGeometry } from "./colliderShapeToBufferGeometry"
@@ -1,10 +1,10 @@
1
- import type { CollisionScene } from "@wandelbots/nova-js/v1"
1
+ import type { CollisionSetup } from "@wandelbots/nova-js/v2"
2
2
  import ColliderCollection, {
3
3
  type MeshChildrenProvider,
4
4
  } from "./ColliderCollection"
5
5
 
6
6
  type CollisionSceneRendererProps = {
7
- scene: CollisionScene
7
+ scene: CollisionSetup
8
8
  meshChildrenProvider: MeshChildrenProvider
9
9
  }
10
10
 
@@ -1,4 +1,4 @@
1
- import type { ColliderShape } from "@wandelbots/nova-js/v1"
1
+ import type { ColliderShape } from "@wandelbots/nova-js/v2"
2
2
  import * as THREE from "three"
3
3
  import { ConvexGeometry } from "three-stdlib"
4
4
 
@@ -219,7 +219,7 @@ export class JoggingStore {
219
219
  this.jogger.dispose()
220
220
  }
221
221
 
222
- get coordSystemCountByName() {
222
+ get coordSystemCountByName(): Record<string, number> {
223
223
  return countBy(this.coordSystems, (cs) => cs.name)
224
224
  }
225
225
 
@@ -328,11 +328,11 @@ export class JoggingStore {
328
328
  return discreteIncrementOptions
329
329
  }
330
330
 
331
- get incrementOptionsById() {
331
+ get incrementOptionsById(): Record<string, IncrementOption> {
332
332
  return keyBy(this.incrementOptions, (o) => o.id)
333
333
  }
334
334
 
335
- get tabsById() {
335
+ get tabsById(): Record<string, { id: TabType; label: string }> {
336
336
  return keyBy(this.tabs, (t) => t.id)
337
337
  }
338
338
 
@@ -344,7 +344,7 @@ export class JoggingStore {
344
344
  return this.tabs.indexOf(this.currentTab)
345
345
  }
346
346
 
347
- get coordSystemsById() {
347
+ get coordSystemsById(): Record<string, CoordinateSystem> {
348
348
  return keyBy(this.coordSystems, (cs) => cs.coordinate_system)
349
349
  }
350
350
 
@@ -363,7 +363,7 @@ export class JoggingStore {
363
363
  : this.selectedCoordSystemId
364
364
  }
365
365
 
366
- get tcpsById() {
366
+ get tcpsById(): Record<string, RobotTcp> {
367
367
  return keyBy(this.tcps, (tcp) => tcp.id)
368
368
  }
369
369
 
@@ -1,10 +1,10 @@
1
- import { afterEach, beforeEach, describe, expect, it, vi } from "vitest"
1
+ import { afterEach, beforeEach, describe, expect, it, type MockedFunction, vi } from "vitest"
2
2
  import { ValueInterpolator } from "./interpolation"
3
3
 
4
4
  describe("ValueInterpolator", () => {
5
5
  let interpolator: ValueInterpolator
6
- let mockOnChange: ReturnType<typeof vi.fn>
7
- let mockOnComplete: ReturnType<typeof vi.fn>
6
+ let mockOnChange: MockedFunction<(values: number[]) => void>
7
+ let mockOnComplete: MockedFunction<(values: number[]) => void>
8
8
 
9
9
  beforeEach(() => {
10
10
  mockOnChange = vi.fn()
package/src/index.ts CHANGED
@@ -1,4 +1,3 @@
1
1
  // Re-export all sub-entry points
2
2
  export * from "./3d"
3
3
  export * from "./core"
4
- export * from "./wandelscript"
@@ -258,11 +258,6 @@ export class ConnectedMotionGroup {
258
258
  return this.description.motion_group_model
259
259
  }
260
260
 
261
- get wandelscriptIdentifier() {
262
- const num = this.motionGroupId.split("@")[0]
263
- return `${this.controllerId.replace(/-/g, "_")}_${num}`
264
- }
265
-
266
261
  /** Jogging velocity in radians for rotation and joint movement */
267
262
  get joggingVelocityRads() {
268
263
  return (this.joggingVelocity * Math.PI) / 180
@@ -170,11 +170,6 @@ export class MotionStreamConnection {
170
170
  return this.controller.controller
171
171
  }
172
172
 
173
- get wandelscriptIdentifier() {
174
- const num = this.motionGroupId.split("@")[0]
175
- return `${this.controllerId.replace(/-/g, "_")}_${num}`
176
- }
177
-
178
173
  get joints() {
179
174
  return this.initialMotionState.joint_position.map((_, i) => {
180
175
  return {
@@ -338,28 +338,7 @@ export function createDarkTheme(): Theme {
338
338
  VelocitySlider: {
339
339
  sliderLegendColor: baseTheme.palette.text.primary,
340
340
  },
341
- },
342
- WandelscriptEditor: {
343
- monacoTheme: {
344
- base: "vs-dark",
345
- inherit: true,
346
- rules: [
347
- {
348
- token: "keyword",
349
- foreground: "#b349a9ff",
350
- },
351
- ],
352
- colors: {
353
- "editor.background": rgbToHex(
354
- baseTheme.palette.backgroundPaperElevation?.[5] ?? "",
355
- ),
356
- "editor.foreground": "#d4d4d4",
357
- "editorLineNumber.foreground": "#797979",
358
- "editorLineNumber.activeForeground": "#e9e9e9",
359
- "editor.lineHighlightBorder": "#e9e9e911",
360
- },
361
- },
362
- },
341
+ }
363
342
  },
364
343
  } as Theme
365
344
  }
@@ -1,5 +1,3 @@
1
- import type { editor } from "monaco-editor"
2
-
3
1
  type NovaColorPaletteExtension = {
4
2
  paletteExt?: {
5
3
  primary?: {
@@ -48,9 +46,6 @@ interface NovaComponentsExtension {
48
46
  sliderLegendColor?: string
49
47
  }
50
48
  }
51
- WandelscriptEditor?: {
52
- monacoTheme: editor.IStandaloneThemeData
53
- }
54
49
  }
55
50
  }
56
51
 
@@ -1 +0,0 @@
1
- {"version":3,"file":"3d.cjs.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}