@wandelbots/wandelbots-js-react-components 2.27.1-pr.feature-add-program-control-component.367.cfb26c6 → 2.27.1-pr.feature-add-cycle-timer.368.7535dcc
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/CycleTimer.d.ts +79 -0
- package/dist/components/CycleTimer.d.ts.map +1 -0
- package/dist/index.cjs +89 -41
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +17207 -9385
- package/dist/index.js.map +1 -1
- package/package.json +2 -1
- package/src/components/CycleTimer.tsx +369 -0
- package/src/i18n/locales/de/translations.json +2 -4
- package/src/i18n/locales/en/translations.json +2 -4
- package/src/index.ts +1 -1
- package/dist/components/ProgramControl.d.ts +0 -43
- package/dist/components/ProgramControl.d.ts.map +0 -1
- package/src/components/ProgramControl.tsx +0 -217
package/dist/index.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";var
|
|
1
|
+
"use strict";var ty=Object.create;var wi=Object.defineProperty;var ry=Object.getOwnPropertyDescriptor;var ny=Object.getOwnPropertyNames;var ay=Object.getPrototypeOf,sy=Object.prototype.hasOwnProperty;var oy=(e,t,r)=>t in e?wi(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var iy=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of ny(t))!sy.call(e,a)&&a!==r&&wi(e,a,{get:()=>t[a],enumerable:!(n=ry(t,a))||n.enumerable});return e};var Ci=(e,t,r)=>(r=e!=null?ty(ay(e)):{},iy(t||!e||!e.__esModule?wi(r,"default",{value:e,enumerable:!0}):r,e));var la=(e,t,r)=>oy(e,typeof t!="symbol"?t+"":t,r);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const ae=require("react"),Lt=require("@react-three/drei"),ly=require("@react-three/fiber"),kt=require("three"),cy=require("three-stdlib"),W=require("@mui/material"),Je=require("mobx-react-lite"),ze=require("react-i18next"),uy=require("i18next-browser-languagedetector"),b=require("prop-types"),dy=require("@emotion/react"),hy=require("@emotion/styled"),Xe=require("mobx"),tc=require("lodash-es"),Nr=require("@wandelbots/nova-js"),ml=require("@react-spring/three"),py=require("react-error-boundary");function Pp(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 F=Pp(ae),qe=Pp(kt);function fy(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ds={exports:{}},ca={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* react-jsx-runtime.production.min.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 iu;function my(){if(iu)return ca;iu=1;var e=ae,t=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,a=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s={key:!0,ref:!0,__self:!0,__source:!0};function o(i,l,c){var u,d={},h=null,p=null;c!==void 0&&(h=""+c),l.key!==void 0&&(h=""+l.key),l.ref!==void 0&&(p=l.ref);for(u in l)n.call(l,u)&&!s.hasOwnProperty(u)&&(d[u]=l[u]);if(i&&i.defaultProps)for(u in l=i.defaultProps,l)d[u]===void 0&&(d[u]=l[u]);return{$$typeof:t,type:i,key:h,ref:p,props:d,_owner:a.current}}return ca.Fragment=r,ca.jsx=o,ca.jsxs=o,ca}var ua={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,27 +14,27 @@
|
|
|
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
|
|
18
|
-
`+
|
|
19
|
-
`),
|
|
20
|
-
`),
|
|
21
|
-
`+
|
|
17
|
+
*/var lu;function gy(){return lu||(lu=1,process.env.NODE_ENV!=="production"&&function(){var e=ae,t=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),a=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),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.offscreen"),m=Symbol.iterator,f="@@iterator";function g(w){if(w===null||typeof w!="object")return null;var Y=m&&w[m]||w[f];return typeof Y=="function"?Y:null}var S=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function T(w){{for(var Y=arguments.length,ne=new Array(Y>1?Y-1:0),de=1;de<Y;de++)ne[de-1]=arguments[de];O("error",w,ne)}}function O(w,Y,ne){{var de=S.ReactDebugCurrentFrame,Pe=de.getStackAddendum();Pe!==""&&(Y+="%s",ne=ne.concat([Pe]));var Ae=ne.map(function(Se){return String(Se)});Ae.unshift("Warning: "+Y),Function.prototype.apply.call(console[w],console,Ae)}}var C=!1,V=!1,R=!1,P=!1,E=!1,B;B=Symbol.for("react.module.reference");function y(w){return!!(typeof w=="string"||typeof w=="function"||w===n||w===s||E||w===a||w===c||w===u||P||w===p||C||V||R||typeof w=="object"&&w!==null&&(w.$$typeof===h||w.$$typeof===d||w.$$typeof===o||w.$$typeof===i||w.$$typeof===l||w.$$typeof===B||w.getModuleId!==void 0))}function A(w,Y,ne){var de=w.displayName;if(de)return de;var Pe=Y.displayName||Y.name||"";return Pe!==""?ne+"("+Pe+")":ne}function z(w){return w.displayName||"Context"}function I(w){if(w==null)return null;if(typeof w.tag=="number"&&T("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof w=="function")return w.displayName||w.name||null;if(typeof w=="string")return w;switch(w){case n:return"Fragment";case r:return"Portal";case s:return"Profiler";case a:return"StrictMode";case c:return"Suspense";case u:return"SuspenseList"}if(typeof w=="object")switch(w.$$typeof){case i:var Y=w;return z(Y)+".Consumer";case o:var ne=w;return z(ne._context)+".Provider";case l:return A(w,w.render,"ForwardRef");case d:var de=w.displayName||null;return de!==null?de:I(w.type)||"Memo";case h:{var Pe=w,Ae=Pe._payload,Se=Pe._init;try{return I(Se(Ae))}catch{return null}}}return null}var G=Object.assign,re=0,te,oe,Z,se,ge,ue,De;function ct(){}ct.__reactDisabledLog=!0;function It(){{if(re===0){te=console.log,oe=console.info,Z=console.warn,se=console.error,ge=console.group,ue=console.groupCollapsed,De=console.groupEnd;var w={configurable:!0,enumerable:!0,value:ct,writable:!0};Object.defineProperties(console,{info:w,log:w,warn:w,error:w,group:w,groupCollapsed:w,groupEnd:w})}re++}}function tt(){{if(re--,re===0){var w={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:G({},w,{value:te}),info:G({},w,{value:oe}),warn:G({},w,{value:Z}),error:G({},w,{value:se}),group:G({},w,{value:ge}),groupCollapsed:G({},w,{value:ue}),groupEnd:G({},w,{value:De})})}re<0&&T("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var St=S.ReactCurrentDispatcher,pt;function rt(w,Y,ne){{if(pt===void 0)try{throw Error()}catch(Pe){var de=Pe.stack.trim().match(/\n( *(at )?)/);pt=de&&de[1]||""}return`
|
|
18
|
+
`+pt+w}}var X=!1,ie;{var he=typeof WeakMap=="function"?WeakMap:Map;ie=new he}function J(w,Y){if(!w||X)return"";{var ne=ie.get(w);if(ne!==void 0)return ne}var de;X=!0;var Pe=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var Ae;Ae=St.current,St.current=null,It();try{if(Y){var Se=function(){throw Error()};if(Object.defineProperty(Se.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(Se,[])}catch(mt){de=mt}Reflect.construct(w,[],Se)}else{try{Se.call()}catch(mt){de=mt}w.call(Se.prototype)}}else{try{throw Error()}catch(mt){de=mt}w()}}catch(mt){if(mt&&de&&typeof mt.stack=="string"){for(var xe=mt.stack.split(`
|
|
19
|
+
`),ut=de.stack.split(`
|
|
20
|
+
`),He=xe.length-1,Qe=ut.length-1;He>=1&&Qe>=0&&xe[He]!==ut[Qe];)Qe--;for(;He>=1&&Qe>=0;He--,Qe--)if(xe[He]!==ut[Qe]){if(He!==1||Qe!==1)do if(He--,Qe--,Qe<0||xe[He]!==ut[Qe]){var Rt=`
|
|
21
|
+
`+xe[He].replace(" at new "," at ");return w.displayName&&Rt.includes("<anonymous>")&&(Rt=Rt.replace("<anonymous>",w.displayName)),typeof w=="function"&&ie.set(w,Rt),Rt}while(He>=1&&Qe>=0);break}}}finally{X=!1,St.current=Ae,tt(),Error.prepareStackTrace=Pe}var dn=w?w.displayName||w.name:"",Ir=dn?rt(dn):"";return typeof w=="function"&&ie.set(w,Ir),Ir}function Oe(w,Y,ne){return J(w,!1)}function be(w){var Y=w.prototype;return!!(Y&&Y.isReactComponent)}function Ne(w,Y,ne){if(w==null)return"";if(typeof w=="function")return J(w,be(w));if(typeof w=="string")return rt(w);switch(w){case c:return rt("Suspense");case u:return rt("SuspenseList")}if(typeof w=="object")switch(w.$$typeof){case l:return Oe(w.render);case d:return Ne(w.type,Y,ne);case h:{var de=w,Pe=de._payload,Ae=de._init;try{return Ne(Ae(Pe),Y,ne)}catch{}}}return""}var ke=Object.prototype.hasOwnProperty,_e={},Mt=S.ReactDebugCurrentFrame;function er(w){if(w){var Y=w._owner,ne=Ne(w.type,w._source,Y?Y.type:null);Mt.setExtraStackFrame(ne)}else Mt.setExtraStackFrame(null)}function on(w,Y,ne,de,Pe){{var Ae=Function.call.bind(ke);for(var Se in w)if(Ae(w,Se)){var xe=void 0;try{if(typeof w[Se]!="function"){var ut=Error((de||"React class")+": "+ne+" type `"+Se+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof w[Se]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw ut.name="Invariant Violation",ut}xe=w[Se](Y,Se,de,ne,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(He){xe=He}xe&&!(xe instanceof Error)&&(er(Pe),T("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",de||"React class",ne,Se,typeof xe),er(null)),xe instanceof Error&&!(xe.message in _e)&&(_e[xe.message]=!0,er(Pe),T("Failed %s type: %s",ne,xe.message),er(null))}}}var ln=Array.isArray;function mr(w){return ln(w)}function gr(w){{var Y=typeof Symbol=="function"&&Symbol.toStringTag,ne=Y&&w[Symbol.toStringTag]||w.constructor.name||"Object";return ne}}function cn(w){try{return Q(w),!1}catch{return!0}}function Q(w){return""+w}function ee(w){if(cn(w))return T("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",gr(w)),Q(w)}var le=S.ReactCurrentOwner,ve={key:!0,ref:!0,__self:!0,__source:!0},Ce,ce;function Ke(w){if(ke.call(w,"ref")){var Y=Object.getOwnPropertyDescriptor(w,"ref").get;if(Y&&Y.isReactWarning)return!1}return w.ref!==void 0}function at(w){if(ke.call(w,"key")){var Y=Object.getOwnPropertyDescriptor(w,"key").get;if(Y&&Y.isReactWarning)return!1}return w.key!==void 0}function Ge(w,Y){typeof w.ref=="string"&&le.current}function ft(w,Y){{var ne=function(){Ce||(Ce=!0,T("%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://reactjs.org/link/special-props)",Y))};ne.isReactWarning=!0,Object.defineProperty(w,"key",{get:ne,configurable:!0})}}function Er(w,Y){{var ne=function(){ce||(ce=!0,T("%s: `ref` 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://reactjs.org/link/special-props)",Y))};ne.isReactWarning=!0,Object.defineProperty(w,"ref",{get:ne,configurable:!0})}}var Si=function(w,Y,ne,de,Pe,Ae,Se){var xe={$$typeof:t,type:w,key:Y,ref:ne,props:Se,_owner:Ae};return xe._store={},Object.defineProperty(xe._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(xe,"_self",{configurable:!1,enumerable:!1,writable:!1,value:de}),Object.defineProperty(xe,"_source",{configurable:!1,enumerable:!1,writable:!1,value:Pe}),Object.freeze&&(Object.freeze(xe.props),Object.freeze(xe)),xe};function aa(w,Y,ne,de,Pe){{var Ae,Se={},xe=null,ut=null;ne!==void 0&&(ee(ne),xe=""+ne),at(Y)&&(ee(Y.key),xe=""+Y.key),Ke(Y)&&(ut=Y.ref,Ge(Y,Pe));for(Ae in Y)ke.call(Y,Ae)&&!ve.hasOwnProperty(Ae)&&(Se[Ae]=Y[Ae]);if(w&&w.defaultProps){var He=w.defaultProps;for(Ae in He)Se[Ae]===void 0&&(Se[Ae]=He[Ae])}if(xe||ut){var Qe=typeof w=="function"?w.displayName||w.name||"Unknown":w;xe&&ft(Se,Qe),ut&&Er(Se,Qe)}return Si(w,xe,ut,Pe,de,le.current,Se)}}var sa=S.ReactCurrentOwner,un=S.ReactDebugCurrentFrame;function zt(w){if(w){var Y=w._owner,ne=Ne(w.type,w._source,Y?Y.type:null);un.setExtraStackFrame(ne)}else un.setExtraStackFrame(null)}var oa;oa=!1;function Le(w){return typeof w=="object"&&w!==null&&w.$$typeof===t}function Ye(){{if(sa.current){var w=I(sa.current.type);if(w)return`
|
|
22
22
|
|
|
23
|
-
Check the render method of \``+
|
|
23
|
+
Check the render method of \``+w+"`."}return""}}function ia(w){return""}var _r={};function $t(w){{var Y=Ye();if(!Y){var ne=typeof w=="string"?w:w.displayName||w.name;ne&&(Y=`
|
|
24
24
|
|
|
25
|
-
Check the top-level render call using <`+
|
|
25
|
+
Check the top-level render call using <`+ne+">.")}return Y}}function nu(w,Y){{if(!w._store||w._store.validated||w.key!=null)return;w._store.validated=!0;var ne=$t(Y);if(_r[ne])return;_r[ne]=!0;var de="";w&&w._owner&&w._owner!==sa.current&&(de=" It was passed a child from "+I(w._owner.type)+"."),zt(w),T('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',ne,de),zt(null)}}function au(w,Y){{if(typeof w!="object")return;if(mr(w))for(var ne=0;ne<w.length;ne++){var de=w[ne];Le(de)&&nu(de,Y)}else if(Le(w))w._store&&(w._store.validated=!0);else if(w){var Pe=g(w);if(typeof Pe=="function"&&Pe!==w.entries)for(var Ae=Pe.call(w),Se;!(Se=Ae.next()).done;)Le(Se.value)&&nu(Se.value,Y)}}}function Jg(w){{var Y=w.type;if(Y==null||typeof Y=="string")return;var ne;if(typeof Y=="function")ne=Y.propTypes;else if(typeof Y=="object"&&(Y.$$typeof===l||Y.$$typeof===d))ne=Y.propTypes;else return;if(ne){var de=I(Y);on(ne,w.props,"prop",de,w)}else if(Y.PropTypes!==void 0&&!oa){oa=!0;var Pe=I(Y);T("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",Pe||"Unknown")}typeof Y.getDefaultProps=="function"&&!Y.getDefaultProps.isReactClassApproved&&T("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Wg(w){{for(var Y=Object.keys(w.props),ne=0;ne<Y.length;ne++){var de=Y[ne];if(de!=="children"&&de!=="key"){zt(w),T("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",de),zt(null);break}}w.ref!==null&&(zt(w),T("Invalid attribute `ref` supplied to `React.Fragment`."),zt(null))}}var su={};function ou(w,Y,ne,de,Pe,Ae){{var Se=y(w);if(!Se){var xe="";(w===void 0||typeof w=="object"&&w!==null&&Object.keys(w).length===0)&&(xe+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var ut=ia();ut?xe+=ut:xe+=Ye();var He;w===null?He="null":mr(w)?He="array":w!==void 0&&w.$$typeof===t?(He="<"+(I(w.type)||"Unknown")+" />",xe=" Did you accidentally export a JSX literal instead of a component?"):He=typeof w,T("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",He,xe)}var Qe=aa(w,Y,ne,Pe,Ae);if(Qe==null)return Qe;if(Se){var Rt=Y.children;if(Rt!==void 0)if(de)if(mr(Rt)){for(var dn=0;dn<Rt.length;dn++)au(Rt[dn],w);Object.freeze&&Object.freeze(Rt)}else T("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 au(Rt,w)}if(ke.call(Y,"key")){var Ir=I(w),mt=Object.keys(Y).filter(function(ey){return ey!=="key"}),Oi=mt.length>0?"{key: someKey, "+mt.join(": ..., ")+": ...}":"{key: someKey}";if(!su[Ir+Oi]){var Zg=mt.length>0?"{"+mt.join(": ..., ")+": ...}":"{}";T(`A props object containing a "key" prop is being spread into JSX:
|
|
26
26
|
let props = %s;
|
|
27
27
|
<%s {...props} />
|
|
28
28
|
React keys must be passed directly to JSX without using spread:
|
|
29
29
|
let props = %s;
|
|
30
|
-
<%s key={someKey} {...props} />`,
|
|
30
|
+
<%s key={someKey} {...props} />`,Oi,Ir,Zg,Ir),su[Ir+Oi]=!0}}return w===n?Wg(Qe):Jg(Qe),Qe}}function Kg(w,Y,ne){return ou(w,Y,ne,!0)}function Yg(w,Y,ne){return ou(w,Y,ne,!1)}var Qg=Yg,Xg=Kg;ua.Fragment=n,ua.jsx=Qg,ua.jsxs=Xg}()),ua}var cu;function yy(){return cu||(cu=1,process.env.NODE_ENV==="production"?ds.exports=my():ds.exports=gy()),ds.exports}var x=yy();function by(){return x.jsx(Lt.Environment,{children:x.jsx(vy,{})})}function vy({positions:e=[2,0,2,0,2,0,2,0]}){return x.jsxs(x.Fragment,{children:[x.jsx(Lt.Lightformer,{intensity:5,"rotation-x":Math.PI/2,position:[0,5,-9],scale:[10,10,1]}),x.jsx("group",{rotation:[0,.5,0],children:x.jsx("group",{children:e.map((t,r)=>x.jsx(Lt.Lightformer,{form:"circle",intensity:5,rotation:[Math.PI/2,0,0],position:[t,4,r*4],scale:[3,1,1]},r))})}),x.jsx(Lt.Lightformer,{intensity:40,"rotation-y":Math.PI/2,position:[-5,1,-1],scale:[20,.1,1]}),x.jsx(Lt.Lightformer,{intensity:20,"rotation-y":-Math.PI,position:[-5,-2,-1],scale:[20,.1,1]}),x.jsx(Lt.Lightformer,{"rotation-y":Math.PI/2,position:[-5,-1,-1],scale:[20,.5,1],intensity:5}),x.jsx(Lt.Lightformer,{"rotation-y":-Math.PI/2,position:[10,1,0],scale:[20,1,1],intensity:10}),x.jsx(Lt.Lightformer,{form:"ring",color:"white",intensity:5,scale:10,position:[-15,4,-18],target:[0,0,0]})]})}function xy(e){if(e.length<3)return console.log("Not enough vertices to define a plane"),{isCoplanar:!1};const t=new qe.Vector3(e[0].x,e[0].y,e[0].z),r=new qe.Vector3(e[1].x,e[1].y,e[1].z),n=new qe.Vector3(e[2].x,e[2].y,e[2].z),a=new qe.Vector3().subVectors(r,t),s=new qe.Vector3().subVectors(n,t),o=new qe.Vector3().crossVectors(a,s).normalize();for(let i=3;i<e.length;i++){const l=new qe.Vector3(e[i].x,e[i].y,e[i].z),c=new qe.Vector3().subVectors(l,t),u=o.dot(c);if(Math.abs(u)>1e-6)return console.log("Vertices are not on the same plane"),{isCoplanar:!1}}return{isCoplanar:!0,normal:o}}function Sy({safetyZones:e,...t}){return x.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((s,o)=>{if(!s.convex_hull)return null;const i=s.convex_hull.vertices.map(u=>new qe.Vector3(u.x/1e3,u.y/1e3,u.z/1e3)),l=xy(i);if(l.isCoplanar&&l.normal){const d=new qe.Vector3().addVectors(i[0],l.normal.multiplyScalar(1e-4));i.push(d)}let c;try{c=new cy.ConvexGeometry(i)}catch(u){return console.log("Error creating ConvexGeometry:",u),null}return x.jsx("mesh",{geometry:c,children:x.jsx("meshStandardMaterial",{attach:"material",color:"#009f4d",opacity:.2,depthTest:!1,depthWrite:!1,transparent:!0,polygonOffset:!0,polygonOffsetFactor:-o},n)},`${n}-${o}`)})})})}function Oy({trajectory:e,...t}){var n;const r=((n=e.trajectory)==null?void 0:n.map(a=>a.tcp_pose?new qe.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 x.jsx("group",{...t,children:r.length>0&&x.jsx(Lt.Line,{points:r,lineWidth:3,polygonOffset:!0,polygonOffsetFactor:10,polygonOffsetUnits:10})})}function K(){return K=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},K.apply(null,arguments)}function Cr(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 wy(e,t,r=void 0){const n={};for(const a in e){const s=e[a];let o="",i=!0;for(let l=0;l<s.length;l+=1){const c=s[l];c&&(o+=(i===!0?"":" ")+t(c),i=!1,r&&r[c]&&(o+=" "+r[c]))}n[a]=o}return n}function Rp(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=Rp(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function Nt(){for(var e,t,r=0,n="",a=arguments.length;r<a;r++)(e=arguments[r])&&(t=Rp(e))&&(n&&(n+=" "),n+=t);return n}function Pr(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 Tp="$$material";function Cy(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 Py={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 Ry(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var Ty=/[A-Z]|^ms/g,Ay=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Ap=function(t){return t.charCodeAt(1)===45},uu=function(t){return t!=null&&typeof t!="boolean"},Pi=Ry(function(e){return Ap(e)?e:e.replace(Ty,"-$&").toLowerCase()}),du=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(Ay,function(n,a,s){return Or={name:a,styles:s,next:Or},a})}return Py[t]!==1&&!Ap(t)&&typeof r=="number"&&r!==0?r+"px":r};function Ys(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 Or={name:a.name,styles:a.styles,next:Or},a.name;var s=r;if(s.styles!==void 0){var o=s.next;if(o!==void 0)for(;o!==void 0;)Or={name:o.name,styles:o.styles,next:Or},o=o.next;var i=s.styles+";";return i}return Vy(e,t,r)}}var l=r;return l}function Vy(e,t,r){var n="";if(Array.isArray(r))for(var a=0;a<r.length;a++)n+=Ys(e,t,r[a])+";";else for(var s in r){var o=r[s];if(typeof o!="object"){var i=o;uu(i)&&(n+=Pi(s)+":"+du(s,i)+";")}else if(Array.isArray(o)&&typeof o[0]=="string"&&t==null)for(var l=0;l<o.length;l++)uu(o[l])&&(n+=Pi(s)+":"+du(s,o[l])+";");else{var c=Ys(e,t,o);switch(s){case"animation":case"animationName":{n+=Pi(s)+":"+c+";";break}default:n+=s+"{"+c+"}"}}}return n}var hu=/label:\s*([^\s;{]+)\s*(;|$)/g,Or;function Ey(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="";Or=void 0;var s=e[0];if(s==null||s.raw===void 0)n=!1,a+=Ys(r,t,s);else{var o=s;a+=o[0]}for(var i=1;i<e.length;i++)if(a+=Ys(r,t,e[i]),n){var l=s;a+=l[i]}hu.lastIndex=0;for(var c="",u;(u=hu.exec(a))!==null;)c+="-"+u[1];var d=Cy(a)+c;return{name:d,styles:a,next:Or}}/**
|
|
31
31
|
* @mui/styled-engine v6.4.6
|
|
32
32
|
*
|
|
33
33
|
* @license MIT
|
|
34
34
|
* This source code is licensed under the MIT license found in the
|
|
35
35
|
* LICENSE file in the root directory of this source tree.
|
|
36
|
-
*/function
|
|
37
|
-
`)):
|
|
36
|
+
*/function _y(e,t){const r=hy(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(`
|
|
37
|
+
`)):n.some(s=>s===void 0)&&console.error(`MUI: the styled(${a})(...args) API requires all its args to be defined.`),r(...n)}:r}function Iy(e,t){Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))}const pu=[];function fu(e){return pu[0]=e,Ey(pu)}var hs={exports:{}},Re={};/**
|
|
38
38
|
* @license React
|
|
39
39
|
* react-is.production.js
|
|
40
40
|
*
|
|
@@ -42,7 +42,7 @@ 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
|
|
45
|
+
*/var mu;function My(){if(mu)return Re;mu=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"),s=Symbol.for("react.consumer"),o=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 m(f){if(typeof f=="object"&&f!==null){var g=f.$$typeof;switch(g){case e:switch(f=f.type,f){case r:case a:case n:case l:case c:case h:return f;default:switch(f=f&&f.$$typeof,f){case o:case i:case d:case u:return f;case s:return f;default:return g}}case t:return g}}}return Re.ContextConsumer=s,Re.ContextProvider=o,Re.Element=e,Re.ForwardRef=i,Re.Fragment=r,Re.Lazy=d,Re.Memo=u,Re.Portal=t,Re.Profiler=a,Re.StrictMode=n,Re.Suspense=l,Re.SuspenseList=c,Re.isContextConsumer=function(f){return m(f)===s},Re.isContextProvider=function(f){return m(f)===o},Re.isElement=function(f){return typeof f=="object"&&f!==null&&f.$$typeof===e},Re.isForwardRef=function(f){return m(f)===i},Re.isFragment=function(f){return m(f)===r},Re.isLazy=function(f){return m(f)===d},Re.isMemo=function(f){return m(f)===u},Re.isPortal=function(f){return m(f)===t},Re.isProfiler=function(f){return m(f)===a},Re.isStrictMode=function(f){return m(f)===n},Re.isSuspense=function(f){return m(f)===l},Re.isSuspenseList=function(f){return m(f)===c},Re.isValidElementType=function(f){return typeof f=="string"||typeof f=="function"||f===r||f===a||f===n||f===l||f===c||typeof f=="object"&&f!==null&&(f.$$typeof===d||f.$$typeof===u||f.$$typeof===o||f.$$typeof===s||f.$$typeof===i||f.$$typeof===p||f.getModuleId!==void 0)},Re.typeOf=m,Re}var Te={};/**
|
|
46
46
|
* @license React
|
|
47
47
|
* react-is.development.js
|
|
48
48
|
*
|
|
@@ -50,19 +50,19 @@ React keys must be passed directly to JSX without using spread:
|
|
|
50
50
|
*
|
|
51
51
|
* This source code is licensed under the MIT license found in the
|
|
52
52
|
* LICENSE file in the root directory of this source tree.
|
|
53
|
-
*/var
|
|
54
|
-
For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:
|
|
53
|
+
*/var gu;function $y(){return gu||(gu=1,process.env.NODE_ENV!=="production"&&function(){function e(f){if(typeof f=="object"&&f!==null){var g=f.$$typeof;switch(g){case t:switch(f=f.type,f){case n:case s:case a:case c:case u:case p:return f;default:switch(f=f&&f.$$typeof,f){case i:case l:case h:case d:return f;case o:return f;default:return g}}case r:return g}}}var t=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),a=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),o=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"),m=Symbol.for("react.client.reference");Te.ContextConsumer=o,Te.ContextProvider=i,Te.Element=t,Te.ForwardRef=l,Te.Fragment=n,Te.Lazy=h,Te.Memo=d,Te.Portal=r,Te.Profiler=s,Te.StrictMode=a,Te.Suspense=c,Te.SuspenseList=u,Te.isContextConsumer=function(f){return e(f)===o},Te.isContextProvider=function(f){return e(f)===i},Te.isElement=function(f){return typeof f=="object"&&f!==null&&f.$$typeof===t},Te.isForwardRef=function(f){return e(f)===l},Te.isFragment=function(f){return e(f)===n},Te.isLazy=function(f){return e(f)===h},Te.isMemo=function(f){return e(f)===d},Te.isPortal=function(f){return e(f)===r},Te.isProfiler=function(f){return e(f)===s},Te.isStrictMode=function(f){return e(f)===a},Te.isSuspense=function(f){return e(f)===c},Te.isSuspenseList=function(f){return e(f)===u},Te.isValidElementType=function(f){return typeof f=="string"||typeof f=="function"||f===n||f===s||f===a||f===c||f===u||typeof f=="object"&&f!==null&&(f.$$typeof===h||f.$$typeof===d||f.$$typeof===i||f.$$typeof===o||f.$$typeof===l||f.$$typeof===m||f.getModuleId!==void 0)},Te.typeOf=e}()),Te}var yu;function jy(){return yu||(yu=1,process.env.NODE_ENV==="production"?hs.exports=My():hs.exports=$y()),hs.exports}var Qs=jy();function Wt(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 Vp(e){if(F.isValidElement(e)||Qs.isValidElementType(e)||!Wt(e))return e;const t={};return Object.keys(e).forEach(r=>{t[r]=Vp(e[r])}),t}function ht(e,t,r={clone:!0}){const n=r.clone?{...e}:e;return Wt(e)&&Wt(t)&&Object.keys(t).forEach(a=>{F.isValidElement(t[a])||Qs.isValidElementType(t[a])?n[a]=t[a]:Wt(t[a])&&Object.prototype.hasOwnProperty.call(e,a)&&Wt(e[a])?n[a]=ht(e[a],t[a],r):r.clone?n[a]=Wt(t[a])?Vp(t[a]):t[a]:n[a]=t[a]}),n}const ky=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 Ly(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:r="px",step:n=5,...a}=e,s=ky(t),o=Object.keys(s);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 m=o.indexOf(p);return`@media (min-width:${typeof t[h]=="number"?t[h]:h}${r}) and (max-width:${(m!==-1&&typeof t[o[m]]=="number"?t[o[m]]:p)-n/100}${r})`}function u(h){return o.indexOf(h)+1<o.length?c(h,o[o.indexOf(h)+1]):i(h)}function d(h){const p=o.indexOf(h);return p===0?i(o[1]):p===o.length-1?l(o[p]):c(h,o[o.indexOf(h)+1]).replace("@media","@media not all and")}return{keys:o,values:s,up:i,down:l,between:c,only:u,not:d,unit:r,...a}}function Uy(e,t){if(!e.containerQueries)return t;const r=Object.keys(t).filter(n=>n.startsWith("@container")).sort((n,a)=>{var o,i;const s=/min-width:\s*([0-9.]+)/;return+(((o=n.match(s))==null?void 0:o[1])||0)-+(((i=a.match(s))==null?void 0:i[1])||0)});return r.length?r.reduce((n,a)=>{const s=t[a];return delete n[a],n[a]=s,n},{...t}):t}function Dy(e,t){return t==="@"||t.startsWith("@")&&(e.some(r=>t.startsWith(`@${r}`))||!!t.match(/^@\d/))}function Ny(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>\`.
|
|
54
|
+
For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:Pr(18,`(${t})`));return null}const[,n,a]=r,s=Number.isNaN(+n)?n||0:+n;return e.containerQueries(a).up(s)}function Fy(e){const t=(s,o)=>s.replace("@media",o?`@container ${o}`:"@container");function r(s,o){s.up=(...i)=>t(e.breakpoints.up(...i),o),s.down=(...i)=>t(e.breakpoints.down(...i),o),s.between=(...i)=>t(e.breakpoints.between(...i),o),s.only=(...i)=>t(e.breakpoints.only(...i),o),s.not=(...i)=>{const l=t(e.breakpoints.not(...i),o);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=s=>(r(n,s),n);return r(a),{...e,containerQueries:a}}const By={borderRadius:4},Ar=process.env.NODE_ENV!=="production"?b.oneOfType([b.number,b.string,b.object,b.array]):{};function _a(e,t){return t?ht(e,t,{clone:!1}):e}const Ao={xs:0,sm:600,md:900,lg:1200,xl:1536},bu={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${Ao[e]}px)`},zy={containerQueries:e=>({up:t=>{let r=typeof t=="number"?t:Ao[t]||t;return typeof r=="number"&&(r=`${r}px`),e?`@container ${e} (min-width:${r})`:`@container (min-width:${r})`}})};function Ft(e,t,r){const n=e.theme||{};if(Array.isArray(t)){const s=n.breakpoints||bu;return t.reduce((o,i,l)=>(o[s.up(s.keys[l])]=r(t[l]),o),{})}if(typeof t=="object"){const s=n.breakpoints||bu;return Object.keys(t).reduce((o,i)=>{if(Dy(s.keys,i)){const l=Ny(n.containerQueries?n:zy,i);l&&(o[l]=r(t[i],i))}else if(Object.keys(s.values||Ao).includes(i)){const l=s.up(i);o[l]=r(t[i],i)}else{const l=i;o[l]=t[l]}return o},{})}return r(t)}function Ep(e={}){var r;return((r=e.keys)==null?void 0:r.reduce((n,a)=>{const s=e.up(a);return n[s]={},n},{}))||{}}function _p(e,t){return e.reduce((r,n)=>{const a=r[n];return(!a||Object.keys(a).length===0)&&delete r[n],r},t)}function Gy(e,...t){const r=Ep(e),n=[r,...t].reduce((a,s)=>ht(a,s),{});return _p(Object.keys(r),n)}function Hy(e,t){if(typeof e!="object")return{};const r={},n=Object.keys(t);return Array.isArray(e)?n.forEach((a,s)=>{s<e.length&&(r[a]=!0)}):n.forEach(a=>{e[a]!=null&&(r[a]=!0)}),r}function Ri({values:e,breakpoints:t,base:r}){const n=r||Hy(e,t),a=Object.keys(n);if(a.length===0)return e;let s;return a.reduce((o,i,l)=>(Array.isArray(e)?(o[i]=e[l]!=null?e[l]:e[s],s=l):typeof e=="object"?(o[i]=e[i]!=null?e[i]:e[s],s=i):o[i]=e,o),{})}function dt(e){if(typeof e!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":Pr(7));return e.charAt(0).toUpperCase()+e.slice(1)}function Vo(e,t,r=!0){if(!t||typeof t!="string")return null;if(e&&e.vars&&r){const n=`vars.${t}`.split(".").reduce((a,s)=>a&&a[s]?a[s]:null,e);if(n!=null)return n}return t.split(".").reduce((n,a)=>n&&n[a]!=null?n[a]:null,e)}function Xs(e,t,r,n=r){let a;return typeof e=="function"?a=e(r):Array.isArray(e)?a=e[r]||n:a=Vo(e,r)||n,t&&(a=t(a,n,e)),a}function We(e){const{prop:t,cssProperty:r=e.prop,themeKey:n,transform:a}=e,s=o=>{if(o[t]==null)return null;const i=o[t],l=o.theme,c=Vo(l,n)||{};return Ft(o,i,d=>{let h=Xs(c,a,d);return d===h&&typeof d=="string"&&(h=Xs(c,a,`${t}${d==="default"?"":dt(d)}`,d)),r===!1?h:{[r]:h}})};return s.propTypes=process.env.NODE_ENV!=="production"?{[t]:Ar}:{},s.filterProps=[t],s}function qy(e){const t={};return r=>(t[r]===void 0&&(t[r]=e(r)),t[r])}const Jy={m:"margin",p:"padding"},Wy={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},vu={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},Ky=qy(e=>{if(e.length>2)if(vu[e])e=vu[e];else return[e];const[t,r]=e.split(""),n=Jy[t],a=Wy[r]||"";return Array.isArray(a)?a.map(s=>n+s):[n+a]}),Eo=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],_o=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],Yy=[...Eo,..._o];function Za(e,t,r,n){const a=Vo(e,t,!0)??r;return typeof a=="number"||typeof a=="string"?s=>typeof s=="string"?s:(process.env.NODE_ENV!=="production"&&typeof s!="number"&&console.error(`MUI: Expected ${n} argument to be a number or a string, got ${s}.`),typeof a=="string"?`calc(${s} * ${a})`:a*s):Array.isArray(a)?s=>{if(typeof s=="string")return s;const o=Math.abs(s);process.env.NODE_ENV!=="production"&&(Number.isInteger(o)?o>a.length-1&&console.error([`MUI: The value provided (${o}) overflows.`,`The supported values are: ${JSON.stringify(a)}.`,`${o} > ${a.length-1}, you need to add the missing values.`].join(`
|
|
55
55
|
`)):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(`
|
|
56
|
-
`)));const i=
|
|
57
|
-
`)),()=>{})}function Un(e){return ka(e,"spacing",8,"spacing")}function cr(e,t){return typeof t=="string"||t==null?t:e(t)}function $u(e,t){return r=>e.reduce((a,n)=>(a[n]=cr(t,r),a),{})}function Uu(e,t,r,a){if(!t.includes(r))return null;const n=Mu(r),o=$u(n,a),s=e[r];return ft(e,s,o)}function Dl(e,t){const r=Un(e.theme);return Object.keys(e).map(a=>Uu(e,t,a,r)).reduce(Ca,{})}function _e(e){return Dl(e,jn)}_e.propTypes=process.env.NODE_ENV!=="production"?jn.reduce((e,t)=>(e[t]=Zt,e),{}):{};_e.filterProps=jn;function Ae(e){return Dl(e,$n)}Ae.propTypes=process.env.NODE_ENV!=="production"?$n.reduce((e,t)=>(e[t]=Zt,e),{}):{};Ae.filterProps=$n;process.env.NODE_ENV!=="production"&&ju.reduce((e,t)=>(e[t]=Zt,e),{});function zl(e=8,t=Un({spacing:e})){if(e.mui)return e;const r=(...a)=>(process.env.NODE_ENV!=="production"&&(a.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${a.length}`)),(a.length===0?[1]:a).map(o=>{const s=t(o);return typeof s=="number"?`${s}px`:s}).join(" "));return r.mui=!0,r}function Ln(...e){const t=e.reduce((a,n)=>(n.filterProps.forEach(o=>{a[o]=n}),a),{}),r=a=>Object.keys(a).reduce((n,o)=>t[o]?Ca(n,t[o](a)):n,{});return r.propTypes=process.env.NODE_ENV!=="production"?e.reduce((a,n)=>Object.assign(a,n.propTypes),{}):{},r.filterProps=e.reduce((a,n)=>a.concat(n.filterProps),[]),r}function it(e){return typeof e!="number"?e:`${e}px solid`}function ct(e,t){return $e({prop:e,themeKey:"borders",transform:t})}const Lu=ct("border",it),ku=ct("borderTop",it),Bu=ct("borderRight",it),Fu=ct("borderBottom",it),Nu=ct("borderLeft",it),Du=ct("borderColor"),zu=ct("borderTopColor"),Gu=ct("borderRightColor"),Ju=ct("borderBottomColor"),Hu=ct("borderLeftColor"),qu=ct("outline",it),Wu=ct("outlineColor"),kn=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=ka(e.theme,"shape.borderRadius",4,"borderRadius"),r=a=>({borderRadius:cr(t,a)});return ft(e,e.borderRadius,r)}return null};kn.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:Zt}:{};kn.filterProps=["borderRadius"];Ln(Lu,ku,Bu,Fu,Nu,Du,zu,Gu,Ju,Hu,kn,qu,Wu);const Bn=e=>{if(e.gap!==void 0&&e.gap!==null){const t=ka(e.theme,"spacing",8,"gap"),r=a=>({gap:cr(t,a)});return ft(e,e.gap,r)}return null};Bn.propTypes=process.env.NODE_ENV!=="production"?{gap:Zt}:{};Bn.filterProps=["gap"];const Fn=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=ka(e.theme,"spacing",8,"columnGap"),r=a=>({columnGap:cr(t,a)});return ft(e,e.columnGap,r)}return null};Fn.propTypes=process.env.NODE_ENV!=="production"?{columnGap:Zt}:{};Fn.filterProps=["columnGap"];const Nn=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=ka(e.theme,"spacing",8,"rowGap"),r=a=>({rowGap:cr(t,a)});return ft(e,e.rowGap,r)}return null};Nn.propTypes=process.env.NODE_ENV!=="production"?{rowGap:Zt}:{};Nn.filterProps=["rowGap"];const Ku=$e({prop:"gridColumn"}),Qu=$e({prop:"gridRow"}),Yu=$e({prop:"gridAutoFlow"}),Xu=$e({prop:"gridAutoColumns"}),Zu=$e({prop:"gridAutoRows"}),ep=$e({prop:"gridTemplateColumns"}),tp=$e({prop:"gridTemplateRows"}),rp=$e({prop:"gridTemplateAreas"}),ap=$e({prop:"gridArea"});Ln(Bn,Fn,Nn,Ku,Qu,Yu,Xu,Zu,ep,tp,rp,ap);function Dr(e,t){return t==="grey"?t:e}const np=$e({prop:"color",themeKey:"palette",transform:Dr}),op=$e({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Dr}),sp=$e({prop:"backgroundColor",themeKey:"palette",transform:Dr});Ln(np,op,sp);function rt(e){return e<=1&&e!==0?`${e*100}%`:e}const ip=$e({prop:"width",transform:rt}),us=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=r=>{var n,o,s,i,l;const a=((s=(o=(n=e.theme)==null?void 0:n.breakpoints)==null?void 0:o.values)==null?void 0:s[r])||In[r];return a?((l=(i=e.theme)==null?void 0:i.breakpoints)==null?void 0:l.unit)!=="px"?{maxWidth:`${a}${e.theme.breakpoints.unit}`}:{maxWidth:a}:{maxWidth:rt(r)}};return ft(e,e.maxWidth,t)}return null};us.filterProps=["maxWidth"];const lp=$e({prop:"minWidth",transform:rt}),cp=$e({prop:"height",transform:rt}),dp=$e({prop:"maxHeight",transform:rt}),up=$e({prop:"minHeight",transform:rt});$e({prop:"size",cssProperty:"width",transform:rt});$e({prop:"size",cssProperty:"height",transform:rt});const pp=$e({prop:"boxSizing"});Ln(ip,us,lp,cp,dp,up,pp);const Ba={border:{themeKey:"borders",transform:it},borderTop:{themeKey:"borders",transform:it},borderRight:{themeKey:"borders",transform:it},borderBottom:{themeKey:"borders",transform:it},borderLeft:{themeKey:"borders",transform:it},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:it},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:kn},color:{themeKey:"palette",transform:Dr},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Dr},backgroundColor:{themeKey:"palette",transform:Dr},p:{style:Ae},pt:{style:Ae},pr:{style:Ae},pb:{style:Ae},pl:{style:Ae},px:{style:Ae},py:{style:Ae},padding:{style:Ae},paddingTop:{style:Ae},paddingRight:{style:Ae},paddingBottom:{style:Ae},paddingLeft:{style:Ae},paddingX:{style:Ae},paddingY:{style:Ae},paddingInline:{style:Ae},paddingInlineStart:{style:Ae},paddingInlineEnd:{style:Ae},paddingBlock:{style:Ae},paddingBlockStart:{style:Ae},paddingBlockEnd:{style:Ae},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:Bn},rowGap:{style:Nn},columnGap:{style:Fn},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:rt},maxWidth:{style:us},minWidth:{transform:rt},height:{transform:rt},maxHeight:{transform:rt},minHeight:{transform:rt},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 hp(...e){const t=e.reduce((a,n)=>a.concat(Object.keys(n)),[]),r=new Set(t);return e.every(a=>r.size===Object.keys(a).length)}function mp(e,t){return typeof e=="function"?e(t):e}function fp(){function e(r,a,n,o){const s={[r]:a,theme:n},i=o[r];if(!i)return{[r]:a};const{cssProperty:l=r,themeKey:c,transform:d,style:u}=i;if(a==null)return null;if(c==="typography"&&a==="inherit")return{[r]:a};const p=Mn(n,c)||{};return u?u(s):ft(s,a,g=>{let h=Sn(p,d,g);return g===h&&typeof g=="string"&&(h=Sn(p,d,`${r}${g==="default"?"":We(g)}`,g)),l===!1?h:{[l]:h}})}function t(r){const{sx:a,theme:n={}}=r||{};if(!a)return null;const o=n.unstable_sxConfig??Ba;function s(i){let l=i;if(typeof i=="function")l=i(n);else if(typeof i!="object")return i;if(!l)return null;const c=Fl(n.breakpoints),d=Object.keys(c);let u=c;return Object.keys(l).forEach(p=>{const m=mp(l[p],n);if(m!=null)if(typeof m=="object")if(o[p])u=Ca(u,e(p,m,n,o));else{const g=ft({theme:n},m,h=>({[p]:h}));hp(g,m)?u[p]=t({sx:m,theme:n}):u=Ca(u,g)}else u=Ca(u,e(p,m,n,o))}),Ou(n,Nl(d,u))}return Array.isArray(a)?a.map(s):s(a)}return t}const Hr=fp();Hr.filterProps=["sx"];function gp(e,t){var a;const r=this;if(r.vars){if(!((a=r.colorSchemes)!=null&&a[e])||typeof r.getColorSchemeSelector!="function")return{};let n=r.getColorSchemeSelector(e);return n==="&"?t:((n.includes("data-")||n.includes("."))&&(n=`*:where(${n.replace(/\s*&$/,"")}) &`),{[n]:t})}return r.palette.mode===e?t:{}}function Dn(e={},...t){const{breakpoints:r={},palette:a={},spacing:n,shape:o={},...s}=e,i=xu(r),l=zl(n);let c=Ke({breakpoints:i,direction:"ltr",components:{},palette:{mode:"light",...a},spacing:l,shape:{...Vu,...o}},s);return c=Pu(c),c.applyStyles=gp,c=t.reduce((d,u)=>Ke(d,u),c),c.unstable_sxConfig={...Ba,...s==null?void 0:s.unstable_sxConfig},c.unstable_sx=function(u){return Hr({sx:u,theme:this})},c}function yp(e){return Object.keys(e).length===0}function bp(e=null){const t=H.useContext(Xd.ThemeContext);return!t||yp(t)?e:t}const Sp=Dn();function vp(e=Sp){return bp(e)}const xp=e=>{var a;const t={systemProps:{},otherProps:{}},r=((a=e==null?void 0:e.theme)==null?void 0:a.unstable_sxConfig)??Ba;return Object.keys(e).forEach(n=>{r[n]?t.systemProps[n]=e[n]:t.otherProps[n]=e[n]}),t};function Op(e){const{sx:t,...r}=e,{systemProps:a,otherProps:n}=xp(r);let o;return Array.isArray(t)?o=[a,...t]:typeof t=="function"?o=(...s)=>{const i=t(...s);return Ot(i)?{...a,...i}:a}:o={...a,...t},{...n,sx:o}}const Hs=e=>e,wp=()=>{let e=Hs;return{configure(t){e=t},generate(t){return e(t)},reset(){e=Hs}}},Cp=wp();function Gl(e){var t,r,a="";if(typeof e=="string"||typeof e=="number")a+=e;else if(typeof e=="object")if(Array.isArray(e)){var n=e.length;for(t=0;t<n;t++)e[t]&&(r=Gl(e[t]))&&(a&&(a+=" "),a+=r)}else for(r in e)e[r]&&(a&&(a+=" "),a+=r);return a}function Pt(){for(var e,t,r=0,a="",n=arguments.length;r<n;r++)(e=arguments[r])&&(t=Gl(e))&&(a&&(a+=" "),a+=t);return a}const Pp={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 Fa(e,t,r="Mui"){const a=Pp[t];return a?`${r}-${a}`:`${Cp.generate(e)}-${t}`}function Jl(e,t,r="Mui"){const a={};return t.forEach(n=>{a[n]=Fa(e,n,r)}),a}function Hl(e,t=""){return e.displayName||e.name||t}function qs(e,t,r){const a=Hl(t);return e.displayName||(a!==""?`${r}(${a})`:r)}function Vp(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return Hl(e,"Component");if(typeof e=="object")switch(e.$$typeof){case bn.ForwardRef:return qs(e,e.render,"ForwardRef");case bn.Memo:return qs(e,e.type,"memo");default:return}}}function ql(e){const{variants:t,...r}=e,a={variants:t,style:Fs(r),isProcessed:!0};return a.style===r||t&&t.forEach(n=>{typeof n.style!="function"&&(n.style=Fs(n.style))}),a}const Rp=Dn();function fo(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}function _p(e){return e?(t,r)=>r[e]:null}function Ap(e,t,r){e.theme=Ip(e.theme)?r:e.theme[t]||e.theme}function dn(e,t){const r=typeof t=="function"?t(e):t;if(Array.isArray(r))return r.flatMap(a=>dn(e,a));if(Array.isArray(r==null?void 0:r.variants)){let a;if(r.isProcessed)a=r.style;else{const{variants:n,...o}=r;a=o}return Wl(e,r.variants,[a])}return r!=null&&r.isProcessed?r.style:r}function Wl(e,t,r=[]){var n;let a;e:for(let o=0;o<t.length;o+=1){const s=t[o];if(typeof s.props=="function"){if(a??(a={...e,...e.ownerState,ownerState:e.ownerState}),!s.props(a))continue}else for(const i in s.props)if(e[i]!==s.props[i]&&((n=e.ownerState)==null?void 0:n[i])!==s.props[i])continue e;typeof s.style=="function"?(a??(a={...e,...e.ownerState,ownerState:e.ownerState}),r.push(s.style(a))):r.push(s.style)}return r}function Kl(e={}){const{themeId:t,defaultTheme:r=Rp,rootShouldForwardProp:a=fo,slotShouldForwardProp:n=fo}=e;function o(i){Ap(i,t,r)}return(i,l={})=>{gu(i,J=>J.filter(K=>K!==Hr));const{name:c,slot:d,skipVariantsResolver:u,skipSx:p,overridesResolver:m=_p(Ql(d)),...g}=l,h=u!==void 0?u:d&&d!=="Root"&&d!=="root"||!1,x=p||!1;let E=fo;d==="Root"||d==="root"?E=a:d?E=n:Mp(i)&&(E=void 0);const U=fu(i,{shouldForwardProp:E,label:Ep(c,d),...g}),F=J=>{if(typeof J=="function"&&J.__emotion_real!==J)return function(j){return dn(j,J)};if(Ot(J)){const K=ql(J);return K.variants?function(L){return dn(L,K)}:K.style}return J},N=(...J)=>{const K=[],j=J.map(F),L=[];if(K.push(o),c&&m&&L.push(function(B){var Z,xe;const D=(xe=(Z=B.theme.components)==null?void 0:Z[c])==null?void 0:xe.styleOverrides;if(!D)return null;const re={};for(const X in D)re[X]=dn(B,D[X]);return m(B,re)}),c&&!h&&L.push(function(B){var re,Z;const G=B.theme,D=(Z=(re=G==null?void 0:G.components)==null?void 0:re[c])==null?void 0:Z.variants;return D?Wl(B,D):null}),x||L.push(Hr),Array.isArray(j[0])){const M=j.shift(),B=new Array(K.length).fill(""),G=new Array(L.length).fill("");let D;D=[...B,...M,...G],D.raw=[...B,...M.raw,...G],K.unshift(D)}const k=[...K,...j,...L],y=U(...k);return i.muiName&&(y.muiName=i.muiName),process.env.NODE_ENV!=="production"&&(y.displayName=Tp(c,d,i)),y};return U.withConfig&&(N.withConfig=U.withConfig),N}}function Tp(e,t,r){return e?`${e}${We(t||"")}`:`Styled(${Vp(r)})`}function Ep(e,t){let r;return process.env.NODE_ENV!=="production"&&e&&(r=`${e}-${Ql(t||"Root")}`),r}function Ip(e){for(const t in e)return!1;return!0}function Mp(e){return typeof e=="string"&&e.charCodeAt(0)>96}function Ql(e){return e&&e.charAt(0).toLowerCase()+e.slice(1)}const jp=Kl();function vn(e,t){const r={...t};for(const a in e)if(Object.prototype.hasOwnProperty.call(e,a)){const n=a;if(n==="components"||n==="slots")r[n]={...e[n],...r[n]};else if(n==="componentsProps"||n==="slotProps"){const o=e[n],s=t[n];if(!s)r[n]=o||{};else if(!o)r[n]=s;else{r[n]={...s};for(const i in o)if(Object.prototype.hasOwnProperty.call(o,i)){const l=i;r[n][l]=vn(o[l],s[l])}}}else r[n]===void 0&&(r[n]=e[n])}return r}function $p(e){const{theme:t,name:r,props:a}=e;return!t||!t.components||!t.components[r]||!t.components[r].defaultProps?a:vn(t.components[r].defaultProps,a)}function Up({props:e,name:t,defaultTheme:r,themeId:a}){let n=vp(r);return a&&(n=n[a]||n),$p({theme:n,name:t,props:e})}const Yl=typeof window<"u"?H.useLayoutEffect:H.useEffect;function Fr(e,t=Number.MIN_SAFE_INTEGER,r=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,r))}function ps(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}].`),Fr(e,t,r)}function Lp(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(a=>a+a)),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((a,n)=>n<3?parseInt(a,16):Math.round(parseInt(a,16)/255*1e3)/1e3).join(", ")})`:""}function Yt(e){if(e.type)return e;if(e.charAt(0)==="#")return Yt(Lp(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.
|
|
58
|
-
The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:
|
|
59
|
-
The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:
|
|
60
|
-
`))},[
|
|
61
|
-
`))},[JSON.stringify(t)])}const l=
|
|
62
|
-
`))}return!1}const Dp={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"};function hs(e,t,r=void 0){const a={};for(const n in e){const o=e[n];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]))}a[n]=s}return a}function zp(e){return typeof e=="string"}function Gp(e,t,r){return e===void 0||zp(e)?t:{...t,ownerState:{...t.ownerState,...r}}}function pn(e,t=[]){if(e===void 0)return{};const r={};return Object.keys(e).filter(a=>a.match(/^on[A-Z]/)&&typeof e[a]=="function"&&!t.includes(a)).forEach(a=>{r[a]=e[a]}),r}function Ys(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 Jp(e){const{getSlotProps:t,additionalProps:r,externalSlotProps:a,externalForwardedProps:n,className:o}=e;if(!t){const m=Pt(r==null?void 0:r.className,o,n==null?void 0:n.className,a==null?void 0:a.className),g={...r==null?void 0:r.style,...n==null?void 0:n.style,...a==null?void 0:a.style},h={...r,...n,...a};return m.length>0&&(h.className=m),Object.keys(g).length>0&&(h.style=g),{props:h,internalRef:void 0}}const s=pn({...n,...a}),i=Ys(a),l=Ys(n),c=t(s),d=Pt(c==null?void 0:c.className,r==null?void 0:r.className,o,n==null?void 0:n.className,a==null?void 0:a.className),u={...c==null?void 0:c.style,...r==null?void 0:r.style,...n==null?void 0:n.style,...a==null?void 0:a.style},p={...c,...r,...l,...i};return d.length>0&&(p.className=d),Object.keys(u).length>0&&(p.style=u),{props:p,internalRef:c.ref}}function Hp(e,t,r){return typeof e=="function"?e(t,r):e}function Gt(e){var u;const{elementType:t,externalSlotProps:r,ownerState:a,skipResolvingSlotProps:n=!1,...o}=e,s=n?{}:Hp(r,a),{props:i,internalRef:l}=Jp({...o,externalSlotProps:s}),c=Zl(l,s==null?void 0:s.ref,(u=e.additionalProps)==null?void 0:u.ref);return Gp(t,{...i,ref:c},a)}const qp=H.createContext();process.env.NODE_ENV!=="production"&&(S.node,S.bool);const Wp=()=>H.useContext(qp)??!1,Kp=H.createContext(void 0);process.env.NODE_ENV!=="production"&&(S.node,S.object);function Qp(e){const{theme:t,name:r,props:a}=e;if(!t||!t.components||!t.components[r])return a;const n=t.components[r];return n.defaultProps?vn(n.defaultProps,a):!n.styleOverrides&&!n.variants?vn(n,a):a}function Yp({props:e,name:t}){const r=H.useContext(Kp);return Qp({props:e,name:t,theme:{components:r}})}const Xs={theme:void 0};function Xp(e){let t,r;return function(n){let o=t;return(o===void 0||n.theme!==r)&&(Xs.theme=n.theme,o=ql(e(Xs)),t=o,r=n.theme),o}}function Zp(e=""){function t(...a){if(!a.length)return"";const n=a[0];return typeof n=="string"&&!n.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}-`:""}${n}${t(...a.slice(1))})`:`, ${n}`}return(a,...n)=>`var(--${e?`${e}-`:""}${a}${t(...n)})`}const Zs=(e,t,r,a=[])=>{let n=e;t.forEach((o,s)=>{s===t.length-1?Array.isArray(n)?n[Number(o)]=r:n&&typeof n=="object"&&(n[o]=r):n&&typeof n=="object"&&(n[o]||(n[o]=a.includes(o)?[]:{}),n=n[o])})},eh=(e,t,r)=>{function a(n,o=[],s=[]){Object.entries(n).forEach(([i,l])=>{(!r||r&&!r([...o,i]))&&l!=null&&(typeof l=="object"&&Object.keys(l).length>0?a(l,[...o,i],Array.isArray(l)?[...s,i]:s):t([...o,i],l,s))})}a(e)},th=(e,t)=>typeof t=="number"?["lineHeight","fontWeight","opacity","zIndex"].some(a=>e.includes(a))||e[e.length-1].toLowerCase().includes("opacity")?t:`${t}px`:t;function yo(e,t){const{prefix:r,shouldSkipGeneratingVar:a}=t||{},n={},o={},s={};return eh(e,(i,l,c)=>{if((typeof l=="string"||typeof l=="number")&&(!a||!a(i,l))){const d=`--${r?`${r}-`:""}${i.join("-")}`,u=th(i,l);Object.assign(n,{[d]:u}),Zs(o,i,`var(${d})`,c),Zs(s,i,`var(${d}, ${u})`,c)}},i=>i[0]==="vars"),{css:n,vars:o,varsWithDefaults:s}}function rh(e,t={}){const{getSelector:r=x,disableCssColorScheme:a,colorSchemeSelector:n}=t,{colorSchemes:o={},components:s,defaultColorScheme:i="light",...l}=e,{vars:c,css:d,varsWithDefaults:u}=yo(l,t);let p=u;const m={},{[i]:g,...h}=o;if(Object.entries(h||{}).forEach(([F,N])=>{const{vars:J,css:K,varsWithDefaults:j}=yo(N,t);p=Ke(p,j),m[F]={css:K,vars:J}}),g){const{css:F,vars:N,varsWithDefaults:J}=yo(g,t);p=Ke(p,J),m[i]={css:F,vars:N}}function x(F,N){var K,j;let J=n;if(n==="class"&&(J=".%s"),n==="data"&&(J="[data-%s]"),n!=null&&n.startsWith("data-")&&!n.includes("%s")&&(J=`[${n}="%s"]`),F){if(J==="media")return e.defaultColorScheme===F?":root":{[`@media (prefers-color-scheme: ${((j=(K=o[F])==null?void 0:K.palette)==null?void 0:j.mode)||F})`]:{":root":N}};if(J)return e.defaultColorScheme===F?`:root, ${J.replace("%s",String(F))}`:J.replace("%s",String(F))}return":root"}return{vars:p,generateThemeVars:()=>{let F={...c};return Object.entries(m).forEach(([,{vars:N}])=>{F=Ke(F,N)}),F},generateStyleSheets:()=>{var L,k;const F=[],N=e.defaultColorScheme||"light";function J(y,M){Object.keys(M).length&&F.push(typeof y=="string"?{[y]:{...M}}:y)}J(r(void 0,{...d}),d);const{[N]:K,...j}=m;if(K){const{css:y}=K,M=(k=(L=o[N])==null?void 0:L.palette)==null?void 0:k.mode,B=!a&&M?{colorScheme:M,...y}:{...y};J(r(N,{...B}),B)}return Object.entries(j).forEach(([y,{css:M}])=>{var D,re;const B=(re=(D=o[y])==null?void 0:D.palette)==null?void 0:re.mode,G=!a&&B?{colorScheme:B,...M}:{...M};J(r(y,{...G}),G)}),F}}}function ah(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)} &`:"&"}}const nh=Dn(),oh=jp("div",{name:"MuiStack",slot:"Root",overridesResolver:(e,t)=>t.root});function sh(e){return Up({props:e,name:"MuiStack",defaultTheme:nh})}function ih(e,t){const r=H.Children.toArray(e).filter(Boolean);return r.reduce((a,n,o)=>(a.push(n),o<r.length-1&&a.push(H.cloneElement(t,{key:`separator-${o}`})),a),[])}const lh=e=>({row:"Left","row-reverse":"Right",column:"Top","column-reverse":"Bottom"})[e],ch=({ownerState:e,theme:t})=>{let r={display:"flex",flexDirection:"column",...ft({theme:t},mo({values:e.direction,breakpoints:t.breakpoints.values}),a=>({flexDirection:a}))};if(e.spacing){const a=Un(t),n=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=mo({values:e.direction,base:n}),s=mo({values:e.spacing,base:n});typeof o=="object"&&Object.keys(o).forEach((l,c,d)=>{if(!o[l]){const p=c>0?o[d[c-1]]:"column";o[l]=p}}),r=Ke(r,ft({theme:t},s,(l,c)=>e.useFlexGap?{gap:cr(a,l)}:{"& > :not(style):not(style)":{margin:0},"& > :not(style) ~ :not(style)":{[`margin${lh(c?o[c]:e.direction)}`]:cr(a,l)}}))}return r=_u(t.breakpoints,r),r};function dh(e={}){const{createStyledComponent:t=oh,useThemeProps:r=sh,componentName:a="MuiStack"}=e,n=()=>hs({root:["root"]},l=>Fa(a,l),{}),o=t(ch),s=H.forwardRef(function(l,c){const d=r(l),u=Op(d),{component:p="div",direction:m="column",spacing:g=0,divider:h,children:x,className:E,useFlexGap:U=!1,...F}=u,N={direction:m,spacing:g,useFlexGap:U},J=n();return b.jsx(o,{as:p,ownerState:N,ref:c,className:Pt(J.root,E),...F,children:h?ih(x,h):x})});return process.env.NODE_ENV!=="production"&&(s.propTypes={children:S.node,direction:S.oneOfType([S.oneOf(["column-reverse","column","row-reverse","row"]),S.arrayOf(S.oneOf(["column-reverse","column","row-reverse","row"])),S.object]),divider:S.node,spacing:S.oneOfType([S.arrayOf(S.oneOfType([S.number,S.string])),S.number,S.object,S.string]),sx:S.oneOfType([S.arrayOf(S.oneOfType([S.func,S.object,S.bool])),S.func,S.object])}),s}const Ta={black:"#000",white:"#fff"},uh={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"},Vr={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},Rr={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},ua={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},_r={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},Ar={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},Tr={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"};function ec(){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:Ta.white,default:Ta.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 ph=ec();function tc(){return{text:{primary:Ta.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:Ta.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 ei=tc();function ti(e,t,r,a){const n=a.light||a,o=a.dark||a*1.5;e[t]||(e.hasOwnProperty(r)?e[t]=e[r]:t==="light"?e.light=Aa(e.main,n):t==="dark"&&(e.dark=_a(e.main,o)))}function hh(e="light"){return e==="dark"?{main:_r[200],light:_r[50],dark:_r[400]}:{main:_r[700],light:_r[400],dark:_r[800]}}function mh(e="light"){return e==="dark"?{main:Vr[200],light:Vr[50],dark:Vr[400]}:{main:Vr[500],light:Vr[300],dark:Vr[700]}}function fh(e="light"){return e==="dark"?{main:Rr[500],light:Rr[300],dark:Rr[700]}:{main:Rr[700],light:Rr[400],dark:Rr[800]}}function gh(e="light"){return e==="dark"?{main:Ar[400],light:Ar[300],dark:Ar[700]}:{main:Ar[700],light:Ar[500],dark:Ar[900]}}function yh(e="light"){return e==="dark"?{main:Tr[400],light:Tr[300],dark:Tr[700]}:{main:Tr[800],light:Tr[500],dark:Tr[900]}}function bh(e="light"){return e==="dark"?{main:ua[400],light:ua[300],dark:ua[700]}:{main:"#ed6c02",light:ua[500],dark:ua[900]}}function ms(e){const{mode:t="light",contrastThreshold:r=3,tonalOffset:a=.2,...n}=e,o=e.primary||hh(t),s=e.secondary||mh(t),i=e.error||fh(t),l=e.info||gh(t),c=e.success||yh(t),d=e.warning||bh(t);function u(h){const x=Ws(h,ei.text.primary)>=r?ei.text.primary:ph.text.primary;if(process.env.NODE_ENV!=="production"){const E=Ws(h,x);E<3&&console.error([`MUI: The contrast ratio of ${E}:1 for ${x} on ${h}`,"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(`
|
|
63
|
-
`))}return
|
|
64
|
-
The color object needs to have a \`main\` property or a \`${
|
|
65
|
-
\`color.main\` should be a string, but \`${JSON.stringify(
|
|
56
|
+
`)));const i=a[o];return s>=0?i:typeof i=="number"?-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(`
|
|
57
|
+
`)),()=>{})}function Io(e){return Za(e,"spacing",8,"spacing")}function zr(e,t){return typeof t=="string"||t==null?t:e(t)}function Qy(e,t){return r=>e.reduce((n,a)=>(n[a]=zr(t,r),n),{})}function Xy(e,t,r,n){if(!t.includes(r))return null;const a=Ky(r),s=Qy(a,n),o=e[r];return Ft(e,o,s)}function Ip(e,t){const r=Io(e.theme);return Object.keys(e).map(n=>Xy(e,t,n,r)).reduce(_a,{})}function Fe(e){return Ip(e,Eo)}Fe.propTypes=process.env.NODE_ENV!=="production"?Eo.reduce((e,t)=>(e[t]=Ar,e),{}):{};Fe.filterProps=Eo;function Be(e){return Ip(e,_o)}Be.propTypes=process.env.NODE_ENV!=="production"?_o.reduce((e,t)=>(e[t]=Ar,e),{}):{};Be.filterProps=_o;process.env.NODE_ENV!=="production"&&Yy.reduce((e,t)=>(e[t]=Ar,e),{});function Mp(e=8,t=Io({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(s=>{const o=t(s);return typeof o=="number"?`${o}px`:o}).join(" "));return r.mui=!0,r}function Mo(...e){const t=e.reduce((n,a)=>(a.filterProps.forEach(s=>{n[s]=a}),n),{}),r=n=>Object.keys(n).reduce((a,s)=>t[s]?_a(a,t[s](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 Tt(e){return typeof e!="number"?e:`${e}px solid`}function _t(e,t){return We({prop:e,themeKey:"borders",transform:t})}const Zy=_t("border",Tt),e0=_t("borderTop",Tt),t0=_t("borderRight",Tt),r0=_t("borderBottom",Tt),n0=_t("borderLeft",Tt),a0=_t("borderColor"),s0=_t("borderTopColor"),o0=_t("borderRightColor"),i0=_t("borderBottomColor"),l0=_t("borderLeftColor"),c0=_t("outline",Tt),u0=_t("outlineColor"),$o=e=>{if(e.borderRadius!==void 0&&e.borderRadius!==null){const t=Za(e.theme,"shape.borderRadius",4,"borderRadius"),r=n=>({borderRadius:zr(t,n)});return Ft(e,e.borderRadius,r)}return null};$o.propTypes=process.env.NODE_ENV!=="production"?{borderRadius:Ar}:{};$o.filterProps=["borderRadius"];Mo(Zy,e0,t0,r0,n0,a0,s0,o0,i0,l0,$o,c0,u0);const jo=e=>{if(e.gap!==void 0&&e.gap!==null){const t=Za(e.theme,"spacing",8,"gap"),r=n=>({gap:zr(t,n)});return Ft(e,e.gap,r)}return null};jo.propTypes=process.env.NODE_ENV!=="production"?{gap:Ar}:{};jo.filterProps=["gap"];const ko=e=>{if(e.columnGap!==void 0&&e.columnGap!==null){const t=Za(e.theme,"spacing",8,"columnGap"),r=n=>({columnGap:zr(t,n)});return Ft(e,e.columnGap,r)}return null};ko.propTypes=process.env.NODE_ENV!=="production"?{columnGap:Ar}:{};ko.filterProps=["columnGap"];const Lo=e=>{if(e.rowGap!==void 0&&e.rowGap!==null){const t=Za(e.theme,"spacing",8,"rowGap"),r=n=>({rowGap:zr(t,n)});return Ft(e,e.rowGap,r)}return null};Lo.propTypes=process.env.NODE_ENV!=="production"?{rowGap:Ar}:{};Lo.filterProps=["rowGap"];const d0=We({prop:"gridColumn"}),h0=We({prop:"gridRow"}),p0=We({prop:"gridAutoFlow"}),f0=We({prop:"gridAutoColumns"}),m0=We({prop:"gridAutoRows"}),g0=We({prop:"gridTemplateColumns"}),y0=We({prop:"gridTemplateRows"}),b0=We({prop:"gridTemplateAreas"}),v0=We({prop:"gridArea"});Mo(jo,ko,Lo,d0,h0,p0,f0,m0,g0,y0,b0,v0);function Mn(e,t){return t==="grey"?t:e}const x0=We({prop:"color",themeKey:"palette",transform:Mn}),S0=We({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:Mn}),O0=We({prop:"backgroundColor",themeKey:"palette",transform:Mn});Mo(x0,S0,O0);function wt(e){return e<=1&&e!==0?`${e*100}%`:e}const w0=We({prop:"width",transform:wt}),rc=e=>{if(e.maxWidth!==void 0&&e.maxWidth!==null){const t=r=>{var a,s,o,i,l;const n=((o=(s=(a=e.theme)==null?void 0:a.breakpoints)==null?void 0:s.values)==null?void 0:o[r])||Ao[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:wt(r)}};return Ft(e,e.maxWidth,t)}return null};rc.filterProps=["maxWidth"];const C0=We({prop:"minWidth",transform:wt}),P0=We({prop:"height",transform:wt}),R0=We({prop:"maxHeight",transform:wt}),T0=We({prop:"minHeight",transform:wt});We({prop:"size",cssProperty:"width",transform:wt});We({prop:"size",cssProperty:"height",transform:wt});const A0=We({prop:"boxSizing"});Mo(w0,rc,C0,P0,R0,T0,A0);const es={border:{themeKey:"borders",transform:Tt},borderTop:{themeKey:"borders",transform:Tt},borderRight:{themeKey:"borders",transform:Tt},borderBottom:{themeKey:"borders",transform:Tt},borderLeft:{themeKey:"borders",transform:Tt},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Tt},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:$o},color:{themeKey:"palette",transform:Mn},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:Mn},backgroundColor:{themeKey:"palette",transform:Mn},p:{style:Be},pt:{style:Be},pr:{style:Be},pb:{style:Be},pl:{style:Be},px:{style:Be},py:{style:Be},padding:{style:Be},paddingTop:{style:Be},paddingRight:{style:Be},paddingBottom:{style:Be},paddingLeft:{style:Be},paddingX:{style:Be},paddingY:{style:Be},paddingInline:{style:Be},paddingInlineStart:{style:Be},paddingInlineEnd:{style:Be},paddingBlock:{style:Be},paddingBlockStart:{style:Be},paddingBlockEnd:{style:Be},m:{style:Fe},mt:{style:Fe},mr:{style:Fe},mb:{style:Fe},ml:{style:Fe},mx:{style:Fe},my:{style:Fe},margin:{style:Fe},marginTop:{style:Fe},marginRight:{style:Fe},marginBottom:{style:Fe},marginLeft:{style:Fe},marginX:{style:Fe},marginY:{style:Fe},marginInline:{style:Fe},marginInlineStart:{style:Fe},marginInlineEnd:{style:Fe},marginBlock:{style:Fe},marginBlockStart:{style:Fe},marginBlockEnd:{style:Fe},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:jo},rowGap:{style:Lo},columnGap:{style:ko},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:wt},maxWidth:{style:rc},minWidth:{transform:wt},height:{transform:wt},maxHeight:{transform:wt},minHeight:{transform:wt},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 V0(...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 E0(e,t){return typeof e=="function"?e(t):e}function _0(){function e(r,n,a,s){const o={[r]:n,theme:a},i=s[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=Vo(a,c)||{};return d?d(o):Ft(o,n,m=>{let f=Xs(h,u,m);return m===f&&typeof m=="string"&&(f=Xs(h,u,`${r}${m==="default"?"":dt(m)}`,m)),l===!1?f:{[l]:f}})}function t(r){const{sx:n,theme:a={}}=r||{};if(!n)return null;const s=a.unstable_sxConfig??es;function o(i){let l=i;if(typeof i=="function")l=i(a);else if(typeof i!="object")return i;if(!l)return null;const c=Ep(a.breakpoints),u=Object.keys(c);let d=c;return Object.keys(l).forEach(h=>{const p=E0(l[h],a);if(p!=null)if(typeof p=="object")if(s[h])d=_a(d,e(h,p,a,s));else{const m=Ft({theme:a},p,f=>({[h]:f}));V0(m,p)?d[h]=t({sx:p,theme:a}):d=_a(d,m)}else d=_a(d,e(h,p,a,s))}),Uy(a,_p(u,d))}return Array.isArray(n)?n.map(o):o(n)}return t}const Un=_0();Un.filterProps=["sx"];function I0(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 Uo(e={},...t){const{breakpoints:r={},palette:n={},spacing:a,shape:s={},...o}=e,i=Ly(r),l=Mp(a);let c=ht({breakpoints:i,direction:"ltr",components:{},palette:{mode:"light",...n},spacing:l,shape:{...By,...s}},o);return c=Fy(c),c.applyStyles=I0,c=t.reduce((u,d)=>ht(u,d),c),c.unstable_sxConfig={...es,...o==null?void 0:o.unstable_sxConfig},c.unstable_sx=function(d){return Un({sx:d,theme:this})},c}function M0(e){return Object.keys(e).length===0}function $0(e=null){const t=F.useContext(dy.ThemeContext);return!t||M0(t)?e:t}const j0=Uo();function k0(e=j0){return $0(e)}const L0=e=>{var n;const t={systemProps:{},otherProps:{}},r=((n=e==null?void 0:e.theme)==null?void 0:n.unstable_sxConfig)??es;return Object.keys(e).forEach(a=>{r[a]?t.systemProps[a]=e[a]:t.otherProps[a]=e[a]}),t};function U0(e){const{sx:t,...r}=e,{systemProps:n,otherProps:a}=L0(r);let s;return Array.isArray(t)?s=[n,...t]:typeof t=="function"?s=(...o)=>{const i=t(...o);return Wt(i)?{...n,...i}:n}:s={...n,...t},{...a,sx:s}}const xu=e=>e,D0=()=>{let e=xu;return{configure(t){e=t},generate(t){return e(t)},reset(){e=xu}}},N0=D0(),F0={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 ts(e,t,r="Mui"){const n=F0[t];return n?`${r}-${n}`:`${N0.generate(e)}-${t}`}function $p(e,t,r="Mui"){const n={};return t.forEach(a=>{n[a]=ts(e,a,r)}),n}function jp(e,t=""){return e.displayName||e.name||t}function Su(e,t,r){const n=jp(t);return e.displayName||(n!==""?`${r}(${n})`:r)}function B0(e){if(e!=null){if(typeof e=="string")return e;if(typeof e=="function")return jp(e,"Component");if(typeof e=="object")switch(e.$$typeof){case Qs.ForwardRef:return Su(e,e.render,"ForwardRef");case Qs.Memo:return Su(e,e.type,"memo");default:return}}}function kp(e){const{variants:t,...r}=e,n={variants:t,style:fu(r),isProcessed:!0};return n.style===r||t&&t.forEach(a=>{typeof a.style!="function"&&(a.style=fu(a.style))}),n}const z0=Uo();function Ti(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}function G0(e){return e?(t,r)=>r[e]:null}function H0(e,t,r){e.theme=W0(e.theme)?r:e.theme[t]||e.theme}function Ns(e,t){const r=typeof t=="function"?t(e):t;if(Array.isArray(r))return r.flatMap(n=>Ns(e,n));if(Array.isArray(r==null?void 0:r.variants)){let n;if(r.isProcessed)n=r.style;else{const{variants:a,...s}=r;n=s}return Lp(e,r.variants,[n])}return r!=null&&r.isProcessed?r.style:r}function Lp(e,t,r=[]){var a;let n;e:for(let s=0;s<t.length;s+=1){const o=t[s];if(typeof o.props=="function"){if(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),!o.props(n))continue}else for(const i in o.props)if(e[i]!==o.props[i]&&((a=e.ownerState)==null?void 0:a[i])!==o.props[i])continue e;typeof o.style=="function"?(n??(n={...e,...e.ownerState,ownerState:e.ownerState}),r.push(o.style(n))):r.push(o.style)}return r}function Up(e={}){const{themeId:t,defaultTheme:r=z0,rootShouldForwardProp:n=Ti,slotShouldForwardProp:a=Ti}=e;function s(i){H0(i,t,r)}return(i,l={})=>{Iy(i,V=>V.filter(R=>R!==Un));const{name:c,slot:u,skipVariantsResolver:d,skipSx:h,overridesResolver:p=G0(Dp(u)),...m}=l,f=d!==void 0?d:u&&u!=="Root"&&u!=="root"||!1,g=h||!1;let S=Ti;u==="Root"||u==="root"?S=n:u?S=a:K0(i)&&(S=void 0);const T=_y(i,{shouldForwardProp:S,label:J0(c,u),...m}),O=V=>{if(typeof V=="function"&&V.__emotion_real!==V)return function(P){return Ns(P,V)};if(Wt(V)){const R=kp(V);return R.variants?function(E){return Ns(E,R)}:R.style}return V},C=(...V)=>{const R=[],P=V.map(O),E=[];if(R.push(s),c&&p&&E.push(function(z){var te,oe;const G=(oe=(te=z.theme.components)==null?void 0:te[c])==null?void 0:oe.styleOverrides;if(!G)return null;const re={};for(const Z in G)re[Z]=Ns(z,G[Z]);return p(z,re)}),c&&!f&&E.push(function(z){var re,te;const I=z.theme,G=(te=(re=I==null?void 0:I.components)==null?void 0:re[c])==null?void 0:te.variants;return G?Lp(z,G):null}),g||E.push(Un),Array.isArray(P[0])){const A=P.shift(),z=new Array(R.length).fill(""),I=new Array(E.length).fill("");let G;G=[...z,...A,...I],G.raw=[...z,...A.raw,...I],R.unshift(G)}const B=[...R,...P,...E],y=T(...B);return i.muiName&&(y.muiName=i.muiName),process.env.NODE_ENV!=="production"&&(y.displayName=q0(c,u,i)),y};return T.withConfig&&(C.withConfig=T.withConfig),C}}function q0(e,t,r){return e?`${e}${dt(t||"")}`:`Styled(${B0(r)})`}function J0(e,t){let r;return process.env.NODE_ENV!=="production"&&e&&(r=`${e}-${Dp(t||"Root")}`),r}function W0(e){for(const t in e)return!1;return!0}function K0(e){return typeof e=="string"&&e.charCodeAt(0)>96}function Dp(e){return e&&e.charAt(0).toLowerCase()+e.slice(1)}const Y0=Up();function Zs(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 s=e[a],o=t[a];if(!o)r[a]=s||{};else if(!s)r[a]=o;else{r[a]={...o};for(const i in s)if(Object.prototype.hasOwnProperty.call(s,i)){const l=i;r[a][l]=Zs(s[l],o[l])}}}else r[a]===void 0&&(r[a]=e[a])}return r}function Q0(e){const{theme:t,name:r,props:n}=e;return!t||!t.components||!t.components[r]||!t.components[r].defaultProps?n:Zs(t.components[r].defaultProps,n)}function Np({props:e,name:t,defaultTheme:r,themeId:n}){let a=k0(r);return n&&(a=a[n]||a),Q0({theme:a,name:t,props:e})}const Fp=typeof window<"u"?F.useLayoutEffect:F.useEffect;function Vn(e,t=Number.MIN_SAFE_INTEGER,r=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,r))}function nc(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}].`),Vn(e,t,r)}function X0(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 Rr(e){if(e.type)return e;if(e.charAt(0)==="#")return Rr(X0(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.
|
|
58
|
+
The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:Pr(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.
|
|
59
|
+
The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:Pr(10,a))}else n=n.split(",");return n=n.map(s=>parseFloat(s)),{type:r,values:n,colorSpace:a}}const Z0=e=>{const t=Rr(e);return t.values.slice(0,3).map((r,n)=>t.type.includes("hsl")&&n!==0?`${r}%`:r).join(" ")},Ta=(e,t)=>{try{return Z0(e)}catch{return t&&process.env.NODE_ENV!=="production"&&console.warn(t),e}};function Do(e){const{type:t,colorSpace:r}=e;let{values:n}=e;return t.includes("rgb")?n=n.map((a,s)=>s<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 Bp(e){e=Rr(e);const{values:t}=e,r=t[0],n=t[1]/100,a=t[2]/100,s=n*Math.min(a,1-a),o=(c,u=(c+r/30)%12)=>a-s*Math.max(Math.min(u-3,9-u,1),-1);let i="rgb";const l=[Math.round(o(0)*255),Math.round(o(8)*255),Math.round(o(4)*255)];return e.type==="hsla"&&(i+="a",l.push(t[3])),Do({type:i,values:l})}function gl(e){e=Rr(e);let t=e.type==="hsl"||e.type==="hsla"?Rr(Bp(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 Ou(e,t){const r=gl(e),n=gl(t);return(Math.max(r,n)+.05)/(Math.min(r,n)+.05)}function yl(e,t){return e=Rr(e),t=nc(t),(e.type==="rgb"||e.type==="hsl")&&(e.type+="a"),e.type==="color"?e.values[3]=`/${t}`:e.values[3]=t,Do(e)}function ps(e,t,r){try{return yl(e,t)}catch{return e}}function ka(e,t){if(e=Rr(e),t=nc(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 Do(e)}function Ve(e,t,r){try{return ka(e,t)}catch{return e}}function La(e,t){if(e=Rr(e),t=nc(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 Do(e)}function Ee(e,t,r){try{return La(e,t)}catch{return e}}function eb(e,t=.15){return gl(e)>.5?ka(e,t):La(e,t)}function fs(e,t,r){try{return eb(e,t)}catch{return e}}function wu(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...n){return e(...n)||t(...n)}}function Fs(e){return e&&e.ownerDocument||document}function tb(e,t){typeof e=="function"?e(t):e&&(e.current=t)}function rb({controlled:e,default:t,name:r,state:n="value"}){const{current:a}=F.useRef(e!==void 0),[s,o]=F.useState(t),i=a?e:s;if(process.env.NODE_ENV!=="production"){F.useEffect(()=>{a!==(e!==void 0)&&console.error([`MUI: A component is changing the ${a?"":"un"}controlled ${n} state of ${r} to be ${a?"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"].join(`
|
|
60
|
+
`))},[n,r,e]);const{current:c}=F.useRef(t);F.useEffect(()=>{!a&&!Object.is(c,t)&&console.error([`MUI: A component is changing the default ${n} state of an uncontrolled ${r} after being initialized. To suppress this warning opt to use a controlled ${r}.`].join(`
|
|
61
|
+
`))},[JSON.stringify(t)])}const l=F.useCallback(c=>{a||o(c)},[]);return[i,l]}function Ai(e){const t=F.useRef(e);return Fp(()=>{t.current=e}),F.useRef((...r)=>(0,t.current)(...r)).current}function zp(...e){return F.useMemo(()=>e.every(t=>t==null)?null:t=>{e.forEach(r=>{tb(r,t)})},e)}function Cu(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(`
|
|
62
|
+
`))}return!1}const nb={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"};function ac(e,t,r=void 0){const n={};for(const a in e){const s=e[a];let o="",i=!0;for(let l=0;l<s.length;l+=1){const c=s[l];c&&(o+=(i===!0?"":" ")+t(c),i=!1,r&&r[c]&&(o+=" "+r[c]))}n[a]=o}return n}function ab(e){return typeof e=="string"}function sb(e,t,r){return e===void 0||ab(e)?t:{...t,ownerState:{...t.ownerState,...r}}}function Bs(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 Pu(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 ob(e){const{getSlotProps:t,additionalProps:r,externalSlotProps:n,externalForwardedProps:a,className:s}=e;if(!t){const p=Nt(r==null?void 0:r.className,s,a==null?void 0:a.className,n==null?void 0:n.className),m={...r==null?void 0:r.style,...a==null?void 0:a.style,...n==null?void 0:n.style},f={...r,...a,...n};return p.length>0&&(f.className=p),Object.keys(m).length>0&&(f.style=m),{props:f,internalRef:void 0}}const o=Bs({...a,...n}),i=Pu(n),l=Pu(a),c=t(o),u=Nt(c==null?void 0:c.className,r==null?void 0:r.className,s,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 ib(e,t,r){return typeof e=="function"?e(t,r):e}function yr(e){var d;const{elementType:t,externalSlotProps:r,ownerState:n,skipResolvingSlotProps:a=!1,...s}=e,o=a?{}:ib(r,n),{props:i,internalRef:l}=ob({...s,externalSlotProps:o}),c=zp(l,o==null?void 0:o.ref,(d=e.additionalProps)==null?void 0:d.ref);return sb(t,{...i,ref:c},n)}const lb=F.createContext();process.env.NODE_ENV!=="production"&&(b.node,b.bool);const cb=()=>F.useContext(lb)??!1,ub=F.createContext(void 0);process.env.NODE_ENV!=="production"&&(b.node,b.object);function db(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?Zs(a.defaultProps,n):!a.styleOverrides&&!a.variants?Zs(a,n):n}function hb({props:e,name:t}){const r=F.useContext(ub);return db({props:e,name:t,theme:{components:r}})}const Ru={theme:void 0};function pb(e){let t,r;return function(a){let s=t;return(s===void 0||a.theme!==r)&&(Ru.theme=a.theme,s=kp(e(Ru)),t=s,r=a.theme),s}}function fb(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 Tu=(e,t,r,n=[])=>{let a=e;t.forEach((s,o)=>{o===t.length-1?Array.isArray(a)?a[Number(s)]=r:a&&typeof a=="object"&&(a[s]=r):a&&typeof a=="object"&&(a[s]||(a[s]=n.includes(s)?[]:{}),a=a[s])})},mb=(e,t,r)=>{function n(a,s=[],o=[]){Object.entries(a).forEach(([i,l])=>{(!r||r&&!r([...s,i]))&&l!=null&&(typeof l=="object"&&Object.keys(l).length>0?n(l,[...s,i],Array.isArray(l)?[...o,i]:o):t([...s,i],l,o))})}n(e)},gb=(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 Vi(e,t){const{prefix:r,shouldSkipGeneratingVar:n}=t||{},a={},s={},o={};return mb(e,(i,l,c)=>{if((typeof l=="string"||typeof l=="number")&&(!n||!n(i,l))){const u=`--${r?`${r}-`:""}${i.join("-")}`,d=gb(i,l);Object.assign(a,{[u]:d}),Tu(s,i,`var(${u})`,c),Tu(o,i,`var(${u}, ${d})`,c)}},i=>i[0]==="vars"),{css:a,vars:s,varsWithDefaults:o}}function yb(e,t={}){const{getSelector:r=g,disableCssColorScheme:n,colorSchemeSelector:a}=t,{colorSchemes:s={},components:o,defaultColorScheme:i="light",...l}=e,{vars:c,css:u,varsWithDefaults:d}=Vi(l,t);let h=d;const p={},{[i]:m,...f}=s;if(Object.entries(f||{}).forEach(([O,C])=>{const{vars:V,css:R,varsWithDefaults:P}=Vi(C,t);h=ht(h,P),p[O]={css:R,vars:V}}),m){const{css:O,vars:C,varsWithDefaults:V}=Vi(m,t);h=ht(h,V),p[i]={css:O,vars:C}}function g(O,C){var R,P;let V=a;if(a==="class"&&(V=".%s"),a==="data"&&(V="[data-%s]"),a!=null&&a.startsWith("data-")&&!a.includes("%s")&&(V=`[${a}="%s"]`),O){if(V==="media")return e.defaultColorScheme===O?":root":{[`@media (prefers-color-scheme: ${((P=(R=s[O])==null?void 0:R.palette)==null?void 0:P.mode)||O})`]:{":root":C}};if(V)return e.defaultColorScheme===O?`:root, ${V.replace("%s",String(O))}`:V.replace("%s",String(O))}return":root"}return{vars:h,generateThemeVars:()=>{let O={...c};return Object.entries(p).forEach(([,{vars:C}])=>{O=ht(O,C)}),O},generateStyleSheets:()=>{var E,B;const O=[],C=e.defaultColorScheme||"light";function V(y,A){Object.keys(A).length&&O.push(typeof y=="string"?{[y]:{...A}}:y)}V(r(void 0,{...u}),u);const{[C]:R,...P}=p;if(R){const{css:y}=R,A=(B=(E=s[C])==null?void 0:E.palette)==null?void 0:B.mode,z=!n&&A?{colorScheme:A,...y}:{...y};V(r(C,{...z}),z)}return Object.entries(P).forEach(([y,{css:A}])=>{var G,re;const z=(re=(G=s[y])==null?void 0:G.palette)==null?void 0:re.mode,I=!n&&z?{colorScheme:z,...A}:{...A};V(r(y,{...I}),I)}),O}}}function bb(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)} &`:"&"}}const vb=Uo(),xb=Y0("div",{name:"MuiStack",slot:"Root",overridesResolver:(e,t)=>t.root});function Sb(e){return Np({props:e,name:"MuiStack",defaultTheme:vb})}function Ob(e,t){const r=F.Children.toArray(e).filter(Boolean);return r.reduce((n,a,s)=>(n.push(a),s<r.length-1&&n.push(F.cloneElement(t,{key:`separator-${s}`})),n),[])}const wb=e=>({row:"Left","row-reverse":"Right",column:"Top","column-reverse":"Bottom"})[e],Cb=({ownerState:e,theme:t})=>{let r={display:"flex",flexDirection:"column",...Ft({theme:t},Ri({values:e.direction,breakpoints:t.breakpoints.values}),n=>({flexDirection:n}))};if(e.spacing){const n=Io(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),{}),s=Ri({values:e.direction,base:a}),o=Ri({values:e.spacing,base:a});typeof s=="object"&&Object.keys(s).forEach((l,c,u)=>{if(!s[l]){const h=c>0?s[u[c-1]]:"column";s[l]=h}}),r=ht(r,Ft({theme:t},o,(l,c)=>e.useFlexGap?{gap:zr(n,l)}:{"& > :not(style):not(style)":{margin:0},"& > :not(style) ~ :not(style)":{[`margin${wb(c?s[c]:e.direction)}`]:zr(n,l)}}))}return r=Gy(t.breakpoints,r),r};function Pb(e={}){const{createStyledComponent:t=xb,useThemeProps:r=Sb,componentName:n="MuiStack"}=e,a=()=>ac({root:["root"]},l=>ts(n,l),{}),s=t(Cb),o=F.forwardRef(function(l,c){const u=r(l),d=U0(u),{component:h="div",direction:p="column",spacing:m=0,divider:f,children:g,className:S,useFlexGap:T=!1,...O}=d,C={direction:p,spacing:m,useFlexGap:T},V=a();return x.jsx(s,{as:h,ownerState:C,ref:c,className:Nt(V.root,S),...O,children:f?Ob(g,f):g})});return process.env.NODE_ENV!=="production"&&(o.propTypes={children:b.node,direction:b.oneOfType([b.oneOf(["column-reverse","column","row-reverse","row"]),b.arrayOf(b.oneOf(["column-reverse","column","row-reverse","row"])),b.object]),divider:b.node,spacing:b.oneOfType([b.arrayOf(b.oneOfType([b.number,b.string])),b.number,b.object,b.string]),sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object])}),o}const Ua={black:"#000",white:"#fff"},Rb={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"},hn={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},pn={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},da={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},fn={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},mn={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},gn={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"};function Gp(){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:Ua.white,default:Ua.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 Tb=Gp();function Hp(){return{text:{primary:Ua.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:Ua.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 Au=Hp();function Vu(e,t,r,n){const a=n.light||n,s=n.dark||n*1.5;e[t]||(e.hasOwnProperty(r)?e[t]=e[r]:t==="light"?e.light=La(e.main,a):t==="dark"&&(e.dark=ka(e.main,s)))}function Ab(e="light"){return e==="dark"?{main:fn[200],light:fn[50],dark:fn[400]}:{main:fn[700],light:fn[400],dark:fn[800]}}function Vb(e="light"){return e==="dark"?{main:hn[200],light:hn[50],dark:hn[400]}:{main:hn[500],light:hn[300],dark:hn[700]}}function Eb(e="light"){return e==="dark"?{main:pn[500],light:pn[300],dark:pn[700]}:{main:pn[700],light:pn[400],dark:pn[800]}}function _b(e="light"){return e==="dark"?{main:mn[400],light:mn[300],dark:mn[700]}:{main:mn[700],light:mn[500],dark:mn[900]}}function Ib(e="light"){return e==="dark"?{main:gn[400],light:gn[300],dark:gn[700]}:{main:gn[800],light:gn[500],dark:gn[900]}}function Mb(e="light"){return e==="dark"?{main:da[400],light:da[300],dark:da[700]}:{main:"#ed6c02",light:da[500],dark:da[900]}}function sc(e){const{mode:t="light",contrastThreshold:r=3,tonalOffset:n=.2,...a}=e,s=e.primary||Ab(t),o=e.secondary||Vb(t),i=e.error||Eb(t),l=e.info||_b(t),c=e.success||Ib(t),u=e.warning||Mb(t);function d(f){const g=Ou(f,Au.text.primary)>=r?Au.text.primary:Tb.text.primary;if(process.env.NODE_ENV!=="production"){const S=Ou(f,g);S<3&&console.error([`MUI: The contrast ratio of ${S}:1 for ${g} on ${f}`,"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(`
|
|
63
|
+
`))}return g}const h=({color:f,name:g,mainShade:S=500,lightShade:T=300,darkShade:O=700})=>{if(f={...f},!f.main&&f[S]&&(f.main=f[S]),!f.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${g?` (${g})`:""} provided to augmentColor(color) is invalid.
|
|
64
|
+
The color object needs to have a \`main\` property or a \`${S}\` property.`:Pr(11,g?` (${g})`:"",S));if(typeof f.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${g?` (${g})`:""} provided to augmentColor(color) is invalid.
|
|
65
|
+
\`color.main\` should be a string, but \`${JSON.stringify(f.main)}\` was provided instead.
|
|
66
66
|
|
|
67
67
|
Did you intend to use one of the following approaches?
|
|
68
68
|
|
|
@@ -74,18 +74,66 @@ const theme1 = createTheme({ palette: {
|
|
|
74
74
|
|
|
75
75
|
const theme2 = createTheme({ palette: {
|
|
76
76
|
primary: { main: green[500] },
|
|
77
|
-
} });`:
|
|
78
|
-
`)),Object.keys(c).length!==0&&console.error(`MUI: Unrecognized argument(s) [${Object.keys(c).join(",")}].`)}return(Array.isArray(
|
|
77
|
+
} });`:Pr(12,g?` (${g})`:"",JSON.stringify(f.main)));return Vu(f,"light",T,n),Vu(f,"dark",O,n),f.contrastText||(f.contrastText=d(f.main)),f};let p;return t==="light"?p=Gp():t==="dark"&&(p=Hp()),process.env.NODE_ENV!=="production"&&(p||console.error(`MUI: The palette mode \`${t}\` is not supported.`)),ht({common:{...Ua},mode:t,primary:h({color:s,name:"primary"}),secondary:h({color:o,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:Rb,contrastThreshold:r,getContrastText:d,augmentColor:h,tonalOffset:n,...p},a)}function $b(e){const t={};return Object.entries(e).forEach(n=>{const[a,s]=n;typeof s=="object"&&(t[a]=`${s.fontStyle?`${s.fontStyle} `:""}${s.fontVariant?`${s.fontVariant} `:""}${s.fontWeight?`${s.fontWeight} `:""}${s.fontStretch?`${s.fontStretch} `:""}${s.fontSize||""}${s.lineHeight?`/${s.lineHeight} `:""}${s.fontFamily||""}`)}),t}function jb(e,t){return{toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}},...t}}function kb(e){return Math.round(e*1e5)/1e5}const Eu={textTransform:"uppercase"},_u='"Roboto", "Helvetica", "Arial", sans-serif';function Lb(e,t){const{fontFamily:r=_u,fontSize:n=14,fontWeightLight:a=300,fontWeightRegular:s=400,fontWeightMedium:o=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||(g=>`${g/l*h}rem`),m=(g,S,T,O,C)=>({fontFamily:r,fontWeight:g,fontSize:p(S),lineHeight:T,...r===_u?{letterSpacing:`${kb(O/S)}em`}:{},...C,...c}),f={h1:m(a,96,1.167,-1.5),h2:m(a,60,1.2,-.5),h3:m(s,48,1.167,0),h4:m(s,34,1.235,.25),h5:m(s,24,1.334,0),h6:m(o,20,1.6,.15),subtitle1:m(s,16,1.75,.15),subtitle2:m(o,14,1.57,.1),body1:m(s,16,1.5,.15),body2:m(s,14,1.43,.15),button:m(o,14,1.75,.4,Eu),caption:m(s,12,1.66,.4),overline:m(s,12,2.66,1,Eu),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return ht({htmlFontSize:l,pxToRem:p,fontFamily:r,fontSize:n,fontWeightLight:a,fontWeightRegular:s,fontWeightMedium:o,fontWeightBold:i,...f},d,{clone:!1})}const Ub=.2,Db=.14,Nb=.12;function Ue(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${Ub})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${Db})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Nb})`].join(",")}const Fb=["none",Ue(0,2,1,-1,0,1,1,0,0,1,3,0),Ue(0,3,1,-2,0,2,2,0,0,1,5,0),Ue(0,3,3,-2,0,3,4,0,0,1,8,0),Ue(0,2,4,-1,0,4,5,0,0,1,10,0),Ue(0,3,5,-1,0,5,8,0,0,1,14,0),Ue(0,3,5,-1,0,6,10,0,0,1,18,0),Ue(0,4,5,-2,0,7,10,1,0,2,16,1),Ue(0,5,5,-3,0,8,10,1,0,3,14,2),Ue(0,5,6,-3,0,9,12,1,0,3,16,2),Ue(0,6,6,-3,0,10,14,1,0,4,18,3),Ue(0,6,7,-4,0,11,15,1,0,4,20,3),Ue(0,7,8,-4,0,12,17,2,0,5,22,4),Ue(0,7,8,-4,0,13,19,2,0,5,24,4),Ue(0,7,9,-4,0,14,21,2,0,5,26,4),Ue(0,8,9,-5,0,15,22,2,0,6,28,5),Ue(0,8,10,-5,0,16,24,2,0,6,30,5),Ue(0,8,11,-5,0,17,26,2,0,6,32,5),Ue(0,9,11,-5,0,18,28,2,0,7,34,6),Ue(0,9,12,-6,0,19,29,2,0,7,36,6),Ue(0,10,13,-6,0,20,31,3,0,8,38,7),Ue(0,10,13,-6,0,21,33,3,0,8,40,7),Ue(0,10,14,-6,0,22,35,3,0,8,42,7),Ue(0,11,14,-7,0,23,36,3,0,9,44,8),Ue(0,11,15,-7,0,24,38,3,0,9,46,8)],Bb={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)"},zb={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function Iu(e){return`${Math.round(e)}ms`}function Gb(e){if(!e)return 0;const t=e/36;return Math.min(Math.round((4+15*t**.25+t/5)*10),3e3)}function Hb(e){const t={...Bb,...e.easing},r={...zb,...e.duration};return{getAutoHeightDuration:Gb,create:(a=["all"],s={})=>{const{duration:o=r.standard,easing:i=t.easeInOut,delay:l=0,...c}=s;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(o)&&!u(o)&&console.error(`MUI: Argument "duration" must be a number or a string but found ${o}.`),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 s!="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(`
|
|
78
|
+
`)),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 o=="string"?o:Iu(o)} ${i} ${typeof l=="string"?l:Iu(l)}`).join(",")},...e,easing:t,duration:r}}const qb={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500};function Jb(e){return Wt(e)||typeof e>"u"||typeof e=="string"||typeof e=="boolean"||typeof e=="number"||Array.isArray(e)}function qp(e={}){const t={...e};function r(n){const a=Object.entries(n);for(let s=0;s<a.length;s++){const[o,i]=a[s];!Jb(i)||o.startsWith("unstable_")?delete n[o]:Wt(i)&&(n[o]={...i},r(n[o]))}}return r(t),`import { unstable_createBreakpoints as createBreakpoints, createTransitions } from '@mui/material/styles';
|
|
79
79
|
|
|
80
80
|
const theme = ${JSON.stringify(t,null,2)};
|
|
81
81
|
|
|
82
82
|
theme.breakpoints = createBreakpoints(theme.breakpoints || {});
|
|
83
83
|
theme.transitions = createTransitions(theme.transitions || {});
|
|
84
84
|
|
|
85
|
-
export default theme;`}function
|
|
86
|
-
`))}
|
|
87
|
-
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 Fh(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const St=e=>{try{return e()}catch{}},Nh=(e="mui")=>Zp(e);function bo(e,t,r,a){if(!t)return;t=t===!0?{}:t;const n=a==="dark"?"dark":"light";if(!r){e[a]=$h({...t,palette:{mode:n,...t==null?void 0:t.palette}});return}const{palette:o,...s}=Fo({...r,palette:{mode:n,...t==null?void 0:t.palette}});return e[a]={...t,palette:o,opacity:{...ac(n),...t==null?void 0:t.opacity},overlays:(t==null?void 0:t.overlays)||nc(n)},s}function Dh(e={},...t){const{colorSchemes:r={light:!0},defaultColorScheme:a,disableCssColorScheme:n=!1,cssVarPrefix:o="mui",shouldSkipGeneratingVar:s=Uh,colorSchemeSelector:i=r.light&&r.dark?"media":void 0,rootSelector:l=":root",...c}=e,d=Object.keys(r)[0],u=a||(r.light&&d!=="light"?"light":d),p=Nh(o),{[u]:m,light:g,dark:h,...x}=r,E={...x};let U=m;if((u==="dark"&&!("dark"in r)||u==="light"&&!("light"in r))&&(U=!0),!U)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${u}\` option is either missing or invalid.`:Qt(21,u));const F=bo(E,U,c,u);g&&!E.light&&bo(E,g,void 0,"light"),h&&!E.dark&&bo(E,h,void 0,"dark");let N={defaultColorScheme:u,...F,cssVarPrefix:o,colorSchemeSelector:i,rootSelector:l,getCssVar:p,colorSchemes:E,font:{...Sh(F.typography),...F.font},spacing:Fh(c.spacing)};Object.keys(N.colorSchemes).forEach(k=>{const y=N.colorSchemes[k].palette,M=B=>{const G=B.split("-"),D=G[1],re=G[2];return p(B,y[D][re])};if(y.mode==="light"&&($(y.common,"background","#fff"),$(y.common,"onBackground","#000")),y.mode==="dark"&&($(y.common,"background","#000"),$(y.common,"onBackground","#fff")),Bh(y,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),y.mode==="light"){$(y.Alert,"errorColor",Se(y.error.light,.6)),$(y.Alert,"infoColor",Se(y.info.light,.6)),$(y.Alert,"successColor",Se(y.success.light,.6)),$(y.Alert,"warningColor",Se(y.warning.light,.6)),$(y.Alert,"errorFilledBg",M("palette-error-main")),$(y.Alert,"infoFilledBg",M("palette-info-main")),$(y.Alert,"successFilledBg",M("palette-success-main")),$(y.Alert,"warningFilledBg",M("palette-warning-main")),$(y.Alert,"errorFilledColor",St(()=>y.getContrastText(y.error.main))),$(y.Alert,"infoFilledColor",St(()=>y.getContrastText(y.info.main))),$(y.Alert,"successFilledColor",St(()=>y.getContrastText(y.success.main))),$(y.Alert,"warningFilledColor",St(()=>y.getContrastText(y.warning.main))),$(y.Alert,"errorStandardBg",ve(y.error.light,.9)),$(y.Alert,"infoStandardBg",ve(y.info.light,.9)),$(y.Alert,"successStandardBg",ve(y.success.light,.9)),$(y.Alert,"warningStandardBg",ve(y.warning.light,.9)),$(y.Alert,"errorIconColor",M("palette-error-main")),$(y.Alert,"infoIconColor",M("palette-info-main")),$(y.Alert,"successIconColor",M("palette-success-main")),$(y.Alert,"warningIconColor",M("palette-warning-main")),$(y.AppBar,"defaultBg",M("palette-grey-100")),$(y.Avatar,"defaultBg",M("palette-grey-400")),$(y.Button,"inheritContainedBg",M("palette-grey-300")),$(y.Button,"inheritContainedHoverBg",M("palette-grey-A100")),$(y.Chip,"defaultBorder",M("palette-grey-400")),$(y.Chip,"defaultAvatarColor",M("palette-grey-700")),$(y.Chip,"defaultIconColor",M("palette-grey-700")),$(y.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),$(y.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),$(y.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),$(y.LinearProgress,"primaryBg",ve(y.primary.main,.62)),$(y.LinearProgress,"secondaryBg",ve(y.secondary.main,.62)),$(y.LinearProgress,"errorBg",ve(y.error.main,.62)),$(y.LinearProgress,"infoBg",ve(y.info.main,.62)),$(y.LinearProgress,"successBg",ve(y.success.main,.62)),$(y.LinearProgress,"warningBg",ve(y.warning.main,.62)),$(y.Skeleton,"bg",`rgba(${M("palette-text-primaryChannel")} / 0.11)`),$(y.Slider,"primaryTrack",ve(y.primary.main,.62)),$(y.Slider,"secondaryTrack",ve(y.secondary.main,.62)),$(y.Slider,"errorTrack",ve(y.error.main,.62)),$(y.Slider,"infoTrack",ve(y.info.main,.62)),$(y.Slider,"successTrack",ve(y.success.main,.62)),$(y.Slider,"warningTrack",ve(y.warning.main,.62));const B=qa(y.background.default,.8);$(y.SnackbarContent,"bg",B),$(y.SnackbarContent,"color",St(()=>y.getContrastText(B))),$(y.SpeedDialAction,"fabHoverBg",qa(y.background.paper,.15)),$(y.StepConnector,"border",M("palette-grey-400")),$(y.StepContent,"border",M("palette-grey-400")),$(y.Switch,"defaultColor",M("palette-common-white")),$(y.Switch,"defaultDisabledColor",M("palette-grey-100")),$(y.Switch,"primaryDisabledColor",ve(y.primary.main,.62)),$(y.Switch,"secondaryDisabledColor",ve(y.secondary.main,.62)),$(y.Switch,"errorDisabledColor",ve(y.error.main,.62)),$(y.Switch,"infoDisabledColor",ve(y.info.main,.62)),$(y.Switch,"successDisabledColor",ve(y.success.main,.62)),$(y.Switch,"warningDisabledColor",ve(y.warning.main,.62)),$(y.TableCell,"border",ve(Ha(y.divider,1),.88)),$(y.Tooltip,"bg",Ha(y.grey[700],.92))}if(y.mode==="dark"){$(y.Alert,"errorColor",ve(y.error.light,.6)),$(y.Alert,"infoColor",ve(y.info.light,.6)),$(y.Alert,"successColor",ve(y.success.light,.6)),$(y.Alert,"warningColor",ve(y.warning.light,.6)),$(y.Alert,"errorFilledBg",M("palette-error-dark")),$(y.Alert,"infoFilledBg",M("palette-info-dark")),$(y.Alert,"successFilledBg",M("palette-success-dark")),$(y.Alert,"warningFilledBg",M("palette-warning-dark")),$(y.Alert,"errorFilledColor",St(()=>y.getContrastText(y.error.dark))),$(y.Alert,"infoFilledColor",St(()=>y.getContrastText(y.info.dark))),$(y.Alert,"successFilledColor",St(()=>y.getContrastText(y.success.dark))),$(y.Alert,"warningFilledColor",St(()=>y.getContrastText(y.warning.dark))),$(y.Alert,"errorStandardBg",Se(y.error.light,.9)),$(y.Alert,"infoStandardBg",Se(y.info.light,.9)),$(y.Alert,"successStandardBg",Se(y.success.light,.9)),$(y.Alert,"warningStandardBg",Se(y.warning.light,.9)),$(y.Alert,"errorIconColor",M("palette-error-main")),$(y.Alert,"infoIconColor",M("palette-info-main")),$(y.Alert,"successIconColor",M("palette-success-main")),$(y.Alert,"warningIconColor",M("palette-warning-main")),$(y.AppBar,"defaultBg",M("palette-grey-900")),$(y.AppBar,"darkBg",M("palette-background-paper")),$(y.AppBar,"darkColor",M("palette-text-primary")),$(y.Avatar,"defaultBg",M("palette-grey-600")),$(y.Button,"inheritContainedBg",M("palette-grey-800")),$(y.Button,"inheritContainedHoverBg",M("palette-grey-700")),$(y.Chip,"defaultBorder",M("palette-grey-700")),$(y.Chip,"defaultAvatarColor",M("palette-grey-300")),$(y.Chip,"defaultIconColor",M("palette-grey-300")),$(y.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),$(y.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),$(y.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),$(y.LinearProgress,"primaryBg",Se(y.primary.main,.5)),$(y.LinearProgress,"secondaryBg",Se(y.secondary.main,.5)),$(y.LinearProgress,"errorBg",Se(y.error.main,.5)),$(y.LinearProgress,"infoBg",Se(y.info.main,.5)),$(y.LinearProgress,"successBg",Se(y.success.main,.5)),$(y.LinearProgress,"warningBg",Se(y.warning.main,.5)),$(y.Skeleton,"bg",`rgba(${M("palette-text-primaryChannel")} / 0.13)`),$(y.Slider,"primaryTrack",Se(y.primary.main,.5)),$(y.Slider,"secondaryTrack",Se(y.secondary.main,.5)),$(y.Slider,"errorTrack",Se(y.error.main,.5)),$(y.Slider,"infoTrack",Se(y.info.main,.5)),$(y.Slider,"successTrack",Se(y.success.main,.5)),$(y.Slider,"warningTrack",Se(y.warning.main,.5));const B=qa(y.background.default,.98);$(y.SnackbarContent,"bg",B),$(y.SnackbarContent,"color",St(()=>y.getContrastText(B))),$(y.SpeedDialAction,"fabHoverBg",qa(y.background.paper,.15)),$(y.StepConnector,"border",M("palette-grey-600")),$(y.StepContent,"border",M("palette-grey-600")),$(y.Switch,"defaultColor",M("palette-grey-300")),$(y.Switch,"defaultDisabledColor",M("palette-grey-600")),$(y.Switch,"primaryDisabledColor",Se(y.primary.main,.55)),$(y.Switch,"secondaryDisabledColor",Se(y.secondary.main,.55)),$(y.Switch,"errorDisabledColor",Se(y.error.main,.55)),$(y.Switch,"infoDisabledColor",Se(y.info.main,.55)),$(y.Switch,"successDisabledColor",Se(y.success.main,.55)),$(y.Switch,"warningDisabledColor",Se(y.warning.main,.55)),$(y.TableCell,"border",Se(Ha(y.divider,1),.68)),$(y.Tooltip,"bg",Ha(y.grey[700],.92))}It(y.background,"default"),It(y.background,"paper"),It(y.common,"background"),It(y.common,"onBackground"),It(y,"divider"),Object.keys(y).forEach(B=>{const G=y[B];B!=="tonalOffset"&&G&&typeof G=="object"&&(G.main&&$(y[B],"mainChannel",Oa(wa(G.main))),G.light&&$(y[B],"lightChannel",Oa(wa(G.light))),G.dark&&$(y[B],"darkChannel",Oa(wa(G.dark))),G.contrastText&&$(y[B],"contrastTextChannel",Oa(wa(G.contrastText))),B==="text"&&(It(y[B],"primary"),It(y[B],"secondary")),B==="action"&&(G.active&&It(y[B],"active"),G.selected&&It(y[B],"selected")))})}),N=t.reduce((k,y)=>Ke(k,y),N);const J={prefix:o,disableCssColorScheme:n,shouldSkipGeneratingVar:s,getSelector:kh(N)},{vars:K,generateThemeVars:j,generateStyleSheets:L}=rh(N,J);return N.vars=K,Object.entries(N.colorSchemes[N.defaultColorScheme]).forEach(([k,y])=>{N[k]=y}),N.generateThemeVars=j,N.generateStyleSheets=L,N.generateSpacing=function(){return zl(c.spacing,Un(this))},N.getColorSchemeSelector=ah(i),N.spacing=N.generateSpacing(),N.shouldSkipGeneratingVar=s,N.unstable_sxConfig={...Ba,...c==null?void 0:c.unstable_sxConfig},N.unstable_sx=function(y){return Hr({sx:y,theme:this})},N.toRuntimeSource=rc,N}function oi(e,t,r){e.colorSchemes&&r&&(e.colorSchemes[t]={...r!==!0&&r,palette:ms({...r===!0?{}:r.palette,mode:t})})}function oc(e={},...t){const{palette:r,cssVariables:a=!1,colorSchemes:n=r?void 0:{light:!0},defaultColorScheme:o=r==null?void 0:r.mode,...s}=e,i=o||"light",l=n==null?void 0:n[i],c={...n,...r?{[i]:{...typeof l!="boolean"&&l,palette:r}}:void 0};if(a===!1){if(!("colorSchemes"in e))return Fo(e,...t);let d=r;"palette"in e||c[i]&&(c[i]!==!0?d=c[i].palette:i==="dark"&&(d={mode:"dark"}));const u=Fo({...e,palette:d},...t);return u.defaultColorScheme=i,u.colorSchemes=c,u.palette.mode==="light"&&(u.colorSchemes.light={...c.light!==!0&&c.light,palette:u.palette},oi(u,"dark",c.dark)),u.palette.mode==="dark"&&(u.colorSchemes.dark={...c.dark!==!0&&c.dark,palette:u.palette},oi(u,"light",c.light)),u}return!r&&!("light"in c)&&i==="light"&&(c.light=!0),Dh({...s,colorSchemes:c,defaultColorScheme:i,...typeof a!="boolean"&&a},...t)}const zh=oc(),Gh="$$material";function fs(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const Jh=e=>fs(e)&&e!=="classes",$t=Kl({themeId:Gh,defaultTheme:zh,rootShouldForwardProp:Jh});process.env.NODE_ENV!=="production"&&(S.node,S.object.isRequired);function gs(e){return Yp(e)}const zr=dh({createStyledComponent:$t("div",{name:"MuiStack",slot:"Root",overridesResolver:(e,t)=>t.root}),useThemeProps:e=>gs({props:e,name:"MuiStack"})});process.env.NODE_ENV!=="production"&&(zr.propTypes={children:S.node,component:S.elementType,direction:S.oneOfType([S.oneOf(["column-reverse","column","row-reverse","row"]),S.arrayOf(S.oneOf(["column-reverse","column","row-reverse","row"])),S.object]),divider:S.node,spacing:S.oneOfType([S.arrayOf(S.oneOfType([S.number,S.string])),S.number,S.object,S.string]),sx:S.oneOfType([S.arrayOf(S.oneOfType([S.func,S.object,S.bool])),S.func,S.object]),useFlexGap:S.bool});const oe=e=>typeof e=="string",pa=()=>{let e,t;const r=new Promise((a,n)=>{e=a,t=n});return r.resolve=e,r.reject=t,r},si=e=>e==null?"":""+e,Hh=(e,t,r)=>{e.forEach(a=>{t[a]&&(r[a]=t[a])})},qh=/###/g,ii=e=>e&&e.indexOf("###")>-1?e.replace(qh,"."):e,li=e=>!e||oe(e),Pa=(e,t,r)=>{const a=oe(t)?t.split("."):t;let n=0;for(;n<a.length-1;){if(li(e))return{};const o=ii(a[n]);!e[o]&&r&&(e[o]=new r),Object.prototype.hasOwnProperty.call(e,o)?e=e[o]:e={},++n}return li(e)?{}:{obj:e,k:ii(a[n])}},ci=(e,t,r)=>{const{obj:a,k:n}=Pa(e,t,Object);if(a!==void 0||t.length===1){a[n]=r;return}let o=t[t.length-1],s=t.slice(0,t.length-1),i=Pa(e,s,Object);for(;i.obj===void 0&&s.length;)o=`${s[s.length-1]}.${o}`,s=s.slice(0,s.length-1),i=Pa(e,s,Object),i!=null&&i.obj&&typeof i.obj[`${i.k}.${o}`]<"u"&&(i.obj=void 0);i.obj[`${i.k}.${o}`]=r},Wh=(e,t,r,a)=>{const{obj:n,k:o}=Pa(e,t,Object);n[o]=n[o]||[],n[o].push(r)},xn=(e,t)=>{const{obj:r,k:a}=Pa(e,t);if(r&&Object.prototype.hasOwnProperty.call(r,a))return r[a]},Kh=(e,t,r)=>{const a=xn(e,r);return a!==void 0?a:xn(t,r)},sc=(e,t,r)=>{for(const a in t)a!=="__proto__"&&a!=="constructor"&&(a in e?oe(e[a])||e[a]instanceof String||oe(t[a])||t[a]instanceof String?r&&(e[a]=t[a]):sc(e[a],t[a],r):e[a]=t[a]);return e},Er=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var Qh={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};const Yh=e=>oe(e)?e.replace(/[&<>"'\/]/g,t=>Qh[t]):e;class Xh{constructor(t){this.capacity=t,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(t){const r=this.regExpMap.get(t);if(r!==void 0)return r;const a=new RegExp(t);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(t,a),this.regExpQueue.push(t),a}}const Zh=[" ",",","?","!",";"],em=new Xh(20),tm=(e,t,r)=>{t=t||"",r=r||"";const a=Zh.filter(s=>t.indexOf(s)<0&&r.indexOf(s)<0);if(a.length===0)return!0;const n=em.getRegExp(`(${a.map(s=>s==="?"?"\\?":s).join("|")})`);let o=!n.test(e);if(!o){const s=e.indexOf(r);s>0&&!n.test(e.substring(0,s))&&(o=!0)}return o},No=function(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".";if(!e)return;if(e[t])return Object.prototype.hasOwnProperty.call(e,t)?e[t]:void 0;const a=t.split(r);let n=e;for(let o=0;o<a.length;){if(!n||typeof n!="object")return;let s,i="";for(let l=o;l<a.length;++l)if(l!==o&&(i+=r),i+=a[l],s=n[i],s!==void 0){if(["string","number","boolean"].indexOf(typeof s)>-1&&l<a.length-1)continue;o+=l-o+1;break}n=s}return n},On=e=>e==null?void 0:e.replace("_","-"),rm={type:"logger",log(e){this.output("log",e)},warn(e){this.output("warn",e)},error(e){this.output("error",e)},output(e,t){var r,a;(a=(r=console==null?void 0:console[e])==null?void 0:r.apply)==null||a.call(r,console,t)}};class wn{constructor(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.init(t,r)}init(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.prefix=r.prefix||"i18next:",this.logger=t||rm,this.options=r,this.debug=r.debug}log(){for(var t=arguments.length,r=new Array(t),a=0;a<t;a++)r[a]=arguments[a];return this.forward(r,"log","",!0)}warn(){for(var t=arguments.length,r=new Array(t),a=0;a<t;a++)r[a]=arguments[a];return this.forward(r,"warn","",!0)}error(){for(var t=arguments.length,r=new Array(t),a=0;a<t;a++)r[a]=arguments[a];return this.forward(r,"error","")}deprecate(){for(var t=arguments.length,r=new Array(t),a=0;a<t;a++)r[a]=arguments[a];return this.forward(r,"warn","WARNING DEPRECATED: ",!0)}forward(t,r,a,n){return n&&!this.debug?null:(oe(t[0])&&(t[0]=`${a}${this.prefix} ${t[0]}`),this.logger[r](t))}create(t){return new wn(this.logger,{prefix:`${this.prefix}:${t}:`,...this.options})}clone(t){return t=t||this.options,t.prefix=t.prefix||this.prefix,new wn(this.logger,t)}}var Ct=new wn;class Gn{constructor(){this.observers={}}on(t,r){return t.split(" ").forEach(a=>{this.observers[a]||(this.observers[a]=new Map);const n=this.observers[a].get(r)||0;this.observers[a].set(r,n+1)}),this}off(t,r){if(this.observers[t]){if(!r){delete this.observers[t];return}this.observers[t].delete(r)}}emit(t){for(var r=arguments.length,a=new Array(r>1?r-1:0),n=1;n<r;n++)a[n-1]=arguments[n];this.observers[t]&&Array.from(this.observers[t].entries()).forEach(s=>{let[i,l]=s;for(let c=0;c<l;c++)i(...a)}),this.observers["*"]&&Array.from(this.observers["*"].entries()).forEach(s=>{let[i,l]=s;for(let c=0;c<l;c++)i.apply(i,[t,...a])})}}class di extends Gn{constructor(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{ns:["translation"],defaultNS:"translation"};super(),this.data=t||{},this.options=r,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.options.ignoreJSONStructure===void 0&&(this.options.ignoreJSONStructure=!0)}addNamespaces(t){this.options.ns.indexOf(t)<0&&this.options.ns.push(t)}removeNamespaces(t){const r=this.options.ns.indexOf(t);r>-1&&this.options.ns.splice(r,1)}getResource(t,r,a){var c,d;let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const o=n.keySeparator!==void 0?n.keySeparator:this.options.keySeparator,s=n.ignoreJSONStructure!==void 0?n.ignoreJSONStructure:this.options.ignoreJSONStructure;let i;t.indexOf(".")>-1?i=t.split("."):(i=[t,r],a&&(Array.isArray(a)?i.push(...a):oe(a)&&o?i.push(...a.split(o)):i.push(a)));const l=xn(this.data,i);return!l&&!r&&!a&&t.indexOf(".")>-1&&(t=i[0],r=i[1],a=i.slice(2).join(".")),l||!s||!oe(a)?l:No((d=(c=this.data)==null?void 0:c[t])==null?void 0:d[r],a,o)}addResource(t,r,a,n){let o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{silent:!1};const s=o.keySeparator!==void 0?o.keySeparator:this.options.keySeparator;let i=[t,r];a&&(i=i.concat(s?a.split(s):a)),t.indexOf(".")>-1&&(i=t.split("."),n=r,r=i[1]),this.addNamespaces(r),ci(this.data,i,n),o.silent||this.emit("added",t,r,a,n)}addResources(t,r,a){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{silent:!1};for(const o in a)(oe(a[o])||Array.isArray(a[o]))&&this.addResource(t,r,o,a[o],{silent:!0});n.silent||this.emit("added",t,r,a)}addResourceBundle(t,r,a,n,o){let s=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{silent:!1,skipCopy:!1},i=[t,r];t.indexOf(".")>-1&&(i=t.split("."),n=a,a=r,r=i[1]),this.addNamespaces(r);let l=xn(this.data,i)||{};s.skipCopy||(a=JSON.parse(JSON.stringify(a))),n?sc(l,a,o):l={...l,...a},ci(this.data,i,l),s.silent||this.emit("added",t,r,a)}removeResourceBundle(t,r){this.hasResourceBundle(t,r)&&delete this.data[t][r],this.removeNamespaces(r),this.emit("removed",t,r)}hasResourceBundle(t,r){return this.getResource(t,r)!==void 0}getResourceBundle(t,r){return r||(r=this.options.defaultNS),this.getResource(t,r)}getDataByLanguage(t){return this.data[t]}hasLanguageSomeTranslations(t){const r=this.getDataByLanguage(t);return!!(r&&Object.keys(r)||[]).find(n=>r[n]&&Object.keys(r[n]).length>0)}toJSON(){return this.data}}var ic={processors:{},addPostProcessor(e){this.processors[e.name]=e},handle(e,t,r,a,n){return e.forEach(o=>{var s;t=((s=this.processors[o])==null?void 0:s.process(t,r,a,n))??t}),t}};const ui={},pi=e=>!oe(e)&&typeof e!="boolean"&&typeof e!="number";class Cn extends Gn{constructor(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};super(),Hh(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],t,this),this.options=r,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.logger=Ct.create("translator")}changeLanguage(t){t&&(this.language=t)}exists(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};if(t==null)return!1;const a=this.resolve(t,r);return(a==null?void 0:a.res)!==void 0}extractFromKey(t,r){let a=r.nsSeparator!==void 0?r.nsSeparator:this.options.nsSeparator;a===void 0&&(a=":");const n=r.keySeparator!==void 0?r.keySeparator:this.options.keySeparator;let o=r.ns||this.options.defaultNS||[];const s=a&&t.indexOf(a)>-1,i=!this.options.userDefinedKeySeparator&&!r.keySeparator&&!this.options.userDefinedNsSeparator&&!r.nsSeparator&&!tm(t,a,n);if(s&&!i){const l=t.match(this.interpolator.nestingRegexp);if(l&&l.length>0)return{key:t,namespaces:oe(o)?[o]:o};const c=t.split(a);(a!==n||a===n&&this.options.ns.indexOf(c[0])>-1)&&(o=c.shift()),t=c.join(n)}return{key:t,namespaces:oe(o)?[o]:o}}translate(t,r,a){if(typeof r!="object"&&this.options.overloadTranslationOptionHandler&&(r=this.options.overloadTranslationOptionHandler(arguments)),typeof r=="object"&&(r={...r}),r||(r={}),t==null)return"";Array.isArray(t)||(t=[String(t)]);const n=r.returnDetails!==void 0?r.returnDetails:this.options.returnDetails,o=r.keySeparator!==void 0?r.keySeparator:this.options.keySeparator,{key:s,namespaces:i}=this.extractFromKey(t[t.length-1],r),l=i[i.length-1],c=r.lng||this.language,d=r.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if((c==null?void 0:c.toLowerCase())==="cimode"){if(d){const M=r.nsSeparator||this.options.nsSeparator;return n?{res:`${l}${M}${s}`,usedKey:s,exactUsedKey:s,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(r)}:`${l}${M}${s}`}return n?{res:s,usedKey:s,exactUsedKey:s,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(r)}:s}const u=this.resolve(t,r);let p=u==null?void 0:u.res;const m=(u==null?void 0:u.usedKey)||s,g=(u==null?void 0:u.exactUsedKey)||s,h=["[object Number]","[object Function]","[object RegExp]"],x=r.joinArrays!==void 0?r.joinArrays:this.options.joinArrays,E=!this.i18nFormat||this.i18nFormat.handleAsObject,U=r.count!==void 0&&!oe(r.count),F=Cn.hasDefaultValue(r),N=U?this.pluralResolver.getSuffix(c,r.count,r):"",J=r.ordinal&&U?this.pluralResolver.getSuffix(c,r.count,{ordinal:!1}):"",K=U&&!r.ordinal&&r.count===0,j=K&&r[`defaultValue${this.options.pluralSeparator}zero`]||r[`defaultValue${N}`]||r[`defaultValue${J}`]||r.defaultValue;let L=p;E&&!p&&F&&(L=j);const k=pi(L),y=Object.prototype.toString.apply(L);if(E&&L&&k&&h.indexOf(y)<0&&!(oe(x)&&Array.isArray(L))){if(!r.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const M=this.options.returnedObjectHandler?this.options.returnedObjectHandler(m,L,{...r,ns:i}):`key '${s} (${this.language})' returned an object instead of string.`;return n?(u.res=M,u.usedParams=this.getUsedParamsDetails(r),u):M}if(o){const M=Array.isArray(L),B=M?[]:{},G=M?g:m;for(const D in L)if(Object.prototype.hasOwnProperty.call(L,D)){const re=`${G}${o}${D}`;F&&!p?B[D]=this.translate(re,{...r,defaultValue:pi(j)?j[D]:void 0,joinArrays:!1,ns:i}):B[D]=this.translate(re,{...r,joinArrays:!1,ns:i}),B[D]===re&&(B[D]=L[D])}p=B}}else if(E&&oe(x)&&Array.isArray(p))p=p.join(x),p&&(p=this.extendTranslation(p,t,r,a));else{let M=!1,B=!1;!this.isValidLookup(p)&&F&&(M=!0,p=j),this.isValidLookup(p)||(B=!0,p=s);const D=(r.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&B?void 0:p,re=F&&j!==p&&this.options.updateMissing;if(B||M||re){if(this.logger.log(re?"updateKey":"missingKey",c,l,s,re?j:p),o){const ce=this.resolve(s,{...r,keySeparator:!1});ce&&ce.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let Z=[];const xe=this.languageUtils.getFallbackCodes(this.options.fallbackLng,r.lng||this.language);if(this.options.saveMissingTo==="fallback"&&xe&&xe[0])for(let ce=0;ce<xe.length;ce++)Z.push(xe[ce]);else this.options.saveMissingTo==="all"?Z=this.languageUtils.toResolveHierarchy(r.lng||this.language):Z.push(r.lng||this.language);const X=(ce,fe,le)=>{var _t;const He=F&&le!==p?le:D;this.options.missingKeyHandler?this.options.missingKeyHandler(ce,l,fe,He,re,r):(_t=this.backendConnector)!=null&&_t.saveMissing&&this.backendConnector.saveMissing(ce,l,fe,He,re,r),this.emit("missingKey",ce,l,fe,p)};this.options.saveMissing&&(this.options.saveMissingPlurals&&U?Z.forEach(ce=>{const fe=this.pluralResolver.getSuffixes(ce,r);K&&r[`defaultValue${this.options.pluralSeparator}zero`]&&fe.indexOf(`${this.options.pluralSeparator}zero`)<0&&fe.push(`${this.options.pluralSeparator}zero`),fe.forEach(le=>{X([ce],s+le,r[`defaultValue${le}`]||j)})}):X(Z,s,j))}p=this.extendTranslation(p,t,r,u,a),B&&p===s&&this.options.appendNamespaceToMissingKey&&(p=`${l}:${s}`),(B||M)&&this.options.parseMissingKeyHandler&&(p=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${l}:${s}`:s,M?p:void 0))}return n?(u.res=p,u.usedParams=this.getUsedParamsDetails(r),u):p}extendTranslation(t,r,a,n,o){var c,d;var s=this;if((c=this.i18nFormat)!=null&&c.parse)t=this.i18nFormat.parse(t,{...this.options.interpolation.defaultVariables,...a},a.lng||this.language||n.usedLng,n.usedNS,n.usedKey,{resolved:n});else if(!a.skipInterpolation){a.interpolation&&this.interpolator.init({...a,interpolation:{...this.options.interpolation,...a.interpolation}});const u=oe(t)&&(((d=a==null?void 0:a.interpolation)==null?void 0:d.skipOnVariables)!==void 0?a.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let p;if(u){const g=t.match(this.interpolator.nestingRegexp);p=g&&g.length}let m=a.replace&&!oe(a.replace)?a.replace:a;if(this.options.interpolation.defaultVariables&&(m={...this.options.interpolation.defaultVariables,...m}),t=this.interpolator.interpolate(t,m,a.lng||this.language||n.usedLng,a),u){const g=t.match(this.interpolator.nestingRegexp),h=g&&g.length;p<h&&(a.nest=!1)}!a.lng&&n&&n.res&&(a.lng=this.language||n.usedLng),a.nest!==!1&&(t=this.interpolator.nest(t,function(){for(var g=arguments.length,h=new Array(g),x=0;x<g;x++)h[x]=arguments[x];return(o==null?void 0:o[0])===h[0]&&!a.context?(s.logger.warn(`It seems you are nesting recursively key: ${h[0]} in key: ${r[0]}`),null):s.translate(...h,r)},a)),a.interpolation&&this.interpolator.reset()}const i=a.postProcess||this.options.postProcess,l=oe(i)?[i]:i;return t!=null&&(l!=null&&l.length)&&a.applyPostProcessor!==!1&&(t=ic.handle(l,t,r,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...n,usedParams:this.getUsedParamsDetails(a)},...a}:a,this)),t}resolve(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a,n,o,s,i;return oe(t)&&(t=[t]),t.forEach(l=>{if(this.isValidLookup(a))return;const c=this.extractFromKey(l,r),d=c.key;n=d;let u=c.namespaces;this.options.fallbackNS&&(u=u.concat(this.options.fallbackNS));const p=r.count!==void 0&&!oe(r.count),m=p&&!r.ordinal&&r.count===0,g=r.context!==void 0&&(oe(r.context)||typeof r.context=="number")&&r.context!=="",h=r.lngs?r.lngs:this.languageUtils.toResolveHierarchy(r.lng||this.language,r.fallbackLng);u.forEach(x=>{var E,U;this.isValidLookup(a)||(i=x,!ui[`${h[0]}-${x}`]&&((E=this.utils)!=null&&E.hasLoadedNamespace)&&!((U=this.utils)!=null&&U.hasLoadedNamespace(i))&&(ui[`${h[0]}-${x}`]=!0,this.logger.warn(`key "${n}" for languages "${h.join(", ")}" won't get resolved as namespace "${i}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),h.forEach(F=>{var K;if(this.isValidLookup(a))return;s=F;const N=[d];if((K=this.i18nFormat)!=null&&K.addLookupKeys)this.i18nFormat.addLookupKeys(N,d,F,x,r);else{let j;p&&(j=this.pluralResolver.getSuffix(F,r.count,r));const L=`${this.options.pluralSeparator}zero`,k=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(p&&(N.push(d+j),r.ordinal&&j.indexOf(k)===0&&N.push(d+j.replace(k,this.options.pluralSeparator)),m&&N.push(d+L)),g){const y=`${d}${this.options.contextSeparator}${r.context}`;N.push(y),p&&(N.push(y+j),r.ordinal&&j.indexOf(k)===0&&N.push(y+j.replace(k,this.options.pluralSeparator)),m&&N.push(y+L))}}let J;for(;J=N.pop();)this.isValidLookup(a)||(o=J,a=this.getResource(F,x,J,r))}))})}),{res:a,usedKey:n,exactUsedKey:o,usedLng:s,usedNS:i}}isValidLookup(t){return t!==void 0&&!(!this.options.returnNull&&t===null)&&!(!this.options.returnEmptyString&&t==="")}getResource(t,r,a){var o;let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return(o=this.i18nFormat)!=null&&o.getResource?this.i18nFormat.getResource(t,r,a,n):this.resourceStore.getResource(t,r,a,n)}getUsedParamsDetails(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const r=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],a=t.replace&&!oe(t.replace);let n=a?t.replace:t;if(a&&typeof t.count<"u"&&(n.count=t.count),this.options.interpolation.defaultVariables&&(n={...this.options.interpolation.defaultVariables,...n}),!a){n={...n};for(const o of r)delete n[o]}return n}static hasDefaultValue(t){const r="defaultValue";for(const a in t)if(Object.prototype.hasOwnProperty.call(t,a)&&r===a.substring(0,r.length)&&t[a]!==void 0)return!0;return!1}}class hi{constructor(t){this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=Ct.create("languageUtils")}getScriptPartFromCode(t){if(t=On(t),!t||t.indexOf("-")<0)return null;const r=t.split("-");return r.length===2||(r.pop(),r[r.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(r.join("-"))}getLanguagePartFromCode(t){if(t=On(t),!t||t.indexOf("-")<0)return t;const r=t.split("-");return this.formatLanguageCode(r[0])}formatLanguageCode(t){if(oe(t)&&t.indexOf("-")>-1){let r;try{r=Intl.getCanonicalLocales(t)[0]}catch{}return r&&this.options.lowerCaseLng&&(r=r.toLowerCase()),r||(this.options.lowerCaseLng?t.toLowerCase():t)}return this.options.cleanCode||this.options.lowerCaseLng?t.toLowerCase():t}isSupportedCode(t){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(t=this.getLanguagePartFromCode(t)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(t)>-1}getBestMatchFromCodes(t){if(!t)return null;let r;return t.forEach(a=>{if(r)return;const n=this.formatLanguageCode(a);(!this.options.supportedLngs||this.isSupportedCode(n))&&(r=n)}),!r&&this.options.supportedLngs&&t.forEach(a=>{if(r)return;const n=this.getLanguagePartFromCode(a);if(this.isSupportedCode(n))return r=n;r=this.options.supportedLngs.find(o=>{if(o===n)return o;if(!(o.indexOf("-")<0&&n.indexOf("-")<0)&&(o.indexOf("-")>0&&n.indexOf("-")<0&&o.substring(0,o.indexOf("-"))===n||o.indexOf(n)===0&&n.length>1))return o})}),r||(r=this.getFallbackCodes(this.options.fallbackLng)[0]),r}getFallbackCodes(t,r){if(!t)return[];if(typeof t=="function"&&(t=t(r)),oe(t)&&(t=[t]),Array.isArray(t))return t;if(!r)return t.default||[];let a=t[r];return a||(a=t[this.getScriptPartFromCode(r)]),a||(a=t[this.formatLanguageCode(r)]),a||(a=t[this.getLanguagePartFromCode(r)]),a||(a=t.default),a||[]}toResolveHierarchy(t,r){const a=this.getFallbackCodes(r||this.options.fallbackLng||[],t),n=[],o=s=>{s&&(this.isSupportedCode(s)?n.push(s):this.logger.warn(`rejecting language code not found in supportedLngs: ${s}`))};return oe(t)&&(t.indexOf("-")>-1||t.indexOf("_")>-1)?(this.options.load!=="languageOnly"&&o(this.formatLanguageCode(t)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&o(this.getScriptPartFromCode(t)),this.options.load!=="currentOnly"&&o(this.getLanguagePartFromCode(t))):oe(t)&&o(this.formatLanguageCode(t)),a.forEach(s=>{n.indexOf(s)<0&&o(this.formatLanguageCode(s))}),n}}const mi={zero:0,one:1,two:2,few:3,many:4,other:5},fi={select:e=>e===1?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})};class am{constructor(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.languageUtils=t,this.options=r,this.logger=Ct.create("pluralResolver"),this.pluralRulesCache={}}addRule(t,r){this.rules[t]=r}clearCache(){this.pluralRulesCache={}}getRule(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const a=On(t==="dev"?"en":t),n=r.ordinal?"ordinal":"cardinal",o=JSON.stringify({cleanedCode:a,type:n});if(o in this.pluralRulesCache)return this.pluralRulesCache[o];let s;try{s=new Intl.PluralRules(a,{type:n})}catch{if(!Intl)return this.logger.error("No Intl support, please use an Intl polyfill!"),fi;if(!t.match(/-|_/))return fi;const l=this.languageUtils.getLanguagePartFromCode(t);s=this.getRule(l,r)}return this.pluralRulesCache[o]=s,s}needsPlural(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=this.getRule(t,r);return a||(a=this.getRule("dev",r)),(a==null?void 0:a.resolvedOptions().pluralCategories.length)>1}getPluralFormsOfKey(t,r){let a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.getSuffixes(t,a).map(n=>`${r}${n}`)}getSuffixes(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=this.getRule(t,r);return a||(a=this.getRule("dev",r)),a?a.resolvedOptions().pluralCategories.sort((n,o)=>mi[n]-mi[o]).map(n=>`${this.options.prepend}${r.ordinal?`ordinal${this.options.prepend}`:""}${n}`):[]}getSuffix(t,r){let a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const n=this.getRule(t,a);return n?`${this.options.prepend}${a.ordinal?`ordinal${this.options.prepend}`:""}${n.select(r)}`:(this.logger.warn(`no plural rule found for: ${t}`),this.getSuffix("dev",r,a))}}const gi=function(e,t,r){let a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:".",n=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,o=Kh(e,t,r);return!o&&n&&oe(r)&&(o=No(e,r,a),o===void 0&&(o=No(t,r,a))),o},So=e=>e.replace(/\$/g,"$$$$");class nm{constructor(){var r;let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=Ct.create("interpolator"),this.options=t,this.format=((r=t==null?void 0:t.interpolation)==null?void 0:r.format)||(a=>a),this.init(t)}init(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};t.interpolation||(t.interpolation={escapeValue:!0});const{escape:r,escapeValue:a,useRawValueToEscape:n,prefix:o,prefixEscaped:s,suffix:i,suffixEscaped:l,formatSeparator:c,unescapeSuffix:d,unescapePrefix:u,nestingPrefix:p,nestingPrefixEscaped:m,nestingSuffix:g,nestingSuffixEscaped:h,nestingOptionsSeparator:x,maxReplaces:E,alwaysFormat:U}=t.interpolation;this.escape=r!==void 0?r:Yh,this.escapeValue=a!==void 0?a:!0,this.useRawValueToEscape=n!==void 0?n:!1,this.prefix=o?Er(o):s||"{{",this.suffix=i?Er(i):l||"}}",this.formatSeparator=c||",",this.unescapePrefix=d?"":u||"-",this.unescapeSuffix=this.unescapePrefix?"":d||"",this.nestingPrefix=p?Er(p):m||Er("$t("),this.nestingSuffix=g?Er(g):h||Er(")"),this.nestingOptionsSeparator=x||",",this.maxReplaces=E||1e3,this.alwaysFormat=U!==void 0?U:!1,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const t=(r,a)=>(r==null?void 0:r.source)===a?(r.lastIndex=0,r):new RegExp(a,"g");this.regexp=t(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=t(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=t(this.nestingRegexp,`${this.nestingPrefix}(.+?)${this.nestingSuffix}`)}interpolate(t,r,a,n){var m;let o,s,i;const l=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},c=g=>{if(g.indexOf(this.formatSeparator)<0){const U=gi(r,l,g,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(U,void 0,a,{...n,...r,interpolationkey:g}):U}const h=g.split(this.formatSeparator),x=h.shift().trim(),E=h.join(this.formatSeparator).trim();return this.format(gi(r,l,x,this.options.keySeparator,this.options.ignoreJSONStructure),E,a,{...n,...r,interpolationkey:x})};this.resetRegExp();const d=(n==null?void 0:n.missingInterpolationHandler)||this.options.missingInterpolationHandler,u=((m=n==null?void 0:n.interpolation)==null?void 0:m.skipOnVariables)!==void 0?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:g=>So(g)},{regex:this.regexp,safeValue:g=>this.escapeValue?So(this.escape(g)):So(g)}].forEach(g=>{for(i=0;o=g.regex.exec(t);){const h=o[1].trim();if(s=c(h),s===void 0)if(typeof d=="function"){const E=d(t,o,n);s=oe(E)?E:""}else if(n&&Object.prototype.hasOwnProperty.call(n,h))s="";else if(u){s=o[0];continue}else this.logger.warn(`missed to pass in variable ${h} for interpolating ${t}`),s="";else!oe(s)&&!this.useRawValueToEscape&&(s=si(s));const x=g.safeValue(s);if(t=t.replace(o[0],x),u?(g.regex.lastIndex+=s.length,g.regex.lastIndex-=o[0].length):g.regex.lastIndex=0,i++,i>=this.maxReplaces)break}}),t}nest(t,r){let a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n,o,s;const i=(l,c)=>{const d=this.nestingOptionsSeparator;if(l.indexOf(d)<0)return l;const u=l.split(new RegExp(`${d}[ ]*{`));let p=`{${u[1]}`;l=u[0],p=this.interpolate(p,s);const m=p.match(/'/g),g=p.match(/"/g);(((m==null?void 0:m.length)??0)%2===0&&!g||g.length%2!==0)&&(p=p.replace(/'/g,'"'));try{s=JSON.parse(p),c&&(s={...c,...s})}catch(h){return this.logger.warn(`failed parsing options string in nesting for key ${l}`,h),`${l}${d}${p}`}return s.defaultValue&&s.defaultValue.indexOf(this.prefix)>-1&&delete s.defaultValue,l};for(;n=this.nestingRegexp.exec(t);){let l=[];s={...a},s=s.replace&&!oe(s.replace)?s.replace:s,s.applyPostProcessor=!1,delete s.defaultValue;let c=!1;if(n[0].indexOf(this.formatSeparator)!==-1&&!/{.*}/.test(n[1])){const d=n[1].split(this.formatSeparator).map(u=>u.trim());n[1]=d.shift(),l=d,c=!0}if(o=r(i.call(this,n[1].trim(),s),s),o&&n[0]===t&&!oe(o))return o;oe(o)||(o=si(o)),o||(this.logger.warn(`missed to resolve ${n[1]} for nesting ${t}`),o=""),c&&(o=l.reduce((d,u)=>this.format(d,u,a.lng,{...a,interpolationkey:n[1].trim()}),o.trim())),t=t.replace(n[0],o),this.regexp.lastIndex=0}return t}}const om=e=>{let t=e.toLowerCase().trim();const r={};if(e.indexOf("(")>-1){const a=e.split("(");t=a[0].toLowerCase().trim();const n=a[1].substring(0,a[1].length-1);t==="currency"&&n.indexOf(":")<0?r.currency||(r.currency=n.trim()):t==="relativetime"&&n.indexOf(":")<0?r.range||(r.range=n.trim()):n.split(";").forEach(s=>{if(s){const[i,...l]=s.split(":"),c=l.join(":").trim().replace(/^'+|'+$/g,""),d=i.trim();r[d]||(r[d]=c),c==="false"&&(r[d]=!1),c==="true"&&(r[d]=!0),isNaN(c)||(r[d]=parseInt(c,10))}})}return{formatName:t,formatOptions:r}},Ir=e=>{const t={};return(r,a,n)=>{let o=n;n&&n.interpolationkey&&n.formatParams&&n.formatParams[n.interpolationkey]&&n[n.interpolationkey]&&(o={...o,[n.interpolationkey]:void 0});const s=a+JSON.stringify(o);let i=t[s];return i||(i=e(On(a),n),t[s]=i),i(r)}};class sm{constructor(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=Ct.create("formatter"),this.options=t,this.formats={number:Ir((r,a)=>{const n=new Intl.NumberFormat(r,{...a});return o=>n.format(o)}),currency:Ir((r,a)=>{const n=new Intl.NumberFormat(r,{...a,style:"currency"});return o=>n.format(o)}),datetime:Ir((r,a)=>{const n=new Intl.DateTimeFormat(r,{...a});return o=>n.format(o)}),relativetime:Ir((r,a)=>{const n=new Intl.RelativeTimeFormat(r,{...a});return o=>n.format(o,a.range||"day")}),list:Ir((r,a)=>{const n=new Intl.ListFormat(r,{...a});return o=>n.format(o)})},this.init(t)}init(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};this.formatSeparator=r.interpolation.formatSeparator||","}add(t,r){this.formats[t.toLowerCase().trim()]=r}addCached(t,r){this.formats[t.toLowerCase().trim()]=Ir(r)}format(t,r,a){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const o=r.split(this.formatSeparator);if(o.length>1&&o[0].indexOf("(")>1&&o[0].indexOf(")")<0&&o.find(i=>i.indexOf(")")>-1)){const i=o.findIndex(l=>l.indexOf(")")>-1);o[0]=[o[0],...o.splice(1,i)].join(this.formatSeparator)}return o.reduce((i,l)=>{var u;const{formatName:c,formatOptions:d}=om(l);if(this.formats[c]){let p=i;try{const m=((u=n==null?void 0:n.formatParams)==null?void 0:u[n.interpolationkey])||{},g=m.locale||m.lng||n.locale||n.lng||a;p=this.formats[c](i,g,{...d,...n,...m})}catch(m){this.logger.warn(m)}return p}else this.logger.warn(`there was no format function for ${c}`);return i},t)}}const im=(e,t)=>{e.pending[t]!==void 0&&(delete e.pending[t],e.pendingCount--)};class lm extends Gn{constructor(t,r,a){var o,s;let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};super(),this.backend=t,this.store=r,this.services=a,this.languageUtils=a.languageUtils,this.options=n,this.logger=Ct.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=n.maxParallelReads||10,this.readingCalls=0,this.maxRetries=n.maxRetries>=0?n.maxRetries:5,this.retryTimeout=n.retryTimeout>=1?n.retryTimeout:350,this.state={},this.queue=[],(s=(o=this.backend)==null?void 0:o.init)==null||s.call(o,a,n.backend,n)}queueLoad(t,r,a,n){const o={},s={},i={},l={};return t.forEach(c=>{let d=!0;r.forEach(u=>{const p=`${c}|${u}`;!a.reload&&this.store.hasResourceBundle(c,u)?this.state[p]=2:this.state[p]<0||(this.state[p]===1?s[p]===void 0&&(s[p]=!0):(this.state[p]=1,d=!1,s[p]===void 0&&(s[p]=!0),o[p]===void 0&&(o[p]=!0),l[u]===void 0&&(l[u]=!0)))}),d||(i[c]=!0)}),(Object.keys(o).length||Object.keys(s).length)&&this.queue.push({pending:s,pendingCount:Object.keys(s).length,loaded:{},errors:[],callback:n}),{toLoad:Object.keys(o),pending:Object.keys(s),toLoadLanguages:Object.keys(i),toLoadNamespaces:Object.keys(l)}}loaded(t,r,a){const n=t.split("|"),o=n[0],s=n[1];r&&this.emit("failedLoading",o,s,r),!r&&a&&this.store.addResourceBundle(o,s,a,void 0,void 0,{skipCopy:!0}),this.state[t]=r?-1:2,r&&a&&(this.state[t]=0);const i={};this.queue.forEach(l=>{Wh(l.loaded,[o],s),im(l,t),r&&l.errors.push(r),l.pendingCount===0&&!l.done&&(Object.keys(l.loaded).forEach(c=>{i[c]||(i[c]={});const d=l.loaded[c];d.length&&d.forEach(u=>{i[c][u]===void 0&&(i[c][u]=!0)})}),l.done=!0,l.errors.length?l.callback(l.errors):l.callback())}),this.emit("loaded",i),this.queue=this.queue.filter(l=>!l.done)}read(t,r,a){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:this.retryTimeout,s=arguments.length>5?arguments[5]:void 0;if(!t.length)return s(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:t,ns:r,fcName:a,tried:n,wait:o,callback:s});return}this.readingCalls++;const i=(c,d)=>{if(this.readingCalls--,this.waitingReads.length>0){const u=this.waitingReads.shift();this.read(u.lng,u.ns,u.fcName,u.tried,u.wait,u.callback)}if(c&&d&&n<this.maxRetries){setTimeout(()=>{this.read.call(this,t,r,a,n+1,o*2,s)},o);return}s(c,d)},l=this.backend[a].bind(this.backend);if(l.length===2){try{const c=l(t,r);c&&typeof c.then=="function"?c.then(d=>i(null,d)).catch(i):i(null,c)}catch(c){i(c)}return}return l(t,r,i)}prepareLoading(t,r){let a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),n&&n();oe(t)&&(t=this.languageUtils.toResolveHierarchy(t)),oe(r)&&(r=[r]);const o=this.queueLoad(t,r,a,n);if(!o.toLoad.length)return o.pending.length||n(),null;o.toLoad.forEach(s=>{this.loadOne(s)})}load(t,r,a){this.prepareLoading(t,r,{},a)}reload(t,r,a){this.prepareLoading(t,r,{reload:!0},a)}loadOne(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";const a=t.split("|"),n=a[0],o=a[1];this.read(n,o,"read",void 0,void 0,(s,i)=>{s&&this.logger.warn(`${r}loading namespace ${o} for language ${n} failed`,s),!s&&i&&this.logger.log(`${r}loaded namespace ${o} for language ${n}`,i),this.loaded(t,s,i)})}saveMissing(t,r,a,n,o){var l,c,d,u,p;let s=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{},i=arguments.length>6&&arguments[6]!==void 0?arguments[6]:()=>{};if((c=(l=this.services)==null?void 0:l.utils)!=null&&c.hasLoadedNamespace&&!((u=(d=this.services)==null?void 0:d.utils)!=null&&u.hasLoadedNamespace(r))){this.logger.warn(`did not save key "${a}" as the namespace "${r}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");return}if(!(a==null||a==="")){if((p=this.backend)!=null&&p.create){const m={...s,isUpdate:o},g=this.backend.create.bind(this.backend);if(g.length<6)try{let h;g.length===5?h=g(t,r,a,n,m):h=g(t,r,a,n),h&&typeof h.then=="function"?h.then(x=>i(null,x)).catch(i):i(null,h)}catch(h){i(h)}else g(t,r,a,n,i,m)}!t||!t[0]||this.store.addResource(t[0],r,a,n)}}}const yi=()=>({debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if(typeof e[1]=="object"&&(t=e[1]),oe(e[1])&&(t.defaultValue=e[1]),oe(e[2])&&(t.tDescription=e[2]),typeof e[2]=="object"||typeof e[3]=="object"){const r=e[3]||e[2];Object.keys(r).forEach(a=>{t[a]=r[a]})}return t},interpolation:{escapeValue:!0,format:e=>e,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}),bi=e=>{var t,r;return oe(e.ns)&&(e.ns=[e.ns]),oe(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),oe(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),((r=(t=e.supportedLngs)==null?void 0:t.indexOf)==null?void 0:r.call(t,"cimode"))<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),typeof e.initImmediate=="boolean"&&(e.initAsync=e.initImmediate),e},Wa=()=>{},cm=e=>{Object.getOwnPropertyNames(Object.getPrototypeOf(e)).forEach(r=>{typeof e[r]=="function"&&(e[r]=e[r].bind(e))})};class Ea extends Gn{constructor(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;if(super(),this.options=bi(t),this.services={},this.logger=Ct,this.modules={external:[]},cm(this),r&&!this.isInitialized&&!t.isClone){if(!this.options.initAsync)return this.init(t,r),this;setTimeout(()=>{this.init(t,r)},0)}}init(){var t=this;let r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},a=arguments.length>1?arguments[1]:void 0;this.isInitializing=!0,typeof r=="function"&&(a=r,r={}),r.defaultNS==null&&r.ns&&(oe(r.ns)?r.defaultNS=r.ns:r.ns.indexOf("translation")<0&&(r.defaultNS=r.ns[0]));const n=yi();this.options={...n,...this.options,...bi(r)},this.options.interpolation={...n.interpolation,...this.options.interpolation},r.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=r.keySeparator),r.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=r.nsSeparator);const o=d=>d?typeof d=="function"?new d:d:null;if(!this.options.isClone){this.modules.logger?Ct.init(o(this.modules.logger),this.options):Ct.init(null,this.options);let d;this.modules.formatter?d=this.modules.formatter:d=sm;const u=new hi(this.options);this.store=new di(this.options.resources,this.options);const p=this.services;p.logger=Ct,p.resourceStore=this.store,p.languageUtils=u,p.pluralResolver=new am(u,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),d&&(!this.options.interpolation.format||this.options.interpolation.format===n.interpolation.format)&&(p.formatter=o(d),p.formatter.init(p,this.options),this.options.interpolation.format=p.formatter.format.bind(p.formatter)),p.interpolator=new nm(this.options),p.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},p.backendConnector=new lm(o(this.modules.backend),p.resourceStore,p,this.options),p.backendConnector.on("*",function(m){for(var g=arguments.length,h=new Array(g>1?g-1:0),x=1;x<g;x++)h[x-1]=arguments[x];t.emit(m,...h)}),this.modules.languageDetector&&(p.languageDetector=o(this.modules.languageDetector),p.languageDetector.init&&p.languageDetector.init(p,this.options.detection,this.options)),this.modules.i18nFormat&&(p.i18nFormat=o(this.modules.i18nFormat),p.i18nFormat.init&&p.i18nFormat.init(this)),this.translator=new Cn(this.services,this.options),this.translator.on("*",function(m){for(var g=arguments.length,h=new Array(g>1?g-1:0),x=1;x<g;x++)h[x-1]=arguments[x];t.emit(m,...h)}),this.modules.external.forEach(m=>{m.init&&m.init(this)})}if(this.format=this.options.interpolation.format,a||(a=Wa),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const d=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);d.length>0&&d[0]!=="dev"&&(this.options.lng=d[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined"),["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(d=>{this[d]=function(){return t.store[d](...arguments)}}),["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(d=>{this[d]=function(){return t.store[d](...arguments),t}});const l=pa(),c=()=>{const d=(u,p)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),l.resolve(p),a(u,p)};if(this.languages&&!this.isInitialized)return d(null,this.t.bind(this));this.changeLanguage(this.options.lng,d)};return this.options.resources||!this.options.initAsync?c():setTimeout(c,0),l}loadResources(t){var o,s;let a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Wa;const n=oe(t)?t:this.language;if(typeof t=="function"&&(a=t),!this.options.resources||this.options.partialBundledLanguages){if((n==null?void 0:n.toLowerCase())==="cimode"&&(!this.options.preload||this.options.preload.length===0))return a();const i=[],l=c=>{if(!c||c==="cimode")return;this.services.languageUtils.toResolveHierarchy(c).forEach(u=>{u!=="cimode"&&i.indexOf(u)<0&&i.push(u)})};n?l(n):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(d=>l(d)),(s=(o=this.options.preload)==null?void 0:o.forEach)==null||s.call(o,c=>l(c)),this.services.backendConnector.load(i,this.options.ns,c=>{!c&&!this.resolvedLanguage&&this.language&&this.setResolvedLanguage(this.language),a(c)})}else a(null)}reloadResources(t,r,a){const n=pa();return typeof t=="function"&&(a=t,t=void 0),typeof r=="function"&&(a=r,r=void 0),t||(t=this.languages),r||(r=this.options.ns),a||(a=Wa),this.services.backendConnector.reload(t,r,o=>{n.resolve(),a(o)}),n}use(t){if(!t)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!t.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return t.type==="backend"&&(this.modules.backend=t),(t.type==="logger"||t.log&&t.warn&&t.error)&&(this.modules.logger=t),t.type==="languageDetector"&&(this.modules.languageDetector=t),t.type==="i18nFormat"&&(this.modules.i18nFormat=t),t.type==="postProcessor"&&ic.addPostProcessor(t),t.type==="formatter"&&(this.modules.formatter=t),t.type==="3rdParty"&&this.modules.external.push(t),this}setResolvedLanguage(t){if(!(!t||!this.languages)&&!(["cimode","dev"].indexOf(t)>-1))for(let r=0;r<this.languages.length;r++){const a=this.languages[r];if(!(["cimode","dev"].indexOf(a)>-1)&&this.store.hasLanguageSomeTranslations(a)){this.resolvedLanguage=a;break}}}changeLanguage(t,r){var a=this;this.isLanguageChangingTo=t;const n=pa();this.emit("languageChanging",t);const o=l=>{this.language=l,this.languages=this.services.languageUtils.toResolveHierarchy(l),this.resolvedLanguage=void 0,this.setResolvedLanguage(l)},s=(l,c)=>{c?(o(c),this.translator.changeLanguage(c),this.isLanguageChangingTo=void 0,this.emit("languageChanged",c),this.logger.log("languageChanged",c)):this.isLanguageChangingTo=void 0,n.resolve(function(){return a.t(...arguments)}),r&&r(l,function(){return a.t(...arguments)})},i=l=>{var d,u;!t&&!l&&this.services.languageDetector&&(l=[]);const c=oe(l)?l:this.services.languageUtils.getBestMatchFromCodes(l);c&&(this.language||o(c),this.translator.language||this.translator.changeLanguage(c),(u=(d=this.services.languageDetector)==null?void 0:d.cacheUserLanguage)==null||u.call(d,c)),this.loadResources(c,p=>{s(p,c)})};return!t&&this.services.languageDetector&&!this.services.languageDetector.async?i(this.services.languageDetector.detect()):!t&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(i):this.services.languageDetector.detect(i):i(t),n}getFixedT(t,r,a){var n=this;const o=function(s,i){let l;if(typeof i!="object"){for(var c=arguments.length,d=new Array(c>2?c-2:0),u=2;u<c;u++)d[u-2]=arguments[u];l=n.options.overloadTranslationOptionHandler([s,i].concat(d))}else l={...i};l.lng=l.lng||o.lng,l.lngs=l.lngs||o.lngs,l.ns=l.ns||o.ns,l.keyPrefix!==""&&(l.keyPrefix=l.keyPrefix||a||o.keyPrefix);const p=n.options.keySeparator||".";let m;return l.keyPrefix&&Array.isArray(s)?m=s.map(g=>`${l.keyPrefix}${p}${g}`):m=l.keyPrefix?`${l.keyPrefix}${p}${s}`:s,n.t(m,l)};return oe(t)?o.lng=t:o.lngs=t,o.ns=r,o.keyPrefix=a,o}t(){var n;for(var t=arguments.length,r=new Array(t),a=0;a<t;a++)r[a]=arguments[a];return(n=this.translator)==null?void 0:n.translate(...r)}exists(){var n;for(var t=arguments.length,r=new Array(t),a=0;a<t;a++)r[a]=arguments[a];return(n=this.translator)==null?void 0:n.exists(...r)}setDefaultNamespace(t){this.options.defaultNS=t}hasLoadedNamespace(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const a=r.lng||this.resolvedLanguage||this.languages[0],n=this.options?this.options.fallbackLng:!1,o=this.languages[this.languages.length-1];if(a.toLowerCase()==="cimode")return!0;const s=(i,l)=>{const c=this.services.backendConnector.state[`${i}|${l}`];return c===-1||c===0||c===2};if(r.precheck){const i=r.precheck(this,s);if(i!==void 0)return i}return!!(this.hasResourceBundle(a,t)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||s(a,t)&&(!n||s(o,t)))}loadNamespaces(t,r){const a=pa();return this.options.ns?(oe(t)&&(t=[t]),t.forEach(n=>{this.options.ns.indexOf(n)<0&&this.options.ns.push(n)}),this.loadResources(n=>{a.resolve(),r&&r(n)}),a):(r&&r(),Promise.resolve())}loadLanguages(t,r){const a=pa();oe(t)&&(t=[t]);const n=this.options.preload||[],o=t.filter(s=>n.indexOf(s)<0&&this.services.languageUtils.isSupportedCode(s));return o.length?(this.options.preload=n.concat(o),this.loadResources(s=>{a.resolve(),r&&r(s)}),a):(r&&r(),Promise.resolve())}dir(t){var n,o;if(t||(t=this.resolvedLanguage||(((n=this.languages)==null?void 0:n.length)>0?this.languages[0]:this.language)),!t)return"rtl";const r=["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"],a=((o=this.services)==null?void 0:o.languageUtils)||new hi(yi());return r.indexOf(a.getLanguagePartFromCode(t))>-1||t.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;return new Ea(t,r)}cloneInstance(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Wa;const a=t.forkResourceStore;a&&delete t.forkResourceStore;const n={...this.options,...t,isClone:!0},o=new Ea(n);if((t.debug!==void 0||t.prefix!==void 0)&&(o.logger=o.logger.clone(t)),["store","services","language"].forEach(i=>{o[i]=this[i]}),o.services={...this.services},o.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},a){const i=Object.keys(this.store.data).reduce((l,c)=>(l[c]={...this.store.data[c]},Object.keys(l[c]).reduce((d,u)=>(d[u]={...l[c][u]},d),{})),{});o.store=new di(i,n),o.services.resourceStore=o.store}return o.translator=new Cn(o.services,n),o.translator.on("*",function(i){for(var l=arguments.length,c=new Array(l>1?l-1:0),d=1;d<l;d++)c[d-1]=arguments[d];o.emit(i,...c)}),o.init(n,r),o.translator.options=n,o.translator.backendConnector.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},o}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const Je=Ea.createInstance();Je.createInstance=Ea.createInstance;Je.createInstance;Je.dir;Je.init;Je.loadResources;Je.reloadResources;Je.use;Je.changeLanguage;Je.getFixedT;Je.t;Je.exists;Je.setDefaultNamespace;Je.hasLoadedNamespace;Je.loadNamespaces;Je.loadLanguages;const dm={"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.
|
|
88
|
-
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","ProgramControl.Start.bt":"Start","ProgramControl.Resume.bt":"Weiter","ProgramControl.Pause.bt":"Pause","ProgramControl.Stop.bt":"Stopp"},um={"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","ProgramControl.Start.bt":"Start","ProgramControl.Resume.bt":"Resume","ProgramControl.Pause.bt":"Pause","ProgramControl.Stop.bt":"Stop"},ys=Je.createInstance();ys.use(Qd).init({supportedLngs:["en","de"],resources:{en:{translations:um},de:{translations:dm}},ns:["translations"],defaultNS:"translations",detection:{order:["navigator","htmlTag"]}});function mr(e){return r=>b.jsx(pm,{children:b.jsx(e,{...r})})}const pm=({children:e})=>b.jsx(Te.I18nextProvider,{i18n:ys,children:e}),hm=({title:e,titleId:t,...r},a)=>H.createElement("svg",{width:21,height:21,viewBox:"0 0 21 21",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.createElement("g",{id:"JogMinus"},H.createElement("path",{id:"Minus",d:"M0 13V8H21V13H0Z",fill:"white"}))),mm=ae.forwardRef(hm),fm=({title:e,titleId:t,...r},a)=>H.createElement("svg",{width:21,height:21,viewBox:"0 0 21 21",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.createElement("g",{id:"JogPlus"},H.createElement("g",{id:"Plus"},H.createElement("path",{d:"M0 13V8H8V13H0Z",fill:"white"}),H.createElement("path",{d:"M8 0L13 2.18557e-07L13 21H8L8 0Z",fill:"white"}),H.createElement("path",{d:"M13 13V8H21V13H13Z",fill:"white"})))),gm=ae.forwardRef(fm);function Jn(e){ae.useEffect(e,[])}function lc(e){Jn(()=>Be.autorun(e))}function cc(e,t,r){Jn(()=>Be.reaction(e,t,r))}function Wr(e){return Jn(()=>{let t;function r(){e(),t=requestAnimationFrame(r)}return t=requestAnimationFrame(r),()=>{cancelAnimationFrame(t)}})}const Do=mr(je.observer(({colors:e,label:t,getDisplayedValue:r,startJogging:a,stopJogging:n,disabled:o,activeJoggingDirection:s,...i})=>{var F,N,J,K,j,L,k;Wr(()=>{const y=r(),M=p.current;M&&(M.textContent=y)});const l=z.useTheme(),[c,d]=ae.useState(null);ae.useEffect(()=>{o&&U()},[o]);const u=s||c,p=ae.useRef(null);e||(e={color:"#fff",backgroundColor:"#000",borderColor:"#000",buttonBackgroundColor:{disabled:"#000",default:"#000",hovered:"#000",pressed:"#000"},labelColor:"#000"});const m=u?(F=e.buttonBackgroundColor)==null?void 0:F.pressed:e.borderColor,g={width:"55px",color:e.color,path:{fill:e.color},alignContent:"center",fontSize:"37px",svg:{pointerEvents:"none"}},h={...g,backgroundColor:(N=e.buttonBackgroundColor)==null?void 0:N.default,":hover":{backgroundColor:(J=e.buttonBackgroundColor)==null?void 0:J.hovered},":active":{backgroundColor:(K=e.buttonBackgroundColor)==null?void 0:K.pressed,color:e.backgroundColor,path:{fill:e.backgroundColor}},":disabled":{backgroundColor:(j=e.buttonBackgroundColor)==null?void 0:j.disabled,"svg path":{fill:l.palette.action.disabled}}},x={...g,backgroundColor:(L=e.buttonBackgroundColor)==null?void 0:L.pressed,color:e.backgroundColor,path:{fill:e.backgroundColor},":disabled":{backgroundColor:(k=e.buttonBackgroundColor)==null?void 0:k.pressed,"svg path":{fill:l.palette.action.disabled}}};function E(y,M){o||y.button===0&&(d(M),a(M))}function U(){d(null),n()}return b.jsxs(zr,{height:"64px",direction:"row",justifyContent:"center",...i,children:[b.jsx(z.IconButton,{disabled:o,disableRipple:!0,onPointerDown:y=>E(y,"-"),onPointerUp:U,onPointerOut:U,size:"large",sx:{...u==="-"?x:h,borderRadius:"16px 0px 0px 16px",borderLeft:`2px solid ${m??"#fff"}`,borderBottom:`2px solid ${m??"#fff"}`,borderTop:`2px solid ${m??"#fff"}`},children:b.jsx(mm,{})}),b.jsxs(zr,{spacing:"6px",sx:{width:"150px",backgroundColor:e.backgroundColor,alignItems:"center",justifyContent:"center",opacity:"0.9",borderBottom:`2px solid ${m??"#fff"}`,borderTop:`2px solid ${m??"#fff"}`},children:[b.jsx(zr,{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}),b.jsx(z.Typography,{height:"22px",sx:{fontSize:"15px",color:o?l.palette.action.disabled:e.color,fontWeight:700},ref:p,children:r()})]}),b.jsx(z.IconButton,{disableRipple:!0,disabled:o,onPointerDown:y=>E(y,"+"),onPointerUp:U,onPointerOut:U,size:"large",sx:{...u==="+"?x:h,borderRadius:"0px 16px 16px 0px",borderRight:`2px solid ${m??"#fff"}`,borderBottom:`2px solid ${m??"#fff"}`,borderTop:`2px solid ${m??"#fff"}`},children:b.jsx(gm,{})})]})})),fr=Xp;function ym(e){return Fa("MuiSvgIcon",e)}Jl("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const bm=e=>{const{color:t,fontSize:r,classes:a}=e,n={root:["root",t!=="inherit"&&`color${We(t)}`,`fontSize${We(r)}`]};return hs(n,ym,a)},Sm=$t("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.color!=="inherit"&&t[`color${We(r.color)}`],t[`fontSize${We(r.fontSize)}`]]}})(fr(({theme:e})=>{var t,r,a,n,o,s,i,l,c,d,u,p,m,g;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:(n=(t=e.transitions)==null?void 0:t.create)==null?void 0:n.call(t,"fill",{duration:(a=(r=(e.vars??e).transitions)==null?void 0:r.duration)==null?void 0:a.shorter}),variants:[{props:h=>!h.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:((d=(c=e.typography)==null?void 0:c.pxToRem)==null?void 0:d.call(c,35))||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,h])=>h&&h.main).map(([h])=>{var x,E;return{props:{color:h},style:{color:(E=(x=(e.vars??e).palette)==null?void 0:x[h])==null?void 0:E.main}}}),{props:{color:"action"},style:{color:(p=(u=(e.vars??e).palette)==null?void 0:u.action)==null?void 0:p.active}},{props:{color:"disabled"},style:{color:(g=(m=(e.vars??e).palette)==null?void 0:m.action)==null?void 0:g.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),Pn=H.forwardRef(function(t,r){const a=gs({props:t,name:"MuiSvgIcon"}),{children:n,className:o,color:s="inherit",component:i="svg",fontSize:l="medium",htmlColor:c,inheritViewBox:d=!1,titleAccess:u,viewBox:p="0 0 24 24",...m}=a,g=H.isValidElement(n)&&n.type==="svg",h={...a,color:s,component:i,fontSize:l,instanceFontSize:t.fontSize,inheritViewBox:d,viewBox:p,hasSvgAsChild:g},x={};d||(x.viewBox=p);const E=bm(h);return b.jsxs(Sm,{as:i,className:Pt(E.root,o),focusable:"false",color:c,"aria-hidden":u?void 0:!0,role:u?"img":void 0,ref:r,...x,...m,...g&&n.props,ownerState:h,children:[g?n.props.children:n,u?b.jsx("title",{children:u}):null]})});process.env.NODE_ENV!=="production"&&(Pn.propTypes={children:S.node,classes:S.object,className:S.string,color:S.oneOfType([S.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),S.string]),component:S.elementType,fontSize:S.oneOfType([S.oneOf(["inherit","large","medium","small"]),S.string]),htmlColor:S.string,inheritViewBox:S.bool,shapeRendering:S.string,sx:S.oneOfType([S.arrayOf(S.oneOfType([S.func,S.object,S.bool])),S.func,S.object]),titleAccess:S.string,viewBox:S.string});Pn.muiName="SvgIcon";function Hn(e,t){function r(a,n){return b.jsx(Pn,{"data-testid":`${t}Icon`,ref:n,...a,children:e})}return process.env.NODE_ENV!=="production"&&(r.displayName=`${t}Icon`),r.muiName=Pn.muiName,H.memo(H.forwardRef(r))}const vm=Hn(b.jsx("path",{d:"M15.41 7.41 14 6l-6 6 6 6 1.41-1.41L10.83 12z"}),"ChevronLeft"),xm=Hn(b.jsx("path",{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}),"ChevronRight");function dr(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var dc=typeof global=="object"&&global&&global.Object===Object&&global,Om=typeof self=="object"&&self&&self.Object===Object&&self,Rt=dc||Om||Function("return this")(),vo=function(){return Rt.Date.now()},wm=/\s/;function Cm(e){for(var t=e.length;t--&&wm.test(e.charAt(t)););return t}var Pm=/^\s+/;function Vm(e){return e&&e.slice(0,Cm(e)+1).replace(Pm,"")}var Xt=Rt.Symbol,uc=Object.prototype,Rm=uc.hasOwnProperty,_m=uc.toString,ha=Xt?Xt.toStringTag:void 0;function Am(e){var t=Rm.call(e,ha),r=e[ha];try{e[ha]=void 0;var a=!0}catch{}var n=_m.call(e);return a&&(t?e[ha]=r:delete e[ha]),n}var Tm=Object.prototype,Em=Tm.toString;function Im(e){return Em.call(e)}var Mm="[object Null]",jm="[object Undefined]",Si=Xt?Xt.toStringTag:void 0;function gr(e){return e==null?e===void 0?jm:Mm:Si&&Si in Object(e)?Am(e):Im(e)}function ur(e){return e!=null&&typeof e=="object"}var $m="[object Symbol]";function qn(e){return typeof e=="symbol"||ur(e)&&gr(e)==$m}var vi=NaN,Um=/^[-+]0x[0-9a-f]+$/i,Lm=/^0b[01]+$/i,km=/^0o[0-7]+$/i,Bm=parseInt;function xi(e){if(typeof e=="number")return e;if(qn(e))return vi;if(dr(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=dr(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=Vm(e);var r=Lm.test(e);return r||km.test(e)?Bm(e.slice(2),r?2:8):Um.test(e)?vi:+e}var Fm="Expected a function",Nm=Math.max,Dm=Math.min;function zm(e,t,r){var a,n,o,s,i,l,c=0,d=!1,u=!1,p=!0;if(typeof e!="function")throw new TypeError(Fm);t=xi(t)||0,dr(r)&&(d=!!r.leading,u="maxWait"in r,o=u?Nm(xi(r.maxWait)||0,t):o,p="trailing"in r?!!r.trailing:p);function m(K){var j=a,L=n;return a=n=void 0,c=K,s=e.apply(L,j),s}function g(K){return c=K,i=setTimeout(E,t),d?m(K):s}function h(K){var j=K-l,L=K-c,k=t-j;return u?Dm(k,o-L):k}function x(K){var j=K-l,L=K-c;return l===void 0||j>=t||j<0||u&&L>=o}function E(){var K=vo();if(x(K))return U(K);i=setTimeout(E,h(K))}function U(K){return i=void 0,p&&a?m(K):(a=n=void 0,s)}function F(){i!==void 0&&clearTimeout(i),c=0,a=l=n=i=void 0}function N(){return i===void 0?s:U(vo())}function J(){var K=vo(),j=x(K);if(a=arguments,n=this,l=K,j){if(i===void 0)return g(l);if(u)return clearTimeout(i),i=setTimeout(E,t),m(l)}return i===void 0&&(i=setTimeout(E,t)),s}return J.cancel=F,J.flush=N,J}var Gm="Expected a function";function Jm(e,t,r){var a=!0,n=!0;if(typeof e!="function")throw new TypeError(Gm);return dr(r)&&(a="leading"in r?!!r.leading:a,n="trailing"in r?!!r.trailing:n),zm(e,t,{leading:a,maxWait:t,trailing:n})}const pc=mr(je.observer(({startJogging:e,stopJogging:t,lowerLimitDegs:r,upperLimitDegs:a,getValueDegs:n,disabled:o,...s})=>{var F,N,J,K,j,L,k,y,M,B,G,D,re,Z,xe;const{t:i}=Te.useTranslation(),[l,c]=ae.useState(),d=z.useTheme(),u={background:(F=d.palette.backgroundPaperElevation)==null?void 0:F[4],color:(N=d.palette.backgroundPaperElevation)==null?void 0:N[11]},p=je.useLocalObservable(()=>({activeJoggingDir:null,startJogging(X){this.activeJoggingDir=X,e(X)},stopJogging(){this.activeJoggingDir=null,t()}})),m=Jm(()=>{c(n())},50);Wr(m);function g(X){X.button===0&&p.startJogging("-")}function h(X){X.button===0&&p.startJogging("+")}function x(X){p.stopJogging()}function E(X){p.stopJogging()}function U(X,ce=1){if(X===void 0||isNaN(X))return"";const fe=i("General.degree.variable",{amount:X.toFixed(ce)});return X>0&&ce===0?`+${fe}`:fe}return b.jsxs(zr,{height:"64px",width:"100%",maxWidth:"260px",direction:"row",...s,sx:{"& .MuiIconButton-root":{width:"52px",color:d.palette.text.primary,alignContent:"center",backgroundColor:(J=d.palette.backgroundPaperElevation)==null?void 0:J[11],"& svg":{width:"42px",height:"42px"},"&.Mui-disabled":{backgroundColor:(K=d.palette.backgroundPaperElevation)==null?void 0:K[11],color:d.palette.action.disabled,opacity:1},"&:hover":{backgroundColor:(j=d.palette.backgroundPaperElevation)==null?void 0:j[9]},"&:active":{...u}}},children:[b.jsx(z.IconButton,{onPointerDown:g,onPointerUp:x,onPointerOut:E,disabled:o,disableRipple:!0,sx:{borderRadius:"16px 0px 0px 16px",...p.activeJoggingDir==="-"?u:{}},children:b.jsx(vm,{sx:{pointerEvents:"none",color:(M=(y=(k=(L=d.componentsExt)==null?void 0:L.JoggingPanel)==null?void 0:k.JoggingJoint)==null?void 0:y.Joint)==null?void 0:M.arrowColor}})}),b.jsxs(zr,{flexGrow:1,alignItems:"center",justifyContent:"center",sx:{borderStyle:"solid",borderLeftWidth:0,borderRightWidth:0,border:"none",backgroundColor:(B=d.palette.backgroundPaperElevation)==null?void 0:B[11],paddingLeft:"20px",paddingRight:"20px",zIndex:1},children:[b.jsx(z.Typography,{sx:{fontSize:"15px",fontWeight:700,position:"relative",top:"5px",color:o?d.palette.action.disabled:d.palette.text.primary},children:U(l)}),b.jsx(z.Slider,{disabled:!0,"aria-label":"Joint position",min:r,max:a,value:l||0,track:!1,sx:{"& .MuiSlider-mark":{display:"none"},"& .MuiSlider-thumb":{width:"5px",height:"12px",borderRadius:"2px",color:o?d.palette.action.disabled:d.palette.text.primary},"& .MuiSlider-markLabel":{top:"20px",fontSize:"12px",color:o?d.palette.action.disabled:d.palette.text.secondary},"& .MuiSlider-rail":{backgroundColor:(G=d.palette.backgroundPaperElevation)==null?void 0:G[5],opacity:1}},marks:r!==void 0&&a!==void 0&&[{value:r,label:U(r,0)},{value:a,label:U(a,0)}]})]}),b.jsx(z.IconButton,{onPointerDown:h,onPointerUp:x,onPointerOut:E,disabled:o,disableRipple:!0,sx:{borderRadius:"0px 16px 16px 0px",...p.activeJoggingDir==="+"?u:{}},children:b.jsx(xm,{sx:{pointerEvents:"none",color:(xe=(Z=(re=(D=d.componentsExt)==null?void 0:D.JoggingPanel)==null?void 0:re.JoggingJoint)==null?void 0:Z.Joint)==null?void 0:xe.arrowColor}})})]})})),Hm=Hn(b.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"),qm=Hn(b.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 Wm(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var hc=Wm;function Km(){this.__data__=[],this.size=0}var Qm=Km;function Ym(e,t){return e===t||e!==e&&t!==t}var mc=Ym;function Xm(e,t){for(var r=e.length;r--;)if(mc(e[r][0],t))return r;return-1}var Wn=Xm,Zm=Array.prototype,ef=Zm.splice;function tf(e){var t=this.__data__,r=Wn(t,e);if(r<0)return!1;var a=t.length-1;return r==a?t.pop():ef.call(t,r,1),--this.size,!0}var rf=tf;function af(e){var t=this.__data__,r=Wn(t,e);return r<0?void 0:t[r][1]}var nf=af;function of(e){return Wn(this.__data__,e)>-1}var sf=of;function lf(e,t){var r=this.__data__,a=Wn(r,e);return a<0?(++this.size,r.push([e,t])):r[a][1]=t,this}var cf=lf;function Kr(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var a=e[t];this.set(a[0],a[1])}}Kr.prototype.clear=Qm;Kr.prototype.delete=rf;Kr.prototype.get=nf;Kr.prototype.has=sf;Kr.prototype.set=cf;var Kn=Kr;function df(){this.__data__=new Kn,this.size=0}var uf=df;function pf(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}var hf=pf;function mf(e){return this.__data__.get(e)}var ff=mf;function gf(e){return this.__data__.has(e)}var yf=gf,bf=typeof global=="object"&&global&&global.Object===Object&&global,fc=bf,Sf=typeof self=="object"&&self&&self.Object===Object&&self,vf=fc||Sf||Function("return this")(),Ut=vf,xf=Ut.Symbol,qr=xf,gc=Object.prototype,Of=gc.hasOwnProperty,wf=gc.toString,ma=qr?qr.toStringTag:void 0;function Cf(e){var t=Of.call(e,ma),r=e[ma];try{e[ma]=void 0;var a=!0}catch{}var n=wf.call(e);return a&&(t?e[ma]=r:delete e[ma]),n}var Pf=Cf,Vf=Object.prototype,Rf=Vf.toString;function _f(e){return Rf.call(e)}var Af=_f,Tf="[object Null]",Ef="[object Undefined]",Oi=qr?qr.toStringTag:void 0;function If(e){return e==null?e===void 0?Ef:Tf:Oi&&Oi in Object(e)?Pf(e):Af(e)}var Na=If,Mf="[object AsyncFunction]",jf="[object Function]",$f="[object GeneratorFunction]",Uf="[object Proxy]";function Lf(e){if(!hc(e))return!1;var t=Na(e);return t==jf||t==$f||t==Mf||t==Uf}var yc=Lf,kf=Ut["__core-js_shared__"],xo=kf,wi=function(){var e=/[^.]+$/.exec(xo&&xo.keys&&xo.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function Bf(e){return!!wi&&wi in e}var Ff=Bf,Nf=Function.prototype,Df=Nf.toString;function zf(e){if(e!=null){try{return Df.call(e)}catch{}try{return e+""}catch{}}return""}var yr=zf,Gf=/[\\^$.*+?()[\]{}|]/g,Jf=/^\[object .+?Constructor\]$/,Hf=Function.prototype,qf=Object.prototype,Wf=Hf.toString,Kf=qf.hasOwnProperty,Qf=RegExp("^"+Wf.call(Kf).replace(Gf,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Yf(e){if(!hc(e)||Ff(e))return!1;var t=yc(e)?Qf:Jf;return t.test(yr(e))}var Xf=Yf;function Zf(e,t){return e==null?void 0:e[t]}var eg=Zf;function tg(e,t){var r=eg(e,t);return Xf(r)?r:void 0}var Qr=tg,rg=Qr(Ut,"Map"),Ia=rg,ag=Qr(Object,"create"),Ma=ag;function ng(){this.__data__=Ma?Ma(null):{},this.size=0}var og=ng;function sg(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var ig=sg,lg="__lodash_hash_undefined__",cg=Object.prototype,dg=cg.hasOwnProperty;function ug(e){var t=this.__data__;if(Ma){var r=t[e];return r===lg?void 0:r}return dg.call(t,e)?t[e]:void 0}var pg=ug,hg=Object.prototype,mg=hg.hasOwnProperty;function fg(e){var t=this.__data__;return Ma?t[e]!==void 0:mg.call(t,e)}var gg=fg,yg="__lodash_hash_undefined__";function bg(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=Ma&&t===void 0?yg:t,this}var Sg=bg;function Yr(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var a=e[t];this.set(a[0],a[1])}}Yr.prototype.clear=og;Yr.prototype.delete=ig;Yr.prototype.get=pg;Yr.prototype.has=gg;Yr.prototype.set=Sg;var Ci=Yr;function vg(){this.size=0,this.__data__={hash:new Ci,map:new(Ia||Kn),string:new Ci}}var xg=vg;function Og(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var wg=Og;function Cg(e,t){var r=e.__data__;return wg(t)?r[typeof t=="string"?"string":"hash"]:r.map}var Qn=Cg;function Pg(e){var t=Qn(this,e).delete(e);return this.size-=t?1:0,t}var Vg=Pg;function Rg(e){return Qn(this,e).get(e)}var _g=Rg;function Ag(e){return Qn(this,e).has(e)}var Tg=Ag;function Eg(e,t){var r=Qn(this,e),a=r.size;return r.set(e,t),this.size+=r.size==a?0:1,this}var Ig=Eg;function Xr(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var a=e[t];this.set(a[0],a[1])}}Xr.prototype.clear=xg;Xr.prototype.delete=Vg;Xr.prototype.get=_g;Xr.prototype.has=Tg;Xr.prototype.set=Ig;var bc=Xr,Mg=200;function jg(e,t){var r=this.__data__;if(r instanceof Kn){var a=r.__data__;if(!Ia||a.length<Mg-1)return a.push([e,t]),this.size=++r.size,this;r=this.__data__=new bc(a)}return r.set(e,t),this.size=r.size,this}var $g=jg;function Zr(e){var t=this.__data__=new Kn(e);this.size=t.size}Zr.prototype.clear=uf;Zr.prototype.delete=hf;Zr.prototype.get=ff;Zr.prototype.has=yf;Zr.prototype.set=$g;var Oo=Zr,Ug="__lodash_hash_undefined__";function Lg(e){return this.__data__.set(e,Ug),this}var kg=Lg;function Bg(e){return this.__data__.has(e)}var Fg=Bg;function Vn(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new bc;++t<r;)this.add(e[t])}Vn.prototype.add=Vn.prototype.push=kg;Vn.prototype.has=Fg;var Ng=Vn;function Dg(e,t){for(var r=-1,a=e==null?0:e.length;++r<a;)if(t(e[r],r,e))return!0;return!1}var zg=Dg;function Gg(e,t){return e.has(t)}var Jg=Gg,Hg=1,qg=2;function Wg(e,t,r,a,n,o){var s=r&Hg,i=e.length,l=t.length;if(i!=l&&!(s&&l>i))return!1;var c=o.get(e),d=o.get(t);if(c&&d)return c==t&&d==e;var u=-1,p=!0,m=r&qg?new Ng:void 0;for(o.set(e,t),o.set(t,e);++u<i;){var g=e[u],h=t[u];if(a)var x=s?a(h,g,u,t,e,o):a(g,h,u,e,t,o);if(x!==void 0){if(x)continue;p=!1;break}if(m){if(!zg(t,function(E,U){if(!Jg(m,U)&&(g===E||n(g,E,r,a,o)))return m.push(U)})){p=!1;break}}else if(!(g===h||n(g,h,r,a,o))){p=!1;break}}return o.delete(e),o.delete(t),p}var Sc=Wg,Kg=Ut.Uint8Array,Pi=Kg;function Qg(e){var t=-1,r=Array(e.size);return e.forEach(function(a,n){r[++t]=[n,a]}),r}var Yg=Qg;function Xg(e){var t=-1,r=Array(e.size);return e.forEach(function(a){r[++t]=a}),r}var Zg=Xg,ey=1,ty=2,ry="[object Boolean]",ay="[object Date]",ny="[object Error]",oy="[object Map]",sy="[object Number]",iy="[object RegExp]",ly="[object Set]",cy="[object String]",dy="[object Symbol]",uy="[object ArrayBuffer]",py="[object DataView]",Vi=qr?qr.prototype:void 0,wo=Vi?Vi.valueOf:void 0;function hy(e,t,r,a,n,o,s){switch(r){case py:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case uy:return!(e.byteLength!=t.byteLength||!o(new Pi(e),new Pi(t)));case ry:case ay:case sy:return mc(+e,+t);case ny:return e.name==t.name&&e.message==t.message;case iy:case cy:return e==t+"";case oy:var i=Yg;case ly:var l=a&ey;if(i||(i=Zg),e.size!=t.size&&!l)return!1;var c=s.get(e);if(c)return c==t;a|=ty,s.set(e,t);var d=Sc(i(e),i(t),a,n,o,s);return s.delete(e),d;case dy:if(wo)return wo.call(e)==wo.call(t)}return!1}var my=hy;function fy(e,t){for(var r=-1,a=t.length,n=e.length;++r<a;)e[n+r]=t[r];return e}var gy=fy,yy=Array.isArray,Rn=yy;function by(e,t,r){var a=t(e);return Rn(e)?a:gy(a,r(e))}var Sy=by;function vy(e,t){for(var r=-1,a=e==null?0:e.length,n=0,o=[];++r<a;){var s=e[r];t(s,r,e)&&(o[n++]=s)}return o}var xy=vy;function Oy(){return[]}var wy=Oy,Cy=Object.prototype,Py=Cy.propertyIsEnumerable,Ri=Object.getOwnPropertySymbols,Vy=Ri?function(e){return e==null?[]:(e=Object(e),xy(Ri(e),function(t){return Py.call(e,t)}))}:wy,Ry=Vy;function _y(e,t){for(var r=-1,a=Array(e);++r<e;)a[r]=t(r);return a}var Ay=_y;function Ty(e){return e!=null&&typeof e=="object"}var ja=Ty,Ey="[object Arguments]";function Iy(e){return ja(e)&&Na(e)==Ey}var _i=Iy,vc=Object.prototype,My=vc.hasOwnProperty,jy=vc.propertyIsEnumerable,$y=_i(function(){return arguments}())?_i:function(e){return ja(e)&&My.call(e,"callee")&&!jy.call(e,"callee")},Uy=$y;function Ly(){return!1}var ky=Ly,xc=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Ai=xc&&typeof module=="object"&&module&&!module.nodeType&&module,By=Ai&&Ai.exports===xc,Ti=By?Ut.Buffer:void 0,Fy=Ti?Ti.isBuffer:void 0,Ny=Fy||ky,zo=Ny,Dy=9007199254740991,zy=/^(?:0|[1-9]\d*)$/;function Gy(e,t){var r=typeof e;return t=t??Dy,!!t&&(r=="number"||r!="symbol"&&zy.test(e))&&e>-1&&e%1==0&&e<t}var Jy=Gy,Hy=9007199254740991;function qy(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Hy}var Oc=qy,Wy="[object Arguments]",Ky="[object Array]",Qy="[object Boolean]",Yy="[object Date]",Xy="[object Error]",Zy="[object Function]",eb="[object Map]",tb="[object Number]",rb="[object Object]",ab="[object RegExp]",nb="[object Set]",ob="[object String]",sb="[object WeakMap]",ib="[object ArrayBuffer]",lb="[object DataView]",cb="[object Float32Array]",db="[object Float64Array]",ub="[object Int8Array]",pb="[object Int16Array]",hb="[object Int32Array]",mb="[object Uint8Array]",fb="[object Uint8ClampedArray]",gb="[object Uint16Array]",yb="[object Uint32Array]",Oe={};Oe[cb]=Oe[db]=Oe[ub]=Oe[pb]=Oe[hb]=Oe[mb]=Oe[fb]=Oe[gb]=Oe[yb]=!0;Oe[Wy]=Oe[Ky]=Oe[ib]=Oe[Qy]=Oe[lb]=Oe[Yy]=Oe[Xy]=Oe[Zy]=Oe[eb]=Oe[tb]=Oe[rb]=Oe[ab]=Oe[nb]=Oe[ob]=Oe[sb]=!1;function bb(e){return ja(e)&&Oc(e.length)&&!!Oe[Na(e)]}var Sb=bb;function vb(e){return function(t){return e(t)}}var xb=vb,wc=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Va=wc&&typeof module=="object"&&module&&!module.nodeType&&module,Ob=Va&&Va.exports===wc,Co=Ob&&fc.process,wb=function(){try{var e=Va&&Va.require&&Va.require("util").types;return e||Co&&Co.binding&&Co.binding("util")}catch{}}(),Ei=wb,Ii=Ei&&Ei.isTypedArray,Cb=Ii?xb(Ii):Sb,Cc=Cb,Pb=Object.prototype,Vb=Pb.hasOwnProperty;function Rb(e,t){var r=Rn(e),a=!r&&Uy(e),n=!r&&!a&&zo(e),o=!r&&!a&&!n&&Cc(e),s=r||a||n||o,i=s?Ay(e.length,String):[],l=i.length;for(var c in e)(t||Vb.call(e,c))&&!(s&&(c=="length"||n&&(c=="offset"||c=="parent")||o&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||Jy(c,l)))&&i.push(c);return i}var _b=Rb,Ab=Object.prototype;function Tb(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||Ab;return e===r}var Eb=Tb;function Ib(e,t){return function(r){return e(t(r))}}var Mb=Ib,jb=Mb(Object.keys,Object),$b=jb,Ub=Object.prototype,Lb=Ub.hasOwnProperty;function kb(e){if(!Eb(e))return $b(e);var t=[];for(var r in Object(e))Lb.call(e,r)&&r!="constructor"&&t.push(r);return t}var Bb=kb;function Fb(e){return e!=null&&Oc(e.length)&&!yc(e)}var Nb=Fb;function Db(e){return Nb(e)?_b(e):Bb(e)}var zb=Db;function Gb(e){return Sy(e,zb,Ry)}var Mi=Gb,Jb=1,Hb=Object.prototype,qb=Hb.hasOwnProperty;function Wb(e,t,r,a,n,o){var s=r&Jb,i=Mi(e),l=i.length,c=Mi(t),d=c.length;if(l!=d&&!s)return!1;for(var u=l;u--;){var p=i[u];if(!(s?p in t:qb.call(t,p)))return!1}var m=o.get(e),g=o.get(t);if(m&&g)return m==t&&g==e;var h=!0;o.set(e,t),o.set(t,e);for(var x=s;++u<l;){p=i[u];var E=e[p],U=t[p];if(a)var F=s?a(U,E,p,t,e,o):a(E,U,p,e,t,o);if(!(F===void 0?E===U||n(E,U,r,a,o):F)){h=!1;break}x||(x=p=="constructor")}if(h&&!x){var N=e.constructor,J=t.constructor;N!=J&&"constructor"in e&&"constructor"in t&&!(typeof N=="function"&&N instanceof N&&typeof J=="function"&&J instanceof J)&&(h=!1)}return o.delete(e),o.delete(t),h}var Kb=Wb,Qb=Qr(Ut,"DataView"),Go=Qb,Yb=Qr(Ut,"Promise"),Jo=Yb,Xb=Qr(Ut,"Set"),Ho=Xb,Zb=Qr(Ut,"WeakMap"),qo=Zb,ji="[object Map]",e0="[object Object]",$i="[object Promise]",Ui="[object Set]",Li="[object WeakMap]",ki="[object DataView]",t0=yr(Go),r0=yr(Ia),a0=yr(Jo),n0=yr(Ho),o0=yr(qo),or=Na;(Go&&or(new Go(new ArrayBuffer(1)))!=ki||Ia&&or(new Ia)!=ji||Jo&&or(Jo.resolve())!=$i||Ho&&or(new Ho)!=Ui||qo&&or(new qo)!=Li)&&(or=function(e){var t=Na(e),r=t==e0?e.constructor:void 0,a=r?yr(r):"";if(a)switch(a){case t0:return ki;case r0:return ji;case a0:return $i;case n0:return Ui;case o0:return Li}return t});var Bi=or,s0=1,Fi="[object Arguments]",Ni="[object Array]",Ka="[object Object]",i0=Object.prototype,Di=i0.hasOwnProperty;function l0(e,t,r,a,n,o){var s=Rn(e),i=Rn(t),l=s?Ni:Bi(e),c=i?Ni:Bi(t);l=l==Fi?Ka:l,c=c==Fi?Ka:c;var d=l==Ka,u=c==Ka,p=l==c;if(p&&zo(e)){if(!zo(t))return!1;s=!0,d=!1}if(p&&!d)return o||(o=new Oo),s||Cc(e)?Sc(e,t,r,a,n,o):my(e,t,l,r,a,n,o);if(!(r&s0)){var m=d&&Di.call(e,"__wrapped__"),g=u&&Di.call(t,"__wrapped__");if(m||g){var h=m?e.value():e,x=g?t.value():t;return o||(o=new Oo),n(h,x,r,a,o)}}return p?(o||(o=new Oo),Kb(e,t,r,a,n,o)):!1}var c0=l0;function Pc(e,t,r,a,n){return e===t?!0:e==null||t==null||!ja(e)&&!ja(t)?e!==e&&t!==t:c0(e,t,r,a,Pc,n)}var d0=Pc;function u0(e,t){return d0(e,t)}var p0=u0;/*! *****************************************************************************
|
|
85
|
+
export default theme;`}function bl(e={},...t){const{breakpoints:r,mixins:n={},spacing:a,palette:s={},transitions:o={},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.":Pr(20));const u=sc(s),d=Uo(e);let h=ht(d,{mixins:jb(d.breakpoints,n),palette:u,shadows:Fb.slice(),typography:Lb(u,i),transitions:Hb(o),zIndex:{...qb}});if(h=ht(h,c),h=t.reduce((p,m)=>ht(p,m),h),process.env.NODE_ENV!=="production"){const p=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],m=(f,g)=>{let S;for(S in f){const T=f[S];if(p.includes(S)&&Object.keys(T).length>0){if(process.env.NODE_ENV!=="production"){const O=ts("",S);console.error([`MUI: The \`${g}\` component increases the CSS specificity of the \`${S}\` internal state.`,"You can not override it like this: ",JSON.stringify(f,null,2),"",`Instead, you need to use the '&.${O}' syntax:`,JSON.stringify({root:{[`&.${O}`]:T}},null,2),"","https://mui.com/r/state-classes-guide"].join(`
|
|
86
|
+
`))}f[S]={}}}};Object.keys(h.components).forEach(f=>{const g=h.components[f].styleOverrides;g&&f.startsWith("Mui")&&m(g,f)})}return h.unstable_sxConfig={...es,...c==null?void 0:c.unstable_sxConfig},h.unstable_sx=function(m){return Un({sx:m,theme:this})},h.toRuntimeSource=qp,h}function Wb(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 Kb=[...Array(25)].map((e,t)=>{if(t===0)return"none";const r=Wb(t);return`linear-gradient(rgba(255 255 255 / ${r}), rgba(255 255 255 / ${r}))`});function Jp(e){return{inputPlaceholder:e==="dark"?.5:.42,inputUnderline:e==="dark"?.7:.42,switchTrackDisabled:e==="dark"?.2:.12,switchTrack:e==="dark"?.3:.38}}function Wp(e){return e==="dark"?Kb:[]}function Yb(e){const{palette:t={mode:"light"},opacity:r,overlays:n,...a}=e,s=sc(t);return{palette:s,opacity:{...Jp(s.mode),...r},overlays:n||Wp(s.mode),...a}}function Qb(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 Xb=e=>[...[...Array(25)].map((t,r)=>`--${e?`${e}-`:""}overlays-${r}`),`--${e?`${e}-`:""}palette-AppBar-darkBg`,`--${e?`${e}-`:""}palette-AppBar-darkColor`],Zb=e=>(t,r)=>{const n=e.rootSelector||":root",a=e.colorSchemeSelector;let s=a;if(a==="class"&&(s=".%s"),a==="data"&&(s="[data-%s]"),a!=null&&a.startsWith("data-")&&!a.includes("%s")&&(s=`[${a}="%s"]`),e.defaultColorScheme===t){if(t==="dark"){const o={};return Xb(e.cssVarPrefix).forEach(i=>{o[i]=r[i],delete r[i]}),s==="media"?{[n]:r,"@media (prefers-color-scheme: dark)":{[n]:o}}:s?{[s.replace("%s",t)]:o,[`${n}, ${s.replace("%s",t)}`]:r}:{[n]:{...r,...o}}}if(s&&s!=="media")return`${n}, ${s.replace("%s",String(t))}`}else if(t){if(s==="media")return{[`@media (prefers-color-scheme: ${String(t)})`]:{[n]:r}};if(s)return s.replace("%s",String(t))}return n};function ev(e,t){t.forEach(r=>{e[r]||(e[r]={})})}function q(e,t,r){!e[t]&&r&&(e[t]=r)}function Aa(e){return typeof e!="string"||!e.startsWith("hsl")?e:Bp(e)}function tr(e,t){`${t}Channel`in e||(e[`${t}Channel`]=Ta(Aa(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().
|
|
87
|
+
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 tv(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const Gt=e=>{try{return e()}catch{}},rv=(e="mui")=>fb(e);function Ei(e,t,r,n){if(!t)return;t=t===!0?{}:t;const a=n==="dark"?"dark":"light";if(!r){e[n]=Yb({...t,palette:{mode:a,...t==null?void 0:t.palette}});return}const{palette:s,...o}=bl({...r,palette:{mode:a,...t==null?void 0:t.palette}});return e[n]={...t,palette:s,opacity:{...Jp(a),...t==null?void 0:t.opacity},overlays:(t==null?void 0:t.overlays)||Wp(a)},o}function nv(e={},...t){const{colorSchemes:r={light:!0},defaultColorScheme:n,disableCssColorScheme:a=!1,cssVarPrefix:s="mui",shouldSkipGeneratingVar:o=Qb,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=rv(s),{[d]:p,light:m,dark:f,...g}=r,S={...g};let T=p;if((d==="dark"&&!("dark"in r)||d==="light"&&!("light"in r))&&(T=!0),!T)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${d}\` option is either missing or invalid.`:Pr(21,d));const O=Ei(S,T,c,d);m&&!S.light&&Ei(S,m,void 0,"light"),f&&!S.dark&&Ei(S,f,void 0,"dark");let C={defaultColorScheme:d,...O,cssVarPrefix:s,colorSchemeSelector:i,rootSelector:l,getCssVar:h,colorSchemes:S,font:{...$b(O.typography),...O.font},spacing:tv(c.spacing)};Object.keys(C.colorSchemes).forEach(B=>{const y=C.colorSchemes[B].palette,A=z=>{const I=z.split("-"),G=I[1],re=I[2];return h(z,y[G][re])};if(y.mode==="light"&&(q(y.common,"background","#fff"),q(y.common,"onBackground","#000")),y.mode==="dark"&&(q(y.common,"background","#000"),q(y.common,"onBackground","#fff")),ev(y,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),y.mode==="light"){q(y.Alert,"errorColor",Ve(y.error.light,.6)),q(y.Alert,"infoColor",Ve(y.info.light,.6)),q(y.Alert,"successColor",Ve(y.success.light,.6)),q(y.Alert,"warningColor",Ve(y.warning.light,.6)),q(y.Alert,"errorFilledBg",A("palette-error-main")),q(y.Alert,"infoFilledBg",A("palette-info-main")),q(y.Alert,"successFilledBg",A("palette-success-main")),q(y.Alert,"warningFilledBg",A("palette-warning-main")),q(y.Alert,"errorFilledColor",Gt(()=>y.getContrastText(y.error.main))),q(y.Alert,"infoFilledColor",Gt(()=>y.getContrastText(y.info.main))),q(y.Alert,"successFilledColor",Gt(()=>y.getContrastText(y.success.main))),q(y.Alert,"warningFilledColor",Gt(()=>y.getContrastText(y.warning.main))),q(y.Alert,"errorStandardBg",Ee(y.error.light,.9)),q(y.Alert,"infoStandardBg",Ee(y.info.light,.9)),q(y.Alert,"successStandardBg",Ee(y.success.light,.9)),q(y.Alert,"warningStandardBg",Ee(y.warning.light,.9)),q(y.Alert,"errorIconColor",A("palette-error-main")),q(y.Alert,"infoIconColor",A("palette-info-main")),q(y.Alert,"successIconColor",A("palette-success-main")),q(y.Alert,"warningIconColor",A("palette-warning-main")),q(y.AppBar,"defaultBg",A("palette-grey-100")),q(y.Avatar,"defaultBg",A("palette-grey-400")),q(y.Button,"inheritContainedBg",A("palette-grey-300")),q(y.Button,"inheritContainedHoverBg",A("palette-grey-A100")),q(y.Chip,"defaultBorder",A("palette-grey-400")),q(y.Chip,"defaultAvatarColor",A("palette-grey-700")),q(y.Chip,"defaultIconColor",A("palette-grey-700")),q(y.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),q(y.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),q(y.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),q(y.LinearProgress,"primaryBg",Ee(y.primary.main,.62)),q(y.LinearProgress,"secondaryBg",Ee(y.secondary.main,.62)),q(y.LinearProgress,"errorBg",Ee(y.error.main,.62)),q(y.LinearProgress,"infoBg",Ee(y.info.main,.62)),q(y.LinearProgress,"successBg",Ee(y.success.main,.62)),q(y.LinearProgress,"warningBg",Ee(y.warning.main,.62)),q(y.Skeleton,"bg",`rgba(${A("palette-text-primaryChannel")} / 0.11)`),q(y.Slider,"primaryTrack",Ee(y.primary.main,.62)),q(y.Slider,"secondaryTrack",Ee(y.secondary.main,.62)),q(y.Slider,"errorTrack",Ee(y.error.main,.62)),q(y.Slider,"infoTrack",Ee(y.info.main,.62)),q(y.Slider,"successTrack",Ee(y.success.main,.62)),q(y.Slider,"warningTrack",Ee(y.warning.main,.62));const z=fs(y.background.default,.8);q(y.SnackbarContent,"bg",z),q(y.SnackbarContent,"color",Gt(()=>y.getContrastText(z))),q(y.SpeedDialAction,"fabHoverBg",fs(y.background.paper,.15)),q(y.StepConnector,"border",A("palette-grey-400")),q(y.StepContent,"border",A("palette-grey-400")),q(y.Switch,"defaultColor",A("palette-common-white")),q(y.Switch,"defaultDisabledColor",A("palette-grey-100")),q(y.Switch,"primaryDisabledColor",Ee(y.primary.main,.62)),q(y.Switch,"secondaryDisabledColor",Ee(y.secondary.main,.62)),q(y.Switch,"errorDisabledColor",Ee(y.error.main,.62)),q(y.Switch,"infoDisabledColor",Ee(y.info.main,.62)),q(y.Switch,"successDisabledColor",Ee(y.success.main,.62)),q(y.Switch,"warningDisabledColor",Ee(y.warning.main,.62)),q(y.TableCell,"border",Ee(ps(y.divider,1),.88)),q(y.Tooltip,"bg",ps(y.grey[700],.92))}if(y.mode==="dark"){q(y.Alert,"errorColor",Ee(y.error.light,.6)),q(y.Alert,"infoColor",Ee(y.info.light,.6)),q(y.Alert,"successColor",Ee(y.success.light,.6)),q(y.Alert,"warningColor",Ee(y.warning.light,.6)),q(y.Alert,"errorFilledBg",A("palette-error-dark")),q(y.Alert,"infoFilledBg",A("palette-info-dark")),q(y.Alert,"successFilledBg",A("palette-success-dark")),q(y.Alert,"warningFilledBg",A("palette-warning-dark")),q(y.Alert,"errorFilledColor",Gt(()=>y.getContrastText(y.error.dark))),q(y.Alert,"infoFilledColor",Gt(()=>y.getContrastText(y.info.dark))),q(y.Alert,"successFilledColor",Gt(()=>y.getContrastText(y.success.dark))),q(y.Alert,"warningFilledColor",Gt(()=>y.getContrastText(y.warning.dark))),q(y.Alert,"errorStandardBg",Ve(y.error.light,.9)),q(y.Alert,"infoStandardBg",Ve(y.info.light,.9)),q(y.Alert,"successStandardBg",Ve(y.success.light,.9)),q(y.Alert,"warningStandardBg",Ve(y.warning.light,.9)),q(y.Alert,"errorIconColor",A("palette-error-main")),q(y.Alert,"infoIconColor",A("palette-info-main")),q(y.Alert,"successIconColor",A("palette-success-main")),q(y.Alert,"warningIconColor",A("palette-warning-main")),q(y.AppBar,"defaultBg",A("palette-grey-900")),q(y.AppBar,"darkBg",A("palette-background-paper")),q(y.AppBar,"darkColor",A("palette-text-primary")),q(y.Avatar,"defaultBg",A("palette-grey-600")),q(y.Button,"inheritContainedBg",A("palette-grey-800")),q(y.Button,"inheritContainedHoverBg",A("palette-grey-700")),q(y.Chip,"defaultBorder",A("palette-grey-700")),q(y.Chip,"defaultAvatarColor",A("palette-grey-300")),q(y.Chip,"defaultIconColor",A("palette-grey-300")),q(y.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),q(y.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),q(y.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),q(y.LinearProgress,"primaryBg",Ve(y.primary.main,.5)),q(y.LinearProgress,"secondaryBg",Ve(y.secondary.main,.5)),q(y.LinearProgress,"errorBg",Ve(y.error.main,.5)),q(y.LinearProgress,"infoBg",Ve(y.info.main,.5)),q(y.LinearProgress,"successBg",Ve(y.success.main,.5)),q(y.LinearProgress,"warningBg",Ve(y.warning.main,.5)),q(y.Skeleton,"bg",`rgba(${A("palette-text-primaryChannel")} / 0.13)`),q(y.Slider,"primaryTrack",Ve(y.primary.main,.5)),q(y.Slider,"secondaryTrack",Ve(y.secondary.main,.5)),q(y.Slider,"errorTrack",Ve(y.error.main,.5)),q(y.Slider,"infoTrack",Ve(y.info.main,.5)),q(y.Slider,"successTrack",Ve(y.success.main,.5)),q(y.Slider,"warningTrack",Ve(y.warning.main,.5));const z=fs(y.background.default,.98);q(y.SnackbarContent,"bg",z),q(y.SnackbarContent,"color",Gt(()=>y.getContrastText(z))),q(y.SpeedDialAction,"fabHoverBg",fs(y.background.paper,.15)),q(y.StepConnector,"border",A("palette-grey-600")),q(y.StepContent,"border",A("palette-grey-600")),q(y.Switch,"defaultColor",A("palette-grey-300")),q(y.Switch,"defaultDisabledColor",A("palette-grey-600")),q(y.Switch,"primaryDisabledColor",Ve(y.primary.main,.55)),q(y.Switch,"secondaryDisabledColor",Ve(y.secondary.main,.55)),q(y.Switch,"errorDisabledColor",Ve(y.error.main,.55)),q(y.Switch,"infoDisabledColor",Ve(y.info.main,.55)),q(y.Switch,"successDisabledColor",Ve(y.success.main,.55)),q(y.Switch,"warningDisabledColor",Ve(y.warning.main,.55)),q(y.TableCell,"border",Ve(ps(y.divider,1),.68)),q(y.Tooltip,"bg",ps(y.grey[700],.92))}tr(y.background,"default"),tr(y.background,"paper"),tr(y.common,"background"),tr(y.common,"onBackground"),tr(y,"divider"),Object.keys(y).forEach(z=>{const I=y[z];z!=="tonalOffset"&&I&&typeof I=="object"&&(I.main&&q(y[z],"mainChannel",Ta(Aa(I.main))),I.light&&q(y[z],"lightChannel",Ta(Aa(I.light))),I.dark&&q(y[z],"darkChannel",Ta(Aa(I.dark))),I.contrastText&&q(y[z],"contrastTextChannel",Ta(Aa(I.contrastText))),z==="text"&&(tr(y[z],"primary"),tr(y[z],"secondary")),z==="action"&&(I.active&&tr(y[z],"active"),I.selected&&tr(y[z],"selected")))})}),C=t.reduce((B,y)=>ht(B,y),C);const V={prefix:s,disableCssColorScheme:a,shouldSkipGeneratingVar:o,getSelector:Zb(C)},{vars:R,generateThemeVars:P,generateStyleSheets:E}=yb(C,V);return C.vars=R,Object.entries(C.colorSchemes[C.defaultColorScheme]).forEach(([B,y])=>{C[B]=y}),C.generateThemeVars=P,C.generateStyleSheets=E,C.generateSpacing=function(){return Mp(c.spacing,Io(this))},C.getColorSchemeSelector=bb(i),C.spacing=C.generateSpacing(),C.shouldSkipGeneratingVar=o,C.unstable_sxConfig={...es,...c==null?void 0:c.unstable_sxConfig},C.unstable_sx=function(y){return Un({sx:y,theme:this})},C.toRuntimeSource=qp,C}function Mu(e,t,r){e.colorSchemes&&r&&(e.colorSchemes[t]={...r!==!0&&r,palette:sc({...r===!0?{}:r.palette,mode:t})})}function Kp(e={},...t){const{palette:r,cssVariables:n=!1,colorSchemes:a=r?void 0:{light:!0},defaultColorScheme:s=r==null?void 0:r.mode,...o}=e,i=s||"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 bl(e,...t);let u=r;"palette"in e||c[i]&&(c[i]!==!0?u=c[i].palette:i==="dark"&&(u={mode:"dark"}));const d=bl({...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},Mu(d,"dark",c.dark)),d.palette.mode==="dark"&&(d.colorSchemes.dark={...c.dark!==!0&&c.dark,palette:d.palette},Mu(d,"light",c.light)),d}return!r&&!("light"in c)&&i==="light"&&(c.light=!0),nv({...o,colorSchemes:c,defaultColorScheme:i,...typeof n!="boolean"&&n},...t)}const Yp=Kp();function av({props:e,name:t}){return Np({props:e,name:t,defaultTheme:Yp,themeId:Tp})}function oc(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const sv=e=>oc(e)&&e!=="classes",Pt=Up({themeId:Tp,defaultTheme:Yp,rootShouldForwardProp:sv});function Qp(...e){const t=F.useRef(void 0),r=F.useCallback(n=>{const a=e.map(s=>{if(s==null)return null;if(typeof s=="function"){const o=s,i=o(n);return typeof i=="function"?i:()=>{o(null)}}return s.current=n,()=>{s.current=null}});return()=>{a.forEach(s=>s==null?void 0:s())}},e);return F.useMemo(()=>e.every(n=>n==null)?null:n=>{t.current&&(t.current(),t.current=void 0),n!=null&&(t.current=r(n))},e)}let $u=0;function ov(e){const[t,r]=F.useState(e),n=t;return F.useEffect(()=>{t==null&&($u+=1,r(`mui-${$u}`))},[t]),n}const iv={...F},ju=iv.useId;function lv(e){return ju!==void 0?ju():ov(e)}class cv{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 or=typeof window<"u"?F.useLayoutEffect:F.useEffect,No=({params:e,store:t})=>{F.useEffect(()=>{t.update(n=>K({},n,{animation:K({},n.animation,{skip:e.skipAnimation})}))},[t,e.skipAnimation]);const r=F.useCallback(()=>{let n=!1;return t.update(a=>K({},a,{animation:K({},a.animation,{skipAnimationRequests:a.animation.skipAnimationRequests+1})})),()=>{n||(n=!0,t.update(a=>K({},a,{animation:K({},a.animation,{skipAnimationRequests:a.animation.skipAnimationRequests-1})})))}},[t]);return or(()=>{if(typeof window>"u"||!(window!=null&&window.matchMedia))return;let a;const s=i=>{i.matches?a=r():a==null||a()},o=window.matchMedia("(prefers-reduced-motion)");return s(o),o.addEventListener("change",s),()=>{o.removeEventListener("change",s)}},[r,t]),{instance:{disableAnimation:r}}};No.params={skipAnimation:!0};No.getDefaultizedParams=({params:e})=>K({},e,{skipAnimation:e.skipAnimation??!1});No.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 uv=(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(s){({stack:a}=s)}console.warn(`The result function returned its own inputs without modification. e.g
|
|
88
|
+
\`createSelector([state => state.todos], todos => todos)\`
|
|
89
|
+
This could lead to inefficient memoization and unnecessary re-renders.
|
|
90
|
+
Ensure transformation logic is in the result function, and extraction logic is in the input selectors.`,{stack:a})}}},dv=(e,t,r)=>{const{memoize:n,memoizeOptions:a}=t,{inputSelectorResults:s,inputSelectorResultsCopy:o}=e,i=n(()=>({}),...a);if(!(i.apply(null,s)===i.apply(null,o))){let c;try{throw new Error}catch(u){({stack:c}=u)}console.warn(`An input selector returned a different result when passed same arguments.
|
|
91
|
+
This means your output selector will likely run more frequently than intended.
|
|
92
|
+
Avoid returning a new reference inside your input selector, e.g.
|
|
93
|
+
\`createSelector([state => state.todos.map(todo => todo.id)], todoIds => todoIds.length)\``,{arguments:r,firstInputs:s,secondInputs:o,stack:c})}},hv={inputStabilityCheck:"once",identityFunctionCheck:"once"},eo=Symbol("NOT_FOUND");function pv(e,t=`expected a function, instead received ${typeof e}`){if(typeof e!="function")throw new TypeError(t)}function fv(e,t=`expected an object, instead received ${typeof e}`){if(typeof e!="object")throw new TypeError(t)}function mv(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 ku=e=>Array.isArray(e)?e:[e];function gv(e){const t=Array.isArray(e[0])?e[0]:e;return mv(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function Lu(e,t){const r=[],{length:n}=e;for(let a=0;a<n;a++)r.push(e[a].apply(null,t));return r}var yv=(e,t)=>{const{identityFunctionCheck:r,inputStabilityCheck:n}={...hv,...t};return{identityFunctionCheck:{shouldRun:r==="always"||r==="once"&&e,run:uv},inputStabilityCheck:{shouldRun:n==="always"||n==="once"&&e,run:dv}}};function bv(e){let t;return{get(r){return t&&e(t.key,r)?t.value:eo},put(r,n){t={key:r,value:n}},getEntries(){return t?[t]:[]},clear(){t=void 0}}}function vv(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 eo}function a(i,l){n(i)===eo&&(r.unshift({key:i,value:l}),r.length>e&&r.pop())}function s(){return r}function o(){r=[]}return{get:n,put:a,getEntries:s,clear:o}}var xv=(e,t)=>e===t;function Sv(e){return function(r,n){if(r===null||n===null||r.length!==n.length)return!1;const{length:a}=r;for(let s=0;s<a;s++)if(!e(r[s],n[s]))return!1;return!0}}function Ov(e,t){const r=typeof t=="object"?t:{equalityCheck:t},{equalityCheck:n=xv,maxSize:a=1,resultEqualityCheck:s}=r,o=Sv(n);let i=0;const l=a<=1?bv(o):vv(a,o);function c(){let u=l.get(arguments);if(u===eo){if(u=e.apply(null,arguments),i++,s){const h=l.getEntries().find(p=>s(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 wv=class{constructor(e){this.value=e}deref(){return this.value}},Cv=typeof WeakRef<"u"?WeakRef:wv,Pv=0,Uu=1;function ms(){return{s:Pv,v:void 0,o:null,p:null}}function Xp(e,t={}){let r=ms();const{resultEqualityCheck:n}=t;let a,s=0;function o(){var d;let i=r;const{length:l}=arguments;for(let h=0,p=l;h<p;h++){const m=arguments[h];if(typeof m=="function"||typeof m=="object"&&m!==null){let f=i.o;f===null&&(i.o=f=new WeakMap);const g=f.get(m);g===void 0?(i=ms(),f.set(m,i)):i=g}else{let f=i.p;f===null&&(i.p=f=new Map);const g=f.get(m);g===void 0?(i=ms(),f.set(m,i)):i=g}}const c=i;let u;if(i.s===Uu)u=i.v;else if(u=e.apply(null,arguments),s++,n){const h=((d=a==null?void 0:a.deref)==null?void 0:d.call(a))??a;h!=null&&n(h,u)&&(u=h,s!==0&&s--),a=typeof u=="object"&&u!==null||typeof u=="function"?new Cv(u):u}return c.s=Uu,c.v=u,u}return o.clearCache=()=>{r=ms(),o.resetResultsCount()},o.resultsCount=()=>s,o.resetResultsCount=()=>{s=0},o}function Zp(e,...t){const r=typeof e=="function"?{memoize:e,memoizeOptions:t}:e,n=(...a)=>{let s=0,o=0,i,l={},c=a.pop();typeof c=="object"&&(l=c,c=a.pop()),pv(c,`createSelector expects an output function after the inputs, but received: [${typeof c}]`);const u={...r,...l},{memoize:d,memoizeOptions:h=[],argsMemoize:p=Xp,argsMemoizeOptions:m=[],devModeChecks:f={}}=u,g=ku(h),S=ku(m),T=gv(a),O=d(function(){return s++,c.apply(null,arguments)},...g);let C=!0;const V=p(function(){o++;const P=Lu(T,arguments);if(i=O.apply(null,P),process.env.NODE_ENV!=="production"){const{identityFunctionCheck:E,inputStabilityCheck:B}=yv(C,f);if(E.shouldRun&&E.run(c,P,i),B.shouldRun){const y=Lu(T,arguments);B.run({inputSelectorResults:P,inputSelectorResultsCopy:y},{memoize:d,memoizeOptions:g},arguments)}C&&(C=!1)}return i},...S);return Object.assign(V,{resultFunc:c,memoizedResultFunc:O,dependencies:T,dependencyRecomputations:()=>o,resetDependencyRecomputations:()=>{o=0},lastResult:()=>i,recomputations:()=>s,resetRecomputations:()=>{s=0},memoize:d,argsMemoize:p})};return Object.assign(n,{withTypes:()=>n}),n}var Rv=Zp(Xp),Tv=Object.assign((e,t=Rv)=>{fv(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(s=>e[s]);return t(n,(...s)=>s.reduce((o,i,l)=>(o[r[l]]=i,o),{}))},{withTypes:()=>Tv});const Av=Zp({memoize:Ov,memoizeOptions:{maxSize:1,equalityCheck:Object.is}}),Du=new WeakMap,ye=(...e)=>(r,...n)=>{const a=r.cacheKey;let s=Du.get(a);s||(s=new Map,Du.set(a,s));const o=s.get(e);if(o)return o(r,...n);const i=Av(...e);return s.set(e,i),i(r,...n)},Vv=e=>e.animation,Ev=ye([Vv],e=>e.skip||e.skipAnimationRequests>0);function _v(e){return e&&e.ownerDocument||document}function Iv(e){return _v(e).defaultView||window}var gs={exports:{}},_i={},ys={exports:{}},Ii={};/**
|
|
94
|
+
* @license React
|
|
95
|
+
* use-sync-external-store-shim.production.js
|
|
96
|
+
*
|
|
97
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
98
|
+
*
|
|
99
|
+
* This source code is licensed under the MIT license found in the
|
|
100
|
+
* LICENSE file in the root directory of this source tree.
|
|
101
|
+
*/var Nu;function Mv(){if(Nu)return Ii;Nu=1;var e=ae;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,s=e.useLayoutEffect,o=e.useDebugValue;function i(d,h){var p=h(),m=n({inst:{value:p,getSnapshot:h}}),f=m[0].inst,g=m[1];return s(function(){f.value=p,f.getSnapshot=h,l(f)&&g({inst:f})},[d,p,h]),a(function(){return l(f)&&g({inst:f}),d(function(){l(f)&&g({inst:f})})},[d]),o(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 Ii.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:u,Ii}var Mi={};/**
|
|
102
|
+
* @license React
|
|
103
|
+
* use-sync-external-store-shim.development.js
|
|
104
|
+
*
|
|
105
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
106
|
+
*
|
|
107
|
+
* This source code is licensed under the MIT license found in the
|
|
108
|
+
* LICENSE file in the root directory of this source tree.
|
|
109
|
+
*/var Fu;function $v(){return Fu||(Fu=1,process.env.NODE_ENV!=="production"&&function(){function e(p,m){return p===m&&(p!==0||1/p===1/m)||p!==p&&m!==m}function t(p,m){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 f=m();if(!d){var g=m();s(f,g)||(console.error("The result of getSnapshot should be cached to avoid an infinite loop"),d=!0)}g=o({inst:{value:f,getSnapshot:m}});var S=g[0].inst,T=g[1];return l(function(){S.value=f,S.getSnapshot=m,r(S)&&T({inst:S})},[p,f,m]),i(function(){return r(S)&&T({inst:S}),p(function(){r(S)&&T({inst:S})})},[p]),c(f),f}function r(p){var m=p.getSnapshot;p=p.value;try{var f=m();return!s(p,f)}catch{return!0}}function n(p,m){return m()}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var a=ae,s=typeof Object.is=="function"?Object.is:e,o=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;Mi.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())}()),Mi}var Bu;function ef(){return Bu||(Bu=1,process.env.NODE_ENV==="production"?ys.exports=Mv():ys.exports=$v()),ys.exports}/**
|
|
110
|
+
* @license React
|
|
111
|
+
* use-sync-external-store-shim/with-selector.production.js
|
|
112
|
+
*
|
|
113
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
114
|
+
*
|
|
115
|
+
* This source code is licensed under the MIT license found in the
|
|
116
|
+
* LICENSE file in the root directory of this source tree.
|
|
117
|
+
*/var zu;function jv(){if(zu)return _i;zu=1;var e=ae,t=ef();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,s=e.useRef,o=e.useEffect,i=e.useMemo,l=e.useDebugValue;return _i.useSyncExternalStoreWithSelector=function(c,u,d,h,p){var m=s(null);if(m.current===null){var f={hasValue:!1,value:null};m.current=f}else f=m.current;m=i(function(){function S(R){if(!T){if(T=!0,O=R,R=h(R),p!==void 0&&f.hasValue){var P=f.value;if(p(P,R))return C=P}return C=R}if(P=C,n(O,R))return P;var E=h(R);return p!==void 0&&p(P,E)?(O=R,P):(O=R,C=E)}var T=!1,O,C,V=d===void 0?null:d;return[function(){return S(u())},V===null?void 0:function(){return S(V())}]},[u,d,h,p]);var g=a(c,m[0],m[1]);return o(function(){f.hasValue=!0,f.value=g},[g]),l(g),g},_i}var $i={};/**
|
|
118
|
+
* @license React
|
|
119
|
+
* use-sync-external-store-shim/with-selector.development.js
|
|
120
|
+
*
|
|
121
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
122
|
+
*
|
|
123
|
+
* This source code is licensed under the MIT license found in the
|
|
124
|
+
* LICENSE file in the root directory of this source tree.
|
|
125
|
+
*/var Gu;function kv(){return Gu||(Gu=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=ae,r=ef(),n=typeof Object.is=="function"?Object.is:e,a=r.useSyncExternalStore,s=t.useRef,o=t.useEffect,i=t.useMemo,l=t.useDebugValue;$i.useSyncExternalStoreWithSelector=function(c,u,d,h,p){var m=s(null);if(m.current===null){var f={hasValue:!1,value:null};m.current=f}else f=m.current;m=i(function(){function S(R){if(!T){if(T=!0,O=R,R=h(R),p!==void 0&&f.hasValue){var P=f.value;if(p(P,R))return C=P}return C=R}if(P=C,n(O,R))return P;var E=h(R);return p!==void 0&&p(P,E)?(O=R,P):(O=R,C=E)}var T=!1,O,C,V=d===void 0?null:d;return[function(){return S(u())},V===null?void 0:function(){return S(V())}]},[u,d,h,p]);var g=a(c,m[0],m[1]);return o(function(){f.hasValue=!0,f.value=g},[g]),l(g),g},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())}()),$i}var Hu;function Lv(){return Hu||(Hu=1,process.env.NODE_ENV==="production"?gs.exports=jv():gs.exports=kv()),gs.exports}var Uv=Lv();const Dv=Object.is,bt=(e,t,r=[],n=Dv)=>{const a=s=>t(s,...r);return Uv.useSyncExternalStoreWithSelector(e.subscribe,e.getSnapshot,e.getSnapshot,a,n)},Nv="DEFAULT_X_AXIS_KEY",Fv="DEFAULT_Y_AXIS_KEY",Bv={top:20,bottom:20,left:20,right:20},zv=45,Gv=25,tf=20,Jn=e=>{var t;return(t=e.cartesianAxis)==null?void 0:t.x},Wn=e=>{var t;return(t=e.cartesianAxis)==null?void 0:t.y},Hv=ye([Wn],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)),qv=ye([Wn],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)),Jv=ye([Jn],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)),Wv=ye([Jn],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)),Kv=e=>e.dimensions,rf=e=>e.dimensions.width,nf=e=>e.dimensions.height,Yv=e=>e.dimensions.margin.top,Qv=e=>e.dimensions.margin.right,Xv=e=>e.dimensions.margin.bottom,Zv=e=>e.dimensions.margin.left,rs=ye([rf,nf,Yv,Qv,Xv,Zv,Jv,qv,Wv,Hv],(e,t,r,n,a,s,o,i,l,c)=>({width:e-s-n-c-i,left:s+c,right:n+i,height:t-r-a-o-l,top:r+o,bottom:a+l})),ex=ye([Kv],e=>({width:e.propsWidth,height:e.propsHeight})),tx=ye([rf,nf],(e,t)=>({width:e,height:t}));function af(e,t){return typeof e=="number"?{top:e,bottom:e,left:e,right:e}:t?K({},t,e):e}const rx=10,Fo=({params:e,store:t,svgRef:r})=>{const n=e.width!==void 0&&e.height!==void 0,a=F.useRef({displayError:!1,initialCompute:!0,computeRun:0}),[s,o]=F.useState(0),[i,l]=F.useState(0),c=F.useCallback(()=>{const m=r==null?void 0:r.current;if(!m)return{};const g=Iv(m).getComputedStyle(m),S=Math.floor(parseFloat(g.height))||0,T=Math.floor(parseFloat(g.width))||0;return t.update(O=>O.dimensions.width===T&&O.dimensions.height===S?O:K({},O,{dimensions:{margin:{top:e.margin.top,right:e.margin.right,bottom:e.margin.bottom,left:e.margin.left},width:e.width??T,height:e.height??S,propsWidth:e.width,propsHeight:e.height}})),{height:S,width:T}},[t,r,e.height,e.width,e.margin.left,e.margin.right,e.margin.top,e.margin.bottom]);F.useEffect(()=>{t.update(m=>{const f=e.width??m.dimensions.width,g=e.height??m.dimensions.height;return K({},m,{dimensions:{margin:{top:e.margin.top,right:e.margin.right,bottom:e.margin.bottom,left:e.margin.left},width:f,height:g,propsHeight:e.height,propsWidth:e.width}})})},[t,e.height,e.width,e.margin.left,e.margin.right,e.margin.top,e.margin.bottom]),F.useEffect(()=>{a.current.displayError=!0},[]),or(()=>{if(n||!a.current.initialCompute||a.current.computeRun>rx)return;const m=c();m.width!==s||m.height!==i?(a.current.computeRun+=1,m.width!==void 0&&o(m.width),m.height!==void 0&&l(m.height)):a.current.initialCompute&&(a.current.initialCompute=!1)},[i,s,c,n]),or(()=>{if(n)return()=>{};c();const m=r.current;if(typeof ResizeObserver>"u")return()=>{};let f;const g=new ResizeObserver(()=>{f=requestAnimationFrame(()=>{c()})});return m&&g.observe(m),()=>{f&&cancelAnimationFrame(f),m&&g.unobserve(m)}},[c,n,r]),process.env.NODE_ENV!=="production"&&(a.current.displayError&&e.width===void 0&&s===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=bt(t,rs),d=F.useCallback(m=>m>=u.left-1&&m<=u.left+u.width,[u.left,u.width]),h=F.useCallback(m=>m>=u.top-1&&m<=u.top+u.height,[u.height,u.top]);return{instance:{isPointInside:F.useCallback((m,f,g)=>g&&"closest"in g&&g.closest("[data-drawing-container]")?!0:d(m)&&h(f),[d,h]),isXInside:d,isYInside:h}}};Fo.params={width:!0,height:!0,margin:!0};Fo.getDefaultizedParams=({params:e})=>K({},e,{margin:af(e.margin,Bv)});Fo.getInitialState=({width:e,height:t,margin:r})=>({dimensions:{margin:r,width:e??0,height:t??0,propsWidth:e,propsHeight:t}});const ic=({params:e,store:t})=>(or(()=>{t.update(r=>K({},r,{experimentalFeatures:e.experimentalFeatures}))},[t,e.experimentalFeatures]),{});ic.params={experimentalFeatures:!0};ic.getInitialState=({experimentalFeatures:e})=>({experimentalFeatures:e});const nx=e=>e.experimentalFeatures,sf=ye([nx],e=>!!(e!=null&&e.preferStrictDomainInLineCharts));let qu=0;const ax=()=>(qu+=1,`mui-chart-${qu}`),lc=({params:e,store:t})=>(F.useEffect(()=>{t.update(r=>e.id===void 0||e.id===r.id.providedChartId&&r.id.chartId!==void 0?r:K({},r,{id:K({},r.id,{chartId:e.id??ax()})}))},[t,e.id]),{});lc.params={id:!0};lc.getInitialState=({id:e})=>({id:{chartId:e,providedChartId:e}});const sx=e=>e.id,ox=ye([sx],e=>e.chartId),ix=["#4254FB","#FFB422","#FA4F58","#0DBEFF","#22BF75","#FA83B4","#FF7511"],lx=["#495AFB","#FFC758","#F35865","#30C8FF","#44CE8D","#F286B3","#FF8C39"],of=e=>e==="dark"?lx:ix,lf=({series:e,colors:t,seriesConfig:r,dataset:n})=>{const a={};e.forEach((o,i)=>{var u;const l=r[o.type].getSeriesWithDefaultValues(o,i,t),c=l.id;if(a[o.type]===void 0&&(a[o.type]={series:{},seriesOrder:[]}),((u=a[o.type])==null?void 0:u.series[c])!==void 0)throw new Error(`MUI X Charts: series' id "${c}" is not unique.`);a[o.type].series[c]=l,a[o.type].seriesOrder.push(c)});const s={};return Object.keys(r).forEach(o=>{var l,c;const i=a[o];i!==void 0&&(s[o]=((c=(l=r[o])==null?void 0:l.seriesProcessor)==null?void 0:c.call(l,i,n))??a[o])}),s},Bo=({params:e,store:t,seriesConfig:r})=>{const{series:n,dataset:a,theme:s,colors:o}=e,i=F.useRef(!0);return F.useEffect(()=>{if(i.current){i.current=!1;return}t.update(l=>K({},l,{series:K({},l.series,{processedSeries:lf({series:n,colors:typeof o=="function"?o(s):o,seriesConfig:r,dataset:a})})}))},[o,a,n,s,r,t]),{}};Bo.params={dataset:!0,series:!0,colors:!0,theme:!0};const cx=[];Bo.getDefaultizedParams=({params:e})=>{var t;return K({},e,{series:(t=e.series)!=null&&t.length?e.series:cx,colors:e.colors??of,theme:e.theme??"light"})};Bo.getInitialState=({series:e=[],colors:t,theme:r,dataset:n},a,s)=>({series:{seriesConfig:s,processedSeries:lf({series:e,colors:typeof t=="function"?t(r):t,seriesConfig:s,dataset:n})}});const cf=e=>e.series,ns=ye([cf],e=>e.processedSeries),zo=ye([cf],e=>e.seriesConfig),ux={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 uf{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 ux)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 s=`${this.name}ChangeOptions`;this.element.addEventListener(s,this.handleOptionsChange.bind(this));const o=`${this.name}ChangeState`;this.element.addEventListener(o,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 dx{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 hx{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 px{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[s,o]of this.pointers.entries()){const i=K({},o,{type:"forceCancel"});this.pointers.set(s,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 fx{constructor(t){this.gestureTemplates=new Map,this.elementGestureMap=new Map,this.activeGesturesRegistry=new dx,this.pointerManager=void 0,this.keyboardManager=new hx,this.pointerManager=new px({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 s=new CustomEvent(`${t}ChangeOptions`,{detail:n,bubbles:!1,cancelable:!1});r.dispatchEvent(s)}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 s=new CustomEvent(`${t}ChangeState`,{detail:n,bubbles:!1,cancelable:!1});r.dispatchEvent(s)}registerElement(t,r,n){if(Array.isArray(t))return t.forEach(s=>{const o=n==null?void 0:n[s];this.registerSingleGesture(s,r,o)}),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 s=this.elementGestureMap.get(r);s.has(t)&&(console.warn(`Element already has gesture "${t}" registered. It will be replaced.`),this.unregisterElement(t,r));const o=a.clone(n);return o.init(r,this.pointerManager,this.activeGesturesRegistry,this.keyboardManager),s.set(t,o),!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 as extends uf{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((s,o)=>this.handlePointerEvent(s,o))}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 mx(e,t){const r=t.x-e.x,n=t.y-e.y;return Math.sqrt(r*r+n*n)}function ji(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+=mx({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 ir(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 Kn(e,t){return`${e}${t==="ongoing"?"":t.charAt(0).toUpperCase()+t.slice(1)}`}const bs=1e-5,br=1e-5,Ju=.15;function gx(e,t){const r=t.x-e.x,n=t.y-e.y,a={vertical:null,horizontal:null,mainAxis:null},s=yx(t,e),o=Math.abs(r)>Math.abs(n)?"horizontal":"vertical",i=s||o==="horizontal"?bs:Ju,l=s?bs:o==="horizontal"?Ju:bs;return Math.abs(r)>i&&(a.horizontal=r>0?"right":"left"),Math.abs(n)>l&&(a.vertical=n>0?"down":"up"),a.mainAxis=s?"diagonal":o,a}function yx(e,t){const r=t.x-e.x,n=t.y-e.y,a=Math.atan2(n,r)*180/Math.PI;return a>=-45+br&&a<=-22.5+br||a>=22.5+br&&a<=45+br||a>=135+br&&a<=157.5+br||a>=-157.5+br&&a<=-135+br}function bx(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 vx=0,xx=e=>e>vx?1:e<-0?-1:0;class cc extends as{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 cc(K({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 s={x:r.clientX,y:r.clientY};this.state.lastPosition=s,this.isActive||(this.isActive=!0,this.emitMoveEvent(a,"start",n,r)),this.emitMoveEvent(a,"ongoing",n,r)}emitMoveEvent(t,r,n,a){const s=this.state.lastPosition||ir(n),o=this.gesturesRegistry.getActiveGestures(t),i={gestureName:this.name,centroid:s,target:a.target,srcEvent:a,phase:r,pointers:n,timeStamp:a.timeStamp,activeGestures:o,customData:this.customData},l=Kn(this.name,r),c=new CustomEvent(l,{bubbles:!0,cancelable:!0,detail:i});t.dispatchEvent(c)}}class uc extends as{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 uc(K({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=K({},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 s=this.getRelevantPointers(n,a);if(s.length<this.minPointers||s.length>this.maxPointers){this.cancel(a,s,r);return}switch(r.type){case"pointerdown":!this.isActive&&!this.state.startCentroid&&(s.forEach(o=>{this.state.startPointers.set(o.pointerId,o)}),this.originalTarget=a,this.state.startCentroid=ir(s),this.state.lastCentroid=K({},this.state.startCentroid));break;case"pointermove":if(this.state.startCentroid&&s.length>=this.minPointers){const o=ir(s),i=o.x-this.state.startCentroid.x,l=o.y-this.state.startCentroid.y,c=Math.sqrt(i*i+l*l),u=gx(this.state.lastCentroid??this.state.startCentroid,o),d=this.state.lastCentroid?o.x-this.state.lastCentroid.x:0,h=this.state.lastCentroid?o.y-this.state.lastCentroid.y:0;!this.state.movementThresholdReached&&c>=this.threshold&&bx(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",s,r,o),this.emitPanEvent(a,"ongoing",s,r,o)):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",s,r,o)),this.state.lastCentroid=o,this.state.lastDirection=u}break;case"pointerup":case"pointercancel":case"forceCancel":if(this.isActive&&this.state.movementThresholdReached){if(s.filter(o=>o.type!=="pointerup"&&o.type!=="pointercancel").length<this.minPointers){const o=this.state.lastCentroid||this.state.startCentroid;r.type==="pointercancel"&&this.emitPanEvent(a,"cancel",s,r,o),this.emitPanEvent(a,"end",s,r,o),this.resetState()}}else this.resetState();break}}emitPanEvent(t,r,n,a,s){var S,T;if(!this.state.startCentroid)return;const o=((S=this.state.lastDeltas)==null?void 0:S.x)??0,i=((T=this.state.lastDeltas)==null?void 0:T.y)??0,l=this.state.startPointers.values().next().value,c=l?(a.timeStamp-l.timeStamp)/1e3:0,u=c>0?o/c:0,d=c>0?i/c:0,h=Math.sqrt(u*u+d*d),p=this.gesturesRegistry.getActiveGestures(t),m={gestureName:this.name,initialCentroid:this.state.startCentroid,centroid:s,target:a.target,srcEvent:a,phase:r,pointers:n,timeStamp:a.timeStamp,deltaX:o,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},f=Kn(this.name,r),g=new CustomEvent(f,{bubbles:!0,cancelable:!0,detail:m});t.dispatchEvent(g),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 dc extends as{constructor(t){super(K({},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 dc(K({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=K({},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 s=this.getRelevantPointers(n,a);switch(r.type){case"pointerdown":if(s.length>=2&&!this.isActive){const o=ji(s);this.state.startDistance=o,this.state.lastDistance=o,this.state.lastTime=r.timeStamp,this.originalTarget=a}break;case"pointermove":if(this.state.startDistance&&s.length>=this.minPointers){const o=ji(s),i=Math.abs(o-this.state.lastDistance);if(i!==0&&i>=this.threshold){const l=this.state.startDistance?o/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=(o-this.state.lastDistance)/u;this.state.velocity=Number.isNaN(h)?0:h}this.state.lastDistance=o,this.state.deltaScale=l-this.state.lastScale,this.state.lastScale=l,this.state.lastTime=r.timeStamp,this.isActive?this.emitPinchEvent(a,"ongoing",s,r):(this.isActive=!0,this.emitPinchEvent(a,"start",s,r),this.emitPinchEvent(a,"ongoing",s,r))}}break;case"pointerup":case"pointercancel":case"forceCancel":if(this.isActive){const o=s.filter(i=>i.type!=="pointerup"&&i.type!=="pointercancel");if(o.length<this.minPointers)r.type==="pointercancel"&&this.emitPinchEvent(a,"cancel",s,r),this.emitPinchEvent(a,"end",s,r),this.resetState();else if(o.length>=2){const i=ji(o);this.state.startDistance=i/this.state.lastScale}}break}}emitPinchEvent(t,r,n,a){const s=ir(n),o=this.state.lastDistance,i=this.state.lastScale,l=this.gesturesRegistry.getActiveGestures(t),c={gestureName:this.name,centroid:s,target:a.target,srcEvent:a,phase:r,pointers:n,timeStamp:a.timeStamp,scale:i,deltaScale:this.state.deltaScale,totalScale:this.state.totalScale,distance:o,velocity:this.state.velocity,activeGestures:l,direction:xx(this.state.velocity),customData:this.customData};this.preventDefault&&a.preventDefault(),this.stopPropagation&&a.stopPropagation();const u=Kn(this.name,r),d=new CustomEvent(u,{bubbles:!0,cancelable:!0,detail:c});t.dispatchEvent(d)}}class hc extends as{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 hc(K({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=K({},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 s=this.getRelevantPointers(n,a);if(s.length<this.minPointers||s.length>this.maxPointers){this.isActive&&this.cancelPress(a,s,r);return}switch(r.type){case"pointerdown":!this.isActive&&!this.state.startCentroid&&(this.state.startCentroid=ir(s),this.state.lastPosition=K({},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 o=this.state.lastPosition;this.emitPressEvent(a,"start",s,r,o),this.emitPressEvent(a,"ongoing",s,r,o)}},this.duration));break;case"pointermove":if(this.isActive&&this.state.startCentroid){const o=ir(s);this.state.lastPosition=o;const i=o.x-this.state.startCentroid.x,l=o.y-this.state.startCentroid.y;Math.sqrt(i*i+l*l)>this.maxDistance&&this.cancelPress(a,s,r)}break;case"pointerup":if(this.isActive){if(this.state.pressThresholdReached){const o=this.state.lastPosition||this.state.startCentroid;this.emitPressEvent(a,"end",s,r,o)}this.resetState()}break;case"pointercancel":case"forceCancel":this.cancelPress(a,s,r);break}}emitPressEvent(t,r,n,a,s){const o=this.gesturesRegistry.getActiveGestures(t),i=a.timeStamp-this.state.startTime,l={gestureName:this.name,centroid:s,target:a.target,srcEvent:a,phase:r,pointers:n,timeStamp:a.timeStamp,x:s.x,y:s.y,duration:i,activeGestures:o,customData:this.customData},c=Kn(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 pc extends as{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 pc(K({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 s=this.getRelevantPointers(n,a);if(this.shouldPreventGesture(a)||s.length<this.minPointers||s.length>this.maxPointers){this.isActive&&this.cancelTap(a,s,r);return}switch(r.type){case"pointerdown":this.isActive||(this.state.startCentroid=ir(s),this.state.lastPosition=K({},this.state.startCentroid),this.isActive=!0,this.originalTarget=a);break;case"pointermove":if(this.isActive&&this.state.startCentroid){const o=ir(s);this.state.lastPosition=o;const i=o.x-this.state.startCentroid.x,l=o.y-this.state.startCentroid.y;Math.sqrt(i*i+l*l)>this.maxDistance&&this.cancelTap(a,s,r)}break;case"pointerup":if(this.isActive){this.state.currentTapCount+=1;const o=this.state.lastPosition||this.state.startCentroid;if(!o){this.cancelTap(a,s,r);return}this.state.currentTapCount>=this.taps?(this.fireTapEvent(a,s,r,o),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,s,r);break}}fireTapEvent(t,r,n,a){const s=this.gesturesRegistry.getActiveGestures(t),o={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:s,customData:this.customData},i=new CustomEvent(this.name,{bubbles:!0,cancelable:!0,detail:o});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,s=this.gesturesRegistry.getActiveGestures(t),o={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:s,customData:this.customData},i=Kn(this.name,"cancel"),l=new CustomEvent(i,{bubbles:!0,cancelable:!0,detail:o});t.dispatchEvent(l)}this.resetState()}}class fc extends uf{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 fc(K({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?ir(t):{x:r.clientX,y:r.clientY},a=this.gesturesRegistry.getActiveGestures(this.element),s={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 o=Kn(this.name,"ongoing"),i=new CustomEvent(o,{bubbles:!0,cancelable:!0,detail:s});this.element.dispatchEvent(i)}}const yn=e=>e.preventDefault(),mc=({svgRef:e})=>{F.useEffect(()=>{const r=e.current;if(!r)return;const n=new fx({gestures:[new uc({name:"pan",threshold:0,maxPointers:1}),new cc({name:"move",preventIf:["pan","pinch"]}),new dc({name:"pinch",threshold:5,preventIf:["pan"]}),new fc({name:"turnWheel",sensitivity:.01,initialDelta:1}),new pc({name:"tap",maxDistance:10,preventIf:["pan","pinch"]}),new hc({name:"quickPress",duration:50,maxDistance:10})]});return n.registerElement(["pan","move","pinch","turnWheel","tap","quickPress"],r),()=>{n.destroy()}},[e]);const t=F.useCallback((r,n,a)=>{const s=e.current;return s==null||s.addEventListener(r,n,a),{cleanup:()=>s==null?void 0:s.removeEventListener(r,n)}},[e]);return F.useEffect(()=>{const r=e.current;return r==null||r.addEventListener("gesturestart",yn),r==null||r.addEventListener("gesturechange",yn),r==null||r.addEventListener("gestureend",yn),()=>{r==null||r.removeEventListener("gesturestart",yn),r==null||r.removeEventListener("gesturechange",yn),r==null||r.removeEventListener("gestureend",yn)}},[e]),{instance:{addInteractionListener:t}}};mc.params={};mc.getInitialState=()=>({});const Sx=[lc,ic,Fo,Bo,mc,No],Ox=["apiRef"],wx=e=>{let{plugins:t}=e,r=Cr(e.props,Ox);const n={};t.forEach(o=>{Object.assign(n,o.params)});const a={};return Object.keys(r).forEach(o=>{const i=r[o];n[o]&&(a[o]=i)}),t.reduce((o,i)=>i.getDefaultizedParams?i.getDefaultizedParams({params:o}):o,a)};let Wu=0;function Cx(e,t,r){const n=lv(),a=F.useMemo(()=>[...Sx,...e],[e]),s=wx({plugins:a,props:t});s.id=s.id??n;const i=F.useRef({}).current,l=Rx(t.apiRef),c=F.useRef(null),u=F.useRef(null),d=F.useRef(null);if(d.current==null){Wu+=1;const m={cacheKey:{id:Wu}};a.forEach(f=>{f.getInitialState&&Object.assign(m,f.getInitialState(s,m,r))}),d.current=new cv(m)}const h=m=>{const f=m({instance:i,params:s,plugins:a,store:d.current,svgRef:u,chartRootRef:c,seriesConfig:r});f.publicAPI&&Object.assign(l.current,f.publicAPI),f.instance&&Object.assign(i,f.instance)};return a.forEach(h),{contextValue:F.useMemo(()=>({store:d.current,publicAPI:l.current,instance:i,svgRef:u,chartRootRef:c}),[i,l])}}function Px(e){return e.current==null&&(e.current={}),e}function Rx(e){const t=F.useRef({});return e?Px(e):t}const gc=F.createContext(null);process.env.NODE_ENV!=="production"&&(gc.displayName="ChartContext");const Ku=new Set;function Da(e,t="warning"){if(process.env.NODE_ENV==="production")return;const r=Array.isArray(e)?e.join(`
|
|
126
|
+
`):e;Ku.has(r)||(Ku.add(r),t==="error"?console.error(r):console.warn(r))}function Tx(e){const{componentName:t,propName:r,controlled:n,defaultValue:a,warningPrefix:s="MUI X"}=e,[{initialDefaultValue:o,isControlled:i}]=F.useState({initialDefaultValue:a,isControlled:n!==void 0});i!==(n!==void 0)&&Da([`${s}: 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(o)!==JSON.stringify(a)&&Da([`${s}: 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 df=process.env.NODE_ENV==="production"?()=>{}:Tx,hf=4,pf=20+2*hf,Ax=40+2*hf,Vx="hover",vs={minStart:0,maxEnd:100,step:5,minSpan:10,maxSpan:100,panning:!0,filterMode:"keep",slider:{enabled:!1,preview:!1,size:pf,showTooltip:Vx}},yc=(e,t,r)=>{var n;if(e)return e===!0?K({axisId:t,axisDirection:r},vs):K({axisId:t,axisDirection:r},vs,e,{slider:K({},vs.slider,{size:((n=e.slider)==null?void 0:n.preview)??vs.slider.preview?Ax:pf},e.slider)})};function ff(e,t){const r={top:0,bottom:0,none:0};return(e&&e.length>0?e:[{id:Nv,scaleType:"linear"}]).map((s,o)=>{var p;const i=s.dataKey,l=o===0?"bottom":"none",c=s.position??l,u=Gv+(s.label?tf:0),d=s.id??`defaultized-x-axis-${o}`,h=K({offset:r[c]},s,{id:d,position:c,height:s.height??u,zoom:yc(s.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||s.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 K({},h,{data:t.map(m=>m[i])})})}function mf(e,t){const r={right:0,left:0,none:0};return(e&&e.length>0?e:[{id:Fv,scaleType:"linear"}]).map((s,o)=>{var p;const i=s.dataKey,l=o===0?"left":"none",c=s.position??l,u=zv+(s.label?tf:0),d=s.id??`defaultized-y-axis-${o}`,h=K({offset:r[c]},s,{id:d,position:c,width:s.width??u,zoom:yc(s.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||s.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 K({},h,{data:t.map(m=>m[i])})})}function zs(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function Ex(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function bc(e){let t,r,n;e.length!==2?(t=zs,r=(i,l)=>zs(e(i),l),n=(i,l)=>e(i)-l):(t=e===zs||e===Ex?e:_x,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 s(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){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:o,right:s}}function _x(){return 0}function Ix(e){return e===null?NaN:+e}const Mx=bc(zs),gf=Mx.right;bc(Ix).center;class Yu extends Map{constructor(t,r=kx){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(Qu(this,t))}has(t){return super.has(Qu(this,t))}set(t,r){return super.set($x(this,t),r)}delete(t){return super.delete(jx(this,t))}}function Qu({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):r}function $x({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):(e.set(n,r),r)}function jx({_intern:e,_key:t},r){const n=t(r);return e.has(n)&&(r=e.get(n),e.delete(n)),r}function kx(e){return e!==null&&typeof e=="object"?e.valueOf():e}const Lx=Math.sqrt(50),Ux=Math.sqrt(10),Dx=Math.sqrt(2);function to(e,t,r){const n=(t-e)/Math.max(0,r),a=Math.floor(Math.log10(n)),s=n/Math.pow(10,a),o=s>=Lx?10:s>=Ux?5:s>=Dx?2:1;let i,l,c;return a<0?(c=Math.pow(10,-a)/o,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)*o,i=Math.round(e/c),l=Math.round(t/c),i*c<e&&++i,l*c>t&&--l),l<i&&.5<=r&&r<2?to(e,t,r*2):[i,l,c]}function vl(e,t,r){if(t=+t,e=+e,r=+r,!(r>0))return[];if(e===t)return[e];const n=t<e,[a,s,o]=n?to(t,e,r):to(e,t,r);if(!(s>=a))return[];const i=s-a+1,l=new Array(i);if(n)if(o<0)for(let c=0;c<i;++c)l[c]=(s-c)/-o;else for(let c=0;c<i;++c)l[c]=(s-c)*o;else if(o<0)for(let c=0;c<i;++c)l[c]=(a+c)/-o;else for(let c=0;c<i;++c)l[c]=(a+c)*o;return l}function xl(e,t,r){return t=+t,e=+e,r=+r,to(e,t,r)[2]}function Sl(e,t,r){t=+t,e=+e,r=+r;const n=t<e,a=n?xl(t,e,r):xl(e,t,r);return(n?-1:1)*(a<0?1/-a:a)}function Nx(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,s=new Array(a);++n<a;)s[n]=e+n*r;return s}function Vr(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function Fx(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 Xu=Symbol("implicit");function ro(){var e=new Yu,t=[],r=[],n=Xu;function a(s){let o=e.get(s);if(o===void 0){if(n!==Xu)return n;e.set(s,o=t.push(s)-1)}return r[o%r.length]}return a.domain=function(s){if(!arguments.length)return t.slice();t=[],e=new Yu;for(const o of s)e.has(o)||e.set(o,t.push(o)-1);return a},a.range=function(s){return arguments.length?(r=Array.from(s),a):r.slice()},a.unknown=function(s){return arguments.length?(n=s,a):n},a.copy=function(){return ro(t,r).unknown(n)},Vr.apply(a,arguments),a}function vc(){var e=ro().unknown(void 0),t=e.domain,r=e.range,n=0,a=1,s,o,i=!1,l=0,c=0,u=.5;delete e.unknown;function d(){var h=t().length,p=a<n,m=p?a:n,f=p?n:a;s=(f-m)/Math.max(1,h-l+c*2),i&&(s=Math.floor(s)),m+=(f-m-s*(h-l))*u,o=s*(1-l),i&&(m=Math.round(m),o=Math.round(o));var g=Nx(h).map(function(S){return m+s*S});return r(p?g.reverse():g)}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 o},e.step=function(){return s},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 vc(t(),[n,a]).round(i).paddingInner(l).paddingOuter(c).align(u)},Vr.apply(d(),arguments)}function yf(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return yf(t())},e}function Bx(){return yf(vc.apply(null,arguments).paddingInner(1))}function xc(e,t,r){e.prototype=t.prototype=r,r.constructor=e}function bf(e,t){var r=Object.create(e.prototype);for(var n in t)r[n]=t[n];return r}function ss(){}var Na=.7,no=1/Na,$n="\\s*([+-]?\\d+)\\s*",Fa="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Qt="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",zx=/^#([0-9a-f]{3,8})$/,Gx=new RegExp(`^rgb\\(${$n},${$n},${$n}\\)$`),Hx=new RegExp(`^rgb\\(${Qt},${Qt},${Qt}\\)$`),qx=new RegExp(`^rgba\\(${$n},${$n},${$n},${Fa}\\)$`),Jx=new RegExp(`^rgba\\(${Qt},${Qt},${Qt},${Fa}\\)$`),Wx=new RegExp(`^hsl\\(${Fa},${Qt},${Qt}\\)$`),Kx=new RegExp(`^hsla\\(${Fa},${Qt},${Qt},${Fa}\\)$`),Zu={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};xc(ss,Ba,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:ed,formatHex:ed,formatHex8:Yx,formatHsl:Qx,formatRgb:td,toString:td});function ed(){return this.rgb().formatHex()}function Yx(){return this.rgb().formatHex8()}function Qx(){return vf(this).formatHsl()}function td(){return this.rgb().formatRgb()}function Ba(e){var t,r;return e=(e+"").trim().toLowerCase(),(t=zx.exec(e))?(r=t[1].length,t=parseInt(t[1],16),r===6?rd(t):r===3?new vt(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):r===8?xs(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?xs(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=Gx.exec(e))?new vt(t[1],t[2],t[3],1):(t=Hx.exec(e))?new vt(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=qx.exec(e))?xs(t[1],t[2],t[3],t[4]):(t=Jx.exec(e))?xs(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=Wx.exec(e))?sd(t[1],t[2]/100,t[3]/100,1):(t=Kx.exec(e))?sd(t[1],t[2]/100,t[3]/100,t[4]):Zu.hasOwnProperty(e)?rd(Zu[e]):e==="transparent"?new vt(NaN,NaN,NaN,0):null}function rd(e){return new vt(e>>16&255,e>>8&255,e&255,1)}function xs(e,t,r,n){return n<=0&&(e=t=r=NaN),new vt(e,t,r,n)}function Xx(e){return e instanceof ss||(e=Ba(e)),e?(e=e.rgb(),new vt(e.r,e.g,e.b,e.opacity)):new vt}function Ol(e,t,r,n){return arguments.length===1?Xx(e):new vt(e,t,r,n??1)}function vt(e,t,r,n){this.r=+e,this.g=+t,this.b=+r,this.opacity=+n}xc(vt,Ol,bf(ss,{brighter(e){return e=e==null?no:Math.pow(no,e),new vt(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Na:Math.pow(Na,e),new vt(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new vt(Fr(this.r),Fr(this.g),Fr(this.b),ao(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:nd,formatHex:nd,formatHex8:Zx,formatRgb:ad,toString:ad}));function nd(){return`#${Lr(this.r)}${Lr(this.g)}${Lr(this.b)}`}function Zx(){return`#${Lr(this.r)}${Lr(this.g)}${Lr(this.b)}${Lr((isNaN(this.opacity)?1:this.opacity)*255)}`}function ad(){const e=ao(this.opacity);return`${e===1?"rgb(":"rgba("}${Fr(this.r)}, ${Fr(this.g)}, ${Fr(this.b)}${e===1?")":`, ${e})`}`}function ao(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Fr(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Lr(e){return e=Fr(e),(e<16?"0":"")+e.toString(16)}function sd(e,t,r,n){return n<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new Ut(e,t,r,n)}function vf(e){if(e instanceof Ut)return new Ut(e.h,e.s,e.l,e.opacity);if(e instanceof ss||(e=Ba(e)),!e)return new Ut;if(e instanceof Ut)return e;e=e.rgb();var t=e.r/255,r=e.g/255,n=e.b/255,a=Math.min(t,r,n),s=Math.max(t,r,n),o=NaN,i=s-a,l=(s+a)/2;return i?(t===s?o=(r-n)/i+(r<n)*6:r===s?o=(n-t)/i+2:o=(t-r)/i+4,i/=l<.5?s+a:2-s-a,o*=60):i=l>0&&l<1?0:o,new Ut(o,i,l,e.opacity)}function eS(e,t,r,n){return arguments.length===1?vf(e):new Ut(e,t,r,n??1)}function Ut(e,t,r,n){this.h=+e,this.s=+t,this.l=+r,this.opacity=+n}xc(Ut,eS,bf(ss,{brighter(e){return e=e==null?no:Math.pow(no,e),new Ut(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Na:Math.pow(Na,e),new Ut(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 vt(ki(e>=240?e-240:e+120,a,n),ki(e,a,n),ki(e<120?e+240:e-120,a,n),this.opacity)},clamp(){return new Ut(od(this.h),Ss(this.s),Ss(this.l),ao(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=ao(this.opacity);return`${e===1?"hsl(":"hsla("}${od(this.h)}, ${Ss(this.s)*100}%, ${Ss(this.l)*100}%${e===1?")":`, ${e})`}`}}));function od(e){return e=(e||0)%360,e<0?e+360:e}function Ss(e){return Math.max(0,Math.min(1,e||0))}function ki(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 Sc=e=>()=>e;function tS(e,t){return function(r){return e+r*t}}function rS(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 nS(e){return(e=+e)==1?xf:function(t,r){return r-t?rS(t,r,e):Sc(isNaN(t)?r:t)}}function xf(e,t){var r=t-e;return r?tS(e,r):Sc(isNaN(e)?t:e)}const id=function e(t){var r=nS(t);function n(a,s){var o=r((a=Ol(a)).r,(s=Ol(s)).r),i=r(a.g,s.g),l=r(a.b,s.b),c=xf(a.opacity,s.opacity);return function(u){return a.r=o(u),a.g=i(u),a.b=l(u),a.opacity=c(u),a+""}}return n.gamma=e,n}(1);function aS(e,t){t||(t=[]);var r=e?Math.min(t.length,e.length):0,n=t.slice(),a;return function(s){for(a=0;a<r;++a)n[a]=e[a]*(1-s)+t[a]*s;return n}}function sS(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function oS(e,t){var r=t?t.length:0,n=e?Math.min(r,e.length):0,a=new Array(n),s=new Array(r),o;for(o=0;o<n;++o)a[o]=Go(e[o],t[o]);for(;o<r;++o)s[o]=t[o];return function(i){for(o=0;o<n;++o)s[o]=a[o](i);return s}}function Oc(e,t){var r=new Date;return e=+e,t=+t,function(n){return r.setTime(e*(1-n)+t*n),r}}function Dt(e,t){return e=+e,t=+t,function(r){return e*(1-r)+t*r}}function iS(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]=Go(e[a],t[a]):n[a]=t[a];return function(s){for(a in r)n[a]=r[a](s);return n}}var wl=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Li=new RegExp(wl.source,"g");function lS(e){return function(){return e}}function cS(e){return function(t){return e(t)+""}}function uS(e,t){var r=wl.lastIndex=Li.lastIndex=0,n,a,s,o=-1,i=[],l=[];for(e=e+"",t=t+"";(n=wl.exec(e))&&(a=Li.exec(t));)(s=a.index)>r&&(s=t.slice(r,s),i[o]?i[o]+=s:i[++o]=s),(n=n[0])===(a=a[0])?i[o]?i[o]+=a:i[++o]=a:(i[++o]=null,l.push({i:o,x:Dt(n,a)})),r=Li.lastIndex;return r<t.length&&(s=t.slice(r),i[o]?i[o]+=s:i[++o]=s),i.length<2?l[0]?cS(l[0].x):lS(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 Go(e,t){var r=typeof t,n;return t==null||r==="boolean"?Sc(t):(r==="number"?Dt:r==="string"?(n=Ba(t))?(t=n,id):uS:t instanceof Ba?id:t instanceof Date?Oc:sS(t)?aS:Array.isArray(t)?oS:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?iS:Dt)(e,t)}function Sf(e,t){return e=+e,t=+t,function(r){return Math.round(e*(1-r)+t*r)}}function dS(e){return function(){return e}}function hS(e){return+e}var ld=[0,1];function At(e){return e}function Cl(e,t){return(t-=e=+e)?function(r){return(r-e)/t}:dS(isNaN(t)?NaN:.5)}function pS(e,t){var r;return e>t&&(r=e,e=t,t=r),function(n){return Math.max(e,Math.min(t,n))}}function fS(e,t,r){var n=e[0],a=e[1],s=t[0],o=t[1];return a<n?(n=Cl(a,n),s=r(o,s)):(n=Cl(n,a),s=r(s,o)),function(i){return s(n(i))}}function mS(e,t,r){var n=Math.min(e.length,t.length)-1,a=new Array(n),s=new Array(n),o=-1;for(e[n]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++o<n;)a[o]=Cl(e[o],e[o+1]),s[o]=r(t[o],t[o+1]);return function(i){var l=gf(e,i,1,n)-1;return s[l](a[l](i))}}function Ho(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function wc(){var e=ld,t=ld,r=Go,n,a,s,o=At,i,l,c;function u(){var h=Math.min(e.length,t.length);return o!==At&&(o=pS(e[0],e[h-1])),i=h>2?mS:fS,l=c=null,d}function d(h){return h==null||isNaN(h=+h)?s:(l||(l=i(e.map(n),t,r)))(n(o(h)))}return d.invert=function(h){return o(a((c||(c=i(t,e.map(n),Dt)))(h)))},d.domain=function(h){return arguments.length?(e=Array.from(h,hS),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=Sf,u()},d.clamp=function(h){return arguments.length?(o=h?!0:At,u()):o!==At},d.interpolate=function(h){return arguments.length?(r=h,u()):r},d.unknown=function(h){return arguments.length?(s=h,d):s},function(h,p){return n=h,a=p,u()}}function Of(){return wc()(At,At)}function gS(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function so(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 Dn(e){return e=so(Math.abs(e)),e?e[1]:NaN}function yS(e,t){return function(r,n){for(var a=r.length,s=[],o=0,i=e[0],l=0;a>0&&i>0&&(l+i+1>n&&(i=Math.max(1,n-l)),s.push(r.substring(a-=i,a+i)),!((l+=i+1)>n));)i=e[o=(o+1)%e.length];return s.reverse().join(t)}}function bS(e){return function(t){return t.replace(/[0-9]/g,function(r){return e[+r]})}}var vS=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function za(e){if(!(t=vS.exec(e)))throw new Error("invalid format: "+e);var t;return new Cc({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]})}za.prototype=Cc.prototype;function Cc(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+""}Cc.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 xS(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 wf;function SS(e,t){var r=so(e,t);if(!r)return e+"";var n=r[0],a=r[1],s=a-(wf=Math.max(-8,Math.min(8,Math.floor(a/3)))*3)+1,o=n.length;return s===o?n:s>o?n+new Array(s-o+1).join("0"):s>0?n.slice(0,s)+"."+n.slice(s):"0."+new Array(1-s).join("0")+so(e,Math.max(0,t+s-1))[0]}function cd(e,t){var r=so(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 ud={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:gS,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)=>cd(e*100,t),r:cd,s:SS,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function dd(e){return e}var hd=Array.prototype.map,pd=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function OS(e){var t=e.grouping===void 0||e.thousands===void 0?dd:yS(hd.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+"",s=e.numerals===void 0?dd:bS(hd.call(e.numerals,String)),o=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=za(d);var h=d.fill,p=d.align,m=d.sign,f=d.symbol,g=d.zero,S=d.width,T=d.comma,O=d.precision,C=d.trim,V=d.type;V==="n"?(T=!0,V="g"):ud[V]||(O===void 0&&(O=12),C=!0,V="g"),(g||h==="0"&&p==="=")&&(g=!0,h="0",p="=");var R=f==="$"?r:f==="#"&&/[boxX]/.test(V)?"0"+V.toLowerCase():"",P=f==="$"?n:/[%p]/.test(V)?o:"",E=ud[V],B=/[defgprs%]/.test(V);O=O===void 0?6:/[gprs]/.test(V)?Math.max(1,Math.min(21,O)):Math.max(0,Math.min(20,O));function y(A){var z=R,I=P,G,re,te;if(V==="c")I=E(A)+I,A="";else{A=+A;var oe=A<0||1/A<0;if(A=isNaN(A)?l:E(Math.abs(A),O),C&&(A=xS(A)),oe&&+A==0&&m!=="+"&&(oe=!1),z=(oe?m==="("?m:i:m==="-"||m==="("?"":m)+z,I=(V==="s"?pd[8+wf/3]:"")+I+(oe&&m==="("?")":""),B){for(G=-1,re=A.length;++G<re;)if(te=A.charCodeAt(G),48>te||te>57){I=(te===46?a+A.slice(G+1):A.slice(G))+I,A=A.slice(0,G);break}}}T&&!g&&(A=t(A,1/0));var Z=z.length+A.length+I.length,se=Z<S?new Array(S-Z+1).join(h):"";switch(T&&g&&(A=t(se+A,se.length?S-I.length:1/0),se=""),p){case"<":A=z+A+I+se;break;case"=":A=z+se+A+I;break;case"^":A=se.slice(0,Z=se.length>>1)+z+A+I+se.slice(Z);break;default:A=se+z+A+I;break}return s(A)}return y.toString=function(){return d+""},y}function u(d,h){var p=c((d=za(d),d.type="f",d)),m=Math.max(-8,Math.min(8,Math.floor(Dn(h)/3)))*3,f=Math.pow(10,-m),g=pd[8+m/3];return function(S){return p(f*S)+g}}return{format:c,formatPrefix:u}}var Os,Pc,Cf;wS({thousands:",",grouping:[3],currency:["$",""]});function wS(e){return Os=OS(e),Pc=Os.format,Cf=Os.formatPrefix,Os}function CS(e){return Math.max(0,-Dn(Math.abs(e)))}function PS(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Dn(t)/3)))*3-Dn(Math.abs(e)))}function RS(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Dn(t)-Dn(e))+1}function TS(e,t,r,n){var a=Sl(e,t,r),s;switch(n=za(n??",f"),n.type){case"s":{var o=Math.max(Math.abs(e),Math.abs(t));return n.precision==null&&!isNaN(s=PS(a,o))&&(n.precision=s),Cf(n,o)}case"":case"e":case"g":case"p":case"r":{n.precision==null&&!isNaN(s=RS(a,Math.max(Math.abs(e),Math.abs(t))))&&(n.precision=s-(n.type==="e"));break}case"f":case"%":{n.precision==null&&!isNaN(s=CS(a))&&(n.precision=s-(n.type==="%")*2);break}}return Pc(n)}function Rc(e){var t=e.domain;return e.ticks=function(r){var n=t();return vl(n[0],n[n.length-1],r??10)},e.tickFormat=function(r,n){var a=t();return TS(a[0],a[a.length-1],r??10,n)},e.nice=function(r){r==null&&(r=10);var n=t(),a=0,s=n.length-1,o=n[a],i=n[s],l,c,u=10;for(i<o&&(c=o,o=i,i=c,c=a,a=s,s=c);u-- >0;){if(c=xl(o,i,r),c===l)return n[a]=o,n[s]=i,t(n);if(c>0)o=Math.floor(o/c)*c,i=Math.ceil(i/c)*c;else if(c<0)o=Math.ceil(o*c)/c,i=Math.floor(i*c)/c;else break;l=c}return e},e}function Pf(){var e=Of();return e.copy=function(){return Ho(e,Pf())},Vr.apply(e,arguments),Rc(e)}function Rf(e,t){e=e.slice();var r=0,n=e.length-1,a=e[r],s=e[n],o;return s<a&&(o=r,r=n,n=o,o=a,a=s,s=o),e[r]=t.floor(a),e[n]=t.ceil(s),e}function fd(e){return Math.log(e)}function md(e){return Math.exp(e)}function AS(e){return-Math.log(-e)}function VS(e){return-Math.exp(-e)}function ES(e){return isFinite(e)?+("1e"+e):e<0?0:e}function _S(e){return e===10?ES:e===Math.E?Math.exp:t=>Math.pow(e,t)}function IS(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 gd(e){return(t,r)=>-e(-t,r)}function MS(e){const t=e(fd,md),r=t.domain;let n=10,a,s;function o(){return a=IS(n),s=_S(n),r()[0]<0?(a=gd(a),s=gd(s),e(AS,VS)):e(fd,md),t}return t.base=function(i){return arguments.length?(n=+i,o()):n},t.domain=function(i){return arguments.length?(r(i),o()):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),m,f;const g=i==null?10:+i;let S=[];if(!(n%1)&&p-h<g){if(h=Math.floor(h),p=Math.ceil(p),c>0){for(;h<=p;++h)for(m=1;m<n;++m)if(f=h<0?m/s(-h):m*s(h),!(f<c)){if(f>u)break;S.push(f)}}else for(;h<=p;++h)for(m=n-1;m>=1;--m)if(f=h>0?m/s(-h):m*s(h),!(f<c)){if(f>u)break;S.push(f)}S.length*2<g&&(S=vl(c,u,g))}else S=vl(h,p,Math.min(p-h,g)).map(s);return d?S.reverse():S},t.tickFormat=(i,l)=>{if(i==null&&(i=10),l==null&&(l=n===10?"s":","),typeof l!="function"&&(!(n%1)&&(l=za(l)).precision==null&&(l.trim=!0),l=Pc(l)),i===1/0)return l;const c=Math.max(1,n*i/t.ticks().length);return u=>{let d=u/s(Math.round(a(u)));return d*n<n-.5&&(d*=n),d<=c?l(u):""}},t.nice=()=>r(Rf(r(),{floor:i=>s(Math.floor(a(i))),ceil:i=>s(Math.ceil(a(i)))})),t}function Tf(){const e=MS(wc()).domain([1,10]);return e.copy=()=>Ho(e,Tf()).base(e.base()),Vr.apply(e,arguments),e}function yd(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function $S(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function jS(e){return e<0?-e*e:e*e}function kS(e){var t=e(At,At),r=1;function n(){return r===1?e(At,At):r===.5?e($S,jS):e(yd(r),yd(1/r))}return t.exponent=function(a){return arguments.length?(r=+a,n()):r},Rc(t)}function Tc(){var e=kS(wc());return e.copy=function(){return Ho(e,Tc()).exponent(e.exponent())},Vr.apply(e,arguments),e}function LS(){return Tc.apply(null,arguments).exponent(.5)}function Af(){var e=[.5],t=[0,1],r,n=1;function a(s){return s!=null&&s<=s?t[gf(e,s,0,n)]:r}return a.domain=function(s){return arguments.length?(e=Array.from(s),n=Math.min(e.length,t.length-1),a):e.slice()},a.range=function(s){return arguments.length?(t=Array.from(s),n=Math.min(e.length,t.length-1),a):t.slice()},a.invertExtent=function(s){var o=t.indexOf(s);return[e[o-1],e[o]]},a.unknown=function(s){return arguments.length?(r=s,a):r},a.copy=function(){return Af().domain(e).range(t).unknown(r)},Vr.apply(a,arguments)}const Ui=new Date,Di=new Date;function et(e,t,r,n){function a(s){return e(s=arguments.length===0?new Date:new Date(+s)),s}return a.floor=s=>(e(s=new Date(+s)),s),a.ceil=s=>(e(s=new Date(s-1)),t(s,1),e(s),s),a.round=s=>{const o=a(s),i=a.ceil(s);return s-o<i-s?o:i},a.offset=(s,o)=>(t(s=new Date(+s),o==null?1:Math.floor(o)),s),a.range=(s,o,i)=>{const l=[];if(s=a.ceil(s),i=i==null?1:Math.floor(i),!(s<o)||!(i>0))return l;let c;do l.push(c=new Date(+s)),t(s,i),e(s);while(c<s&&s<o);return l},a.filter=s=>et(o=>{if(o>=o)for(;e(o),!s(o);)o.setTime(o-1)},(o,i)=>{if(o>=o)if(i<0)for(;++i<=0;)for(;t(o,-1),!s(o););else for(;--i>=0;)for(;t(o,1),!s(o););}),r&&(a.count=(s,o)=>(Ui.setTime(+s),Di.setTime(+o),e(Ui),e(Di),Math.floor(r(Ui,Di))),a.every=s=>(s=Math.floor(s),!isFinite(s)||!(s>0)?null:s>1?a.filter(n?o=>n(o)%s===0:o=>a.count(0,o)%s===0):a)),a}const oo=et(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);oo.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?et(t=>{t.setTime(Math.floor(t/e)*e)},(t,r)=>{t.setTime(+t+r*e)},(t,r)=>(r-t)/e):oo);oo.range;const nr=1e3,Vt=nr*60,ar=Vt*60,lr=ar*24,Ac=lr*7,bd=lr*30,Ni=lr*365,Ur=et(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*nr)},(e,t)=>(t-e)/nr,e=>e.getUTCSeconds());Ur.range;const Vc=et(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*nr)},(e,t)=>{e.setTime(+e+t*Vt)},(e,t)=>(t-e)/Vt,e=>e.getMinutes());Vc.range;const Ec=et(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Vt)},(e,t)=>(t-e)/Vt,e=>e.getUTCMinutes());Ec.range;const _c=et(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*nr-e.getMinutes()*Vt)},(e,t)=>{e.setTime(+e+t*ar)},(e,t)=>(t-e)/ar,e=>e.getHours());_c.range;const Ic=et(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*ar)},(e,t)=>(t-e)/ar,e=>e.getUTCHours());Ic.range;const os=et(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Vt)/lr,e=>e.getDate()-1);os.range;const qo=et(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/lr,e=>e.getUTCDate()-1);qo.range;const Vf=et(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/lr,e=>Math.floor(e/lr));Vf.range;function Kr(e){return et(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())*Vt)/Ac)}const Jo=Kr(0),io=Kr(1),US=Kr(2),DS=Kr(3),Nn=Kr(4),NS=Kr(5),FS=Kr(6);Jo.range;io.range;US.range;DS.range;Nn.range;NS.range;FS.range;function Yr(e){return et(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)/Ac)}const Wo=Yr(0),lo=Yr(1),BS=Yr(2),zS=Yr(3),Fn=Yr(4),GS=Yr(5),HS=Yr(6);Wo.range;lo.range;BS.range;zS.range;Fn.range;GS.range;HS.range;const Mc=et(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());Mc.range;const $c=et(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());$c.range;const cr=et(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());cr.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:et(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)});cr.range;const ur=et(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());ur.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:et(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)});ur.range;function Ef(e,t,r,n,a,s){const o=[[Ur,1,nr],[Ur,5,5*nr],[Ur,15,15*nr],[Ur,30,30*nr],[s,1,Vt],[s,5,5*Vt],[s,15,15*Vt],[s,30,30*Vt],[a,1,ar],[a,3,3*ar],[a,6,6*ar],[a,12,12*ar],[n,1,lr],[n,2,2*lr],[r,1,Ac],[t,1,bd],[t,3,3*bd],[e,1,Ni]];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),m=p?p.range(c,+u+1):[];return h?m.reverse():m}function l(c,u,d){const h=Math.abs(u-c)/d,p=bc(([,,g])=>g).right(o,h);if(p===o.length)return e.every(Sl(c/Ni,u/Ni,d));if(p===0)return oo.every(Math.max(Sl(c,u,d),1));const[m,f]=o[h/o[p-1][2]<o[p][2]/h?p-1:p];return m.every(f)}return[i,l]}const[qS,JS]=Ef(ur,$c,Wo,Vf,Ic,Ec),[WS,KS]=Ef(cr,Mc,Jo,os,_c,Vc);function Fi(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 Bi(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 ha(e,t,r){return{y:e,m:t,d:r,H:0,M:0,S:0,L:0}}function YS(e){var t=e.dateTime,r=e.date,n=e.time,a=e.periods,s=e.days,o=e.shortDays,i=e.months,l=e.shortMonths,c=pa(a),u=fa(a),d=pa(s),h=fa(s),p=pa(o),m=fa(o),f=pa(i),g=fa(i),S=pa(l),T=fa(l),O={a:oe,A:Z,b:se,B:ge,c:null,d:Cd,e:Cd,f:v1,g:V1,G:_1,H:g1,I:y1,j:b1,L:_f,m:x1,M:S1,p:ue,q:De,Q:Td,s:Ad,S:O1,u:w1,U:C1,V:P1,w:R1,W:T1,x:null,X:null,y:A1,Y:E1,Z:I1,"%":Rd},C={a:ct,A:It,b:tt,B:St,c:null,d:Pd,e:Pd,f:k1,g:q1,G:W1,H:M1,I:$1,j:j1,L:Mf,m:L1,M:U1,p:pt,q:rt,Q:Td,s:Ad,S:D1,u:N1,U:F1,V:B1,w:z1,W:G1,x:null,X:null,y:H1,Y:J1,Z:K1,"%":Rd},V={a:y,A,b:z,B:I,c:G,d:Od,e:Od,f:h1,g:Sd,G:xd,H:wd,I:wd,j:l1,L:d1,m:i1,M:c1,p:B,q:o1,Q:f1,s:m1,S:u1,u:t1,U:r1,V:n1,w:e1,W:a1,x:re,X:te,y:Sd,Y:xd,Z:s1,"%":p1};O.x=R(r,O),O.X=R(n,O),O.c=R(t,O),C.x=R(r,C),C.X=R(n,C),C.c=R(t,C);function R(X,ie){return function(he){var J=[],Oe=-1,be=0,Ne=X.length,ke,_e,Mt;for(he instanceof Date||(he=new Date(+he));++Oe<Ne;)X.charCodeAt(Oe)===37&&(J.push(X.slice(be,Oe)),(_e=vd[ke=X.charAt(++Oe)])!=null?ke=X.charAt(++Oe):_e=ke==="e"?" ":"0",(Mt=ie[ke])&&(ke=Mt(he,_e)),J.push(ke),be=Oe+1);return J.push(X.slice(be,Oe)),J.join("")}}function P(X,ie){return function(he){var J=ha(1900,void 0,1),Oe=E(J,X,he+="",0),be,Ne;if(Oe!=he.length)return null;if("Q"in J)return new Date(J.Q);if("s"in J)return new Date(J.s*1e3+("L"in J?J.L:0));if(ie&&!("Z"in J)&&(J.Z=0),"p"in J&&(J.H=J.H%12+J.p*12),J.m===void 0&&(J.m="q"in J?J.q:0),"V"in J){if(J.V<1||J.V>53)return null;"w"in J||(J.w=1),"Z"in J?(be=Bi(ha(J.y,0,1)),Ne=be.getUTCDay(),be=Ne>4||Ne===0?lo.ceil(be):lo(be),be=qo.offset(be,(J.V-1)*7),J.y=be.getUTCFullYear(),J.m=be.getUTCMonth(),J.d=be.getUTCDate()+(J.w+6)%7):(be=Fi(ha(J.y,0,1)),Ne=be.getDay(),be=Ne>4||Ne===0?io.ceil(be):io(be),be=os.offset(be,(J.V-1)*7),J.y=be.getFullYear(),J.m=be.getMonth(),J.d=be.getDate()+(J.w+6)%7)}else("W"in J||"U"in J)&&("w"in J||(J.w="u"in J?J.u%7:"W"in J?1:0),Ne="Z"in J?Bi(ha(J.y,0,1)).getUTCDay():Fi(ha(J.y,0,1)).getDay(),J.m=0,J.d="W"in J?(J.w+6)%7+J.W*7-(Ne+5)%7:J.w+J.U*7-(Ne+6)%7);return"Z"in J?(J.H+=J.Z/100|0,J.M+=J.Z%100,Bi(J)):Fi(J)}}function E(X,ie,he,J){for(var Oe=0,be=ie.length,Ne=he.length,ke,_e;Oe<be;){if(J>=Ne)return-1;if(ke=ie.charCodeAt(Oe++),ke===37){if(ke=ie.charAt(Oe++),_e=V[ke in vd?ie.charAt(Oe++):ke],!_e||(J=_e(X,he,J))<0)return-1}else if(ke!=he.charCodeAt(J++))return-1}return J}function B(X,ie,he){var J=c.exec(ie.slice(he));return J?(X.p=u.get(J[0].toLowerCase()),he+J[0].length):-1}function y(X,ie,he){var J=p.exec(ie.slice(he));return J?(X.w=m.get(J[0].toLowerCase()),he+J[0].length):-1}function A(X,ie,he){var J=d.exec(ie.slice(he));return J?(X.w=h.get(J[0].toLowerCase()),he+J[0].length):-1}function z(X,ie,he){var J=S.exec(ie.slice(he));return J?(X.m=T.get(J[0].toLowerCase()),he+J[0].length):-1}function I(X,ie,he){var J=f.exec(ie.slice(he));return J?(X.m=g.get(J[0].toLowerCase()),he+J[0].length):-1}function G(X,ie,he){return E(X,t,ie,he)}function re(X,ie,he){return E(X,r,ie,he)}function te(X,ie,he){return E(X,n,ie,he)}function oe(X){return o[X.getDay()]}function Z(X){return s[X.getDay()]}function se(X){return l[X.getMonth()]}function ge(X){return i[X.getMonth()]}function ue(X){return a[+(X.getHours()>=12)]}function De(X){return 1+~~(X.getMonth()/3)}function ct(X){return o[X.getUTCDay()]}function It(X){return s[X.getUTCDay()]}function tt(X){return l[X.getUTCMonth()]}function St(X){return i[X.getUTCMonth()]}function pt(X){return a[+(X.getUTCHours()>=12)]}function rt(X){return 1+~~(X.getUTCMonth()/3)}return{format:function(X){var ie=R(X+="",O);return ie.toString=function(){return X},ie},parse:function(X){var ie=P(X+="",!1);return ie.toString=function(){return X},ie},utcFormat:function(X){var ie=R(X+="",C);return ie.toString=function(){return X},ie},utcParse:function(X){var ie=P(X+="",!0);return ie.toString=function(){return X},ie}}}var vd={"-":"",_:" ",0:"0"},nt=/^\s*\d+/,QS=/^%/,XS=/[\\^$*+?|[\]().{}]/g;function we(e,t,r){var n=e<0?"-":"",a=(n?-e:e)+"",s=a.length;return n+(s<r?new Array(r-s+1).join(t)+a:a)}function ZS(e){return e.replace(XS,"\\$&")}function pa(e){return new RegExp("^(?:"+e.map(ZS).join("|")+")","i")}function fa(e){return new Map(e.map((t,r)=>[t.toLowerCase(),r]))}function e1(e,t,r){var n=nt.exec(t.slice(r,r+1));return n?(e.w=+n[0],r+n[0].length):-1}function t1(e,t,r){var n=nt.exec(t.slice(r,r+1));return n?(e.u=+n[0],r+n[0].length):-1}function r1(e,t,r){var n=nt.exec(t.slice(r,r+2));return n?(e.U=+n[0],r+n[0].length):-1}function n1(e,t,r){var n=nt.exec(t.slice(r,r+2));return n?(e.V=+n[0],r+n[0].length):-1}function a1(e,t,r){var n=nt.exec(t.slice(r,r+2));return n?(e.W=+n[0],r+n[0].length):-1}function xd(e,t,r){var n=nt.exec(t.slice(r,r+4));return n?(e.y=+n[0],r+n[0].length):-1}function Sd(e,t,r){var n=nt.exec(t.slice(r,r+2));return n?(e.y=+n[0]+(+n[0]>68?1900:2e3),r+n[0].length):-1}function s1(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 o1(e,t,r){var n=nt.exec(t.slice(r,r+1));return n?(e.q=n[0]*3-3,r+n[0].length):-1}function i1(e,t,r){var n=nt.exec(t.slice(r,r+2));return n?(e.m=n[0]-1,r+n[0].length):-1}function Od(e,t,r){var n=nt.exec(t.slice(r,r+2));return n?(e.d=+n[0],r+n[0].length):-1}function l1(e,t,r){var n=nt.exec(t.slice(r,r+3));return n?(e.m=0,e.d=+n[0],r+n[0].length):-1}function wd(e,t,r){var n=nt.exec(t.slice(r,r+2));return n?(e.H=+n[0],r+n[0].length):-1}function c1(e,t,r){var n=nt.exec(t.slice(r,r+2));return n?(e.M=+n[0],r+n[0].length):-1}function u1(e,t,r){var n=nt.exec(t.slice(r,r+2));return n?(e.S=+n[0],r+n[0].length):-1}function d1(e,t,r){var n=nt.exec(t.slice(r,r+3));return n?(e.L=+n[0],r+n[0].length):-1}function h1(e,t,r){var n=nt.exec(t.slice(r,r+6));return n?(e.L=Math.floor(n[0]/1e3),r+n[0].length):-1}function p1(e,t,r){var n=QS.exec(t.slice(r,r+1));return n?r+n[0].length:-1}function f1(e,t,r){var n=nt.exec(t.slice(r));return n?(e.Q=+n[0],r+n[0].length):-1}function m1(e,t,r){var n=nt.exec(t.slice(r));return n?(e.s=+n[0],r+n[0].length):-1}function Cd(e,t){return we(e.getDate(),t,2)}function g1(e,t){return we(e.getHours(),t,2)}function y1(e,t){return we(e.getHours()%12||12,t,2)}function b1(e,t){return we(1+os.count(cr(e),e),t,3)}function _f(e,t){return we(e.getMilliseconds(),t,3)}function v1(e,t){return _f(e,t)+"000"}function x1(e,t){return we(e.getMonth()+1,t,2)}function S1(e,t){return we(e.getMinutes(),t,2)}function O1(e,t){return we(e.getSeconds(),t,2)}function w1(e){var t=e.getDay();return t===0?7:t}function C1(e,t){return we(Jo.count(cr(e)-1,e),t,2)}function If(e){var t=e.getDay();return t>=4||t===0?Nn(e):Nn.ceil(e)}function P1(e,t){return e=If(e),we(Nn.count(cr(e),e)+(cr(e).getDay()===4),t,2)}function R1(e){return e.getDay()}function T1(e,t){return we(io.count(cr(e)-1,e),t,2)}function A1(e,t){return we(e.getFullYear()%100,t,2)}function V1(e,t){return e=If(e),we(e.getFullYear()%100,t,2)}function E1(e,t){return we(e.getFullYear()%1e4,t,4)}function _1(e,t){var r=e.getDay();return e=r>=4||r===0?Nn(e):Nn.ceil(e),we(e.getFullYear()%1e4,t,4)}function I1(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+we(t/60|0,"0",2)+we(t%60,"0",2)}function Pd(e,t){return we(e.getUTCDate(),t,2)}function M1(e,t){return we(e.getUTCHours(),t,2)}function $1(e,t){return we(e.getUTCHours()%12||12,t,2)}function j1(e,t){return we(1+qo.count(ur(e),e),t,3)}function Mf(e,t){return we(e.getUTCMilliseconds(),t,3)}function k1(e,t){return Mf(e,t)+"000"}function L1(e,t){return we(e.getUTCMonth()+1,t,2)}function U1(e,t){return we(e.getUTCMinutes(),t,2)}function D1(e,t){return we(e.getUTCSeconds(),t,2)}function N1(e){var t=e.getUTCDay();return t===0?7:t}function F1(e,t){return we(Wo.count(ur(e)-1,e),t,2)}function $f(e){var t=e.getUTCDay();return t>=4||t===0?Fn(e):Fn.ceil(e)}function B1(e,t){return e=$f(e),we(Fn.count(ur(e),e)+(ur(e).getUTCDay()===4),t,2)}function z1(e){return e.getUTCDay()}function G1(e,t){return we(lo.count(ur(e)-1,e),t,2)}function H1(e,t){return we(e.getUTCFullYear()%100,t,2)}function q1(e,t){return e=$f(e),we(e.getUTCFullYear()%100,t,2)}function J1(e,t){return we(e.getUTCFullYear()%1e4,t,4)}function W1(e,t){var r=e.getUTCDay();return e=r>=4||r===0?Fn(e):Fn.ceil(e),we(e.getUTCFullYear()%1e4,t,4)}function K1(){return"+0000"}function Rd(){return"%"}function Td(e){return+e}function Ad(e){return Math.floor(+e/1e3)}var bn,jf,kf;Y1({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 Y1(e){return bn=YS(e),jf=bn.format,bn.parse,kf=bn.utcFormat,bn.utcParse,bn}function Q1(e){return new Date(e)}function X1(e){return e instanceof Date?+e:+new Date(+e)}function jc(e,t,r,n,a,s,o,i,l,c){var u=Of(),d=u.invert,h=u.domain,p=c(".%L"),m=c(":%S"),f=c("%I:%M"),g=c("%I %p"),S=c("%a %d"),T=c("%b %d"),O=c("%B"),C=c("%Y");function V(R){return(l(R)<R?p:i(R)<R?m:o(R)<R?f:s(R)<R?g:n(R)<R?a(R)<R?S:T:r(R)<R?O:C)(R)}return u.invert=function(R){return new Date(d(R))},u.domain=function(R){return arguments.length?h(Array.from(R,X1)):h().map(Q1)},u.ticks=function(R){var P=h();return e(P[0],P[P.length-1],R??10)},u.tickFormat=function(R,P){return P==null?V:c(P)},u.nice=function(R){var P=h();return(!R||typeof R.range!="function")&&(R=t(P[0],P[P.length-1],R??10)),R?h(Rf(P,R)):u},u.copy=function(){return Ho(u,jc(e,t,r,n,a,s,o,i,l,c))},u}function Lf(){return Vr.apply(jc(WS,KS,cr,Mc,Jo,os,_c,Vc,Ur,jf).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function Z1(){return Vr.apply(jc(qS,JS,ur,$c,Wo,qo,Ic,Ec,Ur,kf).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function eO(){var e=0,t=1,r,n,a,s,o=At,i=!1,l;function c(d){return d==null||isNaN(d=+d)?l:o(a===0?.5:(d=(s(d)-r)*a,i?Math.max(0,Math.min(1,d)):d))}c.domain=function(d){return arguments.length?([e,t]=d,r=s(e=+e),n=s(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?(o=d,c):o};function u(d){return function(h){var p,m;return arguments.length?([p,m]=h,o=d(p,m),c):[o(0),o(1)]}}return c.range=u(Go),c.rangeRound=u(Sf),c.unknown=function(d){return arguments.length?(l=d,c):l},function(d){return s=d,r=d(e),n=d(t),a=r===n?0:1/(n-r),c}}function tO(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function Uf(){var e=Rc(eO()(At));return e.copy=function(){return tO(e,Uf())},Fx.apply(e,arguments)}function rO(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 nO(e){return e.scaleType==="band"}function aO(e){return e.scaleType==="point"}function sO(e){return e.type==="piecewise"?Af(e.thresholds,e.colors):Uf([e.min??0,e.max??100],e.color)}function co(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 Gs(e){return e.type==="ordinal"?co(e):sO(e)}function oO(e){const{tickMaxStep:t,tickMinStep:r,tickNumber:n,range:a,domain:s}=e,o=r===void 0?999:Math.floor(Math.abs(s[1]-s[0])/r),i=t===void 0?2:Math.ceil(Math.abs(s[1]-s[0])/t),l=n??Math.floor(Math.abs(a[1]-a[0])/50);return Math.min(o,Math.max(i,l))}function iO(e,t){return t[1]-t[0]===0?1:e/((t[1]-t[0])/100)}function Pl(e,t,r){switch(e){case"log":return Tf(t,r);case"pow":return Tc(t,r);case"sqrt":return LS(t,r);case"time":return Lf(t,r);case"utc":return Z1(t,r);default:return Pf(t,r)}}const Vd=e=>(e==null?void 0:e[0])instanceof Date;function Ed(e,t){const r=Lf(e.data,t);return(n,{location:a})=>a==="tick"?r.tickFormat(e.tickNumber)(n):`${n.toLocaleString()}`}const zi=(e,t)=>{const r=e[1]-e[0],n=t[1]-t[0],a=e[0]-t[0]*r/n,s=e[1]+(100-t[1])*r/n;return[a,s]};let _d,Id;class lO{constructor(){if(this.types=new Set,_d)throw new Error("You can only create one instance!");_d=this.types}addType(t){this.types.add(t)}getTypes(){return this.types}}class cO{constructor(){if(this.types=new Set,Id)throw new Error("You can only create one instance!");Id=this.types}addType(t){this.types.add(t)}getTypes(){return this.types}}const Ko=new lO;Ko.addType("bar");Ko.addType("line");Ko.addType("scatter");const uO=new cO;uO.addType("radar");function Df(e){return Ko.getTypes().has(e)}const dO=(e,t,r,n,a,s,o,i)=>{var m;const l=n==="x"?a[t].xExtremumGetter:a[t].yExtremumGetter,c=((m=o[t])==null?void 0:m.series)??{},[u,d]=(l==null?void 0:l({series:c,axis:r,axisIndex:s,isDefaultAxis:s===0,getFilters:i}))??[1/0,-1/0],[h,p]=e;return[Math.min(u,h),Math.max(d,p)]},Nf=(e,t,r,n,a,s)=>{const i=Object.keys(r).filter(Df).reduce((l,c)=>dO(l,c,e,t,r,n,a,s),[1/0,-1/0]);return Number.isNaN(i[0])||Number.isNaN(i[1])?[1/0,-1/0]:i},hO=(e,t,r,n)=>{const a=new Set;return Object.keys(t).filter(Df).forEach(o=>{var c,u,d;const i=((c=r[o])==null?void 0:c.series)??{},l=(d=(u=t[o]).axisTooltipGetter)==null?void 0:d.call(u,i);l!==void 0&&l.forEach(({axisId:h,direction:p})=>{p===e&&a.add(h??n)})}),a},pO=(e,t,r,n)=>{var a;if(e.domainLimit!==void 0)return e.domainLimit;if(t==="x")for(const s of((a=n.line)==null?void 0:a.seriesOrder)??[]){const o=n.line.series[s];if(o.xAxisId===e.id||o.xAxisId===void 0&&r===0)return"strict"}return"nice"};function fO(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 mO=.2,gO=.1;function Ff({drawingArea:e,formattedSeries:t,axis:r,seriesConfig:n,axisDirection:a,zoomMap:s,zoomOptions:o,getFilters:i,preferStrictDomainInLineCharts:l}){if(r===void 0)return{axis:{},axisIds:[]};const c=hO(a,n,t,r[0].id),u={};return r.forEach((d,h)=>{const p=d,m=o==null?void 0:o[p.id],f=s==null?void 0:s.get(p.id),g=f?[f.start,f.end]:[0,100],S=fO(e,a,p),[T,O]=Nf(p,a,n,h,t,f===void 0&&!m?i:void 0),C=!p.ignoreTooltip&&c.has(p.id),V=p.data??[];if(nO(p)){const oe=p.categoryGapRatio??mO,Z=p.barGapRatio??gO,se=a==="y"?[S[1],S[0]]:S,ge=zi(se,g);if(u[p.id]=K({offset:0,height:0,categoryGapRatio:oe,barGapRatio:Z,triggerTooltip:C},p,{data:V,scale:vc(p.data,ge).paddingInner(oe).paddingOuter(oe/2),tickNumber:p.data.length,colorScale:p.colorMap&&(p.colorMap.type==="ordinal"?co(K({values:p.data},p.colorMap)):Gs(p.colorMap))}),Vd(p.data)){const ue=Ed(p,se);u[p.id].valueFormatter=p.valueFormatter??ue}}if(aO(p)){const oe=a==="y"?[...S].reverse():S,Z=zi(oe,g);if(u[p.id]=K({offset:0,height:0,triggerTooltip:C},p,{data:V,scale:Bx(p.data,Z),tickNumber:p.data.length,colorScale:p.colorMap&&(p.colorMap.type==="ordinal"?co(K({values:p.data},p.colorMap)):Gs(p.colorMap))}),Vd(p.data)){const se=Ed(p,oe);u[p.id].valueFormatter=p.valueFormatter??se}}if(p.scaleType==="band"||p.scaleType==="point")return;const R=p.scaleType??"linear",P=l?pO(p,a,h,t):p.domainLimit??"nice",E=[p.min??T,p.max??O];if(typeof P=="function"){const{min:oe,max:Z}=P(T,O);E[0]=oe,E[1]=Z}const B=oO(K({},p,{range:S,domain:E})),y=iO(B,g),A=zi(S,g),z=Pl(R,E,A),I=P==="nice"?z.nice(B):z,[G,re]=I.domain(),te=[p.min??G,p.max??re];u[p.id]=K({offset:0,height:0,triggerTooltip:C},p,{data:V,scaleType:R,scale:I.domain(te),tickNumber:y,colorScale:p.colorMap&&Gs(p.colorMap),valueFormatter:p.valueFormatter??rO(y,Pl(R,S.map(oe=>z.invert(oe)),S))})}),{axis:u,axisIds:r.map(({id:d})=>d)}}function yO(e){return e!=null}function Bf({zoomMap:e,zoomOptions:t,seriesConfig:r,formattedSeries:n,direction:a}){return(s,o)=>{var g;const i=t[s.id];if(!i||i.filterMode!=="discard")return null;const l=e==null?void 0:e.get(s.id);if(l===void 0||l.start<=0&&l.end>=100)return null;let c=[];const u=s.scaleType;u==="point"||u==="band"?c=[0,(((g=s.data)==null?void 0:g.length)??1)-1]:c=Nf(s,a,r,o,n);let d,h;[d,h]=Pl(!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 m=d+l.start*(h-d)/100,f=d+l.end*(h-d)/100;return(S,T)=>{var C;const O=S[a]??((C=s.data)==null?void 0:C[T]);return O==null?!0:s.scaleType==="point"||s.scaleType==="band"||typeof O=="string"?T>=m&&T<=f:O>=m&&O<=f}}}const bO=e=>({currentAxisId:t,seriesXAxisId:r,seriesYAxisId:n,isDefaultAxis:a})=>(s,o)=>{var c,u;return!(t===r?n:r)||a?((u=(c=Object.values(e??{}))[0])==null?void 0:u.call(c,s,o))??!0:[n,r].filter(d=>d!==t).map(d=>e[d??""]).filter(yO).every(d=>d(s,o))},Md=e=>(t=[])=>t.reduce((r,n)=>{const{zoom:a,id:s}=n,o=yc(a,s,e);return o&&(r[s]=o),r},{}),vO=e=>{const t=new Map;return e.forEach(r=>{t.set(r.axisId,r)}),t},zf=e=>e.zoom;ye([zf],e=>e==null?void 0:e.isInteracting);const Yo=ye([zf],e=>(e==null?void 0:e.zoomData)&&vO(e==null?void 0:e.zoomData)),is=ye([Jn,Wn],(e,t)=>K({},Md("x")(e),Md("y")(t)));ye([is,(e,t)=>t],(e,t)=>e[t]);const xO=ye([Yo,is,zo,ns],(e,t,r,n)=>e&&t&&Bf({zoomMap:e,zoomOptions:t,seriesConfig:r,formattedSeries:n,direction:"x"})),SO=ye([Yo,is,zo,ns],(e,t,r,n)=>e&&t&&Bf({zoomMap:e,zoomOptions:t,seriesConfig:r,formattedSeries:n,direction:"y"})),Gf=ye([xO,SO,Jn,Wn],(e,t,r,n)=>{if(e===void 0||t===void 0)return;const a=r==null?void 0:r.reduce((o,i,l)=>{const c=e(i,l);return c!==null&&(o[i.id]=c),o},{}),s=n==null?void 0:n.reduce((o,i,l)=>{const c=t(i,l);return c!==null&&(o[i.id]=c),o},{});if(!(Object.keys(a??{}).length===0&&Object.keys(s??{}).length===0))return bO(K({},a,s))}),Qr=ye([Jn,rs,ns,zo,Yo,is,Gf,sf],(e,t,r,n,a,s,o,i)=>Ff({drawingArea:t,formattedSeries:r,axis:e,seriesConfig:n,axisDirection:"x",zoomMap:a,zoomOptions:s,getFilters:o,preferStrictDomainInLineCharts:i})),Xr=ye([Wn,rs,ns,zo,Yo,is,Gf,sf],(e,t,r,n,a,s,o,i)=>Ff({drawingArea:t,formattedSeries:r,axis:e,seriesConfig:n,axisDirection:"y",zoomMap:a,zoomOptions:s,getFilters:o,preferStrictDomainInLineCharts:i}));ye([Qr,Xr,(e,t)=>t],(e,t,r)=>(e==null?void 0:e.axis[r])??(t==null?void 0:t.axis[r]));ye([Jn,Wn,(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 Hf(e){return e.bandwidth!==void 0}function vn(e){return e instanceof Date?e.getTime():e}function Bn(e,t){const{scale:r,data:n,reverse:a}=e;if(!Hf(r)){const o=r.invert(t);if(n===void 0)return-1;const i=vn(o);return n==null?void 0:n.findIndex((c,u)=>{const d=vn(c);return d>i&&(u===0||Math.abs(i-d)<=Math.abs(i-vn(n[u-1])))||d<=i&&(u===n.length-1||Math.abs(vn(o)-d)<Math.abs(vn(o)-vn(n[u+1])))})}const s=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 s<0||s>=n.length?-1:a?n.length-1-s:s}function $d(e,t,r){const{scale:n,data:a}=e;if(!Hf(n)){const s=n.invert(t);return r<0?s:a[r]}return r<0||r>=a.length?null:a[r]}function jd(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=F.useRef(e);return or(()=>{t.current=e}),F.useRef((...r)=>(0,t.current)(...r)).current}const OO=Object.is;function qf(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,!OO(e[a],t[a])||!(a in t))return!1;for(const a in t)n+=1;return r===n}const kc=({store:e})=>{const t=En(function(){e.update(o=>K({},o,{interaction:{pointer:null,item:null}}))}),r=En(function(o){e.update(i=>{const l=i.interaction.item;return o?l===null||Object.keys(o).some(c=>o[c]!==l[c])?i:K({},i,{interaction:K({},i.interaction,{item:null})}):l===null?i:K({},i,{interaction:K({},i.interaction,{item:null})})})}),n=En(function(o){e.update(i=>qf(i.interaction.item,o)?i:K({},i,{interaction:K({},i.interaction,{item:o})}))}),a=En(function(o){e.update(i=>K({},i,{interaction:K({},i.interaction,{pointer:o})}))});return{instance:{cleanInteraction:t,setItemInteraction:n,removeItemInteraction:r,setPointerCoordinate:a}}};kc.getInitialState=()=>({interaction:{item:null,pointer:null}});kc.params={};const Lc=e=>e.interaction,wO=ye([Lc],e=>e!==void 0),CO=ye([Lc],e=>(e==null?void 0:e.item)??null),Jf=ye([Lc],e=>(e==null?void 0:e.pointer)??null),Qo=ye([Jf],e=>e&&e.x),Xo=ye([Jf],e=>e&&e.y);ye([CO],e=>e!==null);function Ia(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 s=0;s<a;s+=1)if(!Ia(e[s],t[s]))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 s=0;s<a.length;s+=1)if(!t.has(a[s][0]))return!1;for(let s=0;s<a.length;s+=1){const o=a[s];if(!Ia(o[1],t.get(o[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 s=0;s<a.length;s+=1)if(!t.has(a[s][0]))return!1;return!0}if(ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){const a=e.length;if(a!==t.length)return!1;for(let s=0;s<a;s+=1)if(e[s]!==t[s])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 s=r[a];if(!Ia(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}const Zo=(e,t)=>t;function Rl(e,t,r=t.axisIds[0]){return Array.isArray(r)?r.map(n=>Bn(t.axis[n],e)):Bn(t.axis[r],e)}const Wf=(e,t,r)=>{if(e===null)return null;const n=Rl(e,t,r);return n===-1?null:n},PO=ye([Qo,Qr,Zo],Wf),RO=ye([Xo,Xr,Zo],Wf),TO=ye([Qo,Xo,Qr,Xr],(e,t,r,n)=>[...e===null?[]:r.axisIds.map(a=>({axisId:a,dataIndex:Rl(e,r,a)})),...t===null?[]:n.axisIds.map(a=>({axisId:a,dataIndex:Rl(t,n,a)}))].filter(a=>a.dataIndex!==null&&a.dataIndex>=0));function Kf(e,t,r,n=t.axisIds[0]){return Array.isArray(n)?n.map((a,s)=>$d(t.axis[a],e,r[s])):$d(t.axis[n],e,r)}ye([Qo,Qr,PO,Zo],(e,t,r,n)=>e===null||r===null||t.axisIds.length===0?null:Kf(e,t,r,n));ye([Xo,Xr,RO,Zo],(e,t,r,n)=>e===null||r===null||t.axisIds.length===0?null:Kf(e,t,r,n));const AO=ye([Qo,Qr],(e,t)=>e===null?[]:t.axisIds.filter(r=>t.axis[r].triggerTooltip).map(r=>({axisId:r,dataIndex:Bn(t.axis[r],e)})).filter(({dataIndex:r})=>r>=0),{memoizeOptions:{resultEqualityCheck:Ia}}),VO=ye([Xo,Xr],(e,t)=>e===null?[]:t.axisIds.filter(r=>t.axis[r].triggerTooltip).map(r=>({axisId:r,dataIndex:Bn(t.axis[r],e)})).filter(({dataIndex:r})=>r>=0),{memoizeOptions:{resultEqualityCheck:Ia}});ye([AO,VO],(e,t)=>e.length>0||t.length>0);const kd={};function EO(e,t){const r=F.useRef(kd);return r.current===kd&&(r.current=e(t)),r}const _O=()=>{};function IO(e,t,r,n){const a=EO(MO,{store:e,selector:t,skip:n}).current;a.effect=r,F.useEffect(a.onMount(n),[n])}function MO(e){const{store:t,selector:r,skip:n}=e;let a=!1,s;const o=()=>{i.dispose??(i.dispose=t.subscribe(l=>{const c=r(l);i.effect(s,c),s=c}))},i={effect:_O,dispose:null,onMount:l=>()=>{if(!l)return a||(a=!0,s=r(t.value)),o(),()=>{var c;(c=i.dispose)==null||c.call(i),i.dispose=null}}};return n||(a=!0,s=r(t.value),o()),i}const ei=({params:e,store:t,seriesConfig:r,svgRef:n,instance:a})=>{const{xAxis:s,yAxis:o,dataset:i,onHighlightedAxisChange:l}=e;if(process.env.NODE_ENV!=="production"){const O=[...s??[],...o??[]].filter(V=>V.id).map(V=>V.id),C=new Set(O.filter((V,R)=>O.indexOf(V)!==R));C.size>0&&Da([`MUI X Charts: The following axis ids are duplicated: ${Array.from(C).join(", ")}.`,"Please make sure that each axis has a unique id."].join(`
|
|
127
|
+
`),"error")}const c=bt(t,rs),u=bt(t,ns),d=bt(t,wO),{axis:h,axisIds:p}=bt(t,Qr),{axis:m,axisIds:f}=bt(t,Xr);df({warningPrefix:"MUI X Charts",componentName:"Chart",propName:"highlightedAxis",controlled:e.highlightedAxis,defaultValue:void 0}),or(()=>{e.highlightedAxis!==void 0&&t.update(O=>O.controlledCartesianAxisHighlight===e.highlightedAxis?O:K({},O,{controlledCartesianAxisHighlight:e.highlightedAxis}))},[t,e.highlightedAxis]);const g=F.useRef(!0);F.useEffect(()=>{if(g.current){g.current=!1;return}t.update(O=>K({},O,{cartesianAxis:K({},O.cartesianAxis,{x:ff(s,i),y:mf(o,i)})}))},[r,c,s,o,i,t]);const S=p[0],T=f[0];return IO(t,TO,(O,C)=>{if(!Object.is(O,C)){if(O.length!==C.length){l(C);return}O!=null&&O.some(({axisId:V,dataIndex:R},P)=>C[P].axisId!==V||C[P].dataIndex!==R)&&l(C)}},!l),F.useEffect(()=>{const O=n.current;if(!d||!O||e.disableAxisListener)return()=>{};const C=a.addInteractionListener("moveEnd",A=>{var z;A.detail.activeGestures.pan||(z=a.cleanInteraction)==null||z.call(a)}),V=a.addInteractionListener("panEnd",A=>{var z;A.detail.activeGestures.move||(z=a.cleanInteraction)==null||z.call(a)}),R=a.addInteractionListener("quickPressEnd",A=>{var z;!A.detail.activeGestures.move&&!A.detail.activeGestures.pan&&((z=a.cleanInteraction)==null||z.call(a))}),P=A=>{var re,te;const z=A.detail.srcEvent,I=A.detail.target,G=jd(O,z);if(A.detail.srcEvent.buttons>=1&&(I!=null&&I.hasPointerCapture(A.detail.srcEvent.pointerId))&&!(I!=null&&I.closest("[data-charts-zoom-slider]"))&&(I==null||I.releasePointerCapture(A.detail.srcEvent.pointerId)),!a.isPointInside(G.x,G.y,I)){(re=a.cleanInteraction)==null||re.call(a);return}(te=a.setPointerCoordinate)==null||te.call(a,G)},E=a.addInteractionListener("move",P),B=a.addInteractionListener("pan",P),y=a.addInteractionListener("quickPress",P);return()=>{E.cleanup(),C.cleanup(),B.cleanup(),V.cleanup(),y.cleanup(),R.cleanup()}},[n,t,h,S,m,T,a,e.disableAxisListener,d]),F.useEffect(()=>{const O=n.current,C=e.onAxisClick;if(O===null||!C)return()=>{};const V=a.addInteractionListener("tap",R=>{let P=null,E=!1;const B=jd(O,R.detail.srcEvent),y=Bn(h[S],B.x);E=y!==-1,P=E?y:Bn(m[T],B.y);const A=E?p[0]:f[0];if(P==null||P===-1)return;const z=(E?h:m)[A].data[P],I={};Object.keys(u).filter(G=>["bar","line"].includes(G)).forEach(G=>{var re;(re=u[G])==null||re.seriesOrder.forEach(te=>{const oe=u[G].series[te],Z=oe.xAxisId,se=oe.yAxisId,ge=E?Z:se;(ge===void 0||ge===A)&&(I[te]=oe.data[P])})}),C(R.detail.srcEvent,{dataIndex:P,axisValue:z,seriesValues:I})});return()=>{V.cleanup()}},[e.onAxisClick,u,n,h,p,m,f,S,T,a]),{}};ei.params={xAxis:!0,yAxis:!0,dataset:!0,onAxisClick:!0,disableAxisListener:!0,onHighlightedAxisChange:!0,highlightedAxis:!0};ei.getDefaultizedParams=({params:e})=>K({},e,{colors:e.colors??of,theme:e.theme??"light",defaultizedXAxis:ff(e.xAxis,e.dataset),defaultizedYAxis:mf(e.yAxis,e.dataset)});ei.getInitialState=e=>K({cartesianAxis:{x:e.defaultizedXAxis,y:e.defaultizedYAxis}},e.highlightedAxis===void 0?{}:{controlledCartesianAxisHighlight:e.highlightedAxis});function Ld(e,t){return e.id!==void 0?e:K({id:t},e)}function Ud(e){return e.colorMap?K({},e,{colorScale:e.colorMap.type==="ordinal"&&e.data?co(K({values:e.data},e.colorMap)):Gs(e.colorMap.type==="continuous"?K({min:e.min,max:e.max},e.colorMap):e.colorMap)}):e}function Yf(e,t){if(!e||e.length===0)return{axis:{},axisIds:[]};const r={},n=[];return e.forEach((a,s)=>{const o=a.dataKey,i=a.id??`defaultized-z-axis-${s}`;if(o===void 0||a.data!==void 0){r[i]=Ud(Ld(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]=Ud(Ld(K({},a,{data:t.map(l=>l[o])}),i)),n.push(i)}),{axis:r,axisIds:n}}const Uc=({params:e,store:t})=>{const{zAxis:r,dataset:n}=e,a=F.useRef(!0);return F.useEffect(()=>{if(a.current){a.current=!1;return}t.update(s=>K({},s,{zAxis:Yf(r,n)}))},[r,n,t]),{}};Uc.params={zAxis:!0,dataset:!0};Uc.getInitialState=e=>({zAxis:Yf(e.zAxis,e.dataset)});const $O=e=>e,jO=ye([$O],e=>e.zAxis),ti=({store:e,params:t})=>{df({warningPrefix:"MUI X Charts",componentName:"Chart",propName:"highlightedItem",controlled:t.highlightedItem,defaultValue:null}),or(()=>{e.update(a=>a.highlight.item===t.highlightedItem?a:K({},a,{highlight:K({},a.highlight,{item:t.highlightedItem})}))},[e,t.highlightedItem]);const r=En(()=>{var a;(a=t.onHighlightChange)==null||a.call(t,null),e.update(s=>K({},s,{highlight:{item:null}}))}),n=En(a=>{var o;const s=e.getSnapshot().highlight.item;qf(s,a)||((o=t.onHighlightChange)==null||o.call(t,a),e.update(i=>K({},i,{highlight:{item:a}})))});return{instance:{clearHighlight:r,setHighlight:n}}};ti.getDefaultizedParams=({params:e})=>K({},e,{highlightedItem:e.highlightedItem??null});ti.getInitialState=e=>({highlight:{item:e.highlightedItem}});ti.params={highlightedItem:!0,onHighlightChange:!0};const Dd=(e,t)=>t==="x"?{x:e,y:null}:{x:null,y:e},Qf=e=>{var l;const{axis:t,getFilters:r,isDefaultAxis:n}=e,a=r==null?void 0:r({currentAxisId:t.id,isDefaultAxis:n}),s=a?(l=t.data)==null?void 0:l.filter((c,u)=>a({x:null,y:null},u)):t.data,o=Math.min(...s??[]),i=Math.max(...s??[]);return[o,i]},Xf=e=>t=>{const{series:r,axis:n,getFilters:a,isDefaultAxis:s}=t;return Object.keys(r).filter(o=>{const i=e==="x"?r[o].xAxisId:r[o].yAxisId;return i===n.id||s&&i===void 0}).reduce((o,i)=>{const{stackedData:l}=r[i],c=a==null?void 0:a({currentAxisId:n.id,isDefaultAxis:s,seriesXAxisId:r[i].xAxisId,seriesYAxisId:r[i].yAxisId}),[u,d]=(l==null?void 0:l.reduce((h,p,m)=>c&&(!c(Dd(p[0],e),m)||!c(Dd(p[1],e),m))?h:[Math.min(...p,h[0]),Math.max(...p,h[1])],[1/0,-1/0]))??[1/0,-1/0];return[Math.min(u,o[0]),Math.max(d,o[1])]},[1/0,-1/0])},kO=e=>Object.keys(e.series).some(r=>e.series[r].layout==="horizontal")?Xf("x")(e):Qf(e),LO=e=>Object.keys(e.series).some(r=>e.series[r].layout==="horizontal")?Qf(e):Xf("y")(e);function Ze(e){return function(){return e}}const Nd=Math.abs,ot=Math.atan2,Mr=Math.cos,UO=Math.max,Gi=Math.min,Ht=Math.sin,_n=Math.sqrt,yt=1e-12,Ga=Math.PI,uo=Ga/2,Hs=2*Ga;function DO(e){return e>1?0:e<-1?Ga:Math.acos(e)}function Fd(e){return e>=1?uo:e<=-1?-uo:Math.asin(e)}const Tl=Math.PI,Al=2*Tl,jr=1e-6,NO=Al-jr;function Zf(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=arguments[t]+e[t]}function FO(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return Zf;const r=10**t;return function(n){this._+=n[0];for(let a=1,s=n.length;a<s;++a)this._+=Math.round(arguments[a]*r)/r+n[a]}}class BO{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?Zf:FO(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,s,o){this._append`C${+t},${+r},${+n},${+a},${this._x1=+s},${this._y1=+o}`}arcTo(t,r,n,a,s){if(t=+t,r=+r,n=+n,a=+a,s=+s,s<0)throw new Error(`negative radius: ${s}`);let o=this._x1,i=this._y1,l=n-t,c=a-r,u=o-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>jr)if(!(Math.abs(d*l-c*u)>jr)||!s)this._append`L${this._x1=t},${this._y1=r}`;else{let p=n-o,m=a-i,f=l*l+c*c,g=p*p+m*m,S=Math.sqrt(f),T=Math.sqrt(h),O=s*Math.tan((Tl-Math.acos((f+h-g)/(2*S*T)))/2),C=O/T,V=O/S;Math.abs(C-1)>jr&&this._append`L${t+C*u},${r+C*d}`,this._append`A${s},${s},0,0,${+(d*p>u*m)},${this._x1=t+V*l},${this._y1=r+V*c}`}}arc(t,r,n,a,s,o){if(t=+t,r=+r,n=+n,o=!!o,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^o,h=o?a-s:s-a;this._x1===null?this._append`M${c},${u}`:(Math.abs(this._x1-c)>jr||Math.abs(this._y1-u)>jr)&&this._append`L${c},${u}`,n&&(h<0&&(h=h%Al+Al),h>NO?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>jr&&this._append`A${n},${n},0,${+(h>=Tl)},${d},${this._x1=t+n*Math.cos(s)},${this._y1=r+n*Math.sin(s)}`)}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 zO(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 BO(t)}function GO(e){return e.innerRadius}function HO(e){return e.outerRadius}function qO(e){return e.startAngle}function JO(e){return e.endAngle}function WO(e){return e&&e.padAngle}function KO(e,t,r,n,a,s,o,i){var l=r-e,c=n-t,u=o-a,d=i-s,h=d*l-u*c;if(!(h*h<yt))return h=(u*(t-s)-d*(e-a))/h,[e+h*l,t+h*c]}function ws(e,t,r,n,a,s,o){var i=e-r,l=t-n,c=(o?s:-s)/_n(i*i+l*l),u=c*l,d=-c*i,h=e+u,p=t+d,m=r+u,f=n+d,g=(h+m)/2,S=(p+f)/2,T=m-h,O=f-p,C=T*T+O*O,V=a-s,R=h*f-m*p,P=(O<0?-1:1)*_n(UO(0,V*V*C-R*R)),E=(R*O-T*P)/C,B=(-R*T-O*P)/C,y=(R*O+T*P)/C,A=(-R*T+O*P)/C,z=E-g,I=B-S,G=y-g,re=A-S;return z*z+I*I>G*G+re*re&&(E=y,B=A),{cx:E,cy:B,x01:-u,y01:-d,x11:E*(a/V-1),y11:B*(a/V-1)}}function em(){var e=GO,t=HO,r=Ze(0),n=null,a=qO,s=JO,o=WO,i=null,l=zO(c);function c(){var u,d,h=+e.apply(this,arguments),p=+t.apply(this,arguments),m=a.apply(this,arguments)-uo,f=s.apply(this,arguments)-uo,g=Nd(f-m),S=f>m;if(i||(i=u=l()),p<h&&(d=p,p=h,h=d),!(p>yt))i.moveTo(0,0);else if(g>Hs-yt)i.moveTo(p*Mr(m),p*Ht(m)),i.arc(0,0,p,m,f,!S),h>yt&&(i.moveTo(h*Mr(f),h*Ht(f)),i.arc(0,0,h,f,m,S));else{var T=m,O=f,C=m,V=f,R=g,P=g,E=o.apply(this,arguments)/2,B=E>yt&&(n?+n.apply(this,arguments):_n(h*h+p*p)),y=Gi(Nd(p-h)/2,+r.apply(this,arguments)),A=y,z=y,I,G;if(B>yt){var re=Fd(B/h*Ht(E)),te=Fd(B/p*Ht(E));(R-=re*2)>yt?(re*=S?1:-1,C+=re,V-=re):(R=0,C=V=(m+f)/2),(P-=te*2)>yt?(te*=S?1:-1,T+=te,O-=te):(P=0,T=O=(m+f)/2)}var oe=p*Mr(T),Z=p*Ht(T),se=h*Mr(V),ge=h*Ht(V);if(y>yt){var ue=p*Mr(O),De=p*Ht(O),ct=h*Mr(C),It=h*Ht(C),tt;if(g<Ga)if(tt=KO(oe,Z,ct,It,ue,De,se,ge)){var St=oe-tt[0],pt=Z-tt[1],rt=ue-tt[0],X=De-tt[1],ie=1/Ht(DO((St*rt+pt*X)/(_n(St*St+pt*pt)*_n(rt*rt+X*X)))/2),he=_n(tt[0]*tt[0]+tt[1]*tt[1]);A=Gi(y,(h-he)/(ie-1)),z=Gi(y,(p-he)/(ie+1))}else A=z=0}P>yt?z>yt?(I=ws(ct,It,oe,Z,p,z,S),G=ws(ue,De,se,ge,p,z,S),i.moveTo(I.cx+I.x01,I.cy+I.y01),z<y?i.arc(I.cx,I.cy,z,ot(I.y01,I.x01),ot(G.y01,G.x01),!S):(i.arc(I.cx,I.cy,z,ot(I.y01,I.x01),ot(I.y11,I.x11),!S),i.arc(0,0,p,ot(I.cy+I.y11,I.cx+I.x11),ot(G.cy+G.y11,G.cx+G.x11),!S),i.arc(G.cx,G.cy,z,ot(G.y11,G.x11),ot(G.y01,G.x01),!S))):(i.moveTo(oe,Z),i.arc(0,0,p,T,O,!S)):i.moveTo(oe,Z),!(h>yt)||!(R>yt)?i.lineTo(se,ge):A>yt?(I=ws(se,ge,ue,De,h,-A,S),G=ws(oe,Z,ct,It,h,-A,S),i.lineTo(I.cx+I.x01,I.cy+I.y01),A<y?i.arc(I.cx,I.cy,A,ot(I.y01,I.x01),ot(G.y01,G.x01),!S):(i.arc(I.cx,I.cy,A,ot(I.y01,I.x01),ot(I.y11,I.x11),!S),i.arc(0,0,h,ot(I.cy+I.y11,I.cx+I.x11),ot(G.cy+G.y11,G.cx+G.x11),S),i.arc(G.cx,G.cy,A,ot(G.y11,G.x11),ot(G.y01,G.x01),!S))):i.arc(0,0,h,V,C,S)}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)+ +s.apply(this,arguments))/2-Ga/2;return[Mr(d)*u,Ht(d)*u]},c.innerRadius=function(u){return arguments.length?(e=typeof u=="function"?u:Ze(+u),c):e},c.outerRadius=function(u){return arguments.length?(t=typeof u=="function"?u:Ze(+u),c):t},c.cornerRadius=function(u){return arguments.length?(r=typeof u=="function"?u:Ze(+u),c):r},c.padRadius=function(u){return arguments.length?(n=u==null?null:typeof u=="function"?u:Ze(+u),c):n},c.startAngle=function(u){return arguments.length?(a=typeof u=="function"?u:Ze(+u),c):a},c.endAngle=function(u){return arguments.length?(s=typeof u=="function"?u:Ze(+u),c):s},c.padAngle=function(u){return arguments.length?(o=typeof u=="function"?u:Ze(+u),c):o},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 YO(e,t){return t<e?-1:t>e?1:t>=e?0:NaN}function QO(e){return e}function XO(){var e=QO,t=YO,r=null,n=Ze(0),a=Ze(Hs),s=Ze(0);function o(i){var l,c=(i=tm(i)).length,u,d,h=0,p=new Array(c),m=new Array(c),f=+n.apply(this,arguments),g=Math.min(Hs,Math.max(-Hs,a.apply(this,arguments)-f)),S,T=Math.min(Math.abs(g)/c,s.apply(this,arguments)),O=T*(g<0?-1:1),C;for(l=0;l<c;++l)(C=m[p[l]=l]=+e(i[l],l,i))>0&&(h+=C);for(t!=null?p.sort(function(V,R){return t(m[V],m[R])}):r!=null&&p.sort(function(V,R){return r(i[V],i[R])}),l=0,d=h?(g-c*O)/h:0;l<c;++l,f=S)u=p[l],C=m[u],S=f+(C>0?C*d:0)+O,m[u]={data:i[u],index:l,value:C,startAngle:f,endAngle:S,padAngle:T};return m}return o.value=function(i){return arguments.length?(e=typeof i=="function"?i:Ze(+i),o):e},o.sortValues=function(i){return arguments.length?(t=i,r=null,o):t},o.sort=function(i){return arguments.length?(r=i,t=null,o):r},o.startAngle=function(i){return arguments.length?(n=typeof i=="function"?i:Ze(+i),o):n},o.endAngle=function(i){return arguments.length?(a=typeof i=="function"?i:Ze(+i),o):a},o.padAngle=function(i){return arguments.length?(s=typeof i=="function"?i:Ze(+i),o):s},o}function zn(e,t){if((o=e.length)>1)for(var r=1,n,a,s=e[t[0]],o,i=s.length;r<o;++r)for(a=s,s=e[t[r]],n=0;n<i;++n)s[n][1]+=s[n][0]=isNaN(a[n][1])?a[n][0]:a[n][1]}function Gn(e){for(var t=e.length,r=new Array(t);--t>=0;)r[t]=t;return r}function ZO(e,t){return e[t]}function ew(e){const t=[];return t.key=e,t}function rm(){var e=Ze([]),t=Gn,r=zn,n=ZO;function a(s){var o=Array.from(e.apply(this,arguments),ew),i,l=o.length,c=-1,u;for(const d of s)for(i=0,++c;i<l;++i)(o[i][c]=[0,+n(d,o[i].key,c,s)]).data=d;for(i=0,u=tm(t(o));i<l;++i)o[u[i]].index=i;return r(o,u),o}return a.keys=function(s){return arguments.length?(e=typeof s=="function"?s:Ze(Array.from(s)),a):e},a.value=function(s){return arguments.length?(n=typeof s=="function"?s:Ze(+s),a):n},a.order=function(s){return arguments.length?(t=s==null?Gn:typeof s=="function"?s:Ze(Array.from(s)),a):t},a.offset=function(s){return arguments.length?(r=s??zn,a):r},a}function tw(e,t){if((n=e.length)>0){for(var r,n,a=0,s=e[0].length,o;a<s;++a){for(o=r=0;r<n;++r)o+=e[r][a][1]||0;if(o)for(r=0;r<n;++r)e[r][a][1]/=o}zn(e,t)}}function rw(e,t){if((l=e.length)>0)for(var r,n=0,a,s,o,i,l,c=e[t[0]].length;n<c;++n)for(o=i=0,r=0;r<l;++r)(s=(a=e[t[r]][n])[1]-a[0])>0?(a[0]=o,a[1]=o+=s):s<0?(a[1]=i,a[0]=i+=s):(a[0]=0,a[1]=s)}function nw(e,t){if((a=e.length)>0){for(var r=0,n=e[t[0]],a,s=n.length;r<s;++r){for(var o=0,i=0;o<a;++o)i+=e[o][r][1]||0;n[r][1]+=n[r][0]=-i/2}zn(e,t)}}function aw(e,t){if(!(!((o=e.length)>0)||!((s=(a=e[t[0]]).length)>0))){for(var r=0,n=1,a,s,o;n<s;++n){for(var i=0,l=0,c=0;i<o;++i){for(var u=e[t[i]],d=u[n][1]||0,h=u[n-1][1]||0,p=(d-h)/2,m=0;m<i;++m){var f=e[t[m]],g=f[n][1]||0,S=f[n-1][1]||0;p+=g-S}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,zn(e,t)}}function nm(e){var t=e.map(sw);return Gn(e).sort(function(r,n){return t[r]-t[n]})}function sw(e){for(var t=-1,r=0,n=e.length,a,s=-1/0;++t<n;)(a=+e[t][1])>s&&(s=a,r=t);return r}function am(e){var t=e.map(sm);return Gn(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 ow(e){return am(e).reverse()}function iw(e){var t=e.length,r,n,a=e.map(sm),s=nm(e),o=0,i=0,l=[],c=[];for(r=0;r<t;++r)n=s[r],o<i?(o+=a[n],l.push(n)):(i+=a[n],c.push(n));return c.reverse().concat(l)}function lw(e){return Gn(e).reverse()}const Hi={appearance:nm,ascending:am,descending:ow,insideOut:iw,none:Gn,reverse:lw},qi={expand:tw,diverging:rw,none:zn,silhouette:nw,wiggle:aw},om=e=>{const{series:t,seriesOrder:r,defaultStrategy:n}=e,a=[],s={};return r.forEach(o=>{const{stack:i,stackOrder:l,stackOffset:c}=t[o];i===void 0?a.push({ids:[o],stackingOrder:Hi.none,stackingOffset:qi.none}):s[i]===void 0?(s[i]=a.length,a.push({ids:[o],stackingOrder:Hi[l??(n==null?void 0:n.stackOrder)??"none"],stackingOffset:qi[c??(n==null?void 0:n.stackOffset)??"diverging"]})):(a[s[i]].ids.push(o),l!==void 0&&(a[s[i]].stackingOrder=Hi[l]),c!==void 0&&(a[s[i]].stackingOffset=qi[c]))}),a},cw=e=>e==null?"":e.toLocaleString(),uw=(e,t)=>{const{seriesOrder:r,series:n}=e,a=om(e),s=t??[];r.forEach(i=>{const l=n[i].data;if(l!==void 0)l.forEach((c,u)=>{s.length<=u?s.push({[i]:c}):s[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(`
|
|
128
|
+
`))});const o={};return a.forEach(i=>{const{ids:l,stackingOffset:c,stackingOrder:u}=i,d=rm().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)(s);l.forEach((h,p)=>{const m=n[h].dataKey;o[h]=K({layout:"vertical",labelMarkType:"square",minBarSize:0,valueFormatter:n[h].valueFormatter??cw},n[h],{data:m?t.map(f=>{const g=f[m];return typeof g!="number"?(process.env.NODE_ENV!=="production"&&g!==null&&Da([`MUI X Charts: your dataset key "${m}" is used for plotting bars, but contains nonnumerical elements.`,"Bar plots only support numbers and null values."]),null):g}):n[h].data,stackedData:d[p].map(([f,g])=>[f,g])})})}),{seriesOrder:r,stackingGroups:a,series:o}};function dr(e,t){return typeof e=="function"?e(t):e}const dw=e=>{const{seriesOrder:t,series:r}=e;return t.reduce((n,a)=>{const s=dr(r[a].label,"legend");return s===void 0||n.push({markType:r[a].labelMarkType,id:a,seriesId:a,color:r[a].color,label:s}),n},[])},hw=(e,t,r)=>{const n=e.layout==="vertical",a=n?t==null?void 0:t.colorScale:r==null?void 0:r.colorScale,s=n?r==null?void 0:r.colorScale:t==null?void 0:t.colorScale,o=n?t==null?void 0:t.data:r==null?void 0:r.data;return s?i=>{if(i===void 0)return e.color;const l=e.data[i],c=l===null?e.color:s(l);return c===null?e.color:c}:a&&o?i=>{if(i===void 0)return e.color;const l=o[i],c=l===null?e.color:a(l);return c===null?e.color:c}:()=>e.color},pw=e=>{const{series:t,getColor:r,identifier:n}=e;if(!n||n.dataIndex===void 0)return null;const a=dr(t.label,"tooltip"),s=t.data[n.dataIndex];if(s==null)return null;const o=t.valueFormatter(s,{dataIndex:n.dataIndex});return{identifier:n,color:r(n.dataIndex),label:a,value:s,formattedValue:o,markType:t.labelMarkType}},fw=e=>Object.values(e).map(t=>t.layout==="horizontal"?{direction:"y",axisId:t.yAxisId}:{direction:"x",axisId:t.xAxisId}),mw=(e,t,r)=>K({id:e.id??`auto-generated-id-${t}`,color:r[t%r.length]},e),gw={seriesProcessor:uw,colorProcessor:hw,legendGetter:dw,tooltipGetter:pw,axisTooltipGetter:fw,xExtremumGetter:kO,yExtremumGetter:LO,getSeriesWithDefaultValues:mw},ho=(e,t)=>[t[0]===null?e[0]:Math.min(e[0],t[0]),t[1]===null?e[1]:Math.max(e[1],t[1])],yw=e=>{const{series:t,axis:r,isDefaultAxis:n,getFilters:a}=e;return Object.keys(t).filter(s=>{const o=t[s].xAxisId;return o===r.id||o===void 0&&n}).reduce((s,o)=>{var c;const i=a==null?void 0:a({currentAxisId:r.id,isDefaultAxis:n,seriesXAxisId:t[o].xAxisId,seriesYAxisId:t[o].yAxisId}),l=(c=t[o].data)==null?void 0:c.reduce((u,d,h)=>i&&!i(d,h)?u:ho(u,[d.x,d.x]),[1/0,-1/0]);return ho(s,l??[1/0,-1/0])},[1/0,-1/0])},bw=e=>{const{series:t,axis:r,isDefaultAxis:n,getFilters:a}=e;return Object.keys(t).filter(s=>{const o=t[s].yAxisId;return o===r.id||o===void 0&&n}).reduce((s,o)=>{var c;const i=a==null?void 0:a({currentAxisId:r.id,isDefaultAxis:n,seriesXAxisId:t[o].xAxisId,seriesYAxisId:t[o].yAxisId}),l=(c=t[o].data)==null?void 0:c.reduce((u,d,h)=>i&&!i(d,h)?u:ho(u,[d.y,d.y]),[1/0,-1/0]);return ho(s,l??[1/0,-1/0])},[1/0,-1/0])},vw=({series:e,seriesOrder:t},r)=>({series:Object.fromEntries(Object.entries(e).map(([a,s])=>{const o=s==null?void 0:s.datasetKeys,i=["x","y","id"].filter(c=>typeof(o==null?void 0:o[c])!="string");if(s!=null&&s.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(`
|
|
129
|
+
`));const l=o?(r==null?void 0:r.map(c=>({x:c[o.x]??null,y:c[o.y]??null,z:o.z&&c[o.z],id:o.id&&c[o.id]})))??[]:s.data??[];return[a,K({labelMarkType:"circle",markerSize:4},s,{preview:K({markerSize:1},s==null?void 0:s.preview),data:l,valueFormatter:s.valueFormatter??(c=>c&&`(${c.x}, ${c.y})`)})]})),seriesOrder:t}),xw=(e,t,r,n)=>{const a=n==null?void 0:n.colorScale,s=r==null?void 0:r.colorScale,o=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}:s?i=>{if(i===void 0)return e.color;const l=e.data[i],c=l===null?e.color:s(l.y);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.x);return c===null?e.color:c}:()=>e.color},Sw=e=>{const{seriesOrder:t,series:r}=e;return t.reduce((n,a)=>{const s=dr(r[a].label,"legend");return s===void 0||n.push({markType:r[a].labelMarkType,id:a,seriesId:a,color:r[a].color,label:s}),n},[])},Ow=e=>{const{series:t,getColor:r,identifier:n}=e;if(!n||n.dataIndex===void 0)return null;const a=dr(t.label,"tooltip"),s=t.data[n.dataIndex],o=t.valueFormatter(s,{dataIndex:n.dataIndex});return{identifier:n,color:r(n.dataIndex),label:a,value:s,formattedValue:o,markType:t.labelMarkType}},ww=(e,t,r)=>K({id:e.id??`auto-generated-id-${t}`,color:r[t%r.length]},e),Cw={seriesProcessor:vw,colorProcessor:xw,legendGetter:Sw,tooltipGetter:Ow,xExtremumGetter:yw,yExtremumGetter:bw,getSeriesWithDefaultValues:ww},Pw=e=>{const{axis:t}=e,r=Math.min(...t.data??[]),n=Math.max(...t.data??[]);return[r,n]};function Rw(e,t,r,n){return r.reduce((a,s,o)=>{if(t[o]===null)return a;const[i,l]=e(s);return n&&(!n({y:i,x:null},o)||!n({y:l,x:null},o))?a:[Math.min(i,l,a[0]),Math.max(i,l,a[1])]},[1/0,-1/0])}const Tw=e=>{const{series:t,axis:r,isDefaultAxis:n,getFilters:a}=e;return Object.keys(t).filter(s=>{const o=t[s].yAxisId;return o===r.id||n&&o===void 0}).reduce((s,o)=>{const{area:i,stackedData:l,data:c}=t[o],u=i!==void 0,d=a==null?void 0:a({currentAxisId:r.id,isDefaultAxis:n,seriesXAxisId:t[o].xAxisId,seriesYAxisId:t[o].yAxisId}),h=u&&r.scaleType!=="log"&&typeof t[o].baseline!="string"?g=>g:g=>[g[1],g[1]],p=Rw(h,c,l,d),[m,f]=p;return[Math.min(m,s[0]),Math.max(f,s[1])]},[1/0,-1/0])};function Aw(e,t){const r={};return Object.keys(e).forEach(n=>{r[n]=K({},e[n],{valueFormatter:e[n].valueFormatter??t})}),r}const Vw=(e,t)=>{const{seriesOrder:r,series:n}=e,a=om(K({},e,{defaultStrategy:{stackOffset:"none"}})),s=t??[];r.forEach(i=>{const l=n[i].data;if(l!==void 0)l.forEach((c,u)=>{s.length<=u?s.push({[i]:c}):s[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(`
|
|
130
|
+
`))});const o={};return a.forEach(i=>{const{ids:l,stackingOrder:c,stackingOffset:u}=i,d=rm().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)(s);l.forEach((h,p)=>{const m=n[h].dataKey;o[h]=K({labelMarkType:"line"},n[h],{data:m?t.map(f=>{const g=f[m];return typeof g!="number"?(process.env.NODE_ENV!=="production"&&g!==null&&Da([`MUI X Charts: Your dataset key "${m}" is used for plotting line, but contains nonnumerical elements.`,"Line plots only support numbers and null values."]),null):g}):n[h].data,stackedData:d[p].map(([f,g])=>[f,g])})})}),{seriesOrder:r,stackingGroups:a,series:Aw(o,i=>i==null?"":i.toLocaleString())}},Ew=(e,t,r)=>{const n=r==null?void 0:r.colorScale,a=t==null?void 0:t.colorScale;return n?s=>{if(s===void 0)return e.color;const o=e.data[s],i=o===null?e.color:n(o);return i===null?e.color:i}:a?s=>{var l;if(s===void 0)return e.color;const o=(l=t.data)==null?void 0:l[s],i=o===null?e.color:a(o);return i===null?e.color:i}:()=>e.color},_w=e=>{const{seriesOrder:t,series:r}=e;return t.reduce((n,a)=>{const s=dr(r[a].label,"legend");return s===void 0||n.push({markType:r[a].labelMarkType,id:a,seriesId:a,color:r[a].color,label:s}),n},[])},Iw=e=>{const{series:t,getColor:r,identifier:n}=e;if(!n||n.dataIndex===void 0)return null;const a=dr(t.label,"tooltip"),s=t.data[n.dataIndex],o=t.valueFormatter(s,{dataIndex:n.dataIndex});return{identifier:n,color:r(n.dataIndex),label:a,value:s,formattedValue:o,markType:t.labelMarkType}},Mw=e=>Object.values(e).map(t=>({direction:"x",axisId:t.xAxisId})),$w=(e,t,r)=>K({id:e.id??`auto-generated-id-${t}`,color:r[t%r.length]},e),jw={colorProcessor:Ew,seriesProcessor:Vw,legendGetter:_w,tooltipGetter:Iw,axisTooltipGetter:Mw,xExtremumGetter:Pw,yExtremumGetter:Tw,getSeriesWithDefaultValues:$w},kw=(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}},Lw=e=>{const{seriesOrder:t,series:r}=e,n={};return t.forEach(a=>{const s=XO().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(kw(r[a].sortingValues??"none"))(r[a].data.map(o=>o.value));n[a]=K({labelMarkType:"circle",valueFormatter:o=>o.value.toLocaleString()},r[a],{data:r[a].data.map((o,i)=>K({},o,{id:o.id??`auto-generated-pie-id-${a}-${i}`},s[i])).map((o,i)=>{var l,c;return K({labelMarkType:"circle"},o,{formattedValue:((c=(l=r[a]).valueFormatter)==null?void 0:c.call(l,K({},o,{label:dr(o.label,"arc")}),{dataIndex:i}))??o.value.toLocaleString()})})})}),{seriesOrder:t,series:n}},Uw=e=>t=>e.data[t].color,Dw=e=>{const{seriesOrder:t,series:r}=e;return t.reduce((n,a)=>(r[a].data.forEach((s,o)=>{const i=dr(s.label,"legend");i!==void 0&&n.push({markType:s.labelMarkType??r[a].labelMarkType,id:s.id??o,seriesId:a,color:s.color,label:i,itemId:s.id??o})}),n),[])},Nw=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 s=dr(a.label,"tooltip"),o=K({},a,{label:s}),i=t.valueFormatter(o,{dataIndex:n.dataIndex});return{identifier:n,color:r(n.dataIndex),label:s,value:o,formattedValue:i,markType:a.labelMarkType??t.labelMarkType}},Fw=(e,t,r)=>K({id:e.id??`auto-generated-id-${t}`},e,{data:e.data.map((n,a)=>K({color:r[a%r.length]},n))}),Bw={colorProcessor:Uw,seriesProcessor:Lw,legendGetter:Dw,tooltipGetter:Nw,getSeriesWithDefaultValues:Fw},zw={bar:gw,scatter:Cw,line:jw,pie:Bw},Gw=[Uc,ei,kc,ti];function Hw(e){const{children:t,plugins:r=Gw,pluginParams:n={},seriesConfig:a=zw}=e,{contextValue:s}=Cx(r,n,a);return x.jsx(gc.Provider,{value:s,children:t})}const im=()=>{const e=F.useContext(gc);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(`
|
|
131
|
+
`));return e};function Zr(){const e=im();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(`
|
|
132
|
+
`));return e.store}function lm(){const e=Zr();return bt(e,rs)}function cm(){const e=Zr();return bt(e,ox)}const Vl=(e,t)=>e===void 0?t:Math.PI*e/180;function qw(){const e=Zr(),{axis:t,axisIds:r}=bt(e,Qr);return{xAxis:t,xAxisIds:r}}function Jw(){const e=Zr(),{axis:t,axisIds:r}=bt(e,Xr);return{yAxis:t,yAxisIds:r}}function Ww(){const e=Zr(),{axis:t,axisIds:r}=bt(e,jO)??{axis:{},axisIds:[]};return{zAxis:t,zAxisIds:r}}function Kw(){const e=im();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(`
|
|
133
|
+
`));return e.svgRef}function Yw(){const e=cm();return F.useCallback(t=>`${e}-gradient-${t}`,[e])}function Qw(){const e=cm();return F.useCallback(t=>`${e}-gradient-${t}-object-bound`,[e])}var Ji,Bd;function Xw(){if(Bd)return Ji;Bd=1;var e=4,t=.001,r=1e-7,n=10,a=11,s=1/(a-1),o=typeof Float32Array=="function";function i(f,g){return 1-3*g+3*f}function l(f,g){return 3*g-6*f}function c(f){return 3*f}function u(f,g,S){return((i(g,S)*f+l(g,S))*f+c(g))*f}function d(f,g,S){return 3*i(g,S)*f*f+2*l(g,S)*f+c(g)}function h(f,g,S,T,O){var C,V,R=0;do V=g+(S-g)/2,C=u(V,T,O)-f,C>0?S=V:g=V;while(Math.abs(C)>r&&++R<n);return V}function p(f,g,S,T){for(var O=0;O<e;++O){var C=d(g,S,T);if(C===0)return g;var V=u(g,S,T)-f;g-=V/C}return g}function m(f){return f}return Ji=function(g,S,T,O){if(!(0<=g&&g<=1&&0<=T&&T<=1))throw new Error("bezier x values must be in [0, 1] range");if(g===S&&T===O)return m;for(var C=o?new Float32Array(a):new Array(a),V=0;V<a;++V)C[V]=u(V*s,g,T);function R(P){for(var E=0,B=1,y=a-1;B!==y&&C[B]<=P;++B)E+=s;--B;var A=(P-C[B])/(C[B+1]-C[B]),z=E+A*s,I=d(z,g,T);return I>=t?p(P,z,g,T):I===0?z:h(P,E,E+s,g,T)}return function(E){return E===0?0:E===1?1:u(R(E),S,O)}},Ji}var Zw=Xw();const eC=fy(Zw),tC=300,rC=eC(.66,0,.34,1);var Hn=0,Va=0,ma=0,um=1e3,po,Ea,fo=0,Gr=0,ri=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 Dc(){return Gr||(dm(nC),Gr=Ha.now()+ri)}function nC(){Gr=0}function mo(){this._call=this._time=this._next=null}mo.prototype=hm.prototype={constructor:mo,restart:function(e,t,r){if(typeof e!="function")throw new TypeError("callback is not a function");r=(r==null?Dc():+r)+(t==null?0:+t),!this._next&&Ea!==this&&(Ea?Ea._next=this:po=this,Ea=this),this._call=e,this._time=r,_l()},stop:function(){this._call&&(this._call=null,this._time=1/0,_l())}};function hm(e,t,r){var n=new mo;return n.restart(e,t,r),n}function El(){Dc(),++Hn;for(var e=po,t;e;)(t=Gr-e._time)>=0&&e._call.call(void 0,t),e=e._next;--Hn}function zd(){Gr=(fo=Ha.now())+ri,Hn=Va=0;try{El()}finally{Hn=0,sC(),Gr=0}}function aC(){var e=Ha.now(),t=e-fo;t>um&&(ri-=t,fo=e)}function sC(){for(var e,t=po,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:po=r);Ea=e,_l(n)}function _l(e){if(!Hn){Va&&(Va=clearTimeout(Va));var t=e-Gr;t>24?(e<1/0&&(Va=setTimeout(zd,e-Ha.now()-ri)),ma&&(ma=clearInterval(ma))):(ma||(fo=Ha.now(),ma=setInterval(aC,um)),Hn=1,dm(zd))}}function oC(e,t,r){var n=new mo;return t=t==null?0:+t,n.restart(a=>{n.stop(),e(a+t)},t,r),n}class iC{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=Dc()-this.elapsed;return this.timer=hm(r=>this.timerCallback(r),0,t),El(),this}stop(){return this.running?(this.timer&&(this.timer.stop(),this.timer=null),this):this}finish(){return this.stop(),oC(()=>this.timerCallback(this.duration)),El(),this}}function lC(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 s=r[a];if(!Object.prototype.hasOwnProperty.call(t,s)||!Object.is(e[s],t[s]))return!1}return!0}function cC(e,{createInterpolator:t,applyProps:r,skip:n,initialProps:a=e}){const s=F.useRef(a),o=F.useRef(null),i=F.useRef(null),l=F.useRef(e);or(()=>{l.current=e},[e]),or(()=>{var d;n&&((d=o.current)==null||d.finish(),o.current=null,i.current=null,s.current=e)},[e,n]);const c=F.useCallback(d=>{const h=s.current,p=t(h,e);o.current=new iC(tC,rC,m=>{const f=p(m);s.current=f,r(d,f)})},[r,t,e]);return F.useCallback(d=>{var p,m,f,g;if(d===null){(p=o.current)==null||p.stop();return}const h=i.current;if(h===d){if(lC(l.current,e)){(m=o.current)==null||m.resume();return}(f=o.current)==null||f.stop()}h&&((g=o.current)==null||g.stop()),i.current=d,(o.current||!n)&&c(d)},[c,e,n])}function uC(e,{createInterpolator:t,transformProps:r,applyProps:n,skip:a,initialProps:s=e,ref:o}){const i=r??(u=>u),l=cC(e,{initialProps:s,createInterpolator:t,applyProps:(u,d)=>n(u,i(d)),skip:a});return K({},r(a?e:s),{ref:Qp(l,o)})}function Gd(e){const{isReversed:t,gradientId:r,size:n,direction:a,scale:s,colorMap:o}=e;return n<=0?null:x.jsx("linearGradient",{id:r,x1:"0",x2:"0",y1:"0",y2:"0",[`${a}${t?1:2}`]:`${n}px`,gradientUnits:"userSpaceOnUse",children:o.thresholds.map((i,l)=>{const c=s(i);if(c===void 0)return null;const u=t?1-c/n:c/n;return Number.isNaN(u)?null:x.jsxs(F.Fragment,{children:[x.jsx("stop",{offset:u,stopColor:o.colors[l],stopOpacity:1}),x.jsx("stop",{offset:u,stopColor:o.colors[l+1],stopOpacity:1})]},i.toString()+l)})})}const dC=10;function Hd(e){const{gradientUnits:t,isReversed:r,gradientId:n,size:a,direction:s,scale:o,colorScale:i,colorMap:l}=e,c=[l.min??0,l.max??100],u=c.map(o).filter(m=>m!==void 0);if(u.length!==2)return null;const d=typeof c[0]=="number"?Dt(c[0],c[1]):Oc(c[0],c[1]),h=Math.round((Math.max(...u)-Math.min(...u))/dC),p=`${c[0]}-${c[1]}-`;return x.jsx("linearGradient",{id:n,x1:"0",x2:"0",y1:"0",y2:"0",[`${s}${r?1:2}`]:t==="objectBoundingBox"?1:`${a}px`,gradientUnits:t??"userSpaceOnUse",children:Array.from({length:h+1},(m,f)=>{const g=d(f/h);if(g===void 0)return null;const S=o(g);if(S===void 0)return null;const T=r?1-S/a:S/a,O=i(g);return O===null?null:x.jsx("stop",{offset:T,stopColor:O,stopOpacity:1},p+f)})})}const hC=10,pC=e=>e?{x1:"1",x2:"0",y1:"0",y2:"0"}:{x1:"0",x2:"1",y1:"0",y2:"0"};function Wi(e){const{isReversed:t,gradientId:r,colorScale:n,colorMap:a}=e,s=[a.min??0,a.max??100],o=typeof s[0]=="number"?Dt(s[0],s[1]):Oc(s[0],s[1]),i=hC,l=`${s[0]}-${s[1]}-`;return x.jsx("linearGradient",K({id:r},pC(t),{gradientUnits:"objectBoundingBox",children:Array.from({length:i+1},(c,u)=>{const d=u/i,h=o(d);if(h===void 0)return null;const p=n(h);return p===null?null:x.jsx("stop",{offset:d,stopColor:p,stopOpacity:1},l+u)})}))}function fC(){const{top:e,height:t,bottom:r,left:n,width:a,right:s}=lm(),o=e+t+r,i=n+a+s,l=Yw(),c=Qw(),{xAxis:u,xAxisIds:d}=qw(),{yAxis:h,yAxisIds:p}=Jw(),{zAxis:m,zAxisIds:f}=Ww(),g=p.filter(O=>h[O].colorMap!==void 0),S=d.filter(O=>u[O].colorMap!==void 0),T=f.filter(O=>m[O].colorMap!==void 0);return g.length===0&&S.length===0&&T.length===0?null:x.jsxs("defs",{children:[g.map(O=>{const C=l(O),V=c(O),{colorMap:R,scale:P,colorScale:E,reverse:B}=h[O];return(R==null?void 0:R.type)==="piecewise"?x.jsx(Gd,{isReversed:!B,scale:P,colorMap:R,size:o,gradientId:C,direction:"y"},C):(R==null?void 0:R.type)==="continuous"?x.jsxs(F.Fragment,{children:[x.jsx(Hd,{isReversed:!B,scale:P,colorScale:E,colorMap:R,size:o,gradientId:C,direction:"y"}),x.jsx(Wi,{isReversed:B,colorScale:E,colorMap:R,gradientId:V})]},C):null}),S.map(O=>{const C=l(O),V=c(O),{colorMap:R,scale:P,reverse:E,colorScale:B}=u[O];return(R==null?void 0:R.type)==="piecewise"?x.jsx(Gd,{isReversed:E,scale:P,colorMap:R,size:i,gradientId:C,direction:"x"},C):(R==null?void 0:R.type)==="continuous"?x.jsxs(F.Fragment,{children:[x.jsx(Hd,{isReversed:E,scale:P,colorScale:B,colorMap:R,size:i,gradientId:C,direction:"x"}),x.jsx(Wi,{isReversed:E,colorScale:B,colorMap:R,gradientId:V})]},C):null}),T.map(O=>{const C=c(O),{colorMap:V,colorScale:R}=m[O];return(V==null?void 0:V.type)==="continuous"?x.jsx(Wi,{colorScale:R,colorMap:V,gradientId:C},C):null})]})}const mC=["children","className","title","desc"],gC=Pt("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"})),Nc=F.forwardRef(function(t,r){const n=Zr(),{width:a,height:s}=bt(n,tx),{width:o,height:i}=bt(n,ex),l=Kw(),c=Qp(l,r),u=av({props:t,name:"MuiChartsSurface"}),{children:d,className:h,title:p,desc:m}=u,f=Cr(u,mC),g=s>0&&a>0;return x.jsxs(gC,K({ownerState:{width:o,height:i},viewBox:`0 0 ${a} ${s}`,className:h},f,{ref:c,children:[p&&x.jsx("title",{children:p}),m&&x.jsx("desc",{children:m}),x.jsx(fC,{}),g&&d]}))});process.env.NODE_ENV!=="production"&&(Nc.displayName="ChartsSurface");process.env.NODE_ENV!=="production"&&(Nc.propTypes={children:b.node,className:b.string,desc:b.string,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),title:b.string});function ga(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 Ki(e){const t=Vl(e);return[Math.sin(t),-Math.cos(t)]}function yC(e,t){const r=[[0,0],Ki(e),Ki(t)],n=Math.min(e,t),a=Math.max(e,t),s=Math.floor(n/90)*90;for(let u=1;u<=4;u+=1){const d=s+u*90;d<a&&r.push(Ki(d))}const o=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:-o/(i-o),cy:-l/(c-l),minX:o,maxX:i,minY:l,maxY:c}}function bC(e,t,r,n,{minX:a,maxX:s,minY:o,maxY:i}){return Math.min(...[{ratio:Math.abs(a),space:e},{ratio:Math.abs(s),space:r-e},{ratio:Math.abs(o),space:t},{ratio:Math.abs(i),space:n-t}].map(({ratio:l,space:c})=>l<1e-5?1/0:c/l))}const Fc=F.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"&&(Fc.displayName="GaugeContext");function vC(e){const{value:t=null,valueMin:r=0,valueMax:n=100,startAngle:a=0,endAngle:s=360,outerRadius:o,innerRadius:i,cornerRadius:l,cx:c,cy:u,children:d}=e,{left:h,top:p,width:m,height:f}=lm(),g=yC(a,s),S=c?ga(c,m):g.cx*m,T=u?ga(u,f):g.cy*f;let O=h+S,C=p+T;const V=bC(S,T,m,f,g);if(c===void 0){const y=V*(g.maxX-g.minX);O=h+(m-y)/2+g.cx*y}if(u===void 0){const y=V*(g.maxY-g.minY);C=p+(f-y)/2+g.cy*y}const R=ga(o??V,V),P=ga(i??"80%",V),E=ga(l??0,R-P),B=F.useMemo(()=>{const y=Vl(a),A=Vl(s);return{value:t,valueMin:r,valueMax:n,startAngle:y,endAngle:A,outerRadius:R,innerRadius:P,cornerRadius:E,cx:O,cy:C,maxRadius:V,valueAngle:t===null?null:y+(A-y)*(t-r)/(n-r)}},[t,r,n,a,s,R,P,E,O,C,V]);return x.jsx(Fc.Provider,{value:B,children:d})}function Bc(){return F.useContext(Fc)}const xC=["width","height","margin","title","desc","value","valueMin","valueMax","startAngle","endAngle","outerRadius","innerRadius","cornerRadius","cx","cy","children"],SC=Pt("g")(({theme:e})=>({"& text":{fill:(e.vars||e).palette.text.primary}})),zc=F.forwardRef(function(t,r){const{width:n,height:a,margin:s,title:o,desc:i,value:l,valueMin:c=0,valueMax:u=100,startAngle:d,endAngle:h,outerRadius:p,innerRadius:m,cornerRadius:f,cx:g,cy:S,children:T}=t,O=Cr(t,xC);return x.jsx(Hw,{pluginParams:{width:n,height:a,margin:af(s,{left:10,right:10,top:10,bottom:10})},plugins:[],children:x.jsx(vC,{value:l,valueMin:c,valueMax:u,startAngle:d,endAngle:h,outerRadius:p,innerRadius:m,cornerRadius:f,cx:g,cy:S,children:x.jsx(Nc,K({title:o,desc:i,role:"meter","aria-valuenow":l===null?void 0:l,"aria-valuemin":c,"aria-valuemax":u},O,{ref:r,children:x.jsx(SC,{"aria-hidden":"true",children:T})}))})})});process.env.NODE_ENV!=="production"&&(zc.displayName="GaugeContainer");process.env.NODE_ENV!=="production"&&(zc.propTypes={children:b.node,className:b.string,cornerRadius:b.oneOfType([b.number,b.string]),cx:b.oneOfType([b.number,b.string]),cy:b.oneOfType([b.number,b.string]),desc:b.string,endAngle:b.number,height:b.number,id:b.string,innerRadius:b.oneOfType([b.number,b.string]),margin:b.oneOfType([b.number,b.shape({bottom:b.number,left:b.number,right:b.number,top:b.number})]),outerRadius:b.oneOfType([b.number,b.string]),skipAnimation:b.bool,startAngle:b.number,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),title:b.string,value:b.number,valueMax:b.number,valueMin:b.number,width:b.number});function OC(e){const t=Zr(),r=bt(t,Ev);return e||r}function wC(e,t){const r=Dt(e.startAngle,t.startAngle),n=Dt(e.endAngle,t.endAngle),a=Dt(e.innerRadius,t.innerRadius),s=Dt(e.outerRadius,t.outerRadius),o=Dt(e.cornerRadius,t.cornerRadius);return i=>({startAngle:r(i),endAngle:n(i),innerRadius:a(i),outerRadius:s(i),cornerRadius:o(i)})}function CC(e){return uC({startAngle:e.startAngle,endAngle:e.endAngle,innerRadius:e.innerRadius,outerRadius:e.outerRadius,cornerRadius:e.cornerRadius},{createInterpolator:wC,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 PC=["cx","cy","startAngle","endAngle","cornerRadius","innerRadius","outerRadius","skipAnimation"],RC=Pt("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:s,outerRadius:o,innerRadius:i,cornerRadius:l,cx:c,cy:u}=Bc();if(t===null)return null;const d=a+(t-r)/(n-r)*(s-a);return x.jsx(fm,K({},e,{cx:c,cy:u,startAngle:a,endAngle:d,cornerRadius:l,innerRadius:i,outerRadius:o}))}process.env.NODE_ENV!=="production"&&(pm.propTypes={skipAnimation:b.bool});function fm(e){let{cx:t,cy:r,startAngle:n,endAngle:a,cornerRadius:s,innerRadius:o,outerRadius:i,skipAnimation:l}=e,c=Cr(e,PC);const u=OC(l),d=CC({startAngle:n,endAngle:a,cornerRadius:s,innerRadius:o,outerRadius:i,skipAnimation:u});return x.jsx(RC,K({},d,{transform:`translate(${t}, ${r})`},c))}process.env.NODE_ENV!=="production"&&(fm.propTypes={cornerRadius:b.number.isRequired,cx:b.number.isRequired,cy:b.number.isRequired,endAngle:b.number.isRequired,innerRadius:b.number.isRequired,outerRadius:b.number.isRequired,skipAnimation:b.bool,startAngle:b.number.isRequired});const TC=Pt("path",{name:"MuiGauge",slot:"ReferenceArc"})(({theme:e})=>({fill:(e.vars||e).palette.divider}));function AC(e){const{startAngle:t,endAngle:r,outerRadius:n,innerRadius:a,cornerRadius:s,cx:o,cy:i}=Bc();return x.jsx(TC,K({transform:`translate(${o}, ${i})`,d:em().cornerRadius(s)({startAngle:t,endAngle:r,innerRadius:a,outerRadius:n})},e))}const qd=e=>e,VC=()=>{let e=qd;return{configure(t){e=t},generate(t){return e(t)},reset(){e=qd}}},EC=VC(),_C={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 mm(e,t,r="Mui"){const n=_C[t];return n?`${r}-${n}`:`${EC.generate(e)}-${t}`}function IC(e,t,r="Mui"){const n={};return t.forEach(a=>{n[a]=mm(e,a,r)}),n}function MC(e){return mm("MuiGauge",e)}IC("MuiGauge",["root","valueArc","referenceArc","valueText"]);function $C(){return typeof window>"u"}const Cs=new Map,jC=2e3,kC={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},LC=["minWidth","maxWidth","width","minHeight","maxHeight","height","top","left","fontSize","padding","margin","paddingLeft","paddingRight","paddingTop","paddingBottom","marginLeft","marginRight","marginTop","marginBottom"],Jd="mui_measurement_span";function gm(e,t){return LC.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 UC=e=>Object.keys(e).sort().reduce((t,r)=>`${t}${ym(r)}:${gm(r,e[r])};`,"");let Yi;const DC=(e,t={})=>{if(e==null||$C())return{width:0,height:0};const r=`${e}`,n=UC(t),a=`${r}-${n}`,s=Cs.get(a);if(s)return s;try{let o=document.getElementById(Jd);o===null&&(o=document.createElement("span"),o.setAttribute("id",Jd),o.setAttribute("aria-hidden","true"),document.body.appendChild(o));const i=K({},kC,t);Object.keys(i).map(u=>(o.style[ym(u)]=gm(u,i[u]),u)),o.textContent=r;const l=o.getBoundingClientRect(),c={width:l.width,height:l.height};return Cs.set(a,c),Cs.size+1>jC&&Cs.clear(),process.env.NODE_ENV==="test"?o.textContent="":(Yi&&clearTimeout(Yi),Yi=setTimeout(()=>{o.textContent=""},0)),c}catch{return{width:0,height:0}}};function NC({style:e,needsComputation:t,text:r}){return r.split(`
|
|
134
|
+
`).map(n=>K({text:n},t?DC(n,e):{width:0,height:0}))}function FC(){const[e,t]=F.useState(typeof window<"u"||process.env.NODE_ENV==="test");return F.useEffect(()=>{t(!0)},[]),e}const BC=["x","y","style","text","ownerState"],zC=["angle","textAnchor","dominantBaseline"];function bm(e){const{x:t,y:r,style:n,text:a}=e,s=Cr(e,BC),o=n??{},{angle:i,textAnchor:l,dominantBaseline:c}=o,u=Cr(o,zC),d=FC(),h=F.useMemo(()=>NC({style:u,needsComputation:d&&a.includes(`
|
|
135
|
+
`),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 x.jsx("text",K({},s,{transform:i?`rotate(${i}, ${t}, ${r})`:void 0,x:t,y:r,textAnchor:l,dominantBaseline:c,style:u,children:h.map((m,f)=>x.jsx("tspan",{x:t,dy:`${f===0?p:h[0].height}px`,dominantBaseline:c,children:m.text},f))}))}process.env.NODE_ENV!=="production"&&(bm.propTypes={lineHeight:b.number,needsComputation:b.bool,ownerState:b.any,style:b.object,text:b.string.isRequired});const GC=["text","className"];function HC({value:e}){return e===null?null:e.toLocaleString()}function vm(e){const{text:t=HC,className:r}=e,n=Cr(e,GC),{value:a,valueMin:s,valueMax:o,cx:i,cy:l}=Bc(),c=typeof t=="function"?t({value:a,valueMin:s,valueMax:o}):t;return c===null?null:x.jsx("g",{className:r,children:x.jsx(bm,K({x:i,y:l,text:c,style:{textAnchor:"middle",dominantBaseline:"central"}},n))})}process.env.NODE_ENV!=="production"&&(vm.propTypes={lineHeight:b.number,needsComputation:b.bool,ownerState:b.any,style:b.object,text:b.oneOfType([b.func,b.string])});const qC=["text","children","classes","className","skipAnimation"],JC=e=>{const{classes:t}=e;return wy({root:["root"],valueArc:["valueArc"],referenceArc:["referenceArc"],valueText:["valueText"]},MC,t)},go=F.forwardRef(function(t,r){const{text:n,children:a,className:s,skipAnimation:o}=t,i=Cr(t,qC),l=JC(t);return x.jsxs(zc,K({},i,{className:Nt(l.root,s),ref:r,children:[x.jsx(AC,{className:l.referenceArc}),x.jsx(pm,{className:l.valueArc,skipAnimation:o}),x.jsx(vm,{className:l.valueText,text:n}),a]}))});process.env.NODE_ENV!=="production"&&(go.displayName="Gauge");process.env.NODE_ENV!=="production"&&(go.propTypes={children:b.node,classes:b.object,className:b.string,cornerRadius:b.oneOfType([b.number,b.string]),cx:b.oneOfType([b.number,b.string]),cy:b.oneOfType([b.number,b.string]),desc:b.string,endAngle:b.number,height:b.number,id:b.string,innerRadius:b.oneOfType([b.number,b.string]),margin:b.oneOfType([b.number,b.shape({bottom:b.number,left:b.number,right:b.number,top:b.number})]),outerRadius:b.oneOfType([b.number,b.string]),skipAnimation:b.bool,startAngle:b.number,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),text:b.oneOfType([b.func,b.string]),title:b.string,value:b.number,valueMax:b.number,valueMin:b.number,width:b.number});const pe=e=>typeof e=="string",ya=()=>{let e,t;const r=new Promise((n,a)=>{e=n,t=a});return r.resolve=e,r.reject=t,r},Wd=e=>e==null?"":""+e,WC=(e,t,r)=>{e.forEach(n=>{t[n]&&(r[n]=t[n])})},KC=/###/g,Kd=e=>e&&e.indexOf("###")>-1?e.replace(KC,"."):e,Yd=e=>!e||pe(e),Ma=(e,t,r)=>{const n=pe(t)?t.split("."):t;let a=0;for(;a<n.length-1;){if(Yd(e))return{};const s=Kd(n[a]);!e[s]&&r&&(e[s]=new r),Object.prototype.hasOwnProperty.call(e,s)?e=e[s]:e={},++a}return Yd(e)?{}:{obj:e,k:Kd(n[a])}},Qd=(e,t,r)=>{const{obj:n,k:a}=Ma(e,t,Object);if(n!==void 0||t.length===1){n[a]=r;return}let s=t[t.length-1],o=t.slice(0,t.length-1),i=Ma(e,o,Object);for(;i.obj===void 0&&o.length;)s=`${o[o.length-1]}.${s}`,o=o.slice(0,o.length-1),i=Ma(e,o,Object),i!=null&&i.obj&&typeof i.obj[`${i.k}.${s}`]<"u"&&(i.obj=void 0);i.obj[`${i.k}.${s}`]=r},YC=(e,t,r,n)=>{const{obj:a,k:s}=Ma(e,t,Object);a[s]=a[s]||[],a[s].push(r)},yo=(e,t)=>{const{obj:r,k:n}=Ma(e,t);if(r&&Object.prototype.hasOwnProperty.call(r,n))return r[n]},QC=(e,t,r)=>{const n=yo(e,r);return n!==void 0?n:yo(t,r)},xm=(e,t,r)=>{for(const n in t)n!=="__proto__"&&n!=="constructor"&&(n in e?pe(e[n])||e[n]instanceof String||pe(t[n])||t[n]instanceof String?r&&(e[n]=t[n]):xm(e[n],t[n],r):e[n]=t[n]);return e},xn=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var XC={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};const ZC=e=>pe(e)?e.replace(/[&<>"'\/]/g,t=>XC[t]):e;class eP{constructor(t){this.capacity=t,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(t){const r=this.regExpMap.get(t);if(r!==void 0)return r;const n=new RegExp(t);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(t,n),this.regExpQueue.push(t),n}}const tP=[" ",",","?","!",";"],rP=new eP(20),nP=(e,t,r)=>{t=t||"",r=r||"";const n=tP.filter(o=>t.indexOf(o)<0&&r.indexOf(o)<0);if(n.length===0)return!0;const a=rP.getRegExp(`(${n.map(o=>o==="?"?"\\?":o).join("|")})`);let s=!a.test(e);if(!s){const o=e.indexOf(r);o>0&&!a.test(e.substring(0,o))&&(s=!0)}return s},Il=function(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".";if(!e)return;if(e[t])return Object.prototype.hasOwnProperty.call(e,t)?e[t]:void 0;const n=t.split(r);let a=e;for(let s=0;s<n.length;){if(!a||typeof a!="object")return;let o,i="";for(let l=s;l<n.length;++l)if(l!==s&&(i+=r),i+=n[l],o=a[i],o!==void 0){if(["string","number","boolean"].indexOf(typeof o)>-1&&l<n.length-1)continue;s+=l-s+1;break}a=o}return a},bo=e=>e==null?void 0:e.replace("_","-"),aP={type:"logger",log(e){this.output("log",e)},warn(e){this.output("warn",e)},error(e){this.output("error",e)},output(e,t){var r,n;(n=(r=console==null?void 0:console[e])==null?void 0:r.apply)==null||n.call(r,console,t)}};class vo{constructor(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.init(t,r)}init(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.prefix=r.prefix||"i18next:",this.logger=t||aP,this.options=r,this.debug=r.debug}log(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return this.forward(r,"log","",!0)}warn(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return this.forward(r,"warn","",!0)}error(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return this.forward(r,"error","")}deprecate(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return this.forward(r,"warn","WARNING DEPRECATED: ",!0)}forward(t,r,n,a){return a&&!this.debug?null:(pe(t[0])&&(t[0]=`${n}${this.prefix} ${t[0]}`),this.logger[r](t))}create(t){return new vo(this.logger,{prefix:`${this.prefix}:${t}:`,...this.options})}clone(t){return t=t||this.options,t.prefix=t.prefix||this.prefix,new vo(this.logger,t)}}var Yt=new vo;class ni{constructor(){this.observers={}}on(t,r){return t.split(" ").forEach(n=>{this.observers[n]||(this.observers[n]=new Map);const a=this.observers[n].get(r)||0;this.observers[n].set(r,a+1)}),this}off(t,r){if(this.observers[t]){if(!r){delete this.observers[t];return}this.observers[t].delete(r)}}emit(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),a=1;a<r;a++)n[a-1]=arguments[a];this.observers[t]&&Array.from(this.observers[t].entries()).forEach(o=>{let[i,l]=o;for(let c=0;c<l;c++)i(...n)}),this.observers["*"]&&Array.from(this.observers["*"].entries()).forEach(o=>{let[i,l]=o;for(let c=0;c<l;c++)i.apply(i,[t,...n])})}}class Xd extends ni{constructor(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{ns:["translation"],defaultNS:"translation"};super(),this.data=t||{},this.options=r,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.options.ignoreJSONStructure===void 0&&(this.options.ignoreJSONStructure=!0)}addNamespaces(t){this.options.ns.indexOf(t)<0&&this.options.ns.push(t)}removeNamespaces(t){const r=this.options.ns.indexOf(t);r>-1&&this.options.ns.splice(r,1)}getResource(t,r,n){var c,u;let a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const s=a.keySeparator!==void 0?a.keySeparator:this.options.keySeparator,o=a.ignoreJSONStructure!==void 0?a.ignoreJSONStructure:this.options.ignoreJSONStructure;let i;t.indexOf(".")>-1?i=t.split("."):(i=[t,r],n&&(Array.isArray(n)?i.push(...n):pe(n)&&s?i.push(...n.split(s)):i.push(n)));const l=yo(this.data,i);return!l&&!r&&!n&&t.indexOf(".")>-1&&(t=i[0],r=i[1],n=i.slice(2).join(".")),l||!o||!pe(n)?l:Il((u=(c=this.data)==null?void 0:c[t])==null?void 0:u[r],n,s)}addResource(t,r,n,a){let s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{silent:!1};const o=s.keySeparator!==void 0?s.keySeparator:this.options.keySeparator;let i=[t,r];n&&(i=i.concat(o?n.split(o):n)),t.indexOf(".")>-1&&(i=t.split("."),a=r,r=i[1]),this.addNamespaces(r),Qd(this.data,i,a),s.silent||this.emit("added",t,r,n,a)}addResources(t,r,n){let a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{silent:!1};for(const s in n)(pe(n[s])||Array.isArray(n[s]))&&this.addResource(t,r,s,n[s],{silent:!0});a.silent||this.emit("added",t,r,n)}addResourceBundle(t,r,n,a,s){let o=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{silent:!1,skipCopy:!1},i=[t,r];t.indexOf(".")>-1&&(i=t.split("."),a=n,n=r,r=i[1]),this.addNamespaces(r);let l=yo(this.data,i)||{};o.skipCopy||(n=JSON.parse(JSON.stringify(n))),a?xm(l,n,s):l={...l,...n},Qd(this.data,i,l),o.silent||this.emit("added",t,r,n)}removeResourceBundle(t,r){this.hasResourceBundle(t,r)&&delete this.data[t][r],this.removeNamespaces(r),this.emit("removed",t,r)}hasResourceBundle(t,r){return this.getResource(t,r)!==void 0}getResourceBundle(t,r){return r||(r=this.options.defaultNS),this.getResource(t,r)}getDataByLanguage(t){return this.data[t]}hasLanguageSomeTranslations(t){const r=this.getDataByLanguage(t);return!!(r&&Object.keys(r)||[]).find(a=>r[a]&&Object.keys(r[a]).length>0)}toJSON(){return this.data}}var Sm={processors:{},addPostProcessor(e){this.processors[e.name]=e},handle(e,t,r,n,a){return e.forEach(s=>{var o;t=((o=this.processors[s])==null?void 0:o.process(t,r,n,a))??t}),t}};const Zd={},eh=e=>!pe(e)&&typeof e!="boolean"&&typeof e!="number";class xo extends ni{constructor(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};super(),WC(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],t,this),this.options=r,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.logger=Yt.create("translator")}changeLanguage(t){t&&(this.language=t)}exists(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};if(t==null)return!1;const n=this.resolve(t,r);return(n==null?void 0:n.res)!==void 0}extractFromKey(t,r){let n=r.nsSeparator!==void 0?r.nsSeparator:this.options.nsSeparator;n===void 0&&(n=":");const a=r.keySeparator!==void 0?r.keySeparator:this.options.keySeparator;let s=r.ns||this.options.defaultNS||[];const o=n&&t.indexOf(n)>-1,i=!this.options.userDefinedKeySeparator&&!r.keySeparator&&!this.options.userDefinedNsSeparator&&!r.nsSeparator&&!nP(t,n,a);if(o&&!i){const l=t.match(this.interpolator.nestingRegexp);if(l&&l.length>0)return{key:t,namespaces:pe(s)?[s]:s};const c=t.split(n);(n!==a||n===a&&this.options.ns.indexOf(c[0])>-1)&&(s=c.shift()),t=c.join(a)}return{key:t,namespaces:pe(s)?[s]:s}}translate(t,r,n){if(typeof r!="object"&&this.options.overloadTranslationOptionHandler&&(r=this.options.overloadTranslationOptionHandler(arguments)),typeof r=="object"&&(r={...r}),r||(r={}),t==null)return"";Array.isArray(t)||(t=[String(t)]);const a=r.returnDetails!==void 0?r.returnDetails:this.options.returnDetails,s=r.keySeparator!==void 0?r.keySeparator:this.options.keySeparator,{key:o,namespaces:i}=this.extractFromKey(t[t.length-1],r),l=i[i.length-1],c=r.lng||this.language,u=r.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if((c==null?void 0:c.toLowerCase())==="cimode"){if(u){const A=r.nsSeparator||this.options.nsSeparator;return a?{res:`${l}${A}${o}`,usedKey:o,exactUsedKey:o,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(r)}:`${l}${A}${o}`}return a?{res:o,usedKey:o,exactUsedKey:o,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(r)}:o}const d=this.resolve(t,r);let h=d==null?void 0:d.res;const p=(d==null?void 0:d.usedKey)||o,m=(d==null?void 0:d.exactUsedKey)||o,f=["[object Number]","[object Function]","[object RegExp]"],g=r.joinArrays!==void 0?r.joinArrays:this.options.joinArrays,S=!this.i18nFormat||this.i18nFormat.handleAsObject,T=r.count!==void 0&&!pe(r.count),O=xo.hasDefaultValue(r),C=T?this.pluralResolver.getSuffix(c,r.count,r):"",V=r.ordinal&&T?this.pluralResolver.getSuffix(c,r.count,{ordinal:!1}):"",R=T&&!r.ordinal&&r.count===0,P=R&&r[`defaultValue${this.options.pluralSeparator}zero`]||r[`defaultValue${C}`]||r[`defaultValue${V}`]||r.defaultValue;let E=h;S&&!h&&O&&(E=P);const B=eh(E),y=Object.prototype.toString.apply(E);if(S&&E&&B&&f.indexOf(y)<0&&!(pe(g)&&Array.isArray(E))){if(!r.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const A=this.options.returnedObjectHandler?this.options.returnedObjectHandler(p,E,{...r,ns:i}):`key '${o} (${this.language})' returned an object instead of string.`;return a?(d.res=A,d.usedParams=this.getUsedParamsDetails(r),d):A}if(s){const A=Array.isArray(E),z=A?[]:{},I=A?m:p;for(const G in E)if(Object.prototype.hasOwnProperty.call(E,G)){const re=`${I}${s}${G}`;O&&!h?z[G]=this.translate(re,{...r,defaultValue:eh(P)?P[G]:void 0,joinArrays:!1,ns:i}):z[G]=this.translate(re,{...r,joinArrays:!1,ns:i}),z[G]===re&&(z[G]=E[G])}h=z}}else if(S&&pe(g)&&Array.isArray(h))h=h.join(g),h&&(h=this.extendTranslation(h,t,r,n));else{let A=!1,z=!1;!this.isValidLookup(h)&&O&&(A=!0,h=P),this.isValidLookup(h)||(z=!0,h=o);const G=(r.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&z?void 0:h,re=O&&P!==h&&this.options.updateMissing;if(z||A||re){if(this.logger.log(re?"updateKey":"missingKey",c,l,o,re?P:h),s){const se=this.resolve(o,{...r,keySeparator:!1});se&&se.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let te=[];const oe=this.languageUtils.getFallbackCodes(this.options.fallbackLng,r.lng||this.language);if(this.options.saveMissingTo==="fallback"&&oe&&oe[0])for(let se=0;se<oe.length;se++)te.push(oe[se]);else this.options.saveMissingTo==="all"?te=this.languageUtils.toResolveHierarchy(r.lng||this.language):te.push(r.lng||this.language);const Z=(se,ge,ue)=>{var ct;const De=O&&ue!==h?ue:G;this.options.missingKeyHandler?this.options.missingKeyHandler(se,l,ge,De,re,r):(ct=this.backendConnector)!=null&&ct.saveMissing&&this.backendConnector.saveMissing(se,l,ge,De,re,r),this.emit("missingKey",se,l,ge,h)};this.options.saveMissing&&(this.options.saveMissingPlurals&&T?te.forEach(se=>{const ge=this.pluralResolver.getSuffixes(se,r);R&&r[`defaultValue${this.options.pluralSeparator}zero`]&&ge.indexOf(`${this.options.pluralSeparator}zero`)<0&&ge.push(`${this.options.pluralSeparator}zero`),ge.forEach(ue=>{Z([se],o+ue,r[`defaultValue${ue}`]||P)})}):Z(te,o,P))}h=this.extendTranslation(h,t,r,d,n),z&&h===o&&this.options.appendNamespaceToMissingKey&&(h=`${l}:${o}`),(z||A)&&this.options.parseMissingKeyHandler&&(h=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${l}:${o}`:o,A?h:void 0))}return a?(d.res=h,d.usedParams=this.getUsedParamsDetails(r),d):h}extendTranslation(t,r,n,a,s){var c,u;var o=this;if((c=this.i18nFormat)!=null&&c.parse)t=this.i18nFormat.parse(t,{...this.options.interpolation.defaultVariables,...n},n.lng||this.language||a.usedLng,a.usedNS,a.usedKey,{resolved:a});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init({...n,interpolation:{...this.options.interpolation,...n.interpolation}});const d=pe(t)&&(((u=n==null?void 0:n.interpolation)==null?void 0:u.skipOnVariables)!==void 0?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let h;if(d){const m=t.match(this.interpolator.nestingRegexp);h=m&&m.length}let p=n.replace&&!pe(n.replace)?n.replace:n;if(this.options.interpolation.defaultVariables&&(p={...this.options.interpolation.defaultVariables,...p}),t=this.interpolator.interpolate(t,p,n.lng||this.language||a.usedLng,n),d){const m=t.match(this.interpolator.nestingRegexp),f=m&&m.length;h<f&&(n.nest=!1)}!n.lng&&a&&a.res&&(n.lng=this.language||a.usedLng),n.nest!==!1&&(t=this.interpolator.nest(t,function(){for(var m=arguments.length,f=new Array(m),g=0;g<m;g++)f[g]=arguments[g];return(s==null?void 0:s[0])===f[0]&&!n.context?(o.logger.warn(`It seems you are nesting recursively key: ${f[0]} in key: ${r[0]}`),null):o.translate(...f,r)},n)),n.interpolation&&this.interpolator.reset()}const i=n.postProcess||this.options.postProcess,l=pe(i)?[i]:i;return t!=null&&(l!=null&&l.length)&&n.applyPostProcessor!==!1&&(t=Sm.handle(l,t,r,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...a,usedParams:this.getUsedParamsDetails(n)},...n}:n,this)),t}resolve(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n,a,s,o,i;return pe(t)&&(t=[t]),t.forEach(l=>{if(this.isValidLookup(n))return;const c=this.extractFromKey(l,r),u=c.key;a=u;let d=c.namespaces;this.options.fallbackNS&&(d=d.concat(this.options.fallbackNS));const h=r.count!==void 0&&!pe(r.count),p=h&&!r.ordinal&&r.count===0,m=r.context!==void 0&&(pe(r.context)||typeof r.context=="number")&&r.context!=="",f=r.lngs?r.lngs:this.languageUtils.toResolveHierarchy(r.lng||this.language,r.fallbackLng);d.forEach(g=>{var S,T;this.isValidLookup(n)||(i=g,!Zd[`${f[0]}-${g}`]&&((S=this.utils)!=null&&S.hasLoadedNamespace)&&!((T=this.utils)!=null&&T.hasLoadedNamespace(i))&&(Zd[`${f[0]}-${g}`]=!0,this.logger.warn(`key "${a}" for languages "${f.join(", ")}" won't get resolved as namespace "${i}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),f.forEach(O=>{var R;if(this.isValidLookup(n))return;o=O;const C=[u];if((R=this.i18nFormat)!=null&&R.addLookupKeys)this.i18nFormat.addLookupKeys(C,u,O,g,r);else{let P;h&&(P=this.pluralResolver.getSuffix(O,r.count,r));const E=`${this.options.pluralSeparator}zero`,B=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(h&&(C.push(u+P),r.ordinal&&P.indexOf(B)===0&&C.push(u+P.replace(B,this.options.pluralSeparator)),p&&C.push(u+E)),m){const y=`${u}${this.options.contextSeparator}${r.context}`;C.push(y),h&&(C.push(y+P),r.ordinal&&P.indexOf(B)===0&&C.push(y+P.replace(B,this.options.pluralSeparator)),p&&C.push(y+E))}}let V;for(;V=C.pop();)this.isValidLookup(n)||(s=V,n=this.getResource(O,g,V,r))}))})}),{res:n,usedKey:a,exactUsedKey:s,usedLng:o,usedNS:i}}isValidLookup(t){return t!==void 0&&!(!this.options.returnNull&&t===null)&&!(!this.options.returnEmptyString&&t==="")}getResource(t,r,n){var s;let a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return(s=this.i18nFormat)!=null&&s.getResource?this.i18nFormat.getResource(t,r,n,a):this.resourceStore.getResource(t,r,n,a)}getUsedParamsDetails(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const r=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],n=t.replace&&!pe(t.replace);let a=n?t.replace:t;if(n&&typeof t.count<"u"&&(a.count=t.count),this.options.interpolation.defaultVariables&&(a={...this.options.interpolation.defaultVariables,...a}),!n){a={...a};for(const s of r)delete a[s]}return a}static hasDefaultValue(t){const r="defaultValue";for(const n in t)if(Object.prototype.hasOwnProperty.call(t,n)&&r===n.substring(0,r.length)&&t[n]!==void 0)return!0;return!1}}class th{constructor(t){this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=Yt.create("languageUtils")}getScriptPartFromCode(t){if(t=bo(t),!t||t.indexOf("-")<0)return null;const r=t.split("-");return r.length===2||(r.pop(),r[r.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(r.join("-"))}getLanguagePartFromCode(t){if(t=bo(t),!t||t.indexOf("-")<0)return t;const r=t.split("-");return this.formatLanguageCode(r[0])}formatLanguageCode(t){if(pe(t)&&t.indexOf("-")>-1){let r;try{r=Intl.getCanonicalLocales(t)[0]}catch{}return r&&this.options.lowerCaseLng&&(r=r.toLowerCase()),r||(this.options.lowerCaseLng?t.toLowerCase():t)}return this.options.cleanCode||this.options.lowerCaseLng?t.toLowerCase():t}isSupportedCode(t){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(t=this.getLanguagePartFromCode(t)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(t)>-1}getBestMatchFromCodes(t){if(!t)return null;let r;return t.forEach(n=>{if(r)return;const a=this.formatLanguageCode(n);(!this.options.supportedLngs||this.isSupportedCode(a))&&(r=a)}),!r&&this.options.supportedLngs&&t.forEach(n=>{if(r)return;const a=this.getLanguagePartFromCode(n);if(this.isSupportedCode(a))return r=a;r=this.options.supportedLngs.find(s=>{if(s===a)return s;if(!(s.indexOf("-")<0&&a.indexOf("-")<0)&&(s.indexOf("-")>0&&a.indexOf("-")<0&&s.substring(0,s.indexOf("-"))===a||s.indexOf(a)===0&&a.length>1))return s})}),r||(r=this.getFallbackCodes(this.options.fallbackLng)[0]),r}getFallbackCodes(t,r){if(!t)return[];if(typeof t=="function"&&(t=t(r)),pe(t)&&(t=[t]),Array.isArray(t))return t;if(!r)return t.default||[];let n=t[r];return n||(n=t[this.getScriptPartFromCode(r)]),n||(n=t[this.formatLanguageCode(r)]),n||(n=t[this.getLanguagePartFromCode(r)]),n||(n=t.default),n||[]}toResolveHierarchy(t,r){const n=this.getFallbackCodes(r||this.options.fallbackLng||[],t),a=[],s=o=>{o&&(this.isSupportedCode(o)?a.push(o):this.logger.warn(`rejecting language code not found in supportedLngs: ${o}`))};return pe(t)&&(t.indexOf("-")>-1||t.indexOf("_")>-1)?(this.options.load!=="languageOnly"&&s(this.formatLanguageCode(t)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&s(this.getScriptPartFromCode(t)),this.options.load!=="currentOnly"&&s(this.getLanguagePartFromCode(t))):pe(t)&&s(this.formatLanguageCode(t)),n.forEach(o=>{a.indexOf(o)<0&&s(this.formatLanguageCode(o))}),a}}const rh={zero:0,one:1,two:2,few:3,many:4,other:5},nh={select:e=>e===1?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})};class sP{constructor(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.languageUtils=t,this.options=r,this.logger=Yt.create("pluralResolver"),this.pluralRulesCache={}}addRule(t,r){this.rules[t]=r}clearCache(){this.pluralRulesCache={}}getRule(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const n=bo(t==="dev"?"en":t),a=r.ordinal?"ordinal":"cardinal",s=JSON.stringify({cleanedCode:n,type:a});if(s in this.pluralRulesCache)return this.pluralRulesCache[s];let o;try{o=new Intl.PluralRules(n,{type:a})}catch{if(!Intl)return this.logger.error("No Intl support, please use an Intl polyfill!"),nh;if(!t.match(/-|_/))return nh;const l=this.languageUtils.getLanguagePartFromCode(t);o=this.getRule(l,r)}return this.pluralRulesCache[s]=o,o}needsPlural(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=this.getRule(t,r);return n||(n=this.getRule("dev",r)),(n==null?void 0:n.resolvedOptions().pluralCategories.length)>1}getPluralFormsOfKey(t,r){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.getSuffixes(t,n).map(a=>`${r}${a}`)}getSuffixes(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=this.getRule(t,r);return n||(n=this.getRule("dev",r)),n?n.resolvedOptions().pluralCategories.sort((a,s)=>rh[a]-rh[s]).map(a=>`${this.options.prepend}${r.ordinal?`ordinal${this.options.prepend}`:""}${a}`):[]}getSuffix(t,r){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const a=this.getRule(t,n);return a?`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:""}${a.select(r)}`:(this.logger.warn(`no plural rule found for: ${t}`),this.getSuffix("dev",r,n))}}const ah=function(e,t,r){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:".",a=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,s=QC(e,t,r);return!s&&a&&pe(r)&&(s=Il(e,r,n),s===void 0&&(s=Il(t,r,n))),s},Qi=e=>e.replace(/\$/g,"$$$$");class oP{constructor(){var r;let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=Yt.create("interpolator"),this.options=t,this.format=((r=t==null?void 0:t.interpolation)==null?void 0:r.format)||(n=>n),this.init(t)}init(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};t.interpolation||(t.interpolation={escapeValue:!0});const{escape:r,escapeValue:n,useRawValueToEscape:a,prefix:s,prefixEscaped:o,suffix:i,suffixEscaped:l,formatSeparator:c,unescapeSuffix:u,unescapePrefix:d,nestingPrefix:h,nestingPrefixEscaped:p,nestingSuffix:m,nestingSuffixEscaped:f,nestingOptionsSeparator:g,maxReplaces:S,alwaysFormat:T}=t.interpolation;this.escape=r!==void 0?r:ZC,this.escapeValue=n!==void 0?n:!0,this.useRawValueToEscape=a!==void 0?a:!1,this.prefix=s?xn(s):o||"{{",this.suffix=i?xn(i):l||"}}",this.formatSeparator=c||",",this.unescapePrefix=u?"":d||"-",this.unescapeSuffix=this.unescapePrefix?"":u||"",this.nestingPrefix=h?xn(h):p||xn("$t("),this.nestingSuffix=m?xn(m):f||xn(")"),this.nestingOptionsSeparator=g||",",this.maxReplaces=S||1e3,this.alwaysFormat=T!==void 0?T:!1,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const t=(r,n)=>(r==null?void 0:r.source)===n?(r.lastIndex=0,r):new RegExp(n,"g");this.regexp=t(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=t(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=t(this.nestingRegexp,`${this.nestingPrefix}(.+?)${this.nestingSuffix}`)}interpolate(t,r,n,a){var p;let s,o,i;const l=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},c=m=>{if(m.indexOf(this.formatSeparator)<0){const T=ah(r,l,m,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(T,void 0,n,{...a,...r,interpolationkey:m}):T}const f=m.split(this.formatSeparator),g=f.shift().trim(),S=f.join(this.formatSeparator).trim();return this.format(ah(r,l,g,this.options.keySeparator,this.options.ignoreJSONStructure),S,n,{...a,...r,interpolationkey:g})};this.resetRegExp();const u=(a==null?void 0:a.missingInterpolationHandler)||this.options.missingInterpolationHandler,d=((p=a==null?void 0:a.interpolation)==null?void 0:p.skipOnVariables)!==void 0?a.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:m=>Qi(m)},{regex:this.regexp,safeValue:m=>this.escapeValue?Qi(this.escape(m)):Qi(m)}].forEach(m=>{for(i=0;s=m.regex.exec(t);){const f=s[1].trim();if(o=c(f),o===void 0)if(typeof u=="function"){const S=u(t,s,a);o=pe(S)?S:""}else if(a&&Object.prototype.hasOwnProperty.call(a,f))o="";else if(d){o=s[0];continue}else this.logger.warn(`missed to pass in variable ${f} for interpolating ${t}`),o="";else!pe(o)&&!this.useRawValueToEscape&&(o=Wd(o));const g=m.safeValue(o);if(t=t.replace(s[0],g),d?(m.regex.lastIndex+=o.length,m.regex.lastIndex-=s[0].length):m.regex.lastIndex=0,i++,i>=this.maxReplaces)break}}),t}nest(t,r){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},a,s,o;const i=(l,c)=>{const u=this.nestingOptionsSeparator;if(l.indexOf(u)<0)return l;const d=l.split(new RegExp(`${u}[ ]*{`));let h=`{${d[1]}`;l=d[0],h=this.interpolate(h,o);const p=h.match(/'/g),m=h.match(/"/g);(((p==null?void 0:p.length)??0)%2===0&&!m||m.length%2!==0)&&(h=h.replace(/'/g,'"'));try{o=JSON.parse(h),c&&(o={...c,...o})}catch(f){return this.logger.warn(`failed parsing options string in nesting for key ${l}`,f),`${l}${u}${h}`}return o.defaultValue&&o.defaultValue.indexOf(this.prefix)>-1&&delete o.defaultValue,l};for(;a=this.nestingRegexp.exec(t);){let l=[];o={...n},o=o.replace&&!pe(o.replace)?o.replace:o,o.applyPostProcessor=!1,delete o.defaultValue;let c=!1;if(a[0].indexOf(this.formatSeparator)!==-1&&!/{.*}/.test(a[1])){const u=a[1].split(this.formatSeparator).map(d=>d.trim());a[1]=u.shift(),l=u,c=!0}if(s=r(i.call(this,a[1].trim(),o),o),s&&a[0]===t&&!pe(s))return s;pe(s)||(s=Wd(s)),s||(this.logger.warn(`missed to resolve ${a[1]} for nesting ${t}`),s=""),c&&(s=l.reduce((u,d)=>this.format(u,d,n.lng,{...n,interpolationkey:a[1].trim()}),s.trim())),t=t.replace(a[0],s),this.regexp.lastIndex=0}return t}}const iP=e=>{let t=e.toLowerCase().trim();const r={};if(e.indexOf("(")>-1){const n=e.split("(");t=n[0].toLowerCase().trim();const a=n[1].substring(0,n[1].length-1);t==="currency"&&a.indexOf(":")<0?r.currency||(r.currency=a.trim()):t==="relativetime"&&a.indexOf(":")<0?r.range||(r.range=a.trim()):a.split(";").forEach(o=>{if(o){const[i,...l]=o.split(":"),c=l.join(":").trim().replace(/^'+|'+$/g,""),u=i.trim();r[u]||(r[u]=c),c==="false"&&(r[u]=!1),c==="true"&&(r[u]=!0),isNaN(c)||(r[u]=parseInt(c,10))}})}return{formatName:t,formatOptions:r}},Sn=e=>{const t={};return(r,n,a)=>{let s=a;a&&a.interpolationkey&&a.formatParams&&a.formatParams[a.interpolationkey]&&a[a.interpolationkey]&&(s={...s,[a.interpolationkey]:void 0});const o=n+JSON.stringify(s);let i=t[o];return i||(i=e(bo(n),a),t[o]=i),i(r)}};class lP{constructor(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=Yt.create("formatter"),this.options=t,this.formats={number:Sn((r,n)=>{const a=new Intl.NumberFormat(r,{...n});return s=>a.format(s)}),currency:Sn((r,n)=>{const a=new Intl.NumberFormat(r,{...n,style:"currency"});return s=>a.format(s)}),datetime:Sn((r,n)=>{const a=new Intl.DateTimeFormat(r,{...n});return s=>a.format(s)}),relativetime:Sn((r,n)=>{const a=new Intl.RelativeTimeFormat(r,{...n});return s=>a.format(s,n.range||"day")}),list:Sn((r,n)=>{const a=new Intl.ListFormat(r,{...n});return s=>a.format(s)})},this.init(t)}init(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};this.formatSeparator=r.interpolation.formatSeparator||","}add(t,r){this.formats[t.toLowerCase().trim()]=r}addCached(t,r){this.formats[t.toLowerCase().trim()]=Sn(r)}format(t,r,n){let a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const s=r.split(this.formatSeparator);if(s.length>1&&s[0].indexOf("(")>1&&s[0].indexOf(")")<0&&s.find(i=>i.indexOf(")")>-1)){const i=s.findIndex(l=>l.indexOf(")")>-1);s[0]=[s[0],...s.splice(1,i)].join(this.formatSeparator)}return s.reduce((i,l)=>{var d;const{formatName:c,formatOptions:u}=iP(l);if(this.formats[c]){let h=i;try{const p=((d=a==null?void 0:a.formatParams)==null?void 0:d[a.interpolationkey])||{},m=p.locale||p.lng||a.locale||a.lng||n;h=this.formats[c](i,m,{...u,...a,...p})}catch(p){this.logger.warn(p)}return h}else this.logger.warn(`there was no format function for ${c}`);return i},t)}}const cP=(e,t)=>{e.pending[t]!==void 0&&(delete e.pending[t],e.pendingCount--)};class uP extends ni{constructor(t,r,n){var s,o;let a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};super(),this.backend=t,this.store=r,this.services=n,this.languageUtils=n.languageUtils,this.options=a,this.logger=Yt.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=a.maxParallelReads||10,this.readingCalls=0,this.maxRetries=a.maxRetries>=0?a.maxRetries:5,this.retryTimeout=a.retryTimeout>=1?a.retryTimeout:350,this.state={},this.queue=[],(o=(s=this.backend)==null?void 0:s.init)==null||o.call(s,n,a.backend,a)}queueLoad(t,r,n,a){const s={},o={},i={},l={};return t.forEach(c=>{let u=!0;r.forEach(d=>{const h=`${c}|${d}`;!n.reload&&this.store.hasResourceBundle(c,d)?this.state[h]=2:this.state[h]<0||(this.state[h]===1?o[h]===void 0&&(o[h]=!0):(this.state[h]=1,u=!1,o[h]===void 0&&(o[h]=!0),s[h]===void 0&&(s[h]=!0),l[d]===void 0&&(l[d]=!0)))}),u||(i[c]=!0)}),(Object.keys(s).length||Object.keys(o).length)&&this.queue.push({pending:o,pendingCount:Object.keys(o).length,loaded:{},errors:[],callback:a}),{toLoad:Object.keys(s),pending:Object.keys(o),toLoadLanguages:Object.keys(i),toLoadNamespaces:Object.keys(l)}}loaded(t,r,n){const a=t.split("|"),s=a[0],o=a[1];r&&this.emit("failedLoading",s,o,r),!r&&n&&this.store.addResourceBundle(s,o,n,void 0,void 0,{skipCopy:!0}),this.state[t]=r?-1:2,r&&n&&(this.state[t]=0);const i={};this.queue.forEach(l=>{YC(l.loaded,[s],o),cP(l,t),r&&l.errors.push(r),l.pendingCount===0&&!l.done&&(Object.keys(l.loaded).forEach(c=>{i[c]||(i[c]={});const u=l.loaded[c];u.length&&u.forEach(d=>{i[c][d]===void 0&&(i[c][d]=!0)})}),l.done=!0,l.errors.length?l.callback(l.errors):l.callback())}),this.emit("loaded",i),this.queue=this.queue.filter(l=>!l.done)}read(t,r,n){let a=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:this.retryTimeout,o=arguments.length>5?arguments[5]:void 0;if(!t.length)return o(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:t,ns:r,fcName:n,tried:a,wait:s,callback:o});return}this.readingCalls++;const i=(c,u)=>{if(this.readingCalls--,this.waitingReads.length>0){const d=this.waitingReads.shift();this.read(d.lng,d.ns,d.fcName,d.tried,d.wait,d.callback)}if(c&&u&&a<this.maxRetries){setTimeout(()=>{this.read.call(this,t,r,n,a+1,s*2,o)},s);return}o(c,u)},l=this.backend[n].bind(this.backend);if(l.length===2){try{const c=l(t,r);c&&typeof c.then=="function"?c.then(u=>i(null,u)).catch(i):i(null,c)}catch(c){i(c)}return}return l(t,r,i)}prepareLoading(t,r){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},a=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),a&&a();pe(t)&&(t=this.languageUtils.toResolveHierarchy(t)),pe(r)&&(r=[r]);const s=this.queueLoad(t,r,n,a);if(!s.toLoad.length)return s.pending.length||a(),null;s.toLoad.forEach(o=>{this.loadOne(o)})}load(t,r,n){this.prepareLoading(t,r,{},n)}reload(t,r,n){this.prepareLoading(t,r,{reload:!0},n)}loadOne(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";const n=t.split("|"),a=n[0],s=n[1];this.read(a,s,"read",void 0,void 0,(o,i)=>{o&&this.logger.warn(`${r}loading namespace ${s} for language ${a} failed`,o),!o&&i&&this.logger.log(`${r}loaded namespace ${s} for language ${a}`,i),this.loaded(t,o,i)})}saveMissing(t,r,n,a,s){var l,c,u,d,h;let o=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{},i=arguments.length>6&&arguments[6]!==void 0?arguments[6]:()=>{};if((c=(l=this.services)==null?void 0:l.utils)!=null&&c.hasLoadedNamespace&&!((d=(u=this.services)==null?void 0:u.utils)!=null&&d.hasLoadedNamespace(r))){this.logger.warn(`did not save key "${n}" as the namespace "${r}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");return}if(!(n==null||n==="")){if((h=this.backend)!=null&&h.create){const p={...o,isUpdate:s},m=this.backend.create.bind(this.backend);if(m.length<6)try{let f;m.length===5?f=m(t,r,n,a,p):f=m(t,r,n,a),f&&typeof f.then=="function"?f.then(g=>i(null,g)).catch(i):i(null,f)}catch(f){i(f)}else m(t,r,n,a,i,p)}!t||!t[0]||this.store.addResource(t[0],r,n,a)}}}const sh=()=>({debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if(typeof e[1]=="object"&&(t=e[1]),pe(e[1])&&(t.defaultValue=e[1]),pe(e[2])&&(t.tDescription=e[2]),typeof e[2]=="object"||typeof e[3]=="object"){const r=e[3]||e[2];Object.keys(r).forEach(n=>{t[n]=r[n]})}return t},interpolation:{escapeValue:!0,format:e=>e,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}),oh=e=>{var t,r;return pe(e.ns)&&(e.ns=[e.ns]),pe(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),pe(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),((r=(t=e.supportedLngs)==null?void 0:t.indexOf)==null?void 0:r.call(t,"cimode"))<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),typeof e.initImmediate=="boolean"&&(e.initAsync=e.initImmediate),e},Ps=()=>{},dP=e=>{Object.getOwnPropertyNames(Object.getPrototypeOf(e)).forEach(r=>{typeof e[r]=="function"&&(e[r]=e[r].bind(e))})};class qa extends ni{constructor(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;if(super(),this.options=oh(t),this.services={},this.logger=Yt,this.modules={external:[]},dP(this),r&&!this.isInitialized&&!t.isClone){if(!this.options.initAsync)return this.init(t,r),this;setTimeout(()=>{this.init(t,r)},0)}}init(){var t=this;let r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0;this.isInitializing=!0,typeof r=="function"&&(n=r,r={}),r.defaultNS==null&&r.ns&&(pe(r.ns)?r.defaultNS=r.ns:r.ns.indexOf("translation")<0&&(r.defaultNS=r.ns[0]));const a=sh();this.options={...a,...this.options,...oh(r)},this.options.interpolation={...a.interpolation,...this.options.interpolation},r.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=r.keySeparator),r.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=r.nsSeparator);const s=u=>u?typeof u=="function"?new u:u:null;if(!this.options.isClone){this.modules.logger?Yt.init(s(this.modules.logger),this.options):Yt.init(null,this.options);let u;this.modules.formatter?u=this.modules.formatter:u=lP;const d=new th(this.options);this.store=new Xd(this.options.resources,this.options);const h=this.services;h.logger=Yt,h.resourceStore=this.store,h.languageUtils=d,h.pluralResolver=new sP(d,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),u&&(!this.options.interpolation.format||this.options.interpolation.format===a.interpolation.format)&&(h.formatter=s(u),h.formatter.init(h,this.options),this.options.interpolation.format=h.formatter.format.bind(h.formatter)),h.interpolator=new oP(this.options),h.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},h.backendConnector=new uP(s(this.modules.backend),h.resourceStore,h,this.options),h.backendConnector.on("*",function(p){for(var m=arguments.length,f=new Array(m>1?m-1:0),g=1;g<m;g++)f[g-1]=arguments[g];t.emit(p,...f)}),this.modules.languageDetector&&(h.languageDetector=s(this.modules.languageDetector),h.languageDetector.init&&h.languageDetector.init(h,this.options.detection,this.options)),this.modules.i18nFormat&&(h.i18nFormat=s(this.modules.i18nFormat),h.i18nFormat.init&&h.i18nFormat.init(this)),this.translator=new xo(this.services,this.options),this.translator.on("*",function(p){for(var m=arguments.length,f=new Array(m>1?m-1:0),g=1;g<m;g++)f[g-1]=arguments[g];t.emit(p,...f)}),this.modules.external.forEach(p=>{p.init&&p.init(this)})}if(this.format=this.options.interpolation.format,n||(n=Ps),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const u=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);u.length>0&&u[0]!=="dev"&&(this.options.lng=u[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined"),["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(u=>{this[u]=function(){return t.store[u](...arguments)}}),["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(u=>{this[u]=function(){return t.store[u](...arguments),t}});const l=ya(),c=()=>{const u=(d,h)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),l.resolve(h),n(d,h)};if(this.languages&&!this.isInitialized)return u(null,this.t.bind(this));this.changeLanguage(this.options.lng,u)};return this.options.resources||!this.options.initAsync?c():setTimeout(c,0),l}loadResources(t){var s,o;let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Ps;const a=pe(t)?t:this.language;if(typeof t=="function"&&(n=t),!this.options.resources||this.options.partialBundledLanguages){if((a==null?void 0:a.toLowerCase())==="cimode"&&(!this.options.preload||this.options.preload.length===0))return n();const i=[],l=c=>{if(!c||c==="cimode")return;this.services.languageUtils.toResolveHierarchy(c).forEach(d=>{d!=="cimode"&&i.indexOf(d)<0&&i.push(d)})};a?l(a):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(u=>l(u)),(o=(s=this.options.preload)==null?void 0:s.forEach)==null||o.call(s,c=>l(c)),this.services.backendConnector.load(i,this.options.ns,c=>{!c&&!this.resolvedLanguage&&this.language&&this.setResolvedLanguage(this.language),n(c)})}else n(null)}reloadResources(t,r,n){const a=ya();return typeof t=="function"&&(n=t,t=void 0),typeof r=="function"&&(n=r,r=void 0),t||(t=this.languages),r||(r=this.options.ns),n||(n=Ps),this.services.backendConnector.reload(t,r,s=>{a.resolve(),n(s)}),a}use(t){if(!t)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!t.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return t.type==="backend"&&(this.modules.backend=t),(t.type==="logger"||t.log&&t.warn&&t.error)&&(this.modules.logger=t),t.type==="languageDetector"&&(this.modules.languageDetector=t),t.type==="i18nFormat"&&(this.modules.i18nFormat=t),t.type==="postProcessor"&&Sm.addPostProcessor(t),t.type==="formatter"&&(this.modules.formatter=t),t.type==="3rdParty"&&this.modules.external.push(t),this}setResolvedLanguage(t){if(!(!t||!this.languages)&&!(["cimode","dev"].indexOf(t)>-1))for(let r=0;r<this.languages.length;r++){const n=this.languages[r];if(!(["cimode","dev"].indexOf(n)>-1)&&this.store.hasLanguageSomeTranslations(n)){this.resolvedLanguage=n;break}}}changeLanguage(t,r){var n=this;this.isLanguageChangingTo=t;const a=ya();this.emit("languageChanging",t);const s=l=>{this.language=l,this.languages=this.services.languageUtils.toResolveHierarchy(l),this.resolvedLanguage=void 0,this.setResolvedLanguage(l)},o=(l,c)=>{c?(s(c),this.translator.changeLanguage(c),this.isLanguageChangingTo=void 0,this.emit("languageChanged",c),this.logger.log("languageChanged",c)):this.isLanguageChangingTo=void 0,a.resolve(function(){return n.t(...arguments)}),r&&r(l,function(){return n.t(...arguments)})},i=l=>{var u,d;!t&&!l&&this.services.languageDetector&&(l=[]);const c=pe(l)?l:this.services.languageUtils.getBestMatchFromCodes(l);c&&(this.language||s(c),this.translator.language||this.translator.changeLanguage(c),(d=(u=this.services.languageDetector)==null?void 0:u.cacheUserLanguage)==null||d.call(u,c)),this.loadResources(c,h=>{o(h,c)})};return!t&&this.services.languageDetector&&!this.services.languageDetector.async?i(this.services.languageDetector.detect()):!t&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(i):this.services.languageDetector.detect(i):i(t),a}getFixedT(t,r,n){var a=this;const s=function(o,i){let l;if(typeof i!="object"){for(var c=arguments.length,u=new Array(c>2?c-2:0),d=2;d<c;d++)u[d-2]=arguments[d];l=a.options.overloadTranslationOptionHandler([o,i].concat(u))}else l={...i};l.lng=l.lng||s.lng,l.lngs=l.lngs||s.lngs,l.ns=l.ns||s.ns,l.keyPrefix!==""&&(l.keyPrefix=l.keyPrefix||n||s.keyPrefix);const h=a.options.keySeparator||".";let p;return l.keyPrefix&&Array.isArray(o)?p=o.map(m=>`${l.keyPrefix}${h}${m}`):p=l.keyPrefix?`${l.keyPrefix}${h}${o}`:o,a.t(p,l)};return pe(t)?s.lng=t:s.lngs=t,s.ns=r,s.keyPrefix=n,s}t(){var a;for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return(a=this.translator)==null?void 0:a.translate(...r)}exists(){var a;for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return(a=this.translator)==null?void 0:a.exists(...r)}setDefaultNamespace(t){this.options.defaultNS=t}hasLoadedNamespace(t){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const n=r.lng||this.resolvedLanguage||this.languages[0],a=this.options?this.options.fallbackLng:!1,s=this.languages[this.languages.length-1];if(n.toLowerCase()==="cimode")return!0;const o=(i,l)=>{const c=this.services.backendConnector.state[`${i}|${l}`];return c===-1||c===0||c===2};if(r.precheck){const i=r.precheck(this,o);if(i!==void 0)return i}return!!(this.hasResourceBundle(n,t)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||o(n,t)&&(!a||o(s,t)))}loadNamespaces(t,r){const n=ya();return this.options.ns?(pe(t)&&(t=[t]),t.forEach(a=>{this.options.ns.indexOf(a)<0&&this.options.ns.push(a)}),this.loadResources(a=>{n.resolve(),r&&r(a)}),n):(r&&r(),Promise.resolve())}loadLanguages(t,r){const n=ya();pe(t)&&(t=[t]);const a=this.options.preload||[],s=t.filter(o=>a.indexOf(o)<0&&this.services.languageUtils.isSupportedCode(o));return s.length?(this.options.preload=a.concat(s),this.loadResources(o=>{n.resolve(),r&&r(o)}),n):(r&&r(),Promise.resolve())}dir(t){var a,s;if(t||(t=this.resolvedLanguage||(((a=this.languages)==null?void 0:a.length)>0?this.languages[0]:this.language)),!t)return"rtl";const r=["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"],n=((s=this.services)==null?void 0:s.languageUtils)||new th(sh());return r.indexOf(n.getLanguagePartFromCode(t))>-1||t.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;return new qa(t,r)}cloneInstance(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Ps;const n=t.forkResourceStore;n&&delete t.forkResourceStore;const a={...this.options,...t,isClone:!0},s=new qa(a);if((t.debug!==void 0||t.prefix!==void 0)&&(s.logger=s.logger.clone(t)),["store","services","language"].forEach(i=>{s[i]=this[i]}),s.services={...this.services},s.services.utils={hasLoadedNamespace:s.hasLoadedNamespace.bind(s)},n){const i=Object.keys(this.store.data).reduce((l,c)=>(l[c]={...this.store.data[c]},Object.keys(l[c]).reduce((u,d)=>(u[d]={...l[c][d]},u),{})),{});s.store=new Xd(i,a),s.services.resourceStore=s.store}return s.translator=new xo(s.services,a),s.translator.on("*",function(i){for(var l=arguments.length,c=new Array(l>1?l-1:0),u=1;u<l;u++)c[u-1]=arguments[u];s.emit(i,...c)}),s.init(a,r),s.translator.options=a,s.translator.backendConnector.services.utils={hasLoadedNamespace:s.hasLoadedNamespace.bind(s)},s}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const lt=qa.createInstance();lt.createInstance=qa.createInstance;lt.createInstance;lt.dir;lt.init;lt.loadResources;lt.reloadResources;lt.use;lt.changeLanguage;lt.getFixedT;lt.t;lt.exists;lt.setDefaultNamespace;lt.hasLoadedNamespace;lt.loadNamespaces;lt.loadLanguages;const hP={"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.
|
|
136
|
+
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."},pP={"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."},Gc=lt.createInstance();Gc.use(uy).init({supportedLngs:["en","de"],resources:{en:{translations:pP},de:{translations:hP}},ns:["translations"],defaultNS:"translations",detection:{order:["navigator","htmlTag"]}});function en(e){return r=>x.jsx(fP,{children:x.jsx(e,{...r})})}const fP=({children:e})=>x.jsx(ze.I18nextProvider,{i18n:Gc,children:e}),mP=en(Je.observer(({onCycleComplete:e,onCycleEnd:t,autoStart:r=!0,variant:n="default",compact:a=!1,className:s})=>{var P;const o=W.useTheme(),{t:i}=ze.useTranslation(),[l,c]=ae.useState(0),[u,d]=ae.useState(0),[h,p]=ae.useState(!1),[m,f]=ae.useState(!1),g=ae.useRef(null),S=ae.useCallback((E,B=0)=>{console.log(`Starting new cycle with ${E} seconds (${B} seconds already elapsed)`),d(E);const y=Math.max(0,E-B);c(y),f(!1),y===0?(console.log("Cycle already completed (elapsed time >= max time)"),p(!1),t&&setTimeout(()=>t(),0)):r?(console.log("Auto-start enabled, starting timer"),p(!0)):console.log("Auto-start disabled, timer set but not started")},[r,t]),T=ae.useCallback(()=>{console.log("Pausing timer"),p(!1),f(!0)},[]),O=ae.useCallback(()=>{m&&l>0&&(console.log("Resuming timer"),p(!0),f(!1))},[m,l]),C=ae.useCallback(()=>m,[m]);ae.useEffect(()=>{let E=!0;const B=setTimeout(()=>{E&&e({startNewCycle:S,pause:T,resume:O,isPaused:C})},0);return()=>{E=!1,clearTimeout(B)}},[e,S,T,O,C]),ae.useEffect(()=>(h&&l>0?g.current=setInterval(()=>{c(E=>E<=1?(p(!1),t&&setTimeout(()=>t(),0),console.log("Cycle completed! Timer reached zero."),0):E-1)},1e3):g.current&&(clearInterval(g.current),g.current=null),()=>{g.current&&clearInterval(g.current)}),[h,l,t]);const V=E=>{const B=Math.floor(E/60),y=E%60;return`${B}:${y.toString().padStart(2,"0")}`},R=u>0?(u-l)/u*100:0;return n==="small"?x.jsxs(W.Box,{className:s,sx:{display:"flex",alignItems:"center",gap:.125},children:[x.jsx(W.Box,{sx:{position:"relative",width:40,height:40,display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"50%",overflow:"visible"},children:x.jsx(go,{width:40,height:40,value:R,valueMin:0,valueMax:100,innerRadius:"70%",outerRadius:"95%",sx:{"& .MuiGauge-valueArc":{fill:o.palette.success.main},"& .MuiGauge-referenceArc":{fill:o.palette.success.main,opacity:.3},"& .MuiGauge-valueText":{display:"none"},"& .MuiGauge-text":{display:"none"},"& text":{display:"none"}}})}),x.jsx(W.Typography,{variant:"body2",sx:{color:o.palette.text.primary,fontSize:"14px"},children:a?V(l):`${V(l)} / ${i("CycleTimer.OfTime.lb",{time:V(u)})}`})]}):x.jsxs(W.Box,{className:s,sx:{position:"relative",width:264,height:264,display:"flex",alignItems:"center",justifyContent:"center"},children:[x.jsx(go,{width:264,height:264,value:R,valueMin:0,valueMax:100,innerRadius:"71%",outerRadius:"90%",sx:{"& .MuiGauge-valueArc":{fill:o.palette.success.main},"& .MuiGauge-referenceArc":{fill:"white",stroke:"transparent"}}}),x.jsxs(W.Box,{sx:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:187,height:187,borderRadius:"50%",backgroundColor:(P=o.palette.backgroundPaperElevation)==null?void 0:P[8],display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",textAlign:"center",gap:1},children:[x.jsx(W.Typography,{variant:"body2",sx:{fontSize:"12px",color:o.palette.text.secondary,marginBottom:.5},children:i("CycleTimer.RemainingTime.lb")}),x.jsx(W.Typography,{variant:"h1",sx:{fontSize:"48px",fontWeight:500,color:o.palette.text.primary,lineHeight:1,marginBottom:.5},children:V(l)}),x.jsx(W.Typography,{variant:"body2",sx:{fontSize:"12px",color:o.palette.text.secondary},children:i("CycleTimer.OfTime.lb",{time:V(u)})})]})]})}));process.env.NODE_ENV!=="production"&&(b.node,b.object.isRequired);function Hc(e){return hb(e)}const jn=Pb({createStyledComponent:Pt("div",{name:"MuiStack",slot:"Root",overridesResolver:(e,t)=>t.root}),useThemeProps:e=>Hc({props:e,name:"MuiStack"})});process.env.NODE_ENV!=="production"&&(jn.propTypes={children:b.node,component:b.elementType,direction:b.oneOfType([b.oneOf(["column-reverse","column","row-reverse","row"]),b.arrayOf(b.oneOf(["column-reverse","column","row-reverse","row"])),b.object]),divider:b.node,spacing:b.oneOfType([b.arrayOf(b.oneOfType([b.number,b.string])),b.number,b.object,b.string]),sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),useFlexGap:b.bool});const gP=({title:e,titleId:t,...r},n)=>F.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?F.createElement("title",{id:t},e):null,F.createElement("g",{id:"JogMinus"},F.createElement("path",{id:"Minus",d:"M0 13V8H21V13H0Z",fill:"white"}))),yP=ae.forwardRef(gP),bP=({title:e,titleId:t,...r},n)=>F.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?F.createElement("title",{id:t},e):null,F.createElement("g",{id:"JogPlus"},F.createElement("g",{id:"Plus"},F.createElement("path",{d:"M0 13V8H8V13H0Z",fill:"white"}),F.createElement("path",{d:"M8 0L13 2.18557e-07L13 21H8L8 0Z",fill:"white"}),F.createElement("path",{d:"M13 13V8H21V13H13Z",fill:"white"})))),vP=ae.forwardRef(bP);function ai(e){ae.useEffect(e,[])}function Om(e){ai(()=>Xe.autorun(e))}function wm(e,t,r){ai(()=>Xe.reaction(e,t,r))}function Yn(e){return ai(()=>{let t;function r(){e(),t=requestAnimationFrame(r)}return t=requestAnimationFrame(r),()=>{cancelAnimationFrame(t)}})}const Ml=en(Je.observer(({colors:e,label:t,getDisplayedValue:r,startJogging:n,stopJogging:a,disabled:s,activeJoggingDirection:o,...i})=>{var O,C,V,R,P,E,B;Yn(()=>{const y=r(),A=h.current;A&&(A.textContent=y)});const l=W.useTheme(),[c,u]=ae.useState(null);ae.useEffect(()=>{s&&T()},[s]);const d=o||c,h=ae.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,m={width:"55px",color:e.color,path:{fill:e.color},alignContent:"center",fontSize:"37px",svg:{pointerEvents:"none"}},f={...m,backgroundColor:(C=e.buttonBackgroundColor)==null?void 0:C.default,":hover":{backgroundColor:(V=e.buttonBackgroundColor)==null?void 0:V.hovered},":active":{backgroundColor:(R=e.buttonBackgroundColor)==null?void 0:R.pressed,color:e.backgroundColor,path:{fill:e.backgroundColor}},":disabled":{backgroundColor:(P=e.buttonBackgroundColor)==null?void 0:P.disabled,"svg path":{fill:l.palette.action.disabled}}},g={...m,backgroundColor:(E=e.buttonBackgroundColor)==null?void 0:E.pressed,color:e.backgroundColor,path:{fill:e.backgroundColor},":disabled":{backgroundColor:(B=e.buttonBackgroundColor)==null?void 0:B.pressed,"svg path":{fill:l.palette.action.disabled}}};function S(y,A){s||y.button===0&&(u(A),n(A))}function T(){u(null),a()}return x.jsxs(jn,{height:"64px",direction:"row",justifyContent:"center",...i,children:[x.jsx(W.IconButton,{disabled:s,disableRipple:!0,onPointerDown:y=>S(y,"-"),onPointerUp:T,onPointerOut:T,size:"large",sx:{...d==="-"?g:f,borderRadius:"16px 0px 0px 16px",borderLeft:`2px solid ${p??"#fff"}`,borderBottom:`2px solid ${p??"#fff"}`,borderTop:`2px solid ${p??"#fff"}`},children:x.jsx(yP,{})}),x.jsxs(jn,{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:[x.jsx(jn,{height:"22px",direction:"row",alignItems:"center",justifyItems:"center",spacing:1,sx:{userSelect:"none",color:e.color,".MuiTypography-root":{fontWeight:700,...s?{color:l.palette.action.disabled}:{}},...s?{"svg path":{fill:l.palette.action.disabled}}:{}},children:t}),x.jsx(W.Typography,{height:"22px",sx:{fontSize:"15px",color:s?l.palette.action.disabled:e.color,fontWeight:700},ref:h,children:r()})]}),x.jsx(W.IconButton,{disableRipple:!0,disabled:s,onPointerDown:y=>S(y,"+"),onPointerUp:T,onPointerOut:T,size:"large",sx:{...d==="+"?g:f,borderRadius:"0px 16px 16px 0px",borderRight:`2px solid ${p??"#fff"}`,borderBottom:`2px solid ${p??"#fff"}`,borderTop:`2px solid ${p??"#fff"}`},children:x.jsx(vP,{})})]})})),tn=pb;function xP(e){return ts("MuiSvgIcon",e)}$p("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const SP=e=>{const{color:t,fontSize:r,classes:n}=e,a={root:["root",t!=="inherit"&&`color${dt(t)}`,`fontSize${dt(r)}`]};return ac(a,xP,n)},OP=Pt("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.color!=="inherit"&&t[`color${dt(r.color)}`],t[`fontSize${dt(r.fontSize)}`]]}})(tn(({theme:e})=>{var t,r,n,a,s,o,i,l,c,u,d,h,p,m;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:f=>!f.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:((o=(s=e.typography)==null?void 0:s.pxToRem)==null?void 0:o.call(s,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(([,f])=>f&&f.main).map(([f])=>{var g,S;return{props:{color:f},style:{color:(S=(g=(e.vars??e).palette)==null?void 0:g[f])==null?void 0:S.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:(m=(p=(e.vars??e).palette)==null?void 0:p.action)==null?void 0:m.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),So=F.forwardRef(function(t,r){const n=Hc({props:t,name:"MuiSvgIcon"}),{children:a,className:s,color:o="inherit",component:i="svg",fontSize:l="medium",htmlColor:c,inheritViewBox:u=!1,titleAccess:d,viewBox:h="0 0 24 24",...p}=n,m=F.isValidElement(a)&&a.type==="svg",f={...n,color:o,component:i,fontSize:l,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:h,hasSvgAsChild:m},g={};u||(g.viewBox=h);const S=SP(f);return x.jsxs(OP,{as:i,className:Nt(S.root,s),focusable:"false",color:c,"aria-hidden":d?void 0:!0,role:d?"img":void 0,ref:r,...g,...p,...m&&a.props,ownerState:f,children:[m?a.props.children:a,d?x.jsx("title",{children:d}):null]})});process.env.NODE_ENV!=="production"&&(So.propTypes={children:b.node,classes:b.object,className:b.string,color:b.oneOfType([b.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),b.string]),component:b.elementType,fontSize:b.oneOfType([b.oneOf(["inherit","large","medium","small"]),b.string]),htmlColor:b.string,inheritViewBox:b.bool,shapeRendering:b.string,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),titleAccess:b.string,viewBox:b.string});So.muiName="SvgIcon";function si(e,t){function r(n,a){return x.jsx(So,{"data-testid":`${t}Icon`,ref:a,...n,children:e})}return process.env.NODE_ENV!=="production"&&(r.displayName=`${t}Icon`),r.muiName=So.muiName,F.memo(F.forwardRef(r))}const wP=si(x.jsx("path",{d:"M15.41 7.41 14 6l-6 6 6 6 1.41-1.41L10.83 12z"}),"ChevronLeft"),CP=si(x.jsx("path",{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}),"ChevronRight");function Hr(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Cm=typeof global=="object"&&global&&global.Object===Object&&global,PP=typeof self=="object"&&self&&self.Object===Object&&self,Zt=Cm||PP||Function("return this")(),Xi=function(){return Zt.Date.now()},RP=/\s/;function TP(e){for(var t=e.length;t--&&RP.test(e.charAt(t)););return t}var AP=/^\s+/;function VP(e){return e&&e.slice(0,TP(e)+1).replace(AP,"")}var Tr=Zt.Symbol,Pm=Object.prototype,EP=Pm.hasOwnProperty,_P=Pm.toString,ba=Tr?Tr.toStringTag:void 0;function IP(e){var t=EP.call(e,ba),r=e[ba];try{e[ba]=void 0;var n=!0}catch{}var a=_P.call(e);return n&&(t?e[ba]=r:delete e[ba]),a}var MP=Object.prototype,$P=MP.toString;function jP(e){return $P.call(e)}var kP="[object Null]",LP="[object Undefined]",ih=Tr?Tr.toStringTag:void 0;function rn(e){return e==null?e===void 0?LP:kP:ih&&ih in Object(e)?IP(e):jP(e)}function qr(e){return e!=null&&typeof e=="object"}var UP="[object Symbol]";function oi(e){return typeof e=="symbol"||qr(e)&&rn(e)==UP}var lh=NaN,DP=/^[-+]0x[0-9a-f]+$/i,NP=/^0b[01]+$/i,FP=/^0o[0-7]+$/i,BP=parseInt;function ch(e){if(typeof e=="number")return e;if(oi(e))return lh;if(Hr(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Hr(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=VP(e);var r=NP.test(e);return r||FP.test(e)?BP(e.slice(2),r?2:8):DP.test(e)?lh:+e}var zP="Expected a function",GP=Math.max,HP=Math.min;function qP(e,t,r){var n,a,s,o,i,l,c=0,u=!1,d=!1,h=!0;if(typeof e!="function")throw new TypeError(zP);t=ch(t)||0,Hr(r)&&(u=!!r.leading,d="maxWait"in r,s=d?GP(ch(r.maxWait)||0,t):s,h="trailing"in r?!!r.trailing:h);function p(R){var P=n,E=a;return n=a=void 0,c=R,o=e.apply(E,P),o}function m(R){return c=R,i=setTimeout(S,t),u?p(R):o}function f(R){var P=R-l,E=R-c,B=t-P;return d?HP(B,s-E):B}function g(R){var P=R-l,E=R-c;return l===void 0||P>=t||P<0||d&&E>=s}function S(){var R=Xi();if(g(R))return T(R);i=setTimeout(S,f(R))}function T(R){return i=void 0,h&&n?p(R):(n=a=void 0,o)}function O(){i!==void 0&&clearTimeout(i),c=0,n=l=a=i=void 0}function C(){return i===void 0?o:T(Xi())}function V(){var R=Xi(),P=g(R);if(n=arguments,a=this,l=R,P){if(i===void 0)return m(l);if(d)return clearTimeout(i),i=setTimeout(S,t),p(l)}return i===void 0&&(i=setTimeout(S,t)),o}return V.cancel=O,V.flush=C,V}var JP="Expected a function";function WP(e,t,r){var n=!0,a=!0;if(typeof e!="function")throw new TypeError(JP);return Hr(r)&&(n="leading"in r?!!r.leading:n,a="trailing"in r?!!r.trailing:a),qP(e,t,{leading:n,maxWait:t,trailing:a})}const Rm=en(Je.observer(({startJogging:e,stopJogging:t,lowerLimitDegs:r,upperLimitDegs:n,getValueDegs:a,disabled:s,...o})=>{var O,C,V,R,P,E,B,y,A,z,I,G,re,te,oe;const{t:i}=ze.useTranslation(),[l,c]=ae.useState(),u=W.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(Z){this.activeJoggingDir=Z,e(Z)},stopJogging(){this.activeJoggingDir=null,t()}})),p=WP(()=>{c(a())},50);Yn(p);function m(Z){Z.button===0&&h.startJogging("-")}function f(Z){Z.button===0&&h.startJogging("+")}function g(Z){h.stopJogging()}function S(Z){h.stopJogging()}function T(Z,se=1){if(Z===void 0||isNaN(Z))return"";const ge=i("General.degree.variable",{amount:Z.toFixed(se)});return Z>0&&se===0?`+${ge}`:ge}return x.jsxs(jn,{height:"64px",width:"100%",maxWidth:"260px",direction:"row",...o,sx:{"& .MuiIconButton-root":{width:"52px",color:u.palette.text.primary,alignContent:"center",backgroundColor:(V=u.palette.backgroundPaperElevation)==null?void 0:V[11],"& svg":{width:"42px",height:"42px"},"&.Mui-disabled":{backgroundColor:(R=u.palette.backgroundPaperElevation)==null?void 0:R[11],color:u.palette.action.disabled,opacity:1},"&:hover":{backgroundColor:(P=u.palette.backgroundPaperElevation)==null?void 0:P[9]},"&:active":{...d}}},children:[x.jsx(W.IconButton,{onPointerDown:m,onPointerUp:g,onPointerOut:S,disabled:s,disableRipple:!0,sx:{borderRadius:"16px 0px 0px 16px",...h.activeJoggingDir==="-"?d:{}},children:x.jsx(wP,{sx:{pointerEvents:"none",color:(A=(y=(B=(E=u.componentsExt)==null?void 0:E.JoggingPanel)==null?void 0:B.JoggingJoint)==null?void 0:y.Joint)==null?void 0:A.arrowColor}})}),x.jsxs(jn,{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:[x.jsx(W.Typography,{sx:{fontSize:"15px",fontWeight:700,position:"relative",top:"5px",color:s?u.palette.action.disabled:u.palette.text.primary},children:T(l)}),x.jsx(W.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:s?u.palette.action.disabled:u.palette.text.primary},"& .MuiSlider-markLabel":{top:"20px",fontSize:"12px",color:s?u.palette.action.disabled:u.palette.text.secondary},"& .MuiSlider-rail":{backgroundColor:(I=u.palette.backgroundPaperElevation)==null?void 0:I[5],opacity:1}},marks:r!==void 0&&n!==void 0&&[{value:r,label:T(r,0)},{value:n,label:T(n,0)}]})]}),x.jsx(W.IconButton,{onPointerDown:f,onPointerUp:g,onPointerOut:S,disabled:s,disableRipple:!0,sx:{borderRadius:"0px 16px 16px 0px",...h.activeJoggingDir==="+"?d:{}},children:x.jsx(CP,{sx:{pointerEvents:"none",color:(oe=(te=(re=(G=u.componentsExt)==null?void 0:G.JoggingPanel)==null?void 0:re.JoggingJoint)==null?void 0:te.Joint)==null?void 0:oe.arrowColor}})})]})})),KP=si(x.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"),YP=si(x.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 QP(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Tm=QP;function XP(){this.__data__=[],this.size=0}var ZP=XP;function eR(e,t){return e===t||e!==e&&t!==t}var Am=eR;function tR(e,t){for(var r=e.length;r--;)if(Am(e[r][0],t))return r;return-1}var ii=tR,rR=Array.prototype,nR=rR.splice;function aR(e){var t=this.__data__,r=ii(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():nR.call(t,r,1),--this.size,!0}var sR=aR;function oR(e){var t=this.__data__,r=ii(t,e);return r<0?void 0:t[r][1]}var iR=oR;function lR(e){return ii(this.__data__,e)>-1}var cR=lR;function uR(e,t){var r=this.__data__,n=ii(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}var dR=uR;function Qn(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])}}Qn.prototype.clear=ZP;Qn.prototype.delete=sR;Qn.prototype.get=iR;Qn.prototype.has=cR;Qn.prototype.set=dR;var li=Qn;function hR(){this.__data__=new li,this.size=0}var pR=hR;function fR(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}var mR=fR;function gR(e){return this.__data__.get(e)}var yR=gR;function bR(e){return this.__data__.has(e)}var vR=bR,xR=typeof global=="object"&&global&&global.Object===Object&&global,Vm=xR,SR=typeof self=="object"&&self&&self.Object===Object&&self,OR=Vm||SR||Function("return this")(),hr=OR,wR=hr.Symbol,qn=wR,Em=Object.prototype,CR=Em.hasOwnProperty,PR=Em.toString,va=qn?qn.toStringTag:void 0;function RR(e){var t=CR.call(e,va),r=e[va];try{e[va]=void 0;var n=!0}catch{}var a=PR.call(e);return n&&(t?e[va]=r:delete e[va]),a}var TR=RR,AR=Object.prototype,VR=AR.toString;function ER(e){return VR.call(e)}var _R=ER,IR="[object Null]",MR="[object Undefined]",uh=qn?qn.toStringTag:void 0;function $R(e){return e==null?e===void 0?MR:IR:uh&&uh in Object(e)?TR(e):_R(e)}var ls=$R,jR="[object AsyncFunction]",kR="[object Function]",LR="[object GeneratorFunction]",UR="[object Proxy]";function DR(e){if(!Tm(e))return!1;var t=ls(e);return t==kR||t==LR||t==jR||t==UR}var _m=DR,NR=hr["__core-js_shared__"],Zi=NR,dh=function(){var e=/[^.]+$/.exec(Zi&&Zi.keys&&Zi.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function FR(e){return!!dh&&dh in e}var BR=FR,zR=Function.prototype,GR=zR.toString;function HR(e){if(e!=null){try{return GR.call(e)}catch{}try{return e+""}catch{}}return""}var nn=HR,qR=/[\\^$.*+?()[\]{}|]/g,JR=/^\[object .+?Constructor\]$/,WR=Function.prototype,KR=Object.prototype,YR=WR.toString,QR=KR.hasOwnProperty,XR=RegExp("^"+YR.call(QR).replace(qR,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function ZR(e){if(!Tm(e)||BR(e))return!1;var t=_m(e)?XR:JR;return t.test(nn(e))}var eT=ZR;function tT(e,t){return e==null?void 0:e[t]}var rT=tT;function nT(e,t){var r=rT(e,t);return eT(r)?r:void 0}var Xn=nT,aT=Xn(hr,"Map"),Ja=aT,sT=Xn(Object,"create"),Wa=sT;function oT(){this.__data__=Wa?Wa(null):{},this.size=0}var iT=oT;function lT(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var cT=lT,uT="__lodash_hash_undefined__",dT=Object.prototype,hT=dT.hasOwnProperty;function pT(e){var t=this.__data__;if(Wa){var r=t[e];return r===uT?void 0:r}return hT.call(t,e)?t[e]:void 0}var fT=pT,mT=Object.prototype,gT=mT.hasOwnProperty;function yT(e){var t=this.__data__;return Wa?t[e]!==void 0:gT.call(t,e)}var bT=yT,vT="__lodash_hash_undefined__";function xT(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=Wa&&t===void 0?vT:t,this}var ST=xT;function Zn(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])}}Zn.prototype.clear=iT;Zn.prototype.delete=cT;Zn.prototype.get=fT;Zn.prototype.has=bT;Zn.prototype.set=ST;var hh=Zn;function OT(){this.size=0,this.__data__={hash:new hh,map:new(Ja||li),string:new hh}}var wT=OT;function CT(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var PT=CT;function RT(e,t){var r=e.__data__;return PT(t)?r[typeof t=="string"?"string":"hash"]:r.map}var ci=RT;function TT(e){var t=ci(this,e).delete(e);return this.size-=t?1:0,t}var AT=TT;function VT(e){return ci(this,e).get(e)}var ET=VT;function _T(e){return ci(this,e).has(e)}var IT=_T;function MT(e,t){var r=ci(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}var $T=MT;function ea(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])}}ea.prototype.clear=wT;ea.prototype.delete=AT;ea.prototype.get=ET;ea.prototype.has=IT;ea.prototype.set=$T;var Im=ea,jT=200;function kT(e,t){var r=this.__data__;if(r instanceof li){var n=r.__data__;if(!Ja||n.length<jT-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 LT=kT;function ta(e){var t=this.__data__=new li(e);this.size=t.size}ta.prototype.clear=pR;ta.prototype.delete=mR;ta.prototype.get=yR;ta.prototype.has=vR;ta.prototype.set=LT;var el=ta,UT="__lodash_hash_undefined__";function DT(e){return this.__data__.set(e,UT),this}var NT=DT;function FT(e){return this.__data__.has(e)}var BT=FT;function Oo(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new Im;++t<r;)this.add(e[t])}Oo.prototype.add=Oo.prototype.push=NT;Oo.prototype.has=BT;var zT=Oo;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 HT=GT;function qT(e,t){return e.has(t)}var JT=qT,WT=1,KT=2;function YT(e,t,r,n,a,s){var o=r&WT,i=e.length,l=t.length;if(i!=l&&!(o&&l>i))return!1;var c=s.get(e),u=s.get(t);if(c&&u)return c==t&&u==e;var d=-1,h=!0,p=r&KT?new zT:void 0;for(s.set(e,t),s.set(t,e);++d<i;){var m=e[d],f=t[d];if(n)var g=o?n(f,m,d,t,e,s):n(m,f,d,e,t,s);if(g!==void 0){if(g)continue;h=!1;break}if(p){if(!HT(t,function(S,T){if(!JT(p,T)&&(m===S||a(m,S,r,n,s)))return p.push(T)})){h=!1;break}}else if(!(m===f||a(m,f,r,n,s))){h=!1;break}}return s.delete(e),s.delete(t),h}var Mm=YT,QT=hr.Uint8Array,ph=QT;function XT(e){var t=-1,r=Array(e.size);return e.forEach(function(n,a){r[++t]=[a,n]}),r}var ZT=XT;function eA(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var tA=eA,rA=1,nA=2,aA="[object Boolean]",sA="[object Date]",oA="[object Error]",iA="[object Map]",lA="[object Number]",cA="[object RegExp]",uA="[object Set]",dA="[object String]",hA="[object Symbol]",pA="[object ArrayBuffer]",fA="[object DataView]",fh=qn?qn.prototype:void 0,tl=fh?fh.valueOf:void 0;function mA(e,t,r,n,a,s,o){switch(r){case fA:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case pA:return!(e.byteLength!=t.byteLength||!s(new ph(e),new ph(t)));case aA:case sA:case lA:return Am(+e,+t);case oA:return e.name==t.name&&e.message==t.message;case cA:case dA:return e==t+"";case iA:var i=ZT;case uA:var l=n&rA;if(i||(i=tA),e.size!=t.size&&!l)return!1;var c=o.get(e);if(c)return c==t;n|=nA,o.set(e,t);var u=Mm(i(e),i(t),n,a,s,o);return o.delete(e),u;case hA:if(tl)return tl.call(e)==tl.call(t)}return!1}var gA=mA;function yA(e,t){for(var r=-1,n=t.length,a=e.length;++r<n;)e[a+r]=t[r];return e}var bA=yA,vA=Array.isArray,wo=vA;function xA(e,t,r){var n=t(e);return wo(e)?n:bA(n,r(e))}var SA=xA;function OA(e,t){for(var r=-1,n=e==null?0:e.length,a=0,s=[];++r<n;){var o=e[r];t(o,r,e)&&(s[a++]=o)}return s}var wA=OA;function CA(){return[]}var PA=CA,RA=Object.prototype,TA=RA.propertyIsEnumerable,mh=Object.getOwnPropertySymbols,AA=mh?function(e){return e==null?[]:(e=Object(e),wA(mh(e),function(t){return TA.call(e,t)}))}:PA,VA=AA;function EA(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var _A=EA;function IA(e){return e!=null&&typeof e=="object"}var Ka=IA,MA="[object Arguments]";function $A(e){return Ka(e)&&ls(e)==MA}var gh=$A,$m=Object.prototype,jA=$m.hasOwnProperty,kA=$m.propertyIsEnumerable,LA=gh(function(){return arguments}())?gh:function(e){return Ka(e)&&jA.call(e,"callee")&&!kA.call(e,"callee")},UA=LA;function DA(){return!1}var NA=DA,jm=typeof exports=="object"&&exports&&!exports.nodeType&&exports,yh=jm&&typeof module=="object"&&module&&!module.nodeType&&module,FA=yh&&yh.exports===jm,bh=FA?hr.Buffer:void 0,BA=bh?bh.isBuffer:void 0,zA=BA||NA,$l=zA,GA=9007199254740991,HA=/^(?:0|[1-9]\d*)$/;function qA(e,t){var r=typeof e;return t=t??GA,!!t&&(r=="number"||r!="symbol"&&HA.test(e))&&e>-1&&e%1==0&&e<t}var JA=qA,WA=9007199254740991;function KA(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=WA}var km=KA,YA="[object Arguments]",QA="[object Array]",XA="[object Boolean]",ZA="[object Date]",eV="[object Error]",tV="[object Function]",rV="[object Map]",nV="[object Number]",aV="[object Object]",sV="[object RegExp]",oV="[object Set]",iV="[object String]",lV="[object WeakMap]",cV="[object ArrayBuffer]",uV="[object DataView]",dV="[object Float32Array]",hV="[object Float64Array]",pV="[object Int8Array]",fV="[object Int16Array]",mV="[object Int32Array]",gV="[object Uint8Array]",yV="[object Uint8ClampedArray]",bV="[object Uint16Array]",vV="[object Uint32Array]",Ie={};Ie[dV]=Ie[hV]=Ie[pV]=Ie[fV]=Ie[mV]=Ie[gV]=Ie[yV]=Ie[bV]=Ie[vV]=!0;Ie[YA]=Ie[QA]=Ie[cV]=Ie[XA]=Ie[uV]=Ie[ZA]=Ie[eV]=Ie[tV]=Ie[rV]=Ie[nV]=Ie[aV]=Ie[sV]=Ie[oV]=Ie[iV]=Ie[lV]=!1;function xV(e){return Ka(e)&&km(e.length)&&!!Ie[ls(e)]}var SV=xV;function OV(e){return function(t){return e(t)}}var wV=OV,Lm=typeof exports=="object"&&exports&&!exports.nodeType&&exports,$a=Lm&&typeof module=="object"&&module&&!module.nodeType&&module,CV=$a&&$a.exports===Lm,rl=CV&&Vm.process,PV=function(){try{var e=$a&&$a.require&&$a.require("util").types;return e||rl&&rl.binding&&rl.binding("util")}catch{}}(),vh=PV,xh=vh&&vh.isTypedArray,RV=xh?wV(xh):SV,Um=RV,TV=Object.prototype,AV=TV.hasOwnProperty;function VV(e,t){var r=wo(e),n=!r&&UA(e),a=!r&&!n&&$l(e),s=!r&&!n&&!a&&Um(e),o=r||n||a||s,i=o?_A(e.length,String):[],l=i.length;for(var c in e)(t||AV.call(e,c))&&!(o&&(c=="length"||a&&(c=="offset"||c=="parent")||s&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||JA(c,l)))&&i.push(c);return i}var EV=VV,_V=Object.prototype;function IV(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||_V;return e===r}var MV=IV;function $V(e,t){return function(r){return e(t(r))}}var jV=$V,kV=jV(Object.keys,Object),LV=kV,UV=Object.prototype,DV=UV.hasOwnProperty;function NV(e){if(!MV(e))return LV(e);var t=[];for(var r in Object(e))DV.call(e,r)&&r!="constructor"&&t.push(r);return t}var FV=NV;function BV(e){return e!=null&&km(e.length)&&!_m(e)}var zV=BV;function GV(e){return zV(e)?EV(e):FV(e)}var HV=GV;function qV(e){return SA(e,HV,VA)}var Sh=qV,JV=1,WV=Object.prototype,KV=WV.hasOwnProperty;function YV(e,t,r,n,a,s){var o=r&JV,i=Sh(e),l=i.length,c=Sh(t),u=c.length;if(l!=u&&!o)return!1;for(var d=l;d--;){var h=i[d];if(!(o?h in t:KV.call(t,h)))return!1}var p=s.get(e),m=s.get(t);if(p&&m)return p==t&&m==e;var f=!0;s.set(e,t),s.set(t,e);for(var g=o;++d<l;){h=i[d];var S=e[h],T=t[h];if(n)var O=o?n(T,S,h,t,e,s):n(S,T,h,e,t,s);if(!(O===void 0?S===T||a(S,T,r,n,s):O)){f=!1;break}g||(g=h=="constructor")}if(f&&!g){var C=e.constructor,V=t.constructor;C!=V&&"constructor"in e&&"constructor"in t&&!(typeof C=="function"&&C instanceof C&&typeof V=="function"&&V instanceof V)&&(f=!1)}return s.delete(e),s.delete(t),f}var QV=YV,XV=Xn(hr,"DataView"),jl=XV,ZV=Xn(hr,"Promise"),kl=ZV,eE=Xn(hr,"Set"),Ll=eE,tE=Xn(hr,"WeakMap"),Ul=tE,Oh="[object Map]",rE="[object Object]",wh="[object Promise]",Ch="[object Set]",Ph="[object WeakMap]",Rh="[object DataView]",nE=nn(jl),aE=nn(Ja),sE=nn(kl),oE=nn(Ll),iE=nn(Ul),kr=ls;(jl&&kr(new jl(new ArrayBuffer(1)))!=Rh||Ja&&kr(new Ja)!=Oh||kl&&kr(kl.resolve())!=wh||Ll&&kr(new Ll)!=Ch||Ul&&kr(new Ul)!=Ph)&&(kr=function(e){var t=ls(e),r=t==rE?e.constructor:void 0,n=r?nn(r):"";if(n)switch(n){case nE:return Rh;case aE:return Oh;case sE:return wh;case oE:return Ch;case iE:return Ph}return t});var Th=kr,lE=1,Ah="[object Arguments]",Vh="[object Array]",Rs="[object Object]",cE=Object.prototype,Eh=cE.hasOwnProperty;function uE(e,t,r,n,a,s){var o=wo(e),i=wo(t),l=o?Vh:Th(e),c=i?Vh:Th(t);l=l==Ah?Rs:l,c=c==Ah?Rs:c;var u=l==Rs,d=c==Rs,h=l==c;if(h&&$l(e)){if(!$l(t))return!1;o=!0,u=!1}if(h&&!u)return s||(s=new el),o||Um(e)?Mm(e,t,r,n,a,s):gA(e,t,l,r,n,a,s);if(!(r&lE)){var p=u&&Eh.call(e,"__wrapped__"),m=d&&Eh.call(t,"__wrapped__");if(p||m){var f=p?e.value():e,g=m?t.value():t;return s||(s=new el),a(f,g,r,n,s)}}return h?(s||(s=new el),QV(e,t,r,n,a,s)):!1}var dE=uE;function Dm(e,t,r,n,a){return e===t?!0:e==null||t==null||!Ka(e)&&!Ka(t)?e!==e&&t!==t:dE(e,t,r,n,Dm,a)}var hE=Dm;function pE(e,t){return hE(e,t)}var fE=pE;/*! *****************************************************************************
|
|
89
137
|
Copyright (c) Microsoft Corporation. All rights reserved.
|
|
90
138
|
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
|
91
139
|
this file except in compliance with the License. You may obtain a copy of the
|
|
@@ -98,18 +146,18 @@ MERCHANTABLITY OR NON-INFRINGEMENT.
|
|
|
98
146
|
|
|
99
147
|
See the Apache Version 2.0 License for specific language governing permissions
|
|
100
148
|
and limitations under the License.
|
|
101
|
-
***************************************************************************** */var
|
|
149
|
+
***************************************************************************** */var Dl=function(e,t){return Dl=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])},Dl(e,t)};function Nm(e,t){Dl(e,t);function r(){this.constructor=e}e.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}function mE(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 gE(e,t){var r=typeof Symbol=="function"&&e[Symbol.iterator];if(!r)return e;var n=r.call(e),a,s=[],o;try{for(;(t===void 0||t-- >0)&&!(a=n.next()).done;)s.push(a.value)}catch(i){o={error:i}}finally{try{a&&!a.done&&(r=n.return)&&r.call(n)}finally{if(o)throw o.error}}return s}function yE(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(gE(arguments[t]));return e}var Fm=function(){function e(t,r){this.target=r,this.type=t}return e}(),bE=function(e){Nm(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),vE=function(e){Nm(t,e);function t(r,n,a){r===void 0&&(r=1e3),n===void 0&&(n="");var s=e.call(this,"close",a)||this;return s.wasClean=!0,s.code=r,s.reason=n,s}return t}(Fm);/*!
|
|
102
150
|
* Reconnecting WebSocket
|
|
103
151
|
* by Pedro Ladaria <pedro.ladaria@gmail.com>
|
|
104
152
|
* https://github.com/pladaria/reconnecting-websocket
|
|
105
153
|
* License MIT
|
|
106
|
-
*/var b0=function(){if(typeof WebSocket<"u")return WebSocket},S0=function(e){return typeof e<"u"&&!!e&&e.CLOSING===2},nr={maxReconnectionDelay:1e4,minReconnectionDelay:1e3+Math.random()*4e3,minUptime:5e3,reconnectionDelayGrowFactor:1.3,connectionTimeout:4e3,maxRetries:1/0,maxEnqueuedMessages:1/0},v0=function(){function e(t,r,a){var n=this;a===void 0&&(a={}),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){n._debug("open event");var s=n._options.minUptime,i=s===void 0?nr.minUptime:s;clearTimeout(n._connectTimeout),n._uptimeTimeout=setTimeout(function(){return n._acceptOpen()},i),n._ws.binaryType=n._binaryType,n._messageQueue.forEach(function(l){return n._ws.send(l)}),n._messageQueue=[],n.onopen&&n.onopen(o),n._listeners.open.forEach(function(l){return n._callEventListener(o,l)})},this._handleMessage=function(o){n._debug("message event"),n.onmessage&&n.onmessage(o),n._listeners.message.forEach(function(s){return n._callEventListener(o,s)})},this._handleError=function(o){n._debug("error event",o.message),n._disconnect(void 0,o.message==="TIMEOUT"?"timeout":void 0),n.onerror&&n.onerror(o),n._debug("exec error listeners"),n._listeners.error.forEach(function(s){return n._callEventListener(o,s)}),n._connect()},this._handleClose=function(o){n._debug("close event"),n._clearTimeouts(),n._shouldReconnect&&n._connect(),n.onclose&&n.onclose(o),n._listeners.close.forEach(function(s){return n._callEventListener(o,s)})},this._url=t,this._protocols=r,this._options=a,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,a){return typeof a=="string"?r+=a.length:a instanceof Blob?r+=a.size:r+=a.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,a=r===void 0?nr.maxEnqueuedMessages:r;this._messageQueue.length<a&&(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,a,n=this._listeners[t.type];if(n)try{for(var o=h0(n),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&&(a=o.return)&&a.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(a){return a!==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,f0(["RWS>"],t))},e.prototype._getNextDelay=function(){var t=this._options,r=t.reconnectionDelayGrowFactor,a=r===void 0?nr.reconnectionDelayGrowFactor:r,n=t.minReconnectionDelay,o=n===void 0?nr.minReconnectionDelay:n,s=t.maxReconnectionDelay,i=s===void 0?nr.maxReconnectionDelay:s,l=0;return this._retryCount>0&&(l=o*Math.pow(a,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,a=r.maxRetries,n=a===void 0?nr.maxRetries:a,o=r.connectionTimeout,s=o===void 0?nr.connectionTimeout:o,i=r.WebSocket,l=i===void 0?b0():i;if(this._retryCount>=n){this._debug("max retries reached",this._retryCount,">=",n);return}if(this._retryCount++,this._debug("connect",this._retryCount),this._removeListeners(),!S0(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 g0(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 y0(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}(),x0=Object.defineProperty,O0=Object.defineProperties,w0=Object.getOwnPropertyDescriptors,zi=Object.getOwnPropertySymbols,C0=Object.prototype.hasOwnProperty,P0=Object.prototype.propertyIsEnumerable,Gi=(e,t,r)=>t in e?x0(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Nr=(e,t)=>{for(var r in t||(t={}))C0.call(t,r)&&Gi(e,r,t[r]);if(zi)for(var r of zi(t))P0.call(t,r)&&Gi(e,r,t[r]);return e},Ko=(e,t)=>O0(e,w0(t)),Ce=(e,t,r)=>new Promise((a,n)=>{var o=l=>{try{i(r.next(l))}catch(c){n(c)}},s=l=>{try{i(r.throw(l))}catch(c){n(c)}},i=l=>l.done?a(l.value):Promise.resolve(l.value).then(o,s);i((r=r.apply(e,t)).next())}),V0=class extends v0{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",a=>{this.receivedFirstMessage||(this.receivedFirstMessage=a)}),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 Ce(this,null,function*(){return new Promise((e,t)=>{this.readyState===WebSocket.OPEN?e():(this.addEventListener("open",()=>e()),this.addEventListener("error",t))})})}closed(){return Ce(this,null,function*(){return new Promise((e,t)=>{this.readyState===WebSocket.CLOSED?e():(this.addEventListener("close",()=>e()),this.addEventListener("error",t))})})}firstMessage(){return Ce(this,null,function*(){return this.receivedFirstMessage?this.receivedFirstMessage:new Promise((e,t)=>{const r=n=>{this.receivedFirstMessage=n,this.removeEventListener("message",r),this.removeEventListener("error",a),e(n)},a=n=>{this.removeEventListener("message",r),this.removeEventListener("error",a),t(n)};this.addEventListener("message",r),this.addEventListener("error",a)})})}nextMessage(){return Ce(this,null,function*(){return new Promise((e,t)=>{const r=n=>{this.removeEventListener("message",r),this.removeEventListener("error",a),e(n)},a=n=>{this.removeEventListener("message",r),this.removeEventListener("error",a),t(n)};this.addEventListener("message",r),this.addEventListener("error",a)})})}},R0=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}},Po=new R0;function Kt(e){try{return JSON.parse(e)}catch{return}}function _0(e,t){return e||(e="world"),t||(t="world"),e===t}var Gr="wandelbots.io",Vo={dev:{domain:`https://auth.portal.dev.${Gr}`,clientId:"fLbJD0RLp5r2Dpucm5j8BjwMR6Hunfha"},stg:{domain:`https://auth.portal.stg.${Gr}`,clientId:"joVDeD9e786WzFNSGCqoVq7HNkWt5j6s"},prod:{domain:`https://auth.portal.${Gr}`,clientId:"J7WJUi38xVQdJAEBNRT9Xw1b0fXDb4J2"}},A0=e=>{if(e.includes(`dev.${Gr}`))return Vo.dev;if(e.includes(`stg.${Gr}`))return Vo.stg;if(e.includes(Gr))return Vo.prod;throw new Error("Unsupported instance URL. Cannot determine Auth0 configuration.")},T0=e=>Ce(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=A0(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:a}=yield Promise.resolve().then(()=>require("./auth0-spa-js.production.esm-BLRAk7Yh.cjs")),n=new a({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 n.handleRedirectCallback();window.history.replaceState({},document.title,(s==null?void 0:s.returnTo)||window.location.pathname)}else yield n.loginWithRedirect();return yield n.getTokenSilently()});function _c(e,t){return function(){return e.apply(t,arguments)}}const{toString:E0}=Object.prototype,{getPrototypeOf:bs}=Object,Yn=(e=>t=>{const r=E0.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),gt=e=>(e=e.toLowerCase(),t=>Yn(t)===e),Xn=e=>t=>typeof t===e,{isArray:ea}=Array,$a=Xn("undefined");function I0(e){return e!==null&&!$a(e)&&e.constructor!==null&&!$a(e.constructor)&&at(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Ac=gt("ArrayBuffer");function M0(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Ac(e.buffer),t}const j0=Xn("string"),at=Xn("function"),Tc=Xn("number"),Zn=e=>e!==null&&typeof e=="object",$0=e=>e===!0||e===!1,hn=e=>{if(Yn(e)!=="object")return!1;const t=bs(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},U0=gt("Date"),L0=gt("File"),k0=gt("Blob"),B0=gt("FileList"),F0=e=>Zn(e)&&at(e.pipe),N0=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||at(e.append)&&((t=Yn(e))==="formdata"||t==="object"&&at(e.toString)&&e.toString()==="[object FormData]"))},D0=gt("URLSearchParams"),[z0,G0,J0,H0]=["ReadableStream","Request","Response","Headers"].map(gt),q0=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Da(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let a,n;if(typeof e!="object"&&(e=[e]),ea(e))for(a=0,n=e.length;a<n;a++)t.call(null,e[a],a,e);else{const o=r?Object.getOwnPropertyNames(e):Object.keys(e),s=o.length;let i;for(a=0;a<s;a++)i=o[a],t.call(null,e[i],i,e)}}function Ec(e,t){t=t.toLowerCase();const r=Object.keys(e);let a=r.length,n;for(;a-- >0;)if(n=r[a],t===n.toLowerCase())return n;return null}const sr=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Ic=e=>!$a(e)&&e!==sr;function Qo(){const{caseless:e}=Ic(this)&&this||{},t={},r=(a,n)=>{const o=e&&Ec(t,n)||n;hn(t[o])&&hn(a)?t[o]=Qo(t[o],a):hn(a)?t[o]=Qo({},a):ea(a)?t[o]=a.slice():t[o]=a};for(let a=0,n=arguments.length;a<n;a++)arguments[a]&&Da(arguments[a],r);return t}const W0=(e,t,r,{allOwnKeys:a}={})=>(Da(t,(n,o)=>{r&&at(n)?e[o]=_c(n,r):e[o]=n},{allOwnKeys:a}),e),K0=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),Q0=(e,t,r,a)=>{e.prototype=Object.create(t.prototype,a),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},Y0=(e,t,r,a)=>{let n,o,s;const i={};if(t=t||{},e==null)return t;do{for(n=Object.getOwnPropertyNames(e),o=n.length;o-- >0;)s=n[o],(!a||a(s,e,t))&&!i[s]&&(t[s]=e[s],i[s]=!0);e=r!==!1&&bs(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},X0=(e,t,r)=>{e=String(e),(r===void 0||r>e.length)&&(r=e.length),r-=t.length;const a=e.indexOf(t,r);return a!==-1&&a===r},Z0=e=>{if(!e)return null;if(ea(e))return e;let t=e.length;if(!Tc(t))return null;const r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},eS=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&bs(Uint8Array)),tS=(e,t)=>{const a=(e&&e[Symbol.iterator]).call(e);let n;for(;(n=a.next())&&!n.done;){const o=n.value;t.call(e,o[0],o[1])}},rS=(e,t)=>{let r;const a=[];for(;(r=e.exec(t))!==null;)a.push(r);return a},aS=gt("HTMLFormElement"),nS=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,a,n){return a.toUpperCase()+n}),Ji=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),oS=gt("RegExp"),Mc=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),a={};Da(r,(n,o)=>{let s;(s=t(n,o,e))!==!1&&(a[o]=s||n)}),Object.defineProperties(e,a)},sS=e=>{Mc(e,(t,r)=>{if(at(e)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const a=e[r];if(at(a)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},iS=(e,t)=>{const r={},a=n=>{n.forEach(o=>{r[o]=!0})};return ea(e)?a(e):a(String(e).split(t)),r},lS=()=>{},cS=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function dS(e){return!!(e&&at(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const uS=e=>{const t=new Array(10),r=(a,n)=>{if(Zn(a)){if(t.indexOf(a)>=0)return;if(!("toJSON"in a)){t[n]=a;const o=ea(a)?[]:{};return Da(a,(s,i)=>{const l=r(s,n+1);!$a(l)&&(o[i]=l)}),t[n]=void 0,o}}return a};return r(e,0)},pS=gt("AsyncFunction"),hS=e=>e&&(Zn(e)||at(e))&&at(e.then)&&at(e.catch),jc=((e,t)=>e?setImmediate:t?((r,a)=>(sr.addEventListener("message",({source:n,data:o})=>{n===sr&&o===r&&a.length&&a.shift()()},!1),n=>{a.push(n),sr.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",at(sr.postMessage)),mS=typeof queueMicrotask<"u"?queueMicrotask.bind(sr):typeof process<"u"&&process.nextTick||jc,I={isArray:ea,isArrayBuffer:Ac,isBuffer:I0,isFormData:N0,isArrayBufferView:M0,isString:j0,isNumber:Tc,isBoolean:$0,isObject:Zn,isPlainObject:hn,isReadableStream:z0,isRequest:G0,isResponse:J0,isHeaders:H0,isUndefined:$a,isDate:U0,isFile:L0,isBlob:k0,isRegExp:oS,isFunction:at,isStream:F0,isURLSearchParams:D0,isTypedArray:eS,isFileList:B0,forEach:Da,merge:Qo,extend:W0,trim:q0,stripBOM:K0,inherits:Q0,toFlatObject:Y0,kindOf:Yn,kindOfTest:gt,endsWith:X0,toArray:Z0,forEachEntry:tS,matchAll:rS,isHTMLForm:aS,hasOwnProperty:Ji,hasOwnProp:Ji,reduceDescriptors:Mc,freezeMethods:sS,toObjectSet:iS,toCamelCase:nS,noop:lS,toFiniteNumber:cS,findKey:Ec,global:sr,isContextDefined:Ic,isSpecCompliantForm:dS,toJSONObject:uS,isAsyncFn:pS,isThenable:hS,setImmediate:jc,asap:mS};function ie(e,t,r,a,n){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),a&&(this.request=a),n&&(this.response=n,this.status=n.status?n.status:null)}I.inherits(ie,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:I.toJSONObject(this.config),code:this.code,status:this.status}}});const $c=ie.prototype,Uc={};["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=>{Uc[e]={value:e}});Object.defineProperties(ie,Uc);Object.defineProperty($c,"isAxiosError",{value:!0});ie.from=(e,t,r,a,n,o)=>{const s=Object.create($c);return I.toFlatObject(e,s,function(l){return l!==Error.prototype},i=>i!=="isAxiosError"),ie.call(s,e.message,t,r,a,n),s.cause=e,s.name=e.name,o&&Object.assign(s,o),s};const fS=null;function Yo(e){return I.isPlainObject(e)||I.isArray(e)}function Lc(e){return I.endsWith(e,"[]")?e.slice(0,-2):e}function Hi(e,t,r){return e?e.concat(t).map(function(n,o){return n=Lc(n),!r&&o?"["+n+"]":n}).join(r?".":""):t}function gS(e){return I.isArray(e)&&!e.some(Yo)}const yS=I.toFlatObject(I,{},null,function(t){return/^is[A-Z]/.test(t)});function eo(e,t,r){if(!I.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,r=I.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(h,x){return!I.isUndefined(x[h])});const a=r.metaTokens,n=r.visitor||d,o=r.dots,s=r.indexes,l=(r.Blob||typeof Blob<"u"&&Blob)&&I.isSpecCompliantForm(t);if(!I.isFunction(n))throw new TypeError("visitor must be a function");function c(g){if(g===null)return"";if(I.isDate(g))return g.toISOString();if(!l&&I.isBlob(g))throw new ie("Blob is not supported. Use a Buffer instead.");return I.isArrayBuffer(g)||I.isTypedArray(g)?l&&typeof Blob=="function"?new Blob([g]):Buffer.from(g):g}function d(g,h,x){let E=g;if(g&&!x&&typeof g=="object"){if(I.endsWith(h,"{}"))h=a?h:h.slice(0,-2),g=JSON.stringify(g);else if(I.isArray(g)&&gS(g)||(I.isFileList(g)||I.endsWith(h,"[]"))&&(E=I.toArray(g)))return h=Lc(h),E.forEach(function(F,N){!(I.isUndefined(F)||F===null)&&t.append(s===!0?Hi([h],N,o):s===null?h:h+"[]",c(F))}),!1}return Yo(g)?!0:(t.append(Hi(x,h,o),c(g)),!1)}const u=[],p=Object.assign(yS,{defaultVisitor:d,convertValue:c,isVisitable:Yo});function m(g,h){if(!I.isUndefined(g)){if(u.indexOf(g)!==-1)throw Error("Circular reference detected in "+h.join("."));u.push(g),I.forEach(g,function(E,U){(!(I.isUndefined(E)||E===null)&&n.call(t,E,I.isString(U)?U.trim():U,h,p))===!0&&m(E,h?h.concat(U):[U])}),u.pop()}}if(!I.isObject(e))throw new TypeError("data must be an object");return m(e),t}function qi(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(a){return t[a]})}function Ss(e,t){this._pairs=[],e&&eo(e,this,t)}const kc=Ss.prototype;kc.append=function(t,r){this._pairs.push([t,r])};kc.toString=function(t){const r=t?function(a){return t.call(this,a,qi)}:qi;return this._pairs.map(function(n){return r(n[0])+"="+r(n[1])},"").join("&")};function bS(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Bc(e,t,r){if(!t)return e;const a=r&&r.encode||bS;I.isFunction(r)&&(r={serialize:r});const n=r&&r.serialize;let o;if(n?o=n(t,r):o=I.isURLSearchParams(t)?t.toString():new Ss(t,r).toString(a),o){const s=e.indexOf("#");s!==-1&&(e=e.slice(0,s)),e+=(e.indexOf("?")===-1?"?":"&")+o}return e}class Wi{constructor(){this.handlers=[]}use(t,r,a){return this.handlers.push({fulfilled:t,rejected:r,synchronous:a?a.synchronous:!1,runWhen:a?a.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){I.forEach(this.handlers,function(a){a!==null&&t(a)})}}const Fc={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},SS=typeof URLSearchParams<"u"?URLSearchParams:Ss,vS=typeof FormData<"u"?FormData:null,xS=typeof Blob<"u"?Blob:null,OS={isBrowser:!0,classes:{URLSearchParams:SS,FormData:vS,Blob:xS},protocols:["http","https","file","blob","url","data"]},vs=typeof window<"u"&&typeof document<"u",Xo=typeof navigator=="object"&&navigator||void 0,wS=vs&&(!Xo||["ReactNative","NativeScript","NS"].indexOf(Xo.product)<0),CS=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",PS=vs&&window.location.href||"http://localhost",VS=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:vs,hasStandardBrowserEnv:wS,hasStandardBrowserWebWorkerEnv:CS,navigator:Xo,origin:PS},Symbol.toStringTag,{value:"Module"})),Ge={...VS,...OS};function RS(e,t){return eo(e,new Ge.classes.URLSearchParams,Object.assign({visitor:function(r,a,n,o){return Ge.isNode&&I.isBuffer(r)?(this.append(a,r.toString("base64")),!1):o.defaultVisitor.apply(this,arguments)}},t))}function _S(e){return I.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function AS(e){const t={},r=Object.keys(e);let a;const n=r.length;let o;for(a=0;a<n;a++)o=r[a],t[o]=e[o];return t}function Nc(e){function t(r,a,n,o){let s=r[o++];if(s==="__proto__")return!0;const i=Number.isFinite(+s),l=o>=r.length;return s=!s&&I.isArray(n)?n.length:s,l?(I.hasOwnProp(n,s)?n[s]=[n[s],a]:n[s]=a,!i):((!n[s]||!I.isObject(n[s]))&&(n[s]=[]),t(r,a,n[s],o)&&I.isArray(n[s])&&(n[s]=AS(n[s])),!i)}if(I.isFormData(e)&&I.isFunction(e.entries)){const r={};return I.forEachEntry(e,(a,n)=>{t(_S(a),n,r,0)}),r}return null}function TS(e,t,r){if(I.isString(e))try{return(t||JSON.parse)(e),I.trim(e)}catch(a){if(a.name!=="SyntaxError")throw a}return(r||JSON.stringify)(e)}const za={transitional:Fc,adapter:["xhr","http","fetch"],transformRequest:[function(t,r){const a=r.getContentType()||"",n=a.indexOf("application/json")>-1,o=I.isObject(t);if(o&&I.isHTMLForm(t)&&(t=new FormData(t)),I.isFormData(t))return n?JSON.stringify(Nc(t)):t;if(I.isArrayBuffer(t)||I.isBuffer(t)||I.isStream(t)||I.isFile(t)||I.isBlob(t)||I.isReadableStream(t))return t;if(I.isArrayBufferView(t))return t.buffer;if(I.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let i;if(o){if(a.indexOf("application/x-www-form-urlencoded")>-1)return RS(t,this.formSerializer).toString();if((i=I.isFileList(t))||a.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return eo(i?{"files[]":t}:t,l&&new l,this.formSerializer)}}return o||n?(r.setContentType("application/json",!1),TS(t)):t}],transformResponse:[function(t){const r=this.transitional||za.transitional,a=r&&r.forcedJSONParsing,n=this.responseType==="json";if(I.isResponse(t)||I.isReadableStream(t))return t;if(t&&I.isString(t)&&(a&&!this.responseType||n)){const s=!(r&&r.silentJSONParsing)&&n;try{return JSON.parse(t)}catch(i){if(s)throw i.name==="SyntaxError"?ie.from(i,ie.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:Ge.classes.FormData,Blob:Ge.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};I.forEach(["delete","get","head","post","put","patch"],e=>{za.headers[e]={}});const ES=I.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"]),IS=e=>{const t={};let r,a,n;return e&&e.split(`
|
|
107
|
-
`).forEach(function(
|
|
108
|
-
`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...r){const a=new this(t);return r.forEach(n=>a.set(n)),a}static accessor(t){const a=(this[Ki]=this[Ki]={accessors:{}}).accessors,n=this.prototype;function o(s){const i=fa(s);a[i]||(US(n,s),a[i]=!0)}return I.isArray(t)?t.forEach(o):o(t),this}};Ze.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);I.reduceDescriptors(Ze.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(a){this[r]=a}}});I.freezeMethods(Ze);function _o(e,t){const r=this||za,a=t||r,n=Ze.from(a.headers);let o=a.data;return I.forEach(e,function(i){o=i.call(r,o,n.normalize(),t?t.status:void 0)}),n.normalize(),o}function Dc(e){return!!(e&&e.__CANCEL__)}function ta(e,t,r){ie.call(this,e??"canceled",ie.ERR_CANCELED,t,r),this.name="CanceledError"}I.inherits(ta,ie,{__CANCEL__:!0});function zc(e,t,r){const a=r.config.validateStatus;!r.status||!a||a(r.status)?e(r):t(new ie("Request failed with status code "+r.status,[ie.ERR_BAD_REQUEST,ie.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}function LS(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function kS(e,t){e=e||10;const r=new Array(e),a=new Array(e);let n=0,o=0,s;return t=t!==void 0?t:1e3,function(l){const c=Date.now(),d=a[o];s||(s=c),r[n]=l,a[n]=c;let u=o,p=0;for(;u!==n;)p+=r[u++],u=u%e;if(n=(n+1)%e,n===o&&(o=(o+1)%e),c-s<t)return;const m=d&&c-d;return m?Math.round(p*1e3/m):void 0}}function BS(e,t){let r=0,a=1e3/t,n,o;const s=(c,d=Date.now())=>{r=d,n=null,o&&(clearTimeout(o),o=null),e.apply(null,c)};return[(...c)=>{const d=Date.now(),u=d-r;u>=a?s(c,d):(n=c,o||(o=setTimeout(()=>{o=null,s(n)},a-u)))},()=>n&&s(n)]}const _n=(e,t,r=3)=>{let a=0;const n=kS(50,250);return BS(o=>{const s=o.loaded,i=o.lengthComputable?o.total:void 0,l=s-a,c=n(l),d=s<=i;a=s;const u={loaded:s,total:i,progress:i?s/i:void 0,bytes:l,rate:c||void 0,estimated:c&&i&&d?(i-s)/c:void 0,event:o,lengthComputable:i!=null,[t?"download":"upload"]:!0};e(u)},r)},Qi=(e,t)=>{const r=e!=null;return[a=>t[0]({lengthComputable:r,total:e,loaded:a}),t[1]]},Yi=e=>(...t)=>I.asap(()=>e(...t)),FS=Ge.hasStandardBrowserEnv?((e,t)=>r=>(r=new URL(r,Ge.origin),e.protocol===r.protocol&&e.host===r.host&&(t||e.port===r.port)))(new URL(Ge.origin),Ge.navigator&&/(msie|trident)/i.test(Ge.navigator.userAgent)):()=>!0,NS=Ge.hasStandardBrowserEnv?{write(e,t,r,a,n,o){const s=[e+"="+encodeURIComponent(t)];I.isNumber(r)&&s.push("expires="+new Date(r).toGMTString()),I.isString(a)&&s.push("path="+a),I.isString(n)&&s.push("domain="+n),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 DS(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function zS(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function Gc(e,t,r){let a=!DS(t);return e&&a||r==!1?zS(e,t):t}const Xi=e=>e instanceof Ze?{...e}:e;function pr(e,t){t=t||{};const r={};function a(c,d,u,p){return I.isPlainObject(c)&&I.isPlainObject(d)?I.merge.call({caseless:p},c,d):I.isPlainObject(d)?I.merge({},d):I.isArray(d)?d.slice():d}function n(c,d,u,p){if(I.isUndefined(d)){if(!I.isUndefined(c))return a(void 0,c,u,p)}else return a(c,d,u,p)}function o(c,d){if(!I.isUndefined(d))return a(void 0,d)}function s(c,d){if(I.isUndefined(d)){if(!I.isUndefined(c))return a(void 0,c)}else return a(void 0,d)}function i(c,d,u){if(u in t)return a(c,d);if(u in e)return a(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,d,u)=>n(Xi(c),Xi(d),u,!0)};return I.forEach(Object.keys(Object.assign({},e,t)),function(d){const u=l[d]||n,p=u(e[d],t[d],d);I.isUndefined(p)&&u!==i||(r[d]=p)}),r}const Jc=e=>{const t=pr({},e);let{data:r,withXSRFToken:a,xsrfHeaderName:n,xsrfCookieName:o,headers:s,auth:i}=t;t.headers=s=Ze.from(s),t.url=Bc(Gc(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(I.isFormData(r)){if(Ge.hasStandardBrowserEnv||Ge.hasStandardBrowserWebWorkerEnv)s.setContentType(void 0);else if((l=s.getContentType())!==!1){const[c,...d]=l?l.split(";").map(u=>u.trim()).filter(Boolean):[];s.setContentType([c||"multipart/form-data",...d].join("; "))}}if(Ge.hasStandardBrowserEnv&&(a&&I.isFunction(a)&&(a=a(t)),a||a!==!1&&FS(t.url))){const c=n&&o&&NS.read(o);c&&s.set(n,c)}return t},GS=typeof XMLHttpRequest<"u",JS=GS&&function(e){return new Promise(function(r,a){const n=Jc(e);let o=n.data;const s=Ze.from(n.headers).normalize();let{responseType:i,onUploadProgress:l,onDownloadProgress:c}=n,d,u,p,m,g;function h(){m&&m(),g&&g(),n.cancelToken&&n.cancelToken.unsubscribe(d),n.signal&&n.signal.removeEventListener("abort",d)}let x=new XMLHttpRequest;x.open(n.method.toUpperCase(),n.url,!0),x.timeout=n.timeout;function E(){if(!x)return;const F=Ze.from("getAllResponseHeaders"in x&&x.getAllResponseHeaders()),J={data:!i||i==="text"||i==="json"?x.responseText:x.response,status:x.status,statusText:x.statusText,headers:F,config:e,request:x};zc(function(j){r(j),h()},function(j){a(j),h()},J),x=null}"onloadend"in x?x.onloadend=E:x.onreadystatechange=function(){!x||x.readyState!==4||x.status===0&&!(x.responseURL&&x.responseURL.indexOf("file:")===0)||setTimeout(E)},x.onabort=function(){x&&(a(new ie("Request aborted",ie.ECONNABORTED,e,x)),x=null)},x.onerror=function(){a(new ie("Network Error",ie.ERR_NETWORK,e,x)),x=null},x.ontimeout=function(){let N=n.timeout?"timeout of "+n.timeout+"ms exceeded":"timeout exceeded";const J=n.transitional||Fc;n.timeoutErrorMessage&&(N=n.timeoutErrorMessage),a(new ie(N,J.clarifyTimeoutError?ie.ETIMEDOUT:ie.ECONNABORTED,e,x)),x=null},o===void 0&&s.setContentType(null),"setRequestHeader"in x&&I.forEach(s.toJSON(),function(N,J){x.setRequestHeader(J,N)}),I.isUndefined(n.withCredentials)||(x.withCredentials=!!n.withCredentials),i&&i!=="json"&&(x.responseType=n.responseType),c&&([p,g]=_n(c,!0),x.addEventListener("progress",p)),l&&x.upload&&([u,m]=_n(l),x.upload.addEventListener("progress",u),x.upload.addEventListener("loadend",m)),(n.cancelToken||n.signal)&&(d=F=>{x&&(a(!F||F.type?new ta(null,e,x):F),x.abort(),x=null)},n.cancelToken&&n.cancelToken.subscribe(d),n.signal&&(n.signal.aborted?d():n.signal.addEventListener("abort",d)));const U=LS(n.url);if(U&&Ge.protocols.indexOf(U)===-1){a(new ie("Unsupported protocol "+U+":",ie.ERR_BAD_REQUEST,e));return}x.send(o||null)})},HS=(e,t)=>{const{length:r}=e=e?e.filter(Boolean):[];if(t||r){let a=new AbortController,n;const o=function(c){if(!n){n=!0,i();const d=c instanceof Error?c:this.reason;a.abort(d instanceof ie?d:new ta(d instanceof Error?d.message:d))}};let s=t&&setTimeout(()=>{s=null,o(new ie(`timeout ${t} of ms exceeded`,ie.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}=a;return l.unsubscribe=()=>I.asap(i),l}},qS=function*(e,t){let r=e.byteLength;if(r<t){yield e;return}let a=0,n;for(;a<r;)n=a+t,yield e.slice(a,n),a=n},WS=async function*(e,t){for await(const r of KS(e))yield*qS(r,t)},KS=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:r,value:a}=await t.read();if(r)break;yield a}}finally{await t.cancel()}},Zi=(e,t,r,a)=>{const n=WS(e,t);let o=0,s,i=l=>{s||(s=!0,a&&a(l))};return new ReadableStream({async pull(l){try{const{done:c,value:d}=await n.next();if(c){i(),l.close();return}let u=d.byteLength;if(r){let p=o+=u;r(p)}l.enqueue(new Uint8Array(d))}catch(c){throw i(c),c}},cancel(l){return i(l),n.return()}},{highWaterMark:2})},to=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",Hc=to&&typeof ReadableStream=="function",QS=to&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),qc=(e,...t)=>{try{return!!e(...t)}catch{return!1}},YS=Hc&&qc(()=>{let e=!1;const t=new Request(Ge.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),el=64*1024,Zo=Hc&&qc(()=>I.isReadableStream(new Response("").body)),An={stream:Zo&&(e=>e.body)};to&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!An[t]&&(An[t]=I.isFunction(e[t])?r=>r[t]():(r,a)=>{throw new ie(`Response type '${t}' is not supported`,ie.ERR_NOT_SUPPORT,a)})})})(new Response);const XS=async e=>{if(e==null)return 0;if(I.isBlob(e))return e.size;if(I.isSpecCompliantForm(e))return(await new Request(Ge.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(I.isArrayBufferView(e)||I.isArrayBuffer(e))return e.byteLength;if(I.isURLSearchParams(e)&&(e=e+""),I.isString(e))return(await QS(e)).byteLength},ZS=async(e,t)=>{const r=I.toFiniteNumber(e.getContentLength());return r??XS(t)},ev=to&&(async e=>{let{url:t,method:r,data:a,signal:n,cancelToken:o,timeout:s,onDownloadProgress:i,onUploadProgress:l,responseType:c,headers:d,withCredentials:u="same-origin",fetchOptions:p}=Jc(e);c=c?(c+"").toLowerCase():"text";let m=HS([n,o&&o.toAbortSignal()],s),g;const h=m&&m.unsubscribe&&(()=>{m.unsubscribe()});let x;try{if(l&&YS&&r!=="get"&&r!=="head"&&(x=await ZS(d,a))!==0){let J=new Request(t,{method:"POST",body:a,duplex:"half"}),K;if(I.isFormData(a)&&(K=J.headers.get("content-type"))&&d.setContentType(K),J.body){const[j,L]=Qi(x,_n(Yi(l)));a=Zi(J.body,el,j,L)}}I.isString(u)||(u=u?"include":"omit");const E="credentials"in Request.prototype;g=new Request(t,{...p,signal:m,method:r.toUpperCase(),headers:d.normalize().toJSON(),body:a,duplex:"half",credentials:E?u:void 0});let U=await fetch(g);const F=Zo&&(c==="stream"||c==="response");if(Zo&&(i||F&&h)){const J={};["status","statusText","headers"].forEach(k=>{J[k]=U[k]});const K=I.toFiniteNumber(U.headers.get("content-length")),[j,L]=i&&Qi(K,_n(Yi(i),!0))||[];U=new Response(Zi(U.body,el,j,()=>{L&&L(),h&&h()}),J)}c=c||"text";let N=await An[I.findKey(An,c)||"text"](U,e);return!F&&h&&h(),await new Promise((J,K)=>{zc(J,K,{data:N,headers:Ze.from(U.headers),status:U.status,statusText:U.statusText,config:e,request:g})})}catch(E){throw h&&h(),E&&E.name==="TypeError"&&/fetch/i.test(E.message)?Object.assign(new ie("Network Error",ie.ERR_NETWORK,e,g),{cause:E.cause||E}):ie.from(E,E&&E.code,e,g)}}),es={http:fS,xhr:JS,fetch:ev};I.forEach(es,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const tl=e=>`- ${e}`,tv=e=>I.isFunction(e)||e===null||e===!1,Wc={getAdapter:e=>{e=I.isArray(e)?e:[e];const{length:t}=e;let r,a;const n={};for(let o=0;o<t;o++){r=e[o];let s;if(a=r,!tv(r)&&(a=es[(s=String(r)).toLowerCase()],a===void 0))throw new ie(`Unknown adapter '${s}'`);if(a)break;n[s||"#"+o]=a}if(!a){const o=Object.entries(n).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 :
|
|
109
|
-
`+
|
|
110
|
-
`):" "+
|
|
111
|
-
`+o):a.stack=o}catch{}}throw a}}_request(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=pr(this.defaults,r);const{transitional:a,paramsSerializer:n,headers:o}=r;a!==void 0&&fn.assertOptions(a,{silentJSONParsing:vt.transitional(vt.boolean),forcedJSONParsing:vt.transitional(vt.boolean),clarifyTimeoutError:vt.transitional(vt.boolean)},!1),n!=null&&(I.isFunction(n)?r.paramsSerializer={serialize:n}:fn.assertOptions(n,{encode:vt.function,serialize:vt.function},!0)),r.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?r.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:r.allowAbsoluteUrls=!0),fn.assertOptions(r,{baseUrl:vt.spelling("baseURL"),withXsrfToken:vt.spelling("withXSRFToken")},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let s=o&&I.merge(o.common,o[r.method]);o&&I.forEach(["delete","get","head","post","put","patch","common"],g=>{delete o[g]}),r.headers=Ze.concat(s,o);const i=[];let l=!0;this.interceptors.request.forEach(function(h){typeof h.runWhen=="function"&&h.runWhen(r)===!1||(l=l&&h.synchronous,i.unshift(h.fulfilled,h.rejected))});const c=[];this.interceptors.response.forEach(function(h){c.push(h.fulfilled,h.rejected)});let d,u=0,p;if(!l){const g=[rl.bind(this),void 0];for(g.unshift.apply(g,i),g.push.apply(g,c),p=g.length,d=Promise.resolve(r);u<p;)d=d.then(g[u++],g[u++]);return d}p=i.length;let m=r;for(u=0;u<p;){const g=i[u++],h=i[u++];try{m=g(m)}catch(x){h.call(this,x);break}}try{d=rl.call(this,m)}catch(g){return Promise.reject(g)}for(u=0,p=c.length;u<p;)d=d.then(c[u++],c[u++]);return d}getUri(t){t=pr(this.defaults,t);const r=Gc(t.baseURL,t.url,t.allowAbsoluteUrls);return Bc(r,t.params,t.paramsSerializer)}};I.forEach(["delete","get","head","options"],function(t){lr.prototype[t]=function(r,a){return this.request(pr(a||{},{method:t,url:r,data:(a||{}).data}))}});I.forEach(["post","put","patch"],function(t){function r(a){return function(o,s,i){return this.request(pr(i||{},{method:t,headers:a?{"Content-Type":"multipart/form-data"}:{},url:o,data:s}))}}lr.prototype[t]=r(),lr.prototype[t+"Form"]=r(!0)});let av=class Qc{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 a=this;this.promise.then(n=>{if(!a._listeners)return;let o=a._listeners.length;for(;o-- >0;)a._listeners[o](n);a._listeners=null}),this.promise.then=n=>{let o;const s=new Promise(i=>{a.subscribe(i),o=i}).then(n);return s.cancel=function(){a.unsubscribe(o)},s},t(function(o,s,i){a.reason||(a.reason=new ta(o,s,i),r(a.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=a=>{t.abort(a)};return this.subscribe(r),t.signal.unsubscribe=()=>this.unsubscribe(r),t.signal}static source(){let t;return{token:new Qc(function(n){t=n}),cancel:t}}};function nv(e){return function(r){return e.apply(null,r)}}function ov(e){return I.isObject(e)&&e.isAxiosError===!0}const ts={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(ts).forEach(([e,t])=>{ts[t]=e});function Yc(e){const t=new lr(e),r=_c(lr.prototype.request,t);return I.extend(r,lr.prototype,t,{allOwnKeys:!0}),I.extend(r,t,null,{allOwnKeys:!0}),r.create=function(n){return Yc(pr(e,n))},r}const O=Yc(za);O.Axios=lr;O.CanceledError=ta;O.CancelToken=av;O.isCancel=Dc;O.VERSION=Kc;O.toFormData=eo;O.AxiosError=ie;O.Cancel=O.CanceledError;O.all=function(t){return Promise.all(t)};O.spread=nv;O.isAxiosError=ov;O.mergeConfig=pr;O.AxiosHeaders=Ze;O.formToJSON=e=>Nc(I.isHTMLForm(e)?new FormData(e):e);O.getAdapter=Wc.getAdapter;O.HttpStatusCode=ts;O.default=O;const{Axios:hP,AxiosError:rs,CanceledError:mP,isCancel:fP,CancelToken:gP,VERSION:yP,all:bP,Cancel:SP,isAxiosError:sv,spread:vP,toFormData:xP,AxiosHeaders:OP,HttpStatusCode:wP,formToJSON:CP,getAdapter:PP,mergeConfig:VP}=O,w="/api/v1".replace(/\/+$/,"");class Pe{constructor(t,r=w,a=O){ia(this,"basePath");ia(this,"axios");ia(this,"configuration");this.basePath=r,this.axios=a,t&&(this.configuration=t,this.basePath=t.basePath??r)}}class iv extends Error{constructor(r,a){super(a);ia(this,"field");this.field=r,this.name="RequiredError"}}const C={},P="https://example.com",f=function(e,t,r){if(r==null)throw new iv(t,`Required parameter ${t} was null or undefined when calling ${e}.`)},V=function(e,t){t&&(t.username||t.password)&&(e.auth={username:t.username,password:t.password})},R=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 as(e,t,r=""){t!=null&&(typeof t=="object"?Array.isArray(t)?t.forEach(a=>as(e,a,r)):Object.keys(t).forEach(a=>as(e,t[a],`${r}${r!==""?".":""}${a}`)):e.has(r)?e.append(r,t):e.set(r,t))}const _=function(e,...t){const r=new URLSearchParams(e.search);as(r,t),e.search=r.toString()},se=function(e,t,r){const a=typeof e!="string";return(a&&r&&r.isJsonMime?r.isJsonMime(t.headers["Content-Type"]):a)?JSON.stringify(e!==void 0?e:{}):e||""},A=function(e){return e.pathname+e.search+e.hash},T=function(e,t,r,a){return(n=t,o=r)=>{const s={...e.options,url:(n.defaults.baseURL?"":(a==null?void 0:a.basePath)??o)+e.url};return n.request(s)}},lv=function(e){return{addApp:async(t,r,a,n={})=>{f("addApp","cell",t),f("addApp","app",r);const o="/cells/{cell}/apps".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.completionTimeout=a),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(r,l,e),{url:A(s),options:l}},clearApps:async(t,r,a={})=>{f("clearApps","cell",t);const n="/cells/{cell}/apps".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),r!==void 0&&(c.completionTimeout=r),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},deleteApp:async(t,r,a,n={})=>{f("deleteApp","cell",t),f("deleteApp","app",r);const o="/cells/{cell}/apps/{app}".replace("{cell}",encodeURIComponent(String(t))).replace("{app}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"DELETE",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.completionTimeout=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},getApp:async(t,r,a={})=>{f("getApp","cell",t),f("getApp","app",r);const n="/cells/{cell}/apps/{app}".replace("{cell}",encodeURIComponent(String(t))).replace("{app}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listApps:async(t,r={})=>{f("listApps","cell",t);const a="/cells/{cell}/apps".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},updateApp:async(t,r,a,n,o={})=>{f("updateApp","cell",t),f("updateApp","app",r),f("updateApp","app2",a);const s="/cells/{cell}/apps/{app}".replace("{cell}",encodeURIComponent(String(t))).replace("{app}",encodeURIComponent(String(r))),i=new URL(s,P);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},d={},u={};V(c,e),await R(d,e),n!==void 0&&(u.completionTimeout=n),d["Content-Type"]="application/json",_(i,u);let p=l&&l.headers?l.headers:{};return c.headers={...d,...p,...o.headers},c.data=se(a,c,e),{url:A(i),options:c}}}},Mr=function(e){const t=lv(e);return{async addApp(r,a,n,o){var c,d;const s=await t.addApp(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["ApplicationApi.addApp"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async clearApps(r,a,n){var l,c;const o=await t.clearApps(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ApplicationApi.clearApps"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async deleteApp(r,a,n,o){var c,d;const s=await t.deleteApp(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["ApplicationApi.deleteApp"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async getApp(r,a,n){var l,c;const o=await t.getApp(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ApplicationApi.getApp"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listApps(r,a){var i,l;const n=await t.listApps(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["ApplicationApi.listApps"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async updateApp(r,a,n,o,s){var d,u;const i=await t.updateApp(r,a,n,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(u=(d=C["ApplicationApi.updateApp"])==null?void 0:d[l])==null?void 0:u.url;return(p,m)=>T(i,O,w,e)(p,c||m)}}};class nl extends Pe{addApp(t,r,a,n){return Mr(this.configuration).addApp(t,r,a,n).then(o=>o(this.axios,this.basePath))}clearApps(t,r,a){return Mr(this.configuration).clearApps(t,r,a).then(n=>n(this.axios,this.basePath))}deleteApp(t,r,a,n){return Mr(this.configuration).deleteApp(t,r,a,n).then(o=>o(this.axios,this.basePath))}getApp(t,r,a){return Mr(this.configuration).getApp(t,r,a).then(n=>n(this.axios,this.basePath))}listApps(t,r){return Mr(this.configuration).listApps(t,r).then(a=>a(this.axios,this.basePath))}updateApp(t,r,a,n,o){return Mr(this.configuration).updateApp(t,r,a,n,o).then(s=>s(this.axios,this.basePath))}}const cv=function(e){return{deleteCell:async(t,r,a={})=>{f("deleteCell","cell",t);const n="/cells/{cell}".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),r!==void 0&&(c.completionTimeout=r),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},deployCell:async(t,r,a={})=>{f("deployCell","cell",t);const n="/cells",o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...a},l={},c={};V(i,e),await R(l,e),r!==void 0&&(c.completionTimeout=r),l["Content-Type"]="application/json",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(t,i,e),{url:A(o),options:i}},getCell:async(t,r={})=>{f("getCell","cell",t);const a="/cells/{cell}".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},getCellStatus:async(t,r={})=>{f("getCellStatus","cell",t);const a="/cells/{cell}/status".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},listCells:async(t={})=>{const r="/cells",a=new URL(r,P);let n;e&&(n=e.baseOptions);const o={method:"GET",...n,...t},s={},i={};V(o,e),await R(s,e),_(a,i);let l=n&&n.headers?n.headers:{};return o.headers={...s,...l,...t.headers},{url:A(a),options:o}},updateCell:async(t,r,a,n={})=>{f("updateCell","cell",t),f("updateCell","cell2",r);const o="/cells/{cell}".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.completionTimeout=a),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(r,l,e),{url:A(s),options:l}}}},jr=function(e){const t=cv(e);return{async deleteCell(r,a,n){var l,c;const o=await t.deleteCell(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["CellApi.deleteCell"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async deployCell(r,a,n){var l,c;const o=await t.deployCell(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["CellApi.deployCell"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getCell(r,a){var i,l;const n=await t.getCell(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["CellApi.getCell"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async getCellStatus(r,a){var i,l;const n=await t.getCellStatus(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["CellApi.getCellStatus"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async listCells(r){var s,i;const a=await t.listCells(r),n=(e==null?void 0:e.serverIndex)??0,o=(i=(s=C["CellApi.listCells"])==null?void 0:s[n])==null?void 0:i.url;return(l,c)=>T(a,O,w,e)(l,o||c)},async updateCell(r,a,n,o){var c,d;const s=await t.updateCell(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["CellApi.updateCell"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)}}};class dv extends Pe{deleteCell(t,r,a){return jr(this.configuration).deleteCell(t,r,a).then(n=>n(this.axios,this.basePath))}deployCell(t,r,a){return jr(this.configuration).deployCell(t,r,a).then(n=>n(this.axios,this.basePath))}getCell(t,r){return jr(this.configuration).getCell(t,r).then(a=>a(this.axios,this.basePath))}getCellStatus(t,r){return jr(this.configuration).getCellStatus(t,r).then(a=>a(this.axios,this.basePath))}listCells(t){return jr(this.configuration).listCells(t).then(r=>r(this.axios,this.basePath))}updateCell(t,r,a,n){return jr(this.configuration).updateCell(t,r,a,n).then(o=>o(this.axios,this.basePath))}}const uv=function(e){return{addRobotController:async(t,r,a,n={})=>{f("addRobotController","cell",t),f("addRobotController","robotController",r);const o="/cells/{cell}/controllers".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.completionTimeout=a),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(r,l,e),{url:A(s),options:l}},clearRobotControllers:async(t,r,a={})=>{f("clearRobotControllers","cell",t);const n="/cells/{cell}/controllers".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),r!==void 0&&(c.completionTimeout=r),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},deleteRobotController:async(t,r,a,n={})=>{f("deleteRobotController","cell",t),f("deleteRobotController","controller",r);const o="/cells/{cell}/controllers/{controller}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"DELETE",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.completionTimeout=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},getCurrentRobotControllerState:async(t,r,a={})=>{f("getCurrentRobotControllerState","cell",t),f("getCurrentRobotControllerState","controller",r);const n="/cells/{cell}/controllers/{controller}/state".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getMode:async(t,r,a={})=>{f("getMode","cell",t),f("getMode","controller",r);const n="/cells/{cell}/controllers/{controller}/mode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getRobotController:async(t,r,a={})=>{f("getRobotController","cell",t),f("getRobotController","controller",r);const n="/cells/{cell}/controllers/{controller}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getSupportedModes:async(t,r,a={})=>{f("getSupportedModes","cell",t),f("getSupportedModes","controller",r);const n="/cells/{cell}/controllers/{controller}/controller-capabilities".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getVirtualRobotConfiguration:async(t,r,a={})=>{f("getVirtualRobotConfiguration","cell",t),f("getVirtualRobotConfiguration","controller",r);const n="/cells/{cell}/controllers/{controller}/virtual-robot-configuration".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listControllers:async(t,r={})=>{f("listControllers","cell",t);const a="/cells/{cell}/controllers".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},setDefaultMode:async(t,r,a,n={})=>{f("setDefaultMode","cell",t),f("setDefaultMode","controller",r),f("setDefaultMode","mode",a);const o="/cells/{cell}/controllers/{controller}/mode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.mode=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},streamFreeDrive:async(t,r,a,n={})=>{f("streamFreeDrive","cell",t),f("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,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.response_rate=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},streamModeChange:async(t,r,a={})=>{f("streamModeChange","cell",t),f("streamModeChange","controller",r);const n="/cells/{cell}/controllers/{controller}/mode-stream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},streamRobotControllerState:async(t,r,a,n={})=>{f("streamRobotControllerState","cell",t),f("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,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.response_rate=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},updateRobotController:async(t,r,a,n,o={})=>{f("updateRobotController","cell",t),f("updateRobotController","controller",r),f("updateRobotController","robotController",a);const s="/cells/{cell}/controllers/{controller}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),i=new URL(s,P);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},d={},u={};V(c,e),await R(d,e),n!==void 0&&(u.completionTimeout=n),d["Content-Type"]="application/json",_(i,u);let p=l&&l.headers?l.headers:{};return c.headers={...d,...p,...o.headers},c.data=se(a,c,e),{url:A(i),options:c}}}},Xe=function(e){const t=uv(e);return{async addRobotController(r,a,n,o){var c,d;const s=await t.addRobotController(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["ControllerApi.addRobotController"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async clearRobotControllers(r,a,n){var l,c;const o=await t.clearRobotControllers(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ControllerApi.clearRobotControllers"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async deleteRobotController(r,a,n,o){var c,d;const s=await t.deleteRobotController(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["ControllerApi.deleteRobotController"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async getCurrentRobotControllerState(r,a,n){var l,c;const o=await t.getCurrentRobotControllerState(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ControllerApi.getCurrentRobotControllerState"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getMode(r,a,n){var l,c;const o=await t.getMode(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ControllerApi.getMode"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getRobotController(r,a,n){var l,c;const o=await t.getRobotController(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ControllerApi.getRobotController"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getSupportedModes(r,a,n){var l,c;const o=await t.getSupportedModes(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ControllerApi.getSupportedModes"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getVirtualRobotConfiguration(r,a,n){var l,c;const o=await t.getVirtualRobotConfiguration(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ControllerApi.getVirtualRobotConfiguration"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listControllers(r,a){var i,l;const n=await t.listControllers(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["ControllerApi.listControllers"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async setDefaultMode(r,a,n,o){var c,d;const s=await t.setDefaultMode(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["ControllerApi.setDefaultMode"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async streamFreeDrive(r,a,n,o){var c,d;const s=await t.streamFreeDrive(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["ControllerApi.streamFreeDrive"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async streamModeChange(r,a,n){var l,c;const o=await t.streamModeChange(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ControllerApi.streamModeChange"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async streamRobotControllerState(r,a,n,o){var c,d;const s=await t.streamRobotControllerState(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["ControllerApi.streamRobotControllerState"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async updateRobotController(r,a,n,o,s){var d,u;const i=await t.updateRobotController(r,a,n,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(u=(d=C["ControllerApi.updateRobotController"])==null?void 0:d[l])==null?void 0:u.url;return(p,m)=>T(i,O,w,e)(p,c||m)}}};class pv extends Pe{addRobotController(t,r,a,n){return Xe(this.configuration).addRobotController(t,r,a,n).then(o=>o(this.axios,this.basePath))}clearRobotControllers(t,r,a){return Xe(this.configuration).clearRobotControllers(t,r,a).then(n=>n(this.axios,this.basePath))}deleteRobotController(t,r,a,n){return Xe(this.configuration).deleteRobotController(t,r,a,n).then(o=>o(this.axios,this.basePath))}getCurrentRobotControllerState(t,r,a){return Xe(this.configuration).getCurrentRobotControllerState(t,r,a).then(n=>n(this.axios,this.basePath))}getMode(t,r,a){return Xe(this.configuration).getMode(t,r,a).then(n=>n(this.axios,this.basePath))}getRobotController(t,r,a){return Xe(this.configuration).getRobotController(t,r,a).then(n=>n(this.axios,this.basePath))}getSupportedModes(t,r,a){return Xe(this.configuration).getSupportedModes(t,r,a).then(n=>n(this.axios,this.basePath))}getVirtualRobotConfiguration(t,r,a){return Xe(this.configuration).getVirtualRobotConfiguration(t,r,a).then(n=>n(this.axios,this.basePath))}listControllers(t,r){return Xe(this.configuration).listControllers(t,r).then(a=>a(this.axios,this.basePath))}setDefaultMode(t,r,a,n){return Xe(this.configuration).setDefaultMode(t,r,a,n).then(o=>o(this.axios,this.basePath))}streamFreeDrive(t,r,a,n){return Xe(this.configuration).streamFreeDrive(t,r,a,n).then(o=>o(this.axios,this.basePath))}streamModeChange(t,r,a){return Xe(this.configuration).streamModeChange(t,r,a).then(n=>n(this.axios,this.basePath))}streamRobotControllerState(t,r,a,n){return Xe(this.configuration).streamRobotControllerState(t,r,a,n).then(o=>o(this.axios,this.basePath))}updateRobotController(t,r,a,n,o){return Xe(this.configuration).updateRobotController(t,r,a,n,o).then(s=>s(this.axios,this.basePath))}}const hv=function(e){return{listIODescriptions:async(t,r,a,n={})=>{f("listIODescriptions","cell",t),f("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,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),a&&(d.ios=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},listIOValues:async(t,r,a,n={})=>{f("listIOValues","cell",t),f("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,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),a&&(d.ios=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},setOutputValues:async(t,r,a,n={})=>{f("setOutputValues","cell",t),f("setOutputValues","controller",r),f("setOutputValues","iOValue",a);const o="/cells/{cell}/controllers/{controller}/ios/values".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}},streamIOValues:async(t,r,a,n={})=>{f("streamIOValues","cell",t),f("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,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),a&&(d.ios=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},waitForIOEvent:async(t,r,a,n,o,s,i,l={})=>{f("waitForIOEvent","cell",t),f("waitForIOEvent","controller",r),f("waitForIOEvent","io",a),f("waitForIOEvent","comparisonType",n);const c="/cells/{cell}/controllers/{controller}/ios/wait-for".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),d=new URL(c,P);let u;e&&(u=e.baseOptions);const p={method:"GET",...u,...l},m={},g={};V(p,e),await R(m,e),a!==void 0&&(g.io=a),n!==void 0&&(g.comparison_type=n),o!==void 0&&(g.boolean_value=o),s!==void 0&&(g.integer_value=s),i!==void 0&&(g.floating_value=i),_(d,g);let h=u&&u.headers?u.headers:{};return p.headers={...m,...h,...l.headers},{url:A(d),options:p}}}},ga=function(e){const t=hv(e);return{async listIODescriptions(r,a,n,o){var c,d;const s=await t.listIODescriptions(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["ControllerIOsApi.listIODescriptions"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async listIOValues(r,a,n,o){var c,d;const s=await t.listIOValues(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["ControllerIOsApi.listIOValues"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async setOutputValues(r,a,n,o){var c,d;const s=await t.setOutputValues(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["ControllerIOsApi.setOutputValues"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async streamIOValues(r,a,n,o){var c,d;const s=await t.streamIOValues(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["ControllerIOsApi.streamIOValues"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async waitForIOEvent(r,a,n,o,s,i,l,c){var m,g;const d=await t.waitForIOEvent(r,a,n,o,s,i,l,c),u=(e==null?void 0:e.serverIndex)??0,p=(g=(m=C["ControllerIOsApi.waitForIOEvent"])==null?void 0:m[u])==null?void 0:g.url;return(h,x)=>T(d,O,w,e)(h,p||x)}}};class mv extends Pe{listIODescriptions(t,r,a,n){return ga(this.configuration).listIODescriptions(t,r,a,n).then(o=>o(this.axios,this.basePath))}listIOValues(t,r,a,n){return ga(this.configuration).listIOValues(t,r,a,n).then(o=>o(this.axios,this.basePath))}setOutputValues(t,r,a,n){return ga(this.configuration).setOutputValues(t,r,a,n).then(o=>o(this.axios,this.basePath))}streamIOValues(t,r,a,n){return ga(this.configuration).streamIOValues(t,r,a,n).then(o=>o(this.axios,this.basePath))}waitForIOEvent(t,r,a,n,o,s,i,l){return ga(this.configuration).waitForIOEvent(t,r,a,n,o,s,i,l).then(c=>c(this.axios,this.basePath))}}const fv=function(e){return{addCoordinateSystem:async(t,r,a={})=>{f("addCoordinateSystem","cell",t),f("addCoordinateSystem","addRequest",r);const n="/cells/{cell}/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="application/json",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},deleteCoordinateSystem:async(t,r,a={})=>{f("deleteCoordinateSystem","cell",t),f("deleteCoordinateSystem","coordinateSystem",r);const n="/cells/{cell}/coordinate-systems/{coordinate-system}".replace("{cell}",encodeURIComponent(String(t))).replace("{coordinate-system}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getCoordinateSystem:async(t,r,a,n={})=>{f("getCoordinateSystem","cell",t),f("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,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.rotation_type=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},listCoordinateSystems:async(t,r,a={})=>{f("listCoordinateSystems","cell",t);const n="/cells/{cell}/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),r!==void 0&&(c.rotation_type=r),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},transformInCoordinateSystem:async(t,r,a,n={})=>{f("transformInCoordinateSystem","cell",t),f("transformInCoordinateSystem","coordinateSystem",r),f("transformInCoordinateSystem","pose",a);const o="/cells/{cell}/coordinate-systems/{coordinate-system}/transform".replace("{cell}",encodeURIComponent(String(t))).replace("{coordinate-system}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}}}},ya=function(e){const t=fv(e);return{async addCoordinateSystem(r,a,n){var l,c;const o=await t.addCoordinateSystem(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["CoordinateSystemsApi.addCoordinateSystem"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async deleteCoordinateSystem(r,a,n){var l,c;const o=await t.deleteCoordinateSystem(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["CoordinateSystemsApi.deleteCoordinateSystem"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getCoordinateSystem(r,a,n,o){var c,d;const s=await t.getCoordinateSystem(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["CoordinateSystemsApi.getCoordinateSystem"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async listCoordinateSystems(r,a,n){var l,c;const o=await t.listCoordinateSystems(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["CoordinateSystemsApi.listCoordinateSystems"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async transformInCoordinateSystem(r,a,n,o){var c,d;const s=await t.transformInCoordinateSystem(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["CoordinateSystemsApi.transformInCoordinateSystem"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)}}};class gv extends Pe{addCoordinateSystem(t,r,a){return ya(this.configuration).addCoordinateSystem(t,r,a).then(n=>n(this.axios,this.basePath))}deleteCoordinateSystem(t,r,a){return ya(this.configuration).deleteCoordinateSystem(t,r,a).then(n=>n(this.axios,this.basePath))}getCoordinateSystem(t,r,a,n){return ya(this.configuration).getCoordinateSystem(t,r,a,n).then(o=>o(this.axios,this.basePath))}listCoordinateSystems(t,r,a){return ya(this.configuration).listCoordinateSystems(t,r,a).then(n=>n(this.axios,this.basePath))}transformInCoordinateSystem(t,r,a,n){return ya(this.configuration).transformInCoordinateSystem(t,r,a,n).then(o=>o(this.axios,this.basePath))}}const yv=function(e){return{clearDevices:async(t,r={})=>{f("clearDevices","cell",t);const a="/cells/{cell}/devices".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"DELETE",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},createDevice:async(t,r,a={})=>{f("createDevice","cell",t),f("createDevice","createDeviceRequestInner",r);const n="/cells/{cell}/devices".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="application/json",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},deleteDevice:async(t,r,a={})=>{f("deleteDevice","cell",t),f("deleteDevice","identifier",r);const n="/cells/{cell}/devices/{identifier}".replace("{cell}",encodeURIComponent(String(t))).replace("{identifier}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getDevice:async(t,r,a={})=>{f("getDevice","cell",t),f("getDevice","identifier",r);const n="/cells/{cell}/devices/{identifier}".replace("{cell}",encodeURIComponent(String(t))).replace("{identifier}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listDevices:async(t,r={})=>{f("listDevices","cell",t);const a="/cells/{cell}/devices".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}}}},ba=function(e){const t=yv(e);return{async clearDevices(r,a){var i,l;const n=await t.clearDevices(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["DeviceConfigurationApi.clearDevices"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async createDevice(r,a,n){var l,c;const o=await t.createDevice(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["DeviceConfigurationApi.createDevice"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async deleteDevice(r,a,n){var l,c;const o=await t.deleteDevice(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["DeviceConfigurationApi.deleteDevice"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getDevice(r,a,n){var l,c;const o=await t.getDevice(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["DeviceConfigurationApi.getDevice"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listDevices(r,a){var i,l;const n=await t.listDevices(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["DeviceConfigurationApi.listDevices"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)}}};class bv extends Pe{clearDevices(t,r){return ba(this.configuration).clearDevices(t,r).then(a=>a(this.axios,this.basePath))}createDevice(t,r,a){return ba(this.configuration).createDevice(t,r,a).then(n=>n(this.axios,this.basePath))}deleteDevice(t,r,a){return ba(this.configuration).deleteDevice(t,r,a).then(n=>n(this.axios,this.basePath))}getDevice(t,r,a){return ba(this.configuration).getDevice(t,r,a).then(n=>n(this.axios,this.basePath))}listDevices(t,r){return ba(this.configuration).listDevices(t,r).then(a=>a(this.axios,this.basePath))}}const Sv=function(e){return{createProgram:async(t,r,a,n={})=>{f("createProgram","cell",t),f("createProgram","body",r);const o="/cells/{cell}/store/programs".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.name=a),c["Content-Type"]="text/plain",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(r,l,e),{url:A(s),options:l}},deleteProgram:async(t,r,a={})=>{f("deleteProgram","cell",t),f("deleteProgram","program",r);const n="/cells/{cell}/store/programs/{program}".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},deleteProgramList:async(t,r,a={})=>{f("deleteProgramList","cell",t),f("deleteProgramList","programIds",r);const n="/cells/{cell}/store/programs".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),r&&(c.program_ids=r),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getProgram:async(t,r,a={})=>{f("getProgram","cell",t),f("getProgram","program",r);const n="/cells/{cell}/store/programs/{program}".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},updateProgram:async(t,r,a,n={})=>{f("updateProgram","cell",t),f("updateProgram","program",r),f("updateProgram","body",a);const o="/cells/{cell}/store/programs/{program}".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="text/plain",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}}}},Sa=function(e){const t=Sv(e);return{async createProgram(r,a,n,o){var c,d;const s=await t.createProgram(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["LibraryProgramApi.createProgram"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async deleteProgram(r,a,n){var l,c;const o=await t.deleteProgram(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["LibraryProgramApi.deleteProgram"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async deleteProgramList(r,a,n){var l,c;const o=await t.deleteProgramList(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["LibraryProgramApi.deleteProgramList"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getProgram(r,a,n){var l,c;const o=await t.getProgram(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["LibraryProgramApi.getProgram"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async updateProgram(r,a,n,o){var c,d;const s=await t.updateProgram(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["LibraryProgramApi.updateProgram"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)}}};class vv extends Pe{createProgram(t,r,a,n){return Sa(this.configuration).createProgram(t,r,a,n).then(o=>o(this.axios,this.basePath))}deleteProgram(t,r,a){return Sa(this.configuration).deleteProgram(t,r,a).then(n=>n(this.axios,this.basePath))}deleteProgramList(t,r,a){return Sa(this.configuration).deleteProgramList(t,r,a).then(n=>n(this.axios,this.basePath))}getProgram(t,r,a){return Sa(this.configuration).getProgram(t,r,a).then(n=>n(this.axios,this.basePath))}updateProgram(t,r,a,n){return Sa(this.configuration).updateProgram(t,r,a,n).then(o=>o(this.axios,this.basePath))}}const xv=function(e){return{getProgramMetadata:async(t,r,a={})=>{f("getProgramMetadata","cell",t),f("getProgramMetadata","program",r);const n="/cells/{cell}/store/programs/{program}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listProgramMetadata:async(t,r,a={})=>{f("listProgramMetadata","cell",t);const n="/cells/{cell}/store/programs".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),r!==void 0&&(c.show_hidden=r),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},updateProgramMetadata:async(t,r,a,n={})=>{f("updateProgramMetadata","cell",t),f("updateProgramMetadata","program",r),f("updateProgramMetadata","updateProgramMetadataRequest",a);const o="/cells/{cell}/store/programs/{program}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}},uploadProgramMetadataImage:async(t,r,a,n={})=>{f("uploadProgramMetadataImage","cell",t),f("uploadProgramMetadataImage","program",r),f("uploadProgramMetadataImage","file",a);const o="/cells/{cell}/store/programs/{program}/metadata/image".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...n},c={},d={},u=new(e&&e.formDataCtor||FormData);V(l,e),await R(c,e),a!==void 0&&u.append("file",a),c["Content-Type"]="multipart/form-data",_(s,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...n.headers},l.data=u,{url:A(s),options:l}}}},Qa=function(e){const t=xv(e);return{async getProgramMetadata(r,a,n){var l,c;const o=await t.getProgramMetadata(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["LibraryProgramMetadataApi.getProgramMetadata"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listProgramMetadata(r,a,n){var l,c;const o=await t.listProgramMetadata(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["LibraryProgramMetadataApi.listProgramMetadata"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async updateProgramMetadata(r,a,n,o){var c,d;const s=await t.updateProgramMetadata(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["LibraryProgramMetadataApi.updateProgramMetadata"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async uploadProgramMetadataImage(r,a,n,o){var c,d;const s=await t.uploadProgramMetadataImage(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["LibraryProgramMetadataApi.uploadProgramMetadataImage"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)}}};class Ov extends Pe{getProgramMetadata(t,r,a){return Qa(this.configuration).getProgramMetadata(t,r,a).then(n=>n(this.axios,this.basePath))}listProgramMetadata(t,r,a){return Qa(this.configuration).listProgramMetadata(t,r,a).then(n=>n(this.axios,this.basePath))}updateProgramMetadata(t,r,a,n){return Qa(this.configuration).updateProgramMetadata(t,r,a,n).then(o=>o(this.axios,this.basePath))}uploadProgramMetadataImage(t,r,a,n){return Qa(this.configuration).uploadProgramMetadataImage(t,r,a,n).then(o=>o(this.axios,this.basePath))}}const wv=function(e){return{createRecipe:async(t,r,a,n,o={})=>{f("createRecipe","cell",t),f("createRecipe","programId",r),f("createRecipe","body",a);const s="/cells/{cell}/store/recipes".replace("{cell}",encodeURIComponent(String(t))),i=new URL(s,P);let l;e&&(l=e.baseOptions);const c={method:"POST",...l,...o},d={},u={};V(c,e),await R(d,e),r!==void 0&&(u.program_id=r),n!==void 0&&(u.name=n),d["Content-Type"]="application/json",_(i,u);let p=l&&l.headers?l.headers:{};return c.headers={...d,...p,...o.headers},c.data=se(a,c,e),{url:A(i),options:c}},deleteRecipe:async(t,r,a={})=>{f("deleteRecipe","cell",t),f("deleteRecipe","recipe",r);const n="/cells/{cell}/store/recipes/{recipe}".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},deleteRecipeList:async(t,r,a={})=>{f("deleteRecipeList","cell",t),f("deleteRecipeList","recipeIds",r);const n="/cells/{cell}/store/recipes".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),r&&(c.recipe_ids=r),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getRecipe:async(t,r,a={})=>{f("getRecipe","cell",t),f("getRecipe","recipe",r);const n="/cells/{cell}/store/recipes/{recipe}".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},updateRecipe:async(t,r,a,n={})=>{f("updateRecipe","cell",t),f("updateRecipe","recipe",r),f("updateRecipe","body",a);const o="/cells/{cell}/store/recipes/{recipe}".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}}}},va=function(e){const t=wv(e);return{async createRecipe(r,a,n,o,s){var d,u;const i=await t.createRecipe(r,a,n,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(u=(d=C["LibraryRecipeApi.createRecipe"])==null?void 0:d[l])==null?void 0:u.url;return(p,m)=>T(i,O,w,e)(p,c||m)},async deleteRecipe(r,a,n){var l,c;const o=await t.deleteRecipe(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["LibraryRecipeApi.deleteRecipe"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async deleteRecipeList(r,a,n){var l,c;const o=await t.deleteRecipeList(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["LibraryRecipeApi.deleteRecipeList"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getRecipe(r,a,n){var l,c;const o=await t.getRecipe(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["LibraryRecipeApi.getRecipe"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async updateRecipe(r,a,n,o){var c,d;const s=await t.updateRecipe(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["LibraryRecipeApi.updateRecipe"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)}}};class Cv extends Pe{createRecipe(t,r,a,n,o){return va(this.configuration).createRecipe(t,r,a,n,o).then(s=>s(this.axios,this.basePath))}deleteRecipe(t,r,a){return va(this.configuration).deleteRecipe(t,r,a).then(n=>n(this.axios,this.basePath))}deleteRecipeList(t,r,a){return va(this.configuration).deleteRecipeList(t,r,a).then(n=>n(this.axios,this.basePath))}getRecipe(t,r,a){return va(this.configuration).getRecipe(t,r,a).then(n=>n(this.axios,this.basePath))}updateRecipe(t,r,a,n){return va(this.configuration).updateRecipe(t,r,a,n).then(o=>o(this.axios,this.basePath))}}const Pv=function(e){return{getRecipeMetadata:async(t,r,a={})=>{f("getRecipeMetadata","cell",t),f("getRecipeMetadata","recipe",r);const n="/cells/{cell}/store/recipes/{recipe}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listRecipeMetadata:async(t,r={})=>{f("listRecipeMetadata","cell",t);const a="/cells/{cell}/store/recipes".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},updateRecipeMetadata:async(t,r,a,n={})=>{f("updateRecipeMetadata","cell",t),f("updateRecipeMetadata","recipe",r),f("updateRecipeMetadata","updateRecipeMetadataRequest",a);const o="/cells/{cell}/store/recipes/{recipe}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}},uploadRecipeMetadataImage:async(t,r,a,n={})=>{f("uploadRecipeMetadataImage","cell",t),f("uploadRecipeMetadataImage","recipe",r),f("uploadRecipeMetadataImage","file",a);const o="/cells/{cell}/store/recipes/{recipe}/metadata/image".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...n},c={},d={},u=new(e&&e.formDataCtor||FormData);V(l,e),await R(c,e),a!==void 0&&u.append("file",a),c["Content-Type"]="multipart/form-data",_(s,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...n.headers},l.data=u,{url:A(s),options:l}}}},Ya=function(e){const t=Pv(e);return{async getRecipeMetadata(r,a,n){var l,c;const o=await t.getRecipeMetadata(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["LibraryRecipeMetadataApi.getRecipeMetadata"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listRecipeMetadata(r,a){var i,l;const n=await t.listRecipeMetadata(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["LibraryRecipeMetadataApi.listRecipeMetadata"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async updateRecipeMetadata(r,a,n,o){var c,d;const s=await t.updateRecipeMetadata(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["LibraryRecipeMetadataApi.updateRecipeMetadata"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async uploadRecipeMetadataImage(r,a,n,o){var c,d;const s=await t.uploadRecipeMetadataImage(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["LibraryRecipeMetadataApi.uploadRecipeMetadataImage"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)}}};class Vv extends Pe{getRecipeMetadata(t,r,a){return Ya(this.configuration).getRecipeMetadata(t,r,a).then(n=>n(this.axios,this.basePath))}listRecipeMetadata(t,r){return Ya(this.configuration).listRecipeMetadata(t,r).then(a=>a(this.axios,this.basePath))}updateRecipeMetadata(t,r,a,n){return Ya(this.configuration).updateRecipeMetadata(t,r,a,n).then(o=>o(this.axios,this.basePath))}uploadRecipeMetadataImage(t,r,a,n){return Ya(this.configuration).uploadRecipeMetadataImage(t,r,a,n).then(o=>o(this.axios,this.basePath))}}const Rv=function(e){return{deleteAllMotions:async(t,r={})=>{f("deleteAllMotions","cell",t);const a="/cells/{cell}/motions".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"DELETE",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},deleteMotion:async(t,r,a={})=>{f("deleteMotion","cell",t),f("deleteMotion","motion",r);const n="/cells/{cell}/motions/{motion}/delete".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},executeTrajectory:async(t,r,a={})=>{f("executeTrajectory","cell",t),f("executeTrajectory","executeTrajectoryRequest",r);const n="/cells/{cell}/motions/executetrajectory".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="application/json",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},getMotionTrajectory:async(t,r,a,n,o={})=>{f("getMotionTrajectory","cell",t),f("getMotionTrajectory","motion",r),f("getMotionTrajectory","sampleTime",a);const s="/cells/{cell}/motions/{motion}/trajectory".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),i=new URL(s,P);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},d={},u={};V(c,e),await R(d,e),a!==void 0&&(u.sample_time=a),n!==void 0&&(u.responses_coordinate_system=n),_(i,u);let p=l&&l.headers?l.headers:{};return c.headers={...d,...p,...o.headers},{url:A(i),options:c}},getMotionTrajectorySample:async(t,r,a,n,o={})=>{f("getMotionTrajectorySample","cell",t),f("getMotionTrajectorySample","motion",r);const s="/cells/{cell}/motions/{motion}/trajectorysample".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),i=new URL(s,P);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},d={},u={};V(c,e),await R(d,e),a!==void 0&&(u.location_on_trajectory=a),n!==void 0&&(u.response_coordinate_system=n),_(i,u);let p=l&&l.headers?l.headers:{};return c.headers={...d,...p,...o.headers},{url:A(i),options:c}},getPlannedMotion:async(t,r,a,n={})=>{f("getPlannedMotion","cell",t),f("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,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.sample_time=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},getPlanningMotionGroupModels:async(t,r={})=>{f("getPlanningMotionGroupModels","cell",t);const a="/cells/{cell}/motion-planning/motion-group-models".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},listMotions:async(t,r={})=>{f("listMotions","cell",t);const a="/cells/{cell}/motions".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},loadPlannedMotion:async(t,r,a={})=>{f("loadPlannedMotion","cell",t),f("loadPlannedMotion","plannedMotion",r);const n="/cells/{cell}/planned-motions".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="application/json",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},planCollisionFreePTP:async(t,r,a={})=>{f("planCollisionFreePTP","cell",t);const n="/cells/{cell}/motion-planning/plan-collision-free-ptp".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="application/json",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},planMotion:async(t,r,a={})=>{f("planMotion","cell",t),f("planMotion","planRequest",r);const n="/cells/{cell}/motions".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="application/json",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},planTrajectory:async(t,r,a={})=>{f("planTrajectory","cell",t);const n="/cells/{cell}/motion-planning/plan-trajectory".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="application/json",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},stopExecution:async(t,r,a={})=>{f("stopExecution","cell",t),f("stopExecution","motion",r);const n="/cells/{cell}/motions/{motion}/stop".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},streamMove:async(t,r,a={})=>{f("streamMove","cell",t),f("streamMove","streamMoveRequest",r);const n="/cells/{cell}/motions/streammove".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="application/json",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},streamMoveBackward:async(t,r,a,n,o,s,i={})=>{f("streamMoveBackward","cell",t),f("streamMoveBackward","motion",r),f("streamMoveBackward","playbackSpeedInPercent",a);const l="/cells/{cell}/motions/{motion}/executebackward".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),c=new URL(l,P);let d;e&&(d=e.baseOptions);const u={method:"GET",...d,...i},p={},m={};V(u,e),await R(p,e),a!==void 0&&(m.playback_speed_in_percent=a),n!==void 0&&(m.response_rate=n),o!==void 0&&(m.response_coordinate_system=o),s!==void 0&&(m.start_location_on_trajectory=s),_(c,m);let g=d&&d.headers?d.headers:{};return u.headers={...p,...g,...i.headers},{url:A(c),options:u}},streamMoveForward:async(t,r,a,n,o,s,i={})=>{f("streamMoveForward","cell",t),f("streamMoveForward","motion",r),f("streamMoveForward","playbackSpeedInPercent",a);const l="/cells/{cell}/motions/{motion}/executeforward".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),c=new URL(l,P);let d;e&&(d=e.baseOptions);const u={method:"GET",...d,...i},p={},m={};V(u,e),await R(p,e),a!==void 0&&(m.playback_speed_in_percent=a),n!==void 0&&(m.response_rate=n),o!==void 0&&(m.response_coordinate_system=o),s!==void 0&&(m.start_location_on_trajectory=s),_(c,m);let g=d&&d.headers?d.headers:{};return u.headers={...p,...g,...i.headers},{url:A(c),options:u}},streamMoveToTrajectoryViaJointPTP:async(t,r,a,n,o,s,i,l,c,d,u={})=>{f("streamMoveToTrajectoryViaJointPTP","cell",t),f("streamMoveToTrajectoryViaJointPTP","motion",r),f("streamMoveToTrajectoryViaJointPTP","locationOnTrajectory",a);const p="/cells/{cell}/motions/{motion}/executetotrajectory".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),m=new URL(p,P);let g;e&&(g=e.baseOptions);const h={method:"GET",...g,...u},x={},E={};V(h,e),await R(x,e),a!==void 0&&(E.location_on_trajectory=a),n&&(E["limit_override.joint_velocity_limits.joints"]=n),o&&(E["limit_override.joint_acceleration_limits.joints"]=o),s!==void 0&&(E["limit_override.tcp_velocity_limit"]=s),i!==void 0&&(E["limit_override.tcp_acceleration_limit"]=i),l!==void 0&&(E["limit_override.tcp_orientation_velocity_limit"]=l),c!==void 0&&(E["limit_override.tcp_orientation_acceleration_limit"]=c),d!==void 0&&(E.responses_coordinate_system=d),_(m,E);let U=g&&g.headers?g.headers:{};return h.headers={...x,...U,...u.headers},{url:A(m),options:h}}}},ze=function(e){const t=Rv(e);return{async deleteAllMotions(r,a){var i,l;const n=await t.deleteAllMotions(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["MotionApi.deleteAllMotions"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async deleteMotion(r,a,n){var l,c;const o=await t.deleteMotion(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionApi.deleteMotion"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async executeTrajectory(r,a,n){var l,c;const o=await t.executeTrajectory(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionApi.executeTrajectory"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getMotionTrajectory(r,a,n,o,s){var d,u;const i=await t.getMotionTrajectory(r,a,n,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(u=(d=C["MotionApi.getMotionTrajectory"])==null?void 0:d[l])==null?void 0:u.url;return(p,m)=>T(i,O,w,e)(p,c||m)},async getMotionTrajectorySample(r,a,n,o,s){var d,u;const i=await t.getMotionTrajectorySample(r,a,n,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(u=(d=C["MotionApi.getMotionTrajectorySample"])==null?void 0:d[l])==null?void 0:u.url;return(p,m)=>T(i,O,w,e)(p,c||m)},async getPlannedMotion(r,a,n,o){var c,d;const s=await t.getPlannedMotion(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["MotionApi.getPlannedMotion"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async getPlanningMotionGroupModels(r,a){var i,l;const n=await t.getPlanningMotionGroupModels(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["MotionApi.getPlanningMotionGroupModels"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async listMotions(r,a){var i,l;const n=await t.listMotions(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["MotionApi.listMotions"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async loadPlannedMotion(r,a,n){var l,c;const o=await t.loadPlannedMotion(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionApi.loadPlannedMotion"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async planCollisionFreePTP(r,a,n){var l,c;const o=await t.planCollisionFreePTP(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionApi.planCollisionFreePTP"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async planMotion(r,a,n){var l,c;const o=await t.planMotion(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionApi.planMotion"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async planTrajectory(r,a,n){var l,c;const o=await t.planTrajectory(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionApi.planTrajectory"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async stopExecution(r,a,n){var l,c;const o=await t.stopExecution(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionApi.stopExecution"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async streamMove(r,a,n){var l,c;const o=await t.streamMove(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionApi.streamMove"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async streamMoveBackward(r,a,n,o,s,i,l){var p,m;const c=await t.streamMoveBackward(r,a,n,o,s,i,l),d=(e==null?void 0:e.serverIndex)??0,u=(m=(p=C["MotionApi.streamMoveBackward"])==null?void 0:p[d])==null?void 0:m.url;return(g,h)=>T(c,O,w,e)(g,u||h)},async streamMoveForward(r,a,n,o,s,i,l){var p,m;const c=await t.streamMoveForward(r,a,n,o,s,i,l),d=(e==null?void 0:e.serverIndex)??0,u=(m=(p=C["MotionApi.streamMoveForward"])==null?void 0:p[d])==null?void 0:m.url;return(g,h)=>T(c,O,w,e)(g,u||h)},async streamMoveToTrajectoryViaJointPTP(r,a,n,o,s,i,l,c,d,u,p){var x,E;const m=await t.streamMoveToTrajectoryViaJointPTP(r,a,n,o,s,i,l,c,d,u,p),g=(e==null?void 0:e.serverIndex)??0,h=(E=(x=C["MotionApi.streamMoveToTrajectoryViaJointPTP"])==null?void 0:x[g])==null?void 0:E.url;return(U,F)=>T(m,O,w,e)(U,h||F)}}};class _v extends Pe{deleteAllMotions(t,r){return ze(this.configuration).deleteAllMotions(t,r).then(a=>a(this.axios,this.basePath))}deleteMotion(t,r,a){return ze(this.configuration).deleteMotion(t,r,a).then(n=>n(this.axios,this.basePath))}executeTrajectory(t,r,a){return ze(this.configuration).executeTrajectory(t,r,a).then(n=>n(this.axios,this.basePath))}getMotionTrajectory(t,r,a,n,o){return ze(this.configuration).getMotionTrajectory(t,r,a,n,o).then(s=>s(this.axios,this.basePath))}getMotionTrajectorySample(t,r,a,n,o){return ze(this.configuration).getMotionTrajectorySample(t,r,a,n,o).then(s=>s(this.axios,this.basePath))}getPlannedMotion(t,r,a,n){return ze(this.configuration).getPlannedMotion(t,r,a,n).then(o=>o(this.axios,this.basePath))}getPlanningMotionGroupModels(t,r){return ze(this.configuration).getPlanningMotionGroupModels(t,r).then(a=>a(this.axios,this.basePath))}listMotions(t,r){return ze(this.configuration).listMotions(t,r).then(a=>a(this.axios,this.basePath))}loadPlannedMotion(t,r,a){return ze(this.configuration).loadPlannedMotion(t,r,a).then(n=>n(this.axios,this.basePath))}planCollisionFreePTP(t,r,a){return ze(this.configuration).planCollisionFreePTP(t,r,a).then(n=>n(this.axios,this.basePath))}planMotion(t,r,a){return ze(this.configuration).planMotion(t,r,a).then(n=>n(this.axios,this.basePath))}planTrajectory(t,r,a){return ze(this.configuration).planTrajectory(t,r,a).then(n=>n(this.axios,this.basePath))}stopExecution(t,r,a){return ze(this.configuration).stopExecution(t,r,a).then(n=>n(this.axios,this.basePath))}streamMove(t,r,a){return ze(this.configuration).streamMove(t,r,a).then(n=>n(this.axios,this.basePath))}streamMoveBackward(t,r,a,n,o,s,i){return ze(this.configuration).streamMoveBackward(t,r,a,n,o,s,i).then(l=>l(this.axios,this.basePath))}streamMoveForward(t,r,a,n,o,s,i){return ze(this.configuration).streamMoveForward(t,r,a,n,o,s,i).then(l=>l(this.axios,this.basePath))}streamMoveToTrajectoryViaJointPTP(t,r,a,n,o,s,i,l,c,d,u){return ze(this.configuration).streamMoveToTrajectoryViaJointPTP(t,r,a,n,o,s,i,l,c,d,u).then(p=>p(this.axios,this.basePath))}}const Av=function(e){return{activateAllMotionGroups:async(t,r,a={})=>{f("activateAllMotionGroups","cell",t),f("activateAllMotionGroups","controller",r);const n="/cells/{cell}/motion-groups/all".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...a},l={},c={};V(i,e),await R(l,e),r!==void 0&&(c.controller=r),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},activateMotionGroup:async(t,r,a={})=>{f("activateMotionGroup","cell",t),f("activateMotionGroup","motionGroup",r);const n="/cells/{cell}/motion-groups".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...a},l={},c={};V(i,e),await R(l,e),r!==void 0&&(c.motion_group=r),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},deactivateMotionGroup:async(t,r,a={})=>{f("deactivateMotionGroup","cell",t),f("deactivateMotionGroup","motionGroup",r);const n="/cells/{cell}/motion-groups/{motion-group}".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listMotionGroups:async(t,r={})=>{f("listMotionGroups","cell",t);const a="/cells/{cell}/motion-groups".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}}}},Xa=function(e){const t=Av(e);return{async activateAllMotionGroups(r,a,n){var l,c;const o=await t.activateAllMotionGroups(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupApi.activateAllMotionGroups"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async activateMotionGroup(r,a,n){var l,c;const o=await t.activateMotionGroup(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupApi.activateMotionGroup"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async deactivateMotionGroup(r,a,n){var l,c;const o=await t.deactivateMotionGroup(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupApi.deactivateMotionGroup"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listMotionGroups(r,a){var i,l;const n=await t.listMotionGroups(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["MotionGroupApi.listMotionGroups"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)}}};class Tv extends Pe{activateAllMotionGroups(t,r,a){return Xa(this.configuration).activateAllMotionGroups(t,r,a).then(n=>n(this.axios,this.basePath))}activateMotionGroup(t,r,a){return Xa(this.configuration).activateMotionGroup(t,r,a).then(n=>n(this.axios,this.basePath))}deactivateMotionGroup(t,r,a){return Xa(this.configuration).deactivateMotionGroup(t,r,a).then(n=>n(this.axios,this.basePath))}listMotionGroups(t,r){return Xa(this.configuration).listMotionGroups(t,r).then(a=>a(this.axios,this.basePath))}}const Ev=function(e){return{getActivePayload:async(t,r,a={})=>{f("getActivePayload","cell",t),f("getActivePayload","motionGroup",r);const n="/cells/{cell}/motion-groups/{motion-group}/payloads/current".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getActiveTcp:async(t,r,a,n={})=>{f("getActiveTcp","cell",t),f("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,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.rotation_type=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},getCurrentMotionGroupState:async(t,r,a,n,o={})=>{f("getCurrentMotionGroupState","cell",t),f("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,P);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},d={},u={};V(c,e),await R(d,e),a!==void 0&&(u.tcp=a),n!==void 0&&(u.response_coordinate_system=n),_(i,u);let p=l&&l.headers?l.headers:{};return c.headers={...d,...p,...o.headers},{url:A(i),options:c}},getInfoCapabilities:async(t,r,a={})=>{f("getInfoCapabilities","cell",t),f("getInfoCapabilities","motionGroup",r);const n="/cells/{cell}/motion-groups/{motion-group}/info-capabilities".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getMotionGroupSpecification:async(t,r,a={})=>{f("getMotionGroupSpecification","cell",t),f("getMotionGroupSpecification","motionGroup",r);const n="/cells/{cell}/motion-groups/{motion-group}/specification".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getMounting:async(t,r,a={})=>{f("getMounting","cell",t),f("getMounting","motionGroup",r);const n="/cells/{cell}/motion-groups/{motion-group}/mounting".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getOptimizerConfiguration:async(t,r,a,n={})=>{f("getOptimizerConfiguration","cell",t),f("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,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.tcp=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},getSafetySetup:async(t,r,a={})=>{f("getSafetySetup","cell",t),f("getSafetySetup","motionGroup",r);const n="/cells/{cell}/motion-groups/{motion-group}/safety-setup".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listPayloads:async(t,r,a={})=>{f("listPayloads","cell",t),f("listPayloads","motionGroup",r);const n="/cells/{cell}/motion-groups/{motion-group}/payloads".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listTcps:async(t,r,a,n={})=>{f("listTcps","cell",t),f("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,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.rotation_type=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},streamMotionGroupState:async(t,r,a,n,o,s={})=>{f("streamMotionGroupState","cell",t),f("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,P);let c;e&&(c=e.baseOptions);const d={method:"GET",...c,...s},u={},p={};V(d,e),await R(u,e),a!==void 0&&(p.response_rate=a),n!==void 0&&(p.response_coordinate_system=n),o!==void 0&&(p.tcp=o),_(l,p);let m=c&&c.headers?c.headers:{};return d.headers={...u,...m,...s.headers},{url:A(l),options:d}}}},pt=function(e){const t=Ev(e);return{async getActivePayload(r,a,n){var l,c;const o=await t.getActivePayload(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupInfosApi.getActivePayload"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getActiveTcp(r,a,n,o){var c,d;const s=await t.getActiveTcp(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["MotionGroupInfosApi.getActiveTcp"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async getCurrentMotionGroupState(r,a,n,o,s){var d,u;const i=await t.getCurrentMotionGroupState(r,a,n,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(u=(d=C["MotionGroupInfosApi.getCurrentMotionGroupState"])==null?void 0:d[l])==null?void 0:u.url;return(p,m)=>T(i,O,w,e)(p,c||m)},async getInfoCapabilities(r,a,n){var l,c;const o=await t.getInfoCapabilities(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupInfosApi.getInfoCapabilities"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getMotionGroupSpecification(r,a,n){var l,c;const o=await t.getMotionGroupSpecification(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupInfosApi.getMotionGroupSpecification"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getMounting(r,a,n){var l,c;const o=await t.getMounting(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupInfosApi.getMounting"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getOptimizerConfiguration(r,a,n,o){var c,d;const s=await t.getOptimizerConfiguration(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["MotionGroupInfosApi.getOptimizerConfiguration"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async getSafetySetup(r,a,n){var l,c;const o=await t.getSafetySetup(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupInfosApi.getSafetySetup"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listPayloads(r,a,n){var l,c;const o=await t.listPayloads(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupInfosApi.listPayloads"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listTcps(r,a,n,o){var c,d;const s=await t.listTcps(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["MotionGroupInfosApi.listTcps"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async streamMotionGroupState(r,a,n,o,s,i){var u,p;const l=await t.streamMotionGroupState(r,a,n,o,s,i),c=(e==null?void 0:e.serverIndex)??0,d=(p=(u=C["MotionGroupInfosApi.streamMotionGroupState"])==null?void 0:u[c])==null?void 0:p.url;return(m,g)=>T(l,O,w,e)(m,d||g)}}};class Iv extends Pe{getActivePayload(t,r,a){return pt(this.configuration).getActivePayload(t,r,a).then(n=>n(this.axios,this.basePath))}getActiveTcp(t,r,a,n){return pt(this.configuration).getActiveTcp(t,r,a,n).then(o=>o(this.axios,this.basePath))}getCurrentMotionGroupState(t,r,a,n,o){return pt(this.configuration).getCurrentMotionGroupState(t,r,a,n,o).then(s=>s(this.axios,this.basePath))}getInfoCapabilities(t,r,a){return pt(this.configuration).getInfoCapabilities(t,r,a).then(n=>n(this.axios,this.basePath))}getMotionGroupSpecification(t,r,a){return pt(this.configuration).getMotionGroupSpecification(t,r,a).then(n=>n(this.axios,this.basePath))}getMounting(t,r,a){return pt(this.configuration).getMounting(t,r,a).then(n=>n(this.axios,this.basePath))}getOptimizerConfiguration(t,r,a,n){return pt(this.configuration).getOptimizerConfiguration(t,r,a,n).then(o=>o(this.axios,this.basePath))}getSafetySetup(t,r,a){return pt(this.configuration).getSafetySetup(t,r,a).then(n=>n(this.axios,this.basePath))}listPayloads(t,r,a){return pt(this.configuration).listPayloads(t,r,a).then(n=>n(this.axios,this.basePath))}listTcps(t,r,a,n){return pt(this.configuration).listTcps(t,r,a,n).then(o=>o(this.axios,this.basePath))}streamMotionGroupState(t,r,a,n,o,s){return pt(this.configuration).streamMotionGroupState(t,r,a,n,o,s).then(i=>i(this.axios,this.basePath))}}const Mv=function(e){return{directionJogging:async(t,r,a={})=>{f("directionJogging","cell",t),f("directionJogging","directionJoggingRequest",r);const n="/cells/{cell}/motion-groups/move-tcp".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="application/json",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},getJoggingCapabilities:async(t,r,a={})=>{f("getJoggingCapabilities","cell",t),f("getJoggingCapabilities","motionGroup",r);const n="/cells/{cell}/motion-groups/{motion-group}/jogging-capabilities".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},jointJogging:async(t,r,a={})=>{f("jointJogging","cell",t),f("jointJogging","jointJoggingRequest",r);const n="/cells/{cell}/motion-groups/move-joint".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="application/json",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},stopJogging:async(t,r,a={})=>{f("stopJogging","cell",t),f("stopJogging","motionGroup",r);const n="/cells/{cell}/motion-groups/{motion-group}/stop".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}}}},Za=function(e){const t=Mv(e);return{async directionJogging(r,a,n){var l,c;const o=await t.directionJogging(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupJoggingApi.directionJogging"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getJoggingCapabilities(r,a,n){var l,c;const o=await t.getJoggingCapabilities(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupJoggingApi.getJoggingCapabilities"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async jointJogging(r,a,n){var l,c;const o=await t.jointJogging(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupJoggingApi.jointJogging"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async stopJogging(r,a,n){var l,c;const o=await t.stopJogging(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupJoggingApi.stopJogging"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)}}};class jv extends Pe{directionJogging(t,r,a){return Za(this.configuration).directionJogging(t,r,a).then(n=>n(this.axios,this.basePath))}getJoggingCapabilities(t,r,a){return Za(this.configuration).getJoggingCapabilities(t,r,a).then(n=>n(this.axios,this.basePath))}jointJogging(t,r,a){return Za(this.configuration).jointJogging(t,r,a).then(n=>n(this.axios,this.basePath))}stopJogging(t,r,a){return Za(this.configuration).stopJogging(t,r,a).then(n=>n(this.axios,this.basePath))}}const $v=function(e){return{calculateAllInverseKinematic:async(t,r,a,n={})=>{f("calculateAllInverseKinematic","cell",t),f("calculateAllInverseKinematic","motionGroup",r),f("calculateAllInverseKinematic","allJointPositionsRequest",a);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,P);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}},calculateForwardKinematic:async(t,r,a,n={})=>{f("calculateForwardKinematic","cell",t),f("calculateForwardKinematic","motionGroup",r),f("calculateForwardKinematic","tcpPoseRequest",a);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,P);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}},calculateInverseKinematic:async(t,r,a,n={})=>{f("calculateInverseKinematic","cell",t),f("calculateInverseKinematic","motionGroup",r),f("calculateInverseKinematic","jointPositionRequest",a);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,P);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}},getKinematicCapabilities:async(t,r,a={})=>{f("getKinematicCapabilities","cell",t),f("getKinematicCapabilities","motionGroup",r);const n="/cells/{cell}/motion-groups/{motion-group}/kinematic-capabilities".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}}}},en=function(e){const t=$v(e);return{async calculateAllInverseKinematic(r,a,n,o){var c,d;const s=await t.calculateAllInverseKinematic(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["MotionGroupKinematicApi.calculateAllInverseKinematic"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async calculateForwardKinematic(r,a,n,o){var c,d;const s=await t.calculateForwardKinematic(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["MotionGroupKinematicApi.calculateForwardKinematic"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async calculateInverseKinematic(r,a,n,o){var c,d;const s=await t.calculateInverseKinematic(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["MotionGroupKinematicApi.calculateInverseKinematic"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async getKinematicCapabilities(r,a,n){var l,c;const o=await t.getKinematicCapabilities(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["MotionGroupKinematicApi.getKinematicCapabilities"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)}}};class Uv extends Pe{calculateAllInverseKinematic(t,r,a,n){return en(this.configuration).calculateAllInverseKinematic(t,r,a,n).then(o=>o(this.axios,this.basePath))}calculateForwardKinematic(t,r,a,n){return en(this.configuration).calculateForwardKinematic(t,r,a,n).then(o=>o(this.axios,this.basePath))}calculateInverseKinematic(t,r,a,n){return en(this.configuration).calculateInverseKinematic(t,r,a,n).then(o=>o(this.axios,this.basePath))}getKinematicCapabilities(t,r,a){return en(this.configuration).getKinematicCapabilities(t,r,a).then(n=>n(this.axios,this.basePath))}}const Lv=function(e){return{createProgramRunner:async(t,r,a={})=>{f("createProgramRunner","cell",t),f("createProgramRunner","request",r);const n="/cells/{cell}/programs/runners".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="text/plain",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},executeProgram:async(t,r,a={})=>{f("executeProgram","cell",t),f("executeProgram","codeWithArguments",r);const n="/cells/{cell}/programs/execute".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="application/json",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},getProgramRunner:async(t,r,a={})=>{f("getProgramRunner","cell",t),f("getProgramRunner","runner",r);const n="/cells/{cell}/programs/runners/{runner}".replace("{cell}",encodeURIComponent(String(t))).replace("{runner}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listProgramRunners:async(t,r={})=>{f("listProgramRunners","cell",t);const a="/cells/{cell}/programs/runners".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},migrateProgram:async(t,r,a={})=>{f("migrateProgram","cell",t),f("migrateProgram","request1",r);const n="/cells/{cell}/programs/migrate".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="text/plain",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},planProgram:async(t,r,a,n={})=>{f("planProgram","cell",t),f("planProgram","request",r);const o="/cells/{cell}/programs/plan".replace("{cell}",encodeURIComponent(String(t))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.identifier=a),c["Content-Type"]="text/plain",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(r,l,e),{url:A(s),options:l}},stopAllProgramRunner:async(t,r={})=>{f("stopAllProgramRunner","cell",t);const a="/cells/{cell}/programs/runners/stop".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"POST",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},stopProgramRunner:async(t,r,a={})=>{f("stopProgramRunner","cell",t),f("stopProgramRunner","runner",r);const n="/cells/{cell}/programs/runners/{runner}/stop".replace("{cell}",encodeURIComponent(String(t))).replace("{runner}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}}}},Jt=function(e){const t=Lv(e);return{async createProgramRunner(r,a,n){var l,c;const o=await t.createProgramRunner(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ProgramApi.createProgramRunner"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async executeProgram(r,a,n){var l,c;const o=await t.executeProgram(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ProgramApi.executeProgram"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getProgramRunner(r,a,n){var l,c;const o=await t.getProgramRunner(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ProgramApi.getProgramRunner"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listProgramRunners(r,a){var i,l;const n=await t.listProgramRunners(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["ProgramApi.listProgramRunners"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async migrateProgram(r,a,n){var l,c;const o=await t.migrateProgram(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ProgramApi.migrateProgram"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async planProgram(r,a,n,o){var c,d;const s=await t.planProgram(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["ProgramApi.planProgram"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async stopAllProgramRunner(r,a){var i,l;const n=await t.stopAllProgramRunner(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["ProgramApi.stopAllProgramRunner"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async stopProgramRunner(r,a,n){var l,c;const o=await t.stopProgramRunner(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ProgramApi.stopProgramRunner"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)}}};class kv extends Pe{createProgramRunner(t,r,a){return Jt(this.configuration).createProgramRunner(t,r,a).then(n=>n(this.axios,this.basePath))}executeProgram(t,r,a){return Jt(this.configuration).executeProgram(t,r,a).then(n=>n(this.axios,this.basePath))}getProgramRunner(t,r,a){return Jt(this.configuration).getProgramRunner(t,r,a).then(n=>n(this.axios,this.basePath))}listProgramRunners(t,r){return Jt(this.configuration).listProgramRunners(t,r).then(a=>a(this.axios,this.basePath))}migrateProgram(t,r,a){return Jt(this.configuration).migrateProgram(t,r,a).then(n=>n(this.axios,this.basePath))}planProgram(t,r,a,n){return Jt(this.configuration).planProgram(t,r,a,n).then(o=>o(this.axios,this.basePath))}stopAllProgramRunner(t,r){return Jt(this.configuration).stopAllProgramRunner(t,r).then(a=>a(this.axios,this.basePath))}stopProgramRunner(t,r,a){return Jt(this.configuration).stopProgramRunner(t,r,a).then(n=>n(this.axios,this.basePath))}}const Bv=function(e){return{clearProgramsValues:async(t,r={})=>{f("clearProgramsValues","cell",t);const a="/cells/{cell}/programs/values".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"DELETE",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},createProgramsValue:async(t,r,a={})=>{f("createProgramsValue","cell",t),f("createProgramsValue","requestBody",r);const n="/cells/{cell}/programs/values".replace("{cell}",encodeURIComponent(String(t))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"POST",...s,...a},l={},c={};V(i,e),await R(l,e),l["Content-Type"]="application/json",_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},i.data=se(r,i,e),{url:A(o),options:i}},deleteProgramValue:async(t,r,a={})=>{f("deleteProgramValue","cell",t),f("deleteProgramValue","key",r);const n="/cells/{cell}/programs/values/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getProgramValue:async(t,r,a={})=>{f("getProgramValue","cell",t),f("getProgramValue","key",r);const n="/cells/{cell}/programs/values/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listProgramsValues:async(t,r={})=>{f("listProgramsValues","cell",t);const a="/cells/{cell}/programs/values".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},updateProgramValue:async(t,r,a,n={})=>{f("updateProgramValue","cell",t),f("updateProgramValue","key",r),f("updateProgramValue","value",a);const o="/cells/{cell}/programs/values/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}}}},$r=function(e){const t=Bv(e);return{async clearProgramsValues(r,a){var i,l;const n=await t.clearProgramsValues(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["ProgramValuesApi.clearProgramsValues"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async createProgramsValue(r,a,n){var l,c;const o=await t.createProgramsValue(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ProgramValuesApi.createProgramsValue"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async deleteProgramValue(r,a,n){var l,c;const o=await t.deleteProgramValue(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ProgramValuesApi.deleteProgramValue"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getProgramValue(r,a,n){var l,c;const o=await t.getProgramValue(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["ProgramValuesApi.getProgramValue"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listProgramsValues(r,a){var i,l;const n=await t.listProgramsValues(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["ProgramValuesApi.listProgramsValues"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async updateProgramValue(r,a,n,o){var c,d;const s=await t.updateProgramValue(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["ProgramValuesApi.updateProgramValue"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)}}};class Fv extends Pe{clearProgramsValues(t,r){return $r(this.configuration).clearProgramsValues(t,r).then(a=>a(this.axios,this.basePath))}createProgramsValue(t,r,a){return $r(this.configuration).createProgramsValue(t,r,a).then(n=>n(this.axios,this.basePath))}deleteProgramValue(t,r,a){return $r(this.configuration).deleteProgramValue(t,r,a).then(n=>n(this.axios,this.basePath))}getProgramValue(t,r,a){return $r(this.configuration).getProgramValue(t,r,a).then(n=>n(this.axios,this.basePath))}listProgramsValues(t,r){return $r(this.configuration).listProgramsValues(t,r).then(a=>a(this.axios,this.basePath))}updateProgramValue(t,r,a,n){return $r(this.configuration).updateProgramValue(t,r,a,n).then(o=>o(this.axios,this.basePath))}}const Nv=function(e){return{deleteStoredCollider:async(t,r,a={})=>{f("deleteStoredCollider","cell",t),f("deleteStoredCollider","collider",r);const n="/cells/{cell}/store/collision/colliders/{collider}".replace("{cell}",encodeURIComponent(String(t))).replace("{collider}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},deleteStoredCollisionLinkChain:async(t,r,a={})=>{f("deleteStoredCollisionLinkChain","cell",t),f("deleteStoredCollisionLinkChain","linkChain",r);const n="/cells/{cell}/store/collision/link-chains/{link-chain}".replace("{cell}",encodeURIComponent(String(t))).replace("{link-chain}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},deleteStoredCollisionTool:async(t,r,a={})=>{f("deleteStoredCollisionTool","cell",t),f("deleteStoredCollisionTool","tool",r);const n="/cells/{cell}/store/collision/tools/{tool}".replace("{cell}",encodeURIComponent(String(t))).replace("{tool}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getDefaultLinkChain:async(t,r,a={})=>{f("getDefaultLinkChain","cell",t),f("getDefaultLinkChain","motionGroupModel",r);const n="/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(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getStoredCollider:async(t,r,a={})=>{f("getStoredCollider","cell",t),f("getStoredCollider","collider",r);const n="/cells/{cell}/store/collision/colliders/{collider}".replace("{cell}",encodeURIComponent(String(t))).replace("{collider}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getStoredCollisionLinkChain:async(t,r,a={})=>{f("getStoredCollisionLinkChain","cell",t),f("getStoredCollisionLinkChain","linkChain",r);const n="/cells/{cell}/store/collision/link-chains/{link-chain}".replace("{cell}",encodeURIComponent(String(t))).replace("{link-chain}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getStoredCollisionTool:async(t,r,a={})=>{f("getStoredCollisionTool","cell",t),f("getStoredCollisionTool","tool",r);const n="/cells/{cell}/store/collision/tools/{tool}".replace("{cell}",encodeURIComponent(String(t))).replace("{tool}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listCollisionLinkChains:async(t,r={})=>{f("listCollisionLinkChains","cell",t);const a="/cells/{cell}/store/collision/link-chains".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},listStoredColliders:async(t,r={})=>{f("listStoredColliders","cell",t);const a="/cells/{cell}/store/collision/colliders".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},listStoredCollisionTools:async(t,r={})=>{f("listStoredCollisionTools","cell",t);const a="/cells/{cell}/store/collision/tools".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},storeCollider:async(t,r,a,n={})=>{f("storeCollider","cell",t),f("storeCollider","collider",r),f("storeCollider","collider2",a);const o="/cells/{cell}/store/collision/colliders/{collider}".replace("{cell}",encodeURIComponent(String(t))).replace("{collider}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}},storeCollisionLinkChain:async(t,r,a,n={})=>{f("storeCollisionLinkChain","cell",t),f("storeCollisionLinkChain","linkChain",r),f("storeCollisionLinkChain","collider",a);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,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}},storeCollisionTool:async(t,r,a,n={})=>{f("storeCollisionTool","cell",t),f("storeCollisionTool","tool",r),f("storeCollisionTool","requestBody",a);const o="/cells/{cell}/store/collision/tools/{tool}".replace("{cell}",encodeURIComponent(String(t))).replace("{tool}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}}}},tt=function(e){const t=Nv(e);return{async deleteStoredCollider(r,a,n){var l,c;const o=await t.deleteStoredCollider(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["StoreCollisionComponentsApi.deleteStoredCollider"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async deleteStoredCollisionLinkChain(r,a,n){var l,c;const o=await t.deleteStoredCollisionLinkChain(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["StoreCollisionComponentsApi.deleteStoredCollisionLinkChain"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async deleteStoredCollisionTool(r,a,n){var l,c;const o=await t.deleteStoredCollisionTool(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["StoreCollisionComponentsApi.deleteStoredCollisionTool"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getDefaultLinkChain(r,a,n){var l,c;const o=await t.getDefaultLinkChain(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["StoreCollisionComponentsApi.getDefaultLinkChain"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getStoredCollider(r,a,n){var l,c;const o=await t.getStoredCollider(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["StoreCollisionComponentsApi.getStoredCollider"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getStoredCollisionLinkChain(r,a,n){var l,c;const o=await t.getStoredCollisionLinkChain(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["StoreCollisionComponentsApi.getStoredCollisionLinkChain"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getStoredCollisionTool(r,a,n){var l,c;const o=await t.getStoredCollisionTool(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["StoreCollisionComponentsApi.getStoredCollisionTool"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listCollisionLinkChains(r,a){var i,l;const n=await t.listCollisionLinkChains(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["StoreCollisionComponentsApi.listCollisionLinkChains"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async listStoredColliders(r,a){var i,l;const n=await t.listStoredColliders(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["StoreCollisionComponentsApi.listStoredColliders"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async listStoredCollisionTools(r,a){var i,l;const n=await t.listStoredCollisionTools(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["StoreCollisionComponentsApi.listStoredCollisionTools"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async storeCollider(r,a,n,o){var c,d;const s=await t.storeCollider(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["StoreCollisionComponentsApi.storeCollider"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async storeCollisionLinkChain(r,a,n,o){var c,d;const s=await t.storeCollisionLinkChain(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["StoreCollisionComponentsApi.storeCollisionLinkChain"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async storeCollisionTool(r,a,n,o){var c,d;const s=await t.storeCollisionTool(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["StoreCollisionComponentsApi.storeCollisionTool"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)}}};class Dv extends Pe{deleteStoredCollider(t,r,a){return tt(this.configuration).deleteStoredCollider(t,r,a).then(n=>n(this.axios,this.basePath))}deleteStoredCollisionLinkChain(t,r,a){return tt(this.configuration).deleteStoredCollisionLinkChain(t,r,a).then(n=>n(this.axios,this.basePath))}deleteStoredCollisionTool(t,r,a){return tt(this.configuration).deleteStoredCollisionTool(t,r,a).then(n=>n(this.axios,this.basePath))}getDefaultLinkChain(t,r,a){return tt(this.configuration).getDefaultLinkChain(t,r,a).then(n=>n(this.axios,this.basePath))}getStoredCollider(t,r,a){return tt(this.configuration).getStoredCollider(t,r,a).then(n=>n(this.axios,this.basePath))}getStoredCollisionLinkChain(t,r,a){return tt(this.configuration).getStoredCollisionLinkChain(t,r,a).then(n=>n(this.axios,this.basePath))}getStoredCollisionTool(t,r,a){return tt(this.configuration).getStoredCollisionTool(t,r,a).then(n=>n(this.axios,this.basePath))}listCollisionLinkChains(t,r){return tt(this.configuration).listCollisionLinkChains(t,r).then(a=>a(this.axios,this.basePath))}listStoredColliders(t,r){return tt(this.configuration).listStoredColliders(t,r).then(a=>a(this.axios,this.basePath))}listStoredCollisionTools(t,r){return tt(this.configuration).listStoredCollisionTools(t,r).then(a=>a(this.axios,this.basePath))}storeCollider(t,r,a,n){return tt(this.configuration).storeCollider(t,r,a,n).then(o=>o(this.axios,this.basePath))}storeCollisionLinkChain(t,r,a,n){return tt(this.configuration).storeCollisionLinkChain(t,r,a,n).then(o=>o(this.axios,this.basePath))}storeCollisionTool(t,r,a,n){return tt(this.configuration).storeCollisionTool(t,r,a,n).then(o=>o(this.axios,this.basePath))}}const zv=function(e){return{deleteStoredCollisionScene:async(t,r,a={})=>{f("deleteStoredCollisionScene","cell",t),f("deleteStoredCollisionScene","scene",r);const n="/cells/{cell}/store/collision/scenes/{scene}".replace("{cell}",encodeURIComponent(String(t))).replace("{scene}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getStoredCollisionScene:async(t,r,a={})=>{f("getStoredCollisionScene","cell",t),f("getStoredCollisionScene","scene",r);const n="/cells/{cell}/store/collision/scenes/{scene}".replace("{cell}",encodeURIComponent(String(t))).replace("{scene}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listStoredCollisionScenes:async(t,r={})=>{f("listStoredCollisionScenes","cell",t);const a="/cells/{cell}/store/collision/scenes".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},storeCollisionScene:async(t,r,a,n={})=>{f("storeCollisionScene","cell",t),f("storeCollisionScene","scene",r),f("storeCollisionScene","collisionSceneAssembly",a);const o="/cells/{cell}/store/collision/scenes/{scene}".replace("{cell}",encodeURIComponent(String(t))).replace("{scene}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}}}},tn=function(e){const t=zv(e);return{async deleteStoredCollisionScene(r,a,n){var l,c;const o=await t.deleteStoredCollisionScene(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["StoreCollisionScenesApi.deleteStoredCollisionScene"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getStoredCollisionScene(r,a,n){var l,c;const o=await t.getStoredCollisionScene(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["StoreCollisionScenesApi.getStoredCollisionScene"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listStoredCollisionScenes(r,a){var i,l;const n=await t.listStoredCollisionScenes(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["StoreCollisionScenesApi.listStoredCollisionScenes"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async storeCollisionScene(r,a,n,o){var c,d;const s=await t.storeCollisionScene(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["StoreCollisionScenesApi.storeCollisionScene"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)}}};class Gv extends Pe{deleteStoredCollisionScene(t,r,a){return tn(this.configuration).deleteStoredCollisionScene(t,r,a).then(n=>n(this.axios,this.basePath))}getStoredCollisionScene(t,r,a){return tn(this.configuration).getStoredCollisionScene(t,r,a).then(n=>n(this.axios,this.basePath))}listStoredCollisionScenes(t,r){return tn(this.configuration).listStoredCollisionScenes(t,r).then(a=>a(this.axios,this.basePath))}storeCollisionScene(t,r,a,n){return tn(this.configuration).storeCollisionScene(t,r,a,n).then(o=>o(this.axios,this.basePath))}}const Jv=function(e){return{clearAllObjects:async(t,r={})=>{f("clearAllObjects","cell",t);const a="/cells/{cell}/store/objects".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"DELETE",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},deleteObject:async(t,r,a={})=>{f("deleteObject","cell",t),f("deleteObject","key",r);const n="/cells/{cell}/store/objects/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"DELETE",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getObject:async(t,r,a={})=>{f("getObject","cell",t),f("getObject","key",r);const n="/cells/{cell}/store/objects/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getObjectMetadata:async(t,r,a={})=>{f("getObjectMetadata","cell",t),f("getObjectMetadata","key",r);const n="/cells/{cell}/store/objects/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"HEAD",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listAllObjectKeys:async(t,r={})=>{f("listAllObjectKeys","cell",t);const a="/cells/{cell}/store/objects".replace("{cell}",encodeURIComponent(String(t))),n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},storeObject:async(t,r,a,n,o={})=>{f("storeObject","cell",t),f("storeObject","key",r);const s="/cells/{cell}/store/objects/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),i=new URL(s,P);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},d={},u={},p=new(e&&e.formDataCtor||FormData);V(c,e),await R(d,e),n!==void 0&&p.append("AnyValue",new Blob([JSON.stringify(n)],{type:"application/json"})),d["Content-Type"]="multipart/form-data",a!=null&&(d["X-Metadata"]=typeof a=="string"?a:JSON.stringify(a)),_(i,u);let m=l&&l.headers?l.headers:{};return c.headers={...d,...m,...o.headers},c.data=p,{url:A(i),options:c}}}},Ur=function(e){const t=Jv(e);return{async clearAllObjects(r,a){var i,l;const n=await t.clearAllObjects(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["StoreObjectApi.clearAllObjects"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async deleteObject(r,a,n){var l,c;const o=await t.deleteObject(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["StoreObjectApi.deleteObject"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getObject(r,a,n){var l,c;const o=await t.getObject(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["StoreObjectApi.getObject"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getObjectMetadata(r,a,n){var l,c;const o=await t.getObjectMetadata(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["StoreObjectApi.getObjectMetadata"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listAllObjectKeys(r,a){var i,l;const n=await t.listAllObjectKeys(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["StoreObjectApi.listAllObjectKeys"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async storeObject(r,a,n,o,s){var d,u;const i=await t.storeObject(r,a,n,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(u=(d=C["StoreObjectApi.storeObject"])==null?void 0:d[l])==null?void 0:u.url;return(p,m)=>T(i,O,w,e)(p,c||m)}}};class Hv extends Pe{clearAllObjects(t,r){return Ur(this.configuration).clearAllObjects(t,r).then(a=>a(this.axios,this.basePath))}deleteObject(t,r,a){return Ur(this.configuration).deleteObject(t,r,a).then(n=>n(this.axios,this.basePath))}getObject(t,r,a){return Ur(this.configuration).getObject(t,r,a).then(n=>n(this.axios,this.basePath))}getObjectMetadata(t,r,a){return Ur(this.configuration).getObjectMetadata(t,r,a).then(n=>n(this.axios,this.basePath))}listAllObjectKeys(t,r){return Ur(this.configuration).listAllObjectKeys(t,r).then(a=>a(this.axios,this.basePath))}storeObject(t,r,a,n,o){return Ur(this.configuration).storeObject(t,r,a,n,o).then(s=>s(this.axios,this.basePath))}}const qv=function(e){return{checkNovaVersionUpdate:async(t,r={})=>{f("checkNovaVersionUpdate","channel",t);const a="/system/update",n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"GET",...o,...r},i={},l={};V(s,e),await R(i,e),t!==void 0&&(l.channel=t),_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},{url:A(n),options:s}},getDiagnosePackage:async(t={})=>{const r="/system/diagnosis-package/zip",a=new URL(r,P);let n;e&&(n=e.baseOptions);const o={method:"GET",...n,...t},s={},i={};V(o,e),await R(s,e),_(a,i);let l=n&&n.headers?n.headers:{};return o.headers={...s,...l,...t.headers},{url:A(a),options:o}},getSystemStatus:async(t={})=>{const r="/system/status",a=new URL(r,P);let n;e&&(n=e.baseOptions);const o={method:"GET",...n,...t},s={},i={};V(o,e),await R(s,e),_(a,i);let l=n&&n.headers?n.headers:{};return o.headers={...s,...l,...t.headers},{url:A(a),options:o}},getSystemVersion:async(t={})=>{const r="/system/version",a=new URL(r,P);let n;e&&(n=e.baseOptions);const o={method:"GET",...n,...t},s={},i={};V(o,e),await R(s,e),_(a,i);let l=n&&n.headers?n.headers:{};return o.headers={...s,...l,...t.headers},{url:A(a),options:o}},updateNovaVersion:async(t,r={})=>{f("updateNovaVersion","updateNovaVersionRequest",t);const a="/system/update",n=new URL(a,P);let o;e&&(o=e.baseOptions);const s={method:"PUT",...o,...r},i={},l={};V(s,e),await R(i,e),i["Content-Type"]="application/json",_(n,l);let c=o&&o.headers?o.headers:{};return s.headers={...i,...c,...r.headers},s.data=se(t,s,e),{url:A(n),options:s}}}},xa=function(e){const t=qv(e);return{async checkNovaVersionUpdate(r,a){var i,l;const n=await t.checkNovaVersionUpdate(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["SystemApi.checkNovaVersionUpdate"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)},async getDiagnosePackage(r){var s,i;const a=await t.getDiagnosePackage(r),n=(e==null?void 0:e.serverIndex)??0,o=(i=(s=C["SystemApi.getDiagnosePackage"])==null?void 0:s[n])==null?void 0:i.url;return(l,c)=>T(a,O,w,e)(l,o||c)},async getSystemStatus(r){var s,i;const a=await t.getSystemStatus(r),n=(e==null?void 0:e.serverIndex)??0,o=(i=(s=C["SystemApi.getSystemStatus"])==null?void 0:s[n])==null?void 0:i.url;return(l,c)=>T(a,O,w,e)(l,o||c)},async getSystemVersion(r){var s,i;const a=await t.getSystemVersion(r),n=(e==null?void 0:e.serverIndex)??0,o=(i=(s=C["SystemApi.getSystemVersion"])==null?void 0:s[n])==null?void 0:i.url;return(l,c)=>T(a,O,w,e)(l,o||c)},async updateNovaVersion(r,a){var i,l;const n=await t.updateNovaVersion(r,a),o=(e==null?void 0:e.serverIndex)??0,s=(l=(i=C["SystemApi.updateNovaVersion"])==null?void 0:i[o])==null?void 0:l.url;return(c,d)=>T(n,O,w,e)(c,s||d)}}};class Wv extends Pe{checkNovaVersionUpdate(t,r){return xa(this.configuration).checkNovaVersionUpdate(t,r).then(a=>a(this.axios,this.basePath))}getDiagnosePackage(t){return xa(this.configuration).getDiagnosePackage(t).then(r=>r(this.axios,this.basePath))}getSystemStatus(t){return xa(this.configuration).getSystemStatus(t).then(r=>r(this.axios,this.basePath))}getSystemVersion(t){return xa(this.configuration).getSystemVersion(t).then(r=>r(this.axios,this.basePath))}updateNovaVersion(t,r){return xa(this.configuration).updateNovaVersion(t,r).then(a=>a(this.axios,this.basePath))}}const Kv=function(e){return{getMotionGroupState:async(t,r,a,n={})=>{f("getMotionGroupState","cell",t),f("getMotionGroupState","controller",r),f("getMotionGroupState","id",a);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(a))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},getMotionGroups:async(t,r,a={})=>{f("getMotionGroups","cell",t),f("getMotionGroups","controller",r);const n="/cells/{cell}/controllers/{controller}/teach-pendant/motiongroups".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getVirtualRobotIOValue:async(t,r,a,n={})=>{f("getVirtualRobotIOValue","cell",t),f("getVirtualRobotIOValue","controller",r),f("getVirtualRobotIOValue","io",a);const o="/cells/{cell}/controllers/{controller}/teach-pendant/ios/{io}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{io}",encodeURIComponent(String(a))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},listIOs:async(t,r,a={})=>{f("listIOs","cell",t),f("listIOs","controller",r);const n="/cells/{cell}/controllers/{controller}/teach-pendant/ios".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},setMotionGroupState:async(t,r,a,n,o={})=>{f("setMotionGroupState","cell",t),f("setMotionGroupState","controller",r),f("setMotionGroupState","id",a),f("setMotionGroupState","motionGroupJoints",n);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(a))),i=new URL(s,P);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},d={},u={};V(c,e),await R(d,e),d["Content-Type"]="application/json",_(i,u);let p=l&&l.headers?l.headers:{};return c.headers={...d,...p,...o.headers},c.data=se(n,c,e),{url:A(i),options:c}},setVirtualRobotIOValue:async(t,r,a,n,o,s,i={})=>{f("setVirtualRobotIOValue","cell",t),f("setVirtualRobotIOValue","controller",r),f("setVirtualRobotIOValue","io",a);const l="/cells/{cell}/controllers/{controller}/teach-pendant/ios/{io}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{io}",encodeURIComponent(String(a))),c=new URL(l,P);let d;e&&(d=e.baseOptions);const u={method:"PUT",...d,...i},p={},m={};V(u,e),await R(p,e),n!==void 0&&(m.bool=n),o!==void 0&&(m.integer=o),s!==void 0&&(m.double=s),_(c,m);let g=d&&d.headers?d.headers:{};return u.headers={...p,...g,...i.headers},{url:A(c),options:u}}}},Lr=function(e){const t=Kv(e);return{async getMotionGroupState(r,a,n,o){var c,d;const s=await t.getMotionGroupState(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["VirtualRobotApi.getMotionGroupState"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async getMotionGroups(r,a,n){var l,c;const o=await t.getMotionGroups(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["VirtualRobotApi.getMotionGroups"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getVirtualRobotIOValue(r,a,n,o){var c,d;const s=await t.getVirtualRobotIOValue(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["VirtualRobotApi.getVirtualRobotIOValue"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async listIOs(r,a,n){var l,c;const o=await t.listIOs(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["VirtualRobotApi.listIOs"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async setMotionGroupState(r,a,n,o,s){var d,u;const i=await t.setMotionGroupState(r,a,n,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(u=(d=C["VirtualRobotApi.setMotionGroupState"])==null?void 0:d[l])==null?void 0:u.url;return(p,m)=>T(i,O,w,e)(p,c||m)},async setVirtualRobotIOValue(r,a,n,o,s,i,l){var p,m;const c=await t.setVirtualRobotIOValue(r,a,n,o,s,i,l),d=(e==null?void 0:e.serverIndex)??0,u=(m=(p=C["VirtualRobotApi.setVirtualRobotIOValue"])==null?void 0:p[d])==null?void 0:m.url;return(g,h)=>T(c,O,w,e)(g,u||h)}}};class Qv extends Pe{getMotionGroupState(t,r,a,n){return Lr(this.configuration).getMotionGroupState(t,r,a,n).then(o=>o(this.axios,this.basePath))}getMotionGroups(t,r,a){return Lr(this.configuration).getMotionGroups(t,r,a).then(n=>n(this.axios,this.basePath))}getVirtualRobotIOValue(t,r,a,n){return Lr(this.configuration).getVirtualRobotIOValue(t,r,a,n).then(o=>o(this.axios,this.basePath))}listIOs(t,r,a){return Lr(this.configuration).listIOs(t,r,a).then(n=>n(this.axios,this.basePath))}setMotionGroupState(t,r,a,n,o){return Lr(this.configuration).setMotionGroupState(t,r,a,n,o).then(s=>s(this.axios,this.basePath))}setVirtualRobotIOValue(t,r,a,n,o,s,i){return Lr(this.configuration).setVirtualRobotIOValue(t,r,a,n,o,s,i).then(l=>l(this.axios,this.basePath))}}const Yv=function(e){return{externalJointsStream:async(t,r,a,n={})=>{f("externalJointsStream","cell",t),f("externalJointsStream","controller",r),f("externalJointsStream","externalJointStreamDatapoint",a);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,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}},getMotionGroupBehavior:async(t,r,a,n={})=>{f("getMotionGroupBehavior","cell",t),f("getMotionGroupBehavior","controller",r),f("getMotionGroupBehavior","id",a);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(a))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},setMotionGroupBehavior:async(t,r,a,n,o={})=>{f("setMotionGroupBehavior","cell",t),f("setMotionGroupBehavior","controller",r),f("setMotionGroupBehavior","id",a);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(a))),i=new URL(s,P);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},d={},u={};V(c,e),await R(d,e),n!==void 0&&(u.behavior=n),_(i,u);let p=l&&l.headers?l.headers:{};return c.headers={...d,...p,...o.headers},{url:A(i),options:c}}}},To=function(e){const t=Yv(e);return{async externalJointsStream(r,a,n,o){var c,d;const s=await t.externalJointsStream(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["VirtualRobotBehaviorApi.externalJointsStream"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async getMotionGroupBehavior(r,a,n,o){var c,d;const s=await t.getMotionGroupBehavior(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["VirtualRobotBehaviorApi.getMotionGroupBehavior"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async setMotionGroupBehavior(r,a,n,o,s){var d,u;const i=await t.setMotionGroupBehavior(r,a,n,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(u=(d=C["VirtualRobotBehaviorApi.setMotionGroupBehavior"])==null?void 0:d[l])==null?void 0:u.url;return(p,m)=>T(i,O,w,e)(p,c||m)}}};class Xv extends Pe{externalJointsStream(t,r,a,n){return To(this.configuration).externalJointsStream(t,r,a,n).then(o=>o(this.axios,this.basePath))}getMotionGroupBehavior(t,r,a,n){return To(this.configuration).getMotionGroupBehavior(t,r,a,n).then(o=>o(this.axios,this.basePath))}setMotionGroupBehavior(t,r,a,n,o){return To(this.configuration).setMotionGroupBehavior(t,r,a,n,o).then(s=>s(this.axios,this.basePath))}}const Zv=function(e){return{getCycleTime:async(t,r,a={})=>{f("getCycleTime","cell",t),f("getCycleTime","controller",r);const n="/cells/{cell}/controllers/{controller}/teach-pendant/cycle-time".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getEStop:async(t,r,a={})=>{f("getEStop","cell",t),f("getEStop","controller",r);const n="/cells/{cell}/controllers/{controller}/teach-pendant/estop".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},getOperationMode:async(t,r,a={})=>{f("getOperationMode","cell",t),f("getOperationMode","controller",r);const n="/cells/{cell}/controllers/{controller}/teach-pendant/operationmode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},pushEStop:async(t,r,a={})=>{f("pushEStop","cell",t),f("pushEStop","controller",r);const n="/cells/{cell}/controllers/{controller}/teach-pendant/estop/push".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},releaseEStop:async(t,r,a={})=>{f("releaseEStop","cell",t),f("releaseEStop","controller",r);const n="/cells/{cell}/controllers/{controller}/teach-pendant/estop/release".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"PUT",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},setOperationMode:async(t,r,a,n={})=>{f("setOperationMode","cell",t),f("setOperationMode","controller",r),f("setOperationMode","mode",a);const o="/cells/{cell}/controllers/{controller}/teach-pendant/operationmode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),a!==void 0&&(d.mode=a),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}}}},kr=function(e){const t=Zv(e);return{async getCycleTime(r,a,n){var l,c;const o=await t.getCycleTime(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["VirtualRobotModeApi.getCycleTime"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getEStop(r,a,n){var l,c;const o=await t.getEStop(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["VirtualRobotModeApi.getEStop"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async getOperationMode(r,a,n){var l,c;const o=await t.getOperationMode(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["VirtualRobotModeApi.getOperationMode"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async pushEStop(r,a,n){var l,c;const o=await t.pushEStop(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["VirtualRobotModeApi.pushEStop"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async releaseEStop(r,a,n){var l,c;const o=await t.releaseEStop(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["VirtualRobotModeApi.releaseEStop"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async setOperationMode(r,a,n,o){var c,d;const s=await t.setOperationMode(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["VirtualRobotModeApi.setOperationMode"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)}}};class e1 extends Pe{getCycleTime(t,r,a){return kr(this.configuration).getCycleTime(t,r,a).then(n=>n(this.axios,this.basePath))}getEStop(t,r,a){return kr(this.configuration).getEStop(t,r,a).then(n=>n(this.axios,this.basePath))}getOperationMode(t,r,a){return kr(this.configuration).getOperationMode(t,r,a).then(n=>n(this.axios,this.basePath))}pushEStop(t,r,a){return kr(this.configuration).pushEStop(t,r,a).then(n=>n(this.axios,this.basePath))}releaseEStop(t,r,a){return kr(this.configuration).releaseEStop(t,r,a).then(n=>n(this.axios,this.basePath))}setOperationMode(t,r,a,n){return kr(this.configuration).setOperationMode(t,r,a,n).then(o=>o(this.axios,this.basePath))}}const t1=function(e){return{addVirtualRobotCoordinateSystem:async(t,r,a,n={})=>{f("addVirtualRobotCoordinateSystem","cell",t),f("addVirtualRobotCoordinateSystem","controller",r),f("addVirtualRobotCoordinateSystem","coordinateSystem",a);const o="/cells/{cell}/controllers/{controller}/teach-pendant/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};V(l,e),await R(c,e),c["Content-Type"]="application/json",_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},l.data=se(a,l,e),{url:A(s),options:l}},addVirtualRobotTcp:async(t,r,a,n,o={})=>{f("addVirtualRobotTcp","cell",t),f("addVirtualRobotTcp","controller",r),f("addVirtualRobotTcp","id",a),f("addVirtualRobotTcp","robotTcp",n);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(a))),i=new URL(s,P);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},d={},u={};V(c,e),await R(d,e),d["Content-Type"]="application/json",_(i,u);let p=l&&l.headers?l.headers:{};return c.headers={...d,...p,...o.headers},c.data=se(n,c,e),{url:A(i),options:c}},deleteVirtualRobotCoordinateSystem:async(t,r,a,n,o={})=>{f("deleteVirtualRobotCoordinateSystem","cell",t),f("deleteVirtualRobotCoordinateSystem","controller",r),f("deleteVirtualRobotCoordinateSystem","coordinateSystem",a);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(a))),i=new URL(s,P);let l;e&&(l=e.baseOptions);const c={method:"DELETE",...l,...o},d={},u={};V(c,e),await R(d,e),n!==void 0&&(u.delete_dependent=n),_(i,u);let p=l&&l.headers?l.headers:{};return c.headers={...d,...p,...o.headers},{url:A(i),options:c}},deleteVirtualRobotTcp:async(t,r,a,n,o={})=>{f("deleteVirtualRobotTcp","cell",t),f("deleteVirtualRobotTcp","controller",r),f("deleteVirtualRobotTcp","id",a),f("deleteVirtualRobotTcp","tcp",n);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(a))).replace("{tcp}",encodeURIComponent(String(n))),i=new URL(s,P);let l;e&&(l=e.baseOptions);const c={method:"DELETE",...l,...o},d={},u={};V(c,e),await R(d,e),_(i,u);let p=l&&l.headers?l.headers:{};return c.headers={...d,...p,...o.headers},{url:A(i),options:c}},getVirtualRobotMounting:async(t,r,a,n={})=>{f("getVirtualRobotMounting","cell",t),f("getVirtualRobotMounting","controller",r),f("getVirtualRobotMounting","id",a);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(a))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},listVirtualRobotCoordinateSystems:async(t,r,a={})=>{f("listVirtualRobotCoordinateSystems","cell",t),f("listVirtualRobotCoordinateSystems","controller",r);const n="/cells/{cell}/controllers/{controller}/teach-pendant/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(n,P);let s;e&&(s=e.baseOptions);const i={method:"GET",...s,...a},l={},c={};V(i,e),await R(l,e),_(o,c);let d=s&&s.headers?s.headers:{};return i.headers={...l,...d,...a.headers},{url:A(o),options:i}},listVirtualRobotTcps:async(t,r,a,n={})=>{f("listVirtualRobotTcps","cell",t),f("listVirtualRobotTcps","controller",r),f("listVirtualRobotTcps","id",a);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(a))),s=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};V(l,e),await R(c,e),_(s,d);let u=i&&i.headers?i.headers:{};return l.headers={...c,...u,...n.headers},{url:A(s),options:l}},setVirtualRobotMounting:async(t,r,a,n,o={})=>{f("setVirtualRobotMounting","cell",t),f("setVirtualRobotMounting","controller",r),f("setVirtualRobotMounting","id",a),f("setVirtualRobotMounting","coordinateSystem",n);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(a))),i=new URL(s,P);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...o},d={},u={};V(c,e),await R(d,e),d["Content-Type"]="application/json",_(i,u);let p=l&&l.headers?l.headers:{};return c.headers={...d,...p,...o.headers},c.data=se(n,c,e),{url:A(i),options:c}}}},Ht=function(e){const t=t1(e);return{async addVirtualRobotCoordinateSystem(r,a,n,o){var c,d;const s=await t.addVirtualRobotCoordinateSystem(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["VirtualRobotSetupApi.addVirtualRobotCoordinateSystem"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async addVirtualRobotTcp(r,a,n,o,s){var d,u;const i=await t.addVirtualRobotTcp(r,a,n,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(u=(d=C["VirtualRobotSetupApi.addVirtualRobotTcp"])==null?void 0:d[l])==null?void 0:u.url;return(p,m)=>T(i,O,w,e)(p,c||m)},async deleteVirtualRobotCoordinateSystem(r,a,n,o,s){var d,u;const i=await t.deleteVirtualRobotCoordinateSystem(r,a,n,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(u=(d=C["VirtualRobotSetupApi.deleteVirtualRobotCoordinateSystem"])==null?void 0:d[l])==null?void 0:u.url;return(p,m)=>T(i,O,w,e)(p,c||m)},async deleteVirtualRobotTcp(r,a,n,o,s){var d,u;const i=await t.deleteVirtualRobotTcp(r,a,n,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(u=(d=C["VirtualRobotSetupApi.deleteVirtualRobotTcp"])==null?void 0:d[l])==null?void 0:u.url;return(p,m)=>T(i,O,w,e)(p,c||m)},async getVirtualRobotMounting(r,a,n,o){var c,d;const s=await t.getVirtualRobotMounting(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["VirtualRobotSetupApi.getVirtualRobotMounting"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async listVirtualRobotCoordinateSystems(r,a,n){var l,c;const o=await t.listVirtualRobotCoordinateSystems(r,a,n),s=(e==null?void 0:e.serverIndex)??0,i=(c=(l=C["VirtualRobotSetupApi.listVirtualRobotCoordinateSystems"])==null?void 0:l[s])==null?void 0:c.url;return(d,u)=>T(o,O,w,e)(d,i||u)},async listVirtualRobotTcps(r,a,n,o){var c,d;const s=await t.listVirtualRobotTcps(r,a,n,o),i=(e==null?void 0:e.serverIndex)??0,l=(d=(c=C["VirtualRobotSetupApi.listVirtualRobotTcps"])==null?void 0:c[i])==null?void 0:d.url;return(u,p)=>T(s,O,w,e)(u,l||p)},async setVirtualRobotMounting(r,a,n,o,s){var d,u;const i=await t.setVirtualRobotMounting(r,a,n,o,s),l=(e==null?void 0:e.serverIndex)??0,c=(u=(d=C["VirtualRobotSetupApi.setVirtualRobotMounting"])==null?void 0:d[l])==null?void 0:u.url;return(p,m)=>T(i,O,w,e)(p,c||m)}}};class r1 extends Pe{addVirtualRobotCoordinateSystem(t,r,a,n){return Ht(this.configuration).addVirtualRobotCoordinateSystem(t,r,a,n).then(o=>o(this.axios,this.basePath))}addVirtualRobotTcp(t,r,a,n,o){return Ht(this.configuration).addVirtualRobotTcp(t,r,a,n,o).then(s=>s(this.axios,this.basePath))}deleteVirtualRobotCoordinateSystem(t,r,a,n,o){return Ht(this.configuration).deleteVirtualRobotCoordinateSystem(t,r,a,n,o).then(s=>s(this.axios,this.basePath))}deleteVirtualRobotTcp(t,r,a,n,o){return Ht(this.configuration).deleteVirtualRobotTcp(t,r,a,n,o).then(s=>s(this.axios,this.basePath))}getVirtualRobotMounting(t,r,a,n){return Ht(this.configuration).getVirtualRobotMounting(t,r,a,n).then(o=>o(this.axios,this.basePath))}listVirtualRobotCoordinateSystems(t,r,a){return Ht(this.configuration).listVirtualRobotCoordinateSystems(t,r,a).then(n=>n(this.axios,this.basePath))}listVirtualRobotTcps(t,r,a,n){return Ht(this.configuration).listVirtualRobotTcps(t,r,a,n).then(o=>o(this.axios,this.basePath))}setVirtualRobotMounting(t,r,a,n,o){return Ht(this.configuration).setVirtualRobotMounting(t,r,a,n,o).then(s=>s(this.axios,this.basePath))}}function Mt(e,t,r){return Math.max(t,Math.min(r,e))}class a1{constructor(t=0,r=0,a=0,n=1){this.isQuaternion=!0,this._x=t,this._y=r,this._z=a,this._w=n}static slerpFlat(t,r,a,n,o,s,i){let l=a[n+0],c=a[n+1],d=a[n+2],u=a[n+3];const p=o[s+0],m=o[s+1],g=o[s+2],h=o[s+3];if(i===0){t[r+0]=l,t[r+1]=c,t[r+2]=d,t[r+3]=u;return}if(i===1){t[r+0]=p,t[r+1]=m,t[r+2]=g,t[r+3]=h;return}if(u!==h||l!==p||c!==m||d!==g){let x=1-i;const E=l*p+c*m+d*g+u*h,U=E>=0?1:-1,F=1-E*E;if(F>Number.EPSILON){const J=Math.sqrt(F),K=Math.atan2(J,E*U);x=Math.sin(x*K)/J,i=Math.sin(i*K)/J}const N=i*U;if(l=l*x+p*N,c=c*x+m*N,d=d*x+g*N,u=u*x+h*N,x===1-i){const J=1/Math.sqrt(l*l+c*c+d*d+u*u);l*=J,c*=J,d*=J,u*=J}}t[r]=l,t[r+1]=c,t[r+2]=d,t[r+3]=u}static multiplyQuaternionsFlat(t,r,a,n,o,s){const i=a[n],l=a[n+1],c=a[n+2],d=a[n+3],u=o[s],p=o[s+1],m=o[s+2],g=o[s+3];return t[r]=i*g+d*u+l*m-c*p,t[r+1]=l*g+d*p+c*u-i*m,t[r+2]=c*g+d*m+i*p-l*u,t[r+3]=d*g-i*u-l*p-c*m,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,a,n){return this._x=t,this._y=r,this._z=a,this._w=n,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 a=t._x,n=t._y,o=t._z,s=t._order,i=Math.cos,l=Math.sin,c=i(a/2),d=i(n/2),u=i(o/2),p=l(a/2),m=l(n/2),g=l(o/2);switch(s){case"XYZ":this._x=p*d*u+c*m*g,this._y=c*m*u-p*d*g,this._z=c*d*g+p*m*u,this._w=c*d*u-p*m*g;break;case"YXZ":this._x=p*d*u+c*m*g,this._y=c*m*u-p*d*g,this._z=c*d*g-p*m*u,this._w=c*d*u+p*m*g;break;case"ZXY":this._x=p*d*u-c*m*g,this._y=c*m*u+p*d*g,this._z=c*d*g+p*m*u,this._w=c*d*u-p*m*g;break;case"ZYX":this._x=p*d*u-c*m*g,this._y=c*m*u+p*d*g,this._z=c*d*g-p*m*u,this._w=c*d*u+p*m*g;break;case"YZX":this._x=p*d*u+c*m*g,this._y=c*m*u+p*d*g,this._z=c*d*g-p*m*u,this._w=c*d*u-p*m*g;break;case"XZY":this._x=p*d*u-c*m*g,this._y=c*m*u-p*d*g,this._z=c*d*g+p*m*u,this._w=c*d*u+p*m*g;break;default:console.warn("THREE.Quaternion: .setFromEuler() encountered an unknown order: "+s)}return r===!0&&this._onChangeCallback(),this}setFromAxisAngle(t,r){const a=r/2,n=Math.sin(a);return this._x=t.x*n,this._y=t.y*n,this._z=t.z*n,this._w=Math.cos(a),this._onChangeCallback(),this}setFromRotationMatrix(t){const r=t.elements,a=r[0],n=r[4],o=r[8],s=r[1],i=r[5],l=r[9],c=r[2],d=r[6],u=r[10],p=a+i+u;if(p>0){const m=.5/Math.sqrt(p+1);this._w=.25/m,this._x=(d-l)*m,this._y=(o-c)*m,this._z=(s-n)*m}else if(a>i&&a>u){const m=2*Math.sqrt(1+a-i-u);this._w=(d-l)/m,this._x=.25*m,this._y=(n+s)/m,this._z=(o+c)/m}else if(i>u){const m=2*Math.sqrt(1+i-a-u);this._w=(o-c)/m,this._x=(n+s)/m,this._y=.25*m,this._z=(l+d)/m}else{const m=2*Math.sqrt(1+u-a-i);this._w=(s-n)/m,this._x=(o+c)/m,this._y=(l+d)/m,this._z=.25*m}return this._onChangeCallback(),this}setFromUnitVectors(t,r){let a=t.dot(r)+1;return a<Number.EPSILON?(a=0,Math.abs(t.x)>Math.abs(t.z)?(this._x=-t.y,this._y=t.x,this._z=0,this._w=a):(this._x=0,this._y=-t.z,this._z=t.y,this._w=a)):(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=a),this.normalize()}angleTo(t){return 2*Math.acos(Math.abs(Mt(this.dot(t),-1,1)))}rotateTowards(t,r){const a=this.angleTo(t);if(a===0)return this;const n=Math.min(1,r/a);return this.slerp(t,n),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 a=t._x,n=t._y,o=t._z,s=t._w,i=r._x,l=r._y,c=r._z,d=r._w;return this._x=a*d+s*i+n*c-o*l,this._y=n*d+s*l+o*i-a*c,this._z=o*d+s*c+a*l-n*i,this._w=s*d-a*i-n*l-o*c,this._onChangeCallback(),this}slerp(t,r){if(r===0)return this;if(r===1)return this.copy(t);const a=this._x,n=this._y,o=this._z,s=this._w;let i=s*t._w+a*t._x+n*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=a,this._y=n,this._z=o,this;const l=1-i*i;if(l<=Number.EPSILON){const m=1-r;return this._w=m*s+r*this._w,this._x=m*a+r*this._x,this._y=m*n+r*this._y,this._z=m*o+r*this._z,this.normalize(),this}const c=Math.sqrt(l),d=Math.atan2(c,i),u=Math.sin((1-r)*d)/c,p=Math.sin(r*d)/c;return this._w=s*u+this._w*p,this._x=a*u+this._x*p,this._y=n*u+this._y*p,this._z=o*u+this._z*p,this._onChangeCallback(),this}slerpQuaternions(t,r,a){return this.copy(t).slerp(r,a)}random(){const t=2*Math.PI*Math.random(),r=2*Math.PI*Math.random(),a=Math.random(),n=Math.sqrt(1-a),o=Math.sqrt(a);return this.set(n*Math.sin(t),n*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 Jr{constructor(t=0,r=0,a=0){Jr.prototype.isVector3=!0,this.x=t,this.y=r,this.z=a}set(t,r,a){return a===void 0&&(a=this.z),this.x=t,this.y=r,this.z=a,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(ol.setFromEuler(t))}applyAxisAngle(t,r){return this.applyQuaternion(ol.setFromAxisAngle(t,r))}applyMatrix3(t){const r=this.x,a=this.y,n=this.z,o=t.elements;return this.x=o[0]*r+o[3]*a+o[6]*n,this.y=o[1]*r+o[4]*a+o[7]*n,this.z=o[2]*r+o[5]*a+o[8]*n,this}applyNormalMatrix(t){return this.applyMatrix3(t).normalize()}applyMatrix4(t){const r=this.x,a=this.y,n=this.z,o=t.elements,s=1/(o[3]*r+o[7]*a+o[11]*n+o[15]);return this.x=(o[0]*r+o[4]*a+o[8]*n+o[12])*s,this.y=(o[1]*r+o[5]*a+o[9]*n+o[13])*s,this.z=(o[2]*r+o[6]*a+o[10]*n+o[14])*s,this}applyQuaternion(t){const r=this.x,a=this.y,n=this.z,o=t.x,s=t.y,i=t.z,l=t.w,c=2*(s*n-i*a),d=2*(i*r-o*n),u=2*(o*a-s*r);return this.x=r+l*c+s*u-i*d,this.y=a+l*d+i*c-o*u,this.z=n+l*u+o*d-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,a=this.y,n=this.z,o=t.elements;return this.x=o[0]*r+o[4]*a+o[8]*n,this.y=o[1]*r+o[5]*a+o[9]*n,this.z=o[2]*r+o[6]*a+o[10]*n,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=Mt(this.x,t.x,r.x),this.y=Mt(this.y,t.y,r.y),this.z=Mt(this.z,t.z,r.z),this}clampScalar(t,r){return this.x=Mt(this.x,t,r),this.y=Mt(this.y,t,r),this.z=Mt(this.z,t,r),this}clampLength(t,r){const a=this.length();return this.divideScalar(a||1).multiplyScalar(Mt(a,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,a){return this.x=t.x+(r.x-t.x)*a,this.y=t.y+(r.y-t.y)*a,this.z=t.z+(r.z-t.z)*a,this}cross(t){return this.crossVectors(this,t)}crossVectors(t,r){const a=t.x,n=t.y,o=t.z,s=r.x,i=r.y,l=r.z;return this.x=n*l-o*i,this.y=o*s-a*l,this.z=a*i-n*s,this}projectOnVector(t){const r=t.lengthSq();if(r===0)return this.set(0,0,0);const a=t.dot(this)/r;return this.copy(t).multiplyScalar(a)}projectOnPlane(t){return Eo.copy(this).projectOnVector(t),this.sub(Eo)}reflect(t){return this.sub(Eo.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 a=this.dot(t)/r;return Math.acos(Mt(a,-1,1))}distanceTo(t){return Math.sqrt(this.distanceToSquared(t))}distanceToSquared(t){const r=this.x-t.x,a=this.y-t.y,n=this.z-t.z;return r*r+a*a+n*n}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,a){const n=Math.sin(r)*t;return this.x=n*Math.sin(a),this.y=Math.cos(r)*t,this.z=n*Math.cos(a),this}setFromCylindrical(t){return this.setFromCylindricalCoords(t.radius,t.theta,t.y)}setFromCylindricalCoords(t,r,a){return this.x=t*Math.sin(r),this.y=a,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(),a=this.setFromMatrixColumn(t,1).length(),n=this.setFromMatrixColumn(t,2).length();return this.x=r,this.y=a,this.z=n,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,a=Math.sqrt(1-r*r);return this.x=a*Math.cos(t),this.y=r,this.z=a*Math.sin(t),this}*[Symbol.iterator](){yield this.x,yield this.y,yield this.z}}const Eo=new Jr,ol=new a1;function n1(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 a=0;a<e.length;a++){var n=e[a];if(typeof n!="string")throw new TypeError("Url must be a string. Received "+n);n!==""&&(a>0&&(n=n.replace(/^[\/]+/,"")),a<e.length-1?n=n.replace(/[\/]+$/,""):n=n.replace(/[\/]+$/,"/"),t.push(n))}var o=t.join("/");o=o.replace(/\/(\?|&|#[^!])/g,"$1");var s=o.split("?");return o=s.shift()+(s.length>0?"?":"")+s.join("&"),o}function Io(){var e;return typeof arguments[0]=="object"?e=arguments[0]:e=[].slice.call(arguments),n1(e)}var xt={},sl;function o1(){if(sl)return xt;sl=1,Object.defineProperty(xt,"__esModule",{value:!0}),xt.TokenData=void 0,xt.parse=u,xt.compile=p,xt.match=h,xt.pathToRegexp=x,xt.stringify=N;const e="/",t=j=>j,r=/^[$_\p{ID_Start}]$/u,a=/^[$\u200c\u200d\p{ID_Continue}]$/u,n="https://git.new/pathToRegexpError",o={"{":"{","}":"}","(":"(",")":")","[":"[","]":"]","+":"+","?":"?","!":"!"};function s(j){return j.replace(/[{}()\[\]+?!:*]/g,"\\$&")}function i(j){return j.replace(/[.+*?^${}()[\]|/\\]/g,"\\$&")}function*l(j){const L=[...j];let k=0;function y(){let M="";if(r.test(L[++k]))for(M+=L[k];a.test(L[++k]);)M+=L[k];else if(L[k]==='"'){let B=k;for(;k<L.length;){if(L[++k]==='"'){k++,B=0;break}L[k]==="\\"?M+=L[++k]:M+=L[k]}if(B)throw new TypeError(`Unterminated quote at ${B}: ${n}`)}if(!M)throw new TypeError(`Missing parameter name at ${k}: ${n}`);return M}for(;k<L.length;){const M=L[k],B=o[M];if(B)yield{type:B,index:k++,value:M};else if(M==="\\")yield{type:"ESCAPED",index:k++,value:L[k++]};else if(M===":"){const G=y();yield{type:"PARAM",index:k,value:G}}else if(M==="*"){const G=y();yield{type:"WILDCARD",index:k,value:G}}else yield{type:"CHAR",index:k,value:L[k++]}}return{type:"END",index:k,value:""}}class c{constructor(L){this.tokens=L}peek(){if(!this._peek){const L=this.tokens.next();this._peek=L.value}return this._peek}tryConsume(L){const k=this.peek();if(k.type===L)return this._peek=void 0,k.value}consume(L){const k=this.tryConsume(L);if(k!==void 0)return k;const{type:y,index:M}=this.peek();throw new TypeError(`Unexpected ${y} at ${M}, expected ${L}: ${n}`)}text(){let L="",k;for(;k=this.tryConsume("CHAR")||this.tryConsume("ESCAPED");)L+=k;return L}}class d{constructor(L){this.tokens=L}}xt.TokenData=d;function u(j,L={}){const{encodePath:k=t}=L,y=new c(l(j));function M(G){const D=[];for(;;){const re=y.text();re&&D.push({type:"text",value:k(re)});const Z=y.tryConsume("PARAM");if(Z){D.push({type:"param",name:Z});continue}const xe=y.tryConsume("WILDCARD");if(xe){D.push({type:"wildcard",name:xe});continue}if(y.tryConsume("{")){D.push({type:"group",tokens:M("}")});continue}return y.consume(G),D}}const B=M("END");return new d(B)}function p(j,L={}){const{encode:k=encodeURIComponent,delimiter:y=e}=L,M=j instanceof d?j:u(j,L),B=m(M.tokens,y,k);return function(D={}){const[re,...Z]=B(D);if(Z.length)throw new TypeError(`Missing parameters: ${Z.join(", ")}`);return re}}function m(j,L,k){const y=j.map(M=>g(M,L,k));return M=>{const B=[""];for(const G of y){const[D,...re]=G(M);B[0]+=D,B.push(...re)}return B}}function g(j,L,k){if(j.type==="text")return()=>[j.value];if(j.type==="group"){const M=m(j.tokens,L,k);return B=>{const[G,...D]=M(B);return D.length?[""]:[G]}}const y=k||t;return j.type==="wildcard"&&k!==!1?M=>{const B=M[j.name];if(B==null)return["",j.name];if(!Array.isArray(B)||B.length===0)throw new TypeError(`Expected "${j.name}" to be a non-empty array`);return[B.map((G,D)=>{if(typeof G!="string")throw new TypeError(`Expected "${j.name}/${D}" to be a string`);return y(G)}).join(L)]}:M=>{const B=M[j.name];if(B==null)return["",j.name];if(typeof B!="string")throw new TypeError(`Expected "${j.name}" to be a string`);return[y(B)]}}function h(j,L={}){const{decode:k=decodeURIComponent,delimiter:y=e}=L,{regexp:M,keys:B}=x(j,L),G=B.map(D=>k===!1?t:D.type==="param"?k:re=>re.split(y).map(k));return function(re){const Z=M.exec(re);if(!Z)return!1;const xe=Z[0],X=Object.create(null);for(let ce=1;ce<Z.length;ce++){if(Z[ce]===void 0)continue;const fe=B[ce-1],le=G[ce-1];X[fe.name]=le(Z[ce])}return{path:xe,params:X}}}function x(j,L={}){const{delimiter:k=e,end:y=!0,sensitive:M=!1,trailing:B=!0}=L,G=[],D=[],re=M?"":"i",xe=(Array.isArray(j)?j:[j]).map(fe=>fe instanceof d?fe:u(fe,L));for(const{tokens:fe}of xe)for(const le of E(fe,0,[])){const He=U(le,k,G);D.push(He)}let X=`^(?:${D.join("|")})`;return B&&(X+=`(?:${i(k)}$)?`),X+=y?"$":`(?=${i(k)}|$)`,{regexp:new RegExp(X,re),keys:G}}function*E(j,L,k){if(L===j.length)return yield k;const y=j[L];if(y.type==="group"){const M=k.slice();for(const B of E(y.tokens,0,M))yield*E(j,L+1,B)}else k.push(y);yield*E(j,L+1,k)}function U(j,L,k){let y="",M="",B=!0;for(let G=0;G<j.length;G++){const D=j[G];if(D.type==="text"){y+=i(D.value),M+=D.value,B||(B=D.value.includes(L));continue}if(D.type==="param"||D.type==="wildcard"){if(!B&&!M)throw new TypeError(`Missing text after "${D.name}": ${n}`);D.type==="param"?y+=`(${F(L,B?"":M)}+)`:y+="([\\s\\S]+)",k.push(D),M="",B=!1;continue}}return y}function F(j,L){return L.length<2?j.length<2?`[^${i(j+L)}]`:`(?:(?!${i(j)})[^${i(L)}])`:j.length<2?`(?:(?!${i(L)})[^${i(j)}])`:`(?:(?!${i(L)}|${i(j)})[\\s\\S])`}function N(j){return j.tokens.map(function L(k,y,M){if(k.type==="text")return s(k.value);if(k.type==="group")return`{${k.tokens.map(L).join("")}}`;const G=J(k.name)&&K(M[y+1])?k.name:JSON.stringify(k.name);if(k.type==="param")return`:${G}`;if(k.type==="wildcard")return`*${G}`;throw new TypeError(`Unexpected token: ${k}`)}).join("")}function J(j){const[L,...k]=j;return r.test(L)?k.every(y=>a.test(y)):!1}function K(j){return(j==null?void 0:j.type)!=="text"?!0:!a.test(j.value[0])}return xt}var s1=o1();function Xc(e,t,r){if(t.length!==e.length)return!0;for(let a=0;a<t.length;a++)if(Math.abs(t[a]-e[a])>r)return!1;return!0}function Zc(e,t,r){if(e===void 0&&t||e&&t===void 0)return!1;if(e===void 0||t===void 0)return!0;let a=0;return a+=Math.abs(e.orientation.x-t.orientation.x),a+=Math.abs(e.orientation.y-t.orientation.y),a+=Math.abs(e.orientation.z-t.orientation.z),a+=Math.abs(e.position.x-t.position.x),a+=Math.abs(e.position.y-t.position.y),a+=Math.abs(e.position.z-t.position.z),a>r?!1:e.coordinate_system===t.coordinate_system&&e.tcp===t.tcp}var il=1e-4,i1=class ed{constructor(t,r,a,n,o,s,i,l,c,d,u,p){this.nova=t,this.controller=r,this.motionGroup=a,this.initialMotionState=n,this.motionStateSocket=o,this.isVirtual=s,this.tcps=i,this.motionGroupSpecification=l,this.safetySetup=c,this.mounting=d,this.initialControllerState=u,this.controllerStateSocket=p,this.connectedJoggingCartesianSocket=null,this.connectedJoggingJointsSocket=null,this.joggingVelocity=10,this.activationState="inactive",this.rapidlyChangingMotionState=n,this.controllerState=u,p.addEventListener("message",m=>{var g;const h=(g=Kt(m.data))==null?void 0:g.result;h&&Be.runInAction(()=>{this.controllerState=h})}),o.addEventListener("message",m=>{var g;const h=(g=Kt(m.data))==null?void 0:g.result;if(!h)throw new Error(`Failed to get motion state for ${this.motionGroupId}: ${m.data}`);Xc(this.rapidlyChangingMotionState.state.joint_position.joints,h.state.joint_position.joints,il)||Be.runInAction(()=>{this.rapidlyChangingMotionState.state=h.state}),Zc(this.rapidlyChangingMotionState.tcp_pose,h.tcp_pose,il)||Be.runInAction(()=>{this.rapidlyChangingMotionState.tcp_pose=h.tcp_pose})}),Be.makeAutoObservable(this)}static connect(t,r,a){return Ce(this,null,function*(){var n,o;const[s,i]=r.split("@"),l=a.find(K=>K.controller===i),c=l==null?void 0:l.physical_motion_groups.find(K=>K.motion_group===r);if(!l||!c)throw new Error(`Controller ${i} or motion group ${r} not found`);const d=t.openReconnectingWebsocket(`/motion-groups/${r}/state-stream`),u=yield d.firstMessage(),p=(n=Kt(u.data))==null?void 0:n.result;if(!p)throw new Error(`Unable to parse initial motion state message ${u.data}`);console.log(`Connected motion state websocket to motion group ${c.motion_group}. Initial state:
|
|
112
|
-
`,
|
|
113
|
-
`,U);const{tcps:F}=yield t.api.motionGroupInfos.listTcps(r),N=yield t.api.motionGroupInfos.getMotionGroupSpecification(r),J=yield t.api.motionGroupInfos.getSafetySetup(r);return new ed(t,l,c,p,d,g,F,N,J,h,U,x)})}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,a,n,o,s;const i=new Me.Vector3(((r=(t=this.mounting)==null?void 0:t.pose.orientation)==null?void 0:r.x)||0,((n=(a=this.mounting)==null?void 0:a.pose.orientation)==null?void 0:n.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 Me.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 Ce(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 Ce(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}},l1=class td{constructor(t,r={}){this.motionStream=t,this.opts=r,this.cartesianWebsocket=null,this.jointWebsocket=null,this.cartesianJoggingOpts={}}static open(t,r){return Ce(this,arguments,function*(a,n,o={}){const s=yield a.connectMotionStream(n);return new td(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 Ce(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&&(p0(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",a=>{const n=Kt(a.data);if(n&&"error"in n)if(this.opts.onError)this.opts.onError(a.data);else throw new Error(a.data)})),t==="joint"&&!this.jointWebsocket&&(this.jointWebsocket=this.nova.openReconnectingWebsocket("/motion-groups/move-joint"),this.jointWebsocket.addEventListener("message",a=>{const n=Kt(a.data);if(n&&"error"in n)if(this.opts.onError)this.opts.onError(a.data);else throw new Error(a.data)}))}startJointRotation(t){return Ce(this,arguments,function*({joint:r,direction:a,velocityRadsPerSec:n}){if(!this.jointWebsocket)throw new Error("Joint jogging websocket not connected; call setJoggingMode first");const o=new Array(this.numJoints).fill(0);o[r]=a==="-"?-n:n,this.jointWebsocket.sendJson({motion_group:this.motionGroupId,joint_velocities:o})})}startTCPTranslation(t){return Ce(this,arguments,function*({axis:r,direction:a,velocityMmPerSec:n}){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]=a==="-"?-1:1,this.cartesianWebsocket.sendJson({motion_group:this.motionGroupId,position_direction:s,rotation_direction:o,position_velocity:n,rotation_velocity:0,tcp:this.cartesianJoggingOpts.tcpId,coordinate_system:this.cartesianJoggingOpts.coordSystemId})})}startTCPRotation(t){return Ce(this,arguments,function*({axis:r,direction:a,velocityRadsPerSec:n}){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]=a==="-"?-1:1,this.cartesianWebsocket.sendJson({motion_group:this.motionGroupId,position_direction:o,rotation_direction:s,position_velocity:0,rotation_velocity:n,tcp:this.cartesianJoggingOpts.tcpId,coordinate_system:this.cartesianJoggingOpts.coordSystemId})})}runIncrementalCartesianMotion(t){return Ce(this,arguments,function*({currentTcpPose:r,currentJoints:a,coordSystemId:n,velocityInRelevantUnits:o,axis:s,direction:i,motion:l}){var c;const d=[];if(!_0(r.coordinate_system,n))throw new Error(`Current TCP pose coordinate system ${r.coordinate_system} does not match target coordinate system ${n}`);if(l.type==="translate"){const m=Object.assign({},r.position);m[s]+=l.distanceMm*(i==="-"?-1:1),d.push({settings:{limits_override:{tcp_velocity_limit:o}},line:{position:m,orientation:r.orientation,coordinate_system:n}})}else if(l.type==="rotate"){const m=new Jr(r.orientation.x,r.orientation.y,r.orientation.z),g=m.length(),h=m.clone().normalize(),x=l.distanceRads*(i==="-"?-1:1),E=new Jr(0,0,0);E[s]=1;const U=Math.cos(.5*x)*Math.cos(.5*g),F=Math.sin(.5*x)*Math.sin(.5*g),N=Math.sin(.5*x)*Math.cos(.5*g),J=Math.cos(.5*x)*Math.sin(.5*g),K=E.dot(h),j=E.clone().cross(h),L=2*Math.acos(U-F*K),k=L/Math.sin(.5*L),y=new Jr().addScaledVector(j,F).addScaledVector(E,N).addScaledVector(h,J).multiplyScalar(k);d.push({settings:{limits_override:{tcp_orientation_velocity_limit:o}},line:{position:r.position,orientation:y,coordinate_system:n}})}const u=yield this.nova.api.motion.planMotion({motion_group:this.motionGroupId,start_joint_position:a,tcp:this.cartesianJoggingOpts.tcpId,commands:d}),p=(c=u.plan_successful_response)==null?void 0:c.motion;if(!p)throw new Error(`Failed to plan jogging increment motion ${JSON.stringify(u)}`);yield this.nova.api.motion.streamMoveForward(p,100,void 0,void 0,void 0,{timeout:1e3*60})})}runIncrementalJointRotation(t){return Ce(this,arguments,function*({joint:r,currentJoints:a,velocityRadsPerSec:n,direction:o,distanceRads:s}){var i;const l=[...a.joints];l[r]+=s*(o==="-"?-1:1);const c=new Array(a.joints.length).fill(n),d=yield this.nova.api.motion.planMotion({motion_group:this.motionGroupId,start_joint_position:a,commands:[{settings:{limits_override:{joint_velocity_limits:{joints:c}}},joint_ptp:{joints:l}}]}),u=(i=d.plan_successful_response)==null?void 0:i.motion;if(!u){console.error("Failed to plan jogging increment motion",d);return}yield this.nova.api.motion.streamMoveForward(u,100,void 0,void 0,void 0,{timeout:1e3*60})})}},ll=1e-4;function c1(e,t){const r=new ht.Vector3(t.x,t.y,t.z),a=new ht.Vector3(e.x,e.y,e.z),n=r.length(),o=r.normalize();let s=a.length(),i=a.normalize();i.dot(o)<0&&(s=-s,i=i.multiplyScalar(-1));let l=s-n;return l-=2*Math.PI*Math.floor((l+Math.PI)/(2*Math.PI)),s=n+l,i.multiplyScalar(s)}var d1=class rd{constructor(t,r,a,n,o){this.nova=t,this.controller=r,this.motionGroup=a,this.initialMotionState=n,this.motionStateSocket=o,this.rapidlyChangingMotionState=n,o.addEventListener("message",s=>{var i;const l=(i=Kt(s.data))==null?void 0:i.result;if(!l)throw new Error(`Failed to get motion state for ${this.motionGroupId}: ${s.data}`);Xc(this.rapidlyChangingMotionState.state.joint_position.joints,l.state.joint_position.joints,ll)||Be.runInAction(()=>{this.rapidlyChangingMotionState.state=l.state}),Zc(this.rapidlyChangingMotionState.tcp_pose,l.tcp_pose,ll)||Be.runInAction(()=>{this.rapidlyChangingMotionState.tcp_pose==null?this.rapidlyChangingMotionState.tcp_pose=l.tcp_pose:this.rapidlyChangingMotionState.tcp_pose={position:l.tcp_pose.position,orientation:c1(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 Ce(this,null,function*(){var a;const{instances:n}=yield t.api.controller.listControllers(),[o,s]=r.split("@"),i=n.find(p=>p.controller===s),l=i==null?void 0:i.physical_motion_groups.find(p=>p.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`),d=yield c.firstMessage();console.log("got first message",d);const u=(a=Kt(d.data))==null?void 0:a.result;if(!u)throw new Error(`Unable to parse initial motion state message ${d.data}`);return console.log(`Connected motion state websocket to motion group ${l.motion_group}. Initial state:
|
|
114
|
-
`,u),new rd(t,i,l,u,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()}},u1=class{constructor(e,t){this.cellId=e,this.opts=t,this.system=this.withUnwrappedResponsesOnly(Wv),this.cell=this.withUnwrappedResponsesOnly(dv),this.deviceConfig=this.withCellId(bv),this.motionGroup=this.withCellId(Tv),this.motionGroupInfos=this.withCellId(Iv),this.controller=this.withCellId(pv),this.program=this.withCellId(kv),this.programValues=this.withCellId(Fv),this.controllerIOs=this.withCellId(mv),this.motionGroupKinematic=this.withCellId(Uv),this.motion=this.withCellId(_v),this.coordinateSystems=this.withCellId(gv),this.application=this.withCellId(nl),this.applicationGlobal=this.withUnwrappedResponsesOnly(nl),this.motionGroupJogging=this.withCellId(jv),this.virtualRobot=this.withCellId(Qv),this.virtualRobotSetup=this.withCellId(r1),this.virtualRobotMode=this.withCellId(e1),this.virtualRobotBehavior=this.withCellId(Xv),this.libraryProgramMetadata=this.withCellId(Ov),this.libraryProgram=this.withCellId(vv),this.libraryRecipeMetadata=this.withCellId(Vv),this.libraryRecipe=this.withCellId(Cv),this.storeObject=this.withCellId(Hv),this.storeCollisionComponents=this.withCellId(Dv),this.storeCollisionScenes=this.withCellId(Gv)}withCellId(e){var t,r;const a=new e(Ko(Nr({},this.opts),{isJsonMime:n=>n==="application/json"}),(t=this.opts.basePath)!=null?t:"",(r=this.opts.axiosInstance)!=null?r:O.create());for(const n of Reflect.ownKeys(Reflect.getPrototypeOf(a)))if(n!=="constructor"&&typeof a[n]=="function"){const o=a[n];a[n]=(...s)=>o.apply(a,[this.cellId,...s]).then(i=>i.data)}return a}withUnwrappedResponsesOnly(e){var t,r;const a=new e(Ko(Nr({},this.opts),{isJsonMime:n=>n==="application/json"}),(t=this.opts.basePath)!=null?t:"",(r=this.opts.axiosInstance)!=null?r:O.create());for(const n of Reflect.ownKeys(Reflect.getPrototypeOf(a)))if(n!=="constructor"&&typeof a[n]=="function"){const o=a[n];a[n]=(...s)=>o.apply(a,s).then(i=>i.data)}return a}},p1=class{constructor(){this.connections=[]}handleAPIRequest(e){return Ce(this,null,function*(){var t,r,a;const n=[{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"+((a=(r=e.url)==null?void 0:r.split("/cells")[1])==null?void 0:a.split("?")[0]);for(const i of n){const l=s1.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 rs(`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(h1)})),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)}},h1={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]}},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"}}},m1=class{constructor(e){this.authPromise=null,this.accessToken=null;var t;const r=(t=e.cellId)!=null?t:"cell";this.config=Nr({cellId:r},e),this.accessToken=e.accessToken||Po.getString("wbjs.access_token")||null,this.config.instanceUrl==="https://mock.example.com"&&(this.mock=new p1);const a=O.create({baseURL:Io(this.config.instanceUrl,"/api/v1")});a.interceptors.request.use(n=>Ce(this,null,function*(){return n.headers.Authorization||(this.accessToken?n.headers.Authorization=`Bearer ${this.accessToken}`:this.config.username&&this.config.password&&(n.headers.Authorization=`Basic ${btoa(e.username+":"+e.password)}`)),n})),typeof window<"u"&&a.interceptors.response.use(n=>n,n=>Ce(this,null,function*(){var o,s;if(sv(n))if(((o=n.response)==null?void 0:o.status)===401)try{if(yield this.renewAuthentication(),n.config)return this.accessToken?n.config.headers.Authorization=`Bearer ${this.accessToken}`:delete n.config.headers.Authorization,a.request(n.config)}catch(i){return Promise.reject(i)}else((s=n.response)==null?void 0:s.status)===503&&(yield fetch(window.location.href)).status===503&&window.location.reload();return Promise.reject(n)})),this.api=new u1(r,Ko(Nr({},e),{basePath:Io(this.config.instanceUrl,"/api/v1"),isJsonMime:n=>n==="application/json",baseOptions:Nr(Nr({},this.mock?{adapter:n=>this.mock.handleAPIRequest(n)}:{}),e.baseOptions),axiosInstance:a}))}renewAuthentication(){return Ce(this,null,function*(){if(!this.authPromise){this.authPromise=T0(this.config.instanceUrl);try{this.accessToken=yield this.authPromise,this.accessToken?Po.setString("wbjs.access_token",this.accessToken):Po.delete("wbjs.access_token")}finally{this.authPromise=null}}})}makeWebsocketURL(e){const t=new URL(Io(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 V0(this.makeWebsocketURL(e),{mock:this.mock})}connectMotionStream(e){return Ce(this,null,function*(){return yield d1.open(this,e)})}connectJogger(e){return Ce(this,null,function*(){return yield l1.open(this,e)})}connectMotionGroups(e){return Ce(this,null,function*(){const{instances:t}=yield this.api.controller.listControllers();return Promise.all(e.map(r=>i1.connect(this,r,t)))})}connectMotionGroup(e){return Ce(this,null,function*(){return(yield this.connectMotionGroups([e]))[0]})}};function f1(e){try{return JSON.stringify(e)}catch{return}}function g1(e,t){throw new Error(t+` ${JSON.stringify(e)}`)}function y1(e){var t,r,a,n;return e instanceof rs&&e.code==="ERR_NETWORK"?"Failed to connect to the server. Please check your internet connection.":e instanceof rs&&e.response?`${(t=e.response)==null?void 0:t.status} ${(r=e.response)==null?void 0:r.statusText} from ${(a=e.response)==null?void 0:a.config.url}: ${JSON.stringify((n=e.response)==null?void 0:n.data)}`:e instanceof Error?e.message:`Unexpected error: ${f1(e)||e}`}const xs=e=>{const t=e.softTimeout||3e3,[r,a]=ae.useState(!1),n=z.useTheme();return ae.useEffect(()=>{const o=setTimeout(()=>{a(!0)},t);return()=>clearTimeout(o)}),b.jsx(z.Stack,{width:"100%",height:"100%",alignItems:"center",justifyContent:"center",sx:{color:n.palette.text.primary},children:e.error?b.jsx(ad,{loadingMessage:e.message,error:e.error}):b.jsxs(b.Fragment,{children:[b.jsx(z.CircularProgress,{sx:{marginBottom:"24px"}}),!!e.message&&b.jsx("div",{children:e.message}),b.jsx(z.Stack,{sx:{visibility:r?"visible":"hidden",marginTop:"1rem",color:n.palette.text.secondary},children:"This is taking longer than expected..."})]})})},ad=e=>{const t=y1(e.error),r=e.error instanceof Error?e.error.stack:null,a=z.useTheme();return b.jsxs(z.Stack,{sx:{maxHeight:"100%",maxWidth:"min(100%, 800px)",padding:2,overflow:"auto",color:a.palette.error.main,"& pre":{whiteSpace:"pre-wrap",wordBreak:"break-word",paddingBottom:"3rem"}},children:[(e.loadingMessage?`Error while ${ds.lowerFirst(z.capitalize(e.loadingMessage))} - `:"")+t,b.jsx("br",{}),r&&b.jsx("pre",{children:r})]})},b1=({title:e,titleId:t,...r},a)=>H.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:19,height:10,fill:"none",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.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"})),S1=ae.forwardRef(b1),v1=({title:e,titleId:t,...r},a)=>H.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:19,height:10,fill:"none",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.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"})),x1=ae.forwardRef(v1),O1=({title:e,titleId:t,...r},a)=>H.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:10,height:19,fill:"none",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.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"})),w1=ae.forwardRef(O1),C1=({title:e,titleId:t,...r},a)=>H.createElement("svg",{width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.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"})),P1=ae.forwardRef(C1);function V1(){this.__data__=[],this.size=0}function nd(e,t){return e===t||e!==e&&t!==t}function ao(e,t){for(var r=e.length;r--;)if(nd(e[r][0],t))return r;return-1}var R1=Array.prototype,_1=R1.splice;function A1(e){var t=this.__data__,r=ao(t,e);if(r<0)return!1;var a=t.length-1;return r==a?t.pop():_1.call(t,r,1),--this.size,!0}function T1(e){var t=this.__data__,r=ao(t,e);return r<0?void 0:t[r][1]}function E1(e){return ao(this.__data__,e)>-1}function I1(e,t){var r=this.__data__,a=ao(r,e);return a<0?(++this.size,r.push([e,t])):r[a][1]=t,this}function Lt(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var a=e[t];this.set(a[0],a[1])}}Lt.prototype.clear=V1;Lt.prototype.delete=A1;Lt.prototype.get=T1;Lt.prototype.has=E1;Lt.prototype.set=I1;function M1(){this.__data__=new Lt,this.size=0}function j1(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function $1(e){return this.__data__.get(e)}function U1(e){return this.__data__.has(e)}var L1="[object AsyncFunction]",k1="[object Function]",B1="[object GeneratorFunction]",F1="[object Proxy]";function od(e){if(!dr(e))return!1;var t=gr(e);return t==k1||t==B1||t==L1||t==F1}var Mo=Rt["__core-js_shared__"],cl=function(){var e=/[^.]+$/.exec(Mo&&Mo.keys&&Mo.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function N1(e){return!!cl&&cl in e}var D1=Function.prototype,z1=D1.toString;function br(e){if(e!=null){try{return z1.call(e)}catch{}try{return e+""}catch{}}return""}var G1=/[\\^$.*+?()[\]{}|]/g,J1=/^\[object .+?Constructor\]$/,H1=Function.prototype,q1=Object.prototype,W1=H1.toString,K1=q1.hasOwnProperty,Q1=RegExp("^"+W1.call(K1).replace(G1,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Y1(e){if(!dr(e)||N1(e))return!1;var t=od(e)?Q1:J1;return t.test(br(e))}function X1(e,t){return e==null?void 0:e[t]}function Sr(e,t){var r=X1(e,t);return Y1(r)?r:void 0}var Ua=Sr(Rt,"Map"),La=Sr(Object,"create");function Z1(){this.__data__=La?La(null):{},this.size=0}function ex(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var tx="__lodash_hash_undefined__",rx=Object.prototype,ax=rx.hasOwnProperty;function nx(e){var t=this.__data__;if(La){var r=t[e];return r===tx?void 0:r}return ax.call(t,e)?t[e]:void 0}var ox=Object.prototype,sx=ox.hasOwnProperty;function ix(e){var t=this.__data__;return La?t[e]!==void 0:sx.call(t,e)}var lx="__lodash_hash_undefined__";function cx(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=La&&t===void 0?lx:t,this}function hr(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var a=e[t];this.set(a[0],a[1])}}hr.prototype.clear=Z1;hr.prototype.delete=ex;hr.prototype.get=nx;hr.prototype.has=ix;hr.prototype.set=cx;function dx(){this.size=0,this.__data__={hash:new hr,map:new(Ua||Lt),string:new hr}}function ux(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function no(e,t){var r=e.__data__;return ux(t)?r[typeof t=="string"?"string":"hash"]:r.map}function px(e){var t=no(this,e).delete(e);return this.size-=t?1:0,t}function hx(e){return no(this,e).get(e)}function mx(e){return no(this,e).has(e)}function fx(e,t){var r=no(this,e),a=r.size;return r.set(e,t),this.size+=r.size==a?0:1,this}function kt(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var a=e[t];this.set(a[0],a[1])}}kt.prototype.clear=dx;kt.prototype.delete=px;kt.prototype.get=hx;kt.prototype.has=mx;kt.prototype.set=fx;var gx=200;function yx(e,t){var r=this.__data__;if(r instanceof Lt){var a=r.__data__;if(!Ua||a.length<gx-1)return a.push([e,t]),this.size=++r.size,this;r=this.__data__=new kt(a)}return r.set(e,t),this.size=r.size,this}function jt(e){var t=this.__data__=new Lt(e);this.size=t.size}jt.prototype.clear=M1;jt.prototype.delete=j1;jt.prototype.get=$1;jt.prototype.has=U1;jt.prototype.set=yx;var bx="__lodash_hash_undefined__";function Sx(e){return this.__data__.set(e,bx),this}function vx(e){return this.__data__.has(e)}function Tn(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new kt;++t<r;)this.add(e[t])}Tn.prototype.add=Tn.prototype.push=Sx;Tn.prototype.has=vx;function xx(e,t){for(var r=-1,a=e==null?0:e.length;++r<a;)if(t(e[r],r,e))return!0;return!1}function Ox(e,t){return e.has(t)}var wx=1,Cx=2;function sd(e,t,r,a,n,o){var s=r&wx,i=e.length,l=t.length;if(i!=l&&!(s&&l>i))return!1;var c=o.get(e),d=o.get(t);if(c&&d)return c==t&&d==e;var u=-1,p=!0,m=r&Cx?new Tn:void 0;for(o.set(e,t),o.set(t,e);++u<i;){var g=e[u],h=t[u];if(a)var x=s?a(h,g,u,t,e,o):a(g,h,u,e,t,o);if(x!==void 0){if(x)continue;p=!1;break}if(m){if(!xx(t,function(E,U){if(!Ox(m,U)&&(g===E||n(g,E,r,a,o)))return m.push(U)})){p=!1;break}}else if(!(g===h||n(g,h,r,a,o))){p=!1;break}}return o.delete(e),o.delete(t),p}var dl=Rt.Uint8Array;function Px(e){var t=-1,r=Array(e.size);return e.forEach(function(a,n){r[++t]=[n,a]}),r}function Vx(e){var t=-1,r=Array(e.size);return e.forEach(function(a){r[++t]=a}),r}var Rx=1,_x=2,Ax="[object Boolean]",Tx="[object Date]",Ex="[object Error]",Ix="[object Map]",Mx="[object Number]",jx="[object RegExp]",$x="[object Set]",Ux="[object String]",Lx="[object Symbol]",kx="[object ArrayBuffer]",Bx="[object DataView]",ul=Xt?Xt.prototype:void 0,jo=ul?ul.valueOf:void 0;function Fx(e,t,r,a,n,o,s){switch(r){case Bx:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case kx:return!(e.byteLength!=t.byteLength||!o(new dl(e),new dl(t)));case Ax:case Tx:case Mx:return nd(+e,+t);case Ex:return e.name==t.name&&e.message==t.message;case jx:case Ux:return e==t+"";case Ix:var i=Px;case $x:var l=a&Rx;if(i||(i=Vx),e.size!=t.size&&!l)return!1;var c=s.get(e);if(c)return c==t;a|=_x,s.set(e,t);var d=sd(i(e),i(t),a,n,o,s);return s.delete(e),d;case Lx:if(jo)return jo.call(e)==jo.call(t)}return!1}function Nx(e,t){for(var r=-1,a=t.length,n=e.length;++r<a;)e[n+r]=t[r];return e}var Vt=Array.isArray;function Dx(e,t,r){var a=t(e);return Vt(e)?a:Nx(a,r(e))}function zx(e,t){for(var r=-1,a=e==null?0:e.length,n=0,o=[];++r<a;){var s=e[r];t(s,r,e)&&(o[n++]=s)}return o}function Gx(){return[]}var Jx=Object.prototype,Hx=Jx.propertyIsEnumerable,pl=Object.getOwnPropertySymbols,qx=pl?function(e){return e==null?[]:(e=Object(e),zx(pl(e),function(t){return Hx.call(e,t)}))}:Gx;function Wx(e,t){for(var r=-1,a=Array(e);++r<e;)a[r]=t(r);return a}var Kx="[object Arguments]";function hl(e){return ur(e)&&gr(e)==Kx}var id=Object.prototype,Qx=id.hasOwnProperty,Yx=id.propertyIsEnumerable,ld=hl(function(){return arguments}())?hl:function(e){return ur(e)&&Qx.call(e,"callee")&&!Yx.call(e,"callee")};function Xx(){return!1}var cd=typeof exports=="object"&&exports&&!exports.nodeType&&exports,ml=cd&&typeof module=="object"&&module&&!module.nodeType&&module,Zx=ml&&ml.exports===cd,fl=Zx?Rt.Buffer:void 0,eO=fl?fl.isBuffer:void 0,ns=eO||Xx,tO=9007199254740991,rO=/^(?:0|[1-9]\d*)$/;function dd(e,t){var r=typeof e;return t=t??tO,!!t&&(r=="number"||r!="symbol"&&rO.test(e))&&e>-1&&e%1==0&&e<t}var aO=9007199254740991;function Os(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=aO}var nO="[object Arguments]",oO="[object Array]",sO="[object Boolean]",iO="[object Date]",lO="[object Error]",cO="[object Function]",dO="[object Map]",uO="[object Number]",pO="[object Object]",hO="[object RegExp]",mO="[object Set]",fO="[object String]",gO="[object WeakMap]",yO="[object ArrayBuffer]",bO="[object DataView]",SO="[object Float32Array]",vO="[object Float64Array]",xO="[object Int8Array]",OO="[object Int16Array]",wO="[object Int32Array]",CO="[object Uint8Array]",PO="[object Uint8ClampedArray]",VO="[object Uint16Array]",RO="[object Uint32Array]",we={};we[SO]=we[vO]=we[xO]=we[OO]=we[wO]=we[CO]=we[PO]=we[VO]=we[RO]=!0;we[nO]=we[oO]=we[yO]=we[sO]=we[bO]=we[iO]=we[lO]=we[cO]=we[dO]=we[uO]=we[pO]=we[hO]=we[mO]=we[fO]=we[gO]=!1;function _O(e){return ur(e)&&Os(e.length)&&!!we[gr(e)]}function AO(e){return function(t){return e(t)}}var ud=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Ra=ud&&typeof module=="object"&&module&&!module.nodeType&&module,TO=Ra&&Ra.exports===ud,$o=TO&&dc.process,gl=function(){try{var e=Ra&&Ra.require&&Ra.require("util").types;return e||$o&&$o.binding&&$o.binding("util")}catch{}}(),yl=gl&&gl.isTypedArray,pd=yl?AO(yl):_O,EO=Object.prototype,IO=EO.hasOwnProperty;function MO(e,t){var r=Vt(e),a=!r&&ld(e),n=!r&&!a&&ns(e),o=!r&&!a&&!n&&pd(e),s=r||a||n||o,i=s?Wx(e.length,String):[],l=i.length;for(var c in e)IO.call(e,c)&&!(s&&(c=="length"||n&&(c=="offset"||c=="parent")||o&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||dd(c,l)))&&i.push(c);return i}var jO=Object.prototype;function $O(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||jO;return e===r}function UO(e,t){return function(r){return e(t(r))}}var LO=UO(Object.keys,Object),kO=Object.prototype,BO=kO.hasOwnProperty;function FO(e){if(!$O(e))return LO(e);var t=[];for(var r in Object(e))BO.call(e,r)&&r!="constructor"&&t.push(r);return t}function hd(e){return e!=null&&Os(e.length)&&!od(e)}function ws(e){return hd(e)?MO(e):FO(e)}function bl(e){return Dx(e,ws,qx)}var NO=1,DO=Object.prototype,zO=DO.hasOwnProperty;function GO(e,t,r,a,n,o){var s=r&NO,i=bl(e),l=i.length,c=bl(t),d=c.length;if(l!=d&&!s)return!1;for(var u=l;u--;){var p=i[u];if(!(s?p in t:zO.call(t,p)))return!1}var m=o.get(e),g=o.get(t);if(m&&g)return m==t&&g==e;var h=!0;o.set(e,t),o.set(t,e);for(var x=s;++u<l;){p=i[u];var E=e[p],U=t[p];if(a)var F=s?a(U,E,p,t,e,o):a(E,U,p,e,t,o);if(!(F===void 0?E===U||n(E,U,r,a,o):F)){h=!1;break}x||(x=p=="constructor")}if(h&&!x){var N=e.constructor,J=t.constructor;N!=J&&"constructor"in e&&"constructor"in t&&!(typeof N=="function"&&N instanceof N&&typeof J=="function"&&J instanceof J)&&(h=!1)}return o.delete(e),o.delete(t),h}var os=Sr(Rt,"DataView"),ss=Sr(Rt,"Promise"),is=Sr(Rt,"Set"),ls=Sr(Rt,"WeakMap"),Sl="[object Map]",JO="[object Object]",vl="[object Promise]",xl="[object Set]",Ol="[object WeakMap]",wl="[object DataView]",HO=br(os),qO=br(Ua),WO=br(ss),KO=br(is),QO=br(ls),qt=gr;(os&&qt(new os(new ArrayBuffer(1)))!=wl||Ua&&qt(new Ua)!=Sl||ss&&qt(ss.resolve())!=vl||is&&qt(new is)!=xl||ls&&qt(new ls)!=Ol)&&(qt=function(e){var t=gr(e),r=t==JO?e.constructor:void 0,a=r?br(r):"";if(a)switch(a){case HO:return wl;case qO:return Sl;case WO:return vl;case KO:return xl;case QO:return Ol}return t});var YO=1,Cl="[object Arguments]",Pl="[object Array]",rn="[object Object]",XO=Object.prototype,Vl=XO.hasOwnProperty;function ZO(e,t,r,a,n,o){var s=Vt(e),i=Vt(t),l=s?Pl:qt(e),c=i?Pl:qt(t);l=l==Cl?rn:l,c=c==Cl?rn:c;var d=l==rn,u=c==rn,p=l==c;if(p&&ns(e)){if(!ns(t))return!1;s=!0,d=!1}if(p&&!d)return o||(o=new jt),s||pd(e)?sd(e,t,r,a,n,o):Fx(e,t,l,r,a,n,o);if(!(r&YO)){var m=d&&Vl.call(e,"__wrapped__"),g=u&&Vl.call(t,"__wrapped__");if(m||g){var h=m?e.value():e,x=g?t.value():t;return o||(o=new jt),n(h,x,r,a,o)}}return p?(o||(o=new jt),GO(e,t,r,a,n,o)):!1}function oo(e,t,r,a,n){return e===t?!0:e==null||t==null||!ur(e)&&!ur(t)?e!==e&&t!==t:ZO(e,t,r,a,oo,n)}function ew(e,t){return oo(e,t)}const md=({store:e})=>{const{t}=Te.useTranslation(),[r,a]=ae.useState(e.jogger.motionStream.rapidlyChangingMotionState.state.joint_limit_reached.limit_reached),n=ae.useRef(r);Wr(()=>{const s=e.jogger.motionStream.rapidlyChangingMotionState.state.joint_limit_reached.limit_reached;ew(n.current,s)||(n.current=s,a(s))});const o=[];for(const[s,i]of r.entries())i&&o.push(s);return b.jsx(z.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(", ")})})},tw=z.styled(z.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 an({labelValue:e,...t}){return b.jsxs(tw,{fullWidth:!0,variant:"filled",children:[b.jsx(z.InputLabel,{id:t.labelId,children:e}),b.jsx(z.Select,{...t})]})}var Rl=function(){try{var e=Sr(Object,"defineProperty");return e({},"",{}),e}catch{}}();function rw(e,t,r){t=="__proto__"&&Rl?Rl(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function aw(e,t,r,a){for(var n=-1,o=e==null?0:e.length;++n<o;){var s=e[n];t(a,s,r(s),e)}return a}function nw(e){return function(t,r,a){for(var n=-1,o=Object(t),s=a(t),i=s.length;i--;){var l=s[++n];if(r(o[l],l,o)===!1)break}return t}}var ow=nw();function sw(e,t){return e&&ow(e,t,ws)}function iw(e,t){return function(r,a){if(r==null)return r;if(!hd(r))return e(r,a);for(var n=r.length,o=-1,s=Object(r);++o<n&&a(s[o],o,s)!==!1;);return r}}var lw=iw(sw);function cw(e,t,r,a){return lw(e,function(n,o,s){t(a,n,r(n),s)}),a}var dw=1,uw=2;function pw(e,t,r,a){var n=r.length,o=n;if(e==null)return!o;for(e=Object(e);n--;){var s=r[n];if(s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++n<o;){s=r[n];var i=s[0],l=e[i],c=s[1];if(s[2]){if(l===void 0&&!(i in e))return!1}else{var d=new jt,u;if(!(u===void 0?oo(c,l,dw|uw,a,d):u))return!1}}return!0}function fd(e){return e===e&&!dr(e)}function hw(e){for(var t=ws(e),r=t.length;r--;){var a=t[r],n=e[a];t[r]=[a,n,fd(n)]}return t}function gd(e,t){return function(r){return r==null?!1:r[e]===t&&(t!==void 0||e in Object(r))}}function mw(e){var t=hw(e);return t.length==1&&t[0][2]?gd(t[0][0],t[0][1]):function(r){return r===e||pw(r,e,t)}}var fw=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,gw=/^\w*$/;function Cs(e,t){if(Vt(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||qn(e)?!0:gw.test(e)||!fw.test(e)||t!=null&&e in Object(t)}var yw="Expected a function";function Ps(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(yw);var r=function(){var a=arguments,n=t?t.apply(this,a):a[0],o=r.cache;if(o.has(n))return o.get(n);var s=e.apply(this,a);return r.cache=o.set(n,s)||o,s};return r.cache=new(Ps.Cache||kt),r}Ps.Cache=kt;var bw=500;function Sw(e){var t=Ps(e,function(a){return r.size===bw&&r.clear(),a}),r=t.cache;return t}var vw=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,xw=/\\(\\)?/g,Ow=Sw(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(vw,function(r,a,n,o){t.push(n?o.replace(xw,"$1"):a||r)}),t});function ww(e,t){for(var r=-1,a=e==null?0:e.length,n=Array(a);++r<a;)n[r]=t(e[r],r,e);return n}var _l=Xt?Xt.prototype:void 0,Al=_l?_l.toString:void 0;function yd(e){if(typeof e=="string")return e;if(Vt(e))return ww(e,yd)+"";if(qn(e))return Al?Al.call(e):"";var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function bd(e){return e==null?"":yd(e)}function Sd(e,t){return Vt(e)?e:Cs(e,t)?[e]:Ow(bd(e))}function so(e){if(typeof e=="string"||qn(e))return e;var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function vd(e,t){t=Sd(t,e);for(var r=0,a=t.length;e!=null&&r<a;)e=e[so(t[r++])];return r&&r==a?e:void 0}function Cw(e,t,r){var a=e==null?void 0:vd(e,t);return a===void 0?r:a}function Pw(e,t){return e!=null&&t in Object(e)}function Vw(e,t,r){t=Sd(t,e);for(var a=-1,n=t.length,o=!1;++a<n;){var s=so(t[a]);if(!(o=e!=null&&r(e,s)))break;e=e[s]}return o||++a!=n?o:(n=e==null?0:e.length,!!n&&Os(n)&&dd(s,n)&&(Vt(e)||ld(e)))}function Rw(e,t){return e!=null&&Vw(e,t,Pw)}var _w=1,Aw=2;function Tw(e,t){return Cs(e)&&fd(t)?gd(so(e),t):function(r){var a=Cw(r,e);return a===void 0&&a===t?Rw(r,e):oo(t,a,_w|Aw)}}function Ew(e){return e}function Iw(e){return function(t){return t==null?void 0:t[e]}}function Mw(e){return function(t){return vd(t,e)}}function jw(e){return Cs(e)?Iw(so(e)):Mw(e)}function $w(e){return typeof e=="function"?e:e==null?Ew:typeof e=="object"?Vt(e)?Tw(e[0],e[1]):mw(e):jw(e)}function Uw(e,t){return function(r,a){var n=Vt(r)?aw:cw,o={};return n(r,e,$w(a),o)}}var nn=Uw(function(e,t,r){rw(e,r,t)}),Lw=0;function kw(e){var t=++Lw;return bd(e)+t}const cs=[{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}],Bw=[{id:"continuous"},...cs],Fw=["coordsys","tool"];class io{constructor(t,r,a,n){var o,s;this.jogger=t,this.motionGroupSpec=r,this.coordSystems=a,this.tcps=n,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 a)if(i.coordinate_system===""){i.coordinate_system="world";break}this.selectedCoordSystemId=((o=a[0])==null?void 0:o.coordinate_system)||"world",this.selectedTcpId=((s=n[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,[a,{coordinatesystems:n},{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 io(t,a,n||[],o||[])}dispose(){for(const t of this.disposers)t();this.jogger.dispose()}get coordSystemCountByName(){return ds.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=ir.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 Bw}get discreteIncrementOptions(){return cs}get incrementOptionsById(){return nn(this.incrementOptions,t=>t.id)}get tabsById(){return nn(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 nn(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 nn(this.tcps,t=>t.id)}get activeDiscreteIncrement(){return this.selectedOrientation==="tool"?void 0:cs.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 a=this.tabs[r]||this.tabs[0];this.selectedTabId=a.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=kw();this.lock(r);try{return await t()}finally{this.unlock(r)}}}const Nw=je.observer(({store:e})=>{var n;const{t}=Te.useTranslation(),r=[];function a(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(b.jsx(an,{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=>b.jsx(z.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(b.jsx(an,{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=>b.jsx(z.MenuItem,{value:o.id,children:o.id},o.id))},"tcp")),e.showOrientationSelect&&r.push(b.jsx(an,{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:Fw.map(o=>b.jsx(z.MenuItem,{value:o,children:a(o)},o))},"orientation")),e.showIncrementSelect&&r.push(b.jsxs(an,{labelValue:t("Jogging.Increment.hlb"),labelId:"jogging-increment-select",size:"small",variant:"filled",value:((n=e.activeDiscreteIncrement)==null?void 0:n.id)||"continuous",onChange:o=>e.setSelectedIncrementId(o.target.value),disabled:e.isLocked,children:[b.jsx(z.MenuItem,{value:"continuous",children:t("Jogging.Increment.Continuous.dd")},"continuous"),e.selectedOrientation==="tool"?null:e.discreteIncrementOptions.map(o=>b.jsx(z.MenuItem,{value:o.id,children:e.currentMotionType==="translate"?`${o.mm}mm`:`${o.degrees}°`},o.id))]},"increment")),b.jsx(z.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)=>b.jsx(z.Box,{sx:{gridColumn:r.length%2===1&&s===r.length-1?"span 2":"auto"},children:o},s))})}),Dw=z.styled(z.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 zw(e,t,r=(a,n)=>a===n){return e.length===t.length&&e.every((a,n)=>r(a,t[n]))}const Gw=2;function Br(e,t,r,a,n){return r===1?Math.min(e+t,n):Math.max(e-t,a)}function xd(e,t){return e-t}function Tl(e,t){const{index:r}=e.reduce((a,n,o)=>{const s=Math.abs(t-n);return a===null||s<a.distance||s===a.distance?{distance:s,index:o}:a},null)??{};return r}function on(e,t){if(t.current!==void 0&&e.changedTouches){const r=e;for(let a=0;a<r.changedTouches.length;a+=1){const n=r.changedTouches[a];if(n.identifier===t.current)return{x:n.clientX,y:n.clientY}}return!1}return{x:e.clientX,y:e.clientY}}function En(e,t,r){return(e-t)*100/(r-t)}function Jw(e,t,r){return(r-t)*e+t}function Hw(e){if(Math.abs(e)<1){const r=e.toExponential().split("e-"),a=r[0].split(".")[1];return(a?a.length:0)+parseInt(r[1],10)}const t=e.toString().split(".")[1];return t?t.length:0}function qw(e,t,r){const a=Math.round((e-r)/t)*t+r;return Number(a.toFixed(Hw(t)))}function El({values:e,newValue:t,index:r}){const a=e.slice();return a[r]=t,a.sort(xd)}function sn({sliderRef:e,activeIndex:t,setActive:r}){var n,o,s;const a=un(e.current);(!((n=e.current)!=null&&n.contains(a.activeElement))||Number((o=a==null?void 0:a.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 ln(e,t){return typeof e=="number"&&typeof t=="number"?e===t:typeof e=="object"&&typeof t=="object"?zw(e,t):!1}const Ww={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}%`})}},Kw=e=>e;let cn;function Il(){return cn===void 0&&(typeof CSS<"u"&&typeof CSS.supports=="function"?cn=CSS.supports("touch-action","none"):cn=!0),cn}function Qw(e){const{"aria-labelledby":t,defaultValue:r,disabled:a=!1,disableSwap:n=!1,isRtl:o=!1,marks:s=!1,max:i=100,min:l=0,name:c,onChange:d,onChangeCommitted:u,orientation:p="horizontal",rootRef:m,scale:g=Kw,step:h=1,shiftStep:x=10,tabIndex:E,value:U}=e,F=H.useRef(void 0),[N,J]=H.useState(-1),[K,j]=H.useState(-1),[L,k]=H.useState(!1),y=H.useRef(0),M=H.useRef(null),[B,G]=Np({controlled:U,default:r??l,name:"Slider"}),D=d&&((W,Q,ee)=>{const de=W.nativeEvent||W,he=new de.constructor(de.type,de);Object.defineProperty(he,"target",{writable:!0,value:{value:Q,name:c}}),M.current=Q,d(he,Q,ee)}),re=Array.isArray(B);let Z=re?B.slice().sort(xd):[B];Z=Z.map(W=>W==null?l:Fr(W,l,i));const xe=s===!0&&h!==null?[...Array(Math.floor((i-l)/h)+1)].map((W,Q)=>({value:l+h*Q})):s||[],X=xe.map(W=>W.value),[ce,fe]=H.useState(-1),le=H.useRef(null),He=Zl(m,le),_t=W=>Q=>{var de;const ee=Number(Q.currentTarget.getAttribute("data-index"));Qs(Q.target)&&fe(ee),j(ee),(de=W==null?void 0:W.onFocus)==null||de.call(W,Q)},ra=W=>Q=>{var ee;Qs(Q.target)||fe(-1),j(-1),(ee=W==null?void 0:W.onBlur)==null||ee.call(W,Q)},vr=(W,Q)=>{const ee=Number(W.currentTarget.getAttribute("data-index")),de=Z[ee],he=X.indexOf(de);let te=Q;if(xe&&h==null){const Ue=X[X.length-1];te>=Ue?te=Ue:te<=X[0]?te=X[0]:te=te<de?X[he-1]:X[he+1]}if(te=Fr(te,l,i),re){n&&(te=Fr(te,Z[ee-1]||-1/0,Z[ee+1]||1/0));const Ue=te;te=El({values:Z,newValue:te,index:ee});let De=ee;n||(De=te.indexOf(Ue)),sn({sliderRef:le,activeIndex:De})}G(te),fe(ee),D&&!ln(te,B)&&D(W,te,ee),u&&u(W,M.current??te)},er=W=>Q=>{var ee;if(["ArrowUp","ArrowDown","ArrowLeft","ArrowRight","PageUp","PageDown","Home","End"].includes(Q.key)){Q.preventDefault();const de=Number(Q.currentTarget.getAttribute("data-index")),he=Z[de];let te=null;if(h!=null){const Ue=Q.shiftKey?x:h;switch(Q.key){case"ArrowUp":te=Br(he,Ue,1,l,i);break;case"ArrowRight":te=Br(he,Ue,o?-1:1,l,i);break;case"ArrowDown":te=Br(he,Ue,-1,l,i);break;case"ArrowLeft":te=Br(he,Ue,o?1:-1,l,i);break;case"PageUp":te=Br(he,x,1,l,i);break;case"PageDown":te=Br(he,x,-1,l,i);break;case"Home":te=l;break;case"End":te=i;break}}else if(xe){const Ue=X[X.length-1],De=X.indexOf(he),Ee=[o?"ArrowRight":"ArrowLeft","ArrowDown","PageDown","Home"],Qe=[o?"ArrowLeft":"ArrowRight","ArrowUp","PageUp","End"];Ee.includes(Q.key)?De===0?te=X[0]:te=X[De-1]:Qe.includes(Q.key)&&(De===X.length-1?te=Ue:te=X[De+1])}te!=null&&vr(Q,te)}(ee=W==null?void 0:W.onKeyDown)==null||ee.call(W,Q)};Yl(()=>{var W;a&&le.current.contains(document.activeElement)&&((W=document.activeElement)==null||W.blur())},[a]),a&&N!==-1&&J(-1),a&&ce!==-1&&fe(-1);const Bt=W=>Q=>{var ee;(ee=W.onChange)==null||ee.call(W,Q),vr(Q,Q.target.valueAsNumber)},nt=H.useRef(void 0);let dt=p;o&&p==="horizontal"&&(dt+="-reverse");const ot=({finger:W,move:Q=!1})=>{const{current:ee}=le,{width:de,height:he,bottom:te,left:Ue}=ee.getBoundingClientRect();let De;dt.startsWith("vertical")?De=(te-W.y)/he:De=(W.x-Ue)/de,dt.includes("-reverse")&&(De=1-De);let Ee;if(Ee=Jw(De,l,i),h)Ee=qw(Ee,h,l);else{const tr=Tl(X,Ee);Ee=X[tr]}Ee=Fr(Ee,l,i);let Qe=0;if(re){Q?Qe=nt.current:Qe=Tl(Z,Ee),n&&(Ee=Fr(Ee,Z[Qe-1]||-1/0,Z[Qe+1]||1/0));const tr=Ee;Ee=El({values:Z,newValue:Ee,index:Qe}),n&&Q||(Qe=Ee.indexOf(tr),nt.current=Qe)}return{newValue:Ee,activeIndex:Qe}},At=go(W=>{const Q=on(W,F);if(!Q)return;if(y.current+=1,W.type==="mousemove"&&W.buttons===0){et(W);return}const{newValue:ee,activeIndex:de}=ot({finger:Q,move:!0});sn({sliderRef:le,activeIndex:de,setActive:J}),G(ee),!L&&y.current>Gw&&k(!0),D&&!ln(ee,B)&&D(W,ee,de)}),et=go(W=>{const Q=on(W,F);if(k(!1),!Q)return;const{newValue:ee}=ot({finger:Q,move:!0});J(-1),W.type==="touchend"&&j(-1),u&&u(W,M.current??ee),F.current=void 0,Tt()}),Ne=go(W=>{if(a)return;Il()||W.preventDefault();const Q=W.changedTouches[0];Q!=null&&(F.current=Q.identifier);const ee=on(W,F);if(ee!==!1){const{newValue:he,activeIndex:te}=ot({finger:ee});sn({sliderRef:le,activeIndex:te,setActive:J}),G(he),D&&!ln(he,B)&&D(W,he,te)}y.current=0;const de=un(le.current);de.addEventListener("touchmove",At,{passive:!0}),de.addEventListener("touchend",et,{passive:!0})}),Tt=H.useCallback(()=>{const W=un(le.current);W.removeEventListener("mousemove",At),W.removeEventListener("mouseup",et),W.removeEventListener("touchmove",At),W.removeEventListener("touchend",et)},[et,At]);H.useEffect(()=>{const{current:W}=le;return W.addEventListener("touchstart",Ne,{passive:Il()}),()=>{W.removeEventListener("touchstart",Ne),Tt()}},[Tt,Ne]),H.useEffect(()=>{a&&Tt()},[a,Tt]);const Ft=W=>Q=>{var he;if((he=W.onMouseDown)==null||he.call(W,Q),a||Q.defaultPrevented||Q.button!==0)return;Q.preventDefault();const ee=on(Q,F);if(ee!==!1){const{newValue:te,activeIndex:Ue}=ot({finger:ee});sn({sliderRef:le,activeIndex:Ue,setActive:J}),G(te),D&&!ln(te,B)&&D(Q,te,Ue)}y.current=0;const de=un(le.current);de.addEventListener("mousemove",At,{passive:!0}),de.addEventListener("mouseup",et)},yt=En(re?Z[0]:l,l,i),Fe=En(Z[Z.length-1],l,i)-yt,Nt=(W={})=>{const Q=pn(W),ee={onMouseDown:Ft(Q||{})},de={...Q,...ee};return{...W,ref:He,...de}},Et=W=>Q=>{var de;(de=W.onMouseOver)==null||de.call(W,Q);const ee=Number(Q.currentTarget.getAttribute("data-index"));j(ee)},xr=W=>Q=>{var ee;(ee=W.onMouseLeave)==null||ee.call(W,Q),j(-1)},Or=(W={})=>{const Q=pn(W),ee={onMouseOver:Et(Q||{}),onMouseLeave:xr(Q||{})};return{...W,...Q,...ee}},Dt=W=>({pointerEvents:N!==-1&&N!==W?"none":void 0});let zt;return p==="vertical"&&(zt=o?"vertical-rl":"vertical-lr"),{active:N,axis:dt,axisProps:Ww,dragging:L,focusedThumbIndex:ce,getHiddenInputProps:(W={})=>{const Q=pn(W),ee={onChange:Bt(Q||{}),onFocus:_t(Q||{}),onBlur:ra(Q||{}),onKeyDown:er(Q||{})},de={...Q,...ee};return{tabIndex:E,"aria-labelledby":t,"aria-orientation":p,"aria-valuemax":g(i),"aria-valuemin":g(l),name:c,type:"range",min:e.min,max:e.max,step:e.step===null&&e.marks?"any":e.step??void 0,disabled:a,...W,...de,style:{...Dp,direction:o?"rtl":"ltr",width:"100%",height:"100%",writingMode:zt}}},getRootProps:Nt,getThumbProps:Or,marks:xe,open:K,range:re,rootRef:He,trackLeap:Fe,trackOffset:yt,values:Z,getThumbStyle:Dt}}function gn(e){return typeof e=="string"}const Yw=e=>!e||!gn(e);function Xw(e){return typeof e.main=="string"}function Zw(e,t=[]){if(!Xw(e))return!1;for(const r of t)if(!e.hasOwnProperty(r)||typeof e[r]!="string")return!1;return!0}function Vs(e=[]){return([,t])=>t&&Zw(t,e)}function eC(e){return Fa("MuiSlider",e)}const lt=Jl("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"]),tC=e=>{const{open:t}=e;return{offset:Pt(t&<.valueLabelOpen),circle:lt.valueLabelCircle,label:lt.valueLabelLabel}};function Od(e){const{children:t,className:r,value:a}=e,n=tC(e);return t?H.cloneElement(t,{className:Pt(t.props.className)},b.jsxs(H.Fragment,{children:[t.props.children,b.jsx("span",{className:Pt(n.offset,r),"aria-hidden":!0,children:b.jsx("span",{className:n.circle,children:b.jsx("span",{className:n.label,children:a})})})]})):null}process.env.NODE_ENV!=="production"&&(Od.propTypes={children:S.element.isRequired,className:S.string,value:S.node});function Ml(e){return e}const rC=$t("span",{name:"MuiSlider",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,t[`color${We(r.color)}`],r.size!=="medium"&&t[`size${We(r.size)}`],r.marked&&t.marked,r.orientation==="vertical"&&t.vertical,r.track==="inverted"&&t.trackInverted,r.track===!1&&t.trackFalse]}})(fr(({theme:e})=>({borderRadius:12,boxSizing:"content-box",display:"inline-block",position:"relative",cursor:"pointer",touchAction:"none",WebkitTapHighlightColor:"transparent","@media print":{colorAdjust:"exact"},[`&.${lt.disabled}`]:{pointerEvents:"none",cursor:"default",color:(e.vars||e).palette.grey[400]},[`&.${lt.dragging}`]:{[`& .${lt.thumb}, & .${lt.track}`]:{transition:"none"}},variants:[...Object.entries(e.palette).filter(Vs()).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}}]}))),aC=$t("span",{name:"MuiSlider",slot:"Rail",overridesResolver:(e,t)=>t.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}}]}),nC=$t("span",{name:"MuiSlider",slot:"Track",overridesResolver:(e,t)=>t.track})(fr(({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(Vs()).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:_a(e.palette[t].main,.5)}),...e.applyStyles("dark",{borderColor:_a(e.palette[t].main,.5)})}}}))]}))),oC=$t("span",{name:"MuiSlider",slot:"Thumb",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.thumb,t[`thumbColor${We(r.color)}`],r.size!=="medium"&&t[`thumbSize${We(r.size)}`]]}})(fr(({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%)"},[`&.${lt.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(Vs()).map(([t])=>({props:{color:t},style:{[`&:hover, &.${lt.focusVisible}`]:{...e.vars?{boxShadow:`0px 0px 0px 8px rgba(${e.vars.palette[t].mainChannel} / 0.16)`}:{boxShadow:`0px 0px 0px 8px ${Bo(e.palette[t].main,.16)}`},"@media (hover: none)":{boxShadow:"none"}},[`&.${lt.active}`]:{...e.vars?{boxShadow:`0px 0px 0px 14px rgba(${e.vars.palette[t].mainChannel} / 0.16)`}:{boxShadow:`0px 0px 0px 14px ${Bo(e.palette[t].main,.16)}`}}}}))]}))),wd=$t(Od,{name:"MuiSlider",slot:"ValueLabel",overridesResolver:(e,t)=>t.valueLabel})(fr(({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%"},[`&.${lt.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%"},[`&.${lt.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"&&(wd.propTypes={children:S.element.isRequired,index:S.number.isRequired,open:S.bool.isRequired,value:S.node});const sC=$t("span",{name:"MuiSlider",slot:"Mark",shouldForwardProp:e=>fs(e)&&e!=="markActive",overridesResolver:(e,t)=>{const{markActive:r}=e;return[t.mark,r&&t.markActive]}})(fr(({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}}]}))),iC=$t("span",{name:"MuiSlider",slot:"MarkLabel",shouldForwardProp:e=>fs(e)&&e!=="markLabelActive",overridesResolver:(e,t)=>t.markLabel})(fr(({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}}]}))),lC=e=>{const{disabled:t,dragging:r,marked:a,orientation:n,track:o,classes:s,color:i,size:l}=e,c={root:["root",t&&"disabled",r&&"dragging",a&&"marked",n==="vertical"&&"vertical",o==="inverted"&&"trackInverted",o===!1&&"trackFalse",i&&`color${We(i)}`,l&&`size${We(l)}`],rail:["rail"],track:["track"],mark:["mark"],markActive:["markActive"],markLabel:["markLabel"],markLabelActive:["markLabelActive"],valueLabel:["valueLabel"],thumb:["thumb",t&&"disabled",l&&`thumbSize${We(l)}`,i&&`thumbColor${We(i)}`],active:["active"],disabled:["disabled"],focusVisible:["focusVisible"]};return hs(c,eC,s)},cC=({children:e})=>e,Cd=H.forwardRef(function(t,r){const a=gs({props:t,name:"MuiSlider"}),n=Wp(),{"aria-label":o,"aria-valuetext":s,"aria-labelledby":i,component:l="span",components:c={},componentsProps:d={},color:u="primary",classes:p,className:m,disableSwap:g=!1,disabled:h=!1,getAriaLabel:x,getAriaValueText:E,marks:U=!1,max:F=100,min:N=0,name:J,onChange:K,onChangeCommitted:j,orientation:L="horizontal",shiftStep:k=10,size:y="medium",step:M=1,scale:B=Ml,slotProps:G,slots:D,tabIndex:re,track:Z="normal",value:xe,valueLabelDisplay:X="off",valueLabelFormat:ce=Ml,...fe}=a,le={...a,isRtl:n,max:F,min:N,classes:p,disabled:h,disableSwap:g,orientation:L,marks:U,color:u,size:y,step:M,shiftStep:k,scale:B,track:Z,valueLabelDisplay:X,valueLabelFormat:ce},{axisProps:He,getRootProps:_t,getHiddenInputProps:ra,getThumbProps:vr,open:er,active:Bt,axis:nt,focusedThumbIndex:dt,range:ot,dragging:At,marks:et,values:Ne,trackOffset:Tt,trackLeap:Ft,getThumbStyle:yt}=Qw({...le,rootRef:r});le.marked=et.length>0&&et.some(Ve=>Ve.label),le.dragging=At,le.focusedThumbIndex=dt;const Fe=lC(le),Nt=(D==null?void 0:D.root)??c.Root??rC,Et=(D==null?void 0:D.rail)??c.Rail??aC,xr=(D==null?void 0:D.track)??c.Track??nC,Or=(D==null?void 0:D.thumb)??c.Thumb??oC,Dt=(D==null?void 0:D.valueLabel)??c.ValueLabel??wd,zt=(D==null?void 0:D.mark)??c.Mark??sC,wr=(D==null?void 0:D.markLabel)??c.MarkLabel??iC,W=(D==null?void 0:D.input)??c.Input??"input",Q=(G==null?void 0:G.root)??d.root,ee=(G==null?void 0:G.rail)??d.rail,de=(G==null?void 0:G.track)??d.track,he=(G==null?void 0:G.thumb)??d.thumb,te=(G==null?void 0:G.valueLabel)??d.valueLabel,Ue=(G==null?void 0:G.mark)??d.mark,De=(G==null?void 0:G.markLabel)??d.markLabel,Ee=(G==null?void 0:G.input)??d.input,Qe=Gt({elementType:Nt,getSlotProps:_t,externalSlotProps:Q,externalForwardedProps:fe,additionalProps:{...Yw(Nt)&&{as:l}},ownerState:{...le,...Q==null?void 0:Q.ownerState},className:[Fe.root,m]}),tr=Gt({elementType:Et,externalSlotProps:ee,ownerState:le,className:Fe.rail}),lo=Gt({elementType:xr,externalSlotProps:de,additionalProps:{style:{...He[nt].offset(Tt),...He[nt].leap(Ft)}},ownerState:{...le,...de==null?void 0:de.ownerState},className:Fe.track}),aa=Gt({elementType:Or,getSlotProps:vr,externalSlotProps:he,ownerState:{...le,...he==null?void 0:he.ownerState},className:Fe.thumb}),na=Gt({elementType:Dt,externalSlotProps:te,ownerState:{...le,...te==null?void 0:te.ownerState},className:Fe.valueLabel}),Cr=Gt({elementType:zt,externalSlotProps:Ue,ownerState:le,className:Fe.mark}),bt=Gt({elementType:wr,externalSlotProps:De,ownerState:le,className:Fe.markLabel}),oa=Gt({elementType:W,getSlotProps:ra,externalSlotProps:Ee,ownerState:le});return b.jsxs(Nt,{...Qe,children:[b.jsx(Et,{...tr}),b.jsx(xr,{...lo}),et.filter(Ve=>Ve.value>=N&&Ve.value<=F).map((Ve,Le)=>{const sa=En(Ve.value,N,F),rr=He[nt].offset(sa);let ut;return Z===!1?ut=Ne.includes(Ve.value):ut=Z==="normal"&&(ot?Ve.value>=Ne[0]&&Ve.value<=Ne[Ne.length-1]:Ve.value<=Ne[0])||Z==="inverted"&&(ot?Ve.value<=Ne[0]||Ve.value>=Ne[Ne.length-1]:Ve.value>=Ne[0]),b.jsxs(H.Fragment,{children:[b.jsx(zt,{"data-index":Le,...Cr,...!gn(zt)&&{markActive:ut},style:{...rr,...Cr.style},className:Pt(Cr.className,ut&&Fe.markActive)}),Ve.label!=null?b.jsx(wr,{"aria-hidden":!0,"data-index":Le,...bt,...!gn(wr)&&{markLabelActive:ut},style:{...rr,...bt.style},className:Pt(Fe.markLabel,bt.className,ut&&Fe.markLabelActive),children:Ve.label}):null]},Le)}),Ne.map((Ve,Le)=>{const sa=En(Ve,N,F),rr=He[nt].offset(sa),ut=X==="off"?cC:Dt;return b.jsx(ut,{...!gn(ut)&&{valueLabelFormat:ce,valueLabelDisplay:X,value:typeof ce=="function"?ce(B(Ve),Le):ce,index:Le,open:er===Le||Bt===Le||X==="on",disabled:h},...na,children:b.jsx(Or,{"data-index":Le,...aa,className:Pt(Fe.thumb,aa.className,Bt===Le&&Fe.active,dt===Le&&Fe.focusVisible),style:{...rr,...yt(Le),...aa.style},children:b.jsx(W,{"data-index":Le,"aria-label":x?x(Le):o,"aria-valuenow":B(Ve),"aria-labelledby":i,"aria-valuetext":E?E(B(Ve),Le):s,value:Ne[Le],...oa})})},Le)})]})});process.env.NODE_ENV!=="production"&&(Cd.propTypes={"aria-label":Ks(S.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":S.string,"aria-valuetext":Ks(S.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:S.node,classes:S.object,className:S.string,color:S.oneOfType([S.oneOf(["primary","secondary","error","info","success","warning"]),S.string]),components:S.shape({Input:S.elementType,Mark:S.elementType,MarkLabel:S.elementType,Rail:S.elementType,Root:S.elementType,Thumb:S.elementType,Track:S.elementType,ValueLabel:S.elementType}),componentsProps:S.shape({input:S.oneOfType([S.func,S.object]),mark:S.oneOfType([S.func,S.object]),markLabel:S.oneOfType([S.func,S.object]),rail:S.oneOfType([S.func,S.object]),root:S.oneOfType([S.func,S.object]),thumb:S.oneOfType([S.func,S.object]),track:S.oneOfType([S.func,S.object]),valueLabel:S.oneOfType([S.func,S.shape({children:S.element,className:S.string,open:S.bool,style:S.object,value:S.node,valueLabelDisplay:S.oneOf(["auto","off","on"])})])}),defaultValue:S.oneOfType([S.arrayOf(S.number),S.number]),disabled:S.bool,disableSwap:S.bool,getAriaLabel:S.func,getAriaValueText:S.func,marks:S.oneOfType([S.arrayOf(S.shape({label:S.node,value:S.number.isRequired})),S.bool]),max:S.number,min:S.number,name:S.string,onChange:S.func,onChangeCommitted:S.func,orientation:S.oneOf(["horizontal","vertical"]),scale:S.func,shiftStep:S.number,size:S.oneOfType([S.oneOf(["small","medium"]),S.string]),slotProps:S.shape({input:S.oneOfType([S.func,S.object]),mark:S.oneOfType([S.func,S.object]),markLabel:S.oneOfType([S.func,S.object]),rail:S.oneOfType([S.func,S.object]),root:S.oneOfType([S.func,S.object]),thumb:S.oneOfType([S.func,S.object]),track:S.oneOfType([S.func,S.object]),valueLabel:S.oneOfType([S.func,S.shape({children:S.element,className:S.string,open:S.bool,style:S.object,value:S.node,valueLabelDisplay:S.oneOf(["auto","off","on"])})])}),slots:S.shape({input:S.elementType,mark:S.elementType,markLabel:S.elementType,rail:S.elementType,root:S.elementType,thumb:S.elementType,track:S.elementType,valueLabel:S.elementType}),step:S.number,sx:S.oneOfType([S.arrayOf(S.oneOfType([S.func,S.object,S.bool])),S.func,S.object]),tabIndex:S.number,track:S.oneOf(["inverted","normal",!1]),value:S.oneOfType([S.arrayOf(S.number),S.number]),valueLabelDisplay:S.oneOf(["auto","off","on"]),valueLabelFormat:S.oneOfType([S.func,S.string])});var dC="[object Number]";function uC(e){return typeof e=="number"||ur(e)&&gr(e)==dC}const Pd=je.observer(e=>{var o,s,i;const t=z.useTheme(),{store:r}=e,{t:a}=Te.useTranslation();function n(l,c){c===e.velocity||!uC(c)||e.onVelocityChange(c)}return b.jsxs(z.Stack,{direction:"row",gap:2,alignItems:"center",children:[r.showVelocityLegend&&b.jsx(z.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:a("Jogging.Velocity.bt")}),b.jsx(Cd,{value:e.velocity,color:"secondary",onChange:n,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):b.jsx(Rs,{value:e.velocity.toString()}))]})});function Rs({value:e,sx:t}){var a;const r=z.useTheme();return b.jsx(z.Stack,{direction:"row",justifyContent:"center",alignItems:"center",gap:"5px",sx:{padding:"6px 12px",background:(a=r.palette.backgroundPaperElevation)==null?void 0:a[8],borderRadius:"10px",minWidth:"111px",...t},children:b.jsx(z.Typography,{component:"span",sx:{textAlign:"right",fontSize:"14px",opacity:.8,color:r.palette.text.primary,whiteSpace:"nowrap"},children:e})})}const Vd=je.observer(({store:e})=>{const{t}=Te.useTranslation(),r=je.useLocalObservable(()=>({get valueLabelFormat(){return e.currentMotionType==="translate"?a=>`v = ${t("Jogging.Cartesian.Translation.velocityMmPerSec.lb",{amount:a})}`:a=>`ω = ${t("Jogging.Cartesian.Rotation.velocityDegPerSec.lb",{amount:a})}`}}));return b.jsx(Pd,{store:e,velocity:e.velocityInDisplayUnits,min:e.minVelocityInDisplayUnits,max:e.maxVelocityInDisplayUnits,onVelocityChange:e.setVelocityFromSlider,disabled:e.isLocked,renderValue:a=>b.jsx(Rs,{value:r.valueLabelFormat(a),sx:{minWidth:"111px",span:{transform:"translateY(-1.5px)"}}})})}),pC=je.observer(({store:e,children:t})=>{const{t:r}=Te.useTranslation(),a=z.useTheme();function n(p,m){(m==="translate"||m==="rotate")&&e.setSelectedCartesianMotionType(m)}cc(()=>[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(p,m){const g=await e.activate(),h=g.motionStream.rapidlyChangingMotionState.tcp_pose,x=g.motionStream.rapidlyChangingMotionState.state.joint_position;h&&await e.withMotionLock(async()=>{try{e.setCurrentIncrementJog({axis:p.axis,direction:p.direction}),await e.jogger.runIncrementalCartesianMotion({currentTcpPose:h,currentJoints:x,coordSystemId:e.activeCoordSystemId,velocityInRelevantUnits:e.selectedCartesianMotionType==="translate"?e.translationVelocityMmPerSec:e.rotationVelocityRadsPerSec,axis:p.axis,direction:p.direction,motion:e.selectedCartesianMotionType==="translate"?{type:"translate",distanceMm:m.mm}:{type:"rotate",distanceRads:ir.degreesToRadians(m.degrees)}})}finally{e.setCurrentIncrementJog(null),await e.deactivate()}})}async function s(p){if(!e.isLocked){if(await e.activate(),e.activeDiscreteIncrement)return o(p,e.activeDiscreteIncrement);p.motionType==="translate"?await e.jogger.startTCPTranslation({axis:p.axis,direction:p.direction,velocityMmPerSec:e.translationVelocityMmPerSec}):await e.jogger.startTCPRotation({axis:p.axis,direction:p.direction,velocityRadsPerSec:e.rotationVelocityRadsPerSec})}}async function i(){e.isLocked||e.activeDiscreteIncrement||await e.deactivate()}function l(p,m,g){var x,E,U;const h=(U=(E=(x=g.componentsExt)==null?void 0:x.JoggingPanel)==null?void 0:E.JoggingCartesian)==null?void 0:U.Axis;if(h)return m==="translate"?h[p]:h.CustomRotation??h[p]}const c=[{id:"x",icon:b.jsx(S1,{}),colors:l("X",e.selectedCartesianMotionType,a)},{id:"y",icon:b.jsx(x1,{}),colors:l("Y",e.selectedCartesianMotionType,a)},{id:"z",icon:b.jsx(w1,{}),colors:l("Z",e.selectedCartesianMotionType,a)}];function d(p){return r("General.mm.variable",{amount:p.toFixed(1)})}function u(p){return r("General.degree.variable",{amount:ir.radiansToDegrees(p).toFixed(1)})}return b.jsxs(z.Stack,{flexGrow:1,gap:2,sx:{padding:"18px 24px"},children:[b.jsxs(z.Stack,{gap:2,children:[b.jsx(Nw,{store:e}),b.jsx(Vd,{store:e}),b.jsx(z.Divider,{})]}),b.jsx(z.Stack,{marginLeft:"auto",marginRight:"auto",gap:"24px",justifyContent:"center",sx:{flexGrow:"1"},children:b.jsxs(z.Stack,{alignItems:"center",justifyContent:"center",gap:"24px",sx:{flexGrow:1},children:[b.jsxs(Dw,{value:e.selectedCartesianMotionType,onChange:n,exclusive:!0,"aria-label":r("Jogging.Cartesian.MotionType.lb"),sx:{justifyContent:"center"},children:[b.jsx(z.ToggleButton,{value:"translate",children:r("Jogging.Cartesian.Translation.bt")}),b.jsx(z.ToggleButton,{value:"rotate",children:r("Jogging.Cartesian.Rotation.bt")})]}),e.selectedCartesianMotionType==="translate"&&c.map(p=>{var m,g;return b.jsx(Do,{colors:p.colors,disabled:e.isLocked,activeJoggingDirection:((m=e.incrementJogInProgress)==null?void 0:m.axis)===p.id?e.incrementJogInProgress.direction:void 0,label:b.jsxs(b.Fragment,{children:[p.icon,b.jsx(z.Typography,{sx:{fontSize:"24px",color:((g=p.colors)==null?void 0:g.labelColor)??a.palette.text.primary},children:p.id.toUpperCase()})]}),getDisplayedValue:()=>{var h;return d(((h=e.jogger.motionStream.rapidlyChangingMotionState.tcp_pose)==null?void 0:h.position[p.id])||0)},startJogging:h=>s({axis:p.id,motionType:"translate",direction:h}),stopJogging:i},p.id)}),e.selectedCartesianMotionType==="rotate"&&c.map(p=>{var m,g;return b.jsx(Do,{colors:p.colors,disabled:e.isLocked,activeJoggingDirection:((m=e.incrementJogInProgress)==null?void 0:m.axis)===p.id?e.incrementJogInProgress.direction:void 0,label:b.jsxs(b.Fragment,{children:[b.jsx(P1,{}),b.jsx(z.Typography,{sx:{fontSize:"24px",color:((g=p.colors)==null?void 0:g.labelColor)??a.palette.text.primary},children:p.id.toUpperCase()})]}),getDisplayedValue:()=>{var h,x;return u(((x=(h=e.jogger.motionStream.rapidlyChangingMotionState.tcp_pose)==null?void 0:h.orientation)==null?void 0:x[p.id])||0)},startJogging:h=>s({axis:p.id,motionType:"rotate",direction:h}),stopJogging:i},p.id)})]})}),b.jsx(md,{store:e}),t&&b.jsx(z.Divider,{}),t]})}),hC=je.observer(({store:e,children:t})=>{const r=z.useTheme();async function a(o){await e.activate(),await e.jogger.startJointRotation({joint:o.joint,direction:o.direction,velocityRadsPerSec:e.rotationVelocityRadsPerSec})}async function n(){await e.jogger.stop(),await e.deactivate()}return b.jsxs(z.Stack,{flexGrow:1,gap:2,sx:{padding:"18px 24px"},children:[b.jsx(Vd,{store:e}),b.jsx(z.Divider,{}),b.jsx(z.Stack,{justifyContent:"center",alignItems:"stretch",sx:{flexGrow:"1"},id:"JointControls",children:b.jsx(z.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?ir.radiansToDegrees(s.lower_limit):void 0,l=(s==null?void 0:s.upper_limit)!==void 0?ir.radiansToDegrees(s.upper_limit):void 0;return b.jsxs(z.Stack,{direction:"row",alignItems:"center",justifyContent:"center",spacing:1.5,width:"100%",children:[e.showJointsLegend&&b.jsx(z.Typography,{color:e.isLocked?r.palette.text.disabled:r.palette.text.secondary,children:`G${o.index+1}`}),b.jsx(pc,{disabled:e.isLocked,lowerLimitDegs:i,upperLimitDegs:l,getValueDegs:()=>{const d=e.jogger.motionStream.rapidlyChangingMotionState.state.joint_position.joints[o.index];return d!==void 0?ir.radiansToDegrees(d):void 0},startJogging:d=>a({joint:o.index,direction:d}),stopJogging:n})]},`joint-${o.index}`)})})}),b.jsx(md,{store:e}),t&&b.jsx(z.Divider,{}),t]})}),mC=mr(je.observer(e=>{const t=ds.isString(e.nova)?new m1({instanceUrl:e.nova}):e.nova,r=je.useLocalObservable(()=>({joggingStore:null,loadingError:null}));async function a(){Be.runInAction(()=>{r.loadingError=null,r.joggingStore=null});try{let n=e.store;if(!n){const o=await t.connectJogger(e.motionGroupId);n=await io.loadFor(o)}Be.runInAction(()=>{r.joggingStore=n}),e.onSetup&&e.onSetup(n)}catch(n){r.loadingError=n}}return ae.useEffect(()=>(a(),e.store?()=>null:()=>{var n;(n=r.joggingStore)==null||n.dispose()}),[e.store,e.nova,e.motionGroupId]),ae.useEffect(()=>{const n=r.joggingStore;n&&(e.locked?n.lock("external"):n.unlock("external"))},[r.joggingStore,e.locked]),b.jsx(z.Stack,{sx:{maxWidth:"460px",minWidth:"320px",position:"relative",...e.sx},children:r.joggingStore?b.jsx(fC,{store:r.joggingStore,children:e.children}):b.jsx(xs,{message:"Loading jogging",error:r.loadingError})})})),fC=je.observer(({store:e,children:t})=>{const{t:r}=Te.useTranslation();function a(){if(e.currentTab.id==="cartesian")return b.jsx(b.Fragment,{children:b.jsx(pC,{store:e,children:t})});if(e.currentTab.id==="joint")return b.jsx(b.Fragment,{children:b.jsx(hC,{store:e,children:t})})}return b.jsxs(z.Stack,{flexGrow:1,sx:{overflow:"hidden"},children:[b.jsx(z.Tabs,{value:e.tabIndex,onChange:e.onTabChange,variant:"fullWidth",children:e.tabs.map(n=>{const o=n.label==="cartesian"?r("Jogging.Cartesian.bt"):r("Jogging.Joints.bt"),s=n.label==="cartesian"?b.jsx(Hm,{fontSize:"small",sx:{mr:1}}):b.jsx(qm,{fontSize:"small",sx:{mr:1}});return b.jsx(z.Tab,{label:e.showTabIcons?b.jsxs(z.Stack,{direction:"row",alignItems:"center",children:[s,o]}):o,id:`jogging-tab-${n.id}`,"aria-controls":`jogging-tab-${n.id}`},n.id)})}),b.jsx(z.Stack,{flexGrow:1,position:"relative",sx:{overflowY:"auto",overflowX:"hidden"},children:a()})]})}),Rd=ae.forwardRef(({label:e,value:t},r)=>{var i;const a=z.useTheme(),[n,o]=ae.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(),d=document.createRange();d.selectNodeContents(r.current),c.removeAllRanges(),c.addRange(d)}return!1}return ae.useEffect(()=>{if(!n)return;const l=setTimeout(()=>o(!1),3e3);return()=>{l&&clearTimeout(l)}},[n]),b.jsx(z.Tooltip,{open:n,title:"Copied!",children:b.jsx(z.Stack,{justifyContent:"center",sx:{height:"100%",boxSizing:"border-box",padding:"6px 12px",background:(i=a.palette.backgroundPaperElevation)==null?void 0:i[8],borderRadius:"10px",minWidth:"0",cursor:"pointer"},onClick:()=>s(),children:b.jsx(z.Typography,{ref:r,align:"center",sx:{pointerEvents:"none",fontSize:"12px",color:a.palette.text.primary,whiteSpace:"nowrap",minWidth:0,textOverflow:"ellipsis",width:"100%",overflow:"hidden"},children:t})})})}),gC=je.observer(({motionStream:e})=>{const t=ae.useRef(null);function r(){const a=e.rapidlyChangingMotionState.tcp_pose;return a?ir.poseToWandelscriptString(a):""}return Wr(()=>{if(!t.current)return;const a=r();t.current.textContent!==a&&(t.current.textContent=a)}),b.jsx(z.Stack,{alignItems:"left",spacing:2,sx:{flexGrow:1,minWidth:0,overflow:"hidden"},children:b.jsx(Rd,{value:r(),ref:t})})}),yC=je.observer(({motionStream:e})=>{const t=ae.useRef(null);function r(){const{joints:a}=e.rapidlyChangingMotionState.state.joint_position;return`[${a.map(n=>parseFloat(n.toFixed(4))).join(", ")}]`}return Wr(()=>{if(!t.current)return;const a=r();t.current.textContent!==a&&(t.current.textContent=a)}),b.jsx(z.Stack,{alignItems:"left",spacing:2,sx:{flexGrow:1,minWidth:0,overflow:"hidden"},children:b.jsx(Rd,{value:r(),ref:t})})});function bC(){const e=window.location.href;return e.substring(0,e.indexOf("/",e.indexOf("//")+2))}function SC({baseUrl:e=bC(),...t}){return b.jsxs(z.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:[b.jsx(z.DialogTitle,{id:"no-motion-group-modal-title",children:"No motion group found"}),b.jsxs(z.DialogContent,{sx:{marginTop:"3rem",marginBottom:"1.5rem",textAlign:"center"},children:[b.jsx(z.Typography,{color:"#fff",children:"Found no devices to connect to."}),b.jsx(z.Typography,{color:"#fff",children:"Please ensure a motion group has been created."})]}),b.jsx(z.DialogActions,{children:b.jsxs(z.Stack,{width:"100%",maxWidth:"300px",margin:"auto",marginBottom:"2rem",children:[b.jsx(z.Button,{href:`${e}/settings`,variant:"contained",sx:{borderRadius:"8px",width:"100%"},children:"Go to settings app"}),b.jsx(z.Button,{href:`${e}`,variant:"text",sx:{marginTop:"1rem",color:"#fff",textDecoration:"underline",fontSize:"0.75rem"},children:"Back to Homescreen"})]})})]})}const vC=mr(je.observer(({state:e,onRun:t,onPause:r,onStop:a,onReset:n,requiresManualReset:o=!1,variant:s="with_pause",className:i})=>{const l=z.useTheme(),{t:c}=Te.useTranslation(),d=()=>{const m={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:a}};return s==="without_pause"?[m.run,m.stop]:[m.run,m.pause,m.stop]},u=m=>{const g={sx:{fontSize:"55px"}};if(s==="without_pause")return m===0?b.jsx(la.PlayArrow,{...g}):b.jsx(la.Stop,{...g});switch(m){case 0:return b.jsx(la.PlayArrow,{...g});case 1:return b.jsx(la.Pause,{...g});case 2:return b.jsx(la.Stop,{...g});default:return null}},p=d();return b.jsx(z.Box,{className:i,sx:{display:"flex",flexDirection:"column",alignItems:"center",gap:2},children:b.jsx(z.Box,{sx:{display:"flex",gap:"40px",flexWrap:"wrap",justifyContent:"center",alignItems:"center"},children:p.map((m,g)=>b.jsxs(z.Box,{sx:{display:"flex",flexDirection:"column",alignItems:"center",gap:1},children:[b.jsx(z.Button,{variant:"contained",disabled:!m.enabled||e==="stopping"&&!o,onClick:m.onClick,sx:{width:"110px",height:"110px",borderRadius:"110px",backgroundColor:m.color,opacity:m.enabled&&!(e==="stopping"&&!o)?1:.3,"&:hover":{backgroundColor:m.color,opacity:m.enabled&&!(e==="stopping"&&!o)?.8:.3},"&:disabled":{backgroundColor:m.color,opacity:.3},minWidth:"110px",flexShrink:0},children:u(g)}),b.jsx(z.Typography,{variant:"body1",sx:{color:m.enabled&&!(e==="stopping"&&!o)?m.color:l.palette.text.disabled,textAlign:"center",opacity:m.enabled&&!(e==="stopping"&&!o)?1:.3},children:m.label})]},m.label))})})})),xC=Array(6).fill(2*Math.PI),jl="0.0.0-semantically-released";function _s(e){let t=jl;return jl.startsWith("0.")&&(t=""),`https://cdn.jsdelivr.net/gh/wandelbotsgmbh/wandelbots-js-react-components${t?`@${t}`:""}/public/models/${e}.glb`}function OC(e){function t(r){return r.children.length===0?[r]:[r,...r.children.flatMap(a=>t(a))]}return t(e).filter(r=>Ad(r))}function _d(e){return e.name.endsWith("_FLG")}function Ad(e){return/_J[0-9]+$/.test(e.name)}function wC(e,t){let r;function a(n){if(_d(n)){if(r)throw Error(`Found multiple flange groups in robot model ${t}; first ${r.name} then ${n.name}. Only one _FLG group is allowed.`);r=n}Ad(n),n.children.map(a)}if(a(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 Td({rapidlyChangingMotionState:e,dhParameters:t,onRotationChanged:r,children:a}){Lo.Globals.assign({frameLoop:"always"});const n=ae.useRef([]),o=ae.useRef([]),{invalidate:s}=Wd.useThree();function i(p){p&&(o.current=OC(p),c(),s())}function l(p){n.current=p,u.start(Object.assign({},n.current))}function c(){const p=o.current.map((m,g)=>d[g].get());if(r)r(o.current,p);else for(const[m,g]of o.current.entries()){const h=t[m],x=h.theta||0,E=h.reverse_rotation_direction?-1:1;g.rotation.y=E*p[m]+x}}lc(()=>{const p=e.state.joint_position.joints.filter(m=>m!==void 0);requestAnimationFrame(()=>l(p))});const[d,u]=Lo.useSpring(()=>({...Object.assign({},e.state.joint_position.joints),onChange:()=>{c(),s()},onResolve:()=>{c()}}));return b.jsx("group",{ref:i,children:a})}const $l="line",Ul="mesh";function CC({rapidlyChangingMotionState:e,dhParameters:t,...r}){const a=new ht.Matrix4;function n(i,l){const c=new ht.Vector3,d=new ht.Quaternion,u=new ht.Vector3;a.decompose(c,d,u);const p=c.clone(),m=new ht.Matrix4().makeRotationY(i.theta+l*(i.reverse_rotation_direction?-1:1)).multiply(new ht.Matrix4().makeTranslation(0,i.d/1e3,0)).multiply(new ht.Matrix4().makeTranslation(i.a/1e3,0,0)).multiply(new ht.Matrix4().makeRotationX(i.alpha));return a.multiply(m),a.decompose(c,d,u),{a:p,b:c}}function o(i,l,c,d){if(!t)return;const u=t[i];if(!u)return;const{a:p,b:m}=n(u,d);l.geometry.setPositions([p.toArray(),m.toArray()].flat()),c.position.set(m.x,m.y,m.z)}function s(i,l){a.identity(),i.forEach((c,d)=>{o(d,c.getObjectByName($l),c.getObjectByName(Ul),l[d])})}return b.jsx(b.Fragment,{children:b.jsx(Td,{rapidlyChangingMotionState:e,dhParameters:t,onRotationChanged:s,children:b.jsxs("group",{...r,name:"Scene",children:[b.jsxs("mesh",{children:[b.jsx("sphereGeometry",{args:[.01,32,32]}),b.jsx("meshStandardMaterial",{color:"black",depthTest:!0})]}),t.map((i,l)=>{const{a:c,b:d}=n(i,e.state.joint_position.joints[l]??0),u=`dhrobot_J0${l}`;return b.jsxs("group",{name:u,children:[b.jsx(mt.Line,{name:$l,points:[c,d],color:"white",lineWidth:5}),b.jsxs("mesh",{name:Ul,position:d,children:[b.jsx("sphereGeometry",{args:[.01,32,32]}),b.jsx("meshStandardMaterial",{color:"black",depthTest:!0})]},"mesh_"+l)]},u)})]})})})}const PC=console.warn;function VC(){return ae.useEffect(()=>{console.warn=e=>{e!=="Cannot call the manual advancement of rafz whilst frameLoop is not set as demand"&&PC(e)}},[]),b.jsx(b.Fragment,{})}function RC(e){return e.type==="Mesh"}function _C({modelURL:e,flangeRef:t,postModelRender:r,...a}){const{gltf:n}=wC(mt.useGLTF(e),e.split("/").pop()||e),o=ae.useCallback(i=>{i&&r&&r()},[e]);function s(i){return RC(i)?b.jsx("mesh",{name:i.name,geometry:i.geometry,material:i.material,position:i.position,rotation:i.rotation},i.uuid):b.jsx(Lo.animated.group,{name:i.name,position:i.position,rotation:i.rotation,ref:_d(i)?t:void 0,children:i.children.map(s)},i.uuid)}return b.jsx("group",{...a,dispose:null,ref:o,children:s(n.scene)})}const AC=(e,t)=>{e.userData.isGhost||(e.traverse(r=>{if(r instanceof Me.Mesh){r.material instanceof Me.Material&&(r.material.colorWrite=!1);const a=r.clone(),n=r.clone();a.material=new Me.MeshStandardMaterial({depthTest:!0,depthWrite:!0,colorWrite:!1,polygonOffset:!0,polygonOffsetFactor:-1,side:Me.DoubleSide}),a.userData.isGhost=!0,n.material=new Me.MeshStandardMaterial({color:t,opacity:.3,depthTest:!0,depthWrite:!1,transparent:!0,polygonOffset:!0,polygonOffsetFactor:-2,side:Me.DoubleSide}),n.userData.isGhost=!0,r.parent&&(r.parent.add(a),r.parent.add(n))}}),e.userData.isGhost=!0)},TC=e=>{if(!e.userData.isGhost)return;const t=[];e.traverse(r=>{var a;r instanceof Me.Mesh&&((a=r.userData)!=null&&a.isGhost?t.push(r):r.material instanceof Me.Material&&(r.material.colorWrite=!0))}),t.forEach(r=>{r.parent&&r.parent.remove(r)}),e.userData.isGhost=!1},Ed=mr(({rapidlyChangingMotionState:e,modelFromController:t,dhParameters:r,getModel:a=_s,flangeRef:n,postModelRender:o,transparentColor:s,...i})=>{const[l,c]=ae.useState(null),d=ae.useCallback(p=>{c(p)},[]);ae.useEffect(()=>{l&&(s?AC(l,s):TC(l))},[l,s]);const u=b.jsx(CC,{rapidlyChangingMotionState:e,dhParameters:r,...i});return b.jsxs(Zd.ErrorBoundary,{fallback:u,onError:p=>{console.error(p)},children:[b.jsx(ae.Suspense,{fallback:u,children:b.jsx("group",{ref:d,children:b.jsx(Td,{rapidlyChangingMotionState:e,dhParameters:r,children:b.jsx(_C,{modelURL:a(t),postModelRender:o,flangeRef:n,...i})})})}),b.jsx(VC,{})]})});function EC({connectedMotionGroup:e,getModel:t=_s,flangeRef:r,transparentColor:a,...n}){return e.dhParameters?b.jsx(Ed,{rapidlyChangingMotionState:e.rapidlyChangingMotionState,modelFromController:e.modelFromController||"",dhParameters:e.dhParameters,getModel:t,flangeRef:r,transparentColor:a,...n}):null}const IC=({title:e,titleId:t,...r},a)=>H.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.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"})),MC=ae.forwardRef(IC),jC=({title:e,titleId:t,...r},a)=>H.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.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"})),$C=ae.forwardRef(jC),wt=je.observer(({id:e,icon:t,color:r,title:a,name:n,label:o,explanation:s,literalValue:i,anchorOrigin:l,transformOrigin:c})=>{const d=je.useLocalObservable(()=>({anchorEl:null,get isPopoverOpen(){return!!d.anchorEl},openPopover(u){d.anchorEl=u.currentTarget},closePopover(){d.anchorEl=null}}));return b.jsxs(b.Fragment,{children:[b.jsxs(z.Stack,{"aria-owns":d.isPopoverOpen?e:void 0,"aria-haspopup":"true",onMouseEnter:d.openPopover,onMouseLeave:d.closePopover,direction:"row",spacing:1,sx:{cursor:"pointer"},children:[b.jsx(z.SvgIcon,{component:t,sx:{color:r}}),o&&b.jsx("div",{style:{color:r},children:o})]}),b.jsx(z.Popover,{id:e,sx:{pointerEvents:"none"},open:d.isPopoverOpen,anchorEl:d.anchorEl,anchorOrigin:l??{vertical:"bottom",horizontal:"left"},transformOrigin:c??{vertical:"top",horizontal:"left"},onClose:d.closePopover,disableRestoreFocus:!0,children:b.jsxs(z.Stack,{gap:"1rem",padding:2,maxWidth:"450px",sx:{wordWrap:"break-word"},children:[b.jsxs("div",{children:[a&&b.jsx(z.Typography,{component:"span",fontSize:"14px",children:`${a}: `}),b.jsx(z.Typography,{component:"span",color:r,fontWeight:"bold",fontSize:"14px",children:n})]}),b.jsx(z.Typography,{fontSize:"14px",children:s}),i&&b.jsx(z.Typography,{fontSize:"12px",children:i})]})})]})}),UC=je.observer(({isVirtual:e,motionGroupId:t,anchorOrigin:r,transformOrigin:a,compact:n})=>{const o=z.useTheme(),{t:s}=Te.useTranslation();return e?b.jsx(wt,{id:"motion-group-virtual",icon:$C,color:o.palette.tertiary.main,name:s("SafetyBar.ControllerType.Virtual.lb"),label:n?null:s("SafetyBar.ControllerType.Virtual.lb"),explanation:b.jsxs(Te.Trans,{i18nKey:"SafetyBar.MotionGroup.Virtual.Explanation.lb",values:{motionGroupId:t},children:["Motion group ",b.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:a}):b.jsx(wt,{id:"motion-group-physical",icon:MC,color:o.palette.primary.main,name:s("SafetyBar.ControllerType.Physical.lb"),label:n?null:s("SafetyBar.ControllerType.Physical.lb"),explanation:b.jsx(Te.Trans,{i18nKey:"SafetyBar.MotionGroup.Physical.Explanation.lb",values:{motionGroupId:t},components:{code:b.jsx("code",{}),strong:b.jsx("strong",{})}}),anchorOrigin:r,transformOrigin:a})}),LC=({title:e,titleId:t,...r},a)=>H.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.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"})),kC=ae.forwardRef(LC),BC=({title:e,titleId:t,...r},a)=>H.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.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})),FC=ae.forwardRef(BC),NC=({title:e,titleId:t,...r},a)=>H.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.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"})),DC=ae.forwardRef(NC),zC=je.observer(({operationMode:e,anchorOrigin:t,transformOrigin:r,compact:a})=>{const{t:n}=Te.useTranslation(),o=z.useTheme();switch(e){case"OPERATION_MODE_AUTO":return b.jsx(wt,{id:"operation-mode-auto",icon:kC,title:n("SafetyBar.OperationMode.ti"),name:n("SafetyBar.OperationMode.Automatic.ti"),label:a?null:n("SafetyBar.OperationMode.Automatic.ti"),color:o.palette.text.secondary,explanation:b.jsx(Te.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 b.jsx(wt,{id:"operation-mode-manual",icon:DC,color:o.palette.warning.main,title:n("SafetyBar.OperationMode.ti"),name:n("SafetyBar.OperationMode.Manual.lb"),label:a?null:n("SafetyBar.OperationMode.Manual.lb"),explanation:b.jsx(Te.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 b.jsx(wt,{id:"operation-mode-error",icon:FC,color:o.palette.warning.main,title:n("SafetyBar.OperationMode.ti"),name:n("SafetyBar.OperationMode.Error.lb"),label:a?null:n("SafetyBar.OperationMode.Error.lb"),explanation:b.jsx(Te.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})}}),GC=({title:e,titleId:t,...r},a)=>H.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.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"})),JC=ae.forwardRef(GC),HC=({title:e,titleId:t,...r},a)=>H.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.createElement("path",{d:"M10.24 10.636 12 13.764l1.76-3.128h-3.52Z"}),H.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"}),H.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"})),qC=ae.forwardRef(HC),WC=({title:e,titleId:t,...r},a)=>H.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.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})),KC=ae.forwardRef(WC),QC=({title:e,titleId:t,...r},a)=>H.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.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"})),YC=ae.forwardRef(QC),XC=({title:e,titleId:t,...r},a)=>H.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:a,"aria-labelledby":t,...r},e?H.createElement("title",{id:t},e):null,H.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"})),ZC=ae.forwardRef(XC),eP=je.observer(({safetyState:e,anchorOrigin:t,transformOrigin:r,compact:a})=>{const{t:n}=Te.useTranslation(),o=z.useTheme();switch(e){case"SAFETY_STATE_NORMAL":return b.jsx(wt,{id:"safety-state-normal",title:n("SafetyBar.SafetyState.ti"),name:n("SafetyBar.SafetyState.Normal.lb"),label:a?null:n("SafetyBar.SafetyState.Normal.lb"),icon:YC,color:o.palette.text.secondary,explanation:b.jsx(Te.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 b.jsx(wt,{id:"safety-state-estop",title:n("SafetyBar.SafetyState.ti"),name:n("SafetyBar.SafetyState.Estop.lb"),label:a?null:n("SafetyBar.SafetyState.Estop.lb"),icon:qC,color:o.palette.error.main,explanation:b.jsx(Te.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 b.jsx(wt,{id:"safety-state-stop",icon:ZC,title:n("SafetyBar.SafetyState.ti"),name:n("SafetyBar.SafetyState.Stop.lb"),label:a?null:n("SafetyBar.SafetyState.Stop.lb"),color:o.palette.warning.main,explanation:b.jsx(Te.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 b.jsx(wt,{id:"safety-state-manual-action-required",icon:KC,color:o.palette.warning.main,title:n("SafetyBar.SafetyState.ti"),name:n("SafetyBar.SafetyState.ManualActionRequired.lb"),label:a?null:n("SafetyBar.SafetyState.ManualActionRequired.lb"),explanation:b.jsx(Te.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 b.jsx(wt,{id:"safety-state-error",icon:JC,color:o.palette.error.main,title:n("SafetyBar.SafetyState.ti"),name:n("SafetyBar.SafetyState.Error.lb"),label:a?null:n("SafetyBar.SafetyState.Error.lb"),explanation:b.jsx(Te.Trans,{i18nKey:"SafetyBar.SafetyState.Error.Explanation.lb",children:"The robot controller has entered an unexpected safety state."}),literalValue:e,anchorOrigin:t,transformOrigin:r});default:g1(e,`Unknown safety state ${e}`)}}),tP=mr(je.observer(({isVirtual:e,motionGroupId:t,operationMode:r,safetyState:a,anchorOrigin:n,transformOrigin:o,compact:s=!0})=>{const i=s?1:2;return b.jsxs(z.Stack,{direction:"row",gap:i,alignItems:"center",sx:{height:"24px"},children:[b.jsx(eP,{safetyState:a,anchorOrigin:n,transformOrigin:o,compact:s}),b.jsx(z.Divider,{orientation:"vertical",flexItem:!0}),b.jsx(zC,{operationMode:r,anchorOrigin:n,transformOrigin:o,compact:s}),b.jsx(z.Divider,{orientation:"vertical",flexItem:!0}),b.jsx(UC,{isVirtual:e,motionGroupId:t,anchorOrigin:n,transformOrigin:o,compact:s})]})})),rP=z.styled(z.Fab,{shouldForwardProp:e=>e!=="selected"})(({theme:e})=>{var t,r,a;return{borderRadius:"20px","&:hover":{background:(t=e.palette.backgroundPaperElevation)==null?void 0:t[7]},variants:[{props:({selected:n})=>!n,style:{background:(r=e.palette.backgroundPaperElevation)==null?void 0:r[0],color:e.palette.action.disabled,"> img":{opacity:.4}}},{props:({selected:n})=>n,style:{background:(a=e.palette.backgroundPaperElevation)==null?void 0:a[11],border:`1px solid ${e.palette.divider}`,color:e.palette.primary.contrastText}}]}}),aP=ae.forwardRef((e,t)=>b.jsx(rP,{ref:t,selected:e.selected,...e,color:"secondary",variant:"circular"})),nP={$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"},oP=ae.lazy(()=>import("@monaco-editor/react"));let Uo=null;async function sP(){if(!Uo){const[{createHighlighter:e},{shikiToMonaco:t}]=await Promise.all([import("shiki"),import("@shikijs/monaco")]);Uo={shiki:await e({langs:[nP],themes:["dark-plus","light-plus"]}),shikiToMonaco:t}}return Uo}const iP=mr(e=>{const t=z.useTheme(),[r,a]=ae.useState("dark-plus"),n=t.palette.mode==="dark"?"dark-plus":"light-plus";async function o(s){var c,d;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 sP();l(i,s),s.editor.defineTheme(n,((d=(c=t.componentsExt)==null?void 0:c.WandelscriptEditor)==null?void 0:d.monacoTheme)??{base:t.palette.mode==="dark"?"vs-dark":"vs",inherit:!0,rules:[],colors:{}}),e.monacoSetup&&e.monacoSetup(s),a(n)}return b.jsx(ae.Suspense,{fallback:b.jsx(xs,{}),children:b.jsx(oP,{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 Id(){var t,r,a,n,o,s,i;const e=z.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:(a=(r=(t=e.paletteExt)==null?void 0:t.secondary)==null?void 0:r.tonal)==null?void 0:a.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:(n=e.palette.backgroundPaperElevation)==null?void 0:n[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":z.rgbToHex(((i=e.palette.backgroundPaperElevation)==null?void 0:i[5])??""),"editor.foreground":"#d4d4d4","editorLineNumber.foreground":"#797979","editorLineNumber.activeForeground":"#e9e9e9","editor.lineHighlightBorder":"#e9e9e911"}}}}}}function lP(){const e=Id();return e.palette.mode="light",e}function cP(e){var a,n,o,s;let t=!0;((a=e.palette)==null?void 0:a.mode)==="light"?t=!1:((n=e.palette)==null?void 0:n.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?Id():lP();return oc(r,e)}exports.JoggingCartesianAxisControl=Do;exports.JoggingJointRotationControl=pc;exports.JoggingPanel=mC;exports.JoggingStore=io;exports.LoadingCover=xs;exports.LoadingErrorMessage=ad;exports.NoMotionGroupModal=SC;exports.PoseCartesianValues=gC;exports.PoseJointValues=yC;exports.PresetEnvironment=au;exports.ProgramControl=vC;exports.Robot=EC;exports.SafetyBar=tP;exports.SafetyZonesRenderer=su;exports.SelectableFab=aP;exports.SupportedRobot=Ed;exports.TrajectoryRenderer=iu;exports.VelocitySlider=Pd;exports.VelocitySliderLabel=Rs;exports.WandelscriptEditor=iP;exports.createNovaMuiTheme=cP;exports.defaultAxisConfig=xC;exports.defaultGetModel=_s;exports.i18n=ys;exports.useAnimationFrame=Wr;exports.useAutorun=lc;exports.useMounted=Jn;exports.useReaction=cc;
|
|
154
|
+
*/var xE=function(){if(typeof WebSocket<"u")return WebSocket},SE=function(e){return typeof e<"u"&&!!e&&e.CLOSING===2},$r={maxReconnectionDelay:1e4,minReconnectionDelay:1e3+Math.random()*4e3,minUptime:5e3,reconnectionDelayGrowFactor:1.3,connectionTimeout:4e3,maxRetries:1/0,maxEnqueuedMessages:1/0},OE=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(s){a._debug("open event");var o=a._options.minUptime,i=o===void 0?$r.minUptime:o;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(s),a._listeners.open.forEach(function(l){return a._callEventListener(s,l)})},this._handleMessage=function(s){a._debug("message event"),a.onmessage&&a.onmessage(s),a._listeners.message.forEach(function(o){return a._callEventListener(s,o)})},this._handleError=function(s){a._debug("error event",s.message),a._disconnect(void 0,s.message==="TIMEOUT"?"timeout":void 0),a.onerror&&a.onerror(s),a._debug("exec error listeners"),a._listeners.error.forEach(function(o){return a._callEventListener(s,o)}),a._connect()},this._handleClose=function(s){a._debug("close event"),a._clearTimeouts(),a._shouldReconnect&&a._connect(),a.onclose&&a.onclose(s),a._listeners.close.forEach(function(o){return a._callEventListener(s,o)})},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?$r.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 s=mE(a),o=s.next();!o.done;o=s.next()){var i=o.value;this._callEventListener(t,i)}}catch(l){r={error:l}}finally{try{o&&!o.done&&(n=s.return)&&n.call(s)}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,yE(["RWS>"],t))},e.prototype._getNextDelay=function(){var t=this._options,r=t.reconnectionDelayGrowFactor,n=r===void 0?$r.reconnectionDelayGrowFactor:r,a=t.minReconnectionDelay,s=a===void 0?$r.minReconnectionDelay:a,o=t.maxReconnectionDelay,i=o===void 0?$r.maxReconnectionDelay:o,l=0;return this._retryCount>0&&(l=s*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?$r.maxRetries:n,s=r.connectionTimeout,o=s===void 0?$r.connectionTimeout:s,i=r.WebSocket,l=i===void 0?xE():i;if(this._retryCount>=a){this._debug("max retries reached",this._retryCount,">=",a);return}if(this._retryCount++,this._debug("connect",this._retryCount),this._removeListeners(),!SE(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()},o))})}},e.prototype._handleTimeout=function(){this._debug("timeout event"),this._handleError(new bE(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 vE(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}(),wE=Object.defineProperty,CE=Object.defineProperties,PE=Object.getOwnPropertyDescriptors,_h=Object.getOwnPropertySymbols,RE=Object.prototype.hasOwnProperty,TE=Object.prototype.propertyIsEnumerable,Ih=(e,t,r)=>t in e?wE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,In=(e,t)=>{for(var r in t||(t={}))RE.call(t,r)&&Ih(e,r,t[r]);if(_h)for(var r of _h(t))TE.call(t,r)&&Ih(e,r,t[r]);return e},Nl=(e,t)=>CE(e,PE(t)),$e=(e,t,r)=>new Promise((n,a)=>{var s=l=>{try{i(r.next(l))}catch(c){a(c)}},o=l=>{try{i(r.throw(l))}catch(c){a(c)}},i=l=>l.done?n(l.value):Promise.resolve(l.value).then(s,o);i((r=r.apply(e,t)).next())}),AE=class extends OE{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 $e(this,null,function*(){return new Promise((e,t)=>{this.readyState===WebSocket.OPEN?e():(this.addEventListener("open",()=>e()),this.addEventListener("error",t))})})}closed(){return $e(this,null,function*(){return new Promise((e,t)=>{this.readyState===WebSocket.CLOSED?e():(this.addEventListener("close",()=>e()),this.addEventListener("error",t))})})}firstMessage(){return $e(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 $e(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)})})}},VE=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}},nl=new VE;function wr(e){try{return JSON.parse(e)}catch{return}}function EE(e,t){return e||(e="world"),t||(t="world"),e===t}var kn="wandelbots.io",al={dev:{domain:`https://auth.portal.dev.${kn}`,clientId:"fLbJD0RLp5r2Dpucm5j8BjwMR6Hunfha"},stg:{domain:`https://auth.portal.stg.${kn}`,clientId:"joVDeD9e786WzFNSGCqoVq7HNkWt5j6s"},prod:{domain:`https://auth.portal.${kn}`,clientId:"J7WJUi38xVQdJAEBNRT9Xw1b0fXDb4J2"}},_E=e=>{if(e.includes(`dev.${kn}`))return al.dev;if(e.includes(`stg.${kn}`))return al.stg;if(e.includes(kn))return al.prod;throw new Error("Unsupported instance URL. Cannot determine Auth0 configuration.")},IE=e=>$e(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=_E(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:o}=yield a.handleRedirectCallback();window.history.replaceState({},document.title,(o==null?void 0:o.returnTo)||window.location.pathname)}else yield a.loginWithRedirect();return yield a.getTokenSilently()});function Bm(e,t){return function(){return e.apply(t,arguments)}}const{toString:ME}=Object.prototype,{getPrototypeOf:qc}=Object,ui=(e=>t=>{const r=ME.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),Bt=e=>(e=e.toLowerCase(),t=>ui(t)===e),di=e=>t=>typeof t===e,{isArray:ra}=Array,Ya=di("undefined");function $E(e){return e!==null&&!Ya(e)&&e.constructor!==null&&!Ya(e.constructor)&&Ct(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const zm=Bt("ArrayBuffer");function jE(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&zm(e.buffer),t}const kE=di("string"),Ct=di("function"),Gm=di("number"),hi=e=>e!==null&&typeof e=="object",LE=e=>e===!0||e===!1,qs=e=>{if(ui(e)!=="object")return!1;const t=qc(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},UE=Bt("Date"),DE=Bt("File"),NE=Bt("Blob"),FE=Bt("FileList"),BE=e=>hi(e)&&Ct(e.pipe),zE=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||Ct(e.append)&&((t=ui(e))==="formdata"||t==="object"&&Ct(e.toString)&&e.toString()==="[object FormData]"))},GE=Bt("URLSearchParams"),[HE,qE,JE,WE]=["ReadableStream","Request","Response","Headers"].map(Bt),KE=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function cs(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let n,a;if(typeof e!="object"&&(e=[e]),ra(e))for(n=0,a=e.length;n<a;n++)t.call(null,e[n],n,e);else{const s=r?Object.getOwnPropertyNames(e):Object.keys(e),o=s.length;let i;for(n=0;n<o;n++)i=s[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 Dr=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,qm=e=>!Ya(e)&&e!==Dr;function Fl(){const{caseless:e}=qm(this)&&this||{},t={},r=(n,a)=>{const s=e&&Hm(t,a)||a;qs(t[s])&&qs(n)?t[s]=Fl(t[s],n):qs(n)?t[s]=Fl({},n):ra(n)?t[s]=n.slice():t[s]=n};for(let n=0,a=arguments.length;n<a;n++)arguments[n]&&cs(arguments[n],r);return t}const YE=(e,t,r,{allOwnKeys:n}={})=>(cs(t,(a,s)=>{r&&Ct(a)?e[s]=Bm(a,r):e[s]=a},{allOwnKeys:n}),e),QE=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),XE=(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)},ZE=(e,t,r,n)=>{let a,s,o;const i={};if(t=t||{},e==null)return t;do{for(a=Object.getOwnPropertyNames(e),s=a.length;s-- >0;)o=a[s],(!n||n(o,e,t))&&!i[o]&&(t[o]=e[o],i[o]=!0);e=r!==!1&&qc(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},e_=(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},t_=e=>{if(!e)return null;if(ra(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},r_=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&qc(Uint8Array)),n_=(e,t)=>{const n=(e&&e[Symbol.iterator]).call(e);let a;for(;(a=n.next())&&!a.done;){const s=a.value;t.call(e,s[0],s[1])}},a_=(e,t)=>{let r;const n=[];for(;(r=e.exec(t))!==null;)n.push(r);return n},s_=Bt("HTMLFormElement"),o_=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,a){return n.toUpperCase()+a}),Mh=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),i_=Bt("RegExp"),Jm=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),n={};cs(r,(a,s)=>{let o;(o=t(a,s,e))!==!1&&(n[s]=o||a)}),Object.defineProperties(e,n)},l_=e=>{Jm(e,(t,r)=>{if(Ct(e)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const n=e[r];if(Ct(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+"'")})}})},c_=(e,t)=>{const r={},n=a=>{a.forEach(s=>{r[s]=!0})};return ra(e)?n(e):n(String(e).split(t)),r},u_=()=>{},d_=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function h_(e){return!!(e&&Ct(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const p_=e=>{const t=new Array(10),r=(n,a)=>{if(hi(n)){if(t.indexOf(n)>=0)return;if(!("toJSON"in n)){t[a]=n;const s=ra(n)?[]:{};return cs(n,(o,i)=>{const l=r(o,a+1);!Ya(l)&&(s[i]=l)}),t[a]=void 0,s}}return n};return r(e,0)},f_=Bt("AsyncFunction"),m_=e=>e&&(hi(e)||Ct(e))&&Ct(e.then)&&Ct(e.catch),Wm=((e,t)=>e?setImmediate:t?((r,n)=>(Dr.addEventListener("message",({source:a,data:s})=>{a===Dr&&s===r&&n.length&&n.shift()()},!1),a=>{n.push(a),Dr.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",Ct(Dr.postMessage)),g_=typeof queueMicrotask<"u"?queueMicrotask.bind(Dr):typeof process<"u"&&process.nextTick||Wm,H={isArray:ra,isArrayBuffer:zm,isBuffer:$E,isFormData:zE,isArrayBufferView:jE,isString:kE,isNumber:Gm,isBoolean:LE,isObject:hi,isPlainObject:qs,isReadableStream:HE,isRequest:qE,isResponse:JE,isHeaders:WE,isUndefined:Ya,isDate:UE,isFile:DE,isBlob:NE,isRegExp:i_,isFunction:Ct,isStream:BE,isURLSearchParams:GE,isTypedArray:r_,isFileList:FE,forEach:cs,merge:Fl,extend:YE,trim:KE,stripBOM:QE,inherits:XE,toFlatObject:ZE,kindOf:ui,kindOfTest:Bt,endsWith:e_,toArray:t_,forEachEntry:n_,matchAll:a_,isHTMLForm:s_,hasOwnProperty:Mh,hasOwnProp:Mh,reduceDescriptors:Jm,freezeMethods:l_,toObjectSet:c_,toCamelCase:o_,noop:u_,toFiniteNumber:d_,findKey:Hm,global:Dr,isContextDefined:qm,isSpecCompliantForm:h_,toJSONObject:p_,isAsyncFn:f_,isThenable:m_,setImmediate:Wm,asap:g_};function me(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)}H.inherits(me,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:H.toJSONObject(this.config),code:this.code,status:this.status}}});const Km=me.prototype,Ym={};["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=>{Ym[e]={value:e}});Object.defineProperties(me,Ym);Object.defineProperty(Km,"isAxiosError",{value:!0});me.from=(e,t,r,n,a,s)=>{const o=Object.create(Km);return H.toFlatObject(e,o,function(l){return l!==Error.prototype},i=>i!=="isAxiosError"),me.call(o,e.message,t,r,n,a),o.cause=e,o.name=e.name,s&&Object.assign(o,s),o};const y_=null;function Bl(e){return H.isPlainObject(e)||H.isArray(e)}function Qm(e){return H.endsWith(e,"[]")?e.slice(0,-2):e}function $h(e,t,r){return e?e.concat(t).map(function(a,s){return a=Qm(a),!r&&s?"["+a+"]":a}).join(r?".":""):t}function b_(e){return H.isArray(e)&&!e.some(Bl)}const v_=H.toFlatObject(H,{},null,function(t){return/^is[A-Z]/.test(t)});function pi(e,t,r){if(!H.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,r=H.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(f,g){return!H.isUndefined(g[f])});const n=r.metaTokens,a=r.visitor||u,s=r.dots,o=r.indexes,l=(r.Blob||typeof Blob<"u"&&Blob)&&H.isSpecCompliantForm(t);if(!H.isFunction(a))throw new TypeError("visitor must be a function");function c(m){if(m===null)return"";if(H.isDate(m))return m.toISOString();if(!l&&H.isBlob(m))throw new me("Blob is not supported. Use a Buffer instead.");return H.isArrayBuffer(m)||H.isTypedArray(m)?l&&typeof Blob=="function"?new Blob([m]):Buffer.from(m):m}function u(m,f,g){let S=m;if(m&&!g&&typeof m=="object"){if(H.endsWith(f,"{}"))f=n?f:f.slice(0,-2),m=JSON.stringify(m);else if(H.isArray(m)&&b_(m)||(H.isFileList(m)||H.endsWith(f,"[]"))&&(S=H.toArray(m)))return f=Qm(f),S.forEach(function(O,C){!(H.isUndefined(O)||O===null)&&t.append(o===!0?$h([f],C,s):o===null?f:f+"[]",c(O))}),!1}return Bl(m)?!0:(t.append($h(g,f,s),c(m)),!1)}const d=[],h=Object.assign(v_,{defaultVisitor:u,convertValue:c,isVisitable:Bl});function p(m,f){if(!H.isUndefined(m)){if(d.indexOf(m)!==-1)throw Error("Circular reference detected in "+f.join("."));d.push(m),H.forEach(m,function(S,T){(!(H.isUndefined(S)||S===null)&&a.call(t,S,H.isString(T)?T.trim():T,f,h))===!0&&p(S,f?f.concat(T):[T])}),d.pop()}}if(!H.isObject(e))throw new TypeError("data must be an object");return p(e),t}function jh(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(n){return t[n]})}function Jc(e,t){this._pairs=[],e&&pi(e,this,t)}const Xm=Jc.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,jh)}:jh;return this._pairs.map(function(a){return r(a[0])+"="+r(a[1])},"").join("&")};function x_(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||x_;H.isFunction(r)&&(r={serialize:r});const a=r&&r.serialize;let s;if(a?s=a(t,r):s=H.isURLSearchParams(t)?t.toString():new Jc(t,r).toString(n),s){const o=e.indexOf("#");o!==-1&&(e=e.slice(0,o)),e+=(e.indexOf("?")===-1?"?":"&")+s}return e}class kh{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){H.forEach(this.handlers,function(n){n!==null&&t(n)})}}const eg={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},S_=typeof URLSearchParams<"u"?URLSearchParams:Jc,O_=typeof FormData<"u"?FormData:null,w_=typeof Blob<"u"?Blob:null,C_={isBrowser:!0,classes:{URLSearchParams:S_,FormData:O_,Blob:w_},protocols:["http","https","file","blob","url","data"]},Wc=typeof window<"u"&&typeof document<"u",zl=typeof navigator=="object"&&navigator||void 0,P_=Wc&&(!zl||["ReactNative","NativeScript","NS"].indexOf(zl.product)<0),R_=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",T_=Wc&&window.location.href||"http://localhost",A_=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Wc,hasStandardBrowserEnv:P_,hasStandardBrowserWebWorkerEnv:R_,navigator:zl,origin:T_},Symbol.toStringTag,{value:"Module"})),it={...A_,...C_};function V_(e,t){return pi(e,new it.classes.URLSearchParams,Object.assign({visitor:function(r,n,a,s){return it.isNode&&H.isBuffer(r)?(this.append(n,r.toString("base64")),!1):s.defaultVisitor.apply(this,arguments)}},t))}function E_(e){return H.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function __(e){const t={},r=Object.keys(e);let n;const a=r.length;let s;for(n=0;n<a;n++)s=r[n],t[s]=e[s];return t}function tg(e){function t(r,n,a,s){let o=r[s++];if(o==="__proto__")return!0;const i=Number.isFinite(+o),l=s>=r.length;return o=!o&&H.isArray(a)?a.length:o,l?(H.hasOwnProp(a,o)?a[o]=[a[o],n]:a[o]=n,!i):((!a[o]||!H.isObject(a[o]))&&(a[o]=[]),t(r,n,a[o],s)&&H.isArray(a[o])&&(a[o]=__(a[o])),!i)}if(H.isFormData(e)&&H.isFunction(e.entries)){const r={};return H.forEachEntry(e,(n,a)=>{t(E_(n),a,r,0)}),r}return null}function I_(e,t,r){if(H.isString(e))try{return(t||JSON.parse)(e),H.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(e)}const us={transitional:eg,adapter:["xhr","http","fetch"],transformRequest:[function(t,r){const n=r.getContentType()||"",a=n.indexOf("application/json")>-1,s=H.isObject(t);if(s&&H.isHTMLForm(t)&&(t=new FormData(t)),H.isFormData(t))return a?JSON.stringify(tg(t)):t;if(H.isArrayBuffer(t)||H.isBuffer(t)||H.isStream(t)||H.isFile(t)||H.isBlob(t)||H.isReadableStream(t))return t;if(H.isArrayBufferView(t))return t.buffer;if(H.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let i;if(s){if(n.indexOf("application/x-www-form-urlencoded")>-1)return V_(t,this.formSerializer).toString();if((i=H.isFileList(t))||n.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return pi(i?{"files[]":t}:t,l&&new l,this.formSerializer)}}return s||a?(r.setContentType("application/json",!1),I_(t)):t}],transformResponse:[function(t){const r=this.transitional||us.transitional,n=r&&r.forcedJSONParsing,a=this.responseType==="json";if(H.isResponse(t)||H.isReadableStream(t))return t;if(t&&H.isString(t)&&(n&&!this.responseType||a)){const o=!(r&&r.silentJSONParsing)&&a;try{return JSON.parse(t)}catch(i){if(o)throw i.name==="SyntaxError"?me.from(i,me.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:it.classes.FormData,Blob:it.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};H.forEach(["delete","get","head","post","put","patch"],e=>{us.headers[e]={}});const M_=H.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"]),$_=e=>{const t={};let r,n,a;return e&&e.split(`
|
|
155
|
+
`).forEach(function(o){a=o.indexOf(":"),r=o.substring(0,a).trim().toLowerCase(),n=o.substring(a+1).trim(),!(!r||t[r]&&M_[r])&&(r==="set-cookie"?t[r]?t[r].push(n):t[r]=[n]:t[r]=t[r]?t[r]+", "+n:n)}),t},Lh=Symbol("internals");function xa(e){return e&&String(e).trim().toLowerCase()}function Js(e){return e===!1||e==null?e:H.isArray(e)?e.map(Js):String(e)}function j_(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 k_=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function sl(e,t,r,n,a){if(H.isFunction(n))return n.call(this,t,r);if(a&&(t=r),!!H.isString(t)){if(H.isString(n))return t.indexOf(n)!==-1;if(H.isRegExp(n))return n.test(t)}}function L_(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,r,n)=>r.toUpperCase()+n)}function U_(e,t){const r=H.toCamelCase(" "+t);["get","set","has"].forEach(n=>{Object.defineProperty(e,n+r,{value:function(a,s,o){return this[n].call(this,t,a,s,o)},configurable:!0})})}let xt=class{constructor(t){t&&this.set(t)}set(t,r,n){const a=this;function s(i,l,c){const u=xa(l);if(!u)throw new Error("header name must be a non-empty string");const d=H.findKey(a,u);(!d||a[d]===void 0||c===!0||c===void 0&&a[d]!==!1)&&(a[d||l]=Js(i))}const o=(i,l)=>H.forEach(i,(c,u)=>s(c,u,l));if(H.isPlainObject(t)||t instanceof this.constructor)o(t,r);else if(H.isString(t)&&(t=t.trim())&&!k_(t))o($_(t),r);else if(H.isHeaders(t))for(const[i,l]of t.entries())s(l,i,n);else t!=null&&s(r,t,n);return this}get(t,r){if(t=xa(t),t){const n=H.findKey(this,t);if(n){const a=this[n];if(!r)return a;if(r===!0)return j_(a);if(H.isFunction(r))return r.call(this,a,n);if(H.isRegExp(r))return r.exec(a);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,r){if(t=xa(t),t){const n=H.findKey(this,t);return!!(n&&this[n]!==void 0&&(!r||sl(this,this[n],n,r)))}return!1}delete(t,r){const n=this;let a=!1;function s(o){if(o=xa(o),o){const i=H.findKey(n,o);i&&(!r||sl(n,n[i],i,r))&&(delete n[i],a=!0)}}return H.isArray(t)?t.forEach(s):s(t),a}clear(t){const r=Object.keys(this);let n=r.length,a=!1;for(;n--;){const s=r[n];(!t||sl(this,this[s],s,t,!0))&&(delete this[s],a=!0)}return a}normalize(t){const r=this,n={};return H.forEach(this,(a,s)=>{const o=H.findKey(n,s);if(o){r[o]=Js(a),delete r[s];return}const i=t?L_(s):String(s).trim();i!==s&&delete r[s],r[i]=Js(a),n[i]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const r=Object.create(null);return H.forEach(this,(n,a)=>{n!=null&&n!==!1&&(r[a]=t&&H.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(`
|
|
156
|
+
`)}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[Lh]=this[Lh]={accessors:{}}).accessors,a=this.prototype;function s(o){const i=xa(o);n[i]||(U_(a,o),n[i]=!0)}return H.isArray(t)?t.forEach(s):s(t),this}};xt.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);H.reduceDescriptors(xt.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(n){this[r]=n}}});H.freezeMethods(xt);function ol(e,t){const r=this||us,n=t||r,a=xt.from(n.headers);let s=n.data;return H.forEach(e,function(i){s=i.call(r,s,a.normalize(),t?t.status:void 0)}),a.normalize(),s}function rg(e){return!!(e&&e.__CANCEL__)}function na(e,t,r){me.call(this,e??"canceled",me.ERR_CANCELED,t,r),this.name="CanceledError"}H.inherits(na,me,{__CANCEL__:!0});function ng(e,t,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?e(r):t(new me("Request failed with status code "+r.status,[me.ERR_BAD_REQUEST,me.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 N_(e,t){e=e||10;const r=new Array(e),n=new Array(e);let a=0,s=0,o;return t=t!==void 0?t:1e3,function(l){const c=Date.now(),u=n[s];o||(o=c),r[a]=l,n[a]=c;let d=s,h=0;for(;d!==a;)h+=r[d++],d=d%e;if(a=(a+1)%e,a===s&&(s=(s+1)%e),c-o<t)return;const p=u&&c-u;return p?Math.round(h*1e3/p):void 0}}function F_(e,t){let r=0,n=1e3/t,a,s;const o=(c,u=Date.now())=>{r=u,a=null,s&&(clearTimeout(s),s=null),e.apply(null,c)};return[(...c)=>{const u=Date.now(),d=u-r;d>=n?o(c,u):(a=c,s||(s=setTimeout(()=>{s=null,o(a)},n-d)))},()=>a&&o(a)]}const Co=(e,t,r=3)=>{let n=0;const a=N_(50,250);return F_(s=>{const o=s.loaded,i=s.lengthComputable?s.total:void 0,l=o-n,c=a(l),u=o<=i;n=o;const d={loaded:o,total:i,progress:i?o/i:void 0,bytes:l,rate:c||void 0,estimated:c&&i&&u?(i-o)/c:void 0,event:s,lengthComputable:i!=null,[t?"download":"upload"]:!0};e(d)},r)},Uh=(e,t)=>{const r=e!=null;return[n=>t[0]({lengthComputable:r,total:e,loaded:n}),t[1]]},Dh=e=>(...t)=>H.asap(()=>e(...t)),B_=it.hasStandardBrowserEnv?((e,t)=>r=>(r=new URL(r,it.origin),e.protocol===r.protocol&&e.host===r.host&&(t||e.port===r.port)))(new URL(it.origin),it.navigator&&/(msie|trident)/i.test(it.navigator.userAgent)):()=>!0,z_=it.hasStandardBrowserEnv?{write(e,t,r,n,a,s){const o=[e+"="+encodeURIComponent(t)];H.isNumber(r)&&o.push("expires="+new Date(r).toGMTString()),H.isString(n)&&o.push("path="+n),H.isString(a)&&o.push("domain="+a),s===!0&&o.push("secure"),document.cookie=o.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 H_(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function ag(e,t,r){let n=!G_(t);return e&&n||r==!1?H_(e,t):t}const Nh=e=>e instanceof xt?{...e}:e;function Jr(e,t){t=t||{};const r={};function n(c,u,d,h){return H.isPlainObject(c)&&H.isPlainObject(u)?H.merge.call({caseless:h},c,u):H.isPlainObject(u)?H.merge({},u):H.isArray(u)?u.slice():u}function a(c,u,d,h){if(H.isUndefined(u)){if(!H.isUndefined(c))return n(void 0,c,d,h)}else return n(c,u,d,h)}function s(c,u){if(!H.isUndefined(u))return n(void 0,u)}function o(c,u){if(H.isUndefined(u)){if(!H.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:s,method:s,data:s,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,withXSRFToken:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,responseEncoding:o,validateStatus:i,headers:(c,u,d)=>a(Nh(c),Nh(u),d,!0)};return H.forEach(Object.keys(Object.assign({},e,t)),function(u){const d=l[u]||a,h=d(e[u],t[u],u);H.isUndefined(h)&&d!==i||(r[u]=h)}),r}const sg=e=>{const t=Jr({},e);let{data:r,withXSRFToken:n,xsrfHeaderName:a,xsrfCookieName:s,headers:o,auth:i}=t;t.headers=o=xt.from(o),t.url=Zm(ag(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),i&&o.set("Authorization","Basic "+btoa((i.username||"")+":"+(i.password?unescape(encodeURIComponent(i.password)):"")));let l;if(H.isFormData(r)){if(it.hasStandardBrowserEnv||it.hasStandardBrowserWebWorkerEnv)o.setContentType(void 0);else if((l=o.getContentType())!==!1){const[c,...u]=l?l.split(";").map(d=>d.trim()).filter(Boolean):[];o.setContentType([c||"multipart/form-data",...u].join("; "))}}if(it.hasStandardBrowserEnv&&(n&&H.isFunction(n)&&(n=n(t)),n||n!==!1&&B_(t.url))){const c=a&&s&&z_.read(s);c&&o.set(a,c)}return t},q_=typeof XMLHttpRequest<"u",J_=q_&&function(e){return new Promise(function(r,n){const a=sg(e);let s=a.data;const o=xt.from(a.headers).normalize();let{responseType:i,onUploadProgress:l,onDownloadProgress:c}=a,u,d,h,p,m;function f(){p&&p(),m&&m(),a.cancelToken&&a.cancelToken.unsubscribe(u),a.signal&&a.signal.removeEventListener("abort",u)}let g=new XMLHttpRequest;g.open(a.method.toUpperCase(),a.url,!0),g.timeout=a.timeout;function S(){if(!g)return;const O=xt.from("getAllResponseHeaders"in g&&g.getAllResponseHeaders()),V={data:!i||i==="text"||i==="json"?g.responseText:g.response,status:g.status,statusText:g.statusText,headers:O,config:e,request:g};ng(function(P){r(P),f()},function(P){n(P),f()},V),g=null}"onloadend"in g?g.onloadend=S:g.onreadystatechange=function(){!g||g.readyState!==4||g.status===0&&!(g.responseURL&&g.responseURL.indexOf("file:")===0)||setTimeout(S)},g.onabort=function(){g&&(n(new me("Request aborted",me.ECONNABORTED,e,g)),g=null)},g.onerror=function(){n(new me("Network Error",me.ERR_NETWORK,e,g)),g=null},g.ontimeout=function(){let C=a.timeout?"timeout of "+a.timeout+"ms exceeded":"timeout exceeded";const V=a.transitional||eg;a.timeoutErrorMessage&&(C=a.timeoutErrorMessage),n(new me(C,V.clarifyTimeoutError?me.ETIMEDOUT:me.ECONNABORTED,e,g)),g=null},s===void 0&&o.setContentType(null),"setRequestHeader"in g&&H.forEach(o.toJSON(),function(C,V){g.setRequestHeader(V,C)}),H.isUndefined(a.withCredentials)||(g.withCredentials=!!a.withCredentials),i&&i!=="json"&&(g.responseType=a.responseType),c&&([h,m]=Co(c,!0),g.addEventListener("progress",h)),l&&g.upload&&([d,p]=Co(l),g.upload.addEventListener("progress",d),g.upload.addEventListener("loadend",p)),(a.cancelToken||a.signal)&&(u=O=>{g&&(n(!O||O.type?new na(null,e,g):O),g.abort(),g=null)},a.cancelToken&&a.cancelToken.subscribe(u),a.signal&&(a.signal.aborted?u():a.signal.addEventListener("abort",u)));const T=D_(a.url);if(T&&it.protocols.indexOf(T)===-1){n(new me("Unsupported protocol "+T+":",me.ERR_BAD_REQUEST,e));return}g.send(s||null)})},W_=(e,t)=>{const{length:r}=e=e?e.filter(Boolean):[];if(t||r){let n=new AbortController,a;const s=function(c){if(!a){a=!0,i();const u=c instanceof Error?c:this.reason;n.abort(u instanceof me?u:new na(u instanceof Error?u.message:u))}};let o=t&&setTimeout(()=>{o=null,s(new me(`timeout ${t} of ms exceeded`,me.ETIMEDOUT))},t);const i=()=>{e&&(o&&clearTimeout(o),o=null,e.forEach(c=>{c.unsubscribe?c.unsubscribe(s):c.removeEventListener("abort",s)}),e=null)};e.forEach(c=>c.addEventListener("abort",s));const{signal:l}=n;return l.unsubscribe=()=>H.asap(i),l}},K_=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},Y_=async function*(e,t){for await(const r of Q_(e))yield*K_(r,t)},Q_=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()}},Fh=(e,t,r,n)=>{const a=Y_(e,t);let s=0,o,i=l=>{o||(o=!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=s+=d;r(h)}l.enqueue(new Uint8Array(u))}catch(c){throw i(c),c}},cancel(l){return i(l),a.return()}},{highWaterMark:2})},fi=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",og=fi&&typeof ReadableStream=="function",X_=fi&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),ig=(e,...t)=>{try{return!!e(...t)}catch{return!1}},Z_=og&&ig(()=>{let e=!1;const t=new Request(it.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),Bh=64*1024,Gl=og&&ig(()=>H.isReadableStream(new Response("").body)),Po={stream:Gl&&(e=>e.body)};fi&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!Po[t]&&(Po[t]=H.isFunction(e[t])?r=>r[t]():(r,n)=>{throw new me(`Response type '${t}' is not supported`,me.ERR_NOT_SUPPORT,n)})})})(new Response);const eI=async e=>{if(e==null)return 0;if(H.isBlob(e))return e.size;if(H.isSpecCompliantForm(e))return(await new Request(it.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(H.isArrayBufferView(e)||H.isArrayBuffer(e))return e.byteLength;if(H.isURLSearchParams(e)&&(e=e+""),H.isString(e))return(await X_(e)).byteLength},tI=async(e,t)=>{const r=H.toFiniteNumber(e.getContentLength());return r??eI(t)},rI=fi&&(async e=>{let{url:t,method:r,data:n,signal:a,cancelToken:s,timeout:o,onDownloadProgress:i,onUploadProgress:l,responseType:c,headers:u,withCredentials:d="same-origin",fetchOptions:h}=sg(e);c=c?(c+"").toLowerCase():"text";let p=W_([a,s&&s.toAbortSignal()],o),m;const f=p&&p.unsubscribe&&(()=>{p.unsubscribe()});let g;try{if(l&&Z_&&r!=="get"&&r!=="head"&&(g=await tI(u,n))!==0){let V=new Request(t,{method:"POST",body:n,duplex:"half"}),R;if(H.isFormData(n)&&(R=V.headers.get("content-type"))&&u.setContentType(R),V.body){const[P,E]=Uh(g,Co(Dh(l)));n=Fh(V.body,Bh,P,E)}}H.isString(d)||(d=d?"include":"omit");const S="credentials"in Request.prototype;m=new Request(t,{...h,signal:p,method:r.toUpperCase(),headers:u.normalize().toJSON(),body:n,duplex:"half",credentials:S?d:void 0});let T=await fetch(m);const O=Gl&&(c==="stream"||c==="response");if(Gl&&(i||O&&f)){const V={};["status","statusText","headers"].forEach(B=>{V[B]=T[B]});const R=H.toFiniteNumber(T.headers.get("content-length")),[P,E]=i&&Uh(R,Co(Dh(i),!0))||[];T=new Response(Fh(T.body,Bh,P,()=>{E&&E(),f&&f()}),V)}c=c||"text";let C=await Po[H.findKey(Po,c)||"text"](T,e);return!O&&f&&f(),await new Promise((V,R)=>{ng(V,R,{data:C,headers:xt.from(T.headers),status:T.status,statusText:T.statusText,config:e,request:m})})}catch(S){throw f&&f(),S&&S.name==="TypeError"&&/fetch/i.test(S.message)?Object.assign(new me("Network Error",me.ERR_NETWORK,e,m),{cause:S.cause||S}):me.from(S,S&&S.code,e,m)}}),Hl={http:y_,xhr:J_,fetch:rI};H.forEach(Hl,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const zh=e=>`- ${e}`,nI=e=>H.isFunction(e)||e===null||e===!1,lg={getAdapter:e=>{e=H.isArray(e)?e:[e];const{length:t}=e;let r,n;const a={};for(let s=0;s<t;s++){r=e[s];let o;if(n=r,!nI(r)&&(n=Hl[(o=String(r)).toLowerCase()],n===void 0))throw new me(`Unknown adapter '${o}'`);if(n)break;a[o||"#"+s]=n}if(!n){const s=Object.entries(a).map(([i,l])=>`adapter ${i} `+(l===!1?"is not supported by the environment":"is not available in the build"));let o=t?s.length>1?`since :
|
|
157
|
+
`+s.map(zh).join(`
|
|
158
|
+
`):" "+zh(s[0]):"as no adapter specified";throw new me("There is no suitable adapter to dispatch the request "+o,"ERR_NOT_SUPPORT")}return n},adapters:Hl};function il(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new na(null,e)}function Gh(e){return il(e),e.headers=xt.from(e.headers),e.data=ol.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),lg.getAdapter(e.adapter||us.adapter)(e).then(function(n){return il(e),n.data=ol.call(e,e.transformResponse,n),n.headers=xt.from(n.headers),n},function(n){return rg(n)||(il(e),n&&n.response&&(n.response.data=ol.call(e,e.transformResponse,n.response),n.response.headers=xt.from(n.response.headers))),Promise.reject(n)})}const cg="1.8.3",mi={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{mi[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});const Hh={};mi.transitional=function(t,r,n){function a(s,o){return"[Axios v"+cg+"] Transitional option '"+s+"'"+o+(n?". "+n:"")}return(s,o,i)=>{if(t===!1)throw new me(a(o," has been removed"+(r?" in "+r:"")),me.ERR_DEPRECATED);return r&&!Hh[o]&&(Hh[o]=!0,console.warn(a(o," has been deprecated since v"+r+" and will be removed in the near future"))),t?t(s,o,i):!0}};mi.spelling=function(t){return(r,n)=>(console.warn(`${n} is likely a misspelling of ${t}`),!0)};function aI(e,t,r){if(typeof e!="object")throw new me("options must be an object",me.ERR_BAD_OPTION_VALUE);const n=Object.keys(e);let a=n.length;for(;a-- >0;){const s=n[a],o=t[s];if(o){const i=e[s],l=i===void 0||o(i,s,e);if(l!==!0)throw new me("option "+s+" must be "+l,me.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new me("Unknown option "+s,me.ERR_BAD_OPTION)}}const Ws={assertOptions:aI,validators:mi},qt=Ws.validators;let Br=class{constructor(t){this.defaults=t,this.interceptors={request:new kh,response:new kh}}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 s=a.stack?a.stack.replace(/^.+\n/,""):"";try{n.stack?s&&!String(n.stack).endsWith(s.replace(/^.+\n.+\n/,""))&&(n.stack+=`
|
|
159
|
+
`+s):n.stack=s}catch{}}throw n}}_request(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=Jr(this.defaults,r);const{transitional:n,paramsSerializer:a,headers:s}=r;n!==void 0&&Ws.assertOptions(n,{silentJSONParsing:qt.transitional(qt.boolean),forcedJSONParsing:qt.transitional(qt.boolean),clarifyTimeoutError:qt.transitional(qt.boolean)},!1),a!=null&&(H.isFunction(a)?r.paramsSerializer={serialize:a}:Ws.assertOptions(a,{encode:qt.function,serialize:qt.function},!0)),r.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?r.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:r.allowAbsoluteUrls=!0),Ws.assertOptions(r,{baseUrl:qt.spelling("baseURL"),withXsrfToken:qt.spelling("withXSRFToken")},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let o=s&&H.merge(s.common,s[r.method]);s&&H.forEach(["delete","get","head","post","put","patch","common"],m=>{delete s[m]}),r.headers=xt.concat(o,s);const i=[];let l=!0;this.interceptors.request.forEach(function(f){typeof f.runWhen=="function"&&f.runWhen(r)===!1||(l=l&&f.synchronous,i.unshift(f.fulfilled,f.rejected))});const c=[];this.interceptors.response.forEach(function(f){c.push(f.fulfilled,f.rejected)});let u,d=0,h;if(!l){const m=[Gh.bind(this),void 0];for(m.unshift.apply(m,i),m.push.apply(m,c),h=m.length,u=Promise.resolve(r);d<h;)u=u.then(m[d++],m[d++]);return u}h=i.length;let p=r;for(d=0;d<h;){const m=i[d++],f=i[d++];try{p=m(p)}catch(g){f.call(this,g);break}}try{u=Gh.call(this,p)}catch(m){return Promise.reject(m)}for(d=0,h=c.length;d<h;)u=u.then(c[d++],c[d++]);return u}getUri(t){t=Jr(this.defaults,t);const r=ag(t.baseURL,t.url,t.allowAbsoluteUrls);return Zm(r,t.params,t.paramsSerializer)}};H.forEach(["delete","get","head","options"],function(t){Br.prototype[t]=function(r,n){return this.request(Jr(n||{},{method:t,url:r,data:(n||{}).data}))}});H.forEach(["post","put","patch"],function(t){function r(n){return function(s,o,i){return this.request(Jr(i||{},{method:t,headers:n?{"Content-Type":"multipart/form-data"}:{},url:s,data:o}))}}Br.prototype[t]=r(),Br.prototype[t+"Form"]=r(!0)});let sI=class ug{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(s){r=s});const n=this;this.promise.then(a=>{if(!n._listeners)return;let s=n._listeners.length;for(;s-- >0;)n._listeners[s](a);n._listeners=null}),this.promise.then=a=>{let s;const o=new Promise(i=>{n.subscribe(i),s=i}).then(a);return o.cancel=function(){n.unsubscribe(s)},o},t(function(s,o,i){n.reason||(n.reason=new na(s,o,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 ug(function(a){t=a}),cancel:t}}};function oI(e){return function(r){return e.apply(null,r)}}function iI(e){return H.isObject(e)&&e.isAxiosError===!0}const ql={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(ql).forEach(([e,t])=>{ql[t]=e});function dg(e){const t=new Br(e),r=Bm(Br.prototype.request,t);return H.extend(r,Br.prototype,t,{allOwnKeys:!0}),H.extend(r,t,null,{allOwnKeys:!0}),r.create=function(a){return dg(Jr(e,a))},r}const _=dg(us);_.Axios=Br;_.CanceledError=na;_.CancelToken=sI;_.isCancel=rg;_.VERSION=cg;_.toFormData=pi;_.AxiosError=me;_.Cancel=_.CanceledError;_.all=function(t){return Promise.all(t)};_.spread=oI;_.isAxiosError=iI;_.mergeConfig=Jr;_.AxiosHeaders=xt;_.formToJSON=e=>tg(H.isHTMLForm(e)?new FormData(e):e);_.getAdapter=lg.getAdapter;_.HttpStatusCode=ql;_.default=_;const{Axios:fj,AxiosError:Jl,CanceledError:mj,isCancel:gj,CancelToken:yj,VERSION:bj,all:vj,Cancel:xj,isAxiosError:lI,spread:Sj,toFormData:Oj,AxiosHeaders:wj,HttpStatusCode:Cj,formToJSON:Pj,getAdapter:Rj,mergeConfig:Tj}=_,M="/api/v1".replace(/\/+$/,"");class je{constructor(t,r=M,n=_){la(this,"basePath");la(this,"axios");la(this,"configuration");this.basePath=r,this.axios=n,t&&(this.configuration=t,this.basePath=t.basePath??r)}}class cI extends Error{constructor(r,n){super(n);la(this,"field");this.field=r,this.name="RequiredError"}}const $={},j="https://example.com",v=function(e,t,r){if(r==null)throw new cI(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})},L=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 Wl(e,t,r=""){t!=null&&(typeof t=="object"?Array.isArray(t)?t.forEach(n=>Wl(e,n,r)):Object.keys(t).forEach(n=>Wl(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);Wl(r,t),e.search=r.toString()},fe=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,s=r)=>{const o={...e.options,url:(a.defaults.baseURL?"":(n==null?void 0:n.basePath)??s)+e.url};return a.request(o)}},uI=function(e){return{addApp:async(t,r,n,a={})=>{v("addApp","cell",t),v("addApp","app",r);const s="/cells/{cell}/apps".replace("{cell}",encodeURIComponent(String(t))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.completionTimeout=n),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(r,l,e),{url:D(o),options:l}},clearApps:async(t,r,n={})=>{v("clearApps","cell",t);const a="/cells/{cell}/apps".replace("{cell}",encodeURIComponent(String(t))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),r!==void 0&&(c.completionTimeout=r),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},deleteApp:async(t,r,n,a={})=>{v("deleteApp","cell",t),v("deleteApp","app",r);const s="/cells/{cell}/apps/{app}".replace("{cell}",encodeURIComponent(String(t))).replace("{app}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"DELETE",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.completionTimeout=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},updateApp:async(t,r,n,a,s={})=>{v("updateApp","cell",t),v("updateApp","app",r),v("updateApp","app2",n);const o="/cells/{cell}/apps/{app}".replace("{cell}",encodeURIComponent(String(t))).replace("{app}",encodeURIComponent(String(r))),i=new URL(o,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...s},u={},d={};k(c,e),await L(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,...s.headers},c.data=fe(n,c,e),{url:D(i),options:c}}}},On=function(e){const t=uI(e);return{async addApp(r,n,a,s){var c,u;const o=await t.addApp(r,n,a,s),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(o,_,M,e)(d,l||h)},async clearApps(r,n,a){var l,c;const s=await t.clearApps(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ApplicationApi.clearApps"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async deleteApp(r,n,a,s){var c,u;const o=await t.deleteApp(r,n,a,s),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(o,_,M,e)(d,l||h)},async getApp(r,n,a){var l,c;const s=await t.getApp(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ApplicationApi.getApp"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listApps(r,n){var i,l;const a=await t.listApps(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["ApplicationApi.listApps"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async updateApp(r,n,a,s,o){var u,d;const i=await t.updateApp(r,n,a,s,o),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,_,M,e)(h,c||p)}}};class qh extends je{addApp(t,r,n,a){return On(this.configuration).addApp(t,r,n,a).then(s=>s(this.axios,this.basePath))}clearApps(t,r,n){return On(this.configuration).clearApps(t,r,n).then(a=>a(this.axios,this.basePath))}deleteApp(t,r,n,a){return On(this.configuration).deleteApp(t,r,n,a).then(s=>s(this.axios,this.basePath))}getApp(t,r,n){return On(this.configuration).getApp(t,r,n).then(a=>a(this.axios,this.basePath))}listApps(t,r){return On(this.configuration).listApps(t,r).then(n=>n(this.axios,this.basePath))}updateApp(t,r,n,a,s){return On(this.configuration).updateApp(t,r,n,a,s).then(o=>o(this.axios,this.basePath))}}const dI=function(e){return{deleteCell:async(t,r,n={})=>{v("deleteCell","cell",t);const a="/cells/{cell}".replace("{cell}",encodeURIComponent(String(t))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),r!==void 0&&(c.completionTimeout=r),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},deployCell:async(t,r,n={})=>{v("deployCell","cell",t);const a="/cells",s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"POST",...o,...n},l={},c={};k(i,e),await L(l,e),r!==void 0&&(c.completionTimeout=r),l["Content-Type"]="application/json",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(t,i,e),{url:D(s),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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},getCellStatus:async(t,r={})=>{v("getCellStatus","cell",t);const n="/cells/{cell}/status".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},listCells:async(t={})=>{const r="/cells",n=new URL(r,j);let a;e&&(a=e.baseOptions);const s={method:"GET",...a,...t},o={},i={};k(s,e),await L(o,e),U(n,i);let l=a&&a.headers?a.headers:{};return s.headers={...o,...l,...t.headers},{url:D(n),options:s}},updateCell:async(t,r,n,a={})=>{v("updateCell","cell",t),v("updateCell","cell2",r);const s="/cells/{cell}".replace("{cell}",encodeURIComponent(String(t))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.completionTimeout=n),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(r,l,e),{url:D(o),options:l}}}},wn=function(e){const t=dI(e);return{async deleteCell(r,n,a){var l,c;const s=await t.deleteCell(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["CellApi.deleteCell"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async deployCell(r,n,a){var l,c;const s=await t.deployCell(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["CellApi.deployCell"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getCell(r,n){var i,l;const a=await t.getCell(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["CellApi.getCell"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async getCellStatus(r,n){var i,l;const a=await t.getCellStatus(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["CellApi.getCellStatus"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async listCells(r){var o,i;const n=await t.listCells(r),a=(e==null?void 0:e.serverIndex)??0,s=(i=(o=$["CellApi.listCells"])==null?void 0:o[a])==null?void 0:i.url;return(l,c)=>N(n,_,M,e)(l,s||c)},async updateCell(r,n,a,s){var c,u;const o=await t.updateCell(r,n,a,s),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(o,_,M,e)(d,l||h)}}};class hI extends je{deleteCell(t,r,n){return wn(this.configuration).deleteCell(t,r,n).then(a=>a(this.axios,this.basePath))}deployCell(t,r,n){return wn(this.configuration).deployCell(t,r,n).then(a=>a(this.axios,this.basePath))}getCell(t,r){return wn(this.configuration).getCell(t,r).then(n=>n(this.axios,this.basePath))}getCellStatus(t,r){return wn(this.configuration).getCellStatus(t,r).then(n=>n(this.axios,this.basePath))}listCells(t){return wn(this.configuration).listCells(t).then(r=>r(this.axios,this.basePath))}updateCell(t,r,n,a){return wn(this.configuration).updateCell(t,r,n,a).then(s=>s(this.axios,this.basePath))}}const pI=function(e){return{addRobotController:async(t,r,n,a={})=>{v("addRobotController","cell",t),v("addRobotController","robotController",r);const s="/cells/{cell}/controllers".replace("{cell}",encodeURIComponent(String(t))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.completionTimeout=n),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(r,l,e),{url:D(o),options:l}},clearRobotControllers:async(t,r,n={})=>{v("clearRobotControllers","cell",t);const a="/cells/{cell}/controllers".replace("{cell}",encodeURIComponent(String(t))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),r!==void 0&&(c.completionTimeout=r),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},deleteRobotController:async(t,r,n,a={})=>{v("deleteRobotController","cell",t),v("deleteRobotController","controller",r);const s="/cells/{cell}/controllers/{controller}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"DELETE",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.completionTimeout=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},setDefaultMode:async(t,r,n,a={})=>{v("setDefaultMode","cell",t),v("setDefaultMode","controller",r),v("setDefaultMode","mode",n);const s="/cells/{cell}/controllers/{controller}/mode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.mode=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),options:l}},streamFreeDrive:async(t,r,n,a={})=>{v("streamFreeDrive","cell",t),v("streamFreeDrive","controller",r);const s="/cells/{cell}/controllers/{controller}/free-drive-stream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.response_rate=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},streamRobotControllerState:async(t,r,n,a={})=>{v("streamRobotControllerState","cell",t),v("streamRobotControllerState","controller",r);const s="/cells/{cell}/controllers/{controller}/state-stream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.response_rate=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),options:l}},updateRobotController:async(t,r,n,a,s={})=>{v("updateRobotController","cell",t),v("updateRobotController","controller",r),v("updateRobotController","robotController",n);const o="/cells/{cell}/controllers/{controller}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),i=new URL(o,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...s},u={},d={};k(c,e),await L(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,...s.headers},c.data=fe(n,c,e),{url:D(i),options:c}}}},gt=function(e){const t=pI(e);return{async addRobotController(r,n,a,s){var c,u;const o=await t.addRobotController(r,n,a,s),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(o,_,M,e)(d,l||h)},async clearRobotControllers(r,n,a){var l,c;const s=await t.clearRobotControllers(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.clearRobotControllers"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async deleteRobotController(r,n,a,s){var c,u;const o=await t.deleteRobotController(r,n,a,s),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(o,_,M,e)(d,l||h)},async getCurrentRobotControllerState(r,n,a){var l,c;const s=await t.getCurrentRobotControllerState(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.getCurrentRobotControllerState"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getMode(r,n,a){var l,c;const s=await t.getMode(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.getMode"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getRobotController(r,n,a){var l,c;const s=await t.getRobotController(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.getRobotController"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getSupportedModes(r,n,a){var l,c;const s=await t.getSupportedModes(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.getSupportedModes"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getVirtualRobotConfiguration(r,n,a){var l,c;const s=await t.getVirtualRobotConfiguration(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.getVirtualRobotConfiguration"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listControllers(r,n){var i,l;const a=await t.listControllers(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["ControllerApi.listControllers"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async setDefaultMode(r,n,a,s){var c,u;const o=await t.setDefaultMode(r,n,a,s),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(o,_,M,e)(d,l||h)},async streamFreeDrive(r,n,a,s){var c,u;const o=await t.streamFreeDrive(r,n,a,s),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(o,_,M,e)(d,l||h)},async streamModeChange(r,n,a){var l,c;const s=await t.streamModeChange(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ControllerApi.streamModeChange"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async streamRobotControllerState(r,n,a,s){var c,u;const o=await t.streamRobotControllerState(r,n,a,s),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(o,_,M,e)(d,l||h)},async updateRobotController(r,n,a,s,o){var u,d;const i=await t.updateRobotController(r,n,a,s,o),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,_,M,e)(h,c||p)}}};class fI extends je{addRobotController(t,r,n,a){return gt(this.configuration).addRobotController(t,r,n,a).then(s=>s(this.axios,this.basePath))}clearRobotControllers(t,r,n){return gt(this.configuration).clearRobotControllers(t,r,n).then(a=>a(this.axios,this.basePath))}deleteRobotController(t,r,n,a){return gt(this.configuration).deleteRobotController(t,r,n,a).then(s=>s(this.axios,this.basePath))}getCurrentRobotControllerState(t,r,n){return gt(this.configuration).getCurrentRobotControllerState(t,r,n).then(a=>a(this.axios,this.basePath))}getMode(t,r,n){return gt(this.configuration).getMode(t,r,n).then(a=>a(this.axios,this.basePath))}getRobotController(t,r,n){return gt(this.configuration).getRobotController(t,r,n).then(a=>a(this.axios,this.basePath))}getSupportedModes(t,r,n){return gt(this.configuration).getSupportedModes(t,r,n).then(a=>a(this.axios,this.basePath))}getVirtualRobotConfiguration(t,r,n){return gt(this.configuration).getVirtualRobotConfiguration(t,r,n).then(a=>a(this.axios,this.basePath))}listControllers(t,r){return gt(this.configuration).listControllers(t,r).then(n=>n(this.axios,this.basePath))}setDefaultMode(t,r,n,a){return gt(this.configuration).setDefaultMode(t,r,n,a).then(s=>s(this.axios,this.basePath))}streamFreeDrive(t,r,n,a){return gt(this.configuration).streamFreeDrive(t,r,n,a).then(s=>s(this.axios,this.basePath))}streamModeChange(t,r,n){return gt(this.configuration).streamModeChange(t,r,n).then(a=>a(this.axios,this.basePath))}streamRobotControllerState(t,r,n,a){return gt(this.configuration).streamRobotControllerState(t,r,n,a).then(s=>s(this.axios,this.basePath))}updateRobotController(t,r,n,a,s){return gt(this.configuration).updateRobotController(t,r,n,a,s).then(o=>o(this.axios,this.basePath))}}const mI=function(e){return{listIODescriptions:async(t,r,n,a={})=>{v("listIODescriptions","cell",t),v("listIODescriptions","controller",r);const s="/cells/{cell}/controllers/{controller}/ios/description".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),n&&(u.ios=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),options:l}},listIOValues:async(t,r,n,a={})=>{v("listIOValues","cell",t),v("listIOValues","controller",r);const s="/cells/{cell}/controllers/{controller}/ios/values".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),n&&(u.ios=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),options:l}},setOutputValues:async(t,r,n,a={})=>{v("setOutputValues","cell",t),v("setOutputValues","controller",r),v("setOutputValues","iOValue",n);const s="/cells/{cell}/controllers/{controller}/ios/values".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}},streamIOValues:async(t,r,n,a={})=>{v("streamIOValues","cell",t),v("streamIOValues","controller",r);const s="/cells/{cell}/controllers/{controller}/ios/stream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),n&&(u.ios=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),options:l}},waitForIOEvent:async(t,r,n,a,s,o,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={},m={};k(h,e),await L(p,e),n!==void 0&&(m.io=n),a!==void 0&&(m.comparison_type=a),s!==void 0&&(m.boolean_value=s),o!==void 0&&(m.integer_value=o),i!==void 0&&(m.floating_value=i),U(u,m);let f=d&&d.headers?d.headers:{};return h.headers={...p,...f,...l.headers},{url:D(u),options:h}}}},Sa=function(e){const t=mI(e);return{async listIODescriptions(r,n,a,s){var c,u;const o=await t.listIODescriptions(r,n,a,s),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(o,_,M,e)(d,l||h)},async listIOValues(r,n,a,s){var c,u;const o=await t.listIOValues(r,n,a,s),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(o,_,M,e)(d,l||h)},async setOutputValues(r,n,a,s){var c,u;const o=await t.setOutputValues(r,n,a,s),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(o,_,M,e)(d,l||h)},async streamIOValues(r,n,a,s){var c,u;const o=await t.streamIOValues(r,n,a,s),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(o,_,M,e)(d,l||h)},async waitForIOEvent(r,n,a,s,o,i,l,c){var p,m;const u=await t.waitForIOEvent(r,n,a,s,o,i,l,c),d=(e==null?void 0:e.serverIndex)??0,h=(m=(p=$["ControllerIOsApi.waitForIOEvent"])==null?void 0:p[d])==null?void 0:m.url;return(f,g)=>N(u,_,M,e)(f,h||g)}}};class gI extends je{listIODescriptions(t,r,n,a){return Sa(this.configuration).listIODescriptions(t,r,n,a).then(s=>s(this.axios,this.basePath))}listIOValues(t,r,n,a){return Sa(this.configuration).listIOValues(t,r,n,a).then(s=>s(this.axios,this.basePath))}setOutputValues(t,r,n,a){return Sa(this.configuration).setOutputValues(t,r,n,a).then(s=>s(this.axios,this.basePath))}streamIOValues(t,r,n,a){return Sa(this.configuration).streamIOValues(t,r,n,a).then(s=>s(this.axios,this.basePath))}waitForIOEvent(t,r,n,a,s,o,i,l){return Sa(this.configuration).waitForIOEvent(t,r,n,a,s,o,i,l).then(c=>c(this.axios,this.basePath))}}const yI=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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"PUT",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="application/json",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},getCoordinateSystem:async(t,r,n,a={})=>{v("getCoordinateSystem","cell",t),v("getCoordinateSystem","coordinateSystem",r);const s="/cells/{cell}/coordinate-systems/{coordinate-system}".replace("{cell}",encodeURIComponent(String(t))).replace("{coordinate-system}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.rotation_type=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),options:l}},listCoordinateSystems:async(t,r,n={})=>{v("listCoordinateSystems","cell",t);const a="/cells/{cell}/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),r!==void 0&&(c.rotation_type=r),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},transformInCoordinateSystem:async(t,r,n,a={})=>{v("transformInCoordinateSystem","cell",t),v("transformInCoordinateSystem","coordinateSystem",r),v("transformInCoordinateSystem","pose",n);const s="/cells/{cell}/coordinate-systems/{coordinate-system}/transform".replace("{cell}",encodeURIComponent(String(t))).replace("{coordinate-system}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}}}},Oa=function(e){const t=yI(e);return{async addCoordinateSystem(r,n,a){var l,c;const s=await t.addCoordinateSystem(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["CoordinateSystemsApi.addCoordinateSystem"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async deleteCoordinateSystem(r,n,a){var l,c;const s=await t.deleteCoordinateSystem(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["CoordinateSystemsApi.deleteCoordinateSystem"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getCoordinateSystem(r,n,a,s){var c,u;const o=await t.getCoordinateSystem(r,n,a,s),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(o,_,M,e)(d,l||h)},async listCoordinateSystems(r,n,a){var l,c;const s=await t.listCoordinateSystems(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["CoordinateSystemsApi.listCoordinateSystems"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async transformInCoordinateSystem(r,n,a,s){var c,u;const o=await t.transformInCoordinateSystem(r,n,a,s),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(o,_,M,e)(d,l||h)}}};class bI extends je{addCoordinateSystem(t,r,n){return Oa(this.configuration).addCoordinateSystem(t,r,n).then(a=>a(this.axios,this.basePath))}deleteCoordinateSystem(t,r,n){return Oa(this.configuration).deleteCoordinateSystem(t,r,n).then(a=>a(this.axios,this.basePath))}getCoordinateSystem(t,r,n,a){return Oa(this.configuration).getCoordinateSystem(t,r,n,a).then(s=>s(this.axios,this.basePath))}listCoordinateSystems(t,r,n){return Oa(this.configuration).listCoordinateSystems(t,r,n).then(a=>a(this.axios,this.basePath))}transformInCoordinateSystem(t,r,n,a){return Oa(this.configuration).transformInCoordinateSystem(t,r,n,a).then(s=>s(this.axios,this.basePath))}}const vI=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 s;e&&(s=e.baseOptions);const o={method:"DELETE",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},createDevice:async(t,r,n={})=>{v("createDevice","cell",t),v("createDevice","createDeviceRequestInner",r);const a="/cells/{cell}/devices".replace("{cell}",encodeURIComponent(String(t))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"POST",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="application/json",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}}}},wa=function(e){const t=vI(e);return{async clearDevices(r,n){var i,l;const a=await t.clearDevices(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["DeviceConfigurationApi.clearDevices"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async createDevice(r,n,a){var l,c;const s=await t.createDevice(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["DeviceConfigurationApi.createDevice"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async deleteDevice(r,n,a){var l,c;const s=await t.deleteDevice(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["DeviceConfigurationApi.deleteDevice"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getDevice(r,n,a){var l,c;const s=await t.getDevice(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["DeviceConfigurationApi.getDevice"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listDevices(r,n){var i,l;const a=await t.listDevices(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["DeviceConfigurationApi.listDevices"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)}}};class xI extends je{clearDevices(t,r){return wa(this.configuration).clearDevices(t,r).then(n=>n(this.axios,this.basePath))}createDevice(t,r,n){return wa(this.configuration).createDevice(t,r,n).then(a=>a(this.axios,this.basePath))}deleteDevice(t,r,n){return wa(this.configuration).deleteDevice(t,r,n).then(a=>a(this.axios,this.basePath))}getDevice(t,r,n){return wa(this.configuration).getDevice(t,r,n).then(a=>a(this.axios,this.basePath))}listDevices(t,r){return wa(this.configuration).listDevices(t,r).then(n=>n(this.axios,this.basePath))}}const SI=function(e){return{createProgram:async(t,r,n,a={})=>{v("createProgram","cell",t),v("createProgram","body",r);const s="/cells/{cell}/store/programs".replace("{cell}",encodeURIComponent(String(t))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.name=n),c["Content-Type"]="text/plain",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(r,l,e),{url:D(o),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),r&&(c.program_ids=r),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},updateProgram:async(t,r,n,a={})=>{v("updateProgram","cell",t),v("updateProgram","program",r),v("updateProgram","body",n);const s="/cells/{cell}/store/programs/{program}".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="text/plain",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}}}},Ca=function(e){const t=SI(e);return{async createProgram(r,n,a,s){var c,u;const o=await t.createProgram(r,n,a,s),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(o,_,M,e)(d,l||h)},async deleteProgram(r,n,a){var l,c;const s=await t.deleteProgram(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryProgramApi.deleteProgram"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async deleteProgramList(r,n,a){var l,c;const s=await t.deleteProgramList(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryProgramApi.deleteProgramList"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getProgram(r,n,a){var l,c;const s=await t.getProgram(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryProgramApi.getProgram"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async updateProgram(r,n,a,s){var c,u;const o=await t.updateProgram(r,n,a,s),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(o,_,M,e)(d,l||h)}}};class OI extends je{createProgram(t,r,n,a){return Ca(this.configuration).createProgram(t,r,n,a).then(s=>s(this.axios,this.basePath))}deleteProgram(t,r,n){return Ca(this.configuration).deleteProgram(t,r,n).then(a=>a(this.axios,this.basePath))}deleteProgramList(t,r,n){return Ca(this.configuration).deleteProgramList(t,r,n).then(a=>a(this.axios,this.basePath))}getProgram(t,r,n){return Ca(this.configuration).getProgram(t,r,n).then(a=>a(this.axios,this.basePath))}updateProgram(t,r,n,a){return Ca(this.configuration).updateProgram(t,r,n,a).then(s=>s(this.axios,this.basePath))}}const wI=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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},listProgramMetadata:async(t,r,n={})=>{v("listProgramMetadata","cell",t);const a="/cells/{cell}/store/programs".replace("{cell}",encodeURIComponent(String(t))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),r!==void 0&&(c.show_hidden=r),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},updateProgramMetadata:async(t,r,n,a={})=>{v("updateProgramMetadata","cell",t),v("updateProgramMetadata","program",r),v("updateProgramMetadata","updateProgramMetadataRequest",n);const s="/cells/{cell}/store/programs/{program}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}},uploadProgramMetadataImage:async(t,r,n,a={})=>{v("uploadProgramMetadataImage","cell",t),v("uploadProgramMetadataImage","program",r),v("uploadProgramMetadataImage","file",n);const s="/cells/{cell}/store/programs/{program}/metadata/image".replace("{cell}",encodeURIComponent(String(t))).replace("{program}",encodeURIComponent(String(r))),o=new URL(s,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 L(c,e),n!==void 0&&d.append("file",n),c["Content-Type"]="multipart/form-data",U(o,u);let h=i&&i.headers?i.headers:{};return l.headers={...c,...h,...a.headers},l.data=d,{url:D(o),options:l}}}},Ts=function(e){const t=wI(e);return{async getProgramMetadata(r,n,a){var l,c;const s=await t.getProgramMetadata(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryProgramMetadataApi.getProgramMetadata"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listProgramMetadata(r,n,a){var l,c;const s=await t.listProgramMetadata(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryProgramMetadataApi.listProgramMetadata"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async updateProgramMetadata(r,n,a,s){var c,u;const o=await t.updateProgramMetadata(r,n,a,s),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(o,_,M,e)(d,l||h)},async uploadProgramMetadataImage(r,n,a,s){var c,u;const o=await t.uploadProgramMetadataImage(r,n,a,s),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(o,_,M,e)(d,l||h)}}};class CI extends je{getProgramMetadata(t,r,n){return Ts(this.configuration).getProgramMetadata(t,r,n).then(a=>a(this.axios,this.basePath))}listProgramMetadata(t,r,n){return Ts(this.configuration).listProgramMetadata(t,r,n).then(a=>a(this.axios,this.basePath))}updateProgramMetadata(t,r,n,a){return Ts(this.configuration).updateProgramMetadata(t,r,n,a).then(s=>s(this.axios,this.basePath))}uploadProgramMetadataImage(t,r,n,a){return Ts(this.configuration).uploadProgramMetadataImage(t,r,n,a).then(s=>s(this.axios,this.basePath))}}const PI=function(e){return{createRecipe:async(t,r,n,a,s={})=>{v("createRecipe","cell",t),v("createRecipe","programId",r),v("createRecipe","body",n);const o="/cells/{cell}/store/recipes".replace("{cell}",encodeURIComponent(String(t))),i=new URL(o,j);let l;e&&(l=e.baseOptions);const c={method:"POST",...l,...s},u={},d={};k(c,e),await L(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,...s.headers},c.data=fe(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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),r&&(c.recipe_ids=r),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},updateRecipe:async(t,r,n,a={})=>{v("updateRecipe","cell",t),v("updateRecipe","recipe",r),v("updateRecipe","body",n);const s="/cells/{cell}/store/recipes/{recipe}".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}}}},Pa=function(e){const t=PI(e);return{async createRecipe(r,n,a,s,o){var u,d;const i=await t.createRecipe(r,n,a,s,o),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,_,M,e)(h,c||p)},async deleteRecipe(r,n,a){var l,c;const s=await t.deleteRecipe(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryRecipeApi.deleteRecipe"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async deleteRecipeList(r,n,a){var l,c;const s=await t.deleteRecipeList(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryRecipeApi.deleteRecipeList"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getRecipe(r,n,a){var l,c;const s=await t.getRecipe(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryRecipeApi.getRecipe"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async updateRecipe(r,n,a,s){var c,u;const o=await t.updateRecipe(r,n,a,s),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(o,_,M,e)(d,l||h)}}};class RI extends je{createRecipe(t,r,n,a,s){return Pa(this.configuration).createRecipe(t,r,n,a,s).then(o=>o(this.axios,this.basePath))}deleteRecipe(t,r,n){return Pa(this.configuration).deleteRecipe(t,r,n).then(a=>a(this.axios,this.basePath))}deleteRecipeList(t,r,n){return Pa(this.configuration).deleteRecipeList(t,r,n).then(a=>a(this.axios,this.basePath))}getRecipe(t,r,n){return Pa(this.configuration).getRecipe(t,r,n).then(a=>a(this.axios,this.basePath))}updateRecipe(t,r,n,a){return Pa(this.configuration).updateRecipe(t,r,n,a).then(s=>s(this.axios,this.basePath))}}const TI=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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},updateRecipeMetadata:async(t,r,n,a={})=>{v("updateRecipeMetadata","cell",t),v("updateRecipeMetadata","recipe",r),v("updateRecipeMetadata","updateRecipeMetadataRequest",n);const s="/cells/{cell}/store/recipes/{recipe}/metadata".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}},uploadRecipeMetadataImage:async(t,r,n,a={})=>{v("uploadRecipeMetadataImage","cell",t),v("uploadRecipeMetadataImage","recipe",r),v("uploadRecipeMetadataImage","file",n);const s="/cells/{cell}/store/recipes/{recipe}/metadata/image".replace("{cell}",encodeURIComponent(String(t))).replace("{recipe}",encodeURIComponent(String(r))),o=new URL(s,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 L(c,e),n!==void 0&&d.append("file",n),c["Content-Type"]="multipart/form-data",U(o,u);let h=i&&i.headers?i.headers:{};return l.headers={...c,...h,...a.headers},l.data=d,{url:D(o),options:l}}}},As=function(e){const t=TI(e);return{async getRecipeMetadata(r,n,a){var l,c;const s=await t.getRecipeMetadata(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["LibraryRecipeMetadataApi.getRecipeMetadata"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listRecipeMetadata(r,n){var i,l;const a=await t.listRecipeMetadata(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["LibraryRecipeMetadataApi.listRecipeMetadata"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async updateRecipeMetadata(r,n,a,s){var c,u;const o=await t.updateRecipeMetadata(r,n,a,s),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(o,_,M,e)(d,l||h)},async uploadRecipeMetadataImage(r,n,a,s){var c,u;const o=await t.uploadRecipeMetadataImage(r,n,a,s),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(o,_,M,e)(d,l||h)}}};class AI extends je{getRecipeMetadata(t,r,n){return As(this.configuration).getRecipeMetadata(t,r,n).then(a=>a(this.axios,this.basePath))}listRecipeMetadata(t,r){return As(this.configuration).listRecipeMetadata(t,r).then(n=>n(this.axios,this.basePath))}updateRecipeMetadata(t,r,n,a){return As(this.configuration).updateRecipeMetadata(t,r,n,a).then(s=>s(this.axios,this.basePath))}uploadRecipeMetadataImage(t,r,n,a){return As(this.configuration).uploadRecipeMetadataImage(t,r,n,a).then(s=>s(this.axios,this.basePath))}}const VI=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 s;e&&(s=e.baseOptions);const o={method:"DELETE",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="application/json",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),options:i}},getMotionTrajectory:async(t,r,n,a,s={})=>{v("getMotionTrajectory","cell",t),v("getMotionTrajectory","motion",r),v("getMotionTrajectory","sampleTime",n);const o="/cells/{cell}/motions/{motion}/trajectory".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),i=new URL(o,j);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...s},u={},d={};k(c,e),await L(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,...s.headers},{url:D(i),options:c}},getMotionTrajectorySample:async(t,r,n,a,s={})=>{v("getMotionTrajectorySample","cell",t),v("getMotionTrajectorySample","motion",r);const o="/cells/{cell}/motions/{motion}/trajectorysample".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),i=new URL(o,j);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...s},u={},d={};k(c,e),await L(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,...s.headers},{url:D(i),options:c}},getPlannedMotion:async(t,r,n,a={})=>{v("getPlannedMotion","cell",t),v("getPlannedMotion","motion",r);const s="/cells/{cell}/motions/{motion}/planned-motion".replace("{cell}",encodeURIComponent(String(t))).replace("{motion}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.sample_time=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},listMotions:async(t,r={})=>{v("listMotions","cell",t);const n="/cells/{cell}/motions".replace("{cell}",encodeURIComponent(String(t))),a=new URL(n,j);let s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},loadPlannedMotion:async(t,r,n={})=>{v("loadPlannedMotion","cell",t),v("loadPlannedMotion","plannedMotion",r);const a="/cells/{cell}/planned-motions".replace("{cell}",encodeURIComponent(String(t))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"POST",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="application/json",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"POST",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="application/json",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"POST",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="application/json",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),options:i}},planTrajectory:async(t,r,n={})=>{v("planTrajectory","cell",t);const a="/cells/{cell}/motion-planning/plan-trajectory".replace("{cell}",encodeURIComponent(String(t))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"POST",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="application/json",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"PUT",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="application/json",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),options:i}},streamMoveBackward:async(t,r,n,a,s,o,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 L(h,e),n!==void 0&&(p.playback_speed_in_percent=n),a!==void 0&&(p.response_rate=a),s!==void 0&&(p.response_coordinate_system=s),o!==void 0&&(p.start_location_on_trajectory=o),U(c,p);let m=u&&u.headers?u.headers:{};return d.headers={...h,...m,...i.headers},{url:D(c),options:d}},streamMoveForward:async(t,r,n,a,s,o,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 L(h,e),n!==void 0&&(p.playback_speed_in_percent=n),a!==void 0&&(p.response_rate=a),s!==void 0&&(p.response_coordinate_system=s),o!==void 0&&(p.start_location_on_trajectory=o),U(c,p);let m=u&&u.headers?u.headers:{};return d.headers={...h,...m,...i.headers},{url:D(c),options:d}},streamMoveToTrajectoryViaJointPTP:async(t,r,n,a,s,o,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 m;e&&(m=e.baseOptions);const f={method:"GET",...m,...d},g={},S={};k(f,e),await L(g,e),n!==void 0&&(S.location_on_trajectory=n),a&&(S["limit_override.joint_velocity_limits.joints"]=a),s&&(S["limit_override.joint_acceleration_limits.joints"]=s),o!==void 0&&(S["limit_override.tcp_velocity_limit"]=o),i!==void 0&&(S["limit_override.tcp_acceleration_limit"]=i),l!==void 0&&(S["limit_override.tcp_orientation_velocity_limit"]=l),c!==void 0&&(S["limit_override.tcp_orientation_acceleration_limit"]=c),u!==void 0&&(S.responses_coordinate_system=u),U(p,S);let T=m&&m.headers?m.headers:{};return f.headers={...g,...T,...d.headers},{url:D(p),options:f}}}},st=function(e){const t=VI(e);return{async deleteAllMotions(r,n){var i,l;const a=await t.deleteAllMotions(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["MotionApi.deleteAllMotions"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async deleteMotion(r,n,a){var l,c;const s=await t.deleteMotion(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.deleteMotion"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async executeTrajectory(r,n,a){var l,c;const s=await t.executeTrajectory(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.executeTrajectory"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getMotionTrajectory(r,n,a,s,o){var u,d;const i=await t.getMotionTrajectory(r,n,a,s,o),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,_,M,e)(h,c||p)},async getMotionTrajectorySample(r,n,a,s,o){var u,d;const i=await t.getMotionTrajectorySample(r,n,a,s,o),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,_,M,e)(h,c||p)},async getPlannedMotion(r,n,a,s){var c,u;const o=await t.getPlannedMotion(r,n,a,s),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(o,_,M,e)(d,l||h)},async getPlanningMotionGroupModels(r,n){var i,l;const a=await t.getPlanningMotionGroupModels(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["MotionApi.getPlanningMotionGroupModels"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async listMotions(r,n){var i,l;const a=await t.listMotions(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["MotionApi.listMotions"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async loadPlannedMotion(r,n,a){var l,c;const s=await t.loadPlannedMotion(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.loadPlannedMotion"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async planCollisionFreePTP(r,n,a){var l,c;const s=await t.planCollisionFreePTP(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.planCollisionFreePTP"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async planMotion(r,n,a){var l,c;const s=await t.planMotion(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.planMotion"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async planTrajectory(r,n,a){var l,c;const s=await t.planTrajectory(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.planTrajectory"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async stopExecution(r,n,a){var l,c;const s=await t.stopExecution(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.stopExecution"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async streamMove(r,n,a){var l,c;const s=await t.streamMove(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionApi.streamMove"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async streamMoveBackward(r,n,a,s,o,i,l){var h,p;const c=await t.streamMoveBackward(r,n,a,s,o,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(m,f)=>N(c,_,M,e)(m,d||f)},async streamMoveForward(r,n,a,s,o,i,l){var h,p;const c=await t.streamMoveForward(r,n,a,s,o,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(m,f)=>N(c,_,M,e)(m,d||f)},async streamMoveToTrajectoryViaJointPTP(r,n,a,s,o,i,l,c,u,d,h){var g,S;const p=await t.streamMoveToTrajectoryViaJointPTP(r,n,a,s,o,i,l,c,u,d,h),m=(e==null?void 0:e.serverIndex)??0,f=(S=(g=$["MotionApi.streamMoveToTrajectoryViaJointPTP"])==null?void 0:g[m])==null?void 0:S.url;return(T,O)=>N(p,_,M,e)(T,f||O)}}};class EI extends je{deleteAllMotions(t,r){return st(this.configuration).deleteAllMotions(t,r).then(n=>n(this.axios,this.basePath))}deleteMotion(t,r,n){return st(this.configuration).deleteMotion(t,r,n).then(a=>a(this.axios,this.basePath))}executeTrajectory(t,r,n){return st(this.configuration).executeTrajectory(t,r,n).then(a=>a(this.axios,this.basePath))}getMotionTrajectory(t,r,n,a,s){return st(this.configuration).getMotionTrajectory(t,r,n,a,s).then(o=>o(this.axios,this.basePath))}getMotionTrajectorySample(t,r,n,a,s){return st(this.configuration).getMotionTrajectorySample(t,r,n,a,s).then(o=>o(this.axios,this.basePath))}getPlannedMotion(t,r,n,a){return st(this.configuration).getPlannedMotion(t,r,n,a).then(s=>s(this.axios,this.basePath))}getPlanningMotionGroupModels(t,r){return st(this.configuration).getPlanningMotionGroupModels(t,r).then(n=>n(this.axios,this.basePath))}listMotions(t,r){return st(this.configuration).listMotions(t,r).then(n=>n(this.axios,this.basePath))}loadPlannedMotion(t,r,n){return st(this.configuration).loadPlannedMotion(t,r,n).then(a=>a(this.axios,this.basePath))}planCollisionFreePTP(t,r,n){return st(this.configuration).planCollisionFreePTP(t,r,n).then(a=>a(this.axios,this.basePath))}planMotion(t,r,n){return st(this.configuration).planMotion(t,r,n).then(a=>a(this.axios,this.basePath))}planTrajectory(t,r,n){return st(this.configuration).planTrajectory(t,r,n).then(a=>a(this.axios,this.basePath))}stopExecution(t,r,n){return st(this.configuration).stopExecution(t,r,n).then(a=>a(this.axios,this.basePath))}streamMove(t,r,n){return st(this.configuration).streamMove(t,r,n).then(a=>a(this.axios,this.basePath))}streamMoveBackward(t,r,n,a,s,o,i){return st(this.configuration).streamMoveBackward(t,r,n,a,s,o,i).then(l=>l(this.axios,this.basePath))}streamMoveForward(t,r,n,a,s,o,i){return st(this.configuration).streamMoveForward(t,r,n,a,s,o,i).then(l=>l(this.axios,this.basePath))}streamMoveToTrajectoryViaJointPTP(t,r,n,a,s,o,i,l,c,u,d){return st(this.configuration).streamMoveToTrajectoryViaJointPTP(t,r,n,a,s,o,i,l,c,u,d).then(h=>h(this.axios,this.basePath))}}const _I=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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"POST",...o,...n},l={},c={};k(i,e),await L(l,e),r!==void 0&&(c.controller=r),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"POST",...o,...n},l={},c={};k(i,e),await L(l,e),r!==void 0&&(c.motion_group=r),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}}}},Vs=function(e){const t=_I(e);return{async activateAllMotionGroups(r,n,a){var l,c;const s=await t.activateAllMotionGroups(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupApi.activateAllMotionGroups"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async activateMotionGroup(r,n,a){var l,c;const s=await t.activateMotionGroup(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupApi.activateMotionGroup"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async deactivateMotionGroup(r,n,a){var l,c;const s=await t.deactivateMotionGroup(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupApi.deactivateMotionGroup"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listMotionGroups(r,n){var i,l;const a=await t.listMotionGroups(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["MotionGroupApi.listMotionGroups"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)}}};class II extends je{activateAllMotionGroups(t,r,n){return Vs(this.configuration).activateAllMotionGroups(t,r,n).then(a=>a(this.axios,this.basePath))}activateMotionGroup(t,r,n){return Vs(this.configuration).activateMotionGroup(t,r,n).then(a=>a(this.axios,this.basePath))}deactivateMotionGroup(t,r,n){return Vs(this.configuration).deactivateMotionGroup(t,r,n).then(a=>a(this.axios,this.basePath))}listMotionGroups(t,r){return Vs(this.configuration).listMotionGroups(t,r).then(n=>n(this.axios,this.basePath))}}const MI=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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},getActiveTcp:async(t,r,n,a={})=>{v("getActiveTcp","cell",t),v("getActiveTcp","motionGroup",r);const s="/cells/{cell}/motion-groups/{motion-group}/tcps/current".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.rotation_type=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),options:l}},getCurrentMotionGroupState:async(t,r,n,a,s={})=>{v("getCurrentMotionGroupState","cell",t),v("getCurrentMotionGroupState","motionGroup",r);const o="/cells/{cell}/motion-groups/{motion-group}/state".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),i=new URL(o,j);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...s},u={},d={};k(c,e),await L(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,...s.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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},getOptimizerConfiguration:async(t,r,n,a={})=>{v("getOptimizerConfiguration","cell",t),v("getOptimizerConfiguration","motionGroup",r);const s="/cells/{cell}/motion-groups/{motion-group}/optimizer-setup".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.tcp=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},listTcps:async(t,r,n,a={})=>{v("listTcps","cell",t),v("listTcps","motionGroup",r);const s="/cells/{cell}/motion-groups/{motion-group}/tcps".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.rotation_type=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),options:l}},streamMotionGroupState:async(t,r,n,a,s,o={})=>{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,...o},d={},h={};k(u,e),await L(d,e),n!==void 0&&(h.response_rate=n),a!==void 0&&(h.response_coordinate_system=a),s!==void 0&&(h.tcp=s),U(l,h);let p=c&&c.headers?c.headers:{};return u.headers={...d,...p,...o.headers},{url:D(l),options:u}}}},jt=function(e){const t=MI(e);return{async getActivePayload(r,n,a){var l,c;const s=await t.getActivePayload(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupInfosApi.getActivePayload"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getActiveTcp(r,n,a,s){var c,u;const o=await t.getActiveTcp(r,n,a,s),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(o,_,M,e)(d,l||h)},async getCurrentMotionGroupState(r,n,a,s,o){var u,d;const i=await t.getCurrentMotionGroupState(r,n,a,s,o),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,_,M,e)(h,c||p)},async getInfoCapabilities(r,n,a){var l,c;const s=await t.getInfoCapabilities(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupInfosApi.getInfoCapabilities"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getMotionGroupSpecification(r,n,a){var l,c;const s=await t.getMotionGroupSpecification(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupInfosApi.getMotionGroupSpecification"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getMounting(r,n,a){var l,c;const s=await t.getMounting(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupInfosApi.getMounting"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getOptimizerConfiguration(r,n,a,s){var c,u;const o=await t.getOptimizerConfiguration(r,n,a,s),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(o,_,M,e)(d,l||h)},async getSafetySetup(r,n,a){var l,c;const s=await t.getSafetySetup(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupInfosApi.getSafetySetup"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listPayloads(r,n,a){var l,c;const s=await t.listPayloads(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupInfosApi.listPayloads"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listTcps(r,n,a,s){var c,u;const o=await t.listTcps(r,n,a,s),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(o,_,M,e)(d,l||h)},async streamMotionGroupState(r,n,a,s,o,i){var d,h;const l=await t.streamMotionGroupState(r,n,a,s,o,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,m)=>N(l,_,M,e)(p,u||m)}}};class $I extends je{getActivePayload(t,r,n){return jt(this.configuration).getActivePayload(t,r,n).then(a=>a(this.axios,this.basePath))}getActiveTcp(t,r,n,a){return jt(this.configuration).getActiveTcp(t,r,n,a).then(s=>s(this.axios,this.basePath))}getCurrentMotionGroupState(t,r,n,a,s){return jt(this.configuration).getCurrentMotionGroupState(t,r,n,a,s).then(o=>o(this.axios,this.basePath))}getInfoCapabilities(t,r,n){return jt(this.configuration).getInfoCapabilities(t,r,n).then(a=>a(this.axios,this.basePath))}getMotionGroupSpecification(t,r,n){return jt(this.configuration).getMotionGroupSpecification(t,r,n).then(a=>a(this.axios,this.basePath))}getMounting(t,r,n){return jt(this.configuration).getMounting(t,r,n).then(a=>a(this.axios,this.basePath))}getOptimizerConfiguration(t,r,n,a){return jt(this.configuration).getOptimizerConfiguration(t,r,n,a).then(s=>s(this.axios,this.basePath))}getSafetySetup(t,r,n){return jt(this.configuration).getSafetySetup(t,r,n).then(a=>a(this.axios,this.basePath))}listPayloads(t,r,n){return jt(this.configuration).listPayloads(t,r,n).then(a=>a(this.axios,this.basePath))}listTcps(t,r,n,a){return jt(this.configuration).listTcps(t,r,n,a).then(s=>s(this.axios,this.basePath))}streamMotionGroupState(t,r,n,a,s,o){return jt(this.configuration).streamMotionGroupState(t,r,n,a,s,o).then(i=>i(this.axios,this.basePath))}}const jI=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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="application/json",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="application/json",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"PUT",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}}}},Es=function(e){const t=jI(e);return{async directionJogging(r,n,a){var l,c;const s=await t.directionJogging(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupJoggingApi.directionJogging"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getJoggingCapabilities(r,n,a){var l,c;const s=await t.getJoggingCapabilities(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupJoggingApi.getJoggingCapabilities"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async jointJogging(r,n,a){var l,c;const s=await t.jointJogging(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupJoggingApi.jointJogging"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async stopJogging(r,n,a){var l,c;const s=await t.stopJogging(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupJoggingApi.stopJogging"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)}}};class kI extends je{directionJogging(t,r,n){return Es(this.configuration).directionJogging(t,r,n).then(a=>a(this.axios,this.basePath))}getJoggingCapabilities(t,r,n){return Es(this.configuration).getJoggingCapabilities(t,r,n).then(a=>a(this.axios,this.basePath))}jointJogging(t,r,n){return Es(this.configuration).jointJogging(t,r,n).then(a=>a(this.axios,this.basePath))}stopJogging(t,r,n){return Es(this.configuration).stopJogging(t,r,n).then(a=>a(this.axios,this.basePath))}}const LI=function(e){return{calculateAllInverseKinematic:async(t,r,n,a={})=>{v("calculateAllInverseKinematic","cell",t),v("calculateAllInverseKinematic","motionGroup",r),v("calculateAllInverseKinematic","allJointPositionsRequest",n);const s="/cells/{cell}/motion-groups/{motion-group}/kinematic/calculate-all-joint-positions".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}},calculateForwardKinematic:async(t,r,n,a={})=>{v("calculateForwardKinematic","cell",t),v("calculateForwardKinematic","motionGroup",r),v("calculateForwardKinematic","tcpPoseRequest",n);const s="/cells/{cell}/motion-groups/{motion-group}/kinematic/calculate-tcp-pose".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}},calculateInverseKinematic:async(t,r,n,a={})=>{v("calculateInverseKinematic","cell",t),v("calculateInverseKinematic","motionGroup",r),v("calculateInverseKinematic","jointPositionRequest",n);const s="/cells/{cell}/motion-groups/{motion-group}/kinematic/calculate-joint-position".replace("{cell}",encodeURIComponent(String(t))).replace("{motion-group}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}}}},_s=function(e){const t=LI(e);return{async calculateAllInverseKinematic(r,n,a,s){var c,u;const o=await t.calculateAllInverseKinematic(r,n,a,s),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(o,_,M,e)(d,l||h)},async calculateForwardKinematic(r,n,a,s){var c,u;const o=await t.calculateForwardKinematic(r,n,a,s),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(o,_,M,e)(d,l||h)},async calculateInverseKinematic(r,n,a,s){var c,u;const o=await t.calculateInverseKinematic(r,n,a,s),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(o,_,M,e)(d,l||h)},async getKinematicCapabilities(r,n,a){var l,c;const s=await t.getKinematicCapabilities(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["MotionGroupKinematicApi.getKinematicCapabilities"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)}}};class UI extends je{calculateAllInverseKinematic(t,r,n,a){return _s(this.configuration).calculateAllInverseKinematic(t,r,n,a).then(s=>s(this.axios,this.basePath))}calculateForwardKinematic(t,r,n,a){return _s(this.configuration).calculateForwardKinematic(t,r,n,a).then(s=>s(this.axios,this.basePath))}calculateInverseKinematic(t,r,n,a){return _s(this.configuration).calculateInverseKinematic(t,r,n,a).then(s=>s(this.axios,this.basePath))}getKinematicCapabilities(t,r,n){return _s(this.configuration).getKinematicCapabilities(t,r,n).then(a=>a(this.axios,this.basePath))}}const DI=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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"POST",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="text/plain",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"POST",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="application/json",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},migrateProgram:async(t,r,n={})=>{v("migrateProgram","cell",t),v("migrateProgram","request1",r);const a="/cells/{cell}/programs/migrate".replace("{cell}",encodeURIComponent(String(t))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"POST",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="text/plain",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),options:i}},planProgram:async(t,r,n,a={})=>{v("planProgram","cell",t),v("planProgram","request",r);const s="/cells/{cell}/programs/plan".replace("{cell}",encodeURIComponent(String(t))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.identifier=n),c["Content-Type"]="text/plain",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(r,l,e),{url:D(o),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 s;e&&(s=e.baseOptions);const o={method:"POST",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"POST",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}}}},vr=function(e){const t=DI(e);return{async createProgramRunner(r,n,a){var l,c;const s=await t.createProgramRunner(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramApi.createProgramRunner"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async executeProgram(r,n,a){var l,c;const s=await t.executeProgram(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramApi.executeProgram"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getProgramRunner(r,n,a){var l,c;const s=await t.getProgramRunner(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramApi.getProgramRunner"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listProgramRunners(r,n){var i,l;const a=await t.listProgramRunners(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["ProgramApi.listProgramRunners"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async migrateProgram(r,n,a){var l,c;const s=await t.migrateProgram(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramApi.migrateProgram"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async planProgram(r,n,a,s){var c,u;const o=await t.planProgram(r,n,a,s),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(o,_,M,e)(d,l||h)},async stopAllProgramRunner(r,n){var i,l;const a=await t.stopAllProgramRunner(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["ProgramApi.stopAllProgramRunner"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async stopProgramRunner(r,n,a){var l,c;const s=await t.stopProgramRunner(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramApi.stopProgramRunner"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)}}};class NI extends je{createProgramRunner(t,r,n){return vr(this.configuration).createProgramRunner(t,r,n).then(a=>a(this.axios,this.basePath))}executeProgram(t,r,n){return vr(this.configuration).executeProgram(t,r,n).then(a=>a(this.axios,this.basePath))}getProgramRunner(t,r,n){return vr(this.configuration).getProgramRunner(t,r,n).then(a=>a(this.axios,this.basePath))}listProgramRunners(t,r){return vr(this.configuration).listProgramRunners(t,r).then(n=>n(this.axios,this.basePath))}migrateProgram(t,r,n){return vr(this.configuration).migrateProgram(t,r,n).then(a=>a(this.axios,this.basePath))}planProgram(t,r,n,a){return vr(this.configuration).planProgram(t,r,n,a).then(s=>s(this.axios,this.basePath))}stopAllProgramRunner(t,r){return vr(this.configuration).stopAllProgramRunner(t,r).then(n=>n(this.axios,this.basePath))}stopProgramRunner(t,r,n){return vr(this.configuration).stopProgramRunner(t,r,n).then(a=>a(this.axios,this.basePath))}}const FI=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 s;e&&(s=e.baseOptions);const o={method:"DELETE",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},createProgramsValue:async(t,r,n={})=>{v("createProgramsValue","cell",t),v("createProgramsValue","requestBody",r);const a="/cells/{cell}/programs/values".replace("{cell}",encodeURIComponent(String(t))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"POST",...o,...n},l={},c={};k(i,e),await L(l,e),l["Content-Type"]="application/json",U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},i.data=fe(r,i,e),{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},updateProgramValue:async(t,r,n,a={})=>{v("updateProgramValue","cell",t),v("updateProgramValue","key",r),v("updateProgramValue","value",n);const s="/cells/{cell}/programs/values/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}}}},Cn=function(e){const t=FI(e);return{async clearProgramsValues(r,n){var i,l;const a=await t.clearProgramsValues(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["ProgramValuesApi.clearProgramsValues"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async createProgramsValue(r,n,a){var l,c;const s=await t.createProgramsValue(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramValuesApi.createProgramsValue"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async deleteProgramValue(r,n,a){var l,c;const s=await t.deleteProgramValue(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramValuesApi.deleteProgramValue"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getProgramValue(r,n,a){var l,c;const s=await t.getProgramValue(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["ProgramValuesApi.getProgramValue"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listProgramsValues(r,n){var i,l;const a=await t.listProgramsValues(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["ProgramValuesApi.listProgramsValues"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async updateProgramValue(r,n,a,s){var c,u;const o=await t.updateProgramValue(r,n,a,s),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(o,_,M,e)(d,l||h)}}};class BI extends je{clearProgramsValues(t,r){return Cn(this.configuration).clearProgramsValues(t,r).then(n=>n(this.axios,this.basePath))}createProgramsValue(t,r,n){return Cn(this.configuration).createProgramsValue(t,r,n).then(a=>a(this.axios,this.basePath))}deleteProgramValue(t,r,n){return Cn(this.configuration).deleteProgramValue(t,r,n).then(a=>a(this.axios,this.basePath))}getProgramValue(t,r,n){return Cn(this.configuration).getProgramValue(t,r,n).then(a=>a(this.axios,this.basePath))}listProgramsValues(t,r){return Cn(this.configuration).listProgramsValues(t,r).then(n=>n(this.axios,this.basePath))}updateProgramValue(t,r,n,a){return Cn(this.configuration).updateProgramValue(t,r,n,a).then(s=>s(this.axios,this.basePath))}}const zI=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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},storeCollider:async(t,r,n,a={})=>{v("storeCollider","cell",t),v("storeCollider","collider",r),v("storeCollider","collider2",n);const s="/cells/{cell}/store/collision/colliders/{collider}".replace("{cell}",encodeURIComponent(String(t))).replace("{collider}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}},storeCollisionLinkChain:async(t,r,n,a={})=>{v("storeCollisionLinkChain","cell",t),v("storeCollisionLinkChain","linkChain",r),v("storeCollisionLinkChain","collider",n);const s="/cells/{cell}/store/collision/link-chains/{link-chain}".replace("{cell}",encodeURIComponent(String(t))).replace("{link-chain}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}},storeCollisionTool:async(t,r,n,a={})=>{v("storeCollisionTool","cell",t),v("storeCollisionTool","tool",r),v("storeCollisionTool","requestBody",n);const s="/cells/{cell}/store/collision/tools/{tool}".replace("{cell}",encodeURIComponent(String(t))).replace("{tool}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}}}},Ot=function(e){const t=zI(e);return{async deleteStoredCollider(r,n,a){var l,c;const s=await t.deleteStoredCollider(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.deleteStoredCollider"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async deleteStoredCollisionLinkChain(r,n,a){var l,c;const s=await t.deleteStoredCollisionLinkChain(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.deleteStoredCollisionLinkChain"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async deleteStoredCollisionTool(r,n,a){var l,c;const s=await t.deleteStoredCollisionTool(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.deleteStoredCollisionTool"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getDefaultLinkChain(r,n,a){var l,c;const s=await t.getDefaultLinkChain(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.getDefaultLinkChain"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getStoredCollider(r,n,a){var l,c;const s=await t.getStoredCollider(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.getStoredCollider"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getStoredCollisionLinkChain(r,n,a){var l,c;const s=await t.getStoredCollisionLinkChain(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.getStoredCollisionLinkChain"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getStoredCollisionTool(r,n,a){var l,c;const s=await t.getStoredCollisionTool(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionComponentsApi.getStoredCollisionTool"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listCollisionLinkChains(r,n){var i,l;const a=await t.listCollisionLinkChains(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["StoreCollisionComponentsApi.listCollisionLinkChains"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async listStoredColliders(r,n){var i,l;const a=await t.listStoredColliders(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["StoreCollisionComponentsApi.listStoredColliders"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async listStoredCollisionTools(r,n){var i,l;const a=await t.listStoredCollisionTools(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["StoreCollisionComponentsApi.listStoredCollisionTools"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async storeCollider(r,n,a,s){var c,u;const o=await t.storeCollider(r,n,a,s),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(o,_,M,e)(d,l||h)},async storeCollisionLinkChain(r,n,a,s){var c,u;const o=await t.storeCollisionLinkChain(r,n,a,s),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(o,_,M,e)(d,l||h)},async storeCollisionTool(r,n,a,s){var c,u;const o=await t.storeCollisionTool(r,n,a,s),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(o,_,M,e)(d,l||h)}}};class GI extends je{deleteStoredCollider(t,r,n){return Ot(this.configuration).deleteStoredCollider(t,r,n).then(a=>a(this.axios,this.basePath))}deleteStoredCollisionLinkChain(t,r,n){return Ot(this.configuration).deleteStoredCollisionLinkChain(t,r,n).then(a=>a(this.axios,this.basePath))}deleteStoredCollisionTool(t,r,n){return Ot(this.configuration).deleteStoredCollisionTool(t,r,n).then(a=>a(this.axios,this.basePath))}getDefaultLinkChain(t,r,n){return Ot(this.configuration).getDefaultLinkChain(t,r,n).then(a=>a(this.axios,this.basePath))}getStoredCollider(t,r,n){return Ot(this.configuration).getStoredCollider(t,r,n).then(a=>a(this.axios,this.basePath))}getStoredCollisionLinkChain(t,r,n){return Ot(this.configuration).getStoredCollisionLinkChain(t,r,n).then(a=>a(this.axios,this.basePath))}getStoredCollisionTool(t,r,n){return Ot(this.configuration).getStoredCollisionTool(t,r,n).then(a=>a(this.axios,this.basePath))}listCollisionLinkChains(t,r){return Ot(this.configuration).listCollisionLinkChains(t,r).then(n=>n(this.axios,this.basePath))}listStoredColliders(t,r){return Ot(this.configuration).listStoredColliders(t,r).then(n=>n(this.axios,this.basePath))}listStoredCollisionTools(t,r){return Ot(this.configuration).listStoredCollisionTools(t,r).then(n=>n(this.axios,this.basePath))}storeCollider(t,r,n,a){return Ot(this.configuration).storeCollider(t,r,n,a).then(s=>s(this.axios,this.basePath))}storeCollisionLinkChain(t,r,n,a){return Ot(this.configuration).storeCollisionLinkChain(t,r,n,a).then(s=>s(this.axios,this.basePath))}storeCollisionTool(t,r,n,a){return Ot(this.configuration).storeCollisionTool(t,r,n,a).then(s=>s(this.axios,this.basePath))}}const HI=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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},storeCollisionScene:async(t,r,n,a={})=>{v("storeCollisionScene","cell",t),v("storeCollisionScene","scene",r),v("storeCollisionScene","collisionSceneAssembly",n);const s="/cells/{cell}/store/collision/scenes/{scene}".replace("{cell}",encodeURIComponent(String(t))).replace("{scene}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}}}},Is=function(e){const t=HI(e);return{async deleteStoredCollisionScene(r,n,a){var l,c;const s=await t.deleteStoredCollisionScene(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionScenesApi.deleteStoredCollisionScene"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getStoredCollisionScene(r,n,a){var l,c;const s=await t.getStoredCollisionScene(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreCollisionScenesApi.getStoredCollisionScene"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listStoredCollisionScenes(r,n){var i,l;const a=await t.listStoredCollisionScenes(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["StoreCollisionScenesApi.listStoredCollisionScenes"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async storeCollisionScene(r,n,a,s){var c,u;const o=await t.storeCollisionScene(r,n,a,s),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(o,_,M,e)(d,l||h)}}};class qI extends je{deleteStoredCollisionScene(t,r,n){return Is(this.configuration).deleteStoredCollisionScene(t,r,n).then(a=>a(this.axios,this.basePath))}getStoredCollisionScene(t,r,n){return Is(this.configuration).getStoredCollisionScene(t,r,n).then(a=>a(this.axios,this.basePath))}listStoredCollisionScenes(t,r){return Is(this.configuration).listStoredCollisionScenes(t,r).then(n=>n(this.axios,this.basePath))}storeCollisionScene(t,r,n,a){return Is(this.configuration).storeCollisionScene(t,r,n,a).then(s=>s(this.axios,this.basePath))}}const JI=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 s;e&&(s=e.baseOptions);const o={method:"DELETE",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"DELETE",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"HEAD",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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 s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},storeObject:async(t,r,n,a,s={})=>{v("storeObject","cell",t),v("storeObject","key",r);const o="/cells/{cell}/store/objects/{key}".replace("{cell}",encodeURIComponent(String(t))).replace("{key}",encodeURIComponent(String(r))),i=new URL(o,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...s},u={},d={},h=new(e&&e.formDataCtor||FormData);k(c,e),await L(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,...s.headers},c.data=h,{url:D(i),options:c}}}},Pn=function(e){const t=JI(e);return{async clearAllObjects(r,n){var i,l;const a=await t.clearAllObjects(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["StoreObjectApi.clearAllObjects"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async deleteObject(r,n,a){var l,c;const s=await t.deleteObject(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreObjectApi.deleteObject"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getObject(r,n,a){var l,c;const s=await t.getObject(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreObjectApi.getObject"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getObjectMetadata(r,n,a){var l,c;const s=await t.getObjectMetadata(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["StoreObjectApi.getObjectMetadata"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listAllObjectKeys(r,n){var i,l;const a=await t.listAllObjectKeys(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["StoreObjectApi.listAllObjectKeys"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async storeObject(r,n,a,s,o){var u,d;const i=await t.storeObject(r,n,a,s,o),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,_,M,e)(h,c||p)}}};class WI extends je{clearAllObjects(t,r){return Pn(this.configuration).clearAllObjects(t,r).then(n=>n(this.axios,this.basePath))}deleteObject(t,r,n){return Pn(this.configuration).deleteObject(t,r,n).then(a=>a(this.axios,this.basePath))}getObject(t,r,n){return Pn(this.configuration).getObject(t,r,n).then(a=>a(this.axios,this.basePath))}getObjectMetadata(t,r,n){return Pn(this.configuration).getObjectMetadata(t,r,n).then(a=>a(this.axios,this.basePath))}listAllObjectKeys(t,r){return Pn(this.configuration).listAllObjectKeys(t,r).then(n=>n(this.axios,this.basePath))}storeObject(t,r,n,a,s){return Pn(this.configuration).storeObject(t,r,n,a,s).then(o=>o(this.axios,this.basePath))}}const KI=function(e){return{checkNovaVersionUpdate:async(t,r={})=>{v("checkNovaVersionUpdate","channel",t);const n="/system/update",a=new URL(n,j);let s;e&&(s=e.baseOptions);const o={method:"GET",...s,...r},i={},l={};k(o,e),await L(i,e),t!==void 0&&(l.channel=t),U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},{url:D(a),options:o}},getDiagnosePackage:async(t={})=>{const r="/system/diagnosis-package/zip",n=new URL(r,j);let a;e&&(a=e.baseOptions);const s={method:"GET",...a,...t},o={},i={};k(s,e),await L(o,e),U(n,i);let l=a&&a.headers?a.headers:{};return s.headers={...o,...l,...t.headers},{url:D(n),options:s}},getSystemStatus:async(t={})=>{const r="/system/status",n=new URL(r,j);let a;e&&(a=e.baseOptions);const s={method:"GET",...a,...t},o={},i={};k(s,e),await L(o,e),U(n,i);let l=a&&a.headers?a.headers:{};return s.headers={...o,...l,...t.headers},{url:D(n),options:s}},getSystemVersion:async(t={})=>{const r="/system/version",n=new URL(r,j);let a;e&&(a=e.baseOptions);const s={method:"GET",...a,...t},o={},i={};k(s,e),await L(o,e),U(n,i);let l=a&&a.headers?a.headers:{};return s.headers={...o,...l,...t.headers},{url:D(n),options:s}},updateNovaVersion:async(t,r={})=>{v("updateNovaVersion","updateNovaVersionRequest",t);const n="/system/update",a=new URL(n,j);let s;e&&(s=e.baseOptions);const o={method:"PUT",...s,...r},i={},l={};k(o,e),await L(i,e),i["Content-Type"]="application/json",U(a,l);let c=s&&s.headers?s.headers:{};return o.headers={...i,...c,...r.headers},o.data=fe(t,o,e),{url:D(a),options:o}}}},Ra=function(e){const t=KI(e);return{async checkNovaVersionUpdate(r,n){var i,l;const a=await t.checkNovaVersionUpdate(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["SystemApi.checkNovaVersionUpdate"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)},async getDiagnosePackage(r){var o,i;const n=await t.getDiagnosePackage(r),a=(e==null?void 0:e.serverIndex)??0,s=(i=(o=$["SystemApi.getDiagnosePackage"])==null?void 0:o[a])==null?void 0:i.url;return(l,c)=>N(n,_,M,e)(l,s||c)},async getSystemStatus(r){var o,i;const n=await t.getSystemStatus(r),a=(e==null?void 0:e.serverIndex)??0,s=(i=(o=$["SystemApi.getSystemStatus"])==null?void 0:o[a])==null?void 0:i.url;return(l,c)=>N(n,_,M,e)(l,s||c)},async getSystemVersion(r){var o,i;const n=await t.getSystemVersion(r),a=(e==null?void 0:e.serverIndex)??0,s=(i=(o=$["SystemApi.getSystemVersion"])==null?void 0:o[a])==null?void 0:i.url;return(l,c)=>N(n,_,M,e)(l,s||c)},async updateNovaVersion(r,n){var i,l;const a=await t.updateNovaVersion(r,n),s=(e==null?void 0:e.serverIndex)??0,o=(l=(i=$["SystemApi.updateNovaVersion"])==null?void 0:i[s])==null?void 0:l.url;return(c,u)=>N(a,_,M,e)(c,o||u)}}};class YI extends je{checkNovaVersionUpdate(t,r){return Ra(this.configuration).checkNovaVersionUpdate(t,r).then(n=>n(this.axios,this.basePath))}getDiagnosePackage(t){return Ra(this.configuration).getDiagnosePackage(t).then(r=>r(this.axios,this.basePath))}getSystemStatus(t){return Ra(this.configuration).getSystemStatus(t).then(r=>r(this.axios,this.basePath))}getSystemVersion(t){return Ra(this.configuration).getSystemVersion(t).then(r=>r(this.axios,this.basePath))}updateNovaVersion(t,r){return Ra(this.configuration).updateNovaVersion(t,r).then(n=>n(this.axios,this.basePath))}}const QI=function(e){return{getMotionGroupState:async(t,r,n,a={})=>{v("getMotionGroupState","cell",t),v("getMotionGroupState","controller",r),v("getMotionGroupState","id",n);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))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},getVirtualRobotIOValue:async(t,r,n,a={})=>{v("getVirtualRobotIOValue","cell",t),v("getVirtualRobotIOValue","controller",r),v("getVirtualRobotIOValue","io",n);const s="/cells/{cell}/controllers/{controller}/teach-pendant/ios/{io}".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))).replace("{io}",encodeURIComponent(String(n))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},setMotionGroupState:async(t,r,n,a,s={})=>{v("setMotionGroupState","cell",t),v("setMotionGroupState","controller",r),v("setMotionGroupState","id",n),v("setMotionGroupState","motionGroupJoints",a);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))),i=new URL(o,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...s},u={},d={};k(c,e),await L(u,e),u["Content-Type"]="application/json",U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...s.headers},c.data=fe(a,c,e),{url:D(i),options:c}},setVirtualRobotIOValue:async(t,r,n,a,s,o,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 L(h,e),a!==void 0&&(p.bool=a),s!==void 0&&(p.integer=s),o!==void 0&&(p.double=o),U(c,p);let m=u&&u.headers?u.headers:{};return d.headers={...h,...m,...i.headers},{url:D(c),options:d}}}},Rn=function(e){const t=QI(e);return{async getMotionGroupState(r,n,a,s){var c,u;const o=await t.getMotionGroupState(r,n,a,s),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(o,_,M,e)(d,l||h)},async getMotionGroups(r,n,a){var l,c;const s=await t.getMotionGroups(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotApi.getMotionGroups"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getVirtualRobotIOValue(r,n,a,s){var c,u;const o=await t.getVirtualRobotIOValue(r,n,a,s),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(o,_,M,e)(d,l||h)},async listIOs(r,n,a){var l,c;const s=await t.listIOs(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotApi.listIOs"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async setMotionGroupState(r,n,a,s,o){var u,d;const i=await t.setMotionGroupState(r,n,a,s,o),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,_,M,e)(h,c||p)},async setVirtualRobotIOValue(r,n,a,s,o,i,l){var h,p;const c=await t.setVirtualRobotIOValue(r,n,a,s,o,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(m,f)=>N(c,_,M,e)(m,d||f)}}};class XI extends je{getMotionGroupState(t,r,n,a){return Rn(this.configuration).getMotionGroupState(t,r,n,a).then(s=>s(this.axios,this.basePath))}getMotionGroups(t,r,n){return Rn(this.configuration).getMotionGroups(t,r,n).then(a=>a(this.axios,this.basePath))}getVirtualRobotIOValue(t,r,n,a){return Rn(this.configuration).getVirtualRobotIOValue(t,r,n,a).then(s=>s(this.axios,this.basePath))}listIOs(t,r,n){return Rn(this.configuration).listIOs(t,r,n).then(a=>a(this.axios,this.basePath))}setMotionGroupState(t,r,n,a,s){return Rn(this.configuration).setMotionGroupState(t,r,n,a,s).then(o=>o(this.axios,this.basePath))}setVirtualRobotIOValue(t,r,n,a,s,o,i){return Rn(this.configuration).setVirtualRobotIOValue(t,r,n,a,s,o,i).then(l=>l(this.axios,this.basePath))}}const ZI=function(e){return{externalJointsStream:async(t,r,n,a={})=>{v("externalJointsStream","cell",t),v("externalJointsStream","controller",r),v("externalJointsStream","externalJointStreamDatapoint",n);const s="/cells/{cell}/controllers/{controller}/teach-pendant/motion-groups/externalJointsStream".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}},getMotionGroupBehavior:async(t,r,n,a={})=>{v("getMotionGroupBehavior","cell",t),v("getMotionGroupBehavior","controller",r),v("getMotionGroupBehavior","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))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),options:l}},setMotionGroupBehavior:async(t,r,n,a,s={})=>{v("setMotionGroupBehavior","cell",t),v("setMotionGroupBehavior","controller",r),v("setMotionGroupBehavior","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))),i=new URL(o,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...s},u={},d={};k(c,e),await L(u,e),a!==void 0&&(d.behavior=a),U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...s.headers},{url:D(i),options:c}}}},ll=function(e){const t=ZI(e);return{async externalJointsStream(r,n,a,s){var c,u;const o=await t.externalJointsStream(r,n,a,s),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(o,_,M,e)(d,l||h)},async getMotionGroupBehavior(r,n,a,s){var c,u;const o=await t.getMotionGroupBehavior(r,n,a,s),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(o,_,M,e)(d,l||h)},async setMotionGroupBehavior(r,n,a,s,o){var u,d;const i=await t.setMotionGroupBehavior(r,n,a,s,o),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,_,M,e)(h,c||p)}}};class e2 extends je{externalJointsStream(t,r,n,a){return ll(this.configuration).externalJointsStream(t,r,n,a).then(s=>s(this.axios,this.basePath))}getMotionGroupBehavior(t,r,n,a){return ll(this.configuration).getMotionGroupBehavior(t,r,n,a).then(s=>s(this.axios,this.basePath))}setMotionGroupBehavior(t,r,n,a,s){return ll(this.configuration).setMotionGroupBehavior(t,r,n,a,s).then(o=>o(this.axios,this.basePath))}}const t2=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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"PUT",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"PUT",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},setOperationMode:async(t,r,n,a={})=>{v("setOperationMode","cell",t),v("setOperationMode","controller",r),v("setOperationMode","mode",n);const s="/cells/{cell}/controllers/{controller}/teach-pendant/operationmode".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),n!==void 0&&(u.mode=n),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),options:l}}}},Tn=function(e){const t=t2(e);return{async getCycleTime(r,n,a){var l,c;const s=await t.getCycleTime(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotModeApi.getCycleTime"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getEStop(r,n,a){var l,c;const s=await t.getEStop(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotModeApi.getEStop"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async getOperationMode(r,n,a){var l,c;const s=await t.getOperationMode(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotModeApi.getOperationMode"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async pushEStop(r,n,a){var l,c;const s=await t.pushEStop(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotModeApi.pushEStop"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async releaseEStop(r,n,a){var l,c;const s=await t.releaseEStop(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotModeApi.releaseEStop"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async setOperationMode(r,n,a,s){var c,u;const o=await t.setOperationMode(r,n,a,s),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(o,_,M,e)(d,l||h)}}};class r2 extends je{getCycleTime(t,r,n){return Tn(this.configuration).getCycleTime(t,r,n).then(a=>a(this.axios,this.basePath))}getEStop(t,r,n){return Tn(this.configuration).getEStop(t,r,n).then(a=>a(this.axios,this.basePath))}getOperationMode(t,r,n){return Tn(this.configuration).getOperationMode(t,r,n).then(a=>a(this.axios,this.basePath))}pushEStop(t,r,n){return Tn(this.configuration).pushEStop(t,r,n).then(a=>a(this.axios,this.basePath))}releaseEStop(t,r,n){return Tn(this.configuration).releaseEStop(t,r,n).then(a=>a(this.axios,this.basePath))}setOperationMode(t,r,n,a){return Tn(this.configuration).setOperationMode(t,r,n,a).then(s=>s(this.axios,this.basePath))}}const n2=function(e){return{addVirtualRobotCoordinateSystem:async(t,r,n,a={})=>{v("addVirtualRobotCoordinateSystem","cell",t),v("addVirtualRobotCoordinateSystem","controller",r),v("addVirtualRobotCoordinateSystem","coordinateSystem",n);const s="/cells/{cell}/controllers/{controller}/teach-pendant/coordinate-systems".replace("{cell}",encodeURIComponent(String(t))).replace("{controller}",encodeURIComponent(String(r))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...a},c={},u={};k(l,e),await L(c,e),c["Content-Type"]="application/json",U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},l.data=fe(n,l,e),{url:D(o),options:l}},addVirtualRobotTcp:async(t,r,n,a,s={})=>{v("addVirtualRobotTcp","cell",t),v("addVirtualRobotTcp","controller",r),v("addVirtualRobotTcp","id",n),v("addVirtualRobotTcp","robotTcp",a);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))),i=new URL(o,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...s},u={},d={};k(c,e),await L(u,e),u["Content-Type"]="application/json",U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...s.headers},c.data=fe(a,c,e),{url:D(i),options:c}},deleteVirtualRobotCoordinateSystem:async(t,r,n,a,s={})=>{v("deleteVirtualRobotCoordinateSystem","cell",t),v("deleteVirtualRobotCoordinateSystem","controller",r),v("deleteVirtualRobotCoordinateSystem","coordinateSystem",n);const o="/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(o,j);let l;e&&(l=e.baseOptions);const c={method:"DELETE",...l,...s},u={},d={};k(c,e),await L(u,e),a!==void 0&&(d.delete_dependent=a),U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...s.headers},{url:D(i),options:c}},deleteVirtualRobotTcp:async(t,r,n,a,s={})=>{v("deleteVirtualRobotTcp","cell",t),v("deleteVirtualRobotTcp","controller",r),v("deleteVirtualRobotTcp","id",n),v("deleteVirtualRobotTcp","tcp",a);const o="/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(o,j);let l;e&&(l=e.baseOptions);const c={method:"DELETE",...l,...s},u={},d={};k(c,e),await L(u,e),U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...s.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 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))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),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))),s=new URL(a,j);let o;e&&(o=e.baseOptions);const i={method:"GET",...o,...n},l={},c={};k(i,e),await L(l,e),U(s,c);let u=o&&o.headers?o.headers:{};return i.headers={...l,...u,...n.headers},{url:D(s),options:i}},listVirtualRobotTcps:async(t,r,n,a={})=>{v("listVirtualRobotTcps","cell",t),v("listVirtualRobotTcps","controller",r),v("listVirtualRobotTcps","id",n);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))),o=new URL(s,j);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...a},c={},u={};k(l,e),await L(c,e),U(o,u);let d=i&&i.headers?i.headers:{};return l.headers={...c,...d,...a.headers},{url:D(o),options:l}},setVirtualRobotMounting:async(t,r,n,a,s={})=>{v("setVirtualRobotMounting","cell",t),v("setVirtualRobotMounting","controller",r),v("setVirtualRobotMounting","id",n),v("setVirtualRobotMounting","coordinateSystem",a);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))),i=new URL(o,j);let l;e&&(l=e.baseOptions);const c={method:"PUT",...l,...s},u={},d={};k(c,e),await L(u,e),u["Content-Type"]="application/json",U(i,d);let h=l&&l.headers?l.headers:{};return c.headers={...u,...h,...s.headers},c.data=fe(a,c,e),{url:D(i),options:c}}}},xr=function(e){const t=n2(e);return{async addVirtualRobotCoordinateSystem(r,n,a,s){var c,u;const o=await t.addVirtualRobotCoordinateSystem(r,n,a,s),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(o,_,M,e)(d,l||h)},async addVirtualRobotTcp(r,n,a,s,o){var u,d;const i=await t.addVirtualRobotTcp(r,n,a,s,o),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,_,M,e)(h,c||p)},async deleteVirtualRobotCoordinateSystem(r,n,a,s,o){var u,d;const i=await t.deleteVirtualRobotCoordinateSystem(r,n,a,s,o),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,_,M,e)(h,c||p)},async deleteVirtualRobotTcp(r,n,a,s,o){var u,d;const i=await t.deleteVirtualRobotTcp(r,n,a,s,o),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,_,M,e)(h,c||p)},async getVirtualRobotMounting(r,n,a,s){var c,u;const o=await t.getVirtualRobotMounting(r,n,a,s),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(o,_,M,e)(d,l||h)},async listVirtualRobotCoordinateSystems(r,n,a){var l,c;const s=await t.listVirtualRobotCoordinateSystems(r,n,a),o=(e==null?void 0:e.serverIndex)??0,i=(c=(l=$["VirtualRobotSetupApi.listVirtualRobotCoordinateSystems"])==null?void 0:l[o])==null?void 0:c.url;return(u,d)=>N(s,_,M,e)(u,i||d)},async listVirtualRobotTcps(r,n,a,s){var c,u;const o=await t.listVirtualRobotTcps(r,n,a,s),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(o,_,M,e)(d,l||h)},async setVirtualRobotMounting(r,n,a,s,o){var u,d;const i=await t.setVirtualRobotMounting(r,n,a,s,o),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,_,M,e)(h,c||p)}}};class a2 extends je{addVirtualRobotCoordinateSystem(t,r,n,a){return xr(this.configuration).addVirtualRobotCoordinateSystem(t,r,n,a).then(s=>s(this.axios,this.basePath))}addVirtualRobotTcp(t,r,n,a,s){return xr(this.configuration).addVirtualRobotTcp(t,r,n,a,s).then(o=>o(this.axios,this.basePath))}deleteVirtualRobotCoordinateSystem(t,r,n,a,s){return xr(this.configuration).deleteVirtualRobotCoordinateSystem(t,r,n,a,s).then(o=>o(this.axios,this.basePath))}deleteVirtualRobotTcp(t,r,n,a,s){return xr(this.configuration).deleteVirtualRobotTcp(t,r,n,a,s).then(o=>o(this.axios,this.basePath))}getVirtualRobotMounting(t,r,n,a){return xr(this.configuration).getVirtualRobotMounting(t,r,n,a).then(s=>s(this.axios,this.basePath))}listVirtualRobotCoordinateSystems(t,r,n){return xr(this.configuration).listVirtualRobotCoordinateSystems(t,r,n).then(a=>a(this.axios,this.basePath))}listVirtualRobotTcps(t,r,n,a){return xr(this.configuration).listVirtualRobotTcps(t,r,n,a).then(s=>s(this.axios,this.basePath))}setVirtualRobotMounting(t,r,n,a,s){return xr(this.configuration).setVirtualRobotMounting(t,r,n,a,s).then(o=>o(this.axios,this.basePath))}}function rr(e,t,r){return Math.max(t,Math.min(r,e))}class s2{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,s,o,i){let l=n[a+0],c=n[a+1],u=n[a+2],d=n[a+3];const h=s[o+0],p=s[o+1],m=s[o+2],f=s[o+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]=m,t[r+3]=f;return}if(d!==f||l!==h||c!==p||u!==m){let g=1-i;const S=l*h+c*p+u*m+d*f,T=S>=0?1:-1,O=1-S*S;if(O>Number.EPSILON){const V=Math.sqrt(O),R=Math.atan2(V,S*T);g=Math.sin(g*R)/V,i=Math.sin(i*R)/V}const C=i*T;if(l=l*g+h*C,c=c*g+p*C,u=u*g+m*C,d=d*g+f*C,g===1-i){const V=1/Math.sqrt(l*l+c*c+u*u+d*d);l*=V,c*=V,u*=V,d*=V}}t[r]=l,t[r+1]=c,t[r+2]=u,t[r+3]=d}static multiplyQuaternionsFlat(t,r,n,a,s,o){const i=n[a],l=n[a+1],c=n[a+2],u=n[a+3],d=s[o],h=s[o+1],p=s[o+2],m=s[o+3];return t[r]=i*m+u*d+l*p-c*h,t[r+1]=l*m+u*h+c*d-i*p,t[r+2]=c*m+u*p+i*h-l*d,t[r+3]=u*m-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,s=t._z,o=t._order,i=Math.cos,l=Math.sin,c=i(n/2),u=i(a/2),d=i(s/2),h=l(n/2),p=l(a/2),m=l(s/2);switch(o){case"XYZ":this._x=h*u*d+c*p*m,this._y=c*p*d-h*u*m,this._z=c*u*m+h*p*d,this._w=c*u*d-h*p*m;break;case"YXZ":this._x=h*u*d+c*p*m,this._y=c*p*d-h*u*m,this._z=c*u*m-h*p*d,this._w=c*u*d+h*p*m;break;case"ZXY":this._x=h*u*d-c*p*m,this._y=c*p*d+h*u*m,this._z=c*u*m+h*p*d,this._w=c*u*d-h*p*m;break;case"ZYX":this._x=h*u*d-c*p*m,this._y=c*p*d+h*u*m,this._z=c*u*m-h*p*d,this._w=c*u*d+h*p*m;break;case"YZX":this._x=h*u*d+c*p*m,this._y=c*p*d+h*u*m,this._z=c*u*m-h*p*d,this._w=c*u*d-h*p*m;break;case"XZY":this._x=h*u*d-c*p*m,this._y=c*p*d-h*u*m,this._z=c*u*m+h*p*d,this._w=c*u*d+h*p*m;break;default:console.warn("THREE.Quaternion: .setFromEuler() encountered an unknown order: "+o)}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],s=r[8],o=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=(s-c)*p,this._z=(o-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+o)/p,this._z=(s+c)/p}else if(i>d){const p=2*Math.sqrt(1+i-n-d);this._w=(s-c)/p,this._x=(a+o)/p,this._y=.25*p,this._z=(l+u)/p}else{const p=2*Math.sqrt(1+d-n-i);this._w=(o-a)/p,this._x=(s+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(rr(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,s=t._z,o=t._w,i=r._x,l=r._y,c=r._z,u=r._w;return this._x=n*u+o*i+a*c-s*l,this._y=a*u+o*l+s*i-n*c,this._z=s*u+o*c+n*l-a*i,this._w=o*u-n*i-a*l-s*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,s=this._z,o=this._w;let i=o*t._w+n*t._x+a*t._y+s*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=o,this._x=n,this._y=a,this._z=s,this;const l=1-i*i;if(l<=Number.EPSILON){const p=1-r;return this._w=p*o+r*this._w,this._x=p*n+r*this._x,this._y=p*a+r*this._y,this._z=p*s+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=o*d+this._w*h,this._x=n*d+this._x*h,this._y=a*d+this._y*h,this._z=s*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),s=Math.sqrt(n);return this.set(a*Math.sin(t),a*Math.cos(t),s*Math.sin(r),s*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(Jh.setFromEuler(t))}applyAxisAngle(t,r){return this.applyQuaternion(Jh.setFromAxisAngle(t,r))}applyMatrix3(t){const r=this.x,n=this.y,a=this.z,s=t.elements;return this.x=s[0]*r+s[3]*n+s[6]*a,this.y=s[1]*r+s[4]*n+s[7]*a,this.z=s[2]*r+s[5]*n+s[8]*a,this}applyNormalMatrix(t){return this.applyMatrix3(t).normalize()}applyMatrix4(t){const r=this.x,n=this.y,a=this.z,s=t.elements,o=1/(s[3]*r+s[7]*n+s[11]*a+s[15]);return this.x=(s[0]*r+s[4]*n+s[8]*a+s[12])*o,this.y=(s[1]*r+s[5]*n+s[9]*a+s[13])*o,this.z=(s[2]*r+s[6]*n+s[10]*a+s[14])*o,this}applyQuaternion(t){const r=this.x,n=this.y,a=this.z,s=t.x,o=t.y,i=t.z,l=t.w,c=2*(o*a-i*n),u=2*(i*r-s*a),d=2*(s*n-o*r);return this.x=r+l*c+o*d-i*u,this.y=n+l*u+i*c-s*d,this.z=a+l*d+s*u-o*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,s=t.elements;return this.x=s[0]*r+s[4]*n+s[8]*a,this.y=s[1]*r+s[5]*n+s[9]*a,this.z=s[2]*r+s[6]*n+s[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=rr(this.x,t.x,r.x),this.y=rr(this.y,t.y,r.y),this.z=rr(this.z,t.z,r.z),this}clampScalar(t,r){return this.x=rr(this.x,t,r),this.y=rr(this.y,t,r),this.z=rr(this.z,t,r),this}clampLength(t,r){const n=this.length();return this.divideScalar(n||1).multiplyScalar(rr(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,s=t.z,o=r.x,i=r.y,l=r.z;return this.x=a*l-s*i,this.y=s*o-n*l,this.z=n*i-a*o,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 cl.copy(this).projectOnVector(t),this.sub(cl)}reflect(t){return this.sub(cl.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(rr(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 cl=new Ln,Jh=new s2;function o2(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 s=t.join("/");s=s.replace(/\/(\?|&|#[^!])/g,"$1");var o=s.split("?");return s=o.shift()+(o.length>0?"?":"")+o.join("&"),s}function ul(){var e;return typeof arguments[0]=="object"?e=arguments[0]:e=[].slice.call(arguments),o2(e)}var Jt={},Wh;function i2(){if(Wh)return Jt;Wh=1,Object.defineProperty(Jt,"__esModule",{value:!0}),Jt.TokenData=void 0,Jt.parse=d,Jt.compile=h,Jt.match=f,Jt.pathToRegexp=g,Jt.stringify=C;const e="/",t=P=>P,r=/^[$_\p{ID_Start}]$/u,n=/^[$\u200c\u200d\p{ID_Continue}]$/u,a="https://git.new/pathToRegexpError",s={"{":"{","}":"}","(":"(",")":")","[":"[","]":"]","+":"+","?":"?","!":"!"};function o(P){return P.replace(/[{}()\[\]+?!:*]/g,"\\$&")}function i(P){return P.replace(/[.+*?^${}()[\]|/\\]/g,"\\$&")}function*l(P){const E=[...P];let B=0;function y(){let A="";if(r.test(E[++B]))for(A+=E[B];n.test(E[++B]);)A+=E[B];else if(E[B]==='"'){let z=B;for(;B<E.length;){if(E[++B]==='"'){B++,z=0;break}E[B]==="\\"?A+=E[++B]:A+=E[B]}if(z)throw new TypeError(`Unterminated quote at ${z}: ${a}`)}if(!A)throw new TypeError(`Missing parameter name at ${B}: ${a}`);return A}for(;B<E.length;){const A=E[B],z=s[A];if(z)yield{type:z,index:B++,value:A};else if(A==="\\")yield{type:"ESCAPED",index:B++,value:E[B++]};else if(A===":"){const I=y();yield{type:"PARAM",index:B,value:I}}else if(A==="*"){const I=y();yield{type:"WILDCARD",index:B,value:I}}else yield{type:"CHAR",index:B,value:E[B++]}}return{type:"END",index:B,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 B=this.peek();if(B.type===E)return this._peek=void 0,B.value}consume(E){const B=this.tryConsume(E);if(B!==void 0)return B;const{type:y,index:A}=this.peek();throw new TypeError(`Unexpected ${y} at ${A}, expected ${E}: ${a}`)}text(){let E="",B;for(;B=this.tryConsume("CHAR")||this.tryConsume("ESCAPED");)E+=B;return E}}class u{constructor(E){this.tokens=E}}Jt.TokenData=u;function d(P,E={}){const{encodePath:B=t}=E,y=new c(l(P));function A(I){const G=[];for(;;){const re=y.text();re&&G.push({type:"text",value:B(re)});const te=y.tryConsume("PARAM");if(te){G.push({type:"param",name:te});continue}const oe=y.tryConsume("WILDCARD");if(oe){G.push({type:"wildcard",name:oe});continue}if(y.tryConsume("{")){G.push({type:"group",tokens:A("}")});continue}return y.consume(I),G}}const z=A("END");return new u(z)}function h(P,E={}){const{encode:B=encodeURIComponent,delimiter:y=e}=E,A=P instanceof u?P:d(P,E),z=p(A.tokens,y,B);return function(G={}){const[re,...te]=z(G);if(te.length)throw new TypeError(`Missing parameters: ${te.join(", ")}`);return re}}function p(P,E,B){const y=P.map(A=>m(A,E,B));return A=>{const z=[""];for(const I of y){const[G,...re]=I(A);z[0]+=G,z.push(...re)}return z}}function m(P,E,B){if(P.type==="text")return()=>[P.value];if(P.type==="group"){const A=p(P.tokens,E,B);return z=>{const[I,...G]=A(z);return G.length?[""]:[I]}}const y=B||t;return P.type==="wildcard"&&B!==!1?A=>{const z=A[P.name];if(z==null)return["",P.name];if(!Array.isArray(z)||z.length===0)throw new TypeError(`Expected "${P.name}" to be a non-empty array`);return[z.map((I,G)=>{if(typeof I!="string")throw new TypeError(`Expected "${P.name}/${G}" to be a string`);return y(I)}).join(E)]}:A=>{const z=A[P.name];if(z==null)return["",P.name];if(typeof z!="string")throw new TypeError(`Expected "${P.name}" to be a string`);return[y(z)]}}function f(P,E={}){const{decode:B=decodeURIComponent,delimiter:y=e}=E,{regexp:A,keys:z}=g(P,E),I=z.map(G=>B===!1?t:G.type==="param"?B:re=>re.split(y).map(B));return function(re){const te=A.exec(re);if(!te)return!1;const oe=te[0],Z=Object.create(null);for(let se=1;se<te.length;se++){if(te[se]===void 0)continue;const ge=z[se-1],ue=I[se-1];Z[ge.name]=ue(te[se])}return{path:oe,params:Z}}}function g(P,E={}){const{delimiter:B=e,end:y=!0,sensitive:A=!1,trailing:z=!0}=E,I=[],G=[],re=A?"":"i",oe=(Array.isArray(P)?P:[P]).map(ge=>ge instanceof u?ge:d(ge,E));for(const{tokens:ge}of oe)for(const ue of S(ge,0,[])){const De=T(ue,B,I);G.push(De)}let Z=`^(?:${G.join("|")})`;return z&&(Z+=`(?:${i(B)}$)?`),Z+=y?"$":`(?=${i(B)}|$)`,{regexp:new RegExp(Z,re),keys:I}}function*S(P,E,B){if(E===P.length)return yield B;const y=P[E];if(y.type==="group"){const A=B.slice();for(const z of S(y.tokens,0,A))yield*S(P,E+1,z)}else B.push(y);yield*S(P,E+1,B)}function T(P,E,B){let y="",A="",z=!0;for(let I=0;I<P.length;I++){const G=P[I];if(G.type==="text"){y+=i(G.value),A+=G.value,z||(z=G.value.includes(E));continue}if(G.type==="param"||G.type==="wildcard"){if(!z&&!A)throw new TypeError(`Missing text after "${G.name}": ${a}`);G.type==="param"?y+=`(${O(E,z?"":A)}+)`:y+="([\\s\\S]+)",B.push(G),A="",z=!1;continue}}return y}function O(P,E){return E.length<2?P.length<2?`[^${i(P+E)}]`:`(?:(?!${i(P)})[^${i(E)}])`:P.length<2?`(?:(?!${i(E)})[^${i(P)}])`:`(?:(?!${i(E)}|${i(P)})[\\s\\S])`}function C(P){return P.tokens.map(function E(B,y,A){if(B.type==="text")return o(B.value);if(B.type==="group")return`{${B.tokens.map(E).join("")}}`;const I=V(B.name)&&R(A[y+1])?B.name:JSON.stringify(B.name);if(B.type==="param")return`:${I}`;if(B.type==="wildcard")return`*${I}`;throw new TypeError(`Unexpected token: ${B}`)}).join("")}function V(P){const[E,...B]=P;return r.test(E)?B.every(y=>n.test(y)):!1}function R(P){return(P==null?void 0:P.type)!=="text"?!0:!n.test(P.value[0])}return Jt}var l2=i2();function hg(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 pg(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 Kh=1e-4,c2=class fg{constructor(t,r,n,a,s,o,i,l,c,u,d,h){this.nova=t,this.controller=r,this.motionGroup=n,this.initialMotionState=a,this.motionStateSocket=s,this.isVirtual=o,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 m;const f=(m=wr(p.data))==null?void 0:m.result;f&&Xe.runInAction(()=>{this.controllerState=f})}),s.addEventListener("message",p=>{var m;const f=(m=wr(p.data))==null?void 0:m.result;if(!f)throw new Error(`Failed to get motion state for ${this.motionGroupId}: ${p.data}`);hg(this.rapidlyChangingMotionState.state.joint_position.joints,f.state.joint_position.joints,Kh)||Xe.runInAction(()=>{this.rapidlyChangingMotionState.state=f.state}),pg(this.rapidlyChangingMotionState.tcp_pose,f.tcp_pose,Kh)||Xe.runInAction(()=>{this.rapidlyChangingMotionState.tcp_pose=f.tcp_pose})}),Xe.makeAutoObservable(this)}static connect(t,r,n){return $e(this,null,function*(){var a,s;const[o,i]=r.split("@"),l=n.find(R=>R.controller===i),c=l==null?void 0:l.physical_motion_groups.find(R=>R.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=wr(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:
|
|
160
|
+
`,h);const m=(yield t.api.controller.getRobotController(l.controller)).configuration.kind==="VirtualController",f=yield $e(this,null,function*(){try{return yield t.api.motionGroupInfos.getMounting(c.motion_group)}catch(R){return console.error(`Error fetching mounting for ${c.motion_group}`,R),null}}),g=t.openReconnectingWebsocket(`/controllers/${l.controller}/state-stream?response_rate=1000`),S=yield g.firstMessage(),T=(s=wr(S.data))==null?void 0:s.result;if(!T)throw new Error(`Unable to parse initial controller state message ${S.data}`);console.log(`Connected controller state websocket to controller ${l.controller}. Initial state:
|
|
161
|
+
`,T);const{tcps:O}=yield t.api.motionGroupInfos.listTcps(r),C=yield t.api.motionGroupInfos.getMotionGroupSpecification(r),V=yield t.api.motionGroupInfos.getSafetySetup(r);return new fg(t,l,c,h,u,m,O,C,V,f,T,g)})}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,s,o;const i=new qe.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,((o=(s=this.mounting)==null?void 0:s.pose.orientation)==null?void 0:o.z)||0),l=i.length(),c=i.normalize();return new qe.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 $e(this,null,function*(){if(this.activationState!=="active"){console.error("Tried to deactivate while already deactivating");return}Xe.runInAction(()=>{this.activationState="deactivating"});try{yield this.nova.api.controller.setDefaultMode(this.controllerId,"MODE_MONITOR"),Xe.runInAction(()=>{this.activationState="inactive"})}catch(t){throw Xe.runInAction(()=>{this.activationState="active"}),t}})}activate(){return $e(this,null,function*(){if(this.activationState!=="inactive"){console.error("Tried to activate while already activating");return}Xe.runInAction(()=>{this.activationState="activating"});try{yield this.nova.api.controller.setDefaultMode(this.controllerId,"MODE_CONTROL"),Xe.runInAction(()=>{this.activationState="active"})}catch(t){throw Xe.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}},u2=class mg{constructor(t,r={}){this.motionStream=t,this.opts=r,this.cartesianWebsocket=null,this.jointWebsocket=null,this.cartesianJoggingOpts={}}static open(t,r){return $e(this,arguments,function*(n,a,s={}){const o=yield n.connectMotionStream(a);return new mg(o,s)})}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 $e(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&&(fE(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=wr(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=wr(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 $e(this,arguments,function*({joint:r,direction:n,velocityRadsPerSec:a}){if(!this.jointWebsocket)throw new Error("Joint jogging websocket not connected; call setJoggingMode first");const s=new Array(this.numJoints).fill(0);s[r]=n==="-"?-a:a,this.jointWebsocket.sendJson({motion_group:this.motionGroupId,joint_velocities:s})})}startTCPTranslation(t){return $e(this,arguments,function*({axis:r,direction:n,velocityMmPerSec:a}){if(!this.cartesianWebsocket)throw new Error("Cartesian jogging websocket not connected; call setJoggingMode first");const s={x:0,y:0,z:0},o=Object.assign({},s);o[r]=n==="-"?-1:1,this.cartesianWebsocket.sendJson({motion_group:this.motionGroupId,position_direction:o,rotation_direction:s,position_velocity:a,rotation_velocity:0,tcp:this.cartesianJoggingOpts.tcpId,coordinate_system:this.cartesianJoggingOpts.coordSystemId})})}startTCPRotation(t){return $e(this,arguments,function*({axis:r,direction:n,velocityRadsPerSec:a}){if(!this.cartesianWebsocket)throw new Error("Cartesian jogging websocket not connected; call setJoggingMode first");const s={x:0,y:0,z:0},o=Object.assign({},s);o[r]=n==="-"?-1:1,this.cartesianWebsocket.sendJson({motion_group:this.motionGroupId,position_direction:s,rotation_direction:o,position_velocity:0,rotation_velocity:a,tcp:this.cartesianJoggingOpts.tcpId,coordinate_system:this.cartesianJoggingOpts.coordSystemId})})}runIncrementalCartesianMotion(t){return $e(this,arguments,function*({currentTcpPose:r,currentJoints:n,coordSystemId:a,velocityInRelevantUnits:s,axis:o,direction:i,motion:l}){var c;const u=[];if(!EE(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[o]+=l.distanceMm*(i==="-"?-1:1),u.push({settings:{limits_override:{tcp_velocity_limit:s}},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),m=p.length(),f=p.clone().normalize(),g=l.distanceRads*(i==="-"?-1:1),S=new Ln(0,0,0);S[o]=1;const T=Math.cos(.5*g)*Math.cos(.5*m),O=Math.sin(.5*g)*Math.sin(.5*m),C=Math.sin(.5*g)*Math.cos(.5*m),V=Math.cos(.5*g)*Math.sin(.5*m),R=S.dot(f),P=S.clone().cross(f),E=2*Math.acos(T-O*R),B=E/Math.sin(.5*E),y=new Ln().addScaledVector(P,O).addScaledVector(S,C).addScaledVector(f,V).multiplyScalar(B);u.push({settings:{limits_override:{tcp_orientation_velocity_limit:s}},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 $e(this,arguments,function*({joint:r,currentJoints:n,velocityRadsPerSec:a,direction:s,distanceRads:o}){var i;const l=[...n.joints];l[r]+=o*(s==="-"?-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})})}},Yh=1e-4;function d2(e,t){const r=new kt.Vector3(t.x,t.y,t.z),n=new kt.Vector3(e.x,e.y,e.z),a=r.length(),s=r.normalize();let o=n.length(),i=n.normalize();i.dot(s)<0&&(o=-o,i=i.multiplyScalar(-1));let l=o-a;return l-=2*Math.PI*Math.floor((l+Math.PI)/(2*Math.PI)),o=a+l,i.multiplyScalar(o)}var h2=class gg{constructor(t,r,n,a,s){this.nova=t,this.controller=r,this.motionGroup=n,this.initialMotionState=a,this.motionStateSocket=s,this.rapidlyChangingMotionState=a,s.addEventListener("message",o=>{var i;const l=(i=wr(o.data))==null?void 0:i.result;if(!l)throw new Error(`Failed to get motion state for ${this.motionGroupId}: ${o.data}`);hg(this.rapidlyChangingMotionState.state.joint_position.joints,l.state.joint_position.joints,Yh)||Xe.runInAction(()=>{this.rapidlyChangingMotionState.state=l.state}),pg(this.rapidlyChangingMotionState.tcp_pose,l.tcp_pose,Yh)||Xe.runInAction(()=>{this.rapidlyChangingMotionState.tcp_pose==null?this.rapidlyChangingMotionState.tcp_pose=l.tcp_pose:this.rapidlyChangingMotionState.tcp_pose={position:l.tcp_pose.position,orientation:d2(l.tcp_pose.orientation,this.rapidlyChangingMotionState.tcp_pose.orientation),tcp:l.tcp_pose.tcp,coordinate_system:l.tcp_pose.coordinate_system}})}),Xe.makeAutoObservable(this)}static open(t,r){return $e(this,null,function*(){var n;const{instances:a}=yield t.api.controller.listControllers(),[s,o]=r.split("@"),i=a.find(h=>h.controller===o),l=i==null?void 0:i.physical_motion_groups.find(h=>h.motion_group===r);if(!i||!l)throw new Error(`Controller ${o} 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=wr(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:
|
|
162
|
+
`,d),new gg(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()}},p2=class{constructor(e,t){this.cellId=e,this.opts=t,this.system=this.withUnwrappedResponsesOnly(YI),this.cell=this.withUnwrappedResponsesOnly(hI),this.deviceConfig=this.withCellId(xI),this.motionGroup=this.withCellId(II),this.motionGroupInfos=this.withCellId($I),this.controller=this.withCellId(fI),this.program=this.withCellId(NI),this.programValues=this.withCellId(BI),this.controllerIOs=this.withCellId(gI),this.motionGroupKinematic=this.withCellId(UI),this.motion=this.withCellId(EI),this.coordinateSystems=this.withCellId(bI),this.application=this.withCellId(qh),this.applicationGlobal=this.withUnwrappedResponsesOnly(qh),this.motionGroupJogging=this.withCellId(kI),this.virtualRobot=this.withCellId(XI),this.virtualRobotSetup=this.withCellId(a2),this.virtualRobotMode=this.withCellId(r2),this.virtualRobotBehavior=this.withCellId(e2),this.libraryProgramMetadata=this.withCellId(CI),this.libraryProgram=this.withCellId(OI),this.libraryRecipeMetadata=this.withCellId(AI),this.libraryRecipe=this.withCellId(RI),this.storeObject=this.withCellId(WI),this.storeCollisionComponents=this.withCellId(GI),this.storeCollisionScenes=this.withCellId(qI)}withCellId(e){var t,r;const n=new e(Nl(In({},this.opts),{isJsonMime:a=>a==="application/json"}),(t=this.opts.basePath)!=null?t:"",(r=this.opts.axiosInstance)!=null?r:_.create());for(const a of Reflect.ownKeys(Reflect.getPrototypeOf(n)))if(a!=="constructor"&&typeof n[a]=="function"){const s=n[a];n[a]=(...o)=>s.apply(n,[this.cellId,...o]).then(i=>i.data)}return n}withUnwrappedResponsesOnly(e){var t,r;const n=new e(Nl(In({},this.opts),{isJsonMime:a=>a==="application/json"}),(t=this.opts.basePath)!=null?t:"",(r=this.opts.axiosInstance)!=null?r:_.create());for(const a of Reflect.ownKeys(Reflect.getPrototypeOf(n)))if(a!=="constructor"&&typeof n[a]=="function"){const s=n[a];n[a]=(...o)=>s.apply(n,o).then(i=>i.data)}return n}},f2=class{constructor(){this.connections=[]}handleAPIRequest(e){return $e(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"}}]}}}],s=((t=e.method)==null?void 0:t.toUpperCase())||"GET",o="/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=l2.match(i.path)(o||"");if(s===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 Jl(`No mock handler matched this request: ${s} ${o}`,"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(m2)})),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)}},m2={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]}},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"}}},g2=class{constructor(e){this.authPromise=null,this.accessToken=null;var t;const r=(t=e.cellId)!=null?t:"cell";this.config=In({cellId:r},e),this.accessToken=e.accessToken||nl.getString("wbjs.access_token")||null,this.config.instanceUrl==="https://mock.example.com"&&(this.mock=new f2);const n=_.create({baseURL:ul(this.config.instanceUrl,"/api/v1")});n.interceptors.request.use(a=>$e(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=>$e(this,null,function*(){var s,o;if(lI(a))if(((s=a.response)==null?void 0:s.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((o=a.response)==null?void 0:o.status)===503&&(yield fetch(window.location.href)).status===503&&window.location.reload();return Promise.reject(a)})),this.api=new p2(r,Nl(In({},e),{basePath:ul(this.config.instanceUrl,"/api/v1"),isJsonMime:a=>a==="application/json",baseOptions:In(In({},this.mock?{adapter:a=>this.mock.handleAPIRequest(a)}:{}),e.baseOptions),axiosInstance:n}))}renewAuthentication(){return $e(this,null,function*(){if(!this.authPromise){this.authPromise=IE(this.config.instanceUrl);try{this.accessToken=yield this.authPromise,this.accessToken?nl.setString("wbjs.access_token",this.accessToken):nl.delete("wbjs.access_token")}finally{this.authPromise=null}}})}makeWebsocketURL(e){const t=new URL(ul(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 AE(this.makeWebsocketURL(e),{mock:this.mock})}connectMotionStream(e){return $e(this,null,function*(){return yield h2.open(this,e)})}connectJogger(e){return $e(this,null,function*(){return yield u2.open(this,e)})}connectMotionGroups(e){return $e(this,null,function*(){const{instances:t}=yield this.api.controller.listControllers();return Promise.all(e.map(r=>c2.connect(this,r,t)))})}connectMotionGroup(e){return $e(this,null,function*(){return(yield this.connectMotionGroups([e]))[0]})}};function y2(e){try{return JSON.stringify(e)}catch{return}}function b2(e,t){throw new Error(t+` ${JSON.stringify(e)}`)}function v2(e){var t,r,n,a;return e instanceof Jl&&e.code==="ERR_NETWORK"?"Failed to connect to the server. Please check your internet connection.":e instanceof Jl&&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: ${y2(e)||e}`}const Kc=e=>{const t=e.softTimeout||3e3,[r,n]=ae.useState(!1),a=W.useTheme();return ae.useEffect(()=>{const s=setTimeout(()=>{n(!0)},t);return()=>clearTimeout(s)}),x.jsx(W.Stack,{width:"100%",height:"100%",alignItems:"center",justifyContent:"center",sx:{color:a.palette.text.primary},children:e.error?x.jsx(yg,{loadingMessage:e.message,error:e.error}):x.jsxs(x.Fragment,{children:[x.jsx(W.CircularProgress,{sx:{marginBottom:"24px"}}),!!e.message&&x.jsx("div",{children:e.message}),x.jsx(W.Stack,{sx:{visibility:r?"visible":"hidden",marginTop:"1rem",color:a.palette.text.secondary},children:"This is taking longer than expected..."})]})})},yg=e=>{const t=v2(e.error),r=e.error instanceof Error?e.error.stack:null,n=W.useTheme();return x.jsxs(W.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 ${tc.lowerFirst(W.capitalize(e.loadingMessage))} - `:"")+t,x.jsx("br",{}),r&&x.jsx("pre",{children:r})]})},x2=({title:e,titleId:t,...r},n)=>F.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:19,height:10,fill:"none",ref:n,"aria-labelledby":t,...r},e?F.createElement("title",{id:t},e):null,F.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"})),S2=ae.forwardRef(x2),O2=({title:e,titleId:t,...r},n)=>F.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:19,height:10,fill:"none",ref:n,"aria-labelledby":t,...r},e?F.createElement("title",{id:t},e):null,F.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"})),w2=ae.forwardRef(O2),C2=({title:e,titleId:t,...r},n)=>F.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:10,height:19,fill:"none",ref:n,"aria-labelledby":t,...r},e?F.createElement("title",{id:t},e):null,F.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"})),P2=ae.forwardRef(C2),R2=({title:e,titleId:t,...r},n)=>F.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?F.createElement("title",{id:t},e):null,F.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"})),T2=ae.forwardRef(R2);function A2(){this.__data__=[],this.size=0}function bg(e,t){return e===t||e!==e&&t!==t}function gi(e,t){for(var r=e.length;r--;)if(bg(e[r][0],t))return r;return-1}var V2=Array.prototype,E2=V2.splice;function _2(e){var t=this.__data__,r=gi(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():E2.call(t,r,1),--this.size,!0}function I2(e){var t=this.__data__,r=gi(t,e);return r<0?void 0:t[r][1]}function M2(e){return gi(this.__data__,e)>-1}function $2(e,t){var r=this.__data__,n=gi(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}function pr(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])}}pr.prototype.clear=A2;pr.prototype.delete=_2;pr.prototype.get=I2;pr.prototype.has=M2;pr.prototype.set=$2;function j2(){this.__data__=new pr,this.size=0}function k2(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function L2(e){return this.__data__.get(e)}function U2(e){return this.__data__.has(e)}var D2="[object AsyncFunction]",N2="[object Function]",F2="[object GeneratorFunction]",B2="[object Proxy]";function vg(e){if(!Hr(e))return!1;var t=rn(e);return t==N2||t==F2||t==D2||t==B2}var dl=Zt["__core-js_shared__"],Qh=function(){var e=/[^.]+$/.exec(dl&&dl.keys&&dl.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function z2(e){return!!Qh&&Qh in e}var G2=Function.prototype,H2=G2.toString;function an(e){if(e!=null){try{return H2.call(e)}catch{}try{return e+""}catch{}}return""}var q2=/[\\^$.*+?()[\]{}|]/g,J2=/^\[object .+?Constructor\]$/,W2=Function.prototype,K2=Object.prototype,Y2=W2.toString,Q2=K2.hasOwnProperty,X2=RegExp("^"+Y2.call(Q2).replace(q2,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Z2(e){if(!Hr(e)||z2(e))return!1;var t=vg(e)?X2:J2;return t.test(an(e))}function eM(e,t){return e==null?void 0:e[t]}function sn(e,t){var r=eM(e,t);return Z2(r)?r:void 0}var Qa=sn(Zt,"Map"),Xa=sn(Object,"create");function tM(){this.__data__=Xa?Xa(null):{},this.size=0}function rM(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var nM="__lodash_hash_undefined__",aM=Object.prototype,sM=aM.hasOwnProperty;function oM(e){var t=this.__data__;if(Xa){var r=t[e];return r===nM?void 0:r}return sM.call(t,e)?t[e]:void 0}var iM=Object.prototype,lM=iM.hasOwnProperty;function cM(e){var t=this.__data__;return Xa?t[e]!==void 0:lM.call(t,e)}var uM="__lodash_hash_undefined__";function dM(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=Xa&&t===void 0?uM:t,this}function Wr(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])}}Wr.prototype.clear=tM;Wr.prototype.delete=rM;Wr.prototype.get=oM;Wr.prototype.has=cM;Wr.prototype.set=dM;function hM(){this.size=0,this.__data__={hash:new Wr,map:new(Qa||pr),string:new Wr}}function pM(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function yi(e,t){var r=e.__data__;return pM(t)?r[typeof t=="string"?"string":"hash"]:r.map}function fM(e){var t=yi(this,e).delete(e);return this.size-=t?1:0,t}function mM(e){return yi(this,e).get(e)}function gM(e){return yi(this,e).has(e)}function yM(e,t){var r=yi(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}function fr(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])}}fr.prototype.clear=hM;fr.prototype.delete=fM;fr.prototype.get=mM;fr.prototype.has=gM;fr.prototype.set=yM;var bM=200;function vM(e,t){var r=this.__data__;if(r instanceof pr){var n=r.__data__;if(!Qa||n.length<bM-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new fr(n)}return r.set(e,t),this.size=r.size,this}function sr(e){var t=this.__data__=new pr(e);this.size=t.size}sr.prototype.clear=j2;sr.prototype.delete=k2;sr.prototype.get=L2;sr.prototype.has=U2;sr.prototype.set=vM;var xM="__lodash_hash_undefined__";function SM(e){return this.__data__.set(e,xM),this}function OM(e){return this.__data__.has(e)}function Ro(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new fr;++t<r;)this.add(e[t])}Ro.prototype.add=Ro.prototype.push=SM;Ro.prototype.has=OM;function wM(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 CM(e,t){return e.has(t)}var PM=1,RM=2;function xg(e,t,r,n,a,s){var o=r&PM,i=e.length,l=t.length;if(i!=l&&!(o&&l>i))return!1;var c=s.get(e),u=s.get(t);if(c&&u)return c==t&&u==e;var d=-1,h=!0,p=r&RM?new Ro:void 0;for(s.set(e,t),s.set(t,e);++d<i;){var m=e[d],f=t[d];if(n)var g=o?n(f,m,d,t,e,s):n(m,f,d,e,t,s);if(g!==void 0){if(g)continue;h=!1;break}if(p){if(!wM(t,function(S,T){if(!CM(p,T)&&(m===S||a(m,S,r,n,s)))return p.push(T)})){h=!1;break}}else if(!(m===f||a(m,f,r,n,s))){h=!1;break}}return s.delete(e),s.delete(t),h}var Xh=Zt.Uint8Array;function TM(e){var t=-1,r=Array(e.size);return e.forEach(function(n,a){r[++t]=[a,n]}),r}function AM(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var VM=1,EM=2,_M="[object Boolean]",IM="[object Date]",MM="[object Error]",$M="[object Map]",jM="[object Number]",kM="[object RegExp]",LM="[object Set]",UM="[object String]",DM="[object Symbol]",NM="[object ArrayBuffer]",FM="[object DataView]",Zh=Tr?Tr.prototype:void 0,hl=Zh?Zh.valueOf:void 0;function BM(e,t,r,n,a,s,o){switch(r){case FM:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case NM:return!(e.byteLength!=t.byteLength||!s(new Xh(e),new Xh(t)));case _M:case IM:case jM:return bg(+e,+t);case MM:return e.name==t.name&&e.message==t.message;case kM:case UM:return e==t+"";case $M:var i=TM;case LM:var l=n&VM;if(i||(i=AM),e.size!=t.size&&!l)return!1;var c=o.get(e);if(c)return c==t;n|=EM,o.set(e,t);var u=xg(i(e),i(t),n,a,s,o);return o.delete(e),u;case DM:if(hl)return hl.call(e)==hl.call(t)}return!1}function zM(e,t){for(var r=-1,n=t.length,a=e.length;++r<n;)e[a+r]=t[r];return e}var Xt=Array.isArray;function GM(e,t,r){var n=t(e);return Xt(e)?n:zM(n,r(e))}function HM(e,t){for(var r=-1,n=e==null?0:e.length,a=0,s=[];++r<n;){var o=e[r];t(o,r,e)&&(s[a++]=o)}return s}function qM(){return[]}var JM=Object.prototype,WM=JM.propertyIsEnumerable,ep=Object.getOwnPropertySymbols,KM=ep?function(e){return e==null?[]:(e=Object(e),HM(ep(e),function(t){return WM.call(e,t)}))}:qM;function YM(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var QM="[object Arguments]";function tp(e){return qr(e)&&rn(e)==QM}var Sg=Object.prototype,XM=Sg.hasOwnProperty,ZM=Sg.propertyIsEnumerable,Og=tp(function(){return arguments}())?tp:function(e){return qr(e)&&XM.call(e,"callee")&&!ZM.call(e,"callee")};function e5(){return!1}var wg=typeof exports=="object"&&exports&&!exports.nodeType&&exports,rp=wg&&typeof module=="object"&&module&&!module.nodeType&&module,t5=rp&&rp.exports===wg,np=t5?Zt.Buffer:void 0,r5=np?np.isBuffer:void 0,Kl=r5||e5,n5=9007199254740991,a5=/^(?:0|[1-9]\d*)$/;function Cg(e,t){var r=typeof e;return t=t??n5,!!t&&(r=="number"||r!="symbol"&&a5.test(e))&&e>-1&&e%1==0&&e<t}var s5=9007199254740991;function Yc(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=s5}var o5="[object Arguments]",i5="[object Array]",l5="[object Boolean]",c5="[object Date]",u5="[object Error]",d5="[object Function]",h5="[object Map]",p5="[object Number]",f5="[object Object]",m5="[object RegExp]",g5="[object Set]",y5="[object String]",b5="[object WeakMap]",v5="[object ArrayBuffer]",x5="[object DataView]",S5="[object Float32Array]",O5="[object Float64Array]",w5="[object Int8Array]",C5="[object Int16Array]",P5="[object Int32Array]",R5="[object Uint8Array]",T5="[object Uint8ClampedArray]",A5="[object Uint16Array]",V5="[object Uint32Array]",Me={};Me[S5]=Me[O5]=Me[w5]=Me[C5]=Me[P5]=Me[R5]=Me[T5]=Me[A5]=Me[V5]=!0;Me[o5]=Me[i5]=Me[v5]=Me[l5]=Me[x5]=Me[c5]=Me[u5]=Me[d5]=Me[h5]=Me[p5]=Me[f5]=Me[m5]=Me[g5]=Me[y5]=Me[b5]=!1;function E5(e){return qr(e)&&Yc(e.length)&&!!Me[rn(e)]}function _5(e){return function(t){return e(t)}}var Pg=typeof exports=="object"&&exports&&!exports.nodeType&&exports,ja=Pg&&typeof module=="object"&&module&&!module.nodeType&&module,I5=ja&&ja.exports===Pg,pl=I5&&Cm.process,ap=function(){try{var e=ja&&ja.require&&ja.require("util").types;return e||pl&&pl.binding&&pl.binding("util")}catch{}}(),sp=ap&&ap.isTypedArray,Rg=sp?_5(sp):E5,M5=Object.prototype,$5=M5.hasOwnProperty;function j5(e,t){var r=Xt(e),n=!r&&Og(e),a=!r&&!n&&Kl(e),s=!r&&!n&&!a&&Rg(e),o=r||n||a||s,i=o?YM(e.length,String):[],l=i.length;for(var c in e)$5.call(e,c)&&!(o&&(c=="length"||a&&(c=="offset"||c=="parent")||s&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||Cg(c,l)))&&i.push(c);return i}var k5=Object.prototype;function L5(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||k5;return e===r}function U5(e,t){return function(r){return e(t(r))}}var D5=U5(Object.keys,Object),N5=Object.prototype,F5=N5.hasOwnProperty;function B5(e){if(!L5(e))return D5(e);var t=[];for(var r in Object(e))F5.call(e,r)&&r!="constructor"&&t.push(r);return t}function Tg(e){return e!=null&&Yc(e.length)&&!vg(e)}function Qc(e){return Tg(e)?j5(e):B5(e)}function op(e){return GM(e,Qc,KM)}var z5=1,G5=Object.prototype,H5=G5.hasOwnProperty;function q5(e,t,r,n,a,s){var o=r&z5,i=op(e),l=i.length,c=op(t),u=c.length;if(l!=u&&!o)return!1;for(var d=l;d--;){var h=i[d];if(!(o?h in t:H5.call(t,h)))return!1}var p=s.get(e),m=s.get(t);if(p&&m)return p==t&&m==e;var f=!0;s.set(e,t),s.set(t,e);for(var g=o;++d<l;){h=i[d];var S=e[h],T=t[h];if(n)var O=o?n(T,S,h,t,e,s):n(S,T,h,e,t,s);if(!(O===void 0?S===T||a(S,T,r,n,s):O)){f=!1;break}g||(g=h=="constructor")}if(f&&!g){var C=e.constructor,V=t.constructor;C!=V&&"constructor"in e&&"constructor"in t&&!(typeof C=="function"&&C instanceof C&&typeof V=="function"&&V instanceof V)&&(f=!1)}return s.delete(e),s.delete(t),f}var Yl=sn(Zt,"DataView"),Ql=sn(Zt,"Promise"),Xl=sn(Zt,"Set"),Zl=sn(Zt,"WeakMap"),ip="[object Map]",J5="[object Object]",lp="[object Promise]",cp="[object Set]",up="[object WeakMap]",dp="[object DataView]",W5=an(Yl),K5=an(Qa),Y5=an(Ql),Q5=an(Xl),X5=an(Zl),Sr=rn;(Yl&&Sr(new Yl(new ArrayBuffer(1)))!=dp||Qa&&Sr(new Qa)!=ip||Ql&&Sr(Ql.resolve())!=lp||Xl&&Sr(new Xl)!=cp||Zl&&Sr(new Zl)!=up)&&(Sr=function(e){var t=rn(e),r=t==J5?e.constructor:void 0,n=r?an(r):"";if(n)switch(n){case W5:return dp;case K5:return ip;case Y5:return lp;case Q5:return cp;case X5:return up}return t});var Z5=1,hp="[object Arguments]",pp="[object Array]",Ms="[object Object]",e$=Object.prototype,fp=e$.hasOwnProperty;function t$(e,t,r,n,a,s){var o=Xt(e),i=Xt(t),l=o?pp:Sr(e),c=i?pp:Sr(t);l=l==hp?Ms:l,c=c==hp?Ms:c;var u=l==Ms,d=c==Ms,h=l==c;if(h&&Kl(e)){if(!Kl(t))return!1;o=!0,u=!1}if(h&&!u)return s||(s=new sr),o||Rg(e)?xg(e,t,r,n,a,s):BM(e,t,l,r,n,a,s);if(!(r&Z5)){var p=u&&fp.call(e,"__wrapped__"),m=d&&fp.call(t,"__wrapped__");if(p||m){var f=p?e.value():e,g=m?t.value():t;return s||(s=new sr),a(f,g,r,n,s)}}return h?(s||(s=new sr),q5(e,t,r,n,a,s)):!1}function bi(e,t,r,n,a){return e===t?!0:e==null||t==null||!qr(e)&&!qr(t)?e!==e&&t!==t:t$(e,t,r,n,bi,a)}function r$(e,t){return bi(e,t)}const Ag=({store:e})=>{const{t}=ze.useTranslation(),[r,n]=ae.useState(e.jogger.motionStream.rapidlyChangingMotionState.state.joint_limit_reached.limit_reached),a=ae.useRef(r);Yn(()=>{const o=e.jogger.motionStream.rapidlyChangingMotionState.state.joint_limit_reached.limit_reached;r$(a.current,o)||(a.current=o,n(o))});const s=[];for(const[o,i]of r.entries())i&&s.push(o);return x.jsx(W.Typography,{color:"error",sx:{margin:"0.5rem 1rem",textAlign:"center",minHeight:"1.5rem",visibility:s.length?"visible":"hidden"},children:t("Jogging.JointLimitsReached.lb",{jointNumbers:s.map(o=>o+1).join(", ")})})},n$=W.styled(W.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 $s({labelValue:e,...t}){return x.jsxs(n$,{fullWidth:!0,variant:"filled",children:[x.jsx(W.InputLabel,{id:t.labelId,children:e}),x.jsx(W.Select,{...t})]})}var mp=function(){try{var e=sn(Object,"defineProperty");return e({},"",{}),e}catch{}}();function a$(e,t,r){t=="__proto__"&&mp?mp(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function s$(e,t,r,n){for(var a=-1,s=e==null?0:e.length;++a<s;){var o=e[a];t(n,o,r(o),e)}return n}function o$(e){return function(t,r,n){for(var a=-1,s=Object(t),o=n(t),i=o.length;i--;){var l=o[++a];if(r(s[l],l,s)===!1)break}return t}}var i$=o$();function l$(e,t){return e&&i$(e,t,Qc)}function c$(e,t){return function(r,n){if(r==null)return r;if(!Tg(r))return e(r,n);for(var a=r.length,s=-1,o=Object(r);++s<a&&n(o[s],s,o)!==!1;);return r}}var u$=c$(l$);function d$(e,t,r,n){return u$(e,function(a,s,o){t(n,a,r(a),o)}),n}var h$=1,p$=2;function f$(e,t,r,n){var a=r.length,s=a;if(e==null)return!s;for(e=Object(e);a--;){var o=r[a];if(o[2]?o[1]!==e[o[0]]:!(o[0]in e))return!1}for(;++a<s;){o=r[a];var i=o[0],l=e[i],c=o[1];if(o[2]){if(l===void 0&&!(i in e))return!1}else{var u=new sr,d;if(!(d===void 0?bi(c,l,h$|p$,n,u):d))return!1}}return!0}function Vg(e){return e===e&&!Hr(e)}function m$(e){for(var t=Qc(e),r=t.length;r--;){var n=t[r],a=e[n];t[r]=[n,a,Vg(a)]}return t}function Eg(e,t){return function(r){return r==null?!1:r[e]===t&&(t!==void 0||e in Object(r))}}function g$(e){var t=m$(e);return t.length==1&&t[0][2]?Eg(t[0][0],t[0][1]):function(r){return r===e||f$(r,e,t)}}var y$=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,b$=/^\w*$/;function Xc(e,t){if(Xt(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||oi(e)?!0:b$.test(e)||!y$.test(e)||t!=null&&e in Object(t)}var v$="Expected a function";function Zc(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(v$);var r=function(){var n=arguments,a=t?t.apply(this,n):n[0],s=r.cache;if(s.has(a))return s.get(a);var o=e.apply(this,n);return r.cache=s.set(a,o)||s,o};return r.cache=new(Zc.Cache||fr),r}Zc.Cache=fr;var x$=500;function S$(e){var t=Zc(e,function(n){return r.size===x$&&r.clear(),n}),r=t.cache;return t}var O$=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,w$=/\\(\\)?/g,C$=S$(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(O$,function(r,n,a,s){t.push(a?s.replace(w$,"$1"):n||r)}),t});function P$(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 gp=Tr?Tr.prototype:void 0,yp=gp?gp.toString:void 0;function _g(e){if(typeof e=="string")return e;if(Xt(e))return P$(e,_g)+"";if(oi(e))return yp?yp.call(e):"";var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function Ig(e){return e==null?"":_g(e)}function Mg(e,t){return Xt(e)?e:Xc(e,t)?[e]:C$(Ig(e))}function vi(e){if(typeof e=="string"||oi(e))return e;var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function $g(e,t){t=Mg(t,e);for(var r=0,n=t.length;e!=null&&r<n;)e=e[vi(t[r++])];return r&&r==n?e:void 0}function R$(e,t,r){var n=e==null?void 0:$g(e,t);return n===void 0?r:n}function T$(e,t){return e!=null&&t in Object(e)}function A$(e,t,r){t=Mg(t,e);for(var n=-1,a=t.length,s=!1;++n<a;){var o=vi(t[n]);if(!(s=e!=null&&r(e,o)))break;e=e[o]}return s||++n!=a?s:(a=e==null?0:e.length,!!a&&Yc(a)&&Cg(o,a)&&(Xt(e)||Og(e)))}function V$(e,t){return e!=null&&A$(e,t,T$)}var E$=1,_$=2;function I$(e,t){return Xc(e)&&Vg(t)?Eg(vi(e),t):function(r){var n=R$(r,e);return n===void 0&&n===t?V$(r,e):bi(t,n,E$|_$)}}function M$(e){return e}function $$(e){return function(t){return t==null?void 0:t[e]}}function j$(e){return function(t){return $g(t,e)}}function k$(e){return Xc(e)?$$(vi(e)):j$(e)}function L$(e){return typeof e=="function"?e:e==null?M$:typeof e=="object"?Xt(e)?I$(e[0],e[1]):g$(e):k$(e)}function U$(e,t){return function(r,n){var a=Xt(r)?s$:d$,s={};return a(r,e,L$(n),s)}}var js=U$(function(e,t,r){a$(e,r,t)}),D$=0;function N$(e){var t=++D$;return Ig(e)+t}const ec=[{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}],F$=[{id:"continuous"},...ec],B$=["coordsys","tool"];class xi{constructor(t,r,n,a){var s,o;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=((s=n[0])==null?void 0:s.coordinate_system)||"world",this.selectedTcpId=((o=a[0])==null?void 0:o.id)||"",Xe.makeAutoObservable(this,{},{autoBind:!0}),this.loadFromLocalStorage(),this.disposers.push(Xe.autorun(()=>this.saveToLocalStorage())),window.joggingStore=this}static async loadFor(t){const{nova:r}=t,[n,{coordinatesystems:a},{tcps:s}]=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 xi(t,n,a||[],s||[])}dispose(){for(const t of this.disposers)t();this.jogger.dispose()}get coordSystemCountByName(){return tc.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=Nr.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 F$}get discreteIncrementOptions(){return ec}get incrementOptionsById(){return js(this.incrementOptions,t=>t.id)}get tabsById(){return js(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 js(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 js(this.tcps,t=>t.id)}get activeDiscreteIncrement(){return this.selectedOrientation==="tool"?void 0:ec.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=N$();this.lock(r);try{return await t()}finally{this.unlock(r)}}}const z$=Je.observer(({store:e})=>{var a;const{t}=ze.useTranslation(),r=[];function n(s){switch(s){case"coordsys":return t("Jogging.Orientation.coordsys");case"tool":return t("Jogging.Orientation.tool");default:return s}}return e.showCoordSystemSelect&&r.push(x.jsx($s,{labelId:"jogging-coord-select",labelValue:t("Jogging.CoordinateSystem.hlb"),value:e.selectedCoordSystemId,size:"small",variant:"filled",displayEmpty:!0,onChange:s=>e.setSelectedCoordSystemId(s.target.value),disabled:e.isLocked,children:e.coordSystems.map(s=>x.jsx(W.MenuItem,{value:s.coordinate_system,children:s.name&&e.coordSystemCountByName[s.name]>1?`${s.name} / ${s.coordinate_system}`:s.name||s.coordinate_system},s.coordinate_system))},"coord")),e.showTcpSelect&&r.push(x.jsx($s,{labelId:"jogging-tcp-select",labelValue:"TCP",value:e.selectedTcpId,size:"small",variant:"filled",onChange:s=>e.setSelectedTcpId(s.target.value),disabled:e.isLocked,children:e.tcps.map(s=>x.jsx(W.MenuItem,{value:s.id,children:s.id},s.id))},"tcp")),e.showOrientationSelect&&r.push(x.jsx($s,{labelValue:t("Jogging.Cartesian.Orientation.lb"),id:"orientation-select",labelId:"orientation-select",value:e.selectedOrientation,onChange:s=>e.setSelectedOrientation(s.target.value),disabled:e.isLocked,children:B$.map(s=>x.jsx(W.MenuItem,{value:s,children:n(s)},s))},"orientation")),e.showIncrementSelect&&r.push(x.jsxs($s,{labelValue:t("Jogging.Increment.hlb"),labelId:"jogging-increment-select",size:"small",variant:"filled",value:((a=e.activeDiscreteIncrement)==null?void 0:a.id)||"continuous",onChange:s=>e.setSelectedIncrementId(s.target.value),disabled:e.isLocked,children:[x.jsx(W.MenuItem,{value:"continuous",children:t("Jogging.Increment.Continuous.dd")},"continuous"),e.selectedOrientation==="tool"?null:e.discreteIncrementOptions.map(s=>x.jsx(W.MenuItem,{value:s.id,children:e.currentMotionType==="translate"?`${s.mm}mm`:`${s.degrees}°`},s.id))]},"increment")),x.jsx(W.Box,{component:"div",sx:{display:"grid",gap:"16px",gridTemplateColumns:"1fr 1fr",gridAutoRows:"min-content","& label":{opacity:.7,fontSize:"12px",marginBottom:"4px"}},children:r.map((s,o)=>x.jsx(W.Box,{sx:{gridColumn:r.length%2===1&&o===r.length-1?"span 2":"auto"},children:s},o))})}),G$=W.styled(W.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 H$(e,t,r=(n,a)=>n===a){return e.length===t.length&&e.every((n,a)=>r(n,t[a]))}const q$=2;function An(e,t,r,n,a){return r===1?Math.min(e+t,a):Math.max(e-t,n)}function jg(e,t){return e-t}function bp(e,t){const{index:r}=e.reduce((n,a,s)=>{const o=Math.abs(t-a);return n===null||o<n.distance||o===n.distance?{distance:o,index:s}:n},null)??{};return r}function ks(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 To(e,t,r){return(e-t)*100/(r-t)}function J$(e,t,r){return(r-t)*e+t}function W$(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 K$(e,t,r){const n=Math.round((e-r)/t)*t+r;return Number(n.toFixed(W$(t)))}function vp({values:e,newValue:t,index:r}){const n=e.slice();return n[r]=t,n.sort(jg)}function Ls({sliderRef:e,activeIndex:t,setActive:r}){var a,s,o;const n=Fs(e.current);(!((a=e.current)!=null&&a.contains(n.activeElement))||Number((s=n==null?void 0:n.activeElement)==null?void 0:s.getAttribute("data-index"))!==t)&&((o=e.current)==null||o.querySelector(`[type="range"][data-index="${t}"]`).focus()),r&&r(t)}function Us(e,t){return typeof e=="number"&&typeof t=="number"?e===t:typeof e=="object"&&typeof t=="object"?H$(e,t):!1}const Y$={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}%`})}},Q$=e=>e;let Ds;function xp(){return Ds===void 0&&(typeof CSS<"u"&&typeof CSS.supports=="function"?Ds=CSS.supports("touch-action","none"):Ds=!0),Ds}function X$(e){const{"aria-labelledby":t,defaultValue:r,disabled:n=!1,disableSwap:a=!1,isRtl:s=!1,marks:o=!1,max:i=100,min:l=0,name:c,onChange:u,onChangeCommitted:d,orientation:h="horizontal",rootRef:p,scale:m=Q$,step:f=1,shiftStep:g=10,tabIndex:S,value:T}=e,O=F.useRef(void 0),[C,V]=F.useState(-1),[R,P]=F.useState(-1),[E,B]=F.useState(!1),y=F.useRef(0),A=F.useRef(null),[z,I]=rb({controlled:T,default:r??l,name:"Slider"}),G=u&&((Q,ee,le)=>{const ve=Q.nativeEvent||Q,Ce=new ve.constructor(ve.type,ve);Object.defineProperty(Ce,"target",{writable:!0,value:{value:ee,name:c}}),A.current=ee,u(Ce,ee,le)}),re=Array.isArray(z);let te=re?z.slice().sort(jg):[z];te=te.map(Q=>Q==null?l:Vn(Q,l,i));const oe=o===!0&&f!==null?[...Array(Math.floor((i-l)/f)+1)].map((Q,ee)=>({value:l+f*ee})):o||[],Z=oe.map(Q=>Q.value),[se,ge]=F.useState(-1),ue=F.useRef(null),De=zp(p,ue),ct=Q=>ee=>{var ve;const le=Number(ee.currentTarget.getAttribute("data-index"));Cu(ee.target)&&ge(le),P(le),(ve=Q==null?void 0:Q.onFocus)==null||ve.call(Q,ee)},It=Q=>ee=>{var le;Cu(ee.target)||ge(-1),P(-1),(le=Q==null?void 0:Q.onBlur)==null||le.call(Q,ee)},tt=(Q,ee)=>{const le=Number(Q.currentTarget.getAttribute("data-index")),ve=te[le],Ce=Z.indexOf(ve);let ce=ee;if(oe&&f==null){const Ke=Z[Z.length-1];ce>=Ke?ce=Ke:ce<=Z[0]?ce=Z[0]:ce=ce<ve?Z[Ce-1]:Z[Ce+1]}if(ce=Vn(ce,l,i),re){a&&(ce=Vn(ce,te[le-1]||-1/0,te[le+1]||1/0));const Ke=ce;ce=vp({values:te,newValue:ce,index:le});let at=le;a||(at=ce.indexOf(Ke)),Ls({sliderRef:ue,activeIndex:at})}I(ce),ge(le),G&&!Us(ce,z)&&G(Q,ce,le),d&&d(Q,A.current??ce)},St=Q=>ee=>{var le;if(["ArrowUp","ArrowDown","ArrowLeft","ArrowRight","PageUp","PageDown","Home","End"].includes(ee.key)){ee.preventDefault();const ve=Number(ee.currentTarget.getAttribute("data-index")),Ce=te[ve];let ce=null;if(f!=null){const Ke=ee.shiftKey?g:f;switch(ee.key){case"ArrowUp":ce=An(Ce,Ke,1,l,i);break;case"ArrowRight":ce=An(Ce,Ke,s?-1:1,l,i);break;case"ArrowDown":ce=An(Ce,Ke,-1,l,i);break;case"ArrowLeft":ce=An(Ce,Ke,s?1:-1,l,i);break;case"PageUp":ce=An(Ce,g,1,l,i);break;case"PageDown":ce=An(Ce,g,-1,l,i);break;case"Home":ce=l;break;case"End":ce=i;break}}else if(oe){const Ke=Z[Z.length-1],at=Z.indexOf(Ce),Ge=[s?"ArrowRight":"ArrowLeft","ArrowDown","PageDown","Home"],ft=[s?"ArrowLeft":"ArrowRight","ArrowUp","PageUp","End"];Ge.includes(ee.key)?at===0?ce=Z[0]:ce=Z[at-1]:ft.includes(ee.key)&&(at===Z.length-1?ce=Ke:ce=Z[at+1])}ce!=null&&tt(ee,ce)}(le=Q==null?void 0:Q.onKeyDown)==null||le.call(Q,ee)};Fp(()=>{var Q;n&&ue.current.contains(document.activeElement)&&((Q=document.activeElement)==null||Q.blur())},[n]),n&&C!==-1&&V(-1),n&&se!==-1&&ge(-1);const pt=Q=>ee=>{var le;(le=Q.onChange)==null||le.call(Q,ee),tt(ee,ee.target.valueAsNumber)},rt=F.useRef(void 0);let X=h;s&&h==="horizontal"&&(X+="-reverse");const ie=({finger:Q,move:ee=!1})=>{const{current:le}=ue,{width:ve,height:Ce,bottom:ce,left:Ke}=le.getBoundingClientRect();let at;X.startsWith("vertical")?at=(ce-Q.y)/Ce:at=(Q.x-Ke)/ve,X.includes("-reverse")&&(at=1-at);let Ge;if(Ge=J$(at,l,i),f)Ge=K$(Ge,f,l);else{const Er=bp(Z,Ge);Ge=Z[Er]}Ge=Vn(Ge,l,i);let ft=0;if(re){ee?ft=rt.current:ft=bp(te,Ge),a&&(Ge=Vn(Ge,te[ft-1]||-1/0,te[ft+1]||1/0));const Er=Ge;Ge=vp({values:te,newValue:Ge,index:ft}),a&&ee||(ft=Ge.indexOf(Er),rt.current=ft)}return{newValue:Ge,activeIndex:ft}},he=Ai(Q=>{const ee=ks(Q,O);if(!ee)return;if(y.current+=1,Q.type==="mousemove"&&Q.buttons===0){J(Q);return}const{newValue:le,activeIndex:ve}=ie({finger:ee,move:!0});Ls({sliderRef:ue,activeIndex:ve,setActive:V}),I(le),!E&&y.current>q$&&B(!0),G&&!Us(le,z)&&G(Q,le,ve)}),J=Ai(Q=>{const ee=ks(Q,O);if(B(!1),!ee)return;const{newValue:le}=ie({finger:ee,move:!0});V(-1),Q.type==="touchend"&&P(-1),d&&d(Q,A.current??le),O.current=void 0,be()}),Oe=Ai(Q=>{if(n)return;xp()||Q.preventDefault();const ee=Q.changedTouches[0];ee!=null&&(O.current=ee.identifier);const le=ks(Q,O);if(le!==!1){const{newValue:Ce,activeIndex:ce}=ie({finger:le});Ls({sliderRef:ue,activeIndex:ce,setActive:V}),I(Ce),G&&!Us(Ce,z)&&G(Q,Ce,ce)}y.current=0;const ve=Fs(ue.current);ve.addEventListener("touchmove",he,{passive:!0}),ve.addEventListener("touchend",J,{passive:!0})}),be=F.useCallback(()=>{const Q=Fs(ue.current);Q.removeEventListener("mousemove",he),Q.removeEventListener("mouseup",J),Q.removeEventListener("touchmove",he),Q.removeEventListener("touchend",J)},[J,he]);F.useEffect(()=>{const{current:Q}=ue;return Q.addEventListener("touchstart",Oe,{passive:xp()}),()=>{Q.removeEventListener("touchstart",Oe),be()}},[be,Oe]),F.useEffect(()=>{n&&be()},[n,be]);const Ne=Q=>ee=>{var Ce;if((Ce=Q.onMouseDown)==null||Ce.call(Q,ee),n||ee.defaultPrevented||ee.button!==0)return;ee.preventDefault();const le=ks(ee,O);if(le!==!1){const{newValue:ce,activeIndex:Ke}=ie({finger:le});Ls({sliderRef:ue,activeIndex:Ke,setActive:V}),I(ce),G&&!Us(ce,z)&&G(ee,ce,Ke)}y.current=0;const ve=Fs(ue.current);ve.addEventListener("mousemove",he,{passive:!0}),ve.addEventListener("mouseup",J)},ke=To(re?te[0]:l,l,i),_e=To(te[te.length-1],l,i)-ke,Mt=(Q={})=>{const ee=Bs(Q),le={onMouseDown:Ne(ee||{})},ve={...ee,...le};return{...Q,ref:De,...ve}},er=Q=>ee=>{var ve;(ve=Q.onMouseOver)==null||ve.call(Q,ee);const le=Number(ee.currentTarget.getAttribute("data-index"));P(le)},on=Q=>ee=>{var le;(le=Q.onMouseLeave)==null||le.call(Q,ee),P(-1)},ln=(Q={})=>{const ee=Bs(Q),le={onMouseOver:er(ee||{}),onMouseLeave:on(ee||{})};return{...Q,...ee,...le}},mr=Q=>({pointerEvents:C!==-1&&C!==Q?"none":void 0});let gr;return h==="vertical"&&(gr=s?"vertical-rl":"vertical-lr"),{active:C,axis:X,axisProps:Y$,dragging:E,focusedThumbIndex:se,getHiddenInputProps:(Q={})=>{const ee=Bs(Q),le={onChange:pt(ee||{}),onFocus:ct(ee||{}),onBlur:It(ee||{}),onKeyDown:St(ee||{})},ve={...ee,...le};return{tabIndex:S,"aria-labelledby":t,"aria-orientation":h,"aria-valuemax":m(i),"aria-valuemin":m(l),name:c,type:"range",min:e.min,max:e.max,step:e.step===null&&e.marks?"any":e.step??void 0,disabled:n,...Q,...ve,style:{...nb,direction:s?"rtl":"ltr",width:"100%",height:"100%",writingMode:gr}}},getRootProps:Mt,getThumbProps:ln,marks:oe,open:R,range:re,rootRef:De,trackLeap:_e,trackOffset:ke,values:te,getThumbStyle:mr}}function Ks(e){return typeof e=="string"}const Z$=e=>!e||!Ks(e);function e3(e){return typeof e.main=="string"}function t3(e,t=[]){if(!e3(e))return!1;for(const r of t)if(!e.hasOwnProperty(r)||typeof e[r]!="string")return!1;return!0}function eu(e=[]){return([,t])=>t&&t3(t,e)}function r3(e){return ts("MuiSlider",e)}const Et=$p("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"]),n3=e=>{const{open:t}=e;return{offset:Nt(t&&Et.valueLabelOpen),circle:Et.valueLabelCircle,label:Et.valueLabelLabel}};function kg(e){const{children:t,className:r,value:n}=e,a=n3(e);return t?F.cloneElement(t,{className:Nt(t.props.className)},x.jsxs(F.Fragment,{children:[t.props.children,x.jsx("span",{className:Nt(a.offset,r),"aria-hidden":!0,children:x.jsx("span",{className:a.circle,children:x.jsx("span",{className:a.label,children:n})})})]})):null}process.env.NODE_ENV!=="production"&&(kg.propTypes={children:b.element.isRequired,className:b.string,value:b.node});function Sp(e){return e}const a3=Pt("span",{name:"MuiSlider",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,t[`color${dt(r.color)}`],r.size!=="medium"&&t[`size${dt(r.size)}`],r.marked&&t.marked,r.orientation==="vertical"&&t.vertical,r.track==="inverted"&&t.trackInverted,r.track===!1&&t.trackFalse]}})(tn(({theme:e})=>({borderRadius:12,boxSizing:"content-box",display:"inline-block",position:"relative",cursor:"pointer",touchAction:"none",WebkitTapHighlightColor:"transparent","@media print":{colorAdjust:"exact"},[`&.${Et.disabled}`]:{pointerEvents:"none",cursor:"default",color:(e.vars||e).palette.grey[400]},[`&.${Et.dragging}`]:{[`& .${Et.thumb}, & .${Et.track}`]:{transition:"none"}},variants:[...Object.entries(e.palette).filter(eu()).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}}]}))),s3=Pt("span",{name:"MuiSlider",slot:"Rail",overridesResolver:(e,t)=>t.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}}]}),o3=Pt("span",{name:"MuiSlider",slot:"Track",overridesResolver:(e,t)=>t.track})(tn(({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(eu()).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:La(e.palette[t].main,.62),borderColor:La(e.palette[t].main,.62),...e.applyStyles("dark",{backgroundColor:ka(e.palette[t].main,.5)}),...e.applyStyles("dark",{borderColor:ka(e.palette[t].main,.5)})}}}))]}))),i3=Pt("span",{name:"MuiSlider",slot:"Thumb",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.thumb,t[`thumbColor${dt(r.color)}`],r.size!=="medium"&&t[`thumbSize${dt(r.size)}`]]}})(tn(({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%)"},[`&.${Et.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(eu()).map(([t])=>({props:{color:t},style:{[`&:hover, &.${Et.focusVisible}`]:{...e.vars?{boxShadow:`0px 0px 0px 8px rgba(${e.vars.palette[t].mainChannel} / 0.16)`}:{boxShadow:`0px 0px 0px 8px ${yl(e.palette[t].main,.16)}`},"@media (hover: none)":{boxShadow:"none"}},[`&.${Et.active}`]:{...e.vars?{boxShadow:`0px 0px 0px 14px rgba(${e.vars.palette[t].mainChannel} / 0.16)`}:{boxShadow:`0px 0px 0px 14px ${yl(e.palette[t].main,.16)}`}}}}))]}))),Lg=Pt(kg,{name:"MuiSlider",slot:"ValueLabel",overridesResolver:(e,t)=>t.valueLabel})(tn(({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%"},[`&.${Et.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%"},[`&.${Et.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"&&(Lg.propTypes={children:b.element.isRequired,index:b.number.isRequired,open:b.bool.isRequired,value:b.node});const l3=Pt("span",{name:"MuiSlider",slot:"Mark",shouldForwardProp:e=>oc(e)&&e!=="markActive",overridesResolver:(e,t)=>{const{markActive:r}=e;return[t.mark,r&&t.markActive]}})(tn(({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}}]}))),c3=Pt("span",{name:"MuiSlider",slot:"MarkLabel",shouldForwardProp:e=>oc(e)&&e!=="markLabelActive",overridesResolver:(e,t)=>t.markLabel})(tn(({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}}]}))),u3=e=>{const{disabled:t,dragging:r,marked:n,orientation:a,track:s,classes:o,color:i,size:l}=e,c={root:["root",t&&"disabled",r&&"dragging",n&&"marked",a==="vertical"&&"vertical",s==="inverted"&&"trackInverted",s===!1&&"trackFalse",i&&`color${dt(i)}`,l&&`size${dt(l)}`],rail:["rail"],track:["track"],mark:["mark"],markActive:["markActive"],markLabel:["markLabel"],markLabelActive:["markLabelActive"],valueLabel:["valueLabel"],thumb:["thumb",t&&"disabled",l&&`thumbSize${dt(l)}`,i&&`thumbColor${dt(i)}`],active:["active"],disabled:["disabled"],focusVisible:["focusVisible"]};return ac(c,r3,o)},d3=({children:e})=>e,Ug=F.forwardRef(function(t,r){const n=Hc({props:t,name:"MuiSlider"}),a=cb(),{"aria-label":s,"aria-valuetext":o,"aria-labelledby":i,component:l="span",components:c={},componentsProps:u={},color:d="primary",classes:h,className:p,disableSwap:m=!1,disabled:f=!1,getAriaLabel:g,getAriaValueText:S,marks:T=!1,max:O=100,min:C=0,name:V,onChange:R,onChangeCommitted:P,orientation:E="horizontal",shiftStep:B=10,size:y="medium",step:A=1,scale:z=Sp,slotProps:I,slots:G,tabIndex:re,track:te="normal",value:oe,valueLabelDisplay:Z="off",valueLabelFormat:se=Sp,...ge}=n,ue={...n,isRtl:a,max:O,min:C,classes:h,disabled:f,disableSwap:m,orientation:E,marks:T,color:d,size:y,step:A,shiftStep:B,scale:z,track:te,valueLabelDisplay:Z,valueLabelFormat:se},{axisProps:De,getRootProps:ct,getHiddenInputProps:It,getThumbProps:tt,open:St,active:pt,axis:rt,focusedThumbIndex:X,range:ie,dragging:he,marks:J,values:Oe,trackOffset:be,trackLeap:Ne,getThumbStyle:ke}=X$({...ue,rootRef:r});ue.marked=J.length>0&&J.some(Le=>Le.label),ue.dragging=he,ue.focusedThumbIndex=X;const _e=u3(ue),Mt=(G==null?void 0:G.root)??c.Root??a3,er=(G==null?void 0:G.rail)??c.Rail??s3,on=(G==null?void 0:G.track)??c.Track??o3,ln=(G==null?void 0:G.thumb)??c.Thumb??i3,mr=(G==null?void 0:G.valueLabel)??c.ValueLabel??Lg,gr=(G==null?void 0:G.mark)??c.Mark??l3,cn=(G==null?void 0:G.markLabel)??c.MarkLabel??c3,Q=(G==null?void 0:G.input)??c.Input??"input",ee=(I==null?void 0:I.root)??u.root,le=(I==null?void 0:I.rail)??u.rail,ve=(I==null?void 0:I.track)??u.track,Ce=(I==null?void 0:I.thumb)??u.thumb,ce=(I==null?void 0:I.valueLabel)??u.valueLabel,Ke=(I==null?void 0:I.mark)??u.mark,at=(I==null?void 0:I.markLabel)??u.markLabel,Ge=(I==null?void 0:I.input)??u.input,ft=yr({elementType:Mt,getSlotProps:ct,externalSlotProps:ee,externalForwardedProps:ge,additionalProps:{...Z$(Mt)&&{as:l}},ownerState:{...ue,...ee==null?void 0:ee.ownerState},className:[_e.root,p]}),Er=yr({elementType:er,externalSlotProps:le,ownerState:ue,className:_e.rail}),Si=yr({elementType:on,externalSlotProps:ve,additionalProps:{style:{...De[rt].offset(be),...De[rt].leap(Ne)}},ownerState:{...ue,...ve==null?void 0:ve.ownerState},className:_e.track}),aa=yr({elementType:ln,getSlotProps:tt,externalSlotProps:Ce,ownerState:{...ue,...Ce==null?void 0:Ce.ownerState},className:_e.thumb}),sa=yr({elementType:mr,externalSlotProps:ce,ownerState:{...ue,...ce==null?void 0:ce.ownerState},className:_e.valueLabel}),un=yr({elementType:gr,externalSlotProps:Ke,ownerState:ue,className:_e.mark}),zt=yr({elementType:cn,externalSlotProps:at,ownerState:ue,className:_e.markLabel}),oa=yr({elementType:Q,getSlotProps:It,externalSlotProps:Ge,ownerState:ue});return x.jsxs(Mt,{...ft,children:[x.jsx(er,{...Er}),x.jsx(on,{...Si}),J.filter(Le=>Le.value>=C&&Le.value<=O).map((Le,Ye)=>{const ia=To(Le.value,C,O),_r=De[rt].offset(ia);let $t;return te===!1?$t=Oe.includes(Le.value):$t=te==="normal"&&(ie?Le.value>=Oe[0]&&Le.value<=Oe[Oe.length-1]:Le.value<=Oe[0])||te==="inverted"&&(ie?Le.value<=Oe[0]||Le.value>=Oe[Oe.length-1]:Le.value>=Oe[0]),x.jsxs(F.Fragment,{children:[x.jsx(gr,{"data-index":Ye,...un,...!Ks(gr)&&{markActive:$t},style:{..._r,...un.style},className:Nt(un.className,$t&&_e.markActive)}),Le.label!=null?x.jsx(cn,{"aria-hidden":!0,"data-index":Ye,...zt,...!Ks(cn)&&{markLabelActive:$t},style:{..._r,...zt.style},className:Nt(_e.markLabel,zt.className,$t&&_e.markLabelActive),children:Le.label}):null]},Ye)}),Oe.map((Le,Ye)=>{const ia=To(Le,C,O),_r=De[rt].offset(ia),$t=Z==="off"?d3:mr;return x.jsx($t,{...!Ks($t)&&{valueLabelFormat:se,valueLabelDisplay:Z,value:typeof se=="function"?se(z(Le),Ye):se,index:Ye,open:St===Ye||pt===Ye||Z==="on",disabled:f},...sa,children:x.jsx(ln,{"data-index":Ye,...aa,className:Nt(_e.thumb,aa.className,pt===Ye&&_e.active,X===Ye&&_e.focusVisible),style:{..._r,...ke(Ye),...aa.style},children:x.jsx(Q,{"data-index":Ye,"aria-label":g?g(Ye):s,"aria-valuenow":z(Le),"aria-labelledby":i,"aria-valuetext":S?S(z(Le),Ye):o,value:Oe[Ye],...oa})})},Ye)})]})});process.env.NODE_ENV!=="production"&&(Ug.propTypes={"aria-label":wu(b.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":b.string,"aria-valuetext":wu(b.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:b.node,classes:b.object,className:b.string,color:b.oneOfType([b.oneOf(["primary","secondary","error","info","success","warning"]),b.string]),components:b.shape({Input:b.elementType,Mark:b.elementType,MarkLabel:b.elementType,Rail:b.elementType,Root:b.elementType,Thumb:b.elementType,Track:b.elementType,ValueLabel:b.elementType}),componentsProps:b.shape({input:b.oneOfType([b.func,b.object]),mark:b.oneOfType([b.func,b.object]),markLabel:b.oneOfType([b.func,b.object]),rail:b.oneOfType([b.func,b.object]),root:b.oneOfType([b.func,b.object]),thumb:b.oneOfType([b.func,b.object]),track:b.oneOfType([b.func,b.object]),valueLabel:b.oneOfType([b.func,b.shape({children:b.element,className:b.string,open:b.bool,style:b.object,value:b.node,valueLabelDisplay:b.oneOf(["auto","off","on"])})])}),defaultValue:b.oneOfType([b.arrayOf(b.number),b.number]),disabled:b.bool,disableSwap:b.bool,getAriaLabel:b.func,getAriaValueText:b.func,marks:b.oneOfType([b.arrayOf(b.shape({label:b.node,value:b.number.isRequired})),b.bool]),max:b.number,min:b.number,name:b.string,onChange:b.func,onChangeCommitted:b.func,orientation:b.oneOf(["horizontal","vertical"]),scale:b.func,shiftStep:b.number,size:b.oneOfType([b.oneOf(["small","medium"]),b.string]),slotProps:b.shape({input:b.oneOfType([b.func,b.object]),mark:b.oneOfType([b.func,b.object]),markLabel:b.oneOfType([b.func,b.object]),rail:b.oneOfType([b.func,b.object]),root:b.oneOfType([b.func,b.object]),thumb:b.oneOfType([b.func,b.object]),track:b.oneOfType([b.func,b.object]),valueLabel:b.oneOfType([b.func,b.shape({children:b.element,className:b.string,open:b.bool,style:b.object,value:b.node,valueLabelDisplay:b.oneOf(["auto","off","on"])})])}),slots:b.shape({input:b.elementType,mark:b.elementType,markLabel:b.elementType,rail:b.elementType,root:b.elementType,thumb:b.elementType,track:b.elementType,valueLabel:b.elementType}),step:b.number,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),tabIndex:b.number,track:b.oneOf(["inverted","normal",!1]),value:b.oneOfType([b.arrayOf(b.number),b.number]),valueLabelDisplay:b.oneOf(["auto","off","on"]),valueLabelFormat:b.oneOfType([b.func,b.string])});var h3="[object Number]";function p3(e){return typeof e=="number"||qr(e)&&rn(e)==h3}const Dg=Je.observer(e=>{var s,o,i;const t=W.useTheme(),{store:r}=e,{t:n}=ze.useTranslation();function a(l,c){c===e.velocity||!p3(c)||e.onVelocityChange(c)}return x.jsxs(W.Stack,{direction:"row",gap:2,alignItems:"center",children:[r.showVelocityLegend&&x.jsx(W.Typography,{sx:{color:(i=(o=(s=t.componentsExt)==null?void 0:s.JoggingPanel)==null?void 0:o.VelocitySlider)==null?void 0:i.sliderLegendColor,fontSize:"14px"},children:n("Jogging.Velocity.bt")}),x.jsx(Ug,{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):x.jsx(tu,{value:e.velocity.toString()}))]})});function tu({value:e,sx:t}){var n;const r=W.useTheme();return x.jsx(W.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:x.jsx(W.Typography,{component:"span",sx:{textAlign:"right",fontSize:"14px",opacity:.8,color:r.palette.text.primary,whiteSpace:"nowrap"},children:e})})}const Ng=Je.observer(({store:e})=>{const{t}=ze.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 x.jsx(Dg,{store:e,velocity:e.velocityInDisplayUnits,min:e.minVelocityInDisplayUnits,max:e.maxVelocityInDisplayUnits,onVelocityChange:e.setVelocityFromSlider,disabled:e.isLocked,renderValue:n=>x.jsx(tu,{value:r.valueLabelFormat(n),sx:{minWidth:"111px",span:{transform:"translateY(-1.5px)"}}})})}),f3=Je.observer(({store:e,children:t})=>{const{t:r}=ze.useTranslation(),n=W.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 s(h,p){const m=await e.activate(),f=m.motionStream.rapidlyChangingMotionState.tcp_pose,g=m.motionStream.rapidlyChangingMotionState.state.joint_position;f&&await e.withMotionLock(async()=>{try{e.setCurrentIncrementJog({axis:h.axis,direction:h.direction}),await e.jogger.runIncrementalCartesianMotion({currentTcpPose:f,currentJoints:g,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:Nr.degreesToRadians(p.degrees)}})}finally{e.setCurrentIncrementJog(null),await e.deactivate()}})}async function o(h){if(!e.isLocked){if(await e.activate(),e.activeDiscreteIncrement)return s(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,m){var g,S,T;const f=(T=(S=(g=m.componentsExt)==null?void 0:g.JoggingPanel)==null?void 0:S.JoggingCartesian)==null?void 0:T.Axis;if(f)return p==="translate"?f[h]:f.CustomRotation??f[h]}const c=[{id:"x",icon:x.jsx(S2,{}),colors:l("X",e.selectedCartesianMotionType,n)},{id:"y",icon:x.jsx(w2,{}),colors:l("Y",e.selectedCartesianMotionType,n)},{id:"z",icon:x.jsx(P2,{}),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:Nr.radiansToDegrees(h).toFixed(1)})}return x.jsxs(W.Stack,{flexGrow:1,gap:2,sx:{padding:"18px 24px"},children:[x.jsxs(W.Stack,{gap:2,children:[x.jsx(z$,{store:e}),x.jsx(Ng,{store:e}),x.jsx(W.Divider,{})]}),x.jsx(W.Stack,{marginLeft:"auto",marginRight:"auto",gap:"24px",justifyContent:"center",sx:{flexGrow:"1"},children:x.jsxs(W.Stack,{alignItems:"center",justifyContent:"center",gap:"24px",sx:{flexGrow:1},children:[x.jsxs(G$,{value:e.selectedCartesianMotionType,onChange:a,exclusive:!0,"aria-label":r("Jogging.Cartesian.MotionType.lb"),sx:{justifyContent:"center"},children:[x.jsx(W.ToggleButton,{value:"translate",children:r("Jogging.Cartesian.Translation.bt")}),x.jsx(W.ToggleButton,{value:"rotate",children:r("Jogging.Cartesian.Rotation.bt")})]}),e.selectedCartesianMotionType==="translate"&&c.map(h=>{var p,m;return x.jsx(Ml,{colors:h.colors,disabled:e.isLocked,activeJoggingDirection:((p=e.incrementJogInProgress)==null?void 0:p.axis)===h.id?e.incrementJogInProgress.direction:void 0,label:x.jsxs(x.Fragment,{children:[h.icon,x.jsx(W.Typography,{sx:{fontSize:"24px",color:((m=h.colors)==null?void 0:m.labelColor)??n.palette.text.primary},children:h.id.toUpperCase()})]}),getDisplayedValue:()=>{var f;return u(((f=e.jogger.motionStream.rapidlyChangingMotionState.tcp_pose)==null?void 0:f.position[h.id])||0)},startJogging:f=>o({axis:h.id,motionType:"translate",direction:f}),stopJogging:i},h.id)}),e.selectedCartesianMotionType==="rotate"&&c.map(h=>{var p,m;return x.jsx(Ml,{colors:h.colors,disabled:e.isLocked,activeJoggingDirection:((p=e.incrementJogInProgress)==null?void 0:p.axis)===h.id?e.incrementJogInProgress.direction:void 0,label:x.jsxs(x.Fragment,{children:[x.jsx(T2,{}),x.jsx(W.Typography,{sx:{fontSize:"24px",color:((m=h.colors)==null?void 0:m.labelColor)??n.palette.text.primary},children:h.id.toUpperCase()})]}),getDisplayedValue:()=>{var f,g;return d(((g=(f=e.jogger.motionStream.rapidlyChangingMotionState.tcp_pose)==null?void 0:f.orientation)==null?void 0:g[h.id])||0)},startJogging:f=>o({axis:h.id,motionType:"rotate",direction:f}),stopJogging:i},h.id)})]})}),x.jsx(Ag,{store:e}),t&&x.jsx(W.Divider,{}),t]})}),m3=Je.observer(({store:e,children:t})=>{const r=W.useTheme();async function n(s){await e.activate(),await e.jogger.startJointRotation({joint:s.joint,direction:s.direction,velocityRadsPerSec:e.rotationVelocityRadsPerSec})}async function a(){await e.jogger.stop(),await e.deactivate()}return x.jsxs(W.Stack,{flexGrow:1,gap:2,sx:{padding:"18px 24px"},children:[x.jsx(Ng,{store:e}),x.jsx(W.Divider,{}),x.jsx(W.Stack,{justifyContent:"center",alignItems:"stretch",sx:{flexGrow:"1"},id:"JointControls",children:x.jsx(W.Stack,{alignItems:"center",gap:"24px",children:e.jogger.motionStream.joints.map(s=>{var c;const o=(c=e.motionGroupSpec.mechanical_joint_limits)==null?void 0:c[s.index],i=(o==null?void 0:o.lower_limit)!==void 0?Nr.radiansToDegrees(o.lower_limit):void 0,l=(o==null?void 0:o.upper_limit)!==void 0?Nr.radiansToDegrees(o.upper_limit):void 0;return x.jsxs(W.Stack,{direction:"row",alignItems:"center",justifyContent:"center",spacing:1.5,width:"100%",children:[e.showJointsLegend&&x.jsx(W.Typography,{color:e.isLocked?r.palette.text.disabled:r.palette.text.secondary,children:`G${s.index+1}`}),x.jsx(Rm,{disabled:e.isLocked,lowerLimitDegs:i,upperLimitDegs:l,getValueDegs:()=>{const u=e.jogger.motionStream.rapidlyChangingMotionState.state.joint_position.joints[s.index];return u!==void 0?Nr.radiansToDegrees(u):void 0},startJogging:u=>n({joint:s.index,direction:u}),stopJogging:a})]},`joint-${s.index}`)})})}),x.jsx(Ag,{store:e}),t&&x.jsx(W.Divider,{}),t]})}),g3=en(Je.observer(e=>{const t=tc.isString(e.nova)?new g2({instanceUrl:e.nova}):e.nova,r=Je.useLocalObservable(()=>({joggingStore:null,loadingError:null}));async function n(){Xe.runInAction(()=>{r.loadingError=null,r.joggingStore=null});try{let a=e.store;if(!a){const s=await t.connectJogger(e.motionGroupId);a=await xi.loadFor(s)}Xe.runInAction(()=>{r.joggingStore=a}),e.onSetup&&e.onSetup(a)}catch(a){r.loadingError=a}}return ae.useEffect(()=>(n(),e.store?()=>null:()=>{var a;(a=r.joggingStore)==null||a.dispose()}),[e.store,e.nova,e.motionGroupId]),ae.useEffect(()=>{const a=r.joggingStore;a&&(e.locked?a.lock("external"):a.unlock("external"))},[r.joggingStore,e.locked]),x.jsx(W.Stack,{sx:{maxWidth:"460px",minWidth:"320px",position:"relative",...e.sx},children:r.joggingStore?x.jsx(y3,{store:r.joggingStore,children:e.children}):x.jsx(Kc,{message:"Loading jogging",error:r.loadingError})})})),y3=Je.observer(({store:e,children:t})=>{const{t:r}=ze.useTranslation();function n(){if(e.currentTab.id==="cartesian")return x.jsx(x.Fragment,{children:x.jsx(f3,{store:e,children:t})});if(e.currentTab.id==="joint")return x.jsx(x.Fragment,{children:x.jsx(m3,{store:e,children:t})})}return x.jsxs(W.Stack,{flexGrow:1,sx:{overflow:"hidden"},children:[x.jsx(W.Tabs,{value:e.tabIndex,onChange:e.onTabChange,variant:"fullWidth",children:e.tabs.map(a=>{const s=a.label==="cartesian"?r("Jogging.Cartesian.bt"):r("Jogging.Joints.bt"),o=a.label==="cartesian"?x.jsx(KP,{fontSize:"small",sx:{mr:1}}):x.jsx(YP,{fontSize:"small",sx:{mr:1}});return x.jsx(W.Tab,{label:e.showTabIcons?x.jsxs(W.Stack,{direction:"row",alignItems:"center",children:[o,s]}):s,id:`jogging-tab-${a.id}`,"aria-controls":`jogging-tab-${a.id}`},a.id)})}),x.jsx(W.Stack,{flexGrow:1,position:"relative",sx:{overflowY:"auto",overflowX:"hidden"},children:n()})]})}),Fg=ae.forwardRef(({label:e,value:t},r)=>{var i;const n=W.useTheme(),[a,s]=ae.useState(!1);async function o(){if(!r||!("current"in r))return console.warn("No copy target found"),!1;try{return await navigator.clipboard.writeText(t),console.log("Copied!"),s(!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 ae.useEffect(()=>{if(!a)return;const l=setTimeout(()=>s(!1),3e3);return()=>{l&&clearTimeout(l)}},[a]),x.jsx(W.Tooltip,{open:a,title:"Copied!",children:x.jsx(W.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:()=>o(),children:x.jsx(W.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})})})}),b3=Je.observer(({motionStream:e})=>{const t=ae.useRef(null);function r(){const n=e.rapidlyChangingMotionState.tcp_pose;return n?Nr.poseToWandelscriptString(n):""}return Yn(()=>{if(!t.current)return;const n=r();t.current.textContent!==n&&(t.current.textContent=n)}),x.jsx(W.Stack,{alignItems:"left",spacing:2,sx:{flexGrow:1,minWidth:0,overflow:"hidden"},children:x.jsx(Fg,{value:r(),ref:t})})}),v3=Je.observer(({motionStream:e})=>{const t=ae.useRef(null);function r(){const{joints:n}=e.rapidlyChangingMotionState.state.joint_position;return`[${n.map(a=>parseFloat(a.toFixed(4))).join(", ")}]`}return Yn(()=>{if(!t.current)return;const n=r();t.current.textContent!==n&&(t.current.textContent=n)}),x.jsx(W.Stack,{alignItems:"left",spacing:2,sx:{flexGrow:1,minWidth:0,overflow:"hidden"},children:x.jsx(Fg,{value:r(),ref:t})})});function x3(){const e=window.location.href;return e.substring(0,e.indexOf("/",e.indexOf("//")+2))}function S3({baseUrl:e=x3(),...t}){return x.jsxs(W.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:[x.jsx(W.DialogTitle,{id:"no-motion-group-modal-title",children:"No motion group found"}),x.jsxs(W.DialogContent,{sx:{marginTop:"3rem",marginBottom:"1.5rem",textAlign:"center"},children:[x.jsx(W.Typography,{color:"#fff",children:"Found no devices to connect to."}),x.jsx(W.Typography,{color:"#fff",children:"Please ensure a motion group has been created."})]}),x.jsx(W.DialogActions,{children:x.jsxs(W.Stack,{width:"100%",maxWidth:"300px",margin:"auto",marginBottom:"2rem",children:[x.jsx(W.Button,{href:`${e}/settings`,variant:"contained",sx:{borderRadius:"8px",width:"100%"},children:"Go to settings app"}),x.jsx(W.Button,{href:`${e}`,variant:"text",sx:{marginTop:"1rem",color:"#fff",textDecoration:"underline",fontSize:"0.75rem"},children:"Back to Homescreen"})]})})]})}const O3=Array(6).fill(2*Math.PI),Op="0.0.0-semantically-released";function ru(e){let t=Op;return Op.startsWith("0.")&&(t=""),`https://cdn.jsdelivr.net/gh/wandelbotsgmbh/wandelbots-js-react-components${t?`@${t}`:""}/public/models/${e}.glb`}function w3(e){function t(r){return r.children.length===0?[r]:[r,...r.children.flatMap(n=>t(n))]}return t(e).filter(r=>zg(r))}function Bg(e){return e.name.endsWith("_FLG")}function zg(e){return/_J[0-9]+$/.test(e.name)}function C3(e,t){let r;function n(a){if(Bg(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}zg(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 Gg({rapidlyChangingMotionState:e,dhParameters:t,onRotationChanged:r,children:n}){ml.Globals.assign({frameLoop:"always"});const a=ae.useRef([]),s=ae.useRef([]),{invalidate:o}=ly.useThree();function i(h){h&&(s.current=w3(h),c(),o())}function l(h){a.current=h,d.start(Object.assign({},a.current))}function c(){const h=s.current.map((p,m)=>u[m].get());if(r)r(s.current,h);else for(const[p,m]of s.current.entries()){const f=t[p],g=f.theta||0,S=f.reverse_rotation_direction?-1:1;m.rotation.y=S*h[p]+g}}Om(()=>{const h=e.state.joint_position.joints.filter(p=>p!==void 0);requestAnimationFrame(()=>l(h))});const[u,d]=ml.useSpring(()=>({...Object.assign({},e.state.joint_position.joints),onChange:()=>{c(),o()},onResolve:()=>{c()}}));return x.jsx("group",{ref:i,children:n})}const wp="line",Cp="mesh";function P3({rapidlyChangingMotionState:e,dhParameters:t,...r}){const n=new kt.Matrix4;function a(i,l){const c=new kt.Vector3,u=new kt.Quaternion,d=new kt.Vector3;n.decompose(c,u,d);const h=c.clone(),p=new kt.Matrix4().makeRotationY(i.theta+l*(i.reverse_rotation_direction?-1:1)).multiply(new kt.Matrix4().makeTranslation(0,i.d/1e3,0)).multiply(new kt.Matrix4().makeTranslation(i.a/1e3,0,0)).multiply(new kt.Matrix4().makeRotationX(i.alpha));return n.multiply(p),n.decompose(c,u,d),{a:h,b:c}}function s(i,l,c,u){if(!t)return;const d=t[i];if(!d)return;const{a:h,b:p}=a(d,u);l.geometry.setPositions([h.toArray(),p.toArray()].flat()),c.position.set(p.x,p.y,p.z)}function o(i,l){n.identity(),i.forEach((c,u)=>{s(u,c.getObjectByName(wp),c.getObjectByName(Cp),l[u])})}return x.jsx(x.Fragment,{children:x.jsx(Gg,{rapidlyChangingMotionState:e,dhParameters:t,onRotationChanged:o,children:x.jsxs("group",{...r,name:"Scene",children:[x.jsxs("mesh",{children:[x.jsx("sphereGeometry",{args:[.01,32,32]}),x.jsx("meshStandardMaterial",{color:"black",depthTest:!0})]}),t.map((i,l)=>{const{a:c,b:u}=a(i,e.state.joint_position.joints[l]??0),d=`dhrobot_J0${l}`;return x.jsxs("group",{name:d,children:[x.jsx(Lt.Line,{name:wp,points:[c,u],color:"white",lineWidth:5}),x.jsxs("mesh",{name:Cp,position:u,children:[x.jsx("sphereGeometry",{args:[.01,32,32]}),x.jsx("meshStandardMaterial",{color:"black",depthTest:!0})]},"mesh_"+l)]},d)})]})})})}const R3=console.warn;function T3(){return ae.useEffect(()=>{console.warn=e=>{e!=="Cannot call the manual advancement of rafz whilst frameLoop is not set as demand"&&R3(e)}},[]),x.jsx(x.Fragment,{})}function A3(e){return e.type==="Mesh"}function V3({modelURL:e,flangeRef:t,postModelRender:r,...n}){const{gltf:a}=C3(Lt.useGLTF(e),e.split("/").pop()||e),s=ae.useCallback(i=>{i&&r&&r()},[e]);function o(i){return A3(i)?x.jsx("mesh",{name:i.name,geometry:i.geometry,material:i.material,position:i.position,rotation:i.rotation},i.uuid):x.jsx(ml.animated.group,{name:i.name,position:i.position,rotation:i.rotation,ref:Bg(i)?t:void 0,children:i.children.map(o)},i.uuid)}return x.jsx("group",{...n,dispose:null,ref:s,children:o(a.scene)})}const E3=(e,t)=>{e.userData.isGhost||(e.traverse(r=>{if(r instanceof qe.Mesh){r.material instanceof qe.Material&&(r.material.colorWrite=!1);const n=r.clone(),a=r.clone();n.material=new qe.MeshStandardMaterial({depthTest:!0,depthWrite:!0,colorWrite:!1,polygonOffset:!0,polygonOffsetFactor:-1,side:qe.DoubleSide}),n.userData.isGhost=!0,a.material=new qe.MeshStandardMaterial({color:t,opacity:.3,depthTest:!0,depthWrite:!1,transparent:!0,polygonOffset:!0,polygonOffsetFactor:-2,side:qe.DoubleSide}),a.userData.isGhost=!0,r.parent&&(r.parent.add(n),r.parent.add(a))}}),e.userData.isGhost=!0)},_3=e=>{if(!e.userData.isGhost)return;const t=[];e.traverse(r=>{var n;r instanceof qe.Mesh&&((n=r.userData)!=null&&n.isGhost?t.push(r):r.material instanceof qe.Material&&(r.material.colorWrite=!0))}),t.forEach(r=>{r.parent&&r.parent.remove(r)}),e.userData.isGhost=!1},Hg=en(({rapidlyChangingMotionState:e,modelFromController:t,dhParameters:r,getModel:n=ru,flangeRef:a,postModelRender:s,transparentColor:o,...i})=>{const[l,c]=ae.useState(null),u=ae.useCallback(h=>{c(h)},[]);ae.useEffect(()=>{l&&(o?E3(l,o):_3(l))},[l,o]);const d=x.jsx(P3,{rapidlyChangingMotionState:e,dhParameters:r,...i});return x.jsxs(py.ErrorBoundary,{fallback:d,onError:h=>{console.error(h)},children:[x.jsx(ae.Suspense,{fallback:d,children:x.jsx("group",{ref:u,children:x.jsx(Gg,{rapidlyChangingMotionState:e,dhParameters:r,children:x.jsx(V3,{modelURL:n(t),postModelRender:s,flangeRef:a,...i})})})}),x.jsx(T3,{})]})});function I3({connectedMotionGroup:e,getModel:t=ru,flangeRef:r,transparentColor:n,...a}){return e.dhParameters?x.jsx(Hg,{rapidlyChangingMotionState:e.rapidlyChangingMotionState,modelFromController:e.modelFromController||"",dhParameters:e.dhParameters,getModel:t,flangeRef:r,transparentColor:n,...a}):null}const M3=({title:e,titleId:t,...r},n)=>F.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?F.createElement("title",{id:t},e):null,F.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"})),$3=ae.forwardRef(M3),j3=({title:e,titleId:t,...r},n)=>F.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?F.createElement("title",{id:t},e):null,F.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"})),k3=ae.forwardRef(j3),Kt=Je.observer(({id:e,icon:t,color:r,title:n,name:a,label:s,explanation:o,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 x.jsxs(x.Fragment,{children:[x.jsxs(W.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:[x.jsx(W.SvgIcon,{component:t,sx:{color:r}}),s&&x.jsx("div",{style:{color:r},children:s})]}),x.jsx(W.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:x.jsxs(W.Stack,{gap:"1rem",padding:2,maxWidth:"450px",sx:{wordWrap:"break-word"},children:[x.jsxs("div",{children:[n&&x.jsx(W.Typography,{component:"span",fontSize:"14px",children:`${n}: `}),x.jsx(W.Typography,{component:"span",color:r,fontWeight:"bold",fontSize:"14px",children:a})]}),x.jsx(W.Typography,{fontSize:"14px",children:o}),i&&x.jsx(W.Typography,{fontSize:"12px",children:i})]})})]})}),L3=Je.observer(({isVirtual:e,motionGroupId:t,anchorOrigin:r,transformOrigin:n,compact:a})=>{const s=W.useTheme(),{t:o}=ze.useTranslation();return e?x.jsx(Kt,{id:"motion-group-virtual",icon:k3,color:s.palette.tertiary.main,name:o("SafetyBar.ControllerType.Virtual.lb"),label:a?null:o("SafetyBar.ControllerType.Virtual.lb"),explanation:x.jsxs(ze.Trans,{i18nKey:"SafetyBar.MotionGroup.Virtual.Explanation.lb",values:{motionGroupId:t},children:["Motion group ",x.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}):x.jsx(Kt,{id:"motion-group-physical",icon:$3,color:s.palette.primary.main,name:o("SafetyBar.ControllerType.Physical.lb"),label:a?null:o("SafetyBar.ControllerType.Physical.lb"),explanation:x.jsx(ze.Trans,{i18nKey:"SafetyBar.MotionGroup.Physical.Explanation.lb",values:{motionGroupId:t},components:{code:x.jsx("code",{}),strong:x.jsx("strong",{})}}),anchorOrigin:r,transformOrigin:n})}),U3=({title:e,titleId:t,...r},n)=>F.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?F.createElement("title",{id:t},e):null,F.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"})),D3=ae.forwardRef(U3),N3=({title:e,titleId:t,...r},n)=>F.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?F.createElement("title",{id:t},e):null,F.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})),F3=ae.forwardRef(N3),B3=({title:e,titleId:t,...r},n)=>F.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?F.createElement("title",{id:t},e):null,F.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"})),z3=ae.forwardRef(B3),G3=Je.observer(({operationMode:e,anchorOrigin:t,transformOrigin:r,compact:n})=>{const{t:a}=ze.useTranslation(),s=W.useTheme();switch(e){case"OPERATION_MODE_AUTO":return x.jsx(Kt,{id:"operation-mode-auto",icon:D3,title:a("SafetyBar.OperationMode.ti"),name:a("SafetyBar.OperationMode.Automatic.ti"),label:n?null:a("SafetyBar.OperationMode.Automatic.ti"),color:s.palette.text.secondary,explanation:x.jsx(ze.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 x.jsx(Kt,{id:"operation-mode-manual",icon:z3,color:s.palette.warning.main,title:a("SafetyBar.OperationMode.ti"),name:a("SafetyBar.OperationMode.Manual.lb"),label:n?null:a("SafetyBar.OperationMode.Manual.lb"),explanation:x.jsx(ze.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 x.jsx(Kt,{id:"operation-mode-error",icon:F3,color:s.palette.warning.main,title:a("SafetyBar.OperationMode.ti"),name:a("SafetyBar.OperationMode.Error.lb"),label:n?null:a("SafetyBar.OperationMode.Error.lb"),explanation:x.jsx(ze.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})}}),H3=({title:e,titleId:t,...r},n)=>F.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?F.createElement("title",{id:t},e):null,F.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"})),q3=ae.forwardRef(H3),J3=({title:e,titleId:t,...r},n)=>F.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?F.createElement("title",{id:t},e):null,F.createElement("path",{d:"M10.24 10.636 12 13.764l1.76-3.128h-3.52Z"}),F.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"}),F.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"})),W3=ae.forwardRef(J3),K3=({title:e,titleId:t,...r},n)=>F.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?F.createElement("title",{id:t},e):null,F.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})),Y3=ae.forwardRef(K3),Q3=({title:e,titleId:t,...r},n)=>F.createElement("svg",{width:24,height:24,fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?F.createElement("title",{id:t},e):null,F.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"})),X3=ae.forwardRef(Q3),Z3=({title:e,titleId:t,...r},n)=>F.createElement("svg",{width:24,height:24,xmlns:"http://www.w3.org/2000/svg",ref:n,"aria-labelledby":t,...r},e?F.createElement("title",{id:t},e):null,F.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"})),ej=ae.forwardRef(Z3),tj=Je.observer(({safetyState:e,anchorOrigin:t,transformOrigin:r,compact:n})=>{const{t:a}=ze.useTranslation(),s=W.useTheme();switch(e){case"SAFETY_STATE_NORMAL":return x.jsx(Kt,{id:"safety-state-normal",title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.Normal.lb"),label:n?null:a("SafetyBar.SafetyState.Normal.lb"),icon:X3,color:s.palette.text.secondary,explanation:x.jsx(ze.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 x.jsx(Kt,{id:"safety-state-estop",title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.Estop.lb"),label:n?null:a("SafetyBar.SafetyState.Estop.lb"),icon:W3,color:s.palette.error.main,explanation:x.jsx(ze.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 x.jsx(Kt,{id:"safety-state-stop",icon:ej,title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.Stop.lb"),label:n?null:a("SafetyBar.SafetyState.Stop.lb"),color:s.palette.warning.main,explanation:x.jsx(ze.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 x.jsx(Kt,{id:"safety-state-manual-action-required",icon:Y3,color:s.palette.warning.main,title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.ManualActionRequired.lb"),label:n?null:a("SafetyBar.SafetyState.ManualActionRequired.lb"),explanation:x.jsx(ze.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 x.jsx(Kt,{id:"safety-state-error",icon:q3,color:s.palette.error.main,title:a("SafetyBar.SafetyState.ti"),name:a("SafetyBar.SafetyState.Error.lb"),label:n?null:a("SafetyBar.SafetyState.Error.lb"),explanation:x.jsx(ze.Trans,{i18nKey:"SafetyBar.SafetyState.Error.Explanation.lb",children:"The robot controller has entered an unexpected safety state."}),literalValue:e,anchorOrigin:t,transformOrigin:r});default:b2(e,`Unknown safety state ${e}`)}}),rj=en(Je.observer(({isVirtual:e,motionGroupId:t,operationMode:r,safetyState:n,anchorOrigin:a,transformOrigin:s,compact:o=!0})=>{const i=o?1:2;return x.jsxs(W.Stack,{direction:"row",gap:i,alignItems:"center",sx:{height:"24px"},children:[x.jsx(tj,{safetyState:n,anchorOrigin:a,transformOrigin:s,compact:o}),x.jsx(W.Divider,{orientation:"vertical",flexItem:!0}),x.jsx(G3,{operationMode:r,anchorOrigin:a,transformOrigin:s,compact:o}),x.jsx(W.Divider,{orientation:"vertical",flexItem:!0}),x.jsx(L3,{isVirtual:e,motionGroupId:t,anchorOrigin:a,transformOrigin:s,compact:o})]})})),nj=W.styled(W.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}}]}}),aj=ae.forwardRef((e,t)=>x.jsx(nj,{ref:t,selected:e.selected,...e,color:"secondary",variant:"circular"})),sj={$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"},oj=ae.lazy(()=>import("@monaco-editor/react"));let fl=null;async function ij(){if(!fl){const[{createHighlighter:e},{shikiToMonaco:t}]=await Promise.all([import("shiki"),import("@shikijs/monaco")]);fl={shiki:await e({langs:[sj],themes:["dark-plus","light-plus"]}),shikiToMonaco:t}}return fl}const lj=en(e=>{const t=W.useTheme(),[r,n]=ae.useState("dark-plus"),a=t.palette.mode==="dark"?"dark-plus":"light-plus";async function s(o){var c,u;o.languages.register({id:"wandelscript"}),o.languages.setLanguageConfiguration("wandelscript",{comments:{lineComment:"#"},brackets:[["(",")"],["[","]"]],autoClosingPairs:[{open:"[",close:"]"},{open:"(",close:")"}],surroundingPairs:[{open:"[",close:"]"},{open:"(",close:")"}]});const{shiki:i,shikiToMonaco:l}=await ij();l(i,o),o.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(o),n(a)}return x.jsx(ae.Suspense,{fallback:x.jsx(Kc,{}),children:x.jsx(oj,{value:e.code,onMount:(o,i)=>{s(i)},onChange:e.onChange,defaultLanguage:"wandelscript",theme:r,options:{minimap:{enabled:!1},wordWrap:"on",automaticLayout:!0,...e.monacoOptions}})})});function qg(){var t,r,n,a,s,o,i;const e=W.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:(o=(s=e.paletteExt)==null?void 0:s.secondary)==null?void 0:o.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":W.rgbToHex(((i=e.palette.backgroundPaperElevation)==null?void 0:i[5])??""),"editor.foreground":"#d4d4d4","editorLineNumber.foreground":"#797979","editorLineNumber.activeForeground":"#e9e9e9","editor.lineHighlightBorder":"#e9e9e911"}}}}}}function cj(){const e=qg();return e.palette.mode="light",e}function uj(e){var n,a,s,o;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"&&((o=(s=window.matchMedia)==null?void 0:s.call(window,"(prefers-color-scheme: light)"))==null?void 0:o.matches)));const r=t?qg():cj();return Kp(r,e)}exports.CycleTimer=mP;exports.JoggingCartesianAxisControl=Ml;exports.JoggingJointRotationControl=Rm;exports.JoggingPanel=g3;exports.JoggingStore=xi;exports.LoadingCover=Kc;exports.LoadingErrorMessage=yg;exports.NoMotionGroupModal=S3;exports.PoseCartesianValues=b3;exports.PoseJointValues=v3;exports.PresetEnvironment=by;exports.Robot=I3;exports.SafetyBar=rj;exports.SafetyZonesRenderer=Sy;exports.SelectableFab=aj;exports.SupportedRobot=Hg;exports.TrajectoryRenderer=Oy;exports.VelocitySlider=Dg;exports.VelocitySliderLabel=tu;exports.WandelscriptEditor=lj;exports.createNovaMuiTheme=uj;exports.defaultAxisConfig=O3;exports.defaultGetModel=ru;exports.i18n=Gc;exports.useAnimationFrame=Yn;exports.useAutorun=Om;exports.useMounted=ai;exports.useReaction=wm;
|
|
115
163
|
//# sourceMappingURL=index.cjs.map
|