@wandelbots/wandelbots-js-react-components 2.31.0 → 2.32.0-pr.feature-robot-precondition-list.372.297bf4f
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.
- package/dist/components/ProgramStateIndicator.d.ts +26 -0
- package/dist/components/ProgramStateIndicator.d.ts.map +1 -0
- package/dist/components/RobotListItem.d.ts +34 -0
- package/dist/components/RobotListItem.d.ts.map +1 -0
- package/dist/components/RobotSetupReadinessIndicator.d.ts +31 -0
- package/dist/components/RobotSetupReadinessIndicator.d.ts.map +1 -0
- package/dist/components/RobotSetupReadinessIndicator.test.d.ts +2 -0
- package/dist/components/RobotSetupReadinessIndicator.test.d.ts.map +1 -0
- package/dist/index.cjs +49 -49
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +5577 -5267
- package/dist/index.js.map +1 -1
- package/package.json +5 -5
- package/src/components/ProgramStateIndicator.tsx +148 -0
- package/src/components/RobotListItem.tsx +152 -0
- package/src/components/RobotSetupReadinessIndicator.test.tsx +60 -0
- package/src/components/RobotSetupReadinessIndicator.tsx +122 -0
- package/src/i18n/locales/de/translations.json +15 -1
- package/src/i18n/locales/en/translations.json +15 -1
- package/src/index.ts +3 -0
package/dist/index.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";var
|
|
1
|
+
"use strict";var Zf=Object.create;var Hs=Object.defineProperty;var eg=Object.getOwnPropertyDescriptor;var tg=Object.getOwnPropertyNames;var rg=Object.getPrototypeOf,ng=Object.prototype.hasOwnProperty;var ag=(e,t,r)=>t in e?Hs(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var og=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of tg(t))!ng.call(e,a)&&a!==r&&Hs(e,a,{get:()=>t[a],enumerable:!(n=eg(t,a))||n.enumerable});return e};var qs=(e,t,r)=>(r=e!=null?Zf(rg(e)):{},og(t||!e||!e.__esModule?Hs(r,"default",{value:e,enumerable:!0}):r,e));var En=(e,t,r)=>ag(e,typeof t!="symbol"?t+"":t,r);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const ee=require("react"),St=require("@react-three/drei"),Cc=require("@react-three/fiber"),vt=require("three"),sg=require("three-stdlib"),q=require("@mui/material"),Ee=require("mobx-react-lite"),_e=require("react-i18next"),ig=require("i18next"),lg=require("i18next-browser-languagedetector"),g=require("prop-types"),cg=require("@emotion/react"),ug=require("@emotion/styled"),Ne=require("mobx"),Sl=require("lodash-es"),br=require("@wandelbots/nova-js"),Vn=require("@mui/icons-material"),dg=require("react-error-boundary");function Ah(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const V=Ah(ee),ke=Ah(vt);function hg(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var La={exports:{}},In={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* react-jsx-runtime.production.js
|
|
4
4
|
*
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var
|
|
9
|
+
*/var Pc;function pg(){if(Pc)return In;Pc=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function r(n,a,o){var s=null;if(o!==void 0&&(s=""+o),a.key!==void 0&&(s=""+a.key),"key"in a){o={};for(var i in a)i!=="key"&&(o[i]=a[i])}else o=a;return a=o.ref,{$$typeof:e,type:n,key:s,ref:a!==void 0?a:null,props:o}}return In.Fragment=t,In.jsx=r,In.jsxs=r,In}var Mn={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,19 +14,19 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var
|
|
17
|
+
*/var Tc;function mg(){return Tc||(Tc=1,process.env.NODE_ENV!=="production"&&function(){function e(J){if(J==null)return null;if(typeof J=="function")return J.$$typeof===y?null:J.displayName||J.name||null;if(typeof J=="string")return J;switch(J){case m:return"Fragment";case x:return"Profiler";case b:return"StrictMode";case P:return"Suspense";case w:return"SuspenseList";case F:return"Activity"}if(typeof J=="object")switch(typeof J.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),J.$$typeof){case f:return"Portal";case O:return(J.displayName||"Context")+".Provider";case _:return(J._context.displayName||"Context")+".Consumer";case C:var X=J.render;return J=J.displayName,J||(J=X.displayName||X.name||"",J=J!==""?"ForwardRef("+J+")":"ForwardRef"),J;case R:return X=J.displayName||null,X!==null?X:e(J.type)||"Memo";case I:X=J._payload,J=J._init;try{return e(J(X))}catch{}}return null}function t(J){return""+J}function r(J){try{t(J);var X=!1}catch{X=!0}if(X){X=console;var he=X.error,Pe=typeof Symbol=="function"&&Symbol.toStringTag&&J[Symbol.toStringTag]||J.constructor.name||"Object";return he.call(X,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",Pe),t(J)}}function n(J){if(J===m)return"<>";if(typeof J=="object"&&J!==null&&J.$$typeof===I)return"<...>";try{var X=e(J);return X?"<"+X+">":"<...>"}catch{return"<...>"}}function a(){var J=T.A;return J===null?null:J.getOwner()}function o(){return Error("react-stack-top-frame")}function s(J){if(z.call(J,"key")){var X=Object.getOwnPropertyDescriptor(J,"key").get;if(X&&X.isReactWarning)return!1}return J.key!==void 0}function i(J,X){function he(){te||(te=!0,console.error("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",X))}he.isReactWarning=!0,Object.defineProperty(J,"key",{get:he,configurable:!0})}function l(){var J=e(this.type);return Z[J]||(Z[J]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),J=this.props.ref,J!==void 0?J:null}function c(J,X,he,Pe,ze,xe,it,tt){return he=xe.ref,J={$$typeof:p,type:J,key:X,props:xe,_owner:ze},(he!==void 0?he:null)!==null?Object.defineProperty(J,"ref",{enumerable:!1,get:l}):Object.defineProperty(J,"ref",{enumerable:!1,value:null}),J._store={},Object.defineProperty(J._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(J,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(J,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:it}),Object.defineProperty(J,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:tt}),Object.freeze&&(Object.freeze(J.props),Object.freeze(J)),J}function u(J,X,he,Pe,ze,xe,it,tt){var ye=X.children;if(ye!==void 0)if(Pe)if(E(ye)){for(Pe=0;Pe<ye.length;Pe++)d(ye[Pe]);Object.freeze&&Object.freeze(ye)}else console.error("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else d(ye);if(z.call(X,"key")){ye=e(J);var Q=Object.keys(X).filter(function(ce){return ce!=="key"});Pe=0<Q.length?"{key: someKey, "+Q.join(": ..., ")+": ...}":"{key: someKey}",le[ye+Pe]||(Q=0<Q.length?"{"+Q.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
|
|
18
18
|
let props = %s;
|
|
19
19
|
<%s {...props} />
|
|
20
20
|
React keys must be passed directly to JSX without using spread:
|
|
21
21
|
let props = %s;
|
|
22
|
-
<%s key={someKey} {...props} />`,Pe,ye,Q,ye),le[ye+Pe]=!0)}if(ye=null,he!==void 0&&(r(he),ye=""+he),s(X)&&(r(X.key),ye=""+X.key),"key"in X){he={};for(var oe in X)oe!=="key"&&(he[oe]=X[oe])}else he=X;return ye&&i(he,typeof
|
|
22
|
+
<%s key={someKey} {...props} />`,Pe,ye,Q,ye),le[ye+Pe]=!0)}if(ye=null,he!==void 0&&(r(he),ye=""+he),s(X)&&(r(X.key),ye=""+X.key),"key"in X){he={};for(var oe in X)oe!=="key"&&(he[oe]=X[oe])}else he=X;return ye&&i(he,typeof J=="function"?J.displayName||J.name||"Unknown":J),c(J,ye,xe,ze,a(),he,it,tt)}function d(J){typeof J=="object"&&J!==null&&J.$$typeof===p&&J._store&&(J._store.validated=1)}var h=ee,p=Symbol.for("react.transitional.element"),f=Symbol.for("react.portal"),m=Symbol.for("react.fragment"),b=Symbol.for("react.strict_mode"),x=Symbol.for("react.profiler"),_=Symbol.for("react.consumer"),O=Symbol.for("react.context"),C=Symbol.for("react.forward_ref"),P=Symbol.for("react.suspense"),w=Symbol.for("react.suspense_list"),R=Symbol.for("react.memo"),I=Symbol.for("react.lazy"),F=Symbol.for("react.activity"),y=Symbol.for("react.client.reference"),T=h.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,z=Object.prototype.hasOwnProperty,E=Array.isArray,B=console.createTask?console.createTask:function(){return null};h={"react-stack-bottom-frame":function(J){return J()}};var te,Z={},ae=h["react-stack-bottom-frame"].bind(h,o)(),re=B(n(o)),le={};Mn.Fragment=m,Mn.jsx=function(J,X,he,Pe,ze){var xe=1e4>T.recentlyCreatedOwnerStacks++;return u(J,X,he,!1,Pe,ze,xe?Error("react-stack-top-frame"):ae,xe?B(n(J)):re)},Mn.jsxs=function(J,X,he,Pe,ze){var xe=1e4>T.recentlyCreatedOwnerStacks++;return u(J,X,he,!0,Pe,ze,xe?Error("react-stack-top-frame"):ae,xe?B(n(J)):re)}}()),Mn}var Rc;function fg(){return Rc||(Rc=1,process.env.NODE_ENV==="production"?La.exports=pg():La.exports=mg()),La.exports}var S=fg();function gg(){return S.jsx(St.Environment,{children:S.jsx(yg,{})})}function yg({positions:e=[2,0,2,0,2,0,2,0]}){return S.jsxs(S.Fragment,{children:[S.jsx(St.Lightformer,{intensity:5,"rotation-x":Math.PI/2,position:[0,5,-9],scale:[10,10,1]}),S.jsx("group",{rotation:[0,.5,0],children:S.jsx("group",{children:e.map((t,r)=>S.jsx(St.Lightformer,{form:"circle",intensity:5,rotation:[Math.PI/2,0,0],position:[t,4,r*4],scale:[3,1,1]},r))})}),S.jsx(St.Lightformer,{intensity:40,"rotation-y":Math.PI/2,position:[-5,1,-1],scale:[20,.1,1]}),S.jsx(St.Lightformer,{intensity:20,"rotation-y":-Math.PI,position:[-5,-2,-1],scale:[20,.1,1]}),S.jsx(St.Lightformer,{"rotation-y":Math.PI/2,position:[-5,-1,-1],scale:[20,.5,1],intensity:5}),S.jsx(St.Lightformer,{"rotation-y":-Math.PI/2,position:[10,1,0],scale:[20,1,1],intensity:10}),S.jsx(St.Lightformer,{form:"ring",color:"white",intensity:5,scale:10,position:[-15,4,-18],target:[0,0,0]})]})}function bg(e){if(e.length<3)return console.log("Not enough vertices to define a plane"),{isCoplanar:!1};const t=new ke.Vector3(e[0].x,e[0].y,e[0].z),r=new ke.Vector3(e[1].x,e[1].y,e[1].z),n=new ke.Vector3(e[2].x,e[2].y,e[2].z),a=new ke.Vector3().subVectors(r,t),o=new ke.Vector3().subVectors(n,t),s=new ke.Vector3().crossVectors(a,o).normalize();for(let i=3;i<e.length;i++){const l=new ke.Vector3(e[i].x,e[i].y,e[i].z),c=new ke.Vector3().subVectors(l,t),u=s.dot(c);if(Math.abs(u)>1e-6)return console.log("Vertices are not on the same plane"),{isCoplanar:!1}}return{isCoplanar:!0,normal:s}}function vg({safetyZones:e,...t}){return S.jsx("group",{...t,children:e.map((r,n)=>{let a=[];return r.geometry&&(r.geometry.compound?a=r.geometry.compound.child_geometries:r.geometry.convex_hull&&(a=[r.geometry])),a.map((o,s)=>{if(!o.convex_hull)return null;const i=o.convex_hull.vertices.map(u=>new ke.Vector3(u.x/1e3,u.y/1e3,u.z/1e3)),l=bg(i);if(l.isCoplanar&&l.normal){const d=new ke.Vector3().addVectors(i[0],l.normal.multiplyScalar(1e-4));i.push(d)}let c;try{c=new sg.ConvexGeometry(i)}catch(u){return console.log("Error creating ConvexGeometry:",u),null}return S.jsx("mesh",{geometry:c,children:S.jsx("meshStandardMaterial",{attach:"material",color:"#009f4d",opacity:.2,depthTest:!1,depthWrite:!1,transparent:!0,polygonOffset:!0,polygonOffsetFactor:-s},n)},`${n}-${s}`)})})})}function Sg({trajectory:e,...t}){var n;const r=((n=e.trajectory)==null?void 0:n.map(a=>a.tcp_pose?new ke.Vector3(a.tcp_pose.position.x/1e3,a.tcp_pose.position.z/1e3,-a.tcp_pose.position.y/1e3):null).filter(a=>a!==null))||[];return S.jsx("group",{...t,children:r.length>0&&S.jsx(St.Line,{points:r,lineWidth:3,polygonOffset:!0,polygonOffsetFactor:10,polygonOffsetUnits:10})})}function Y(){return Y=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Y.apply(null,arguments)}function or(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function xg(e,t,r=void 0){const n={};for(const a in e){const o=e[a];let s="",i=!0;for(let l=0;l<o.length;l+=1){const c=o[l];c&&(s+=(i===!0?"":" ")+t(c),i=!1,r&&r[c]&&(s+=" "+r[c]))}n[a]=s}return n}function _h(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var a=e.length;for(t=0;t<a;t++)e[t]&&(r=_h(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function It(){for(var e,t,r=0,n="",a=arguments.length;r<a;r++)(e=arguments[r])&&(t=_h(e))&&(n&&(n+=" "),n+=t);return n}function sr(e,...t){const r=new URL(`https://mui.com/production-error/?code=${e}`);return t.forEach(n=>r.searchParams.append("args[]",n)),`Minified MUI error #${e}; visit ${r} for the full message.`}const Eh="$$material";function Og(e){for(var t=0,r,n=0,a=e.length;a>=4;++n,a-=4)r=e.charCodeAt(n)&255|(e.charCodeAt(++n)&255)<<8|(e.charCodeAt(++n)&255)<<16|(e.charCodeAt(++n)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(a){case 3:t^=(e.charCodeAt(n+2)&255)<<16;case 2:t^=(e.charCodeAt(n+1)&255)<<8;case 1:t^=e.charCodeAt(n)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var wg={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function Cg(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var Pg=/[A-Z]|^ms/g,Tg=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Vh=function(t){return t.charCodeAt(1)===45},Ac=function(t){return t!=null&&typeof t!="boolean"},Js=Cg(function(e){return Vh(e)?e:e.replace(Pg,"-$&").toLowerCase()}),_c=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(Tg,function(n,a,o){return nr={name:a,styles:o,next:nr},a})}return wg[t]!==1&&!Vh(t)&&typeof r=="number"&&r!==0?r+"px":r};function wo(e,t,r){if(r==null)return"";var n=r;if(n.__emotion_styles!==void 0)return n;switch(typeof r){case"boolean":return"";case"object":{var a=r;if(a.anim===1)return nr={name:a.name,styles:a.styles,next:nr},a.name;var o=r;if(o.styles!==void 0){var s=o.next;if(s!==void 0)for(;s!==void 0;)nr={name:s.name,styles:s.styles,next:nr},s=s.next;var i=o.styles+";";return i}return Rg(e,t,r)}}var l=r;return l}function Rg(e,t,r){var n="";if(Array.isArray(r))for(var a=0;a<r.length;a++)n+=wo(e,t,r[a])+";";else for(var o in r){var s=r[o];if(typeof s!="object"){var i=s;Ac(i)&&(n+=Js(o)+":"+_c(o,i)+";")}else if(Array.isArray(s)&&typeof s[0]=="string"&&t==null)for(var l=0;l<s.length;l++)Ac(s[l])&&(n+=Js(o)+":"+_c(o,s[l])+";");else{var c=wo(e,t,s);switch(o){case"animation":case"animationName":{n+=Js(o)+":"+c+";";break}default:n+=o+"{"+c+"}"}}}return n}var Ec=/label:\s*([^\s;{]+)\s*(;|$)/g,nr;function Ag(e,t,r){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var n=!0,a="";nr=void 0;var o=e[0];if(o==null||o.raw===void 0)n=!1,a+=wo(r,t,o);else{var s=o;a+=s[0]}for(var i=1;i<e.length;i++)if(a+=wo(r,t,e[i]),n){var l=o;a+=l[i]}Ec.lastIndex=0;for(var c="",u;(u=Ec.exec(a))!==null;)c+="-"+u[1];var d=Og(a)+c;return{name:d,styles:a,next:nr}}/**
|
|
23
23
|
* @mui/styled-engine v7.1.1
|
|
24
24
|
*
|
|
25
25
|
* @license MIT
|
|
26
26
|
* This source code is licensed under the MIT license found in the
|
|
27
27
|
* LICENSE file in the root directory of this source tree.
|
|
28
|
-
*/function
|
|
29
|
-
`)):n.some(o=>o===void 0)&&console.error(`MUI: the styled(${a})(...args) API requires all its args to be defined.`),r(...n)}:r}function
|
|
28
|
+
*/function _g(e,t){const r=ug(e,t);return process.env.NODE_ENV!=="production"?(...n)=>{const a=typeof e=="string"?`"${e}"`:"component";return n.length===0?console.error([`MUI: Seems like you called \`styled(${a})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join(`
|
|
29
|
+
`)):n.some(o=>o===void 0)&&console.error(`MUI: the styled(${a})(...args) API requires all its args to be defined.`),r(...n)}:r}function Eg(e,t){Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))}const Vc=[];function Ic(e){return Vc[0]=e,Ag(Vc)}var Da={exports:{}},ve={};/**
|
|
30
30
|
* @license React
|
|
31
31
|
* react-is.production.js
|
|
32
32
|
*
|
|
@@ -34,7 +34,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
34
34
|
*
|
|
35
35
|
* This source code is licensed under the MIT license found in the
|
|
36
36
|
* LICENSE file in the root directory of this source tree.
|
|
37
|
-
*/var
|
|
37
|
+
*/var Mc;function Vg(){if(Mc)return ve;Mc=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),s=Symbol.for("react.context"),i=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),c=Symbol.for("react.suspense_list"),u=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),h=Symbol.for("react.view_transition"),p=Symbol.for("react.client.reference");function f(m){if(typeof m=="object"&&m!==null){var b=m.$$typeof;switch(b){case e:switch(m=m.type,m){case r:case a:case n:case l:case c:case h:return m;default:switch(m=m&&m.$$typeof,m){case s:case i:case d:case u:return m;case o:return m;default:return b}}case t:return b}}}return ve.ContextConsumer=o,ve.ContextProvider=s,ve.Element=e,ve.ForwardRef=i,ve.Fragment=r,ve.Lazy=d,ve.Memo=u,ve.Portal=t,ve.Profiler=a,ve.StrictMode=n,ve.Suspense=l,ve.SuspenseList=c,ve.isContextConsumer=function(m){return f(m)===o},ve.isContextProvider=function(m){return f(m)===s},ve.isElement=function(m){return typeof m=="object"&&m!==null&&m.$$typeof===e},ve.isForwardRef=function(m){return f(m)===i},ve.isFragment=function(m){return f(m)===r},ve.isLazy=function(m){return f(m)===d},ve.isMemo=function(m){return f(m)===u},ve.isPortal=function(m){return f(m)===t},ve.isProfiler=function(m){return f(m)===a},ve.isStrictMode=function(m){return f(m)===n},ve.isSuspense=function(m){return f(m)===l},ve.isSuspenseList=function(m){return f(m)===c},ve.isValidElementType=function(m){return typeof m=="string"||typeof m=="function"||m===r||m===a||m===n||m===l||m===c||typeof m=="object"&&m!==null&&(m.$$typeof===d||m.$$typeof===u||m.$$typeof===s||m.$$typeof===o||m.$$typeof===i||m.$$typeof===p||m.getModuleId!==void 0)},ve.typeOf=f,ve}var Se={};/**
|
|
38
38
|
* @license React
|
|
39
39
|
* react-is.development.js
|
|
40
40
|
*
|
|
@@ -42,15 +42,15 @@ React keys must be passed directly to JSX without using spread:
|
|
|
42
42
|
*
|
|
43
43
|
* This source code is licensed under the MIT license found in the
|
|
44
44
|
* LICENSE file in the root directory of this source tree.
|
|
45
|
-
*/var
|
|
46
|
-
For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:
|
|
45
|
+
*/var $c;function Ig(){return $c||($c=1,process.env.NODE_ENV!=="production"&&function(){function e(m){if(typeof m=="object"&&m!==null){var b=m.$$typeof;switch(b){case t:switch(m=m.type,m){case n:case o:case a:case c:case u:case p:return m;default:switch(m=m&&m.$$typeof,m){case i:case l:case h:case d:return m;case s:return m;default:return b}}case r:return b}}}var t=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),a=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.consumer"),i=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),p=Symbol.for("react.view_transition"),f=Symbol.for("react.client.reference");Se.ContextConsumer=s,Se.ContextProvider=i,Se.Element=t,Se.ForwardRef=l,Se.Fragment=n,Se.Lazy=h,Se.Memo=d,Se.Portal=r,Se.Profiler=o,Se.StrictMode=a,Se.Suspense=c,Se.SuspenseList=u,Se.isContextConsumer=function(m){return e(m)===s},Se.isContextProvider=function(m){return e(m)===i},Se.isElement=function(m){return typeof m=="object"&&m!==null&&m.$$typeof===t},Se.isForwardRef=function(m){return e(m)===l},Se.isFragment=function(m){return e(m)===n},Se.isLazy=function(m){return e(m)===h},Se.isMemo=function(m){return e(m)===d},Se.isPortal=function(m){return e(m)===r},Se.isProfiler=function(m){return e(m)===o},Se.isStrictMode=function(m){return e(m)===a},Se.isSuspense=function(m){return e(m)===c},Se.isSuspenseList=function(m){return e(m)===u},Se.isValidElementType=function(m){return typeof m=="string"||typeof m=="function"||m===n||m===o||m===a||m===c||m===u||typeof m=="object"&&m!==null&&(m.$$typeof===h||m.$$typeof===d||m.$$typeof===i||m.$$typeof===s||m.$$typeof===l||m.$$typeof===f||m.getModuleId!==void 0)},Se.typeOf=e}()),Se}var jc;function Mg(){return jc||(jc=1,process.env.NODE_ENV==="production"?Da.exports=Vg():Da.exports=Ig()),Da.exports}var Co=Mg();function Et(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function Ih(e){if(V.isValidElement(e)||Co.isValidElementType(e)||!Et(e))return e;const t={};return Object.keys(e).forEach(r=>{t[r]=Ih(e[r])}),t}function et(e,t,r={clone:!0}){const n=r.clone?{...e}:e;return Et(e)&&Et(t)&&Object.keys(t).forEach(a=>{V.isValidElement(t[a])||Co.isValidElementType(t[a])?n[a]=t[a]:Et(t[a])&&Object.prototype.hasOwnProperty.call(e,a)&&Et(e[a])?n[a]=et(e[a],t[a],r):r.clone?n[a]=Et(t[a])?Ih(t[a]):t[a]:n[a]=t[a]}),n}const $g=e=>{const t=Object.keys(e).map(r=>({key:r,val:e[r]}))||[];return t.sort((r,n)=>r.val-n.val),t.reduce((r,n)=>({...r,[n.key]:n.val}),{})};function jg(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:r="px",step:n=5,...a}=e,o=$g(t),s=Object.keys(o);function i(h){return`@media (min-width:${typeof t[h]=="number"?t[h]:h}${r})`}function l(h){return`@media (max-width:${(typeof t[h]=="number"?t[h]:h)-n/100}${r})`}function c(h,p){const f=s.indexOf(p);return`@media (min-width:${typeof t[h]=="number"?t[h]:h}${r}) and (max-width:${(f!==-1&&typeof t[s[f]]=="number"?t[s[f]]:p)-n/100}${r})`}function u(h){return s.indexOf(h)+1<s.length?c(h,s[s.indexOf(h)+1]):i(h)}function d(h){const p=s.indexOf(h);return p===0?i(s[1]):p===s.length-1?l(s[p]):c(h,s[s.indexOf(h)+1]).replace("@media","@media not all and")}return{keys:s,values:o,up:i,down:l,between:c,only:u,not:d,unit:r,...a}}function kg(e,t){if(!e.containerQueries)return t;const r=Object.keys(t).filter(n=>n.startsWith("@container")).sort((n,a)=>{var s,i;const o=/min-width:\s*([0-9.]+)/;return+(((s=n.match(o))==null?void 0:s[1])||0)-+(((i=a.match(o))==null?void 0:i[1])||0)});return r.length?r.reduce((n,a)=>{const o=t[a];return delete n[a],n[a]=o,n},{...t}):t}function Ug(e,t){return t==="@"||t.startsWith("@")&&(e.some(r=>t.startsWith(`@${r}`))||!!t.match(/^@\d/))}function Lg(e,t){const r=t.match(/^@([^/]+)?\/?(.+)?$/);if(!r){if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The provided shorthand ${`(${t})`} is invalid. The format should be \`@<breakpoint | number>\` or \`@<breakpoint | number>/<container>\`.
|
|
46
|
+
For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:sr(18,`(${t})`));return null}const[,n,a]=r,o=Number.isNaN(+n)?n||0:+n;return e.containerQueries(a).up(o)}function Dg(e){const t=(o,s)=>o.replace("@media",s?`@container ${s}`:"@container");function r(o,s){o.up=(...i)=>t(e.breakpoints.up(...i),s),o.down=(...i)=>t(e.breakpoints.down(...i),s),o.between=(...i)=>t(e.breakpoints.between(...i),s),o.only=(...i)=>t(e.breakpoints.only(...i),s),o.not=(...i)=>{const l=t(e.breakpoints.not(...i),s);return l.includes("not all and")?l.replace("not all and ","").replace("min-width:","width<").replace("max-width:","width>").replace("and","or"):l}}const n={},a=o=>(r(n,o),n);return r(a),{...e,containerQueries:a}}const Ng={borderRadius:4},cr=process.env.NODE_ENV!=="production"?g.oneOfType([g.number,g.string,g.object,g.array]):{};function Zn(e,t){return t?et(e,t,{clone:!1}):e}const Ko={xs:0,sm:600,md:900,lg:1200,xl:1536},kc={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${Ko[e]}px)`},Bg={containerQueries:e=>({up:t=>{let r=typeof t=="number"?t:Ko[t]||t;return typeof r=="number"&&(r=`${r}px`),e?`@container ${e} (min-width:${r})`:`@container (min-width:${r})`}})};function wt(e,t,r){const n=e.theme||{};if(Array.isArray(t)){const o=n.breakpoints||kc;return t.reduce((s,i,l)=>(s[o.up(o.keys[l])]=r(t[l]),s),{})}if(typeof t=="object"){const o=n.breakpoints||kc;return Object.keys(t).reduce((s,i)=>{if(Ug(o.keys,i)){const l=Lg(n.containerQueries?n:Bg,i);l&&(s[l]=r(t[i],i))}else if(Object.keys(o.values||Ko).includes(i)){const l=o.up(i);s[l]=r(t[i],i)}else{const l=i;s[l]=t[l]}return s},{})}return r(t)}function Mh(e={}){var r;return((r=e.keys)==null?void 0:r.reduce((n,a)=>{const o=e.up(a);return n[o]={},n},{}))||{}}function $h(e,t){return e.reduce((r,n)=>{const a=r[n];return(!a||Object.keys(a).length===0)&&delete r[n],r},t)}function Fg(e,...t){const r=Mh(e),n=[r,...t].reduce((a,o)=>et(a,o),{});return $h(Object.keys(r),n)}function zg(e,t){if(typeof e!="object")return{};const r={},n=Object.keys(t);return Array.isArray(e)?n.forEach((a,o)=>{o<e.length&&(r[a]=!0)}):n.forEach(a=>{e[a]!=null&&(r[a]=!0)}),r}function Ws({values:e,breakpoints:t,base:r}){const n=r||zg(e,t),a=Object.keys(n);if(a.length===0)return e;let o;return a.reduce((s,i,l)=>(Array.isArray(e)?(s[i]=e[l]!=null?e[l]:e[o],o=l):typeof e=="object"?(s[i]=e[i]!=null?e[i]:e[o],o=i):s[i]=e,s),{})}function Ze(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":sr(7));return e.charAt(0).toUpperCase()+e.slice(1)}function Qo(e,t,r=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&r){const n=`vars.${t}`.split(".").reduce((a,o)=>a&&a[o]?a[o]:null,e);if(n!=null)return n}return t.split(".").reduce((n,a)=>n&&n[a]!=null?n[a]:null,e)}function Po(e,t,r,n=r){let a;return typeof e=="function"?a=e(r):Array.isArray(e)?a=e[r]||n:a=Qo(e,r)||n,t&&(a=t(a,n,e)),a}function Ue(e){const{prop:t,cssProperty:r=e.prop,themeKey:n,transform:a}=e,o=s=>{if(s[t]==null)return null;const i=s[t],l=s.theme,c=Qo(l,n)||{};return wt(s,i,d=>{let h=Po(c,a,d);return d===h&&typeof d=="string"&&(h=Po(c,a,`${t}${d==="default"?"":Ze(d)}`,d)),r===!1?h:{[r]:h}})};return o.propTypes=process.env.NODE_ENV!=="production"?{[t]:cr}:{},o.filterProps=[t],o}function Gg(e){const t={};return r=>(t[r]===void 0&&(t[r]=e(r)),t[r])}const Hg={m:"margin",p:"padding"},qg={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Uc={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},Jg=Gg(e=>{if(e.length>2)if(Uc[e])e=Uc[e];else return[e];const[t,r]=e.split(""),n=Hg[t],a=qg[r]||"";return Array.isArray(a)?a.map(o=>n+o):[n+a]}),Xo=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],Zo=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],Wg=[...Xo,...Zo];function va(e,t,r,n){const a=Qo(e,t,!0)??r;return typeof a=="number"||typeof a=="string"?o=>typeof o=="string"?o:(process.env.NODE_ENV!=="production"&&typeof o!="number"&&console.error(`MUI: Expected ${n} argument to be a number or a string, got ${o}.`),typeof a=="string"?a.startsWith("var(")&&o===0?0:a.startsWith("var(")&&o===1?a:`calc(${o} * ${a})`:a*o):Array.isArray(a)?o=>{if(typeof o=="string")return o;const s=Math.abs(o);process.env.NODE_ENV!=="production"&&(Number.isInteger(s)?s>a.length-1&&console.error([`MUI: The value provided (${s}) overflows.`,`The supported values are: ${JSON.stringify(a)}.`,`${s} > ${a.length-1}, you need to add the missing values.`].join(`
|
|
47
47
|
`)):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join(`
|
|
48
48
|
`)));const i=a[s];return o>=0?i:typeof i=="number"?-i:typeof i=="string"&&i.startsWith("var(")?`calc(-1 * ${i})`:`-${i}`}:typeof a=="function"?a:(process.env.NODE_ENV!=="production"&&console.error([`MUI: The \`theme.${t}\` value (${a}) is invalid.`,"It should be a number, an array or a function."].join(`
|
|
49
|
-
`)),()=>{})}function Zo(e){return va(e,"spacing",8,"spacing")}function xr(e,t){return typeof t=="string"||t==null?t:e(t)}function Jg(e,t){return r=>e.reduce((n,a)=>(n[a]=xr(t,r),n),{})}function Wg(e,t,r,n){if(!t.includes(r))return null;const a=Hg(r),o=Jg(a,n),s=e[r];return wt(e,s,o)}function $h(e,t){const r=Zo(e.theme);return Object.keys(e).map(n=>Wg(e,t,n,r)).reduce(Zn,{})}function Me(e){return $h(e,Qo)}Me.propTypes=process.env.NODE_ENV!=="production"?Qo.reduce((e,t)=>(e[t]=lr,e),{}):{};Me.filterProps=Qo;function $e(e){return $h(e,Xo)}$e.propTypes=process.env.NODE_ENV!=="production"?Xo.reduce((e,t)=>(e[t]=lr,e),{}):{};$e.filterProps=Xo;process.env.NODE_ENV!=="production"&&qg.reduce((e,t)=>(e[t]=lr,e),{});function jh(e=8,t=Zo({spacing:e})){if(e.mui)return e;const r=(...n)=>(process.env.NODE_ENV!=="production"&&(n.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${n.length}`)),(n.length===0?[1]:n).map(o=>{const s=t(o);return typeof s=="number"?`${s}px`:s}).join(" "));return r.mui=!0,r}function es(...e){const t=e.reduce((n,a)=>(a.filterProps.forEach(o=>{n[o]=a}),n),{}),r=n=>Object.keys(n).reduce((a,o)=>t[o]?Zn(a,t[o](n)):a,{});return r.propTypes=process.env.NODE_ENV!=="production"?e.reduce((n,a)=>Object.assign(n,a.propTypes),{}):{},r.filterProps=e.reduce((n,a)=>n.concat(a.filterProps),[]),r}function pt(e){return typeof e!="number"?e:`${e}px solid`}function yt(e,t){return Ue({prop:e,themeKey:"borders",transform:t})}const Yg=yt("border",pt),Kg=yt("borderTop",pt),Qg=yt("borderRight",pt),Xg=yt("borderBottom",pt),Zg=yt("borderLeft",pt),ey=yt("borderColor"),ty=yt("borderTopColor"),ry=yt("borderRightColor"),ny=yt("borderBottomColor"),ay=yt("borderLeftColor"),oy=yt("outline",pt),sy=yt("outlineColor"),ts=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=va(e.theme,"shape.borderRadius",4,"borderRadius"),r=n=>({borderRadius:xr(t,n)});return wt(e,e.borderRadius,r)}return null};ts.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:lr}:{};ts.filterProps=["borderRadius"];es(Yg,Kg,Qg,Xg,Zg,ey,ty,ry,ny,ay,ts,oy,sy);const rs=e=>{if(e.gap!==void 0&&e.gap!==null){const t=va(e.theme,"spacing",8,"gap"),r=n=>({gap:xr(t,n)});return wt(e,e.gap,r)}return null};rs.propTypes=process.env.NODE_ENV!=="production"?{gap:lr}:{};rs.filterProps=["gap"];const ns=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=va(e.theme,"spacing",8,"columnGap"),r=n=>({columnGap:xr(t,n)});return wt(e,e.columnGap,r)}return null};ns.propTypes=process.env.NODE_ENV!=="production"?{columnGap:lr}:{};ns.filterProps=["columnGap"];const as=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=va(e.theme,"spacing",8,"rowGap"),r=n=>({rowGap:xr(t,n)});return wt(e,e.rowGap,r)}return null};as.propTypes=process.env.NODE_ENV!=="production"?{rowGap:lr}:{};as.filterProps=["rowGap"];const iy=Ue({prop:"gridColumn"}),ly=Ue({prop:"gridRow"}),cy=Ue({prop:"gridAutoFlow"}),uy=Ue({prop:"gridAutoColumns"}),dy=Ue({prop:"gridAutoRows"}),hy=Ue({prop:"gridTemplateColumns"}),py=Ue({prop:"gridTemplateRows"}),my=Ue({prop:"gridTemplateAreas"}),fy=Ue({prop:"gridArea"});es(rs,ns,as,iy,ly,cy,uy,dy,hy,py,my,fy);function nn(e,t){return t==="grey"?t:e}const gy=Ue({prop:"color",themeKey:"palette",transform:nn}),yy=Ue({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:nn}),by=Ue({prop:"backgroundColor",themeKey:"palette",transform:nn});es(gy,yy,by);function ct(e){return e<=1&&e!==0?`${e*100}%`:e}const vy=Ue({prop:"width",transform:ct}),xl=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=r=>{var a,o,s,i,l;const n=((s=(o=(a=e.theme)==null?void 0:a.breakpoints)==null?void 0:o.values)==null?void 0:s[r])||Yo[r];return n?((l=(i=e.theme)==null?void 0:i.breakpoints)==null?void 0:l.unit)!=="px"?{maxWidth:`${n}${e.theme.breakpoints.unit}`}:{maxWidth:n}:{maxWidth:ct(r)}};return wt(e,e.maxWidth,t)}return null};xl.filterProps=["maxWidth"];const Sy=Ue({prop:"minWidth",transform:ct}),xy=Ue({prop:"height",transform:ct}),Oy=Ue({prop:"maxHeight",transform:ct}),wy=Ue({prop:"minHeight",transform:ct});Ue({prop:"size",cssProperty:"width",transform:ct});Ue({prop:"size",cssProperty:"height",transform:ct});const Cy=Ue({prop:"boxSizing"});es(vy,xl,Sy,xy,Oy,wy,Cy);const Sa={border:{themeKey:"borders",transform:pt},borderTop:{themeKey:"borders",transform:pt},borderRight:{themeKey:"borders",transform:pt},borderBottom:{themeKey:"borders",transform:pt},borderLeft:{themeKey:"borders",transform:pt},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:pt},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:ts},color:{themeKey:"palette",transform:nn},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:nn},backgroundColor:{themeKey:"palette",transform:nn},p:{style:$e},pt:{style:$e},pr:{style:$e},pb:{style:$e},pl:{style:$e},px:{style:$e},py:{style:$e},padding:{style:$e},paddingTop:{style:$e},paddingRight:{style:$e},paddingBottom:{style:$e},paddingLeft:{style:$e},paddingX:{style:$e},paddingY:{style:$e},paddingInline:{style:$e},paddingInlineStart:{style:$e},paddingInlineEnd:{style:$e},paddingBlock:{style:$e},paddingBlockStart:{style:$e},paddingBlockEnd:{style:$e},m:{style:Me},mt:{style:Me},mr:{style:Me},mb:{style:Me},ml:{style:Me},mx:{style:Me},my:{style:Me},margin:{style:Me},marginTop:{style:Me},marginRight:{style:Me},marginBottom:{style:Me},marginLeft:{style:Me},marginX:{style:Me},marginY:{style:Me},marginInline:{style:Me},marginInlineStart:{style:Me},marginInlineEnd:{style:Me},marginBlock:{style:Me},marginBlockStart:{style:Me},marginBlockEnd:{style:Me},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:rs},rowGap:{style:as},columnGap:{style:ns},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:ct},maxWidth:{style:xl},minWidth:{transform:ct},height:{transform:ct},maxHeight:{transform:ct},minHeight:{transform:ct},boxSizing:{},font:{themeKey:"font"},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};function Py(...e){const t=e.reduce((n,a)=>n.concat(Object.keys(a)),[]),r=new Set(t);return e.every(n=>r.size===Object.keys(n).length)}function Ty(e,t){return typeof e=="function"?e(t):e}function Ay(){function e(r,n,a,o){const s={[r]:n,theme:a},i=o[r];if(!i)return{[r]:n};const{cssProperty:l=r,themeKey:c,transform:u,style:d}=i;if(n==null)return null;if(c==="typography"&&n==="inherit")return{[r]:n};const h=Ko(a,c)||{};return d?d(s):wt(s,n,f=>{let m=Co(h,u,f);return f===m&&typeof f=="string"&&(m=Co(h,u,`${r}${f==="default"?"":Ze(f)}`,f)),l===!1?m:{[l]:m}})}function t(r){const{sx:n,theme:a={}}=r||{};if(!n)return null;const o=a.unstable_sxConfig??Sa;function s(i){let l=i;if(typeof i=="function")l=i(a);else if(typeof i!="object")return i;if(!l)return null;const c=Ih(a.breakpoints),u=Object.keys(c);let d=c;return Object.keys(l).forEach(h=>{const p=Ty(l[h],a);if(p!=null)if(typeof p=="object")if(o[h])d=Zn(d,e(h,p,a,o));else{const f=wt({theme:a},p,m=>({[h]:m}));Py(f,p)?d[h]=t({sx:p,theme:a}):d=Zn(d,f)}else d=Zn(d,e(h,p,a,o))}),$g(a,Mh(u,d))}return Array.isArray(n)?n.map(s):s(n)}return t}const cn=Ay();cn.filterProps=["sx"];function Ry(e,t){var n;const r=this;if(r.vars){if(!((n=r.colorSchemes)!=null&&n[e])||typeof r.getColorSchemeSelector!="function")return{};let a=r.getColorSchemeSelector(e);return a==="&"?t:((a.includes("data-")||a.includes("."))&&(a=`*:where(${a.replace(/\s*&$/,"")}) &`),{[a]:t})}return r.palette.mode===e?t:{}}function os(e={},...t){const{breakpoints:r={},palette:n={},spacing:a,shape:o={},...s}=e,i=Mg(r),l=jh(a);let c=et({breakpoints:i,direction:"ltr",components:{},palette:{mode:"light",...n},spacing:l,shape:{...Lg,...o}},s);return c=Ug(c),c.applyStyles=Ry,c=t.reduce((u,d)=>et(u,d),c),c.unstable_sxConfig={...Sa,...s==null?void 0:s.unstable_sxConfig},c.unstable_sx=function(d){return cn({sx:d,theme:this})},c}function Vy(e){return Object.keys(e).length===0}function _y(e=null){const t=B.useContext(ig.ThemeContext);return!t||Vy(t)?e:t}const Ey=os();function Iy(e=Ey){return _y(e)}const My=e=>{var n;const t={systemProps:{},otherProps:{}},r=((n=e==null?void 0:e.theme)==null?void 0:n.unstable_sxConfig)??Sa;return Object.keys(e).forEach(a=>{r[a]?t.systemProps[a]=e[a]:t.otherProps[a]=e[a]}),t};function $y(e){const{sx:t,...r}=e,{systemProps:n,otherProps:a}=My(r);let o;return Array.isArray(t)?o=[n,...t]:typeof t=="function"?o=(...s)=>{const i=t(...s);return Vt(i)?{...n,...i}:n}:o={...n,...t},{...a,sx:o}}const Uc=e=>e,jy=()=>{let e=Uc;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Uc}}},ky=jy(),Uy={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function xa(e,t,r="Mui"){const n=Uy[t];return n?`${r}-${n}`:`${ky.generate(e)}-${t}`}function kh(e,t,r="Mui"){const n={};return t.forEach(a=>{n[a]=xa(e,a,r)}),n}function Uh(e,t=""){return e.displayName||e.name||t}function Lc(e,t,r){const n=Uh(t);return e.displayName||(n!==""?`${r}(${n})`:r)}function Ly(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return Uh(e,"Component");if(typeof e=="object")switch(e.$$typeof){case wo.ForwardRef:return Lc(e,e.render,"ForwardRef");case wo.Memo:return Lc(e,e.type,"memo");default:return}}}function Lh(e){const{variants:t,...r}=e,n={variants:t,style:Ec(r),isProcessed:!0};return n.style===r||t&&t.forEach(a=>{typeof a.style!="function"&&(a.style=Ec(a.style))}),n}const Dy=os();function Ys(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}function By(e){return e?(t,r)=>r[e]:null}function Ny(e,t,r){e.theme=Gy(e.theme)?r:e.theme[t]||e.theme}function ho(e,t){const r=typeof t=="function"?t(e):t;if(Array.isArray(r))return r.flatMap(n=>ho(e,n));if(Array.isArray(r==null?void 0:r.variants)){let n;if(r.isProcessed)n=r.style;else{const{variants:a,...o}=r;n=o}return Dh(e,r.variants,[n])}return r!=null&&r.isProcessed?r.style:r}function Dh(e,t,r=[]){var a;let n;e:for(let o=0;o<t.length;o+=1){const s=t[o];if(typeof s.props=="function"){if(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),!s.props(n))continue}else for(const i in s.props)if(e[i]!==s.props[i]&&((a=e.ownerState)==null?void 0:a[i])!==s.props[i])continue e;typeof s.style=="function"?(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),r.push(s.style(n))):r.push(s.style)}return r}function Bh(e={}){const{themeId:t,defaultTheme:r=Dy,rootShouldForwardProp:n=Ys,slotShouldForwardProp:a=Ys}=e;function o(i){Ny(i,t,r)}return(i,l={})=>{Rg(i,P=>P.filter(w=>w!==cn));const{name:c,slot:u,skipVariantsResolver:d,skipSx:h,overridesResolver:p=By(Nh(u)),...f}=l,m=d!==void 0?d:u&&u!=="Root"&&u!=="root"||!1,b=h||!1;let x=Ys;u==="Root"||u==="root"?x=n:u?x=a:Hy(i)&&(x=void 0);const V=Ag(i,{shouldForwardProp:x,label:zy(c,u),...f}),O=P=>{if(P.__emotion_real===P)return P;if(typeof P=="function")return function(A){return ho(A,P)};if(Vt(P)){const w=Lh(P);return w.variants?function(E){return ho(E,w)}:w.style}return P},C=(...P)=>{const w=[],A=P.map(O),E=[];if(w.push(o),c&&p&&E.push(function(z){var Z,ae;const N=(ae=(Z=z.theme.components)==null?void 0:Z[c])==null?void 0:ae.styleOverrides;if(!N)return null;const te={};for(const re in N)te[re]=ho(z,N[re]);return p(z,te)}),c&&!m&&E.push(function(z){var te,Z;const _=z.theme,N=(Z=(te=_==null?void 0:_.components)==null?void 0:te[c])==null?void 0:Z.variants;return N?Dh(z,N):null}),b||E.push(cn),Array.isArray(A[0])){const T=A.shift(),z=new Array(w.length).fill(""),_=new Array(E.length).fill("");let N;N=[...z,...T,..._],N.raw=[...z,...T.raw,..._],w.unshift(N)}const F=[...w,...A,...E],y=V(...F);return i.muiName&&(y.muiName=i.muiName),process.env.NODE_ENV!=="production"&&(y.displayName=Fy(c,u,i)),y};return V.withConfig&&(C.withConfig=V.withConfig),C}}function Fy(e,t,r){return e?`${e}${Ze(t||"")}`:`Styled(${Ly(r)})`}function zy(e,t){let r;return process.env.NODE_ENV!=="production"&&e&&(r=`${e}-${Nh(t||"Root")}`),r}function Gy(e){for(const t in e)return!1;return!0}function Hy(e){return typeof e=="string"&&e.charCodeAt(0)>96}function Nh(e){return e&&e.charAt(0).toLowerCase()+e.slice(1)}const qy=Bh();function Po(e,t){const r={...t};for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)){const a=n;if(a==="components"||a==="slots")r[a]={...e[a],...r[a]};else if(a==="componentsProps"||a==="slotProps"){const o=e[a],s=t[a];if(!s)r[a]=o||{};else if(!o)r[a]=s;else{r[a]={...s};for(const i in o)if(Object.prototype.hasOwnProperty.call(o,i)){const l=i;r[a][l]=Po(o[l],s[l])}}}else r[a]===void 0&&(r[a]=e[a])}return r}function Jy(e){const{theme:t,name:r,props:n}=e;return!t||!t.components||!t.components[r]||!t.components[r].defaultProps?n:Po(t.components[r].defaultProps,n)}function Fh({props:e,name:t,defaultTheme:r,themeId:n}){let a=Iy(r);return n&&(a=a[n]||a),Jy({theme:a,name:t,props:e})}const zh=typeof window<"u"?B.useLayoutEffect:B.useEffect;function Zr(e,t=Number.MIN_SAFE_INTEGER,r=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,r))}function Ol(e,t=0,r=1){return process.env.NODE_ENV!=="production"&&(e<t||e>r)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${r}].`),Zr(e,t,r)}function Wy(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let r=e.match(t);return r&&r[0].length===1&&(r=r.map(n=>n+n)),process.env.NODE_ENV!=="production"&&e.length!==e.trim().length&&console.error(`MUI: The color: "${e}" is invalid. Make sure the color input doesn't contain leading/trailing space.`),r?`rgb${r.length===4?"a":""}(${r.map((n,a)=>a<3?parseInt(n,16):Math.round(parseInt(n,16)/255*1e3)/1e3).join(", ")})`:""}function sr(e){if(e.type)return e;if(e.charAt(0)==="#")return sr(Wy(e));const t=e.indexOf("("),r=e.substring(0,t);if(!["rgb","rgba","hsl","hsla","color"].includes(r))throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color.
|
|
50
|
-
The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:
|
|
51
|
-
The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:or(10,a))}else n=n.split(",");return n=n.map(o=>parseFloat(o)),{type:r,values:n,colorSpace:a}}const Yy=e=>{const t=sr(e);return t.values.slice(0,3).map((r,n)=>t.type.includes("hsl")&&n!==0?`${r}%`:r).join(" ")},Yn=(e,t)=>{try{return Yy(e)}catch{return t&&process.env.NODE_ENV!=="production"&&console.warn(t),e}};function ss(e){const{type:t,colorSpace:r}=e;let{values:n}=e;return t.includes("rgb")?n=n.map((a,o)=>o<3?parseInt(a,10):a):t.includes("hsl")&&(n[1]=`${n[1]}%`,n[2]=`${n[2]}%`),t.includes("color")?n=`${r} ${n.join(" ")}`:n=`${n.join(", ")}`,`${t}(${n})`}function Gh(e){e=sr(e);const{values:t}=e,r=t[0],n=t[1]/100,a=t[2]/100,o=n*Math.min(a,1-a),s=(c,u=(c+r/30)%12)=>a-o*Math.max(Math.min(u-3,9-u,1),-1);let i="rgb";const l=[Math.round(s(0)*255),Math.round(s(8)*255),Math.round(s(4)*255)];return e.type==="hsla"&&(i+="a",l.push(t[3])),ss({type:i,values:l})}function ki(e){e=sr(e);let t=e.type==="hsl"||e.type==="hsla"?sr(Gh(e)).values:e.values;return t=t.map(r=>(e.type!=="color"&&(r/=255),r<=.03928?r/12.92:((r+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Dc(e,t){const r=ki(e),n=ki(t);return(Math.max(r,n)+.05)/(Math.min(r,n)+.05)}function Ui(e,t){return e=sr(e),t=Ol(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,ss(e)}function Da(e,t,r){try{return Ui(e,t)}catch{return e}}function na(e,t){if(e=sr(e),t=Ol(t),e.type.includes("hsl"))e.values[2]*=1-t;else if(e.type.includes("rgb")||e.type.includes("color"))for(let r=0;r<3;r+=1)e.values[r]*=1-t;return ss(e)}function we(e,t,r){try{return na(e,t)}catch{return e}}function aa(e,t){if(e=sr(e),t=Ol(t),e.type.includes("hsl"))e.values[2]+=(100-e.values[2])*t;else if(e.type.includes("rgb"))for(let r=0;r<3;r+=1)e.values[r]+=(255-e.values[r])*t;else if(e.type.includes("color"))for(let r=0;r<3;r+=1)e.values[r]+=(1-e.values[r])*t;return ss(e)}function Ce(e,t,r){try{return aa(e,t)}catch{return e}}function Ky(e,t=.15){return ki(e)>.5?na(e,t):aa(e,t)}function Ba(e,t,r){try{return Ky(e,t)}catch{return e}}const Qy=B.createContext();process.env.NODE_ENV!=="production"&&(g.node,g.bool);const Xy=()=>B.useContext(Qy)??!1,Zy=B.createContext(void 0);process.env.NODE_ENV!=="production"&&(g.node,g.object);function e0(e){const{theme:t,name:r,props:n}=e;if(!t||!t.components||!t.components[r])return n;const a=t.components[r];return a.defaultProps?Po(a.defaultProps,n):!a.styleOverrides&&!a.variants?Po(a,n):n}function t0({props:e,name:t}){const r=B.useContext(Zy);return e0({props:e,name:t,theme:{components:r}})}const Bc={theme:void 0};function r0(e){let t,r;return function(a){let o=t;return(o===void 0||a.theme!==r)&&(Bc.theme=a.theme,o=Lh(e(Bc)),t=o,r=a.theme),o}}function n0(e=""){function t(...n){if(!n.length)return"";const a=n[0];return typeof a=="string"&&!a.match(/(#|\(|\)|(-?(\d*\.)?\d+)(px|em|%|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc))|^(-?(\d*\.)?\d+)$|(\d+ \d+ \d+)/)?`, var(--${e?`${e}-`:""}${a}${t(...n.slice(1))})`:`, ${a}`}return(n,...a)=>`var(--${e?`${e}-`:""}${n}${t(...a)})`}const Nc=(e,t,r,n=[])=>{let a=e;t.forEach((o,s)=>{s===t.length-1?Array.isArray(a)?a[Number(o)]=r:a&&typeof a=="object"&&(a[o]=r):a&&typeof a=="object"&&(a[o]||(a[o]=n.includes(o)?[]:{}),a=a[o])})},a0=(e,t,r)=>{function n(a,o=[],s=[]){Object.entries(a).forEach(([i,l])=>{(!r||r&&!r([...o,i]))&&l!=null&&(typeof l=="object"&&Object.keys(l).length>0?n(l,[...o,i],Array.isArray(l)?[...s,i]:s):t([...o,i],l,s))})}n(e)},o0=(e,t)=>typeof t=="number"?["lineHeight","fontWeight","opacity","zIndex"].some(n=>e.includes(n))||e[e.length-1].toLowerCase().includes("opacity")?t:`${t}px`:t;function Ks(e,t){const{prefix:r,shouldSkipGeneratingVar:n}=t||{},a={},o={},s={};return a0(e,(i,l,c)=>{if((typeof l=="string"||typeof l=="number")&&(!n||!n(i,l))){const u=`--${r?`${r}-`:""}${i.join("-")}`,d=o0(i,l);Object.assign(a,{[u]:d}),Nc(o,i,`var(${u})`,c),Nc(s,i,`var(${u}, ${d})`,c)}},i=>i[0]==="vars"),{css:a,vars:o,varsWithDefaults:s}}function s0(e,t={}){const{getSelector:r=b,disableCssColorScheme:n,colorSchemeSelector:a}=t,{colorSchemes:o={},components:s,defaultColorScheme:i="light",...l}=e,{vars:c,css:u,varsWithDefaults:d}=Ks(l,t);let h=d;const p={},{[i]:f,...m}=o;if(Object.entries(m||{}).forEach(([O,C])=>{const{vars:P,css:w,varsWithDefaults:A}=Ks(C,t);h=et(h,A),p[O]={css:w,vars:P}}),f){const{css:O,vars:C,varsWithDefaults:P}=Ks(f,t);h=et(h,P),p[i]={css:O,vars:C}}function b(O,C){var w,A;let P=a;if(a==="class"&&(P=".%s"),a==="data"&&(P="[data-%s]"),a!=null&&a.startsWith("data-")&&!a.includes("%s")&&(P=`[${a}="%s"]`),O){if(P==="media")return e.defaultColorScheme===O?":root":{[`@media (prefers-color-scheme: ${((A=(w=o[O])==null?void 0:w.palette)==null?void 0:A.mode)||O})`]:{":root":C}};if(P)return e.defaultColorScheme===O?`:root, ${P.replace("%s",String(O))}`:P.replace("%s",String(O))}return":root"}return{vars:h,generateThemeVars:()=>{let O={...c};return Object.entries(p).forEach(([,{vars:C}])=>{O=et(O,C)}),O},generateStyleSheets:()=>{var E,F;const O=[],C=e.defaultColorScheme||"light";function P(y,T){Object.keys(T).length&&O.push(typeof y=="string"?{[y]:{...T}}:y)}P(r(void 0,{...u}),u);const{[C]:w,...A}=p;if(w){const{css:y}=w,T=(F=(E=o[C])==null?void 0:E.palette)==null?void 0:F.mode,z=!n&&T?{colorScheme:T,...y}:{...y};P(r(C,{...z}),z)}return Object.entries(A).forEach(([y,{css:T}])=>{var N,te;const z=(te=(N=o[y])==null?void 0:N.palette)==null?void 0:te.mode,_=!n&&z?{colorScheme:z,...T}:{...T};P(r(y,{..._}),_)}),O}}}function i0(e){return function(r){return e==="media"?(process.env.NODE_ENV!=="production"&&r!=="light"&&r!=="dark"&&console.error(`MUI: @media (prefers-color-scheme) supports only 'light' or 'dark', but receive '${r}'.`),`@media (prefers-color-scheme: ${r})`):e?e.startsWith("data-")&&!e.includes("%s")?`[${e}="${r}"] &`:e==="class"?`.${r} &`:e==="data"?`[data-${r}] &`:`${e.replace("%s",r)} &`:"&"}}function wl(e,t,r=void 0){const n={};for(const a in e){const o=e[a];let s="",i=!0;for(let l=0;l<o.length;l+=1){const c=o[l];c&&(s+=(i===!0?"":" ")+t(c),i=!1,r&&r[c]&&(s+=" "+r[c]))}n[a]=s}return n}const l0=os(),c0=qy("div",{name:"MuiStack",slot:"Root"});function u0(e){return Fh({props:e,name:"MuiStack",defaultTheme:l0})}function d0(e,t){const r=B.Children.toArray(e).filter(Boolean);return r.reduce((n,a,o)=>(n.push(a),o<r.length-1&&n.push(B.cloneElement(t,{key:`separator-${o}`})),n),[])}const h0=e=>({row:"Left","row-reverse":"Right",column:"Top","column-reverse":"Bottom"})[e],p0=({ownerState:e,theme:t})=>{let r={display:"flex",flexDirection:"column",...wt({theme:t},Ws({values:e.direction,breakpoints:t.breakpoints.values}),n=>({flexDirection:n}))};if(e.spacing){const n=Zo(t),a=Object.keys(t.breakpoints.values).reduce((l,c)=>((typeof e.spacing=="object"&&e.spacing[c]!=null||typeof e.direction=="object"&&e.direction[c]!=null)&&(l[c]=!0),l),{}),o=Ws({values:e.direction,base:a}),s=Ws({values:e.spacing,base:a});typeof o=="object"&&Object.keys(o).forEach((l,c,u)=>{if(!o[l]){const h=c>0?o[u[c-1]]:"column";o[l]=h}}),r=et(r,wt({theme:t},s,(l,c)=>e.useFlexGap?{gap:xr(n,l)}:{"& > :not(style):not(style)":{margin:0},"& > :not(style) ~ :not(style)":{[`margin${h0(c?o[c]:e.direction)}`]:xr(n,l)}}))}return r=Bg(t.breakpoints,r),r};function m0(e={}){const{createStyledComponent:t=c0,useThemeProps:r=u0,componentName:n="MuiStack"}=e,a=()=>wl({root:["root"]},l=>xa(n,l),{}),o=t(p0),s=B.forwardRef(function(l,c){const u=r(l),d=$y(u),{component:h="div",direction:p="column",spacing:f=0,divider:m,children:b,className:x,useFlexGap:V=!1,...O}=d,C={direction:p,spacing:f,useFlexGap:V},P=a();return S.jsx(o,{as:h,ownerState:C,ref:c,className:Et(P.root,x),...O,children:m?d0(b,m):b})});return process.env.NODE_ENV!=="production"&&(s.propTypes={children:g.node,direction:g.oneOfType([g.oneOf(["column-reverse","column","row-reverse","row"]),g.arrayOf(g.oneOf(["column-reverse","column","row-reverse","row"])),g.object]),divider:g.node,spacing:g.oneOfType([g.arrayOf(g.oneOfType([g.number,g.string])),g.number,g.object,g.string]),sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object])}),s}const oa={black:"#000",white:"#fff"},f0={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},Lr={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},Dr={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},$n={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},Br={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},Nr={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},Fr={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"};function Hh(){return{text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:oa.white,default:oa.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}}}const g0=Hh();function qh(){return{text:{primary:oa.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:oa.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}}}const Fc=qh();function zc(e,t,r,n){const a=n.light||n,o=n.dark||n*1.5;e[t]||(e.hasOwnProperty(r)?e[t]=e[r]:t==="light"?e.light=aa(e.main,a):t==="dark"&&(e.dark=na(e.main,o)))}function y0(e="light"){return e==="dark"?{main:Br[200],light:Br[50],dark:Br[400]}:{main:Br[700],light:Br[400],dark:Br[800]}}function b0(e="light"){return e==="dark"?{main:Lr[200],light:Lr[50],dark:Lr[400]}:{main:Lr[500],light:Lr[300],dark:Lr[700]}}function v0(e="light"){return e==="dark"?{main:Dr[500],light:Dr[300],dark:Dr[700]}:{main:Dr[700],light:Dr[400],dark:Dr[800]}}function S0(e="light"){return e==="dark"?{main:Nr[400],light:Nr[300],dark:Nr[700]}:{main:Nr[700],light:Nr[500],dark:Nr[900]}}function x0(e="light"){return e==="dark"?{main:Fr[400],light:Fr[300],dark:Fr[700]}:{main:Fr[800],light:Fr[500],dark:Fr[900]}}function O0(e="light"){return e==="dark"?{main:$n[400],light:$n[300],dark:$n[700]}:{main:"#ed6c02",light:$n[500],dark:$n[900]}}function Cl(e){const{mode:t="light",contrastThreshold:r=3,tonalOffset:n=.2,...a}=e,o=e.primary||y0(t),s=e.secondary||b0(t),i=e.error||v0(t),l=e.info||S0(t),c=e.success||x0(t),u=e.warning||O0(t);function d(m){const b=Dc(m,Fc.text.primary)>=r?Fc.text.primary:g0.text.primary;if(process.env.NODE_ENV!=="production"){const x=Dc(m,b);x<3&&console.error([`MUI: The contrast ratio of ${x}:1 for ${b} on ${m}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(`
|
|
52
|
-
`))}return b}const h=({color:m,name:b,mainShade:x=500,lightShade:
|
|
53
|
-
The color object needs to have a \`main\` property or a \`${x}\` property.`:
|
|
49
|
+
`)),()=>{})}function es(e){return va(e,"spacing",8,"spacing")}function xr(e,t){return typeof t=="string"||t==null?t:e(t)}function Yg(e,t){return r=>e.reduce((n,a)=>(n[a]=xr(t,r),n),{})}function Kg(e,t,r,n){if(!t.includes(r))return null;const a=Jg(r),o=Yg(a,n),s=e[r];return wt(e,s,o)}function jh(e,t){const r=es(e.theme);return Object.keys(e).map(n=>Kg(e,t,n,r)).reduce(Zn,{})}function $e(e){return jh(e,Xo)}$e.propTypes=process.env.NODE_ENV!=="production"?Xo.reduce((e,t)=>(e[t]=cr,e),{}):{};$e.filterProps=Xo;function je(e){return jh(e,Zo)}je.propTypes=process.env.NODE_ENV!=="production"?Zo.reduce((e,t)=>(e[t]=cr,e),{}):{};je.filterProps=Zo;process.env.NODE_ENV!=="production"&&Wg.reduce((e,t)=>(e[t]=cr,e),{});function kh(e=8,t=es({spacing:e})){if(e.mui)return e;const r=(...n)=>(process.env.NODE_ENV!=="production"&&(n.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${n.length}`)),(n.length===0?[1]:n).map(o=>{const s=t(o);return typeof s=="number"?`${s}px`:s}).join(" "));return r.mui=!0,r}function ts(...e){const t=e.reduce((n,a)=>(a.filterProps.forEach(o=>{n[o]=a}),n),{}),r=n=>Object.keys(n).reduce((a,o)=>t[o]?Zn(a,t[o](n)):a,{});return r.propTypes=process.env.NODE_ENV!=="production"?e.reduce((n,a)=>Object.assign(n,a.propTypes),{}):{},r.filterProps=e.reduce((n,a)=>n.concat(a.filterProps),[]),r}function pt(e){return typeof e!="number"?e:`${e}px solid`}function yt(e,t){return Ue({prop:e,themeKey:"borders",transform:t})}const Qg=yt("border",pt),Xg=yt("borderTop",pt),Zg=yt("borderRight",pt),ey=yt("borderBottom",pt),ty=yt("borderLeft",pt),ry=yt("borderColor"),ny=yt("borderTopColor"),ay=yt("borderRightColor"),oy=yt("borderBottomColor"),sy=yt("borderLeftColor"),iy=yt("outline",pt),ly=yt("outlineColor"),rs=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=va(e.theme,"shape.borderRadius",4,"borderRadius"),r=n=>({borderRadius:xr(t,n)});return wt(e,e.borderRadius,r)}return null};rs.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:cr}:{};rs.filterProps=["borderRadius"];ts(Qg,Xg,Zg,ey,ty,ry,ny,ay,oy,sy,rs,iy,ly);const ns=e=>{if(e.gap!==void 0&&e.gap!==null){const t=va(e.theme,"spacing",8,"gap"),r=n=>({gap:xr(t,n)});return wt(e,e.gap,r)}return null};ns.propTypes=process.env.NODE_ENV!=="production"?{gap:cr}:{};ns.filterProps=["gap"];const as=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=va(e.theme,"spacing",8,"columnGap"),r=n=>({columnGap:xr(t,n)});return wt(e,e.columnGap,r)}return null};as.propTypes=process.env.NODE_ENV!=="production"?{columnGap:cr}:{};as.filterProps=["columnGap"];const os=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=va(e.theme,"spacing",8,"rowGap"),r=n=>({rowGap:xr(t,n)});return wt(e,e.rowGap,r)}return null};os.propTypes=process.env.NODE_ENV!=="production"?{rowGap:cr}:{};os.filterProps=["rowGap"];const cy=Ue({prop:"gridColumn"}),uy=Ue({prop:"gridRow"}),dy=Ue({prop:"gridAutoFlow"}),hy=Ue({prop:"gridAutoColumns"}),py=Ue({prop:"gridAutoRows"}),my=Ue({prop:"gridTemplateColumns"}),fy=Ue({prop:"gridTemplateRows"}),gy=Ue({prop:"gridTemplateAreas"}),yy=Ue({prop:"gridArea"});ts(ns,as,os,cy,uy,dy,hy,py,my,fy,gy,yy);function nn(e,t){return t==="grey"?t:e}const by=Ue({prop:"color",themeKey:"palette",transform:nn}),vy=Ue({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:nn}),Sy=Ue({prop:"backgroundColor",themeKey:"palette",transform:nn});ts(by,vy,Sy);function ct(e){return e<=1&&e!==0?`${e*100}%`:e}const xy=Ue({prop:"width",transform:ct}),xl=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=r=>{var a,o,s,i,l;const n=((s=(o=(a=e.theme)==null?void 0:a.breakpoints)==null?void 0:o.values)==null?void 0:s[r])||Ko[r];return n?((l=(i=e.theme)==null?void 0:i.breakpoints)==null?void 0:l.unit)!=="px"?{maxWidth:`${n}${e.theme.breakpoints.unit}`}:{maxWidth:n}:{maxWidth:ct(r)}};return wt(e,e.maxWidth,t)}return null};xl.filterProps=["maxWidth"];const Oy=Ue({prop:"minWidth",transform:ct}),wy=Ue({prop:"height",transform:ct}),Cy=Ue({prop:"maxHeight",transform:ct}),Py=Ue({prop:"minHeight",transform:ct});Ue({prop:"size",cssProperty:"width",transform:ct});Ue({prop:"size",cssProperty:"height",transform:ct});const Ty=Ue({prop:"boxSizing"});ts(xy,xl,Oy,wy,Cy,Py,Ty);const Sa={border:{themeKey:"borders",transform:pt},borderTop:{themeKey:"borders",transform:pt},borderRight:{themeKey:"borders",transform:pt},borderBottom:{themeKey:"borders",transform:pt},borderLeft:{themeKey:"borders",transform:pt},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:pt},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:rs},color:{themeKey:"palette",transform:nn},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:nn},backgroundColor:{themeKey:"palette",transform:nn},p:{style:je},pt:{style:je},pr:{style:je},pb:{style:je},pl:{style:je},px:{style:je},py:{style:je},padding:{style:je},paddingTop:{style:je},paddingRight:{style:je},paddingBottom:{style:je},paddingLeft:{style:je},paddingX:{style:je},paddingY:{style:je},paddingInline:{style:je},paddingInlineStart:{style:je},paddingInlineEnd:{style:je},paddingBlock:{style:je},paddingBlockStart:{style:je},paddingBlockEnd:{style:je},m:{style:$e},mt:{style:$e},mr:{style:$e},mb:{style:$e},ml:{style:$e},mx:{style:$e},my:{style:$e},margin:{style:$e},marginTop:{style:$e},marginRight:{style:$e},marginBottom:{style:$e},marginLeft:{style:$e},marginX:{style:$e},marginY:{style:$e},marginInline:{style:$e},marginInlineStart:{style:$e},marginInlineEnd:{style:$e},marginBlock:{style:$e},marginBlockStart:{style:$e},marginBlockEnd:{style:$e},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:ns},rowGap:{style:os},columnGap:{style:as},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:ct},maxWidth:{style:xl},minWidth:{transform:ct},height:{transform:ct},maxHeight:{transform:ct},minHeight:{transform:ct},boxSizing:{},font:{themeKey:"font"},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};function Ry(...e){const t=e.reduce((n,a)=>n.concat(Object.keys(a)),[]),r=new Set(t);return e.every(n=>r.size===Object.keys(n).length)}function Ay(e,t){return typeof e=="function"?e(t):e}function _y(){function e(r,n,a,o){const s={[r]:n,theme:a},i=o[r];if(!i)return{[r]:n};const{cssProperty:l=r,themeKey:c,transform:u,style:d}=i;if(n==null)return null;if(c==="typography"&&n==="inherit")return{[r]:n};const h=Qo(a,c)||{};return d?d(s):wt(s,n,f=>{let m=Po(h,u,f);return f===m&&typeof f=="string"&&(m=Po(h,u,`${r}${f==="default"?"":Ze(f)}`,f)),l===!1?m:{[l]:m}})}function t(r){const{sx:n,theme:a={}}=r||{};if(!n)return null;const o=a.unstable_sxConfig??Sa;function s(i){let l=i;if(typeof i=="function")l=i(a);else if(typeof i!="object")return i;if(!l)return null;const c=Mh(a.breakpoints),u=Object.keys(c);let d=c;return Object.keys(l).forEach(h=>{const p=Ay(l[h],a);if(p!=null)if(typeof p=="object")if(o[h])d=Zn(d,e(h,p,a,o));else{const f=wt({theme:a},p,m=>({[h]:m}));Ry(f,p)?d[h]=t({sx:p,theme:a}):d=Zn(d,f)}else d=Zn(d,e(h,p,a,o))}),kg(a,$h(u,d))}return Array.isArray(n)?n.map(s):s(n)}return t}const cn=_y();cn.filterProps=["sx"];function Ey(e,t){var n;const r=this;if(r.vars){if(!((n=r.colorSchemes)!=null&&n[e])||typeof r.getColorSchemeSelector!="function")return{};let a=r.getColorSchemeSelector(e);return a==="&"?t:((a.includes("data-")||a.includes("."))&&(a=`*:where(${a.replace(/\s*&$/,"")}) &`),{[a]:t})}return r.palette.mode===e?t:{}}function ss(e={},...t){const{breakpoints:r={},palette:n={},spacing:a,shape:o={},...s}=e,i=jg(r),l=kh(a);let c=et({breakpoints:i,direction:"ltr",components:{},palette:{mode:"light",...n},spacing:l,shape:{...Ng,...o}},s);return c=Dg(c),c.applyStyles=Ey,c=t.reduce((u,d)=>et(u,d),c),c.unstable_sxConfig={...Sa,...s==null?void 0:s.unstable_sxConfig},c.unstable_sx=function(d){return cn({sx:d,theme:this})},c}function Vy(e){return Object.keys(e).length===0}function Iy(e=null){const t=V.useContext(cg.ThemeContext);return!t||Vy(t)?e:t}const My=ss();function $y(e=My){return Iy(e)}const jy=e=>{var n;const t={systemProps:{},otherProps:{}},r=((n=e==null?void 0:e.theme)==null?void 0:n.unstable_sxConfig)??Sa;return Object.keys(e).forEach(a=>{r[a]?t.systemProps[a]=e[a]:t.otherProps[a]=e[a]}),t};function ky(e){const{sx:t,...r}=e,{systemProps:n,otherProps:a}=jy(r);let o;return Array.isArray(t)?o=[n,...t]:typeof t=="function"?o=(...s)=>{const i=t(...s);return Et(i)?{...n,...i}:n}:o={...n,...t},{...a,sx:o}}const Lc=e=>e,Uy=()=>{let e=Lc;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Lc}}},Ly=Uy(),Dy={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function xa(e,t,r="Mui"){const n=Dy[t];return n?`${r}-${n}`:`${Ly.generate(e)}-${t}`}function Uh(e,t,r="Mui"){const n={};return t.forEach(a=>{n[a]=xa(e,a,r)}),n}function Lh(e,t=""){return e.displayName||e.name||t}function Dc(e,t,r){const n=Lh(t);return e.displayName||(n!==""?`${r}(${n})`:r)}function Ny(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return Lh(e,"Component");if(typeof e=="object")switch(e.$$typeof){case Co.ForwardRef:return Dc(e,e.render,"ForwardRef");case Co.Memo:return Dc(e,e.type,"memo");default:return}}}function Dh(e){const{variants:t,...r}=e,n={variants:t,style:Ic(r),isProcessed:!0};return n.style===r||t&&t.forEach(a=>{typeof a.style!="function"&&(a.style=Ic(a.style))}),n}const By=ss();function Ys(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}function Fy(e){return e?(t,r)=>r[e]:null}function zy(e,t,r){e.theme=qy(e.theme)?r:e.theme[t]||e.theme}function po(e,t){const r=typeof t=="function"?t(e):t;if(Array.isArray(r))return r.flatMap(n=>po(e,n));if(Array.isArray(r==null?void 0:r.variants)){let n;if(r.isProcessed)n=r.style;else{const{variants:a,...o}=r;n=o}return Nh(e,r.variants,[n])}return r!=null&&r.isProcessed?r.style:r}function Nh(e,t,r=[]){var a;let n;e:for(let o=0;o<t.length;o+=1){const s=t[o];if(typeof s.props=="function"){if(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),!s.props(n))continue}else for(const i in s.props)if(e[i]!==s.props[i]&&((a=e.ownerState)==null?void 0:a[i])!==s.props[i])continue e;typeof s.style=="function"?(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),r.push(s.style(n))):r.push(s.style)}return r}function Bh(e={}){const{themeId:t,defaultTheme:r=By,rootShouldForwardProp:n=Ys,slotShouldForwardProp:a=Ys}=e;function o(i){zy(i,t,r)}return(i,l={})=>{Eg(i,P=>P.filter(w=>w!==cn));const{name:c,slot:u,skipVariantsResolver:d,skipSx:h,overridesResolver:p=Fy(Fh(u)),...f}=l,m=d!==void 0?d:u&&u!=="Root"&&u!=="root"||!1,b=h||!1;let x=Ys;u==="Root"||u==="root"?x=n:u?x=a:Jy(i)&&(x=void 0);const _=_g(i,{shouldForwardProp:x,label:Hy(c,u),...f}),O=P=>{if(P.__emotion_real===P)return P;if(typeof P=="function")return function(R){return po(R,P)};if(Et(P)){const w=Dh(P);return w.variants?function(I){return po(I,w)}:w.style}return P},C=(...P)=>{const w=[],R=P.map(O),I=[];if(w.push(o),c&&p&&I.push(function(z){var Z,ae;const B=(ae=(Z=z.theme.components)==null?void 0:Z[c])==null?void 0:ae.styleOverrides;if(!B)return null;const te={};for(const re in B)te[re]=po(z,B[re]);return p(z,te)}),c&&!m&&I.push(function(z){var te,Z;const E=z.theme,B=(Z=(te=E==null?void 0:E.components)==null?void 0:te[c])==null?void 0:Z.variants;return B?Nh(z,B):null}),b||I.push(cn),Array.isArray(R[0])){const T=R.shift(),z=new Array(w.length).fill(""),E=new Array(I.length).fill("");let B;B=[...z,...T,...E],B.raw=[...z,...T.raw,...E],w.unshift(B)}const F=[...w,...R,...I],y=_(...F);return i.muiName&&(y.muiName=i.muiName),process.env.NODE_ENV!=="production"&&(y.displayName=Gy(c,u,i)),y};return _.withConfig&&(C.withConfig=_.withConfig),C}}function Gy(e,t,r){return e?`${e}${Ze(t||"")}`:`Styled(${Ny(r)})`}function Hy(e,t){let r;return process.env.NODE_ENV!=="production"&&e&&(r=`${e}-${Fh(t||"Root")}`),r}function qy(e){for(const t in e)return!1;return!0}function Jy(e){return typeof e=="string"&&e.charCodeAt(0)>96}function Fh(e){return e&&e.charAt(0).toLowerCase()+e.slice(1)}const Wy=Bh();function To(e,t){const r={...t};for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)){const a=n;if(a==="components"||a==="slots")r[a]={...e[a],...r[a]};else if(a==="componentsProps"||a==="slotProps"){const o=e[a],s=t[a];if(!s)r[a]=o||{};else if(!o)r[a]=s;else{r[a]={...s};for(const i in o)if(Object.prototype.hasOwnProperty.call(o,i)){const l=i;r[a][l]=To(o[l],s[l])}}}else r[a]===void 0&&(r[a]=e[a])}return r}function Yy(e){const{theme:t,name:r,props:n}=e;return!t||!t.components||!t.components[r]||!t.components[r].defaultProps?n:To(t.components[r].defaultProps,n)}function zh({props:e,name:t,defaultTheme:r,themeId:n}){let a=$y(r);return n&&(a=a[n]||a),Yy({theme:a,name:t,props:e})}const Gh=typeof window<"u"?V.useLayoutEffect:V.useEffect;function Zr(e,t=Number.MIN_SAFE_INTEGER,r=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,r))}function Ol(e,t=0,r=1){return process.env.NODE_ENV!=="production"&&(e<t||e>r)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${r}].`),Zr(e,t,r)}function Ky(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let r=e.match(t);return r&&r[0].length===1&&(r=r.map(n=>n+n)),process.env.NODE_ENV!=="production"&&e.length!==e.trim().length&&console.error(`MUI: The color: "${e}" is invalid. Make sure the color input doesn't contain leading/trailing space.`),r?`rgb${r.length===4?"a":""}(${r.map((n,a)=>a<3?parseInt(n,16):Math.round(parseInt(n,16)/255*1e3)/1e3).join(", ")})`:""}function ir(e){if(e.type)return e;if(e.charAt(0)==="#")return ir(Ky(e));const t=e.indexOf("("),r=e.substring(0,t);if(!["rgb","rgba","hsl","hsla","color"].includes(r))throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${e}\` color.
|
|
50
|
+
The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:sr(9,e));let n=e.substring(t+1,e.length-1),a;if(r==="color"){if(n=n.split(" "),a=n.shift(),n.length===4&&n[3].charAt(0)==="/"&&(n[3]=n[3].slice(1)),!["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].includes(a))throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${a}\` color space.
|
|
51
|
+
The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:sr(10,a))}else n=n.split(",");return n=n.map(o=>parseFloat(o)),{type:r,values:n,colorSpace:a}}const Qy=e=>{const t=ir(e);return t.values.slice(0,3).map((r,n)=>t.type.includes("hsl")&&n!==0?`${r}%`:r).join(" ")},Yn=(e,t)=>{try{return Qy(e)}catch{return t&&process.env.NODE_ENV!=="production"&&console.warn(t),e}};function is(e){const{type:t,colorSpace:r}=e;let{values:n}=e;return t.includes("rgb")?n=n.map((a,o)=>o<3?parseInt(a,10):a):t.includes("hsl")&&(n[1]=`${n[1]}%`,n[2]=`${n[2]}%`),t.includes("color")?n=`${r} ${n.join(" ")}`:n=`${n.join(", ")}`,`${t}(${n})`}function Hh(e){e=ir(e);const{values:t}=e,r=t[0],n=t[1]/100,a=t[2]/100,o=n*Math.min(a,1-a),s=(c,u=(c+r/30)%12)=>a-o*Math.max(Math.min(u-3,9-u,1),-1);let i="rgb";const l=[Math.round(s(0)*255),Math.round(s(8)*255),Math.round(s(4)*255)];return e.type==="hsla"&&(i+="a",l.push(t[3])),is({type:i,values:l})}function ki(e){e=ir(e);let t=e.type==="hsl"||e.type==="hsla"?ir(Hh(e)).values:e.values;return t=t.map(r=>(e.type!=="color"&&(r/=255),r<=.03928?r/12.92:((r+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function Nc(e,t){const r=ki(e),n=ki(t);return(Math.max(r,n)+.05)/(Math.min(r,n)+.05)}function Ui(e,t){return e=ir(e),t=Ol(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,is(e)}function Na(e,t,r){try{return Ui(e,t)}catch{return e}}function na(e,t){if(e=ir(e),t=Ol(t),e.type.includes("hsl"))e.values[2]*=1-t;else if(e.type.includes("rgb")||e.type.includes("color"))for(let r=0;r<3;r+=1)e.values[r]*=1-t;return is(e)}function we(e,t,r){try{return na(e,t)}catch{return e}}function aa(e,t){if(e=ir(e),t=Ol(t),e.type.includes("hsl"))e.values[2]+=(100-e.values[2])*t;else if(e.type.includes("rgb"))for(let r=0;r<3;r+=1)e.values[r]+=(255-e.values[r])*t;else if(e.type.includes("color"))for(let r=0;r<3;r+=1)e.values[r]+=(1-e.values[r])*t;return is(e)}function Ce(e,t,r){try{return aa(e,t)}catch{return e}}function Xy(e,t=.15){return ki(e)>.5?na(e,t):aa(e,t)}function Ba(e,t,r){try{return Xy(e,t)}catch{return e}}const Zy=V.createContext();process.env.NODE_ENV!=="production"&&(g.node,g.bool);const e0=()=>V.useContext(Zy)??!1,t0=V.createContext(void 0);process.env.NODE_ENV!=="production"&&(g.node,g.object);function r0(e){const{theme:t,name:r,props:n}=e;if(!t||!t.components||!t.components[r])return n;const a=t.components[r];return a.defaultProps?To(a.defaultProps,n):!a.styleOverrides&&!a.variants?To(a,n):n}function n0({props:e,name:t}){const r=V.useContext(t0);return r0({props:e,name:t,theme:{components:r}})}const Bc={theme:void 0};function a0(e){let t,r;return function(a){let o=t;return(o===void 0||a.theme!==r)&&(Bc.theme=a.theme,o=Dh(e(Bc)),t=o,r=a.theme),o}}function o0(e=""){function t(...n){if(!n.length)return"";const a=n[0];return typeof a=="string"&&!a.match(/(#|\(|\)|(-?(\d*\.)?\d+)(px|em|%|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc))|^(-?(\d*\.)?\d+)$|(\d+ \d+ \d+)/)?`, var(--${e?`${e}-`:""}${a}${t(...n.slice(1))})`:`, ${a}`}return(n,...a)=>`var(--${e?`${e}-`:""}${n}${t(...a)})`}const Fc=(e,t,r,n=[])=>{let a=e;t.forEach((o,s)=>{s===t.length-1?Array.isArray(a)?a[Number(o)]=r:a&&typeof a=="object"&&(a[o]=r):a&&typeof a=="object"&&(a[o]||(a[o]=n.includes(o)?[]:{}),a=a[o])})},s0=(e,t,r)=>{function n(a,o=[],s=[]){Object.entries(a).forEach(([i,l])=>{(!r||r&&!r([...o,i]))&&l!=null&&(typeof l=="object"&&Object.keys(l).length>0?n(l,[...o,i],Array.isArray(l)?[...s,i]:s):t([...o,i],l,s))})}n(e)},i0=(e,t)=>typeof t=="number"?["lineHeight","fontWeight","opacity","zIndex"].some(n=>e.includes(n))||e[e.length-1].toLowerCase().includes("opacity")?t:`${t}px`:t;function Ks(e,t){const{prefix:r,shouldSkipGeneratingVar:n}=t||{},a={},o={},s={};return s0(e,(i,l,c)=>{if((typeof l=="string"||typeof l=="number")&&(!n||!n(i,l))){const u=`--${r?`${r}-`:""}${i.join("-")}`,d=i0(i,l);Object.assign(a,{[u]:d}),Fc(o,i,`var(${u})`,c),Fc(s,i,`var(${u}, ${d})`,c)}},i=>i[0]==="vars"),{css:a,vars:o,varsWithDefaults:s}}function l0(e,t={}){const{getSelector:r=b,disableCssColorScheme:n,colorSchemeSelector:a}=t,{colorSchemes:o={},components:s,defaultColorScheme:i="light",...l}=e,{vars:c,css:u,varsWithDefaults:d}=Ks(l,t);let h=d;const p={},{[i]:f,...m}=o;if(Object.entries(m||{}).forEach(([O,C])=>{const{vars:P,css:w,varsWithDefaults:R}=Ks(C,t);h=et(h,R),p[O]={css:w,vars:P}}),f){const{css:O,vars:C,varsWithDefaults:P}=Ks(f,t);h=et(h,P),p[i]={css:O,vars:C}}function b(O,C){var w,R;let P=a;if(a==="class"&&(P=".%s"),a==="data"&&(P="[data-%s]"),a!=null&&a.startsWith("data-")&&!a.includes("%s")&&(P=`[${a}="%s"]`),O){if(P==="media")return e.defaultColorScheme===O?":root":{[`@media (prefers-color-scheme: ${((R=(w=o[O])==null?void 0:w.palette)==null?void 0:R.mode)||O})`]:{":root":C}};if(P)return e.defaultColorScheme===O?`:root, ${P.replace("%s",String(O))}`:P.replace("%s",String(O))}return":root"}return{vars:h,generateThemeVars:()=>{let O={...c};return Object.entries(p).forEach(([,{vars:C}])=>{O=et(O,C)}),O},generateStyleSheets:()=>{var I,F;const O=[],C=e.defaultColorScheme||"light";function P(y,T){Object.keys(T).length&&O.push(typeof y=="string"?{[y]:{...T}}:y)}P(r(void 0,{...u}),u);const{[C]:w,...R}=p;if(w){const{css:y}=w,T=(F=(I=o[C])==null?void 0:I.palette)==null?void 0:F.mode,z=!n&&T?{colorScheme:T,...y}:{...y};P(r(C,{...z}),z)}return Object.entries(R).forEach(([y,{css:T}])=>{var B,te;const z=(te=(B=o[y])==null?void 0:B.palette)==null?void 0:te.mode,E=!n&&z?{colorScheme:z,...T}:{...T};P(r(y,{...E}),E)}),O}}}function c0(e){return function(r){return e==="media"?(process.env.NODE_ENV!=="production"&&r!=="light"&&r!=="dark"&&console.error(`MUI: @media (prefers-color-scheme) supports only 'light' or 'dark', but receive '${r}'.`),`@media (prefers-color-scheme: ${r})`):e?e.startsWith("data-")&&!e.includes("%s")?`[${e}="${r}"] &`:e==="class"?`.${r} &`:e==="data"?`[data-${r}] &`:`${e.replace("%s",r)} &`:"&"}}function wl(e,t,r=void 0){const n={};for(const a in e){const o=e[a];let s="",i=!0;for(let l=0;l<o.length;l+=1){const c=o[l];c&&(s+=(i===!0?"":" ")+t(c),i=!1,r&&r[c]&&(s+=" "+r[c]))}n[a]=s}return n}const u0=ss(),d0=Wy("div",{name:"MuiStack",slot:"Root"});function h0(e){return zh({props:e,name:"MuiStack",defaultTheme:u0})}function p0(e,t){const r=V.Children.toArray(e).filter(Boolean);return r.reduce((n,a,o)=>(n.push(a),o<r.length-1&&n.push(V.cloneElement(t,{key:`separator-${o}`})),n),[])}const m0=e=>({row:"Left","row-reverse":"Right",column:"Top","column-reverse":"Bottom"})[e],f0=({ownerState:e,theme:t})=>{let r={display:"flex",flexDirection:"column",...wt({theme:t},Ws({values:e.direction,breakpoints:t.breakpoints.values}),n=>({flexDirection:n}))};if(e.spacing){const n=es(t),a=Object.keys(t.breakpoints.values).reduce((l,c)=>((typeof e.spacing=="object"&&e.spacing[c]!=null||typeof e.direction=="object"&&e.direction[c]!=null)&&(l[c]=!0),l),{}),o=Ws({values:e.direction,base:a}),s=Ws({values:e.spacing,base:a});typeof o=="object"&&Object.keys(o).forEach((l,c,u)=>{if(!o[l]){const h=c>0?o[u[c-1]]:"column";o[l]=h}}),r=et(r,wt({theme:t},s,(l,c)=>e.useFlexGap?{gap:xr(n,l)}:{"& > :not(style):not(style)":{margin:0},"& > :not(style) ~ :not(style)":{[`margin${m0(c?o[c]:e.direction)}`]:xr(n,l)}}))}return r=Fg(t.breakpoints,r),r};function g0(e={}){const{createStyledComponent:t=d0,useThemeProps:r=h0,componentName:n="MuiStack"}=e,a=()=>wl({root:["root"]},l=>xa(n,l),{}),o=t(f0),s=V.forwardRef(function(l,c){const u=r(l),d=ky(u),{component:h="div",direction:p="column",spacing:f=0,divider:m,children:b,className:x,useFlexGap:_=!1,...O}=d,C={direction:p,spacing:f,useFlexGap:_},P=a();return S.jsx(o,{as:h,ownerState:C,ref:c,className:It(P.root,x),...O,children:m?p0(b,m):b})});return process.env.NODE_ENV!=="production"&&(s.propTypes={children:g.node,direction:g.oneOfType([g.oneOf(["column-reverse","column","row-reverse","row"]),g.arrayOf(g.oneOf(["column-reverse","column","row-reverse","row"])),g.object]),divider:g.node,spacing:g.oneOfType([g.arrayOf(g.oneOfType([g.number,g.string])),g.number,g.object,g.string]),sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object])}),s}const oa={black:"#000",white:"#fff"},y0={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},Lr={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},Dr={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},$n={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},Nr={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},Br={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},Fr={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"};function qh(){return{text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:oa.white,default:oa.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}}}const b0=qh();function Jh(){return{text:{primary:oa.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:oa.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}}}const zc=Jh();function Gc(e,t,r,n){const a=n.light||n,o=n.dark||n*1.5;e[t]||(e.hasOwnProperty(r)?e[t]=e[r]:t==="light"?e.light=aa(e.main,a):t==="dark"&&(e.dark=na(e.main,o)))}function v0(e="light"){return e==="dark"?{main:Nr[200],light:Nr[50],dark:Nr[400]}:{main:Nr[700],light:Nr[400],dark:Nr[800]}}function S0(e="light"){return e==="dark"?{main:Lr[200],light:Lr[50],dark:Lr[400]}:{main:Lr[500],light:Lr[300],dark:Lr[700]}}function x0(e="light"){return e==="dark"?{main:Dr[500],light:Dr[300],dark:Dr[700]}:{main:Dr[700],light:Dr[400],dark:Dr[800]}}function O0(e="light"){return e==="dark"?{main:Br[400],light:Br[300],dark:Br[700]}:{main:Br[700],light:Br[500],dark:Br[900]}}function w0(e="light"){return e==="dark"?{main:Fr[400],light:Fr[300],dark:Fr[700]}:{main:Fr[800],light:Fr[500],dark:Fr[900]}}function C0(e="light"){return e==="dark"?{main:$n[400],light:$n[300],dark:$n[700]}:{main:"#ed6c02",light:$n[500],dark:$n[900]}}function Cl(e){const{mode:t="light",contrastThreshold:r=3,tonalOffset:n=.2,...a}=e,o=e.primary||v0(t),s=e.secondary||S0(t),i=e.error||x0(t),l=e.info||O0(t),c=e.success||w0(t),u=e.warning||C0(t);function d(m){const b=Nc(m,zc.text.primary)>=r?zc.text.primary:b0.text.primary;if(process.env.NODE_ENV!=="production"){const x=Nc(m,b);x<3&&console.error([`MUI: The contrast ratio of ${x}:1 for ${b} on ${m}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(`
|
|
52
|
+
`))}return b}const h=({color:m,name:b,mainShade:x=500,lightShade:_=300,darkShade:O=700})=>{if(m={...m},!m.main&&m[x]&&(m.main=m[x]),!m.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${b?` (${b})`:""} provided to augmentColor(color) is invalid.
|
|
53
|
+
The color object needs to have a \`main\` property or a \`${x}\` property.`:sr(11,b?` (${b})`:"",x));if(typeof m.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${b?` (${b})`:""} provided to augmentColor(color) is invalid.
|
|
54
54
|
\`color.main\` should be a string, but \`${JSON.stringify(m.main)}\` was provided instead.
|
|
55
55
|
|
|
56
56
|
Did you intend to use one of the following approaches?
|
|
@@ -63,23 +63,23 @@ const theme1 = createTheme({ palette: {
|
|
|
63
63
|
|
|
64
64
|
const theme2 = createTheme({ palette: {
|
|
65
65
|
primary: { main: green[500] },
|
|
66
|
-
} });`:
|
|
67
|
-
`)),Object.keys(c).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(c).join(",")}].`)}return(Array.isArray(a)?a:[a]).map(u=>`${u} ${typeof s=="string"?s:
|
|
66
|
+
} });`:sr(12,b?` (${b})`:"",JSON.stringify(m.main)));return Gc(m,"light",_,n),Gc(m,"dark",O,n),m.contrastText||(m.contrastText=d(m.main)),m};let p;return t==="light"?p=qh():t==="dark"&&(p=Jh()),process.env.NODE_ENV!=="production"&&(p||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),et({common:{...oa},mode:t,primary:h({color:o,name:"primary"}),secondary:h({color:s,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:h({color:i,name:"error"}),warning:h({color:u,name:"warning"}),info:h({color:l,name:"info"}),success:h({color:c,name:"success"}),grey:y0,contrastThreshold:r,getContrastText:d,augmentColor:h,tonalOffset:n,...p},a)}function P0(e){const t={};return Object.entries(e).forEach(n=>{const[a,o]=n;typeof o=="object"&&(t[a]=`${o.fontStyle?`${o.fontStyle} `:""}${o.fontVariant?`${o.fontVariant} `:""}${o.fontWeight?`${o.fontWeight} `:""}${o.fontStretch?`${o.fontStretch} `:""}${o.fontSize||""}${o.lineHeight?`/${o.lineHeight} `:""}${o.fontFamily||""}`)}),t}function T0(e,t){return{toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}},...t}}function R0(e){return Math.round(e*1e5)/1e5}const Hc={textTransform:"uppercase"},qc='"Roboto", "Helvetica", "Arial", sans-serif';function A0(e,t){const{fontFamily:r=qc,fontSize:n=14,fontWeightLight:a=300,fontWeightRegular:o=400,fontWeightMedium:s=500,fontWeightBold:i=700,htmlFontSize:l=16,allVariants:c,pxToRem:u,...d}=typeof t=="function"?t(e):t;process.env.NODE_ENV!=="production"&&(typeof n!="number"&&console.error("MUI: `fontSize` is required to be a number."),typeof l!="number"&&console.error("MUI: `htmlFontSize` is required to be a number."));const h=n/14,p=u||(b=>`${b/l*h}rem`),f=(b,x,_,O,C)=>({fontFamily:r,fontWeight:b,fontSize:p(x),lineHeight:_,...r===qc?{letterSpacing:`${R0(O/x)}em`}:{},...C,...c}),m={h1:f(a,96,1.167,-1.5),h2:f(a,60,1.2,-.5),h3:f(o,48,1.167,0),h4:f(o,34,1.235,.25),h5:f(o,24,1.334,0),h6:f(s,20,1.6,.15),subtitle1:f(o,16,1.75,.15),subtitle2:f(s,14,1.57,.1),body1:f(o,16,1.5,.15),body2:f(o,14,1.43,.15),button:f(s,14,1.75,.4,Hc),caption:f(o,12,1.66,.4),overline:f(o,12,2.66,1,Hc),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return et({htmlFontSize:l,pxToRem:p,fontFamily:r,fontSize:n,fontWeightLight:a,fontWeightRegular:o,fontWeightMedium:s,fontWeightBold:i,...m},d,{clone:!1})}const _0=.2,E0=.14,V0=.12;function Ie(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${_0})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${E0})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${V0})`].join(",")}const I0=["none",Ie(0,2,1,-1,0,1,1,0,0,1,3,0),Ie(0,3,1,-2,0,2,2,0,0,1,5,0),Ie(0,3,3,-2,0,3,4,0,0,1,8,0),Ie(0,2,4,-1,0,4,5,0,0,1,10,0),Ie(0,3,5,-1,0,5,8,0,0,1,14,0),Ie(0,3,5,-1,0,6,10,0,0,1,18,0),Ie(0,4,5,-2,0,7,10,1,0,2,16,1),Ie(0,5,5,-3,0,8,10,1,0,3,14,2),Ie(0,5,6,-3,0,9,12,1,0,3,16,2),Ie(0,6,6,-3,0,10,14,1,0,4,18,3),Ie(0,6,7,-4,0,11,15,1,0,4,20,3),Ie(0,7,8,-4,0,12,17,2,0,5,22,4),Ie(0,7,8,-4,0,13,19,2,0,5,24,4),Ie(0,7,9,-4,0,14,21,2,0,5,26,4),Ie(0,8,9,-5,0,15,22,2,0,6,28,5),Ie(0,8,10,-5,0,16,24,2,0,6,30,5),Ie(0,8,11,-5,0,17,26,2,0,6,32,5),Ie(0,9,11,-5,0,18,28,2,0,7,34,6),Ie(0,9,12,-6,0,19,29,2,0,7,36,6),Ie(0,10,13,-6,0,20,31,3,0,8,38,7),Ie(0,10,13,-6,0,21,33,3,0,8,40,7),Ie(0,10,14,-6,0,22,35,3,0,8,42,7),Ie(0,11,14,-7,0,23,36,3,0,9,44,8),Ie(0,11,15,-7,0,24,38,3,0,9,46,8)],M0={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},$0={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Jc(e){return`${Math.round(e)}ms`}function j0(e){if(!e)return 0;const t=e/36;return Math.min(Math.round((4+15*t**.25+t/5)*10),3e3)}function k0(e){const t={...M0,...e.easing},r={...$0,...e.duration};return{getAutoHeightDuration:j0,create:(a=["all"],o={})=>{const{duration:s=r.standard,easing:i=t.easeInOut,delay:l=0,...c}=o;if(process.env.NODE_ENV!=="production"){const u=h=>typeof h=="string",d=h=>!Number.isNaN(parseFloat(h));!u(a)&&!Array.isArray(a)&&console.error('MUI: Argument "props" must be a string or Array.'),!d(s)&&!u(s)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${s}.`),u(i)||console.error('MUI: Argument "easing" must be a string.'),!d(l)&&!u(l)&&console.error('MUI: Argument "delay" must be a number or a string.'),typeof o!="object"&&console.error(["MUI: Secong argument of transition.create must be an object.","Arguments should be either `create('prop1', options)` or `create(['prop1', 'prop2'], options)`"].join(`
|
|
67
|
+
`)),Object.keys(c).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(c).join(",")}].`)}return(Array.isArray(a)?a:[a]).map(u=>`${u} ${typeof s=="string"?s:Jc(s)} ${i} ${typeof l=="string"?l:Jc(l)}`).join(",")},...e,easing:t,duration:r}}const U0={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500};function L0(e){return Et(e)||typeof e>"u"||typeof e=="string"||typeof e=="boolean"||typeof e=="number"||Array.isArray(e)}function Wh(e={}){const t={...e};function r(n){const a=Object.entries(n);for(let o=0;o<a.length;o++){const[s,i]=a[o];!L0(i)||s.startsWith("unstable_")?delete n[s]:Et(i)&&(n[s]={...i},r(n[s]))}}return r(t),`import { unstable_createBreakpoints as createBreakpoints, createTransitions } from '@mui/material/styles';
|
|
68
68
|
|
|
69
69
|
const theme = ${JSON.stringify(t,null,2)};
|
|
70
70
|
|
|
71
71
|
theme.breakpoints = createBreakpoints(theme.breakpoints || {});
|
|
72
72
|
theme.transitions = createTransitions(theme.transitions || {});
|
|
73
73
|
|
|
74
|
-
export default theme;`}function Li(e={},...t){const{breakpoints:r,mixins:n={},spacing:a,palette:o={},transitions:s={},typography:i={},shape:l,...c}=e;if(e.vars&&e.generateThemeVars===void 0)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name or follow the [docs](https://mui.com/material-ui/customization/css-theme-variables/usage/) to enable the feature.":
|
|
75
|
-
`))}m[x]={}}}};Object.keys(h.components).forEach(m=>{const b=h.components[m].styleOverrides;b&&m.startsWith("Mui")&&f(b,m)})}return h.unstable_sxConfig={...Sa,...c==null?void 0:c.unstable_sxConfig},h.unstable_sx=function(f){return cn({sx:f,theme:this})},h.toRuntimeSource=
|
|
76
|
-
To suppress this warning, you need to explicitly provide the \`palette.${t}Channel\` as a string (in rgb format, for example "12 12 12") or undefined if you want to remove the channel token.`))}function G0(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const Pt=e=>{try{return e()}catch{}},H0=(e="mui")=>n0(e);function Qs(e,t,r,n){if(!t)return;t=t===!0?{}:t;const a=n==="dark"?"dark":"light";if(!r){e[n]=D0({...t,palette:{mode:a,...t==null?void 0:t.palette}});return}const{palette:o,...s}=Li({...r,palette:{mode:a,...t==null?void 0:t.palette}});return e[n]={...t,palette:o,opacity:{...Wh(a),...t==null?void 0:t.opacity},overlays:(t==null?void 0:t.overlays)||Yh(a)},s}function q0(e={},...t){const{colorSchemes:r={light:!0},defaultColorScheme:n,disableCssColorScheme:a=!1,cssVarPrefix:o="mui",shouldSkipGeneratingVar:s=B0,colorSchemeSelector:i=r.light&&r.dark?"media":void 0,rootSelector:l=":root",...c}=e,u=Object.keys(r)[0],d=n||(r.light&&u!=="light"?"light":u),h=H0(o),{[d]:p,light:f,dark:m,...b}=r,x={...b};let V=p;if((d==="dark"&&!("dark"in r)||d==="light"&&!("light"in r))&&(V=!0),!V)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${d}\` option is either missing or invalid.`:or(21,d));const O=Qs(x,V,c,d);f&&!x.light&&Qs(x,f,void 0,"light"),m&&!x.dark&&Qs(x,m,void 0,"dark");let C={defaultColorScheme:d,...O,cssVarPrefix:o,colorSchemeSelector:i,rootSelector:l,getCssVar:h,colorSchemes:x,font:{...w0(O.typography),...O.font},spacing:G0(c.spacing)};Object.keys(C.colorSchemes).forEach(F=>{const y=C.colorSchemes[F].palette,T=z=>{const _=z.split("-"),N=_[1],te=_[2];return h(z,y[N][te])};if(y.mode==="light"&&(H(y.common,"background","#fff"),H(y.common,"onBackground","#000")),y.mode==="dark"&&(H(y.common,"background","#000"),H(y.common,"onBackground","#fff")),z0(y,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),y.mode==="light"){H(y.Alert,"errorColor",we(y.error.light,.6)),H(y.Alert,"infoColor",we(y.info.light,.6)),H(y.Alert,"successColor",we(y.success.light,.6)),H(y.Alert,"warningColor",we(y.warning.light,.6)),H(y.Alert,"errorFilledBg",T("palette-error-main")),H(y.Alert,"infoFilledBg",T("palette-info-main")),H(y.Alert,"successFilledBg",T("palette-success-main")),H(y.Alert,"warningFilledBg",T("palette-warning-main")),H(y.Alert,"errorFilledColor",Pt(()=>y.getContrastText(y.error.main))),H(y.Alert,"infoFilledColor",Pt(()=>y.getContrastText(y.info.main))),H(y.Alert,"successFilledColor",Pt(()=>y.getContrastText(y.success.main))),H(y.Alert,"warningFilledColor",Pt(()=>y.getContrastText(y.warning.main))),H(y.Alert,"errorStandardBg",Ce(y.error.light,.9)),H(y.Alert,"infoStandardBg",Ce(y.info.light,.9)),H(y.Alert,"successStandardBg",Ce(y.success.light,.9)),H(y.Alert,"warningStandardBg",Ce(y.warning.light,.9)),H(y.Alert,"errorIconColor",T("palette-error-main")),H(y.Alert,"infoIconColor",T("palette-info-main")),H(y.Alert,"successIconColor",T("palette-success-main")),H(y.Alert,"warningIconColor",T("palette-warning-main")),H(y.AppBar,"defaultBg",T("palette-grey-100")),H(y.Avatar,"defaultBg",T("palette-grey-400")),H(y.Button,"inheritContainedBg",T("palette-grey-300")),H(y.Button,"inheritContainedHoverBg",T("palette-grey-A100")),H(y.Chip,"defaultBorder",T("palette-grey-400")),H(y.Chip,"defaultAvatarColor",T("palette-grey-700")),H(y.Chip,"defaultIconColor",T("palette-grey-700")),H(y.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),H(y.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),H(y.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),H(y.LinearProgress,"primaryBg",Ce(y.primary.main,.62)),H(y.LinearProgress,"secondaryBg",Ce(y.secondary.main,.62)),H(y.LinearProgress,"errorBg",Ce(y.error.main,.62)),H(y.LinearProgress,"infoBg",Ce(y.info.main,.62)),H(y.LinearProgress,"successBg",Ce(y.success.main,.62)),H(y.LinearProgress,"warningBg",Ce(y.warning.main,.62)),H(y.Skeleton,"bg",`rgba(${T("palette-text-primaryChannel")} / 0.11)`),H(y.Slider,"primaryTrack",Ce(y.primary.main,.62)),H(y.Slider,"secondaryTrack",Ce(y.secondary.main,.62)),H(y.Slider,"errorTrack",Ce(y.error.main,.62)),H(y.Slider,"infoTrack",Ce(y.info.main,.62)),H(y.Slider,"successTrack",Ce(y.success.main,.62)),H(y.Slider,"warningTrack",Ce(y.warning.main,.62));const z=Ba(y.background.default,.8);H(y.SnackbarContent,"bg",z),H(y.SnackbarContent,"color",Pt(()=>y.getContrastText(z))),H(y.SpeedDialAction,"fabHoverBg",Ba(y.background.paper,.15)),H(y.StepConnector,"border",T("palette-grey-400")),H(y.StepContent,"border",T("palette-grey-400")),H(y.Switch,"defaultColor",T("palette-common-white")),H(y.Switch,"defaultDisabledColor",T("palette-grey-100")),H(y.Switch,"primaryDisabledColor",Ce(y.primary.main,.62)),H(y.Switch,"secondaryDisabledColor",Ce(y.secondary.main,.62)),H(y.Switch,"errorDisabledColor",Ce(y.error.main,.62)),H(y.Switch,"infoDisabledColor",Ce(y.info.main,.62)),H(y.Switch,"successDisabledColor",Ce(y.success.main,.62)),H(y.Switch,"warningDisabledColor",Ce(y.warning.main,.62)),H(y.TableCell,"border",Ce(Da(y.divider,1),.88)),H(y.Tooltip,"bg",Da(y.grey[700],.92))}if(y.mode==="dark"){H(y.Alert,"errorColor",Ce(y.error.light,.6)),H(y.Alert,"infoColor",Ce(y.info.light,.6)),H(y.Alert,"successColor",Ce(y.success.light,.6)),H(y.Alert,"warningColor",Ce(y.warning.light,.6)),H(y.Alert,"errorFilledBg",T("palette-error-dark")),H(y.Alert,"infoFilledBg",T("palette-info-dark")),H(y.Alert,"successFilledBg",T("palette-success-dark")),H(y.Alert,"warningFilledBg",T("palette-warning-dark")),H(y.Alert,"errorFilledColor",Pt(()=>y.getContrastText(y.error.dark))),H(y.Alert,"infoFilledColor",Pt(()=>y.getContrastText(y.info.dark))),H(y.Alert,"successFilledColor",Pt(()=>y.getContrastText(y.success.dark))),H(y.Alert,"warningFilledColor",Pt(()=>y.getContrastText(y.warning.dark))),H(y.Alert,"errorStandardBg",we(y.error.light,.9)),H(y.Alert,"infoStandardBg",we(y.info.light,.9)),H(y.Alert,"successStandardBg",we(y.success.light,.9)),H(y.Alert,"warningStandardBg",we(y.warning.light,.9)),H(y.Alert,"errorIconColor",T("palette-error-main")),H(y.Alert,"infoIconColor",T("palette-info-main")),H(y.Alert,"successIconColor",T("palette-success-main")),H(y.Alert,"warningIconColor",T("palette-warning-main")),H(y.AppBar,"defaultBg",T("palette-grey-900")),H(y.AppBar,"darkBg",T("palette-background-paper")),H(y.AppBar,"darkColor",T("palette-text-primary")),H(y.Avatar,"defaultBg",T("palette-grey-600")),H(y.Button,"inheritContainedBg",T("palette-grey-800")),H(y.Button,"inheritContainedHoverBg",T("palette-grey-700")),H(y.Chip,"defaultBorder",T("palette-grey-700")),H(y.Chip,"defaultAvatarColor",T("palette-grey-300")),H(y.Chip,"defaultIconColor",T("palette-grey-300")),H(y.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),H(y.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),H(y.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),H(y.LinearProgress,"primaryBg",we(y.primary.main,.5)),H(y.LinearProgress,"secondaryBg",we(y.secondary.main,.5)),H(y.LinearProgress,"errorBg",we(y.error.main,.5)),H(y.LinearProgress,"infoBg",we(y.info.main,.5)),H(y.LinearProgress,"successBg",we(y.success.main,.5)),H(y.LinearProgress,"warningBg",we(y.warning.main,.5)),H(y.Skeleton,"bg",`rgba(${T("palette-text-primaryChannel")} / 0.13)`),H(y.Slider,"primaryTrack",we(y.primary.main,.5)),H(y.Slider,"secondaryTrack",we(y.secondary.main,.5)),H(y.Slider,"errorTrack",we(y.error.main,.5)),H(y.Slider,"infoTrack",we(y.info.main,.5)),H(y.Slider,"successTrack",we(y.success.main,.5)),H(y.Slider,"warningTrack",we(y.warning.main,.5));const z=Ba(y.background.default,.98);H(y.SnackbarContent,"bg",z),H(y.SnackbarContent,"color",Pt(()=>y.getContrastText(z))),H(y.SpeedDialAction,"fabHoverBg",Ba(y.background.paper,.15)),H(y.StepConnector,"border",T("palette-grey-600")),H(y.StepContent,"border",T("palette-grey-600")),H(y.Switch,"defaultColor",T("palette-grey-300")),H(y.Switch,"defaultDisabledColor",T("palette-grey-600")),H(y.Switch,"primaryDisabledColor",we(y.primary.main,.55)),H(y.Switch,"secondaryDisabledColor",we(y.secondary.main,.55)),H(y.Switch,"errorDisabledColor",we(y.error.main,.55)),H(y.Switch,"infoDisabledColor",we(y.info.main,.55)),H(y.Switch,"successDisabledColor",we(y.success.main,.55)),H(y.Switch,"warningDisabledColor",we(y.warning.main,.55)),H(y.TableCell,"border",we(Da(y.divider,1),.68)),H(y.Tooltip,"bg",Da(y.grey[700],.92))}kt(y.background,"default"),kt(y.background,"paper"),kt(y.common,"background"),kt(y.common,"onBackground"),kt(y,"divider"),Object.keys(y).forEach(z=>{const _=y[z];z!=="tonalOffset"&&_&&typeof _=="object"&&(_.main&&H(y[z],"mainChannel",Yn(Kn(_.main))),_.light&&H(y[z],"lightChannel",Yn(Kn(_.light))),_.dark&&H(y[z],"darkChannel",Yn(Kn(_.dark))),_.contrastText&&H(y[z],"contrastTextChannel",Yn(Kn(_.contrastText))),z==="text"&&(kt(y[z],"primary"),kt(y[z],"secondary")),z==="action"&&(_.active&&kt(y[z],"active"),_.selected&&kt(y[z],"selected")))})}),C=t.reduce((F,y)=>et(F,y),C);const P={prefix:o,disableCssColorScheme:a,shouldSkipGeneratingVar:s,getSelector:F0(C)},{vars:w,generateThemeVars:A,generateStyleSheets:E}=s0(C,P);return C.vars=w,Object.entries(C.colorSchemes[C.defaultColorScheme]).forEach(([F,y])=>{C[F]=y}),C.generateThemeVars=A,C.generateStyleSheets=E,C.generateSpacing=function(){return jh(c.spacing,Zo(this))},C.getColorSchemeSelector=i0(i),C.spacing=C.generateSpacing(),C.shouldSkipGeneratingVar=s,C.unstable_sxConfig={...Sa,...c==null?void 0:c.unstable_sxConfig},C.unstable_sx=function(y){return cn({sx:y,theme:this})},C.toRuntimeSource=Jh,C}function Jc(e,t,r){e.colorSchemes&&r&&(e.colorSchemes[t]={...r!==!0&&r,palette:Cl({...r===!0?{}:r.palette,mode:t})})}function Kh(e={},...t){const{palette:r,cssVariables:n=!1,colorSchemes:a=r?void 0:{light:!0},defaultColorScheme:o=r==null?void 0:r.mode,...s}=e,i=o||"light",l=a==null?void 0:a[i],c={...a,...r?{[i]:{...typeof l!="boolean"&&l,palette:r}}:void 0};if(n===!1){if(!("colorSchemes"in e))return Li(e,...t);let u=r;"palette"in e||c[i]&&(c[i]!==!0?u=c[i].palette:i==="dark"&&(u={mode:"dark"}));const d=Li({...e,palette:u},...t);return d.defaultColorScheme=i,d.colorSchemes=c,d.palette.mode==="light"&&(d.colorSchemes.light={...c.light!==!0&&c.light,palette:d.palette},Jc(d,"dark",c.dark)),d.palette.mode==="dark"&&(d.colorSchemes.dark={...c.dark!==!0&&c.dark,palette:d.palette},Jc(d,"light",c.light)),d}return!r&&!("light"in c)&&i==="light"&&(c.light=!0),q0({...s,colorSchemes:c,defaultColorScheme:i,...typeof n!="boolean"&&n},...t)}const Qh=Kh();function J0({props:e,name:t}){return Fh({props:e,name:t,defaultTheme:Qh,themeId:Vh})}function Pl(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const W0=e=>Pl(e)&&e!=="classes",dt=Bh({themeId:Vh,defaultTheme:Qh,rootShouldForwardProp:W0});function Xh(...e){const t=B.useRef(void 0),r=B.useCallback(n=>{const a=e.map(o=>{if(o==null)return null;if(typeof o=="function"){const s=o,i=s(n);return typeof i=="function"?i:()=>{s(null)}}return o.current=n,()=>{o.current=null}});return()=>{a.forEach(o=>o==null?void 0:o())}},e);return B.useMemo(()=>e.every(n=>n==null)?null:n=>{t.current&&(t.current(),t.current=void 0),n!=null&&(t.current=r(n))},e)}let Wc=0;function Y0(e){const[t,r]=B.useState(e),n=t;return B.useEffect(()=>{t==null&&(Wc+=1,r(`mui-${Wc}`))},[t]),n}const K0={...B},Yc=K0.useId;function Q0(e){return Yc!==void 0?Yc():Y0(e)}class X0{constructor(t){this.value=void 0,this.listeners=void 0,this.subscribe=r=>(this.listeners.add(r),()=>{this.listeners.delete(r)}),this.getSnapshot=()=>this.value,this.update=r=>{const n=r(this.value);n!==this.value&&(this.value=n,this.listeners.forEach(a=>a(n)))},this.value=t,this.listeners=new Set}}const Nt=typeof window<"u"?B.useLayoutEffect:B.useEffect,is=({params:e,store:t})=>{B.useEffect(()=>{t.update(n=>Y({},n,{animation:Y({},n.animation,{skip:e.skipAnimation})}))},[t,e.skipAnimation]);const r=B.useCallback(()=>{let n=!1;return t.update(a=>Y({},a,{animation:Y({},a.animation,{skipAnimationRequests:a.animation.skipAnimationRequests+1})})),()=>{n||(n=!0,t.update(a=>Y({},a,{animation:Y({},a.animation,{skipAnimationRequests:a.animation.skipAnimationRequests-1})})))}},[t]);return Nt(()=>{if(typeof window>"u"||!(window!=null&&window.matchMedia))return;let a;const o=i=>{i.matches?a=r():a==null||a()},s=window.matchMedia("(prefers-reduced-motion)");return o(s),s.addEventListener("change",o),()=>{s.removeEventListener("change",o)}},[r,t]),{instance:{disableAnimation:r}}};is.params={skipAnimation:!0};is.getDefaultizedParams=({params:e})=>Y({},e,{skipAnimation:e.skipAnimation??!1});is.getInitialState=({skipAnimation:e})=>{const t=typeof window>"u"||!(window!=null&&window.matchMedia),r=process.env.NODE_ENV==="test"?t:!1;return{animation:{skip:e,skipAnimationRequests:r?1:0}}};var Z0=(e,t,r)=>{if(t.length===1&&t[0]===r){let n=!1;try{const a={};e(a)===a&&(n=!0)}catch{}if(n){let a;try{throw new Error}catch(o){({stack:a}=o)}console.warn(`The result function returned its own inputs without modification. e.g
|
|
74
|
+
export default theme;`}function Li(e={},...t){const{breakpoints:r,mixins:n={},spacing:a,palette:o={},transitions:s={},typography:i={},shape:l,...c}=e;if(e.vars&&e.generateThemeVars===void 0)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name or follow the [docs](https://mui.com/material-ui/customization/css-theme-variables/usage/) to enable the feature.":sr(20));const u=Cl(o),d=ss(e);let h=et(d,{mixins:T0(d.breakpoints,n),palette:u,shadows:I0.slice(),typography:A0(u,i),transitions:k0(s),zIndex:{...U0}});if(h=et(h,c),h=t.reduce((p,f)=>et(p,f),h),process.env.NODE_ENV!=="production"){const p=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],f=(m,b)=>{let x;for(x in m){const _=m[x];if(p.includes(x)&&Object.keys(_).length>0){if(process.env.NODE_ENV!=="production"){const O=xa("",x);console.error([`MUI: The \`${b}\` component increases the CSS specificity of the \`${x}\` internal state.`,"You can not override it like this: ",JSON.stringify(m,null,2),"",`Instead, you need to use the '&.${O}' syntax:`,JSON.stringify({root:{[`&.${O}`]:_}},null,2),"","https://mui.com/r/state-classes-guide"].join(`
|
|
75
|
+
`))}m[x]={}}}};Object.keys(h.components).forEach(m=>{const b=h.components[m].styleOverrides;b&&m.startsWith("Mui")&&f(b,m)})}return h.unstable_sxConfig={...Sa,...c==null?void 0:c.unstable_sxConfig},h.unstable_sx=function(f){return cn({sx:f,theme:this})},h.toRuntimeSource=Wh,h}function D0(e){let t;return e<1?t=5.11916*e**2:t=4.5*Math.log(e+1)+2,Math.round(t*10)/1e3}const N0=[...Array(25)].map((e,t)=>{if(t===0)return"none";const r=D0(t);return`linear-gradient(rgba(255 255 255 / ${r}), rgba(255 255 255 / ${r}))`});function Yh(e){return{inputPlaceholder:e==="dark"?.5:.42,inputUnderline:e==="dark"?.7:.42,switchTrackDisabled:e==="dark"?.2:.12,switchTrack:e==="dark"?.3:.38}}function Kh(e){return e==="dark"?N0:[]}function B0(e){const{palette:t={mode:"light"},opacity:r,overlays:n,...a}=e,o=Cl(t);return{palette:o,opacity:{...Yh(o.mode),...r},overlays:n||Kh(o.mode),...a}}function F0(e){var t;return!!e[0].match(/(cssVarPrefix|colorSchemeSelector|rootSelector|typography|mixins|breakpoints|direction|transitions)/)||!!e[0].match(/sxConfig$/)||e[0]==="palette"&&!!((t=e[1])!=null&&t.match(/(mode|contrastThreshold|tonalOffset)/))}const z0=e=>[...[...Array(25)].map((t,r)=>`--${e?`${e}-`:""}overlays-${r}`),`--${e?`${e}-`:""}palette-AppBar-darkBg`,`--${e?`${e}-`:""}palette-AppBar-darkColor`],G0=e=>(t,r)=>{const n=e.rootSelector||":root",a=e.colorSchemeSelector;let o=a;if(a==="class"&&(o=".%s"),a==="data"&&(o="[data-%s]"),a!=null&&a.startsWith("data-")&&!a.includes("%s")&&(o=`[${a}="%s"]`),e.defaultColorScheme===t){if(t==="dark"){const s={};return z0(e.cssVarPrefix).forEach(i=>{s[i]=r[i],delete r[i]}),o==="media"?{[n]:r,"@media (prefers-color-scheme: dark)":{[n]:s}}:o?{[o.replace("%s",t)]:s,[`${n}, ${o.replace("%s",t)}`]:r}:{[n]:{...r,...s}}}if(o&&o!=="media")return`${n}, ${o.replace("%s",String(t))}`}else if(t){if(o==="media")return{[`@media (prefers-color-scheme: ${String(t)})`]:{[n]:r}};if(o)return o.replace("%s",String(t))}return n};function H0(e,t){t.forEach(r=>{e[r]||(e[r]={})})}function H(e,t,r){!e[t]&&r&&(e[t]=r)}function Kn(e){return typeof e!="string"||!e.startsWith("hsl")?e:Hh(e)}function Ut(e,t){`${t}Channel`in e||(e[`${t}Channel`]=Yn(Kn(e[t]),`MUI: Can't create \`palette.${t}Channel\` because \`palette.${t}\` is not one of these formats: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().
|
|
76
|
+
To suppress this warning, you need to explicitly provide the \`palette.${t}Channel\` as a string (in rgb format, for example "12 12 12") or undefined if you want to remove the channel token.`))}function q0(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const Tt=e=>{try{return e()}catch{}},J0=(e="mui")=>o0(e);function Qs(e,t,r,n){if(!t)return;t=t===!0?{}:t;const a=n==="dark"?"dark":"light";if(!r){e[n]=B0({...t,palette:{mode:a,...t==null?void 0:t.palette}});return}const{palette:o,...s}=Li({...r,palette:{mode:a,...t==null?void 0:t.palette}});return e[n]={...t,palette:o,opacity:{...Yh(a),...t==null?void 0:t.opacity},overlays:(t==null?void 0:t.overlays)||Kh(a)},s}function W0(e={},...t){const{colorSchemes:r={light:!0},defaultColorScheme:n,disableCssColorScheme:a=!1,cssVarPrefix:o="mui",shouldSkipGeneratingVar:s=F0,colorSchemeSelector:i=r.light&&r.dark?"media":void 0,rootSelector:l=":root",...c}=e,u=Object.keys(r)[0],d=n||(r.light&&u!=="light"?"light":u),h=J0(o),{[d]:p,light:f,dark:m,...b}=r,x={...b};let _=p;if((d==="dark"&&!("dark"in r)||d==="light"&&!("light"in r))&&(_=!0),!_)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${d}\` option is either missing or invalid.`:sr(21,d));const O=Qs(x,_,c,d);f&&!x.light&&Qs(x,f,void 0,"light"),m&&!x.dark&&Qs(x,m,void 0,"dark");let C={defaultColorScheme:d,...O,cssVarPrefix:o,colorSchemeSelector:i,rootSelector:l,getCssVar:h,colorSchemes:x,font:{...P0(O.typography),...O.font},spacing:q0(c.spacing)};Object.keys(C.colorSchemes).forEach(F=>{const y=C.colorSchemes[F].palette,T=z=>{const E=z.split("-"),B=E[1],te=E[2];return h(z,y[B][te])};if(y.mode==="light"&&(H(y.common,"background","#fff"),H(y.common,"onBackground","#000")),y.mode==="dark"&&(H(y.common,"background","#000"),H(y.common,"onBackground","#fff")),H0(y,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),y.mode==="light"){H(y.Alert,"errorColor",we(y.error.light,.6)),H(y.Alert,"infoColor",we(y.info.light,.6)),H(y.Alert,"successColor",we(y.success.light,.6)),H(y.Alert,"warningColor",we(y.warning.light,.6)),H(y.Alert,"errorFilledBg",T("palette-error-main")),H(y.Alert,"infoFilledBg",T("palette-info-main")),H(y.Alert,"successFilledBg",T("palette-success-main")),H(y.Alert,"warningFilledBg",T("palette-warning-main")),H(y.Alert,"errorFilledColor",Tt(()=>y.getContrastText(y.error.main))),H(y.Alert,"infoFilledColor",Tt(()=>y.getContrastText(y.info.main))),H(y.Alert,"successFilledColor",Tt(()=>y.getContrastText(y.success.main))),H(y.Alert,"warningFilledColor",Tt(()=>y.getContrastText(y.warning.main))),H(y.Alert,"errorStandardBg",Ce(y.error.light,.9)),H(y.Alert,"infoStandardBg",Ce(y.info.light,.9)),H(y.Alert,"successStandardBg",Ce(y.success.light,.9)),H(y.Alert,"warningStandardBg",Ce(y.warning.light,.9)),H(y.Alert,"errorIconColor",T("palette-error-main")),H(y.Alert,"infoIconColor",T("palette-info-main")),H(y.Alert,"successIconColor",T("palette-success-main")),H(y.Alert,"warningIconColor",T("palette-warning-main")),H(y.AppBar,"defaultBg",T("palette-grey-100")),H(y.Avatar,"defaultBg",T("palette-grey-400")),H(y.Button,"inheritContainedBg",T("palette-grey-300")),H(y.Button,"inheritContainedHoverBg",T("palette-grey-A100")),H(y.Chip,"defaultBorder",T("palette-grey-400")),H(y.Chip,"defaultAvatarColor",T("palette-grey-700")),H(y.Chip,"defaultIconColor",T("palette-grey-700")),H(y.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),H(y.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),H(y.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),H(y.LinearProgress,"primaryBg",Ce(y.primary.main,.62)),H(y.LinearProgress,"secondaryBg",Ce(y.secondary.main,.62)),H(y.LinearProgress,"errorBg",Ce(y.error.main,.62)),H(y.LinearProgress,"infoBg",Ce(y.info.main,.62)),H(y.LinearProgress,"successBg",Ce(y.success.main,.62)),H(y.LinearProgress,"warningBg",Ce(y.warning.main,.62)),H(y.Skeleton,"bg",`rgba(${T("palette-text-primaryChannel")} / 0.11)`),H(y.Slider,"primaryTrack",Ce(y.primary.main,.62)),H(y.Slider,"secondaryTrack",Ce(y.secondary.main,.62)),H(y.Slider,"errorTrack",Ce(y.error.main,.62)),H(y.Slider,"infoTrack",Ce(y.info.main,.62)),H(y.Slider,"successTrack",Ce(y.success.main,.62)),H(y.Slider,"warningTrack",Ce(y.warning.main,.62));const z=Ba(y.background.default,.8);H(y.SnackbarContent,"bg",z),H(y.SnackbarContent,"color",Tt(()=>y.getContrastText(z))),H(y.SpeedDialAction,"fabHoverBg",Ba(y.background.paper,.15)),H(y.StepConnector,"border",T("palette-grey-400")),H(y.StepContent,"border",T("palette-grey-400")),H(y.Switch,"defaultColor",T("palette-common-white")),H(y.Switch,"defaultDisabledColor",T("palette-grey-100")),H(y.Switch,"primaryDisabledColor",Ce(y.primary.main,.62)),H(y.Switch,"secondaryDisabledColor",Ce(y.secondary.main,.62)),H(y.Switch,"errorDisabledColor",Ce(y.error.main,.62)),H(y.Switch,"infoDisabledColor",Ce(y.info.main,.62)),H(y.Switch,"successDisabledColor",Ce(y.success.main,.62)),H(y.Switch,"warningDisabledColor",Ce(y.warning.main,.62)),H(y.TableCell,"border",Ce(Na(y.divider,1),.88)),H(y.Tooltip,"bg",Na(y.grey[700],.92))}if(y.mode==="dark"){H(y.Alert,"errorColor",Ce(y.error.light,.6)),H(y.Alert,"infoColor",Ce(y.info.light,.6)),H(y.Alert,"successColor",Ce(y.success.light,.6)),H(y.Alert,"warningColor",Ce(y.warning.light,.6)),H(y.Alert,"errorFilledBg",T("palette-error-dark")),H(y.Alert,"infoFilledBg",T("palette-info-dark")),H(y.Alert,"successFilledBg",T("palette-success-dark")),H(y.Alert,"warningFilledBg",T("palette-warning-dark")),H(y.Alert,"errorFilledColor",Tt(()=>y.getContrastText(y.error.dark))),H(y.Alert,"infoFilledColor",Tt(()=>y.getContrastText(y.info.dark))),H(y.Alert,"successFilledColor",Tt(()=>y.getContrastText(y.success.dark))),H(y.Alert,"warningFilledColor",Tt(()=>y.getContrastText(y.warning.dark))),H(y.Alert,"errorStandardBg",we(y.error.light,.9)),H(y.Alert,"infoStandardBg",we(y.info.light,.9)),H(y.Alert,"successStandardBg",we(y.success.light,.9)),H(y.Alert,"warningStandardBg",we(y.warning.light,.9)),H(y.Alert,"errorIconColor",T("palette-error-main")),H(y.Alert,"infoIconColor",T("palette-info-main")),H(y.Alert,"successIconColor",T("palette-success-main")),H(y.Alert,"warningIconColor",T("palette-warning-main")),H(y.AppBar,"defaultBg",T("palette-grey-900")),H(y.AppBar,"darkBg",T("palette-background-paper")),H(y.AppBar,"darkColor",T("palette-text-primary")),H(y.Avatar,"defaultBg",T("palette-grey-600")),H(y.Button,"inheritContainedBg",T("palette-grey-800")),H(y.Button,"inheritContainedHoverBg",T("palette-grey-700")),H(y.Chip,"defaultBorder",T("palette-grey-700")),H(y.Chip,"defaultAvatarColor",T("palette-grey-300")),H(y.Chip,"defaultIconColor",T("palette-grey-300")),H(y.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),H(y.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),H(y.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),H(y.LinearProgress,"primaryBg",we(y.primary.main,.5)),H(y.LinearProgress,"secondaryBg",we(y.secondary.main,.5)),H(y.LinearProgress,"errorBg",we(y.error.main,.5)),H(y.LinearProgress,"infoBg",we(y.info.main,.5)),H(y.LinearProgress,"successBg",we(y.success.main,.5)),H(y.LinearProgress,"warningBg",we(y.warning.main,.5)),H(y.Skeleton,"bg",`rgba(${T("palette-text-primaryChannel")} / 0.13)`),H(y.Slider,"primaryTrack",we(y.primary.main,.5)),H(y.Slider,"secondaryTrack",we(y.secondary.main,.5)),H(y.Slider,"errorTrack",we(y.error.main,.5)),H(y.Slider,"infoTrack",we(y.info.main,.5)),H(y.Slider,"successTrack",we(y.success.main,.5)),H(y.Slider,"warningTrack",we(y.warning.main,.5));const z=Ba(y.background.default,.98);H(y.SnackbarContent,"bg",z),H(y.SnackbarContent,"color",Tt(()=>y.getContrastText(z))),H(y.SpeedDialAction,"fabHoverBg",Ba(y.background.paper,.15)),H(y.StepConnector,"border",T("palette-grey-600")),H(y.StepContent,"border",T("palette-grey-600")),H(y.Switch,"defaultColor",T("palette-grey-300")),H(y.Switch,"defaultDisabledColor",T("palette-grey-600")),H(y.Switch,"primaryDisabledColor",we(y.primary.main,.55)),H(y.Switch,"secondaryDisabledColor",we(y.secondary.main,.55)),H(y.Switch,"errorDisabledColor",we(y.error.main,.55)),H(y.Switch,"infoDisabledColor",we(y.info.main,.55)),H(y.Switch,"successDisabledColor",we(y.success.main,.55)),H(y.Switch,"warningDisabledColor",we(y.warning.main,.55)),H(y.TableCell,"border",we(Na(y.divider,1),.68)),H(y.Tooltip,"bg",Na(y.grey[700],.92))}Ut(y.background,"default"),Ut(y.background,"paper"),Ut(y.common,"background"),Ut(y.common,"onBackground"),Ut(y,"divider"),Object.keys(y).forEach(z=>{const E=y[z];z!=="tonalOffset"&&E&&typeof E=="object"&&(E.main&&H(y[z],"mainChannel",Yn(Kn(E.main))),E.light&&H(y[z],"lightChannel",Yn(Kn(E.light))),E.dark&&H(y[z],"darkChannel",Yn(Kn(E.dark))),E.contrastText&&H(y[z],"contrastTextChannel",Yn(Kn(E.contrastText))),z==="text"&&(Ut(y[z],"primary"),Ut(y[z],"secondary")),z==="action"&&(E.active&&Ut(y[z],"active"),E.selected&&Ut(y[z],"selected")))})}),C=t.reduce((F,y)=>et(F,y),C);const P={prefix:o,disableCssColorScheme:a,shouldSkipGeneratingVar:s,getSelector:G0(C)},{vars:w,generateThemeVars:R,generateStyleSheets:I}=l0(C,P);return C.vars=w,Object.entries(C.colorSchemes[C.defaultColorScheme]).forEach(([F,y])=>{C[F]=y}),C.generateThemeVars=R,C.generateStyleSheets=I,C.generateSpacing=function(){return kh(c.spacing,es(this))},C.getColorSchemeSelector=c0(i),C.spacing=C.generateSpacing(),C.shouldSkipGeneratingVar=s,C.unstable_sxConfig={...Sa,...c==null?void 0:c.unstable_sxConfig},C.unstable_sx=function(y){return cn({sx:y,theme:this})},C.toRuntimeSource=Wh,C}function Wc(e,t,r){e.colorSchemes&&r&&(e.colorSchemes[t]={...r!==!0&&r,palette:Cl({...r===!0?{}:r.palette,mode:t})})}function Qh(e={},...t){const{palette:r,cssVariables:n=!1,colorSchemes:a=r?void 0:{light:!0},defaultColorScheme:o=r==null?void 0:r.mode,...s}=e,i=o||"light",l=a==null?void 0:a[i],c={...a,...r?{[i]:{...typeof l!="boolean"&&l,palette:r}}:void 0};if(n===!1){if(!("colorSchemes"in e))return Li(e,...t);let u=r;"palette"in e||c[i]&&(c[i]!==!0?u=c[i].palette:i==="dark"&&(u={mode:"dark"}));const d=Li({...e,palette:u},...t);return d.defaultColorScheme=i,d.colorSchemes=c,d.palette.mode==="light"&&(d.colorSchemes.light={...c.light!==!0&&c.light,palette:d.palette},Wc(d,"dark",c.dark)),d.palette.mode==="dark"&&(d.colorSchemes.dark={...c.dark!==!0&&c.dark,palette:d.palette},Wc(d,"light",c.light)),d}return!r&&!("light"in c)&&i==="light"&&(c.light=!0),W0({...s,colorSchemes:c,defaultColorScheme:i,...typeof n!="boolean"&&n},...t)}const Xh=Qh();function Y0({props:e,name:t}){return zh({props:e,name:t,defaultTheme:Xh,themeId:Eh})}function Pl(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const K0=e=>Pl(e)&&e!=="classes",dt=Bh({themeId:Eh,defaultTheme:Xh,rootShouldForwardProp:K0});function Zh(...e){const t=V.useRef(void 0),r=V.useCallback(n=>{const a=e.map(o=>{if(o==null)return null;if(typeof o=="function"){const s=o,i=s(n);return typeof i=="function"?i:()=>{s(null)}}return o.current=n,()=>{o.current=null}});return()=>{a.forEach(o=>o==null?void 0:o())}},e);return V.useMemo(()=>e.every(n=>n==null)?null:n=>{t.current&&(t.current(),t.current=void 0),n!=null&&(t.current=r(n))},e)}let Yc=0;function Q0(e){const[t,r]=V.useState(e),n=t;return V.useEffect(()=>{t==null&&(Yc+=1,r(`mui-${Yc}`))},[t]),n}const X0={...V},Kc=X0.useId;function Z0(e){return Kc!==void 0?Kc():Q0(e)}class eb{constructor(t){this.value=void 0,this.listeners=void 0,this.subscribe=r=>(this.listeners.add(r),()=>{this.listeners.delete(r)}),this.getSnapshot=()=>this.value,this.update=r=>{const n=r(this.value);n!==this.value&&(this.value=n,this.listeners.forEach(a=>a(n)))},this.value=t,this.listeners=new Set}}const Ft=typeof window<"u"?V.useLayoutEffect:V.useEffect,ls=({params:e,store:t})=>{V.useEffect(()=>{t.update(n=>Y({},n,{animation:Y({},n.animation,{skip:e.skipAnimation})}))},[t,e.skipAnimation]);const r=V.useCallback(()=>{let n=!1;return t.update(a=>Y({},a,{animation:Y({},a.animation,{skipAnimationRequests:a.animation.skipAnimationRequests+1})})),()=>{n||(n=!0,t.update(a=>Y({},a,{animation:Y({},a.animation,{skipAnimationRequests:a.animation.skipAnimationRequests-1})})))}},[t]);return Ft(()=>{if(typeof window>"u"||!(window!=null&&window.matchMedia))return;let a;const o=i=>{i.matches?a=r():a==null||a()},s=window.matchMedia("(prefers-reduced-motion)");return o(s),s.addEventListener("change",o),()=>{s.removeEventListener("change",o)}},[r,t]),{instance:{disableAnimation:r}}};ls.params={skipAnimation:!0};ls.getDefaultizedParams=({params:e})=>Y({},e,{skipAnimation:e.skipAnimation??!1});ls.getInitialState=({skipAnimation:e})=>{const t=typeof window>"u"||!(window!=null&&window.matchMedia),r=process.env.NODE_ENV==="test"?t:!1;return{animation:{skip:e,skipAnimationRequests:r?1:0}}};var tb=(e,t,r)=>{if(t.length===1&&t[0]===r){let n=!1;try{const a={};e(a)===a&&(n=!0)}catch{}if(n){let a;try{throw new Error}catch(o){({stack:a}=o)}console.warn(`The result function returned its own inputs without modification. e.g
|
|
77
77
|
\`createSelector([state => state.todos], todos => todos)\`
|
|
78
78
|
This could lead to inefficient memoization and unnecessary re-renders.
|
|
79
|
-
Ensure transformation logic is in the result function, and extraction logic is in the input selectors.`,{stack:a})}}},
|
|
79
|
+
Ensure transformation logic is in the result function, and extraction logic is in the input selectors.`,{stack:a})}}},rb=(e,t,r)=>{const{memoize:n,memoizeOptions:a}=t,{inputSelectorResults:o,inputSelectorResultsCopy:s}=e,i=n(()=>({}),...a);if(!(i.apply(null,o)===i.apply(null,s))){let c;try{throw new Error}catch(u){({stack:c}=u)}console.warn(`An input selector returned a different result when passed same arguments.
|
|
80
80
|
This means your output selector will likely run more frequently than intended.
|
|
81
81
|
Avoid returning a new reference inside your input selector, e.g.
|
|
82
|
-
\`createSelector([state => state.todos.map(todo => todo.id)], todoIds => todoIds.length)\``,{arguments:r,firstInputs:o,secondInputs:s,stack:c})}},
|
|
82
|
+
\`createSelector([state => state.todos.map(todo => todo.id)], todoIds => todoIds.length)\``,{arguments:r,firstInputs:o,secondInputs:s,stack:c})}},nb={inputStabilityCheck:"once",identityFunctionCheck:"once"},Ro=Symbol("NOT_FOUND");function ab(e,t=`expected a function, instead received ${typeof e}`){if(typeof e!="function")throw new TypeError(t)}function ob(e,t=`expected an object, instead received ${typeof e}`){if(typeof e!="object")throw new TypeError(t)}function sb(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(r=>typeof r=="function")){const r=e.map(n=>typeof n=="function"?`function ${n.name||"unnamed"}()`:typeof n).join(", ");throw new TypeError(`${t}[${r}]`)}}var Qc=e=>Array.isArray(e)?e:[e];function ib(e){const t=Array.isArray(e[0])?e[0]:e;return sb(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function Xc(e,t){const r=[],{length:n}=e;for(let a=0;a<n;a++)r.push(e[a].apply(null,t));return r}var lb=(e,t)=>{const{identityFunctionCheck:r,inputStabilityCheck:n}={...nb,...t};return{identityFunctionCheck:{shouldRun:r==="always"||r==="once"&&e,run:tb},inputStabilityCheck:{shouldRun:n==="always"||n==="once"&&e,run:rb}}};function cb(e){let t;return{get(r){return t&&e(t.key,r)?t.value:Ro},put(r,n){t={key:r,value:n}},getEntries(){return t?[t]:[]},clear(){t=void 0}}}function ub(e,t){let r=[];function n(i){const l=r.findIndex(c=>t(i,c.key));if(l>-1){const c=r[l];return l>0&&(r.splice(l,1),r.unshift(c)),c.value}return Ro}function a(i,l){n(i)===Ro&&(r.unshift({key:i,value:l}),r.length>e&&r.pop())}function o(){return r}function s(){r=[]}return{get:n,put:a,getEntries:o,clear:s}}var db=(e,t)=>e===t;function hb(e){return function(r,n){if(r===null||n===null||r.length!==n.length)return!1;const{length:a}=r;for(let o=0;o<a;o++)if(!e(r[o],n[o]))return!1;return!0}}function pb(e,t){const r=typeof t=="object"?t:{equalityCheck:t},{equalityCheck:n=db,maxSize:a=1,resultEqualityCheck:o}=r,s=hb(n);let i=0;const l=a<=1?cb(s):ub(a,s);function c(){let u=l.get(arguments);if(u===Ro){if(u=e.apply(null,arguments),i++,o){const h=l.getEntries().find(p=>o(p.value,u));h&&(u=h.value,i!==0&&i--)}l.put(arguments,u)}return u}return c.clearCache=()=>{l.clear(),c.resetResultsCount()},c.resultsCount=()=>i,c.resetResultsCount=()=>{i=0},c}var mb=class{constructor(e){this.value=e}deref(){return this.value}},fb=typeof WeakRef<"u"?WeakRef:mb,gb=0,Zc=1;function Fa(){return{s:gb,v:void 0,o:null,p:null}}function ep(e,t={}){let r=Fa();const{resultEqualityCheck:n}=t;let a,o=0;function s(){var d;let i=r;const{length:l}=arguments;for(let h=0,p=l;h<p;h++){const f=arguments[h];if(typeof f=="function"||typeof f=="object"&&f!==null){let m=i.o;m===null&&(i.o=m=new WeakMap);const b=m.get(f);b===void 0?(i=Fa(),m.set(f,i)):i=b}else{let m=i.p;m===null&&(i.p=m=new Map);const b=m.get(f);b===void 0?(i=Fa(),m.set(f,i)):i=b}}const c=i;let u;if(i.s===Zc)u=i.v;else if(u=e.apply(null,arguments),o++,n){const h=((d=a==null?void 0:a.deref)==null?void 0:d.call(a))??a;h!=null&&n(h,u)&&(u=h,o!==0&&o--),a=typeof u=="object"&&u!==null||typeof u=="function"?new fb(u):u}return c.s=Zc,c.v=u,u}return s.clearCache=()=>{r=Fa(),s.resetResultsCount()},s.resultsCount=()=>o,s.resetResultsCount=()=>{o=0},s}function tp(e,...t){const r=typeof e=="function"?{memoize:e,memoizeOptions:t}:e,n=(...a)=>{let o=0,s=0,i,l={},c=a.pop();typeof c=="object"&&(l=c,c=a.pop()),ab(c,`createSelector expects an output function after the inputs, but received: [${typeof c}]`);const u={...r,...l},{memoize:d,memoizeOptions:h=[],argsMemoize:p=ep,argsMemoizeOptions:f=[],devModeChecks:m={}}=u,b=Qc(h),x=Qc(f),_=ib(a),O=d(function(){return o++,c.apply(null,arguments)},...b);let C=!0;const P=p(function(){s++;const R=Xc(_,arguments);if(i=O.apply(null,R),process.env.NODE_ENV!=="production"){const{identityFunctionCheck:I,inputStabilityCheck:F}=lb(C,m);if(I.shouldRun&&I.run(c,R,i),F.shouldRun){const y=Xc(_,arguments);F.run({inputSelectorResults:R,inputSelectorResultsCopy:y},{memoize:d,memoizeOptions:b},arguments)}C&&(C=!1)}return i},...x);return Object.assign(P,{resultFunc:c,memoizedResultFunc:O,dependencies:_,dependencyRecomputations:()=>s,resetDependencyRecomputations:()=>{s=0},lastResult:()=>i,recomputations:()=>o,resetRecomputations:()=>{o=0},memoize:d,argsMemoize:p})};return Object.assign(n,{withTypes:()=>n}),n}var yb=tp(ep),bb=Object.assign((e,t=yb)=>{ob(e,`createStructuredSelector expects first argument to be an object where each property is a selector, instead received a ${typeof e}`);const r=Object.keys(e),n=r.map(o=>e[o]);return t(n,(...o)=>o.reduce((s,i,l)=>(s[r[l]]=i,s),{}))},{withTypes:()=>bb});const vb=tp({memoize:pb,memoizeOptions:{maxSize:1,equalityCheck:Object.is}}),eu=new WeakMap,pe=(...e)=>(r,...n)=>{const a=r.cacheKey;let o=eu.get(a);o||(o=new Map,eu.set(a,o));const s=o.get(e);if(s)return s(r,...n);const i=vb(...e);return o.set(e,i),i(r,...n)},Sb=e=>e.animation,xb=pe([Sb],e=>e.skip||e.skipAnimationRequests>0);function Ob(e){return e&&e.ownerDocument||document}function wb(e){return Ob(e).defaultView||window}var za={exports:{}},Xs={},Ga={exports:{}},Zs={};/**
|
|
83
83
|
* @license React
|
|
84
84
|
* use-sync-external-store-shim.production.js
|
|
85
85
|
*
|
|
@@ -87,7 +87,7 @@ Avoid returning a new reference inside your input selector, e.g.
|
|
|
87
87
|
*
|
|
88
88
|
* This source code is licensed under the MIT license found in the
|
|
89
89
|
* LICENSE file in the root directory of this source tree.
|
|
90
|
-
*/var
|
|
90
|
+
*/var tu;function Cb(){if(tu)return Zs;tu=1;var e=ee;function t(d,h){return d===h&&(d!==0||1/d===1/h)||d!==d&&h!==h}var r=typeof Object.is=="function"?Object.is:t,n=e.useState,a=e.useEffect,o=e.useLayoutEffect,s=e.useDebugValue;function i(d,h){var p=h(),f=n({inst:{value:p,getSnapshot:h}}),m=f[0].inst,b=f[1];return o(function(){m.value=p,m.getSnapshot=h,l(m)&&b({inst:m})},[d,p,h]),a(function(){return l(m)&&b({inst:m}),d(function(){l(m)&&b({inst:m})})},[d]),s(p),p}function l(d){var h=d.getSnapshot;d=d.value;try{var p=h();return!r(d,p)}catch{return!0}}function c(d,h){return h()}var u=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?c:i;return Zs.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:u,Zs}var ei={};/**
|
|
91
91
|
* @license React
|
|
92
92
|
* use-sync-external-store-shim.development.js
|
|
93
93
|
*
|
|
@@ -95,7 +95,7 @@ Avoid returning a new reference inside your input selector, e.g.
|
|
|
95
95
|
*
|
|
96
96
|
* This source code is licensed under the MIT license found in the
|
|
97
97
|
* LICENSE file in the root directory of this source tree.
|
|
98
|
-
*/var
|
|
98
|
+
*/var ru;function Pb(){return ru||(ru=1,process.env.NODE_ENV!=="production"&&function(){function e(p,f){return p===f&&(p!==0||1/p===1/f)||p!==p&&f!==f}function t(p,f){u||a.startTransition===void 0||(u=!0,console.error("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));var m=f();if(!d){var b=f();o(m,b)||(console.error("The result of getSnapshot should be cached to avoid an infinite loop"),d=!0)}b=s({inst:{value:m,getSnapshot:f}});var x=b[0].inst,_=b[1];return l(function(){x.value=m,x.getSnapshot=f,r(x)&&_({inst:x})},[p,m,f]),i(function(){return r(x)&&_({inst:x}),p(function(){r(x)&&_({inst:x})})},[p]),c(m),m}function r(p){var f=p.getSnapshot;p=p.value;try{var m=f();return!o(p,m)}catch{return!0}}function n(p,f){return f()}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var a=ee,o=typeof Object.is=="function"?Object.is:e,s=a.useState,i=a.useEffect,l=a.useLayoutEffect,c=a.useDebugValue,u=!1,d=!1,h=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?n:t;ei.useSyncExternalStore=a.useSyncExternalStore!==void 0?a.useSyncExternalStore:h,typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())}()),ei}var nu;function rp(){return nu||(nu=1,process.env.NODE_ENV==="production"?Ga.exports=Cb():Ga.exports=Pb()),Ga.exports}/**
|
|
99
99
|
* @license React
|
|
100
100
|
* use-sync-external-store-shim/with-selector.production.js
|
|
101
101
|
*
|
|
@@ -103,7 +103,7 @@ Avoid returning a new reference inside your input selector, e.g.
|
|
|
103
103
|
*
|
|
104
104
|
* This source code is licensed under the MIT license found in the
|
|
105
105
|
* LICENSE file in the root directory of this source tree.
|
|
106
|
-
*/var
|
|
106
|
+
*/var au;function Tb(){if(au)return Xs;au=1;var e=ee,t=rp();function r(c,u){return c===u&&(c!==0||1/c===1/u)||c!==c&&u!==u}var n=typeof Object.is=="function"?Object.is:r,a=t.useSyncExternalStore,o=e.useRef,s=e.useEffect,i=e.useMemo,l=e.useDebugValue;return Xs.useSyncExternalStoreWithSelector=function(c,u,d,h,p){var f=o(null);if(f.current===null){var m={hasValue:!1,value:null};f.current=m}else m=f.current;f=i(function(){function x(w){if(!_){if(_=!0,O=w,w=h(w),p!==void 0&&m.hasValue){var R=m.value;if(p(R,w))return C=R}return C=w}if(R=C,n(O,w))return R;var I=h(w);return p!==void 0&&p(R,I)?(O=w,R):(O=w,C=I)}var _=!1,O,C,P=d===void 0?null:d;return[function(){return x(u())},P===null?void 0:function(){return x(P())}]},[u,d,h,p]);var b=a(c,f[0],f[1]);return s(function(){m.hasValue=!0,m.value=b},[b]),l(b),b},Xs}var ti={};/**
|
|
107
107
|
* @license React
|
|
108
108
|
* use-sync-external-store-shim/with-selector.development.js
|
|
109
109
|
*
|
|
@@ -111,20 +111,20 @@ Avoid returning a new reference inside your input selector, e.g.
|
|
|
111
111
|
*
|
|
112
112
|
* This source code is licensed under the MIT license found in the
|
|
113
113
|
* LICENSE file in the root directory of this source tree.
|
|
114
|
-
*/var au;function Pb(){return au||(au=1,process.env.NODE_ENV!=="production"&&function(){function e(c,u){return c===u&&(c!==0||1/c===1/u)||c!==c&&u!==u}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var t=ee,r=tp(),n=typeof Object.is=="function"?Object.is:e,a=r.useSyncExternalStore,o=t.useRef,s=t.useEffect,i=t.useMemo,l=t.useDebugValue;ti.useSyncExternalStoreWithSelector=function(c,u,d,h,p){var f=o(null);if(f.current===null){var m={hasValue:!1,value:null};f.current=m}else m=f.current;f=i(function(){function x(w){if(!V){if(V=!0,O=w,w=h(w),p!==void 0&&m.hasValue){var A=m.value;if(p(A,w))return C=A}return C=w}if(A=C,n(O,w))return A;var E=h(w);return p!==void 0&&p(A,E)?(O=w,A):(O=w,C=E)}var V=!1,O,C,P=d===void 0?null:d;return[function(){return x(u())},P===null?void 0:function(){return x(P())}]},[u,d,h,p]);var b=a(c,f[0],f[1]);return s(function(){m.hasValue=!0,m.value=b},[b]),l(b),b},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())}()),ti}var ou;function Tb(){return ou||(ou=1,process.env.NODE_ENV==="production"?Fa.exports=Cb():Fa.exports=Pb()),Fa.exports}var Ab=Tb();const Rb=Object.is,at=(e,t,r=[],n=Rb)=>{const a=o=>t(o,...r);return Ab.useSyncExternalStoreWithSelector(e.subscribe,e.getSnapshot,e.getSnapshot,a,n)},Vb="DEFAULT_X_AXIS_KEY",_b="DEFAULT_Y_AXIS_KEY",Eb={top:20,bottom:20,left:20,right:20},Ib=45,Mb=25,rp=20,bn=e=>{var t;return(t=e.cartesianAxis)==null?void 0:t.x},vn=e=>{var t;return(t=e.cartesianAxis)==null?void 0:t.y},$b=pe([vn],e=>(e??[]).reduce((t,r)=>{var n;return r.position==="left"?t+(r.width||0)+((n=r.zoom)!=null&&n.slider.enabled?r.zoom.slider.size:0):t},0)),jb=pe([vn],e=>(e??[]).reduce((t,r)=>{var n;return r.position==="right"?t+(r.width||0)+((n=r.zoom)!=null&&n.slider.enabled?r.zoom.slider.size:0):t},0)),kb=pe([bn],e=>(e??[]).reduce((t,r)=>{var n;return r.position==="top"?t+(r.height||0)+((n=r.zoom)!=null&&n.slider.enabled?r.zoom.slider.size:0):t},0)),Ub=pe([bn],e=>(e??[]).reduce((t,r)=>{var n;return r.position==="bottom"?t+(r.height||0)+((n=r.zoom)!=null&&n.slider.enabled?r.zoom.slider.size:0):t},0)),Lb=e=>e.dimensions,np=e=>e.dimensions.width,ap=e=>e.dimensions.height,Db=e=>e.dimensions.margin.top,Bb=e=>e.dimensions.margin.right,Nb=e=>e.dimensions.margin.bottom,Fb=e=>e.dimensions.margin.left,Oa=pe([np,ap,Db,Bb,Nb,Fb,kb,jb,Ub,$b],(e,t,r,n,a,o,s,i,l,c)=>({width:e-o-n-c-i,left:o+c,right:n+i,height:t-r-a-s-l,top:r+s,bottom:a+l})),zb=pe([Lb],e=>({width:e.propsWidth,height:e.propsHeight})),Gb=pe([np,ap],(e,t)=>({width:e,height:t}));function op(e,t){return typeof e=="number"?{top:e,bottom:e,left:e,right:e}:t?Y({},t,e):e}const Hb=10,ls=({params:e,store:t,svgRef:r})=>{const n=e.width!==void 0&&e.height!==void 0,a=B.useRef({displayError:!1,initialCompute:!0,computeRun:0}),[o,s]=B.useState(0),[i,l]=B.useState(0),c=B.useCallback(()=>{const f=r==null?void 0:r.current;if(!f)return{};const b=xb(f).getComputedStyle(f),x=Math.floor(parseFloat(b.height))||0,V=Math.floor(parseFloat(b.width))||0;return t.update(O=>O.dimensions.width===V&&O.dimensions.height===x?O:Y({},O,{dimensions:{margin:{top:e.margin.top,right:e.margin.right,bottom:e.margin.bottom,left:e.margin.left},width:e.width??V,height:e.height??x,propsWidth:e.width,propsHeight:e.height}})),{height:x,width:V}},[t,r,e.height,e.width,e.margin.left,e.margin.right,e.margin.top,e.margin.bottom]);B.useEffect(()=>{t.update(f=>{const m=e.width??f.dimensions.width,b=e.height??f.dimensions.height;return Y({},f,{dimensions:{margin:{top:e.margin.top,right:e.margin.right,bottom:e.margin.bottom,left:e.margin.left},width:m,height:b,propsHeight:e.height,propsWidth:e.width}})})},[t,e.height,e.width,e.margin.left,e.margin.right,e.margin.top,e.margin.bottom]),B.useEffect(()=>{a.current.displayError=!0},[]),Nt(()=>{if(n||!a.current.initialCompute||a.current.computeRun>Hb)return;const f=c();f.width!==o||f.height!==i?(a.current.computeRun+=1,f.width!==void 0&&s(f.width),f.height!==void 0&&l(f.height)):a.current.initialCompute&&(a.current.initialCompute=!1)},[i,o,c,n]),Nt(()=>{if(n)return()=>{};c();const f=r.current;if(typeof ResizeObserver>"u")return()=>{};let m;const b=new ResizeObserver(()=>{m=requestAnimationFrame(()=>{c()})});return f&&b.observe(f),()=>{m&&cancelAnimationFrame(m),f&&b.unobserve(f)}},[c,n,r]),process.env.NODE_ENV!=="production"&&(a.current.displayError&&e.width===void 0&&o===0&&(console.error("MUI X Charts: ChartContainer does not have `width` prop, and its container has no `width` defined."),a.current.displayError=!1),a.current.displayError&&e.height===void 0&&i===0&&(console.error("MUI X Charts: ChartContainer does not have `height` prop, and its container has no `height` defined."),a.current.displayError=!1));const u=at(t,Oa),d=B.useCallback(f=>f>=u.left-1&&f<=u.left+u.width,[u.left,u.width]),h=B.useCallback(f=>f>=u.top-1&&f<=u.top+u.height,[u.height,u.top]);return{instance:{isPointInside:B.useCallback((f,m,b)=>b&&"closest"in b&&b.closest("[data-drawing-container]")?!0:d(f)&&h(m),[d,h]),isXInside:d,isYInside:h}}};ls.params={width:!0,height:!0,margin:!0};ls.getDefaultizedParams=({params:e})=>Y({},e,{margin:op(e.margin,Eb)});ls.getInitialState=({width:e,height:t,margin:r})=>({dimensions:{margin:r,width:e??0,height:t??0,propsWidth:e,propsHeight:t}});const Tl=({params:e,store:t})=>(Nt(()=>{t.update(r=>Y({},r,{experimentalFeatures:e.experimentalFeatures}))},[t,e.experimentalFeatures]),{});Tl.params={experimentalFeatures:!0};Tl.getInitialState=({experimentalFeatures:e})=>({experimentalFeatures:e});const qb=e=>e.experimentalFeatures,sp=pe([qb],e=>!!(e!=null&&e.preferStrictDomainInLineCharts));let su=0;const Jb=()=>(su+=1,`mui-chart-${su}`),Al=({params:e,store:t})=>(B.useEffect(()=>{t.update(r=>e.id===void 0||e.id===r.id.providedChartId&&r.id.chartId!==void 0?r:Y({},r,{id:Y({},r.id,{chartId:e.id??Jb()})}))},[t,e.id]),{});Al.params={id:!0};Al.getInitialState=({id:e})=>({id:{chartId:e,providedChartId:e}});const Wb=e=>e.id,Yb=pe([Wb],e=>e.chartId),Kb=["#4254FB","#FFB422","#FA4F58","#0DBEFF","#22BF75","#FA83B4","#FF7511"],Qb=["#495AFB","#FFC758","#F35865","#30C8FF","#44CE8D","#F286B3","#FF8C39"],ip=e=>e==="dark"?Qb:Kb,lp=({series:e,colors:t,seriesConfig:r,dataset:n})=>{const a={};e.forEach((s,i)=>{var u;const l=r[s.type].getSeriesWithDefaultValues(s,i,t),c=l.id;if(a[s.type]===void 0&&(a[s.type]={series:{},seriesOrder:[]}),((u=a[s.type])==null?void 0:u.series[c])!==void 0)throw new Error(`MUI X Charts: series' id "${c}" is not unique.`);a[s.type].series[c]=l,a[s.type].seriesOrder.push(c)});const o={};return Object.keys(r).forEach(s=>{var l,c;const i=a[s];i!==void 0&&(o[s]=((c=(l=r[s])==null?void 0:l.seriesProcessor)==null?void 0:c.call(l,i,n))??a[s])}),o},cs=({params:e,store:t,seriesConfig:r})=>{const{series:n,dataset:a,theme:o,colors:s}=e,i=B.useRef(!0);return B.useEffect(()=>{if(i.current){i.current=!1;return}t.update(l=>Y({},l,{series:Y({},l.series,{processedSeries:lp({series:n,colors:typeof s=="function"?s(o):s,seriesConfig:r,dataset:a})})}))},[s,a,n,o,r,t]),{}};cs.params={dataset:!0,series:!0,colors:!0,theme:!0};const Xb=[];cs.getDefaultizedParams=({params:e})=>{var t;return Y({},e,{series:(t=e.series)!=null&&t.length?e.series:Xb,colors:e.colors??ip,theme:e.theme??"light"})};cs.getInitialState=({series:e=[],colors:t,theme:r,dataset:n},a,o)=>({series:{seriesConfig:o,processedSeries:lp({series:e,colors:typeof t=="function"?t(r):t,seriesConfig:o,dataset:n})}});const cp=e=>e.series,wa=pe([cp],e=>e.processedSeries),us=pe([cp],e=>e.seriesConfig),Zb={abort:!0,animationcancel:!0,animationend:!0,animationiteration:!0,animationstart:!0,auxclick:!0,beforeinput:!0,beforetoggle:!0,blur:!0,cancel:!0,canplay:!0,canplaythrough:!0,change:!0,click:!0,close:!0,compositionend:!0,compositionstart:!0,compositionupdate:!0,contextlost:!0,contextmenu:!0,contextrestored:!0,copy:!0,cuechange:!0,cut:!0,dblclick:!0,drag:!0,dragend:!0,dragenter:!0,dragleave:!0,dragover:!0,dragstart:!0,drop:!0,durationchange:!0,emptied:!0,ended:!0,error:!0,focus:!0,focusin:!0,focusout:!0,formdata:!0,gotpointercapture:!0,input:!0,invalid:!0,keydown:!0,keypress:!0,keyup:!0,load:!0,loadeddata:!0,loadedmetadata:!0,loadstart:!0,lostpointercapture:!0,mousedown:!0,mouseenter:!0,mouseleave:!0,mousemove:!0,mouseout:!0,mouseover:!0,mouseup:!0,paste:!0,pause:!0,play:!0,playing:!0,pointercancel:!0,pointerdown:!0,pointerenter:!0,pointerleave:!0,pointermove:!0,pointerout:!0,pointerover:!0,pointerup:!0,progress:!0,ratechange:!0,reset:!0,resize:!0,scroll:!0,scrollend:!0,securitypolicyviolation:!0,seeked:!0,seeking:!0,select:!0,selectionchange:!0,selectstart:!0,slotchange:!0,stalled:!0,submit:!0,suspend:!0,timeupdate:!0,toggle:!0,touchcancel:!0,touchend:!0,touchmove:!0,touchstart:!0,transitioncancel:!0,transitionend:!0,transitionrun:!0,transitionstart:!0,volumechange:!0,waiting:!0,webkitanimationend:!0,webkitanimationiteration:!0,webkitanimationstart:!0,webkittransitionend:!0,wheel:!0};class up{constructor(t){if(this.name=void 0,this.preventDefault=void 0,this.stopPropagation=void 0,this.preventIf=void 0,this.requiredKeys=void 0,this.keyboardManager=void 0,this.pointerMode=void 0,this.customData={},this.pointerManager=void 0,this.gesturesRegistry=void 0,this.element=void 0,this.state=void 0,this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,!t||!t.name)throw new Error("Gesture must be initialized with a valid name.");if(t.name in Zb)throw new Error(`Gesture can't be created with a native event name. Tried to use "${t.name}". Please use a custom name instead.`);this.name=t.name,this.preventDefault=t.preventDefault??!1,this.stopPropagation=t.stopPropagation??!1,this.preventIf=t.preventIf??[],this.requiredKeys=t.requiredKeys??[],this.pointerMode=t.pointerMode??[]}init(t,r,n,a){this.element=t,this.pointerManager=r,this.gesturesRegistry=n,this.keyboardManager=a;const o=`${this.name}ChangeOptions`;this.element.addEventListener(o,this.handleOptionsChange.bind(this));const s=`${this.name}ChangeState`;this.element.addEventListener(s,this.handleStateChange.bind(this))}handleOptionsChange(t){t&&t.detail&&this.updateOptions(t.detail)}updateOptions(t){this.preventDefault=t.preventDefault??this.preventDefault,this.stopPropagation=t.stopPropagation??this.stopPropagation,this.preventIf=t.preventIf??this.preventIf,this.requiredKeys=t.requiredKeys??this.requiredKeys,this.pointerMode=t.pointerMode??this.pointerMode}handleStateChange(t){t&&t.detail&&this.updateState(t.detail)}updateState(t){Object.assign(this.state,t)}getTargetElement(t){return this.isActive||this.element===t.target||this.element.contains(t.target)?this.element:null}set isActive(t){t?this.gesturesRegistry.registerActiveGesture(this.element,this):this.gesturesRegistry.unregisterActiveGesture(this.element,this)}get isActive(){return this.gesturesRegistry.isGestureActive(this.element,this)??!1}shouldPreventGesture(t){if(!this.keyboardManager.areKeysPressed(this.requiredKeys))return!0;if(this.preventIf.length===0)return!1;const r=this.gesturesRegistry.getActiveGestures(t);return this.preventIf.some(n=>r[n])}isPointerTypeAllowed(t){return!this.pointerMode||this.pointerMode.length===0?!0:this.pointerMode.includes(t)}destroy(){const t=`${this.name}ChangeOptions`;this.element.removeEventListener(t,this.handleOptionsChange.bind(this));const r=`${this.name}ChangeState`;this.element.removeEventListener(r,this.handleStateChange.bind(this))}}class ev{constructor(){this.activeGestures=new Map}registerActiveGesture(t,r){this.activeGestures.has(t)||this.activeGestures.set(t,new Set);const n=this.activeGestures.get(t),a={gesture:r,element:t};n.add(a)}unregisterActiveGesture(t,r){const n=this.activeGestures.get(t);n&&(n.forEach(a=>{a.gesture===r&&n.delete(a)}),n.size===0&&this.activeGestures.delete(t))}getActiveGestures(t){const r=this.activeGestures.get(t);return r?Array.from(r).reduce((n,a)=>(n[a.gesture.name]=!0,n),{}):{}}isGestureActive(t,r){const n=this.activeGestures.get(t);return n?Array.from(n).some(a=>a.gesture===r):!1}destroy(){this.activeGestures.clear()}unregisterElement(t){this.activeGestures.delete(t)}}class tv{constructor(){this.pressedKeys=new Set,this.handleKeyDown=t=>{this.pressedKeys.add(t.key)},this.handleKeyUp=t=>{this.pressedKeys.delete(t.key)},this.clearKeys=()=>{this.pressedKeys.clear()},this.initialize()}initialize(){typeof window>"u"||(window.addEventListener("keydown",this.handleKeyDown),window.addEventListener("keyup",this.handleKeyUp),window.addEventListener("blur",this.clearKeys))}areKeysPressed(t){return!t||t.length===0?!0:t.every(r=>r==="ControlOrMeta"?this.pressedKeys.has("Control")||this.pressedKeys.has("Meta"):this.pressedKeys.has(r))}destroy(){typeof window<"u"&&(window.removeEventListener("keydown",this.handleKeyDown),window.removeEventListener("keyup",this.handleKeyUp),window.removeEventListener("blur",this.clearKeys)),this.clearKeys()}}class rv{constructor(t){this.root=void 0,this.touchAction=void 0,this.passive=void 0,this.preventEventInterruption=!0,this.pointers=new Map,this.gestureHandlers=new Set,this.handleInterruptEvents=r=>{if(this.preventEventInterruption&&"pointerType"in r&&r.pointerType==="touch"){r.preventDefault();return}const n=new PointerEvent("forceCancel",{bubbles:!1,cancelable:!1}),a=this.pointers.values().next().value;if(this.pointers.size>0&&a){Object.defineProperties(n,{clientX:{value:a.clientX},clientY:{value:a.clientY},pointerId:{value:a.pointerId},pointerType:{value:a.pointerType}});for(const[o,s]of this.pointers.entries()){const i=Y({},s,{type:"forceCancel"});this.pointers.set(o,i)}}this.notifyHandlers(n),this.pointers.clear()},this.handlePointerEvent=r=>{const{type:n,pointerId:a}=r;if(n==="pointerdown"){if(this.pointers.set(a,this.createPointerData(r)),r.target instanceof Element)try{r.target.setPointerCapture(a)}catch{}}else if(n==="pointermove")this.pointers.set(a,this.createPointerData(r));else if(n==="pointerup"||n==="pointercancel"||n==="forceCancel"){if(r.target instanceof Element)try{r.target.releasePointerCapture(a)}catch{}this.pointers.set(a,this.createPointerData(r)),this.notifyHandlers(r),this.pointers.delete(a);return}this.notifyHandlers(r)},this.root=t.root??document.documentElement,this.touchAction=t.touchAction||"auto",this.passive=t.passive!==!1,this.preventEventInterruption=t.preventEventInterruption!==!1,this.setupEventListeners()}registerGestureHandler(t){return this.gestureHandlers.add(t),()=>{this.gestureHandlers.delete(t)}}getPointers(){return new Map(this.pointers)}setupEventListeners(){this.touchAction!=="auto"&&(this.root.style.touchAction=this.touchAction),this.root.addEventListener("pointerdown",this.handlePointerEvent,{passive:this.passive}),this.root.addEventListener("pointermove",this.handlePointerEvent,{passive:this.passive}),this.root.addEventListener("pointerup",this.handlePointerEvent,{passive:this.passive}),this.root.addEventListener("pointercancel",this.handlePointerEvent,{passive:this.passive}),this.root.addEventListener("forceCancel",this.handlePointerEvent,{passive:this.passive}),this.root.addEventListener("blur",this.handleInterruptEvents),this.root.addEventListener("contextmenu",this.handleInterruptEvents)}notifyHandlers(t){this.gestureHandlers.forEach(r=>r(this.pointers,t))}createPointerData(t){return{pointerId:t.pointerId,clientX:t.clientX,clientY:t.clientY,pageX:t.pageX,pageY:t.pageY,target:t.target,timeStamp:t.timeStamp,type:t.type,isPrimary:t.isPrimary,pressure:t.pressure,width:t.width,height:t.height,pointerType:t.pointerType,srcEvent:t}}destroy(){this.root.removeEventListener("pointerdown",this.handlePointerEvent),this.root.removeEventListener("pointermove",this.handlePointerEvent),this.root.removeEventListener("pointerup",this.handlePointerEvent),this.root.removeEventListener("pointercancel",this.handlePointerEvent),this.root.removeEventListener("forceCancel",this.handlePointerEvent),this.root.removeEventListener("blur",this.handleInterruptEvents),this.root.removeEventListener("contextmenu",this.handleInterruptEvents),this.pointers.clear(),this.gestureHandlers.clear()}}class nv{constructor(t){this.gestureTemplates=new Map,this.elementGestureMap=new Map,this.activeGesturesRegistry=new ev,this.pointerManager=void 0,this.keyboardManager=new tv,this.pointerManager=new rv({root:t.root,touchAction:t.touchAction,passive:t.passive}),t.gestures&&t.gestures.length>0&&t.gestures.forEach(r=>{this.addGestureTemplate(r)})}addGestureTemplate(t){this.gestureTemplates.has(t.name)&&console.warn(`Gesture template with name "${t.name}" already exists. It will be overwritten.`),this.gestureTemplates.set(t.name,t)}setGestureOptions(t,r,n){const a=this.elementGestureMap.get(r);if(!a||!a.has(t)){console.error(`Gesture "${t}" not found on the provided element.`);return}const o=new CustomEvent(`${t}ChangeOptions`,{detail:n,bubbles:!1,cancelable:!1});r.dispatchEvent(o)}setGestureState(t,r,n){const a=this.elementGestureMap.get(r);if(!a||!a.has(t)){console.error(`Gesture "${t}" not found on the provided element.`);return}const o=new CustomEvent(`${t}ChangeState`,{detail:n,bubbles:!1,cancelable:!1});r.dispatchEvent(o)}registerElement(t,r,n){if(Array.isArray(t))return t.forEach(o=>{const s=n==null?void 0:n[o];this.registerSingleGesture(o,r,s)}),r;const a=n==null?void 0:n[t];return this.registerSingleGesture(t,r,a),r}registerSingleGesture(t,r,n){const a=this.gestureTemplates.get(t);if(!a)return console.error(`Gesture template "${t}" not found.`),!1;this.elementGestureMap.has(r)||this.elementGestureMap.set(r,new Map);const o=this.elementGestureMap.get(r);o.has(t)&&(console.warn(`Element already has gesture "${t}" registered. It will be replaced.`),this.unregisterElement(t,r));const s=a.clone(n);return s.init(r,this.pointerManager,this.activeGesturesRegistry,this.keyboardManager),o.set(t,s),!0}unregisterElement(t,r){const n=this.elementGestureMap.get(r);return!n||!n.has(t)?!1:(n.get(t).destroy(),n.delete(t),this.activeGesturesRegistry.unregisterElement(r),n.size===0&&this.elementGestureMap.delete(r),!0)}unregisterAllGestures(t){const r=this.elementGestureMap.get(t);if(r){for(const[,n]of r)n.destroy(),this.activeGesturesRegistry.unregisterElement(t);this.elementGestureMap.delete(t)}}destroy(){for(const[t]of this.elementGestureMap)this.unregisterAllGestures(t);this.gestureTemplates.clear(),this.elementGestureMap.clear(),this.activeGesturesRegistry.destroy(),this.keyboardManager.destroy()}}class Ca extends up{constructor(t){super(t),this.unregisterHandler=null,this.originalTarget=null,this.optionsType=void 0,this.mutableOptionsType=void 0,this.minPointers=void 0,this.maxPointers=void 0,this.minPointers=t.minPointers??1,this.maxPointers=t.maxPointers??1/0}init(t,r,n,a){super.init(t,r,n,a),this.unregisterHandler=this.pointerManager.registerGestureHandler((o,s)=>this.handlePointerEvent(o,s))}updateOptions(t){super.updateOptions(t),this.minPointers=t.minPointers??this.minPointers,this.maxPointers=t.maxPointers??this.maxPointers}getRelevantPointers(t,r){return t.filter(n=>this.isPointerTypeAllowed(n.pointerType)&&(r===n.target||n.target===this.originalTarget||r===this.originalTarget||r.contains(n.target)))}destroy(){this.unregisterHandler&&(this.unregisterHandler(),this.unregisterHandler=null),super.destroy()}}function av(e,t){const r=t.x-e.x,n=t.y-e.y;return Math.sqrt(r*r+n*n)}function ri(e){if(e.length<2)return 0;let t=0,r=0;for(let n=0;n<e.length;n+=1)for(let a=n+1;a<e.length;a+=1)t+=av({x:e[n].clientX,y:e[n].clientY},{x:e[a].clientX,y:e[a].clientY}),r+=1;return r>0?t/r:0}function Ft(e){if(e.length===0)return{x:0,y:0};const t=e.reduce((r,n)=>(r.x+=n.clientX,r.y+=n.clientY,r),{x:0,y:0});return{x:t.x/e.length,y:t.y/e.length}}function Sn(e,t){return`${e}${t==="ongoing"?"":t.charAt(0).toUpperCase()+t.slice(1)}`}const Ga=1e-5,Qt=1e-5,iu=.15;function ov(e,t){const r=t.x-e.x,n=t.y-e.y,a={vertical:null,horizontal:null,mainAxis:null},o=sv(t,e),s=Math.abs(r)>Math.abs(n)?"horizontal":"vertical",i=o||s==="horizontal"?Ga:iu,l=o?Ga:s==="horizontal"?iu:Ga;return Math.abs(r)>i&&(a.horizontal=r>0?"right":"left"),Math.abs(n)>l&&(a.vertical=n>0?"down":"up"),a.mainAxis=o?"diagonal":s,a}function sv(e,t){const r=t.x-e.x,n=t.y-e.y,a=Math.atan2(n,r)*180/Math.PI;return a>=-45+Qt&&a<=-22.5+Qt||a>=22.5+Qt&&a<=45+Qt||a>=135+Qt&&a<=157.5+Qt||a>=-157.5+Qt&&a<=-135+Qt}function iv(e,t){if(!e.vertical&&!e.horizontal)return!1;if(t.length===0)return!0;const r=e.vertical===null||t.includes(e.vertical),n=e.horizontal===null||t.includes(e.horizontal);return r&&n}const lv=0,cv=e=>e>lv?1:e<-0?-1:0;class Rl extends Ca{constructor(t){super(t),this.state={lastPosition:null},this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,this.threshold=void 0,this.handleElementEnterBound=void 0,this.handleElementLeaveBound=void 0,this.handleElementEnterBound=this.handleElementEnter.bind(this),this.handleElementLeaveBound=this.handleElementLeave.bind(this),this.threshold=t.threshold||0}clone(t){return new Rl(Y({name:this.name,preventDefault:this.preventDefault,stopPropagation:this.stopPropagation,threshold:this.threshold,minPointers:this.minPointers,maxPointers:this.maxPointers,requiredKeys:[...this.requiredKeys],pointerMode:[...this.pointerMode],preventIf:[...this.preventIf]},t))}init(t,r,n,a){super.init(t,r,n,a),this.element.addEventListener("pointerenter",this.handleElementEnterBound),this.element.addEventListener("pointerleave",this.handleElementLeaveBound)}destroy(){this.element.removeEventListener("pointerenter",this.handleElementEnterBound),this.element.removeEventListener("pointerleave",this.handleElementLeaveBound),this.resetState(),super.destroy()}updateOptions(t){super.updateOptions(t)}resetState(){this.isActive=!1,this.state={lastPosition:null}}handleElementEnter(t){if(t.pointerType!=="mouse"&&t.pointerType!=="pen")return;const r=this.pointerManager.getPointers()||new Map,n=Array.from(r.values());if(n.length>=this.minPointers&&n.length<=this.maxPointers){this.isActive=!0;const a={x:t.clientX,y:t.clientY};this.state.lastPosition=a,this.emitMoveEvent(this.element,"start",n,t),this.emitMoveEvent(this.element,"ongoing",n,t)}}handleElementLeave(t){if(t.pointerType!=="mouse"&&t.pointerType!=="pen"||!this.isActive)return;const r=this.pointerManager.getPointers()||new Map,n=Array.from(r.values());this.emitMoveEvent(this.element,"end",n,t),this.resetState()}handlePointerEvent(t,r){if(r.type!=="pointermove"||r.pointerType!=="mouse"&&r.pointerType!=="pen")return;this.preventDefault&&r.preventDefault(),this.stopPropagation&&r.stopPropagation();const n=Array.from(t.values()),a=this.getTargetElement(r);if(!a||n.length<this.minPointers||n.length>this.maxPointers)return;if(this.shouldPreventGesture(a)){if(!this.isActive)return;this.resetState(),this.emitMoveEvent(a,"end",n,r);return}const o={x:r.clientX,y:r.clientY};this.state.lastPosition=o,this.isActive||(this.isActive=!0,this.emitMoveEvent(a,"start",n,r)),this.emitMoveEvent(a,"ongoing",n,r)}emitMoveEvent(t,r,n,a){const o=this.state.lastPosition||Ft(n),s=this.gesturesRegistry.getActiveGestures(t),i={gestureName:this.name,centroid:o,target:a.target,srcEvent:a,phase:r,pointers:n,timeStamp:a.timeStamp,activeGestures:s,customData:this.customData},l=Sn(this.name,r),c=new CustomEvent(l,{bubbles:!0,cancelable:!0,detail:i});t.dispatchEvent(c)}}class Vl extends Ca{constructor(t){super(t),this.state={startPointers:new Map,startCentroid:null,lastCentroid:null,movementThresholdReached:!1,totalDeltaX:0,totalDeltaY:0,activeDeltaX:0,activeDeltaY:0,lastDirection:{vertical:null,horizontal:null,mainAxis:null},lastDeltas:null},this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,this.threshold=void 0,this.direction=void 0,this.direction=t.direction||["up","down","left","right"],this.threshold=t.threshold||0}clone(t){return new Vl(Y({name:this.name,preventDefault:this.preventDefault,stopPropagation:this.stopPropagation,threshold:this.threshold,minPointers:this.minPointers,maxPointers:this.maxPointers,direction:[...this.direction],requiredKeys:[...this.requiredKeys],pointerMode:[...this.pointerMode],preventIf:[...this.preventIf]},t))}destroy(){this.resetState(),super.destroy()}updateOptions(t){super.updateOptions(t),this.direction=t.direction||this.direction}resetState(){this.isActive=!1,this.state=Y({},this.state,{startPointers:new Map,startCentroid:null,lastCentroid:null,lastDeltas:null,activeDeltaX:0,activeDeltaY:0,movementThresholdReached:!1,lastDirection:{vertical:null,horizontal:null,mainAxis:null}})}handlePointerEvent(t,r){const n=Array.from(t.values());if(r.type==="forceCancel"){this.cancel(r.target,n,r);return}const a=this.getTargetElement(r);if(!a)return;if(this.shouldPreventGesture(a)){this.cancel(a,n,r);return}const o=this.getRelevantPointers(n,a);if(o.length<this.minPointers||o.length>this.maxPointers){this.cancel(a,o,r);return}switch(r.type){case"pointerdown":!this.isActive&&!this.state.startCentroid&&(o.forEach(s=>{this.state.startPointers.set(s.pointerId,s)}),this.originalTarget=a,this.state.startCentroid=Ft(o),this.state.lastCentroid=Y({},this.state.startCentroid));break;case"pointermove":if(this.state.startCentroid&&o.length>=this.minPointers){const s=Ft(o),i=s.x-this.state.startCentroid.x,l=s.y-this.state.startCentroid.y,c=Math.sqrt(i*i+l*l),u=ov(this.state.lastCentroid??this.state.startCentroid,s),d=this.state.lastCentroid?s.x-this.state.lastCentroid.x:0,h=this.state.lastCentroid?s.y-this.state.lastCentroid.y:0;!this.state.movementThresholdReached&&c>=this.threshold&&iv(u,this.direction)?(this.state.movementThresholdReached=!0,this.isActive=!0,this.state.lastDeltas={x:d,y:h},this.state.totalDeltaX+=d,this.state.totalDeltaY+=h,this.state.activeDeltaX+=d,this.state.activeDeltaY+=h,this.emitPanEvent(a,"start",o,r,s),this.emitPanEvent(a,"ongoing",o,r,s)):this.state.movementThresholdReached&&this.isActive&&(this.state.lastDeltas={x:d,y:h},this.state.totalDeltaX+=d,this.state.totalDeltaY+=h,this.state.activeDeltaX+=d,this.state.activeDeltaY+=h,this.emitPanEvent(a,"ongoing",o,r,s)),this.state.lastCentroid=s,this.state.lastDirection=u}break;case"pointerup":case"pointercancel":case"forceCancel":if(this.isActive&&this.state.movementThresholdReached){if(o.filter(s=>s.type!=="pointerup"&&s.type!=="pointercancel").length<this.minPointers){const s=this.state.lastCentroid||this.state.startCentroid;r.type==="pointercancel"&&this.emitPanEvent(a,"cancel",o,r,s),this.emitPanEvent(a,"end",o,r,s),this.resetState()}}else this.resetState();break}}emitPanEvent(t,r,n,a,o){var x,V;if(!this.state.startCentroid)return;const s=((x=this.state.lastDeltas)==null?void 0:x.x)??0,i=((V=this.state.lastDeltas)==null?void 0:V.y)??0,l=this.state.startPointers.values().next().value,c=l?(a.timeStamp-l.timeStamp)/1e3:0,u=c>0?s/c:0,d=c>0?i/c:0,h=Math.sqrt(u*u+d*d),p=this.gesturesRegistry.getActiveGestures(t),f={gestureName:this.name,initialCentroid:this.state.startCentroid,centroid:o,target:a.target,srcEvent:a,phase:r,pointers:n,timeStamp:a.timeStamp,deltaX:s,deltaY:i,direction:this.state.lastDirection,velocityX:u,velocityY:d,velocity:h,totalDeltaX:this.state.totalDeltaX,totalDeltaY:this.state.totalDeltaY,activeDeltaX:this.state.activeDeltaX,activeDeltaY:this.state.activeDeltaY,activeGestures:p,customData:this.customData},m=Sn(this.name,r),b=new CustomEvent(m,{bubbles:!0,cancelable:!0,detail:f});t.dispatchEvent(b),this.preventDefault&&a.preventDefault(),this.stopPropagation&&a.stopPropagation()}cancel(t,r,n){if(this.isActive){const a=t??this.element;this.emitPanEvent(a,"cancel",r,n,this.state.lastCentroid),this.emitPanEvent(a,"end",r,n,this.state.lastCentroid)}this.resetState()}}class _l extends Ca{constructor(t){super(Y({},t,{minPointers:t.minPointers??2})),this.state={startDistance:0,lastDistance:0,lastScale:1,lastTime:0,velocity:0,totalScale:1,deltaScale:0},this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,this.threshold=void 0,this.threshold=t.threshold??0}clone(t){return new _l(Y({name:this.name,preventDefault:this.preventDefault,stopPropagation:this.stopPropagation,threshold:this.threshold,minPointers:this.minPointers,maxPointers:this.maxPointers,requiredKeys:[...this.requiredKeys],pointerMode:[...this.pointerMode],preventIf:[...this.preventIf]},t))}destroy(){this.resetState(),super.destroy()}updateOptions(t){super.updateOptions(t)}resetState(){this.isActive=!1,this.state=Y({},this.state,{startDistance:0,lastDistance:0,lastScale:1,lastTime:0,velocity:0,deltaScale:0})}handlePointerEvent(t,r){const n=Array.from(t.values()),a=this.getTargetElement(r);if(!a)return;if(this.shouldPreventGesture(a)){this.isActive&&(this.emitPinchEvent(a,"cancel",n,r),this.resetState());return}const o=this.getRelevantPointers(n,a);switch(r.type){case"pointerdown":if(o.length>=2&&!this.isActive){const s=ri(o);this.state.startDistance=s,this.state.lastDistance=s,this.state.lastTime=r.timeStamp,this.originalTarget=a}break;case"pointermove":if(this.state.startDistance&&o.length>=this.minPointers){const s=ri(o),i=Math.abs(s-this.state.lastDistance);if(i!==0&&i>=this.threshold){const l=this.state.startDistance?s/this.state.startDistance:1,c=l/this.state.lastScale;this.state.totalScale*=c;const u=(r.timeStamp-this.state.lastTime)/1e3;if(this.state.lastDistance){const h=(s-this.state.lastDistance)/u;this.state.velocity=Number.isNaN(h)?0:h}this.state.lastDistance=s,this.state.deltaScale=l-this.state.lastScale,this.state.lastScale=l,this.state.lastTime=r.timeStamp,this.isActive?this.emitPinchEvent(a,"ongoing",o,r):(this.isActive=!0,this.emitPinchEvent(a,"start",o,r),this.emitPinchEvent(a,"ongoing",o,r))}}break;case"pointerup":case"pointercancel":case"forceCancel":if(this.isActive){const s=o.filter(i=>i.type!=="pointerup"&&i.type!=="pointercancel");if(s.length<this.minPointers)r.type==="pointercancel"&&this.emitPinchEvent(a,"cancel",o,r),this.emitPinchEvent(a,"end",o,r),this.resetState();else if(s.length>=2){const i=ri(s);this.state.startDistance=i/this.state.lastScale}}break}}emitPinchEvent(t,r,n,a){const o=Ft(n),s=this.state.lastDistance,i=this.state.lastScale,l=this.gesturesRegistry.getActiveGestures(t),c={gestureName:this.name,centroid:o,target:a.target,srcEvent:a,phase:r,pointers:n,timeStamp:a.timeStamp,scale:i,deltaScale:this.state.deltaScale,totalScale:this.state.totalScale,distance:s,velocity:this.state.velocity,activeGestures:l,direction:cv(this.state.velocity),customData:this.customData};this.preventDefault&&a.preventDefault(),this.stopPropagation&&a.stopPropagation();const u=Sn(this.name,r),d=new CustomEvent(u,{bubbles:!0,cancelable:!0,detail:c});t.dispatchEvent(d)}}class El extends Ca{constructor(t){super(t),this.state={startCentroid:null,lastPosition:null,timerId:null,startTime:0,pressThresholdReached:!1},this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,this.duration=void 0,this.maxDistance=void 0,this.duration=t.duration??500,this.maxDistance=t.maxDistance??10}clone(t){return new El(Y({name:this.name,preventDefault:this.preventDefault,stopPropagation:this.stopPropagation,minPointers:this.minPointers,maxPointers:this.maxPointers,duration:this.duration,maxDistance:this.maxDistance,requiredKeys:[...this.requiredKeys],pointerMode:[...this.pointerMode],preventIf:[...this.preventIf]},t))}destroy(){this.clearPressTimer(),this.resetState(),super.destroy()}updateOptions(t){super.updateOptions(t),this.duration=t.duration??this.duration,this.maxDistance=t.maxDistance??this.maxDistance}resetState(){this.clearPressTimer(),this.isActive=!1,this.state=Y({},this.state,{startCentroid:null,lastPosition:null,timerId:null,startTime:0,pressThresholdReached:!1})}clearPressTimer(){this.state.timerId!==null&&(clearTimeout(this.state.timerId),this.state.timerId=null)}handlePointerEvent(t,r){const n=Array.from(t.values());if(r.type==="forceCancel"){this.cancelPress(r.target,n,r);return}const a=this.getTargetElement(r);if(!a)return;if(this.shouldPreventGesture(a)){this.isActive&&this.cancelPress(a,n,r);return}const o=this.getRelevantPointers(n,a);if(o.length<this.minPointers||o.length>this.maxPointers){this.isActive&&this.cancelPress(a,o,r);return}switch(r.type){case"pointerdown":!this.isActive&&!this.state.startCentroid&&(this.state.startCentroid=Ft(o),this.state.lastPosition=Y({},this.state.startCentroid),this.state.startTime=r.timeStamp,this.isActive=!0,this.originalTarget=a,this.clearPressTimer(),this.state.timerId=setTimeout(()=>{if(this.isActive&&this.state.startCentroid){this.state.pressThresholdReached=!0;const s=this.state.lastPosition;this.emitPressEvent(a,"start",o,r,s),this.emitPressEvent(a,"ongoing",o,r,s)}},this.duration));break;case"pointermove":if(this.isActive&&this.state.startCentroid){const s=Ft(o);this.state.lastPosition=s;const i=s.x-this.state.startCentroid.x,l=s.y-this.state.startCentroid.y;Math.sqrt(i*i+l*l)>this.maxDistance&&this.cancelPress(a,o,r)}break;case"pointerup":if(this.isActive){if(this.state.pressThresholdReached){const s=this.state.lastPosition||this.state.startCentroid;this.emitPressEvent(a,"end",o,r,s)}this.resetState()}break;case"pointercancel":case"forceCancel":this.cancelPress(a,o,r);break}}emitPressEvent(t,r,n,a,o){const s=this.gesturesRegistry.getActiveGestures(t),i=a.timeStamp-this.state.startTime,l={gestureName:this.name,centroid:o,target:a.target,srcEvent:a,phase:r,pointers:n,timeStamp:a.timeStamp,x:o.x,y:o.y,duration:i,activeGestures:s,customData:this.customData},c=Sn(this.name,r),u=new CustomEvent(c,{bubbles:!0,cancelable:!0,detail:l});t.dispatchEvent(u),this.preventDefault&&a.preventDefault(),this.stopPropagation&&a.stopPropagation()}cancelPress(t,r,n){if(this.isActive&&this.state.pressThresholdReached){const a=this.state.lastPosition||this.state.startCentroid;this.emitPressEvent(t??this.element,"cancel",r,n,a),this.emitPressEvent(t??this.element,"end",r,n,a)}this.resetState()}}class Il extends Ca{constructor(t){super(t),this.state={startCentroid:null,currentTapCount:0,lastTapTime:0,lastPosition:null},this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,this.maxDistance=void 0,this.taps=void 0,this.maxDistance=t.maxDistance??10,this.taps=t.taps??1}clone(t){return new Il(Y({name:this.name,preventDefault:this.preventDefault,stopPropagation:this.stopPropagation,minPointers:this.minPointers,maxPointers:this.maxPointers,maxDistance:this.maxDistance,taps:this.taps,requiredKeys:[...this.requiredKeys],pointerMode:[...this.pointerMode],preventIf:[...this.preventIf]},t))}destroy(){this.resetState(),super.destroy()}updateOptions(t){super.updateOptions(t),this.maxDistance=t.maxDistance??this.maxDistance,this.taps=t.taps??this.taps}resetState(){this.isActive=!1,this.state={startCentroid:null,currentTapCount:0,lastTapTime:0,lastPosition:null}}handlePointerEvent(t,r){const n=Array.from(t.values()),a=this.getTargetElement(r);if(!a)return;const o=this.getRelevantPointers(n,a);if(this.shouldPreventGesture(a)||o.length<this.minPointers||o.length>this.maxPointers){this.isActive&&this.cancelTap(a,o,r);return}switch(r.type){case"pointerdown":this.isActive||(this.state.startCentroid=Ft(o),this.state.lastPosition=Y({},this.state.startCentroid),this.isActive=!0,this.originalTarget=a);break;case"pointermove":if(this.isActive&&this.state.startCentroid){const s=Ft(o);this.state.lastPosition=s;const i=s.x-this.state.startCentroid.x,l=s.y-this.state.startCentroid.y;Math.sqrt(i*i+l*l)>this.maxDistance&&this.cancelTap(a,o,r)}break;case"pointerup":if(this.isActive){this.state.currentTapCount+=1;const s=this.state.lastPosition||this.state.startCentroid;if(!s){this.cancelTap(a,o,r);return}this.state.currentTapCount>=this.taps?(this.fireTapEvent(a,o,r,s),this.resetState()):(this.state.lastTapTime=r.timeStamp,this.isActive=!1,this.state.startCentroid=null,setTimeout(()=>{this.state&&this.state.currentTapCount>0&&this.state.currentTapCount<this.taps&&(this.state.currentTapCount=0)},300))}break;case"pointercancel":case"forceCancel":this.cancelTap(a,o,r);break}}fireTapEvent(t,r,n,a){const o=this.gesturesRegistry.getActiveGestures(t),s={gestureName:this.name,centroid:a,target:n.target,srcEvent:n,phase:"end",pointers:r,timeStamp:n.timeStamp,x:a.x,y:a.y,tapCount:this.state.currentTapCount,activeGestures:o,customData:this.customData},i=new CustomEvent(this.name,{bubbles:!0,cancelable:!0,detail:s});t.dispatchEvent(i),this.preventDefault&&n.preventDefault(),this.stopPropagation&&n.stopPropagation()}cancelTap(t,r,n){if(this.state.startCentroid||this.state.lastPosition){const a=this.state.lastPosition||this.state.startCentroid,o=this.gesturesRegistry.getActiveGestures(t),s={gestureName:this.name,centroid:a,target:n.target,srcEvent:n,phase:"cancel",pointers:r,timeStamp:n.timeStamp,x:a.x,y:a.y,tapCount:this.state.currentTapCount,activeGestures:o,customData:this.customData},i=Sn(this.name,"cancel"),l=new CustomEvent(i,{bubbles:!0,cancelable:!0,detail:s});t.dispatchEvent(l)}this.resetState()}}class Ml extends up{constructor(t){super(t),this.state={totalDeltaX:0,totalDeltaY:0,totalDeltaZ:0},this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,this.sensitivity=void 0,this.max=void 0,this.min=void 0,this.initialDelta=void 0,this.invert=void 0,this.handleWheelEventBound=void 0,this.sensitivity=t.sensitivity??1,this.max=t.max??Number.MAX_SAFE_INTEGER,this.min=t.min??Number.MIN_SAFE_INTEGER,this.initialDelta=t.initialDelta??0,this.invert=t.invert??!1,this.state.totalDeltaX=this.initialDelta,this.state.totalDeltaY=this.initialDelta,this.state.totalDeltaZ=this.initialDelta,this.handleWheelEventBound=this.handleWheelEvent.bind(this)}clone(t){return new Ml(Y({name:this.name,preventDefault:this.preventDefault,stopPropagation:this.stopPropagation,sensitivity:this.sensitivity,max:this.max,min:this.min,initialDelta:this.initialDelta,invert:this.invert,requiredKeys:[...this.requiredKeys],pointerMode:[...this.pointerMode],preventIf:[...this.preventIf]},t))}init(t,r,n,a){super.init(t,r,n,a),this.element.addEventListener("wheel",this.handleWheelEventBound)}destroy(){this.element.removeEventListener("wheel",this.handleWheelEventBound),this.resetState(),super.destroy()}resetState(){this.isActive=!1,this.state={totalDeltaX:0,totalDeltaY:0,totalDeltaZ:0}}updateOptions(t){super.updateOptions(t),this.sensitivity=t.sensitivity??this.sensitivity,this.max=t.max??this.max,this.min=t.min??this.min,this.initialDelta=t.initialDelta??this.initialDelta,this.invert=t.invert??this.invert}handleWheelEvent(t){if(this.shouldPreventGesture(this.element))return;const r=this.pointerManager.getPointers()||new Map,n=Array.from(r.values());this.state.totalDeltaX+=t.deltaX*this.sensitivity*(this.invert?-1:1),this.state.totalDeltaY+=t.deltaY*this.sensitivity*(this.invert?-1:1),this.state.totalDeltaZ+=t.deltaZ*this.sensitivity*(this.invert?-1:1),["totalDeltaX","totalDeltaY","totalDeltaZ"].forEach(a=>{this.state[a]<this.min&&(this.state[a]=this.min),this.state[a]>this.max&&(this.state[a]=this.max)}),this.emitWheelEvent(n,t)}emitWheelEvent(t,r){const n=t.length>0?Ft(t):{x:r.clientX,y:r.clientY},a=this.gesturesRegistry.getActiveGestures(this.element),o={gestureName:this.name,centroid:n,target:r.target,srcEvent:r,phase:"ongoing",pointers:t,timeStamp:r.timeStamp,deltaX:r.deltaX*this.sensitivity*(this.invert?-1:1),deltaY:r.deltaY*this.sensitivity*(this.invert?-1:1),deltaZ:r.deltaZ*this.sensitivity*(this.invert?-1:1),deltaMode:r.deltaMode,totalDeltaX:this.state.totalDeltaX,totalDeltaY:this.state.totalDeltaY,totalDeltaZ:this.state.totalDeltaZ,activeGestures:a,customData:this.customData};this.preventDefault&&r.preventDefault(),this.stopPropagation&&r.stopPropagation();const s=Sn(this.name,"ongoing"),i=new CustomEvent(s,{bubbles:!0,cancelable:!0,detail:o});this.element.dispatchEvent(i)}}const zr=e=>e.preventDefault(),$l=({svgRef:e})=>{B.useEffect(()=>{const r=e.current;if(!r)return;const n=new nv({gestures:[new Vl({name:"pan",threshold:0,maxPointers:1}),new Rl({name:"move",preventIf:["pan","pinch"]}),new _l({name:"pinch",threshold:5,preventIf:["pan"]}),new Ml({name:"turnWheel",sensitivity:.01,initialDelta:1}),new Il({name:"tap",maxDistance:10,preventIf:["pan","pinch"]}),new El({name:"quickPress",duration:50,maxDistance:10})]});return n.registerElement(["pan","move","pinch","turnWheel","tap","quickPress"],r),()=>{n.destroy()}},[e]);const t=B.useCallback((r,n,a)=>{const o=e.current;return o==null||o.addEventListener(r,n,a),{cleanup:()=>o==null?void 0:o.removeEventListener(r,n)}},[e]);return B.useEffect(()=>{const r=e.current;return r==null||r.addEventListener("gesturestart",zr),r==null||r.addEventListener("gesturechange",zr),r==null||r.addEventListener("gestureend",zr),()=>{r==null||r.removeEventListener("gesturestart",zr),r==null||r.removeEventListener("gesturechange",zr),r==null||r.removeEventListener("gestureend",zr)}},[e]),{instance:{addInteractionListener:t}}};$l.params={};$l.getInitialState=()=>({});const uv=[Al,Tl,ls,cs,$l,is],dv=["apiRef"],hv=e=>{let{plugins:t}=e,r=ar(e.props,dv);const n={};t.forEach(s=>{Object.assign(n,s.params)});const a={};return Object.keys(r).forEach(s=>{const i=r[s];n[s]&&(a[s]=i)}),t.reduce((s,i)=>i.getDefaultizedParams?i.getDefaultizedParams({params:s}):s,a)};let lu=0;function pv(e,t,r){const n=Q0(),a=B.useMemo(()=>[...uv,...e],[e]),o=hv({plugins:a,props:t});o.id=o.id??n;const i=B.useRef({}).current,l=fv(t.apiRef),c=B.useRef(null),u=B.useRef(null),d=B.useRef(null);if(d.current==null){lu+=1;const f={cacheKey:{id:lu}};a.forEach(m=>{m.getInitialState&&Object.assign(f,m.getInitialState(o,f,r))}),d.current=new X0(f)}const h=f=>{const m=f({instance:i,params:o,plugins:a,store:d.current,svgRef:u,chartRootRef:c,seriesConfig:r});m.publicAPI&&Object.assign(l.current,m.publicAPI),m.instance&&Object.assign(i,m.instance)};return a.forEach(h),{contextValue:B.useMemo(()=>({store:d.current,publicAPI:l.current,instance:i,svgRef:u,chartRootRef:c}),[i,l])}}function mv(e){return e.current==null&&(e.current={}),e}function fv(e){const t=B.useRef({});return e?mv(e):t}const jl=B.createContext(null);process.env.NODE_ENV!=="production"&&(jl.displayName="ChartContext");const cu=new Set;function sa(e,t="warning"){if(process.env.NODE_ENV==="production")return;const r=Array.isArray(e)?e.join(`
|
|
115
|
-
`):e;cu.has(r)||(cu.add(r),t==="error"?console.error(r):console.warn(r))}function gv(e){const{componentName:t,propName:r,controlled:n,defaultValue:a,warningPrefix:o="MUI X"}=e,[{initialDefaultValue:s,isControlled:i}]=B.useState({initialDefaultValue:a,isControlled:n!==void 0});i!==(n!==void 0)&&sa([`${o}: A component is changing the ${i?"":"un"}controlled ${r} state of ${t} to be ${i?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${r} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"],"error"),JSON.stringify(s)!==JSON.stringify(a)&&sa([`${o}: A component is changing the default ${r} state of an uncontrolled ${t} after being initialized. To suppress this warning opt to use a controlled ${t}.`],"error")}const dp=process.env.NODE_ENV==="production"?()=>{}:gv,hp=4,pp=20+2*hp,yv=40+2*hp,bv="hover",Ha={minStart:0,maxEnd:100,step:5,minSpan:10,maxSpan:100,panning:!0,filterMode:"keep",slider:{enabled:!1,preview:!1,size:pp,showTooltip:bv}},kl=(e,t,r)=>{var n;if(e)return e===!0?Y({axisId:t,axisDirection:r},Ha):Y({axisId:t,axisDirection:r},Ha,e,{slider:Y({},Ha.slider,{size:((n=e.slider)==null?void 0:n.preview)??Ha.slider.preview?yv:pp},e.slider)})};function mp(e,t){const r={top:0,bottom:0,none:0};return(e&&e.length>0?e:[{id:Vb,scaleType:"linear"}]).map((o,s)=>{var p;const i=o.dataKey,l=s===0?"bottom":"none",c=o.position??l,u=Mb+(o.label?rp:0),d=o.id??`defaultized-x-axis-${s}`,h=Y({offset:r[c]},o,{id:d,position:c,height:o.height??u,zoom:kl(o.zoom,d,"x")});if(c!=="none"&&(r[c]+=h.height,(p=h.zoom)!=null&&p.slider.enabled&&(r[c]+=h.zoom.slider.size)),i===void 0||o.data!==void 0)return h;if(t===void 0)throw new Error("MUI X Charts: x-axis uses `dataKey` but no `dataset` is provided.");return Y({},h,{data:t.map(f=>f[i])})})}function fp(e,t){const r={right:0,left:0,none:0};return(e&&e.length>0?e:[{id:_b,scaleType:"linear"}]).map((o,s)=>{var p;const i=o.dataKey,l=s===0?"left":"none",c=o.position??l,u=Ib+(o.label?rp:0),d=o.id??`defaultized-y-axis-${s}`,h=Y({offset:r[c]},o,{id:d,position:c,width:o.width??u,zoom:kl(o.zoom,d,"y")});if(c!=="none"&&(r[c]+=h.width,(p=h.zoom)!=null&&p.slider.enabled&&(r[c]+=h.zoom.slider.size)),i===void 0||o.data!==void 0)return h;if(t===void 0)throw new Error("MUI X Charts: y-axis uses `dataKey` but no `dataset` is provided.");return Y({},h,{data:t.map(f=>f[i])})})}function po(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function vv(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Ul(e){let t,r,n;e.length!==2?(t=po,r=(i,l)=>po(e(i),l),n=(i,l)=>e(i)-l):(t=e===po||e===vv?e:Sv,r=e,n=e);function a(i,l,c=0,u=i.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;r(i[d],l)<0?c=d+1:u=d}while(c<u)}return c}function o(i,l,c=0,u=i.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;r(i[d],l)<=0?c=d+1:u=d}while(c<u)}return c}function s(i,l,c=0,u=i.length){const d=a(i,l,c,u-1);return d>c&&n(i[d-1],l)>-n(i[d],l)?d-1:d}return{left:a,center:s,right:o}}function Sv(){return 0}function xv(e){return e===null?NaN:+e}const Ov=Ul(po),gp=Ov.right;Ul(xv).center;class uu extends Map{constructor(t,r=Pv){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),t!=null)for(const[n,a]of t)this.set(n,a)}get(t){return super.get(du(this,t))}has(t){return super.has(du(this,t))}set(t,r){return super.set(wv(this,t),r)}delete(t){return super.delete(Cv(this,t))}}function du({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):r}function wv({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):(e.set(n,r),r)}function Cv({_intern:e,_key:t},r){const n=t(r);return e.has(n)&&(r=e.get(n),e.delete(n)),r}function Pv(e){return e!==null&&typeof e=="object"?e.valueOf():e}const Tv=Math.sqrt(50),Av=Math.sqrt(10),Rv=Math.sqrt(2);function Ao(e,t,r){const n=(t-e)/Math.max(0,r),a=Math.floor(Math.log10(n)),o=n/Math.pow(10,a),s=o>=Tv?10:o>=Av?5:o>=Rv?2:1;let i,l,c;return a<0?(c=Math.pow(10,-a)/s,i=Math.round(e*c),l=Math.round(t*c),i/c<e&&++i,l/c>t&&--l,c=-c):(c=Math.pow(10,a)*s,i=Math.round(e/c),l=Math.round(t/c),i*c<e&&++i,l*c>t&&--l),l<i&&.5<=r&&r<2?Ao(e,t,r*2):[i,l,c]}function Di(e,t,r){if(t=+t,e=+e,r=+r,!(r>0))return[];if(e===t)return[e];const n=t<e,[a,o,s]=n?Ao(t,e,r):Ao(e,t,r);if(!(o>=a))return[];const i=o-a+1,l=new Array(i);if(n)if(s<0)for(let c=0;c<i;++c)l[c]=(o-c)/-s;else for(let c=0;c<i;++c)l[c]=(o-c)*s;else if(s<0)for(let c=0;c<i;++c)l[c]=(a+c)/-s;else for(let c=0;c<i;++c)l[c]=(a+c)*s;return l}function Bi(e,t,r){return t=+t,e=+e,r=+r,Ao(e,t,r)[2]}function Ni(e,t,r){t=+t,e=+e,r=+r;const n=t<e,a=n?Bi(t,e,r):Bi(e,t,r);return(n?-1:1)*(a<0?1/-a:a)}function Vv(e,t,r){e=+e,t=+t,r=(a=arguments.length)<2?(t=e,e=0,1):a<3?1:+r;for(var n=-1,a=Math.max(0,Math.ceil((t-e)/r))|0,o=new Array(a);++n<a;)o[n]=e+n*r;return o}function cr(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function _v(e,t){switch(arguments.length){case 0:break;case 1:{typeof e=="function"?this.interpolator(e):this.range(e);break}default:{this.domain(e),typeof t=="function"?this.interpolator(t):this.range(t);break}}return this}const hu=Symbol("implicit");function Ro(){var e=new uu,t=[],r=[],n=hu;function a(o){let s=e.get(o);if(s===void 0){if(n!==hu)return n;e.set(o,s=t.push(o)-1)}return r[s%r.length]}return a.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new uu;for(const s of o)e.has(s)||e.set(s,t.push(s)-1);return a},a.range=function(o){return arguments.length?(r=Array.from(o),a):r.slice()},a.unknown=function(o){return arguments.length?(n=o,a):n},a.copy=function(){return Ro(t,r).unknown(n)},cr.apply(a,arguments),a}function Ll(){var e=Ro().unknown(void 0),t=e.domain,r=e.range,n=0,a=1,o,s,i=!1,l=0,c=0,u=.5;delete e.unknown;function d(){var h=t().length,p=a<n,f=p?a:n,m=p?n:a;o=(m-f)/Math.max(1,h-l+c*2),i&&(o=Math.floor(o)),f+=(m-f-o*(h-l))*u,s=o*(1-l),i&&(f=Math.round(f),s=Math.round(s));var b=Vv(h).map(function(x){return f+o*x});return r(p?b.reverse():b)}return e.domain=function(h){return arguments.length?(t(h),d()):t()},e.range=function(h){return arguments.length?([n,a]=h,n=+n,a=+a,d()):[n,a]},e.rangeRound=function(h){return[n,a]=h,n=+n,a=+a,i=!0,d()},e.bandwidth=function(){return s},e.step=function(){return o},e.round=function(h){return arguments.length?(i=!!h,d()):i},e.padding=function(h){return arguments.length?(l=Math.min(1,c=+h),d()):l},e.paddingInner=function(h){return arguments.length?(l=Math.min(1,h),d()):l},e.paddingOuter=function(h){return arguments.length?(c=+h,d()):c},e.align=function(h){return arguments.length?(u=Math.max(0,Math.min(1,h)),d()):u},e.copy=function(){return Ll(t(),[n,a]).round(i).paddingInner(l).paddingOuter(c).align(u)},cr.apply(d(),arguments)}function yp(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return yp(t())},e}function Ev(){return yp(Ll.apply(null,arguments).paddingInner(1))}function Dl(e,t,r){e.prototype=t.prototype=r,r.constructor=e}function bp(e,t){var r=Object.create(e.prototype);for(var n in t)r[n]=t[n];return r}function Pa(){}var ia=.7,Vo=1/ia,an="\\s*([+-]?\\d+)\\s*",la="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",It="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Iv=/^#([0-9a-f]{3,8})$/,Mv=new RegExp(`^rgb\\(${an},${an},${an}\\)$`),$v=new RegExp(`^rgb\\(${It},${It},${It}\\)$`),jv=new RegExp(`^rgba\\(${an},${an},${an},${la}\\)$`),kv=new RegExp(`^rgba\\(${It},${It},${It},${la}\\)$`),Uv=new RegExp(`^hsl\\(${la},${It},${It}\\)$`),Lv=new RegExp(`^hsla\\(${la},${It},${It},${la}\\)$`),pu={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Dl(Pa,ca,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:mu,formatHex:mu,formatHex8:Dv,formatHsl:Bv,formatRgb:fu,toString:fu});function mu(){return this.rgb().formatHex()}function Dv(){return this.rgb().formatHex8()}function Bv(){return vp(this).formatHsl()}function fu(){return this.rgb().formatRgb()}function ca(e){var t,r;return e=(e+"").trim().toLowerCase(),(t=Iv.exec(e))?(r=t[1].length,t=parseInt(t[1],16),r===6?gu(t):r===3?new ot(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):r===8?qa(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?qa(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=Mv.exec(e))?new ot(t[1],t[2],t[3],1):(t=$v.exec(e))?new ot(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=jv.exec(e))?qa(t[1],t[2],t[3],t[4]):(t=kv.exec(e))?qa(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=Uv.exec(e))?vu(t[1],t[2]/100,t[3]/100,1):(t=Lv.exec(e))?vu(t[1],t[2]/100,t[3]/100,t[4]):pu.hasOwnProperty(e)?gu(pu[e]):e==="transparent"?new ot(NaN,NaN,NaN,0):null}function gu(e){return new ot(e>>16&255,e>>8&255,e&255,1)}function qa(e,t,r,n){return n<=0&&(e=t=r=NaN),new ot(e,t,r,n)}function Nv(e){return e instanceof Pa||(e=ca(e)),e?(e=e.rgb(),new ot(e.r,e.g,e.b,e.opacity)):new ot}function Fi(e,t,r,n){return arguments.length===1?Nv(e):new ot(e,t,r,n??1)}function ot(e,t,r,n){this.r=+e,this.g=+t,this.b=+r,this.opacity=+n}Dl(ot,Fi,bp(Pa,{brighter(e){return e=e==null?Vo:Math.pow(Vo,e),new ot(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?ia:Math.pow(ia,e),new ot(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new ot(vr(this.r),vr(this.g),vr(this.b),_o(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:yu,formatHex:yu,formatHex8:Fv,formatRgb:bu,toString:bu}));function yu(){return`#${fr(this.r)}${fr(this.g)}${fr(this.b)}`}function Fv(){return`#${fr(this.r)}${fr(this.g)}${fr(this.b)}${fr((isNaN(this.opacity)?1:this.opacity)*255)}`}function bu(){const e=_o(this.opacity);return`${e===1?"rgb(":"rgba("}${vr(this.r)}, ${vr(this.g)}, ${vr(this.b)}${e===1?")":`, ${e})`}`}function _o(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function vr(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function fr(e){return e=vr(e),(e<16?"0":"")+e.toString(16)}function vu(e,t,r,n){return n<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new xt(e,t,r,n)}function vp(e){if(e instanceof xt)return new xt(e.h,e.s,e.l,e.opacity);if(e instanceof Pa||(e=ca(e)),!e)return new xt;if(e instanceof xt)return e;e=e.rgb();var t=e.r/255,r=e.g/255,n=e.b/255,a=Math.min(t,r,n),o=Math.max(t,r,n),s=NaN,i=o-a,l=(o+a)/2;return i?(t===o?s=(r-n)/i+(r<n)*6:r===o?s=(n-t)/i+2:s=(t-r)/i+4,i/=l<.5?o+a:2-o-a,s*=60):i=l>0&&l<1?0:s,new xt(s,i,l,e.opacity)}function zv(e,t,r,n){return arguments.length===1?vp(e):new xt(e,t,r,n??1)}function xt(e,t,r,n){this.h=+e,this.s=+t,this.l=+r,this.opacity=+n}Dl(xt,zv,bp(Pa,{brighter(e){return e=e==null?Vo:Math.pow(Vo,e),new xt(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?ia:Math.pow(ia,e),new xt(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*t,a=2*r-n;return new ot(ni(e>=240?e-240:e+120,a,n),ni(e,a,n),ni(e<120?e+240:e-120,a,n),this.opacity)},clamp(){return new xt(Su(this.h),Ja(this.s),Ja(this.l),_o(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=_o(this.opacity);return`${e===1?"hsl(":"hsla("}${Su(this.h)}, ${Ja(this.s)*100}%, ${Ja(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Su(e){return e=(e||0)%360,e<0?e+360:e}function Ja(e){return Math.max(0,Math.min(1,e||0))}function ni(e,t,r){return(e<60?t+(r-t)*e/60:e<180?r:e<240?t+(r-t)*(240-e)/60:t)*255}const Bl=e=>()=>e;function Gv(e,t){return function(r){return e+r*t}}function Hv(e,t,r){return e=Math.pow(e,r),t=Math.pow(t,r)-e,r=1/r,function(n){return Math.pow(e+n*t,r)}}function qv(e){return(e=+e)==1?Sp:function(t,r){return r-t?Hv(t,r,e):Bl(isNaN(t)?r:t)}}function Sp(e,t){var r=t-e;return r?Gv(e,r):Bl(isNaN(e)?t:e)}const xu=function e(t){var r=qv(t);function n(a,o){var s=r((a=Fi(a)).r,(o=Fi(o)).r),i=r(a.g,o.g),l=r(a.b,o.b),c=Sp(a.opacity,o.opacity);return function(u){return a.r=s(u),a.g=i(u),a.b=l(u),a.opacity=c(u),a+""}}return n.gamma=e,n}(1);function Jv(e,t){t||(t=[]);var r=e?Math.min(t.length,e.length):0,n=t.slice(),a;return function(o){for(a=0;a<r;++a)n[a]=e[a]*(1-o)+t[a]*o;return n}}function Wv(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function Yv(e,t){var r=t?t.length:0,n=e?Math.min(r,e.length):0,a=new Array(n),o=new Array(r),s;for(s=0;s<n;++s)a[s]=ds(e[s],t[s]);for(;s<r;++s)o[s]=t[s];return function(i){for(s=0;s<n;++s)o[s]=a[s](i);return o}}function Nl(e,t){var r=new Date;return e=+e,t=+t,function(n){return r.setTime(e*(1-n)+t*n),r}}function Ot(e,t){return e=+e,t=+t,function(r){return e*(1-r)+t*r}}function Kv(e,t){var r={},n={},a;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(a in t)a in e?r[a]=ds(e[a],t[a]):n[a]=t[a];return function(o){for(a in r)n[a]=r[a](o);return n}}var zi=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,ai=new RegExp(zi.source,"g");function Qv(e){return function(){return e}}function Xv(e){return function(t){return e(t)+""}}function Zv(e,t){var r=zi.lastIndex=ai.lastIndex=0,n,a,o,s=-1,i=[],l=[];for(e=e+"",t=t+"";(n=zi.exec(e))&&(a=ai.exec(t));)(o=a.index)>r&&(o=t.slice(r,o),i[s]?i[s]+=o:i[++s]=o),(n=n[0])===(a=a[0])?i[s]?i[s]+=a:i[++s]=a:(i[++s]=null,l.push({i:s,x:Ot(n,a)})),r=ai.lastIndex;return r<t.length&&(o=t.slice(r),i[s]?i[s]+=o:i[++s]=o),i.length<2?l[0]?Xv(l[0].x):Qv(t):(t=l.length,function(c){for(var u=0,d;u<t;++u)i[(d=l[u]).i]=d.x(c);return i.join("")})}function ds(e,t){var r=typeof t,n;return t==null||r==="boolean"?Bl(t):(r==="number"?Ot:r==="string"?(n=ca(t))?(t=n,xu):Zv:t instanceof ca?xu:t instanceof Date?Nl:Wv(t)?Jv:Array.isArray(t)?Yv:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?Kv:Ot)(e,t)}function xp(e,t){return e=+e,t=+t,function(r){return Math.round(e*(1-r)+t*r)}}function e1(e){return function(){return e}}function t1(e){return+e}var Ou=[0,1];function mt(e){return e}function Gi(e,t){return(t-=e=+e)?function(r){return(r-e)/t}:e1(isNaN(t)?NaN:.5)}function r1(e,t){var r;return e>t&&(r=e,e=t,t=r),function(n){return Math.max(e,Math.min(t,n))}}function n1(e,t,r){var n=e[0],a=e[1],o=t[0],s=t[1];return a<n?(n=Gi(a,n),o=r(s,o)):(n=Gi(n,a),o=r(o,s)),function(i){return o(n(i))}}function a1(e,t,r){var n=Math.min(e.length,t.length)-1,a=new Array(n),o=new Array(n),s=-1;for(e[n]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++s<n;)a[s]=Gi(e[s],e[s+1]),o[s]=r(t[s],t[s+1]);return function(i){var l=gp(e,i,1,n)-1;return o[l](a[l](i))}}function hs(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Fl(){var e=Ou,t=Ou,r=ds,n,a,o,s=mt,i,l,c;function u(){var h=Math.min(e.length,t.length);return s!==mt&&(s=r1(e[0],e[h-1])),i=h>2?a1:n1,l=c=null,d}function d(h){return h==null||isNaN(h=+h)?o:(l||(l=i(e.map(n),t,r)))(n(s(h)))}return d.invert=function(h){return s(a((c||(c=i(t,e.map(n),Ot)))(h)))},d.domain=function(h){return arguments.length?(e=Array.from(h,t1),u()):e.slice()},d.range=function(h){return arguments.length?(t=Array.from(h),u()):t.slice()},d.rangeRound=function(h){return t=Array.from(h),r=xp,u()},d.clamp=function(h){return arguments.length?(s=h?!0:mt,u()):s!==mt},d.interpolate=function(h){return arguments.length?(r=h,u()):r},d.unknown=function(h){return arguments.length?(o=h,d):o},function(h,p){return n=h,a=p,u()}}function Op(){return Fl()(mt,mt)}function o1(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Eo(e,t){if((r=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var r,n=e.slice(0,r);return[n.length>1?n[0]+n.slice(2):n,+e.slice(r+1)]}function un(e){return e=Eo(Math.abs(e)),e?e[1]:NaN}function s1(e,t){return function(r,n){for(var a=r.length,o=[],s=0,i=e[0],l=0;a>0&&i>0&&(l+i+1>n&&(i=Math.max(1,n-l)),o.push(r.substring(a-=i,a+i)),!((l+=i+1)>n));)i=e[s=(s+1)%e.length];return o.reverse().join(t)}}function i1(e){return function(t){return t.replace(/[0-9]/g,function(r){return e[+r]})}}var l1=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ua(e){if(!(t=l1.exec(e)))throw new Error("invalid format: "+e);var t;return new zl({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}ua.prototype=zl.prototype;function zl(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}zl.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function c1(e){e:for(var t=e.length,r=1,n=-1,a;r<t;++r)switch(e[r]){case".":n=a=r;break;case"0":n===0&&(n=r),a=r;break;default:if(!+e[r])break e;n>0&&(n=0);break}return n>0?e.slice(0,n)+e.slice(a+1):e}var wp;function u1(e,t){var r=Eo(e,t);if(!r)return e+"";var n=r[0],a=r[1],o=a-(wp=Math.max(-8,Math.min(8,Math.floor(a/3)))*3)+1,s=n.length;return o===s?n:o>s?n+new Array(o-s+1).join("0"):o>0?n.slice(0,o)+"."+n.slice(o):"0."+new Array(1-o).join("0")+Eo(e,Math.max(0,t+o-1))[0]}function wu(e,t){var r=Eo(e,t);if(!r)return e+"";var n=r[0],a=r[1];return a<0?"0."+new Array(-a).join("0")+n:n.length>a+1?n.slice(0,a+1)+"."+n.slice(a+1):n+new Array(a-n.length+2).join("0")}const Cu={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:o1,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>wu(e*100,t),r:wu,s:u1,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function Pu(e){return e}var Tu=Array.prototype.map,Au=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function d1(e){var t=e.grouping===void 0||e.thousands===void 0?Pu:s1(Tu.call(e.grouping,Number),e.thousands+""),r=e.currency===void 0?"":e.currency[0]+"",n=e.currency===void 0?"":e.currency[1]+"",a=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?Pu:i1(Tu.call(e.numerals,String)),s=e.percent===void 0?"%":e.percent+"",i=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function c(d){d=ua(d);var h=d.fill,p=d.align,f=d.sign,m=d.symbol,b=d.zero,x=d.width,V=d.comma,O=d.precision,C=d.trim,P=d.type;P==="n"?(V=!0,P="g"):Cu[P]||(O===void 0&&(O=12),C=!0,P="g"),(b||h==="0"&&p==="=")&&(b=!0,h="0",p="=");var w=m==="$"?r:m==="#"&&/[boxX]/.test(P)?"0"+P.toLowerCase():"",A=m==="$"?n:/[%p]/.test(P)?s:"",E=Cu[P],F=/[defgprs%]/.test(P);O=O===void 0?6:/[gprs]/.test(P)?Math.max(1,Math.min(21,O)):Math.max(0,Math.min(20,O));function y(T){var z=w,_=A,N,te,Z;if(P==="c")_=E(T)+_,T="";else{T=+T;var ae=T<0||1/T<0;if(T=isNaN(T)?l:E(Math.abs(T),O),C&&(T=c1(T)),ae&&+T==0&&f!=="+"&&(ae=!1),z=(ae?f==="("?f:i:f==="-"||f==="("?"":f)+z,_=(P==="s"?Au[8+wp/3]:"")+_+(ae&&f==="("?")":""),F){for(N=-1,te=T.length;++N<te;)if(Z=T.charCodeAt(N),48>Z||Z>57){_=(Z===46?a+T.slice(N+1):T.slice(N))+_,T=T.slice(0,N);break}}}V&&!b&&(T=t(T,1/0));var re=z.length+T.length+_.length,le=re<x?new Array(x-re+1).join(h):"";switch(V&&b&&(T=t(le+T,le.length?x-_.length:1/0),le=""),p){case"<":T=z+T+_+le;break;case"=":T=z+le+T+_;break;case"^":T=le.slice(0,re=le.length>>1)+z+T+_+le.slice(re);break;default:T=le+z+T+_;break}return o(T)}return y.toString=function(){return d+""},y}function u(d,h){var p=c((d=ua(d),d.type="f",d)),f=Math.max(-8,Math.min(8,Math.floor(un(h)/3)))*3,m=Math.pow(10,-f),b=Au[8+f/3];return function(x){return p(m*x)+b}}return{format:c,formatPrefix:u}}var Wa,Gl,Cp;h1({thousands:",",grouping:[3],currency:["$",""]});function h1(e){return Wa=d1(e),Gl=Wa.format,Cp=Wa.formatPrefix,Wa}function p1(e){return Math.max(0,-un(Math.abs(e)))}function m1(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(un(t)/3)))*3-un(Math.abs(e)))}function f1(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,un(t)-un(e))+1}function g1(e,t,r,n){var a=Ni(e,t,r),o;switch(n=ua(n??",f"),n.type){case"s":{var s=Math.max(Math.abs(e),Math.abs(t));return n.precision==null&&!isNaN(o=m1(a,s))&&(n.precision=o),Cp(n,s)}case"":case"e":case"g":case"p":case"r":{n.precision==null&&!isNaN(o=f1(a,Math.max(Math.abs(e),Math.abs(t))))&&(n.precision=o-(n.type==="e"));break}case"f":case"%":{n.precision==null&&!isNaN(o=p1(a))&&(n.precision=o-(n.type==="%")*2);break}}return Gl(n)}function Hl(e){var t=e.domain;return e.ticks=function(r){var n=t();return Di(n[0],n[n.length-1],r??10)},e.tickFormat=function(r,n){var a=t();return g1(a[0],a[a.length-1],r??10,n)},e.nice=function(r){r==null&&(r=10);var n=t(),a=0,o=n.length-1,s=n[a],i=n[o],l,c,u=10;for(i<s&&(c=s,s=i,i=c,c=a,a=o,o=c);u-- >0;){if(c=Bi(s,i,r),c===l)return n[a]=s,n[o]=i,t(n);if(c>0)s=Math.floor(s/c)*c,i=Math.ceil(i/c)*c;else if(c<0)s=Math.ceil(s*c)/c,i=Math.floor(i*c)/c;else break;l=c}return e},e}function Pp(){var e=Op();return e.copy=function(){return hs(e,Pp())},cr.apply(e,arguments),Hl(e)}function Tp(e,t){e=e.slice();var r=0,n=e.length-1,a=e[r],o=e[n],s;return o<a&&(s=r,r=n,n=s,s=a,a=o,o=s),e[r]=t.floor(a),e[n]=t.ceil(o),e}function Ru(e){return Math.log(e)}function Vu(e){return Math.exp(e)}function y1(e){return-Math.log(-e)}function b1(e){return-Math.exp(-e)}function v1(e){return isFinite(e)?+("1e"+e):e<0?0:e}function S1(e){return e===10?v1:e===Math.E?Math.exp:t=>Math.pow(e,t)}function x1(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function _u(e){return(t,r)=>-e(-t,r)}function O1(e){const t=e(Ru,Vu),r=t.domain;let n=10,a,o;function s(){return a=x1(n),o=S1(n),r()[0]<0?(a=_u(a),o=_u(o),e(y1,b1)):e(Ru,Vu),t}return t.base=function(i){return arguments.length?(n=+i,s()):n},t.domain=function(i){return arguments.length?(r(i),s()):r()},t.ticks=i=>{const l=r();let c=l[0],u=l[l.length-1];const d=u<c;d&&([c,u]=[u,c]);let h=a(c),p=a(u),f,m;const b=i==null?10:+i;let x=[];if(!(n%1)&&p-h<b){if(h=Math.floor(h),p=Math.ceil(p),c>0){for(;h<=p;++h)for(f=1;f<n;++f)if(m=h<0?f/o(-h):f*o(h),!(m<c)){if(m>u)break;x.push(m)}}else for(;h<=p;++h)for(f=n-1;f>=1;--f)if(m=h>0?f/o(-h):f*o(h),!(m<c)){if(m>u)break;x.push(m)}x.length*2<b&&(x=Di(c,u,b))}else x=Di(h,p,Math.min(p-h,b)).map(o);return d?x.reverse():x},t.tickFormat=(i,l)=>{if(i==null&&(i=10),l==null&&(l=n===10?"s":","),typeof l!="function"&&(!(n%1)&&(l=ua(l)).precision==null&&(l.trim=!0),l=Gl(l)),i===1/0)return l;const c=Math.max(1,n*i/t.ticks().length);return u=>{let d=u/o(Math.round(a(u)));return d*n<n-.5&&(d*=n),d<=c?l(u):""}},t.nice=()=>r(Tp(r(),{floor:i=>o(Math.floor(a(i))),ceil:i=>o(Math.ceil(a(i)))})),t}function Ap(){const e=O1(Fl()).domain([1,10]);return e.copy=()=>hs(e,Ap()).base(e.base()),cr.apply(e,arguments),e}function Eu(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function w1(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function C1(e){return e<0?-e*e:e*e}function P1(e){var t=e(mt,mt),r=1;function n(){return r===1?e(mt,mt):r===.5?e(w1,C1):e(Eu(r),Eu(1/r))}return t.exponent=function(a){return arguments.length?(r=+a,n()):r},Hl(t)}function ql(){var e=P1(Fl());return e.copy=function(){return hs(e,ql()).exponent(e.exponent())},cr.apply(e,arguments),e}function T1(){return ql.apply(null,arguments).exponent(.5)}function Rp(){var e=[.5],t=[0,1],r,n=1;function a(o){return o!=null&&o<=o?t[gp(e,o,0,n)]:r}return a.domain=function(o){return arguments.length?(e=Array.from(o),n=Math.min(e.length,t.length-1),a):e.slice()},a.range=function(o){return arguments.length?(t=Array.from(o),n=Math.min(e.length,t.length-1),a):t.slice()},a.invertExtent=function(o){var s=t.indexOf(o);return[e[s-1],e[s]]},a.unknown=function(o){return arguments.length?(r=o,a):r},a.copy=function(){return Rp().domain(e).range(t).unknown(r)},cr.apply(a,arguments)}const oi=new Date,si=new Date;function Fe(e,t,r,n){function a(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return a.floor=o=>(e(o=new Date(+o)),o),a.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),a.round=o=>{const s=a(o),i=a.ceil(o);return o-s<i-o?s:i},a.offset=(o,s)=>(t(o=new Date(+o),s==null?1:Math.floor(s)),o),a.range=(o,s,i)=>{const l=[];if(o=a.ceil(o),i=i==null?1:Math.floor(i),!(o<s)||!(i>0))return l;let c;do l.push(c=new Date(+o)),t(o,i),e(o);while(c<o&&o<s);return l},a.filter=o=>Fe(s=>{if(s>=s)for(;e(s),!o(s);)s.setTime(s-1)},(s,i)=>{if(s>=s)if(i<0)for(;++i<=0;)for(;t(s,-1),!o(s););else for(;--i>=0;)for(;t(s,1),!o(s););}),r&&(a.count=(o,s)=>(oi.setTime(+o),si.setTime(+s),e(oi),e(si),Math.floor(r(oi,si))),a.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?a.filter(n?s=>n(s)%o===0:s=>a.count(0,s)%o===0):a)),a}const Io=Fe(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Io.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Fe(t=>{t.setTime(Math.floor(t/e)*e)},(t,r)=>{t.setTime(+t+r*e)},(t,r)=>(r-t)/e):Io);Io.range;const Lt=1e3,ft=Lt*60,Dt=ft*60,zt=Dt*24,Jl=zt*7,Iu=zt*30,ii=zt*365,gr=Fe(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Lt)},(e,t)=>(t-e)/Lt,e=>e.getUTCSeconds());gr.range;const Wl=Fe(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Lt)},(e,t)=>{e.setTime(+e+t*ft)},(e,t)=>(t-e)/ft,e=>e.getMinutes());Wl.range;const Yl=Fe(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*ft)},(e,t)=>(t-e)/ft,e=>e.getUTCMinutes());Yl.range;const Kl=Fe(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Lt-e.getMinutes()*ft)},(e,t)=>{e.setTime(+e+t*Dt)},(e,t)=>(t-e)/Dt,e=>e.getHours());Kl.range;const Ql=Fe(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*Dt)},(e,t)=>(t-e)/Dt,e=>e.getUTCHours());Ql.range;const Ta=Fe(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*ft)/zt,e=>e.getDate()-1);Ta.range;const ps=Fe(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/zt,e=>e.getUTCDate()-1);ps.range;const Vp=Fe(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/zt,e=>Math.floor(e/zt));Vp.range;function Ar(e){return Fe(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,r)=>{t.setDate(t.getDate()+r*7)},(t,r)=>(r-t-(r.getTimezoneOffset()-t.getTimezoneOffset())*ft)/Jl)}const ms=Ar(0),Mo=Ar(1),A1=Ar(2),R1=Ar(3),dn=Ar(4),V1=Ar(5),_1=Ar(6);ms.range;Mo.range;A1.range;R1.range;dn.range;V1.range;_1.range;function Rr(e){return Fe(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCDate(t.getUTCDate()+r*7)},(t,r)=>(r-t)/Jl)}const fs=Rr(0),$o=Rr(1),E1=Rr(2),I1=Rr(3),hn=Rr(4),M1=Rr(5),$1=Rr(6);fs.range;$o.range;E1.range;I1.range;hn.range;M1.range;$1.range;const Xl=Fe(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());Xl.range;const Zl=Fe(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());Zl.range;const Gt=Fe(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());Gt.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Fe(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,r)=>{t.setFullYear(t.getFullYear()+r*e)});Gt.range;const Ht=Fe(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());Ht.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Fe(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCFullYear(t.getUTCFullYear()+r*e)});Ht.range;function _p(e,t,r,n,a,o){const s=[[gr,1,Lt],[gr,5,5*Lt],[gr,15,15*Lt],[gr,30,30*Lt],[o,1,ft],[o,5,5*ft],[o,15,15*ft],[o,30,30*ft],[a,1,Dt],[a,3,3*Dt],[a,6,6*Dt],[a,12,12*Dt],[n,1,zt],[n,2,2*zt],[r,1,Jl],[t,1,Iu],[t,3,3*Iu],[e,1,ii]];function i(c,u,d){const h=u<c;h&&([c,u]=[u,c]);const p=d&&typeof d.range=="function"?d:l(c,u,d),f=p?p.range(c,+u+1):[];return h?f.reverse():f}function l(c,u,d){const h=Math.abs(u-c)/d,p=Ul(([,,b])=>b).right(s,h);if(p===s.length)return e.every(Ni(c/ii,u/ii,d));if(p===0)return Io.every(Math.max(Ni(c,u,d),1));const[f,m]=s[h/s[p-1][2]<s[p][2]/h?p-1:p];return f.every(m)}return[i,l]}const[j1,k1]=_p(Ht,Zl,fs,Vp,Ql,Yl),[U1,L1]=_p(Gt,Xl,ms,Ta,Kl,Wl);function li(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function ci(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function jn(e,t,r){return{y:e,m:t,d:r,H:0,M:0,S:0,L:0}}function D1(e){var t=e.dateTime,r=e.date,n=e.time,a=e.periods,o=e.days,s=e.shortDays,i=e.months,l=e.shortMonths,c=kn(a),u=Un(a),d=kn(o),h=Un(o),p=kn(s),f=Un(s),m=kn(i),b=Un(i),x=kn(l),V=Un(l),O={a:ae,A:re,b:le,B:q,c:null,d:Lu,e:Lu,f:lS,g:bS,G:SS,H:oS,I:sS,j:iS,L:Ep,m:cS,M:uS,p:X,q:he,Q:Nu,s:Fu,S:dS,u:hS,U:pS,V:mS,w:fS,W:gS,x:null,X:null,y:yS,Y:vS,Z:xS,"%":Bu},C={a:Pe,A:ze,b:xe,B:it,c:null,d:Du,e:Du,f:PS,g:jS,G:US,H:OS,I:wS,j:CS,L:Mp,m:TS,M:AS,p:tt,q:ye,Q:Nu,s:Fu,S:RS,u:VS,U:_S,V:ES,w:IS,W:MS,x:null,X:null,y:$S,Y:kS,Z:LS,"%":Bu},P={a:y,A:T,b:z,B:_,c:N,d:ku,e:ku,f:tS,g:ju,G:$u,H:Uu,I:Uu,j:Q1,L:eS,m:K1,M:X1,p:F,q:Y1,Q:nS,s:aS,S:Z1,u:G1,U:H1,V:q1,w:z1,W:J1,x:te,X:Z,y:ju,Y:$u,Z:W1,"%":rS};O.x=w(r,O),O.X=w(n,O),O.c=w(t,O),C.x=w(r,C),C.X=w(n,C),C.c=w(t,C);function w(Q,oe){return function(ce){var W=[],be=-1,me=0,Je=Q.length,Ge,Ee,Kt;for(ce instanceof Date||(ce=new Date(+ce));++be<Je;)Q.charCodeAt(be)===37&&(W.push(Q.slice(me,be)),(Ee=Mu[Ge=Q.charAt(++be)])!=null?Ge=Q.charAt(++be):Ee=Ge==="e"?" ":"0",(Kt=oe[Ge])&&(Ge=Kt(ce,Ee)),W.push(Ge),me=be+1);return W.push(Q.slice(me,be)),W.join("")}}function A(Q,oe){return function(ce){var W=jn(1900,void 0,1),be=E(W,Q,ce+="",0),me,Je;if(be!=ce.length)return null;if("Q"in W)return new Date(W.Q);if("s"in W)return new Date(W.s*1e3+("L"in W?W.L:0));if(oe&&!("Z"in W)&&(W.Z=0),"p"in W&&(W.H=W.H%12+W.p*12),W.m===void 0&&(W.m="q"in W?W.q:0),"V"in W){if(W.V<1||W.V>53)return null;"w"in W||(W.w=1),"Z"in W?(me=ci(jn(W.y,0,1)),Je=me.getUTCDay(),me=Je>4||Je===0?$o.ceil(me):$o(me),me=ps.offset(me,(W.V-1)*7),W.y=me.getUTCFullYear(),W.m=me.getUTCMonth(),W.d=me.getUTCDate()+(W.w+6)%7):(me=li(jn(W.y,0,1)),Je=me.getDay(),me=Je>4||Je===0?Mo.ceil(me):Mo(me),me=Ta.offset(me,(W.V-1)*7),W.y=me.getFullYear(),W.m=me.getMonth(),W.d=me.getDate()+(W.w+6)%7)}else("W"in W||"U"in W)&&("w"in W||(W.w="u"in W?W.u%7:"W"in W?1:0),Je="Z"in W?ci(jn(W.y,0,1)).getUTCDay():li(jn(W.y,0,1)).getDay(),W.m=0,W.d="W"in W?(W.w+6)%7+W.W*7-(Je+5)%7:W.w+W.U*7-(Je+6)%7);return"Z"in W?(W.H+=W.Z/100|0,W.M+=W.Z%100,ci(W)):li(W)}}function E(Q,oe,ce,W){for(var be=0,me=oe.length,Je=ce.length,Ge,Ee;be<me;){if(W>=Je)return-1;if(Ge=oe.charCodeAt(be++),Ge===37){if(Ge=oe.charAt(be++),Ee=P[Ge in Mu?oe.charAt(be++):Ge],!Ee||(W=Ee(Q,ce,W))<0)return-1}else if(Ge!=ce.charCodeAt(W++))return-1}return W}function F(Q,oe,ce){var W=c.exec(oe.slice(ce));return W?(Q.p=u.get(W[0].toLowerCase()),ce+W[0].length):-1}function y(Q,oe,ce){var W=p.exec(oe.slice(ce));return W?(Q.w=f.get(W[0].toLowerCase()),ce+W[0].length):-1}function T(Q,oe,ce){var W=d.exec(oe.slice(ce));return W?(Q.w=h.get(W[0].toLowerCase()),ce+W[0].length):-1}function z(Q,oe,ce){var W=x.exec(oe.slice(ce));return W?(Q.m=V.get(W[0].toLowerCase()),ce+W[0].length):-1}function _(Q,oe,ce){var W=m.exec(oe.slice(ce));return W?(Q.m=b.get(W[0].toLowerCase()),ce+W[0].length):-1}function N(Q,oe,ce){return E(Q,t,oe,ce)}function te(Q,oe,ce){return E(Q,r,oe,ce)}function Z(Q,oe,ce){return E(Q,n,oe,ce)}function ae(Q){return s[Q.getDay()]}function re(Q){return o[Q.getDay()]}function le(Q){return l[Q.getMonth()]}function q(Q){return i[Q.getMonth()]}function X(Q){return a[+(Q.getHours()>=12)]}function he(Q){return 1+~~(Q.getMonth()/3)}function Pe(Q){return s[Q.getUTCDay()]}function ze(Q){return o[Q.getUTCDay()]}function xe(Q){return l[Q.getUTCMonth()]}function it(Q){return i[Q.getUTCMonth()]}function tt(Q){return a[+(Q.getUTCHours()>=12)]}function ye(Q){return 1+~~(Q.getUTCMonth()/3)}return{format:function(Q){var oe=w(Q+="",O);return oe.toString=function(){return Q},oe},parse:function(Q){var oe=A(Q+="",!1);return oe.toString=function(){return Q},oe},utcFormat:function(Q){var oe=w(Q+="",C);return oe.toString=function(){return Q},oe},utcParse:function(Q){var oe=A(Q+="",!0);return oe.toString=function(){return Q},oe}}}var Mu={"-":"",_:" ",0:"0"},qe=/^\s*\d+/,B1=/^%/,N1=/[\\^$*+?|[\]().{}]/g;function ge(e,t,r){var n=e<0?"-":"",a=(n?-e:e)+"",o=a.length;return n+(o<r?new Array(r-o+1).join(t)+a:a)}function F1(e){return e.replace(N1,"\\$&")}function kn(e){return new RegExp("^(?:"+e.map(F1).join("|")+")","i")}function Un(e){return new Map(e.map((t,r)=>[t.toLowerCase(),r]))}function z1(e,t,r){var n=qe.exec(t.slice(r,r+1));return n?(e.w=+n[0],r+n[0].length):-1}function G1(e,t,r){var n=qe.exec(t.slice(r,r+1));return n?(e.u=+n[0],r+n[0].length):-1}function H1(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.U=+n[0],r+n[0].length):-1}function q1(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.V=+n[0],r+n[0].length):-1}function J1(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.W=+n[0],r+n[0].length):-1}function $u(e,t,r){var n=qe.exec(t.slice(r,r+4));return n?(e.y=+n[0],r+n[0].length):-1}function ju(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.y=+n[0]+(+n[0]>68?1900:2e3),r+n[0].length):-1}function W1(e,t,r){var n=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(r,r+6));return n?(e.Z=n[1]?0:-(n[2]+(n[3]||"00")),r+n[0].length):-1}function Y1(e,t,r){var n=qe.exec(t.slice(r,r+1));return n?(e.q=n[0]*3-3,r+n[0].length):-1}function K1(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.m=n[0]-1,r+n[0].length):-1}function ku(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.d=+n[0],r+n[0].length):-1}function Q1(e,t,r){var n=qe.exec(t.slice(r,r+3));return n?(e.m=0,e.d=+n[0],r+n[0].length):-1}function Uu(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.H=+n[0],r+n[0].length):-1}function X1(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.M=+n[0],r+n[0].length):-1}function Z1(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.S=+n[0],r+n[0].length):-1}function eS(e,t,r){var n=qe.exec(t.slice(r,r+3));return n?(e.L=+n[0],r+n[0].length):-1}function tS(e,t,r){var n=qe.exec(t.slice(r,r+6));return n?(e.L=Math.floor(n[0]/1e3),r+n[0].length):-1}function rS(e,t,r){var n=B1.exec(t.slice(r,r+1));return n?r+n[0].length:-1}function nS(e,t,r){var n=qe.exec(t.slice(r));return n?(e.Q=+n[0],r+n[0].length):-1}function aS(e,t,r){var n=qe.exec(t.slice(r));return n?(e.s=+n[0],r+n[0].length):-1}function Lu(e,t){return ge(e.getDate(),t,2)}function oS(e,t){return ge(e.getHours(),t,2)}function sS(e,t){return ge(e.getHours()%12||12,t,2)}function iS(e,t){return ge(1+Ta.count(Gt(e),e),t,3)}function Ep(e,t){return ge(e.getMilliseconds(),t,3)}function lS(e,t){return Ep(e,t)+"000"}function cS(e,t){return ge(e.getMonth()+1,t,2)}function uS(e,t){return ge(e.getMinutes(),t,2)}function dS(e,t){return ge(e.getSeconds(),t,2)}function hS(e){var t=e.getDay();return t===0?7:t}function pS(e,t){return ge(ms.count(Gt(e)-1,e),t,2)}function Ip(e){var t=e.getDay();return t>=4||t===0?dn(e):dn.ceil(e)}function mS(e,t){return e=Ip(e),ge(dn.count(Gt(e),e)+(Gt(e).getDay()===4),t,2)}function fS(e){return e.getDay()}function gS(e,t){return ge(Mo.count(Gt(e)-1,e),t,2)}function yS(e,t){return ge(e.getFullYear()%100,t,2)}function bS(e,t){return e=Ip(e),ge(e.getFullYear()%100,t,2)}function vS(e,t){return ge(e.getFullYear()%1e4,t,4)}function SS(e,t){var r=e.getDay();return e=r>=4||r===0?dn(e):dn.ceil(e),ge(e.getFullYear()%1e4,t,4)}function xS(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ge(t/60|0,"0",2)+ge(t%60,"0",2)}function Du(e,t){return ge(e.getUTCDate(),t,2)}function OS(e,t){return ge(e.getUTCHours(),t,2)}function wS(e,t){return ge(e.getUTCHours()%12||12,t,2)}function CS(e,t){return ge(1+ps.count(Ht(e),e),t,3)}function Mp(e,t){return ge(e.getUTCMilliseconds(),t,3)}function PS(e,t){return Mp(e,t)+"000"}function TS(e,t){return ge(e.getUTCMonth()+1,t,2)}function AS(e,t){return ge(e.getUTCMinutes(),t,2)}function RS(e,t){return ge(e.getUTCSeconds(),t,2)}function VS(e){var t=e.getUTCDay();return t===0?7:t}function _S(e,t){return ge(fs.count(Ht(e)-1,e),t,2)}function $p(e){var t=e.getUTCDay();return t>=4||t===0?hn(e):hn.ceil(e)}function ES(e,t){return e=$p(e),ge(hn.count(Ht(e),e)+(Ht(e).getUTCDay()===4),t,2)}function IS(e){return e.getUTCDay()}function MS(e,t){return ge($o.count(Ht(e)-1,e),t,2)}function $S(e,t){return ge(e.getUTCFullYear()%100,t,2)}function jS(e,t){return e=$p(e),ge(e.getUTCFullYear()%100,t,2)}function kS(e,t){return ge(e.getUTCFullYear()%1e4,t,4)}function US(e,t){var r=e.getUTCDay();return e=r>=4||r===0?hn(e):hn.ceil(e),ge(e.getUTCFullYear()%1e4,t,4)}function LS(){return"+0000"}function Bu(){return"%"}function Nu(e){return+e}function Fu(e){return Math.floor(+e/1e3)}var Gr,jp,kp;DS({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function DS(e){return Gr=D1(e),jp=Gr.format,Gr.parse,kp=Gr.utcFormat,Gr.utcParse,Gr}function BS(e){return new Date(e)}function NS(e){return e instanceof Date?+e:+new Date(+e)}function ec(e,t,r,n,a,o,s,i,l,c){var u=Op(),d=u.invert,h=u.domain,p=c(".%L"),f=c(":%S"),m=c("%I:%M"),b=c("%I %p"),x=c("%a %d"),V=c("%b %d"),O=c("%B"),C=c("%Y");function P(w){return(l(w)<w?p:i(w)<w?f:s(w)<w?m:o(w)<w?b:n(w)<w?a(w)<w?x:V:r(w)<w?O:C)(w)}return u.invert=function(w){return new Date(d(w))},u.domain=function(w){return arguments.length?h(Array.from(w,NS)):h().map(BS)},u.ticks=function(w){var A=h();return e(A[0],A[A.length-1],w??10)},u.tickFormat=function(w,A){return A==null?P:c(A)},u.nice=function(w){var A=h();return(!w||typeof w.range!="function")&&(w=t(A[0],A[A.length-1],w??10)),w?h(Tp(A,w)):u},u.copy=function(){return hs(u,ec(e,t,r,n,a,o,s,i,l,c))},u}function Up(){return cr.apply(ec(U1,L1,Gt,Xl,ms,Ta,Kl,Wl,gr,jp).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function FS(){return cr.apply(ec(j1,k1,Ht,Zl,fs,ps,Ql,Yl,gr,kp).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function zS(){var e=0,t=1,r,n,a,o,s=mt,i=!1,l;function c(d){return d==null||isNaN(d=+d)?l:s(a===0?.5:(d=(o(d)-r)*a,i?Math.max(0,Math.min(1,d)):d))}c.domain=function(d){return arguments.length?([e,t]=d,r=o(e=+e),n=o(t=+t),a=r===n?0:1/(n-r),c):[e,t]},c.clamp=function(d){return arguments.length?(i=!!d,c):i},c.interpolator=function(d){return arguments.length?(s=d,c):s};function u(d){return function(h){var p,f;return arguments.length?([p,f]=h,s=d(p,f),c):[s(0),s(1)]}}return c.range=u(ds),c.rangeRound=u(xp),c.unknown=function(d){return arguments.length?(l=d,c):l},function(d){return o=d,r=d(e),n=d(t),a=r===n?0:1/(n-r),c}}function GS(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function Lp(){var e=Hl(zS()(mt));return e.copy=function(){return GS(e,Lp())},_v.apply(e,arguments)}function HS(e,t){return function(n,a){return a.location==="tick"?a.scale.tickFormat(e)(n):a.location==="zoom-slider-tooltip"?t.tickFormat(2)(n):`${n}`}}function qS(e){return e.scaleType==="band"}function JS(e){return e.scaleType==="point"}function WS(e){return e.type==="piecewise"?Rp(e.thresholds,e.colors):Lp([e.min??0,e.max??100],e.color)}function jo(e){return e.values?Ro(e.values,e.colors).unknown(e.unknownColor??null):Ro(e.colors.map((t,r)=>r),e.colors).unknown(e.unknownColor??null)}function mo(e){return e.type==="ordinal"?jo(e):WS(e)}function YS(e){const{tickMaxStep:t,tickMinStep:r,tickNumber:n,range:a,domain:o}=e,s=r===void 0?999:Math.floor(Math.abs(o[1]-o[0])/r),i=t===void 0?2:Math.ceil(Math.abs(o[1]-o[0])/t),l=n??Math.floor(Math.abs(a[1]-a[0])/50);return Math.min(s,Math.max(i,l))}function KS(e,t){return t[1]-t[0]===0?1:e/((t[1]-t[0])/100)}function Hi(e,t,r){switch(e){case"log":return Ap(t,r);case"pow":return ql(t,r);case"sqrt":return T1(t,r);case"time":return Up(t,r);case"utc":return FS(t,r);default:return Pp(t,r)}}const zu=e=>(e==null?void 0:e[0])instanceof Date;function Gu(e,t){const r=Up(e.data,t);return(n,{location:a})=>a==="tick"?r.tickFormat(e.tickNumber)(n):`${n.toLocaleString()}`}const ui=(e,t)=>{const r=e[1]-e[0],n=t[1]-t[0],a=e[0]-t[0]*r/n,o=e[1]+(100-t[1])*r/n;return[a,o]};let Hu,qu;class QS{constructor(){if(this.types=new Set,Hu)throw new Error("You can only create one instance!");Hu=this.types}addType(t){this.types.add(t)}getTypes(){return this.types}}class XS{constructor(){if(this.types=new Set,qu)throw new Error("You can only create one instance!");qu=this.types}addType(t){this.types.add(t)}getTypes(){return this.types}}const gs=new QS;gs.addType("bar");gs.addType("line");gs.addType("scatter");const ZS=new XS;ZS.addType("radar");function Dp(e){return gs.getTypes().has(e)}const ex=(e,t,r,n,a,o,s,i)=>{var f;const l=n==="x"?a[t].xExtremumGetter:a[t].yExtremumGetter,c=((f=s[t])==null?void 0:f.series)??{},[u,d]=(l==null?void 0:l({series:c,axis:r,axisIndex:o,isDefaultAxis:o===0,getFilters:i}))??[1/0,-1/0],[h,p]=e;return[Math.min(u,h),Math.max(d,p)]},Bp=(e,t,r,n,a,o)=>{const i=Object.keys(r).filter(Dp).reduce((l,c)=>ex(l,c,e,t,r,n,a,o),[1/0,-1/0]);return Number.isNaN(i[0])||Number.isNaN(i[1])?[1/0,-1/0]:i},tx=(e,t,r,n)=>{const a=new Set;return Object.keys(t).filter(Dp).forEach(s=>{var c,u,d;const i=((c=r[s])==null?void 0:c.series)??{},l=(d=(u=t[s]).axisTooltipGetter)==null?void 0:d.call(u,i);l!==void 0&&l.forEach(({axisId:h,direction:p})=>{p===e&&a.add(h??n)})}),a},rx=(e,t,r,n)=>{var a;if(e.domainLimit!==void 0)return e.domainLimit;if(t==="x")for(const o of((a=n.line)==null?void 0:a.seriesOrder)??[]){const s=n.line.series[o];if(s.xAxisId===e.id||s.xAxisId===void 0&&r===0)return"strict"}return"nice"};function nx(e,t,r){const n=t==="x"?[e.left,e.left+e.width]:[e.top+e.height,e.top];return r.reverse?[n[1],n[0]]:n}const ax=.2,ox=.1;function Np({drawingArea:e,formattedSeries:t,axis:r,seriesConfig:n,axisDirection:a,zoomMap:o,zoomOptions:s,getFilters:i,preferStrictDomainInLineCharts:l}){if(r===void 0)return{axis:{},axisIds:[]};const c=tx(a,n,t,r[0].id),u={};return r.forEach((d,h)=>{const p=d,f=s==null?void 0:s[p.id],m=o==null?void 0:o.get(p.id),b=m?[m.start,m.end]:[0,100],x=nx(e,a,p),[V,O]=Bp(p,a,n,h,t,m===void 0&&!f?i:void 0),C=!p.ignoreTooltip&&c.has(p.id),P=p.data??[];if(qS(p)){const ae=p.categoryGapRatio??ax,re=p.barGapRatio??ox,le=a==="y"?[x[1],x[0]]:x,q=ui(le,b);if(u[p.id]=Y({offset:0,height:0,categoryGapRatio:ae,barGapRatio:re,triggerTooltip:C},p,{data:P,scale:Ll(p.data,q).paddingInner(ae).paddingOuter(ae/2),tickNumber:p.data.length,colorScale:p.colorMap&&(p.colorMap.type==="ordinal"?jo(Y({values:p.data},p.colorMap)):mo(p.colorMap))}),zu(p.data)){const X=Gu(p,le);u[p.id].valueFormatter=p.valueFormatter??X}}if(JS(p)){const ae=a==="y"?[...x].reverse():x,re=ui(ae,b);if(u[p.id]=Y({offset:0,height:0,triggerTooltip:C},p,{data:P,scale:Ev(p.data,re),tickNumber:p.data.length,colorScale:p.colorMap&&(p.colorMap.type==="ordinal"?jo(Y({values:p.data},p.colorMap)):mo(p.colorMap))}),zu(p.data)){const le=Gu(p,ae);u[p.id].valueFormatter=p.valueFormatter??le}}if(p.scaleType==="band"||p.scaleType==="point")return;const w=p.scaleType??"linear",A=l?rx(p,a,h,t):p.domainLimit??"nice",E=[p.min??V,p.max??O];if(typeof A=="function"){const{min:ae,max:re}=A(V,O);E[0]=ae,E[1]=re}const F=YS(Y({},p,{range:x,domain:E})),y=KS(F,b),T=ui(x,b),z=Hi(w,E,T),_=A==="nice"?z.nice(F):z,[N,te]=_.domain(),Z=[p.min??N,p.max??te];u[p.id]=Y({offset:0,height:0,triggerTooltip:C},p,{data:P,scaleType:w,scale:_.domain(Z),tickNumber:y,colorScale:p.colorMap&&mo(p.colorMap),valueFormatter:p.valueFormatter??HS(y,Hi(w,x.map(ae=>z.invert(ae)),x))})}),{axis:u,axisIds:r.map(({id:d})=>d)}}function sx(e){return e!=null}function Fp({zoomMap:e,zoomOptions:t,seriesConfig:r,formattedSeries:n,direction:a}){return(o,s)=>{var b;const i=t[o.id];if(!i||i.filterMode!=="discard")return null;const l=e==null?void 0:e.get(o.id);if(l===void 0||l.start<=0&&l.end>=100)return null;let c=[];const u=o.scaleType;u==="point"||u==="band"?c=[0,(((b=o.data)==null?void 0:b.length)??1)-1]:c=Bp(o,a,r,s,n);let d,h;[d,h]=Hi(!u||u==="band"||u==="point"?"linear":u,c,[0,100]).nice().domain(),d=d instanceof Date?d.getTime():d,h=h instanceof Date?h.getTime():h;const f=d+l.start*(h-d)/100,m=d+l.end*(h-d)/100;return(x,V)=>{var C;const O=x[a]??((C=o.data)==null?void 0:C[V]);return O==null?!0:o.scaleType==="point"||o.scaleType==="band"||typeof O=="string"?V>=f&&V<=m:O>=f&&O<=m}}}const ix=e=>({currentAxisId:t,seriesXAxisId:r,seriesYAxisId:n,isDefaultAxis:a})=>(o,s)=>{var c,u;return!(t===r?n:r)||a?((u=(c=Object.values(e??{}))[0])==null?void 0:u.call(c,o,s))??!0:[n,r].filter(d=>d!==t).map(d=>e[d??""]).filter(sx).every(d=>d(o,s))},Ju=e=>(t=[])=>t.reduce((r,n)=>{const{zoom:a,id:o}=n,s=kl(a,o,e);return s&&(r[o]=s),r},{}),lx=e=>{const t=new Map;return e.forEach(r=>{t.set(r.axisId,r)}),t},zp=e=>e.zoom;pe([zp],e=>e==null?void 0:e.isInteracting);const ys=pe([zp],e=>(e==null?void 0:e.zoomData)&&lx(e==null?void 0:e.zoomData)),Aa=pe([bn,vn],(e,t)=>Y({},Ju("x")(e),Ju("y")(t)));pe([Aa,(e,t)=>t],(e,t)=>e[t]);const cx=pe([ys,Aa,us,wa],(e,t,r,n)=>e&&t&&Fp({zoomMap:e,zoomOptions:t,seriesConfig:r,formattedSeries:n,direction:"x"})),ux=pe([ys,Aa,us,wa],(e,t,r,n)=>e&&t&&Fp({zoomMap:e,zoomOptions:t,seriesConfig:r,formattedSeries:n,direction:"y"})),Gp=pe([cx,ux,bn,vn],(e,t,r,n)=>{if(e===void 0||t===void 0)return;const a=r==null?void 0:r.reduce((s,i,l)=>{const c=e(i,l);return c!==null&&(s[i.id]=c),s},{}),o=n==null?void 0:n.reduce((s,i,l)=>{const c=t(i,l);return c!==null&&(s[i.id]=c),s},{});if(!(Object.keys(a??{}).length===0&&Object.keys(o??{}).length===0))return ix(Y({},a,o))}),Vr=pe([bn,Oa,wa,us,ys,Aa,Gp,sp],(e,t,r,n,a,o,s,i)=>Np({drawingArea:t,formattedSeries:r,axis:e,seriesConfig:n,axisDirection:"x",zoomMap:a,zoomOptions:o,getFilters:s,preferStrictDomainInLineCharts:i})),_r=pe([vn,Oa,wa,us,ys,Aa,Gp,sp],(e,t,r,n,a,o,s,i)=>Np({drawingArea:t,formattedSeries:r,axis:e,seriesConfig:n,axisDirection:"y",zoomMap:a,zoomOptions:o,getFilters:s,preferStrictDomainInLineCharts:i}));pe([Vr,_r,(e,t)=>t],(e,t,r)=>(e==null?void 0:e.axis[r])??(t==null?void 0:t.axis[r]));pe([bn,vn,(e,t)=>t],(e,t,r)=>{const n=(e==null?void 0:e.find(a=>a.id===r))??(t==null?void 0:t.find(a=>a.id===r))??null;if(n)return n});function Hp(e){return e.bandwidth!==void 0}function Hr(e){return e instanceof Date?e.getTime():e}function pn(e,t){const{scale:r,data:n,reverse:a}=e;if(!Hp(r)){const s=r.invert(t);if(n===void 0)return-1;const i=Hr(s);return n==null?void 0:n.findIndex((c,u)=>{const d=Hr(c);return d>i&&(u===0||Math.abs(i-d)<=Math.abs(i-Hr(n[u-1])))||d<=i&&(u===n.length-1||Math.abs(Hr(s)-d)<Math.abs(Hr(s)-Hr(n[u+1])))})}const o=r.bandwidth()===0?Math.floor((t-Math.min(...r.range())+r.step()/2)/r.step()):Math.floor((t-Math.min(...r.range()))/r.step());return o<0||o>=n.length?-1:a?n.length-1-o:o}function Wu(e,t,r){const{scale:n,data:a}=e;if(!Hp(n)){const o=n.invert(t);return r<0?o:a[r]}return r<0||r>=a.length?null:a[r]}function Yu(e,t){const r=e.createSVGPoint();return r.x=t.clientX,r.y=t.clientY,r.matrixTransform(e.getScreenCTM().inverse())}function en(e){const t=B.useRef(e);return Nt(()=>{t.current=e}),B.useRef((...r)=>(0,t.current)(...r)).current}const dx=Object.is;function qp(e,t){if(e===t)return!0;if(!(e instanceof Object)||!(t instanceof Object))return!1;let r=0,n=0;for(const a in e)if(r+=1,!dx(e[a],t[a])||!(a in t))return!1;for(const a in t)n+=1;return r===n}const tc=({store:e})=>{const t=en(function(){e.update(s=>Y({},s,{interaction:{pointer:null,item:null}}))}),r=en(function(s){e.update(i=>{const l=i.interaction.item;return s?l===null||Object.keys(s).some(c=>s[c]!==l[c])?i:Y({},i,{interaction:Y({},i.interaction,{item:null})}):l===null?i:Y({},i,{interaction:Y({},i.interaction,{item:null})})})}),n=en(function(s){e.update(i=>qp(i.interaction.item,s)?i:Y({},i,{interaction:Y({},i.interaction,{item:s})}))}),a=en(function(s){e.update(i=>Y({},i,{interaction:Y({},i.interaction,{pointer:s})}))});return{instance:{cleanInteraction:t,setItemInteraction:n,removeItemInteraction:r,setPointerCoordinate:a}}};tc.getInitialState=()=>({interaction:{item:null,pointer:null}});tc.params={};const rc=e=>e.interaction,hx=pe([rc],e=>e!==void 0),px=pe([rc],e=>(e==null?void 0:e.item)??null),Jp=pe([rc],e=>(e==null?void 0:e.pointer)??null),bs=pe([Jp],e=>e&&e.x),vs=pe([Jp],e=>e&&e.y);pe([px],e=>e!==null);function ea(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;if(Array.isArray(e)){const a=e.length;if(a!==t.length)return!1;for(let o=0;o<a;o+=1)if(!ea(e[o],t[o]))return!1;return!0}if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;const a=Array.from(e.entries());for(let o=0;o<a.length;o+=1)if(!t.has(a[o][0]))return!1;for(let o=0;o<a.length;o+=1){const s=a[o];if(!ea(s[1],t.get(s[0])))return!1}return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;const a=Array.from(e.entries());for(let o=0;o<a.length;o+=1)if(!t.has(a[o][0]))return!1;return!0}if(ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){const a=e.length;if(a!==t.length)return!1;for(let o=0;o<a;o+=1)if(e[o]!==t[o])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();const r=Object.keys(e),n=r.length;if(n!==Object.keys(t).length)return!1;for(let a=0;a<n;a+=1)if(!Object.prototype.hasOwnProperty.call(t,r[a]))return!1;for(let a=0;a<n;a+=1){const o=r[a];if(!ea(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}const Ss=(e,t)=>t;function qi(e,t,r=t.axisIds[0]){return Array.isArray(r)?r.map(n=>pn(t.axis[n],e)):pn(t.axis[r],e)}const Wp=(e,t,r)=>{if(e===null)return null;const n=qi(e,t,r);return n===-1?null:n},mx=pe([bs,Vr,Ss],Wp),fx=pe([vs,_r,Ss],Wp),gx=pe([bs,vs,Vr,_r],(e,t,r,n)=>[...e===null?[]:r.axisIds.map(a=>({axisId:a,dataIndex:qi(e,r,a)})),...t===null?[]:n.axisIds.map(a=>({axisId:a,dataIndex:qi(t,n,a)}))].filter(a=>a.dataIndex!==null&&a.dataIndex>=0));function Yp(e,t,r,n=t.axisIds[0]){return Array.isArray(n)?n.map((a,o)=>Wu(t.axis[a],e,r[o])):Wu(t.axis[n],e,r)}pe([bs,Vr,mx,Ss],(e,t,r,n)=>e===null||r===null||t.axisIds.length===0?null:Yp(e,t,r,n));pe([vs,_r,fx,Ss],(e,t,r,n)=>e===null||r===null||t.axisIds.length===0?null:Yp(e,t,r,n));const yx=pe([bs,Vr],(e,t)=>e===null?[]:t.axisIds.filter(r=>t.axis[r].triggerTooltip).map(r=>({axisId:r,dataIndex:pn(t.axis[r],e)})).filter(({dataIndex:r})=>r>=0),{memoizeOptions:{resultEqualityCheck:ea}}),bx=pe([vs,_r],(e,t)=>e===null?[]:t.axisIds.filter(r=>t.axis[r].triggerTooltip).map(r=>({axisId:r,dataIndex:pn(t.axis[r],e)})).filter(({dataIndex:r})=>r>=0),{memoizeOptions:{resultEqualityCheck:ea}});pe([yx,bx],(e,t)=>e.length>0||t.length>0);const Ku={};function vx(e,t){const r=B.useRef(Ku);return r.current===Ku&&(r.current=e(t)),r}const Sx=()=>{};function xx(e,t,r,n){const a=vx(Ox,{store:e,selector:t,skip:n}).current;a.effect=r,B.useEffect(a.onMount(n),[n])}function Ox(e){const{store:t,selector:r,skip:n}=e;let a=!1,o;const s=()=>{i.dispose??(i.dispose=t.subscribe(l=>{const c=r(l);i.effect(o,c),o=c}))},i={effect:Sx,dispose:null,onMount:l=>()=>{if(!l)return a||(a=!0,o=r(t.value)),s(),()=>{var c;(c=i.dispose)==null||c.call(i),i.dispose=null}}};return n||(a=!0,o=r(t.value),s()),i}const xs=({params:e,store:t,seriesConfig:r,svgRef:n,instance:a})=>{const{xAxis:o,yAxis:s,dataset:i,onHighlightedAxisChange:l}=e;if(process.env.NODE_ENV!=="production"){const O=[...o??[],...s??[]].filter(P=>P.id).map(P=>P.id),C=new Set(O.filter((P,w)=>O.indexOf(P)!==w));C.size>0&&sa([`MUI X Charts: The following axis ids are duplicated: ${Array.from(C).join(", ")}.`,"Please make sure that each axis has a unique id."].join(`
|
|
116
|
-
`),"error")}const c=at(t,Oa),u=at(t,wa),d=at(t,hx),{axis:h,axisIds:p}=at(t,Vr),{axis:f,axisIds:m}=at(t,_r);dp({warningPrefix:"MUI X Charts",componentName:"Chart",propName:"highlightedAxis",controlled:e.highlightedAxis,defaultValue:void 0}),Nt(()=>{e.highlightedAxis!==void 0&&t.update(O=>O.controlledCartesianAxisHighlight===e.highlightedAxis?O:Y({},O,{controlledCartesianAxisHighlight:e.highlightedAxis}))},[t,e.highlightedAxis]);const b=B.useRef(!0);B.useEffect(()=>{if(b.current){b.current=!1;return}t.update(O=>Y({},O,{cartesianAxis:Y({},O.cartesianAxis,{x:mp(o,i),y:fp(s,i)})}))},[r,c,o,s,i,t]);const x=p[0],V=m[0];return xx(t,gx,(O,C)=>{if(!Object.is(O,C)){if(O.length!==C.length){l(C);return}O!=null&&O.some(({axisId:P,dataIndex:w},A)=>C[A].axisId!==P||C[A].dataIndex!==w)&&l(C)}},!l),B.useEffect(()=>{const O=n.current;if(!d||!O||e.disableAxisListener)return()=>{};const C=a.addInteractionListener("moveEnd",T=>{var z;T.detail.activeGestures.pan||(z=a.cleanInteraction)==null||z.call(a)}),P=a.addInteractionListener("panEnd",T=>{var z;T.detail.activeGestures.move||(z=a.cleanInteraction)==null||z.call(a)}),w=a.addInteractionListener("quickPressEnd",T=>{var z;!T.detail.activeGestures.move&&!T.detail.activeGestures.pan&&((z=a.cleanInteraction)==null||z.call(a))}),A=T=>{var te,Z;const z=T.detail.srcEvent,_=T.detail.target,N=Yu(O,z);if(T.detail.srcEvent.buttons>=1&&(_!=null&&_.hasPointerCapture(T.detail.srcEvent.pointerId))&&!(_!=null&&_.closest("[data-charts-zoom-slider]"))&&(_==null||_.releasePointerCapture(T.detail.srcEvent.pointerId)),!a.isPointInside(N.x,N.y,_)){(te=a.cleanInteraction)==null||te.call(a);return}(Z=a.setPointerCoordinate)==null||Z.call(a,N)},E=a.addInteractionListener("move",A),F=a.addInteractionListener("pan",A),y=a.addInteractionListener("quickPress",A);return()=>{E.cleanup(),C.cleanup(),F.cleanup(),P.cleanup(),y.cleanup(),w.cleanup()}},[n,t,h,x,f,V,a,e.disableAxisListener,d]),B.useEffect(()=>{const O=n.current,C=e.onAxisClick;if(O===null||!C)return()=>{};const P=a.addInteractionListener("tap",w=>{let A=null,E=!1;const F=Yu(O,w.detail.srcEvent),y=pn(h[x],F.x);E=y!==-1,A=E?y:pn(f[V],F.y);const T=E?p[0]:m[0];if(A==null||A===-1)return;const z=(E?h:f)[T].data[A],_={};Object.keys(u).filter(N=>["bar","line"].includes(N)).forEach(N=>{var te;(te=u[N])==null||te.seriesOrder.forEach(Z=>{const ae=u[N].series[Z],re=ae.xAxisId,le=ae.yAxisId,q=E?re:le;(q===void 0||q===T)&&(_[Z]=ae.data[A])})}),C(w.detail.srcEvent,{dataIndex:A,axisValue:z,seriesValues:_})});return()=>{P.cleanup()}},[e.onAxisClick,u,n,h,p,f,m,x,V,a]),{}};xs.params={xAxis:!0,yAxis:!0,dataset:!0,onAxisClick:!0,disableAxisListener:!0,onHighlightedAxisChange:!0,highlightedAxis:!0};xs.getDefaultizedParams=({params:e})=>Y({},e,{colors:e.colors??ip,theme:e.theme??"light",defaultizedXAxis:mp(e.xAxis,e.dataset),defaultizedYAxis:fp(e.yAxis,e.dataset)});xs.getInitialState=e=>Y({cartesianAxis:{x:e.defaultizedXAxis,y:e.defaultizedYAxis}},e.highlightedAxis===void 0?{}:{controlledCartesianAxisHighlight:e.highlightedAxis});function Qu(e,t){return e.id!==void 0?e:Y({id:t},e)}function Xu(e){return e.colorMap?Y({},e,{colorScale:e.colorMap.type==="ordinal"&&e.data?jo(Y({values:e.data},e.colorMap)):mo(e.colorMap.type==="continuous"?Y({min:e.min,max:e.max},e.colorMap):e.colorMap)}):e}function Kp(e,t){if(!e||e.length===0)return{axis:{},axisIds:[]};const r={},n=[];return e.forEach((a,o)=>{const s=a.dataKey,i=a.id??`defaultized-z-axis-${o}`;if(s===void 0||a.data!==void 0){r[i]=Xu(Qu(a,i)),n.push(i);return}if(t===void 0)throw new Error("MUI X Charts: z-axis uses `dataKey` but no `dataset` is provided.");r[i]=Xu(Qu(Y({},a,{data:t.map(l=>l[s])}),i)),n.push(i)}),{axis:r,axisIds:n}}const nc=({params:e,store:t})=>{const{zAxis:r,dataset:n}=e,a=B.useRef(!0);return B.useEffect(()=>{if(a.current){a.current=!1;return}t.update(o=>Y({},o,{zAxis:Kp(r,n)}))},[r,n,t]),{}};nc.params={zAxis:!0,dataset:!0};nc.getInitialState=e=>({zAxis:Kp(e.zAxis,e.dataset)});const wx=e=>e,Cx=pe([wx],e=>e.zAxis),Os=({store:e,params:t})=>{dp({warningPrefix:"MUI X Charts",componentName:"Chart",propName:"highlightedItem",controlled:t.highlightedItem,defaultValue:null}),Nt(()=>{e.update(a=>a.highlight.item===t.highlightedItem?a:Y({},a,{highlight:Y({},a.highlight,{item:t.highlightedItem})}))},[e,t.highlightedItem]);const r=en(()=>{var a;(a=t.onHighlightChange)==null||a.call(t,null),e.update(o=>Y({},o,{highlight:{item:null}}))}),n=en(a=>{var s;const o=e.getSnapshot().highlight.item;qp(o,a)||((s=t.onHighlightChange)==null||s.call(t,a),e.update(i=>Y({},i,{highlight:{item:a}})))});return{instance:{clearHighlight:r,setHighlight:n}}};Os.getDefaultizedParams=({params:e})=>Y({},e,{highlightedItem:e.highlightedItem??null});Os.getInitialState=e=>({highlight:{item:e.highlightedItem}});Os.params={highlightedItem:!0,onHighlightChange:!0};const Zu=(e,t)=>t==="x"?{x:e,y:null}:{x:null,y:e},Qp=e=>{var l;const{axis:t,getFilters:r,isDefaultAxis:n}=e,a=r==null?void 0:r({currentAxisId:t.id,isDefaultAxis:n}),o=a?(l=t.data)==null?void 0:l.filter((c,u)=>a({x:null,y:null},u)):t.data,s=Math.min(...o??[]),i=Math.max(...o??[]);return[s,i]},Xp=e=>t=>{const{series:r,axis:n,getFilters:a,isDefaultAxis:o}=t;return Object.keys(r).filter(s=>{const i=e==="x"?r[s].xAxisId:r[s].yAxisId;return i===n.id||o&&i===void 0}).reduce((s,i)=>{const{stackedData:l}=r[i],c=a==null?void 0:a({currentAxisId:n.id,isDefaultAxis:o,seriesXAxisId:r[i].xAxisId,seriesYAxisId:r[i].yAxisId}),[u,d]=(l==null?void 0:l.reduce((h,p,f)=>c&&(!c(Zu(p[0],e),f)||!c(Zu(p[1],e),f))?h:[Math.min(...p,h[0]),Math.max(...p,h[1])],[1/0,-1/0]))??[1/0,-1/0];return[Math.min(u,s[0]),Math.max(d,s[1])]},[1/0,-1/0])},Px=e=>Object.keys(e.series).some(r=>e.series[r].layout==="horizontal")?Xp("x")(e):Qp(e),Tx=e=>Object.keys(e.series).some(r=>e.series[r].layout==="horizontal")?Qp(e):Xp("y")(e);function Ne(e){return function(){return e}}const ed=Math.abs,Ke=Math.atan2,dr=Math.cos,Ax=Math.max,di=Math.min,Tt=Math.sin,tn=Math.sqrt,nt=1e-12,da=Math.PI,ko=da/2,fo=2*da;function Rx(e){return e>1?0:e<-1?da:Math.acos(e)}function td(e){return e>=1?ko:e<=-1?-ko:Math.asin(e)}const Ji=Math.PI,Wi=2*Ji,pr=1e-6,Vx=Wi-pr;function Zp(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=arguments[t]+e[t]}function _x(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return Zp;const r=10**t;return function(n){this._+=n[0];for(let a=1,o=n.length;a<o;++a)this._+=Math.round(arguments[a]*r)/r+n[a]}}class Ex{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?Zp:_x(t)}moveTo(t,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,r){this._append`L${this._x1=+t},${this._y1=+r}`}quadraticCurveTo(t,r,n,a){this._append`Q${+t},${+r},${this._x1=+n},${this._y1=+a}`}bezierCurveTo(t,r,n,a,o,s){this._append`C${+t},${+r},${+n},${+a},${this._x1=+o},${this._y1=+s}`}arcTo(t,r,n,a,o){if(t=+t,r=+r,n=+n,a=+a,o=+o,o<0)throw new Error(`negative radius: ${o}`);let s=this._x1,i=this._y1,l=n-t,c=a-r,u=s-t,d=i-r,h=u*u+d*d;if(this._x1===null)this._append`M${this._x1=t},${this._y1=r}`;else if(h>pr)if(!(Math.abs(d*l-c*u)>pr)||!o)this._append`L${this._x1=t},${this._y1=r}`;else{let p=n-s,f=a-i,m=l*l+c*c,b=p*p+f*f,x=Math.sqrt(m),V=Math.sqrt(h),O=o*Math.tan((Ji-Math.acos((m+h-b)/(2*x*V)))/2),C=O/V,P=O/x;Math.abs(C-1)>pr&&this._append`L${t+C*u},${r+C*d}`,this._append`A${o},${o},0,0,${+(d*p>u*f)},${this._x1=t+P*l},${this._y1=r+P*c}`}}arc(t,r,n,a,o,s){if(t=+t,r=+r,n=+n,s=!!s,n<0)throw new Error(`negative radius: ${n}`);let i=n*Math.cos(a),l=n*Math.sin(a),c=t+i,u=r+l,d=1^s,h=s?a-o:o-a;this._x1===null?this._append`M${c},${u}`:(Math.abs(this._x1-c)>pr||Math.abs(this._y1-u)>pr)&&this._append`L${c},${u}`,n&&(h<0&&(h=h%Wi+Wi),h>Vx?this._append`A${n},${n},0,1,${d},${t-i},${r-l}A${n},${n},0,1,${d},${this._x1=c},${this._y1=u}`:h>pr&&this._append`A${n},${n},0,${+(h>=Ji)},${d},${this._x1=t+n*Math.cos(o)},${this._y1=r+n*Math.sin(o)}`)}rect(t,r,n,a){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}h${n=+n}v${+a}h${-n}Z`}toString(){return this._}}function Ix(e){let t=3;return e.digits=function(r){if(!arguments.length)return t;if(r==null)t=null;else{const n=Math.floor(r);if(!(n>=0))throw new RangeError(`invalid digits: ${r}`);t=n}return e},()=>new Ex(t)}function Mx(e){return e.innerRadius}function $x(e){return e.outerRadius}function jx(e){return e.startAngle}function kx(e){return e.endAngle}function Ux(e){return e&&e.padAngle}function Lx(e,t,r,n,a,o,s,i){var l=r-e,c=n-t,u=s-a,d=i-o,h=d*l-u*c;if(!(h*h<nt))return h=(u*(t-o)-d*(e-a))/h,[e+h*l,t+h*c]}function Ya(e,t,r,n,a,o,s){var i=e-r,l=t-n,c=(s?o:-o)/tn(i*i+l*l),u=c*l,d=-c*i,h=e+u,p=t+d,f=r+u,m=n+d,b=(h+f)/2,x=(p+m)/2,V=f-h,O=m-p,C=V*V+O*O,P=a-o,w=h*m-f*p,A=(O<0?-1:1)*tn(Ax(0,P*P*C-w*w)),E=(w*O-V*A)/C,F=(-w*V-O*A)/C,y=(w*O+V*A)/C,T=(-w*V+O*A)/C,z=E-b,_=F-x,N=y-b,te=T-x;return z*z+_*_>N*N+te*te&&(E=y,F=T),{cx:E,cy:F,x01:-u,y01:-d,x11:E*(a/P-1),y11:F*(a/P-1)}}function em(){var e=Mx,t=$x,r=Ne(0),n=null,a=jx,o=kx,s=Ux,i=null,l=Ix(c);function c(){var u,d,h=+e.apply(this,arguments),p=+t.apply(this,arguments),f=a.apply(this,arguments)-ko,m=o.apply(this,arguments)-ko,b=ed(m-f),x=m>f;if(i||(i=u=l()),p<h&&(d=p,p=h,h=d),!(p>nt))i.moveTo(0,0);else if(b>fo-nt)i.moveTo(p*dr(f),p*Tt(f)),i.arc(0,0,p,f,m,!x),h>nt&&(i.moveTo(h*dr(m),h*Tt(m)),i.arc(0,0,h,m,f,x));else{var V=f,O=m,C=f,P=m,w=b,A=b,E=s.apply(this,arguments)/2,F=E>nt&&(n?+n.apply(this,arguments):tn(h*h+p*p)),y=di(ed(p-h)/2,+r.apply(this,arguments)),T=y,z=y,_,N;if(F>nt){var te=td(F/h*Tt(E)),Z=td(F/p*Tt(E));(w-=te*2)>nt?(te*=x?1:-1,C+=te,P-=te):(w=0,C=P=(f+m)/2),(A-=Z*2)>nt?(Z*=x?1:-1,V+=Z,O-=Z):(A=0,V=O=(f+m)/2)}var ae=p*dr(V),re=p*Tt(V),le=h*dr(P),q=h*Tt(P);if(y>nt){var X=p*dr(O),he=p*Tt(O),Pe=h*dr(C),ze=h*Tt(C),xe;if(b<da)if(xe=Lx(ae,re,Pe,ze,X,he,le,q)){var it=ae-xe[0],tt=re-xe[1],ye=X-xe[0],Q=he-xe[1],oe=1/Tt(Rx((it*ye+tt*Q)/(tn(it*it+tt*tt)*tn(ye*ye+Q*Q)))/2),ce=tn(xe[0]*xe[0]+xe[1]*xe[1]);T=di(y,(h-ce)/(oe-1)),z=di(y,(p-ce)/(oe+1))}else T=z=0}A>nt?z>nt?(_=Ya(Pe,ze,ae,re,p,z,x),N=Ya(X,he,le,q,p,z,x),i.moveTo(_.cx+_.x01,_.cy+_.y01),z<y?i.arc(_.cx,_.cy,z,Ke(_.y01,_.x01),Ke(N.y01,N.x01),!x):(i.arc(_.cx,_.cy,z,Ke(_.y01,_.x01),Ke(_.y11,_.x11),!x),i.arc(0,0,p,Ke(_.cy+_.y11,_.cx+_.x11),Ke(N.cy+N.y11,N.cx+N.x11),!x),i.arc(N.cx,N.cy,z,Ke(N.y11,N.x11),Ke(N.y01,N.x01),!x))):(i.moveTo(ae,re),i.arc(0,0,p,V,O,!x)):i.moveTo(ae,re),!(h>nt)||!(w>nt)?i.lineTo(le,q):T>nt?(_=Ya(le,q,X,he,h,-T,x),N=Ya(ae,re,Pe,ze,h,-T,x),i.lineTo(_.cx+_.x01,_.cy+_.y01),T<y?i.arc(_.cx,_.cy,T,Ke(_.y01,_.x01),Ke(N.y01,N.x01),!x):(i.arc(_.cx,_.cy,T,Ke(_.y01,_.x01),Ke(_.y11,_.x11),!x),i.arc(0,0,h,Ke(_.cy+_.y11,_.cx+_.x11),Ke(N.cy+N.y11,N.cx+N.x11),x),i.arc(N.cx,N.cy,T,Ke(N.y11,N.x11),Ke(N.y01,N.x01),!x))):i.arc(0,0,h,P,C,x)}if(i.closePath(),u)return i=null,u+""||null}return c.centroid=function(){var u=(+e.apply(this,arguments)+ +t.apply(this,arguments))/2,d=(+a.apply(this,arguments)+ +o.apply(this,arguments))/2-da/2;return[dr(d)*u,Tt(d)*u]},c.innerRadius=function(u){return arguments.length?(e=typeof u=="function"?u:Ne(+u),c):e},c.outerRadius=function(u){return arguments.length?(t=typeof u=="function"?u:Ne(+u),c):t},c.cornerRadius=function(u){return arguments.length?(r=typeof u=="function"?u:Ne(+u),c):r},c.padRadius=function(u){return arguments.length?(n=u==null?null:typeof u=="function"?u:Ne(+u),c):n},c.startAngle=function(u){return arguments.length?(a=typeof u=="function"?u:Ne(+u),c):a},c.endAngle=function(u){return arguments.length?(o=typeof u=="function"?u:Ne(+u),c):o},c.padAngle=function(u){return arguments.length?(s=typeof u=="function"?u:Ne(+u),c):s},c.context=function(u){return arguments.length?(i=u??null,c):i},c}function tm(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Dx(e,t){return t<e?-1:t>e?1:t>=e?0:NaN}function Bx(e){return e}function Nx(){var e=Bx,t=Dx,r=null,n=Ne(0),a=Ne(fo),o=Ne(0);function s(i){var l,c=(i=tm(i)).length,u,d,h=0,p=new Array(c),f=new Array(c),m=+n.apply(this,arguments),b=Math.min(fo,Math.max(-fo,a.apply(this,arguments)-m)),x,V=Math.min(Math.abs(b)/c,o.apply(this,arguments)),O=V*(b<0?-1:1),C;for(l=0;l<c;++l)(C=f[p[l]=l]=+e(i[l],l,i))>0&&(h+=C);for(t!=null?p.sort(function(P,w){return t(f[P],f[w])}):r!=null&&p.sort(function(P,w){return r(i[P],i[w])}),l=0,d=h?(b-c*O)/h:0;l<c;++l,m=x)u=p[l],C=f[u],x=m+(C>0?C*d:0)+O,f[u]={data:i[u],index:l,value:C,startAngle:m,endAngle:x,padAngle:V};return f}return s.value=function(i){return arguments.length?(e=typeof i=="function"?i:Ne(+i),s):e},s.sortValues=function(i){return arguments.length?(t=i,r=null,s):t},s.sort=function(i){return arguments.length?(r=i,t=null,s):r},s.startAngle=function(i){return arguments.length?(n=typeof i=="function"?i:Ne(+i),s):n},s.endAngle=function(i){return arguments.length?(a=typeof i=="function"?i:Ne(+i),s):a},s.padAngle=function(i){return arguments.length?(o=typeof i=="function"?i:Ne(+i),s):o},s}function mn(e,t){if((s=e.length)>1)for(var r=1,n,a,o=e[t[0]],s,i=o.length;r<s;++r)for(a=o,o=e[t[r]],n=0;n<i;++n)o[n][1]+=o[n][0]=isNaN(a[n][1])?a[n][0]:a[n][1]}function fn(e){for(var t=e.length,r=new Array(t);--t>=0;)r[t]=t;return r}function Fx(e,t){return e[t]}function zx(e){const t=[];return t.key=e,t}function rm(){var e=Ne([]),t=fn,r=mn,n=Fx;function a(o){var s=Array.from(e.apply(this,arguments),zx),i,l=s.length,c=-1,u;for(const d of o)for(i=0,++c;i<l;++i)(s[i][c]=[0,+n(d,s[i].key,c,o)]).data=d;for(i=0,u=tm(t(s));i<l;++i)s[u[i]].index=i;return r(s,u),s}return a.keys=function(o){return arguments.length?(e=typeof o=="function"?o:Ne(Array.from(o)),a):e},a.value=function(o){return arguments.length?(n=typeof o=="function"?o:Ne(+o),a):n},a.order=function(o){return arguments.length?(t=o==null?fn:typeof o=="function"?o:Ne(Array.from(o)),a):t},a.offset=function(o){return arguments.length?(r=o??mn,a):r},a}function Gx(e,t){if((n=e.length)>0){for(var r,n,a=0,o=e[0].length,s;a<o;++a){for(s=r=0;r<n;++r)s+=e[r][a][1]||0;if(s)for(r=0;r<n;++r)e[r][a][1]/=s}mn(e,t)}}function Hx(e,t){if((l=e.length)>0)for(var r,n=0,a,o,s,i,l,c=e[t[0]].length;n<c;++n)for(s=i=0,r=0;r<l;++r)(o=(a=e[t[r]][n])[1]-a[0])>0?(a[0]=s,a[1]=s+=o):o<0?(a[1]=i,a[0]=i+=o):(a[0]=0,a[1]=o)}function qx(e,t){if((a=e.length)>0){for(var r=0,n=e[t[0]],a,o=n.length;r<o;++r){for(var s=0,i=0;s<a;++s)i+=e[s][r][1]||0;n[r][1]+=n[r][0]=-i/2}mn(e,t)}}function Jx(e,t){if(!(!((s=e.length)>0)||!((o=(a=e[t[0]]).length)>0))){for(var r=0,n=1,a,o,s;n<o;++n){for(var i=0,l=0,c=0;i<s;++i){for(var u=e[t[i]],d=u[n][1]||0,h=u[n-1][1]||0,p=(d-h)/2,f=0;f<i;++f){var m=e[t[f]],b=m[n][1]||0,x=m[n-1][1]||0;p+=b-x}l+=d,c+=p*d}a[n-1][1]+=a[n-1][0]=r,l&&(r-=c/l)}a[n-1][1]+=a[n-1][0]=r,mn(e,t)}}function nm(e){var t=e.map(Wx);return fn(e).sort(function(r,n){return t[r]-t[n]})}function Wx(e){for(var t=-1,r=0,n=e.length,a,o=-1/0;++t<n;)(a=+e[t][1])>o&&(o=a,r=t);return r}function am(e){var t=e.map(om);return fn(e).sort(function(r,n){return t[r]-t[n]})}function om(e){for(var t=0,r=-1,n=e.length,a;++r<n;)(a=+e[r][1])&&(t+=a);return t}function Yx(e){return am(e).reverse()}function Kx(e){var t=e.length,r,n,a=e.map(om),o=nm(e),s=0,i=0,l=[],c=[];for(r=0;r<t;++r)n=o[r],s<i?(s+=a[n],l.push(n)):(i+=a[n],c.push(n));return c.reverse().concat(l)}function Qx(e){return fn(e).reverse()}const hi={appearance:nm,ascending:am,descending:Yx,insideOut:Kx,none:fn,reverse:Qx},pi={expand:Gx,diverging:Hx,none:mn,silhouette:qx,wiggle:Jx},sm=e=>{const{series:t,seriesOrder:r,defaultStrategy:n}=e,a=[],o={};return r.forEach(s=>{const{stack:i,stackOrder:l,stackOffset:c}=t[s];i===void 0?a.push({ids:[s],stackingOrder:hi.none,stackingOffset:pi.none}):o[i]===void 0?(o[i]=a.length,a.push({ids:[s],stackingOrder:hi[l??(n==null?void 0:n.stackOrder)??"none"],stackingOffset:pi[c??(n==null?void 0:n.stackOffset)??"diverging"]})):(a[o[i]].ids.push(s),l!==void 0&&(a[o[i]].stackingOrder=hi[l]),c!==void 0&&(a[o[i]].stackingOffset=pi[c]))}),a},Xx=e=>e==null?"":e.toLocaleString(),Zx=(e,t)=>{const{seriesOrder:r,series:n}=e,a=sm(e),o=t??[];r.forEach(i=>{const l=n[i].data;if(l!==void 0)l.forEach((c,u)=>{o.length<=u?o.push({[i]:c}):o[u][i]=c});else if(t===void 0)throw new Error([`MUI X Charts: bar series with id='${i}' has no data.`,"Either provide a data property to the series or use the dataset prop."].join(`
|
|
117
|
-
`))});const s={};return a.forEach(i=>{const{ids:l,stackingOffset:c,stackingOrder:u}=i,d=
|
|
118
|
-
`));const l=s?(r==null?void 0:r.map(c=>({x:c[s.x]??null,y:c[s.y]??null,z:s.z&&c[s.z],id:s.id&&c[s.id]})))??[]:o.data??[];return[a,Y({labelMarkType:"circle",markerSize:4},o,{preview:Y({markerSize:1},o==null?void 0:o.preview),data:l,valueFormatter:o.valueFormatter??(c=>c&&`(${c.x}, ${c.y})`)})]})),seriesOrder:t}),
|
|
119
|
-
`))});const s={};return a.forEach(i=>{const{ids:l,stackingOrder:c,stackingOffset:u}=i,d=
|
|
120
|
-
`));return e};function
|
|
121
|
-
`));return e.store}function
|
|
122
|
-
`));return e.svgRef}function DO(){const e=cm();return B.useCallback(t=>`${e}-gradient-${t}`,[e])}function BO(){const e=cm();return B.useCallback(t=>`${e}-gradient-${t}-object-bound`,[e])}var mi,rd;function NO(){if(rd)return mi;rd=1;var e=4,t=.001,r=1e-7,n=10,a=11,o=1/(a-1),s=typeof Float32Array=="function";function i(m,b){return 1-3*b+3*m}function l(m,b){return 3*b-6*m}function c(m){return 3*m}function u(m,b,x){return((i(b,x)*m+l(b,x))*m+c(b))*m}function d(m,b,x){return 3*i(b,x)*m*m+2*l(b,x)*m+c(b)}function h(m,b,x,V,O){var C,P,w=0;do P=b+(x-b)/2,C=u(P,V,O)-m,C>0?x=P:b=P;while(Math.abs(C)>r&&++w<n);return P}function p(m,b,x,V){for(var O=0;O<e;++O){var C=d(b,x,V);if(C===0)return b;var P=u(b,x,V)-m;b-=P/C}return b}function f(m){return m}return mi=function(b,x,V,O){if(!(0<=b&&b<=1&&0<=V&&V<=1))throw new Error("bezier x values must be in [0, 1] range");if(b===x&&V===O)return f;for(var C=s?new Float32Array(a):new Array(a),P=0;P<a;++P)C[P]=u(P*o,b,V);function w(A){for(var E=0,F=1,y=a-1;F!==y&&C[F]<=A;++F)E+=o;--F;var T=(A-C[F])/(C[F+1]-C[F]),z=E+T*o,_=d(z,b,V);return _>=t?p(A,z,b,V):_===0?z:h(A,E,E+o,b,V)}return function(E){return E===0?0:E===1?1:u(w(E),x,O)}},mi}var FO=NO();const zO=ug(FO),GO=300,HO=zO(.66,0,.34,1);var gn=0,Qn=0,Ln=0,um=1e3,Lo,Xn,Do=0,Or=0,ws=0,ha=typeof performance=="object"&&performance.now?performance:Date,dm=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function ac(){return Or||(dm(qO),Or=ha.now()+ws)}function qO(){Or=0}function Bo(){this._call=this._time=this._next=null}Bo.prototype=hm.prototype={constructor:Bo,restart:function(e,t,r){if(typeof e!="function")throw new TypeError("callback is not a function");r=(r==null?ac():+r)+(t==null?0:+t),!this._next&&Xn!==this&&(Xn?Xn._next=this:Lo=this,Xn=this),this._call=e,this._time=r,Qi()},stop:function(){this._call&&(this._call=null,this._time=1/0,Qi())}};function hm(e,t,r){var n=new Bo;return n.restart(e,t,r),n}function Ki(){ac(),++gn;for(var e=Lo,t;e;)(t=Or-e._time)>=0&&e._call.call(void 0,t),e=e._next;--gn}function nd(){Or=(Do=ha.now())+ws,gn=Qn=0;try{Ki()}finally{gn=0,WO(),Or=0}}function JO(){var e=ha.now(),t=e-Do;t>um&&(ws-=t,Do=e)}function WO(){for(var e,t=Lo,r,n=1/0;t;)t._call?(n>t._time&&(n=t._time),e=t,t=t._next):(r=t._next,t._next=null,t=e?e._next=r:Lo=r);Xn=e,Qi(n)}function Qi(e){if(!gn){Qn&&(Qn=clearTimeout(Qn));var t=e-Or;t>24?(e<1/0&&(Qn=setTimeout(nd,e-ha.now()-ws)),Ln&&(Ln=clearInterval(Ln))):(Ln||(Do=ha.now(),Ln=setInterval(JO,um)),gn=1,dm(nd))}}function YO(e,t,r){var n=new Bo;return t=t==null?0:+t,n.restart(a=>{n.stop(),e(a+t)},t,r),n}class KO{constructor(t,r,n){this.duration=void 0,this.elapsed=0,this.easingFn=void 0,this.timer=null,this.onTickCallback=void 0,this.duration=t,this.easingFn=r,this.onTickCallback=n,this.resume()}get running(){return this.timer!==null}timerCallback(t){this.elapsed=Math.min(t,this.duration);const r=this.duration===0?1:this.elapsed/this.duration,n=this.easingFn(r);this.onTickCallback(n),this.elapsed>=this.duration&&this.stop()}resume(){if(this.running||this.elapsed>=this.duration)return this;const t=ac()-this.elapsed;return this.timer=hm(r=>this.timerCallback(r),0,t),Ki(),this}stop(){return this.running?(this.timer&&(this.timer.stop(),this.timer=null),this):this}finish(){return this.stop(),YO(()=>this.timerCallback(this.duration)),Ki(),this}}function QO(e,t){if(Object.is(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;const r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(let a=0;a<r.length;a+=1){const o=r[a];if(!Object.prototype.hasOwnProperty.call(t,o)||!Object.is(e[o],t[o]))return!1}return!0}function XO(e,{createInterpolator:t,applyProps:r,skip:n,initialProps:a=e}){const o=B.useRef(a),s=B.useRef(null),i=B.useRef(null),l=B.useRef(e);Nt(()=>{l.current=e},[e]),Nt(()=>{var d;n&&((d=s.current)==null||d.finish(),s.current=null,i.current=null,o.current=e)},[e,n]);const c=B.useCallback(d=>{const h=o.current,p=t(h,e);s.current=new KO(GO,HO,f=>{const m=p(f);o.current=m,r(d,m)})},[r,t,e]);return B.useCallback(d=>{var p,f,m,b;if(d===null){(p=s.current)==null||p.stop();return}const h=i.current;if(h===d){if(QO(l.current,e)){(f=s.current)==null||f.resume();return}(m=s.current)==null||m.stop()}h&&((b=s.current)==null||b.stop()),i.current=d,(s.current||!n)&&c(d)},[c,e,n])}function ZO(e,{createInterpolator:t,transformProps:r,applyProps:n,skip:a,initialProps:o=e,ref:s}){const i=r??(u=>u),l=XO(e,{initialProps:o,createInterpolator:t,applyProps:(u,d)=>n(u,i(d)),skip:a});return Y({},r(a?e:o),{ref:Xh(l,s)})}function ad(e){const{isReversed:t,gradientId:r,size:n,direction:a,scale:o,colorMap:s}=e;return n<=0?null:S.jsx("linearGradient",{id:r,x1:"0",x2:"0",y1:"0",y2:"0",[`${a}${t?1:2}`]:`${n}px`,gradientUnits:"userSpaceOnUse",children:s.thresholds.map((i,l)=>{const c=o(i);if(c===void 0)return null;const u=t?1-c/n:c/n;return Number.isNaN(u)?null:S.jsxs(B.Fragment,{children:[S.jsx("stop",{offset:u,stopColor:s.colors[l],stopOpacity:1}),S.jsx("stop",{offset:u,stopColor:s.colors[l+1],stopOpacity:1})]},i.toString()+l)})})}const ew=10;function od(e){const{gradientUnits:t,isReversed:r,gradientId:n,size:a,direction:o,scale:s,colorScale:i,colorMap:l}=e,c=[l.min??0,l.max??100],u=c.map(s).filter(f=>f!==void 0);if(u.length!==2)return null;const d=typeof c[0]=="number"?Ot(c[0],c[1]):Nl(c[0],c[1]),h=Math.round((Math.max(...u)-Math.min(...u))/ew),p=`${c[0]}-${c[1]}-`;return S.jsx("linearGradient",{id:n,x1:"0",x2:"0",y1:"0",y2:"0",[`${o}${r?1:2}`]:t==="objectBoundingBox"?1:`${a}px`,gradientUnits:t??"userSpaceOnUse",children:Array.from({length:h+1},(f,m)=>{const b=d(m/h);if(b===void 0)return null;const x=s(b);if(x===void 0)return null;const V=r?1-x/a:x/a,O=i(b);return O===null?null:S.jsx("stop",{offset:V,stopColor:O,stopOpacity:1},p+m)})})}const tw=10,rw=e=>e?{x1:"1",x2:"0",y1:"0",y2:"0"}:{x1:"0",x2:"1",y1:"0",y2:"0"};function fi(e){const{isReversed:t,gradientId:r,colorScale:n,colorMap:a}=e,o=[a.min??0,a.max??100],s=typeof o[0]=="number"?Ot(o[0],o[1]):Nl(o[0],o[1]),i=tw,l=`${o[0]}-${o[1]}-`;return S.jsx("linearGradient",Y({id:r},rw(t),{gradientUnits:"objectBoundingBox",children:Array.from({length:i+1},(c,u)=>{const d=u/i,h=s(d);if(h===void 0)return null;const p=n(h);return p===null?null:S.jsx("stop",{offset:d,stopColor:p,stopOpacity:1},l+u)})}))}function nw(){const{top:e,height:t,bottom:r,left:n,width:a,right:o}=lm(),s=e+t+r,i=n+a+o,l=DO(),c=BO(),{xAxis:u,xAxisIds:d}=jO(),{yAxis:h,yAxisIds:p}=kO(),{zAxis:f,zAxisIds:m}=UO(),b=p.filter(O=>h[O].colorMap!==void 0),x=d.filter(O=>u[O].colorMap!==void 0),V=m.filter(O=>f[O].colorMap!==void 0);return b.length===0&&x.length===0&&V.length===0?null:S.jsxs("defs",{children:[b.map(O=>{const C=l(O),P=c(O),{colorMap:w,scale:A,colorScale:E,reverse:F}=h[O];return(w==null?void 0:w.type)==="piecewise"?S.jsx(ad,{isReversed:!F,scale:A,colorMap:w,size:s,gradientId:C,direction:"y"},C):(w==null?void 0:w.type)==="continuous"?S.jsxs(B.Fragment,{children:[S.jsx(od,{isReversed:!F,scale:A,colorScale:E,colorMap:w,size:s,gradientId:C,direction:"y"}),S.jsx(fi,{isReversed:F,colorScale:E,colorMap:w,gradientId:P})]},C):null}),x.map(O=>{const C=l(O),P=c(O),{colorMap:w,scale:A,reverse:E,colorScale:F}=u[O];return(w==null?void 0:w.type)==="piecewise"?S.jsx(ad,{isReversed:E,scale:A,colorMap:w,size:i,gradientId:C,direction:"x"},C):(w==null?void 0:w.type)==="continuous"?S.jsxs(B.Fragment,{children:[S.jsx(od,{isReversed:E,scale:A,colorScale:F,colorMap:w,size:i,gradientId:C,direction:"x"}),S.jsx(fi,{isReversed:E,colorScale:F,colorMap:w,gradientId:P})]},C):null}),V.map(O=>{const C=c(O),{colorMap:P,colorScale:w}=f[O];return(P==null?void 0:P.type)==="continuous"?S.jsx(fi,{colorScale:w,colorMap:P,gradientId:C},C):null})]})}const aw=["children","className","title","desc"],ow=dt("svg",{name:"MuiChartsSurface",slot:"Root"})(({ownerState:e})=>({width:e.width??"100%",height:e.height??"100%",display:"flex",position:"relative",flexDirection:"column",alignItems:"center",justifyContent:"center",overflow:"hidden",touchAction:"pan-y",userSelect:"none"})),oc=B.forwardRef(function(t,r){const n=Er(),{width:a,height:o}=at(n,Gb),{width:s,height:i}=at(n,zb),l=LO(),c=Xh(l,r),u=J0({props:t,name:"MuiChartsSurface"}),{children:d,className:h,title:p,desc:f}=u,m=ar(u,aw),b=o>0&&a>0;return S.jsxs(ow,Y({ownerState:{width:s,height:i},viewBox:`0 0 ${a} ${o}`,className:h},m,{ref:c,children:[p&&S.jsx("title",{children:p}),f&&S.jsx("desc",{children:f}),S.jsx(nw,{}),b&&d]}))});process.env.NODE_ENV!=="production"&&(oc.displayName="ChartsSurface");process.env.NODE_ENV!=="production"&&(oc.propTypes={children:g.node,className:g.string,desc:g.string,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),title:g.string});function Dn(e,t){if(typeof e=="number")return e;if(e==="100%")return t;if(e.endsWith("%")){const r=Number.parseFloat(e.slice(0,e.length-1));if(!Number.isNaN(r))return r*t/100}if(e.endsWith("px")){const r=Number.parseFloat(e.slice(0,e.length-2));if(!Number.isNaN(r))return r}throw new Error(`MUI X Charts: Received an unknown value "${e}". It should be a number, or a string with a percentage value.`)}function gi(e){const t=Yi(e);return[Math.sin(t),-Math.cos(t)]}function sw(e,t){const r=[[0,0],gi(e),gi(t)],n=Math.min(e,t),a=Math.max(e,t),o=Math.floor(n/90)*90;for(let u=1;u<=4;u+=1){const d=o+u*90;d<a&&r.push(gi(d))}const s=Math.min(...r.map(([u])=>u)),i=Math.max(...r.map(([u])=>u)),l=Math.min(...r.map(([,u])=>u)),c=Math.max(...r.map(([,u])=>u));return{cx:-s/(i-s),cy:-l/(c-l),minX:s,maxX:i,minY:l,maxY:c}}function iw(e,t,r,n,{minX:a,maxX:o,minY:s,maxY:i}){return Math.min(...[{ratio:Math.abs(a),space:e},{ratio:Math.abs(o),space:r-e},{ratio:Math.abs(s),space:t},{ratio:Math.abs(i),space:n-t}].map(({ratio:l,space:c})=>l<1e-5?1/0:c/l))}const sc=B.createContext({value:null,valueMin:0,valueMax:0,startAngle:0,endAngle:0,innerRadius:0,outerRadius:0,cornerRadius:0,cx:0,cy:0,maxRadius:0,valueAngle:null});process.env.NODE_ENV!=="production"&&(sc.displayName="GaugeContext");function lw(e){const{value:t=null,valueMin:r=0,valueMax:n=100,startAngle:a=0,endAngle:o=360,outerRadius:s,innerRadius:i,cornerRadius:l,cx:c,cy:u,children:d}=e,{left:h,top:p,width:f,height:m}=lm(),b=sw(a,o),x=c?Dn(c,f):b.cx*f,V=u?Dn(u,m):b.cy*m;let O=h+x,C=p+V;const P=iw(x,V,f,m,b);if(c===void 0){const y=P*(b.maxX-b.minX);O=h+(f-y)/2+b.cx*y}if(u===void 0){const y=P*(b.maxY-b.minY);C=p+(m-y)/2+b.cy*y}const w=Dn(s??P,P),A=Dn(i??"80%",P),E=Dn(l??0,w-A),F=B.useMemo(()=>{const y=Yi(a),T=Yi(o);return{value:t,valueMin:r,valueMax:n,startAngle:y,endAngle:T,outerRadius:w,innerRadius:A,cornerRadius:E,cx:O,cy:C,maxRadius:P,valueAngle:t===null?null:y+(T-y)*(t-r)/(n-r)}},[t,r,n,a,o,w,A,E,O,C,P]);return S.jsx(sc.Provider,{value:F,children:d})}function ic(){return B.useContext(sc)}const cw=["width","height","margin","title","desc","value","valueMin","valueMax","startAngle","endAngle","outerRadius","innerRadius","cornerRadius","cx","cy","children"],uw=dt("g")(({theme:e})=>({"& text":{fill:(e.vars||e).palette.text.primary}})),lc=B.forwardRef(function(t,r){const{width:n,height:a,margin:o,title:s,desc:i,value:l,valueMin:c=0,valueMax:u=100,startAngle:d,endAngle:h,outerRadius:p,innerRadius:f,cornerRadius:m,cx:b,cy:x,children:V}=t,O=ar(t,cw);return S.jsx($O,{pluginParams:{width:n,height:a,margin:op(o,{left:10,right:10,top:10,bottom:10})},plugins:[],children:S.jsx(lw,{value:l,valueMin:c,valueMax:u,startAngle:d,endAngle:h,outerRadius:p,innerRadius:f,cornerRadius:m,cx:b,cy:x,children:S.jsx(oc,Y({title:s,desc:i,role:"meter","aria-valuenow":l===null?void 0:l,"aria-valuemin":c,"aria-valuemax":u},O,{ref:r,children:S.jsx(uw,{"aria-hidden":"true",children:V})}))})})});process.env.NODE_ENV!=="production"&&(lc.displayName="GaugeContainer");process.env.NODE_ENV!=="production"&&(lc.propTypes={children:g.node,className:g.string,cornerRadius:g.oneOfType([g.number,g.string]),cx:g.oneOfType([g.number,g.string]),cy:g.oneOfType([g.number,g.string]),desc:g.string,endAngle:g.number,height:g.number,id:g.string,innerRadius:g.oneOfType([g.number,g.string]),margin:g.oneOfType([g.number,g.shape({bottom:g.number,left:g.number,right:g.number,top:g.number})]),outerRadius:g.oneOfType([g.number,g.string]),skipAnimation:g.bool,startAngle:g.number,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),title:g.string,value:g.number,valueMax:g.number,valueMin:g.number,width:g.number});function dw(e){const t=Er(),r=at(t,vb);return e||r}function hw(e,t){const r=Ot(e.startAngle,t.startAngle),n=Ot(e.endAngle,t.endAngle),a=Ot(e.innerRadius,t.innerRadius),o=Ot(e.outerRadius,t.outerRadius),s=Ot(e.cornerRadius,t.cornerRadius);return i=>({startAngle:r(i),endAngle:n(i),innerRadius:a(i),outerRadius:o(i),cornerRadius:s(i)})}function pw(e){return ZO({startAngle:e.startAngle,endAngle:e.endAngle,innerRadius:e.innerRadius,outerRadius:e.outerRadius,cornerRadius:e.cornerRadius},{createInterpolator:hw,transformProps:t=>({d:em().cornerRadius(t.cornerRadius)({innerRadius:t.innerRadius,outerRadius:t.outerRadius,startAngle:t.startAngle,endAngle:t.endAngle})}),applyProps(t,r){t.setAttribute("d",r.d)},initialProps:{startAngle:e.startAngle,endAngle:e.startAngle,innerRadius:e.innerRadius,outerRadius:e.outerRadius,cornerRadius:e.cornerRadius},skip:e.skipAnimation,ref:e.ref})}const mw=["cx","cy","startAngle","endAngle","cornerRadius","innerRadius","outerRadius","skipAnimation"],fw=dt("path",{name:"MuiGauge",slot:"ReferenceArc"})(({theme:e})=>({fill:(e.vars||e).palette.primary.main}));function pm(e){const{value:t,valueMin:r,valueMax:n,startAngle:a,endAngle:o,outerRadius:s,innerRadius:i,cornerRadius:l,cx:c,cy:u}=ic();if(t===null)return null;const d=a+(t-r)/(n-r)*(o-a);return S.jsx(mm,Y({},e,{cx:c,cy:u,startAngle:a,endAngle:d,cornerRadius:l,innerRadius:i,outerRadius:s}))}process.env.NODE_ENV!=="production"&&(pm.propTypes={skipAnimation:g.bool});function mm(e){let{cx:t,cy:r,startAngle:n,endAngle:a,cornerRadius:o,innerRadius:s,outerRadius:i,skipAnimation:l}=e,c=ar(e,mw);const u=dw(l),d=pw({startAngle:n,endAngle:a,cornerRadius:o,innerRadius:s,outerRadius:i,skipAnimation:u});return S.jsx(fw,Y({},d,{transform:`translate(${t}, ${r})`},c))}process.env.NODE_ENV!=="production"&&(mm.propTypes={cornerRadius:g.number.isRequired,cx:g.number.isRequired,cy:g.number.isRequired,endAngle:g.number.isRequired,innerRadius:g.number.isRequired,outerRadius:g.number.isRequired,skipAnimation:g.bool,startAngle:g.number.isRequired});const gw=dt("path",{name:"MuiGauge",slot:"ReferenceArc"})(({theme:e})=>({fill:(e.vars||e).palette.divider}));function yw(e){const{startAngle:t,endAngle:r,outerRadius:n,innerRadius:a,cornerRadius:o,cx:s,cy:i}=ic();return S.jsx(gw,Y({transform:`translate(${s}, ${i})`,d:em().cornerRadius(o)({startAngle:t,endAngle:r,innerRadius:a,outerRadius:n})},e))}const sd=e=>e,bw=()=>{let e=sd;return{configure(t){e=t},generate(t){return e(t)},reset(){e=sd}}},vw=bw(),Sw={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function fm(e,t,r="Mui"){const n=Sw[t];return n?`${r}-${n}`:`${vw.generate(e)}-${t}`}function xw(e,t,r="Mui"){const n={};return t.forEach(a=>{n[a]=fm(e,a,r)}),n}function Ow(e){return fm("MuiGauge",e)}xw("MuiGauge",["root","valueArc","referenceArc","valueText"]);function ww(){return typeof window>"u"}const Ka=new Map,Cw=2e3,Pw={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},Tw=["minWidth","maxWidth","width","minHeight","maxHeight","height","top","left","fontSize","padding","margin","paddingLeft","paddingRight","paddingTop","paddingBottom","marginLeft","marginRight","marginTop","marginBottom"],id="mui_measurement_span";function gm(e,t){return Tw.indexOf(e)>=0&&t===+t?`${t}px`:t}function ym(e){return e.split("").reduce((n,a)=>a===a.toUpperCase()?[...n,"-",a.toLowerCase()]:[...n,a],[]).join("")}const Aw=e=>Object.keys(e).sort().reduce((t,r)=>`${t}${ym(r)}:${gm(r,e[r])};`,"");let yi;const Rw=(e,t={})=>{if(e==null||ww())return{width:0,height:0};const r=`${e}`,n=Aw(t),a=`${r}-${n}`,o=Ka.get(a);if(o)return o;try{let s=document.getElementById(id);s===null&&(s=document.createElement("span"),s.setAttribute("id",id),s.setAttribute("aria-hidden","true"),document.body.appendChild(s));const i=Y({},Pw,t);Object.keys(i).map(u=>(s.style[ym(u)]=gm(u,i[u]),u)),s.textContent=r;const l=s.getBoundingClientRect(),c={width:l.width,height:l.height};return Ka.set(a,c),Ka.size+1>Cw&&Ka.clear(),process.env.NODE_ENV==="test"?s.textContent="":(yi&&clearTimeout(yi),yi=setTimeout(()=>{s.textContent=""},0)),c}catch{return{width:0,height:0}}};function Vw({style:e,needsComputation:t,text:r}){return r.split(`
|
|
123
|
-
`).map(n=>Y({text:n},t?
|
|
124
|
-
`),text:a}),[u,a,d]);let p;switch(c){case"hanging":case"text-before-edge":p=0;break;case"central":p=(h.length-1)/2*-h[0].height;break;default:p=(h.length-1)*-h[0].height;break}return S.jsx("text",Y({},o,{transform:i?`rotate(${i}, ${t}, ${r})`:void 0,x:t,y:r,textAnchor:l,dominantBaseline:c,style:u,children:h.map((f,m)=>S.jsx("tspan",{x:t,dy:`${m===0?p:h[0].height}px`,dominantBaseline:c,children:f.text},m))}))}process.env.NODE_ENV!=="production"&&(
|
|
125
|
-
Bei einem physischen Roboter bedeutet dies im Allgemeinen, dass ein Freigabeschalter gedrückt werden muss, damit sich der Roboter erfolgreich bewegen kann.`,"SafetyBar.OperationMode.Manual.lb":"Manuell","SafetyBar.OperationMode.ti":"Betriebsmodus","SafetyBar.SafetyState.Error.Explanation.lb":"Die Robotersteuerung ist in einen unerwarteten Sicherheitszustand eingetreten.","SafetyBar.SafetyState.Error.lb":"Fehler","SafetyBar.SafetyState.Estop.lb":"NOT-AUS","SafetyBar.SafetyState.ManualActionRequired.Explanation.lb":"Die Robotersteuerung ist in einen Sicherheitszustand eingetreten, der manuelle Maßnahmen zur Behebung erfordert.","SafetyBar.SafetyState.ManualActionRequired.lb":"Aktion erforderlich","SafetyBar.SafetyState.Normal.Explanation.lb":"Die Robotersteuerung befindet sich in einem sicheren Zustand. Roboterbewegungen sind möglich.","SafetyBar.SafetyState.Normal.lb":"Sicher","SafetyBar.SafetyState.Stop.Explanation.lb":"Die Robotersteuerung ist in einen Stoppzustand übergegangen. Bis der Stoppzustand aufgelöst ist, ist keine Bewegung mehr möglich.","SafetyBar.SafetyState.Stop.lb":"Stopp","SafetyBar.SafetyState.ti":"Sicherheitszustand","SafetyBar.StopState.Estop.Explanation.lb":"NOT-AUS aktiviert. NOT-AUS freischalten, um Roboter zu bewegen.","Jogging.Increment.hlb":"Schrittgröße","Jogging.CoordinateSystem.hlb":"Koordinatensystem","Jogging.Cartesian.bt":"Kartesisch","Jogging.Joints.bt":"Gelenke","Jogging.Velocity.bt":"Geschwindigkeit","CycleTimer.RemainingTime.lb":"Verbleibende Zeit","CycleTimer.OfTime.lb":"von {{time}} min.","CycleTimer.Time.lb":"{{time}} min.","ProgramControl.Start.bt":"Start","ProgramControl.Resume.bt":"Weiter","ProgramControl.Pause.bt":"Pause","ProgramControl.Stop.bt":"Stopp"},Lw={"Jogging.Cartesian.Translation.velocityMmPerSec.lb":"{{amount}} mm/s","Jogging.Cartesian.Rotation.velocityDegPerSec.lb":"{{amount}}°/s","Jogging.Velocity.lb":"Velocity","General.degree.variable":"{{amount}}°","General.mm.variable":"{{amount}} mm","Jogging.Cartesian.MotionType.lb":"Motion type","Jogging.Cartesian.Translation.bt":"Translation","Jogging.Cartesian.Rotation.bt":"Rotation","Jogging.Joints.JointValues.lb":"Joint values","Jogging.Increment.Continuous.dd":"Continuous","Jogging.Cartesian.Orientation.lb":"Orientation","Jogging.Activating.lb":"Activating jogging","Jogging.JointLimitsReached.lb":"Joint limit reached for joint {{jointNumbers}}","Jogging.Orientation.coordsys":"Robot base","Jogging.Orientation.tool":"Tool","SafetyBar.ActivationToggle.Activate.bt":"Activate","SafetyBar.ActivationToggle.Activated.bt":"Activated","SafetyBar.ActivationToggle.Activating.bt":"Activating","SafetyBar.ActivationToggle.Deactivating.bt":"Deactivating","SafetyBar.ControllerType.Physical.lb":"Physical","SafetyBar.ControllerType.Virtual.lb":"Virtual","SafetyBar.MotionGroup.Physical.Explanation.lb":"<code>{{motionGroupId}}</code> is a physical robot controller. <strong>Safety precautions</strong> are active for the movement of this robot.","SafetyBar.MotionGroup.Virtual.Explanation.lb":"<1>{{motionGroupId}}</1> is a virtual robot controller with no physical counterpart. It can be freely manipulated without safety precautions.","SafetyBar.OperationMode.Auto.Explanation.lb":"Automatic operation mode active. Automated movement without manual confirmation enabled.","SafetyBar.OperationMode.Automatic.ti":"Automatic","SafetyBar.OperationMode.Error.Explanation.lb":"Failed to get operation mode. Use the original control panel to resolve the error.","SafetyBar.OperationMode.Error.lb":"Error","SafetyBar.OperationMode.Manual.Explanation.lb":"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.","SafetyBar.OperationMode.Manual.lb":"Manual","SafetyBar.OperationMode.ti":"Operation mode","SafetyBar.SafetyState.Error.Explanation.lb":"The robot controller has entered an unexpected safety state.","SafetyBar.SafetyState.Error.lb":"Error","SafetyBar.SafetyState.Estop.lb":"E-Stop","SafetyBar.SafetyState.ManualActionRequired.Explanation.lb":"The robot controller has entered a safety state requiring manual action to resolve.","SafetyBar.SafetyState.ManualActionRequired.lb":"Action required","SafetyBar.SafetyState.Normal.Explanation.lb":"The robot controller is in a safe state. Robot movement is enabled.","SafetyBar.SafetyState.Normal.lb":"Safe","SafetyBar.SafetyState.Stop.Explanation.lb":"The robot controller has entered a stop state. Movement is no longer possible until the stop state is resolved.","SafetyBar.SafetyState.Stop.lb":"Stop","SafetyBar.SafetyState.ti":"Safety state","SafetyBar.StopState.Estop.Explanation.lb":"An emergency stop of the robot controller has been triggered. Movement of the robot is no longer possible until the estop is released.","Jogging.Increment.hlb":"Increment","Jogging.CoordinateSystem.hlb":"Coordinate system","Jogging.Cartesian.bt":"Cartesian","Jogging.Joints.bt":"Joints","Jogging.Velocity.bt":"Velocity","CycleTimer.RemainingTime.lb":"Time remaining","CycleTimer.OfTime.lb":"of {{time}} min.","CycleTimer.Time.lb":"{{time}} min.","ProgramControl.Start.bt":"Start","ProgramControl.Resume.bt":"Resume","ProgramControl.Pause.bt":"Pause","ProgramControl.Stop.bt":"Stop"},cc=og.createInstance();cc.use(sg).init({supportedLngs:["en","de"],resources:{en:{translations:Lw},de:{translations:Uw}},ns:["translations"],defaultNS:"translations",detection:{order:["navigator","htmlTag"]}});function ur(e){return r=>S.jsx(Dw,{children:S.jsx(e,{...r})})}const Dw=({children:e})=>S.jsx(Ie.I18nextProvider,{i18n:cc,children:e});class uc{constructor(t=[],r={}){this.currentValues=[],this.targetValues=[],this.previousTargetValues=[],this.targetUpdateTime=0,this.animationId=null,this.updateCount=0,this.velocities=[],this.animate=()=>{this.update(.016666666666666666)?this.animationId=null:this.animationId=requestAnimationFrame(this.animate)},this.options={tension:120,friction:20,threshold:.001,onChange:()=>{},onComplete:()=>{},...r},this.currentValues=[...t],this.targetValues=[...t],this.previousTargetValues=[...t],this.velocities=new Array(t.length).fill(0),this.targetUpdateTime=performance.now(),this.updateCount=0}update(t=1/60){let r=!1,n=!0;this.updateCount++;const a=Math.min(t,1/15),o=this.updateCount===1?.7:1;for(let s=0;s<this.currentValues.length;s++){const i=this.currentValues[s],l=this.targetValues[s],c=this.velocities[s],u=l-i,d=u*this.options.tension*o,h=c*this.options.friction,p=d-h,f=c+p*a,m=i+f*a;Math.abs(u)<this.options.threshold&&Math.abs(f)<this.options.threshold*10?this.currentValues[s]!==l&&(this.currentValues[s]=l,this.velocities[s]=0,r=!0):(n=!1,this.currentValues[s]=m,this.velocities[s]=f,r=!0)}return r&&this.options.onChange(this.currentValues),n&&this.options.onComplete(this.currentValues),n}setTarget(t){const r=performance.now(),n=r-this.targetUpdateTime;this.previousTargetValues=[...this.targetValues],this.targetValues=[...t],this.targetUpdateTime=r,this.updateCount=0;const a=this.previousTargetValues.every((o,s)=>o===this.currentValues[s]);if(n<8&&n>0&&this.previousTargetValues.length>0&&!a){const o=Math.min(n/8,1);for(let s=0;s<this.targetValues.length;s++){const i=this.previousTargetValues[s]||0,l=t[s]||0;Math.abs(l-i)>.1&&(this.targetValues[s]=i+(l-i)*o)}}for(;this.currentValues.length<t.length;)this.currentValues.push(t[this.currentValues.length]),this.velocities.push(0);this.currentValues.length>t.length&&(this.currentValues=this.currentValues.slice(0,t.length),this.velocities=this.velocities.slice(0,t.length))}getCurrentValues(){return[...this.currentValues]}getValue(t){return this.currentValues[t]??0}isInterpolating(){return this.animationId!==null}stop(){this.animationId!==null&&(cancelAnimationFrame(this.animationId),this.animationId=null)}setImmediate(t){this.stop(),this.currentValues=[...t],this.targetValues=[...t],this.previousTargetValues=[...t],this.velocities=new Array(t.length).fill(0),this.targetUpdateTime=performance.now(),this.updateCount=0,this.options.onChange(this.currentValues)}updateOptions(t){this.options={...this.options,...t}}startAutoInterpolation(){this.startInterpolation()}destroy(){this.stop()}startInterpolation(){this.animationId===null&&this.animate()}}function Sm(e=[],t={}){const r=ee.useRef(null);return r.current||(r.current=new uc(e,t)),ee.useEffect(()=>{var n;(n=r.current)==null||n.updateOptions(t)},[t]),ee.useEffect(()=>()=>{var n;(n=r.current)==null||n.destroy()},[]),[r.current]}const Bw=ur(je.observer(({onCycleComplete:e,onCycleEnd:t,autoStart:r=!0,variant:n="default",compact:a=!1,className:o})=>{var z,_;const s=J.useTheme(),{t:i}=Ie.useTranslation(),[l,c]=ee.useState(0),[u,d]=ee.useState(0),[h,p]=ee.useState(!1),[f,m]=ee.useState(!1),[b,x]=ee.useState(0),V=ee.useRef(null),O=ee.useRef(null),C=ee.useRef(0),[P]=Sm([0],{tension:80,friction:18,onChange:([N])=>{x(N)}}),w=ee.useCallback((N,te=0)=>{d(N);const Z=Math.max(0,N-te);c(Z),m(!1),C.current=0;const ae=te>0?te/N*100:0;te===0?P.setTarget([0]):P.setTarget([ae]),Z===0?(p(!1),O.current=null,t&&setTimeout(()=>t(),0)):r?(O.current=Date.now()-te*1e3,p(!0)):O.current=null},[r,t,P]),A=ee.useCallback(()=>{if(O.current&&h){const te=Date.now()-O.current;C.current+=te;const Z=C.current/1e3,ae=Math.min(100,Z/u*100);P.setTarget([ae])}p(!1),m(!0)},[h,u,P]),E=ee.useCallback(()=>{f&&l>0&&(O.current=Date.now(),p(!0),m(!1))},[f,l]),F=ee.useCallback(()=>f,[f]);ee.useEffect(()=>{let N=!0;const te=setTimeout(()=>{N&&e({startNewCycle:w,pause:A,resume:E,isPaused:F})},0);return()=>{N=!1,clearTimeout(te)}},[e,w,A,E,F]),ee.useEffect(()=>{if(h){const N=()=>{if(O.current&&u>0){const Z=(Date.now()-O.current+C.current)/1e3,ae=Math.max(0,u-Z);c(Math.ceil(ae));const re=Math.min(100,Z/u*100);if(P.setTarget([re]),ae<=0){p(!1),O.current=null,c(0),P.setTarget([100]),t&&setTimeout(()=>t(),0);return}h&&(V.current=requestAnimationFrame(N))}};V.current=requestAnimationFrame(N)}else V.current&&(cancelAnimationFrame(V.current),V.current=null);return()=>{V.current&&cancelAnimationFrame(V.current)}},[h,t,u,P]),ee.useEffect(()=>{let N=null;const te=()=>{P.update(1/60),N=requestAnimationFrame(te)};return N=requestAnimationFrame(te),()=>{N&&cancelAnimationFrame(N)}},[P]),ee.useEffect(()=>{if(!h&&!f&&u>0){const N=(u-l)/u*100;P.setTarget([N])}},[h,f,u,l,P]);const y=N=>{const te=Math.floor(N/60),Z=N%60;return`${te}:${Z.toString().padStart(2,"0")}`},T=b;return n==="small"?S.jsxs(J.Box,{className:o,sx:{display:"flex",alignItems:"center",gap:.125},children:[S.jsxs(J.Box,{sx:{position:"relative",width:40,height:40,display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"50%",overflow:"visible"},children:[S.jsx(No,{width:40,height:40,value:T,valueMin:0,valueMax:100,innerRadius:"70%",outerRadius:"95%",skipAnimation:!0,sx:{opacity:f?.6:1,transition:"opacity 0.2s ease","& .MuiGauge-valueArc":{fill:s.palette.success.main},"& .MuiGauge-referenceArc":{fill:s.palette.success.main,opacity:.3},"& .MuiGauge-valueText":{display:"none"},"& .MuiGauge-text":{display:"none"},"& text":{display:"none"},"& .MuiGauge-referenceArcBackground":{display:"none"},"& .MuiGauge-valueArcBackground":{display:"none"},"& circle":{display:"none"}}}),S.jsx(J.Box,{sx:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:13,height:13,borderRadius:"50%",backgroundColor:((z=s.palette.background)==null?void 0:z.paper)||"white",pointerEvents:"none"}})]}),S.jsx(J.Typography,{variant:"body2",sx:{color:s.palette.text.primary,fontSize:"14px"},children:a?y(l):`${y(l)} / ${i("CycleTimer.Time.lb",{time:y(u)})}`})]}):S.jsxs(J.Box,{className:o,sx:{position:"relative",width:264,height:264,display:"flex",alignItems:"center",justifyContent:"center"},children:[S.jsx(No,{width:264,height:264,value:T,valueMin:0,valueMax:100,innerRadius:"71%",outerRadius:"90%",skipAnimation:!0,sx:{opacity:f?.6:1,transition:"opacity 0.2s ease","& .MuiGauge-valueArc":{fill:s.palette.success.main},"& .MuiGauge-referenceArc":{fill:"white",stroke:"transparent"}}}),S.jsxs(J.Box,{sx:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:187,height:187,borderRadius:"50%",backgroundColor:(_=s.palette.backgroundPaperElevation)==null?void 0:_[8],display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",textAlign:"center",gap:1},children:[S.jsx(J.Typography,{variant:"body2",sx:{fontSize:"12px",color:s.palette.text.secondary,marginBottom:.5},children:i("CycleTimer.RemainingTime.lb")}),S.jsx(J.Typography,{variant:"h1",sx:{fontSize:"48px",fontWeight:500,color:s.palette.text.primary,lineHeight:1,marginBottom:.5},children:y(l)}),S.jsx(J.Typography,{variant:"body2",sx:{fontSize:"12px",color:s.palette.text.secondary},children:i("CycleTimer.OfTime.lb",{time:y(u)})})]})]})}));process.env.NODE_ENV!=="production"&&(g.node,g.object.isRequired);function dc(e){return t0(e)}const on=m0({createStyledComponent:dt("div",{name:"MuiStack",slot:"Root"}),useThemeProps:e=>dc({props:e,name:"MuiStack"})});process.env.NODE_ENV!=="production"&&(on.propTypes={children:g.node,component:g.elementType,direction:g.oneOfType([g.oneOf(["column-reverse","column","row-reverse","row"]),g.arrayOf(g.oneOf(["column-reverse","column","row-reverse","row"])),g.object]),divider:g.node,spacing:g.oneOfType([g.arrayOf(g.oneOfType([g.number,g.string])),g.number,g.object,g.string]),sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),useFlexGap:g.bool});const Nw=({title:e,titleId:t,...r},n)=>B.createElement("svg",{width:21,height:21,viewBox:"0 0 21 21",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.createElement("g",{id:"JogMinus"},B.createElement("path",{id:"Minus",d:"M0 13V8H21V13H0Z",fill:"white"}))),Fw=ee.forwardRef(Nw),zw=({title:e,titleId:t,...r},n)=>B.createElement("svg",{width:21,height:21,viewBox:"0 0 21 21",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.createElement("g",{id:"JogPlus"},B.createElement("g",{id:"Plus"},B.createElement("path",{d:"M0 13V8H8V13H0Z",fill:"white"}),B.createElement("path",{d:"M8 0L13 2.18557e-07L13 21H8L8 0Z",fill:"white"}),B.createElement("path",{d:"M13 13V8H21V13H13Z",fill:"white"})))),Gw=ee.forwardRef(zw);function Cs(e){ee.useEffect(e,[])}function xm(e){Cs(()=>Be.autorun(e))}function Om(e,t,r){Cs(()=>Be.reaction(e,t,r))}function xn(e){return Cs(()=>{let t;function r(){e(),t=requestAnimationFrame(r)}return t=requestAnimationFrame(r),()=>{cancelAnimationFrame(t)}})}const Xi=ur(je.observer(({colors:e,label:t,getDisplayedValue:r,startJogging:n,stopJogging:a,disabled:o,activeJoggingDirection:s,...i})=>{var O,C,P,w,A,E,F;xn(()=>{const y=r(),T=h.current;T&&(T.textContent=y)});const l=J.useTheme(),[c,u]=ee.useState(null);ee.useEffect(()=>{o&&V()},[o]);const d=s||c,h=ee.useRef(null);e||(e={color:"#fff",backgroundColor:"#000",borderColor:"#000",buttonBackgroundColor:{disabled:"#000",default:"#000",hovered:"#000",pressed:"#000"},labelColor:"#000"});const p=d?(O=e.buttonBackgroundColor)==null?void 0:O.pressed:e.borderColor,f={width:"55px",color:e.color,path:{fill:e.color},alignContent:"center",fontSize:"37px",svg:{pointerEvents:"none"}},m={...f,backgroundColor:(C=e.buttonBackgroundColor)==null?void 0:C.default,":hover":{backgroundColor:(P=e.buttonBackgroundColor)==null?void 0:P.hovered},":active":{backgroundColor:(w=e.buttonBackgroundColor)==null?void 0:w.pressed,color:e.backgroundColor,path:{fill:e.backgroundColor}},":disabled":{backgroundColor:(A=e.buttonBackgroundColor)==null?void 0:A.disabled,"svg path":{fill:l.palette.action.disabled}}},b={...f,backgroundColor:(E=e.buttonBackgroundColor)==null?void 0:E.pressed,color:e.backgroundColor,path:{fill:e.backgroundColor},":disabled":{backgroundColor:(F=e.buttonBackgroundColor)==null?void 0:F.pressed,"svg path":{fill:l.palette.action.disabled}}};function x(y,T){o||y.button===0&&(u(T),n(T))}function V(){u(null),a()}return S.jsxs(on,{height:"64px",direction:"row",justifyContent:"center",...i,children:[S.jsx(J.IconButton,{disabled:o,disableRipple:!0,onPointerDown:y=>x(y,"-"),onPointerUp:V,onPointerOut:V,size:"large",sx:{...d==="-"?b:m,borderRadius:"16px 0px 0px 16px",borderLeft:`2px solid ${p??"#fff"}`,borderBottom:`2px solid ${p??"#fff"}`,borderTop:`2px solid ${p??"#fff"}`},children:S.jsx(Fw,{})}),S.jsxs(on,{spacing:"6px",sx:{width:"150px",backgroundColor:e.backgroundColor,alignItems:"center",justifyContent:"center",opacity:"0.9",borderBottom:`2px solid ${p??"#fff"}`,borderTop:`2px solid ${p??"#fff"}`},children:[S.jsx(on,{height:"22px",direction:"row",alignItems:"center",justifyItems:"center",spacing:1,sx:{userSelect:"none",color:e.color,".MuiTypography-root":{fontWeight:700,...o?{color:l.palette.action.disabled}:{}},...o?{"svg path":{fill:l.palette.action.disabled}}:{}},children:t}),S.jsx(J.Typography,{height:"22px",sx:{fontSize:"15px",color:o?l.palette.action.disabled:e.color,fontWeight:700},ref:h,children:r()})]}),S.jsx(J.IconButton,{disableRipple:!0,disabled:o,onPointerDown:y=>x(y,"+"),onPointerUp:V,onPointerOut:V,size:"large",sx:{...d==="+"?b:m,borderRadius:"0px 16px 16px 0px",borderRight:`2px solid ${p??"#fff"}`,borderBottom:`2px solid ${p??"#fff"}`,borderTop:`2px solid ${p??"#fff"}`},children:S.jsx(Gw,{})})]})})),Ir=r0;function Hw(e){return xa("MuiSvgIcon",e)}kh("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const qw=e=>{const{color:t,fontSize:r,classes:n}=e,a={root:["root",t!=="inherit"&&`color${Ze(t)}`,`fontSize${Ze(r)}`]};return wl(a,Hw,n)},Jw=dt("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.color!=="inherit"&&t[`color${Ze(r.color)}`],t[`fontSize${Ze(r.fontSize)}`]]}})(Ir(({theme:e})=>{var t,r,n,a,o,s,i,l,c,u,d,h,p,f;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:(a=(t=e.transitions)==null?void 0:t.create)==null?void 0:a.call(t,"fill",{duration:(n=(r=(e.vars??e).transitions)==null?void 0:r.duration)==null?void 0:n.shorter}),variants:[{props:m=>!m.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:((s=(o=e.typography)==null?void 0:o.pxToRem)==null?void 0:s.call(o,20))||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:((l=(i=e.typography)==null?void 0:i.pxToRem)==null?void 0:l.call(i,24))||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:((u=(c=e.typography)==null?void 0:c.pxToRem)==null?void 0:u.call(c,35))||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,m])=>m&&m.main).map(([m])=>{var b,x;return{props:{color:m},style:{color:(x=(b=(e.vars??e).palette)==null?void 0:b[m])==null?void 0:x.main}}}),{props:{color:"action"},style:{color:(h=(d=(e.vars??e).palette)==null?void 0:d.action)==null?void 0:h.active}},{props:{color:"disabled"},style:{color:(f=(p=(e.vars??e).palette)==null?void 0:p.action)==null?void 0:f.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),Fo=B.forwardRef(function(t,r){const n=dc({props:t,name:"MuiSvgIcon"}),{children:a,className:o,color:s="inherit",component:i="svg",fontSize:l="medium",htmlColor:c,inheritViewBox:u=!1,titleAccess:d,viewBox:h="0 0 24 24",...p}=n,f=B.isValidElement(a)&&a.type==="svg",m={...n,color:s,component:i,fontSize:l,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:h,hasSvgAsChild:f},b={};u||(b.viewBox=h);const x=qw(m);return S.jsxs(Jw,{as:i,className:Et(x.root,o),focusable:"false",color:c,"aria-hidden":d?void 0:!0,role:d?"img":void 0,ref:r,...b,...p,...f&&a.props,ownerState:m,children:[f?a.props.children:a,d?S.jsx("title",{children:d}):null]})});process.env.NODE_ENV!=="production"&&(Fo.propTypes={children:g.node,classes:g.object,className:g.string,color:g.oneOfType([g.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),g.string]),component:g.elementType,fontSize:g.oneOfType([g.oneOf(["inherit","large","medium","small"]),g.string]),htmlColor:g.string,inheritViewBox:g.bool,shapeRendering:g.string,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),titleAccess:g.string,viewBox:g.string});Fo.muiName="SvgIcon";function Ps(e,t){function r(n,a){return S.jsx(Fo,{"data-testid":process.env.NODE_ENV!=="production"?`${t}Icon`:void 0,ref:a,...n,children:e})}return process.env.NODE_ENV!=="production"&&(r.displayName=`${t}Icon`),r.muiName=Fo.muiName,B.memo(B.forwardRef(r))}function go(e){return e&&e.ownerDocument||document}function Ww(e){const{controlled:t,default:r,name:n,state:a="value"}=e,{current:o}=B.useRef(t!==void 0),[s,i]=B.useState(r),l=o?t:s;if(process.env.NODE_ENV!=="production"){B.useEffect(()=>{o!==(t!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${a} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(`
|
|
126
|
-
`))},[a,n,t]);const{current:u}=
|
|
127
|
-
`))},[JSON.stringify(r)])}const c=B.useCallback(u=>{o||i(u)},[]);return[l,c]}function bi(e){const t=B.useRef(e);return zh(()=>{t.current=e}),B.useRef((...r)=>(0,t.current)(...r)).current}function wm(...e){const t=B.useRef(void 0),r=B.useCallback(n=>{const a=e.map(o=>{if(o==null)return null;if(typeof o=="function"){const s=o,i=s(n);return typeof i=="function"?i:()=>{s(null)}}return o.current=n,()=>{o.current=null}});return()=>{a.forEach(o=>o==null?void 0:o())}},e);return B.useMemo(()=>e.every(n=>n==null)?null:n=>{t.current&&(t.current(),t.current=void 0),n!=null&&(t.current=r(n))},e)}const Yw=Ps(S.jsx("path",{d:"M15.41 7.41 14 6l-6 6 6 6 1.41-1.41L10.83 12z"}),"ChevronLeft"),Kw=Ps(S.jsx("path",{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}),"ChevronRight");function wr(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Cm=typeof global=="object"&&global&&global.Object===Object&&global,Qw=typeof self=="object"&&self&&self.Object===Object&&self,$t=Cm||Qw||Function("return this")(),vi=function(){return $t.Date.now()},Xw=/\s/;function Zw(e){for(var t=e.length;t--&&Xw.test(e.charAt(t)););return t}var eC=/^\s+/;function tC(e){return e&&e.slice(0,Zw(e)+1).replace(eC,"")}var ir=$t.Symbol,Pm=Object.prototype,rC=Pm.hasOwnProperty,nC=Pm.toString,Bn=ir?ir.toStringTag:void 0;function aC(e){var t=rC.call(e,Bn),r=e[Bn];try{e[Bn]=void 0;var n=!0}catch{}var a=nC.call(e);return n&&(t?e[Bn]=r:delete e[Bn]),a}var oC=Object.prototype,sC=oC.toString;function iC(e){return sC.call(e)}var lC="[object Null]",cC="[object Undefined]",ld=ir?ir.toStringTag:void 0;function Mr(e){return e==null?e===void 0?cC:lC:ld&&ld in Object(e)?aC(e):iC(e)}function Cr(e){return e!=null&&typeof e=="object"}var uC="[object Symbol]";function Ts(e){return typeof e=="symbol"||Cr(e)&&Mr(e)==uC}var cd=NaN,dC=/^[-+]0x[0-9a-f]+$/i,hC=/^0b[01]+$/i,pC=/^0o[0-7]+$/i,mC=parseInt;function ud(e){if(typeof e=="number")return e;if(Ts(e))return cd;if(wr(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=wr(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=tC(e);var r=hC.test(e);return r||pC.test(e)?mC(e.slice(2),r?2:8):dC.test(e)?cd:+e}var fC="Expected a function",gC=Math.max,yC=Math.min;function bC(e,t,r){var n,a,o,s,i,l,c=0,u=!1,d=!1,h=!0;if(typeof e!="function")throw new TypeError(fC);t=ud(t)||0,wr(r)&&(u=!!r.leading,d="maxWait"in r,o=d?gC(ud(r.maxWait)||0,t):o,h="trailing"in r?!!r.trailing:h);function p(w){var A=n,E=a;return n=a=void 0,c=w,s=e.apply(E,A),s}function f(w){return c=w,i=setTimeout(x,t),u?p(w):s}function m(w){var A=w-l,E=w-c,F=t-A;return d?yC(F,o-E):F}function b(w){var A=w-l,E=w-c;return l===void 0||A>=t||A<0||d&&E>=o}function x(){var w=vi();if(b(w))return V(w);i=setTimeout(x,m(w))}function V(w){return i=void 0,h&&n?p(w):(n=a=void 0,s)}function O(){i!==void 0&&clearTimeout(i),c=0,n=l=a=i=void 0}function C(){return i===void 0?s:V(vi())}function P(){var w=vi(),A=b(w);if(n=arguments,a=this,l=w,A){if(i===void 0)return f(l);if(d)return clearTimeout(i),i=setTimeout(x,t),p(l)}return i===void 0&&(i=setTimeout(x,t)),s}return P.cancel=O,P.flush=C,P}var vC="Expected a function";function SC(e,t,r){var n=!0,a=!0;if(typeof e!="function")throw new TypeError(vC);return wr(r)&&(n="leading"in r?!!r.leading:n,a="trailing"in r?!!r.trailing:a),bC(e,t,{leading:n,maxWait:t,trailing:a})}const Tm=ur(je.observer(({startJogging:e,stopJogging:t,lowerLimitDegs:r,upperLimitDegs:n,getValueDegs:a,disabled:o,...s})=>{var O,C,P,w,A,E,F,y,T,z,_,N,te,Z,ae;const{t:i}=Ie.useTranslation(),[l,c]=ee.useState(),u=J.useTheme(),d={background:(O=u.palette.backgroundPaperElevation)==null?void 0:O[4],color:(C=u.palette.backgroundPaperElevation)==null?void 0:C[11]},h=je.useLocalObservable(()=>({activeJoggingDir:null,startJogging(re){this.activeJoggingDir=re,e(re)},stopJogging(){this.activeJoggingDir=null,t()}})),p=SC(()=>{c(a())},50);xn(p);function f(re){re.button===0&&h.startJogging("-")}function m(re){re.button===0&&h.startJogging("+")}function b(re){h.stopJogging()}function x(re){h.stopJogging()}function V(re,le=1){if(re===void 0||isNaN(re))return"";const q=i("General.degree.variable",{amount:re.toFixed(le)});return re>0&&le===0?`+${q}`:q}return S.jsxs(on,{height:"64px",width:"100%",maxWidth:"260px",direction:"row",...s,sx:{"& .MuiIconButton-root":{width:"52px",color:u.palette.text.primary,alignContent:"center",backgroundColor:(P=u.palette.backgroundPaperElevation)==null?void 0:P[11],"& svg":{width:"42px",height:"42px"},"&.Mui-disabled":{backgroundColor:(w=u.palette.backgroundPaperElevation)==null?void 0:w[11],color:u.palette.action.disabled,opacity:1},"&:hover":{backgroundColor:(A=u.palette.backgroundPaperElevation)==null?void 0:A[9]},"&:active":{...d}}},children:[S.jsx(J.IconButton,{onPointerDown:f,onPointerUp:b,onPointerOut:x,disabled:o,disableRipple:!0,sx:{borderRadius:"16px 0px 0px 16px",...h.activeJoggingDir==="-"?d:{}},children:S.jsx(Yw,{sx:{pointerEvents:"none",color:(T=(y=(F=(E=u.componentsExt)==null?void 0:E.JoggingPanel)==null?void 0:F.JoggingJoint)==null?void 0:y.Joint)==null?void 0:T.arrowColor}})}),S.jsxs(on,{flexGrow:1,alignItems:"center",justifyContent:"center",sx:{borderStyle:"solid",borderLeftWidth:0,borderRightWidth:0,border:"none",backgroundColor:(z=u.palette.backgroundPaperElevation)==null?void 0:z[11],paddingLeft:"20px",paddingRight:"20px",zIndex:1},children:[S.jsx(J.Typography,{sx:{fontSize:"15px",fontWeight:700,position:"relative",top:"5px",color:o?u.palette.action.disabled:u.palette.text.primary},children:V(l)}),S.jsx(J.Slider,{disabled:!0,"aria-label":"Joint position",min:r,max:n,value:l||0,track:!1,sx:{"& .MuiSlider-mark":{display:"none"},"& .MuiSlider-thumb":{width:"5px",height:"12px",borderRadius:"2px",color:o?u.palette.action.disabled:u.palette.text.primary},"& .MuiSlider-markLabel":{top:"20px",fontSize:"12px",color:o?u.palette.action.disabled:u.palette.text.secondary},"& .MuiSlider-rail":{backgroundColor:(_=u.palette.backgroundPaperElevation)==null?void 0:_[5],opacity:1}},marks:r!==void 0&&n!==void 0&&[{value:r,label:V(r,0)},{value:n,label:V(n,0)}]})]}),S.jsx(J.IconButton,{onPointerDown:m,onPointerUp:b,onPointerOut:x,disabled:o,disableRipple:!0,sx:{borderRadius:"0px 16px 16px 0px",...h.activeJoggingDir==="+"?d:{}},children:S.jsx(Kw,{sx:{pointerEvents:"none",color:(ae=(Z=(te=(N=u.componentsExt)==null?void 0:N.JoggingPanel)==null?void 0:te.JoggingJoint)==null?void 0:Z.Joint)==null?void 0:ae.arrowColor}})})]})})),xC=Ps(S.jsx("path",{d:"M10 9h4V6h3l-5-5-5 5h3zm-1 1H6V7l-5 5 5 5v-3h3zm14 2-5-5v3h-3v4h3v3zm-9 3h-4v3H7l5 5 5-5h-3z"}),"OpenWith"),OC=Ps(S.jsx("path",{d:"M18 16.08c-.76 0-1.44.3-1.96.77L8.91 12.7c.05-.23.09-.46.09-.7s-.04-.47-.09-.7l7.05-4.11c.54.5 1.25.81 2.04.81 1.66 0 3-1.34 3-3s-1.34-3-3-3-3 1.34-3 3c0 .24.04.47.09.7L8.04 9.81C7.5 9.31 6.79 9 6 9c-1.66 0-3 1.34-3 3s1.34 3 3 3c.79 0 1.5-.31 2.04-.81l7.12 4.16c-.05.21-.08.43-.08.65 0 1.61 1.31 2.92 2.92 2.92s2.92-1.31 2.92-2.92-1.31-2.92-2.92-2.92"}),"Share");function wC(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Am=wC;function CC(){this.__data__=[],this.size=0}var PC=CC;function TC(e,t){return e===t||e!==e&&t!==t}var Rm=TC;function AC(e,t){for(var r=e.length;r--;)if(Rm(e[r][0],t))return r;return-1}var As=AC,RC=Array.prototype,VC=RC.splice;function _C(e){var t=this.__data__,r=As(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():VC.call(t,r,1),--this.size,!0}var EC=_C;function IC(e){var t=this.__data__,r=As(t,e);return r<0?void 0:t[r][1]}var MC=IC;function $C(e){return As(this.__data__,e)>-1}var jC=$C;function kC(e,t){var r=this.__data__,n=As(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}var UC=kC;function On(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}On.prototype.clear=PC;On.prototype.delete=EC;On.prototype.get=MC;On.prototype.has=jC;On.prototype.set=UC;var Rs=On;function LC(){this.__data__=new Rs,this.size=0}var DC=LC;function BC(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}var NC=BC;function FC(e){return this.__data__.get(e)}var zC=FC;function GC(e){return this.__data__.has(e)}var HC=GC,qC=typeof global=="object"&&global&&global.Object===Object&&global,Vm=qC,JC=typeof self=="object"&&self&&self.Object===Object&&self,WC=Vm||JC||Function("return this")(),Jt=WC,YC=Jt.Symbol,yn=YC,_m=Object.prototype,KC=_m.hasOwnProperty,QC=_m.toString,Nn=yn?yn.toStringTag:void 0;function XC(e){var t=KC.call(e,Nn),r=e[Nn];try{e[Nn]=void 0;var n=!0}catch{}var a=QC.call(e);return n&&(t?e[Nn]=r:delete e[Nn]),a}var ZC=XC,eP=Object.prototype,tP=eP.toString;function rP(e){return tP.call(e)}var nP=rP,aP="[object Null]",oP="[object Undefined]",dd=yn?yn.toStringTag:void 0;function sP(e){return e==null?e===void 0?oP:aP:dd&&dd in Object(e)?ZC(e):nP(e)}var Ra=sP,iP="[object AsyncFunction]",lP="[object Function]",cP="[object GeneratorFunction]",uP="[object Proxy]";function dP(e){if(!Am(e))return!1;var t=Ra(e);return t==lP||t==cP||t==iP||t==uP}var Em=dP,hP=Jt["__core-js_shared__"],Si=hP,hd=function(){var e=/[^.]+$/.exec(Si&&Si.keys&&Si.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function pP(e){return!!hd&&hd in e}var mP=pP,fP=Function.prototype,gP=fP.toString;function yP(e){if(e!=null){try{return gP.call(e)}catch{}try{return e+""}catch{}}return""}var $r=yP,bP=/[\\^$.*+?()[\]{}|]/g,vP=/^\[object .+?Constructor\]$/,SP=Function.prototype,xP=Object.prototype,OP=SP.toString,wP=xP.hasOwnProperty,CP=RegExp("^"+OP.call(wP).replace(bP,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function PP(e){if(!Am(e)||mP(e))return!1;var t=Em(e)?CP:vP;return t.test($r(e))}var TP=PP;function AP(e,t){return e==null?void 0:e[t]}var RP=AP;function VP(e,t){var r=RP(e,t);return TP(r)?r:void 0}var wn=VP,_P=wn(Jt,"Map"),pa=_P,EP=wn(Object,"create"),ma=EP;function IP(){this.__data__=ma?ma(null):{},this.size=0}var MP=IP;function $P(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var jP=$P,kP="__lodash_hash_undefined__",UP=Object.prototype,LP=UP.hasOwnProperty;function DP(e){var t=this.__data__;if(ma){var r=t[e];return r===kP?void 0:r}return LP.call(t,e)?t[e]:void 0}var BP=DP,NP=Object.prototype,FP=NP.hasOwnProperty;function zP(e){var t=this.__data__;return ma?t[e]!==void 0:FP.call(t,e)}var GP=zP,HP="__lodash_hash_undefined__";function qP(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=ma&&t===void 0?HP:t,this}var JP=qP;function Cn(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Cn.prototype.clear=MP;Cn.prototype.delete=jP;Cn.prototype.get=BP;Cn.prototype.has=GP;Cn.prototype.set=JP;var pd=Cn;function WP(){this.size=0,this.__data__={hash:new pd,map:new(pa||Rs),string:new pd}}var YP=WP;function KP(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var QP=KP;function XP(e,t){var r=e.__data__;return QP(t)?r[typeof t=="string"?"string":"hash"]:r.map}var Vs=XP;function ZP(e){var t=Vs(this,e).delete(e);return this.size-=t?1:0,t}var eT=ZP;function tT(e){return Vs(this,e).get(e)}var rT=tT;function nT(e){return Vs(this,e).has(e)}var aT=nT;function oT(e,t){var r=Vs(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}var sT=oT;function Pn(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Pn.prototype.clear=YP;Pn.prototype.delete=eT;Pn.prototype.get=rT;Pn.prototype.has=aT;Pn.prototype.set=sT;var Im=Pn,iT=200;function lT(e,t){var r=this.__data__;if(r instanceof Rs){var n=r.__data__;if(!pa||n.length<iT-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new Im(n)}return r.set(e,t),this.size=r.size,this}var cT=lT;function Tn(e){var t=this.__data__=new Rs(e);this.size=t.size}Tn.prototype.clear=DC;Tn.prototype.delete=NC;Tn.prototype.get=zC;Tn.prototype.has=HC;Tn.prototype.set=cT;var xi=Tn,uT="__lodash_hash_undefined__";function dT(e){return this.__data__.set(e,uT),this}var hT=dT;function pT(e){return this.__data__.has(e)}var mT=pT;function zo(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new Im;++t<r;)this.add(e[t])}zo.prototype.add=zo.prototype.push=hT;zo.prototype.has=mT;var fT=zo;function gT(e,t){for(var r=-1,n=e==null?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}var yT=gT;function bT(e,t){return e.has(t)}var vT=bT,ST=1,xT=2;function OT(e,t,r,n,a,o){var s=r&ST,i=e.length,l=t.length;if(i!=l&&!(s&&l>i))return!1;var c=o.get(e),u=o.get(t);if(c&&u)return c==t&&u==e;var d=-1,h=!0,p=r&xT?new fT:void 0;for(o.set(e,t),o.set(t,e);++d<i;){var f=e[d],m=t[d];if(n)var b=s?n(m,f,d,t,e,o):n(f,m,d,e,t,o);if(b!==void 0){if(b)continue;h=!1;break}if(p){if(!yT(t,function(x,V){if(!vT(p,V)&&(f===x||a(f,x,r,n,o)))return p.push(V)})){h=!1;break}}else if(!(f===m||a(f,m,r,n,o))){h=!1;break}}return o.delete(e),o.delete(t),h}var Mm=OT,wT=Jt.Uint8Array,md=wT;function CT(e){var t=-1,r=Array(e.size);return e.forEach(function(n,a){r[++t]=[a,n]}),r}var PT=CT;function TT(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var AT=TT,RT=1,VT=2,_T="[object Boolean]",ET="[object Date]",IT="[object Error]",MT="[object Map]",$T="[object Number]",jT="[object RegExp]",kT="[object Set]",UT="[object String]",LT="[object Symbol]",DT="[object ArrayBuffer]",BT="[object DataView]",fd=yn?yn.prototype:void 0,Oi=fd?fd.valueOf:void 0;function NT(e,t,r,n,a,o,s){switch(r){case BT:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case DT:return!(e.byteLength!=t.byteLength||!o(new md(e),new md(t)));case _T:case ET:case $T:return Rm(+e,+t);case IT:return e.name==t.name&&e.message==t.message;case jT:case UT:return e==t+"";case MT:var i=PT;case kT:var l=n&RT;if(i||(i=AT),e.size!=t.size&&!l)return!1;var c=s.get(e);if(c)return c==t;n|=VT,s.set(e,t);var u=Mm(i(e),i(t),n,a,o,s);return s.delete(e),u;case LT:if(Oi)return Oi.call(e)==Oi.call(t)}return!1}var FT=NT;function zT(e,t){for(var r=-1,n=t.length,a=e.length;++r<n;)e[a+r]=t[r];return e}var GT=zT,HT=Array.isArray,Go=HT;function qT(e,t,r){var n=t(e);return Go(e)?n:GT(n,r(e))}var JT=qT;function WT(e,t){for(var r=-1,n=e==null?0:e.length,a=0,o=[];++r<n;){var s=e[r];t(s,r,e)&&(o[a++]=s)}return o}var YT=WT;function KT(){return[]}var QT=KT,XT=Object.prototype,ZT=XT.propertyIsEnumerable,gd=Object.getOwnPropertySymbols,eA=gd?function(e){return e==null?[]:(e=Object(e),YT(gd(e),function(t){return ZT.call(e,t)}))}:QT,tA=eA;function rA(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var nA=rA;function aA(e){return e!=null&&typeof e=="object"}var fa=aA,oA="[object Arguments]";function sA(e){return fa(e)&&Ra(e)==oA}var yd=sA,$m=Object.prototype,iA=$m.hasOwnProperty,lA=$m.propertyIsEnumerable,cA=yd(function(){return arguments}())?yd:function(e){return fa(e)&&iA.call(e,"callee")&&!lA.call(e,"callee")},uA=cA;function dA(){return!1}var hA=dA,jm=typeof exports=="object"&&exports&&!exports.nodeType&&exports,bd=jm&&typeof module=="object"&&module&&!module.nodeType&&module,pA=bd&&bd.exports===jm,vd=pA?Jt.Buffer:void 0,mA=vd?vd.isBuffer:void 0,fA=mA||hA,Zi=fA,gA=9007199254740991,yA=/^(?:0|[1-9]\d*)$/;function bA(e,t){var r=typeof e;return t=t??gA,!!t&&(r=="number"||r!="symbol"&&yA.test(e))&&e>-1&&e%1==0&&e<t}var vA=bA,SA=9007199254740991;function xA(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=SA}var km=xA,OA="[object Arguments]",wA="[object Array]",CA="[object Boolean]",PA="[object Date]",TA="[object Error]",AA="[object Function]",RA="[object Map]",VA="[object Number]",_A="[object Object]",EA="[object RegExp]",IA="[object Set]",MA="[object String]",$A="[object WeakMap]",jA="[object ArrayBuffer]",kA="[object DataView]",UA="[object Float32Array]",LA="[object Float64Array]",DA="[object Int8Array]",BA="[object Int16Array]",NA="[object Int32Array]",FA="[object Uint8Array]",zA="[object Uint8ClampedArray]",GA="[object Uint16Array]",HA="[object Uint32Array]",Te={};Te[UA]=Te[LA]=Te[DA]=Te[BA]=Te[NA]=Te[FA]=Te[zA]=Te[GA]=Te[HA]=!0;Te[OA]=Te[wA]=Te[jA]=Te[CA]=Te[kA]=Te[PA]=Te[TA]=Te[AA]=Te[RA]=Te[VA]=Te[_A]=Te[EA]=Te[IA]=Te[MA]=Te[$A]=!1;function qA(e){return fa(e)&&km(e.length)&&!!Te[Ra(e)]}var JA=qA;function WA(e){return function(t){return e(t)}}var YA=WA,Um=typeof exports=="object"&&exports&&!exports.nodeType&&exports,ta=Um&&typeof module=="object"&&module&&!module.nodeType&&module,KA=ta&&ta.exports===Um,wi=KA&&Vm.process,QA=function(){try{var e=ta&&ta.require&&ta.require("util").types;return e||wi&&wi.binding&&wi.binding("util")}catch{}}(),Sd=QA,xd=Sd&&Sd.isTypedArray,XA=xd?YA(xd):JA,Lm=XA,ZA=Object.prototype,eR=ZA.hasOwnProperty;function tR(e,t){var r=Go(e),n=!r&&uA(e),a=!r&&!n&&Zi(e),o=!r&&!n&&!a&&Lm(e),s=r||n||a||o,i=s?nA(e.length,String):[],l=i.length;for(var c in e)(t||eR.call(e,c))&&!(s&&(c=="length"||a&&(c=="offset"||c=="parent")||o&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||vA(c,l)))&&i.push(c);return i}var rR=tR,nR=Object.prototype;function aR(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||nR;return e===r}var oR=aR;function sR(e,t){return function(r){return e(t(r))}}var iR=sR,lR=iR(Object.keys,Object),cR=lR,uR=Object.prototype,dR=uR.hasOwnProperty;function hR(e){if(!oR(e))return cR(e);var t=[];for(var r in Object(e))dR.call(e,r)&&r!="constructor"&&t.push(r);return t}var pR=hR;function mR(e){return e!=null&&km(e.length)&&!Em(e)}var fR=mR;function gR(e){return fR(e)?rR(e):pR(e)}var yR=gR;function bR(e){return JT(e,yR,tA)}var Od=bR,vR=1,SR=Object.prototype,xR=SR.hasOwnProperty;function OR(e,t,r,n,a,o){var s=r&vR,i=Od(e),l=i.length,c=Od(t),u=c.length;if(l!=u&&!s)return!1;for(var d=l;d--;){var h=i[d];if(!(s?h in t:xR.call(t,h)))return!1}var p=o.get(e),f=o.get(t);if(p&&f)return p==t&&f==e;var m=!0;o.set(e,t),o.set(t,e);for(var b=s;++d<l;){h=i[d];var x=e[h],V=t[h];if(n)var O=s?n(V,x,h,t,e,o):n(x,V,h,e,t,o);if(!(O===void 0?x===V||a(x,V,r,n,o):O)){m=!1;break}b||(b=h=="constructor")}if(m&&!b){var C=e.constructor,P=t.constructor;C!=P&&"constructor"in e&&"constructor"in t&&!(typeof C=="function"&&C instanceof C&&typeof P=="function"&&P instanceof P)&&(m=!1)}return o.delete(e),o.delete(t),m}var wR=OR,CR=wn(Jt,"DataView"),el=CR,PR=wn(Jt,"Promise"),tl=PR,TR=wn(Jt,"Set"),rl=TR,AR=wn(Jt,"WeakMap"),nl=AR,wd="[object Map]",RR="[object Object]",Cd="[object Promise]",Pd="[object Set]",Td="[object WeakMap]",Ad="[object DataView]",VR=$r(el),_R=$r(pa),ER=$r(tl),IR=$r(rl),MR=$r(nl),mr=Ra;(el&&mr(new el(new ArrayBuffer(1)))!=Ad||pa&&mr(new pa)!=wd||tl&&mr(tl.resolve())!=Cd||rl&&mr(new rl)!=Pd||nl&&mr(new nl)!=Td)&&(mr=function(e){var t=Ra(e),r=t==RR?e.constructor:void 0,n=r?$r(r):"";if(n)switch(n){case VR:return Ad;case _R:return wd;case ER:return Cd;case IR:return Pd;case MR:return Td}return t});var Rd=mr,$R=1,Vd="[object Arguments]",_d="[object Array]",Qa="[object Object]",jR=Object.prototype,Ed=jR.hasOwnProperty;function kR(e,t,r,n,a,o){var s=Go(e),i=Go(t),l=s?_d:Rd(e),c=i?_d:Rd(t);l=l==Vd?Qa:l,c=c==Vd?Qa:c;var u=l==Qa,d=c==Qa,h=l==c;if(h&&Zi(e)){if(!Zi(t))return!1;s=!0,u=!1}if(h&&!u)return o||(o=new xi),s||Lm(e)?Mm(e,t,r,n,a,o):FT(e,t,l,r,n,a,o);if(!(r&$R)){var p=u&&Ed.call(e,"__wrapped__"),f=d&&Ed.call(t,"__wrapped__");if(p||f){var m=p?e.value():e,b=f?t.value():t;return o||(o=new xi),a(m,b,r,n,o)}}return h?(o||(o=new xi),wR(e,t,r,n,a,o)):!1}var UR=kR;function Dm(e,t,r,n,a){return e===t?!0:e==null||t==null||!fa(e)&&!fa(t)?e!==e&&t!==t:UR(e,t,r,n,Dm,a)}var LR=Dm;function DR(e,t){return LR(e,t)}var BR=DR;/*! *****************************************************************************
|
|
114
|
+
*/var ou;function Rb(){return ou||(ou=1,process.env.NODE_ENV!=="production"&&function(){function e(c,u){return c===u&&(c!==0||1/c===1/u)||c!==c&&u!==u}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var t=ee,r=rp(),n=typeof Object.is=="function"?Object.is:e,a=r.useSyncExternalStore,o=t.useRef,s=t.useEffect,i=t.useMemo,l=t.useDebugValue;ti.useSyncExternalStoreWithSelector=function(c,u,d,h,p){var f=o(null);if(f.current===null){var m={hasValue:!1,value:null};f.current=m}else m=f.current;f=i(function(){function x(w){if(!_){if(_=!0,O=w,w=h(w),p!==void 0&&m.hasValue){var R=m.value;if(p(R,w))return C=R}return C=w}if(R=C,n(O,w))return R;var I=h(w);return p!==void 0&&p(R,I)?(O=w,R):(O=w,C=I)}var _=!1,O,C,P=d===void 0?null:d;return[function(){return x(u())},P===null?void 0:function(){return x(P())}]},[u,d,h,p]);var b=a(c,f[0],f[1]);return s(function(){m.hasValue=!0,m.value=b},[b]),l(b),b},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())}()),ti}var su;function Ab(){return su||(su=1,process.env.NODE_ENV==="production"?za.exports=Tb():za.exports=Rb()),za.exports}var _b=Ab();const Eb=Object.is,at=(e,t,r=[],n=Eb)=>{const a=o=>t(o,...r);return _b.useSyncExternalStoreWithSelector(e.subscribe,e.getSnapshot,e.getSnapshot,a,n)},Vb="DEFAULT_X_AXIS_KEY",Ib="DEFAULT_Y_AXIS_KEY",Mb={top:20,bottom:20,left:20,right:20},$b=45,jb=25,np=20,bn=e=>{var t;return(t=e.cartesianAxis)==null?void 0:t.x},vn=e=>{var t;return(t=e.cartesianAxis)==null?void 0:t.y},kb=pe([vn],e=>(e??[]).reduce((t,r)=>{var n;return r.position==="left"?t+(r.width||0)+((n=r.zoom)!=null&&n.slider.enabled?r.zoom.slider.size:0):t},0)),Ub=pe([vn],e=>(e??[]).reduce((t,r)=>{var n;return r.position==="right"?t+(r.width||0)+((n=r.zoom)!=null&&n.slider.enabled?r.zoom.slider.size:0):t},0)),Lb=pe([bn],e=>(e??[]).reduce((t,r)=>{var n;return r.position==="top"?t+(r.height||0)+((n=r.zoom)!=null&&n.slider.enabled?r.zoom.slider.size:0):t},0)),Db=pe([bn],e=>(e??[]).reduce((t,r)=>{var n;return r.position==="bottom"?t+(r.height||0)+((n=r.zoom)!=null&&n.slider.enabled?r.zoom.slider.size:0):t},0)),Nb=e=>e.dimensions,ap=e=>e.dimensions.width,op=e=>e.dimensions.height,Bb=e=>e.dimensions.margin.top,Fb=e=>e.dimensions.margin.right,zb=e=>e.dimensions.margin.bottom,Gb=e=>e.dimensions.margin.left,Oa=pe([ap,op,Bb,Fb,zb,Gb,Lb,Ub,Db,kb],(e,t,r,n,a,o,s,i,l,c)=>({width:e-o-n-c-i,left:o+c,right:n+i,height:t-r-a-s-l,top:r+s,bottom:a+l})),Hb=pe([Nb],e=>({width:e.propsWidth,height:e.propsHeight})),qb=pe([ap,op],(e,t)=>({width:e,height:t}));function sp(e,t){return typeof e=="number"?{top:e,bottom:e,left:e,right:e}:t?Y({},t,e):e}const Jb=10,cs=({params:e,store:t,svgRef:r})=>{const n=e.width!==void 0&&e.height!==void 0,a=V.useRef({displayError:!1,initialCompute:!0,computeRun:0}),[o,s]=V.useState(0),[i,l]=V.useState(0),c=V.useCallback(()=>{const f=r==null?void 0:r.current;if(!f)return{};const b=wb(f).getComputedStyle(f),x=Math.floor(parseFloat(b.height))||0,_=Math.floor(parseFloat(b.width))||0;return t.update(O=>O.dimensions.width===_&&O.dimensions.height===x?O:Y({},O,{dimensions:{margin:{top:e.margin.top,right:e.margin.right,bottom:e.margin.bottom,left:e.margin.left},width:e.width??_,height:e.height??x,propsWidth:e.width,propsHeight:e.height}})),{height:x,width:_}},[t,r,e.height,e.width,e.margin.left,e.margin.right,e.margin.top,e.margin.bottom]);V.useEffect(()=>{t.update(f=>{const m=e.width??f.dimensions.width,b=e.height??f.dimensions.height;return Y({},f,{dimensions:{margin:{top:e.margin.top,right:e.margin.right,bottom:e.margin.bottom,left:e.margin.left},width:m,height:b,propsHeight:e.height,propsWidth:e.width}})})},[t,e.height,e.width,e.margin.left,e.margin.right,e.margin.top,e.margin.bottom]),V.useEffect(()=>{a.current.displayError=!0},[]),Ft(()=>{if(n||!a.current.initialCompute||a.current.computeRun>Jb)return;const f=c();f.width!==o||f.height!==i?(a.current.computeRun+=1,f.width!==void 0&&s(f.width),f.height!==void 0&&l(f.height)):a.current.initialCompute&&(a.current.initialCompute=!1)},[i,o,c,n]),Ft(()=>{if(n)return()=>{};c();const f=r.current;if(typeof ResizeObserver>"u")return()=>{};let m;const b=new ResizeObserver(()=>{m=requestAnimationFrame(()=>{c()})});return f&&b.observe(f),()=>{m&&cancelAnimationFrame(m),f&&b.unobserve(f)}},[c,n,r]),process.env.NODE_ENV!=="production"&&(a.current.displayError&&e.width===void 0&&o===0&&(console.error("MUI X Charts: ChartContainer does not have `width` prop, and its container has no `width` defined."),a.current.displayError=!1),a.current.displayError&&e.height===void 0&&i===0&&(console.error("MUI X Charts: ChartContainer does not have `height` prop, and its container has no `height` defined."),a.current.displayError=!1));const u=at(t,Oa),d=V.useCallback(f=>f>=u.left-1&&f<=u.left+u.width,[u.left,u.width]),h=V.useCallback(f=>f>=u.top-1&&f<=u.top+u.height,[u.height,u.top]);return{instance:{isPointInside:V.useCallback((f,m,b)=>b&&"closest"in b&&b.closest("[data-drawing-container]")?!0:d(f)&&h(m),[d,h]),isXInside:d,isYInside:h}}};cs.params={width:!0,height:!0,margin:!0};cs.getDefaultizedParams=({params:e})=>Y({},e,{margin:sp(e.margin,Mb)});cs.getInitialState=({width:e,height:t,margin:r})=>({dimensions:{margin:r,width:e??0,height:t??0,propsWidth:e,propsHeight:t}});const Tl=({params:e,store:t})=>(Ft(()=>{t.update(r=>Y({},r,{experimentalFeatures:e.experimentalFeatures}))},[t,e.experimentalFeatures]),{});Tl.params={experimentalFeatures:!0};Tl.getInitialState=({experimentalFeatures:e})=>({experimentalFeatures:e});const Wb=e=>e.experimentalFeatures,ip=pe([Wb],e=>!!(e!=null&&e.preferStrictDomainInLineCharts));let iu=0;const Yb=()=>(iu+=1,`mui-chart-${iu}`),Rl=({params:e,store:t})=>(V.useEffect(()=>{t.update(r=>e.id===void 0||e.id===r.id.providedChartId&&r.id.chartId!==void 0?r:Y({},r,{id:Y({},r.id,{chartId:e.id??Yb()})}))},[t,e.id]),{});Rl.params={id:!0};Rl.getInitialState=({id:e})=>({id:{chartId:e,providedChartId:e}});const Kb=e=>e.id,Qb=pe([Kb],e=>e.chartId),Xb=["#4254FB","#FFB422","#FA4F58","#0DBEFF","#22BF75","#FA83B4","#FF7511"],Zb=["#495AFB","#FFC758","#F35865","#30C8FF","#44CE8D","#F286B3","#FF8C39"],lp=e=>e==="dark"?Zb:Xb,cp=({series:e,colors:t,seriesConfig:r,dataset:n})=>{const a={};e.forEach((s,i)=>{var u;const l=r[s.type].getSeriesWithDefaultValues(s,i,t),c=l.id;if(a[s.type]===void 0&&(a[s.type]={series:{},seriesOrder:[]}),((u=a[s.type])==null?void 0:u.series[c])!==void 0)throw new Error(`MUI X Charts: series' id "${c}" is not unique.`);a[s.type].series[c]=l,a[s.type].seriesOrder.push(c)});const o={};return Object.keys(r).forEach(s=>{var l,c;const i=a[s];i!==void 0&&(o[s]=((c=(l=r[s])==null?void 0:l.seriesProcessor)==null?void 0:c.call(l,i,n))??a[s])}),o},us=({params:e,store:t,seriesConfig:r})=>{const{series:n,dataset:a,theme:o,colors:s}=e,i=V.useRef(!0);return V.useEffect(()=>{if(i.current){i.current=!1;return}t.update(l=>Y({},l,{series:Y({},l.series,{processedSeries:cp({series:n,colors:typeof s=="function"?s(o):s,seriesConfig:r,dataset:a})})}))},[s,a,n,o,r,t]),{}};us.params={dataset:!0,series:!0,colors:!0,theme:!0};const ev=[];us.getDefaultizedParams=({params:e})=>{var t;return Y({},e,{series:(t=e.series)!=null&&t.length?e.series:ev,colors:e.colors??lp,theme:e.theme??"light"})};us.getInitialState=({series:e=[],colors:t,theme:r,dataset:n},a,o)=>({series:{seriesConfig:o,processedSeries:cp({series:e,colors:typeof t=="function"?t(r):t,seriesConfig:o,dataset:n})}});const up=e=>e.series,wa=pe([up],e=>e.processedSeries),ds=pe([up],e=>e.seriesConfig),tv={abort:!0,animationcancel:!0,animationend:!0,animationiteration:!0,animationstart:!0,auxclick:!0,beforeinput:!0,beforetoggle:!0,blur:!0,cancel:!0,canplay:!0,canplaythrough:!0,change:!0,click:!0,close:!0,compositionend:!0,compositionstart:!0,compositionupdate:!0,contextlost:!0,contextmenu:!0,contextrestored:!0,copy:!0,cuechange:!0,cut:!0,dblclick:!0,drag:!0,dragend:!0,dragenter:!0,dragleave:!0,dragover:!0,dragstart:!0,drop:!0,durationchange:!0,emptied:!0,ended:!0,error:!0,focus:!0,focusin:!0,focusout:!0,formdata:!0,gotpointercapture:!0,input:!0,invalid:!0,keydown:!0,keypress:!0,keyup:!0,load:!0,loadeddata:!0,loadedmetadata:!0,loadstart:!0,lostpointercapture:!0,mousedown:!0,mouseenter:!0,mouseleave:!0,mousemove:!0,mouseout:!0,mouseover:!0,mouseup:!0,paste:!0,pause:!0,play:!0,playing:!0,pointercancel:!0,pointerdown:!0,pointerenter:!0,pointerleave:!0,pointermove:!0,pointerout:!0,pointerover:!0,pointerup:!0,progress:!0,ratechange:!0,reset:!0,resize:!0,scroll:!0,scrollend:!0,securitypolicyviolation:!0,seeked:!0,seeking:!0,select:!0,selectionchange:!0,selectstart:!0,slotchange:!0,stalled:!0,submit:!0,suspend:!0,timeupdate:!0,toggle:!0,touchcancel:!0,touchend:!0,touchmove:!0,touchstart:!0,transitioncancel:!0,transitionend:!0,transitionrun:!0,transitionstart:!0,volumechange:!0,waiting:!0,webkitanimationend:!0,webkitanimationiteration:!0,webkitanimationstart:!0,webkittransitionend:!0,wheel:!0};class dp{constructor(t){if(this.name=void 0,this.preventDefault=void 0,this.stopPropagation=void 0,this.preventIf=void 0,this.requiredKeys=void 0,this.keyboardManager=void 0,this.pointerMode=void 0,this.customData={},this.pointerManager=void 0,this.gesturesRegistry=void 0,this.element=void 0,this.state=void 0,this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,!t||!t.name)throw new Error("Gesture must be initialized with a valid name.");if(t.name in tv)throw new Error(`Gesture can't be created with a native event name. Tried to use "${t.name}". Please use a custom name instead.`);this.name=t.name,this.preventDefault=t.preventDefault??!1,this.stopPropagation=t.stopPropagation??!1,this.preventIf=t.preventIf??[],this.requiredKeys=t.requiredKeys??[],this.pointerMode=t.pointerMode??[]}init(t,r,n,a){this.element=t,this.pointerManager=r,this.gesturesRegistry=n,this.keyboardManager=a;const o=`${this.name}ChangeOptions`;this.element.addEventListener(o,this.handleOptionsChange.bind(this));const s=`${this.name}ChangeState`;this.element.addEventListener(s,this.handleStateChange.bind(this))}handleOptionsChange(t){t&&t.detail&&this.updateOptions(t.detail)}updateOptions(t){this.preventDefault=t.preventDefault??this.preventDefault,this.stopPropagation=t.stopPropagation??this.stopPropagation,this.preventIf=t.preventIf??this.preventIf,this.requiredKeys=t.requiredKeys??this.requiredKeys,this.pointerMode=t.pointerMode??this.pointerMode}handleStateChange(t){t&&t.detail&&this.updateState(t.detail)}updateState(t){Object.assign(this.state,t)}getTargetElement(t){return this.isActive||this.element===t.target||this.element.contains(t.target)?this.element:null}set isActive(t){t?this.gesturesRegistry.registerActiveGesture(this.element,this):this.gesturesRegistry.unregisterActiveGesture(this.element,this)}get isActive(){return this.gesturesRegistry.isGestureActive(this.element,this)??!1}shouldPreventGesture(t){if(!this.keyboardManager.areKeysPressed(this.requiredKeys))return!0;if(this.preventIf.length===0)return!1;const r=this.gesturesRegistry.getActiveGestures(t);return this.preventIf.some(n=>r[n])}isPointerTypeAllowed(t){return!this.pointerMode||this.pointerMode.length===0?!0:this.pointerMode.includes(t)}destroy(){const t=`${this.name}ChangeOptions`;this.element.removeEventListener(t,this.handleOptionsChange.bind(this));const r=`${this.name}ChangeState`;this.element.removeEventListener(r,this.handleStateChange.bind(this))}}class rv{constructor(){this.activeGestures=new Map}registerActiveGesture(t,r){this.activeGestures.has(t)||this.activeGestures.set(t,new Set);const n=this.activeGestures.get(t),a={gesture:r,element:t};n.add(a)}unregisterActiveGesture(t,r){const n=this.activeGestures.get(t);n&&(n.forEach(a=>{a.gesture===r&&n.delete(a)}),n.size===0&&this.activeGestures.delete(t))}getActiveGestures(t){const r=this.activeGestures.get(t);return r?Array.from(r).reduce((n,a)=>(n[a.gesture.name]=!0,n),{}):{}}isGestureActive(t,r){const n=this.activeGestures.get(t);return n?Array.from(n).some(a=>a.gesture===r):!1}destroy(){this.activeGestures.clear()}unregisterElement(t){this.activeGestures.delete(t)}}class nv{constructor(){this.pressedKeys=new Set,this.handleKeyDown=t=>{this.pressedKeys.add(t.key)},this.handleKeyUp=t=>{this.pressedKeys.delete(t.key)},this.clearKeys=()=>{this.pressedKeys.clear()},this.initialize()}initialize(){typeof window>"u"||(window.addEventListener("keydown",this.handleKeyDown),window.addEventListener("keyup",this.handleKeyUp),window.addEventListener("blur",this.clearKeys))}areKeysPressed(t){return!t||t.length===0?!0:t.every(r=>r==="ControlOrMeta"?this.pressedKeys.has("Control")||this.pressedKeys.has("Meta"):this.pressedKeys.has(r))}destroy(){typeof window<"u"&&(window.removeEventListener("keydown",this.handleKeyDown),window.removeEventListener("keyup",this.handleKeyUp),window.removeEventListener("blur",this.clearKeys)),this.clearKeys()}}class av{constructor(t){this.root=void 0,this.touchAction=void 0,this.passive=void 0,this.preventEventInterruption=!0,this.pointers=new Map,this.gestureHandlers=new Set,this.handleInterruptEvents=r=>{if(this.preventEventInterruption&&"pointerType"in r&&r.pointerType==="touch"){r.preventDefault();return}const n=new PointerEvent("forceCancel",{bubbles:!1,cancelable:!1}),a=this.pointers.values().next().value;if(this.pointers.size>0&&a){Object.defineProperties(n,{clientX:{value:a.clientX},clientY:{value:a.clientY},pointerId:{value:a.pointerId},pointerType:{value:a.pointerType}});for(const[o,s]of this.pointers.entries()){const i=Y({},s,{type:"forceCancel"});this.pointers.set(o,i)}}this.notifyHandlers(n),this.pointers.clear()},this.handlePointerEvent=r=>{const{type:n,pointerId:a}=r;if(n==="pointerdown"){if(this.pointers.set(a,this.createPointerData(r)),r.target instanceof Element)try{r.target.setPointerCapture(a)}catch{}}else if(n==="pointermove")this.pointers.set(a,this.createPointerData(r));else if(n==="pointerup"||n==="pointercancel"||n==="forceCancel"){if(r.target instanceof Element)try{r.target.releasePointerCapture(a)}catch{}this.pointers.set(a,this.createPointerData(r)),this.notifyHandlers(r),this.pointers.delete(a);return}this.notifyHandlers(r)},this.root=t.root??document.documentElement,this.touchAction=t.touchAction||"auto",this.passive=t.passive!==!1,this.preventEventInterruption=t.preventEventInterruption!==!1,this.setupEventListeners()}registerGestureHandler(t){return this.gestureHandlers.add(t),()=>{this.gestureHandlers.delete(t)}}getPointers(){return new Map(this.pointers)}setupEventListeners(){this.touchAction!=="auto"&&(this.root.style.touchAction=this.touchAction),this.root.addEventListener("pointerdown",this.handlePointerEvent,{passive:this.passive}),this.root.addEventListener("pointermove",this.handlePointerEvent,{passive:this.passive}),this.root.addEventListener("pointerup",this.handlePointerEvent,{passive:this.passive}),this.root.addEventListener("pointercancel",this.handlePointerEvent,{passive:this.passive}),this.root.addEventListener("forceCancel",this.handlePointerEvent,{passive:this.passive}),this.root.addEventListener("blur",this.handleInterruptEvents),this.root.addEventListener("contextmenu",this.handleInterruptEvents)}notifyHandlers(t){this.gestureHandlers.forEach(r=>r(this.pointers,t))}createPointerData(t){return{pointerId:t.pointerId,clientX:t.clientX,clientY:t.clientY,pageX:t.pageX,pageY:t.pageY,target:t.target,timeStamp:t.timeStamp,type:t.type,isPrimary:t.isPrimary,pressure:t.pressure,width:t.width,height:t.height,pointerType:t.pointerType,srcEvent:t}}destroy(){this.root.removeEventListener("pointerdown",this.handlePointerEvent),this.root.removeEventListener("pointermove",this.handlePointerEvent),this.root.removeEventListener("pointerup",this.handlePointerEvent),this.root.removeEventListener("pointercancel",this.handlePointerEvent),this.root.removeEventListener("forceCancel",this.handlePointerEvent),this.root.removeEventListener("blur",this.handleInterruptEvents),this.root.removeEventListener("contextmenu",this.handleInterruptEvents),this.pointers.clear(),this.gestureHandlers.clear()}}class ov{constructor(t){this.gestureTemplates=new Map,this.elementGestureMap=new Map,this.activeGesturesRegistry=new rv,this.pointerManager=void 0,this.keyboardManager=new nv,this.pointerManager=new av({root:t.root,touchAction:t.touchAction,passive:t.passive}),t.gestures&&t.gestures.length>0&&t.gestures.forEach(r=>{this.addGestureTemplate(r)})}addGestureTemplate(t){this.gestureTemplates.has(t.name)&&console.warn(`Gesture template with name "${t.name}" already exists. It will be overwritten.`),this.gestureTemplates.set(t.name,t)}setGestureOptions(t,r,n){const a=this.elementGestureMap.get(r);if(!a||!a.has(t)){console.error(`Gesture "${t}" not found on the provided element.`);return}const o=new CustomEvent(`${t}ChangeOptions`,{detail:n,bubbles:!1,cancelable:!1});r.dispatchEvent(o)}setGestureState(t,r,n){const a=this.elementGestureMap.get(r);if(!a||!a.has(t)){console.error(`Gesture "${t}" not found on the provided element.`);return}const o=new CustomEvent(`${t}ChangeState`,{detail:n,bubbles:!1,cancelable:!1});r.dispatchEvent(o)}registerElement(t,r,n){if(Array.isArray(t))return t.forEach(o=>{const s=n==null?void 0:n[o];this.registerSingleGesture(o,r,s)}),r;const a=n==null?void 0:n[t];return this.registerSingleGesture(t,r,a),r}registerSingleGesture(t,r,n){const a=this.gestureTemplates.get(t);if(!a)return console.error(`Gesture template "${t}" not found.`),!1;this.elementGestureMap.has(r)||this.elementGestureMap.set(r,new Map);const o=this.elementGestureMap.get(r);o.has(t)&&(console.warn(`Element already has gesture "${t}" registered. It will be replaced.`),this.unregisterElement(t,r));const s=a.clone(n);return s.init(r,this.pointerManager,this.activeGesturesRegistry,this.keyboardManager),o.set(t,s),!0}unregisterElement(t,r){const n=this.elementGestureMap.get(r);return!n||!n.has(t)?!1:(n.get(t).destroy(),n.delete(t),this.activeGesturesRegistry.unregisterElement(r),n.size===0&&this.elementGestureMap.delete(r),!0)}unregisterAllGestures(t){const r=this.elementGestureMap.get(t);if(r){for(const[,n]of r)n.destroy(),this.activeGesturesRegistry.unregisterElement(t);this.elementGestureMap.delete(t)}}destroy(){for(const[t]of this.elementGestureMap)this.unregisterAllGestures(t);this.gestureTemplates.clear(),this.elementGestureMap.clear(),this.activeGesturesRegistry.destroy(),this.keyboardManager.destroy()}}class Ca extends dp{constructor(t){super(t),this.unregisterHandler=null,this.originalTarget=null,this.optionsType=void 0,this.mutableOptionsType=void 0,this.minPointers=void 0,this.maxPointers=void 0,this.minPointers=t.minPointers??1,this.maxPointers=t.maxPointers??1/0}init(t,r,n,a){super.init(t,r,n,a),this.unregisterHandler=this.pointerManager.registerGestureHandler((o,s)=>this.handlePointerEvent(o,s))}updateOptions(t){super.updateOptions(t),this.minPointers=t.minPointers??this.minPointers,this.maxPointers=t.maxPointers??this.maxPointers}getRelevantPointers(t,r){return t.filter(n=>this.isPointerTypeAllowed(n.pointerType)&&(r===n.target||n.target===this.originalTarget||r===this.originalTarget||r.contains(n.target)))}destroy(){this.unregisterHandler&&(this.unregisterHandler(),this.unregisterHandler=null),super.destroy()}}function sv(e,t){const r=t.x-e.x,n=t.y-e.y;return Math.sqrt(r*r+n*n)}function ri(e){if(e.length<2)return 0;let t=0,r=0;for(let n=0;n<e.length;n+=1)for(let a=n+1;a<e.length;a+=1)t+=sv({x:e[n].clientX,y:e[n].clientY},{x:e[a].clientX,y:e[a].clientY}),r+=1;return r>0?t/r:0}function zt(e){if(e.length===0)return{x:0,y:0};const t=e.reduce((r,n)=>(r.x+=n.clientX,r.y+=n.clientY,r),{x:0,y:0});return{x:t.x/e.length,y:t.y/e.length}}function Sn(e,t){return`${e}${t==="ongoing"?"":t.charAt(0).toUpperCase()+t.slice(1)}`}const Ha=1e-5,Xt=1e-5,lu=.15;function iv(e,t){const r=t.x-e.x,n=t.y-e.y,a={vertical:null,horizontal:null,mainAxis:null},o=lv(t,e),s=Math.abs(r)>Math.abs(n)?"horizontal":"vertical",i=o||s==="horizontal"?Ha:lu,l=o?Ha:s==="horizontal"?lu:Ha;return Math.abs(r)>i&&(a.horizontal=r>0?"right":"left"),Math.abs(n)>l&&(a.vertical=n>0?"down":"up"),a.mainAxis=o?"diagonal":s,a}function lv(e,t){const r=t.x-e.x,n=t.y-e.y,a=Math.atan2(n,r)*180/Math.PI;return a>=-45+Xt&&a<=-22.5+Xt||a>=22.5+Xt&&a<=45+Xt||a>=135+Xt&&a<=157.5+Xt||a>=-157.5+Xt&&a<=-135+Xt}function cv(e,t){if(!e.vertical&&!e.horizontal)return!1;if(t.length===0)return!0;const r=e.vertical===null||t.includes(e.vertical),n=e.horizontal===null||t.includes(e.horizontal);return r&&n}const uv=0,dv=e=>e>uv?1:e<-0?-1:0;class Al extends Ca{constructor(t){super(t),this.state={lastPosition:null},this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,this.threshold=void 0,this.handleElementEnterBound=void 0,this.handleElementLeaveBound=void 0,this.handleElementEnterBound=this.handleElementEnter.bind(this),this.handleElementLeaveBound=this.handleElementLeave.bind(this),this.threshold=t.threshold||0}clone(t){return new Al(Y({name:this.name,preventDefault:this.preventDefault,stopPropagation:this.stopPropagation,threshold:this.threshold,minPointers:this.minPointers,maxPointers:this.maxPointers,requiredKeys:[...this.requiredKeys],pointerMode:[...this.pointerMode],preventIf:[...this.preventIf]},t))}init(t,r,n,a){super.init(t,r,n,a),this.element.addEventListener("pointerenter",this.handleElementEnterBound),this.element.addEventListener("pointerleave",this.handleElementLeaveBound)}destroy(){this.element.removeEventListener("pointerenter",this.handleElementEnterBound),this.element.removeEventListener("pointerleave",this.handleElementLeaveBound),this.resetState(),super.destroy()}updateOptions(t){super.updateOptions(t)}resetState(){this.isActive=!1,this.state={lastPosition:null}}handleElementEnter(t){if(t.pointerType!=="mouse"&&t.pointerType!=="pen")return;const r=this.pointerManager.getPointers()||new Map,n=Array.from(r.values());if(n.length>=this.minPointers&&n.length<=this.maxPointers){this.isActive=!0;const a={x:t.clientX,y:t.clientY};this.state.lastPosition=a,this.emitMoveEvent(this.element,"start",n,t),this.emitMoveEvent(this.element,"ongoing",n,t)}}handleElementLeave(t){if(t.pointerType!=="mouse"&&t.pointerType!=="pen"||!this.isActive)return;const r=this.pointerManager.getPointers()||new Map,n=Array.from(r.values());this.emitMoveEvent(this.element,"end",n,t),this.resetState()}handlePointerEvent(t,r){if(r.type!=="pointermove"||r.pointerType!=="mouse"&&r.pointerType!=="pen")return;this.preventDefault&&r.preventDefault(),this.stopPropagation&&r.stopPropagation();const n=Array.from(t.values()),a=this.getTargetElement(r);if(!a||n.length<this.minPointers||n.length>this.maxPointers)return;if(this.shouldPreventGesture(a)){if(!this.isActive)return;this.resetState(),this.emitMoveEvent(a,"end",n,r);return}const o={x:r.clientX,y:r.clientY};this.state.lastPosition=o,this.isActive||(this.isActive=!0,this.emitMoveEvent(a,"start",n,r)),this.emitMoveEvent(a,"ongoing",n,r)}emitMoveEvent(t,r,n,a){const o=this.state.lastPosition||zt(n),s=this.gesturesRegistry.getActiveGestures(t),i={gestureName:this.name,centroid:o,target:a.target,srcEvent:a,phase:r,pointers:n,timeStamp:a.timeStamp,activeGestures:s,customData:this.customData},l=Sn(this.name,r),c=new CustomEvent(l,{bubbles:!0,cancelable:!0,detail:i});t.dispatchEvent(c)}}class _l extends Ca{constructor(t){super(t),this.state={startPointers:new Map,startCentroid:null,lastCentroid:null,movementThresholdReached:!1,totalDeltaX:0,totalDeltaY:0,activeDeltaX:0,activeDeltaY:0,lastDirection:{vertical:null,horizontal:null,mainAxis:null},lastDeltas:null},this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,this.threshold=void 0,this.direction=void 0,this.direction=t.direction||["up","down","left","right"],this.threshold=t.threshold||0}clone(t){return new _l(Y({name:this.name,preventDefault:this.preventDefault,stopPropagation:this.stopPropagation,threshold:this.threshold,minPointers:this.minPointers,maxPointers:this.maxPointers,direction:[...this.direction],requiredKeys:[...this.requiredKeys],pointerMode:[...this.pointerMode],preventIf:[...this.preventIf]},t))}destroy(){this.resetState(),super.destroy()}updateOptions(t){super.updateOptions(t),this.direction=t.direction||this.direction}resetState(){this.isActive=!1,this.state=Y({},this.state,{startPointers:new Map,startCentroid:null,lastCentroid:null,lastDeltas:null,activeDeltaX:0,activeDeltaY:0,movementThresholdReached:!1,lastDirection:{vertical:null,horizontal:null,mainAxis:null}})}handlePointerEvent(t,r){const n=Array.from(t.values());if(r.type==="forceCancel"){this.cancel(r.target,n,r);return}const a=this.getTargetElement(r);if(!a)return;if(this.shouldPreventGesture(a)){this.cancel(a,n,r);return}const o=this.getRelevantPointers(n,a);if(o.length<this.minPointers||o.length>this.maxPointers){this.cancel(a,o,r);return}switch(r.type){case"pointerdown":!this.isActive&&!this.state.startCentroid&&(o.forEach(s=>{this.state.startPointers.set(s.pointerId,s)}),this.originalTarget=a,this.state.startCentroid=zt(o),this.state.lastCentroid=Y({},this.state.startCentroid));break;case"pointermove":if(this.state.startCentroid&&o.length>=this.minPointers){const s=zt(o),i=s.x-this.state.startCentroid.x,l=s.y-this.state.startCentroid.y,c=Math.sqrt(i*i+l*l),u=iv(this.state.lastCentroid??this.state.startCentroid,s),d=this.state.lastCentroid?s.x-this.state.lastCentroid.x:0,h=this.state.lastCentroid?s.y-this.state.lastCentroid.y:0;!this.state.movementThresholdReached&&c>=this.threshold&&cv(u,this.direction)?(this.state.movementThresholdReached=!0,this.isActive=!0,this.state.lastDeltas={x:d,y:h},this.state.totalDeltaX+=d,this.state.totalDeltaY+=h,this.state.activeDeltaX+=d,this.state.activeDeltaY+=h,this.emitPanEvent(a,"start",o,r,s),this.emitPanEvent(a,"ongoing",o,r,s)):this.state.movementThresholdReached&&this.isActive&&(this.state.lastDeltas={x:d,y:h},this.state.totalDeltaX+=d,this.state.totalDeltaY+=h,this.state.activeDeltaX+=d,this.state.activeDeltaY+=h,this.emitPanEvent(a,"ongoing",o,r,s)),this.state.lastCentroid=s,this.state.lastDirection=u}break;case"pointerup":case"pointercancel":case"forceCancel":if(this.isActive&&this.state.movementThresholdReached){if(o.filter(s=>s.type!=="pointerup"&&s.type!=="pointercancel").length<this.minPointers){const s=this.state.lastCentroid||this.state.startCentroid;r.type==="pointercancel"&&this.emitPanEvent(a,"cancel",o,r,s),this.emitPanEvent(a,"end",o,r,s),this.resetState()}}else this.resetState();break}}emitPanEvent(t,r,n,a,o){var x,_;if(!this.state.startCentroid)return;const s=((x=this.state.lastDeltas)==null?void 0:x.x)??0,i=((_=this.state.lastDeltas)==null?void 0:_.y)??0,l=this.state.startPointers.values().next().value,c=l?(a.timeStamp-l.timeStamp)/1e3:0,u=c>0?s/c:0,d=c>0?i/c:0,h=Math.sqrt(u*u+d*d),p=this.gesturesRegistry.getActiveGestures(t),f={gestureName:this.name,initialCentroid:this.state.startCentroid,centroid:o,target:a.target,srcEvent:a,phase:r,pointers:n,timeStamp:a.timeStamp,deltaX:s,deltaY:i,direction:this.state.lastDirection,velocityX:u,velocityY:d,velocity:h,totalDeltaX:this.state.totalDeltaX,totalDeltaY:this.state.totalDeltaY,activeDeltaX:this.state.activeDeltaX,activeDeltaY:this.state.activeDeltaY,activeGestures:p,customData:this.customData},m=Sn(this.name,r),b=new CustomEvent(m,{bubbles:!0,cancelable:!0,detail:f});t.dispatchEvent(b),this.preventDefault&&a.preventDefault(),this.stopPropagation&&a.stopPropagation()}cancel(t,r,n){if(this.isActive){const a=t??this.element;this.emitPanEvent(a,"cancel",r,n,this.state.lastCentroid),this.emitPanEvent(a,"end",r,n,this.state.lastCentroid)}this.resetState()}}class El extends Ca{constructor(t){super(Y({},t,{minPointers:t.minPointers??2})),this.state={startDistance:0,lastDistance:0,lastScale:1,lastTime:0,velocity:0,totalScale:1,deltaScale:0},this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,this.threshold=void 0,this.threshold=t.threshold??0}clone(t){return new El(Y({name:this.name,preventDefault:this.preventDefault,stopPropagation:this.stopPropagation,threshold:this.threshold,minPointers:this.minPointers,maxPointers:this.maxPointers,requiredKeys:[...this.requiredKeys],pointerMode:[...this.pointerMode],preventIf:[...this.preventIf]},t))}destroy(){this.resetState(),super.destroy()}updateOptions(t){super.updateOptions(t)}resetState(){this.isActive=!1,this.state=Y({},this.state,{startDistance:0,lastDistance:0,lastScale:1,lastTime:0,velocity:0,deltaScale:0})}handlePointerEvent(t,r){const n=Array.from(t.values()),a=this.getTargetElement(r);if(!a)return;if(this.shouldPreventGesture(a)){this.isActive&&(this.emitPinchEvent(a,"cancel",n,r),this.resetState());return}const o=this.getRelevantPointers(n,a);switch(r.type){case"pointerdown":if(o.length>=2&&!this.isActive){const s=ri(o);this.state.startDistance=s,this.state.lastDistance=s,this.state.lastTime=r.timeStamp,this.originalTarget=a}break;case"pointermove":if(this.state.startDistance&&o.length>=this.minPointers){const s=ri(o),i=Math.abs(s-this.state.lastDistance);if(i!==0&&i>=this.threshold){const l=this.state.startDistance?s/this.state.startDistance:1,c=l/this.state.lastScale;this.state.totalScale*=c;const u=(r.timeStamp-this.state.lastTime)/1e3;if(this.state.lastDistance){const h=(s-this.state.lastDistance)/u;this.state.velocity=Number.isNaN(h)?0:h}this.state.lastDistance=s,this.state.deltaScale=l-this.state.lastScale,this.state.lastScale=l,this.state.lastTime=r.timeStamp,this.isActive?this.emitPinchEvent(a,"ongoing",o,r):(this.isActive=!0,this.emitPinchEvent(a,"start",o,r),this.emitPinchEvent(a,"ongoing",o,r))}}break;case"pointerup":case"pointercancel":case"forceCancel":if(this.isActive){const s=o.filter(i=>i.type!=="pointerup"&&i.type!=="pointercancel");if(s.length<this.minPointers)r.type==="pointercancel"&&this.emitPinchEvent(a,"cancel",o,r),this.emitPinchEvent(a,"end",o,r),this.resetState();else if(s.length>=2){const i=ri(s);this.state.startDistance=i/this.state.lastScale}}break}}emitPinchEvent(t,r,n,a){const o=zt(n),s=this.state.lastDistance,i=this.state.lastScale,l=this.gesturesRegistry.getActiveGestures(t),c={gestureName:this.name,centroid:o,target:a.target,srcEvent:a,phase:r,pointers:n,timeStamp:a.timeStamp,scale:i,deltaScale:this.state.deltaScale,totalScale:this.state.totalScale,distance:s,velocity:this.state.velocity,activeGestures:l,direction:dv(this.state.velocity),customData:this.customData};this.preventDefault&&a.preventDefault(),this.stopPropagation&&a.stopPropagation();const u=Sn(this.name,r),d=new CustomEvent(u,{bubbles:!0,cancelable:!0,detail:c});t.dispatchEvent(d)}}class Vl extends Ca{constructor(t){super(t),this.state={startCentroid:null,lastPosition:null,timerId:null,startTime:0,pressThresholdReached:!1},this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,this.duration=void 0,this.maxDistance=void 0,this.duration=t.duration??500,this.maxDistance=t.maxDistance??10}clone(t){return new Vl(Y({name:this.name,preventDefault:this.preventDefault,stopPropagation:this.stopPropagation,minPointers:this.minPointers,maxPointers:this.maxPointers,duration:this.duration,maxDistance:this.maxDistance,requiredKeys:[...this.requiredKeys],pointerMode:[...this.pointerMode],preventIf:[...this.preventIf]},t))}destroy(){this.clearPressTimer(),this.resetState(),super.destroy()}updateOptions(t){super.updateOptions(t),this.duration=t.duration??this.duration,this.maxDistance=t.maxDistance??this.maxDistance}resetState(){this.clearPressTimer(),this.isActive=!1,this.state=Y({},this.state,{startCentroid:null,lastPosition:null,timerId:null,startTime:0,pressThresholdReached:!1})}clearPressTimer(){this.state.timerId!==null&&(clearTimeout(this.state.timerId),this.state.timerId=null)}handlePointerEvent(t,r){const n=Array.from(t.values());if(r.type==="forceCancel"){this.cancelPress(r.target,n,r);return}const a=this.getTargetElement(r);if(!a)return;if(this.shouldPreventGesture(a)){this.isActive&&this.cancelPress(a,n,r);return}const o=this.getRelevantPointers(n,a);if(o.length<this.minPointers||o.length>this.maxPointers){this.isActive&&this.cancelPress(a,o,r);return}switch(r.type){case"pointerdown":!this.isActive&&!this.state.startCentroid&&(this.state.startCentroid=zt(o),this.state.lastPosition=Y({},this.state.startCentroid),this.state.startTime=r.timeStamp,this.isActive=!0,this.originalTarget=a,this.clearPressTimer(),this.state.timerId=setTimeout(()=>{if(this.isActive&&this.state.startCentroid){this.state.pressThresholdReached=!0;const s=this.state.lastPosition;this.emitPressEvent(a,"start",o,r,s),this.emitPressEvent(a,"ongoing",o,r,s)}},this.duration));break;case"pointermove":if(this.isActive&&this.state.startCentroid){const s=zt(o);this.state.lastPosition=s;const i=s.x-this.state.startCentroid.x,l=s.y-this.state.startCentroid.y;Math.sqrt(i*i+l*l)>this.maxDistance&&this.cancelPress(a,o,r)}break;case"pointerup":if(this.isActive){if(this.state.pressThresholdReached){const s=this.state.lastPosition||this.state.startCentroid;this.emitPressEvent(a,"end",o,r,s)}this.resetState()}break;case"pointercancel":case"forceCancel":this.cancelPress(a,o,r);break}}emitPressEvent(t,r,n,a,o){const s=this.gesturesRegistry.getActiveGestures(t),i=a.timeStamp-this.state.startTime,l={gestureName:this.name,centroid:o,target:a.target,srcEvent:a,phase:r,pointers:n,timeStamp:a.timeStamp,x:o.x,y:o.y,duration:i,activeGestures:s,customData:this.customData},c=Sn(this.name,r),u=new CustomEvent(c,{bubbles:!0,cancelable:!0,detail:l});t.dispatchEvent(u),this.preventDefault&&a.preventDefault(),this.stopPropagation&&a.stopPropagation()}cancelPress(t,r,n){if(this.isActive&&this.state.pressThresholdReached){const a=this.state.lastPosition||this.state.startCentroid;this.emitPressEvent(t??this.element,"cancel",r,n,a),this.emitPressEvent(t??this.element,"end",r,n,a)}this.resetState()}}class Il extends Ca{constructor(t){super(t),this.state={startCentroid:null,currentTapCount:0,lastTapTime:0,lastPosition:null},this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,this.maxDistance=void 0,this.taps=void 0,this.maxDistance=t.maxDistance??10,this.taps=t.taps??1}clone(t){return new Il(Y({name:this.name,preventDefault:this.preventDefault,stopPropagation:this.stopPropagation,minPointers:this.minPointers,maxPointers:this.maxPointers,maxDistance:this.maxDistance,taps:this.taps,requiredKeys:[...this.requiredKeys],pointerMode:[...this.pointerMode],preventIf:[...this.preventIf]},t))}destroy(){this.resetState(),super.destroy()}updateOptions(t){super.updateOptions(t),this.maxDistance=t.maxDistance??this.maxDistance,this.taps=t.taps??this.taps}resetState(){this.isActive=!1,this.state={startCentroid:null,currentTapCount:0,lastTapTime:0,lastPosition:null}}handlePointerEvent(t,r){const n=Array.from(t.values()),a=this.getTargetElement(r);if(!a)return;const o=this.getRelevantPointers(n,a);if(this.shouldPreventGesture(a)||o.length<this.minPointers||o.length>this.maxPointers){this.isActive&&this.cancelTap(a,o,r);return}switch(r.type){case"pointerdown":this.isActive||(this.state.startCentroid=zt(o),this.state.lastPosition=Y({},this.state.startCentroid),this.isActive=!0,this.originalTarget=a);break;case"pointermove":if(this.isActive&&this.state.startCentroid){const s=zt(o);this.state.lastPosition=s;const i=s.x-this.state.startCentroid.x,l=s.y-this.state.startCentroid.y;Math.sqrt(i*i+l*l)>this.maxDistance&&this.cancelTap(a,o,r)}break;case"pointerup":if(this.isActive){this.state.currentTapCount+=1;const s=this.state.lastPosition||this.state.startCentroid;if(!s){this.cancelTap(a,o,r);return}this.state.currentTapCount>=this.taps?(this.fireTapEvent(a,o,r,s),this.resetState()):(this.state.lastTapTime=r.timeStamp,this.isActive=!1,this.state.startCentroid=null,setTimeout(()=>{this.state&&this.state.currentTapCount>0&&this.state.currentTapCount<this.taps&&(this.state.currentTapCount=0)},300))}break;case"pointercancel":case"forceCancel":this.cancelTap(a,o,r);break}}fireTapEvent(t,r,n,a){const o=this.gesturesRegistry.getActiveGestures(t),s={gestureName:this.name,centroid:a,target:n.target,srcEvent:n,phase:"end",pointers:r,timeStamp:n.timeStamp,x:a.x,y:a.y,tapCount:this.state.currentTapCount,activeGestures:o,customData:this.customData},i=new CustomEvent(this.name,{bubbles:!0,cancelable:!0,detail:s});t.dispatchEvent(i),this.preventDefault&&n.preventDefault(),this.stopPropagation&&n.stopPropagation()}cancelTap(t,r,n){if(this.state.startCentroid||this.state.lastPosition){const a=this.state.lastPosition||this.state.startCentroid,o=this.gesturesRegistry.getActiveGestures(t),s={gestureName:this.name,centroid:a,target:n.target,srcEvent:n,phase:"cancel",pointers:r,timeStamp:n.timeStamp,x:a.x,y:a.y,tapCount:this.state.currentTapCount,activeGestures:o,customData:this.customData},i=Sn(this.name,"cancel"),l=new CustomEvent(i,{bubbles:!0,cancelable:!0,detail:s});t.dispatchEvent(l)}this.resetState()}}class Ml extends dp{constructor(t){super(t),this.state={totalDeltaX:0,totalDeltaY:0,totalDeltaZ:0},this.isSinglePhase=void 0,this.eventType=void 0,this.optionsType=void 0,this.mutableOptionsType=void 0,this.mutableStateType=void 0,this.sensitivity=void 0,this.max=void 0,this.min=void 0,this.initialDelta=void 0,this.invert=void 0,this.handleWheelEventBound=void 0,this.sensitivity=t.sensitivity??1,this.max=t.max??Number.MAX_SAFE_INTEGER,this.min=t.min??Number.MIN_SAFE_INTEGER,this.initialDelta=t.initialDelta??0,this.invert=t.invert??!1,this.state.totalDeltaX=this.initialDelta,this.state.totalDeltaY=this.initialDelta,this.state.totalDeltaZ=this.initialDelta,this.handleWheelEventBound=this.handleWheelEvent.bind(this)}clone(t){return new Ml(Y({name:this.name,preventDefault:this.preventDefault,stopPropagation:this.stopPropagation,sensitivity:this.sensitivity,max:this.max,min:this.min,initialDelta:this.initialDelta,invert:this.invert,requiredKeys:[...this.requiredKeys],pointerMode:[...this.pointerMode],preventIf:[...this.preventIf]},t))}init(t,r,n,a){super.init(t,r,n,a),this.element.addEventListener("wheel",this.handleWheelEventBound)}destroy(){this.element.removeEventListener("wheel",this.handleWheelEventBound),this.resetState(),super.destroy()}resetState(){this.isActive=!1,this.state={totalDeltaX:0,totalDeltaY:0,totalDeltaZ:0}}updateOptions(t){super.updateOptions(t),this.sensitivity=t.sensitivity??this.sensitivity,this.max=t.max??this.max,this.min=t.min??this.min,this.initialDelta=t.initialDelta??this.initialDelta,this.invert=t.invert??this.invert}handleWheelEvent(t){if(this.shouldPreventGesture(this.element))return;const r=this.pointerManager.getPointers()||new Map,n=Array.from(r.values());this.state.totalDeltaX+=t.deltaX*this.sensitivity*(this.invert?-1:1),this.state.totalDeltaY+=t.deltaY*this.sensitivity*(this.invert?-1:1),this.state.totalDeltaZ+=t.deltaZ*this.sensitivity*(this.invert?-1:1),["totalDeltaX","totalDeltaY","totalDeltaZ"].forEach(a=>{this.state[a]<this.min&&(this.state[a]=this.min),this.state[a]>this.max&&(this.state[a]=this.max)}),this.emitWheelEvent(n,t)}emitWheelEvent(t,r){const n=t.length>0?zt(t):{x:r.clientX,y:r.clientY},a=this.gesturesRegistry.getActiveGestures(this.element),o={gestureName:this.name,centroid:n,target:r.target,srcEvent:r,phase:"ongoing",pointers:t,timeStamp:r.timeStamp,deltaX:r.deltaX*this.sensitivity*(this.invert?-1:1),deltaY:r.deltaY*this.sensitivity*(this.invert?-1:1),deltaZ:r.deltaZ*this.sensitivity*(this.invert?-1:1),deltaMode:r.deltaMode,totalDeltaX:this.state.totalDeltaX,totalDeltaY:this.state.totalDeltaY,totalDeltaZ:this.state.totalDeltaZ,activeGestures:a,customData:this.customData};this.preventDefault&&r.preventDefault(),this.stopPropagation&&r.stopPropagation();const s=Sn(this.name,"ongoing"),i=new CustomEvent(s,{bubbles:!0,cancelable:!0,detail:o});this.element.dispatchEvent(i)}}const zr=e=>e.preventDefault(),$l=({svgRef:e})=>{V.useEffect(()=>{const r=e.current;if(!r)return;const n=new ov({gestures:[new _l({name:"pan",threshold:0,maxPointers:1}),new Al({name:"move",preventIf:["pan","pinch"]}),new El({name:"pinch",threshold:5,preventIf:["pan"]}),new Ml({name:"turnWheel",sensitivity:.01,initialDelta:1}),new Il({name:"tap",maxDistance:10,preventIf:["pan","pinch"]}),new Vl({name:"quickPress",duration:50,maxDistance:10})]});return n.registerElement(["pan","move","pinch","turnWheel","tap","quickPress"],r),()=>{n.destroy()}},[e]);const t=V.useCallback((r,n,a)=>{const o=e.current;return o==null||o.addEventListener(r,n,a),{cleanup:()=>o==null?void 0:o.removeEventListener(r,n)}},[e]);return V.useEffect(()=>{const r=e.current;return r==null||r.addEventListener("gesturestart",zr),r==null||r.addEventListener("gesturechange",zr),r==null||r.addEventListener("gestureend",zr),()=>{r==null||r.removeEventListener("gesturestart",zr),r==null||r.removeEventListener("gesturechange",zr),r==null||r.removeEventListener("gestureend",zr)}},[e]),{instance:{addInteractionListener:t}}};$l.params={};$l.getInitialState=()=>({});const hv=[Rl,Tl,cs,us,$l,ls],pv=["apiRef"],mv=e=>{let{plugins:t}=e,r=or(e.props,pv);const n={};t.forEach(s=>{Object.assign(n,s.params)});const a={};return Object.keys(r).forEach(s=>{const i=r[s];n[s]&&(a[s]=i)}),t.reduce((s,i)=>i.getDefaultizedParams?i.getDefaultizedParams({params:s}):s,a)};let cu=0;function fv(e,t,r){const n=Z0(),a=V.useMemo(()=>[...hv,...e],[e]),o=mv({plugins:a,props:t});o.id=o.id??n;const i=V.useRef({}).current,l=yv(t.apiRef),c=V.useRef(null),u=V.useRef(null),d=V.useRef(null);if(d.current==null){cu+=1;const f={cacheKey:{id:cu}};a.forEach(m=>{m.getInitialState&&Object.assign(f,m.getInitialState(o,f,r))}),d.current=new eb(f)}const h=f=>{const m=f({instance:i,params:o,plugins:a,store:d.current,svgRef:u,chartRootRef:c,seriesConfig:r});m.publicAPI&&Object.assign(l.current,m.publicAPI),m.instance&&Object.assign(i,m.instance)};return a.forEach(h),{contextValue:V.useMemo(()=>({store:d.current,publicAPI:l.current,instance:i,svgRef:u,chartRootRef:c}),[i,l])}}function gv(e){return e.current==null&&(e.current={}),e}function yv(e){const t=V.useRef({});return e?gv(e):t}const jl=V.createContext(null);process.env.NODE_ENV!=="production"&&(jl.displayName="ChartContext");const uu=new Set;function sa(e,t="warning"){if(process.env.NODE_ENV==="production")return;const r=Array.isArray(e)?e.join(`
|
|
115
|
+
`):e;uu.has(r)||(uu.add(r),t==="error"?console.error(r):console.warn(r))}function bv(e){const{componentName:t,propName:r,controlled:n,defaultValue:a,warningPrefix:o="MUI X"}=e,[{initialDefaultValue:s,isControlled:i}]=V.useState({initialDefaultValue:a,isControlled:n!==void 0});i!==(n!==void 0)&&sa([`${o}: A component is changing the ${i?"":"un"}controlled ${r} state of ${t} to be ${i?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${r} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"],"error"),JSON.stringify(s)!==JSON.stringify(a)&&sa([`${o}: A component is changing the default ${r} state of an uncontrolled ${t} after being initialized. To suppress this warning opt to use a controlled ${t}.`],"error")}const hp=process.env.NODE_ENV==="production"?()=>{}:bv,pp=4,mp=20+2*pp,vv=40+2*pp,Sv="hover",qa={minStart:0,maxEnd:100,step:5,minSpan:10,maxSpan:100,panning:!0,filterMode:"keep",slider:{enabled:!1,preview:!1,size:mp,showTooltip:Sv}},kl=(e,t,r)=>{var n;if(e)return e===!0?Y({axisId:t,axisDirection:r},qa):Y({axisId:t,axisDirection:r},qa,e,{slider:Y({},qa.slider,{size:((n=e.slider)==null?void 0:n.preview)??qa.slider.preview?vv:mp},e.slider)})};function fp(e,t){const r={top:0,bottom:0,none:0};return(e&&e.length>0?e:[{id:Vb,scaleType:"linear"}]).map((o,s)=>{var p;const i=o.dataKey,l=s===0?"bottom":"none",c=o.position??l,u=jb+(o.label?np:0),d=o.id??`defaultized-x-axis-${s}`,h=Y({offset:r[c]},o,{id:d,position:c,height:o.height??u,zoom:kl(o.zoom,d,"x")});if(c!=="none"&&(r[c]+=h.height,(p=h.zoom)!=null&&p.slider.enabled&&(r[c]+=h.zoom.slider.size)),i===void 0||o.data!==void 0)return h;if(t===void 0)throw new Error("MUI X Charts: x-axis uses `dataKey` but no `dataset` is provided.");return Y({},h,{data:t.map(f=>f[i])})})}function gp(e,t){const r={right:0,left:0,none:0};return(e&&e.length>0?e:[{id:Ib,scaleType:"linear"}]).map((o,s)=>{var p;const i=o.dataKey,l=s===0?"left":"none",c=o.position??l,u=$b+(o.label?np:0),d=o.id??`defaultized-y-axis-${s}`,h=Y({offset:r[c]},o,{id:d,position:c,width:o.width??u,zoom:kl(o.zoom,d,"y")});if(c!=="none"&&(r[c]+=h.width,(p=h.zoom)!=null&&p.slider.enabled&&(r[c]+=h.zoom.slider.size)),i===void 0||o.data!==void 0)return h;if(t===void 0)throw new Error("MUI X Charts: y-axis uses `dataKey` but no `dataset` is provided.");return Y({},h,{data:t.map(f=>f[i])})})}function mo(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function xv(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Ul(e){let t,r,n;e.length!==2?(t=mo,r=(i,l)=>mo(e(i),l),n=(i,l)=>e(i)-l):(t=e===mo||e===xv?e:Ov,r=e,n=e);function a(i,l,c=0,u=i.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;r(i[d],l)<0?c=d+1:u=d}while(c<u)}return c}function o(i,l,c=0,u=i.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;r(i[d],l)<=0?c=d+1:u=d}while(c<u)}return c}function s(i,l,c=0,u=i.length){const d=a(i,l,c,u-1);return d>c&&n(i[d-1],l)>-n(i[d],l)?d-1:d}return{left:a,center:s,right:o}}function Ov(){return 0}function wv(e){return e===null?NaN:+e}const Cv=Ul(mo),yp=Cv.right;Ul(wv).center;class du extends Map{constructor(t,r=Rv){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),t!=null)for(const[n,a]of t)this.set(n,a)}get(t){return super.get(hu(this,t))}has(t){return super.has(hu(this,t))}set(t,r){return super.set(Pv(this,t),r)}delete(t){return super.delete(Tv(this,t))}}function hu({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):r}function Pv({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):(e.set(n,r),r)}function Tv({_intern:e,_key:t},r){const n=t(r);return e.has(n)&&(r=e.get(n),e.delete(n)),r}function Rv(e){return e!==null&&typeof e=="object"?e.valueOf():e}const Av=Math.sqrt(50),_v=Math.sqrt(10),Ev=Math.sqrt(2);function Ao(e,t,r){const n=(t-e)/Math.max(0,r),a=Math.floor(Math.log10(n)),o=n/Math.pow(10,a),s=o>=Av?10:o>=_v?5:o>=Ev?2:1;let i,l,c;return a<0?(c=Math.pow(10,-a)/s,i=Math.round(e*c),l=Math.round(t*c),i/c<e&&++i,l/c>t&&--l,c=-c):(c=Math.pow(10,a)*s,i=Math.round(e/c),l=Math.round(t/c),i*c<e&&++i,l*c>t&&--l),l<i&&.5<=r&&r<2?Ao(e,t,r*2):[i,l,c]}function Di(e,t,r){if(t=+t,e=+e,r=+r,!(r>0))return[];if(e===t)return[e];const n=t<e,[a,o,s]=n?Ao(t,e,r):Ao(e,t,r);if(!(o>=a))return[];const i=o-a+1,l=new Array(i);if(n)if(s<0)for(let c=0;c<i;++c)l[c]=(o-c)/-s;else for(let c=0;c<i;++c)l[c]=(o-c)*s;else if(s<0)for(let c=0;c<i;++c)l[c]=(a+c)/-s;else for(let c=0;c<i;++c)l[c]=(a+c)*s;return l}function Ni(e,t,r){return t=+t,e=+e,r=+r,Ao(e,t,r)[2]}function Bi(e,t,r){t=+t,e=+e,r=+r;const n=t<e,a=n?Ni(t,e,r):Ni(e,t,r);return(n?-1:1)*(a<0?1/-a:a)}function Vv(e,t,r){e=+e,t=+t,r=(a=arguments.length)<2?(t=e,e=0,1):a<3?1:+r;for(var n=-1,a=Math.max(0,Math.ceil((t-e)/r))|0,o=new Array(a);++n<a;)o[n]=e+n*r;return o}function ur(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function Iv(e,t){switch(arguments.length){case 0:break;case 1:{typeof e=="function"?this.interpolator(e):this.range(e);break}default:{this.domain(e),typeof t=="function"?this.interpolator(t):this.range(t);break}}return this}const pu=Symbol("implicit");function _o(){var e=new du,t=[],r=[],n=pu;function a(o){let s=e.get(o);if(s===void 0){if(n!==pu)return n;e.set(o,s=t.push(o)-1)}return r[s%r.length]}return a.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new du;for(const s of o)e.has(s)||e.set(s,t.push(s)-1);return a},a.range=function(o){return arguments.length?(r=Array.from(o),a):r.slice()},a.unknown=function(o){return arguments.length?(n=o,a):n},a.copy=function(){return _o(t,r).unknown(n)},ur.apply(a,arguments),a}function Ll(){var e=_o().unknown(void 0),t=e.domain,r=e.range,n=0,a=1,o,s,i=!1,l=0,c=0,u=.5;delete e.unknown;function d(){var h=t().length,p=a<n,f=p?a:n,m=p?n:a;o=(m-f)/Math.max(1,h-l+c*2),i&&(o=Math.floor(o)),f+=(m-f-o*(h-l))*u,s=o*(1-l),i&&(f=Math.round(f),s=Math.round(s));var b=Vv(h).map(function(x){return f+o*x});return r(p?b.reverse():b)}return e.domain=function(h){return arguments.length?(t(h),d()):t()},e.range=function(h){return arguments.length?([n,a]=h,n=+n,a=+a,d()):[n,a]},e.rangeRound=function(h){return[n,a]=h,n=+n,a=+a,i=!0,d()},e.bandwidth=function(){return s},e.step=function(){return o},e.round=function(h){return arguments.length?(i=!!h,d()):i},e.padding=function(h){return arguments.length?(l=Math.min(1,c=+h),d()):l},e.paddingInner=function(h){return arguments.length?(l=Math.min(1,h),d()):l},e.paddingOuter=function(h){return arguments.length?(c=+h,d()):c},e.align=function(h){return arguments.length?(u=Math.max(0,Math.min(1,h)),d()):u},e.copy=function(){return Ll(t(),[n,a]).round(i).paddingInner(l).paddingOuter(c).align(u)},ur.apply(d(),arguments)}function bp(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return bp(t())},e}function Mv(){return bp(Ll.apply(null,arguments).paddingInner(1))}function Dl(e,t,r){e.prototype=t.prototype=r,r.constructor=e}function vp(e,t){var r=Object.create(e.prototype);for(var n in t)r[n]=t[n];return r}function Pa(){}var ia=.7,Eo=1/ia,an="\\s*([+-]?\\d+)\\s*",la="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Mt="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",$v=/^#([0-9a-f]{3,8})$/,jv=new RegExp(`^rgb\\(${an},${an},${an}\\)$`),kv=new RegExp(`^rgb\\(${Mt},${Mt},${Mt}\\)$`),Uv=new RegExp(`^rgba\\(${an},${an},${an},${la}\\)$`),Lv=new RegExp(`^rgba\\(${Mt},${Mt},${Mt},${la}\\)$`),Dv=new RegExp(`^hsl\\(${la},${Mt},${Mt}\\)$`),Nv=new RegExp(`^hsla\\(${la},${Mt},${Mt},${la}\\)$`),mu={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Dl(Pa,ca,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:fu,formatHex:fu,formatHex8:Bv,formatHsl:Fv,formatRgb:gu,toString:gu});function fu(){return this.rgb().formatHex()}function Bv(){return this.rgb().formatHex8()}function Fv(){return Sp(this).formatHsl()}function gu(){return this.rgb().formatRgb()}function ca(e){var t,r;return e=(e+"").trim().toLowerCase(),(t=$v.exec(e))?(r=t[1].length,t=parseInt(t[1],16),r===6?yu(t):r===3?new ot(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):r===8?Ja(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?Ja(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=jv.exec(e))?new ot(t[1],t[2],t[3],1):(t=kv.exec(e))?new ot(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=Uv.exec(e))?Ja(t[1],t[2],t[3],t[4]):(t=Lv.exec(e))?Ja(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=Dv.exec(e))?Su(t[1],t[2]/100,t[3]/100,1):(t=Nv.exec(e))?Su(t[1],t[2]/100,t[3]/100,t[4]):mu.hasOwnProperty(e)?yu(mu[e]):e==="transparent"?new ot(NaN,NaN,NaN,0):null}function yu(e){return new ot(e>>16&255,e>>8&255,e&255,1)}function Ja(e,t,r,n){return n<=0&&(e=t=r=NaN),new ot(e,t,r,n)}function zv(e){return e instanceof Pa||(e=ca(e)),e?(e=e.rgb(),new ot(e.r,e.g,e.b,e.opacity)):new ot}function Fi(e,t,r,n){return arguments.length===1?zv(e):new ot(e,t,r,n??1)}function ot(e,t,r,n){this.r=+e,this.g=+t,this.b=+r,this.opacity=+n}Dl(ot,Fi,vp(Pa,{brighter(e){return e=e==null?Eo:Math.pow(Eo,e),new ot(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?ia:Math.pow(ia,e),new ot(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new ot(vr(this.r),vr(this.g),vr(this.b),Vo(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:bu,formatHex:bu,formatHex8:Gv,formatRgb:vu,toString:vu}));function bu(){return`#${fr(this.r)}${fr(this.g)}${fr(this.b)}`}function Gv(){return`#${fr(this.r)}${fr(this.g)}${fr(this.b)}${fr((isNaN(this.opacity)?1:this.opacity)*255)}`}function vu(){const e=Vo(this.opacity);return`${e===1?"rgb(":"rgba("}${vr(this.r)}, ${vr(this.g)}, ${vr(this.b)}${e===1?")":`, ${e})`}`}function Vo(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function vr(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function fr(e){return e=vr(e),(e<16?"0":"")+e.toString(16)}function Su(e,t,r,n){return n<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new xt(e,t,r,n)}function Sp(e){if(e instanceof xt)return new xt(e.h,e.s,e.l,e.opacity);if(e instanceof Pa||(e=ca(e)),!e)return new xt;if(e instanceof xt)return e;e=e.rgb();var t=e.r/255,r=e.g/255,n=e.b/255,a=Math.min(t,r,n),o=Math.max(t,r,n),s=NaN,i=o-a,l=(o+a)/2;return i?(t===o?s=(r-n)/i+(r<n)*6:r===o?s=(n-t)/i+2:s=(t-r)/i+4,i/=l<.5?o+a:2-o-a,s*=60):i=l>0&&l<1?0:s,new xt(s,i,l,e.opacity)}function Hv(e,t,r,n){return arguments.length===1?Sp(e):new xt(e,t,r,n??1)}function xt(e,t,r,n){this.h=+e,this.s=+t,this.l=+r,this.opacity=+n}Dl(xt,Hv,vp(Pa,{brighter(e){return e=e==null?Eo:Math.pow(Eo,e),new xt(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?ia:Math.pow(ia,e),new xt(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*t,a=2*r-n;return new ot(ni(e>=240?e-240:e+120,a,n),ni(e,a,n),ni(e<120?e+240:e-120,a,n),this.opacity)},clamp(){return new xt(xu(this.h),Wa(this.s),Wa(this.l),Vo(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Vo(this.opacity);return`${e===1?"hsl(":"hsla("}${xu(this.h)}, ${Wa(this.s)*100}%, ${Wa(this.l)*100}%${e===1?")":`, ${e})`}`}}));function xu(e){return e=(e||0)%360,e<0?e+360:e}function Wa(e){return Math.max(0,Math.min(1,e||0))}function ni(e,t,r){return(e<60?t+(r-t)*e/60:e<180?r:e<240?t+(r-t)*(240-e)/60:t)*255}const Nl=e=>()=>e;function qv(e,t){return function(r){return e+r*t}}function Jv(e,t,r){return e=Math.pow(e,r),t=Math.pow(t,r)-e,r=1/r,function(n){return Math.pow(e+n*t,r)}}function Wv(e){return(e=+e)==1?xp:function(t,r){return r-t?Jv(t,r,e):Nl(isNaN(t)?r:t)}}function xp(e,t){var r=t-e;return r?qv(e,r):Nl(isNaN(e)?t:e)}const Ou=function e(t){var r=Wv(t);function n(a,o){var s=r((a=Fi(a)).r,(o=Fi(o)).r),i=r(a.g,o.g),l=r(a.b,o.b),c=xp(a.opacity,o.opacity);return function(u){return a.r=s(u),a.g=i(u),a.b=l(u),a.opacity=c(u),a+""}}return n.gamma=e,n}(1);function Yv(e,t){t||(t=[]);var r=e?Math.min(t.length,e.length):0,n=t.slice(),a;return function(o){for(a=0;a<r;++a)n[a]=e[a]*(1-o)+t[a]*o;return n}}function Kv(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function Qv(e,t){var r=t?t.length:0,n=e?Math.min(r,e.length):0,a=new Array(n),o=new Array(r),s;for(s=0;s<n;++s)a[s]=hs(e[s],t[s]);for(;s<r;++s)o[s]=t[s];return function(i){for(s=0;s<n;++s)o[s]=a[s](i);return o}}function Bl(e,t){var r=new Date;return e=+e,t=+t,function(n){return r.setTime(e*(1-n)+t*n),r}}function Ot(e,t){return e=+e,t=+t,function(r){return e*(1-r)+t*r}}function Xv(e,t){var r={},n={},a;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(a in t)a in e?r[a]=hs(e[a],t[a]):n[a]=t[a];return function(o){for(a in r)n[a]=r[a](o);return n}}var zi=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,ai=new RegExp(zi.source,"g");function Zv(e){return function(){return e}}function e1(e){return function(t){return e(t)+""}}function t1(e,t){var r=zi.lastIndex=ai.lastIndex=0,n,a,o,s=-1,i=[],l=[];for(e=e+"",t=t+"";(n=zi.exec(e))&&(a=ai.exec(t));)(o=a.index)>r&&(o=t.slice(r,o),i[s]?i[s]+=o:i[++s]=o),(n=n[0])===(a=a[0])?i[s]?i[s]+=a:i[++s]=a:(i[++s]=null,l.push({i:s,x:Ot(n,a)})),r=ai.lastIndex;return r<t.length&&(o=t.slice(r),i[s]?i[s]+=o:i[++s]=o),i.length<2?l[0]?e1(l[0].x):Zv(t):(t=l.length,function(c){for(var u=0,d;u<t;++u)i[(d=l[u]).i]=d.x(c);return i.join("")})}function hs(e,t){var r=typeof t,n;return t==null||r==="boolean"?Nl(t):(r==="number"?Ot:r==="string"?(n=ca(t))?(t=n,Ou):t1:t instanceof ca?Ou:t instanceof Date?Bl:Kv(t)?Yv:Array.isArray(t)?Qv:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?Xv:Ot)(e,t)}function Op(e,t){return e=+e,t=+t,function(r){return Math.round(e*(1-r)+t*r)}}function r1(e){return function(){return e}}function n1(e){return+e}var wu=[0,1];function mt(e){return e}function Gi(e,t){return(t-=e=+e)?function(r){return(r-e)/t}:r1(isNaN(t)?NaN:.5)}function a1(e,t){var r;return e>t&&(r=e,e=t,t=r),function(n){return Math.max(e,Math.min(t,n))}}function o1(e,t,r){var n=e[0],a=e[1],o=t[0],s=t[1];return a<n?(n=Gi(a,n),o=r(s,o)):(n=Gi(n,a),o=r(o,s)),function(i){return o(n(i))}}function s1(e,t,r){var n=Math.min(e.length,t.length)-1,a=new Array(n),o=new Array(n),s=-1;for(e[n]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++s<n;)a[s]=Gi(e[s],e[s+1]),o[s]=r(t[s],t[s+1]);return function(i){var l=yp(e,i,1,n)-1;return o[l](a[l](i))}}function ps(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Fl(){var e=wu,t=wu,r=hs,n,a,o,s=mt,i,l,c;function u(){var h=Math.min(e.length,t.length);return s!==mt&&(s=a1(e[0],e[h-1])),i=h>2?s1:o1,l=c=null,d}function d(h){return h==null||isNaN(h=+h)?o:(l||(l=i(e.map(n),t,r)))(n(s(h)))}return d.invert=function(h){return s(a((c||(c=i(t,e.map(n),Ot)))(h)))},d.domain=function(h){return arguments.length?(e=Array.from(h,n1),u()):e.slice()},d.range=function(h){return arguments.length?(t=Array.from(h),u()):t.slice()},d.rangeRound=function(h){return t=Array.from(h),r=Op,u()},d.clamp=function(h){return arguments.length?(s=h?!0:mt,u()):s!==mt},d.interpolate=function(h){return arguments.length?(r=h,u()):r},d.unknown=function(h){return arguments.length?(o=h,d):o},function(h,p){return n=h,a=p,u()}}function wp(){return Fl()(mt,mt)}function i1(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Io(e,t){if((r=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var r,n=e.slice(0,r);return[n.length>1?n[0]+n.slice(2):n,+e.slice(r+1)]}function un(e){return e=Io(Math.abs(e)),e?e[1]:NaN}function l1(e,t){return function(r,n){for(var a=r.length,o=[],s=0,i=e[0],l=0;a>0&&i>0&&(l+i+1>n&&(i=Math.max(1,n-l)),o.push(r.substring(a-=i,a+i)),!((l+=i+1)>n));)i=e[s=(s+1)%e.length];return o.reverse().join(t)}}function c1(e){return function(t){return t.replace(/[0-9]/g,function(r){return e[+r]})}}var u1=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ua(e){if(!(t=u1.exec(e)))throw new Error("invalid format: "+e);var t;return new zl({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}ua.prototype=zl.prototype;function zl(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}zl.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function d1(e){e:for(var t=e.length,r=1,n=-1,a;r<t;++r)switch(e[r]){case".":n=a=r;break;case"0":n===0&&(n=r),a=r;break;default:if(!+e[r])break e;n>0&&(n=0);break}return n>0?e.slice(0,n)+e.slice(a+1):e}var Cp;function h1(e,t){var r=Io(e,t);if(!r)return e+"";var n=r[0],a=r[1],o=a-(Cp=Math.max(-8,Math.min(8,Math.floor(a/3)))*3)+1,s=n.length;return o===s?n:o>s?n+new Array(o-s+1).join("0"):o>0?n.slice(0,o)+"."+n.slice(o):"0."+new Array(1-o).join("0")+Io(e,Math.max(0,t+o-1))[0]}function Cu(e,t){var r=Io(e,t);if(!r)return e+"";var n=r[0],a=r[1];return a<0?"0."+new Array(-a).join("0")+n:n.length>a+1?n.slice(0,a+1)+"."+n.slice(a+1):n+new Array(a-n.length+2).join("0")}const Pu={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:i1,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>Cu(e*100,t),r:Cu,s:h1,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function Tu(e){return e}var Ru=Array.prototype.map,Au=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function p1(e){var t=e.grouping===void 0||e.thousands===void 0?Tu:l1(Ru.call(e.grouping,Number),e.thousands+""),r=e.currency===void 0?"":e.currency[0]+"",n=e.currency===void 0?"":e.currency[1]+"",a=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?Tu:c1(Ru.call(e.numerals,String)),s=e.percent===void 0?"%":e.percent+"",i=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function c(d){d=ua(d);var h=d.fill,p=d.align,f=d.sign,m=d.symbol,b=d.zero,x=d.width,_=d.comma,O=d.precision,C=d.trim,P=d.type;P==="n"?(_=!0,P="g"):Pu[P]||(O===void 0&&(O=12),C=!0,P="g"),(b||h==="0"&&p==="=")&&(b=!0,h="0",p="=");var w=m==="$"?r:m==="#"&&/[boxX]/.test(P)?"0"+P.toLowerCase():"",R=m==="$"?n:/[%p]/.test(P)?s:"",I=Pu[P],F=/[defgprs%]/.test(P);O=O===void 0?6:/[gprs]/.test(P)?Math.max(1,Math.min(21,O)):Math.max(0,Math.min(20,O));function y(T){var z=w,E=R,B,te,Z;if(P==="c")E=I(T)+E,T="";else{T=+T;var ae=T<0||1/T<0;if(T=isNaN(T)?l:I(Math.abs(T),O),C&&(T=d1(T)),ae&&+T==0&&f!=="+"&&(ae=!1),z=(ae?f==="("?f:i:f==="-"||f==="("?"":f)+z,E=(P==="s"?Au[8+Cp/3]:"")+E+(ae&&f==="("?")":""),F){for(B=-1,te=T.length;++B<te;)if(Z=T.charCodeAt(B),48>Z||Z>57){E=(Z===46?a+T.slice(B+1):T.slice(B))+E,T=T.slice(0,B);break}}}_&&!b&&(T=t(T,1/0));var re=z.length+T.length+E.length,le=re<x?new Array(x-re+1).join(h):"";switch(_&&b&&(T=t(le+T,le.length?x-E.length:1/0),le=""),p){case"<":T=z+T+E+le;break;case"=":T=z+le+T+E;break;case"^":T=le.slice(0,re=le.length>>1)+z+T+E+le.slice(re);break;default:T=le+z+T+E;break}return o(T)}return y.toString=function(){return d+""},y}function u(d,h){var p=c((d=ua(d),d.type="f",d)),f=Math.max(-8,Math.min(8,Math.floor(un(h)/3)))*3,m=Math.pow(10,-f),b=Au[8+f/3];return function(x){return p(m*x)+b}}return{format:c,formatPrefix:u}}var Ya,Gl,Pp;m1({thousands:",",grouping:[3],currency:["$",""]});function m1(e){return Ya=p1(e),Gl=Ya.format,Pp=Ya.formatPrefix,Ya}function f1(e){return Math.max(0,-un(Math.abs(e)))}function g1(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(un(t)/3)))*3-un(Math.abs(e)))}function y1(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,un(t)-un(e))+1}function b1(e,t,r,n){var a=Bi(e,t,r),o;switch(n=ua(n??",f"),n.type){case"s":{var s=Math.max(Math.abs(e),Math.abs(t));return n.precision==null&&!isNaN(o=g1(a,s))&&(n.precision=o),Pp(n,s)}case"":case"e":case"g":case"p":case"r":{n.precision==null&&!isNaN(o=y1(a,Math.max(Math.abs(e),Math.abs(t))))&&(n.precision=o-(n.type==="e"));break}case"f":case"%":{n.precision==null&&!isNaN(o=f1(a))&&(n.precision=o-(n.type==="%")*2);break}}return Gl(n)}function Hl(e){var t=e.domain;return e.ticks=function(r){var n=t();return Di(n[0],n[n.length-1],r??10)},e.tickFormat=function(r,n){var a=t();return b1(a[0],a[a.length-1],r??10,n)},e.nice=function(r){r==null&&(r=10);var n=t(),a=0,o=n.length-1,s=n[a],i=n[o],l,c,u=10;for(i<s&&(c=s,s=i,i=c,c=a,a=o,o=c);u-- >0;){if(c=Ni(s,i,r),c===l)return n[a]=s,n[o]=i,t(n);if(c>0)s=Math.floor(s/c)*c,i=Math.ceil(i/c)*c;else if(c<0)s=Math.ceil(s*c)/c,i=Math.floor(i*c)/c;else break;l=c}return e},e}function Tp(){var e=wp();return e.copy=function(){return ps(e,Tp())},ur.apply(e,arguments),Hl(e)}function Rp(e,t){e=e.slice();var r=0,n=e.length-1,a=e[r],o=e[n],s;return o<a&&(s=r,r=n,n=s,s=a,a=o,o=s),e[r]=t.floor(a),e[n]=t.ceil(o),e}function _u(e){return Math.log(e)}function Eu(e){return Math.exp(e)}function v1(e){return-Math.log(-e)}function S1(e){return-Math.exp(-e)}function x1(e){return isFinite(e)?+("1e"+e):e<0?0:e}function O1(e){return e===10?x1:e===Math.E?Math.exp:t=>Math.pow(e,t)}function w1(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function Vu(e){return(t,r)=>-e(-t,r)}function C1(e){const t=e(_u,Eu),r=t.domain;let n=10,a,o;function s(){return a=w1(n),o=O1(n),r()[0]<0?(a=Vu(a),o=Vu(o),e(v1,S1)):e(_u,Eu),t}return t.base=function(i){return arguments.length?(n=+i,s()):n},t.domain=function(i){return arguments.length?(r(i),s()):r()},t.ticks=i=>{const l=r();let c=l[0],u=l[l.length-1];const d=u<c;d&&([c,u]=[u,c]);let h=a(c),p=a(u),f,m;const b=i==null?10:+i;let x=[];if(!(n%1)&&p-h<b){if(h=Math.floor(h),p=Math.ceil(p),c>0){for(;h<=p;++h)for(f=1;f<n;++f)if(m=h<0?f/o(-h):f*o(h),!(m<c)){if(m>u)break;x.push(m)}}else for(;h<=p;++h)for(f=n-1;f>=1;--f)if(m=h>0?f/o(-h):f*o(h),!(m<c)){if(m>u)break;x.push(m)}x.length*2<b&&(x=Di(c,u,b))}else x=Di(h,p,Math.min(p-h,b)).map(o);return d?x.reverse():x},t.tickFormat=(i,l)=>{if(i==null&&(i=10),l==null&&(l=n===10?"s":","),typeof l!="function"&&(!(n%1)&&(l=ua(l)).precision==null&&(l.trim=!0),l=Gl(l)),i===1/0)return l;const c=Math.max(1,n*i/t.ticks().length);return u=>{let d=u/o(Math.round(a(u)));return d*n<n-.5&&(d*=n),d<=c?l(u):""}},t.nice=()=>r(Rp(r(),{floor:i=>o(Math.floor(a(i))),ceil:i=>o(Math.ceil(a(i)))})),t}function Ap(){const e=C1(Fl()).domain([1,10]);return e.copy=()=>ps(e,Ap()).base(e.base()),ur.apply(e,arguments),e}function Iu(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function P1(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function T1(e){return e<0?-e*e:e*e}function R1(e){var t=e(mt,mt),r=1;function n(){return r===1?e(mt,mt):r===.5?e(P1,T1):e(Iu(r),Iu(1/r))}return t.exponent=function(a){return arguments.length?(r=+a,n()):r},Hl(t)}function ql(){var e=R1(Fl());return e.copy=function(){return ps(e,ql()).exponent(e.exponent())},ur.apply(e,arguments),e}function A1(){return ql.apply(null,arguments).exponent(.5)}function _p(){var e=[.5],t=[0,1],r,n=1;function a(o){return o!=null&&o<=o?t[yp(e,o,0,n)]:r}return a.domain=function(o){return arguments.length?(e=Array.from(o),n=Math.min(e.length,t.length-1),a):e.slice()},a.range=function(o){return arguments.length?(t=Array.from(o),n=Math.min(e.length,t.length-1),a):t.slice()},a.invertExtent=function(o){var s=t.indexOf(o);return[e[s-1],e[s]]},a.unknown=function(o){return arguments.length?(r=o,a):r},a.copy=function(){return _p().domain(e).range(t).unknown(r)},ur.apply(a,arguments)}const oi=new Date,si=new Date;function Fe(e,t,r,n){function a(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return a.floor=o=>(e(o=new Date(+o)),o),a.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),a.round=o=>{const s=a(o),i=a.ceil(o);return o-s<i-o?s:i},a.offset=(o,s)=>(t(o=new Date(+o),s==null?1:Math.floor(s)),o),a.range=(o,s,i)=>{const l=[];if(o=a.ceil(o),i=i==null?1:Math.floor(i),!(o<s)||!(i>0))return l;let c;do l.push(c=new Date(+o)),t(o,i),e(o);while(c<o&&o<s);return l},a.filter=o=>Fe(s=>{if(s>=s)for(;e(s),!o(s);)s.setTime(s-1)},(s,i)=>{if(s>=s)if(i<0)for(;++i<=0;)for(;t(s,-1),!o(s););else for(;--i>=0;)for(;t(s,1),!o(s););}),r&&(a.count=(o,s)=>(oi.setTime(+o),si.setTime(+s),e(oi),e(si),Math.floor(r(oi,si))),a.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?a.filter(n?s=>n(s)%o===0:s=>a.count(0,s)%o===0):a)),a}const Mo=Fe(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Mo.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Fe(t=>{t.setTime(Math.floor(t/e)*e)},(t,r)=>{t.setTime(+t+r*e)},(t,r)=>(r-t)/e):Mo);Mo.range;const Dt=1e3,ft=Dt*60,Nt=ft*60,Gt=Nt*24,Jl=Gt*7,Mu=Gt*30,ii=Gt*365,gr=Fe(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Dt)},(e,t)=>(t-e)/Dt,e=>e.getUTCSeconds());gr.range;const Wl=Fe(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Dt)},(e,t)=>{e.setTime(+e+t*ft)},(e,t)=>(t-e)/ft,e=>e.getMinutes());Wl.range;const Yl=Fe(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*ft)},(e,t)=>(t-e)/ft,e=>e.getUTCMinutes());Yl.range;const Kl=Fe(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Dt-e.getMinutes()*ft)},(e,t)=>{e.setTime(+e+t*Nt)},(e,t)=>(t-e)/Nt,e=>e.getHours());Kl.range;const Ql=Fe(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*Nt)},(e,t)=>(t-e)/Nt,e=>e.getUTCHours());Ql.range;const Ta=Fe(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*ft)/Gt,e=>e.getDate()-1);Ta.range;const ms=Fe(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Gt,e=>e.getUTCDate()-1);ms.range;const Ep=Fe(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Gt,e=>Math.floor(e/Gt));Ep.range;function Rr(e){return Fe(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,r)=>{t.setDate(t.getDate()+r*7)},(t,r)=>(r-t-(r.getTimezoneOffset()-t.getTimezoneOffset())*ft)/Jl)}const fs=Rr(0),$o=Rr(1),_1=Rr(2),E1=Rr(3),dn=Rr(4),V1=Rr(5),I1=Rr(6);fs.range;$o.range;_1.range;E1.range;dn.range;V1.range;I1.range;function Ar(e){return Fe(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCDate(t.getUTCDate()+r*7)},(t,r)=>(r-t)/Jl)}const gs=Ar(0),jo=Ar(1),M1=Ar(2),$1=Ar(3),hn=Ar(4),j1=Ar(5),k1=Ar(6);gs.range;jo.range;M1.range;$1.range;hn.range;j1.range;k1.range;const Xl=Fe(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());Xl.range;const Zl=Fe(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());Zl.range;const Ht=Fe(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());Ht.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Fe(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,r)=>{t.setFullYear(t.getFullYear()+r*e)});Ht.range;const qt=Fe(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());qt.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Fe(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCFullYear(t.getUTCFullYear()+r*e)});qt.range;function Vp(e,t,r,n,a,o){const s=[[gr,1,Dt],[gr,5,5*Dt],[gr,15,15*Dt],[gr,30,30*Dt],[o,1,ft],[o,5,5*ft],[o,15,15*ft],[o,30,30*ft],[a,1,Nt],[a,3,3*Nt],[a,6,6*Nt],[a,12,12*Nt],[n,1,Gt],[n,2,2*Gt],[r,1,Jl],[t,1,Mu],[t,3,3*Mu],[e,1,ii]];function i(c,u,d){const h=u<c;h&&([c,u]=[u,c]);const p=d&&typeof d.range=="function"?d:l(c,u,d),f=p?p.range(c,+u+1):[];return h?f.reverse():f}function l(c,u,d){const h=Math.abs(u-c)/d,p=Ul(([,,b])=>b).right(s,h);if(p===s.length)return e.every(Bi(c/ii,u/ii,d));if(p===0)return Mo.every(Math.max(Bi(c,u,d),1));const[f,m]=s[h/s[p-1][2]<s[p][2]/h?p-1:p];return f.every(m)}return[i,l]}const[U1,L1]=Vp(qt,Zl,gs,Ep,Ql,Yl),[D1,N1]=Vp(Ht,Xl,fs,Ta,Kl,Wl);function li(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function ci(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function jn(e,t,r){return{y:e,m:t,d:r,H:0,M:0,S:0,L:0}}function B1(e){var t=e.dateTime,r=e.date,n=e.time,a=e.periods,o=e.days,s=e.shortDays,i=e.months,l=e.shortMonths,c=kn(a),u=Un(a),d=kn(o),h=Un(o),p=kn(s),f=Un(s),m=kn(i),b=Un(i),x=kn(l),_=Un(l),O={a:ae,A:re,b:le,B:J,c:null,d:Du,e:Du,f:uS,g:SS,G:OS,H:iS,I:lS,j:cS,L:Ip,m:dS,M:hS,p:X,q:he,Q:Fu,s:zu,S:pS,u:mS,U:fS,V:gS,w:yS,W:bS,x:null,X:null,y:vS,Y:xS,Z:wS,"%":Bu},C={a:Pe,A:ze,b:xe,B:it,c:null,d:Nu,e:Nu,f:RS,g:US,G:DS,H:CS,I:PS,j:TS,L:$p,m:AS,M:_S,p:tt,q:ye,Q:Fu,s:zu,S:ES,u:VS,U:IS,V:MS,w:$S,W:jS,x:null,X:null,y:kS,Y:LS,Z:NS,"%":Bu},P={a:y,A:T,b:z,B:E,c:B,d:Uu,e:Uu,f:nS,g:ku,G:ju,H:Lu,I:Lu,j:Z1,L:rS,m:X1,M:eS,p:F,q:Q1,Q:oS,s:sS,S:tS,u:q1,U:J1,V:W1,w:H1,W:Y1,x:te,X:Z,y:ku,Y:ju,Z:K1,"%":aS};O.x=w(r,O),O.X=w(n,O),O.c=w(t,O),C.x=w(r,C),C.X=w(n,C),C.c=w(t,C);function w(Q,oe){return function(ce){var W=[],be=-1,me=0,Je=Q.length,Ge,Me,Qt;for(ce instanceof Date||(ce=new Date(+ce));++be<Je;)Q.charCodeAt(be)===37&&(W.push(Q.slice(me,be)),(Me=$u[Ge=Q.charAt(++be)])!=null?Ge=Q.charAt(++be):Me=Ge==="e"?" ":"0",(Qt=oe[Ge])&&(Ge=Qt(ce,Me)),W.push(Ge),me=be+1);return W.push(Q.slice(me,be)),W.join("")}}function R(Q,oe){return function(ce){var W=jn(1900,void 0,1),be=I(W,Q,ce+="",0),me,Je;if(be!=ce.length)return null;if("Q"in W)return new Date(W.Q);if("s"in W)return new Date(W.s*1e3+("L"in W?W.L:0));if(oe&&!("Z"in W)&&(W.Z=0),"p"in W&&(W.H=W.H%12+W.p*12),W.m===void 0&&(W.m="q"in W?W.q:0),"V"in W){if(W.V<1||W.V>53)return null;"w"in W||(W.w=1),"Z"in W?(me=ci(jn(W.y,0,1)),Je=me.getUTCDay(),me=Je>4||Je===0?jo.ceil(me):jo(me),me=ms.offset(me,(W.V-1)*7),W.y=me.getUTCFullYear(),W.m=me.getUTCMonth(),W.d=me.getUTCDate()+(W.w+6)%7):(me=li(jn(W.y,0,1)),Je=me.getDay(),me=Je>4||Je===0?$o.ceil(me):$o(me),me=Ta.offset(me,(W.V-1)*7),W.y=me.getFullYear(),W.m=me.getMonth(),W.d=me.getDate()+(W.w+6)%7)}else("W"in W||"U"in W)&&("w"in W||(W.w="u"in W?W.u%7:"W"in W?1:0),Je="Z"in W?ci(jn(W.y,0,1)).getUTCDay():li(jn(W.y,0,1)).getDay(),W.m=0,W.d="W"in W?(W.w+6)%7+W.W*7-(Je+5)%7:W.w+W.U*7-(Je+6)%7);return"Z"in W?(W.H+=W.Z/100|0,W.M+=W.Z%100,ci(W)):li(W)}}function I(Q,oe,ce,W){for(var be=0,me=oe.length,Je=ce.length,Ge,Me;be<me;){if(W>=Je)return-1;if(Ge=oe.charCodeAt(be++),Ge===37){if(Ge=oe.charAt(be++),Me=P[Ge in $u?oe.charAt(be++):Ge],!Me||(W=Me(Q,ce,W))<0)return-1}else if(Ge!=ce.charCodeAt(W++))return-1}return W}function F(Q,oe,ce){var W=c.exec(oe.slice(ce));return W?(Q.p=u.get(W[0].toLowerCase()),ce+W[0].length):-1}function y(Q,oe,ce){var W=p.exec(oe.slice(ce));return W?(Q.w=f.get(W[0].toLowerCase()),ce+W[0].length):-1}function T(Q,oe,ce){var W=d.exec(oe.slice(ce));return W?(Q.w=h.get(W[0].toLowerCase()),ce+W[0].length):-1}function z(Q,oe,ce){var W=x.exec(oe.slice(ce));return W?(Q.m=_.get(W[0].toLowerCase()),ce+W[0].length):-1}function E(Q,oe,ce){var W=m.exec(oe.slice(ce));return W?(Q.m=b.get(W[0].toLowerCase()),ce+W[0].length):-1}function B(Q,oe,ce){return I(Q,t,oe,ce)}function te(Q,oe,ce){return I(Q,r,oe,ce)}function Z(Q,oe,ce){return I(Q,n,oe,ce)}function ae(Q){return s[Q.getDay()]}function re(Q){return o[Q.getDay()]}function le(Q){return l[Q.getMonth()]}function J(Q){return i[Q.getMonth()]}function X(Q){return a[+(Q.getHours()>=12)]}function he(Q){return 1+~~(Q.getMonth()/3)}function Pe(Q){return s[Q.getUTCDay()]}function ze(Q){return o[Q.getUTCDay()]}function xe(Q){return l[Q.getUTCMonth()]}function it(Q){return i[Q.getUTCMonth()]}function tt(Q){return a[+(Q.getUTCHours()>=12)]}function ye(Q){return 1+~~(Q.getUTCMonth()/3)}return{format:function(Q){var oe=w(Q+="",O);return oe.toString=function(){return Q},oe},parse:function(Q){var oe=R(Q+="",!1);return oe.toString=function(){return Q},oe},utcFormat:function(Q){var oe=w(Q+="",C);return oe.toString=function(){return Q},oe},utcParse:function(Q){var oe=R(Q+="",!0);return oe.toString=function(){return Q},oe}}}var $u={"-":"",_:" ",0:"0"},qe=/^\s*\d+/,F1=/^%/,z1=/[\\^$*+?|[\]().{}]/g;function ge(e,t,r){var n=e<0?"-":"",a=(n?-e:e)+"",o=a.length;return n+(o<r?new Array(r-o+1).join(t)+a:a)}function G1(e){return e.replace(z1,"\\$&")}function kn(e){return new RegExp("^(?:"+e.map(G1).join("|")+")","i")}function Un(e){return new Map(e.map((t,r)=>[t.toLowerCase(),r]))}function H1(e,t,r){var n=qe.exec(t.slice(r,r+1));return n?(e.w=+n[0],r+n[0].length):-1}function q1(e,t,r){var n=qe.exec(t.slice(r,r+1));return n?(e.u=+n[0],r+n[0].length):-1}function J1(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.U=+n[0],r+n[0].length):-1}function W1(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.V=+n[0],r+n[0].length):-1}function Y1(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.W=+n[0],r+n[0].length):-1}function ju(e,t,r){var n=qe.exec(t.slice(r,r+4));return n?(e.y=+n[0],r+n[0].length):-1}function ku(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.y=+n[0]+(+n[0]>68?1900:2e3),r+n[0].length):-1}function K1(e,t,r){var n=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(r,r+6));return n?(e.Z=n[1]?0:-(n[2]+(n[3]||"00")),r+n[0].length):-1}function Q1(e,t,r){var n=qe.exec(t.slice(r,r+1));return n?(e.q=n[0]*3-3,r+n[0].length):-1}function X1(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.m=n[0]-1,r+n[0].length):-1}function Uu(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.d=+n[0],r+n[0].length):-1}function Z1(e,t,r){var n=qe.exec(t.slice(r,r+3));return n?(e.m=0,e.d=+n[0],r+n[0].length):-1}function Lu(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.H=+n[0],r+n[0].length):-1}function eS(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.M=+n[0],r+n[0].length):-1}function tS(e,t,r){var n=qe.exec(t.slice(r,r+2));return n?(e.S=+n[0],r+n[0].length):-1}function rS(e,t,r){var n=qe.exec(t.slice(r,r+3));return n?(e.L=+n[0],r+n[0].length):-1}function nS(e,t,r){var n=qe.exec(t.slice(r,r+6));return n?(e.L=Math.floor(n[0]/1e3),r+n[0].length):-1}function aS(e,t,r){var n=F1.exec(t.slice(r,r+1));return n?r+n[0].length:-1}function oS(e,t,r){var n=qe.exec(t.slice(r));return n?(e.Q=+n[0],r+n[0].length):-1}function sS(e,t,r){var n=qe.exec(t.slice(r));return n?(e.s=+n[0],r+n[0].length):-1}function Du(e,t){return ge(e.getDate(),t,2)}function iS(e,t){return ge(e.getHours(),t,2)}function lS(e,t){return ge(e.getHours()%12||12,t,2)}function cS(e,t){return ge(1+Ta.count(Ht(e),e),t,3)}function Ip(e,t){return ge(e.getMilliseconds(),t,3)}function uS(e,t){return Ip(e,t)+"000"}function dS(e,t){return ge(e.getMonth()+1,t,2)}function hS(e,t){return ge(e.getMinutes(),t,2)}function pS(e,t){return ge(e.getSeconds(),t,2)}function mS(e){var t=e.getDay();return t===0?7:t}function fS(e,t){return ge(fs.count(Ht(e)-1,e),t,2)}function Mp(e){var t=e.getDay();return t>=4||t===0?dn(e):dn.ceil(e)}function gS(e,t){return e=Mp(e),ge(dn.count(Ht(e),e)+(Ht(e).getDay()===4),t,2)}function yS(e){return e.getDay()}function bS(e,t){return ge($o.count(Ht(e)-1,e),t,2)}function vS(e,t){return ge(e.getFullYear()%100,t,2)}function SS(e,t){return e=Mp(e),ge(e.getFullYear()%100,t,2)}function xS(e,t){return ge(e.getFullYear()%1e4,t,4)}function OS(e,t){var r=e.getDay();return e=r>=4||r===0?dn(e):dn.ceil(e),ge(e.getFullYear()%1e4,t,4)}function wS(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ge(t/60|0,"0",2)+ge(t%60,"0",2)}function Nu(e,t){return ge(e.getUTCDate(),t,2)}function CS(e,t){return ge(e.getUTCHours(),t,2)}function PS(e,t){return ge(e.getUTCHours()%12||12,t,2)}function TS(e,t){return ge(1+ms.count(qt(e),e),t,3)}function $p(e,t){return ge(e.getUTCMilliseconds(),t,3)}function RS(e,t){return $p(e,t)+"000"}function AS(e,t){return ge(e.getUTCMonth()+1,t,2)}function _S(e,t){return ge(e.getUTCMinutes(),t,2)}function ES(e,t){return ge(e.getUTCSeconds(),t,2)}function VS(e){var t=e.getUTCDay();return t===0?7:t}function IS(e,t){return ge(gs.count(qt(e)-1,e),t,2)}function jp(e){var t=e.getUTCDay();return t>=4||t===0?hn(e):hn.ceil(e)}function MS(e,t){return e=jp(e),ge(hn.count(qt(e),e)+(qt(e).getUTCDay()===4),t,2)}function $S(e){return e.getUTCDay()}function jS(e,t){return ge(jo.count(qt(e)-1,e),t,2)}function kS(e,t){return ge(e.getUTCFullYear()%100,t,2)}function US(e,t){return e=jp(e),ge(e.getUTCFullYear()%100,t,2)}function LS(e,t){return ge(e.getUTCFullYear()%1e4,t,4)}function DS(e,t){var r=e.getUTCDay();return e=r>=4||r===0?hn(e):hn.ceil(e),ge(e.getUTCFullYear()%1e4,t,4)}function NS(){return"+0000"}function Bu(){return"%"}function Fu(e){return+e}function zu(e){return Math.floor(+e/1e3)}var Gr,kp,Up;BS({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function BS(e){return Gr=B1(e),kp=Gr.format,Gr.parse,Up=Gr.utcFormat,Gr.utcParse,Gr}function FS(e){return new Date(e)}function zS(e){return e instanceof Date?+e:+new Date(+e)}function ec(e,t,r,n,a,o,s,i,l,c){var u=wp(),d=u.invert,h=u.domain,p=c(".%L"),f=c(":%S"),m=c("%I:%M"),b=c("%I %p"),x=c("%a %d"),_=c("%b %d"),O=c("%B"),C=c("%Y");function P(w){return(l(w)<w?p:i(w)<w?f:s(w)<w?m:o(w)<w?b:n(w)<w?a(w)<w?x:_:r(w)<w?O:C)(w)}return u.invert=function(w){return new Date(d(w))},u.domain=function(w){return arguments.length?h(Array.from(w,zS)):h().map(FS)},u.ticks=function(w){var R=h();return e(R[0],R[R.length-1],w??10)},u.tickFormat=function(w,R){return R==null?P:c(R)},u.nice=function(w){var R=h();return(!w||typeof w.range!="function")&&(w=t(R[0],R[R.length-1],w??10)),w?h(Rp(R,w)):u},u.copy=function(){return ps(u,ec(e,t,r,n,a,o,s,i,l,c))},u}function Lp(){return ur.apply(ec(D1,N1,Ht,Xl,fs,Ta,Kl,Wl,gr,kp).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function GS(){return ur.apply(ec(U1,L1,qt,Zl,gs,ms,Ql,Yl,gr,Up).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function HS(){var e=0,t=1,r,n,a,o,s=mt,i=!1,l;function c(d){return d==null||isNaN(d=+d)?l:s(a===0?.5:(d=(o(d)-r)*a,i?Math.max(0,Math.min(1,d)):d))}c.domain=function(d){return arguments.length?([e,t]=d,r=o(e=+e),n=o(t=+t),a=r===n?0:1/(n-r),c):[e,t]},c.clamp=function(d){return arguments.length?(i=!!d,c):i},c.interpolator=function(d){return arguments.length?(s=d,c):s};function u(d){return function(h){var p,f;return arguments.length?([p,f]=h,s=d(p,f),c):[s(0),s(1)]}}return c.range=u(hs),c.rangeRound=u(Op),c.unknown=function(d){return arguments.length?(l=d,c):l},function(d){return o=d,r=d(e),n=d(t),a=r===n?0:1/(n-r),c}}function qS(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function Dp(){var e=Hl(HS()(mt));return e.copy=function(){return qS(e,Dp())},Iv.apply(e,arguments)}function JS(e,t){return function(n,a){return a.location==="tick"?a.scale.tickFormat(e)(n):a.location==="zoom-slider-tooltip"?t.tickFormat(2)(n):`${n}`}}function WS(e){return e.scaleType==="band"}function YS(e){return e.scaleType==="point"}function KS(e){return e.type==="piecewise"?_p(e.thresholds,e.colors):Dp([e.min??0,e.max??100],e.color)}function ko(e){return e.values?_o(e.values,e.colors).unknown(e.unknownColor??null):_o(e.colors.map((t,r)=>r),e.colors).unknown(e.unknownColor??null)}function fo(e){return e.type==="ordinal"?ko(e):KS(e)}function QS(e){const{tickMaxStep:t,tickMinStep:r,tickNumber:n,range:a,domain:o}=e,s=r===void 0?999:Math.floor(Math.abs(o[1]-o[0])/r),i=t===void 0?2:Math.ceil(Math.abs(o[1]-o[0])/t),l=n??Math.floor(Math.abs(a[1]-a[0])/50);return Math.min(s,Math.max(i,l))}function XS(e,t){return t[1]-t[0]===0?1:e/((t[1]-t[0])/100)}function Hi(e,t,r){switch(e){case"log":return Ap(t,r);case"pow":return ql(t,r);case"sqrt":return A1(t,r);case"time":return Lp(t,r);case"utc":return GS(t,r);default:return Tp(t,r)}}const Gu=e=>(e==null?void 0:e[0])instanceof Date;function Hu(e,t){const r=Lp(e.data,t);return(n,{location:a})=>a==="tick"?r.tickFormat(e.tickNumber)(n):`${n.toLocaleString()}`}const ui=(e,t)=>{const r=e[1]-e[0],n=t[1]-t[0],a=e[0]-t[0]*r/n,o=e[1]+(100-t[1])*r/n;return[a,o]};let qu,Ju;class ZS{constructor(){if(this.types=new Set,qu)throw new Error("You can only create one instance!");qu=this.types}addType(t){this.types.add(t)}getTypes(){return this.types}}class ex{constructor(){if(this.types=new Set,Ju)throw new Error("You can only create one instance!");Ju=this.types}addType(t){this.types.add(t)}getTypes(){return this.types}}const ys=new ZS;ys.addType("bar");ys.addType("line");ys.addType("scatter");const tx=new ex;tx.addType("radar");function Np(e){return ys.getTypes().has(e)}const rx=(e,t,r,n,a,o,s,i)=>{var f;const l=n==="x"?a[t].xExtremumGetter:a[t].yExtremumGetter,c=((f=s[t])==null?void 0:f.series)??{},[u,d]=(l==null?void 0:l({series:c,axis:r,axisIndex:o,isDefaultAxis:o===0,getFilters:i}))??[1/0,-1/0],[h,p]=e;return[Math.min(u,h),Math.max(d,p)]},Bp=(e,t,r,n,a,o)=>{const i=Object.keys(r).filter(Np).reduce((l,c)=>rx(l,c,e,t,r,n,a,o),[1/0,-1/0]);return Number.isNaN(i[0])||Number.isNaN(i[1])?[1/0,-1/0]:i},nx=(e,t,r,n)=>{const a=new Set;return Object.keys(t).filter(Np).forEach(s=>{var c,u,d;const i=((c=r[s])==null?void 0:c.series)??{},l=(d=(u=t[s]).axisTooltipGetter)==null?void 0:d.call(u,i);l!==void 0&&l.forEach(({axisId:h,direction:p})=>{p===e&&a.add(h??n)})}),a},ax=(e,t,r,n)=>{var a;if(e.domainLimit!==void 0)return e.domainLimit;if(t==="x")for(const o of((a=n.line)==null?void 0:a.seriesOrder)??[]){const s=n.line.series[o];if(s.xAxisId===e.id||s.xAxisId===void 0&&r===0)return"strict"}return"nice"};function ox(e,t,r){const n=t==="x"?[e.left,e.left+e.width]:[e.top+e.height,e.top];return r.reverse?[n[1],n[0]]:n}const sx=.2,ix=.1;function Fp({drawingArea:e,formattedSeries:t,axis:r,seriesConfig:n,axisDirection:a,zoomMap:o,zoomOptions:s,getFilters:i,preferStrictDomainInLineCharts:l}){if(r===void 0)return{axis:{},axisIds:[]};const c=nx(a,n,t,r[0].id),u={};return r.forEach((d,h)=>{const p=d,f=s==null?void 0:s[p.id],m=o==null?void 0:o.get(p.id),b=m?[m.start,m.end]:[0,100],x=ox(e,a,p),[_,O]=Bp(p,a,n,h,t,m===void 0&&!f?i:void 0),C=!p.ignoreTooltip&&c.has(p.id),P=p.data??[];if(WS(p)){const ae=p.categoryGapRatio??sx,re=p.barGapRatio??ix,le=a==="y"?[x[1],x[0]]:x,J=ui(le,b);if(u[p.id]=Y({offset:0,height:0,categoryGapRatio:ae,barGapRatio:re,triggerTooltip:C},p,{data:P,scale:Ll(p.data,J).paddingInner(ae).paddingOuter(ae/2),tickNumber:p.data.length,colorScale:p.colorMap&&(p.colorMap.type==="ordinal"?ko(Y({values:p.data},p.colorMap)):fo(p.colorMap))}),Gu(p.data)){const X=Hu(p,le);u[p.id].valueFormatter=p.valueFormatter??X}}if(YS(p)){const ae=a==="y"?[...x].reverse():x,re=ui(ae,b);if(u[p.id]=Y({offset:0,height:0,triggerTooltip:C},p,{data:P,scale:Mv(p.data,re),tickNumber:p.data.length,colorScale:p.colorMap&&(p.colorMap.type==="ordinal"?ko(Y({values:p.data},p.colorMap)):fo(p.colorMap))}),Gu(p.data)){const le=Hu(p,ae);u[p.id].valueFormatter=p.valueFormatter??le}}if(p.scaleType==="band"||p.scaleType==="point")return;const w=p.scaleType??"linear",R=l?ax(p,a,h,t):p.domainLimit??"nice",I=[p.min??_,p.max??O];if(typeof R=="function"){const{min:ae,max:re}=R(_,O);I[0]=ae,I[1]=re}const F=QS(Y({},p,{range:x,domain:I})),y=XS(F,b),T=ui(x,b),z=Hi(w,I,T),E=R==="nice"?z.nice(F):z,[B,te]=E.domain(),Z=[p.min??B,p.max??te];u[p.id]=Y({offset:0,height:0,triggerTooltip:C},p,{data:P,scaleType:w,scale:E.domain(Z),tickNumber:y,colorScale:p.colorMap&&fo(p.colorMap),valueFormatter:p.valueFormatter??JS(y,Hi(w,x.map(ae=>z.invert(ae)),x))})}),{axis:u,axisIds:r.map(({id:d})=>d)}}function lx(e){return e!=null}function zp({zoomMap:e,zoomOptions:t,seriesConfig:r,formattedSeries:n,direction:a}){return(o,s)=>{var b;const i=t[o.id];if(!i||i.filterMode!=="discard")return null;const l=e==null?void 0:e.get(o.id);if(l===void 0||l.start<=0&&l.end>=100)return null;let c=[];const u=o.scaleType;u==="point"||u==="band"?c=[0,(((b=o.data)==null?void 0:b.length)??1)-1]:c=Bp(o,a,r,s,n);let d,h;[d,h]=Hi(!u||u==="band"||u==="point"?"linear":u,c,[0,100]).nice().domain(),d=d instanceof Date?d.getTime():d,h=h instanceof Date?h.getTime():h;const f=d+l.start*(h-d)/100,m=d+l.end*(h-d)/100;return(x,_)=>{var C;const O=x[a]??((C=o.data)==null?void 0:C[_]);return O==null?!0:o.scaleType==="point"||o.scaleType==="band"||typeof O=="string"?_>=f&&_<=m:O>=f&&O<=m}}}const cx=e=>({currentAxisId:t,seriesXAxisId:r,seriesYAxisId:n,isDefaultAxis:a})=>(o,s)=>{var c,u;return!(t===r?n:r)||a?((u=(c=Object.values(e??{}))[0])==null?void 0:u.call(c,o,s))??!0:[n,r].filter(d=>d!==t).map(d=>e[d??""]).filter(lx).every(d=>d(o,s))},Wu=e=>(t=[])=>t.reduce((r,n)=>{const{zoom:a,id:o}=n,s=kl(a,o,e);return s&&(r[o]=s),r},{}),ux=e=>{const t=new Map;return e.forEach(r=>{t.set(r.axisId,r)}),t},Gp=e=>e.zoom;pe([Gp],e=>e==null?void 0:e.isInteracting);const bs=pe([Gp],e=>(e==null?void 0:e.zoomData)&&ux(e==null?void 0:e.zoomData)),Ra=pe([bn,vn],(e,t)=>Y({},Wu("x")(e),Wu("y")(t)));pe([Ra,(e,t)=>t],(e,t)=>e[t]);const dx=pe([bs,Ra,ds,wa],(e,t,r,n)=>e&&t&&zp({zoomMap:e,zoomOptions:t,seriesConfig:r,formattedSeries:n,direction:"x"})),hx=pe([bs,Ra,ds,wa],(e,t,r,n)=>e&&t&&zp({zoomMap:e,zoomOptions:t,seriesConfig:r,formattedSeries:n,direction:"y"})),Hp=pe([dx,hx,bn,vn],(e,t,r,n)=>{if(e===void 0||t===void 0)return;const a=r==null?void 0:r.reduce((s,i,l)=>{const c=e(i,l);return c!==null&&(s[i.id]=c),s},{}),o=n==null?void 0:n.reduce((s,i,l)=>{const c=t(i,l);return c!==null&&(s[i.id]=c),s},{});if(!(Object.keys(a??{}).length===0&&Object.keys(o??{}).length===0))return cx(Y({},a,o))}),_r=pe([bn,Oa,wa,ds,bs,Ra,Hp,ip],(e,t,r,n,a,o,s,i)=>Fp({drawingArea:t,formattedSeries:r,axis:e,seriesConfig:n,axisDirection:"x",zoomMap:a,zoomOptions:o,getFilters:s,preferStrictDomainInLineCharts:i})),Er=pe([vn,Oa,wa,ds,bs,Ra,Hp,ip],(e,t,r,n,a,o,s,i)=>Fp({drawingArea:t,formattedSeries:r,axis:e,seriesConfig:n,axisDirection:"y",zoomMap:a,zoomOptions:o,getFilters:s,preferStrictDomainInLineCharts:i}));pe([_r,Er,(e,t)=>t],(e,t,r)=>(e==null?void 0:e.axis[r])??(t==null?void 0:t.axis[r]));pe([bn,vn,(e,t)=>t],(e,t,r)=>{const n=(e==null?void 0:e.find(a=>a.id===r))??(t==null?void 0:t.find(a=>a.id===r))??null;if(n)return n});function qp(e){return e.bandwidth!==void 0}function Hr(e){return e instanceof Date?e.getTime():e}function pn(e,t){const{scale:r,data:n,reverse:a}=e;if(!qp(r)){const s=r.invert(t);if(n===void 0)return-1;const i=Hr(s);return n==null?void 0:n.findIndex((c,u)=>{const d=Hr(c);return d>i&&(u===0||Math.abs(i-d)<=Math.abs(i-Hr(n[u-1])))||d<=i&&(u===n.length-1||Math.abs(Hr(s)-d)<Math.abs(Hr(s)-Hr(n[u+1])))})}const o=r.bandwidth()===0?Math.floor((t-Math.min(...r.range())+r.step()/2)/r.step()):Math.floor((t-Math.min(...r.range()))/r.step());return o<0||o>=n.length?-1:a?n.length-1-o:o}function Yu(e,t,r){const{scale:n,data:a}=e;if(!qp(n)){const o=n.invert(t);return r<0?o:a[r]}return r<0||r>=a.length?null:a[r]}function Ku(e,t){const r=e.createSVGPoint();return r.x=t.clientX,r.y=t.clientY,r.matrixTransform(e.getScreenCTM().inverse())}function en(e){const t=V.useRef(e);return Ft(()=>{t.current=e}),V.useRef((...r)=>(0,t.current)(...r)).current}const px=Object.is;function Jp(e,t){if(e===t)return!0;if(!(e instanceof Object)||!(t instanceof Object))return!1;let r=0,n=0;for(const a in e)if(r+=1,!px(e[a],t[a])||!(a in t))return!1;for(const a in t)n+=1;return r===n}const tc=({store:e})=>{const t=en(function(){e.update(s=>Y({},s,{interaction:{pointer:null,item:null}}))}),r=en(function(s){e.update(i=>{const l=i.interaction.item;return s?l===null||Object.keys(s).some(c=>s[c]!==l[c])?i:Y({},i,{interaction:Y({},i.interaction,{item:null})}):l===null?i:Y({},i,{interaction:Y({},i.interaction,{item:null})})})}),n=en(function(s){e.update(i=>Jp(i.interaction.item,s)?i:Y({},i,{interaction:Y({},i.interaction,{item:s})}))}),a=en(function(s){e.update(i=>Y({},i,{interaction:Y({},i.interaction,{pointer:s})}))});return{instance:{cleanInteraction:t,setItemInteraction:n,removeItemInteraction:r,setPointerCoordinate:a}}};tc.getInitialState=()=>({interaction:{item:null,pointer:null}});tc.params={};const rc=e=>e.interaction,mx=pe([rc],e=>e!==void 0),fx=pe([rc],e=>(e==null?void 0:e.item)??null),Wp=pe([rc],e=>(e==null?void 0:e.pointer)??null),vs=pe([Wp],e=>e&&e.x),Ss=pe([Wp],e=>e&&e.y);pe([fx],e=>e!==null);function ea(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;if(Array.isArray(e)){const a=e.length;if(a!==t.length)return!1;for(let o=0;o<a;o+=1)if(!ea(e[o],t[o]))return!1;return!0}if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;const a=Array.from(e.entries());for(let o=0;o<a.length;o+=1)if(!t.has(a[o][0]))return!1;for(let o=0;o<a.length;o+=1){const s=a[o];if(!ea(s[1],t.get(s[0])))return!1}return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;const a=Array.from(e.entries());for(let o=0;o<a.length;o+=1)if(!t.has(a[o][0]))return!1;return!0}if(ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){const a=e.length;if(a!==t.length)return!1;for(let o=0;o<a;o+=1)if(e[o]!==t[o])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();const r=Object.keys(e),n=r.length;if(n!==Object.keys(t).length)return!1;for(let a=0;a<n;a+=1)if(!Object.prototype.hasOwnProperty.call(t,r[a]))return!1;for(let a=0;a<n;a+=1){const o=r[a];if(!ea(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}const xs=(e,t)=>t;function qi(e,t,r=t.axisIds[0]){return Array.isArray(r)?r.map(n=>pn(t.axis[n],e)):pn(t.axis[r],e)}const Yp=(e,t,r)=>{if(e===null)return null;const n=qi(e,t,r);return n===-1?null:n},gx=pe([vs,_r,xs],Yp),yx=pe([Ss,Er,xs],Yp),bx=pe([vs,Ss,_r,Er],(e,t,r,n)=>[...e===null?[]:r.axisIds.map(a=>({axisId:a,dataIndex:qi(e,r,a)})),...t===null?[]:n.axisIds.map(a=>({axisId:a,dataIndex:qi(t,n,a)}))].filter(a=>a.dataIndex!==null&&a.dataIndex>=0));function Kp(e,t,r,n=t.axisIds[0]){return Array.isArray(n)?n.map((a,o)=>Yu(t.axis[a],e,r[o])):Yu(t.axis[n],e,r)}pe([vs,_r,gx,xs],(e,t,r,n)=>e===null||r===null||t.axisIds.length===0?null:Kp(e,t,r,n));pe([Ss,Er,yx,xs],(e,t,r,n)=>e===null||r===null||t.axisIds.length===0?null:Kp(e,t,r,n));const vx=pe([vs,_r],(e,t)=>e===null?[]:t.axisIds.filter(r=>t.axis[r].triggerTooltip).map(r=>({axisId:r,dataIndex:pn(t.axis[r],e)})).filter(({dataIndex:r})=>r>=0),{memoizeOptions:{resultEqualityCheck:ea}}),Sx=pe([Ss,Er],(e,t)=>e===null?[]:t.axisIds.filter(r=>t.axis[r].triggerTooltip).map(r=>({axisId:r,dataIndex:pn(t.axis[r],e)})).filter(({dataIndex:r})=>r>=0),{memoizeOptions:{resultEqualityCheck:ea}});pe([vx,Sx],(e,t)=>e.length>0||t.length>0);const Qu={};function xx(e,t){const r=V.useRef(Qu);return r.current===Qu&&(r.current=e(t)),r}const Ox=()=>{};function wx(e,t,r,n){const a=xx(Cx,{store:e,selector:t,skip:n}).current;a.effect=r,V.useEffect(a.onMount(n),[n])}function Cx(e){const{store:t,selector:r,skip:n}=e;let a=!1,o;const s=()=>{i.dispose??(i.dispose=t.subscribe(l=>{const c=r(l);i.effect(o,c),o=c}))},i={effect:Ox,dispose:null,onMount:l=>()=>{if(!l)return a||(a=!0,o=r(t.value)),s(),()=>{var c;(c=i.dispose)==null||c.call(i),i.dispose=null}}};return n||(a=!0,o=r(t.value),s()),i}const Os=({params:e,store:t,seriesConfig:r,svgRef:n,instance:a})=>{const{xAxis:o,yAxis:s,dataset:i,onHighlightedAxisChange:l}=e;if(process.env.NODE_ENV!=="production"){const O=[...o??[],...s??[]].filter(P=>P.id).map(P=>P.id),C=new Set(O.filter((P,w)=>O.indexOf(P)!==w));C.size>0&&sa([`MUI X Charts: The following axis ids are duplicated: ${Array.from(C).join(", ")}.`,"Please make sure that each axis has a unique id."].join(`
|
|
116
|
+
`),"error")}const c=at(t,Oa),u=at(t,wa),d=at(t,mx),{axis:h,axisIds:p}=at(t,_r),{axis:f,axisIds:m}=at(t,Er);hp({warningPrefix:"MUI X Charts",componentName:"Chart",propName:"highlightedAxis",controlled:e.highlightedAxis,defaultValue:void 0}),Ft(()=>{e.highlightedAxis!==void 0&&t.update(O=>O.controlledCartesianAxisHighlight===e.highlightedAxis?O:Y({},O,{controlledCartesianAxisHighlight:e.highlightedAxis}))},[t,e.highlightedAxis]);const b=V.useRef(!0);V.useEffect(()=>{if(b.current){b.current=!1;return}t.update(O=>Y({},O,{cartesianAxis:Y({},O.cartesianAxis,{x:fp(o,i),y:gp(s,i)})}))},[r,c,o,s,i,t]);const x=p[0],_=m[0];return wx(t,bx,(O,C)=>{if(!Object.is(O,C)){if(O.length!==C.length){l(C);return}O!=null&&O.some(({axisId:P,dataIndex:w},R)=>C[R].axisId!==P||C[R].dataIndex!==w)&&l(C)}},!l),V.useEffect(()=>{const O=n.current;if(!d||!O||e.disableAxisListener)return()=>{};const C=a.addInteractionListener("moveEnd",T=>{var z;T.detail.activeGestures.pan||(z=a.cleanInteraction)==null||z.call(a)}),P=a.addInteractionListener("panEnd",T=>{var z;T.detail.activeGestures.move||(z=a.cleanInteraction)==null||z.call(a)}),w=a.addInteractionListener("quickPressEnd",T=>{var z;!T.detail.activeGestures.move&&!T.detail.activeGestures.pan&&((z=a.cleanInteraction)==null||z.call(a))}),R=T=>{var te,Z;const z=T.detail.srcEvent,E=T.detail.target,B=Ku(O,z);if(T.detail.srcEvent.buttons>=1&&(E!=null&&E.hasPointerCapture(T.detail.srcEvent.pointerId))&&!(E!=null&&E.closest("[data-charts-zoom-slider]"))&&(E==null||E.releasePointerCapture(T.detail.srcEvent.pointerId)),!a.isPointInside(B.x,B.y,E)){(te=a.cleanInteraction)==null||te.call(a);return}(Z=a.setPointerCoordinate)==null||Z.call(a,B)},I=a.addInteractionListener("move",R),F=a.addInteractionListener("pan",R),y=a.addInteractionListener("quickPress",R);return()=>{I.cleanup(),C.cleanup(),F.cleanup(),P.cleanup(),y.cleanup(),w.cleanup()}},[n,t,h,x,f,_,a,e.disableAxisListener,d]),V.useEffect(()=>{const O=n.current,C=e.onAxisClick;if(O===null||!C)return()=>{};const P=a.addInteractionListener("tap",w=>{let R=null,I=!1;const F=Ku(O,w.detail.srcEvent),y=pn(h[x],F.x);I=y!==-1,R=I?y:pn(f[_],F.y);const T=I?p[0]:m[0];if(R==null||R===-1)return;const z=(I?h:f)[T].data[R],E={};Object.keys(u).filter(B=>["bar","line"].includes(B)).forEach(B=>{var te;(te=u[B])==null||te.seriesOrder.forEach(Z=>{const ae=u[B].series[Z],re=ae.xAxisId,le=ae.yAxisId,J=I?re:le;(J===void 0||J===T)&&(E[Z]=ae.data[R])})}),C(w.detail.srcEvent,{dataIndex:R,axisValue:z,seriesValues:E})});return()=>{P.cleanup()}},[e.onAxisClick,u,n,h,p,f,m,x,_,a]),{}};Os.params={xAxis:!0,yAxis:!0,dataset:!0,onAxisClick:!0,disableAxisListener:!0,onHighlightedAxisChange:!0,highlightedAxis:!0};Os.getDefaultizedParams=({params:e})=>Y({},e,{colors:e.colors??lp,theme:e.theme??"light",defaultizedXAxis:fp(e.xAxis,e.dataset),defaultizedYAxis:gp(e.yAxis,e.dataset)});Os.getInitialState=e=>Y({cartesianAxis:{x:e.defaultizedXAxis,y:e.defaultizedYAxis}},e.highlightedAxis===void 0?{}:{controlledCartesianAxisHighlight:e.highlightedAxis});function Xu(e,t){return e.id!==void 0?e:Y({id:t},e)}function Zu(e){return e.colorMap?Y({},e,{colorScale:e.colorMap.type==="ordinal"&&e.data?ko(Y({values:e.data},e.colorMap)):fo(e.colorMap.type==="continuous"?Y({min:e.min,max:e.max},e.colorMap):e.colorMap)}):e}function Qp(e,t){if(!e||e.length===0)return{axis:{},axisIds:[]};const r={},n=[];return e.forEach((a,o)=>{const s=a.dataKey,i=a.id??`defaultized-z-axis-${o}`;if(s===void 0||a.data!==void 0){r[i]=Zu(Xu(a,i)),n.push(i);return}if(t===void 0)throw new Error("MUI X Charts: z-axis uses `dataKey` but no `dataset` is provided.");r[i]=Zu(Xu(Y({},a,{data:t.map(l=>l[s])}),i)),n.push(i)}),{axis:r,axisIds:n}}const nc=({params:e,store:t})=>{const{zAxis:r,dataset:n}=e,a=V.useRef(!0);return V.useEffect(()=>{if(a.current){a.current=!1;return}t.update(o=>Y({},o,{zAxis:Qp(r,n)}))},[r,n,t]),{}};nc.params={zAxis:!0,dataset:!0};nc.getInitialState=e=>({zAxis:Qp(e.zAxis,e.dataset)});const Px=e=>e,Tx=pe([Px],e=>e.zAxis),ws=({store:e,params:t})=>{hp({warningPrefix:"MUI X Charts",componentName:"Chart",propName:"highlightedItem",controlled:t.highlightedItem,defaultValue:null}),Ft(()=>{e.update(a=>a.highlight.item===t.highlightedItem?a:Y({},a,{highlight:Y({},a.highlight,{item:t.highlightedItem})}))},[e,t.highlightedItem]);const r=en(()=>{var a;(a=t.onHighlightChange)==null||a.call(t,null),e.update(o=>Y({},o,{highlight:{item:null}}))}),n=en(a=>{var s;const o=e.getSnapshot().highlight.item;Jp(o,a)||((s=t.onHighlightChange)==null||s.call(t,a),e.update(i=>Y({},i,{highlight:{item:a}})))});return{instance:{clearHighlight:r,setHighlight:n}}};ws.getDefaultizedParams=({params:e})=>Y({},e,{highlightedItem:e.highlightedItem??null});ws.getInitialState=e=>({highlight:{item:e.highlightedItem}});ws.params={highlightedItem:!0,onHighlightChange:!0};const ed=(e,t)=>t==="x"?{x:e,y:null}:{x:null,y:e},Xp=e=>{var l;const{axis:t,getFilters:r,isDefaultAxis:n}=e,a=r==null?void 0:r({currentAxisId:t.id,isDefaultAxis:n}),o=a?(l=t.data)==null?void 0:l.filter((c,u)=>a({x:null,y:null},u)):t.data,s=Math.min(...o??[]),i=Math.max(...o??[]);return[s,i]},Zp=e=>t=>{const{series:r,axis:n,getFilters:a,isDefaultAxis:o}=t;return Object.keys(r).filter(s=>{const i=e==="x"?r[s].xAxisId:r[s].yAxisId;return i===n.id||o&&i===void 0}).reduce((s,i)=>{const{stackedData:l}=r[i],c=a==null?void 0:a({currentAxisId:n.id,isDefaultAxis:o,seriesXAxisId:r[i].xAxisId,seriesYAxisId:r[i].yAxisId}),[u,d]=(l==null?void 0:l.reduce((h,p,f)=>c&&(!c(ed(p[0],e),f)||!c(ed(p[1],e),f))?h:[Math.min(...p,h[0]),Math.max(...p,h[1])],[1/0,-1/0]))??[1/0,-1/0];return[Math.min(u,s[0]),Math.max(d,s[1])]},[1/0,-1/0])},Rx=e=>Object.keys(e.series).some(r=>e.series[r].layout==="horizontal")?Zp("x")(e):Xp(e),Ax=e=>Object.keys(e.series).some(r=>e.series[r].layout==="horizontal")?Xp(e):Zp("y")(e);function Be(e){return function(){return e}}const td=Math.abs,Ke=Math.atan2,dr=Math.cos,_x=Math.max,di=Math.min,Rt=Math.sin,tn=Math.sqrt,nt=1e-12,da=Math.PI,Uo=da/2,go=2*da;function Ex(e){return e>1?0:e<-1?da:Math.acos(e)}function rd(e){return e>=1?Uo:e<=-1?-Uo:Math.asin(e)}const Ji=Math.PI,Wi=2*Ji,pr=1e-6,Vx=Wi-pr;function em(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=arguments[t]+e[t]}function Ix(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return em;const r=10**t;return function(n){this._+=n[0];for(let a=1,o=n.length;a<o;++a)this._+=Math.round(arguments[a]*r)/r+n[a]}}class Mx{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?em:Ix(t)}moveTo(t,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,r){this._append`L${this._x1=+t},${this._y1=+r}`}quadraticCurveTo(t,r,n,a){this._append`Q${+t},${+r},${this._x1=+n},${this._y1=+a}`}bezierCurveTo(t,r,n,a,o,s){this._append`C${+t},${+r},${+n},${+a},${this._x1=+o},${this._y1=+s}`}arcTo(t,r,n,a,o){if(t=+t,r=+r,n=+n,a=+a,o=+o,o<0)throw new Error(`negative radius: ${o}`);let s=this._x1,i=this._y1,l=n-t,c=a-r,u=s-t,d=i-r,h=u*u+d*d;if(this._x1===null)this._append`M${this._x1=t},${this._y1=r}`;else if(h>pr)if(!(Math.abs(d*l-c*u)>pr)||!o)this._append`L${this._x1=t},${this._y1=r}`;else{let p=n-s,f=a-i,m=l*l+c*c,b=p*p+f*f,x=Math.sqrt(m),_=Math.sqrt(h),O=o*Math.tan((Ji-Math.acos((m+h-b)/(2*x*_)))/2),C=O/_,P=O/x;Math.abs(C-1)>pr&&this._append`L${t+C*u},${r+C*d}`,this._append`A${o},${o},0,0,${+(d*p>u*f)},${this._x1=t+P*l},${this._y1=r+P*c}`}}arc(t,r,n,a,o,s){if(t=+t,r=+r,n=+n,s=!!s,n<0)throw new Error(`negative radius: ${n}`);let i=n*Math.cos(a),l=n*Math.sin(a),c=t+i,u=r+l,d=1^s,h=s?a-o:o-a;this._x1===null?this._append`M${c},${u}`:(Math.abs(this._x1-c)>pr||Math.abs(this._y1-u)>pr)&&this._append`L${c},${u}`,n&&(h<0&&(h=h%Wi+Wi),h>Vx?this._append`A${n},${n},0,1,${d},${t-i},${r-l}A${n},${n},0,1,${d},${this._x1=c},${this._y1=u}`:h>pr&&this._append`A${n},${n},0,${+(h>=Ji)},${d},${this._x1=t+n*Math.cos(o)},${this._y1=r+n*Math.sin(o)}`)}rect(t,r,n,a){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}h${n=+n}v${+a}h${-n}Z`}toString(){return this._}}function $x(e){let t=3;return e.digits=function(r){if(!arguments.length)return t;if(r==null)t=null;else{const n=Math.floor(r);if(!(n>=0))throw new RangeError(`invalid digits: ${r}`);t=n}return e},()=>new Mx(t)}function jx(e){return e.innerRadius}function kx(e){return e.outerRadius}function Ux(e){return e.startAngle}function Lx(e){return e.endAngle}function Dx(e){return e&&e.padAngle}function Nx(e,t,r,n,a,o,s,i){var l=r-e,c=n-t,u=s-a,d=i-o,h=d*l-u*c;if(!(h*h<nt))return h=(u*(t-o)-d*(e-a))/h,[e+h*l,t+h*c]}function Ka(e,t,r,n,a,o,s){var i=e-r,l=t-n,c=(s?o:-o)/tn(i*i+l*l),u=c*l,d=-c*i,h=e+u,p=t+d,f=r+u,m=n+d,b=(h+f)/2,x=(p+m)/2,_=f-h,O=m-p,C=_*_+O*O,P=a-o,w=h*m-f*p,R=(O<0?-1:1)*tn(_x(0,P*P*C-w*w)),I=(w*O-_*R)/C,F=(-w*_-O*R)/C,y=(w*O+_*R)/C,T=(-w*_+O*R)/C,z=I-b,E=F-x,B=y-b,te=T-x;return z*z+E*E>B*B+te*te&&(I=y,F=T),{cx:I,cy:F,x01:-u,y01:-d,x11:I*(a/P-1),y11:F*(a/P-1)}}function tm(){var e=jx,t=kx,r=Be(0),n=null,a=Ux,o=Lx,s=Dx,i=null,l=$x(c);function c(){var u,d,h=+e.apply(this,arguments),p=+t.apply(this,arguments),f=a.apply(this,arguments)-Uo,m=o.apply(this,arguments)-Uo,b=td(m-f),x=m>f;if(i||(i=u=l()),p<h&&(d=p,p=h,h=d),!(p>nt))i.moveTo(0,0);else if(b>go-nt)i.moveTo(p*dr(f),p*Rt(f)),i.arc(0,0,p,f,m,!x),h>nt&&(i.moveTo(h*dr(m),h*Rt(m)),i.arc(0,0,h,m,f,x));else{var _=f,O=m,C=f,P=m,w=b,R=b,I=s.apply(this,arguments)/2,F=I>nt&&(n?+n.apply(this,arguments):tn(h*h+p*p)),y=di(td(p-h)/2,+r.apply(this,arguments)),T=y,z=y,E,B;if(F>nt){var te=rd(F/h*Rt(I)),Z=rd(F/p*Rt(I));(w-=te*2)>nt?(te*=x?1:-1,C+=te,P-=te):(w=0,C=P=(f+m)/2),(R-=Z*2)>nt?(Z*=x?1:-1,_+=Z,O-=Z):(R=0,_=O=(f+m)/2)}var ae=p*dr(_),re=p*Rt(_),le=h*dr(P),J=h*Rt(P);if(y>nt){var X=p*dr(O),he=p*Rt(O),Pe=h*dr(C),ze=h*Rt(C),xe;if(b<da)if(xe=Nx(ae,re,Pe,ze,X,he,le,J)){var it=ae-xe[0],tt=re-xe[1],ye=X-xe[0],Q=he-xe[1],oe=1/Rt(Ex((it*ye+tt*Q)/(tn(it*it+tt*tt)*tn(ye*ye+Q*Q)))/2),ce=tn(xe[0]*xe[0]+xe[1]*xe[1]);T=di(y,(h-ce)/(oe-1)),z=di(y,(p-ce)/(oe+1))}else T=z=0}R>nt?z>nt?(E=Ka(Pe,ze,ae,re,p,z,x),B=Ka(X,he,le,J,p,z,x),i.moveTo(E.cx+E.x01,E.cy+E.y01),z<y?i.arc(E.cx,E.cy,z,Ke(E.y01,E.x01),Ke(B.y01,B.x01),!x):(i.arc(E.cx,E.cy,z,Ke(E.y01,E.x01),Ke(E.y11,E.x11),!x),i.arc(0,0,p,Ke(E.cy+E.y11,E.cx+E.x11),Ke(B.cy+B.y11,B.cx+B.x11),!x),i.arc(B.cx,B.cy,z,Ke(B.y11,B.x11),Ke(B.y01,B.x01),!x))):(i.moveTo(ae,re),i.arc(0,0,p,_,O,!x)):i.moveTo(ae,re),!(h>nt)||!(w>nt)?i.lineTo(le,J):T>nt?(E=Ka(le,J,X,he,h,-T,x),B=Ka(ae,re,Pe,ze,h,-T,x),i.lineTo(E.cx+E.x01,E.cy+E.y01),T<y?i.arc(E.cx,E.cy,T,Ke(E.y01,E.x01),Ke(B.y01,B.x01),!x):(i.arc(E.cx,E.cy,T,Ke(E.y01,E.x01),Ke(E.y11,E.x11),!x),i.arc(0,0,h,Ke(E.cy+E.y11,E.cx+E.x11),Ke(B.cy+B.y11,B.cx+B.x11),x),i.arc(B.cx,B.cy,T,Ke(B.y11,B.x11),Ke(B.y01,B.x01),!x))):i.arc(0,0,h,P,C,x)}if(i.closePath(),u)return i=null,u+""||null}return c.centroid=function(){var u=(+e.apply(this,arguments)+ +t.apply(this,arguments))/2,d=(+a.apply(this,arguments)+ +o.apply(this,arguments))/2-da/2;return[dr(d)*u,Rt(d)*u]},c.innerRadius=function(u){return arguments.length?(e=typeof u=="function"?u:Be(+u),c):e},c.outerRadius=function(u){return arguments.length?(t=typeof u=="function"?u:Be(+u),c):t},c.cornerRadius=function(u){return arguments.length?(r=typeof u=="function"?u:Be(+u),c):r},c.padRadius=function(u){return arguments.length?(n=u==null?null:typeof u=="function"?u:Be(+u),c):n},c.startAngle=function(u){return arguments.length?(a=typeof u=="function"?u:Be(+u),c):a},c.endAngle=function(u){return arguments.length?(o=typeof u=="function"?u:Be(+u),c):o},c.padAngle=function(u){return arguments.length?(s=typeof u=="function"?u:Be(+u),c):s},c.context=function(u){return arguments.length?(i=u??null,c):i},c}function rm(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Bx(e,t){return t<e?-1:t>e?1:t>=e?0:NaN}function Fx(e){return e}function zx(){var e=Fx,t=Bx,r=null,n=Be(0),a=Be(go),o=Be(0);function s(i){var l,c=(i=rm(i)).length,u,d,h=0,p=new Array(c),f=new Array(c),m=+n.apply(this,arguments),b=Math.min(go,Math.max(-go,a.apply(this,arguments)-m)),x,_=Math.min(Math.abs(b)/c,o.apply(this,arguments)),O=_*(b<0?-1:1),C;for(l=0;l<c;++l)(C=f[p[l]=l]=+e(i[l],l,i))>0&&(h+=C);for(t!=null?p.sort(function(P,w){return t(f[P],f[w])}):r!=null&&p.sort(function(P,w){return r(i[P],i[w])}),l=0,d=h?(b-c*O)/h:0;l<c;++l,m=x)u=p[l],C=f[u],x=m+(C>0?C*d:0)+O,f[u]={data:i[u],index:l,value:C,startAngle:m,endAngle:x,padAngle:_};return f}return s.value=function(i){return arguments.length?(e=typeof i=="function"?i:Be(+i),s):e},s.sortValues=function(i){return arguments.length?(t=i,r=null,s):t},s.sort=function(i){return arguments.length?(r=i,t=null,s):r},s.startAngle=function(i){return arguments.length?(n=typeof i=="function"?i:Be(+i),s):n},s.endAngle=function(i){return arguments.length?(a=typeof i=="function"?i:Be(+i),s):a},s.padAngle=function(i){return arguments.length?(o=typeof i=="function"?i:Be(+i),s):o},s}function mn(e,t){if((s=e.length)>1)for(var r=1,n,a,o=e[t[0]],s,i=o.length;r<s;++r)for(a=o,o=e[t[r]],n=0;n<i;++n)o[n][1]+=o[n][0]=isNaN(a[n][1])?a[n][0]:a[n][1]}function fn(e){for(var t=e.length,r=new Array(t);--t>=0;)r[t]=t;return r}function Gx(e,t){return e[t]}function Hx(e){const t=[];return t.key=e,t}function nm(){var e=Be([]),t=fn,r=mn,n=Gx;function a(o){var s=Array.from(e.apply(this,arguments),Hx),i,l=s.length,c=-1,u;for(const d of o)for(i=0,++c;i<l;++i)(s[i][c]=[0,+n(d,s[i].key,c,o)]).data=d;for(i=0,u=rm(t(s));i<l;++i)s[u[i]].index=i;return r(s,u),s}return a.keys=function(o){return arguments.length?(e=typeof o=="function"?o:Be(Array.from(o)),a):e},a.value=function(o){return arguments.length?(n=typeof o=="function"?o:Be(+o),a):n},a.order=function(o){return arguments.length?(t=o==null?fn:typeof o=="function"?o:Be(Array.from(o)),a):t},a.offset=function(o){return arguments.length?(r=o??mn,a):r},a}function qx(e,t){if((n=e.length)>0){for(var r,n,a=0,o=e[0].length,s;a<o;++a){for(s=r=0;r<n;++r)s+=e[r][a][1]||0;if(s)for(r=0;r<n;++r)e[r][a][1]/=s}mn(e,t)}}function Jx(e,t){if((l=e.length)>0)for(var r,n=0,a,o,s,i,l,c=e[t[0]].length;n<c;++n)for(s=i=0,r=0;r<l;++r)(o=(a=e[t[r]][n])[1]-a[0])>0?(a[0]=s,a[1]=s+=o):o<0?(a[1]=i,a[0]=i+=o):(a[0]=0,a[1]=o)}function Wx(e,t){if((a=e.length)>0){for(var r=0,n=e[t[0]],a,o=n.length;r<o;++r){for(var s=0,i=0;s<a;++s)i+=e[s][r][1]||0;n[r][1]+=n[r][0]=-i/2}mn(e,t)}}function Yx(e,t){if(!(!((s=e.length)>0)||!((o=(a=e[t[0]]).length)>0))){for(var r=0,n=1,a,o,s;n<o;++n){for(var i=0,l=0,c=0;i<s;++i){for(var u=e[t[i]],d=u[n][1]||0,h=u[n-1][1]||0,p=(d-h)/2,f=0;f<i;++f){var m=e[t[f]],b=m[n][1]||0,x=m[n-1][1]||0;p+=b-x}l+=d,c+=p*d}a[n-1][1]+=a[n-1][0]=r,l&&(r-=c/l)}a[n-1][1]+=a[n-1][0]=r,mn(e,t)}}function am(e){var t=e.map(Kx);return fn(e).sort(function(r,n){return t[r]-t[n]})}function Kx(e){for(var t=-1,r=0,n=e.length,a,o=-1/0;++t<n;)(a=+e[t][1])>o&&(o=a,r=t);return r}function om(e){var t=e.map(sm);return fn(e).sort(function(r,n){return t[r]-t[n]})}function sm(e){for(var t=0,r=-1,n=e.length,a;++r<n;)(a=+e[r][1])&&(t+=a);return t}function Qx(e){return om(e).reverse()}function Xx(e){var t=e.length,r,n,a=e.map(sm),o=am(e),s=0,i=0,l=[],c=[];for(r=0;r<t;++r)n=o[r],s<i?(s+=a[n],l.push(n)):(i+=a[n],c.push(n));return c.reverse().concat(l)}function Zx(e){return fn(e).reverse()}const hi={appearance:am,ascending:om,descending:Qx,insideOut:Xx,none:fn,reverse:Zx},pi={expand:qx,diverging:Jx,none:mn,silhouette:Wx,wiggle:Yx},im=e=>{const{series:t,seriesOrder:r,defaultStrategy:n}=e,a=[],o={};return r.forEach(s=>{const{stack:i,stackOrder:l,stackOffset:c}=t[s];i===void 0?a.push({ids:[s],stackingOrder:hi.none,stackingOffset:pi.none}):o[i]===void 0?(o[i]=a.length,a.push({ids:[s],stackingOrder:hi[l??(n==null?void 0:n.stackOrder)??"none"],stackingOffset:pi[c??(n==null?void 0:n.stackOffset)??"diverging"]})):(a[o[i]].ids.push(s),l!==void 0&&(a[o[i]].stackingOrder=hi[l]),c!==void 0&&(a[o[i]].stackingOffset=pi[c]))}),a},eO=e=>e==null?"":e.toLocaleString(),tO=(e,t)=>{const{seriesOrder:r,series:n}=e,a=im(e),o=t??[];r.forEach(i=>{const l=n[i].data;if(l!==void 0)l.forEach((c,u)=>{o.length<=u?o.push({[i]:c}):o[u][i]=c});else if(t===void 0)throw new Error([`MUI X Charts: bar series with id='${i}' has no data.`,"Either provide a data property to the series or use the dataset prop."].join(`
|
|
117
|
+
`))});const s={};return a.forEach(i=>{const{ids:l,stackingOffset:c,stackingOrder:u}=i,d=nm().keys(l.map(h=>{const p=n[h].dataKey;return n[h].data===void 0&&p!==void 0?p:h})).value((h,p)=>h[p]??0).order(u).offset(c)(o);l.forEach((h,p)=>{const f=n[h].dataKey;s[h]=Y({layout:"vertical",labelMarkType:"square",minBarSize:0,valueFormatter:n[h].valueFormatter??eO},n[h],{data:f?t.map(m=>{const b=m[f];return typeof b!="number"?(process.env.NODE_ENV!=="production"&&b!==null&&sa([`MUI X Charts: your dataset key "${f}" is used for plotting bars, but contains nonnumerical elements.`,"Bar plots only support numbers and null values."]),null):b}):n[h].data,stackedData:d[p].map(([m,b])=>[m,b])})})}),{seriesOrder:r,stackingGroups:a,series:s}};function Jt(e,t){return typeof e=="function"?e(t):e}const rO=e=>{const{seriesOrder:t,series:r}=e;return t.reduce((n,a)=>{const o=Jt(r[a].label,"legend");return o===void 0||n.push({markType:r[a].labelMarkType,id:a,seriesId:a,color:r[a].color,label:o}),n},[])},nO=(e,t,r)=>{const n=e.layout==="vertical",a=n?t==null?void 0:t.colorScale:r==null?void 0:r.colorScale,o=n?r==null?void 0:r.colorScale:t==null?void 0:t.colorScale,s=n?t==null?void 0:t.data:r==null?void 0:r.data;return o?i=>{if(i===void 0)return e.color;const l=e.data[i],c=l===null?e.color:o(l);return c===null?e.color:c}:a&&s?i=>{if(i===void 0)return e.color;const l=s[i],c=l===null?e.color:a(l);return c===null?e.color:c}:()=>e.color},aO=e=>{const{series:t,getColor:r,identifier:n}=e;if(!n||n.dataIndex===void 0)return null;const a=Jt(t.label,"tooltip"),o=t.data[n.dataIndex];if(o==null)return null;const s=t.valueFormatter(o,{dataIndex:n.dataIndex});return{identifier:n,color:r(n.dataIndex),label:a,value:o,formattedValue:s,markType:t.labelMarkType}},oO=e=>Object.values(e).map(t=>t.layout==="horizontal"?{direction:"y",axisId:t.yAxisId}:{direction:"x",axisId:t.xAxisId}),sO=(e,t,r)=>Y({id:e.id??`auto-generated-id-${t}`,color:r[t%r.length]},e),iO={seriesProcessor:tO,colorProcessor:nO,legendGetter:rO,tooltipGetter:aO,axisTooltipGetter:oO,xExtremumGetter:Rx,yExtremumGetter:Ax,getSeriesWithDefaultValues:sO},Lo=(e,t)=>[t[0]===null?e[0]:Math.min(e[0],t[0]),t[1]===null?e[1]:Math.max(e[1],t[1])],lO=e=>{const{series:t,axis:r,isDefaultAxis:n,getFilters:a}=e;return Object.keys(t).filter(o=>{const s=t[o].xAxisId;return s===r.id||s===void 0&&n}).reduce((o,s)=>{var c;const i=a==null?void 0:a({currentAxisId:r.id,isDefaultAxis:n,seriesXAxisId:t[s].xAxisId,seriesYAxisId:t[s].yAxisId}),l=(c=t[s].data)==null?void 0:c.reduce((u,d,h)=>i&&!i(d,h)?u:Lo(u,[d.x,d.x]),[1/0,-1/0]);return Lo(o,l??[1/0,-1/0])},[1/0,-1/0])},cO=e=>{const{series:t,axis:r,isDefaultAxis:n,getFilters:a}=e;return Object.keys(t).filter(o=>{const s=t[o].yAxisId;return s===r.id||s===void 0&&n}).reduce((o,s)=>{var c;const i=a==null?void 0:a({currentAxisId:r.id,isDefaultAxis:n,seriesXAxisId:t[s].xAxisId,seriesYAxisId:t[s].yAxisId}),l=(c=t[s].data)==null?void 0:c.reduce((u,d,h)=>i&&!i(d,h)?u:Lo(u,[d.y,d.y]),[1/0,-1/0]);return Lo(o,l??[1/0,-1/0])},[1/0,-1/0])},uO=({series:e,seriesOrder:t},r)=>({series:Object.fromEntries(Object.entries(e).map(([a,o])=>{const s=o==null?void 0:o.datasetKeys,i=["x","y","id"].filter(c=>typeof(s==null?void 0:s[c])!="string");if(o!=null&&o.datasetKeys&&i.length>0)throw new Error([`MUI X Charts: scatter series with id='${a}' has incomplete datasetKeys.`,`Properties ${i.map(c=>`"${c}"`).join(", ")} are missing.`].join(`
|
|
118
|
+
`));const l=s?(r==null?void 0:r.map(c=>({x:c[s.x]??null,y:c[s.y]??null,z:s.z&&c[s.z],id:s.id&&c[s.id]})))??[]:o.data??[];return[a,Y({labelMarkType:"circle",markerSize:4},o,{preview:Y({markerSize:1},o==null?void 0:o.preview),data:l,valueFormatter:o.valueFormatter??(c=>c&&`(${c.x}, ${c.y})`)})]})),seriesOrder:t}),dO=(e,t,r,n)=>{const a=n==null?void 0:n.colorScale,o=r==null?void 0:r.colorScale,s=t==null?void 0:t.colorScale;return a?i=>{var u,d;if(i===void 0)return e.color;if(((u=n==null?void 0:n.data)==null?void 0:u[i])!==void 0){const h=a((d=n==null?void 0:n.data)==null?void 0:d[i]);if(h!==null)return h}const l=e.data[i],c=l===null?e.color:a(l.z);return c===null?e.color:c}:o?i=>{if(i===void 0)return e.color;const l=e.data[i],c=l===null?e.color:o(l.y);return c===null?e.color:c}:s?i=>{if(i===void 0)return e.color;const l=e.data[i],c=l===null?e.color:s(l.x);return c===null?e.color:c}:()=>e.color},hO=e=>{const{seriesOrder:t,series:r}=e;return t.reduce((n,a)=>{const o=Jt(r[a].label,"legend");return o===void 0||n.push({markType:r[a].labelMarkType,id:a,seriesId:a,color:r[a].color,label:o}),n},[])},pO=e=>{const{series:t,getColor:r,identifier:n}=e;if(!n||n.dataIndex===void 0)return null;const a=Jt(t.label,"tooltip"),o=t.data[n.dataIndex],s=t.valueFormatter(o,{dataIndex:n.dataIndex});return{identifier:n,color:r(n.dataIndex),label:a,value:o,formattedValue:s,markType:t.labelMarkType}},mO=(e,t,r)=>Y({id:e.id??`auto-generated-id-${t}`,color:r[t%r.length]},e),fO={seriesProcessor:uO,colorProcessor:dO,legendGetter:hO,tooltipGetter:pO,xExtremumGetter:lO,yExtremumGetter:cO,getSeriesWithDefaultValues:mO},gO=e=>{const{axis:t}=e,r=Math.min(...t.data??[]),n=Math.max(...t.data??[]);return[r,n]};function yO(e,t,r,n){return r.reduce((a,o,s)=>{if(t[s]===null)return a;const[i,l]=e(o);return n&&(!n({y:i,x:null},s)||!n({y:l,x:null},s))?a:[Math.min(i,l,a[0]),Math.max(i,l,a[1])]},[1/0,-1/0])}const bO=e=>{const{series:t,axis:r,isDefaultAxis:n,getFilters:a}=e;return Object.keys(t).filter(o=>{const s=t[o].yAxisId;return s===r.id||n&&s===void 0}).reduce((o,s)=>{const{area:i,stackedData:l,data:c}=t[s],u=i!==void 0,d=a==null?void 0:a({currentAxisId:r.id,isDefaultAxis:n,seriesXAxisId:t[s].xAxisId,seriesYAxisId:t[s].yAxisId}),h=u&&r.scaleType!=="log"&&typeof t[s].baseline!="string"?b=>b:b=>[b[1],b[1]],p=yO(h,c,l,d),[f,m]=p;return[Math.min(f,o[0]),Math.max(m,o[1])]},[1/0,-1/0])};function vO(e,t){const r={};return Object.keys(e).forEach(n=>{r[n]=Y({},e[n],{valueFormatter:e[n].valueFormatter??t})}),r}const SO=(e,t)=>{const{seriesOrder:r,series:n}=e,a=im(Y({},e,{defaultStrategy:{stackOffset:"none"}})),o=t??[];r.forEach(i=>{const l=n[i].data;if(l!==void 0)l.forEach((c,u)=>{o.length<=u?o.push({[i]:c}):o[u][i]=c});else if(t===void 0&&process.env.NODE_ENV!=="production")throw new Error([`MUI X Charts: line series with id='${i}' has no data.`,"Either provide a data property to the series or use the dataset prop."].join(`
|
|
119
|
+
`))});const s={};return a.forEach(i=>{const{ids:l,stackingOrder:c,stackingOffset:u}=i,d=nm().keys(l.map(h=>{const p=n[h].dataKey;return n[h].data===void 0&&p!==void 0?p:h})).value((h,p)=>h[p]??0).order(c).offset(u)(o);l.forEach((h,p)=>{const f=n[h].dataKey;s[h]=Y({labelMarkType:"line"},n[h],{data:f?t.map(m=>{const b=m[f];return typeof b!="number"?(process.env.NODE_ENV!=="production"&&b!==null&&sa([`MUI X Charts: Your dataset key "${f}" is used for plotting line, but contains nonnumerical elements.`,"Line plots only support numbers and null values."]),null):b}):n[h].data,stackedData:d[p].map(([m,b])=>[m,b])})})}),{seriesOrder:r,stackingGroups:a,series:vO(s,i=>i==null?"":i.toLocaleString())}},xO=(e,t,r)=>{const n=r==null?void 0:r.colorScale,a=t==null?void 0:t.colorScale;return n?o=>{if(o===void 0)return e.color;const s=e.data[o],i=s===null?e.color:n(s);return i===null?e.color:i}:a?o=>{var l;if(o===void 0)return e.color;const s=(l=t.data)==null?void 0:l[o],i=s===null?e.color:a(s);return i===null?e.color:i}:()=>e.color},OO=e=>{const{seriesOrder:t,series:r}=e;return t.reduce((n,a)=>{const o=Jt(r[a].label,"legend");return o===void 0||n.push({markType:r[a].labelMarkType,id:a,seriesId:a,color:r[a].color,label:o}),n},[])},wO=e=>{const{series:t,getColor:r,identifier:n}=e;if(!n||n.dataIndex===void 0)return null;const a=Jt(t.label,"tooltip"),o=t.data[n.dataIndex],s=t.valueFormatter(o,{dataIndex:n.dataIndex});return{identifier:n,color:r(n.dataIndex),label:a,value:o,formattedValue:s,markType:t.labelMarkType}},CO=e=>Object.values(e).map(t=>({direction:"x",axisId:t.xAxisId})),PO=(e,t,r)=>Y({id:e.id??`auto-generated-id-${t}`,color:r[t%r.length]},e),TO={colorProcessor:xO,seriesProcessor:SO,legendGetter:OO,tooltipGetter:wO,axisTooltipGetter:CO,xExtremumGetter:gO,yExtremumGetter:bO,getSeriesWithDefaultValues:PO},RO=(e="none")=>{if(typeof e=="function")return e;switch(e){case"none":return null;case"desc":return(t,r)=>r-t;case"asc":return(t,r)=>t-r;default:return null}},AO=e=>{const{seriesOrder:t,series:r}=e,n={};return t.forEach(a=>{const o=zx().startAngle(2*Math.PI*(r[a].startAngle??0)/360).endAngle(2*Math.PI*(r[a].endAngle??360)/360).padAngle(2*Math.PI*(r[a].paddingAngle??0)/360).sortValues(RO(r[a].sortingValues??"none"))(r[a].data.map(s=>s.value));n[a]=Y({labelMarkType:"circle",valueFormatter:s=>s.value.toLocaleString()},r[a],{data:r[a].data.map((s,i)=>Y({},s,{id:s.id??`auto-generated-pie-id-${a}-${i}`},o[i])).map((s,i)=>{var l,c;return Y({labelMarkType:"circle"},s,{formattedValue:((c=(l=r[a]).valueFormatter)==null?void 0:c.call(l,Y({},s,{label:Jt(s.label,"arc")}),{dataIndex:i}))??s.value.toLocaleString()})})})}),{seriesOrder:t,series:n}},_O=e=>t=>e.data[t].color,EO=e=>{const{seriesOrder:t,series:r}=e;return t.reduce((n,a)=>(r[a].data.forEach((o,s)=>{const i=Jt(o.label,"legend");i!==void 0&&n.push({markType:o.labelMarkType??r[a].labelMarkType,id:o.id??s,seriesId:a,color:o.color,label:i,itemId:o.id??s})}),n),[])},VO=e=>{const{series:t,getColor:r,identifier:n}=e;if(!n||n.dataIndex===void 0)return null;const a=t.data[n.dataIndex];if(a==null)return null;const o=Jt(a.label,"tooltip"),s=Y({},a,{label:o}),i=t.valueFormatter(s,{dataIndex:n.dataIndex});return{identifier:n,color:r(n.dataIndex),label:o,value:s,formattedValue:i,markType:a.labelMarkType??t.labelMarkType}},IO=(e,t,r)=>Y({id:e.id??`auto-generated-id-${t}`},e,{data:e.data.map((n,a)=>Y({color:r[a%r.length]},n))}),MO={colorProcessor:_O,seriesProcessor:AO,legendGetter:EO,tooltipGetter:VO,getSeriesWithDefaultValues:IO},$O={bar:iO,scatter:fO,line:TO,pie:MO},jO=[nc,Os,tc,ws];function kO(e){const{children:t,plugins:r=jO,pluginParams:n={},seriesConfig:a=$O}=e,{contextValue:o}=fv(r,n,a);return S.jsx(jl.Provider,{value:o,children:t})}const lm=()=>{const e=V.useContext(jl);if(e==null)throw new Error(["MUI X Charts: Could not find the Chart context.","It looks like you rendered your component outside of a ChartDataProvider.","This can also happen if you are bundling multiple versions of the library."].join(`
|
|
120
|
+
`));return e};function Vr(){const e=lm();if(!e)throw new Error(["MUI X Charts: Could not find the charts context.","It looks like you rendered your component outside of a ChartContainer parent component."].join(`
|
|
121
|
+
`));return e.store}function cm(){const e=Vr();return at(e,Oa)}function um(){const e=Vr();return at(e,Qb)}const Yi=(e,t)=>e===void 0?t:Math.PI*e/180;function UO(){const e=Vr(),{axis:t,axisIds:r}=at(e,_r);return{xAxis:t,xAxisIds:r}}function LO(){const e=Vr(),{axis:t,axisIds:r}=at(e,Er);return{yAxis:t,yAxisIds:r}}function DO(){const e=Vr(),{axis:t,axisIds:r}=at(e,Tx)??{axis:{},axisIds:[]};return{zAxis:t,zAxisIds:r}}function NO(){const e=lm();if(!e)throw new Error(["MUI X Charts: Could not find the svg ref context.","It looks like you rendered your component outside of a ChartContainer parent component."].join(`
|
|
122
|
+
`));return e.svgRef}function BO(){const e=um();return V.useCallback(t=>`${e}-gradient-${t}`,[e])}function FO(){const e=um();return V.useCallback(t=>`${e}-gradient-${t}-object-bound`,[e])}var mi,nd;function zO(){if(nd)return mi;nd=1;var e=4,t=.001,r=1e-7,n=10,a=11,o=1/(a-1),s=typeof Float32Array=="function";function i(m,b){return 1-3*b+3*m}function l(m,b){return 3*b-6*m}function c(m){return 3*m}function u(m,b,x){return((i(b,x)*m+l(b,x))*m+c(b))*m}function d(m,b,x){return 3*i(b,x)*m*m+2*l(b,x)*m+c(b)}function h(m,b,x,_,O){var C,P,w=0;do P=b+(x-b)/2,C=u(P,_,O)-m,C>0?x=P:b=P;while(Math.abs(C)>r&&++w<n);return P}function p(m,b,x,_){for(var O=0;O<e;++O){var C=d(b,x,_);if(C===0)return b;var P=u(b,x,_)-m;b-=P/C}return b}function f(m){return m}return mi=function(b,x,_,O){if(!(0<=b&&b<=1&&0<=_&&_<=1))throw new Error("bezier x values must be in [0, 1] range");if(b===x&&_===O)return f;for(var C=s?new Float32Array(a):new Array(a),P=0;P<a;++P)C[P]=u(P*o,b,_);function w(R){for(var I=0,F=1,y=a-1;F!==y&&C[F]<=R;++F)I+=o;--F;var T=(R-C[F])/(C[F+1]-C[F]),z=I+T*o,E=d(z,b,_);return E>=t?p(R,z,b,_):E===0?z:h(R,I,I+o,b,_)}return function(I){return I===0?0:I===1?1:u(w(I),x,O)}},mi}var GO=zO();const HO=hg(GO),qO=300,JO=HO(.66,0,.34,1);var gn=0,Qn=0,Ln=0,dm=1e3,Do,Xn,No=0,Or=0,Cs=0,ha=typeof performance=="object"&&performance.now?performance:Date,hm=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function ac(){return Or||(hm(WO),Or=ha.now()+Cs)}function WO(){Or=0}function Bo(){this._call=this._time=this._next=null}Bo.prototype=pm.prototype={constructor:Bo,restart:function(e,t,r){if(typeof e!="function")throw new TypeError("callback is not a function");r=(r==null?ac():+r)+(t==null?0:+t),!this._next&&Xn!==this&&(Xn?Xn._next=this:Do=this,Xn=this),this._call=e,this._time=r,Qi()},stop:function(){this._call&&(this._call=null,this._time=1/0,Qi())}};function pm(e,t,r){var n=new Bo;return n.restart(e,t,r),n}function Ki(){ac(),++gn;for(var e=Do,t;e;)(t=Or-e._time)>=0&&e._call.call(void 0,t),e=e._next;--gn}function ad(){Or=(No=ha.now())+Cs,gn=Qn=0;try{Ki()}finally{gn=0,KO(),Or=0}}function YO(){var e=ha.now(),t=e-No;t>dm&&(Cs-=t,No=e)}function KO(){for(var e,t=Do,r,n=1/0;t;)t._call?(n>t._time&&(n=t._time),e=t,t=t._next):(r=t._next,t._next=null,t=e?e._next=r:Do=r);Xn=e,Qi(n)}function Qi(e){if(!gn){Qn&&(Qn=clearTimeout(Qn));var t=e-Or;t>24?(e<1/0&&(Qn=setTimeout(ad,e-ha.now()-Cs)),Ln&&(Ln=clearInterval(Ln))):(Ln||(No=ha.now(),Ln=setInterval(YO,dm)),gn=1,hm(ad))}}function QO(e,t,r){var n=new Bo;return t=t==null?0:+t,n.restart(a=>{n.stop(),e(a+t)},t,r),n}class XO{constructor(t,r,n){this.duration=void 0,this.elapsed=0,this.easingFn=void 0,this.timer=null,this.onTickCallback=void 0,this.duration=t,this.easingFn=r,this.onTickCallback=n,this.resume()}get running(){return this.timer!==null}timerCallback(t){this.elapsed=Math.min(t,this.duration);const r=this.duration===0?1:this.elapsed/this.duration,n=this.easingFn(r);this.onTickCallback(n),this.elapsed>=this.duration&&this.stop()}resume(){if(this.running||this.elapsed>=this.duration)return this;const t=ac()-this.elapsed;return this.timer=pm(r=>this.timerCallback(r),0,t),Ki(),this}stop(){return this.running?(this.timer&&(this.timer.stop(),this.timer=null),this):this}finish(){return this.stop(),QO(()=>this.timerCallback(this.duration)),Ki(),this}}function ZO(e,t){if(Object.is(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;const r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(let a=0;a<r.length;a+=1){const o=r[a];if(!Object.prototype.hasOwnProperty.call(t,o)||!Object.is(e[o],t[o]))return!1}return!0}function ew(e,{createInterpolator:t,applyProps:r,skip:n,initialProps:a=e}){const o=V.useRef(a),s=V.useRef(null),i=V.useRef(null),l=V.useRef(e);Ft(()=>{l.current=e},[e]),Ft(()=>{var d;n&&((d=s.current)==null||d.finish(),s.current=null,i.current=null,o.current=e)},[e,n]);const c=V.useCallback(d=>{const h=o.current,p=t(h,e);s.current=new XO(qO,JO,f=>{const m=p(f);o.current=m,r(d,m)})},[r,t,e]);return V.useCallback(d=>{var p,f,m,b;if(d===null){(p=s.current)==null||p.stop();return}const h=i.current;if(h===d){if(ZO(l.current,e)){(f=s.current)==null||f.resume();return}(m=s.current)==null||m.stop()}h&&((b=s.current)==null||b.stop()),i.current=d,(s.current||!n)&&c(d)},[c,e,n])}function tw(e,{createInterpolator:t,transformProps:r,applyProps:n,skip:a,initialProps:o=e,ref:s}){const i=r??(u=>u),l=ew(e,{initialProps:o,createInterpolator:t,applyProps:(u,d)=>n(u,i(d)),skip:a});return Y({},r(a?e:o),{ref:Zh(l,s)})}function od(e){const{isReversed:t,gradientId:r,size:n,direction:a,scale:o,colorMap:s}=e;return n<=0?null:S.jsx("linearGradient",{id:r,x1:"0",x2:"0",y1:"0",y2:"0",[`${a}${t?1:2}`]:`${n}px`,gradientUnits:"userSpaceOnUse",children:s.thresholds.map((i,l)=>{const c=o(i);if(c===void 0)return null;const u=t?1-c/n:c/n;return Number.isNaN(u)?null:S.jsxs(V.Fragment,{children:[S.jsx("stop",{offset:u,stopColor:s.colors[l],stopOpacity:1}),S.jsx("stop",{offset:u,stopColor:s.colors[l+1],stopOpacity:1})]},i.toString()+l)})})}const rw=10;function sd(e){const{gradientUnits:t,isReversed:r,gradientId:n,size:a,direction:o,scale:s,colorScale:i,colorMap:l}=e,c=[l.min??0,l.max??100],u=c.map(s).filter(f=>f!==void 0);if(u.length!==2)return null;const d=typeof c[0]=="number"?Ot(c[0],c[1]):Bl(c[0],c[1]),h=Math.round((Math.max(...u)-Math.min(...u))/rw),p=`${c[0]}-${c[1]}-`;return S.jsx("linearGradient",{id:n,x1:"0",x2:"0",y1:"0",y2:"0",[`${o}${r?1:2}`]:t==="objectBoundingBox"?1:`${a}px`,gradientUnits:t??"userSpaceOnUse",children:Array.from({length:h+1},(f,m)=>{const b=d(m/h);if(b===void 0)return null;const x=s(b);if(x===void 0)return null;const _=r?1-x/a:x/a,O=i(b);return O===null?null:S.jsx("stop",{offset:_,stopColor:O,stopOpacity:1},p+m)})})}const nw=10,aw=e=>e?{x1:"1",x2:"0",y1:"0",y2:"0"}:{x1:"0",x2:"1",y1:"0",y2:"0"};function fi(e){const{isReversed:t,gradientId:r,colorScale:n,colorMap:a}=e,o=[a.min??0,a.max??100],s=typeof o[0]=="number"?Ot(o[0],o[1]):Bl(o[0],o[1]),i=nw,l=`${o[0]}-${o[1]}-`;return S.jsx("linearGradient",Y({id:r},aw(t),{gradientUnits:"objectBoundingBox",children:Array.from({length:i+1},(c,u)=>{const d=u/i,h=s(d);if(h===void 0)return null;const p=n(h);return p===null?null:S.jsx("stop",{offset:d,stopColor:p,stopOpacity:1},l+u)})}))}function ow(){const{top:e,height:t,bottom:r,left:n,width:a,right:o}=cm(),s=e+t+r,i=n+a+o,l=BO(),c=FO(),{xAxis:u,xAxisIds:d}=UO(),{yAxis:h,yAxisIds:p}=LO(),{zAxis:f,zAxisIds:m}=DO(),b=p.filter(O=>h[O].colorMap!==void 0),x=d.filter(O=>u[O].colorMap!==void 0),_=m.filter(O=>f[O].colorMap!==void 0);return b.length===0&&x.length===0&&_.length===0?null:S.jsxs("defs",{children:[b.map(O=>{const C=l(O),P=c(O),{colorMap:w,scale:R,colorScale:I,reverse:F}=h[O];return(w==null?void 0:w.type)==="piecewise"?S.jsx(od,{isReversed:!F,scale:R,colorMap:w,size:s,gradientId:C,direction:"y"},C):(w==null?void 0:w.type)==="continuous"?S.jsxs(V.Fragment,{children:[S.jsx(sd,{isReversed:!F,scale:R,colorScale:I,colorMap:w,size:s,gradientId:C,direction:"y"}),S.jsx(fi,{isReversed:F,colorScale:I,colorMap:w,gradientId:P})]},C):null}),x.map(O=>{const C=l(O),P=c(O),{colorMap:w,scale:R,reverse:I,colorScale:F}=u[O];return(w==null?void 0:w.type)==="piecewise"?S.jsx(od,{isReversed:I,scale:R,colorMap:w,size:i,gradientId:C,direction:"x"},C):(w==null?void 0:w.type)==="continuous"?S.jsxs(V.Fragment,{children:[S.jsx(sd,{isReversed:I,scale:R,colorScale:F,colorMap:w,size:i,gradientId:C,direction:"x"}),S.jsx(fi,{isReversed:I,colorScale:F,colorMap:w,gradientId:P})]},C):null}),_.map(O=>{const C=c(O),{colorMap:P,colorScale:w}=f[O];return(P==null?void 0:P.type)==="continuous"?S.jsx(fi,{colorScale:w,colorMap:P,gradientId:C},C):null})]})}const sw=["children","className","title","desc"],iw=dt("svg",{name:"MuiChartsSurface",slot:"Root"})(({ownerState:e})=>({width:e.width??"100%",height:e.height??"100%",display:"flex",position:"relative",flexDirection:"column",alignItems:"center",justifyContent:"center",overflow:"hidden",touchAction:"pan-y",userSelect:"none"})),oc=V.forwardRef(function(t,r){const n=Vr(),{width:a,height:o}=at(n,qb),{width:s,height:i}=at(n,Hb),l=NO(),c=Zh(l,r),u=Y0({props:t,name:"MuiChartsSurface"}),{children:d,className:h,title:p,desc:f}=u,m=or(u,sw),b=o>0&&a>0;return S.jsxs(iw,Y({ownerState:{width:s,height:i},viewBox:`0 0 ${a} ${o}`,className:h},m,{ref:c,children:[p&&S.jsx("title",{children:p}),f&&S.jsx("desc",{children:f}),S.jsx(ow,{}),b&&d]}))});process.env.NODE_ENV!=="production"&&(oc.displayName="ChartsSurface");process.env.NODE_ENV!=="production"&&(oc.propTypes={children:g.node,className:g.string,desc:g.string,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),title:g.string});function Dn(e,t){if(typeof e=="number")return e;if(e==="100%")return t;if(e.endsWith("%")){const r=Number.parseFloat(e.slice(0,e.length-1));if(!Number.isNaN(r))return r*t/100}if(e.endsWith("px")){const r=Number.parseFloat(e.slice(0,e.length-2));if(!Number.isNaN(r))return r}throw new Error(`MUI X Charts: Received an unknown value "${e}". It should be a number, or a string with a percentage value.`)}function gi(e){const t=Yi(e);return[Math.sin(t),-Math.cos(t)]}function lw(e,t){const r=[[0,0],gi(e),gi(t)],n=Math.min(e,t),a=Math.max(e,t),o=Math.floor(n/90)*90;for(let u=1;u<=4;u+=1){const d=o+u*90;d<a&&r.push(gi(d))}const s=Math.min(...r.map(([u])=>u)),i=Math.max(...r.map(([u])=>u)),l=Math.min(...r.map(([,u])=>u)),c=Math.max(...r.map(([,u])=>u));return{cx:-s/(i-s),cy:-l/(c-l),minX:s,maxX:i,minY:l,maxY:c}}function cw(e,t,r,n,{minX:a,maxX:o,minY:s,maxY:i}){return Math.min(...[{ratio:Math.abs(a),space:e},{ratio:Math.abs(o),space:r-e},{ratio:Math.abs(s),space:t},{ratio:Math.abs(i),space:n-t}].map(({ratio:l,space:c})=>l<1e-5?1/0:c/l))}const sc=V.createContext({value:null,valueMin:0,valueMax:0,startAngle:0,endAngle:0,innerRadius:0,outerRadius:0,cornerRadius:0,cx:0,cy:0,maxRadius:0,valueAngle:null});process.env.NODE_ENV!=="production"&&(sc.displayName="GaugeContext");function uw(e){const{value:t=null,valueMin:r=0,valueMax:n=100,startAngle:a=0,endAngle:o=360,outerRadius:s,innerRadius:i,cornerRadius:l,cx:c,cy:u,children:d}=e,{left:h,top:p,width:f,height:m}=cm(),b=lw(a,o),x=c?Dn(c,f):b.cx*f,_=u?Dn(u,m):b.cy*m;let O=h+x,C=p+_;const P=cw(x,_,f,m,b);if(c===void 0){const y=P*(b.maxX-b.minX);O=h+(f-y)/2+b.cx*y}if(u===void 0){const y=P*(b.maxY-b.minY);C=p+(m-y)/2+b.cy*y}const w=Dn(s??P,P),R=Dn(i??"80%",P),I=Dn(l??0,w-R),F=V.useMemo(()=>{const y=Yi(a),T=Yi(o);return{value:t,valueMin:r,valueMax:n,startAngle:y,endAngle:T,outerRadius:w,innerRadius:R,cornerRadius:I,cx:O,cy:C,maxRadius:P,valueAngle:t===null?null:y+(T-y)*(t-r)/(n-r)}},[t,r,n,a,o,w,R,I,O,C,P]);return S.jsx(sc.Provider,{value:F,children:d})}function ic(){return V.useContext(sc)}const dw=["width","height","margin","title","desc","value","valueMin","valueMax","startAngle","endAngle","outerRadius","innerRadius","cornerRadius","cx","cy","children"],hw=dt("g")(({theme:e})=>({"& text":{fill:(e.vars||e).palette.text.primary}})),lc=V.forwardRef(function(t,r){const{width:n,height:a,margin:o,title:s,desc:i,value:l,valueMin:c=0,valueMax:u=100,startAngle:d,endAngle:h,outerRadius:p,innerRadius:f,cornerRadius:m,cx:b,cy:x,children:_}=t,O=or(t,dw);return S.jsx(kO,{pluginParams:{width:n,height:a,margin:sp(o,{left:10,right:10,top:10,bottom:10})},plugins:[],children:S.jsx(uw,{value:l,valueMin:c,valueMax:u,startAngle:d,endAngle:h,outerRadius:p,innerRadius:f,cornerRadius:m,cx:b,cy:x,children:S.jsx(oc,Y({title:s,desc:i,role:"meter","aria-valuenow":l===null?void 0:l,"aria-valuemin":c,"aria-valuemax":u},O,{ref:r,children:S.jsx(hw,{"aria-hidden":"true",children:_})}))})})});process.env.NODE_ENV!=="production"&&(lc.displayName="GaugeContainer");process.env.NODE_ENV!=="production"&&(lc.propTypes={children:g.node,className:g.string,cornerRadius:g.oneOfType([g.number,g.string]),cx:g.oneOfType([g.number,g.string]),cy:g.oneOfType([g.number,g.string]),desc:g.string,endAngle:g.number,height:g.number,id:g.string,innerRadius:g.oneOfType([g.number,g.string]),margin:g.oneOfType([g.number,g.shape({bottom:g.number,left:g.number,right:g.number,top:g.number})]),outerRadius:g.oneOfType([g.number,g.string]),skipAnimation:g.bool,startAngle:g.number,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),title:g.string,value:g.number,valueMax:g.number,valueMin:g.number,width:g.number});function pw(e){const t=Vr(),r=at(t,xb);return e||r}function mw(e,t){const r=Ot(e.startAngle,t.startAngle),n=Ot(e.endAngle,t.endAngle),a=Ot(e.innerRadius,t.innerRadius),o=Ot(e.outerRadius,t.outerRadius),s=Ot(e.cornerRadius,t.cornerRadius);return i=>({startAngle:r(i),endAngle:n(i),innerRadius:a(i),outerRadius:o(i),cornerRadius:s(i)})}function fw(e){return tw({startAngle:e.startAngle,endAngle:e.endAngle,innerRadius:e.innerRadius,outerRadius:e.outerRadius,cornerRadius:e.cornerRadius},{createInterpolator:mw,transformProps:t=>({d:tm().cornerRadius(t.cornerRadius)({innerRadius:t.innerRadius,outerRadius:t.outerRadius,startAngle:t.startAngle,endAngle:t.endAngle})}),applyProps(t,r){t.setAttribute("d",r.d)},initialProps:{startAngle:e.startAngle,endAngle:e.startAngle,innerRadius:e.innerRadius,outerRadius:e.outerRadius,cornerRadius:e.cornerRadius},skip:e.skipAnimation,ref:e.ref})}const gw=["cx","cy","startAngle","endAngle","cornerRadius","innerRadius","outerRadius","skipAnimation"],yw=dt("path",{name:"MuiGauge",slot:"ReferenceArc"})(({theme:e})=>({fill:(e.vars||e).palette.primary.main}));function mm(e){const{value:t,valueMin:r,valueMax:n,startAngle:a,endAngle:o,outerRadius:s,innerRadius:i,cornerRadius:l,cx:c,cy:u}=ic();if(t===null)return null;const d=a+(t-r)/(n-r)*(o-a);return S.jsx(fm,Y({},e,{cx:c,cy:u,startAngle:a,endAngle:d,cornerRadius:l,innerRadius:i,outerRadius:s}))}process.env.NODE_ENV!=="production"&&(mm.propTypes={skipAnimation:g.bool});function fm(e){let{cx:t,cy:r,startAngle:n,endAngle:a,cornerRadius:o,innerRadius:s,outerRadius:i,skipAnimation:l}=e,c=or(e,gw);const u=pw(l),d=fw({startAngle:n,endAngle:a,cornerRadius:o,innerRadius:s,outerRadius:i,skipAnimation:u});return S.jsx(yw,Y({},d,{transform:`translate(${t}, ${r})`},c))}process.env.NODE_ENV!=="production"&&(fm.propTypes={cornerRadius:g.number.isRequired,cx:g.number.isRequired,cy:g.number.isRequired,endAngle:g.number.isRequired,innerRadius:g.number.isRequired,outerRadius:g.number.isRequired,skipAnimation:g.bool,startAngle:g.number.isRequired});const bw=dt("path",{name:"MuiGauge",slot:"ReferenceArc"})(({theme:e})=>({fill:(e.vars||e).palette.divider}));function vw(e){const{startAngle:t,endAngle:r,outerRadius:n,innerRadius:a,cornerRadius:o,cx:s,cy:i}=ic();return S.jsx(bw,Y({transform:`translate(${s}, ${i})`,d:tm().cornerRadius(o)({startAngle:t,endAngle:r,innerRadius:a,outerRadius:n})},e))}const id=e=>e,Sw=()=>{let e=id;return{configure(t){e=t},generate(t){return e(t)},reset(){e=id}}},xw=Sw(),Ow={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function gm(e,t,r="Mui"){const n=Ow[t];return n?`${r}-${n}`:`${xw.generate(e)}-${t}`}function ww(e,t,r="Mui"){const n={};return t.forEach(a=>{n[a]=gm(e,a,r)}),n}function Cw(e){return gm("MuiGauge",e)}ww("MuiGauge",["root","valueArc","referenceArc","valueText"]);function Pw(){return typeof window>"u"}const Qa=new Map,Tw=2e3,Rw={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},Aw=["minWidth","maxWidth","width","minHeight","maxHeight","height","top","left","fontSize","padding","margin","paddingLeft","paddingRight","paddingTop","paddingBottom","marginLeft","marginRight","marginTop","marginBottom"],ld="mui_measurement_span";function ym(e,t){return Aw.indexOf(e)>=0&&t===+t?`${t}px`:t}function bm(e){return e.split("").reduce((n,a)=>a===a.toUpperCase()?[...n,"-",a.toLowerCase()]:[...n,a],[]).join("")}const _w=e=>Object.keys(e).sort().reduce((t,r)=>`${t}${bm(r)}:${ym(r,e[r])};`,"");let yi;const Ew=(e,t={})=>{if(e==null||Pw())return{width:0,height:0};const r=`${e}`,n=_w(t),a=`${r}-${n}`,o=Qa.get(a);if(o)return o;try{let s=document.getElementById(ld);s===null&&(s=document.createElement("span"),s.setAttribute("id",ld),s.setAttribute("aria-hidden","true"),document.body.appendChild(s));const i=Y({},Rw,t);Object.keys(i).map(u=>(s.style[bm(u)]=ym(u,i[u]),u)),s.textContent=r;const l=s.getBoundingClientRect(),c={width:l.width,height:l.height};return Qa.set(a,c),Qa.size+1>Tw&&Qa.clear(),process.env.NODE_ENV==="test"?s.textContent="":(yi&&clearTimeout(yi),yi=setTimeout(()=>{s.textContent=""},0)),c}catch{return{width:0,height:0}}};function Vw({style:e,needsComputation:t,text:r}){return r.split(`
|
|
123
|
+
`).map(n=>Y({text:n},t?Ew(n,e):{width:0,height:0}))}function Iw(){const[e,t]=V.useState(typeof window<"u"||process.env.NODE_ENV==="test");return V.useEffect(()=>{t(!0)},[]),e}const Mw=["x","y","style","text","ownerState"],$w=["angle","textAnchor","dominantBaseline"];function vm(e){const{x:t,y:r,style:n,text:a}=e,o=or(e,Mw),s=n??{},{angle:i,textAnchor:l,dominantBaseline:c}=s,u=or(s,$w),d=Iw(),h=V.useMemo(()=>Vw({style:u,needsComputation:d&&a.includes(`
|
|
124
|
+
`),text:a}),[u,a,d]);let p;switch(c){case"hanging":case"text-before-edge":p=0;break;case"central":p=(h.length-1)/2*-h[0].height;break;default:p=(h.length-1)*-h[0].height;break}return S.jsx("text",Y({},o,{transform:i?`rotate(${i}, ${t}, ${r})`:void 0,x:t,y:r,textAnchor:l,dominantBaseline:c,style:u,children:h.map((f,m)=>S.jsx("tspan",{x:t,dy:`${m===0?p:h[0].height}px`,dominantBaseline:c,children:f.text},m))}))}process.env.NODE_ENV!=="production"&&(vm.propTypes={lineHeight:g.number,needsComputation:g.bool,ownerState:g.any,style:g.object,text:g.string.isRequired});const jw=["text","className"];function kw({value:e}){return e===null?null:e.toLocaleString()}function Sm(e){const{text:t=kw,className:r}=e,n=or(e,jw),{value:a,valueMin:o,valueMax:s,cx:i,cy:l}=ic(),c=typeof t=="function"?t({value:a,valueMin:o,valueMax:s}):t;return c===null?null:S.jsx("g",{className:r,children:S.jsx(vm,Y({x:i,y:l,text:c,style:{textAnchor:"middle",dominantBaseline:"central"}},n))})}process.env.NODE_ENV!=="production"&&(Sm.propTypes={lineHeight:g.number,needsComputation:g.bool,ownerState:g.any,style:g.object,text:g.oneOfType([g.func,g.string])});const Uw=["text","children","classes","className","skipAnimation"],Lw=e=>{const{classes:t}=e;return xg({root:["root"],valueArc:["valueArc"],referenceArc:["referenceArc"],valueText:["valueText"]},Cw,t)},Fo=V.forwardRef(function(t,r){const{text:n,children:a,className:o,skipAnimation:s}=t,i=or(t,Uw),l=Lw(t);return S.jsxs(lc,Y({},i,{className:It(l.root,o),ref:r,children:[S.jsx(vw,{className:l.referenceArc}),S.jsx(mm,{className:l.valueArc,skipAnimation:s}),S.jsx(Sm,{className:l.valueText,text:n}),a]}))});process.env.NODE_ENV!=="production"&&(Fo.displayName="Gauge");process.env.NODE_ENV!=="production"&&(Fo.propTypes={children:g.node,classes:g.object,className:g.string,cornerRadius:g.oneOfType([g.number,g.string]),cx:g.oneOfType([g.number,g.string]),cy:g.oneOfType([g.number,g.string]),desc:g.string,endAngle:g.number,height:g.number,id:g.string,innerRadius:g.oneOfType([g.number,g.string]),margin:g.oneOfType([g.number,g.shape({bottom:g.number,left:g.number,right:g.number,top:g.number})]),outerRadius:g.oneOfType([g.number,g.string]),skipAnimation:g.bool,startAngle:g.number,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),text:g.oneOfType([g.func,g.string]),title:g.string,value:g.number,valueMax:g.number,valueMin:g.number,width:g.number});const Dw={"Jogging.Cartesian.Translation.velocityMmPerSec.lb":"{{amount}} mm/s","Jogging.Cartesian.Rotation.velocityDegPerSec.lb":"{{amount}}°/s","Jogging.Velocity.lb":"Geschwindigkeit","General.degree.variable":"{{amount}}°","General.mm.variable":"{{amount}} mm","Jogging.Cartesian.MotionType.lb":"Bewegungstyp","Jogging.Cartesian.Translation.bt":"Translation","Jogging.Cartesian.Rotation.bt":"Rotation","Jogging.Joints.JointValues.lb":"Gelenkwerte","Jogging.Increment.Continuous.dd":"Fortlaufend","Jogging.Cartesian.Orientation.lb":"Orientierung","Jogging.JointLimitsReached.lb":"Gelenkgrenzen für Gelenk {{jointNumbers}} erreicht","Jogging.Orientation.coordsys":"Roboterbasis","Jogging.Orientation.tool":"Werkzeug","SafetyBar.ActivationToggle.Activate.bt":"Aktivieren","SafetyBar.ActivationToggle.Activated.bt":"Aktiviert","SafetyBar.ActivationToggle.Activating.bt":"Wird aktiviert…","SafetyBar.ActivationToggle.Deactivating.bt":"Wird deaktiviert…","SafetyBar.ControllerType.Physical.lb":"Physisch","SafetyBar.ControllerType.Virtual.lb":"Virtuell","SafetyBar.MotionGroup.Physical.Explanation.lb":"<code>{{motionGroupId}}</code> ist ein physische Robotersteuerung. Für die Bewegung dieses Roboters sind <strong>Sicherheitsmaßnahmen</strong> aktiv.","SafetyBar.MotionGroup.Virtual.Explanation.lb":"<1>{{motionGroupId}}</1> ist eine virtuelle Robotersteuerung ohne physisches Gegenstück. Der Roboter kann ohne Sicherheitsmaßnahmen bewegt werden.","SafetyBar.OperationMode.Auto.Explanation.lb":"Automatischer Betriebsmodus der Robotersteuerung aktiv. Automatisierte Bewegung ohne manuelle Bestätigung freigegeben.","SafetyBar.OperationMode.Automatic.ti":"Automatisch","SafetyBar.OperationMode.Error.Explanation.lb":"Fehler beim Abrufen des Betriebsmodus. Originalhandbediengerät des Roboters verwenden, um Fehler zu lösen.","SafetyBar.OperationMode.Error.lb":"Fehler","SafetyBar.OperationMode.Manual.Explanation.lb":`Die Robotersteuerung befindet sich im manuellen Betriebsmodus.
|
|
125
|
+
Bei einem physischen Roboter bedeutet dies im Allgemeinen, dass ein Freigabeschalter gedrückt werden muss, damit sich der Roboter erfolgreich bewegen kann.`,"SafetyBar.OperationMode.Manual.lb":"Manuell","SafetyBar.OperationMode.ti":"Betriebsmodus","SafetyBar.SafetyState.Error.Explanation.lb":"Die Robotersteuerung ist in einen unerwarteten Sicherheitszustand eingetreten.","SafetyBar.SafetyState.Error.lb":"Fehler","SafetyBar.SafetyState.Estop.lb":"NOT-AUS","SafetyBar.SafetyState.ManualActionRequired.Explanation.lb":"Die Robotersteuerung ist in einen Sicherheitszustand eingetreten, der manuelle Maßnahmen zur Behebung erfordert.","SafetyBar.SafetyState.ManualActionRequired.lb":"Aktion erforderlich","SafetyBar.SafetyState.Normal.Explanation.lb":"Die Robotersteuerung befindet sich in einem sicheren Zustand. Roboterbewegungen sind möglich.","SafetyBar.SafetyState.Normal.lb":"Sicher","SafetyBar.SafetyState.Stop.Explanation.lb":"Die Robotersteuerung ist in einen Stoppzustand übergegangen. Bis der Stoppzustand aufgelöst ist, ist keine Bewegung mehr möglich.","SafetyBar.SafetyState.Stop.lb":"Stopp","SafetyBar.SafetyState.ti":"Sicherheitszustand","SafetyBar.StopState.Estop.Explanation.lb":"NOT-AUS aktiviert. NOT-AUS freischalten, um Roboter zu bewegen.","Jogging.Increment.hlb":"Schrittgröße","Jogging.CoordinateSystem.hlb":"Koordinatensystem","Jogging.Cartesian.bt":"Kartesisch","Jogging.Joints.bt":"Gelenke","Jogging.Velocity.bt":"Geschwindigkeit","CycleTimer.RemainingTime.lb":"Verbleibende Zeit","CycleTimer.OfTime.lb":"von {{time}} min.","CycleTimer.Time.lb":"{{time}} min.","ProgramControl.Start.bt":"Start","ProgramControl.Resume.bt":"Weiter","ProgramControl.Pause.bt":"Pause","ProgramControl.Stop.bt":"Stopp","ProgramStateIndicator.Running.lb":"In Betrieb","ProgramStateIndicator.Error.lb":"Fehler","ProgramStateIndicator.EStop.lb":"Not-Aus","ProgramStateIndicator.Idle.lb":"Leerlauf","ProgramStateIndicator.Paused.lb":"Pausiert","ProgramStateIndicator.Ready.lb":"Bereit","ProgramStateIndicator.Stopped.lb":"Gestoppt","ProgramStateIndicator.Auto.lb":"Auto","ProgramStateIndicator.Manual.lb":"Manuell","ProgramStateIndicator.ManualT1.lb":"Manuell T1","ProgramStateIndicator.ManualT2.lb":"Manuell T2","RobotSetupReadinessIndicator.Ready.lb":"Bereit","RobotSetupReadinessIndicator.RobotDisconnected.lb":"Roboter getrennt","RobotSetupReadinessIndicator.PreconditionNotFulfilled.lb":"Voraussetzung nicht erfüllt"},Nw={"Jogging.Cartesian.Translation.velocityMmPerSec.lb":"{{amount}} mm/s","Jogging.Cartesian.Rotation.velocityDegPerSec.lb":"{{amount}}°/s","Jogging.Velocity.lb":"Velocity","General.degree.variable":"{{amount}}°","General.mm.variable":"{{amount}} mm","Jogging.Cartesian.MotionType.lb":"Motion type","Jogging.Cartesian.Translation.bt":"Translation","Jogging.Cartesian.Rotation.bt":"Rotation","Jogging.Joints.JointValues.lb":"Joint values","Jogging.Increment.Continuous.dd":"Continuous","Jogging.Cartesian.Orientation.lb":"Orientation","Jogging.Activating.lb":"Activating jogging","Jogging.JointLimitsReached.lb":"Joint limit reached for joint {{jointNumbers}}","Jogging.Orientation.coordsys":"Robot base","Jogging.Orientation.tool":"Tool","SafetyBar.ActivationToggle.Activate.bt":"Activate","SafetyBar.ActivationToggle.Activated.bt":"Activated","SafetyBar.ActivationToggle.Activating.bt":"Activating","SafetyBar.ActivationToggle.Deactivating.bt":"Deactivating","SafetyBar.ControllerType.Physical.lb":"Physical","SafetyBar.ControllerType.Virtual.lb":"Virtual","SafetyBar.MotionGroup.Physical.Explanation.lb":"<code>{{motionGroupId}}</code> is a physical robot controller. <strong>Safety precautions</strong> are active for the movement of this robot.","SafetyBar.MotionGroup.Virtual.Explanation.lb":"<1>{{motionGroupId}}</1> is a virtual robot controller with no physical counterpart. It can be freely manipulated without safety precautions.","SafetyBar.OperationMode.Auto.Explanation.lb":"Automatic operation mode active. Automated movement without manual confirmation enabled.","SafetyBar.OperationMode.Automatic.ti":"Automatic","SafetyBar.OperationMode.Error.Explanation.lb":"Failed to get operation mode. Use the original control panel to resolve the error.","SafetyBar.OperationMode.Error.lb":"Error","SafetyBar.OperationMode.Manual.Explanation.lb":"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.","SafetyBar.OperationMode.Manual.lb":"Manual","SafetyBar.OperationMode.ti":"Operation mode","SafetyBar.SafetyState.Error.Explanation.lb":"The robot controller has entered an unexpected safety state.","SafetyBar.SafetyState.Error.lb":"Error","SafetyBar.SafetyState.Estop.lb":"E-Stop","SafetyBar.SafetyState.ManualActionRequired.Explanation.lb":"The robot controller has entered a safety state requiring manual action to resolve.","SafetyBar.SafetyState.ManualActionRequired.lb":"Action required","SafetyBar.SafetyState.Normal.Explanation.lb":"The robot controller is in a safe state. Robot movement is enabled.","SafetyBar.SafetyState.Normal.lb":"Safe","SafetyBar.SafetyState.Stop.Explanation.lb":"The robot controller has entered a stop state. Movement is no longer possible until the stop state is resolved.","SafetyBar.SafetyState.Stop.lb":"Stop","SafetyBar.SafetyState.ti":"Safety state","SafetyBar.StopState.Estop.Explanation.lb":"An emergency stop of the robot controller has been triggered. Movement of the robot is no longer possible until the estop is released.","Jogging.Increment.hlb":"Increment","Jogging.CoordinateSystem.hlb":"Coordinate system","Jogging.Cartesian.bt":"Cartesian","Jogging.Joints.bt":"Joints","Jogging.Velocity.bt":"Velocity","CycleTimer.RemainingTime.lb":"Time remaining","CycleTimer.OfTime.lb":"of {{time}} min.","CycleTimer.Time.lb":"{{time}} min.","ProgramControl.Start.bt":"Start","ProgramControl.Resume.bt":"Resume","ProgramControl.Pause.bt":"Pause","ProgramControl.Stop.bt":"Stop","ProgramStateIndicator.Running.lb":"Running","ProgramStateIndicator.Error.lb":"Error","ProgramStateIndicator.EStop.lb":"E-Stop","ProgramStateIndicator.Idle.lb":"Idle","ProgramStateIndicator.Paused.lb":"Paused","ProgramStateIndicator.Ready.lb":"Ready","ProgramStateIndicator.Stopped.lb":"Stopped","ProgramStateIndicator.Auto.lb":"Auto","ProgramStateIndicator.Manual.lb":"Manual","ProgramStateIndicator.ManualT1.lb":"Manual T1","ProgramStateIndicator.ManualT2.lb":"Manual T2","RobotSetupReadinessIndicator.Ready.lb":"Ready","RobotSetupReadinessIndicator.RobotDisconnected.lb":"Robot disconnected","RobotSetupReadinessIndicator.PreconditionNotFulfilled.lb":"Precondition not fulfilled"},cc=ig.createInstance();cc.use(lg).init({supportedLngs:["en","de"],resources:{en:{translations:Nw},de:{translations:Dw}},ns:["translations"],defaultNS:"translations",detection:{order:["navigator","htmlTag"]}});function Ct(e){return r=>S.jsx(Bw,{children:S.jsx(e,{...r})})}const Bw=({children:e})=>S.jsx(_e.I18nextProvider,{i18n:cc,children:e});class uc{constructor(t=[],r={}){this.currentValues=[],this.targetValues=[],this.previousTargetValues=[],this.targetUpdateTime=0,this.animationId=null,this.updateCount=0,this.velocities=[],this.animate=()=>{this.update(.016666666666666666)?this.animationId=null:this.animationId=requestAnimationFrame(this.animate)},this.options={tension:120,friction:20,threshold:.001,onChange:()=>{},onComplete:()=>{},...r},this.currentValues=[...t],this.targetValues=[...t],this.previousTargetValues=[...t],this.velocities=new Array(t.length).fill(0),this.targetUpdateTime=performance.now(),this.updateCount=0}update(t=1/60){let r=!1,n=!0;this.updateCount++;const a=Math.min(t,1/15),o=this.updateCount===1?.7:1;for(let s=0;s<this.currentValues.length;s++){const i=this.currentValues[s],l=this.targetValues[s],c=this.velocities[s],u=l-i,d=u*this.options.tension*o,h=c*this.options.friction,p=d-h,f=c+p*a,m=i+f*a;Math.abs(u)<this.options.threshold&&Math.abs(f)<this.options.threshold*10?this.currentValues[s]!==l&&(this.currentValues[s]=l,this.velocities[s]=0,r=!0):(n=!1,this.currentValues[s]=m,this.velocities[s]=f,r=!0)}return r&&this.options.onChange(this.currentValues),n&&this.options.onComplete(this.currentValues),n}setTarget(t){const r=performance.now(),n=r-this.targetUpdateTime;this.previousTargetValues=[...this.targetValues],this.targetValues=[...t],this.targetUpdateTime=r,this.updateCount=0;const a=this.previousTargetValues.every((o,s)=>o===this.currentValues[s]);if(n<8&&n>0&&this.previousTargetValues.length>0&&!a){const o=Math.min(n/8,1);for(let s=0;s<this.targetValues.length;s++){const i=this.previousTargetValues[s]||0,l=t[s]||0;Math.abs(l-i)>.1&&(this.targetValues[s]=i+(l-i)*o)}}for(;this.currentValues.length<t.length;)this.currentValues.push(t[this.currentValues.length]),this.velocities.push(0);this.currentValues.length>t.length&&(this.currentValues=this.currentValues.slice(0,t.length),this.velocities=this.velocities.slice(0,t.length))}getCurrentValues(){return[...this.currentValues]}getValue(t){return this.currentValues[t]??0}isInterpolating(){return this.animationId!==null}stop(){this.animationId!==null&&(cancelAnimationFrame(this.animationId),this.animationId=null)}setImmediate(t){this.stop(),this.currentValues=[...t],this.targetValues=[...t],this.previousTargetValues=[...t],this.velocities=new Array(t.length).fill(0),this.targetUpdateTime=performance.now(),this.updateCount=0,this.options.onChange(this.currentValues)}updateOptions(t){this.options={...this.options,...t}}startAutoInterpolation(){this.startInterpolation()}destroy(){this.stop()}startInterpolation(){this.animationId===null&&this.animate()}}function xm(e=[],t={}){const r=ee.useRef(null);return r.current||(r.current=new uc(e,t)),ee.useEffect(()=>{var n;(n=r.current)==null||n.updateOptions(t)},[t]),ee.useEffect(()=>()=>{var n;(n=r.current)==null||n.destroy()},[]),[r.current]}const Fw=Ct(Ee.observer(({onCycleComplete:e,onCycleEnd:t,autoStart:r=!0,variant:n="default",compact:a=!1,className:o})=>{var z,E;const s=q.useTheme(),{t:i}=_e.useTranslation(),[l,c]=ee.useState(0),[u,d]=ee.useState(0),[h,p]=ee.useState(!1),[f,m]=ee.useState(!1),[b,x]=ee.useState(0),_=ee.useRef(null),O=ee.useRef(null),C=ee.useRef(0),[P]=xm([0],{tension:80,friction:18,onChange:([B])=>{x(B)}}),w=ee.useCallback((B,te=0)=>{d(B);const Z=Math.max(0,B-te);c(Z),m(!1),C.current=0;const ae=te>0?te/B*100:0;te===0?P.setTarget([0]):P.setTarget([ae]),Z===0?(p(!1),O.current=null,t&&setTimeout(()=>t(),0)):r?(O.current=Date.now()-te*1e3,p(!0)):O.current=null},[r,t,P]),R=ee.useCallback(()=>{if(O.current&&h){const te=Date.now()-O.current;C.current+=te;const Z=C.current/1e3,ae=Math.min(100,Z/u*100);P.setTarget([ae])}p(!1),m(!0)},[h,u,P]),I=ee.useCallback(()=>{f&&l>0&&(O.current=Date.now(),p(!0),m(!1))},[f,l]),F=ee.useCallback(()=>f,[f]);ee.useEffect(()=>{let B=!0;const te=setTimeout(()=>{B&&e({startNewCycle:w,pause:R,resume:I,isPaused:F})},0);return()=>{B=!1,clearTimeout(te)}},[e,w,R,I,F]),ee.useEffect(()=>{if(h){const B=()=>{if(O.current&&u>0){const Z=(Date.now()-O.current+C.current)/1e3,ae=Math.max(0,u-Z);c(Math.ceil(ae));const re=Math.min(100,Z/u*100);if(P.setTarget([re]),ae<=0){p(!1),O.current=null,c(0),P.setTarget([100]),t&&setTimeout(()=>t(),0);return}h&&(_.current=requestAnimationFrame(B))}};_.current=requestAnimationFrame(B)}else _.current&&(cancelAnimationFrame(_.current),_.current=null);return()=>{_.current&&cancelAnimationFrame(_.current)}},[h,t,u,P]),ee.useEffect(()=>{let B=null;const te=()=>{P.update(1/60),B=requestAnimationFrame(te)};return B=requestAnimationFrame(te),()=>{B&&cancelAnimationFrame(B)}},[P]),ee.useEffect(()=>{if(!h&&!f&&u>0){const B=(u-l)/u*100;P.setTarget([B])}},[h,f,u,l,P]);const y=B=>{const te=Math.floor(B/60),Z=B%60;return`${te}:${Z.toString().padStart(2,"0")}`},T=b;return n==="small"?S.jsxs(q.Box,{className:o,sx:{display:"flex",alignItems:"center",gap:.125},children:[S.jsxs(q.Box,{sx:{position:"relative",width:40,height:40,display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"50%",overflow:"visible"},children:[S.jsx(Fo,{width:40,height:40,value:T,valueMin:0,valueMax:100,innerRadius:"70%",outerRadius:"95%",skipAnimation:!0,sx:{opacity:f?.6:1,transition:"opacity 0.2s ease","& .MuiGauge-valueArc":{fill:s.palette.success.main},"& .MuiGauge-referenceArc":{fill:s.palette.success.main,opacity:.3},"& .MuiGauge-valueText":{display:"none"},"& .MuiGauge-text":{display:"none"},"& text":{display:"none"},"& .MuiGauge-referenceArcBackground":{display:"none"},"& .MuiGauge-valueArcBackground":{display:"none"},"& circle":{display:"none"}}}),S.jsx(q.Box,{sx:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:13,height:13,borderRadius:"50%",backgroundColor:((z=s.palette.background)==null?void 0:z.paper)||"white",pointerEvents:"none"}})]}),S.jsx(q.Typography,{variant:"body2",sx:{color:s.palette.text.primary,fontSize:"14px"},children:a?y(l):`${y(l)} / ${i("CycleTimer.Time.lb",{time:y(u)})}`})]}):S.jsxs(q.Box,{className:o,sx:{position:"relative",width:264,height:264,display:"flex",alignItems:"center",justifyContent:"center"},children:[S.jsx(Fo,{width:264,height:264,value:T,valueMin:0,valueMax:100,innerRadius:"71%",outerRadius:"90%",skipAnimation:!0,sx:{opacity:f?.6:1,transition:"opacity 0.2s ease","& .MuiGauge-valueArc":{fill:s.palette.success.main},"& .MuiGauge-referenceArc":{fill:"white",stroke:"transparent"}}}),S.jsxs(q.Box,{sx:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:187,height:187,borderRadius:"50%",backgroundColor:(E=s.palette.backgroundPaperElevation)==null?void 0:E[8],display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",textAlign:"center",gap:1},children:[S.jsx(q.Typography,{variant:"body2",sx:{fontSize:"12px",color:s.palette.text.secondary,marginBottom:.5},children:i("CycleTimer.RemainingTime.lb")}),S.jsx(q.Typography,{variant:"h1",sx:{fontSize:"48px",fontWeight:500,color:s.palette.text.primary,lineHeight:1,marginBottom:.5},children:y(l)}),S.jsx(q.Typography,{variant:"body2",sx:{fontSize:"12px",color:s.palette.text.secondary},children:i("CycleTimer.OfTime.lb",{time:y(u)})})]})]})}));process.env.NODE_ENV!=="production"&&(g.node,g.object.isRequired);function dc(e){return n0(e)}const on=g0({createStyledComponent:dt("div",{name:"MuiStack",slot:"Root"}),useThemeProps:e=>dc({props:e,name:"MuiStack"})});process.env.NODE_ENV!=="production"&&(on.propTypes={children:g.node,component:g.elementType,direction:g.oneOfType([g.oneOf(["column-reverse","column","row-reverse","row"]),g.arrayOf(g.oneOf(["column-reverse","column","row-reverse","row"])),g.object]),divider:g.node,spacing:g.oneOfType([g.arrayOf(g.oneOfType([g.number,g.string])),g.number,g.object,g.string]),sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),useFlexGap:g.bool});const zw=({title:e,titleId:t,...r},n)=>V.createElement("svg",{width:21,height:21,viewBox:"0 0 21 21",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.createElement("g",{id:"JogMinus"},V.createElement("path",{id:"Minus",d:"M0 13V8H21V13H0Z",fill:"white"}))),Gw=ee.forwardRef(zw),Hw=({title:e,titleId:t,...r},n)=>V.createElement("svg",{width:21,height:21,viewBox:"0 0 21 21",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.createElement("g",{id:"JogPlus"},V.createElement("g",{id:"Plus"},V.createElement("path",{d:"M0 13V8H8V13H0Z",fill:"white"}),V.createElement("path",{d:"M8 0L13 2.18557e-07L13 21H8L8 0Z",fill:"white"}),V.createElement("path",{d:"M13 13V8H21V13H13Z",fill:"white"})))),qw=ee.forwardRef(Hw);function Ps(e){ee.useEffect(e,[])}function Om(e){Ps(()=>Ne.autorun(e))}function wm(e,t,r){Ps(()=>Ne.reaction(e,t,r))}function xn(e){return Ps(()=>{let t;function r(){e(),t=requestAnimationFrame(r)}return t=requestAnimationFrame(r),()=>{cancelAnimationFrame(t)}})}const Xi=Ct(Ee.observer(({colors:e,label:t,getDisplayedValue:r,startJogging:n,stopJogging:a,disabled:o,activeJoggingDirection:s,...i})=>{var O,C,P,w,R,I,F;xn(()=>{const y=r(),T=h.current;T&&(T.textContent=y)});const l=q.useTheme(),[c,u]=ee.useState(null);ee.useEffect(()=>{o&&_()},[o]);const d=s||c,h=ee.useRef(null);e||(e={color:"#fff",backgroundColor:"#000",borderColor:"#000",buttonBackgroundColor:{disabled:"#000",default:"#000",hovered:"#000",pressed:"#000"},labelColor:"#000"});const p=d?(O=e.buttonBackgroundColor)==null?void 0:O.pressed:e.borderColor,f={width:"55px",color:e.color,path:{fill:e.color},alignContent:"center",fontSize:"37px",svg:{pointerEvents:"none"}},m={...f,backgroundColor:(C=e.buttonBackgroundColor)==null?void 0:C.default,":hover":{backgroundColor:(P=e.buttonBackgroundColor)==null?void 0:P.hovered},":active":{backgroundColor:(w=e.buttonBackgroundColor)==null?void 0:w.pressed,color:e.backgroundColor,path:{fill:e.backgroundColor}},":disabled":{backgroundColor:(R=e.buttonBackgroundColor)==null?void 0:R.disabled,"svg path":{fill:l.palette.action.disabled}}},b={...f,backgroundColor:(I=e.buttonBackgroundColor)==null?void 0:I.pressed,color:e.backgroundColor,path:{fill:e.backgroundColor},":disabled":{backgroundColor:(F=e.buttonBackgroundColor)==null?void 0:F.pressed,"svg path":{fill:l.palette.action.disabled}}};function x(y,T){o||y.button===0&&(u(T),n(T))}function _(){u(null),a()}return S.jsxs(on,{height:"64px",direction:"row",justifyContent:"center",...i,children:[S.jsx(q.IconButton,{disabled:o,disableRipple:!0,onPointerDown:y=>x(y,"-"),onPointerUp:_,onPointerOut:_,size:"large",sx:{...d==="-"?b:m,borderRadius:"16px 0px 0px 16px",borderLeft:`2px solid ${p??"#fff"}`,borderBottom:`2px solid ${p??"#fff"}`,borderTop:`2px solid ${p??"#fff"}`},children:S.jsx(Gw,{})}),S.jsxs(on,{spacing:"6px",sx:{width:"150px",backgroundColor:e.backgroundColor,alignItems:"center",justifyContent:"center",opacity:"0.9",borderBottom:`2px solid ${p??"#fff"}`,borderTop:`2px solid ${p??"#fff"}`},children:[S.jsx(on,{height:"22px",direction:"row",alignItems:"center",justifyItems:"center",spacing:1,sx:{userSelect:"none",color:e.color,".MuiTypography-root":{fontWeight:700,...o?{color:l.palette.action.disabled}:{}},...o?{"svg path":{fill:l.palette.action.disabled}}:{}},children:t}),S.jsx(q.Typography,{height:"22px",sx:{fontSize:"15px",color:o?l.palette.action.disabled:e.color,fontWeight:700},ref:h,children:r()})]}),S.jsx(q.IconButton,{disableRipple:!0,disabled:o,onPointerDown:y=>x(y,"+"),onPointerUp:_,onPointerOut:_,size:"large",sx:{...d==="+"?b:m,borderRadius:"0px 16px 16px 0px",borderRight:`2px solid ${p??"#fff"}`,borderBottom:`2px solid ${p??"#fff"}`,borderTop:`2px solid ${p??"#fff"}`},children:S.jsx(qw,{})})]})})),Ir=a0;function Jw(e){return xa("MuiSvgIcon",e)}Uh("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const Ww=e=>{const{color:t,fontSize:r,classes:n}=e,a={root:["root",t!=="inherit"&&`color${Ze(t)}`,`fontSize${Ze(r)}`]};return wl(a,Jw,n)},Yw=dt("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.color!=="inherit"&&t[`color${Ze(r.color)}`],t[`fontSize${Ze(r.fontSize)}`]]}})(Ir(({theme:e})=>{var t,r,n,a,o,s,i,l,c,u,d,h,p,f;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:(a=(t=e.transitions)==null?void 0:t.create)==null?void 0:a.call(t,"fill",{duration:(n=(r=(e.vars??e).transitions)==null?void 0:r.duration)==null?void 0:n.shorter}),variants:[{props:m=>!m.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:((s=(o=e.typography)==null?void 0:o.pxToRem)==null?void 0:s.call(o,20))||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:((l=(i=e.typography)==null?void 0:i.pxToRem)==null?void 0:l.call(i,24))||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:((u=(c=e.typography)==null?void 0:c.pxToRem)==null?void 0:u.call(c,35))||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,m])=>m&&m.main).map(([m])=>{var b,x;return{props:{color:m},style:{color:(x=(b=(e.vars??e).palette)==null?void 0:b[m])==null?void 0:x.main}}}),{props:{color:"action"},style:{color:(h=(d=(e.vars??e).palette)==null?void 0:d.action)==null?void 0:h.active}},{props:{color:"disabled"},style:{color:(f=(p=(e.vars??e).palette)==null?void 0:p.action)==null?void 0:f.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),zo=V.forwardRef(function(t,r){const n=dc({props:t,name:"MuiSvgIcon"}),{children:a,className:o,color:s="inherit",component:i="svg",fontSize:l="medium",htmlColor:c,inheritViewBox:u=!1,titleAccess:d,viewBox:h="0 0 24 24",...p}=n,f=V.isValidElement(a)&&a.type==="svg",m={...n,color:s,component:i,fontSize:l,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:h,hasSvgAsChild:f},b={};u||(b.viewBox=h);const x=Ww(m);return S.jsxs(Yw,{as:i,className:It(x.root,o),focusable:"false",color:c,"aria-hidden":d?void 0:!0,role:d?"img":void 0,ref:r,...b,...p,...f&&a.props,ownerState:m,children:[f?a.props.children:a,d?S.jsx("title",{children:d}):null]})});process.env.NODE_ENV!=="production"&&(zo.propTypes={children:g.node,classes:g.object,className:g.string,color:g.oneOfType([g.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),g.string]),component:g.elementType,fontSize:g.oneOfType([g.oneOf(["inherit","large","medium","small"]),g.string]),htmlColor:g.string,inheritViewBox:g.bool,shapeRendering:g.string,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),titleAccess:g.string,viewBox:g.string});zo.muiName="SvgIcon";function Aa(e,t){function r(n,a){return S.jsx(zo,{"data-testid":process.env.NODE_ENV!=="production"?`${t}Icon`:void 0,ref:a,...n,children:e})}return process.env.NODE_ENV!=="production"&&(r.displayName=`${t}Icon`),r.muiName=zo.muiName,V.memo(V.forwardRef(r))}function yo(e){return e&&e.ownerDocument||document}function Kw(e){const{controlled:t,default:r,name:n,state:a="value"}=e,{current:o}=V.useRef(t!==void 0),[s,i]=V.useState(r),l=o?t:s;if(process.env.NODE_ENV!=="production"){V.useEffect(()=>{o!==(t!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${a} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(`
|
|
126
|
+
`))},[a,n,t]);const{current:u}=V.useRef(r);V.useEffect(()=>{!o&&!Object.is(u,r)&&console.error([`MUI: A component is changing the default ${a} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(`
|
|
127
|
+
`))},[JSON.stringify(r)])}const c=V.useCallback(u=>{o||i(u)},[]);return[l,c]}function bi(e){const t=V.useRef(e);return Gh(()=>{t.current=e}),V.useRef((...r)=>(0,t.current)(...r)).current}function Cm(...e){const t=V.useRef(void 0),r=V.useCallback(n=>{const a=e.map(o=>{if(o==null)return null;if(typeof o=="function"){const s=o,i=s(n);return typeof i=="function"?i:()=>{s(null)}}return o.current=n,()=>{o.current=null}});return()=>{a.forEach(o=>o==null?void 0:o())}},e);return V.useMemo(()=>e.every(n=>n==null)?null:n=>{t.current&&(t.current(),t.current=void 0),n!=null&&(t.current=r(n))},e)}const Qw=Aa(S.jsx("path",{d:"M15.41 7.41 14 6l-6 6 6 6 1.41-1.41L10.83 12z"}),"ChevronLeft"),Xw=Aa(S.jsx("path",{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}),"ChevronRight");function wr(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Pm=typeof global=="object"&&global&&global.Object===Object&&global,Zw=typeof self=="object"&&self&&self.Object===Object&&self,jt=Pm||Zw||Function("return this")(),vi=function(){return jt.Date.now()},eC=/\s/;function tC(e){for(var t=e.length;t--&&eC.test(e.charAt(t)););return t}var rC=/^\s+/;function nC(e){return e&&e.slice(0,tC(e)+1).replace(rC,"")}var lr=jt.Symbol,Tm=Object.prototype,aC=Tm.hasOwnProperty,oC=Tm.toString,Nn=lr?lr.toStringTag:void 0;function sC(e){var t=aC.call(e,Nn),r=e[Nn];try{e[Nn]=void 0;var n=!0}catch{}var a=oC.call(e);return n&&(t?e[Nn]=r:delete e[Nn]),a}var iC=Object.prototype,lC=iC.toString;function cC(e){return lC.call(e)}var uC="[object Null]",dC="[object Undefined]",cd=lr?lr.toStringTag:void 0;function Mr(e){return e==null?e===void 0?dC:uC:cd&&cd in Object(e)?sC(e):cC(e)}function Cr(e){return e!=null&&typeof e=="object"}var hC="[object Symbol]";function Ts(e){return typeof e=="symbol"||Cr(e)&&Mr(e)==hC}var ud=NaN,pC=/^[-+]0x[0-9a-f]+$/i,mC=/^0b[01]+$/i,fC=/^0o[0-7]+$/i,gC=parseInt;function dd(e){if(typeof e=="number")return e;if(Ts(e))return ud;if(wr(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=wr(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=nC(e);var r=mC.test(e);return r||fC.test(e)?gC(e.slice(2),r?2:8):pC.test(e)?ud:+e}var yC="Expected a function",bC=Math.max,vC=Math.min;function SC(e,t,r){var n,a,o,s,i,l,c=0,u=!1,d=!1,h=!0;if(typeof e!="function")throw new TypeError(yC);t=dd(t)||0,wr(r)&&(u=!!r.leading,d="maxWait"in r,o=d?bC(dd(r.maxWait)||0,t):o,h="trailing"in r?!!r.trailing:h);function p(w){var R=n,I=a;return n=a=void 0,c=w,s=e.apply(I,R),s}function f(w){return c=w,i=setTimeout(x,t),u?p(w):s}function m(w){var R=w-l,I=w-c,F=t-R;return d?vC(F,o-I):F}function b(w){var R=w-l,I=w-c;return l===void 0||R>=t||R<0||d&&I>=o}function x(){var w=vi();if(b(w))return _(w);i=setTimeout(x,m(w))}function _(w){return i=void 0,h&&n?p(w):(n=a=void 0,s)}function O(){i!==void 0&&clearTimeout(i),c=0,n=l=a=i=void 0}function C(){return i===void 0?s:_(vi())}function P(){var w=vi(),R=b(w);if(n=arguments,a=this,l=w,R){if(i===void 0)return f(l);if(d)return clearTimeout(i),i=setTimeout(x,t),p(l)}return i===void 0&&(i=setTimeout(x,t)),s}return P.cancel=O,P.flush=C,P}var xC="Expected a function";function OC(e,t,r){var n=!0,a=!0;if(typeof e!="function")throw new TypeError(xC);return wr(r)&&(n="leading"in r?!!r.leading:n,a="trailing"in r?!!r.trailing:a),SC(e,t,{leading:n,maxWait:t,trailing:a})}const Rm=Ct(Ee.observer(({startJogging:e,stopJogging:t,lowerLimitDegs:r,upperLimitDegs:n,getValueDegs:a,disabled:o,...s})=>{var O,C,P,w,R,I,F,y,T,z,E,B,te,Z,ae;const{t:i}=_e.useTranslation(),[l,c]=ee.useState(),u=q.useTheme(),d={background:(O=u.palette.backgroundPaperElevation)==null?void 0:O[4],color:(C=u.palette.backgroundPaperElevation)==null?void 0:C[11]},h=Ee.useLocalObservable(()=>({activeJoggingDir:null,startJogging(re){this.activeJoggingDir=re,e(re)},stopJogging(){this.activeJoggingDir=null,t()}})),p=OC(()=>{c(a())},50);xn(p);function f(re){re.button===0&&h.startJogging("-")}function m(re){re.button===0&&h.startJogging("+")}function b(re){h.stopJogging()}function x(re){h.stopJogging()}function _(re,le=1){if(re===void 0||isNaN(re))return"";const J=i("General.degree.variable",{amount:re.toFixed(le)});return re>0&&le===0?`+${J}`:J}return S.jsxs(on,{height:"64px",width:"100%",maxWidth:"260px",direction:"row",...s,sx:{"& .MuiIconButton-root":{width:"52px",color:u.palette.text.primary,alignContent:"center",backgroundColor:(P=u.palette.backgroundPaperElevation)==null?void 0:P[11],"& svg":{width:"42px",height:"42px"},"&.Mui-disabled":{backgroundColor:(w=u.palette.backgroundPaperElevation)==null?void 0:w[11],color:u.palette.action.disabled,opacity:1},"&:hover":{backgroundColor:(R=u.palette.backgroundPaperElevation)==null?void 0:R[9]},"&:active":{...d}}},children:[S.jsx(q.IconButton,{onPointerDown:f,onPointerUp:b,onPointerOut:x,disabled:o,disableRipple:!0,sx:{borderRadius:"16px 0px 0px 16px",...h.activeJoggingDir==="-"?d:{}},children:S.jsx(Qw,{sx:{pointerEvents:"none",color:(T=(y=(F=(I=u.componentsExt)==null?void 0:I.JoggingPanel)==null?void 0:F.JoggingJoint)==null?void 0:y.Joint)==null?void 0:T.arrowColor}})}),S.jsxs(on,{flexGrow:1,alignItems:"center",justifyContent:"center",sx:{borderStyle:"solid",borderLeftWidth:0,borderRightWidth:0,border:"none",backgroundColor:(z=u.palette.backgroundPaperElevation)==null?void 0:z[11],paddingLeft:"20px",paddingRight:"20px",zIndex:1},children:[S.jsx(q.Typography,{sx:{fontSize:"15px",fontWeight:700,position:"relative",top:"5px",color:o?u.palette.action.disabled:u.palette.text.primary},children:_(l)}),S.jsx(q.Slider,{disabled:!0,"aria-label":"Joint position",min:r,max:n,value:l||0,track:!1,sx:{"& .MuiSlider-mark":{display:"none"},"& .MuiSlider-thumb":{width:"5px",height:"12px",borderRadius:"2px",color:o?u.palette.action.disabled:u.palette.text.primary},"& .MuiSlider-markLabel":{top:"20px",fontSize:"12px",color:o?u.palette.action.disabled:u.palette.text.secondary},"& .MuiSlider-rail":{backgroundColor:(E=u.palette.backgroundPaperElevation)==null?void 0:E[5],opacity:1}},marks:r!==void 0&&n!==void 0&&[{value:r,label:_(r,0)},{value:n,label:_(n,0)}]})]}),S.jsx(q.IconButton,{onPointerDown:m,onPointerUp:b,onPointerOut:x,disabled:o,disableRipple:!0,sx:{borderRadius:"0px 16px 16px 0px",...h.activeJoggingDir==="+"?d:{}},children:S.jsx(Xw,{sx:{pointerEvents:"none",color:(ae=(Z=(te=(B=u.componentsExt)==null?void 0:B.JoggingPanel)==null?void 0:te.JoggingJoint)==null?void 0:Z.Joint)==null?void 0:ae.arrowColor}})})]})})),wC=Aa(S.jsx("path",{d:"M10 9h4V6h3l-5-5-5 5h3zm-1 1H6V7l-5 5 5 5v-3h3zm14 2-5-5v3h-3v4h3v3zm-9 3h-4v3H7l5 5 5-5h-3z"}),"OpenWith"),CC=Aa(S.jsx("path",{d:"M18 16.08c-.76 0-1.44.3-1.96.77L8.91 12.7c.05-.23.09-.46.09-.7s-.04-.47-.09-.7l7.05-4.11c.54.5 1.25.81 2.04.81 1.66 0 3-1.34 3-3s-1.34-3-3-3-3 1.34-3 3c0 .24.04.47.09.7L8.04 9.81C7.5 9.31 6.79 9 6 9c-1.66 0-3 1.34-3 3s1.34 3 3 3c.79 0 1.5-.31 2.04-.81l7.12 4.16c-.05.21-.08.43-.08.65 0 1.61 1.31 2.92 2.92 2.92s2.92-1.31 2.92-2.92-1.31-2.92-2.92-2.92"}),"Share");function PC(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Am=PC;function TC(){this.__data__=[],this.size=0}var RC=TC;function AC(e,t){return e===t||e!==e&&t!==t}var _m=AC;function _C(e,t){for(var r=e.length;r--;)if(_m(e[r][0],t))return r;return-1}var Rs=_C,EC=Array.prototype,VC=EC.splice;function IC(e){var t=this.__data__,r=Rs(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():VC.call(t,r,1),--this.size,!0}var MC=IC;function $C(e){var t=this.__data__,r=Rs(t,e);return r<0?void 0:t[r][1]}var jC=$C;function kC(e){return Rs(this.__data__,e)>-1}var UC=kC;function LC(e,t){var r=this.__data__,n=Rs(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}var DC=LC;function On(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}On.prototype.clear=RC;On.prototype.delete=MC;On.prototype.get=jC;On.prototype.has=UC;On.prototype.set=DC;var As=On;function NC(){this.__data__=new As,this.size=0}var BC=NC;function FC(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}var zC=FC;function GC(e){return this.__data__.get(e)}var HC=GC;function qC(e){return this.__data__.has(e)}var JC=qC,WC=typeof global=="object"&&global&&global.Object===Object&&global,Em=WC,YC=typeof self=="object"&&self&&self.Object===Object&&self,KC=Em||YC||Function("return this")(),Wt=KC,QC=Wt.Symbol,yn=QC,Vm=Object.prototype,XC=Vm.hasOwnProperty,ZC=Vm.toString,Bn=yn?yn.toStringTag:void 0;function eP(e){var t=XC.call(e,Bn),r=e[Bn];try{e[Bn]=void 0;var n=!0}catch{}var a=ZC.call(e);return n&&(t?e[Bn]=r:delete e[Bn]),a}var tP=eP,rP=Object.prototype,nP=rP.toString;function aP(e){return nP.call(e)}var oP=aP,sP="[object Null]",iP="[object Undefined]",hd=yn?yn.toStringTag:void 0;function lP(e){return e==null?e===void 0?iP:sP:hd&&hd in Object(e)?tP(e):oP(e)}var _a=lP,cP="[object AsyncFunction]",uP="[object Function]",dP="[object GeneratorFunction]",hP="[object Proxy]";function pP(e){if(!Am(e))return!1;var t=_a(e);return t==uP||t==dP||t==cP||t==hP}var Im=pP,mP=Wt["__core-js_shared__"],Si=mP,pd=function(){var e=/[^.]+$/.exec(Si&&Si.keys&&Si.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function fP(e){return!!pd&&pd in e}var gP=fP,yP=Function.prototype,bP=yP.toString;function vP(e){if(e!=null){try{return bP.call(e)}catch{}try{return e+""}catch{}}return""}var $r=vP,SP=/[\\^$.*+?()[\]{}|]/g,xP=/^\[object .+?Constructor\]$/,OP=Function.prototype,wP=Object.prototype,CP=OP.toString,PP=wP.hasOwnProperty,TP=RegExp("^"+CP.call(PP).replace(SP,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function RP(e){if(!Am(e)||gP(e))return!1;var t=Im(e)?TP:xP;return t.test($r(e))}var AP=RP;function _P(e,t){return e==null?void 0:e[t]}var EP=_P;function VP(e,t){var r=EP(e,t);return AP(r)?r:void 0}var wn=VP,IP=wn(Wt,"Map"),pa=IP,MP=wn(Object,"create"),ma=MP;function $P(){this.__data__=ma?ma(null):{},this.size=0}var jP=$P;function kP(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var UP=kP,LP="__lodash_hash_undefined__",DP=Object.prototype,NP=DP.hasOwnProperty;function BP(e){var t=this.__data__;if(ma){var r=t[e];return r===LP?void 0:r}return NP.call(t,e)?t[e]:void 0}var FP=BP,zP=Object.prototype,GP=zP.hasOwnProperty;function HP(e){var t=this.__data__;return ma?t[e]!==void 0:GP.call(t,e)}var qP=HP,JP="__lodash_hash_undefined__";function WP(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=ma&&t===void 0?JP:t,this}var YP=WP;function Cn(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Cn.prototype.clear=jP;Cn.prototype.delete=UP;Cn.prototype.get=FP;Cn.prototype.has=qP;Cn.prototype.set=YP;var md=Cn;function KP(){this.size=0,this.__data__={hash:new md,map:new(pa||As),string:new md}}var QP=KP;function XP(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var ZP=XP;function eT(e,t){var r=e.__data__;return ZP(t)?r[typeof t=="string"?"string":"hash"]:r.map}var _s=eT;function tT(e){var t=_s(this,e).delete(e);return this.size-=t?1:0,t}var rT=tT;function nT(e){return _s(this,e).get(e)}var aT=nT;function oT(e){return _s(this,e).has(e)}var sT=oT;function iT(e,t){var r=_s(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}var lT=iT;function Pn(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Pn.prototype.clear=QP;Pn.prototype.delete=rT;Pn.prototype.get=aT;Pn.prototype.has=sT;Pn.prototype.set=lT;var Mm=Pn,cT=200;function uT(e,t){var r=this.__data__;if(r instanceof As){var n=r.__data__;if(!pa||n.length<cT-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new Mm(n)}return r.set(e,t),this.size=r.size,this}var dT=uT;function Tn(e){var t=this.__data__=new As(e);this.size=t.size}Tn.prototype.clear=BC;Tn.prototype.delete=zC;Tn.prototype.get=HC;Tn.prototype.has=JC;Tn.prototype.set=dT;var xi=Tn,hT="__lodash_hash_undefined__";function pT(e){return this.__data__.set(e,hT),this}var mT=pT;function fT(e){return this.__data__.has(e)}var gT=fT;function Go(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new Mm;++t<r;)this.add(e[t])}Go.prototype.add=Go.prototype.push=mT;Go.prototype.has=gT;var yT=Go;function bT(e,t){for(var r=-1,n=e==null?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}var vT=bT;function ST(e,t){return e.has(t)}var xT=ST,OT=1,wT=2;function CT(e,t,r,n,a,o){var s=r&OT,i=e.length,l=t.length;if(i!=l&&!(s&&l>i))return!1;var c=o.get(e),u=o.get(t);if(c&&u)return c==t&&u==e;var d=-1,h=!0,p=r&wT?new yT:void 0;for(o.set(e,t),o.set(t,e);++d<i;){var f=e[d],m=t[d];if(n)var b=s?n(m,f,d,t,e,o):n(f,m,d,e,t,o);if(b!==void 0){if(b)continue;h=!1;break}if(p){if(!vT(t,function(x,_){if(!xT(p,_)&&(f===x||a(f,x,r,n,o)))return p.push(_)})){h=!1;break}}else if(!(f===m||a(f,m,r,n,o))){h=!1;break}}return o.delete(e),o.delete(t),h}var $m=CT,PT=Wt.Uint8Array,fd=PT;function TT(e){var t=-1,r=Array(e.size);return e.forEach(function(n,a){r[++t]=[a,n]}),r}var RT=TT;function AT(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var _T=AT,ET=1,VT=2,IT="[object Boolean]",MT="[object Date]",$T="[object Error]",jT="[object Map]",kT="[object Number]",UT="[object RegExp]",LT="[object Set]",DT="[object String]",NT="[object Symbol]",BT="[object ArrayBuffer]",FT="[object DataView]",gd=yn?yn.prototype:void 0,Oi=gd?gd.valueOf:void 0;function zT(e,t,r,n,a,o,s){switch(r){case FT:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case BT:return!(e.byteLength!=t.byteLength||!o(new fd(e),new fd(t)));case IT:case MT:case kT:return _m(+e,+t);case $T:return e.name==t.name&&e.message==t.message;case UT:case DT:return e==t+"";case jT:var i=RT;case LT:var l=n&ET;if(i||(i=_T),e.size!=t.size&&!l)return!1;var c=s.get(e);if(c)return c==t;n|=VT,s.set(e,t);var u=$m(i(e),i(t),n,a,o,s);return s.delete(e),u;case NT:if(Oi)return Oi.call(e)==Oi.call(t)}return!1}var GT=zT;function HT(e,t){for(var r=-1,n=t.length,a=e.length;++r<n;)e[a+r]=t[r];return e}var qT=HT,JT=Array.isArray,Ho=JT;function WT(e,t,r){var n=t(e);return Ho(e)?n:qT(n,r(e))}var YT=WT;function KT(e,t){for(var r=-1,n=e==null?0:e.length,a=0,o=[];++r<n;){var s=e[r];t(s,r,e)&&(o[a++]=s)}return o}var QT=KT;function XT(){return[]}var ZT=XT,eR=Object.prototype,tR=eR.propertyIsEnumerable,yd=Object.getOwnPropertySymbols,rR=yd?function(e){return e==null?[]:(e=Object(e),QT(yd(e),function(t){return tR.call(e,t)}))}:ZT,nR=rR;function aR(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var oR=aR;function sR(e){return e!=null&&typeof e=="object"}var fa=sR,iR="[object Arguments]";function lR(e){return fa(e)&&_a(e)==iR}var bd=lR,jm=Object.prototype,cR=jm.hasOwnProperty,uR=jm.propertyIsEnumerable,dR=bd(function(){return arguments}())?bd:function(e){return fa(e)&&cR.call(e,"callee")&&!uR.call(e,"callee")},hR=dR;function pR(){return!1}var mR=pR,km=typeof exports=="object"&&exports&&!exports.nodeType&&exports,vd=km&&typeof module=="object"&&module&&!module.nodeType&&module,fR=vd&&vd.exports===km,Sd=fR?Wt.Buffer:void 0,gR=Sd?Sd.isBuffer:void 0,yR=gR||mR,Zi=yR,bR=9007199254740991,vR=/^(?:0|[1-9]\d*)$/;function SR(e,t){var r=typeof e;return t=t??bR,!!t&&(r=="number"||r!="symbol"&&vR.test(e))&&e>-1&&e%1==0&&e<t}var xR=SR,OR=9007199254740991;function wR(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=OR}var Um=wR,CR="[object Arguments]",PR="[object Array]",TR="[object Boolean]",RR="[object Date]",AR="[object Error]",_R="[object Function]",ER="[object Map]",VR="[object Number]",IR="[object Object]",MR="[object RegExp]",$R="[object Set]",jR="[object String]",kR="[object WeakMap]",UR="[object ArrayBuffer]",LR="[object DataView]",DR="[object Float32Array]",NR="[object Float64Array]",BR="[object Int8Array]",FR="[object Int16Array]",zR="[object Int32Array]",GR="[object Uint8Array]",HR="[object Uint8ClampedArray]",qR="[object Uint16Array]",JR="[object Uint32Array]",Te={};Te[DR]=Te[NR]=Te[BR]=Te[FR]=Te[zR]=Te[GR]=Te[HR]=Te[qR]=Te[JR]=!0;Te[CR]=Te[PR]=Te[UR]=Te[TR]=Te[LR]=Te[RR]=Te[AR]=Te[_R]=Te[ER]=Te[VR]=Te[IR]=Te[MR]=Te[$R]=Te[jR]=Te[kR]=!1;function WR(e){return fa(e)&&Um(e.length)&&!!Te[_a(e)]}var YR=WR;function KR(e){return function(t){return e(t)}}var QR=KR,Lm=typeof exports=="object"&&exports&&!exports.nodeType&&exports,ta=Lm&&typeof module=="object"&&module&&!module.nodeType&&module,XR=ta&&ta.exports===Lm,wi=XR&&Em.process,ZR=function(){try{var e=ta&&ta.require&&ta.require("util").types;return e||wi&&wi.binding&&wi.binding("util")}catch{}}(),xd=ZR,Od=xd&&xd.isTypedArray,eA=Od?QR(Od):YR,Dm=eA,tA=Object.prototype,rA=tA.hasOwnProperty;function nA(e,t){var r=Ho(e),n=!r&&hR(e),a=!r&&!n&&Zi(e),o=!r&&!n&&!a&&Dm(e),s=r||n||a||o,i=s?oR(e.length,String):[],l=i.length;for(var c in e)(t||rA.call(e,c))&&!(s&&(c=="length"||a&&(c=="offset"||c=="parent")||o&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||xR(c,l)))&&i.push(c);return i}var aA=nA,oA=Object.prototype;function sA(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||oA;return e===r}var iA=sA;function lA(e,t){return function(r){return e(t(r))}}var cA=lA,uA=cA(Object.keys,Object),dA=uA,hA=Object.prototype,pA=hA.hasOwnProperty;function mA(e){if(!iA(e))return dA(e);var t=[];for(var r in Object(e))pA.call(e,r)&&r!="constructor"&&t.push(r);return t}var fA=mA;function gA(e){return e!=null&&Um(e.length)&&!Im(e)}var yA=gA;function bA(e){return yA(e)?aA(e):fA(e)}var vA=bA;function SA(e){return YT(e,vA,nR)}var wd=SA,xA=1,OA=Object.prototype,wA=OA.hasOwnProperty;function CA(e,t,r,n,a,o){var s=r&xA,i=wd(e),l=i.length,c=wd(t),u=c.length;if(l!=u&&!s)return!1;for(var d=l;d--;){var h=i[d];if(!(s?h in t:wA.call(t,h)))return!1}var p=o.get(e),f=o.get(t);if(p&&f)return p==t&&f==e;var m=!0;o.set(e,t),o.set(t,e);for(var b=s;++d<l;){h=i[d];var x=e[h],_=t[h];if(n)var O=s?n(_,x,h,t,e,o):n(x,_,h,e,t,o);if(!(O===void 0?x===_||a(x,_,r,n,o):O)){m=!1;break}b||(b=h=="constructor")}if(m&&!b){var C=e.constructor,P=t.constructor;C!=P&&"constructor"in e&&"constructor"in t&&!(typeof C=="function"&&C instanceof C&&typeof P=="function"&&P instanceof P)&&(m=!1)}return o.delete(e),o.delete(t),m}var PA=CA,TA=wn(Wt,"DataView"),el=TA,RA=wn(Wt,"Promise"),tl=RA,AA=wn(Wt,"Set"),rl=AA,_A=wn(Wt,"WeakMap"),nl=_A,Cd="[object Map]",EA="[object Object]",Pd="[object Promise]",Td="[object Set]",Rd="[object WeakMap]",Ad="[object DataView]",VA=$r(el),IA=$r(pa),MA=$r(tl),$A=$r(rl),jA=$r(nl),mr=_a;(el&&mr(new el(new ArrayBuffer(1)))!=Ad||pa&&mr(new pa)!=Cd||tl&&mr(tl.resolve())!=Pd||rl&&mr(new rl)!=Td||nl&&mr(new nl)!=Rd)&&(mr=function(e){var t=_a(e),r=t==EA?e.constructor:void 0,n=r?$r(r):"";if(n)switch(n){case VA:return Ad;case IA:return Cd;case MA:return Pd;case $A:return Td;case jA:return Rd}return t});var _d=mr,kA=1,Ed="[object Arguments]",Vd="[object Array]",Xa="[object Object]",UA=Object.prototype,Id=UA.hasOwnProperty;function LA(e,t,r,n,a,o){var s=Ho(e),i=Ho(t),l=s?Vd:_d(e),c=i?Vd:_d(t);l=l==Ed?Xa:l,c=c==Ed?Xa:c;var u=l==Xa,d=c==Xa,h=l==c;if(h&&Zi(e)){if(!Zi(t))return!1;s=!0,u=!1}if(h&&!u)return o||(o=new xi),s||Dm(e)?$m(e,t,r,n,a,o):GT(e,t,l,r,n,a,o);if(!(r&kA)){var p=u&&Id.call(e,"__wrapped__"),f=d&&Id.call(t,"__wrapped__");if(p||f){var m=p?e.value():e,b=f?t.value():t;return o||(o=new xi),a(m,b,r,n,o)}}return h?(o||(o=new xi),PA(e,t,r,n,a,o)):!1}var DA=LA;function Nm(e,t,r,n,a){return e===t?!0:e==null||t==null||!fa(e)&&!fa(t)?e!==e&&t!==t:DA(e,t,r,n,Nm,a)}var NA=Nm;function BA(e,t){return NA(e,t)}var FA=BA;/*! *****************************************************************************
|
|
128
128
|
Copyright (c) Microsoft Corporation. All rights reserved.
|
|
129
129
|
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
|
130
130
|
this file except in compliance with the License. You may obtain a copy of the
|
|
@@ -137,19 +137,19 @@ MERCHANTABLITY OR NON-INFRINGEMENT.
|
|
|
137
137
|
|
|
138
138
|
See the Apache Version 2.0 License for specific language governing permissions
|
|
139
139
|
and limitations under the License.
|
|
140
|
-
***************************************************************************** */var al=function(e,t){return al=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,n){r.__proto__=n}||function(r,n){for(var a in n)n.hasOwnProperty(a)&&(r[a]=n[a])},al(e,t)};function Bm(e,t){al(e,t);function r(){this.constructor=e}e.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}function
|
|
140
|
+
***************************************************************************** */var al=function(e,t){return al=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,n){r.__proto__=n}||function(r,n){for(var a in n)n.hasOwnProperty(a)&&(r[a]=n[a])},al(e,t)};function Bm(e,t){al(e,t);function r(){this.constructor=e}e.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}function zA(e){var t=typeof Symbol=="function"&&e[Symbol.iterator],r=0;return t?t.call(e):{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}}}function GA(e,t){var r=typeof Symbol=="function"&&e[Symbol.iterator];if(!r)return e;var n=r.call(e),a,o=[],s;try{for(;(t===void 0||t-- >0)&&!(a=n.next()).done;)o.push(a.value)}catch(i){s={error:i}}finally{try{a&&!a.done&&(r=n.return)&&r.call(n)}finally{if(s)throw s.error}}return o}function HA(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(GA(arguments[t]));return e}var Fm=function(){function e(t,r){this.target=r,this.type=t}return e}(),qA=function(e){Bm(t,e);function t(r,n){var a=e.call(this,"error",n)||this;return a.message=r.message,a.error=r,a}return t}(Fm),JA=function(e){Bm(t,e);function t(r,n,a){r===void 0&&(r=1e3),n===void 0&&(n="");var o=e.call(this,"close",a)||this;return o.wasClean=!0,o.code=r,o.reason=n,o}return t}(Fm);/*!
|
|
141
141
|
* Reconnecting WebSocket
|
|
142
142
|
* by Pedro Ladaria <pedro.ladaria@gmail.com>
|
|
143
143
|
* https://github.com/pladaria/reconnecting-websocket
|
|
144
144
|
* License MIT
|
|
145
|
-
*/var qR=function(){if(typeof WebSocket<"u")return WebSocket},JR=function(e){return typeof e<"u"&&!!e&&e.CLOSING===2},hr={maxReconnectionDelay:1e4,minReconnectionDelay:1e3+Math.random()*4e3,minUptime:5e3,reconnectionDelayGrowFactor:1.3,connectionTimeout:4e3,maxRetries:1/0,maxEnqueuedMessages:1/0},WR=function(){function e(t,r,n){var a=this;n===void 0&&(n={}),this._listeners={error:[],message:[],open:[],close:[]},this._retryCount=-1,this._shouldReconnect=!0,this._connectLock=!1,this._binaryType="blob",this._closeCalled=!1,this._messageQueue=[],this.onclose=null,this.onerror=null,this.onmessage=null,this.onopen=null,this._handleOpen=function(o){a._debug("open event");var s=a._options.minUptime,i=s===void 0?hr.minUptime:s;clearTimeout(a._connectTimeout),a._uptimeTimeout=setTimeout(function(){return a._acceptOpen()},i),a._ws.binaryType=a._binaryType,a._messageQueue.forEach(function(l){return a._ws.send(l)}),a._messageQueue=[],a.onopen&&a.onopen(o),a._listeners.open.forEach(function(l){return a._callEventListener(o,l)})},this._handleMessage=function(o){a._debug("message event"),a.onmessage&&a.onmessage(o),a._listeners.message.forEach(function(s){return a._callEventListener(o,s)})},this._handleError=function(o){a._debug("error event",o.message),a._disconnect(void 0,o.message==="TIMEOUT"?"timeout":void 0),a.onerror&&a.onerror(o),a._debug("exec error listeners"),a._listeners.error.forEach(function(s){return a._callEventListener(o,s)}),a._connect()},this._handleClose=function(o){a._debug("close event"),a._clearTimeouts(),a._shouldReconnect&&a._connect(),a.onclose&&a.onclose(o),a._listeners.close.forEach(function(s){return a._callEventListener(o,s)})},this._url=t,this._protocols=r,this._options=n,this._options.startClosed&&(this._shouldReconnect=!1),this._connect()}return Object.defineProperty(e,"CONNECTING",{get:function(){return 0},enumerable:!0,configurable:!0}),Object.defineProperty(e,"OPEN",{get:function(){return 1},enumerable:!0,configurable:!0}),Object.defineProperty(e,"CLOSING",{get:function(){return 2},enumerable:!0,configurable:!0}),Object.defineProperty(e,"CLOSED",{get:function(){return 3},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"CONNECTING",{get:function(){return e.CONNECTING},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"OPEN",{get:function(){return e.OPEN},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"CLOSING",{get:function(){return e.CLOSING},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"CLOSED",{get:function(){return e.CLOSED},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"binaryType",{get:function(){return this._ws?this._ws.binaryType:this._binaryType},set:function(t){this._binaryType=t,this._ws&&(this._ws.binaryType=t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"retryCount",{get:function(){return Math.max(this._retryCount,0)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"bufferedAmount",{get:function(){var t=this._messageQueue.reduce(function(r,n){return typeof n=="string"?r+=n.length:n instanceof Blob?r+=n.size:r+=n.byteLength,r},0);return t+(this._ws?this._ws.bufferedAmount:0)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"extensions",{get:function(){return this._ws?this._ws.extensions:""},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"protocol",{get:function(){return this._ws?this._ws.protocol:""},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"readyState",{get:function(){return this._ws?this._ws.readyState:this._options.startClosed?e.CLOSED:e.CONNECTING},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"url",{get:function(){return this._ws?this._ws.url:""},enumerable:!0,configurable:!0}),e.prototype.close=function(t,r){if(t===void 0&&(t=1e3),this._closeCalled=!0,this._shouldReconnect=!1,this._clearTimeouts(),!this._ws){this._debug("close enqueued: no ws instance");return}if(this._ws.readyState===this.CLOSED){this._debug("close: already closed");return}this._ws.close(t,r)},e.prototype.reconnect=function(t,r){this._shouldReconnect=!0,this._closeCalled=!1,this._retryCount=-1,!this._ws||this._ws.readyState===this.CLOSED?this._connect():(this._disconnect(t,r),this._connect())},e.prototype.send=function(t){if(this._ws&&this._ws.readyState===this.OPEN)this._debug("send",t),this._ws.send(t);else{var r=this._options.maxEnqueuedMessages,n=r===void 0?hr.maxEnqueuedMessages:r;this._messageQueue.length<n&&(this._debug("enqueue",t),this._messageQueue.push(t))}},e.prototype.addEventListener=function(t,r){this._listeners[t]&&this._listeners[t].push(r)},e.prototype.dispatchEvent=function(t){var r,n,a=this._listeners[t.type];if(a)try{for(var o=NR(a),s=o.next();!s.done;s=o.next()){var i=s.value;this._callEventListener(t,i)}}catch(l){r={error:l}}finally{try{s&&!s.done&&(n=o.return)&&n.call(o)}finally{if(r)throw r.error}}return!0},e.prototype.removeEventListener=function(t,r){this._listeners[t]&&(this._listeners[t]=this._listeners[t].filter(function(n){return n!==r}))},e.prototype._debug=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];this._options.debug&&console.log.apply(console,zR(["RWS>"],t))},e.prototype._getNextDelay=function(){var t=this._options,r=t.reconnectionDelayGrowFactor,n=r===void 0?hr.reconnectionDelayGrowFactor:r,a=t.minReconnectionDelay,o=a===void 0?hr.minReconnectionDelay:a,s=t.maxReconnectionDelay,i=s===void 0?hr.maxReconnectionDelay:s,l=0;return this._retryCount>0&&(l=o*Math.pow(n,this._retryCount-1),l>i&&(l=i)),this._debug("next delay",l),l},e.prototype._wait=function(){var t=this;return new Promise(function(r){setTimeout(r,t._getNextDelay())})},e.prototype._getNextUrl=function(t){if(typeof t=="string")return Promise.resolve(t);if(typeof t=="function"){var r=t();if(typeof r=="string")return Promise.resolve(r);if(r.then)return r}throw Error("Invalid URL")},e.prototype._connect=function(){var t=this;if(!(this._connectLock||!this._shouldReconnect)){this._connectLock=!0;var r=this._options,n=r.maxRetries,a=n===void 0?hr.maxRetries:n,o=r.connectionTimeout,s=o===void 0?hr.connectionTimeout:o,i=r.WebSocket,l=i===void 0?qR():i;if(this._retryCount>=a){this._debug("max retries reached",this._retryCount,">=",a);return}if(this._retryCount++,this._debug("connect",this._retryCount),this._removeListeners(),!JR(l))throw Error("No valid WebSocket class provided");this._wait().then(function(){return t._getNextUrl(t._url)}).then(function(c){t._closeCalled||(t._debug("connect",{url:c,protocols:t._protocols}),t._ws=t._protocols?new l(c,t._protocols):new l(c),t._ws.binaryType=t._binaryType,t._connectLock=!1,t._addListeners(),t._connectTimeout=setTimeout(function(){return t._handleTimeout()},s))})}},e.prototype._handleTimeout=function(){this._debug("timeout event"),this._handleError(new GR(Error("TIMEOUT"),this))},e.prototype._disconnect=function(t,r){if(t===void 0&&(t=1e3),this._clearTimeouts(),!!this._ws){this._removeListeners();try{this._ws.close(t,r),this._handleClose(new HR(t,r,this))}catch{}}},e.prototype._acceptOpen=function(){this._debug("accept open"),this._retryCount=0},e.prototype._callEventListener=function(t,r){"handleEvent"in r?r.handleEvent(t):r(t)},e.prototype._removeListeners=function(){this._ws&&(this._debug("removeListeners"),this._ws.removeEventListener("open",this._handleOpen),this._ws.removeEventListener("close",this._handleClose),this._ws.removeEventListener("message",this._handleMessage),this._ws.removeEventListener("error",this._handleError))},e.prototype._addListeners=function(){this._ws&&(this._debug("addListeners"),this._ws.addEventListener("open",this._handleOpen),this._ws.addEventListener("close",this._handleClose),this._ws.addEventListener("message",this._handleMessage),this._ws.addEventListener("error",this._handleError))},e.prototype._clearTimeouts=function(){clearTimeout(this._connectTimeout),clearTimeout(this._uptimeTimeout)},e}(),YR=Object.defineProperty,KR=Object.defineProperties,QR=Object.getOwnPropertyDescriptors,Id=Object.getOwnPropertySymbols,XR=Object.prototype.hasOwnProperty,ZR=Object.prototype.propertyIsEnumerable,Md=(e,t,r)=>t in e?YR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,rn=(e,t)=>{for(var r in t||(t={}))XR.call(t,r)&&Md(e,r,t[r]);if(Id)for(var r of Id(t))ZR.call(t,r)&&Md(e,r,t[r]);return e},ol=(e,t)=>KR(e,QR(t)),Re=(e,t,r)=>new Promise((n,a)=>{var o=l=>{try{i(r.next(l))}catch(c){a(c)}},s=l=>{try{i(r.throw(l))}catch(c){a(c)}},i=l=>l.done?n(l.value):Promise.resolve(l.value).then(o,s);i((r=r.apply(e,t)).next())}),eV=class extends WR{constructor(e,t={}){console.log("Opening websocket to",e),super(()=>this.targetUrl||e,void 0,{startClosed:!0}),this.opts=t,this.disposed=!1,Object.defineProperty(this,"url",{get(){return this.targetUrl}}),this.targetUrl=e,this.addEventListener("open",()=>{console.log(`Websocket to ${this.url} opened`)}),this.addEventListener("message",n=>{this.receivedFirstMessage||(this.receivedFirstMessage=n)}),this.addEventListener("close",()=>{console.log(`Websocket to ${this.url} closed`)});const r=this.reconnect;this.reconnect=()=>{this.opts.mock?this.opts.mock.handleWebsocketConnection(this):r.apply(this)},this.reconnect()}changeUrl(e){this.receivedFirstMessage=void 0,this.targetUrl=e,this.reconnect()}sendJson(e){this.opts.mock?this.opts.mock.handleWebsocketMessage(this,JSON.stringify(e)):this.send(JSON.stringify(e))}dispose(){this.close(),this.disposed=!0,this.opts.onDispose&&this.opts.onDispose()}opened(){return Re(this,null,function*(){return new Promise((e,t)=>{this.readyState===WebSocket.OPEN?e():(this.addEventListener("open",()=>e()),this.addEventListener("error",t))})})}closed(){return Re(this,null,function*(){return new Promise((e,t)=>{this.readyState===WebSocket.CLOSED?e():(this.addEventListener("close",()=>e()),this.addEventListener("error",t))})})}firstMessage(){return Re(this,null,function*(){return this.receivedFirstMessage?this.receivedFirstMessage:new Promise((e,t)=>{const r=a=>{this.receivedFirstMessage=a,this.removeEventListener("message",r),this.removeEventListener("error",n),e(a)},n=a=>{this.removeEventListener("message",r),this.removeEventListener("error",n),t(a)};this.addEventListener("message",r),this.addEventListener("error",n)})})}nextMessage(){return Re(this,null,function*(){return new Promise((e,t)=>{const r=a=>{this.removeEventListener("message",r),this.removeEventListener("error",n),e(a)},n=a=>{this.removeEventListener("message",r),this.removeEventListener("error",n),t(a)};this.addEventListener("message",r),this.addEventListener("error",n)})})}},tV=class{constructor(){this.available=typeof window<"u"&&!!window.localStorage}getJSON(e){if(!this.available)return null;const t=window.localStorage.getItem(e);if(t===null)return null;try{return JSON.parse(t)}catch{return null}}setJSON(e,t){if(!this.available)return null;window.localStorage.setItem(e,JSON.stringify(t))}delete(e){if(!this.available)return null;window.localStorage.removeItem(e)}setString(e,t){if(!this.available)return null;window.localStorage.setItem(e,t)}getString(e){return this.available?window.localStorage.getItem(e):null}},Ci=new tV;function nr(e){try{return JSON.parse(e)}catch{return}}function rV(e,t){return e||(e="world"),t||(t="world"),e===t}var sn="wandelbots.io",Pi={dev:{domain:`https://auth.portal.dev.${sn}`,clientId:"fLbJD0RLp5r2Dpucm5j8BjwMR6Hunfha"},stg:{domain:`https://auth.portal.stg.${sn}`,clientId:"joVDeD9e786WzFNSGCqoVq7HNkWt5j6s"},prod:{domain:`https://auth.portal.${sn}`,clientId:"J7WJUi38xVQdJAEBNRT9Xw1b0fXDb4J2"}},nV=e=>{if(e.includes(`dev.${sn}`))return Pi.dev;if(e.includes(`stg.${sn}`))return Pi.stg;if(e.includes(sn))return Pi.prod;throw new Error("Unsupported instance URL. Cannot determine Auth0 configuration.")},aV=e=>Re(void 0,null,function*(){var t;if(typeof window>"u")throw new Error("Access token must be set to use NovaClient when not in a browser environment.");const r=nV(e);if(new URL(e).origin===window.location.origin)throw window.location.reload(),new Error("Failed to reload page to get auth details, please refresh manually");const{Auth0Client:n}=yield Promise.resolve().then(()=>require("./auth0-spa-js.production.esm-BLRAk7Yh.cjs")),a=new n({domain:r.domain,clientId:(t=r.clientId)!=null?t:"",useRefreshTokens:!1,authorizationParams:{audience:"nova-api",redirect_uri:window.location.origin}});if(window.location.search.includes("code=")&&window.location.search.includes("state=")){const{appState:s}=yield a.handleRedirectCallback();window.history.replaceState({},document.title,(s==null?void 0:s.returnTo)||window.location.pathname)}else yield a.loginWithRedirect();return yield a.getTokenSilently()});function Fm(e,t){return function(){return e.apply(t,arguments)}}const{toString:oV}=Object.prototype,{getPrototypeOf:hc}=Object,_s=(e=>t=>{const r=oV.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),Ct=e=>(e=e.toLowerCase(),t=>_s(t)===e),Es=e=>t=>typeof t===e,{isArray:An}=Array,ga=Es("undefined");function sV(e){return e!==null&&!ga(e)&&e.constructor!==null&&!ga(e.constructor)&&ut(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const zm=Ct("ArrayBuffer");function iV(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&zm(e.buffer),t}const lV=Es("string"),ut=Es("function"),Gm=Es("number"),Is=e=>e!==null&&typeof e=="object",cV=e=>e===!0||e===!1,yo=e=>{if(_s(e)!=="object")return!1;const t=hc(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},uV=Ct("Date"),dV=Ct("File"),hV=Ct("Blob"),pV=Ct("FileList"),mV=e=>Is(e)&&ut(e.pipe),fV=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||ut(e.append)&&((t=_s(e))==="formdata"||t==="object"&&ut(e.toString)&&e.toString()==="[object FormData]"))},gV=Ct("URLSearchParams"),[yV,bV,vV,SV]=["ReadableStream","Request","Response","Headers"].map(Ct),xV=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Va(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let n,a;if(typeof e!="object"&&(e=[e]),An(e))for(n=0,a=e.length;n<a;n++)t.call(null,e[n],n,e);else{const o=r?Object.getOwnPropertyNames(e):Object.keys(e),s=o.length;let i;for(n=0;n<s;n++)i=o[n],t.call(null,e[i],i,e)}}function Hm(e,t){t=t.toLowerCase();const r=Object.keys(e);let n=r.length,a;for(;n-- >0;)if(a=r[n],t===a.toLowerCase())return a;return null}const yr=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,qm=e=>!ga(e)&&e!==yr;function sl(){const{caseless:e}=qm(this)&&this||{},t={},r=(n,a)=>{const o=e&&Hm(t,a)||a;yo(t[o])&&yo(n)?t[o]=sl(t[o],n):yo(n)?t[o]=sl({},n):An(n)?t[o]=n.slice():t[o]=n};for(let n=0,a=arguments.length;n<a;n++)arguments[n]&&Va(arguments[n],r);return t}const OV=(e,t,r,{allOwnKeys:n}={})=>(Va(t,(a,o)=>{r&&ut(a)?e[o]=Fm(a,r):e[o]=a},{allOwnKeys:n}),e),wV=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),CV=(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},PV=(e,t,r,n)=>{let a,o,s;const i={};if(t=t||{},e==null)return t;do{for(a=Object.getOwnPropertyNames(e),o=a.length;o-- >0;)s=a[o],(!n||n(s,e,t))&&!i[s]&&(t[s]=e[s],i[s]=!0);e=r!==!1&&hc(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},TV=(e,t,r)=>{e=String(e),(r===void 0||r>e.length)&&(r=e.length),r-=t.length;const n=e.indexOf(t,r);return n!==-1&&n===r},AV=e=>{if(!e)return null;if(An(e))return e;let t=e.length;if(!Gm(t))return null;const r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},RV=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&hc(Uint8Array)),VV=(e,t)=>{const n=(e&&e[Symbol.iterator]).call(e);let a;for(;(a=n.next())&&!a.done;){const o=a.value;t.call(e,o[0],o[1])}},_V=(e,t)=>{let r;const n=[];for(;(r=e.exec(t))!==null;)n.push(r);return n},EV=Ct("HTMLFormElement"),IV=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,a){return n.toUpperCase()+a}),$d=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),MV=Ct("RegExp"),Jm=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),n={};Va(r,(a,o)=>{let s;(s=t(a,o,e))!==!1&&(n[o]=s||a)}),Object.defineProperties(e,n)},$V=e=>{Jm(e,(t,r)=>{if(ut(e)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const n=e[r];if(ut(n)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},jV=(e,t)=>{const r={},n=a=>{a.forEach(o=>{r[o]=!0})};return An(e)?n(e):n(String(e).split(t)),r},kV=()=>{},UV=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function LV(e){return!!(e&&ut(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const DV=e=>{const t=new Array(10),r=(n,a)=>{if(Is(n)){if(t.indexOf(n)>=0)return;if(!("toJSON"in n)){t[a]=n;const o=An(n)?[]:{};return Va(n,(s,i)=>{const l=r(s,a+1);!ga(l)&&(o[i]=l)}),t[a]=void 0,o}}return n};return r(e,0)},BV=Ct("AsyncFunction"),NV=e=>e&&(Is(e)||ut(e))&&ut(e.then)&&ut(e.catch),Wm=((e,t)=>e?setImmediate:t?((r,n)=>(yr.addEventListener("message",({source:a,data:o})=>{a===yr&&o===r&&n.length&&n.shift()()},!1),a=>{n.push(a),yr.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",ut(yr.postMessage)),FV=typeof queueMicrotask<"u"?queueMicrotask.bind(yr):typeof process<"u"&&process.nextTick||Wm,G={isArray:An,isArrayBuffer:zm,isBuffer:sV,isFormData:fV,isArrayBufferView:iV,isString:lV,isNumber:Gm,isBoolean:cV,isObject:Is,isPlainObject:yo,isReadableStream:yV,isRequest:bV,isResponse:vV,isHeaders:SV,isUndefined:ga,isDate:uV,isFile:dV,isBlob:hV,isRegExp:MV,isFunction:ut,isStream:mV,isURLSearchParams:gV,isTypedArray:RV,isFileList:pV,forEach:Va,merge:sl,extend:OV,trim:xV,stripBOM:wV,inherits:CV,toFlatObject:PV,kindOf:_s,kindOfTest:Ct,endsWith:TV,toArray:AV,forEachEntry:VV,matchAll:_V,isHTMLForm:EV,hasOwnProperty:$d,hasOwnProp:$d,reduceDescriptors:Jm,freezeMethods:$V,toObjectSet:jV,toCamelCase:IV,noop:kV,toFiniteNumber:UV,findKey:Hm,global:yr,isContextDefined:qm,isSpecCompliantForm:LV,toJSONObject:DV,isAsyncFn:BV,isThenable:NV,setImmediate:Wm,asap:FV};function de(e,t,r,n,a){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),a&&(this.response=a,this.status=a.status?a.status:null)}G.inherits(de,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:G.toJSONObject(this.config),code:this.code,status:this.status}}});const Ym=de.prototype,Km={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{Km[e]={value:e}});Object.defineProperties(de,Km);Object.defineProperty(Ym,"isAxiosError",{value:!0});de.from=(e,t,r,n,a,o)=>{const s=Object.create(Ym);return G.toFlatObject(e,s,function(l){return l!==Error.prototype},i=>i!=="isAxiosError"),de.call(s,e.message,t,r,n,a),s.cause=e,s.name=e.name,o&&Object.assign(s,o),s};const zV=null;function il(e){return G.isPlainObject(e)||G.isArray(e)}function Qm(e){return G.endsWith(e,"[]")?e.slice(0,-2):e}function jd(e,t,r){return e?e.concat(t).map(function(a,o){return a=Qm(a),!r&&o?"["+a+"]":a}).join(r?".":""):t}function GV(e){return G.isArray(e)&&!e.some(il)}const HV=G.toFlatObject(G,{},null,function(t){return/^is[A-Z]/.test(t)});function Ms(e,t,r){if(!G.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,r=G.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(m,b){return!G.isUndefined(b[m])});const n=r.metaTokens,a=r.visitor||u,o=r.dots,s=r.indexes,l=(r.Blob||typeof Blob<"u"&&Blob)&&G.isSpecCompliantForm(t);if(!G.isFunction(a))throw new TypeError("visitor must be a function");function c(f){if(f===null)return"";if(G.isDate(f))return f.toISOString();if(!l&&G.isBlob(f))throw new de("Blob is not supported. Use a Buffer instead.");return G.isArrayBuffer(f)||G.isTypedArray(f)?l&&typeof Blob=="function"?new Blob([f]):Buffer.from(f):f}function u(f,m,b){let x=f;if(f&&!b&&typeof f=="object"){if(G.endsWith(m,"{}"))m=n?m:m.slice(0,-2),f=JSON.stringify(f);else if(G.isArray(f)&&GV(f)||(G.isFileList(f)||G.endsWith(m,"[]"))&&(x=G.toArray(f)))return m=Qm(m),x.forEach(function(O,C){!(G.isUndefined(O)||O===null)&&t.append(s===!0?jd([m],C,o):s===null?m:m+"[]",c(O))}),!1}return il(f)?!0:(t.append(jd(b,m,o),c(f)),!1)}const d=[],h=Object.assign(HV,{defaultVisitor:u,convertValue:c,isVisitable:il});function p(f,m){if(!G.isUndefined(f)){if(d.indexOf(f)!==-1)throw Error("Circular reference detected in "+m.join("."));d.push(f),G.forEach(f,function(x,V){(!(G.isUndefined(x)||x===null)&&a.call(t,x,G.isString(V)?V.trim():V,m,h))===!0&&p(x,m?m.concat(V):[V])}),d.pop()}}if(!G.isObject(e))throw new TypeError("data must be an object");return p(e),t}function kd(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(n){return t[n]})}function pc(e,t){this._pairs=[],e&&Ms(e,this,t)}const Xm=pc.prototype;Xm.append=function(t,r){this._pairs.push([t,r])};Xm.toString=function(t){const r=t?function(n){return t.call(this,n,kd)}:kd;return this._pairs.map(function(a){return r(a[0])+"="+r(a[1])},"").join("&")};function qV(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Zm(e,t,r){if(!t)return e;const n=r&&r.encode||qV;G.isFunction(r)&&(r={serialize:r});const a=r&&r.serialize;let o;if(a?o=a(t,r):o=G.isURLSearchParams(t)?t.toString():new pc(t,r).toString(n),o){const s=e.indexOf("#");s!==-1&&(e=e.slice(0,s)),e+=(e.indexOf("?")===-1?"?":"&")+o}return e}class Ud{constructor(){this.handlers=[]}use(t,r,n){return this.handlers.push({fulfilled:t,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){G.forEach(this.handlers,function(n){n!==null&&t(n)})}}const ef={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},JV=typeof URLSearchParams<"u"?URLSearchParams:pc,WV=typeof FormData<"u"?FormData:null,YV=typeof Blob<"u"?Blob:null,KV={isBrowser:!0,classes:{URLSearchParams:JV,FormData:WV,Blob:YV},protocols:["http","https","file","blob","url","data"]},mc=typeof window<"u"&&typeof document<"u",ll=typeof navigator=="object"&&navigator||void 0,QV=mc&&(!ll||["ReactNative","NativeScript","NS"].indexOf(ll.product)<0),XV=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",ZV=mc&&window.location.href||"http://localhost",e_=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:mc,hasStandardBrowserEnv:QV,hasStandardBrowserWebWorkerEnv:XV,navigator:ll,origin:ZV},Symbol.toStringTag,{value:"Module"})),Qe={...e_,...KV};function t_(e,t){return Ms(e,new Qe.classes.URLSearchParams,Object.assign({visitor:function(r,n,a,o){return Qe.isNode&&G.isBuffer(r)?(this.append(n,r.toString("base64")),!1):o.defaultVisitor.apply(this,arguments)}},t))}function r_(e){return G.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function n_(e){const t={},r=Object.keys(e);let n;const a=r.length;let o;for(n=0;n<a;n++)o=r[n],t[o]=e[o];return t}function tf(e){function t(r,n,a,o){let s=r[o++];if(s==="__proto__")return!0;const i=Number.isFinite(+s),l=o>=r.length;return s=!s&&G.isArray(a)?a.length:s,l?(G.hasOwnProp(a,s)?a[s]=[a[s],n]:a[s]=n,!i):((!a[s]||!G.isObject(a[s]))&&(a[s]=[]),t(r,n,a[s],o)&&G.isArray(a[s])&&(a[s]=n_(a[s])),!i)}if(G.isFormData(e)&&G.isFunction(e.entries)){const r={};return G.forEachEntry(e,(n,a)=>{t(r_(n),a,r,0)}),r}return null}function a_(e,t,r){if(G.isString(e))try{return(t||JSON.parse)(e),G.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(e)}const _a={transitional:ef,adapter:["xhr","http","fetch"],transformRequest:[function(t,r){const n=r.getContentType()||"",a=n.indexOf("application/json")>-1,o=G.isObject(t);if(o&&G.isHTMLForm(t)&&(t=new FormData(t)),G.isFormData(t))return a?JSON.stringify(tf(t)):t;if(G.isArrayBuffer(t)||G.isBuffer(t)||G.isStream(t)||G.isFile(t)||G.isBlob(t)||G.isReadableStream(t))return t;if(G.isArrayBufferView(t))return t.buffer;if(G.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let i;if(o){if(n.indexOf("application/x-www-form-urlencoded")>-1)return t_(t,this.formSerializer).toString();if((i=G.isFileList(t))||n.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return Ms(i?{"files[]":t}:t,l&&new l,this.formSerializer)}}return o||a?(r.setContentType("application/json",!1),a_(t)):t}],transformResponse:[function(t){const r=this.transitional||_a.transitional,n=r&&r.forcedJSONParsing,a=this.responseType==="json";if(G.isResponse(t)||G.isReadableStream(t))return t;if(t&&G.isString(t)&&(n&&!this.responseType||a)){const s=!(r&&r.silentJSONParsing)&&a;try{return JSON.parse(t)}catch(i){if(s)throw i.name==="SyntaxError"?de.from(i,de.ERR_BAD_RESPONSE,this,null,this.response):i}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Qe.classes.FormData,Blob:Qe.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};G.forEach(["delete","get","head","post","put","patch"],e=>{_a.headers[e]={}});const o_=G.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),s_=e=>{const t={};let r,n,a;return e&&e.split(`
|
|
146
|
-
`).forEach(function(s){a=s.indexOf(":"),r=s.substring(0,a).trim().toLowerCase(),n=s.substring(a+1).trim(),!(!r||t[r]&&
|
|
147
|
-
`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...r){const n=new this(t);return r.forEach(a=>n.set(a)),n}static accessor(t){const n=(this[Ld]=this[Ld]={accessors:{}}).accessors,a=this.prototype;function o(s){const i=Fn(s);n[i]||(u_(a,s),n[i]=!0)}return G.isArray(t)?t.forEach(o):o(t),this}};st.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);G.reduceDescriptors(st.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(n){this[r]=n}}});G.freezeMethods(st);function Ai(e,t){const r=this||_a,n=t||r,a=st.from(n.headers);let o=n.data;return G.forEach(e,function(i){o=i.call(r,o,a.normalize(),t?t.status:void 0)}),a.normalize(),o}function rf(e){return!!(e&&e.__CANCEL__)}function Rn(e,t,r){de.call(this,e??"canceled",de.ERR_CANCELED,t,r),this.name="CanceledError"}G.inherits(Rn,de,{__CANCEL__:!0});function nf(e,t,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?e(r):t(new de("Request failed with status code "+r.status,[de.ERR_BAD_REQUEST,de.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}function d_(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function h_(e,t){e=e||10;const r=new Array(e),n=new Array(e);let a=0,o=0,s;return t=t!==void 0?t:1e3,function(l){const c=Date.now(),u=n[o];s||(s=c),r[a]=l,n[a]=c;let d=o,h=0;for(;d!==a;)h+=r[d++],d=d%e;if(a=(a+1)%e,a===o&&(o=(o+1)%e),c-s<t)return;const p=u&&c-u;return p?Math.round(h*1e3/p):void 0}}function p_(e,t){let r=0,n=1e3/t,a,o;const s=(c,u=Date.now())=>{r=u,a=null,o&&(clearTimeout(o),o=null),e.apply(null,c)};return[(...c)=>{const u=Date.now(),d=u-r;d>=n?s(c,u):(a=c,o||(o=setTimeout(()=>{o=null,s(a)},n-d)))},()=>a&&s(a)]}const Ho=(e,t,r=3)=>{let n=0;const a=h_(50,250);return p_(o=>{const s=o.loaded,i=o.lengthComputable?o.total:void 0,l=s-n,c=a(l),u=s<=i;n=s;const d={loaded:s,total:i,progress:i?s/i:void 0,bytes:l,rate:c||void 0,estimated:c&&i&&u?(i-s)/c:void 0,event:o,lengthComputable:i!=null,[t?"download":"upload"]:!0};e(d)},r)},Dd=(e,t)=>{const r=e!=null;return[n=>t[0]({lengthComputable:r,total:e,loaded:n}),t[1]]},Bd=e=>(...t)=>G.asap(()=>e(...t)),m_=Qe.hasStandardBrowserEnv?((e,t)=>r=>(r=new URL(r,Qe.origin),e.protocol===r.protocol&&e.host===r.host&&(t||e.port===r.port)))(new URL(Qe.origin),Qe.navigator&&/(msie|trident)/i.test(Qe.navigator.userAgent)):()=>!0,f_=Qe.hasStandardBrowserEnv?{write(e,t,r,n,a,o){const s=[e+"="+encodeURIComponent(t)];G.isNumber(r)&&s.push("expires="+new Date(r).toGMTString()),G.isString(n)&&s.push("path="+n),G.isString(a)&&s.push("domain="+a),o===!0&&s.push("secure"),document.cookie=s.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function g_(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function y_(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function af(e,t,r){let n=!g_(t);return e&&n||r==!1?y_(e,t):t}const Nd=e=>e instanceof st?{...e}:e;function Pr(e,t){t=t||{};const r={};function n(c,u,d,h){return G.isPlainObject(c)&&G.isPlainObject(u)?G.merge.call({caseless:h},c,u):G.isPlainObject(u)?G.merge({},u):G.isArray(u)?u.slice():u}function a(c,u,d,h){if(G.isUndefined(u)){if(!G.isUndefined(c))return n(void 0,c,d,h)}else return n(c,u,d,h)}function o(c,u){if(!G.isUndefined(u))return n(void 0,u)}function s(c,u){if(G.isUndefined(u)){if(!G.isUndefined(c))return n(void 0,c)}else return n(void 0,u)}function i(c,u,d){if(d in t)return n(c,u);if(d in e)return n(void 0,c)}const l={url:o,method:o,data:o,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:i,headers:(c,u,d)=>a(Nd(c),Nd(u),d,!0)};return G.forEach(Object.keys(Object.assign({},e,t)),function(u){const d=l[u]||a,h=d(e[u],t[u],u);G.isUndefined(h)&&d!==i||(r[u]=h)}),r}const of=e=>{const t=Pr({},e);let{data:r,withXSRFToken:n,xsrfHeaderName:a,xsrfCookieName:o,headers:s,auth:i}=t;t.headers=s=st.from(s),t.url=Zm(af(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),i&&s.set("Authorization","Basic "+btoa((i.username||"")+":"+(i.password?unescape(encodeURIComponent(i.password)):"")));let l;if(G.isFormData(r)){if(Qe.hasStandardBrowserEnv||Qe.hasStandardBrowserWebWorkerEnv)s.setContentType(void 0);else if((l=s.getContentType())!==!1){const[c,...u]=l?l.split(";").map(d=>d.trim()).filter(Boolean):[];s.setContentType([c||"multipart/form-data",...u].join("; "))}}if(Qe.hasStandardBrowserEnv&&(n&&G.isFunction(n)&&(n=n(t)),n||n!==!1&&m_(t.url))){const c=a&&o&&f_.read(o);c&&s.set(a,c)}return t},b_=typeof XMLHttpRequest<"u",v_=b_&&function(e){return new Promise(function(r,n){const a=of(e);let o=a.data;const s=st.from(a.headers).normalize();let{responseType:i,onUploadProgress:l,onDownloadProgress:c}=a,u,d,h,p,f;function m(){p&&p(),f&&f(),a.cancelToken&&a.cancelToken.unsubscribe(u),a.signal&&a.signal.removeEventListener("abort",u)}let b=new XMLHttpRequest;b.open(a.method.toUpperCase(),a.url,!0),b.timeout=a.timeout;function x(){if(!b)return;const O=st.from("getAllResponseHeaders"in b&&b.getAllResponseHeaders()),P={data:!i||i==="text"||i==="json"?b.responseText:b.response,status:b.status,statusText:b.statusText,headers:O,config:e,request:b};nf(function(A){r(A),m()},function(A){n(A),m()},P),b=null}"onloadend"in b?b.onloadend=x:b.onreadystatechange=function(){!b||b.readyState!==4||b.status===0&&!(b.responseURL&&b.responseURL.indexOf("file:")===0)||setTimeout(x)},b.onabort=function(){b&&(n(new de("Request aborted",de.ECONNABORTED,e,b)),b=null)},b.onerror=function(){n(new de("Network Error",de.ERR_NETWORK,e,b)),b=null},b.ontimeout=function(){let C=a.timeout?"timeout of "+a.timeout+"ms exceeded":"timeout exceeded";const P=a.transitional||ef;a.timeoutErrorMessage&&(C=a.timeoutErrorMessage),n(new de(C,P.clarifyTimeoutError?de.ETIMEDOUT:de.ECONNABORTED,e,b)),b=null},o===void 0&&s.setContentType(null),"setRequestHeader"in b&&G.forEach(s.toJSON(),function(C,P){b.setRequestHeader(P,C)}),G.isUndefined(a.withCredentials)||(b.withCredentials=!!a.withCredentials),i&&i!=="json"&&(b.responseType=a.responseType),c&&([h,f]=Ho(c,!0),b.addEventListener("progress",h)),l&&b.upload&&([d,p]=Ho(l),b.upload.addEventListener("progress",d),b.upload.addEventListener("loadend",p)),(a.cancelToken||a.signal)&&(u=O=>{b&&(n(!O||O.type?new Rn(null,e,b):O),b.abort(),b=null)},a.cancelToken&&a.cancelToken.subscribe(u),a.signal&&(a.signal.aborted?u():a.signal.addEventListener("abort",u)));const V=d_(a.url);if(V&&Qe.protocols.indexOf(V)===-1){n(new de("Unsupported protocol "+V+":",de.ERR_BAD_REQUEST,e));return}b.send(o||null)})},S_=(e,t)=>{const{length:r}=e=e?e.filter(Boolean):[];if(t||r){let n=new AbortController,a;const o=function(c){if(!a){a=!0,i();const u=c instanceof Error?c:this.reason;n.abort(u instanceof de?u:new Rn(u instanceof Error?u.message:u))}};let s=t&&setTimeout(()=>{s=null,o(new de(`timeout ${t} of ms exceeded`,de.ETIMEDOUT))},t);const i=()=>{e&&(s&&clearTimeout(s),s=null,e.forEach(c=>{c.unsubscribe?c.unsubscribe(o):c.removeEventListener("abort",o)}),e=null)};e.forEach(c=>c.addEventListener("abort",o));const{signal:l}=n;return l.unsubscribe=()=>G.asap(i),l}},x_=function*(e,t){let r=e.byteLength;if(r<t){yield e;return}let n=0,a;for(;n<r;)a=n+t,yield e.slice(n,a),n=a},O_=async function*(e,t){for await(const r of w_(e))yield*x_(r,t)},w_=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:r,value:n}=await t.read();if(r)break;yield n}}finally{await t.cancel()}},Fd=(e,t,r,n)=>{const a=O_(e,t);let o=0,s,i=l=>{s||(s=!0,n&&n(l))};return new ReadableStream({async pull(l){try{const{done:c,value:u}=await a.next();if(c){i(),l.close();return}let d=u.byteLength;if(r){let h=o+=d;r(h)}l.enqueue(new Uint8Array(u))}catch(c){throw i(c),c}},cancel(l){return i(l),a.return()}},{highWaterMark:2})},$s=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",sf=$s&&typeof ReadableStream=="function",C_=$s&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),lf=(e,...t)=>{try{return!!e(...t)}catch{return!1}},P_=sf&&lf(()=>{let e=!1;const t=new Request(Qe.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),zd=64*1024,cl=sf&&lf(()=>G.isReadableStream(new Response("").body)),qo={stream:cl&&(e=>e.body)};$s&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!qo[t]&&(qo[t]=G.isFunction(e[t])?r=>r[t]():(r,n)=>{throw new de(`Response type '${t}' is not supported`,de.ERR_NOT_SUPPORT,n)})})})(new Response);const T_=async e=>{if(e==null)return 0;if(G.isBlob(e))return e.size;if(G.isSpecCompliantForm(e))return(await new Request(Qe.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(G.isArrayBufferView(e)||G.isArrayBuffer(e))return e.byteLength;if(G.isURLSearchParams(e)&&(e=e+""),G.isString(e))return(await C_(e)).byteLength},A_=async(e,t)=>{const r=G.toFiniteNumber(e.getContentLength());return r??T_(t)},R_=$s&&(async e=>{let{url:t,method:r,data:n,signal:a,cancelToken:o,timeout:s,onDownloadProgress:i,onUploadProgress:l,responseType:c,headers:u,withCredentials:d="same-origin",fetchOptions:h}=of(e);c=c?(c+"").toLowerCase():"text";let p=S_([a,o&&o.toAbortSignal()],s),f;const m=p&&p.unsubscribe&&(()=>{p.unsubscribe()});let b;try{if(l&&P_&&r!=="get"&&r!=="head"&&(b=await A_(u,n))!==0){let P=new Request(t,{method:"POST",body:n,duplex:"half"}),w;if(G.isFormData(n)&&(w=P.headers.get("content-type"))&&u.setContentType(w),P.body){const[A,E]=Dd(b,Ho(Bd(l)));n=Fd(P.body,zd,A,E)}}G.isString(d)||(d=d?"include":"omit");const x="credentials"in Request.prototype;f=new Request(t,{...h,signal:p,method:r.toUpperCase(),headers:u.normalize().toJSON(),body:n,duplex:"half",credentials:x?d:void 0});let V=await fetch(f);const O=cl&&(c==="stream"||c==="response");if(cl&&(i||O&&m)){const P={};["status","statusText","headers"].forEach(F=>{P[F]=V[F]});const w=G.toFiniteNumber(V.headers.get("content-length")),[A,E]=i&&Dd(w,Ho(Bd(i),!0))||[];V=new Response(Fd(V.body,zd,A,()=>{E&&E(),m&&m()}),P)}c=c||"text";let C=await qo[G.findKey(qo,c)||"text"](V,e);return!O&&m&&m(),await new Promise((P,w)=>{nf(P,w,{data:C,headers:st.from(V.headers),status:V.status,statusText:V.statusText,config:e,request:f})})}catch(x){throw m&&m(),x&&x.name==="TypeError"&&/fetch/i.test(x.message)?Object.assign(new de("Network Error",de.ERR_NETWORK,e,f),{cause:x.cause||x}):de.from(x,x&&x.code,e,f)}}),ul={http:zV,xhr:v_,fetch:R_};G.forEach(ul,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const Gd=e=>`- ${e}`,V_=e=>G.isFunction(e)||e===null||e===!1,cf={getAdapter:e=>{e=G.isArray(e)?e:[e];const{length:t}=e;let r,n;const a={};for(let o=0;o<t;o++){r=e[o];let s;if(n=r,!V_(r)&&(n=ul[(s=String(r)).toLowerCase()],n===void 0))throw new de(`Unknown adapter '${s}'`);if(n)break;a[s||"#"+o]=n}if(!n){const o=Object.entries(a).map(([i,l])=>`adapter ${i} `+(l===!1?"is not supported by the environment":"is not available in the build"));let s=t?o.length>1?`since :
|
|
148
|
-
`+o.map(
|
|
149
|
-
`):" "+
|
|
150
|
-
`+o):n.stack=o}catch{}}throw n}}_request(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=Pr(this.defaults,r);const{transitional:n,paramsSerializer:a,headers:o}=r;n!==void 0&&vo.assertOptions(n,{silentJSONParsing:At.transitional(At.boolean),forcedJSONParsing:At.transitional(At.boolean),clarifyTimeoutError:At.transitional(At.boolean)},!1),a!=null&&(G.isFunction(a)?r.paramsSerializer={serialize:a}:vo.assertOptions(a,{encode:At.function,serialize:At.function},!0)),r.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?r.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:r.allowAbsoluteUrls=!0),vo.assertOptions(r,{baseUrl:At.spelling("baseURL"),withXsrfToken:At.spelling("withXSRFToken")},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let s=o&&G.merge(o.common,o[r.method]);o&&G.forEach(["delete","get","head","post","put","patch","common"],f=>{delete o[f]}),r.headers=st.concat(s,o);const i=[];let l=!0;this.interceptors.request.forEach(function(m){typeof m.runWhen=="function"&&m.runWhen(r)===!1||(l=l&&m.synchronous,i.unshift(m.fulfilled,m.rejected))});const c=[];this.interceptors.response.forEach(function(m){c.push(m.fulfilled,m.rejected)});let u,d=0,h;if(!l){const f=[Hd.bind(this),void 0];for(f.unshift.apply(f,i),f.push.apply(f,c),h=f.length,u=Promise.resolve(r);d<h;)u=u.then(f[d++],f[d++]);return u}h=i.length;let p=r;for(d=0;d<h;){const f=i[d++],m=i[d++];try{p=f(p)}catch(b){m.call(this,b);break}}try{u=Hd.call(this,p)}catch(f){return Promise.reject(f)}for(d=0,h=c.length;d<h;)u=u.then(c[d++],c[d++]);return u}getUri(t){t=Pr(this.defaults,t);const r=af(t.baseURL,t.url,t.allowAbsoluteUrls);return Zm(r,t.params,t.paramsSerializer)}};G.forEach(["delete","get","head","options"],function(t){Sr.prototype[t]=function(r,n){return this.request(Pr(n||{},{method:t,url:r,data:(n||{}).data}))}});G.forEach(["post","put","patch"],function(t){function r(n){return function(o,s,i){return this.request(Pr(i||{},{method:t,headers:n?{"Content-Type":"multipart/form-data"}:{},url:o,data:s}))}}Sr.prototype[t]=r(),Sr.prototype[t+"Form"]=r(!0)});let E_=class df{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(o){r=o});const n=this;this.promise.then(a=>{if(!n._listeners)return;let o=n._listeners.length;for(;o-- >0;)n._listeners[o](a);n._listeners=null}),this.promise.then=a=>{let o;const s=new Promise(i=>{n.subscribe(i),o=i}).then(a);return s.cancel=function(){n.unsubscribe(o)},s},t(function(o,s,i){n.reason||(n.reason=new Rn(o,s,i),r(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const r=this._listeners.indexOf(t);r!==-1&&this._listeners.splice(r,1)}toAbortSignal(){const t=new AbortController,r=n=>{t.abort(n)};return this.subscribe(r),t.signal.unsubscribe=()=>this.unsubscribe(r),t.signal}static source(){let t;return{token:new df(function(a){t=a}),cancel:t}}};function I_(e){return function(r){return e.apply(null,r)}}function M_(e){return G.isObject(e)&&e.isAxiosError===!0}const dl={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(dl).forEach(([e,t])=>{dl[t]=e});function hf(e){const t=new Sr(e),r=Fm(Sr.prototype.request,t);return G.extend(r,Sr.prototype,t,{allOwnKeys:!0}),G.extend(r,t,null,{allOwnKeys:!0}),r.create=function(a){return hf(Pr(e,a))},r}const R=hf(_a);R.Axios=Sr;R.CanceledError=Rn;R.CancelToken=E_;R.isCancel=rf;R.VERSION=uf;R.toFormData=Ms;R.AxiosError=de;R.Cancel=R.CanceledError;R.all=function(t){return Promise.all(t)};R.spread=I_;R.isAxiosError=M_;R.mergeConfig=Pr;R.AxiosHeaders=st;R.formToJSON=e=>tf(G.isHTMLForm(e)?new FormData(e):e);R.getAdapter=cf.getAdapter;R.HttpStatusCode=dl;R.default=R;const{Axios:W3,AxiosError:hl,CanceledError:Y3,isCancel:K3,CancelToken:Q3,VERSION:X3,all:Z3,Cancel:e$,isAxiosError:$_,spread:t$,toFormData:r$,AxiosHeaders:n$,HttpStatusCode:a$,formToJSON:o$,getAdapter:s$,mergeConfig:i$}=R,I="/api/v1".replace(/\/+$/,"");class Ve{constructor(t,r=I,n=R){_n(this,"basePath");_n(this,"axios");_n(this,"configuration");this.basePath=r,this.axios=n,t&&(this.configuration=t,this.basePath=t.basePath??r)}}class j_ extends Error{constructor(r,n){super(n);_n(this,"field");this.field=r,this.name="RequiredError"}}const M={},$="https://example.com",v=function(e,t,r){if(r==null)throw new j_(t,`Required parameter ${t} was null or undefined when calling ${e}.`)},j=function(e,t){t&&(t.username||t.password)&&(e.auth={username:t.username,password:t.password})},k=async function(e,t){if(t&&t.accessToken){const r=typeof t.accessToken=="function"?await t.accessToken():await t.accessToken;e.Authorization="Bearer "+r}};function pl(e,t,r=""){t!=null&&(typeof t=="object"?Array.isArray(t)?t.forEach(n=>pl(e,n,r)):Object.keys(t).forEach(n=>pl(e,t[n],`${r}${r!==""?".":""}${n}`)):e.has(r)?e.append(r,t):e.set(r,t))}const U=function(e,...t){const r=new URLSearchParams(e.search);pl(r,t),e.search=r.toString()},ue=function(e,t,r){const n=typeof e!="string";return(n&&r&&r.isJsonMime?r.isJsonMime(t.headers["Content-Type"]):n)?JSON.stringify(e!==void 0?e:{}):e||""},L=function(e){return e.pathname+e.search+e.hash},D=function(e,t,r,n){return(a=t,o=r)=>{const s={...e.options,url:(a.defaults.baseURL?"":(n==null?void 0:n.basePath)??o)+e.url};return a.request(s)}},k_=function(e){return{addApp:async(t,r,n,a={})=>{v("addApp","cell",t),v("addApp","app",r);const o="/cells/{cell}/apps".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.completionTimeout=n),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(r,l,e),{url:L(s),options:l}},clearApps:async(t,r,n={})=>{v("clearApps","cell",t);const a="/cells/{cell}/apps".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),r!==void 0&&(c.completionTimeout=r),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},deleteApp:async(t,r,n,a={})=>{v("deleteApp","cell",t),v("deleteApp","app",r);const o="/cells/{cell}/apps/{app}".replace("{cell}",encodeURIComponent(String(t))).replace("{app}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"DELETE",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.completionTimeout=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},getApp:async(t,r,n={})=>{v("getApp","cell",t),v("getApp","app",r);const a="/cells/{cell}/apps/{app}".replace("{cell}",encodeURIComponent(String(t))).replace("{app}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listApps:async(t,r={})=>{v("listApps","cell",t);const n="/cells/{cell}/apps".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},updateApp:async(t,r,n,a,o={})=>{v("updateApp","cell",t),v("updateApp","app",r),v("updateApp","app2",n);const s="/cells/{cell}/apps/{app}".replace("{cell}",encodeURIComponent(String(t))).replace("{app}",encodeURIComponent(String(r))),i=new URL(s,$);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={};j(c,e),await k(u,e),a!==void 0&&(d.completionTimeout=a),u["Content-Type"]="application/json",U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},c.data=ue(n,c,e),{url:L(i),options:c}}}},qr=function(e){const t=k_(e);return{async addApp(r,n,a,o){var c,u;const s=await t.addApp(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["ApplicationApi.addApp"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async clearApps(r,n,a){var l,c;const o=await t.clearApps(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ApplicationApi.clearApps"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async deleteApp(r,n,a,o){var c,u;const s=await t.deleteApp(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["ApplicationApi.deleteApp"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async getApp(r,n,a){var l,c;const o=await t.getApp(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ApplicationApi.getApp"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listApps(r,n){var i,l;const a=await t.listApps(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["ApplicationApi.listApps"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async updateApp(r,n,a,o,s){var u,d;const i=await t.updateApp(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=M["ApplicationApi.updateApp"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>D(i,R,I,e)(h,c||p)}}};class Jd extends Ve{addApp(t,r,n,a){return qr(this.configuration).addApp(t,r,n,a).then(o=>o(this.axios,this.basePath))}clearApps(t,r,n){return qr(this.configuration).clearApps(t,r,n).then(a=>a(this.axios,this.basePath))}deleteApp(t,r,n,a){return qr(this.configuration).deleteApp(t,r,n,a).then(o=>o(this.axios,this.basePath))}getApp(t,r,n){return qr(this.configuration).getApp(t,r,n).then(a=>a(this.axios,this.basePath))}listApps(t,r){return qr(this.configuration).listApps(t,r).then(n=>n(this.axios,this.basePath))}updateApp(t,r,n,a,o){return qr(this.configuration).updateApp(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}}const U_=function(e){return{deleteCell:async(t,r,n={})=>{v("deleteCell","cell",t);const a="/cells/{cell}".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),r!==void 0&&(c.completionTimeout=r),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},deployCell:async(t,r,n={})=>{v("deployCell","cell",t);const a="/cells",o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};j(i,e),await k(l,e),r!==void 0&&(c.completionTimeout=r),l["Content-Type"]="application/json",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(t,i,e),{url:L(o),options:i}},getCell:async(t,r={})=>{v("getCell","cell",t);const n="/cells/{cell}".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},getCellStatus:async(t,r={})=>{v("getCellStatus","cell",t);const n="/cells/{cell}/status".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},listCells:async(t={})=>{const r="/cells",n=new URL(r,$);let a;e&&(a=e.baseOptions);const o={method:"GET",...a,...t},s={},i={};j(o,e),await k(s,e),U(n,i);let l=a&&a.headers?a.headers:{};return o.headers={...s,...l,...t.headers},{url:L(n),options:o}},updateCell:async(t,r,n,a={})=>{v("updateCell","cell",t),v("updateCell","cell2",r);const o="/cells/{cell}".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.completionTimeout=n),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(r,l,e),{url:L(s),options:l}}}},Jr=function(e){const t=U_(e);return{async deleteCell(r,n,a){var l,c;const o=await t.deleteCell(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["CellApi.deleteCell"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async deployCell(r,n,a){var l,c;const o=await t.deployCell(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["CellApi.deployCell"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getCell(r,n){var i,l;const a=await t.getCell(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["CellApi.getCell"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async getCellStatus(r,n){var i,l;const a=await t.getCellStatus(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["CellApi.getCellStatus"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async listCells(r){var s,i;const n=await t.listCells(r),a=(e==null?void 0:e.serverIndex)??0,o=(i=(s=M["CellApi.listCells"])==null?void 0:s[a])==null?void 0:i.url;return(l,c)=>D(n,R,I,e)(l,o||c)},async updateCell(r,n,a,o){var c,u;const s=await t.updateCell(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["CellApi.updateCell"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)}}};class L_ extends Ve{deleteCell(t,r,n){return Jr(this.configuration).deleteCell(t,r,n).then(a=>a(this.axios,this.basePath))}deployCell(t,r,n){return Jr(this.configuration).deployCell(t,r,n).then(a=>a(this.axios,this.basePath))}getCell(t,r){return Jr(this.configuration).getCell(t,r).then(n=>n(this.axios,this.basePath))}getCellStatus(t,r){return Jr(this.configuration).getCellStatus(t,r).then(n=>n(this.axios,this.basePath))}listCells(t){return Jr(this.configuration).listCells(t).then(r=>r(this.axios,this.basePath))}updateCell(t,r,n,a){return Jr(this.configuration).updateCell(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const D_=function(e){return{addRobotController:async(t,r,n,a={})=>{v("addRobotController","cell",t),v("addRobotController","robotController",r);const o="/cells/{cell}/controllers".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.completionTimeout=n),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(r,l,e),{url:L(s),options:l}},clearRobotControllers:async(t,r,n={})=>{v("clearRobotControllers","cell",t);const a="/cells/{cell}/controllers".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),r!==void 0&&(c.completionTimeout=r),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},deleteRobotController:async(t,r,n,a={})=>{v("deleteRobotController","cell",t),v("deleteRobotController","controller",r);const o="/cells/{cell}/controllers/{controller}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"DELETE",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.completionTimeout=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},getCurrentRobotControllerState:async(t,r,n={})=>{v("getCurrentRobotControllerState","cell",t),v("getCurrentRobotControllerState","controller",r);const a="/cells/{cell}/controllers/{controller}/state".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getMode:async(t,r,n={})=>{v("getMode","cell",t),v("getMode","controller",r);const a="/cells/{cell}/controllers/{controller}/mode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getRobotController:async(t,r,n={})=>{v("getRobotController","cell",t),v("getRobotController","controller",r);const a="/cells/{cell}/controllers/{controller}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getSupportedModes:async(t,r,n={})=>{v("getSupportedModes","cell",t),v("getSupportedModes","controller",r);const a="/cells/{cell}/controllers/{controller}/controller-capabilities".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getVirtualRobotConfiguration:async(t,r,n={})=>{v("getVirtualRobotConfiguration","cell",t),v("getVirtualRobotConfiguration","controller",r);const a="/cells/{cell}/controllers/{controller}/virtual-robot-configuration".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listControllers:async(t,r={})=>{v("listControllers","cell",t);const n="/cells/{cell}/controllers".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},setDefaultMode:async(t,r,n,a={})=>{v("setDefaultMode","cell",t),v("setDefaultMode","controller",r),v("setDefaultMode","mode",n);const o="/cells/{cell}/controllers/{controller}/mode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.mode=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},streamFreeDrive:async(t,r,n,a={})=>{v("streamFreeDrive","cell",t),v("streamFreeDrive","controller",r);const o="/cells/{cell}/controllers/{controller}/free-drive-stream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.response_rate=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},streamModeChange:async(t,r,n={})=>{v("streamModeChange","cell",t),v("streamModeChange","controller",r);const a="/cells/{cell}/controllers/{controller}/mode-stream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},streamRobotControllerState:async(t,r,n,a={})=>{v("streamRobotControllerState","cell",t),v("streamRobotControllerState","controller",r);const o="/cells/{cell}/controllers/{controller}/state-stream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.response_rate=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},updateRobotController:async(t,r,n,a,o={})=>{v("updateRobotController","cell",t),v("updateRobotController","controller",r),v("updateRobotController","robotController",n);const s="/cells/{cell}/controllers/{controller}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),i=new URL(s,$);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={};j(c,e),await k(u,e),a!==void 0&&(d.completionTimeout=a),u["Content-Type"]="application/json",U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},c.data=ue(n,c,e),{url:L(i),options:c}}}},rt=function(e){const t=D_(e);return{async addRobotController(r,n,a,o){var c,u;const s=await t.addRobotController(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["ControllerApi.addRobotController"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async clearRobotControllers(r,n,a){var l,c;const o=await t.clearRobotControllers(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ControllerApi.clearRobotControllers"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async deleteRobotController(r,n,a,o){var c,u;const s=await t.deleteRobotController(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["ControllerApi.deleteRobotController"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async getCurrentRobotControllerState(r,n,a){var l,c;const o=await t.getCurrentRobotControllerState(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ControllerApi.getCurrentRobotControllerState"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getMode(r,n,a){var l,c;const o=await t.getMode(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ControllerApi.getMode"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getRobotController(r,n,a){var l,c;const o=await t.getRobotController(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ControllerApi.getRobotController"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getSupportedModes(r,n,a){var l,c;const o=await t.getSupportedModes(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ControllerApi.getSupportedModes"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getVirtualRobotConfiguration(r,n,a){var l,c;const o=await t.getVirtualRobotConfiguration(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ControllerApi.getVirtualRobotConfiguration"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listControllers(r,n){var i,l;const a=await t.listControllers(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["ControllerApi.listControllers"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async setDefaultMode(r,n,a,o){var c,u;const s=await t.setDefaultMode(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["ControllerApi.setDefaultMode"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async streamFreeDrive(r,n,a,o){var c,u;const s=await t.streamFreeDrive(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["ControllerApi.streamFreeDrive"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async streamModeChange(r,n,a){var l,c;const o=await t.streamModeChange(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ControllerApi.streamModeChange"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async streamRobotControllerState(r,n,a,o){var c,u;const s=await t.streamRobotControllerState(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["ControllerApi.streamRobotControllerState"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async updateRobotController(r,n,a,o,s){var u,d;const i=await t.updateRobotController(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=M["ControllerApi.updateRobotController"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>D(i,R,I,e)(h,c||p)}}};class B_ extends Ve{addRobotController(t,r,n,a){return rt(this.configuration).addRobotController(t,r,n,a).then(o=>o(this.axios,this.basePath))}clearRobotControllers(t,r,n){return rt(this.configuration).clearRobotControllers(t,r,n).then(a=>a(this.axios,this.basePath))}deleteRobotController(t,r,n,a){return rt(this.configuration).deleteRobotController(t,r,n,a).then(o=>o(this.axios,this.basePath))}getCurrentRobotControllerState(t,r,n){return rt(this.configuration).getCurrentRobotControllerState(t,r,n).then(a=>a(this.axios,this.basePath))}getMode(t,r,n){return rt(this.configuration).getMode(t,r,n).then(a=>a(this.axios,this.basePath))}getRobotController(t,r,n){return rt(this.configuration).getRobotController(t,r,n).then(a=>a(this.axios,this.basePath))}getSupportedModes(t,r,n){return rt(this.configuration).getSupportedModes(t,r,n).then(a=>a(this.axios,this.basePath))}getVirtualRobotConfiguration(t,r,n){return rt(this.configuration).getVirtualRobotConfiguration(t,r,n).then(a=>a(this.axios,this.basePath))}listControllers(t,r){return rt(this.configuration).listControllers(t,r).then(n=>n(this.axios,this.basePath))}setDefaultMode(t,r,n,a){return rt(this.configuration).setDefaultMode(t,r,n,a).then(o=>o(this.axios,this.basePath))}streamFreeDrive(t,r,n,a){return rt(this.configuration).streamFreeDrive(t,r,n,a).then(o=>o(this.axios,this.basePath))}streamModeChange(t,r,n){return rt(this.configuration).streamModeChange(t,r,n).then(a=>a(this.axios,this.basePath))}streamRobotControllerState(t,r,n,a){return rt(this.configuration).streamRobotControllerState(t,r,n,a).then(o=>o(this.axios,this.basePath))}updateRobotController(t,r,n,a,o){return rt(this.configuration).updateRobotController(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}}const N_=function(e){return{listIODescriptions:async(t,r,n,a={})=>{v("listIODescriptions","cell",t),v("listIODescriptions","controller",r);const o="/cells/{cell}/controllers/{controller}/ios/description".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),n&&(u.ios=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},listIOValues:async(t,r,n,a={})=>{v("listIOValues","cell",t),v("listIOValues","controller",r);const o="/cells/{cell}/controllers/{controller}/ios/values".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),n&&(u.ios=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},setOutputValues:async(t,r,n,a={})=>{v("setOutputValues","cell",t),v("setOutputValues","controller",r),v("setOutputValues","iOValue",n);const o="/cells/{cell}/controllers/{controller}/ios/values".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}},streamIOValues:async(t,r,n,a={})=>{v("streamIOValues","cell",t),v("streamIOValues","controller",r);const o="/cells/{cell}/controllers/{controller}/ios/stream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),n&&(u.ios=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},waitForIOEvent:async(t,r,n,a,o,s,i,l={})=>{v("waitForIOEvent","cell",t),v("waitForIOEvent","controller",r),v("waitForIOEvent","io",n),v("waitForIOEvent","comparisonType",a);const c="/cells/{cell}/controllers/{controller}/ios/wait-for".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),u=new URL(c,$);let d;e&&(d=e.baseOptions);const h={method:"GET",...d,...l},p={},f={};j(h,e),await k(p,e),n!==void 0&&(f.io=n),a!==void 0&&(f.comparison_type=a),o!==void 0&&(f.boolean_value=o),s!==void 0&&(f.integer_value=s),i!==void 0&&(f.floating_value=i),U(u,f);let m=d&&d.headers?d.headers:{};return h.headers={...p,...m,...l.headers},{url:L(u),options:h}}}},zn=function(e){const t=N_(e);return{async listIODescriptions(r,n,a,o){var c,u;const s=await t.listIODescriptions(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["ControllerIOsApi.listIODescriptions"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async listIOValues(r,n,a,o){var c,u;const s=await t.listIOValues(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["ControllerIOsApi.listIOValues"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async setOutputValues(r,n,a,o){var c,u;const s=await t.setOutputValues(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["ControllerIOsApi.setOutputValues"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async streamIOValues(r,n,a,o){var c,u;const s=await t.streamIOValues(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["ControllerIOsApi.streamIOValues"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async waitForIOEvent(r,n,a,o,s,i,l,c){var p,f;const u=await t.waitForIOEvent(r,n,a,o,s,i,l,c),d=(e==null?void 0:e.serverIndex)??0,h=(f=(p=M["ControllerIOsApi.waitForIOEvent"])==null?void 0:p[d])==null?void 0:f.url;return(m,b)=>D(u,R,I,e)(m,h||b)}}};class F_ extends Ve{listIODescriptions(t,r,n,a){return zn(this.configuration).listIODescriptions(t,r,n,a).then(o=>o(this.axios,this.basePath))}listIOValues(t,r,n,a){return zn(this.configuration).listIOValues(t,r,n,a).then(o=>o(this.axios,this.basePath))}setOutputValues(t,r,n,a){return zn(this.configuration).setOutputValues(t,r,n,a).then(o=>o(this.axios,this.basePath))}streamIOValues(t,r,n,a){return zn(this.configuration).streamIOValues(t,r,n,a).then(o=>o(this.axios,this.basePath))}waitForIOEvent(t,r,n,a,o,s,i,l){return zn(this.configuration).waitForIOEvent(t,r,n,a,o,s,i,l).then(c=>c(this.axios,this.basePath))}}const z_=function(e){return{addCoordinateSystem:async(t,r,n={})=>{v("addCoordinateSystem","cell",t),v("addCoordinateSystem","addRequest",r);const a="/cells/{cell}/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="application/json",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},deleteCoordinateSystem:async(t,r,n={})=>{v("deleteCoordinateSystem","cell",t),v("deleteCoordinateSystem","coordinateSystem",r);const a="/cells/{cell}/coordinate-systems/{coordinate-system}".replace("{cell}",encodeURIComponent(String(t))).replace("{coordinate-system}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getCoordinateSystem:async(t,r,n,a={})=>{v("getCoordinateSystem","cell",t),v("getCoordinateSystem","coordinateSystem",r);const o="/cells/{cell}/coordinate-systems/{coordinate-system}".replace("{cell}",encodeURIComponent(String(t))).replace("{coordinate-system}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.rotation_type=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},listCoordinateSystems:async(t,r,n={})=>{v("listCoordinateSystems","cell",t);const a="/cells/{cell}/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),r!==void 0&&(c.rotation_type=r),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},transformInCoordinateSystem:async(t,r,n,a={})=>{v("transformInCoordinateSystem","cell",t),v("transformInCoordinateSystem","coordinateSystem",r),v("transformInCoordinateSystem","pose",n);const o="/cells/{cell}/coordinate-systems/{coordinate-system}/transform".replace("{cell}",encodeURIComponent(String(t))).replace("{coordinate-system}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}}}},Gn=function(e){const t=z_(e);return{async addCoordinateSystem(r,n,a){var l,c;const o=await t.addCoordinateSystem(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["CoordinateSystemsApi.addCoordinateSystem"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async deleteCoordinateSystem(r,n,a){var l,c;const o=await t.deleteCoordinateSystem(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["CoordinateSystemsApi.deleteCoordinateSystem"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getCoordinateSystem(r,n,a,o){var c,u;const s=await t.getCoordinateSystem(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["CoordinateSystemsApi.getCoordinateSystem"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async listCoordinateSystems(r,n,a){var l,c;const o=await t.listCoordinateSystems(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["CoordinateSystemsApi.listCoordinateSystems"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async transformInCoordinateSystem(r,n,a,o){var c,u;const s=await t.transformInCoordinateSystem(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["CoordinateSystemsApi.transformInCoordinateSystem"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)}}};class G_ extends Ve{addCoordinateSystem(t,r,n){return Gn(this.configuration).addCoordinateSystem(t,r,n).then(a=>a(this.axios,this.basePath))}deleteCoordinateSystem(t,r,n){return Gn(this.configuration).deleteCoordinateSystem(t,r,n).then(a=>a(this.axios,this.basePath))}getCoordinateSystem(t,r,n,a){return Gn(this.configuration).getCoordinateSystem(t,r,n,a).then(o=>o(this.axios,this.basePath))}listCoordinateSystems(t,r,n){return Gn(this.configuration).listCoordinateSystems(t,r,n).then(a=>a(this.axios,this.basePath))}transformInCoordinateSystem(t,r,n,a){return Gn(this.configuration).transformInCoordinateSystem(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const H_=function(e){return{clearDevices:async(t,r={})=>{v("clearDevices","cell",t);const n="/cells/{cell}/devices".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"DELETE",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},createDevice:async(t,r,n={})=>{v("createDevice","cell",t),v("createDevice","createDeviceRequestInner",r);const a="/cells/{cell}/devices".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="application/json",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},deleteDevice:async(t,r,n={})=>{v("deleteDevice","cell",t),v("deleteDevice","identifier",r);const a="/cells/{cell}/devices/{identifier}".replace("{cell}",encodeURIComponent(String(t))).replace("{identifier}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getDevice:async(t,r,n={})=>{v("getDevice","cell",t),v("getDevice","identifier",r);const a="/cells/{cell}/devices/{identifier}".replace("{cell}",encodeURIComponent(String(t))).replace("{identifier}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listDevices:async(t,r={})=>{v("listDevices","cell",t);const n="/cells/{cell}/devices".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}}}},Hn=function(e){const t=H_(e);return{async clearDevices(r,n){var i,l;const a=await t.clearDevices(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["DeviceConfigurationApi.clearDevices"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async createDevice(r,n,a){var l,c;const o=await t.createDevice(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["DeviceConfigurationApi.createDevice"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async deleteDevice(r,n,a){var l,c;const o=await t.deleteDevice(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["DeviceConfigurationApi.deleteDevice"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getDevice(r,n,a){var l,c;const o=await t.getDevice(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["DeviceConfigurationApi.getDevice"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listDevices(r,n){var i,l;const a=await t.listDevices(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["DeviceConfigurationApi.listDevices"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)}}};class q_ extends Ve{clearDevices(t,r){return Hn(this.configuration).clearDevices(t,r).then(n=>n(this.axios,this.basePath))}createDevice(t,r,n){return Hn(this.configuration).createDevice(t,r,n).then(a=>a(this.axios,this.basePath))}deleteDevice(t,r,n){return Hn(this.configuration).deleteDevice(t,r,n).then(a=>a(this.axios,this.basePath))}getDevice(t,r,n){return Hn(this.configuration).getDevice(t,r,n).then(a=>a(this.axios,this.basePath))}listDevices(t,r){return Hn(this.configuration).listDevices(t,r).then(n=>n(this.axios,this.basePath))}}const J_=function(e){return{createProgram:async(t,r,n,a={})=>{v("createProgram","cell",t),v("createProgram","body",r);const o="/cells/{cell}/store/programs".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.name=n),c["Content-Type"]="text/plain",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(r,l,e),{url:L(s),options:l}},deleteProgram:async(t,r,n={})=>{v("deleteProgram","cell",t),v("deleteProgram","program",r);const a="/cells/{cell}/store/programs/{program}".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},deleteProgramList:async(t,r,n={})=>{v("deleteProgramList","cell",t),v("deleteProgramList","programIds",r);const a="/cells/{cell}/store/programs".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),r&&(c.program_ids=r),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getProgram:async(t,r,n={})=>{v("getProgram","cell",t),v("getProgram","program",r);const a="/cells/{cell}/store/programs/{program}".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},updateProgram:async(t,r,n,a={})=>{v("updateProgram","cell",t),v("updateProgram","program",r),v("updateProgram","body",n);const o="/cells/{cell}/store/programs/{program}".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="text/plain",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}}}},qn=function(e){const t=J_(e);return{async createProgram(r,n,a,o){var c,u;const s=await t.createProgram(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["LibraryProgramApi.createProgram"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async deleteProgram(r,n,a){var l,c;const o=await t.deleteProgram(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["LibraryProgramApi.deleteProgram"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async deleteProgramList(r,n,a){var l,c;const o=await t.deleteProgramList(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["LibraryProgramApi.deleteProgramList"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getProgram(r,n,a){var l,c;const o=await t.getProgram(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["LibraryProgramApi.getProgram"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async updateProgram(r,n,a,o){var c,u;const s=await t.updateProgram(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["LibraryProgramApi.updateProgram"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)}}};class W_ extends Ve{createProgram(t,r,n,a){return qn(this.configuration).createProgram(t,r,n,a).then(o=>o(this.axios,this.basePath))}deleteProgram(t,r,n){return qn(this.configuration).deleteProgram(t,r,n).then(a=>a(this.axios,this.basePath))}deleteProgramList(t,r,n){return qn(this.configuration).deleteProgramList(t,r,n).then(a=>a(this.axios,this.basePath))}getProgram(t,r,n){return qn(this.configuration).getProgram(t,r,n).then(a=>a(this.axios,this.basePath))}updateProgram(t,r,n,a){return qn(this.configuration).updateProgram(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const Y_=function(e){return{getProgramMetadata:async(t,r,n={})=>{v("getProgramMetadata","cell",t),v("getProgramMetadata","program",r);const a="/cells/{cell}/store/programs/{program}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listProgramMetadata:async(t,r,n={})=>{v("listProgramMetadata","cell",t);const a="/cells/{cell}/store/programs".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),r!==void 0&&(c.show_hidden=r),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},updateProgramMetadata:async(t,r,n,a={})=>{v("updateProgramMetadata","cell",t),v("updateProgramMetadata","program",r),v("updateProgramMetadata","updateProgramMetadataRequest",n);const o="/cells/{cell}/store/programs/{program}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}},uploadProgramMetadataImage:async(t,r,n,a={})=>{v("uploadProgramMetadataImage","cell",t),v("uploadProgramMetadataImage","program",r),v("uploadProgramMetadataImage","file",n);const o="/cells/{cell}/store/programs/{program}/metadata/image".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={},d=new(e&&e.formDataCtor||FormData);j(l,e),await k(c,e),n!==void 0&&d.append("file",n),c["Content-Type"]="multipart/form-data",U(s,u);let h=i&&i.headers?i.headers:{};return l.headers={...c,...h,...a.headers},l.data=d,{url:L(s),options:l}}}},Xa=function(e){const t=Y_(e);return{async getProgramMetadata(r,n,a){var l,c;const o=await t.getProgramMetadata(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["LibraryProgramMetadataApi.getProgramMetadata"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listProgramMetadata(r,n,a){var l,c;const o=await t.listProgramMetadata(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["LibraryProgramMetadataApi.listProgramMetadata"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async updateProgramMetadata(r,n,a,o){var c,u;const s=await t.updateProgramMetadata(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["LibraryProgramMetadataApi.updateProgramMetadata"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async uploadProgramMetadataImage(r,n,a,o){var c,u;const s=await t.uploadProgramMetadataImage(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["LibraryProgramMetadataApi.uploadProgramMetadataImage"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)}}};class K_ extends Ve{getProgramMetadata(t,r,n){return Xa(this.configuration).getProgramMetadata(t,r,n).then(a=>a(this.axios,this.basePath))}listProgramMetadata(t,r,n){return Xa(this.configuration).listProgramMetadata(t,r,n).then(a=>a(this.axios,this.basePath))}updateProgramMetadata(t,r,n,a){return Xa(this.configuration).updateProgramMetadata(t,r,n,a).then(o=>o(this.axios,this.basePath))}uploadProgramMetadataImage(t,r,n,a){return Xa(this.configuration).uploadProgramMetadataImage(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const Q_=function(e){return{createRecipe:async(t,r,n,a,o={})=>{v("createRecipe","cell",t),v("createRecipe","programId",r),v("createRecipe","body",n);const s="/cells/{cell}/store/recipes".replace("{cell}",encodeURIComponent(String(t))),i=new URL(s,$);let l;e&&(l=e.baseOptions);const c={method:"POST",...l,...o},u={},d={};j(c,e),await k(u,e),r!==void 0&&(d.program_id=r),a!==void 0&&(d.name=a),u["Content-Type"]="application/json",U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},c.data=ue(n,c,e),{url:L(i),options:c}},deleteRecipe:async(t,r,n={})=>{v("deleteRecipe","cell",t),v("deleteRecipe","recipe",r);const a="/cells/{cell}/store/recipes/{recipe}".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},deleteRecipeList:async(t,r,n={})=>{v("deleteRecipeList","cell",t),v("deleteRecipeList","recipeIds",r);const a="/cells/{cell}/store/recipes".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),r&&(c.recipe_ids=r),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getRecipe:async(t,r,n={})=>{v("getRecipe","cell",t),v("getRecipe","recipe",r);const a="/cells/{cell}/store/recipes/{recipe}".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},updateRecipe:async(t,r,n,a={})=>{v("updateRecipe","cell",t),v("updateRecipe","recipe",r),v("updateRecipe","body",n);const o="/cells/{cell}/store/recipes/{recipe}".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}}}},Jn=function(e){const t=Q_(e);return{async createRecipe(r,n,a,o,s){var u,d;const i=await t.createRecipe(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=M["LibraryRecipeApi.createRecipe"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>D(i,R,I,e)(h,c||p)},async deleteRecipe(r,n,a){var l,c;const o=await t.deleteRecipe(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["LibraryRecipeApi.deleteRecipe"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async deleteRecipeList(r,n,a){var l,c;const o=await t.deleteRecipeList(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["LibraryRecipeApi.deleteRecipeList"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getRecipe(r,n,a){var l,c;const o=await t.getRecipe(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["LibraryRecipeApi.getRecipe"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async updateRecipe(r,n,a,o){var c,u;const s=await t.updateRecipe(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["LibraryRecipeApi.updateRecipe"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)}}};class X_ extends Ve{createRecipe(t,r,n,a,o){return Jn(this.configuration).createRecipe(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}deleteRecipe(t,r,n){return Jn(this.configuration).deleteRecipe(t,r,n).then(a=>a(this.axios,this.basePath))}deleteRecipeList(t,r,n){return Jn(this.configuration).deleteRecipeList(t,r,n).then(a=>a(this.axios,this.basePath))}getRecipe(t,r,n){return Jn(this.configuration).getRecipe(t,r,n).then(a=>a(this.axios,this.basePath))}updateRecipe(t,r,n,a){return Jn(this.configuration).updateRecipe(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const Z_=function(e){return{getRecipeMetadata:async(t,r,n={})=>{v("getRecipeMetadata","cell",t),v("getRecipeMetadata","recipe",r);const a="/cells/{cell}/store/recipes/{recipe}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listRecipeMetadata:async(t,r={})=>{v("listRecipeMetadata","cell",t);const n="/cells/{cell}/store/recipes".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},updateRecipeMetadata:async(t,r,n,a={})=>{v("updateRecipeMetadata","cell",t),v("updateRecipeMetadata","recipe",r),v("updateRecipeMetadata","updateRecipeMetadataRequest",n);const o="/cells/{cell}/store/recipes/{recipe}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}},uploadRecipeMetadataImage:async(t,r,n,a={})=>{v("uploadRecipeMetadataImage","cell",t),v("uploadRecipeMetadataImage","recipe",r),v("uploadRecipeMetadataImage","file",n);const o="/cells/{cell}/store/recipes/{recipe}/metadata/image".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={},d=new(e&&e.formDataCtor||FormData);j(l,e),await k(c,e),n!==void 0&&d.append("file",n),c["Content-Type"]="multipart/form-data",U(s,u);let h=i&&i.headers?i.headers:{};return l.headers={...c,...h,...a.headers},l.data=d,{url:L(s),options:l}}}},Za=function(e){const t=Z_(e);return{async getRecipeMetadata(r,n,a){var l,c;const o=await t.getRecipeMetadata(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["LibraryRecipeMetadataApi.getRecipeMetadata"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listRecipeMetadata(r,n){var i,l;const a=await t.listRecipeMetadata(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["LibraryRecipeMetadataApi.listRecipeMetadata"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async updateRecipeMetadata(r,n,a,o){var c,u;const s=await t.updateRecipeMetadata(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["LibraryRecipeMetadataApi.updateRecipeMetadata"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async uploadRecipeMetadataImage(r,n,a,o){var c,u;const s=await t.uploadRecipeMetadataImage(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["LibraryRecipeMetadataApi.uploadRecipeMetadataImage"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)}}};class eE extends Ve{getRecipeMetadata(t,r,n){return Za(this.configuration).getRecipeMetadata(t,r,n).then(a=>a(this.axios,this.basePath))}listRecipeMetadata(t,r){return Za(this.configuration).listRecipeMetadata(t,r).then(n=>n(this.axios,this.basePath))}updateRecipeMetadata(t,r,n,a){return Za(this.configuration).updateRecipeMetadata(t,r,n,a).then(o=>o(this.axios,this.basePath))}uploadRecipeMetadataImage(t,r,n,a){return Za(this.configuration).uploadRecipeMetadataImage(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const tE=function(e){return{deleteAllMotions:async(t,r={})=>{v("deleteAllMotions","cell",t);const n="/cells/{cell}/motions".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"DELETE",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},deleteMotion:async(t,r,n={})=>{v("deleteMotion","cell",t),v("deleteMotion","motion",r);const a="/cells/{cell}/motions/{motion}/delete".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},executeTrajectory:async(t,r,n={})=>{v("executeTrajectory","cell",t),v("executeTrajectory","executeTrajectoryRequest",r);const a="/cells/{cell}/motions/executetrajectory".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="application/json",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},getMotionTrajectory:async(t,r,n,a,o={})=>{v("getMotionTrajectory","cell",t),v("getMotionTrajectory","motion",r),v("getMotionTrajectory","sampleTime",n);const s="/cells/{cell}/motions/{motion}/trajectory".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),i=new URL(s,$);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},u={},d={};j(c,e),await k(u,e),n!==void 0&&(d.sample_time=n),a!==void 0&&(d.responses_coordinate_system=a),U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},{url:L(i),options:c}},getMotionTrajectorySample:async(t,r,n,a,o={})=>{v("getMotionTrajectorySample","cell",t),v("getMotionTrajectorySample","motion",r);const s="/cells/{cell}/motions/{motion}/trajectorysample".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),i=new URL(s,$);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},u={},d={};j(c,e),await k(u,e),n!==void 0&&(d.location_on_trajectory=n),a!==void 0&&(d.response_coordinate_system=a),U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},{url:L(i),options:c}},getPlannedMotion:async(t,r,n,a={})=>{v("getPlannedMotion","cell",t),v("getPlannedMotion","motion",r);const o="/cells/{cell}/motions/{motion}/planned-motion".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.sample_time=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},getPlanningMotionGroupModels:async(t,r={})=>{v("getPlanningMotionGroupModels","cell",t);const n="/cells/{cell}/motion-planning/motion-group-models".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},listMotions:async(t,r={})=>{v("listMotions","cell",t);const n="/cells/{cell}/motions".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},loadPlannedMotion:async(t,r,n={})=>{v("loadPlannedMotion","cell",t),v("loadPlannedMotion","plannedMotion",r);const a="/cells/{cell}/planned-motions".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="application/json",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},planCollisionFreePTP:async(t,r,n={})=>{v("planCollisionFreePTP","cell",t);const a="/cells/{cell}/motion-planning/plan-collision-free-ptp".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="application/json",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},planMotion:async(t,r,n={})=>{v("planMotion","cell",t),v("planMotion","planRequest",r);const a="/cells/{cell}/motions".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="application/json",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},planTrajectory:async(t,r,n={})=>{v("planTrajectory","cell",t);const a="/cells/{cell}/motion-planning/plan-trajectory".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="application/json",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},stopExecution:async(t,r,n={})=>{v("stopExecution","cell",t),v("stopExecution","motion",r);const a="/cells/{cell}/motions/{motion}/stop".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},streamMove:async(t,r,n={})=>{v("streamMove","cell",t),v("streamMove","streamMoveRequest",r);const a="/cells/{cell}/motions/streammove".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="application/json",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},streamMoveBackward:async(t,r,n,a,o,s,i={})=>{v("streamMoveBackward","cell",t),v("streamMoveBackward","motion",r),v("streamMoveBackward","playbackSpeedInPercent",n);const l="/cells/{cell}/motions/{motion}/executebackward".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),c=new URL(l,$);let u;e&&(u=e.baseOptions);const d={method:"GET",...u,...i},h={},p={};j(d,e),await k(h,e),n!==void 0&&(p.playback_speed_in_percent=n),a!==void 0&&(p.response_rate=a),o!==void 0&&(p.response_coordinate_system=o),s!==void 0&&(p.start_location_on_trajectory=s),U(c,p);let f=u&&u.headers?u.headers:{};return d.headers={...h,...f,...i.headers},{url:L(c),options:d}},streamMoveForward:async(t,r,n,a,o,s,i={})=>{v("streamMoveForward","cell",t),v("streamMoveForward","motion",r),v("streamMoveForward","playbackSpeedInPercent",n);const l="/cells/{cell}/motions/{motion}/executeforward".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),c=new URL(l,$);let u;e&&(u=e.baseOptions);const d={method:"GET",...u,...i},h={},p={};j(d,e),await k(h,e),n!==void 0&&(p.playback_speed_in_percent=n),a!==void 0&&(p.response_rate=a),o!==void 0&&(p.response_coordinate_system=o),s!==void 0&&(p.start_location_on_trajectory=s),U(c,p);let f=u&&u.headers?u.headers:{};return d.headers={...h,...f,...i.headers},{url:L(c),options:d}},streamMoveToTrajectoryViaJointPTP:async(t,r,n,a,o,s,i,l,c,u,d={})=>{v("streamMoveToTrajectoryViaJointPTP","cell",t),v("streamMoveToTrajectoryViaJointPTP","motion",r),v("streamMoveToTrajectoryViaJointPTP","locationOnTrajectory",n);const h="/cells/{cell}/motions/{motion}/executetotrajectory".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),p=new URL(h,$);let f;e&&(f=e.baseOptions);const m={method:"GET",...f,...d},b={},x={};j(m,e),await k(b,e),n!==void 0&&(x.location_on_trajectory=n),a&&(x["limit_override.joint_velocity_limits.joints"]=a),o&&(x["limit_override.joint_acceleration_limits.joints"]=o),s!==void 0&&(x["limit_override.tcp_velocity_limit"]=s),i!==void 0&&(x["limit_override.tcp_acceleration_limit"]=i),l!==void 0&&(x["limit_override.tcp_orientation_velocity_limit"]=l),c!==void 0&&(x["limit_override.tcp_orientation_acceleration_limit"]=c),u!==void 0&&(x.responses_coordinate_system=u),U(p,x);let V=f&&f.headers?f.headers:{};return m.headers={...b,...V,...d.headers},{url:L(p),options:m}}}},Ye=function(e){const t=tE(e);return{async deleteAllMotions(r,n){var i,l;const a=await t.deleteAllMotions(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["MotionApi.deleteAllMotions"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async deleteMotion(r,n,a){var l,c;const o=await t.deleteMotion(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionApi.deleteMotion"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async executeTrajectory(r,n,a){var l,c;const o=await t.executeTrajectory(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionApi.executeTrajectory"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getMotionTrajectory(r,n,a,o,s){var u,d;const i=await t.getMotionTrajectory(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=M["MotionApi.getMotionTrajectory"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>D(i,R,I,e)(h,c||p)},async getMotionTrajectorySample(r,n,a,o,s){var u,d;const i=await t.getMotionTrajectorySample(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=M["MotionApi.getMotionTrajectorySample"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>D(i,R,I,e)(h,c||p)},async getPlannedMotion(r,n,a,o){var c,u;const s=await t.getPlannedMotion(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["MotionApi.getPlannedMotion"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async getPlanningMotionGroupModels(r,n){var i,l;const a=await t.getPlanningMotionGroupModels(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["MotionApi.getPlanningMotionGroupModels"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async listMotions(r,n){var i,l;const a=await t.listMotions(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["MotionApi.listMotions"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async loadPlannedMotion(r,n,a){var l,c;const o=await t.loadPlannedMotion(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionApi.loadPlannedMotion"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async planCollisionFreePTP(r,n,a){var l,c;const o=await t.planCollisionFreePTP(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionApi.planCollisionFreePTP"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async planMotion(r,n,a){var l,c;const o=await t.planMotion(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionApi.planMotion"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async planTrajectory(r,n,a){var l,c;const o=await t.planTrajectory(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionApi.planTrajectory"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async stopExecution(r,n,a){var l,c;const o=await t.stopExecution(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionApi.stopExecution"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async streamMove(r,n,a){var l,c;const o=await t.streamMove(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionApi.streamMove"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async streamMoveBackward(r,n,a,o,s,i,l){var h,p;const c=await t.streamMoveBackward(r,n,a,o,s,i,l),u=(e==null?void 0:e.serverIndex)??0,d=(p=(h=M["MotionApi.streamMoveBackward"])==null?void 0:h[u])==null?void 0:p.url;return(f,m)=>D(c,R,I,e)(f,d||m)},async streamMoveForward(r,n,a,o,s,i,l){var h,p;const c=await t.streamMoveForward(r,n,a,o,s,i,l),u=(e==null?void 0:e.serverIndex)??0,d=(p=(h=M["MotionApi.streamMoveForward"])==null?void 0:h[u])==null?void 0:p.url;return(f,m)=>D(c,R,I,e)(f,d||m)},async streamMoveToTrajectoryViaJointPTP(r,n,a,o,s,i,l,c,u,d,h){var b,x;const p=await t.streamMoveToTrajectoryViaJointPTP(r,n,a,o,s,i,l,c,u,d,h),f=(e==null?void 0:e.serverIndex)??0,m=(x=(b=M["MotionApi.streamMoveToTrajectoryViaJointPTP"])==null?void 0:b[f])==null?void 0:x.url;return(V,O)=>D(p,R,I,e)(V,m||O)}}};class rE extends Ve{deleteAllMotions(t,r){return Ye(this.configuration).deleteAllMotions(t,r).then(n=>n(this.axios,this.basePath))}deleteMotion(t,r,n){return Ye(this.configuration).deleteMotion(t,r,n).then(a=>a(this.axios,this.basePath))}executeTrajectory(t,r,n){return Ye(this.configuration).executeTrajectory(t,r,n).then(a=>a(this.axios,this.basePath))}getMotionTrajectory(t,r,n,a,o){return Ye(this.configuration).getMotionTrajectory(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}getMotionTrajectorySample(t,r,n,a,o){return Ye(this.configuration).getMotionTrajectorySample(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}getPlannedMotion(t,r,n,a){return Ye(this.configuration).getPlannedMotion(t,r,n,a).then(o=>o(this.axios,this.basePath))}getPlanningMotionGroupModels(t,r){return Ye(this.configuration).getPlanningMotionGroupModels(t,r).then(n=>n(this.axios,this.basePath))}listMotions(t,r){return Ye(this.configuration).listMotions(t,r).then(n=>n(this.axios,this.basePath))}loadPlannedMotion(t,r,n){return Ye(this.configuration).loadPlannedMotion(t,r,n).then(a=>a(this.axios,this.basePath))}planCollisionFreePTP(t,r,n){return Ye(this.configuration).planCollisionFreePTP(t,r,n).then(a=>a(this.axios,this.basePath))}planMotion(t,r,n){return Ye(this.configuration).planMotion(t,r,n).then(a=>a(this.axios,this.basePath))}planTrajectory(t,r,n){return Ye(this.configuration).planTrajectory(t,r,n).then(a=>a(this.axios,this.basePath))}stopExecution(t,r,n){return Ye(this.configuration).stopExecution(t,r,n).then(a=>a(this.axios,this.basePath))}streamMove(t,r,n){return Ye(this.configuration).streamMove(t,r,n).then(a=>a(this.axios,this.basePath))}streamMoveBackward(t,r,n,a,o,s,i){return Ye(this.configuration).streamMoveBackward(t,r,n,a,o,s,i).then(l=>l(this.axios,this.basePath))}streamMoveForward(t,r,n,a,o,s,i){return Ye(this.configuration).streamMoveForward(t,r,n,a,o,s,i).then(l=>l(this.axios,this.basePath))}streamMoveToTrajectoryViaJointPTP(t,r,n,a,o,s,i,l,c,u,d){return Ye(this.configuration).streamMoveToTrajectoryViaJointPTP(t,r,n,a,o,s,i,l,c,u,d).then(h=>h(this.axios,this.basePath))}}const nE=function(e){return{activateAllMotionGroups:async(t,r,n={})=>{v("activateAllMotionGroups","cell",t),v("activateAllMotionGroups","controller",r);const a="/cells/{cell}/motion-groups/all".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};j(i,e),await k(l,e),r!==void 0&&(c.controller=r),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},activateMotionGroup:async(t,r,n={})=>{v("activateMotionGroup","cell",t),v("activateMotionGroup","motionGroup",r);const a="/cells/{cell}/motion-groups".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};j(i,e),await k(l,e),r!==void 0&&(c.motion_group=r),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},deactivateMotionGroup:async(t,r,n={})=>{v("deactivateMotionGroup","cell",t),v("deactivateMotionGroup","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listMotionGroups:async(t,r={})=>{v("listMotionGroups","cell",t);const n="/cells/{cell}/motion-groups".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}}}},eo=function(e){const t=nE(e);return{async activateAllMotionGroups(r,n,a){var l,c;const o=await t.activateAllMotionGroups(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupApi.activateAllMotionGroups"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async activateMotionGroup(r,n,a){var l,c;const o=await t.activateMotionGroup(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupApi.activateMotionGroup"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async deactivateMotionGroup(r,n,a){var l,c;const o=await t.deactivateMotionGroup(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupApi.deactivateMotionGroup"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listMotionGroups(r,n){var i,l;const a=await t.listMotionGroups(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["MotionGroupApi.listMotionGroups"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)}}};class aE extends Ve{activateAllMotionGroups(t,r,n){return eo(this.configuration).activateAllMotionGroups(t,r,n).then(a=>a(this.axios,this.basePath))}activateMotionGroup(t,r,n){return eo(this.configuration).activateMotionGroup(t,r,n).then(a=>a(this.axios,this.basePath))}deactivateMotionGroup(t,r,n){return eo(this.configuration).deactivateMotionGroup(t,r,n).then(a=>a(this.axios,this.basePath))}listMotionGroups(t,r){return eo(this.configuration).listMotionGroups(t,r).then(n=>n(this.axios,this.basePath))}}const oE=function(e){return{getActivePayload:async(t,r,n={})=>{v("getActivePayload","cell",t),v("getActivePayload","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/payloads/current".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getActiveTcp:async(t,r,n,a={})=>{v("getActiveTcp","cell",t),v("getActiveTcp","motionGroup",r);const o="/cells/{cell}/motion-groups/{motion-group}/tcps/current".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.rotation_type=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},getCurrentMotionGroupState:async(t,r,n,a,o={})=>{v("getCurrentMotionGroupState","cell",t),v("getCurrentMotionGroupState","motionGroup",r);const s="/cells/{cell}/motion-groups/{motion-group}/state".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),i=new URL(s,$);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},u={},d={};j(c,e),await k(u,e),n!==void 0&&(d.tcp=n),a!==void 0&&(d.response_coordinate_system=a),U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},{url:L(i),options:c}},getInfoCapabilities:async(t,r,n={})=>{v("getInfoCapabilities","cell",t),v("getInfoCapabilities","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/info-capabilities".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getMotionGroupSpecification:async(t,r,n={})=>{v("getMotionGroupSpecification","cell",t),v("getMotionGroupSpecification","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/specification".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getMounting:async(t,r,n={})=>{v("getMounting","cell",t),v("getMounting","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/mounting".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getOptimizerConfiguration:async(t,r,n,a={})=>{v("getOptimizerConfiguration","cell",t),v("getOptimizerConfiguration","motionGroup",r);const o="/cells/{cell}/motion-groups/{motion-group}/optimizer-setup".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.tcp=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},getSafetySetup:async(t,r,n={})=>{v("getSafetySetup","cell",t),v("getSafetySetup","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/safety-setup".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listPayloads:async(t,r,n={})=>{v("listPayloads","cell",t),v("listPayloads","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/payloads".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listTcps:async(t,r,n,a={})=>{v("listTcps","cell",t),v("listTcps","motionGroup",r);const o="/cells/{cell}/motion-groups/{motion-group}/tcps".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.rotation_type=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},streamMotionGroupState:async(t,r,n,a,o,s={})=>{v("streamMotionGroupState","cell",t),v("streamMotionGroupState","motionGroup",r);const i="/cells/{cell}/motion-groups/{motion-group}/state-stream".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),l=new URL(i,$);let c;e&&(c=e.baseOptions);const u={method:"GET",...c,...s},d={},h={};j(u,e),await k(d,e),n!==void 0&&(h.response_rate=n),a!==void 0&&(h.response_coordinate_system=a),o!==void 0&&(h.tcp=o),U(l,h);let p=c&&c.headers?c.headers:{};return u.headers={...d,...p,...s.headers},{url:L(l),options:u}}}},bt=function(e){const t=oE(e);return{async getActivePayload(r,n,a){var l,c;const o=await t.getActivePayload(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupInfosApi.getActivePayload"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getActiveTcp(r,n,a,o){var c,u;const s=await t.getActiveTcp(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["MotionGroupInfosApi.getActiveTcp"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async getCurrentMotionGroupState(r,n,a,o,s){var u,d;const i=await t.getCurrentMotionGroupState(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=M["MotionGroupInfosApi.getCurrentMotionGroupState"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>D(i,R,I,e)(h,c||p)},async getInfoCapabilities(r,n,a){var l,c;const o=await t.getInfoCapabilities(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupInfosApi.getInfoCapabilities"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getMotionGroupSpecification(r,n,a){var l,c;const o=await t.getMotionGroupSpecification(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupInfosApi.getMotionGroupSpecification"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getMounting(r,n,a){var l,c;const o=await t.getMounting(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupInfosApi.getMounting"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getOptimizerConfiguration(r,n,a,o){var c,u;const s=await t.getOptimizerConfiguration(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["MotionGroupInfosApi.getOptimizerConfiguration"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async getSafetySetup(r,n,a){var l,c;const o=await t.getSafetySetup(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupInfosApi.getSafetySetup"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listPayloads(r,n,a){var l,c;const o=await t.listPayloads(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupInfosApi.listPayloads"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listTcps(r,n,a,o){var c,u;const s=await t.listTcps(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["MotionGroupInfosApi.listTcps"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async streamMotionGroupState(r,n,a,o,s,i){var d,h;const l=await t.streamMotionGroupState(r,n,a,o,s,i),c=(e==null?void 0:e.serverIndex)??0,u=(h=(d=M["MotionGroupInfosApi.streamMotionGroupState"])==null?void 0:d[c])==null?void 0:h.url;return(p,f)=>D(l,R,I,e)(p,u||f)}}};class sE extends Ve{getActivePayload(t,r,n){return bt(this.configuration).getActivePayload(t,r,n).then(a=>a(this.axios,this.basePath))}getActiveTcp(t,r,n,a){return bt(this.configuration).getActiveTcp(t,r,n,a).then(o=>o(this.axios,this.basePath))}getCurrentMotionGroupState(t,r,n,a,o){return bt(this.configuration).getCurrentMotionGroupState(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}getInfoCapabilities(t,r,n){return bt(this.configuration).getInfoCapabilities(t,r,n).then(a=>a(this.axios,this.basePath))}getMotionGroupSpecification(t,r,n){return bt(this.configuration).getMotionGroupSpecification(t,r,n).then(a=>a(this.axios,this.basePath))}getMounting(t,r,n){return bt(this.configuration).getMounting(t,r,n).then(a=>a(this.axios,this.basePath))}getOptimizerConfiguration(t,r,n,a){return bt(this.configuration).getOptimizerConfiguration(t,r,n,a).then(o=>o(this.axios,this.basePath))}getSafetySetup(t,r,n){return bt(this.configuration).getSafetySetup(t,r,n).then(a=>a(this.axios,this.basePath))}listPayloads(t,r,n){return bt(this.configuration).listPayloads(t,r,n).then(a=>a(this.axios,this.basePath))}listTcps(t,r,n,a){return bt(this.configuration).listTcps(t,r,n,a).then(o=>o(this.axios,this.basePath))}streamMotionGroupState(t,r,n,a,o,s){return bt(this.configuration).streamMotionGroupState(t,r,n,a,o,s).then(i=>i(this.axios,this.basePath))}}const iE=function(e){return{directionJogging:async(t,r,n={})=>{v("directionJogging","cell",t),v("directionJogging","directionJoggingRequest",r);const a="/cells/{cell}/motion-groups/move-tcp".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="application/json",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},getJoggingCapabilities:async(t,r,n={})=>{v("getJoggingCapabilities","cell",t),v("getJoggingCapabilities","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/jogging-capabilities".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},jointJogging:async(t,r,n={})=>{v("jointJogging","cell",t),v("jointJogging","jointJoggingRequest",r);const a="/cells/{cell}/motion-groups/move-joint".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="application/json",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},stopJogging:async(t,r,n={})=>{v("stopJogging","cell",t),v("stopJogging","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/stop".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}}}},to=function(e){const t=iE(e);return{async directionJogging(r,n,a){var l,c;const o=await t.directionJogging(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupJoggingApi.directionJogging"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getJoggingCapabilities(r,n,a){var l,c;const o=await t.getJoggingCapabilities(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupJoggingApi.getJoggingCapabilities"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async jointJogging(r,n,a){var l,c;const o=await t.jointJogging(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupJoggingApi.jointJogging"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async stopJogging(r,n,a){var l,c;const o=await t.stopJogging(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupJoggingApi.stopJogging"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)}}};class lE extends Ve{directionJogging(t,r,n){return to(this.configuration).directionJogging(t,r,n).then(a=>a(this.axios,this.basePath))}getJoggingCapabilities(t,r,n){return to(this.configuration).getJoggingCapabilities(t,r,n).then(a=>a(this.axios,this.basePath))}jointJogging(t,r,n){return to(this.configuration).jointJogging(t,r,n).then(a=>a(this.axios,this.basePath))}stopJogging(t,r,n){return to(this.configuration).stopJogging(t,r,n).then(a=>a(this.axios,this.basePath))}}const cE=function(e){return{calculateAllInverseKinematic:async(t,r,n,a={})=>{v("calculateAllInverseKinematic","cell",t),v("calculateAllInverseKinematic","motionGroup",r),v("calculateAllInverseKinematic","allJointPositionsRequest",n);const o="/cells/{cell}/motion-groups/{motion-group}/kinematic/calculate-all-joint-positions".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}},calculateForwardKinematic:async(t,r,n,a={})=>{v("calculateForwardKinematic","cell",t),v("calculateForwardKinematic","motionGroup",r),v("calculateForwardKinematic","tcpPoseRequest",n);const o="/cells/{cell}/motion-groups/{motion-group}/kinematic/calculate-tcp-pose".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}},calculateInverseKinematic:async(t,r,n,a={})=>{v("calculateInverseKinematic","cell",t),v("calculateInverseKinematic","motionGroup",r),v("calculateInverseKinematic","jointPositionRequest",n);const o="/cells/{cell}/motion-groups/{motion-group}/kinematic/calculate-joint-position".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}},getKinematicCapabilities:async(t,r,n={})=>{v("getKinematicCapabilities","cell",t),v("getKinematicCapabilities","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/kinematic-capabilities".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}}}},ro=function(e){const t=cE(e);return{async calculateAllInverseKinematic(r,n,a,o){var c,u;const s=await t.calculateAllInverseKinematic(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["MotionGroupKinematicApi.calculateAllInverseKinematic"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async calculateForwardKinematic(r,n,a,o){var c,u;const s=await t.calculateForwardKinematic(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["MotionGroupKinematicApi.calculateForwardKinematic"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async calculateInverseKinematic(r,n,a,o){var c,u;const s=await t.calculateInverseKinematic(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["MotionGroupKinematicApi.calculateInverseKinematic"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async getKinematicCapabilities(r,n,a){var l,c;const o=await t.getKinematicCapabilities(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["MotionGroupKinematicApi.getKinematicCapabilities"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)}}};class uE extends Ve{calculateAllInverseKinematic(t,r,n,a){return ro(this.configuration).calculateAllInverseKinematic(t,r,n,a).then(o=>o(this.axios,this.basePath))}calculateForwardKinematic(t,r,n,a){return ro(this.configuration).calculateForwardKinematic(t,r,n,a).then(o=>o(this.axios,this.basePath))}calculateInverseKinematic(t,r,n,a){return ro(this.configuration).calculateInverseKinematic(t,r,n,a).then(o=>o(this.axios,this.basePath))}getKinematicCapabilities(t,r,n){return ro(this.configuration).getKinematicCapabilities(t,r,n).then(a=>a(this.axios,this.basePath))}}const dE=function(e){return{createProgramRunner:async(t,r,n={})=>{v("createProgramRunner","cell",t),v("createProgramRunner","request",r);const a="/cells/{cell}/programs/runners".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="text/plain",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},executeProgram:async(t,r,n={})=>{v("executeProgram","cell",t),v("executeProgram","codeWithArguments",r);const a="/cells/{cell}/programs/execute".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="application/json",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},getProgramRunner:async(t,r,n={})=>{v("getProgramRunner","cell",t),v("getProgramRunner","runner",r);const a="/cells/{cell}/programs/runners/{runner}".replace("{cell}",encodeURIComponent(String(t))).replace("{runner}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listProgramRunners:async(t,r={})=>{v("listProgramRunners","cell",t);const n="/cells/{cell}/programs/runners".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},migrateProgram:async(t,r,n={})=>{v("migrateProgram","cell",t),v("migrateProgram","request1",r);const a="/cells/{cell}/programs/migrate".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="text/plain",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},planProgram:async(t,r,n,a={})=>{v("planProgram","cell",t),v("planProgram","request",r);const o="/cells/{cell}/programs/plan".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.identifier=n),c["Content-Type"]="text/plain",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(r,l,e),{url:L(s),options:l}},stopAllProgramRunner:async(t,r={})=>{v("stopAllProgramRunner","cell",t);const n="/cells/{cell}/programs/runners/stop".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"POST",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},stopProgramRunner:async(t,r,n={})=>{v("stopProgramRunner","cell",t),v("stopProgramRunner","runner",r);const a="/cells/{cell}/programs/runners/{runner}/stop".replace("{cell}",encodeURIComponent(String(t))).replace("{runner}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}}}},Xt=function(e){const t=dE(e);return{async createProgramRunner(r,n,a){var l,c;const o=await t.createProgramRunner(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ProgramApi.createProgramRunner"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async executeProgram(r,n,a){var l,c;const o=await t.executeProgram(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ProgramApi.executeProgram"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getProgramRunner(r,n,a){var l,c;const o=await t.getProgramRunner(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ProgramApi.getProgramRunner"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listProgramRunners(r,n){var i,l;const a=await t.listProgramRunners(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["ProgramApi.listProgramRunners"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async migrateProgram(r,n,a){var l,c;const o=await t.migrateProgram(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ProgramApi.migrateProgram"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async planProgram(r,n,a,o){var c,u;const s=await t.planProgram(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["ProgramApi.planProgram"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async stopAllProgramRunner(r,n){var i,l;const a=await t.stopAllProgramRunner(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["ProgramApi.stopAllProgramRunner"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async stopProgramRunner(r,n,a){var l,c;const o=await t.stopProgramRunner(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ProgramApi.stopProgramRunner"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)}}};class hE extends Ve{createProgramRunner(t,r,n){return Xt(this.configuration).createProgramRunner(t,r,n).then(a=>a(this.axios,this.basePath))}executeProgram(t,r,n){return Xt(this.configuration).executeProgram(t,r,n).then(a=>a(this.axios,this.basePath))}getProgramRunner(t,r,n){return Xt(this.configuration).getProgramRunner(t,r,n).then(a=>a(this.axios,this.basePath))}listProgramRunners(t,r){return Xt(this.configuration).listProgramRunners(t,r).then(n=>n(this.axios,this.basePath))}migrateProgram(t,r,n){return Xt(this.configuration).migrateProgram(t,r,n).then(a=>a(this.axios,this.basePath))}planProgram(t,r,n,a){return Xt(this.configuration).planProgram(t,r,n,a).then(o=>o(this.axios,this.basePath))}stopAllProgramRunner(t,r){return Xt(this.configuration).stopAllProgramRunner(t,r).then(n=>n(this.axios,this.basePath))}stopProgramRunner(t,r,n){return Xt(this.configuration).stopProgramRunner(t,r,n).then(a=>a(this.axios,this.basePath))}}const pE=function(e){return{clearProgramsValues:async(t,r={})=>{v("clearProgramsValues","cell",t);const n="/cells/{cell}/programs/values".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"DELETE",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},createProgramsValue:async(t,r,n={})=>{v("createProgramsValue","cell",t),v("createProgramsValue","requestBody",r);const a="/cells/{cell}/programs/values".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};j(i,e),await k(l,e),l["Content-Type"]="application/json",U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:L(o),options:i}},deleteProgramValue:async(t,r,n={})=>{v("deleteProgramValue","cell",t),v("deleteProgramValue","key",r);const a="/cells/{cell}/programs/values/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getProgramValue:async(t,r,n={})=>{v("getProgramValue","cell",t),v("getProgramValue","key",r);const a="/cells/{cell}/programs/values/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listProgramsValues:async(t,r={})=>{v("listProgramsValues","cell",t);const n="/cells/{cell}/programs/values".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},updateProgramValue:async(t,r,n,a={})=>{v("updateProgramValue","cell",t),v("updateProgramValue","key",r),v("updateProgramValue","value",n);const o="/cells/{cell}/programs/values/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}}}},Wr=function(e){const t=pE(e);return{async clearProgramsValues(r,n){var i,l;const a=await t.clearProgramsValues(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["ProgramValuesApi.clearProgramsValues"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async createProgramsValue(r,n,a){var l,c;const o=await t.createProgramsValue(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ProgramValuesApi.createProgramsValue"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async deleteProgramValue(r,n,a){var l,c;const o=await t.deleteProgramValue(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ProgramValuesApi.deleteProgramValue"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getProgramValue(r,n,a){var l,c;const o=await t.getProgramValue(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["ProgramValuesApi.getProgramValue"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listProgramsValues(r,n){var i,l;const a=await t.listProgramsValues(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["ProgramValuesApi.listProgramsValues"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async updateProgramValue(r,n,a,o){var c,u;const s=await t.updateProgramValue(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["ProgramValuesApi.updateProgramValue"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)}}};class mE extends Ve{clearProgramsValues(t,r){return Wr(this.configuration).clearProgramsValues(t,r).then(n=>n(this.axios,this.basePath))}createProgramsValue(t,r,n){return Wr(this.configuration).createProgramsValue(t,r,n).then(a=>a(this.axios,this.basePath))}deleteProgramValue(t,r,n){return Wr(this.configuration).deleteProgramValue(t,r,n).then(a=>a(this.axios,this.basePath))}getProgramValue(t,r,n){return Wr(this.configuration).getProgramValue(t,r,n).then(a=>a(this.axios,this.basePath))}listProgramsValues(t,r){return Wr(this.configuration).listProgramsValues(t,r).then(n=>n(this.axios,this.basePath))}updateProgramValue(t,r,n,a){return Wr(this.configuration).updateProgramValue(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const fE=function(e){return{deleteStoredCollider:async(t,r,n={})=>{v("deleteStoredCollider","cell",t),v("deleteStoredCollider","collider",r);const a="/cells/{cell}/store/collision/colliders/{collider}".replace("{cell}",encodeURIComponent(String(t))).replace("{collider}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},deleteStoredCollisionLinkChain:async(t,r,n={})=>{v("deleteStoredCollisionLinkChain","cell",t),v("deleteStoredCollisionLinkChain","linkChain",r);const a="/cells/{cell}/store/collision/link-chains/{link-chain}".replace("{cell}",encodeURIComponent(String(t))).replace("{link-chain}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},deleteStoredCollisionTool:async(t,r,n={})=>{v("deleteStoredCollisionTool","cell",t),v("deleteStoredCollisionTool","tool",r);const a="/cells/{cell}/store/collision/tools/{tool}".replace("{cell}",encodeURIComponent(String(t))).replace("{tool}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getDefaultLinkChain:async(t,r,n={})=>{v("getDefaultLinkChain","cell",t),v("getDefaultLinkChain","motionGroupModel",r);const a="/cells/{cell}/store/collision/default-link-chains/{motion-group-model}".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group-model}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getStoredCollider:async(t,r,n={})=>{v("getStoredCollider","cell",t),v("getStoredCollider","collider",r);const a="/cells/{cell}/store/collision/colliders/{collider}".replace("{cell}",encodeURIComponent(String(t))).replace("{collider}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getStoredCollisionLinkChain:async(t,r,n={})=>{v("getStoredCollisionLinkChain","cell",t),v("getStoredCollisionLinkChain","linkChain",r);const a="/cells/{cell}/store/collision/link-chains/{link-chain}".replace("{cell}",encodeURIComponent(String(t))).replace("{link-chain}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getStoredCollisionTool:async(t,r,n={})=>{v("getStoredCollisionTool","cell",t),v("getStoredCollisionTool","tool",r);const a="/cells/{cell}/store/collision/tools/{tool}".replace("{cell}",encodeURIComponent(String(t))).replace("{tool}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listCollisionLinkChains:async(t,r={})=>{v("listCollisionLinkChains","cell",t);const n="/cells/{cell}/store/collision/link-chains".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},listStoredColliders:async(t,r={})=>{v("listStoredColliders","cell",t);const n="/cells/{cell}/store/collision/colliders".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},listStoredCollisionTools:async(t,r={})=>{v("listStoredCollisionTools","cell",t);const n="/cells/{cell}/store/collision/tools".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},storeCollider:async(t,r,n,a={})=>{v("storeCollider","cell",t),v("storeCollider","collider",r),v("storeCollider","collider2",n);const o="/cells/{cell}/store/collision/colliders/{collider}".replace("{cell}",encodeURIComponent(String(t))).replace("{collider}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}},storeCollisionLinkChain:async(t,r,n,a={})=>{v("storeCollisionLinkChain","cell",t),v("storeCollisionLinkChain","linkChain",r),v("storeCollisionLinkChain","collider",n);const o="/cells/{cell}/store/collision/link-chains/{link-chain}".replace("{cell}",encodeURIComponent(String(t))).replace("{link-chain}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}},storeCollisionTool:async(t,r,n,a={})=>{v("storeCollisionTool","cell",t),v("storeCollisionTool","tool",r),v("storeCollisionTool","requestBody",n);const o="/cells/{cell}/store/collision/tools/{tool}".replace("{cell}",encodeURIComponent(String(t))).replace("{tool}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}}}},lt=function(e){const t=fE(e);return{async deleteStoredCollider(r,n,a){var l,c;const o=await t.deleteStoredCollider(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["StoreCollisionComponentsApi.deleteStoredCollider"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async deleteStoredCollisionLinkChain(r,n,a){var l,c;const o=await t.deleteStoredCollisionLinkChain(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["StoreCollisionComponentsApi.deleteStoredCollisionLinkChain"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async deleteStoredCollisionTool(r,n,a){var l,c;const o=await t.deleteStoredCollisionTool(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["StoreCollisionComponentsApi.deleteStoredCollisionTool"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getDefaultLinkChain(r,n,a){var l,c;const o=await t.getDefaultLinkChain(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["StoreCollisionComponentsApi.getDefaultLinkChain"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getStoredCollider(r,n,a){var l,c;const o=await t.getStoredCollider(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["StoreCollisionComponentsApi.getStoredCollider"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getStoredCollisionLinkChain(r,n,a){var l,c;const o=await t.getStoredCollisionLinkChain(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["StoreCollisionComponentsApi.getStoredCollisionLinkChain"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getStoredCollisionTool(r,n,a){var l,c;const o=await t.getStoredCollisionTool(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["StoreCollisionComponentsApi.getStoredCollisionTool"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listCollisionLinkChains(r,n){var i,l;const a=await t.listCollisionLinkChains(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["StoreCollisionComponentsApi.listCollisionLinkChains"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async listStoredColliders(r,n){var i,l;const a=await t.listStoredColliders(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["StoreCollisionComponentsApi.listStoredColliders"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async listStoredCollisionTools(r,n){var i,l;const a=await t.listStoredCollisionTools(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["StoreCollisionComponentsApi.listStoredCollisionTools"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async storeCollider(r,n,a,o){var c,u;const s=await t.storeCollider(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["StoreCollisionComponentsApi.storeCollider"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async storeCollisionLinkChain(r,n,a,o){var c,u;const s=await t.storeCollisionLinkChain(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["StoreCollisionComponentsApi.storeCollisionLinkChain"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async storeCollisionTool(r,n,a,o){var c,u;const s=await t.storeCollisionTool(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["StoreCollisionComponentsApi.storeCollisionTool"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)}}};class gE extends Ve{deleteStoredCollider(t,r,n){return lt(this.configuration).deleteStoredCollider(t,r,n).then(a=>a(this.axios,this.basePath))}deleteStoredCollisionLinkChain(t,r,n){return lt(this.configuration).deleteStoredCollisionLinkChain(t,r,n).then(a=>a(this.axios,this.basePath))}deleteStoredCollisionTool(t,r,n){return lt(this.configuration).deleteStoredCollisionTool(t,r,n).then(a=>a(this.axios,this.basePath))}getDefaultLinkChain(t,r,n){return lt(this.configuration).getDefaultLinkChain(t,r,n).then(a=>a(this.axios,this.basePath))}getStoredCollider(t,r,n){return lt(this.configuration).getStoredCollider(t,r,n).then(a=>a(this.axios,this.basePath))}getStoredCollisionLinkChain(t,r,n){return lt(this.configuration).getStoredCollisionLinkChain(t,r,n).then(a=>a(this.axios,this.basePath))}getStoredCollisionTool(t,r,n){return lt(this.configuration).getStoredCollisionTool(t,r,n).then(a=>a(this.axios,this.basePath))}listCollisionLinkChains(t,r){return lt(this.configuration).listCollisionLinkChains(t,r).then(n=>n(this.axios,this.basePath))}listStoredColliders(t,r){return lt(this.configuration).listStoredColliders(t,r).then(n=>n(this.axios,this.basePath))}listStoredCollisionTools(t,r){return lt(this.configuration).listStoredCollisionTools(t,r).then(n=>n(this.axios,this.basePath))}storeCollider(t,r,n,a){return lt(this.configuration).storeCollider(t,r,n,a).then(o=>o(this.axios,this.basePath))}storeCollisionLinkChain(t,r,n,a){return lt(this.configuration).storeCollisionLinkChain(t,r,n,a).then(o=>o(this.axios,this.basePath))}storeCollisionTool(t,r,n,a){return lt(this.configuration).storeCollisionTool(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const yE=function(e){return{deleteStoredCollisionScene:async(t,r,n={})=>{v("deleteStoredCollisionScene","cell",t),v("deleteStoredCollisionScene","scene",r);const a="/cells/{cell}/store/collision/scenes/{scene}".replace("{cell}",encodeURIComponent(String(t))).replace("{scene}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getStoredCollisionScene:async(t,r,n={})=>{v("getStoredCollisionScene","cell",t),v("getStoredCollisionScene","scene",r);const a="/cells/{cell}/store/collision/scenes/{scene}".replace("{cell}",encodeURIComponent(String(t))).replace("{scene}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listStoredCollisionScenes:async(t,r={})=>{v("listStoredCollisionScenes","cell",t);const n="/cells/{cell}/store/collision/scenes".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},storeCollisionScene:async(t,r,n,a={})=>{v("storeCollisionScene","cell",t),v("storeCollisionScene","scene",r),v("storeCollisionScene","collisionSceneAssembly",n);const o="/cells/{cell}/store/collision/scenes/{scene}".replace("{cell}",encodeURIComponent(String(t))).replace("{scene}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}}}},no=function(e){const t=yE(e);return{async deleteStoredCollisionScene(r,n,a){var l,c;const o=await t.deleteStoredCollisionScene(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["StoreCollisionScenesApi.deleteStoredCollisionScene"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getStoredCollisionScene(r,n,a){var l,c;const o=await t.getStoredCollisionScene(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["StoreCollisionScenesApi.getStoredCollisionScene"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listStoredCollisionScenes(r,n){var i,l;const a=await t.listStoredCollisionScenes(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["StoreCollisionScenesApi.listStoredCollisionScenes"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async storeCollisionScene(r,n,a,o){var c,u;const s=await t.storeCollisionScene(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["StoreCollisionScenesApi.storeCollisionScene"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)}}};class bE extends Ve{deleteStoredCollisionScene(t,r,n){return no(this.configuration).deleteStoredCollisionScene(t,r,n).then(a=>a(this.axios,this.basePath))}getStoredCollisionScene(t,r,n){return no(this.configuration).getStoredCollisionScene(t,r,n).then(a=>a(this.axios,this.basePath))}listStoredCollisionScenes(t,r){return no(this.configuration).listStoredCollisionScenes(t,r).then(n=>n(this.axios,this.basePath))}storeCollisionScene(t,r,n,a){return no(this.configuration).storeCollisionScene(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const vE=function(e){return{clearAllObjects:async(t,r={})=>{v("clearAllObjects","cell",t);const n="/cells/{cell}/store/objects".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"DELETE",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},deleteObject:async(t,r,n={})=>{v("deleteObject","cell",t),v("deleteObject","key",r);const a="/cells/{cell}/store/objects/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getObject:async(t,r,n={})=>{v("getObject","cell",t),v("getObject","key",r);const a="/cells/{cell}/store/objects/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getObjectMetadata:async(t,r,n={})=>{v("getObjectMetadata","cell",t),v("getObjectMetadata","key",r);const a="/cells/{cell}/store/objects/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"HEAD",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listAllObjectKeys:async(t,r={})=>{v("listAllObjectKeys","cell",t);const n="/cells/{cell}/store/objects".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},storeObject:async(t,r,n,a,o={})=>{v("storeObject","cell",t),v("storeObject","key",r);const s="/cells/{cell}/store/objects/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),i=new URL(s,$);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={},h=new(e&&e.formDataCtor||FormData);j(c,e),await k(u,e),a!==void 0&&h.append("AnyValue",new Blob([JSON.stringify(a)],{type:"application/json"})),u["Content-Type"]="multipart/form-data",n!=null&&(u["X-Metadata"]=typeof n=="string"?n:JSON.stringify(n)),U(i,d);let p=l&&l.headers?l.headers:{};return c.headers={...u,...p,...o.headers},c.data=h,{url:L(i),options:c}}}},Yr=function(e){const t=vE(e);return{async clearAllObjects(r,n){var i,l;const a=await t.clearAllObjects(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["StoreObjectApi.clearAllObjects"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async deleteObject(r,n,a){var l,c;const o=await t.deleteObject(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["StoreObjectApi.deleteObject"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getObject(r,n,a){var l,c;const o=await t.getObject(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["StoreObjectApi.getObject"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getObjectMetadata(r,n,a){var l,c;const o=await t.getObjectMetadata(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["StoreObjectApi.getObjectMetadata"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listAllObjectKeys(r,n){var i,l;const a=await t.listAllObjectKeys(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["StoreObjectApi.listAllObjectKeys"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async storeObject(r,n,a,o,s){var u,d;const i=await t.storeObject(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=M["StoreObjectApi.storeObject"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>D(i,R,I,e)(h,c||p)}}};class SE extends Ve{clearAllObjects(t,r){return Yr(this.configuration).clearAllObjects(t,r).then(n=>n(this.axios,this.basePath))}deleteObject(t,r,n){return Yr(this.configuration).deleteObject(t,r,n).then(a=>a(this.axios,this.basePath))}getObject(t,r,n){return Yr(this.configuration).getObject(t,r,n).then(a=>a(this.axios,this.basePath))}getObjectMetadata(t,r,n){return Yr(this.configuration).getObjectMetadata(t,r,n).then(a=>a(this.axios,this.basePath))}listAllObjectKeys(t,r){return Yr(this.configuration).listAllObjectKeys(t,r).then(n=>n(this.axios,this.basePath))}storeObject(t,r,n,a,o){return Yr(this.configuration).storeObject(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}}const xE=function(e){return{checkNovaVersionUpdate:async(t,r={})=>{v("checkNovaVersionUpdate","channel",t);const n="/system/update",a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};j(s,e),await k(i,e),t!==void 0&&(l.channel=t),U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:L(a),options:s}},getDiagnosePackage:async(t={})=>{const r="/system/diagnosis-package/zip",n=new URL(r,$);let a;e&&(a=e.baseOptions);const o={method:"GET",...a,...t},s={},i={};j(o,e),await k(s,e),U(n,i);let l=a&&a.headers?a.headers:{};return o.headers={...s,...l,...t.headers},{url:L(n),options:o}},getSystemStatus:async(t={})=>{const r="/system/status",n=new URL(r,$);let a;e&&(a=e.baseOptions);const o={method:"GET",...a,...t},s={},i={};j(o,e),await k(s,e),U(n,i);let l=a&&a.headers?a.headers:{};return o.headers={...s,...l,...t.headers},{url:L(n),options:o}},getSystemVersion:async(t={})=>{const r="/system/version",n=new URL(r,$);let a;e&&(a=e.baseOptions);const o={method:"GET",...a,...t},s={},i={};j(o,e),await k(s,e),U(n,i);let l=a&&a.headers?a.headers:{};return o.headers={...s,...l,...t.headers},{url:L(n),options:o}},updateNovaVersion:async(t,r={})=>{v("updateNovaVersion","updateNovaVersionRequest",t);const n="/system/update",a=new URL(n,$);let o;e&&(o=e.baseOptions);const s={method:"PUT",...o,...r},i={},l={};j(s,e),await k(i,e),i["Content-Type"]="application/json",U(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},s.data=ue(t,s,e),{url:L(a),options:s}}}},Wn=function(e){const t=xE(e);return{async checkNovaVersionUpdate(r,n){var i,l;const a=await t.checkNovaVersionUpdate(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["SystemApi.checkNovaVersionUpdate"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)},async getDiagnosePackage(r){var s,i;const n=await t.getDiagnosePackage(r),a=(e==null?void 0:e.serverIndex)??0,o=(i=(s=M["SystemApi.getDiagnosePackage"])==null?void 0:s[a])==null?void 0:i.url;return(l,c)=>D(n,R,I,e)(l,o||c)},async getSystemStatus(r){var s,i;const n=await t.getSystemStatus(r),a=(e==null?void 0:e.serverIndex)??0,o=(i=(s=M["SystemApi.getSystemStatus"])==null?void 0:s[a])==null?void 0:i.url;return(l,c)=>D(n,R,I,e)(l,o||c)},async getSystemVersion(r){var s,i;const n=await t.getSystemVersion(r),a=(e==null?void 0:e.serverIndex)??0,o=(i=(s=M["SystemApi.getSystemVersion"])==null?void 0:s[a])==null?void 0:i.url;return(l,c)=>D(n,R,I,e)(l,o||c)},async updateNovaVersion(r,n){var i,l;const a=await t.updateNovaVersion(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=M["SystemApi.updateNovaVersion"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>D(a,R,I,e)(c,s||u)}}};class OE extends Ve{checkNovaVersionUpdate(t,r){return Wn(this.configuration).checkNovaVersionUpdate(t,r).then(n=>n(this.axios,this.basePath))}getDiagnosePackage(t){return Wn(this.configuration).getDiagnosePackage(t).then(r=>r(this.axios,this.basePath))}getSystemStatus(t){return Wn(this.configuration).getSystemStatus(t).then(r=>r(this.axios,this.basePath))}getSystemVersion(t){return Wn(this.configuration).getSystemVersion(t).then(r=>r(this.axios,this.basePath))}updateNovaVersion(t,r){return Wn(this.configuration).updateNovaVersion(t,r).then(n=>n(this.axios,this.basePath))}}const wE=function(e){return{getMotionGroupState:async(t,r,n,a={})=>{v("getMotionGroupState","cell",t),v("getMotionGroupState","controller",r),v("getMotionGroupState","id",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},getMotionGroups:async(t,r,n={})=>{v("getMotionGroups","cell",t),v("getMotionGroups","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/motiongroups".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getVirtualRobotIOValue:async(t,r,n,a={})=>{v("getVirtualRobotIOValue","cell",t),v("getVirtualRobotIOValue","controller",r),v("getVirtualRobotIOValue","io",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/ios/{io}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{io}",encodeURIComponent(String(n))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},listIOs:async(t,r,n={})=>{v("listIOs","cell",t),v("listIOs","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/ios".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},setMotionGroupState:async(t,r,n,a,o={})=>{v("setMotionGroupState","cell",t),v("setMotionGroupState","controller",r),v("setMotionGroupState","id",n),v("setMotionGroupState","motionGroupJoints",a);const s="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),i=new URL(s,$);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={};j(c,e),await k(u,e),u["Content-Type"]="application/json",U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},c.data=ue(a,c,e),{url:L(i),options:c}},setVirtualRobotIOValue:async(t,r,n,a,o,s,i={})=>{v("setVirtualRobotIOValue","cell",t),v("setVirtualRobotIOValue","controller",r),v("setVirtualRobotIOValue","io",n);const l="/cells/{cell}/controllers/{controller}/teach-pendant/ios/{io}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{io}",encodeURIComponent(String(n))),c=new URL(l,$);let u;e&&(u=e.baseOptions);const d={method:"PUT",...u,...i},h={},p={};j(d,e),await k(h,e),a!==void 0&&(p.bool=a),o!==void 0&&(p.integer=o),s!==void 0&&(p.double=s),U(c,p);let f=u&&u.headers?u.headers:{};return d.headers={...h,...f,...i.headers},{url:L(c),options:d}}}},Kr=function(e){const t=wE(e);return{async getMotionGroupState(r,n,a,o){var c,u;const s=await t.getMotionGroupState(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["VirtualRobotApi.getMotionGroupState"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async getMotionGroups(r,n,a){var l,c;const o=await t.getMotionGroups(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["VirtualRobotApi.getMotionGroups"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getVirtualRobotIOValue(r,n,a,o){var c,u;const s=await t.getVirtualRobotIOValue(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["VirtualRobotApi.getVirtualRobotIOValue"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async listIOs(r,n,a){var l,c;const o=await t.listIOs(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["VirtualRobotApi.listIOs"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async setMotionGroupState(r,n,a,o,s){var u,d;const i=await t.setMotionGroupState(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=M["VirtualRobotApi.setMotionGroupState"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>D(i,R,I,e)(h,c||p)},async setVirtualRobotIOValue(r,n,a,o,s,i,l){var h,p;const c=await t.setVirtualRobotIOValue(r,n,a,o,s,i,l),u=(e==null?void 0:e.serverIndex)??0,d=(p=(h=M["VirtualRobotApi.setVirtualRobotIOValue"])==null?void 0:h[u])==null?void 0:p.url;return(f,m)=>D(c,R,I,e)(f,d||m)}}};class CE extends Ve{getMotionGroupState(t,r,n,a){return Kr(this.configuration).getMotionGroupState(t,r,n,a).then(o=>o(this.axios,this.basePath))}getMotionGroups(t,r,n){return Kr(this.configuration).getMotionGroups(t,r,n).then(a=>a(this.axios,this.basePath))}getVirtualRobotIOValue(t,r,n,a){return Kr(this.configuration).getVirtualRobotIOValue(t,r,n,a).then(o=>o(this.axios,this.basePath))}listIOs(t,r,n){return Kr(this.configuration).listIOs(t,r,n).then(a=>a(this.axios,this.basePath))}setMotionGroupState(t,r,n,a,o){return Kr(this.configuration).setMotionGroupState(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}setVirtualRobotIOValue(t,r,n,a,o,s,i){return Kr(this.configuration).setVirtualRobotIOValue(t,r,n,a,o,s,i).then(l=>l(this.axios,this.basePath))}}const PE=function(e){return{externalJointsStream:async(t,r,n,a={})=>{v("externalJointsStream","cell",t),v("externalJointsStream","controller",r),v("externalJointsStream","externalJointStreamDatapoint",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/externalJointsStream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}},getMotionGroupBehavior:async(t,r,n,a={})=>{v("getMotionGroupBehavior","cell",t),v("getMotionGroupBehavior","controller",r),v("getMotionGroupBehavior","id",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/behavior".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},setMotionGroupBehavior:async(t,r,n,a,o={})=>{v("setMotionGroupBehavior","cell",t),v("setMotionGroupBehavior","controller",r),v("setMotionGroupBehavior","id",n);const s="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/behavior".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),i=new URL(s,$);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={};j(c,e),await k(u,e),a!==void 0&&(d.behavior=a),U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},{url:L(i),options:c}}}},Vi=function(e){const t=PE(e);return{async externalJointsStream(r,n,a,o){var c,u;const s=await t.externalJointsStream(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["VirtualRobotBehaviorApi.externalJointsStream"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async getMotionGroupBehavior(r,n,a,o){var c,u;const s=await t.getMotionGroupBehavior(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["VirtualRobotBehaviorApi.getMotionGroupBehavior"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async setMotionGroupBehavior(r,n,a,o,s){var u,d;const i=await t.setMotionGroupBehavior(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=M["VirtualRobotBehaviorApi.setMotionGroupBehavior"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>D(i,R,I,e)(h,c||p)}}};class TE extends Ve{externalJointsStream(t,r,n,a){return Vi(this.configuration).externalJointsStream(t,r,n,a).then(o=>o(this.axios,this.basePath))}getMotionGroupBehavior(t,r,n,a){return Vi(this.configuration).getMotionGroupBehavior(t,r,n,a).then(o=>o(this.axios,this.basePath))}setMotionGroupBehavior(t,r,n,a,o){return Vi(this.configuration).setMotionGroupBehavior(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}}const AE=function(e){return{getCycleTime:async(t,r,n={})=>{v("getCycleTime","cell",t),v("getCycleTime","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/cycle-time".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getEStop:async(t,r,n={})=>{v("getEStop","cell",t),v("getEStop","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/estop".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},getOperationMode:async(t,r,n={})=>{v("getOperationMode","cell",t),v("getOperationMode","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/operationmode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},pushEStop:async(t,r,n={})=>{v("pushEStop","cell",t),v("pushEStop","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/estop/push".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},releaseEStop:async(t,r,n={})=>{v("releaseEStop","cell",t),v("releaseEStop","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/estop/release".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},setOperationMode:async(t,r,n,a={})=>{v("setOperationMode","cell",t),v("setOperationMode","controller",r),v("setOperationMode","mode",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/operationmode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),n!==void 0&&(u.mode=n),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}}}},Qr=function(e){const t=AE(e);return{async getCycleTime(r,n,a){var l,c;const o=await t.getCycleTime(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["VirtualRobotModeApi.getCycleTime"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getEStop(r,n,a){var l,c;const o=await t.getEStop(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["VirtualRobotModeApi.getEStop"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async getOperationMode(r,n,a){var l,c;const o=await t.getOperationMode(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["VirtualRobotModeApi.getOperationMode"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async pushEStop(r,n,a){var l,c;const o=await t.pushEStop(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["VirtualRobotModeApi.pushEStop"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async releaseEStop(r,n,a){var l,c;const o=await t.releaseEStop(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["VirtualRobotModeApi.releaseEStop"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async setOperationMode(r,n,a,o){var c,u;const s=await t.setOperationMode(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["VirtualRobotModeApi.setOperationMode"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)}}};class RE extends Ve{getCycleTime(t,r,n){return Qr(this.configuration).getCycleTime(t,r,n).then(a=>a(this.axios,this.basePath))}getEStop(t,r,n){return Qr(this.configuration).getEStop(t,r,n).then(a=>a(this.axios,this.basePath))}getOperationMode(t,r,n){return Qr(this.configuration).getOperationMode(t,r,n).then(a=>a(this.axios,this.basePath))}pushEStop(t,r,n){return Qr(this.configuration).pushEStop(t,r,n).then(a=>a(this.axios,this.basePath))}releaseEStop(t,r,n){return Qr(this.configuration).releaseEStop(t,r,n).then(a=>a(this.axios,this.basePath))}setOperationMode(t,r,n,a){return Qr(this.configuration).setOperationMode(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const VE=function(e){return{addVirtualRobotCoordinateSystem:async(t,r,n,a={})=>{v("addVirtualRobotCoordinateSystem","cell",t),v("addVirtualRobotCoordinateSystem","controller",r),v("addVirtualRobotCoordinateSystem","coordinateSystem",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};j(l,e),await k(c,e),c["Content-Type"]="application/json",U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:L(s),options:l}},addVirtualRobotTcp:async(t,r,n,a,o={})=>{v("addVirtualRobotTcp","cell",t),v("addVirtualRobotTcp","controller",r),v("addVirtualRobotTcp","id",n),v("addVirtualRobotTcp","robotTcp",a);const s="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/tcps".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),i=new URL(s,$);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={};j(c,e),await k(u,e),u["Content-Type"]="application/json",U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},c.data=ue(a,c,e),{url:L(i),options:c}},deleteVirtualRobotCoordinateSystem:async(t,r,n,a,o={})=>{v("deleteVirtualRobotCoordinateSystem","cell",t),v("deleteVirtualRobotCoordinateSystem","controller",r),v("deleteVirtualRobotCoordinateSystem","coordinateSystem",n);const s="/cells/{cell}/controllers/{controller}/teach-pendant/coordinate-systems/{coordinate-system}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{coordinate-system}",encodeURIComponent(String(n))),i=new URL(s,$);let l;e&&(l=e.baseOptions);const c={method:"DELETE",...l,...o},u={},d={};j(c,e),await k(u,e),a!==void 0&&(d.delete_dependent=a),U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},{url:L(i),options:c}},deleteVirtualRobotTcp:async(t,r,n,a,o={})=>{v("deleteVirtualRobotTcp","cell",t),v("deleteVirtualRobotTcp","controller",r),v("deleteVirtualRobotTcp","id",n),v("deleteVirtualRobotTcp","tcp",a);const s="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/tcps/{tcp}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))).replace("{tcp}",encodeURIComponent(String(a))),i=new URL(s,$);let l;e&&(l=e.baseOptions);const c={method:"DELETE",...l,...o},u={},d={};j(c,e),await k(u,e),U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},{url:L(i),options:c}},getVirtualRobotMounting:async(t,r,n,a={})=>{v("getVirtualRobotMounting","cell",t),v("getVirtualRobotMounting","controller",r),v("getVirtualRobotMounting","id",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/mounting".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},listVirtualRobotCoordinateSystems:async(t,r,n={})=>{v("listVirtualRobotCoordinateSystems","cell",t),v("listVirtualRobotCoordinateSystems","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,$);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};j(i,e),await k(l,e),U(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:L(o),options:i}},listVirtualRobotTcps:async(t,r,n,a={})=>{v("listVirtualRobotTcps","cell",t),v("listVirtualRobotTcps","controller",r),v("listVirtualRobotTcps","id",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/tcps".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),s=new URL(o,$);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};j(l,e),await k(c,e),U(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:L(s),options:l}},setVirtualRobotMounting:async(t,r,n,a,o={})=>{v("setVirtualRobotMounting","cell",t),v("setVirtualRobotMounting","controller",r),v("setVirtualRobotMounting","id",n),v("setVirtualRobotMounting","coordinateSystem",a);const s="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/mounting".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),i=new URL(s,$);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={};j(c,e),await k(u,e),u["Content-Type"]="application/json",U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},c.data=ue(a,c,e),{url:L(i),options:c}}}},Zt=function(e){const t=VE(e);return{async addVirtualRobotCoordinateSystem(r,n,a,o){var c,u;const s=await t.addVirtualRobotCoordinateSystem(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["VirtualRobotSetupApi.addVirtualRobotCoordinateSystem"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async addVirtualRobotTcp(r,n,a,o,s){var u,d;const i=await t.addVirtualRobotTcp(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=M["VirtualRobotSetupApi.addVirtualRobotTcp"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>D(i,R,I,e)(h,c||p)},async deleteVirtualRobotCoordinateSystem(r,n,a,o,s){var u,d;const i=await t.deleteVirtualRobotCoordinateSystem(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=M["VirtualRobotSetupApi.deleteVirtualRobotCoordinateSystem"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>D(i,R,I,e)(h,c||p)},async deleteVirtualRobotTcp(r,n,a,o,s){var u,d;const i=await t.deleteVirtualRobotTcp(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=M["VirtualRobotSetupApi.deleteVirtualRobotTcp"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>D(i,R,I,e)(h,c||p)},async getVirtualRobotMounting(r,n,a,o){var c,u;const s=await t.getVirtualRobotMounting(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["VirtualRobotSetupApi.getVirtualRobotMounting"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async listVirtualRobotCoordinateSystems(r,n,a){var l,c;const o=await t.listVirtualRobotCoordinateSystems(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=M["VirtualRobotSetupApi.listVirtualRobotCoordinateSystems"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>D(o,R,I,e)(u,i||d)},async listVirtualRobotTcps(r,n,a,o){var c,u;const s=await t.listVirtualRobotTcps(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=M["VirtualRobotSetupApi.listVirtualRobotTcps"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>D(s,R,I,e)(d,l||h)},async setVirtualRobotMounting(r,n,a,o,s){var u,d;const i=await t.setVirtualRobotMounting(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=M["VirtualRobotSetupApi.setVirtualRobotMounting"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>D(i,R,I,e)(h,c||p)}}};class _E extends Ve{addVirtualRobotCoordinateSystem(t,r,n,a){return Zt(this.configuration).addVirtualRobotCoordinateSystem(t,r,n,a).then(o=>o(this.axios,this.basePath))}addVirtualRobotTcp(t,r,n,a,o){return Zt(this.configuration).addVirtualRobotTcp(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}deleteVirtualRobotCoordinateSystem(t,r,n,a,o){return Zt(this.configuration).deleteVirtualRobotCoordinateSystem(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}deleteVirtualRobotTcp(t,r,n,a,o){return Zt(this.configuration).deleteVirtualRobotTcp(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}getVirtualRobotMounting(t,r,n,a){return Zt(this.configuration).getVirtualRobotMounting(t,r,n,a).then(o=>o(this.axios,this.basePath))}listVirtualRobotCoordinateSystems(t,r,n){return Zt(this.configuration).listVirtualRobotCoordinateSystems(t,r,n).then(a=>a(this.axios,this.basePath))}listVirtualRobotTcps(t,r,n,a){return Zt(this.configuration).listVirtualRobotTcps(t,r,n,a).then(o=>o(this.axios,this.basePath))}setVirtualRobotMounting(t,r,n,a,o){return Zt(this.configuration).setVirtualRobotMounting(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}}function Ut(e,t,r){return Math.max(t,Math.min(r,e))}class EE{constructor(t=0,r=0,n=0,a=1){this.isQuaternion=!0,this._x=t,this._y=r,this._z=n,this._w=a}static slerpFlat(t,r,n,a,o,s,i){let l=n[a+0],c=n[a+1],u=n[a+2],d=n[a+3];const h=o[s+0],p=o[s+1],f=o[s+2],m=o[s+3];if(i===0){t[r+0]=l,t[r+1]=c,t[r+2]=u,t[r+3]=d;return}if(i===1){t[r+0]=h,t[r+1]=p,t[r+2]=f,t[r+3]=m;return}if(d!==m||l!==h||c!==p||u!==f){let b=1-i;const x=l*h+c*p+u*f+d*m,V=x>=0?1:-1,O=1-x*x;if(O>Number.EPSILON){const P=Math.sqrt(O),w=Math.atan2(P,x*V);b=Math.sin(b*w)/P,i=Math.sin(i*w)/P}const C=i*V;if(l=l*b+h*C,c=c*b+p*C,u=u*b+f*C,d=d*b+m*C,b===1-i){const P=1/Math.sqrt(l*l+c*c+u*u+d*d);l*=P,c*=P,u*=P,d*=P}}t[r]=l,t[r+1]=c,t[r+2]=u,t[r+3]=d}static multiplyQuaternionsFlat(t,r,n,a,o,s){const i=n[a],l=n[a+1],c=n[a+2],u=n[a+3],d=o[s],h=o[s+1],p=o[s+2],f=o[s+3];return t[r]=i*f+u*d+l*p-c*h,t[r+1]=l*f+u*h+c*d-i*p,t[r+2]=c*f+u*p+i*h-l*d,t[r+3]=u*f-i*d-l*h-c*p,t}get x(){return this._x}set x(t){this._x=t,this._onChangeCallback()}get y(){return this._y}set y(t){this._y=t,this._onChangeCallback()}get z(){return this._z}set z(t){this._z=t,this._onChangeCallback()}get w(){return this._w}set w(t){this._w=t,this._onChangeCallback()}set(t,r,n,a){return this._x=t,this._y=r,this._z=n,this._w=a,this._onChangeCallback(),this}clone(){return new this.constructor(this._x,this._y,this._z,this._w)}copy(t){return this._x=t.x,this._y=t.y,this._z=t.z,this._w=t.w,this._onChangeCallback(),this}setFromEuler(t,r=!0){const n=t._x,a=t._y,o=t._z,s=t._order,i=Math.cos,l=Math.sin,c=i(n/2),u=i(a/2),d=i(o/2),h=l(n/2),p=l(a/2),f=l(o/2);switch(s){case"XYZ":this._x=h*u*d+c*p*f,this._y=c*p*d-h*u*f,this._z=c*u*f+h*p*d,this._w=c*u*d-h*p*f;break;case"YXZ":this._x=h*u*d+c*p*f,this._y=c*p*d-h*u*f,this._z=c*u*f-h*p*d,this._w=c*u*d+h*p*f;break;case"ZXY":this._x=h*u*d-c*p*f,this._y=c*p*d+h*u*f,this._z=c*u*f+h*p*d,this._w=c*u*d-h*p*f;break;case"ZYX":this._x=h*u*d-c*p*f,this._y=c*p*d+h*u*f,this._z=c*u*f-h*p*d,this._w=c*u*d+h*p*f;break;case"YZX":this._x=h*u*d+c*p*f,this._y=c*p*d+h*u*f,this._z=c*u*f-h*p*d,this._w=c*u*d-h*p*f;break;case"XZY":this._x=h*u*d-c*p*f,this._y=c*p*d-h*u*f,this._z=c*u*f+h*p*d,this._w=c*u*d+h*p*f;break;default:console.warn("THREE.Quaternion: .setFromEuler() encountered an unknown order: "+s)}return r===!0&&this._onChangeCallback(),this}setFromAxisAngle(t,r){const n=r/2,a=Math.sin(n);return this._x=t.x*a,this._y=t.y*a,this._z=t.z*a,this._w=Math.cos(n),this._onChangeCallback(),this}setFromRotationMatrix(t){const r=t.elements,n=r[0],a=r[4],o=r[8],s=r[1],i=r[5],l=r[9],c=r[2],u=r[6],d=r[10],h=n+i+d;if(h>0){const p=.5/Math.sqrt(h+1);this._w=.25/p,this._x=(u-l)*p,this._y=(o-c)*p,this._z=(s-a)*p}else if(n>i&&n>d){const p=2*Math.sqrt(1+n-i-d);this._w=(u-l)/p,this._x=.25*p,this._y=(a+s)/p,this._z=(o+c)/p}else if(i>d){const p=2*Math.sqrt(1+i-n-d);this._w=(o-c)/p,this._x=(a+s)/p,this._y=.25*p,this._z=(l+u)/p}else{const p=2*Math.sqrt(1+d-n-i);this._w=(s-a)/p,this._x=(o+c)/p,this._y=(l+u)/p,this._z=.25*p}return this._onChangeCallback(),this}setFromUnitVectors(t,r){let n=t.dot(r)+1;return n<Number.EPSILON?(n=0,Math.abs(t.x)>Math.abs(t.z)?(this._x=-t.y,this._y=t.x,this._z=0,this._w=n):(this._x=0,this._y=-t.z,this._z=t.y,this._w=n)):(this._x=t.y*r.z-t.z*r.y,this._y=t.z*r.x-t.x*r.z,this._z=t.x*r.y-t.y*r.x,this._w=n),this.normalize()}angleTo(t){return 2*Math.acos(Math.abs(Ut(this.dot(t),-1,1)))}rotateTowards(t,r){const n=this.angleTo(t);if(n===0)return this;const a=Math.min(1,r/n);return this.slerp(t,a),this}identity(){return this.set(0,0,0,1)}invert(){return this.conjugate()}conjugate(){return this._x*=-1,this._y*=-1,this._z*=-1,this._onChangeCallback(),this}dot(t){return this._x*t._x+this._y*t._y+this._z*t._z+this._w*t._w}lengthSq(){return this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w}length(){return Math.sqrt(this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w)}normalize(){let t=this.length();return t===0?(this._x=0,this._y=0,this._z=0,this._w=1):(t=1/t,this._x=this._x*t,this._y=this._y*t,this._z=this._z*t,this._w=this._w*t),this._onChangeCallback(),this}multiply(t){return this.multiplyQuaternions(this,t)}premultiply(t){return this.multiplyQuaternions(t,this)}multiplyQuaternions(t,r){const n=t._x,a=t._y,o=t._z,s=t._w,i=r._x,l=r._y,c=r._z,u=r._w;return this._x=n*u+s*i+a*c-o*l,this._y=a*u+s*l+o*i-n*c,this._z=o*u+s*c+n*l-a*i,this._w=s*u-n*i-a*l-o*c,this._onChangeCallback(),this}slerp(t,r){if(r===0)return this;if(r===1)return this.copy(t);const n=this._x,a=this._y,o=this._z,s=this._w;let i=s*t._w+n*t._x+a*t._y+o*t._z;if(i<0?(this._w=-t._w,this._x=-t._x,this._y=-t._y,this._z=-t._z,i=-i):this.copy(t),i>=1)return this._w=s,this._x=n,this._y=a,this._z=o,this;const l=1-i*i;if(l<=Number.EPSILON){const p=1-r;return this._w=p*s+r*this._w,this._x=p*n+r*this._x,this._y=p*a+r*this._y,this._z=p*o+r*this._z,this.normalize(),this}const c=Math.sqrt(l),u=Math.atan2(c,i),d=Math.sin((1-r)*u)/c,h=Math.sin(r*u)/c;return this._w=s*d+this._w*h,this._x=n*d+this._x*h,this._y=a*d+this._y*h,this._z=o*d+this._z*h,this._onChangeCallback(),this}slerpQuaternions(t,r,n){return this.copy(t).slerp(r,n)}random(){const t=2*Math.PI*Math.random(),r=2*Math.PI*Math.random(),n=Math.random(),a=Math.sqrt(1-n),o=Math.sqrt(n);return this.set(a*Math.sin(t),a*Math.cos(t),o*Math.sin(r),o*Math.cos(r))}equals(t){return t._x===this._x&&t._y===this._y&&t._z===this._z&&t._w===this._w}fromArray(t,r=0){return this._x=t[r],this._y=t[r+1],this._z=t[r+2],this._w=t[r+3],this._onChangeCallback(),this}toArray(t=[],r=0){return t[r]=this._x,t[r+1]=this._y,t[r+2]=this._z,t[r+3]=this._w,t}fromBufferAttribute(t,r){return this._x=t.getX(r),this._y=t.getY(r),this._z=t.getZ(r),this._w=t.getW(r),this._onChangeCallback(),this}toJSON(){return this.toArray()}_onChange(t){return this._onChangeCallback=t,this}_onChangeCallback(){}*[Symbol.iterator](){yield this._x,yield this._y,yield this._z,yield this._w}}class ln{constructor(t=0,r=0,n=0){ln.prototype.isVector3=!0,this.x=t,this.y=r,this.z=n}set(t,r,n){return n===void 0&&(n=this.z),this.x=t,this.y=r,this.z=n,this}setScalar(t){return this.x=t,this.y=t,this.z=t,this}setX(t){return this.x=t,this}setY(t){return this.y=t,this}setZ(t){return this.z=t,this}setComponent(t,r){switch(t){case 0:this.x=r;break;case 1:this.y=r;break;case 2:this.z=r;break;default:throw new Error("index is out of range: "+t)}return this}getComponent(t){switch(t){case 0:return this.x;case 1:return this.y;case 2:return this.z;default:throw new Error("index is out of range: "+t)}}clone(){return new this.constructor(this.x,this.y,this.z)}copy(t){return this.x=t.x,this.y=t.y,this.z=t.z,this}add(t){return this.x+=t.x,this.y+=t.y,this.z+=t.z,this}addScalar(t){return this.x+=t,this.y+=t,this.z+=t,this}addVectors(t,r){return this.x=t.x+r.x,this.y=t.y+r.y,this.z=t.z+r.z,this}addScaledVector(t,r){return this.x+=t.x*r,this.y+=t.y*r,this.z+=t.z*r,this}sub(t){return this.x-=t.x,this.y-=t.y,this.z-=t.z,this}subScalar(t){return this.x-=t,this.y-=t,this.z-=t,this}subVectors(t,r){return this.x=t.x-r.x,this.y=t.y-r.y,this.z=t.z-r.z,this}multiply(t){return this.x*=t.x,this.y*=t.y,this.z*=t.z,this}multiplyScalar(t){return this.x*=t,this.y*=t,this.z*=t,this}multiplyVectors(t,r){return this.x=t.x*r.x,this.y=t.y*r.y,this.z=t.z*r.z,this}applyEuler(t){return this.applyQuaternion(Wd.setFromEuler(t))}applyAxisAngle(t,r){return this.applyQuaternion(Wd.setFromAxisAngle(t,r))}applyMatrix3(t){const r=this.x,n=this.y,a=this.z,o=t.elements;return this.x=o[0]*r+o[3]*n+o[6]*a,this.y=o[1]*r+o[4]*n+o[7]*a,this.z=o[2]*r+o[5]*n+o[8]*a,this}applyNormalMatrix(t){return this.applyMatrix3(t).normalize()}applyMatrix4(t){const r=this.x,n=this.y,a=this.z,o=t.elements,s=1/(o[3]*r+o[7]*n+o[11]*a+o[15]);return this.x=(o[0]*r+o[4]*n+o[8]*a+o[12])*s,this.y=(o[1]*r+o[5]*n+o[9]*a+o[13])*s,this.z=(o[2]*r+o[6]*n+o[10]*a+o[14])*s,this}applyQuaternion(t){const r=this.x,n=this.y,a=this.z,o=t.x,s=t.y,i=t.z,l=t.w,c=2*(s*a-i*n),u=2*(i*r-o*a),d=2*(o*n-s*r);return this.x=r+l*c+s*d-i*u,this.y=n+l*u+i*c-o*d,this.z=a+l*d+o*u-s*c,this}project(t){return this.applyMatrix4(t.matrixWorldInverse).applyMatrix4(t.projectionMatrix)}unproject(t){return this.applyMatrix4(t.projectionMatrixInverse).applyMatrix4(t.matrixWorld)}transformDirection(t){const r=this.x,n=this.y,a=this.z,o=t.elements;return this.x=o[0]*r+o[4]*n+o[8]*a,this.y=o[1]*r+o[5]*n+o[9]*a,this.z=o[2]*r+o[6]*n+o[10]*a,this.normalize()}divide(t){return this.x/=t.x,this.y/=t.y,this.z/=t.z,this}divideScalar(t){return this.multiplyScalar(1/t)}min(t){return this.x=Math.min(this.x,t.x),this.y=Math.min(this.y,t.y),this.z=Math.min(this.z,t.z),this}max(t){return this.x=Math.max(this.x,t.x),this.y=Math.max(this.y,t.y),this.z=Math.max(this.z,t.z),this}clamp(t,r){return this.x=Ut(this.x,t.x,r.x),this.y=Ut(this.y,t.y,r.y),this.z=Ut(this.z,t.z,r.z),this}clampScalar(t,r){return this.x=Ut(this.x,t,r),this.y=Ut(this.y,t,r),this.z=Ut(this.z,t,r),this}clampLength(t,r){const n=this.length();return this.divideScalar(n||1).multiplyScalar(Ut(n,t,r))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this}roundToZero(){return this.x=Math.trunc(this.x),this.y=Math.trunc(this.y),this.z=Math.trunc(this.z),this}negate(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this}dot(t){return this.x*t.x+this.y*t.y+this.z*t.z}lengthSq(){return this.x*this.x+this.y*this.y+this.z*this.z}length(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)}normalize(){return this.divideScalar(this.length()||1)}setLength(t){return this.normalize().multiplyScalar(t)}lerp(t,r){return this.x+=(t.x-this.x)*r,this.y+=(t.y-this.y)*r,this.z+=(t.z-this.z)*r,this}lerpVectors(t,r,n){return this.x=t.x+(r.x-t.x)*n,this.y=t.y+(r.y-t.y)*n,this.z=t.z+(r.z-t.z)*n,this}cross(t){return this.crossVectors(this,t)}crossVectors(t,r){const n=t.x,a=t.y,o=t.z,s=r.x,i=r.y,l=r.z;return this.x=a*l-o*i,this.y=o*s-n*l,this.z=n*i-a*s,this}projectOnVector(t){const r=t.lengthSq();if(r===0)return this.set(0,0,0);const n=t.dot(this)/r;return this.copy(t).multiplyScalar(n)}projectOnPlane(t){return _i.copy(this).projectOnVector(t),this.sub(_i)}reflect(t){return this.sub(_i.copy(t).multiplyScalar(2*this.dot(t)))}angleTo(t){const r=Math.sqrt(this.lengthSq()*t.lengthSq());if(r===0)return Math.PI/2;const n=this.dot(t)/r;return Math.acos(Ut(n,-1,1))}distanceTo(t){return Math.sqrt(this.distanceToSquared(t))}distanceToSquared(t){const r=this.x-t.x,n=this.y-t.y,a=this.z-t.z;return r*r+n*n+a*a}manhattanDistanceTo(t){return Math.abs(this.x-t.x)+Math.abs(this.y-t.y)+Math.abs(this.z-t.z)}setFromSpherical(t){return this.setFromSphericalCoords(t.radius,t.phi,t.theta)}setFromSphericalCoords(t,r,n){const a=Math.sin(r)*t;return this.x=a*Math.sin(n),this.y=Math.cos(r)*t,this.z=a*Math.cos(n),this}setFromCylindrical(t){return this.setFromCylindricalCoords(t.radius,t.theta,t.y)}setFromCylindricalCoords(t,r,n){return this.x=t*Math.sin(r),this.y=n,this.z=t*Math.cos(r),this}setFromMatrixPosition(t){const r=t.elements;return this.x=r[12],this.y=r[13],this.z=r[14],this}setFromMatrixScale(t){const r=this.setFromMatrixColumn(t,0).length(),n=this.setFromMatrixColumn(t,1).length(),a=this.setFromMatrixColumn(t,2).length();return this.x=r,this.y=n,this.z=a,this}setFromMatrixColumn(t,r){return this.fromArray(t.elements,r*4)}setFromMatrix3Column(t,r){return this.fromArray(t.elements,r*3)}setFromEuler(t){return this.x=t._x,this.y=t._y,this.z=t._z,this}setFromColor(t){return this.x=t.r,this.y=t.g,this.z=t.b,this}equals(t){return t.x===this.x&&t.y===this.y&&t.z===this.z}fromArray(t,r=0){return this.x=t[r],this.y=t[r+1],this.z=t[r+2],this}toArray(t=[],r=0){return t[r]=this.x,t[r+1]=this.y,t[r+2]=this.z,t}fromBufferAttribute(t,r){return this.x=t.getX(r),this.y=t.getY(r),this.z=t.getZ(r),this}random(){return this.x=Math.random(),this.y=Math.random(),this.z=Math.random(),this}randomDirection(){const t=Math.random()*Math.PI*2,r=Math.random()*2-1,n=Math.sqrt(1-r*r);return this.x=n*Math.cos(t),this.y=r,this.z=n*Math.sin(t),this}*[Symbol.iterator](){yield this.x,yield this.y,yield this.z}}const _i=new ln,Wd=new EE;function IE(e){var t=[];if(e.length===0)return"";if(typeof e[0]!="string")throw new TypeError("Url must be a string. Received "+e[0]);if(e[0].match(/^[^/:]+:\/*$/)&&e.length>1){var r=e.shift();e[0]=r+e[0]}e[0].match(/^file:\/\/\//)?e[0]=e[0].replace(/^([^/:]+):\/*/,"$1:///"):e[0]=e[0].replace(/^([^/:]+):\/*/,"$1://");for(var n=0;n<e.length;n++){var a=e[n];if(typeof a!="string")throw new TypeError("Url must be a string. Received "+a);a!==""&&(n>0&&(a=a.replace(/^[\/]+/,"")),n<e.length-1?a=a.replace(/[\/]+$/,""):a=a.replace(/[\/]+$/,"/"),t.push(a))}var o=t.join("/");o=o.replace(/\/(\?|&|#[^!])/g,"$1");var s=o.split("?");return o=s.shift()+(s.length>0?"?":"")+s.join("&"),o}function Ei(){var e;return typeof arguments[0]=="object"?e=arguments[0]:e=[].slice.call(arguments),IE(e)}var Rt={},Yd;function ME(){if(Yd)return Rt;Yd=1,Object.defineProperty(Rt,"__esModule",{value:!0}),Rt.TokenData=void 0,Rt.parse=d,Rt.compile=h,Rt.match=m,Rt.pathToRegexp=b,Rt.stringify=C;const e="/",t=A=>A,r=/^[$_\p{ID_Start}]$/u,n=/^[$\u200c\u200d\p{ID_Continue}]$/u,a="https://git.new/pathToRegexpError",o={"{":"{","}":"}","(":"(",")":")","[":"[","]":"]","+":"+","?":"?","!":"!"};function s(A){return A.replace(/[{}()\[\]+?!:*]/g,"\\$&")}function i(A){return A.replace(/[.+*?^${}()[\]|/\\]/g,"\\$&")}function*l(A){const E=[...A];let F=0;function y(){let T="";if(r.test(E[++F]))for(T+=E[F];n.test(E[++F]);)T+=E[F];else if(E[F]==='"'){let z=F;for(;F<E.length;){if(E[++F]==='"'){F++,z=0;break}E[F]==="\\"?T+=E[++F]:T+=E[F]}if(z)throw new TypeError(`Unterminated quote at ${z}: ${a}`)}if(!T)throw new TypeError(`Missing parameter name at ${F}: ${a}`);return T}for(;F<E.length;){const T=E[F],z=o[T];if(z)yield{type:z,index:F++,value:T};else if(T==="\\")yield{type:"ESCAPED",index:F++,value:E[F++]};else if(T===":"){const _=y();yield{type:"PARAM",index:F,value:_}}else if(T==="*"){const _=y();yield{type:"WILDCARD",index:F,value:_}}else yield{type:"CHAR",index:F,value:E[F++]}}return{type:"END",index:F,value:""}}class c{constructor(E){this.tokens=E}peek(){if(!this._peek){const E=this.tokens.next();this._peek=E.value}return this._peek}tryConsume(E){const F=this.peek();if(F.type===E)return this._peek=void 0,F.value}consume(E){const F=this.tryConsume(E);if(F!==void 0)return F;const{type:y,index:T}=this.peek();throw new TypeError(`Unexpected ${y} at ${T}, expected ${E}: ${a}`)}text(){let E="",F;for(;F=this.tryConsume("CHAR")||this.tryConsume("ESCAPED");)E+=F;return E}}class u{constructor(E){this.tokens=E}}Rt.TokenData=u;function d(A,E={}){const{encodePath:F=t}=E,y=new c(l(A));function T(_){const N=[];for(;;){const te=y.text();te&&N.push({type:"text",value:F(te)});const Z=y.tryConsume("PARAM");if(Z){N.push({type:"param",name:Z});continue}const ae=y.tryConsume("WILDCARD");if(ae){N.push({type:"wildcard",name:ae});continue}if(y.tryConsume("{")){N.push({type:"group",tokens:T("}")});continue}return y.consume(_),N}}const z=T("END");return new u(z)}function h(A,E={}){const{encode:F=encodeURIComponent,delimiter:y=e}=E,T=A instanceof u?A:d(A,E),z=p(T.tokens,y,F);return function(N={}){const[te,...Z]=z(N);if(Z.length)throw new TypeError(`Missing parameters: ${Z.join(", ")}`);return te}}function p(A,E,F){const y=A.map(T=>f(T,E,F));return T=>{const z=[""];for(const _ of y){const[N,...te]=_(T);z[0]+=N,z.push(...te)}return z}}function f(A,E,F){if(A.type==="text")return()=>[A.value];if(A.type==="group"){const T=p(A.tokens,E,F);return z=>{const[_,...N]=T(z);return N.length?[""]:[_]}}const y=F||t;return A.type==="wildcard"&&F!==!1?T=>{const z=T[A.name];if(z==null)return["",A.name];if(!Array.isArray(z)||z.length===0)throw new TypeError(`Expected "${A.name}" to be a non-empty array`);return[z.map((_,N)=>{if(typeof _!="string")throw new TypeError(`Expected "${A.name}/${N}" to be a string`);return y(_)}).join(E)]}:T=>{const z=T[A.name];if(z==null)return["",A.name];if(typeof z!="string")throw new TypeError(`Expected "${A.name}" to be a string`);return[y(z)]}}function m(A,E={}){const{decode:F=decodeURIComponent,delimiter:y=e}=E,{regexp:T,keys:z}=b(A,E),_=z.map(N=>F===!1?t:N.type==="param"?F:te=>te.split(y).map(F));return function(te){const Z=T.exec(te);if(!Z)return!1;const ae=Z[0],re=Object.create(null);for(let le=1;le<Z.length;le++){if(Z[le]===void 0)continue;const q=z[le-1],X=_[le-1];re[q.name]=X(Z[le])}return{path:ae,params:re}}}function b(A,E={}){const{delimiter:F=e,end:y=!0,sensitive:T=!1,trailing:z=!0}=E,_=[],N=[],te=T?"":"i",ae=(Array.isArray(A)?A:[A]).map(q=>q instanceof u?q:d(q,E));for(const{tokens:q}of ae)for(const X of x(q,0,[])){const he=V(X,F,_);N.push(he)}let re=`^(?:${N.join("|")})`;return z&&(re+=`(?:${i(F)}$)?`),re+=y?"$":`(?=${i(F)}|$)`,{regexp:new RegExp(re,te),keys:_}}function*x(A,E,F){if(E===A.length)return yield F;const y=A[E];if(y.type==="group"){const T=F.slice();for(const z of x(y.tokens,0,T))yield*x(A,E+1,z)}else F.push(y);yield*x(A,E+1,F)}function V(A,E,F){let y="",T="",z=!0;for(let _=0;_<A.length;_++){const N=A[_];if(N.type==="text"){y+=i(N.value),T+=N.value,z||(z=N.value.includes(E));continue}if(N.type==="param"||N.type==="wildcard"){if(!z&&!T)throw new TypeError(`Missing text after "${N.name}": ${a}`);N.type==="param"?y+=`(${O(E,z?"":T)}+)`:y+="([\\s\\S]+)",F.push(N),T="",z=!1;continue}}return y}function O(A,E){return E.length<2?A.length<2?`[^${i(A+E)}]`:`(?:(?!${i(A)})[^${i(E)}])`:A.length<2?`(?:(?!${i(E)})[^${i(A)}])`:`(?:(?!${i(E)}|${i(A)})[\\s\\S])`}function C(A){return A.tokens.map(function E(F,y,T){if(F.type==="text")return s(F.value);if(F.type==="group")return`{${F.tokens.map(E).join("")}}`;const _=P(F.name)&&w(T[y+1])?F.name:JSON.stringify(F.name);if(F.type==="param")return`:${_}`;if(F.type==="wildcard")return`*${_}`;throw new TypeError(`Unexpected token: ${F}`)}).join("")}function P(A){const[E,...F]=A;return r.test(E)?F.every(y=>n.test(y)):!1}function w(A){return(A==null?void 0:A.type)!=="text"?!0:!n.test(A.value[0])}return Rt}var $E=ME();function pf(e,t,r){if(t.length!==e.length)return!0;for(let n=0;n<t.length;n++)if(Math.abs(t[n]-e[n])>r)return!1;return!0}function mf(e,t,r){if(e===void 0&&t||e&&t===void 0)return!1;if(e===void 0||t===void 0)return!0;let n=0;return n+=Math.abs(e.orientation.x-t.orientation.x),n+=Math.abs(e.orientation.y-t.orientation.y),n+=Math.abs(e.orientation.z-t.orientation.z),n+=Math.abs(e.position.x-t.position.x),n+=Math.abs(e.position.y-t.position.y),n+=Math.abs(e.position.z-t.position.z),n>r?!1:e.coordinate_system===t.coordinate_system&&e.tcp===t.tcp}var Kd=1e-4,jE=class ff{constructor(t,r,n,a,o,s,i,l,c,u,d,h){this.nova=t,this.controller=r,this.motionGroup=n,this.initialMotionState=a,this.motionStateSocket=o,this.isVirtual=s,this.tcps=i,this.motionGroupSpecification=l,this.safetySetup=c,this.mounting=u,this.initialControllerState=d,this.controllerStateSocket=h,this.connectedJoggingCartesianSocket=null,this.connectedJoggingJointsSocket=null,this.joggingVelocity=10,this.activationState="inactive",this.rapidlyChangingMotionState=a,this.controllerState=d,h.addEventListener("message",p=>{var f;const m=(f=nr(p.data))==null?void 0:f.result;m&&Be.runInAction(()=>{this.controllerState=m})}),o.addEventListener("message",p=>{var f;const m=(f=nr(p.data))==null?void 0:f.result;if(!m)throw new Error(`Failed to get motion state for ${this.motionGroupId}: ${p.data}`);pf(this.rapidlyChangingMotionState.state.joint_position.joints,m.state.joint_position.joints,Kd)||Be.runInAction(()=>{this.rapidlyChangingMotionState.state=m.state}),mf(this.rapidlyChangingMotionState.tcp_pose,m.tcp_pose,Kd)||Be.runInAction(()=>{this.rapidlyChangingMotionState.tcp_pose=m.tcp_pose})}),Be.makeAutoObservable(this)}static connect(t,r,n){return Re(this,null,function*(){var a,o;const[s,i]=r.split("@"),l=n.find(w=>w.controller===i),c=l==null?void 0:l.physical_motion_groups.find(w=>w.motion_group===r);if(!l||!c)throw new Error(`Controller ${i} or motion group ${r} not found`);const u=t.openReconnectingWebsocket(`/motion-groups/${r}/state-stream`),d=yield u.firstMessage(),h=(a=nr(d.data))==null?void 0:a.result;if(!h)throw new Error(`Unable to parse initial motion state message ${d.data}`);console.log(`Connected motion state websocket to motion group ${c.motion_group}. Initial state:
|
|
151
|
-
`,h);const f=(yield t.api.controller.getRobotController(l.controller)).configuration.kind==="VirtualController",m=yield
|
|
152
|
-
`,V);const{tcps:O}=yield t.api.motionGroupInfos.listTcps(r),C=yield t.api.motionGroupInfos.getMotionGroupSpecification(r),P=yield t.api.motionGroupInfos.getSafetySetup(r);return new ff(t,l,c,h,u,f,O,C,P,m,V,b)})}get motionGroupId(){return this.motionGroup.motion_group}get controllerId(){return this.controller.controller}get modelFromController(){return this.motionGroup.model_from_controller}get wandelscriptIdentifier(){const t=this.motionGroupId.split("@")[0];return`${this.controllerId.replaceAll("-","_")}_${t}`}get joggingVelocityRads(){return this.joggingVelocity*Math.PI/180}get joints(){return this.initialMotionState.state.joint_position.joints.map((t,r)=>({index:r}))}get dhParameters(){return this.motionGroupSpecification.dh_parameters}get safetyZones(){return this.safetySetup.safety_zones}get mountingPosition(){return this.mounting?[this.mounting.pose.position.x/1e3,this.mounting.pose.position.y/1e3,this.mounting.pose.position.z/1e3]:[0,0,0]}get mountingQuaternion(){var t,r,n,a,o,s;const i=new ke.Vector3(((r=(t=this.mounting)==null?void 0:t.pose.orientation)==null?void 0:r.x)||0,((a=(n=this.mounting)==null?void 0:n.pose.orientation)==null?void 0:a.y)||0,((s=(o=this.mounting)==null?void 0:o.pose.orientation)==null?void 0:s.z)||0),l=i.length(),c=i.normalize();return new ke.Quaternion().setFromAxisAngle(c,l)}get isEstopActive(){return["SAFETY_STATE_ROBOT_EMERGENCY_STOP","SAFETY_STATE_DEVICE_EMERGENCY_STOP"].includes(this.controllerState.safety_state)}get isMoveableSafetyState(){return["SAFETY_STATE_NORMAL","SAFETY_STATE_REDUCED"].includes(this.controllerState.safety_state)}get isMoveableOperationMode(){return["OPERATION_MODE_AUTO","OPERATION_MODE_MANUAL","OPERATION_MODE_MANUAL_T1","OPERATION_MODE_MANUAL_T2"].includes(this.controllerState.operation_mode)}get canBeMoved(){return this.isMoveableSafetyState&&this.isMoveableOperationMode&&this.activationState==="active"}deactivate(){return Re(this,null,function*(){if(this.activationState!=="active"){console.error("Tried to deactivate while already deactivating");return}Be.runInAction(()=>{this.activationState="deactivating"});try{yield this.nova.api.controller.setDefaultMode(this.controllerId,"MODE_MONITOR"),Be.runInAction(()=>{this.activationState="inactive"})}catch(t){throw Be.runInAction(()=>{this.activationState="active"}),t}})}activate(){return Re(this,null,function*(){if(this.activationState!=="inactive"){console.error("Tried to activate while already activating");return}Be.runInAction(()=>{this.activationState="activating"});try{yield this.nova.api.controller.setDefaultMode(this.controllerId,"MODE_CONTROL"),Be.runInAction(()=>{this.activationState="active"})}catch(t){throw Be.runInAction(()=>{this.activationState="inactive"}),t}})}toggleActivation(){this.activationState==="inactive"?this.activate():this.activationState==="active"&&this.deactivate()}dispose(){this.motionStateSocket.close(),this.connectedJoggingCartesianSocket&&this.connectedJoggingCartesianSocket.close(),this.connectedJoggingJointsSocket&&this.connectedJoggingJointsSocket.close()}setJoggingVelocity(t){this.joggingVelocity=t}},kE=class gf{constructor(t,r={}){this.motionStream=t,this.opts=r,this.cartesianWebsocket=null,this.jointWebsocket=null,this.cartesianJoggingOpts={}}static open(t,r){return Re(this,arguments,function*(n,a,o={}){const s=yield n.connectMotionStream(a);return new gf(s,o)})}get motionGroupId(){return this.motionStream.motionGroupId}get nova(){return this.motionStream.nova}get numJoints(){return this.motionStream.joints.length}get activeJoggingMode(){return this.cartesianWebsocket?"cartesian":this.jointWebsocket?"joint":"increment"}get activeWebsocket(){return this.cartesianWebsocket||this.jointWebsocket}stop(){return Re(this,null,function*(){this.cartesianWebsocket&&this.cartesianWebsocket.sendJson({motion_group:this.motionGroupId,position_direction:{x:0,y:0,z:0},rotation_direction:{x:0,y:0,z:0},position_velocity:0,rotation_velocity:0,tcp:this.cartesianJoggingOpts.tcpId,coordinate_system:this.cartesianJoggingOpts.coordSystemId}),this.jointWebsocket&&this.jointWebsocket.sendJson({motion_group:this.motionGroupId,joint_velocities:new Array(this.numJoints).fill(0)})})}dispose(){this.cartesianWebsocket&&this.cartesianWebsocket.dispose(),this.jointWebsocket&&this.jointWebsocket.dispose()}setJoggingMode(t,r){console.log("Setting jogging mode to",t),r&&(BR(this.cartesianJoggingOpts,r)||this.cartesianWebsocket&&(this.cartesianWebsocket.dispose(),this.cartesianWebsocket=null),this.cartesianJoggingOpts=r),t!=="cartesian"&&this.cartesianWebsocket&&(this.cartesianWebsocket.dispose(),this.cartesianWebsocket=null),t!=="joint"&&this.jointWebsocket&&(this.jointWebsocket.dispose(),this.jointWebsocket=null),t==="cartesian"&&!this.cartesianWebsocket&&(this.cartesianWebsocket=this.nova.openReconnectingWebsocket("/motion-groups/move-tcp"),this.cartesianWebsocket.addEventListener("message",n=>{const a=nr(n.data);if(a&&"error"in a)if(this.opts.onError)this.opts.onError(n.data);else throw new Error(n.data)})),t==="joint"&&!this.jointWebsocket&&(this.jointWebsocket=this.nova.openReconnectingWebsocket("/motion-groups/move-joint"),this.jointWebsocket.addEventListener("message",n=>{const a=nr(n.data);if(a&&"error"in a)if(this.opts.onError)this.opts.onError(n.data);else throw new Error(n.data)}))}startJointRotation(t){return Re(this,arguments,function*({joint:r,direction:n,velocityRadsPerSec:a}){if(!this.jointWebsocket)throw new Error("Joint jogging websocket not connected; call setJoggingMode first");const o=new Array(this.numJoints).fill(0);o[r]=n==="-"?-a:a,this.jointWebsocket.sendJson({motion_group:this.motionGroupId,joint_velocities:o})})}startTCPTranslation(t){return Re(this,arguments,function*({axis:r,direction:n,velocityMmPerSec:a}){if(!this.cartesianWebsocket)throw new Error("Cartesian jogging websocket not connected; call setJoggingMode first");const o={x:0,y:0,z:0},s=Object.assign({},o);s[r]=n==="-"?-1:1,this.cartesianWebsocket.sendJson({motion_group:this.motionGroupId,position_direction:s,rotation_direction:o,position_velocity:a,rotation_velocity:0,tcp:this.cartesianJoggingOpts.tcpId,coordinate_system:this.cartesianJoggingOpts.coordSystemId})})}startTCPRotation(t){return Re(this,arguments,function*({axis:r,direction:n,velocityRadsPerSec:a}){if(!this.cartesianWebsocket)throw new Error("Cartesian jogging websocket not connected; call setJoggingMode first");const o={x:0,y:0,z:0},s=Object.assign({},o);s[r]=n==="-"?-1:1,this.cartesianWebsocket.sendJson({motion_group:this.motionGroupId,position_direction:o,rotation_direction:s,position_velocity:0,rotation_velocity:a,tcp:this.cartesianJoggingOpts.tcpId,coordinate_system:this.cartesianJoggingOpts.coordSystemId})})}runIncrementalCartesianMotion(t){return Re(this,arguments,function*({currentTcpPose:r,currentJoints:n,coordSystemId:a,velocityInRelevantUnits:o,axis:s,direction:i,motion:l}){var c;const u=[];if(!rV(r.coordinate_system,a))throw new Error(`Current TCP pose coordinate system ${r.coordinate_system} does not match target coordinate system ${a}`);if(l.type==="translate"){const p=Object.assign({},r.position);p[s]+=l.distanceMm*(i==="-"?-1:1),u.push({settings:{limits_override:{tcp_velocity_limit:o}},line:{position:p,orientation:r.orientation,coordinate_system:a}})}else if(l.type==="rotate"){const p=new ln(r.orientation.x,r.orientation.y,r.orientation.z),f=p.length(),m=p.clone().normalize(),b=l.distanceRads*(i==="-"?-1:1),x=new ln(0,0,0);x[s]=1;const V=Math.cos(.5*b)*Math.cos(.5*f),O=Math.sin(.5*b)*Math.sin(.5*f),C=Math.sin(.5*b)*Math.cos(.5*f),P=Math.cos(.5*b)*Math.sin(.5*f),w=x.dot(m),A=x.clone().cross(m),E=2*Math.acos(V-O*w),F=E/Math.sin(.5*E),y=new ln().addScaledVector(A,O).addScaledVector(x,C).addScaledVector(m,P).multiplyScalar(F);u.push({settings:{limits_override:{tcp_orientation_velocity_limit:o}},line:{position:r.position,orientation:y,coordinate_system:a}})}const d=yield this.nova.api.motion.planMotion({motion_group:this.motionGroupId,start_joint_position:n,tcp:this.cartesianJoggingOpts.tcpId,commands:u}),h=(c=d.plan_successful_response)==null?void 0:c.motion;if(!h)throw new Error(`Failed to plan jogging increment motion ${JSON.stringify(d)}`);yield this.nova.api.motion.streamMoveForward(h,100,void 0,void 0,void 0,{timeout:1e3*60})})}runIncrementalJointRotation(t){return Re(this,arguments,function*({joint:r,currentJoints:n,velocityRadsPerSec:a,direction:o,distanceRads:s}){var i;const l=[...n.joints];l[r]+=s*(o==="-"?-1:1);const c=new Array(n.joints.length).fill(a),u=yield this.nova.api.motion.planMotion({motion_group:this.motionGroupId,start_joint_position:n,commands:[{settings:{limits_override:{joint_velocity_limits:{joints:c}}},joint_ptp:{joints:l}}]}),d=(i=u.plan_successful_response)==null?void 0:i.motion;if(!d){console.error("Failed to plan jogging increment motion",u);return}yield this.nova.api.motion.streamMoveForward(d,100,void 0,void 0,void 0,{timeout:1e3*60})})}},Qd=1e-4;function UE(e,t){const r=new vt.Vector3(t.x,t.y,t.z),n=new vt.Vector3(e.x,e.y,e.z),a=r.length(),o=r.normalize();let s=n.length(),i=n.normalize();i.dot(o)<0&&(s=-s,i=i.multiplyScalar(-1));let l=s-a;return l-=2*Math.PI*Math.floor((l+Math.PI)/(2*Math.PI)),s=a+l,i.multiplyScalar(s)}var LE=class yf{constructor(t,r,n,a,o){this.nova=t,this.controller=r,this.motionGroup=n,this.initialMotionState=a,this.motionStateSocket=o,this.rapidlyChangingMotionState=a,o.addEventListener("message",s=>{var i;const l=(i=nr(s.data))==null?void 0:i.result;if(!l)throw new Error(`Failed to get motion state for ${this.motionGroupId}: ${s.data}`);pf(this.rapidlyChangingMotionState.state.joint_position.joints,l.state.joint_position.joints,Qd)||Be.runInAction(()=>{this.rapidlyChangingMotionState.state=l.state}),mf(this.rapidlyChangingMotionState.tcp_pose,l.tcp_pose,Qd)||Be.runInAction(()=>{this.rapidlyChangingMotionState.tcp_pose==null?this.rapidlyChangingMotionState.tcp_pose=l.tcp_pose:this.rapidlyChangingMotionState.tcp_pose={position:l.tcp_pose.position,orientation:UE(l.tcp_pose.orientation,this.rapidlyChangingMotionState.tcp_pose.orientation),tcp:l.tcp_pose.tcp,coordinate_system:l.tcp_pose.coordinate_system}})}),Be.makeAutoObservable(this)}static open(t,r){return Re(this,null,function*(){var n;const{instances:a}=yield t.api.controller.listControllers(),[o,s]=r.split("@"),i=a.find(h=>h.controller===s),l=i==null?void 0:i.physical_motion_groups.find(h=>h.motion_group===r);if(!i||!l)throw new Error(`Controller ${s} or motion group ${r} not found`);const c=t.openReconnectingWebsocket(`/motion-groups/${r}/state-stream`),u=yield c.firstMessage();console.log("got first message",u);const d=(n=nr(u.data))==null?void 0:n.result;if(!d)throw new Error(`Unable to parse initial motion state message ${u.data}`);return console.log(`Connected motion state websocket to motion group ${l.motion_group}. Initial state:
|
|
153
|
-
`,d),new yf(t,i,l,d,c)})}get motionGroupId(){return this.motionGroup.motion_group}get controllerId(){return this.controller.controller}get modelFromController(){return this.motionGroup.model_from_controller}get wandelscriptIdentifier(){const t=this.motionGroupId.split("@")[0];return`${this.controllerId.replaceAll("-","_")}_${t}`}get joints(){return this.initialMotionState.state.joint_position.joints.map((t,r)=>({index:r}))}dispose(){this.motionStateSocket.close()}},DE=class{constructor(e,t){this.cellId=e,this.opts=t,this.system=this.withUnwrappedResponsesOnly(OE),this.cell=this.withUnwrappedResponsesOnly(L_),this.deviceConfig=this.withCellId(q_),this.motionGroup=this.withCellId(aE),this.motionGroupInfos=this.withCellId(sE),this.controller=this.withCellId(B_),this.program=this.withCellId(hE),this.programValues=this.withCellId(mE),this.controllerIOs=this.withCellId(F_),this.motionGroupKinematic=this.withCellId(uE),this.motion=this.withCellId(rE),this.coordinateSystems=this.withCellId(G_),this.application=this.withCellId(Jd),this.applicationGlobal=this.withUnwrappedResponsesOnly(Jd),this.motionGroupJogging=this.withCellId(lE),this.virtualRobot=this.withCellId(CE),this.virtualRobotSetup=this.withCellId(_E),this.virtualRobotMode=this.withCellId(RE),this.virtualRobotBehavior=this.withCellId(TE),this.libraryProgramMetadata=this.withCellId(K_),this.libraryProgram=this.withCellId(W_),this.libraryRecipeMetadata=this.withCellId(eE),this.libraryRecipe=this.withCellId(X_),this.storeObject=this.withCellId(SE),this.storeCollisionComponents=this.withCellId(gE),this.storeCollisionScenes=this.withCellId(bE)}withCellId(e){var t,r;const n=new e(ol(rn({},this.opts),{isJsonMime:a=>a==="application/json"}),(t=this.opts.basePath)!=null?t:"",(r=this.opts.axiosInstance)!=null?r:R.create());for(const a of Reflect.ownKeys(Reflect.getPrototypeOf(n)))if(a!=="constructor"&&typeof n[a]=="function"){const o=n[a];n[a]=(...s)=>o.apply(n,[this.cellId,...s]).then(i=>i.data)}return n}withUnwrappedResponsesOnly(e){var t,r;const n=new e(ol(rn({},this.opts),{isJsonMime:a=>a==="application/json"}),(t=this.opts.basePath)!=null?t:"",(r=this.opts.axiosInstance)!=null?r:R.create());for(const a of Reflect.ownKeys(Reflect.getPrototypeOf(n)))if(a!=="constructor"&&typeof n[a]=="function"){const o=n[a];n[a]=(...s)=>o.apply(n,s).then(i=>i.data)}return n}},BE=class{constructor(){this.connections=[]}handleAPIRequest(e){return Re(this,null,function*(){var t,r,n;const a=[{method:"GET",path:"/cells/:cellId/controllers",handle(){return{instances:[{controller:"mock-ur5e",model_name:"UniversalRobots::Controller",host:"mock-ur5e",allow_software_install_on_controller:!0,physical_motion_groups:[{motion_group:"0@mock-ur5e",name_from_controller:"UR5e",active:!1,model_from_controller:"UniversalRobots_UR5e"}],has_error:!1,error_details:""}]}}},{method:"GET",path:"/cells/:cellId/controllers/:controllerId",handle(){return{configuration:{kind:"VirtualController",manufacturer:"universalrobots",position:"[0,-1.571,-1.571,-1.571,1.571,-1.571,0]",type:"universalrobots-ur5e"},name:"mock-ur5"}}},{method:"GET",path:"/cells/:cellId/motion-groups/:motionGroupId/specification",handle(){return{dh_parameters:[{alpha:1.5707963267948966,theta:0,a:0,d:162.25,reverse_rotation_direction:!1},{alpha:0,theta:0,a:-425,d:0,reverse_rotation_direction:!1},{alpha:0,theta:0,a:-392.2,d:0,reverse_rotation_direction:!1},{alpha:1.5707963267948966,theta:0,a:0,d:133.3,reverse_rotation_direction:!1},{alpha:-1.5707963267948966,theta:0,a:0,d:99.7,reverse_rotation_direction:!1},{alpha:0,theta:0,a:0,d:99.6,reverse_rotation_direction:!1}],mechanical_joint_limits:[{joint:"JOINTNAME_AXIS_1",lower_limit:-6.335545063018799,upper_limit:6.335545063018799,unlimited:!1},{joint:"JOINTNAME_AXIS_2",lower_limit:-6.335545063018799,upper_limit:6.335545063018799,unlimited:!1},{joint:"JOINTNAME_AXIS_3",lower_limit:-6.335545063018799,upper_limit:6.335545063018799,unlimited:!1},{joint:"JOINTNAME_AXIS_4",lower_limit:-6.335545063018799,upper_limit:6.335545063018799,unlimited:!1},{joint:"JOINTNAME_AXIS_5",lower_limit:-6.335545063018799,upper_limit:6.335545063018799,unlimited:!1},{joint:"JOINTNAME_AXIS_6",lower_limit:-6.335545063018799,upper_limit:6.335545063018799,unlimited:!1}]}}},{method:"GET",path:"/cells/:cellId/motion-groups/:motionGroupId/safety-setup",handle(){return{safety_settings:[{safety_state:"SAFETY_NORMAL",settings:{joint_position_limits:[{joint:"JOINTNAME_AXIS_1",lower_limit:-2.96705961227417,upper_limit:2.96705961227417,unlimited:!1},{joint:"JOINTNAME_AXIS_2",lower_limit:-1.7453292608261108,upper_limit:2.7925267219543457,unlimited:!1},{joint:"JOINTNAME_AXIS_3",lower_limit:-3.3161256313323975,upper_limit:.40142571926116943,unlimited:!1},{joint:"JOINTNAME_AXIS_4",lower_limit:-3.4906585216522217,upper_limit:3.4906585216522217,unlimited:!1},{joint:"JOINTNAME_AXIS_5",lower_limit:-2.4434609413146973,upper_limit:2.4434609413146973,unlimited:!1},{joint:"JOINTNAME_AXIS_6",lower_limit:-4.71238899230957,upper_limit:4.71238899230957,unlimited:!1}],joint_velocity_limits:[{joint:"JOINTNAME_AXIS_1",limit:3.1415927410125732},{joint:"JOINTNAME_AXIS_2",limit:3.1415927410125732},{joint:"JOINTNAME_AXIS_3",limit:3.4906585216522217},{joint:"JOINTNAME_AXIS_4",limit:6.108652591705322},{joint:"JOINTNAME_AXIS_5",limit:6.108652591705322},{joint:"JOINTNAME_AXIS_6",limit:6.981317043304443}],joint_acceleration_limits:[],joint_torque_limits:[],tcp_velocity_limit:1800}}],safety_zones:[{id:1,priority:0,geometry:{compound:{child_geometries:[{convex_hull:{vertices:[{x:-800,y:-1330,z:-1820},{x:1650,y:-1330,z:-1820},{x:1650,y:1330,z:-1820},{x:-800,y:1330,z:-1820}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"box"},{convex_hull:{vertices:[{x:-800,y:-1330,z:-1820},{x:1650,y:-1330,z:-1820},{x:1650,y:-1330,z:1500},{x:-800,y:-1330,z:1500}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"box"},{convex_hull:{vertices:[{x:-800,y:-1330,z:-1820},{x:-800,y:1330,z:-1820},{x:-800,y:1330,z:1500},{x:-800,y:-1330,z:1500}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"box"},{convex_hull:{vertices:[{x:1650,y:1330,z:1500},{x:-800,y:1330,z:1500},{x:-800,y:-1330,z:1500},{x:1650,y:-1330,z:1500}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"box"},{convex_hull:{vertices:[{x:1650,y:1330,z:1500},{x:-800,y:1330,z:1500},{x:-800,y:1330,z:-1820},{x:1650,y:1330,z:-1820}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"box"},{convex_hull:{vertices:[{x:1650,y:1330,z:1500},{x:1650,y:-1330,z:1500},{x:1650,y:-1330,z:-1820},{x:1650,y:1330,z:-1820}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"box"}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"Cell workzone"},motion_group_uid:1},{id:2,priority:0,geometry:{convex_hull:{vertices:[{x:1650,y:1330,z:-1850},{x:865,y:1330,z:-1850},{x:865,y:-720,z:-1850},{x:1650,y:-720,z:-1850},{x:1650,y:1330,z:-920},{x:865,y:1330,z:-920},{x:865,y:-720,z:-920},{x:1650,y:-720,z:-920}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"Transport"},motion_group_uid:1},{id:3,priority:0,geometry:{convex_hull:{vertices:[{x:1650,y:1330,z:-600},{x:865,y:1330,z:-600},{x:865,y:430,z:-600},{x:1650,y:430,z:-600},{x:1650,y:1330,z:-1250},{x:865,y:1330,z:-1250},{x:865,y:430,z:-1250},{x:1650,y:430,z:-1250}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"Tunel"},motion_group_uid:1},{id:4,priority:0,geometry:{convex_hull:{vertices:[{x:1650,y:-760,z:-440},{x:900,y:-760,z:-440},{x:900,y:-1330,z:-440},{x:1650,y:-1330,z:-440},{x:1650,y:-760,z:-1800},{x:900,y:-760,z:-1800},{x:900,y:-1330,z:-1800},{x:1650,y:-1330,z:-1800}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"Fanuc controller"},motion_group_uid:1},{id:6,priority:0,geometry:{convex_hull:{vertices:[{x:-200,y:-200,z:-1900},{x:200,y:-200,z:-1900},{x:200,y:200,z:-1900},{x:-200,y:200,z:-1900},{x:-200,y:-200,z:-350},{x:200,y:-200,z:-350},{x:200,y:200,z:-350},{x:-200,y:200,z:-350}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"Robot base"},motion_group_uid:1}],robot_model_geometries:[{link_index:1,geometry:{sphere:{radius:270},init_pose:{position:{x:-70,y:-70,z:-50},orientation:{x:0,y:0,z:0,w:1}},id:"link1_sphere"}},{link_index:2,geometry:{capsule:{radius:160,cylinder_height:800},init_pose:{position:{x:-450,y:40,z:170},orientation:{x:0,y:-.7071067811865475,z:0,w:.7071067811865476}},id:"link2_capsule"}},{link_index:3,geometry:{sphere:{radius:270},init_pose:{position:{x:-110,y:10,z:-100},orientation:{x:0,y:0,z:0,w:1}},id:"link3_sphere"}},{link_index:4,geometry:{capsule:{radius:110,cylinder_height:600},init_pose:{position:{x:0,y:300,z:40},orientation:{x:-.7071067811865475,y:0,z:0,w:.7071067811865476}},id:"link4_capsule"}},{link_index:5,geometry:{sphere:{radius:75},init_pose:{position:{x:0,y:0,z:-50},orientation:{x:0,y:0,z:0,w:1}},id:"link5_sphere"}}],tool_geometries:[]}}},{method:"GET",path:"/cells/:cellId/coordinate-systems",handle(){return{coordinatesystems:[{coordinate_system:"",name:"world",reference_uid:"",position:{x:0,y:0,z:0},rotation:{angles:[0,0,0],type:"ROTATION_VECTOR"}}]}}},{method:"GET",path:"/cells/:cellId/motion-groups/:motionGroupId/tcps",handle(){return{tcps:[{id:"Flange",readable_name:"Default-Flange",position:{x:0,y:0,z:0},rotation:{angles:[0,0,0,0],type:"ROTATION_VECTOR"}},{id:"complex-tcp-position",readable_name:"Complex TCP Position",position:{x:-200,y:300,z:150},rotation:{angles:[-.12139440409113832,-.06356210998212003,-.2023240068185639,0],type:"ROTATION_VECTOR"}}]}}}],o=((t=e.method)==null?void 0:t.toUpperCase())||"GET",s="/cells"+((n=(r=e.url)==null?void 0:r.split("/cells")[1])==null?void 0:n.split("?")[0]);for(const i of a){const l=$E.match(i.path)(s||"");if(o===i.method&&l){const c=i.handle();return{status:200,statusText:"Success",data:JSON.stringify(c),headers:{},config:e,request:{responseURL:e.url}}}}throw new hl(`No mock handler matched this request: ${o} ${s}`,"404",e)})}handleWebsocketConnection(e){this.connections.push(e),setTimeout(()=>{e.dispatchEvent(new Event("open")),console.log("Websocket connection opened from",e.url),e.url.includes("/state-stream")&&e.dispatchEvent(new MessageEvent("message",{data:JSON.stringify(NE)})),e.url.includes("/move-joint")&&e.dispatchEvent(new MessageEvent("message",{data:JSON.stringify({result:{motion_group:"0@ur",state:{controller:"ur",operation_mode:"OPERATION_MODE_AUTO",safety_state:"SAFETY_STATE_NORMAL",timestamp:"2024-09-18T12:48:26.096266444Z",velocity_override:100,motion_groups:[{motion_group:"0@ur",controller:"ur",joint_position:{joints:[1.3492152690887451,-1.5659207105636597,1.6653711795806885,-1.0991662740707397,-1.829018235206604,1.264623761177063]},joint_velocity:{joints:[0,0,0,0,0,0]},flange_pose:{position:{x:6.437331889439328,y:-628.4123774830913,z:577.0569957147832},orientation:{x:-1.683333649797158,y:-1.9783363827298732,z:-.4928031860165713},coordinate_system:""},tcp_pose:{position:{x:6.437331889439328,y:-628.4123774830913,z:577.0569957147832},orientation:{x:-1.683333649797158,y:-1.9783363827298732,z:-.4928031860165713},coordinate_system:"",tcp:"Flange"},velocity:{linear:{x:0,y:0,z:0},angular:{x:-0,y:0,z:0},coordinate_system:""},force:{force:{x:0,y:0,z:0},moment:{x:0,y:0,z:0},coordinate_system:""},joint_limit_reached:{limit_reached:[!1,!1,!1,!1,!1,!1]},joint_current:{joints:[0,0,0,0,0,0]},sequence_number:"671259"}],sequence_number:"671259"},movement_state:"MOVEMENT_STATE_MOVING"}})})),e.url.includes("/move-tcp")&&e.dispatchEvent(new MessageEvent("message",{data:JSON.stringify({result:{motion_group:"0@ur",state:{controller:"ur",operation_mode:"OPERATION_MODE_AUTO",safety_state:"SAFETY_STATE_NORMAL",timestamp:"2024-09-18T12:43:12.188335774Z",velocity_override:100,motion_groups:[{motion_group:"0@ur",controller:"ur",joint_position:{joints:[1.3352527618408203,-1.5659207105636597,1.6653711795806885,-1.110615611076355,-1.829018235206604,1.264623761177063]},joint_velocity:{joints:[0,0,0,0,0,0]},flange_pose:{position:{x:-2.763015284002938,y:-630.2151479701106,z:577.524509114342},orientation:{x:-1.704794877102097,y:-1.9722372952861567,z:-.4852079204210754},coordinate_system:""},tcp_pose:{position:{x:-2.763015284002938,y:-630.2151479701106,z:577.524509114342},orientation:{x:-1.704794877102097,y:-1.9722372952861567,z:-.4852079204210754},coordinate_system:"",tcp:"Flange"},velocity:{linear:{x:0,y:0,z:0},angular:{x:-0,y:0,z:0},coordinate_system:""},force:{force:{x:0,y:0,z:0},moment:{x:0,y:0,z:0},coordinate_system:""},joint_limit_reached:{limit_reached:[!1,!1,!1,!1,!1,!1]},joint_current:{joints:[0,0,0,0,0,0]},sequence_number:"627897"}],sequence_number:"627897"},movement_state:"MOVEMENT_STATE_MOVING"}})}))},10)}handleWebsocketMessage(e,t){console.log(`Received message on ${e.url}`,t)}},NE={result:{state:{motion_group:"0@universalrobots-ur5e",controller:"universalrobots-ur5e",joint_position:{joints:[1.1699999570846558,-1.5700000524520874,1.3600000143051147,1.0299999713897705,1.2899999618530273,1.2799999713897705]},joint_velocity:{joints:[0,0,0,0,0,0]},flange_pose:{position:{x:1.3300010259703043,y:-409.2680714682808,z:531.0203477065281},orientation:{x:1.7564919306270736,y:-1.7542521568325058,z:.7326972590614671},coordinate_system:""},tcp_pose:{position:{x:1.3300010259703043,y:-409.2680714682808,z:531.0203477065281},orientation:{x:1.7564919306270736,y:-1.7542521568325058,z:.7326972590614671},coordinate_system:"",tcp:"Flange"},velocity:{linear:{x:0,y:0,z:0},angular:{x:0,y:0,z:0},coordinate_system:""},force:{force:{x:0,y:0,z:0},moment:{x:0,y:0,z:0},coordinate_system:""},joint_limit_reached:{limit_reached:[!1,!1,!1,!1,!1,!1]},joint_current:{joints:[0,0,0,0,0,0]},sequence_number:"1"},tcp_pose:{position:{x:302.90748476115556,y:-152.87065869452337,z:424.0454619321661},orientation:{x:2.3403056115045353,y:-1.1706836379431356,z:.9772511964246311},coordinate_system:"",tcp:"Flange"}}},FE=class{constructor(e){this.authPromise=null,this.accessToken=null;var t;const r=(t=e.cellId)!=null?t:"cell";this.config=rn({cellId:r},e),this.accessToken=e.accessToken||Ci.getString("wbjs.access_token")||null,this.config.instanceUrl==="https://mock.example.com"&&(this.mock=new BE);const n=R.create({baseURL:Ei(this.config.instanceUrl,"/api/v1"),headers:{"User-Agent":"Wandelbots-Nova-JS-SDK"}});n.interceptors.request.use(a=>Re(this,null,function*(){return a.headers.Authorization||(this.accessToken?a.headers.Authorization=`Bearer ${this.accessToken}`:this.config.username&&this.config.password&&(a.headers.Authorization=`Basic ${btoa(e.username+":"+e.password)}`)),a})),typeof window<"u"&&n.interceptors.response.use(a=>a,a=>Re(this,null,function*(){var o,s;if($_(a))if(((o=a.response)==null?void 0:o.status)===401)try{if(yield this.renewAuthentication(),a.config)return this.accessToken?a.config.headers.Authorization=`Bearer ${this.accessToken}`:delete a.config.headers.Authorization,n.request(a.config)}catch(i){return Promise.reject(i)}else((s=a.response)==null?void 0:s.status)===503&&(yield fetch(window.location.href)).status===503&&window.location.reload();return Promise.reject(a)})),this.api=new DE(r,ol(rn({},e),{basePath:Ei(this.config.instanceUrl,"/api/v1"),isJsonMime:a=>a==="application/json",baseOptions:rn(rn({},this.mock?{adapter:a=>this.mock.handleAPIRequest(a)}:{}),e.baseOptions),axiosInstance:n}))}renewAuthentication(){return Re(this,null,function*(){if(!this.authPromise){this.authPromise=aV(this.config.instanceUrl);try{this.accessToken=yield this.authPromise,this.accessToken?Ci.setString("wbjs.access_token",this.accessToken):Ci.delete("wbjs.access_token")}finally{this.authPromise=null}}})}makeWebsocketURL(e){const t=new URL(Ei(this.config.instanceUrl,`/api/v1/cells/${this.config.cellId}`,e));return t.protocol=t.protocol.replace("http","ws"),t.protocol=t.protocol.replace("https","wss"),this.accessToken?t.searchParams.append("token",this.accessToken):this.config.username&&this.config.password&&(t.username=this.config.username,t.password=this.config.password),t.toString()}openReconnectingWebsocket(e){return new eV(this.makeWebsocketURL(e),{mock:this.mock})}connectMotionStream(e){return Re(this,null,function*(){return yield LE.open(this,e)})}connectJogger(e){return Re(this,null,function*(){return yield kE.open(this,e)})}connectMotionGroups(e){return Re(this,null,function*(){const{instances:t}=yield this.api.controller.listControllers();return Promise.all(e.map(r=>jE.connect(this,r,t)))})}connectMotionGroup(e){return Re(this,null,function*(){return(yield this.connectMotionGroups([e]))[0]})}};function zE(e){try{return JSON.stringify(e)}catch{return}}function GE(e,t){throw new Error(t+` ${JSON.stringify(e)}`)}function HE(e){var t,r,n,a;return e instanceof hl&&e.code==="ERR_NETWORK"?"Failed to connect to the server. Please check your internet connection.":e instanceof hl&&e.response?`${(t=e.response)==null?void 0:t.status} ${(r=e.response)==null?void 0:r.statusText} from ${(n=e.response)==null?void 0:n.config.url}: ${JSON.stringify((a=e.response)==null?void 0:a.data)}`:e instanceof Error?e.message:`Unexpected error: ${zE(e)||e}`}const fc=e=>{const t=e.softTimeout||3e3,[r,n]=ee.useState(!1),a=J.useTheme();return ee.useEffect(()=>{const o=setTimeout(()=>{n(!0)},t);return()=>clearTimeout(o)}),S.jsx(J.Stack,{width:"100%",height:"100%",alignItems:"center",justifyContent:"center",sx:{color:a.palette.text.primary},children:e.error?S.jsx(bf,{loadingMessage:e.message,error:e.error}):S.jsxs(S.Fragment,{children:[S.jsx(J.CircularProgress,{sx:{marginBottom:"24px"}}),!!e.message&&S.jsx("div",{children:e.message}),S.jsx(J.Stack,{sx:{visibility:r?"visible":"hidden",marginTop:"1rem",color:a.palette.text.secondary},children:"This is taking longer than expected..."})]})})},bf=e=>{const t=HE(e.error),r=e.error instanceof Error?e.error.stack:null,n=J.useTheme();return S.jsxs(J.Stack,{sx:{maxHeight:"100%",maxWidth:"min(100%, 800px)",padding:2,overflow:"auto",color:n.palette.error.main,"& pre":{whiteSpace:"pre-wrap",wordBreak:"break-word",paddingBottom:"3rem"}},children:[(e.loadingMessage?`Error while ${Sl.lowerFirst(J.capitalize(e.loadingMessage))} - `:"")+t,S.jsx("br",{}),r&&S.jsx("pre",{children:r})]})},qE=({title:e,titleId:t,...r},n)=>B.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:19,height:10,fill:"none",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.createElement("path",{fill:"#fff",fillRule:"evenodd",d:"M5.131.312a.9.9 0 0 1 0 1.272L3.07 3.645h12.44l-2.06-2.061A.9.9 0 0 1 14.72.313l3.596 3.596a.9.9 0 0 1 0 1.271l-3.596 3.597a.9.9 0 0 1-1.271-1.272l2.061-2.062H3.07L5.13 7.505A.9.9 0 0 1 3.86 8.777L.263 5.18a.9.9 0 0 1 0-1.271L3.86.312a.9.9 0 0 1 1.271 0",clipRule:"evenodd"})),JE=ee.forwardRef(qE),WE=({title:e,titleId:t,...r},n)=>B.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:19,height:10,fill:"none",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.createElement("path",{fill:"#fff",fillRule:"evenodd",d:"M5.131.312a.9.9 0 0 1 0 1.272L3.07 3.645h12.44l-2.06-2.061A.9.9 0 0 1 14.72.313l3.596 3.596a.9.9 0 0 1 0 1.271l-3.596 3.597a.9.9 0 0 1-1.271-1.272l2.061-2.062H3.07L5.13 7.505A.9.9 0 0 1 3.86 8.777L.263 5.18a.9.9 0 0 1 0-1.271L3.86.312a.9.9 0 0 1 1.271 0",clipRule:"evenodd"})),YE=ee.forwardRef(WE),KE=({title:e,titleId:t,...r},n)=>B.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:10,height:19,fill:"none",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.createElement("path",{fill:"#fff",fillRule:"evenodd",d:"M9.522 14.811A.899.899 0 1 0 8.25 13.54L6.19 15.601V3.16L8.25 5.221A.9.9 0 0 0 9.522 3.95L5.926.354a.9.9 0 0 0-1.272 0L1.058 3.95a.9.9 0 1 0 1.271 1.271L4.391 3.16v12.442L2.329 13.54a.899.899 0 1 0-1.271 1.271l3.596 3.597a.9.9 0 0 0 1.272 0z",clipRule:"evenodd"})),QE=ee.forwardRef(KE),XE=({title:e,titleId:t,...r},n)=>B.createElement("svg",{width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.createElement("path",{d:"M8 16C5.76667 16 3.875 15.225 2.325 13.675C0.775 12.125 0 10.2333 0 8C0 5.76667 0.775 3.875 2.325 2.325C3.875 0.775 5.76667 0 8 0C9.15 0 10.25 0.2375 11.3 0.7125C12.35 1.1875 13.25 1.86667 14 2.75V0H16V7H9V5H13.2C12.6667 4.06667 11.9375 3.33333 11.0125 2.8C10.0875 2.26667 9.08333 2 8 2C6.33333 2 4.91667 2.58333 3.75 3.75C2.58333 4.91667 2 6.33333 2 8C2 9.66667 2.58333 11.0833 3.75 12.25C4.91667 13.4167 6.33333 14 8 14C9.28333 14 10.4417 13.6333 11.475 12.9C11.0583 14.1 12.5083 12.1667 11.475 12.9L12.9 14.325C11.4667 15.4417 9.83333 16 8 16Z",fill:"white"})),ZE=ee.forwardRef(XE);function eI(){this.__data__=[],this.size=0}function vf(e,t){return e===t||e!==e&&t!==t}function ks(e,t){for(var r=e.length;r--;)if(vf(e[r][0],t))return r;return-1}var tI=Array.prototype,rI=tI.splice;function nI(e){var t=this.__data__,r=ks(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():rI.call(t,r,1),--this.size,!0}function aI(e){var t=this.__data__,r=ks(t,e);return r<0?void 0:t[r][1]}function oI(e){return ks(this.__data__,e)>-1}function sI(e,t){var r=this.__data__,n=ks(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}function Wt(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Wt.prototype.clear=eI;Wt.prototype.delete=nI;Wt.prototype.get=aI;Wt.prototype.has=oI;Wt.prototype.set=sI;function iI(){this.__data__=new Wt,this.size=0}function lI(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function cI(e){return this.__data__.get(e)}function uI(e){return this.__data__.has(e)}var dI="[object AsyncFunction]",hI="[object Function]",pI="[object GeneratorFunction]",mI="[object Proxy]";function Sf(e){if(!wr(e))return!1;var t=Mr(e);return t==hI||t==pI||t==dI||t==mI}var Ii=$t["__core-js_shared__"],Xd=function(){var e=/[^.]+$/.exec(Ii&&Ii.keys&&Ii.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function fI(e){return!!Xd&&Xd in e}var gI=Function.prototype,yI=gI.toString;function jr(e){if(e!=null){try{return yI.call(e)}catch{}try{return e+""}catch{}}return""}var bI=/[\\^$.*+?()[\]{}|]/g,vI=/^\[object .+?Constructor\]$/,SI=Function.prototype,xI=Object.prototype,OI=SI.toString,wI=xI.hasOwnProperty,CI=RegExp("^"+OI.call(wI).replace(bI,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function PI(e){if(!wr(e)||fI(e))return!1;var t=Sf(e)?CI:vI;return t.test(jr(e))}function TI(e,t){return e==null?void 0:e[t]}function kr(e,t){var r=TI(e,t);return PI(r)?r:void 0}var ya=kr($t,"Map"),ba=kr(Object,"create");function AI(){this.__data__=ba?ba(null):{},this.size=0}function RI(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var VI="__lodash_hash_undefined__",_I=Object.prototype,EI=_I.hasOwnProperty;function II(e){var t=this.__data__;if(ba){var r=t[e];return r===VI?void 0:r}return EI.call(t,e)?t[e]:void 0}var MI=Object.prototype,$I=MI.hasOwnProperty;function jI(e){var t=this.__data__;return ba?t[e]!==void 0:$I.call(t,e)}var kI="__lodash_hash_undefined__";function UI(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=ba&&t===void 0?kI:t,this}function Tr(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Tr.prototype.clear=AI;Tr.prototype.delete=RI;Tr.prototype.get=II;Tr.prototype.has=jI;Tr.prototype.set=UI;function LI(){this.size=0,this.__data__={hash:new Tr,map:new(ya||Wt),string:new Tr}}function DI(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Us(e,t){var r=e.__data__;return DI(t)?r[typeof t=="string"?"string":"hash"]:r.map}function BI(e){var t=Us(this,e).delete(e);return this.size-=t?1:0,t}function NI(e){return Us(this,e).get(e)}function FI(e){return Us(this,e).has(e)}function zI(e,t){var r=Us(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}function Yt(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Yt.prototype.clear=LI;Yt.prototype.delete=BI;Yt.prototype.get=NI;Yt.prototype.has=FI;Yt.prototype.set=zI;var GI=200;function HI(e,t){var r=this.__data__;if(r instanceof Wt){var n=r.__data__;if(!ya||n.length<GI-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new Yt(n)}return r.set(e,t),this.size=r.size,this}function Bt(e){var t=this.__data__=new Wt(e);this.size=t.size}Bt.prototype.clear=iI;Bt.prototype.delete=lI;Bt.prototype.get=cI;Bt.prototype.has=uI;Bt.prototype.set=HI;var qI="__lodash_hash_undefined__";function JI(e){return this.__data__.set(e,qI),this}function WI(e){return this.__data__.has(e)}function Jo(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new Yt;++t<r;)this.add(e[t])}Jo.prototype.add=Jo.prototype.push=JI;Jo.prototype.has=WI;function YI(e,t){for(var r=-1,n=e==null?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}function KI(e,t){return e.has(t)}var QI=1,XI=2;function xf(e,t,r,n,a,o){var s=r&QI,i=e.length,l=t.length;if(i!=l&&!(s&&l>i))return!1;var c=o.get(e),u=o.get(t);if(c&&u)return c==t&&u==e;var d=-1,h=!0,p=r&XI?new Jo:void 0;for(o.set(e,t),o.set(t,e);++d<i;){var f=e[d],m=t[d];if(n)var b=s?n(m,f,d,t,e,o):n(f,m,d,e,t,o);if(b!==void 0){if(b)continue;h=!1;break}if(p){if(!YI(t,function(x,V){if(!KI(p,V)&&(f===x||a(f,x,r,n,o)))return p.push(V)})){h=!1;break}}else if(!(f===m||a(f,m,r,n,o))){h=!1;break}}return o.delete(e),o.delete(t),h}var Zd=$t.Uint8Array;function ZI(e){var t=-1,r=Array(e.size);return e.forEach(function(n,a){r[++t]=[a,n]}),r}function e2(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var t2=1,r2=2,n2="[object Boolean]",a2="[object Date]",o2="[object Error]",s2="[object Map]",i2="[object Number]",l2="[object RegExp]",c2="[object Set]",u2="[object String]",d2="[object Symbol]",h2="[object ArrayBuffer]",p2="[object DataView]",eh=ir?ir.prototype:void 0,Mi=eh?eh.valueOf:void 0;function m2(e,t,r,n,a,o,s){switch(r){case p2:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case h2:return!(e.byteLength!=t.byteLength||!o(new Zd(e),new Zd(t)));case n2:case a2:case i2:return vf(+e,+t);case o2:return e.name==t.name&&e.message==t.message;case l2:case u2:return e==t+"";case s2:var i=ZI;case c2:var l=n&t2;if(i||(i=e2),e.size!=t.size&&!l)return!1;var c=s.get(e);if(c)return c==t;n|=r2,s.set(e,t);var u=xf(i(e),i(t),n,a,o,s);return s.delete(e),u;case d2:if(Mi)return Mi.call(e)==Mi.call(t)}return!1}function f2(e,t){for(var r=-1,n=t.length,a=e.length;++r<n;)e[a+r]=t[r];return e}var Mt=Array.isArray;function g2(e,t,r){var n=t(e);return Mt(e)?n:f2(n,r(e))}function y2(e,t){for(var r=-1,n=e==null?0:e.length,a=0,o=[];++r<n;){var s=e[r];t(s,r,e)&&(o[a++]=s)}return o}function b2(){return[]}var v2=Object.prototype,S2=v2.propertyIsEnumerable,th=Object.getOwnPropertySymbols,x2=th?function(e){return e==null?[]:(e=Object(e),y2(th(e),function(t){return S2.call(e,t)}))}:b2;function O2(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var w2="[object Arguments]";function rh(e){return Cr(e)&&Mr(e)==w2}var Of=Object.prototype,C2=Of.hasOwnProperty,P2=Of.propertyIsEnumerable,wf=rh(function(){return arguments}())?rh:function(e){return Cr(e)&&C2.call(e,"callee")&&!P2.call(e,"callee")};function T2(){return!1}var Cf=typeof exports=="object"&&exports&&!exports.nodeType&&exports,nh=Cf&&typeof module=="object"&&module&&!module.nodeType&&module,A2=nh&&nh.exports===Cf,ah=A2?$t.Buffer:void 0,R2=ah?ah.isBuffer:void 0,ml=R2||T2,V2=9007199254740991,_2=/^(?:0|[1-9]\d*)$/;function Pf(e,t){var r=typeof e;return t=t??V2,!!t&&(r=="number"||r!="symbol"&&_2.test(e))&&e>-1&&e%1==0&&e<t}var E2=9007199254740991;function gc(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=E2}var I2="[object Arguments]",M2="[object Array]",$2="[object Boolean]",j2="[object Date]",k2="[object Error]",U2="[object Function]",L2="[object Map]",D2="[object Number]",B2="[object Object]",N2="[object RegExp]",F2="[object Set]",z2="[object String]",G2="[object WeakMap]",H2="[object ArrayBuffer]",q2="[object DataView]",J2="[object Float32Array]",W2="[object Float64Array]",Y2="[object Int8Array]",K2="[object Int16Array]",Q2="[object Int32Array]",X2="[object Uint8Array]",Z2="[object Uint8ClampedArray]",eM="[object Uint16Array]",tM="[object Uint32Array]",Ae={};Ae[J2]=Ae[W2]=Ae[Y2]=Ae[K2]=Ae[Q2]=Ae[X2]=Ae[Z2]=Ae[eM]=Ae[tM]=!0;Ae[I2]=Ae[M2]=Ae[H2]=Ae[$2]=Ae[q2]=Ae[j2]=Ae[k2]=Ae[U2]=Ae[L2]=Ae[D2]=Ae[B2]=Ae[N2]=Ae[F2]=Ae[z2]=Ae[G2]=!1;function rM(e){return Cr(e)&&gc(e.length)&&!!Ae[Mr(e)]}function nM(e){return function(t){return e(t)}}var Tf=typeof exports=="object"&&exports&&!exports.nodeType&&exports,ra=Tf&&typeof module=="object"&&module&&!module.nodeType&&module,aM=ra&&ra.exports===Tf,$i=aM&&Cm.process,oh=function(){try{var e=ra&&ra.require&&ra.require("util").types;return e||$i&&$i.binding&&$i.binding("util")}catch{}}(),sh=oh&&oh.isTypedArray,Af=sh?nM(sh):rM,oM=Object.prototype,sM=oM.hasOwnProperty;function iM(e,t){var r=Mt(e),n=!r&&wf(e),a=!r&&!n&&ml(e),o=!r&&!n&&!a&&Af(e),s=r||n||a||o,i=s?O2(e.length,String):[],l=i.length;for(var c in e)sM.call(e,c)&&!(s&&(c=="length"||a&&(c=="offset"||c=="parent")||o&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||Pf(c,l)))&&i.push(c);return i}var lM=Object.prototype;function cM(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||lM;return e===r}function uM(e,t){return function(r){return e(t(r))}}var dM=uM(Object.keys,Object),hM=Object.prototype,pM=hM.hasOwnProperty;function mM(e){if(!cM(e))return dM(e);var t=[];for(var r in Object(e))pM.call(e,r)&&r!="constructor"&&t.push(r);return t}function Rf(e){return e!=null&&gc(e.length)&&!Sf(e)}function yc(e){return Rf(e)?iM(e):mM(e)}function ih(e){return g2(e,yc,x2)}var fM=1,gM=Object.prototype,yM=gM.hasOwnProperty;function bM(e,t,r,n,a,o){var s=r&fM,i=ih(e),l=i.length,c=ih(t),u=c.length;if(l!=u&&!s)return!1;for(var d=l;d--;){var h=i[d];if(!(s?h in t:yM.call(t,h)))return!1}var p=o.get(e),f=o.get(t);if(p&&f)return p==t&&f==e;var m=!0;o.set(e,t),o.set(t,e);for(var b=s;++d<l;){h=i[d];var x=e[h],V=t[h];if(n)var O=s?n(V,x,h,t,e,o):n(x,V,h,e,t,o);if(!(O===void 0?x===V||a(x,V,r,n,o):O)){m=!1;break}b||(b=h=="constructor")}if(m&&!b){var C=e.constructor,P=t.constructor;C!=P&&"constructor"in e&&"constructor"in t&&!(typeof C=="function"&&C instanceof C&&typeof P=="function"&&P instanceof P)&&(m=!1)}return o.delete(e),o.delete(t),m}var fl=kr($t,"DataView"),gl=kr($t,"Promise"),yl=kr($t,"Set"),bl=kr($t,"WeakMap"),lh="[object Map]",vM="[object Object]",ch="[object Promise]",uh="[object Set]",dh="[object WeakMap]",hh="[object DataView]",SM=jr(fl),xM=jr(ya),OM=jr(gl),wM=jr(yl),CM=jr(bl),tr=Mr;(fl&&tr(new fl(new ArrayBuffer(1)))!=hh||ya&&tr(new ya)!=lh||gl&&tr(gl.resolve())!=ch||yl&&tr(new yl)!=uh||bl&&tr(new bl)!=dh)&&(tr=function(e){var t=Mr(e),r=t==vM?e.constructor:void 0,n=r?jr(r):"";if(n)switch(n){case SM:return hh;case xM:return lh;case OM:return ch;case wM:return uh;case CM:return dh}return t});var PM=1,ph="[object Arguments]",mh="[object Array]",ao="[object Object]",TM=Object.prototype,fh=TM.hasOwnProperty;function AM(e,t,r,n,a,o){var s=Mt(e),i=Mt(t),l=s?mh:tr(e),c=i?mh:tr(t);l=l==ph?ao:l,c=c==ph?ao:c;var u=l==ao,d=c==ao,h=l==c;if(h&&ml(e)){if(!ml(t))return!1;s=!0,u=!1}if(h&&!u)return o||(o=new Bt),s||Af(e)?xf(e,t,r,n,a,o):m2(e,t,l,r,n,a,o);if(!(r&PM)){var p=u&&fh.call(e,"__wrapped__"),f=d&&fh.call(t,"__wrapped__");if(p||f){var m=p?e.value():e,b=f?t.value():t;return o||(o=new Bt),a(m,b,r,n,o)}}return h?(o||(o=new Bt),bM(e,t,r,n,a,o)):!1}function Ls(e,t,r,n,a){return e===t?!0:e==null||t==null||!Cr(e)&&!Cr(t)?e!==e&&t!==t:AM(e,t,r,n,Ls,a)}function RM(e,t){return Ls(e,t)}const Vf=({store:e})=>{const{t}=Ie.useTranslation(),[r,n]=ee.useState(e.jogger.motionStream.rapidlyChangingMotionState.state.joint_limit_reached.limit_reached),a=ee.useRef(r);xn(()=>{const s=e.jogger.motionStream.rapidlyChangingMotionState.state.joint_limit_reached.limit_reached;RM(a.current,s)||(a.current=s,n(s))});const o=[];for(const[s,i]of r.entries())i&&o.push(s);return S.jsx(J.Typography,{color:"error",sx:{margin:"0.5rem 1rem",textAlign:"center",minHeight:"1.5rem",visibility:o.length?"visible":"hidden"},children:t("Jogging.JointLimitsReached.lb",{jointNumbers:o.map(s=>s+1).join(", ")})})},VM=J.styled(J.FormControl)(({theme:e})=>({"&.MuiFormControl-root":{".MuiSelect-select":{paddingTop:"20px",paddingLeft:"12px"},label:{pointerEvents:"none",fontSize:"16px"},".MuiInputLabel-root":{"&.Mui-focused":{color:e.palette.text.primary}}}}));function oo({labelValue:e,...t}){return S.jsxs(VM,{fullWidth:!0,variant:"filled",children:[S.jsx(J.InputLabel,{id:t.labelId,children:e}),S.jsx(J.Select,{...t})]})}var gh=function(){try{var e=kr(Object,"defineProperty");return e({},"",{}),e}catch{}}();function _M(e,t,r){t=="__proto__"&&gh?gh(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function EM(e,t,r,n){for(var a=-1,o=e==null?0:e.length;++a<o;){var s=e[a];t(n,s,r(s),e)}return n}function IM(e){return function(t,r,n){for(var a=-1,o=Object(t),s=n(t),i=s.length;i--;){var l=s[++a];if(r(o[l],l,o)===!1)break}return t}}var MM=IM();function $M(e,t){return e&&MM(e,t,yc)}function jM(e,t){return function(r,n){if(r==null)return r;if(!Rf(r))return e(r,n);for(var a=r.length,o=-1,s=Object(r);++o<a&&n(s[o],o,s)!==!1;);return r}}var kM=jM($M);function UM(e,t,r,n){return kM(e,function(a,o,s){t(n,a,r(a),s)}),n}var LM=1,DM=2;function BM(e,t,r,n){var a=r.length,o=a;if(e==null)return!o;for(e=Object(e);a--;){var s=r[a];if(s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++a<o;){s=r[a];var i=s[0],l=e[i],c=s[1];if(s[2]){if(l===void 0&&!(i in e))return!1}else{var u=new Bt,d;if(!(d===void 0?Ls(c,l,LM|DM,n,u):d))return!1}}return!0}function _f(e){return e===e&&!wr(e)}function NM(e){for(var t=yc(e),r=t.length;r--;){var n=t[r],a=e[n];t[r]=[n,a,_f(a)]}return t}function Ef(e,t){return function(r){return r==null?!1:r[e]===t&&(t!==void 0||e in Object(r))}}function FM(e){var t=NM(e);return t.length==1&&t[0][2]?Ef(t[0][0],t[0][1]):function(r){return r===e||BM(r,e,t)}}var zM=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,GM=/^\w*$/;function bc(e,t){if(Mt(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||Ts(e)?!0:GM.test(e)||!zM.test(e)||t!=null&&e in Object(t)}var HM="Expected a function";function vc(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(HM);var r=function(){var n=arguments,a=t?t.apply(this,n):n[0],o=r.cache;if(o.has(a))return o.get(a);var s=e.apply(this,n);return r.cache=o.set(a,s)||o,s};return r.cache=new(vc.Cache||Yt),r}vc.Cache=Yt;var qM=500;function JM(e){var t=vc(e,function(n){return r.size===qM&&r.clear(),n}),r=t.cache;return t}var WM=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,YM=/\\(\\)?/g,KM=JM(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(WM,function(r,n,a,o){t.push(a?o.replace(YM,"$1"):n||r)}),t});function QM(e,t){for(var r=-1,n=e==null?0:e.length,a=Array(n);++r<n;)a[r]=t(e[r],r,e);return a}var yh=ir?ir.prototype:void 0,bh=yh?yh.toString:void 0;function If(e){if(typeof e=="string")return e;if(Mt(e))return QM(e,If)+"";if(Ts(e))return bh?bh.call(e):"";var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function Mf(e){return e==null?"":If(e)}function $f(e,t){return Mt(e)?e:bc(e,t)?[e]:KM(Mf(e))}function Ds(e){if(typeof e=="string"||Ts(e))return e;var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function jf(e,t){t=$f(t,e);for(var r=0,n=t.length;e!=null&&r<n;)e=e[Ds(t[r++])];return r&&r==n?e:void 0}function XM(e,t,r){var n=e==null?void 0:jf(e,t);return n===void 0?r:n}function ZM(e,t){return e!=null&&t in Object(e)}function e5(e,t,r){t=$f(t,e);for(var n=-1,a=t.length,o=!1;++n<a;){var s=Ds(t[n]);if(!(o=e!=null&&r(e,s)))break;e=e[s]}return o||++n!=a?o:(a=e==null?0:e.length,!!a&&gc(a)&&Pf(s,a)&&(Mt(e)||wf(e)))}function t5(e,t){return e!=null&&e5(e,t,ZM)}var r5=1,n5=2;function a5(e,t){return bc(e)&&_f(t)?Ef(Ds(e),t):function(r){var n=XM(r,e);return n===void 0&&n===t?t5(r,e):Ls(t,n,r5|n5)}}function o5(e){return e}function s5(e){return function(t){return t==null?void 0:t[e]}}function i5(e){return function(t){return jf(t,e)}}function l5(e){return bc(e)?s5(Ds(e)):i5(e)}function c5(e){return typeof e=="function"?e:e==null?o5:typeof e=="object"?Mt(e)?a5(e[0],e[1]):FM(e):l5(e)}function u5(e,t){return function(r,n){var a=Mt(r)?EM:UM,o={};return a(r,e,c5(n),o)}}var so=u5(function(e,t,r){_M(e,r,t)}),d5=0;function h5(e){var t=++d5;return Mf(e)+t}const vl=[{id:"0.1",mm:.1,degrees:.05},{id:"1",mm:1,degrees:.5},{id:"5",mm:5,degrees:2.5},{id:"10",mm:10,degrees:5}],p5=[{id:"continuous"},...vl],m5=["coordsys","tool"];class Bs{constructor(t,r,n,a){var o,s;this.jogger=t,this.motionGroupSpec=r,this.coordSystems=n,this.tcps=a,this.selectedTabId="cartesian",this.activationState="inactive",this.activationError=null,this.activationCounter=0,this.locks=new Set,this.selectedCoordSystemId="world",this.selectedTcpId="",this.selectedOrientation="coordsys",this.selectedIncrementId="continuous",this.selectedCartesianMotionType="translate",this.incrementJogInProgress=null,this.translationVelocityMmPerSec=10,this.rotationVelocityDegPerSec=1,this.minTranslationVelocityMmPerSec=5,this.maxTranslationVelocityMmPerSec=250,this.minRotationVelocityDegPerSec=1,this.maxRotationVelocityDegPerSec=60,this.showCoordSystemSelect=!0,this.showTcpSelect=!0,this.showOrientationSelect=!0,this.showIncrementSelect=!0,this.showTabIcons=!1,this.showVelocitySliderLabel=!0,this.showVelocityLegend=!1,this.showJointsLegend=!1,this.disposers=[];for(const i of n)if(i.coordinate_system===""){i.coordinate_system="world";break}this.selectedCoordSystemId=((o=n[0])==null?void 0:o.coordinate_system)||"world",this.selectedTcpId=((s=a[0])==null?void 0:s.id)||"",Be.makeAutoObservable(this,{},{autoBind:!0}),this.loadFromLocalStorage(),this.disposers.push(Be.autorun(()=>this.saveToLocalStorage())),window.joggingStore=this}static async loadFor(t){const{nova:r}=t,[n,{coordinatesystems:a},{tcps:o}]=await Promise.all([r.api.motionGroupInfos.getMotionGroupSpecification(t.motionGroupId),r.api.coordinateSystems.listCoordinateSystems("ROTATION_VECTOR"),r.api.motionGroupInfos.listTcps(t.motionGroupId,"ROTATION_VECTOR")]);return new Bs(t,n,a||[],o||[])}dispose(){for(const t of this.disposers)t();this.jogger.dispose()}get coordSystemCountByName(){return Sl.countBy(this.coordSystems,t=>t.name)}async deactivate(){const t=this.jogger.activeWebsocket;this.jogger.setJoggingMode("increment"),t&&await t.closed()}async activate(){if(this.currentTab.id==="cartesian"){const t={tcpId:this.selectedTcpId,coordSystemId:this.activeCoordSystemId};this.activeDiscreteIncrement?this.jogger.setJoggingMode("increment",t):this.jogger.setJoggingMode("cartesian",t)}else this.jogger.setJoggingMode("joint");return this.jogger}loadFromLocalStorage(){const t=br.tryParseJson(localStorage.getItem("joggingToolStore"));t&&(this.tabsById[t.selectedTabId]&&(this.selectedTabId=t.selectedTabId),this.coordSystemsById[t.selectedCoordSystemId]&&(this.selectedCoordSystemId=t.selectedCoordSystemId),this.tcpsById[t.selectedTcpId]&&(this.selectedTcpId=t.selectedTcpId),this.incrementOptionsById[t.selectedIncrementId]&&(this.selectedIncrementId=t.selectedIncrementId),["translate","rotate"].includes(t.selectedCartesianMotionType)&&(this.selectedCartesianMotionType=t.selectedCartesianMotionType),["coordsys","tool"].includes(t.selectedOrientation)&&(this.selectedOrientation=t.selectedOrientation))}saveToLocalStorage(){localStorage.setItem("joggingToolStore",JSON.stringify(this.localStorageSave))}get isLocked(){return this.locks.size>0}get localStorageSave(){return{selectedTabId:this.selectedTabId,selectedCoordSystemId:this.selectedCoordSystemId,selectedTcpId:this.selectedTcpId,selectedOrientation:this.selectedOrientation,selectedIncrementId:this.selectedIncrementId,selectedCartesianMotionType:this.selectedCartesianMotionType}}get tabs(){return[{id:"cartesian",label:"cartesian"},{id:"joint",label:"joint"}]}get incrementOptions(){return p5}get discreteIncrementOptions(){return vl}get incrementOptionsById(){return so(this.incrementOptions,t=>t.id)}get tabsById(){return so(this.tabs,t=>t.id)}get currentTab(){return this.tabsById[this.selectedTabId]||this.tabs[0]}get tabIndex(){return this.tabs.indexOf(this.currentTab)}get coordSystemsById(){return so(this.coordSystems,t=>t.coordinate_system)}get selectedCoordSystem(){return this.coordSystemsById[this.selectedCoordSystemId]}get activeCoordSystemId(){return this.selectedOrientation==="tool"?"tool":this.selectedCoordSystemId}get tcpsById(){return so(this.tcps,t=>t.id)}get activeDiscreteIncrement(){return this.selectedOrientation==="tool"?void 0:vl.find(t=>t.id===this.selectedIncrementId)}get rotationVelocityRadsPerSec(){return this.rotationVelocityDegPerSec*Math.PI/180}get velocityInDisplayUnits(){return this.currentMotionType==="translate"?this.translationVelocityMmPerSec:this.rotationVelocityDegPerSec}get minVelocityInDisplayUnits(){return this.currentMotionType==="translate"?this.minTranslationVelocityMmPerSec:this.minRotationVelocityDegPerSec}get maxVelocityInDisplayUnits(){return this.currentMotionType==="translate"?this.maxTranslationVelocityMmPerSec:this.maxRotationVelocityDegPerSec}get currentMotionType(){return this.selectedTabId==="cartesian"&&this.selectedCartesianMotionType==="translate"?"translate":"rotate"}onTabChange(t,r){const n=this.tabs[r]||this.tabs[0];this.selectedTabId=n.id}setSelectedCoordSystemId(t){this.selectedCoordSystemId=t}setSelectedTcpId(t){this.selectedTcpId=t}setSelectedOrientation(t){this.selectedOrientation=t}setSelectedIncrementId(t){this.selectedIncrementId=t}setCurrentIncrementJog(t){this.incrementJogInProgress=t}setVelocityFromSlider(t){this.currentMotionType==="translate"?this.translationVelocityMmPerSec=t:this.rotationVelocityDegPerSec=t}setSelectedCartesianMotionType(t){this.selectedCartesianMotionType=t}lock(t){this.locks.add(t)}unlock(t){this.locks.delete(t)}async withMotionLock(t){const r=h5();this.lock(r);try{return await t()}finally{this.unlock(r)}}}const f5=je.observer(({store:e})=>{var a;const{t}=Ie.useTranslation(),r=[];function n(o){switch(o){case"coordsys":return t("Jogging.Orientation.coordsys");case"tool":return t("Jogging.Orientation.tool");default:return o}}return e.showCoordSystemSelect&&r.push(S.jsx(oo,{labelId:"jogging-coord-select",labelValue:t("Jogging.CoordinateSystem.hlb"),value:e.selectedCoordSystemId,size:"small",variant:"filled",displayEmpty:!0,onChange:o=>e.setSelectedCoordSystemId(o.target.value),disabled:e.isLocked,children:e.coordSystems.map(o=>S.jsx(J.MenuItem,{value:o.coordinate_system,children:o.name&&e.coordSystemCountByName[o.name]>1?`${o.name} / ${o.coordinate_system}`:o.name||o.coordinate_system},o.coordinate_system))},"coord")),e.showTcpSelect&&r.push(S.jsx(oo,{labelId:"jogging-tcp-select",labelValue:"TCP",value:e.selectedTcpId,size:"small",variant:"filled",onChange:o=>e.setSelectedTcpId(o.target.value),disabled:e.isLocked,children:e.tcps.map(o=>S.jsx(J.MenuItem,{value:o.id,children:o.id},o.id))},"tcp")),e.showOrientationSelect&&r.push(S.jsx(oo,{labelValue:t("Jogging.Cartesian.Orientation.lb"),id:"orientation-select",labelId:"orientation-select",value:e.selectedOrientation,onChange:o=>e.setSelectedOrientation(o.target.value),disabled:e.isLocked,children:m5.map(o=>S.jsx(J.MenuItem,{value:o,children:n(o)},o))},"orientation")),e.showIncrementSelect&&r.push(S.jsxs(oo,{labelValue:t("Jogging.Increment.hlb"),labelId:"jogging-increment-select",size:"small",variant:"filled",value:((a=e.activeDiscreteIncrement)==null?void 0:a.id)||"continuous",onChange:o=>e.setSelectedIncrementId(o.target.value),disabled:e.isLocked,children:[S.jsx(J.MenuItem,{value:"continuous",children:t("Jogging.Increment.Continuous.dd")},"continuous"),e.selectedOrientation==="tool"?null:e.discreteIncrementOptions.map(o=>S.jsx(J.MenuItem,{value:o.id,children:e.currentMotionType==="translate"?`${o.mm}mm`:`${o.degrees}°`},o.id))]},"increment")),S.jsx(J.Box,{component:"div",sx:{display:"grid",gap:"16px",gridTemplateColumns:"1fr 1fr",gridAutoRows:"min-content","& label":{opacity:.7,fontSize:"12px",marginBottom:"4px"}},children:r.map((o,s)=>S.jsx(J.Box,{sx:{gridColumn:r.length%2===1&&s===r.length-1?"span 2":"auto"},children:o},s))})}),g5=J.styled(J.ToggleButtonGroup)(({theme:e})=>{var t;return{"&.MuiToggleButtonGroup-root":{background:(t=e.palette.backgroundPaperElevation)==null?void 0:t[8],borderRadius:"8px",padding:"4px",gap:"4px",button:{border:"none",borderRadius:"4px",flex:"1 1 0px",minWidth:0,"&.MuiToggleButtonGroup-firstButton":{borderRadius:"8px 4px 4px 8px"},"&.MuiToggleButtonGroup-lastButton":{borderRadius:"4px 8px 8px 4px"}}}}});function vh(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...n){return e(...n)||t(...n)}}function y5(e){return typeof e=="string"}function b5(e,t,r){return e===void 0||y5(e)?t:{...t,ownerState:{...t.ownerState,...r}}}function So(e,t=[]){if(e===void 0)return{};const r={};return Object.keys(e).filter(n=>n.match(/^on[A-Z]/)&&typeof e[n]=="function"&&!t.includes(n)).forEach(n=>{r[n]=e[n]}),r}function Sh(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(r=>!(r.match(/^on[A-Z]/)&&typeof e[r]=="function")).forEach(r=>{t[r]=e[r]}),t}function v5(e){const{getSlotProps:t,additionalProps:r,externalSlotProps:n,externalForwardedProps:a,className:o}=e;if(!t){const p=Et(r==null?void 0:r.className,o,a==null?void 0:a.className,n==null?void 0:n.className),f={...r==null?void 0:r.style,...a==null?void 0:a.style,...n==null?void 0:n.style},m={...r,...a,...n};return p.length>0&&(m.className=p),Object.keys(f).length>0&&(m.style=f),{props:m,internalRef:void 0}}const s=So({...a,...n}),i=Sh(n),l=Sh(a),c=t(s),u=Et(c==null?void 0:c.className,r==null?void 0:r.className,o,a==null?void 0:a.className,n==null?void 0:n.className),d={...c==null?void 0:c.style,...r==null?void 0:r.style,...a==null?void 0:a.style,...n==null?void 0:n.style},h={...c,...r,...l,...i};return u.length>0&&(h.className=u),Object.keys(d).length>0&&(h.style=d),{props:h,internalRef:c.ref}}function S5(e,t,r){return typeof e=="function"?e(t,r):e}function er(e){var d;const{elementType:t,externalSlotProps:r,ownerState:n,skipResolvingSlotProps:a=!1,...o}=e,s=a?{}:S5(r,n),{props:i,internalRef:l}=v5({...o,externalSlotProps:s}),c=wm(l,s==null?void 0:s.ref,(d=e.additionalProps)==null?void 0:d.ref);return b5(t,{...i,ref:c},n)}function xh(e){try{return e.matches(":focus-visible")}catch{process.env.NODE_ENV!=="production"&&!/jsdom/.test(window.navigator.userAgent)&&console.warn(["MUI: The `:focus-visible` pseudo class is not supported in this browser.","Some components rely on this feature to work properly."].join(`
|
|
154
|
-
`))}return!1}const x5={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"};function O5(e,t,r=(n,a)=>n===a){return e.length===t.length&&e.every((n,a)=>r(n,t[a]))}const w5=2;function Xr(e,t,r,n,a){return r===1?Math.min(e+t,a):Math.max(e-t,n)}function kf(e,t){return e-t}function Oh(e,t){const{index:r}=e.reduce((n,a,o)=>{const s=Math.abs(t-a);return n===null||s<n.distance||s===n.distance?{distance:s,index:o}:n},null)??{};return r}function io(e,t){if(t.current!==void 0&&e.changedTouches){const r=e;for(let n=0;n<r.changedTouches.length;n+=1){const a=r.changedTouches[n];if(a.identifier===t.current)return{x:a.clientX,y:a.clientY}}return!1}return{x:e.clientX,y:e.clientY}}function Wo(e,t,r){return(e-t)*100/(r-t)}function C5(e,t,r){return(r-t)*e+t}function P5(e){if(Math.abs(e)<1){const r=e.toExponential().split("e-"),n=r[0].split(".")[1];return(n?n.length:0)+parseInt(r[1],10)}const t=e.toString().split(".")[1];return t?t.length:0}function T5(e,t,r){const n=Math.round((e-r)/t)*t+r;return Number(n.toFixed(P5(t)))}function wh({values:e,newValue:t,index:r}){const n=e.slice();return n[r]=t,n.sort(kf)}function lo({sliderRef:e,activeIndex:t,setActive:r}){var a,o,s;const n=go(e.current);(!((a=e.current)!=null&&a.contains(n.activeElement))||Number((o=n==null?void 0:n.activeElement)==null?void 0:o.getAttribute("data-index"))!==t)&&((s=e.current)==null||s.querySelector(`[type="range"][data-index="${t}"]`).focus()),r&&r(t)}function co(e,t){return typeof e=="number"&&typeof t=="number"?e===t:typeof e=="object"&&typeof t=="object"?O5(e,t):!1}const A5={horizontal:{offset:e=>({left:`${e}%`}),leap:e=>({width:`${e}%`})},"horizontal-reverse":{offset:e=>({right:`${e}%`}),leap:e=>({width:`${e}%`})},vertical:{offset:e=>({bottom:`${e}%`}),leap:e=>({height:`${e}%`})}},R5=e=>e;let uo;function Ch(){return uo===void 0&&(typeof CSS<"u"&&typeof CSS.supports=="function"?uo=CSS.supports("touch-action","none"):uo=!0),uo}function V5(e){const{"aria-labelledby":t,defaultValue:r,disabled:n=!1,disableSwap:a=!1,isRtl:o=!1,marks:s=!1,max:i=100,min:l=0,name:c,onChange:u,onChangeCommitted:d,orientation:h="horizontal",rootRef:p,scale:f=R5,step:m=1,shiftStep:b=10,tabIndex:x,value:V}=e,O=B.useRef(void 0),[C,P]=B.useState(-1),[w,A]=B.useState(-1),[E,F]=B.useState(!1),y=B.useRef(0),T=B.useRef(null),[z,_]=Ww({controlled:V,default:r??l,name:"Slider"}),N=u&&((K,ne,se)=>{const fe=K.nativeEvent||K,Oe=new fe.constructor(fe.type,fe);Object.defineProperty(Oe,"target",{writable:!0,value:{value:ne,name:c}}),T.current=ne,u(Oe,ne,se)}),te=Array.isArray(z);let Z=te?z.slice().sort(kf):[z];Z=Z.map(K=>K==null?l:Zr(K,l,i));const ae=s===!0&&m!==null?[...Array(Math.floor((i-l)/m)+1)].map((K,ne)=>({value:l+m*ne})):s||[],re=ae.map(K=>K.value),[le,q]=B.useState(-1),X=B.useRef(null),he=wm(p,X),Pe=K=>ne=>{var fe;const se=Number(ne.currentTarget.getAttribute("data-index"));xh(ne.target)&&q(se),A(se),(fe=K==null?void 0:K.onFocus)==null||fe.call(K,ne)},ze=K=>ne=>{var se;xh(ne.target)||q(-1),A(-1),(se=K==null?void 0:K.onBlur)==null||se.call(K,ne)},xe=(K,ne)=>{const se=Number(K.currentTarget.getAttribute("data-index")),fe=Z[se],Oe=re.indexOf(fe);let ie=ne;if(ae&&m==null){const He=re[re.length-1];ie>=He?ie=He:ie<=re[0]?ie=re[0]:ie=ie<fe?re[Oe-1]:re[Oe+1]}if(ie=Zr(ie,l,i),te){a&&(ie=Zr(ie,Z[se-1]||-1/0,Z[se+1]||1/0));const He=ie;ie=wh({values:Z,newValue:ie,index:se});let Xe=se;a||(Xe=ie.indexOf(He)),lo({sliderRef:X,activeIndex:Xe})}_(ie),q(se),N&&!co(ie,z)&&N(K,ie,se),d&&d(K,T.current??ie)},it=K=>ne=>{var se;if(["ArrowUp","ArrowDown","ArrowLeft","ArrowRight","PageUp","PageDown","Home","End"].includes(ne.key)){ne.preventDefault();const fe=Number(ne.currentTarget.getAttribute("data-index")),Oe=Z[fe];let ie=null;if(m!=null){const He=ne.shiftKey?b:m;switch(ne.key){case"ArrowUp":ie=Xr(Oe,He,1,l,i);break;case"ArrowRight":ie=Xr(Oe,He,o?-1:1,l,i);break;case"ArrowDown":ie=Xr(Oe,He,-1,l,i);break;case"ArrowLeft":ie=Xr(Oe,He,o?1:-1,l,i);break;case"PageUp":ie=Xr(Oe,b,1,l,i);break;case"PageDown":ie=Xr(Oe,b,-1,l,i);break;case"Home":ie=l;break;case"End":ie=i;break}}else if(ae){const He=re[re.length-1],Xe=re.indexOf(Oe),De=[o?"ArrowRight":"ArrowLeft","ArrowDown","PageDown","Home"],ht=[o?"ArrowLeft":"ArrowRight","ArrowUp","PageUp","End"];De.includes(ne.key)?Xe===0?ie=re[0]:ie=re[Xe-1]:ht.includes(ne.key)&&(Xe===re.length-1?ie=He:ie=re[Xe+1])}ie!=null&&xe(ne,ie)}(se=K==null?void 0:K.onKeyDown)==null||se.call(K,ne)};zh(()=>{var K;n&&X.current.contains(document.activeElement)&&((K=document.activeElement)==null||K.blur())},[n]),n&&C!==-1&&P(-1),n&&le!==-1&&q(-1);const tt=K=>ne=>{var se;(se=K.onChange)==null||se.call(K,ne),xe(ne,ne.target.valueAsNumber)},ye=B.useRef(void 0);let Q=h;o&&h==="horizontal"&&(Q+="-reverse");const oe=({finger:K,move:ne=!1})=>{const{current:se}=X,{width:fe,height:Oe,bottom:ie,left:He}=se.getBoundingClientRect();let Xe;Q.startsWith("vertical")?Xe=(ie-K.y)/Oe:Xe=(K.x-He)/fe,Q.includes("-reverse")&&(Xe=1-Xe);let De;if(De=C5(Xe,l,i),m)De=T5(De,m,l);else{const Vn=Oh(re,De);De=re[Vn]}De=Zr(De,l,i);let ht=0;if(te){ne?ht=ye.current:ht=Oh(Z,De),a&&(De=Zr(De,Z[ht-1]||-1/0,Z[ht+1]||1/0));const Vn=De;De=wh({values:Z,newValue:De,index:ht}),a&&ne||(ht=De.indexOf(Vn),ye.current=ht)}return{newValue:De,activeIndex:ht}},ce=bi(K=>{const ne=io(K,O);if(!ne)return;if(y.current+=1,K.type==="mousemove"&&K.buttons===0){W(K);return}const{newValue:se,activeIndex:fe}=oe({finger:ne,move:!0});lo({sliderRef:X,activeIndex:fe,setActive:P}),_(se),!E&&y.current>w5&&F(!0),N&&!co(se,z)&&N(K,se,fe)}),W=bi(K=>{const ne=io(K,O);if(F(!1),!ne)return;const{newValue:se}=oe({finger:ne,move:!0});P(-1),K.type==="touchend"&&A(-1),d&&d(K,T.current??se),O.current=void 0,me()}),be=bi(K=>{if(n)return;Ch()||K.preventDefault();const ne=K.changedTouches[0];ne!=null&&(O.current=ne.identifier);const se=io(K,O);if(se!==!1){const{newValue:Oe,activeIndex:ie}=oe({finger:se});lo({sliderRef:X,activeIndex:ie,setActive:P}),_(Oe),N&&!co(Oe,z)&&N(K,Oe,ie)}y.current=0;const fe=go(X.current);fe.addEventListener("touchmove",ce,{passive:!0}),fe.addEventListener("touchend",W,{passive:!0})}),me=B.useCallback(()=>{const K=go(X.current);K.removeEventListener("mousemove",ce),K.removeEventListener("mouseup",W),K.removeEventListener("touchmove",ce),K.removeEventListener("touchend",W)},[W,ce]);B.useEffect(()=>{const{current:K}=X;return K.addEventListener("touchstart",be,{passive:Ch()}),()=>{K.removeEventListener("touchstart",be),me()}},[me,be]),B.useEffect(()=>{n&&me()},[n,me]);const Je=K=>ne=>{var Oe;if((Oe=K.onMouseDown)==null||Oe.call(K,ne),n||ne.defaultPrevented||ne.button!==0)return;ne.preventDefault();const se=io(ne,O);if(se!==!1){const{newValue:ie,activeIndex:He}=oe({finger:se});lo({sliderRef:X,activeIndex:He,setActive:P}),_(ie),N&&!co(ie,z)&&N(ne,ie,He)}y.current=0;const fe=go(X.current);fe.addEventListener("mousemove",ce,{passive:!0}),fe.addEventListener("mouseup",W)},Ge=Wo(te?Z[0]:l,l,i),Ee=Wo(Z[Z.length-1],l,i)-Ge,Kt=(K={})=>{const ne=So(K),se={onMouseDown:Je(ne||{})},fe={...ne,...se};return{...K,ref:he,...fe}},Ea=K=>ne=>{var fe;(fe=K.onMouseOver)==null||fe.call(K,ne);const se=Number(ne.currentTarget.getAttribute("data-index"));A(se)},Ia=K=>ne=>{var se;(se=K.onMouseLeave)==null||se.call(K,ne),A(-1)},Ma=(K={})=>{const ne=So(K),se={onMouseOver:Ea(ne||{}),onMouseLeave:Ia(ne||{})};return{...K,...ne,...se}},$a=K=>({pointerEvents:C!==-1&&C!==K?"none":void 0});let Ur;return h==="vertical"&&(Ur=o?"vertical-rl":"vertical-lr"),{active:C,axis:Q,axisProps:A5,dragging:E,focusedThumbIndex:le,getHiddenInputProps:(K={})=>{const ne=So(K),se={onChange:tt(ne||{}),onFocus:Pe(ne||{}),onBlur:ze(ne||{}),onKeyDown:it(ne||{})},fe={...ne,...se};return{tabIndex:x,"aria-labelledby":t,"aria-orientation":h,"aria-valuemax":f(i),"aria-valuemin":f(l),name:c,type:"range",min:e.min,max:e.max,step:e.step===null&&e.marks?"any":e.step??void 0,disabled:n,...K,...fe,style:{...x5,direction:o?"rtl":"ltr",width:"100%",height:"100%",writingMode:Ur}}},getRootProps:Kt,getThumbProps:Ma,marks:ae,open:w,range:te,rootRef:he,trackLeap:Ee,trackOffset:Ge,values:Z,getThumbStyle:$a}}function xo(e){return typeof e=="string"}const _5=e=>!e||!xo(e);function E5(e){return typeof e.main=="string"}function I5(e,t=[]){if(!E5(e))return!1;for(const r of t)if(!e.hasOwnProperty(r)||typeof e[r]!="string")return!1;return!0}function Sc(e=[]){return([,t])=>t&&I5(t,e)}function M5(e){return xa("MuiSlider",e)}const gt=kh("MuiSlider",["root","active","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","disabled","dragging","focusVisible","mark","markActive","marked","markLabel","markLabelActive","rail","sizeSmall","thumb","thumbColorPrimary","thumbColorSecondary","thumbColorError","thumbColorSuccess","thumbColorInfo","thumbColorWarning","track","trackInverted","trackFalse","thumbSizeSmall","valueLabel","valueLabelOpen","valueLabelCircle","valueLabelLabel","vertical"]),$5=e=>{const{open:t}=e;return{offset:Et(t&>.valueLabelOpen),circle:gt.valueLabelCircle,label:gt.valueLabelLabel}};function Uf(e){const{children:t,className:r,value:n}=e,a=$5(e);return t?B.cloneElement(t,{className:t.props.className},S.jsxs(B.Fragment,{children:[t.props.children,S.jsx("span",{className:Et(a.offset,r),"aria-hidden":!0,children:S.jsx("span",{className:a.circle,children:S.jsx("span",{className:a.label,children:n})})})]})):null}process.env.NODE_ENV!=="production"&&(Uf.propTypes={children:g.element.isRequired,className:g.string,value:g.node});function Ph(e){return e}const j5=dt("span",{name:"MuiSlider",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,t[`color${Ze(r.color)}`],r.size!=="medium"&&t[`size${Ze(r.size)}`],r.marked&&t.marked,r.orientation==="vertical"&&t.vertical,r.track==="inverted"&&t.trackInverted,r.track===!1&&t.trackFalse]}})(Ir(({theme:e})=>({borderRadius:12,boxSizing:"content-box",display:"inline-block",position:"relative",cursor:"pointer",touchAction:"none",WebkitTapHighlightColor:"transparent","@media print":{colorAdjust:"exact"},[`&.${gt.disabled}`]:{pointerEvents:"none",cursor:"default",color:(e.vars||e).palette.grey[400]},[`&.${gt.dragging}`]:{[`& .${gt.thumb}, & .${gt.track}`]:{transition:"none"}},variants:[...Object.entries(e.palette).filter(Sc()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}})),{props:{orientation:"horizontal"},style:{height:4,width:"100%",padding:"13px 0","@media (pointer: coarse)":{padding:"20px 0"}}},{props:{orientation:"horizontal",size:"small"},style:{height:2}},{props:{orientation:"horizontal",marked:!0},style:{marginBottom:20}},{props:{orientation:"vertical"},style:{height:"100%",width:4,padding:"0 13px","@media (pointer: coarse)":{padding:"0 20px"}}},{props:{orientation:"vertical",size:"small"},style:{width:2}},{props:{orientation:"vertical",marked:!0},style:{marginRight:44}}]}))),k5=dt("span",{name:"MuiSlider",slot:"Rail"})({display:"block",position:"absolute",borderRadius:"inherit",backgroundColor:"currentColor",opacity:.38,variants:[{props:{orientation:"horizontal"},style:{width:"100%",height:"inherit",top:"50%",transform:"translateY(-50%)"}},{props:{orientation:"vertical"},style:{height:"100%",width:"inherit",left:"50%",transform:"translateX(-50%)"}},{props:{track:"inverted"},style:{opacity:1}}]}),U5=dt("span",{name:"MuiSlider",slot:"Track"})(Ir(({theme:e})=>({display:"block",position:"absolute",borderRadius:"inherit",border:"1px solid currentColor",backgroundColor:"currentColor",transition:e.transitions.create(["left","width","bottom","height"],{duration:e.transitions.duration.shortest}),variants:[{props:{size:"small"},style:{border:"none"}},{props:{orientation:"horizontal"},style:{height:"inherit",top:"50%",transform:"translateY(-50%)"}},{props:{orientation:"vertical"},style:{width:"inherit",left:"50%",transform:"translateX(-50%)"}},{props:{track:!1},style:{display:"none"}},...Object.entries(e.palette).filter(Sc()).map(([t])=>({props:{color:t,track:"inverted"},style:{...e.vars?{backgroundColor:e.vars.palette.Slider[`${t}Track`],borderColor:e.vars.palette.Slider[`${t}Track`]}:{backgroundColor:aa(e.palette[t].main,.62),borderColor:aa(e.palette[t].main,.62),...e.applyStyles("dark",{backgroundColor:na(e.palette[t].main,.5)}),...e.applyStyles("dark",{borderColor:na(e.palette[t].main,.5)})}}}))]}))),L5=dt("span",{name:"MuiSlider",slot:"Thumb",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.thumb,t[`thumbColor${Ze(r.color)}`],r.size!=="medium"&&t[`thumbSize${Ze(r.size)}`]]}})(Ir(({theme:e})=>({position:"absolute",width:20,height:20,boxSizing:"border-box",borderRadius:"50%",outline:0,backgroundColor:"currentColor",display:"flex",alignItems:"center",justifyContent:"center",transition:e.transitions.create(["box-shadow","left","bottom"],{duration:e.transitions.duration.shortest}),"&::before":{position:"absolute",content:'""',borderRadius:"inherit",width:"100%",height:"100%",boxShadow:(e.vars||e).shadows[2]},"&::after":{position:"absolute",content:'""',borderRadius:"50%",width:42,height:42,top:"50%",left:"50%",transform:"translate(-50%, -50%)"},[`&.${gt.disabled}`]:{"&:hover":{boxShadow:"none"}},variants:[{props:{size:"small"},style:{width:12,height:12,"&::before":{boxShadow:"none"}}},{props:{orientation:"horizontal"},style:{top:"50%",transform:"translate(-50%, -50%)"}},{props:{orientation:"vertical"},style:{left:"50%",transform:"translate(-50%, 50%)"}},...Object.entries(e.palette).filter(Sc()).map(([t])=>({props:{color:t},style:{[`&:hover, &.${gt.focusVisible}`]:{...e.vars?{boxShadow:`0px 0px 0px 8px rgba(${e.vars.palette[t].mainChannel} / 0.16)`}:{boxShadow:`0px 0px 0px 8px ${Ui(e.palette[t].main,.16)}`},"@media (hover: none)":{boxShadow:"none"}},[`&.${gt.active}`]:{...e.vars?{boxShadow:`0px 0px 0px 14px rgba(${e.vars.palette[t].mainChannel} / 0.16)`}:{boxShadow:`0px 0px 0px 14px ${Ui(e.palette[t].main,.16)}`}}}}))]}))),Lf=dt(Uf,{name:"MuiSlider",slot:"ValueLabel"})(Ir(({theme:e})=>({zIndex:1,whiteSpace:"nowrap",...e.typography.body2,fontWeight:500,transition:e.transitions.create(["transform"],{duration:e.transitions.duration.shortest}),position:"absolute",backgroundColor:(e.vars||e).palette.grey[600],borderRadius:2,color:(e.vars||e).palette.common.white,display:"flex",alignItems:"center",justifyContent:"center",padding:"0.25rem 0.75rem",variants:[{props:{orientation:"horizontal"},style:{transform:"translateY(-100%) scale(0)",top:"-10px",transformOrigin:"bottom center","&::before":{position:"absolute",content:'""',width:8,height:8,transform:"translate(-50%, 50%) rotate(45deg)",backgroundColor:"inherit",bottom:0,left:"50%"},[`&.${gt.valueLabelOpen}`]:{transform:"translateY(-100%) scale(1)"}}},{props:{orientation:"vertical"},style:{transform:"translateY(-50%) scale(0)",right:"30px",top:"50%",transformOrigin:"right center","&::before":{position:"absolute",content:'""',width:8,height:8,transform:"translate(-50%, -50%) rotate(45deg)",backgroundColor:"inherit",right:-8,top:"50%"},[`&.${gt.valueLabelOpen}`]:{transform:"translateY(-50%) scale(1)"}}},{props:{size:"small"},style:{fontSize:e.typography.pxToRem(12),padding:"0.25rem 0.5rem"}},{props:{orientation:"vertical",size:"small"},style:{right:"20px"}}]})));process.env.NODE_ENV!=="production"&&(Lf.propTypes={children:g.element.isRequired,index:g.number.isRequired,open:g.bool.isRequired,value:g.node});const D5=dt("span",{name:"MuiSlider",slot:"Mark",shouldForwardProp:e=>Pl(e)&&e!=="markActive",overridesResolver:(e,t)=>{const{markActive:r}=e;return[t.mark,r&&t.markActive]}})(Ir(({theme:e})=>({position:"absolute",width:2,height:2,borderRadius:1,backgroundColor:"currentColor",variants:[{props:{orientation:"horizontal"},style:{top:"50%",transform:"translate(-1px, -50%)"}},{props:{orientation:"vertical"},style:{left:"50%",transform:"translate(-50%, 1px)"}},{props:{markActive:!0},style:{backgroundColor:(e.vars||e).palette.background.paper,opacity:.8}}]}))),B5=dt("span",{name:"MuiSlider",slot:"MarkLabel",shouldForwardProp:e=>Pl(e)&&e!=="markLabelActive"})(Ir(({theme:e})=>({...e.typography.body2,color:(e.vars||e).palette.text.secondary,position:"absolute",whiteSpace:"nowrap",variants:[{props:{orientation:"horizontal"},style:{top:30,transform:"translateX(-50%)","@media (pointer: coarse)":{top:40}}},{props:{orientation:"vertical"},style:{left:36,transform:"translateY(50%)","@media (pointer: coarse)":{left:44}}},{props:{markLabelActive:!0},style:{color:(e.vars||e).palette.text.primary}}]}))),N5=e=>{const{disabled:t,dragging:r,marked:n,orientation:a,track:o,classes:s,color:i,size:l}=e,c={root:["root",t&&"disabled",r&&"dragging",n&&"marked",a==="vertical"&&"vertical",o==="inverted"&&"trackInverted",o===!1&&"trackFalse",i&&`color${Ze(i)}`,l&&`size${Ze(l)}`],rail:["rail"],track:["track"],mark:["mark"],markActive:["markActive"],markLabel:["markLabel"],markLabelActive:["markLabelActive"],valueLabel:["valueLabel"],thumb:["thumb",t&&"disabled",l&&`thumbSize${Ze(l)}`,i&&`thumbColor${Ze(i)}`],active:["active"],disabled:["disabled"],focusVisible:["focusVisible"]};return wl(c,M5,s)},F5=({children:e})=>e,Df=B.forwardRef(function(t,r){const n=dc({props:t,name:"MuiSlider"}),a=Xy(),{"aria-label":o,"aria-valuetext":s,"aria-labelledby":i,component:l="span",components:c={},componentsProps:u={},color:d="primary",classes:h,className:p,disableSwap:f=!1,disabled:m=!1,getAriaLabel:b,getAriaValueText:x,marks:V=!1,max:O=100,min:C=0,name:P,onChange:w,onChangeCommitted:A,orientation:E="horizontal",shiftStep:F=10,size:y="medium",step:T=1,scale:z=Ph,slotProps:_,slots:N,tabIndex:te,track:Z="normal",value:ae,valueLabelDisplay:re="off",valueLabelFormat:le=Ph,...q}=n,X={...n,isRtl:a,max:O,min:C,classes:h,disabled:m,disableSwap:f,orientation:E,marks:V,color:d,size:y,step:T,shiftStep:F,scale:z,track:Z,valueLabelDisplay:re,valueLabelFormat:le},{axisProps:he,getRootProps:Pe,getHiddenInputProps:ze,getThumbProps:xe,open:it,active:tt,axis:ye,focusedThumbIndex:Q,range:oe,dragging:ce,marks:W,values:be,trackOffset:me,trackLeap:Je,getThumbStyle:Ge}=V5({...X,rootRef:r});X.marked=W.length>0&&W.some(Le=>Le.label),X.dragging=ce,X.focusedThumbIndex=Q;const Ee=N5(X),Kt=(N==null?void 0:N.root)??c.Root??j5,Ea=(N==null?void 0:N.rail)??c.Rail??k5,Ia=(N==null?void 0:N.track)??c.Track??U5,Ma=(N==null?void 0:N.thumb)??c.Thumb??L5,$a=(N==null?void 0:N.valueLabel)??c.ValueLabel??Lf,Ur=(N==null?void 0:N.mark)??c.Mark??D5,ja=(N==null?void 0:N.markLabel)??c.MarkLabel??B5,K=(N==null?void 0:N.input)??c.Input??"input",ne=(_==null?void 0:_.root)??u.root,se=(_==null?void 0:_.rail)??u.rail,fe=(_==null?void 0:_.track)??u.track,Oe=(_==null?void 0:_.thumb)??u.thumb,ie=(_==null?void 0:_.valueLabel)??u.valueLabel,He=(_==null?void 0:_.mark)??u.mark,Xe=(_==null?void 0:_.markLabel)??u.markLabel,De=(_==null?void 0:_.input)??u.input,ht=er({elementType:Kt,getSlotProps:Pe,externalSlotProps:ne,externalForwardedProps:q,additionalProps:{..._5(Kt)&&{as:l}},ownerState:{...X,...ne==null?void 0:ne.ownerState},className:[Ee.root,p]}),Vn=er({elementType:Ea,externalSlotProps:se,ownerState:X,className:Ee.rail}),Wf=er({elementType:Ia,externalSlotProps:fe,additionalProps:{style:{...he[ye].offset(me),...he[ye].leap(Je)}},ownerState:{...X,...fe==null?void 0:fe.ownerState},className:Ee.track}),Ns=er({elementType:Ma,getSlotProps:xe,externalSlotProps:Oe,ownerState:{...X,...Oe==null?void 0:Oe.ownerState},className:Ee.thumb}),Yf=er({elementType:$a,externalSlotProps:ie,ownerState:{...X,...ie==null?void 0:ie.ownerState},className:Ee.valueLabel}),Fs=er({elementType:Ur,externalSlotProps:He,ownerState:X,className:Ee.mark}),zs=er({elementType:ja,externalSlotProps:Xe,ownerState:X,className:Ee.markLabel}),Kf=er({elementType:K,getSlotProps:ze,externalSlotProps:De,ownerState:X});return S.jsxs(Kt,{...ht,children:[S.jsx(Ea,{...Vn}),S.jsx(Ia,{...Wf}),W.filter(Le=>Le.value>=C&&Le.value<=O).map((Le,We)=>{const Gs=Wo(Le.value,C,O),ka=he[ye].offset(Gs);let jt;return Z===!1?jt=be.includes(Le.value):jt=Z==="normal"&&(oe?Le.value>=be[0]&&Le.value<=be[be.length-1]:Le.value<=be[0])||Z==="inverted"&&(oe?Le.value<=be[0]||Le.value>=be[be.length-1]:Le.value>=be[0]),S.jsxs(B.Fragment,{children:[S.jsx(Ur,{"data-index":We,...Fs,...!xo(Ur)&&{markActive:jt},style:{...ka,...Fs.style},className:Et(Fs.className,jt&&Ee.markActive)}),Le.label!=null?S.jsx(ja,{"aria-hidden":!0,"data-index":We,...zs,...!xo(ja)&&{markLabelActive:jt},style:{...ka,...zs.style},className:Et(Ee.markLabel,zs.className,jt&&Ee.markLabelActive),children:Le.label}):null]},We)}),be.map((Le,We)=>{const Gs=Wo(Le,C,O),ka=he[ye].offset(Gs),jt=re==="off"?F5:$a;return S.jsx(jt,{...!xo(jt)&&{valueLabelFormat:le,valueLabelDisplay:re,value:typeof le=="function"?le(z(Le),We):le,index:We,open:it===We||tt===We||re==="on",disabled:m},...Yf,children:S.jsx(Ma,{"data-index":We,...Ns,className:Et(Ee.thumb,Ns.className,tt===We&&Ee.active,Q===We&&Ee.focusVisible),style:{...ka,...Ge(We),...Ns.style},children:S.jsx(K,{"data-index":We,"aria-label":b?b(We):o,"aria-valuenow":z(Le),"aria-labelledby":i,"aria-valuetext":x?x(z(Le),We):s,value:be[We],...Kf})})},We)})]})});process.env.NODE_ENV!=="production"&&(Df.propTypes={"aria-label":vh(g.string,e=>Array.isArray(e.value||e.defaultValue)&&e["aria-label"]!=null?new Error("MUI: You need to use the `getAriaLabel` prop instead of `aria-label` when using a range slider."):null),"aria-labelledby":g.string,"aria-valuetext":vh(g.string,e=>Array.isArray(e.value||e.defaultValue)&&e["aria-valuetext"]!=null?new Error("MUI: You need to use the `getAriaValueText` prop instead of `aria-valuetext` when using a range slider."):null),children:g.node,classes:g.object,className:g.string,color:g.oneOfType([g.oneOf(["primary","secondary","error","info","success","warning"]),g.string]),components:g.shape({Input:g.elementType,Mark:g.elementType,MarkLabel:g.elementType,Rail:g.elementType,Root:g.elementType,Thumb:g.elementType,Track:g.elementType,ValueLabel:g.elementType}),componentsProps:g.shape({input:g.oneOfType([g.func,g.object]),mark:g.oneOfType([g.func,g.object]),markLabel:g.oneOfType([g.func,g.object]),rail:g.oneOfType([g.func,g.object]),root:g.oneOfType([g.func,g.object]),thumb:g.oneOfType([g.func,g.object]),track:g.oneOfType([g.func,g.object]),valueLabel:g.oneOfType([g.func,g.shape({children:g.element,className:g.string,open:g.bool,style:g.object,value:g.node,valueLabelDisplay:g.oneOf(["auto","off","on"])})])}),defaultValue:g.oneOfType([g.arrayOf(g.number),g.number]),disabled:g.bool,disableSwap:g.bool,getAriaLabel:g.func,getAriaValueText:g.func,marks:g.oneOfType([g.arrayOf(g.shape({label:g.node,value:g.number.isRequired})),g.bool]),max:g.number,min:g.number,name:g.string,onChange:g.func,onChangeCommitted:g.func,orientation:g.oneOf(["horizontal","vertical"]),scale:g.func,shiftStep:g.number,size:g.oneOfType([g.oneOf(["small","medium"]),g.string]),slotProps:g.shape({input:g.oneOfType([g.func,g.object]),mark:g.oneOfType([g.func,g.object]),markLabel:g.oneOfType([g.func,g.object]),rail:g.oneOfType([g.func,g.object]),root:g.oneOfType([g.func,g.object]),thumb:g.oneOfType([g.func,g.object]),track:g.oneOfType([g.func,g.object]),valueLabel:g.oneOfType([g.func,g.shape({children:g.element,className:g.string,open:g.bool,style:g.object,value:g.node,valueLabelDisplay:g.oneOf(["auto","off","on"])})])}),slots:g.shape({input:g.elementType,mark:g.elementType,markLabel:g.elementType,rail:g.elementType,root:g.elementType,thumb:g.elementType,track:g.elementType,valueLabel:g.elementType}),step:g.number,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),tabIndex:g.number,track:g.oneOf(["inverted","normal",!1]),value:g.oneOfType([g.arrayOf(g.number),g.number]),valueLabelDisplay:g.oneOf(["auto","off","on"]),valueLabelFormat:g.oneOfType([g.func,g.string])});var z5="[object Number]";function G5(e){return typeof e=="number"||Cr(e)&&Mr(e)==z5}const Bf=je.observer(e=>{var o,s,i;const t=J.useTheme(),{store:r}=e,{t:n}=Ie.useTranslation();function a(l,c){c===e.velocity||!G5(c)||e.onVelocityChange(c)}return S.jsxs(J.Stack,{direction:"row",gap:2,alignItems:"center",children:[r.showVelocityLegend&&S.jsx(J.Typography,{sx:{color:(i=(s=(o=t.componentsExt)==null?void 0:o.JoggingPanel)==null?void 0:s.VelocitySlider)==null?void 0:i.sliderLegendColor,fontSize:"14px"},children:n("Jogging.Velocity.bt")}),S.jsx(Df,{value:e.velocity,color:"secondary",onChange:a,min:e.min,max:e.max,"aria-labelledby":"input-slider",disabled:e.disabled,sx:{"& .MuiSlider-valueLabelOpen":{zIndex:100,backgroundColor:"transparent",top:"0px"}}}),r.showVelocitySliderLabel&&(e.renderValue?e.renderValue(e.velocity):S.jsx(xc,{value:e.velocity.toString()}))]})});function xc({value:e,sx:t}){var n;const r=J.useTheme();return S.jsx(J.Stack,{direction:"row",justifyContent:"center",alignItems:"center",gap:"5px",sx:{padding:"6px 12px",background:(n=r.palette.backgroundPaperElevation)==null?void 0:n[8],borderRadius:"10px",minWidth:"111px",...t},children:S.jsx(J.Typography,{component:"span",sx:{textAlign:"right",fontSize:"14px",opacity:.8,color:r.palette.text.primary,whiteSpace:"nowrap"},children:e})})}const Nf=je.observer(({store:e})=>{const{t}=Ie.useTranslation(),r=je.useLocalObservable(()=>({get valueLabelFormat(){return e.currentMotionType==="translate"?n=>`v = ${t("Jogging.Cartesian.Translation.velocityMmPerSec.lb",{amount:n})}`:n=>`ω = ${t("Jogging.Cartesian.Rotation.velocityDegPerSec.lb",{amount:n})}`}}));return S.jsx(Bf,{store:e,velocity:e.velocityInDisplayUnits,min:e.minVelocityInDisplayUnits,max:e.maxVelocityInDisplayUnits,onVelocityChange:e.setVelocityFromSlider,disabled:e.isLocked,renderValue:n=>S.jsx(xc,{value:r.valueLabelFormat(n),sx:{minWidth:"111px",span:{transform:"translateY(-1.5px)"}}})})}),H5=je.observer(({store:e,children:t})=>{const{t:r}=Ie.useTranslation(),n=J.useTheme();function a(h,p){(p==="translate"||p==="rotate")&&e.setSelectedCartesianMotionType(p)}Om(()=>[e.selectedCoordSystemId,e.selectedTcpId],()=>{e.jogger.motionStream.motionStateSocket.changeUrl(e.jogger.nova.makeWebsocketURL(`/motion-groups/${e.jogger.motionGroupId}/state-stream?tcp=${e.selectedTcpId}&response_coordinate_system=${e.selectedCoordSystemId}`))},{fireImmediately:!0});async function o(h,p){const f=await e.activate(),m=f.motionStream.rapidlyChangingMotionState.tcp_pose,b=f.motionStream.rapidlyChangingMotionState.state.joint_position;m&&await e.withMotionLock(async()=>{try{e.setCurrentIncrementJog({axis:h.axis,direction:h.direction}),await e.jogger.runIncrementalCartesianMotion({currentTcpPose:m,currentJoints:b,coordSystemId:e.activeCoordSystemId,velocityInRelevantUnits:e.selectedCartesianMotionType==="translate"?e.translationVelocityMmPerSec:e.rotationVelocityRadsPerSec,axis:h.axis,direction:h.direction,motion:e.selectedCartesianMotionType==="translate"?{type:"translate",distanceMm:p.mm}:{type:"rotate",distanceRads:br.degreesToRadians(p.degrees)}})}finally{e.setCurrentIncrementJog(null),await e.deactivate()}})}async function s(h){if(!e.isLocked){if(await e.activate(),e.activeDiscreteIncrement)return o(h,e.activeDiscreteIncrement);h.motionType==="translate"?await e.jogger.startTCPTranslation({axis:h.axis,direction:h.direction,velocityMmPerSec:e.translationVelocityMmPerSec}):await e.jogger.startTCPRotation({axis:h.axis,direction:h.direction,velocityRadsPerSec:e.rotationVelocityRadsPerSec})}}async function i(){e.isLocked||e.activeDiscreteIncrement||await e.deactivate()}function l(h,p,f){var b,x,V;const m=(V=(x=(b=f.componentsExt)==null?void 0:b.JoggingPanel)==null?void 0:x.JoggingCartesian)==null?void 0:V.Axis;if(m)return p==="translate"?m[h]:m.CustomRotation??m[h]}const c=[{id:"x",icon:S.jsx(JE,{}),colors:l("X",e.selectedCartesianMotionType,n)},{id:"y",icon:S.jsx(YE,{}),colors:l("Y",e.selectedCartesianMotionType,n)},{id:"z",icon:S.jsx(QE,{}),colors:l("Z",e.selectedCartesianMotionType,n)}];function u(h){return r("General.mm.variable",{amount:h.toFixed(1)})}function d(h){return r("General.degree.variable",{amount:br.radiansToDegrees(h).toFixed(1)})}return S.jsxs(J.Stack,{flexGrow:1,gap:2,sx:{padding:"18px 24px"},children:[S.jsxs(J.Stack,{gap:2,children:[S.jsx(f5,{store:e}),S.jsx(Nf,{store:e}),S.jsx(J.Divider,{})]}),S.jsx(J.Stack,{marginLeft:"auto",marginRight:"auto",gap:"24px",justifyContent:"center",sx:{flexGrow:"1"},children:S.jsxs(J.Stack,{alignItems:"center",justifyContent:"center",gap:"24px",sx:{flexGrow:1},children:[S.jsxs(g5,{value:e.selectedCartesianMotionType,onChange:a,exclusive:!0,"aria-label":r("Jogging.Cartesian.MotionType.lb"),sx:{justifyContent:"center"},children:[S.jsx(J.ToggleButton,{value:"translate",children:r("Jogging.Cartesian.Translation.bt")}),S.jsx(J.ToggleButton,{value:"rotate",children:r("Jogging.Cartesian.Rotation.bt")})]}),e.selectedCartesianMotionType==="translate"&&c.map(h=>{var p,f;return S.jsx(Xi,{colors:h.colors,disabled:e.isLocked,activeJoggingDirection:((p=e.incrementJogInProgress)==null?void 0:p.axis)===h.id?e.incrementJogInProgress.direction:void 0,label:S.jsxs(S.Fragment,{children:[h.icon,S.jsx(J.Typography,{sx:{fontSize:"24px",color:((f=h.colors)==null?void 0:f.labelColor)??n.palette.text.primary},children:h.id.toUpperCase()})]}),getDisplayedValue:()=>{var m;return u(((m=e.jogger.motionStream.rapidlyChangingMotionState.tcp_pose)==null?void 0:m.position[h.id])||0)},startJogging:m=>s({axis:h.id,motionType:"translate",direction:m}),stopJogging:i},h.id)}),e.selectedCartesianMotionType==="rotate"&&c.map(h=>{var p,f;return S.jsx(Xi,{colors:h.colors,disabled:e.isLocked,activeJoggingDirection:((p=e.incrementJogInProgress)==null?void 0:p.axis)===h.id?e.incrementJogInProgress.direction:void 0,label:S.jsxs(S.Fragment,{children:[S.jsx(ZE,{}),S.jsx(J.Typography,{sx:{fontSize:"24px",color:((f=h.colors)==null?void 0:f.labelColor)??n.palette.text.primary},children:h.id.toUpperCase()})]}),getDisplayedValue:()=>{var m,b;return d(((b=(m=e.jogger.motionStream.rapidlyChangingMotionState.tcp_pose)==null?void 0:m.orientation)==null?void 0:b[h.id])||0)},startJogging:m=>s({axis:h.id,motionType:"rotate",direction:m}),stopJogging:i},h.id)})]})}),S.jsx(Vf,{store:e}),t&&S.jsx(J.Divider,{}),t]})}),q5=je.observer(({store:e,children:t})=>{const r=J.useTheme();async function n(o){await e.activate(),await e.jogger.startJointRotation({joint:o.joint,direction:o.direction,velocityRadsPerSec:e.rotationVelocityRadsPerSec})}async function a(){await e.jogger.stop(),await e.deactivate()}return S.jsxs(J.Stack,{flexGrow:1,gap:2,sx:{padding:"18px 24px"},children:[S.jsx(Nf,{store:e}),S.jsx(J.Divider,{}),S.jsx(J.Stack,{justifyContent:"center",alignItems:"stretch",sx:{flexGrow:"1"},id:"JointControls",children:S.jsx(J.Stack,{alignItems:"center",gap:"24px",children:e.jogger.motionStream.joints.map(o=>{var c;const s=(c=e.motionGroupSpec.mechanical_joint_limits)==null?void 0:c[o.index],i=(s==null?void 0:s.lower_limit)!==void 0?br.radiansToDegrees(s.lower_limit):void 0,l=(s==null?void 0:s.upper_limit)!==void 0?br.radiansToDegrees(s.upper_limit):void 0;return S.jsxs(J.Stack,{direction:"row",alignItems:"center",justifyContent:"center",spacing:1.5,width:"100%",children:[e.showJointsLegend&&S.jsx(J.Typography,{color:e.isLocked?r.palette.text.disabled:r.palette.text.secondary,children:`G${o.index+1}`}),S.jsx(Tm,{disabled:e.isLocked,lowerLimitDegs:i,upperLimitDegs:l,getValueDegs:()=>{const u=e.jogger.motionStream.rapidlyChangingMotionState.state.joint_position.joints[o.index];return u!==void 0?br.radiansToDegrees(u):void 0},startJogging:u=>n({joint:o.index,direction:u}),stopJogging:a})]},`joint-${o.index}`)})})}),S.jsx(Vf,{store:e}),t&&S.jsx(J.Divider,{}),t]})}),J5=ur(je.observer(e=>{const t=Sl.isString(e.nova)?new FE({instanceUrl:e.nova}):e.nova,r=je.useLocalObservable(()=>({joggingStore:null,loadingError:null}));async function n(){Be.runInAction(()=>{r.loadingError=null,r.joggingStore=null});try{let a=e.store;if(!a){const o=await t.connectJogger(e.motionGroupId);a=await Bs.loadFor(o)}Be.runInAction(()=>{r.joggingStore=a}),e.onSetup&&e.onSetup(a)}catch(a){r.loadingError=a}}return ee.useEffect(()=>(n(),e.store?()=>null:()=>{var a;(a=r.joggingStore)==null||a.dispose()}),[e.store,e.nova,e.motionGroupId]),ee.useEffect(()=>{const a=r.joggingStore;a&&(e.locked?a.lock("external"):a.unlock("external"))},[r.joggingStore,e.locked]),S.jsx(J.Stack,{sx:{maxWidth:"460px",minWidth:"320px",position:"relative",...e.sx},children:r.joggingStore?S.jsx(W5,{store:r.joggingStore,children:e.children}):S.jsx(fc,{message:"Loading jogging",error:r.loadingError})})})),W5=je.observer(({store:e,children:t})=>{const{t:r}=Ie.useTranslation();function n(){if(e.currentTab.id==="cartesian")return S.jsx(S.Fragment,{children:S.jsx(H5,{store:e,children:t})});if(e.currentTab.id==="joint")return S.jsx(S.Fragment,{children:S.jsx(q5,{store:e,children:t})})}return S.jsxs(J.Stack,{flexGrow:1,sx:{overflow:"hidden"},children:[S.jsx(J.Tabs,{value:e.tabIndex,onChange:e.onTabChange,variant:"fullWidth",children:e.tabs.map(a=>{const o=a.label==="cartesian"?r("Jogging.Cartesian.bt"):r("Jogging.Joints.bt"),s=a.label==="cartesian"?S.jsx(xC,{fontSize:"small",sx:{mr:1}}):S.jsx(OC,{fontSize:"small",sx:{mr:1}});return S.jsx(J.Tab,{label:e.showTabIcons?S.jsxs(J.Stack,{direction:"row",alignItems:"center",children:[s,o]}):o,id:`jogging-tab-${a.id}`,"aria-controls":`jogging-tab-${a.id}`},a.id)})}),S.jsx(J.Stack,{flexGrow:1,position:"relative",sx:{overflowY:"auto",overflowX:"hidden"},children:n()})]})}),Ff=ee.forwardRef(({label:e,value:t},r)=>{var i;const n=J.useTheme(),[a,o]=ee.useState(!1);async function s(){if(!r||!("current"in r))return console.warn("No copy target found"),!1;try{return await navigator.clipboard.writeText(t),console.log("Copied!"),o(!0),!0}catch(l){console.error(l);const c=window.getSelection(),u=document.createRange();u.selectNodeContents(r.current),c.removeAllRanges(),c.addRange(u)}return!1}return ee.useEffect(()=>{if(!a)return;const l=setTimeout(()=>o(!1),3e3);return()=>{l&&clearTimeout(l)}},[a]),S.jsx(J.Tooltip,{open:a,title:"Copied!",children:S.jsx(J.Stack,{justifyContent:"center",sx:{height:"100%",boxSizing:"border-box",padding:"6px 12px",background:(i=n.palette.backgroundPaperElevation)==null?void 0:i[8],borderRadius:"10px",minWidth:"0",cursor:"pointer"},onClick:()=>s(),children:S.jsx(J.Typography,{ref:r,align:"center",sx:{pointerEvents:"none",fontSize:"12px",color:n.palette.text.primary,whiteSpace:"nowrap",minWidth:0,textOverflow:"ellipsis",width:"100%",overflow:"hidden"},children:t})})})}),Y5=je.observer(({motionStream:e})=>{const t=ee.useRef(null);function r(){const n=e.rapidlyChangingMotionState.tcp_pose;return n?br.poseToWandelscriptString(n):""}return xn(()=>{if(!t.current)return;const n=r();t.current.textContent!==n&&(t.current.textContent=n)}),S.jsx(J.Stack,{alignItems:"left",spacing:2,sx:{flexGrow:1,minWidth:0,overflow:"hidden"},children:S.jsx(Ff,{value:r(),ref:t})})}),K5=je.observer(({motionStream:e})=>{const t=ee.useRef(null);function r(){const{joints:n}=e.rapidlyChangingMotionState.state.joint_position;return`[${n.map(a=>parseFloat(a.toFixed(4))).join(", ")}]`}return xn(()=>{if(!t.current)return;const n=r();t.current.textContent!==n&&(t.current.textContent=n)}),S.jsx(J.Stack,{alignItems:"left",spacing:2,sx:{flexGrow:1,minWidth:0,overflow:"hidden"},children:S.jsx(Ff,{value:r(),ref:t})})});function Q5(){const e=window.location.href;return e.substring(0,e.indexOf("/",e.indexOf("//")+2))}function X5({baseUrl:e=Q5(),...t}){return S.jsxs(J.Dialog,{"aria-labelledby":"no-motion-group-modal-title",open:!0,fullWidth:!0,sx:{"& .MuiModal-backdrop":{backdropFilter:"blur(10px)"},"& .MuiDialog-paper":{"::before":{content:'""',height:"8px",width:"100%",background:"linear-gradient(90deg, #FF0E65 0%, #47D3FF 100%)"},background:"#101629"}},children:[S.jsx(J.DialogTitle,{id:"no-motion-group-modal-title",children:"No motion group found"}),S.jsxs(J.DialogContent,{sx:{marginTop:"3rem",marginBottom:"1.5rem",textAlign:"center"},children:[S.jsx(J.Typography,{color:"#fff",children:"Found no devices to connect to."}),S.jsx(J.Typography,{color:"#fff",children:"Please ensure a motion group has been created."})]}),S.jsx(J.DialogActions,{children:S.jsxs(J.Stack,{width:"100%",maxWidth:"300px",margin:"auto",marginBottom:"2rem",children:[S.jsx(J.Button,{href:`${e}/settings`,variant:"contained",sx:{borderRadius:"8px",width:"100%"},children:"Go to settings app"}),S.jsx(J.Button,{href:`${e}`,variant:"text",sx:{marginTop:"1rem",color:"#fff",textDecoration:"underline",fontSize:"0.75rem"},children:"Back to Homescreen"})]})})]})}const Z5=ur(je.observer(({state:e,onRun:t,onPause:r,onStop:n,onReset:a,requiresManualReset:o=!1,variant:s="with_pause",className:i})=>{const l=J.useTheme(),{t:c}=Ie.useTranslation(),u=()=>{const p={run:{enabled:e==="idle"||e==="paused",label:c(e==="paused"?"ProgramControl.Resume.bt":"ProgramControl.Start.bt"),color:l.palette.success.main,onClick:t},pause:{enabled:e==="running",label:c("ProgramControl.Pause.bt"),color:"#FFFFFF33",onClick:r||(()=>{})},stop:{enabled:e==="running"||e==="paused",label:c("ProgramControl.Stop.bt"),color:l.palette.error.main,onClick:n}};return s==="without_pause"?[p.run,p.stop]:[p.run,p.pause,p.stop]},d=p=>{const f={sx:{fontSize:"55px"}};if(s==="without_pause")return p===0?S.jsx(En.PlayArrow,{...f}):S.jsx(En.Stop,{...f});switch(p){case 0:return S.jsx(En.PlayArrow,{...f});case 1:return S.jsx(En.Pause,{...f});case 2:return S.jsx(En.Stop,{...f});default:return null}},h=u();return S.jsx(J.Box,{className:i,sx:{display:"flex",flexDirection:"column",alignItems:"center",gap:2},children:S.jsx(J.Box,{sx:{display:"flex",gap:"40px",flexWrap:"wrap",justifyContent:"center",alignItems:"center"},children:h.map((p,f)=>S.jsxs(J.Box,{sx:{display:"flex",flexDirection:"column",alignItems:"center",gap:1},children:[S.jsx(J.Button,{variant:"contained",disabled:!p.enabled||e==="stopping"&&!o,onClick:p.onClick,sx:{width:"110px",height:"110px",borderRadius:"110px",backgroundColor:p.color,opacity:p.enabled&&!(e==="stopping"&&!o)?1:.3,"&:hover":{backgroundColor:p.color,opacity:p.enabled&&!(e==="stopping"&&!o)?.8:.3},"&:disabled":{backgroundColor:p.color,opacity:.3},minWidth:"110px",flexShrink:0},children:d(f)}),S.jsx(J.Typography,{variant:"body1",sx:{color:p.enabled&&!(e==="stopping"&&!o)?p.color:l.palette.text.disabled,textAlign:"center",opacity:p.enabled&&!(e==="stopping"&&!o)?1:.3},children:p.label})]},p.label))})})})),e3=Array(6).fill(2*Math.PI),Th="0.0.0-semantically-released";function Oc(e){let t=Th;return Th.startsWith("0.")&&(t=""),`https://cdn.jsdelivr.net/gh/wandelbotsgmbh/wandelbots-js-react-components${t?`@${t}`:""}/public/models/${e}.glb`}function t3(e){function t(r){return r.children.length===0?[r]:[r,...r.children.flatMap(n=>t(n))]}return t(e).filter(r=>Gf(r))}function zf(e){return e.name.endsWith("_FLG")}function Gf(e){return/_J[0-9]+$/.test(e.name)}function r3(e,t){let r;function n(a){if(zf(a)){if(r)throw Error(`Found multiple flange groups in robot model ${t}; first ${r.name} then ${a.name}. Only one _FLG group is allowed.`);r=a}Gf(a),a.children.map(n)}if(n(e.scene),!r)throw Error(`No flange group found in robot model ${t}. Flange must be identified with a name ending in _FLG.`);return{gltf:e}}function Hf({rapidlyChangingMotionState:e,dhParameters:t,onRotationChanged:r,children:n}){const a=ee.useRef([]),o=ee.useRef([]),s=ee.useRef(null),{invalidate:i}=wc.useThree();ee.useEffect(()=>{const d=e.state.joint_position.joints.filter(h=>h!==void 0);return s.current=new uc(d,{tension:120,friction:20,threshold:.001}),()=>{var h;(h=s.current)==null||h.destroy()}},[]),wc.useFrame((d,h)=>{if(s.current){const p=s.current.update(h);u(),p||i()}});function l(d){d&&(o.current=t3(d),u(),i())}function c(d){var h;a.current=d,(h=s.current)==null||h.setTarget(d)}function u(){var h;const d=((h=s.current)==null?void 0:h.getCurrentValues())||[];if(r)r(o.current,d);else for(const[p,f]of o.current.entries()){const m=t[p],b=m.theta||0,x=m.reverse_rotation_direction?-1:1;f.rotation.y=x*(d[p]||0)+b}}return xm(()=>{const d=e.state.joint_position.joints.filter(h=>h!==void 0);requestAnimationFrame(()=>c(d))}),S.jsx("group",{ref:l,children:n})}const n3="line",a3="mesh";function o3({rapidlyChangingMotionState:e,dhParameters:t,...r}){const n=new vt.Matrix4,a=ee.useRef([]),o=ee.useRef([]);ee.useEffect(()=>{a.current=new Array(t.length).fill(null),o.current=new Array(t.length).fill(null)},[t.length]);function s(c,u){const d=new vt.Vector3,h=new vt.Quaternion,p=new vt.Vector3;n.decompose(d,h,p);const f=d.clone(),m=new vt.Matrix4().makeRotationY(c.theta+u*(c.reverse_rotation_direction?-1:1)).multiply(new vt.Matrix4().makeTranslation(0,c.d/1e3,0)).multiply(new vt.Matrix4().makeTranslation(c.a/1e3,0,0)).multiply(new vt.Matrix4().makeRotationX(c.alpha));return n.multiply(m),n.decompose(d,h,p),{a:f,b:d}}function i(c,u,d,h){if(!t)return;const p=t[c];if(!p)return;const{a:f,b:m}=s(p,h);u.geometry.setPositions([f.toArray(),m.toArray()].flat()),d.position.set(m.x,m.y,m.z)}function l(c,u){n.identity();for(let d=0;d<Math.min(c.length,u.length);d++){const h=a.current[d],p=o.current[d];h&&p&&i(d,h,p,u[d])}}return S.jsx(S.Fragment,{children:S.jsx(Hf,{rapidlyChangingMotionState:e,dhParameters:t,onRotationChanged:l,children:S.jsxs("group",{...r,name:"Scene",children:[S.jsxs("mesh",{children:[S.jsx("sphereGeometry",{args:[.01,32,32]}),S.jsx("meshStandardMaterial",{color:"black",depthTest:!0})]}),t.map((c,u)=>{const{a:d,b:h}=s(c,e.state.joint_position.joints[u]??0),p=`dhrobot_J0${u}`;return S.jsxs("group",{name:p,children:[S.jsx(St.Line,{ref:f=>{a.current[u]=f},name:n3,points:[d,h],color:"white",lineWidth:5}),S.jsxs("mesh",{ref:f=>{o.current[u]=f},name:a3,position:h,children:[S.jsx("sphereGeometry",{args:[.01,32,32]}),S.jsx("meshStandardMaterial",{color:"black",depthTest:!0})]},"mesh_"+u)]},p)})]})})})}const s3=console.warn;function i3(){return ee.useEffect(()=>{console.warn=e=>{e!=="Cannot call the manual advancement of rafz whilst frameLoop is not set as demand"&&s3(e)}},[]),S.jsx(S.Fragment,{})}function l3(e){return e.type==="Mesh"}function c3({modelURL:e,flangeRef:t,postModelRender:r,...n}){const{gltf:a}=r3(St.useGLTF(e),e.split("/").pop()||e),o=ee.useCallback(i=>{i&&r&&r()},[e]);function s(i){return l3(i)?S.jsx("mesh",{name:i.name,geometry:i.geometry,material:i.material,position:i.position,rotation:i.rotation},i.uuid):S.jsx("group",{name:i.name,position:i.position,rotation:i.rotation,ref:zf(i)?t:void 0,children:i.children.map(s)},i.uuid)}return S.jsx("group",{...n,dispose:null,ref:o,children:s(a.scene)})}const u3=(e,t)=>{e.userData.isGhost||(e.traverse(r=>{if(r instanceof ke.Mesh){r.material instanceof ke.Material&&(r.material.colorWrite=!1);const n=r.clone(),a=r.clone();n.material=new ke.MeshStandardMaterial({depthTest:!0,depthWrite:!0,colorWrite:!1,polygonOffset:!0,polygonOffsetFactor:-1,side:ke.DoubleSide}),n.userData.isGhost=!0,a.material=new ke.MeshStandardMaterial({color:t,opacity:.3,depthTest:!0,depthWrite:!1,transparent:!0,polygonOffset:!0,polygonOffsetFactor:-2,side:ke.DoubleSide}),a.userData.isGhost=!0,r.parent&&(r.parent.add(n),r.parent.add(a))}}),e.userData.isGhost=!0)},d3=e=>{if(!e.userData.isGhost)return;const t=[];e.traverse(r=>{var n;r instanceof ke.Mesh&&((n=r.userData)!=null&&n.isGhost?t.push(r):r.material instanceof ke.Material&&(r.material.colorWrite=!0))}),t.forEach(r=>{r.parent&&r.parent.remove(r)}),e.userData.isGhost=!1},qf=ur(({rapidlyChangingMotionState:e,modelFromController:t,dhParameters:r,getModel:n=Oc,flangeRef:a,postModelRender:o,transparentColor:s,...i})=>{const[l,c]=ee.useState(null),u=ee.useCallback(h=>{c(h)},[]);ee.useEffect(()=>{l&&(s?u3(l,s):d3(l))},[l,s]);const d=S.jsx(o3,{rapidlyChangingMotionState:e,dhParameters:r,...i});return S.jsxs(cg.ErrorBoundary,{fallback:d,onError:h=>{console.error(h)},children:[S.jsx(ee.Suspense,{fallback:d,children:S.jsx("group",{ref:u,children:S.jsx(Hf,{rapidlyChangingMotionState:e,dhParameters:r,children:S.jsx(c3,{modelURL:n(t),postModelRender:o,flangeRef:a,...i})})})}),S.jsx(i3,{})]})});function h3({connectedMotionGroup:e,getModel:t=Oc,flangeRef:r,transparentColor:n,...a}){return e.dhParameters?S.jsx(qf,{rapidlyChangingMotionState:e.rapidlyChangingMotionState,modelFromController:e.modelFromController||"",dhParameters:e.dhParameters,getModel:t,flangeRef:r,transparentColor:n,...a}):null}const p3=({title:e,titleId:t,...r},n)=>B.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.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"})),m3=ee.forwardRef(p3),f3=({title:e,titleId:t,...r},n)=>B.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.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"})),g3=ee.forwardRef(f3),_t=je.observer(({id:e,icon:t,color:r,title:n,name:a,label:o,explanation:s,literalValue:i,anchorOrigin:l,transformOrigin:c})=>{const u=je.useLocalObservable(()=>({anchorEl:null,get isPopoverOpen(){return!!u.anchorEl},openPopover(d){u.anchorEl=d.currentTarget},closePopover(){u.anchorEl=null}}));return S.jsxs(S.Fragment,{children:[S.jsxs(J.Stack,{"aria-owns":u.isPopoverOpen?e:void 0,"aria-haspopup":"true",onMouseEnter:u.openPopover,onMouseLeave:u.closePopover,direction:"row",spacing:1,sx:{cursor:"pointer"},children:[S.jsx(J.SvgIcon,{component:t,sx:{color:r}}),o&&S.jsx("div",{style:{color:r},children:o})]}),S.jsx(J.Popover,{id:e,sx:{pointerEvents:"none"},open:u.isPopoverOpen,anchorEl:u.anchorEl,anchorOrigin:l??{vertical:"bottom",horizontal:"left"},transformOrigin:c??{vertical:"top",horizontal:"left"},onClose:u.closePopover,disableRestoreFocus:!0,children:S.jsxs(J.Stack,{gap:"1rem",padding:2,maxWidth:"450px",sx:{wordWrap:"break-word"},children:[S.jsxs("div",{children:[n&&S.jsx(J.Typography,{component:"span",fontSize:"14px",children:`${n}: `}),S.jsx(J.Typography,{component:"span",color:r,fontWeight:"bold",fontSize:"14px",children:a})]}),S.jsx(J.Typography,{fontSize:"14px",children:s}),i&&S.jsx(J.Typography,{fontSize:"12px",children:i})]})})]})}),y3=je.observer(({isVirtual:e,motionGroupId:t,anchorOrigin:r,transformOrigin:n,compact:a})=>{const o=J.useTheme(),{t:s}=Ie.useTranslation();return e?S.jsx(_t,{id:"motion-group-virtual",icon:g3,color:o.palette.tertiary.main,name:s("SafetyBar.ControllerType.Virtual.lb"),label:a?null:s("SafetyBar.ControllerType.Virtual.lb"),explanation:S.jsxs(Ie.Trans,{i18nKey:"SafetyBar.MotionGroup.Virtual.Explanation.lb",values:{motionGroupId:t},children:["Motion group ",S.jsx("code",{children:t})," refers to a virtual robot with no physical counterpart. It can be freely manipulated without special safety precautions."]}),anchorOrigin:r,transformOrigin:n}):S.jsx(_t,{id:"motion-group-physical",icon:m3,color:o.palette.primary.main,name:s("SafetyBar.ControllerType.Physical.lb"),label:a?null:s("SafetyBar.ControllerType.Physical.lb"),explanation:S.jsx(Ie.Trans,{i18nKey:"SafetyBar.MotionGroup.Physical.Explanation.lb",values:{motionGroupId:t},components:{code:S.jsx("code",{}),strong:S.jsx("strong",{})}}),anchorOrigin:r,transformOrigin:n})}),b3=({title:e,titleId:t,...r},n)=>B.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.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"})),v3=ee.forwardRef(b3),S3=({title:e,titleId:t,...r},n)=>B.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.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:.56})),x3=ee.forwardRef(S3),O3=({title:e,titleId:t,...r},n)=>B.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.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"})),w3=ee.forwardRef(O3),C3=je.observer(({operationMode:e,anchorOrigin:t,transformOrigin:r,compact:n})=>{const{t:a}=Ie.useTranslation(),o=J.useTheme();switch(e){case"OPERATION_MODE_AUTO":return S.jsx(_t,{id:"operation-mode-auto",icon:v3,title:a("SafetyBar.OperationMode.ti"),name:a("SafetyBar.OperationMode.Automatic.ti"),label:n?null:a("SafetyBar.OperationMode.Automatic.ti"),color:o.palette.text.secondary,explanation:S.jsx(Ie.Trans,{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."}),anchorOrigin:t,transformOrigin:r});case"OPERATION_MODE_MANUAL":case"OPERATION_MODE_MANUAL_T1":case"OPERATION_MODE_MANUAL_T2":return S.jsx(_t,{id:"operation-mode-manual",icon:w3,color:o.palette.warning.main,title:a("SafetyBar.OperationMode.ti"),name:a("SafetyBar.OperationMode.Manual.lb"),label:n?null:a("SafetyBar.OperationMode.Manual.lb"),explanation:S.jsx(Ie.Trans,{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."}),literalValue:e,anchorOrigin:t,transformOrigin:r});default:return S.jsx(_t,{id:"operation-mode-error",icon:x3,color:o.palette.warning.main,title:a("SafetyBar.OperationMode.ti"),name:a("SafetyBar.OperationMode.Error.lb"),label:n?null:a("SafetyBar.OperationMode.Error.lb"),explanation:S.jsx(Ie.Trans,{i18nKey:"SafetyBar.OperationMode.Error.Explanation.lb",children:"The robot controller has entered an unexpected operation mode. Motion group movement may not be possible."}),literalValue:e,anchorOrigin:t,transformOrigin:r})}}),P3=({title:e,titleId:t,...r},n)=>B.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.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"})),T3=ee.forwardRef(P3),A3=({title:e,titleId:t,...r},n)=>B.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.createElement("path",{d:"M10.24 10.636 12 13.764l1.76-3.128h-3.52Z"}),B.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"}),B.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"})),R3=ee.forwardRef(A3),V3=({title:e,titleId:t,...r},n)=>B.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.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:.56})),_3=ee.forwardRef(V3),E3=({title:e,titleId:t,...r},n)=>B.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.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"})),I3=ee.forwardRef(E3),M3=({title:e,titleId:t,...r},n)=>B.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?B.createElement("title",{id:t},e):null,B.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"})),$3=ee.forwardRef(M3),j3=je.observer(({safetyState:e,anchorOrigin:t,transformOrigin:r,compact:n})=>{const{t:a}=Ie.useTranslation(),o=J.useTheme();switch(e){case"SAFETY_STATE_NORMAL":return S.jsx(_t,{id:"safety-state-normal",title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.Normal.lb"),label:n?null:a("SafetyBar.SafetyState.Normal.lb"),icon:I3,color:o.palette.text.secondary,explanation:S.jsx(Ie.Trans,{i18nKey:"SafetyBar.SafetyState.Normal.Explanation.lb",children:"The robot controller is in a normal safety state. Movement is not prevented by this state."}),anchorOrigin:t,transformOrigin:r});case"SAFETY_STATE_DEVICE_EMERGENCY_STOP":case"SAFETY_STATE_ROBOT_EMERGENCY_STOP":return S.jsx(_t,{id:"safety-state-estop",title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.Estop.lb"),label:n?null:a("SafetyBar.SafetyState.Estop.lb"),icon:R3,color:o.palette.error.main,explanation:S.jsx(Ie.Trans,{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."}),literalValue:e,anchorOrigin:t,transformOrigin:r});case"SAFETY_STATE_STOP_0":case"SAFETY_STATE_STOP_1":case"SAFETY_STATE_STOP_2":case"SAFETY_STATE_PROTECTIVE_STOP":case"SAFETY_STATE_STOP":return S.jsx(_t,{id:"safety-state-stop",icon:$3,title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.Stop.lb"),label:n?null:a("SafetyBar.SafetyState.Stop.lb"),color:o.palette.warning.main,explanation:S.jsx(Ie.Trans,{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."}),literalValue:e,anchorOrigin:t,transformOrigin:r});case"SAFETY_STATE_REDUCED":case"SAFETY_STATE_MASTERING":case"SAFETY_STATE_CONFIRM_SAFETY":case"SAFETY_STATE_OPERATOR_SAFETY":case"SAFETY_STATE_RECOVERY":case"SAFETY_STATE_VIOLATION":return S.jsx(_t,{id:"safety-state-manual-action-required",icon:_3,color:o.palette.warning.main,title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.ManualActionRequired.lb"),label:n?null:a("SafetyBar.SafetyState.ManualActionRequired.lb"),explanation:S.jsx(Ie.Trans,{i18nKey:"SafetyBar.SafetyState.ManualActionRequired.Explanation.lb",children:"The robot controller has entered a safety state requiring manual action to resolve."}),literalValue:e,anchorOrigin:t,transformOrigin:r});case"SAFETY_STATE_UNKNOWN":case"SAFETY_STATE_FAULT":return S.jsx(_t,{id:"safety-state-error",icon:T3,color:o.palette.error.main,title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.Error.lb"),label:n?null:a("SafetyBar.SafetyState.Error.lb"),explanation:S.jsx(Ie.Trans,{i18nKey:"SafetyBar.SafetyState.Error.Explanation.lb",children:"The robot controller has entered an unexpected safety state."}),literalValue:e,anchorOrigin:t,transformOrigin:r});default:GE(e,`Unknown safety state ${e}`)}}),k3=ur(je.observer(({isVirtual:e,motionGroupId:t,operationMode:r,safetyState:n,anchorOrigin:a,transformOrigin:o,compact:s=!0})=>{const i=s?1:2;return S.jsxs(J.Stack,{direction:"row",gap:i,alignItems:"center",sx:{height:"24px"},children:[S.jsx(j3,{safetyState:n,anchorOrigin:a,transformOrigin:o,compact:s}),S.jsx(J.Divider,{orientation:"vertical",flexItem:!0}),S.jsx(C3,{operationMode:r,anchorOrigin:a,transformOrigin:o,compact:s}),S.jsx(J.Divider,{orientation:"vertical",flexItem:!0}),S.jsx(y3,{isVirtual:e,motionGroupId:t,anchorOrigin:a,transformOrigin:o,compact:s})]})})),U3=J.styled(J.Fab,{shouldForwardProp:e=>e!=="selected"})(({theme:e})=>{var t,r,n;return{borderRadius:"20px","&:hover":{background:(t=e.palette.backgroundPaperElevation)==null?void 0:t[7]},variants:[{props:({selected:a})=>!a,style:{background:(r=e.palette.backgroundPaperElevation)==null?void 0:r[0],color:e.palette.action.disabled,"> img":{opacity:.4}}},{props:({selected:a})=>a,style:{background:(n=e.palette.backgroundPaperElevation)==null?void 0:n[11],border:`1px solid ${e.palette.divider}`,color:e.palette.primary.contrastText}}]}}),L3=ee.forwardRef((e,t)=>S.jsx(U3,{ref:t,selected:e.selected,...e,color:"secondary",variant:"circular"})),D3={$schema:"https://raw.githubusercontent.com/martinring/tmlanguage/master/tmlanguage.json",name:"wandelscript",patterns:[{include:"#keywords"},{include:"#strings"},{include:"#comments"},{include:"#functions"}],repository:{keywords:{patterns:[{name:"keyword.control.flow.wandelscript",match:"\\b(move|via|to|interrupt|def|False|True|for|if|else|elif|while|return|switch|activate|deactivate|print|and|or|not)\\b"}]},strings:{name:"string.quoted.double.wandelscript",begin:'"',end:'"',patterns:[{name:"constant.character.escape.wandelscript",match:"\\\\."}]},comments:{patterns:[{begin:"#",beginCaptures:{0:{name:"punctuation.definition.comment.wandelscript"}},end:"$",name:"comment.line.number-sign.wandelscript"}]},functions:{patterns:[{match:"[a-zA-Z_-]+\\(",name:"entity.name.function.wandelscript"}]}},scopeName:"source.wandelscript"},B3=ee.lazy(()=>import("@monaco-editor/react"));let ji=null;async function N3(){if(!ji){const[{createHighlighter:e},{shikiToMonaco:t}]=await Promise.all([import("shiki"),import("@shikijs/monaco")]);ji={shiki:await e({langs:[D3],themes:["dark-plus","light-plus"]}),shikiToMonaco:t}}return ji}const F3=ur(e=>{const t=J.useTheme(),[r,n]=ee.useState("dark-plus"),a=t.palette.mode==="dark"?"dark-plus":"light-plus";async function o(s){var c,u;s.languages.register({id:"wandelscript"}),s.languages.setLanguageConfiguration("wandelscript",{comments:{lineComment:"#"},brackets:[["(",")"],["[","]"]],autoClosingPairs:[{open:"[",close:"]"},{open:"(",close:")"}],surroundingPairs:[{open:"[",close:"]"},{open:"(",close:")"}]});const{shiki:i,shikiToMonaco:l}=await N3();l(i,s),s.editor.defineTheme(a,((u=(c=t.componentsExt)==null?void 0:c.WandelscriptEditor)==null?void 0:u.monacoTheme)??{base:t.palette.mode==="dark"?"vs-dark":"vs",inherit:!0,rules:[],colors:{}}),e.monacoSetup&&e.monacoSetup(s),n(a)}return S.jsx(ee.Suspense,{fallback:S.jsx(fc,{}),children:S.jsx(B3,{value:e.code,onMount:(s,i)=>{o(i)},onChange:e.onChange,defaultLanguage:"wandelscript",theme:r,options:{minimap:{enabled:!1},wordWrap:"on",automaticLayout:!0,...e.monacoOptions}})})});function Jf(){var t,r,n,a,o,s,i;const e=J.createTheme({palette:{mode:"dark",text:{primary:"rgba(255, 255, 255, 1)",secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.38)"},primary:{main:"rgba(142, 86, 252, 1)",dark:"rgba(136, 58, 255, 1)",light:"rgba(157, 131, 246, 1)",contrastText:"rgba(255, 255, 255, 0.87)"},secondary:{main:"rgba(255, 255, 255, 1)",dark:"rgba(255, 255, 255, 0.06)",contrastText:"rgba(255, 255, 255, 0.87)"},tertiary:{main:"rgba(100, 255, 218, 1)",dark:"rgba(38, 166, 154, 1)",light:"rgba(167, 255, 235, 1)",contrastText:"rgba(0, 0, 0, 1)"},error:{main:"rgba(239, 83, 80, 1)",dark:"rgba(229, 57, 53, 1)",light:"rgba(239, 154, 154, 1)",contrastText:"rgba(255, 255, 255, 1)"},warning:{main:"rgba(255, 171, 64, 1)",dark:"rgba(255, 145, 0, 1)",light:"rgba(255, 209, 128, 1)",contrastText:"rgba(0, 0, 0, 0.87)"},success:{main:"rgba(38, 166, 154, 1)",dark:"rgba(0, 121, 107, 1)",light:"rgba(128, 203, 196, 1)",contrastText:"rgba(255, 255, 255, 0.87)"},background:{default:"rgba(2, 6, 23, 1)",paper:"rgba(17, 19, 31, 1)"},action:{active:"rgba(255, 255, 255, 0.56)",hover:"rgba(255, 255, 255, 0.08)",selected:"rgba(255, 255, 255, 0.16)",disabledBackground:"rgba(255, 255, 255, 0.12)",focus:"rgba(255, 255, 255, 0.12)",disabled:"rgba(255, 255, 255, 0.38)"},common:{white:"rgba(255, 255, 255, 1)",black:"rgba(0, 0, 0, 1)"},divider:"rgba(255, 255, 255, 0.12)",backgroundPaperElevation:{0:"rgba(17,19,31,1.0)",1:"rgba(20,22,35,1.0)",2:"rgba(23,25,39,1.0)",3:"rgba(26,28,43,1.0)",4:"rgba(29,31,47,1.0)",5:"rgba(32,34,51,1.0)",6:"rgba(35,37,55,1.0)",7:"rgba(38,40,59,1.0)",8:"rgba(41,43,63,1.0)",9:"rgba(44,46,67,1.0)",10:"rgba(47,49,71,1.0)",11:"rgba(50,52,75,1.0)",12:"rgba(53,55,79,1.0)",13:"rgba(56,58,83,1.0)",14:"rgba(59,61,87,1.0)",15:"rgba(62,64,91,1.0)",16:"rgba(57,63,87,1.0)"}},paletteExt:{primary:{hover:"rgba(142, 86, 252, 0.08)",selected:"rgba(142, 86, 252, 0.16)",focus:"rgba(142, 86, 252, 0.12)",focusVisible:"rgba(142, 86, 252, 0.3)",outlineBorder:"rgba(142, 86, 252, 0.5)"},secondary:{tonal:"rgba(255,255,255,0.1)"}}});return{...e,components:{MuiCssBaseline:{styleOverrides:{"html, body, *":{scrollbarWidth:"none",msOverflowStyle:"none"},"html:hover, body:hover, *:hover":{scrollbarWidth:"thin",scrollbarColor:`${e.palette.divider} transparent`}}},MuiButton:{styleOverrides:{root:{textTransform:"none",borderRadius:"10px"}},variants:[{props:{color:"secondary",variant:"contained"},style:{border:`1px solid ${e.palette.divider}`,background:(n=(r=(t=e.paletteExt)==null?void 0:t.secondary)==null?void 0:r.tonal)==null?void 0:n.toString()}},{props:{color:"secondary",variant:"outlined"},style:{border:`1px solid ${e.palette.divider}`}}]},MuiTab:{styleOverrides:{root:{textTransform:"none",color:e.palette.text.secondary,"&.Mui-selected":{color:e.palette.text.primary}}}},MuiTabs:{styleOverrides:{root:{background:(a=e.palette.backgroundPaperElevation)==null?void 0:a[1]}}},MuiToggleButtonGroup:{styleOverrides:{root:{".MuiToggleButtonGroup-firstButton":{borderRadius:"10px 0 0 10px"},".MuiToggleButtonGroup-lastButton":{borderRadius:"0 10px 10px 0"}}}},MuiToggleButton:{styleOverrides:{root:{textTransform:"none",padding:"6px 16px"}}},MuiSelect:{variants:[{props:{variant:"filled"},style:{borderRadius:"10px","::before, ::after":{visibility:"collapse"},".MuiInputBase-input":{padding:"6px 16px",borderRadius:"10px"}}}]},MuiDrawer:{styleOverrides:{paper:{border:"none",boxShadow:"4px 0 8px -4px rgba(0, 0, 0, 0.3)"}}},MuiFab:{styleOverrides:{root:{background:(s=(o=e.paletteExt)==null?void 0:o.secondary)==null?void 0:s.tonal}},variants:[{props:{color:"primary"},style:{background:e.palette.primary.main}}]}},componentsExt:{JoggingPanel:{JoggingCartesian:{Axis:{X:{backgroundColor:"rgba(215, 66, 56, 1)",borderColor:"rgba(215, 66, 56, 1)",buttonBackgroundColor:{default:"rgba(241, 77, 66, 1)",pressed:"rgba(138, 41, 35, 1)",hovered:"rgba(241, 77, 66, 1)",disabled:"rgba(241, 77, 66, 1)"},color:"rgba(255, 198, 198, 1)",labelColor:e.palette.text.primary},Y:{backgroundColor:"rgba(20, 151, 108, 1)",borderColor:"rgba(20, 151, 108, 1)",buttonBackgroundColor:{default:"rgba(28, 188, 135, 1)",pressed:"rgba(11, 89, 63, 1)",disabled:"rgba(28, 188, 135, 1)",hovered:"rgba(28, 188, 135, 1)"},color:"rgba(215, 255, 242, 1)",labelColor:e.palette.text.primary},Z:{backgroundColor:"rgba(1, 87, 155, 1)",borderColor:"rgba(1, 87, 155, 1)",buttonBackgroundColor:{default:"rgba(2, 136, 209, 1)",pressed:"rgba(2, 64, 114, 1)",disabled:"rgba(2, 136, 209, 1)",hovered:"rgba(2, 136, 209, 1)"},color:"rgba(210, 239, 255, 1)",labelColor:e.palette.text.primary}}},JoggingJoint:{Joint:{arrowColor:e.palette.text.primary}},VelocitySlider:{sliderLegendColor:e.palette.text.primary}},WandelscriptEditor:{monacoTheme:{base:"vs-dark",inherit:!0,rules:[{token:"keyword",foreground:"#b349a9ff"}],colors:{"editor.background":J.rgbToHex(((i=e.palette.backgroundPaperElevation)==null?void 0:i[5])??""),"editor.foreground":"#d4d4d4","editorLineNumber.foreground":"#797979","editorLineNumber.activeForeground":"#e9e9e9","editor.lineHighlightBorder":"#e9e9e911"}}}}}}function z3(){const e=Jf();return e.palette.mode="light",e}function G3(e){var n,a,o,s;let t=!0;((n=e.palette)==null?void 0:n.mode)==="light"?t=!1:((a=e.palette)==null?void 0:a.mode)!=="dark"&&(t=!(typeof window<"u"&&((s=(o=window.matchMedia)==null?void 0:o.call(window,"(prefers-color-scheme: light)"))==null?void 0:s.matches)));const r=t?Jf():z3();return Kh(r,e)}exports.CycleTimer=Bw;exports.JoggingCartesianAxisControl=Xi;exports.JoggingJointRotationControl=Tm;exports.JoggingPanel=J5;exports.JoggingStore=Bs;exports.LoadingCover=fc;exports.LoadingErrorMessage=bf;exports.NoMotionGroupModal=X5;exports.PoseCartesianValues=Y5;exports.PoseJointValues=K5;exports.PresetEnvironment=mg;exports.ProgramControl=Z5;exports.Robot=h3;exports.SafetyBar=k3;exports.SafetyZonesRenderer=yg;exports.SelectableFab=L3;exports.SupportedRobot=qf;exports.TrajectoryRenderer=bg;exports.ValueInterpolator=uc;exports.VelocitySlider=Bf;exports.VelocitySliderLabel=xc;exports.WandelscriptEditor=F3;exports.createNovaMuiTheme=G3;exports.defaultAxisConfig=e3;exports.defaultGetModel=Oc;exports.i18n=cc;exports.useAnimationFrame=xn;exports.useAutorun=xm;exports.useInterpolation=Sm;exports.useMounted=Cs;exports.useReaction=Om;
|
|
145
|
+
*/var WA=function(){if(typeof WebSocket<"u")return WebSocket},YA=function(e){return typeof e<"u"&&!!e&&e.CLOSING===2},hr={maxReconnectionDelay:1e4,minReconnectionDelay:1e3+Math.random()*4e3,minUptime:5e3,reconnectionDelayGrowFactor:1.3,connectionTimeout:4e3,maxRetries:1/0,maxEnqueuedMessages:1/0},KA=function(){function e(t,r,n){var a=this;n===void 0&&(n={}),this._listeners={error:[],message:[],open:[],close:[]},this._retryCount=-1,this._shouldReconnect=!0,this._connectLock=!1,this._binaryType="blob",this._closeCalled=!1,this._messageQueue=[],this.onclose=null,this.onerror=null,this.onmessage=null,this.onopen=null,this._handleOpen=function(o){a._debug("open event");var s=a._options.minUptime,i=s===void 0?hr.minUptime:s;clearTimeout(a._connectTimeout),a._uptimeTimeout=setTimeout(function(){return a._acceptOpen()},i),a._ws.binaryType=a._binaryType,a._messageQueue.forEach(function(l){return a._ws.send(l)}),a._messageQueue=[],a.onopen&&a.onopen(o),a._listeners.open.forEach(function(l){return a._callEventListener(o,l)})},this._handleMessage=function(o){a._debug("message event"),a.onmessage&&a.onmessage(o),a._listeners.message.forEach(function(s){return a._callEventListener(o,s)})},this._handleError=function(o){a._debug("error event",o.message),a._disconnect(void 0,o.message==="TIMEOUT"?"timeout":void 0),a.onerror&&a.onerror(o),a._debug("exec error listeners"),a._listeners.error.forEach(function(s){return a._callEventListener(o,s)}),a._connect()},this._handleClose=function(o){a._debug("close event"),a._clearTimeouts(),a._shouldReconnect&&a._connect(),a.onclose&&a.onclose(o),a._listeners.close.forEach(function(s){return a._callEventListener(o,s)})},this._url=t,this._protocols=r,this._options=n,this._options.startClosed&&(this._shouldReconnect=!1),this._connect()}return Object.defineProperty(e,"CONNECTING",{get:function(){return 0},enumerable:!0,configurable:!0}),Object.defineProperty(e,"OPEN",{get:function(){return 1},enumerable:!0,configurable:!0}),Object.defineProperty(e,"CLOSING",{get:function(){return 2},enumerable:!0,configurable:!0}),Object.defineProperty(e,"CLOSED",{get:function(){return 3},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"CONNECTING",{get:function(){return e.CONNECTING},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"OPEN",{get:function(){return e.OPEN},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"CLOSING",{get:function(){return e.CLOSING},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"CLOSED",{get:function(){return e.CLOSED},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"binaryType",{get:function(){return this._ws?this._ws.binaryType:this._binaryType},set:function(t){this._binaryType=t,this._ws&&(this._ws.binaryType=t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"retryCount",{get:function(){return Math.max(this._retryCount,0)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"bufferedAmount",{get:function(){var t=this._messageQueue.reduce(function(r,n){return typeof n=="string"?r+=n.length:n instanceof Blob?r+=n.size:r+=n.byteLength,r},0);return t+(this._ws?this._ws.bufferedAmount:0)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"extensions",{get:function(){return this._ws?this._ws.extensions:""},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"protocol",{get:function(){return this._ws?this._ws.protocol:""},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"readyState",{get:function(){return this._ws?this._ws.readyState:this._options.startClosed?e.CLOSED:e.CONNECTING},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"url",{get:function(){return this._ws?this._ws.url:""},enumerable:!0,configurable:!0}),e.prototype.close=function(t,r){if(t===void 0&&(t=1e3),this._closeCalled=!0,this._shouldReconnect=!1,this._clearTimeouts(),!this._ws){this._debug("close enqueued: no ws instance");return}if(this._ws.readyState===this.CLOSED){this._debug("close: already closed");return}this._ws.close(t,r)},e.prototype.reconnect=function(t,r){this._shouldReconnect=!0,this._closeCalled=!1,this._retryCount=-1,!this._ws||this._ws.readyState===this.CLOSED?this._connect():(this._disconnect(t,r),this._connect())},e.prototype.send=function(t){if(this._ws&&this._ws.readyState===this.OPEN)this._debug("send",t),this._ws.send(t);else{var r=this._options.maxEnqueuedMessages,n=r===void 0?hr.maxEnqueuedMessages:r;this._messageQueue.length<n&&(this._debug("enqueue",t),this._messageQueue.push(t))}},e.prototype.addEventListener=function(t,r){this._listeners[t]&&this._listeners[t].push(r)},e.prototype.dispatchEvent=function(t){var r,n,a=this._listeners[t.type];if(a)try{for(var o=zA(a),s=o.next();!s.done;s=o.next()){var i=s.value;this._callEventListener(t,i)}}catch(l){r={error:l}}finally{try{s&&!s.done&&(n=o.return)&&n.call(o)}finally{if(r)throw r.error}}return!0},e.prototype.removeEventListener=function(t,r){this._listeners[t]&&(this._listeners[t]=this._listeners[t].filter(function(n){return n!==r}))},e.prototype._debug=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];this._options.debug&&console.log.apply(console,HA(["RWS>"],t))},e.prototype._getNextDelay=function(){var t=this._options,r=t.reconnectionDelayGrowFactor,n=r===void 0?hr.reconnectionDelayGrowFactor:r,a=t.minReconnectionDelay,o=a===void 0?hr.minReconnectionDelay:a,s=t.maxReconnectionDelay,i=s===void 0?hr.maxReconnectionDelay:s,l=0;return this._retryCount>0&&(l=o*Math.pow(n,this._retryCount-1),l>i&&(l=i)),this._debug("next delay",l),l},e.prototype._wait=function(){var t=this;return new Promise(function(r){setTimeout(r,t._getNextDelay())})},e.prototype._getNextUrl=function(t){if(typeof t=="string")return Promise.resolve(t);if(typeof t=="function"){var r=t();if(typeof r=="string")return Promise.resolve(r);if(r.then)return r}throw Error("Invalid URL")},e.prototype._connect=function(){var t=this;if(!(this._connectLock||!this._shouldReconnect)){this._connectLock=!0;var r=this._options,n=r.maxRetries,a=n===void 0?hr.maxRetries:n,o=r.connectionTimeout,s=o===void 0?hr.connectionTimeout:o,i=r.WebSocket,l=i===void 0?WA():i;if(this._retryCount>=a){this._debug("max retries reached",this._retryCount,">=",a);return}if(this._retryCount++,this._debug("connect",this._retryCount),this._removeListeners(),!YA(l))throw Error("No valid WebSocket class provided");this._wait().then(function(){return t._getNextUrl(t._url)}).then(function(c){t._closeCalled||(t._debug("connect",{url:c,protocols:t._protocols}),t._ws=t._protocols?new l(c,t._protocols):new l(c),t._ws.binaryType=t._binaryType,t._connectLock=!1,t._addListeners(),t._connectTimeout=setTimeout(function(){return t._handleTimeout()},s))})}},e.prototype._handleTimeout=function(){this._debug("timeout event"),this._handleError(new qA(Error("TIMEOUT"),this))},e.prototype._disconnect=function(t,r){if(t===void 0&&(t=1e3),this._clearTimeouts(),!!this._ws){this._removeListeners();try{this._ws.close(t,r),this._handleClose(new JA(t,r,this))}catch{}}},e.prototype._acceptOpen=function(){this._debug("accept open"),this._retryCount=0},e.prototype._callEventListener=function(t,r){"handleEvent"in r?r.handleEvent(t):r(t)},e.prototype._removeListeners=function(){this._ws&&(this._debug("removeListeners"),this._ws.removeEventListener("open",this._handleOpen),this._ws.removeEventListener("close",this._handleClose),this._ws.removeEventListener("message",this._handleMessage),this._ws.removeEventListener("error",this._handleError))},e.prototype._addListeners=function(){this._ws&&(this._debug("addListeners"),this._ws.addEventListener("open",this._handleOpen),this._ws.addEventListener("close",this._handleClose),this._ws.addEventListener("message",this._handleMessage),this._ws.addEventListener("error",this._handleError))},e.prototype._clearTimeouts=function(){clearTimeout(this._connectTimeout),clearTimeout(this._uptimeTimeout)},e}(),QA=Object.defineProperty,XA=Object.defineProperties,ZA=Object.getOwnPropertyDescriptors,Md=Object.getOwnPropertySymbols,e_=Object.prototype.hasOwnProperty,t_=Object.prototype.propertyIsEnumerable,$d=(e,t,r)=>t in e?QA(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,rn=(e,t)=>{for(var r in t||(t={}))e_.call(t,r)&&$d(e,r,t[r]);if(Md)for(var r of Md(t))t_.call(t,r)&&$d(e,r,t[r]);return e},ol=(e,t)=>XA(e,ZA(t)),Ae=(e,t,r)=>new Promise((n,a)=>{var o=l=>{try{i(r.next(l))}catch(c){a(c)}},s=l=>{try{i(r.throw(l))}catch(c){a(c)}},i=l=>l.done?n(l.value):Promise.resolve(l.value).then(o,s);i((r=r.apply(e,t)).next())}),r_=class extends KA{constructor(e,t={}){console.log("Opening websocket to",e),super(()=>this.targetUrl||e,void 0,{startClosed:!0}),this.opts=t,this.disposed=!1,Object.defineProperty(this,"url",{get(){return this.targetUrl}}),this.targetUrl=e,this.addEventListener("open",()=>{console.log(`Websocket to ${this.url} opened`)}),this.addEventListener("message",n=>{this.receivedFirstMessage||(this.receivedFirstMessage=n)}),this.addEventListener("close",()=>{console.log(`Websocket to ${this.url} closed`)});const r=this.reconnect;this.reconnect=()=>{this.opts.mock?this.opts.mock.handleWebsocketConnection(this):r.apply(this)},this.reconnect()}changeUrl(e){this.receivedFirstMessage=void 0,this.targetUrl=e,this.reconnect()}sendJson(e){this.opts.mock?this.opts.mock.handleWebsocketMessage(this,JSON.stringify(e)):this.send(JSON.stringify(e))}dispose(){this.close(),this.disposed=!0,this.opts.onDispose&&this.opts.onDispose()}opened(){return Ae(this,null,function*(){return new Promise((e,t)=>{this.readyState===WebSocket.OPEN?e():(this.addEventListener("open",()=>e()),this.addEventListener("error",t))})})}closed(){return Ae(this,null,function*(){return new Promise((e,t)=>{this.readyState===WebSocket.CLOSED?e():(this.addEventListener("close",()=>e()),this.addEventListener("error",t))})})}firstMessage(){return Ae(this,null,function*(){return this.receivedFirstMessage?this.receivedFirstMessage:new Promise((e,t)=>{const r=a=>{this.receivedFirstMessage=a,this.removeEventListener("message",r),this.removeEventListener("error",n),e(a)},n=a=>{this.removeEventListener("message",r),this.removeEventListener("error",n),t(a)};this.addEventListener("message",r),this.addEventListener("error",n)})})}nextMessage(){return Ae(this,null,function*(){return new Promise((e,t)=>{const r=a=>{this.removeEventListener("message",r),this.removeEventListener("error",n),e(a)},n=a=>{this.removeEventListener("message",r),this.removeEventListener("error",n),t(a)};this.addEventListener("message",r),this.addEventListener("error",n)})})}},n_=class{constructor(){this.available=typeof window<"u"&&!!window.localStorage}getJSON(e){if(!this.available)return null;const t=window.localStorage.getItem(e);if(t===null)return null;try{return JSON.parse(t)}catch{return null}}setJSON(e,t){if(!this.available)return null;window.localStorage.setItem(e,JSON.stringify(t))}delete(e){if(!this.available)return null;window.localStorage.removeItem(e)}setString(e,t){if(!this.available)return null;window.localStorage.setItem(e,t)}getString(e){return this.available?window.localStorage.getItem(e):null}},Ci=new n_;function ar(e){try{return JSON.parse(e)}catch{return}}function a_(e,t){return e||(e="world"),t||(t="world"),e===t}var sn="wandelbots.io",Pi={dev:{domain:`https://auth.portal.dev.${sn}`,clientId:"fLbJD0RLp5r2Dpucm5j8BjwMR6Hunfha"},stg:{domain:`https://auth.portal.stg.${sn}`,clientId:"joVDeD9e786WzFNSGCqoVq7HNkWt5j6s"},prod:{domain:`https://auth.portal.${sn}`,clientId:"J7WJUi38xVQdJAEBNRT9Xw1b0fXDb4J2"}},o_=e=>{if(e.includes(`dev.${sn}`))return Pi.dev;if(e.includes(`stg.${sn}`))return Pi.stg;if(e.includes(sn))return Pi.prod;throw new Error("Unsupported instance URL. Cannot determine Auth0 configuration.")},s_=e=>Ae(void 0,null,function*(){var t;if(typeof window>"u")throw new Error("Access token must be set to use NovaClient when not in a browser environment.");const r=o_(e);if(new URL(e).origin===window.location.origin)throw window.location.reload(),new Error("Failed to reload page to get auth details, please refresh manually");const{Auth0Client:n}=yield Promise.resolve().then(()=>require("./auth0-spa-js.production.esm-BLRAk7Yh.cjs")),a=new n({domain:r.domain,clientId:(t=r.clientId)!=null?t:"",useRefreshTokens:!1,authorizationParams:{audience:"nova-api",redirect_uri:window.location.origin}});if(window.location.search.includes("code=")&&window.location.search.includes("state=")){const{appState:s}=yield a.handleRedirectCallback();window.history.replaceState({},document.title,(s==null?void 0:s.returnTo)||window.location.pathname)}else yield a.loginWithRedirect();return yield a.getTokenSilently()});function zm(e,t){return function(){return e.apply(t,arguments)}}const{toString:i_}=Object.prototype,{getPrototypeOf:hc}=Object,Es=(e=>t=>{const r=i_.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),Pt=e=>(e=e.toLowerCase(),t=>Es(t)===e),Vs=e=>t=>typeof t===e,{isArray:Rn}=Array,ga=Vs("undefined");function l_(e){return e!==null&&!ga(e)&&e.constructor!==null&&!ga(e.constructor)&&ut(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Gm=Pt("ArrayBuffer");function c_(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Gm(e.buffer),t}const u_=Vs("string"),ut=Vs("function"),Hm=Vs("number"),Is=e=>e!==null&&typeof e=="object",d_=e=>e===!0||e===!1,bo=e=>{if(Es(e)!=="object")return!1;const t=hc(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},h_=Pt("Date"),p_=Pt("File"),m_=Pt("Blob"),f_=Pt("FileList"),g_=e=>Is(e)&&ut(e.pipe),y_=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||ut(e.append)&&((t=Es(e))==="formdata"||t==="object"&&ut(e.toString)&&e.toString()==="[object FormData]"))},b_=Pt("URLSearchParams"),[v_,S_,x_,O_]=["ReadableStream","Request","Response","Headers"].map(Pt),w_=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ea(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let n,a;if(typeof e!="object"&&(e=[e]),Rn(e))for(n=0,a=e.length;n<a;n++)t.call(null,e[n],n,e);else{const o=r?Object.getOwnPropertyNames(e):Object.keys(e),s=o.length;let i;for(n=0;n<s;n++)i=o[n],t.call(null,e[i],i,e)}}function qm(e,t){t=t.toLowerCase();const r=Object.keys(e);let n=r.length,a;for(;n-- >0;)if(a=r[n],t===a.toLowerCase())return a;return null}const yr=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Jm=e=>!ga(e)&&e!==yr;function sl(){const{caseless:e}=Jm(this)&&this||{},t={},r=(n,a)=>{const o=e&&qm(t,a)||a;bo(t[o])&&bo(n)?t[o]=sl(t[o],n):bo(n)?t[o]=sl({},n):Rn(n)?t[o]=n.slice():t[o]=n};for(let n=0,a=arguments.length;n<a;n++)arguments[n]&&Ea(arguments[n],r);return t}const C_=(e,t,r,{allOwnKeys:n}={})=>(Ea(t,(a,o)=>{r&&ut(a)?e[o]=zm(a,r):e[o]=a},{allOwnKeys:n}),e),P_=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),T_=(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},R_=(e,t,r,n)=>{let a,o,s;const i={};if(t=t||{},e==null)return t;do{for(a=Object.getOwnPropertyNames(e),o=a.length;o-- >0;)s=a[o],(!n||n(s,e,t))&&!i[s]&&(t[s]=e[s],i[s]=!0);e=r!==!1&&hc(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},A_=(e,t,r)=>{e=String(e),(r===void 0||r>e.length)&&(r=e.length),r-=t.length;const n=e.indexOf(t,r);return n!==-1&&n===r},__=e=>{if(!e)return null;if(Rn(e))return e;let t=e.length;if(!Hm(t))return null;const r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},E_=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&hc(Uint8Array)),V_=(e,t)=>{const n=(e&&e[Symbol.iterator]).call(e);let a;for(;(a=n.next())&&!a.done;){const o=a.value;t.call(e,o[0],o[1])}},I_=(e,t)=>{let r;const n=[];for(;(r=e.exec(t))!==null;)n.push(r);return n},M_=Pt("HTMLFormElement"),$_=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,a){return n.toUpperCase()+a}),jd=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),j_=Pt("RegExp"),Wm=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),n={};Ea(r,(a,o)=>{let s;(s=t(a,o,e))!==!1&&(n[o]=s||a)}),Object.defineProperties(e,n)},k_=e=>{Wm(e,(t,r)=>{if(ut(e)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const n=e[r];if(ut(n)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},U_=(e,t)=>{const r={},n=a=>{a.forEach(o=>{r[o]=!0})};return Rn(e)?n(e):n(String(e).split(t)),r},L_=()=>{},D_=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function N_(e){return!!(e&&ut(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const B_=e=>{const t=new Array(10),r=(n,a)=>{if(Is(n)){if(t.indexOf(n)>=0)return;if(!("toJSON"in n)){t[a]=n;const o=Rn(n)?[]:{};return Ea(n,(s,i)=>{const l=r(s,a+1);!ga(l)&&(o[i]=l)}),t[a]=void 0,o}}return n};return r(e,0)},F_=Pt("AsyncFunction"),z_=e=>e&&(Is(e)||ut(e))&&ut(e.then)&&ut(e.catch),Ym=((e,t)=>e?setImmediate:t?((r,n)=>(yr.addEventListener("message",({source:a,data:o})=>{a===yr&&o===r&&n.length&&n.shift()()},!1),a=>{n.push(a),yr.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",ut(yr.postMessage)),G_=typeof queueMicrotask<"u"?queueMicrotask.bind(yr):typeof process<"u"&&process.nextTick||Ym,G={isArray:Rn,isArrayBuffer:Gm,isBuffer:l_,isFormData:y_,isArrayBufferView:c_,isString:u_,isNumber:Hm,isBoolean:d_,isObject:Is,isPlainObject:bo,isReadableStream:v_,isRequest:S_,isResponse:x_,isHeaders:O_,isUndefined:ga,isDate:h_,isFile:p_,isBlob:m_,isRegExp:j_,isFunction:ut,isStream:g_,isURLSearchParams:b_,isTypedArray:E_,isFileList:f_,forEach:Ea,merge:sl,extend:C_,trim:w_,stripBOM:P_,inherits:T_,toFlatObject:R_,kindOf:Es,kindOfTest:Pt,endsWith:A_,toArray:__,forEachEntry:V_,matchAll:I_,isHTMLForm:M_,hasOwnProperty:jd,hasOwnProp:jd,reduceDescriptors:Wm,freezeMethods:k_,toObjectSet:U_,toCamelCase:$_,noop:L_,toFiniteNumber:D_,findKey:qm,global:yr,isContextDefined:Jm,isSpecCompliantForm:N_,toJSONObject:B_,isAsyncFn:F_,isThenable:z_,setImmediate:Ym,asap:G_};function de(e,t,r,n,a){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),a&&(this.response=a,this.status=a.status?a.status:null)}G.inherits(de,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:G.toJSONObject(this.config),code:this.code,status:this.status}}});const Km=de.prototype,Qm={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{Qm[e]={value:e}});Object.defineProperties(de,Qm);Object.defineProperty(Km,"isAxiosError",{value:!0});de.from=(e,t,r,n,a,o)=>{const s=Object.create(Km);return G.toFlatObject(e,s,function(l){return l!==Error.prototype},i=>i!=="isAxiosError"),de.call(s,e.message,t,r,n,a),s.cause=e,s.name=e.name,o&&Object.assign(s,o),s};const H_=null;function il(e){return G.isPlainObject(e)||G.isArray(e)}function Xm(e){return G.endsWith(e,"[]")?e.slice(0,-2):e}function kd(e,t,r){return e?e.concat(t).map(function(a,o){return a=Xm(a),!r&&o?"["+a+"]":a}).join(r?".":""):t}function q_(e){return G.isArray(e)&&!e.some(il)}const J_=G.toFlatObject(G,{},null,function(t){return/^is[A-Z]/.test(t)});function Ms(e,t,r){if(!G.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,r=G.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(m,b){return!G.isUndefined(b[m])});const n=r.metaTokens,a=r.visitor||u,o=r.dots,s=r.indexes,l=(r.Blob||typeof Blob<"u"&&Blob)&&G.isSpecCompliantForm(t);if(!G.isFunction(a))throw new TypeError("visitor must be a function");function c(f){if(f===null)return"";if(G.isDate(f))return f.toISOString();if(!l&&G.isBlob(f))throw new de("Blob is not supported. Use a Buffer instead.");return G.isArrayBuffer(f)||G.isTypedArray(f)?l&&typeof Blob=="function"?new Blob([f]):Buffer.from(f):f}function u(f,m,b){let x=f;if(f&&!b&&typeof f=="object"){if(G.endsWith(m,"{}"))m=n?m:m.slice(0,-2),f=JSON.stringify(f);else if(G.isArray(f)&&q_(f)||(G.isFileList(f)||G.endsWith(m,"[]"))&&(x=G.toArray(f)))return m=Xm(m),x.forEach(function(O,C){!(G.isUndefined(O)||O===null)&&t.append(s===!0?kd([m],C,o):s===null?m:m+"[]",c(O))}),!1}return il(f)?!0:(t.append(kd(b,m,o),c(f)),!1)}const d=[],h=Object.assign(J_,{defaultVisitor:u,convertValue:c,isVisitable:il});function p(f,m){if(!G.isUndefined(f)){if(d.indexOf(f)!==-1)throw Error("Circular reference detected in "+m.join("."));d.push(f),G.forEach(f,function(x,_){(!(G.isUndefined(x)||x===null)&&a.call(t,x,G.isString(_)?_.trim():_,m,h))===!0&&p(x,m?m.concat(_):[_])}),d.pop()}}if(!G.isObject(e))throw new TypeError("data must be an object");return p(e),t}function Ud(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(n){return t[n]})}function pc(e,t){this._pairs=[],e&&Ms(e,this,t)}const Zm=pc.prototype;Zm.append=function(t,r){this._pairs.push([t,r])};Zm.toString=function(t){const r=t?function(n){return t.call(this,n,Ud)}:Ud;return this._pairs.map(function(a){return r(a[0])+"="+r(a[1])},"").join("&")};function W_(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function ef(e,t,r){if(!t)return e;const n=r&&r.encode||W_;G.isFunction(r)&&(r={serialize:r});const a=r&&r.serialize;let o;if(a?o=a(t,r):o=G.isURLSearchParams(t)?t.toString():new pc(t,r).toString(n),o){const s=e.indexOf("#");s!==-1&&(e=e.slice(0,s)),e+=(e.indexOf("?")===-1?"?":"&")+o}return e}class Ld{constructor(){this.handlers=[]}use(t,r,n){return this.handlers.push({fulfilled:t,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){G.forEach(this.handlers,function(n){n!==null&&t(n)})}}const tf={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Y_=typeof URLSearchParams<"u"?URLSearchParams:pc,K_=typeof FormData<"u"?FormData:null,Q_=typeof Blob<"u"?Blob:null,X_={isBrowser:!0,classes:{URLSearchParams:Y_,FormData:K_,Blob:Q_},protocols:["http","https","file","blob","url","data"]},mc=typeof window<"u"&&typeof document<"u",ll=typeof navigator=="object"&&navigator||void 0,Z_=mc&&(!ll||["ReactNative","NativeScript","NS"].indexOf(ll.product)<0),eE=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",tE=mc&&window.location.href||"http://localhost",rE=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:mc,hasStandardBrowserEnv:Z_,hasStandardBrowserWebWorkerEnv:eE,navigator:ll,origin:tE},Symbol.toStringTag,{value:"Module"})),Qe={...rE,...X_};function nE(e,t){return Ms(e,new Qe.classes.URLSearchParams,Object.assign({visitor:function(r,n,a,o){return Qe.isNode&&G.isBuffer(r)?(this.append(n,r.toString("base64")),!1):o.defaultVisitor.apply(this,arguments)}},t))}function aE(e){return G.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function oE(e){const t={},r=Object.keys(e);let n;const a=r.length;let o;for(n=0;n<a;n++)o=r[n],t[o]=e[o];return t}function rf(e){function t(r,n,a,o){let s=r[o++];if(s==="__proto__")return!0;const i=Number.isFinite(+s),l=o>=r.length;return s=!s&&G.isArray(a)?a.length:s,l?(G.hasOwnProp(a,s)?a[s]=[a[s],n]:a[s]=n,!i):((!a[s]||!G.isObject(a[s]))&&(a[s]=[]),t(r,n,a[s],o)&&G.isArray(a[s])&&(a[s]=oE(a[s])),!i)}if(G.isFormData(e)&&G.isFunction(e.entries)){const r={};return G.forEachEntry(e,(n,a)=>{t(aE(n),a,r,0)}),r}return null}function sE(e,t,r){if(G.isString(e))try{return(t||JSON.parse)(e),G.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(e)}const Va={transitional:tf,adapter:["xhr","http","fetch"],transformRequest:[function(t,r){const n=r.getContentType()||"",a=n.indexOf("application/json")>-1,o=G.isObject(t);if(o&&G.isHTMLForm(t)&&(t=new FormData(t)),G.isFormData(t))return a?JSON.stringify(rf(t)):t;if(G.isArrayBuffer(t)||G.isBuffer(t)||G.isStream(t)||G.isFile(t)||G.isBlob(t)||G.isReadableStream(t))return t;if(G.isArrayBufferView(t))return t.buffer;if(G.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let i;if(o){if(n.indexOf("application/x-www-form-urlencoded")>-1)return nE(t,this.formSerializer).toString();if((i=G.isFileList(t))||n.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return Ms(i?{"files[]":t}:t,l&&new l,this.formSerializer)}}return o||a?(r.setContentType("application/json",!1),sE(t)):t}],transformResponse:[function(t){const r=this.transitional||Va.transitional,n=r&&r.forcedJSONParsing,a=this.responseType==="json";if(G.isResponse(t)||G.isReadableStream(t))return t;if(t&&G.isString(t)&&(n&&!this.responseType||a)){const s=!(r&&r.silentJSONParsing)&&a;try{return JSON.parse(t)}catch(i){if(s)throw i.name==="SyntaxError"?de.from(i,de.ERR_BAD_RESPONSE,this,null,this.response):i}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Qe.classes.FormData,Blob:Qe.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};G.forEach(["delete","get","head","post","put","patch"],e=>{Va.headers[e]={}});const iE=G.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),lE=e=>{const t={};let r,n,a;return e&&e.split(`
|
|
146
|
+
`).forEach(function(s){a=s.indexOf(":"),r=s.substring(0,a).trim().toLowerCase(),n=s.substring(a+1).trim(),!(!r||t[r]&&iE[r])&&(r==="set-cookie"?t[r]?t[r].push(n):t[r]=[n]:t[r]=t[r]?t[r]+", "+n:n)}),t},Dd=Symbol("internals");function Fn(e){return e&&String(e).trim().toLowerCase()}function vo(e){return e===!1||e==null?e:G.isArray(e)?e.map(vo):String(e)}function cE(e){const t=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=r.exec(e);)t[n[1]]=n[2];return t}const uE=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Ti(e,t,r,n,a){if(G.isFunction(n))return n.call(this,t,r);if(a&&(t=r),!!G.isString(t)){if(G.isString(n))return t.indexOf(n)!==-1;if(G.isRegExp(n))return n.test(t)}}function dE(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,r,n)=>r.toUpperCase()+n)}function hE(e,t){const r=G.toCamelCase(" "+t);["get","set","has"].forEach(n=>{Object.defineProperty(e,n+r,{value:function(a,o,s){return this[n].call(this,t,a,o,s)},configurable:!0})})}let st=class{constructor(t){t&&this.set(t)}set(t,r,n){const a=this;function o(i,l,c){const u=Fn(l);if(!u)throw new Error("header name must be a non-empty string");const d=G.findKey(a,u);(!d||a[d]===void 0||c===!0||c===void 0&&a[d]!==!1)&&(a[d||l]=vo(i))}const s=(i,l)=>G.forEach(i,(c,u)=>o(c,u,l));if(G.isPlainObject(t)||t instanceof this.constructor)s(t,r);else if(G.isString(t)&&(t=t.trim())&&!uE(t))s(lE(t),r);else if(G.isHeaders(t))for(const[i,l]of t.entries())o(l,i,n);else t!=null&&o(r,t,n);return this}get(t,r){if(t=Fn(t),t){const n=G.findKey(this,t);if(n){const a=this[n];if(!r)return a;if(r===!0)return cE(a);if(G.isFunction(r))return r.call(this,a,n);if(G.isRegExp(r))return r.exec(a);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,r){if(t=Fn(t),t){const n=G.findKey(this,t);return!!(n&&this[n]!==void 0&&(!r||Ti(this,this[n],n,r)))}return!1}delete(t,r){const n=this;let a=!1;function o(s){if(s=Fn(s),s){const i=G.findKey(n,s);i&&(!r||Ti(n,n[i],i,r))&&(delete n[i],a=!0)}}return G.isArray(t)?t.forEach(o):o(t),a}clear(t){const r=Object.keys(this);let n=r.length,a=!1;for(;n--;){const o=r[n];(!t||Ti(this,this[o],o,t,!0))&&(delete this[o],a=!0)}return a}normalize(t){const r=this,n={};return G.forEach(this,(a,o)=>{const s=G.findKey(n,o);if(s){r[s]=vo(a),delete r[o];return}const i=t?dE(o):String(o).trim();i!==o&&delete r[o],r[i]=vo(a),n[i]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const r=Object.create(null);return G.forEach(this,(n,a)=>{n!=null&&n!==!1&&(r[a]=t&&G.isArray(n)?n.join(", "):n)}),r}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,r])=>t+": "+r).join(`
|
|
147
|
+
`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...r){const n=new this(t);return r.forEach(a=>n.set(a)),n}static accessor(t){const n=(this[Dd]=this[Dd]={accessors:{}}).accessors,a=this.prototype;function o(s){const i=Fn(s);n[i]||(hE(a,s),n[i]=!0)}return G.isArray(t)?t.forEach(o):o(t),this}};st.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);G.reduceDescriptors(st.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(n){this[r]=n}}});G.freezeMethods(st);function Ri(e,t){const r=this||Va,n=t||r,a=st.from(n.headers);let o=n.data;return G.forEach(e,function(i){o=i.call(r,o,a.normalize(),t?t.status:void 0)}),a.normalize(),o}function nf(e){return!!(e&&e.__CANCEL__)}function An(e,t,r){de.call(this,e??"canceled",de.ERR_CANCELED,t,r),this.name="CanceledError"}G.inherits(An,de,{__CANCEL__:!0});function af(e,t,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?e(r):t(new de("Request failed with status code "+r.status,[de.ERR_BAD_REQUEST,de.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}function pE(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function mE(e,t){e=e||10;const r=new Array(e),n=new Array(e);let a=0,o=0,s;return t=t!==void 0?t:1e3,function(l){const c=Date.now(),u=n[o];s||(s=c),r[a]=l,n[a]=c;let d=o,h=0;for(;d!==a;)h+=r[d++],d=d%e;if(a=(a+1)%e,a===o&&(o=(o+1)%e),c-s<t)return;const p=u&&c-u;return p?Math.round(h*1e3/p):void 0}}function fE(e,t){let r=0,n=1e3/t,a,o;const s=(c,u=Date.now())=>{r=u,a=null,o&&(clearTimeout(o),o=null),e.apply(null,c)};return[(...c)=>{const u=Date.now(),d=u-r;d>=n?s(c,u):(a=c,o||(o=setTimeout(()=>{o=null,s(a)},n-d)))},()=>a&&s(a)]}const qo=(e,t,r=3)=>{let n=0;const a=mE(50,250);return fE(o=>{const s=o.loaded,i=o.lengthComputable?o.total:void 0,l=s-n,c=a(l),u=s<=i;n=s;const d={loaded:s,total:i,progress:i?s/i:void 0,bytes:l,rate:c||void 0,estimated:c&&i&&u?(i-s)/c:void 0,event:o,lengthComputable:i!=null,[t?"download":"upload"]:!0};e(d)},r)},Nd=(e,t)=>{const r=e!=null;return[n=>t[0]({lengthComputable:r,total:e,loaded:n}),t[1]]},Bd=e=>(...t)=>G.asap(()=>e(...t)),gE=Qe.hasStandardBrowserEnv?((e,t)=>r=>(r=new URL(r,Qe.origin),e.protocol===r.protocol&&e.host===r.host&&(t||e.port===r.port)))(new URL(Qe.origin),Qe.navigator&&/(msie|trident)/i.test(Qe.navigator.userAgent)):()=>!0,yE=Qe.hasStandardBrowserEnv?{write(e,t,r,n,a,o){const s=[e+"="+encodeURIComponent(t)];G.isNumber(r)&&s.push("expires="+new Date(r).toGMTString()),G.isString(n)&&s.push("path="+n),G.isString(a)&&s.push("domain="+a),o===!0&&s.push("secure"),document.cookie=s.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function bE(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function vE(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function of(e,t,r){let n=!bE(t);return e&&n||r==!1?vE(e,t):t}const Fd=e=>e instanceof st?{...e}:e;function Pr(e,t){t=t||{};const r={};function n(c,u,d,h){return G.isPlainObject(c)&&G.isPlainObject(u)?G.merge.call({caseless:h},c,u):G.isPlainObject(u)?G.merge({},u):G.isArray(u)?u.slice():u}function a(c,u,d,h){if(G.isUndefined(u)){if(!G.isUndefined(c))return n(void 0,c,d,h)}else return n(c,u,d,h)}function o(c,u){if(!G.isUndefined(u))return n(void 0,u)}function s(c,u){if(G.isUndefined(u)){if(!G.isUndefined(c))return n(void 0,c)}else return n(void 0,u)}function i(c,u,d){if(d in t)return n(c,u);if(d in e)return n(void 0,c)}const l={url:o,method:o,data:o,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:i,headers:(c,u,d)=>a(Fd(c),Fd(u),d,!0)};return G.forEach(Object.keys(Object.assign({},e,t)),function(u){const d=l[u]||a,h=d(e[u],t[u],u);G.isUndefined(h)&&d!==i||(r[u]=h)}),r}const sf=e=>{const t=Pr({},e);let{data:r,withXSRFToken:n,xsrfHeaderName:a,xsrfCookieName:o,headers:s,auth:i}=t;t.headers=s=st.from(s),t.url=ef(of(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),i&&s.set("Authorization","Basic "+btoa((i.username||"")+":"+(i.password?unescape(encodeURIComponent(i.password)):"")));let l;if(G.isFormData(r)){if(Qe.hasStandardBrowserEnv||Qe.hasStandardBrowserWebWorkerEnv)s.setContentType(void 0);else if((l=s.getContentType())!==!1){const[c,...u]=l?l.split(";").map(d=>d.trim()).filter(Boolean):[];s.setContentType([c||"multipart/form-data",...u].join("; "))}}if(Qe.hasStandardBrowserEnv&&(n&&G.isFunction(n)&&(n=n(t)),n||n!==!1&&gE(t.url))){const c=a&&o&&yE.read(o);c&&s.set(a,c)}return t},SE=typeof XMLHttpRequest<"u",xE=SE&&function(e){return new Promise(function(r,n){const a=sf(e);let o=a.data;const s=st.from(a.headers).normalize();let{responseType:i,onUploadProgress:l,onDownloadProgress:c}=a,u,d,h,p,f;function m(){p&&p(),f&&f(),a.cancelToken&&a.cancelToken.unsubscribe(u),a.signal&&a.signal.removeEventListener("abort",u)}let b=new XMLHttpRequest;b.open(a.method.toUpperCase(),a.url,!0),b.timeout=a.timeout;function x(){if(!b)return;const O=st.from("getAllResponseHeaders"in b&&b.getAllResponseHeaders()),P={data:!i||i==="text"||i==="json"?b.responseText:b.response,status:b.status,statusText:b.statusText,headers:O,config:e,request:b};af(function(R){r(R),m()},function(R){n(R),m()},P),b=null}"onloadend"in b?b.onloadend=x:b.onreadystatechange=function(){!b||b.readyState!==4||b.status===0&&!(b.responseURL&&b.responseURL.indexOf("file:")===0)||setTimeout(x)},b.onabort=function(){b&&(n(new de("Request aborted",de.ECONNABORTED,e,b)),b=null)},b.onerror=function(){n(new de("Network Error",de.ERR_NETWORK,e,b)),b=null},b.ontimeout=function(){let C=a.timeout?"timeout of "+a.timeout+"ms exceeded":"timeout exceeded";const P=a.transitional||tf;a.timeoutErrorMessage&&(C=a.timeoutErrorMessage),n(new de(C,P.clarifyTimeoutError?de.ETIMEDOUT:de.ECONNABORTED,e,b)),b=null},o===void 0&&s.setContentType(null),"setRequestHeader"in b&&G.forEach(s.toJSON(),function(C,P){b.setRequestHeader(P,C)}),G.isUndefined(a.withCredentials)||(b.withCredentials=!!a.withCredentials),i&&i!=="json"&&(b.responseType=a.responseType),c&&([h,f]=qo(c,!0),b.addEventListener("progress",h)),l&&b.upload&&([d,p]=qo(l),b.upload.addEventListener("progress",d),b.upload.addEventListener("loadend",p)),(a.cancelToken||a.signal)&&(u=O=>{b&&(n(!O||O.type?new An(null,e,b):O),b.abort(),b=null)},a.cancelToken&&a.cancelToken.subscribe(u),a.signal&&(a.signal.aborted?u():a.signal.addEventListener("abort",u)));const _=pE(a.url);if(_&&Qe.protocols.indexOf(_)===-1){n(new de("Unsupported protocol "+_+":",de.ERR_BAD_REQUEST,e));return}b.send(o||null)})},OE=(e,t)=>{const{length:r}=e=e?e.filter(Boolean):[];if(t||r){let n=new AbortController,a;const o=function(c){if(!a){a=!0,i();const u=c instanceof Error?c:this.reason;n.abort(u instanceof de?u:new An(u instanceof Error?u.message:u))}};let s=t&&setTimeout(()=>{s=null,o(new de(`timeout ${t} of ms exceeded`,de.ETIMEDOUT))},t);const i=()=>{e&&(s&&clearTimeout(s),s=null,e.forEach(c=>{c.unsubscribe?c.unsubscribe(o):c.removeEventListener("abort",o)}),e=null)};e.forEach(c=>c.addEventListener("abort",o));const{signal:l}=n;return l.unsubscribe=()=>G.asap(i),l}},wE=function*(e,t){let r=e.byteLength;if(r<t){yield e;return}let n=0,a;for(;n<r;)a=n+t,yield e.slice(n,a),n=a},CE=async function*(e,t){for await(const r of PE(e))yield*wE(r,t)},PE=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:r,value:n}=await t.read();if(r)break;yield n}}finally{await t.cancel()}},zd=(e,t,r,n)=>{const a=CE(e,t);let o=0,s,i=l=>{s||(s=!0,n&&n(l))};return new ReadableStream({async pull(l){try{const{done:c,value:u}=await a.next();if(c){i(),l.close();return}let d=u.byteLength;if(r){let h=o+=d;r(h)}l.enqueue(new Uint8Array(u))}catch(c){throw i(c),c}},cancel(l){return i(l),a.return()}},{highWaterMark:2})},$s=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",lf=$s&&typeof ReadableStream=="function",TE=$s&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),cf=(e,...t)=>{try{return!!e(...t)}catch{return!1}},RE=lf&&cf(()=>{let e=!1;const t=new Request(Qe.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),Gd=64*1024,cl=lf&&cf(()=>G.isReadableStream(new Response("").body)),Jo={stream:cl&&(e=>e.body)};$s&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!Jo[t]&&(Jo[t]=G.isFunction(e[t])?r=>r[t]():(r,n)=>{throw new de(`Response type '${t}' is not supported`,de.ERR_NOT_SUPPORT,n)})})})(new Response);const AE=async e=>{if(e==null)return 0;if(G.isBlob(e))return e.size;if(G.isSpecCompliantForm(e))return(await new Request(Qe.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(G.isArrayBufferView(e)||G.isArrayBuffer(e))return e.byteLength;if(G.isURLSearchParams(e)&&(e=e+""),G.isString(e))return(await TE(e)).byteLength},_E=async(e,t)=>{const r=G.toFiniteNumber(e.getContentLength());return r??AE(t)},EE=$s&&(async e=>{let{url:t,method:r,data:n,signal:a,cancelToken:o,timeout:s,onDownloadProgress:i,onUploadProgress:l,responseType:c,headers:u,withCredentials:d="same-origin",fetchOptions:h}=sf(e);c=c?(c+"").toLowerCase():"text";let p=OE([a,o&&o.toAbortSignal()],s),f;const m=p&&p.unsubscribe&&(()=>{p.unsubscribe()});let b;try{if(l&&RE&&r!=="get"&&r!=="head"&&(b=await _E(u,n))!==0){let P=new Request(t,{method:"POST",body:n,duplex:"half"}),w;if(G.isFormData(n)&&(w=P.headers.get("content-type"))&&u.setContentType(w),P.body){const[R,I]=Nd(b,qo(Bd(l)));n=zd(P.body,Gd,R,I)}}G.isString(d)||(d=d?"include":"omit");const x="credentials"in Request.prototype;f=new Request(t,{...h,signal:p,method:r.toUpperCase(),headers:u.normalize().toJSON(),body:n,duplex:"half",credentials:x?d:void 0});let _=await fetch(f);const O=cl&&(c==="stream"||c==="response");if(cl&&(i||O&&m)){const P={};["status","statusText","headers"].forEach(F=>{P[F]=_[F]});const w=G.toFiniteNumber(_.headers.get("content-length")),[R,I]=i&&Nd(w,qo(Bd(i),!0))||[];_=new Response(zd(_.body,Gd,R,()=>{I&&I(),m&&m()}),P)}c=c||"text";let C=await Jo[G.findKey(Jo,c)||"text"](_,e);return!O&&m&&m(),await new Promise((P,w)=>{af(P,w,{data:C,headers:st.from(_.headers),status:_.status,statusText:_.statusText,config:e,request:f})})}catch(x){throw m&&m(),x&&x.name==="TypeError"&&/fetch/i.test(x.message)?Object.assign(new de("Network Error",de.ERR_NETWORK,e,f),{cause:x.cause||x}):de.from(x,x&&x.code,e,f)}}),ul={http:H_,xhr:xE,fetch:EE};G.forEach(ul,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const Hd=e=>`- ${e}`,VE=e=>G.isFunction(e)||e===null||e===!1,uf={getAdapter:e=>{e=G.isArray(e)?e:[e];const{length:t}=e;let r,n;const a={};for(let o=0;o<t;o++){r=e[o];let s;if(n=r,!VE(r)&&(n=ul[(s=String(r)).toLowerCase()],n===void 0))throw new de(`Unknown adapter '${s}'`);if(n)break;a[s||"#"+o]=n}if(!n){const o=Object.entries(a).map(([i,l])=>`adapter ${i} `+(l===!1?"is not supported by the environment":"is not available in the build"));let s=t?o.length>1?`since :
|
|
148
|
+
`+o.map(Hd).join(`
|
|
149
|
+
`):" "+Hd(o[0]):"as no adapter specified";throw new de("There is no suitable adapter to dispatch the request "+s,"ERR_NOT_SUPPORT")}return n},adapters:ul};function Ai(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new An(null,e)}function qd(e){return Ai(e),e.headers=st.from(e.headers),e.data=Ri.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),uf.getAdapter(e.adapter||Va.adapter)(e).then(function(n){return Ai(e),n.data=Ri.call(e,e.transformResponse,n),n.headers=st.from(n.headers),n},function(n){return nf(n)||(Ai(e),n&&n.response&&(n.response.data=Ri.call(e,e.transformResponse,n.response),n.response.headers=st.from(n.response.headers))),Promise.reject(n)})}const df="1.8.3",js={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{js[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});const Jd={};js.transitional=function(t,r,n){function a(o,s){return"[Axios v"+df+"] Transitional option '"+o+"'"+s+(n?". "+n:"")}return(o,s,i)=>{if(t===!1)throw new de(a(s," has been removed"+(r?" in "+r:"")),de.ERR_DEPRECATED);return r&&!Jd[s]&&(Jd[s]=!0,console.warn(a(s," has been deprecated since v"+r+" and will be removed in the near future"))),t?t(o,s,i):!0}};js.spelling=function(t){return(r,n)=>(console.warn(`${n} is likely a misspelling of ${t}`),!0)};function IE(e,t,r){if(typeof e!="object")throw new de("options must be an object",de.ERR_BAD_OPTION_VALUE);const n=Object.keys(e);let a=n.length;for(;a-- >0;){const o=n[a],s=t[o];if(s){const i=e[o],l=i===void 0||s(i,o,e);if(l!==!0)throw new de("option "+o+" must be "+l,de.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new de("Unknown option "+o,de.ERR_BAD_OPTION)}}const So={assertOptions:IE,validators:js},At=So.validators;let Sr=class{constructor(t){this.defaults=t,this.interceptors={request:new Ld,response:new Ld}}async request(t,r){try{return await this._request(t,r)}catch(n){if(n instanceof Error){let a={};Error.captureStackTrace?Error.captureStackTrace(a):a=new Error;const o=a.stack?a.stack.replace(/^.+\n/,""):"";try{n.stack?o&&!String(n.stack).endsWith(o.replace(/^.+\n.+\n/,""))&&(n.stack+=`
|
|
150
|
+
`+o):n.stack=o}catch{}}throw n}}_request(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=Pr(this.defaults,r);const{transitional:n,paramsSerializer:a,headers:o}=r;n!==void 0&&So.assertOptions(n,{silentJSONParsing:At.transitional(At.boolean),forcedJSONParsing:At.transitional(At.boolean),clarifyTimeoutError:At.transitional(At.boolean)},!1),a!=null&&(G.isFunction(a)?r.paramsSerializer={serialize:a}:So.assertOptions(a,{encode:At.function,serialize:At.function},!0)),r.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?r.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:r.allowAbsoluteUrls=!0),So.assertOptions(r,{baseUrl:At.spelling("baseURL"),withXsrfToken:At.spelling("withXSRFToken")},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let s=o&&G.merge(o.common,o[r.method]);o&&G.forEach(["delete","get","head","post","put","patch","common"],f=>{delete o[f]}),r.headers=st.concat(s,o);const i=[];let l=!0;this.interceptors.request.forEach(function(m){typeof m.runWhen=="function"&&m.runWhen(r)===!1||(l=l&&m.synchronous,i.unshift(m.fulfilled,m.rejected))});const c=[];this.interceptors.response.forEach(function(m){c.push(m.fulfilled,m.rejected)});let u,d=0,h;if(!l){const f=[qd.bind(this),void 0];for(f.unshift.apply(f,i),f.push.apply(f,c),h=f.length,u=Promise.resolve(r);d<h;)u=u.then(f[d++],f[d++]);return u}h=i.length;let p=r;for(d=0;d<h;){const f=i[d++],m=i[d++];try{p=f(p)}catch(b){m.call(this,b);break}}try{u=qd.call(this,p)}catch(f){return Promise.reject(f)}for(d=0,h=c.length;d<h;)u=u.then(c[d++],c[d++]);return u}getUri(t){t=Pr(this.defaults,t);const r=of(t.baseURL,t.url,t.allowAbsoluteUrls);return ef(r,t.params,t.paramsSerializer)}};G.forEach(["delete","get","head","options"],function(t){Sr.prototype[t]=function(r,n){return this.request(Pr(n||{},{method:t,url:r,data:(n||{}).data}))}});G.forEach(["post","put","patch"],function(t){function r(n){return function(o,s,i){return this.request(Pr(i||{},{method:t,headers:n?{"Content-Type":"multipart/form-data"}:{},url:o,data:s}))}}Sr.prototype[t]=r(),Sr.prototype[t+"Form"]=r(!0)});let ME=class hf{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(o){r=o});const n=this;this.promise.then(a=>{if(!n._listeners)return;let o=n._listeners.length;for(;o-- >0;)n._listeners[o](a);n._listeners=null}),this.promise.then=a=>{let o;const s=new Promise(i=>{n.subscribe(i),o=i}).then(a);return s.cancel=function(){n.unsubscribe(o)},s},t(function(o,s,i){n.reason||(n.reason=new An(o,s,i),r(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const r=this._listeners.indexOf(t);r!==-1&&this._listeners.splice(r,1)}toAbortSignal(){const t=new AbortController,r=n=>{t.abort(n)};return this.subscribe(r),t.signal.unsubscribe=()=>this.unsubscribe(r),t.signal}static source(){let t;return{token:new hf(function(a){t=a}),cancel:t}}};function $E(e){return function(r){return e.apply(null,r)}}function jE(e){return G.isObject(e)&&e.isAxiosError===!0}const dl={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(dl).forEach(([e,t])=>{dl[t]=e});function pf(e){const t=new Sr(e),r=zm(Sr.prototype.request,t);return G.extend(r,Sr.prototype,t,{allOwnKeys:!0}),G.extend(r,t,null,{allOwnKeys:!0}),r.create=function(a){return pf(Pr(e,a))},r}const A=pf(Va);A.Axios=Sr;A.CanceledError=An;A.CancelToken=ME;A.isCancel=nf;A.VERSION=df;A.toFormData=Ms;A.AxiosError=de;A.Cancel=A.CanceledError;A.all=function(t){return Promise.all(t)};A.spread=$E;A.isAxiosError=jE;A.mergeConfig=Pr;A.AxiosHeaders=st;A.formToJSON=e=>rf(G.isHTMLForm(e)?new FormData(e):e);A.getAdapter=uf.getAdapter;A.HttpStatusCode=dl;A.default=A;const{Axios:t$,AxiosError:hl,CanceledError:r$,isCancel:n$,CancelToken:a$,VERSION:o$,all:s$,Cancel:i$,isAxiosError:kE,spread:l$,toFormData:c$,AxiosHeaders:u$,HttpStatusCode:d$,formToJSON:h$,getAdapter:p$,mergeConfig:m$}=A,M="/api/v1".replace(/\/+$/,"");class Ve{constructor(t,r=M,n=A){En(this,"basePath");En(this,"axios");En(this,"configuration");this.basePath=r,this.axios=n,t&&(this.configuration=t,this.basePath=t.basePath??r)}}class UE extends Error{constructor(r,n){super(n);En(this,"field");this.field=r,this.name="RequiredError"}}const $={},j="https://example.com",v=function(e,t,r){if(r==null)throw new UE(t,`Required parameter ${t} was null or undefined when calling ${e}.`)},k=function(e,t){t&&(t.username||t.password)&&(e.auth={username:t.username,password:t.password})},U=async function(e,t){if(t&&t.accessToken){const r=typeof t.accessToken=="function"?await t.accessToken():await t.accessToken;e.Authorization="Bearer "+r}};function pl(e,t,r=""){t!=null&&(typeof t=="object"?Array.isArray(t)?t.forEach(n=>pl(e,n,r)):Object.keys(t).forEach(n=>pl(e,t[n],`${r}${r!==""?".":""}${n}`)):e.has(r)?e.append(r,t):e.set(r,t))}const L=function(e,...t){const r=new URLSearchParams(e.search);pl(r,t),e.search=r.toString()},ue=function(e,t,r){const n=typeof e!="string";return(n&&r&&r.isJsonMime?r.isJsonMime(t.headers["Content-Type"]):n)?JSON.stringify(e!==void 0?e:{}):e||""},D=function(e){return e.pathname+e.search+e.hash},N=function(e,t,r,n){return(a=t,o=r)=>{const s={...e.options,url:(a.defaults.baseURL?"":(n==null?void 0:n.basePath)??o)+e.url};return a.request(s)}},LE=function(e){return{addApp:async(t,r,n,a={})=>{v("addApp","cell",t),v("addApp","app",r);const o="/cells/{cell}/apps".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.completionTimeout=n),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(r,l,e),{url:D(s),options:l}},clearApps:async(t,r,n={})=>{v("clearApps","cell",t);const a="/cells/{cell}/apps".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),r!==void 0&&(c.completionTimeout=r),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},deleteApp:async(t,r,n,a={})=>{v("deleteApp","cell",t),v("deleteApp","app",r);const o="/cells/{cell}/apps/{app}".replace("{cell}",encodeURIComponent(String(t))).replace("{app}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"DELETE",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.completionTimeout=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},getApp:async(t,r,n={})=>{v("getApp","cell",t),v("getApp","app",r);const a="/cells/{cell}/apps/{app}".replace("{cell}",encodeURIComponent(String(t))).replace("{app}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listApps:async(t,r={})=>{v("listApps","cell",t);const n="/cells/{cell}/apps".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},updateApp:async(t,r,n,a,o={})=>{v("updateApp","cell",t),v("updateApp","app",r),v("updateApp","app2",n);const s="/cells/{cell}/apps/{app}".replace("{cell}",encodeURIComponent(String(t))).replace("{app}",encodeURIComponent(String(r))),i=new URL(s,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={};k(c,e),await U(u,e),a!==void 0&&(d.completionTimeout=a),u["Content-Type"]="application/json",L(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},c.data=ue(n,c,e),{url:D(i),options:c}}}},qr=function(e){const t=LE(e);return{async addApp(r,n,a,o){var c,u;const s=await t.addApp(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["ApplicationApi.addApp"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async clearApps(r,n,a){var l,c;const o=await t.clearApps(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ApplicationApi.clearApps"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async deleteApp(r,n,a,o){var c,u;const s=await t.deleteApp(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["ApplicationApi.deleteApp"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async getApp(r,n,a){var l,c;const o=await t.getApp(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ApplicationApi.getApp"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listApps(r,n){var i,l;const a=await t.listApps(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["ApplicationApi.listApps"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async updateApp(r,n,a,o,s){var u,d;const i=await t.updateApp(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=$["ApplicationApi.updateApp"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>N(i,A,M,e)(h,c||p)}}};class Wd extends Ve{addApp(t,r,n,a){return qr(this.configuration).addApp(t,r,n,a).then(o=>o(this.axios,this.basePath))}clearApps(t,r,n){return qr(this.configuration).clearApps(t,r,n).then(a=>a(this.axios,this.basePath))}deleteApp(t,r,n,a){return qr(this.configuration).deleteApp(t,r,n,a).then(o=>o(this.axios,this.basePath))}getApp(t,r,n){return qr(this.configuration).getApp(t,r,n).then(a=>a(this.axios,this.basePath))}listApps(t,r){return qr(this.configuration).listApps(t,r).then(n=>n(this.axios,this.basePath))}updateApp(t,r,n,a,o){return qr(this.configuration).updateApp(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}}const DE=function(e){return{deleteCell:async(t,r,n={})=>{v("deleteCell","cell",t);const a="/cells/{cell}".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),r!==void 0&&(c.completionTimeout=r),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},deployCell:async(t,r,n={})=>{v("deployCell","cell",t);const a="/cells",o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};k(i,e),await U(l,e),r!==void 0&&(c.completionTimeout=r),l["Content-Type"]="application/json",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(t,i,e),{url:D(o),options:i}},getCell:async(t,r={})=>{v("getCell","cell",t);const n="/cells/{cell}".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},getCellStatus:async(t,r={})=>{v("getCellStatus","cell",t);const n="/cells/{cell}/status".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},listCells:async(t={})=>{const r="/cells",n=new URL(r,j);let a;e&&(a=e.baseOptions);const o={method:"GET",...a,...t},s={},i={};k(o,e),await U(s,e),L(n,i);let l=a&&a.headers?a.headers:{};return o.headers={...s,...l,...t.headers},{url:D(n),options:o}},updateCell:async(t,r,n,a={})=>{v("updateCell","cell",t),v("updateCell","cell2",r);const o="/cells/{cell}".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.completionTimeout=n),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(r,l,e),{url:D(s),options:l}}}},Jr=function(e){const t=DE(e);return{async deleteCell(r,n,a){var l,c;const o=await t.deleteCell(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["CellApi.deleteCell"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async deployCell(r,n,a){var l,c;const o=await t.deployCell(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["CellApi.deployCell"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getCell(r,n){var i,l;const a=await t.getCell(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["CellApi.getCell"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async getCellStatus(r,n){var i,l;const a=await t.getCellStatus(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["CellApi.getCellStatus"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async listCells(r){var s,i;const n=await t.listCells(r),a=(e==null?void 0:e.serverIndex)??0,o=(i=(s=$["CellApi.listCells"])==null?void 0:s[a])==null?void 0:i.url;return(l,c)=>N(n,A,M,e)(l,o||c)},async updateCell(r,n,a,o){var c,u;const s=await t.updateCell(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["CellApi.updateCell"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)}}};class NE extends Ve{deleteCell(t,r,n){return Jr(this.configuration).deleteCell(t,r,n).then(a=>a(this.axios,this.basePath))}deployCell(t,r,n){return Jr(this.configuration).deployCell(t,r,n).then(a=>a(this.axios,this.basePath))}getCell(t,r){return Jr(this.configuration).getCell(t,r).then(n=>n(this.axios,this.basePath))}getCellStatus(t,r){return Jr(this.configuration).getCellStatus(t,r).then(n=>n(this.axios,this.basePath))}listCells(t){return Jr(this.configuration).listCells(t).then(r=>r(this.axios,this.basePath))}updateCell(t,r,n,a){return Jr(this.configuration).updateCell(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const BE=function(e){return{addRobotController:async(t,r,n,a={})=>{v("addRobotController","cell",t),v("addRobotController","robotController",r);const o="/cells/{cell}/controllers".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.completionTimeout=n),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(r,l,e),{url:D(s),options:l}},clearRobotControllers:async(t,r,n={})=>{v("clearRobotControllers","cell",t);const a="/cells/{cell}/controllers".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),r!==void 0&&(c.completionTimeout=r),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},deleteRobotController:async(t,r,n,a={})=>{v("deleteRobotController","cell",t),v("deleteRobotController","controller",r);const o="/cells/{cell}/controllers/{controller}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"DELETE",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.completionTimeout=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},getCurrentRobotControllerState:async(t,r,n={})=>{v("getCurrentRobotControllerState","cell",t),v("getCurrentRobotControllerState","controller",r);const a="/cells/{cell}/controllers/{controller}/state".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getMode:async(t,r,n={})=>{v("getMode","cell",t),v("getMode","controller",r);const a="/cells/{cell}/controllers/{controller}/mode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getRobotController:async(t,r,n={})=>{v("getRobotController","cell",t),v("getRobotController","controller",r);const a="/cells/{cell}/controllers/{controller}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getSupportedModes:async(t,r,n={})=>{v("getSupportedModes","cell",t),v("getSupportedModes","controller",r);const a="/cells/{cell}/controllers/{controller}/controller-capabilities".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getVirtualRobotConfiguration:async(t,r,n={})=>{v("getVirtualRobotConfiguration","cell",t),v("getVirtualRobotConfiguration","controller",r);const a="/cells/{cell}/controllers/{controller}/virtual-robot-configuration".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listControllers:async(t,r={})=>{v("listControllers","cell",t);const n="/cells/{cell}/controllers".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},setDefaultMode:async(t,r,n,a={})=>{v("setDefaultMode","cell",t),v("setDefaultMode","controller",r),v("setDefaultMode","mode",n);const o="/cells/{cell}/controllers/{controller}/mode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.mode=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},streamFreeDrive:async(t,r,n,a={})=>{v("streamFreeDrive","cell",t),v("streamFreeDrive","controller",r);const o="/cells/{cell}/controllers/{controller}/free-drive-stream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.response_rate=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},streamModeChange:async(t,r,n={})=>{v("streamModeChange","cell",t),v("streamModeChange","controller",r);const a="/cells/{cell}/controllers/{controller}/mode-stream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},streamRobotControllerState:async(t,r,n,a={})=>{v("streamRobotControllerState","cell",t),v("streamRobotControllerState","controller",r);const o="/cells/{cell}/controllers/{controller}/state-stream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.response_rate=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},updateRobotController:async(t,r,n,a,o={})=>{v("updateRobotController","cell",t),v("updateRobotController","controller",r),v("updateRobotController","robotController",n);const s="/cells/{cell}/controllers/{controller}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),i=new URL(s,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={};k(c,e),await U(u,e),a!==void 0&&(d.completionTimeout=a),u["Content-Type"]="application/json",L(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},c.data=ue(n,c,e),{url:D(i),options:c}}}},rt=function(e){const t=BE(e);return{async addRobotController(r,n,a,o){var c,u;const s=await t.addRobotController(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["ControllerApi.addRobotController"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async clearRobotControllers(r,n,a){var l,c;const o=await t.clearRobotControllers(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.clearRobotControllers"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async deleteRobotController(r,n,a,o){var c,u;const s=await t.deleteRobotController(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["ControllerApi.deleteRobotController"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async getCurrentRobotControllerState(r,n,a){var l,c;const o=await t.getCurrentRobotControllerState(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.getCurrentRobotControllerState"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getMode(r,n,a){var l,c;const o=await t.getMode(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.getMode"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getRobotController(r,n,a){var l,c;const o=await t.getRobotController(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.getRobotController"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getSupportedModes(r,n,a){var l,c;const o=await t.getSupportedModes(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.getSupportedModes"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getVirtualRobotConfiguration(r,n,a){var l,c;const o=await t.getVirtualRobotConfiguration(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.getVirtualRobotConfiguration"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listControllers(r,n){var i,l;const a=await t.listControllers(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["ControllerApi.listControllers"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async setDefaultMode(r,n,a,o){var c,u;const s=await t.setDefaultMode(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["ControllerApi.setDefaultMode"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async streamFreeDrive(r,n,a,o){var c,u;const s=await t.streamFreeDrive(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["ControllerApi.streamFreeDrive"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async streamModeChange(r,n,a){var l,c;const o=await t.streamModeChange(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.streamModeChange"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async streamRobotControllerState(r,n,a,o){var c,u;const s=await t.streamRobotControllerState(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["ControllerApi.streamRobotControllerState"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async updateRobotController(r,n,a,o,s){var u,d;const i=await t.updateRobotController(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=$["ControllerApi.updateRobotController"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>N(i,A,M,e)(h,c||p)}}};class FE extends Ve{addRobotController(t,r,n,a){return rt(this.configuration).addRobotController(t,r,n,a).then(o=>o(this.axios,this.basePath))}clearRobotControllers(t,r,n){return rt(this.configuration).clearRobotControllers(t,r,n).then(a=>a(this.axios,this.basePath))}deleteRobotController(t,r,n,a){return rt(this.configuration).deleteRobotController(t,r,n,a).then(o=>o(this.axios,this.basePath))}getCurrentRobotControllerState(t,r,n){return rt(this.configuration).getCurrentRobotControllerState(t,r,n).then(a=>a(this.axios,this.basePath))}getMode(t,r,n){return rt(this.configuration).getMode(t,r,n).then(a=>a(this.axios,this.basePath))}getRobotController(t,r,n){return rt(this.configuration).getRobotController(t,r,n).then(a=>a(this.axios,this.basePath))}getSupportedModes(t,r,n){return rt(this.configuration).getSupportedModes(t,r,n).then(a=>a(this.axios,this.basePath))}getVirtualRobotConfiguration(t,r,n){return rt(this.configuration).getVirtualRobotConfiguration(t,r,n).then(a=>a(this.axios,this.basePath))}listControllers(t,r){return rt(this.configuration).listControllers(t,r).then(n=>n(this.axios,this.basePath))}setDefaultMode(t,r,n,a){return rt(this.configuration).setDefaultMode(t,r,n,a).then(o=>o(this.axios,this.basePath))}streamFreeDrive(t,r,n,a){return rt(this.configuration).streamFreeDrive(t,r,n,a).then(o=>o(this.axios,this.basePath))}streamModeChange(t,r,n){return rt(this.configuration).streamModeChange(t,r,n).then(a=>a(this.axios,this.basePath))}streamRobotControllerState(t,r,n,a){return rt(this.configuration).streamRobotControllerState(t,r,n,a).then(o=>o(this.axios,this.basePath))}updateRobotController(t,r,n,a,o){return rt(this.configuration).updateRobotController(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}}const zE=function(e){return{listIODescriptions:async(t,r,n,a={})=>{v("listIODescriptions","cell",t),v("listIODescriptions","controller",r);const o="/cells/{cell}/controllers/{controller}/ios/description".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),n&&(u.ios=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},listIOValues:async(t,r,n,a={})=>{v("listIOValues","cell",t),v("listIOValues","controller",r);const o="/cells/{cell}/controllers/{controller}/ios/values".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),n&&(u.ios=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},setOutputValues:async(t,r,n,a={})=>{v("setOutputValues","cell",t),v("setOutputValues","controller",r),v("setOutputValues","iOValue",n);const o="/cells/{cell}/controllers/{controller}/ios/values".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}},streamIOValues:async(t,r,n,a={})=>{v("streamIOValues","cell",t),v("streamIOValues","controller",r);const o="/cells/{cell}/controllers/{controller}/ios/stream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),n&&(u.ios=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},waitForIOEvent:async(t,r,n,a,o,s,i,l={})=>{v("waitForIOEvent","cell",t),v("waitForIOEvent","controller",r),v("waitForIOEvent","io",n),v("waitForIOEvent","comparisonType",a);const c="/cells/{cell}/controllers/{controller}/ios/wait-for".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),u=new URL(c,j);let d;e&&(d=e.baseOptions);const h={method:"GET",...d,...l},p={},f={};k(h,e),await U(p,e),n!==void 0&&(f.io=n),a!==void 0&&(f.comparison_type=a),o!==void 0&&(f.boolean_value=o),s!==void 0&&(f.integer_value=s),i!==void 0&&(f.floating_value=i),L(u,f);let m=d&&d.headers?d.headers:{};return h.headers={...p,...m,...l.headers},{url:D(u),options:h}}}},zn=function(e){const t=zE(e);return{async listIODescriptions(r,n,a,o){var c,u;const s=await t.listIODescriptions(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["ControllerIOsApi.listIODescriptions"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async listIOValues(r,n,a,o){var c,u;const s=await t.listIOValues(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["ControllerIOsApi.listIOValues"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async setOutputValues(r,n,a,o){var c,u;const s=await t.setOutputValues(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["ControllerIOsApi.setOutputValues"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async streamIOValues(r,n,a,o){var c,u;const s=await t.streamIOValues(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["ControllerIOsApi.streamIOValues"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async waitForIOEvent(r,n,a,o,s,i,l,c){var p,f;const u=await t.waitForIOEvent(r,n,a,o,s,i,l,c),d=(e==null?void 0:e.serverIndex)??0,h=(f=(p=$["ControllerIOsApi.waitForIOEvent"])==null?void 0:p[d])==null?void 0:f.url;return(m,b)=>N(u,A,M,e)(m,h||b)}}};class GE extends Ve{listIODescriptions(t,r,n,a){return zn(this.configuration).listIODescriptions(t,r,n,a).then(o=>o(this.axios,this.basePath))}listIOValues(t,r,n,a){return zn(this.configuration).listIOValues(t,r,n,a).then(o=>o(this.axios,this.basePath))}setOutputValues(t,r,n,a){return zn(this.configuration).setOutputValues(t,r,n,a).then(o=>o(this.axios,this.basePath))}streamIOValues(t,r,n,a){return zn(this.configuration).streamIOValues(t,r,n,a).then(o=>o(this.axios,this.basePath))}waitForIOEvent(t,r,n,a,o,s,i,l){return zn(this.configuration).waitForIOEvent(t,r,n,a,o,s,i,l).then(c=>c(this.axios,this.basePath))}}const HE=function(e){return{addCoordinateSystem:async(t,r,n={})=>{v("addCoordinateSystem","cell",t),v("addCoordinateSystem","addRequest",r);const a="/cells/{cell}/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="application/json",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},deleteCoordinateSystem:async(t,r,n={})=>{v("deleteCoordinateSystem","cell",t),v("deleteCoordinateSystem","coordinateSystem",r);const a="/cells/{cell}/coordinate-systems/{coordinate-system}".replace("{cell}",encodeURIComponent(String(t))).replace("{coordinate-system}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getCoordinateSystem:async(t,r,n,a={})=>{v("getCoordinateSystem","cell",t),v("getCoordinateSystem","coordinateSystem",r);const o="/cells/{cell}/coordinate-systems/{coordinate-system}".replace("{cell}",encodeURIComponent(String(t))).replace("{coordinate-system}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.rotation_type=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},listCoordinateSystems:async(t,r,n={})=>{v("listCoordinateSystems","cell",t);const a="/cells/{cell}/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),r!==void 0&&(c.rotation_type=r),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},transformInCoordinateSystem:async(t,r,n,a={})=>{v("transformInCoordinateSystem","cell",t),v("transformInCoordinateSystem","coordinateSystem",r),v("transformInCoordinateSystem","pose",n);const o="/cells/{cell}/coordinate-systems/{coordinate-system}/transform".replace("{cell}",encodeURIComponent(String(t))).replace("{coordinate-system}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}}}},Gn=function(e){const t=HE(e);return{async addCoordinateSystem(r,n,a){var l,c;const o=await t.addCoordinateSystem(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["CoordinateSystemsApi.addCoordinateSystem"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async deleteCoordinateSystem(r,n,a){var l,c;const o=await t.deleteCoordinateSystem(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["CoordinateSystemsApi.deleteCoordinateSystem"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getCoordinateSystem(r,n,a,o){var c,u;const s=await t.getCoordinateSystem(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["CoordinateSystemsApi.getCoordinateSystem"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async listCoordinateSystems(r,n,a){var l,c;const o=await t.listCoordinateSystems(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["CoordinateSystemsApi.listCoordinateSystems"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async transformInCoordinateSystem(r,n,a,o){var c,u;const s=await t.transformInCoordinateSystem(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["CoordinateSystemsApi.transformInCoordinateSystem"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)}}};class qE extends Ve{addCoordinateSystem(t,r,n){return Gn(this.configuration).addCoordinateSystem(t,r,n).then(a=>a(this.axios,this.basePath))}deleteCoordinateSystem(t,r,n){return Gn(this.configuration).deleteCoordinateSystem(t,r,n).then(a=>a(this.axios,this.basePath))}getCoordinateSystem(t,r,n,a){return Gn(this.configuration).getCoordinateSystem(t,r,n,a).then(o=>o(this.axios,this.basePath))}listCoordinateSystems(t,r,n){return Gn(this.configuration).listCoordinateSystems(t,r,n).then(a=>a(this.axios,this.basePath))}transformInCoordinateSystem(t,r,n,a){return Gn(this.configuration).transformInCoordinateSystem(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const JE=function(e){return{clearDevices:async(t,r={})=>{v("clearDevices","cell",t);const n="/cells/{cell}/devices".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"DELETE",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},createDevice:async(t,r,n={})=>{v("createDevice","cell",t),v("createDevice","createDeviceRequestInner",r);const a="/cells/{cell}/devices".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="application/json",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},deleteDevice:async(t,r,n={})=>{v("deleteDevice","cell",t),v("deleteDevice","identifier",r);const a="/cells/{cell}/devices/{identifier}".replace("{cell}",encodeURIComponent(String(t))).replace("{identifier}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getDevice:async(t,r,n={})=>{v("getDevice","cell",t),v("getDevice","identifier",r);const a="/cells/{cell}/devices/{identifier}".replace("{cell}",encodeURIComponent(String(t))).replace("{identifier}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listDevices:async(t,r={})=>{v("listDevices","cell",t);const n="/cells/{cell}/devices".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}}}},Hn=function(e){const t=JE(e);return{async clearDevices(r,n){var i,l;const a=await t.clearDevices(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["DeviceConfigurationApi.clearDevices"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async createDevice(r,n,a){var l,c;const o=await t.createDevice(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["DeviceConfigurationApi.createDevice"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async deleteDevice(r,n,a){var l,c;const o=await t.deleteDevice(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["DeviceConfigurationApi.deleteDevice"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getDevice(r,n,a){var l,c;const o=await t.getDevice(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["DeviceConfigurationApi.getDevice"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listDevices(r,n){var i,l;const a=await t.listDevices(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["DeviceConfigurationApi.listDevices"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)}}};class WE extends Ve{clearDevices(t,r){return Hn(this.configuration).clearDevices(t,r).then(n=>n(this.axios,this.basePath))}createDevice(t,r,n){return Hn(this.configuration).createDevice(t,r,n).then(a=>a(this.axios,this.basePath))}deleteDevice(t,r,n){return Hn(this.configuration).deleteDevice(t,r,n).then(a=>a(this.axios,this.basePath))}getDevice(t,r,n){return Hn(this.configuration).getDevice(t,r,n).then(a=>a(this.axios,this.basePath))}listDevices(t,r){return Hn(this.configuration).listDevices(t,r).then(n=>n(this.axios,this.basePath))}}const YE=function(e){return{createProgram:async(t,r,n,a={})=>{v("createProgram","cell",t),v("createProgram","body",r);const o="/cells/{cell}/store/programs".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.name=n),c["Content-Type"]="text/plain",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(r,l,e),{url:D(s),options:l}},deleteProgram:async(t,r,n={})=>{v("deleteProgram","cell",t),v("deleteProgram","program",r);const a="/cells/{cell}/store/programs/{program}".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},deleteProgramList:async(t,r,n={})=>{v("deleteProgramList","cell",t),v("deleteProgramList","programIds",r);const a="/cells/{cell}/store/programs".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),r&&(c.program_ids=r),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getProgram:async(t,r,n={})=>{v("getProgram","cell",t),v("getProgram","program",r);const a="/cells/{cell}/store/programs/{program}".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},updateProgram:async(t,r,n,a={})=>{v("updateProgram","cell",t),v("updateProgram","program",r),v("updateProgram","body",n);const o="/cells/{cell}/store/programs/{program}".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="text/plain",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}}}},qn=function(e){const t=YE(e);return{async createProgram(r,n,a,o){var c,u;const s=await t.createProgram(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["LibraryProgramApi.createProgram"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async deleteProgram(r,n,a){var l,c;const o=await t.deleteProgram(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryProgramApi.deleteProgram"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async deleteProgramList(r,n,a){var l,c;const o=await t.deleteProgramList(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryProgramApi.deleteProgramList"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getProgram(r,n,a){var l,c;const o=await t.getProgram(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryProgramApi.getProgram"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async updateProgram(r,n,a,o){var c,u;const s=await t.updateProgram(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["LibraryProgramApi.updateProgram"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)}}};class KE extends Ve{createProgram(t,r,n,a){return qn(this.configuration).createProgram(t,r,n,a).then(o=>o(this.axios,this.basePath))}deleteProgram(t,r,n){return qn(this.configuration).deleteProgram(t,r,n).then(a=>a(this.axios,this.basePath))}deleteProgramList(t,r,n){return qn(this.configuration).deleteProgramList(t,r,n).then(a=>a(this.axios,this.basePath))}getProgram(t,r,n){return qn(this.configuration).getProgram(t,r,n).then(a=>a(this.axios,this.basePath))}updateProgram(t,r,n,a){return qn(this.configuration).updateProgram(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const QE=function(e){return{getProgramMetadata:async(t,r,n={})=>{v("getProgramMetadata","cell",t),v("getProgramMetadata","program",r);const a="/cells/{cell}/store/programs/{program}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listProgramMetadata:async(t,r,n={})=>{v("listProgramMetadata","cell",t);const a="/cells/{cell}/store/programs".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),r!==void 0&&(c.show_hidden=r),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},updateProgramMetadata:async(t,r,n,a={})=>{v("updateProgramMetadata","cell",t),v("updateProgramMetadata","program",r),v("updateProgramMetadata","updateProgramMetadataRequest",n);const o="/cells/{cell}/store/programs/{program}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}},uploadProgramMetadataImage:async(t,r,n,a={})=>{v("uploadProgramMetadataImage","cell",t),v("uploadProgramMetadataImage","program",r),v("uploadProgramMetadataImage","file",n);const o="/cells/{cell}/store/programs/{program}/metadata/image".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={},d=new(e&&e.formDataCtor||FormData);k(l,e),await U(c,e),n!==void 0&&d.append("file",n),c["Content-Type"]="multipart/form-data",L(s,u);let h=i&&i.headers?i.headers:{};return l.headers={...c,...h,...a.headers},l.data=d,{url:D(s),options:l}}}},Za=function(e){const t=QE(e);return{async getProgramMetadata(r,n,a){var l,c;const o=await t.getProgramMetadata(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryProgramMetadataApi.getProgramMetadata"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listProgramMetadata(r,n,a){var l,c;const o=await t.listProgramMetadata(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryProgramMetadataApi.listProgramMetadata"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async updateProgramMetadata(r,n,a,o){var c,u;const s=await t.updateProgramMetadata(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["LibraryProgramMetadataApi.updateProgramMetadata"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async uploadProgramMetadataImage(r,n,a,o){var c,u;const s=await t.uploadProgramMetadataImage(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["LibraryProgramMetadataApi.uploadProgramMetadataImage"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)}}};class XE extends Ve{getProgramMetadata(t,r,n){return Za(this.configuration).getProgramMetadata(t,r,n).then(a=>a(this.axios,this.basePath))}listProgramMetadata(t,r,n){return Za(this.configuration).listProgramMetadata(t,r,n).then(a=>a(this.axios,this.basePath))}updateProgramMetadata(t,r,n,a){return Za(this.configuration).updateProgramMetadata(t,r,n,a).then(o=>o(this.axios,this.basePath))}uploadProgramMetadataImage(t,r,n,a){return Za(this.configuration).uploadProgramMetadataImage(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const ZE=function(e){return{createRecipe:async(t,r,n,a,o={})=>{v("createRecipe","cell",t),v("createRecipe","programId",r),v("createRecipe","body",n);const s="/cells/{cell}/store/recipes".replace("{cell}",encodeURIComponent(String(t))),i=new URL(s,j);let l;e&&(l=e.baseOptions);const c={method:"POST",...l,...o},u={},d={};k(c,e),await U(u,e),r!==void 0&&(d.program_id=r),a!==void 0&&(d.name=a),u["Content-Type"]="application/json",L(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},c.data=ue(n,c,e),{url:D(i),options:c}},deleteRecipe:async(t,r,n={})=>{v("deleteRecipe","cell",t),v("deleteRecipe","recipe",r);const a="/cells/{cell}/store/recipes/{recipe}".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},deleteRecipeList:async(t,r,n={})=>{v("deleteRecipeList","cell",t),v("deleteRecipeList","recipeIds",r);const a="/cells/{cell}/store/recipes".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),r&&(c.recipe_ids=r),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getRecipe:async(t,r,n={})=>{v("getRecipe","cell",t),v("getRecipe","recipe",r);const a="/cells/{cell}/store/recipes/{recipe}".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},updateRecipe:async(t,r,n,a={})=>{v("updateRecipe","cell",t),v("updateRecipe","recipe",r),v("updateRecipe","body",n);const o="/cells/{cell}/store/recipes/{recipe}".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}}}},Jn=function(e){const t=ZE(e);return{async createRecipe(r,n,a,o,s){var u,d;const i=await t.createRecipe(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=$["LibraryRecipeApi.createRecipe"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>N(i,A,M,e)(h,c||p)},async deleteRecipe(r,n,a){var l,c;const o=await t.deleteRecipe(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryRecipeApi.deleteRecipe"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async deleteRecipeList(r,n,a){var l,c;const o=await t.deleteRecipeList(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryRecipeApi.deleteRecipeList"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getRecipe(r,n,a){var l,c;const o=await t.getRecipe(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryRecipeApi.getRecipe"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async updateRecipe(r,n,a,o){var c,u;const s=await t.updateRecipe(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["LibraryRecipeApi.updateRecipe"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)}}};class eV extends Ve{createRecipe(t,r,n,a,o){return Jn(this.configuration).createRecipe(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}deleteRecipe(t,r,n){return Jn(this.configuration).deleteRecipe(t,r,n).then(a=>a(this.axios,this.basePath))}deleteRecipeList(t,r,n){return Jn(this.configuration).deleteRecipeList(t,r,n).then(a=>a(this.axios,this.basePath))}getRecipe(t,r,n){return Jn(this.configuration).getRecipe(t,r,n).then(a=>a(this.axios,this.basePath))}updateRecipe(t,r,n,a){return Jn(this.configuration).updateRecipe(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const tV=function(e){return{getRecipeMetadata:async(t,r,n={})=>{v("getRecipeMetadata","cell",t),v("getRecipeMetadata","recipe",r);const a="/cells/{cell}/store/recipes/{recipe}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listRecipeMetadata:async(t,r={})=>{v("listRecipeMetadata","cell",t);const n="/cells/{cell}/store/recipes".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},updateRecipeMetadata:async(t,r,n,a={})=>{v("updateRecipeMetadata","cell",t),v("updateRecipeMetadata","recipe",r),v("updateRecipeMetadata","updateRecipeMetadataRequest",n);const o="/cells/{cell}/store/recipes/{recipe}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}},uploadRecipeMetadataImage:async(t,r,n,a={})=>{v("uploadRecipeMetadataImage","cell",t),v("uploadRecipeMetadataImage","recipe",r),v("uploadRecipeMetadataImage","file",n);const o="/cells/{cell}/store/recipes/{recipe}/metadata/image".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={},d=new(e&&e.formDataCtor||FormData);k(l,e),await U(c,e),n!==void 0&&d.append("file",n),c["Content-Type"]="multipart/form-data",L(s,u);let h=i&&i.headers?i.headers:{};return l.headers={...c,...h,...a.headers},l.data=d,{url:D(s),options:l}}}},eo=function(e){const t=tV(e);return{async getRecipeMetadata(r,n,a){var l,c;const o=await t.getRecipeMetadata(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryRecipeMetadataApi.getRecipeMetadata"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listRecipeMetadata(r,n){var i,l;const a=await t.listRecipeMetadata(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["LibraryRecipeMetadataApi.listRecipeMetadata"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async updateRecipeMetadata(r,n,a,o){var c,u;const s=await t.updateRecipeMetadata(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["LibraryRecipeMetadataApi.updateRecipeMetadata"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async uploadRecipeMetadataImage(r,n,a,o){var c,u;const s=await t.uploadRecipeMetadataImage(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["LibraryRecipeMetadataApi.uploadRecipeMetadataImage"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)}}};class rV extends Ve{getRecipeMetadata(t,r,n){return eo(this.configuration).getRecipeMetadata(t,r,n).then(a=>a(this.axios,this.basePath))}listRecipeMetadata(t,r){return eo(this.configuration).listRecipeMetadata(t,r).then(n=>n(this.axios,this.basePath))}updateRecipeMetadata(t,r,n,a){return eo(this.configuration).updateRecipeMetadata(t,r,n,a).then(o=>o(this.axios,this.basePath))}uploadRecipeMetadataImage(t,r,n,a){return eo(this.configuration).uploadRecipeMetadataImage(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const nV=function(e){return{deleteAllMotions:async(t,r={})=>{v("deleteAllMotions","cell",t);const n="/cells/{cell}/motions".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"DELETE",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},deleteMotion:async(t,r,n={})=>{v("deleteMotion","cell",t),v("deleteMotion","motion",r);const a="/cells/{cell}/motions/{motion}/delete".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},executeTrajectory:async(t,r,n={})=>{v("executeTrajectory","cell",t),v("executeTrajectory","executeTrajectoryRequest",r);const a="/cells/{cell}/motions/executetrajectory".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="application/json",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},getMotionTrajectory:async(t,r,n,a,o={})=>{v("getMotionTrajectory","cell",t),v("getMotionTrajectory","motion",r),v("getMotionTrajectory","sampleTime",n);const s="/cells/{cell}/motions/{motion}/trajectory".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),i=new URL(s,j);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},u={},d={};k(c,e),await U(u,e),n!==void 0&&(d.sample_time=n),a!==void 0&&(d.responses_coordinate_system=a),L(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},{url:D(i),options:c}},getMotionTrajectorySample:async(t,r,n,a,o={})=>{v("getMotionTrajectorySample","cell",t),v("getMotionTrajectorySample","motion",r);const s="/cells/{cell}/motions/{motion}/trajectorysample".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),i=new URL(s,j);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},u={},d={};k(c,e),await U(u,e),n!==void 0&&(d.location_on_trajectory=n),a!==void 0&&(d.response_coordinate_system=a),L(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},{url:D(i),options:c}},getPlannedMotion:async(t,r,n,a={})=>{v("getPlannedMotion","cell",t),v("getPlannedMotion","motion",r);const o="/cells/{cell}/motions/{motion}/planned-motion".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.sample_time=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},getPlanningMotionGroupModels:async(t,r={})=>{v("getPlanningMotionGroupModels","cell",t);const n="/cells/{cell}/motion-planning/motion-group-models".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},listMotions:async(t,r={})=>{v("listMotions","cell",t);const n="/cells/{cell}/motions".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},loadPlannedMotion:async(t,r,n={})=>{v("loadPlannedMotion","cell",t),v("loadPlannedMotion","plannedMotion",r);const a="/cells/{cell}/planned-motions".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="application/json",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},planCollisionFreePTP:async(t,r,n={})=>{v("planCollisionFreePTP","cell",t);const a="/cells/{cell}/motion-planning/plan-collision-free-ptp".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="application/json",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},planMotion:async(t,r,n={})=>{v("planMotion","cell",t),v("planMotion","planRequest",r);const a="/cells/{cell}/motions".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="application/json",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},planTrajectory:async(t,r,n={})=>{v("planTrajectory","cell",t);const a="/cells/{cell}/motion-planning/plan-trajectory".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="application/json",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},stopExecution:async(t,r,n={})=>{v("stopExecution","cell",t),v("stopExecution","motion",r);const a="/cells/{cell}/motions/{motion}/stop".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},streamMove:async(t,r,n={})=>{v("streamMove","cell",t),v("streamMove","streamMoveRequest",r);const a="/cells/{cell}/motions/streammove".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="application/json",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},streamMoveBackward:async(t,r,n,a,o,s,i={})=>{v("streamMoveBackward","cell",t),v("streamMoveBackward","motion",r),v("streamMoveBackward","playbackSpeedInPercent",n);const l="/cells/{cell}/motions/{motion}/executebackward".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),c=new URL(l,j);let u;e&&(u=e.baseOptions);const d={method:"GET",...u,...i},h={},p={};k(d,e),await U(h,e),n!==void 0&&(p.playback_speed_in_percent=n),a!==void 0&&(p.response_rate=a),o!==void 0&&(p.response_coordinate_system=o),s!==void 0&&(p.start_location_on_trajectory=s),L(c,p);let f=u&&u.headers?u.headers:{};return d.headers={...h,...f,...i.headers},{url:D(c),options:d}},streamMoveForward:async(t,r,n,a,o,s,i={})=>{v("streamMoveForward","cell",t),v("streamMoveForward","motion",r),v("streamMoveForward","playbackSpeedInPercent",n);const l="/cells/{cell}/motions/{motion}/executeforward".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),c=new URL(l,j);let u;e&&(u=e.baseOptions);const d={method:"GET",...u,...i},h={},p={};k(d,e),await U(h,e),n!==void 0&&(p.playback_speed_in_percent=n),a!==void 0&&(p.response_rate=a),o!==void 0&&(p.response_coordinate_system=o),s!==void 0&&(p.start_location_on_trajectory=s),L(c,p);let f=u&&u.headers?u.headers:{};return d.headers={...h,...f,...i.headers},{url:D(c),options:d}},streamMoveToTrajectoryViaJointPTP:async(t,r,n,a,o,s,i,l,c,u,d={})=>{v("streamMoveToTrajectoryViaJointPTP","cell",t),v("streamMoveToTrajectoryViaJointPTP","motion",r),v("streamMoveToTrajectoryViaJointPTP","locationOnTrajectory",n);const h="/cells/{cell}/motions/{motion}/executetotrajectory".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),p=new URL(h,j);let f;e&&(f=e.baseOptions);const m={method:"GET",...f,...d},b={},x={};k(m,e),await U(b,e),n!==void 0&&(x.location_on_trajectory=n),a&&(x["limit_override.joint_velocity_limits.joints"]=a),o&&(x["limit_override.joint_acceleration_limits.joints"]=o),s!==void 0&&(x["limit_override.tcp_velocity_limit"]=s),i!==void 0&&(x["limit_override.tcp_acceleration_limit"]=i),l!==void 0&&(x["limit_override.tcp_orientation_velocity_limit"]=l),c!==void 0&&(x["limit_override.tcp_orientation_acceleration_limit"]=c),u!==void 0&&(x.responses_coordinate_system=u),L(p,x);let _=f&&f.headers?f.headers:{};return m.headers={...b,..._,...d.headers},{url:D(p),options:m}}}},Ye=function(e){const t=nV(e);return{async deleteAllMotions(r,n){var i,l;const a=await t.deleteAllMotions(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["MotionApi.deleteAllMotions"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async deleteMotion(r,n,a){var l,c;const o=await t.deleteMotion(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.deleteMotion"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async executeTrajectory(r,n,a){var l,c;const o=await t.executeTrajectory(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.executeTrajectory"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getMotionTrajectory(r,n,a,o,s){var u,d;const i=await t.getMotionTrajectory(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=$["MotionApi.getMotionTrajectory"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>N(i,A,M,e)(h,c||p)},async getMotionTrajectorySample(r,n,a,o,s){var u,d;const i=await t.getMotionTrajectorySample(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=$["MotionApi.getMotionTrajectorySample"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>N(i,A,M,e)(h,c||p)},async getPlannedMotion(r,n,a,o){var c,u;const s=await t.getPlannedMotion(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["MotionApi.getPlannedMotion"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async getPlanningMotionGroupModels(r,n){var i,l;const a=await t.getPlanningMotionGroupModels(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["MotionApi.getPlanningMotionGroupModels"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async listMotions(r,n){var i,l;const a=await t.listMotions(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["MotionApi.listMotions"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async loadPlannedMotion(r,n,a){var l,c;const o=await t.loadPlannedMotion(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.loadPlannedMotion"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async planCollisionFreePTP(r,n,a){var l,c;const o=await t.planCollisionFreePTP(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.planCollisionFreePTP"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async planMotion(r,n,a){var l,c;const o=await t.planMotion(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.planMotion"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async planTrajectory(r,n,a){var l,c;const o=await t.planTrajectory(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.planTrajectory"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async stopExecution(r,n,a){var l,c;const o=await t.stopExecution(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.stopExecution"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async streamMove(r,n,a){var l,c;const o=await t.streamMove(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.streamMove"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async streamMoveBackward(r,n,a,o,s,i,l){var h,p;const c=await t.streamMoveBackward(r,n,a,o,s,i,l),u=(e==null?void 0:e.serverIndex)??0,d=(p=(h=$["MotionApi.streamMoveBackward"])==null?void 0:h[u])==null?void 0:p.url;return(f,m)=>N(c,A,M,e)(f,d||m)},async streamMoveForward(r,n,a,o,s,i,l){var h,p;const c=await t.streamMoveForward(r,n,a,o,s,i,l),u=(e==null?void 0:e.serverIndex)??0,d=(p=(h=$["MotionApi.streamMoveForward"])==null?void 0:h[u])==null?void 0:p.url;return(f,m)=>N(c,A,M,e)(f,d||m)},async streamMoveToTrajectoryViaJointPTP(r,n,a,o,s,i,l,c,u,d,h){var b,x;const p=await t.streamMoveToTrajectoryViaJointPTP(r,n,a,o,s,i,l,c,u,d,h),f=(e==null?void 0:e.serverIndex)??0,m=(x=(b=$["MotionApi.streamMoveToTrajectoryViaJointPTP"])==null?void 0:b[f])==null?void 0:x.url;return(_,O)=>N(p,A,M,e)(_,m||O)}}};class aV extends Ve{deleteAllMotions(t,r){return Ye(this.configuration).deleteAllMotions(t,r).then(n=>n(this.axios,this.basePath))}deleteMotion(t,r,n){return Ye(this.configuration).deleteMotion(t,r,n).then(a=>a(this.axios,this.basePath))}executeTrajectory(t,r,n){return Ye(this.configuration).executeTrajectory(t,r,n).then(a=>a(this.axios,this.basePath))}getMotionTrajectory(t,r,n,a,o){return Ye(this.configuration).getMotionTrajectory(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}getMotionTrajectorySample(t,r,n,a,o){return Ye(this.configuration).getMotionTrajectorySample(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}getPlannedMotion(t,r,n,a){return Ye(this.configuration).getPlannedMotion(t,r,n,a).then(o=>o(this.axios,this.basePath))}getPlanningMotionGroupModels(t,r){return Ye(this.configuration).getPlanningMotionGroupModels(t,r).then(n=>n(this.axios,this.basePath))}listMotions(t,r){return Ye(this.configuration).listMotions(t,r).then(n=>n(this.axios,this.basePath))}loadPlannedMotion(t,r,n){return Ye(this.configuration).loadPlannedMotion(t,r,n).then(a=>a(this.axios,this.basePath))}planCollisionFreePTP(t,r,n){return Ye(this.configuration).planCollisionFreePTP(t,r,n).then(a=>a(this.axios,this.basePath))}planMotion(t,r,n){return Ye(this.configuration).planMotion(t,r,n).then(a=>a(this.axios,this.basePath))}planTrajectory(t,r,n){return Ye(this.configuration).planTrajectory(t,r,n).then(a=>a(this.axios,this.basePath))}stopExecution(t,r,n){return Ye(this.configuration).stopExecution(t,r,n).then(a=>a(this.axios,this.basePath))}streamMove(t,r,n){return Ye(this.configuration).streamMove(t,r,n).then(a=>a(this.axios,this.basePath))}streamMoveBackward(t,r,n,a,o,s,i){return Ye(this.configuration).streamMoveBackward(t,r,n,a,o,s,i).then(l=>l(this.axios,this.basePath))}streamMoveForward(t,r,n,a,o,s,i){return Ye(this.configuration).streamMoveForward(t,r,n,a,o,s,i).then(l=>l(this.axios,this.basePath))}streamMoveToTrajectoryViaJointPTP(t,r,n,a,o,s,i,l,c,u,d){return Ye(this.configuration).streamMoveToTrajectoryViaJointPTP(t,r,n,a,o,s,i,l,c,u,d).then(h=>h(this.axios,this.basePath))}}const oV=function(e){return{activateAllMotionGroups:async(t,r,n={})=>{v("activateAllMotionGroups","cell",t),v("activateAllMotionGroups","controller",r);const a="/cells/{cell}/motion-groups/all".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};k(i,e),await U(l,e),r!==void 0&&(c.controller=r),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},activateMotionGroup:async(t,r,n={})=>{v("activateMotionGroup","cell",t),v("activateMotionGroup","motionGroup",r);const a="/cells/{cell}/motion-groups".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};k(i,e),await U(l,e),r!==void 0&&(c.motion_group=r),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},deactivateMotionGroup:async(t,r,n={})=>{v("deactivateMotionGroup","cell",t),v("deactivateMotionGroup","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listMotionGroups:async(t,r={})=>{v("listMotionGroups","cell",t);const n="/cells/{cell}/motion-groups".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}}}},to=function(e){const t=oV(e);return{async activateAllMotionGroups(r,n,a){var l,c;const o=await t.activateAllMotionGroups(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupApi.activateAllMotionGroups"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async activateMotionGroup(r,n,a){var l,c;const o=await t.activateMotionGroup(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupApi.activateMotionGroup"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async deactivateMotionGroup(r,n,a){var l,c;const o=await t.deactivateMotionGroup(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupApi.deactivateMotionGroup"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listMotionGroups(r,n){var i,l;const a=await t.listMotionGroups(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["MotionGroupApi.listMotionGroups"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)}}};class sV extends Ve{activateAllMotionGroups(t,r,n){return to(this.configuration).activateAllMotionGroups(t,r,n).then(a=>a(this.axios,this.basePath))}activateMotionGroup(t,r,n){return to(this.configuration).activateMotionGroup(t,r,n).then(a=>a(this.axios,this.basePath))}deactivateMotionGroup(t,r,n){return to(this.configuration).deactivateMotionGroup(t,r,n).then(a=>a(this.axios,this.basePath))}listMotionGroups(t,r){return to(this.configuration).listMotionGroups(t,r).then(n=>n(this.axios,this.basePath))}}const iV=function(e){return{getActivePayload:async(t,r,n={})=>{v("getActivePayload","cell",t),v("getActivePayload","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/payloads/current".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getActiveTcp:async(t,r,n,a={})=>{v("getActiveTcp","cell",t),v("getActiveTcp","motionGroup",r);const o="/cells/{cell}/motion-groups/{motion-group}/tcps/current".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.rotation_type=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},getCurrentMotionGroupState:async(t,r,n,a,o={})=>{v("getCurrentMotionGroupState","cell",t),v("getCurrentMotionGroupState","motionGroup",r);const s="/cells/{cell}/motion-groups/{motion-group}/state".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),i=new URL(s,j);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},u={},d={};k(c,e),await U(u,e),n!==void 0&&(d.tcp=n),a!==void 0&&(d.response_coordinate_system=a),L(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},{url:D(i),options:c}},getInfoCapabilities:async(t,r,n={})=>{v("getInfoCapabilities","cell",t),v("getInfoCapabilities","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/info-capabilities".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getMotionGroupSpecification:async(t,r,n={})=>{v("getMotionGroupSpecification","cell",t),v("getMotionGroupSpecification","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/specification".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getMounting:async(t,r,n={})=>{v("getMounting","cell",t),v("getMounting","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/mounting".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getOptimizerConfiguration:async(t,r,n,a={})=>{v("getOptimizerConfiguration","cell",t),v("getOptimizerConfiguration","motionGroup",r);const o="/cells/{cell}/motion-groups/{motion-group}/optimizer-setup".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.tcp=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},getSafetySetup:async(t,r,n={})=>{v("getSafetySetup","cell",t),v("getSafetySetup","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/safety-setup".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listPayloads:async(t,r,n={})=>{v("listPayloads","cell",t),v("listPayloads","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/payloads".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listTcps:async(t,r,n,a={})=>{v("listTcps","cell",t),v("listTcps","motionGroup",r);const o="/cells/{cell}/motion-groups/{motion-group}/tcps".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.rotation_type=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},streamMotionGroupState:async(t,r,n,a,o,s={})=>{v("streamMotionGroupState","cell",t),v("streamMotionGroupState","motionGroup",r);const i="/cells/{cell}/motion-groups/{motion-group}/state-stream".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),l=new URL(i,j);let c;e&&(c=e.baseOptions);const u={method:"GET",...c,...s},d={},h={};k(u,e),await U(d,e),n!==void 0&&(h.response_rate=n),a!==void 0&&(h.response_coordinate_system=a),o!==void 0&&(h.tcp=o),L(l,h);let p=c&&c.headers?c.headers:{};return u.headers={...d,...p,...s.headers},{url:D(l),options:u}}}},bt=function(e){const t=iV(e);return{async getActivePayload(r,n,a){var l,c;const o=await t.getActivePayload(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupInfosApi.getActivePayload"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getActiveTcp(r,n,a,o){var c,u;const s=await t.getActiveTcp(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["MotionGroupInfosApi.getActiveTcp"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async getCurrentMotionGroupState(r,n,a,o,s){var u,d;const i=await t.getCurrentMotionGroupState(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=$["MotionGroupInfosApi.getCurrentMotionGroupState"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>N(i,A,M,e)(h,c||p)},async getInfoCapabilities(r,n,a){var l,c;const o=await t.getInfoCapabilities(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupInfosApi.getInfoCapabilities"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getMotionGroupSpecification(r,n,a){var l,c;const o=await t.getMotionGroupSpecification(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupInfosApi.getMotionGroupSpecification"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getMounting(r,n,a){var l,c;const o=await t.getMounting(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupInfosApi.getMounting"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getOptimizerConfiguration(r,n,a,o){var c,u;const s=await t.getOptimizerConfiguration(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["MotionGroupInfosApi.getOptimizerConfiguration"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async getSafetySetup(r,n,a){var l,c;const o=await t.getSafetySetup(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupInfosApi.getSafetySetup"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listPayloads(r,n,a){var l,c;const o=await t.listPayloads(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupInfosApi.listPayloads"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listTcps(r,n,a,o){var c,u;const s=await t.listTcps(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["MotionGroupInfosApi.listTcps"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async streamMotionGroupState(r,n,a,o,s,i){var d,h;const l=await t.streamMotionGroupState(r,n,a,o,s,i),c=(e==null?void 0:e.serverIndex)??0,u=(h=(d=$["MotionGroupInfosApi.streamMotionGroupState"])==null?void 0:d[c])==null?void 0:h.url;return(p,f)=>N(l,A,M,e)(p,u||f)}}};class lV extends Ve{getActivePayload(t,r,n){return bt(this.configuration).getActivePayload(t,r,n).then(a=>a(this.axios,this.basePath))}getActiveTcp(t,r,n,a){return bt(this.configuration).getActiveTcp(t,r,n,a).then(o=>o(this.axios,this.basePath))}getCurrentMotionGroupState(t,r,n,a,o){return bt(this.configuration).getCurrentMotionGroupState(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}getInfoCapabilities(t,r,n){return bt(this.configuration).getInfoCapabilities(t,r,n).then(a=>a(this.axios,this.basePath))}getMotionGroupSpecification(t,r,n){return bt(this.configuration).getMotionGroupSpecification(t,r,n).then(a=>a(this.axios,this.basePath))}getMounting(t,r,n){return bt(this.configuration).getMounting(t,r,n).then(a=>a(this.axios,this.basePath))}getOptimizerConfiguration(t,r,n,a){return bt(this.configuration).getOptimizerConfiguration(t,r,n,a).then(o=>o(this.axios,this.basePath))}getSafetySetup(t,r,n){return bt(this.configuration).getSafetySetup(t,r,n).then(a=>a(this.axios,this.basePath))}listPayloads(t,r,n){return bt(this.configuration).listPayloads(t,r,n).then(a=>a(this.axios,this.basePath))}listTcps(t,r,n,a){return bt(this.configuration).listTcps(t,r,n,a).then(o=>o(this.axios,this.basePath))}streamMotionGroupState(t,r,n,a,o,s){return bt(this.configuration).streamMotionGroupState(t,r,n,a,o,s).then(i=>i(this.axios,this.basePath))}}const cV=function(e){return{directionJogging:async(t,r,n={})=>{v("directionJogging","cell",t),v("directionJogging","directionJoggingRequest",r);const a="/cells/{cell}/motion-groups/move-tcp".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="application/json",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},getJoggingCapabilities:async(t,r,n={})=>{v("getJoggingCapabilities","cell",t),v("getJoggingCapabilities","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/jogging-capabilities".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},jointJogging:async(t,r,n={})=>{v("jointJogging","cell",t),v("jointJogging","jointJoggingRequest",r);const a="/cells/{cell}/motion-groups/move-joint".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="application/json",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},stopJogging:async(t,r,n={})=>{v("stopJogging","cell",t),v("stopJogging","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/stop".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}}}},ro=function(e){const t=cV(e);return{async directionJogging(r,n,a){var l,c;const o=await t.directionJogging(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupJoggingApi.directionJogging"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getJoggingCapabilities(r,n,a){var l,c;const o=await t.getJoggingCapabilities(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupJoggingApi.getJoggingCapabilities"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async jointJogging(r,n,a){var l,c;const o=await t.jointJogging(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupJoggingApi.jointJogging"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async stopJogging(r,n,a){var l,c;const o=await t.stopJogging(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupJoggingApi.stopJogging"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)}}};class uV extends Ve{directionJogging(t,r,n){return ro(this.configuration).directionJogging(t,r,n).then(a=>a(this.axios,this.basePath))}getJoggingCapabilities(t,r,n){return ro(this.configuration).getJoggingCapabilities(t,r,n).then(a=>a(this.axios,this.basePath))}jointJogging(t,r,n){return ro(this.configuration).jointJogging(t,r,n).then(a=>a(this.axios,this.basePath))}stopJogging(t,r,n){return ro(this.configuration).stopJogging(t,r,n).then(a=>a(this.axios,this.basePath))}}const dV=function(e){return{calculateAllInverseKinematic:async(t,r,n,a={})=>{v("calculateAllInverseKinematic","cell",t),v("calculateAllInverseKinematic","motionGroup",r),v("calculateAllInverseKinematic","allJointPositionsRequest",n);const o="/cells/{cell}/motion-groups/{motion-group}/kinematic/calculate-all-joint-positions".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}},calculateForwardKinematic:async(t,r,n,a={})=>{v("calculateForwardKinematic","cell",t),v("calculateForwardKinematic","motionGroup",r),v("calculateForwardKinematic","tcpPoseRequest",n);const o="/cells/{cell}/motion-groups/{motion-group}/kinematic/calculate-tcp-pose".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}},calculateInverseKinematic:async(t,r,n,a={})=>{v("calculateInverseKinematic","cell",t),v("calculateInverseKinematic","motionGroup",r),v("calculateInverseKinematic","jointPositionRequest",n);const o="/cells/{cell}/motion-groups/{motion-group}/kinematic/calculate-joint-position".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}},getKinematicCapabilities:async(t,r,n={})=>{v("getKinematicCapabilities","cell",t),v("getKinematicCapabilities","motionGroup",r);const a="/cells/{cell}/motion-groups/{motion-group}/kinematic-capabilities".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}}}},no=function(e){const t=dV(e);return{async calculateAllInverseKinematic(r,n,a,o){var c,u;const s=await t.calculateAllInverseKinematic(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["MotionGroupKinematicApi.calculateAllInverseKinematic"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async calculateForwardKinematic(r,n,a,o){var c,u;const s=await t.calculateForwardKinematic(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["MotionGroupKinematicApi.calculateForwardKinematic"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async calculateInverseKinematic(r,n,a,o){var c,u;const s=await t.calculateInverseKinematic(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["MotionGroupKinematicApi.calculateInverseKinematic"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async getKinematicCapabilities(r,n,a){var l,c;const o=await t.getKinematicCapabilities(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupKinematicApi.getKinematicCapabilities"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)}}};class hV extends Ve{calculateAllInverseKinematic(t,r,n,a){return no(this.configuration).calculateAllInverseKinematic(t,r,n,a).then(o=>o(this.axios,this.basePath))}calculateForwardKinematic(t,r,n,a){return no(this.configuration).calculateForwardKinematic(t,r,n,a).then(o=>o(this.axios,this.basePath))}calculateInverseKinematic(t,r,n,a){return no(this.configuration).calculateInverseKinematic(t,r,n,a).then(o=>o(this.axios,this.basePath))}getKinematicCapabilities(t,r,n){return no(this.configuration).getKinematicCapabilities(t,r,n).then(a=>a(this.axios,this.basePath))}}const pV=function(e){return{createProgramRunner:async(t,r,n={})=>{v("createProgramRunner","cell",t),v("createProgramRunner","request",r);const a="/cells/{cell}/programs/runners".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="text/plain",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},executeProgram:async(t,r,n={})=>{v("executeProgram","cell",t),v("executeProgram","codeWithArguments",r);const a="/cells/{cell}/programs/execute".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="application/json",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},getProgramRunner:async(t,r,n={})=>{v("getProgramRunner","cell",t),v("getProgramRunner","runner",r);const a="/cells/{cell}/programs/runners/{runner}".replace("{cell}",encodeURIComponent(String(t))).replace("{runner}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listProgramRunners:async(t,r={})=>{v("listProgramRunners","cell",t);const n="/cells/{cell}/programs/runners".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},migrateProgram:async(t,r,n={})=>{v("migrateProgram","cell",t),v("migrateProgram","request1",r);const a="/cells/{cell}/programs/migrate".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="text/plain",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},planProgram:async(t,r,n,a={})=>{v("planProgram","cell",t),v("planProgram","request",r);const o="/cells/{cell}/programs/plan".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.identifier=n),c["Content-Type"]="text/plain",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(r,l,e),{url:D(s),options:l}},stopAllProgramRunner:async(t,r={})=>{v("stopAllProgramRunner","cell",t);const n="/cells/{cell}/programs/runners/stop".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"POST",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},stopProgramRunner:async(t,r,n={})=>{v("stopProgramRunner","cell",t),v("stopProgramRunner","runner",r);const a="/cells/{cell}/programs/runners/{runner}/stop".replace("{cell}",encodeURIComponent(String(t))).replace("{runner}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}}}},Zt=function(e){const t=pV(e);return{async createProgramRunner(r,n,a){var l,c;const o=await t.createProgramRunner(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramApi.createProgramRunner"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async executeProgram(r,n,a){var l,c;const o=await t.executeProgram(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramApi.executeProgram"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getProgramRunner(r,n,a){var l,c;const o=await t.getProgramRunner(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramApi.getProgramRunner"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listProgramRunners(r,n){var i,l;const a=await t.listProgramRunners(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["ProgramApi.listProgramRunners"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async migrateProgram(r,n,a){var l,c;const o=await t.migrateProgram(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramApi.migrateProgram"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async planProgram(r,n,a,o){var c,u;const s=await t.planProgram(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["ProgramApi.planProgram"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async stopAllProgramRunner(r,n){var i,l;const a=await t.stopAllProgramRunner(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["ProgramApi.stopAllProgramRunner"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async stopProgramRunner(r,n,a){var l,c;const o=await t.stopProgramRunner(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramApi.stopProgramRunner"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)}}};class mV extends Ve{createProgramRunner(t,r,n){return Zt(this.configuration).createProgramRunner(t,r,n).then(a=>a(this.axios,this.basePath))}executeProgram(t,r,n){return Zt(this.configuration).executeProgram(t,r,n).then(a=>a(this.axios,this.basePath))}getProgramRunner(t,r,n){return Zt(this.configuration).getProgramRunner(t,r,n).then(a=>a(this.axios,this.basePath))}listProgramRunners(t,r){return Zt(this.configuration).listProgramRunners(t,r).then(n=>n(this.axios,this.basePath))}migrateProgram(t,r,n){return Zt(this.configuration).migrateProgram(t,r,n).then(a=>a(this.axios,this.basePath))}planProgram(t,r,n,a){return Zt(this.configuration).planProgram(t,r,n,a).then(o=>o(this.axios,this.basePath))}stopAllProgramRunner(t,r){return Zt(this.configuration).stopAllProgramRunner(t,r).then(n=>n(this.axios,this.basePath))}stopProgramRunner(t,r,n){return Zt(this.configuration).stopProgramRunner(t,r,n).then(a=>a(this.axios,this.basePath))}}const fV=function(e){return{clearProgramsValues:async(t,r={})=>{v("clearProgramsValues","cell",t);const n="/cells/{cell}/programs/values".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"DELETE",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},createProgramsValue:async(t,r,n={})=>{v("createProgramsValue","cell",t),v("createProgramsValue","requestBody",r);const a="/cells/{cell}/programs/values".replace("{cell}",encodeURIComponent(String(t))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...n},l={},c={};k(i,e),await U(l,e),l["Content-Type"]="application/json",L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},i.data=ue(r,i,e),{url:D(o),options:i}},deleteProgramValue:async(t,r,n={})=>{v("deleteProgramValue","cell",t),v("deleteProgramValue","key",r);const a="/cells/{cell}/programs/values/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getProgramValue:async(t,r,n={})=>{v("getProgramValue","cell",t),v("getProgramValue","key",r);const a="/cells/{cell}/programs/values/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listProgramsValues:async(t,r={})=>{v("listProgramsValues","cell",t);const n="/cells/{cell}/programs/values".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},updateProgramValue:async(t,r,n,a={})=>{v("updateProgramValue","cell",t),v("updateProgramValue","key",r),v("updateProgramValue","value",n);const o="/cells/{cell}/programs/values/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}}}},Wr=function(e){const t=fV(e);return{async clearProgramsValues(r,n){var i,l;const a=await t.clearProgramsValues(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["ProgramValuesApi.clearProgramsValues"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async createProgramsValue(r,n,a){var l,c;const o=await t.createProgramsValue(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramValuesApi.createProgramsValue"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async deleteProgramValue(r,n,a){var l,c;const o=await t.deleteProgramValue(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramValuesApi.deleteProgramValue"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getProgramValue(r,n,a){var l,c;const o=await t.getProgramValue(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramValuesApi.getProgramValue"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listProgramsValues(r,n){var i,l;const a=await t.listProgramsValues(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["ProgramValuesApi.listProgramsValues"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async updateProgramValue(r,n,a,o){var c,u;const s=await t.updateProgramValue(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["ProgramValuesApi.updateProgramValue"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)}}};class gV extends Ve{clearProgramsValues(t,r){return Wr(this.configuration).clearProgramsValues(t,r).then(n=>n(this.axios,this.basePath))}createProgramsValue(t,r,n){return Wr(this.configuration).createProgramsValue(t,r,n).then(a=>a(this.axios,this.basePath))}deleteProgramValue(t,r,n){return Wr(this.configuration).deleteProgramValue(t,r,n).then(a=>a(this.axios,this.basePath))}getProgramValue(t,r,n){return Wr(this.configuration).getProgramValue(t,r,n).then(a=>a(this.axios,this.basePath))}listProgramsValues(t,r){return Wr(this.configuration).listProgramsValues(t,r).then(n=>n(this.axios,this.basePath))}updateProgramValue(t,r,n,a){return Wr(this.configuration).updateProgramValue(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const yV=function(e){return{deleteStoredCollider:async(t,r,n={})=>{v("deleteStoredCollider","cell",t),v("deleteStoredCollider","collider",r);const a="/cells/{cell}/store/collision/colliders/{collider}".replace("{cell}",encodeURIComponent(String(t))).replace("{collider}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},deleteStoredCollisionLinkChain:async(t,r,n={})=>{v("deleteStoredCollisionLinkChain","cell",t),v("deleteStoredCollisionLinkChain","linkChain",r);const a="/cells/{cell}/store/collision/link-chains/{link-chain}".replace("{cell}",encodeURIComponent(String(t))).replace("{link-chain}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},deleteStoredCollisionTool:async(t,r,n={})=>{v("deleteStoredCollisionTool","cell",t),v("deleteStoredCollisionTool","tool",r);const a="/cells/{cell}/store/collision/tools/{tool}".replace("{cell}",encodeURIComponent(String(t))).replace("{tool}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getDefaultLinkChain:async(t,r,n={})=>{v("getDefaultLinkChain","cell",t),v("getDefaultLinkChain","motionGroupModel",r);const a="/cells/{cell}/store/collision/default-link-chains/{motion-group-model}".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group-model}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getStoredCollider:async(t,r,n={})=>{v("getStoredCollider","cell",t),v("getStoredCollider","collider",r);const a="/cells/{cell}/store/collision/colliders/{collider}".replace("{cell}",encodeURIComponent(String(t))).replace("{collider}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getStoredCollisionLinkChain:async(t,r,n={})=>{v("getStoredCollisionLinkChain","cell",t),v("getStoredCollisionLinkChain","linkChain",r);const a="/cells/{cell}/store/collision/link-chains/{link-chain}".replace("{cell}",encodeURIComponent(String(t))).replace("{link-chain}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getStoredCollisionTool:async(t,r,n={})=>{v("getStoredCollisionTool","cell",t),v("getStoredCollisionTool","tool",r);const a="/cells/{cell}/store/collision/tools/{tool}".replace("{cell}",encodeURIComponent(String(t))).replace("{tool}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listCollisionLinkChains:async(t,r={})=>{v("listCollisionLinkChains","cell",t);const n="/cells/{cell}/store/collision/link-chains".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},listStoredColliders:async(t,r={})=>{v("listStoredColliders","cell",t);const n="/cells/{cell}/store/collision/colliders".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},listStoredCollisionTools:async(t,r={})=>{v("listStoredCollisionTools","cell",t);const n="/cells/{cell}/store/collision/tools".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},storeCollider:async(t,r,n,a={})=>{v("storeCollider","cell",t),v("storeCollider","collider",r),v("storeCollider","collider2",n);const o="/cells/{cell}/store/collision/colliders/{collider}".replace("{cell}",encodeURIComponent(String(t))).replace("{collider}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}},storeCollisionLinkChain:async(t,r,n,a={})=>{v("storeCollisionLinkChain","cell",t),v("storeCollisionLinkChain","linkChain",r),v("storeCollisionLinkChain","collider",n);const o="/cells/{cell}/store/collision/link-chains/{link-chain}".replace("{cell}",encodeURIComponent(String(t))).replace("{link-chain}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}},storeCollisionTool:async(t,r,n,a={})=>{v("storeCollisionTool","cell",t),v("storeCollisionTool","tool",r),v("storeCollisionTool","requestBody",n);const o="/cells/{cell}/store/collision/tools/{tool}".replace("{cell}",encodeURIComponent(String(t))).replace("{tool}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}}}},lt=function(e){const t=yV(e);return{async deleteStoredCollider(r,n,a){var l,c;const o=await t.deleteStoredCollider(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.deleteStoredCollider"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async deleteStoredCollisionLinkChain(r,n,a){var l,c;const o=await t.deleteStoredCollisionLinkChain(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.deleteStoredCollisionLinkChain"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async deleteStoredCollisionTool(r,n,a){var l,c;const o=await t.deleteStoredCollisionTool(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.deleteStoredCollisionTool"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getDefaultLinkChain(r,n,a){var l,c;const o=await t.getDefaultLinkChain(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.getDefaultLinkChain"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getStoredCollider(r,n,a){var l,c;const o=await t.getStoredCollider(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.getStoredCollider"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getStoredCollisionLinkChain(r,n,a){var l,c;const o=await t.getStoredCollisionLinkChain(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.getStoredCollisionLinkChain"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getStoredCollisionTool(r,n,a){var l,c;const o=await t.getStoredCollisionTool(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.getStoredCollisionTool"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listCollisionLinkChains(r,n){var i,l;const a=await t.listCollisionLinkChains(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["StoreCollisionComponentsApi.listCollisionLinkChains"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async listStoredColliders(r,n){var i,l;const a=await t.listStoredColliders(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["StoreCollisionComponentsApi.listStoredColliders"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async listStoredCollisionTools(r,n){var i,l;const a=await t.listStoredCollisionTools(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["StoreCollisionComponentsApi.listStoredCollisionTools"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async storeCollider(r,n,a,o){var c,u;const s=await t.storeCollider(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["StoreCollisionComponentsApi.storeCollider"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async storeCollisionLinkChain(r,n,a,o){var c,u;const s=await t.storeCollisionLinkChain(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["StoreCollisionComponentsApi.storeCollisionLinkChain"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async storeCollisionTool(r,n,a,o){var c,u;const s=await t.storeCollisionTool(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["StoreCollisionComponentsApi.storeCollisionTool"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)}}};class bV extends Ve{deleteStoredCollider(t,r,n){return lt(this.configuration).deleteStoredCollider(t,r,n).then(a=>a(this.axios,this.basePath))}deleteStoredCollisionLinkChain(t,r,n){return lt(this.configuration).deleteStoredCollisionLinkChain(t,r,n).then(a=>a(this.axios,this.basePath))}deleteStoredCollisionTool(t,r,n){return lt(this.configuration).deleteStoredCollisionTool(t,r,n).then(a=>a(this.axios,this.basePath))}getDefaultLinkChain(t,r,n){return lt(this.configuration).getDefaultLinkChain(t,r,n).then(a=>a(this.axios,this.basePath))}getStoredCollider(t,r,n){return lt(this.configuration).getStoredCollider(t,r,n).then(a=>a(this.axios,this.basePath))}getStoredCollisionLinkChain(t,r,n){return lt(this.configuration).getStoredCollisionLinkChain(t,r,n).then(a=>a(this.axios,this.basePath))}getStoredCollisionTool(t,r,n){return lt(this.configuration).getStoredCollisionTool(t,r,n).then(a=>a(this.axios,this.basePath))}listCollisionLinkChains(t,r){return lt(this.configuration).listCollisionLinkChains(t,r).then(n=>n(this.axios,this.basePath))}listStoredColliders(t,r){return lt(this.configuration).listStoredColliders(t,r).then(n=>n(this.axios,this.basePath))}listStoredCollisionTools(t,r){return lt(this.configuration).listStoredCollisionTools(t,r).then(n=>n(this.axios,this.basePath))}storeCollider(t,r,n,a){return lt(this.configuration).storeCollider(t,r,n,a).then(o=>o(this.axios,this.basePath))}storeCollisionLinkChain(t,r,n,a){return lt(this.configuration).storeCollisionLinkChain(t,r,n,a).then(o=>o(this.axios,this.basePath))}storeCollisionTool(t,r,n,a){return lt(this.configuration).storeCollisionTool(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const vV=function(e){return{deleteStoredCollisionScene:async(t,r,n={})=>{v("deleteStoredCollisionScene","cell",t),v("deleteStoredCollisionScene","scene",r);const a="/cells/{cell}/store/collision/scenes/{scene}".replace("{cell}",encodeURIComponent(String(t))).replace("{scene}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getStoredCollisionScene:async(t,r,n={})=>{v("getStoredCollisionScene","cell",t),v("getStoredCollisionScene","scene",r);const a="/cells/{cell}/store/collision/scenes/{scene}".replace("{cell}",encodeURIComponent(String(t))).replace("{scene}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listStoredCollisionScenes:async(t,r={})=>{v("listStoredCollisionScenes","cell",t);const n="/cells/{cell}/store/collision/scenes".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},storeCollisionScene:async(t,r,n,a={})=>{v("storeCollisionScene","cell",t),v("storeCollisionScene","scene",r),v("storeCollisionScene","collisionSceneAssembly",n);const o="/cells/{cell}/store/collision/scenes/{scene}".replace("{cell}",encodeURIComponent(String(t))).replace("{scene}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}}}},ao=function(e){const t=vV(e);return{async deleteStoredCollisionScene(r,n,a){var l,c;const o=await t.deleteStoredCollisionScene(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionScenesApi.deleteStoredCollisionScene"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getStoredCollisionScene(r,n,a){var l,c;const o=await t.getStoredCollisionScene(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionScenesApi.getStoredCollisionScene"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listStoredCollisionScenes(r,n){var i,l;const a=await t.listStoredCollisionScenes(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["StoreCollisionScenesApi.listStoredCollisionScenes"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async storeCollisionScene(r,n,a,o){var c,u;const s=await t.storeCollisionScene(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["StoreCollisionScenesApi.storeCollisionScene"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)}}};class SV extends Ve{deleteStoredCollisionScene(t,r,n){return ao(this.configuration).deleteStoredCollisionScene(t,r,n).then(a=>a(this.axios,this.basePath))}getStoredCollisionScene(t,r,n){return ao(this.configuration).getStoredCollisionScene(t,r,n).then(a=>a(this.axios,this.basePath))}listStoredCollisionScenes(t,r){return ao(this.configuration).listStoredCollisionScenes(t,r).then(n=>n(this.axios,this.basePath))}storeCollisionScene(t,r,n,a){return ao(this.configuration).storeCollisionScene(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const xV=function(e){return{clearAllObjects:async(t,r={})=>{v("clearAllObjects","cell",t);const n="/cells/{cell}/store/objects".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"DELETE",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},deleteObject:async(t,r,n={})=>{v("deleteObject","cell",t),v("deleteObject","key",r);const a="/cells/{cell}/store/objects/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getObject:async(t,r,n={})=>{v("getObject","cell",t),v("getObject","key",r);const a="/cells/{cell}/store/objects/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getObjectMetadata:async(t,r,n={})=>{v("getObjectMetadata","cell",t),v("getObjectMetadata","key",r);const a="/cells/{cell}/store/objects/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"HEAD",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listAllObjectKeys:async(t,r={})=>{v("listAllObjectKeys","cell",t);const n="/cells/{cell}/store/objects".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},storeObject:async(t,r,n,a,o={})=>{v("storeObject","cell",t),v("storeObject","key",r);const s="/cells/{cell}/store/objects/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),i=new URL(s,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={},h=new(e&&e.formDataCtor||FormData);k(c,e),await U(u,e),a!==void 0&&h.append("AnyValue",new Blob([JSON.stringify(a)],{type:"application/json"})),u["Content-Type"]="multipart/form-data",n!=null&&(u["X-Metadata"]=typeof n=="string"?n:JSON.stringify(n)),L(i,d);let p=l&&l.headers?l.headers:{};return c.headers={...u,...p,...o.headers},c.data=h,{url:D(i),options:c}}}},Yr=function(e){const t=xV(e);return{async clearAllObjects(r,n){var i,l;const a=await t.clearAllObjects(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["StoreObjectApi.clearAllObjects"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async deleteObject(r,n,a){var l,c;const o=await t.deleteObject(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreObjectApi.deleteObject"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getObject(r,n,a){var l,c;const o=await t.getObject(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreObjectApi.getObject"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getObjectMetadata(r,n,a){var l,c;const o=await t.getObjectMetadata(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreObjectApi.getObjectMetadata"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listAllObjectKeys(r,n){var i,l;const a=await t.listAllObjectKeys(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["StoreObjectApi.listAllObjectKeys"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async storeObject(r,n,a,o,s){var u,d;const i=await t.storeObject(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=$["StoreObjectApi.storeObject"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>N(i,A,M,e)(h,c||p)}}};class OV extends Ve{clearAllObjects(t,r){return Yr(this.configuration).clearAllObjects(t,r).then(n=>n(this.axios,this.basePath))}deleteObject(t,r,n){return Yr(this.configuration).deleteObject(t,r,n).then(a=>a(this.axios,this.basePath))}getObject(t,r,n){return Yr(this.configuration).getObject(t,r,n).then(a=>a(this.axios,this.basePath))}getObjectMetadata(t,r,n){return Yr(this.configuration).getObjectMetadata(t,r,n).then(a=>a(this.axios,this.basePath))}listAllObjectKeys(t,r){return Yr(this.configuration).listAllObjectKeys(t,r).then(n=>n(this.axios,this.basePath))}storeObject(t,r,n,a,o){return Yr(this.configuration).storeObject(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}}const wV=function(e){return{checkNovaVersionUpdate:async(t,r={})=>{v("checkNovaVersionUpdate","channel",t);const n="/system/update",a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};k(s,e),await U(i,e),t!==void 0&&(l.channel=t),L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:D(a),options:s}},getDiagnosePackage:async(t={})=>{const r="/system/diagnosis-package/zip",n=new URL(r,j);let a;e&&(a=e.baseOptions);const o={method:"GET",...a,...t},s={},i={};k(o,e),await U(s,e),L(n,i);let l=a&&a.headers?a.headers:{};return o.headers={...s,...l,...t.headers},{url:D(n),options:o}},getSystemStatus:async(t={})=>{const r="/system/status",n=new URL(r,j);let a;e&&(a=e.baseOptions);const o={method:"GET",...a,...t},s={},i={};k(o,e),await U(s,e),L(n,i);let l=a&&a.headers?a.headers:{};return o.headers={...s,...l,...t.headers},{url:D(n),options:o}},getSystemVersion:async(t={})=>{const r="/system/version",n=new URL(r,j);let a;e&&(a=e.baseOptions);const o={method:"GET",...a,...t},s={},i={};k(o,e),await U(s,e),L(n,i);let l=a&&a.headers?a.headers:{};return o.headers={...s,...l,...t.headers},{url:D(n),options:o}},updateNovaVersion:async(t,r={})=>{v("updateNovaVersion","updateNovaVersionRequest",t);const n="/system/update",a=new URL(n,j);let o;e&&(o=e.baseOptions);const s={method:"PUT",...o,...r},i={},l={};k(s,e),await U(i,e),i["Content-Type"]="application/json",L(a,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},s.data=ue(t,s,e),{url:D(a),options:s}}}},Wn=function(e){const t=wV(e);return{async checkNovaVersionUpdate(r,n){var i,l;const a=await t.checkNovaVersionUpdate(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["SystemApi.checkNovaVersionUpdate"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)},async getDiagnosePackage(r){var s,i;const n=await t.getDiagnosePackage(r),a=(e==null?void 0:e.serverIndex)??0,o=(i=(s=$["SystemApi.getDiagnosePackage"])==null?void 0:s[a])==null?void 0:i.url;return(l,c)=>N(n,A,M,e)(l,o||c)},async getSystemStatus(r){var s,i;const n=await t.getSystemStatus(r),a=(e==null?void 0:e.serverIndex)??0,o=(i=(s=$["SystemApi.getSystemStatus"])==null?void 0:s[a])==null?void 0:i.url;return(l,c)=>N(n,A,M,e)(l,o||c)},async getSystemVersion(r){var s,i;const n=await t.getSystemVersion(r),a=(e==null?void 0:e.serverIndex)??0,o=(i=(s=$["SystemApi.getSystemVersion"])==null?void 0:s[a])==null?void 0:i.url;return(l,c)=>N(n,A,M,e)(l,o||c)},async updateNovaVersion(r,n){var i,l;const a=await t.updateNovaVersion(r,n),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=$["SystemApi.updateNovaVersion"])==null?void 0:i[o])==null?void 0:l.url;return(c,u)=>N(a,A,M,e)(c,s||u)}}};class CV extends Ve{checkNovaVersionUpdate(t,r){return Wn(this.configuration).checkNovaVersionUpdate(t,r).then(n=>n(this.axios,this.basePath))}getDiagnosePackage(t){return Wn(this.configuration).getDiagnosePackage(t).then(r=>r(this.axios,this.basePath))}getSystemStatus(t){return Wn(this.configuration).getSystemStatus(t).then(r=>r(this.axios,this.basePath))}getSystemVersion(t){return Wn(this.configuration).getSystemVersion(t).then(r=>r(this.axios,this.basePath))}updateNovaVersion(t,r){return Wn(this.configuration).updateNovaVersion(t,r).then(n=>n(this.axios,this.basePath))}}const PV=function(e){return{getMotionGroupState:async(t,r,n,a={})=>{v("getMotionGroupState","cell",t),v("getMotionGroupState","controller",r),v("getMotionGroupState","id",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},getMotionGroups:async(t,r,n={})=>{v("getMotionGroups","cell",t),v("getMotionGroups","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/motiongroups".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getVirtualRobotIOValue:async(t,r,n,a={})=>{v("getVirtualRobotIOValue","cell",t),v("getVirtualRobotIOValue","controller",r),v("getVirtualRobotIOValue","io",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/ios/{io}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{io}",encodeURIComponent(String(n))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},listIOs:async(t,r,n={})=>{v("listIOs","cell",t),v("listIOs","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/ios".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},setMotionGroupState:async(t,r,n,a,o={})=>{v("setMotionGroupState","cell",t),v("setMotionGroupState","controller",r),v("setMotionGroupState","id",n),v("setMotionGroupState","motionGroupJoints",a);const s="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),i=new URL(s,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={};k(c,e),await U(u,e),u["Content-Type"]="application/json",L(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},c.data=ue(a,c,e),{url:D(i),options:c}},setVirtualRobotIOValue:async(t,r,n,a,o,s,i={})=>{v("setVirtualRobotIOValue","cell",t),v("setVirtualRobotIOValue","controller",r),v("setVirtualRobotIOValue","io",n);const l="/cells/{cell}/controllers/{controller}/teach-pendant/ios/{io}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{io}",encodeURIComponent(String(n))),c=new URL(l,j);let u;e&&(u=e.baseOptions);const d={method:"PUT",...u,...i},h={},p={};k(d,e),await U(h,e),a!==void 0&&(p.bool=a),o!==void 0&&(p.integer=o),s!==void 0&&(p.double=s),L(c,p);let f=u&&u.headers?u.headers:{};return d.headers={...h,...f,...i.headers},{url:D(c),options:d}}}},Kr=function(e){const t=PV(e);return{async getMotionGroupState(r,n,a,o){var c,u;const s=await t.getMotionGroupState(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["VirtualRobotApi.getMotionGroupState"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async getMotionGroups(r,n,a){var l,c;const o=await t.getMotionGroups(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotApi.getMotionGroups"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getVirtualRobotIOValue(r,n,a,o){var c,u;const s=await t.getVirtualRobotIOValue(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["VirtualRobotApi.getVirtualRobotIOValue"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async listIOs(r,n,a){var l,c;const o=await t.listIOs(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotApi.listIOs"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async setMotionGroupState(r,n,a,o,s){var u,d;const i=await t.setMotionGroupState(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=$["VirtualRobotApi.setMotionGroupState"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>N(i,A,M,e)(h,c||p)},async setVirtualRobotIOValue(r,n,a,o,s,i,l){var h,p;const c=await t.setVirtualRobotIOValue(r,n,a,o,s,i,l),u=(e==null?void 0:e.serverIndex)??0,d=(p=(h=$["VirtualRobotApi.setVirtualRobotIOValue"])==null?void 0:h[u])==null?void 0:p.url;return(f,m)=>N(c,A,M,e)(f,d||m)}}};class TV extends Ve{getMotionGroupState(t,r,n,a){return Kr(this.configuration).getMotionGroupState(t,r,n,a).then(o=>o(this.axios,this.basePath))}getMotionGroups(t,r,n){return Kr(this.configuration).getMotionGroups(t,r,n).then(a=>a(this.axios,this.basePath))}getVirtualRobotIOValue(t,r,n,a){return Kr(this.configuration).getVirtualRobotIOValue(t,r,n,a).then(o=>o(this.axios,this.basePath))}listIOs(t,r,n){return Kr(this.configuration).listIOs(t,r,n).then(a=>a(this.axios,this.basePath))}setMotionGroupState(t,r,n,a,o){return Kr(this.configuration).setMotionGroupState(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}setVirtualRobotIOValue(t,r,n,a,o,s,i){return Kr(this.configuration).setVirtualRobotIOValue(t,r,n,a,o,s,i).then(l=>l(this.axios,this.basePath))}}const RV=function(e){return{externalJointsStream:async(t,r,n,a={})=>{v("externalJointsStream","cell",t),v("externalJointsStream","controller",r),v("externalJointsStream","externalJointStreamDatapoint",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/externalJointsStream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}},getMotionGroupBehavior:async(t,r,n,a={})=>{v("getMotionGroupBehavior","cell",t),v("getMotionGroupBehavior","controller",r),v("getMotionGroupBehavior","id",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/behavior".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},setMotionGroupBehavior:async(t,r,n,a,o={})=>{v("setMotionGroupBehavior","cell",t),v("setMotionGroupBehavior","controller",r),v("setMotionGroupBehavior","id",n);const s="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/behavior".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),i=new URL(s,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={};k(c,e),await U(u,e),a!==void 0&&(d.behavior=a),L(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},{url:D(i),options:c}}}},_i=function(e){const t=RV(e);return{async externalJointsStream(r,n,a,o){var c,u;const s=await t.externalJointsStream(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["VirtualRobotBehaviorApi.externalJointsStream"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async getMotionGroupBehavior(r,n,a,o){var c,u;const s=await t.getMotionGroupBehavior(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["VirtualRobotBehaviorApi.getMotionGroupBehavior"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async setMotionGroupBehavior(r,n,a,o,s){var u,d;const i=await t.setMotionGroupBehavior(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=$["VirtualRobotBehaviorApi.setMotionGroupBehavior"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>N(i,A,M,e)(h,c||p)}}};class AV extends Ve{externalJointsStream(t,r,n,a){return _i(this.configuration).externalJointsStream(t,r,n,a).then(o=>o(this.axios,this.basePath))}getMotionGroupBehavior(t,r,n,a){return _i(this.configuration).getMotionGroupBehavior(t,r,n,a).then(o=>o(this.axios,this.basePath))}setMotionGroupBehavior(t,r,n,a,o){return _i(this.configuration).setMotionGroupBehavior(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}}const _V=function(e){return{getCycleTime:async(t,r,n={})=>{v("getCycleTime","cell",t),v("getCycleTime","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/cycle-time".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getEStop:async(t,r,n={})=>{v("getEStop","cell",t),v("getEStop","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/estop".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},getOperationMode:async(t,r,n={})=>{v("getOperationMode","cell",t),v("getOperationMode","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/operationmode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},pushEStop:async(t,r,n={})=>{v("pushEStop","cell",t),v("pushEStop","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/estop/push".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},releaseEStop:async(t,r,n={})=>{v("releaseEStop","cell",t),v("releaseEStop","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/estop/release".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},setOperationMode:async(t,r,n,a={})=>{v("setOperationMode","cell",t),v("setOperationMode","controller",r),v("setOperationMode","mode",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/operationmode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),n!==void 0&&(u.mode=n),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}}}},Qr=function(e){const t=_V(e);return{async getCycleTime(r,n,a){var l,c;const o=await t.getCycleTime(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotModeApi.getCycleTime"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getEStop(r,n,a){var l,c;const o=await t.getEStop(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotModeApi.getEStop"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async getOperationMode(r,n,a){var l,c;const o=await t.getOperationMode(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotModeApi.getOperationMode"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async pushEStop(r,n,a){var l,c;const o=await t.pushEStop(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotModeApi.pushEStop"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async releaseEStop(r,n,a){var l,c;const o=await t.releaseEStop(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotModeApi.releaseEStop"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async setOperationMode(r,n,a,o){var c,u;const s=await t.setOperationMode(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["VirtualRobotModeApi.setOperationMode"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)}}};class EV extends Ve{getCycleTime(t,r,n){return Qr(this.configuration).getCycleTime(t,r,n).then(a=>a(this.axios,this.basePath))}getEStop(t,r,n){return Qr(this.configuration).getEStop(t,r,n).then(a=>a(this.axios,this.basePath))}getOperationMode(t,r,n){return Qr(this.configuration).getOperationMode(t,r,n).then(a=>a(this.axios,this.basePath))}pushEStop(t,r,n){return Qr(this.configuration).pushEStop(t,r,n).then(a=>a(this.axios,this.basePath))}releaseEStop(t,r,n){return Qr(this.configuration).releaseEStop(t,r,n).then(a=>a(this.axios,this.basePath))}setOperationMode(t,r,n,a){return Qr(this.configuration).setOperationMode(t,r,n,a).then(o=>o(this.axios,this.basePath))}}const VV=function(e){return{addVirtualRobotCoordinateSystem:async(t,r,n,a={})=>{v("addVirtualRobotCoordinateSystem","cell",t),v("addVirtualRobotCoordinateSystem","controller",r),v("addVirtualRobotCoordinateSystem","coordinateSystem",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await U(c,e),c["Content-Type"]="application/json",L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=ue(n,l,e),{url:D(s),options:l}},addVirtualRobotTcp:async(t,r,n,a,o={})=>{v("addVirtualRobotTcp","cell",t),v("addVirtualRobotTcp","controller",r),v("addVirtualRobotTcp","id",n),v("addVirtualRobotTcp","robotTcp",a);const s="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/tcps".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),i=new URL(s,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={};k(c,e),await U(u,e),u["Content-Type"]="application/json",L(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},c.data=ue(a,c,e),{url:D(i),options:c}},deleteVirtualRobotCoordinateSystem:async(t,r,n,a,o={})=>{v("deleteVirtualRobotCoordinateSystem","cell",t),v("deleteVirtualRobotCoordinateSystem","controller",r),v("deleteVirtualRobotCoordinateSystem","coordinateSystem",n);const s="/cells/{cell}/controllers/{controller}/teach-pendant/coordinate-systems/{coordinate-system}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{coordinate-system}",encodeURIComponent(String(n))),i=new URL(s,j);let l;e&&(l=e.baseOptions);const c={method:"DELETE",...l,...o},u={},d={};k(c,e),await U(u,e),a!==void 0&&(d.delete_dependent=a),L(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},{url:D(i),options:c}},deleteVirtualRobotTcp:async(t,r,n,a,o={})=>{v("deleteVirtualRobotTcp","cell",t),v("deleteVirtualRobotTcp","controller",r),v("deleteVirtualRobotTcp","id",n),v("deleteVirtualRobotTcp","tcp",a);const s="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/tcps/{tcp}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))).replace("{tcp}",encodeURIComponent(String(a))),i=new URL(s,j);let l;e&&(l=e.baseOptions);const c={method:"DELETE",...l,...o},u={},d={};k(c,e),await U(u,e),L(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},{url:D(i),options:c}},getVirtualRobotMounting:async(t,r,n,a={})=>{v("getVirtualRobotMounting","cell",t),v("getVirtualRobotMounting","controller",r),v("getVirtualRobotMounting","id",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/mounting".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},listVirtualRobotCoordinateSystems:async(t,r,n={})=>{v("listVirtualRobotCoordinateSystems","cell",t),v("listVirtualRobotCoordinateSystems","controller",r);const a="/cells/{cell}/controllers/{controller}/teach-pendant/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(a,j);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...n},l={},c={};k(i,e),await U(l,e),L(o,c);let u=s&&s.headers?s.headers:{};return i.headers={...l,...u,...n.headers},{url:D(o),options:i}},listVirtualRobotTcps:async(t,r,n,a={})=>{v("listVirtualRobotTcps","cell",t),v("listVirtualRobotTcps","controller",r),v("listVirtualRobotTcps","id",n);const o="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/tcps".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),s=new URL(o,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await U(c,e),L(s,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(s),options:l}},setVirtualRobotMounting:async(t,r,n,a,o={})=>{v("setVirtualRobotMounting","cell",t),v("setVirtualRobotMounting","controller",r),v("setVirtualRobotMounting","id",n),v("setVirtualRobotMounting","coordinateSystem",a);const s="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/{id}/mounting".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{id}",encodeURIComponent(String(n))),i=new URL(s,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},u={},d={};k(c,e),await U(u,e),u["Content-Type"]="application/json",L(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...o.headers},c.data=ue(a,c,e),{url:D(i),options:c}}}},er=function(e){const t=VV(e);return{async addVirtualRobotCoordinateSystem(r,n,a,o){var c,u;const s=await t.addVirtualRobotCoordinateSystem(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["VirtualRobotSetupApi.addVirtualRobotCoordinateSystem"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async addVirtualRobotTcp(r,n,a,o,s){var u,d;const i=await t.addVirtualRobotTcp(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=$["VirtualRobotSetupApi.addVirtualRobotTcp"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>N(i,A,M,e)(h,c||p)},async deleteVirtualRobotCoordinateSystem(r,n,a,o,s){var u,d;const i=await t.deleteVirtualRobotCoordinateSystem(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=$["VirtualRobotSetupApi.deleteVirtualRobotCoordinateSystem"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>N(i,A,M,e)(h,c||p)},async deleteVirtualRobotTcp(r,n,a,o,s){var u,d;const i=await t.deleteVirtualRobotTcp(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=$["VirtualRobotSetupApi.deleteVirtualRobotTcp"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>N(i,A,M,e)(h,c||p)},async getVirtualRobotMounting(r,n,a,o){var c,u;const s=await t.getVirtualRobotMounting(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["VirtualRobotSetupApi.getVirtualRobotMounting"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async listVirtualRobotCoordinateSystems(r,n,a){var l,c;const o=await t.listVirtualRobotCoordinateSystems(r,n,a),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotSetupApi.listVirtualRobotCoordinateSystems"])==null?void 0:l[s])==null?void 0:c.url;return(u,d)=>N(o,A,M,e)(u,i||d)},async listVirtualRobotTcps(r,n,a,o){var c,u;const s=await t.listVirtualRobotTcps(r,n,a,o),i=(e==null?void 0:e.serverIndex)??0,l=(u=(c=$["VirtualRobotSetupApi.listVirtualRobotTcps"])==null?void 0:c[i])==null?void 0:u.url;return(d,h)=>N(s,A,M,e)(d,l||h)},async setVirtualRobotMounting(r,n,a,o,s){var u,d;const i=await t.setVirtualRobotMounting(r,n,a,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(d=(u=$["VirtualRobotSetupApi.setVirtualRobotMounting"])==null?void 0:u[l])==null?void 0:d.url;return(h,p)=>N(i,A,M,e)(h,c||p)}}};class IV extends Ve{addVirtualRobotCoordinateSystem(t,r,n,a){return er(this.configuration).addVirtualRobotCoordinateSystem(t,r,n,a).then(o=>o(this.axios,this.basePath))}addVirtualRobotTcp(t,r,n,a,o){return er(this.configuration).addVirtualRobotTcp(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}deleteVirtualRobotCoordinateSystem(t,r,n,a,o){return er(this.configuration).deleteVirtualRobotCoordinateSystem(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}deleteVirtualRobotTcp(t,r,n,a,o){return er(this.configuration).deleteVirtualRobotTcp(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}getVirtualRobotMounting(t,r,n,a){return er(this.configuration).getVirtualRobotMounting(t,r,n,a).then(o=>o(this.axios,this.basePath))}listVirtualRobotCoordinateSystems(t,r,n){return er(this.configuration).listVirtualRobotCoordinateSystems(t,r,n).then(a=>a(this.axios,this.basePath))}listVirtualRobotTcps(t,r,n,a){return er(this.configuration).listVirtualRobotTcps(t,r,n,a).then(o=>o(this.axios,this.basePath))}setVirtualRobotMounting(t,r,n,a,o){return er(this.configuration).setVirtualRobotMounting(t,r,n,a,o).then(s=>s(this.axios,this.basePath))}}function Lt(e,t,r){return Math.max(t,Math.min(r,e))}class MV{constructor(t=0,r=0,n=0,a=1){this.isQuaternion=!0,this._x=t,this._y=r,this._z=n,this._w=a}static slerpFlat(t,r,n,a,o,s,i){let l=n[a+0],c=n[a+1],u=n[a+2],d=n[a+3];const h=o[s+0],p=o[s+1],f=o[s+2],m=o[s+3];if(i===0){t[r+0]=l,t[r+1]=c,t[r+2]=u,t[r+3]=d;return}if(i===1){t[r+0]=h,t[r+1]=p,t[r+2]=f,t[r+3]=m;return}if(d!==m||l!==h||c!==p||u!==f){let b=1-i;const x=l*h+c*p+u*f+d*m,_=x>=0?1:-1,O=1-x*x;if(O>Number.EPSILON){const P=Math.sqrt(O),w=Math.atan2(P,x*_);b=Math.sin(b*w)/P,i=Math.sin(i*w)/P}const C=i*_;if(l=l*b+h*C,c=c*b+p*C,u=u*b+f*C,d=d*b+m*C,b===1-i){const P=1/Math.sqrt(l*l+c*c+u*u+d*d);l*=P,c*=P,u*=P,d*=P}}t[r]=l,t[r+1]=c,t[r+2]=u,t[r+3]=d}static multiplyQuaternionsFlat(t,r,n,a,o,s){const i=n[a],l=n[a+1],c=n[a+2],u=n[a+3],d=o[s],h=o[s+1],p=o[s+2],f=o[s+3];return t[r]=i*f+u*d+l*p-c*h,t[r+1]=l*f+u*h+c*d-i*p,t[r+2]=c*f+u*p+i*h-l*d,t[r+3]=u*f-i*d-l*h-c*p,t}get x(){return this._x}set x(t){this._x=t,this._onChangeCallback()}get y(){return this._y}set y(t){this._y=t,this._onChangeCallback()}get z(){return this._z}set z(t){this._z=t,this._onChangeCallback()}get w(){return this._w}set w(t){this._w=t,this._onChangeCallback()}set(t,r,n,a){return this._x=t,this._y=r,this._z=n,this._w=a,this._onChangeCallback(),this}clone(){return new this.constructor(this._x,this._y,this._z,this._w)}copy(t){return this._x=t.x,this._y=t.y,this._z=t.z,this._w=t.w,this._onChangeCallback(),this}setFromEuler(t,r=!0){const n=t._x,a=t._y,o=t._z,s=t._order,i=Math.cos,l=Math.sin,c=i(n/2),u=i(a/2),d=i(o/2),h=l(n/2),p=l(a/2),f=l(o/2);switch(s){case"XYZ":this._x=h*u*d+c*p*f,this._y=c*p*d-h*u*f,this._z=c*u*f+h*p*d,this._w=c*u*d-h*p*f;break;case"YXZ":this._x=h*u*d+c*p*f,this._y=c*p*d-h*u*f,this._z=c*u*f-h*p*d,this._w=c*u*d+h*p*f;break;case"ZXY":this._x=h*u*d-c*p*f,this._y=c*p*d+h*u*f,this._z=c*u*f+h*p*d,this._w=c*u*d-h*p*f;break;case"ZYX":this._x=h*u*d-c*p*f,this._y=c*p*d+h*u*f,this._z=c*u*f-h*p*d,this._w=c*u*d+h*p*f;break;case"YZX":this._x=h*u*d+c*p*f,this._y=c*p*d+h*u*f,this._z=c*u*f-h*p*d,this._w=c*u*d-h*p*f;break;case"XZY":this._x=h*u*d-c*p*f,this._y=c*p*d-h*u*f,this._z=c*u*f+h*p*d,this._w=c*u*d+h*p*f;break;default:console.warn("THREE.Quaternion: .setFromEuler() encountered an unknown order: "+s)}return r===!0&&this._onChangeCallback(),this}setFromAxisAngle(t,r){const n=r/2,a=Math.sin(n);return this._x=t.x*a,this._y=t.y*a,this._z=t.z*a,this._w=Math.cos(n),this._onChangeCallback(),this}setFromRotationMatrix(t){const r=t.elements,n=r[0],a=r[4],o=r[8],s=r[1],i=r[5],l=r[9],c=r[2],u=r[6],d=r[10],h=n+i+d;if(h>0){const p=.5/Math.sqrt(h+1);this._w=.25/p,this._x=(u-l)*p,this._y=(o-c)*p,this._z=(s-a)*p}else if(n>i&&n>d){const p=2*Math.sqrt(1+n-i-d);this._w=(u-l)/p,this._x=.25*p,this._y=(a+s)/p,this._z=(o+c)/p}else if(i>d){const p=2*Math.sqrt(1+i-n-d);this._w=(o-c)/p,this._x=(a+s)/p,this._y=.25*p,this._z=(l+u)/p}else{const p=2*Math.sqrt(1+d-n-i);this._w=(s-a)/p,this._x=(o+c)/p,this._y=(l+u)/p,this._z=.25*p}return this._onChangeCallback(),this}setFromUnitVectors(t,r){let n=t.dot(r)+1;return n<Number.EPSILON?(n=0,Math.abs(t.x)>Math.abs(t.z)?(this._x=-t.y,this._y=t.x,this._z=0,this._w=n):(this._x=0,this._y=-t.z,this._z=t.y,this._w=n)):(this._x=t.y*r.z-t.z*r.y,this._y=t.z*r.x-t.x*r.z,this._z=t.x*r.y-t.y*r.x,this._w=n),this.normalize()}angleTo(t){return 2*Math.acos(Math.abs(Lt(this.dot(t),-1,1)))}rotateTowards(t,r){const n=this.angleTo(t);if(n===0)return this;const a=Math.min(1,r/n);return this.slerp(t,a),this}identity(){return this.set(0,0,0,1)}invert(){return this.conjugate()}conjugate(){return this._x*=-1,this._y*=-1,this._z*=-1,this._onChangeCallback(),this}dot(t){return this._x*t._x+this._y*t._y+this._z*t._z+this._w*t._w}lengthSq(){return this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w}length(){return Math.sqrt(this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w)}normalize(){let t=this.length();return t===0?(this._x=0,this._y=0,this._z=0,this._w=1):(t=1/t,this._x=this._x*t,this._y=this._y*t,this._z=this._z*t,this._w=this._w*t),this._onChangeCallback(),this}multiply(t){return this.multiplyQuaternions(this,t)}premultiply(t){return this.multiplyQuaternions(t,this)}multiplyQuaternions(t,r){const n=t._x,a=t._y,o=t._z,s=t._w,i=r._x,l=r._y,c=r._z,u=r._w;return this._x=n*u+s*i+a*c-o*l,this._y=a*u+s*l+o*i-n*c,this._z=o*u+s*c+n*l-a*i,this._w=s*u-n*i-a*l-o*c,this._onChangeCallback(),this}slerp(t,r){if(r===0)return this;if(r===1)return this.copy(t);const n=this._x,a=this._y,o=this._z,s=this._w;let i=s*t._w+n*t._x+a*t._y+o*t._z;if(i<0?(this._w=-t._w,this._x=-t._x,this._y=-t._y,this._z=-t._z,i=-i):this.copy(t),i>=1)return this._w=s,this._x=n,this._y=a,this._z=o,this;const l=1-i*i;if(l<=Number.EPSILON){const p=1-r;return this._w=p*s+r*this._w,this._x=p*n+r*this._x,this._y=p*a+r*this._y,this._z=p*o+r*this._z,this.normalize(),this}const c=Math.sqrt(l),u=Math.atan2(c,i),d=Math.sin((1-r)*u)/c,h=Math.sin(r*u)/c;return this._w=s*d+this._w*h,this._x=n*d+this._x*h,this._y=a*d+this._y*h,this._z=o*d+this._z*h,this._onChangeCallback(),this}slerpQuaternions(t,r,n){return this.copy(t).slerp(r,n)}random(){const t=2*Math.PI*Math.random(),r=2*Math.PI*Math.random(),n=Math.random(),a=Math.sqrt(1-n),o=Math.sqrt(n);return this.set(a*Math.sin(t),a*Math.cos(t),o*Math.sin(r),o*Math.cos(r))}equals(t){return t._x===this._x&&t._y===this._y&&t._z===this._z&&t._w===this._w}fromArray(t,r=0){return this._x=t[r],this._y=t[r+1],this._z=t[r+2],this._w=t[r+3],this._onChangeCallback(),this}toArray(t=[],r=0){return t[r]=this._x,t[r+1]=this._y,t[r+2]=this._z,t[r+3]=this._w,t}fromBufferAttribute(t,r){return this._x=t.getX(r),this._y=t.getY(r),this._z=t.getZ(r),this._w=t.getW(r),this._onChangeCallback(),this}toJSON(){return this.toArray()}_onChange(t){return this._onChangeCallback=t,this}_onChangeCallback(){}*[Symbol.iterator](){yield this._x,yield this._y,yield this._z,yield this._w}}class ln{constructor(t=0,r=0,n=0){ln.prototype.isVector3=!0,this.x=t,this.y=r,this.z=n}set(t,r,n){return n===void 0&&(n=this.z),this.x=t,this.y=r,this.z=n,this}setScalar(t){return this.x=t,this.y=t,this.z=t,this}setX(t){return this.x=t,this}setY(t){return this.y=t,this}setZ(t){return this.z=t,this}setComponent(t,r){switch(t){case 0:this.x=r;break;case 1:this.y=r;break;case 2:this.z=r;break;default:throw new Error("index is out of range: "+t)}return this}getComponent(t){switch(t){case 0:return this.x;case 1:return this.y;case 2:return this.z;default:throw new Error("index is out of range: "+t)}}clone(){return new this.constructor(this.x,this.y,this.z)}copy(t){return this.x=t.x,this.y=t.y,this.z=t.z,this}add(t){return this.x+=t.x,this.y+=t.y,this.z+=t.z,this}addScalar(t){return this.x+=t,this.y+=t,this.z+=t,this}addVectors(t,r){return this.x=t.x+r.x,this.y=t.y+r.y,this.z=t.z+r.z,this}addScaledVector(t,r){return this.x+=t.x*r,this.y+=t.y*r,this.z+=t.z*r,this}sub(t){return this.x-=t.x,this.y-=t.y,this.z-=t.z,this}subScalar(t){return this.x-=t,this.y-=t,this.z-=t,this}subVectors(t,r){return this.x=t.x-r.x,this.y=t.y-r.y,this.z=t.z-r.z,this}multiply(t){return this.x*=t.x,this.y*=t.y,this.z*=t.z,this}multiplyScalar(t){return this.x*=t,this.y*=t,this.z*=t,this}multiplyVectors(t,r){return this.x=t.x*r.x,this.y=t.y*r.y,this.z=t.z*r.z,this}applyEuler(t){return this.applyQuaternion(Yd.setFromEuler(t))}applyAxisAngle(t,r){return this.applyQuaternion(Yd.setFromAxisAngle(t,r))}applyMatrix3(t){const r=this.x,n=this.y,a=this.z,o=t.elements;return this.x=o[0]*r+o[3]*n+o[6]*a,this.y=o[1]*r+o[4]*n+o[7]*a,this.z=o[2]*r+o[5]*n+o[8]*a,this}applyNormalMatrix(t){return this.applyMatrix3(t).normalize()}applyMatrix4(t){const r=this.x,n=this.y,a=this.z,o=t.elements,s=1/(o[3]*r+o[7]*n+o[11]*a+o[15]);return this.x=(o[0]*r+o[4]*n+o[8]*a+o[12])*s,this.y=(o[1]*r+o[5]*n+o[9]*a+o[13])*s,this.z=(o[2]*r+o[6]*n+o[10]*a+o[14])*s,this}applyQuaternion(t){const r=this.x,n=this.y,a=this.z,o=t.x,s=t.y,i=t.z,l=t.w,c=2*(s*a-i*n),u=2*(i*r-o*a),d=2*(o*n-s*r);return this.x=r+l*c+s*d-i*u,this.y=n+l*u+i*c-o*d,this.z=a+l*d+o*u-s*c,this}project(t){return this.applyMatrix4(t.matrixWorldInverse).applyMatrix4(t.projectionMatrix)}unproject(t){return this.applyMatrix4(t.projectionMatrixInverse).applyMatrix4(t.matrixWorld)}transformDirection(t){const r=this.x,n=this.y,a=this.z,o=t.elements;return this.x=o[0]*r+o[4]*n+o[8]*a,this.y=o[1]*r+o[5]*n+o[9]*a,this.z=o[2]*r+o[6]*n+o[10]*a,this.normalize()}divide(t){return this.x/=t.x,this.y/=t.y,this.z/=t.z,this}divideScalar(t){return this.multiplyScalar(1/t)}min(t){return this.x=Math.min(this.x,t.x),this.y=Math.min(this.y,t.y),this.z=Math.min(this.z,t.z),this}max(t){return this.x=Math.max(this.x,t.x),this.y=Math.max(this.y,t.y),this.z=Math.max(this.z,t.z),this}clamp(t,r){return this.x=Lt(this.x,t.x,r.x),this.y=Lt(this.y,t.y,r.y),this.z=Lt(this.z,t.z,r.z),this}clampScalar(t,r){return this.x=Lt(this.x,t,r),this.y=Lt(this.y,t,r),this.z=Lt(this.z,t,r),this}clampLength(t,r){const n=this.length();return this.divideScalar(n||1).multiplyScalar(Lt(n,t,r))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this}roundToZero(){return this.x=Math.trunc(this.x),this.y=Math.trunc(this.y),this.z=Math.trunc(this.z),this}negate(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this}dot(t){return this.x*t.x+this.y*t.y+this.z*t.z}lengthSq(){return this.x*this.x+this.y*this.y+this.z*this.z}length(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)}normalize(){return this.divideScalar(this.length()||1)}setLength(t){return this.normalize().multiplyScalar(t)}lerp(t,r){return this.x+=(t.x-this.x)*r,this.y+=(t.y-this.y)*r,this.z+=(t.z-this.z)*r,this}lerpVectors(t,r,n){return this.x=t.x+(r.x-t.x)*n,this.y=t.y+(r.y-t.y)*n,this.z=t.z+(r.z-t.z)*n,this}cross(t){return this.crossVectors(this,t)}crossVectors(t,r){const n=t.x,a=t.y,o=t.z,s=r.x,i=r.y,l=r.z;return this.x=a*l-o*i,this.y=o*s-n*l,this.z=n*i-a*s,this}projectOnVector(t){const r=t.lengthSq();if(r===0)return this.set(0,0,0);const n=t.dot(this)/r;return this.copy(t).multiplyScalar(n)}projectOnPlane(t){return Ei.copy(this).projectOnVector(t),this.sub(Ei)}reflect(t){return this.sub(Ei.copy(t).multiplyScalar(2*this.dot(t)))}angleTo(t){const r=Math.sqrt(this.lengthSq()*t.lengthSq());if(r===0)return Math.PI/2;const n=this.dot(t)/r;return Math.acos(Lt(n,-1,1))}distanceTo(t){return Math.sqrt(this.distanceToSquared(t))}distanceToSquared(t){const r=this.x-t.x,n=this.y-t.y,a=this.z-t.z;return r*r+n*n+a*a}manhattanDistanceTo(t){return Math.abs(this.x-t.x)+Math.abs(this.y-t.y)+Math.abs(this.z-t.z)}setFromSpherical(t){return this.setFromSphericalCoords(t.radius,t.phi,t.theta)}setFromSphericalCoords(t,r,n){const a=Math.sin(r)*t;return this.x=a*Math.sin(n),this.y=Math.cos(r)*t,this.z=a*Math.cos(n),this}setFromCylindrical(t){return this.setFromCylindricalCoords(t.radius,t.theta,t.y)}setFromCylindricalCoords(t,r,n){return this.x=t*Math.sin(r),this.y=n,this.z=t*Math.cos(r),this}setFromMatrixPosition(t){const r=t.elements;return this.x=r[12],this.y=r[13],this.z=r[14],this}setFromMatrixScale(t){const r=this.setFromMatrixColumn(t,0).length(),n=this.setFromMatrixColumn(t,1).length(),a=this.setFromMatrixColumn(t,2).length();return this.x=r,this.y=n,this.z=a,this}setFromMatrixColumn(t,r){return this.fromArray(t.elements,r*4)}setFromMatrix3Column(t,r){return this.fromArray(t.elements,r*3)}setFromEuler(t){return this.x=t._x,this.y=t._y,this.z=t._z,this}setFromColor(t){return this.x=t.r,this.y=t.g,this.z=t.b,this}equals(t){return t.x===this.x&&t.y===this.y&&t.z===this.z}fromArray(t,r=0){return this.x=t[r],this.y=t[r+1],this.z=t[r+2],this}toArray(t=[],r=0){return t[r]=this.x,t[r+1]=this.y,t[r+2]=this.z,t}fromBufferAttribute(t,r){return this.x=t.getX(r),this.y=t.getY(r),this.z=t.getZ(r),this}random(){return this.x=Math.random(),this.y=Math.random(),this.z=Math.random(),this}randomDirection(){const t=Math.random()*Math.PI*2,r=Math.random()*2-1,n=Math.sqrt(1-r*r);return this.x=n*Math.cos(t),this.y=r,this.z=n*Math.sin(t),this}*[Symbol.iterator](){yield this.x,yield this.y,yield this.z}}const Ei=new ln,Yd=new MV;function $V(e){var t=[];if(e.length===0)return"";if(typeof e[0]!="string")throw new TypeError("Url must be a string. Received "+e[0]);if(e[0].match(/^[^/:]+:\/*$/)&&e.length>1){var r=e.shift();e[0]=r+e[0]}e[0].match(/^file:\/\/\//)?e[0]=e[0].replace(/^([^/:]+):\/*/,"$1:///"):e[0]=e[0].replace(/^([^/:]+):\/*/,"$1://");for(var n=0;n<e.length;n++){var a=e[n];if(typeof a!="string")throw new TypeError("Url must be a string. Received "+a);a!==""&&(n>0&&(a=a.replace(/^[\/]+/,"")),n<e.length-1?a=a.replace(/[\/]+$/,""):a=a.replace(/[\/]+$/,"/"),t.push(a))}var o=t.join("/");o=o.replace(/\/(\?|&|#[^!])/g,"$1");var s=o.split("?");return o=s.shift()+(s.length>0?"?":"")+s.join("&"),o}function Vi(){var e;return typeof arguments[0]=="object"?e=arguments[0]:e=[].slice.call(arguments),$V(e)}var _t={},Kd;function jV(){if(Kd)return _t;Kd=1,Object.defineProperty(_t,"__esModule",{value:!0}),_t.TokenData=void 0,_t.parse=d,_t.compile=h,_t.match=m,_t.pathToRegexp=b,_t.stringify=C;const e="/",t=R=>R,r=/^[$_\p{ID_Start}]$/u,n=/^[$\u200c\u200d\p{ID_Continue}]$/u,a="https://git.new/pathToRegexpError",o={"{":"{","}":"}","(":"(",")":")","[":"[","]":"]","+":"+","?":"?","!":"!"};function s(R){return R.replace(/[{}()\[\]+?!:*]/g,"\\$&")}function i(R){return R.replace(/[.+*?^${}()[\]|/\\]/g,"\\$&")}function*l(R){const I=[...R];let F=0;function y(){let T="";if(r.test(I[++F]))for(T+=I[F];n.test(I[++F]);)T+=I[F];else if(I[F]==='"'){let z=F;for(;F<I.length;){if(I[++F]==='"'){F++,z=0;break}I[F]==="\\"?T+=I[++F]:T+=I[F]}if(z)throw new TypeError(`Unterminated quote at ${z}: ${a}`)}if(!T)throw new TypeError(`Missing parameter name at ${F}: ${a}`);return T}for(;F<I.length;){const T=I[F],z=o[T];if(z)yield{type:z,index:F++,value:T};else if(T==="\\")yield{type:"ESCAPED",index:F++,value:I[F++]};else if(T===":"){const E=y();yield{type:"PARAM",index:F,value:E}}else if(T==="*"){const E=y();yield{type:"WILDCARD",index:F,value:E}}else yield{type:"CHAR",index:F,value:I[F++]}}return{type:"END",index:F,value:""}}class c{constructor(I){this.tokens=I}peek(){if(!this._peek){const I=this.tokens.next();this._peek=I.value}return this._peek}tryConsume(I){const F=this.peek();if(F.type===I)return this._peek=void 0,F.value}consume(I){const F=this.tryConsume(I);if(F!==void 0)return F;const{type:y,index:T}=this.peek();throw new TypeError(`Unexpected ${y} at ${T}, expected ${I}: ${a}`)}text(){let I="",F;for(;F=this.tryConsume("CHAR")||this.tryConsume("ESCAPED");)I+=F;return I}}class u{constructor(I){this.tokens=I}}_t.TokenData=u;function d(R,I={}){const{encodePath:F=t}=I,y=new c(l(R));function T(E){const B=[];for(;;){const te=y.text();te&&B.push({type:"text",value:F(te)});const Z=y.tryConsume("PARAM");if(Z){B.push({type:"param",name:Z});continue}const ae=y.tryConsume("WILDCARD");if(ae){B.push({type:"wildcard",name:ae});continue}if(y.tryConsume("{")){B.push({type:"group",tokens:T("}")});continue}return y.consume(E),B}}const z=T("END");return new u(z)}function h(R,I={}){const{encode:F=encodeURIComponent,delimiter:y=e}=I,T=R instanceof u?R:d(R,I),z=p(T.tokens,y,F);return function(B={}){const[te,...Z]=z(B);if(Z.length)throw new TypeError(`Missing parameters: ${Z.join(", ")}`);return te}}function p(R,I,F){const y=R.map(T=>f(T,I,F));return T=>{const z=[""];for(const E of y){const[B,...te]=E(T);z[0]+=B,z.push(...te)}return z}}function f(R,I,F){if(R.type==="text")return()=>[R.value];if(R.type==="group"){const T=p(R.tokens,I,F);return z=>{const[E,...B]=T(z);return B.length?[""]:[E]}}const y=F||t;return R.type==="wildcard"&&F!==!1?T=>{const z=T[R.name];if(z==null)return["",R.name];if(!Array.isArray(z)||z.length===0)throw new TypeError(`Expected "${R.name}" to be a non-empty array`);return[z.map((E,B)=>{if(typeof E!="string")throw new TypeError(`Expected "${R.name}/${B}" to be a string`);return y(E)}).join(I)]}:T=>{const z=T[R.name];if(z==null)return["",R.name];if(typeof z!="string")throw new TypeError(`Expected "${R.name}" to be a string`);return[y(z)]}}function m(R,I={}){const{decode:F=decodeURIComponent,delimiter:y=e}=I,{regexp:T,keys:z}=b(R,I),E=z.map(B=>F===!1?t:B.type==="param"?F:te=>te.split(y).map(F));return function(te){const Z=T.exec(te);if(!Z)return!1;const ae=Z[0],re=Object.create(null);for(let le=1;le<Z.length;le++){if(Z[le]===void 0)continue;const J=z[le-1],X=E[le-1];re[J.name]=X(Z[le])}return{path:ae,params:re}}}function b(R,I={}){const{delimiter:F=e,end:y=!0,sensitive:T=!1,trailing:z=!0}=I,E=[],B=[],te=T?"":"i",ae=(Array.isArray(R)?R:[R]).map(J=>J instanceof u?J:d(J,I));for(const{tokens:J}of ae)for(const X of x(J,0,[])){const he=_(X,F,E);B.push(he)}let re=`^(?:${B.join("|")})`;return z&&(re+=`(?:${i(F)}$)?`),re+=y?"$":`(?=${i(F)}|$)`,{regexp:new RegExp(re,te),keys:E}}function*x(R,I,F){if(I===R.length)return yield F;const y=R[I];if(y.type==="group"){const T=F.slice();for(const z of x(y.tokens,0,T))yield*x(R,I+1,z)}else F.push(y);yield*x(R,I+1,F)}function _(R,I,F){let y="",T="",z=!0;for(let E=0;E<R.length;E++){const B=R[E];if(B.type==="text"){y+=i(B.value),T+=B.value,z||(z=B.value.includes(I));continue}if(B.type==="param"||B.type==="wildcard"){if(!z&&!T)throw new TypeError(`Missing text after "${B.name}": ${a}`);B.type==="param"?y+=`(${O(I,z?"":T)}+)`:y+="([\\s\\S]+)",F.push(B),T="",z=!1;continue}}return y}function O(R,I){return I.length<2?R.length<2?`[^${i(R+I)}]`:`(?:(?!${i(R)})[^${i(I)}])`:R.length<2?`(?:(?!${i(I)})[^${i(R)}])`:`(?:(?!${i(I)}|${i(R)})[\\s\\S])`}function C(R){return R.tokens.map(function I(F,y,T){if(F.type==="text")return s(F.value);if(F.type==="group")return`{${F.tokens.map(I).join("")}}`;const E=P(F.name)&&w(T[y+1])?F.name:JSON.stringify(F.name);if(F.type==="param")return`:${E}`;if(F.type==="wildcard")return`*${E}`;throw new TypeError(`Unexpected token: ${F}`)}).join("")}function P(R){const[I,...F]=R;return r.test(I)?F.every(y=>n.test(y)):!1}function w(R){return(R==null?void 0:R.type)!=="text"?!0:!n.test(R.value[0])}return _t}var kV=jV();function mf(e,t,r){if(t.length!==e.length)return!0;for(let n=0;n<t.length;n++)if(Math.abs(t[n]-e[n])>r)return!1;return!0}function ff(e,t,r){if(e===void 0&&t||e&&t===void 0)return!1;if(e===void 0||t===void 0)return!0;let n=0;return n+=Math.abs(e.orientation.x-t.orientation.x),n+=Math.abs(e.orientation.y-t.orientation.y),n+=Math.abs(e.orientation.z-t.orientation.z),n+=Math.abs(e.position.x-t.position.x),n+=Math.abs(e.position.y-t.position.y),n+=Math.abs(e.position.z-t.position.z),n>r?!1:e.coordinate_system===t.coordinate_system&&e.tcp===t.tcp}var Qd=1e-4,UV=class gf{constructor(t,r,n,a,o,s,i,l,c,u,d,h){this.nova=t,this.controller=r,this.motionGroup=n,this.initialMotionState=a,this.motionStateSocket=o,this.isVirtual=s,this.tcps=i,this.motionGroupSpecification=l,this.safetySetup=c,this.mounting=u,this.initialControllerState=d,this.controllerStateSocket=h,this.connectedJoggingCartesianSocket=null,this.connectedJoggingJointsSocket=null,this.joggingVelocity=10,this.activationState="inactive",this.rapidlyChangingMotionState=a,this.controllerState=d,h.addEventListener("message",p=>{var f;const m=(f=ar(p.data))==null?void 0:f.result;m&&Ne.runInAction(()=>{this.controllerState=m})}),o.addEventListener("message",p=>{var f;const m=(f=ar(p.data))==null?void 0:f.result;if(!m)throw new Error(`Failed to get motion state for ${this.motionGroupId}: ${p.data}`);mf(this.rapidlyChangingMotionState.state.joint_position.joints,m.state.joint_position.joints,Qd)||Ne.runInAction(()=>{this.rapidlyChangingMotionState.state=m.state}),ff(this.rapidlyChangingMotionState.tcp_pose,m.tcp_pose,Qd)||Ne.runInAction(()=>{this.rapidlyChangingMotionState.tcp_pose=m.tcp_pose})}),Ne.makeAutoObservable(this)}static connect(t,r,n){return Ae(this,null,function*(){var a,o;const[s,i]=r.split("@"),l=n.find(w=>w.controller===i),c=l==null?void 0:l.physical_motion_groups.find(w=>w.motion_group===r);if(!l||!c)throw new Error(`Controller ${i} or motion group ${r} not found`);const u=t.openReconnectingWebsocket(`/motion-groups/${r}/state-stream`),d=yield u.firstMessage(),h=(a=ar(d.data))==null?void 0:a.result;if(!h)throw new Error(`Unable to parse initial motion state message ${d.data}`);console.log(`Connected motion state websocket to motion group ${c.motion_group}. Initial state:
|
|
151
|
+
`,h);const f=(yield t.api.controller.getRobotController(l.controller)).configuration.kind==="VirtualController",m=yield Ae(this,null,function*(){try{return yield t.api.motionGroupInfos.getMounting(c.motion_group)}catch(w){return console.error(`Error fetching mounting for ${c.motion_group}`,w),null}}),b=t.openReconnectingWebsocket(`/controllers/${l.controller}/state-stream?response_rate=1000`),x=yield b.firstMessage(),_=(o=ar(x.data))==null?void 0:o.result;if(!_)throw new Error(`Unable to parse initial controller state message ${x.data}`);console.log(`Connected controller state websocket to controller ${l.controller}. Initial state:
|
|
152
|
+
`,_);const{tcps:O}=yield t.api.motionGroupInfos.listTcps(r),C=yield t.api.motionGroupInfos.getMotionGroupSpecification(r),P=yield t.api.motionGroupInfos.getSafetySetup(r);return new gf(t,l,c,h,u,f,O,C,P,m,_,b)})}get motionGroupId(){return this.motionGroup.motion_group}get controllerId(){return this.controller.controller}get modelFromController(){return this.motionGroup.model_from_controller}get wandelscriptIdentifier(){const t=this.motionGroupId.split("@")[0];return`${this.controllerId.replaceAll("-","_")}_${t}`}get joggingVelocityRads(){return this.joggingVelocity*Math.PI/180}get joints(){return this.initialMotionState.state.joint_position.joints.map((t,r)=>({index:r}))}get dhParameters(){return this.motionGroupSpecification.dh_parameters}get safetyZones(){return this.safetySetup.safety_zones}get mountingPosition(){return this.mounting?[this.mounting.pose.position.x/1e3,this.mounting.pose.position.y/1e3,this.mounting.pose.position.z/1e3]:[0,0,0]}get mountingQuaternion(){var t,r,n,a,o,s;const i=new ke.Vector3(((r=(t=this.mounting)==null?void 0:t.pose.orientation)==null?void 0:r.x)||0,((a=(n=this.mounting)==null?void 0:n.pose.orientation)==null?void 0:a.y)||0,((s=(o=this.mounting)==null?void 0:o.pose.orientation)==null?void 0:s.z)||0),l=i.length(),c=i.normalize();return new ke.Quaternion().setFromAxisAngle(c,l)}get isEstopActive(){return["SAFETY_STATE_ROBOT_EMERGENCY_STOP","SAFETY_STATE_DEVICE_EMERGENCY_STOP"].includes(this.controllerState.safety_state)}get isMoveableSafetyState(){return["SAFETY_STATE_NORMAL","SAFETY_STATE_REDUCED"].includes(this.controllerState.safety_state)}get isMoveableOperationMode(){return["OPERATION_MODE_AUTO","OPERATION_MODE_MANUAL","OPERATION_MODE_MANUAL_T1","OPERATION_MODE_MANUAL_T2"].includes(this.controllerState.operation_mode)}get canBeMoved(){return this.isMoveableSafetyState&&this.isMoveableOperationMode&&this.activationState==="active"}deactivate(){return Ae(this,null,function*(){if(this.activationState!=="active"){console.error("Tried to deactivate while already deactivating");return}Ne.runInAction(()=>{this.activationState="deactivating"});try{yield this.nova.api.controller.setDefaultMode(this.controllerId,"MODE_MONITOR"),Ne.runInAction(()=>{this.activationState="inactive"})}catch(t){throw Ne.runInAction(()=>{this.activationState="active"}),t}})}activate(){return Ae(this,null,function*(){if(this.activationState!=="inactive"){console.error("Tried to activate while already activating");return}Ne.runInAction(()=>{this.activationState="activating"});try{yield this.nova.api.controller.setDefaultMode(this.controllerId,"MODE_CONTROL"),Ne.runInAction(()=>{this.activationState="active"})}catch(t){throw Ne.runInAction(()=>{this.activationState="inactive"}),t}})}toggleActivation(){this.activationState==="inactive"?this.activate():this.activationState==="active"&&this.deactivate()}dispose(){this.motionStateSocket.close(),this.connectedJoggingCartesianSocket&&this.connectedJoggingCartesianSocket.close(),this.connectedJoggingJointsSocket&&this.connectedJoggingJointsSocket.close()}setJoggingVelocity(t){this.joggingVelocity=t}},LV=class yf{constructor(t,r={}){this.motionStream=t,this.opts=r,this.cartesianWebsocket=null,this.jointWebsocket=null,this.cartesianJoggingOpts={}}static open(t,r){return Ae(this,arguments,function*(n,a,o={}){const s=yield n.connectMotionStream(a);return new yf(s,o)})}get motionGroupId(){return this.motionStream.motionGroupId}get nova(){return this.motionStream.nova}get numJoints(){return this.motionStream.joints.length}get activeJoggingMode(){return this.cartesianWebsocket?"cartesian":this.jointWebsocket?"joint":"increment"}get activeWebsocket(){return this.cartesianWebsocket||this.jointWebsocket}stop(){return Ae(this,null,function*(){this.cartesianWebsocket&&this.cartesianWebsocket.sendJson({motion_group:this.motionGroupId,position_direction:{x:0,y:0,z:0},rotation_direction:{x:0,y:0,z:0},position_velocity:0,rotation_velocity:0,tcp:this.cartesianJoggingOpts.tcpId,coordinate_system:this.cartesianJoggingOpts.coordSystemId}),this.jointWebsocket&&this.jointWebsocket.sendJson({motion_group:this.motionGroupId,joint_velocities:new Array(this.numJoints).fill(0)})})}dispose(){this.cartesianWebsocket&&this.cartesianWebsocket.dispose(),this.jointWebsocket&&this.jointWebsocket.dispose()}setJoggingMode(t,r){console.log("Setting jogging mode to",t),r&&(FA(this.cartesianJoggingOpts,r)||this.cartesianWebsocket&&(this.cartesianWebsocket.dispose(),this.cartesianWebsocket=null),this.cartesianJoggingOpts=r),t!=="cartesian"&&this.cartesianWebsocket&&(this.cartesianWebsocket.dispose(),this.cartesianWebsocket=null),t!=="joint"&&this.jointWebsocket&&(this.jointWebsocket.dispose(),this.jointWebsocket=null),t==="cartesian"&&!this.cartesianWebsocket&&(this.cartesianWebsocket=this.nova.openReconnectingWebsocket("/motion-groups/move-tcp"),this.cartesianWebsocket.addEventListener("message",n=>{const a=ar(n.data);if(a&&"error"in a)if(this.opts.onError)this.opts.onError(n.data);else throw new Error(n.data)})),t==="joint"&&!this.jointWebsocket&&(this.jointWebsocket=this.nova.openReconnectingWebsocket("/motion-groups/move-joint"),this.jointWebsocket.addEventListener("message",n=>{const a=ar(n.data);if(a&&"error"in a)if(this.opts.onError)this.opts.onError(n.data);else throw new Error(n.data)}))}startJointRotation(t){return Ae(this,arguments,function*({joint:r,direction:n,velocityRadsPerSec:a}){if(!this.jointWebsocket)throw new Error("Joint jogging websocket not connected; call setJoggingMode first");const o=new Array(this.numJoints).fill(0);o[r]=n==="-"?-a:a,this.jointWebsocket.sendJson({motion_group:this.motionGroupId,joint_velocities:o})})}startTCPTranslation(t){return Ae(this,arguments,function*({axis:r,direction:n,velocityMmPerSec:a}){if(!this.cartesianWebsocket)throw new Error("Cartesian jogging websocket not connected; call setJoggingMode first");const o={x:0,y:0,z:0},s=Object.assign({},o);s[r]=n==="-"?-1:1,this.cartesianWebsocket.sendJson({motion_group:this.motionGroupId,position_direction:s,rotation_direction:o,position_velocity:a,rotation_velocity:0,tcp:this.cartesianJoggingOpts.tcpId,coordinate_system:this.cartesianJoggingOpts.coordSystemId})})}startTCPRotation(t){return Ae(this,arguments,function*({axis:r,direction:n,velocityRadsPerSec:a}){if(!this.cartesianWebsocket)throw new Error("Cartesian jogging websocket not connected; call setJoggingMode first");const o={x:0,y:0,z:0},s=Object.assign({},o);s[r]=n==="-"?-1:1,this.cartesianWebsocket.sendJson({motion_group:this.motionGroupId,position_direction:o,rotation_direction:s,position_velocity:0,rotation_velocity:a,tcp:this.cartesianJoggingOpts.tcpId,coordinate_system:this.cartesianJoggingOpts.coordSystemId})})}runIncrementalCartesianMotion(t){return Ae(this,arguments,function*({currentTcpPose:r,currentJoints:n,coordSystemId:a,velocityInRelevantUnits:o,axis:s,direction:i,motion:l}){var c;const u=[];if(!a_(r.coordinate_system,a))throw new Error(`Current TCP pose coordinate system ${r.coordinate_system} does not match target coordinate system ${a}`);if(l.type==="translate"){const p=Object.assign({},r.position);p[s]+=l.distanceMm*(i==="-"?-1:1),u.push({settings:{limits_override:{tcp_velocity_limit:o}},line:{position:p,orientation:r.orientation,coordinate_system:a}})}else if(l.type==="rotate"){const p=new ln(r.orientation.x,r.orientation.y,r.orientation.z),f=p.length(),m=p.clone().normalize(),b=l.distanceRads*(i==="-"?-1:1),x=new ln(0,0,0);x[s]=1;const _=Math.cos(.5*b)*Math.cos(.5*f),O=Math.sin(.5*b)*Math.sin(.5*f),C=Math.sin(.5*b)*Math.cos(.5*f),P=Math.cos(.5*b)*Math.sin(.5*f),w=x.dot(m),R=x.clone().cross(m),I=2*Math.acos(_-O*w),F=I/Math.sin(.5*I),y=new ln().addScaledVector(R,O).addScaledVector(x,C).addScaledVector(m,P).multiplyScalar(F);u.push({settings:{limits_override:{tcp_orientation_velocity_limit:o}},line:{position:r.position,orientation:y,coordinate_system:a}})}const d=yield this.nova.api.motion.planMotion({motion_group:this.motionGroupId,start_joint_position:n,tcp:this.cartesianJoggingOpts.tcpId,commands:u}),h=(c=d.plan_successful_response)==null?void 0:c.motion;if(!h)throw new Error(`Failed to plan jogging increment motion ${JSON.stringify(d)}`);yield this.nova.api.motion.streamMoveForward(h,100,void 0,void 0,void 0,{timeout:1e3*60})})}runIncrementalJointRotation(t){return Ae(this,arguments,function*({joint:r,currentJoints:n,velocityRadsPerSec:a,direction:o,distanceRads:s}){var i;const l=[...n.joints];l[r]+=s*(o==="-"?-1:1);const c=new Array(n.joints.length).fill(a),u=yield this.nova.api.motion.planMotion({motion_group:this.motionGroupId,start_joint_position:n,commands:[{settings:{limits_override:{joint_velocity_limits:{joints:c}}},joint_ptp:{joints:l}}]}),d=(i=u.plan_successful_response)==null?void 0:i.motion;if(!d){console.error("Failed to plan jogging increment motion",u);return}yield this.nova.api.motion.streamMoveForward(d,100,void 0,void 0,void 0,{timeout:1e3*60})})}},Xd=1e-4;function DV(e,t){const r=new vt.Vector3(t.x,t.y,t.z),n=new vt.Vector3(e.x,e.y,e.z),a=r.length(),o=r.normalize();let s=n.length(),i=n.normalize();i.dot(o)<0&&(s=-s,i=i.multiplyScalar(-1));let l=s-a;return l-=2*Math.PI*Math.floor((l+Math.PI)/(2*Math.PI)),s=a+l,i.multiplyScalar(s)}var NV=class bf{constructor(t,r,n,a,o){this.nova=t,this.controller=r,this.motionGroup=n,this.initialMotionState=a,this.motionStateSocket=o,this.rapidlyChangingMotionState=a,o.addEventListener("message",s=>{var i;const l=(i=ar(s.data))==null?void 0:i.result;if(!l)throw new Error(`Failed to get motion state for ${this.motionGroupId}: ${s.data}`);mf(this.rapidlyChangingMotionState.state.joint_position.joints,l.state.joint_position.joints,Xd)||Ne.runInAction(()=>{this.rapidlyChangingMotionState.state=l.state}),ff(this.rapidlyChangingMotionState.tcp_pose,l.tcp_pose,Xd)||Ne.runInAction(()=>{this.rapidlyChangingMotionState.tcp_pose==null?this.rapidlyChangingMotionState.tcp_pose=l.tcp_pose:this.rapidlyChangingMotionState.tcp_pose={position:l.tcp_pose.position,orientation:DV(l.tcp_pose.orientation,this.rapidlyChangingMotionState.tcp_pose.orientation),tcp:l.tcp_pose.tcp,coordinate_system:l.tcp_pose.coordinate_system}})}),Ne.makeAutoObservable(this)}static open(t,r){return Ae(this,null,function*(){var n;const{instances:a}=yield t.api.controller.listControllers(),[o,s]=r.split("@"),i=a.find(h=>h.controller===s),l=i==null?void 0:i.physical_motion_groups.find(h=>h.motion_group===r);if(!i||!l)throw new Error(`Controller ${s} or motion group ${r} not found`);const c=t.openReconnectingWebsocket(`/motion-groups/${r}/state-stream`),u=yield c.firstMessage();console.log("got first message",u);const d=(n=ar(u.data))==null?void 0:n.result;if(!d)throw new Error(`Unable to parse initial motion state message ${u.data}`);return console.log(`Connected motion state websocket to motion group ${l.motion_group}. Initial state:
|
|
153
|
+
`,d),new bf(t,i,l,d,c)})}get motionGroupId(){return this.motionGroup.motion_group}get controllerId(){return this.controller.controller}get modelFromController(){return this.motionGroup.model_from_controller}get wandelscriptIdentifier(){const t=this.motionGroupId.split("@")[0];return`${this.controllerId.replaceAll("-","_")}_${t}`}get joints(){return this.initialMotionState.state.joint_position.joints.map((t,r)=>({index:r}))}dispose(){this.motionStateSocket.close()}},BV=class{constructor(e,t){this.cellId=e,this.opts=t,this.system=this.withUnwrappedResponsesOnly(CV),this.cell=this.withUnwrappedResponsesOnly(NE),this.deviceConfig=this.withCellId(WE),this.motionGroup=this.withCellId(sV),this.motionGroupInfos=this.withCellId(lV),this.controller=this.withCellId(FE),this.program=this.withCellId(mV),this.programValues=this.withCellId(gV),this.controllerIOs=this.withCellId(GE),this.motionGroupKinematic=this.withCellId(hV),this.motion=this.withCellId(aV),this.coordinateSystems=this.withCellId(qE),this.application=this.withCellId(Wd),this.applicationGlobal=this.withUnwrappedResponsesOnly(Wd),this.motionGroupJogging=this.withCellId(uV),this.virtualRobot=this.withCellId(TV),this.virtualRobotSetup=this.withCellId(IV),this.virtualRobotMode=this.withCellId(EV),this.virtualRobotBehavior=this.withCellId(AV),this.libraryProgramMetadata=this.withCellId(XE),this.libraryProgram=this.withCellId(KE),this.libraryRecipeMetadata=this.withCellId(rV),this.libraryRecipe=this.withCellId(eV),this.storeObject=this.withCellId(OV),this.storeCollisionComponents=this.withCellId(bV),this.storeCollisionScenes=this.withCellId(SV)}withCellId(e){var t,r;const n=new e(ol(rn({},this.opts),{isJsonMime:a=>a==="application/json"}),(t=this.opts.basePath)!=null?t:"",(r=this.opts.axiosInstance)!=null?r:A.create());for(const a of Reflect.ownKeys(Reflect.getPrototypeOf(n)))if(a!=="constructor"&&typeof n[a]=="function"){const o=n[a];n[a]=(...s)=>o.apply(n,[this.cellId,...s]).then(i=>i.data)}return n}withUnwrappedResponsesOnly(e){var t,r;const n=new e(ol(rn({},this.opts),{isJsonMime:a=>a==="application/json"}),(t=this.opts.basePath)!=null?t:"",(r=this.opts.axiosInstance)!=null?r:A.create());for(const a of Reflect.ownKeys(Reflect.getPrototypeOf(n)))if(a!=="constructor"&&typeof n[a]=="function"){const o=n[a];n[a]=(...s)=>o.apply(n,s).then(i=>i.data)}return n}},FV=class{constructor(){this.connections=[]}handleAPIRequest(e){return Ae(this,null,function*(){var t,r,n;const a=[{method:"GET",path:"/cells/:cellId/controllers",handle(){return{instances:[{controller:"mock-ur5e",model_name:"UniversalRobots::Controller",host:"mock-ur5e",allow_software_install_on_controller:!0,physical_motion_groups:[{motion_group:"0@mock-ur5e",name_from_controller:"UR5e",active:!1,model_from_controller:"UniversalRobots_UR5e"}],has_error:!1,error_details:""}]}}},{method:"GET",path:"/cells/:cellId/controllers/:controllerId",handle(){return{configuration:{kind:"VirtualController",manufacturer:"universalrobots",position:"[0,-1.571,-1.571,-1.571,1.571,-1.571,0]",type:"universalrobots-ur5e"},name:"mock-ur5"}}},{method:"GET",path:"/cells/:cellId/motion-groups/:motionGroupId/specification",handle(){return{dh_parameters:[{alpha:1.5707963267948966,theta:0,a:0,d:162.25,reverse_rotation_direction:!1},{alpha:0,theta:0,a:-425,d:0,reverse_rotation_direction:!1},{alpha:0,theta:0,a:-392.2,d:0,reverse_rotation_direction:!1},{alpha:1.5707963267948966,theta:0,a:0,d:133.3,reverse_rotation_direction:!1},{alpha:-1.5707963267948966,theta:0,a:0,d:99.7,reverse_rotation_direction:!1},{alpha:0,theta:0,a:0,d:99.6,reverse_rotation_direction:!1}],mechanical_joint_limits:[{joint:"JOINTNAME_AXIS_1",lower_limit:-6.335545063018799,upper_limit:6.335545063018799,unlimited:!1},{joint:"JOINTNAME_AXIS_2",lower_limit:-6.335545063018799,upper_limit:6.335545063018799,unlimited:!1},{joint:"JOINTNAME_AXIS_3",lower_limit:-6.335545063018799,upper_limit:6.335545063018799,unlimited:!1},{joint:"JOINTNAME_AXIS_4",lower_limit:-6.335545063018799,upper_limit:6.335545063018799,unlimited:!1},{joint:"JOINTNAME_AXIS_5",lower_limit:-6.335545063018799,upper_limit:6.335545063018799,unlimited:!1},{joint:"JOINTNAME_AXIS_6",lower_limit:-6.335545063018799,upper_limit:6.335545063018799,unlimited:!1}]}}},{method:"GET",path:"/cells/:cellId/motion-groups/:motionGroupId/safety-setup",handle(){return{safety_settings:[{safety_state:"SAFETY_NORMAL",settings:{joint_position_limits:[{joint:"JOINTNAME_AXIS_1",lower_limit:-2.96705961227417,upper_limit:2.96705961227417,unlimited:!1},{joint:"JOINTNAME_AXIS_2",lower_limit:-1.7453292608261108,upper_limit:2.7925267219543457,unlimited:!1},{joint:"JOINTNAME_AXIS_3",lower_limit:-3.3161256313323975,upper_limit:.40142571926116943,unlimited:!1},{joint:"JOINTNAME_AXIS_4",lower_limit:-3.4906585216522217,upper_limit:3.4906585216522217,unlimited:!1},{joint:"JOINTNAME_AXIS_5",lower_limit:-2.4434609413146973,upper_limit:2.4434609413146973,unlimited:!1},{joint:"JOINTNAME_AXIS_6",lower_limit:-4.71238899230957,upper_limit:4.71238899230957,unlimited:!1}],joint_velocity_limits:[{joint:"JOINTNAME_AXIS_1",limit:3.1415927410125732},{joint:"JOINTNAME_AXIS_2",limit:3.1415927410125732},{joint:"JOINTNAME_AXIS_3",limit:3.4906585216522217},{joint:"JOINTNAME_AXIS_4",limit:6.108652591705322},{joint:"JOINTNAME_AXIS_5",limit:6.108652591705322},{joint:"JOINTNAME_AXIS_6",limit:6.981317043304443}],joint_acceleration_limits:[],joint_torque_limits:[],tcp_velocity_limit:1800}}],safety_zones:[{id:1,priority:0,geometry:{compound:{child_geometries:[{convex_hull:{vertices:[{x:-800,y:-1330,z:-1820},{x:1650,y:-1330,z:-1820},{x:1650,y:1330,z:-1820},{x:-800,y:1330,z:-1820}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"box"},{convex_hull:{vertices:[{x:-800,y:-1330,z:-1820},{x:1650,y:-1330,z:-1820},{x:1650,y:-1330,z:1500},{x:-800,y:-1330,z:1500}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"box"},{convex_hull:{vertices:[{x:-800,y:-1330,z:-1820},{x:-800,y:1330,z:-1820},{x:-800,y:1330,z:1500},{x:-800,y:-1330,z:1500}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"box"},{convex_hull:{vertices:[{x:1650,y:1330,z:1500},{x:-800,y:1330,z:1500},{x:-800,y:-1330,z:1500},{x:1650,y:-1330,z:1500}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"box"},{convex_hull:{vertices:[{x:1650,y:1330,z:1500},{x:-800,y:1330,z:1500},{x:-800,y:1330,z:-1820},{x:1650,y:1330,z:-1820}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"box"},{convex_hull:{vertices:[{x:1650,y:1330,z:1500},{x:1650,y:-1330,z:1500},{x:1650,y:-1330,z:-1820},{x:1650,y:1330,z:-1820}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"box"}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"Cell workzone"},motion_group_uid:1},{id:2,priority:0,geometry:{convex_hull:{vertices:[{x:1650,y:1330,z:-1850},{x:865,y:1330,z:-1850},{x:865,y:-720,z:-1850},{x:1650,y:-720,z:-1850},{x:1650,y:1330,z:-920},{x:865,y:1330,z:-920},{x:865,y:-720,z:-920},{x:1650,y:-720,z:-920}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"Transport"},motion_group_uid:1},{id:3,priority:0,geometry:{convex_hull:{vertices:[{x:1650,y:1330,z:-600},{x:865,y:1330,z:-600},{x:865,y:430,z:-600},{x:1650,y:430,z:-600},{x:1650,y:1330,z:-1250},{x:865,y:1330,z:-1250},{x:865,y:430,z:-1250},{x:1650,y:430,z:-1250}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"Tunel"},motion_group_uid:1},{id:4,priority:0,geometry:{convex_hull:{vertices:[{x:1650,y:-760,z:-440},{x:900,y:-760,z:-440},{x:900,y:-1330,z:-440},{x:1650,y:-1330,z:-440},{x:1650,y:-760,z:-1800},{x:900,y:-760,z:-1800},{x:900,y:-1330,z:-1800},{x:1650,y:-1330,z:-1800}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"Fanuc controller"},motion_group_uid:1},{id:6,priority:0,geometry:{convex_hull:{vertices:[{x:-200,y:-200,z:-1900},{x:200,y:-200,z:-1900},{x:200,y:200,z:-1900},{x:-200,y:200,z:-1900},{x:-200,y:-200,z:-350},{x:200,y:-200,z:-350},{x:200,y:200,z:-350},{x:-200,y:200,z:-350}]},init_pose:{position:{x:0,y:0,z:0},orientation:{x:0,y:0,z:0,w:1}},id:"Robot base"},motion_group_uid:1}],robot_model_geometries:[{link_index:1,geometry:{sphere:{radius:270},init_pose:{position:{x:-70,y:-70,z:-50},orientation:{x:0,y:0,z:0,w:1}},id:"link1_sphere"}},{link_index:2,geometry:{capsule:{radius:160,cylinder_height:800},init_pose:{position:{x:-450,y:40,z:170},orientation:{x:0,y:-.7071067811865475,z:0,w:.7071067811865476}},id:"link2_capsule"}},{link_index:3,geometry:{sphere:{radius:270},init_pose:{position:{x:-110,y:10,z:-100},orientation:{x:0,y:0,z:0,w:1}},id:"link3_sphere"}},{link_index:4,geometry:{capsule:{radius:110,cylinder_height:600},init_pose:{position:{x:0,y:300,z:40},orientation:{x:-.7071067811865475,y:0,z:0,w:.7071067811865476}},id:"link4_capsule"}},{link_index:5,geometry:{sphere:{radius:75},init_pose:{position:{x:0,y:0,z:-50},orientation:{x:0,y:0,z:0,w:1}},id:"link5_sphere"}}],tool_geometries:[]}}},{method:"GET",path:"/cells/:cellId/coordinate-systems",handle(){return{coordinatesystems:[{coordinate_system:"",name:"world",reference_uid:"",position:{x:0,y:0,z:0},rotation:{angles:[0,0,0],type:"ROTATION_VECTOR"}}]}}},{method:"GET",path:"/cells/:cellId/motion-groups/:motionGroupId/tcps",handle(){return{tcps:[{id:"Flange",readable_name:"Default-Flange",position:{x:0,y:0,z:0},rotation:{angles:[0,0,0,0],type:"ROTATION_VECTOR"}},{id:"complex-tcp-position",readable_name:"Complex TCP Position",position:{x:-200,y:300,z:150},rotation:{angles:[-.12139440409113832,-.06356210998212003,-.2023240068185639,0],type:"ROTATION_VECTOR"}}]}}}],o=((t=e.method)==null?void 0:t.toUpperCase())||"GET",s="/cells"+((n=(r=e.url)==null?void 0:r.split("/cells")[1])==null?void 0:n.split("?")[0]);for(const i of a){const l=kV.match(i.path)(s||"");if(o===i.method&&l){const c=i.handle();return{status:200,statusText:"Success",data:JSON.stringify(c),headers:{},config:e,request:{responseURL:e.url}}}}throw new hl(`No mock handler matched this request: ${o} ${s}`,"404",e)})}handleWebsocketConnection(e){this.connections.push(e),setTimeout(()=>{e.dispatchEvent(new Event("open")),console.log("Websocket connection opened from",e.url),e.url.includes("/state-stream")&&e.dispatchEvent(new MessageEvent("message",{data:JSON.stringify(zV)})),e.url.includes("/move-joint")&&e.dispatchEvent(new MessageEvent("message",{data:JSON.stringify({result:{motion_group:"0@ur",state:{controller:"ur",operation_mode:"OPERATION_MODE_AUTO",safety_state:"SAFETY_STATE_NORMAL",timestamp:"2024-09-18T12:48:26.096266444Z",velocity_override:100,motion_groups:[{motion_group:"0@ur",controller:"ur",joint_position:{joints:[1.3492152690887451,-1.5659207105636597,1.6653711795806885,-1.0991662740707397,-1.829018235206604,1.264623761177063]},joint_velocity:{joints:[0,0,0,0,0,0]},flange_pose:{position:{x:6.437331889439328,y:-628.4123774830913,z:577.0569957147832},orientation:{x:-1.683333649797158,y:-1.9783363827298732,z:-.4928031860165713},coordinate_system:""},tcp_pose:{position:{x:6.437331889439328,y:-628.4123774830913,z:577.0569957147832},orientation:{x:-1.683333649797158,y:-1.9783363827298732,z:-.4928031860165713},coordinate_system:"",tcp:"Flange"},velocity:{linear:{x:0,y:0,z:0},angular:{x:-0,y:0,z:0},coordinate_system:""},force:{force:{x:0,y:0,z:0},moment:{x:0,y:0,z:0},coordinate_system:""},joint_limit_reached:{limit_reached:[!1,!1,!1,!1,!1,!1]},joint_current:{joints:[0,0,0,0,0,0]},sequence_number:"671259"}],sequence_number:"671259"},movement_state:"MOVEMENT_STATE_MOVING"}})})),e.url.includes("/move-tcp")&&e.dispatchEvent(new MessageEvent("message",{data:JSON.stringify({result:{motion_group:"0@ur",state:{controller:"ur",operation_mode:"OPERATION_MODE_AUTO",safety_state:"SAFETY_STATE_NORMAL",timestamp:"2024-09-18T12:43:12.188335774Z",velocity_override:100,motion_groups:[{motion_group:"0@ur",controller:"ur",joint_position:{joints:[1.3352527618408203,-1.5659207105636597,1.6653711795806885,-1.110615611076355,-1.829018235206604,1.264623761177063]},joint_velocity:{joints:[0,0,0,0,0,0]},flange_pose:{position:{x:-2.763015284002938,y:-630.2151479701106,z:577.524509114342},orientation:{x:-1.704794877102097,y:-1.9722372952861567,z:-.4852079204210754},coordinate_system:""},tcp_pose:{position:{x:-2.763015284002938,y:-630.2151479701106,z:577.524509114342},orientation:{x:-1.704794877102097,y:-1.9722372952861567,z:-.4852079204210754},coordinate_system:"",tcp:"Flange"},velocity:{linear:{x:0,y:0,z:0},angular:{x:-0,y:0,z:0},coordinate_system:""},force:{force:{x:0,y:0,z:0},moment:{x:0,y:0,z:0},coordinate_system:""},joint_limit_reached:{limit_reached:[!1,!1,!1,!1,!1,!1]},joint_current:{joints:[0,0,0,0,0,0]},sequence_number:"627897"}],sequence_number:"627897"},movement_state:"MOVEMENT_STATE_MOVING"}})}))},10)}handleWebsocketMessage(e,t){console.log(`Received message on ${e.url}`,t)}},zV={result:{state:{motion_group:"0@universalrobots-ur5e",controller:"universalrobots-ur5e",joint_position:{joints:[1.1699999570846558,-1.5700000524520874,1.3600000143051147,1.0299999713897705,1.2899999618530273,1.2799999713897705]},joint_velocity:{joints:[0,0,0,0,0,0]},flange_pose:{position:{x:1.3300010259703043,y:-409.2680714682808,z:531.0203477065281},orientation:{x:1.7564919306270736,y:-1.7542521568325058,z:.7326972590614671},coordinate_system:""},tcp_pose:{position:{x:1.3300010259703043,y:-409.2680714682808,z:531.0203477065281},orientation:{x:1.7564919306270736,y:-1.7542521568325058,z:.7326972590614671},coordinate_system:"",tcp:"Flange"},velocity:{linear:{x:0,y:0,z:0},angular:{x:0,y:0,z:0},coordinate_system:""},force:{force:{x:0,y:0,z:0},moment:{x:0,y:0,z:0},coordinate_system:""},joint_limit_reached:{limit_reached:[!1,!1,!1,!1,!1,!1]},joint_current:{joints:[0,0,0,0,0,0]},sequence_number:"1"},tcp_pose:{position:{x:302.90748476115556,y:-152.87065869452337,z:424.0454619321661},orientation:{x:2.3403056115045353,y:-1.1706836379431356,z:.9772511964246311},coordinate_system:"",tcp:"Flange"}}},GV=class{constructor(e){this.authPromise=null,this.accessToken=null;var t;const r=(t=e.cellId)!=null?t:"cell";this.config=rn({cellId:r},e),this.accessToken=e.accessToken||Ci.getString("wbjs.access_token")||null,this.config.instanceUrl==="https://mock.example.com"&&(this.mock=new FV);const n=A.create({baseURL:Vi(this.config.instanceUrl,"/api/v1"),headers:{"User-Agent":"Wandelbots-Nova-JS-SDK"}});n.interceptors.request.use(a=>Ae(this,null,function*(){return a.headers.Authorization||(this.accessToken?a.headers.Authorization=`Bearer ${this.accessToken}`:this.config.username&&this.config.password&&(a.headers.Authorization=`Basic ${btoa(e.username+":"+e.password)}`)),a})),typeof window<"u"&&n.interceptors.response.use(a=>a,a=>Ae(this,null,function*(){var o,s;if(kE(a))if(((o=a.response)==null?void 0:o.status)===401)try{if(yield this.renewAuthentication(),a.config)return this.accessToken?a.config.headers.Authorization=`Bearer ${this.accessToken}`:delete a.config.headers.Authorization,n.request(a.config)}catch(i){return Promise.reject(i)}else((s=a.response)==null?void 0:s.status)===503&&(yield fetch(window.location.href)).status===503&&window.location.reload();return Promise.reject(a)})),this.api=new BV(r,ol(rn({},e),{basePath:Vi(this.config.instanceUrl,"/api/v1"),isJsonMime:a=>a==="application/json",baseOptions:rn(rn({},this.mock?{adapter:a=>this.mock.handleAPIRequest(a)}:{}),e.baseOptions),axiosInstance:n}))}renewAuthentication(){return Ae(this,null,function*(){if(!this.authPromise){this.authPromise=s_(this.config.instanceUrl);try{this.accessToken=yield this.authPromise,this.accessToken?Ci.setString("wbjs.access_token",this.accessToken):Ci.delete("wbjs.access_token")}finally{this.authPromise=null}}})}makeWebsocketURL(e){const t=new URL(Vi(this.config.instanceUrl,`/api/v1/cells/${this.config.cellId}`,e));return t.protocol=t.protocol.replace("http","ws"),t.protocol=t.protocol.replace("https","wss"),this.accessToken?t.searchParams.append("token",this.accessToken):this.config.username&&this.config.password&&(t.username=this.config.username,t.password=this.config.password),t.toString()}openReconnectingWebsocket(e){return new r_(this.makeWebsocketURL(e),{mock:this.mock})}connectMotionStream(e){return Ae(this,null,function*(){return yield NV.open(this,e)})}connectJogger(e){return Ae(this,null,function*(){return yield LV.open(this,e)})}connectMotionGroups(e){return Ae(this,null,function*(){const{instances:t}=yield this.api.controller.listControllers();return Promise.all(e.map(r=>UV.connect(this,r,t)))})}connectMotionGroup(e){return Ae(this,null,function*(){return(yield this.connectMotionGroups([e]))[0]})}};function HV(e){try{return JSON.stringify(e)}catch{return}}function qV(e,t){throw new Error(t+` ${JSON.stringify(e)}`)}function JV(e){var t,r,n,a;return e instanceof hl&&e.code==="ERR_NETWORK"?"Failed to connect to the server. Please check your internet connection.":e instanceof hl&&e.response?`${(t=e.response)==null?void 0:t.status} ${(r=e.response)==null?void 0:r.statusText} from ${(n=e.response)==null?void 0:n.config.url}: ${JSON.stringify((a=e.response)==null?void 0:a.data)}`:e instanceof Error?e.message:`Unexpected error: ${HV(e)||e}`}const fc=e=>{const t=e.softTimeout||3e3,[r,n]=ee.useState(!1),a=q.useTheme();return ee.useEffect(()=>{const o=setTimeout(()=>{n(!0)},t);return()=>clearTimeout(o)}),S.jsx(q.Stack,{width:"100%",height:"100%",alignItems:"center",justifyContent:"center",sx:{color:a.palette.text.primary},children:e.error?S.jsx(vf,{loadingMessage:e.message,error:e.error}):S.jsxs(S.Fragment,{children:[S.jsx(q.CircularProgress,{sx:{marginBottom:"24px"}}),!!e.message&&S.jsx("div",{children:e.message}),S.jsx(q.Stack,{sx:{visibility:r?"visible":"hidden",marginTop:"1rem",color:a.palette.text.secondary},children:"This is taking longer than expected..."})]})})},vf=e=>{const t=JV(e.error),r=e.error instanceof Error?e.error.stack:null,n=q.useTheme();return S.jsxs(q.Stack,{sx:{maxHeight:"100%",maxWidth:"min(100%, 800px)",padding:2,overflow:"auto",color:n.palette.error.main,"& pre":{whiteSpace:"pre-wrap",wordBreak:"break-word",paddingBottom:"3rem"}},children:[(e.loadingMessage?`Error while ${Sl.lowerFirst(q.capitalize(e.loadingMessage))} - `:"")+t,S.jsx("br",{}),r&&S.jsx("pre",{children:r})]})},WV=({title:e,titleId:t,...r},n)=>V.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:19,height:10,fill:"none",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.createElement("path",{fill:"#fff",fillRule:"evenodd",d:"M5.131.312a.9.9 0 0 1 0 1.272L3.07 3.645h12.44l-2.06-2.061A.9.9 0 0 1 14.72.313l3.596 3.596a.9.9 0 0 1 0 1.271l-3.596 3.597a.9.9 0 0 1-1.271-1.272l2.061-2.062H3.07L5.13 7.505A.9.9 0 0 1 3.86 8.777L.263 5.18a.9.9 0 0 1 0-1.271L3.86.312a.9.9 0 0 1 1.271 0",clipRule:"evenodd"})),YV=ee.forwardRef(WV),KV=({title:e,titleId:t,...r},n)=>V.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:19,height:10,fill:"none",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.createElement("path",{fill:"#fff",fillRule:"evenodd",d:"M5.131.312a.9.9 0 0 1 0 1.272L3.07 3.645h12.44l-2.06-2.061A.9.9 0 0 1 14.72.313l3.596 3.596a.9.9 0 0 1 0 1.271l-3.596 3.597a.9.9 0 0 1-1.271-1.272l2.061-2.062H3.07L5.13 7.505A.9.9 0 0 1 3.86 8.777L.263 5.18a.9.9 0 0 1 0-1.271L3.86.312a.9.9 0 0 1 1.271 0",clipRule:"evenodd"})),QV=ee.forwardRef(KV),XV=({title:e,titleId:t,...r},n)=>V.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:10,height:19,fill:"none",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.createElement("path",{fill:"#fff",fillRule:"evenodd",d:"M9.522 14.811A.899.899 0 1 0 8.25 13.54L6.19 15.601V3.16L8.25 5.221A.9.9 0 0 0 9.522 3.95L5.926.354a.9.9 0 0 0-1.272 0L1.058 3.95a.9.9 0 1 0 1.271 1.271L4.391 3.16v12.442L2.329 13.54a.899.899 0 1 0-1.271 1.271l3.596 3.597a.9.9 0 0 0 1.272 0z",clipRule:"evenodd"})),ZV=ee.forwardRef(XV),eI=({title:e,titleId:t,...r},n)=>V.createElement("svg",{width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.createElement("path",{d:"M8 16C5.76667 16 3.875 15.225 2.325 13.675C0.775 12.125 0 10.2333 0 8C0 5.76667 0.775 3.875 2.325 2.325C3.875 0.775 5.76667 0 8 0C9.15 0 10.25 0.2375 11.3 0.7125C12.35 1.1875 13.25 1.86667 14 2.75V0H16V7H9V5H13.2C12.6667 4.06667 11.9375 3.33333 11.0125 2.8C10.0875 2.26667 9.08333 2 8 2C6.33333 2 4.91667 2.58333 3.75 3.75C2.58333 4.91667 2 6.33333 2 8C2 9.66667 2.58333 11.0833 3.75 12.25C4.91667 13.4167 6.33333 14 8 14C9.28333 14 10.4417 13.6333 11.475 12.9C11.0583 14.1 12.5083 12.1667 11.475 12.9L12.9 14.325C11.4667 15.4417 9.83333 16 8 16Z",fill:"white"})),tI=ee.forwardRef(eI);function rI(){this.__data__=[],this.size=0}function Sf(e,t){return e===t||e!==e&&t!==t}function ks(e,t){for(var r=e.length;r--;)if(Sf(e[r][0],t))return r;return-1}var nI=Array.prototype,aI=nI.splice;function oI(e){var t=this.__data__,r=ks(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():aI.call(t,r,1),--this.size,!0}function sI(e){var t=this.__data__,r=ks(t,e);return r<0?void 0:t[r][1]}function iI(e){return ks(this.__data__,e)>-1}function lI(e,t){var r=this.__data__,n=ks(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}function Yt(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Yt.prototype.clear=rI;Yt.prototype.delete=oI;Yt.prototype.get=sI;Yt.prototype.has=iI;Yt.prototype.set=lI;function cI(){this.__data__=new Yt,this.size=0}function uI(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function dI(e){return this.__data__.get(e)}function hI(e){return this.__data__.has(e)}var pI="[object AsyncFunction]",mI="[object Function]",fI="[object GeneratorFunction]",gI="[object Proxy]";function xf(e){if(!wr(e))return!1;var t=Mr(e);return t==mI||t==fI||t==pI||t==gI}var Ii=jt["__core-js_shared__"],Zd=function(){var e=/[^.]+$/.exec(Ii&&Ii.keys&&Ii.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function yI(e){return!!Zd&&Zd in e}var bI=Function.prototype,vI=bI.toString;function jr(e){if(e!=null){try{return vI.call(e)}catch{}try{return e+""}catch{}}return""}var SI=/[\\^$.*+?()[\]{}|]/g,xI=/^\[object .+?Constructor\]$/,OI=Function.prototype,wI=Object.prototype,CI=OI.toString,PI=wI.hasOwnProperty,TI=RegExp("^"+CI.call(PI).replace(SI,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function RI(e){if(!wr(e)||yI(e))return!1;var t=xf(e)?TI:xI;return t.test(jr(e))}function AI(e,t){return e==null?void 0:e[t]}function kr(e,t){var r=AI(e,t);return RI(r)?r:void 0}var ya=kr(jt,"Map"),ba=kr(Object,"create");function _I(){this.__data__=ba?ba(null):{},this.size=0}function EI(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var VI="__lodash_hash_undefined__",II=Object.prototype,MI=II.hasOwnProperty;function $I(e){var t=this.__data__;if(ba){var r=t[e];return r===VI?void 0:r}return MI.call(t,e)?t[e]:void 0}var jI=Object.prototype,kI=jI.hasOwnProperty;function UI(e){var t=this.__data__;return ba?t[e]!==void 0:kI.call(t,e)}var LI="__lodash_hash_undefined__";function DI(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=ba&&t===void 0?LI:t,this}function Tr(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Tr.prototype.clear=_I;Tr.prototype.delete=EI;Tr.prototype.get=$I;Tr.prototype.has=UI;Tr.prototype.set=DI;function NI(){this.size=0,this.__data__={hash:new Tr,map:new(ya||Yt),string:new Tr}}function BI(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Us(e,t){var r=e.__data__;return BI(t)?r[typeof t=="string"?"string":"hash"]:r.map}function FI(e){var t=Us(this,e).delete(e);return this.size-=t?1:0,t}function zI(e){return Us(this,e).get(e)}function GI(e){return Us(this,e).has(e)}function HI(e,t){var r=Us(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}function Kt(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}Kt.prototype.clear=NI;Kt.prototype.delete=FI;Kt.prototype.get=zI;Kt.prototype.has=GI;Kt.prototype.set=HI;var qI=200;function JI(e,t){var r=this.__data__;if(r instanceof Yt){var n=r.__data__;if(!ya||n.length<qI-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new Kt(n)}return r.set(e,t),this.size=r.size,this}function Bt(e){var t=this.__data__=new Yt(e);this.size=t.size}Bt.prototype.clear=cI;Bt.prototype.delete=uI;Bt.prototype.get=dI;Bt.prototype.has=hI;Bt.prototype.set=JI;var WI="__lodash_hash_undefined__";function YI(e){return this.__data__.set(e,WI),this}function KI(e){return this.__data__.has(e)}function Wo(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new Kt;++t<r;)this.add(e[t])}Wo.prototype.add=Wo.prototype.push=YI;Wo.prototype.has=KI;function QI(e,t){for(var r=-1,n=e==null?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}function XI(e,t){return e.has(t)}var ZI=1,e2=2;function Of(e,t,r,n,a,o){var s=r&ZI,i=e.length,l=t.length;if(i!=l&&!(s&&l>i))return!1;var c=o.get(e),u=o.get(t);if(c&&u)return c==t&&u==e;var d=-1,h=!0,p=r&e2?new Wo:void 0;for(o.set(e,t),o.set(t,e);++d<i;){var f=e[d],m=t[d];if(n)var b=s?n(m,f,d,t,e,o):n(f,m,d,e,t,o);if(b!==void 0){if(b)continue;h=!1;break}if(p){if(!QI(t,function(x,_){if(!XI(p,_)&&(f===x||a(f,x,r,n,o)))return p.push(_)})){h=!1;break}}else if(!(f===m||a(f,m,r,n,o))){h=!1;break}}return o.delete(e),o.delete(t),h}var eh=jt.Uint8Array;function t2(e){var t=-1,r=Array(e.size);return e.forEach(function(n,a){r[++t]=[a,n]}),r}function r2(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var n2=1,a2=2,o2="[object Boolean]",s2="[object Date]",i2="[object Error]",l2="[object Map]",c2="[object Number]",u2="[object RegExp]",d2="[object Set]",h2="[object String]",p2="[object Symbol]",m2="[object ArrayBuffer]",f2="[object DataView]",th=lr?lr.prototype:void 0,Mi=th?th.valueOf:void 0;function g2(e,t,r,n,a,o,s){switch(r){case f2:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case m2:return!(e.byteLength!=t.byteLength||!o(new eh(e),new eh(t)));case o2:case s2:case c2:return Sf(+e,+t);case i2:return e.name==t.name&&e.message==t.message;case u2:case h2:return e==t+"";case l2:var i=t2;case d2:var l=n&n2;if(i||(i=r2),e.size!=t.size&&!l)return!1;var c=s.get(e);if(c)return c==t;n|=a2,s.set(e,t);var u=Of(i(e),i(t),n,a,o,s);return s.delete(e),u;case p2:if(Mi)return Mi.call(e)==Mi.call(t)}return!1}function y2(e,t){for(var r=-1,n=t.length,a=e.length;++r<n;)e[a+r]=t[r];return e}var $t=Array.isArray;function b2(e,t,r){var n=t(e);return $t(e)?n:y2(n,r(e))}function v2(e,t){for(var r=-1,n=e==null?0:e.length,a=0,o=[];++r<n;){var s=e[r];t(s,r,e)&&(o[a++]=s)}return o}function S2(){return[]}var x2=Object.prototype,O2=x2.propertyIsEnumerable,rh=Object.getOwnPropertySymbols,w2=rh?function(e){return e==null?[]:(e=Object(e),v2(rh(e),function(t){return O2.call(e,t)}))}:S2;function C2(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var P2="[object Arguments]";function nh(e){return Cr(e)&&Mr(e)==P2}var wf=Object.prototype,T2=wf.hasOwnProperty,R2=wf.propertyIsEnumerable,Cf=nh(function(){return arguments}())?nh:function(e){return Cr(e)&&T2.call(e,"callee")&&!R2.call(e,"callee")};function A2(){return!1}var Pf=typeof exports=="object"&&exports&&!exports.nodeType&&exports,ah=Pf&&typeof module=="object"&&module&&!module.nodeType&&module,_2=ah&&ah.exports===Pf,oh=_2?jt.Buffer:void 0,E2=oh?oh.isBuffer:void 0,ml=E2||A2,V2=9007199254740991,I2=/^(?:0|[1-9]\d*)$/;function Tf(e,t){var r=typeof e;return t=t??V2,!!t&&(r=="number"||r!="symbol"&&I2.test(e))&&e>-1&&e%1==0&&e<t}var M2=9007199254740991;function gc(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=M2}var $2="[object Arguments]",j2="[object Array]",k2="[object Boolean]",U2="[object Date]",L2="[object Error]",D2="[object Function]",N2="[object Map]",B2="[object Number]",F2="[object Object]",z2="[object RegExp]",G2="[object Set]",H2="[object String]",q2="[object WeakMap]",J2="[object ArrayBuffer]",W2="[object DataView]",Y2="[object Float32Array]",K2="[object Float64Array]",Q2="[object Int8Array]",X2="[object Int16Array]",Z2="[object Int32Array]",eM="[object Uint8Array]",tM="[object Uint8ClampedArray]",rM="[object Uint16Array]",nM="[object Uint32Array]",Re={};Re[Y2]=Re[K2]=Re[Q2]=Re[X2]=Re[Z2]=Re[eM]=Re[tM]=Re[rM]=Re[nM]=!0;Re[$2]=Re[j2]=Re[J2]=Re[k2]=Re[W2]=Re[U2]=Re[L2]=Re[D2]=Re[N2]=Re[B2]=Re[F2]=Re[z2]=Re[G2]=Re[H2]=Re[q2]=!1;function aM(e){return Cr(e)&&gc(e.length)&&!!Re[Mr(e)]}function oM(e){return function(t){return e(t)}}var Rf=typeof exports=="object"&&exports&&!exports.nodeType&&exports,ra=Rf&&typeof module=="object"&&module&&!module.nodeType&&module,sM=ra&&ra.exports===Rf,$i=sM&&Pm.process,sh=function(){try{var e=ra&&ra.require&&ra.require("util").types;return e||$i&&$i.binding&&$i.binding("util")}catch{}}(),ih=sh&&sh.isTypedArray,Af=ih?oM(ih):aM,iM=Object.prototype,lM=iM.hasOwnProperty;function cM(e,t){var r=$t(e),n=!r&&Cf(e),a=!r&&!n&&ml(e),o=!r&&!n&&!a&&Af(e),s=r||n||a||o,i=s?C2(e.length,String):[],l=i.length;for(var c in e)lM.call(e,c)&&!(s&&(c=="length"||a&&(c=="offset"||c=="parent")||o&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||Tf(c,l)))&&i.push(c);return i}var uM=Object.prototype;function dM(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||uM;return e===r}function hM(e,t){return function(r){return e(t(r))}}var pM=hM(Object.keys,Object),mM=Object.prototype,fM=mM.hasOwnProperty;function gM(e){if(!dM(e))return pM(e);var t=[];for(var r in Object(e))fM.call(e,r)&&r!="constructor"&&t.push(r);return t}function _f(e){return e!=null&&gc(e.length)&&!xf(e)}function yc(e){return _f(e)?cM(e):gM(e)}function lh(e){return b2(e,yc,w2)}var yM=1,bM=Object.prototype,vM=bM.hasOwnProperty;function SM(e,t,r,n,a,o){var s=r&yM,i=lh(e),l=i.length,c=lh(t),u=c.length;if(l!=u&&!s)return!1;for(var d=l;d--;){var h=i[d];if(!(s?h in t:vM.call(t,h)))return!1}var p=o.get(e),f=o.get(t);if(p&&f)return p==t&&f==e;var m=!0;o.set(e,t),o.set(t,e);for(var b=s;++d<l;){h=i[d];var x=e[h],_=t[h];if(n)var O=s?n(_,x,h,t,e,o):n(x,_,h,e,t,o);if(!(O===void 0?x===_||a(x,_,r,n,o):O)){m=!1;break}b||(b=h=="constructor")}if(m&&!b){var C=e.constructor,P=t.constructor;C!=P&&"constructor"in e&&"constructor"in t&&!(typeof C=="function"&&C instanceof C&&typeof P=="function"&&P instanceof P)&&(m=!1)}return o.delete(e),o.delete(t),m}var fl=kr(jt,"DataView"),gl=kr(jt,"Promise"),yl=kr(jt,"Set"),bl=kr(jt,"WeakMap"),ch="[object Map]",xM="[object Object]",uh="[object Promise]",dh="[object Set]",hh="[object WeakMap]",ph="[object DataView]",OM=jr(fl),wM=jr(ya),CM=jr(gl),PM=jr(yl),TM=jr(bl),rr=Mr;(fl&&rr(new fl(new ArrayBuffer(1)))!=ph||ya&&rr(new ya)!=ch||gl&&rr(gl.resolve())!=uh||yl&&rr(new yl)!=dh||bl&&rr(new bl)!=hh)&&(rr=function(e){var t=Mr(e),r=t==xM?e.constructor:void 0,n=r?jr(r):"";if(n)switch(n){case OM:return ph;case wM:return ch;case CM:return uh;case PM:return dh;case TM:return hh}return t});var RM=1,mh="[object Arguments]",fh="[object Array]",oo="[object Object]",AM=Object.prototype,gh=AM.hasOwnProperty;function _M(e,t,r,n,a,o){var s=$t(e),i=$t(t),l=s?fh:rr(e),c=i?fh:rr(t);l=l==mh?oo:l,c=c==mh?oo:c;var u=l==oo,d=c==oo,h=l==c;if(h&&ml(e)){if(!ml(t))return!1;s=!0,u=!1}if(h&&!u)return o||(o=new Bt),s||Af(e)?Of(e,t,r,n,a,o):g2(e,t,l,r,n,a,o);if(!(r&RM)){var p=u&&gh.call(e,"__wrapped__"),f=d&&gh.call(t,"__wrapped__");if(p||f){var m=p?e.value():e,b=f?t.value():t;return o||(o=new Bt),a(m,b,r,n,o)}}return h?(o||(o=new Bt),SM(e,t,r,n,a,o)):!1}function Ls(e,t,r,n,a){return e===t?!0:e==null||t==null||!Cr(e)&&!Cr(t)?e!==e&&t!==t:_M(e,t,r,n,Ls,a)}function EM(e,t){return Ls(e,t)}const Ef=({store:e})=>{const{t}=_e.useTranslation(),[r,n]=ee.useState(e.jogger.motionStream.rapidlyChangingMotionState.state.joint_limit_reached.limit_reached),a=ee.useRef(r);xn(()=>{const s=e.jogger.motionStream.rapidlyChangingMotionState.state.joint_limit_reached.limit_reached;EM(a.current,s)||(a.current=s,n(s))});const o=[];for(const[s,i]of r.entries())i&&o.push(s);return S.jsx(q.Typography,{color:"error",sx:{margin:"0.5rem 1rem",textAlign:"center",minHeight:"1.5rem",visibility:o.length?"visible":"hidden"},children:t("Jogging.JointLimitsReached.lb",{jointNumbers:o.map(s=>s+1).join(", ")})})},VM=q.styled(q.FormControl)(({theme:e})=>({"&.MuiFormControl-root":{".MuiSelect-select":{paddingTop:"20px",paddingLeft:"12px"},label:{pointerEvents:"none",fontSize:"16px"},".MuiInputLabel-root":{"&.Mui-focused":{color:e.palette.text.primary}}}}));function so({labelValue:e,...t}){return S.jsxs(VM,{fullWidth:!0,variant:"filled",children:[S.jsx(q.InputLabel,{id:t.labelId,children:e}),S.jsx(q.Select,{...t})]})}var yh=function(){try{var e=kr(Object,"defineProperty");return e({},"",{}),e}catch{}}();function IM(e,t,r){t=="__proto__"&&yh?yh(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function MM(e,t,r,n){for(var a=-1,o=e==null?0:e.length;++a<o;){var s=e[a];t(n,s,r(s),e)}return n}function $M(e){return function(t,r,n){for(var a=-1,o=Object(t),s=n(t),i=s.length;i--;){var l=s[++a];if(r(o[l],l,o)===!1)break}return t}}var jM=$M();function kM(e,t){return e&&jM(e,t,yc)}function UM(e,t){return function(r,n){if(r==null)return r;if(!_f(r))return e(r,n);for(var a=r.length,o=-1,s=Object(r);++o<a&&n(s[o],o,s)!==!1;);return r}}var LM=UM(kM);function DM(e,t,r,n){return LM(e,function(a,o,s){t(n,a,r(a),s)}),n}var NM=1,BM=2;function FM(e,t,r,n){var a=r.length,o=a;if(e==null)return!o;for(e=Object(e);a--;){var s=r[a];if(s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++a<o;){s=r[a];var i=s[0],l=e[i],c=s[1];if(s[2]){if(l===void 0&&!(i in e))return!1}else{var u=new Bt,d;if(!(d===void 0?Ls(c,l,NM|BM,n,u):d))return!1}}return!0}function Vf(e){return e===e&&!wr(e)}function zM(e){for(var t=yc(e),r=t.length;r--;){var n=t[r],a=e[n];t[r]=[n,a,Vf(a)]}return t}function If(e,t){return function(r){return r==null?!1:r[e]===t&&(t!==void 0||e in Object(r))}}function GM(e){var t=zM(e);return t.length==1&&t[0][2]?If(t[0][0],t[0][1]):function(r){return r===e||FM(r,e,t)}}var HM=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,qM=/^\w*$/;function bc(e,t){if($t(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||Ts(e)?!0:qM.test(e)||!HM.test(e)||t!=null&&e in Object(t)}var JM="Expected a function";function vc(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(JM);var r=function(){var n=arguments,a=t?t.apply(this,n):n[0],o=r.cache;if(o.has(a))return o.get(a);var s=e.apply(this,n);return r.cache=o.set(a,s)||o,s};return r.cache=new(vc.Cache||Kt),r}vc.Cache=Kt;var WM=500;function YM(e){var t=vc(e,function(n){return r.size===WM&&r.clear(),n}),r=t.cache;return t}var KM=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,QM=/\\(\\)?/g,XM=YM(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(KM,function(r,n,a,o){t.push(a?o.replace(QM,"$1"):n||r)}),t});function ZM(e,t){for(var r=-1,n=e==null?0:e.length,a=Array(n);++r<n;)a[r]=t(e[r],r,e);return a}var bh=lr?lr.prototype:void 0,vh=bh?bh.toString:void 0;function Mf(e){if(typeof e=="string")return e;if($t(e))return ZM(e,Mf)+"";if(Ts(e))return vh?vh.call(e):"";var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function $f(e){return e==null?"":Mf(e)}function jf(e,t){return $t(e)?e:bc(e,t)?[e]:XM($f(e))}function Ds(e){if(typeof e=="string"||Ts(e))return e;var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function kf(e,t){t=jf(t,e);for(var r=0,n=t.length;e!=null&&r<n;)e=e[Ds(t[r++])];return r&&r==n?e:void 0}function e5(e,t,r){var n=e==null?void 0:kf(e,t);return n===void 0?r:n}function t5(e,t){return e!=null&&t in Object(e)}function r5(e,t,r){t=jf(t,e);for(var n=-1,a=t.length,o=!1;++n<a;){var s=Ds(t[n]);if(!(o=e!=null&&r(e,s)))break;e=e[s]}return o||++n!=a?o:(a=e==null?0:e.length,!!a&&gc(a)&&Tf(s,a)&&($t(e)||Cf(e)))}function n5(e,t){return e!=null&&r5(e,t,t5)}var a5=1,o5=2;function s5(e,t){return bc(e)&&Vf(t)?If(Ds(e),t):function(r){var n=e5(r,e);return n===void 0&&n===t?n5(r,e):Ls(t,n,a5|o5)}}function i5(e){return e}function l5(e){return function(t){return t==null?void 0:t[e]}}function c5(e){return function(t){return kf(t,e)}}function u5(e){return bc(e)?l5(Ds(e)):c5(e)}function d5(e){return typeof e=="function"?e:e==null?i5:typeof e=="object"?$t(e)?s5(e[0],e[1]):GM(e):u5(e)}function h5(e,t){return function(r,n){var a=$t(r)?MM:DM,o={};return a(r,e,d5(n),o)}}var io=h5(function(e,t,r){IM(e,r,t)}),p5=0;function m5(e){var t=++p5;return $f(e)+t}const vl=[{id:"0.1",mm:.1,degrees:.05},{id:"1",mm:1,degrees:.5},{id:"5",mm:5,degrees:2.5},{id:"10",mm:10,degrees:5}],f5=[{id:"continuous"},...vl],g5=["coordsys","tool"];class Ns{constructor(t,r,n,a){var o,s;this.jogger=t,this.motionGroupSpec=r,this.coordSystems=n,this.tcps=a,this.selectedTabId="cartesian",this.activationState="inactive",this.activationError=null,this.activationCounter=0,this.locks=new Set,this.selectedCoordSystemId="world",this.selectedTcpId="",this.selectedOrientation="coordsys",this.selectedIncrementId="continuous",this.selectedCartesianMotionType="translate",this.incrementJogInProgress=null,this.translationVelocityMmPerSec=10,this.rotationVelocityDegPerSec=1,this.minTranslationVelocityMmPerSec=5,this.maxTranslationVelocityMmPerSec=250,this.minRotationVelocityDegPerSec=1,this.maxRotationVelocityDegPerSec=60,this.showCoordSystemSelect=!0,this.showTcpSelect=!0,this.showOrientationSelect=!0,this.showIncrementSelect=!0,this.showTabIcons=!1,this.showVelocitySliderLabel=!0,this.showVelocityLegend=!1,this.showJointsLegend=!1,this.disposers=[];for(const i of n)if(i.coordinate_system===""){i.coordinate_system="world";break}this.selectedCoordSystemId=((o=n[0])==null?void 0:o.coordinate_system)||"world",this.selectedTcpId=((s=a[0])==null?void 0:s.id)||"",Ne.makeAutoObservable(this,{},{autoBind:!0}),this.loadFromLocalStorage(),this.disposers.push(Ne.autorun(()=>this.saveToLocalStorage())),window.joggingStore=this}static async loadFor(t){const{nova:r}=t,[n,{coordinatesystems:a},{tcps:o}]=await Promise.all([r.api.motionGroupInfos.getMotionGroupSpecification(t.motionGroupId),r.api.coordinateSystems.listCoordinateSystems("ROTATION_VECTOR"),r.api.motionGroupInfos.listTcps(t.motionGroupId,"ROTATION_VECTOR")]);return new Ns(t,n,a||[],o||[])}dispose(){for(const t of this.disposers)t();this.jogger.dispose()}get coordSystemCountByName(){return Sl.countBy(this.coordSystems,t=>t.name)}async deactivate(){const t=this.jogger.activeWebsocket;this.jogger.setJoggingMode("increment"),t&&await t.closed()}async activate(){if(this.currentTab.id==="cartesian"){const t={tcpId:this.selectedTcpId,coordSystemId:this.activeCoordSystemId};this.activeDiscreteIncrement?this.jogger.setJoggingMode("increment",t):this.jogger.setJoggingMode("cartesian",t)}else this.jogger.setJoggingMode("joint");return this.jogger}loadFromLocalStorage(){const t=br.tryParseJson(localStorage.getItem("joggingToolStore"));t&&(this.tabsById[t.selectedTabId]&&(this.selectedTabId=t.selectedTabId),this.coordSystemsById[t.selectedCoordSystemId]&&(this.selectedCoordSystemId=t.selectedCoordSystemId),this.tcpsById[t.selectedTcpId]&&(this.selectedTcpId=t.selectedTcpId),this.incrementOptionsById[t.selectedIncrementId]&&(this.selectedIncrementId=t.selectedIncrementId),["translate","rotate"].includes(t.selectedCartesianMotionType)&&(this.selectedCartesianMotionType=t.selectedCartesianMotionType),["coordsys","tool"].includes(t.selectedOrientation)&&(this.selectedOrientation=t.selectedOrientation))}saveToLocalStorage(){localStorage.setItem("joggingToolStore",JSON.stringify(this.localStorageSave))}get isLocked(){return this.locks.size>0}get localStorageSave(){return{selectedTabId:this.selectedTabId,selectedCoordSystemId:this.selectedCoordSystemId,selectedTcpId:this.selectedTcpId,selectedOrientation:this.selectedOrientation,selectedIncrementId:this.selectedIncrementId,selectedCartesianMotionType:this.selectedCartesianMotionType}}get tabs(){return[{id:"cartesian",label:"cartesian"},{id:"joint",label:"joint"}]}get incrementOptions(){return f5}get discreteIncrementOptions(){return vl}get incrementOptionsById(){return io(this.incrementOptions,t=>t.id)}get tabsById(){return io(this.tabs,t=>t.id)}get currentTab(){return this.tabsById[this.selectedTabId]||this.tabs[0]}get tabIndex(){return this.tabs.indexOf(this.currentTab)}get coordSystemsById(){return io(this.coordSystems,t=>t.coordinate_system)}get selectedCoordSystem(){return this.coordSystemsById[this.selectedCoordSystemId]}get activeCoordSystemId(){return this.selectedOrientation==="tool"?"tool":this.selectedCoordSystemId}get tcpsById(){return io(this.tcps,t=>t.id)}get activeDiscreteIncrement(){return this.selectedOrientation==="tool"?void 0:vl.find(t=>t.id===this.selectedIncrementId)}get rotationVelocityRadsPerSec(){return this.rotationVelocityDegPerSec*Math.PI/180}get velocityInDisplayUnits(){return this.currentMotionType==="translate"?this.translationVelocityMmPerSec:this.rotationVelocityDegPerSec}get minVelocityInDisplayUnits(){return this.currentMotionType==="translate"?this.minTranslationVelocityMmPerSec:this.minRotationVelocityDegPerSec}get maxVelocityInDisplayUnits(){return this.currentMotionType==="translate"?this.maxTranslationVelocityMmPerSec:this.maxRotationVelocityDegPerSec}get currentMotionType(){return this.selectedTabId==="cartesian"&&this.selectedCartesianMotionType==="translate"?"translate":"rotate"}onTabChange(t,r){const n=this.tabs[r]||this.tabs[0];this.selectedTabId=n.id}setSelectedCoordSystemId(t){this.selectedCoordSystemId=t}setSelectedTcpId(t){this.selectedTcpId=t}setSelectedOrientation(t){this.selectedOrientation=t}setSelectedIncrementId(t){this.selectedIncrementId=t}setCurrentIncrementJog(t){this.incrementJogInProgress=t}setVelocityFromSlider(t){this.currentMotionType==="translate"?this.translationVelocityMmPerSec=t:this.rotationVelocityDegPerSec=t}setSelectedCartesianMotionType(t){this.selectedCartesianMotionType=t}lock(t){this.locks.add(t)}unlock(t){this.locks.delete(t)}async withMotionLock(t){const r=m5();this.lock(r);try{return await t()}finally{this.unlock(r)}}}const y5=Ee.observer(({store:e})=>{var a;const{t}=_e.useTranslation(),r=[];function n(o){switch(o){case"coordsys":return t("Jogging.Orientation.coordsys");case"tool":return t("Jogging.Orientation.tool");default:return o}}return e.showCoordSystemSelect&&r.push(S.jsx(so,{labelId:"jogging-coord-select",labelValue:t("Jogging.CoordinateSystem.hlb"),value:e.selectedCoordSystemId,size:"small",variant:"filled",displayEmpty:!0,onChange:o=>e.setSelectedCoordSystemId(o.target.value),disabled:e.isLocked,children:e.coordSystems.map(o=>S.jsx(q.MenuItem,{value:o.coordinate_system,children:o.name&&e.coordSystemCountByName[o.name]>1?`${o.name} / ${o.coordinate_system}`:o.name||o.coordinate_system},o.coordinate_system))},"coord")),e.showTcpSelect&&r.push(S.jsx(so,{labelId:"jogging-tcp-select",labelValue:"TCP",value:e.selectedTcpId,size:"small",variant:"filled",onChange:o=>e.setSelectedTcpId(o.target.value),disabled:e.isLocked,children:e.tcps.map(o=>S.jsx(q.MenuItem,{value:o.id,children:o.id},o.id))},"tcp")),e.showOrientationSelect&&r.push(S.jsx(so,{labelValue:t("Jogging.Cartesian.Orientation.lb"),id:"orientation-select",labelId:"orientation-select",value:e.selectedOrientation,onChange:o=>e.setSelectedOrientation(o.target.value),disabled:e.isLocked,children:g5.map(o=>S.jsx(q.MenuItem,{value:o,children:n(o)},o))},"orientation")),e.showIncrementSelect&&r.push(S.jsxs(so,{labelValue:t("Jogging.Increment.hlb"),labelId:"jogging-increment-select",size:"small",variant:"filled",value:((a=e.activeDiscreteIncrement)==null?void 0:a.id)||"continuous",onChange:o=>e.setSelectedIncrementId(o.target.value),disabled:e.isLocked,children:[S.jsx(q.MenuItem,{value:"continuous",children:t("Jogging.Increment.Continuous.dd")},"continuous"),e.selectedOrientation==="tool"?null:e.discreteIncrementOptions.map(o=>S.jsx(q.MenuItem,{value:o.id,children:e.currentMotionType==="translate"?`${o.mm}mm`:`${o.degrees}°`},o.id))]},"increment")),S.jsx(q.Box,{component:"div",sx:{display:"grid",gap:"16px",gridTemplateColumns:"1fr 1fr",gridAutoRows:"min-content","& label":{opacity:.7,fontSize:"12px",marginBottom:"4px"}},children:r.map((o,s)=>S.jsx(q.Box,{sx:{gridColumn:r.length%2===1&&s===r.length-1?"span 2":"auto"},children:o},s))})}),b5=q.styled(q.ToggleButtonGroup)(({theme:e})=>{var t;return{"&.MuiToggleButtonGroup-root":{background:(t=e.palette.backgroundPaperElevation)==null?void 0:t[8],borderRadius:"8px",padding:"4px",gap:"4px",button:{border:"none",borderRadius:"4px",flex:"1 1 0px",minWidth:0,"&.MuiToggleButtonGroup-firstButton":{borderRadius:"8px 4px 4px 8px"},"&.MuiToggleButtonGroup-lastButton":{borderRadius:"4px 8px 8px 4px"}}}}});function Sh(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...n){return e(...n)||t(...n)}}function v5(e){return typeof e=="string"}function S5(e,t,r){return e===void 0||v5(e)?t:{...t,ownerState:{...t.ownerState,...r}}}function xo(e,t=[]){if(e===void 0)return{};const r={};return Object.keys(e).filter(n=>n.match(/^on[A-Z]/)&&typeof e[n]=="function"&&!t.includes(n)).forEach(n=>{r[n]=e[n]}),r}function xh(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(r=>!(r.match(/^on[A-Z]/)&&typeof e[r]=="function")).forEach(r=>{t[r]=e[r]}),t}function x5(e){const{getSlotProps:t,additionalProps:r,externalSlotProps:n,externalForwardedProps:a,className:o}=e;if(!t){const p=It(r==null?void 0:r.className,o,a==null?void 0:a.className,n==null?void 0:n.className),f={...r==null?void 0:r.style,...a==null?void 0:a.style,...n==null?void 0:n.style},m={...r,...a,...n};return p.length>0&&(m.className=p),Object.keys(f).length>0&&(m.style=f),{props:m,internalRef:void 0}}const s=xo({...a,...n}),i=xh(n),l=xh(a),c=t(s),u=It(c==null?void 0:c.className,r==null?void 0:r.className,o,a==null?void 0:a.className,n==null?void 0:n.className),d={...c==null?void 0:c.style,...r==null?void 0:r.style,...a==null?void 0:a.style,...n==null?void 0:n.style},h={...c,...r,...l,...i};return u.length>0&&(h.className=u),Object.keys(d).length>0&&(h.style=d),{props:h,internalRef:c.ref}}function O5(e,t,r){return typeof e=="function"?e(t,r):e}function tr(e){var d;const{elementType:t,externalSlotProps:r,ownerState:n,skipResolvingSlotProps:a=!1,...o}=e,s=a?{}:O5(r,n),{props:i,internalRef:l}=x5({...o,externalSlotProps:s}),c=Cm(l,s==null?void 0:s.ref,(d=e.additionalProps)==null?void 0:d.ref);return S5(t,{...i,ref:c},n)}function Oh(e){try{return e.matches(":focus-visible")}catch{process.env.NODE_ENV!=="production"&&!/jsdom/.test(window.navigator.userAgent)&&console.warn(["MUI: The `:focus-visible` pseudo class is not supported in this browser.","Some components rely on this feature to work properly."].join(`
|
|
154
|
+
`))}return!1}const w5={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"};function C5(e,t,r=(n,a)=>n===a){return e.length===t.length&&e.every((n,a)=>r(n,t[a]))}const P5=2;function Xr(e,t,r,n,a){return r===1?Math.min(e+t,a):Math.max(e-t,n)}function Uf(e,t){return e-t}function wh(e,t){const{index:r}=e.reduce((n,a,o)=>{const s=Math.abs(t-a);return n===null||s<n.distance||s===n.distance?{distance:s,index:o}:n},null)??{};return r}function lo(e,t){if(t.current!==void 0&&e.changedTouches){const r=e;for(let n=0;n<r.changedTouches.length;n+=1){const a=r.changedTouches[n];if(a.identifier===t.current)return{x:a.clientX,y:a.clientY}}return!1}return{x:e.clientX,y:e.clientY}}function Yo(e,t,r){return(e-t)*100/(r-t)}function T5(e,t,r){return(r-t)*e+t}function R5(e){if(Math.abs(e)<1){const r=e.toExponential().split("e-"),n=r[0].split(".")[1];return(n?n.length:0)+parseInt(r[1],10)}const t=e.toString().split(".")[1];return t?t.length:0}function A5(e,t,r){const n=Math.round((e-r)/t)*t+r;return Number(n.toFixed(R5(t)))}function Ch({values:e,newValue:t,index:r}){const n=e.slice();return n[r]=t,n.sort(Uf)}function co({sliderRef:e,activeIndex:t,setActive:r}){var a,o,s;const n=yo(e.current);(!((a=e.current)!=null&&a.contains(n.activeElement))||Number((o=n==null?void 0:n.activeElement)==null?void 0:o.getAttribute("data-index"))!==t)&&((s=e.current)==null||s.querySelector(`[type="range"][data-index="${t}"]`).focus()),r&&r(t)}function uo(e,t){return typeof e=="number"&&typeof t=="number"?e===t:typeof e=="object"&&typeof t=="object"?C5(e,t):!1}const _5={horizontal:{offset:e=>({left:`${e}%`}),leap:e=>({width:`${e}%`})},"horizontal-reverse":{offset:e=>({right:`${e}%`}),leap:e=>({width:`${e}%`})},vertical:{offset:e=>({bottom:`${e}%`}),leap:e=>({height:`${e}%`})}},E5=e=>e;let ho;function Ph(){return ho===void 0&&(typeof CSS<"u"&&typeof CSS.supports=="function"?ho=CSS.supports("touch-action","none"):ho=!0),ho}function V5(e){const{"aria-labelledby":t,defaultValue:r,disabled:n=!1,disableSwap:a=!1,isRtl:o=!1,marks:s=!1,max:i=100,min:l=0,name:c,onChange:u,onChangeCommitted:d,orientation:h="horizontal",rootRef:p,scale:f=E5,step:m=1,shiftStep:b=10,tabIndex:x,value:_}=e,O=V.useRef(void 0),[C,P]=V.useState(-1),[w,R]=V.useState(-1),[I,F]=V.useState(!1),y=V.useRef(0),T=V.useRef(null),[z,E]=Kw({controlled:_,default:r??l,name:"Slider"}),B=u&&((K,ne,se)=>{const fe=K.nativeEvent||K,Oe=new fe.constructor(fe.type,fe);Object.defineProperty(Oe,"target",{writable:!0,value:{value:ne,name:c}}),T.current=ne,u(Oe,ne,se)}),te=Array.isArray(z);let Z=te?z.slice().sort(Uf):[z];Z=Z.map(K=>K==null?l:Zr(K,l,i));const ae=s===!0&&m!==null?[...Array(Math.floor((i-l)/m)+1)].map((K,ne)=>({value:l+m*ne})):s||[],re=ae.map(K=>K.value),[le,J]=V.useState(-1),X=V.useRef(null),he=Cm(p,X),Pe=K=>ne=>{var fe;const se=Number(ne.currentTarget.getAttribute("data-index"));Oh(ne.target)&&J(se),R(se),(fe=K==null?void 0:K.onFocus)==null||fe.call(K,ne)},ze=K=>ne=>{var se;Oh(ne.target)||J(-1),R(-1),(se=K==null?void 0:K.onBlur)==null||se.call(K,ne)},xe=(K,ne)=>{const se=Number(K.currentTarget.getAttribute("data-index")),fe=Z[se],Oe=re.indexOf(fe);let ie=ne;if(ae&&m==null){const He=re[re.length-1];ie>=He?ie=He:ie<=re[0]?ie=re[0]:ie=ie<fe?re[Oe-1]:re[Oe+1]}if(ie=Zr(ie,l,i),te){a&&(ie=Zr(ie,Z[se-1]||-1/0,Z[se+1]||1/0));const He=ie;ie=Ch({values:Z,newValue:ie,index:se});let Xe=se;a||(Xe=ie.indexOf(He)),co({sliderRef:X,activeIndex:Xe})}E(ie),J(se),B&&!uo(ie,z)&&B(K,ie,se),d&&d(K,T.current??ie)},it=K=>ne=>{var se;if(["ArrowUp","ArrowDown","ArrowLeft","ArrowRight","PageUp","PageDown","Home","End"].includes(ne.key)){ne.preventDefault();const fe=Number(ne.currentTarget.getAttribute("data-index")),Oe=Z[fe];let ie=null;if(m!=null){const He=ne.shiftKey?b:m;switch(ne.key){case"ArrowUp":ie=Xr(Oe,He,1,l,i);break;case"ArrowRight":ie=Xr(Oe,He,o?-1:1,l,i);break;case"ArrowDown":ie=Xr(Oe,He,-1,l,i);break;case"ArrowLeft":ie=Xr(Oe,He,o?1:-1,l,i);break;case"PageUp":ie=Xr(Oe,b,1,l,i);break;case"PageDown":ie=Xr(Oe,b,-1,l,i);break;case"Home":ie=l;break;case"End":ie=i;break}}else if(ae){const He=re[re.length-1],Xe=re.indexOf(Oe),De=[o?"ArrowRight":"ArrowLeft","ArrowDown","PageDown","Home"],ht=[o?"ArrowLeft":"ArrowRight","ArrowUp","PageUp","End"];De.includes(ne.key)?Xe===0?ie=re[0]:ie=re[Xe-1]:ht.includes(ne.key)&&(Xe===re.length-1?ie=He:ie=re[Xe+1])}ie!=null&&xe(ne,ie)}(se=K==null?void 0:K.onKeyDown)==null||se.call(K,ne)};Gh(()=>{var K;n&&X.current.contains(document.activeElement)&&((K=document.activeElement)==null||K.blur())},[n]),n&&C!==-1&&P(-1),n&&le!==-1&&J(-1);const tt=K=>ne=>{var se;(se=K.onChange)==null||se.call(K,ne),xe(ne,ne.target.valueAsNumber)},ye=V.useRef(void 0);let Q=h;o&&h==="horizontal"&&(Q+="-reverse");const oe=({finger:K,move:ne=!1})=>{const{current:se}=X,{width:fe,height:Oe,bottom:ie,left:He}=se.getBoundingClientRect();let Xe;Q.startsWith("vertical")?Xe=(ie-K.y)/Oe:Xe=(K.x-He)/fe,Q.includes("-reverse")&&(Xe=1-Xe);let De;if(De=T5(Xe,l,i),m)De=A5(De,m,l);else{const _n=wh(re,De);De=re[_n]}De=Zr(De,l,i);let ht=0;if(te){ne?ht=ye.current:ht=wh(Z,De),a&&(De=Zr(De,Z[ht-1]||-1/0,Z[ht+1]||1/0));const _n=De;De=Ch({values:Z,newValue:De,index:ht}),a&&ne||(ht=De.indexOf(_n),ye.current=ht)}return{newValue:De,activeIndex:ht}},ce=bi(K=>{const ne=lo(K,O);if(!ne)return;if(y.current+=1,K.type==="mousemove"&&K.buttons===0){W(K);return}const{newValue:se,activeIndex:fe}=oe({finger:ne,move:!0});co({sliderRef:X,activeIndex:fe,setActive:P}),E(se),!I&&y.current>P5&&F(!0),B&&!uo(se,z)&&B(K,se,fe)}),W=bi(K=>{const ne=lo(K,O);if(F(!1),!ne)return;const{newValue:se}=oe({finger:ne,move:!0});P(-1),K.type==="touchend"&&R(-1),d&&d(K,T.current??se),O.current=void 0,me()}),be=bi(K=>{if(n)return;Ph()||K.preventDefault();const ne=K.changedTouches[0];ne!=null&&(O.current=ne.identifier);const se=lo(K,O);if(se!==!1){const{newValue:Oe,activeIndex:ie}=oe({finger:se});co({sliderRef:X,activeIndex:ie,setActive:P}),E(Oe),B&&!uo(Oe,z)&&B(K,Oe,ie)}y.current=0;const fe=yo(X.current);fe.addEventListener("touchmove",ce,{passive:!0}),fe.addEventListener("touchend",W,{passive:!0})}),me=V.useCallback(()=>{const K=yo(X.current);K.removeEventListener("mousemove",ce),K.removeEventListener("mouseup",W),K.removeEventListener("touchmove",ce),K.removeEventListener("touchend",W)},[W,ce]);V.useEffect(()=>{const{current:K}=X;return K.addEventListener("touchstart",be,{passive:Ph()}),()=>{K.removeEventListener("touchstart",be),me()}},[me,be]),V.useEffect(()=>{n&&me()},[n,me]);const Je=K=>ne=>{var Oe;if((Oe=K.onMouseDown)==null||Oe.call(K,ne),n||ne.defaultPrevented||ne.button!==0)return;ne.preventDefault();const se=lo(ne,O);if(se!==!1){const{newValue:ie,activeIndex:He}=oe({finger:se});co({sliderRef:X,activeIndex:He,setActive:P}),E(ie),B&&!uo(ie,z)&&B(ne,ie,He)}y.current=0;const fe=yo(X.current);fe.addEventListener("mousemove",ce,{passive:!0}),fe.addEventListener("mouseup",W)},Ge=Yo(te?Z[0]:l,l,i),Me=Yo(Z[Z.length-1],l,i)-Ge,Qt=(K={})=>{const ne=xo(K),se={onMouseDown:Je(ne||{})},fe={...ne,...se};return{...K,ref:he,...fe}},Ia=K=>ne=>{var fe;(fe=K.onMouseOver)==null||fe.call(K,ne);const se=Number(ne.currentTarget.getAttribute("data-index"));R(se)},Ma=K=>ne=>{var se;(se=K.onMouseLeave)==null||se.call(K,ne),R(-1)},$a=(K={})=>{const ne=xo(K),se={onMouseOver:Ia(ne||{}),onMouseLeave:Ma(ne||{})};return{...K,...ne,...se}},ja=K=>({pointerEvents:C!==-1&&C!==K?"none":void 0});let Ur;return h==="vertical"&&(Ur=o?"vertical-rl":"vertical-lr"),{active:C,axis:Q,axisProps:_5,dragging:I,focusedThumbIndex:le,getHiddenInputProps:(K={})=>{const ne=xo(K),se={onChange:tt(ne||{}),onFocus:Pe(ne||{}),onBlur:ze(ne||{}),onKeyDown:it(ne||{})},fe={...ne,...se};return{tabIndex:x,"aria-labelledby":t,"aria-orientation":h,"aria-valuemax":f(i),"aria-valuemin":f(l),name:c,type:"range",min:e.min,max:e.max,step:e.step===null&&e.marks?"any":e.step??void 0,disabled:n,...K,...fe,style:{...w5,direction:o?"rtl":"ltr",width:"100%",height:"100%",writingMode:Ur}}},getRootProps:Qt,getThumbProps:$a,marks:ae,open:w,range:te,rootRef:he,trackLeap:Me,trackOffset:Ge,values:Z,getThumbStyle:ja}}function Oo(e){return typeof e=="string"}const I5=e=>!e||!Oo(e);function M5(e){return typeof e.main=="string"}function $5(e,t=[]){if(!M5(e))return!1;for(const r of t)if(!e.hasOwnProperty(r)||typeof e[r]!="string")return!1;return!0}function Sc(e=[]){return([,t])=>t&&$5(t,e)}function j5(e){return xa("MuiSlider",e)}const gt=Uh("MuiSlider",["root","active","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","disabled","dragging","focusVisible","mark","markActive","marked","markLabel","markLabelActive","rail","sizeSmall","thumb","thumbColorPrimary","thumbColorSecondary","thumbColorError","thumbColorSuccess","thumbColorInfo","thumbColorWarning","track","trackInverted","trackFalse","thumbSizeSmall","valueLabel","valueLabelOpen","valueLabelCircle","valueLabelLabel","vertical"]),k5=e=>{const{open:t}=e;return{offset:It(t&>.valueLabelOpen),circle:gt.valueLabelCircle,label:gt.valueLabelLabel}};function Lf(e){const{children:t,className:r,value:n}=e,a=k5(e);return t?V.cloneElement(t,{className:t.props.className},S.jsxs(V.Fragment,{children:[t.props.children,S.jsx("span",{className:It(a.offset,r),"aria-hidden":!0,children:S.jsx("span",{className:a.circle,children:S.jsx("span",{className:a.label,children:n})})})]})):null}process.env.NODE_ENV!=="production"&&(Lf.propTypes={children:g.element.isRequired,className:g.string,value:g.node});function Th(e){return e}const U5=dt("span",{name:"MuiSlider",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,t[`color${Ze(r.color)}`],r.size!=="medium"&&t[`size${Ze(r.size)}`],r.marked&&t.marked,r.orientation==="vertical"&&t.vertical,r.track==="inverted"&&t.trackInverted,r.track===!1&&t.trackFalse]}})(Ir(({theme:e})=>({borderRadius:12,boxSizing:"content-box",display:"inline-block",position:"relative",cursor:"pointer",touchAction:"none",WebkitTapHighlightColor:"transparent","@media print":{colorAdjust:"exact"},[`&.${gt.disabled}`]:{pointerEvents:"none",cursor:"default",color:(e.vars||e).palette.grey[400]},[`&.${gt.dragging}`]:{[`& .${gt.thumb}, & .${gt.track}`]:{transition:"none"}},variants:[...Object.entries(e.palette).filter(Sc()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}})),{props:{orientation:"horizontal"},style:{height:4,width:"100%",padding:"13px 0","@media (pointer: coarse)":{padding:"20px 0"}}},{props:{orientation:"horizontal",size:"small"},style:{height:2}},{props:{orientation:"horizontal",marked:!0},style:{marginBottom:20}},{props:{orientation:"vertical"},style:{height:"100%",width:4,padding:"0 13px","@media (pointer: coarse)":{padding:"0 20px"}}},{props:{orientation:"vertical",size:"small"},style:{width:2}},{props:{orientation:"vertical",marked:!0},style:{marginRight:44}}]}))),L5=dt("span",{name:"MuiSlider",slot:"Rail"})({display:"block",position:"absolute",borderRadius:"inherit",backgroundColor:"currentColor",opacity:.38,variants:[{props:{orientation:"horizontal"},style:{width:"100%",height:"inherit",top:"50%",transform:"translateY(-50%)"}},{props:{orientation:"vertical"},style:{height:"100%",width:"inherit",left:"50%",transform:"translateX(-50%)"}},{props:{track:"inverted"},style:{opacity:1}}]}),D5=dt("span",{name:"MuiSlider",slot:"Track"})(Ir(({theme:e})=>({display:"block",position:"absolute",borderRadius:"inherit",border:"1px solid currentColor",backgroundColor:"currentColor",transition:e.transitions.create(["left","width","bottom","height"],{duration:e.transitions.duration.shortest}),variants:[{props:{size:"small"},style:{border:"none"}},{props:{orientation:"horizontal"},style:{height:"inherit",top:"50%",transform:"translateY(-50%)"}},{props:{orientation:"vertical"},style:{width:"inherit",left:"50%",transform:"translateX(-50%)"}},{props:{track:!1},style:{display:"none"}},...Object.entries(e.palette).filter(Sc()).map(([t])=>({props:{color:t,track:"inverted"},style:{...e.vars?{backgroundColor:e.vars.palette.Slider[`${t}Track`],borderColor:e.vars.palette.Slider[`${t}Track`]}:{backgroundColor:aa(e.palette[t].main,.62),borderColor:aa(e.palette[t].main,.62),...e.applyStyles("dark",{backgroundColor:na(e.palette[t].main,.5)}),...e.applyStyles("dark",{borderColor:na(e.palette[t].main,.5)})}}}))]}))),N5=dt("span",{name:"MuiSlider",slot:"Thumb",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.thumb,t[`thumbColor${Ze(r.color)}`],r.size!=="medium"&&t[`thumbSize${Ze(r.size)}`]]}})(Ir(({theme:e})=>({position:"absolute",width:20,height:20,boxSizing:"border-box",borderRadius:"50%",outline:0,backgroundColor:"currentColor",display:"flex",alignItems:"center",justifyContent:"center",transition:e.transitions.create(["box-shadow","left","bottom"],{duration:e.transitions.duration.shortest}),"&::before":{position:"absolute",content:'""',borderRadius:"inherit",width:"100%",height:"100%",boxShadow:(e.vars||e).shadows[2]},"&::after":{position:"absolute",content:'""',borderRadius:"50%",width:42,height:42,top:"50%",left:"50%",transform:"translate(-50%, -50%)"},[`&.${gt.disabled}`]:{"&:hover":{boxShadow:"none"}},variants:[{props:{size:"small"},style:{width:12,height:12,"&::before":{boxShadow:"none"}}},{props:{orientation:"horizontal"},style:{top:"50%",transform:"translate(-50%, -50%)"}},{props:{orientation:"vertical"},style:{left:"50%",transform:"translate(-50%, 50%)"}},...Object.entries(e.palette).filter(Sc()).map(([t])=>({props:{color:t},style:{[`&:hover, &.${gt.focusVisible}`]:{...e.vars?{boxShadow:`0px 0px 0px 8px rgba(${e.vars.palette[t].mainChannel} / 0.16)`}:{boxShadow:`0px 0px 0px 8px ${Ui(e.palette[t].main,.16)}`},"@media (hover: none)":{boxShadow:"none"}},[`&.${gt.active}`]:{...e.vars?{boxShadow:`0px 0px 0px 14px rgba(${e.vars.palette[t].mainChannel} / 0.16)`}:{boxShadow:`0px 0px 0px 14px ${Ui(e.palette[t].main,.16)}`}}}}))]}))),Df=dt(Lf,{name:"MuiSlider",slot:"ValueLabel"})(Ir(({theme:e})=>({zIndex:1,whiteSpace:"nowrap",...e.typography.body2,fontWeight:500,transition:e.transitions.create(["transform"],{duration:e.transitions.duration.shortest}),position:"absolute",backgroundColor:(e.vars||e).palette.grey[600],borderRadius:2,color:(e.vars||e).palette.common.white,display:"flex",alignItems:"center",justifyContent:"center",padding:"0.25rem 0.75rem",variants:[{props:{orientation:"horizontal"},style:{transform:"translateY(-100%) scale(0)",top:"-10px",transformOrigin:"bottom center","&::before":{position:"absolute",content:'""',width:8,height:8,transform:"translate(-50%, 50%) rotate(45deg)",backgroundColor:"inherit",bottom:0,left:"50%"},[`&.${gt.valueLabelOpen}`]:{transform:"translateY(-100%) scale(1)"}}},{props:{orientation:"vertical"},style:{transform:"translateY(-50%) scale(0)",right:"30px",top:"50%",transformOrigin:"right center","&::before":{position:"absolute",content:'""',width:8,height:8,transform:"translate(-50%, -50%) rotate(45deg)",backgroundColor:"inherit",right:-8,top:"50%"},[`&.${gt.valueLabelOpen}`]:{transform:"translateY(-50%) scale(1)"}}},{props:{size:"small"},style:{fontSize:e.typography.pxToRem(12),padding:"0.25rem 0.5rem"}},{props:{orientation:"vertical",size:"small"},style:{right:"20px"}}]})));process.env.NODE_ENV!=="production"&&(Df.propTypes={children:g.element.isRequired,index:g.number.isRequired,open:g.bool.isRequired,value:g.node});const B5=dt("span",{name:"MuiSlider",slot:"Mark",shouldForwardProp:e=>Pl(e)&&e!=="markActive",overridesResolver:(e,t)=>{const{markActive:r}=e;return[t.mark,r&&t.markActive]}})(Ir(({theme:e})=>({position:"absolute",width:2,height:2,borderRadius:1,backgroundColor:"currentColor",variants:[{props:{orientation:"horizontal"},style:{top:"50%",transform:"translate(-1px, -50%)"}},{props:{orientation:"vertical"},style:{left:"50%",transform:"translate(-50%, 1px)"}},{props:{markActive:!0},style:{backgroundColor:(e.vars||e).palette.background.paper,opacity:.8}}]}))),F5=dt("span",{name:"MuiSlider",slot:"MarkLabel",shouldForwardProp:e=>Pl(e)&&e!=="markLabelActive"})(Ir(({theme:e})=>({...e.typography.body2,color:(e.vars||e).palette.text.secondary,position:"absolute",whiteSpace:"nowrap",variants:[{props:{orientation:"horizontal"},style:{top:30,transform:"translateX(-50%)","@media (pointer: coarse)":{top:40}}},{props:{orientation:"vertical"},style:{left:36,transform:"translateY(50%)","@media (pointer: coarse)":{left:44}}},{props:{markLabelActive:!0},style:{color:(e.vars||e).palette.text.primary}}]}))),z5=e=>{const{disabled:t,dragging:r,marked:n,orientation:a,track:o,classes:s,color:i,size:l}=e,c={root:["root",t&&"disabled",r&&"dragging",n&&"marked",a==="vertical"&&"vertical",o==="inverted"&&"trackInverted",o===!1&&"trackFalse",i&&`color${Ze(i)}`,l&&`size${Ze(l)}`],rail:["rail"],track:["track"],mark:["mark"],markActive:["markActive"],markLabel:["markLabel"],markLabelActive:["markLabelActive"],valueLabel:["valueLabel"],thumb:["thumb",t&&"disabled",l&&`thumbSize${Ze(l)}`,i&&`thumbColor${Ze(i)}`],active:["active"],disabled:["disabled"],focusVisible:["focusVisible"]};return wl(c,j5,s)},G5=({children:e})=>e,Nf=V.forwardRef(function(t,r){const n=dc({props:t,name:"MuiSlider"}),a=e0(),{"aria-label":o,"aria-valuetext":s,"aria-labelledby":i,component:l="span",components:c={},componentsProps:u={},color:d="primary",classes:h,className:p,disableSwap:f=!1,disabled:m=!1,getAriaLabel:b,getAriaValueText:x,marks:_=!1,max:O=100,min:C=0,name:P,onChange:w,onChangeCommitted:R,orientation:I="horizontal",shiftStep:F=10,size:y="medium",step:T=1,scale:z=Th,slotProps:E,slots:B,tabIndex:te,track:Z="normal",value:ae,valueLabelDisplay:re="off",valueLabelFormat:le=Th,...J}=n,X={...n,isRtl:a,max:O,min:C,classes:h,disabled:m,disableSwap:f,orientation:I,marks:_,color:d,size:y,step:T,shiftStep:F,scale:z,track:Z,valueLabelDisplay:re,valueLabelFormat:le},{axisProps:he,getRootProps:Pe,getHiddenInputProps:ze,getThumbProps:xe,open:it,active:tt,axis:ye,focusedThumbIndex:Q,range:oe,dragging:ce,marks:W,values:be,trackOffset:me,trackLeap:Je,getThumbStyle:Ge}=V5({...X,rootRef:r});X.marked=W.length>0&&W.some(Le=>Le.label),X.dragging=ce,X.focusedThumbIndex=Q;const Me=z5(X),Qt=(B==null?void 0:B.root)??c.Root??U5,Ia=(B==null?void 0:B.rail)??c.Rail??L5,Ma=(B==null?void 0:B.track)??c.Track??D5,$a=(B==null?void 0:B.thumb)??c.Thumb??N5,ja=(B==null?void 0:B.valueLabel)??c.ValueLabel??Df,Ur=(B==null?void 0:B.mark)??c.Mark??B5,ka=(B==null?void 0:B.markLabel)??c.MarkLabel??F5,K=(B==null?void 0:B.input)??c.Input??"input",ne=(E==null?void 0:E.root)??u.root,se=(E==null?void 0:E.rail)??u.rail,fe=(E==null?void 0:E.track)??u.track,Oe=(E==null?void 0:E.thumb)??u.thumb,ie=(E==null?void 0:E.valueLabel)??u.valueLabel,He=(E==null?void 0:E.mark)??u.mark,Xe=(E==null?void 0:E.markLabel)??u.markLabel,De=(E==null?void 0:E.input)??u.input,ht=tr({elementType:Qt,getSlotProps:Pe,externalSlotProps:ne,externalForwardedProps:J,additionalProps:{...I5(Qt)&&{as:l}},ownerState:{...X,...ne==null?void 0:ne.ownerState},className:[Me.root,p]}),_n=tr({elementType:Ia,externalSlotProps:se,ownerState:X,className:Me.rail}),Kf=tr({elementType:Ma,externalSlotProps:fe,additionalProps:{style:{...he[ye].offset(me),...he[ye].leap(Je)}},ownerState:{...X,...fe==null?void 0:fe.ownerState},className:Me.track}),Bs=tr({elementType:$a,getSlotProps:xe,externalSlotProps:Oe,ownerState:{...X,...Oe==null?void 0:Oe.ownerState},className:Me.thumb}),Qf=tr({elementType:ja,externalSlotProps:ie,ownerState:{...X,...ie==null?void 0:ie.ownerState},className:Me.valueLabel}),Fs=tr({elementType:Ur,externalSlotProps:He,ownerState:X,className:Me.mark}),zs=tr({elementType:ka,externalSlotProps:Xe,ownerState:X,className:Me.markLabel}),Xf=tr({elementType:K,getSlotProps:ze,externalSlotProps:De,ownerState:X});return S.jsxs(Qt,{...ht,children:[S.jsx(Ia,{..._n}),S.jsx(Ma,{...Kf}),W.filter(Le=>Le.value>=C&&Le.value<=O).map((Le,We)=>{const Gs=Yo(Le.value,C,O),Ua=he[ye].offset(Gs);let kt;return Z===!1?kt=be.includes(Le.value):kt=Z==="normal"&&(oe?Le.value>=be[0]&&Le.value<=be[be.length-1]:Le.value<=be[0])||Z==="inverted"&&(oe?Le.value<=be[0]||Le.value>=be[be.length-1]:Le.value>=be[0]),S.jsxs(V.Fragment,{children:[S.jsx(Ur,{"data-index":We,...Fs,...!Oo(Ur)&&{markActive:kt},style:{...Ua,...Fs.style},className:It(Fs.className,kt&&Me.markActive)}),Le.label!=null?S.jsx(ka,{"aria-hidden":!0,"data-index":We,...zs,...!Oo(ka)&&{markLabelActive:kt},style:{...Ua,...zs.style},className:It(Me.markLabel,zs.className,kt&&Me.markLabelActive),children:Le.label}):null]},We)}),be.map((Le,We)=>{const Gs=Yo(Le,C,O),Ua=he[ye].offset(Gs),kt=re==="off"?G5:ja;return S.jsx(kt,{...!Oo(kt)&&{valueLabelFormat:le,valueLabelDisplay:re,value:typeof le=="function"?le(z(Le),We):le,index:We,open:it===We||tt===We||re==="on",disabled:m},...Qf,children:S.jsx($a,{"data-index":We,...Bs,className:It(Me.thumb,Bs.className,tt===We&&Me.active,Q===We&&Me.focusVisible),style:{...Ua,...Ge(We),...Bs.style},children:S.jsx(K,{"data-index":We,"aria-label":b?b(We):o,"aria-valuenow":z(Le),"aria-labelledby":i,"aria-valuetext":x?x(z(Le),We):s,value:be[We],...Xf})})},We)})]})});process.env.NODE_ENV!=="production"&&(Nf.propTypes={"aria-label":Sh(g.string,e=>Array.isArray(e.value||e.defaultValue)&&e["aria-label"]!=null?new Error("MUI: You need to use the `getAriaLabel` prop instead of `aria-label` when using a range slider."):null),"aria-labelledby":g.string,"aria-valuetext":Sh(g.string,e=>Array.isArray(e.value||e.defaultValue)&&e["aria-valuetext"]!=null?new Error("MUI: You need to use the `getAriaValueText` prop instead of `aria-valuetext` when using a range slider."):null),children:g.node,classes:g.object,className:g.string,color:g.oneOfType([g.oneOf(["primary","secondary","error","info","success","warning"]),g.string]),components:g.shape({Input:g.elementType,Mark:g.elementType,MarkLabel:g.elementType,Rail:g.elementType,Root:g.elementType,Thumb:g.elementType,Track:g.elementType,ValueLabel:g.elementType}),componentsProps:g.shape({input:g.oneOfType([g.func,g.object]),mark:g.oneOfType([g.func,g.object]),markLabel:g.oneOfType([g.func,g.object]),rail:g.oneOfType([g.func,g.object]),root:g.oneOfType([g.func,g.object]),thumb:g.oneOfType([g.func,g.object]),track:g.oneOfType([g.func,g.object]),valueLabel:g.oneOfType([g.func,g.shape({children:g.element,className:g.string,open:g.bool,style:g.object,value:g.node,valueLabelDisplay:g.oneOf(["auto","off","on"])})])}),defaultValue:g.oneOfType([g.arrayOf(g.number),g.number]),disabled:g.bool,disableSwap:g.bool,getAriaLabel:g.func,getAriaValueText:g.func,marks:g.oneOfType([g.arrayOf(g.shape({label:g.node,value:g.number.isRequired})),g.bool]),max:g.number,min:g.number,name:g.string,onChange:g.func,onChangeCommitted:g.func,orientation:g.oneOf(["horizontal","vertical"]),scale:g.func,shiftStep:g.number,size:g.oneOfType([g.oneOf(["small","medium"]),g.string]),slotProps:g.shape({input:g.oneOfType([g.func,g.object]),mark:g.oneOfType([g.func,g.object]),markLabel:g.oneOfType([g.func,g.object]),rail:g.oneOfType([g.func,g.object]),root:g.oneOfType([g.func,g.object]),thumb:g.oneOfType([g.func,g.object]),track:g.oneOfType([g.func,g.object]),valueLabel:g.oneOfType([g.func,g.shape({children:g.element,className:g.string,open:g.bool,style:g.object,value:g.node,valueLabelDisplay:g.oneOf(["auto","off","on"])})])}),slots:g.shape({input:g.elementType,mark:g.elementType,markLabel:g.elementType,rail:g.elementType,root:g.elementType,thumb:g.elementType,track:g.elementType,valueLabel:g.elementType}),step:g.number,sx:g.oneOfType([g.arrayOf(g.oneOfType([g.func,g.object,g.bool])),g.func,g.object]),tabIndex:g.number,track:g.oneOf(["inverted","normal",!1]),value:g.oneOfType([g.arrayOf(g.number),g.number]),valueLabelDisplay:g.oneOf(["auto","off","on"]),valueLabelFormat:g.oneOfType([g.func,g.string])});var H5="[object Number]";function q5(e){return typeof e=="number"||Cr(e)&&Mr(e)==H5}const Bf=Ee.observer(e=>{var o,s,i;const t=q.useTheme(),{store:r}=e,{t:n}=_e.useTranslation();function a(l,c){c===e.velocity||!q5(c)||e.onVelocityChange(c)}return S.jsxs(q.Stack,{direction:"row",gap:2,alignItems:"center",children:[r.showVelocityLegend&&S.jsx(q.Typography,{sx:{color:(i=(s=(o=t.componentsExt)==null?void 0:o.JoggingPanel)==null?void 0:s.VelocitySlider)==null?void 0:i.sliderLegendColor,fontSize:"14px"},children:n("Jogging.Velocity.bt")}),S.jsx(Nf,{value:e.velocity,color:"secondary",onChange:a,min:e.min,max:e.max,"aria-labelledby":"input-slider",disabled:e.disabled,sx:{"& .MuiSlider-valueLabelOpen":{zIndex:100,backgroundColor:"transparent",top:"0px"}}}),r.showVelocitySliderLabel&&(e.renderValue?e.renderValue(e.velocity):S.jsx(xc,{value:e.velocity.toString()}))]})});function xc({value:e,sx:t}){var n;const r=q.useTheme();return S.jsx(q.Stack,{direction:"row",justifyContent:"center",alignItems:"center",gap:"5px",sx:{padding:"6px 12px",background:(n=r.palette.backgroundPaperElevation)==null?void 0:n[8],borderRadius:"10px",minWidth:"111px",...t},children:S.jsx(q.Typography,{component:"span",sx:{textAlign:"right",fontSize:"14px",opacity:.8,color:r.palette.text.primary,whiteSpace:"nowrap"},children:e})})}const Ff=Ee.observer(({store:e})=>{const{t}=_e.useTranslation(),r=Ee.useLocalObservable(()=>({get valueLabelFormat(){return e.currentMotionType==="translate"?n=>`v = ${t("Jogging.Cartesian.Translation.velocityMmPerSec.lb",{amount:n})}`:n=>`ω = ${t("Jogging.Cartesian.Rotation.velocityDegPerSec.lb",{amount:n})}`}}));return S.jsx(Bf,{store:e,velocity:e.velocityInDisplayUnits,min:e.minVelocityInDisplayUnits,max:e.maxVelocityInDisplayUnits,onVelocityChange:e.setVelocityFromSlider,disabled:e.isLocked,renderValue:n=>S.jsx(xc,{value:r.valueLabelFormat(n),sx:{minWidth:"111px",span:{transform:"translateY(-1.5px)"}}})})}),J5=Ee.observer(({store:e,children:t})=>{const{t:r}=_e.useTranslation(),n=q.useTheme();function a(h,p){(p==="translate"||p==="rotate")&&e.setSelectedCartesianMotionType(p)}wm(()=>[e.selectedCoordSystemId,e.selectedTcpId],()=>{e.jogger.motionStream.motionStateSocket.changeUrl(e.jogger.nova.makeWebsocketURL(`/motion-groups/${e.jogger.motionGroupId}/state-stream?tcp=${e.selectedTcpId}&response_coordinate_system=${e.selectedCoordSystemId}`))},{fireImmediately:!0});async function o(h,p){const f=await e.activate(),m=f.motionStream.rapidlyChangingMotionState.tcp_pose,b=f.motionStream.rapidlyChangingMotionState.state.joint_position;m&&await e.withMotionLock(async()=>{try{e.setCurrentIncrementJog({axis:h.axis,direction:h.direction}),await e.jogger.runIncrementalCartesianMotion({currentTcpPose:m,currentJoints:b,coordSystemId:e.activeCoordSystemId,velocityInRelevantUnits:e.selectedCartesianMotionType==="translate"?e.translationVelocityMmPerSec:e.rotationVelocityRadsPerSec,axis:h.axis,direction:h.direction,motion:e.selectedCartesianMotionType==="translate"?{type:"translate",distanceMm:p.mm}:{type:"rotate",distanceRads:br.degreesToRadians(p.degrees)}})}finally{e.setCurrentIncrementJog(null),await e.deactivate()}})}async function s(h){if(!e.isLocked){if(await e.activate(),e.activeDiscreteIncrement)return o(h,e.activeDiscreteIncrement);h.motionType==="translate"?await e.jogger.startTCPTranslation({axis:h.axis,direction:h.direction,velocityMmPerSec:e.translationVelocityMmPerSec}):await e.jogger.startTCPRotation({axis:h.axis,direction:h.direction,velocityRadsPerSec:e.rotationVelocityRadsPerSec})}}async function i(){e.isLocked||e.activeDiscreteIncrement||await e.deactivate()}function l(h,p,f){var b,x,_;const m=(_=(x=(b=f.componentsExt)==null?void 0:b.JoggingPanel)==null?void 0:x.JoggingCartesian)==null?void 0:_.Axis;if(m)return p==="translate"?m[h]:m.CustomRotation??m[h]}const c=[{id:"x",icon:S.jsx(YV,{}),colors:l("X",e.selectedCartesianMotionType,n)},{id:"y",icon:S.jsx(QV,{}),colors:l("Y",e.selectedCartesianMotionType,n)},{id:"z",icon:S.jsx(ZV,{}),colors:l("Z",e.selectedCartesianMotionType,n)}];function u(h){return r("General.mm.variable",{amount:h.toFixed(1)})}function d(h){return r("General.degree.variable",{amount:br.radiansToDegrees(h).toFixed(1)})}return S.jsxs(q.Stack,{flexGrow:1,gap:2,sx:{padding:"18px 24px"},children:[S.jsxs(q.Stack,{gap:2,children:[S.jsx(y5,{store:e}),S.jsx(Ff,{store:e}),S.jsx(q.Divider,{})]}),S.jsx(q.Stack,{marginLeft:"auto",marginRight:"auto",gap:"24px",justifyContent:"center",sx:{flexGrow:"1"},children:S.jsxs(q.Stack,{alignItems:"center",justifyContent:"center",gap:"24px",sx:{flexGrow:1},children:[S.jsxs(b5,{value:e.selectedCartesianMotionType,onChange:a,exclusive:!0,"aria-label":r("Jogging.Cartesian.MotionType.lb"),sx:{justifyContent:"center"},children:[S.jsx(q.ToggleButton,{value:"translate",children:r("Jogging.Cartesian.Translation.bt")}),S.jsx(q.ToggleButton,{value:"rotate",children:r("Jogging.Cartesian.Rotation.bt")})]}),e.selectedCartesianMotionType==="translate"&&c.map(h=>{var p,f;return S.jsx(Xi,{colors:h.colors,disabled:e.isLocked,activeJoggingDirection:((p=e.incrementJogInProgress)==null?void 0:p.axis)===h.id?e.incrementJogInProgress.direction:void 0,label:S.jsxs(S.Fragment,{children:[h.icon,S.jsx(q.Typography,{sx:{fontSize:"24px",color:((f=h.colors)==null?void 0:f.labelColor)??n.palette.text.primary},children:h.id.toUpperCase()})]}),getDisplayedValue:()=>{var m;return u(((m=e.jogger.motionStream.rapidlyChangingMotionState.tcp_pose)==null?void 0:m.position[h.id])||0)},startJogging:m=>s({axis:h.id,motionType:"translate",direction:m}),stopJogging:i},h.id)}),e.selectedCartesianMotionType==="rotate"&&c.map(h=>{var p,f;return S.jsx(Xi,{colors:h.colors,disabled:e.isLocked,activeJoggingDirection:((p=e.incrementJogInProgress)==null?void 0:p.axis)===h.id?e.incrementJogInProgress.direction:void 0,label:S.jsxs(S.Fragment,{children:[S.jsx(tI,{}),S.jsx(q.Typography,{sx:{fontSize:"24px",color:((f=h.colors)==null?void 0:f.labelColor)??n.palette.text.primary},children:h.id.toUpperCase()})]}),getDisplayedValue:()=>{var m,b;return d(((b=(m=e.jogger.motionStream.rapidlyChangingMotionState.tcp_pose)==null?void 0:m.orientation)==null?void 0:b[h.id])||0)},startJogging:m=>s({axis:h.id,motionType:"rotate",direction:m}),stopJogging:i},h.id)})]})}),S.jsx(Ef,{store:e}),t&&S.jsx(q.Divider,{}),t]})}),W5=Ee.observer(({store:e,children:t})=>{const r=q.useTheme();async function n(o){await e.activate(),await e.jogger.startJointRotation({joint:o.joint,direction:o.direction,velocityRadsPerSec:e.rotationVelocityRadsPerSec})}async function a(){await e.jogger.stop(),await e.deactivate()}return S.jsxs(q.Stack,{flexGrow:1,gap:2,sx:{padding:"18px 24px"},children:[S.jsx(Ff,{store:e}),S.jsx(q.Divider,{}),S.jsx(q.Stack,{justifyContent:"center",alignItems:"stretch",sx:{flexGrow:"1"},id:"JointControls",children:S.jsx(q.Stack,{alignItems:"center",gap:"24px",children:e.jogger.motionStream.joints.map(o=>{var c;const s=(c=e.motionGroupSpec.mechanical_joint_limits)==null?void 0:c[o.index],i=(s==null?void 0:s.lower_limit)!==void 0?br.radiansToDegrees(s.lower_limit):void 0,l=(s==null?void 0:s.upper_limit)!==void 0?br.radiansToDegrees(s.upper_limit):void 0;return S.jsxs(q.Stack,{direction:"row",alignItems:"center",justifyContent:"center",spacing:1.5,width:"100%",children:[e.showJointsLegend&&S.jsx(q.Typography,{color:e.isLocked?r.palette.text.disabled:r.palette.text.secondary,children:`G${o.index+1}`}),S.jsx(Rm,{disabled:e.isLocked,lowerLimitDegs:i,upperLimitDegs:l,getValueDegs:()=>{const u=e.jogger.motionStream.rapidlyChangingMotionState.state.joint_position.joints[o.index];return u!==void 0?br.radiansToDegrees(u):void 0},startJogging:u=>n({joint:o.index,direction:u}),stopJogging:a})]},`joint-${o.index}`)})})}),S.jsx(Ef,{store:e}),t&&S.jsx(q.Divider,{}),t]})}),Y5=Ct(Ee.observer(e=>{const t=Sl.isString(e.nova)?new GV({instanceUrl:e.nova}):e.nova,r=Ee.useLocalObservable(()=>({joggingStore:null,loadingError:null}));async function n(){Ne.runInAction(()=>{r.loadingError=null,r.joggingStore=null});try{let a=e.store;if(!a){const o=await t.connectJogger(e.motionGroupId);a=await Ns.loadFor(o)}Ne.runInAction(()=>{r.joggingStore=a}),e.onSetup&&e.onSetup(a)}catch(a){r.loadingError=a}}return ee.useEffect(()=>(n(),e.store?()=>null:()=>{var a;(a=r.joggingStore)==null||a.dispose()}),[e.store,e.nova,e.motionGroupId]),ee.useEffect(()=>{const a=r.joggingStore;a&&(e.locked?a.lock("external"):a.unlock("external"))},[r.joggingStore,e.locked]),S.jsx(q.Stack,{sx:{maxWidth:"460px",minWidth:"320px",position:"relative",...e.sx},children:r.joggingStore?S.jsx(K5,{store:r.joggingStore,children:e.children}):S.jsx(fc,{message:"Loading jogging",error:r.loadingError})})})),K5=Ee.observer(({store:e,children:t})=>{const{t:r}=_e.useTranslation();function n(){if(e.currentTab.id==="cartesian")return S.jsx(S.Fragment,{children:S.jsx(J5,{store:e,children:t})});if(e.currentTab.id==="joint")return S.jsx(S.Fragment,{children:S.jsx(W5,{store:e,children:t})})}return S.jsxs(q.Stack,{flexGrow:1,sx:{overflow:"hidden"},children:[S.jsx(q.Tabs,{value:e.tabIndex,onChange:e.onTabChange,variant:"fullWidth",children:e.tabs.map(a=>{const o=a.label==="cartesian"?r("Jogging.Cartesian.bt"):r("Jogging.Joints.bt"),s=a.label==="cartesian"?S.jsx(wC,{fontSize:"small",sx:{mr:1}}):S.jsx(CC,{fontSize:"small",sx:{mr:1}});return S.jsx(q.Tab,{label:e.showTabIcons?S.jsxs(q.Stack,{direction:"row",alignItems:"center",children:[s,o]}):o,id:`jogging-tab-${a.id}`,"aria-controls":`jogging-tab-${a.id}`},a.id)})}),S.jsx(q.Stack,{flexGrow:1,position:"relative",sx:{overflowY:"auto",overflowX:"hidden"},children:n()})]})}),zf=ee.forwardRef(({label:e,value:t},r)=>{var i;const n=q.useTheme(),[a,o]=ee.useState(!1);async function s(){if(!r||!("current"in r))return console.warn("No copy target found"),!1;try{return await navigator.clipboard.writeText(t),console.log("Copied!"),o(!0),!0}catch(l){console.error(l);const c=window.getSelection(),u=document.createRange();u.selectNodeContents(r.current),c.removeAllRanges(),c.addRange(u)}return!1}return ee.useEffect(()=>{if(!a)return;const l=setTimeout(()=>o(!1),3e3);return()=>{l&&clearTimeout(l)}},[a]),S.jsx(q.Tooltip,{open:a,title:"Copied!",children:S.jsx(q.Stack,{justifyContent:"center",sx:{height:"100%",boxSizing:"border-box",padding:"6px 12px",background:(i=n.palette.backgroundPaperElevation)==null?void 0:i[8],borderRadius:"10px",minWidth:"0",cursor:"pointer"},onClick:()=>s(),children:S.jsx(q.Typography,{ref:r,align:"center",sx:{pointerEvents:"none",fontSize:"12px",color:n.palette.text.primary,whiteSpace:"nowrap",minWidth:0,textOverflow:"ellipsis",width:"100%",overflow:"hidden"},children:t})})})}),Q5=Ee.observer(({motionStream:e})=>{const t=ee.useRef(null);function r(){const n=e.rapidlyChangingMotionState.tcp_pose;return n?br.poseToWandelscriptString(n):""}return xn(()=>{if(!t.current)return;const n=r();t.current.textContent!==n&&(t.current.textContent=n)}),S.jsx(q.Stack,{alignItems:"left",spacing:2,sx:{flexGrow:1,minWidth:0,overflow:"hidden"},children:S.jsx(zf,{value:r(),ref:t})})}),X5=Ee.observer(({motionStream:e})=>{const t=ee.useRef(null);function r(){const{joints:n}=e.rapidlyChangingMotionState.state.joint_position;return`[${n.map(a=>parseFloat(a.toFixed(4))).join(", ")}]`}return xn(()=>{if(!t.current)return;const n=r();t.current.textContent!==n&&(t.current.textContent=n)}),S.jsx(q.Stack,{alignItems:"left",spacing:2,sx:{flexGrow:1,minWidth:0,overflow:"hidden"},children:S.jsx(zf,{value:r(),ref:t})})});function Z5(){const e=window.location.href;return e.substring(0,e.indexOf("/",e.indexOf("//")+2))}function e3({baseUrl:e=Z5(),...t}){return S.jsxs(q.Dialog,{"aria-labelledby":"no-motion-group-modal-title",open:!0,fullWidth:!0,sx:{"& .MuiModal-backdrop":{backdropFilter:"blur(10px)"},"& .MuiDialog-paper":{"::before":{content:'""',height:"8px",width:"100%",background:"linear-gradient(90deg, #FF0E65 0%, #47D3FF 100%)"},background:"#101629"}},children:[S.jsx(q.DialogTitle,{id:"no-motion-group-modal-title",children:"No motion group found"}),S.jsxs(q.DialogContent,{sx:{marginTop:"3rem",marginBottom:"1.5rem",textAlign:"center"},children:[S.jsx(q.Typography,{color:"#fff",children:"Found no devices to connect to."}),S.jsx(q.Typography,{color:"#fff",children:"Please ensure a motion group has been created."})]}),S.jsx(q.DialogActions,{children:S.jsxs(q.Stack,{width:"100%",maxWidth:"300px",margin:"auto",marginBottom:"2rem",children:[S.jsx(q.Button,{href:`${e}/settings`,variant:"contained",sx:{borderRadius:"8px",width:"100%"},children:"Go to settings app"}),S.jsx(q.Button,{href:`${e}`,variant:"text",sx:{marginTop:"1rem",color:"#fff",textDecoration:"underline",fontSize:"0.75rem"},children:"Back to Homescreen"})]})})]})}const t3=Ct(Ee.observer(({state:e,onRun:t,onPause:r,onStop:n,onReset:a,requiresManualReset:o=!1,variant:s="with_pause",className:i})=>{const l=q.useTheme(),{t:c}=_e.useTranslation(),u=()=>{const p={run:{enabled:e==="idle"||e==="paused",label:c(e==="paused"?"ProgramControl.Resume.bt":"ProgramControl.Start.bt"),color:l.palette.success.main,onClick:t},pause:{enabled:e==="running",label:c("ProgramControl.Pause.bt"),color:"#FFFFFF33",onClick:r||(()=>{})},stop:{enabled:e==="running"||e==="paused",label:c("ProgramControl.Stop.bt"),color:l.palette.error.main,onClick:n}};return s==="without_pause"?[p.run,p.stop]:[p.run,p.pause,p.stop]},d=p=>{const f={sx:{fontSize:"55px"}};if(s==="without_pause")return p===0?S.jsx(Vn.PlayArrow,{...f}):S.jsx(Vn.Stop,{...f});switch(p){case 0:return S.jsx(Vn.PlayArrow,{...f});case 1:return S.jsx(Vn.Pause,{...f});case 2:return S.jsx(Vn.Stop,{...f});default:return null}},h=u();return S.jsx(q.Box,{className:i,sx:{display:"flex",flexDirection:"column",alignItems:"center",gap:2},children:S.jsx(q.Box,{sx:{display:"flex",gap:"40px",flexWrap:"wrap",justifyContent:"center",alignItems:"center"},children:h.map((p,f)=>S.jsxs(q.Box,{sx:{display:"flex",flexDirection:"column",alignItems:"center",gap:1},children:[S.jsx(q.Button,{variant:"contained",disabled:!p.enabled||e==="stopping"&&!o,onClick:p.onClick,sx:{width:"110px",height:"110px",borderRadius:"110px",backgroundColor:p.color,opacity:p.enabled&&!(e==="stopping"&&!o)?1:.3,"&:hover":{backgroundColor:p.color,opacity:p.enabled&&!(e==="stopping"&&!o)?.8:.3},"&:disabled":{backgroundColor:p.color,opacity:.3},minWidth:"110px",flexShrink:0},children:d(f)}),S.jsx(q.Typography,{variant:"body1",sx:{color:p.enabled&&!(e==="stopping"&&!o)?p.color:l.palette.text.disabled,textAlign:"center",opacity:p.enabled&&!(e==="stopping"&&!o)?1:.3},children:p.label})]},p.label))})})})),r3=Ct(Ee.observer(({programState:e,safetyState:t,operationMode:r,className:n})=>{const a=q.useTheme(),{t:o}=_e.useTranslation(),s=()=>{if(t==="SAFETY_STATE_DEVICE_EMERGENCY_STOP"||t==="SAFETY_STATE_ROBOT_EMERGENCY_STOP"||t==="SAFETY_STATE_STOP_0"||t==="SAFETY_STATE_STOP_1"||t==="SAFETY_STATE_STOP_2"||t==="SAFETY_STATE_PROTECTIVE_STOP"||t==="SAFETY_STATE_STOP"||t==="SAFETY_STATE_REDUCED"||t==="SAFETY_STATE_MASTERING"||t==="SAFETY_STATE_CONFIRM_SAFETY"||t==="SAFETY_STATE_OPERATOR_SAFETY"||t==="SAFETY_STATE_RECOVERY"||t==="SAFETY_STATE_VIOLATION")return{label:o("ProgramStateIndicator.EStop.lb"),color:a.palette.error.main};if(t==="SAFETY_STATE_UNKNOWN"||t==="SAFETY_STATE_FAULT")return{label:o("ProgramStateIndicator.Error.lb"),color:a.palette.error.main};if(t==="SAFETY_STATE_NORMAL")switch(e){case"running":return{label:o("ProgramStateIndicator.Running.lb"),color:a.palette.success.main};case"paused":return{label:o("ProgramStateIndicator.Paused.lb"),color:a.palette.grey[600]};case"stopping":return{label:o("ProgramStateIndicator.Stopped.lb"),color:a.palette.error.main};case"idle":default:return{label:o("ProgramStateIndicator.Ready.lb"),color:a.palette.success.main}}return{label:o("ProgramStateIndicator.Idle.lb"),color:a.palette.grey[600]}},{label:i,color:l}=s(),u=`${i} / ${(()=>{switch(r){case"OPERATION_MODE_AUTO":return o("ProgramStateIndicator.Auto.lb");case"OPERATION_MODE_MANUAL":return o("ProgramStateIndicator.Manual.lb");case"OPERATION_MODE_MANUAL_T1":return o("ProgramStateIndicator.ManualT1.lb");case"OPERATION_MODE_MANUAL_T2":return o("ProgramStateIndicator.ManualT2.lb");default:return o("ProgramStateIndicator.Auto.lb")}})()}`;return S.jsx(q.Chip,{className:n,label:u,variant:"filled",sx:{backgroundColor:l,color:a.palette.getContrastText(l),fontWeight:500,"& .MuiChip-label":{paddingX:2}}})})),n3=Aa(S.jsx("path",{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"}),"Error"),a3=({title:e,titleId:t,...r},n)=>V.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:18,height:18,fill:"none",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.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"})),o3=ee.forwardRef(a3);var Oc=(e=>(e.PRECONDITION_NOT_FULFILLED="PRECONDITION_NOT_FULFILLED",e.ROBOT_DISCONNECTED="ROBOT_DISCONNECTED",e.READY="READY",e))(Oc||{});const Gf=Ct(Ee.observer(({setupState:e,className:t})=>{const r=q.useTheme(),{t:n}=_e.useTranslation(),a=()=>{var c,u,d,h;switch(e){case"READY":return{label:n("RobotSetupReadinessIndicator.Ready.lb"),indicatorColor:((c=r.palette.tertiary)==null?void 0:c.main)||r.palette.primary.main,backgroundColor:((u=r.palette.backgroundPaperElevation)==null?void 0:u[11])||r.palette.background.paper,textColor:"var(--secondary-contrast, #FFFFFFDE)"};case"ROBOT_DISCONNECTED":return{label:n("RobotSetupReadinessIndicator.RobotDisconnected.lb"),indicatorColor:r.palette.error.main,backgroundColor:((d=r.palette.backgroundPaperElevation)==null?void 0:d[11])||r.palette.background.paper,textColor:"var(--secondary-contrast, #FFFFFFDE)"};case"PRECONDITION_NOT_FULFILLED":default:return{label:n("RobotSetupReadinessIndicator.PreconditionNotFulfilled.lb"),indicatorColor:r.palette.error.main,backgroundColor:((h=r.palette.backgroundPaperElevation)==null?void 0:h[11])||r.palette.background.paper,textColor:"var(--secondary-contrast, #FFFFFFDE)"}}},{label:o,indicatorColor:s,backgroundColor:i,textColor:l}=a();return S.jsx(q.Chip,{className:t,label:S.jsxs(q.Box,{sx:{display:"flex",alignItems:"center",gap:1},children:[S.jsx(q.Box,{sx:{width:8,height:8,borderRadius:"50%",backgroundColor:s,flexShrink:0}}),S.jsx(q.Typography,{variant:"body2",sx:{color:l,fontSize:"0.75rem",lineHeight:1.2},children:o})]}),variant:"filled",sx:{backgroundColor:i,color:r.palette.getContrastText(i),fontWeight:500,"& .MuiChip-label":{paddingX:1.5}}})})),s3=Ct(Ee.observer(({robotName:e,robotType:t,setupState:r,PreconditionComponent:n=Gf,className:a})=>{const o=q.useTheme(),s=t||"Robot",i=r===Oc.READY;return S.jsxs(q.Box,{className:a,sx:{border:"1px solid var(--secondary-_states-outlinedBorder, #FFFFFF1F)",background:"var(--background-paper-elevation-8, #292B3E)",height:80,minHeight:"80px",borderRadius:"8px",padding:"20px",display:"flex",alignItems:"center",justifyContent:"space-between",opacity:1},children:[S.jsxs(q.Box,{sx:{display:"flex",alignItems:"center",gap:2,flex:1},children:[i?S.jsx(q.Box,{sx:{fontSize:24,display:"flex",alignItems:"center",justifyContent:"center",width:24,height:24,"& svg":{fill:"var(--primary-main, #8E56FC) !important"},"& svg path":{fill:"var(--primary-main, #8E56FC) !important"}},children:S.jsx(o3,{})}):S.jsx(n3,{sx:{color:o.palette.error.main,fontSize:24}}),S.jsx(q.Typography,{variant:"body1",sx:{fontWeight:500,color:o.palette.text.primary},children:e}),S.jsx(q.Divider,{orientation:"vertical",flexItem:!0,sx:{backgroundColor:o.palette.text.secondary,opacity:.3,width:"1px"}}),S.jsx(q.Typography,{variant:"body2",sx:{color:o.palette.text.secondary},children:s})]}),n&&S.jsx(n,{setupState:r})]})})),i3=Array(6).fill(2*Math.PI),Rh="0.0.0-semantically-released";function wc(e){let t=Rh;return Rh.startsWith("0.")&&(t=""),`https://cdn.jsdelivr.net/gh/wandelbotsgmbh/wandelbots-js-react-components${t?`@${t}`:""}/public/models/${e}.glb`}function l3(e){function t(r){return r.children.length===0?[r]:[r,...r.children.flatMap(n=>t(n))]}return t(e).filter(r=>qf(r))}function Hf(e){return e.name.endsWith("_FLG")}function qf(e){return/_J[0-9]+$/.test(e.name)}function c3(e,t){let r;function n(a){if(Hf(a)){if(r)throw Error(`Found multiple flange groups in robot model ${t}; first ${r.name} then ${a.name}. Only one _FLG group is allowed.`);r=a}qf(a),a.children.map(n)}if(n(e.scene),!r)throw Error(`No flange group found in robot model ${t}. Flange must be identified with a name ending in _FLG.`);return{gltf:e}}function Jf({rapidlyChangingMotionState:e,dhParameters:t,onRotationChanged:r,children:n}){const a=ee.useRef([]),o=ee.useRef([]),s=ee.useRef(null),{invalidate:i}=Cc.useThree();ee.useEffect(()=>{const d=e.state.joint_position.joints.filter(h=>h!==void 0);return s.current=new uc(d,{tension:120,friction:20,threshold:.001}),()=>{var h;(h=s.current)==null||h.destroy()}},[]),Cc.useFrame((d,h)=>{if(s.current){const p=s.current.update(h);u(),p||i()}});function l(d){d&&(o.current=l3(d),u(),i())}function c(d){var h;a.current=d,(h=s.current)==null||h.setTarget(d)}function u(){var h;const d=((h=s.current)==null?void 0:h.getCurrentValues())||[];if(r)r(o.current,d);else for(const[p,f]of o.current.entries()){const m=t[p],b=m.theta||0,x=m.reverse_rotation_direction?-1:1;f.rotation.y=x*(d[p]||0)+b}}return Om(()=>{const d=e.state.joint_position.joints.filter(h=>h!==void 0);requestAnimationFrame(()=>c(d))}),S.jsx("group",{ref:l,children:n})}const u3="line",d3="mesh";function h3({rapidlyChangingMotionState:e,dhParameters:t,...r}){const n=new vt.Matrix4,a=ee.useRef([]),o=ee.useRef([]);ee.useEffect(()=>{a.current=new Array(t.length).fill(null),o.current=new Array(t.length).fill(null)},[t.length]);function s(c,u){const d=new vt.Vector3,h=new vt.Quaternion,p=new vt.Vector3;n.decompose(d,h,p);const f=d.clone(),m=new vt.Matrix4().makeRotationY(c.theta+u*(c.reverse_rotation_direction?-1:1)).multiply(new vt.Matrix4().makeTranslation(0,c.d/1e3,0)).multiply(new vt.Matrix4().makeTranslation(c.a/1e3,0,0)).multiply(new vt.Matrix4().makeRotationX(c.alpha));return n.multiply(m),n.decompose(d,h,p),{a:f,b:d}}function i(c,u,d,h){if(!t)return;const p=t[c];if(!p)return;const{a:f,b:m}=s(p,h);u.geometry.setPositions([f.toArray(),m.toArray()].flat()),d.position.set(m.x,m.y,m.z)}function l(c,u){n.identity();for(let d=0;d<Math.min(c.length,u.length);d++){const h=a.current[d],p=o.current[d];h&&p&&i(d,h,p,u[d])}}return S.jsx(S.Fragment,{children:S.jsx(Jf,{rapidlyChangingMotionState:e,dhParameters:t,onRotationChanged:l,children:S.jsxs("group",{...r,name:"Scene",children:[S.jsxs("mesh",{children:[S.jsx("sphereGeometry",{args:[.01,32,32]}),S.jsx("meshStandardMaterial",{color:"black",depthTest:!0})]}),t.map((c,u)=>{const{a:d,b:h}=s(c,e.state.joint_position.joints[u]??0),p=`dhrobot_J0${u}`;return S.jsxs("group",{name:p,children:[S.jsx(St.Line,{ref:f=>{a.current[u]=f},name:u3,points:[d,h],color:"white",lineWidth:5}),S.jsxs("mesh",{ref:f=>{o.current[u]=f},name:d3,position:h,children:[S.jsx("sphereGeometry",{args:[.01,32,32]}),S.jsx("meshStandardMaterial",{color:"black",depthTest:!0})]},"mesh_"+u)]},p)})]})})})}const p3=console.warn;function m3(){return ee.useEffect(()=>{console.warn=e=>{e!=="Cannot call the manual advancement of rafz whilst frameLoop is not set as demand"&&p3(e)}},[]),S.jsx(S.Fragment,{})}function f3(e){return e.type==="Mesh"}function g3({modelURL:e,flangeRef:t,postModelRender:r,...n}){const{gltf:a}=c3(St.useGLTF(e),e.split("/").pop()||e),o=ee.useCallback(i=>{i&&r&&r()},[e]);function s(i){return f3(i)?S.jsx("mesh",{name:i.name,geometry:i.geometry,material:i.material,position:i.position,rotation:i.rotation},i.uuid):S.jsx("group",{name:i.name,position:i.position,rotation:i.rotation,ref:Hf(i)?t:void 0,children:i.children.map(s)},i.uuid)}return S.jsx("group",{...n,dispose:null,ref:o,children:s(a.scene)})}const y3=(e,t)=>{e.userData.isGhost||(e.traverse(r=>{if(r instanceof ke.Mesh){r.material instanceof ke.Material&&(r.material.colorWrite=!1);const n=r.clone(),a=r.clone();n.material=new ke.MeshStandardMaterial({depthTest:!0,depthWrite:!0,colorWrite:!1,polygonOffset:!0,polygonOffsetFactor:-1,side:ke.DoubleSide}),n.userData.isGhost=!0,a.material=new ke.MeshStandardMaterial({color:t,opacity:.3,depthTest:!0,depthWrite:!1,transparent:!0,polygonOffset:!0,polygonOffsetFactor:-2,side:ke.DoubleSide}),a.userData.isGhost=!0,r.parent&&(r.parent.add(n),r.parent.add(a))}}),e.userData.isGhost=!0)},b3=e=>{if(!e.userData.isGhost)return;const t=[];e.traverse(r=>{var n;r instanceof ke.Mesh&&((n=r.userData)!=null&&n.isGhost?t.push(r):r.material instanceof ke.Material&&(r.material.colorWrite=!0))}),t.forEach(r=>{r.parent&&r.parent.remove(r)}),e.userData.isGhost=!1},Wf=Ct(({rapidlyChangingMotionState:e,modelFromController:t,dhParameters:r,getModel:n=wc,flangeRef:a,postModelRender:o,transparentColor:s,...i})=>{const[l,c]=ee.useState(null),u=ee.useCallback(h=>{c(h)},[]);ee.useEffect(()=>{l&&(s?y3(l,s):b3(l))},[l,s]);const d=S.jsx(h3,{rapidlyChangingMotionState:e,dhParameters:r,...i});return S.jsxs(dg.ErrorBoundary,{fallback:d,onError:h=>{console.error(h)},children:[S.jsx(ee.Suspense,{fallback:d,children:S.jsx("group",{ref:u,children:S.jsx(Jf,{rapidlyChangingMotionState:e,dhParameters:r,children:S.jsx(g3,{modelURL:n(t),postModelRender:o,flangeRef:a,...i})})})}),S.jsx(m3,{})]})});function v3({connectedMotionGroup:e,getModel:t=wc,flangeRef:r,transparentColor:n,...a}){return e.dhParameters?S.jsx(Wf,{rapidlyChangingMotionState:e.rapidlyChangingMotionState,modelFromController:e.modelFromController||"",dhParameters:e.dhParameters,getModel:t,flangeRef:r,transparentColor:n,...a}):null}const S3=({title:e,titleId:t,...r},n)=>V.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.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"})),x3=ee.forwardRef(S3),O3=({title:e,titleId:t,...r},n)=>V.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.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"})),w3=ee.forwardRef(O3),Vt=Ee.observer(({id:e,icon:t,color:r,title:n,name:a,label:o,explanation:s,literalValue:i,anchorOrigin:l,transformOrigin:c})=>{const u=Ee.useLocalObservable(()=>({anchorEl:null,get isPopoverOpen(){return!!u.anchorEl},openPopover(d){u.anchorEl=d.currentTarget},closePopover(){u.anchorEl=null}}));return S.jsxs(S.Fragment,{children:[S.jsxs(q.Stack,{"aria-owns":u.isPopoverOpen?e:void 0,"aria-haspopup":"true",onMouseEnter:u.openPopover,onMouseLeave:u.closePopover,direction:"row",spacing:1,sx:{cursor:"pointer"},children:[S.jsx(q.SvgIcon,{component:t,sx:{color:r}}),o&&S.jsx("div",{style:{color:r},children:o})]}),S.jsx(q.Popover,{id:e,sx:{pointerEvents:"none"},open:u.isPopoverOpen,anchorEl:u.anchorEl,anchorOrigin:l??{vertical:"bottom",horizontal:"left"},transformOrigin:c??{vertical:"top",horizontal:"left"},onClose:u.closePopover,disableRestoreFocus:!0,children:S.jsxs(q.Stack,{gap:"1rem",padding:2,maxWidth:"450px",sx:{wordWrap:"break-word"},children:[S.jsxs("div",{children:[n&&S.jsx(q.Typography,{component:"span",fontSize:"14px",children:`${n}: `}),S.jsx(q.Typography,{component:"span",color:r,fontWeight:"bold",fontSize:"14px",children:a})]}),S.jsx(q.Typography,{fontSize:"14px",children:s}),i&&S.jsx(q.Typography,{fontSize:"12px",children:i})]})})]})}),C3=Ee.observer(({isVirtual:e,motionGroupId:t,anchorOrigin:r,transformOrigin:n,compact:a})=>{const o=q.useTheme(),{t:s}=_e.useTranslation();return e?S.jsx(Vt,{id:"motion-group-virtual",icon:w3,color:o.palette.tertiary.main,name:s("SafetyBar.ControllerType.Virtual.lb"),label:a?null:s("SafetyBar.ControllerType.Virtual.lb"),explanation:S.jsxs(_e.Trans,{i18nKey:"SafetyBar.MotionGroup.Virtual.Explanation.lb",values:{motionGroupId:t},children:["Motion group ",S.jsx("code",{children:t})," refers to a virtual robot with no physical counterpart. It can be freely manipulated without special safety precautions."]}),anchorOrigin:r,transformOrigin:n}):S.jsx(Vt,{id:"motion-group-physical",icon:x3,color:o.palette.primary.main,name:s("SafetyBar.ControllerType.Physical.lb"),label:a?null:s("SafetyBar.ControllerType.Physical.lb"),explanation:S.jsx(_e.Trans,{i18nKey:"SafetyBar.MotionGroup.Physical.Explanation.lb",values:{motionGroupId:t},components:{code:S.jsx("code",{}),strong:S.jsx("strong",{})}}),anchorOrigin:r,transformOrigin:n})}),P3=({title:e,titleId:t,...r},n)=>V.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.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"})),T3=ee.forwardRef(P3),R3=({title:e,titleId:t,...r},n)=>V.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.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:.56})),A3=ee.forwardRef(R3),_3=({title:e,titleId:t,...r},n)=>V.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.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"})),E3=ee.forwardRef(_3),V3=Ee.observer(({operationMode:e,anchorOrigin:t,transformOrigin:r,compact:n})=>{const{t:a}=_e.useTranslation(),o=q.useTheme();switch(e){case"OPERATION_MODE_AUTO":return S.jsx(Vt,{id:"operation-mode-auto",icon:T3,title:a("SafetyBar.OperationMode.ti"),name:a("SafetyBar.OperationMode.Automatic.ti"),label:n?null:a("SafetyBar.OperationMode.Automatic.ti"),color:o.palette.text.secondary,explanation:S.jsx(_e.Trans,{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."}),anchorOrigin:t,transformOrigin:r});case"OPERATION_MODE_MANUAL":case"OPERATION_MODE_MANUAL_T1":case"OPERATION_MODE_MANUAL_T2":return S.jsx(Vt,{id:"operation-mode-manual",icon:E3,color:o.palette.warning.main,title:a("SafetyBar.OperationMode.ti"),name:a("SafetyBar.OperationMode.Manual.lb"),label:n?null:a("SafetyBar.OperationMode.Manual.lb"),explanation:S.jsx(_e.Trans,{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."}),literalValue:e,anchorOrigin:t,transformOrigin:r});default:return S.jsx(Vt,{id:"operation-mode-error",icon:A3,color:o.palette.warning.main,title:a("SafetyBar.OperationMode.ti"),name:a("SafetyBar.OperationMode.Error.lb"),label:n?null:a("SafetyBar.OperationMode.Error.lb"),explanation:S.jsx(_e.Trans,{i18nKey:"SafetyBar.OperationMode.Error.Explanation.lb",children:"The robot controller has entered an unexpected operation mode. Motion group movement may not be possible."}),literalValue:e,anchorOrigin:t,transformOrigin:r})}}),I3=({title:e,titleId:t,...r},n)=>V.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.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"})),M3=ee.forwardRef(I3),$3=({title:e,titleId:t,...r},n)=>V.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.createElement("path",{d:"M10.24 10.636 12 13.764l1.76-3.128h-3.52Z"}),V.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"}),V.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"})),j3=ee.forwardRef($3),k3=({title:e,titleId:t,...r},n)=>V.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.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:.56})),U3=ee.forwardRef(k3),L3=({title:e,titleId:t,...r},n)=>V.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.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"})),D3=ee.forwardRef(L3),N3=({title:e,titleId:t,...r},n)=>V.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?V.createElement("title",{id:t},e):null,V.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"})),B3=ee.forwardRef(N3),F3=Ee.observer(({safetyState:e,anchorOrigin:t,transformOrigin:r,compact:n})=>{const{t:a}=_e.useTranslation(),o=q.useTheme();switch(e){case"SAFETY_STATE_NORMAL":return S.jsx(Vt,{id:"safety-state-normal",title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.Normal.lb"),label:n?null:a("SafetyBar.SafetyState.Normal.lb"),icon:D3,color:o.palette.text.secondary,explanation:S.jsx(_e.Trans,{i18nKey:"SafetyBar.SafetyState.Normal.Explanation.lb",children:"The robot controller is in a normal safety state. Movement is not prevented by this state."}),anchorOrigin:t,transformOrigin:r});case"SAFETY_STATE_DEVICE_EMERGENCY_STOP":case"SAFETY_STATE_ROBOT_EMERGENCY_STOP":return S.jsx(Vt,{id:"safety-state-estop",title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.Estop.lb"),label:n?null:a("SafetyBar.SafetyState.Estop.lb"),icon:j3,color:o.palette.error.main,explanation:S.jsx(_e.Trans,{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."}),literalValue:e,anchorOrigin:t,transformOrigin:r});case"SAFETY_STATE_STOP_0":case"SAFETY_STATE_STOP_1":case"SAFETY_STATE_STOP_2":case"SAFETY_STATE_PROTECTIVE_STOP":case"SAFETY_STATE_STOP":return S.jsx(Vt,{id:"safety-state-stop",icon:B3,title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.Stop.lb"),label:n?null:a("SafetyBar.SafetyState.Stop.lb"),color:o.palette.warning.main,explanation:S.jsx(_e.Trans,{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."}),literalValue:e,anchorOrigin:t,transformOrigin:r});case"SAFETY_STATE_REDUCED":case"SAFETY_STATE_MASTERING":case"SAFETY_STATE_CONFIRM_SAFETY":case"SAFETY_STATE_OPERATOR_SAFETY":case"SAFETY_STATE_RECOVERY":case"SAFETY_STATE_VIOLATION":return S.jsx(Vt,{id:"safety-state-manual-action-required",icon:U3,color:o.palette.warning.main,title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.ManualActionRequired.lb"),label:n?null:a("SafetyBar.SafetyState.ManualActionRequired.lb"),explanation:S.jsx(_e.Trans,{i18nKey:"SafetyBar.SafetyState.ManualActionRequired.Explanation.lb",children:"The robot controller has entered a safety state requiring manual action to resolve."}),literalValue:e,anchorOrigin:t,transformOrigin:r});case"SAFETY_STATE_UNKNOWN":case"SAFETY_STATE_FAULT":return S.jsx(Vt,{id:"safety-state-error",icon:M3,color:o.palette.error.main,title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.Error.lb"),label:n?null:a("SafetyBar.SafetyState.Error.lb"),explanation:S.jsx(_e.Trans,{i18nKey:"SafetyBar.SafetyState.Error.Explanation.lb",children:"The robot controller has entered an unexpected safety state."}),literalValue:e,anchorOrigin:t,transformOrigin:r});default:qV(e,`Unknown safety state ${e}`)}}),z3=Ct(Ee.observer(({isVirtual:e,motionGroupId:t,operationMode:r,safetyState:n,anchorOrigin:a,transformOrigin:o,compact:s=!0})=>{const i=s?1:2;return S.jsxs(q.Stack,{direction:"row",gap:i,alignItems:"center",sx:{height:"24px"},children:[S.jsx(F3,{safetyState:n,anchorOrigin:a,transformOrigin:o,compact:s}),S.jsx(q.Divider,{orientation:"vertical",flexItem:!0}),S.jsx(V3,{operationMode:r,anchorOrigin:a,transformOrigin:o,compact:s}),S.jsx(q.Divider,{orientation:"vertical",flexItem:!0}),S.jsx(C3,{isVirtual:e,motionGroupId:t,anchorOrigin:a,transformOrigin:o,compact:s})]})})),G3=q.styled(q.Fab,{shouldForwardProp:e=>e!=="selected"})(({theme:e})=>{var t,r,n;return{borderRadius:"20px","&:hover":{background:(t=e.palette.backgroundPaperElevation)==null?void 0:t[7]},variants:[{props:({selected:a})=>!a,style:{background:(r=e.palette.backgroundPaperElevation)==null?void 0:r[0],color:e.palette.action.disabled,"> img":{opacity:.4}}},{props:({selected:a})=>a,style:{background:(n=e.palette.backgroundPaperElevation)==null?void 0:n[11],border:`1px solid ${e.palette.divider}`,color:e.palette.primary.contrastText}}]}}),H3=ee.forwardRef((e,t)=>S.jsx(G3,{ref:t,selected:e.selected,...e,color:"secondary",variant:"circular"})),q3={$schema:"https://raw.githubusercontent.com/martinring/tmlanguage/master/tmlanguage.json",name:"wandelscript",patterns:[{include:"#keywords"},{include:"#strings"},{include:"#comments"},{include:"#functions"}],repository:{keywords:{patterns:[{name:"keyword.control.flow.wandelscript",match:"\\b(move|via|to|interrupt|def|False|True|for|if|else|elif|while|return|switch|activate|deactivate|print|and|or|not)\\b"}]},strings:{name:"string.quoted.double.wandelscript",begin:'"',end:'"',patterns:[{name:"constant.character.escape.wandelscript",match:"\\\\."}]},comments:{patterns:[{begin:"#",beginCaptures:{0:{name:"punctuation.definition.comment.wandelscript"}},end:"$",name:"comment.line.number-sign.wandelscript"}]},functions:{patterns:[{match:"[a-zA-Z_-]+\\(",name:"entity.name.function.wandelscript"}]}},scopeName:"source.wandelscript"},J3=ee.lazy(()=>import("@monaco-editor/react"));let ji=null;async function W3(){if(!ji){const[{createHighlighter:e},{shikiToMonaco:t}]=await Promise.all([import("shiki"),import("@shikijs/monaco")]);ji={shiki:await e({langs:[q3],themes:["dark-plus","light-plus"]}),shikiToMonaco:t}}return ji}const Y3=Ct(e=>{const t=q.useTheme(),[r,n]=ee.useState("dark-plus"),a=t.palette.mode==="dark"?"dark-plus":"light-plus";async function o(s){var c,u;s.languages.register({id:"wandelscript"}),s.languages.setLanguageConfiguration("wandelscript",{comments:{lineComment:"#"},brackets:[["(",")"],["[","]"]],autoClosingPairs:[{open:"[",close:"]"},{open:"(",close:")"}],surroundingPairs:[{open:"[",close:"]"},{open:"(",close:")"}]});const{shiki:i,shikiToMonaco:l}=await W3();l(i,s),s.editor.defineTheme(a,((u=(c=t.componentsExt)==null?void 0:c.WandelscriptEditor)==null?void 0:u.monacoTheme)??{base:t.palette.mode==="dark"?"vs-dark":"vs",inherit:!0,rules:[],colors:{}}),e.monacoSetup&&e.monacoSetup(s),n(a)}return S.jsx(ee.Suspense,{fallback:S.jsx(fc,{}),children:S.jsx(J3,{value:e.code,onMount:(s,i)=>{o(i)},onChange:e.onChange,defaultLanguage:"wandelscript",theme:r,options:{minimap:{enabled:!1},wordWrap:"on",automaticLayout:!0,...e.monacoOptions}})})});function Yf(){var t,r,n,a,o,s,i;const e=q.createTheme({palette:{mode:"dark",text:{primary:"rgba(255, 255, 255, 1)",secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.38)"},primary:{main:"rgba(142, 86, 252, 1)",dark:"rgba(136, 58, 255, 1)",light:"rgba(157, 131, 246, 1)",contrastText:"rgba(255, 255, 255, 0.87)"},secondary:{main:"rgba(255, 255, 255, 1)",dark:"rgba(255, 255, 255, 0.06)",contrastText:"rgba(255, 255, 255, 0.87)"},tertiary:{main:"rgba(100, 255, 218, 1)",dark:"rgba(38, 166, 154, 1)",light:"rgba(167, 255, 235, 1)",contrastText:"rgba(0, 0, 0, 1)"},error:{main:"rgba(239, 83, 80, 1)",dark:"rgba(229, 57, 53, 1)",light:"rgba(239, 154, 154, 1)",contrastText:"rgba(255, 255, 255, 1)"},warning:{main:"rgba(255, 171, 64, 1)",dark:"rgba(255, 145, 0, 1)",light:"rgba(255, 209, 128, 1)",contrastText:"rgba(0, 0, 0, 0.87)"},success:{main:"rgba(38, 166, 154, 1)",dark:"rgba(0, 121, 107, 1)",light:"rgba(128, 203, 196, 1)",contrastText:"rgba(255, 255, 255, 0.87)"},background:{default:"rgba(2, 6, 23, 1)",paper:"rgba(17, 19, 31, 1)"},action:{active:"rgba(255, 255, 255, 0.56)",hover:"rgba(255, 255, 255, 0.08)",selected:"rgba(255, 255, 255, 0.16)",disabledBackground:"rgba(255, 255, 255, 0.12)",focus:"rgba(255, 255, 255, 0.12)",disabled:"rgba(255, 255, 255, 0.38)"},common:{white:"rgba(255, 255, 255, 1)",black:"rgba(0, 0, 0, 1)"},divider:"rgba(255, 255, 255, 0.12)",backgroundPaperElevation:{0:"rgba(17,19,31,1.0)",1:"rgba(20,22,35,1.0)",2:"rgba(23,25,39,1.0)",3:"rgba(26,28,43,1.0)",4:"rgba(29,31,47,1.0)",5:"rgba(32,34,51,1.0)",6:"rgba(35,37,55,1.0)",7:"rgba(38,40,59,1.0)",8:"rgba(41,43,63,1.0)",9:"rgba(44,46,67,1.0)",10:"rgba(47,49,71,1.0)",11:"rgba(50,52,75,1.0)",12:"rgba(53,55,79,1.0)",13:"rgba(56,58,83,1.0)",14:"rgba(59,61,87,1.0)",15:"rgba(62,64,91,1.0)",16:"rgba(57,63,87,1.0)"}},paletteExt:{primary:{hover:"rgba(142, 86, 252, 0.08)",selected:"rgba(142, 86, 252, 0.16)",focus:"rgba(142, 86, 252, 0.12)",focusVisible:"rgba(142, 86, 252, 0.3)",outlineBorder:"rgba(142, 86, 252, 0.5)"},secondary:{tonal:"rgba(255,255,255,0.1)"}}});return{...e,components:{MuiCssBaseline:{styleOverrides:{"html, body, *":{scrollbarWidth:"none",msOverflowStyle:"none"},"html:hover, body:hover, *:hover":{scrollbarWidth:"thin",scrollbarColor:`${e.palette.divider} transparent`}}},MuiButton:{styleOverrides:{root:{textTransform:"none",borderRadius:"10px"}},variants:[{props:{color:"secondary",variant:"contained"},style:{border:`1px solid ${e.palette.divider}`,background:(n=(r=(t=e.paletteExt)==null?void 0:t.secondary)==null?void 0:r.tonal)==null?void 0:n.toString()}},{props:{color:"secondary",variant:"outlined"},style:{border:`1px solid ${e.palette.divider}`}}]},MuiTab:{styleOverrides:{root:{textTransform:"none",color:e.palette.text.secondary,"&.Mui-selected":{color:e.palette.text.primary}}}},MuiTabs:{styleOverrides:{root:{background:(a=e.palette.backgroundPaperElevation)==null?void 0:a[1]}}},MuiToggleButtonGroup:{styleOverrides:{root:{".MuiToggleButtonGroup-firstButton":{borderRadius:"10px 0 0 10px"},".MuiToggleButtonGroup-lastButton":{borderRadius:"0 10px 10px 0"}}}},MuiToggleButton:{styleOverrides:{root:{textTransform:"none",padding:"6px 16px"}}},MuiSelect:{variants:[{props:{variant:"filled"},style:{borderRadius:"10px","::before, ::after":{visibility:"collapse"},".MuiInputBase-input":{padding:"6px 16px",borderRadius:"10px"}}}]},MuiDrawer:{styleOverrides:{paper:{border:"none",boxShadow:"4px 0 8px -4px rgba(0, 0, 0, 0.3)"}}},MuiFab:{styleOverrides:{root:{background:(s=(o=e.paletteExt)==null?void 0:o.secondary)==null?void 0:s.tonal}},variants:[{props:{color:"primary"},style:{background:e.palette.primary.main}}]}},componentsExt:{JoggingPanel:{JoggingCartesian:{Axis:{X:{backgroundColor:"rgba(215, 66, 56, 1)",borderColor:"rgba(215, 66, 56, 1)",buttonBackgroundColor:{default:"rgba(241, 77, 66, 1)",pressed:"rgba(138, 41, 35, 1)",hovered:"rgba(241, 77, 66, 1)",disabled:"rgba(241, 77, 66, 1)"},color:"rgba(255, 198, 198, 1)",labelColor:e.palette.text.primary},Y:{backgroundColor:"rgba(20, 151, 108, 1)",borderColor:"rgba(20, 151, 108, 1)",buttonBackgroundColor:{default:"rgba(28, 188, 135, 1)",pressed:"rgba(11, 89, 63, 1)",disabled:"rgba(28, 188, 135, 1)",hovered:"rgba(28, 188, 135, 1)"},color:"rgba(215, 255, 242, 1)",labelColor:e.palette.text.primary},Z:{backgroundColor:"rgba(1, 87, 155, 1)",borderColor:"rgba(1, 87, 155, 1)",buttonBackgroundColor:{default:"rgba(2, 136, 209, 1)",pressed:"rgba(2, 64, 114, 1)",disabled:"rgba(2, 136, 209, 1)",hovered:"rgba(2, 136, 209, 1)"},color:"rgba(210, 239, 255, 1)",labelColor:e.palette.text.primary}}},JoggingJoint:{Joint:{arrowColor:e.palette.text.primary}},VelocitySlider:{sliderLegendColor:e.palette.text.primary}},WandelscriptEditor:{monacoTheme:{base:"vs-dark",inherit:!0,rules:[{token:"keyword",foreground:"#b349a9ff"}],colors:{"editor.background":q.rgbToHex(((i=e.palette.backgroundPaperElevation)==null?void 0:i[5])??""),"editor.foreground":"#d4d4d4","editorLineNumber.foreground":"#797979","editorLineNumber.activeForeground":"#e9e9e9","editor.lineHighlightBorder":"#e9e9e911"}}}}}}function K3(){const e=Yf();return e.palette.mode="light",e}function Q3(e){var n,a,o,s;let t=!0;((n=e.palette)==null?void 0:n.mode)==="light"?t=!1:((a=e.palette)==null?void 0:a.mode)!=="dark"&&(t=!(typeof window<"u"&&((s=(o=window.matchMedia)==null?void 0:o.call(window,"(prefers-color-scheme: light)"))==null?void 0:s.matches)));const r=t?Yf():K3();return Qh(r,e)}exports.CycleTimer=Fw;exports.JoggingCartesianAxisControl=Xi;exports.JoggingJointRotationControl=Rm;exports.JoggingPanel=Y5;exports.JoggingStore=Ns;exports.LoadingCover=fc;exports.LoadingErrorMessage=vf;exports.NoMotionGroupModal=e3;exports.PoseCartesianValues=Q5;exports.PoseJointValues=X5;exports.PresetEnvironment=gg;exports.ProgramControl=t3;exports.ProgramStateIndicator=r3;exports.Robot=v3;exports.RobotListItem=s3;exports.RobotSetupReadinessIndicator=Gf;exports.RobotSetupReadinessState=Oc;exports.SafetyBar=z3;exports.SafetyZonesRenderer=vg;exports.SelectableFab=H3;exports.SupportedRobot=Wf;exports.TrajectoryRenderer=Sg;exports.ValueInterpolator=uc;exports.VelocitySlider=Bf;exports.VelocitySliderLabel=xc;exports.WandelscriptEditor=Y3;exports.createNovaMuiTheme=Q3;exports.defaultAxisConfig=i3;exports.defaultGetModel=wc;exports.i18n=cc;exports.useAnimationFrame=xn;exports.useAutorun=Om;exports.useInterpolation=xm;exports.useMounted=Ps;exports.useReaction=wm;
|
|
155
155
|
//# sourceMappingURL=index.cjs.map
|