@wandelbots/wandelbots-js-react-components 3.1.1 → 3.2.0-pr.feat-improve-exports.414.40b4b4e

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 (87) hide show
  1. package/README.md +79 -2
  2. package/dist/3d.cjs.js +2 -0
  3. package/dist/3d.cjs.js.map +1 -0
  4. package/dist/3d.d.ts +11 -0
  5. package/dist/3d.d.ts.map +1 -0
  6. package/dist/3d.es.js +16 -0
  7. package/dist/3d.es.js.map +1 -0
  8. package/dist/PoseJointValues-C3bsJdfd.js +5446 -0
  9. package/dist/PoseJointValues-C3bsJdfd.js.map +1 -0
  10. package/dist/PoseJointValues-wLOjcYDe.cjs +21 -0
  11. package/dist/PoseJointValues-wLOjcYDe.cjs.map +1 -0
  12. package/dist/ProgramStateIndicator-CTT-CAcJ.js +268 -0
  13. package/dist/ProgramStateIndicator-CTT-CAcJ.js.map +1 -0
  14. package/dist/ProgramStateIndicator-DYKBcj1s.cjs +2 -0
  15. package/dist/ProgramStateIndicator-DYKBcj1s.cjs.map +1 -0
  16. package/dist/VelocitySlider-2Zme2MN7.cjs +5 -0
  17. package/dist/VelocitySlider-2Zme2MN7.cjs.map +1 -0
  18. package/dist/VelocitySlider-QSg_8eb1.js +1906 -0
  19. package/dist/VelocitySlider-QSg_8eb1.js.map +1 -0
  20. package/dist/components/jogging/JoggingStore.d.ts +1 -1
  21. package/dist/core.cjs.js +2 -0
  22. package/dist/core.cjs.js.map +1 -0
  23. package/dist/core.d.ts +23 -0
  24. package/dist/core.d.ts.map +1 -0
  25. package/dist/core.es.js +46 -0
  26. package/dist/core.es.js.map +1 -0
  27. package/dist/createSvgIcon-BG4_bQuX.cjs +56 -0
  28. package/dist/createSvgIcon-BG4_bQuX.cjs.map +1 -0
  29. package/dist/createSvgIcon-D3GRPlVu.js +3072 -0
  30. package/dist/createSvgIcon-D3GRPlVu.js.map +1 -0
  31. package/dist/data.cjs.js +2 -0
  32. package/dist/data.cjs.js.map +1 -0
  33. package/dist/data.d.ts +4 -0
  34. package/dist/data.d.ts.map +1 -0
  35. package/dist/data.es.js +7 -0
  36. package/dist/data.es.js.map +1 -0
  37. package/dist/externalizeComponent-C12Qf79R.cjs +24 -0
  38. package/dist/externalizeComponent-C12Qf79R.cjs.map +1 -0
  39. package/dist/externalizeComponent-RpcZ_G17.js +491 -0
  40. package/dist/externalizeComponent-RpcZ_G17.js.map +1 -0
  41. package/dist/index-8UEqiXug.cjs +7 -0
  42. package/dist/index-8UEqiXug.cjs.map +1 -0
  43. package/dist/index-CQDi5W62.cjs +2 -0
  44. package/dist/index-CQDi5W62.cjs.map +1 -0
  45. package/dist/index-DSz82V23.js +1801 -0
  46. package/dist/index-DSz82V23.js.map +1 -0
  47. package/dist/index-DZubFUuo.js +4909 -0
  48. package/dist/index-DZubFUuo.js.map +1 -0
  49. package/dist/index-MyU3fVEK.cjs +50 -0
  50. package/dist/index-MyU3fVEK.cjs.map +1 -0
  51. package/dist/index-VURe0U2S.js +9443 -0
  52. package/dist/index-VURe0U2S.js.map +1 -0
  53. package/dist/index.cjs.js +2 -0
  54. package/dist/index.cjs.js.map +1 -0
  55. package/dist/index.es.js +72 -0
  56. package/dist/index.es.js.map +1 -0
  57. package/dist/interpolation-CVSmVNjc.cjs +2 -0
  58. package/dist/interpolation-CVSmVNjc.cjs.map +1 -0
  59. package/dist/interpolation-DjBX_Si-.js +138 -0
  60. package/dist/interpolation-DjBX_Si-.js.map +1 -0
  61. package/dist/jogging.cjs.js +2 -0
  62. package/dist/jogging.cjs.js.map +1 -0
  63. package/dist/jogging.d.ts +9 -0
  64. package/dist/jogging.d.ts.map +1 -0
  65. package/dist/jogging.es.js +12 -0
  66. package/dist/jogging.es.js.map +1 -0
  67. package/dist/manufacturerHomePositions-DHqcbFON.js +979 -0
  68. package/dist/manufacturerHomePositions-DHqcbFON.js.map +1 -0
  69. package/dist/manufacturerHomePositions-zd-CKEiQ.cjs +2 -0
  70. package/dist/manufacturerHomePositions-zd-CKEiQ.cjs.map +1 -0
  71. package/dist/theming-BO8z_Hpa.js +2198 -0
  72. package/dist/theming-BO8z_Hpa.js.map +1 -0
  73. package/dist/theming-D5DvGuxX.cjs +4 -0
  74. package/dist/theming-D5DvGuxX.cjs.map +1 -0
  75. package/dist/useThemeProps-P648Ox74.cjs +2 -0
  76. package/dist/useThemeProps-P648Ox74.cjs.map +1 -0
  77. package/dist/useThemeProps-jE_Qg6SI.js +40 -0
  78. package/dist/useThemeProps-jE_Qg6SI.js.map +1 -0
  79. package/package.json +24 -3
  80. package/src/3d.ts +15 -0
  81. package/src/core.ts +23 -0
  82. package/src/data.ts +4 -0
  83. package/src/jogging.ts +9 -0
  84. package/dist/index.cjs +0 -155
  85. package/dist/index.cjs.map +0 -1
  86. package/dist/index.js +0 -30530
  87. package/dist/index.js.map +0 -1
@@ -0,0 +1,2198 @@
1
+ import { j as a, e as A } from "./externalizeComponent-RpcZ_G17.js";
2
+ import { SvgIcon as q, AppBar as te, Toolbar as oe, Box as m, Typography as x, IconButton as z, alpha as U, Backdrop as ae, Menu as re, MenuItem as ne, useTheme as B, Paper as ie, Button as V, Dialog as le, DialogTitle as se, DialogContent as ce, DialogActions as de, Stack as F, Chip as pe, Divider as Z, Popover as ue, styled as ge, Fab as he, Tabs as be, Tab as me, Badge as xe, createTheme as fe, rgbToHex as ve } from "@mui/material";
3
+ import { observer as v, useLocalObservable as ye } from "mobx-react-lite";
4
+ import * as u from "react";
5
+ import { useState as I, useRef as Q, useEffect as W, useMemo as Se, forwardRef as y, lazy as Ee, Suspense as Te } from "react";
6
+ import { makeObservable as we, action as G, observable as Me, runInAction as E, makeAutoObservable as Ce } from "mobx";
7
+ import { DescriptionOutlined as ke, ContentCopy as je, ExpandLess as Oe, ExpandMore as Ae } from "@mui/icons-material";
8
+ import { a as _e, b as Re } from "./createSvgIcon-D3GRPlVu.js";
9
+ import { useTranslation as D, Trans as T } from "react-i18next";
10
+ import { c as Be, L as Ie, j as Pe, t as Le } from "./VelocitySlider-QSg_8eb1.js";
11
+ import { tryParseJson as L } from "@wandelbots/nova-js";
12
+ import * as K from "three";
13
+ const Fe = (t) => /* @__PURE__ */ a.jsx(q, { ...t, viewBox: "0 0 10 8", children: /* @__PURE__ */ a.jsx(
14
+ "path",
15
+ {
16
+ d: "M8.825 0.9125L5 4.72917L1.175 0.9125L0 2.0875L5 7.0875L10 2.0875L8.825 0.9125Z",
17
+ fill: "currentColor",
18
+ fillOpacity: "0.56"
19
+ }
20
+ ) }), Rt = A(
21
+ v((t) => {
22
+ const {
23
+ appIcon: e,
24
+ appName: o,
25
+ apps: r = [],
26
+ onAppSelect: n,
27
+ disabled: i = !1,
28
+ sx: s
29
+ } = t, [d, g] = I(null), b = !!d, h = (c) => {
30
+ g(c.currentTarget);
31
+ }, p = () => {
32
+ g(null);
33
+ }, l = (c) => {
34
+ p(), c.onClick ? c.onClick() : c.href && (window.location.href = c.href), n == null || n(c);
35
+ };
36
+ return /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
37
+ /* @__PURE__ */ a.jsx(
38
+ te,
39
+ {
40
+ position: "static",
41
+ sx: {
42
+ boxShadow: "none",
43
+ backgroundImage: "none",
44
+ "& .MuiAppBar-root": {
45
+ backgroundImage: "none",
46
+ backgroundColor: "transparent"
47
+ },
48
+ ...s
49
+ },
50
+ children: /* @__PURE__ */ a.jsxs(oe, { sx: { minHeight: "62px !important" }, children: [
51
+ /* @__PURE__ */ a.jsx(m, { sx: { mr: 1, display: "flex", alignItems: "center" }, children: e }),
52
+ /* @__PURE__ */ a.jsxs(m, { sx: { display: "flex", alignItems: "center", flexGrow: 1 }, children: [
53
+ /* @__PURE__ */ a.jsx(
54
+ x,
55
+ {
56
+ component: "h1",
57
+ sx: {
58
+ fontWeight: "bold",
59
+ fontSize: "1rem"
60
+ },
61
+ children: o
62
+ }
63
+ ),
64
+ r.length > 0 && /* @__PURE__ */ a.jsx(
65
+ z,
66
+ {
67
+ color: "inherit",
68
+ "aria-label": "switch app",
69
+ "aria-controls": "app-menu",
70
+ "aria-haspopup": "true",
71
+ onClick: h,
72
+ disabled: i,
73
+ sx: {
74
+ ml: 1,
75
+ width: 28,
76
+ height: 28,
77
+ borderRadius: "6px",
78
+ padding: 0,
79
+ backgroundColor: (c) => U(c.palette.common.white, 0.1),
80
+ opacity: 1,
81
+ "&:hover": {
82
+ backgroundColor: (c) => U(c.palette.common.white, 0.16)
83
+ },
84
+ "& .MuiSvgIcon-root": {
85
+ fontSize: "8px",
86
+ width: "8px",
87
+ height: "6px"
88
+ }
89
+ },
90
+ children: /* @__PURE__ */ a.jsx(Fe, {})
91
+ }
92
+ )
93
+ ] })
94
+ ] })
95
+ }
96
+ ),
97
+ /* @__PURE__ */ a.jsx(
98
+ ae,
99
+ {
100
+ open: b,
101
+ onClick: p,
102
+ sx: {
103
+ backdropFilter: "blur(4px)",
104
+ backgroundColor: "rgba(0, 0, 0, 0.3)",
105
+ zIndex: (c) => c.zIndex.modal - 1
106
+ }
107
+ }
108
+ ),
109
+ /* @__PURE__ */ a.jsx(
110
+ re,
111
+ {
112
+ id: "app-menu",
113
+ anchorEl: d,
114
+ open: b,
115
+ onClose: p,
116
+ anchorOrigin: {
117
+ vertical: "bottom",
118
+ horizontal: "left"
119
+ },
120
+ transformOrigin: {
121
+ vertical: "top",
122
+ horizontal: "left"
123
+ },
124
+ sx: {
125
+ zIndex: (c) => c.zIndex.modal,
126
+ "& .MuiPaper-root": {
127
+ minWidth: 200,
128
+ mt: 1
129
+ }
130
+ },
131
+ children: r.map((c) => /* @__PURE__ */ a.jsxs(ne, { onClick: () => l(c), children: [
132
+ /* @__PURE__ */ a.jsx(m, { sx: { display: "flex", alignItems: "center" }, children: c.icon }),
133
+ /* @__PURE__ */ a.jsx(x, { variant: "body1", sx: { ml: 2 }, children: c.name })
134
+ ] }, c.id))
135
+ }
136
+ )
137
+ ] });
138
+ })
139
+ );
140
+ class De {
141
+ constructor() {
142
+ this.messages = [], this.addMessage = (e, o = "info") => {
143
+ const r = {
144
+ id: Math.random().toString(36).substring(2, 11),
145
+ timestamp: /* @__PURE__ */ new Date(),
146
+ message: e,
147
+ level: o
148
+ };
149
+ this.messages.push(r);
150
+ }, this.clearMessages = () => {
151
+ this.messages = [];
152
+ }, this.addInfo = (e) => {
153
+ this.addMessage(e, "info");
154
+ }, this.addWarning = (e) => {
155
+ this.addMessage(e, "warning");
156
+ }, this.addError = (e) => {
157
+ this.addMessage(e, "error");
158
+ }, this.addDebug = (e) => {
159
+ this.addMessage(e, "debug");
160
+ }, we(this, {
161
+ messages: Me,
162
+ addMessage: G,
163
+ clearMessages: G
164
+ });
165
+ }
166
+ }
167
+ const N = (t, e, o) => ({
168
+ id: o || `${Date.now()}-${Math.random().toString(36).substring(2, 11)}`,
169
+ timestamp: /* @__PURE__ */ new Date(),
170
+ message: t,
171
+ level: e
172
+ }), Bt = (t, e) => N(t, "debug", e), It = (t, e) => N(t, "info", e), Pt = (t, e) => N(t, "warning", e), Lt = (t, e) => N(t, "error", e), Ne = A(
173
+ v((t) => {
174
+ var h;
175
+ const { messages: e = [], onClear: o, height: r = 400, sx: n } = t, i = B(), s = Q(null);
176
+ W(() => {
177
+ if (e.length === 0) return;
178
+ const p = s.current;
179
+ if (!p) return;
180
+ const l = setTimeout(() => {
181
+ p.scrollTop = p.scrollHeight;
182
+ }, 10);
183
+ return () => clearTimeout(l);
184
+ }, [e.length]);
185
+ const d = (p) => p.toLocaleTimeString("en-US", {
186
+ hour12: !1,
187
+ hour: "2-digit",
188
+ minute: "2-digit",
189
+ second: "2-digit"
190
+ }), g = (p) => {
191
+ switch (p) {
192
+ case "error":
193
+ return i.palette.error.main;
194
+ case "warning":
195
+ return i.palette.warning.main;
196
+ case "info":
197
+ return i.palette.info.main;
198
+ case "debug":
199
+ return i.palette.text.disabled;
200
+ default:
201
+ return i.palette.text.secondary;
202
+ }
203
+ }, b = ({ message: p }) => {
204
+ const [l, c] = I(!1), [M, S] = I(!1), [k, _] = I(!1), R = p.message.length > 150, j = async () => {
205
+ try {
206
+ await navigator.clipboard.writeText(p.message), S(!0), setTimeout(() => S(!1), 2e3);
207
+ } catch (P) {
208
+ console.error("Failed to copy message:", P);
209
+ }
210
+ }, O = R && !l ? p.message.substring(0, 150) + "..." : p.message;
211
+ return /* @__PURE__ */ a.jsx(
212
+ m,
213
+ {
214
+ onMouseEnter: () => _(!0),
215
+ onMouseLeave: () => _(!1),
216
+ sx: {
217
+ display: "flex",
218
+ gap: 1,
219
+ fontFamily: "monospace",
220
+ flexDirection: "column",
221
+ "&:hover": {
222
+ backgroundColor: i.palette.action.hover
223
+ },
224
+ borderRadius: "4px",
225
+ padding: "2px 4px",
226
+ margin: "-2px -4px"
227
+ },
228
+ children: /* @__PURE__ */ a.jsxs(m, { sx: { display: "flex", gap: 1 }, children: [
229
+ /* @__PURE__ */ a.jsxs(
230
+ x,
231
+ {
232
+ component: "span",
233
+ sx: {
234
+ fontWeight: 400,
235
+ fontSize: "12px",
236
+ lineHeight: "18px",
237
+ letterSpacing: "0.4px",
238
+ color: i.palette.text.disabled,
239
+ whiteSpace: "nowrap",
240
+ flexShrink: 0
241
+ },
242
+ children: [
243
+ "[",
244
+ d(p.timestamp),
245
+ "]"
246
+ ]
247
+ }
248
+ ),
249
+ /* @__PURE__ */ a.jsx(
250
+ x,
251
+ {
252
+ component: "span",
253
+ sx: {
254
+ fontWeight: 400,
255
+ fontSize: "12px",
256
+ lineHeight: "18px",
257
+ letterSpacing: "0.4px",
258
+ color: g(p.level),
259
+ wordBreak: "break-word",
260
+ overflowWrap: "anywhere",
261
+ hyphens: "auto",
262
+ flex: 1,
263
+ whiteSpace: "pre-wrap"
264
+ },
265
+ children: O
266
+ }
267
+ ),
268
+ /* @__PURE__ */ a.jsxs(
269
+ m,
270
+ {
271
+ sx: {
272
+ display: "flex",
273
+ alignItems: "flex-start",
274
+ gap: 0.5,
275
+ opacity: k ? 1 : 0,
276
+ transition: "opacity 0.2s ease-in-out",
277
+ visibility: k ? "visible" : "hidden"
278
+ },
279
+ children: [
280
+ /* @__PURE__ */ a.jsx(
281
+ z,
282
+ {
283
+ size: "small",
284
+ onClick: j,
285
+ sx: {
286
+ padding: "2px",
287
+ color: i.palette.text.secondary,
288
+ "&:hover": {
289
+ backgroundColor: i.palette.action.hover
290
+ }
291
+ },
292
+ title: M ? "Copied!" : "Copy message",
293
+ children: /* @__PURE__ */ a.jsx(je, { sx: { fontSize: 12 } })
294
+ }
295
+ ),
296
+ R && /* @__PURE__ */ a.jsx(
297
+ z,
298
+ {
299
+ size: "small",
300
+ onClick: () => c(!l),
301
+ sx: {
302
+ padding: "2px",
303
+ color: i.palette.text.secondary,
304
+ "&:hover": {
305
+ backgroundColor: i.palette.action.hover
306
+ }
307
+ },
308
+ title: l ? "Collapse" : "Expand",
309
+ children: l ? /* @__PURE__ */ a.jsx(Oe, { sx: { fontSize: 12 } }) : /* @__PURE__ */ a.jsx(Ae, { sx: { fontSize: 12 } })
310
+ }
311
+ )
312
+ ]
313
+ }
314
+ )
315
+ ] })
316
+ },
317
+ p.id
318
+ );
319
+ };
320
+ return /* @__PURE__ */ a.jsxs(
321
+ ie,
322
+ {
323
+ sx: {
324
+ backgroundColor: ((h = i.palette.backgroundPaperElevation) == null ? void 0 : h[2]) || "#171927",
325
+ backgroundImage: "none",
326
+ // Override any gradient from elevation
327
+ height: r,
328
+ display: "flex",
329
+ flexDirection: "column",
330
+ overflow: "hidden",
331
+ ...n
332
+ },
333
+ children: [
334
+ /* @__PURE__ */ a.jsxs(
335
+ m,
336
+ {
337
+ sx: {
338
+ display: "flex",
339
+ alignItems: "center",
340
+ justifyContent: "space-between",
341
+ padding: "12px 16px"
342
+ },
343
+ children: [
344
+ /* @__PURE__ */ a.jsxs(m, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
345
+ /* @__PURE__ */ a.jsx(
346
+ ke,
347
+ {
348
+ sx: {
349
+ fontSize: 16,
350
+ color: i.palette.action.active,
351
+ opacity: 0.56
352
+ }
353
+ }
354
+ ),
355
+ /* @__PURE__ */ a.jsx(
356
+ x,
357
+ {
358
+ sx: {
359
+ fontWeight: 500,
360
+ fontSize: "14px",
361
+ lineHeight: "143%",
362
+ letterSpacing: "0.17px",
363
+ color: i.palette.text.primary
364
+ },
365
+ children: "Log"
366
+ }
367
+ )
368
+ ] }),
369
+ /* @__PURE__ */ a.jsx(
370
+ V,
371
+ {
372
+ onClick: o,
373
+ variant: "text",
374
+ sx: {
375
+ fontWeight: 500,
376
+ fontSize: "13px",
377
+ lineHeight: "22px",
378
+ letterSpacing: "0.46px",
379
+ color: i.palette.primary.main,
380
+ textTransform: "none",
381
+ minWidth: "auto",
382
+ padding: "4px 8px",
383
+ "&:hover": {
384
+ backgroundColor: i.palette.primary.main + "14"
385
+ // 8% opacity
386
+ }
387
+ },
388
+ children: "Clear"
389
+ }
390
+ )
391
+ ]
392
+ }
393
+ ),
394
+ /* @__PURE__ */ a.jsx(
395
+ m,
396
+ {
397
+ ref: s,
398
+ sx: {
399
+ flex: 1,
400
+ overflow: "auto",
401
+ padding: "8px 16px",
402
+ display: "flex",
403
+ flexDirection: "column",
404
+ gap: "2px",
405
+ // Custom scrollbar styling to keep it consistently dark
406
+ scrollbarWidth: "thin",
407
+ scrollbarColor: `${i.palette.divider} transparent`,
408
+ "&::-webkit-scrollbar": {
409
+ width: "6px"
410
+ },
411
+ "&::-webkit-scrollbar-track": {
412
+ background: "transparent"
413
+ },
414
+ "&::-webkit-scrollbar-thumb": {
415
+ backgroundColor: i.palette.divider,
416
+ borderRadius: "3px",
417
+ "&:hover": {
418
+ backgroundColor: i.palette.divider
419
+ }
420
+ }
421
+ },
422
+ children: e.length === 0 ? /* @__PURE__ */ a.jsx(
423
+ x,
424
+ {
425
+ sx: {
426
+ color: i.palette.text.disabled,
427
+ fontSize: "12px",
428
+ fontStyle: "italic",
429
+ textAlign: "center",
430
+ marginTop: 2
431
+ },
432
+ children: "No log messages"
433
+ }
434
+ ) : e.map((p) => /* @__PURE__ */ a.jsx(b, { message: p }, p.id))
435
+ }
436
+ )
437
+ ]
438
+ }
439
+ );
440
+ })
441
+ ), Ft = A(
442
+ v((t) => {
443
+ const { store: e, onStoreReady: o, ...r } = t, n = Q(o);
444
+ W(() => {
445
+ n.current = o;
446
+ }, [o]);
447
+ const i = Se(() => {
448
+ var g;
449
+ const d = e || new De();
450
+ return (g = n.current) == null || g.call(n, d), d;
451
+ }, [e]), s = () => {
452
+ i.clearMessages();
453
+ };
454
+ return /* @__PURE__ */ a.jsx(
455
+ Ne,
456
+ {
457
+ ...r,
458
+ messages: i.messages,
459
+ onClear: s
460
+ }
461
+ );
462
+ })
463
+ );
464
+ function $e() {
465
+ const t = window.location.href;
466
+ return t.substring(
467
+ 0,
468
+ t.indexOf("/", t.indexOf("//") + 2)
469
+ );
470
+ }
471
+ function Dt({
472
+ baseUrl: t = $e(),
473
+ ...e
474
+ }) {
475
+ return /* @__PURE__ */ a.jsxs(
476
+ le,
477
+ {
478
+ "aria-labelledby": "no-motion-group-modal-title",
479
+ open: !0,
480
+ fullWidth: !0,
481
+ sx: {
482
+ "& .MuiModal-backdrop": {
483
+ backdropFilter: "blur(10px)"
484
+ },
485
+ "& .MuiDialog-paper": {
486
+ "::before": {
487
+ content: '""',
488
+ height: "8px",
489
+ width: "100%",
490
+ background: "linear-gradient(90deg, #FF0E65 0%, #47D3FF 100%)"
491
+ },
492
+ background: "#101629"
493
+ }
494
+ },
495
+ children: [
496
+ /* @__PURE__ */ a.jsx(se, { id: "no-motion-group-modal-title", children: "No motion group found" }),
497
+ /* @__PURE__ */ a.jsxs(
498
+ ce,
499
+ {
500
+ sx: {
501
+ marginTop: "3rem",
502
+ marginBottom: "1.5rem",
503
+ textAlign: "center"
504
+ },
505
+ children: [
506
+ /* @__PURE__ */ a.jsx(x, { color: "#fff", children: "Found no devices to connect to." }),
507
+ /* @__PURE__ */ a.jsx(x, { color: "#fff", children: "Please ensure a motion group has been created." })
508
+ ]
509
+ }
510
+ ),
511
+ /* @__PURE__ */ a.jsx(de, { children: /* @__PURE__ */ a.jsxs(F, { width: "100%", maxWidth: "300px", margin: "auto", marginBottom: "2rem", children: [
512
+ /* @__PURE__ */ a.jsx(
513
+ V,
514
+ {
515
+ href: `${t}/settings`,
516
+ variant: "contained",
517
+ sx: {
518
+ borderRadius: "8px",
519
+ width: "100%"
520
+ },
521
+ children: "Go to settings app"
522
+ }
523
+ ),
524
+ /* @__PURE__ */ a.jsx(
525
+ V,
526
+ {
527
+ href: `${t}`,
528
+ variant: "text",
529
+ sx: {
530
+ marginTop: "1rem",
531
+ color: "#fff",
532
+ textDecoration: "underline",
533
+ fontSize: "0.75rem"
534
+ },
535
+ children: "Back to Homescreen"
536
+ }
537
+ )
538
+ ] }) })
539
+ ]
540
+ }
541
+ );
542
+ }
543
+ const ze = _e(/* @__PURE__ */ a.jsx("path", {
544
+ d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m1 15h-2v-2h2zm0-4h-2V7h2z"
545
+ }), "Error"), Ve = ({
546
+ title: t,
547
+ titleId: e,
548
+ ...o
549
+ }, r) => /* @__PURE__ */ u.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 18, height: 18, fill: "none", ref: r, "aria-labelledby": e, ...o }, t ? /* @__PURE__ */ u.createElement("title", { id: e }, t) : null, /* @__PURE__ */ u.createElement("path", { fill: "#38C6F4", fillRule: "evenodd", d: "M6.359 14.25v2.934h7.63v-3.521L10.196 9.87 9 8.674l.859-.859.337-.337.858-.858.565.565.631.63.565.565 1.196-1.195.543-.544 1.196-1.195-1.196-1.196-2.304-2.304L11.054.75 9.86 1.946 3.446 8.359 2.25 9.554l1.196 1.196 2.913 2.913zm1.69 0v1.244h4.249v-1.13L7.804 9.87 6.608 8.674l1.196-1.196L9.86 5.424l.007-.008-.543-.543-4.681 4.681 2.912 2.913.496.496v.113h2.124l1.174 1.174zm3.005-10.022-.294.294-.543-.543.837-.837 2.304 2.304-.543.543-.565-.565z", clipRule: "evenodd" })), Ze = y(Ve);
550
+ var X = /* @__PURE__ */ ((t) => (t.PRECONDITION_NOT_FULFILLED = "PRECONDITION_NOT_FULFILLED", t.ROBOT_DISCONNECTED = "ROBOT_DISCONNECTED", t.CELL_OPEN = "CELL_OPEN", t.E_STOP = "E_STOP", t.MANUAL_MODE = "MANUAL_MODE", t.READY = "READY", t))(X || {});
551
+ const Ye = A(
552
+ v(({ setupState: t, className: e }) => {
553
+ const o = B(), { t: r } = D(), n = () => {
554
+ var b, h, p, l, c, M, S;
555
+ switch (t) {
556
+ case "READY":
557
+ return {
558
+ label: r("RobotSetupReadinessIndicator.Ready.lb"),
559
+ indicatorColor: ((b = o.palette.tertiary) == null ? void 0 : b.main) || o.palette.primary.main,
560
+ backgroundColor: ((h = o.palette.backgroundPaperElevation) == null ? void 0 : h[11]) || o.palette.background.paper,
561
+ textColor: o.palette.secondary.contrastText
562
+ };
563
+ case "ROBOT_DISCONNECTED":
564
+ return {
565
+ label: r("RobotSetupReadinessIndicator.RobotDisconnected.lb"),
566
+ indicatorColor: o.palette.error.main,
567
+ backgroundColor: ((p = o.palette.backgroundPaperElevation) == null ? void 0 : p[11]) || o.palette.background.paper,
568
+ textColor: o.palette.secondary.contrastText
569
+ };
570
+ case "CELL_OPEN":
571
+ return {
572
+ label: r("RobotSetupReadinessIndicator.CellOpen.lb"),
573
+ indicatorColor: o.palette.error.main,
574
+ backgroundColor: ((l = o.palette.backgroundPaperElevation) == null ? void 0 : l[11]) || o.palette.background.paper,
575
+ textColor: o.palette.secondary.contrastText
576
+ };
577
+ case "E_STOP":
578
+ return {
579
+ label: r("RobotSetupReadinessIndicator.EStop.lb"),
580
+ indicatorColor: o.palette.error.main,
581
+ backgroundColor: ((c = o.palette.backgroundPaperElevation) == null ? void 0 : c[11]) || o.palette.background.paper,
582
+ textColor: o.palette.secondary.contrastText
583
+ };
584
+ case "MANUAL_MODE":
585
+ return {
586
+ label: r("RobotSetupReadinessIndicator.ManualMode.lb"),
587
+ indicatorColor: o.palette.error.main,
588
+ backgroundColor: ((M = o.palette.backgroundPaperElevation) == null ? void 0 : M[11]) || o.palette.background.paper,
589
+ textColor: o.palette.secondary.contrastText
590
+ };
591
+ case "PRECONDITION_NOT_FULFILLED":
592
+ default:
593
+ return {
594
+ label: r(
595
+ "RobotSetupReadinessIndicator.PreconditionNotFulfilled.lb"
596
+ ),
597
+ indicatorColor: o.palette.error.main,
598
+ backgroundColor: ((S = o.palette.backgroundPaperElevation) == null ? void 0 : S[11]) || o.palette.background.paper,
599
+ textColor: o.palette.secondary.contrastText
600
+ };
601
+ }
602
+ }, { label: i, indicatorColor: s, backgroundColor: d, textColor: g } = n();
603
+ return /* @__PURE__ */ a.jsx(
604
+ pe,
605
+ {
606
+ className: e,
607
+ label: /* @__PURE__ */ a.jsxs(
608
+ m,
609
+ {
610
+ sx: {
611
+ display: "flex",
612
+ alignItems: "center",
613
+ gap: 1
614
+ },
615
+ children: [
616
+ /* @__PURE__ */ a.jsx(
617
+ m,
618
+ {
619
+ sx: {
620
+ width: 8,
621
+ height: 8,
622
+ borderRadius: "50%",
623
+ backgroundColor: s,
624
+ flexShrink: 0
625
+ }
626
+ }
627
+ ),
628
+ /* @__PURE__ */ a.jsx(
629
+ x,
630
+ {
631
+ variant: "body2",
632
+ sx: {
633
+ color: g,
634
+ fontSize: "0.75rem",
635
+ // Smaller than body2
636
+ lineHeight: 1.2
637
+ },
638
+ children: i
639
+ }
640
+ )
641
+ ]
642
+ }
643
+ ),
644
+ variant: "filled",
645
+ sx: {
646
+ backgroundColor: d,
647
+ color: o.palette.getContrastText(d),
648
+ fontWeight: 500,
649
+ height: "auto",
650
+ "& .MuiChip-label": {
651
+ paddingX: 1.5,
652
+ paddingY: 0.5
653
+ }
654
+ }
655
+ }
656
+ );
657
+ })
658
+ ), Nt = A(
659
+ v(
660
+ ({
661
+ robotName: t,
662
+ robotType: e,
663
+ setupState: o,
664
+ PreconditionComponent: r = Ye,
665
+ className: n
666
+ }) => {
667
+ var g;
668
+ const i = B(), s = e || "Robot", d = o === X.READY;
669
+ return /* @__PURE__ */ a.jsxs(
670
+ m,
671
+ {
672
+ className: n,
673
+ sx: {
674
+ border: `1px solid ${i.palette.divider}`,
675
+ background: ((g = i.palette.backgroundPaperElevation) == null ? void 0 : g[8]) || "#292B3F",
676
+ borderRadius: "8px",
677
+ padding: "20px",
678
+ display: "flex",
679
+ alignItems: "center",
680
+ justifyContent: "space-between",
681
+ opacity: 1
682
+ },
683
+ children: [
684
+ /* @__PURE__ */ a.jsxs(
685
+ m,
686
+ {
687
+ sx: {
688
+ display: "flex",
689
+ alignItems: "center",
690
+ gap: 2,
691
+ flex: 1
692
+ },
693
+ children: [
694
+ d ? /* @__PURE__ */ a.jsx(
695
+ m,
696
+ {
697
+ sx: {
698
+ fontSize: 24,
699
+ display: "flex",
700
+ alignItems: "center",
701
+ justifyContent: "center",
702
+ width: 24,
703
+ height: 24,
704
+ "& svg": {
705
+ fill: `${i.palette.primary.main} !important`
706
+ },
707
+ "& svg path": {
708
+ fill: `${i.palette.primary.main} !important`
709
+ }
710
+ },
711
+ children: /* @__PURE__ */ a.jsx(Ze, {})
712
+ }
713
+ ) : /* @__PURE__ */ a.jsx(
714
+ ze,
715
+ {
716
+ sx: {
717
+ color: i.palette.error.main,
718
+ fontSize: 24
719
+ }
720
+ }
721
+ ),
722
+ /* @__PURE__ */ a.jsx(
723
+ x,
724
+ {
725
+ variant: "body1",
726
+ sx: {
727
+ fontWeight: 500,
728
+ color: i.palette.text.primary
729
+ },
730
+ children: t
731
+ }
732
+ ),
733
+ /* @__PURE__ */ a.jsx(
734
+ Z,
735
+ {
736
+ orientation: "vertical",
737
+ flexItem: !0,
738
+ sx: {
739
+ backgroundColor: i.palette.text.secondary,
740
+ opacity: 0.3,
741
+ width: "1px"
742
+ }
743
+ }
744
+ ),
745
+ /* @__PURE__ */ a.jsx(
746
+ x,
747
+ {
748
+ variant: "body2",
749
+ sx: {
750
+ color: i.palette.text.secondary
751
+ },
752
+ children: s
753
+ }
754
+ )
755
+ ]
756
+ }
757
+ ),
758
+ r && /* @__PURE__ */ a.jsx(r, { setupState: o })
759
+ ]
760
+ }
761
+ );
762
+ }
763
+ )
764
+ ), We = ({
765
+ title: t,
766
+ titleId: e,
767
+ ...o
768
+ }, r) => /* @__PURE__ */ u.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": e, ...o }, t ? /* @__PURE__ */ u.createElement("title", { id: e }, t) : null, /* @__PURE__ */ u.createElement("path", { d: "M5.248 21c-.334 0-.619-.116-.853-.35a1.153 1.153 0 0 1-.351-.848c0-.333.117-.616.351-.85.234-.233.519-.35.853-.35H7.24L4.558 9.87a2.881 2.881 0 0 1-1.126-1.042A2.77 2.77 0 0 1 3 7.317c0-.793.28-1.467.838-2.023a2.774 2.774 0 0 1 2.033-.834 2.71 2.71 0 0 1 1.728.585c.494.389.832.887 1.014 1.493h3.58V5.239c0-.22.076-.406.226-.555a.76.76 0 0 1 .558-.224c.136 0 .263.035.381.104.118.07.209.167.273.292v.14l1.835-1.702a.979.979 0 0 1 .52-.279.881.881 0 0 1 .58.091l4.01 1.85a.74.74 0 0 1 .36.364.537.537 0 0 1-.002.474.592.592 0 0 1-.366.323.657.657 0 0 1-.477-.039l-3.858-1.774L13.76 6.59v1.454l2.473 2.233 3.858-1.774a.648.648 0 0 1 .485-.03.571.571 0 0 1 .358.314.513.513 0 0 1 .01.482.79.79 0 0 1-.367.357l-4.011 1.882a.881.881 0 0 1-.58.09.979.979 0 0 1-.52-.278L13.63 9.638v.14a.92.92 0 0 1-.273.275.665.665 0 0 1-.381.12.76.76 0 0 1-.558-.224.752.752 0 0 1-.225-.555V8.096h-3.58a2.82 2.82 0 0 1-.215.54 2.552 2.552 0 0 1-.323.479l5.139 9.488h2.673c.335 0 .62.116.854.35.234.233.35.516.35.849 0 .332-.116.615-.35.849a1.167 1.167 0 0 1-.854.349H5.248Zm.623-12.385c.362 0 .67-.126.924-.378a1.25 1.25 0 0 0 .38-.92 1.25 1.25 0 0 0-.38-.92 1.261 1.261 0 0 0-.924-.379 1.26 1.26 0 0 0-.925.379 1.25 1.25 0 0 0-.38.92c0 .36.127.667.38.92.254.252.562.378.925.378Z" })), He = y(We), Ue = ({
769
+ title: t,
770
+ titleId: e,
771
+ ...o
772
+ }, r) => /* @__PURE__ */ u.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": e, ...o }, t ? /* @__PURE__ */ u.createElement("title", { id: e }, t) : null, /* @__PURE__ */ u.createElement("path", { d: "m13.37 9.12 1.69 1.69 2.99-2.99-3.73-3.73-.95-.95-7.66 7.66-.95.95 3.99 3.99v3.44h7.55v-3.55l-4.72-4.72 1.79-1.79Zm-.91-2.99.91-.91 2.6 2.6-.91.91-2.6-2.6Zm-2.25 10.24h3.74l-1.34-1.34-.04-.04h-2.5l-3.25-3.25 4.59-4.59.92.92L9.5 10.9l5.33 5.33v1.48H10.2v-1.35l.01.01ZM2 2v4.99h1.41V3.4h3.58V2H2ZM22.21 2h-4.98v1.41h3.59v3.58h1.4V2h-.01ZM20.81 20.65h-3.58v1.4h4.98v-4.99h-1.4v3.59ZM3.4 17.06H2v4.98h4.99v-1.4H3.4v-3.58Z" })), Ge = y(Ue), w = v(
773
+ ({
774
+ id: t,
775
+ icon: e,
776
+ color: o,
777
+ title: r,
778
+ name: n,
779
+ label: i,
780
+ explanation: s,
781
+ literalValue: d,
782
+ anchorOrigin: g,
783
+ transformOrigin: b
784
+ }) => {
785
+ const h = ye(() => ({
786
+ anchorEl: null,
787
+ get isPopoverOpen() {
788
+ return !!h.anchorEl;
789
+ },
790
+ openPopover(p) {
791
+ h.anchorEl = p.currentTarget;
792
+ },
793
+ closePopover() {
794
+ h.anchorEl = null;
795
+ }
796
+ }));
797
+ return /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
798
+ /* @__PURE__ */ a.jsxs(
799
+ F,
800
+ {
801
+ "aria-owns": h.isPopoverOpen ? t : void 0,
802
+ "aria-haspopup": "true",
803
+ onMouseEnter: h.openPopover,
804
+ onMouseLeave: h.closePopover,
805
+ direction: "row",
806
+ spacing: 1,
807
+ sx: {
808
+ cursor: "pointer"
809
+ },
810
+ children: [
811
+ /* @__PURE__ */ a.jsx(
812
+ q,
813
+ {
814
+ component: e,
815
+ sx: {
816
+ color: o
817
+ }
818
+ }
819
+ ),
820
+ i && /* @__PURE__ */ a.jsx("div", { style: {
821
+ color: o
822
+ }, children: i })
823
+ ]
824
+ }
825
+ ),
826
+ /* @__PURE__ */ a.jsx(
827
+ ue,
828
+ {
829
+ id: t,
830
+ sx: {
831
+ pointerEvents: "none"
832
+ },
833
+ open: h.isPopoverOpen,
834
+ anchorEl: h.anchorEl,
835
+ anchorOrigin: g ?? {
836
+ vertical: "bottom",
837
+ horizontal: "left"
838
+ },
839
+ transformOrigin: b ?? {
840
+ vertical: "top",
841
+ horizontal: "left"
842
+ },
843
+ onClose: h.closePopover,
844
+ disableRestoreFocus: !0,
845
+ children: /* @__PURE__ */ a.jsxs(
846
+ F,
847
+ {
848
+ gap: "1rem",
849
+ padding: 2,
850
+ maxWidth: "450px",
851
+ sx: {
852
+ wordWrap: "break-word"
853
+ },
854
+ children: [
855
+ /* @__PURE__ */ a.jsxs("div", { children: [
856
+ r && /* @__PURE__ */ a.jsx(x, { component: "span", fontSize: "14px", children: `${r}: ` }),
857
+ /* @__PURE__ */ a.jsx(
858
+ x,
859
+ {
860
+ component: "span",
861
+ color: o,
862
+ fontWeight: "bold",
863
+ fontSize: "14px",
864
+ children: n
865
+ }
866
+ )
867
+ ] }),
868
+ /* @__PURE__ */ a.jsx(x, { fontSize: "14px", children: s }),
869
+ d && /* @__PURE__ */ a.jsx(x, { fontSize: "12px", children: d })
870
+ ]
871
+ }
872
+ )
873
+ }
874
+ )
875
+ ] });
876
+ }
877
+ ), Ke = v(
878
+ ({
879
+ isVirtual: t,
880
+ motionGroupId: e,
881
+ anchorOrigin: o,
882
+ transformOrigin: r,
883
+ compact: n
884
+ }) => {
885
+ const i = B(), { t: s } = D();
886
+ return t ? /* @__PURE__ */ a.jsx(
887
+ w,
888
+ {
889
+ id: "motion-group-virtual",
890
+ icon: Ge,
891
+ color: i.palette.tertiary.main,
892
+ name: s("SafetyBar.ControllerType.Virtual.lb"),
893
+ label: n ? null : s("SafetyBar.ControllerType.Virtual.lb"),
894
+ explanation: /* @__PURE__ */ a.jsxs(
895
+ T,
896
+ {
897
+ i18nKey: "SafetyBar.MotionGroup.Virtual.Explanation.lb",
898
+ values: {
899
+ motionGroupId: e
900
+ },
901
+ children: [
902
+ "Motion group ",
903
+ /* @__PURE__ */ a.jsx("code", { children: e }),
904
+ " refers to a virtual robot with no physical counterpart. It can be freely manipulated without special safety precautions."
905
+ ]
906
+ }
907
+ ),
908
+ anchorOrigin: o,
909
+ transformOrigin: r
910
+ }
911
+ ) : /* @__PURE__ */ a.jsx(
912
+ w,
913
+ {
914
+ id: "motion-group-physical",
915
+ icon: He,
916
+ color: i.palette.primary.main,
917
+ name: s("SafetyBar.ControllerType.Physical.lb"),
918
+ label: n ? null : s("SafetyBar.ControllerType.Physical.lb"),
919
+ explanation: /* @__PURE__ */ a.jsx(
920
+ T,
921
+ {
922
+ i18nKey: "SafetyBar.MotionGroup.Physical.Explanation.lb",
923
+ values: {
924
+ motionGroupId: e
925
+ },
926
+ components: { code: /* @__PURE__ */ a.jsx("code", {}), strong: /* @__PURE__ */ a.jsx("strong", {}) }
927
+ }
928
+ ),
929
+ anchorOrigin: o,
930
+ transformOrigin: r
931
+ }
932
+ );
933
+ }
934
+ ), Je = ({
935
+ title: t,
936
+ titleId: e,
937
+ ...o
938
+ }, r) => /* @__PURE__ */ u.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": e, ...o }, t ? /* @__PURE__ */ u.createElement("title", { id: e }, t) : null, /* @__PURE__ */ u.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M15.306 2.768c0-.424.344-.768.768-.768h.406C19.53 2 22 4.551 22 7.699c0 3.237-2.51 5.587-5.31 5.703-.84 1.595-2.478 2.677-4.36 2.677a4.845 4.845 0 0 1-3.146-1.163c-.6 1.783 0 3.922 1.79 4.99 1.929 1.149 4.395.467 5.508-1.524l.212-.378a.75.75 0 1 1 1.308.732l-.231.414c-1.524 2.725-4.9 3.66-7.54 2.085-2.716-1.618-3.432-5.037-2.129-7.599a5.22 5.22 0 0 1-.73-2.677c0-2.192 1.335-4.063 3.212-4.793-1.195-1.427-3.29-1.96-5.08-.892-1.928 1.15-2.589 3.696-1.475 5.687l.231.413a.75.75 0 0 1-1.308.732l-.212-.377c-1.524-2.726-.62-6.211 2.02-7.785 2.716-1.619 5.943-.55 7.44 1.897l.13-.001c2.739 0 4.96 2.292 4.96 5.12 0 .284-.023.563-.066.834 1.795-.354 3.288-1.96 3.288-4.095 0-2.3-1.805-4.163-4.032-4.163h-.406a.768.768 0 0 1-.768-.768Zm.496 8.191c0 .286-.033.564-.094.831a3.62 3.62 0 0 1-.672 1.415 3.425 3.425 0 0 1-2.706 1.338 3.402 3.402 0 0 1-2.384-.98 3.598 3.598 0 0 1-.852-1.306 3.677 3.677 0 0 1-.235-1.298c0-1.623 1.046-2.994 2.48-3.435a3.37 3.37 0 0 1 1.522-.107c1.665.264 2.94 1.75 2.94 3.542Z" })), qe = y(Je), Qe = ({
939
+ title: t,
940
+ titleId: e,
941
+ ...o
942
+ }, r) => /* @__PURE__ */ u.createElement("svg", { width: 24, height: 24, fill: "none", xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": e, ...o }, t ? /* @__PURE__ */ u.createElement("title", { id: e }, t) : null, /* @__PURE__ */ u.createElement("path", { d: "M19.763 16.432 13.516 5.864c-.674-1.152-2.358-1.152-3.049 0l-6.23 10.568C3.563 17.567 4.405 19 5.753 19H18.23c1.364 0 2.206-1.432 1.532-2.568ZM12 8.498c.539 0 .96.428.96.938v.066l-.32 4.708a.639.639 0 0 1-.64.592.639.639 0 0 1-.64-.592l-.32-4.708A.953.953 0 0 1 12 8.498Zm0 8.79c-.556 0-1.01-.444-1.01-.987 0-.544.454-.988 1.01-.988s1.01.444 1.01.988c0 .542-.454.987-1.01.987Z", fill: "#fff", fillOpacity: 0.56 })), Xe = y(Qe), et = ({
943
+ title: t,
944
+ titleId: e,
945
+ ...o
946
+ }, r) => /* @__PURE__ */ u.createElement("svg", { width: 24, height: 24, fill: "none", xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": e, ...o }, t ? /* @__PURE__ */ u.createElement("title", { id: e }, t) : null, /* @__PURE__ */ u.createElement("path", { d: "M12.953 5.09a1.497 1.497 0 0 0-1.653-.518l-1.35.43a1.504 1.504 0 0 0-1.726-.376L2.858 6.97c-.736.321-1.06 1.155-.726 1.862.334.707 1.202 1.02 1.937.698l4.27-1.865 1.466 1.973v.402c0 .873-.627 1.63-1.512 1.827l-2.56.567c-1.329.295-2.27 1.431-2.27 2.74v.107c0 .26.22.469.489.469h11.117c1.329 0 2.618.435 3.656 1.233l1.665 1.28A1 1 0 0 0 22 17.47V11.062c0-.312-.108-.616-.308-.863l-3.415-4.218a1.5 1.5 0 0 0-1.618-.471l-.378.12-.866-.475a1.516 1.516 0 0 0-1.188-.114l-1.06.338-.214-.289Z" })), tt = y(et), ot = v(
947
+ ({
948
+ operationMode: t,
949
+ anchorOrigin: e,
950
+ transformOrigin: o,
951
+ compact: r
952
+ }) => {
953
+ const { t: n } = D(), i = B();
954
+ switch (t) {
955
+ case "OPERATION_MODE_AUTO":
956
+ return /* @__PURE__ */ a.jsx(
957
+ w,
958
+ {
959
+ id: "operation-mode-auto",
960
+ icon: qe,
961
+ title: n("SafetyBar.OperationMode.ti"),
962
+ name: n("SafetyBar.OperationMode.Automatic.ti"),
963
+ label: r ? null : n("SafetyBar.OperationMode.Automatic.ti"),
964
+ color: i.palette.text.secondary,
965
+ explanation: /* @__PURE__ */ a.jsx(T, { i18nKey: "SafetyBar.OperationMode.Auto.Explanation.lb", children: "The robot controller is in automatic operation mode. Automated movement without manual confirmation is possible in this mode." }),
966
+ anchorOrigin: e,
967
+ transformOrigin: o
968
+ }
969
+ );
970
+ case "OPERATION_MODE_MANUAL":
971
+ case "OPERATION_MODE_MANUAL_T1":
972
+ case "OPERATION_MODE_MANUAL_T2":
973
+ return /* @__PURE__ */ a.jsx(
974
+ w,
975
+ {
976
+ id: "operation-mode-manual",
977
+ icon: tt,
978
+ color: i.palette.warning.main,
979
+ title: n("SafetyBar.OperationMode.ti"),
980
+ name: n("SafetyBar.OperationMode.Manual.lb"),
981
+ label: r ? null : n("SafetyBar.OperationMode.Manual.lb"),
982
+ explanation: /* @__PURE__ */ a.jsx(T, { i18nKey: "SafetyBar.OperationMode.Manual.Explanation.lb", children: "The robot controller is in manual operation mode. On a physical robot, this generally indicates that an enabling switch must be held for the robot to move successfully." }),
983
+ literalValue: t,
984
+ anchorOrigin: e,
985
+ transformOrigin: o
986
+ }
987
+ );
988
+ default:
989
+ return /* @__PURE__ */ a.jsx(
990
+ w,
991
+ {
992
+ id: "operation-mode-error",
993
+ icon: Xe,
994
+ color: i.palette.warning.main,
995
+ title: n("SafetyBar.OperationMode.ti"),
996
+ name: n("SafetyBar.OperationMode.Error.lb"),
997
+ label: r ? null : n("SafetyBar.OperationMode.Error.lb"),
998
+ explanation: /* @__PURE__ */ a.jsx(T, { i18nKey: "SafetyBar.OperationMode.Error.Explanation.lb", children: "The robot controller has entered an unexpected operation mode. Motion group movement may not be possible." }),
999
+ literalValue: t,
1000
+ anchorOrigin: e,
1001
+ transformOrigin: o
1002
+ }
1003
+ );
1004
+ }
1005
+ }
1006
+ ), at = ({
1007
+ title: t,
1008
+ titleId: e,
1009
+ ...o
1010
+ }, r) => /* @__PURE__ */ u.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": e, ...o }, t ? /* @__PURE__ */ u.createElement("title", { id: e }, t) : null, /* @__PURE__ */ u.createElement("path", { d: "M19.763 16.432 13.516 5.864c-.674-1.152-2.358-1.152-3.049 0l-6.23 10.568C3.563 17.567 4.405 19 5.753 19H18.23c1.364 0 2.206-1.432 1.532-2.568ZM12 8.498c.539 0 .96.428.96.938v.066l-.32 4.708a.639.639 0 0 1-.64.592.639.639 0 0 1-.64-.592l-.32-4.708A.953.953 0 0 1 12 8.498Zm0 8.79c-.556 0-1.01-.444-1.01-.987 0-.544.454-.988 1.01-.988s1.01.444 1.01.988c0 .542-.454.987-1.01.987Z" })), rt = y(at), nt = ({
1011
+ title: t,
1012
+ titleId: e,
1013
+ ...o
1014
+ }, r) => /* @__PURE__ */ u.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": e, ...o }, t ? /* @__PURE__ */ u.createElement("title", { id: e }, t) : null, /* @__PURE__ */ u.createElement("path", { d: "M10.24 10.636 12 13.764l1.76-3.128h-3.52Z" }), /* @__PURE__ */ u.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M18.364 12a6.364 6.364 0 1 1-12.728 0 6.364 6.364 0 0 1 12.728 0ZM7.909 9.273 12 16.546l4.09-7.273H7.91Z" }), /* @__PURE__ */ u.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Zm-1.364 0a8.636 8.636 0 1 1-17.273 0 8.636 8.636 0 0 1 17.273 0Z" })), it = y(nt), lt = ({
1015
+ title: t,
1016
+ titleId: e,
1017
+ ...o
1018
+ }, r) => /* @__PURE__ */ u.createElement("svg", { width: 24, height: 24, fill: "none", xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": e, ...o }, t ? /* @__PURE__ */ u.createElement("title", { id: e }, t) : null, /* @__PURE__ */ u.createElement("path", { d: "M9.057 15.115c-1.681 0-3.111-.59-4.29-1.768C3.59 12.17 3 10.74 3 9.057c0-.29.021-.582.064-.876a4.1 4.1 0 0 1 .214-.844.78.78 0 0 1 .273-.36c.115-.077.244-.133.389-.168a.857.857 0 0 1 .437.008c.146.04.28.12.4.24l2.806 2.787 2.26-2.261-2.775-2.786a.903.903 0 0 1-.241-.405.875.875 0 0 1-.008-.442 1.13 1.13 0 0 1 .174-.389.82.82 0 0 1 .355-.273c.268-.107.548-.182.838-.224.29-.043.581-.064.871-.064 1.682 0 3.112.59 4.29 1.768 1.179 1.178 1.768 2.608 1.768 4.29 0 .444-.042.858-.126 1.241-.084.384-.21.755-.377 1.113l5.726 5.692A2.2 2.2 0 0 1 21 18.721a2.2 2.2 0 0 1-.662 1.617A2.2 2.2 0 0 1 18.72 21a2.173 2.173 0 0 1-1.617-.679l-5.692-5.709c-.372.161-.75.285-1.133.372-.383.087-.79.13-1.222.13Z", fill: "#fff", fillOpacity: 0.56 })), st = y(lt), ct = ({
1019
+ title: t,
1020
+ titleId: e,
1021
+ ...o
1022
+ }, r) => /* @__PURE__ */ u.createElement("svg", { width: 24, height: 24, fill: "none", xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": e, ...o }, t ? /* @__PURE__ */ u.createElement("title", { id: e }, t) : null, /* @__PURE__ */ u.createElement("path", { d: "m10.6 13.8-2.15-2.15a.948.948 0 0 0-.7-.275.948.948 0 0 0-.7.275.948.948 0 0 0-.275.7c0 .283.092.517.275.7L9.9 15.9c.2.2.433.3.7.3.267 0 .5-.1.7-.3l5.65-5.65a.948.948 0 0 0 .275-.7.948.948 0 0 0-.275-.7.948.948 0 0 0-.7-.275.948.948 0 0 0-.7.275L10.6 13.8ZM12 22a9.738 9.738 0 0 1-3.9-.788 10.099 10.099 0 0 1-3.175-2.137c-.9-.9-1.612-1.958-2.137-3.175A9.738 9.738 0 0 1 2 12c0-1.383.263-2.683.788-3.9a10.099 10.099 0 0 1 2.137-3.175c.9-.9 1.958-1.612 3.175-2.137A9.738 9.738 0 0 1 12 2c1.383 0 2.683.263 3.9.788a10.098 10.098 0 0 1 3.175 2.137c.9.9 1.613 1.958 2.137 3.175A9.738 9.738 0 0 1 22 12a9.738 9.738 0 0 1-.788 3.9 10.098 10.098 0 0 1-2.137 3.175c-.9.9-1.958 1.613-3.175 2.137A9.738 9.738 0 0 1 12 22Zm0-2c2.233 0 4.125-.775 5.675-2.325C19.225 16.125 20 14.233 20 12c0-2.233-.775-4.125-2.325-5.675C16.125 4.775 14.233 4 12 4c-2.233 0-4.125.775-5.675 2.325C4.775 7.875 4 9.767 4 12c0 2.233.775 4.125 2.325 5.675C7.875 19.225 9.767 20 12 20Z" })), dt = y(ct), pt = ({
1023
+ title: t,
1024
+ titleId: e,
1025
+ ...o
1026
+ }, r) => /* @__PURE__ */ u.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": e, ...o }, t ? /* @__PURE__ */ u.createElement("title", { id: e }, t) : null, /* @__PURE__ */ u.createElement("path", { d: "M9 16h6c.283 0 .52-.096.713-.287A.968.968 0 0 0 16 15V9a.967.967 0 0 0-.287-.713A.968.968 0 0 0 15 8H9a.968.968 0 0 0-.713.287A.968.968 0 0 0 8 9v6c0 .283.096.52.287.713.192.191.43.287.713.287Zm3 6a9.738 9.738 0 0 1-3.9-.788 10.099 10.099 0 0 1-3.175-2.137c-.9-.9-1.612-1.958-2.137-3.175A9.738 9.738 0 0 1 2 12c0-1.383.263-2.683.788-3.9a10.099 10.099 0 0 1 2.137-3.175c.9-.9 1.958-1.612 3.175-2.137A9.738 9.738 0 0 1 12 2c1.383 0 2.683.263 3.9.788a10.098 10.098 0 0 1 3.175 2.137c.9.9 1.613 1.958 2.137 3.175A9.738 9.738 0 0 1 22 12a9.738 9.738 0 0 1-.788 3.9 10.098 10.098 0 0 1-2.137 3.175c-.9.9-1.958 1.613-3.175 2.137A9.738 9.738 0 0 1 12 22Zm0-2c2.233 0 4.125-.775 5.675-2.325C19.225 16.125 20 14.233 20 12c0-2.233-.775-4.125-2.325-5.675C16.125 4.775 14.233 4 12 4c-2.233 0-4.125.775-5.675 2.325C4.775 7.875 4 9.767 4 12c0 2.233.775 4.125 2.325 5.675C7.875 19.225 9.767 20 12 20Z" })), ut = y(pt), gt = v(
1027
+ ({
1028
+ safetyState: t,
1029
+ anchorOrigin: e,
1030
+ transformOrigin: o,
1031
+ compact: r
1032
+ }) => {
1033
+ const { t: n } = D(), i = B();
1034
+ switch (t) {
1035
+ // Normal state, robot can move
1036
+ case "SAFETY_STATE_NORMAL":
1037
+ return /* @__PURE__ */ a.jsx(
1038
+ w,
1039
+ {
1040
+ id: "safety-state-normal",
1041
+ title: n("SafetyBar.SafetyState.ti"),
1042
+ name: n("SafetyBar.SafetyState.Normal.lb"),
1043
+ label: r ? null : n("SafetyBar.SafetyState.Normal.lb"),
1044
+ icon: dt,
1045
+ color: i.palette.text.secondary,
1046
+ explanation: /* @__PURE__ */ a.jsx(T, { i18nKey: "SafetyBar.SafetyState.Normal.Explanation.lb", children: "The robot controller is in a normal safety state. Movement is not prevented by this state." }),
1047
+ anchorOrigin: e,
1048
+ transformOrigin: o
1049
+ }
1050
+ );
1051
+ // Estop
1052
+ case "SAFETY_STATE_DEVICE_EMERGENCY_STOP":
1053
+ case "SAFETY_STATE_ROBOT_EMERGENCY_STOP":
1054
+ return /* @__PURE__ */ a.jsx(
1055
+ w,
1056
+ {
1057
+ id: "safety-state-estop",
1058
+ title: n("SafetyBar.SafetyState.ti"),
1059
+ name: n("SafetyBar.SafetyState.Estop.lb"),
1060
+ label: r ? null : n("SafetyBar.SafetyState.Estop.lb"),
1061
+ icon: it,
1062
+ color: i.palette.error.main,
1063
+ explanation: /* @__PURE__ */ a.jsx(T, { i18nKey: "SafetyBar.StopState.Estop.Explanation.lb", children: "An emergency stop of the robot controller has been triggered. Movement of the robot is no longer possible until the estop is released." }),
1064
+ literalValue: t,
1065
+ anchorOrigin: e,
1066
+ transformOrigin: o
1067
+ }
1068
+ );
1069
+ // General stop
1070
+ case "SAFETY_STATE_STOP_0":
1071
+ case "SAFETY_STATE_STOP_1":
1072
+ case "SAFETY_STATE_STOP_2":
1073
+ case "SAFETY_STATE_PROTECTIVE_STOP":
1074
+ case "SAFETY_STATE_STOP":
1075
+ return /* @__PURE__ */ a.jsx(
1076
+ w,
1077
+ {
1078
+ id: "safety-state-stop",
1079
+ icon: ut,
1080
+ title: n("SafetyBar.SafetyState.ti"),
1081
+ name: n("SafetyBar.SafetyState.Stop.lb"),
1082
+ label: r ? null : n("SafetyBar.SafetyState.Stop.lb"),
1083
+ color: i.palette.warning.main,
1084
+ explanation: /* @__PURE__ */ a.jsx(T, { i18nKey: "SafetyBar.SafetyState.Stop.Explanation.lb", children: "The robot controller has entered a stop state. Movement is no longer possible until the stop state is resolved." }),
1085
+ literalValue: t,
1086
+ anchorOrigin: e,
1087
+ transformOrigin: o
1088
+ }
1089
+ );
1090
+ // Manual action required
1091
+ case "SAFETY_STATE_REDUCED":
1092
+ case "SAFETY_STATE_MASTERING":
1093
+ case "SAFETY_STATE_CONFIRM_SAFETY":
1094
+ case "SAFETY_STATE_OPERATOR_SAFETY":
1095
+ case "SAFETY_STATE_RECOVERY":
1096
+ case "SAFETY_STATE_VIOLATION":
1097
+ return /* @__PURE__ */ a.jsx(
1098
+ w,
1099
+ {
1100
+ id: "safety-state-manual-action-required",
1101
+ icon: st,
1102
+ color: i.palette.warning.main,
1103
+ title: n("SafetyBar.SafetyState.ti"),
1104
+ name: n("SafetyBar.SafetyState.ManualActionRequired.lb"),
1105
+ label: r ? null : n("SafetyBar.SafetyState.ManualActionRequired.lb"),
1106
+ explanation: /* @__PURE__ */ a.jsx(T, { i18nKey: "SafetyBar.SafetyState.ManualActionRequired.Explanation.lb", children: "The robot controller has entered a safety state requiring manual action to resolve." }),
1107
+ literalValue: t,
1108
+ anchorOrigin: e,
1109
+ transformOrigin: o
1110
+ }
1111
+ );
1112
+ // Error
1113
+ case "SAFETY_STATE_UNKNOWN":
1114
+ case "SAFETY_STATE_FAULT":
1115
+ return /* @__PURE__ */ a.jsx(
1116
+ w,
1117
+ {
1118
+ id: "safety-state-error",
1119
+ icon: rt,
1120
+ color: i.palette.error.main,
1121
+ title: n("SafetyBar.SafetyState.ti"),
1122
+ name: n("SafetyBar.SafetyState.Error.lb"),
1123
+ label: r ? null : n("SafetyBar.SafetyState.Error.lb"),
1124
+ explanation: /* @__PURE__ */ a.jsx(T, { i18nKey: "SafetyBar.SafetyState.Error.Explanation.lb", children: "The robot controller has entered an unexpected safety state." }),
1125
+ literalValue: t,
1126
+ anchorOrigin: e,
1127
+ transformOrigin: o
1128
+ }
1129
+ );
1130
+ default:
1131
+ Be(t, `Unknown safety state ${t}`);
1132
+ }
1133
+ }
1134
+ ), $t = A(
1135
+ v(
1136
+ ({
1137
+ isVirtual: t,
1138
+ motionGroupId: e,
1139
+ operationMode: o,
1140
+ safetyState: r,
1141
+ anchorOrigin: n,
1142
+ transformOrigin: i,
1143
+ compact: s = !0
1144
+ }) => {
1145
+ const d = s ? 1 : 2;
1146
+ return /* @__PURE__ */ a.jsxs(
1147
+ F,
1148
+ {
1149
+ direction: "row",
1150
+ gap: d,
1151
+ alignItems: "center",
1152
+ sx: { height: "24px" },
1153
+ children: [
1154
+ /* @__PURE__ */ a.jsx(
1155
+ gt,
1156
+ {
1157
+ safetyState: r,
1158
+ anchorOrigin: n,
1159
+ transformOrigin: i,
1160
+ compact: s
1161
+ }
1162
+ ),
1163
+ /* @__PURE__ */ a.jsx(Z, { orientation: "vertical", flexItem: !0 }),
1164
+ /* @__PURE__ */ a.jsx(
1165
+ ot,
1166
+ {
1167
+ operationMode: o,
1168
+ anchorOrigin: n,
1169
+ transformOrigin: i,
1170
+ compact: s
1171
+ }
1172
+ ),
1173
+ /* @__PURE__ */ a.jsx(Z, { orientation: "vertical", flexItem: !0 }),
1174
+ /* @__PURE__ */ a.jsx(
1175
+ Ke,
1176
+ {
1177
+ isVirtual: t,
1178
+ motionGroupId: e,
1179
+ anchorOrigin: n,
1180
+ transformOrigin: i,
1181
+ compact: s
1182
+ }
1183
+ )
1184
+ ]
1185
+ }
1186
+ );
1187
+ }
1188
+ )
1189
+ ), ht = ge(he, {
1190
+ shouldForwardProp: (t) => t !== "selected"
1191
+ })(({ theme: t }) => {
1192
+ var e, o, r;
1193
+ return {
1194
+ borderRadius: "20px",
1195
+ "&:hover": {
1196
+ background: (e = t.palette.backgroundPaperElevation) == null ? void 0 : e[7]
1197
+ },
1198
+ variants: [
1199
+ {
1200
+ props: ({ selected: n }) => !n,
1201
+ style: {
1202
+ background: (o = t.palette.backgroundPaperElevation) == null ? void 0 : o[0],
1203
+ color: t.palette.action.disabled,
1204
+ "> img": {
1205
+ opacity: 0.4
1206
+ }
1207
+ }
1208
+ },
1209
+ {
1210
+ props: ({ selected: n }) => n,
1211
+ style: {
1212
+ background: (r = t.palette.backgroundPaperElevation) == null ? void 0 : r[11],
1213
+ border: `1px solid ${t.palette.divider}`,
1214
+ color: t.palette.primary.contrastText
1215
+ }
1216
+ }
1217
+ ]
1218
+ };
1219
+ }), zt = (t) => {
1220
+ const { ref: e, ...o } = t;
1221
+ return /* @__PURE__ */ a.jsx(
1222
+ ht,
1223
+ {
1224
+ ref: e,
1225
+ selected: t.selected,
1226
+ ...o,
1227
+ color: "secondary",
1228
+ variant: "circular"
1229
+ }
1230
+ );
1231
+ };
1232
+ function bt(t) {
1233
+ const { children: e, value: o, index: r, ...n } = t;
1234
+ return /* @__PURE__ */ a.jsx(
1235
+ "div",
1236
+ {
1237
+ role: "tabpanel",
1238
+ hidden: o !== r,
1239
+ id: `tabpanel-${r}`,
1240
+ "aria-labelledby": `tab-${r}`,
1241
+ ...n,
1242
+ children: o === r && /* @__PURE__ */ a.jsx(m, { children: e })
1243
+ }
1244
+ );
1245
+ }
1246
+ function mt({ children: t, ...e }) {
1247
+ const {
1248
+ fullWidth: o,
1249
+ indicator: r,
1250
+ onChange: n,
1251
+ orientation: i,
1252
+ scrollButtons: s,
1253
+ selectionFollowsFocus: d,
1254
+ textColor: g,
1255
+ value: b,
1256
+ variant: h,
1257
+ ...p
1258
+ } = e;
1259
+ return /* @__PURE__ */ a.jsx(m, { ...p, children: t });
1260
+ }
1261
+ const Vt = A(
1262
+ v((t) => {
1263
+ const {
1264
+ items: e,
1265
+ activeTab: o,
1266
+ defaultActiveTab: r = 0,
1267
+ onTabChange: n,
1268
+ sx: i,
1269
+ ref: s
1270
+ } = t, d = o !== void 0, [g, b] = I(r), h = d ? o : g;
1271
+ W(() => {
1272
+ d || e.length !== 0 && (g < 0 || g > e.length - 1) && b(0);
1273
+ }, [e.length, d, g]);
1274
+ const p = (l, c) => {
1275
+ d || b(c), n == null || n(c);
1276
+ };
1277
+ return /* @__PURE__ */ a.jsxs(
1278
+ m,
1279
+ {
1280
+ ref: s,
1281
+ sx: { height: "100%", display: "flex", flexDirection: "column", ...i },
1282
+ children: [
1283
+ /* @__PURE__ */ a.jsx(
1284
+ m,
1285
+ {
1286
+ sx: {
1287
+ px: 0,
1288
+ py: 0,
1289
+ overflow: "visible",
1290
+ position: "relative",
1291
+ // Extra padding to prevent badge clipping
1292
+ // Top: accommodates badge positioned at top: -6px with 20px height
1293
+ // Right: accommodates badge positioned at right: -8px with 20px width
1294
+ paddingTop: (l) => l.spacing(2),
1295
+ // 16px
1296
+ paddingRight: (l) => l.spacing(2.5)
1297
+ // 20px
1298
+ },
1299
+ children: /* @__PURE__ */ a.jsx(
1300
+ be,
1301
+ {
1302
+ value: h,
1303
+ onChange: p,
1304
+ sx: {
1305
+ minHeight: "32px",
1306
+ backgroundColor: "transparent",
1307
+ overflow: "visible",
1308
+ "& .MuiTabs-indicator": {
1309
+ display: "none"
1310
+ // Hide the default indicator
1311
+ },
1312
+ "& .MuiTabs-flexContainer": {
1313
+ gap: 2,
1314
+ overflow: "visible",
1315
+ paddingTop: 0,
1316
+ paddingBottom: 0
1317
+ },
1318
+ "& .MuiTabs-scroller": {
1319
+ overflow: "visible !important"
1320
+ },
1321
+ "& .MuiTab-root": {
1322
+ overflow: "visible"
1323
+ }
1324
+ },
1325
+ children: e.map((l, c) => {
1326
+ var O, P, H;
1327
+ const M = () => {
1328
+ if (!l.badge) return;
1329
+ const C = l.badge.content, f = l.badge.max;
1330
+ return typeof C == "number" && f && C > f ? `${f}+` : C;
1331
+ }, S = () => {
1332
+ if (!l.badge) return !1;
1333
+ const C = l.badge.content, f = l.badge.showZero;
1334
+ return !(C === 0 && !f);
1335
+ }, k = M(), _ = S(), R = () => {
1336
+ d || b(c), n == null || n(c);
1337
+ }, j = /* @__PURE__ */ a.jsx(
1338
+ me,
1339
+ {
1340
+ label: l.label,
1341
+ icon: l.icon,
1342
+ iconPosition: "start",
1343
+ disableRipple: !0,
1344
+ onClick: R,
1345
+ sx: {
1346
+ minHeight: "32px",
1347
+ height: "32px",
1348
+ padding: "0px 10px",
1349
+ borderRadius: "12px",
1350
+ backgroundColor: (C) => {
1351
+ var f;
1352
+ return ((f = C.palette.backgroundPaperElevation) == null ? void 0 : f[11]) || "#32344B";
1353
+ },
1354
+ color: "text.primary",
1355
+ opacity: h === c ? 1 : 0.38,
1356
+ fontSize: "13px",
1357
+ transition: "all 0.2s ease-in-out",
1358
+ position: "relative",
1359
+ overflow: "visible",
1360
+ "&:hover": {
1361
+ opacity: h === c ? 1 : 0.6
1362
+ },
1363
+ "&.Mui-selected": {
1364
+ opacity: 1,
1365
+ backgroundColor: (C) => {
1366
+ var f;
1367
+ return ((f = C.palette.backgroundPaperElevation) == null ? void 0 : f[11]) || "#32344B";
1368
+ },
1369
+ color: "text.primary"
1370
+ },
1371
+ "&:focus": {
1372
+ outline: "none"
1373
+ },
1374
+ "&:active": {
1375
+ transform: "none"
1376
+ }
1377
+ }
1378
+ },
1379
+ l.id
1380
+ );
1381
+ return _ ? /* @__PURE__ */ a.jsx(
1382
+ mt,
1383
+ {
1384
+ component: "span",
1385
+ sx: { display: "inline-flex" },
1386
+ children: /* @__PURE__ */ a.jsx(
1387
+ xe,
1388
+ {
1389
+ badgeContent: k,
1390
+ color: ((O = l.badge) == null ? void 0 : O.color) || "error",
1391
+ max: (P = l.badge) == null ? void 0 : P.max,
1392
+ showZero: (H = l.badge) == null ? void 0 : H.showZero,
1393
+ anchorOrigin: {
1394
+ vertical: "top",
1395
+ horizontal: "right"
1396
+ },
1397
+ overlap: "rectangular",
1398
+ sx: {
1399
+ "& .MuiBadge-badge": {
1400
+ // Ensure badge doesn't inherit tab opacity
1401
+ opacity: "1 !important"
1402
+ }
1403
+ },
1404
+ children: j
1405
+ }
1406
+ )
1407
+ },
1408
+ l.id
1409
+ ) : j;
1410
+ })
1411
+ }
1412
+ )
1413
+ }
1414
+ ),
1415
+ /* @__PURE__ */ a.jsx(
1416
+ m,
1417
+ {
1418
+ sx: {
1419
+ mt: (l) => l.spacing(2),
1420
+ borderBottom: 1,
1421
+ borderColor: "divider"
1422
+ }
1423
+ }
1424
+ ),
1425
+ /* @__PURE__ */ a.jsx(m, { sx: { flex: 1, overflow: "auto" }, children: e.map((l, c) => /* @__PURE__ */ a.jsx(bt, { value: h, index: c, children: l.content }, l.id)) })
1426
+ ]
1427
+ }
1428
+ );
1429
+ })
1430
+ ), xt = {
1431
+ $schema: "https://raw.githubusercontent.com/martinring/tmlanguage/master/tmlanguage.json",
1432
+ name: "wandelscript",
1433
+ patterns: [
1434
+ {
1435
+ include: "#keywords"
1436
+ },
1437
+ {
1438
+ include: "#strings"
1439
+ },
1440
+ {
1441
+ include: "#comments"
1442
+ },
1443
+ {
1444
+ include: "#functions"
1445
+ }
1446
+ ],
1447
+ repository: {
1448
+ keywords: {
1449
+ patterns: [
1450
+ {
1451
+ name: "keyword.control.flow.wandelscript",
1452
+ match: "\\b(move|via|to|interrupt|def|False|True|for|if|else|elif|while|return|switch|activate|deactivate|print|and|or|not)\\b"
1453
+ }
1454
+ ]
1455
+ },
1456
+ strings: {
1457
+ name: "string.quoted.double.wandelscript",
1458
+ begin: '"',
1459
+ end: '"',
1460
+ patterns: [
1461
+ {
1462
+ name: "constant.character.escape.wandelscript",
1463
+ match: "\\\\."
1464
+ }
1465
+ ]
1466
+ },
1467
+ comments: {
1468
+ patterns: [
1469
+ {
1470
+ begin: "#",
1471
+ beginCaptures: {
1472
+ 0: { name: "punctuation.definition.comment.wandelscript" }
1473
+ },
1474
+ end: "$",
1475
+ name: "comment.line.number-sign.wandelscript"
1476
+ }
1477
+ ]
1478
+ },
1479
+ functions: {
1480
+ patterns: [
1481
+ {
1482
+ match: "[a-zA-Z_-]+\\(",
1483
+ name: "entity.name.function.wandelscript"
1484
+ }
1485
+ ]
1486
+ }
1487
+ },
1488
+ scopeName: "source.wandelscript"
1489
+ }, ft = Ee(() => import("@monaco-editor/react"));
1490
+ let $ = null;
1491
+ async function vt() {
1492
+ if (!$) {
1493
+ const [{ createHighlighter: t }, { shikiToMonaco: e }] = await Promise.all([
1494
+ import("shiki"),
1495
+ import("@shikijs/monaco")
1496
+ ]);
1497
+ $ = {
1498
+ shiki: await t({
1499
+ // Our textmate grammar doesn't quite conform to the expected type
1500
+ // here; I'm not sure what the missing properties mean exactly
1501
+ langs: [xt],
1502
+ themes: ["dark-plus", "light-plus"]
1503
+ }),
1504
+ shikiToMonaco: e
1505
+ };
1506
+ }
1507
+ return $;
1508
+ }
1509
+ const Zt = A(
1510
+ (t) => {
1511
+ const e = B(), [o, r] = I("dark-plus"), n = e.palette.mode === "dark" ? "dark-plus" : "light-plus";
1512
+ async function i(s) {
1513
+ var b, h;
1514
+ s.languages.register({ id: "wandelscript" }), s.languages.setLanguageConfiguration("wandelscript", {
1515
+ comments: {
1516
+ lineComment: "#"
1517
+ },
1518
+ brackets: [
1519
+ ["(", ")"],
1520
+ ["[", "]"]
1521
+ ],
1522
+ autoClosingPairs: [
1523
+ { open: "[", close: "]" },
1524
+ { open: "(", close: ")" }
1525
+ ],
1526
+ surroundingPairs: [
1527
+ { open: "[", close: "]" },
1528
+ { open: "(", close: ")" }
1529
+ ]
1530
+ });
1531
+ const { shiki: d, shikiToMonaco: g } = await vt();
1532
+ g(d, s), s.editor.defineTheme(
1533
+ n,
1534
+ ((h = (b = e.componentsExt) == null ? void 0 : b.WandelscriptEditor) == null ? void 0 : h.monacoTheme) ?? {
1535
+ base: e.palette.mode === "dark" ? "vs-dark" : "vs",
1536
+ inherit: !0,
1537
+ rules: [],
1538
+ colors: {}
1539
+ }
1540
+ ), t.monacoSetup && t.monacoSetup(s), r(n);
1541
+ }
1542
+ return /* @__PURE__ */ a.jsx(Te, { fallback: /* @__PURE__ */ a.jsx(Ie, {}), children: /* @__PURE__ */ a.jsx(
1543
+ ft,
1544
+ {
1545
+ value: t.code,
1546
+ onMount: (s, d) => {
1547
+ i(d);
1548
+ },
1549
+ onChange: t.onChange,
1550
+ defaultLanguage: "wandelscript",
1551
+ theme: o,
1552
+ options: {
1553
+ minimap: { enabled: !1 },
1554
+ wordWrap: "on",
1555
+ automaticLayout: !0,
1556
+ ...t.monacoOptions
1557
+ }
1558
+ }
1559
+ ) });
1560
+ }
1561
+ ), J = 1e-4, yt = {
1562
+ a: 0,
1563
+ d: 0,
1564
+ alpha: 0,
1565
+ theta: 0,
1566
+ reverse_rotation_direction: !1
1567
+ };
1568
+ class Y {
1569
+ constructor(e, o, r, n, i, s, d, g, b, h) {
1570
+ this.nova = e, this.controller = o, this.motionGroup = r, this.initialMotionState = n, this.motionStateSocket = i, this.isVirtual = s, this.tcps = d, this.description = g, this.initialControllerState = b, this.controllerStateSocket = h, this.connectedJoggingSocket = null, this.joggingVelocity = 10, this.activationState = "inactive", this.rapidlyChangingMotionState = n, this.controllerState = b, h.addEventListener("message", (p) => {
1571
+ var c;
1572
+ const l = (c = L(p.data)) == null ? void 0 : c.result;
1573
+ l && E(() => {
1574
+ this.controllerState = l;
1575
+ });
1576
+ }), i.addEventListener("message", (p) => {
1577
+ var c;
1578
+ const l = (c = L(p.data)) == null ? void 0 : c.result;
1579
+ if (!l)
1580
+ throw new Error(
1581
+ `Failed to get motion state for ${this.motionGroupId}: ${p.data}`
1582
+ );
1583
+ Pe(
1584
+ this.rapidlyChangingMotionState.joint_position,
1585
+ l.joint_position,
1586
+ J
1587
+ ) || E(() => {
1588
+ this.rapidlyChangingMotionState.joint_position = l.joint_position;
1589
+ }), Le(
1590
+ this.rapidlyChangingMotionState,
1591
+ l,
1592
+ J
1593
+ ) || E(() => {
1594
+ this.rapidlyChangingMotionState.tcp_pose = l.tcp_pose;
1595
+ }), this.rapidlyChangingMotionState.standstill !== l.standstill && E(() => {
1596
+ this.rapidlyChangingMotionState.standstill = l.standstill;
1597
+ });
1598
+ }), Ce(this);
1599
+ }
1600
+ static async connectMultiple(e, o) {
1601
+ return Promise.all(
1602
+ o.map(
1603
+ (r) => Y.connect(e, r)
1604
+ )
1605
+ );
1606
+ }
1607
+ static async connect(e, o) {
1608
+ var _, R;
1609
+ const [r, n] = o.split("@"), i = await e.api.controller.getCurrentRobotControllerState(n), s = i == null ? void 0 : i.motion_groups.find(
1610
+ (j) => j.motion_group === o
1611
+ );
1612
+ if (!i || !s)
1613
+ throw new Error(
1614
+ `Controller ${n} or motion group ${o} not found`
1615
+ );
1616
+ const d = e.openReconnectingWebsocket(
1617
+ `/controllers/${n}/motion-groups/${o}/state-stream`
1618
+ ), g = await d.firstMessage(), b = (_ = L(g.data)) == null ? void 0 : _.result;
1619
+ if (!b)
1620
+ throw new Error(
1621
+ `Unable to parse initial motion state message ${g.data}`
1622
+ );
1623
+ console.log(
1624
+ `Connected motion state websocket to motion group ${s.motion_group}. Initial state:
1625
+ `,
1626
+ b
1627
+ );
1628
+ const p = (await e.api.controller.getRobotController(
1629
+ i.controller
1630
+ )).configuration.kind === "VirtualController", l = await e.api.motionGroup.getMotionGroupDescription(
1631
+ n,
1632
+ s.motion_group
1633
+ ), c = Object.entries(l.tcps || {}).map(
1634
+ ([j, O]) => ({
1635
+ id: j,
1636
+ readable_name: O.name,
1637
+ position: O.pose.position,
1638
+ orientation: O.pose.orientation
1639
+ })
1640
+ ), M = e.openReconnectingWebsocket(
1641
+ `/controllers/${i.controller}/state-stream?response_rate=1000`
1642
+ ), S = await M.firstMessage(), k = (R = L(S.data)) == null ? void 0 : R.result;
1643
+ if (!k)
1644
+ throw new Error(
1645
+ `Unable to parse initial controller state message ${S.data}`
1646
+ );
1647
+ return console.log(
1648
+ `Connected controller state websocket to controller ${i.controller}. Initial state:
1649
+ `,
1650
+ k
1651
+ ), new Y(
1652
+ e,
1653
+ i,
1654
+ s,
1655
+ b,
1656
+ d,
1657
+ p,
1658
+ c,
1659
+ l,
1660
+ k,
1661
+ M
1662
+ );
1663
+ }
1664
+ get motionGroupId() {
1665
+ return this.motionGroup.motion_group;
1666
+ }
1667
+ get controllerId() {
1668
+ return this.controller.controller;
1669
+ }
1670
+ get modelFromController() {
1671
+ return this.description.motion_group_model;
1672
+ }
1673
+ get wandelscriptIdentifier() {
1674
+ const e = this.motionGroupId.split("@")[0];
1675
+ return `${this.controllerId.replace(/-/g, "_")}_${e}`;
1676
+ }
1677
+ /** Jogging velocity in radians for rotation and joint movement */
1678
+ get joggingVelocityRads() {
1679
+ return this.joggingVelocity * Math.PI / 180;
1680
+ }
1681
+ get joints() {
1682
+ return this.initialMotionState.joint_position.map((e, o) => ({
1683
+ index: o
1684
+ }));
1685
+ }
1686
+ // Please note that API v2 omits 0 values
1687
+ get dhParameters() {
1688
+ if (this.description.dh_parameters !== void 0)
1689
+ return this.description.dh_parameters.map((e) => ({
1690
+ ...yt,
1691
+ ...e
1692
+ }));
1693
+ }
1694
+ get safetyZones() {
1695
+ return this.description.safety_zones;
1696
+ }
1697
+ /** Gets the robot mounting position offset in 3D viz coordinates */
1698
+ get mountingPosition() {
1699
+ var e, o, r;
1700
+ return this.description.mounting ? [
1701
+ (((e = this.description.mounting.position) == null ? void 0 : e[0]) || 0) / 1e3,
1702
+ (((o = this.description.mounting.position) == null ? void 0 : o[1]) || 0) / 1e3,
1703
+ (((r = this.description.mounting.position) == null ? void 0 : r[2]) || 0) / 1e3
1704
+ ] : [0, 0, 0];
1705
+ }
1706
+ /** Gets the robot mounting position rotation in 3D viz coordinates */
1707
+ get mountingQuaternion() {
1708
+ var n, i, s, d, g, b;
1709
+ const e = new K.Vector3(
1710
+ ((i = (n = this.description.mounting) == null ? void 0 : n.orientation) == null ? void 0 : i[0]) || 0,
1711
+ ((d = (s = this.description.mounting) == null ? void 0 : s.orientation) == null ? void 0 : d[1]) || 0,
1712
+ ((b = (g = this.description.mounting) == null ? void 0 : g.orientation) == null ? void 0 : b[2]) || 0
1713
+ ), o = e.length(), r = e.normalize();
1714
+ return new K.Quaternion().setFromAxisAngle(r, o);
1715
+ }
1716
+ /**
1717
+ * Whether the controller is currently in a safety state
1718
+ * corresponding to an emergency stop
1719
+ */
1720
+ get isEstopActive() {
1721
+ return [
1722
+ "SAFETY_STATE_ROBOT_EMERGENCY_STOP",
1723
+ "SAFETY_STATE_DEVICE_EMERGENCY_STOP"
1724
+ ].includes(this.controllerState.safety_state);
1725
+ }
1726
+ /**
1727
+ * Whether the controller is in a safety state
1728
+ * that may be non-functional for robot pad purposes
1729
+ */
1730
+ get isMoveableSafetyState() {
1731
+ return [
1732
+ "SAFETY_STATE_NORMAL",
1733
+ "SAFETY_STATE_REDUCED"
1734
+ ].includes(this.controllerState.safety_state);
1735
+ }
1736
+ /**
1737
+ * Whether the controller is in an operation mode that allows movement
1738
+ */
1739
+ get isMoveableOperationMode() {
1740
+ return [
1741
+ "OPERATION_MODE_AUTO",
1742
+ "OPERATION_MODE_MANUAL",
1743
+ "OPERATION_MODE_MANUAL_T1",
1744
+ "OPERATION_MODE_MANUAL_T2"
1745
+ ].includes(this.controllerState.operation_mode);
1746
+ }
1747
+ /**
1748
+ * Whether the robot is currently active and can be moved, based on the
1749
+ * safety state, operation mode and servo toggle activation state.
1750
+ */
1751
+ get canBeMoved() {
1752
+ return this.isMoveableSafetyState && this.isMoveableOperationMode && this.activationState === "active";
1753
+ }
1754
+ async deactivate() {
1755
+ if (this.activationState !== "active") {
1756
+ console.error("Tried to deactivate while already deactivating");
1757
+ return;
1758
+ }
1759
+ E(() => {
1760
+ this.activationState = "deactivating";
1761
+ });
1762
+ try {
1763
+ await this.nova.api.controller.setDefaultMode(
1764
+ this.controllerId,
1765
+ "ROBOT_SYSTEM_MODE_MONITOR"
1766
+ ), E(() => {
1767
+ this.activationState = "inactive";
1768
+ });
1769
+ } catch (e) {
1770
+ throw E(() => {
1771
+ this.activationState = "active";
1772
+ }), e;
1773
+ }
1774
+ }
1775
+ async activate() {
1776
+ if (this.activationState !== "inactive") {
1777
+ console.error("Tried to activate while already activating");
1778
+ return;
1779
+ }
1780
+ E(() => {
1781
+ this.activationState = "activating";
1782
+ });
1783
+ try {
1784
+ await this.nova.api.controller.setDefaultMode(
1785
+ this.controllerId,
1786
+ "ROBOT_SYSTEM_MODE_CONTROL"
1787
+ ), E(() => {
1788
+ this.activationState = "active";
1789
+ });
1790
+ } catch (e) {
1791
+ throw E(() => {
1792
+ this.activationState = "inactive";
1793
+ }), e;
1794
+ }
1795
+ }
1796
+ toggleActivation() {
1797
+ this.activationState === "inactive" ? this.activate() : this.activationState === "active" && this.deactivate();
1798
+ }
1799
+ dispose() {
1800
+ this.motionStateSocket.close(), this.connectedJoggingSocket && this.connectedJoggingSocket.close();
1801
+ }
1802
+ setJoggingVelocity(e) {
1803
+ this.joggingVelocity = e;
1804
+ }
1805
+ }
1806
+ function ee() {
1807
+ var e, o, r, n, i, s, d;
1808
+ const t = fe({
1809
+ palette: {
1810
+ mode: "dark",
1811
+ text: {
1812
+ primary: "rgba(255, 255, 255, 1)",
1813
+ secondary: "rgba(255, 255, 255, 0.7)",
1814
+ disabled: "rgba(255, 255, 255, 0.38)"
1815
+ },
1816
+ primary: {
1817
+ main: "rgba(142, 86, 252, 1)",
1818
+ dark: "rgba(136, 58, 255, 1)",
1819
+ light: "rgba(157, 131, 246, 1)",
1820
+ contrastText: "rgba(255, 255, 255, 0.87)"
1821
+ },
1822
+ secondary: {
1823
+ main: "rgba(255, 255, 255, 1)",
1824
+ dark: "rgba(255, 255, 255, 0.06)",
1825
+ contrastText: "rgba(255, 255, 255, 0.87)"
1826
+ },
1827
+ tertiary: {
1828
+ main: "rgba(100, 255, 218, 1)",
1829
+ dark: "rgba(38, 166, 154, 1)",
1830
+ light: "rgba(167, 255, 235, 1)",
1831
+ contrastText: "rgba(0, 0, 0, 1)"
1832
+ },
1833
+ error: {
1834
+ main: "rgba(239, 83, 80, 1)",
1835
+ dark: "rgba(229, 57, 53, 1)",
1836
+ light: "rgba(239, 154, 154, 1)",
1837
+ contrastText: "rgba(255, 255, 255, 1)"
1838
+ },
1839
+ warning: {
1840
+ main: "rgba(255, 171, 64, 1)",
1841
+ dark: "rgba(255, 145, 0, 1)",
1842
+ light: "rgba(255, 209, 128, 1)",
1843
+ contrastText: "rgba(0, 0, 0, 0.87)"
1844
+ },
1845
+ success: {
1846
+ main: "rgba(38, 166, 154, 1)",
1847
+ dark: "rgba(0, 121, 107, 1)",
1848
+ light: "rgba(128, 203, 196, 1)",
1849
+ contrastText: "rgba(255, 255, 255, 0.87)"
1850
+ },
1851
+ background: {
1852
+ default: "rgba(2, 6, 23, 1)",
1853
+ paper: "rgba(17, 19, 31, 1)"
1854
+ },
1855
+ action: {
1856
+ active: "rgba(255, 255, 255, 0.56)",
1857
+ hover: "rgba(255, 255, 255, 0.08)",
1858
+ selected: "rgba(255, 255, 255, 0.16)",
1859
+ disabledBackground: "rgba(255, 255, 255, 0.12)",
1860
+ focus: "rgba(255, 255, 255, 0.12)",
1861
+ disabled: "rgba(255, 255, 255, 0.38)"
1862
+ },
1863
+ common: {
1864
+ white: "rgba(255, 255, 255, 1)",
1865
+ black: "rgba(0, 0, 0, 1)"
1866
+ },
1867
+ divider: "rgba(255, 255, 255, 0.12)",
1868
+ backgroundPaperElevation: {
1869
+ 0: "rgba(17,19,31,1.0)",
1870
+ 1: "rgba(20,22,35,1.0)",
1871
+ 2: "rgba(23,25,39,1.0)",
1872
+ 3: "rgba(26,28,43,1.0)",
1873
+ 4: "rgba(29,31,47,1.0)",
1874
+ 5: "rgba(32,34,51,1.0)",
1875
+ 6: "rgba(35,37,55,1.0)",
1876
+ 7: "rgba(38,40,59,1.0)",
1877
+ 8: "rgba(41,43,63,1.0)",
1878
+ 9: "rgba(44,46,67,1.0)",
1879
+ 10: "rgba(47,49,71,1.0)",
1880
+ 11: "rgba(50,52,75,1.0)",
1881
+ 12: "rgba(53,55,79,1.0)",
1882
+ 13: "rgba(56,58,83,1.0)",
1883
+ 14: "rgba(59,61,87,1.0)",
1884
+ 15: "rgba(62,64,91,1.0)",
1885
+ 16: "rgba(57,63,87,1.0)"
1886
+ }
1887
+ },
1888
+ paletteExt: {
1889
+ primary: {
1890
+ hover: "rgba(142, 86, 252, 0.08)",
1891
+ selected: "rgba(142, 86, 252, 0.16)",
1892
+ focus: "rgba(142, 86, 252, 0.12)",
1893
+ focusVisible: "rgba(142, 86, 252, 0.3)",
1894
+ outlineBorder: "rgba(142, 86, 252, 0.5)"
1895
+ },
1896
+ secondary: {
1897
+ tonal: "rgba(255,255,255,0.1)"
1898
+ }
1899
+ }
1900
+ });
1901
+ return {
1902
+ ...t,
1903
+ components: {
1904
+ MuiCssBaseline: {
1905
+ styleOverrides: {
1906
+ "html, body, *": {
1907
+ scrollbarWidth: "none",
1908
+ msOverflowStyle: "none"
1909
+ },
1910
+ "html:hover, body:hover, *:hover": {
1911
+ scrollbarWidth: "thin",
1912
+ scrollbarColor: `${t.palette.divider} transparent`
1913
+ },
1914
+ // Global styles for DataGrid filter popup
1915
+ ".MuiDataGrid-panelContent": {
1916
+ borderRadius: "16px !important",
1917
+ "& .MuiPaper-root": {
1918
+ borderRadius: "16px !important"
1919
+ }
1920
+ },
1921
+ ".MuiDataGrid-filterForm": {
1922
+ borderRadius: "16px !important",
1923
+ "& .MuiInputBase-root": {
1924
+ borderRadius: "16px !important",
1925
+ "& fieldset": {
1926
+ borderRadius: "16px !important"
1927
+ },
1928
+ "& .MuiOutlinedInput-notchedOutline": {
1929
+ borderRadius: "16px !important"
1930
+ }
1931
+ },
1932
+ "& .MuiTextField-root": {
1933
+ "& .MuiInputBase-root": {
1934
+ borderRadius: "16px !important",
1935
+ "& fieldset": {
1936
+ borderRadius: "16px !important"
1937
+ },
1938
+ "& .MuiOutlinedInput-notchedOutline": {
1939
+ borderRadius: "16px !important"
1940
+ }
1941
+ }
1942
+ }
1943
+ },
1944
+ ".MuiDataGrid-filterFormValueInput": {
1945
+ "& .MuiInputBase-root": {
1946
+ borderRadius: "16px !important",
1947
+ "& fieldset": {
1948
+ borderRadius: "16px !important"
1949
+ },
1950
+ "& .MuiOutlinedInput-notchedOutline": {
1951
+ borderRadius: "16px !important"
1952
+ }
1953
+ }
1954
+ }
1955
+ }
1956
+ },
1957
+ MuiDataGrid: {
1958
+ styleOverrides: {
1959
+ root: {
1960
+ // Main DataGrid styling can go here if needed
1961
+ },
1962
+ panelContent: {
1963
+ borderRadius: "16px !important"
1964
+ },
1965
+ filterForm: {
1966
+ "& .MuiInputBase-root": {
1967
+ borderRadius: "10px !important",
1968
+ "& fieldset": {
1969
+ borderRadius: "10px !important"
1970
+ },
1971
+ "& .MuiOutlinedInput-notchedOutline": {
1972
+ borderRadius: "10px !important"
1973
+ }
1974
+ }
1975
+ },
1976
+ filterFormValueInput: {
1977
+ "& .MuiInputBase-root": {
1978
+ borderRadius: "10px !important",
1979
+ "& fieldset": {
1980
+ borderRadius: "10px !important"
1981
+ },
1982
+ "& .MuiOutlinedInput-notchedOutline": {
1983
+ borderRadius: "10px !important"
1984
+ }
1985
+ }
1986
+ }
1987
+ }
1988
+ },
1989
+ MuiButton: {
1990
+ styleOverrides: {
1991
+ root: {
1992
+ textTransform: "none",
1993
+ borderRadius: "10px"
1994
+ }
1995
+ },
1996
+ variants: [
1997
+ {
1998
+ props: { color: "secondary", variant: "contained" },
1999
+ style: {
2000
+ border: `1px solid ${t.palette.divider}`,
2001
+ background: (r = (o = (e = t.paletteExt) == null ? void 0 : e.secondary) == null ? void 0 : o.tonal) == null ? void 0 : r.toString()
2002
+ }
2003
+ },
2004
+ {
2005
+ props: { color: "secondary", variant: "outlined" },
2006
+ style: {
2007
+ border: `1px solid ${t.palette.divider}`
2008
+ }
2009
+ }
2010
+ ]
2011
+ },
2012
+ MuiTab: {
2013
+ styleOverrides: {
2014
+ root: {
2015
+ textTransform: "none",
2016
+ color: t.palette.text.secondary,
2017
+ "&.Mui-selected": {
2018
+ color: t.palette.text.primary
2019
+ }
2020
+ }
2021
+ }
2022
+ },
2023
+ MuiTabs: {
2024
+ styleOverrides: {
2025
+ root: {
2026
+ background: (n = t.palette.backgroundPaperElevation) == null ? void 0 : n[1]
2027
+ }
2028
+ }
2029
+ },
2030
+ MuiToggleButtonGroup: {
2031
+ styleOverrides: {
2032
+ root: {
2033
+ ".MuiToggleButtonGroup-firstButton": {
2034
+ borderRadius: "10px 0 0 10px"
2035
+ },
2036
+ ".MuiToggleButtonGroup-lastButton": {
2037
+ borderRadius: "0 10px 10px 0"
2038
+ }
2039
+ }
2040
+ }
2041
+ },
2042
+ MuiToggleButton: {
2043
+ styleOverrides: {
2044
+ root: {
2045
+ textTransform: "none",
2046
+ padding: "6px 16px"
2047
+ }
2048
+ }
2049
+ },
2050
+ MuiSelect: {
2051
+ variants: [
2052
+ {
2053
+ props: { variant: "filled" },
2054
+ style: {
2055
+ borderRadius: "10px",
2056
+ "::before, ::after": {
2057
+ visibility: "collapse"
2058
+ },
2059
+ ".MuiInputBase-input": {
2060
+ padding: "6px 16px",
2061
+ borderRadius: "10px"
2062
+ }
2063
+ }
2064
+ }
2065
+ ]
2066
+ },
2067
+ MuiDrawer: {
2068
+ styleOverrides: {
2069
+ paper: {
2070
+ border: "none",
2071
+ boxShadow: "4px 0 8px -4px rgba(0, 0, 0, 0.3)"
2072
+ }
2073
+ }
2074
+ },
2075
+ MuiFab: {
2076
+ styleOverrides: {
2077
+ root: {
2078
+ background: (s = (i = t.paletteExt) == null ? void 0 : i.secondary) == null ? void 0 : s.tonal
2079
+ }
2080
+ },
2081
+ variants: [
2082
+ {
2083
+ props: { color: "primary" },
2084
+ style: {
2085
+ background: t.palette.primary.main
2086
+ }
2087
+ }
2088
+ ]
2089
+ }
2090
+ },
2091
+ componentsExt: {
2092
+ JoggingPanel: {
2093
+ JoggingCartesian: {
2094
+ Axis: {
2095
+ X: {
2096
+ backgroundColor: "rgba(215, 66, 56, 1)",
2097
+ borderColor: "rgba(215, 66, 56, 1)",
2098
+ buttonBackgroundColor: {
2099
+ default: "rgba(241, 77, 66, 1)",
2100
+ pressed: "rgba(138, 41, 35, 1)",
2101
+ hovered: "rgba(241, 77, 66, 1)",
2102
+ disabled: "rgba(241, 77, 66, 1)"
2103
+ },
2104
+ color: "rgba(255, 198, 198, 1)",
2105
+ labelColor: t.palette.text.primary
2106
+ },
2107
+ Y: {
2108
+ backgroundColor: "rgba(20, 151, 108, 1)",
2109
+ borderColor: "rgba(20, 151, 108, 1)",
2110
+ buttonBackgroundColor: {
2111
+ default: "rgba(28, 188, 135, 1)",
2112
+ pressed: "rgba(11, 89, 63, 1)",
2113
+ disabled: "rgba(28, 188, 135, 1)",
2114
+ hovered: "rgba(28, 188, 135, 1)"
2115
+ },
2116
+ color: "rgba(215, 255, 242, 1)",
2117
+ labelColor: t.palette.text.primary
2118
+ },
2119
+ Z: {
2120
+ backgroundColor: "rgba(1, 87, 155, 1)",
2121
+ borderColor: "rgba(1, 87, 155, 1)",
2122
+ buttonBackgroundColor: {
2123
+ default: "rgba(2, 136, 209, 1)",
2124
+ pressed: "rgba(2, 64, 114, 1)",
2125
+ disabled: "rgba(2, 136, 209, 1)",
2126
+ hovered: "rgba(2, 136, 209, 1)"
2127
+ },
2128
+ color: "rgba(210, 239, 255, 1)",
2129
+ labelColor: t.palette.text.primary
2130
+ }
2131
+ }
2132
+ },
2133
+ JoggingJoint: {
2134
+ Joint: {
2135
+ arrowColor: t.palette.text.primary
2136
+ }
2137
+ },
2138
+ VelocitySlider: {
2139
+ sliderLegendColor: t.palette.text.primary
2140
+ }
2141
+ },
2142
+ WandelscriptEditor: {
2143
+ monacoTheme: {
2144
+ base: "vs-dark",
2145
+ inherit: !0,
2146
+ rules: [
2147
+ {
2148
+ token: "keyword",
2149
+ foreground: "#b349a9ff"
2150
+ }
2151
+ ],
2152
+ colors: {
2153
+ "editor.background": ve(
2154
+ ((d = t.palette.backgroundPaperElevation) == null ? void 0 : d[5]) ?? ""
2155
+ ),
2156
+ "editor.foreground": "#d4d4d4",
2157
+ "editorLineNumber.foreground": "#797979",
2158
+ "editorLineNumber.activeForeground": "#e9e9e9",
2159
+ "editor.lineHighlightBorder": "#e9e9e911"
2160
+ }
2161
+ }
2162
+ }
2163
+ }
2164
+ };
2165
+ }
2166
+ function St() {
2167
+ const t = ee();
2168
+ return t.palette.mode = "light", t;
2169
+ }
2170
+ function Yt(t) {
2171
+ var r, n, i, s;
2172
+ let e = !0;
2173
+ ((r = t.palette) == null ? void 0 : r.mode) === "light" ? e = !1 : ((n = t.palette) == null ? void 0 : n.mode) !== "dark" && (e = !(typeof window < "u" && ((s = (i = window.matchMedia) == null ? void 0 : i.call(window, "(prefers-color-scheme: light)")) == null ? void 0 : s.matches)));
2174
+ const o = e ? ee() : St();
2175
+ return Re(o, t);
2176
+ }
2177
+ export {
2178
+ Rt as A,
2179
+ Y as C,
2180
+ De as L,
2181
+ Dt as N,
2182
+ Nt as R,
2183
+ $t as S,
2184
+ Vt as T,
2185
+ Zt as W,
2186
+ Ft as a,
2187
+ N as b,
2188
+ Yt as c,
2189
+ Bt as d,
2190
+ It as e,
2191
+ Pt as f,
2192
+ Lt as g,
2193
+ Ne as h,
2194
+ X as i,
2195
+ Ye as j,
2196
+ zt as k
2197
+ };
2198
+ //# sourceMappingURL=theming-BO8z_Hpa.js.map