@wandelbots/wandelbots-js-react-components 6.4.0-pr.revamp.667.bd2ec84 → 6.4.0-pr.revamp.667.ca77f09

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 (154) hide show
  1. package/README.md +172 -40
  2. package/dist/3d.cjs +1 -1
  3. package/dist/3d.d.ts +3 -4
  4. package/dist/3d.js +35 -38
  5. package/dist/CurrentPose/index.cjs +1 -1
  6. package/dist/CurrentPose/index.js +2 -2
  7. package/dist/CurrentPoseBar/index.cjs +1 -1
  8. package/dist/CurrentPoseBar/index.js +1 -1
  9. package/dist/JoggingButtons/index.cjs +1 -1
  10. package/dist/JoggingButtons/index.js +1 -1
  11. package/dist/JoggingGizmo/index.cjs +1 -1
  12. package/dist/JoggingGizmo/index.js +2 -2
  13. package/dist/JoggingJointSlider/index.cjs +1 -1
  14. package/dist/JoggingJointSlider/index.js +1 -1
  15. package/dist/RobotControl/index.cjs +1 -1
  16. package/dist/RobotControl/index.js +2 -2
  17. package/dist/RobotControlPanel/index.cjs +1 -1
  18. package/dist/RobotControlPanel/index.d.ts +1 -1
  19. package/dist/RobotControlPanel/index.js +1 -1
  20. package/dist/RobotHeader/index.cjs +1 -1
  21. package/dist/RobotHeader/index.d.ts +3 -5
  22. package/dist/RobotHeader/index.js +6 -7
  23. package/dist/RobotScene/index.cjs +1 -1
  24. package/dist/RobotScene/index.js +3 -3
  25. package/dist/RobotView/index.cjs +1 -1
  26. package/dist/RobotView/index.js +2 -2
  27. package/dist/SafetyBar/IndicatorWithExplanation.d.ts +12 -1
  28. package/dist/SafetyBar/SafetyBar.d.ts +15 -1
  29. package/dist/SafetyBar/index.cjs +1 -1
  30. package/dist/SafetyBar/index.d.ts +0 -1
  31. package/dist/SafetyBar/index.js +3 -4
  32. package/dist/SafetyBar/robotSafetyOf.d.ts +1 -0
  33. package/dist/chunks/{ConnectedMotionGroup-BifrgwV1.js → ConnectedMotionGroup-DNYakgxy.js} +6 -5
  34. package/dist/chunks/ConnectedMotionGroup-IRTsTxwB.cjs +3 -0
  35. package/dist/chunks/{CurrentPose-CMqO8oqX.cjs → CurrentPose-CAq9e9JY.cjs} +1 -1
  36. package/dist/chunks/{CurrentPose-CdD2ZB7B.js → CurrentPose-CgdINEh2.js} +3 -3
  37. package/dist/chunks/{CurrentPoseBar-CX1xFBtm.js → CurrentPoseBar--HkZBGnN.js} +11 -11
  38. package/dist/chunks/{CurrentPoseBar-BTBAwIO4.cjs → CurrentPoseBar-DoOUfRRs.cjs} +1 -1
  39. package/dist/chunks/{JoggingButtons-aijK-3g6.js → JoggingButtons-BNOnpcTH.js} +1 -1
  40. package/dist/chunks/{JoggingButtons-BOHl7hVq.cjs → JoggingButtons-Boaym2hQ.cjs} +1 -1
  41. package/dist/chunks/{JoggingGizmo-CoKYUtXq.cjs → JoggingGizmo-CNFjpWDv.cjs} +1 -1
  42. package/dist/chunks/{JoggingGizmo-DHvrJouR.js → JoggingGizmo-RDiEVQes.js} +1 -1
  43. package/dist/chunks/{JoggingGizmoOrientation-CIvIAIeO.js → JoggingGizmoOrientation-Dzzz2gEz.js} +1 -1
  44. package/dist/chunks/{JoggingGizmoOrientation-DVcagPRJ.cjs → JoggingGizmoOrientation-laUrgY0N.cjs} +1 -1
  45. package/dist/chunks/{JoggingJointSlider-DQtt4-pa.js → JoggingJointSlider-BY-Tof8G.js} +1 -1
  46. package/dist/chunks/{JoggingJointSlider-CTFYKzsU.cjs → JoggingJointSlider-Dm3vILd3.cjs} +1 -1
  47. package/dist/chunks/{JoggingRefusedError-BIkUM6-g.js → JoggingRefusedError-C4D8_YR_.js} +5 -3
  48. package/dist/chunks/JoggingRefusedError-DqyrfUcc.cjs +1 -0
  49. package/dist/chunks/Pose3-BfBNPRDM.cjs +1 -0
  50. package/dist/chunks/{Pose3-B_fLR-Wv.js → Pose3-DWxfC6Dj.js} +1 -2
  51. package/dist/chunks/{Robot-C-IWfxP9.js → Robot-B-VAYuAr.js} +5 -5
  52. package/dist/chunks/{Robot-Cfhjv9Z8.cjs → Robot-DRf8T9Zf.cjs} +1 -1
  53. package/dist/chunks/RobotActivation-CRVxXvlx.cjs +1 -0
  54. package/dist/chunks/RobotActivation-oR-8Y0iq.js +143 -0
  55. package/dist/chunks/RobotControl-Dbe50ZKM.cjs +1 -0
  56. package/dist/chunks/RobotControl-Ms1F7fFe.js +332 -0
  57. package/dist/chunks/RobotControlPanel-B7NxoHsO.cjs +1 -0
  58. package/dist/chunks/RobotControlPanel-CkQlkq8x.js +1029 -0
  59. package/dist/chunks/RobotHeader-CjOaf9s6.cjs +1 -0
  60. package/dist/chunks/RobotHeader-LSuRTDFB.js +395 -0
  61. package/dist/chunks/RobotScene-Au6zpHH1.cjs +1 -0
  62. package/dist/chunks/RobotScene-C6XEgaVR.js +1284 -0
  63. package/dist/chunks/RobotSessionProvider-CoF_tX0O.cjs +1 -0
  64. package/dist/chunks/RobotSessionProvider-DuHi-dtw.js +30 -0
  65. package/dist/chunks/{RobotView-BGYlAWj-.cjs → RobotView-Cg6JfGiY.cjs} +1 -1
  66. package/dist/chunks/{RobotView-D-v8jCM7.js → RobotView-CrAxNkyG.js} +3 -3
  67. package/dist/chunks/{robotSafetyOf-DuKKma1_.js → SafetyBar-C85BAKsL.js} +244 -215
  68. package/dist/chunks/SafetyBar-D2l81Omq.cjs +1 -0
  69. package/dist/chunks/externalizeComponent-CA_sHzyH.cjs +2 -0
  70. package/dist/chunks/{externalizeComponent-4juwPKL5.js → externalizeComponent-CChY_1bN.js} +34 -8
  71. package/dist/chunks/{useSmoothedMotionState-BSSV8aZN.js → hooks-BWoeBWLV.js} +43 -87
  72. package/dist/chunks/hooks-BXe2bNMo.cjs +1 -0
  73. package/dist/chunks/loadRobotSession-BzY9H3F8.cjs +1 -0
  74. package/dist/chunks/{loadRobotSession-GHHtv5dv.js → loadRobotSession-Ts2MumBB.js} +1065 -679
  75. package/dist/chunks/poseText-BxG4Caa-.js +48 -0
  76. package/dist/chunks/poseText-CwplkbDM.cjs +1 -0
  77. package/dist/chunks/useSmoothedMotionState-CCXmMZ0S.cjs +1 -0
  78. package/dist/chunks/useSmoothedMotionState-CELh-YJa.js +50 -0
  79. package/dist/components/VelocitySlider.d.ts +14 -1
  80. package/dist/components/connectionWarning/ConnectionWarning.d.ts +18 -4
  81. package/dist/components/connectionWarning/connectionWarningOf.d.ts +1 -11
  82. package/dist/components/jogging/JoggingCartesianAxisControl.d.ts +7 -1
  83. package/dist/components/jogging/JoggingCartesianTab.d.ts +6 -0
  84. package/dist/components/jogging/JoggingJointTab.d.ts +5 -0
  85. package/dist/components/jogging/JoggingJointValueControl.d.ts +7 -1
  86. package/dist/components/jogging/JoggingPanel.d.ts +11 -0
  87. package/dist/components/jogging/JoggingRefusedError.d.ts +8 -3
  88. package/dist/components/jogging/JoggingStore.d.ts +206 -17
  89. package/dist/components/jogging/joggingColors.d.ts +6 -0
  90. package/dist/components/robotControl/CartesianJogTab.d.ts +14 -3
  91. package/dist/components/robotControl/JogArea.d.ts +6 -3
  92. package/dist/components/robotControl/JogDisabledReason.d.ts +15 -0
  93. package/dist/components/robotControl/JointJogTab.d.ts +10 -2
  94. package/dist/components/robotControl/MoveToTab.d.ts +24 -3
  95. package/dist/components/robotControl/PoseField.d.ts +3 -1
  96. package/dist/components/robotControl/RobotControl.d.ts +3 -0
  97. package/dist/components/robotControl/RobotControlPanel.d.ts +91 -22
  98. package/dist/components/robotControl/VelocityRow.d.ts +8 -2
  99. package/dist/components/robotControl/atPose.d.ts +6 -0
  100. package/dist/components/robotControl/poseText.d.ts +13 -1
  101. package/dist/components/robotControl/units.d.ts +10 -2
  102. package/dist/components/robotControl/useRobotControlProps.d.ts +7 -4
  103. package/dist/components/robotControl/velocityText.d.ts +18 -0
  104. package/dist/components/robotHeader/ActivationSwitch.d.ts +13 -2
  105. package/dist/components/robotHeader/RobotHeader.d.ts +25 -4
  106. package/dist/components/robotHeader/robotActivationOf.d.ts +1 -8
  107. package/dist/components/robotScene/RobotScene.d.ts +7 -1
  108. package/dist/components/robots/MotionGroupVisualizer.d.ts +6 -4
  109. package/dist/components/robots/SupportedLinearAxis.d.ts +6 -4
  110. package/dist/components/robots/SupportedRobot.d.ts +7 -5
  111. package/dist/components/robots/useFrameSmoothedMotionState.d.ts +25 -0
  112. package/dist/components/utils/useSmoothedMotionState.d.ts +11 -2
  113. package/dist/core.cjs +1 -1
  114. package/dist/core.d.ts +8 -10
  115. package/dist/core.js +60 -69
  116. package/dist/index.cjs +1 -1
  117. package/dist/index.js +100 -113
  118. package/dist/lib/ConnectedMotionGroup.d.ts +11 -0
  119. package/dist/lib/ControllerStateStream.d.ts +9 -9
  120. package/dist/lib/JoggerConnection.d.ts +48 -13
  121. package/dist/lib/MotionStreamConnection.d.ts +3 -2
  122. package/dist/lib/TrajectoryExecutionStore.d.ts +58 -20
  123. package/dist/lib/controllerStateSource.d.ts +6 -5
  124. package/dist/lib/robotSession/RobotActivation.d.ts +52 -21
  125. package/dist/lib/robotSession/RobotSession.d.ts +27 -8
  126. package/dist/lib/robotSession/RobotTargetPose.d.ts +4 -2
  127. package/dist/lib/robotSession/loadRobotSession.d.ts +1 -1
  128. package/dist/lib/robotSession/robotPose.d.ts +0 -6
  129. package/dist/session.cjs +1 -1
  130. package/dist/session.d.ts +6 -6
  131. package/dist/session.js +30 -38
  132. package/package.json +22 -1
  133. package/dist/chunks/ConnectedMotionGroup-CybwJHkh.cjs +0 -3
  134. package/dist/chunks/JoggingRefusedError-BuCGsVsa.cjs +0 -1
  135. package/dist/chunks/Pose3-Ch4xVeXV.cjs +0 -1
  136. package/dist/chunks/RobotActivation-Bb0oNSBN.cjs +0 -1
  137. package/dist/chunks/RobotActivation-C0rrwpQZ.js +0 -115
  138. package/dist/chunks/RobotControl-Cv6Sr1Ni.js +0 -289
  139. package/dist/chunks/RobotControl-DFnOYMAa.cjs +0 -1
  140. package/dist/chunks/RobotControlPanel-B1_9g9D-.js +0 -850
  141. package/dist/chunks/RobotControlPanel-BpTpRBgy.cjs +0 -1
  142. package/dist/chunks/RobotScene-0ZJzXL50.cjs +0 -1
  143. package/dist/chunks/RobotScene-DpFeFpnx.js +0 -1255
  144. package/dist/chunks/RobotSessionProvider--AekyPqD.cjs +0 -1
  145. package/dist/chunks/RobotSessionProvider-TVaKGzqa.js +0 -25
  146. package/dist/chunks/externalizeComponent-Br_U-QAr.cjs +0 -2
  147. package/dist/chunks/loadRobotSession-DYbeNnTI.cjs +0 -1
  148. package/dist/chunks/poseText-BXUaQWnK.cjs +0 -1
  149. package/dist/chunks/poseText-pg4cxE8R.js +0 -41
  150. package/dist/chunks/robotActivationOf-B4oV10Za.cjs +0 -1
  151. package/dist/chunks/robotActivationOf-EzcT9g07.js +0 -368
  152. package/dist/chunks/robotSafetyOf-Dxm6s7Pp.cjs +0 -1
  153. package/dist/chunks/useSmoothedMotionState-B9WO73k0.cjs +0 -1
  154. package/dist/components/robotHeader/robotSafetyOf.d.ts +0 -11
@@ -1,65 +1,80 @@
1
- import { jsxs as h, Fragment as x, jsx as n } from "react/jsx-runtime";
2
- import b from "@mui/material/Divider";
3
- import E from "@mui/material/Stack";
4
- import { observer as f, useLocalObservable as _ } from "mobx-react-lite";
5
- import { e as O } from "./externalizeComponent-4juwPKL5.js";
6
- import { useTheme as y } from "@mui/material/styles";
7
- import * as r from "react";
8
- import { forwardRef as d, useId as v } from "react";
9
- import { useTranslation as T, Trans as s } from "react-i18next";
10
- import R from "@mui/material/Popover";
11
- import B from "@mui/material/SvgIcon";
12
- import u from "@mui/material/Typography";
13
- import { AxiosError as w } from "axios";
14
- import { a as F } from "./json-3cqBD7UQ.js";
1
+ import { jsxs as h, Fragment as O, jsx as n } from "react/jsx-runtime";
2
+ import M from "@mui/material/Divider";
3
+ import v from "@mui/material/Stack";
4
+ import { observer as u, useLocalObservable as B } from "mobx-react-lite";
5
+ import { b as R } from "./RobotSessionProvider-DuHi-dtw.js";
6
+ import { e as N } from "./externalizeComponent-CChY_1bN.js";
7
+ import { useTheme as T } from "@mui/material/styles";
8
+ import * as l from "react";
9
+ import { forwardRef as m, useId as A } from "react";
10
+ import { useTranslation as w, Trans as d } from "react-i18next";
11
+ import $ from "@mui/material/Popover";
12
+ import F from "@mui/material/SvgIcon";
13
+ import b from "@mui/material/Typography";
14
+ import { AxiosError as x } from "axios";
15
+ import { a as C } from "./json-3cqBD7UQ.js";
15
16
  function Z(e, t) {
16
17
  throw new Error(`${t} ${JSON.stringify(e)}`);
17
18
  }
18
- function fe(e) {
19
- var t, a, o, l;
20
- return e instanceof w && e.code === "ERR_NETWORK" ? "Failed to connect to the server. Please check your internet connection." : e instanceof w && e.response ? `${(t = e.response) == null ? void 0 : t.status} ${(a = e.response) == null ? void 0 : a.statusText} from ${(o = e.response) == null ? void 0 : o.config.url}: ${JSON.stringify((l = e.response) == null ? void 0 : l.data)}` : e instanceof Error ? e.message : `Unexpected error: ${F(e) || e}`;
19
+ function ve(e) {
20
+ var t, o, r, a;
21
+ return e instanceof x && e.code === "ERR_NETWORK" ? "Failed to connect to the server. Please check your internet connection." : e instanceof x && e.response ? `${(t = e.response) == null ? void 0 : t.status} ${(o = e.response) == null ? void 0 : o.statusText} from ${(r = e.response) == null ? void 0 : r.config.url}: ${JSON.stringify((a = e.response) == null ? void 0 : a.data)}` : e instanceof Error ? e.message : `Unexpected error: ${C(e) || e}`;
21
22
  }
22
- const C = ({
23
+ function P(e) {
24
+ const { controllerState: t } = e.state;
25
+ return {
26
+ isVirtual: e.description.isVirtual,
27
+ motionGroupId: e.motionGroupId,
28
+ operationMode: t.operation_mode,
29
+ safetyState: t.safety_state
30
+ };
31
+ }
32
+ const I = ({
23
33
  title: e,
24
34
  titleId: t,
25
- ...a
26
- }, o) => /* @__PURE__ */ r.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: o, "aria-labelledby": t, ...a }, e ? /* @__PURE__ */ r.createElement("title", { id: t }, e) : null, /* @__PURE__ */ r.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" })), $ = d(C), P = ({
35
+ ...o
36
+ }, r) => /* @__PURE__ */ l.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": t, ...o }, e ? /* @__PURE__ */ l.createElement("title", { id: t }, e) : null, /* @__PURE__ */ l.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" })), V = m(I), Y = ({
27
37
  title: e,
28
38
  titleId: t,
29
- ...a
30
- }, o) => /* @__PURE__ */ r.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: o, "aria-labelledby": t, ...a }, e ? /* @__PURE__ */ r.createElement("title", { id: t }, e) : null, /* @__PURE__ */ r.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" })), N = d(P), p = f(
39
+ ...o
40
+ }, r) => /* @__PURE__ */ l.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": t, ...o }, e ? /* @__PURE__ */ l.createElement("title", { id: t }, e) : null, /* @__PURE__ */ l.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" })), L = m(Y), S = u(
31
41
  ({
32
42
  id: e,
33
- icon: t,
43
+ testId: t,
44
+ accessibleName: o,
45
+ icon: r,
34
46
  color: a,
35
- title: o,
36
- name: l,
47
+ title: c,
48
+ name: s,
37
49
  label: i,
38
- explanation: c,
39
- literalValue: m,
40
- anchorOrigin: A,
50
+ explanation: p,
51
+ literalValue: y,
52
+ anchorOrigin: E,
41
53
  transformOrigin: g
42
54
  }) => {
43
- const S = _(() => ({
55
+ const f = B(() => ({
44
56
  anchorEl: null,
45
57
  get isPopoverOpen() {
46
- return !!S.anchorEl;
58
+ return !!f.anchorEl;
47
59
  },
48
- openPopover(M) {
49
- S.anchorEl = M.currentTarget;
60
+ openPopover(_) {
61
+ f.anchorEl = _.currentTarget;
50
62
  },
51
63
  closePopover() {
52
- S.anchorEl = null;
64
+ f.anchorEl = null;
53
65
  }
54
66
  }));
55
- return /* @__PURE__ */ h(x, { children: [
67
+ return /* @__PURE__ */ h(O, { children: [
56
68
  /* @__PURE__ */ h(
57
- E,
69
+ v,
58
70
  {
59
- "aria-owns": S.isPopoverOpen ? e : void 0,
71
+ "data-testid": t,
72
+ role: "img",
73
+ "aria-label": o,
74
+ "aria-owns": f.isPopoverOpen ? e : void 0,
60
75
  "aria-haspopup": "true",
61
- onMouseEnter: S.openPopover,
62
- onMouseLeave: S.closePopover,
76
+ onMouseEnter: f.openPopover,
77
+ onMouseLeave: f.closePopover,
63
78
  direction: "row",
64
79
  spacing: 1,
65
80
  sx: {
@@ -67,9 +82,9 @@ const C = ({
67
82
  },
68
83
  children: [
69
84
  /* @__PURE__ */ n(
70
- B,
85
+ F,
71
86
  {
72
- component: t,
87
+ component: r,
73
88
  sx: {
74
89
  color: a
75
90
  }
@@ -88,15 +103,15 @@ const C = ({
88
103
  }
89
104
  ),
90
105
  /* @__PURE__ */ n(
91
- R,
106
+ $,
92
107
  {
93
108
  id: e,
94
109
  sx: {
95
110
  pointerEvents: "none"
96
111
  },
97
- open: S.isPopoverOpen,
98
- anchorEl: S.anchorEl,
99
- anchorOrigin: A ?? {
112
+ open: f.isPopoverOpen,
113
+ anchorEl: f.anchorEl,
114
+ anchorOrigin: E ?? {
100
115
  vertical: "bottom",
101
116
  horizontal: "left"
102
117
  },
@@ -104,10 +119,10 @@ const C = ({
104
119
  vertical: "top",
105
120
  horizontal: "left"
106
121
  },
107
- onClose: S.closePopover,
122
+ onClose: f.closePopover,
108
123
  disableRestoreFocus: !0,
109
124
  children: /* @__PURE__ */ h(
110
- E,
125
+ v,
111
126
  {
112
127
  gap: "1rem",
113
128
  padding: 2,
@@ -117,20 +132,20 @@ const C = ({
117
132
  },
118
133
  children: [
119
134
  /* @__PURE__ */ h("div", { children: [
120
- o && /* @__PURE__ */ n(u, { component: "span", fontSize: "14px", children: `${o}: ` }),
135
+ c && /* @__PURE__ */ n(b, { component: "span", fontSize: "14px", children: `${c}: ` }),
121
136
  /* @__PURE__ */ n(
122
- u,
137
+ b,
123
138
  {
124
139
  component: "span",
125
140
  color: a,
126
141
  fontWeight: "bold",
127
142
  fontSize: "14px",
128
- children: l
143
+ children: s
129
144
  }
130
145
  )
131
146
  ] }),
132
- /* @__PURE__ */ n(u, { fontSize: "14px", children: c }),
133
- m && /* @__PURE__ */ n(u, { fontSize: "12px", children: m })
147
+ /* @__PURE__ */ n(b, { fontSize: "14px", children: p }),
148
+ y && /* @__PURE__ */ n(b, { fontSize: "12px", children: y })
134
149
  ]
135
150
  }
136
151
  )
@@ -138,25 +153,27 @@ const C = ({
138
153
  )
139
154
  ] });
140
155
  }
141
- ), V = f(
156
+ ), K = u(
142
157
  ({
143
158
  isVirtual: e,
144
159
  motionGroupId: t,
145
- anchorOrigin: a,
146
- transformOrigin: o,
147
- compact: l
160
+ anchorOrigin: o,
161
+ transformOrigin: r,
162
+ compact: a
148
163
  }) => {
149
- const i = y(), c = v(), { t: m } = T();
164
+ const c = T(), s = A(), { t: i } = w(), p = (y) => `${i("SafetyBar.ControllerType.ti")}: ${y}`;
150
165
  return e ? /* @__PURE__ */ n(
151
- p,
166
+ S,
152
167
  {
153
- id: `motion-group-virtual-${c}`,
154
- icon: N,
155
- color: i.palette.tertiary.main,
156
- name: m("SafetyBar.ControllerType.Virtual.lb"),
157
- label: l ? null : m("SafetyBar.ControllerType.Virtual.lb"),
168
+ id: `motion-group-virtual-${s}`,
169
+ testId: "controller-type-indicator",
170
+ accessibleName: p(i("SafetyBar.ControllerType.Virtual.lb")),
171
+ icon: L,
172
+ color: c.palette.tertiary.main,
173
+ name: i("SafetyBar.ControllerType.Virtual.lb"),
174
+ label: a ? null : i("SafetyBar.ControllerType.Virtual.lb"),
158
175
  explanation: /* @__PURE__ */ h(
159
- s,
176
+ d,
160
177
  {
161
178
  i18nKey: "SafetyBar.MotionGroup.Virtual.Explanation.lb",
162
179
  values: {
@@ -169,19 +186,21 @@ const C = ({
169
186
  ]
170
187
  }
171
188
  ),
172
- anchorOrigin: a,
173
- transformOrigin: o
189
+ anchorOrigin: o,
190
+ transformOrigin: r
174
191
  }
175
192
  ) : /* @__PURE__ */ n(
176
- p,
193
+ S,
177
194
  {
178
- id: `motion-group-physical-${c}`,
179
- icon: $,
180
- color: i.palette.primary.main,
181
- name: m("SafetyBar.ControllerType.Physical.lb"),
182
- label: l ? null : m("SafetyBar.ControllerType.Physical.lb"),
195
+ id: `motion-group-physical-${s}`,
196
+ testId: "controller-type-indicator",
197
+ accessibleName: p(i("SafetyBar.ControllerType.Physical.lb")),
198
+ icon: V,
199
+ color: c.palette.primary.main,
200
+ name: i("SafetyBar.ControllerType.Physical.lb"),
201
+ label: a ? null : i("SafetyBar.ControllerType.Physical.lb"),
183
202
  explanation: /* @__PURE__ */ n(
184
- s,
203
+ d,
185
204
  {
186
205
  i18nKey: "SafetyBar.MotionGroup.Physical.Explanation.lb",
187
206
  values: {
@@ -190,144 +209,154 @@ const C = ({
190
209
  components: { code: /* @__PURE__ */ n("code", {}), strong: /* @__PURE__ */ n("strong", {}) }
191
210
  }
192
211
  ),
193
- anchorOrigin: a,
194
- transformOrigin: o
212
+ anchorOrigin: o,
213
+ transformOrigin: r
195
214
  }
196
215
  );
197
216
  }
198
- ), Y = ({
217
+ ), H = ({
199
218
  title: e,
200
219
  titleId: t,
201
- ...a
202
- }, o) => /* @__PURE__ */ r.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: o, "aria-labelledby": t, ...a }, e ? /* @__PURE__ */ r.createElement("title", { id: t }, e) : null, /* @__PURE__ */ r.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" })), L = d(Y), I = ({
220
+ ...o
221
+ }, r) => /* @__PURE__ */ l.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": t, ...o }, e ? /* @__PURE__ */ l.createElement("title", { id: t }, e) : null, /* @__PURE__ */ l.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" })), U = m(H), D = ({
203
222
  title: e,
204
223
  titleId: t,
205
- ...a
206
- }, o) => /* @__PURE__ */ r.createElement("svg", { width: 24, height: 24, fill: "none", xmlns: "http://www.w3.org/2000/svg", ref: o, "aria-labelledby": t, ...a }, e ? /* @__PURE__ */ r.createElement("title", { id: t }, e) : null, /* @__PURE__ */ r.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 })), K = d(I), H = ({
224
+ ...o
225
+ }, r) => /* @__PURE__ */ l.createElement("svg", { width: 24, height: 24, fill: "none", xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": t, ...o }, e ? /* @__PURE__ */ l.createElement("title", { id: t }, e) : null, /* @__PURE__ */ l.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 })), q = m(D), z = ({
207
226
  title: e,
208
227
  titleId: t,
209
- ...a
210
- }, o) => /* @__PURE__ */ r.createElement("svg", { width: 24, height: 24, fill: "none", xmlns: "http://www.w3.org/2000/svg", ref: o, "aria-labelledby": t, ...a }, e ? /* @__PURE__ */ r.createElement("title", { id: t }, e) : null, /* @__PURE__ */ r.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" })), U = d(H), D = f(
228
+ ...o
229
+ }, r) => /* @__PURE__ */ l.createElement("svg", { width: 24, height: 24, fill: "none", xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": t, ...o }, e ? /* @__PURE__ */ l.createElement("title", { id: t }, e) : null, /* @__PURE__ */ l.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" })), G = m(z), W = u(
211
230
  ({
212
231
  operationMode: e,
213
232
  anchorOrigin: t,
214
- transformOrigin: a,
215
- compact: o
233
+ transformOrigin: o,
234
+ compact: r
216
235
  }) => {
217
- const { t: l } = T(), i = y(), c = v();
236
+ const { t: a } = w(), c = T(), s = A(), i = (p) => `${a("SafetyBar.OperationMode.ti")}: ${p}`;
218
237
  switch (e) {
219
238
  case "OPERATION_MODE_AUTO":
220
239
  return /* @__PURE__ */ n(
221
- p,
240
+ S,
222
241
  {
223
- id: `operation-mode-auto-${c}`,
224
- icon: L,
225
- title: l("SafetyBar.OperationMode.ti"),
226
- name: l("SafetyBar.OperationMode.Automatic.ti"),
227
- label: o ? null : l("SafetyBar.OperationMode.Automatic.ti"),
228
- color: i.palette.text.secondary,
229
- explanation: /* @__PURE__ */ n(s, { 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." }),
242
+ id: `operation-mode-auto-${s}`,
243
+ testId: "operation-mode-indicator",
244
+ accessibleName: i(a("SafetyBar.OperationMode.Automatic.ti")),
245
+ icon: U,
246
+ title: a("SafetyBar.OperationMode.ti"),
247
+ name: a("SafetyBar.OperationMode.Automatic.ti"),
248
+ label: r ? null : a("SafetyBar.OperationMode.Automatic.ti"),
249
+ color: c.palette.text.secondary,
250
+ explanation: /* @__PURE__ */ n(d, { 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." }),
230
251
  anchorOrigin: t,
231
- transformOrigin: a
252
+ transformOrigin: o
232
253
  }
233
254
  );
234
255
  case "OPERATION_MODE_MANUAL":
235
256
  case "OPERATION_MODE_MANUAL_T1":
236
257
  case "OPERATION_MODE_MANUAL_T2":
237
258
  return /* @__PURE__ */ n(
238
- p,
259
+ S,
239
260
  {
240
- id: `operation-mode-manual-${c}`,
241
- icon: U,
242
- color: i.palette.warning.main,
243
- title: l("SafetyBar.OperationMode.ti"),
244
- name: l("SafetyBar.OperationMode.Manual.lb"),
245
- label: o ? null : l("SafetyBar.OperationMode.Manual.lb"),
246
- explanation: /* @__PURE__ */ n(s, { 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." }),
261
+ id: `operation-mode-manual-${s}`,
262
+ testId: "operation-mode-indicator",
263
+ accessibleName: i(a("SafetyBar.OperationMode.Manual.lb")),
264
+ icon: G,
265
+ color: c.palette.warning.main,
266
+ title: a("SafetyBar.OperationMode.ti"),
267
+ name: a("SafetyBar.OperationMode.Manual.lb"),
268
+ label: r ? null : a("SafetyBar.OperationMode.Manual.lb"),
269
+ explanation: /* @__PURE__ */ n(d, { 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." }),
247
270
  literalValue: e,
248
271
  anchorOrigin: t,
249
- transformOrigin: a
272
+ transformOrigin: o
250
273
  }
251
274
  );
252
275
  default:
253
276
  return /* @__PURE__ */ n(
254
- p,
277
+ S,
255
278
  {
256
- id: `operation-mode-error-${c}`,
257
- icon: K,
258
- color: i.palette.warning.main,
259
- title: l("SafetyBar.OperationMode.ti"),
260
- name: l("SafetyBar.OperationMode.Error.lb"),
261
- label: o ? null : l("SafetyBar.OperationMode.Error.lb"),
262
- explanation: /* @__PURE__ */ n(s, { i18nKey: "SafetyBar.OperationMode.Error.Explanation.lb", children: "The robot controller has entered an unexpected operation mode. Motion group movement may not be possible." }),
279
+ id: `operation-mode-error-${s}`,
280
+ testId: "operation-mode-indicator",
281
+ accessibleName: i(a("SafetyBar.OperationMode.Error.lb")),
282
+ icon: q,
283
+ color: c.palette.warning.main,
284
+ title: a("SafetyBar.OperationMode.ti"),
285
+ name: a("SafetyBar.OperationMode.Error.lb"),
286
+ label: r ? null : a("SafetyBar.OperationMode.Error.lb"),
287
+ explanation: /* @__PURE__ */ n(d, { i18nKey: "SafetyBar.OperationMode.Error.Explanation.lb", children: "The robot controller has entered an unexpected operation mode. Motion group movement may not be possible." }),
263
288
  literalValue: e,
264
289
  anchorOrigin: t,
265
- transformOrigin: a
290
+ transformOrigin: o
266
291
  }
267
292
  );
268
293
  }
269
294
  }
270
- ), z = ({
295
+ ), k = ({
271
296
  title: e,
272
297
  titleId: t,
273
- ...a
274
- }, o) => /* @__PURE__ */ r.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: o, "aria-labelledby": t, ...a }, e ? /* @__PURE__ */ r.createElement("title", { id: t }, e) : null, /* @__PURE__ */ r.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" })), q = d(z), W = ({
298
+ ...o
299
+ }, r) => /* @__PURE__ */ l.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": t, ...o }, e ? /* @__PURE__ */ l.createElement("title", { id: t }, e) : null, /* @__PURE__ */ l.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" })), J = m(k), j = ({
275
300
  title: e,
276
301
  titleId: t,
277
- ...a
278
- }, o) => /* @__PURE__ */ r.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: o, "aria-labelledby": t, ...a }, e ? /* @__PURE__ */ r.createElement("title", { id: t }, e) : null, /* @__PURE__ */ r.createElement("path", { d: "M10.24 10.636 12 13.764l1.76-3.128h-3.52Z" }), /* @__PURE__ */ r.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__ */ r.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" })), k = d(W), G = ({
302
+ ...o
303
+ }, r) => /* @__PURE__ */ l.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": t, ...o }, e ? /* @__PURE__ */ l.createElement("title", { id: t }, e) : null, /* @__PURE__ */ l.createElement("path", { d: "M10.24 10.636 12 13.764l1.76-3.128h-3.52Z" }), /* @__PURE__ */ l.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__ */ l.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" })), Q = m(j), X = ({
279
304
  title: e,
280
305
  titleId: t,
281
- ...a
282
- }, o) => /* @__PURE__ */ r.createElement("svg", { width: 24, height: 24, fill: "none", xmlns: "http://www.w3.org/2000/svg", ref: o, "aria-labelledby": t, ...a }, e ? /* @__PURE__ */ r.createElement("title", { id: t }, e) : null, /* @__PURE__ */ r.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 })), J = d(G), j = ({
306
+ ...o
307
+ }, r) => /* @__PURE__ */ l.createElement("svg", { width: 24, height: 24, fill: "none", xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": t, ...o }, e ? /* @__PURE__ */ l.createElement("title", { id: t }, e) : null, /* @__PURE__ */ l.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 })), ee = m(X), te = ({
283
308
  title: e,
284
309
  titleId: t,
285
- ...a
286
- }, o) => /* @__PURE__ */ r.createElement("svg", { width: 24, height: 24, fill: "none", xmlns: "http://www.w3.org/2000/svg", ref: o, "aria-labelledby": t, ...a }, e ? /* @__PURE__ */ r.createElement("title", { id: t }, e) : null, /* @__PURE__ */ r.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" })), Q = d(j), X = ({
310
+ ...o
311
+ }, r) => /* @__PURE__ */ l.createElement("svg", { width: 24, height: 24, fill: "none", xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": t, ...o }, e ? /* @__PURE__ */ l.createElement("title", { id: t }, e) : null, /* @__PURE__ */ l.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" })), ae = m(te), oe = ({
287
312
  title: e,
288
313
  titleId: t,
289
- ...a
290
- }, o) => /* @__PURE__ */ r.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: o, "aria-labelledby": t, ...a }, e ? /* @__PURE__ */ r.createElement("title", { id: t }, e) : null, /* @__PURE__ */ r.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" })), ee = d(X), te = f(
314
+ ...o
315
+ }, r) => /* @__PURE__ */ l.createElement("svg", { width: 24, height: 24, xmlns: "http://www.w3.org/2000/svg", ref: r, "aria-labelledby": t, ...o }, e ? /* @__PURE__ */ l.createElement("title", { id: t }, e) : null, /* @__PURE__ */ l.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" })), re = m(oe), ne = u(
291
316
  ({
292
317
  safetyState: e,
293
318
  anchorOrigin: t,
294
- transformOrigin: a,
295
- compact: o
319
+ transformOrigin: o,
320
+ compact: r
296
321
  }) => {
297
- const { t: l } = T(), i = y(), c = v();
322
+ const { t: a } = w(), c = T(), s = A(), i = (p) => `${a("SafetyBar.SafetyState.ti")}: ${p}`;
298
323
  switch (e) {
299
324
  // Normal state, robot can move
300
325
  case "SAFETY_STATE_NORMAL":
301
326
  return /* @__PURE__ */ n(
302
- p,
327
+ S,
303
328
  {
304
- id: `safety-state-normal-${c}`,
305
- title: l("SafetyBar.SafetyState.ti"),
306
- name: l("SafetyBar.SafetyState.Normal.lb"),
307
- label: o ? null : l("SafetyBar.SafetyState.Normal.lb"),
308
- icon: Q,
309
- color: i.palette.text.secondary,
310
- explanation: /* @__PURE__ */ n(s, { i18nKey: "SafetyBar.SafetyState.Normal.Explanation.lb", children: "The robot controller is in a normal safety state. Movement is not prevented by this state." }),
329
+ id: `safety-state-normal-${s}`,
330
+ testId: "safety-state-indicator",
331
+ accessibleName: i(a("SafetyBar.SafetyState.Normal.lb")),
332
+ title: a("SafetyBar.SafetyState.ti"),
333
+ name: a("SafetyBar.SafetyState.Normal.lb"),
334
+ label: r ? null : a("SafetyBar.SafetyState.Normal.lb"),
335
+ icon: ae,
336
+ color: c.palette.text.secondary,
337
+ explanation: /* @__PURE__ */ n(d, { i18nKey: "SafetyBar.SafetyState.Normal.Explanation.lb", children: "The robot controller is in a normal safety state. Movement is not prevented by this state." }),
311
338
  anchorOrigin: t,
312
- transformOrigin: a
339
+ transformOrigin: o
313
340
  }
314
341
  );
315
342
  // Estop
316
343
  case "SAFETY_STATE_DEVICE_EMERGENCY_STOP":
317
344
  case "SAFETY_STATE_ROBOT_EMERGENCY_STOP":
318
345
  return /* @__PURE__ */ n(
319
- p,
346
+ S,
320
347
  {
321
- id: `safety-state-estop-${c}`,
322
- title: l("SafetyBar.SafetyState.ti"),
323
- name: l("SafetyBar.SafetyState.Estop.lb"),
324
- label: o ? null : l("SafetyBar.SafetyState.Estop.lb"),
325
- icon: k,
326
- color: i.palette.error.main,
327
- explanation: /* @__PURE__ */ n(s, { 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." }),
348
+ id: `safety-state-estop-${s}`,
349
+ testId: "safety-state-indicator",
350
+ accessibleName: i(a("SafetyBar.SafetyState.Estop.lb")),
351
+ title: a("SafetyBar.SafetyState.ti"),
352
+ name: a("SafetyBar.SafetyState.Estop.lb"),
353
+ label: r ? null : a("SafetyBar.SafetyState.Estop.lb"),
354
+ icon: Q,
355
+ color: c.palette.error.main,
356
+ explanation: /* @__PURE__ */ n(d, { 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." }),
328
357
  literalValue: e,
329
358
  anchorOrigin: t,
330
- transformOrigin: a
359
+ transformOrigin: o
331
360
  }
332
361
  );
333
362
  // General stop
@@ -337,18 +366,20 @@ const C = ({
337
366
  case "SAFETY_STATE_PROTECTIVE_STOP":
338
367
  case "SAFETY_STATE_STOP":
339
368
  return /* @__PURE__ */ n(
340
- p,
369
+ S,
341
370
  {
342
- id: `safety-state-stop-${c}`,
343
- icon: ee,
344
- title: l("SafetyBar.SafetyState.ti"),
345
- name: l("SafetyBar.SafetyState.Stop.lb"),
346
- label: o ? null : l("SafetyBar.SafetyState.Stop.lb"),
347
- color: i.palette.warning.main,
348
- explanation: /* @__PURE__ */ n(s, { 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." }),
371
+ id: `safety-state-stop-${s}`,
372
+ testId: "safety-state-indicator",
373
+ accessibleName: i(a("SafetyBar.SafetyState.Stop.lb")),
374
+ icon: re,
375
+ title: a("SafetyBar.SafetyState.ti"),
376
+ name: a("SafetyBar.SafetyState.Stop.lb"),
377
+ label: r ? null : a("SafetyBar.SafetyState.Stop.lb"),
378
+ color: c.palette.warning.main,
379
+ explanation: /* @__PURE__ */ n(d, { 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." }),
349
380
  literalValue: e,
350
381
  anchorOrigin: t,
351
- transformOrigin: a
382
+ transformOrigin: o
352
383
  }
353
384
  );
354
385
  // Manual action required
@@ -359,106 +390,104 @@ const C = ({
359
390
  case "SAFETY_STATE_RECOVERY":
360
391
  case "SAFETY_STATE_VIOLATION":
361
392
  return /* @__PURE__ */ n(
362
- p,
393
+ S,
363
394
  {
364
- id: `safety-state-manual-action-required-${c}`,
365
- icon: J,
366
- color: i.palette.warning.main,
367
- title: l("SafetyBar.SafetyState.ti"),
368
- name: l("SafetyBar.SafetyState.ManualActionRequired.lb"),
369
- label: o ? null : l("SafetyBar.SafetyState.ManualActionRequired.lb"),
370
- explanation: /* @__PURE__ */ n(s, { i18nKey: "SafetyBar.SafetyState.ManualActionRequired.Explanation.lb", children: "The robot controller has entered a safety state requiring manual action to resolve." }),
395
+ id: `safety-state-manual-action-required-${s}`,
396
+ testId: "safety-state-indicator",
397
+ accessibleName: i(
398
+ a("SafetyBar.SafetyState.ManualActionRequired.lb")
399
+ ),
400
+ icon: ee,
401
+ color: c.palette.warning.main,
402
+ title: a("SafetyBar.SafetyState.ti"),
403
+ name: a("SafetyBar.SafetyState.ManualActionRequired.lb"),
404
+ label: r ? null : a("SafetyBar.SafetyState.ManualActionRequired.lb"),
405
+ explanation: /* @__PURE__ */ n(d, { i18nKey: "SafetyBar.SafetyState.ManualActionRequired.Explanation.lb", children: "The robot controller has entered a safety state requiring manual action to resolve." }),
371
406
  literalValue: e,
372
407
  anchorOrigin: t,
373
- transformOrigin: a
408
+ transformOrigin: o
374
409
  }
375
410
  );
376
411
  // Error
377
412
  case "SAFETY_STATE_UNKNOWN":
378
413
  case "SAFETY_STATE_FAULT":
379
414
  return /* @__PURE__ */ n(
380
- p,
415
+ S,
381
416
  {
382
- id: `safety-state-error-${c}`,
383
- icon: q,
384
- color: i.palette.error.main,
385
- title: l("SafetyBar.SafetyState.ti"),
386
- name: l("SafetyBar.SafetyState.Error.lb"),
387
- label: o ? null : l("SafetyBar.SafetyState.Error.lb"),
388
- explanation: /* @__PURE__ */ n(s, { i18nKey: "SafetyBar.SafetyState.Error.Explanation.lb", children: "The robot controller has entered an unexpected safety state." }),
417
+ id: `safety-state-error-${s}`,
418
+ testId: "safety-state-indicator",
419
+ accessibleName: i(a("SafetyBar.SafetyState.Error.lb")),
420
+ icon: J,
421
+ color: c.palette.error.main,
422
+ title: a("SafetyBar.SafetyState.ti"),
423
+ name: a("SafetyBar.SafetyState.Error.lb"),
424
+ label: r ? null : a("SafetyBar.SafetyState.Error.lb"),
425
+ explanation: /* @__PURE__ */ n(d, { i18nKey: "SafetyBar.SafetyState.Error.Explanation.lb", children: "The robot controller has entered an unexpected safety state." }),
389
426
  literalValue: e,
390
427
  anchorOrigin: t,
391
- transformOrigin: a
428
+ transformOrigin: o
392
429
  }
393
430
  );
394
431
  default:
395
432
  Z(e, `Unknown safety state ${e}`);
396
433
  }
397
434
  }
398
- ), ue = O(
399
- f(
400
- ({
401
- isVirtual: e,
402
- motionGroupId: t,
403
- operationMode: a,
404
- safetyState: o,
405
- anchorOrigin: l,
406
- transformOrigin: i,
407
- compact: c = !0
408
- }) => /* @__PURE__ */ h(
409
- E,
435
+ ), Te = N(
436
+ u((e) => {
437
+ const {
438
+ session: t,
439
+ anchorOrigin: o,
440
+ transformOrigin: r,
441
+ compact: a = !0,
442
+ ...c
443
+ } = e, s = R(t), { isVirtual: i, motionGroupId: p, operationMode: y, safetyState: E } = {
444
+ ...s && P(s),
445
+ ...c
446
+ };
447
+ return i === void 0 || p === void 0 || y === void 0 || E === void 0 ? null : /* @__PURE__ */ h(
448
+ v,
410
449
  {
411
450
  direction: "row",
412
- gap: c ? 1 : 2,
451
+ gap: a ? 1 : 2,
413
452
  alignItems: "center",
414
453
  sx: { height: "24px" },
415
454
  children: [
416
455
  /* @__PURE__ */ n(
417
- te,
456
+ ne,
418
457
  {
419
- safetyState: o,
420
- anchorOrigin: l,
421
- transformOrigin: i,
422
- compact: c
458
+ safetyState: E,
459
+ anchorOrigin: o,
460
+ transformOrigin: r,
461
+ compact: a
423
462
  }
424
463
  ),
425
- /* @__PURE__ */ n(b, { orientation: "vertical", flexItem: !0 }),
464
+ /* @__PURE__ */ n(M, { orientation: "vertical", flexItem: !0 }),
426
465
  /* @__PURE__ */ n(
427
- D,
466
+ W,
428
467
  {
429
- operationMode: a,
430
- anchorOrigin: l,
431
- transformOrigin: i,
432
- compact: c
468
+ operationMode: y,
469
+ anchorOrigin: o,
470
+ transformOrigin: r,
471
+ compact: a
433
472
  }
434
473
  ),
435
- /* @__PURE__ */ n(b, { orientation: "vertical", flexItem: !0 }),
474
+ /* @__PURE__ */ n(M, { orientation: "vertical", flexItem: !0 }),
436
475
  /* @__PURE__ */ n(
437
- V,
476
+ K,
438
477
  {
439
- isVirtual: e,
440
- motionGroupId: t,
441
- anchorOrigin: l,
442
- transformOrigin: i,
443
- compact: c
478
+ isVirtual: i,
479
+ motionGroupId: p,
480
+ anchorOrigin: o,
481
+ transformOrigin: r,
482
+ compact: a
444
483
  }
445
484
  )
446
485
  ]
447
486
  }
448
- )
449
- )
487
+ );
488
+ })
450
489
  );
451
- function Ee(e) {
452
- const { controllerState: t } = e.state;
453
- return {
454
- isVirtual: e.description.isVirtual,
455
- motionGroupId: e.motionGroupId,
456
- operationMode: t.operation_mode,
457
- safetyState: t.safety_state
458
- };
459
- }
460
490
  export {
461
- ue as S,
462
- fe as m,
463
- Ee as r
491
+ Te as S,
492
+ ve as m
464
493
  };