mirror of
git://soft.sys114.com/mainsail
synced 2026-02-04 14:30:36 +09:00
52 lines
1.4 MiB
52 lines
1.4 MiB
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/Codemirror--JcAba3g.js","assets/codemirror-ZSHHXwGs.js","assets/vuetify-Ce4WN_Dg.js","assets/overlayscrollbars-CiKU261J.js","assets/overlayscrollbars-BJn_P54_.css","assets/vuetify-BSwS9o2d.css","assets/echarts-DzoUeqWp.js","assets/virtual_pwa-register-DiXdS4qF.js","assets/Hlsstreamer-BpBN3Lzc.js","assets/Hlsstreamer-Dpcrs_uP.css","assets/Ipstreamer-BPf8FdFe.js","assets/Ipstreamer-B2DsK1lF.css","assets/JanusStreamer-CQyYvBpk.js","assets/JanusStreamer-CtR5HFZ8.css","assets/JMuxerStream-Cqmc9Hrb.js","assets/JMuxerStream-COVqP7gw.css","assets/Mjpegstreamer-vxbaTGlP.js","assets/WebcamNozzleCrosshair-OgFJAMdG.js","assets/WebcamNozzleCrosshair-nYNM-zbo.css","assets/Mjpegstreamer-BgvUrWpO.css","assets/MjpegstreamerAdaptive-Boi1-RyL.js","assets/MjpegstreamerAdaptive-BIOOAIPf.css","assets/Uv4lMjpeg-1VbXGWjy.js","assets/Uv4lMjpeg-DO1dNraK.css","assets/WebrtcCameraStreamer-CRSlmQer.js","assets/WebrtcCameraStreamer-CeCrPMao.css","assets/WebrtcMediaMTX-9dkGjohV.js","assets/WebrtcMediaMTX-D-CyIvoY.css","assets/WebrtcGo2rtc-DGvVGkMJ.js","assets/WebrtcGo2rtc-rSd4eisB.css","assets/Heightmap-1ReT1M6e.js","assets/Heightmap-Cx_CgFq_.css","assets/Viewer-DVCEMRp5.js","assets/Viewer-oTo4b16s.css"])))=>i.map(i=>d[i]);
|
||
import{V as y,_ as Pe,a as Op,b as ru,c as _,d as ae,e as S$,f as g,g as iu,h as le,i as Z,j as I,k as Ss,l as or,m as x,n as b,o as se,p as oe,q as ge,r as ot,s as $s,t as it,u as Ee,v as Wt,w as xi,x as de,y as J,z as _t,A as Ze,B as Va,C as P$,D as ye,E as Me,F as rl,G as Dr,H as T_,I as Ys,J as D$,K as Qr,L as pi,M as cs,N as gt,O as wr,P as ke,Q as Hs,R as Xt,S as Lr,T as we,U as T$,W as Zs,X as pr,Y as Nn,Z as O$,$ as nu,a0 as O_,a1 as Mp,a2 as M$,a3 as k$,a4 as E$,a5 as jr,a6 as Zn,a7 as M_,a8 as L$,a9 as A$,aa as F$,ab as R$,ac as H$,ad as j$,ae as k_,af as I$,ag as N$,ah as V$,ai as B$,aj as Ag,ak as _o,al as vo,am as U$,an as W$,ao as bo,ap as Fg,aq as z$,ar as G$,as as Z$,at as q$}from"./vuetify-Ce4WN_Dg.js";import{c as Tr,a as en,g as E_,O as jo}from"./overlayscrollbars-CiKU261J.js";import{i as X$,t as Y$,u as J$,a as K$,b as Q$,c as ex,d as tx,e as sx,f as rx,g as ix,h as nx}from"./echarts-DzoUeqWp.js";(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const n of i)if(n.type==="childList")for(const a of n.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&r(a)}).observe(document,{childList:!0,subtree:!0});function t(i){const n={};return i.integrity&&(n.integrity=i.integrity),i.referrerPolicy&&(n.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?n.credentials="include":i.crossOrigin==="anonymous"?n.credentials="omit":n.credentials="same-origin",n}function r(i){if(i.ep)return;i.ep=!0;const n=t(i);fetch(i.href,n)}})();var ax={exports:{}};(function(s){var e=function(t){var r=Object.prototype,i=r.hasOwnProperty,n=Object.defineProperty||function(R,B,T){R[B]=T.value},a,o=typeof Symbol=="function"?Symbol:{},l=o.iterator||"@@iterator",u=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function d(R,B,T){return Object.defineProperty(R,B,{value:T,enumerable:!0,configurable:!0,writable:!0}),R[B]}try{d({},"")}catch{d=function(B,T,A){return B[T]=A}}function m(R,B,T,A){var H=B&&B.prototype instanceof M?B:M,ee=Object.create(H.prototype),ie=new K(A||[]);return n(ee,"_invoke",{value:te(R,T,ie)}),ee}t.wrap=m;function h(R,B,T){try{return{type:"normal",arg:R.call(B,T)}}catch(A){return{type:"throw",arg:A}}}var f="suspendedStart",p="suspendedYield",v="executing",C="completed",P={};function M(){}function F(){}function O(){}var $={};d($,l,function(){return this});var D=Object.getPrototypeOf,V=D&&D(D(Q([])));V&&V!==r&&i.call(V,l)&&($=V);var N=O.prototype=M.prototype=Object.create($);F.prototype=O,n(N,"constructor",{value:O,configurable:!0}),n(O,"constructor",{value:F,configurable:!0}),F.displayName=d(O,c,"GeneratorFunction");function W(R){["next","throw","return"].forEach(function(B){d(R,B,function(T){return this._invoke(B,T)})})}t.isGeneratorFunction=function(R){var B=typeof R=="function"&&R.constructor;return B?B===F||(B.displayName||B.name)==="GeneratorFunction":!1},t.mark=function(R){return Object.setPrototypeOf?Object.setPrototypeOf(R,O):(R.__proto__=O,d(R,c,"GeneratorFunction")),R.prototype=Object.create(N),R},t.awrap=function(R){return{__await:R}};function G(R,B){function T(ee,ie,ue,be){var Se=h(R[ee],R,ie);if(Se.type==="throw")be(Se.arg);else{var rt=Se.arg,Pt=rt.value;return Pt&&typeof Pt=="object"&&i.call(Pt,"__await")?B.resolve(Pt.__await).then(function(jt){T("next",jt,ue,be)},function(jt){T("throw",jt,ue,be)}):B.resolve(Pt).then(function(jt){rt.value=jt,ue(rt)},function(jt){return T("throw",jt,ue,be)})}}var A;function H(ee,ie){function ue(){return new B(function(be,Se){T(ee,ie,be,Se)})}return A=A?A.then(ue,ue):ue()}n(this,"_invoke",{value:H})}W(G.prototype),d(G.prototype,u,function(){return this}),t.AsyncIterator=G,t.async=function(R,B,T,A,H){H===void 0&&(H=Promise);var ee=new G(m(R,B,T,A),H);return t.isGeneratorFunction(B)?ee:ee.next().then(function(ie){return ie.done?ie.value:ee.next()})};function te(R,B,T){var A=f;return function(ee,ie){if(A===v)throw new Error("Generator is already running");if(A===C){if(ee==="throw")throw ie;return re()}for(T.method=ee,T.arg=ie;;){var ue=T.delegate;if(ue){var be=X(ue,T);if(be){if(be===P)continue;return be}}if(T.method==="next")T.sent=T._sent=T.arg;else if(T.method==="throw"){if(A===f)throw A=C,T.arg;T.dispatchException(T.arg)}else T.method==="return"&&T.abrupt("return",T.arg);A=v;var Se=h(R,B,T);if(Se.type==="normal"){if(A=T.done?C:p,Se.arg===P)continue;return{value:Se.arg,done:T.done}}else Se.type==="throw"&&(A=C,T.method="throw",T.arg=Se.arg)}}}function X(R,B){var T=B.method,A=R.iterator[T];if(A===a)return B.delegate=null,T==="throw"&&R.iterator.return&&(B.method="return",B.arg=a,X(R,B),B.method==="throw")||T!=="return"&&(B.method="throw",B.arg=new TypeError("The iterator does not provide a '"+T+"' method")),P;var H=h(A,R.iterator,B.arg);if(H.type==="throw")return B.method="throw",B.arg=H.arg,B.delegate=null,P;var ee=H.arg;if(!ee)return B.method="throw",B.arg=new TypeError("iterator result is not an object"),B.delegate=null,P;if(ee.done)B[R.resultName]=ee.value,B.next=R.nextLoc,B.method!=="return"&&(B.method="next",B.arg=a);else return ee;return B.delegate=null,P}W(N),d(N,c,"Generator"),d(N,l,function(){return this}),d(N,"toString",function(){return"[object Generator]"});function q(R){var B={tryLoc:R[0]};1 in R&&(B.catchLoc=R[1]),2 in R&&(B.finallyLoc=R[2],B.afterLoc=R[3]),this.tryEntries.push(B)}function z(R){var B=R.completion||{};B.type="normal",delete B.arg,R.completion=B}function K(R){this.tryEntries=[{tryLoc:"root"}],R.forEach(q,this),this.reset(!0)}t.keys=function(R){var B=Object(R),T=[];for(var A in B)T.push(A);return T.reverse(),function H(){for(;T.length;){var ee=T.pop();if(ee in B)return H.value=ee,H.done=!1,H}return H.done=!0,H}};function Q(R){if(R||R===""){var B=R[l];if(B)return B.call(R);if(typeof R.next=="function")return R;if(!isNaN(R.length)){var T=-1,A=function H(){for(;++T<R.length;)if(i.call(R,T))return H.value=R[T],H.done=!1,H;return H.value=a,H.done=!0,H};return A.next=A}}throw new TypeError(typeof R+" is not iterable")}t.values=Q;function re(){return{value:a,done:!0}}return K.prototype={constructor:K,reset:function(R){if(this.prev=0,this.next=0,this.sent=this._sent=a,this.done=!1,this.delegate=null,this.method="next",this.arg=a,this.tryEntries.forEach(z),!R)for(var B in this)B.charAt(0)==="t"&&i.call(this,B)&&!isNaN(+B.slice(1))&&(this[B]=a)},stop:function(){this.done=!0;var R=this.tryEntries[0],B=R.completion;if(B.type==="throw")throw B.arg;return this.rval},dispatchException:function(R){if(this.done)throw R;var B=this;function T(be,Se){return ee.type="throw",ee.arg=R,B.next=be,Se&&(B.method="next",B.arg=a),!!Se}for(var A=this.tryEntries.length-1;A>=0;--A){var H=this.tryEntries[A],ee=H.completion;if(H.tryLoc==="root")return T("end");if(H.tryLoc<=this.prev){var ie=i.call(H,"catchLoc"),ue=i.call(H,"finallyLoc");if(ie&&ue){if(this.prev<H.catchLoc)return T(H.catchLoc,!0);if(this.prev<H.finallyLoc)return T(H.finallyLoc)}else if(ie){if(this.prev<H.catchLoc)return T(H.catchLoc,!0)}else if(ue){if(this.prev<H.finallyLoc)return T(H.finallyLoc)}else throw new Error("try statement without catch or finally")}}},abrupt:function(R,B){for(var T=this.tryEntries.length-1;T>=0;--T){var A=this.tryEntries[T];if(A.tryLoc<=this.prev&&i.call(A,"finallyLoc")&&this.prev<A.finallyLoc){var H=A;break}}H&&(R==="break"||R==="continue")&&H.tryLoc<=B&&B<=H.finallyLoc&&(H=null);var ee=H?H.completion:{};return ee.type=R,ee.arg=B,H?(this.method="next",this.next=H.finallyLoc,P):this.complete(ee)},complete:function(R,B){if(R.type==="throw")throw R.arg;return R.type==="break"||R.type==="continue"?this.next=R.arg:R.type==="return"?(this.rval=this.arg=R.arg,this.method="return",this.next="end"):R.type==="normal"&&B&&(this.next=B),P},finish:function(R){for(var B=this.tryEntries.length-1;B>=0;--B){var T=this.tryEntries[B];if(T.finallyLoc===R)return this.complete(T.completion,T.afterLoc),z(T),P}},catch:function(R){for(var B=this.tryEntries.length-1;B>=0;--B){var T=this.tryEntries[B];if(T.tryLoc===R){var A=T.completion;if(A.type==="throw"){var H=A.arg;z(T)}return H}}throw new Error("illegal catch attempt")},delegateYield:function(R,B,T){return this.delegate={iterator:Q(R),resultName:B,nextLoc:T},this.method==="next"&&(this.arg=a),P}},t}(s.exports);try{regeneratorRuntime=e}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=e:Function("r","regeneratorRuntime = r")(e)}})(ax);var L_=function(){if(typeof Map<"u")return Map;function s(e,t){var r=-1;return e.some(function(i,n){return i[0]===t?(r=n,!0):!1}),r}return function(){function e(){this.__entries__=[]}return Object.defineProperty(e.prototype,"size",{get:function(){return this.__entries__.length},enumerable:!0,configurable:!0}),e.prototype.get=function(t){var r=s(this.__entries__,t),i=this.__entries__[r];return i&&i[1]},e.prototype.set=function(t,r){var i=s(this.__entries__,t);~i?this.__entries__[i][1]=r:this.__entries__.push([t,r])},e.prototype.delete=function(t){var r=this.__entries__,i=s(r,t);~i&&r.splice(i,1)},e.prototype.has=function(t){return!!~s(this.__entries__,t)},e.prototype.clear=function(){this.__entries__.splice(0)},e.prototype.forEach=function(t,r){r===void 0&&(r=null);for(var i=0,n=this.__entries__;i<n.length;i++){var a=n[i];t.call(r,a[1],a[0])}},e}()}(),um=typeof window<"u"&&typeof document<"u"&&window.document===document,il=function(){return typeof global<"u"&&global.Math===Math?global:typeof self<"u"&&self.Math===Math?self:typeof window<"u"&&window.Math===Math?window:Function("return this")()}(),ox=function(){return typeof requestAnimationFrame=="function"?requestAnimationFrame.bind(il):function(s){return setTimeout(function(){return s(Date.now())},1e3/60)}}(),lx=2;function cx(s,e){var t=!1,r=!1,i=0;function n(){t&&(t=!1,s()),r&&o()}function a(){ox(n)}function o(){var l=Date.now();if(t){if(l-i<lx)return;r=!0}else t=!0,r=!1,setTimeout(a,e);i=l}return o}var ux=20,dx=["top","right","bottom","left","width","height","size","weight"],mx=typeof MutationObserver<"u",hx=function(){function s(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=cx(this.refresh.bind(this),ux)}return s.prototype.addObserver=function(e){~this.observers_.indexOf(e)||this.observers_.push(e),this.connected_||this.connect_()},s.prototype.removeObserver=function(e){var t=this.observers_,r=t.indexOf(e);~r&&t.splice(r,1),!t.length&&this.connected_&&this.disconnect_()},s.prototype.refresh=function(){var e=this.updateObservers_();e&&this.refresh()},s.prototype.updateObservers_=function(){var e=this.observers_.filter(function(t){return t.gatherActive(),t.hasActive()});return e.forEach(function(t){return t.broadcastActive()}),e.length>0},s.prototype.connect_=function(){!um||this.connected_||(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),mx?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},s.prototype.disconnect_=function(){!um||!this.connected_||(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},s.prototype.onTransitionEnd_=function(e){var t=e.propertyName,r=t===void 0?"":t,i=dx.some(function(n){return!!~r.indexOf(n)});i&&this.refresh()},s.getInstance=function(){return this.instance_||(this.instance_=new s),this.instance_},s.instance_=null,s}(),A_=function(s,e){for(var t=0,r=Object.keys(e);t<r.length;t++){var i=r[t];Object.defineProperty(s,i,{value:e[i],enumerable:!1,writable:!1,configurable:!0})}return s},wi=function(s){var e=s&&s.ownerDocument&&s.ownerDocument.defaultView;return e||il},F_=au(0,0,0,0);function nl(s){return parseFloat(s)||0}function Rg(s){for(var e=[],t=1;t<arguments.length;t++)e[t-1]=arguments[t];return e.reduce(function(r,i){var n=s["border-"+i+"-width"];return r+nl(n)},0)}function px(s){for(var e=["top","right","bottom","left"],t={},r=0,i=e;r<i.length;r++){var n=i[r],a=s["padding-"+n];t[n]=nl(a)}return t}function fx(s){var e=s.getBBox();return au(0,0,e.width,e.height)}function gx(s){var e=s.clientWidth,t=s.clientHeight;if(!e&&!t)return F_;var r=wi(s).getComputedStyle(s),i=px(r),n=i.left+i.right,a=i.top+i.bottom,o=nl(r.width),l=nl(r.height);if(r.boxSizing==="border-box"&&(Math.round(o+n)!==e&&(o-=Rg(r,"left","right")+n),Math.round(l+a)!==t&&(l-=Rg(r,"top","bottom")+a)),!vx(s)){var u=Math.round(o+n)-e,c=Math.round(l+a)-t;Math.abs(u)!==1&&(o-=u),Math.abs(c)!==1&&(l-=c)}return au(i.left,i.top,o,l)}var _x=function(){return typeof SVGGraphicsElement<"u"?function(s){return s instanceof wi(s).SVGGraphicsElement}:function(s){return s instanceof wi(s).SVGElement&&typeof s.getBBox=="function"}}();function vx(s){return s===wi(s).document.documentElement}function bx(s){return um?_x(s)?fx(s):gx(s):F_}function yx(s){var e=s.x,t=s.y,r=s.width,i=s.height,n=typeof DOMRectReadOnly<"u"?DOMRectReadOnly:Object,a=Object.create(n.prototype);return A_(a,{x:e,y:t,width:r,height:i,top:t,right:e+r,bottom:i+t,left:e}),a}function au(s,e,t,r){return{x:s,y:e,width:t,height:r}}var Cx=function(){function s(e){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=au(0,0,0,0),this.target=e}return s.prototype.isActive=function(){var e=bx(this.target);return this.contentRect_=e,e.width!==this.broadcastWidth||e.height!==this.broadcastHeight},s.prototype.broadcastRect=function(){var e=this.contentRect_;return this.broadcastWidth=e.width,this.broadcastHeight=e.height,e},s}(),$x=function(){function s(e,t){var r=yx(t);A_(this,{target:e,contentRect:r})}return s}(),xx=function(){function s(e,t,r){if(this.activeObservations_=[],this.observations_=new L_,typeof e!="function")throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=e,this.controller_=t,this.callbackCtx_=r}return s.prototype.observe=function(e){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(e instanceof wi(e).Element))throw new TypeError('parameter 1 is not of type "Element".');var t=this.observations_;t.has(e)||(t.set(e,new Cx(e)),this.controller_.addObserver(this),this.controller_.refresh())}},s.prototype.unobserve=function(e){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(e instanceof wi(e).Element))throw new TypeError('parameter 1 is not of type "Element".');var t=this.observations_;t.has(e)&&(t.delete(e),t.size||this.controller_.removeObserver(this))}},s.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},s.prototype.gatherActive=function(){var e=this;this.clearActive(),this.observations_.forEach(function(t){t.isActive()&&e.activeObservations_.push(t)})},s.prototype.broadcastActive=function(){if(this.hasActive()){var e=this.callbackCtx_,t=this.activeObservations_.map(function(r){return new $x(r.target,r.broadcastRect())});this.callback_.call(e,t,e),this.clearActive()}},s.prototype.clearActive=function(){this.activeObservations_.splice(0)},s.prototype.hasActive=function(){return this.activeObservations_.length>0},s}(),R_=typeof WeakMap<"u"?new WeakMap:new L_,H_=function(){function s(e){if(!(this instanceof s))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var t=hx.getInstance(),r=new xx(e,t,this);R_.set(this,r)}return s}();["observe","unobserve","disconnect"].forEach(function(s){H_.prototype[s]=function(){var e;return(e=R_.get(this))[s].apply(e,arguments)}});(function(){return typeof il.ResizeObserver<"u"?il.ResizeObserver:H_})();/**
|
||
* vue-class-component v7.2.6
|
||
* (c) 2015-present Evan You
|
||
* @license MIT
|
||
*/function Io(s){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Io=function(e){return typeof e}:Io=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Io(s)}function wx(s,e,t){return e in s?Object.defineProperty(s,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):s[e]=t,s}function Sx(s){return Px(s)||Dx(s)||Tx()}function Px(s){if(Array.isArray(s)){for(var e=0,t=new Array(s.length);e<s.length;e++)t[e]=s[e];return t}}function Dx(s){if(Symbol.iterator in Object(s)||Object.prototype.toString.call(s)==="[object Arguments]")return Array.from(s)}function Tx(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function Ox(){return typeof Reflect<"u"&&Reflect.defineMetadata&&Reflect.getOwnMetadataKeys}function Mx(s,e){Od(s,e),Object.getOwnPropertyNames(e.prototype).forEach(function(t){Od(s.prototype,e.prototype,t)}),Object.getOwnPropertyNames(e).forEach(function(t){Od(s,e,t)})}function Od(s,e,t){var r=t?Reflect.getOwnMetadataKeys(e,t):Reflect.getOwnMetadataKeys(e);r.forEach(function(i){var n=t?Reflect.getOwnMetadata(i,e,t):Reflect.getOwnMetadata(i,e);t?Reflect.defineMetadata(i,n,s,t):Reflect.defineMetadata(i,n,s)})}var kx={__proto__:[]},Ex=kx instanceof Array;function ou(s){return function(e,t,r){var i=typeof e=="function"?e:e.constructor;i.__decorators__||(i.__decorators__=[]),typeof r!="number"&&(r=void 0),i.__decorators__.push(function(n){return s(n,t,r)})}}function k(){for(var s=arguments.length,e=new Array(s),t=0;t<s;t++)e[t]=arguments[t];return y.extend({mixins:e})}function Lx(s){var e=Io(s);return s==null||e!=="object"&&e!=="function"}function Ax(s,e){var t=e.prototype._init;e.prototype._init=function(){var n=this,a=Object.getOwnPropertyNames(s);if(s.$options.props)for(var o in s.$options.props)s.hasOwnProperty(o)||a.push(o);a.forEach(function(l){Object.defineProperty(n,l,{get:function(){return s[l]},set:function(c){s[l]=c},configurable:!0})})};var r=new e;e.prototype._init=t;var i={};return Object.keys(r).forEach(function(n){r[n]!==void 0&&(i[n]=r[n])}),i}var dm=["data","beforeCreate","created","beforeMount","mounted","beforeDestroy","destroyed","beforeUpdate","updated","activated","deactivated","render","errorCaptured","serverPrefetch"];function Hg(s){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};e.name=e.name||s._componentTag||s.name;var t=s.prototype;Object.getOwnPropertyNames(t).forEach(function(o){if(o!=="constructor"){if(dm.indexOf(o)>-1){e[o]=t[o];return}var l=Object.getOwnPropertyDescriptor(t,o);l.value!==void 0?typeof l.value=="function"?(e.methods||(e.methods={}))[o]=l.value:(e.mixins||(e.mixins=[])).push({data:function(){return wx({},o,l.value)}}):(l.get||l.set)&&((e.computed||(e.computed={}))[o]={get:l.get,set:l.set})}}),(e.mixins||(e.mixins=[])).push({data:function(){return Ax(this,s)}});var r=s.__decorators__;r&&(r.forEach(function(o){return o(e)}),delete s.__decorators__);var i=Object.getPrototypeOf(s.prototype),n=i instanceof y?i.constructor:y,a=n.extend(e);return Rx(a,s,n),Ox()&&Mx(a,s),a}var Fx={prototype:!0,arguments:!0,callee:!0,caller:!0};function Rx(s,e,t){Object.getOwnPropertyNames(e).forEach(function(r){if(!Fx[r]){var i=Object.getOwnPropertyDescriptor(s,r);if(!(i&&!i.configurable)){var n=Object.getOwnPropertyDescriptor(e,r);if(!Ex){if(r==="cid")return;var a=Object.getOwnPropertyDescriptor(t,r);if(!Lx(n.value)&&a&&a.value===n.value)return}Object.defineProperty(s,r,n)}}})}function S(s){return typeof s=="function"?Hg(s):function(e){return Hg(e,s)}}S.registerHooks=function(e){dm.push.apply(dm,Sx(e))};var Hx=typeof Reflect<"u"&&typeof Reflect.getMetadata<"u";function jx(s,e,t){if(Hx&&!Array.isArray(s)&&typeof s!="function"&&!s.hasOwnProperty("type")&&typeof s.type>"u"){var r=Reflect.getMetadata("design:type",e,t);r!==Object&&(s.type=r)}}function w(s){return s===void 0&&(s={}),function(e,t){jx(s,e,t),ou(function(r,i){(r.props||(r.props={}))[i]=s})(e,t)}}function Ts(s){return ou(function(e,t){e.computed=e.computed||{},e.computed[t]={cache:!1,get:function(){return this.$refs[s||t]}}})}function Ix(s){s===void 0&&(s={});var e="value";return ou(function(t,r){(t.props||(t.props={}))[e]=s,(t.computed||(t.computed={}))[r]={get:function(){return this[e]},set:function(i){this.$emit("input",i)}}})}function he(s,e){e===void 0&&(e={});var t=e.deep,r=t===void 0?!1:t,i=e.immediate,n=i===void 0?!1:i;return ou(function(a,o){typeof a.watch!="object"&&(a.watch=Object.create(null));var l=a.watch;typeof l[s]=="object"&&!Array.isArray(l[s])?l[s]=[l[s]]:typeof l[s]>"u"&&(l[s]=[]),l[s].push({handler:o,deep:r,immediate:n})})}var Nx=Object.getOwnPropertyDescriptor,Vx=(s,e,t,r)=>{for(var i=r>1?void 0:r?Nx(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let L=class extends y{get apiUrl(){return this.$store.getters["socket/getUrl"]}get hostUrl(){return this.$store.getters["socket/getHostUrl"]}get hostPort(){var s;return parseInt((s=this.$store.state.socket.port)!=null?s:80)}get instancesDB(){var s;return(s=this.$store.state.instancesDB)!=null?s:"moonraker"}get socketIsConnected(){var s;return(s=this.$store.state.socket.isConnected)!=null?s:!1}get guiIsReady(){return this.$store.state.socket.initializationList.length===0}get klippyIsConnected(){var s;return(s=this.$store.state.server.klippy_connected)!=null?s:!1}get klipperState(){var s;return this.klippyIsConnected?(s=this.$store.state.server.klippy_state)!=null?s:"":"disconnected"}get klipperReadyForGui(){return this.socketIsConnected&&this.klipperState==="ready"}get klipperAppName(){var s;return(s=this.$store.state.printer.app_name)!=null?s:"Klipper"}get printerIsPrinting(){return this.klipperReadyForGui&&["printing","paused"].includes(this.printer_state)}get printerIsPrintingOnly(){return this.klipperReadyForGui&&this.printer_state==="printing"}get printerPowerDevice(){var t,r,i,n;const s=(t=this.$store.state.gui.uiSettings.powerDeviceName)!=null?t:null;return s!==null?s:(n=(i=((r=this.$store.getters["server/power/getDevices"])!=null?r:[]).find(a=>a.device.toLowerCase()==="printer"))==null?void 0:i.device)!=null?n:"printer"}get isPrinterPowerOff(){var r;const s=(r=this.$store.getters["server/power/getDevices"])!=null?r:[];if(s.length===0)return!1;const e=s.findIndex(i=>i.device===this.printerPowerDevice);return e===-1||s[e].status!=="off"?!1:!this.klippyIsConnected}get loadings(){var s;return(s=this.$store.state.socket.loadings)!=null?s:[]}get printer_state(){var t,r,i,n,a,o;const s=(n=(i=(t=this.$store.state.printer.print_stats)==null?void 0:t.state)!=null?i:(r=this.$store.state.printer.idle_timeout)==null?void 0:r.state)!=null?n:"",e=(o=(a=this.$store.state.printer["gcode_macro TIMELAPSE_TAKE_FRAME"])==null?void 0:a.is_paused)!=null?o:!1;return s==="paused"&&e?"printing":s}get isMobile(){return this.$vuetify.breakpoint.mobile}get isTablet(){return this.$vuetify.breakpoint.smAndUp&&!this.isDesktop&&!this.isWidescreen}get isDesktop(){return this.$vuetify.breakpoint.lgAndUp&&!this.isWidescreen}get isWidescreen(){return this.$vuetify.breakpoint.xl}get viewport(){return this.isMobile?"mobile":this.isTablet?"tablet":this.isDesktop?"desktop":"widescreen"}get isTouchDevice(){return"ontouchstart"in window||navigator.maxTouchPoints>0&&navigator.maxTouchPoints!==256}get isIOS(){return!!(navigator.userAgent.match(/(iPad|iPhone|iPod)/)||navigator.platform==="MacIntel"&&typeof navigator.standalone<"u")}get moonrakerComponents(){var s,e;return(e=(s=this.$store.state.server)==null?void 0:s.components)!=null?e:[]}get existGcodesRootDirectory(){return this.$store.state.server.registered_directories.findIndex(e=>e==="gcodes")>=0}get formatDateOptions(){switch(this.$store.state.gui.general.dateFormat){case"2-digits":return{day:"2-digit",month:"2-digit",year:"numeric"};case"short":return{day:"2-digit",month:"short",year:"numeric"};default:return{dateStyle:"medium"}}}get formatTimeOptions(){switch(this.$store.state.gui.general.timeFormat){case"24hours":return{hour:"2-digit",minute:"2-digit",hourCycle:"h23"};case"12hours":return{hour:"2-digit",minute:"2-digit",hourCycle:"h12"};default:return{timeStyle:"short"}}}get formatTimeWithSecondsOptions(){switch(this.$store.state.gui.general.timeFormat){case"24hours":return{hour:"2-digit",minute:"2-digit",second:"2-digit",hourCycle:"h23"};case"12hours":return{hour:"2-digit",minute:"2-digit",second:"2-digit",hourCycle:"h12"};default:return{timeStyle:"short"}}}get browserLocale(){return navigator.language}get hours12Format(){return this.$store.getters["gui/getHours12Format"]}formatDate(s){let e=null;try{e=typeof s.getMonth=="function"?s:new Date(s)}catch{return"UNKNOWN"}return e.toLocaleDateString(this.browserLocale,this.formatDateOptions)}formatTime(s,e=!1){let t=null;try{t=typeof s.getMonth=="function"?s:new Date(s)}catch{return"UNKNOWN"}return e?t.toLocaleTimeString(this.browserLocale,this.formatTimeWithSecondsOptions):t.toLocaleTimeString(this.browserLocale,this.formatTimeOptions)}formatDateTime(s,e=!1){const t=this.formatDate(s),r=this.formatTime(s,e);return"".concat(t," ").concat(r)}};L=Vx([S],L);var Bx=Object.defineProperty,Ux=Object.getOwnPropertyDescriptor,kp=(s,e,t,r)=>{for(var i=r>1?void 0:r?Ux(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&Bx(e,t,i),i};let qn=class extends k(L){get colorMainsail(){return"200,200,200"}get colorMoonraker(){return this.moonraker?"200,200,200":"115,115,115"}get colorKlipper(){return this.klipper?"200,200,200":"115,115,115"}};kp([w({default:!1})],qn.prototype,"moonraker",2);kp([w({default:!1})],qn.prototype,"klipper",2);qn=kp([S],qn);function E(s,e,t,r,i,n,a,o){var l=typeof s=="function"?s.options:s;return e&&(l.render=e,l.staticRenderFns=t,l._compiled=!0),n&&(l._scopeId="data-v-"+n),{exports:s,options:l}}var Wx=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("svg",{staticStyle:{"fill-rule":"evenodd","clip-rule":"evenodd","stroke-linejoin":"round","stroke-miterlimit":"2"},attrs:{width:"100%",height:"100%",viewBox:"0 0 430 70",version:"1.1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","xml:space":"preserve","xmlns:serif":"http://www.serif.com/"}},[t("g",{attrs:{id:"Mainsail",transform:"matrix(1,0,0,1,10,0)"}},[t("g",{attrs:{id:"Mainsail_text",transform:"matrix(1,0,0,1,-54.2745,6.1424)"}},[t("text",{style:"font-family:Roboto;font-size:16px;fill:rgb("+e.colorMainsail+");",attrs:{x:"47.429px",y:"60.749px"}},[e._v(" Mainsail ")])]),t("g",{attrs:{id:"Mainsail_icon",transform:"matrix(1.00478,0,0,1.00478,-1.35436,-0.18202)"}},[t("g",{attrs:{transform:"matrix(0.101469,0,0,0.101469,1.34792,1.1764)"}},[t("path",{style:"fill:rgb("+e.colorMainsail+");fill-rule:nonzero;",attrs:{d:"M286.718,107.235L99.735,392.115L0,392.01L258.225,0C264.135,36.795 273.9,73.26 286.718,107.235"}})]),t("g",{attrs:{transform:"matrix(0.101469,0,0,0.101469,1.34792,1.1764)"}},[t("path",{style:"fill:rgb("+e.colorMainsail+");fill-rule:nonzero;",attrs:{d:"M309.96,160.155L156.375,392.19L256.08,392.332L357.353,237.585C339.518,213.218 323.648,187.328 309.96,160.155"}})]),t("g",{attrs:{transform:"matrix(0.101469,0,0,0.101469,1.34792,1.1764)"}},[t("path",{style:"fill:rgb("+e.colorMainsail+");fill-rule:nonzero;",attrs:{d:"M449.535,335.768L412.597,392.332L312.75,392.115L388.95,276.862C407.61,298.012 427.868,317.707 449.535,335.767L449.535,335.768Z"}})])])]),t("g",{attrs:{id:"Mainsail_Moonraker",transform:"matrix(1,0,0,1,1.49628,0)"}},[t("g",{attrs:{id:"arrow_left1","serif:id":"arrow_left",transform:"matrix(0.687874,0,0,0.721154,20.3568,-15.8811)"}},[t("path",{style:"fill:rgb("+e.colorMoonraker+")",attrs:{d:"M93.918,56.626L93.918,60.724L73.299,52.528L93.918,44.333L93.918,48.431L118.741,48.431L118.741,56.626L93.918,56.626Z"}})]),t("g",{attrs:{id:"arrow_right1","serif:id":"arrow_right",transform:"matrix(-0.687874,-8.42403e-17,8.83159e-17,-0.721154,217.125,59.8811)"}},[t("path",{style:"fill:rgb("+e.colorMoonraker+")",attrs:{d:"M93.918,56.626L93.918,60.724L73.299,52.528L93.918,44.333L93.918,48.431L118.741,48.431L118.741,56.626L93.918,56.626Z"}})]),e.moonraker?t("g",{attrs:{id:"success1","serif:id":"success",transform:"matrix(1.1,0,0,1.1,105.541,9.8)"}},[t("path",{staticStyle:{fill:"rgb(38, 203, 124)","fill-rule":"nonzero"},attrs:{d:"M20,12C20,16.389 16.389,20 12,20C7.611,20 4,16.389 4,12C4,7.611 7.611,4 12,4C12.76,4 13.5,4.11 14.2,4.31L15.77,2.74C14.61,2.26 13.34,2 12,2C6.514,2 2,6.514 2,12C2,17.486 6.514,22 12,22C17.486,22 22,17.486 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z"}})]):t("g",{attrs:{id:"alert1","serif:id":"alert",transform:"matrix(1.1,0,0,1.1,105.541,9.8)"}},[t("path",{staticStyle:{fill:"rgb(245, 124, 5)","fill-rule":"nonzero"},attrs:{d:"M11,15L13,15L13,17L11,17L11,15M11,7L13,7L13,13L11,13L11,7M12,2C6.47,2 2,6.5 2,12C2,17.486 6.514,22 12,22C17.486,22 22,17.486 22,12C22,6.514 17.486,2 12,2M12,20C7.611,20 4,16.389 4,12C4,7.611 7.611,4 12,4C16.389,4 20,7.611 20,12C20,16.389 16.389,20 12,20Z"}})])]),t("g",{attrs:{id:"Moonraker",transform:"matrix(1,0,0,1,10,0)"}},[t("g",{attrs:{id:"Moonraker_text",transform:"matrix(1,0,0,1,120.368,6.1424)"}},[t("text",{style:"fill:rgb("+e.colorMoonraker+");font-family:Roboto;font-size:16px;",attrs:{x:"45.429px",y:"60.749px"}},[e._v(" Moonraker ")])]),t("g",{attrs:{id:"Moonraker_icon",transform:"matrix(2,0,0,2,181,-5)"}},[t("path",{style:"fill:rgb("+e.colorMoonraker+");fill-rule:nonzero;",attrs:{d:"M13,19L14,19C14.549,19 15,19.451 15,20L22,20L22,22L15,22C15,22.549 14.549,23 14,23L10,23C9.451,23 9,22.549 9,22L2,22L2,20L9,20C9,19.451 9.451,19 10,19L11,19L11,17L4,17C3.451,17 3,16.549 3,16L3,12C3,11.451 3.451,11 4,11L20,11C20.549,11 21,11.451 21,12L21,16C21,16.549 20.549,17 20,17L13,17L13,19M4,3L20,3C20.549,3 21,3.451 21,4L21,8C21,8.549 20.549,9 20,9L4,9C3.451,9 3,8.549 3,8L3,4C3,3.451 3.451,3 4,3M9,7L10,7L10,5L9,5L9,7M9,15L10,15L10,13L9,13L9,15M5,5L5,7L7,7L7,5L5,5M5,13L5,15L7,15L7,13L5,13Z"}})])]),t("g",{attrs:{id:"Moonraker_Klipper",transform:"matrix(1,0,0,1,194.593,0)"}},[t("g",{attrs:{id:"arrow_left",transform:"matrix(0.687874,0,0,0.721154,20.3568,-15.8811)"}},[t("path",{staticStyle:{fill:"rgb(115, 115, 115)"},attrs:{d:"M93.918,56.626L93.918,60.724L73.299,52.528L93.918,44.333L93.918,48.431L118.741,48.431L118.741,56.626L93.918,56.626Z"}})]),t("g",{attrs:{id:"arrow_right",transform:"matrix(-0.687874,-8.42403e-17,8.83159e-17,-0.721154,217.125,59.8811)"}},[t("path",{staticStyle:{fill:"rgb(115, 115, 115)"},attrs:{d:"M93.918,56.626L93.918,60.724L73.299,52.528L93.918,44.333L93.918,48.431L118.741,48.431L118.741,56.626L93.918,56.626Z"}})]),e.moonraker?[e.klipper?t("g",{attrs:{id:"success",transform:"matrix(1.1,0,0,1.1,105.541,9.8)"}},[t("path",{staticStyle:{fill:"rgb(38, 203, 124)","fill-rule":"nonzero"},attrs:{d:"M20,12C20,16.389 16.389,20 12,20C7.611,20 4,16.389 4,12C4,7.611 7.611,4 12,4C12.76,4 13.5,4.11 14.2,4.31L15.77,2.74C14.61,2.26 13.34,2 12,2C6.514,2 2,6.514 2,12C2,17.486 6.514,22 12,22C17.486,22 22,17.486 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z"}})]):t("g",{attrs:{id:"alert",transform:"matrix(1.1,0,0,1.1,105.541,9.8)"}},[t("path",{staticStyle:{fill:"rgb(245, 124, 5)","fill-rule":"nonzero"},attrs:{d:"M11,15L13,15L13,17L11,17L11,15M11,7L13,7L13,13L11,13L11,7M12,2C6.47,2 2,6.5 2,12C2,17.486 6.514,22 12,22C17.486,22 22,17.486 22,12C22,6.514 17.486,2 12,2M12,20C7.611,20 4,16.389 4,12C4,7.611 7.611,4 12,4C16.389,4 20,7.611 20,12C20,16.389 16.389,20 12,20Z"}})])]:[t("g",{attrs:{id:"unknown",transform:"matrix(1.1,0,0,1.1,105.541,9.8)"}},[t("path",{staticStyle:{fill:"rgb(115, 115, 115)","fill-rule":"nonzero"},attrs:{d:"M11,18L13,18L13,16L11,16L11,18M12,2C6.514,2 2,6.514 2,12C2,17.486 6.514,22 12,22C17.486,22 22,17.486 22,12C22,6.514 17.486,2 12,2M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,6C9.806,6 8,7.806 8,10L10,10C10,8.903 10.903,8 12,8C13.097,8 14,8.903 14,10C14,12 11,11.75 11,15L13,15C13,12.75 16,12.5 16,10C16,7.806 14.194,6 12,6Z"}})])]],2),t("g",{attrs:{id:"Klipper",transform:"matrix(1,0,0,1,10,0)"}},[t("g",{attrs:{id:"Klipper_text",transform:"matrix(1,0,0,1,317.036,6.1424)"}},[t("text",{style:"font-family:Roboto;font-size:16px;fill:rgb("+e.colorKlipper+");",attrs:{x:"48.429px",y:"60.749px"}},[e._v(" Klipper ")])]),t("g",{attrs:{id:"Klipper_icon",transform:"matrix(2,0,0,2,366,-3)"}},[t("path",{style:"fill:rgb("+e.colorKlipper+");fill-rule:nonzero;",attrs:{d:"M19,6C19.549,6 20,5.549 20,5C20,4.451 19.549,4 19,4C18.451,4 18,4.451 18,5C18,5.549 18.451,6 19,6M19,2C20.646,2 22,3.354 22,5L22,11L18,11L18,7L6,7L6,11L2,11L2,5C2,3.354 3.354,2 5,2L19,2M18,18.25C18,18.63 17.79,18.96 17.47,19.13L12.57,21.82C12.4,21.94 12.21,22 12,22C11.79,22 11.59,21.94 11.43,21.82L6.53,19.13C6.21,18.96 6,18.63 6,18.25L6,13C6,12.62 6.21,12.29 6.53,12.12L11.43,9.68C11.59,9.56 11.79,9.5 12,9.5C12.21,9.5 12.4,9.56 12.57,9.68L17.47,12.12C17.79,12.29 18,12.62 18,13L18,18.25M12,11.65L9.04,13L12,14.6L14.96,13L12,11.65M8,17.66L11,19.29L11,16.33L8,14.71L8,17.66M16,17.66L16,14.71L13,16.33L13,19.29L16,17.66Z"}})])])])},zx=[],Gx=E(qn,Wx,zx,!1,null,null);const lu=Gx.exports,j_="dark",I_="mainsail",Ir="#D41216",al="#2196f3",At="#1e1e1e",jg="v0.11.0-257",Ig="v0.8.0-306",Zx=[{name:"safari",version:"16.5.2"}],qx=["#F44336","#8e379d","#03DAC5","#3F51B5","#ffde03","#009688","#E91E63"],Xx="#2196F3",Yx="#4CAF50",N_="99",V_="44",Si=".theme",Jx=1e3,Ln=["temperature","target","power","speed"],Xn=["power","speed"],Kx=["aht10","bme280","htu21d","sgp40","sht3x"],Pi=[".gcode",".g",".gco",".ufp",".nc"],B_=["history","power","updateManager","timelapse","jobQueue","announcements","spoolman","sensor"],Qx=["virtual_sdcard","pause_resume","gcode_macro pause","gcode_macro resume","gcode_macro cancel_print"],ew=["uuid","estimated_time","filament_name","filament_type","filament_total","filament_weight_total","nozzle_diameter","first_layer_bed_temp","first_layer_extr_temp","chamber_temp","first_layer_height","gcode_end_byte","gcode_start_byte","job_id","layer_height","object_height","print_start_time","size","slicer","slicer_version","thumbnails"],yo=500,tw=50,sw=["toolhead-control","extruder-control","macros","machine-settings","miniconsole","miscellaneous","spoolman","temperature","webcam"],Yt=30,Jt=64,Ls=128,rw=220,iw=48,mm=48,Vn=48,nw=["^_TIMELAPSE_NEW_FRAME","^TIMELAPSE_TAKE_FRAME","^TIMELAPSE_RENDER","^_SET_TIMELAPSE_SETUP","^HYPERLAPSE ACTION=","^SET_GCODE_VARIABLE MACRO=TIMELAPSE_"],aw=["gcodes","timelapse","timelapse_frames"],ow=[".git"],lw=["klippy","moonraker","crowsnest","mmu","sonar"],cw=["klipper","moonraker"],Ci=[{name:"mainsail",displayName:"Mainsail",colorLogo:Ir},{name:"klipper",displayName:"Klipper",colorLogo:"#b12f35",logo:{show:!0,light:!1}},{name:"voron",displayName:"Voron Design",colorLogo:"#FF2300",logo:{show:!0,light:!1}},{name:"ldo",displayName:"LDO Motion (Sponsor)",colorLogo:"#326799",colorPrimary:"#326799",logo:{show:!0,light:!1}},{name:"yumi",displayName:"YUMI (Sponsor)",colorLogo:"#F6CF3D",colorPrimary:"#F6CF3D",logo:{show:!0,light:!1}},{name:"vzbot",displayName:"VzBot",colorLogo:"#FF0000",logo:{show:!0,light:!1},sidebarBackground:{show:!0,light:!1},css:!0},{name:"prusa",displayName:"Prusa Research (Sponsor)",colorLogo:"#fa6831",colorPrimary:"#fa6831",logo:{show:!0,light:!1}},{name:"btt",displayName:"BigTreeTech (Sponsor)",colorLogo:"#ef0025",logo:{show:!0,light:!1}},{name:"multec",displayName:"Multec GmbH (Sponsor)",colorLogo:"#234D7A",colorPrimary:"#234D7A",logo:{show:!0,light:!1}}],Ng={Klipper:{url:"https://www.klipper3d.org/",docsLanguages:["it","hu","zh"]},Kalico:{url:"https://docs.kalico.gg/"}};var tn="M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M15,12A3,3 0 0,1 12,15A3,3 0 0,1 9,12A3,3 0 0,1 12,9A3,3 0 0,1 15,12Z",Yn="M12,20A7,7 0 0,1 5,13A7,7 0 0,1 12,6A7,7 0 0,1 19,13A7,7 0 0,1 12,20M12,4A9,9 0 0,0 3,13A9,9 0 0,0 12,22A9,9 0 0,0 21,13A9,9 0 0,0 12,4M12.5,8H11V14L15.75,16.85L16.5,15.62L12.5,13.25V8M7.88,3.39L6.6,1.86L2,5.71L3.29,7.24L7.88,3.39M22,5.72L17.4,1.86L16.11,3.39L20.71,7.25L22,5.72Z",uw="M9.29,3.25L5.16,6.72L4,5.34L8.14,1.87L9.29,3.25M22,5.35L20.84,6.73L16.7,3.25L17.86,1.87L22,5.35M13,4A8,8 0 0,1 21,12A8,8 0 0,1 13,20A8,8 0 0,1 5,12A8,8 0 0,1 13,4M13,6A6,6 0 0,0 7,12A6,6 0 0,0 13,18A6,6 0 0,0 19,12A6,6 0 0,0 13,6M12,7.5H13.5V12.03L16.72,13.5L16.1,14.86L12,13V7.5M1,14C1,11.5 2.13,9.3 3.91,7.83C3.33,9.1 3,10.5 3,12L3.06,13.13L3,14C3,16.28 4.27,18.26 6.14,19.28C7.44,20.5 9.07,21.39 10.89,21.78C10.28,21.92 9.65,22 9,22A8,8 0 0,1 1,14Z",dw="M12,11A1,1 0 0,0 11,12A1,1 0 0,0 12,13A1,1 0 0,0 13,12A1,1 0 0,0 12,11M12,16.5C9.5,16.5 7.5,14.5 7.5,12C7.5,9.5 9.5,7.5 12,7.5C14.5,7.5 16.5,9.5 16.5,12C16.5,14.5 14.5,16.5 12,16.5M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z",mw="M13 14H11V9H13M13 18H11V16H13M1 21H23L12 2L1 21Z",U_="M13,13H11V7H13M13,17H11V15H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z",W_="M8.27,3L3,8.27V15.73L8.27,21H15.73C17.5,19.24 21,15.73 21,15.73V8.27L15.73,3M9.1,5H14.9L19,9.1V14.9L14.9,19H9.1L5,14.9V9.1M11,15H13V17H11V15M11,7H13V13H11V7",Jn="M12,2L1,21H23M12,6L19.53,19H4.47M11,10V14H13V10M11,16V18H13V16",cu="M19.92,12.08L12,20L4.08,12.08L5.5,10.67L11,16.17V2H13V16.17L18.5,10.66L19.92,12.08M12,20H2V22H22V20H12Z",hw="M4,12H20V14H4V12M4,9H20V11H4V9M16,4L12,8L8,4H11V1H13V4H16M8,19L12,15L16,19H13V22H11V19H8Z",pw="M9,4H15V12H19.84L12,19.84L4.16,12H9V4Z",z_="M2,20V22H22V20H13V5.83L18.5,11.33L19.92,9.92L12,2L4.08,9.92L5.5,11.33L11,5.83V20H2Z",fw="M13,9V15H16L12,19L8,15H11V9H8L12,5L16,9H13M4,2H20V4H4V2M4,20H20V22H4V20Z",gw="M15,20H9V12H4.16L12,4.16L19.84,12H15V20Z",_w="M21,19V20H3V19L5,17V11C5,7.9 7.03,5.17 10,4.29C10,4.19 10,4.1 10,4A2,2 0 0,1 12,2A2,2 0 0,1 14,4C14,4.1 14,4.19 14,4.29C16.97,5.17 19,7.9 19,11V17L21,19M14,21A2,2 0 0,1 12,23A2,2 0 0,1 10,21",vw="M22.11,21.46L2.39,1.73L1.11,3L5.83,7.72C5.29,8.73 5,9.86 5,11V17L3,19V20H18.11L20.84,22.73L22.11,21.46M7,18V11C7,10.39 7.11,9.79 7.34,9.23L16.11,18H7M10,21H14A2,2 0 0,1 12,23A2,2 0 0,1 10,21M8.29,5.09C8.82,4.75 9.4,4.5 10,4.29C10,4.19 10,4.1 10,4A2,2 0 0,1 12,2A2,2 0 0,1 14,4C14,4.1 14,4.19 14,4.29C16.97,5.17 19,7.9 19,11V15.8L17,13.8V11A5,5 0 0,0 12,6C11.22,6 10.45,6.2 9.76,6.56L8.29,5.09Z",bw="M10 21H14C14 22.1 13.1 23 12 23S10 22.1 10 21M21 19V20H3V19L5 17V11C5 7.9 7 5.2 10 4.3V4C10 2.9 10.9 2 12 2S14 2.9 14 4V4.3C17 5.2 19 7.9 19 11V17L21 19M17 11C17 8.2 14.8 6 12 6S7 8.2 7 11V18H17V11Z",G_="M19.36,2.72L20.78,4.14L15.06,9.85C16.13,11.39 16.28,13.24 15.38,14.44L9.06,8.12C10.26,7.22 12.11,7.37 13.65,8.44L19.36,2.72M5.93,17.57C3.92,15.56 2.69,13.16 2.35,10.92L7.23,8.83L14.67,16.27L12.58,21.15C10.34,20.81 7.94,19.58 5.93,17.57Z",uu="M19,19H5V8H19M16,1V3H8V1H6V3H5C3.89,3 3,3.89 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3H18V1M17,12H12V17H17V12Z",$te="M20,5H17L15,3H9L7,5H4A2,2 0 0,0 2,7V19A2,2 0 0,0 4,21H20A2,2 0 0,0 22,19V7A2,2 0 0,0 20,5M12,18C10.92,18 9.86,17.65 9,17L10.44,15.56C10.91,15.85 11.45,16 12,16A3,3 0 0,0 15,13A3,3 0 0,0 12,10C10.74,10 9.6,10.8 9.18,12H11L8,15L5,12H7.1C7.65,9.29 10.29,7.55 13,8.1C15.7,8.65 17.45,11.29 16.9,14C16.42,16.33 14.38,18 12,18Z",yw="M15.9,18.5L21.9,20.1L21.5,22L12.1,19.5L2.7,22L2.2,20.1L8.2,18.5L2.1,16.9L2.6,15L12,17.5L21.4,15L21.9,16.9L15.9,18.5M16.07,7.92C15.91,7.7 15.71,7.5 15.5,7.33C15.05,6.9 14.5,6.59 14.06,6.13C13,5.08 12.79,3.34 13.44,2C12.79,2.17 12.18,2.54 11.67,2.95C9.84,4.46 9.11,7.1 10,9.38C10,9.45 10.04,9.53 10.04,9.62C10.04,9.78 9.93,9.92 9.79,10C9.63,10.05 9.46,10 9.33,9.9C9.28,9.86 9.25,9.82 9.22,9.77C8.42,8.74 8.29,7.26 8.84,6.07C7.65,7.06 7,8.72 7.11,10.29C7.13,10.65 7.18,11 7.3,11.36C7.41,11.8 7.59,12.23 7.82,12.61C8.57,13.86 9.9,14.76 11.32,14.94C12.84,15.14 14.46,14.85 15.63,13.79C16.93,12.59 17.4,10.67 16.71,9L16.61,8.83C16.47,8.5 16.28,8.2 16.04,7.93L16.07,7.92M13.83,12.47C13.63,12.65 13.31,12.83 13.05,12.91C12.26,13.19 11.46,12.79 11,12.31C11.84,12.11 12.34,11.47 12.5,10.83C12.61,10.25 12.39,9.78 12.29,9.22C12.21,8.69 12.22,8.23 12.42,7.73C12.55,8 12.69,8.28 12.86,8.5C13.41,9.22 14.27,9.54 14.45,10.5C14.47,10.63 14.5,10.72 14.5,10.83C14.5,11.43 14.26,12.07 13.82,12.47",Z_="M12 2C17.5 2 22 6.5 22 12S17.5 22 12 22 2 17.5 2 12 6.5 2 12 2M12 4C10.1 4 8.4 4.6 7.1 5.7L18.3 16.9C19.3 15.5 20 13.8 20 12C20 7.6 16.4 4 12 4M16.9 18.3L5.7 7.1C4.6 8.4 4 10.1 4 12C4 16.4 7.6 20 12 20C13.9 20 15.6 19.4 16.9 18.3Z",Cw="M17,19H7V5H17M17,1H7C5.89,1 5,1.89 5,3V21A2,2 0 0,0 7,23H17A2,2 0 0,0 19,21V3C19,1.89 18.1,1 17,1Z",$w="M17.45,15.18L22,7.31V19L22,21H2V3H4V15.54L9.5,6L16,9.78L20.24,2.45L21.97,3.45L16.74,12.5L10.23,8.75L4.31,19H6.57L10.96,11.44L17.45,15.18Z",q_="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z",Ep="M19,3H5C3.89,3 3,3.89 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3M19,5V19H5V5H19Z",Lp="M10,17L5,12L6.41,10.58L10,14.17L17.59,6.58L19,8M19,3H5C3.89,3 3,3.89 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3Z",X_="M10,17L5,12L6.41,10.58L10,14.17L17.59,6.58L19,8M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z",xw="M20,12A8,8 0 0,1 12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4C12.76,4 13.5,4.11 14.2,4.31L15.77,2.74C14.61,2.26 13.34,2 12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z",ww="M5.59,7.41L7,6L13,12L7,18L5.59,16.59L10.17,12L5.59,7.41M11.59,7.41L13,6L19,12L13,18L11.59,16.59L16.17,12L11.59,7.41Z",fr="M7.41,8.58L12,13.17L16.59,8.58L18,10L12,16L6,10L7.41,8.58Z",Sw="M15.41,16.58L10.83,12L15.41,7.41L14,6L8,12L14,18L15.41,16.58Z",Pw="M8.59,16.58L13.17,12L8.59,7.41L10,6L16,12L10,18L8.59,16.58Z",Dw="M9.42,7.41L4.83,12L9.42,16.59L8,18L2,12L8,6L9.42,7.41M15.42,7.41L10.83,12L15.42,16.59L14,18L8,12L14,6L15.42,7.41M21.42,7.41L16.83,12L21.42,16.59L20,18L14,12L20,6L21.42,7.41Z",Tw="M14.58,16.59L19.17,12L14.58,7.41L16,6L22,12L16,18L14.58,16.59M8.58,16.59L13.17,12L8.58,7.41L10,6L16,12L10,18L8.58,16.59M2.58,16.59L7.17,12L2.58,7.41L4,6L10,12L4,18L2.58,16.59Z",du="M7.41,15.41L12,10.83L16.59,15.41L18,14L12,8L6,14L7.41,15.41Z",Ow="M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M16.2,16.2L11,13V7H12.5V12.2L17,14.9L16.2,16.2Z",Ba="M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z",Mw="M20 2H8C6.9 2 6 2.9 6 4V16C6 17.11 6.9 18 8 18H20C21.11 18 22 17.11 22 16V4C22 2.9 21.11 2 20 2M20 16H8V4H20V16M4 6V20H18V22H4C2.9 22 2 21.11 2 20V6H4M9.77 12.84L12.6 10L9.77 7.15L11.17 5.75L14 8.6L16.84 5.77L18.24 7.17L15.4 10L18.23 12.84L16.83 14.24L14 11.4L11.17 14.24L9.77 12.84Z",ol="M12,2C17.53,2 22,6.47 22,12C22,17.53 17.53,22 12,22C6.47,22 2,17.53 2,12C2,6.47 6.47,2 12,2M15.59,7L12,10.59L8.41,7L7,8.41L10.59,12L7,15.59L8.41,17L12,13.41L15.59,17L17,15.59L13.41,12L17,8.41L15.59,7Z",kw="M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,2C6.47,2 2,6.47 2,12C2,17.53 6.47,22 12,22C17.53,22 22,17.53 22,12C22,6.47 17.53,2 12,2M14.59,8L12,10.59L9.41,8L8,9.41L10.59,12L8,14.59L9.41,16L12,13.41L14.59,16L16,14.59L13.41,12L16,9.41L14.59,8Z",pe="M20 6.91L17.09 4L12 9.09L6.91 4L4 6.91L9.09 12L4 17.09L6.91 20L12 14.91L17.09 20L20 17.09L14.91 12L20 6.91Z",Kn="M6.5 20Q4.22 20 2.61 18.43 1 16.85 1 14.58 1 12.63 2.17 11.1 3.35 9.57 5.25 9.15 5.83 7.13 7.39 5.75 8.95 4.38 11 4.08V12.15L9.4 10.6L8 12L12 16L16 12L14.6 10.6L13 12.15V4.08Q15.58 4.43 17.29 6.39 19 8.35 19 11 20.73 11.2 21.86 12.5 23 13.78 23 15.5 23 17.38 21.69 18.69 20.38 20 18.5 20Z",Qn="M14.6,16.6L19.2,12L14.6,7.4L16,6L22,12L16,18L14.6,16.6M9.4,16.6L4.8,12L9.4,7.4L8,6L2,12L8,18L9.4,16.6Z",ss="M12,15.5A3.5,3.5 0 0,1 8.5,12A3.5,3.5 0 0,1 12,8.5A3.5,3.5 0 0,1 15.5,12A3.5,3.5 0 0,1 12,15.5M19.43,12.97C19.47,12.65 19.5,12.33 19.5,12C19.5,11.67 19.47,11.34 19.43,11L21.54,9.37C21.73,9.22 21.78,8.95 21.66,8.73L19.66,5.27C19.54,5.05 19.27,4.96 19.05,5.05L16.56,6.05C16.04,5.66 15.5,5.32 14.87,5.07L14.5,2.42C14.46,2.18 14.25,2 14,2H10C9.75,2 9.54,2.18 9.5,2.42L9.13,5.07C8.5,5.32 7.96,5.66 7.44,6.05L4.95,5.05C4.73,4.96 4.46,5.05 4.34,5.27L2.34,8.73C2.21,8.95 2.27,9.22 2.46,9.37L4.57,11C4.53,11.34 4.5,11.67 4.5,12C4.5,12.33 4.53,12.65 4.57,12.97L2.46,14.63C2.27,14.78 2.21,15.05 2.34,15.27L4.34,18.73C4.46,18.95 4.73,19.03 4.95,18.95L7.44,17.94C7.96,18.34 8.5,18.68 9.13,18.93L9.5,21.58C9.54,21.82 9.75,22 10,22H14C14.25,22 14.46,21.82 14.5,21.58L14.87,18.93C15.5,18.67 16.04,18.34 16.56,17.94L19.05,18.95C19.27,19.03 19.54,18.95 19.66,18.73L21.66,15.27C21.78,15.05 21.73,14.78 21.54,14.63L19.43,12.97Z",Ew="M22.12 21.46L2.4 1.73L1.12 3L4 5.87L2.34 8.73C2.21 8.95 2.27 9.22 2.46 9.37L4.57 11C4.53 11.34 4.5 11.67 4.5 12S4.53 12.65 4.57 12.97L2.46 14.63C2.27 14.78 2.21 15.05 2.34 15.27L4.34 18.73C4.46 18.95 4.73 19.03 4.95 18.95L7.44 17.94C7.96 18.34 8.5 18.68 9.13 18.93L9.5 21.58C9.54 21.82 9.75 22 10 22H14C14.25 22 14.46 21.82 14.5 21.58L14.87 18.93C15.38 18.72 15.83 18.45 16.26 18.14L20.85 22.73L22.12 21.46M12 15.5C10.07 15.5 8.5 13.93 8.5 12C8.5 11.5 8.62 11.08 8.79 10.67L13.33 15.21C12.92 15.39 12.5 15.5 12 15.5M11.74 8.53L8.56 5.35C8.75 5.25 8.93 5.15 9.13 5.07L9.5 2.42C9.54 2.18 9.75 2 10 2H14C14.25 2 14.46 2.18 14.5 2.42L14.87 5.07C15.5 5.32 16.04 5.66 16.56 6.05L19.05 5.05C19.27 4.96 19.54 5.05 19.66 5.27L21.66 8.73C21.78 8.95 21.73 9.22 21.54 9.37L19.43 11C19.47 11.34 19.5 11.67 19.5 12S19.47 12.65 19.43 12.97L21.54 14.63C21.73 14.78 21.78 15.05 21.66 15.27L20.5 17.29L15.47 12.26C15.5 12.18 15.5 12.09 15.5 12C15.5 10.07 13.93 8.5 12 8.5C11.91 8.5 11.83 8.5 11.74 8.53Z",Lw="M15.9,18.45C17.25,18.45 18.35,17.35 18.35,16C18.35,14.65 17.25,13.55 15.9,13.55C14.54,13.55 13.45,14.65 13.45,16C13.45,17.35 14.54,18.45 15.9,18.45M21.1,16.68L22.58,17.84C22.71,17.95 22.75,18.13 22.66,18.29L21.26,20.71C21.17,20.86 21,20.92 20.83,20.86L19.09,20.16C18.73,20.44 18.33,20.67 17.91,20.85L17.64,22.7C17.62,22.87 17.47,23 17.3,23H14.5C14.32,23 14.18,22.87 14.15,22.7L13.89,20.85C13.46,20.67 13.07,20.44 12.71,20.16L10.96,20.86C10.81,20.92 10.62,20.86 10.54,20.71L9.14,18.29C9.05,18.13 9.09,17.95 9.22,17.84L10.7,16.68L10.65,16L10.7,15.31L9.22,14.16C9.09,14.05 9.05,13.86 9.14,13.71L10.54,11.29C10.62,11.13 10.81,11.07 10.96,11.13L12.71,11.84C13.07,11.56 13.46,11.32 13.89,11.15L14.15,9.29C14.18,9.13 14.32,9 14.5,9H17.3C17.47,9 17.62,9.13 17.64,9.29L17.91,11.15C18.33,11.32 18.73,11.56 19.09,11.84L20.83,11.13C21,11.07 21.17,11.13 21.26,11.29L22.66,13.71C22.75,13.86 22.71,14.05 22.58,14.16L21.1,15.31L21.15,16L21.1,16.68M6.69,8.07C7.56,8.07 8.26,7.37 8.26,6.5C8.26,5.63 7.56,4.92 6.69,4.92A1.58,1.58 0 0,0 5.11,6.5C5.11,7.37 5.82,8.07 6.69,8.07M10.03,6.94L11,7.68C11.07,7.75 11.09,7.87 11.03,7.97L10.13,9.53C10.08,9.63 9.96,9.67 9.86,9.63L8.74,9.18L8,9.62L7.81,10.81C7.79,10.92 7.7,11 7.59,11H5.79C5.67,11 5.58,10.92 5.56,10.81L5.4,9.62L4.64,9.18L3.5,9.63C3.41,9.67 3.3,9.63 3.24,9.53L2.34,7.97C2.28,7.87 2.31,7.75 2.39,7.68L3.34,6.94L3.31,6.5L3.34,6.06L2.39,5.32C2.31,5.25 2.28,5.13 2.34,5.03L3.24,3.47C3.3,3.37 3.41,3.33 3.5,3.37L4.63,3.82L5.4,3.38L5.56,2.19C5.58,2.08 5.67,2 5.79,2H7.59C7.7,2 7.79,2.08 7.81,2.19L8,3.38L8.74,3.82L9.86,3.37C9.96,3.33 10.08,3.37 10.13,3.47L11.03,5.03C11.09,5.13 11.07,5.25 11,5.32L10.03,6.06L10.06,6.5L10.03,6.94Z",Ap="M21.4 7.5C22.2 8.3 22.2 9.6 21.4 10.3L18.6 13.1L10.8 5.3L13.6 2.5C14.4 1.7 15.7 1.7 16.4 2.5L18.2 4.3L21.2 1.3L22.6 2.7L19.6 5.7L21.4 7.5M15.6 13.3L14.2 11.9L11.4 14.7L9.3 12.6L12.1 9.8L10.7 8.4L7.9 11.2L6.4 9.8L3.6 12.6C2.8 13.4 2.8 14.7 3.6 15.4L5.4 17.2L1.4 21.2L2.8 22.6L6.8 18.6L8.6 20.4C9.4 21.2 10.7 21.2 11.4 20.4L14.2 17.6L12.8 16.2L15.6 13.3Z",Ua="M13,19V16H21V19H13M8.5,13L2.47,7H6.71L11.67,11.95C12.25,12.54 12.25,13.5 11.67,14.07L6.74,19H2.5L8.5,13Z",Fp="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z",Rp="M15,9H5V5H15M12,19A3,3 0 0,1 9,16A3,3 0 0,1 12,13A3,3 0 0,1 15,16A3,3 0 0,1 12,19M17,3H5C3.89,3 3,3.9 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V7L17,3Z",Y_="M4,4H20A2,2 0 0,1 22,6V18A2,2 0 0,1 20,20H4A2,2 0 0,1 2,18V6A2,2 0 0,1 4,4M4,6V18H11V6H4M20,18V6H18.76C19,6.54 18.95,7.07 18.95,7.13C18.88,7.8 18.41,8.5 18.24,8.75L15.91,11.3L19.23,11.28L19.24,12.5L14.04,12.47L14,11.47C14,11.47 17.05,8.24 17.2,7.95C17.34,7.67 17.91,6 16.5,6C15.27,6.05 15.41,7.3 15.41,7.3L13.87,7.31C13.87,7.31 13.88,6.65 14.25,6H13V18H15.58L15.57,17.14L16.54,17.13C16.54,17.13 17.45,16.97 17.46,16.08C17.5,15.08 16.65,15.08 16.5,15.08C16.37,15.08 15.43,15.13 15.43,15.95H13.91C13.91,15.95 13.95,13.89 16.5,13.89C19.1,13.89 18.96,15.91 18.96,15.91C18.96,15.91 19,17.16 17.85,17.63L18.37,18H20M8.92,16H7.42V10.2L5.62,10.76V9.53L8.76,8.41H8.92V16Z",Aw="M12,8A4,4 0 0,1 16,12A4,4 0 0,1 12,16A4,4 0 0,1 8,12A4,4 0 0,1 12,8M3.05,13H1V11H3.05C3.5,6.83 6.83,3.5 11,3.05V1H13V3.05C17.17,3.5 20.5,6.83 20.95,11H23V13H20.95C20.5,17.17 17.17,20.5 13,20.95V23H11V20.95C6.83,20.5 3.5,17.17 3.05,13M12,5A7,7 0 0,0 5,12A7,7 0 0,0 12,19A7,7 0 0,0 19,12A7,7 0 0,0 12,5Z",Fw="M12,3C7.58,3 4,4.79 4,7C4,9.21 7.58,11 12,11C16.42,11 20,9.21 20,7C20,4.79 16.42,3 12,3M4,9V12C4,14.21 7.58,16 12,16C16.42,16 20,14.21 20,12V9C20,11.21 16.42,13 12,13C7.58,13 4,11.21 4,9M4,14V17C4,19.21 7.58,21 12,21C16.42,21 20,19.21 20,17V14C20,16.21 16.42,18 12,18C7.58,18 4,16.21 4,14Z",J_="M20 13.09V7C20 4.79 16.42 3 12 3S4 4.79 4 7V17C4 19.21 7.59 21 12 21C12.46 21 12.9 21 13.33 20.94C13.12 20.33 13 19.68 13 19L13 18.95C12.68 19 12.35 19 12 19C8.13 19 6 17.5 6 17V14.77C7.61 15.55 9.72 16 12 16C12.65 16 13.27 15.96 13.88 15.89C14.93 14.16 16.83 13 19 13C19.34 13 19.67 13.04 20 13.09M18 12.45C16.7 13.4 14.42 14 12 14S7.3 13.4 6 12.45V9.64C7.47 10.47 9.61 11 12 11S16.53 10.47 18 9.64V12.45M12 9C8.13 9 6 7.5 6 7S8.13 5 12 5 18 6.5 18 7 15.87 9 12 9M22 20L19 23L16 20H18V16H20V20H22Z",Rw="M17.86 18L18.9 19C17.5 20.2 14.94 21 12 21C7.59 21 4 19.21 4 17V7C4 4.79 7.58 3 12 3C14.95 3 17.5 3.8 18.9 5L17.86 6L17.5 6.4C16.65 5.77 14.78 5 12 5C8.13 5 6 6.5 6 7S8.13 9 12 9C13.37 9 14.5 8.81 15.42 8.54L16.38 9.5H13.5V10.92C13 10.97 12.5 11 12 11C9.61 11 7.47 10.47 6 9.64V12.45C7.3 13.4 9.58 14 12 14C12.5 14 13 13.97 13.5 13.92V14.5H16.38L15.38 15.5L15.5 15.61C14.41 15.86 13.24 16 12 16C9.72 16 7.61 15.55 6 14.77V17C6 17.5 8.13 19 12 19C14.78 19 16.65 18.23 17.5 17.61L17.86 18M18.92 7.08L17.5 8.5L20 11H15V13H20L17.5 15.5L18.92 16.92L23.84 12L18.92 7.08Z",Ue="M19,4H15.5L14.5,3H9.5L8.5,4H5V6H19M6,19A2,2 0 0,0 8,21H16A2,2 0 0,0 18,19V7H6V19Z",Hw="M4.15,21.46L5.47,19.58C3.35,17.74 2,15.03 2,12A10,10 0 0,1 12,2C13.78,2 15.44,2.46 16.89,3.27L18.21,1.39L19.85,2.54L18.53,4.42C20.65,6.26 22,8.97 22,12A10,10 0 0,1 12,22C10.22,22 8.56,21.54 7.11,20.73L5.79,22.61L4.15,21.46M12,4A8,8 0 0,0 4,12C4,14.35 5,16.46 6.63,17.93L15.73,4.92C14.62,4.33 13.35,4 12,4M12,20A8,8 0 0,0 20,12C20,9.65 19,7.54 17.37,6.07L8.27,19.08C9.38,19.67 10.65,20 12,20Z",Hp="M3,4H7A1,1 0 0,1 8,5V19A1,1 0 0,1 7,20H3A1,1 0 0,1 2,19V5A1,1 0 0,1 3,4M10,4H14A1,1 0 0,1 15,5V19A1,1 0 0,1 14,20H10A1,1 0 0,1 9,19V5A1,1 0 0,1 10,4M17,4H21A1,1 0 0,1 22,5V19A1,1 0 0,1 21,20H17A1,1 0 0,1 16,19V5A1,1 0 0,1 17,4M4,18H6V13H4V18M11,11H13V6H11V11M18,18H20V13H18V18Z",jw="M8,3C6.89,3 6,3.89 6,5V21H18V5C18,3.89 17.11,3 16,3H8M8,5H16V19H8V5M13,11V13H15V11H13Z",Iw="M16,12A2,2 0 0,1 18,10A2,2 0 0,1 20,12A2,2 0 0,1 18,14A2,2 0 0,1 16,12M10,12A2,2 0 0,1 12,10A2,2 0 0,1 14,12A2,2 0 0,1 12,14A2,2 0 0,1 10,12M4,12A2,2 0 0,1 6,10A2,2 0 0,1 8,12A2,2 0 0,1 6,14A2,2 0 0,1 4,12Z",mu="M12,16A2,2 0 0,1 14,18A2,2 0 0,1 12,20A2,2 0 0,1 10,18A2,2 0 0,1 12,16M12,10A2,2 0 0,1 14,12A2,2 0 0,1 12,14A2,2 0 0,1 10,12A2,2 0 0,1 12,10M12,4A2,2 0 0,1 14,6A2,2 0 0,1 12,8A2,2 0 0,1 10,6A2,2 0 0,1 12,4Z",K_="M5,20H19V18H5M19,9H15V3H9V9H5L12,16L19,9Z",Wa="M9,3H11V5H9V3M13,3H15V5H13V3M9,7H11V9H9V7M13,7H15V9H13V7M9,11H11V13H9V11M13,11H15V13H13V11M9,15H11V17H9V15M13,15H15V17H13V15M9,19H11V21H9V19M13,19H15V21H13V19Z",Q_="M12,5L5.33,15H18.67M5,17H19V19H5V17Z",ev="M7,4V6H10V8H7L5,10V13H3V10H1V18H3V15H5V18H8L10,20H18V16H20V19H23V9H20V12H18V8H12V6H15V4H7Z",jp="M3.78,2.5L21.5,20.22L20.23,21.5L18,19.27V20H10L8,18H5V15H3V18H1V10H3V13H5V10L6.87,8.14L2.5,3.77L3.78,2.5M20,9V12H18V8H12V6H15V4H7.82L22.82,19H23V9H20Z",Nw="M12,9A3,3 0 0,0 9,12A3,3 0 0,0 12,15A3,3 0 0,0 15,12A3,3 0 0,0 12,9M12,17A5,5 0 0,1 7,12A5,5 0 0,1 12,7A5,5 0 0,1 17,12A5,5 0 0,1 12,17M12,4.5C7,4.5 2.73,7.61 1,12C2.73,16.39 7,19.5 12,19.5C17,19.5 21.27,16.39 23,12C21.27,7.61 17,4.5 12,4.5Z",Ip="M12,11A1,1 0 0,0 11,12A1,1 0 0,0 12,13A1,1 0 0,0 13,12A1,1 0 0,0 12,11M12.5,2C17,2 17.11,5.57 14.75,6.75C13.76,7.24 13.32,8.29 13.13,9.22C13.61,9.42 14.03,9.73 14.35,10.13C18.05,8.13 22.03,8.92 22.03,12.5C22.03,17 18.46,17.1 17.28,14.73C16.78,13.74 15.72,13.3 14.79,13.11C14.59,13.59 14.28,14 13.88,14.34C15.87,18.03 15.08,22 11.5,22C7,22 6.91,18.42 9.27,17.24C10.25,16.75 10.69,15.71 10.89,14.79C10.4,14.59 9.97,14.27 9.65,13.87C5.96,15.85 2,15.07 2,11.5C2,7 5.56,6.89 6.74,9.26C7.24,10.25 8.29,10.68 9.22,10.87C9.41,10.39 9.73,9.97 10.14,9.65C8.15,5.96 8.94,2 12.5,2Z",xte="M13,6V18L21.5,12M4,18L12.5,12L4,6V18Z",Bs="M13,9V3.5L18.5,9M6,2C4.89,2 4,2.89 4,4V20A2,2 0 0,0 6,22H18A2,2 0 0,0 20,20V8L14,2H6Z",Vw="M13,9H18.5L13,3.5V9M6,2H14L20,8V20A2,2 0 0,1 18,22H6C4.89,22 4,21.1 4,20V4C4,2.89 4.89,2 6,2M10.5,11C8,11 6,13 6,15.5C6,18 8,20 10.5,20C13,20 15,18 15,15.5C15,13 13,11 10.5,11M10.5,12.5A3,3 0 0,1 13.5,15.5C13.5,16.06 13.35,16.58 13.08,17L9,12.92C9.42,12.65 9.94,12.5 10.5,12.5M7.5,15.5C7.5,14.94 7.65,14.42 7.92,14L12,18.08C11.58,18.35 11.06,18.5 10.5,18.5A3,3 0 0,1 7.5,15.5Z",Bw="M6,2C4.89,2 4,2.89 4,4V20A2,2 0 0,0 6,22H10V20.09L12.09,18H6V16H14.09L16.09,14H6V12H18.09L20,10.09V8L14,2H6M13,3.5L18.5,9H13V3.5M20.15,13C20,13 19.86,13.05 19.75,13.16L18.73,14.18L20.82,16.26L21.84,15.25C22.05,15.03 22.05,14.67 21.84,14.46L20.54,13.16C20.43,13.05 20.29,13 20.15,13M18.14,14.77L12,20.92V23H14.08L20.23,16.85L18.14,14.77Z",za="M8,12H16V14H8V12M10,20H6V4H13V9H18V12.1L20,10.1V8L14,2H6A2,2 0 0,0 4,4V20A2,2 0 0,0 6,22H10V20M8,18H12.1L13,17.1V16H8V18M20.2,13C20.3,13 20.5,13.1 20.6,13.2L21.9,14.5C22.1,14.7 22.1,15.1 21.9,15.3L20.9,16.3L18.8,14.2L19.8,13.2C19.9,13.1 20,13 20.2,13M20.2,16.9L14.1,23H12V20.9L18.1,14.8L20.2,16.9Z",Ga="M16 0H8C6.9 0 6 .9 6 2V18C6 19.1 6.9 20 8 20H20C21.1 20 22 19.1 22 18V6L16 0M20 18H8V2H15V7H20V18M4 4V22H20V24H4C2.9 24 2 23.1 2 22V4H4M10 10V12H18V10H10M10 14V16H15V14H10Z",Uw="M6,2A2,2 0 0,0 4,4V20A2,2 0 0,0 6,22H18A2,2 0 0,0 20,20V8L14,2H6M6,4H13V9H18V20H6V4M8,12V14H16V12H8M8,16V18H13V16H8Z",Ww="M15,7H20.5L15,1.5V7M8,0H16L22,6V18A2,2 0 0,1 20,20H8C6.89,20 6,19.1 6,18V2A2,2 0 0,1 8,0M4,4V22H20V24H4A2,2 0 0,1 2,22V4H4Z",tv="M14,2H6A2,2 0 0,0 4,4V20A2,2 0 0,0 6,22H18A2,2 0 0,0 20,20V8L14,2M18,20H6V4H13V9H18V20Z",zw="M14 2H6C4.89 2 4 2.89 4 4V20C4 21.11 4.89 22 6 22H13.81C13.28 21.09 13 20.05 13 19C13 15.69 15.69 13 19 13C19.34 13 19.67 13.03 20 13.08V8L14 2M13 9V3.5L18.5 9H13M23 20H20V23H18V20H15V18H18V15H20V18H23V20Z",sv="M12.8 22H6C4.9 22 4 21.1 4 20V4C4 2.9 4.9 2 6 2H14L20 8V11.5C19.4 11.2 18.7 11.1 18 11V9H13V4H6V20H11.5C11.8 20.7 12.3 21.4 12.8 22M17 12L14.8 14.2L17 16.4V15C18.4 15 19.5 16.1 19.5 17.5C19.5 17.9 19.4 18.3 19.2 18.6L20.3 19.7C20.7 19.1 21 18.3 21 17.5C21 15.3 19.2 13.5 17 13.5V12M19.2 20.8L17 18.5V20C15.6 20 14.5 18.9 14.5 17.5C14.5 17.1 14.6 16.7 14.8 16.4L13.7 15.3C13.3 15.9 13 16.7 13 17.5C13 19.7 14.8 21.5 17 21.5V23L19.2 20.8Z",rv="M14,2H6A2,2 0 0,0 4,4V20A2,2 0 0,0 6,22H18A2,2 0 0,0 20,20V8L14,2M13.5,16V19H10.5V16H8L12,12L16,16H13.5M13,9V3.5L18.5,9H13Z",Gw="M13,9H18.5L13,3.5V9M6,2H14L20,8V20A2,2 0 0,1 18,22H6C4.89,22 4,21.1 4,20V4C4,2.89 4.89,2 6,2M17,19V13L14,15.2V13H7V19H14V16.8L17,19Z",Zw="M14,12V19.88C14.04,20.18 13.94,20.5 13.71,20.71C13.32,21.1 12.69,21.1 12.3,20.71L10.29,18.7C10.06,18.47 9.96,18.16 10,17.87V12H9.97L4.21,4.62C3.87,4.19 3.95,3.56 4.38,3.22C4.57,3.08 4.78,3 5,3V3H19V3C19.22,3 19.43,3.08 19.62,3.22C20.05,3.56 20.13,4.19 19.79,4.62L14.03,12H14Z",qw="M2.39 1.73L1.11 3L9.5 11.37L9.97 12H10V17.87C9.96 18.16 10.06 18.47 10.29 18.7L12.3 20.71C12.69 21.1 13.32 21.1 13.71 20.71C13.94 20.5 14.04 20.18 14 19.88V15.89L20.84 22.73L22.11 21.46L14 13.35L9.41 8.76L4.15 3.5L2.39 1.73M6.21 3L14.54 11.34L19.79 4.62C20.13 4.19 20.05 3.56 19.62 3.22C19.43 3.08 19.22 3 19 3H6.21Z",sn="M17.66 11.2C17.43 10.9 17.15 10.64 16.89 10.38C16.22 9.78 15.46 9.35 14.82 8.72C13.33 7.26 13 4.85 13.95 3C13 3.23 12.17 3.75 11.46 4.32C8.87 6.4 7.85 10.07 9.07 13.22C9.11 13.32 9.15 13.42 9.15 13.55C9.15 13.77 9 13.97 8.8 14.05C8.57 14.15 8.33 14.09 8.14 13.93C8.08 13.88 8.04 13.83 8 13.76C6.87 12.33 6.69 10.28 7.45 8.64C5.78 10 4.87 12.3 5 14.47C5.06 14.97 5.12 15.47 5.29 15.97C5.43 16.57 5.7 17.17 6 17.7C7.08 19.43 8.95 20.67 10.96 20.92C13.1 21.19 15.39 20.8 17.03 19.32C18.86 17.66 19.5 15 18.56 12.72L18.43 12.46C18.22 12 17.66 11.2 17.66 11.2M14.5 17.5C14.22 17.74 13.76 18 13.4 18.1C12.28 18.5 11.16 17.94 10.5 17.28C11.69 17 12.4 16.12 12.61 15.23C12.78 14.43 12.46 13.77 12.33 13C12.21 12.26 12.23 11.63 12.5 10.94C12.69 11.32 12.89 11.7 13.13 12C13.9 13 15.11 13.44 15.37 14.8C15.41 14.94 15.43 15.08 15.43 15.23C15.46 16.05 15.1 16.95 14.5 17.5H14.5Z",Vg="M7,2V13H10V22L17,10H13L17,2H7Z",Np="M10,4H4C2.89,4 2,4.89 2,6V18A2,2 0 0,0 4,20H20A2,2 0 0,0 22,18V8C22,6.89 21.1,6 20,6H12L10,4Z",Vp="M13 19C13 19.34 13.04 19.67 13.09 20H4C2.9 20 2 19.11 2 18V6C2 4.89 2.89 4 4 4H10L12 6H20C21.1 6 22 6.89 22 8V13.81C21.12 13.3 20.1 13 19 13C15.69 13 13 15.69 13 19M20 18V15H18V18H15V20H18V23H20V20H23V18H20Z",Bp="M20,6A2,2 0 0,1 22,8V18A2,2 0 0,1 20,20H4A2,2 0 0,1 2,18V6A2,2 0 0,1 4,4H10L12,6H20M10.75,13H14V17H16V13H19.25L15,8.75",Xw="M20 6H12L10 4H4C2.9 4 2 4.9 2 6V18C2 19.1 2.9 20 4 20H20C21.1 20 22 19.1 22 18V8C22 6.9 21.1 6 20 6M20 18H16V16H14V18H4V8H14V10H16V8H20V18M16 12V10H18V12H16M14 12H16V14H14V12M18 16H16V14H18V16Z",Yw="M21,19V17H8V19H21M21,13V11H8V13H21M8,7H21V5H8V7M4,5V7H6V5H4M3,5A1,1 0 0,1 4,4H6A1,1 0 0,1 7,5V7A1,1 0 0,1 6,8H4A1,1 0 0,1 3,7V5M4,11V13H6V11H4M3,11A1,1 0 0,1 4,10H6A1,1 0 0,1 7,11V13A1,1 0 0,1 6,14H4A1,1 0 0,1 3,13V11M4,17V19H6V17H4M3,17A1,1 0 0,1 4,16H6A1,1 0 0,1 7,17V19A1,1 0 0,1 6,20H4A1,1 0 0,1 3,19V17Z",Up="M16.5,9L13.5,12L16.5,15H22V9M9,16.5V22H15V16.5L12,13.5M7.5,9H2V15H7.5L10.5,12M15,7.5V2H9V7.5L12,10.5L15,7.5Z",Jw="M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M12,4A8,8 0 0,1 20,12C20,14.4 19,16.5 17.3,18C15.9,16.7 14,16 12,16C10,16 8.2,16.7 6.7,18C5,16.5 4,14.4 4,12A8,8 0 0,1 12,4M14,5.89C13.62,5.9 13.26,6.15 13.1,6.54L11.81,9.77L11.71,10C11,10.13 10.41,10.6 10.14,11.26C9.73,12.29 10.23,13.45 11.26,13.86C12.29,14.27 13.45,13.77 13.86,12.74C14.12,12.08 14,11.32 13.57,10.76L13.67,10.5L14.96,7.29L14.97,7.26C15.17,6.75 14.92,6.17 14.41,5.96C14.28,5.91 14.15,5.89 14,5.89M10,6A1,1 0 0,0 9,7A1,1 0 0,0 10,8A1,1 0 0,0 11,7A1,1 0 0,0 10,6M7,9A1,1 0 0,0 6,10A1,1 0 0,0 7,11A1,1 0 0,0 8,10A1,1 0 0,0 7,9M17,9A1,1 0 0,0 16,10A1,1 0 0,0 17,11A1,1 0 0,0 18,10A1,1 0 0,0 17,9Z",hu="M10,4V8H14V4H10M16,4V8H20V4H16M16,10V14H20V10H16M16,16V20H20V16H16M14,20V16H10V20H14M8,20V16H4V20H8M8,14V10H4V14H8M8,8V4H4V8H8M10,14H14V10H10V14M4,2H20A2,2 0 0,1 22,4V20A2,2 0 0,1 20,22H4C2.92,22 2,21.1 2,20V4A2,2 0 0,1 4,2Z",Wp="M10,19H13V22H10V19M12,2C17.35,2.22 19.68,7.62 16.5,11.67C15.67,12.67 14.33,13.33 13.67,14.17C13,15 13,16 13,17H10C10,15.33 10,13.92 10.67,12.92C11.33,11.92 12.67,11.33 13.5,10.67C15.92,8.43 15.32,5.26 12,5A3,3 0 0,0 9,8H6A6,6 0 0,1 12,2Z",pu="M15.07,11.25L14.17,12.17C13.45,12.89 13,13.5 13,15H11V14.5C11,13.39 11.45,12.39 12.17,11.67L13.41,10.41C13.78,10.05 14,9.55 14,9C14,7.89 13.1,7 12,7A2,2 0 0,0 10,9H8A4,4 0 0,1 12,5A4,4 0 0,1 16,9C16,9.88 15.64,10.67 15.07,11.25M13,19H11V17H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12C22,6.47 17.5,2 12,2Z",iv="M11,18H13V16H11V18M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,6A4,4 0 0,0 8,10H10A2,2 0 0,1 12,8A2,2 0 0,1 14,10C14,12 11,11.75 11,15H13C13,12.75 16,12.5 16,10A4,4 0 0,0 12,6Z",nv="M13.5,8H12V13L16.28,15.54L17,14.33L13.5,12.25V8M13,3A9,9 0 0,0 4,12H1L4.96,16.03L9,12H6A7,7 0 0,1 13,5A7,7 0 0,1 20,12A7,7 0 0,1 13,19C11.07,19 9.32,18.21 8.06,16.94L6.64,18.36C8.27,20 10.5,21 13,21A9,9 0 0,0 22,12A9,9 0 0,0 13,3",av="M10,20V14H14V20H19V12H22L12,3L2,12H5V20H10Z",Ht="M13,9H11V7H13M13,17H11V11H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z",ov="M11,9H13V7H11M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M11,17H13V11H11V17Z",Kw="M12 22C17.5 22 22 17.5 22 12C22 6.5 17.5 2 12 2C6.5 2 2 6.5 2 12C2 17.5 6.5 22 12 22M12.3 7.29C12.5 7.11 12.74 7 13 7C13.27 7 13.5 7.11 13.71 7.29C13.9 7.5 14 7.74 14 8C14 8.27 13.9 8.5 13.71 8.71C13.5 8.9 13.27 9 13 9C12.74 9 12.5 8.9 12.3 8.71C12.11 8.5 12 8.27 12 8C12 7.74 12.11 7.5 12.3 7.29M9.8 11.97C9.8 11.97 11.97 10.25 12.76 10.18C13.5 10.12 13.35 10.97 13.28 11.41L13.27 11.47C13.13 12 12.96 12.64 12.79 13.25C12.41 14.64 12.04 16 12.13 16.25C12.23 16.59 12.85 16.16 13.3 15.86C13.36 15.82 13.41 15.78 13.46 15.75C13.46 15.75 13.54 15.67 13.62 15.78C13.64 15.81 13.66 15.84 13.68 15.86C13.77 16 13.82 16.05 13.7 16.13L13.66 16.15C13.44 16.3 12.5 16.96 12.12 17.2C11.71 17.47 10.14 18.37 10.38 16.62C10.59 15.39 10.87 14.33 11.09 13.5C11.5 12 11.68 11.32 10.76 11.91C10.39 12.13 10.17 12.27 10.04 12.36C9.93 12.44 9.92 12.44 9.85 12.31L9.82 12.25L9.77 12.17C9.7 12.07 9.7 12.06 9.8 11.97Z",Qw="M12,18.54L19.37,12.8L21,14.07L12,21.07L3,14.07L4.62,12.81L12,18.54M12,16L3,9L12,2L21,9L12,16M12,4.53L6.26,9L12,13.47L17.74,9L12,4.53Z",hm="M17,14H19V17H22V19H19V22H17V19H14V17H17V14M11,16L2,9L11,2L20,9L11,16M11,18.54L12,17.75V18C12,18.71 12.12,19.39 12.35,20L11,21.07L2,14.07L3.62,12.81L11,18.54Z",lv="M20,11H23V13H20V11M1,11H4V13H1V11M13,1V4H11V1H13M4.92,3.5L7.05,5.64L5.63,7.05L3.5,4.93L4.92,3.5M16.95,5.63L19.07,3.5L20.5,4.93L18.37,7.05L16.95,5.63M12,6A6,6 0 0,1 18,12C18,14.22 16.79,16.16 15,17.2V19A1,1 0 0,1 14,20H10A1,1 0 0,1 9,19V17.2C7.21,16.16 6,14.22 6,12A6,6 0 0,1 12,6M14,21V22A1,1 0 0,1 13,23H11A1,1 0 0,1 10,22V21H14M11,18H13V15.87C14.73,15.43 16,13.86 16,12A4,4 0 0,0 12,8A4,4 0 0,0 8,12C8,13.86 9.27,15.43 11,15.87V18Z",zp="M12,2A7,7 0 0,1 19,9C19,11.38 17.81,13.47 16,14.74V17A1,1 0 0,1 15,18H9A1,1 0 0,1 8,17V14.74C6.19,13.47 5,11.38 5,9A7,7 0 0,1 12,2M9,21V20H15V21A1,1 0 0,1 14,22H10A1,1 0 0,1 9,21M12,4A5,5 0 0,0 7,9C7,11.05 8.23,12.81 10,13.58V16H14V13.58C15.77,12.81 17,11.05 17,9A5,5 0 0,0 12,4Z",Co="M11 9.47V11H14.76L13 14.53V13H9.24L11 9.47M13 1L6 15H11V23L18 9H13V1Z",cv="M10.59,13.41C11,13.8 11,14.44 10.59,14.83C10.2,15.22 9.56,15.22 9.17,14.83C7.22,12.88 7.22,9.71 9.17,7.76V7.76L12.71,4.22C14.66,2.27 17.83,2.27 19.78,4.22C21.73,6.17 21.73,9.34 19.78,11.29L18.29,12.78C18.3,11.96 18.17,11.14 17.89,10.36L18.36,9.88C19.54,8.71 19.54,6.81 18.36,5.64C17.19,4.46 15.29,4.46 14.12,5.64L10.59,9.17C9.41,10.34 9.41,12.24 10.59,13.41M13.41,9.17C13.8,8.78 14.44,8.78 14.83,9.17C16.78,11.12 16.78,14.29 14.83,16.24V16.24L11.29,19.78C9.34,21.73 6.17,21.73 4.22,19.78C2.27,17.83 2.27,14.66 4.22,12.71L5.71,11.22C5.7,12.04 5.83,12.86 6.11,13.65L5.64,14.12C4.46,15.29 4.46,17.19 5.64,18.36C6.81,19.54 8.71,19.54 9.88,18.36L13.41,14.83C14.59,13.66 14.59,11.76 13.41,10.59C13,10.2 13,9.56 13.41,9.17Z",eS="M12,17A2,2 0 0,0 14,15C14,13.89 13.1,13 12,13A2,2 0 0,0 10,15A2,2 0 0,0 12,17M18,8A2,2 0 0,1 20,10V20A2,2 0 0,1 18,22H6A2,2 0 0,1 4,20V10C4,8.89 4.9,8 6,8H7V6A5,5 0 0,1 12,1A5,5 0 0,1 17,6V8H18M12,3A3,3 0 0,0 9,6V8H15V6A3,3 0 0,0 12,3Z",uv="M10 13C11.1 13 12 13.89 12 15C12 16.11 11.11 17 10 17S8 16.11 8 15 8.9 13 10 13M18 1C15.24 1 13 3.24 13 6V8H4C2.9 8 2 8.9 2 10V20C2 21.1 2.9 22 4 22H16C17.1 22 18 21.1 18 20V10C18 8.9 17.1 8 16 8H15V6C15 4.34 16.34 3 18 3S21 4.34 21 6V8H23V6C23 3.24 20.76 1 18 1M16 10V20H4V10H16Z",fu="M12,17C10.89,17 10,16.1 10,15C10,13.89 10.89,13 12,13A2,2 0 0,1 14,15A2,2 0 0,1 12,17M18,20V10H6V20H18M18,8A2,2 0 0,1 20,10V20A2,2 0 0,1 18,22H6C4.89,22 4,21.1 4,20V10C4,8.89 4.89,8 6,8H7V6A5,5 0 0,1 12,1A5,5 0 0,1 17,6V8H18M12,3A3,3 0 0,0 9,6V8H15V6A3,3 0 0,0 12,3Z",rn="M9.5,3A6.5,6.5 0 0,1 16,9.5C16,11.11 15.41,12.59 14.44,13.73L14.71,14H15.5L20.5,19L19,20.5L14,15.5V14.71L13.73,14.44C12.59,15.41 11.11,16 9.5,16A6.5,6.5 0 0,1 3,9.5A6.5,6.5 0 0,1 9.5,3M9.5,5C7,5 5,7 5,9.5C5,12 7,14 9.5,14C12,14 14,12 14,9.5C14,7 12,5 9.5,5Z",dv="M17,17H7V7H17M21,11V9H19V7C19,5.89 18.1,5 17,5H15V3H13V5H11V3H9V5H7C5.89,5 5,5.89 5,7V9H3V11H5V13H3V15H5V17A2,2 0 0,0 7,19H9V21H11V19H13V21H15V19H17A2,2 0 0,0 19,17V15H21V13H19V11M13,13H11V11H13M15,9H9V15H15V9Z",tS="M3,6H21V8H3V6M3,11H21V13H3V11M3,16H21V18H3V16Z",gr="M7,10L12,15L17,10H7Z",sS="M20 2H4C2.9 2 2 2.9 2 4V22L6 18H20C21.1 18 22 17.1 22 16V4C22 2.9 21.1 2 20 2M20 16H5.2L4 17.2V4H20V16Z",rS="M20 2H4C2.9 2 2 2.9 2 4V22L6 18H20C21.1 18 22 17.1 22 16V4C22 2.9 21.1 2 20 2M20 16H5.2L4 17.2V4H20V16M17 11H15V9H17M13 11H11V9H13M9 11H7V9H9",iS="M21 11C21 6.03 16.97 2 12 2S3 6.03 3 11C3 14.92 5.5 18.24 9 19.5V22H11V19.94C11.33 20 11.66 20 12 20S12.67 20 13 19.94V22H15V19.5C18.5 18.24 21 14.92 21 11M12 18C8.14 18 5 14.86 5 11S8.14 4 12 4 19 7.14 19 11 15.86 18 12 18M8 7H16V9H8V7M12.75 10L9.75 13L11 14.25L9.75 15.5L11.25 17L14.25 14L13 12.75L14.25 11.5L12.75 10Z",mv="M19,13H5V11H19V13Z",nS="M20 14H4V10H20",Gp="M21,16V4H3V16H21M21,2A2,2 0 0,1 23,4V16A2,2 0 0,1 21,18H14V20H16V22H8V20H10V18H3C1.89,18 1,17.1 1,16V4C1,2.89 1.89,2 3,2H21M5,6H14V11H5V6M15,6H19V8H15V6M19,9V14H15V9H19M5,12H9V14H5V12M10,12H14V14H10V12Z",aS="M9,6H5V10H7V8H9M19,10H17V12H15V14H19M21,16H3V4H21M21,2H3C1.89,2 1,2.89 1,4V16A2,2 0 0,0 3,18H10V20H8V22H16V20H14V18H21A2,2 0 0,0 23,16V4C23,2.89 22.1,2 21,2",oS="M2 12A10 10 0 0 0 15 21.54A10 10 0 0 1 15 2.46A10 10 0 0 0 2 12Z",hv="M18.13 12L19.39 10.74C19.83 10.3 20.39 10.06 21 10V9L15 3H5C3.89 3 3 3.89 3 5V19C3 20.1 3.89 21 5 21H11V19.13L11.13 19H5V5H12V12H18.13M14 4.5L19.5 10H14V4.5M19.13 13.83L21.17 15.87L15.04 22H13V19.96L19.13 13.83M22.85 14.19L21.87 15.17L19.83 13.13L20.81 12.15C21 11.95 21.33 11.95 21.53 12.15L22.85 13.47C23.05 13.67 23.05 14 22.85 14.19Z",pv="M5 19V5H12V12H19V13C19.7 13 20.37 13.13 21 13.35V9L15 3H5C3.89 3 3 3.89 3 5V19C3 20.1 3.89 21 5 21H13.35C13.13 20.37 13 19.7 13 19H5M14 4.5L19.5 10H14V4.5M23 18V20H20V23H18V20H15V18H18V15H20V18H23Z",lS="M15 3H5A2 2 0 0 0 3 5V19A2 2 0 0 0 5 21H19A2 2 0 0 0 21 19V9L15 3M19 19H5V5H14V10H19M17 14H7V12H17M14 17H7V15H14",gu="M3,7V5H5V4C5,2.89 5.9,2 7,2H13V9L15.5,7.5L18,9V2H19C20.05,2 21,2.95 21,4V20C21,21.05 20.05,22 19,22H7C5.95,22 5,21.05 5,20V19H3V17H5V13H3V11H5V7H3M7,11H5V13H7V11M7,7V5H5V7H7M7,19V17H5V19H7Z",cS="M16.75 22.16L14 19.16L15.16 18L16.75 19.59L20.34 16L21.5 17.41L16.75 22.16M3 7V5H5V4C5 2.89 5.9 2 7 2H13V9L15.5 7.5L18 9V2H19C20.05 2 21 2.95 21 4V13.8C20.12 13.29 19.09 13 18 13C14.69 13 12 15.69 12 19C12 20.09 12.29 21.12 12.8 22H7C5.95 22 5 21.05 5 20V19H3V17H5V13H3V11H5V7H3M5 5V7H7V5H5M5 19H7V17H5V19M5 13H7V11H5V13Z",fv="M3 7V5H5V4C5 2.9 5.9 2 7 2H13V9L15.5 7.5L18 9V2H19C20 2 21 3 21 4V13.8C20.1 13.3 19.1 13 18 13C14.7 13 12 15.7 12 19C12 20.1 12.3 21.1 12.8 22H7C5.9 22 5 21 5 20V19H3V17H5V13H3V11H5V7H3M5 5V7H7V5H5M5 19H7V17H5V19M5 13H7V11H5V13M17 15V18H14V20H17V23H19V20H22V18H19V15H17Z",gv="M14,3V5H17.59L7.76,14.83L9.17,16.24L19,6.41V10H21V3M19,19H5V5H12V3H5C3.89,3 3,3.9 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V12H19V19Z",uS="M21,16.5C21,16.88 20.79,17.21 20.47,17.38L12.57,21.82C12.41,21.94 12.21,22 12,22C11.79,22 11.59,21.94 11.43,21.82L3.53,17.38C3.21,17.21 3,16.88 3,16.5V7.5C3,7.12 3.21,6.79 3.53,6.62L11.43,2.18C11.59,2.06 11.79,2 12,2C12.21,2 12.41,2.06 12.57,2.18L20.47,6.62C20.79,6.79 21,7.12 21,7.5V16.5M12,4.15L10.11,5.22L16,8.61L17.96,7.5L12,4.15M6.04,7.5L12,10.85L13.96,9.75L8.08,6.35L6.04,7.5M5,15.91L11,19.29V12.58L5,9.21V15.91M19,15.91V9.21L13,12.58V19.29L19,15.91Z",_u="M17.5,12A1.5,1.5 0 0,1 16,10.5A1.5,1.5 0 0,1 17.5,9A1.5,1.5 0 0,1 19,10.5A1.5,1.5 0 0,1 17.5,12M14.5,8A1.5,1.5 0 0,1 13,6.5A1.5,1.5 0 0,1 14.5,5A1.5,1.5 0 0,1 16,6.5A1.5,1.5 0 0,1 14.5,8M9.5,8A1.5,1.5 0 0,1 8,6.5A1.5,1.5 0 0,1 9.5,5A1.5,1.5 0 0,1 11,6.5A1.5,1.5 0 0,1 9.5,8M6.5,12A1.5,1.5 0 0,1 5,10.5A1.5,1.5 0 0,1 6.5,9A1.5,1.5 0 0,1 8,10.5A1.5,1.5 0 0,1 6.5,12M12,3A9,9 0 0,0 3,12A9,9 0 0,0 12,21A1.5,1.5 0 0,0 13.5,19.5C13.5,19.11 13.35,18.76 13.11,18.5C12.88,18.23 12.73,17.88 12.73,17.5A1.5,1.5 0 0,1 14.23,16H16A5,5 0 0,0 21,11C21,6.58 16.97,3 12,3Z",Zp="M14,19H18V5H14M6,19H10V5H6V19Z",bt="M20.71,7.04C21.1,6.65 21.1,6 20.71,5.63L18.37,3.29C18,2.9 17.35,2.9 16.96,3.29L15.12,5.12L18.87,8.87M3,17.25V21H6.75L17.81,9.93L14.06,6.18L3,17.25Z",nn="M8,5.14V19.14L19,12.14L8,5.14Z",Za="M3 16H10V14H3M18 14V10H16V14H12V16H16V20H18V16H22V14M14 6H3V8H14M14 10H3V12H14V10Z",dS="M14 10H3V12H14V10M14 6H3V8H14V6M3 16H10V14H3V16M14.4 22L17 19.4L19.6 22L21 20.6L18.4 18L21 15.4L19.6 14L17 16.6L14.4 14L13 15.4L15.6 18L13 20.6L14.4 22Z",qp="M19,13H13V19H11V13H5V11H11V5H13V11H19V13Z",mS="M20 14H14V20H10V14H4V10H10V4H14V10H20V14Z",_v="M16.56,5.44L15.11,6.89C16.84,7.94 18,9.83 18,12A6,6 0 0,1 12,18A6,6 0 0,1 6,12C6,9.83 7.16,7.94 8.88,6.88L7.44,5.44C5.36,6.88 4,9.28 4,12A8,8 0 0,0 12,20A8,8 0 0,0 20,12C20,9.28 18.64,6.88 16.56,5.44M13,3H11V13H13",hS="M13,3H11V13H13V3M17.83,5.17L16.41,6.59C18.05,7.91 19,9.9 19,12A7,7 0 0,1 12,19C8.14,19 5,15.88 5,12C5,9.91 5.95,7.91 7.58,6.58L6.17,5.17C2.38,8.39 1.92,14.07 5.14,17.86C8.36,21.64 14.04,22.1 17.83,18.88C19.85,17.17 21,14.65 21,12C21,9.37 19.84,6.87 17.83,5.17Z",Xp="M18,3H6V7H18M19,12A1,1 0 0,1 18,11A1,1 0 0,1 19,10A1,1 0 0,1 20,11A1,1 0 0,1 19,12M16,19H8V14H16M19,8H5A3,3 0 0,0 2,11V17H6V21H18V17H22V11A3,3 0 0,0 19,8Z",qa="M19,6A1,1 0 0,0 20,5A1,1 0 0,0 19,4A1,1 0 0,0 18,5A1,1 0 0,0 19,6M19,2A3,3 0 0,1 22,5V11H18V7H6V11H2V5A3,3 0 0,1 5,2H19M18,18.25C18,18.63 17.79,18.96 17.47,19.13L12.57,21.82C12.4,21.94 12.21,22 12,22C11.79,22 11.59,21.94 11.43,21.82L6.53,19.13C6.21,18.96 6,18.63 6,18.25V13C6,12.62 6.21,12.29 6.53,12.12L11.43,9.68C11.59,9.56 11.79,9.5 12,9.5C12.21,9.5 12.4,9.56 12.57,9.68L17.47,12.12C17.79,12.29 18,12.62 18,13V18.25M12,11.65L9.04,13L12,14.6L14.96,13L12,11.65M8,17.66L11,19.29V16.33L8,14.71V17.66M16,17.66V14.71L13,16.33V19.29L16,17.66Z",Us="M7,2H17V8H19V13H16.5L13,17H11L7.5,13H5V8H7V2M10,22H2V20H10A1,1 0 0,0 11,19V18H13V19A3,3 0 0,1 10,22Z",vv="M7 2H17V8H19V13H16.5L13 17H11L7.5 13H5V8H7V2M10 22H2V20H10C10.6 20 11 19.5 11 19V18H13V19C13 20.7 11.7 22 10 22M21 13V7H23V13H21M21 17V15H23V17H21Z",pS="M7,2H17V7H19V13H16.5L13,17H11L7.5,13H5V7H7V2M10,22H2V20H10A1,1 0 0,0 11,19V18H13V19A3,3 0 0,1 10,22M7,9V11H8.5L12,15L15.5,11H17V9H15V4H9V9H7Z",fS="M13,2.03V2.05L13,4.05C17.39,4.59 20.5,8.58 19.96,12.97C19.5,16.61 16.64,19.5 13,19.93V21.93C18.5,21.38 22.5,16.5 21.95,11C21.5,6.25 17.73,2.5 13,2.03M11,2.06C9.05,2.25 7.19,3 5.67,4.26L7.1,5.74C8.22,4.84 9.57,4.26 11,4.06V2.06M4.26,5.67C3,7.19 2.25,9.04 2.05,11H4.05C4.24,9.58 4.8,8.23 5.69,7.1L4.26,5.67M2.06,13C2.26,14.96 3.03,16.81 4.27,18.33L5.69,16.9C4.81,15.77 4.24,14.42 4.06,13H2.06M7.1,18.37L5.67,19.74C7.18,21 9.04,21.79 11,22V20C9.58,19.82 8.23,19.25 7.1,18.37M12.5,7V12.25L17,14.92L16.25,16.15L11,13V7H12.5Z",bv="M13 18H11V16H13V18M13 15H11C11 11.75 14 12 14 10C14 8.9 13.1 8 12 8C10.9 8 10 8.9 10 10H8C8 7.79 9.79 6 12 6C14.21 6 16 7.79 16 10C16 12.5 13 12.75 13 15M22 12C22 17.18 18.05 21.45 13 21.95V19.94C16.95 19.45 20 16.08 20 12C20 7.92 16.95 4.55 13 4.06V2.05C18.05 2.55 22 6.82 22 12M11 2.05V4.06C9.54 4.24 8.2 4.82 7.09 5.68L5.67 4.26C7.15 3.05 9 2.25 11 2.05M4.06 11H2.05C2.25 9 3.05 7.15 4.26 5.67L5.68 7.1C4.82 8.2 4.24 9.54 4.06 11M11 19.94V21.95C9 21.75 7.15 20.96 5.67 19.74L7.09 18.32C8.2 19.18 9.54 19.76 11 19.94M2.05 13H4.06C4.24 14.46 4.82 15.8 5.68 16.91L4.26 18.33C3.05 16.85 2.25 15 2.05 13Z",ll="M13,2.03C17.73,2.5 21.5,6.25 21.95,11C22.5,16.5 18.5,21.38 13,21.93V19.93C16.64,19.5 19.5,16.61 19.96,12.97C20.5,8.58 17.39,4.59 13,4.05V2.05L13,2.03M11,2.06V4.06C9.57,4.26 8.22,4.84 7.1,5.74L5.67,4.26C7.19,3 9.05,2.25 11,2.06M4.26,5.67L5.69,7.1C4.8,8.23 4.24,9.58 4.05,11H2.05C2.25,9.04 3,7.19 4.26,5.67M2.06,13H4.06C4.24,14.42 4.81,15.77 5.69,16.9L4.27,18.33C3.03,16.81 2.26,14.96 2.06,13M7.1,18.37C8.23,19.25 9.58,19.82 11,20V22C9.04,21.79 7.18,21 5.67,19.74L7.1,18.37M12,7.5L7.5,12H11V16H13V12H16.5L12,7.5Z",gS="M7.95,3L6.53,5.19L7.95,7.4H7.94L5.95,10.5L4.22,9.6L5.64,7.39L4.22,5.19L6.22,2.09L7.95,3M13.95,2.89L12.53,5.1L13.95,7.3L13.94,7.31L11.95,10.4L10.22,9.5L11.64,7.3L10.22,5.1L12.22,2L13.95,2.89M20,2.89L18.56,5.1L20,7.3V7.31L18,10.4L16.25,9.5L17.67,7.3L16.25,5.1L18.25,2L20,2.89M2,22V14A2,2 0 0,1 4,12H20A2,2 0 0,1 22,14V22H20V20H4V22H2M6,14A1,1 0 0,0 5,15V17A1,1 0 0,0 6,18A1,1 0 0,0 7,17V15A1,1 0 0,0 6,14M10,14A1,1 0 0,0 9,15V17A1,1 0 0,0 10,18A1,1 0 0,0 11,17V15A1,1 0 0,0 10,14M14,14A1,1 0 0,0 13,15V17A1,1 0 0,0 14,18A1,1 0 0,0 15,17V15A1,1 0 0,0 14,14M18,14A1,1 0 0,0 17,15V17A1,1 0 0,0 18,18A1,1 0 0,0 19,17V15A1,1 0 0,0 18,14Z",yv="M20,12H4A2,2 0 0,0 2,14V22H4V20H20V22H22V14A2,2 0 0,0 20,12M7,17A1,1 0 0,1 6,18A1,1 0 0,1 5,17V15A1,1 0 0,1 6,14A1,1 0 0,1 7,15V17M11,17A1,1 0 0,1 10,18A1,1 0 0,1 9,17V15A1,1 0 0,1 10,14A1,1 0 0,1 11,15V17M15,17A1,1 0 0,1 14,18A1,1 0 0,1 13,17V15A1,1 0 0,1 14,14A1,1 0 0,1 15,15V17M19,17A1,1 0 0,1 18,18A1,1 0 0,1 17,17V15A1,1 0 0,1 18,14A1,1 0 0,1 19,15V17Z",_S="M20,8H22V10H20V8M4,5H20A2,2 0 0,1 22,7H19V9H5V13H8V16H19V17H22A2,2 0 0,1 20,19H16V20H14V19H11V20H7V19H4A2,2 0 0,1 2,17V7A2,2 0 0,1 4,5M19,15H9V10H19V11H22V13H19V15M13,12V14H15V12H13M5,6V8H6V6H5M7,6V8H8V6H7M9,6V8H10V6H9M11,6V8H12V6H11M13,6V8H14V6H13M15,6V8H16V6H15M20,14H22V16H20V14Z",an="M17.65,6.35C16.2,4.9 14.21,4 12,4A8,8 0 0,0 4,12A8,8 0 0,0 12,20C15.73,20 18.84,17.45 19.73,14H17.65C16.83,16.33 14.61,18 12,18A6,6 0 0,1 6,12A6,6 0 0,1 12,6C13.66,6 15.14,6.69 16.22,7.78L13,11H20V4L17.65,6.35Z",vS="M2 12C2 16.97 6.03 21 11 21C13.39 21 15.68 20.06 17.4 18.4L15.9 16.9C14.63 18.25 12.86 19 11 19C4.76 19 1.64 11.46 6.05 7.05C10.46 2.64 18 5.77 18 12H15L19 16H19.1L23 12H20C20 7.03 15.97 3 11 3C6.03 3 2 7.03 2 12Z",wte="M2 12C2 17 6 21 11 21C13.4 21 15.7 20.1 17.4 18.4L15.9 16.9C14.6 18.3 12.9 19 11 19C4.8 19 1.6 11.5 6.1 7.1S18 5.8 18 12H15L19 16H19.1L23 12H20C20 7 16 3 11 3S2 7 2 12M10 15H12V17H10V15M10 7H12V13H10V7",vu="M18,17H10.5L12.5,15H18M6,17V14.5L13.88,6.65C14.07,6.45 14.39,6.45 14.59,6.65L16.35,8.41C16.55,8.61 16.55,8.92 16.35,9.12L8.47,17M19,3H5C3.89,3 3,3.89 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3Z",_r="M12,4C14.1,4 16.1,4.8 17.6,6.3C20.7,9.4 20.7,14.5 17.6,17.6C15.8,19.5 13.3,20.2 10.9,19.9L11.4,17.9C13.1,18.1 14.9,17.5 16.2,16.2C18.5,13.9 18.5,10.1 16.2,7.7C15.1,6.6 13.5,6 12,6V10.6L7,5.6L12,0.6V4M6.3,17.6C3.7,15 3.3,11 5.1,7.9L6.6,9.4C5.5,11.6 5.9,14.4 7.8,16.2C8.3,16.7 8.9,17.1 9.6,17.4L9,19.4C8,19 7.1,18.4 6.3,17.6Z",bS="M13,3A9,9 0 0,0 4,12H1L4.89,15.89L4.96,16.03L9,12H6A7,7 0 0,1 13,5A7,7 0 0,1 20,12A7,7 0 0,1 13,19C11.07,19 9.32,18.21 8.06,16.94L6.64,18.36C8.27,20 10.5,21 13,21A9,9 0 0,0 22,12A9,9 0 0,0 13,3Z",yS="M13.13 22.19L11.5 18.36C13.07 17.78 14.54 17 15.9 16.09L13.13 22.19M5.64 12.5L1.81 10.87L7.91 8.1C7 9.46 6.22 10.93 5.64 12.5M21.61 2.39C21.61 2.39 16.66 .269 11 5.93C8.81 8.12 7.5 10.53 6.65 12.64C6.37 13.39 6.56 14.21 7.11 14.77L9.24 16.89C9.79 17.45 10.61 17.63 11.36 17.35C13.5 16.53 15.88 15.19 18.07 13C23.73 7.34 21.61 2.39 21.61 2.39M14.54 9.46C13.76 8.68 13.76 7.41 14.54 6.63S16.59 5.85 17.37 6.63C18.14 7.41 18.15 8.68 17.37 9.46C16.59 10.24 15.32 10.24 14.54 9.46M8.88 16.53L7.47 15.12L8.88 16.53M6.24 22L9.88 18.36C9.54 18.27 9.21 18.12 8.91 17.91L4.83 22H6.24M2 22H3.41L8.18 17.24L6.76 15.83L2 20.59V22M2 19.17L6.09 15.09C5.88 14.79 5.73 14.47 5.64 14.12L2 17.76V19.17Z",CS="M13,4.07V1L8.45,5.55L13,10V6.09C15.84,6.57 18,9.03 18,12C18,14.97 15.84,17.43 13,17.91V19.93C16.95,19.44 20,16.08 20,12C20,7.92 16.95,4.56 13,4.07M7.1,18.32C8.26,19.22 9.61,19.76 11,19.93V17.9C10.13,17.75 9.29,17.41 8.54,16.87L7.1,18.32M6.09,13H4.07C4.24,14.39 4.79,15.73 5.69,16.89L7.1,15.47C6.58,14.72 6.23,13.88 6.09,13M7.11,8.53L5.7,7.11C4.8,8.27 4.24,9.61 4.07,11H6.09C6.23,10.13 6.58,9.28 7.11,8.53Z",$S="M16.89,15.5L18.31,16.89C19.21,15.73 19.76,14.39 19.93,13H17.91C17.77,13.87 17.43,14.72 16.89,15.5M13,17.9V19.92C14.39,19.75 15.74,19.21 16.9,18.31L15.46,16.87C14.71,17.41 13.87,17.76 13,17.9M19.93,11C19.76,9.61 19.21,8.27 18.31,7.11L16.89,8.53C17.43,9.28 17.77,10.13 17.91,11M15.55,5.55L11,1V4.07C7.06,4.56 4,7.92 4,12C4,16.08 7.05,19.44 11,19.93V17.91C8.16,17.43 6,14.97 6,12C6,9.03 8.16,6.57 11,6.09V10L15.55,5.55Z",xS="M8.46,15.06L7.05,16.47L5.68,15.1C4.82,16.21 4.24,17.54 4.06,19H6V21H2V20C2,15.16 5.44,11.13 10,10.2V8.2L2,5V3H22V5L14,8.2V10.2C18.56,11.13 22,15.16 22,20V21H18V19H19.94C19.76,17.54 19.18,16.21 18.32,15.1L16.95,16.47L15.54,15.06L16.91,13.68C15.8,12.82 14.46,12.24 13,12.06V14H11V12.06C9.54,12.24 8.2,12.82 7.09,13.68L8.46,15.06M12,18A2,2 0 0,1 14,20A2,2 0 0,1 12,22C11.68,22 11.38,21.93 11.12,21.79L7.27,20L11.12,18.21C11.38,18.07 11.68,18 12,18Z",cl="M20 20V17H22V20C22 21.11 21.1 22 20 22H17V20H20M2 20V17H4V20H7V22H4C2.9 22 2 21.1 2 20M10 20H14V22H10V20M14.59 8L12 10.59L9.41 8L8 9.41L10.59 12L8 14.59L9.41 16L12 13.41L14.59 16L16 14.59L13.41 12L16 9.41L14.59 8M20 10H22V14H20V10M2 10H4V14H2V10M2 4C2 2.89 2.9 2 4 2H7V4H4V7H2V4M22 4V7H20V4H17V2H20C21.1 2 22 2.9 22 4M10 2H14V4H10V2Z",wS="M2,21L23,12L2,3V10L17,12L2,14V21Z",SS="M23,12H17V10L20.39,6H17V4H23V6L19.62,10H23V12M15,16H9V14L12.39,10H9V8H15V10L11.62,14H15V16M7,20H1V18L4.39,14H1V12H7V14L3.62,18H7V20Z",bu="M20.79,13.95L18.46,14.57L16.46,13.44V10.56L18.46,9.43L20.79,10.05L21.31,8.12L19.54,7.65L20,5.88L18.07,5.36L17.45,7.69L15.45,8.82L13,7.38V5.12L14.71,3.41L13.29,2L12,3.29L10.71,2L9.29,3.41L11,5.12V7.38L8.5,8.82L6.5,7.69L5.92,5.36L4,5.88L4.47,7.65L2.7,8.12L3.22,10.05L5.55,9.43L7.55,10.56V13.45L5.55,14.58L3.22,13.96L2.7,15.89L4.47,16.36L4,18.12L5.93,18.64L6.55,16.31L8.55,15.18L11,16.62V18.88L9.29,20.59L10.71,22L12,20.71L13.29,22L14.7,20.59L13,18.88V16.62L15.5,15.17L17.5,16.3L18.12,18.63L20,18.12L19.53,16.35L21.3,15.88L20.79,13.95M9.5,10.56L12,9.11L14.5,10.56V13.44L12,14.89L9.5,13.44V10.56Z",Cv="M12,16A3,3 0 0,1 9,13C9,11.88 9.61,10.9 10.5,10.39L20.21,4.77L14.68,14.35C14.18,15.33 13.17,16 12,16M12,3C13.81,3 15.5,3.5 16.97,4.32L14.87,5.53C14,5.19 13,5 12,5A8,8 0 0,0 4,13C4,15.21 4.89,17.21 6.34,18.65H6.35C6.74,19.04 6.74,19.67 6.35,20.06C5.96,20.45 5.32,20.45 4.93,20.07V20.07C3.12,18.26 2,15.76 2,13A10,10 0 0,1 12,3M22,13C22,15.76 20.88,18.26 19.07,20.07V20.07C18.68,20.45 18.05,20.45 17.66,20.06C17.27,19.67 17.27,19.04 17.66,18.65V18.65C19.11,17.2 20,15.21 20,13C20,12 19.81,11 19.46,10.1L20.67,8C21.5,9.5 22,11.18 22,13Z",Ste="M17.36,20.2V14.82H19.15V22H3V14.82H4.8V20.2H17.36M6.77,14.32L7.14,12.56L15.93,14.41L15.56,16.17L6.77,14.32M7.93,10.11L8.69,8.5L16.83,12.28L16.07,13.9L7.93,10.11M10.19,6.12L11.34,4.74L18.24,10.5L17.09,11.87L10.19,6.12M14.64,1.87L20,9.08L18.56,10.15L13.2,2.94L14.64,1.87M6.59,18.41V16.61H15.57V18.41H6.59Z",$v="M18,18H6V6H18V18Z",PS="M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4M9,9V15H15V9",xv="M9,3L5,7H8V14H10V7H13M16,17V10H14V17H11L15,21L19,17H16Z",wv="M12,18A6,6 0 0,1 6,12C6,11 6.25,10.03 6.7,9.2L5.24,7.74C4.46,8.97 4,10.43 4,12A8,8 0 0,0 12,20V23L16,19L12,15M12,4V1L8,5L12,9V6A6,6 0 0,1 18,12C18,13 17.75,13.97 17.3,14.8L18.76,16.26C19.54,15.03 20,13.57 20,12A8,8 0 0,0 12,4Z",DS="M19,18H5V6H19M21,4H3C1.89,4 1,4.89 1,6V18A2,2 0 0,0 3,20H21A2,2 0 0,0 23,18V6C23,4.89 22.1,4 21,4Z",Sv="M15.5,12C18,12 20,14 20,16.5C20,17.38 19.75,18.21 19.31,18.9L22.39,22L21,23.39L17.88,20.32C17.19,20.75 16.37,21 15.5,21C13,21 11,19 11,16.5C11,14 13,12 15.5,12M15.5,14A2.5,2.5 0 0,0 13,16.5A2.5,2.5 0 0,0 15.5,19A2.5,2.5 0 0,0 18,16.5A2.5,2.5 0 0,0 15.5,14M7,15V17H9C9.14,18.55 9.8,19.94 10.81,21H5C3.89,21 3,20.1 3,19V5C3,3.89 3.89,3 5,3H19A2,2 0 0,1 21,5V13.03C19.85,11.21 17.82,10 15.5,10C14.23,10 13.04,10.37 12.04,11H7V13H10C9.64,13.6 9.34,14.28 9.17,15H7M17,9V7H7V9H17Z",Pv="M15.5,12C18,12 20,14 20,16.5C20,17.38 19.75,18.21 19.31,18.9L22.39,22L21,23.39L17.88,20.32C17.19,20.75 16.37,21 15.5,21C13,21 11,19 11,16.5C11,14 13,12 15.5,12M15.5,14A2.5,2.5 0 0,0 13,16.5A2.5,2.5 0 0,0 15.5,19A2.5,2.5 0 0,0 18,16.5A2.5,2.5 0 0,0 15.5,14M5,3H19C20.11,3 21,3.89 21,5V13.03C20.5,12.23 19.81,11.54 19,11V5H5V19H9.5C9.81,19.75 10.26,20.42 10.81,21H5C3.89,21 3,20.11 3,19V5C3,3.89 3.89,3 5,3M7,7H17V9H7V7M7,11H12.03C11.23,11.5 10.54,12.19 10,13H7V11M7,15H9.17C9.06,15.5 9,16 9,16.5V17H7V15Z",fi="M15 13V5A3 3 0 0 0 9 5V13A5 5 0 1 0 15 13M12 4A1 1 0 0 1 13 5V8H11V5A1 1 0 0 1 12 4Z",Dv="M17 3H21V5H17V3M17 7H21V9H17V7M17 11H21V13H17.75L17 12.1V11M21 15V17H19C19 16.31 18.9 15.63 18.71 15H21M7 3V5H3V3H7M7 7V9H3V7H7M7 11V12.1L6.25 13H3V11H7M3 15H5.29C5.1 15.63 5 16.31 5 17H3V15M15 13V5C15 3.34 13.66 2 12 2S9 3.34 9 5V13C6.79 14.66 6.34 17.79 8 20S12.79 22.66 15 21 17.66 16.21 16 14C15.72 13.62 15.38 13.28 15 13M12 4C12.55 4 13 4.45 13 5V8H11V5C11 4.45 11.45 4 12 4Z",Tv="M12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4A8,8 0 0,1 20,12A8,8 0 0,1 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M16.24,7.76C15.07,6.58 13.53,6 12,6V12L7.76,16.24C10.1,18.58 13.9,18.58 16.24,16.24C18.59,13.9 18.59,10.1 16.24,7.76Z",TS="M12,20A7,7 0 0,1 5,13A7,7 0 0,1 12,6A7,7 0 0,1 19,13A7,7 0 0,1 12,20M19.03,7.39L20.45,5.97C20,5.46 19.55,5 19.04,4.56L17.62,6C16.07,4.74 14.12,4 12,4A9,9 0 0,0 3,13A9,9 0 0,0 12,22C17,22 21,17.97 21,13C21,10.88 20.26,8.93 19.03,7.39M11,14H13V8H11M15,1H9V3H15V1Z",Yp="M17,7H7A5,5 0 0,0 2,12A5,5 0 0,0 7,17H17A5,5 0 0,0 22,12A5,5 0 0,0 17,7M17,15A3,3 0 0,1 14,12A3,3 0 0,1 17,9A3,3 0 0,1 20,12A3,3 0 0,1 17,15Z",OS="M17,7H7A5,5 0 0,0 2,12A5,5 0 0,0 7,17H17A5,5 0 0,0 22,12A5,5 0 0,0 17,7M7,15A3,3 0 0,1 4,12A3,3 0 0,1 7,9A3,3 0 0,1 10,12A3,3 0 0,1 7,15Z",Ov="M17 6H7c-3.31 0-6 2.69-6 6s2.69 6 6 6h10c3.31 0 6-2.69 6-6s-2.69-6-6-6zm0 10H7c-2.21 0-4-1.79-4-4s1.79-4 4-4h10c2.21 0 4 1.79 4 4s-1.79 4-4 4zM7 9c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z",Mv="M9,3V4H4V6H5V19A2,2 0 0,0 7,21H17A2,2 0 0,0 19,19V6H20V4H15V3H9M9,8H11V17H9V8M13,8H15V17H13V8Z",MS="M2 12H4V17H20V12H22V17C22 18.11 21.11 19 20 19H4C2.9 19 2 18.11 2 17V12M12 15L17.55 9.54L16.13 8.13L13 11.25V2H11V11.25L7.88 8.13L6.46 9.55L12 15Z",kv="M18 5H6V7H18M6 9H18V11H6M2 12H4V17H20V12H22V17A2 2 0 0 1 20 19H4A2 2 0 0 1 2 17M18 13H6V15H18Z",kS="M3,17V19H9V17H3M3,5V7H13V5H3M13,21V19H21V17H13V15H11V21H13M7,9V11H3V13H7V15H9V9H7M21,13V11H11V13H21M15,9H17V7H21V5H17V3H15V9Z",Xa="M21,10.12H14.22L16.96,7.3C14.23,4.6 9.81,4.5 7.08,7.2C4.35,9.91 4.35,14.28 7.08,17C9.81,19.7 14.23,19.7 16.96,17C18.32,15.65 19,14.08 19,12.1H21C21,14.08 20.12,16.65 18.36,18.39C14.85,21.87 9.15,21.87 5.64,18.39C2.14,14.92 2.11,9.28 5.62,5.81C9.13,2.34 14.76,2.34 18.27,5.81L21,3V10.12M12.5,8V12.25L16,14.33L15.28,15.54L11,13V8H12.5Z",ES="M9,16V10H5L12,3L19,10H15V16H9M5,20V18H19V20H5Z",Jp="M15,7V11H16V13H13V5H15L12,1L9,5H11V13H8V10.93C8.7,10.56 9.2,9.85 9.2,9C9.2,7.78 8.21,6.8 7,6.8C5.78,6.8 4.8,7.78 4.8,9C4.8,9.85 5.3,10.56 6,10.93V13A2,2 0 0,0 8,15H11V18.05C10.29,18.41 9.8,19.15 9.8,20A2.2,2.2 0 0,0 12,22.2A2.2,2.2 0 0,0 14.2,20C14.2,19.15 13.71,18.41 13,18.05V15H16A2,2 0 0,0 18,13V11H19V7H15Z",yu="M5,7H9A2,2 0 0,1 11,9V15A2,2 0 0,1 9,17H5V15H9V13H6V11H9V9H5V7M13,7H16A3,3 0 0,1 19,10V14A3,3 0 0,1 16,17H13V7M16,15A1,1 0 0,0 17,14V10A1,1 0 0,0 16,9H15V15H16Z",LS="M19,5V7H15V5H19M9,5V11H5V5H9M19,13V19H15V13H19M9,17V19H5V17H9M21,3H13V9H21V3M11,3H3V13H11V3M21,11H13V21H21V11M11,15H3V21H11V15Z",Bg="M3,11H11V3H3M3,21H11V13H3M13,21H21V13H13M13,3V11H21V3",on="M12,2A7,7 0 0,1 19,9A7,7 0 0,1 12,16A7,7 0 0,1 5,9A7,7 0 0,1 12,2M12,4A5,5 0 0,0 7,9A5,5 0 0,0 12,14A5,5 0 0,0 17,9A5,5 0 0,0 12,4M12,6A3,3 0 0,1 15,9A3,3 0 0,1 12,12A3,3 0 0,1 9,9A3,3 0 0,1 12,6M6,22A2,2 0 0,1 4,20C4,19.62 4.1,19.27 4.29,18.97L6.11,15.81C7.69,17.17 9.75,18 12,18C14.25,18 16.31,17.17 17.89,15.81L19.71,18.97C19.9,19.27 20,19.62 20,20A2,2 0 0,1 18,22H6Z",AS="M12 6C13.66 6 15 7.34 15 9C15 9.78 14.7 10.5 14.21 11L10 6.79C10.5 6.3 11.22 6 12 6M12 4C14.76 4 17 6.24 17 9C17 10.33 16.47 11.53 15.62 12.42L17.04 13.84C18.25 12.59 19 10.88 19 9C19 5.13 15.87 2 12 2C10.12 2 8.41 2.75 7.16 3.96L8.58 5.38C9.47 4.53 10.67 4 12 4M22.11 21.46L20.84 22.73L19.46 21.35C19.1 21.75 18.58 22 18 22H6C4.89 22 4 21.11 4 20C4 19.62 4.1 19.27 4.29 18.97L6.11 15.81C7.69 17.17 9.75 18 12 18C13.21 18 14.37 17.75 15.43 17.32L13.85 15.74C13.26 15.91 12.64 16 12 16C8.13 16 5 12.87 5 9C5 8.36 5.09 7.74 5.26 7.15L1.11 3L2.39 1.73L22.11 21.46M12.1 14L7 8.9C7 8.93 7 8.97 7 9C7 11.76 9.24 14 12 14C12.03 14 12.07 14 12.1 14Z",FS="M22.7,19L13.6,9.9C14.5,7.6 14,4.9 12.1,3C10.1,1 7.1,0.6 4.7,1.7L9,6L6,9L1.6,4.7C0.4,7.1 0.9,10.1 2.9,12.1C4.8,14 7.5,14.5 9.8,13.6L18.9,22.7C19.3,23.1 19.9,23.1 20.3,22.7L22.6,20.4C23.1,20 23.1,19.3 22.7,19Z",RS=Object.defineProperty,HS=Object.getOwnPropertyDescriptor,Os=(s,e,t,r)=>{for(var i=r>1?void 0:r?HS(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&RS(e,t,i),i};let Qt=class extends k(L){constructor(){super(...arguments),this.mdiChevronDown=fr,this.panelToolbarHeight=mm}get expand(){return this.$store.getters["gui/getPanelExpand"](this.cardClass,this.viewport)}set expand(e){this.$store.dispatch("gui/saveExpandPanel",{name:this.cardClass,value:e,viewport:this.viewport})}get hasIconSlot(){return!!this.$slots.icon}get hasButtonsSlot(){return!!this.$slots.buttons}get getToolbarClass(){let e=this.toolbarClass;return this.collapsible&&(e+=" collapsible"),e}get additionalStyle(){return this.$vuetify.theme.dark?"":"border-bottom: 1px solid #A8A8A8"}};Os([w({default:null})],Qt.prototype,"icon",2);Os([w({required:!0,default:""})],Qt.prototype,"title",2);Os([w({default:!1})],Qt.prototype,"collapsible",2);Os([w({required:!0})],Qt.prototype,"cardClass",2);Os([w({default:""})],Qt.prototype,"toolbarColor",2);Os([w({default:""})],Qt.prototype,"toolbarClass",2);Os([w({default:!1})],Qt.prototype,"loading",2);Os([w({default:!0})],Qt.prototype,"marginBottom",2);Os([w({default:!1})],Qt.prototype,"hideButtonsOnCollapse",2);Qt=Os([S],Qt);var jS=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{class:"panel "+e.cardClass+" "+(e.marginBottom?"mb-3 mb-md-6":"")+" "+(e.expand?"":"expanded"),attrs:{loading:e.loading}},[t(Op,{staticClass:"panel-toolbar",class:e.getToolbarClass,style:e.additionalStyle,attrs:{flat:"",dense:"",color:e.toolbarColor,height:e.panelToolbarHeight}},[e._t("buttons-left"),t(ru,{staticClass:"d-flex align-center"},[e.hasIconSlot?e._t("icon"):e._e(),e.icon!==null&&!e.hasIconSlot?t(_,{attrs:{left:""}},[e._v(e._s(e.icon))]):e._e(),e.title?t("span",{staticClass:"subheading"},[e._v(e._s(e.title))]):e._e()],2),e._t("buttons-title"),t(ae),t(S$,{directives:[{name:"show",rawName:"v-show",value:e.hasButtonsSlot||e.collapsible,expression:"hasButtonsSlot || collapsible"}]},[e.expand||!e.hideButtonsOnCollapse?t("div",{staticClass:"d-flex align-center"},[e._t("buttons")],2):e._e(),e.collapsible?t(g,{staticClass:"btn-collapsible",attrs:{icon:"",ripple:!0},on:{click:function(r){e.expand=!e.expand}}},[t(_,{class:e.expand?"":"icon-rotate-90"},[e._v(e._s(e.mdiChevronDown))])],1):e._e()],1)],2),t(iu,[t("div",{directives:[{name:"show",rawName:"v-show",value:e.expand||!e.collapsible,expression:"expand || !collapsible"}]},[e._t("default")],2)])],1)},IS=[],NS=E(Qt,jS,IS,!1,null,"36b00e8e");const U=NS.exports;var VS=Object.getOwnPropertyDescriptor,BS=(s,e,t,r)=>{for(var i=r>1?void 0:r?VS(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let vt=class extends y{fgColor(s=1,e=this.$vuetify.theme.dark){const t=e?255:0;return"rgba(".concat(t,", ").concat(t,", ").concat(t,", ").concat(s,")")}bgColor(s=1){return this.fgColor(s,!this.$vuetify.theme.dark)}get themeName(){return this.$store.getters["gui/theme"]}get theme(){return this.$store.getters["gui/getTheme"]}get themeMode(){var s;return(s=this.$store.state.gui.uiSettings.mode)!=null?s:"dark"}get fgColorHi(){return this.fgColor(.8)}get fgColorMid(){return this.fgColor(.5)}get fgColorLow(){return this.fgColor(.2)}get fgColorFaint(){return this.fgColor(.1)}get machineButtonCol(){return this.$vuetify.theme.dark?"grey darken-3":"grey lighten-1"}get draggableBgStyle(){const s=this.$vuetify.theme.dark?"#282828":"#e7e7e7";return"background-color: ".concat(s)}get progressBarColor(){return this.$vuetify.theme.dark?"white":"primary"}get sidebarBgImage(){var s,e;return(s=this.theme.sidebarBackground)!=null&&s.show?(e=this.theme.sidebarBackground)!=null&&e.light&&this.themeMode==="light"?"/img/themes/sidebarBackground-".concat(this.themeName,"-light.png"):"/img/themes/sidebarBackground-".concat(this.themeName,".png"):this.$vuetify.theme.dark?"/img/sidebar-background.svg":"/img/sidebar-background-light.svg"}get sidebarLogo(){var e,t,r;const s=this.$store.getters["files/getSidebarLogo"];return s!==""||this.themeName==="mainsail"?s:(t=(e=this.theme.logo)==null?void 0:e.show)!=null&&t?(r=this.theme.logo)!=null&&r.light&&this.themeMode==="light"?"/img/themes/sidebarLogo-".concat(this.themeName,"-light.svg"):"/img/themes/sidebarLogo-".concat(this.themeName,".svg"):""}get mainBgImage(){var e,t;const s=this.$store.getters["files/getMainBackground"];return s||this.themeName==="mainsail"?s:(e=this.theme.mainBackground)!=null&&e.show?(t=this.theme.mainBackground)!=null&&t.light&&this.themeMode==="light"?"/img/themes/mainBackground-".concat(this.themeName,"-light.png"):"/img/themes/mainBackground-".concat(this.themeName,".png"):null}get themeCss(){var s;return(s=this.theme.css)!=null&&s?"/css/themes/".concat(this.themeName,".css"):null}};vt=BS([S],vt);var US=Object.getOwnPropertyDescriptor,WS=(s,e,t,r)=>{for(var i=r>1?void 0:r?US(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let pm=class extends k(L,vt){constructor(){super(...arguments),this.mdiConnection=Ap,this.mdiHelp=Wp,this.counter=0}get hostname(){return this.$store.state.socket.hostname}get port(){return this.$store.state.socket.port}get path(){return this.$store.state.socket.path}get formatHostname(){return parseInt(this.port)!==80&&this.port!==""?this.hostname+":"+this.port+this.path:this.hostname+this.path}get isConnecting(){return this.$store.state.socket.isConnecting}get connectingFailed(){return this.$store.state.socket.connectingFailed}get showDialog(){return!0}get titleText(){return this.connectingFailed?this.$t("ConnectionDialog.Failed",{host:this.formatHostname}):this.isConnecting?this.$t("ConnectionDialog.Connecting",{host:this.formatHostname}):this.guiIsReady?this.formatHostname:this.$t("ConnectionDialog.Initializing")}get connectionFailedMessage(){var s;return(s=this.$store.state.socket.connectionFailedMessage)!=null?s:null}get helpButtonUrl(){var s;return this.$store.state.socket.connectionFailedMessage?"https://docs.mainsail.xyz/faq/mainsail_errors/connection-".concat((s=this.connectionFailedMessage)==null?void 0:s.toLowerCase()):null}reconnect(){this.counter++,this.$store.dispatch("socket/setData",{connectingFailed:!1}),this.$socket.connect()}};pm=WS([S({components:{ConnectionStatus:lu}})],pm);var zS=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{persistent:"",width:400},model:{value:e.showDialog,callback:function(r){e.showDialog=r},expression:"showDialog"}},[t(U,{attrs:{title:e.titleText,icon:e.mdiConnection,"card-class":"the-connection-dialog","margin-bottom":!1}},[e.connectingFailed?t(Z,{staticClass:"pt-5"},[t(lu,{attrs:{moonraker:!1}}),t("p",{staticClass:"text-center mt-3 mb-0"},[e._v(" "+e._s(e.$t("ConnectionDialog.CannotConnectTo",{host:e.formatHostname}))+" ")]),e.connectionFailedMessage?t("p",{staticClass:"text-center mt-1 red--text"},[e._v(" "+e._s(e.$t("ConnectionDialog.ErrorMessage",{message:e.connectionFailedMessage}))+" ")]):e._e(),e.counter>2?[t(I,{staticClass:"my-3"}),t("p",[e._v(e._s(e.$t("ConnectionDialog.CheckMoonrakerLog")))]),t("ul",[t("li",[e._v("~/printer_data/logs/moonraker.log")])]),t(I,{staticClass:"mt-4 mb-5"})]:e._e(),t("div",{staticClass:"text-center mt-3"},[e.helpButtonUrl?t(g,{staticClass:"text--disabled mr-3",attrs:{href:e.helpButtonUrl,target:"_blank"}},[t(_,{attrs:{left:""}},[e._v(e._s(e.mdiHelp))]),e._v(" "+e._s(e.$t("ConnectionDialog.Help"))+" ")],1):e._e(),t(g,{staticClass:"primary--text",on:{click:e.reconnect}},[e._v(e._s(e.$t("ConnectionDialog.TryAgain")))])],1)],2):t(Z,{staticClass:"pt-5"},[t(Ss,{attrs:{color:e.progressBarColor,indeterminate:""}})],1)],1)],1)},GS=[],ZS=E(pm,zS,GS,!1,null,null);const Ev=ZS.exports;var qS=Object.getOwnPropertyDescriptor,XS=(s,e,t,r)=>{for(var i=r>1?void 0:r?qS(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let fm=class extends k(L){constructor(){super(...arguments),this.addPrinterValid=!1,this.dialogAddPrinter={bool:!1,hostname:"",port:7125,path:"/",name:""},this.editPrinterValid=!1,this.dialogEditPrinter={bool:!1,id:"",hostname:"",port:0,path:"/",name:""},this.showOptionalSettings=!1,this.mdiConnection=Ap,this.mdiCloseThick=pe,this.mdiSync=wv,this.mdiDelete=Ue,this.mdiPencil=bt,this.mdiCheckboxMarkedCircle=X_,this.mdiCancel=Z_,this.mdiShowOptional=ss,this.mdiHideOptional=Ew}get printers(){var s;return(s=this.$store.getters["gui/remoteprinters/getRemoteprinters"])!=null?s:[]}get canAddPrinters(){return this.instancesDB!=="json"}get protocol(){return this.$store.state.socket.protocol}get defaultMoonrakerPort(){return this.protocol==="wss"?7130:7125}get hostname(){return this.$store.state.socket.hostname}get port(){return this.$store.state.socket.port}get path(){return this.$store.state.socket.path}get name(){return this.$store.state.printer}get formatHostname(){return this.hostname+(this.port!==""?":"+this.port:"")+(this.path!==""?this.path:"")}get isConnected(){return this.$store.state.socket.isConnected}get isConnecting(){return this.$store.state.socket.isConnecting}get connectingFailed(){return this.$store.state.socket.connectingFailed}get showDialog(){return!this.isConnected||this.isConnected&&!this.guiIsReady}get currentUrl(){let s=document.location.protocol+"//"+window.location.hostname;return parseInt(window.location.port)!==80&&window.location.port!==""&&(s+=":"+window.location.port),s}get showCorsInfo(){return this.printers.length?(this.printers.forEach(s=>{var e;if(s&&!((e=s.socket)!=null&&e.isConnected))return!0}),!1):!0}get panelTitle(){return this.dialogAddPrinter.bool?this.$t("SelectPrinterDialog.AddPrinter"):this.dialogEditPrinter.bool?this.$t("SelectPrinterDialog.EditPrinter"):this.isConnecting?this.$t("SelectPrinterDialog.Connecting",{host:this.formatHostname}):this.isConnected&&!this.guiIsReady?this.$t("ConnectionDialog.Initializing"):this.connectingFailed?this.$t("SelectPrinterDialog.ConnectionFailed",{host:this.formatHostname}):this.$t("SelectPrinterDialog.SelectPrinter")}getPrinterName(s){return this.$store.getters["farm/getPrinterName"](s)}createPrinter(){this.dialogAddPrinter.hostname="",this.dialogAddPrinter.port=this.defaultMoonrakerPort,this.dialogAddPrinter.bool=!0}addPrinter(){const s={hostname:this.dialogAddPrinter.hostname,port:this.dialogAddPrinter.port,path:this.dialogAddPrinter.path,name:this.dialogAddPrinter.name};this.$store.dispatch("gui/remoteprinters/store",{values:s}),this.dialogAddPrinter.hostname="",this.dialogAddPrinter.bool=!1,this.dialogAddPrinter.path="/",this.dialogAddPrinter.name=""}editPrinter(s){var e,t,r;this.dialogEditPrinter.hostname=s.hostname,this.dialogEditPrinter.port=s.port,this.dialogEditPrinter.id=(e=s.id)!=null?e:"",this.dialogEditPrinter.path=(t=s.path)!=null?t:"/",this.dialogEditPrinter.name=(r=s.name)!=null?r:"",this.dialogEditPrinter.bool=!0,this.showOptionalSettings=s.name?s.name.length>0:!1}updatePrinter(){const s={hostname:this.dialogEditPrinter.hostname,port:this.dialogEditPrinter.port,path:this.dialogEditPrinter.path,id:this.dialogEditPrinter.id,name:this.dialogEditPrinter.name};this.$store.dispatch("gui/remoteprinters/update",{id:this.dialogEditPrinter.id,values:s}),this.dialogEditPrinter.bool=!1}delPrinter(){this.$store.dispatch("gui/remoteprinters/delete",this.dialogEditPrinter.id),this.dialogEditPrinter.bool=!1}connect(s){this.$store.dispatch("socket/setData",{hostname:s.socket.hostname,port:s.socket.port,path:s.socket.path});const e=s.socket.path.replaceAll(/(^\/*)|(\/*$)/g,""),t=this.protocol+"://"+s.socket.hostname+":"+s.socket.port+(e.length>0?"/".concat(e):"")+"/websocket";this.$socket.setUrl(t),this.$socket.connect()}reconnect(){this.$store.dispatch("socket/setData",{connectingFailed:!1}),this.$socket.connect()}switchToChangePrinter(){this.$store.dispatch("socket/setData",{connectingFailed:!1})}checkPrinters(){this.printers.forEach(s=>{var e,t;s&&!((e=s.socket)!=null&&e.isConnected)&&!((t=s.socket)!=null&&t.isConnecting)&&this.$store.dispatch("farm/"+s.id+"/connect")})}mounted(){this.$store.dispatch("gui/remoteprinters/initFromLocalstorage").then(()=>{if(!("printer"in this.$route.query))return;let s=this.$route.query.printer.toString().toLowerCase(),e=this.printers.filter(t=>{var r;return((r=t.name)==null?void 0:r.toLowerCase())===s});if(e.length==0){window.console.error("No printer with given name '".concat(s,"' found. Showing selection dialog instead."));return}if(e.length>1){window.console.error("Multiple printers with name '".concat(s,"' found. Showing selection dialog instead."));return}this.connect(e[0])})}};fm=XS([S({components:{Panel:U}})],fm);var YS=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{persistent:"",width:400},model:{value:e.showDialog,callback:function(r){e.showDialog=r},expression:"showDialog"}},[t(U,{attrs:{"card-class":"select-printer-dialog",icon:e.mdiConnection,title:e.panelTitle,"margin-bottom":!1,"toolbar-color":"toolbar"},scopedSlots:e._u([{key:"buttons",fn:function(){return[!e.isConnecting&&!e.connectingFailed?[e.dialogEditPrinter.bool?[t(g,{staticClass:"minwidth-0",attrs:{icon:"",tile:""},on:{click:function(r){e.dialogEditPrinter.bool=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]:e.dialogAddPrinter.bool?[e.dialogAddPrinter.bool?t(g,{staticClass:"minwidth-0",attrs:{icon:"",tile:""},on:{click:function(r){e.dialogAddPrinter.bool=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1):e._e()]:e.printers.length>0?[t(g,{staticClass:"minwidth-0",attrs:{icon:"",tile:"",color:"primary"},on:{click:e.checkPrinters}},[t(_,[e._v(e._s(e.mdiSync))])],1)]:e._e()]:e._e()]},proxy:!0}])},[e.isConnecting||e.isConnected&&!e.guiIsReady?[t(Z,[t(Ss,{attrs:{color:"primary",indeterminate:""}})],1)]:e.connectingFailed?[t(Z,[t("p",[e._v(" "+e._s(e.$t("SelectPrinterDialog.CannotConnectTo",{host:parseInt(e.port)!==80?e.hostname+":"+e.port:e.hostname}))+" ")]),t("div",{staticClass:"text-center"},[t(g,{staticClass:"mr-3",attrs:{text:"",color:"white"},on:{click:e.switchToChangePrinter}},[e._v(" "+e._s(e.$t("SelectPrinterDialog.ChangePrinter"))+" ")]),t(g,{attrs:{text:"",color:"primary"},on:{click:e.reconnect}},[e._v(e._s(e.$t("SelectPrinterDialog.TryAgain")))])],1)])]:e.dialogAddPrinter.bool?[t(or,{on:{submit:function(r){return r.preventDefault(),e.addPrinter.apply(null,arguments)}},model:{value:e.addPrinterValid,callback:function(r){e.addPrinterValid=r},expression:"addPrinterValid"}},[t(Z,[t(x,[t(b,{staticClass:"col-8"},[t(se,{attrs:{rules:[r=>!!r||e.$t("SelectPrinterDialog.HostnameRequired"),r=>!r.startsWith("http:")||e.$t("SelectPrinterDialog.HostnameInvalid"),r=>!r.startsWith("https:")||e.$t("SelectPrinterDialog.HostnameInvalid")],label:e.$t("SelectPrinterDialog.HostnameIp"),required:"",outlined:"","hide-details":"auto",dense:""},model:{value:e.dialogAddPrinter.hostname,callback:function(r){e.$set(e.dialogAddPrinter,"hostname",r)},expression:"dialogAddPrinter.hostname"}})],1),t(b,{staticClass:"col-4"},[t(se,{attrs:{rules:[r=>!!r||e.$t("SelectPrinterDialog.PortRequired")],label:e.$t("SelectPrinterDialog.Port"),"hide-details":"auto",required:"",outlined:"",dense:""},model:{value:e.dialogAddPrinter.port,callback:function(r){e.$set(e.dialogAddPrinter,"port",r)},expression:"dialogAddPrinter.port"}})],1)],1),e.showOptionalSettings?t(x,[t(b,{attrs:{cols:6}},[t(se,{attrs:{rules:[r=>!r||r.startsWith("/")||"Path must start with /"],label:e.$t("SelectPrinterDialog.Path"),"hide-details":"auto",outlined:"",dense:""},model:{value:e.dialogAddPrinter.path,callback:function(r){e.$set(e.dialogAddPrinter,"path",r)},expression:"dialogAddPrinter.path"}})],1),t(b,{attrs:{cols:6}},[t(se,{attrs:{label:e.$t("SelectPrinterDialog.Name"),outlined:"","hide-details":"auto",dense:""},model:{value:e.dialogAddPrinter.name,callback:function(r){e.$set(e.dialogAddPrinter,"name",r)},expression:"dialogAddPrinter.name"}})],1)],1):e._e()],1),t(oe,[t(ge,{staticClass:"ml-2",attrs:{"on-icon":e.mdiShowOptional,"off-icon":e.mdiHideOptional,"true-value":!1,"false-value":!0},model:{value:e.showOptionalSettings,callback:function(r){e.showOptionalSettings=r},expression:"showOptionalSettings"}}),t(ae),t(g,{staticClass:"middle",attrs:{color:"primary",text:"",type:"submit",disabled:!e.addPrinterValid}},[e._v(" "+e._s(e.$t("SelectPrinterDialog.AddPrinter"))+" ")])],1)],1)]:e.dialogEditPrinter.bool?[t(or,{on:{submit:function(r){return r.preventDefault(),e.updatePrinter.apply(null,arguments)}},model:{value:e.editPrinterValid,callback:function(r){e.editPrinterValid=r},expression:"editPrinterValid"}},[t(Z,[t(x,[t(b,{staticClass:"col-8"},[t(se,{attrs:{rules:[r=>!!r||e.$t("SelectPrinterDialog.HostnameRequired"),r=>!r.startsWith("http:")||e.$t("SelectPrinterDialog.HostnameInvalid"),r=>!r.startsWith("https:")||e.$t("SelectPrinterDialog.HostnameInvalid")],label:e.$t("SelectPrinterDialog.HostnameIp"),required:"",outlined:"",dense:"","hide-details":"auto"},model:{value:e.dialogEditPrinter.hostname,callback:function(r){e.$set(e.dialogEditPrinter,"hostname",r)},expression:"dialogEditPrinter.hostname"}})],1),t(b,{staticClass:"col-4"},[t(se,{attrs:{rules:[r=>!!r||e.$t("SelectPrinterDialog.PortRequired")],label:e.$t("SelectPrinterDialog.Port"),required:"",outlined:"",dense:"","hide-details":"auto"},model:{value:e.dialogEditPrinter.port,callback:function(r){e.$set(e.dialogEditPrinter,"port",r)},expression:"dialogEditPrinter.port"}})],1)],1),e.showOptionalSettings?t(x,[t(b,{attrs:{cols:6}},[t(se,{attrs:{rules:[r=>!r||r.startsWith("/")||"Path must start with /"],label:e.$t("SelectPrinterDialog.Path"),"hide-details":"auto",outlined:"",dense:""},model:{value:e.dialogEditPrinter.path,callback:function(r){e.$set(e.dialogEditPrinter,"path",r)},expression:"dialogEditPrinter.path"}})],1),t(b,{attrs:{cols:6}},[t(se,{attrs:{label:e.$t("SelectPrinterDialog.Name"),outlined:"","hide-details":"auto",dense:""},model:{value:e.dialogEditPrinter.name,callback:function(r){e.$set(e.dialogEditPrinter,"name",r)},expression:"dialogEditPrinter.name"}})],1)],1):e._e()],1),t(oe,[t(g,{staticClass:"minwidth-0 rounded",attrs:{color:"red",icon:"",tile:""},on:{click:e.delPrinter}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiDelete))])],1),t(ge,{staticClass:"ml-2",attrs:{"on-icon":e.mdiShowOptional,"off-icon":e.mdiHideOptional,"true-value":!1,"false-value":!0},model:{value:e.showOptionalSettings,callback:function(r){e.showOptionalSettings=r},expression:"showOptionalSettings"}}),t(ae),t(g,{attrs:{color:"primary",text:"",type:"submit",disabled:!e.editPrinterValid}},[e._v(" "+e._s(e.$t("SelectPrinterDialog.UpdatePrinter"))+" ")])],1)],1)]:[t(Z,{staticClass:"mt-3"},[e.printers.length?t(x,[t(b,{staticClass:"px-6"},e._l(e.printers,function(r,i){return t(x,{key:i},[t(b,{staticClass:"rounded transition-swing toolbar py-2 px-2 mb-2 overflow-hidden",staticStyle:{cursor:"pointer"},on:{click:function(n){return e.connect(r)}}},[t(x,{attrs:{align:"center"}},[t(b,{staticClass:"col-auto pr-0"},[r.socket.isConnecting?t(ot,{attrs:{indeterminate:"",color:"primary",size:"24",width:"2.5"}}):e._e(),r.socket.isConnecting?e._e():t(_,{attrs:{color:r.socket.isConnected?"green":"red"}},[e._v(" "+e._s(r.socket.isConnected?e.mdiCheckboxMarkedCircle:e.mdiCancel)+" ")])],1),t(b,[e._v(e._s(e.getPrinterName(r.id)))]),e.canAddPrinters?t(b,{staticClass:"col-auto pa-0"},[t(g,{staticClass:"mr-1",attrs:{tile:"",text:"",icon:"",large:""},on:{click:function(n){return n.stopPropagation(),n.preventDefault(),e.editPrinter(r)}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiPencil))])],1)],1):e._e()],1)],1)],1)}),1)],1):e._e(),e.instancesDB==="browser"?[e.showCorsInfo?t(x,[t(b,[e.printers.length===0?t("p",{staticClass:"text-center"},[e._v(" "+e._s(e.$t("SelectPrinterDialog.Hello"))+" ")]):e._e(),t("p",{staticClass:"text-center"},[e._v(" "+e._s(e.$t("SelectPrinterDialog.RememberToAdd",{cors:e.currentUrl}))+" ")]),t("p",{staticClass:"text-center mb-0"},[e._v(" "+e._s(e.$t("SelectPrinterDialog.YouCanFindMore"))+" "),t("br"),t("a",{attrs:{href:"https://docs.mainsail.xyz/remotemode",target:"_blank"}},[e._v(" https://docs.mainsail.xyz/remotemode ")]),e._v(" . ")])])],1):e._e(),t(x,[t(b,{staticClass:"text-center mt-0"},[t(g,{attrs:{text:"",color:"primary"},on:{click:e.createPrinter}},[e._v(" "+e._s(e.$t("SelectPrinterDialog.AddPrinter"))+" ")])],1)],1)]:e.instancesDB==="json"&&e.printers.length===0?t(x,[t(b,{staticClass:"text-center mt-0"},[t("p",{staticClass:"text-center"},[e._v(" "+e._s(e.$t("SelectPrinterDialog.AddPrintersToJson"))+" ")])])],1):e._e()],2)]],2)],1)},JS=[],KS=E(fm,YS,JS,!1,null,null);const Kp=KS.exports;var QS=Object.defineProperty,eP=Object.getOwnPropertyDescriptor,Lv=(s,e,t,r)=>{for(var i=r>1?void 0:r?eP(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&QS(e,t,i),i};let ul=class extends k(L){get splits(){return this.event.message.split("|")}get text(){return this.splits[0]}get command(){var s;return(s=this.splits[1])!=null?s:this.text}get color(){var s;return(s=this.splits[2])!=null?s:""}clickButton(){this.$store.dispatch("server/addEvent",{message:this.command,type:"command"}),this.$socket.emit("printer.gcode.script",{script:this.command})}};Lv([w({type:Object,required:!0})],ul.prototype,"event",2);ul=Lv([S({})],ul);var tP=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(g,{attrs:{color:e.color,text:""},on:{click:e.clickButton}},[e._v(" "+e._s(e.text)+" ")])},sP=[],rP=E(ul,tP,sP,!1,null,"ece2d321");const Av=rP.exports;var iP=Object.defineProperty,nP=Object.getOwnPropertyDescriptor,Fv=(s,e,t,r)=>{for(var i=r>1?void 0:r?nP(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&iP(e,t,i),i};let dl=class extends k(L){get splits(){return this.event.message.split("|")}get text(){return this.splits[0]}get command(){var e;return(e=this.splits[1])!=null?e:this.text}get color(){var e;return(e=this.splits[2])!=null?e:""}sendCommand(){this.$store.dispatch("server/addEvent",{message:this.command,type:"command"}),this.$socket.emit("printer.gcode.script",{script:this.command})}};Fv([w({type:Object,required:!0})],dl.prototype,"event",2);dl=Fv([S({})],dl);var aP=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(g,{staticClass:"mx-2",attrs:{color:e.color},on:{click:e.sendCommand}},[e._v(e._s(e.text))])},oP=[],lP=E(dl,aP,oP,!1,null,null);const Rv=lP.exports;var cP=Object.defineProperty,uP=Object.getOwnPropertyDescriptor,Qp=(s,e,t,r)=>{for(var i=r>1?void 0:r?uP(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&cP(e,t,i),i};let ea=class extends k(L){};Qp([w({type:Array,required:!0})],ea.prototype,"children",2);Qp([w({type:Number,required:!0})],ea.prototype,"groupIndex",2);ea=Qp([S({})],ea);var dP=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,[t(b,{staticClass:"text-center"},e._l(e.children,function(r,i){return t(Rv,{key:"prompt_"+e.groupIndex+"_"+i,attrs:{event:r}})}),1)],1)},mP=[],hP=E(ea,dP,mP,!1,null,null);const gm=hP.exports;var pP=Object.defineProperty,fP=Object.getOwnPropertyDescriptor,Hv=(s,e,t,r)=>{for(var i=r>1?void 0:r?fP(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&pP(e,t,i),i};let ml=class extends k(L){get text(){return this.event.message}};Hv([w({type:Object,required:!0})],ml.prototype,"event",2);ml=Hv([S({})],ml);var gP=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,[t(b,[t("p",{staticClass:"mb-0"},[e._v(e._s(e.text))])])],1)},_P=[],vP=E(ml,gP,_P,!1,null,null);const jv=vP.exports;var bP=Object.getOwnPropertyDescriptor,yP=(s,e,t,r)=>{for(var i=r>1?void 0:r?bP(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let _m=class extends k(L){constructor(){super(...arguments),this.mdiInformation=Ht,this.mdiCloseThick=pe,this.internalCloseCommand=null,this.checkpointEvent=null,this.currentPrompt=[],this.promptMessageExp=/^\/\/ action:prompt_(?<type>[^\s]+) *(?<msg>.*)$/}get events(){return this.$store.state.server.events}get macroPromptEvents(){var t,r,i,n;const s=this.events,e=[];for(let a=s.length-1;a>=0;a--){const o=s[a];if(o===this.checkpointEvent)break;if(o.type!=="action"||!((t=o.message)!=null&&t.startsWith("// action:prompt_")))continue;const l=o.message.match(this.promptMessageExp),u=(i=(r=l==null?void 0:l.groups)==null?void 0:r.type)!=null?i:"";if(u==="end"){this.currentPrompt=[];break}const c=(((n=l==null?void 0:l.groups)==null?void 0:n.msg)||"").trim();if(e.unshift({date:o.date,type:u,message:c}),u==="begin"){this.currentPrompt=[];break}}return this.checkpointEvent=s[s.length-1],e.length>0&&(this.currentPrompt=[...this.currentPrompt,...e]),this.currentPrompt}get lastPromptBeginPos(){return this.lastPromptShowPos===-1?-1:this.macroPromptEvents.findLastIndex(s=>s.type==="begin",this.lastPromptShowPos)}get lastPromptShowPos(){return this.macroPromptEvents.findLastIndex(s=>s.type==="show")}get lastPromptClosePos(){return this.macroPromptEvents.findLastIndex(s=>s.type==="end")}get showDialog(){var e,t,r;if(this.lastPromptBeginPos===-1)return!1;const s=(e=this.macroPromptEvents[this.lastPromptBeginPos])!=null?e:null;return this.internalCloseCommand!==null&&this.internalCloseCommand==((r=(t=s==null?void 0:s.date)==null?void 0:t.getTime())!=null?r:null)?!1:this.lastPromptBeginPos>this.lastPromptClosePos&&this.activePromptContent.length>0}get activePrompt(){return this.lastPromptShowPos===-1?[]:this.macroPromptEvents.slice(this.lastPromptBeginPos,this.lastPromptShowPos)}get activePromptContent(){const s=["button","text","button_group_start","button_group_end"],e=this.activePrompt.filter(t=>s.includes(t.type));for(;e.findIndex(t=>t.type==="button_group_start")!==-1&&e.findIndex(t=>t.type==="button_group_end")!==-1;){const t=e.findIndex(n=>n.type==="button_group_start"),r=e.findIndex(n=>n.type==="button_group_end"),i=e.slice(t+1,r);e[t]={date:i[0].date,type:"button_group",message:"",children:i.filter(n=>n.type==="button")},e.splice(t+1,i.length+1)}return e}get headline(){var s,e;return!this.showDialog||this.lastPromptBeginPos===-1?"":(e=(s=this.macroPromptEvents[this.lastPromptBeginPos])==null?void 0:s.message)!=null?e:""}get footerButtons(){return!this.showDialog||this.lastPromptBeginPos===-1?[]:this.activePrompt.filter(s=>s.type==="footer_button")}closePrompt(){var e,t,r;this.internalCloseCommand=(r=(t=(e=this.macroPromptEvents[this.lastPromptBeginPos])==null?void 0:e.date)==null?void 0:t.getTime())!=null?r:null;const s='RESPOND type="command" msg="action:prompt_end"';this.$store.dispatch("server/addEvent",{message:s,type:"command"}),this.$socket.emit("printer.gcode.script",{script:s})}};_m=yP([S({components:{MacroPromptButtonGroup:gm,MacroPromptButton:Rv,MacroPromptText:jv,MacroPromptFooterButton:Av,Panel:U}})],_m);var CP=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.showDialog,width:"400",persistent:"",fullscreen:e.isMobile}},[t(U,{staticStyle:{overflow:"hidden"},attrs:{title:e.headline,icon:e.mdiInformation,"card-class":"macro_prompt-dialog","margin-bottom":!1,height:e.isMobile?0:548},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closePrompt}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[e._l(e.activePromptContent,function(r,i){var n;return[r.type==="text"?t(jv,{key:"prompt_"+i,attrs:{event:r}}):e._e(),r.type==="button_group"?t(gm,{key:"prompt_"+i,attrs:{"group-index":i,children:(n=r.children)!=null?n:[]}}):e._e(),r.type==="button"?t(gm,{key:"prompt_"+i,attrs:{"group-index":i,children:[r]}}):e._e()]})],2),e.footerButtons.length?t(oe,[t(ae),e._l(e.footerButtons,function(r,i){return t(Av,{key:"prompt_footer_"+i,attrs:{event:r}})})],2):e._e()],1)],1)},$P=[],xP=E(_m,CP,$P,!1,null,"473b6448");const Iv=xP.exports;var wP=Object.defineProperty,SP=Object.getOwnPropertyDescriptor,ei=(s,e,t,r)=>{for(var i=r>1?void 0:r?SP(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&wP(e,t,i),i};let js=class extends k(L){get firstColClasses(){const s=" d-flex justify-center";return this.dynamicSlotWidth?"col"+s:this.mobileSecondRow?"col-12 col-md-6"+s:"col-6"+s}get secondColClasses(){const s=" d-flex justify-end align-center settings-row-slot";return this.dynamicSlotWidth?"col-auto"+s:this.mobileSecondRow?"col-12 col-md-6 pt-0 pt-md-3"+s:"col-6"+s}};ei([w({required:!1,default:!1})],js.prototype,"loading",2);ei([w({required:!1,default:""})],js.prototype,"icon",2);ei([w({required:!0})],js.prototype,"title",2);ei([w({required:!1})],js.prototype,"subTitle",2);ei([w({required:!1,default:!1})],js.prototype,"dynamicSlotWidth",2);ei([w({required:!1,default:!1})],js.prototype,"mobileSecondRow",2);js=ei([S],js);var PP=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,[t(b,{class:e.firstColClasses},[t(x,{staticClass:"d-flex flex-row"},[e.loading?t(b,{staticClass:"col-auto d-flex justify-center align-center pr-0"},[t(ot,{attrs:{indeterminate:"",color:"primary",size:24}})],1):e.icon?t(b,{staticClass:"col-auto d-flex justify-center align-center pr-0"},[t(_,[e._v(e._s(e.icon))])],1):e._e(),t(b,{staticClass:"col d-flex justify-center flex-column"},[t("span",{staticClass:"settings-row-title"},[e._v(e._s(e.title))]),e.subTitle?t("span",{staticClass:"settings-row-subtitle"},[e._v(e._s(e.subTitle))]):e._e()])],1)],1),t(b,{class:e.secondColClasses},[e._t("default")],2)],1)},DP=[],TP=E(js,PP,DP,!1,null,"c095664a");const j=TP.exports;var Nv="Expected a function",Ug=NaN,OP="[object Symbol]",MP=/^\s+|\s+$/g,kP=/^[-+]0x[0-9a-f]+$/i,EP=/^0b[01]+$/i,LP=/^0o[0-7]+$/i,AP=parseInt,FP=typeof Tr=="object"&&Tr&&Tr.Object===Object&&Tr,RP=typeof self=="object"&&self&&self.Object===Object&&self,HP=FP||RP||Function("return this")(),jP=Object.prototype,IP=jP.toString,NP=Math.max,VP=Math.min,Md=function(){return HP.Date.now()};function BP(s,e,t){var r,i,n,a,o,l,u=0,c=!1,d=!1,m=!0;if(typeof s!="function")throw new TypeError(Nv);e=Wg(e)||0,hl(t)&&(c=!!t.leading,d="maxWait"in t,n=d?NP(Wg(t.maxWait)||0,e):n,m="trailing"in t?!!t.trailing:m);function h($){var D=r,V=i;return r=i=void 0,u=$,a=s.apply(V,D),a}function f($){return u=$,o=setTimeout(C,e),c?h($):a}function p($){var D=$-l,V=$-u,N=e-D;return d?VP(N,n-V):N}function v($){var D=$-l,V=$-u;return l===void 0||D>=e||D<0||d&&V>=n}function C(){var $=Md();if(v($))return P($);o=setTimeout(C,p($))}function P($){return o=void 0,m&&r?h($):(r=i=void 0,a)}function M(){o!==void 0&&clearTimeout(o),u=0,r=l=i=o=void 0}function F(){return o===void 0?a:P(Md())}function O(){var $=Md(),D=v($);if(r=arguments,i=this,l=$,D){if(o===void 0)return f(l);if(d)return o=setTimeout(C,e),h(l)}return o===void 0&&(o=setTimeout(C,e)),a}return O.cancel=M,O.flush=F,O}function UP(s,e,t){var r=!0,i=!0;if(typeof s!="function")throw new TypeError(Nv);return hl(t)&&(r="leading"in t?!!t.leading:r,i="trailing"in t?!!t.trailing:i),BP(s,e,{leading:r,maxWait:e,trailing:i})}function hl(s){var e=typeof s;return!!s&&(e=="object"||e=="function")}function WP(s){return!!s&&typeof s=="object"}function zP(s){return typeof s=="symbol"||WP(s)&&IP.call(s)==OP}function Wg(s){if(typeof s=="number")return s;if(zP(s))return Ug;if(hl(s)){var e=typeof s.valueOf=="function"?s.valueOf():s;s=hl(e)?e+"":e}if(typeof s!="string")return s===0?s:+s;s=s.replace(MP,"");var t=EP.test(s);return t||LP.test(s)?AP(s.slice(2),t?2:8):kP.test(s)?Ug:+s}var GP=UP;const Vv=en(GP);var ZP=Object.defineProperty,qP=Object.getOwnPropertyDescriptor,Bv=(s,e,t,r)=>{for(var i=r>1?void 0:r?qP(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&ZP(e,t,i),i};let pl=class extends L{constructor(){super(...arguments),this.el={is:{}}}mounted(){this.breakpoints&&this.$nextTick(()=>{this.observer=new ResizeObserver(Vv(this.onResize,50)),this.$el instanceof Element&&this.observer.observe(this.$el)})}beforeDestroy(){var s;this.$el instanceof Element&&((s=this.observer)==null||s.unobserve(this.$el))}onResize(s){if(s[0].contentRect.height===0&&s[0].contentRect.width===0)return;const e=s[0].contentRect,t=this.breakpoints;for(const r in t)this.$set(this.el.is,r,t[r](e))}};Bv([w()],pl.prototype,"breakpoints",2);pl=Bv([S],pl);var XP=Object.defineProperty,YP=Object.getOwnPropertyDescriptor,Uv=(s,e,t,r)=>{for(var i=r>1?void 0:r?YP(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&XP(e,t,i),i};let fl=class extends k(pl){constructor(){super(...arguments),this.init=!1}mounted(){this.init=!0}};Uv([w({default:!1})],fl.prototype,"noHide",2);fl=Uv([S],fl);var JP=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[!e.noHide&&!e.init?t("div",{staticStyle:{visibility:"hidden"}},[e._t("default",null,{el:e.el})],2):e._e(),e._t("default",null,{el:e.el})],2)},KP=[],QP=E(fl,JP,KP,!1,null,null);const tt=QP.exports;var e3=Object.getOwnPropertyDescriptor,t3=(s,e,t,r)=>{for(var i=r>1?void 0:r?e3(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Je=class extends y{get absolute_coordinates(){var s,e,t;return(t=(e=(s=this.$store.state.printer)==null?void 0:s.gcode_move)==null?void 0:e.absolute_coordinates)!=null?t:!0}get enableXYHoming(){return this.$store.state.gui.control.enableXYHoming}get feedrateXY(){var s,e;return(e=(s=this.$store.state.gui.control)==null?void 0:s.feedrateXY)!=null?e:100}get feedrateZ(){var s,e;return(e=(s=this.$store.state.gui.control)==null?void 0:s.feedrateZ)!=null?e:10}get existsQGL(){return this.$store.getters["printer/existsQGL"]}get existsZtilt(){return this.$store.getters["printer/existsZtilt"]}get existsBedTilt(){return this.$store.getters["printer/existsBedTilt"]}get existsBedScrews(){return this.$store.getters["printer/existsBedScrews"]}get existsDeltaCalibrate(){return this.$store.getters["printer/existsDeltaCalibrate"]}get existsScrewsTilt(){return this.$store.getters["printer/existsScrewsTilt"]}get existsFirmwareRetraction(){return this.$store.getters["printer/existsFirmwareRetraction"]}get colorQuadGantryLevel(){var e,t;return((t=(e=this.$store.state.printer.quad_gantry_level)==null?void 0:e.applied)!=null?t:!0)?"primary":"warning"}get colorZTilt(){var e,t;let s=!0;return"z_tilt"in this.$store.state.printer?s=(e=this.$store.state.printer.z_tilt)==null?void 0:e.applied:"z_tilt_ng"in this.$store.state.printer&&(s=(t=this.$store.state.printer.z_tilt_ng)==null?void 0:t.applied),s?"primary":"warning"}get defaultActionButton(){return this.$store.getters["gui/getDefaultControlActionButton"]}get actionButton(){var e;const s=(e=this.$store.state.gui.control.actionButton)!=null?e:this.defaultActionButton;return s==="qgl"&&!this.$store.getters["printer/existsQGL"]||s==="ztilt"&&!this.$store.getters["printer/existsZTilt"]?this.defaultActionButton:s}get homedAxes(){var s,e,t;return(t=(e=(s=this.$store.state.printer)==null?void 0:s.toolhead)==null?void 0:e.homed_axes)!=null?t:""}get xAxisHomed(){return this.homedAxes.includes("x")}get yAxisHomed(){return this.homedAxes.includes("y")}get zAxisHomed(){return this.homedAxes.includes("z")}get macros(){return this.$store.getters["printer/getMacros"]}get toolchangeMacros(){var t,r;const s=(i,n)=>{const a=parseInt(i.slice(1)),o=parseInt(n.slice(1));return a-o},e=(r=(t=this.$store.state.printer.gcode)==null?void 0:t.commands)!=null?r:null;return e?Object.keys(e).filter(i=>i.match(/^T\d+/)).sort(s):Object.keys(this.$store.state.printer).filter(i=>i.toLowerCase().match(/^gcode_macro t\d+/)).map(i=>i.slice(i.indexOf(" ")+1)).sort(s)}get existsClientLinearMoveMacro(){var e,t,r;return"_CLIENT_LINEAR_MOVE"in((r=(t=(e=this.$store.state.printer)==null?void 0:e.gcode)==null?void 0:t.commands)!=null?r:{})}doHome(){this.$store.dispatch("server/addEvent",{message:"G28",type:"command"}),this.$socket.emit("printer.gcode.script",{script:"G28"},{loading:"homeAll"})}doHomeX(){this.$store.dispatch("server/addEvent",{message:"G28 X",type:"command"}),this.$socket.emit("printer.gcode.script",{script:"G28 X"},{loading:"homeX"})}doHomeY(){this.$store.dispatch("server/addEvent",{message:"G28 Y",type:"command"}),this.$socket.emit("printer.gcode.script",{script:"G28 Y"},{loading:"homeY"})}doHomeXY(){this.$store.dispatch("server/addEvent",{message:"G28 X Y",type:"command"}),this.$socket.emit("printer.gcode.script",{script:"G28 X Y"},{loading:"homeXY"})}doHomeZ(){this.$store.dispatch("server/addEvent",{message:"G28 Z",type:"command"}),this.$socket.emit("printer.gcode.script",{script:"G28 Z"},{loading:"homeZ"})}doQGL(){this.$store.dispatch("server/addEvent",{message:"QUAD_GANTRY_LEVEL",type:"command"}),this.$socket.emit("printer.gcode.script",{script:"QUAD_GANTRY_LEVEL"},{loading:"qgl"})}doZtilt(){this.$store.dispatch("server/addEvent",{message:"Z_TILT_ADJUST",type:"command"}),this.$socket.emit("printer.gcode.script",{script:"Z_TILT_ADJUST"},{loading:"zTilt"})}doSendMove(s,e){let t="SAVE_GCODE_STATE NAME=_ui_movement\nG91\nG1 ".concat(s," F").concat(e*60,"\nRESTORE_GCODE_STATE NAME=_ui_movement");this.existsClientLinearMoveMacro&&(s=s.split(" ").map(r=>{const i=r.slice(0,1),n=parseFloat(r.slice(1));return"".concat(i,"=").concat(n)}).join(" "),t="_CLIENT_LINEAR_MOVE ".concat(s," F=").concat(e*60)),this.doSend(t)}doSend(s){this.$store.dispatch("server/addEvent",{message:s,type:"command"}),this.$socket.emit("printer.gcode.script",{script:s})}};Je=t3([S],Je);var s3=Object.defineProperty,r3=Object.getOwnPropertyDescriptor,ef=(s,e,t,r)=>{for(var i=r>1?void 0:r?r3(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&s3(e,t,i),i};let ta=class extends k(L,Je){constructor(){super(...arguments),this.mdiRotateLeft=CS,this.mdiCloseThick=pe,this.mdiRotateRight=$S}get settings(){var s,e,t;return(t=(e=(s=this.$store.state.printer.configfile)==null?void 0:s.settings)==null?void 0:e.screws_tilt_adjust)!=null?t:{}}get outputName(){var s;return(s=this.settings[this.name+"_name"])!=null?s:"Unknown"}get coordinates(){var s;return(s=this.settings[this.name])!=null?s:[0,0]}get x(){var s;return(s=this.coordinates[0])!=null?s:0}get y(){var s;return(s=this.coordinates[1])!=null?s:0}get z(){return this.result.z.toFixed(3)}get subTitle(){return"(X: ".concat(this.x,", Y: ").concat(this.y,", Z: ").concat(this.z,")")}get sign(){var s;return(s=this.result.sign)!=null?s:""}get adjust(){var s;return(s=this.result.adjust)!=null?s:"00:00"}get is_base(){var s;return(s=this.result.is_base)!=null?s:!1}};ef([w({required:!0})],ta.prototype,"name",2);ef([w({required:!0})],ta.prototype,"result",2);ta=ef([S({components:{Panel:U,Responsive:tt,SettingsRow:j}})],ta);var i3=function(){var r;var e=this,t=e._self._c;return e._self._setupProxy,t(j,{attrs:{title:e.outputName,"sub-title":e.subTitle}},[(r=e.is_base)!=null&&r?t($s,{attrs:{label:"",small:""}},[e._v(e._s(e.$t("ScrewsTiltAdjust.Base")))]):t($s,{attrs:{label:"",small:""}},[e.sign==="CCW"?t(_,{attrs:{small:"",left:""}},[e._v(e._s(e.mdiRotateLeft))]):e._e(),e.sign==="CW"?t(_,{attrs:{small:"",left:""}},[e._v(e._s(e.mdiRotateRight))]):e._e(),e._v(" "+e._s(e.adjust)+" ")],1)],1)},n3=[],a3=E(ta,i3,n3,!1,null,null);const Wv=a3.exports;var o3=Object.getOwnPropertyDescriptor,l3=(s,e,t,r)=>{for(var i=r>1?void 0:r?o3(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let vm=class extends k(L,Je){constructor(){super(...arguments),this.mdiArrowCollapseDown=cu,this.mdiCloseThick=pe}get state(){var s;return(s=this.$store.state.printer.screws_tilt_adjust)!=null?s:{}}get error(){var s,e;return(e=(s=this.$store.state.printer.screws_tilt_adjust)==null?void 0:s.error)!=null?e:!1}get max_deviation(){var s,e;return(e=(s=this.$store.state.printer.screws_tilt_adjust)==null?void 0:s.max_deviation)!=null?e:null}get results(){var s,e;return(e=(s=this.$store.state.printer.screws_tilt_adjust)==null?void 0:s.results)!=null?e:{}}get showDialog(){return!this.boolScrewsTiltAdjustDialog||this.max_deviation!==null?!1:this.error||Object.keys(this.results).length}get boolScrewsTiltAdjustDialog(){var s;return(s=this.$store.state.gui.uiSettings.boolScrewsTiltAdjustDialog)!=null?s:!0}clearScrewsTiltAdjust(){this.$store.dispatch("printer/clearScrewsTiltAdjust")}async retryScrewsTiltAdjust(){var t,r;const e=[...(t=this.$store.state.server.events)!=null?t:[]].reverse().find(i=>i.type==="command"&&i.message.startsWith("SCREWS_TILT_CALCULATE"));await this.$store.dispatch("printer/clearScrewsTiltAdjust"),this.doSend((r=e==null?void 0:e.message)!=null?r:"SCREWS_TILT_CALCULATE")}};vm=l3([S({components:{TheScrewsTiltAdjustDialogEntry:Wv,Panel:U,Responsive:tt,SettingsRow:j}})],vm);var c3=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.showDialog,width:"400",persistent:"",fullscreen:e.isMobile}},[t(U,{staticStyle:{overflow:"hidden"},attrs:{title:e.$t("ScrewsTiltAdjust.Headline"),icon:e.mdiArrowCollapseDown,"card-class":"manual_probe-dialog","margin-bottom":!1,height:e.isMobile?0:548},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.clearScrewsTiltAdjust}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[e.error?t(Z,[t(x,[t(b,[t(it,{attrs:{border:"left",text:"",type:"error"}},[e._v(e._s(e.$t("ScrewsTiltAdjust.ErrorText")))])],1)],1)],1):e._e(),Object.keys(e.results).length?t(Z,[e._l(e.results,function(r,i,n){return[n?t(I,{key:"result-divider-".concat(i),staticClass:"my-1"}):e._e(),t(Wv,{key:"result-".concat(i,"-").concat(i),attrs:{name:i.toString(),result:r}})]})],2):e._e(),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.retryScrewsTiltAdjust}},[e._v(" "+e._s(e.$t("ScrewsTiltAdjust.Retry"))+" ")]),t(g,{attrs:{color:"primary",text:""},on:{click:e.clearScrewsTiltAdjust}},[e._v(" "+e._s(e.$t("ScrewsTiltAdjust.Accept"))+" ")])],1)],1)],1)},u3=[],d3=E(vm,c3,u3,!1,null,null);const zv=d3.exports;var m3=Object.getOwnPropertyDescriptor,h3=(s,e,t,r)=>{for(var i=r>1?void 0:r?m3(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let bm=class extends k(L,Je){constructor(){super(...arguments),this.mdiArrowCollapseDown=cu,this.mdiInformation=Ht,this.mdiCloseThick=pe}get showDialog(){var e,t;return this.boolBedScrewsDialog?((t=(e=this.$store.state.printer.bed_screws)==null?void 0:e.is_active)!=null?t:!1)&&this.homedAxes.includes("xyz"):!1}get boolBedScrewsDialog(){var s;return(s=this.$store.state.gui.uiSettings.boolBedScrewsDialog)!=null?s:!0}get config(){var s,e,t;return(t=(e=(s=this.$store.state.printer.configfile)==null?void 0:s.settings)==null?void 0:e.bed_screws)!=null?t:{}}get bed_screws_state(){var s;return(s=this.$store.state.printer.bed_screws)==null?void 0:s.state}get current_screw(){var s;return(s=this.$store.state.printer.bed_screws)==null?void 0:s.current_screw}get accepted_screws(){var s;return(s=this.$store.state.printer.bed_screws)==null?void 0:s.accepted_screws}get loadingAbort(){return this.loadings.includes("bedScrewsAbort")}get loadingAccept(){return this.loadings.includes("bedScrewsAccept")}get loadingAdjusted(){return this.loadings.includes("bedScrewsAdjusted")}get screwNames(){const e=Object.keys(this.config).filter(r=>r.startsWith("screw")&&r.endsWith("_name")),t=[];return e==null||e.forEach(r=>{var a;const i=r.indexOf("_"),n=parseInt(r.slice(5,i));t[n-1]=(a=this.config["screw".concat(n,"_name")])!=null?a:""}),t}get countScrews(){return this.screwNames.length}get currentScrewName(){var s;return(s=this.screwNames[this.current_screw])!=null?s:"UNKNOWN"}get currentScrewOutput(){return this.$t("BedScrews.ScrewOutput",{current:this.current_screw,max:this.countScrews})}get acceptedScrewOutput(){return this.$t("BedScrews.ScrewOutput",{current:this.accepted_screws,max:this.countScrews})}sendAbort(){const s="ABORT";this.$store.dispatch("server/addEvent",{message:s,type:"command"}),this.$socket.emit("printer.gcode.script",{script:s},{loading:"manualProbeAbort"})}sendAccept(){const s="ACCEPT";this.$store.dispatch("server/addEvent",{message:s,type:"command"}),this.$socket.emit("printer.gcode.script",{script:s},{loading:"manualProbeAccept"})}sendAdjusted(){const s="ADJUSTED";this.$store.dispatch("server/addEvent",{message:s,type:"command"}),this.$socket.emit("printer.gcode.script",{script:s},{loading:"manualProbeAccept"})}};bm=h3([S({components:{Panel:U,Responsive:tt}})],bm);var p3=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.showDialog,width:"400",persistent:"",fullscreen:e.isMobile}},[t(U,{staticStyle:{overflow:"hidden"},attrs:{title:e.$t("BedScrews.Headline").toString(),icon:e.mdiArrowCollapseDown,"card-class":"manual_probe-dialog","margin-bottom":!1,height:e.isMobile?0:548},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.sendAbort}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(x,[t(b,[t(se,{attrs:{label:e.$t("BedScrews.ScrewName"),outlined:"",dense:"",clearable:"","hide-details":""},model:{value:e.currentScrewName,callback:function(r){e.currentScrewName=r},expression:"currentScrewName"}})],1)],1),t(x,[t(b,{attrs:{cols:"6"}},[t(se,{attrs:{label:e.$t("BedScrews.ScrewIndex"),outlined:"",dense:"",clearable:"","hide-details":""},model:{value:e.currentScrewOutput,callback:function(r){e.currentScrewOutput=r},expression:"currentScrewOutput"}})],1),t(b,{attrs:{cols:"6"}},[t(se,{attrs:{label:e.$t("BedScrews.ScrewAccepted"),outlined:"",dense:"",clearable:"","hide-details":""},model:{value:e.acceptedScrewOutput,callback:function(r){e.acceptedScrewOutput=r},expression:"acceptedScrewOutput"}})],1)],1),t(x,[t(b,[t("p",{staticClass:"text-center mb-0",domProps:{innerHTML:e._s(e.$t("BedScrews.Description"))}})])],1)],1),t(oe,[t(ae),t(g,{attrs:{text:"",loading:e.loadingAbort},on:{click:e.sendAbort}},[e._v(" "+e._s(e.$t("BedScrews.Abort"))+" ")]),t(g,{attrs:{color:"primary",text:"",loading:e.loadingAdjusted},on:{click:e.sendAdjusted}},[e._v(" "+e._s(e.$t("BedScrews.Adjusted"))+" ")]),t(g,{attrs:{color:"primary",text:"",loading:e.loadingAccept},on:{click:e.sendAccept}},[e._v(" "+e._s(e.$t("BedScrews.Accept"))+" ")])],1)],1)],1)},f3=[],g3=E(bm,p3,f3,!1,null,"8e6140c4");const Gv=g3.exports;var _3=Object.defineProperty,v3=Object.getOwnPropertyDescriptor,Ya=(s,e,t,r)=>{for(var i=r>1?void 0:r?v3(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&_3(e,t,i),i};let Nr=class extends k(L){get expand(){return this.$store.getters["gui/getPanelExpand"](this.subPanelClass,this.viewport)}set expand(s){this.$store.dispatch("gui/saveExpandPanel",{name:this.subPanelClass,value:s,viewport:this.viewport})}};Ya([w({required:!1,default:fr})],Nr.prototype,"iconExpanded",2);Ya([w({required:!1,default:fr})],Nr.prototype,"iconCollapsed",2);Ya([w({required:!0,default:""})],Nr.prototype,"title",2);Ya([w({required:!0})],Nr.prototype,"subPanelClass",2);Nr=Ya([S],Nr);var b3=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t("div",{staticClass:"px-3 d-flex align-center"},[t(g,{staticClass:"px-0 btn-collapsible",attrs:{plain:"",small:"",ripple:!1},on:{click:function(r){e.expand=!e.expand}}},[t(_,{class:e.expand?"":"icon-rotate-n90",attrs:{small:""}},[e._v(" "+e._s(e.expand?e.iconExpanded:e.iconCollapsed)+" ")]),t("span",{staticClass:"pl-1"},[e._v(e._s(e.title))])],1),t(I,{staticClass:"ml-3"})],1),t(iu,[t("div",{directives:[{name:"show",rawName:"v-show",value:e.expand,expression:"expand"}]},[e._t("default")],2)])],1)},y3=[],C3=E(Nr,b3,y3,!1,null,"fed68b4f");const $3=C3.exports;var x3=Object.getOwnPropertyDescriptor,w3=(s,e,t,r)=>{for(var i=r>1?void 0:r?x3(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let ym=class extends k(L){constructor(){super(...arguments),this.mdiArrowCollapseDown=cu,this.mdiArrowExpandUp=z_,this.mdiInformation=Ht,this.mdiPlusThick=mS,this.mdiMinusThick=nS,this.mdiChevronTripleLeft=Dw,this.mdiChevronTripleRight=Tw,this.mdiCloseThick=pe}get showDialog(){var s,e;return this.boolManualProbeDialog&&(e=(s=this.$store.state.printer.manual_probe)==null?void 0:s.is_active)!=null?e:!1}get boolManualProbeDialog(){var s;return(s=this.$store.state.gui.uiSettings.boolManualProbeDialog)!=null?s:!0}get offsetsZ(){return[1,.1,.05,.01,.005].sort()}get z_position(){var s,e;return((e=(s=this.$store.state.printer.manual_probe)==null?void 0:s.z_position)!=null?e:0).toFixed(3)}get z_position_lower(){var e,t;const s=(t=(e=this.$store.state.printer.manual_probe)==null?void 0:e.z_position_lower)!=null?t:null;return s===null?"??????":s.toFixed(3)}get z_position_upper(){var e,t;const s=(t=(e=this.$store.state.printer.manual_probe)==null?void 0:e.z_position_upper)!=null?t:null;return s===null?"??????":s.toFixed(3)}get loadingAbort(){return this.loadings.includes("manualProbeAbort")}get loadingAccept(){return this.loadings.includes("manualProbeAccept")}sendTestZ(s){const e="TESTZ Z=".concat(s);this.$store.dispatch("server/addEvent",{message:e,type:"command"}),this.$socket.emit("printer.gcode.script",{script:e})}sendAbort(){const s="ABORT";this.$store.dispatch("server/addEvent",{message:s,type:"command"}),this.$socket.emit("printer.gcode.script",{script:s},{loading:"manualProbeAbort"})}sendAccept(){const s="ACCEPT";this.$store.dispatch("server/addEvent",{message:s,type:"command"}),this.$socket.emit("printer.gcode.script",{script:s},{loading:"manualProbeAccept"})}};ym=w3([S({components:{Panel:U,Responsive:tt}})],ym);var S3=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.showDialog,width:"400",persistent:"",fullscreen:e.isMobile}},[t(U,{staticStyle:{overflow:"hidden"},attrs:{title:e.$t("ManualProbe.Headline").toString(),icon:e.mdiArrowCollapseDown,"card-class":"manual_probe-dialog","margin-bottom":!1,height:e.isMobile?0:548},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.sendAbort}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Ee,[t(x,[t(b,{staticClass:"d-flex align-center justify-center"},[t("span",{staticClass:"text-h5"},[e._v(e._s(e.z_position_lower))]),t(_,{staticClass:"mx-2"},[e._v(e._s(e.mdiChevronTripleRight))]),t("span",{staticClass:"text-h4"},[e._v(e._s(e.z_position))]),t(_,{staticClass:"mx-2"},[e._v(e._s(e.mdiChevronTripleLeft))]),t("span",{staticClass:"text-h5"},[e._v(e._s(e.z_position_upper))])],1)],1),t(x,[t(b,{staticClass:"text-left"},[t(g,{attrs:{color:"primary"},on:{click:function(r){return e.sendTestZ("--")}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiMinusThick))]),t(_,{attrs:{small:""}},[e._v(e._s(e.mdiMinusThick))])],1)],1),t(b,{staticClass:"text-left"},[t(g,{attrs:{color:"primary"},on:{click:function(r){return e.sendTestZ("-")}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiMinusThick))])],1)],1),t(b,{staticClass:"text-right"},[t(g,{attrs:{color:"primary"},on:{click:function(r){return e.sendTestZ("+")}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiPlusThick))])],1)],1),t(b,{staticClass:"text-right"},[t(g,{attrs:{color:"primary"},on:{click:function(r){return e.sendTestZ("++")}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiPlusThick))]),t(_,{attrs:{small:""}},[e._v(e._s(e.mdiPlusThick))])],1)],1)],1)],1),t($3,{staticClass:"mb-n2",attrs:{title:e.$t("ManualProbe.Advanced"),"sub-panel-class":"manual-probe-dialog-advanced"}},[t(Ee,[t(Wt,{staticClass:"_btn-group"},e._l(e.offsetsZ,function(r,i){return t(g,{key:"offsetsUp-".concat(i),staticClass:"_btn-qs flex-grow-1 px-1",attrs:{small:""},on:{click:function(n){e.sendTestZ(r.toString())}}},[i===0?t(_,{staticClass:"mr-1 ml-n1",attrs:{left:"",small:""}},[e._v(" "+e._s(e.mdiArrowExpandUp)+" ")]):e._e(),t("span",[e._v("+"+e._s(r))])],1)}),1),t(Wt,{staticClass:"_btn-group mt-6 mt-sm-3"},e._l(e.offsetsZ,function(r,i){return t(g,{key:"offsetsDown-".concat(i),staticClass:"_btn-qs flex-grow-1 px-1",attrs:{small:""},on:{click:function(n){e.sendTestZ((r*-1).toString())}}},[i===0?t(_,{staticClass:"mr-1 ml-n1",attrs:{left:"",small:""}},[e._v(" "+e._s(e.mdiArrowCollapseDown)+" ")]):e._e(),t("span",[e._v("−"+e._s(r))])],1)}),1)],1)],1),t(oe,[t(ae),t(g,{attrs:{text:"",loading:e.loadingAbort},on:{click:e.sendAbort}},[e._v(" "+e._s(e.$t("ManualProbe.Abort"))+" ")]),t(g,{attrs:{color:"primary",text:"",loading:e.loadingAccept},on:{click:e.sendAccept}},[e._v(" "+e._s(e.$t("ManualProbe.Accept"))+" ")])],1)],1)],1)},P3=[],D3=E(ym,S3,P3,!1,null,"eed61d3e");const Zv=D3.exports,tf=(s,e)=>{e!==null&&typeof e=="object"&&Object.keys(e).forEach(t=>{const r=e[t];typeof r=="object"&&!Array.isArray(r)&&t in s&&r!==null&&s[t]!==null?tf(s[t],r):y.set(s,t,r)})},Nt=(s,e)=>{if(s!=null&&e.length){const t=s==null?void 0:s.find(r=>r.isDirectory&&r.filename===e[0]);if(t){if(e.shift(),t.childrens&&e.length)return Nt(t.childrens,e);if(t.childrens)return t.childrens}return s}return null},Ft=(s,e)=>s.sort((t,r)=>{const i=t[e].toLowerCase(),n=r[e].toLowerCase();return i<n?-1:i>n?1:0}),lr=s=>s.charAt(0).toUpperCase()+s.slice(1),T3=s=>s.replace(/_/g," ").replace(/(?:^\w|[A-Z]|\b\w)/g,(e,t)=>t===0?e.toLowerCase():e.toUpperCase()).replace(/\s+/g,"");function sf(s){return s=s.replace(/^!! /g,""),s=s.replace(/\n!! /g,"\n"),s=s.replace(/^\/\/ /g,""),s=s.replace(/\n\/\/ /g,"\n"),s=s.replace(/^echo:/g,""),s=s.replace(/^debug:/g,""),s=s.replace("\n// ","<br>"),s=s.replace(/\r\n|\r|\n/g,"<br>"),s.trim()}const Ye=s=>{let e="";return s=s.replace(/_/g," "),s.split(" ").forEach(t=>{e+=" "+t.charAt(0).toUpperCase()+t.slice(1)}),e=e.slice(1),e},Xe=s=>{let e=-1;const t=[" kB"," MB"," GB"," TB"," PB"," EB"," ZB"," YB"];do s=s/1024,e++;while(s>1024);return Math.max(s,.1).toFixed(1)+t[e]},O3=s=>{let e=-1;const t=[" kHz"," MHz"," GHz"];do s=s/1e3,e++;while(s>1e3);return Math.max(s,.1).toFixed()+t[e]},Is=(s,e=!0)=>{if(!s)return"--";const t=[];if(e){const a=Math.floor(s/86400);a&&(s%=3600*24,t.push("".concat(a,"d")))}const r=Math.floor(s/3600);s%=3600,r&&t.push("".concat(r,"h"));const i=Math.floor(s/60);i&&t.push("".concat(i,"m"));const n=s%60;return n&&t.push("".concat(n.toFixed(0),"s")),t.join(" ")},rf=(s,e,t)=>{const r=e.length?e[0]:"filename",i=t[0];return s!==null&&(s.sort(function(n,a){if(n[r]===a[r])return 0;if(n[r]===null||n[r]===void 0)return-1;if(a[r]===null||a[r]===void 0)return 1;if(n[r].constructor===String&&a[r].constructor===String)return n[r].localeCompare(a[r],void 0,{sensivity:"base"});if(n[r]instanceof Array&&a[r]instanceof Array){const o=n[r].length?n.filament.reduce((u,c)=>u+c):0,l=a[r].length?a.filament.reduce((u,c)=>u+c):0;return o-l}return n[r]-a[r]}),i&&s.reverse(),s.sort((n,a)=>n.isDirectory===a.isDirectory?0:n.isDirectory?-1:1)),s!=null?s:[]};function M3(s,e){var i,n;const t=Math.min((i=s==null?void 0:s.length)!=null?i:Number.MAX_VALUE,(n=e==null?void 0:e.length)!=null?n:Number.MAX_VALUE);let r=0;for(;r<t&&!(s.charCodeAt(r)^e.charCodeAt(r));)r+=1;return s.substr(0,r)}function k3(s){var a,o,l;const e=/{%?.*?params\.([A-Za-z_0-9]+)(?:\|(int|string|double))?(?:\|default\('?"?(.*?)"?'?\))?(?:\|(int|string))?.*?%?}/;let t=e.exec(s.gcode),r=s.gcode,i=null;for(;t;){i===null&&(i={});const u=t[1],c=(o=(a=t[2])!=null?a:t[4])!=null?o:null,d=(l=t[3])!=null?l:null;i["".concat(u)]={type:c,default:d},r=r.replace(t[0],""),t=e.exec(r)}const n=/{%?.*?if.*?'([A-Za-z_0-9]+)' (?:not )?in params.*?%?}/;for(t=n.exec(s.gcode),r=s.gcode;t;){i===null&&(i={});const u=t[1];"".concat(u)in i||(i["".concat(u)]={type:null,default:null}),r=r.replace(t[0],""),t=n.exec(r)}return i}function Cm(s){s.preventDefault(),s.returnValue=""}function E3(s){if(navigator.clipboard){navigator.clipboard.writeText(s);return}const e=document.createElement("textarea");let t=document.getElementById("devices-dialog");t||(t=document.body),e.value=s,e.style.position="absolute",e.style.top="0",e.style.left="0",e.style.zIndex="100000",e.style.opacity="0",t.appendChild(e),e.focus(),e.select();try{document.execCommand("copy")}catch(r){console.error("Unable to copy to clipboard",r)}e.remove()}function qv(s,e){const t=parseInt(s.split("x")[0]),r=parseInt(e.split("x")[0]);return t-r}function Ie(s){return s.split("/").map(e=>encodeURIComponent(e)).join("/")}const Xv=s=>{var e;return(e={wh:Co,kwh:Co,mwh:Co,j:Co,w:Vg,v:Vg,a:iS,"°c":fi,c:fi,"°f":fi,f:fi,"°":fi,g:xS}[s==null?void 0:s.toLowerCase()])!=null?e:Jw};var L3=Object.defineProperty,A3=Object.getOwnPropertyDescriptor,Yv=(s,e,t,r)=>{for(var i=r>1?void 0:r?A3(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&L3(e,t,i),i};let gl=class extends k(L){constructor(){super(...arguments),this.mdiClose=Ba,this.formatFilesize=Xe}get show(){var s;return(s=this.$store.state.files.upload.show)!=null?s:!1}get cancelTokenSource(){return this.$store.state.files.upload.cancelTokenSource}get filename(){var s;return(s=this.$store.state.files.upload.filename)!=null?s:""}get currentNumber(){var s;return(s=this.$store.state.files.upload.currentNumber)!=null?s:0}get maxNumber(){var s;return(s=this.$store.state.files.upload.maxNumber)!=null?s:0}get speed(){var s;return Xe(Math.round((s=this.$store.state.files.upload.speed)!=null?s:0))}get percent(){var s;return Math.round((s=this.$store.state.files.upload.percent)!=null?s:0)}cancelUpload(){var s;(s=this.cancelTokenSource)==null||s.cancel(),this.$store.dispatch("files/uploadSetShow",!1),this.$store.dispatch("socket/removeLoading",{name:"gcodeUpload"}),this.$store.dispatch("socket/removeLoading",{name:"configFileUpload"})}showChanged(s){const e=document.getElementsByTagName("body")[0];s?e.classList.add("fullscreenUpload--active"):e.classList.remove("fullscreenUpload--active")}};Yv([he("show")],gl.prototype,"showChanged",1);gl=Yv([S({components:{}})],gl);var F3=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.show?t(xi,{attrs:{timeout:-1,value:!0,fixed:"",right:"",bottom:""},scopedSlots:e._u([{key:"action",fn:function({attrs:r}){return[t(g,e._b({staticStyle:{"min-width":"auto"},attrs:{color:"red",text:""},on:{click:e.cancelUpload}},"v-btn",r,!1),[t(_,{staticClass:"0"},[e._v(e._s(e.mdiClose))])],1)]}}],null,!1,2940317734)},[e.maxNumber>1?t("span",{staticClass:"mr-1"},[e._v("("+e._s(e.currentNumber)+"/"+e._s(e.maxNumber)+")")]):e._e(),t("strong",[e._v(e._s(e.$t("Editor.Uploading")+" "+e.filename))]),t("br"),e._v(" "+e._s(e.percent)+" % @ "+e._s(e.speed)+"/s "),t("br"),t(Ss,{staticClass:"mt-2",attrs:{value:e.percent}})],1):e._e()},R3=[],H3=E(gl,F3,R3,!1,null,null);const Jv=H3.exports;var j3=Object.getOwnPropertyDescriptor,I3=(s,e,t,r)=>{for(var i=r>1?void 0:r?j3(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let $m=class extends k(L){constructor(){super(...arguments),this.mdiTrayArrowDown=MS,this.visible=!1}get dropzoneClasses(){return{"fullscreen-upload__dragzone--visible":this.visible}}get currentRoute(){var s;return(s=this.$route.path)!=null?s:""}get currentPathGcodes(){var s;return(s=this.$store.state.gui.view.gcodefiles.currentPath)!=null?s:""}get currentPathConfig(){var s;return(s=this.$store.state.gui.view.configfiles.currentPath)!=null?s:""}mounted(){window.addEventListener("dragenter",this.onDragOverWindow),window.addEventListener("dragover",this.onDragOverWindow),window.addEventListener("dragleave",this.onDragLeaveWindow)}beforeDestroy(){window.removeEventListener("dragenter",this.onDragOverWindow),window.removeEventListener("dragover",this.onDragOverWindow),window.removeEventListener("dragleave",this.onDragLeaveWindow)}showDropZone(){this.visible=!0}hideDropZone(){this.visible=!1}onDragOverWindow(s){var t,r;((r=(t=s.dataTransfer)==null?void 0:t.types)!=null?r:[]).includes("Files")&&(s.preventDefault(),!this.visible&&this.showDropZone())}onDragLeaveWindow(s){s.preventDefault(),this.hideDropZone()}async onDrop(s){var e,t;if(s.preventDefault(),this.hideDropZone(),(t=(e=s.dataTransfer)==null?void 0:e.files)!=null&&t.length){const r=[...s.dataTransfer.files];await this.$store.dispatch("socket/addLoading",{name:"gcodeUpload"}),await this.$store.dispatch("files/uploadSetCurrentNumber",0),await this.$store.dispatch("files/uploadSetMaxNumber",r.length);for(const i of r){const n=i.name.lastIndexOf("."),a=i.name.slice(n),o=Pi.includes(a);let l="";this.currentRoute==="/files"&&o?l=this.currentPathGcodes:this.currentRoute==="/config"&&!o&&(l=this.currentPathConfig);const u=o?"gcodes":"config";await this.$store.dispatch("files/uploadIncrementCurrentNumber");const c=await this.$store.dispatch("files/uploadFile",{file:i,path:l,root:u});c!==!1&&this.$toast.success(this.$t("Files.SuccessfullyUploaded",{filename:c}).toString())}await this.$store.dispatch("socket/removeLoading",{name:"gcodeUpload"})}}};$m=I3([S],$m);var N3=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",{staticClass:"d-flex justify-center flex-column fullscreen-upload__dragzone",class:e.dropzoneClasses,on:{drop:e.onDrop}},[t(_,{staticClass:"fullscreen-upload__icon"},[e._v(e._s(e.mdiTrayArrowDown))]),t("div",{staticClass:"textnode"},[e._v(e._s(e.$t("FullscreenUpload.DropFilesToUploadFiles")))])],1)},V3=[],B3=E($m,N3,V3,!1,null,null);const Kv=B3.exports;var U3=Object.getOwnPropertyDescriptor,W3=(s,e,t,r)=>{for(var i=r>1?void 0:r?U3(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let xm=class extends k(L){get boolShowDialogRunning(){return this.status==="running"}get boolShowDialogSuccess(){return this.status==="success"}set boolShowDialogSuccess(s){s||this.$store.dispatch("server/timelapse/resetSnackbar")}get status(){var s;return(s=this.$store.state.server.timelapse.rendering.status)!=null?s:""}get progress(){var s;return(s=this.$store.state.server.timelapse.rendering.progress)!=null?s:""}get filename(){var s;return(s=this.$store.state.server.timelapse.rendering.filename)!=null?s:""}};xm=W3([S({components:{}})],xm);var z3=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(xi,{attrs:{timeout:-1,value:!0,fixed:"",right:"",bottom:""},model:{value:e.boolShowDialogRunning,callback:function(r){e.boolShowDialogRunning=r},expression:"boolShowDialogRunning"}},[t("div",[e._v(e._s(e.$t("Timelapse.TimelapseRendering"))+"...")]),e.progress>0?t(Ss,{staticClass:"mt-2",attrs:{value:e.progress,indeterminate:""}}):e._e(),e.progress===0?t(Ss,{staticClass:"mt-2",attrs:{indeterminate:""}}):e._e()],1),t(xi,{attrs:{timeout:5e3,value:!0,fixed:"",right:"",bottom:""},model:{value:e.boolShowDialogSuccess,callback:function(r){e.boolShowDialogSuccess=r},expression:"boolShowDialogSuccess"}},[t("div",[e._v(" "+e._s(e.$t("Timelapse.TimelapseRenderingSuccessful"))+" "),t("br"),t("strong",[e._v(e._s(e.filename))])])])],1)},G3=[],Z3=E(xm,z3,G3,!1,null,null);const Qv=Z3.exports;let $o;const q3=new Uint8Array(16);function X3(){if(!$o&&($o=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!$o))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return $o(q3)}const ct=[];for(let s=0;s<256;++s)ct.push((s+256).toString(16).slice(1));function Y3(s,e=0){return ct[s[e+0]]+ct[s[e+1]]+ct[s[e+2]]+ct[s[e+3]]+"-"+ct[s[e+4]]+ct[s[e+5]]+"-"+ct[s[e+6]]+ct[s[e+7]]+"-"+ct[s[e+8]]+ct[s[e+9]]+"-"+ct[s[e+10]]+ct[s[e+11]]+ct[s[e+12]]+ct[s[e+13]]+ct[s[e+14]]+ct[s[e+15]]}const J3=typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),zg={randomUUID:J3};function ds(s,e,t){if(zg.randomUUID&&!s)return zg.randomUUID();s=s||{};const r=s.random||(s.rng||X3)();return r[6]=r[6]&15|64,r[8]=r[8]&63|128,Y3(r)}var K3=Object.defineProperty,Q3=Object.getOwnPropertyDescriptor,nf=(s,e,t,r)=>{for(var i=r>1?void 0:r?Q3(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&K3(e,t,i),i};let sa=class extends k(L){constructor(){super(...arguments),this.mdiContentCopy=Fp,this.isShowTooltip=!1,this.cssClassName=""}mounted(){this.cssClassName="textfield-with-copy-".concat(ds())}copy(){E3(this.value),this.isShowTooltip=!0,setTimeout(()=>this.isShowTooltip=!1,2e3)}};nf([w({type:String,required:!0})],sa.prototype,"label",2);nf([w({type:String,required:!0})],sa.prototype,"value",2);sa=nf([S],sa);var eD=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(se,{class:e.cssClassName,attrs:{readonly:"",dense:"",outlined:"","hide-details":"",label:e.label,value:e.value},scopedSlots:e._u([{key:"append",fn:function(){return[t(_,{on:{click:e.copy}},[e._v(e._s(e.mdiContentCopy))]),t(de,{attrs:{"open-on-click":"","open-on-hover":!1,attach:"."+e.cssClassName,"position-x":50,"position-y":0},model:{value:e.isShowTooltip,callback:function(r){e.isShowTooltip=r},expression:"isShowTooltip"}},[t("span",[e._v(e._s(e.$t("App.TextfieldWithCopy.Copied")))])])]},proxy:!0}])})},tD=[],sD=E(sa,eD,tD,!1,null,"8d851db2");const Kt=sD.exports;var rD=Object.defineProperty,iD=Object.getOwnPropertyDescriptor,eb=(s,e,t,r)=>{for(var i=r>1?void 0:r?iD(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&rD(e,t,i),i};let _l=class extends k(L){get identicalResolutions(){const s=this.device.modes.map(e=>e.resolutions.sort(qv).join(","));return s.every(e=>e===s[0])}get resolutions(){var s,e,t;return(t=(e=(s=this.device.modes[0])==null?void 0:s.resolutions)==null?void 0:e.join(", "))!=null?t:""}get formats(){return this.device.modes.map(s=>"".concat(s.description," (").concat(s.format,")")).join(", ")}get show_alt_name(){return this.device.alt_name===null?!1:this.device.alt_name!==this.device.camera_name}};eb([w({type:Object,required:!0})],_l.prototype,"device",2);_l=eb([S({components:{TextfieldWithCopy:Kt}})],_l);var nD=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{staticClass:"mt-3 w-100",attrs:{outlined:""}},[t(J,{attrs:{"three-line":""}},[t(_t,[t("div",{staticClass:"text-overline mb-2 d-flex flex-row"},[e._v("V4L2")]),t(Ze,{staticClass:"text-h5 mb-0"},[e._v(e._s(e.device.camera_name))]),e.show_alt_name?t(Va,[e._v(e._s(e.device.alt_name))]):e._e()],1)],1),t(Z,[t(x,[t(b,[t(Kt,{attrs:{label:e.$t("DevicesDialog.DevicePath"),value:e.device.device_path}})],1)],1),e.device.path_by_id?t(x,[t(b,[t(Kt,{attrs:{label:e.$t("DevicesDialog.PathById"),value:e.device.path_by_id}})],1)],1):e._e(),e.device.path_by_hardware?t(x,[t(b,[t(Kt,{attrs:{label:e.$t("DevicesDialog.PathByHardware"),value:e.device.path_by_hardware}})],1)],1):e._e(),e.device.modes.length?[e.identicalResolutions?[t(x,{staticClass:"mt-0"},[t(b,{staticClass:"py-2",attrs:{cols:"4"}},[e._v(e._s(e.$t("DevicesDialog.Formats")))]),t(b,{staticClass:"py-2"},[e._v(e._s(e.formats))])],1),t(x,{staticClass:"mt-0"},[t(b,{staticClass:"py-2",attrs:{cols:"4"}},[e._v(e._s(e.$t("DevicesDialog.Resolutions")))]),t(b,{staticClass:"py-2"},[e._v(e._s(e.resolutions))])],1)]:e._l(e.device.modes,function(r){return t(x,{key:r.format,staticClass:"mt-0"},[t(b,{staticClass:"py-2",attrs:{cols:"4"}},[e._v(" "+e._s(r.description)+" "),t("br"),t("small",[e._v(e._s(r.format))])]),t(b,{staticClass:"py-2"},[e._v(e._s(r.resolutions.join(", ")))])],1)})]:e._e()],2)],1)},aD=[],oD=E(_l,nD,aD,!1,null,null);const lD=oD.exports;var cD=Object.defineProperty,uD=Object.getOwnPropertyDescriptor,tb=(s,e,t,r)=>{for(var i=r>1?void 0:r?uD(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&cD(e,t,i),i};let vl=class extends k(L){get identicalResolutions(){const s=this.device.modes.map(e=>e.resolutions.sort(qv).join(","));return s.every(e=>e===s[0])}get resolutions(){return this.device.modes[0].resolutions.join(", ")}get formats(){return this.device.modes.map(s=>s.format).join(", ")}};tb([w({type:Object,required:!0})],vl.prototype,"device",2);vl=tb([S({components:{TextfieldWithCopy:Kt}})],vl);var dD=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{staticClass:"mt-3 w-100",attrs:{outlined:""}},[t(J,{attrs:{"three-line":""}},[t(_t,[t("div",{staticClass:"text-overline mb-2 d-flex flex-row"},[e._v("Libcamera")]),t(Ze,{staticClass:"text-h5 mb-0"},[e._v(e._s(e.device.model))])],1)],1),t(Z,[t(x,{staticClass:"mb-1"},[t(b,[t(Kt,{attrs:{label:e.$t("DevicesDialog.LibcameraId"),value:e.device.libcamera_id}})],1)],1),e.identicalResolutions?[t(x,{staticClass:"mt-0"},[t(b,{staticClass:"py-2",attrs:{cols:"4"}},[e._v(e._s(e.$t("DevicesDialog.Formats")))]),t(b,{staticClass:"py-2"},[e._v(e._s(e.formats))])],1),t(x,{staticClass:"mt-0"},[t(b,{staticClass:"py-2",attrs:{cols:"4"}},[e._v(e._s(e.$t("DevicesDialog.Resolutions")))]),t(b,{staticClass:"py-2"},[e._v(e._s(e.resolutions))])],1)]:e._l(e.device.modes,function(r){return t(x,{key:r.format,staticClass:"mt-0"},[t(b,{staticClass:"py-2",attrs:{cols:"4"}},[e._v(e._s(r.format))]),t(b,{staticClass:"py-2"},[e._v(e._s(r.resolutions.join(", ")))])],1)})],2)],1)},mD=[],hD=E(vl,dD,mD,!1,null,null);const pD=hD.exports;var fD=Object.defineProperty,gD=Object.getOwnPropertyDescriptor,sb=(s,e,t,r)=>{for(var i=r>1?void 0:r?gD(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&fD(e,t,i),i};let bl=class extends k(L){constructor(){super(...arguments),this.v4l2Devices=[],this.libcameraDevices=[],this.loading=!1,this.loaded=!1}get filteredLibcameraDevices(){return this.hideSystemEntries?this.libcameraDevices.filter(s=>!s.libcamera_id.includes("usb@")):this.libcameraDevices}get filteredV4l2Devices(){return this.v4l2Devices.filter(s=>this.hideSystemEntries?this.libcameraDevices.length===0&&s.hardware_bus.endsWith("csi")?!0:!s.hardware_bus.startsWith("platform:"):!0)}async refresh(){var e,t;this.loading=!0;const s=await fetch(this.apiUrl+"/machine/peripherals/video").then(r=>r.json()).then(r=>{var i;return(i=r.result)!=null?i:{}});this.v4l2Devices=(e=s.v4l2_devices)!=null?e:[],this.libcameraDevices=(t=s.libcamera_devices)!=null?t:[],this.loading=!1,this.loaded=!0}};sb([w({type:Boolean,default:!1})],bl.prototype,"hideSystemEntries",2);bl=sb([S],bl);var _D=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Z,[t(x,[t(b,{staticClass:"text-center"},[t(g,{attrs:{loading:e.loading,color:"primary"},on:{click:e.refresh}},[e._v(e._s(e.$t("DevicesDialog.Refresh")))])],1)],1),e.libcameraDevices.length||e.filteredV4l2Devices.length?t(x,{staticClass:"mt-0"},[t(b,[e._l(e.filteredLibcameraDevices,function(r,i){return t(pD,{key:"libcamera_".concat(r.libcamera_id,"_").concat(i),attrs:{device:r}})}),e._l(e.filteredV4l2Devices,function(r,i){return t(lD,{key:"v4l2_".concat(r.hardware_bus,"_").concat(i),attrs:{device:r}})})],2)],1):e.loaded?t(x,{staticClass:"mt-0"},[t(b,{staticClass:"col-8 mx-auto"},[t("p",{staticClass:"text-center text--disabled mb-0"},[e._v(e._s(e.$t("DevicesDialog.NoDeviceFound")))])])],1):t(x,{staticClass:"mt-0"},[t(b,{staticClass:"col-8 mx-auto"},[t("p",{staticClass:"text-center text--disabled mb-0"},[e._v(e._s(e.$t("DevicesDialog.ClickRefresh")))])])],1)],1)},vD=[],bD=E(bl,_D,vD,!1,null,"dcdc8e37");const yD=bD.exports;var CD=Object.defineProperty,$D=Object.getOwnPropertyDescriptor,rb=(s,e,t,r)=>{for(var i=r>1?void 0:r?$D(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&CD(e,t,i),i};let yl=class extends k(L){get details(){const s=["protocol","class","serial","usb_location"],e=[];return Object.keys(this.device).forEach(t=>{var i;let r=(i=this.device[t])!=null?i:null;!s.includes(t)||r===null||(t==="class"&&this.device.subclass&&(r+=", ".concat(this.device.subclass)),e.push({key:t,value:r}))}),e}};rb([w({type:Object,required:!0})],yl.prototype,"device",2);yl=rb([S],yl);var xD=function(){var r,i;var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{staticClass:"mt-3",attrs:{outlined:""}},[t(J,{attrs:{"three-line":""}},[t(_t,[t("div",{staticClass:"text-overline mb-2 d-flex flex-row"},[t("span",[e._v(e._s((r=e.device.manufacturer)!=null?r:"Unknown"))]),t(ae),t("span",[e._v(e._s(e.device.vendor_id)+":"+e._s(e.device.product_id))])],1),t(Ze,{staticClass:"text-h5 mb-1"},[e._v(e._s((i=e.device.product)!=null?i:"Unknown"))]),e.device.description?t(Va,[e._v(e._s(e.device.description))]):e._e()],1)],1),t(Z,{staticClass:"pt-0"},e._l(e.details,function(n){return t(x,{key:n.key,staticClass:"mt-0"},[t(b,{staticClass:"py-2",attrs:{cols:"3"}},[e._v(e._s(n.key))]),t(b,{staticClass:"py-2"},[e._v(e._s(n.value))])],1)}),1)],1)},wD=[],SD=E(yl,xD,wD,!1,null,null);const PD=SD.exports;var DD=Object.defineProperty,TD=Object.getOwnPropertyDescriptor,ib=(s,e,t,r)=>{for(var i=r>1?void 0:r?TD(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&DD(e,t,i),i};let Cl=class extends k(L){constructor(){super(...arguments),this.devices=[],this.loading=!1,this.loaded=!1}get filteredDevices(){return this.hideSystemEntries?this.devices.filter(s=>s.class!=="Hub"):this.devices}async refresh(){this.loading=!0,this.devices=await fetch(this.apiUrl+"/machine/peripherals/usb").then(s=>s.json()).then(s=>{var e,t;return(t=(e=s.result)==null?void 0:e.usb_devices)!=null?t:[]}),this.loading=!1,this.loaded=!0}};ib([w({type:Boolean,default:!1})],Cl.prototype,"hideSystemEntries",2);Cl=ib([S],Cl);var OD=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Z,[t(x,[t(b,{staticClass:"text-center"},[t(g,{attrs:{loading:e.loading,color:"primary"},on:{click:e.refresh}},[e._v(e._s(e.$t("DevicesDialog.Refresh")))])],1)],1),e.filteredDevices.length?t(x,{staticClass:"mt-0"},[t(b,e._l(e.filteredDevices,function(r){return t(PD,{key:r.usb_location,attrs:{device:r}})}),1)],1):e.loaded?t(x,{staticClass:"mt-0"},[t(b,{staticClass:"col-8 mx-auto"},[t("p",{staticClass:"text-center text--disabled mb-0"},[e._v(e._s(e.$t("DevicesDialog.NoDeviceFound")))])])],1):t(x,{staticClass:"mt-0"},[t(b,{staticClass:"col-8 mx-auto"},[t("p",{staticClass:"text-center text--disabled mb-0"},[e._v(e._s(e.$t("DevicesDialog.ClickRefresh")))])])],1)],1)},MD=[],kD=E(Cl,OD,MD,!1,null,"0262a811");const ED=kD.exports;var LD=Object.defineProperty,AD=Object.getOwnPropertyDescriptor,nb=(s,e,t,r)=>{for(var i=r>1?void 0:r?AD(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&LD(e,t,i),i};let $l=class extends k(L){};nb([w({type:Object,required:!0})],$l.prototype,"device",2);$l=nb([S({components:{TextfieldWithCopy:Kt}})],$l);var FD=function(){var r,i;var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{staticClass:"mt-3 w-100",attrs:{outlined:""}},[t(J,{attrs:{"three-line":""}},[t(_t,[t("div",{staticClass:"text-overline mb-2 d-flex flex-row"},[t("span",[e._v(e._s(e.device.device_type.toUpperCase().replaceAll("_"," ")))]),t(ae),t("span",[e._v(e._s(e.device.driver_name))])],1),t(Ze,{staticClass:"text-h5 mb-0"},[e._v(e._s(e.device.device_name))])],1)],1),t(Z,[t(x,[t(b,[t(Kt,{attrs:{label:e.$t("DevicesDialog.DevicePath"),value:e.device.device_path}})],1)],1),(r=e.device.path_by_id)!=null&&r?t(x,[t(b,[t(Kt,{attrs:{label:e.$t("DevicesDialog.PathById"),value:e.device.path_by_id}})],1)],1):e._e(),(i=e.device.path_by_hardware)!=null&&i?t(x,[t(b,[t(Kt,{attrs:{label:e.$t("DevicesDialog.PathByHardware"),value:e.device.path_by_hardware}})],1)],1):e._e()],1)],1)},RD=[],HD=E($l,FD,RD,!1,null,null);const jD=HD.exports;var ID=Object.defineProperty,ND=Object.getOwnPropertyDescriptor,ab=(s,e,t,r)=>{for(var i=r>1?void 0:r?ND(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&ID(e,t,i),i};let xl=class extends k(L){constructor(){super(...arguments),this.devices=[],this.loading=!1,this.loaded=!1}get filteredDevices(){return this.hideSystemEntries?this.devices.filter(s=>s.device_type!=="hardware_uart"):this.devices}async refresh(){this.loading=!0,this.devices=await fetch(this.apiUrl+"/machine/peripherals/serial").then(s=>s.json()).then(s=>{var e,t;return(t=(e=s.result)==null?void 0:e.serial_devices)!=null?t:[]}),this.loading=!1,this.loaded=!0}};ab([w({type:Boolean,default:!1})],xl.prototype,"hideSystemEntries",2);xl=ab([S],xl);var VD=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Z,[t(x,[t(b,{staticClass:"text-center"},[t(g,{attrs:{loading:e.loading,color:"primary"},on:{click:e.refresh}},[e._v(e._s(e.$t("DevicesDialog.Refresh")))])],1)],1),e.filteredDevices.length?t(x,{staticClass:"mt-0"},[t(b,[t(P$,{attrs:{accordion:""}},e._l(e.filteredDevices,function(r){var i;return t(jD,{key:(i=r.path_by_hardware)!=null?i:r.device_path,attrs:{device:r}})}),1)],1)],1):e.loaded?t(x,{staticClass:"mt-0"},[t(b,{staticClass:"col-8 mx-auto"},[t("p",{staticClass:"text-center text--disabled mb-0"},[e._v(e._s(e.$t("DevicesDialog.NoDeviceFound")))])])],1):t(x,{staticClass:"mt-0"},[t(b,{staticClass:"col-8 mx-auto"},[t("p",{staticClass:"text-center text--disabled mb-0"},[e._v(e._s(e.$t("DevicesDialog.ClickRefresh")))])])],1)],1)},BD=[],UD=E(xl,VD,BD,!1,null,"17c3494f");const WD=UD.exports;var zD=Object.defineProperty,GD=Object.getOwnPropertyDescriptor,ob=(s,e,t,r)=>{for(var i=r>1?void 0:r?GD(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&zD(e,t,i),i};let wl=class extends k(L){};ob([w({type:Object,required:!0})],wl.prototype,"device",2);wl=ob([S({components:{TextfieldWithCopy:Kt}})],wl);var ZD=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{staticClass:"mt-3 w-100",attrs:{outlined:""}},[t(Z,[t(x,[t(b,[t("div",{staticClass:"text-overline mb-2 d-flex flex-row"},[t("span",[e._v(e._s(e.device.application))])])])],1),t(x,{staticClass:"mt-0"},[t(b,[t(Kt,{attrs:{label:"UUID",value:e.device.uuid}})],1)],1)],1)],1)},qD=[],XD=E(wl,ZD,qD,!1,null,null);const lb=XD.exports;var YD=Object.defineProperty,JD=Object.getOwnPropertyDescriptor,af=(s,e,t,r)=>{for(var i=r>1?void 0:r?JD(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&YD(e,t,i),i};let ra=class extends k(L){constructor(){super(...arguments),this.mdiInformationVariantCircle=Kw,this.devices=[],this.loading=!1,this.loaded=!1}async refresh(){this.loading=!0,this.devices=await fetch("".concat(this.apiUrl,"/machine/peripherals/canbus?interface=").concat(this.name)).then(s=>s.json()).then(s=>{var e;return(e=s.result.can_uuids)!=null?e:[]}),this.loading=!1,this.loaded=!0}};af([w({type:String,required:!0})],ra.prototype,"name",2);af([w({type:Boolean,default:!1})],ra.prototype,"hideSystemEntries",2);ra=af([S({components:{DevicesDialogCanDevice:lb}})],ra);var KD=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("overlay-scrollbars",{staticStyle:{"max-height":"400px","overflow-x":"hidden"}},[t(Z,[t(x,[t(b,{staticClass:"text-center"},[t(g,{attrs:{loading:e.loading,color:"primary"},on:{click:e.refresh}},[e._v(e._s(e.$t("DevicesDialog.Refresh")))])],1)],1),e.devices.length?t(x,{staticClass:"mt-0"},[t(b,e._l(e.devices,function(r){return t(lb,{key:r.uuid,attrs:{device:r}})}),1)],1):e.loaded?t(x,{staticClass:"mt-0"},[t(b,{staticClass:"col-8 mx-auto"},[t("p",{staticClass:"text-center text--disabled mb-0"},[e._v(e._s(e.$t("DevicesDialog.NoDeviceFound")))])])],1):t(x,{staticClass:"mt-0"},[t(b,{staticClass:"col-8 mx-auto"},[t("p",{staticClass:"text-center text--disabled mb-0"},[e._v(e._s(e.$t("DevicesDialog.ClickRefresh")))])])],1),e.devices.length===0?t(x,[t(b,[t(it,{attrs:{dense:"",outlined:"",type:"info",icon:e.mdiInformationVariantCircle}},[e._v(" "+e._s(e.$t("DevicesDialog.CanBusInfo"))+" "),t(x,{staticClass:"my-0"},[t(b,{staticClass:"text-center"},[t(g,{attrs:{href:"https://docs.mainsail.xyz/overview/features/query-devices#can-devices",color:"info",outlined:"",text:"",small:""}},[e._v(" open guide ")])],1)],1)],1)],1)],1):e._e()],1)],1)},QD=[],e5=E(ra,KD,QD,!1,null,"dde76904");const t5=e5.exports;var s5=Object.defineProperty,r5=Object.getOwnPropertyDescriptor,cb=(s,e,t,r)=>{for(var i=r>1?void 0:r?r5(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&s5(e,t,i),i};let Sl=class extends k(L){constructor(){super(...arguments),this.mdiCog=ss,this.mdiUsb=Jp,this.mdiCloseThick=pe,this.tab="serial",this.hideSystemEntries=!0}get tabs(){const s=[{tab:"serial",title:"Serial"},{tab:"usb",title:"USB"},{tab:"video",title:"Video"}];return this.canInterfaces.forEach(e=>{s.push({tab:e,title:e.toUpperCase()})}),s.sort((e,t)=>e.title.localeCompare(t.title))}get canInterfaces(){var s,e;return Object.keys((e=(s=this.$store.state.server.system_info)==null?void 0:s.canbus)!=null?e:{})}closePrompt(){this.$emit("close")}};cb([w({type:Boolean,default:!1})],Sl.prototype,"showDialog",2);Sl=cb([S({components:{Panel:U}})],Sl);var i5=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.showDialog,width:"500",persistent:"",fullscreen:e.isMobile}},[t(U,{staticStyle:{overflow:"hidden"},attrs:{id:"devices-dialog",title:e.$t("DevicesDialog.Headline"),icon:e.mdiUsb,"card-class":"devices-dialog","margin-bottom":!1,height:e.isMobile?0:548},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(ye,{attrs:{left:!0,"offset-y":!0,"close-on-content-click":!1,attach:"#devices-dialog"},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{icon:"",tile:""}},"v-btn",i,!1),r),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiCog))])],1)]}}])},[t(Me,[t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("DevicesDialog.HideSystemEntries")},model:{value:e.hideSystemEntries,callback:function(r){e.hideSystemEntries=r},expression:"hideSystemEntries"}})],1)],1)],1),t(g,{attrs:{icon:"",tile:""},on:{click:e.closePrompt}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(rl,{attrs:{"fixed-tabs":""},model:{value:e.tab,callback:function(r){e.tab=r},expression:"tab"}},e._l(e.tabs,function(r){return t(Dr,{key:r.tab},[e._v(e._s(r.title))])}),1),t("overlay-scrollbars",{staticStyle:{"max-height":"400px","overflow-x":"hidden"}},[t(T_,{model:{value:e.tab,callback:function(r){e.tab=r},expression:"tab"}},[e._l(e.canInterfaces,function(r){return t(Ys,{key:r},[t(t5,{attrs:{"hide-system-entries":e.hideSystemEntries,name:r}})],1)}),t(Ys,{key:"serial"},[t(WD,{attrs:{"hide-system-entries":e.hideSystemEntries}})],1),t(Ys,{key:"usb"},[t(ED,{attrs:{"hide-system-entries":e.hideSystemEntries}})],1),t(Ys,{key:"video"},[t(yD,{attrs:{"hide-system-entries":e.hideSystemEntries}})],1)],2)],1)],1)],1)},n5=[],a5=E(Sl,i5,n5,!1,null,"309be890");const of=a5.exports,o5="modulepreload",l5=function(s){return"/"+s},Gg={},fe=function(e,t,r){let i=Promise.resolve();if(t&&t.length>0){document.getElementsByTagName("link");const a=document.querySelector("meta[property=csp-nonce]"),o=(a==null?void 0:a.nonce)||(a==null?void 0:a.getAttribute("nonce"));i=Promise.allSettled(t.map(l=>{if(l=l5(l),l in Gg)return;Gg[l]=!0;const u=l.endsWith(".css"),c=u?'[rel="stylesheet"]':"";if(document.querySelector('link[href="'.concat(l,'"]').concat(c)))return;const d=document.createElement("link");if(d.rel=u?"stylesheet":o5,u||(d.as="script"),d.crossOrigin="",d.href=l,o&&d.setAttribute("nonce",o),document.head.appendChild(d),u)return new Promise((m,h)=>{d.addEventListener("load",m),d.addEventListener("error",()=>h(new Error("Unable to preload CSS for ".concat(l))))})}))}function n(a){const o=new Event("vite:preloadError",{cancelable:!0});if(o.payload=a,window.dispatchEvent(o),!o.defaultPrevented)throw a}return i.then(a=>{for(const o of a||[])o.status==="rejected"&&n(o.reason);return e().catch(n)})},c5=y.component("CodemirrorAsync",()=>fe(()=>import("./Codemirror--JcAba3g.js"),__vite__mapDeps([0,1,2,3,4,5,6])));var u5=Object.defineProperty,d5=Object.getOwnPropertyDescriptor,lf=(s,e,t,r)=>{for(var i=r>1?void 0:r?d5(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&u5(e,t,i),i};let ia=class extends k(L){constructor(){super(...arguments),this.dialogConfirmChange=!1,this.dialogDevices=!1,this.treeviewItemKeyProp="line",this.structureActive=[],this.structureOpen=[],this.structureActiveChangedBySidebar=!1,this.formatFilesize=Xe,this.mdiCloseThick=pe,this.mdiHelp=Wp,this.mdiContentSave=Rp,this.mdiRestart=_r,this.mdiClose=Ba,this.mdiHelpCircle=pu,this.mdiFileDocumentEditOutline=za,this.mdiFileDocumentOutline=Uw,this.mdiUsb=Jp,this.mdiFormatListCheckbox=Yw}get changed(){var s;return(s=this.$store.state.editor.changed)!=null?s:!1}get changedOutput(){return this.changed?"*":""}get show(){var s;return(s=this.$store.state.editor.bool)!=null?s:!1}get filepath(){var s;return(s=this.$store.state.editor.filepath)!=null?s:""}get filename(){var s;return(s=this.$store.state.editor.filename)!=null?s:""}get filenameWithoutExtension(){return this.filename.lastIndexOf(".")?this.filename.slice(0,this.filename.lastIndexOf(".")):this.filename}get fileExtension(){return this.filename.lastIndexOf(".")?this.filename.slice(this.filename.lastIndexOf(".")+1):""}get fileroot(){var s;return(s=this.$store.state.editor.fileroot)!=null?s:"gcodes"}get permissions(){var s;return(s=this.$store.state.editor.permissions)!=null?s:"r"}get isWriteable(){return this.permissions.includes("w")}get sourcecode(){var s;return(s=this.$store.state.editor.sourcecode)!=null?s:""}set sourcecode(s){this.$store.dispatch("editor/updateSourcecode",s)}get loaderBool(){var s;return(s=this.$store.state.editor.loaderBool)!=null?s:!1}get loaderProgress(){var s;return(s=this.$store.state.editor.loaderProgress)!=null?s:{}}get snackbarHeadline(){let s=this.$t("Editor.Downloading");return this.loaderProgress.direction&&(s=lr(this.loaderProgress.direction)),this.$t("Editor.".concat(s))}get availableServices(){var s,e;return(e=(s=this.$store.state.server.system_info)==null?void 0:s.available_services)!=null?e:[]}get restartAllowedOrPossible(){return!this.isWriteable||["printing","paused"].includes(this.printer_state)?null:!0}get restartServiceName(){return this.availableServices.includes(this.filenameWithoutExtension)&&this.fileExtension==="conf"?this.filenameWithoutExtension:this.filename.startsWith("webcam")&&["conf","txt"].includes(this.fileExtension)?"webcamd":this.filename.startsWith("mooncord")&&this.fileExtension==="json"?"mooncord":this.filename==="moonraker.conf"?"moonraker":this.fileExtension==="cfg"?"klipper":null}get restartServiceNameExists(){return!this.restartAllowedOrPossible||this.restartServiceName===null?!1:["klipper","moonraker"].includes(this.restartServiceName)?!0:this.availableServices.includes(this.restartServiceName)}get confirmUnsavedChanges(){var s;return(s=this.$store.state.gui.editor.confirmUnsavedChanges)!=null?s:!1}get escToClose(){var s;return(s=this.$store.state.gui.editor.escToClose)!=null?s:!1}get title(){const s=this.filepath?"".concat(this.filepath,"/").concat(this.filename):this.filename;return this.isWriteable?"".concat(s," ").concat(this.changedOutput):"".concat(s," (").concat(this.$t("Editor.FileReadOnly"),")")}get currentLanguage(){return this.$store.state.gui.general.language}get klipperConfigReference(){var r,i;const s=this.currentLanguage,e=(r=Ng[this.klipperAppName])!=null?r:Ng.Klipper;let t=e.url;return(i=e.docsLanguages)!=null&&i.includes(s)&&(t+="".concat(s,"/")),t+="Config_Reference.html",t}get fileStructureSidebar(){return this.$store.state.gui.editor.fileStructureSidebar}set fileStructureSidebar(s){this.$store.dispatch("gui/saveSetting",{name:"editor.fileStructureSidebar",value:s})}get configFileStructure(){if(!["conf","cfg"].includes(this.fileExtension))return[];const s=this.sourcecode.split(/\n/gi),e=/^[^#\S]*?(\[(?<section>.*?)]|(?<name>\w+)\s*?[:=])/gim,t=[];for(let r=0;r<s.length;r++){const n=[...s[r].matchAll(e)];if(n.length===0)continue;const a=n[0];if(a.groups.section){t.push({name:a.groups.section,type:"section",line:r+1,children:[]});continue}t.length&&a.groups.name&&t[t.length-1].children.push({name:a.groups.name,type:"item",line:r+1})}return t}get existsFileStructure(){return this.configFileStructure.length>0}toggleFileStructure(){this.fileStructureSidebar=!this.fileStructureSidebar}cancelDownload(){this.$store.dispatch("editor/cancelLoad")}escClose(){this.escToClose&&this.close()}close(){this.confirmUnsavedChanges?this.promptUnsavedChanges():this.$store.dispatch("editor/close")}discardChanges(){this.dialogConfirmChange=!1,this.$store.dispatch("editor/close")}promptUnsavedChanges(){!this.changed||!this.isWriteable?this.$store.dispatch("editor/close"):this.dialogConfirmChange=!0}save(s=null){this.dialogConfirmChange=!1,this.$store.dispatch("editor/saveFile",{content:this.sourcecode,restartServiceName:s})}activeChangesItemClick(){this.structureActiveChangedBySidebar=!0}activeChanges(s){var e;this.structureActiveChangedBySidebar&&(this.structureActiveChangedBySidebar=!1,s.length&&((e=this.editor)==null||e.gotoLine(s[0])))}lineChanges(s){var e;(e=this.configFileStructure)==null||e.map(t=>{var r;t.line==s?this.structureActive=[s]:(r=t.children)==null||r.map(i=>{i.line==s&&(this.structureActive=[s],this.structureOpen.includes(t.line)||this.structureOpen.push(t.line))})})}changedChanged(s){if(this.confirmUnsavedChanges){if(s){window.addEventListener("beforeunload",Cm);return}window.removeEventListener("beforeunload",Cm)}}};lf([Ts("editor")],ia.prototype,"editor",2);lf([he("changed")],ia.prototype,"changedChanged",1);ia=lf([S({components:{DevicesDialog:of,Panel:U,CodemirrorAsync:c5}})],ia);var m5=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(le,{attrs:{persistent:"",fullscreen:"","hide-overlay":"",transition:!1},on:{close:e.close,keydown:[function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"esc",27,r.key,["Esc","Escape"])?null:e.escClose.apply(null,arguments)},function(r){if(!r.type.indexOf("key")&&e._k(r.keyCode,"s",void 0,r.key,void 0)||!r.ctrlKey||!r.shiftKey)return null;r.preventDefault(),e.restartServiceNameExists&&e.save(e.restartServiceName)},function(r){if(!r.type.indexOf("key")&&e._k(r.keyCode,"s",void 0,r.key,void 0)||!r.metaKey||!r.shiftKey)return null;r.preventDefault(),e.restartServiceNameExists&&e.save(e.restartServiceName)},function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"s",void 0,r.key,void 0)||!r.ctrlKey?null:(r.preventDefault(),e.save(null))},function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"s",void 0,r.key,void 0)||!r.metaKey?null:(r.preventDefault(),e.save(null))}]},model:{value:e.show,callback:function(r){e.show=r},expression:"show"}},[t(U,{attrs:{"card-class":"editor-dialog",icon:e.isWriteable?e.mdiFileDocumentEditOutline:e.mdiFileDocumentOutline,title:e.title},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{staticClass:"d-none d-md-flex",attrs:{text:"",tile:""},on:{click:function(r){e.dialogDevices=!0}}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiUsb))]),e._v(" "+e._s(e.$t("Editor.DeviceDialog"))+" ")],1),e.restartServiceName==="klipper"?t(g,{staticClass:"d-none d-md-flex",attrs:{text:"",tile:"",href:e.klipperConfigReference,target:"_blank"}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiHelp))]),e._v(" "+e._s(e.$t("Editor.ConfigReference"))+" ")],1):e._e(),e.existsFileStructure?t(g,{staticClass:"d-none d-md-flex",attrs:{text:"",tile:""},on:{click:e.toggleFileStructure}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiFormatListCheckbox))]),e._v(" "+e._s(e.$t("Editor.FileStructure"))+" ")],1):e._e(),e.restartServiceNameExists?t(g,{staticClass:"d-none d-sm-flex",attrs:{color:"primary",text:"",tile:""},on:{click:function(r){return e.save(e.restartServiceName)}}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiRestart))]),e._v(" "+e._s(e.$t("Editor.SaveRestart"))+" ")],1):e._e(),e.isWriteable?t(g,{attrs:{icon:"",tile:""},on:{click:function(r){return e.save(null)}}},[t(_,[e._v(e._s(e.mdiContentSave))])],1):e._e(),t(g,{attrs:{icon:"",tile:""},on:{click:e.close}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{staticClass:"pa-0 d-flex"},[e.show?t("codemirror-async",{ref:"editor",staticClass:"codemirror",class:{withSidebar:e.existsFileStructure&&e.fileStructureSidebar},attrs:{name:e.filename,"file-extension":e.fileExtension},on:{lineChange:e.lineChanges},model:{value:e.sourcecode,callback:function(r){e.sourcecode=r},expression:"sourcecode"}}):e._e(),e.existsFileStructure&&e.fileStructureSidebar?t("div",{staticClass:"d-none d-md-flex structure-sidebar"},[t(D$,{staticClass:"w-100",attrs:{activatable:"",dense:"",active:e.structureActive,open:e.structureOpen,"item-key":e.treeviewItemKeyProp,items:e.configFileStructure},on:{"update:active":e.activeChanges},scopedSlots:e._u([{key:"label",fn:function({item:r}){return[t("div",{staticClass:"cursor-pointer _structure-sidebar-item",class:r.type=="item"?"ͼp":"ͼt",on:{click:e.activeChangesItemClick}},[e._v(" "+e._s(r.name)+" ")])]}},e.restartServiceName==="klipper"?{key:"append",fn:function({item:r}){return[r.type=="section"?t(g,{attrs:{icon:"",small:"",plain:"",color:"grey darken-2",href:e.klipperConfigReference+"#"+r.name.split(" ")[0],target:"_blank"}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiHelpCircle))])],1):e._e()]}}:null],null,!0)})],1):e._e()],1)],1)],1),t(xi,{attrs:{timeout:-1,fixed:"",right:"",bottom:""},scopedSlots:e._u([{key:"action",fn:function({attrs:r}){return[t(g,e._b({staticStyle:{"min-width":"auto"},attrs:{color:"red",text:"",tile:""},on:{click:e.cancelDownload}},"v-btn",r,!1),[t(_,{staticClass:"0"},[e._v(e._s(e.mdiClose))])],1)]}}]),model:{value:e.loaderBool,callback:function(r){e.loaderBool=r},expression:"loaderBool"}},[t("div",[e._v(" "+e._s(e.snackbarHeadline)+" "),t("br"),t("strong",[e._v(e._s(e.filename))])]),e.loaderProgress.total>0?[t("span",{staticClass:"mr-1"},[e._v(" ("+e._s(e.formatFilesize(e.loaderProgress.loaded))+"/"+e._s(e.formatFilesize(e.loaderProgress.total))+") ")]),e._v(" "+e._s(Math.round(100*e.loaderProgress.loaded/e.loaderProgress.total))+" % @ "+e._s(e.loaderProgress.speed)+"/s "),t("br"),t(Ss,{staticClass:"mt-2",attrs:{value:100*e.loaderProgress.loaded/e.loaderProgress.total}})]:[t(Ss,{staticClass:"mt-2",attrs:{indeterminate:""}})]],2),t(le,{attrs:{persistent:"",width:600},model:{value:e.dialogConfirmChange,callback:function(r){e.dialogConfirmChange=r},expression:"dialogConfirmChange"}},[t(U,{attrs:{"card-class":"editor-confirm-change-dialog",icon:e.mdiHelpCircle,title:e.$t("Editor.UnsavedChanges"),"margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.dialogConfirmChange=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{staticClass:"pt-3"},[t(x,[t(b,[t("p",{staticClass:"body-1 mb-2"},[e._v(e._s(e.$t("Editor.UnsavedChangesMessage",{filename:e.filename})))]),t("p",{staticClass:"body-2"},[e._v(e._s(e.$t("Editor.UnsavedChangesSubMessage")))])])],1)],1),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.discardChanges}},[e._v(" "+e._s(e.$t("Editor.DontSave"))+" ")]),t(g,{attrs:{text:"",color:"primary"},on:{click:e.save}},[e._v(" "+e._s(e.$t("Editor.SaveClose"))+" ")]),e.restartServiceNameExists?[t(g,{attrs:{text:"",color:"primary"},on:{click:function(r){return e.save(e.restartServiceName)}}},[e._v(" "+e._s(e.$t("Editor.SaveRestart"))+" ")])]:e._e()],2)],1)],1),t(of,{attrs:{"show-dialog":e.dialogDevices},on:{close:function(r){e.dialogDevices=!1}}})],1)},h5=[],p5=E(ia,m5,h5,!1,null,"9cf62f8a");const ub=p5.exports;var f5=Object.defineProperty,g5=Object.getOwnPropertyDescriptor,db=(s,e,t,r)=>{for(var i=r>1?void 0:r?g5(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&f5(e,t,i),i};let Pl=class extends k(L){constructor(){super(...arguments),this.mdiUpdate=Xa,this.headers=[{text:"Date",value:"date",width:"1%",dateType:"Date"},{text:"Message",sortable:!1,value:"message",width:"99%"}]}get application(){var s;return(s=this.$store.state.server.updateManager.updateResponse.application)!=null?s:""}get messages(){var s;return(s=this.$store.state.server.updateManager.updateResponse.messages)!=null?s:[]}get complete(){var s;return(s=this.$store.state.server.updateManager.updateResponse.complete)!=null?s:!0}customSort(s,e,t){return s.sort((r,i)=>{if(e[0]==="date")return t[0]?new Date(r[e]).getTime()-new Date(i[e]).getTime():new Date(i[e]).getTime()-new Date(r[e]).getTime();if(typeof r[e]<"u")return t[0]?i[e].toLowerCase().localeCompare(r[e].toLowerCase()):r[e].toLowerCase().localeCompare(i[e].toLowerCase())}),s}formatTime(s){const e=s.getHours()<10?"0"+s.getHours().toString():s.getHours(),t=s.getMinutes()<10?"0"+s.getMinutes().toString():s.getMinutes(),r=s.getSeconds()<10?"0"+s.getSeconds().toString():s.getSeconds();return e+":"+t+":"+r}close(){this.application!==null&&this.complete&&["client","mainsail","full"].includes(this.application.toLowerCase())?window.location.reload():(this.$store.commit("server/updateManager/resetUpdateResponse"),this.$socket.emit("machine.update.status",{refresh:!1},{action:"server/updateManager/onUpdateStatus"}))}messagesChanged(){setTimeout(()=>{this.$nextTick(()=>{if(this.$refs.updaterLogScroll){const s=this.$refs.updaterLogScroll.osInstance();s==null||s.scroll({y:"100%"})}})},50)}};db([he("messages")],Pl.prototype,"messagesChanged",1);Pl=db([S({components:{}})],Pl);var _5=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{staticClass:"mx-0",attrs:{value:e.application!=="",persistent:"","max-width":"800"}},[t(Pe,{attrs:{loading:!e.complete}},[t("template",{slot:"progress"},[t(Ss,{attrs:{color:"primary",indeterminate:""}})],1),t(Op,{attrs:{flat:"",dense:""}},[t(ru,[t("span",{staticClass:"subheading"},[t(_,{attrs:{left:""}},[e._v(e._s(e.mdiUpdate))]),e.application.substr(0,8)==="recover_"&&!e.complete?[e._v(" "+e._s(e.$t("App.UpdateDialog.Recovering",{software:e.application.substr(8)}))+" ")]:e.application.substr(0,8)==="recover_"?[e._v(" "+e._s(e.$t("App.UpdateDialog.RecoveringDone",{software:e.application.substr(8)}))+" ")]:e.complete?[e._v(" "+e._s(e.$t("App.UpdateDialog.UpdatingDone",{software:e.application}))+" ")]:[e._v(" "+e._s(e.$t("App.UpdateDialog.Updating",{software:e.application}))+" ")]],2)])],1),t(Z,{staticClass:"px-3"},[t(x,[t(b,{staticClass:"py-6 px-0"},[t("overlay-scrollbars",{ref:"updaterLogScroll",staticClass:"updaterLogScroll"},[t(Qr,{ref:"updaterLog",staticClass:"updaterLog",attrs:{headers:e.headers,items:e.messages,"item-key":"date","hide-default-footer":"","hide-default-header":"","disable-pagination":"","custom-sort":e.customSort,"sort-by":"date","sort-desc":!0,color:"primary"},scopedSlots:e._u([{key:"no-data",fn:function(){return[t("div",{staticClass:"py-2"},[e._v(e._s(e.$t("App.UpdateDialog.Empty")))])]},proxy:!0},{key:"item",fn:function({item:r}){return[t("tr",[t("td",{staticClass:"log-cell title-cell py-2"},[e._v(" "+e._s(e.formatTime(r.date))+" ")]),t("td",{staticClass:"log-cell content-cell pl-0 py-2",staticStyle:{width:"100%"},attrs:{colspan:"2"}},[r.message?t("span",{staticClass:"message",domProps:{innerHTML:e._s(r.message)}}):e._e()])])]}}])})],1)],1)],1),t(x,[t(b,{staticClass:"text-center pt-5"},[t(g,{attrs:{text:"",disabled:!e.complete,color:"primary"},on:{click:e.close}},[e._v(" "+e._s(e.$t("App.UpdateDialog.Close"))+" ")])],1)],1)],1)],2)],1)},v5=[],b5=E(Pl,_5,v5,!1,null,"7932e4ad");const mb=b5.exports;var y5=Object.getOwnPropertyDescriptor,C5=(s,e,t,r)=>{for(var i=r>1?void 0:r?y5(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let wm=class extends k(L){constructor(){super(...arguments),this.showDialog=!1,this.updateSW=null}onOfflineReady(){window.console.info("PWA is offline ready")}onNeedRefresh(){window.console.warn("PWA needs to refresh"),this.showDialog=!0}onRegistered(){window.console.debug("PWA is registered")}onRegisterError(s){window.console.error("PWA registration error:",s)}update(){var s;(s=this.updateSW)==null||s.call(this,!0),this.showDialog=!1}async mounted(){const{registerSW:s}=await fe(async()=>{const{registerSW:e}=await import("./virtual_pwa-register-DiXdS4qF.js");return{registerSW:e}},__vite__mapDeps([7,2,3,4,5,6]));this.updateSW=s({immediate:!0,onOfflineReady:this.onOfflineReady,onNeedRefresh:this.onNeedRefresh,onRegistered:this.onRegistered,onRegisterError:this.onRegisterError})}};wm=C5([S],wm);var $5=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{staticClass:"mx-0",attrs:{persistent:"","max-width":"400"},model:{value:e.showDialog,callback:function(r){e.showDialog=r},expression:"showDialog"}},[t(U,{attrs:{title:e.$t("App.TheServiceWorker.TitleNeedUpdate"),"card-class":"service-worker-dialog","margin-bottom":!1}},[t(Z,[t("p",[e._v(e._s(e.$t("App.TheServiceWorker.DescriptionNeedUpdate")))])]),t(oe,[t(ae),t(g,{attrs:{text:"",color:"primary"},on:{click:e.update}},[e._v(e._s(e.$t("App.TheServiceWorker.Update")))])],1)],1)],1)},x5=[],w5=E(wm,$5,x5,!1,null,null);const S5=w5.exports;var P5=Object.defineProperty,D5=Object.getOwnPropertyDescriptor,hb=(s,e,t,r)=>{for(var i=r>1?void 0:r?D5(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&P5(e,t,i),i};let Dl=class extends k(L){constructor(){super(...arguments),this.mdiAlertOctagonOutline=W_,this.mdiCloseThick=pe}emergencyStop(){this.$socket.emit("printer.emergency_stop",{},{loading:"topbarEmergencyStop"}),this.closePrompt()}closePrompt(){this.$emit("close")}};hb([w({type:Boolean,default:!1})],Dl.prototype,"showDialog",2);Dl=hb([S({components:{Panel:U}})],Dl);var T5=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.showDialog,width:"400",persistent:""}},[t(U,{attrs:{title:e.$t("EmergencyStopDialog.EmergencyStop"),"toolbar-color":"error","card-class":"emergency-stop-dialog",icon:e.mdiAlertOctagonOutline,"margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closePrompt}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[e._v(e._s(e.$t("EmergencyStopDialog.AreYouSure")))]),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.closePrompt}},[e._v(e._s(e.$t("EmergencyStopDialog.No")))]),t(g,{attrs:{color:"primary",text:""},on:{click:e.emergencyStop}},[e._v(e._s(e.$t("EmergencyStopDialog.Yes")))])],1)],1)],1)},O5=[],M5=E(Dl,T5,O5,!1,null,"3fed6302");const pb=M5.exports;var k5=Object.defineProperty,E5=Object.getOwnPropertyDescriptor,ln=(s,e,t,r)=>{for(var i=r>1?void 0:r?E5(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&k5(e,t,i),i};let cr=class extends k(L){constructor(){super(...arguments),this.mdiAlert=mw,this.mdiCloseThick=pe}action(){this.$emit("action")}close(){this.$emit("close")}};ln([w({type:Boolean,required:!0})],cr.prototype,"show",2);ln([w({type:String,required:!0})],cr.prototype,"title",2);ln([w({type:String,required:!0})],cr.prototype,"text",2);ln([w({type:String,required:!0})],cr.prototype,"actionButtonText",2);ln([w({type:String,required:!0})],cr.prototype,"cancelButtonText",2);cr=ln([S({components:{Panel:U}})],cr);var L5=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.show,width:"400",fullscreen:e.isMobile}},[t(U,{attrs:{"card-class":"confirm-top-corner-menu-dialog",icon:e.mdiAlert,title:e.title,"margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.close}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{staticClass:"pt-3"},[t(x,[t(b,[t("p",{staticClass:"body-2"},[e._v(e._s(e.text))])])],1)],1),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.close}},[e._v(e._s(e.cancelButtonText))]),t(g,{attrs:{text:"",color:"error"},on:{click:e.action}},[e._v(e._s(e.actionButtonText))])],1)],1)],1)},A5=[],F5=E(cr,L5,A5,!1,null,null);const Tl=F5.exports;var R5=Object.getOwnPropertyDescriptor,H5=(s,e,t,r)=>{for(var i=r>1?void 0:r?R5(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Ol=class extends y{get hideOtherInstances(){var s;return(s=this.$store.state.gui.uiSettings.hideOtherInstances)!=null?s:!1}get instance_ids(){var s,e;return(e=(s=this.$store.state.server.system_info)==null?void 0:s.instance_ids)!=null?e:{}}get klipperInstance(){var s;return(s=this.instance_ids.klipper)!=null?s:""}get moonrakerInstance(){var s;return(s=this.instance_ids.moonraker)!=null?s:""}};Ol=H5([S],Ol);var j5=Object.defineProperty,I5=Object.getOwnPropertyDescriptor,fb=(s,e,t,r)=>{for(var i=r>1?void 0:r?I5(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&j5(e,t,i),i};let Ml=class extends k(L,Ol){constructor(){super(...arguments),this.mdiPlay=nn,this.mdiRestart=_r,this.mdiStop=$v,this.showRestartDialog=!1,this.showStopDialog=!1}get name(){return this.hideOtherInstances&&this.service===this.klipperInstance?"Klipper":this.hideOtherInstances&&this.service===this.moonrakerInstance?"Moonraker":lr(this.service)}get service_states(){var s,e;return(e=(s=this.$store.state.server.system_info)==null?void 0:s.service_state)!=null?e:{}}get state(){return this.service in this.service_states?this.service_states[this.service].active_state:null}get subState(){return this.service in this.service_states?this.service_states[this.service].sub_state:null}get dialogRestartTitle(){return this.service===this.klipperInstance?this.$t("App.TopCornerMenu.ConfirmationDialog.Title.KlipperRestart"):this.$t("App.TopCornerMenu.ConfirmationDialog.Title.ServiceRestart")}get dialogStopTitle(){return this.$t("App.TopCornerMenu.ConfirmationDialog.Title.ServiceStop")}get dialogRestartDescription(){return this.service===this.klipperInstance?this.$t("App.TopCornerMenu.ConfirmationDialog.Description.KlipperRestart"):this.$t("App.TopCornerMenu.ConfirmationDialog.Description.ServiceRestart")}get dialogStopDescription(){return this.service===this.klipperInstance?this.$t("App.TopCornerMenu.ConfirmationDialog.Description.KlipperStop"):this.$t("App.TopCornerMenu.ConfirmationDialog.Description.ServiceStop")}get disableStopButton(){return this.state==="inactive"||this.service===this.moonrakerInstance}get styleStopButton(){return this.service===this.moonrakerInstance?"visibility: hidden;":""}clickStart(){this.$socket.emit("machine.services.start",{service:this.service}),this.closeMenu()}clickRestart(){if(this.printerIsPrinting){this.showRestartDialog=!0;return}this.serviceRestart()}clickStop(){if(this.printerIsPrinting){this.showStopDialog=!0;return}this.serviceStop()}serviceRestart(){this.showRestartDialog=!1,this.$socket.emit("machine.services.restart",{service:this.service}),this.closeMenu()}serviceStop(){this.showStopDialog=!1,this.$socket.emit("machine.services.stop",{service:this.service}),this.closeMenu()}closeMenu(){this.$emit("close-menu")}};fb([w({type:String,required:!0})],Ml.prototype,"service",2);Ml=fb([S({})],Ml);var N5=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(J,{staticClass:"minHeight30 pr-2"},[t(Ze,[t(de,{attrs:{left:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("span",e._g(e._b({},"span",i,!1),r),[e._v(e._s(e.name))])]}}])},[t("span",[e._v(e._s(e.state)+" ("+e._s(e.subState)+")")])])],1),t(pi,{staticClass:"my-0 d-flex flex-row",staticStyle:{"min-width":"auto"}},[e.state==="inactive"?t(g,{attrs:{icon:"",small:""},on:{click:e.clickStart}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiPlay))])],1):t(g,{attrs:{icon:"",small:""},on:{click:e.clickRestart}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiRestart))])],1),t(g,{style:e.styleStopButton,attrs:{icon:"",small:"",disabled:e.disableStopButton},on:{click:e.clickStop}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiStop))])],1)],1),t(Tl,{attrs:{show:e.showRestartDialog,title:e.dialogRestartTitle,text:e.dialogRestartDescription,"action-button-text":e.$t("App.TopCornerMenu.Restart"),"cancel-button-text":e.$t("App.TopCornerMenu.Cancel")},on:{action:e.serviceRestart,close:function(r){e.showRestartDialog=!1}}}),t(Tl,{attrs:{show:e.showStopDialog,title:e.dialogStopTitle,text:e.dialogStopDescription,"action-button-text":e.$t("App.TopCornerMenu.Stop"),"cancel-button-text":e.$t("App.TopCornerMenu.Cancel")},on:{action:e.serviceStop,close:function(r){e.showStopDialog=!1}}})],1)},V5=[],B5=E(Ml,N5,V5,!1,null,null);const gb=B5.exports;var U5=Object.getOwnPropertyDescriptor,W5=(s,e,t,r)=>{for(var i=r>1?void 0:r?U5(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Sm=class extends k(L,Ol){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiPowerStandby=hS,this.mdiRestart=_r,this.mdiPower=_v,this.mdiToggleSwitch=Yp,this.mdiToggleSwitchOff=OS,this.showMenu=!1,this.dialogPowerDeviceChange={show:!1,device:"",value:""},this.dialogConfirmation={show:!1,serviceName:null,executableFunction:null,title:"",description:"",actionButtonText:""}}get services(){var e,t,r;let s=(r=(t=(e=this.$store.state.server.system_info)==null?void 0:e.available_services)==null?void 0:t.filter(i=>i!=="klipper_mcu"))!=null?r:[];return this.hideOtherInstances&&this.klipperInstance!==""&&(s=s.filter(i=>!i.toLowerCase().startsWith("klipper-")&&i.toLowerCase()!=="klipper"||i===this.klipperInstance)),this.hideOtherInstances&&this.moonrakerInstance!==""&&(s=s.filter(i=>!i.toLowerCase().startsWith("moonraker-")&&i.toLowerCase()!=="moonraker"||i===this.moonrakerInstance)),s.sort()}get powerDevices(){var e;return((e=this.$store.getters["server/power/getDevices"])!=null?e:[]).filter(t=>!t.device.startsWith("_"))}checkDialog(s,e,t){if(!this.printerIsPrinting){s(e);return}this.dialogConfirmation.executableFunction=s,this.dialogConfirmation.serviceName=e;const r=t.trim().charAt(0).toUpperCase()+t.trim().slice(1);let i="App.TopCornerMenu.ConfirmationDialog.Title.Service"+r,n="App.TopCornerMenu.ConfirmationDialog.Description.Service"+r,a="App.TopCornerMenu."+r;e==="klipper"&&["stop","restart","firmwareRestart"].includes(t)?(i="App.TopCornerMenu.ConfirmationDialog.Title."+(t!=="stop"?"Klipper":"Service")+r,n="App.TopCornerMenu.ConfirmationDialog.Description.Klipper"+r,t==="firmwareRestart"&&(a="App.TopCornerMenu.KlipperFirmwareRestart")):e==="host"&&(i="App.TopCornerMenu.ConfirmationDialog.Title.Host"+r,n="App.TopCornerMenu.ConfirmationDialog.Description.Host"+r),this.dialogConfirmation.title=this.$t(i).toString(),this.dialogConfirmation.description=this.$t(n).toString(),this.dialogConfirmation.actionButtonText=this.$t(a).toString(),this.dialogConfirmation.show=!0}executeDialog(){this.dialogConfirmation.executableFunction(this.dialogConfirmation.serviceName),this.dialogConfirmation.show=!1}klipperRestart(){this.showMenu=!1,this.$store.dispatch("server/addEvent",{message:"RESTART",type:"command"}),this.$socket.emit("printer.gcode.script",{script:"RESTART"})}klipperFirmwareRestart(){this.showMenu=!1,this.$store.dispatch("server/addEvent",{message:"FIRMWARE_RESTART",type:"command"}),this.$socket.emit("printer.gcode.script",{script:"FIRMWARE_RESTART"})}changeSwitch(s,e){this.dialogPowerDeviceChange.device=s.device,this.dialogPowerDeviceChange.value=e,this.$store.state.gui.uiSettings.confirmOnPowerDeviceChange?this.dialogPowerDeviceChange.show=!0:this.powerDeviceToggle()}powerDeviceToggle(){this.dialogPowerDeviceChange.show=!1;const s=this.dialogPowerDeviceChange.value==="off"?"machine.device_power.on":"machine.device_power.off";this.$socket.emit(s,{[this.dialogPowerDeviceChange.device]:null},{action:"server/power/responseToggle"})}hostReboot(){this.showMenu=!1,this.$socket.emit("machine.reboot",{})}hostShutdown(){this.showMenu=!1,this.$socket.emit("machine.shutdown",{})}};Sm=W5([S({components:{ConfirmationDialog:Tl,TopCornerMenuService:gb,Panel:U}})],Sm);var z5=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(ye,{attrs:{bottom:"",left:"","offset-y":!0,"close-on-content-click":!1},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{icon:"",tile:""}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiPowerStandby))])],1)]}}]),model:{value:e.showMenu,callback:function(r){e.showMenu=r},expression:"showMenu"}},[t(Me,{attrs:{dense:""}},[e.klipperState!=="disconnected"?[t(cs,{staticStyle:{height:"auto"}},[e._v(" "+e._s(e.$t("App.TopCornerMenu.KlipperControl"))+" ")]),t(J,{staticClass:"minHeight30 pr-2",attrs:{link:""},on:{click:function(r){return e.checkDialog(e.klipperRestart,"klipper","restart")}}},[t(Ze,[e._v(e._s(e.$t("App.TopCornerMenu.KlipperRestart")))]),t(pi,{staticClass:"my-0 d-flex flex-row",staticStyle:{"min-width":"auto"}},[t(_,{staticClass:"mr-2",attrs:{small:""}},[e._v(e._s(e.mdiRestart))])],1)],1),t(J,{staticClass:"minHeight30 pr-2",attrs:{link:""},on:{click:function(r){return e.checkDialog(e.klipperFirmwareRestart,"klipper","firmwareRestart")}}},[t(Ze,[e._v(e._s(e.$t("App.TopCornerMenu.KlipperFirmwareRestart")))]),t(pi,{staticClass:"my-0 d-flex flex-row",staticStyle:{"min-width":"auto"}},[t(_,{staticClass:"mr-2",attrs:{small:""}},[e._v(e._s(e.mdiRestart))])],1)],1)]:e._e(),e.services.length?[e.klipperState!=="disconnected"?t(I,{staticClass:"mt-0"}):e._e(),t(cs,{staticClass:"pt-2",staticStyle:{height:"auto"}},[e._v(" "+e._s(e.$t("App.TopCornerMenu.ServiceControl"))+" ")]),e._l(e.services,function(r){return t(gb,{key:r,attrs:{service:r},on:{"close-menu":function(i){e.showMenu=!1}}})})]:e._e(),e.powerDevices.length?[t(I,{staticClass:"mt-0"}),t(cs,{staticClass:"pt-2",staticStyle:{height:"auto"}},[e._v(" "+e._s(e.$t("App.TopCornerMenu.PowerDevices"))+" ")]),e._l(e.powerDevices,function(r,i){return t(J,{key:i,staticClass:"minHeight30 pr-2",attrs:{disabled:r.status==="error"||r.locked_while_printing&&["printing","paused"].includes(e.printer_state)},on:{click:function(n){return e.changeSwitch(r,r.status)}}},[t(Ze,[e._v(e._s(r.device))]),t(pi,{staticClass:"my-0 d-flex flex-row",staticStyle:{"min-width":"auto"}},[t(_,{staticClass:"mr-2",attrs:{color:r.status==="on"?"":"grey darken-2"}},[e._v(" "+e._s(r.status==="on"?e.mdiToggleSwitch:e.mdiToggleSwitchOff)+" ")])],1)],1)})]:e._e(),t(I,{staticClass:"mt-0"}),t(cs,{staticClass:"pt-2",staticStyle:{height:"auto"}},[e._v(e._s(e.$t("App.TopCornerMenu.HostControl")))]),t(J,{staticClass:"minHeight30 pr-2",attrs:{link:""},on:{click:function(r){return e.checkDialog(e.hostReboot,"host","reboot")}}},[t(Ze,[e._v(e._s(e.$t("App.TopCornerMenu.Reboot")))]),t(pi,{staticClass:"my-0 d-flex flex-row",staticStyle:{"min-width":"auto"}},[t(_,{staticClass:"mr-2",attrs:{small:""}},[e._v(e._s(e.mdiPower))])],1)],1),t(J,{staticClass:"minHeight30 pr-2",attrs:{link:""},on:{click:function(r){return e.checkDialog(e.hostShutdown,"host","shutdown")}}},[t(Ze,[e._v(e._s(e.$t("App.TopCornerMenu.Shutdown")))]),t(pi,{staticClass:"my-0 d-flex flex-row",staticStyle:{"min-width":"auto"}},[t(_,{staticClass:"mr-2",attrs:{small:""}},[e._v(e._s(e.mdiPower))])],1)],1)],2)],1),t(le,{attrs:{width:"400",fullscreen:e.isMobile},model:{value:e.dialogPowerDeviceChange.show,callback:function(r){e.$set(e.dialogPowerDeviceChange,"show",r)},expression:"dialogPowerDeviceChange.show"}},[t(Pe,[t(gt,{staticClass:"headline"},[e._v(" "+e._s(e.dialogPowerDeviceChange.value==="off"?e.$t("PowerDeviceChangeDialog.TurnDeviceOn",{device:e.dialogPowerDeviceChange.device}):e.$t("PowerDeviceChangeDialog.TurnDeviceOff",{device:e.dialogPowerDeviceChange.device}))+" ")]),t(Z,[e._v(e._s(e.$t("PowerDeviceChangeDialog.AreYouSure")))]),t(oe,[t(ae),t(g,{attrs:{color:"red darken-1",text:""},on:{click:function(r){e.dialogPowerDeviceChange.show=!1}}},[e._v(" "+e._s(e.$t("PowerDeviceChangeDialog.No"))+" ")]),t(g,{attrs:{color:"green darken-1",text:""},on:{click:e.powerDeviceToggle}},[e._v(" "+e._s(e.$t("PowerDeviceChangeDialog.Yes"))+" ")])],1)],1)],1),t(Tl,{attrs:{show:e.dialogConfirmation.show,title:e.dialogConfirmation.title,text:e.dialogConfirmation.description,"action-button-text":e.dialogConfirmation.actionButtonText,"cancel-button-text":e.$t("App.TopCornerMenu.Cancel")},on:{action:e.executeDialog,close:function(r){e.dialogConfirmation.show=!1}}})],1)},G5=[],Z5=E(Sm,z5,G5,!1,null,null);const _b=Z5.exports;var q5=Object.defineProperty,X5=Object.getOwnPropertyDescriptor,cf=(s,e,t,r)=>{for(var i=r>1?void 0:r?X5(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&q5(e,t,i),i};let na=class extends k(L){constructor(){super(...arguments),this.selectedCheckboxes=[],this.selectAllIndeterminate=!1,this.selectAllModel=wr({get:this.getSelectAll,set:this.setSelectAll})}getSelectAll(){return this.selectAllIndeterminate=!1,0<this.selectedCheckboxes.length&&this.selectedCheckboxes.length<this.options.length?(this.selectAllIndeterminate=!0,!1):this.selectedCheckboxes.length==this.options.length}setSelectAll(e){if(e){this.selectedCheckboxes=this.options.map(t=>t.value);return}this.selectedCheckboxes=[]}};cf([w({required:!0})],na.prototype,"options",2);cf([w({type:Boolean,required:!1,default:!1})],na.prototype,"selectAll",2);na=cf([S],na);var Y5=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(b,{staticClass:"pl-6"},[e.selectAll?[t(ge,{staticClass:"mt-0",attrs:{label:e.$t("Settings.GeneralTab.Everything"),"hide-details":"",indeterminate:e.selectAllIndeterminate},on:{change:function(r){return e.$emit("update:selectedCheckboxes",e.selectedCheckboxes)}},model:{value:e.selectAllModel,callback:function(r){e.selectAllModel=r},expression:"selectAllModel"}}),t(I,{staticClass:"my-2"})]:e._e(),e._l(e.options,function(r){return[t(ge,{key:r.value,staticClass:"mt-0",attrs:{label:r.label,"hide-details":"",value:r.value},on:{change:function(i){return e.$emit("update:selectedCheckboxes",e.selectedCheckboxes)}},model:{value:e.selectedCheckboxes,callback:function(i){e.selectedCheckboxes=i},expression:"selectedCheckboxes"}})]})],2)},J5=[],K5=E(na,Y5,J5,!1,null,null);const ti=K5.exports;var Q5=Object.getOwnPropertyDescriptor,eT=(s,e,t,r)=>{for(var i=r>1?void 0:r?Q5(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Di=class extends L{get availableKeys(){return[{value:"general",label:this.$t("Settings.GeneralTab.General")},{value:"control",label:this.$t("Settings.ControlTab.Control")},{value:"dashboard",label:this.$t("Settings.DashboardTab.Dashboard")},{value:"editor",label:this.$t("Settings.EditorTab.Editor")},{value:"gcodeViewer",label:this.$t("Settings.GCodeViewerTab.GCodeViewer")},{value:"navigation",label:this.$t("Settings.GeneralTab.DbNavigation")},{value:"uiSettings",label:this.$t("Settings.UiSettingsTab.UiSettings")},{value:"view",label:this.$t("Settings.GeneralTab.DbView")},{value:"console",label:this.$t("Settings.ConsoleTab.Console")},{value:"gcodehistory",label:this.$t("Settings.GeneralTab.DbConsoleHistory")},{value:"macros",label:this.$t("Settings.MacrosTab.Macros")},{value:"notifications",label:this.$t("App.Notifications.Notifications")},{value:"presets",label:this.$t("Settings.PresetsTab.PreheatPresets")},{value:"remoteprinters",label:this.$t("Settings.RemotePrintersTab.RemotePrinters")},{value:"timelapse",label:this.$t("Settings.TimelapseTab.Timelapse")}]}async loadBackupableNamespaces(){let s=[];const e=this.$store.getters["socket/getUrl"]+"/server/database/list",t=await fetch(e).then(r=>r==null?void 0:r.json()).then(r=>{var i,n;return(n=(i=r==null?void 0:r.result)==null?void 0:i.namespaces)!=null?n:[]}).catch(()=>(window.console.error("Cannot load Moonraker DB namespaces"),[]));if(t.includes("mainsail")){const r=this.$store.getters["socket/getUrl"]+"/server/database/item?namespace=mainsail";s=await fetch(r).then(i=>i==null?void 0:i.json()).then(i=>{var n,a;return(a=(n=i==null?void 0:i.result)==null?void 0:n.value)!=null?a:{}}).then(i=>Object.keys(i)).then(i=>i.filter(n=>n!=="initVersion")).then(i=>i.map(n=>{const a=this.availableKeys.find(o=>o.value===n);return a||{value:n,label:n}})),s=s.sort(this.sortNamespaces)}return t.includes("maintenance")&&s.push({value:"maintenance",label:this.$t("Settings.GeneralTab.DbMaintenance")}),t.includes("timelapse")&&s.push({value:"timelapse",label:this.$t("Settings.GeneralTab.DbTimelapseSettings")}),t.includes("webcams")&&s.push({value:"webcams",label:this.$t("Settings.WebcamsTab.Webcams")}),s}sortNamespaces(s,e){if(s.value==="general")return-1;if(e.value==="general")return 1;const t=s.label.toString().toLowerCase(),r=e.label.toString().toLowerCase();return t<r?-1:t>r?1:0}};Di=eT([S],Di);var tT=Object.getOwnPropertyDescriptor,sT=(s,e,t,r)=>{for(var i=r>1?void 0:r?tT(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Pm=class extends k(L,Di){constructor(){super(...arguments),this.mdiHelpCircle=pu,this.mdiCloseThick=pe,this.showDialog=!1,this.backupableNamespaces=[],this.backupCheckboxes=[]}async mounted(){this.backupableNamespaces=await this.loadBackupableNamespaces()}onSelectBackupCheckboxes(e){this.backupCheckboxes=e}async backupMainsail(){await this.$store.dispatch("socket/addLoading","backupMainsail"),await this.$store.dispatch("gui/backupMoonrakerDB",this.backupCheckboxes),await this.$store.dispatch("socket/removeLoading","backupMainsail"),this.closeDialog()}async openDialog(){this.backupableNamespaces=await this.loadBackupableNamespaces(),this.showDialog=!0}closeDialog(){this.showDialog=!1}};Pm=sT([S({components:{Panel:U,SettingsRow:j,CheckboxList:ti}})],Pm);var rT=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(g,{attrs:{loading:e.loadings.includes("backupDbButton"),small:""},on:{click:e.openDialog}},[e._v(" "+e._s(e.$t("Settings.GeneralTab.Backup"))+" ")]),t(le,{attrs:{persistent:"",width:360},model:{value:e.showDialog,callback:function(r){e.showDialog=r},expression:"showDialog"}},[t(U,{attrs:{title:e.$t("Settings.GeneralTab.Backup"),"card-class":"mainsail-backup-dialog","margin-bottom":!1,icon:e.mdiHelpCircle},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(x,[t(b,[t("p",{staticClass:"mb-0"},[e._v(e._s(e.$t("Settings.GeneralTab.BackupDialog")))])])],1),t(x,[t(ti,{attrs:{options:e.backupableNamespaces,"select-all":""},on:{"update:selectedCheckboxes":e.onSelectBackupCheckboxes}})],1),t(x,[t(b,{staticClass:"text-center"},[t(g,{attrs:{color:"red",loading:e.loadings.includes("backupMainsail")},on:{click:e.backupMainsail}},[e._v(" "+e._s(e.$t("Settings.GeneralTab.Backup"))+" ")])],1)],1)],1)],1)],1)],1)},iT=[],nT=E(Pm,rT,iT,!1,null,null);const vb=nT.exports;var aT=Object.getOwnPropertyDescriptor,oT=(s,e,t,r)=>{for(var i=r>1?void 0:r?aT(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Dm=class extends k(L,Di){constructor(){super(...arguments),this.mdiHelpCircle=pu,this.mdiCloseThick=pe,this.showDialog=!1,this.restoreableNamespaces=[],this.restoreCheckboxes=[],this.restoreObjects={}}onSelectRestoreCheckboxes(e){this.restoreCheckboxes=e}async restoreDb(){var e,t;(t=(e=this.$refs)==null?void 0:e.uploadBackupFile)==null||t.click()}uploadRestore(){var r,i,n,a;if(((i=(r=this.$refs.uploadBackupFile.files)==null?void 0:r.length)!=null?i:0)===0){window.console.error("No json uploaded");return}const e=(a=(n=this.$refs)==null?void 0:n.uploadBackupFile)==null?void 0:a.files[0],t=new FileReader;t.readAsText(e,"UTF-8"),t.onload=o=>{var l;this.restoreableNamespaces=[];try{this.restoreObjects=JSON.parse(((l=o==null?void 0:o.target)==null?void 0:l.result)+"");const u=Object.keys(this.restoreObjects);this.restoreableNamespaces=u.map(c=>{const d=this.availableKeys.find(m=>m.value===c);return d||{value:c,label:c}}),this.restoreableNamespaces=this.restoreableNamespaces.sort(this.sortNamespaces),this.openDialog()}catch{y.$toast.error(this.$t("Settings.GeneralTab.CannotReadJson").toString())}},t.onerror=o=>{window.console.error(o)},this.$refs.uploadBackupFile.value=""}openDialog(){this.showDialog=!0}closeDialog(){this.showDialog=!1}restoreDbAction(){this.$store.dispatch("socket/addLoading","restoreDbAction"),this.$store.dispatch("gui/restoreMoonrakerDB",{dbCheckboxes:this.restoreCheckboxes,restoreObjects:this.restoreObjects})}};Dm=oT([S({components:{SettingsGeneralTabBackupDatabase:vb,Panel:U,SettingsRow:j,CheckboxList:ti}})],Dm);var lT=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t("input",{ref:"uploadBackupFile",staticClass:"d-none",attrs:{type:"file",accept:[".json"]},on:{change:e.uploadRestore}}),t(g,{staticClass:"ml-3",attrs:{small:"",loading:e.loadings.includes("restoreUploadButton")},on:{click:e.restoreDb}},[e._v(" "+e._s(e.$t("Settings.GeneralTab.Restore"))+" ")]),t(le,{attrs:{value:e.showDialog,persistent:"",width:360}},[t(U,{attrs:{title:e.$t("Settings.GeneralTab.Restore"),"card-class":"mainsail-restore-dialog","margin-bottom":!1,icon:e.mdiHelpCircle},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(x,[t(b,[t("p",{staticClass:"mb-0"},[e._v(e._s(e.$t("Settings.GeneralTab.RestoreDialog")))])])],1),t(x,[t(ti,{attrs:{options:e.restoreableNamespaces,"select-all":""},on:{"update:selectedCheckboxes":e.onSelectRestoreCheckboxes}})],1),t(x,[t(b,{staticClass:"text-center"},[t(g,{attrs:{color:"red",loading:e.loadings.includes("restoreMainsail")},on:{click:e.restoreDbAction}},[e._v(" "+e._s(e.$t("Settings.GeneralTab.Restore"))+" ")])],1)],1)],1)],1)],1)],1)},cT=[],uT=E(Dm,lT,cT,!1,null,null);const dT=uT.exports;var mT=Object.getOwnPropertyDescriptor,hT=(s,e,t,r)=>{for(var i=r>1?void 0:r?mT(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Tm=class extends k(L,Di){constructor(){super(...arguments),this.mdiHelpCircle=pu,this.mdiCloseThick=pe,this.showDialog=!1,this.resetableNamespaces=[],this.resetCheckboxes=[]}async mounted(){await this.loadResetableNamespaces()}onSelectResetCheckboxes(e){this.resetCheckboxes=e}resetMainsailAction(){this.$store.dispatch("socket/addLoading","resetMainsail"),this.$store.dispatch("gui/resetMoonrakerDB",this.resetCheckboxes)}async openDialog(){await this.loadResetableNamespaces(),this.showDialog=!0}async loadResetableNamespaces(){this.resetableNamespaces=await this.loadBackupableNamespaces(),this.moonrakerComponents.includes("history")&&(this.resetableNamespaces.push({value:"history_jobs",label:this.$t("Settings.GeneralTab.DbHistoryJobs")}),this.resetableNamespaces.push({value:"history_totals",label:this.$t("Settings.GeneralTab.DbHistoryTotals")}))}closeDialog(){this.showDialog=!1}};Tm=hT([S({components:{Panel:U,SettingsRow:j,CheckboxList:ti}})],Tm);var pT=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(g,{attrs:{color:"error",small:""},on:{click:e.openDialog}},[e._v(" "+e._s(e.$t("Settings.GeneralTab.FactoryReset"))+" ")]),t(le,{attrs:{persistent:"",width:360},model:{value:e.showDialog,callback:function(r){e.showDialog=r},expression:"showDialog"}},[t(U,{attrs:{title:e.$t("Settings.GeneralTab.FactoryReset"),"card-class":"mainsail-reset-dialog","margin-bottom":!1,icon:e.mdiHelpCircle},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(x,[t(b,[t("p",{staticClass:"mb-0"},[e._v(e._s(e.$t("Settings.GeneralTab.FactoryDialog")))])])],1),t(x,[t(ti,{attrs:{options:e.resetableNamespaces,"select-all":""},on:{"update:selectedCheckboxes":e.onSelectResetCheckboxes}})],1),t(x,[t(b,{staticClass:"text-center"},[t(g,{attrs:{color:"red",loading:e.loadings.includes("resetMainsail")},on:{click:e.resetMainsailAction}},[e._v(" "+e._s(e.$t("Settings.GeneralTab.Reset"))+" ")])],1)],1)],1)],1)],1)],1)},fT=[],gT=E(Tm,pT,fT,!1,null,null);const _T=gT.exports;var vT=Object.getOwnPropertyDescriptor,bT=(s,e,t,r)=>{for(var i=r>1?void 0:r?vT(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Om=class extends k(L,Di){constructor(){super(...arguments),this.availableLanguages=[]}async created(){const e=Object.assign({"../../locales/cz.json":()=>fe(()=>import("./cz-D8m9rjS3.js"),[]).then(r=>r.default),"../../locales/da.json":()=>fe(()=>import("./da-DYgaz82Z.js"),[]).then(r=>r.default),"../../locales/de.json":()=>fe(()=>import("./de-P4W13_SZ.js"),[]).then(r=>r.default),"../../locales/en.json":()=>fe(()=>import("./en-o7vnTKjO.js"),[]).then(r=>r.default),"../../locales/es.json":()=>fe(()=>import("./es-DJtSPj3U.js"),[]).then(r=>r.default),"../../locales/fr.json":()=>fe(()=>import("./fr-BgUf3CTX.js"),[]).then(r=>r.default),"../../locales/hu.json":()=>fe(()=>import("./hu-B1cvWa_J.js"),[]).then(r=>r.default),"../../locales/it.json":()=>fe(()=>import("./it-CPOq0Dki.js"),[]).then(r=>r.default),"../../locales/ja.json":()=>fe(()=>import("./ja-CS5xLYiw.js"),[]).then(r=>r.default),"../../locales/ko.json":()=>fe(()=>import("./ko-D481bVT5.js"),[]).then(r=>r.default),"../../locales/nl.json":()=>fe(()=>import("./nl-B9Xo5zsI.js"),[]).then(r=>r.default),"../../locales/pl.json":()=>fe(()=>import("./pl-bBR_77jy.js"),[]).then(r=>r.default),"../../locales/pt.json":()=>fe(()=>import("./pt-D716Rj3y.js"),[]).then(r=>r.default),"../../locales/ru.json":()=>fe(()=>import("./ru-BYzx4dUn.js"),[]).then(r=>r.default),"../../locales/se.json":()=>fe(()=>import("./se-Dt3G_241.js"),[]).then(r=>r.default),"../../locales/tr.json":()=>fe(()=>import("./tr-cyYpyxgv.js"),[]).then(r=>r.default),"../../locales/uk.json":()=>fe(()=>import("./uk-DIP7xo0c.js"),[]).then(r=>r.default),"../../locales/zh.json":()=>fe(()=>import("./zh-T9gotgQQ.js"),[]).then(r=>r.default),"../../locales/zh_TW.json":()=>fe(()=>import("./zh_TW-BFyG3P84.js"),[]).then(r=>r.default)}),t=[];for(const r in e){const i=r.slice(r.lastIndexOf("/")+1,r.lastIndexOf(".")),n=await e[r]();t.push({text:n.title,value:i})}this.availableLanguages=t.sort((r,i)=>r.text.localeCompare(i.text))}get printerName(){return this.$store.state.gui.general.printername}set printerName(e){this.$store.dispatch("gui/saveSetting",{name:"general.printername",value:e})}get currentLanguage(){return this.$store.state.gui.general.language}set currentLanguage(e){this.$store.dispatch("gui/saveSetting",{name:"general.language",value:e})}get dateFormat(){return this.$store.state.gui.general.dateFormat}set dateFormat(e){this.$store.dispatch("gui/saveSetting",{name:"general.dateFormat",value:e})}get dateFormatItems(){const e=new Date,t=navigator.languages&&navigator.languages.length?navigator.languages[0]:navigator.language;return[{value:null,text:"Browser (".concat(e.toLocaleDateString(t,{dateStyle:"medium"}),")")},{value:"2-digits",text:e.toLocaleDateString(t,{day:"2-digit",month:"2-digit",year:"numeric"})},{value:"short",text:e.toLocaleDateString(t,{day:"2-digit",month:"short",year:"numeric"})}]}get timeFormat(){return this.$store.state.gui.general.timeFormat}set timeFormat(e){this.$store.dispatch("gui/saveSetting",{name:"general.timeFormat",value:e})}get timeFormatItems(){const e=new Date,t=navigator.languages&&navigator.languages.length?navigator.languages[0]:navigator.language;return[{value:null,text:"Browser (".concat(e.toLocaleTimeString(t,{timeStyle:"short"}),")")},{value:"24hours",text:this.$t("Settings.GeneralTab.24hours",{time:e.toLocaleTimeString(t,{hour:"2-digit",minute:"2-digit",hourCycle:"h23"})})},{value:"12hours",text:this.$t("Settings.GeneralTab.12hours",{time:e.toLocaleTimeString(t,{hour:"2-digit",minute:"2-digit",hourCycle:"h12"})})}]}get calcPrintProgressItems(){return[{value:"file-relative",text:this.$t("Settings.GeneralTab.CalcPrintProgressItems.FileRelative")},{value:"file-absolute",text:this.$t("Settings.GeneralTab.CalcPrintProgressItems.FileAbsolute")},{value:"slicer",text:this.$t("Settings.GeneralTab.CalcPrintProgressItems.Slicer")},{value:"filament",text:this.$t("Settings.GeneralTab.CalcPrintProgressItems.Filament")}]}get calcPrintProgress(){var e;return(e=this.$store.state.gui.general.calcPrintProgress)!=null?e:"file-relative"}set calcPrintProgress(e){this.$store.dispatch("gui/saveSetting",{name:"general.calcPrintProgress",value:e})}get calcEstimateItems(){return[{value:"file",text:this.$t("Settings.GeneralTab.EstimateValues.File")},{value:"filament",text:this.$t("Settings.GeneralTab.EstimateValues.Filament")}]}get calcEstimateTime(){return this.$store.state.gui.general.calcEstimateTime}set calcEstimateTime(e){this.$store.dispatch("gui/saveSetting",{name:"general.calcEstimateTime",value:e})}get calcEtaTimeItems(){return[{value:"file",text:this.$t("Settings.GeneralTab.EstimateValues.File")},{value:"filament",text:this.$t("Settings.GeneralTab.EstimateValues.Filament")},{value:"slicer",text:this.$t("Settings.GeneralTab.EstimateValues.Slicer")}]}get calcEtaTime(){return this.$store.state.gui.general.calcEtaTime}set calcEtaTime(e){this.$store.dispatch("gui/saveSetting",{name:"general.calcEtaTime",value:e})}};Om=bT([S({components:{Panel:U,SettingsRow:j,CheckboxList:ti,SettingsGeneralTabBackupDatabase:vb,SettingsGeneralTabRestoreDatabase:dT,SettingsGeneralTabResetDatabase:_T}})],Om);var yT=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(Pe,{attrs:{flat:""}},[t(Z,[t(j,{attrs:{title:e.$t("Settings.GeneralTab.PrinterName")}},[t(se,{attrs:{"hide-details":"",outlined:"",dense:""},model:{value:e.printerName,callback:function(r){e.printerName=r},expression:"printerName"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GeneralTab.Language")}},[t(ke,{attrs:{items:e.availableLanguages,"hide-details":"",outlined:"",dense:""},model:{value:e.currentLanguage,callback:function(r){e.currentLanguage=r},expression:"currentLanguage"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GeneralTab.DateFormat")}},[t(ke,{attrs:{items:e.dateFormatItems,"hide-details":"",outlined:"",dense:""},model:{value:e.dateFormat,callback:function(r){e.dateFormat=r},expression:"dateFormat"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GeneralTab.TimeFormat")}},[t(ke,{attrs:{items:e.timeFormatItems,"hide-details":"",outlined:"",dense:""},model:{value:e.timeFormat,callback:function(r){e.timeFormat=r},expression:"timeFormat"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GeneralTab.CalcPrintProgress"),"sub-title":e.$t("Settings.GeneralTab.CalcPrintProgressDescription")}},[t(ke,{attrs:{items:e.calcPrintProgressItems,"hide-details":"",dense:"",outlined:""},model:{value:e.calcPrintProgress,callback:function(r){e.calcPrintProgress=r},expression:"calcPrintProgress"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GeneralTab.CalcEstimateTime"),"sub-title":e.$t("Settings.GeneralTab.CalcEstimateTimeDescription")}},[t(ke,{attrs:{items:e.calcEstimateItems,multiple:"","hide-details":"",dense:"",outlined:""},model:{value:e.calcEstimateTime,callback:function(r){e.calcEstimateTime=r},expression:"calcEstimateTime"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GeneralTab.CalcEtaTime"),"sub-title":e.$t("Settings.GeneralTab.CalcEtaTimeDescription")}},[t(ke,{attrs:{items:e.calcEtaTimeItems,multiple:"","hide-details":"",dense:"",outlined:""},model:{value:e.calcEtaTime,callback:function(r){e.calcEtaTime=r},expression:"calcEtaTime"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GeneralTab.MainsailSettingsMoonrakerDb"),"dynamic-slot-width":!0}},[t("settings-general-tab-backup-database"),t("settings-general-tab-restore-database")],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GeneralTab.FactoryReset"),"dynamic-slot-width":!0}},[t("settings-general-tab-reset-database")],1)],1)],1)],1)},CT=[],$T=E(Om,yT,CT,!1,null,null);const xT=$T.exports;function wT(s){switch(s){case"Hlsstreamer":return()=>fe(()=>import("./Hlsstreamer-BpBN3Lzc.js"),__vite__mapDeps([8,2,3,4,5,6,9]));case"Ipstreamer":return()=>fe(()=>import("./Ipstreamer-BPf8FdFe.js"),__vite__mapDeps([10,2,3,4,5,6,11]));case"JanusStreamer":return()=>fe(()=>import("./JanusStreamer-CQyYvBpk.js"),__vite__mapDeps([12,3,4,6,2,5,13]));case"JMuxerStream":return()=>fe(()=>import("./JMuxerStream-Cqmc9Hrb.js"),__vite__mapDeps([14,3,4,2,5,6,15]));case"Mjpegstreamer":return()=>fe(()=>import("./Mjpegstreamer-vxbaTGlP.js"),__vite__mapDeps([16,17,18,2,3,4,5,6,19]));case"MjpegstreamerAdaptive":return()=>fe(()=>import("./MjpegstreamerAdaptive-Boi1-RyL.js"),__vite__mapDeps([20,17,18,2,3,4,5,6,21]));case"Uv4lMjpeg":return()=>fe(()=>import("./Uv4lMjpeg-1VbXGWjy.js"),__vite__mapDeps([22,2,3,4,5,6,23]));case"WebrtcCameraStreamer":return()=>fe(()=>import("./WebrtcCameraStreamer-CRSlmQer.js"),__vite__mapDeps([24,17,18,2,3,4,5,6,25]));case"WebrtcMediaMTX":return()=>fe(()=>import("./WebrtcMediaMTX-9dkGjohV.js"),__vite__mapDeps([26,2,3,4,5,6,27]));case"WebrtcGo2rtc":return()=>fe(()=>import("./WebrtcGo2rtc-DGvVGkMJ.js"),__vite__mapDeps([28,2,3,4,5,6,29]))}}const bs=s=>y.component(s,wT(s));var ST=Object.defineProperty,PT=Object.getOwnPropertyDescriptor,Ja=(s,e,t,r)=>{for(var i=r>1?void 0:r?PT(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&ST(e,t,i),i};let Vr=class extends k(L){get service(){var s,e;return(e=(s=this.webcam)==null?void 0:s.service)!=null?e:"unknown"}};Ja([w({type:Object,required:!0})],Vr.prototype,"webcam",2);Ja([w({type:Boolean,default:!0})],Vr.prototype,"showFps",2);Ja([w({default:null})],Vr.prototype,"printerUrl",2);Ja([w({type:String,default:null})],Vr.prototype,"page",2);Vr=Ja([S({components:{HlsstreamerAsync:bs("Hlsstreamer"),IpstreamerAsync:bs("Ipstreamer"),JanusStreamerAsync:bs("JanusStreamer"),JMuxerStreamAsync:bs("JMuxerStream"),MjpegstreamerAsync:bs("Mjpegstreamer"),MjpegstreamerAdaptiveAsync:bs("MjpegstreamerAdaptive"),Uv4lMjpegAsync:bs("Uv4lMjpeg"),WebrtcCameraStreamerAsync:bs("WebrtcCameraStreamer"),WebrtcMediaMTXAsync:bs("WebrtcMediaMTX"),WebrtcGo2rtcAsync:bs("WebrtcGo2rtc")}})],Vr);var DT=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e.service==="mjpegstreamer"?[t("mjpegstreamer-async",{attrs:{"cam-settings":e.webcam,"show-fps":e.showFps,"printer-url":e.printerUrl,page:e.page}})]:e.service==="mjpegstreamer-adaptive"?[t("mjpegstreamer-adaptive-async",{attrs:{"cam-settings":e.webcam,"show-fps":e.showFps,"printer-url":e.printerUrl}})]:e.service==="uv4l-mjpeg"?[t("uv4l-mjpeg-async",{attrs:{"cam-settings":e.webcam,"printer-url":e.printerUrl}})]:e.service==="ipstream"?[t("ipstreamer-async",{attrs:{"cam-settings":e.webcam,"printer-url":e.printerUrl}})]:e.service==="hlsstream"?[t("hlsstreamer-async",{attrs:{"cam-settings":e.webcam,"printer-url":e.printerUrl}})]:e.service==="jmuxer-stream"?[t("j-muxer-stream-async",{attrs:{"cam-settings":e.webcam,"printer-url":e.printerUrl}})]:e.service==="webrtc-camerastreamer"?[t("webrtc-camera-streamer-async",{attrs:{"cam-settings":e.webcam,"printer-url":e.printerUrl,page:e.page}})]:e.service==="webrtc-janus"?[t("janus-streamer-async",{attrs:{"cam-settings":e.webcam,"printer-url":e.printerUrl}})]:e.service==="webrtc-mediamtx"?[t("webrtc-media-m-t-x-async",{attrs:{"cam-settings":e.webcam,"printer-url":e.printerUrl,page:e.page}})]:e.service==="webrtc-go2rtc"?[t("webrtc-go2rtc-async",{attrs:{"cam-settings":e.webcam,"printer-url":e.printerUrl}})]:[t("p",{staticClass:"text-center py-3 font-italic"},[e._v(e._s(e.$t("Panels.WebcamPanel.UnknownWebcamService")))])]],2)},TT=[],OT=E(Vr,DT,TT,!1,null,"23c5e0fb");const Mm=OT.exports;var MT=Object.defineProperty,kT=Object.getOwnPropertyDescriptor,Ka=(s,e,t,r)=>{for(var i=r>1?void 0:r?kT(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&MT(e,t,i),i};let Br=class extends k(L){get webcams(){return this.$store.getters["gui/webcams/getWebcams"]}};Ka([w({type:Object,required:!0})],Br.prototype,"webcam",2);Ka([w({type:Boolean,default:!0})],Br.prototype,"showFps",2);Ka([w({type:String,default:null})],Br.prototype,"printerUrl",2);Ka([w({type:String,default:null})],Br.prototype,"page",2);Br=Ka([S({components:{WebcamWrapperItem:Mm}})],Br);var ET=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e.webcam.service==="grid"?[e.webcams?t(Ee,{staticClass:"pb-4",attrs:{fluid:""}},[t(x,{attrs:{dense:""}},e._l(e.webcams,function(r){return t(b,{key:r.name,attrs:{cols:"6"}},[t(Mm,{attrs:{webcam:r,"printer-url":e.printerUrl,"show-fps":e.showFps,page:e.page}})],1)}),1)],1):e._e()]:[t(Mm,{attrs:{webcam:e.webcam,"printer-url":e.printerUrl,"show-fps":e.showFps,page:e.page}})]],2)},LT=[],AT=E(Br,ET,LT,!1,null,"ecfdaad2");const Cu=AT.exports;var FT=Object.getOwnPropertyDescriptor,RT=(s,e,t,r)=>{for(var i=r>1?void 0:r?FT(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let ur=class extends k(L){convertUrl(s,e){var r,i,n,a,o,l,u,c;let t=new URL(s,this.hostUrl.toString());if(e!==null&&(t=new URL(s,e)),(s.startsWith("http")||s.startsWith("://"))&&(t=new URL(s)),s.startsWith("/webcam")){const d=[80];d.push((a=(n=(i=(r=this.$store.state.server.config)==null?void 0:r.config)==null?void 0:i.server)==null?void 0:n.port)!=null?a:7125),d.push((c=(u=(l=(o=this.$store.state.server.config)==null?void 0:o.config)==null?void 0:l.server)==null?void 0:u.ssl_port)!=null?c:7130),d.includes(this.hostPort)||(t.port=this.hostPort.toString())}return decodeURIComponent(t.toString())}convertWebcamIcon(s){switch(s){case"mdiAlbum":return dw;case"mdiCampfire":return yw;case"mdiDoor":return jw;case"mdiRadiatorDisabled":return yv;case"mdiPrinter3d":return qa;case"mdiPrinter3dNozzle":return Us;case"mdiRaspberryPi":return _S;default:return on}}generateTransform(s,e,t){let r="";return s&&(r+=" scaleX(-1)"),e&&(r+=" scaleY(-1)"),t===180&&(r+=" rotate(180deg)"),r.trimStart().length?r.trimStart():"none"}};ur=RT([S],ur);var HT=Object.defineProperty,jT=Object.getOwnPropertyDescriptor,uf=(s,e,t,r)=>{for(var i=r>1?void 0:r?jT(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&HT(e,t,i),i};let aa=class extends k(L,ur){constructor(){super(...arguments),this.mdiPencil=bt,this.mdiDelete=Ue,this.mdiMenuDown=gr,this.selectIcon=!1,this.valid=!1,this.oldWebcamName="",this.rules={required:s=>s!==""||this.$t("Settings.WebcamsTab.Required"),unique:s=>!this.existsWebcamName(s)||this.$t("Settings.WebcamsTab.NameAlreadyExists")}}get webcams(){var s,e;return(e=(s=this.$store.state.gui.webcams)==null?void 0:s.webcams)!=null?e:[]}get title(){return this.type==="create"?this.$t("Settings.WebcamsTab.CreateWebcam"):this.$t("Settings.WebcamsTab.EditWebcam")}get actionButtonText(){return this.type==="create"?this.$t("Settings.WebcamsTab.SaveWebcam"):this.$t("Settings.WebcamsTab.UpdateWebcam")}get rotationItems(){const s=[0,90,180,270],e=[];return s.forEach(t=>{e.push({value:t,text:"".concat(t,"°")})}),e}get rulesStreamUrl(){let s=[];return this.webcam.service!=="mjpegstreamer-adaptive"&&s.push(this.rules.required),s}get rulesSnapshotUrl(){let s=[];return this.webcam.service==="mjpegstreamer-adaptive"&&s.push(this.rules.required),s}get serviceItems(){return[{value:"mjpegstreamer",text:this.$t("Settings.WebcamsTab.Mjpegstreamer")},{value:"mjpegstreamer-adaptive",text:this.$t("Settings.WebcamsTab.MjpegstreamerAdaptive")},{value:"uv4l-mjpeg",text:this.$t("Settings.WebcamsTab.Uv4lMjpeg")},{value:"ipstream",text:this.$t("Settings.WebcamsTab.Ipstream")},{value:"webrtc-camerastreamer",text:this.$t("Settings.WebcamsTab.WebrtcCameraStreamer")},{value:"webrtc-go2rtc",text:this.$t("Settings.WebcamsTab.WebrtcGo2rtc")},{value:"webrtc-mediamtx",text:this.$t("Settings.WebcamsTab.WebrtcMediaMTX")},{value:"hlsstream",text:this.$t("Settings.WebcamsTab.Hlsstream")},{value:"jmuxer-stream",text:this.$t("Settings.WebcamsTab.JMuxerStream")},{value:"webrtc-janus",text:this.$t("Settings.WebcamsTab.WebrtcJanus")}]}get iconItems(){return[{value:"mdiPrinter3d",text:this.$t("Settings.WebcamsTab.IconPrinter")},{value:"mdiPrinter3dNozzle",text:this.$t("Settings.WebcamsTab.IconNozzle")},{value:"mdiRadiatorDisabled",text:this.$t("Settings.WebcamsTab.IconBed")},{value:"mdiWebcam",text:this.$t("Settings.WebcamsTab.IconCam")},{value:"mdiAlbum",text:this.$t("Settings.WebcamsTab.IconFilament")},{value:"mdiDoor",text:this.$t("Settings.WebcamsTab.IconDoor")},{value:"mdiRaspberryPi",text:this.$t("Settings.WebcamsTab.IconMcu")},{value:"mdiCampfire",text:this.$t("Settings.WebcamsTab.IconHot")}]}get classIconButtonArrow(){let s=["_transition"];return this.selectIcon&&s.push("_rotate-180"),s}get hasFpsCounter(){return["mjpegstreamer","mjpegstreamer-adaptive"].includes(this.webcam.service)}get hasAudioOption(){return["webrtc-go2rtc"].includes(this.webcam.service)}get hideFps(){var s,e;return(e=(s=this.webcam.extra_data)==null?void 0:s.hideFps)!=null?e:!1}set hideFps(s){if(!("extra_data"in this.webcam)){this.webcam.extra_data={hideFps:s};return}this.webcam.extra_data.hideFps=s}get enableAudio(){var s,e;return(e=(s=this.webcam.extra_data)==null?void 0:s.enableAudio)!=null?e:!1}set enableAudio(s){if(!("extra_data"in this.webcam)){this.webcam.extra_data={enableAudio:s};return}this.webcam.extra_data.enableAudio=s}get nozzleCrosshairAvialable(){return["mjpegstreamer","mjpegstreamer-adaptive","webrtc-camerastreamer"].includes(this.webcam.service)}get nozzleCrosshair(){var s,e;return(e=(s=this.webcam.extra_data)==null?void 0:s.nozzleCrosshair)!=null?e:!1}set nozzleCrosshair(s){var t;const e={...(t=this.webcam.extra_data)!=null?t:{}};e.nozzleCrosshair=s,this.webcam.extra_data=e}get nozzleCrosshairColor(){var s,e;return(e=(s=this.webcam.extra_data)==null?void 0:s.nozzleCrosshairColor)!=null?e:"#ff0000"}set nozzleCrosshairColor(s){var t;const e={...(t=this.webcam.extra_data)!=null?t:{}};e.nozzleCrosshairColor=s,this.webcam.extra_data=e}updateLogoColor(s){if(typeof s=="object"){this.nozzleCrosshairColor=s.hex;return}this.nozzleCrosshairColor=s}get nozzleCrosshairSize(){var s,e;return(e=(s=this.webcam.extra_data)==null?void 0:s.nozzleCrosshairSize)!=null?e:.1}set nozzleCrosshairSize(s){var t;const e={...(t=this.webcam.extra_data)!=null?t:{}};e.nozzleCrosshairSize=s,this.webcam.extra_data=e}mounted(){this.oldWebcamName=this.webcam.name}existsWebcamName(s){var t,r;s=s.toLowerCase().trim();const e=(r=(t=this.webcams.find(i=>i.name.toLowerCase().trim()===s))==null?void 0:t.length)!=null?r:0;return this.type==="create"?e!==0:e>=1}submit(){if(this.type==="create"){this.save();return}this.update()}async save(){await this.$store.dispatch("gui/webcams/store",this.webcam),this.$emit("close")}async update(){await this.$store.dispatch("gui/webcams/update",{webcam:this.webcam,oldWebcamName:this.oldWebcamName}),this.$emit("close")}closeForm(){this.$emit("close")}};uf([w({type:Object,required:!0})],aa.prototype,"webcam",2);uf([w({type:String,default:"create"})],aa.prototype,"type",2);aa=uf([S({components:{SettingsRow:j}})],aa);var IT=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(or,{ref:"webcamForm",on:{submit:function(r){return r.preventDefault(),e.submit.apply(null,arguments)}},model:{value:e.valid,callback:function(r){e.valid=r},expression:"valid"}},[t(gt,[e._v(e._s(e.title))]),t(Z,[t(x,[t(b,{staticClass:"col-12 col-sm-6"},[t(x,[t(b,{staticClass:"d-flex"},[t(Wt,[t(ye,{attrs:{"offset-y":!0,title:"Icon"},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"px-2 mr-2 _transition _menu-button",attrs:{color:"transparent",elevation:"0",ripple:!1}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.convertWebcamIcon(e.webcam.icon)))]),t(_,{staticClass:"pl-1 mr-n2",class:e.classIconButtonArrow},[e._v(" "+e._s(e.mdiMenuDown)+" ")])],1)]}}]),model:{value:e.selectIcon,callback:function(r){e.selectIcon=r},expression:"selectIcon"}},[t(Me,{staticClass:"py-0",attrs:{dense:""}},e._l(e.iconItems,function(r){return t(J,{key:r.value,attrs:{link:""},on:{click:function(i){e.webcam.icon=r.value}}},[t(Hs,{staticClass:"mr-2"},[t(_,{staticClass:"mt-1",attrs:{small:""}},[e._v(" "+e._s(e.convertWebcamIcon(r.value))+" ")])],1),t(_t,[t(Ze,{domProps:{textContent:e._s(r.text)}})],1)],1)}),1)],1)],1),t(se,{staticClass:"_webcam-settings-name-field",attrs:{label:e.$t("Settings.WebcamsTab.Name"),"hide-details":"auto",outlined:"",rules:[e.rules.required,e.rules.unique],dense:""},model:{value:e.webcam.name,callback:function(r){e.$set(e.webcam,"name",r)},expression:"webcam.name"}})],1)],1),t(x,[t(b,{staticClass:"py-2"},[t(se,{attrs:{label:e.$t("Settings.WebcamsTab.UrlStream"),"hide-details":"auto",outlined:"",dense:"",rules:e.rulesStreamUrl},model:{value:e.webcam.stream_url,callback:function(r){e.$set(e.webcam,"stream_url",r)},expression:"webcam.stream_url"}})],1)],1),t(x,[t(b,{staticClass:"py-2"},[t(se,{attrs:{label:e.$t("Settings.WebcamsTab.UrlSnapshot"),"hide-details":"auto",outlined:"",dense:"",rules:e.rulesSnapshotUrl},model:{value:e.webcam.snapshot_url,callback:function(r){e.$set(e.webcam,"snapshot_url",r)},expression:"webcam.snapshot_url"}})],1)],1),t(x,[t(b,{staticClass:"py-2"},[t(ke,{attrs:{items:e.serviceItems,"hide-details":"",outlined:"",dense:"",label:e.$t("Settings.WebcamsTab.Service")},model:{value:e.webcam.service,callback:function(r){e.$set(e.webcam,"service",r)},expression:"webcam.service"}})],1)],1),["mjpegstreamer-adaptive","jmuxer-stream"].includes(e.webcam.service)?t(x,[t(b,{staticClass:"py-2 col-6"},[t(se,{attrs:{outlined:"",dense:"","hide-details":"",label:e.$t("Settings.WebcamsTab.TargetFPS")},model:{value:e.webcam.target_fps,callback:function(r){e.$set(e.webcam,"target_fps",r)},expression:"webcam.target_fps"}})],1),t(b,{staticClass:"py-2 col-6"},[t(ke,{attrs:{items:e.rotationItems,outlined:"",dense:"","hide-details":"",label:e.$t("Settings.WebcamsTab.Rotate")},model:{value:e.webcam.rotation,callback:function(r){e.$set(e.webcam,"rotation",r)},expression:"webcam.rotation"}})],1)],1):e._e(),e.hasFpsCounter?t(x,[t(b,{staticClass:"pt-1 pb-3"},[t(ge,{staticClass:"mt-1",attrs:{"hide-details":"",label:e.$t("Settings.WebcamsTab.HideFps")},model:{value:e.hideFps,callback:function(r){e.hideFps=r},expression:"hideFps"}})],1)],1):e._e(),e.hasAudioOption?t(x,[t(b,{staticClass:"pt-1 pb-3"},[t(ge,{staticClass:"mt-1",attrs:{"hide-details":"",label:e.$t("Settings.WebcamsTab.EnableAudio")},model:{value:e.enableAudio,callback:function(r){e.enableAudio=r},expression:"enableAudio"}})],1)],1):e._e(),t(x,[t(b,{staticClass:"pt-1 pb-3"},[t("div",{staticClass:"v-label v-label--active theme--dark text-subtitle-1"},[e._v(" "+e._s(e.$t("Settings.WebcamsTab.FlipWebcam"))+" ")])])],1),t(x,{staticClass:"mt-0"},[t(b,{staticClass:"py-0"},[t(ge,{staticClass:"mt-1",attrs:{"hide-details":"",label:e.$t("Settings.WebcamsTab.Horizontally")},model:{value:e.webcam.flip_horizontal,callback:function(r){e.$set(e.webcam,"flip_horizontal",r)},expression:"webcam.flip_horizontal"}})],1),t(b,{staticClass:"py-0"},[t(ge,{staticClass:"mt-1",attrs:{"hide-details":"",label:e.$t("Settings.WebcamsTab.Vertically")},model:{value:e.webcam.flip_vertical,callback:function(r){e.$set(e.webcam,"flip_vertical",r)},expression:"webcam.flip_vertical"}})],1)],1),e.nozzleCrosshairAvialable?[t(x,[t(b,{staticClass:"pt-3 pb-3"},[t("div",{staticClass:"v-label v-label--active theme--dark text-subtitle-1"},[e._v(" "+e._s(e.$t("Settings.WebcamsTab.NozzleCrosshair"))+": ")])])],1),t(x,{staticClass:"mt-0"},[t(b,{staticClass:"py-0"},[t(ge,{staticClass:"mt-1",attrs:{"hide-details":"",label:e.$t("Settings.WebcamsTab.Enable")},model:{value:e.nozzleCrosshair,callback:function(r){e.nozzleCrosshair=r},expression:"nozzleCrosshair"}})],1),e.nozzleCrosshair?t(b,{staticClass:"py-0"},[t(ye,{attrs:{bottom:"",left:"","offset-y":"","close-on-content-click":!1},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"minwidth-0 px-5",attrs:{color:e.nozzleCrosshairColor,small:""}},"v-btn",i,!1),r))]}}],null,!1,3652875639)},[t(Xt,{attrs:{value:e.nozzleCrosshairColor,"hide-mode-switch":"",mode:"rgba"},on:{"update:color":e.updateLogoColor}})],1),t("div",{staticClass:"v-label v-label--active theme--dark text-subtitle-1 d-inline-block ml-2 mt-2"},[e._v(" "+e._s(e.$t("Settings.WebcamsTab.Color"))+" ")])],1):e._e()],1),e.nozzleCrosshair?t(x,[t(b,[t(Lr,{attrs:{max:1,min:.01,step:.01,"thumb-label":"","thumb-size":"24","hide-details":"",label:e.$t("Settings.WebcamsTab.Size")},model:{value:e.nozzleCrosshairSize,callback:function(r){e.nozzleCrosshairSize=r},expression:"nozzleCrosshairSize"}})],1)],1):e._e()]:e._e()],2),t(b,{staticClass:"col-12 col-sm-6 text-center",attrs:{"align-self":"center"}},[t(Cu,{attrs:{webcam:e.webcam,page:"settings"}})],1)],1)],1),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:""},on:{click:e.closeForm}},[e._v(e._s(e.$t("Settings.Cancel")))]),t(g,{attrs:{color:"primary",text:"",type:"submit",disabled:!e.valid}},[e._v(e._s(e.actionButtonText))])],1)],1)},NT=[],VT=E(aa,IT,NT,!1,null,"7419c62c");const bb=VT.exports;var BT=Object.defineProperty,UT=Object.getOwnPropertyDescriptor,df=(s,e,t,r)=>{for(var i=r>1?void 0:r?UT(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&BT(e,t,i),i};let oa=class extends k(L,ur){constructor(){super(...arguments),this.mdiPencil=bt,this.mdiDelete=Ue,this.mdiLightbulbOutline=zp}get icon(){return this.convertWebcamIcon(this.webcam.icon)}get subtitle(){return this.webcam.service==="mjpegstreamer-adaptive"?"URL: ".concat(this.webcam.snapshot_url):"URL: ".concat(this.webcam.stream_url)}toogleStatus(){let s={...this.webcam};s.enabled=!s.enabled,this.$store.dispatch("gui/webcams/update",{webcam:s,oldWebcamName:s.name})}edit(){this.$emit("edit-webcam",this.webcam)}deleteWebcam(){this.$store.dispatch("gui/webcams/delete",this.webcam.name)}};df([w({type:Object,default:()=>{}})],oa.prototype,"webcam",2);df([w({type:Boolean,default:!1})],oa.prototype,"boolBorderTop",2);oa=df([S({components:{SettingsRow:j}})],oa);var WT=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e.boolBorderTop?t(I,{staticClass:"my-2"}):e._e(),t(j,{attrs:{title:e.webcam.name,icon:e.icon,"sub-title":e.subtitle}},[e.webcam.source==="database"?[t(g,{staticClass:"minwidth-0 px-2",attrs:{small:"",outlined:"",color:e.webcam.enabled?"":"secondary"},on:{click:e.toogleStatus}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiLightbulbOutline))])],1),t(g,{staticClass:"ml-3",attrs:{small:"",outlined:""},on:{click:e.edit}},[t(_,{attrs:{small:"",left:""}},[e._v(e._s(e.mdiPencil))]),e._v(" "+e._s(e.$t("Settings.Edit"))+" ")],1),t(g,{staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:"error"},on:{click:e.deleteWebcam}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiDelete))])],1)]:e._e()],2)],1)},zT=[],GT=E(oa,WT,zT,!1,null,"a57386ad");const yb=GT.exports;var ZT=Object.getOwnPropertyDescriptor,qT=(s,e,t,r)=>{for(var i=r>1?void 0:r?ZT(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let km=class extends k(L,ur){constructor(){super(...arguments),this.mdiPencil=bt,this.mdiDelete=Ue,this.boolForm=!1,this.typeForm="create",this.formWebcam={}}get webcams(){var e;return(e=this.$store.state.gui.webcams.webcams)!=null?e:[]}get configfiles(){var e,t;return(t=(e=this.$store.getters["files/getDirectory"]("config"))==null?void 0:e.childrens)!=null?t:[]}get crowsnestConf(){return this.configfiles.find(e=>e.filename==="crowsnest.conf")}get existCrowsnestConf(){return this.configfiles.findIndex(e=>e.filename==="crowsnest.conf")!==-1}openCrowsnestConf(){var e,t,r;this.$store.dispatch("editor/openFile",{root:"config",path:"/",filename:(e=this.crowsnestConf)==null?void 0:e.filename,size:(t=this.crowsnestConf)==null?void 0:t.size,permissions:(r=this.crowsnestConf)==null?void 0:r.permissions})}createWebcam(){this.formWebcam={name:"",enabled:!0,icon:"mdiWebcam",service:"mjpegstreamer-adaptive",target_fps:15,target_fps_idle:15,stream_url:"/webcam/?action=stream",snapshot_url:"/webcam/?action=snapshot",rotation:0,flip_horizontal:!1,flip_vertical:!1,extra_data:{}},this.typeForm="create",this.boolForm=!0}closeForm(){this.boolForm=!1}editWebcam(e){this.formWebcam={...e},this.typeForm="edit",this.boolForm=!0}};km=qT([S({components:{SettingsRow:j,WebcamForm:bb,WebcamListEntry:yb}})],km);var XT=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e.boolForm?t(Pe,{attrs:{flat:""}},[t(bb,{attrs:{webcam:e.formWebcam,type:e.typeForm},on:{close:e.closeForm}})],1):t(Pe,{attrs:{flat:""}},[t(Z,[t("h3",{staticClass:"text-h5 mb-3"},[e._v(e._s(e.$t("Settings.WebcamsTab.Webcams")))]),e._l(e.webcams,function(r,i){return t(yb,{key:r.name,attrs:{webcam:r,"bool-border-top":i>0},on:{"edit-webcam":e.editWebcam}})})],2),t(oe,[e.existCrowsnestConf?t(g,{attrs:{text:"",color:"primary"},on:{click:e.openCrowsnestConf}},[e._v(" "+e._s(e.$t("Settings.WebcamsTab.EditCrowsnestConf"))+" ")]):e._e(),t(ae),t(g,{attrs:{text:"",color:"primary"},on:{click:e.createWebcam}},[e._v(e._s(e.$t("Settings.WebcamsTab.AddWebcam")))])],1)],1)],1)},YT=[],JT=E(km,XT,YT,!1,null,null);const KT=JT.exports;var QT=Object.getOwnPropertyDescriptor,eO=(s,e,t,r)=>{for(var i=r>1?void 0:r?QT(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Em=class extends k(L){constructor(){super(...arguments),this.mdiMagnify=rn,this.searchMacros=""}get macros(){var e;return((e=this.$store.getters["printer/getMacros"])!=null?e:[]).filter(t=>{var r;return t.name.toLowerCase().includes(this.searchMacros.toLowerCase())||((r=t.description)==null?void 0:r.toLowerCase().includes(this.searchMacros.toLowerCase()))})}get hiddenMacros(){var s;return(s=this.$store.state.gui.macros.hiddenMacros)!=null?s:[]}getMacroStatus(s){return!this.hiddenMacros.includes(s.toUpperCase())}changeMacroStatus(s){const e=[...this.hiddenMacros];this.hiddenMacros.includes(s.toUpperCase())?e.splice(e.indexOf(s.toUpperCase()),1):e.push(s.toUpperCase()),this.$store.dispatch("gui/macros/saveSetting",{name:"hiddenMacros",value:e})}};Em=eO([S({components:{SettingsRow:j}})],Em);var tO=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Z,[t(x,{staticClass:"mt-6 mb-3 flex-column flex-md-row"},[t(b,{staticClass:"py-0 align-content-center mb-3 mb-md-0"},[t("h3",{staticClass:"text-h5"},[e._v(e._s(e.$t("Settings.MacrosTab.Macros")))])]),t(b,{staticClass:"py-0"},[t(se,{attrs:{"append-icon":e.mdiMagnify,label:e.$t("Settings.MacrosTab.Search"),"single-line":"",outlined:"",clearable:"","hide-details":"",dense:""},model:{value:e.searchMacros,callback:function(r){e.searchMacros=r},expression:"searchMacros"}})],1)],1),e.macros.length?[e._l(e.macros,function(r,i){return[i?t(I,{key:i+"_divider",staticClass:"my-2"}):e._e(),t(j,{key:i,attrs:{title:r.name,"sub-title":r.description,"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"input-value":e.getMacroStatus(r.name),"hide-details":""},on:{change:function(n){return e.changeMacroStatus(r.name)}}})],1)]})]:t(x,[t(b,[t("p",{staticClass:"mb-0 text-center font-italic"},[e._v(e._s(e.$t("Settings.MacrosTab.NOMacros")))])])],1)],2)},sO=[],rO=E(Em,tO,sO,!1,null,null);const Cb=rO.exports;var $b={exports:{}};/**!
|
||
* Sortable 1.10.2
|
||
* @author RubaXa <trash@rubaxa.org>
|
||
* @author owenm <owen23355@gmail.com>
|
||
* @license MIT
|
||
*/function No(s){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?No=function(e){return typeof e}:No=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},No(s)}function iO(s,e,t){return e in s?Object.defineProperty(s,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):s[e]=t,s}function es(){return es=Object.assign||function(s){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(s[r]=t[r])}return s},es.apply(this,arguments)}function dr(s){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{},r=Object.keys(t);typeof Object.getOwnPropertySymbols=="function"&&(r=r.concat(Object.getOwnPropertySymbols(t).filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable}))),r.forEach(function(i){iO(s,i,t[i])})}return s}function nO(s,e){if(s==null)return{};var t={},r=Object.keys(s),i,n;for(n=0;n<r.length;n++)i=r[n],!(e.indexOf(i)>=0)&&(t[i]=s[i]);return t}function aO(s,e){if(s==null)return{};var t=nO(s,e),r,i;if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(s);for(i=0;i<n.length;i++)r=n[i],!(e.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(s,r)&&(t[r]=s[r])}return t}function oO(s){return lO(s)||cO(s)||uO()}function lO(s){if(Array.isArray(s)){for(var e=0,t=new Array(s.length);e<s.length;e++)t[e]=s[e];return t}}function cO(s){if(Symbol.iterator in Object(s)||Object.prototype.toString.call(s)==="[object Arguments]")return Array.from(s)}function uO(){throw new TypeError("Invalid attempt to spread non-iterable instance")}var dO="1.10.2";function As(s){if(typeof window<"u"&&window.navigator)return!!navigator.userAgent.match(s)}var Ws=As(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),Qa=As(/Edge/i),Zg=As(/firefox/i),Lm=As(/safari/i)&&!As(/chrome/i)&&!As(/android/i),xb=As(/iP(ad|od|hone)/i),mO=As(/chrome/i)&&As(/android/i),wb={capture:!1,passive:!1};function Oe(s,e,t){s.addEventListener(e,t,!Ws&&wb)}function De(s,e,t){s.removeEventListener(e,t,!Ws&&wb)}function kl(s,e){if(e){if(e[0]===">"&&(e=e.substring(1)),s)try{if(s.matches)return s.matches(e);if(s.msMatchesSelector)return s.msMatchesSelector(e);if(s.webkitMatchesSelector)return s.webkitMatchesSelector(e)}catch{return!1}return!1}}function hO(s){return s.host&&s!==document&&s.host.nodeType?s.host:s.parentNode}function os(s,e,t,r){if(s){t=t||document;do{if(e!=null&&(e[0]===">"?s.parentNode===t&&kl(s,e):kl(s,e))||r&&s===t)return s;if(s===t)break}while(s=hO(s))}return null}var qg=/\s+/g;function Ve(s,e,t){if(s&&e)if(s.classList)s.classList[t?"add":"remove"](e);else{var r=(" "+s.className+" ").replace(qg," ").replace(" "+e+" "," ");s.className=(r+(t?" "+e:"")).replace(qg," ")}}function me(s,e,t){var r=s&&s.style;if(r){if(t===void 0)return document.defaultView&&document.defaultView.getComputedStyle?t=document.defaultView.getComputedStyle(s,""):s.currentStyle&&(t=s.currentStyle),e===void 0?t:t[e];!(e in r)&&e.indexOf("webkit")===-1&&(e="-webkit-"+e),r[e]=t+(typeof t=="string"?"":"px")}}function Ar(s,e){var t="";if(typeof s=="string")t=s;else do{var r=me(s,"transform");r&&r!=="none"&&(t=r+" "+t)}while(!e&&(s=s.parentNode));var i=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return i&&new i(t)}function Sb(s,e,t){if(s){var r=s.getElementsByTagName(e),i=0,n=r.length;if(t)for(;i<n;i++)t(r[i],i);return r}return[]}function xs(){var s=document.scrollingElement;return s||document.documentElement}function Ge(s,e,t,r,i){if(!(!s.getBoundingClientRect&&s!==window)){var n,a,o,l,u,c,d;if(s!==window&&s!==xs()?(n=s.getBoundingClientRect(),a=n.top,o=n.left,l=n.bottom,u=n.right,c=n.height,d=n.width):(a=0,o=0,l=window.innerHeight,u=window.innerWidth,c=window.innerHeight,d=window.innerWidth),(e||t)&&s!==window&&(i=i||s.parentNode,!Ws))do if(i&&i.getBoundingClientRect&&(me(i,"transform")!=="none"||t&&me(i,"position")!=="static")){var m=i.getBoundingClientRect();a-=m.top+parseInt(me(i,"border-top-width")),o-=m.left+parseInt(me(i,"border-left-width")),l=a+n.height,u=o+n.width;break}while(i=i.parentNode);if(r&&s!==window){var h=Ar(i||s),f=h&&h.a,p=h&&h.d;h&&(a/=p,o/=f,d/=f,c/=p,l=a+c,u=o+d)}return{top:a,left:o,bottom:l,right:u,width:d,height:c}}}function Xg(s,e,t){for(var r=Js(s,!0),i=Ge(s)[e];r;){var n=Ge(r)[t],a=void 0;if(a=i>=n,!a)return r;if(r===xs())break;r=Js(r,!1)}return!1}function El(s,e,t){for(var r=0,i=0,n=s.children;i<n.length;){if(n[i].style.display!=="none"&&n[i]!==_e.ghost&&n[i]!==_e.dragged&&os(n[i],t.draggable,s,!1)){if(r===e)return n[i];r++}i++}return null}function mf(s,e){for(var t=s.lastElementChild;t&&(t===_e.ghost||me(t,"display")==="none"||e&&!kl(t,e));)t=t.previousElementSibling;return t||null}function ze(s,e){var t=0;if(!s||!s.parentNode)return-1;for(;s=s.previousElementSibling;)s.nodeName.toUpperCase()!=="TEMPLATE"&&s!==_e.clone&&(!e||kl(s,e))&&t++;return t}function Yg(s){var e=0,t=0,r=xs();if(s)do{var i=Ar(s),n=i.a,a=i.d;e+=s.scrollLeft*n,t+=s.scrollTop*a}while(s!==r&&(s=s.parentNode));return[e,t]}function pO(s,e){for(var t in s)if(s.hasOwnProperty(t)){for(var r in e)if(e.hasOwnProperty(r)&&e[r]===s[t][r])return Number(t)}return-1}function Js(s,e){if(!s||!s.getBoundingClientRect)return xs();var t=s,r=!1;do if(t.clientWidth<t.scrollWidth||t.clientHeight<t.scrollHeight){var i=me(t);if(t.clientWidth<t.scrollWidth&&(i.overflowX=="auto"||i.overflowX=="scroll")||t.clientHeight<t.scrollHeight&&(i.overflowY=="auto"||i.overflowY=="scroll")){if(!t.getBoundingClientRect||t===document.body)return xs();if(r||e)return t;r=!0}}while(t=t.parentNode);return xs()}function fO(s,e){if(s&&e)for(var t in e)e.hasOwnProperty(t)&&(s[t]=e[t]);return s}function kd(s,e){return Math.round(s.top)===Math.round(e.top)&&Math.round(s.left)===Math.round(e.left)&&Math.round(s.height)===Math.round(e.height)&&Math.round(s.width)===Math.round(e.width)}var Bn;function Pb(s,e){return function(){if(!Bn){var t=arguments,r=this;t.length===1?s.call(r,t[0]):s.apply(r,t),Bn=setTimeout(function(){Bn=void 0},e)}}}function gO(){clearTimeout(Bn),Bn=void 0}function Db(s,e,t){s.scrollLeft+=e,s.scrollTop+=t}function hf(s){var e=window.Polymer,t=window.jQuery||window.Zepto;return e&&e.dom?e.dom(s).cloneNode(!0):t?t(s).clone(!0)[0]:s.cloneNode(!0)}function Jg(s,e){me(s,"position","absolute"),me(s,"top",e.top),me(s,"left",e.left),me(s,"width",e.width),me(s,"height",e.height)}function Ed(s){me(s,"position",""),me(s,"top",""),me(s,"left",""),me(s,"width",""),me(s,"height","")}var pt="Sortable"+new Date().getTime();function _O(){var s=[],e;return{captureAnimationState:function(){if(s=[],!!this.options.animation){var r=[].slice.call(this.el.children);r.forEach(function(i){if(!(me(i,"display")==="none"||i===_e.ghost)){s.push({target:i,rect:Ge(i)});var n=dr({},s[s.length-1].rect);if(i.thisAnimationDuration){var a=Ar(i,!0);a&&(n.top-=a.f,n.left-=a.e)}i.fromRect=n}})}},addAnimationState:function(r){s.push(r)},removeAnimationState:function(r){s.splice(pO(s,{target:r}),1)},animateAll:function(r){var i=this;if(!this.options.animation){clearTimeout(e),typeof r=="function"&&r();return}var n=!1,a=0;s.forEach(function(o){var l=0,u=o.target,c=u.fromRect,d=Ge(u),m=u.prevFromRect,h=u.prevToRect,f=o.rect,p=Ar(u,!0);p&&(d.top-=p.f,d.left-=p.e),u.toRect=d,u.thisAnimationDuration&&kd(m,d)&&!kd(c,d)&&(f.top-d.top)/(f.left-d.left)===(c.top-d.top)/(c.left-d.left)&&(l=bO(f,m,h,i.options)),kd(d,c)||(u.prevFromRect=c,u.prevToRect=d,l||(l=i.options.animation),i.animate(u,f,d,l)),l&&(n=!0,a=Math.max(a,l),clearTimeout(u.animationResetTimer),u.animationResetTimer=setTimeout(function(){u.animationTime=0,u.prevFromRect=null,u.fromRect=null,u.prevToRect=null,u.thisAnimationDuration=null},l),u.thisAnimationDuration=l)}),clearTimeout(e),n?e=setTimeout(function(){typeof r=="function"&&r()},a):typeof r=="function"&&r(),s=[]},animate:function(r,i,n,a){if(a){me(r,"transition",""),me(r,"transform","");var o=Ar(this.el),l=o&&o.a,u=o&&o.d,c=(i.left-n.left)/(l||1),d=(i.top-n.top)/(u||1);r.animatingX=!!c,r.animatingY=!!d,me(r,"transform","translate3d("+c+"px,"+d+"px,0)"),vO(r),me(r,"transition","transform "+a+"ms"+(this.options.easing?" "+this.options.easing:"")),me(r,"transform","translate3d(0,0,0)"),typeof r.animated=="number"&&clearTimeout(r.animated),r.animated=setTimeout(function(){me(r,"transition",""),me(r,"transform",""),r.animated=!1,r.animatingX=!1,r.animatingY=!1},a)}}}}function vO(s){return s.offsetWidth}function bO(s,e,t,r){return Math.sqrt(Math.pow(e.top-s.top,2)+Math.pow(e.left-s.left,2))/Math.sqrt(Math.pow(e.top-t.top,2)+Math.pow(e.left-t.left,2))*r.animation}var Cn=[],Ld={initializeByDefault:!0},eo={mount:function(e){for(var t in Ld)Ld.hasOwnProperty(t)&&!(t in e)&&(e[t]=Ld[t]);Cn.push(e)},pluginEvent:function(e,t,r){var i=this;this.eventCanceled=!1,r.cancel=function(){i.eventCanceled=!0};var n=e+"Global";Cn.forEach(function(a){t[a.pluginName]&&(t[a.pluginName][n]&&t[a.pluginName][n](dr({sortable:t},r)),t.options[a.pluginName]&&t[a.pluginName][e]&&t[a.pluginName][e](dr({sortable:t},r)))})},initializePlugins:function(e,t,r,i){Cn.forEach(function(o){var l=o.pluginName;if(!(!e.options[l]&&!o.initializeByDefault)){var u=new o(e,t,e.options);u.sortable=e,u.options=e.options,e[l]=u,es(r,u.defaults)}});for(var n in e.options)if(e.options.hasOwnProperty(n)){var a=this.modifyOption(e,n,e.options[n]);typeof a<"u"&&(e.options[n]=a)}},getEventProperties:function(e,t){var r={};return Cn.forEach(function(i){typeof i.eventProperties=="function"&&es(r,i.eventProperties.call(t[i.pluginName],e))}),r},modifyOption:function(e,t,r){var i;return Cn.forEach(function(n){e[n.pluginName]&&n.optionListeners&&typeof n.optionListeners[t]=="function"&&(i=n.optionListeners[t].call(e[n.pluginName],r))}),i}};function An(s){var e=s.sortable,t=s.rootEl,r=s.name,i=s.targetEl,n=s.cloneEl,a=s.toEl,o=s.fromEl,l=s.oldIndex,u=s.newIndex,c=s.oldDraggableIndex,d=s.newDraggableIndex,m=s.originalEvent,h=s.putSortable,f=s.extraEventProperties;if(e=e||t&&t[pt],!!e){var p,v=e.options,C="on"+r.charAt(0).toUpperCase()+r.substr(1);window.CustomEvent&&!Ws&&!Qa?p=new CustomEvent(r,{bubbles:!0,cancelable:!0}):(p=document.createEvent("Event"),p.initEvent(r,!0,!0)),p.to=a||t,p.from=o||t,p.item=i||t,p.clone=n,p.oldIndex=l,p.newIndex=u,p.oldDraggableIndex=c,p.newDraggableIndex=d,p.originalEvent=m,p.pullMode=h?h.lastPutMode:void 0;var P=dr({},f,eo.getEventProperties(r,e));for(var M in P)p[M]=P[M];t&&t.dispatchEvent(p),v[C]&&v[C].call(e,p)}}var Dt=function(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=r.evt,n=aO(r,["evt"]);eo.pluginEvent.bind(_e)(e,t,dr({dragEl:ne,parentEl:Qe,ghostEl:$e,rootEl:Ne,nextEl:Sr,lastDownEl:Vo,cloneEl:We,cloneHidden:Xs,dragStarted:Fn,putSortable:ut,activeSortable:_e.active,originalEvent:i,oldIndex:_i,oldDraggableIndex:Un,newIndex:Bt,newDraggableIndex:qs,hideGhostForTarget:kb,unhideGhostForTarget:Eb,cloneNowHidden:function(){Xs=!0},cloneNowShown:function(){Xs=!1},dispatchSortableEvent:function(o){yt({sortable:t,name:o,originalEvent:i})}},n))};function yt(s){An(dr({putSortable:ut,cloneEl:We,targetEl:ne,rootEl:Ne,oldIndex:_i,oldDraggableIndex:Un,newIndex:Bt,newDraggableIndex:qs},s))}var ne,Qe,$e,Ne,Sr,Vo,We,Xs,_i,Bt,Un,qs,xo,ut,gi=!1,Ll=!1,Al=[],Cr,is,Ad,Fd,Kg,Qg,Fn,li,Wn,zn=!1,wo=!1,Bo,ht,Rd=[],Am=!1,Fl=[],$u=typeof document<"u",So=xb,e1=Qa||Ws?"cssFloat":"float",yO=$u&&!mO&&!xb&&"draggable"in document.createElement("div"),Tb=function(){if($u){if(Ws)return!1;var s=document.createElement("x");return s.style.cssText="pointer-events:auto",s.style.pointerEvents==="auto"}}(),Ob=function(e,t){var r=me(e),i=parseInt(r.width)-parseInt(r.paddingLeft)-parseInt(r.paddingRight)-parseInt(r.borderLeftWidth)-parseInt(r.borderRightWidth),n=El(e,0,t),a=El(e,1,t),o=n&&me(n),l=a&&me(a),u=o&&parseInt(o.marginLeft)+parseInt(o.marginRight)+Ge(n).width,c=l&&parseInt(l.marginLeft)+parseInt(l.marginRight)+Ge(a).width;if(r.display==="flex")return r.flexDirection==="column"||r.flexDirection==="column-reverse"?"vertical":"horizontal";if(r.display==="grid")return r.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(n&&o.float&&o.float!=="none"){var d=o.float==="left"?"left":"right";return a&&(l.clear==="both"||l.clear===d)?"vertical":"horizontal"}return n&&(o.display==="block"||o.display==="flex"||o.display==="table"||o.display==="grid"||u>=i&&r[e1]==="none"||a&&r[e1]==="none"&&u+c>i)?"vertical":"horizontal"},CO=function(e,t,r){var i=r?e.left:e.top,n=r?e.right:e.bottom,a=r?e.width:e.height,o=r?t.left:t.top,l=r?t.right:t.bottom,u=r?t.width:t.height;return i===o||n===l||i+a/2===o+u/2},$O=function(e,t){var r;return Al.some(function(i){if(!mf(i)){var n=Ge(i),a=i[pt].options.emptyInsertThreshold,o=e>=n.left-a&&e<=n.right+a,l=t>=n.top-a&&t<=n.bottom+a;if(a&&o&&l)return r=i}}),r},Mb=function(e){function t(n,a){return function(o,l,u,c){var d=o.options.group.name&&l.options.group.name&&o.options.group.name===l.options.group.name;if(n==null&&(a||d))return!0;if(n==null||n===!1)return!1;if(a&&n==="clone")return n;if(typeof n=="function")return t(n(o,l,u,c),a)(o,l,u,c);var m=(a?o:l).options.group.name;return n===!0||typeof n=="string"&&n===m||n.join&&n.indexOf(m)>-1}}var r={},i=e.group;(!i||No(i)!="object")&&(i={name:i}),r.name=i.name,r.checkPull=t(i.pull,!0),r.checkPut=t(i.put),r.revertClone=i.revertClone,e.group=r},kb=function(){!Tb&&$e&&me($e,"display","none")},Eb=function(){!Tb&&$e&&me($e,"display","")};$u&&document.addEventListener("click",function(s){if(Ll)return s.preventDefault(),s.stopPropagation&&s.stopPropagation(),s.stopImmediatePropagation&&s.stopImmediatePropagation(),Ll=!1,!1},!0);var $r=function(e){if(ne){e=e.touches?e.touches[0]:e;var t=$O(e.clientX,e.clientY);if(t){var r={};for(var i in e)e.hasOwnProperty(i)&&(r[i]=e[i]);r.target=r.rootEl=t,r.preventDefault=void 0,r.stopPropagation=void 0,t[pt]._onDragOver(r)}}},xO=function(e){ne&&ne.parentNode[pt]._isOutsideThisEl(e.target)};function _e(s,e){if(!(s&&s.nodeType&&s.nodeType===1))throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(s));this.el=s,this.options=e=es({},e),s[pt]=this;var t={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(s.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return Ob(s,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(a,o){a.setData("Text",o.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:_e.supportPointer!==!1&&"PointerEvent"in window,emptyInsertThreshold:5};eo.initializePlugins(this,s,t);for(var r in t)!(r in e)&&(e[r]=t[r]);Mb(e);for(var i in this)i.charAt(0)==="_"&&typeof this[i]=="function"&&(this[i]=this[i].bind(this));this.nativeDraggable=e.forceFallback?!1:yO,this.nativeDraggable&&(this.options.touchStartThreshold=1),e.supportPointer?Oe(s,"pointerdown",this._onTapStart):(Oe(s,"mousedown",this._onTapStart),Oe(s,"touchstart",this._onTapStart)),this.nativeDraggable&&(Oe(s,"dragover",this),Oe(s,"dragenter",this)),Al.push(this.el),e.store&&e.store.get&&this.sort(e.store.get(this)||[]),es(this,_O())}_e.prototype={constructor:_e,_isOutsideThisEl:function(e){!this.el.contains(e)&&e!==this.el&&(li=null)},_getDirection:function(e,t){return typeof this.options.direction=="function"?this.options.direction.call(this,e,t,ne):this.options.direction},_onTapStart:function(e){if(e.cancelable){var t=this,r=this.el,i=this.options,n=i.preventOnFilter,a=e.type,o=e.touches&&e.touches[0]||e.pointerType&&e.pointerType==="touch"&&e,l=(o||e).target,u=e.target.shadowRoot&&(e.path&&e.path[0]||e.composedPath&&e.composedPath()[0])||l,c=i.filter;if(MO(r),!ne&&!(/mousedown|pointerdown/.test(a)&&e.button!==0||i.disabled)&&!u.isContentEditable&&(l=os(l,i.draggable,r,!1),!(l&&l.animated)&&Vo!==l)){if(_i=ze(l),Un=ze(l,i.draggable),typeof c=="function"){if(c.call(this,e,l,this)){yt({sortable:t,rootEl:u,name:"filter",targetEl:l,toEl:r,fromEl:r}),Dt("filter",t,{evt:e}),n&&e.cancelable&&e.preventDefault();return}}else if(c&&(c=c.split(",").some(function(d){if(d=os(u,d.trim(),r,!1),d)return yt({sortable:t,rootEl:d,name:"filter",targetEl:l,fromEl:r,toEl:r}),Dt("filter",t,{evt:e}),!0}),c)){n&&e.cancelable&&e.preventDefault();return}i.handle&&!os(u,i.handle,r,!1)||this._prepareDragStart(e,o,l)}}},_prepareDragStart:function(e,t,r){var i=this,n=i.el,a=i.options,o=n.ownerDocument,l;if(r&&!ne&&r.parentNode===n){var u=Ge(r);if(Ne=n,ne=r,Qe=ne.parentNode,Sr=ne.nextSibling,Vo=r,xo=a.group,_e.dragged=ne,Cr={target:ne,clientX:(t||e).clientX,clientY:(t||e).clientY},Kg=Cr.clientX-u.left,Qg=Cr.clientY-u.top,this._lastX=(t||e).clientX,this._lastY=(t||e).clientY,ne.style["will-change"]="all",l=function(){if(Dt("delayEnded",i,{evt:e}),_e.eventCanceled){i._onDrop();return}i._disableDelayedDragEvents(),!Zg&&i.nativeDraggable&&(ne.draggable=!0),i._triggerDragStart(e,t),yt({sortable:i,name:"choose",originalEvent:e}),Ve(ne,a.chosenClass,!0)},a.ignore.split(",").forEach(function(c){Sb(ne,c.trim(),jd)}),Oe(o,"dragover",$r),Oe(o,"mousemove",$r),Oe(o,"touchmove",$r),Oe(o,"mouseup",i._onDrop),Oe(o,"touchend",i._onDrop),Oe(o,"touchcancel",i._onDrop),Zg&&this.nativeDraggable&&(this.options.touchStartThreshold=4,ne.draggable=!0),Dt("delayStart",this,{evt:e}),a.delay&&(!a.delayOnTouchOnly||t)&&(!this.nativeDraggable||!(Qa||Ws))){if(_e.eventCanceled){this._onDrop();return}Oe(o,"mouseup",i._disableDelayedDrag),Oe(o,"touchend",i._disableDelayedDrag),Oe(o,"touchcancel",i._disableDelayedDrag),Oe(o,"mousemove",i._delayedDragTouchMoveHandler),Oe(o,"touchmove",i._delayedDragTouchMoveHandler),a.supportPointer&&Oe(o,"pointermove",i._delayedDragTouchMoveHandler),i._dragStartTimer=setTimeout(l,a.delay)}else l()}},_delayedDragTouchMoveHandler:function(e){var t=e.touches?e.touches[0]:e;Math.max(Math.abs(t.clientX-this._lastX),Math.abs(t.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){ne&&jd(ne),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var e=this.el.ownerDocument;De(e,"mouseup",this._disableDelayedDrag),De(e,"touchend",this._disableDelayedDrag),De(e,"touchcancel",this._disableDelayedDrag),De(e,"mousemove",this._delayedDragTouchMoveHandler),De(e,"touchmove",this._delayedDragTouchMoveHandler),De(e,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(e,t){t=t||e.pointerType=="touch"&&e,!this.nativeDraggable||t?this.options.supportPointer?Oe(document,"pointermove",this._onTouchMove):t?Oe(document,"touchmove",this._onTouchMove):Oe(document,"mousemove",this._onTouchMove):(Oe(ne,"dragend",this),Oe(Ne,"dragstart",this._onDragStart));try{document.selection?Uo(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch{}},_dragStarted:function(e,t){if(gi=!1,Ne&&ne){Dt("dragStarted",this,{evt:t}),this.nativeDraggable&&Oe(document,"dragover",xO);var r=this.options;!e&&Ve(ne,r.dragClass,!1),Ve(ne,r.ghostClass,!0),_e.active=this,e&&this._appendGhost(),yt({sortable:this,name:"start",originalEvent:t})}else this._nulling()},_emulateDragOver:function(){if(is){this._lastX=is.clientX,this._lastY=is.clientY,kb();for(var e=document.elementFromPoint(is.clientX,is.clientY),t=e;e&&e.shadowRoot&&(e=e.shadowRoot.elementFromPoint(is.clientX,is.clientY),e!==t);)t=e;if(ne.parentNode[pt]._isOutsideThisEl(e),t)do{if(t[pt]){var r=void 0;if(r=t[pt]._onDragOver({clientX:is.clientX,clientY:is.clientY,target:e,rootEl:t}),r&&!this.options.dragoverBubble)break}e=t}while(t=t.parentNode);Eb()}},_onTouchMove:function(e){if(Cr){var t=this.options,r=t.fallbackTolerance,i=t.fallbackOffset,n=e.touches?e.touches[0]:e,a=$e&&Ar($e,!0),o=$e&&a&&a.a,l=$e&&a&&a.d,u=So&&ht&&Yg(ht),c=(n.clientX-Cr.clientX+i.x)/(o||1)+(u?u[0]-Rd[0]:0)/(o||1),d=(n.clientY-Cr.clientY+i.y)/(l||1)+(u?u[1]-Rd[1]:0)/(l||1);if(!_e.active&&!gi){if(r&&Math.max(Math.abs(n.clientX-this._lastX),Math.abs(n.clientY-this._lastY))<r)return;this._onDragStart(e,!0)}if($e){a?(a.e+=c-(Ad||0),a.f+=d-(Fd||0)):a={a:1,b:0,c:0,d:1,e:c,f:d};var m="matrix(".concat(a.a,",").concat(a.b,",").concat(a.c,",").concat(a.d,",").concat(a.e,",").concat(a.f,")");me($e,"webkitTransform",m),me($e,"mozTransform",m),me($e,"msTransform",m),me($e,"transform",m),Ad=c,Fd=d,is=n}e.cancelable&&e.preventDefault()}},_appendGhost:function(){if(!$e){var e=this.options.fallbackOnBody?document.body:Ne,t=Ge(ne,!0,So,!0,e),r=this.options;if(So){for(ht=e;me(ht,"position")==="static"&&me(ht,"transform")==="none"&&ht!==document;)ht=ht.parentNode;ht!==document.body&&ht!==document.documentElement?(ht===document&&(ht=xs()),t.top+=ht.scrollTop,t.left+=ht.scrollLeft):ht=xs(),Rd=Yg(ht)}$e=ne.cloneNode(!0),Ve($e,r.ghostClass,!1),Ve($e,r.fallbackClass,!0),Ve($e,r.dragClass,!0),me($e,"transition",""),me($e,"transform",""),me($e,"box-sizing","border-box"),me($e,"margin",0),me($e,"top",t.top),me($e,"left",t.left),me($e,"width",t.width),me($e,"height",t.height),me($e,"opacity","0.8"),me($e,"position",So?"absolute":"fixed"),me($e,"zIndex","100000"),me($e,"pointerEvents","none"),_e.ghost=$e,e.appendChild($e),me($e,"transform-origin",Kg/parseInt($e.style.width)*100+"% "+Qg/parseInt($e.style.height)*100+"%")}},_onDragStart:function(e,t){var r=this,i=e.dataTransfer,n=r.options;if(Dt("dragStart",this,{evt:e}),_e.eventCanceled){this._onDrop();return}Dt("setupClone",this),_e.eventCanceled||(We=hf(ne),We.draggable=!1,We.style["will-change"]="",this._hideClone(),Ve(We,this.options.chosenClass,!1),_e.clone=We),r.cloneId=Uo(function(){Dt("clone",r),!_e.eventCanceled&&(r.options.removeCloneOnHide||Ne.insertBefore(We,ne),r._hideClone(),yt({sortable:r,name:"clone"}))}),!t&&Ve(ne,n.dragClass,!0),t?(Ll=!0,r._loopId=setInterval(r._emulateDragOver,50)):(De(document,"mouseup",r._onDrop),De(document,"touchend",r._onDrop),De(document,"touchcancel",r._onDrop),i&&(i.effectAllowed="move",n.setData&&n.setData.call(r,i,ne)),Oe(document,"drop",r),me(ne,"transform","translateZ(0)")),gi=!0,r._dragStartId=Uo(r._dragStarted.bind(r,t,e)),Oe(document,"selectstart",r),Fn=!0,Lm&&me(document.body,"user-select","none")},_onDragOver:function(e){var t=this.el,r=e.target,i,n,a,o=this.options,l=o.group,u=_e.active,c=xo===l,d=o.sort,m=ut||u,h,f=this,p=!1;if(Am)return;function v(Q,re){Dt(Q,f,dr({evt:e,isOwner:c,axis:h?"vertical":"horizontal",revert:a,dragRect:i,targetRect:n,canSort:d,fromSortable:m,target:r,completed:P,onMove:function(B,T){return Hd(Ne,t,ne,i,B,Ge(B),e,T)},changed:M},re))}function C(){v("dragOverAnimationCapture"),f.captureAnimationState(),f!==m&&m.captureAnimationState()}function P(Q){return v("dragOverCompleted",{insertion:Q}),Q&&(c?u._hideClone():u._showClone(f),f!==m&&(Ve(ne,ut?ut.options.ghostClass:u.options.ghostClass,!1),Ve(ne,o.ghostClass,!0)),ut!==f&&f!==_e.active?ut=f:f===_e.active&&ut&&(ut=null),m===f&&(f._ignoreWhileAnimating=r),f.animateAll(function(){v("dragOverAnimationComplete"),f._ignoreWhileAnimating=null}),f!==m&&(m.animateAll(),m._ignoreWhileAnimating=null)),(r===ne&&!ne.animated||r===t&&!r.animated)&&(li=null),!o.dragoverBubble&&!e.rootEl&&r!==document&&(ne.parentNode[pt]._isOutsideThisEl(e.target),!Q&&$r(e)),!o.dragoverBubble&&e.stopPropagation&&e.stopPropagation(),p=!0}function M(){Bt=ze(ne),qs=ze(ne,o.draggable),yt({sortable:f,name:"change",toEl:t,newIndex:Bt,newDraggableIndex:qs,originalEvent:e})}if(e.preventDefault!==void 0&&e.cancelable&&e.preventDefault(),r=os(r,o.draggable,t,!0),v("dragOver"),_e.eventCanceled)return p;if(ne.contains(e.target)||r.animated&&r.animatingX&&r.animatingY||f._ignoreWhileAnimating===r)return P(!1);if(Ll=!1,u&&!o.disabled&&(c?d||(a=!Ne.contains(ne)):ut===this||(this.lastPutMode=xo.checkPull(this,u,ne,e))&&l.checkPut(this,u,ne,e))){if(h=this._getDirection(e,r)==="vertical",i=Ge(ne),v("dragOverValid"),_e.eventCanceled)return p;if(a)return Qe=Ne,C(),this._hideClone(),v("revert"),_e.eventCanceled||(Sr?Ne.insertBefore(ne,Sr):Ne.appendChild(ne)),P(!0);var F=mf(t,o.draggable);if(!F||PO(e,h,this)&&!F.animated){if(F===ne)return P(!1);if(F&&t===e.target&&(r=F),r&&(n=Ge(r)),Hd(Ne,t,ne,i,r,n,e,!!r)!==!1)return C(),t.appendChild(ne),Qe=t,M(),P(!0)}else if(r.parentNode===t){n=Ge(r);var O=0,$,D=ne.parentNode!==t,V=!CO(ne.animated&&ne.toRect||i,r.animated&&r.toRect||n,h),N=h?"top":"left",W=Xg(r,"top","top")||Xg(ne,"top","top"),G=W?W.scrollTop:void 0;li!==r&&($=n[N],zn=!1,wo=!V&&o.invertSwap||D),O=DO(e,r,n,h,V?1:o.swapThreshold,o.invertedSwapThreshold==null?o.swapThreshold:o.invertedSwapThreshold,wo,li===r);var te;if(O!==0){var X=ze(ne);do X-=O,te=Qe.children[X];while(te&&(me(te,"display")==="none"||te===$e))}if(O===0||te===r)return P(!1);li=r,Wn=O;var q=r.nextElementSibling,z=!1;z=O===1;var K=Hd(Ne,t,ne,i,r,n,e,z);if(K!==!1)return(K===1||K===-1)&&(z=K===1),Am=!0,setTimeout(SO,30),C(),z&&!q?t.appendChild(ne):r.parentNode.insertBefore(ne,z?q:r),W&&Db(W,0,G-W.scrollTop),Qe=ne.parentNode,$!==void 0&&!wo&&(Bo=Math.abs($-Ge(r)[N])),M(),P(!0)}if(t.contains(ne))return P(!1)}return!1},_ignoreWhileAnimating:null,_offMoveEvents:function(){De(document,"mousemove",this._onTouchMove),De(document,"touchmove",this._onTouchMove),De(document,"pointermove",this._onTouchMove),De(document,"dragover",$r),De(document,"mousemove",$r),De(document,"touchmove",$r)},_offUpEvents:function(){var e=this.el.ownerDocument;De(e,"mouseup",this._onDrop),De(e,"touchend",this._onDrop),De(e,"pointerup",this._onDrop),De(e,"touchcancel",this._onDrop),De(document,"selectstart",this)},_onDrop:function(e){var t=this.el,r=this.options;if(Bt=ze(ne),qs=ze(ne,r.draggable),Dt("drop",this,{evt:e}),Qe=ne&&ne.parentNode,Bt=ze(ne),qs=ze(ne,r.draggable),_e.eventCanceled){this._nulling();return}gi=!1,wo=!1,zn=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),Fm(this.cloneId),Fm(this._dragStartId),this.nativeDraggable&&(De(document,"drop",this),De(t,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),Lm&&me(document.body,"user-select",""),me(ne,"transform",""),e&&(Fn&&(e.cancelable&&e.preventDefault(),!r.dropBubble&&e.stopPropagation()),$e&&$e.parentNode&&$e.parentNode.removeChild($e),(Ne===Qe||ut&&ut.lastPutMode!=="clone")&&We&&We.parentNode&&We.parentNode.removeChild(We),ne&&(this.nativeDraggable&&De(ne,"dragend",this),jd(ne),ne.style["will-change"]="",Fn&&!gi&&Ve(ne,ut?ut.options.ghostClass:this.options.ghostClass,!1),Ve(ne,this.options.chosenClass,!1),yt({sortable:this,name:"unchoose",toEl:Qe,newIndex:null,newDraggableIndex:null,originalEvent:e}),Ne!==Qe?(Bt>=0&&(yt({rootEl:Qe,name:"add",toEl:Qe,fromEl:Ne,originalEvent:e}),yt({sortable:this,name:"remove",toEl:Qe,originalEvent:e}),yt({rootEl:Qe,name:"sort",toEl:Qe,fromEl:Ne,originalEvent:e}),yt({sortable:this,name:"sort",toEl:Qe,originalEvent:e})),ut&&ut.save()):Bt!==_i&&Bt>=0&&(yt({sortable:this,name:"update",toEl:Qe,originalEvent:e}),yt({sortable:this,name:"sort",toEl:Qe,originalEvent:e})),_e.active&&((Bt==null||Bt===-1)&&(Bt=_i,qs=Un),yt({sortable:this,name:"end",toEl:Qe,originalEvent:e}),this.save()))),this._nulling()},_nulling:function(){Dt("nulling",this),Ne=ne=Qe=$e=Sr=We=Vo=Xs=Cr=is=Fn=Bt=qs=_i=Un=li=Wn=ut=xo=_e.dragged=_e.ghost=_e.clone=_e.active=null,Fl.forEach(function(e){e.checked=!0}),Fl.length=Ad=Fd=0},handleEvent:function(e){switch(e.type){case"drop":case"dragend":this._onDrop(e);break;case"dragenter":case"dragover":ne&&(this._onDragOver(e),wO(e));break;case"selectstart":e.preventDefault();break}},toArray:function(){for(var e=[],t,r=this.el.children,i=0,n=r.length,a=this.options;i<n;i++)t=r[i],os(t,a.draggable,this.el,!1)&&e.push(t.getAttribute(a.dataIdAttr)||OO(t));return e},sort:function(e){var t={},r=this.el;this.toArray().forEach(function(i,n){var a=r.children[n];os(a,this.options.draggable,r,!1)&&(t[i]=a)},this),e.forEach(function(i){t[i]&&(r.removeChild(t[i]),r.appendChild(t[i]))})},save:function(){var e=this.options.store;e&&e.set&&e.set(this)},closest:function(e,t){return os(e,t||this.options.draggable,this.el,!1)},option:function(e,t){var r=this.options;if(t===void 0)return r[e];var i=eo.modifyOption(this,e,t);typeof i<"u"?r[e]=i:r[e]=t,e==="group"&&Mb(r)},destroy:function(){Dt("destroy",this);var e=this.el;e[pt]=null,De(e,"mousedown",this._onTapStart),De(e,"touchstart",this._onTapStart),De(e,"pointerdown",this._onTapStart),this.nativeDraggable&&(De(e,"dragover",this),De(e,"dragenter",this)),Array.prototype.forEach.call(e.querySelectorAll("[draggable]"),function(t){t.removeAttribute("draggable")}),this._onDrop(),this._disableDelayedDragEvents(),Al.splice(Al.indexOf(this.el),1),this.el=e=null},_hideClone:function(){if(!Xs){if(Dt("hideClone",this),_e.eventCanceled)return;me(We,"display","none"),this.options.removeCloneOnHide&&We.parentNode&&We.parentNode.removeChild(We),Xs=!0}},_showClone:function(e){if(e.lastPutMode!=="clone"){this._hideClone();return}if(Xs){if(Dt("showClone",this),_e.eventCanceled)return;Ne.contains(ne)&&!this.options.group.revertClone?Ne.insertBefore(We,ne):Sr?Ne.insertBefore(We,Sr):Ne.appendChild(We),this.options.group.revertClone&&this.animate(ne,We),me(We,"display",""),Xs=!1}}};function wO(s){s.dataTransfer&&(s.dataTransfer.dropEffect="move"),s.cancelable&&s.preventDefault()}function Hd(s,e,t,r,i,n,a,o){var l,u=s[pt],c=u.options.onMove,d;return window.CustomEvent&&!Ws&&!Qa?l=new CustomEvent("move",{bubbles:!0,cancelable:!0}):(l=document.createEvent("Event"),l.initEvent("move",!0,!0)),l.to=e,l.from=s,l.dragged=t,l.draggedRect=r,l.related=i||e,l.relatedRect=n||Ge(e),l.willInsertAfter=o,l.originalEvent=a,s.dispatchEvent(l),c&&(d=c.call(u,l,a)),d}function jd(s){s.draggable=!1}function SO(){Am=!1}function PO(s,e,t){var r=Ge(mf(t.el,t.options.draggable)),i=10;return e?s.clientX>r.right+i||s.clientX<=r.right&&s.clientY>r.bottom&&s.clientX>=r.left:s.clientX>r.right&&s.clientY>r.top||s.clientX<=r.right&&s.clientY>r.bottom+i}function DO(s,e,t,r,i,n,a,o){var l=r?s.clientY:s.clientX,u=r?t.height:t.width,c=r?t.top:t.left,d=r?t.bottom:t.right,m=!1;if(!a){if(o&&Bo<u*i){if(!zn&&(Wn===1?l>c+u*n/2:l<d-u*n/2)&&(zn=!0),zn)m=!0;else if(Wn===1?l<c+Bo:l>d-Bo)return-Wn}else if(l>c+u*(1-i)/2&&l<d-u*(1-i)/2)return TO(e)}return m=m||a,m&&(l<c+u*n/2||l>d-u*n/2)?l>c+u/2?1:-1:0}function TO(s){return ze(ne)<ze(s)?1:-1}function OO(s){for(var e=s.tagName+s.className+s.src+s.href+s.textContent,t=e.length,r=0;t--;)r+=e.charCodeAt(t);return r.toString(36)}function MO(s){Fl.length=0;for(var e=s.getElementsByTagName("input"),t=e.length;t--;){var r=e[t];r.checked&&Fl.push(r)}}function Uo(s){return setTimeout(s,0)}function Fm(s){return clearTimeout(s)}$u&&Oe(document,"touchmove",function(s){(_e.active||gi)&&s.cancelable&&s.preventDefault()});_e.utils={on:Oe,off:De,css:me,find:Sb,is:function(e,t){return!!os(e,t,e,!1)},extend:fO,throttle:Pb,closest:os,toggleClass:Ve,clone:hf,index:ze,nextTick:Uo,cancelNextTick:Fm,detectDirection:Ob,getChild:El};_e.get=function(s){return s[pt]};_e.mount=function(){for(var s=arguments.length,e=new Array(s),t=0;t<s;t++)e[t]=arguments[t];e[0].constructor===Array&&(e=e[0]),e.forEach(function(r){if(!r.prototype||!r.prototype.constructor)throw"Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(r));r.utils&&(_e.utils=dr({},_e.utils,r.utils)),eo.mount(r)})};_e.create=function(s,e){return new _e(s,e)};_e.version=dO;var et=[],Rn,Rm,Hm=!1,Id,Nd,Rl,Hn;function kO(){function s(){this.defaults={scroll:!0,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0};for(var e in this)e.charAt(0)==="_"&&typeof this[e]=="function"&&(this[e]=this[e].bind(this))}return s.prototype={dragStarted:function(t){var r=t.originalEvent;this.sortable.nativeDraggable?Oe(document,"dragover",this._handleAutoScroll):this.options.supportPointer?Oe(document,"pointermove",this._handleFallbackAutoScroll):r.touches?Oe(document,"touchmove",this._handleFallbackAutoScroll):Oe(document,"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(t){var r=t.originalEvent;!this.options.dragOverBubble&&!r.rootEl&&this._handleAutoScroll(r)},drop:function(){this.sortable.nativeDraggable?De(document,"dragover",this._handleAutoScroll):(De(document,"pointermove",this._handleFallbackAutoScroll),De(document,"touchmove",this._handleFallbackAutoScroll),De(document,"mousemove",this._handleFallbackAutoScroll)),t1(),Wo(),gO()},nulling:function(){Rl=Rm=Rn=Hm=Hn=Id=Nd=null,et.length=0},_handleFallbackAutoScroll:function(t){this._handleAutoScroll(t,!0)},_handleAutoScroll:function(t,r){var i=this,n=(t.touches?t.touches[0]:t).clientX,a=(t.touches?t.touches[0]:t).clientY,o=document.elementFromPoint(n,a);if(Rl=t,r||Qa||Ws||Lm){Vd(t,this.options,o,r);var l=Js(o,!0);Hm&&(!Hn||n!==Id||a!==Nd)&&(Hn&&t1(),Hn=setInterval(function(){var u=Js(document.elementFromPoint(n,a),!0);u!==l&&(l=u,Wo()),Vd(t,i.options,u,r)},10),Id=n,Nd=a)}else{if(!this.options.bubbleScroll||Js(o,!0)===xs()){Wo();return}Vd(t,this.options,Js(o,!1),!1)}}},es(s,{pluginName:"scroll",initializeByDefault:!0})}function Wo(){et.forEach(function(s){clearInterval(s.pid)}),et=[]}function t1(){clearInterval(Hn)}var Vd=Pb(function(s,e,t,r){if(e.scroll){var i=(s.touches?s.touches[0]:s).clientX,n=(s.touches?s.touches[0]:s).clientY,a=e.scrollSensitivity,o=e.scrollSpeed,l=xs(),u=!1,c;Rm!==t&&(Rm=t,Wo(),Rn=e.scroll,c=e.scrollFn,Rn===!0&&(Rn=Js(t,!0)));var d=0,m=Rn;do{var h=m,f=Ge(h),p=f.top,v=f.bottom,C=f.left,P=f.right,M=f.width,F=f.height,O=void 0,$=void 0,D=h.scrollWidth,V=h.scrollHeight,N=me(h),W=h.scrollLeft,G=h.scrollTop;h===l?(O=M<D&&(N.overflowX==="auto"||N.overflowX==="scroll"||N.overflowX==="visible"),$=F<V&&(N.overflowY==="auto"||N.overflowY==="scroll"||N.overflowY==="visible")):(O=M<D&&(N.overflowX==="auto"||N.overflowX==="scroll"),$=F<V&&(N.overflowY==="auto"||N.overflowY==="scroll"));var te=O&&(Math.abs(P-i)<=a&&W+M<D)-(Math.abs(C-i)<=a&&!!W),X=$&&(Math.abs(v-n)<=a&&G+F<V)-(Math.abs(p-n)<=a&&!!G);if(!et[d])for(var q=0;q<=d;q++)et[q]||(et[q]={});(et[d].vx!=te||et[d].vy!=X||et[d].el!==h)&&(et[d].el=h,et[d].vx=te,et[d].vy=X,clearInterval(et[d].pid),(te!=0||X!=0)&&(u=!0,et[d].pid=setInterval((function(){r&&this.layer===0&&_e.active._onTouchMove(Rl);var z=et[this.layer].vy?et[this.layer].vy*o:0,K=et[this.layer].vx?et[this.layer].vx*o:0;typeof c=="function"&&c.call(_e.dragged.parentNode[pt],K,z,s,Rl,et[this.layer].el)!=="continue"||Db(et[this.layer].el,K,z)}).bind({layer:d}),24))),d++}while(e.bubbleScroll&&m!==l&&(m=Js(m,!1)));Hm=u}},30),Lb=function(e){var t=e.originalEvent,r=e.putSortable,i=e.dragEl,n=e.activeSortable,a=e.dispatchSortableEvent,o=e.hideGhostForTarget,l=e.unhideGhostForTarget;if(t){var u=r||n;o();var c=t.changedTouches&&t.changedTouches.length?t.changedTouches[0]:t,d=document.elementFromPoint(c.clientX,c.clientY);l(),u&&!u.el.contains(d)&&(a("spill"),this.onSpill({dragEl:i,putSortable:r}))}};function pf(){}pf.prototype={startIndex:null,dragStart:function(e){var t=e.oldDraggableIndex;this.startIndex=t},onSpill:function(e){var t=e.dragEl,r=e.putSortable;this.sortable.captureAnimationState(),r&&r.captureAnimationState();var i=El(this.sortable.el,this.startIndex,this.options);i?this.sortable.el.insertBefore(t,i):this.sortable.el.appendChild(t),this.sortable.animateAll(),r&&r.animateAll()},drop:Lb};es(pf,{pluginName:"revertOnSpill"});function ff(){}ff.prototype={onSpill:function(e){var t=e.dragEl,r=e.putSortable,i=r||this.sortable;i.captureAnimationState(),t.parentNode&&t.parentNode.removeChild(t),i.animateAll()},drop:Lb};es(ff,{pluginName:"removeOnSpill"});var Zt;function EO(){function s(){this.defaults={swapClass:"sortable-swap-highlight"}}return s.prototype={dragStart:function(t){var r=t.dragEl;Zt=r},dragOverValid:function(t){var r=t.completed,i=t.target,n=t.onMove,a=t.activeSortable,o=t.changed,l=t.cancel;if(a.options.swap){var u=this.sortable.el,c=this.options;if(i&&i!==u){var d=Zt;n(i)!==!1?(Ve(i,c.swapClass,!0),Zt=i):Zt=null,d&&d!==Zt&&Ve(d,c.swapClass,!1)}o(),r(!0),l()}},drop:function(t){var r=t.activeSortable,i=t.putSortable,n=t.dragEl,a=i||this.sortable,o=this.options;Zt&&Ve(Zt,o.swapClass,!1),Zt&&(o.swap||i&&i.options.swap)&&n!==Zt&&(a.captureAnimationState(),a!==r&&r.captureAnimationState(),LO(n,Zt),a.animateAll(),a!==r&&r.animateAll())},nulling:function(){Zt=null}},es(s,{pluginName:"swap",eventProperties:function(){return{swapItem:Zt}}})}function LO(s,e){var t=s.parentNode,r=e.parentNode,i,n;!t||!r||t.isEqualNode(e)||r.isEqualNode(s)||(i=ze(s),n=ze(e),t.isEqualNode(r)&&i<n&&n++,t.insertBefore(e,t.children[i]),r.insertBefore(s,r.children[n]))}var Ce=[],Vt=[],$n,ns,xn=!1,It=!1,ci=!1,Re,wn,Po;function AO(){function s(e){for(var t in this)t.charAt(0)==="_"&&typeof this[t]=="function"&&(this[t]=this[t].bind(this));e.options.supportPointer?Oe(document,"pointerup",this._deselectMultiDrag):(Oe(document,"mouseup",this._deselectMultiDrag),Oe(document,"touchend",this._deselectMultiDrag)),Oe(document,"keydown",this._checkKeyDown),Oe(document,"keyup",this._checkKeyUp),this.defaults={selectedClass:"sortable-selected",multiDragKey:null,setData:function(i,n){var a="";Ce.length&&ns===e?Ce.forEach(function(o,l){a+=(l?", ":"")+o.textContent}):a=n.textContent,i.setData("Text",a)}}}return s.prototype={multiDragKeyDown:!1,isMultiDrag:!1,delayStartGlobal:function(t){var r=t.dragEl;Re=r},delayEnded:function(){this.isMultiDrag=~Ce.indexOf(Re)},setupClone:function(t){var r=t.sortable,i=t.cancel;if(this.isMultiDrag){for(var n=0;n<Ce.length;n++)Vt.push(hf(Ce[n])),Vt[n].sortableIndex=Ce[n].sortableIndex,Vt[n].draggable=!1,Vt[n].style["will-change"]="",Ve(Vt[n],this.options.selectedClass,!1),Ce[n]===Re&&Ve(Vt[n],this.options.chosenClass,!1);r._hideClone(),i()}},clone:function(t){var r=t.sortable,i=t.rootEl,n=t.dispatchSortableEvent,a=t.cancel;this.isMultiDrag&&(this.options.removeCloneOnHide||Ce.length&&ns===r&&(s1(!0,i),n("clone"),a()))},showClone:function(t){var r=t.cloneNowShown,i=t.rootEl,n=t.cancel;this.isMultiDrag&&(s1(!1,i),Vt.forEach(function(a){me(a,"display","")}),r(),Po=!1,n())},hideClone:function(t){var r=this;t.sortable;var i=t.cloneNowHidden,n=t.cancel;this.isMultiDrag&&(Vt.forEach(function(a){me(a,"display","none"),r.options.removeCloneOnHide&&a.parentNode&&a.parentNode.removeChild(a)}),i(),Po=!0,n())},dragStartGlobal:function(t){t.sortable,!this.isMultiDrag&&ns&&ns.multiDrag._deselectMultiDrag(),Ce.forEach(function(r){r.sortableIndex=ze(r)}),Ce=Ce.sort(function(r,i){return r.sortableIndex-i.sortableIndex}),ci=!0},dragStarted:function(t){var r=this,i=t.sortable;if(this.isMultiDrag){if(this.options.sort&&(i.captureAnimationState(),this.options.animation)){Ce.forEach(function(a){a!==Re&&me(a,"position","absolute")});var n=Ge(Re,!1,!0,!0);Ce.forEach(function(a){a!==Re&&Jg(a,n)}),It=!0,xn=!0}i.animateAll(function(){It=!1,xn=!1,r.options.animation&&Ce.forEach(function(a){Ed(a)}),r.options.sort&&Do()})}},dragOver:function(t){var r=t.target,i=t.completed,n=t.cancel;It&&~Ce.indexOf(r)&&(i(!1),n())},revert:function(t){var r=t.fromSortable,i=t.rootEl,n=t.sortable,a=t.dragRect;Ce.length>1&&(Ce.forEach(function(o){n.addAnimationState({target:o,rect:It?Ge(o):a}),Ed(o),o.fromRect=a,r.removeAnimationState(o)}),It=!1,FO(!this.options.removeCloneOnHide,i))},dragOverCompleted:function(t){var r=t.sortable,i=t.isOwner,n=t.insertion,a=t.activeSortable,o=t.parentEl,l=t.putSortable,u=this.options;if(n){if(i&&a._hideClone(),xn=!1,u.animation&&Ce.length>1&&(It||!i&&!a.options.sort&&!l)){var c=Ge(Re,!1,!0,!0);Ce.forEach(function(m){m!==Re&&(Jg(m,c),o.appendChild(m))}),It=!0}if(!i)if(It||Do(),Ce.length>1){var d=Po;a._showClone(r),a.options.animation&&!Po&&d&&Vt.forEach(function(m){a.addAnimationState({target:m,rect:wn}),m.fromRect=wn,m.thisAnimationDuration=null})}else a._showClone(r)}},dragOverAnimationCapture:function(t){var r=t.dragRect,i=t.isOwner,n=t.activeSortable;if(Ce.forEach(function(o){o.thisAnimationDuration=null}),n.options.animation&&!i&&n.multiDrag.isMultiDrag){wn=es({},r);var a=Ar(Re,!0);wn.top-=a.f,wn.left-=a.e}},dragOverAnimationComplete:function(){It&&(It=!1,Do())},drop:function(t){var r=t.originalEvent,i=t.rootEl,n=t.parentEl,a=t.sortable,o=t.dispatchSortableEvent,l=t.oldIndex,u=t.putSortable,c=u||this.sortable;if(r){var d=this.options,m=n.children;if(!ci)if(d.multiDragKey&&!this.multiDragKeyDown&&this._deselectMultiDrag(),Ve(Re,d.selectedClass,!~Ce.indexOf(Re)),~Ce.indexOf(Re))Ce.splice(Ce.indexOf(Re),1),$n=null,An({sortable:a,rootEl:i,name:"deselect",targetEl:Re});else{if(Ce.push(Re),An({sortable:a,rootEl:i,name:"select",targetEl:Re}),r.shiftKey&&$n&&a.el.contains($n)){var h=ze($n),f=ze(Re);if(~h&&~f&&h!==f){var p,v;for(f>h?(v=h,p=f):(v=f,p=h+1);v<p;v++)~Ce.indexOf(m[v])||(Ve(m[v],d.selectedClass,!0),Ce.push(m[v]),An({sortable:a,rootEl:i,name:"select",targetEl:m[v]}))}}else $n=Re;ns=c}if(ci&&this.isMultiDrag){if((n[pt].options.sort||n!==i)&&Ce.length>1){var C=Ge(Re),P=ze(Re,":not(."+this.options.selectedClass+")");if(!xn&&d.animation&&(Re.thisAnimationDuration=null),c.captureAnimationState(),!xn&&(d.animation&&(Re.fromRect=C,Ce.forEach(function(F){if(F.thisAnimationDuration=null,F!==Re){var O=It?Ge(F):C;F.fromRect=O,c.addAnimationState({target:F,rect:O})}})),Do(),Ce.forEach(function(F){m[P]?n.insertBefore(F,m[P]):n.appendChild(F),P++}),l===ze(Re))){var M=!1;Ce.forEach(function(F){if(F.sortableIndex!==ze(F)){M=!0;return}}),M&&o("update")}Ce.forEach(function(F){Ed(F)}),c.animateAll()}ns=c}(i===n||u&&u.lastPutMode!=="clone")&&Vt.forEach(function(F){F.parentNode&&F.parentNode.removeChild(F)})}},nullingGlobal:function(){this.isMultiDrag=ci=!1,Vt.length=0},destroyGlobal:function(){this._deselectMultiDrag(),De(document,"pointerup",this._deselectMultiDrag),De(document,"mouseup",this._deselectMultiDrag),De(document,"touchend",this._deselectMultiDrag),De(document,"keydown",this._checkKeyDown),De(document,"keyup",this._checkKeyUp)},_deselectMultiDrag:function(t){if(!(typeof ci<"u"&&ci)&&ns===this.sortable&&!(t&&os(t.target,this.options.draggable,this.sortable.el,!1))&&!(t&&t.button!==0))for(;Ce.length;){var r=Ce[0];Ve(r,this.options.selectedClass,!1),Ce.shift(),An({sortable:this.sortable,rootEl:this.sortable.el,name:"deselect",targetEl:r})}},_checkKeyDown:function(t){t.key===this.options.multiDragKey&&(this.multiDragKeyDown=!0)},_checkKeyUp:function(t){t.key===this.options.multiDragKey&&(this.multiDragKeyDown=!1)}},es(s,{pluginName:"multiDrag",utils:{select:function(t){var r=t.parentNode[pt];!r||!r.options.multiDrag||~Ce.indexOf(t)||(ns&&ns!==r&&(ns.multiDrag._deselectMultiDrag(),ns=r),Ve(t,r.options.selectedClass,!0),Ce.push(t))},deselect:function(t){var r=t.parentNode[pt],i=Ce.indexOf(t);!r||!r.options.multiDrag||!~i||(Ve(t,r.options.selectedClass,!1),Ce.splice(i,1))}},eventProperties:function(){var t=this,r=[],i=[];return Ce.forEach(function(n){r.push({multiDragElement:n,index:n.sortableIndex});var a;It&&n!==Re?a=-1:It?a=ze(n,":not(."+t.options.selectedClass+")"):a=ze(n),i.push({multiDragElement:n,index:a})}),{items:oO(Ce),clones:[].concat(Vt),oldIndicies:r,newIndicies:i}},optionListeners:{multiDragKey:function(t){return t=t.toLowerCase(),t==="ctrl"?t="Control":t.length>1&&(t=t.charAt(0).toUpperCase()+t.substr(1)),t}}})}function FO(s,e){Ce.forEach(function(t,r){var i=e.children[t.sortableIndex+(s?Number(r):0)];i?e.insertBefore(t,i):e.appendChild(t)})}function s1(s,e){Vt.forEach(function(t,r){var i=e.children[t.sortableIndex+(s?Number(r):0)];i?e.insertBefore(t,i):e.appendChild(t)})}function Do(){Ce.forEach(function(s){s!==Re&&s.parentNode&&s.parentNode.removeChild(s)})}_e.mount(new kO);_e.mount(ff,pf);const RO=Object.freeze(Object.defineProperty({__proto__:null,MultiDrag:AO,Sortable:_e,Swap:EO,default:_e},Symbol.toStringTag,{value:"Module"})),HO=E_(RO);(function(s,e){(function(r,i){s.exports=i(HO)})(typeof self<"u"?self:Tr,function(t){return function(r){var i={};function n(a){if(i[a])return i[a].exports;var o=i[a]={i:a,l:!1,exports:{}};return r[a].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=r,n.c=i,n.d=function(a,o,l){n.o(a,o)||Object.defineProperty(a,o,{enumerable:!0,get:l})},n.r=function(a){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(a,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(a,"__esModule",{value:!0})},n.t=function(a,o){if(o&1&&(a=n(a)),o&8||o&4&&typeof a=="object"&&a&&a.__esModule)return a;var l=Object.create(null);if(n.r(l),Object.defineProperty(l,"default",{enumerable:!0,value:a}),o&2&&typeof a!="string")for(var u in a)n.d(l,u,(function(c){return a[c]}).bind(null,u));return l},n.n=function(a){var o=a&&a.__esModule?function(){return a.default}:function(){return a};return n.d(o,"a",o),o},n.o=function(a,o){return Object.prototype.hasOwnProperty.call(a,o)},n.p="",n(n.s="fb15")}({"01f9":function(r,i,n){var a=n("2d00"),o=n("5ca1"),l=n("2aba"),u=n("32e9"),c=n("84f2"),d=n("41a0"),m=n("7f20"),h=n("38fd"),f=n("2b4c")("iterator"),p=!([].keys&&"next"in[].keys()),v="@@iterator",C="keys",P="values",M=function(){return this};r.exports=function(F,O,$,D,V,N,W){d($,O,D);var G=function(H){if(!p&&H in z)return z[H];switch(H){case C:return function(){return new $(this,H)};case P:return function(){return new $(this,H)}}return function(){return new $(this,H)}},te=O+" Iterator",X=V==P,q=!1,z=F.prototype,K=z[f]||z[v]||V&&z[V],Q=K||G(V),re=V?X?G("entries"):Q:void 0,R=O=="Array"&&z.entries||K,B,T,A;if(R&&(A=h(R.call(new F)),A!==Object.prototype&&A.next&&(m(A,te,!0),!a&&typeof A[f]!="function"&&u(A,f,M))),X&&K&&K.name!==P&&(q=!0,Q=function(){return K.call(this)}),(!a||W)&&(p||q||!z[f])&&u(z,f,Q),c[O]=Q,c[te]=M,V)if(B={values:X?Q:G(P),keys:N?Q:G(C),entries:re},W)for(T in B)T in z||l(z,T,B[T]);else o(o.P+o.F*(p||q),O,B);return B}},"02f4":function(r,i,n){var a=n("4588"),o=n("be13");r.exports=function(l){return function(u,c){var d=String(o(u)),m=a(c),h=d.length,f,p;return m<0||m>=h?l?"":void 0:(f=d.charCodeAt(m),f<55296||f>56319||m+1===h||(p=d.charCodeAt(m+1))<56320||p>57343?l?d.charAt(m):f:l?d.slice(m,m+2):(f-55296<<10)+(p-56320)+65536)}}},"0390":function(r,i,n){var a=n("02f4")(!0);r.exports=function(o,l,u){return l+(u?a(o,l).length:1)}},"0bfb":function(r,i,n){var a=n("cb7c");r.exports=function(){var o=a(this),l="";return o.global&&(l+="g"),o.ignoreCase&&(l+="i"),o.multiline&&(l+="m"),o.unicode&&(l+="u"),o.sticky&&(l+="y"),l}},"0d58":function(r,i,n){var a=n("ce10"),o=n("e11e");r.exports=Object.keys||function(u){return a(u,o)}},1495:function(r,i,n){var a=n("86cc"),o=n("cb7c"),l=n("0d58");r.exports=n("9e1e")?Object.defineProperties:function(c,d){o(c);for(var m=l(d),h=m.length,f=0,p;h>f;)a.f(c,p=m[f++],d[p]);return c}},"214f":function(r,i,n){n("b0c5");var a=n("2aba"),o=n("32e9"),l=n("79e5"),u=n("be13"),c=n("2b4c"),d=n("520a"),m=c("species"),h=!l(function(){var p=/./;return p.exec=function(){var v=[];return v.groups={a:"7"},v},"".replace(p,"$<a>")!=="7"}),f=function(){var p=/(?:)/,v=p.exec;p.exec=function(){return v.apply(this,arguments)};var C="ab".split(p);return C.length===2&&C[0]==="a"&&C[1]==="b"}();r.exports=function(p,v,C){var P=c(p),M=!l(function(){var N={};return N[P]=function(){return 7},""[p](N)!=7}),F=M?!l(function(){var N=!1,W=/a/;return W.exec=function(){return N=!0,null},p==="split"&&(W.constructor={},W.constructor[m]=function(){return W}),W[P](""),!N}):void 0;if(!M||!F||p==="replace"&&!h||p==="split"&&!f){var O=/./[P],$=C(u,P,""[p],function(W,G,te,X,q){return G.exec===d?M&&!q?{done:!0,value:O.call(G,te,X)}:{done:!0,value:W.call(te,G,X)}:{done:!1}}),D=$[0],V=$[1];a(String.prototype,p,D),o(RegExp.prototype,P,v==2?function(N,W){return V.call(N,this,W)}:function(N){return V.call(N,this)})}}},"230e":function(r,i,n){var a=n("d3f4"),o=n("7726").document,l=a(o)&&a(o.createElement);r.exports=function(u){return l?o.createElement(u):{}}},"23c6":function(r,i,n){var a=n("2d95"),o=n("2b4c")("toStringTag"),l=a(function(){return arguments}())=="Arguments",u=function(c,d){try{return c[d]}catch{}};r.exports=function(c){var d,m,h;return c===void 0?"Undefined":c===null?"Null":typeof(m=u(d=Object(c),o))=="string"?m:l?a(d):(h=a(d))=="Object"&&typeof d.callee=="function"?"Arguments":h}},2621:function(r,i){i.f=Object.getOwnPropertySymbols},"2aba":function(r,i,n){var a=n("7726"),o=n("32e9"),l=n("69a8"),u=n("ca5a")("src"),c=n("fa5b"),d="toString",m=(""+c).split(d);n("8378").inspectSource=function(h){return c.call(h)},(r.exports=function(h,f,p,v){var C=typeof p=="function";C&&(l(p,"name")||o(p,"name",f)),h[f]!==p&&(C&&(l(p,u)||o(p,u,h[f]?""+h[f]:m.join(String(f)))),h===a?h[f]=p:v?h[f]?h[f]=p:o(h,f,p):(delete h[f],o(h,f,p)))})(Function.prototype,d,function(){return typeof this=="function"&&this[u]||c.call(this)})},"2aeb":function(r,i,n){var a=n("cb7c"),o=n("1495"),l=n("e11e"),u=n("613b")("IE_PROTO"),c=function(){},d="prototype",m=function(){var h=n("230e")("iframe"),f=l.length,p="<",v=">",C;for(h.style.display="none",n("fab2").appendChild(h),h.src="javascript:",C=h.contentWindow.document,C.open(),C.write(p+"script"+v+"document.F=Object"+p+"/script"+v),C.close(),m=C.F;f--;)delete m[d][l[f]];return m()};r.exports=Object.create||function(f,p){var v;return f!==null?(c[d]=a(f),v=new c,c[d]=null,v[u]=f):v=m(),p===void 0?v:o(v,p)}},"2b4c":function(r,i,n){var a=n("5537")("wks"),o=n("ca5a"),l=n("7726").Symbol,u=typeof l=="function",c=r.exports=function(d){return a[d]||(a[d]=u&&l[d]||(u?l:o)("Symbol."+d))};c.store=a},"2d00":function(r,i){r.exports=!1},"2d95":function(r,i){var n={}.toString;r.exports=function(a){return n.call(a).slice(8,-1)}},"2fdb":function(r,i,n){var a=n("5ca1"),o=n("d2c8"),l="includes";a(a.P+a.F*n("5147")(l),"String",{includes:function(c){return!!~o(this,c,l).indexOf(c,arguments.length>1?arguments[1]:void 0)}})},"32e9":function(r,i,n){var a=n("86cc"),o=n("4630");r.exports=n("9e1e")?function(l,u,c){return a.f(l,u,o(1,c))}:function(l,u,c){return l[u]=c,l}},"38fd":function(r,i,n){var a=n("69a8"),o=n("4bf8"),l=n("613b")("IE_PROTO"),u=Object.prototype;r.exports=Object.getPrototypeOf||function(c){return c=o(c),a(c,l)?c[l]:typeof c.constructor=="function"&&c instanceof c.constructor?c.constructor.prototype:c instanceof Object?u:null}},"41a0":function(r,i,n){var a=n("2aeb"),o=n("4630"),l=n("7f20"),u={};n("32e9")(u,n("2b4c")("iterator"),function(){return this}),r.exports=function(c,d,m){c.prototype=a(u,{next:o(1,m)}),l(c,d+" Iterator")}},"456d":function(r,i,n){var a=n("4bf8"),o=n("0d58");n("5eda")("keys",function(){return function(u){return o(a(u))}})},4588:function(r,i){var n=Math.ceil,a=Math.floor;r.exports=function(o){return isNaN(o=+o)?0:(o>0?a:n)(o)}},4630:function(r,i){r.exports=function(n,a){return{enumerable:!(n&1),configurable:!(n&2),writable:!(n&4),value:a}}},"4bf8":function(r,i,n){var a=n("be13");r.exports=function(o){return Object(a(o))}},5147:function(r,i,n){var a=n("2b4c")("match");r.exports=function(o){var l=/./;try{"/./"[o](l)}catch{try{return l[a]=!1,!"/./"[o](l)}catch{}}return!0}},"520a":function(r,i,n){var a=n("0bfb"),o=RegExp.prototype.exec,l=String.prototype.replace,u=o,c="lastIndex",d=function(){var f=/a/,p=/b*/g;return o.call(f,"a"),o.call(p,"a"),f[c]!==0||p[c]!==0}(),m=/()??/.exec("")[1]!==void 0,h=d||m;h&&(u=function(p){var v=this,C,P,M,F;return m&&(P=new RegExp("^"+v.source+"$(?!\\s)",a.call(v))),d&&(C=v[c]),M=o.call(v,p),d&&M&&(v[c]=v.global?M.index+M[0].length:C),m&&M&&M.length>1&&l.call(M[0],P,function(){for(F=1;F<arguments.length-2;F++)arguments[F]===void 0&&(M[F]=void 0)}),M}),r.exports=u},"52a7":function(r,i){i.f={}.propertyIsEnumerable},5537:function(r,i,n){var a=n("8378"),o=n("7726"),l="__core-js_shared__",u=o[l]||(o[l]={});(r.exports=function(c,d){return u[c]||(u[c]=d!==void 0?d:{})})("versions",[]).push({version:a.version,mode:n("2d00")?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},"5ca1":function(r,i,n){var a=n("7726"),o=n("8378"),l=n("32e9"),u=n("2aba"),c=n("9b43"),d="prototype",m=function(h,f,p){var v=h&m.F,C=h&m.G,P=h&m.S,M=h&m.P,F=h&m.B,O=C?a:P?a[f]||(a[f]={}):(a[f]||{})[d],$=C?o:o[f]||(o[f]={}),D=$[d]||($[d]={}),V,N,W,G;C&&(p=f);for(V in p)N=!v&&O&&O[V]!==void 0,W=(N?O:p)[V],G=F&&N?c(W,a):M&&typeof W=="function"?c(Function.call,W):W,O&&u(O,V,W,h&m.U),$[V]!=W&&l($,V,G),M&&D[V]!=W&&(D[V]=W)};a.core=o,m.F=1,m.G=2,m.S=4,m.P=8,m.B=16,m.W=32,m.U=64,m.R=128,r.exports=m},"5eda":function(r,i,n){var a=n("5ca1"),o=n("8378"),l=n("79e5");r.exports=function(u,c){var d=(o.Object||{})[u]||Object[u],m={};m[u]=c(d),a(a.S+a.F*l(function(){d(1)}),"Object",m)}},"5f1b":function(r,i,n){var a=n("23c6"),o=RegExp.prototype.exec;r.exports=function(l,u){var c=l.exec;if(typeof c=="function"){var d=c.call(l,u);if(typeof d!="object")throw new TypeError("RegExp exec method returned something other than an Object or null");return d}if(a(l)!=="RegExp")throw new TypeError("RegExp#exec called on incompatible receiver");return o.call(l,u)}},"613b":function(r,i,n){var a=n("5537")("keys"),o=n("ca5a");r.exports=function(l){return a[l]||(a[l]=o(l))}},"626a":function(r,i,n){var a=n("2d95");r.exports=Object("z").propertyIsEnumerable(0)?Object:function(o){return a(o)=="String"?o.split(""):Object(o)}},6762:function(r,i,n){var a=n("5ca1"),o=n("c366")(!0);a(a.P,"Array",{includes:function(u){return o(this,u,arguments.length>1?arguments[1]:void 0)}}),n("9c6c")("includes")},6821:function(r,i,n){var a=n("626a"),o=n("be13");r.exports=function(l){return a(o(l))}},"69a8":function(r,i){var n={}.hasOwnProperty;r.exports=function(a,o){return n.call(a,o)}},"6a99":function(r,i,n){var a=n("d3f4");r.exports=function(o,l){if(!a(o))return o;var u,c;if(l&&typeof(u=o.toString)=="function"&&!a(c=u.call(o))||typeof(u=o.valueOf)=="function"&&!a(c=u.call(o))||!l&&typeof(u=o.toString)=="function"&&!a(c=u.call(o)))return c;throw TypeError("Can't convert object to primitive value")}},7333:function(r,i,n){var a=n("0d58"),o=n("2621"),l=n("52a7"),u=n("4bf8"),c=n("626a"),d=Object.assign;r.exports=!d||n("79e5")(function(){var m={},h={},f=Symbol(),p="abcdefghijklmnopqrst";return m[f]=7,p.split("").forEach(function(v){h[v]=v}),d({},m)[f]!=7||Object.keys(d({},h)).join("")!=p})?function(h,f){for(var p=u(h),v=arguments.length,C=1,P=o.f,M=l.f;v>C;)for(var F=c(arguments[C++]),O=P?a(F).concat(P(F)):a(F),$=O.length,D=0,V;$>D;)M.call(F,V=O[D++])&&(p[V]=F[V]);return p}:d},7726:function(r,i){var n=r.exports=typeof window<"u"&&window.Math==Math?window:typeof self<"u"&&self.Math==Math?self:Function("return this")();typeof __g=="number"&&(__g=n)},"77f1":function(r,i,n){var a=n("4588"),o=Math.max,l=Math.min;r.exports=function(u,c){return u=a(u),u<0?o(u+c,0):l(u,c)}},"79e5":function(r,i){r.exports=function(n){try{return!!n()}catch{return!0}}},"7f20":function(r,i,n){var a=n("86cc").f,o=n("69a8"),l=n("2b4c")("toStringTag");r.exports=function(u,c,d){u&&!o(u=d?u:u.prototype,l)&&a(u,l,{configurable:!0,value:c})}},8378:function(r,i){var n=r.exports={version:"2.6.5"};typeof __e=="number"&&(__e=n)},"84f2":function(r,i){r.exports={}},"86cc":function(r,i,n){var a=n("cb7c"),o=n("c69a"),l=n("6a99"),u=Object.defineProperty;i.f=n("9e1e")?Object.defineProperty:function(d,m,h){if(a(d),m=l(m,!0),a(h),o)try{return u(d,m,h)}catch{}if("get"in h||"set"in h)throw TypeError("Accessors not supported!");return"value"in h&&(d[m]=h.value),d}},"9b43":function(r,i,n){var a=n("d8e8");r.exports=function(o,l,u){if(a(o),l===void 0)return o;switch(u){case 1:return function(c){return o.call(l,c)};case 2:return function(c,d){return o.call(l,c,d)};case 3:return function(c,d,m){return o.call(l,c,d,m)}}return function(){return o.apply(l,arguments)}}},"9c6c":function(r,i,n){var a=n("2b4c")("unscopables"),o=Array.prototype;o[a]==null&&n("32e9")(o,a,{}),r.exports=function(l){o[a][l]=!0}},"9def":function(r,i,n){var a=n("4588"),o=Math.min;r.exports=function(l){return l>0?o(a(l),9007199254740991):0}},"9e1e":function(r,i,n){r.exports=!n("79e5")(function(){return Object.defineProperty({},"a",{get:function(){return 7}}).a!=7})},a352:function(r,i){r.exports=t},a481:function(r,i,n){var a=n("cb7c"),o=n("4bf8"),l=n("9def"),u=n("4588"),c=n("0390"),d=n("5f1b"),m=Math.max,h=Math.min,f=Math.floor,p=/\$([$&`']|\d\d?|<[^>]*>)/g,v=/\$([$&`']|\d\d?)/g,C=function(P){return P===void 0?P:String(P)};n("214f")("replace",2,function(P,M,F,O){return[function(V,N){var W=P(this),G=V==null?void 0:V[M];return G!==void 0?G.call(V,W,N):F.call(String(W),V,N)},function(D,V){var N=O(F,D,this,V);if(N.done)return N.value;var W=a(D),G=String(this),te=typeof V=="function";te||(V=String(V));var X=W.global;if(X){var q=W.unicode;W.lastIndex=0}for(var z=[];;){var K=d(W,G);if(K===null||(z.push(K),!X))break;var Q=String(K[0]);Q===""&&(W.lastIndex=c(G,l(W.lastIndex),q))}for(var re="",R=0,B=0;B<z.length;B++){K=z[B];for(var T=String(K[0]),A=m(h(u(K.index),G.length),0),H=[],ee=1;ee<K.length;ee++)H.push(C(K[ee]));var ie=K.groups;if(te){var ue=[T].concat(H,A,G);ie!==void 0&&ue.push(ie);var be=String(V.apply(void 0,ue))}else be=$(T,G,A,H,ie,V);A>=R&&(re+=G.slice(R,A)+be,R=A+T.length)}return re+G.slice(R)}];function $(D,V,N,W,G,te){var X=N+D.length,q=W.length,z=v;return G!==void 0&&(G=o(G),z=p),F.call(te,z,function(K,Q){var re;switch(Q.charAt(0)){case"$":return"$";case"&":return D;case"`":return V.slice(0,N);case"'":return V.slice(X);case"<":re=G[Q.slice(1,-1)];break;default:var R=+Q;if(R===0)return K;if(R>q){var B=f(R/10);return B===0?K:B<=q?W[B-1]===void 0?Q.charAt(1):W[B-1]+Q.charAt(1):K}re=W[R-1]}return re===void 0?"":re})}})},aae3:function(r,i,n){var a=n("d3f4"),o=n("2d95"),l=n("2b4c")("match");r.exports=function(u){var c;return a(u)&&((c=u[l])!==void 0?!!c:o(u)=="RegExp")}},ac6a:function(r,i,n){for(var a=n("cadf"),o=n("0d58"),l=n("2aba"),u=n("7726"),c=n("32e9"),d=n("84f2"),m=n("2b4c"),h=m("iterator"),f=m("toStringTag"),p=d.Array,v={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1},C=o(v),P=0;P<C.length;P++){var M=C[P],F=v[M],O=u[M],$=O&&O.prototype,D;if($&&($[h]||c($,h,p),$[f]||c($,f,M),d[M]=p,F))for(D in a)$[D]||l($,D,a[D],!0)}},b0c5:function(r,i,n){var a=n("520a");n("5ca1")({target:"RegExp",proto:!0,forced:a!==/./.exec},{exec:a})},be13:function(r,i){r.exports=function(n){if(n==null)throw TypeError("Can't call method on "+n);return n}},c366:function(r,i,n){var a=n("6821"),o=n("9def"),l=n("77f1");r.exports=function(u){return function(c,d,m){var h=a(c),f=o(h.length),p=l(m,f),v;if(u&&d!=d){for(;f>p;)if(v=h[p++],v!=v)return!0}else for(;f>p;p++)if((u||p in h)&&h[p]===d)return u||p||0;return!u&&-1}}},c649:function(r,i,n){(function(a){n.d(i,"c",function(){return h}),n.d(i,"a",function(){return d}),n.d(i,"b",function(){return l}),n.d(i,"d",function(){return m}),n("a481");function o(){return typeof window<"u"?window.console:a.console}var l=o();function u(f){var p=Object.create(null);return function(C){var P=p[C];return P||(p[C]=f(C))}}var c=/-(\w)/g,d=u(function(f){return f.replace(c,function(p,v){return v?v.toUpperCase():""})});function m(f){f.parentElement!==null&&f.parentElement.removeChild(f)}function h(f,p,v){var C=v===0?f.children[0]:f.children[v-1].nextSibling;f.insertBefore(p,C)}}).call(this,n("c8ba"))},c69a:function(r,i,n){r.exports=!n("9e1e")&&!n("79e5")(function(){return Object.defineProperty(n("230e")("div"),"a",{get:function(){return 7}}).a!=7})},c8ba:function(r,i){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch{typeof window=="object"&&(n=window)}r.exports=n},ca5a:function(r,i){var n=0,a=Math.random();r.exports=function(o){return"Symbol(".concat(o===void 0?"":o,")_",(++n+a).toString(36))}},cadf:function(r,i,n){var a=n("9c6c"),o=n("d53b"),l=n("84f2"),u=n("6821");r.exports=n("01f9")(Array,"Array",function(c,d){this._t=u(c),this._i=0,this._k=d},function(){var c=this._t,d=this._k,m=this._i++;return!c||m>=c.length?(this._t=void 0,o(1)):d=="keys"?o(0,m):d=="values"?o(0,c[m]):o(0,[m,c[m]])},"values"),l.Arguments=l.Array,a("keys"),a("values"),a("entries")},cb7c:function(r,i,n){var a=n("d3f4");r.exports=function(o){if(!a(o))throw TypeError(o+" is not an object!");return o}},ce10:function(r,i,n){var a=n("69a8"),o=n("6821"),l=n("c366")(!1),u=n("613b")("IE_PROTO");r.exports=function(c,d){var m=o(c),h=0,f=[],p;for(p in m)p!=u&&a(m,p)&&f.push(p);for(;d.length>h;)a(m,p=d[h++])&&(~l(f,p)||f.push(p));return f}},d2c8:function(r,i,n){var a=n("aae3"),o=n("be13");r.exports=function(l,u,c){if(a(u))throw TypeError("String#"+c+" doesn't accept regex!");return String(o(l))}},d3f4:function(r,i){r.exports=function(n){return typeof n=="object"?n!==null:typeof n=="function"}},d53b:function(r,i){r.exports=function(n,a){return{value:a,done:!!n}}},d8e8:function(r,i){r.exports=function(n){if(typeof n!="function")throw TypeError(n+" is not a function!");return n}},e11e:function(r,i){r.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},f559:function(r,i,n){var a=n("5ca1"),o=n("9def"),l=n("d2c8"),u="startsWith",c=""[u];a(a.P+a.F*n("5147")(u),"String",{startsWith:function(m){var h=l(this,m,u),f=o(Math.min(arguments.length>1?arguments[1]:void 0,h.length)),p=String(m);return c?c.call(h,p,f):h.slice(f,f+p.length)===p}})},f6fd:function(r,i){(function(n){var a="currentScript",o=n.getElementsByTagName("script");a in n||Object.defineProperty(n,a,{get:function(){try{throw new Error}catch(c){var l,u=(/.*at [^\(]*\((.*):.+:.+\)$/ig.exec(c.stack)||[!1])[1];for(l in o)if(o[l].src==u||o[l].readyState=="interactive")return o[l];return null}}})})(document)},f751:function(r,i,n){var a=n("5ca1");a(a.S+a.F,"Object",{assign:n("7333")})},fa5b:function(r,i,n){r.exports=n("5537")("native-function-to-string",Function.toString)},fab2:function(r,i,n){var a=n("7726").document;r.exports=a&&a.documentElement},fb15:function(r,i,n){if(n.r(i),typeof window<"u"){n("f6fd");var a;(a=window.document.currentScript)&&(a=a.src.match(/(.+\/)[^/]+\.js(\?.*)?$/))&&(n.p=a[1])}n("f751"),n("f559"),n("ac6a"),n("cadf"),n("456d");function o(T){if(Array.isArray(T))return T}function l(T,A){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(T)))){var H=[],ee=!0,ie=!1,ue=void 0;try{for(var be=T[Symbol.iterator](),Se;!(ee=(Se=be.next()).done)&&(H.push(Se.value),!(A&&H.length===A));ee=!0);}catch(rt){ie=!0,ue=rt}finally{try{!ee&&be.return!=null&&be.return()}finally{if(ie)throw ue}}return H}}function u(T,A){(A==null||A>T.length)&&(A=T.length);for(var H=0,ee=new Array(A);H<A;H++)ee[H]=T[H];return ee}function c(T,A){if(T){if(typeof T=="string")return u(T,A);var H=Object.prototype.toString.call(T).slice(8,-1);if(H==="Object"&&T.constructor&&(H=T.constructor.name),H==="Map"||H==="Set")return Array.from(T);if(H==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(H))return u(T,A)}}function d(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function m(T,A){return o(T)||l(T,A)||c(T,A)||d()}n("6762"),n("2fdb");function h(T){if(Array.isArray(T))return u(T)}function f(T){if(typeof Symbol<"u"&&Symbol.iterator in Object(T))return Array.from(T)}function p(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function v(T){return h(T)||f(T)||c(T)||p()}var C=n("a352"),P=n.n(C),M=n("c649");function F(T,A,H){return H===void 0||(T=T||{},T[A]=H),T}function O(T,A){return T.map(function(H){return H.elm}).indexOf(A)}function $(T,A,H,ee){if(!T)return[];var ie=T.map(function(Se){return Se.elm}),ue=A.length-ee,be=v(A).map(function(Se,rt){return rt>=ue?ie.length:ie.indexOf(Se)});return H?be.filter(function(Se){return Se!==-1}):be}function D(T,A){var H=this;this.$nextTick(function(){return H.$emit(T.toLowerCase(),A)})}function V(T){var A=this;return function(H){A.realList!==null&&A["onDrag"+T](H),D.call(A,T,H)}}function N(T){return["transition-group","TransitionGroup"].includes(T)}function W(T){if(!T||T.length!==1)return!1;var A=m(T,1),H=A[0].componentOptions;return H?N(H.tag):!1}function G(T,A,H){return T[H]||(A[H]?A[H]():void 0)}function te(T,A,H){var ee=0,ie=0,ue=G(A,H,"header");ue&&(ee=ue.length,T=T?[].concat(v(ue),v(T)):v(ue));var be=G(A,H,"footer");return be&&(ie=be.length,T=T?[].concat(v(T),v(be)):v(be)),{children:T,headerOffset:ee,footerOffset:ie}}function X(T,A){var H=null,ee=function(Pt,jt){H=F(H,Pt,jt)},ie=Object.keys(T).filter(function(rt){return rt==="id"||rt.startsWith("data-")}).reduce(function(rt,Pt){return rt[Pt]=T[Pt],rt},{});if(ee("attrs",ie),!A)return H;var ue=A.on,be=A.props,Se=A.attrs;return ee("on",ue),ee("props",be),Object.assign(H.attrs,Se),H}var q=["Start","Add","Remove","Update","End"],z=["Choose","Unchoose","Sort","Filter","Clone"],K=["Move"].concat(q,z).map(function(T){return"on"+T}),Q=null,re={options:Object,list:{type:Array,required:!1,default:null},value:{type:Array,required:!1,default:null},noTransitionOnDrag:{type:Boolean,default:!1},clone:{type:Function,default:function(A){return A}},element:{type:String,default:"div"},tag:{type:String,default:null},move:{type:Function,default:null},componentData:{type:Object,required:!1,default:null}},R={name:"draggable",inheritAttrs:!1,props:re,data:function(){return{transitionMode:!1,noneFunctionalComponentMode:!1}},render:function(A){var H=this.$slots.default;this.transitionMode=W(H);var ee=te(H,this.$slots,this.$scopedSlots),ie=ee.children,ue=ee.headerOffset,be=ee.footerOffset;this.headerOffset=ue,this.footerOffset=be;var Se=X(this.$attrs,this.componentData);return A(this.getTag(),Se,ie)},created:function(){this.list!==null&&this.value!==null&&M.b.error("Value and list props are mutually exclusive! Please set one or another."),this.element!=="div"&&M.b.warn("Element props is deprecated please use tag props instead. See https://github.com/SortableJS/Vue.Draggable/blob/master/documentation/migrate.md#element-props"),this.options!==void 0&&M.b.warn("Options props is deprecated, add sortable options directly as vue.draggable item, or use v-bind. See https://github.com/SortableJS/Vue.Draggable/blob/master/documentation/migrate.md#options-props")},mounted:function(){var A=this;if(this.noneFunctionalComponentMode=this.getTag().toLowerCase()!==this.$el.nodeName.toLowerCase()&&!this.getIsFunctional(),this.noneFunctionalComponentMode&&this.transitionMode)throw new Error("Transition-group inside component is not supported. Please alter tag value or remove transition-group. Current tag value: ".concat(this.getTag()));var H={};q.forEach(function(ue){H["on"+ue]=V.call(A,ue)}),z.forEach(function(ue){H["on"+ue]=D.bind(A,ue)});var ee=Object.keys(this.$attrs).reduce(function(ue,be){return ue[Object(M.a)(be)]=A.$attrs[be],ue},{}),ie=Object.assign({},this.options,ee,H,{onMove:function(be,Se){return A.onDragMove(be,Se)}});!("draggable"in ie)&&(ie.draggable=">*"),this._sortable=new P.a(this.rootContainer,ie),this.computeIndexes()},beforeDestroy:function(){this._sortable!==void 0&&this._sortable.destroy()},computed:{rootContainer:function(){return this.transitionMode?this.$el.children[0]:this.$el},realList:function(){return this.list?this.list:this.value}},watch:{options:{handler:function(A){this.updateOptions(A)},deep:!0},$attrs:{handler:function(A){this.updateOptions(A)},deep:!0},realList:function(){this.computeIndexes()}},methods:{getIsFunctional:function(){var A=this._vnode.fnOptions;return A&&A.functional},getTag:function(){return this.tag||this.element},updateOptions:function(A){for(var H in A){var ee=Object(M.a)(H);K.indexOf(ee)===-1&&this._sortable.option(ee,A[H])}},getChildrenNodes:function(){if(this.noneFunctionalComponentMode)return this.$children[0].$slots.default;var A=this.$slots.default;return this.transitionMode?A[0].child.$slots.default:A},computeIndexes:function(){var A=this;this.$nextTick(function(){A.visibleIndexes=$(A.getChildrenNodes(),A.rootContainer.children,A.transitionMode,A.footerOffset)})},getUnderlyingVm:function(A){var H=O(this.getChildrenNodes()||[],A);if(H===-1)return null;var ee=this.realList[H];return{index:H,element:ee}},getUnderlyingPotencialDraggableComponent:function(A){var H=A.__vue__;return!H||!H.$options||!N(H.$options._componentTag)?!("realList"in H)&&H.$children.length===1&&"realList"in H.$children[0]?H.$children[0]:H:H.$parent},emitChanges:function(A){var H=this;this.$nextTick(function(){H.$emit("change",A)})},alterList:function(A){if(this.list){A(this.list);return}var H=v(this.value);A(H),this.$emit("input",H)},spliceList:function(){var A=arguments,H=function(ie){return ie.splice.apply(ie,v(A))};this.alterList(H)},updatePosition:function(A,H){var ee=function(ue){return ue.splice(H,0,ue.splice(A,1)[0])};this.alterList(ee)},getRelatedContextFromMoveEvent:function(A){var H=A.to,ee=A.related,ie=this.getUnderlyingPotencialDraggableComponent(H);if(!ie)return{component:ie};var ue=ie.realList,be={list:ue,component:ie};if(H!==ee&&ue&&ie.getUnderlyingVm){var Se=ie.getUnderlyingVm(ee);if(Se)return Object.assign(Se,be)}return be},getVmIndex:function(A){var H=this.visibleIndexes,ee=H.length;return A>ee-1?ee:H[A]},getComponent:function(){return this.$slots.default[0].componentInstance},resetTransitionData:function(A){if(!(!this.noTransitionOnDrag||!this.transitionMode)){var H=this.getChildrenNodes();H[A].data=null;var ee=this.getComponent();ee.children=[],ee.kept=void 0}},onDragStart:function(A){this.context=this.getUnderlyingVm(A.item),A.item._underlying_vm_=this.clone(this.context.element),Q=A.item},onDragAdd:function(A){var H=A.item._underlying_vm_;if(H!==void 0){Object(M.d)(A.item);var ee=this.getVmIndex(A.newIndex);this.spliceList(ee,0,H),this.computeIndexes();var ie={element:H,newIndex:ee};this.emitChanges({added:ie})}},onDragRemove:function(A){if(Object(M.c)(this.rootContainer,A.item,A.oldIndex),A.pullMode==="clone"){Object(M.d)(A.clone);return}var H=this.context.index;this.spliceList(H,1);var ee={element:this.context.element,oldIndex:H};this.resetTransitionData(H),this.emitChanges({removed:ee})},onDragUpdate:function(A){Object(M.d)(A.item),Object(M.c)(A.from,A.item,A.oldIndex);var H=this.context.index,ee=this.getVmIndex(A.newIndex);this.updatePosition(H,ee);var ie={element:this.context.element,oldIndex:H,newIndex:ee};this.emitChanges({moved:ie})},updateProperty:function(A,H){A.hasOwnProperty(H)&&(A[H]+=this.headerOffset)},computeFutureIndex:function(A,H){if(!A.element)return 0;var ee=v(H.to.children).filter(function(Se){return Se.style.display!=="none"}),ie=ee.indexOf(H.related),ue=A.component.getVmIndex(ie),be=ee.indexOf(Q)!==-1;return be||!H.willInsertAfter?ue:ue+1},onDragMove:function(A,H){var ee=this.move;if(!ee||!this.realList)return!0;var ie=this.getRelatedContextFromMoveEvent(A),ue=this.context,be=this.computeFutureIndex(ie,A);Object.assign(ue,{futureIndex:be});var Se=Object.assign({},A,{relatedContext:ie,draggedContext:ue});return ee(Se,H)},onDragEnd:function(){this.computeIndexes(),Q=null}}};typeof window<"u"&&"Vue"in window&&window.Vue.component("draggable",R);var B=R;i.default=B}}).default})})($b);var jO=$b.exports;const si=en(jO);var xu={};/**
|
||
* vue-class-component v6.3.2
|
||
* (c) 2015-present Evan You
|
||
* @license MIT
|
||
*/Object.defineProperty(xu,"__esModule",{value:!0});function IO(s){return s&&typeof s=="object"&&"default"in s?s.default:s}var jm=IO(T$),NO=typeof Reflect<"u"&&Reflect.defineMetadata;function VO(s,e){Bd(s,e),Object.getOwnPropertyNames(e.prototype).forEach(function(t){Bd(s.prototype,e.prototype,t)}),Object.getOwnPropertyNames(e).forEach(function(t){Bd(s,e,t)})}function Bd(s,e,t){var r=t?Reflect.getOwnMetadataKeys(e,t):Reflect.getOwnMetadataKeys(e);r.forEach(function(i){var n=t?Reflect.getOwnMetadata(i,e,t):Reflect.getOwnMetadata(i,e);t?Reflect.defineMetadata(i,n,s,t):Reflect.defineMetadata(i,n,s)})}var BO={__proto__:[]},UO=BO instanceof Array;function WO(s){return function(e,t,r){var i=typeof e=="function"?e:e.constructor;i.__decorators__||(i.__decorators__=[]),typeof r!="number"&&(r=void 0),i.__decorators__.push(function(n){return s(n,t,r)})}}function zO(){for(var s=[],e=0;e<arguments.length;e++)s[e]=arguments[e];return jm.extend({mixins:s})}function GO(s){var e=typeof s;return s==null||e!=="object"&&e!=="function"}function ZO(s,e){var t=e.prototype._init;e.prototype._init=function(){var n=this,a=Object.getOwnPropertyNames(s);if(s.$options.props)for(var o in s.$options.props)s.hasOwnProperty(o)||a.push(o);a.forEach(function(l){l.charAt(0)!=="_"&&Object.defineProperty(n,l,{get:function(){return s[l]},set:function(u){s[l]=u},configurable:!0})})};var r=new e;e.prototype._init=t;var i={};return Object.keys(r).forEach(function(n){r[n]!==void 0&&(i[n]=r[n])}),i}var Im=["data","beforeCreate","created","beforeMount","mounted","beforeDestroy","destroyed","beforeUpdate","updated","activated","deactivated","render","errorCaptured"];function r1(s,e){e===void 0&&(e={}),e.name=e.name||s._componentTag||s.name;var t=s.prototype;Object.getOwnPropertyNames(t).forEach(function(o){if(o!=="constructor"){if(Im.indexOf(o)>-1){e[o]=t[o];return}var l=Object.getOwnPropertyDescriptor(t,o);l.value!==void 0?typeof l.value=="function"?(e.methods||(e.methods={}))[o]=l.value:(e.mixins||(e.mixins=[])).push({data:function(){var u;return u={},u[o]=l.value,u}}):(l.get||l.set)&&((e.computed||(e.computed={}))[o]={get:l.get,set:l.set})}}),(e.mixins||(e.mixins=[])).push({data:function(){return ZO(this,s)}});var r=s.__decorators__;r&&(r.forEach(function(o){return o(e)}),delete s.__decorators__);var i=Object.getPrototypeOf(s.prototype),n=i instanceof jm?i.constructor:jm,a=n.extend(e);return qO(a,s,n),NO&&VO(a,s),a}function qO(s,e,t){Object.getOwnPropertyNames(e).forEach(function(r){if(r!=="prototype"){var i=Object.getOwnPropertyDescriptor(s,r);if(!(i&&!i.configurable)){var n=Object.getOwnPropertyDescriptor(e,r);if(!UO){if(r==="cid")return;var a=Object.getOwnPropertyDescriptor(t,r);if(!GO(n.value)&&a&&a.value===n.value)return}Object.defineProperty(s,r,n)}}})}function Ab(s){return typeof s=="function"?r1(s):function(e){return r1(e,s)}}Ab.registerHooks=function(e){Im.push.apply(Im,e)};xu.default=Ab;var XO=xu.createDecorator=WO;xu.mixins=zO;function Ke(s){return XO(function(e,t){if(!e.methods)throw new Error("This decorator must be used on a vue component method.");var r=typeof s=="number"?s:s.time,i=e.methods[t],n=0,a=function(){n&&(clearTimeout(n),n=0)};e.methods[t]=function(){for(var o=this,l=[],u=0;u<arguments.length;u++)l[u]=arguments[u];a(),n=setTimeout(function(){n=0,i.apply(o,l)},r)}})}var YO=Object.defineProperty,JO=Object.getOwnPropertyDescriptor,wu=(s,e,t,r)=>{for(var i=r>1?void 0:r?JO(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&YO(e,t,i),i};let Ti=class extends k(L,vt){constructor(){super(...arguments),this.mdiPencil=bt,this.mdiDelete=Ue,this.mdiSleep=SS,this.mdiPause=Zp,this.mdiPrinter3dNozzle=Us,this.mdiPlus=qp,this.mdiDragVertical=Wa,this.mdiPalette=_u,this.mdiMagnify=rn,this.rules={required:s=>s!==""||"required",groupUnique:s=>!this.existsGroupName(s)||"Name already exists"},this.boolFormEdit=!1,this.editGroupId="",this.searchMacros=""}get groupColors(){return[{text:this.$t("Settings.MacrosTab.Primary"),value:"primary"},{text:this.$t("Settings.MacrosTab.Secondary"),value:"secondary"},{text:this.$t("Settings.MacrosTab.Success"),value:"success"},{text:this.$t("Settings.MacrosTab.Warning"),value:"warning"},{text:this.$t("Settings.MacrosTab.Error"),value:"error"},{text:this.$t("Settings.MacrosTab.Custom"),value:"custom"}]}get macroColors(){const s=[...this.groupColors],e=s.findIndex(t=>t.value==="custom");return e!==-1&&s.splice(e,1),s.push({text:this.$t("Settings.MacrosTab.Group"),value:"group"}),s}get allMacros(){var e;return((e=this.$store.getters["printer/getMacros"])!=null?e:[]).filter(t=>{var r;return t.name.toLowerCase().includes(this.searchMacros.toLowerCase())||((r=t.description)==null?void 0:r.toLowerCase().includes(this.searchMacros.toLowerCase()))})}get availableMacros(){return this.allMacros.filter(s=>!this.editGroupUsedMacros.includes(s.name))}get groups(){var s;return(s=this.$store.getters["gui/macros/getAllMacrogroups"])!=null?s:[]}get editGroupUsedMacros(){var s,e,t;return(t=(e=(s=this.editGroup)==null?void 0:s.macros)==null?void 0:e.map(r=>r.name))!=null?t:[]}get editGroup(){return this.$store.getters["gui/macros/getMacrogroup"](this.editGroupId)}get editGroupMacros(){var e,t;const s=(t=(e=this.editGroup)==null?void 0:e.macros)!=null?t:[];return s.sort((r,i)=>r.pos-i.pos),s}set editGroupMacros(s){}existsGroupName(s){return this.groups.findIndex(e=>e.name===s&&e.id!=this.editGroupId)>=0}clearColorObject(s){return typeof s=="object"&&"hex"in s&&(s=s.hex),s.length>7&&(s=s.substr(0,7)),s}updateShowGeneral(s){this.$emit("update:showGeneral",s)}async addGroup(){const s={name:"",color:"primary",colorCustom:"#fff",showInStandby:!0,showInPause:!0,showInPrinting:!0};this.editGroupId=await this.$store.dispatch("gui/macros/groupStore",{values:s}),this.boolFormEdit=!0}editMacrogroup(s){this.boolFormEdit=!0,this.editGroupId=s.id}deleteMacrogroup(s){this.$store.dispatch("gui/macros/groupDelete",s)}addMacroToGroup(s){this.$store.dispatch("gui/macros/addMacroToMacrogroup",{id:this.editGroupId,macro:s.name})}updateMacroFromGroup(s,e,t){this.$store.dispatch("gui/macros/updateMacroFromMacrogroup",{id:this.editGroupId,macro:s.name,option:e,value:t})}updateMacroOrder(s){var n,a;const e=(n=s.moved.oldIndex)!=null?n:0,t=(a=s.moved.newIndex)!=null?a:0,r=this.editGroupMacros[e].pos,i=this.editGroupMacros[t].pos;this.updateMacroFromGroup(this.editGroupMacros[e],"pos",i),this.updateMacroFromGroup(this.editGroupMacros[t],"pos",r)}changeColorMacroFromGroup(s){let e=this.macroColors.findIndex(i=>i.value===s.color)+1;const t=this.macroColors.length-1;e>t&&(e=0);const r=this.macroColors[e].value;this.updateMacroFromGroup(s,"color",r)}removeMacroFromGroup(s){this.$store.dispatch("gui/macros/removeMacroFromMacrogroup",{id:this.editGroupId,macro:s.name})}existsMacro(s){return this.allMacros.findIndex(e=>e.name.toLowerCase()===s.toLowerCase())!==-1}getMacroDescription(s){var t;const e=this.allMacros.find(r=>r.name.toLowerCase()===s.toLowerCase());return e?(t=e==null?void 0:e.description)!=null?t:null:this.$t("Settings.MacrosTab.DeletedMacro")}updateMacrogroupOption(s,e){const t={};t[s]=e,this.$store.dispatch("gui/macros/groupUpdate",{id:this.editGroupId,values:t})}updateGroupOptionName(s){this.updateMacrogroupOption("name",s)}updateGroupOptionColor(s){this.updateMacrogroupOption("color",s)}updateGroupOptionColorCustom(s){this.updateMacrogroupOption("colorCustom",this.clearColorObject(s))}updateGroupOptionShowInStandby(s){this.updateMacrogroupOption("showInStandby",s)}updateGroupOptionShowInPause(s){this.updateMacrogroupOption("showInPause",s)}updateGroupOptionShowInPrinting(s){this.updateMacrogroupOption("showInPrinting",s)}updatedBoolFormEdit(s){this.updateShowGeneral(!s)}cancelEditMacrogroup(){this.boolFormEdit=!1,this.$emit("scrollToTop")}};wu([Ke(250)],Ti.prototype,"updateGroupOptionName",1);wu([Ke(250)],Ti.prototype,"updateGroupOptionColorCustom",1);wu([he("boolFormEdit")],Ti.prototype,"updatedBoolFormEdit",1);Ti=wu([S({components:{SettingsRow:j,draggable:si}})],Ti);var KO=function(){var r,i,n,a;var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e.boolFormEdit===!1?[t(Z,[t("h3",{staticClass:"text-h5 mb-3"},[e._v(e._s(e.$t("Settings.MacrosTab.Macrogroups")))]),e.groups.length?e._l(e.groups,function(o,l){return t("div",{key:l},[l?t(I,{staticClass:"my-2"}):e._e(),t(j,{attrs:{title:o.name!==""?o.name:"<"+e.$t("Settings.MacrosTab.UnknownGroup")+">","sub-title":e.$tc("Settings.MacrosTab.CountMacros","macros"in o?o.macros.length:0,{count:"macros"in o?o.macros.length:0}),"dynamic-slot-width":!0}},[t(g,{staticClass:"ml-3",attrs:{small:"",outlined:""},on:{click:function(u){return e.editMacrogroup(o)}}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiPencil))]),e._v(" "+e._s(e.$t("Settings.Edit"))+" ")],1),t(g,{staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:"error"},on:{click:function(u){return e.deleteMacrogroup(o.id)}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiDelete))])],1)],1)],1)}):[t(x,[t(b,[t("p",{staticClass:"mb-0 text-center font-italic"},[e._v(e._s(e.$t("Settings.MacrosTab.NoGroups")))])])],1)]],2),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:"",color:"primary"},on:{click:e.addGroup}},[e._v(e._s(e.$t("Settings.MacrosTab.AddGroup")))])],1)]:e.boolFormEdit?[t(Z,[t("h3",{staticClass:"text-h5 mb-3"},[e._v(e._s(e.$t("Settings.MacrosTab.EditGroup")))]),t(j,{attrs:{title:e.$t("Settings.MacrosTab.Name")}},[t(se,{attrs:{"hide-details":"auto",rules:[e.rules.required,e.rules.groupUnique],dense:"",outlined:""},on:{change:e.updateGroupOptionName},model:{value:e.editGroup.name,callback:function(o){e.$set(e.editGroup,"name",o)},expression:"editGroup.name"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.MacrosTab.Color")}},[t(ke,{attrs:{items:e.groupColors,outlined:"",dense:"","hide-details":"",attach:""},on:{change:e.updateGroupOptionColor},model:{value:e.editGroup.color,callback:function(o){e.$set(e.editGroup,"color",o)},expression:"editGroup.color"}})],1),((r=e.editGroup)==null?void 0:r.color)==="custom"?[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.MacrosTab.CustomColor")}},[t(ye,{attrs:{bottom:"",left:"","offset-y":"","close-on-content-click":!1},scopedSlots:e._u([{key:"activator",fn:function({on:o,attrs:l}){return[t(g,e._g(e._b({staticClass:"minwidth-0 px-5",attrs:{color:e.editGroup.colorCustom,small:""}},"v-btn",l,!1),o))]}}],null,!1,3888687373)},[t(Xt,{attrs:{value:e.editGroup.colorCustom,"hide-mode-switch":"",mode:"rgba"},on:{"update:color":e.updateGroupOptionColorCustom}})],1)],1)]:e._e(),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.MacrosTab.Status")}},[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:o,attrs:l}){var u;return[t(g,e._g(e._b({staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:(u=e.editGroup)!=null&&u.showInStandby?"":"secondary"},on:{click:function(c){var d;return e.updateGroupOptionShowInStandby(!((d=e.editGroup)!=null&&d.showInStandby))}}},"v-btn",l,!1),o),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiSleep))])],1)]}}])},[t("span",[e._v(e._s(e.$t("Settings.MacrosTab.ShowInStateStandby")))])]),t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:o,attrs:l}){var u;return[t(g,e._g(e._b({staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:(u=e.editGroup)!=null&&u.showInPause?"":"secondary"},on:{click:function(c){var d;return e.updateGroupOptionShowInPause(!((d=e.editGroup)!=null&&d.showInPause))}}},"v-btn",l,!1),o),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiPause))])],1)]}}])},[t("span",[e._v(e._s(e.$t("Settings.MacrosTab.ShowInStatePaused")))])]),t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:o,attrs:l}){var u;return[t(g,e._g(e._b({staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:(u=e.editGroup)!=null&&u.showInPrinting?"":"secondary"},on:{click:function(c){var d;return e.updateGroupOptionShowInPrinting(!((d=e.editGroup)!=null&&d.showInPrinting))}}},"v-btn",l,!1),o),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiPrinter3dNozzle))])],1)]}}])},[t("span",[e._v(e._s(e.$t("Settings.MacrosTab.ShowInStatePrinting")))])])],1),t(I,{staticClass:"my-2"}),t("h3",{staticClass:"text-h5 mt-6 mb-3"},[e._v(e._s(e.$t("Settings.MacrosTab.GroupMacros")))]),(i=e.editGroup)!=null&&i.macros&&((a=(n=e.editGroup)==null?void 0:n.macros)!=null&&a.length)?[t("draggable",{attrs:{handle:".handle","ghost-class":"ghost",group:"macros"},on:{change:e.updateMacroOrder},model:{value:e.editGroupMacros,callback:function(o){e.editGroupMacros=o},expression:"editGroupMacros"}},e._l(e.editGroupMacros,function(o,l){return t(x,{key:o.name,staticClass:"my-2 mx-0",style:e.draggableBgStyle},[t(b,{staticClass:"col-auto pr-0 d-flex py-2"},[t(_,{staticClass:"handle"},[e._v(e._s(e.mdiDragVertical))])],1),t(b,{staticClass:"py-2"},[t(j,{key:"groupMacro_macro_"+l,attrs:{title:o.name,"sub-title":e.getMacroDescription(o.name),"dynamic-slot-width":!0}},[e.existsMacro(o.name)?[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:u,attrs:c}){return[t(g,e._g(e._b({staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:o.color},on:{click:function(d){return e.changeColorMacroFromGroup(o)}}},"v-btn",c,!1),u),[t(_,{attrs:{small:"",left:""}},[e._v(e._s(e.mdiPalette))]),e._v(" "+e._s(o.color)+" ")],1)]}}],null,!0)},[t("span",[e._v(e._s(e.$t("Settings.MacrosTab.ChangeMacroColor")))])]),t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:u,attrs:c}){return[t(g,e._g(e._b({staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:o.showInStandby?"":"secondary"},on:{click:function(d){return e.updateMacroFromGroup(o,"showInStandby",!o.showInStandby)}}},"v-btn",c,!1),u),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiSleep))])],1)]}}],null,!0)},[t("span",[e._v(e._s(e.$t("Settings.MacrosTab.ShowInStateStandby")))])]),t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:u,attrs:c}){return[t(g,e._g(e._b({staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:o.showInPause?"":"secondary"},on:{click:function(d){return e.updateMacroFromGroup(o,"showInPause",!o.showInPause)}}},"v-btn",c,!1),u),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiPause))])],1)]}}],null,!0)},[t("span",[e._v(e._s(e.$t("Settings.MacrosTab.ShowInStatePaused")))])]),t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:u,attrs:c}){return[t(g,e._g(e._b({staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:o.showInPrinting?"":"secondary"},on:{click:function(d){return e.updateMacroFromGroup(o,"showInPrinting",!o.showInPrinting)}}},"v-btn",c,!1),u),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiPrinter3dNozzle))])],1)]}}],null,!0)},[t("span",[e._v(e._s(e.$t("Settings.MacrosTab.ShowInStatePrinting")))])])]:e._e(),t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:u,attrs:c}){return[t(g,e._g(e._b({staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:"error"},on:{click:function(d){return e.removeMacroFromGroup(o)}}},"v-btn",c,!1),u),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiDelete))])],1)]}}],null,!0)},[t("span",[e._v(e._s(e.$t("Settings.MacrosTab.DeleteMacroFromGroup")))])])],2)],1)],1)}),1)]:[t(x,[t(b,[t("p",{staticClass:"mb-0 text-center font-italic"},[e._v(e._s(e.$t("Settings.MacrosTab.NoMacrosInGroup")))])])],1)],t(x,{staticClass:"mt-6 mb-3 flex-column flex-md-row"},[t(b,{staticClass:"py-0 align-content-center mb-3 mb-md-0"},[t("h3",{staticClass:"text-h5"},[e._v(e._s(e.$t("Settings.MacrosTab.AvailableMacros")))])]),t(b,{staticClass:"py-0"},[t(se,{attrs:{"append-icon":e.mdiMagnify,label:e.$t("Settings.MacrosTab.Search"),"single-line":"",outlined:"",clearable:"","hide-details":"",dense:""},model:{value:e.searchMacros,callback:function(o){e.searchMacros=o},expression:"searchMacros"}})],1)],1),e.availableMacros.length?[e._l(e.availableMacros,function(o,l){return[l?t(I,{key:"availableMacro_deliver_"+l,staticClass:"my-2"}):e._e(),t(j,{key:"availableMacro_macro_"+l,attrs:{title:o.name,"sub-title":o.description,"dynamic-slot-width":!0}},[t(g,{staticClass:"ml-3",attrs:{small:"",outlined:""},on:{click:function(u){return e.addMacroToGroup(o)}}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiPlus))]),e._v(" "+e._s(e.$t("Settings.MacrosTab.Add"))+" ")],1)],1)]})]:[t(x,[t(b,[t("p",{staticClass:"mb-0 text-center font-italic"},[e._v(e._s(e.$t("Settings.MacrosTab.NoAvailableMacros")))])])],1)]],2),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:""},on:{click:e.cancelEditMacrogroup}},[e._v(e._s(e.$t("Settings.Close")))])],1)]:e._e()],2)},QO=[],e4=E(Ti,KO,QO,!1,null,null);const Fb=e4.exports;var t4=Object.getOwnPropertyDescriptor,s4=(s,e,t,r)=>{for(var i=r>1?void 0:r?t4(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Nm=class extends k(L){constructor(){super(...arguments),this.showGeneral=!0}get modes(){return[{text:this.$t("Settings.MacrosTab.Simple"),value:"simple"},{text:this.$t("Settings.MacrosTab.Expert"),value:"expert"}]}get mode(){var e,t,r;return(r=(t=(e=this.$store.state.gui)==null?void 0:e.macros)==null?void 0:t.mode)!=null?r:"simple"}set mode(e){this.$store.dispatch("gui/macros/saveSetting",{name:"mode",value:e})}updateShowGeneral(e){this.showGeneral=e}scrollToTop(){this.$emit("scrollToTop")}};Nm=s4([S({components:{SettingsMacrosTabExpert:Fb,SettingsMacrosTabSimple:Cb,SettingsRow:j}})],Nm);var r4=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{attrs:{flat:""}},[e.showGeneral?t(Z,[t("h3",{staticClass:"text-h5 mb-3"},[e._v(e._s(e.$t("Settings.MacrosTab.General")))]),t(j,{attrs:{title:e.$t("Settings.MacrosTab.Management")}},[t(ke,{attrs:{items:e.modes,outlined:"",dense:"","hide-details":"",attach:""},model:{value:e.mode,callback:function(r){e.mode=r},expression:"mode"}})],1),t(I,{staticClass:"my-2"})],1):e._e(),e.mode==="expert"?[t(Fb,{on:{"update:showGeneral":e.updateShowGeneral,scrollToTop:e.scrollToTop}})]:[t(Cb)]],2)},i4=[],n4=E(Nm,r4,i4,!1,null,null);const a4=n4.exports;var o4=Object.getOwnPropertyDescriptor,l4=(s,e,t,r)=>{for(var i=r>1?void 0:r?o4(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Hl=class extends y{get homing_origin(){var s,e,t;return(t=(e=(s=this.$store.state.printer)==null?void 0:s.gcode_move)==null?void 0:e.homing_origin)!=null?t:[]}get z_gcode_offset(){return this.homing_origin.length>1?Math.round(this.homing_origin[2]*1e3)/1e3:0}get commands(){var s,e;return(e=(s=this.$store.state.printer.gcode)==null?void 0:s.commands)!=null?e:{}}get settings(){var s,e;return(e=(s=this.$store.state.printer.configfile)==null?void 0:s.settings)!=null?e:{}}get kinematics(){var s,e;return(e=(s=this.settings.printer)==null?void 0:s.kinematics)!=null?e:"cartesian"}get stepper_name(){return this.kinematics==="delta"?"stepper_a":"stepper_z"}get endstop_pin(){var s,e,t;return(t=(e=(s=this.settings[this.stepper_name])==null?void 0:s.endstop_pin)==null?void 0:e.trim())!=null?t:null}get zOffset(){var s,e;return(e=(s=this.$store.state.printer)==null?void 0:s.gcode_move)==null?void 0:e.homing_origin[2].toFixed(3)}get isEndstopProbe(){return this.endstop_pin.replaceAll(" ","").search("probe:z_virtual_endstop")!==-1}get existZOffsetApplyProbe(){return"Z_OFFSET_APPLY_PROBE"in this.commands}get existZOffsetApplyEndstop(){return"Z_OFFSET_APPLY_ENDSTOP"in this.commands}get showSaveButton(){return this.z_gcode_offset===0?!1:this.isEndstopProbe&&this.existZOffsetApplyProbe?!0:!this.isEndstopProbe&&this.existZOffsetApplyEndstop}get autoSaveZOffsetOption(){return this.isEndstopProbe&&this.existZOffsetApplyProbe?"Z_OFFSET_APPLY_PROBE":"Z_OFFSET_APPLY_ENDSTOP"}};Hl=l4([S],Hl);var c4=Object.getOwnPropertyDescriptor,u4=(s,e,t,r)=>{for(var i=r>1?void 0:r?c4(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Vm=class extends k(L,Je,Hl){constructor(){super(...arguments),this.mdiGamepad=Up,this.mdiPrinter3dNozzle=Us}get controlStyles(){return[{text:this.$t("Settings.ControlTab.Bars"),value:"bars"},{text:this.$t("Settings.ControlTab.Circle"),value:"circle"},{text:this.$t("Settings.ControlTab.Cross"),value:"cross"}]}get controlStyle(){var e;return(e=this.$store.state.gui.control.style)!=null?e:"bar"}set controlStyle(e){this.$store.dispatch("gui/saveSetting",{name:"control.style",value:e})}get hideDuringPrint(){var e;return(e=this.$store.state.gui.control.hideDuringPrint)!=null?e:!1}set hideDuringPrint(e){this.$store.dispatch("gui/saveSetting",{name:"control.hideDuringPrint",value:e})}get actionOptions(){let e=[{text:this.$t("Settings.ControlTab.MotorsOff",{isDefault:this.defaultActionButton==="m84"?this.$t("Settings.ControlTab.IsDefault"):""}),value:"m84"}];return this.existsQGL&&e.push({text:this.$t("Settings.ControlTab.QuadGantryLevel",{isDefault:this.defaultActionButton==="qgl"?this.$t("Settings.ControlTab.IsDefault"):""}),value:"qgl"}),this.existsZtilt&&e.push({text:this.$t("Settings.ControlTab.ZTiltAdjust",{isDefault:this.defaultActionButton==="ztilt"?this.$t("Settings.ControlTab.IsDefault"):""}),value:"ztilt"}),e}get actionButton(){var e;return(e=this.$store.state.gui.control.actionButton)!=null?e:this.defaultActionButton}set actionButton(e){this.$store.dispatch("gui/saveSetting",{name:"control.actionButton",value:e})}get defaultActionButton(){return this.$store.getters["gui/getDefaultControlActionButton"]}get enableXYHoming(){var e;return(e=this.$store.state.gui.control.enableXYHoming)!=null?e:!1}set enableXYHoming(e){this.$store.dispatch("gui/saveSetting",{name:"control.enableXYHoming",value:e})}get reverseX(){return this.$store.state.gui.control.reverseX}set reverseX(e){this.$store.dispatch("gui/saveSetting",{name:"control.reverseX",value:e})}get reverseY(){return this.$store.state.gui.control.reverseY}set reverseY(e){this.$store.dispatch("gui/saveSetting",{name:"control.reverseY",value:e})}get reverseZ(){return this.$store.state.gui.control.reverseZ}set reverseZ(e){this.$store.dispatch("gui/saveSetting",{name:"control.reverseZ",value:e})}get feedrateXY(){return this.$store.state.gui.control.feedrateXY}set feedrateXY(e){this.$store.dispatch("gui/saveSetting",{name:"control.feedrateXY",value:e})}get feedrateZ(){return this.$store.state.gui.control.feedrateZ}set feedrateZ(e){this.$store.dispatch("gui/saveSetting",{name:"control.feedrateZ",value:e})}get offsetsZ(){return this.$store.state.gui.control.offsetsZ.sort(function(t,r){return t-r})}set offsetsZ(e){const t=new Set;for(const r of e)t.add(Math.abs(r));this.$store.dispatch("gui/saveSetting",{name:"control.offsetsZ",value:Array.from(t)})}get stepsAll(){const e=this.$store.state.gui.control.stepsAll;return(e!=null?e:[]).sort(function(t,r){return r-t})}set stepsAll(e){const t=[];for(const i of e)t.push(Math.abs(i));const r=t.filter(this.onlyUnique);this.$store.dispatch("gui/saveSetting",{name:"control.stepsAll",value:r})}get stepsXY(){return this.$store.state.gui.control.stepsXY.sort(function(t,r){return r-t})}set stepsXY(e){const t=[];for(const i of e)t.push(Math.abs(i));const r=t.filter(this.onlyUnique);this.$store.dispatch("gui/saveSetting",{name:"control.stepsXY",value:r})}get stepsZ(){return this.$store.state.gui.control.stepsZ.sort(function(t,r){return r-t})}set stepsZ(e){const t=[];for(const i of e)t.push(Math.abs(i));const r=t.filter(this.onlyUnique);this.$store.dispatch("gui/saveSetting",{name:"control.stepsZ",value:r})}get stepsCircleXY(){return this.$store.state.gui.control.stepsCircleXY.sort(function(t,r){return r-t})}set stepsCircleXY(e){const t=[];for(const i of e)t.push(Math.abs(i));const r=t.filter(this.onlyUnique);this.$store.dispatch("gui/saveSetting",{name:"control.stepsCircleXY",value:r})}get stepsCircleZ(){return this.$store.state.gui.control.stepsCircleZ.sort(function(t,r){return r-t})}set stepsCircleZ(e){const t=[];for(const i of e)t.push(Math.abs(i));const r=t.filter(this.onlyUnique);this.$store.dispatch("gui/saveSetting",{name:"control.stepsCircleZ",value:r})}get feedamountsE(){return this.$store.state.gui.control.extruder.feedamounts.sort(function(t,r){return r-t})}set feedamountsE(e){const t=[];for(const i of e)t.push(Math.abs(i));const r=t.filter(this.onlyUnique);this.$store.dispatch("gui/saveSetting",{name:"control.extruder.feedamounts",value:r})}get feedratesE(){return this.$store.state.gui.control.extruder.feedrates.sort(function(t,r){return r-t})}set feedratesE(e){const t=[];for(const i of e)t.push(Math.abs(i));const r=t.filter(this.onlyUnique);this.$store.dispatch("gui/saveSetting",{name:"control.extruder.feedrates",value:r})}get showEstimatedExtrusionInfo(){return this.$store.state.gui.control.extruder.showEstimatedExtrusionInfo}set showEstimatedExtrusionInfo(e){this.$store.dispatch("gui/saveSetting",{name:"control.extruder.showEstimatedExtrusionInfo",value:e})}get offsetZSaveOption(){var e;return(e=this.$store.state.gui.control.offsetZSaveOption)!=null?e:null}set offsetZSaveOption(e){this.$store.dispatch("gui/saveSetting",{name:"control.offsetZSaveOption",value:e})}get offsetZSaveOptions(){const e=this.autoSaveZOffsetOption.replace(/Z_OFFSET_APPLY_/g,""),t=[{value:null,text:"Auto (".concat(e,")")}];return this.existZOffsetApplyEndstop&&t.push({value:"Z_OFFSET_APPLY_ENDSTOP",text:"ENDSTOP"}),this.existZOffsetApplyProbe&&t.push({value:"Z_OFFSET_APPLY_PROBE",text:"PROBE"}),t}blurFeedrateXY(){this.feedrateXY>0||(this.feedrateXY=100)}blurFeedrateZ(){this.feedrateZ>0||(this.feedrateZ=25)}onlyUnique(e,t,r){return r.indexOf(e)===t}mounted(){var e;(e=this.$refs.formControlExtruder)==null||e.validate()}};Vm=u4([S({components:{SettingsRow:j}})],Vm);var d4=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{attrs:{flat:""}},[t(Z,[t(or,{ref:"formControlExtruder"},[t("div",{staticClass:"d-flex align-center"},[t(_,{staticStyle:{opacity:"0.7"}},[e._v(e._s(e.mdiGamepad))]),t(gt,{staticClass:"mx-n2"},[e._v(" "+e._s(e.$t("Panels.ToolheadControlPanel.Headline"))+" ")]),t(I,{staticClass:"ml-3"})],1),t(j,{attrs:{title:e.$t("Settings.ControlTab.Style")}},[t(ke,{attrs:{items:e.controlStyles,outlined:"",dense:"","hide-details":"",attach:""},model:{value:e.controlStyle,callback:function(r){e.controlStyle=r},expression:"controlStyle"}})],1),t(I,{staticClass:"my-2"}),["circle","cross"].includes(e.controlStyle)&&e.actionOptions.length>1?[t(j,{attrs:{title:e.$t("Settings.ControlTab.OverwriteActionButton")}},[t(ke,{attrs:{items:e.actionOptions,outlined:"",dense:"","hide-details":"",attach:""},model:{value:e.actionButton,callback:function(r){e.actionButton=r},expression:"actionButton"}})],1),t(I,{staticClass:"my-2"})]:e._e(),t(j,{attrs:{title:e.$t("Settings.ControlTab.HideDuringPrint"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.hideDuringPrint,callback:function(r){e.hideDuringPrint=r},expression:"hideDuringPrint"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.ControlTab.EnableXYHoming"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.enableXYHoming,callback:function(r){e.enableXYHoming=r},expression:"enableXYHoming"}})],1),t(I,{staticClass:"my-2"}),["circle","cross"].includes(e.controlStyle)?[t(j,{attrs:{title:e.$t("Settings.ControlTab.InvertXMovement"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.reverseX,callback:function(r){e.reverseX=r},expression:"reverseX"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.ControlTab.InvertYMovement"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.reverseY,callback:function(r){e.reverseY=r},expression:"reverseY"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.ControlTab.InvertZMovement"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.reverseZ,callback:function(r){e.reverseZ=r},expression:"reverseZ"}})],1),t(I,{staticClass:"my-2"})]:e._e(),t(j,{attrs:{title:e.$t("Settings.ControlTab.SpeedXY")}},[t(se,{attrs:{type:"number",suffix:"mm/s","hide-details":"auto",rules:[r=>r>0||e.$t("Settings.ControlTab.ValueGreaterThan",{value:"0"})],outlined:"",dense:"","hide-spin-buttons":""},on:{blur:e.blurFeedrateXY},model:{value:e.feedrateXY,callback:function(r){e.feedrateXY=r},expression:"feedrateXY"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.ControlTab.SpeedZ")}},[t(se,{attrs:{type:"number",suffix:"mm/s","hide-details":"auto",rules:[r=>r>0||e.$t("Settings.ControlTab.ValueGreaterThan",{value:"0"})],outlined:"",dense:"","hide-spin-buttons":""},on:{blur:e.blurFeedrateZ},model:{value:e.feedrateZ,callback:function(r){e.feedrateZ=r},expression:"feedrateZ"}})],1),t(I,{staticClass:"my-2"}),e.controlStyle==="cross"?[t(j,{attrs:{title:e.$t("Settings.ControlTab.MoveDistancesInMm"),"mobile-second-row":!0}},[t(Zs,{attrs:{"hide-selected":"","hide-details":"auto",multiple:"","small-chips":"","deletable-chips":!0,"append-icon":"",type:"number",rules:[r=>r.length>0||e.$t("Settings.ControlTab.MinimumValues",{minimum:"1"}),r=>r.length<=9||e.$t("Settings.ControlTab.MaximumValuesVisibility",{maximum:"9"})],dense:"",outlined:"","hide-spin-buttons":""},model:{value:e.stepsAll,callback:function(r){e.stepsAll=r},expression:"stepsAll"}})],1),t(I,{staticClass:"my-2"})]:e.controlStyle==="circle"?[t(j,{attrs:{title:e.$t("Settings.ControlTab.MoveDistancesXYInMm"),"mobile-second-row":!0}},[t(Zs,{attrs:{"hide-selected":"","hide-details":"auto",multiple:"","small-chips":"","deletable-chips":!0,"append-icon":"",type:"number",rules:[r=>r.length>0||e.$t("Settings.ControlTab.MinimumValues",{minimum:"1"}),r=>r.length<=4||e.$t("Settings.ControlTab.MaximumValues",{maximum:"4"})],dense:"",outlined:"","hide-spin-buttons":""},model:{value:e.stepsCircleXY,callback:function(r){e.stepsCircleXY=r},expression:"stepsCircleXY"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.ControlTab.MoveDistancesZInMm"),"mobile-second-row":!0}},[t(Zs,{attrs:{"hide-selected":"","hide-details":"auto",multiple:"","small-chips":"","deletable-chips":!0,"append-icon":"",type:"number",rules:[r=>r.length>0||e.$t("Settings.ControlTab.MinimumValues",{minimum:"1"}),r=>r.length<=4||e.$t("Settings.ControlTab.MaximumValues",{maximum:"4"})],dense:"",outlined:"","hide-spin-buttons":""},model:{value:e.stepsCircleZ,callback:function(r){e.stepsCircleZ=r},expression:"stepsCircleZ"}})],1),t(I,{staticClass:"my-2"})]:[t(j,{attrs:{title:e.$t("Settings.ControlTab.MoveDistancesXYInMm"),"mobile-second-row":!0}},[t(Zs,{attrs:{"hide-selected":"","hide-details":"auto",multiple:"","small-chips":"","deletable-chips":!0,"append-icon":"",type:"number",rules:[r=>r.length>0||e.$t("Settings.ControlTab.MinimumValues",{minimum:"1"}),r=>r.length<=3||e.$t("Settings.ControlTab.MaximumValuesVisibility",{maximum:"3"})],dense:"",outlined:"","hide-spin-buttons":""},model:{value:e.stepsXY,callback:function(r){e.stepsXY=r},expression:"stepsXY"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.ControlTab.MoveDistancesZInMm"),"mobile-second-row":!0}},[t(Zs,{attrs:{"hide-selected":"","hide-details":"auto",multiple:"","small-chips":"","deletable-chips":!0,"append-icon":"",type:"number",rules:[r=>r.length>0||e.$t("Settings.ControlTab.MinimumValues",{minimum:"1"}),r=>r.length<=3||e.$t("Settings.ControlTab.MaximumValuesVisibility",{maximum:"3"})],dense:"",outlined:"","hide-spin-buttons":""},model:{value:e.stepsZ,callback:function(r){e.stepsZ=r},expression:"stepsZ"}})],1),t(I,{staticClass:"my-2"})],e.klipperReadyForGui&&e.endstop_pin!==null?[t(j,{attrs:{title:e.$t("Settings.ControlTab.ZOffsetSaveOption"),"sub-title":e.$t("Settings.ControlTab.ZOffsetSaveOptionDescription")}},[t(ke,{staticClass:"mt-0",attrs:{items:e.offsetZSaveOptions,"hide-details":"",outlined:"",dense:""},model:{value:e.offsetZSaveOption,callback:function(r){e.offsetZSaveOption=r},expression:"offsetZSaveOption"}})],1),t(I,{staticClass:"my-2"})]:e._e(),t(j,{attrs:{title:e.$t("Settings.ControlTab.ZOffsetIncrements"),"mobile-second-row":!0}},[t(Zs,{attrs:{"hide-selected":"","hide-details":"auto",multiple:"","small-chips":"","deletable-chips":!0,"append-icon":"",type:"number",rules:[r=>r.length>0||e.$t("Settings.ControlTab.MinimumValues",{minimum:"1"}),r=>r.length<=4||e.$t("Settings.ControlTab.MaximumValuesVisibility",{maximum:"4"})],dense:"",outlined:"","hide-spin-buttons":""},model:{value:e.offsetsZ,callback:function(r){e.offsetsZ=r},expression:"offsetsZ"}})],1),t("div",{staticClass:"d-flex align-center"},[t(_,{staticStyle:{opacity:"0.7"}},[e._v(e._s(e.mdiPrinter3dNozzle))]),t(gt,{staticClass:"mx-n2"},[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.Headline"))+" ")]),t(I,{staticClass:"ml-3"})],1),t(j,{attrs:{title:e.$t("Settings.ControlTab.MoveDistancesEInMm"),"mobile-second-row":!0}},[t(Zs,{attrs:{"hide-selected":"","hide-details":"auto",multiple:"","small-chips":"","deletable-chips":!0,"append-icon":"",type:"number",rules:[r=>r.length>0||e.$t("Settings.ControlTab.MinimumValues",{minimum:"1"}),r=>r.length<=5||e.$t("Settings.ControlTab.MaximumValuesVisibility",{maximum:"5"})],dense:"",outlined:"","hide-spin-buttons":""},model:{value:e.feedamountsE,callback:function(r){e.feedamountsE=r},expression:"feedamountsE"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.ControlTab.SpeedEInMms"),"mobile-second-row":!0}},[t(Zs,{attrs:{"hide-selected":"","hide-details":"auto",multiple:"","small-chips":"","deletable-chips":!0,"append-icon":"",type:"number",rules:[r=>r.length>0||e.$t("Settings.ControlTab.MinimumValues",{minimum:"1"}),r=>r.length<=5||e.$t("Settings.ControlTab.MaximumValuesVisibility",{maximum:"5"})],dense:"",outlined:"","hide-spin-buttons":""},model:{value:e.feedratesE,callback:function(r){e.feedratesE=r},expression:"feedratesE"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.ControlTab.EstimatedExtrusionInfo"),"sub-title":e.$t("Settings.ControlTab.EstimatedExtrusionInfoDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.showEstimatedExtrusionInfo,callback:function(r){e.showEstimatedExtrusionInfo=r},expression:"showEstimatedExtrusionInfo"}})],1)],2)],1)],1)},m4=[],h4=E(Vm,d4,m4,!1,null,null);const p4=h4.exports;var f4=Object.defineProperty,g4=Object.getOwnPropertyDescriptor,gf=(s,e,t,r)=>{for(var i=r>1?void 0:r?g4(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&f4(e,t,i),i};let la=class extends k(L){constructor(){super(...arguments),this.mdiFilter=Zw,this.mdiFilterOff=qw,this.mdiPencil=bt,this.mdiDelete=Ue,this.mdiConsoleLine=Ua,this.form={bool:!1,valid:!1,name:"",regex:"",id:null},this.rules={required:e=>e!==""||"required",unique:e=>!this.existsPresetName(e)||"Name already exists"},this.consoleHeightTmp=300}mounted(){this.consoleHeightTmp=this.consoleHeight}get consoleFilters(){var e;return(e=this.$store.getters["gui/console/getConsolefilters"])!=null?e:[]}get availableDirections(){return[{text:this.$t("Settings.ConsoleTab.DirectionTable"),value:"table"},{text:this.$t("Settings.ConsoleTab.DirectionShell"),value:"shell"}]}get consoleDirection(){var e;return(e=this.$store.state.gui.console.direction)!=null?e:"table"}set consoleDirection(e){this.$store.dispatch("gui/console/saveSetting",{name:"direction",value:e})}get availableEntryStyles(){return[{text:this.$t("Settings.ConsoleTab.EntryStyleDefault"),value:"default"},{text:this.$t("Settings.ConsoleTab.EntryStyleCompact"),value:"compact"}]}get entryStyle(){var e;return(e=this.$store.state.gui.console.entryStyle)!=null?e:"default"}set entryStyle(e){this.$store.dispatch("gui/console/saveSetting",{name:"entryStyle",value:e})}get consoleHeight(){var e;return(e=this.$store.state.gui.console.height)!=null?e:300}set consoleHeight(e){this.$store.dispatch("gui/console/saveSetting",{name:"height",value:e})}consoleHeightChanged(e){this.consoleHeightTmp=e}updateConsoleHeight(e){this.consoleHeight=e}get hideWaitTemperatures(){return this.$store.state.gui.console.hideWaitTemperatures}set hideWaitTemperatures(e){this.$store.dispatch("gui/console/saveSetting",{name:"hideWaitTemperatures",value:e})}get hideTimelapse(){return this.$store.state.gui.console.hideTlCommands}set hideTimelapse(e){this.$store.dispatch("gui/console/saveSetting",{name:"hideTlCommands",value:e})}existsPresetName(e){return this.consoleFilters.findIndex(t=>t.name===e&&t.id!==this.form.id)>=0}clearForm(){this.form.bool=!1,this.form.id=null,this.form.name="",this.form.regex=""}toggleFilter(e){const t={name:e.name,bool:!e.bool,regex:e.regex};this.$store.dispatch("gui/console/filterUpdate",{id:e.id,values:t})}createFilter(){this.clearForm(),this.form.bool=!0}editFilter(e){this.form.name=e.name,this.form.id=e.id,this.form.regex=e.regex,this.form.bool=!0}saveFilter(){if(this.form.valid){const e={name:this.form.name,bool:this.form.bool,regex:this.form.regex};this.form.id?this.$store.dispatch("gui/console/filterUpdate",{id:this.form.id,values:e}):this.$store.dispatch("gui/console/filterStore",{values:e}),this.clearForm()}}deleteFilter(e){this.$store.dispatch("gui/console/filterDelete",e)}};gf([he("consoleHeight")],la.prototype,"consoleHeightChanged",1);gf([Ke(500)],la.prototype,"updateConsoleHeight",1);la=gf([S({components:{SettingsRow:j}})],la);var _4=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e.form.bool?t(Pe,{attrs:{flat:""}},[t(or,{on:{submit:function(r){return r.preventDefault(),e.saveFilter.apply(null,arguments)}},model:{value:e.form.valid,callback:function(r){e.$set(e.form,"valid",r)},expression:"form.valid"}},[t(gt,[e._v(" "+e._s(e.form.id===null?e.$t("Settings.ConsoleTab.CreateHeadline"):e.$t("Settings.ConsoleTab.EditHeadline"))+" ")]),t(Z,[t(j,{attrs:{title:e.$t("Settings.ConsoleTab.Name").toString()}},[t(se,{attrs:{"hide-details":"auto",rules:[e.rules.required,e.rules.unique],dense:"",outlined:""},model:{value:e.form.name,callback:function(r){e.$set(e.form,"name",r)},expression:"form.name"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.ConsoleTab.Regex").toString()}},[t(pr,{attrs:{outlined:"","hide-details":"auto"},model:{value:e.form.regex,callback:function(r){e.$set(e.form,"regex",r)},expression:"form.regex"}})],1)],1),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:""},on:{click:function(r){e.form.bool=!1}}},[e._v(" "+e._s(e.$t("Settings.Cancel"))+" ")]),t(g,{attrs:{color:"primary",text:"",type:"submit"}},[e._v(" "+e._s(e.form.id===null?e.$t("Settings.ConsoleTab.StoreButton"):e.$t("Settings.ConsoleTab.UpdateButton"))+" ")])],1)],1)],1):t(Pe,{attrs:{flat:""}},[t(Z,[t("div",{staticClass:"d-flex align-center"},[t(_,{staticStyle:{opacity:"0.7"}},[e._v(e._s(e.mdiConsoleLine))]),t(gt,{staticClass:"mx-n2"},[e._v(" "+e._s(e.$t("Settings.ConsoleTab.Console"))+" ")]),t(I,{staticClass:"ml-3"})],1),t(j,{attrs:{title:e.$t("Settings.ConsoleTab.Direction").toString()}},[t(ke,{attrs:{items:e.availableDirections,"hide-details":"",outlined:"",dense:"",attach:""},model:{value:e.consoleDirection,callback:function(r){e.consoleDirection=r},expression:"consoleDirection"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.ConsoleTab.EntryStyle").toString()}},[t(ke,{attrs:{items:e.availableEntryStyles,"hide-details":"",outlined:"",dense:"",attach:""},model:{value:e.entryStyle,callback:function(r){e.entryStyle=r},expression:"entryStyle"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.ConsoleTab.Height").toString()}},[t(Lr,{attrs:{"hide-details":"",min:200,max:900,step:10,label:e.consoleHeightTmp+"px"},on:{change:e.updateConsoleHeight},model:{value:e.consoleHeightTmp,callback:function(r){e.consoleHeightTmp=r},expression:"consoleHeightTmp"}})],1),t("div",{staticClass:"d-flex align-center"},[t(_,{staticStyle:{opacity:"0.7"}},[e._v(e._s(e.mdiFilter))]),t(gt,{staticClass:"mx-n2"},[e._v(" "+e._s(e.$t("Settings.ConsoleTab.Filters"))+" ")]),t(I,{staticClass:"ml-3"})],1),t(j,{attrs:{title:e.$t("Settings.ConsoleTab.HideTemperatures").toString(),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.hideWaitTemperatures,callback:function(r){e.hideWaitTemperatures=r},expression:"hideWaitTemperatures"}})],1),e.moonrakerComponents.includes("timelapse")?[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.ConsoleTab.HideTimelapse").toString(),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.hideTimelapse,callback:function(r){e.hideTimelapse=r},expression:"hideTimelapse"}})],1)]:e._e(),t(I,{staticClass:"my-2"}),e._l(e.consoleFilters,function(r,i){return t("div",{key:i},[i?t(I,{staticClass:"my-2"}):e._e(),t(j,{attrs:{title:r.name}},[t(g,{staticClass:"minwidth-0 px-2",attrs:{small:"",outlined:"",color:r.bool?"white":"grey"},on:{click:function(n){return e.toggleFilter(r)}}},[t(_,{attrs:{small:""}},[e._v(e._s(r.bool?e.mdiFilter:e.mdiFilterOff))])],1),t(g,{staticClass:"ml-3",attrs:{small:"",outlined:""},on:{click:function(n){return e.editFilter(r)}}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiPencil))]),e._v(" "+e._s(e.$t("Settings.Edit"))+" ")],1),t(g,{staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:"error"},on:{click:function(n){return e.deleteFilter(r.id)}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiDelete))])],1)],1)],1)})],2),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:"",color:"primary"},on:{click:e.createFilter}},[e._v(e._s(e.$t("Settings.ConsoleTab.AddFilter")))])],1)],1)],1)},v4=[],b4=E(la,_4,v4,!1,null,"57ed801f");const y4=b4.exports;var C4=Object.getOwnPropertyDescriptor,$4=(s,e,t,r)=>{for(var i=r>1?void 0:r?C4(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Bm=class extends k(L){constructor(){super(...arguments),this.mdiPencil=bt}editCooldown(){this.$emit("edit")}};Bm=$4([S({components:{SettingsRow:j}})],Bm);var x4=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(j,{attrs:{title:e.$t("Settings.PresetsTab.Cooldown")}},[t(g,{staticClass:"ml-3",attrs:{small:"",outlined:""},on:{click:e.editCooldown}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiPencil))]),e._v(" "+e._s(e.$t("Settings.Edit"))+" ")],1)],1)},w4=[],S4=E(Bm,x4,w4,!1,null,null);const Rb=S4.exports;var P4=Object.defineProperty,D4=Object.getOwnPropertyDescriptor,Hb=(s,e,t,r)=>{for(var i=r>1?void 0:r?D4(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&P4(e,t,i),i};let jl=class extends k(L){constructor(){super(...arguments),this.mdiPencil=bt,this.mdiDelete=Ue}get subTitle(){let s=[];return Object.keys(this.preset.values).forEach(e=>{const t=this.preset.values[e];if(t.bool){const r=e.indexOf(" ")?e.slice(e.indexOf(" ")+1):e;s.push(Ye(r)+": "+t.value+"°C")}}),this.preset.gcode&&s.push(this.$t("Settings.PresetsTab.CustomGCode").toString()),s.join(", ")}editPreset(){this.$emit("edit",this.preset)}deletePreset(){this.$store.dispatch("gui/presets/delete",this.preset.id)}};Hb([w({required:!0})],jl.prototype,"preset",2);jl=Hb([S({components:{SettingsRow:j}})],jl);var T4=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(j,{attrs:{title:e.preset.name,"sub-title":e.subTitle}},[t(g,{staticClass:"ml-3",attrs:{small:"",outlined:""},on:{click:e.editPreset}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiPencil))]),e._v(" "+e._s(e.$t("Settings.Edit"))+" ")],1),t(g,{staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:"error"},on:{click:e.deletePreset}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiDelete))])],1)],1)},O4=[],M4=E(jl,T4,O4,!1,null,null);const jb=M4.exports;var k4=Object.defineProperty,E4=Object.getOwnPropertyDescriptor,Ib=(s,e,t,r)=>{for(var i=r>1?void 0:r?E4(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&k4(e,t,i),i};let Il=class extends k(L){constructor(){super(...arguments),this.mdiPencil=bt,this.mdiDelete=Ue,this.gcode=""}mounted(){this.gcode=this.inputGcode}closeForm(){this.$emit("close")}saveCooldown(){this.$store.dispatch("gui/presets/saveSetting",{name:"cooldownGcode",value:this.gcode}),this.closeForm()}};Ib([w({required:!0})],Il.prototype,"inputGcode",2);Il=Ib([S({components:{SettingsRow:j}})],Il);var L4=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{attrs:{flat:""}},[t(or,{on:{submit:function(r){return r.preventDefault(),e.saveCooldown.apply(null,arguments)}}},[t(gt,[e._v(e._s(e.$t("Settings.PresetsTab.EditCooldown")))]),t(Z,[t(j,{attrs:{title:e.$t("Settings.PresetsTab.CustomGCode")}},[t(pr,{attrs:{outlined:"","hide-details":""},model:{value:e.gcode,callback:function(r){e.gcode=r},expression:"gcode"}})],1)],1),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:""},on:{click:e.closeForm}},[e._v(" "+e._s(e.$t("Settings.Cancel"))+" ")]),t(g,{attrs:{color:"primary",text:"",type:"submit"}},[e._v(" "+e._s(e.$t("Settings.PresetsTab.UpdateCooldown"))+" ")])],1)],1)],1)},A4=[],F4=E(Il,L4,A4,!1,null,null);const R4=F4.exports;var H4=Object.defineProperty,j4=Object.getOwnPropertyDescriptor,Nb=(s,e,t,r)=>{for(var i=r>1?void 0:r?j4(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&H4(e,t,i),i};let Nl=class extends k(L){constructor(){super(...arguments),this.mdiPencil=bt,this.mdiDelete=Ue,this.valid=!1,this.boolInvalidMin=!1,this.rules={required:s=>s!==""||this.$t("Settings.PresetsTab.ErrorNameRequired"),unique:s=>!this.existsPresetName(s)||this.$t("Settings.PresetsTab.ErrorNameNotUnique"),invalid:s=>parseFloat(s)>=0||this.$t("Settings.PresetsTab.ErrorInvalidValue")}}get title(){return this.preset.id===null?this.$t("Settings.PresetsTab.CreateHeadline"):this.$t("Settings.PresetsTab.EditHeadline")}get storeButtonText(){return this.preset.id===null?this.$t("Settings.PresetsTab.StoreButton"):this.$t("Settings.PresetsTab.UpdateButton")}get presets(){var s;return(s=this.$store.getters["gui/presets/getPresets"])!=null?s:[]}get available_heaters(){var s,e,t;return((t=(e=(s=this.$store.state.printer)==null?void 0:s.heaters)==null?void 0:e.available_heaters)!=null?t:[]).sort()}get available_temperature_fans(){var s,e,t;return((t=(e=(s=this.$store.state.printer)==null?void 0:s.heaters)==null?void 0:e.available_sensors)!=null?t:[]).filter(r=>r.startsWith("temperature_fan ")).sort()}mounted(){const s=Object.keys(this.preset.values);this.available_heaters.filter(e=>!s.includes(e)).forEach(e=>{this.preset.values[e]={bool:!1,type:"heater",value:0}}),this.available_temperature_fans.filter(e=>!s.includes(e)).forEach(e=>{this.preset.values[e]={bool:!1,type:"temperature_fan",value:0}}),s.filter(e=>!this.available_heaters.includes(e)&&!this.available_temperature_fans.includes(e)).forEach(e=>{delete this.preset.values[e]})}existsPresetName(s){return this.presets.findIndex(e=>e.name===s&&e.id!==this.preset.id)!==-1}converNameObject(s){return Ye(s.replace("temperature_fan ",""))}closeForm(){this.$emit("close")}savePreset(){let s=0;for(const e of Object.keys(this.preset.values))this.preset.values[e].bool&&s++;if(this.preset.gcode.length&&s++,s===0){this.boolInvalidMin=!0;return}if(this.preset.id===null){this.$store.dispatch("gui/presets/store",{values:this.preset}),this.closeForm();return}this.$store.dispatch("gui/presets/update",{id:this.preset.id,values:this.preset}),this.closeForm()}};Nb([w({required:!0})],Nl.prototype,"preset",2);Nl=Nb([S({components:{SettingsRow:j}})],Nl);var I4=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{attrs:{flat:""}},[t(or,{on:{submit:function(r){return r.preventDefault(),e.savePreset.apply(null,arguments)}},model:{value:e.valid,callback:function(r){e.valid=r},expression:"valid"}},[t(gt,[e._v(e._s(e.title))]),t(Z,[e.boolInvalidMin?t(x,{staticClass:"mt-3"},[t(b,{staticClass:"py-0"},[t(it,{attrs:{dense:"",text:"",type:"error"}},[e._v(e._s(e.$t("Settings.PresetsTab.PresetInfo")))])],1)],1):e._e(),t(j,{attrs:{title:e.$t("Settings.PresetsTab.Name")}},[t(se,{attrs:{placeholder:e.$t("Settings.PresetsTab.PresetNamePlaceholder"),"hide-details":"auto",rules:[e.rules.required,e.rules.unique],dense:"",outlined:""},model:{value:e.preset.name,callback:function(r){e.$set(e.preset,"name",r)},expression:"preset.name"}})],1),e._l(e.preset.values,function(r,i){return t("div",{key:i},[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.converNameObject(i)}},[t(ge,{staticClass:"shrink mt-0",attrs:{"hide-details":""},model:{value:r.bool,callback:function(n){e.$set(r,"bool",n)},expression:"value.bool"}}),t(se,{attrs:{"hide-details":"auto",rules:[e.rules.invalid],type:"number",suffix:"°C",dense:"",outlined:"","hide-spin-buttons":""},on:{focus:function(n){return n.target.select()}},model:{value:r.value,callback:function(n){e.$set(r,"value",n)},expression:"value.value"}})],1)],1)}),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.PresetsTab.CustomGCode")}},[t(pr,{attrs:{outlined:"","hide-details":""},model:{value:e.preset.gcode,callback:function(r){e.$set(e.preset,"gcode",r)},expression:"preset.gcode"}})],1)],2),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:""},on:{click:e.closeForm}},[e._v(" "+e._s(e.$t("Settings.Cancel"))+" ")]),t(g,{attrs:{color:"primary",text:"",type:"submit",disabled:!e.valid}},[e._v(" "+e._s(e.storeButtonText)+" ")])],1)],1)],1)},N4=[],V4=E(Nl,I4,N4,!1,null,null);const Vb=V4.exports;var B4=Object.getOwnPropertyDescriptor,U4=(s,e,t,r)=>{for(var i=r>1?void 0:r?B4(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Um=class extends k(L){constructor(){super(...arguments),this.mdiPencil=bt,this.mdiDelete=Ue,this.boolForm=!1,this.boolFormCooldown=!1,this.formPreset={}}get presets(){var e;return(e=this.$store.getters["gui/presets/getPresets"])!=null?e:[]}get cooldownGcode(){return this.$store.getters["gui/presets/getCooldownGcode"]}createPreset(){this.formPreset.id=null,this.formPreset.name="",this.formPreset.values={},this.formPreset.gcode="",this.boolForm=!0}edit(e){this.formPreset={...e},this.boolForm=!0}};Um=U4([S({components:{PresetsForm:Vb,PresetsEntryCooldown:Rb,PresetsEntry:jb,SettingsRow:j}})],Um);var W4=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e.boolForm?t(Vb,{attrs:{preset:e.formPreset},on:{close:function(r){e.boolForm=!1}}}):e.boolFormCooldown?t(R4,{attrs:{"input-gcode":e.cooldownGcode},on:{close:function(r){e.boolFormCooldown=!1}}}):t(Pe,{attrs:{flat:""}},[t(Z,[t("h3",{staticClass:"text-h5 mb-3"},[e._v(e._s(e.$t("Settings.PresetsTab.PreheatPresets")))]),e._l(e.presets,function(r,i){return t("div",{key:r.index},[i?t(I,{staticClass:"my-2"}):e._e(),t(jb,{attrs:{preset:r},on:{edit:e.edit}})],1)}),e.presets.length?t(I,{staticClass:"my-2"}):e._e(),t(Rb,{on:{edit:function(r){e.boolFormCooldown=!0}}})],2),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:"",color:"primary"},on:{click:e.createPreset}},[e._v(e._s(e.$t("Settings.PresetsTab.AddPreset")))])],1)],1)],1)},z4=[],G4=E(Um,W4,z4,!1,null,null);const Z4=G4.exports;var q4=Object.getOwnPropertyDescriptor,X4=(s,e,t,r)=>{for(var i=r>1?void 0:r?q4(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Wm=class extends k(L){constructor(){super(...arguments),this.mdiCheckboxMarkedCircle=X_,this.mdiCancel=Z_,this.mdiPencil=bt,this.mdiDelete=Ue,this.mdiAlertOutline=Jn,this.form={bool:!1,hostname:"",port:7125,path:"/",name:"",id:null,namespace:null}}get printers(){var e;return(e=this.$store.getters["gui/remoteprinters/getRemoteprinters"])!=null?e:[]}get canAddPrinters(){return this.$store.state.instancesDB!=="json"}get protocol(){var e;return(e=this.$store.state.socket.protocol)!=null?e:"ws"}formatPrinterName(e){var t;return e.hostname+(e.port!==80?":"+e.port:"")+((t=e.path)!=null?t:"")}createPrinter(){this.form.hostname="",this.form.port=7125,this.form.path="/",this.form.name="",this.form.id=null,this.form.namespace=null,this.form.bool=!0}storePrinter(){const e={hostname:this.form.hostname,port:this.form.port,name:this.form.name,path:this.form.path};this.$store.dispatch("gui/remoteprinters/store",{values:e}),this.form.hostname="",this.form.port=7125,this.form.name="",this.form.id=null,this.form.bool=!1}editPrinter(e){var t,r,i;this.form.id=(t=e.id)!=null?t:null,this.form.hostname=e.hostname,this.form.port=e.port,this.form.path=(r=e.path)!=null?r:"/",this.form.name=(i=e.name)!=null?i:"",this.form.bool=!0}updatePrinter(){const e={hostname:this.form.hostname,port:this.form.port,name:this.form.name,path:this.form.path};this.$store.dispatch("gui/remoteprinters/update",{id:this.form.id,values:e}),this.form.id=null,this.form.hostname="",this.form.port=7125,this.form.path="/",this.form.name="",this.form.bool=!1}delPrinter(e){this.$store.dispatch("gui/remoteprinters/delete",e)}};Wm=X4([S({components:{SettingsRow:j}})],Wm);var Y4=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e.form.bool?t(Pe,{attrs:{flat:""}},[t(gt,[e._v(" "+e._s(e.form.id!==null?e.$t("Settings.RemotePrintersTab.EditPrinter"):e.$t("Settings.RemotePrintersTab.AddPrinter"))+" ")]),t(Z,[t(j,{attrs:{title:e.$t("Settings.RemotePrintersTab.Hostname")}},[t(se,{attrs:{rules:[r=>!!r||"Hostname is required",r=>!r.startsWith("http:")||"invalid hostname/IP",r=>!r.startsWith("https:")||"invalid hostname/IP"],"hide-details":"auto",required:"",dense:"",outlined:""},model:{value:e.form.hostname,callback:function(r){e.$set(e.form,"hostname",r)},expression:"form.hostname"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.RemotePrintersTab.Port")}},[t(se,{attrs:{rules:[r=>!!r||"Port is required"],"hide-details":"auto",required:"",dense:"",outlined:""},model:{value:e.form.port,callback:function(r){e.$set(e.form,"port",r)},expression:"form.port"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.RemotePrintersTab.Path")}},[t(se,{attrs:{rules:[r=>!r||r.startsWith("/")||"Path must start with /"],"hide-details":"auto",outlined:"",dense:""},model:{value:e.form.path,callback:function(r){e.$set(e.form,"path",r)},expression:"form.path"}})],1),e.instancesDB!=="moonraker"?[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.RemotePrintersTab.Name"),"sub-title":e.$t("Settings.RemotePrintersTab.NameDescription")}},[t(se,{attrs:{outlined:"","hide-details":"auto",dense:""},model:{value:e.form.name,callback:function(r){e.$set(e.form,"name",r)},expression:"form.name"}})],1)]:e._e()],2),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:""},on:{click:function(r){e.form.bool=!1}}},[e._v(e._s(e.$t("Settings.Cancel")))]),e.form.id===null?t(g,{attrs:{text:"",color:"primary"},on:{click:e.storePrinter}},[e._v(" "+e._s(e.$t("Settings.RemotePrintersTab.AddPrinter"))+" ")]):t(g,{attrs:{text:"",color:"primary"},on:{click:e.updatePrinter}},[e._v(" "+e._s(e.$t("Settings.RemotePrintersTab.UpdatePrinter"))+" ")])],1)],1):t(Pe,{attrs:{flat:""}},[t(Z,[t("h3",{staticClass:"text-h5 mb-3"},[e._v(e._s(e.$t("Settings.RemotePrintersTab.RemotePrinters")))]),e.canAddPrinters?e._e():t(it,{attrs:{icon:e.mdiAlertOutline,type:"warning",text:""}},[e._v(" "+e._s(e.$t("Settings.RemotePrintersTab.UseConfigJson"))+" ")]),e._l(e.printers,function(r,i){return t("div",{key:r.id},[i?t(I,{staticClass:"my-2"}):e._e(),t(j,{attrs:{title:e.formatPrinterName(r),loading:r.socket.isConnecting,icon:r.socket.isConnected?e.mdiCheckboxMarkedCircle:e.mdiCancel}},[t(g,{attrs:{small:"",outlined:"",disabled:!e.canAddPrinters},on:{click:function(n){return e.editPrinter(r)}}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiPencil))]),e._v(" "+e._s(e.$t("Settings.Edit"))+" ")],1),t(g,{staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:"error",disabled:!e.canAddPrinters},on:{click:function(n){return e.delPrinter(r.id)}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiDelete))])],1)],1)],1)})],2),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:"",color:"primary",disabled:!e.canAddPrinters},on:{click:e.createPrinter}},[e._v(" "+e._s(e.$t("Settings.RemotePrintersTab.AddPrinter"))+" ")])],1)],1)],1)},J4=[],K4=E(Wm,Y4,J4,!1,null,null);const Q4=K4.exports;var eM=Object.defineProperty,tM=Object.getOwnPropertyDescriptor,to=(s,e,t,r)=>{for(var i=r>1?void 0:r?tM(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&eM(e,t,i),i};let Ur=class extends k(L,vt){constructor(){super(...arguments),this.mdiRestart=_r,this.mdiTimerOutline=TS,this.defaultBigThumbnailBackground=At}get mode(){return this.$store.state.gui.uiSettings.mode}set mode(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.mode",value:e})}get themeName(){return this.$store.getters["gui/theme"]}set themeName(e){var r,i;const t=Ci.find(n=>n.name===e);this.logoColor===this.defaultLogoColor&&(this.logoColor=(r=t==null?void 0:t.colorLogo)!=null?r:Ir),this.primaryColor===this.defaultPrimaryColor&&(this.primaryColor=(i=t==null?void 0:t.colorPrimary)!=null?i:al),this.$store.dispatch("gui/saveSetting",{name:"uiSettings.theme",value:e})}get modes(){return[{text:this.$t("Settings.UiSettingsTab.ThemeDark"),value:"dark"},{text:this.$t("Settings.UiSettingsTab.ThemeLight"),value:"light"}]}get themes(){return Ci.map(e=>({text:e.displayName,value:e.name}))}get logoColor(){return this.$store.state.gui.uiSettings.logo}set logoColor(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.logo",value:e})}get defaultLogoColor(){var e,t;return(t=(e=this.theme)==null?void 0:e.colorLogo)!=null?t:Ir}get defaultPrimaryColor(){var e,t;return(t=(e=this.theme)==null?void 0:e.colorPrimary)!=null?t:al}get primaryColor(){return this.$store.state.gui.uiSettings.primary}set primaryColor(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.primary",value:e})}get boolBigThumbnail(){return this.$store.state.gui.uiSettings.boolBigThumbnail}set boolBigThumbnail(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.boolBigThumbnail",value:e})}get bigThumbnailBackground(){return this.$store.state.gui.uiSettings.bigThumbnailBackground}set bigThumbnailBackground(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.bigThumbnailBackground",value:e})}get displayCancelPrint(){return this.$store.state.gui.uiSettings.displayCancelPrint}set displayCancelPrint(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.displayCancelPrint",value:e})}get progressAsFavicon(){return this.$store.state.gui.uiSettings.progressAsFavicon}set progressAsFavicon(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.progressAsFavicon",value:e})}get confirmOnEmergencyStop(){return this.$store.state.gui.uiSettings.confirmOnEmergencyStop}set confirmOnEmergencyStop(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.confirmOnEmergencyStop",value:e})}get confirmOnCoolDown(){return this.$store.state.gui.uiSettings.confirmOnCoolDown}set confirmOnCoolDown(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.confirmOnCoolDown",value:e})}get confirmOnPowerDeviceChange(){return this.$store.state.gui.uiSettings.confirmOnPowerDeviceChange}set confirmOnPowerDeviceChange(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.confirmOnPowerDeviceChange",value:e})}get confirmOnCancelJob(){return this.$store.state.gui.uiSettings.confirmOnCancelJob}set confirmOnCancelJob(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.confirmOnCancelJob",value:e})}get lockSliders(){return this.$store.state.gui.uiSettings.lockSlidersOnTouchDevices}set lockSliders(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.lockSlidersOnTouchDevices",value:e})}get lockSlidersDelay(){return this.$store.state.gui.uiSettings.lockSlidersDelay}set lockSlidersDelay(e){e>=0&&this.$store.dispatch("gui/saveSetting",{name:"uiSettings.lockSlidersDelay",value:e})}get boolWideNavDrawer(){var e;return(e=this.$store.state.gui.uiSettings.boolWideNavDrawer)!=null?e:!1}get navigationStyleSetting(){return this.$store.state.gui.uiSettings.navigationStyle}set navigationStyleSetting(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.navigationStyle",value:e})}get navigationStyles(){return[{text:this.$t("Settings.UiSettingsTab.NavigationStyleIconsOnly"),value:"iconsOnly"},{text:this.$t("Settings.UiSettingsTab.NavigationStyleIconsAndText"),value:"iconsAndText"}]}get defaultNavigationStateSetting(){return this.$store.state.gui.uiSettings.defaultNavigationStateSetting}set defaultNavigationStateSetting(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.defaultNavigationStateSetting",value:e})}get defaultNavigationStateSettings(){return[{text:this.$t("Settings.UiSettingsTab.DefaultNavigationStateAlwaysOpen"),value:"alwaysOpen"},{text:this.$t("Settings.UiSettingsTab.DefaultNavigationStateAlwaysClosed"),value:"alwaysClosed"},{text:this.$t("Settings.UiSettingsTab.DefaultNavigationStateLastState"),value:"lastState"}]}get boolHideUploadAndPrintButton(){var e;return(e=this.$store.state.gui.uiSettings.boolHideUploadAndPrintButton)!=null?e:!1}set boolHideUploadAndPrintButton(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.boolHideUploadAndPrintButton",value:e})}get powerDevices(){var e;return(e=this.$store.getters["server/power/getDevices"])!=null?e:[]}get autoPowerDevice(){var e,t;return(t=(e=this.powerDevices.find(r=>r.device.toLowerCase()==="printer"))==null?void 0:e.device)!=null?t:"--"}get powerDeviceName(){var e;return(e=this.$store.state.gui.uiSettings.powerDeviceName)!=null?e:null}set powerDeviceName(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.powerDeviceName",value:e})}get powerDeviceOptions(){const e=[{text:"Auto (".concat(this.autoPowerDevice,")"),value:null}];return this.powerDevices.forEach(t=>{e.push({text:"".concat(t.device," (").concat(t.type,")"),value:t.device.toString()})}),e}get hideSaveConfigForBedMash(){var e;return(e=this.$store.state.gui.uiSettings.hideSaveConfigForBedMash)!=null?e:!1}set hideSaveConfigForBedMash(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.hideSaveConfigForBedMash",value:e})}get disableFanAnimation(){var e;return(e=this.$store.state.gui.uiSettings.disableFanAnimation)!=null?e:!1}set disableFanAnimation(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.disableFanAnimation",value:e})}get boolManualProbeDialog(){var e;return(e=this.$store.state.gui.uiSettings.boolManualProbeDialog)!=null?e:!0}set boolManualProbeDialog(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.boolManualProbeDialog",value:e})}get boolBedScrewsDialog(){var e;return(e=this.$store.state.gui.uiSettings.boolBedScrewsDialog)!=null?e:!0}set boolBedScrewsDialog(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.boolBedScrewsDialog",value:e})}get boolScrewsTiltAdjustDialog(){var e;return(e=this.$store.state.gui.uiSettings.boolScrewsTiltAdjustDialog)!=null?e:!0}set boolScrewsTiltAdjustDialog(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.boolScrewsTiltAdjustDialog",value:e})}get printstatusThumbnailZoom(){var e;return(e=this.$store.state.gui.uiSettings.printstatusThumbnailZoom)!=null?e:!0}set printstatusThumbnailZoom(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.printstatusThumbnailZoom",value:e})}get tempchartHeight(){var e;return(e=this.$store.state.gui.uiSettings.tempchartHeight)!=null?e:250}set tempchartHeight(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.tempchartHeight",value:e})}get hideUpdateWarnings(){var e;return(e=this.$store.state.gui.uiSettings.hideUpdateWarnings)!=null?e:!1}set hideUpdateWarnings(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.hideUpdateWarnings",value:e})}get dashboardFilesLimit(){var e;return(e=this.$store.state.gui.uiSettings.dashboardFilesLimit)!=null?e:5}set dashboardFilesLimit(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.dashboardFilesLimit",value:e})}get dashboardFilesFilter(){var e;return(e=this.$store.state.gui.uiSettings.dashboardFilesFilter)!=null?e:[]}set dashboardFilesFilter(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.dashboardFilesFilter",value:e})}get dashboardFilesFilters(){return[{text:this.$t("Settings.UiSettingsTab.DashboardFilesFilterNew"),value:"new"},{text:this.$t("Settings.UiSettingsTab.DashboardFilesFilterFailed"),value:"failed"},{text:this.$t("Settings.UiSettingsTab.DashboardFilesFilterCompleted"),value:"completed"}]}get dashboardHistoryLimit(){var e;return(e=this.$store.state.gui.uiSettings.dashboardHistoryLimit)!=null?e:5}set dashboardHistoryLimit(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.dashboardHistoryLimit",value:e})}get hideOtherInstances(){var e;return(e=this.$store.state.gui.uiSettings.hideOtherInstances)!=null?e:!1}set hideOtherInstances(e){this.$store.dispatch("gui/saveSetting",{name:"uiSettings.hideOtherInstances",value:e})}clearColorObject(e){return typeof e=="object"&&"hex"in e&&(e=e.hex),e.length>7&&(e=e.substr(0,7)),e}updateLogoColor(e){this.logoColor=this.clearColorObject(e)}updatePrimaryColor(e){this.primaryColor=this.clearColorObject(e)}updateBigThumbnailBackground(e){this.bigThumbnailBackground=this.clearColorObject(e)}onThemeChanged(e){const t=Ci.find(r=>r.name===e);t&&t.colorLogo&&(this.logoColor=t.colorLogo)}};to([Ke(500)],Ur.prototype,"updateLogoColor",1);to([Ke(500)],Ur.prototype,"updatePrimaryColor",1);to([Ke(500)],Ur.prototype,"updateBigThumbnailBackground",1);to([he("theme")],Ur.prototype,"onThemeChanged",1);Ur=to([S({components:{SettingsRow:j}})],Ur);var sM=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(Pe,{attrs:{flat:""}},[t(Z,[t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.Mode"),"sub-title":e.$t("Settings.UiSettingsTab.ModeDescription")}},[t(ke,{staticClass:"mt-0",attrs:{items:e.modes,"hide-details":"",outlined:"",dense:""},model:{value:e.mode,callback:function(r){e.mode=r},expression:"mode"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.Theme"),"sub-title":e.$t("Settings.UiSettingsTab.ThemeDescription")}},[t(ke,{staticClass:"mt-0",attrs:{items:e.themes,"hide-details":"",outlined:"",dense:""},model:{value:e.themeName,callback:function(r){e.themeName=r},expression:"themeName"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.Logo")}},[e.logoColor.toLowerCase()!==e.defaultLogoColor.toLowerCase()?t(g,{staticClass:"minwidth-0",attrs:{small:"",text:""},on:{click:function(r){e.logoColor=e.defaultLogoColor}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiRestart))])],1):e._e(),t(ye,{attrs:{bottom:"",left:"","offset-y":"","close-on-content-click":!1},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"minwidth-0 px-5",attrs:{color:e.logoColor,small:""}},"v-btn",i,!1),r))]}}])},[t(Xt,{attrs:{value:e.logoColor,"hide-mode-switch":"",mode:"rgba"},on:{"update:color":e.updateLogoColor}})],1)],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.Primary")}},[e.primaryColor.toLowerCase()!==e.defaultPrimaryColor.toLowerCase()?t(g,{staticClass:"minwidth-0",attrs:{small:"",text:""},on:{click:function(r){e.primaryColor=e.defaultPrimaryColor}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiRestart))])],1):e._e(),t(ye,{attrs:{bottom:"",left:"","offset-y":"","close-on-content-click":!1},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"minwidth-0 px-5",attrs:{color:e.primaryColor,small:""}},"v-btn",i,!1),r))]}}])},[t(Xt,{attrs:{value:e.primaryColor,"hide-mode-switch":"",mode:"rgba"},on:{"update:color":e.updatePrimaryColor}})],1)],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.GcodeThumbnails"),"sub-title":e.$t("Settings.UiSettingsTab.GcodeThumbnailsDescription"),"dynamic-slot-width":!0}},[t(g,{attrs:{outlined:"",small:"",color:"primary",href:"https://docs.mainsail.xyz/overview/features/thumbnails",target:"_blank"}},[e._v(" "+e._s(e.$t("Settings.UiSettingsTab.Guide"))+" ")])],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.BoolBigThumbnail"),"sub-title":e.$t("Settings.UiSettingsTab.BoolBigThumbnailDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.boolBigThumbnail,callback:function(r){e.boolBigThumbnail=r},expression:"boolBigThumbnail"}})],1),e.boolBigThumbnail?[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.PrintstatusThumbnailZoom"),"sub-title":e.$t("Settings.UiSettingsTab.PrintstatusThumbnailZoomDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.printstatusThumbnailZoom,callback:function(r){e.printstatusThumbnailZoom=r},expression:"printstatusThumbnailZoom"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.BigThumbnailBackground")}},[e.bigThumbnailBackground.toLowerCase()!==e.defaultBigThumbnailBackground.toLowerCase()?t(g,{staticClass:"minwidth-0",attrs:{small:"",text:""},on:{click:function(r){e.bigThumbnailBackground=e.defaultBigThumbnailBackground}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiRestart))])],1):e._e(),t(ye,{attrs:{bottom:"",left:"","offset-y":"","close-on-content-click":!1},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"minwidth-0 px-5",attrs:{color:e.bigThumbnailBackground,small:""}},"v-btn",i,!1),r))]}}],null,!1,2319691296)},[t(Xt,{attrs:{value:e.bigThumbnailBackground,"hide-mode-switch":"",mode:"rgba"},on:{"update:color":e.updateBigThumbnailBackground}})],1)],1)]:e._e(),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.DisplayCANCEL_PRINT"),"sub-title":e.$t("Settings.UiSettingsTab.DisplayCANCEL_PRINTDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.displayCancelPrint,callback:function(r){e.displayCancelPrint=r},expression:"displayCancelPrint"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.ProgressAsFavicon"),"sub-title":e.$t("Settings.UiSettingsTab.ProgressAsFaviconDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.progressAsFavicon,callback:function(r){e.progressAsFavicon=r},expression:"progressAsFavicon"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.LockSliders"),"sub-title":e.$t("Settings.UiSettingsTab.LockSlidersDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.lockSliders,callback:function(r){e.lockSliders=r},expression:"lockSliders"}})],1),t(I,{staticClass:"my-2"}),t(iu,[t(j,{directives:[{name:"show",rawName:"v-show",value:e.lockSliders,expression:"lockSliders"}],attrs:{title:e.$t("Settings.UiSettingsTab.LockSlidersDelay"),"sub-title":e.$t("Settings.UiSettingsTab.LockSlidersDelayDescription"),"dynamic-slot-width":!0}},[t(se,{staticClass:"mt-0",style:e.isMobile?{"max-width":"140px"}:{},attrs:{"prepend-icon":e.mdiTimerOutline,label:"Timeout",type:"number",rules:[r=>r>=0],min:"0",step:"0.5",suffix:"s","hide-details":"",outlined:"",dense:"","hide-spin-buttons":""},model:{value:e.lockSlidersDelay,callback:function(r){e.lockSlidersDelay=r},expression:"lockSlidersDelay"}})],1)],1),t(I,{directives:[{name:"show",rawName:"v-show",value:e.lockSliders,expression:"lockSliders"}],staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.ConfirmOnEmergencyStop"),"sub-title":e.$t("Settings.UiSettingsTab.ConfirmOnEmergencyStopDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.confirmOnEmergencyStop,callback:function(r){e.confirmOnEmergencyStop=r},expression:"confirmOnEmergencyStop"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.ConfirmOnCoolDown"),"sub-title":e.$t("Settings.UiSettingsTab.ConfirmOnCoolDownDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.confirmOnCoolDown,callback:function(r){e.confirmOnCoolDown=r},expression:"confirmOnCoolDown"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.ConfirmOnPowerDeviceChange"),"sub-title":e.$t("Settings.UiSettingsTab.ConfirmOnPowerDeviceChangeDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.confirmOnPowerDeviceChange,callback:function(r){e.confirmOnPowerDeviceChange=r},expression:"confirmOnPowerDeviceChange"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.ConfirmOnCancelJob"),"sub-title":e.$t("Settings.UiSettingsTab.ConfirmOnCancelJobDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.confirmOnCancelJob,callback:function(r){e.confirmOnCancelJob=r},expression:"confirmOnCancelJob"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.NavigationStyle"),"sub-title":e.$t("Settings.UiSettingsTab.NavigationStyleDescription")}},[t(ke,{staticClass:"mt-0",attrs:{items:e.navigationStyles,"hide-details":"",outlined:"",dense:""},model:{value:e.navigationStyleSetting,callback:function(r){e.navigationStyleSetting=r},expression:"navigationStyleSetting"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.DefaultNavigationState"),"sub-title":e.$t("Settings.UiSettingsTab.DefaultNavigationStateDescription")}},[t(ke,{staticClass:"mt-0",attrs:{items:e.defaultNavigationStateSettings,"hide-details":"",outlined:"",dense:""},model:{value:e.defaultNavigationStateSetting,callback:function(r){e.defaultNavigationStateSetting=r},expression:"defaultNavigationStateSetting"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.BoolHideUploadAndPrintButton"),"sub-title":e.$t("Settings.UiSettingsTab.BoolHideUploadAndPrintButtonDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.boolHideUploadAndPrintButton,callback:function(r){e.boolHideUploadAndPrintButton=r},expression:"boolHideUploadAndPrintButton"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.PowerDeviceName"),"sub-title":e.$t("Settings.UiSettingsTab.PowerDeviceNameDescription"),"dynamic-slot-width":!0}},[t(ke,{staticClass:"mt-0",attrs:{items:e.powerDeviceOptions,"hide-details":"",outlined:"",dense:""},model:{value:e.powerDeviceName,callback:function(r){e.powerDeviceName=r},expression:"powerDeviceName"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.HideSaveConfigButtonForBedMesh"),"sub-title":e.$t("Settings.UiSettingsTab.HideSaveConfigButtonForBedMeshDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.hideSaveConfigForBedMash,callback:function(r){e.hideSaveConfigForBedMash=r},expression:"hideSaveConfigForBedMash"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.DisableFanAnimation"),"sub-title":e.$t("Settings.UiSettingsTab.DisableFanAnimationDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.disableFanAnimation,callback:function(r){e.disableFanAnimation=r},expression:"disableFanAnimation"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.ManualProbeDialog"),"sub-title":e.$t("Settings.UiSettingsTab.ManualProbeDialogDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.boolManualProbeDialog,callback:function(r){e.boolManualProbeDialog=r},expression:"boolManualProbeDialog"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.BedScrewsDialog"),"sub-title":e.$t("Settings.UiSettingsTab.BedScrewsDialogDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.boolBedScrewsDialog,callback:function(r){e.boolBedScrewsDialog=r},expression:"boolBedScrewsDialog"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.ScrewsTiltAdjustDialog"),"sub-title":e.$t("Settings.UiSettingsTab.ScrewsTiltAdjustDialogDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.boolScrewsTiltAdjustDialog,callback:function(r){e.boolScrewsTiltAdjustDialog=r},expression:"boolScrewsTiltAdjustDialog"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.TempchartHeight"),"sub-title":e.$t("Settings.UiSettingsTab.TempchartHeightDescription")}},[t(Lr,{attrs:{"hide-details":"",min:100,max:500,step:1,label:e.tempchartHeight+"px"},model:{value:e.tempchartHeight,callback:function(r){e.tempchartHeight=r},expression:"tempchartHeight"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.HideUpdateWarnings"),"sub-title":e.$t("Settings.UiSettingsTab.HideUpdateWarningsDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.hideUpdateWarnings,callback:function(r){e.hideUpdateWarnings=r},expression:"hideUpdateWarnings"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.DashboardFilesLimit"),"sub-title":e.$t("Settings.UiSettingsTab.DashboardFilesLimitDescription")}},[t(Lr,{attrs:{"hide-details":"",min:0,max:10,step:1,label:e.$t("Settings.UiSettingsTab.DashboardFilesLimitLabel",{count:e.dashboardFilesLimit})},model:{value:e.dashboardFilesLimit,callback:function(r){e.dashboardFilesLimit=r},expression:"dashboardFilesLimit"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.DashboardFilesFilter"),"sub-title":e.$t("Settings.UiSettingsTab.DashboardFilesFilterDescription")}},[t(ke,{attrs:{items:e.dashboardFilesFilters,multiple:"","hide-details":"",dense:"",outlined:""},model:{value:e.dashboardFilesFilter,callback:function(r){e.dashboardFilesFilter=r},expression:"dashboardFilesFilter"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.DashboardHistoryLimit"),"sub-title":e.$t("Settings.UiSettingsTab.DashboardHistoryLimitDescription")}},[t(Lr,{attrs:{"hide-details":"",min:0,max:10,step:1,label:e.$t("Settings.UiSettingsTab.DashboardHistoryLimitLabel",{count:e.dashboardHistoryLimit})},model:{value:e.dashboardHistoryLimit,callback:function(r){e.dashboardHistoryLimit=r},expression:"dashboardHistoryLimit"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.UiSettingsTab.HideOtherInstances"),"sub-title":e.$t("Settings.UiSettingsTab.HideOtherInstancesDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.hideOtherInstances,callback:function(r){e.hideOtherInstances=r},expression:"hideOtherInstances"}})],1)],2)],1)],1)},rM=[],iM=E(Ur,sM,rM,!1,null,null);const nM=iM.exports;var aM=Object.getOwnPropertyDescriptor,oM=(s,e,t,r)=>{for(var i=r>1?void 0:r?aM(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Ns=class extends L{get macrogroups(){var s;return(s=this.$store.getters["gui/macros/getAllMacrogroups"])!=null?s:[]}get webcams(){var s;return(s=this.$store.getters["gui/webcams/getWebcams"])!=null?s:[]}getPanelName(s){var e;if(s.startsWith("macrogroup_")){const t=(e=s.split("_")[1])!=null?e:"",r=this.macrogroups.find(i=>i.id===t);return r?r.name:"Macrogroup"}if(s.includes("-")){let t="";return s.split("-").forEach(i=>{t+=lr(i)}),this.$t("Panels.".concat(t,"Panel.Headline"))}return this.$t("Panels.".concat(lr(s),"Panel.Headline"))}convertPanelnameToIcon(s){if(s.startsWith("macrogroup_"))return Qn;switch(s){case"webcam":return on;case"zoffset":return hw;case"toolhead-control":return Up;case"macros":return Qn;case"miscellaneous":return Hp;case"temperature":return Dv;case"miniconsole":return Ua;case"machine-settings":return ev;case"extruder-control":return Us;default:return Ht}}};Ns=oM([S],Ns);var lM=Object.defineProperty,cM=Object.getOwnPropertyDescriptor,_f=(s,e,t,r)=>{for(var i=r>1?void 0:r?cM(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&lM(e,t,i),i};let ca=class extends k(Ns){constructor(){super(...arguments),this.mdiInformation=Ht,this.mdiDragVertical=Wa}get panelname(){return this.getPanelName(this.name)}get icon(){return this.convertPanelnameToIcon(this.name)}get checkboxColor(){return this.visible?"primary":"grey lighten-1"}get checkboxIcon(){return this.visible?Lp:Ep}};_f([w({type:String,required:!0})],ca.prototype,"name",2);_f([w({type:Boolean,required:!0})],ca.prototype,"visible",2);ca=_f([S({components:{draggable:si}})],ca);var uM=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(J,[t(x,[t(b,{staticClass:"col-auto px-0"},[t(_,{staticClass:"handle pr-2"},[e._v(e._s(e.mdiDragVertical))]),t(_,[e._v(e._s(e.icon))])],1),t(b,{staticClass:"pr-0 text-truncate"},[e._v(" "+e._s(e.panelname)+" ")]),t(b,{staticClass:"col-auto pl-2"},[t(_,{attrs:{color:e.checkboxColor},domProps:{innerHTML:e._s(e.checkboxIcon)},on:{click:function(r){return r.stopPropagation(),e.$emit("change-visible",e.name,!e.visible)}}})],1)],1)],1)},dM=[],mM=E(ca,uM,dM,!1,null,"82546576");const hM=mM.exports;var pM=Object.defineProperty,fM=Object.getOwnPropertyDescriptor,vf=(s,e,t,r)=>{for(var i=r>1?void 0:r?fM(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&pM(e,t,i),i};let ua=class extends k(Ns){constructor(){super(...arguments),this.mdiInformation=Ht,this.mdiLock=eS}get layoutname(){return this.column?"".concat(this.viewportName,"Layout").concat(this.column):"".concat(this.viewportName,"Layout")}get groupname(){return"".concat(this.viewportName,"Viewport")}get layout(){return this.$store.getters["gui/getPanels"](this.viewportName,this.column)}set layout(e){e=e.filter(t=>t!==void 0),this.$store.dispatch("gui/saveSetting",{name:"dashboard.".concat(this.layoutname),value:e})}changeVisible(e,t){const r=this.layout.findIndex(i=>i.name===e);r!==-1&&(this.layout[r].visible=t,this.$store.dispatch("gui/saveSetting",{name:"dashboard.".concat(this.layoutname),value:this.layout}))}};vf([w({type:String,required:!0})],ua.prototype,"viewportName",2);vf([w({type:Number,required:!1,default:1})],ua.prototype,"column",2);ua=vf([S({components:{SettingsDashboardSortableItem:hM,draggable:si}})],ua);var gM=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{staticClass:"mx-auto fill-height",attrs:{"max-width":"300",tile:""}},[t(Me,{staticClass:"fill-height",attrs:{dense:""}},[e.column<2?t(J,[t(x,[t(b,{staticClass:"col-auto pr-0 pl-8"},[t(_,[e._v(e._s(e.mdiInformation))])],1),t(b,{staticClass:"pr-0 text-truncate"},[e._v(" "+e._s(e.$t("Panels.StatusPanel.Headline"))+" ")]),t(b,{staticClass:"col-auto pl-0"},[t(_,{attrs:{color:"grey lighten-1"}},[e._v(e._s(e.mdiLock))])],1)],1)],1):e._e(),t("draggable",{staticClass:"v-list-item-group fill-height",attrs:{handle:".handle","ghost-class":"ghost",group:e.groupname},model:{value:e.layout,callback:function(r){e.layout=r},expression:"layout"}},[t("transition-group",e._l(e.layout,function(r){return t("settings-dashboard-sortable-item",{key:"item-".concat(r.name),attrs:{name:r.name,visible:r.visible},on:{"change-visible":e.changeVisible}})}),1)],1)],1)],1)},_M=[],vM=E(ua,gM,_M,!1,null,"084031c4");const Su=vM.exports;var bM=Object.getOwnPropertyDescriptor,yM=(s,e,t,r)=>{for(var i=r>1?void 0:r?bM(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let zm=class extends k(Ns){resetLayout(){this.$store.dispatch("gui/resetLayout","mobileLayout")}};zm=yM([S({components:{SettingsDashboardSortable:Su}})],zm);var CM=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{attrs:{flat:""}},[t(Z,[t(x,[t(b,[t("settings-dashboard-sortable",{attrs:{"viewport-name":"mobile",column:0}})],1)],1),t(x,[t(b,{staticClass:"text-center"},[t(g,{attrs:{color:"error"},on:{click:e.resetLayout}},[e._v(e._s(e.$t("Settings.DashboardTab.ResetLayout")))])],1)],1)],1)],1)},$M=[],xM=E(zm,CM,$M,!1,null,"30a43531");const wM=xM.exports;var SM=Object.getOwnPropertyDescriptor,PM=(s,e,t,r)=>{for(var i=r>1?void 0:r?SM(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Gm=class extends k(Ns){resetLayout(){this.$store.dispatch("gui/resetLayout","tabletLayout1"),this.$store.dispatch("gui/resetLayout","tabletLayout2")}};Gm=PM([S({components:{SettingsDashboardSortable:Su}})],Gm);var DM=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{attrs:{flat:""}},[t(Z,[t(x,[t(b,{staticClass:"col-12 col-md-6"},[t("settings-dashboard-sortable",{attrs:{"viewport-name":"tablet",column:1}})],1),t(b,{staticClass:"col-12 col-md-6"},[t("settings-dashboard-sortable",{attrs:{"viewport-name":"tablet",column:2}})],1)],1),t(x,[t(b,{staticClass:"text-center"},[t(g,{attrs:{color:"error"},on:{click:e.resetLayout}},[e._v(e._s(e.$t("Settings.DashboardTab.ResetLayout")))])],1)],1)],1)],1)},TM=[],OM=E(Gm,DM,TM,!1,null,"48768826");const MM=OM.exports;var kM=Object.getOwnPropertyDescriptor,EM=(s,e,t,r)=>{for(var i=r>1?void 0:r?kM(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Zm=class extends k(Ns){resetLayout(){this.$store.dispatch("gui/resetLayout","desktopLayout1"),this.$store.dispatch("gui/resetLayout","desktopLayout2")}};Zm=EM([S({components:{SettingsDashboardSortable:Su}})],Zm);var LM=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{attrs:{flat:""}},[t(Z,[t(x,[t(b,{staticClass:"col-12 col-md-6"},[t("settings-dashboard-sortable",{attrs:{"viewport-name":"desktop",column:1}})],1),t(b,{staticClass:"col-12 col-md-6"},[t("settings-dashboard-sortable",{attrs:{"viewport-name":"desktop",column:2}})],1)],1),t(x,[t(b,{staticClass:"text-center"},[t(g,{attrs:{color:"error"},on:{click:e.resetLayout}},[e._v(e._s(e.$t("Settings.DashboardTab.ResetLayout")))])],1)],1)],1)],1)},AM=[],FM=E(Zm,LM,AM,!1,null,"158aaae3");const RM=FM.exports;var HM=Object.getOwnPropertyDescriptor,jM=(s,e,t,r)=>{for(var i=r>1?void 0:r?HM(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let qm=class extends k(Ns){resetLayout(){this.$store.dispatch("gui/resetLayout","widescreenLayout1"),this.$store.dispatch("gui/resetLayout","widescreenLayout2"),this.$store.dispatch("gui/resetLayout","widescreenLayout3")}};qm=jM([S({components:{SettingsDashboardSortable:Su}})],qm);var IM=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{attrs:{flat:""}},[t(Z,[t(x,[t(b,{staticClass:"col-12 col-md-4"},[t("settings-dashboard-sortable",{attrs:{"viewport-name":"widescreen",column:1}})],1),t(b,{staticClass:"col-12 col-md-4"},[t("settings-dashboard-sortable",{attrs:{"viewport-name":"widescreen",column:2}})],1),t(b,{staticClass:"col-12 col-md-4"},[t("settings-dashboard-sortable",{attrs:{"viewport-name":"widescreen",column:3}})],1)],1),t(x,[t(b,{staticClass:"text-center"},[t(g,{attrs:{color:"error"},on:{click:e.resetLayout}},[e._v(e._s(e.$t("Settings.DashboardTab.ResetLayout")))])],1)],1)],1)],1)},NM=[],VM=E(qm,IM,NM,!1,null,"c9afa703");const BM=VM.exports;var UM=Object.getOwnPropertyDescriptor,WM=(s,e,t,r)=>{for(var i=r>1?void 0:r?UM(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Xm=class extends k(L){constructor(){super(...arguments),this.mdiCellphone=Cw,this.mdiTablet=DS,this.mdiMonitorDashboard=Gp,this.mdiMonitorScreenshot=aS,this.currentViewport="desktop"}mounted(){this.isMobile?this.currentViewport="mobile":this.isTablet?this.currentViewport="tablet":this.isDesktop?this.currentViewport="desktop":this.isWidescreen?this.currentViewport="widescreen":this.currentViewport="desktop"}get currentTab(){return"settings-dashboard-tab-"+this.currentViewport}};Xm=WM([S({components:{SettingsDashboardTabMobile:wM,SettingsDashboardTabTablet:MM,SettingsDashboardTabDesktop:RM,SettingsDashboardTabWidescreen:BM}})],Xm);var zM=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{attrs:{flat:""}},[t(Z,[t(x,[t(b,{staticClass:"text-center"},[t(Nn,{staticClass:"mx-auto",attrs:{mandatory:""},model:{value:e.currentViewport,callback:function(r){e.currentViewport=r},expression:"currentViewport"}},[t(g,{attrs:{value:"mobile"}},[t("span",{staticClass:"hidden-sm-and-down"},[e._v(e._s(e.$t("Settings.DashboardTab.Mobile")))]),t(_,{staticClass:"hidden-sm-and-down",attrs:{right:""}},[e._v(e._s(e.mdiCellphone))]),t(_,{staticClass:"hidden-md-and-up"},[e._v(e._s(e.mdiCellphone))])],1),t(g,{attrs:{value:"tablet"}},[t("span",{staticClass:"hidden-sm-and-down"},[e._v(e._s(e.$t("Settings.DashboardTab.Tablet")))]),t(_,{staticClass:"hidden-sm-and-down",attrs:{right:""}},[e._v(e._s(e.mdiTablet))]),t(_,{staticClass:"hidden-md-and-up"},[e._v(e._s(e.mdiTablet))])],1),t(g,{attrs:{value:"desktop"}},[t("span",{staticClass:"hidden-sm-and-down"},[e._v(e._s(e.$t("Settings.DashboardTab.Desktop")))]),t(_,{staticClass:"hidden-sm-and-down",attrs:{right:""}},[e._v(e._s(e.mdiMonitorDashboard))]),t(_,{staticClass:"hidden-md-and-up"},[e._v(e._s(e.mdiMonitorDashboard))])],1),t(g,{attrs:{value:"widescreen"}},[t("span",{staticClass:"hidden-sm-and-down"},[e._v(e._s(e.$t("Settings.DashboardTab.Widescreen")))]),t(_,{staticClass:"hidden-sm-and-down",attrs:{right:""}},[e._v(e._s(e.mdiMonitorScreenshot))]),t(_,{staticClass:"hidden-md-and-up"},[e._v(e._s(e.mdiMonitorScreenshot))])],1)],1)],1)],1),t(x,[t(b,{staticClass:"dashboard-rows-container"},[t(e.currentTab,{tag:"component"})],1)],1)],1)],1)},GM=[],ZM=E(Xm,zM,GM,!1,null,"205c16a5");const qM=ZM.exports;var XM=Object.defineProperty,YM=Object.getOwnPropertyDescriptor,bf=(s,e,t,r)=>{for(var i=r>1?void 0:r?YM(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&XM(e,t,i),i};let da=class extends k(L){get showAxes(){return this.$store.state.gui.gcodeViewer.showAxes}set showAxes(e){this.$store.dispatch("gui/saveSetting",{name:"gcodeViewer.showAxes",value:e})}get extruderColors(){return this.$store.state.gui.gcodeViewer.extruderColors}colorsUpdated(e,t){let r=this.extruderColors;r[t]=e.hex,this.$store.dispatch("gui/saveSetting",{name:"gcodeViewer.extruderColors",value:r})}get backgroundColor(){return this.$store.state.gui.gcodeViewer.backgroundColor}set backgroundColor(e){this.$store.dispatch("gui/saveSetting",{name:"gcodeViewer.backgroundColor",value:e})}get gridColor(){return this.$store.state.gui.gcodeViewer.gridColor}set gridColor(e){this.$store.dispatch("gui/saveSetting",{name:"gcodeViewer.gridColor",value:e})}get progressColor(){return this.$store.state.gui.gcodeViewer.progressColor}set progressColor(e){this.$store.dispatch("gui/saveSetting",{name:"gcodeViewer.progressColor",value:e})}updateColorValue(e,t){y.set(this,e,this.clearColorObject(t))}clearColorObject(e){return typeof e=="object"&&"hex"in e&&(e=e.hex),e.length>7&&(e=e.substr(0,7)),e}get minFeed(){return this.$store.state.gui.gcodeViewer.minFeed}set minFeed(e){this.$store.dispatch("gui/saveSetting",{name:"gcodeViewer.minFeed",value:e})}get maxFeed(){return this.$store.state.gui.gcodeViewer.maxFeed}set maxFeed(e){this.$store.dispatch("gui/saveSetting",{name:"gcodeViewer.maxFeed",value:e})}get minFeedColor(){return this.$store.state.gui.gcodeViewer.minFeedColor}set minFeedColor(e){this.$store.dispatch("gui/saveSetting",{name:"gcodeViewer.minFeedColor",value:e})}get maxFeedColor(){return this.$store.state.gui.gcodeViewer.maxFeedColor}set maxFeedColor(e){this.$store.dispatch("gui/saveSetting",{name:"gcodeViewer.maxFeedColor",value:e})}feedBlur(){this.minFeed<1&&(this.minFeed=1),this.maxFeed<this.minFeed&&(this.maxFeed=this.minFeed+1)}};bf([Ke(500)],da.prototype,"colorsUpdated",1);bf([Ke(500)],da.prototype,"updateColorValue",1);da=bf([S({components:{SettingsRow:j}})],da);var JM=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(Pe,{attrs:{flat:""}},[t(Z,[t(j,{attrs:{title:e.$t("Settings.GCodeViewerTab.ShowAxes")}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.showAxes,callback:function(r){e.showAxes=r},expression:"showAxes"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GCodeViewerTab.BackgroundColor")}},[t(ye,{attrs:{"close-on-content-click":!1,bottom:"",left:"","offset-y":""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"minwidth-0 px-5",attrs:{color:e.backgroundColor,small:""}},"v-btn",i,!1),r))]}}])},[t(Xt,{attrs:{value:e.backgroundColor,"hide-mode-switch":"",mode:"rgba"},on:{"update:color":function(r){return e.updateColorValue("backgroundColor",r)}}})],1)],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GCodeViewerTab.GridColor")}},[t(ye,{attrs:{"close-on-content-click":!1,bottom:"",left:"","offset-y":""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"minwidth-0 px-5",attrs:{color:e.gridColor,small:""}},"v-btn",i,!1),r))]}}])},[t(Xt,{attrs:{value:e.gridColor,"hide-mode-switch":"",mode:"rgba"},on:{"update:color":function(r){return e.updateColorValue("gridColor",r)}}})],1)],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GCodeViewerTab.ProgressColor")}},[t(ye,{attrs:{"close-on-content-click":!1,bottom:"",left:"","offset-y":""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"minwidth-0 px-5",attrs:{color:e.progressColor,small:""}},"v-btn",i,!1),r))]}}])},[t(Xt,{attrs:{value:e.progressColor,"hide-mode-switch":"",mode:"rgba"},on:{"update:color":function(r){return e.updateColorValue("progressColor",r)}}})],1)],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GCodeViewerTab.ExtruderColor")}},[t(x,{attrs:{"no-gutters":""}},e._l(e.extruderColors,function(r,i){return t(ye,{key:i,attrs:{"close-on-content-click":!1,bottom:"",left:"","offset-y":""},scopedSlots:e._u([{key:"activator",fn:function({on:n,attrs:a}){return[t(b,{staticClass:"mt-1",attrs:{align:"right",cols:"12"}},[t("span",{staticClass:"mr-2"},[e._v(e._s(i))]),t(g,e._g(e._b({staticClass:"minwidth-0 px-5",attrs:{color:e.extruderColors[i],small:""}},"v-btn",a,!1),n))],1)]}}],null,!0)},[t(Xt,{attrs:{value:e.extruderColors[i],"hide-mode-switch":"",mode:"rgba"},on:{"update:color":function(n){return e.colorsUpdated(n,i)}}})],1)}),1)],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GCodeViewerTab.MinFeed")}},[t(ye,{attrs:{"close-on-content-click":!1,bottom:"",left:"","offset-y":""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"minwidth-0 px-5 mr-3",attrs:{color:e.minFeedColor,small:""}},"v-btn",i,!1),r))]}}])},[t(Xt,{attrs:{value:e.minFeedColor,"hide-mode-switch":"",mode:"rgba"},on:{"update:color":function(r){return e.updateColorValue("minFeedColor",r)}}})],1),t(se,{attrs:{rules:[r=>r>0||"Minimum speed is 1"],dense:"","hide-details":"auto",outlined:"",suffix:"mm/s",type:"number","hide-spin-buttons":""},on:{blur:e.feedBlur},model:{value:e.minFeed,callback:function(r){e.minFeed=r},expression:"minFeed"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.GCodeViewerTab.MaxFeed")}},[t(ye,{attrs:{"close-on-content-click":!1,bottom:"",left:"","offset-y":""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"minwidth-0 px-5 mr-3",attrs:{color:e.maxFeedColor,small:""}},"v-btn",i,!1),r))]}}])},[t(Xt,{attrs:{value:e.maxFeedColor,"hide-mode-switch":"",mode:"rgba"},on:{"update:color":function(r){return e.updateColorValue("maxFeedColor",r)}}})],1),t(se,{attrs:{rules:[r=>r>0||"Minimum speed is 1"],dense:"","hide-details":"auto",outlined:"",suffix:"mm/s",type:"number","hide-spin-buttons":""},on:{blur:e.feedBlur},model:{value:e.maxFeed,callback:function(r){e.maxFeed=r},expression:"maxFeed"}})],1)],1)],1)],1)},KM=[],QM=E(da,JM,KM,!1,null,null);const e6=QM.exports;var t6=Object.getOwnPropertyDescriptor,s6=(s,e,t,r)=>{for(var i=r>1?void 0:r?t6(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Ym=class extends k(L){constructor(){super(...arguments),this.klipperRestartMethods=[{text:"FIRMWARE_RESTART",value:"FIRMWARE_RESTART"},{text:"RESTART",value:"RESTART"}]}get tabSizes(){return[2,4,6,8].map(t=>({text:this.$t("Settings.EditorTab.Spaces",{count:t}),value:t}))}get escToClose(){return this.$store.state.gui.editor.escToClose}set escToClose(e){this.$store.dispatch("gui/saveSetting",{name:"editor.escToClose",value:e})}get confirmUnsavedChanges(){return this.$store.state.gui.editor.confirmUnsavedChanges}set confirmUnsavedChanges(e){this.$store.dispatch("gui/saveSetting",{name:"editor.confirmUnsavedChanges",value:e})}get tabSize(){return this.$store.state.gui.editor.tabSize||2}set tabSize(e){this.$store.dispatch("gui/saveSetting",{name:"editor.tabSize",value:e})}get klipperRestartMethod(){return this.$store.state.gui.editor.klipperRestartMethod}set klipperRestartMethod(e){this.$store.dispatch("gui/saveSetting",{name:"editor.klipperRestartMethod",value:e})}};Ym=s6([S({components:{SettingsRow:j}})],Ym);var r6=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(Pe,{attrs:{flat:""}},[t(Z,[t(j,{attrs:{title:e.$t("Settings.EditorTab.UseEscToClose"),"sub-title":e.$t("Settings.EditorTab.UseEscToCloseDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.escToClose,callback:function(r){e.escToClose=r},expression:"escToClose"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.EditorTab.ConfirmUnsavedChanges"),"sub-title":e.$t("Settings.EditorTab.ConfirmUnsavedChangesDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.confirmUnsavedChanges,callback:function(r){e.confirmUnsavedChanges=r},expression:"confirmUnsavedChanges"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.EditorTab.TabSize"),"sub-title":e.$t("Settings.EditorTab.TabSizeDescription"),"dynamic-slot-width":!0}},[t(ke,{attrs:{items:e.tabSizes,"hide-details":"",outlined:"",dense:"",attached:""},model:{value:e.tabSize,callback:function(r){e.tabSize=r},expression:"tabSize"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.EditorTab.KlipperRestartMethod"),"sub-title":e.$t("Settings.EditorTab.KlipperRestartMethodDescription")}},[t(ke,{attrs:{items:e.klipperRestartMethods,"hide-details":"",outlined:"",dense:"",attached:""},model:{value:e.klipperRestartMethod,callback:function(r){e.klipperRestartMethod=r},expression:"klipperRestartMethod"}})],1)],1)],1)],1)},i6=[],n6=E(Ym,r6,i6,!1,null,null);const a6=n6.exports;var o6=Object.getOwnPropertyDescriptor,l6=(s,e,t,r)=>{for(var i=r>1?void 0:r?o6(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Jm=class extends k(L){constructor(){super(...arguments),this.modeOptions=[{text:"layermacro",value:"layermacro"},{text:"hyperlapse",value:"hyperlapse"}],this.parkposOptions=[{text:"center",value:"center"},{text:"front_left",value:"front_left"},{text:"front_right",value:"front_right"},{text:"back_left",value:"back_left"},{text:"back_right",value:"back_right"},{text:"x_only",value:"x_only"},{text:"y_only",value:"y_only"},{text:"custom",value:"custom"}]}get availableSnapshotWebcams(){return this.$store.getters["gui/webcams/getWebcams"].filter(e=>e.snapshot_url!=="")}get cameraOptions(){let e=[];return this.availableSnapshotWebcams.length===0?[{value:null,text:this.$t("Settings.TimelapseTab.NoWebcamFound")}]:(this.availableSnapshotWebcams.forEach(t=>{e.push({text:t.name,value:t.name})}),e=Ft(e,"text"),this.camera===null&&e.unshift({value:null,text:this.$t("Settings.TimelapseTab.SelectWebcam")}),e)}get blockedsettings(){var e;return(e=this.$store.state.server.timelapse.settings.blockedsettings)!=null?e:[]}get enabled(){return this.$store.state.server.timelapse.settings.enabled}set enabled(e){this.$store.dispatch("server/timelapse/saveSetting",{enabled:e})}get mode(){return this.$store.state.server.timelapse.settings.mode}set mode(e){this.$store.dispatch("server/timelapse/saveSetting",{mode:e})}get hyperlapseCycle(){return this.$store.state.server.timelapse.settings.hyperlapse_cycle}set hyperlapseCycle(e){this.$store.dispatch("server/timelapse/saveSetting",{hyperlapse_cycle:e})}get autorender(){return this.$store.state.server.timelapse.settings.autorender}set autorender(e){this.$store.dispatch("server/timelapse/saveSetting",{autorender:e})}get saveframes(){return this.$store.state.server.timelapse.settings.saveframes}set saveframes(e){this.$store.dispatch("server/timelapse/saveSetting",{saveframes:e})}get stream_delay_compensation(){return this.$store.state.server.timelapse.settings.stream_delay_compensation}set stream_delay_compensation(e){e===""&&(e=0),this.$store.dispatch("server/timelapse/saveSetting",{stream_delay_compensation:e})}get previewimage(){return this.$store.state.server.timelapse.settings.previewimage}set previewimage(e){this.$store.dispatch("server/timelapse/saveSetting",{previewimage:e})}get gcode_verbose(){return this.$store.state.server.timelapse.settings.gcode_verbose}set gcode_verbose(e){this.$store.dispatch("server/timelapse/saveSetting",{gcode_verbose:e})}get parkhead(){return this.$store.state.server.timelapse.settings.parkhead}set parkhead(e){this.$store.dispatch("server/timelapse/saveSetting",{parkhead:e})}get parkpos(){return this.$store.state.server.timelapse.settings.parkpos}set parkpos(e){this.$store.dispatch("server/timelapse/saveSetting",{parkpos:e})}get park_custom_pos_x(){return this.$store.state.server.timelapse.settings.park_custom_pos_x}set park_custom_pos_x(e){e===""||e<this.stepperXmin||e>this.stepperXmax||this.$store.dispatch("server/timelapse/saveSetting",{park_custom_pos_x:e})}get stepperXmin(){var e,t,r,i;return(i=(r=(t=(e=this.$store.state.printer.configfile)==null?void 0:e.settings)==null?void 0:t.stepper_x)==null?void 0:r.position_min)!=null?i:0}get stepperXmax(){var e,t,r,i;return(i=(r=(t=(e=this.$store.state.printer.configfile)==null?void 0:e.settings)==null?void 0:t.stepper_x)==null?void 0:r.position_max)!=null?i:200}get park_custom_pos_y(){return this.$store.state.server.timelapse.settings.park_custom_pos_y}set park_custom_pos_y(e){e===""||e<this.stepperYmin||e>this.stepperYmax||this.$store.dispatch("server/timelapse/saveSetting",{park_custom_pos_y:e})}get stepperYmin(){var e,t,r,i;return(i=(r=(t=(e=this.$store.state.printer.configfile)==null?void 0:e.settings)==null?void 0:t.stepper_y)==null?void 0:r.position_min)!=null?i:0}get stepperYmax(){var e,t,r,i;return(i=(r=(t=(e=this.$store.state.printer.configfile)==null?void 0:e.settings)==null?void 0:t.stepper_y)==null?void 0:r.position_max)!=null?i:200}get park_custom_pos_dz(){return this.$store.state.server.timelapse.settings.park_custom_pos_dz}set park_custom_pos_dz(e){e===""||e<0||this.$store.dispatch("server/timelapse/saveSetting",{park_custom_pos_dz:e})}get park_travel_speed(){return this.$store.state.server.timelapse.settings.park_travel_speed}set park_travel_speed(e){e===""||e<0||this.$store.dispatch("server/timelapse/saveSetting",{park_travel_speed:e})}get park_retract_speed(){return this.$store.state.server.timelapse.settings.park_retract_speed}set park_retract_speed(e){e===""||e<=0||this.$store.dispatch("server/timelapse/saveSetting",{park_retract_speed:e})}get park_extrude_speed(){return this.$store.state.server.timelapse.settings.park_extrude_speed}set park_extrude_speed(e){e===""||e<=0||this.$store.dispatch("server/timelapse/saveSetting",{park_extrude_speed:e})}get park_retract_distance(){return this.$store.state.server.timelapse.settings.park_retract_distance}set park_retract_distance(e){e===""||e<0||this.$store.dispatch("server/timelapse/saveSetting",{park_retract_distance:e})}get park_extrude_distance(){return this.$store.state.server.timelapse.settings.park_extrude_distance}set park_extrude_distance(e){e===""||e<0||this.$store.dispatch("server/timelapse/saveSetting",{park_extrude_distance:e})}get park_time(){return this.$store.state.server.timelapse.settings.park_time}set park_time(e){e===""||e<0||this.$store.dispatch("server/timelapse/saveSetting",{park_time:e})}get fw_retract(){return this.$store.state.server.timelapse.settings.fw_retract}set fw_retract(e){this.$store.dispatch("server/timelapse/saveSetting",{fw_retract:e})}get constant_rate_factor(){return this.$store.state.server.timelapse.settings.constant_rate_factor}set constant_rate_factor(e){e===""||e<=0||this.$store.dispatch("server/timelapse/saveSetting",{constant_rate_factor:e})}get output_framerate(){return this.$store.state.server.timelapse.settings.output_framerate}set output_framerate(e){e===""||e<=0||this.$store.dispatch("server/timelapse/saveSetting",{output_framerate:e})}get pixelformat(){return this.$store.state.server.timelapse.settings.pixelformat}set pixelformat(e){this.$store.dispatch("server/timelapse/saveSetting",{pixelformat:e})}get extraoutputparams(){return this.$store.state.server.timelapse.settings.extraoutputparams}set extraoutputparams(e){this.$store.dispatch("server/timelapse/saveSetting",{extraoutputparams:e})}get variable_fps(){return this.$store.state.server.timelapse.settings.variable_fps}set variable_fps(e){this.$store.dispatch("server/timelapse/saveSetting",{variable_fps:e})}get targetlength(){return this.$store.state.server.timelapse.settings.targetlength}set targetlength(e){e===""||e<=0||this.$store.dispatch("server/timelapse/saveSetting",{targetlength:e})}get variable_fps_min(){return this.$store.state.server.timelapse.settings.variable_fps_min}set variable_fps_min(e){e===""||e<=0||this.$store.dispatch("server/timelapse/saveSetting",{variable_fps_min:e})}get variable_fps_max(){return this.$store.state.server.timelapse.settings.variable_fps_max}set variable_fps_max(e){e===""||e<=this.variable_fps_min||this.$store.dispatch("server/timelapse/saveSetting",{variable_fps_max:e})}get duplicatelastframe(){return this.$store.state.server.timelapse.settings.duplicatelastframe}set duplicatelastframe(e){e===""||e<0||this.$store.dispatch("server/timelapse/saveSetting",{duplicatelastframe:e})}get camera(){var t;const e=(t=this.$store.state.server.timelapse.settings.camera)!=null?t:null;return e===null||this.blockedsettings.includes("snapshoturl")||this.availableSnapshotWebcams.length===0||this.availableSnapshotWebcams.find(r=>r.name===e)===void 0?null:this.$store.state.server.timelapse.settings.camera}set camera(e){this.$store.dispatch("server/timelapse/saveSetting",{camera:e})}get time_format_code(){return this.$store.state.server.timelapse.settings.time_format_code}set time_format_code(e){this.$store.dispatch("server/timelapse/saveSetting",{time_format_code:e})}};Jm=l6([S({components:{SettingsRow:j}})],Jm);var c6=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(Pe,{attrs:{flat:""}},[t(Z,[t("h3",{staticClass:"text-h5 mb-3"},[e._v(e._s(e.$t("Settings.TimelapseTab.General")))]),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.Enabled"),"sub-title":e.$t("Settings.TimelapseTab.EnabledDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":"",disabled:e.blockedsettings.includes("enabled")},model:{value:e.enabled,callback:function(r){e.enabled=r},expression:"enabled"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.Autorender"),"sub-title":e.$t("Settings.TimelapseTab.AutorenderDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":"",disabled:e.blockedsettings.includes("autorender")},model:{value:e.autorender,callback:function(r){e.autorender=r},expression:"autorender"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.Camera"),"sub-title":e.$t("Settings.TimelapseTab.CameraDescriptionWithSnapshotUrl")}},[e.blockedsettings.includes("snapshoturl")?t(it,{staticClass:"mb-0",attrs:{dense:"",text:"",type:"warning"}},[e._v(" "+e._s(e.$t("Settings.TimelapseTab.CameraWarningAlreadySet"))+" "),t("small",[e._v("("+e._s(e.$t("Settings.TimelapseTab.CameraWarningAlreadySetSmall"))+")")])]):t(ke,{attrs:{items:e.cameraOptions,"hide-details":"",outlined:"",dense:"",disabled:e.blockedsettings.includes("camera")||e.availableSnapshotWebcams.length===0},model:{value:e.camera,callback:function(r){e.camera=r},expression:"camera"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.Mode"),"sub-title":e.$t("Settings.TimelapseTab.ModeDescription")}},[t(ke,{attrs:{items:e.modeOptions,"hide-details":"",outlined:"",dense:"",disabled:e.blockedsettings.includes("modeOptions")},model:{value:e.mode,callback:function(r){e.mode=r},expression:"mode"}})],1),e.mode==="hyperlapse"?[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.HyperlapseCycle"),"sub-title":e.$t("Settings.TimelapseTab.HyperlapseCycleDescription")}},[t(se,{attrs:{type:"number",suffix:"s","hide-details":"auto",outlined:"",dense:"",disabled:e.blockedsettings.includes("hyperlapseCycle"),"hide-spin-buttons":""},model:{value:e.hyperlapseCycle,callback:function(r){e.hyperlapseCycle=r},expression:"hyperlapseCycle"}})],1)]:e._e(),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.PreviewImage"),"sub-title":e.$t("Settings.TimelapseTab.PreviewImageDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":"",disabled:e.blockedsettings.includes("previewimage")},model:{value:e.previewimage,callback:function(r){e.previewimage=r},expression:"previewimage"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.SaveFrames"),"sub-title":e.$t("Settings.TimelapseTab.SaveFramesDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":"",disabled:e.blockedsettings.includes("saveframes")},model:{value:e.saveframes,callback:function(r){e.saveframes=r},expression:"saveframes"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.StreamDelayCompensation"),"sub-title":e.$t("Settings.TimelapseTab.StreamDelayCompensationDescription")}},[t(se,{attrs:{type:"number",suffix:"s",step:"0.01","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>=0||e.$t("Settings.TimelapseTab.RulesZeroAndPositive")],disabled:e.blockedsettings.includes("stream_delay_compensation")},model:{value:e.stream_delay_compensation,callback:function(r){e.stream_delay_compensation=r},expression:"stream_delay_compensation"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.GcodeVerbose"),"sub-title":e.$t("Settings.TimelapseTab.GcodeVerboseDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":"",disabled:e.blockedsettings.includes("gcode_verbose")},model:{value:e.gcode_verbose,callback:function(r){e.gcode_verbose=r},expression:"gcode_verbose"}})],1),t(I,{staticClass:"my-2"}),t("h3",{staticClass:"text-h5 mt-6 mb-3"},[e._v(e._s(e.$t("Settings.TimelapseTab.Parkhead")))]),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.Parkhead"),"sub-title":e.$t("Settings.TimelapseTab.ParkheadDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":"",disabled:e.blockedsettings.includes("parkhead")},model:{value:e.parkhead,callback:function(r){e.parkhead=r},expression:"parkhead"}})],1),e.parkhead?[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.Parkpos"),"sub-title":e.$t("Settings.TimelapseTab.ParkposDescription")}},[t(ke,{attrs:{items:e.parkposOptions,"hide-details":"",outlined:"",dense:"",disabled:e.blockedsettings.includes("parkposOptions")},model:{value:e.parkpos,callback:function(r){e.parkpos=r},expression:"parkpos"}})],1),["x_only","custom"].includes(e.parkpos)?[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.PosX"),"sub-title":e.$t("Settings.TimelapseTab.PosXDescription")}},[t(se,{attrs:{type:"number",suffix:"mm","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>=e.stepperXmin&&r<=e.stepperXmax||e.$t("Settings.TimelapseTab.RulesBetweenMinMax",{min:e.stepperXmin,max:e.stepperXmax})],disabled:e.blockedsettings.includes("park_custom_pos_x"),"hide-spin-buttons":""},model:{value:e.park_custom_pos_x,callback:function(r){e.park_custom_pos_x=r},expression:"park_custom_pos_x"}})],1)]:e._e(),["y_only","custom"].includes(e.parkpos)?[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.PosY"),"sub-title":e.$t("Settings.TimelapseTab.PosYDescription")}},[t(se,{attrs:{type:"number",suffix:"mm","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>=e.stepperYmin&&r<=e.stepperYmax||e.$t("Settings.TimelapseTab.RulesBetweenMinMax",{min:e.stepperYmin,max:e.stepperYmax})],disabled:e.blockedsettings.includes("park_custom_pos_y"),"hide-spin-buttons":""},model:{value:e.park_custom_pos_y,callback:function(r){e.park_custom_pos_y=r},expression:"park_custom_pos_y"}})],1)]:e._e(),["x_only","y_only","custom"].includes(e.parkpos)?[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.PosDZ"),"sub-title":e.$t("Settings.TimelapseTab.PosDZDescription")}},[t(se,{attrs:{type:"number",suffix:"mm","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>=0||e.$t("Settings.TimelapseTab.RulesZeroAndPositive")],disabled:e.blockedsettings.includes("park_custom_pos_dz"),"hide-spin-buttons":""},model:{value:e.park_custom_pos_dz,callback:function(r){e.park_custom_pos_dz=r},expression:"park_custom_pos_dz"}})],1)]:e._e(),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.TravelSpeed"),"sub-title":e.$t("Settings.TimelapseTab.TravelSpeedDescription")}},[t(se,{attrs:{type:"number",suffix:"mm/s","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>=0||e.$t("Settings.TimelapseTab.RulesZeroAndPositive")],disabled:e.blockedsettings.includes("park_travel_speed"),"hide-spin-buttons":""},model:{value:e.park_travel_speed,callback:function(r){e.park_travel_speed=r},expression:"park_travel_speed"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.FwRetract"),"sub-title":e.$t("Settings.TimelapseTab.FwRetractDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":"",disabled:e.blockedsettings.includes("fw_retract")},model:{value:e.fw_retract,callback:function(r){e.fw_retract=r},expression:"fw_retract"}})],1),e.fw_retract?e._e():[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.RetractSpeed"),"sub-title":e.$t("Settings.TimelapseTab.RetractSpeedDescription")}},[t(se,{attrs:{type:"number",suffix:"mm/s","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>0||e.$t("Settings.TimelapseTab.RulesPositive")],disabled:e.blockedsettings.includes("park_retract_speed"),"hide-spin-buttons":""},model:{value:e.park_retract_speed,callback:function(r){e.park_retract_speed=r},expression:"park_retract_speed"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.RetractDistance"),"sub-title":e.$t("Settings.TimelapseTab.RetractDistanceDescription")}},[t(se,{attrs:{type:"number",suffix:"mm","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>=0||e.$t("Settings.TimelapseTab.RulesZeroAndPositive")],disabled:e.blockedsettings.includes("park_retract_distance"),"hide-spin-buttons":""},model:{value:e.park_retract_distance,callback:function(r){e.park_retract_distance=r},expression:"park_retract_distance"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.UnretractSpeed"),"sub-title":e.$t("Settings.TimelapseTab.UnretractSpeedDescription")}},[t(se,{attrs:{type:"number",suffix:"mm/s","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>0||e.$t("Settings.TimelapseTab.RulesPositive")],disabled:e.blockedsettings.includes("park_extrude_speed"),"hide-spin-buttons":""},model:{value:e.park_extrude_speed,callback:function(r){e.park_extrude_speed=r},expression:"park_extrude_speed"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.UnretractDistance"),"sub-title":e.$t("Settings.TimelapseTab.UnretractDistanceDescription")}},[t(se,{attrs:{type:"number",suffix:"mm","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>=0||e.$t("Settings.TimelapseTab.RulesZeroAndPositive")],disabled:e.blockedsettings.includes("park_extrude_distance"),"hide-spin-buttons":""},model:{value:e.park_extrude_distance,callback:function(r){e.park_extrude_distance=r},expression:"park_extrude_distance"}})],1)],t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.ParkTime"),"sub-title":e.$t("Settings.TimelapseTab.ParkTimeDescription")}},[t(se,{attrs:{type:"number",suffix:"s","hide-details":"auto",step:"0.1",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>=0||e.$t("Settings.TimelapseTab.RulesZeroAndPositive")],disabled:e.blockedsettings.includes("park_time")},model:{value:e.park_time,callback:function(r){e.park_time=r},expression:"park_time"}})],1)]:e._e(),t(I,{staticClass:"my-2"}),t("h3",{staticClass:"text-h5 mt-6 mb-3"},[e._v(e._s(e.$t("Settings.TimelapseTab.RenderingOptions")))]),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.VariableFps"),"sub-title":e.$t("Settings.TimelapseTab.VariableFpsDescription"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":"",disabled:e.blockedsettings.includes("variable_fps")},model:{value:e.variable_fps,callback:function(r){e.variable_fps=r},expression:"variable_fps"}})],1),e.variable_fps?[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.Targetlength"),"sub-title":e.$t("Settings.TimelapseTab.TargetlengthDescription")}},[t(se,{attrs:{type:"number",suffix:"s","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>0||e.$t("Settings.TimelapseTab.RulesPositive")],disabled:e.blockedsettings.includes("targetlength"),"hide-spin-buttons":""},model:{value:e.targetlength,callback:function(r){e.targetlength=r},expression:"targetlength"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.VariableFpsMin"),"sub-title":e.$t("Settings.TimelapseTab.VariableFpsMinDescription")}},[t(se,{attrs:{type:"number",suffix:"frames","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>0||e.$t("Settings.TimelapseTab.RulesPositive")],disabled:e.blockedsettings.includes("variable_fps_min"),"hide-spin-buttons":""},model:{value:e.variable_fps_min,callback:function(r){e.variable_fps_min=r},expression:"variable_fps_min"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.VariableFpsMax"),"sub-title":e.$t("Settings.TimelapseTab.VariableFpsMaxDescription")}},[t(se,{attrs:{type:"number",suffix:"frames","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>e.variable_fps_min||e.$t("Settings.TimelapseTab.RulesMin")],disabled:e.blockedsettings.includes("variable_fps_max"),"hide-spin-buttons":""},model:{value:e.variable_fps_max,callback:function(r){e.variable_fps_max=r},expression:"variable_fps_max"}})],1)]:[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.OutputFramerate"),"sub-title":e.$t("Settings.TimelapseTab.OutputFramerateDescription")}},[t(se,{attrs:{type:"number",suffix:"frames","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>0||e.$t("Settings.TimelapseTab.RulesPositive")],disabled:e.blockedsettings.includes("output_framerate"),"hide-spin-buttons":""},model:{value:e.output_framerate,callback:function(r){e.output_framerate=r},expression:"output_framerate"}})],1)],t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.duplicatelastframe"),"sub-title":e.$t("Settings.TimelapseTab.duplicatelastframeDescription")}},[t(se,{attrs:{type:"number","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>=0||e.$t("Settings.TimelapseTab.RulesZeroAndPositive")],disabled:e.blockedsettings.includes("duplicatelastframe"),"hide-spin-buttons":""},model:{value:e.duplicatelastframe,callback:function(r){e.duplicatelastframe=r},expression:"duplicatelastframe"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.ConstantRateFactor"),"sub-title":e.$t("Settings.TimelapseTab.ConstantRateFactorDescription")}},[t(se,{attrs:{type:"number","hide-details":"auto",outlined:"",dense:"",rules:[r=>!!r||e.$t("Settings.TimelapseTab.RulesRequired"),r=>r>0||e.$t("Settings.TimelapseTab.RulesPositive")],disabled:e.blockedsettings.includes("constant_rate_factor"),"hide-spin-buttons":""},model:{value:e.constant_rate_factor,callback:function(r){e.constant_rate_factor=r},expression:"constant_rate_factor"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.Pixelformat"),"sub-title":e.$t("Settings.TimelapseTab.PixelformatDescription")}},[t(se,{attrs:{type:"text","hide-details":"auto",outlined:"",dense:"",disabled:e.blockedsettings.includes("pixelformat")},model:{value:e.pixelformat,callback:function(r){e.pixelformat=r},expression:"pixelformat"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.TimeFormatCode"),"sub-title":e.$t("Settings.TimelapseTab.TimeFormatCodeDescription")}},[t(se,{attrs:{type:"text","hide-details":"auto",outlined:"",dense:"",disabled:e.blockedsettings.includes("time_format_code")},model:{value:e.time_format_code,callback:function(r){e.time_format_code=r},expression:"time_format_code"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.TimelapseTab.Extraoutputparams"),"sub-title":e.$t("Settings.TimelapseTab.ExtraoutputparamsDescription")}},[t(se,{attrs:{type:"text","hide-details":"auto",outlined:"",dense:"",disabled:e.blockedsettings.includes("extraoutputparams")},model:{value:e.extraoutputparams,callback:function(r){e.extraoutputparams=r},expression:"extraoutputparams"}})],1)],2)],1)],1)},u6=[],d6=E(Jm,c6,u6,!1,null,null);const m6=d6.exports;var h6=Object.defineProperty,p6=Object.getOwnPropertyDescriptor,Bb=(s,e,t,r)=>{for(var i=r>1?void 0:r?p6(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&h6(e,t,i),i};let Vl=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiStopCircleOutline=PS}cancelJob(){this.$emit("cancel-job")}closePrompt(){this.$emit("close")}};Bb([w({type:Boolean,default:!1})],Vl.prototype,"showDialog",2);Vl=Bb([S({components:{Panel:U}})],Vl);var f6=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.showDialog,width:"400",persistent:""}},[t(U,{attrs:{title:e.$t("CancelJobDialog.CancelJob"),"toolbar-color":"normal","card-class":"cancel-job-dialog",icon:e.mdiStopCircleOutline,"margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closePrompt}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[e._v(e._s(e.$t("CancelJobDialog.AreYouSure")))]),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.closePrompt}},[e._v(e._s(e.$t("CancelJobDialog.No")))]),t(g,{attrs:{color:"primary",text:""},on:{click:e.cancelJob}},[e._v(e._s(e.$t("CancelJobDialog.Yes")))])],1)],1)],1)},g6=[],_6=E(Vl,f6,g6,!1,null,"a6fd90b2");const Ub=_6.exports;var v6=Object.getOwnPropertyDescriptor,b6=(s,e,t,r)=>{for(var i=r>1?void 0:r?v6(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Km=class extends k(L){constructor(){super(...arguments),this.mdiPrinter3d=qa,this.mdiRestart=_r,this.mdiDownload=K_,this.mdiPower=_v}get klippy_message(){var s;return(s=this.$store.state.server.klippy_message)!=null?s:null}get messageType(){switch(this.klipperState){case"startup":return{color:"info",icon:yS};case"shutdown":return{color:"warning",icon:Jn};case"error":return{color:"error",icon:Jn};case"disconnected":return{color:"",icon:Ap};default:return{color:"",icon:sS}}}get buttonClasses(){return[this.messageType.color+"--text","my-1","w-100"]}get serviceReportsKlipper(){return"".concat(this.$t("Panels.KlippyStatePanel.ServiceReports",{service:"Klipper"}),": ").concat(this.klipperState.toUpperCase())}get serviceReportsMoonraker(){return"".concat(this.$t("Panels.KlippyStatePanel.ServiceReports",{service:"Moonraker"}),": ").concat(this.klipperState.toUpperCase())}restart(){this.$socket.emit("printer.restart",{},{loading:"restart"})}firmwareRestart(){this.$socket.emit("printer.firmware_restart",{},{loading:"firmwareRestart"})}downloadLog(s){s.preventDefault();let e="";"href"in s.target.attributes&&(e=s.target.attributes.href.value),"href"in s.target.parentElement.attributes&&(e=s.target.parentElement.attributes.href.value),window.open(e)}powerOn(){this.$socket.emit("machine.device_power.post_device",{device:this.printerPowerDevice,action:"on"},{action:"server/power/responseToggle"})}};Km=b6([S({components:{Panel:U,ConnectionStatus:lu}})],Km);var y6=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.klipperState!=="ready"&&e.socketIsConnected?t("div",[e.klippyIsConnected?t(it,{staticClass:"mb-0 mb-6",attrs:{color:e.messageType.color,dense:"",text:"",border:"left"}},[t("p",{staticClass:"font-weight-medium d-flex align-center"},[t(_,{staticClass:"pr-2",attrs:{color:e.messageType.color}},[e._v(e._s(e.messageType.icon))]),e._v(" "+e._s(e.serviceReportsKlipper)+" ")],1),e.klippy_message!==null?t("div",[t("pre",{staticStyle:{"white-space":"pre-wrap"}},[e._v(e._s(e.klippy_message.trim()))]),t(I,{staticClass:"mt-2 pb-3"}),t(x,[t(b,[t(g,{class:e.buttonClasses,attrs:{small:"",outlined:"",text:""},on:{click:e.restart}},[t(_,{staticClass:"mr-sm-2"},[e._v(e._s(e.mdiRestart))]),e._v(" "+e._s(e.$t("Panels.KlippyStatePanel.Restart"))+" ")],1),t(g,{class:e.buttonClasses,attrs:{small:"",outlined:"",text:""},on:{click:e.firmwareRestart}},[t(_,{staticClass:"mr-sm-2"},[e._v(e._s(e.mdiRestart))]),e._v(" "+e._s(e.$t("Panels.KlippyStatePanel.FirmwareRestart"))+" ")],1)],1),t(b,[t(g,{class:e.buttonClasses,attrs:{href:e.apiUrl+"/server/files/klippy.log",small:"",outlined:"",text:""},on:{click:e.downloadLog}},[t(_,{staticClass:"mr-2"},[e._v(e._s(e.mdiDownload))]),e._v(" "+e._s(e.$t("Panels.KlippyStatePanel.KlipperLog"))+" ")],1),t(g,{class:e.buttonClasses,attrs:{href:e.apiUrl+"/server/files/moonraker.log",small:"",outlined:"",text:""},on:{click:e.downloadLog}},[t(_,{staticClass:"mr-2"},[e._v(e._s(e.mdiDownload))]),e._v(" "+e._s(e.$t("Panels.KlippyStatePanel.MoonrakerLog"))+" ")],1)],1)],1)],1):t(Z,{staticClass:"text-center py-3"},[t(ot,{attrs:{indeterminate:"",color:e.messageType.color}})],1)],1):e.isPrinterPowerOff?t(it,{staticClass:"mb-6",attrs:{dense:"",text:"",border:"left"}},[t("p",{staticClass:"font-weight-medium d-flex align-center"},[t(_,{staticClass:"pr-2"},[e._v(e._s(e.messageType.icon))]),e._v(" "+e._s(e.$t("Panels.KlippyStatePanel.PrinterSwitchedOff"))+" ")],1),t("p",[e._v(e._s(e.$t("Panels.KlippyStatePanel.PrinterSwitchedOffDescription")))]),t(x,[t(b,{staticClass:"text-center"},[t(g,{class:"".concat(e.messageType.color,"--text my-1"),attrs:{small:"",outlined:"",text:""},on:{click:e.powerOn}},[t(_,{staticClass:"mr-sm-2"},[e._v(e._s(e.mdiPower))]),e._v(" "+e._s(e.$t("Panels.KlippyStatePanel.PowerOn"))+" ")],1)],1)],1)],1):e.klipperState==="disconnected"?t(it,{staticClass:"mb-6",attrs:{dense:"",text:"",border:"left"}},[t("p",{staticClass:"font-weight-medium d-flex align-center"},[t(_,{staticClass:"pr-2"},[e._v(e._s(e.messageType.icon))]),e._v(" "+e._s(e.serviceReportsMoonraker)+" ")],1),t(lu,{attrs:{moonraker:!0,klipper:!1}}),t("p",{staticClass:"mt-2 mb-0 text-center"},[e._v(e._s(e.$t("Panels.KlippyStatePanel.MoonrakerCannotConnect")))]),t("p",{staticClass:"mb-0 text-center"},[e._v(e._s(e.$t("Panels.KlippyStatePanel.CheckKlippyAndUdsAddress")))])],1):e._e()],1):e._e()},C6=[],$6=E(Km,y6,C6,!1,null,null);const so=$6.exports;var x6=Object.getOwnPropertyDescriptor,w6=(s,e,t,r)=>{for(var i=r>1?void 0:r?x6(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Qm=class extends k(L){constructor(){super(...arguments),this.mdiAlertCircle=U_,this.mdiInformation=Ht}get existsPrinterConfig(){var e;return(e=this.$store.getters["printer/existPrinterConfig"])!=null?e:!1}get missingConfigs(){var e;return(e=this.$store.getters["printer/checkNecessaryConfig"])!=null?e:[]}get mainsailCfgExists(){var e;return(e=this.$store.getters["files/checkConfigFile"]("mainsail.cfg"))!=null?e:!1}};Qm=w6([S({components:{Panel:U}})],Qm);var S6=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.klipperState==="ready"&&e.existsPrinterConfig&&e.missingConfigs.length?t(U,{attrs:{icon:e.mdiAlertCircle,title:e.$t("Panels.MinSettingsPanel.MissingConfiguration"),collapsible:!0,"card-class":"min-settings-panel","toolbar-color":"orange darken-2"}},[t(Z,[t(x,[t(b,[t("ul",{},e._l(e.missingConfigs,function(r){return t("li",{key:r,staticClass:"orange--text"},[t("code",[e._v(e._s(r))]),e._v(" "+e._s(e.$t("Panels.MinSettingsPanel.IsNotDefinedInConfig"))+" ")])}),0)])],1)],1),e.mainsailCfgExists?[t(I),t(Z,[t(x,[t(b,[t("p",{staticClass:"orange--text mb-0"},[e._v(e._s(e.$t("Panels.MinSettingsPanel.IncludeMainsailCfg")))])])],1)],1),t(I,{staticClass:"mb-2"})]:e._e(),t(oe,{staticClass:"justify-center pb-3"},[t(g,{attrs:{small:"",href:"https://docs.mainsail.xyz/setup/configuration",target:"_blank"}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiInformation))]),e._v(" "+e._s(e.$t("Panels.MinSettingsPanel.MoreInformation"))+" ")],1)],1)],2):e._e()},P6=[],D6=E(Qm,S6,P6,!1,null,"d51d0178");const yf=D6.exports;var T6=Object.defineProperty,O6=Object.getOwnPropertyDescriptor,Wb=(s,e,t,r)=>{for(var i=r>1?void 0:r?O6(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&T6(e,t,i),i};let Bl=class extends k(L){constructor(){super(...arguments),this.mdiFileMultiple=Ww}get sums(){const s={filamentLength:0,filamentWeight:0,estimatedTime:0};return this.jobs.forEach(e=>{var r,i,n,a,o,l,u,c;const t=((i=(r=e.combinedIds)==null?void 0:r.length)!=null?i:0)+1;s.filamentLength+=((a=(n=e.metadata)==null?void 0:n.filament_total)!=null?a:0)*t,s.filamentWeight+=((l=(o=e.metadata)==null?void 0:o.filament_weight_total)!=null?l:0)*t,s.estimatedTime+=((c=(u=e.metadata)==null?void 0:u.estimated_time)!=null?c:0)*t}),s}get count(){let s=0;return this.jobs.forEach(e=>{var t,r;s+=((r=(t=e.combinedIds)==null?void 0:t.length)!=null?r:0)+1}),s}get headline(){return this.$tc("Panels.StatusPanel.JobqueueMoreFiles",this.count,{count:this.count})}get description(){const s=[];let e="--";this.filamentLength&&s.push(this.filamentLength),this.filamentWeight&&s.push(this.filamentWeight),s.length&&(e=s.join(" / "));let t="--";return this.estimatedTime&&(t=this.estimatedTime),"".concat(this.$t("Panels.StatusPanel.Filament"),": ").concat(e,", ").concat(this.$t("Panels.StatusPanel.PrintTime"),": ").concat(t)}get filamentLength(){const s=this.sums.filamentLength;return s===0?null:s>=1e3?(s/1e3).toFixed(1)+" m":s.toFixed(0)+" mm"}get filamentWeight(){const s=this.sums.filamentWeight;return s===0?null:s>=1e3?(s/1e3).toFixed(1)+" kg":s.toFixed(0)+" g"}get estimatedTime(){let s=this.sums.estimatedTime;if(s==0)return"--";const e=[],t=Math.floor(s/(3600*24));t&&(s%=3600*24,e.push(t+"d"));const r=Math.floor(s/3600);s%=3600,r&&e.push(r+"h");const i=Math.floor(s/60);if(i&&e.push(i+"m"),r>0)return e.join(" ");const n=s%60;return n&&e.push(n.toFixed(0)+"s"),e.join(" ")}};Wb([w({type:Array,required:!0})],Bl.prototype,"jobs",2);Bl=Wb([S],Bl);var M6=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,{staticClass:"d-flex flex-row flex-nowrap"},[t(b,{staticClass:"col-auto d-flex flex-column justify-center pr-0 py-0"},[t(_,{staticStyle:{width:"32px"}},[e._v(e._s(e.mdiFileMultiple))])],1),t(b,{staticClass:"py-2",staticStyle:{"min-width":"0","font-size":"0.875em"}},[t("div",{staticClass:"text-truncate"},[e._v(e._s(e.headline))]),t("small",{staticClass:"text-truncate"},[e._v(e._s(e.description))])])],1)},k6=[],E6=E(Bl,M6,k6,!1,null,null);const L6=E6.exports;var A6=Object.defineProperty,F6=Object.getOwnPropertyDescriptor,Pu=(s,e,t,r)=>{for(var i=r>1?void 0:r?F6(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&A6(e,t,i),i};let Oi=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiChevronUp=du,this.mdiChevronDown=fr,this.mdiCounter=Y_,this.count=1,this.countInputRules=[s=>!!s||this.$t("JobQueue.InvalidCountEmpty"),s=>parseInt(s)>0||this.$t("JobQueue.InvalidCountGreaterZero")]}update(){this.$store.dispatch("server/jobQueue/changeCount",{job_id:this.job.job_id,count:this.count}),this.closeDialog()}closeDialog(){this.$emit("close")}showChanged(s){var e,t;s&&(this.count=((t=(e=this.job.combinedIds)==null?void 0:e.length)!=null?t:0)+1)}};Pu([w({type:Boolean,required:!0})],Oi.prototype,"show",2);Pu([w({type:Object,required:!0})],Oi.prototype,"job",2);Pu([he("show")],Oi.prototype,"showChanged",1);Oi=Pu([S({components:{Panel:U}})],Oi);var R6=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.show,"max-width":"400"}},[t(U,{attrs:{title:e.$t("JobQueue.ChangeCount"),icon:e.mdiCounter,"card-class":"jobqueue-change-count-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputFieldAddToQueueCount",attrs:{label:e.$t("JobQueue.Count"),required:"",rules:e.countInputRules,"hide-spin-buttons":"",type:"number"},on:{keyup:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"enter",13,r.key,"Enter")?null:e.update.apply(null,arguments)}},scopedSlots:e._u([{key:"append-outer",fn:function(){return[t("div",{staticClass:"_spin_button_group"},[t(g,{staticClass:"mt-n3",attrs:{icon:"",plain:"",small:""},on:{click:function(r){e.count++}}},[t(_,[e._v(e._s(e.mdiChevronUp))])],1),t(g,{staticClass:"mb-n3",attrs:{disabled:e.count<=1,icon:"",plain:"",small:""},on:{click:function(r){e.count--}}},[t(_,[e._v(e._s(e.mdiChevronDown))])],1)],1)]},proxy:!0}]),model:{value:e.count,callback:function(r){e.count=r},expression:"count"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:e.closeDialog}},[e._v(e._s(e.$t("JobQueue.Cancel")))]),t(g,{attrs:{color:"primary",text:""},on:{click:e.update}},[e._v(e._s(e.$t("JobQueue.ChangeCount")))])],1)],1)],1)},H6=[],j6=E(Oi,R6,H6,!1,null,null);const I6=j6.exports;var N6=Object.defineProperty,V6=Object.getOwnPropertyDescriptor,Du=(s,e,t,r)=>{for(var i=r>1?void 0:r?V6(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&N6(e,t,i),i};let Mi=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiCounter=Y_,this.mdiDragVertical=Wa,this.mdiFile=Bs,this.mdiPlay=nn,this.mdiPlaylistRemove=dS,this.showContextMenu=!1,this.contextMenuX=0,this.contextMenuY=0,this.showChangeCountDialog=!1}get smallThumbnail(){return this.$store.getters["server/jobQueue/getSmallThumbnail"](this.job)}get bigThumbnail(){return this.$store.getters["server/jobQueue/getBigThumbnail"](this.job)}get description(){var r,i;if(!((i=(r=this.job)==null?void 0:r.metadata)!=null&&i.metadataPulled))return!1;const s=[];let e="--";this.filamentLength&&s.push(this.filamentLength),this.filamentWeight&&s.push(this.filamentWeight),s.length&&(e=s.join(" / "));let t="--";return this.estimatedTime&&(t=this.estimatedTime),"".concat(this.$t("Panels.StatusPanel.Filament"),": ").concat(e,", ").concat(this.$t("Panels.StatusPanel.PrintTime"),": ").concat(t)}get filamentLength(){var e,t;const s=(t=(e=this.job.metadata)==null?void 0:e.filament_total)!=null?t:0;return s===0?null:s>=1e3?(s/1e3).toFixed(1)+" m":s.toFixed(0)+" mm"}get filamentWeight(){var e,t;const s=(t=(e=this.job.metadata)==null?void 0:e.filament_weight_total)!=null?t:0;return s===0?null:s>=1e3?(length/1e3).toFixed(1)+" kg":s.toFixed(0)+" g"}get estimatedTime(){var a,o;let s=(o=(a=this.job.metadata)==null?void 0:a.estimated_time)!=null?o:0;if(s==0)return"--";const e=[],t=Math.floor(s/(3600*24));t&&(s%=3600*24,e.push(t+"d"));const r=Math.floor(s/3600);s%=3600,r&&e.push(r+"h");const i=Math.floor(s/60);if(i&&e.push(i+"m"),r>0)return e.join(" ");const n=s%60;return n&&e.push(n.toFixed(0)+"s"),e.join(" ")}get bigThumbnailBackground(){var s;return(s=this.$store.state.gui.uiSettings.bigThumbnailBackground)!=null?s:At}get bigThumbnailTooltipColor(){if(At.toLowerCase()!==this.bigThumbnailBackground.toLowerCase())return this.bigThumbnailBackground}openContextMenu(s){if(s==null||s.preventDefault(),this.showContextMenu){this.showContextMenu=!1;return}this.showContextMenu=!0,this.contextMenuX=(s==null?void 0:s.clientX)||(s==null?void 0:s.pageX)||window.screenX/2,this.contextMenuY=(s==null?void 0:s.clientY)||(s==null?void 0:s.pageY)||window.screenY/2}printJob(){this.$store.dispatch("server/jobQueue/startByJobId",this.job.job_id)}startJobqueue(){this.$store.dispatch("server/jobQueue/start")}removeFromJobqueue(){var e;const s=[...(e=this.job.combinedIds)!=null?e:[],this.job.job_id];this.$store.dispatch("server/jobQueue/deleteFromQueue",s)}};Du([w({type:Object,required:!0})],Mi.prototype,"job",2);Du([w({type:Boolean,default:!1})],Mi.prototype,"showPrintButton",2);Du([w({type:Boolean,default:!1})],Mi.prototype,"showHandle",2);Mi=Du([S],Mi);var B6=function(){var r;var e=this,t=e._self._c;return e._self._setupProxy,t(x,{directives:[{name:"longpress",rawName:"v-longpress:600",value:i=>e.openContextMenu(i),expression:"(e) => openContextMenu(e)",arg:"600"}],staticClass:"jobqueue-list-entry d-flex flex-row flex-nowrap cursor-pointer",on:{contextmenu:function(i){return e.openContextMenu(i)}}},[e.showHandle?t(b,{staticClass:"col-auto d-flex flex-column justify-center pr-0 py-0"},[t(_,{staticClass:"handle"},[e._v(e._s(e.mdiDragVertical))])],1):e._e(),t(b,{staticClass:"col-auto d-flex flex-column justify-center pr-0 py-0"},[e.smallThumbnail?t(de,{attrs:{top:"",disabled:!e.bigThumbnail,"content-class":"tooltip__content-opacity1",color:e.bigThumbnailTooltipColor},scopedSlots:e._u([{key:"activator",fn:function({on:i,attrs:n}){return[t("vue-load-image",[t("img",e._g(e._b({attrs:{slot:"image",src:e.smallThumbnail,width:32,height:32,alt:e.job.filename},slot:"image"},"img",n,!1),i)),t("div",{attrs:{slot:"preloader"},slot:"preloader"},[t(ot,{attrs:{indeterminate:"",color:"primary"}})],1),t("div",{attrs:{slot:"error"},slot:"error"},[t(_,[e._v(e._s(e.mdiFile))])],1)])]}}],null,!1,2738555475)},[t("span",[t("img",{attrs:{src:e.bigThumbnail,width:250,alt:e.job.filename}})])]):t(_,[e._v(e._s(e.mdiFile))])],1),t(b,{staticClass:"py-1",staticStyle:{"min-width":"0","font-size":"0.875em"}},[t("div",{staticClass:"text-truncate"},[(r=e.job.combinedIds)!=null&&r.length?t("strong",[e._v(e._s(e.job.combinedIds.length+1)+"x")]):e._e(),e._v(" "+e._s(e.job.filename)+" ")]),e.description?t("small",{staticClass:"text-truncate"},[e._v(e._s(e.description))]):e._e()]),e.showPrintButton&&!e.printerIsPrinting?t(b,{staticClass:"col-auto d-flex flex-column justify-center pa-0 pr-1"},[t(g,{staticClass:"minwidth-0",attrs:{icon:"",color:"success"},on:{click:e.startJobqueue}},[t(_,[e._v(e._s(e.mdiPlay))])],1)],1):e._e(),t(ye,{attrs:{"position-x":e.contextMenuX,"position-y":e.contextMenuY,absolute:"","offset-y":""},model:{value:e.showContextMenu,callback:function(i){e.showContextMenu=i},expression:"showContextMenu"}},[t(Me,[t(J,{on:{click:e.printJob}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPlay))]),e._v(" "+e._s(e.$t("JobQueue.StartPrint"))+" ")],1),t(J,{on:{click:function(i){e.showChangeCountDialog=!0}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiCounter))]),e._v(" "+e._s(e.$t("JobQueue.ChangeCount"))+" ")],1),t(J,{on:{click:e.removeFromJobqueue}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPlaylistRemove))]),e._v(" "+e._s(e.$t("JobQueue.RemoveFromQueue"))+" ")],1)],1)],1),t(I6,{attrs:{show:e.showChangeCountDialog,job:e.job},on:{close:function(i){e.showChangeCountDialog=!1}}})],1)},U6=[],W6=E(Mi,B6,U6,!1,null,null);const Tu=W6.exports;var z6=Object.getOwnPropertyDescriptor,G6=(s,e,t,r)=>{for(var i=r>1?void 0:r?z6(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let eh=class extends k(L){get jobs(){var e;return(e=this.$store.getters["server/jobQueue/getJobs"])!=null?e:[]}get maxLength(){return this.jobs.length>5?4:5}get jobsTable(){return this.jobs.slice(0,this.maxLength)}get jobsRest(){return this.jobs.slice(this.maxLength)}startJobqueue(){this.$store.dispatch("server/jobQueue/start")}};eh=G6([S({components:{JobqueueEntry:Tu}})],eh);var Z6=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{staticClass:"filesJobqueue",attrs:{flat:""}},[e.jobs.length?[t(x,{staticClass:"mx-0 mt-0 pb-3"},[t(b,{staticClass:"jobqueue-list"},[e._l(e.jobsTable,function(r,i){return t(Tu,{key:r.job_id,attrs:{job:r,"show-handle":!1,"show-print-button":i===0}})}),e.jobsRest.length?t(L6,{attrs:{jobs:e.jobsRest}}):e._e()],2)],1)]:t("div",[t("p",{staticClass:"body-2 my-3 text-center text--disabled"},[e._v(e._s(e.$t("Panels.StatusPanel.EmptyJobqueue")))])])],2)},q6=[],X6=E(eh,Z6,q6,!1,null,"0b5b1a36");const zb=X6.exports;var Y6=Object.defineProperty,J6=Object.getOwnPropertyDescriptor,ro=(s,e,t,r)=>{for(var i=r>1?void 0:r?J6(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&Y6(e,t,i),i};let Wr=class extends k(L){constructor(){super(...arguments),this.mdiChevronDown=fr,this.mdiChevronUp=du,this.mdiPlaylistPlus=Za,this.mdiCloseThick=pe,this.isValid=!1,this.input="1",this.rules={count:[s=>!!s||this.$t("JobQueue.InvalidCountEmpty"),s=>parseInt(s,10)>0||this.$t("JobQueue.InvalidCountGreaterZero")]}}async addBatchToQueueAction(){const s=Array(parseInt(this.input)).fill(this.filename);await this.$store.dispatch("server/jobQueue/addToQueue",s),this.showToast&&this.$toast.info(this.$t("History.AddToQueueSuccessful",{filename:this.filename}).toString()),this.closeDialog()}closeDialog(){this.$emit("close")}resetFormState(){this.input="1"}isVisibleChanged(s){s&&this.resetFormState()}};ro([w({type:Boolean,default:!1})],Wr.prototype,"isVisible",2);ro([w({type:Boolean,default:!1})],Wr.prototype,"showToast",2);ro([w({type:String,required:!0})],Wr.prototype,"filename",2);ro([he("isVisible")],Wr.prototype,"isVisibleChanged",1);Wr=ro([S],Wr);var K6=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.isVisible,"max-width":400},on:{"click:outside":e.closeDialog,keydown:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"esc",27,r.key,["Esc","Escape"])?null:e.closeDialog.apply(null,arguments)}}},[t(U,{attrs:{title:e.$t("Files.AddToQueue"),"card-class":"gcode-files-add-to-queue-dialog",icon:e.mdiPlaylistPlus,"margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(or,{on:{submit:function(r){return r.preventDefault(),e.addBatchToQueueAction.apply(null,arguments)}},model:{value:e.isValid,callback:function(r){e.isValid=r},expression:"isValid"}},[t(Z,[t(se,{ref:"inputFieldAddToQueueCount",attrs:{label:e.$t("Files.Count"),required:"","hide-spin-buttons":"",type:"number",rules:e.rules.count},scopedSlots:e._u([{key:"append-outer",fn:function(){return[t("div",{staticClass:"_spin_button_group"},[t(g,{staticClass:"mt-n3",attrs:{icon:"",plain:"",small:""},on:{click:function(r){e.input++}}},[t(_,[e._v(e._s(e.mdiChevronUp))])],1),t(g,{staticClass:"mb-n3",attrs:{disabled:e.input<=1,icon:"",plain:"",small:""},on:{click:function(r){e.input--}}},[t(_,[e._v(e._s(e.mdiChevronDown))])],1)],1)]},proxy:!0}]),model:{value:e.input,callback:function(r){e.input=r},expression:"input"}})],1),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.closeDialog}},[e._v(e._s(e.$t("Files.Cancel")))]),t(g,{attrs:{color:"primary",text:"",type:"submit",disabled:!e.isValid}},[e._v(" "+e._s(e.$t("Files.AddToQueue"))+" ")])],1)],1)],1)],1)},Q6=[],ek=E(Wr,K6,Q6,!1,null,"85d0eee1");const ri=ek.exports;var tk=Object.defineProperty,sk=Object.getOwnPropertyDescriptor,Gb=(s,e,t,r)=>{for(var i=r>1?void 0:r?sk(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&tk(e,t,i),i};let Ul=class extends k(L){get styleCircle1(){return{fill:this.color}}get styleCircle2(){return{fill:"#bebebe"}}get styleCircle3(){return{fill:"#343434"}}clickSpool(){this.$emit("click-spool")}};Gb([w({required:!1,default:"#ff0"})],Ul.prototype,"color",2);Ul=Gb([S({})],Ul);var rk=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("svg",{staticClass:"cursor-pointer",attrs:{version:"1.1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",x:"0px",y:"0px",viewBox:"0 0 487.04 487.04","xml:space":"preserve"},on:{click:e.clickSpool}},[t("g",[t("circle",{style:e.styleCircle1,attrs:{cx:"243.52",cy:"243.52",r:"232.97"}}),t("circle",{style:e.styleCircle2,attrs:{cx:"243.52",cy:"243.52",r:"112.5"}}),t("path",{style:e.styleCircle3,attrs:{d:"M0,243.52c0,134.42,109.1,243.52,243.52,243.52,134.42,0,243.52-109.1,243.52-243.52S377.95,0,243.52,0C109.1,0,0,109.1,0,243.52Zm115.73,181.78c-52.4-39.5-86.52-98.59-94.52-163.72v-.09c-.68-5.43,1-10.89,4.6-15,3.6-4.12,8.79-6.51,14.26-6.57l118.36-1.33c18.99-.21,36.63,9.83,46.12,26.29,9.5,16.45,9.38,36.74-.3,53.09l-60.29,101.76c-2.8,4.73-7.48,8.03-12.87,9.1-5.39,1.06-10.98-.22-15.36-3.52ZM450.22,238.8c5.49,.06,10.7,2.46,14.31,6.59,3.62,4.13,5.3,9.61,4.63,15.06-8.01,65.13-42.12,124.22-94.52,163.72l-.07,.05c-4.37,3.29-9.93,4.57-15.3,3.51-5.37-1.06-10.03-4.36-12.82-9.06l-60.33-101.84c-9.68-16.34-9.8-36.64-.3-53.09,9.5-16.45,27.13-26.5,46.12-26.29l118.27,1.33ZM338.12,40.02c5.04,2.14,8.92,6.32,10.69,11.49,1.77,5.18,1.24,10.86-1.44,15.63l-58.03,103.17c-9.31,16.56-26.83,26.8-45.83,26.8-19,0-36.51-10.25-45.83-26.8l-57.99-103.09c-2.69-4.79-3.22-10.49-1.45-15.69,1.77-5.2,5.68-9.4,10.73-11.54,60.41-25.63,128.64-25.63,189.05,0l.08,.04Z"}})])])},ik=[],nk=E(Ul,rk,ik,!1,null,null);const Zb=nk.exports;var ak=Object.defineProperty,ok=Object.getOwnPropertyDescriptor,Cf=(s,e,t,r)=>{for(var i=r>1?void 0:r?ok(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&ak(e,t,i),i};let ma=class extends k(L){get color(){var e,t;const s=(t=(e=this.spool.filament)==null?void 0:e.color_hex)!=null?t:"000";return"#".concat(s)}get id(){let s=this.spool.id.toString();for(;s.length<this.max_id_digits;)s="0"+s;return s}get vendor(){var s,e,t;return(t=(e=(s=this.spool.filament)==null?void 0:s.vendor)==null?void 0:e.name)!=null?t:"Unknown"}get name(){var s,e;return(e=(s=this.spool.filament)==null?void 0:s.name)!=null?e:"Unknown"}get location(){return this.spool.location}get material(){var s,e;return(e=(s=this.spool.filament)==null?void 0:s.material)!=null?e:"--"}get remaining_weight(){var s;return(s=this.spool.remaining_weight)!=null?s:0}get total_weight(){var s,e;return(e=(s=this.spool.filament)==null?void 0:s.weight)!=null?e:0}get remaining_weight_format(){return"".concat(this.remaining_weight.toFixed(0),"g")}get total_weight_format(){if(this.total_weight<1e3)return"".concat(this.total_weight.toFixed(0),"g");let s=Math.round(this.total_weight/1e3);return s!==this.total_weight/1e3&&(s=Math.round(this.total_weight/100)/10),"".concat(s,"kg")}get last_used(){var i;if(!((i=this.spool.last_used)!=null?i:null))return this.$t("Panels.SpoolmanPanel.Never");const e=new Date(this.spool.last_used),r=new Date().getTime()-e.getTime();if(r<=1e3*60*60*24)return this.$t("Panels.SpoolmanPanel.Today");if(r<=1e3*60*60*24*2)return this.$t("Panels.SpoolmanPanel.Yesterday");if(r<=1e3*60*60*24*14){const n=Math.floor(r/864e5);return this.$t("Panels.SpoolmanPanel.DaysAgo",{days:n})}return e.toLocaleDateString()}setSpoolRow(){this.$emit("set-spool",this.spool)}};Cf([w({required:!0})],ma.prototype,"spool",2);Cf([w({required:!1})],ma.prototype,"max_id_digits",2);ma=Cf([S({})],ma);var lk=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("tr",{staticClass:"cursor-pointer",on:{click:e.setSpoolRow}},[t("td",{staticClass:"pr-0 py-2",staticStyle:{width:"50px"}},[t(Zb,{staticClass:"mr-3",staticStyle:{width:"50px",float:"left"},attrs:{color:e.color}})],1),t("td",{staticClass:"py-2",staticStyle:{"min-width":"300px"}},[t(J,{attrs:{"two-line":""}},[t(_t,{staticClass:"no--padding"},[t("div",{staticClass:"text--disabled mb-1"},[e._v("#"+e._s(e.id)+" | "+e._s(e.vendor))]),t(Ze,{staticClass:"mb-1"},[t("span",{staticClass:"text--filament"},[e._v(e._s(e.name))]),e.location?[t("br"),t("small",[e._v(e._s(e.$t("Panels.SpoolmanPanel.Location"))+": "+e._s(e.location))])]:e._e(),e.spool.comment?[t("br"),t("small",{staticClass:"comment"},[e._v(e._s(e.spool.comment))])]:e._e()],2)],1)],1)],1),t("td",{staticClass:"text-center text-no-wrap"},[e._v(e._s(e.material))]),t("td",{staticClass:"text-right text-no-wrap"},[e._v(e._s(e.last_used))]),t("td",{staticClass:"text-right text-no-wrap"},[t("strong",[e._v(e._s(e.remaining_weight_format))]),t("small",{staticClass:"ml-1"},[e._v("/ "+e._s(e.total_weight_format))])])])},ck=[],uk=E(ma,lk,ck,!1,null,"23996042");const qb=uk.exports;var dk=Object.defineProperty,mk=Object.getOwnPropertyDescriptor,Ou=(s,e,t,r)=>{for(var i=r>1?void 0:r?mk(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&dk(e,t,i),i};let ki=class extends k(L){constructor(){super(...arguments),this.mdiAdjust=tn,this.mdiCloseThick=pe,this.mdiDatabase=Fw,this.mdiMagnify=rn,this.mdiRefresh=an,this.search=""}get spools(){var s;return(s=this.$store.state.server.spoolman.spools)!=null?s:[]}get max_spool_id_digits(){return this.$store.state.server.spoolman.spools.reduce((e,t)=>Math.max(e,t.id),0).toString().length}get headers(){return[{text:" ",align:"start",sortable:!1},{text:this.$t("Panels.SpoolmanPanel.Filament"),align:"start",value:"filament.name",sortable:!1},{text:this.$t("Panels.SpoolmanPanel.Material"),align:"center",value:"filament.material"},{text:this.$t("Panels.SpoolmanPanel.LastUsed"),align:"end",value:"last_used"},{text:this.$t("Panels.SpoolmanPanel.Weight"),align:"end",value:"remaining_weight"}]}get spoolManagerUrl(){var s,e,t;return(t=(e=(s=this.$store.state.server.config.config)==null?void 0:s.spoolman)==null?void 0:e.server)!=null?t:null}get existsSaveVariables(){var e,t;return"save_variables"in((t=(e=this.$store.state.printer.configfile)==null?void 0:e.settings)!=null?t:{})}openSpoolManager(){window.open(this.spoolManagerUrl,"_blank")}mounted(){this.refresh()}refresh(){this.$store.dispatch("server/spoolman/refreshSpools")}close(){this.$emit("close")}refreshSpools(){this.$store.dispatch("server/spoolman/refreshSpools")}customFilter(s,e,t){var n;if(e.trim().startsWith("web+spoolman:s-")){const a=parseInt((n=e.split("-")[1])!=null?n:-1);return t.id===a}const r=e.toLowerCase().split(" "),i=[t.id.toString(),t.comment,t.filament.name,t.filament.vendor.name,t.filament.material,t.location];for(const a of r)if(!i.some(l=>l==null?void 0:l.toLowerCase().includes(a)))return!1;return!0}setSpool(s){if(this.$store.dispatch("server/spoolman/setActiveSpool",s.id),!this.tool){this.close();return}const e="SET_GCODE_VARIABLE MACRO=".concat(this.tool," VARIABLE=spool_id VALUE=").concat(s.id);if(this.$store.dispatch("server/addEvent",{message:e,type:"command"}),this.$socket.emit("printer.gcode.script",{script:e}),!this.existsSaveVariables){this.close();return}const t="SAVE_VARIABLE VARIABLE=".concat(this.tool.toLowerCase(),"__spool_id VALUE=").concat(s.id);this.$store.dispatch("server/addEvent",{message:t,type:"command"}),this.$socket.emit("printer.gcode.script",{script:t}),this.close()}onShowDialogChanged(s){s&&(this.search="")}};Ou([w({required:!0})],ki.prototype,"showDialog",2);Ou([w({required:!1,default:null})],ki.prototype,"tool",2);Ou([he("showDialog")],ki.prototype,"onShowDialogChanged",1);ki=Ou([S({components:{SpoolmanChangeSpoolDialogRow:qb,Panel:U}})],ki);var hk=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(le,{attrs:{width:"800",persistent:"",fullscreen:e.isMobile},model:{value:e.showDialog,callback:function(r){e.showDialog=r},expression:"showDialog"}},[t(U,{attrs:{title:e.$t("Panels.SpoolmanPanel.ChangeSpool"),icon:e.mdiAdjust,"card-class":"spoolman-change-spool-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.close}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(gt,[t(se,{staticStyle:{"max-width":"300px"},attrs:{"append-icon":e.mdiMagnify,label:e.$t("Panels.SpoolmanPanel.Search"),outlined:"",dense:"","hide-details":""},model:{value:e.search,callback:function(r){e.search=r},expression:"search"}}),t(ae),t(g,{staticClass:"px-2 minwidth-0 ml-3",attrs:{title:e.$t("Panels.SpoolmanPanel.Refresh"),loading:e.loadings.includes("refreshSpools")},on:{click:e.refreshSpools}},[t(_,[e._v(e._s(e.mdiRefresh))])],1),t(g,{staticClass:"px-2 minwidth-0 ml-3",attrs:{title:e.$t("Panels.SpoolmanPanel.OpenSpoolManager")},on:{click:e.openSpoolManager}},[t(_,[e._v(e._s(e.mdiDatabase))])],1)],1),t(Z,{staticClass:"px-0 pb-0"},[t(Qr,{attrs:{headers:e.headers,items:e.spools,"item-key":"id",search:e.search,"sort-by":"last_used","sort-desc":!0,"custom-filter":e.customFilter},scopedSlots:e._u([{key:"no-data",fn:function(){return[t("div",{staticClass:"text-center"},[e._v(e._s(e.$t("Panels.SpoolmanPanel.NoSpools")))])]},proxy:!0},{key:"no-results",fn:function(){return[t("div",{staticClass:"text-center"},[e._v(e._s(e.$t("Panels.SpoolmanPanel.NoResults")))])]},proxy:!0},{key:"item",fn:function({item:r}){return[t(qb,{key:r.id,attrs:{spool:r,max_id_digits:e.max_spool_id_digits},on:{"set-spool":e.setSpool}})]}}])})],1)],1)],1)],1)},pk=[],fk=E(ki,hk,pk,!1,null,null);const cn=fk.exports;var gk=Object.defineProperty,_k=Object.getOwnPropertyDescriptor,Xb=(s,e,t,r)=>{for(var i=r>1?void 0:r?_k(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&gk(e,t,i),i};let Wl=class extends k(L){constructor(){super(...arguments),this.mdiEject=Q_,this.mdiCloseThick=pe}close(){this.$emit("close")}removeSpool(){this.$store.dispatch("server/spoolman/setActiveSpool",null),this.close()}};Xb([w({required:!0})],Wl.prototype,"showDialog",2);Wl=Xb([S({components:{Panel:U}})],Wl);var vk=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{width:"400",persistent:"",fullscreen:e.isMobile},model:{value:e.showDialog,callback:function(r){e.showDialog=r},expression:"showDialog"}},[t(U,{attrs:{title:e.$t("Panels.SpoolmanPanel.EjectSpool"),icon:e.mdiEject,"card-class":"spoolman-eject-spool-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.close}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(x,[t(b,[t("p",{staticClass:"body-2"},[e._v(e._s(e.$t("Panels.SpoolmanPanel.EjectSpoolQuestion")))])])],1)],1),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.close}},[e._v(e._s(e.$t("Panels.SpoolmanPanel.Cancel")))]),t(g,{attrs:{color:"primary",text:""},on:{click:e.removeSpool}},[e._v(" "+e._s(e.$t("Panels.SpoolmanPanel.EjectSpool"))+" ")])],1)],1)],1)},bk=[],yk=E(Wl,vk,bk,!1,null,null);const $f=yk.exports;var Ck=Object.defineProperty,$k=Object.getOwnPropertyDescriptor,Yb=(s,e,t,r)=>{for(var i=r>1?void 0:r?$k(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&Ck(e,t,i),i};let zl=class extends k(L){get listItemContentClass(){return this.small?"my-0":""}get overlineClass(){const s=["text-overline","mb-1"];return this.small&&s.push("line-height-auto"),s}get listItemTitleClass(){return this.small?["text-h6","mb-1"]:["text-h5","mb-1"]}get avatarSize(){return this.small?60:80}get active_spool(){var s;return(s=this.$store.state.server.spoolman.active_spool)!=null?s:null}get color(){var e,t;const s=(t=(e=this.active_spool)==null?void 0:e.filament.color_hex)!=null?t:null;return s===null?"#000":"#".concat(s)}get id(){var s,e;return(e=(s=this.active_spool)==null?void 0:s.id)!=null?e:"XX"}get vendor(){var s,e,t,r;return(r=(t=(e=(s=this.active_spool)==null?void 0:s.filament)==null?void 0:e.vendor)==null?void 0:t.name)!=null?r:"Unknown"}get name(){var s,e;return(e=(s=this.active_spool)==null?void 0:s.filament.name)!=null?e:"Unknown"}get materialOutput(){var e,t;const s=(t=(e=this.active_spool)==null?void 0:e.filament.material)!=null?t:null;return s===null?null:s}get weightOutput(){var i,n,a,o;let s=(n=(i=this.active_spool)==null?void 0:i.remaining_weight)!=null?n:null,e=(o=(a=this.active_spool)==null?void 0:a.filament.weight)!=null?o:null,t="g";if(s===null||e===null)return null;s=Math.round(s);let r=Math.floor(e/1e3);return e>=1e3?(r!==e/1e3&&(r=Math.round(e/100)/10),"".concat(s,"g / ").concat(r,"kg")):"".concat(s," / ").concat(e).concat(t)}get lengthOutput(){var e,t;let s=(t=(e=this.active_spool)==null?void 0:e.remaining_length)!=null?t:null;return s===null?null:(s=Math.round(s/1e3),"".concat(s,"m"))}get subtitle(){return[this.materialOutput,this.weightOutput,this.lengthOutput].filter(s=>s!==null).join(" | ")}clickSpool(){this.$emit("change-spool")}};Yb([w({required:!1,default:!1})],zl.prototype,"small",2);zl=Yb([S({components:{Panel:U,SpoolmanChangeSpoolDialog:cn,SpoolmanEjectSpoolDialog:$f}})],zl);var xk=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(J,{attrs:{"three-line":""}},[t(_t,{class:e.listItemContentClass},[t("div",{class:e.overlineClass},[e._v("#"+e._s(e.id)+" | "+e._s(e.vendor))]),t(Ze,{class:e.listItemTitleClass},[t("span",{staticClass:"cursor-pointer",on:{click:e.clickSpool}},[e._v(e._s(e.name))])]),t(Va,[e._v(e._s(e.subtitle))])],1),t(O$,{attrs:{tile:"",size:e.avatarSize}},[t(Zb,{attrs:{color:e.color},on:{"click-spool":e.clickSpool}})],1)],1)},wk=[],Sk=E(zl,xk,wk,!1,null,"5b0a993e");const Mu=Sk.exports;var Pk=Object.defineProperty,Dk=Object.getOwnPropertyDescriptor,Jb=(s,e,t,r)=>{for(var i=r>1?void 0:r?Dk(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&Pk(e,t,i),i};let Gl=class extends k(L){constructor(){super(...arguments),this.showChangeSpoolDialog=!1}get activeSpoolId(){var e,t;let s=(t=(e=this.$store.state.server.spoolman)==null?void 0:e.active_spool_id)!=null?t:null;return s===0&&(s=null),s}get activeSpool(){var s,e;return(e=(s=this.$store.state.server.spoolman)==null?void 0:s.active_spool)!=null?e:null}get classSecondDivider(){const s=["mt-4"];return s.push(this.moonrakerComponents.includes("timelapse")?"mb-2":"mb-0"),s}get buttonText(){return this.activeSpoolId===null?this.$t("Panels.SpoolmanPanel.SelectSpool"):this.$t("Panels.SpoolmanPanel.ChangeSpool")}get alerts(){var i,n,a,o,l,u,c,d,m;let s=[];if(this.activeSpoolId===null)return s.push({text:this.$t("Panels.SpoolmanPanel.NoSpoolSelected"),color:"orange"}),s;let e=(i=this.file.filament_type)!=null?i:"";e.includes(";")&&(e=e.split(";")[0]),e!==""&&((o=(a=(n=this.activeSpool)==null?void 0:n.filament)==null?void 0:a.material)==null?void 0:o.toLowerCase())!==e.toLowerCase()&&s.push({text:this.$t("Panels.SpoolmanPanel.FilamentTypeMismatch",{fileType:e,spoolType:(u=(l=this.activeSpool)==null?void 0:l.filament)==null?void 0:u.material}),color:"warning"});const t=Math.round((c=this.file.filament_weight_total)!=null?c:0),r=Math.round((m=(d=this.activeSpool)==null?void 0:d.remaining_weight)!=null?m:0);return r<t&&s.push({text:this.$t("Panels.SpoolmanPanel.TooLessFilament",{fileWeight:t,spoolWeight:r}),color:"warning"}),s}};Jb([w({required:!0})],Gl.prototype,"file",2);Gl=Jb([S({components:{SpoolmanPanelActiveSpool:Mu}})],Gl);var Tk=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(I,{staticClass:"mt-3 mb-0"}),t(Z,{staticClass:"py-0 px-2"},[e.activeSpoolId!==null?t(Mu,{staticClass:"my-0",attrs:{small:!0},on:{"change-spool":function(r){e.showChangeSpoolDialog=!0}}}):e._e(),e._l(e.alerts,function(r){return t(it,{key:r.text,staticClass:"mt-4 mx-3",attrs:{text:"",color:r.color}},[e._v(" "+e._s(r.text)+" ")])}),t("div",{staticClass:"text-center"},[t(g,{staticClass:"mx-auto",attrs:{color:"primary",small:""},on:{click:function(r){e.showChangeSpoolDialog=!0}}},[e._v(" "+e._s(e.buttonText)+" ")])],1)],2),t(I,{class:e.classSecondDivider}),t(cn,{attrs:{"show-dialog":e.showChangeSpoolDialog},on:{close:function(r){e.showChangeSpoolDialog=!1}}})],1)},Ok=[],Mk=E(Gl,Tk,Ok,!1,null,null);const kk=Mk.exports;var Ek=Object.defineProperty,Lk=Object.getOwnPropertyDescriptor,ku=(s,e,t,r)=>{for(var i=r>1?void 0:r?Lk(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&Ek(e,t,i),i};let Ei=class extends k(L){constructor(){super(...arguments),this.mdiPrinter3d=qa}get timelapseEnabled(){var s,e,t;return(t=(e=(s=this.$store.state.server.timelapse)==null?void 0:s.settings)==null?void 0:e.enabled)!=null?t:!1}set timelapseEnabled(s){this.$socket.emit("machine.timelapse.post_settings",{enabled:s},{action:"server/timelapse/initSettings"})}get bigThumbnailBackground(){var s;return(s=this.$store.state.gui.uiSettings.bigThumbnailBackground)!=null?s:At}get bigThumbnailStyle(){return At.toLowerCase()===this.bigThumbnailBackground.toLowerCase()?{}:{backgroundColor:this.bigThumbnailBackground}}get active_spool(){var s;return(s=this.$store.state.server.spoolman.active_spool)!=null?s:null}get filamentVendor(){var s,e,t,r;return(r=(t=(e=(s=this.active_spool)==null?void 0:s.filament)==null?void 0:e.vendor)==null?void 0:t.name)!=null?r:"Unknown"}get filamentName(){var s,e;return(e=(s=this.active_spool)==null?void 0:s.filament.name)!=null?e:"Unknown"}get filament(){return"".concat(this.filamentVendor," - ").concat(this.filamentName)}get question(){var s,e,t,r;return this.active_spool?this.$t("Dialogs.StartPrint.DoYouWantToStartFilenameFilament",{filename:(e=(s=this.file)==null?void 0:s.filename)!=null?e:"unknown"}):this.$t("Dialogs.StartPrint.DoYouWantToStartFilename",{filename:(r=(t=this.file)==null?void 0:t.filename)!=null?r:"unknown"})}get maxThumbnailWidth(){var s,e;return(e=(s=this.file)==null?void 0:s.big_thumbnail_width)!=null?e:400}startPrint(s=""){s=(this.currentPath+"/"+s).substring(1),this.closeDialog(),this.$socket.emit("printer.print.start",{filename:s},{action:"switchToDashboard"})}closeDialog(){this.$emit("closeDialog")}};ku([w({required:!0,default:!1})],Ei.prototype,"bool",2);ku([w({required:!0,default:""})],Ei.prototype,"currentPath",2);ku([w({required:!0})],Ei.prototype,"file",2);Ei=ku([S({components:{SettingsRow:j}})],Ei);var Ak=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{"max-width":400,"content-class":"overflow-x-hidden"},on:{"click:outside":e.closeDialog,keydown:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"esc",27,r.key,["Esc","Escape"])?null:e.closeDialog.apply(null,arguments)}},model:{value:e.bool,callback:function(r){e.bool=r},expression:"bool"}},[t(Pe,[e.file.big_thumbnail?t("div",{staticClass:"d-flex align-center justify-center",staticStyle:{"min-height":"200px"}},[t(nu,{staticClass:"d-inline-block",style:e.bigThumbnailStyle,attrs:{src:e.file.big_thumbnail,"max-width":e.maxThumbnailWidth}})],1):e._e(),t(gt,{staticClass:"text-h5"},[e._v(e._s(e.$t("Dialogs.StartPrint.Headline")))]),t(Z,{staticClass:"pb-0"},[t("p",{staticClass:"body-2"},[e._v(" "+e._s(e.question)+" ")])]),e.moonrakerComponents.includes("spoolman")?t(kk,{attrs:{file:e.file}}):e._e(),e.moonrakerComponents.includes("timelapse")?[e.moonrakerComponents.includes("spoolman")?e._e():t(I,{staticClass:"mt-3 mb-2"}),t(Z,{staticClass:"py-0"},[t(j,{attrs:{title:e.$t("Dialogs.StartPrint.Timelapse")}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.timelapseEnabled,callback:function(r){e.timelapseEnabled=r},expression:"timelapseEnabled"}})],1)],1),t(I,{staticClass:"mt-2 mb-0"})]:e._e(),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.closeDialog}},[e._v(e._s(e.$t("Dialogs.StartPrint.Cancel")))]),t(g,{attrs:{color:"primary",text:"",disabled:e.printerIsPrinting||!e.klipperReadyForGui},on:{click:function(r){return e.startPrint(e.file.filename)}}},[e._v(" "+e._s(e.$t("Dialogs.StartPrint.Print"))+" ")])],1)],2)],1)},Fk=[],Rk=E(Ei,Ak,Fk,!1,null,null);const Eu=Rk.exports;var Hk=Object.defineProperty,jk=Object.getOwnPropertyDescriptor,xf=(s,e,t,r)=>{for(var i=r>1?void 0:r?jk(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&Hk(e,t,i),i};let ha=class extends k(L,Je){constructor(){super(...arguments),this.mdiFile=Bs,this.mdiPlay=nn,this.mdiPlaylistPlus=Za,this.mdiFire=sn,this.mdiVideo3d=yu,this.mdiCloudDownload=Kn,this.mdiFileDocumentEditOutline=za,this.mdiRenameBox=vu,this.mdiDelete=Ue,this.mdiCloseThick=pe,this.currentPath="",this.contextMenuShow=!1,this.contextMenuX=0,this.contextMenuY=0,this.showPrintDialog=!1,this.showAddBatchToQueueDialog=!1,this.showRenameFileDialog=!1,this.renameFileNewName="",this.showDeleteDialog=!1}get styleContentTdWidth(){return"width: ".concat(this.contentTdWidth,"px;")}get bigThumbnailBackground(){var e;return(e=this.$store.state.gui.uiSettings.bigThumbnailBackground)!=null?e:At}get bigThumbnailTooltipColor(){if(At.toLowerCase()!==this.bigThumbnailBackground.toLowerCase())return this.bigThumbnailBackground}get existsMetadata(){var e,t;return(t=(e=this.item)==null?void 0:e.metadataPulled)!=null?t:!1}get description(){const e=[];let t="--";(this.item.filament_total||this.item.filament_weight_total)&&(t="",this.item.filament_total&&this.item.filament_total>1e3?t+="".concat((this.item.filament_total/1e3).toFixed(2)," m"):this.item.filament_total&&(t+="".concat(this.item.filament_total.toFixed(0)," mm")),this.item.filament_total&&this.item.filament_weight_total&&(t+=" / "),this.item.filament_weight_total&&(t+=this.item.filament_weight_total.toFixed(0)+" g")),e.push("".concat(this.$t("Panels.StatusPanel.Filament"),": ").concat(t));const r=this.item.estimated_time?Is(this.item.estimated_time):"--";return e.push("".concat(this.$t("Panels.StatusPanel.PrintTime"),": ").concat(r)),e.join(", ")}get statusIcon(){return this.$store.getters["server/history/getPrintStatusIcon"](this.item.last_status)}get statusColor(){return this.$store.getters["server/history/getPrintStatusIconColor"](this.item.last_status)}get pathOfFile(){return this.item.filename.lastIndexOf("/")>=0?"/"+this.item.filename.slice(0,this.item.filename.lastIndexOf("/")):""}get filename(){return this.item.filename.slice(this.item.filename.lastIndexOf("/")+1)}showContextMenu(e){this.contextMenuShow||(e==null||e.preventDefault(),this.contextMenuX=(e==null?void 0:e.clientX)||(e==null?void 0:e.pageX)||window.screenX/2,this.contextMenuY=(e==null?void 0:e.clientY)||(e==null?void 0:e.pageY)||window.screenY/2,this.$nextTick(()=>{this.contextMenuShow=!0}))}addToQueue(){this.$store.dispatch("server/jobQueue/addToQueue",[this.item.filename])}view3D(){this.$router.push({path:"/viewer",query:{filename:"gcodes/"+this.item.filename}})}downloadFile(){const e=this.apiUrl+"/server/files/gcodes/"+Ie(this.item.filename);window.open(e)}renameFile(){this.showRenameFileDialog=!1,this.$socket.emit("server.files.move",{source:"gcodes/"+this.item.filename,dest:"gcodes/"+this.pathOfFile+this.renameFileNewName},{action:"files/getMove"})}editFile(){const e=this.item.filename.lastIndexOf("/"),t=e>0?this.item.filename.slice(0,e+1):"",r=e>0?this.item.filename.slice(e+1):this.item.filename;this.$store.dispatch("editor/openFile",{root:"gcodes",path:t,filename:r,size:this.item.size,permissions:this.item.permissions})}removeFile(){this.$socket.emit("server.files.delete_file",{path:"gcodes/"+this.item.filename},{action:"files/getDeleteFile"}),this.showDeleteDialog=!1}mounted(){this.renameFileNewName=this.filename}};xf([w({type:Object,required:!0})],ha.prototype,"item",2);xf([w({type:Number,required:!0})],ha.prototype,"contentTdWidth",2);ha=xf([S({components:{Panel:U,StartPrintDialog:Eu,AddBatchToQueueDialog:ri}})],ha);var Ik=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("tr",{directives:[{name:"longpress",rawName:"v-longpress:600",value:r=>e.showContextMenu(r),expression:"(e) => showContextMenu(e)",arg:"600"}],staticClass:"cursor-pointer",on:{contextmenu:function(r){return e.showContextMenu(r)},click:function(r){e.showPrintDialog=!0}}},[t("td",{staticClass:"pr-0 text-center",staticStyle:{width:"32px"}},[e.item.small_thumbnail?[t(de,{attrs:{top:"","content-class":"tooltip__content-opacity1",disabled:!e.item.big_thumbnail,color:e.bigThumbnailTooltipColor},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("vue-load-image",{staticClass:"d-flex"},[t("img",e._g(e._b({attrs:{slot:"image",src:e.item.small_thumbnail,alt:e.item.filename,width:"32",height:"32"},slot:"image"},"img",i,!1),r)),t("div",{attrs:{slot:"preloader"},slot:"preloader"},[t(ot,{attrs:{indeterminate:"",color:"primary"}})],1),t("div",{attrs:{slot:"error"},slot:"error"},[t(_,[e._v(e._s(e.mdiFile))])],1)])]}}],null,!1,2095430365)},[t("span",[t("img",{attrs:{src:e.item.big_thumbnail,alt:e.item.filename,width:"250"}})])])]:[t(_,[e._v(e._s(e.mdiFile))])]],2),t("td",{staticClass:"pr-2"},[t("div",{staticClass:"d-block text-truncate",style:e.styleContentTdWidth},[e._v(e._s(e.item.filename))]),e.existsMetadata?t("small",[e._v(e._s(e.description))]):e._e()]),t("td",[e.item.last_status?t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("span",e._g(e._b({},"span",i,!1),r),[t(_,{attrs:{small:"",color:e.statusColor}},[e._v(e._s(e.statusIcon))])],1)]}}],null,!1,4217021254)},[t("span",[e._v(e._s(e.item.last_status.replace(/_/g," ")))])]):e._e()],1),t(ye,{attrs:{"position-x":e.contextMenuX,"position-y":e.contextMenuY,absolute:"","offset-y":""},model:{value:e.contextMenuShow,callback:function(r){e.contextMenuShow=r},expression:"contextMenuShow"}},[t(Me,[t(J,{attrs:{disabled:e.printerIsPrinting||!e.klipperReadyForGui},on:{click:function(r){e.showPrintDialog=!0}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPlay))]),e._v(" "+e._s(e.$t("Files.PrintStart"))+" ")],1),e.moonrakerComponents.includes("job_queue")?t(J,{on:{click:e.addToQueue}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPlaylistPlus))]),e._v(" "+e._s(e.$t("Files.AddToQueue"))+" ")],1):e._e(),e.moonrakerComponents.includes("job_queue")?t(J,{on:{click:function(r){e.showAddBatchToQueueDialog=!0}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPlaylistPlus))]),e._v(" "+e._s(e.$t("Files.AddBatchToQueue"))+" ")],1):e._e(),e.item.preheat_gcode!==null?t(J,{attrs:{disabled:["error","printing","paused"].includes(e.printer_state)},on:{click:function(r){return e.doSend(e.item.preheat_gcode)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiFire))]),e._v(" "+e._s(e.$t("Files.Preheat"))+" ")],1):e._e(),t(J,{on:{click:e.view3D}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiVideo3d))]),e._v(" "+e._s(e.$t("Files.View3D"))+" ")],1),t(J,{on:{click:e.downloadFile}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiCloudDownload))]),e._v(" "+e._s(e.$t("Files.Download"))+" ")],1),t(J,{on:{click:e.editFile}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiFileDocumentEditOutline))]),e._v(" "+e._s(e.$t("Files.EditFile"))+" ")],1),t(J,{on:{click:function(r){e.showRenameFileDialog=!0}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiRenameBox))]),e._v(" "+e._s(e.$t("Files.Rename"))+" ")],1),t(J,{staticClass:"red--text",on:{click:function(r){e.showDeleteDialog=!0}}},[t(_,{staticClass:"mr-1",attrs:{color:"error"}},[e._v(e._s(e.mdiDelete))]),e._v(" "+e._s(e.$t("Files.Delete"))+" ")],1)],1)],1),t(Eu,{attrs:{bool:e.showPrintDialog,file:e.item,"current-path":""},on:{closeDialog:function(r){e.showPrintDialog=!1}}}),t(ri,{attrs:{"is-visible":e.showAddBatchToQueueDialog,filename:e.filename},on:{close:function(r){e.showAddBatchToQueueDialog=!1}}}),t(le,{attrs:{"max-width":400},model:{value:e.showRenameFileDialog,callback:function(r){e.showRenameFileDialog=r},expression:"showRenameFileDialog"}},[t(U,{attrs:{title:e.$t("Files.RenameFile"),"card-class":"dashboard-files-rename-file-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.showRenameFileDialog=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputFieldRenameFile",attrs:{label:e.$t("Files.Name"),required:""},on:{keyup:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"enter",13,r.key,"Enter")?null:e.renameFile.apply(null,arguments)}},model:{value:e.renameFileNewName,callback:function(r){e.renameFileNewName=r},expression:"renameFileNewName"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.showRenameFileDialog=!1}}},[e._v(e._s(e.$t("Files.Cancel")))]),t(g,{attrs:{color:"primary",text:""},on:{click:e.renameFile}},[e._v(e._s(e.$t("Files.Rename")))])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.showDeleteDialog,callback:function(r){e.showDeleteDialog=r},expression:"showDeleteDialog"}},[t(U,{attrs:{title:e.$t("Files.Delete"),"card-class":"gcode-files-delete-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.showDeleteDialog=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t("p",{staticClass:"mb-0"},[e._v(e._s(e.$t("Files.DeleteSingleFileQuestion",{name:e.filename})))])]),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.showDeleteDialog=!1}}},[e._v(" "+e._s(e.$t("Files.Cancel"))+" ")]),t(g,{attrs:{color:"error",text:""},on:{click:e.removeFile}},[e._v(" "+e._s(e.$t("Files.Delete"))+" ")])],1)],1)],1)],1)},Nk=[],Vk=E(ha,Ik,Nk,!1,null,"64231dfc");const Bk=Vk.exports;var Uk=Object.getOwnPropertyDescriptor,Wk=(s,e,t,r)=>{for(var i=r>1?void 0:r?Uk(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let th=class extends k(L,Je){constructor(){super(...arguments),this.contentTdWidth=100}get filesLimit(){var e;return(e=this.$store.state.gui.uiSettings.dashboardFilesLimit)!=null?e:5}get filesFilter(){var e;return(e=this.$store.state.gui.uiSettings.dashboardFilesFilter)!=null?e:[]}get gcodeFiles(){var r;let e=(r=this.$store.getters["files/getAllGcodes"])!=null?r:[];this.filesFilter.length>0&&this.filesFilter.length<3&&(e=e.filter(i=>!!(this.filesFilter.includes("new")&&i.last_status===null||this.filesFilter.includes("completed")&&i.last_status==="completed"||this.filesFilter.includes("failed")&&i.last_status!==null&&i.last_status!=="completed"))),e=e.sort((i,n)=>n.modified.getTime()-i.modified.getTime()).slice(0,this.filesLimit);const t=e.filter(i=>!i.metadataRequested&&!i.metadataPulled);return this.$store.dispatch("files/requestMetadata",t.map(i=>({filename:"gcodes/"+i.filename}))),e}mounted(){setTimeout(()=>{this.calcContentTdWidth()},200)}calcContentTdWidth(){this.contentTdWidth=this.$refs.filesGcodeCard.$el.clientWidth-48-48-32}handleResize(){this.$nextTick(()=>{this.calcContentTdWidth()})}};th=Wk([S({components:{Panel:U,StatusPanelGcodefilesEntry:Bk}})],th);var zk=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{ref:"filesGcodeCard",staticClass:"filesGcodeCard",attrs:{flat:""}},[t(Qr,{staticClass:"dashboard-gcodes-table",attrs:{items:e.gcodeFiles,"hide-default-footer":"","sort-by":"time_added","mobile-breakpoint":"0"},scopedSlots:e._u([{key:"no-data",fn:function(){return[t("div",{staticClass:"text-center"},[e._v(e._s(e.$t("Panels.StatusPanel.EmptyGcodes")))])]},proxy:!0},{key:"item",fn:function({item:r}){return[t("status-panel-gcodefiles-entry",{key:r.filename,attrs:{"content-td-width":e.contentTdWidth,item:r}})]}}])}),t("resize-observer",{on:{notify:e.handleResize}})],1)},Gk=[],Zk=E(th,zk,Gk,!1,null,"113058c5");const Kb=Zk.exports;var qk=Object.getOwnPropertyDescriptor,Xk=(s,e,t,r)=>{for(var i=r>1?void 0:r?qk(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let sh=class extends k(L){constructor(){super(...arguments),this.maxFlow=0}get current_file(){var e;return(e=this.$store.state.printer.current_file)!=null?e:{}}get live_velocity(){var e,t,r;return(r=Math.abs((t=(e=this.$store.state.printer.motion_report)==null?void 0:e.live_velocity)==null?void 0:t.toFixed(0)))!=null?r:null}get live_extruder_velocity(){var t,r;const e=(r=(t=this.$store.state.printer.motion_report)==null?void 0:t.live_extruder_velocity)!=null?r:null;return e===null?null:e>0?e:0}get live_flow(){if(this.live_extruder_velocity===null)return null;const t=Math.pow(this.filament_diameter/2,2)*Math.PI*this.live_extruder_velocity;return t&&this.maxFlow<t&&(this.maxFlow=t),t==null?void 0:t.toFixed(1)}get outputMaxFlow(){return this.maxFlow?this.maxFlow.toFixed(1)+" mm³/s":"--"}get requested_speed(){var n,a,o,l,u,c;const e=(a=(n=this.$store.state.printer.gcode_move)==null?void 0:n.speed)!=null?a:0,t=(l=(o=this.$store.state.printer.gcode_move)==null?void 0:o.speed_factor)!=null?l:0,r=(c=(u=this.$store.state.printer.toolhead)==null?void 0:u.max_velocity)!=null?c:0,i=e/60*t;return i>r?r:i.toFixed(0)}get max_layers(){var e;return(e=this.$store.getters["printer/getPrintMaxLayers"])!=null?e:0}get current_layer(){var e;return(e=this.$store.getters["printer/getPrintCurrentLayer"])!=null?e:0}get estimated_time_file(){return this.$store.getters["printer/getEstimatedTimeFile"]}get estimated_time_filament(){return this.$store.getters["printer/getEstimatedTimeFilament"]}get estimated_time_slicer(){return this.$store.getters["printer/getEstimatedTimeSlicer"]}get estimated_time_avg(){return this.$store.getters["printer/getEstimatedTimeAvg"]}get eta(){return this.$store.getters["printer/getEstimatedTimeETAFormat"]}get filament_diameter(){var e,t,r,i;return(i=(r=(t=(e=this.$store.state.printer.configfile)==null?void 0:e.settings)==null?void 0:t.extruder)==null?void 0:r.filament_diameter)!=null?i:1.75}get print_time(){var e,t;return(t=(e=this.$store.state.printer.print_stats)==null?void 0:e.print_duration)!=null?t:0}get print_time_total(){var e,t;return(t=(e=this.$store.state.printer.print_stats)==null?void 0:e.total_duration)!=null?t:0}get filament_used(){var e,t;return(t=(e=this.$store.state.printer.print_stats)==null?void 0:e.filament_used)!=null?t:0}get outputFilamentUsed(){return this.filament_used>=1e3?(this.filament_used/1e3).toFixed(2)+" m":this.filament_used.toFixed(2)+" mm"}formatDuration(e){const t=e<0?"-":"";let r=Math.abs(e);const i=Math.floor(r/3600);r%=3600;const n=("0"+Math.floor(r/60)).slice(-2),a=("0"+Math.floor(r%60)).slice(-2);return t+i+":"+n+":"+a}};sh=Xk([S({components:{StatusPanelFilesJobqueue:zb,StatusPanelFilesGcodes:Kb}})],sh);var Yk=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Z,{staticClass:"pa-0"},[t(Ee,{staticClass:"py-0"},[t(x,{staticClass:"text-center py-5",attrs:{align:"center"}},[t(b,{staticClass:"col-3 pa-0"},[e.live_velocity!==null?[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("div",e._g(e._b({},"div",i,!1),r),[t("strong",[e._v(e._s(e.$t("Panels.StatusPanel.Speed")))]),t("br"),t("span",{staticClass:"text-no-wrap"},[e._v(e._s(e.live_velocity)+" mm/s")])])]}}],null,!1,1141285171)},[t("span",[e._v(e._s(e.$t("Panels.StatusPanel.Requested"))+": "+e._s(e.requested_speed+" mm/s"))])])]:[t("strong",[e._v(e._s(e.$t("Panels.StatusPanel.Speed")))]),t("br"),t("span",{staticClass:"text-no-wrap"},[e._v(e._s(e.requested_speed)+" mm/s")])]],2),t(b,{staticClass:"col-3 pa-0"},[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("div",e._g(e._b({},"div",i,!1),r),[t("strong",[e._v(e._s(e.$t("Panels.StatusPanel.Flow")))]),t("br"),t("span",{staticClass:"d-block text-center text-no-wrap"},[e._v(" "+e._s(e.live_flow+" mm³/s")+" ")])])]}}])},[t("span",[e._v(e._s(e.$t("Panels.StatusPanel.Max"))+": "+e._s(e.outputMaxFlow))])])],1),t(b,{staticClass:"col-3 pa-0"},[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("div",e._g(e._b({},"div",i,!1),r),[t("strong",[e._v(e._s(e.$t("Panels.StatusPanel.Filament")))]),t("br"),t("span",{staticClass:"d-block text-center text-no-wrap"},[e._v(" "+e._s(e.outputFilamentUsed)+" ")])])]}}])},["filament_total"in e.current_file?t("span",[e._v(" "+e._s((e.filament_used/1e3).toFixed(2))+" / "+e._s((e.current_file.filament_total/1e3).toFixed(2))+" m = "+e._s((100/e.current_file.filament_total*e.filament_used).toFixed(0))+" % ")]):e._e()])],1),t(b,{staticClass:"col-3 pa-0 text-center"},[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("div",e._g(e._b({staticClass:"text-center"},"div",i,!1),r),[t("strong",[e._v(e._s(e.$t("Panels.StatusPanel.Layer")))]),t("br"),t("span",{staticClass:"text-no-wrap"},[e._v(e._s(e.current_layer)+" of "+e._s(e.max_layers))])])]}}])},["object_height"in e.current_file&&e.current_file.object_height>0?t("span",[e._v(" "+e._s(e.$t("Panels.StatusPanel.ObjectHeight"))+": "+e._s(e.current_file.object_height)+" mm ")]):e._e()])],1)],1)],1),t(I,{staticClass:"my-0"}),t(Ee,{staticClass:"py-0"},[t(x,{staticClass:"text-center pt-5 pb-2 mb-0",attrs:{align:"center"}},[t(b,{staticClass:"col-3 pa-0"},[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("div",e._g(e._b({staticClass:"text-center"},"div",i,!1),r),[t("strong",[e._v(e._s(e.$t("Panels.StatusPanel.Estimate")))]),t("br"),t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.estimated_time_avg?e.formatDuration(e.estimated_time_avg):"--")+" ")])])]}}])},[t("div",{staticClass:"text-right"},[e._v(" "+e._s(e.$t("Panels.StatusPanel.File"))+": "+e._s(e.estimated_time_file?e.formatDuration(e.estimated_time_file):"--")+" "),t("br"),e._v(" "+e._s(e.$t("Panels.StatusPanel.Filament"))+": "+e._s(e.estimated_time_filament?e.formatDuration(e.estimated_time_filament):"--")+" ")])])],1),t(b,{staticClass:"col-3 pa-0"},[t("strong",[e._v(e._s(e.$t("Panels.StatusPanel.Slicer")))]),t("br"),t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.estimated_time_slicer?e.formatDuration(e.estimated_time_slicer):"--")+" ")])]),t(b,{staticClass:"col-3 pa-0"},[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("div",e._g(e._b({staticClass:"text-center"},"div",i,!1),r),[t("strong",[e._v(e._s(e.$t("Panels.StatusPanel.Total")))]),t("br"),t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.print_time_total?e.formatDuration(e.print_time_total):"--")+" ")])])]}}])},[t("div",{staticClass:"text-right"},[e._v(" "+e._s(e.$t("Panels.StatusPanel.Print"))+": "+e._s(e.print_time?e.formatDuration(e.print_time):"--")+" "),t("br"),e._v(" "+e._s(e.$t("Panels.StatusPanel.Difference"))+": "+e._s(e.print_time&&e.print_time_total?e.formatDuration(e.print_time_total-e.print_time):"--")+" ")])])],1),t(b,{staticClass:"col-3 pa-0"},[t("strong",[e._v(e._s(e.$t("Panels.StatusPanel.ETA")))]),t("br"),t("span",{staticClass:"text-no-wrap"},[e._v(e._s(e.eta))])])],1)],1)],1)},Jk=[],Kk=E(sh,Yk,Jk,!1,null,"ab7492ce");const Qk=Kk.exports;var eE=Object.getOwnPropertyDescriptor,tE=(s,e,t,r)=>{for(var i=r>1?void 0:r?eE(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let rh=class extends k(L){get current_file(){var e;return(e=this.$store.state.printer.current_file)!=null?e:{}}get filament_used(){var e,t;return(t=(e=this.$store.state.printer.print_stats)==null?void 0:e.filament_used)!=null?t:0}get outputFilamentUsed(){return this.filament_used>=1e3?(this.filament_used/1e3).toFixed(2)+" m":this.filament_used.toFixed(2)+" mm"}get print_time(){var e,t;return(t=(e=this.$store.state.printer.print_stats)==null?void 0:e.print_duration)!=null?t:0}get print_time_total(){var e,t;return(t=(e=this.$store.state.printer.print_stats)==null?void 0:e.total_duration)!=null?t:0}formatTime(e){let t=Math.floor(e/3600);e%=3600;let r=("0"+Math.floor(e/60)).slice(-2),i=("0"+(e%60).toFixed(0)).slice(-2);return t+":"+r+":"+i}};rh=tE([S({components:{}})],rh);var sE=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Z,{staticClass:"pa-0"},[t(Ee,{staticClass:"py-0"},[t(x,{staticClass:"text-center pt-5 pb-2 mb-0",attrs:{align:"center"}},[t(b,{staticClass:"col-3 pa-0"},[t("strong",[e._v(e._s(e.$t("Panels.StatusPanel.Filament")))]),t("br"),t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.outputFilamentUsed)+" ")])]),t(b,{staticClass:"col-3 pa-0"},[t("strong",[e._v(e._s(e.$t("Panels.StatusPanel.Slicer")))]),t("br"),t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s("estimated_time"in e.current_file?e.formatTime(e.current_file.estimated_time):"--")+" ")])]),t(b,{staticClass:"col-3 pa-0"},[t("strong",[e._v(e._s(e.$t("Panels.StatusPanel.Print")))]),t("br"),t("span",{staticClass:"text-no-wrap"},[e._v(e._s(e.print_time?e.formatTime(e.print_time):"--"))])]),t(b,{staticClass:"col-3 pa-0"},[t("strong",[e._v(e._s(e.$t("Panels.StatusPanel.Total")))]),t("br"),t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.print_time_total?e.formatTime(e.print_time_total):"--")+" ")])])],1)],1)],1)},rE=[],iE=E(rh,sE,rE,!1,null,"75863c9f");const nE=iE.exports;var aE=Object.getOwnPropertyDescriptor,oE=(s,e,t,r)=>{for(var i=r>1?void 0:r?aE(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let ih=class extends k(L){};ih=oE([S({components:{StatusPanelPrintstatusPrinting:Qk,StatusPanelPrintstatusComplete:nE}})],ih);var lE=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[["printing","paused","error","cancelled"].includes(e.printer_state)?[t("status-panel-printstatus-printing")]:e._e(),["complete"].includes(e.printer_state)?[t("status-panel-printstatus-complete")]:e._e()],2)},cE=[],uE=E(ih,lE,cE,!1,null,"61a1ffca");const dE=uE.exports;var mE=Object.defineProperty,hE=Object.getOwnPropertyDescriptor,Qb=(s,e,t,r)=>{for(var i=r>1?void 0:r?hE(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&mE(e,t,i),i};let Zl=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiDelete=Ue,this.mdiFile=Bs,this.mdiPlaylistPlus=Za,this.mdiPrinter=Xp,this.showContextMenu=!1,this.contextMenuX=0,this.contextMenuY=0,this.addBatchToQueueDialogBool=!1}get smallThumbnail(){var t,r,i,n,a;if(((i=(r=(t=this.job.metadata)==null?void 0:t.thumbnails)==null?void 0:r.length)!=null?i:0)<1)return!1;const e=(a=(n=this.job.metadata)==null?void 0:n.thumbnails)==null?void 0:a.find(o=>o.width>=Yt&&o.width<=Jt&&o.height>=Yt&&o.height<=Jt);return e?this.createThumbnailUrl(e):!1}get bigThumbnail(){var t,r,i,n,a;if(((i=(r=(t=this.job.metadata)==null?void 0:t.thumbnails)==null?void 0:r.length)!=null?i:0)<1)return!1;const e=(a=(n=this.job.metadata)==null?void 0:n.thumbnails)==null?void 0:a.find(o=>o.width>=Ls);return e?this.createThumbnailUrl(e):!1}get statusIcon(){return this.$store.getters["server/history/getPrintStatusIcon"](this.job.status)}get statusColor(){return this.$store.getters["server/history/getPrintStatusIconColor"](this.job.status)}get statusName(){return this.$t("History.StatusValues.".concat(this.job.status),"en")?this.$t("History.StatusValues.".concat(this.job.status)):this.job.status.replace(/_/g," ")}get description(){const e=[],t=[];let r="--";return this.filamentLength&&t.push(this.filamentLength),this.filamentWeight&&t.push(this.filamentWeight),t.length&&(r=t.join(" / ")),e.push("".concat(this.$t("Panels.StatusPanel.Filament"),": ").concat(r)),this.estimatedTime!=="--"?e.push("".concat(this.$t("Panels.StatusPanel.PrintTime"),": ").concat(this.estimatedTime)):this.totalTime&&e.push("".concat(this.$t("Panels.StatusPanel.TotalTime"),": ").concat(this.totalTime)),e.join(", ")}get filamentLength(){const e=this.job.filament_used;return e===0?null:e>=1e3?(e/1e3).toFixed(1)+" m":e.toFixed(0)+" mm"}get filamentWeight(){var n,a,o,l;const e=(a=(n=this.job.metadata)==null?void 0:n.filament_total)!=null?a:0,t=(l=(o=this.job.metadata)==null?void 0:o.filament_weight_total)!=null?l:0;if(e===0||t===0)return null;const r=t/e,i=this.job.filament_used*r;return i===0?null:i>=1e3?(length/1e3).toFixed(1)+" kg":i.toFixed(0)+" g"}get estimatedTime(){var t;let e=(t=this.job.print_duration)!=null?t:0;return e==0?"--":Is(e)}get totalTime(){var t;let e=(t=this.job.total_duration)!=null?t:0;return e===0?null:Is(e)}get bigThumbnailBackground(){var e;return(e=this.$store.state.gui.uiSettings.bigThumbnailBackground)!=null?e:At}get bigThumbnailTooltipColor(){if(At.toLowerCase()!==this.bigThumbnailBackground.toLowerCase())return this.bigThumbnailBackground}get isJobQueueAvailable(){return this.moonrakerComponents.includes("job_queue")}openContextMenu(e){if(e==null||e.preventDefault(),this.showContextMenu){this.showContextMenu=!1;return}this.showContextMenu=!0,this.contextMenuX=(e==null?void 0:e.clientX)||(e==null?void 0:e.pageX)||window.screenX/2,this.contextMenuY=(e==null?void 0:e.clientY)||(e==null?void 0:e.pageY)||window.screenY/2}startPrint(){this.job.exists&&this.$socket.emit("printer.print.start",{filename:this.job.filename})}addToQueue(){this.$store.dispatch("server/jobQueue/addToQueue",[this.job.filename]),this.$toast.info(this.$t("History.AddToQueueSuccessful",{filename:this.job.filename}).toString())}deleteJob(){this.$socket.emit("server.history.delete_job",{uid:this.job.job_id},{action:"server/history/getDeletedJobs"})}createThumbnailUrl(e){let t="";return this.job.filename.lastIndexOf("/")!==-1&&(t=this.job.filename.substring(0,this.job.filename.lastIndexOf("/")+1)),"".concat(this.apiUrl,"/server/files/gcodes/").concat(Ie(t+e.relative_path),"?timestamp=").concat(this.job.metadata.modified)}};Qb([w({type:Object,required:!0})],Zl.prototype,"job",2);Zl=Qb([S],Zl);var pE=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,{directives:[{name:"longpress",rawName:"v-longpress:600",value:r=>e.openContextMenu(r),expression:"(e) => openContextMenu(e)",arg:"600"}],staticClass:"history-list-entry d-flex flex-row flex-nowrap cursor-pointer",on:{contextmenu:function(r){return e.openContextMenu(r)}}},[t(b,{staticClass:"col-auto d-flex flex-column justify-center pr-0 py-0"},[e.smallThumbnail?t(de,{attrs:{top:"",disabled:!e.bigThumbnail,"content-class":"tooltip__content-opacity1",color:e.bigThumbnailTooltipColor},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("vue-load-image",{staticClass:"text-center width-32"},[t("img",e._g(e._b({attrs:{slot:"image",src:e.smallThumbnail,width:32,height:32,alt:e.job.filename},slot:"image"},"img",i,!1),r)),t("div",{attrs:{slot:"preloader"},slot:"preloader"},[t(ot,{attrs:{indeterminate:"",color:"primary"}})],1),t("div",{attrs:{slot:"error"},slot:"error"},[t(_,[e._v(e._s(e.mdiFile))])],1)])]}}],null,!1,3004314596)},[t("span",[t("img",{attrs:{src:e.bigThumbnail,width:250,alt:e.job.filename}})])]):t(_,[e._v(e._s(e.mdiFile))])],1),t(b,{staticClass:"py-1",staticStyle:{"min-width":"0","font-size":"0.875em"}},[t("div",{staticClass:"text-truncate"},[e.job.count>1?t("strong",[e._v(e._s(e.job.count)+"x")]):e._e(),e._v(" "+e._s(e.job.filename)+" ")]),e.description?t("small",{staticClass:"text-truncate"},[e._v(e._s(e.description))]):e._e()]),t(b,{staticClass:"col-auto d-flex flex-column justify-center pa-0 pr-3"},[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("span",e._g(e._b({},"span",i,!1),r),[t(_,{attrs:{small:"",color:e.statusColor,disabled:!e.job.exists}},[e._v(" "+e._s(e.statusIcon)+" ")])],1)]}}])},[t("span",[e._v(e._s(e.statusName))])])],1),t(ye,{attrs:{"position-x":e.contextMenuX,"position-y":e.contextMenuY,absolute:"","offset-y":""},model:{value:e.showContextMenu,callback:function(r){e.showContextMenu=r},expression:"showContextMenu"}},[t(Me,[e.job.exists?t(J,{attrs:{disabled:e.printerIsPrinting||!e.klipperReadyForGui},on:{click:e.startPrint}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPrinter))]),e._v(" "+e._s(e.$t("History.Reprint"))+" ")],1):e._e(),e.job.exists&&e.isJobQueueAvailable?t(J,{on:{click:e.addToQueue}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPlaylistPlus))]),e._v(" "+e._s(e.$t("Files.AddToQueue"))+" ")],1):e._e(),e.job.exists&&e.isJobQueueAvailable?t(J,{on:{click:function(r){e.addBatchToQueueDialogBool=!0}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPlaylistPlus))]),e._v(" "+e._s(e.$t("Files.AddBatchToQueue"))+" ")],1):e._e(),t(J,{staticClass:"red--text",on:{click:e.deleteJob}},[t(_,{staticClass:"mr-1",attrs:{color:"error"}},[e._v(e._s(e.mdiDelete))]),e._v(" "+e._s(e.$t("History.Delete"))+" ")],1)],1)],1),t(ri,{attrs:{"is-visible":e.addBatchToQueueDialogBool,"show-toast":!0,filename:e.job.filename},on:{close:function(r){e.addBatchToQueueDialogBool=!1}}})],1)},fE=[],gE=E(Zl,pE,fE,!1,null,"e7f9a117");const _E=gE.exports;var vE=Object.getOwnPropertyDescriptor,bE=(s,e,t,r)=>{for(var i=r>1?void 0:r?vE(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let nh=class extends k(L){get jobs(){var e;return(e=this.$store.state.server.history.jobs)!=null?e:[]}get maxLength(){var e;return(e=this.$store.state.gui.uiSettings.dashboardHistoryLimit)!=null?e:5}get jobsCombined(){var t,r;const e=[];for(const i of this.jobs){if(e.length===0){e.push({...i,count:1});continue}const n=e[e.length-1],a=(t=n.metadata.uuid)!=null?t:null,o=(r=i.metadata.uuid)!=null?r:null;if(a===o&&n.status===i.status){n.filament_used+=i.filament_used,n.print_duration+=i.print_duration,n.total_duration+=i.total_duration,n.count+=1;continue}if(e.length>=this.maxLength)break;e.push({...i,count:1})}return e}startJobqueue(){this.$store.dispatch("server/jobQueue/start")}};nh=bE([S({components:{StatusPanelHistoryEntry:_E}})],nh);var yE=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Pe,{staticClass:"history",attrs:{flat:""}},[e.jobsCombined.length?[t(x,{staticClass:"mx-0 mt-0 pb-3"},[t(b,{staticClass:"history-list"},e._l(e.jobsCombined,function(r){return t("status-panel-history-entry",{key:r.job_id,attrs:{job:r}})}),1)],1)]:t("div",[t("p",{staticClass:"body-2 my-3 text-center text--disabled"},[e._v(e._s(e.$t("Panels.StatusPanel.EmptyHistory")))])])],2)},CE=[],$E=E(nh,yE,CE,!1,null,"6af64ef2");const xE=$E.exports;var wE=Object.defineProperty,SE=Object.getOwnPropertyDescriptor,e0=(s,e,t,r)=>{for(var i=r>1?void 0:r?SE(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&wE(e,t,i),i};let ql=class extends k(L){constructor(){super(...arguments),this.coordinationCrossColor="#888",this.stripesOffset=50}get printing_objects(){var s,e;return((e=(s=this.$store.state.printer.exclude_object)==null?void 0:s.objects)!=null?e:[]).map(t=>{let r=0;if("polygon"in t)for(let i=0;i<t.polygon.length;i++){const n=t.polygon[i],a=i===t.polygon.length-1?t.polygon[0]:t.polygon[i+1];r+=n[0]*a[1]-n[1]*a[0]}return{center:t.center,name:t.name,polygon:t.polygon,size:Math.abs(r)}}).sort((t,r)=>r.size-t.size)}get printing_objects_with_polygons(){return this.printing_objects.filter(s=>"polygon"in s)}get current_object(){var s,e;return(e=(s=this.$store.state.printer.exclude_object)==null?void 0:s.current_object)!=null?e:null}get excluded_objects(){var s,e;return(e=(s=this.$store.state.printer.exclude_object)==null?void 0:s.excluded_objects)!=null?e:[]}get viewBox(){return this.convertX(this.stepperXmin)+" "+this.convertY(this.stepperYmax)+" "+this.absoluteX+" "+this.absoluteY}get toolhead(){var s;return(s=this.$store.state.printer.toolhead)!=null?s:{}}get axis_minimum(){var s;return(s=this.toolhead.axis_minimum)!=null?s:[]}get axis_maximum(){var s;return(s=this.toolhead.axis_maximum)!=null?s:[]}get stepperXmin(){var s;return(s=this.axis_minimum[0])!=null?s:0}get stepperXmax(){var s;return(s=this.axis_maximum[0])!=null?s:200}get stepperYmin(){var s;return(s=this.axis_minimum[1])!=null?s:0}get stepperYmax(){var s;return(s=this.axis_maximum[1])!=null?s:200}get absoluteX(){return Math.abs(this.stepperXmin)+Math.abs(this.stepperXmax)}get absoluteY(){return Math.abs(this.stepperYmin)+Math.abs(this.stepperYmax)}get xStripes(){const s=[],e=Math.floor(this.stepperXmin/this.stripesOffset)*this.stripesOffset,t=Math.floor(this.stepperXmax/this.stripesOffset)*this.stripesOffset;for(let r=e;r<=t;r=r+this.stripesOffset)s.push(r);return s}get yStripes(){const s=[],e=Math.floor(this.stepperYmin/this.stripesOffset)*this.stripesOffset,t=Math.floor(this.stepperYmax/this.stripesOffset)*this.stripesOffset;for(let r=e;r<=t;r=r+this.stripesOffset)s.push(r);return s}get primaryColor(){var s,e;return(e=(s=this.$store.state.gui.theme)==null?void 0:s.primary)!=null?e:al}convertX(s){return s}convertY(s){return s*-1}showObjectTooltip(s){this.$refs.tooltipObjectMap&&(this.$refs.tooltipObjectMap.innerHTML=s,this.$refs.tooltipObjectMap.style.display="block",window.addEventListener("mousemove",this.moveTooltip))}hideObjectTooltip(){this.$refs.tooltipObjectMap&&(this.$refs.tooltipObjectMap.style.display="none",window.removeEventListener("mousemove",this.moveTooltip))}moveTooltip(s){if(!this.$refs.tooltipObjectMap)return;const e=s.offsetY-this.$refs.tooltipObjectMap.clientHeight-15;this.$refs.tooltipObjectMap.style.left="".concat(s.offsetX-20,"px"),this.$refs.tooltipObjectMap.style.top="".concat(e,"px")}openExcludeObjectDialog(s){this.$emit("update:name",s),this.$emit("update:bool",!0)}};e0([w({required:!1,default:""})],ql.prototype,"hoverName",2);ql=e0([S],ql);var PE=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",{staticStyle:{position:"relative"}},[t("div",{ref:"tooltipObjectMap",attrs:{id:"tooltipObjectMap"}}),t("svg",{attrs:{version:"1.1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",viewBox:e.viewBox,"xml:space":"preserve"}},[t("defs",[t("marker",{attrs:{id:"arrowhead",markerWidth:"5",markerHeight:"4",refX:"2",refY:"2",orient:"auto"}},[t("polygon",{attrs:{points:"0 0, 5 2, 0 4",fill:e.coordinationCrossColor}})])]),t("line",{attrs:{x1:e.convertX(0),y1:e.convertY(1),x2:e.convertX(e.stepperXmax/4),y2:e.convertY(1),stroke:e.coordinationCrossColor,"stroke-width":"2","marker-end":"url(#arrowhead)"}}),t("line",{attrs:{x1:e.convertX(1),y1:e.convertY(0),x2:e.convertX(1),y2:e.convertY(e.stepperYmax/4),stroke:e.coordinationCrossColor,"stroke-width":"2","marker-end":"url(#arrowhead)"}}),t("g",[e._l(e.xStripes,function(r){return t("line",{key:"xLines"+r,attrs:{x1:e.convertX(r),x2:e.convertX(r),y1:e.convertY(e.stepperYmin),y2:e.convertY(e.stepperYmax),stroke:e.coordinationCrossColor,"stroke-opacity":.25,"stroke-width":"1"}})}),e._l(e.yStripes,function(r){return t("line",{key:"yLines"+r,attrs:{x1:e.convertX(e.stepperXmin),x2:e.convertX(e.stepperXmax),y1:e.convertY(r),y2:e.convertY(r),stroke:e.coordinationCrossColor,"stroke-opacity":.25,"stroke-width":"1"}})})],2),e._l(e.printing_objects_with_polygons,function(r,i){return t("g",{key:i},[t("polygon",{staticStyle:{cursor:"pointer"},attrs:{points:r.polygon.map(n=>e.convertX(n[0])+","+e.convertY(n[1])).join(" "),stroke:e.current_object===r.name?e.primaryColor:"#666","stroke-width":"2","fill-rule":"evenodd",fill:e.hoverName===r.name?e.primaryColor:e.excluded_objects.includes(r.name)?"#6668":"#bbb"},on:{mouseover:function(n){return e.showObjectTooltip(r.name)},mouseout:e.hideObjectTooltip,click:function(n){return e.openExcludeObjectDialog(r.name)}}})])})],2)])},DE=[],TE=E(ql,PE,DE,!1,null,"908c0af1");const t0=TE.exports;var OE=Object.defineProperty,ME=Object.getOwnPropertyDescriptor,s0=(s,e,t,r)=>{for(var i=r>1?void 0:r?ME(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&OE(e,t,i),i};let Xl=class extends k(L){constructor(){super(...arguments),this.mdiCloseCircle=ol}get printing_objects(){var s,e;return(e=(s=this.$store.state.printer.exclude_object)==null?void 0:s.objects)!=null?e:[]}get current_object(){var s,e;return(e=(s=this.$store.state.printer.exclude_object)==null?void 0:s.current_object)!=null?e:null}get excluded_objects(){var s,e;return(e=(s=this.$store.state.printer.exclude_object)==null?void 0:s.excluded_objects)!=null?e:[]}openExcludeObjectDialog(s){this.$emit("update:name",s),this.$emit("update:bool",!0)}mouseOverObject(s){this.$emit("update:hoverName",s)}};s0([w({required:!1,default:""})],Xl.prototype,"hoverName",2);Xl=s0([S],Xl);var kE=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e._l(e.printing_objects,function(r){return[t(x,{key:"div_"+r.name,staticClass:"py-3 d-flex",on:{click:function(i){return e.mouseOverObject(r.name)},mouseover:function(i){return e.mouseOverObject(r.name)},mouseleave:function(i){return e.mouseOverObject("")}}},[t(b,{class:"py-2 subtitle-2 text-truncate "+(e.hoverName===r.name?"text--white":"text--disabled")},[e._v(" "+e._s(r.name)+" ")]),t(b,{staticClass:"col-auto py-2"},[e.excluded_objects.includes(r.name)?t($s,{staticClass:"text--disabled",attrs:{pill:"",small:""}},[e._v(" "+e._s(e.$t("Panels.StatusPanel.ExcludeObject.Excluded"))+" ")]):t(_,{staticClass:"text--disabled cursor-pointer",attrs:{small:""},on:{click:function(i){return e.openExcludeObjectDialog(r.name)}}},[e._v(" "+e._s(e.mdiCloseCircle)+" ")])],1)],1),t(I,{key:"divider_"+r.name})]})],2)},EE=[],LE=E(Xl,kE,EE,!1,null,"c8da0728");const r0=LE.exports;var AE=Object.defineProperty,FE=Object.getOwnPropertyDescriptor,Lu=(s,e,t,r)=>{for(var i=r>1?void 0:r?FE(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&AE(e,t,i),i};let Li=class extends k(L){constructor(){super(...arguments),this.hoverName="",this.mdiSelectionRemove=cl,this.mdiCloseThick=pe}hideDialog(){this.$emit("update:showDialog",!1)}get passName(){return this.excludeObjectDialogName}set passName(e){this.$emit("update:name",e)}updateExcludeObjectDialogBool(e){this.$emit("update:bool",e)}updateExcludeObjectDialogName(e){this.$emit("update:name",e)}updateHoverObjectDialogName(e){this.hoverName=e}};Lu([w({required:!0})],Li.prototype,"showDialog",2);Lu([w({required:!0})],Li.prototype,"excludeObjectDialogBool",2);Lu([w({required:!0})],Li.prototype,"excludeObjectDialogName",2);Li=Lu([S({components:{Panel:U,StatusPanelExcludeObjectDialogList:r0,StatusPanelExcludeObjectDialogMap:t0}})],Li);var RE=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(le,{attrs:{width:"900",persistent:"",fullscreen:e.isMobile},model:{value:e.showDialog,callback:function(r){e.showDialog=r},expression:"showDialog"}},[t(U,{attrs:{title:e.$t("Panels.StatusPanel.ExcludeObject.ExcludeObject"),icon:e.mdiSelectionRemove,"card-class":"exclude-object-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.hideDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Ee,[t(x,[t(b,{staticClass:"col-12 col-sm-6 pb-0 pb-sm-3"},[t("status-panel-exclude-object-dialog-map",{attrs:{"hover-name":e.hoverName},on:{"update:name":e.updateExcludeObjectDialogName,"update:bool":e.updateExcludeObjectDialogBool}})],1),t(b,{staticClass:"col-12 col-sm-6 pt-0 pt-sm-3"},[t("status-panel-exclude-object-dialog-list",{attrs:{"exclude-object-dialog-name":e.excludeObjectDialogName,"exclude-object-dialog-bool":e.excludeObjectDialogBool,"hover-name":e.hoverName},on:{"update:excludeObjectDialogName":function(r){e.excludeObjectDialogName=r},"update:exclude-object-dialog-name":function(r){e.excludeObjectDialogName=r},"update:excludeObjectDialogBool":function(r){e.excludeObjectDialogBool=r},"update:exclude-object-dialog-bool":function(r){e.excludeObjectDialogBool=r},"update:name":e.updateExcludeObjectDialogName,"update:hoverName":e.updateHoverObjectDialogName,"update:bool":e.updateExcludeObjectDialogBool}})],1)],1)],1)],1)],1)],1)},HE=[],jE=E(Li,RE,HE,!1,null,"9253cf61");const IE=jE.exports;var NE=Object.defineProperty,VE=Object.getOwnPropertyDescriptor,i0=(s,e,t,r)=>{for(var i=r>1?void 0:r?VE(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&NE(e,t,i),i};let Yl=class extends k(L){constructor(){super(...arguments),this.mdiPrinter3dNozzle=Us,this.mdiSelectionRemove=cl,this.boolShowExcludeObjectDialog=!1,this.excludeObjectDialogName=""}get showDialogPass(){return this.showDialog}set showDialogPass(e){this.$emit("update:showDialog",e)}get printing_objects(){var e,t;return(t=(e=this.$store.state.printer.exclude_object)==null?void 0:e.objects)!=null?t:[]}get current_object(){var e,t;return(t=(e=this.$store.state.printer.exclude_object)==null?void 0:e.current_object)!=null?t:null}get excluded_objects(){var e,t;return(t=(e=this.$store.state.printer.exclude_object)==null?void 0:e.excluded_objects)!=null?t:[]}updateExcludeObjectDialogName(e){this.excludeObjectDialogName=e}updateExcludeObjectDialogBool(e){this.boolShowExcludeObjectDialog=e}openCancelObjectDialog(e){this.excludeObjectDialogName=e,this.boolShowExcludeObjectDialog=!0}cancelObject(){this.$socket.emit("printer.gcode.script",{script:"EXCLUDE_OBJECT NAME="+this.excludeObjectDialogName}),this.boolShowExcludeObjectDialog=!1}};i0([w({required:!0})],Yl.prototype,"showDialog",2);Yl=i0([S({components:{StatusPanelExcludeObjectDialog:IE}})],Yl);var BE=function(){var e=this,t=e._self._c;return e._self._setupProxy,["printing","paused"].includes(e.printer_state)&&e.printing_objects.length?t("div",[t(Ee,{staticClass:"py-0"},[t("div",{staticClass:"d-flex flex-row flex-nowrap justify-space-between"},[t("div",{staticClass:"py-2",staticStyle:{width:"calc(100% - 25px)"}},[t("span",{staticClass:"subtitle-2 d-block px-0 text--disabled text-truncate"},[t(_,{staticClass:"mr-2",attrs:{small:""}},[e._v(e._s(e.mdiPrinter3dNozzle))]),e._v(" "+e._s(e.current_object!==null?e.current_object:"--")+" ")],1)]),t("div",{staticClass:"py-2 pl-0"},[e.current_object!==null?t(_,{staticClass:"text--disabled cursor-pointer",attrs:{small:""},on:{click:function(r){return e.openCancelObjectDialog(e.current_object)}}},[e._v(" "+e._s(e.mdiSelectionRemove)+" ")]):e._e()],1)])]),t(I,{staticClass:"mt-0 mb-0"}),t(le,{attrs:{"max-width":"400"},model:{value:e.boolShowExcludeObjectDialog,callback:function(r){e.boolShowExcludeObjectDialog=r},expression:"boolShowExcludeObjectDialog"}},[t(Pe,[t(Op,{attrs:{flat:"",dense:""}},[t(ru,[t("span",{staticClass:"subheading"},[t(_,{attrs:{left:""}},[e._v(e._s(e.mdiSelectionRemove))]),e._v(" "+e._s(e.$t("Panels.StatusPanel.ExcludeObject.ExcludeObjectHeadline"))+" ")],1)])],1),t(Z,{staticClass:"mt-3"},[e._v(" "+e._s(e.$t("Panels.StatusPanel.ExcludeObject.ExcludeObjectText",{name:e.excludeObjectDialogName}))+" ")]),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:function(r){e.boolShowExcludeObjectDialog=!1}}},[e._v(" "+e._s(e.$t("Panels.StatusPanel.ExcludeObject.Cancel"))+" ")]),t(g,{attrs:{color:"primary",text:""},on:{click:e.cancelObject}},[e._v(" "+e._s(e.$t("Panels.StatusPanel.ExcludeObject.ExcludeObject"))+" ")])],1)],1)],1),t("status-panel-exclude-object-dialog",{attrs:{"show-dialog":e.showDialogPass,"exclude-object-dialog-name":e.excludeObjectDialogName,"exclude-object-dialog-bool":e.boolShowExcludeObjectDialog},on:{"update:showDialog":function(r){e.showDialogPass=r},"update:show-dialog":function(r){e.showDialogPass=r},"update:excludeObjectDialogName":function(r){e.excludeObjectDialogName=r},"update:exclude-object-dialog-name":function(r){e.excludeObjectDialogName=r},"update:excludeObjectDialogBool":function(r){e.boolShowExcludeObjectDialog=r},"update:exclude-object-dialog-bool":function(r){e.boolShowExcludeObjectDialog=r},"update:name":e.updateExcludeObjectDialogName,"update:bool":e.updateExcludeObjectDialogBool}})],1):e._e()},UE=[],WE=E(Yl,BE,UE,!1,null,"fc6f7b3c");const zE=WE.exports;var GE=Object.defineProperty,ZE=Object.getOwnPropertyDescriptor,n0=(s,e,t,r)=>{for(var i=r>1?void 0:r?ZE(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&GE(e,t,i),i};let Jl=class extends k(L){constructor(){super(...arguments),this.mdiFileOutline=tv,this.mdiFile=Bs,this.focus=!1,this.thumbnailFactor=0}get current_filename(){var e,t;return(t=(e=this.$store.state.printer.print_stats)==null?void 0:e.filename)!=null?t:""}get current_file(){var e;return(e=this.$store.state.printer.current_file)!=null?e:{}}get thumbnailBig(){if("thumbnails"in this.current_file&&this.current_file.thumbnails.length){const e=this.current_file.thumbnails.find(t=>t.width>=Ls);if(e&&"relative_path"in e){let t="";if(this.current_file.filename.lastIndexOf("/")!==-1&&(t=this.current_file.filename.substr(0,this.current_file.filename.lastIndexOf("/")+1)),e&&"relative_path"in e)return"".concat(this.apiUrl,"/server/files/gcodes/").concat(Ie(t+e.relative_path),"?timestamp=").concat(this.current_file.modified)}}return""}get thumbnailBigHeight(){if("thumbnails"in this.current_file&&this.current_file.thumbnails.length){const e=this.current_file.thumbnails.find(t=>t.width>=Ls);if(e&&"height"in e)return e.height}return 200}get thumbnailBigWidth(){if("thumbnails"in this.current_file&&this.current_file.thumbnails.length){const e=this.current_file.thumbnails.find(t=>t.width>=Ls);if(e&&"width"in e)return e.width}return 300}get thumbnailSmall(){if("thumbnails"in this.current_file&&this.current_file.thumbnails.length){const e=this.current_file.thumbnails.find(t=>t.width>=Yt&&t.width<=Jt&&t.height>=Yt&&t.height<=Jt);if(e&&"relative_path"in e){let t="";if(this.current_file.filename.lastIndexOf("/")!==-1&&(t=this.current_file.filename.substr(0,this.current_file.filename.lastIndexOf("/")+1)),e&&"relative_path"in e)return"".concat(this.apiUrl,"/server/files/gcodes/").concat(Ie(t+e.relative_path),"?timestamp=").concat(this.current_file.modified)}}return""}get boolBigThumbnail(){var t;const e=(t=this.$store.state.gui.uiSettings.boolBigThumbnail)!=null?t:!0;return this.current_filename&&e&&this.thumbnailBig}get bigThumbnailBackground(){var e;return(e=this.$store.state.gui.uiSettings.bigThumbnailBackground)!=null?e:At}get thumbnailStyle(){let e={height:"200px"};return this.printstatusThumbnailZoom?this.focus&&this.thumbnailBlurHeight>0&&(e.height="".concat(this.thumbnailBlurHeight,"px")):e.height="100%",At.toLowerCase()!==this.bigThumbnailBackground.toLowerCase()&&(e.backgroundColor=this.bigThumbnailBackground),e}get styleThumbnailOverlay(){const e={backgroundColor:"rgba(0, 0, 0, 0.3)",backdropFilter:"blur(3px)"};return this.$vuetify.theme.dark||(e.backgroundColor="rgba(255, 255, 255, 0.3)"),e}get thumbnailBlurHeight(){return this.thumbnailFactor===0?0:(this.thumbnailBigHeight*this.thumbnailFactor).toFixed()}get printstatusThumbnailZoom(){var e;return(e=this.$store.state.gui.uiSettings.printstatusThumbnailZoom)!=null?e:!0}calcThumbnailFactor(){var t,r;const e=(r=(t=this.$refs.bigThumbnail)==null?void 0:t.$el.clientWidth)!=null?r:0;return(!e||!this.thumbnailBigWidth)&&(this.thumbnailFactor=0),this.thumbnailFactor=e/this.thumbnailBigWidth}handleResize(){this.$nextTick(()=>{this.calcThumbnailFactor()})}};n0([Ke(200)],Jl.prototype,"handleResize",1);Jl=n0([S({})],Jl);var qE=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.current_filename?t("div",{staticClass:"statusPanel-printstatus-thumbnail"},[e.boolBigThumbnail?t(nu,{ref:"bigThumbnail",staticClass:"d-flex align-end statusPanel-big-thumbnail",style:e.thumbnailStyle,attrs:{src:e.thumbnailBig,tabindex:"-1",height:"200"},on:{focus:function(r){e.focus=!0},blur:function(r){e.focus=!1}}},[t(gt,{staticClass:"white--text py-2 px-2",style:e.styleThumbnailOverlay},[t(x,[t(b,[t("span",{staticClass:"subtitle-2 text-truncate px-0 text--disabled d-block"},[t(_,{staticClass:"mr-2",attrs:{small:""}},[e._v(e._s(e.mdiFileOutline))]),e._v(" "+e._s(e.current_filename)+" ")],1)])],1)],1)],1):[t(Ee,[t(x,[t(b,{class:e.thumbnailSmall?"py-3":"py-2",style:e.thumbnailSmall?"width: calc(100% - 40px);":""},[t("span",{staticClass:"subtitle-2 text-truncate d-block px-0 text--disabled"},[t(_,{staticClass:"mr-2",attrs:{small:""}},[e._v(e._s(e.mdiFileOutline))]),e._v(" "+e._s(e.current_filename)+" ")],1)]),e.thumbnailSmall?t(b,{staticClass:"pa-2 pl-0 col-auto"},[e.thumbnailSmall&&e.thumbnailBig?[t(de,{attrs:{top:"","content-class":"tooltip__content-opacity1"},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("vue-load-image",{staticClass:"d-flex"},[t("img",e._g(e._b({attrs:{slot:"image",src:e.thumbnailSmall,width:"32",height:"32",alt:e.current_filename},slot:"image"},"img",i,!1),r)),t("div",{attrs:{slot:"preloader"},slot:"preloader"},[t(ot,{attrs:{indeterminate:"",color:"primary"}})],1),t("div",{attrs:{slot:"error"},slot:"error"},[t(_,[e._v(e._s(e.mdiFile))])],1)])]}}],null,!1,4119397588)},[t("span",[t("img",{attrs:{src:e.thumbnailBig,width:"250",alt:e.current_filename}})])])]:e.thumbnailSmall?[t("vue-load-image",[t("img",{attrs:{slot:"image",src:e.thumbnailSmall,width:"32",height:"32",alt:e.current_filename},slot:"image"}),t("div",{attrs:{slot:"preloader"},slot:"preloader"},[t(ot,{attrs:{indeterminate:"",color:"primary"}})],1),t("div",{attrs:{slot:"error"},slot:"error"},[t(_,[e._v(e._s(e.mdiFile))])],1)])]:e._e()],2):e._e()],1)],1)],t("resize-observer",{on:{notify:e.handleResize}})],2):e._e()},XE=[],YE=E(Jl,qE,XE,!1,null,"2a5f7305");const JE=YE.exports;var KE=Object.defineProperty,QE=Object.getOwnPropertyDescriptor,Au=(s,e,t,r)=>{for(var i=r>1?void 0:r?QE(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&KE(e,t,i),i};let Ai=class extends k(L){constructor(){super(...arguments),this.mdiLayersPlus=hm,this.mdiCloseThick=pe,this.type="atLayer",this.layer=0,this.call="PAUSE"}hideDialog(){this.$emit("update:showDialog",!1)}get items(){return[{text:this.$t("Panels.StatusPanel.PauseAtLayer.AtLayer"),value:"atLayer",status:this.existsSetPauseAtLayer},{text:this.$t("Panels.StatusPanel.PauseAtLayer.NextLayer"),value:"nextLayer",status:this.existsSetPauseNextLayer}]}get itemsFiltered(){return this.items.filter(e=>e.status)}get itemsCall(){return[{text:"PAUSE",value:"PAUSE"},{text:"M600",value:"M600"}]}get current_layer(){var e,t,r;return(r=(t=(e=this.$store.state.printer.print_stats)==null?void 0:e.info)==null?void 0:t.current_layer)!=null?r:0}get total_layer(){var e,t,r;return(r=(t=(e=this.$store.state.printer.print_stats)==null?void 0:e.info)==null?void 0:t.total_layer)!=null?r:0}get macros(){var e;return(e=this.$store.getters["printer/getMacros"])!=null?e:[]}get existsSetPauseAtLayer(){return this.macros.findIndex(e=>e.name==="SET_PAUSE_AT_LAYER")!==-1}get existsSetPauseNextLayer(){return this.macros.findIndex(e=>e.name==="SET_PAUSE_NEXT_LAYER")!==-1}get macroSetPrintStatsInfo(){var e;return(e=this.$store.state.printer["gcode_macro SET_PRINT_STATS_INFO"])!=null?e:{}}get macroSettingsPauseAtLayer(){var e;return(e=this.macroSetPrintStatsInfo.pause_at_layer)!=null?e:{}}get macroSettingsPauseAtLayerEnable(){var e;return(e=this.macroSettingsPauseAtLayer.enable)!=null?e:!1}get macroSettingsPauseAtLayerCall(){var e;return(e=this.macroSettingsPauseAtLayer.call)!=null?e:"PAUSE"}get macroSettingsPauseAtLayerLayer(){var e;return(e=this.macroSettingsPauseAtLayer.layer)!=null?e:0}get macroSettingsPauseNextLayer(){var e;return(e=this.macroSetPrintStatsInfo.pause_next_layer)!=null?e:{}}get macroSettingsPauseNextLayerEnable(){var e;return(e=this.macroSettingsPauseNextLayer.enable)!=null?e:!1}get macroSettingsPauseNextLayerCall(){var e;return(e=this.macroSettingsPauseNextLayer.call)!=null?e:"PAUSE"}sendCommand(){if(this.type==="atLayer"){this.doSend("SET_PAUSE_AT_LAYER ENABLE=1 LAYER=".concat(this.layer," MACRO=").concat(this.call)),this.hideDialog();return}this.doSend("SET_PAUSE_NEXT_LAYER ENABLE=1 MACRO=".concat(this.call)),this.hideDialog()}doSend(e){this.$store.dispatch("server/addEvent",{message:e,type:"command"}),this.$socket.emit("printer.gcode.script",{script:e})}showDialogChanged(e){e&&(this.layer=this.current_layer+1,this.type="atLayer",this.existsSetPauseAtLayer||(this.type="nextLayer"))}typeChanged(e){e==="atLayer"?this.call=this.macroSettingsPauseAtLayerCall:e==="nextLayer"&&(this.call=this.macroSettingsPauseNextLayerCall)}};Au([w({required:!0})],Ai.prototype,"showDialog",2);Au([he("showDialog")],Ai.prototype,"showDialogChanged",1);Au([he("type")],Ai.prototype,"typeChanged",1);Ai=Au([S({components:{Panel:U,StatusPanelExcludeObjectDialogList:r0,StatusPanelExcludeObjectDialogMap:t0}})],Ai);var e9=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(le,{attrs:{width:"400",persistent:"",fullscreen:e.isMobile},model:{value:e.showDialog,callback:function(r){e.showDialog=r},expression:"showDialog"}},[t(U,{attrs:{title:e.$t("Panels.StatusPanel.PauseAtLayer.PauseAtLayer").toString(),icon:e.mdiLayersPlus,"card-class":"pause-at-layer-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.hideDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[e.type==="atLayer"&&e.macroSettingsPauseAtLayerEnable?t(x,[t(b,[t(it,{attrs:{text:"",type:"warning",border:"left"}},[e._v(" "+e._s(e.$t("Panels.StatusPanel.PauseAtLayer.DescriptionPauseAtLayerActive",{layer:e.macroSettingsPauseAtLayerLayer,call:e.macroSettingsPauseAtLayerCall}))+" ")])],1)],1):e._e(),e.type==="nextLayer"&&e.macroSettingsPauseNextLayerEnable?t(x,[t(b,[t(it,{attrs:{text:"",type:"warning",border:"left"}},[e._v(" "+e._s(e.$t("Panels.StatusPanel.PauseAtLayer.DescriptionPauseNextLayerActive",{call:e.macroSettingsPauseAtLayerCall}))+" ")])],1)],1):e._e(),t(x,[t(b,[t(ke,{attrs:{items:e.itemsFiltered,label:e.$t("Panels.StatusPanel.PauseAtLayer.Type"),outlined:"","hide-details":""},model:{value:e.type,callback:function(r){e.type=r},expression:"type"}})],1),e.type==="atLayer"?t(b,[t(se,{attrs:{label:e.$t("Panels.StatusPanel.PauseAtLayer.Layer"),outlined:"","hide-details":""},model:{value:e.layer,callback:function(r){e.layer=r},expression:"layer"}})],1):e._e()],1),t(x,{staticClass:"mt-0"},[t(b,[t(ke,{attrs:{items:e.itemsCall,label:e.$t("Panels.StatusPanel.PauseAtLayer.Call"),outlined:"","hide-details":""},model:{value:e.call,callback:function(r){e.call=r},expression:"call"}})],1)],1)],1),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.hideDialog}},[e._v(e._s(e.$t("Panels.StatusPanel.PauseAtLayer.Abort")))]),t(g,{attrs:{color:"primary",text:""},on:{click:e.sendCommand}},[e._v(" "+e._s(e.$t("Panels.StatusPanel.PauseAtLayer.Accept"))+" ")])],1)],1)],1)],1)},t9=[],s9=E(Ai,e9,t9,!1,null,"52377d67");const r9=s9.exports;var i9=Object.defineProperty,n9=Object.getOwnPropertyDescriptor,a0=(s,e,t,r)=>{for(var i=r>1?void 0:r?n9(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&i9(e,t,i),i};let Kl=class extends k(L){constructor(){super(...arguments),this.mdiAlertOutline=Jn,this.mdiCloseCircle=ol,this.mdiDotsVertical=mu,this.mdiFileDocumentMultipleOutline=Ga,this.mdiInformation=Ht,this.mdiHistory=nv,this.mdiMessageProcessingOutline=rS,this.mdiSpeedometer=Cv,this.mdiTrayFull=kv,this.showCancelJobDialog=!1,this.boolShowObjects=!1,this.boolShowPauseAtLayer=!1,this.activeTab="files",this.lastFilename=""}get jobs(){return this.$store.getters["server/jobQueue/getJobs"]}get jobsCount(){return this.$store.getters["server/jobQueue/getJobsCount"]}get jobQueueBadgeColor(){return this.jobsCount>0?"primary darken-2":"grey darken-2"}get current_filename(){var s,e;return(e=(s=this.$store.state.printer.print_stats)==null?void 0:s.filename)!=null?e:""}get current_file(){var s;return(s=this.$store.state.printer.current_file)!=null?s:{}}get printPercent(){return Math.floor(this.$store.getters["printer/getPrintPercent"]*100)}get printerStateOutput(){var s;if(this.printer_state!==""){const e=(s=this.$store.state.printer.idle_timeout)==null?void 0:s.state;return this.printer_state==="standby"&&e==="Printing"?"Busy":this.printer_state!==""&&["paused","printing"].includes(this.printer_state)?this.printPercent+"% "+this.printer_state.charAt(0).toUpperCase()+this.printer_state.slice(1):this.printer_state.charAt(0).toUpperCase()+this.printer_state.slice(1)}return this.$t("Panels.StatusPanel.Unknown")}get toolbarButtons(){return[{text:this.$t("Panels.StatusPanel.PausePrint"),color:"warning",icon:Zp,loadingName:"statusPrintPause",status:()=>["printing"].includes(this.printer_state),click:this.btnPauseJob},{text:this.$t("Panels.StatusPanel.ResumePrint"),color:"success",icon:nn,loadingName:"statusPrintResume",status:()=>["paused"].includes(this.printer_state),click:this.btnResumeJob},{text:this.$t("Panels.StatusPanel.CancelPrint"),color:"error",icon:$v,loadingName:"statusPrintCancel",status:()=>this.$store.state.gui.uiSettings.displayCancelPrint?["paused","printing"].includes(this.printer_state):["paused"].includes(this.printer_state),click:this.btnCancelJob},{text:this.$t("Panels.StatusPanel.ExcludeObject.ExcludeObject"),color:"warning",icon:cl,loadingName:"excludeObjectButton",status:()=>this.multiFunctionButton||this.printing_objects.length<2?!1:["paused","printing"].includes(this.printer_state),click:this.btnExcludeObject},{text:this.$t("Panels.StatusPanel.PauseAtLayer.PauseAtLayer"),color:"warning",icon:hm,loadingName:"pauseAtLayer",status:()=>this.multiFunctionButton||!this.displayPauseAtLayerButton?!1:["paused","printing"].includes(this.printer_state),click:this.btnPauseAtLayer},{text:this.$t("Panels.StatusPanel.ClearPrintStats"),color:"primary",icon:G_,loadingName:"statusPrintClear",status:()=>["error","complete","cancelled"].includes(this.printer_state),click:this.btnClearJob},{text:this.$t("Panels.StatusPanel.ReprintJob"),color:"primary",icon:Xp,loadingName:"statusPrintReprint",status:()=>["error","complete","cancelled"].includes(this.printer_state),click:this.btnReprintJob}]}get filteredToolbarButtons(){return this.toolbarButtons.filter(s=>s.status())}get printing_objects(){var s,e;return(e=(s=this.$store.state.printer.exclude_object)==null?void 0:s.objects)!=null?e:[]}get display_message(){var s,e;return(e=(s=this.$store.state.printer.display_status)==null?void 0:s.message)!=null?e:null}get print_stats_message(){var s,e;return(e=(s=this.$store.state.printer.print_stats)==null?void 0:s.message)!=null?e:null}get layer_count(){var s,e,t;return(t=(e=(s=this.$store.state.printer.print_stats)==null?void 0:s.info)==null?void 0:e.total_layer)!=null?t:null}get multiFunctionMenuButtons(){return[{text:this.$t("Panels.StatusPanel.ExcludeObject.ExcludeObject"),loadingName:"excludeObjectButton",icon:cl,status:()=>this.printing_objects.length>1,disabled:()=>["paused","printing"].includes(this.printer_state),click:this.btnExcludeObject},{text:this.$t("Panels.StatusPanel.PauseAtLayer.PauseAtLayer"),loadingName:"pauseAtLayer",icon:hm,status:()=>this.displayPauseAtLayerButton,disabled:()=>["paused","printing"].includes(this.printer_state),click:this.btnPauseAtLayer}]}get multiFunctionMenuButtonsFiltered(){return this.multiFunctionMenuButtons.filter(s=>s.status())}get multiFunctionButton(){return["paused","printing"].includes(this.printer_state)?this.multiFunctionMenuButtonsFiltered.length>1:!1}get macros(){var s;return(s=this.$store.getters["printer/getMacros"])!=null?s:[]}get existsSetPauseAtLayer(){return this.macros.findIndex(s=>s.name==="SET_PAUSE_AT_LAYER")!==-1}get existsSetPauseNextLayer(){return this.macros.findIndex(s=>s.name==="SET_PAUSE_NEXT_LAYER")!==-1}get displayPauseAtLayerButton(){return this.layer_count!==null&&(this.existsSetPauseAtLayer||this.existsSetPauseNextLayer)}get displayFilesTab(){var e;return((e=this.$store.state.gui.uiSettings.dashboardFilesLimit)!=null?e:5)>0}get displayHistoryTab(){var e;return((e=this.$store.state.gui.uiSettings.dashboardHistoryLimit)!=null?e:5)>0}mounted(){this.current_filename!==""&&(this.activeTab="status"),this.displayFilesTab||(this.activeTab="history"),this.displayHistoryTab||(this.activeTab="jobqueue")}current_filenameChanged(s){s===""?this.activeTab="files":this.lastFilename!==s&&(this.activeTab="status"),this.lastFilename=s}clearDisplayMessage(){this.$socket.emit("printer.gcode.script",{script:"M117"})}updateShowDialog(s){this.boolShowObjects=s}btnPauseJob(){this.$socket.emit("printer.print.pause",{},{loading:"statusPrintPause"})}btnResumeJob(){this.$socket.emit("printer.print.resume",{},{loading:"statusPrintResume"})}btnExcludeObject(){this.boolShowObjects=!0}btnPauseAtLayer(){this.boolShowPauseAtLayer=!0}btnCancelJob(){if(this.$store.state.gui.uiSettings.confirmOnCancelJob){this.showCancelJobDialog=!0;return}this.cancelJob()}cancelJob(){this.showCancelJobDialog=!1,this.$socket.emit("printer.print.cancel",{},{loading:"statusPrintCancel"})}btnClearJob(){this.$socket.emit("printer.gcode.script",{script:"SDCARD_RESET_FILE"},{loading:"statusPrintClear"})}btnReprintJob(){this.$socket.emit("printer.print.start",{filename:this.current_filename},{loading:"statusPrintReprint"})}};a0([he("current_filename")],Kl.prototype,"current_filenameChanged",1);Kl=a0([S({components:{CancelJobDialog:Ub,KlippyStatePanel:so,MinSettingsPanel:yf,Panel:U,StatusPanelExcludeObject:zE,StatusPanelGcodefiles:Kb,StatusPanelHistory:xE,StatusPanelJobqueue:zb,StatusPanelPrintstatus:dE,StatusPanelPrintstatusThumbnail:JE,StatusPanelPauseAtLayerDialog:r9}})],Kl);var a9=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(yf),t(so),e.klipperReadyForGui?t(U,{attrs:{icon:e.mdiInformation,title:e.printerStateOutput,collapsible:!0,"card-class":"status-panel"},scopedSlots:e._u([{key:"icon",fn:function(){return[["paused","printing"].includes(e.printer_state)?t(ot,{staticClass:"mr-3",attrs:{rotate:-90,size:30,width:5,value:e.printPercent,color:"primary"}}):e._e()]},proxy:!0},{key:"buttons",fn:function(){return[e._l(e.filteredToolbarButtons,function(r){return t(g,{key:r.loadingName,attrs:{color:r.color,loading:e.loadings.includes(r.loadingName),icon:"",tile:""},on:{click:r.click}},[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:i,attrs:n}){return[t(_,e._g(e._b({},"v-icon",n,!1),i),[e._v(e._s(r.icon))])]}}],null,!0)},[t("span",[e._v(e._s(r.text))])])],1)}),e.multiFunctionButton?t(ye,{staticClass:"pa-0",attrs:{left:"","offset-y":"","close-on-content-click":!1},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{icon:"",tile:""}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiDotsVertical))])],1)]}}],null,!1,2883138713)},[t(Me,{attrs:{dense:""}},e._l(e.multiFunctionMenuButtonsFiltered,function(r,i){return t(J,{key:"multiFunction_"+i},[t(g,{staticStyle:{width:"100%"},attrs:{small:""},on:{click:function(n){return r.click()}}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(r.icon))]),e._v(" "+e._s(r.text)+" ")],1)],1)}),1)],1):e._e()]},proxy:!0}],null,!1,3390704979)},[t("status-panel-printstatus-thumbnail"),t("status-panel-exclude-object",{attrs:{"show-dialog":e.boolShowObjects},on:{"update:showDialog":[function(r){e.boolShowObjects=r},e.updateShowDialog],"update:show-dialog":function(r){e.boolShowObjects=r}}}),t("status-panel-pause-at-layer-dialog",{attrs:{"show-dialog":e.boolShowPauseAtLayer},on:{"update:showDialog":function(r){e.boolShowPauseAtLayer=r},"update:show-dialog":function(r){e.boolShowPauseAtLayer=r}}}),e.print_stats_message?[t(Ee,[t(x,[t(b,{staticClass:"py-2"},[t("span",{staticClass:"subtitle-2 px-0 text--disabled"},[t(_,{staticClass:"mr-2 mt-1 float-left",attrs:{color:"warning",small:""}},[e._v(" "+e._s(e.mdiAlertOutline)+" ")]),e._v(" "+e._s(e.print_stats_message)+" ")],1)])],1)],1),t(I,{staticClass:"mt-0 mb-0"})]:e._e(),e.display_message?[t(Ee,[t(x,{staticClass:"flex-nowrap"},[t(b,{staticClass:"py-2",staticStyle:{"min-width":"0"}},[t("span",{staticClass:"subtitle-2 px-0 text--disabled"},[t(_,{staticClass:"mr-2 mt-1 float-left",attrs:{small:""}},[e._v(e._s(e.mdiMessageProcessingOutline))]),e._v(" "+e._s(e.display_message)+" ")],1)]),t(b,{staticClass:"col-auto py-2"},[t(_,{staticClass:"text--disabled cursor-pointer",attrs:{small:""},on:{click:e.clearDisplayMessage}},[e._v(" "+e._s(e.mdiCloseCircle)+" ")])],1)],1)],1),t(I,{staticClass:"mt-0 mb-0"})]:e._e(),t(rl,{attrs:{"fixed-tabs":""},model:{value:e.activeTab,callback:function(r){e.activeTab=r},expression:"activeTab"}},[e.current_filename?t(Dr,{attrs:{href:"#status"}},[t(_,[e._v(e._s(e.mdiSpeedometer))])],1):e._e(),e.displayFilesTab?t(Dr,{attrs:{href:"#files"}},[t(_,[e._v(e._s(e.mdiFileDocumentMultipleOutline))])],1):e._e(),e.displayHistoryTab?t(Dr,{attrs:{href:"#history"}},[t(_,[e._v(e._s(e.mdiHistory))])],1):e._e(),t(Dr,{attrs:{href:"#jobqueue"}},[t(O_,{attrs:{color:e.jobQueueBadgeColor,content:e.jobsCount.toString(),inline:!0}},[t(_,{attrs:{color:"disabled"}},[e._v(e._s(e.mdiTrayFull))])],1)],1)],1),t(I,{staticClass:"my-0"}),t(T_,{staticClass:"_border-radius",model:{value:e.activeTab,callback:function(r){e.activeTab=r},expression:"activeTab"}},[e.current_filename?t(Ys,{attrs:{value:"status"}},[t("status-panel-printstatus")],1):e._e(),e.displayFilesTab?t(Ys,{attrs:{value:"files"}},[t("status-panel-gcodefiles")],1):e._e(),e.displayHistoryTab?t(Ys,{attrs:{value:"history"}},[t("status-panel-history")],1):e._e(),t(Ys,{attrs:{value:"jobqueue"}},[t("status-panel-jobqueue")],1)],1)],2):e._e(),t(Ub,{attrs:{"show-dialog":e.showCancelJobDialog},on:{"cancel-job":e.cancelJob,close:function(r){e.showCancelJobDialog=!1}}})],1)},o9=[],l9=E(Kl,a9,o9,!1,null,"4d139ef7");const jn=l9.exports;var c9=Object.getOwnPropertyDescriptor,u9=(s,e,t,r)=>{for(var i=r>1?void 0:r?c9(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Fi=class extends y{get extruders(){return this.$store.getters["printer/getExtruders"]}get activeExtruder(){var s;return(s=this.$store.state.printer.toolhead)==null?void 0:s.extruder}get activeExtruderSettings(){var s,e;return(e=(s=this.$store.state.printer.configfile)==null?void 0:s.settings)==null?void 0:e[this.activeExtruder]}get filamentDiameter(){var s,e;return(e=(s=this.activeExtruderSettings)==null?void 0:s.filament_diameter)!=null?e:1.75}get nozzleDiameter(){var s,e;return(e=(s=this.activeExtruderSettings)==null?void 0:s.nozzle_diameter)!=null?e:.4}get feedamount(){return parseFloat(this.$store.state.gui.control.extruder.feedamount)}get feedrate(){return parseFloat(this.$store.state.gui.control.extruder.feedrate)}get extrudeFactor(){var s,e,t;return(t=(e=(s=this.$store.state.printer)==null?void 0:s.gcode_move)==null?void 0:e.extrude_factor)!=null?t:1}get extrudePossible(){return this.$store.getters["printer/getExtrudePossible"]}get minExtrudeTemp(){var s,e;return(e=(s=this.activeExtruderSettings)==null?void 0:s.min_extrude_temp)!=null?e:170}};Fi=u9([S],Fi);var d9=Object.getOwnPropertyDescriptor,m9=(s,e,t,r)=>{for(var i=r>1?void 0:r?d9(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let ah=class extends k(L,Fi){constructor(){super(...arguments),this.mdiDiameterVariant=Hw,this.mdiInformationOutline=ov}get showEstimatedExtrusion(){var e;return(e=this.$store.state.gui.control.extruder.showEstimatedExtrusionInfo)!=null?e:!0}get extrudedLength(){return Math.round(this.feedamount*this.extrudeFactor*(Math.pow(this.filamentDiameter,2)/Math.pow(this.nozzleDiameter,2)))}get speed_factor(){var e,t;return(t=(e=this.$store.state.printer.gcode_move)==null?void 0:e.speed_factor)!=null?t:1}get volumetricFlow(){return Math.round(Math.pow(this.filamentDiameter/2,2)*Math.PI*this.feedrate*this.speed_factor*10)/10}get showTooltip(){return this.speed_factor!==1||this.extrudeFactor!==1}get speedFactorOutput(){return(this.speed_factor*100).toFixed(0)}get extrudeFactorOutput(){return(this.extrudeFactor*100).toFixed(0)}};ah=m9([S({})],ah);var h9=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.showEstimatedExtrusion?t(Ee,{staticClass:"pa-0 ma-0 pb-2"},[t("div",{staticClass:"text--disabled text-caption font-weight-light d-flex justify-center",staticStyle:{"font-size":"0.8em"}},[t("span",[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.EstimatedExtrusion"))+" ~ "+e._s(e.extrudedLength)+" mm @ "+e._s(e.volumetricFlow)+" mm³/s - "),t(_,{staticStyle:{opacity:"0.4","margin-top":"-2px"},attrs:{"x-small":""}},[e._v(" "+e._s(e.mdiDiameterVariant)+" ")]),e._v(" "+e._s(e.nozzleDiameter)+" mm "),e.showTooltip?t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(_,e._g(e._b({attrs:{small:"",color:"warning"}},"v-icon",i,!1),r),[e._v(" "+e._s(e.mdiInformationOutline)+" ")])]}}],null,!1,3195294278)},[t("span",[e.speed_factor!==1?t("div",[e._v(" "+e._s(e.$t("Panels.ToolheadControlPanel.SpeedFactor"))+": "+e._s(e.speedFactorOutput)+" % ")]):e._e(),e.extrudeFactor!==1?t("div",[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.ExtrusionFactor"))+": "+e._s(e.extrudeFactorOutput)+" % ")]):e._e()])]):e._e()],1)])]):e._e()},p9=[],f9=E(ah,h9,p9,!1,null,null);const g9=f9.exports;var _9=Object.defineProperty,v9=Object.getOwnPropertyDescriptor,xt=(s,e,t,r)=>{for(var i=r>1?void 0:r?v9(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&_9(e,t,i),i};let dt=class extends k(L){constructor(){super(...arguments),this.mdiRestart=_r,this.mdiChevronUp=du,this.mdiChevronDown=fr,this.value="0",this.error=!1,this.invalidChars=["e","E","+"]}created(){this.value=this.target.toString()}updateTarget(){this.value=this.target.toString()}incrementValue(){this.inputValue+this.step*this.spinnerFactor<this.max||this.max===null?this.value=(Math.round((this.inputValue+this.step*this.spinnerFactor)*10**this.dec)/10**this.dec).toString():this.value=this.max.toString(),this.submit()}decrementValue(){this.inputValue-this.step*this.spinnerFactor>this.min?this.value=(Math.round((this.inputValue-this.step*this.spinnerFactor)*10**this.dec)/10**this.dec).toString():this.value=this.min.toString(),this.submit()}resetToDefault(){this.value=this.defaultValue.toString(),this.submit()}submit(){this.invalidInput||this.$emit("submit",{name:this.param,value:this.inputValue})}checkInvalidChars(s){this.min>=0&&this.invalidChars.push("-"),this.invalidChars.includes(s.key)&&s.preventDefault()}get inputValue(){return this.value.toString()===""?0:parseFloat(this.value.replace(",","."))}get invalidInput(){return this.inputErrors.length>0}get inputErrors(){if(!this.outputErrorMsg)return[];const s=[];return this.max===null&&this.inputValue<this.min&&s.push(this.$t("App.NumberInput.GreaterOrEqualError",{min:this.min})),this.max!==null&&(this.inputValue>this.max||this.inputValue<this.min)&&s.push(this.$t("App.NumberInput.MustBeBetweenError",{min:this.min,max:this.max})),s}};xt([w({required:!0})],dt.prototype,"label",2);xt([w({type:String,required:!0})],dt.prototype,"param",2);xt([w({type:Number,required:!0})],dt.prototype,"target",2);xt([w({type:Number,required:!1})],dt.prototype,"defaultValue",2);xt([w({type:Number,required:!0})],dt.prototype,"min",2);xt([w({default:null})],dt.prototype,"max",2);xt([w({type:Number,required:!0})],dt.prototype,"dec",2);xt([w({type:Number,required:!1,default:1})],dt.prototype,"step",2);xt([w({type:String,required:!1})],dt.prototype,"unit",2);xt([w({type:Boolean,required:!1,default:!1})],dt.prototype,"hasSpinner",2);xt([w({type:Number,required:!1,default:1})],dt.prototype,"spinnerFactor",2);xt([w({type:Boolean,required:!1,default:!1})],dt.prototype,"disabled",2);xt([w({type:Boolean,required:!1,default:!1})],dt.prototype,"outputErrorMsg",2);xt([he("target")],dt.prototype,"updateTarget",1);dt=xt([S],dt);var b9=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("form",{on:{submit:function(r){return r.preventDefault(),e.submit.apply(null,arguments)}}},[t(se,{staticClass:"d-flex align-top",attrs:{label:e.label,suffix:e.unit,error:e.invalidInput,"error-messages":e.inputErrors,disabled:e.disabled,step:e.step,min:e.min,max:e.max,dec:e.dec,"hide-spin-buttons":"","hide-details":"auto",outlined:"",dense:""},on:{blur:function(r){e.value=e.target.toString()},focus:function(r){return r.target.select()},keydown:e.checkInvalidChars},scopedSlots:e._u([e.defaultValue?{key:"append",fn:function(){return[t(_,{on:{click:e.resetToDefault}},[e._v(e._s(e.value!==e.defaultValue.toString()?e.mdiRestart:""))])]},proxy:!0}:null,e.hasSpinner?{key:"append-outer",fn:function(){return[t("div",{staticClass:"_spin_button_group"},[t(g,{staticClass:"mt-n3",attrs:{disabled:e.value>=e.max&&e.max!==null||e.error||e.disabled,icon:"",plain:"",small:""},on:{click:e.incrementValue}},[t(_,[e._v(e._s(e.mdiChevronUp))])],1),t(g,{staticClass:"mb-n3",attrs:{disabled:e.value<=e.min||e.error||e.disabled,icon:"",plain:"",small:""},on:{click:e.decrementValue}},[t(_,[e._v(e._s(e.mdiChevronDown))])],1)],1)]},proxy:!0}:null],null,!0),model:{value:e.value,callback:function(r){e.value=r},expression:"value"}})],1)},y9=[],C9=E(dt,b9,y9,!1,null,"bfe880f2");const He=C9.exports;var $9=Object.defineProperty,x9=Object.getOwnPropertyDescriptor,st=(s,e,t,r)=>{for(var i=r>1?void 0:r?x9(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&$9(e,t,i),i};let qe=class extends k(L){constructor(){super(...arguments),this.mdiRestart=_r,this.mdiLockOutline=fu,this.mdiLockOpenVariantOutline=uv,this.mdiMinus=mv,this.mdiPlus=qp,this.isLocked=!1,this.invalidChars=["e","E","+"],this.value=0,this.numInput=0,this.startValue=0,this.processedMax=100,this.dynamicStep=50}created(){this.value=this.target*this.multi,this.numInput=this.value,this.startValue=this.target*this.multi,this.dynamicStep=Math.floor(this.max/2),this.value>=this.processedMax&&(this.processedMax=(Math.ceil(this.value/this.dynamicStep)+1)*this.dynamicStep)}lockSlidersChanged(){this.isLocked=this.lockSliders&&this.isTouchDevice}startLockTimer(){let s=this.lockSlidersDelay;!this.isTouchDevice||!this.lockSliders||s<=0||(this.timeout=setTimeout(()=>this.isLocked=!0,s*1e3))}resetLockTimer(){clearTimeout(this.timeout)}get lockSliders(){return this.$store.state.gui.uiSettings.lockSlidersOnTouchDevices}get lockSlidersDelay(){return this.$store.state.gui.uiSettings.lockSlidersDelay}get colorBar(){return this.max<this.value?"warning":"primary"}changeSlider(){this.sendCmd(),this.dynamicRange&&this.value>=this.processedMax&&(this.processedMax=this.value+this.dynamicStep)}valueChanged(s){this.numInput=s}targetChanged(s){this.value=Math.round(s*this.multi),this.dynamicRange&&this.value>=this.processedMax&&(this.processedMax=this.value+this.dynamicStep)}maxChanged(s){this.processedMax=s>this.value?s:Math.ceil(this.value/this.dynamicStep)*this.dynamicStep}checkInvalidChars(s){this.min>=0&&this.invalidChars.push("-"),this.invalidChars.includes(s.key)&&s.preventDefault()}errors(){const s=[];return this.numInput.toString()===""&&s.push(this.$t("App.NumberInput.NoEmptyAllowedError")),this.numInput<this.min&&s.push(this.$t("App.NumberInput.GreaterOrEqualError",{min:this.min})),(!this.dynamicRange&&this.numInput>this.max||this.numInput<this.min)&&s.push(this.$t("App.NumberInput.MustBeBetweenError",{min:this.min,max:this.max})),s}submitInput(){this.errors().length>0||(!this.dynamicRange&&this.numInput>this.max?this.value=this.max:this.value=this.numInput,this.sendCmd())}resetSlider(){this.value=this.defaultValue,this.numInput=this.defaultValue,this.processedMax=this.max,this.value>=this.processedMax&&(this.processedMax=(Math.ceil(this.value/this.dynamicStep)+1)*this.dynamicStep),this.sendCmd()}sendCmd(){const s=(Math.max(1,this.value)*this.attributeScale).toFixed(0),e="".concat(this.command," ").concat(this.attributeName).concat(s);this.$store.dispatch("server/addEvent",{message:e,type:"command"}),this.$socket.emit("printer.gcode.script",{script:e}),this.startLockTimer()}decrement(){this.value=this.value>this.min?Math.round(this.value-this.step):this.min,this.sendCmd()}increment(){this.value=this.value<this.processedMax||this.dynamicRange?Math.round(this.value+this.step):this.processedMax,this.sendCmd()}};st([w({type:Number,required:!0})],qe.prototype,"target",2);st([w({type:String,required:!0})],qe.prototype,"command",2);st([w({type:String,default:""})],qe.prototype,"attributeName",2);st([w({default:""})],qe.prototype,"label",2);st([w({type:String,default:""})],qe.prototype,"icon",2);st([w({type:String,default:"%"})],qe.prototype,"unit",2);st([w({type:Number,default:1})],qe.prototype,"attributeScale",2);st([w({type:Number,default:0})],qe.prototype,"min",2);st([w({type:Number,default:100})],qe.prototype,"max",2);st([w({type:Boolean,required:!1,default:!1})],qe.prototype,"hasInputField",2);st([w({type:Boolean,default:!1})],qe.prototype,"dynamicRange",2);st([w({type:Number,default:100})],qe.prototype,"defaultValue",2);st([w({type:Number,default:100})],qe.prototype,"step",2);st([w({type:Number,default:1})],qe.prototype,"multi",2);st([he("lockSliders",{immediate:!0})],qe.prototype,"lockSlidersChanged",1);st([Ke(250)],qe.prototype,"changeSlider",1);st([he("value",{immediate:!0})],qe.prototype,"valueChanged",1);st([he("target",{immediate:!0})],qe.prototype,"targetChanged",1);st([he("max",{immediate:!0})],qe.prototype,"maxChanged",1);qe=st([S],qe);var w9=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,{attrs:{dense:""}},[t(b,{staticClass:"pa-0"},[t(cs,{staticClass:"_tool-slider-subheader px-1"},[t(_,{staticClass:"mr-2",attrs:{small:""}},[e._v(" "+e._s(e.icon)+" ")]),t("span",[e._v(e._s(e.label))]),e.value!==e.defaultValue&&!e.hasInputField?t(g,{staticClass:"ml-2",attrs:{"x-small":"",icon:"",disabled:e.isLocked},on:{click:e.resetSlider}},[t(_,[e._v(e._s(e.mdiRestart))])],1):e._e(),t(ae),e.hasInputField?e._e():t("span",{staticClass:"font-weight-bold"},[e._v(e._s(e.value)+" "+e._s(e.unit))]),t("form",{on:{submit:function(r){return r.preventDefault(),e.submitInput.apply(null,arguments)}}},[e.hasInputField?t(se,{staticClass:"_slider-input d-flex align-center pt-1",attrs:{error:e.errors().length>0,suffix:e.unit,type:"number","hide-spin-buttons":"","hide-details":"",outlined:"",dense:""},on:{blur:function(r){e.numInput=e.value},focus:function(r){return r.target.select()},keydown:e.checkInvalidChars},scopedSlots:e._u([e.value!==e.defaultValue||e.value!==e.numInput?{key:"append",fn:function(){return[t(_,{attrs:{small:""},on:{click:e.resetSlider}},[e._v(e._s(e.mdiRestart))])]},proxy:!0}:null],null,!0),model:{value:e.numInput,callback:function(r){e.numInput=r},expression:"numInput"}}):e._e()],1)],1),t("transition",{attrs:{name:"fade"}},[t("div",{directives:[{name:"show",rawName:"v-show",value:e.errors().length>0,expression:"errors().length > 0"}],staticClass:"_error-msg d-flex justify-end"},[e._v(" "+e._s(e.errors()[0])+" ")])]),t(Z,{staticClass:"pa-0 d-flex align-center"},[e.lockSliders&&e.isTouchDevice?t(g,{staticClass:"_lock-button",attrs:{plain:"",small:"",icon:""},on:{click:function(r){e.isLocked=!e.isLocked}}},[t(_,{attrs:{small:"",color:e.isLocked?"red":""}},[e._v(" "+e._s(e.isLocked?e.mdiLockOutline:e.mdiLockOpenVariantOutline)+" ")])],1):e._e(),t(Lr,{directives:[{name:"touch",rawName:"v-touch",value:{start:e.resetLockTimer},expression:"{ start: resetLockTimer }"}],attrs:{disabled:e.isLocked,min:e.min,max:e.processedMax,color:e.colorBar,"hide-details":""},on:{change:e.changeSlider},scopedSlots:e._u([{key:"prepend",fn:function(){return[t(_,{attrs:{disabled:e.isLocked||e.value<=e.min},on:{click:e.decrement}},[e._v(e._s(e.mdiMinus))])]},proxy:!0},{key:"append",fn:function(){return[t(_,{attrs:{disabled:e.isLocked||e.value>=e.max&&!e.dynamicRange},on:{click:e.increment}},[e._v(" "+e._s(e.mdiPlus)+" ")])]},proxy:!0}]),model:{value:e.value,callback:function(r){e.value=r},expression:"value"}})],1)],1)],1)},S9=[],P9=E(qe,w9,S9,!1,null,"0e034f01");const Fu=P9.exports;var D9=Object.defineProperty,T9=Object.getOwnPropertyDescriptor,o0=(s,e,t,r)=>{for(var i=r>1?void 0:r?T9(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&D9(e,t,i),i};let Ql=class extends k(L,Fi){constructor(){super(...arguments),this.mdiArrowDownBold=pw,this.mdiArrowUpBold=gw,this.mdiPrinter3dNozzle=Us}get feedamounts(){var e,t;return(t=(e=this.$store.state.gui.control.extruder)==null?void 0:e.feedamounts)!=null?t:[]}get feedrates(){var e,t;return(t=(e=this.$store.state.gui.control.extruder)==null?void 0:e.feedrates)!=null?t:[]}get feedamountsSorted(){return[...this.feedamounts].sort((e,t)=>t-e)}get feedratesSorted(){return[...this.feedrates].sort((e,t)=>t-e)}setFeedamount(e){this.$store.dispatch("gui/saveSetting",{name:"control.extruder.feedamount",value:e.value})}setFeedrate(e){this.$store.dispatch("gui/saveSetting",{name:"control.extruder.feedrate",value:e.value})}get maxExtrudeOnlyDistance(){var e,t;return(t=(e=this.activeExtruderSettings)==null?void 0:e.max_extrude_only_distance)!=null?t:50}get tooLargeExtrusion(){return this.feedamount*this.extrudeFactor>this.maxExtrudeOnlyDistance}get existsClientLinearMoveMacro(){var t,r,i;return"_CLIENT_LINEAR_MOVE"in((i=(r=(t=this.$store.state.printer)==null?void 0:t.gcode)==null?void 0:r.commands)!=null?i:{})}onMaxExtrudeOnlyDistanceChange(){this.feedamount>this.maxExtrudeOnlyDistance&&this.setFeedamount({value:this.maxExtrudeOnlyDistance})}sendRetract(){this.sendCommand(this.feedamount*-1,"btnRetract")}sendExtrude(){this.sendCommand(this.feedamount,"btnExtrude")}sendCommand(e,t){let r="SAVE_GCODE_STATE NAME=_ui_extrude\nM83\nG1 E".concat(e," F").concat(this.feedrate*60,"\nRESTORE_GCODE_STATE NAME=_ui_extrude");this.existsClientLinearMoveMacro&&(r="_CLIENT_LINEAR_MOVE E=".concat(e," F=").concat(this.feedrate*60)),this.$store.dispatch("server/addEvent",{message:r,type:"command"}),this.$socket.emit("printer.gcode.script",{script:r},{loading:t})}};o0([he("maxExtrudeOnlyDistance",{immediate:!0})],Ql.prototype,"onMaxExtrudeOnlyDistanceChange",1);Ql=o0([S({components:{NumberInput:He,Responsive:tt,ToolSlider:Fu}})],Ql);var O9=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(tt,{attrs:{breakpoints:{large:r=>r.width>=640}},scopedSlots:e._u([{key:"default",fn:function({el:r}){return[t(Ee,[t(x,[t(b,[t(He,{attrs:{label:e.$t("Panels.ExtruderControlPanel.FilamentLength"),param:"feedamount",target:e.feedamount,disabled:e.printerIsPrintingOnly,"output-error-msg":!0,"has-spinner":!0,"spinner-factor":100,step:.01,min:.01,max:e.maxExtrudeOnlyDistance,dec:2,unit:"mm","submit-on-blur":!0},on:{submit:e.setFeedamount}}),t(Wt,{staticClass:"_btn-group pt-3"},e._l(e.feedamountsSorted,function(i){return t(g,{key:i,staticClass:"_btn-qs flex-grow-1 px-0",attrs:{disabled:e.printerIsPrintingOnly,dense:""},on:{click:function(n){return e.setFeedamount({value:i})}}},[e._v(" "+e._s(i)+" ")])}),1)],1),t(b,[t(He,{attrs:{label:e.$t("Panels.ExtruderControlPanel.ExtrusionFeedrate"),param:"feedrate",target:e.feedrate,disabled:e.printerIsPrintingOnly,"has-spinner":!0,"output-error-msg":!0,"spinner-factor":100,step:.01,min:.01,max:null,dec:2,type:"number",unit:"mm/s"},on:{submit:e.setFeedrate}}),t(Wt,{staticClass:"_btn-group pt-3"},e._l(e.feedratesSorted,function(i){return t(g,{key:i,staticClass:"_btn-qs flex-grow-1 px-0",attrs:{disabled:e.printerIsPrintingOnly,dense:""},on:{click:function(n){return e.setFeedrate({value:i})}}},[e._v(" "+e._s(i)+" ")])}),1)],1),r.is.large?t(b,{staticClass:"col-3 d-flex align-center flex-column justify-center"},[t(de,{attrs:{left:"",disabled:e.extrudePossible&&!e.tooLargeExtrusion,color:"secondary"},scopedSlots:e._u([{key:"activator",fn:function({on:i}){return[t("div",e._g({staticClass:"mb-4"},i),[t(g,{staticClass:"_btn-extruder-cmd",attrs:{loading:e.loadings.includes("btnRetract"),disabled:!e.extrudePossible||e.tooLargeExtrusion||e.printerIsPrintingOnly,small:""},on:{click:function(n){return e.sendRetract()}}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiArrowUpBold))]),e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.Retract"))+" ")],1)],1)]}}],null,!0)},[t("span",{directives:[{name:"show",rawName:"v-show",value:!e.extrudePossible,expression:"!extrudePossible"}]},[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.ExtruderTempTooLow"))+" "+e._s(e.minExtrudeTemp)+" °C ")]),t("span",{directives:[{name:"show",rawName:"v-show",value:e.tooLargeExtrusion,expression:"tooLargeExtrusion"}]},[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.TooLargeExtrusion"))+" "),t("br"),e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.Requested"))+": "+e._s(e.feedamount*e.extrudeFactor)+" mm "),t("br"),e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.Allowed"))+": "+e._s(e.maxExtrudeOnlyDistance)+" mm ")])]),t(de,{attrs:{left:"",disabled:e.extrudePossible&&!e.tooLargeExtrusion,color:"secondary"},scopedSlots:e._u([{key:"activator",fn:function({on:i}){return[t("div",e._g({},i),[t(g,{staticClass:"_btn-extruder-cmd",attrs:{loading:e.loadings.includes("btnExtrude"),disabled:!e.extrudePossible||e.tooLargeExtrusion||e.printerIsPrintingOnly,small:""},on:{click:function(n){return e.sendExtrude()}}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiArrowDownBold))]),e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.Extrude"))+" ")],1)],1)]}}],null,!0)},[t("span",{directives:[{name:"show",rawName:"v-show",value:!e.extrudePossible,expression:"!extrudePossible"}]},[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.ExtruderTempTooLow"))+" "+e._s(e.minExtrudeTemp)+" °C ")]),t("span",{directives:[{name:"show",rawName:"v-show",value:e.tooLargeExtrusion,expression:"tooLargeExtrusion"}]},[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.TooLargeExtrusion"))+" "),t("br"),e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.Requested"))+": "+e._s(e.feedamount*e.extrudeFactor)+" mm "),t("br"),e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.Allowed"))+": "+e._s(e.maxExtrudeOnlyDistance)+" mm ")])])],1):e._e()],1),r.is.large?e._e():t(x,[t(b,{staticClass:"pa-0"},[t("div",{staticClass:"d-flex justify-space-around"},[t("div",{staticClass:"d-flex align-center"},[t(de,{attrs:{top:"",disabled:e.extrudePossible&&!e.tooLargeExtrusion,color:"secondary"},scopedSlots:e._u([{key:"activator",fn:function({on:i}){return[t("div",e._g({staticClass:"pt-1 pb-2 px-3"},i),[t(g,{staticClass:"_btn-extruder-cmd",attrs:{loading:e.loadings.includes("btnRetract"),disabled:!e.extrudePossible||e.tooLargeExtrusion||e.printerIsPrintingOnly,small:""},on:{click:function(n){return e.sendRetract()}}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiArrowUpBold))]),e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.Retract"))+" ")],1)],1)]}}],null,!0)},[t("span",{directives:[{name:"show",rawName:"v-show",value:!e.extrudePossible,expression:"!extrudePossible"}]},[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.ExtruderTempTooLow"))+" "+e._s(e.minExtrudeTemp)+" °C ")]),t("span",{directives:[{name:"show",rawName:"v-show",value:e.tooLargeExtrusion,expression:"tooLargeExtrusion"}]},[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.TooLargeExtrusion"))+" "),t("br"),e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.Requested"))+": "+e._s(e.feedamount*e.extrudeFactor)+" mm "),t("br"),e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.Allowed"))+": "+e._s(e.maxExtrudeOnlyDistance)+" mm ")])]),t(de,{attrs:{top:"",disabled:e.extrudePossible&&!e.tooLargeExtrusion,color:"secondary"},scopedSlots:e._u([{key:"activator",fn:function({on:i}){return[t("div",e._g({staticClass:"pt-1 pb-2 px-3"},i),[t(g,{staticClass:"_btn-extruder-cmd",attrs:{loading:e.loadings.includes("btnExtrude"),disabled:!e.extrudePossible||e.tooLargeExtrusion||e.printerIsPrintingOnly,small:""},on:{click:function(n){return e.sendExtrude()}}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiArrowDownBold))]),e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.Extrude"))+" ")],1)],1)]}}],null,!0)},[t("span",{directives:[{name:"show",rawName:"v-show",value:!e.extrudePossible,expression:"!extrudePossible"}]},[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.ExtruderTempTooLow"))+" "+e._s(e.minExtrudeTemp)+" °C ")]),t("span",{directives:[{name:"show",rawName:"v-show",value:e.tooLargeExtrusion,expression:"tooLargeExtrusion"}]},[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.TooLargeExtrusion"))+" "),t("br"),e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.Requested"))+": "+e._s(e.feedamount*e.extrudeFactor)+" mm "),t("br"),e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.Allowed"))+": "+e._s(e.maxExtrudeOnlyDistance)+" mm ")])])],1)])])],1)],1),t(g9)]}}])})},M9=[],k9=E(Ql,O9,M9,!1,null,"1b2327b2");const E9=k9.exports;var L9=Object.defineProperty,A9=Object.getOwnPropertyDescriptor,l0=(s,e,t,r)=>{for(var i=r>1?void 0:r?A9(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&L9(e,t,i),i};let ec=class extends k(L,Je){get retractLength(){var s,e,t;return Math.floor(((t=(e=(s=this.$store.state.printer)==null?void 0:s.firmware_retraction)==null?void 0:e.retract_length)!=null?t:0)*100)/100}get retractSpeed(){var s,e,t;return Math.trunc((t=(e=(s=this.$store.state.printer)==null?void 0:s.firmware_retraction)==null?void 0:e.retract_speed)!=null?t:20)}get unretractExtraLength(){var s,e,t;return Math.floor(((t=(e=(s=this.$store.state.printer)==null?void 0:s.firmware_retraction)==null?void 0:e.unretract_extra_length)!=null?t:0)*100)/100}get unretractSpeed(){var s,e,t;return Math.trunc((t=(e=(s=this.$store.state.printer)==null?void 0:s.firmware_retraction)==null?void 0:e.unretract_speed)!=null?t:10)}get defaultRetractLength(){var s,e,t,r,i;return Math.floor(((i=(r=(t=(e=(s=this.$store.state.printer)==null?void 0:s.configfile)==null?void 0:e.settings)==null?void 0:t.firmware_retraction)==null?void 0:r.retract_length)!=null?i:0)*100)/100}get defaultRetractSpeed(){var s,e,t,r,i;return Math.trunc((i=(r=(t=(e=(s=this.$store.state.printer)==null?void 0:s.configfile)==null?void 0:e.settings)==null?void 0:t.firmware_retraction)==null?void 0:r.retract_speed)!=null?i:20)}get defaultUnretractExtraLength(){var s,e,t,r,i;return Math.floor(((i=(r=(t=(e=(s=this.$store.state.printer)==null?void 0:s.configfile)==null?void 0:e.settings)==null?void 0:t.firmware_retraction)==null?void 0:r.unretract_extra_length)!=null?i:0)*100)/100}get defaultUnretractSpeed(){var s,e,t,r,i;return Math.trunc((i=(r=(t=(e=(s=this.$store.state.printer)==null?void 0:s.configfile)==null?void 0:e.settings)==null?void 0:t.firmware_retraction)==null?void 0:r.unretract_speed)!=null?i:0)}sendCmd(s){const e="SET_RETRACTION ".concat(s.name,"=").concat(s.value);this.$store.dispatch("server/addEvent",{message:e,type:"command"}),this.$socket.emit("printer.gcode.script",{script:e})}};l0([Ke(500)],ec.prototype,"sendCmd",1);ec=l0([S({components:{Panel:U,NumberInput:He,Responsive:tt}})],ec);var F9=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.existsFirmwareRetraction?t("div",[t(Ee,[t(tt,{attrs:{breakpoints:{small:r=>r.width<=350}},scopedSlots:e._u([{key:"default",fn:function({el:r}){return[t(x,[t(b,{class:{"col-12":r.is.small}},[t(He,{attrs:{label:e.$t("Panels.ExtruderControlPanel.FirmwareRetractionSettings.RetractLength"),param:"RETRACT_LENGTH",target:e.retractLength,"default-value":e.defaultRetractLength,"output-error-msg":!0,"has-spinner":!0,"spinner-factor":10,step:.01,min:0,max:null,dec:2,unit:"mm"},on:{submit:e.sendCmd}})],1),t(b,{class:{"col-12":r.is.small}},[t(He,{attrs:{label:e.$t("Panels.ExtruderControlPanel.FirmwareRetractionSettings.RetractSpeed"),param:"RETRACT_SPEED",target:e.retractSpeed,"default-value":e.defaultRetractSpeed,"output-error-msg":!0,"has-spinner":!0,"spinner-factor":5,step:1,min:1,max:null,dec:0,unit:"mm/s"},on:{submit:e.sendCmd}})],1)],1),t(x,[t(b,{class:{"col-12":r.is.small}},[t(He,{attrs:{label:e.$t("Panels.ExtruderControlPanel.FirmwareRetractionSettings.UnretractExtraLength"),param:"UNRETRACT_EXTRA_LENGTH",target:e.unretractExtraLength,"default-value":e.defaultUnretractExtraLength,"output-error-msg":!0,"has-spinner":!0,"spinner-factor":10,step:.01,min:0,max:null,dec:2,unit:"mm"},on:{submit:e.sendCmd}})],1),t(b,{class:{"col-12":r.is.small}},[t(He,{attrs:{label:e.$t("Panels.ExtruderControlPanel.FirmwareRetractionSettings.UnretractSpeed"),param:"UNRETRACT_SPEED",target:e.unretractSpeed,"default-value":e.defaultUnretractSpeed,"output-error-msg":!0,"has-spinner":!0,"spinner-factor":5,step:1,min:1,max:null,dec:0,unit:"mm/s"},on:{submit:e.sendCmd}})],1)],1)]}}],null,!1,259554286)})],1)],1):e._e()},R9=[],H9=E(ec,F9,R9,!1,null,null);const j9=H9.exports;var I9=Object.defineProperty,N9=Object.getOwnPropertyDescriptor,c0=(s,e,t,r)=>{for(var i=r>1?void 0:r?N9(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&I9(e,t,i),i};let tc=class extends k(L){constructor(){super(...arguments),this.mdiRestart=_r,this.extruders=[],this.selectedExtruder=""}resetToActiveExtruder(){var e;this.selectedExtruder=(e=this.$store.state.printer.toolhead)==null?void 0:e.extruder}get allExtruders(){return Object.keys(this.$store.state.printer).forEach(e=>{e.startsWith("extruder")&&!this.extruders.includes(e)&&this.extruders.push(e)}),this.extruders.length===1&&this.resetToActiveExtruder(),this.extruders}get activeExtruder(){var e;return this.resetToActiveExtruder(),(e=this.$store.state.printer.toolhead)==null?void 0:e.extruder}get pressureAdvance(){var e,t,r;return Math.floor(((r=(t=(e=this.$store.state.printer)==null?void 0:e[this.selectedExtruder])==null?void 0:t.pressure_advance)!=null?r:0)*1e3)/1e3}get smoothTime(){var e,t,r;return Math.floor(((r=(t=(e=this.$store.state.printer)==null?void 0:e[this.selectedExtruder])==null?void 0:t.smooth_time)!=null?r:.04)*1e3)/1e3}get defaultPressureAdvance(){var e,t,r,i;return Math.floor(((i=(r=(t=(e=this.$store.state.printer.configfile)==null?void 0:e.settings)==null?void 0:t[this.selectedExtruder])==null?void 0:r.pressure_advance)!=null?i:0)*1e3)/1e3}get defaultSmoothTime(){var e,t,r,i;return Math.floor(((i=(r=(t=(e=this.$store.state.printer.configfile)==null?void 0:e.settings)==null?void 0:t[this.selectedExtruder])==null?void 0:r.pressure_advance_smooth_time)!=null?i:.04)*1e3)/1e3}sendCmd(e){const t="SET_PRESSURE_ADVANCE EXTRUDER=".concat(this.selectedExtruder," ").concat(e.name,"=").concat(e.value);this.$store.dispatch("server/addEvent",{message:t,type:"command"}),this.$socket.emit("printer.gcode.script",{script:t})}};c0([Ke(500)],tc.prototype,"sendCmd",1);tc=c0([S({components:{NumberInput:He,Panel:U,Responsive:tt}})],tc);var V9=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(tt,{attrs:{breakpoints:{small:r=>r.width<=350,medium:r=>r.width>350&&r.width<=500}},scopedSlots:e._u([{key:"default",fn:function({el:r}){return[t(Ee,[t(x,[e.allExtruders.length>1?t(b,{class:{"col-12":r.is.small||r.is.medium}},[t("div",{staticClass:"d-flex align-center"},[e.selectedExtruder!==e.activeExtruder?t(g,{attrs:{icon:"",plain:""},on:{click:e.resetToActiveExtruder}},[t(_,[e._v(e._s(e.mdiRestart))])],1):e._e(),t(ke,{attrs:{label:e.$t("Panels.ExtruderControlPanel.PressureAdvanceSettings.Extruder"),items:e.allExtruders,value:e.activeExtruder,"hide-details":"",outlined:"",dense:""},model:{value:e.selectedExtruder,callback:function(i){e.selectedExtruder=i},expression:"selectedExtruder"}})],1)]):e._e(),t(b,{class:{"col-12":r.is.small}},[t(He,{attrs:{label:e.$t("Panels.ExtruderControlPanel.PressureAdvanceSettings.Advance"),param:"ADVANCE",target:e.pressureAdvance,"default-value":e.defaultPressureAdvance,extruder:e.selectedExtruder,"output-error-msg":!0,"has-spinner":!0,min:0,max:null,step:.001,dec:3,unit:"s"},on:{submit:e.sendCmd}})],1),t(b,{class:{"col-12":r.is.small}},[t(He,{attrs:{label:e.$t("Panels.ExtruderControlPanel.PressureAdvanceSettings.SmoothTime"),param:"SMOOTH_TIME",target:e.smoothTime,"default-value":e.defaultSmoothTime,extruder:e.selectedExtruder,"output-error-msg":!0,"has-spinner":!0,"spinner-factor":10,min:0,max:.2,step:.001,dec:3,unit:"s"},on:{submit:e.sendCmd}})],1)],1)],1)]}}])})},B9=[],U9=E(tc,V9,B9,!1,null,null);const W9=U9.exports;var z9=Object.getOwnPropertyDescriptor,G9=(s,e,t,r)=>{for(var i=r>1?void 0:r?z9(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let oh=class extends k(L,Fi){constructor(){super(...arguments),this.mdiPrinter3dNozzleOutline=pS}};oh=G9([S({})],oh);var Z9=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Ee,[t(Fu,{attrs:{label:e.$t("Panels.ExtruderControlPanel.ExtrusionFactor"),icon:e.mdiPrinter3dNozzleOutline,target:e.extrudeFactor,min:1,max:200,multi:100,step:1,"has-input-field":!0,command:"M221","attribute-name":"S"}})],1)},q9=[],X9=E(oh,Z9,q9,!1,null,null);const Y9=X9.exports;var J9=Object.defineProperty,K9=Object.getOwnPropertyDescriptor,u0=(s,e,t,r)=>{for(var i=r>1?void 0:r?K9(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&J9(e,t,i),i};let sc=class extends k(L,Je){get macro(){var t;const e=Object.keys(this.$store.state.printer).find(r=>{var i;return r.toLowerCase()==="gcode_macro ".concat((i=this.name)==null?void 0:i.toLowerCase())});if(e)return(t=this.$store.state.printer[e])!=null?t:{}}get active(){var e,t;return(t=(e=this.macro)==null?void 0:e.active)!=null?t:!1}get color(){var t,r,i,n,a,o;if(this.spool)return(r=(t=this.spool.filament)==null?void 0:t.color_hex)!=null?r:"000000";const e=(o=(a=(i=this.macro)==null?void 0:i.color)!=null?a:(n=this.macro)==null?void 0:n.colour)!=null?o:null;return e===""||e==="undefined"?null:e}get spoolId(){var e,t;return(t=(e=this.macro)==null?void 0:e.spool_id)!=null?t:null}get spool(){var t,r;return(r=((t=this.$store.state.server.spoolman.spools)!=null?t:[]).find(i=>i.id===this.spoolId))!=null?r:null}get primaryColor(){return this.$store.state.gui.uiSettings.primary}get primaryTextColor(){let e=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(this.primaryColor);if(e){const t=parseInt(e[1],16)*.2126,r=parseInt(e[2],16)*.7152,i=parseInt(e[3],16)*.0722;return(t+r+i)/255>.7?"#222":"#fff"}return"#ffffff"}get warningColor(){var e,t,r,i,n;return(n=(i=(r=(t=(e=this.$vuetify)==null?void 0:e.theme)==null?void 0:t.currentTheme)==null?void 0:r.warning)==null?void 0:i.toString())!=null?n:"#ff8300"}get buttonStyle(){let e="";return this.active&&(e=this.homedAxes.includes("xyz")?this.primaryColor:this.warningColor),{color:this.active?this.primaryTextColor:"","background-color":e}}get dotStyle(){return{"border-color":this.active?this.primaryTextColor:"","background-color":"#"+this.color}}changeTool(){this.doSend(this.name.toUpperCase())}};u0([w({type:String})],sc.prototype,"name",2);sc=u0([S({components:{}})],sc);var Q9=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(g,{staticClass:"flex-grow-1 px-0",style:e.buttonStyle,attrs:{disabled:e.printerIsPrintingOnly,dense:""},on:{click:e.changeTool}},[e.color!=null?t("span",{staticClass:"_extruderColorState mr-1",style:e.dotStyle}):e._e(),e._v(" "+e._s(e.name.toUpperCase())+" ")])},e7=[],t7=E(sc,Q9,e7,!1,null,"81ee7357");const s7=t7.exports;var r7=Object.getOwnPropertyDescriptor,i7=(s,e,t,r)=>{for(var i=r>1?void 0:r?r7(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let lh=class extends k(L,Je){constructor(){super(...arguments),this.mdiPrinter3dNozzle=Us}get rows(){const e=this.toolchangeMacros.length,t=Math.ceil(e/Math.ceil(e/6));let r=[];for(let i=0;i<this.toolchangeMacros.length;i+=t)r.push(this.toolchangeMacros.slice(i,i+t));return r}};lh=i7([S({})],lh);var n7=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",{staticClass:"mb-3"},e._l(e.rows,function(r,i){return t(x,{key:"row_"+i,staticClass:"mt-0"},[t(b,[t(Wt,{staticClass:"_btn-group py-0 px-3"},e._l(r,function(n){return t(s7,{key:n,attrs:{name:n}})}),1)],1)],1)}),1)},a7=[],o7=E(lh,n7,a7,!1,null,"6d361cdc");const l7=o7.exports;var c7=Object.getOwnPropertyDescriptor,u7=(s,e,t,r)=>{for(var i=r>1?void 0:r?c7(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let ch=class extends k(L,Je){constructor(){super(...arguments),this.mdiCog=ss}get showTools(){var s;return(s=this.$store.state.gui.view.extruder.showTools)!=null?s:!0}set showTools(s){this.$store.dispatch("gui/saveSetting",{name:"view.extruder.showTools",value:s})}get showExtrusionFactor(){var s;return(s=this.$store.state.gui.view.extruder.showExtrusionFactor)!=null?s:!0}set showExtrusionFactor(s){this.$store.dispatch("gui/saveSetting",{name:"view.extruder.showExtrusionFactor",value:s})}get existsPressureAdvance(){return!(this.$store.getters["printer/getExtruderSteppers"].length>0)}get showPressureAdvance(){var s;return(s=this.$store.state.gui.view.extruder.showPressureAdvance)!=null?s:!0}set showPressureAdvance(s){this.$store.dispatch("gui/saveSetting",{name:"view.extruder.showPressureAdvance",value:s})}get showFirmwareRetraction(){var s;return(s=this.$store.state.gui.view.extruder.showFirmwareRetraction)!=null?s:!0}set showFirmwareRetraction(s){this.$store.dispatch("gui/saveSetting",{name:"view.extruder.showFirmwareRetraction",value:s})}get showExtruderControl(){var s;return(s=this.$store.state.gui.view.extruder.showExtruderControl)!=null?s:!0}set showExtruderControl(s){this.$store.dispatch("gui/saveSetting",{name:"view.extruder.showExtruderControl",value:s})}};ch=u7([S],ch);var d7=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(ye,{attrs:{"offset-y":!0,left:!0,"close-on-content-click":!1},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{icon:"",tile:""}},"v-btn",i,!1),r),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiCog))])],1)]}}])},[t(Me,[e.toolchangeMacros.length?t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.ExtruderControlPanel.Tools")},model:{value:e.showTools,callback:function(r){e.showTools=r},expression:"showTools"}})],1):e._e(),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.ExtruderControlPanel.ExtrusionFactor")},model:{value:e.showExtrusionFactor,callback:function(r){e.showExtrusionFactor=r},expression:"showExtrusionFactor"}})],1),e.existsPressureAdvance?t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.ExtruderControlPanel.PressureAdvance")},model:{value:e.showPressureAdvance,callback:function(r){e.showPressureAdvance=r},expression:"showPressureAdvance"}})],1):e._e(),e.existsFirmwareRetraction?t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.ExtruderControlPanel.FirmwareRetraction")},model:{value:e.showFirmwareRetraction,callback:function(r){e.showFirmwareRetraction=r},expression:"showFirmwareRetraction"}})],1):e._e(),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.ExtruderControlPanel.ExtruderControl")},model:{value:e.showExtruderControl,callback:function(r){e.showExtruderControl=r},expression:"showExtruderControl"}})],1)],1)],1)},m7=[],h7=E(ch,d7,m7,!1,null,null);const p7=h7.exports;var f7=Object.defineProperty,g7=Object.getOwnPropertyDescriptor,un=(s,e,t,r)=>{for(var i=r>1?void 0:r?g7(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&f7(e,t,i),i};let mr=class extends k(L){constructor(){super(...arguments),this.DEFAULT_DESC="G-Code macro",this.mdiCloseThick=pe,this.mdiMenuDown=gr,this.mdiRefresh=an,this.paramArray=[],this.params={},this.paramsDialog=!1}get klipperMacro(){return this.$store.getters["printer/getMacro"](this.macro.name)}get isGcodeStyle(){return this.macro.name.match(/[G|M]\d{1,3}/gm)}get paramCols(){if(this.isMobile)return 1;const s=Math.ceil(this.paramArray.length/5);return s>4?4:s}get paramCssCols(){return 12/this.paramCols}get paramsOverlayWidth(){return 200*this.paramCols}get hasDescription(){return this.klipperMacro.description&&this.klipperMacro.description!==this.DEFAULT_DESC}klipperMacroChange(){this.refreshParams()}refreshParams(){var s;this.paramArray.splice(0,this.paramArray.length),this.params={},((s=this.klipperMacro)==null?void 0:s.params)!==null&&Object.keys(this.klipperMacro.params).forEach(e=>{e.startsWith("_")||(this.paramArray.push(e),this.params[e]={type:this.klipperMacro.params[e].type,default:this.klipperMacro.params[e].default,value:""})})}doSendMacro(s){this.$store.dispatch("server/addEvent",{message:s,type:"command"}),this.$socket.emit("printer.gcode.script",{script:s},{loading:"macro_"+s})}sendWithParams(){let s=[];this.paramArray.forEach(t=>{var i;let r=(i=this.params[t].value)==null?void 0:i.toString().trim();if(this.params[t].value!==null&&r!==""){let n=t;r!=null&&r.includes(" ")&&(r='"'.concat(r,'"')),n+=this.isGcodeStyle?r:"=".concat(r),s.push(n)}});const e=this.macro.name+" "+s.join(" ");this.doSendMacro(e)}mounted(){this.refreshParams()}};un([w({required:!0})],mr.prototype,"macro",2);un([w({default:"primary"})],mr.prototype,"color",2);un([w({default:null})],mr.prototype,"alias",2);un([w({default:!1})],mr.prototype,"disabled",2);un([he("klipperMacro")],mr.prototype,"klipperMacroChange",1);mr=un([S({components:{Panel:U}})],mr);var _7=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Wt,{staticClass:"d-inline-block"},[t(de,{attrs:{disabled:!e.hasDescription,top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({class:e.paramArray.length?"macroWithParameters":"",attrs:{small:"",color:e.color,loading:e.loadings.includes("macro_"+e.macro.name),disabled:e.disabled},on:{click:function(n){return e.doSendMacro(e.macro.name)}}},"v-btn",i,!1),r),[e._v(" "+e._s(e.alias?e.alias:e.macro.name.replace(/_/g," "))+" ")])]}}])},[t("span",[e._v(e._s(e.klipperMacro.description))])]),e.paramArray.length?[e.isMobile?[t(g,{staticClass:"minwidth-0 px-1 btnMacroMenu",attrs:{disabled:e.disabled,color:e.color,small:""},on:{click:function(r){e.paramsDialog=!0}}},[t(_,[e._v(e._s(e.mdiMenuDown))])],1),t(le,{model:{value:e.paramsDialog,callback:function(r){e.paramsDialog=r},expression:"paramsDialog"}},[t(U,{attrs:{title:e.macro.name,"card-class":"macro-params-mobile-".concat(e.macro.name),"margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.paramsDialog=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}],null,!1,2576054633)},[t(Z,[t(x,e._l(e.paramArray,function(r,i){return t(b,{key:"param_mobile_"+i,attrs:{cols:6}},[t(se,{attrs:{label:r,placeholder:e.params[r].default,"persistent-placeholder":!0,"hide-details":"",outlined:"",dense:"",clearable:"","clear-icon":e.mdiRefresh},on:{keyup:function(n){return!n.type.indexOf("key")&&e._k(n.keyCode,"enter",13,n.key,"Enter")?null:e.sendWithParams.apply(null,arguments)}},model:{value:e.params[r].value,callback:function(n){e.$set(e.params[r],"value",n)},expression:"params[name].value"}})],1)}),1)],1),t(oe,{staticClass:"px-4 pb-4"},[t(g,{staticClass:"text-uppercase",attrs:{color:"primary",block:""},on:{click:e.sendWithParams}},[e._v(" "+e._s(e.$t("Panels.MacrosPanel.Send"))+" ")])],1)],1)],1)]:t(ye,{attrs:{"offset-y":"","close-on-content-click":!1},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"minwidth-0 px-1 btnMacroMenu",attrs:{disabled:e.disabled,color:e.color,small:""}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiMenuDown))])],1)]}}],null,!1,3313662284)},[t(Pe,{attrs:{"max-width":e.paramsOverlayWidth}},[t(Z,{staticClass:"py-2"},[t(x,{staticClass:"my-2"},e._l(e.paramArray,function(r,i){return t(b,{key:"param_"+i,attrs:{cols:e.paramCssCols}},[t(se,{attrs:{label:r,placeholder:e.params[r].default,"persistent-placeholder":!0,"hide-details":"",outlined:"",dense:"",clearable:"","clear-icon":e.mdiRefresh},on:{keyup:function(n){return!n.type.indexOf("key")&&e._k(n.keyCode,"enter",13,n.key,"Enter")?null:e.sendWithParams.apply(null,arguments)}},model:{value:e.params[r].value,callback:function(n){e.$set(e.params[r],"value",n)},expression:"params[name].value"}})],1)}),1),t(x,{staticClass:"my-2"},[t(b,{staticClass:"py-0"},[t(g,{staticClass:"text-uppercase",attrs:{color:"primary",block:""},on:{click:e.sendWithParams}},[e._v(" "+e._s(e.$t("Panels.MacrosPanel.Send"))+" ")])],1)],1)],1)],1)],1)]:e._e()],2)},v7=[],b7=E(mr,_7,v7,!1,null,"a84fe633");const Ks=b7.exports;var y7=Object.getOwnPropertyDescriptor,C7=(s,e,t,r)=>{for(var i=r>1?void 0:r?y7(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let uh=class extends k(L,Je,Fi){constructor(){super(...arguments),this.mdiPrinter3dNozzle=Us,this.mdiDotsVertical=mu,this.heatWaitGcodes=["printer.extruder.can_extrude","TEMPERATURE_WAIT","M109"]}get showPanel(){return this.klipperReadyForGui&&this.extruders.length>0}get macros(){return this.$store.getters["printer/getMacros"]}get loadFilamentMacro(){const e=["LOAD_FILAMENT","FILAMENT_LOAD"];return this.macros.find(t=>e.includes(t.name.toUpperCase()))}get unloadFilamentMacro(){const e=["UNLOAD_FILAMENT","FILAMENT_UNLOAD"];return this.macros.find(t=>e.includes(t.name.toUpperCase()))}get purgeFilamentMacro(){const e=["PURGE_FILAMENT","FILAMENT_PURGE"];return this.macros.find(t=>e.includes(t.name.toUpperCase()))}get cleanNozzleMacro(){const e=["CLEAN_NOZZLE","NOZZLE_CLEAN","WIPE_NOZZLE","NOZZLE_WIPE"];return this.macros.find(t=>e.includes(t.name.toUpperCase()))}get canExecuteLoadMacro(){return this.extrudePossible?!0:this.heatWaitGcodes.some(e=>{var t;return(t=this.loadFilamentMacro)==null?void 0:t.prop.gcode.includes(e)})}get canExecuteUnloadMacro(){return this.extrudePossible?!0:this.heatWaitGcodes.some(e=>{var t;return(t=this.unloadFilamentMacro)==null?void 0:t.prop.gcode.includes(e)})}get canExecutePurgeMacro(){return this.extrudePossible?!0:this.heatWaitGcodes.some(e=>{var t;return(t=this.purgeFilamentMacro)==null?void 0:t.prop.gcode.includes(e)})}get showFilamentMacros(){return this.loadFilamentMacro!==void 0||this.unloadFilamentMacro!==void 0||this.purgeFilamentMacro!==void 0||this.cleanNozzleMacro!==void 0}get showTools(){var e;return this.toolchangeMacros.length<1?!1:(e=this.$store.state.gui.view.extruder.showTools)!=null?e:!0}get showExtrusionFactor(){var e;return(e=this.$store.state.gui.view.extruder.showExtrusionFactor)!=null?e:!0}get existsPressureAdvance(){return!(this.$store.getters["printer/getExtruderSteppers"].length>0)}get showPressureAdvance(){var e;return this.existsPressureAdvance?(e=this.$store.state.gui.view.extruder.showPressureAdvance)!=null?e:!0:!1}get showFirmwareRetraction(){var e;return this.existsFirmwareRetraction?(e=this.$store.state.gui.view.extruder.showFirmwareRetraction)!=null?e:!0:!1}get showExtruderControl(){var e;return(e=this.$store.state.gui.view.extruder.showExtruderControl)!=null?e:!0}};uh=C7([S({components:{Panel:U}})],uh);var $7=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.showPanel?t(U,{attrs:{icon:e.mdiPrinter3dNozzle,title:e.$t("Panels.ExtruderControlPanel.Headline"),collapsible:!0,"card-class":"extruder-control-panel"},scopedSlots:e._u([{key:"buttons",fn:function(){return[e.showFilamentMacros?t(ye,{attrs:{"offset-y":!0,"close-on-content-click":!1,left:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{icon:"",tile:""}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiDotsVertical))])],1)]}}],null,!1,2883138713)},[t(Me,{attrs:{dense:""}},[e.unloadFilamentMacro?t(J,[t(de,{attrs:{top:"",disabled:e.canExecuteUnloadMacro,color:"secondary"},scopedSlots:e._u([{key:"activator",fn:function({on:r}){return[t("div",e._g({},r),[t(Ks,{attrs:{macro:e.unloadFilamentMacro,alias:e.$t("Panels.ExtruderControlPanel.UnloadFilament"),disabled:!e.canExecuteUnloadMacro||e.printerIsPrintingOnly,color:"#272727"}})],1)]}}],null,!1,3835858943)},[t("span",[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.ExtruderTempTooLow"))+" "+e._s(e.minExtrudeTemp)+" °C ")])])],1):e._e(),e.loadFilamentMacro?t(J,[t(de,{attrs:{top:"",disabled:e.canExecuteLoadMacro,color:"secondary"},scopedSlots:e._u([{key:"activator",fn:function({on:r}){return[t("div",e._g({},r),[t(Ks,{attrs:{macro:e.loadFilamentMacro,alias:e.$t("Panels.ExtruderControlPanel.LoadFilament"),disabled:!e.canExecuteLoadMacro||e.printerIsPrintingOnly,color:"#272727"}})],1)]}}],null,!1,1294394980)},[t("span",[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.ExtruderTempTooLow"))+" "+e._s(e.minExtrudeTemp)+" °C ")])])],1):e._e(),e.purgeFilamentMacro?t(J,[t(de,{attrs:{top:"",disabled:e.canExecutePurgeMacro,color:"secondary"},scopedSlots:e._u([{key:"activator",fn:function({on:r}){return[t("div",e._g({},r),[t(Ks,{attrs:{macro:e.purgeFilamentMacro,alias:e.$t("Panels.ExtruderControlPanel.PurgeFilament"),disabled:!e.canExecutePurgeMacro||e.printerIsPrintingOnly,color:"#272727"}})],1)]}}],null,!1,2789275863)},[t("span",[e._v(" "+e._s(e.$t("Panels.ExtruderControlPanel.ExtruderTempTooLow"))+" "+e._s(e.minExtrudeTemp)+" °C ")])])],1):e._e(),e.cleanNozzleMacro?t(J,[t(Ks,{attrs:{macro:e.cleanNozzleMacro,alias:e.$t("Panels.ExtruderControlPanel.CleanNozzle"),disabled:e.printerIsPrintingOnly,color:"#272727"}})],1):e._e()],1)],1):e._e(),t(p7)]},proxy:!0}],null,!1,40833120)},[e.showTools&&e.toolchangeMacros.length?t(l7):e._e(),e.showExtrusionFactor?[e.showTools?t(I):e._e(),t(Y9)]:e._e(),e.showPressureAdvance?[e.showTools||e.showExtrusionFactor?t(I):e._e(),t(W9)]:e._e(),e.showFirmwareRetraction?[e.showTools||e.showExtrusionFactor||e.showPressureAdvance?t(I):e._e(),t(j9)]:e._e(),e.showExtruderControl?[e.showTools||e.showExtrusionFactor||e.showPressureAdvance||e.showFirmwareRetraction?t(I):e._e(),t(E9)]:e._e()],2):e._e()},x7=[],w7=E(uh,$7,x7,!1,null,null);const S7=w7.exports;var P7=Object.defineProperty,D7=Object.getOwnPropertyDescriptor,d0=(s,e,t,r)=>{for(var i=r>1?void 0:r?D7(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&P7(e,t,i),i};let rc=class extends k(L){constructor(){super(...arguments),this.mdiEngine=ev}get toolhead(){var e,t;return(t=(e=this.$store.state.printer)==null?void 0:e.toolhead)!=null?t:{}}get configPrinter(){var e,t,r,i;return(i=(r=(t=(e=this.$store.state.printer)==null?void 0:e.configfile)==null?void 0:t.settings)==null?void 0:r.printer)!=null?i:{}}get velocity(){var e;return Math.trunc((e=this.toolhead.max_velocity)!=null?e:300)}get accel(){var e;return Math.trunc((e=this.toolhead.max_accel)!=null?e:3e3)}get accelToDecel(){var e;return Math.trunc((e=this.toolhead.max_accel_to_decel)!=null?e:this.accel/2)}get minimumCruiseRatio(){var t;const e=(t=this.toolhead.minimum_cruise_ratio)!=null?t:null;return e===null?null:Math.round(e*100)}get squareCornerVelocity(){var e;return Math.floor(((e=this.toolhead.square_corner_velocity)!=null?e:8)*10)/10}get defaultVelocity(){var e;return Math.trunc((e=this.configPrinter.max_velocity)!=null?e:300)}get defaultAccel(){var e;return Math.trunc((e=this.configPrinter.max_accel)!=null?e:3e3)}get defaultAccelToDecel(){var e;return Math.trunc((e=this.configPrinter.max_accel_to_decel)!=null?e:1500)}get defaultMinimumCruiseRatio(){var t;const e=(t=this.configPrinter.minimum_cruise_ratio)!=null?t:.5;return Math.round(e*100)}get defaultSquareCornerVelocity(){var t;const e=(t=this.configPrinter.square_corner_velocity)!=null?t:8;return Math.floor(e*10)/10}sendCruiseRatioCmd(e){e.value=e.value/100,this.sendCmd(e)}sendCmd(e){const t="SET_VELOCITY_LIMIT ".concat(e.name,"=").concat(e.value);this.$store.dispatch("server/addEvent",{message:t,type:"command"}),this.$socket.emit("printer.gcode.script",{script:t})}};d0([Ke(500)],rc.prototype,"sendCmd",1);rc=d0([S({components:{NumberInput:He,Panel:U,Responsive:tt}})],rc);var T7=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.klipperReadyForGui?t(U,{attrs:{icon:e.mdiEngine,title:e.$t("Panels.MachineSettingsPanel.Headline"),collapsible:!0,"card-class":"machine-settings-panel"}},[t(tt,{attrs:{breakpoints:{small:r=>r.width<375,medium:r=>r.width>=375}},scopedSlots:e._u([{key:"default",fn:function({el:r}){return[t(Z,{staticClass:"pt-5"},[t(x,[t(b,{class:{"col-12":r.is.small,"col-6":r.is.medium}},[t(He,{attrs:{label:e.$t("Panels.MachineSettingsPanel.MotionSettings.Velocity"),param:"VELOCITY",target:e.velocity,"default-value":e.defaultVelocity,"output-error-msg":!0,"has-spinner":!0,"spinner-factor":5,step:1,min:1,max:null,dec:0,unit:"mm/s"},on:{submit:e.sendCmd}})],1),t(b,{class:{"col-12":r.is.small,"col-6":r.is.medium}},[t(He,{attrs:{label:e.$t("Panels.MachineSettingsPanel.MotionSettings.SquareCornerVelocity"),param:"SQUARE_CORNER_VELOCITY",target:e.squareCornerVelocity,"default-value":e.defaultSquareCornerVelocity,"output-error-msg":!0,"has-spinner":!0,step:.1,min:.1,max:null,dec:1,unit:"mm/s"},on:{submit:e.sendCmd}})],1)],1),t(x,[t(b,{class:{"col-12":r.is.small,"col-6":r.is.medium}},[t(He,{attrs:{label:e.$t("Panels.MachineSettingsPanel.MotionSettings.Acceleration"),param:"ACCEL",target:e.accel,"default-value":e.defaultAccel,"output-error-msg":!0,"has-spinner":!0,"spinner-factor":100,step:1,min:1,max:null,dec:0,unit:"mm/s²"},on:{submit:e.sendCmd}})],1),t(b,{class:{"col-12":r.is.small,"col-6":r.is.medium}},[e.minimumCruiseRatio===null?t(He,{attrs:{label:e.$t("Panels.MachineSettingsPanel.MotionSettings.MaxAccelToDecel"),param:"ACCEL_TO_DECEL",target:e.accelToDecel,"default-value":e.defaultAccelToDecel,"output-error-msg":!0,"has-spinner":!0,"spinner-factor":100,step:1,min:1,max:null,dec:0,unit:"mm/s²"},on:{submit:e.sendCmd}}):t(He,{attrs:{label:e.$t("Panels.MachineSettingsPanel.MotionSettings.MinimumCruiseRatio"),param:"MINIMUM_CRUISE_RATIO",target:e.minimumCruiseRatio,"default-value":e.defaultMinimumCruiseRatio,"output-error-msg":!0,"has-spinner":!0,"spinner-factor":5,step:1,min:0,max:99,dec:0,unit:"%"},on:{submit:e.sendCruiseRatioCmd}})],1)],1)],1)]}}],null,!1,1115546932)})],1):e._e()},O7=[],M7=E(rc,T7,O7,!1,null,null);const k7=M7.exports;var E7=Object.defineProperty,L7=Object.getOwnPropertyDescriptor,m0=(s,e,t,r)=>{for(var i=r>1?void 0:r?L7(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&E7(e,t,i),i};let ic=class extends k(L){constructor(){super(...arguments),this.mdiCodeTags=Qn}get macrogroup(){return this.$store.getters["gui/macros/getMacrogroup"](this.panelId)}get allMacros(){var e;return(e=this.$store.getters["printer/getMacros"])!=null?e:[]}get macros(){var t,r;let e=(r=(t=this.macrogroup)==null?void 0:t.macros)!=null?r:[];return e=e.filter(i=>this.allMacros.find(n=>n.name.toLowerCase()===i.name.toLowerCase())?i.showInStandby&&["standby","cancelled","complete","error"].includes(this.printer_state)||i.showInPause&&this.printer_state==="paused"||i.showInPrinting&&this.printer_state==="printing":!1),e.sort((i,n)=>i.pos-n.pos)}get macrogroupStatus(){return this.macrogroup.showInStandby&&["standby","cancelled","complete","error"].includes(this.printer_state)||this.macrogroup.showInPause&&this.printer_state==="paused"||this.macrogroup.showInPrinting&&this.printer_state==="printing"}getColor(e){return e.color==="group"?this.macrogroup.color==="custom"?this.macrogroup.colorCustom:this.macrogroup.color:e.color}};m0([w({required:!0})],ic.prototype,"panelId",2);ic=m0([S({components:{MacroButton:Ks,Panel:U}})],ic);var A7=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.klipperReadyForGui&&e.macros.length>0&&e.macrogroupStatus?t(U,{attrs:{icon:e.mdiCodeTags,title:e.macrogroup.name,collapsible:!0,"card-class":"macrogroup_"+e.panelId+"_panel"}},[t(Z,{staticClass:"py-2"},[t(x,[t(b,{staticClass:"text-center"},e._l(e.macros,function(r,i){return t(Ks,{key:"macroparam_"+i,staticClass:"mx-1 my-1",attrs:{macro:r,color:e.getColor(r)}})}),1)],1)],1)],1):e._e()},F7=[],R7=E(ic,A7,F7,!1,null,"c11dd985");const H7=R7.exports;var j7=Object.getOwnPropertyDescriptor,I7=(s,e,t,r)=>{for(var i=r>1?void 0:r?j7(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let dh=class extends k(L){constructor(){super(...arguments),this.mdiCodeTags=Qn}get hiddenMacros(){var e,t,r;return((r=(t=(e=this.$store.state.gui)==null?void 0:e.macros)==null?void 0:t.hiddenMacros)!=null?r:[]).map(i=>i.toLowerCase())}get macros(){return this.$store.getters["printer/getMacros"].filter(t=>!this.hiddenMacros.includes(t.name.toLowerCase()))}};dh=I7([S({components:{MacroButton:Ks,Panel:U}})],dh);var N7=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.klipperReadyForGui&&e.macros.length>0?t(U,{attrs:{icon:e.mdiCodeTags,title:e.$t("Panels.MacrosPanel.Headline"),collapsible:!0,"card-class":"macros-panel"}},[t(Z,{staticClass:"py-2"},[t(x,[t(b,{staticClass:"text-center"},e._l(e.macros,function(r,i){return t(Ks,{key:"macro_"+i,staticClass:"mx-1 my-1",attrs:{macro:r,color:"primary"}})}),1)],1)],1)],1):e._e()},V7=[],B7=E(dh,N7,V7,!1,null,null);const U7=B7.exports;var W7=Object.defineProperty,z7=Object.getOwnPropertyDescriptor,h0=(s,e,t,r)=>{for(var i=r>1?void 0:r?z7(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&W7(e,t,i),i};let nc=class extends k(L){get entryStyle(){var e;const s=["ma-0","flex-nowrap"];return s.push((e=this.$store.state.gui.console.entryStyle)!=null?e:"default"),["action","debug"].includes(this.event.type)&&s.push("text--disabled"),s}get entryFormatTime(){return this.formatTime(this.event.date.getTime(),!0)}get messageClass(){const s=["console-message"];return["action","debug"].includes(this.event.type)?s.push("text--disabled"):this.event.message.startsWith("!! ")?s.push("error--text"):s.push("text--primary"),s}get rawOutput(){var s;return(s=this.$store.state.gui.console.rawOutput)!=null?s:!1}commandClick(s){const e=s.target;if(e.localName==="a"&&e.className.indexOf("command")!==-1){const t=e.innerHTML.replace(/<br>/g,"\n");this.$emit("command-click",t)}}};h0([w({required:!0})],nc.prototype,"event",2);nc=h0([S],nc);var G7=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,{class:e.entryStyle},[t(b,{staticClass:"col-auto pr-0 text--disabled console-time"},[e._v(e._s(e.entryFormatTime))]),e.rawOutput?t(b,{class:e.messageClass,staticStyle:{"min-width":"0"},domProps:{textContent:e._s(e.event.message)},on:{"!click":function(r){return e.commandClick.apply(null,arguments)}}}):t(b,{class:e.messageClass,staticStyle:{"min-width":"0"},domProps:{innerHTML:e._s(e.event.formatMessage)},on:{"!click":function(r){return e.commandClick.apply(null,arguments)}}})],1)},Z7=[],q7=E(nc,G7,Z7,!1,null,"d7ebc5ec");const p0=q7.exports;var X7=Object.defineProperty,Y7=Object.getOwnPropertyDescriptor,wf=(s,e,t,r)=>{for(var i=r>1?void 0:r?Y7(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&X7(e,t,i),i};let pa=class extends y{commandClick(s){this.$emit("command-click",s)}};wf([w({required:!0})],pa.prototype,"events",2);wf([w({required:!1,default:!1})],pa.prototype,"isMini",2);pa=wf([S({components:{ConsoleTableEntry:p0}})],pa);var J7=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",{class:"consoleTable "+(e.isMini?"mini":"")},[e.events.length===0?[t(x,{staticClass:"pa-0 ma-0"},[t(b,{staticClass:"text-center py-3"},[e._v(e._s(e.$t("Console.Empty")))])],1)]:e._l(e.events,function(r,i){return t(p0,{key:i,staticClass:"consoleTableRow",attrs:{event:r},on:{"command-click":e.commandClick}})})],2)},K7=[],Q7=E(pa,J7,K7,!1,null,"87e97010");const Ru=Q7.exports;var eL=Object.getOwnPropertyDescriptor,tL=(s,e,t,r)=>{for(var i=r>1?void 0:r?eL(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let fa=class extends y{get helplist(){var t,r,i;const s=(r=(t=this.$store.state.printer.gcode)==null?void 0:t.commands)!=null?r:{},e=[];for(const[n,a]of Object.entries(s))e.push({command:n,help:(i=a.help)!=null?i:""});return e}get consoleDirection(){var s;return(s=this.$store.state.gui.console.direction)!=null?s:"table"}get hideWaitTemperatures(){return this.$store.state.gui.console.hideWaitTemperatures}set hideWaitTemperatures(s){this.$store.dispatch("gui/saveSetting",{name:"console.hideWaitTemperatures",value:s})}get hideTlCommands(){return this.$store.state.gui.console.hideTlCommands}set hideTlCommands(s){this.$store.dispatch("gui/saveSetting",{name:"console.hideTlCommands",value:s})}get customFilters(){var s;return(s=this.$store.state.gui.console.consolefilters)!=null?s:{}}get autoscroll(){var s;return(s=this.$store.state.gui.console.autoscroll)!=null?s:!0}set autoscroll(s){this.$store.dispatch("gui/saveSetting",{name:"console.autoscroll",value:s})}get rawOutput(){var s;return(s=this.$store.state.gui.console.rawOutput)!=null?s:!1}set rawOutput(s){this.$store.dispatch("gui/saveSetting",{name:"console.rawOutput",value:s})}get lastCommands(){var s;return(s=this.$store.state.gui.gcodehistory.entries)!=null?s:[]}toggleFilter(s,e){this.$store.dispatch("gui/console/filterUpdate",{id:s,values:e})}clearConsole(){this.$store.dispatch("gui/console/clear")}};fa=tL([S],fa);var sL=Object.defineProperty,rL=Object.getOwnPropertyDescriptor,f0=(s,e,t,r)=>{for(var i=r>1?void 0:r?rL(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&sL(e,t,i),i};let ac=class extends k(L,fa){constructor(){super(...arguments),this.mdiSend=wS,this.mdiChevronDoubleRight=ww,this.gcode="",this.lastCommandNumber=null,this.items=[]}get rows(){var s,e;return(e=(s=this.gcode)==null?void 0:s.split("\n").length)!=null?e:1}getCurrentLine(){const s=this.gcodeCommandField.$refs.input;return s.value.substring(0,s.selectionStart).split("\n").length}setGcode(s){this.gcode=s,this.$nextTick(()=>{this.gcodeCommandField.focus()})}onKeyUp(s){const e=this.getCurrentLine();this.rows>1&&e>1||(s.preventDefault(),this.lastCommandNumber===null&&this.lastCommands.length?(this.lastCommandNumber=this.lastCommands.length-1,this.gcode=this.lastCommands[this.lastCommandNumber]):this.lastCommandNumber&&this.lastCommandNumber>0&&(this.lastCommandNumber--,this.gcode=this.lastCommands[this.lastCommandNumber]))}onKeyDown(s){const e=this.getCurrentLine();this.rows>e||(s.preventDefault(),this.lastCommandNumber!==null&&(this.lastCommandNumber<this.lastCommands.length-1?(this.lastCommandNumber++,this.gcode=this.lastCommands[this.lastCommandNumber]):this.lastCommandNumber===this.lastCommands.length-1&&(this.lastCommandNumber=null,this.gcode="")))}doSend(s){if(s.shiftKey){this.gcode+="\n";return}this.gcode!==""&&(this.$store.dispatch("printer/sendGcode",this.gcode),this.$store.dispatch("gui/gcodehistory/addToHistory",this.gcode),this.gcode="",this.lastCommandNumber=null)}onAutocomplete(s){if(s.preventDefault(),!this.gcode.length)return;const t=this.gcodeCommandField.$refs.input.selectionStart,r=this.gcode.substring(0,t),i=r.lastIndexOf("\n"),a=r.substring(i+1).toUpperCase(),o=this.helplist.filter(c=>c.command.startsWith(a));if(o.length===0)return;if((o==null?void 0:o.length)===1){this.updateGcode(o[0].command,i,t);return}const l=o.reduce((c,d)=>M3(c,d.command),o[0].command);let u="";o.forEach(c=>u+='<a class="command font-weight-bold">'.concat(c.command,"</a>: ").concat(c.help,"<br />")),this.$store.dispatch("server/addEvent",{message:u,type:"autocomplete"}),this.updateGcode(l,i,t)}updateGcode(s,e,t){this.gcode=this.gcode.substring(0,e+1)+s+this.gcode.substring(t)}};f0([Ts()],ac.prototype,"gcodeCommandField",2);ac=f0([S],ac);var iL=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(pr,{ref:"gcodeCommandField",staticClass:"gcode-command-field",attrs:{items:e.items,label:e.$t("Panels.MiniconsolePanel.SendCode"),solo:"",autocomplete:"off","no-resize":"","auto-grow":"",rows:e.rows,"hide-details":"",outlined:"",dense:"","prepend-icon":e.isTouchDevice?e.mdiChevronDoubleRight:"","append-icon":e.mdiSend},on:{keydown:[function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"enter",13,r.key,"Enter")?null:(r.preventDefault(),r.stopPropagation(),e.doSend.apply(null,arguments))},function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"up",38,r.key,["Up","ArrowUp"])?null:e.onKeyUp.apply(null,arguments)},function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"down",40,r.key,["Down","ArrowDown"])?null:e.onKeyDown.apply(null,arguments)},function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"tab",9,r.key,"Tab")?null:e.onAutocomplete.apply(null,arguments)}],"click:prepend":e.onAutocomplete,"click:append":e.doSend},model:{value:e.gcode,callback:function(r){e.gcode=r},expression:"gcode"}})},nL=[],aL=E(ac,iL,nL,!1,null,"6fc1f5a7");const g0=aL.exports;var oL=Object.defineProperty,lL=Object.getOwnPropertyDescriptor,_0=(s,e,t,r)=>{for(var i=r>1?void 0:r?lL(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&oL(e,t,i),i};let oc=class extends k(L){get commands(){var s,e;return(e=(s=this.$store.state.printer.gcode)==null?void 0:s.commands)!=null?e:{}}get commandObject(){var s;return(s=this.commands[this.command])!=null?s:{}}get description(){var s;return(s=this.commandObject.help)!=null?s:null}get twoLine(){return this.description!==null}onCommand(){this.$emit("click-on-command",this.command)}};_0([w({required:!0,type:String})],oc.prototype,"command",2);oc=_0([S],oc);var cL=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(J,{staticClass:"px-0",attrs:{"two-line":e.twoLine}},[t(_t,{staticClass:"px-0"},[t(Ze,{staticClass:"primary--text font-weight-bold cursor-pointer",on:{click:e.onCommand}},[e._v(" "+e._s(e.command)+" ")]),e.description?t(Va,{staticClass:"text-wrap"},[e._v(e._s(e.description))]):e._e()],1)],1)},uL=[],dL=E(oc,cL,uL,!1,null,null);const v0=dL.exports;var mL=Object.defineProperty,hL=Object.getOwnPropertyDescriptor,Hu=(s,e,t,r)=>{for(var i=r>1?void 0:r?hL(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&mL(e,t,i),i};let Ri=class extends k(L){constructor(){super(...arguments),this.cmdListSearch="",this.isOpen=!1,this.mdiHelp=Wp,this.mdiCloseThick=pe}get helplist(){var s,e;return Object.keys((e=(s=this.$store.state.printer.gcode)==null?void 0:s.commands)!=null?e:{})}get helplistFiltered(){return this.helplist.filter(s=>s.includes(this.cmdListSearch.toUpperCase())).sort((s,e)=>s.localeCompare(e))}onCommand(s){this.$emit("onCommand",s),this.isOpen=!1}onIsOpen(s){s||(this.cmdListSearch="")}};Hu([w({required:!1,default:!1})],Ri.prototype,"isMini",2);Hu([w({required:!1,default:!1})],Ri.prototype,"inToolbar",2);Hu([he("isOpen")],Ri.prototype,"onIsOpen",1);Ri=Hu([S({components:{CommandHelpModalEntry:v0,Panel:U}})],Ri);var pL=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{transition:"dialog-bottom-transition","max-width":"600",fullscreen:e.isMobile},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[e.inToolbar?[t(g,e._g(e._b({attrs:{icon:"",tile:""}},"v-btn",i,!1),r),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiHelp))])],1)]:[t(g,e._g(e._b({staticClass:"gcode-command-btn px-2 minwidth-0",attrs:{color:"lightgray",small:e.isMini}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiHelp))])],1)]]}},{key:"default",fn:function(){return[t(U,{attrs:{title:e.$t("Console.CommandList"),icon:e.mdiHelp,"card-class":"command-help-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.isOpen=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(gt,[t(x,[t(b,[t(se,{attrs:{label:e.$t("Console.Search"),outlined:"","hide-details":"",clearable:"",dense:""},model:{value:e.cmdListSearch,callback:function(r){e.cmdListSearch=r},expression:"cmdListSearch"}})],1)],1)],1),t(I),t("overlay-scrollbars",{staticClass:"command-help-content",class:e.isMobile?"mobileHeight":"height300"},[t(Z,{staticClass:"pt-0"},[t(Me,e._l(e.helplistFiltered,function(r){return t(v0,{key:r,attrs:{command:r},on:{"click-on-command":e.onCommand}})}),1)],1)],1)],1)]},proxy:!0}]),model:{value:e.isOpen,callback:function(r){e.isOpen=r},expression:"isOpen"}})},fL=[],gL=E(Ri,pL,fL,!1,null,"44dffa8a");const ju=gL.exports;var _L=Object.defineProperty,vL=Object.getOwnPropertyDescriptor,io=(s,e,t,r)=>{for(var i=r>1?void 0:r?vL(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&_L(e,t,i),i};let zr=class extends k(L,fa){constructor(){super(...arguments),this.mdiTrashCan=Mv,this.mdiConsoleLine=Ua,this.mdiCog=ss}get consoleHeight(){var e;return(e=this.$store.state.gui.console.height)!=null?e:300}get events(){return this.$store.getters["server/getConsoleEvents"](this.consoleDirection==="table",250)}eventsChanged(){this.consoleDirection==="shell"&&this.autoscroll&&setTimeout(()=>{this.scrollToBottom()},50)}autoscrollChanged(e){e&&this.scrollToBottom()}commandClick(e){this.gcodeCommandField.setGcode(e)}mounted(){this.consoleDirection==="shell"&&this.scrollToBottom()}scrollToBottom(){this.$nextTick(()=>{this.scrollTo(100)})}scrollToTop(){this.$nextTick(()=>{this.scrollTo(0)})}scrollTo(e){if(!this.miniConsoleScroll)return;const t=this.miniConsoleScroll.osInstance();t==null||t.scroll({y:"".concat(e,"%")})}};io([Ts()],zr.prototype,"miniConsoleScroll",2);io([Ts()],zr.prototype,"gcodeCommandField",2);io([he("events")],zr.prototype,"eventsChanged",1);io([he("autoscroll")],zr.prototype,"autoscrollChanged",1);zr=io([S({components:{Panel:U,ConsoleTable:Ru,CommandHelpModal:ju}})],zr);var bL=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.socketIsConnected&&e.klipperState!=="disconnected"?t(U,{attrs:{icon:e.mdiConsoleLine,title:e.$t("Panels.MiniconsolePanel.Headline"),collapsible:!0,"card-class":"miniconsole-panel","hide-buttons-on-collapse":!0},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.clearConsole}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiTrashCan))])],1),t(ju,{attrs:{"in-toolbar":!0},on:{onCommand:function(r){return e.commandClick(r)}}}),t(ye,{attrs:{"offset-y":!0,"close-on-content-click":!1,title:e.$t("Panels.MiniconsolePanel.SetupConsole")},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{icon:"",tile:""}},"v-btn",i,!1),r),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiCog))])],1)]}}],null,!1,3210076863)},[t(Me,[e.consoleDirection==="shell"?t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.MiniconsolePanel.Autoscroll")},model:{value:e.autoscroll,callback:function(r){e.autoscroll=r},expression:"autoscroll"}})],1):e._e(),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.MiniconsolePanel.HideTemperatures")},model:{value:e.hideWaitTemperatures,callback:function(r){e.hideWaitTemperatures=r},expression:"hideWaitTemperatures"}})],1),e.moonrakerComponents.includes("timelapse")?t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.MiniconsolePanel.HideTimelapse")},model:{value:e.hideTlCommands,callback:function(r){e.hideTlCommands=r},expression:"hideTlCommands"}})],1):e._e(),e._l(e.customFilters,function(r,i){return t(J,{key:i,staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:r.name},on:{change:function(n){return e.toggleFilter(i,r)}},model:{value:r.bool,callback:function(n){e.$set(r,"bool",n)},expression:"filter.bool"}})],1)}),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.MiniconsolePanel.RawOutput")},model:{value:e.rawOutput,callback:function(r){e.rawOutput=r},expression:"rawOutput"}})],1)],2)],1)]},proxy:!0}],null,!1,4082619026)},[t("div",{staticClass:"d-flex flex-column"},[t(Z,{class:e.consoleDirection==="table"?"order-1":"order-2"},[t(g0,{ref:"gcodeCommandField"})],1),t(Z,{class:(e.consoleDirection==="table"?"order-2":"order-1")+" pa-0"},[t(x,[t(b,[t("overlay-scrollbars",{ref:"miniConsoleScroll",style:"height: "+e.consoleHeight+"px;",attrs:{options:{}}},[t(Ru,{ref:"console",attrs:{events:e.events,"is-mini":!0},on:{"command-click":e.commandClick}}),t(I)],1)],1)],1)],1)],1)]):e._e()},yL=[],CL=E(zr,bL,yL,!1,null,"d438c597");const $L=CL.exports;var xL=Object.defineProperty,wL=Object.getOwnPropertyDescriptor,Sf=(s,e,t,r)=>{for(var i=r>1?void 0:r?wL(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&xL(e,t,i),i};let ga=class extends k(L){constructor(){super(...arguments),this.convertName=Ye,this.unitToSymbol=Xv}get sensorData(){const s=this.$store.state.server.sensor.sensors;return this.sensor in s?s[this.sensor].values:{}}get sensorConfig(){var t,r;const s="sensor ".concat(this.sensor),e=(r=(t=this.$store.state.server.config)==null?void 0:t.config)!=null?r:{};return s in e?e[s]:{}}get parameterConfig(){const s="parameter_".concat(this.valueName);return s in this.sensorConfig?this.sensorConfig[s]:{}}get unit(){return"units"in this.parameterConfig?this.parameterConfig.units:null}get value(){return this.valueName in this.sensorData?Math.round(this.sensorData[this.valueName]*1e3)/1e3:"--"}get output(){return this.unit===null?this.value:"".concat(this.value," ").concat(this.unit)}get name(){return this.convertName(this.valueName)}};Sf([w({type:String,required:!0})],ga.prototype,"sensor",2);Sf([w({type:String,required:!0})],ga.prototype,"valueName",2);ga=Sf([S],ga);var SL=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",{staticClass:"d-flex w-100 flex-row align-center"},[t(_,{attrs:{small:"",left:""}},[e._v(e._s(e.unitToSymbol(e.unit)))]),t("span",{staticClass:"flex-grow-1"},[e._v(e._s(e.name)+":")]),t("span",[e._v(e._s(e.output))])],1)},PL=[],DL=E(ga,SL,PL,!1,null,null);const b0=DL.exports;var TL=Object.defineProperty,OL=Object.getOwnPropertyDescriptor,y0=(s,e,t,r)=>{for(var i=r>1?void 0:r?OL(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&TL(e,t,i),i};let lc=class extends k(L){constructor(){super(...arguments),this.convertName=Ye}get valueNames(){const s=this.$store.state.server.sensor.sensors;return this.name in s?Object.keys(s[this.name].values):[]}};y0([w({type:String,required:!0})],lc.prototype,"name",2);lc=y0([S({components:{MoonrakerSensorValue:b0}})],lc);var ML=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Ee,{staticClass:"px-0 py-2"},[t(x,[t(b,{staticClass:"pb-3"},[t(cs,{staticClass:"mb-1 d-block _moonraker-sensor-subheader"},[e._v(" "+e._s(e.convertName(e.name))+" ")]),t(cs,{staticClass:"d-block _moonraker-sensor-subheader"},e._l(e.valueNames,function(r,i){return t(b0,{key:"moonraker_sensor_value_"+i,attrs:{sensor:e.name,"value-name":r}})}),1)],1)],1)],1)},kL=[],EL=E(lc,ML,kL,!1,null,"e21d748d");const C0=EL.exports;var LL=Object.defineProperty,AL=Object.getOwnPropertyDescriptor,Iu=(s,e,t,r)=>{for(var i=r>1?void 0:r?AL(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&LL(e,t,i),i};let Hi=class extends k(L){constructor(){super(...arguments),this.convertName=Ye,this.unitToSymbol=Xv}get output(){const s=isNaN(this.value)?"--":this.value;return this.unit===null?this.value:"".concat(s," ").concat(this.unit)}};Iu([w({type:String,required:!0})],Hi.prototype,"name",2);Iu([w({type:Number,required:!0})],Hi.prototype,"value",2);Iu([w({type:String,required:!1})],Hi.prototype,"unit",2);Hi=Iu([S()],Hi);var FL=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Ee,{staticClass:"px-0 py-2"},[t(x,[t(b,{staticClass:"pb-3"},[t(cs,{staticClass:"_miscellaneous-sensor-subheader"},[t(_,{staticClass:"mr-2",attrs:{small:""}},[e._v(e._s(e.unitToSymbol(e.unit)))]),t("span",[e._v(e._s(e.convertName(e.name)))]),t(ae),t("span",[e._v(e._s(e.output))])],1)],1)],1)],1)},RL=[],HL=E(Hi,FL,RL,!1,null,"0d332281");const $0=HL.exports;var jL=Object.defineProperty,IL=Object.getOwnPropertyDescriptor,dn=(s,e,t,r)=>{for(var i=r>1?void 0:r?IL(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&jL(e,t,i),i};let hr=class extends k(L){constructor(){super(...arguments),this.mdiToggleSwitch=Yp,this.mdiToggleSwitchOffOutline=Ov,this.mdiPrinter3dNozzleAlert=vv,this.convertName=Ye}get statusColor(){if(this.enabled){if(this.filament_detected)return"success"}else return"gray";return"warning"}get statusText(){return this.filament_diameter!==void 0&&this.filament_detected?this.filament_diameter.toPrecision(3)+"mm":this.filament_detected?this.$t("Panels.MiscellaneousPanel.RunoutSensor.Detected"):this.$t("Panels.MiscellaneousPanel.RunoutSensor.Empty")}changeSensor(){let s=["SET_FILAMENT_SENSOR SENSOR="+this.name+" ENABLE="+(this.enabled?0:1)];this.type=="hall_filament_width_sensor"&&s.push((this.enabled?"DIS":"EN")+"ABLE_FILAMENT_WIDTH_SENSOR");for(const e of s)this.$store.dispatch("server/addEvent",{message:e,type:"command"}),this.$socket.emit("printer.gcode.script",{script:e})}};dn([w({type:String,required:!0})],hr.prototype,"type",2);dn([w({type:String,required:!0})],hr.prototype,"name",2);dn([w({type:Boolean,required:!0})],hr.prototype,"enabled",2);dn([w({type:Boolean,required:!0})],hr.prototype,"filament_detected",2);dn([w({type:Number})],hr.prototype,"filament_diameter",2);hr=dn([S],hr);var NL=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Ee,{staticClass:"px-0 py-2"},[t(x,[t(b,{staticClass:"pb-3"},[t(cs,{staticClass:"_filamentRunout-subheader"},[t(_,{staticClass:"mr-2",attrs:{small:""}},[e._v(e._s(e.mdiPrinter3dNozzleAlert))]),t("span",[e._v(e._s(e.convertName(e.name)))]),t(ae),t("small",{class:"mr-3 "+e.statusColor+"--text"},[e._v(e._s(e.statusText))]),t(_,{on:{click:e.changeSensor}},[e._v(" "+e._s(e.enabled?e.mdiToggleSwitch:e.mdiToggleSwitchOffOutline)+" ")])],1)],1)],1)],1)},VL=[],BL=E(hr,NL,VL,!1,null,"36204c70");const x0=BL.exports;/*!
|
||
* iro.js v5.5.2
|
||
* 2016-2021 James Daniel
|
||
* Licensed under MPL 2.0
|
||
* github.com/jaames/iro.js
|
||
*/var Be,cc,w0,mh,S0,sr={},Pf=[],UL=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|^--/i;function Qs(s,e){for(var t in e)s[t]=e[t];return s}function P0(s){var e=s.parentNode;e&&e.removeChild(s)}function Fe(s,e,t){var r,i,n,a,o=arguments;if(e=Qs({},e),arguments.length>3)for(t=[t],r=3;r<arguments.length;r++)t.push(o[r]);if(t!=null&&(e.children=t),s!=null&&s.defaultProps!=null)for(i in s.defaultProps)e[i]===void 0&&(e[i]=s.defaultProps[i]);return a=e.key,(n=e.ref)!=null&&delete e.ref,a!=null&&delete e.key,hh(s,e,a,n)}function hh(s,e,t,r){var i={type:s,props:e,key:t,ref:r,__k:null,__p:null,__b:0,__e:null,l:null,__c:null,constructor:void 0};return Be.vnode&&Be.vnode(i),i}function Nu(s){return s.children}function WL(s){if(s==null||typeof s=="boolean")return null;if(typeof s=="string"||typeof s=="number")return hh(null,s,null,null);if(s.__e!=null||s.__c!=null){var e=hh(s.type,s.props,s.key,null);return e.__e=s.__e,e}return s}function $i(s,e){this.props=s,this.context=e}function uc(s,e){if(e==null)return s.__p?uc(s.__p,s.__p.__k.indexOf(s)+1):null;for(var t;e<s.__k.length;e++)if((t=s.__k[e])!=null&&t.__e!=null)return t.__e;return typeof s.type=="function"?uc(s):null}function D0(s){var e,t;if((s=s.__p)!=null&&s.__c!=null){for(s.__e=s.__c.base=null,e=0;e<s.__k.length;e++)if((t=s.__k[e])!=null&&t.__e!=null){s.__e=s.__c.base=t.__e;break}return D0(s)}}function Ud(s){(!s.__d&&(s.__d=!0)&&cc.push(s)===1||mh!==Be.debounceRendering)&&(mh=Be.debounceRendering,(Be.debounceRendering||w0)(zL))}function zL(){var s,e,t,r,i,n,a,o;for(cc.sort(function(l,u){return u.__v.__b-l.__v.__b});s=cc.pop();)s.__d&&(t=void 0,r=void 0,n=(i=(e=s).__v).__e,a=e.__P,o=e.u,e.u=!1,a&&(t=[],r=Tf(a,i,Qs({},i),e.__n,a.ownerSVGElement!==void 0,null,t,o,n==null?uc(i):n),O0(t,i),r!=n&&D0(i)))}function T0(s,e,t,r,i,n,a,o,l){var u,c,d,m,h,f,p,v=t&&t.__k||Pf,C=v.length;if(o==sr&&(o=n!=null?n[0]:C?uc(t,0):null),u=0,e.__k=Df(e.__k,function(P){if(P!=null){if(P.__p=e,P.__b=e.__b+1,(d=v[u])===null||d&&P.key==d.key&&P.type===d.type)v[u]=void 0;else for(c=0;c<C;c++){if((d=v[c])&&P.key==d.key&&P.type===d.type){v[c]=void 0;break}d=null}if(m=Tf(s,P,d=d||sr,r,i,n,a,null,o,l),(c=P.ref)&&d.ref!=c&&(p||(p=[])).push(c,P.__c||m,P),m!=null){if(f==null&&(f=m),P.l!=null)m=P.l,P.l=null;else if(n==d||m!=o||m.parentNode==null){e:if(o==null||o.parentNode!==s)s.appendChild(m);else{for(h=o,c=0;(h=h.nextSibling)&&c<C;c+=2)if(h==m)break e;s.insertBefore(m,o)}e.type=="option"&&(s.value="")}o=m.nextSibling,typeof e.type=="function"&&(e.l=m)}}return u++,P}),e.__e=f,n!=null&&typeof e.type!="function")for(u=n.length;u--;)n[u]!=null&&P0(n[u]);for(u=C;u--;)v[u]!=null&&k0(v[u],v[u]);if(p)for(u=0;u<p.length;u++)M0(p[u],p[++u],p[++u])}function Df(s,e,t){if(t==null&&(t=[]),s==null||typeof s=="boolean")e&&t.push(e(null));else if(Array.isArray(s))for(var r=0;r<s.length;r++)Df(s[r],e,t);else t.push(e?e(WL(s)):s);return t}function GL(s,e,t,r,i){var n;for(n in t)n in e||n1(s,n,null,t[n],r);for(n in e)i&&typeof e[n]!="function"||n==="value"||n==="checked"||t[n]===e[n]||n1(s,n,e[n],t[n],r)}function i1(s,e,t){e[0]==="-"?s.setProperty(e,t):s[e]=typeof t=="number"&&UL.test(e)===!1?t+"px":t==null?"":t}function n1(s,e,t,r,i){var n,a,o,l,u;if(!((e=i?e==="className"?"class":e:e==="class"?"className":e)==="key"||e==="children"))if(e==="style")if(n=s.style,typeof t=="string")n.cssText=t;else{if(typeof r=="string"&&(n.cssText="",r=null),r)for(a in r)t&&a in t||i1(n,a,"");if(t)for(o in t)r&&t[o]===r[o]||i1(n,o,t[o])}else e[0]==="o"&&e[1]==="n"?(l=e!==(e=e.replace(/Capture$/,"")),u=e.toLowerCase(),e=(u in s?u:e).slice(2),t?(r||s.addEventListener(e,a1,l),(s.t||(s.t={}))[e]=t):s.removeEventListener(e,a1,l)):e!=="list"&&e!=="tagName"&&e!=="form"&&!i&&e in s?s[e]=t==null?"":t:typeof t!="function"&&e!=="dangerouslySetInnerHTML"&&(e!==(e=e.replace(/^xlink:?/,""))?t==null||t===!1?s.removeAttributeNS("http://www.w3.org/1999/xlink",e.toLowerCase()):s.setAttributeNS("http://www.w3.org/1999/xlink",e.toLowerCase(),t):t==null||t===!1?s.removeAttribute(e):s.setAttribute(e,t))}function a1(s){return this.t[s.type](Be.event?Be.event(s):s)}function Tf(s,e,t,r,i,n,a,o,l,u){var c,d,m,h,f,p,v,C,P,M,F=e.type;if(e.constructor!==void 0)return null;(c=Be.__b)&&c(e);try{e:if(typeof F=="function"){if(C=e.props,P=(c=F.contextType)&&r[c.__c],M=c?P?P.props.value:c.__p:r,t.__c?v=(d=e.__c=t.__c).__p=d.__E:("prototype"in F&&F.prototype.render?e.__c=d=new F(C,M):(e.__c=d=new $i(C,M),d.constructor=F,d.render=qL),P&&P.sub(d),d.props=C,d.state||(d.state={}),d.context=M,d.__n=r,m=d.__d=!0,d.__h=[]),d.__s==null&&(d.__s=d.state),F.getDerivedStateFromProps!=null&&Qs(d.__s==d.state?d.__s=Qs({},d.__s):d.__s,F.getDerivedStateFromProps(C,d.__s)),m)F.getDerivedStateFromProps==null&&d.componentWillMount!=null&&d.componentWillMount(),d.componentDidMount!=null&&a.push(d);else{if(F.getDerivedStateFromProps==null&&o==null&&d.componentWillReceiveProps!=null&&d.componentWillReceiveProps(C,M),!o&&d.shouldComponentUpdate!=null&&d.shouldComponentUpdate(C,d.__s,M)===!1){for(d.props=C,d.state=d.__s,d.__d=!1,d.__v=e,e.__e=l!=null?l!==t.__e?l:t.__e:null,e.__k=t.__k,c=0;c<e.__k.length;c++)e.__k[c]&&(e.__k[c].__p=e);break e}d.componentWillUpdate!=null&&d.componentWillUpdate(C,d.__s,M)}for(h=d.props,f=d.state,d.context=M,d.props=C,d.state=d.__s,(c=Be.__r)&&c(e),d.__d=!1,d.__v=e,d.__P=s,c=d.render(d.props,d.state,d.context),e.__k=Df(c!=null&&c.type==Nu&&c.key==null?c.props.children:c),d.getChildContext!=null&&(r=Qs(Qs({},r),d.getChildContext())),m||d.getSnapshotBeforeUpdate==null||(p=d.getSnapshotBeforeUpdate(h,f)),T0(s,e,t,r,i,n,a,l,u),d.base=e.__e;c=d.__h.pop();)d.__s&&(d.state=d.__s),c.call(d);m||h==null||d.componentDidUpdate==null||d.componentDidUpdate(h,f,p),v&&(d.__E=d.__p=null)}else e.__e=ZL(t.__e,e,t,r,i,n,a,u);(c=Be.diffed)&&c(e)}catch(O){Be.__e(O,e,t)}return e.__e}function O0(s,e){for(var t;t=s.pop();)try{t.componentDidMount()}catch(r){Be.__e(r,t.__v)}Be.__c&&Be.__c(e)}function ZL(s,e,t,r,i,n,a,o){var l,u,c,d,m=t.props,h=e.props;if(i=e.type==="svg"||i,s==null&&n!=null){for(l=0;l<n.length;l++)if((u=n[l])!=null&&(e.type===null?u.nodeType===3:u.localName===e.type)){s=u,n[l]=null;break}}if(s==null){if(e.type===null)return document.createTextNode(h);s=i?document.createElementNS("http://www.w3.org/2000/svg",e.type):document.createElement(e.type),n=null}return e.type===null?m!==h&&(n!=null&&(n[n.indexOf(s)]=null),s.data=h):e!==t&&(n!=null&&(n=Pf.slice.call(s.childNodes)),c=(m=t.props||sr).dangerouslySetInnerHTML,d=h.dangerouslySetInnerHTML,o||(d||c)&&(d&&c&&d.__html==c.__html||(s.innerHTML=d&&d.__html||"")),GL(s,h,m,i,o),e.__k=e.props.children,d||T0(s,e,t,r,e.type!=="foreignObject"&&i,n,a,sr,o),o||("value"in h&&h.value!==void 0&&h.value!==s.value&&(s.value=h.value==null?"":h.value),"checked"in h&&h.checked!==void 0&&h.checked!==s.checked&&(s.checked=h.checked))),s}function M0(s,e,t){try{typeof s=="function"?s(e):s.current=e}catch(r){Be.__e(r,t)}}function k0(s,e,t){var r,i,n;if(Be.unmount&&Be.unmount(s),(r=s.ref)&&M0(r,null,e),t||typeof s.type=="function"||(t=(i=s.__e)!=null),s.__e=s.l=null,(r=s.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(a){Be.__e(a,e)}r.base=r.__P=null}if(r=s.__k)for(n=0;n<r.length;n++)r[n]&&k0(r[n],e,t);i!=null&&P0(i)}function qL(s,e,t){return this.constructor(s,t)}function XL(s,e,t){var r,i,n;Be.__p&&Be.__p(s,e),i=(r=t===S0)?null:e.__k,s=Fe(Nu,null,[s]),n=[],Tf(e,e.__k=s,i||sr,sr,e.ownerSVGElement!==void 0,i?null:Pf.slice.call(e.childNodes),n,!1,sr,r),O0(n,s)}Be={},$i.prototype.setState=function(s,e){var t=this.__s!==this.state&&this.__s||(this.__s=Qs({},this.state));(typeof s!="function"||(s=s(t,this.props)))&&Qs(t,s),s!=null&&this.__v&&(this.u=!1,e&&this.__h.push(e),Ud(this))},$i.prototype.forceUpdate=function(s){this.__v&&(s&&this.__h.push(s),this.u=!0,Ud(this))},$i.prototype.render=Nu,cc=[],w0=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,mh=Be.debounceRendering,Be.__e=function(s,e,t){for(var r;e=e.__p;)if((r=e.__c)&&!r.__p)try{if(r.constructor&&r.constructor.getDerivedStateFromError!=null)r.setState(r.constructor.getDerivedStateFromError(s));else{if(r.componentDidCatch==null)continue;r.componentDidCatch(s)}return Ud(r.__E=r)}catch(i){s=i}throw s},S0=sr;function YL(s,e){for(var t=0;t<e.length;t++){var r=e[t];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(s,r.key,r)}}function JL(s,e,t){return e&&YL(s.prototype,e),s}function Mt(){return Mt=Object.assign||function(s){for(var e=arguments,t=1;t<arguments.length;t++){var r=e[t];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(s[i]=r[i])}return s},Mt.apply(this,arguments)}var KL="[-\\+]?\\d+%?",QL="[-\\+]?\\d*\\.\\d+%?",Or="(?:"+QL+")|(?:"+KL+")",E0="[\\s|\\(]+("+Or+")[,|\\s]+("+Or+")[,|\\s]+("+Or+")\\s*\\)?",L0="[\\s|\\(]+("+Or+")[,|\\s]+("+Or+")[,|\\s]+("+Or+")[,|\\s]+("+Or+")\\s*\\)?",e8=new RegExp("rgb"+E0),t8=new RegExp("rgba"+L0),s8=new RegExp("hsl"+E0),r8=new RegExp("hsla"+L0),Vu="^(?:#?|0x?)",Mr="([0-9a-fA-F]{1})",kr="([0-9a-fA-F]{2})",i8=new RegExp(Vu+Mr+Mr+Mr+"$"),n8=new RegExp(Vu+Mr+Mr+Mr+Mr+"$"),a8=new RegExp(Vu+kr+kr+kr+"$"),o8=new RegExp(Vu+kr+kr+kr+kr+"$"),l8=2e3,c8=4e4,To=Math.log,ui=Math.round,Sn=Math.floor;function qt(s,e,t){return Math.min(Math.max(s,e),t)}function Tt(s,e){var t=s.indexOf("%")>-1,r=parseFloat(s);return t?e/100*r:r}function Ot(s){return parseInt(s,16)}function xr(s){return s.toString(16).padStart(2,"0")}var vi=function(){function s(t,r){this.$={h:0,s:0,v:0,a:1},t&&this.set(t),this.onChange=r,this.initialValue=Mt({},this.$)}var e=s.prototype;return e.set=function(r){if(typeof r=="string")/^(?:#?|0x?)[0-9a-fA-F]{3,8}$/.test(r)?this.hexString=r:/^rgba?/.test(r)?this.rgbString=r:/^hsla?/.test(r)&&(this.hslString=r);else if(typeof r=="object")r instanceof s?this.hsva=r.hsva:"r"in r&&"g"in r&&"b"in r?this.rgb=r:"h"in r&&"s"in r&&"v"in r?this.hsv=r:"h"in r&&"s"in r&&"l"in r?this.hsl=r:"kelvin"in r&&(this.kelvin=r.kelvin);else throw new Error("Invalid color value")},e.setChannel=function(r,i,n){var a;this[r]=Mt({},this[r],(a={},a[i]=n,a))},e.reset=function(){this.hsva=this.initialValue},e.clone=function(){return new s(this)},e.unbind=function(){this.onChange=void 0},s.hsvToRgb=function(r){var i=r.h/60,n=r.s/100,a=r.v/100,o=Sn(i),l=i-o,u=a*(1-n),c=a*(1-l*n),d=a*(1-(1-l)*n),m=o%6,h=[a,c,u,u,d,a][m],f=[d,a,a,c,u,u][m],p=[u,u,d,a,a,c][m];return{r:qt(h*255,0,255),g:qt(f*255,0,255),b:qt(p*255,0,255)}},s.rgbToHsv=function(r){var i=r.r/255,n=r.g/255,a=r.b/255,o=Math.max(i,n,a),l=Math.min(i,n,a),u=o-l,c=0,d=o,m=o===0?0:u/o;switch(o){case l:c=0;break;case i:c=(n-a)/u+(n<a?6:0);break;case n:c=(a-i)/u+2;break;case a:c=(i-n)/u+4;break}return{h:c*60%360,s:qt(m*100,0,100),v:qt(d*100,0,100)}},s.hsvToHsl=function(r){var i=r.s/100,n=r.v/100,a=(2-i)*n,o=a<=1?a:2-a,l=o<1e-9?0:i*n/o;return{h:r.h,s:qt(l*100,0,100),l:qt(a*50,0,100)}},s.hslToHsv=function(r){var i=r.l*2,n=r.s*(i<=100?i:200-i)/100,a=i+n<1e-9?0:2*n/(i+n);return{h:r.h,s:qt(a*100,0,100),v:qt((i+n)/2,0,100)}},s.kelvinToRgb=function(r){var i=r/100,n,a,o;return i<66?(n=255,a=-155.25485562709179-.44596950469579133*(a=i-2)+104.49216199393888*To(a),o=i<20?0:-254.76935184120902+.8274096064007395*(o=i-10)+115.67994401066147*To(o)):(n=351.97690566805693+.114206453784165*(n=i-55)-40.25366309332127*To(n),a=325.4494125711974+.07943456536662342*(a=i-50)-28.0852963507957*To(a),o=255),{r:qt(Sn(n),0,255),g:qt(Sn(a),0,255),b:qt(Sn(o),0,255)}},s.rgbToKelvin=function(r){for(var i=r.r,n=r.b,a=.4,o=l8,l=c8,u;l-o>a;){u=(l+o)*.5;var c=s.kelvinToRgb(u);c.b/c.r>=n/i?l=u:o=u}return u},JL(s,[{key:"hsv",get:function(){var r=this.$;return{h:r.h,s:r.s,v:r.v}},set:function(r){var i=this.$;if(r=Mt({},i,r),this.onChange){var n={h:!1,v:!1,s:!1,a:!1};for(var a in i)n[a]=r[a]!=i[a];this.$=r,(n.h||n.s||n.v||n.a)&&this.onChange(this,n)}else this.$=r}},{key:"hsva",get:function(){return Mt({},this.$)},set:function(r){this.hsv=r}},{key:"hue",get:function(){return this.$.h},set:function(r){this.hsv={h:r}}},{key:"saturation",get:function(){return this.$.s},set:function(r){this.hsv={s:r}}},{key:"value",get:function(){return this.$.v},set:function(r){this.hsv={v:r}}},{key:"alpha",get:function(){return this.$.a},set:function(r){this.hsv=Mt({},this.hsv,{a:r})}},{key:"kelvin",get:function(){return s.rgbToKelvin(this.rgb)},set:function(r){this.rgb=s.kelvinToRgb(r)}},{key:"red",get:function(){var r=this.rgb;return r.r},set:function(r){this.rgb=Mt({},this.rgb,{r})}},{key:"green",get:function(){var r=this.rgb;return r.g},set:function(r){this.rgb=Mt({},this.rgb,{g:r})}},{key:"blue",get:function(){var r=this.rgb;return r.b},set:function(r){this.rgb=Mt({},this.rgb,{b:r})}},{key:"rgb",get:function(){var r=s.hsvToRgb(this.$),i=r.r,n=r.g,a=r.b;return{r:ui(i),g:ui(n),b:ui(a)}},set:function(r){this.hsv=Mt({},s.rgbToHsv(r),{a:r.a===void 0?1:r.a})}},{key:"rgba",get:function(){return Mt({},this.rgb,{a:this.alpha})},set:function(r){this.rgb=r}},{key:"hsl",get:function(){var r=s.hsvToHsl(this.$),i=r.h,n=r.s,a=r.l;return{h:ui(i),s:ui(n),l:ui(a)}},set:function(r){this.hsv=Mt({},s.hslToHsv(r),{a:r.a===void 0?1:r.a})}},{key:"hsla",get:function(){return Mt({},this.hsl,{a:this.alpha})},set:function(r){this.hsl=r}},{key:"rgbString",get:function(){var r=this.rgb;return"rgb("+r.r+", "+r.g+", "+r.b+")"},set:function(r){var i,n,a,o,l=1;if((i=e8.exec(r))?(n=Tt(i[1],255),a=Tt(i[2],255),o=Tt(i[3],255)):(i=t8.exec(r))&&(n=Tt(i[1],255),a=Tt(i[2],255),o=Tt(i[3],255),l=Tt(i[4],1)),i)this.rgb={r:n,g:a,b:o,a:l};else throw new Error("Invalid rgb string")}},{key:"rgbaString",get:function(){var r=this.rgba;return"rgba("+r.r+", "+r.g+", "+r.b+", "+r.a+")"},set:function(r){this.rgbString=r}},{key:"hexString",get:function(){var r=this.rgb;return"#"+xr(r.r)+xr(r.g)+xr(r.b)},set:function(r){var i,n,a,o,l=255;if((i=i8.exec(r))?(n=Ot(i[1])*17,a=Ot(i[2])*17,o=Ot(i[3])*17):(i=n8.exec(r))?(n=Ot(i[1])*17,a=Ot(i[2])*17,o=Ot(i[3])*17,l=Ot(i[4])*17):(i=a8.exec(r))?(n=Ot(i[1]),a=Ot(i[2]),o=Ot(i[3])):(i=o8.exec(r))&&(n=Ot(i[1]),a=Ot(i[2]),o=Ot(i[3]),l=Ot(i[4])),i)this.rgb={r:n,g:a,b:o,a:l/255};else throw new Error("Invalid hex string")}},{key:"hex8String",get:function(){var r=this.rgba;return"#"+xr(r.r)+xr(r.g)+xr(r.b)+xr(Sn(r.a*255))},set:function(r){this.hexString=r}},{key:"hslString",get:function(){var r=this.hsl;return"hsl("+r.h+", "+r.s+"%, "+r.l+"%)"},set:function(r){var i,n,a,o,l=1;if((i=s8.exec(r))?(n=Tt(i[1],360),a=Tt(i[2],100),o=Tt(i[3],100)):(i=r8.exec(r))&&(n=Tt(i[1],360),a=Tt(i[2],100),o=Tt(i[3],100),l=Tt(i[4],1)),i)this.hsl={h:n,s:a,l:o,a:l};else throw new Error("Invalid hsl string")}},{key:"hslaString",get:function(){var r=this.hsla;return"hsla("+r.h+", "+r.s+"%, "+r.l+"%, "+r.a+")"},set:function(r){this.hslString=r}}]),s}(),u8={sliderShape:"bar",sliderType:"value",minTemperature:2200,maxTemperature:11e3};function Of(s){var e,t=s.width,r=s.sliderSize,i=s.borderWidth,n=s.handleRadius,a=s.padding,o=s.sliderShape,l=s.layoutDirection==="horizontal";return r=(e=r)!=null?e:a*2+n*2,o==="circle"?{handleStart:s.padding+s.handleRadius,handleRange:t-a*2-n*2,width:t,height:t,cx:t/2,cy:t/2,radius:t/2-i/2}:{handleStart:r/2,handleRange:t-r,radius:r/2,x:0,y:0,width:l?r:t,height:l?t:r}}function d8(s,e){var t=e.hsva,r=e.rgb;switch(s.sliderType){case"red":return r.r/2.55;case"green":return r.g/2.55;case"blue":return r.b/2.55;case"alpha":return t.a*100;case"kelvin":var i=s.minTemperature,n=s.maxTemperature,a=n-i,o=(e.kelvin-i)/a*100;return Math.max(0,Math.min(o,100));case"hue":return t.h/=3.6;case"saturation":return t.s;case"value":default:return t.v}}function m8(s,e,t){var r=Of(s),i=r.handleRange,n=r.handleStart,a;s.layoutDirection==="horizontal"?a=-1*t+i+n:a=e-n,a=Math.max(Math.min(a,i),0);var o=Math.round(100/i*a);switch(s.sliderType){case"kelvin":var l=s.minTemperature,u=s.maxTemperature,c=u-l;return l+c*(o/100);case"alpha":return o/100;case"hue":return o*3.6;case"red":case"blue":case"green":return o*2.55;default:return o}}function h8(s,e){var t=Of(s),r=t.width,i=t.height,n=t.handleRange,a=t.handleStart,o=s.layoutDirection==="horizontal",l=d8(s,e),u=o?r/2:i/2,c=a+l/100*n;return o&&(c=-1*c+n+a*2),{x:o?u:c,y:o?c:u}}function p8(s,e){var t=e.hsv,r=e.rgb;switch(s.sliderType){case"red":return[[0,"rgb(0,"+r.g+","+r.b+")"],[100,"rgb(255,"+r.g+","+r.b+")"]];case"green":return[[0,"rgb("+r.r+",0,"+r.b+")"],[100,"rgb("+r.r+",255,"+r.b+")"]];case"blue":return[[0,"rgb("+r.r+","+r.g+",0)"],[100,"rgb("+r.r+","+r.g+",255)"]];case"alpha":return[[0,"rgba("+r.r+","+r.g+","+r.b+",0)"],[100,"rgb("+r.r+","+r.g+","+r.b+")"]];case"kelvin":for(var i=[],n=s.minTemperature,a=s.maxTemperature,o=8,l=a-n,u=n,c=0;u<a;u+=l/o,c+=1){var d=vi.kelvinToRgb(u),m=d.r,h=d.g,f=d.b;i.push([100/o*c,"rgb("+m+","+h+","+f+")"])}return i;case"hue":return[[0,"#f00"],[16.666,"#ff0"],[33.333,"#0f0"],[50,"#0ff"],[66.666,"#00f"],[83.333,"#f0f"],[100,"#f00"]];case"saturation":var p=vi.hsvToHsl({h:t.h,s:0,v:t.v}),v=vi.hsvToHsl({h:t.h,s:100,v:t.v});return[[0,"hsl("+p.h+","+p.s+"%,"+p.l+"%)"],[100,"hsl("+v.h+","+v.s+"%,"+v.l+"%)"]];case"value":default:var C=vi.hsvToHsl({h:t.h,s:t.s,v:100});return[[0,"#000"],[100,"hsl("+C.h+","+C.s+"%,"+C.l+"%)"]]}}var A0=Math.PI*2,f8=function(e,t){return(e%t+t)%t},F0=function(e,t){return Math.sqrt(e*e+t*t)};function R0(s){return s.width/2-s.padding-s.handleRadius-s.borderWidth}function g8(s,e,t){var r=Bu(s),i=r.cx,n=r.cy,a=s.width/2;return F0(i-e,n-t)<a}function Bu(s){var e=s.width/2;return{width:s.width,radius:e-s.borderWidth,cx:e,cy:e}}function H0(s,e,t){var r=s.wheelAngle,i=s.wheelDirection;return t&&i==="clockwise"?e=r+e:i==="clockwise"?e=360-r+e:t&&i==="anticlockwise"?e=r+180-e:i==="anticlockwise"&&(e=r-e),f8(e,360)}function _8(s,e){var t=e.hsv,r=Bu(s),i=r.cx,n=r.cy,a=R0(s),o=(180+H0(s,t.h,!0))*(A0/360),l=t.s/100*a,u=s.wheelDirection==="clockwise"?-1:1;return{x:i+l*Math.cos(o)*u,y:n+l*Math.sin(o)*u}}function o1(s,e,t){var r=Bu(s),i=r.cx,n=r.cy,a=R0(s);e=i-e,t=n-t;var o=H0(s,Math.atan2(-t,-e)*(360/A0)),l=Math.min(F0(e,t),a);return{h:Math.round(o),s:Math.round(100/a*l)}}function Mf(s){var e=s.width,t=s.boxHeight,r=s.padding,i=s.handleRadius;return{width:e,height:t!=null?t:e,radius:r+i}}function l1(s,e,t){var r=Mf(s),i=r.width,n=r.height,a=r.radius,o=a,l=i-a*2,u=n-a*2,c=(e-o)/l*100,d=(t-o)/u*100;return{s:Math.max(0,Math.min(c,100)),v:Math.max(0,Math.min(100-d,100))}}function v8(s,e){var t=Mf(s),r=t.width,i=t.height,n=t.radius,a=e.hsv,o=n,l=r-n*2,u=i-n*2;return{x:o+a.s/100*l,y:o+(u-a.v/100*u)}}function b8(s,e){var t=e.hue;return[[[0,"#fff"],[100,"hsl("+t+",100%,50%)"]],[[0,"rgba(0,0,0,0)"],[100,"#000"]]]}var Wd;function y8(s){Wd||(Wd=document.getElementsByTagName("base"));var e=window.navigator.userAgent,t=/^((?!chrome|android).)*safari/i.test(e),r=/iPhone|iPod|iPad/i.test(e),i=window.location;return(t||r)&&Wd.length>0?i.protocol+"//"+i.host+i.pathname+i.search+s:s}function j0(s,e,t,r){for(var i=0;i<r.length;i++){var n=r[i].x-e,a=r[i].y-t,o=Math.sqrt(n*n+a*a);if(o<s.handleRadius)return i}return null}function kf(s){return{boxSizing:"border-box",border:s.borderWidth+"px solid "+s.borderColor}}function ph(s,e,t){return s+"-gradient("+e+", "+t.map(function(r){var i=r[0],n=r[1];return n+" "+i+"%"}).join(",")+")"}function $t(s){return typeof s=="string"?s:s+"px"}var C8={width:300,height:300,color:"#fff",colors:[],padding:6,layoutDirection:"vertical",borderColor:"#fff",borderWidth:0,handleRadius:8,activeHandleRadius:null,handleSvg:null,handleProps:{x:0,y:0},wheelLightness:!0,wheelAngle:0,wheelDirection:"anticlockwise",sliderSize:null,sliderMargin:12,boxHeight:null},c1=["mousemove","touchmove","mouseup","touchend"],Uu=function(s){function e(t){s.call(this,t),this.uid=(Math.random()+1).toString(36).substring(5)}return s&&(e.__proto__=s),e.prototype=Object.create(s&&s.prototype),e.prototype.constructor=e,e.prototype.render=function(r){var i=this.handleEvent.bind(this),n={onMouseDown:i,ontouchstart:i},a=r.layoutDirection==="horizontal",o=r.margin===null?r.sliderMargin:r.margin,l={overflow:"visible",display:a?"inline-block":"block"};return r.index>0&&(l[a?"marginLeft":"marginTop"]=o),Fe(Nu,null,r.children(this.uid,n,l))},e.prototype.handleEvent=function(r){var i=this,n=this.props.onInput,a=this.base.getBoundingClientRect();r.preventDefault();var o=r.touches?r.changedTouches[0]:r,l=o.clientX-a.left,u=o.clientY-a.top;switch(r.type){case"mousedown":case"touchstart":var c=n(l,u,0);c!==!1&&c1.forEach(function(d){document.addEventListener(d,i,{passive:!1})});break;case"mousemove":case"touchmove":n(l,u,1);break;case"mouseup":case"touchend":n(l,u,2),c1.forEach(function(d){document.removeEventListener(d,i,{passive:!1})});break}},e}($i);function Gr(s){var e=s.r,t=s.url,r=e,i=e;return Fe("svg",{className:"IroHandle IroHandle--"+s.index+" "+(s.isActive?"IroHandle--isActive":""),style:{"-webkit-tap-highlight-color":"rgba(0, 0, 0, 0);",transform:"translate("+$t(s.x)+", "+$t(s.y)+")",willChange:"transform",top:$t(-e),left:$t(-e),width:$t(e*2),height:$t(e*2),position:"absolute",overflow:"visible"}},t&&Fe("use",Object.assign({xlinkHref:y8(t)},s.props)),!t&&Fe("circle",{cx:r,cy:i,r:e,fill:"none","stroke-width":2,stroke:"#000"}),!t&&Fe("circle",{cx:r,cy:i,r:e-2,fill:s.fill,"stroke-width":2,stroke:"#fff"}))}Gr.defaultProps={fill:"none",x:0,y:0,r:8,url:null,props:{x:0,y:0}};function dc(s){var e=s.activeIndex,t=e!==void 0&&e<s.colors.length?s.colors[e]:s.color,r=Of(s),i=r.width,n=r.height,a=r.radius,o=h8(s,t),l=p8(s,t);function u(c,d,m){var h=m8(s,c,d);s.parent.inputActive=!0,t[s.sliderType]=h,s.onInput(m,s.id)}return Fe(Uu,Object.assign({},s,{onInput:u}),function(c,d,m){return Fe("div",Object.assign({},d,{className:"IroSlider",style:Object.assign({},{position:"relative",width:$t(i),height:$t(n),borderRadius:$t(a),background:"conic-gradient(#ccc 25%, #fff 0 50%, #ccc 0 75%, #fff 0)",backgroundSize:"8px 8px"},m)}),Fe("div",{className:"IroSliderGradient",style:Object.assign({},{position:"absolute",top:0,left:0,width:"100%",height:"100%",borderRadius:$t(a),background:ph("linear",s.layoutDirection==="horizontal"?"to top":"to right",l)},kf(s))}),Fe(Gr,{isActive:!0,index:t.index,r:s.handleRadius,url:s.handleSvg,props:s.handleProps,x:o.x,y:o.y}))})}dc.defaultProps=Object.assign({},u8);function $8(s){var e=Mf(s),t=e.width,r=e.height,i=e.radius,n=s.colors,a=s.parent,o=s.activeIndex,l=o!==void 0&&o<s.colors.length?s.colors[o]:s.color,u=b8(s,l),c=n.map(function(m){return v8(s,m)});function d(m,h,f){if(f===0){var p=j0(s,m,h,c);p!==null?a.setActiveColor(p):(a.inputActive=!0,l.hsv=l1(s,m,h),s.onInput(f,s.id))}else f===1&&(a.inputActive=!0,l.hsv=l1(s,m,h));s.onInput(f,s.id)}return Fe(Uu,Object.assign({},s,{onInput:d}),function(m,h,f){return Fe("div",Object.assign({},h,{className:"IroBox",style:Object.assign({},{width:$t(t),height:$t(r),position:"relative"},f)}),Fe("div",{className:"IroBox",style:Object.assign({},{width:"100%",height:"100%",borderRadius:$t(i)},kf(s),{background:ph("linear","to bottom",u[1])+","+ph("linear","to right",u[0])})}),n.filter(function(p){return p!==l}).map(function(p){return Fe(Gr,{isActive:!1,index:p.index,fill:p.hslString,r:s.handleRadius,url:s.handleSvg,props:s.handleProps,x:c[p.index].x,y:c[p.index].y})}),Fe(Gr,{isActive:!0,index:l.index,fill:l.hslString,r:s.activeHandleRadius||s.handleRadius,url:s.handleSvg,props:s.handleProps,x:c[l.index].x,y:c[l.index].y}))})}var x8="conic-gradient(red, yellow, lime, aqua, blue, magenta, red)",w8="conic-gradient(red, magenta, blue, aqua, lime, yellow, red)";function I0(s){var e=Bu(s),t=e.width,r=s.colors;s.borderWidth;var i=s.parent,n=s.color,a=n.hsv,o=r.map(function(c){return _8(s,c)}),l={position:"absolute",top:0,left:0,width:"100%",height:"100%",borderRadius:"50%",boxSizing:"border-box"};function u(c,d,m){if(m===0){if(!g8(s,c,d))return!1;var h=j0(s,c,d,o);h!==null?i.setActiveColor(h):(i.inputActive=!0,n.hsv=o1(s,c,d),s.onInput(m,s.id))}else m===1&&(i.inputActive=!0,n.hsv=o1(s,c,d));s.onInput(m,s.id)}return Fe(Uu,Object.assign({},s,{onInput:u}),function(c,d,m){return Fe("div",Object.assign({},d,{className:"IroWheel",style:Object.assign({},{width:$t(t),height:$t(t),position:"relative"},m)}),Fe("div",{className:"IroWheelHue",style:Object.assign({},l,{transform:"rotateZ("+(s.wheelAngle+90)+"deg)",background:s.wheelDirection==="clockwise"?x8:w8})}),Fe("div",{className:"IroWheelSaturation",style:Object.assign({},l,{background:"radial-gradient(circle closest-side, #fff, transparent)"})}),s.wheelLightness&&Fe("div",{className:"IroWheelLightness",style:Object.assign({},l,{background:"#000",opacity:1-a.v/100})}),Fe("div",{className:"IroWheelBorder",style:Object.assign({},l,kf(s))}),r.filter(function(h){return h!==n}).map(function(h){return Fe(Gr,{isActive:!1,index:h.index,fill:h.hslString,r:s.handleRadius,url:s.handleSvg,props:s.handleProps,x:o[h.index].x,y:o[h.index].y})}),Fe(Gr,{isActive:!0,index:n.index,fill:n.hslString,r:s.activeHandleRadius||s.handleRadius,url:s.handleSvg,props:s.handleProps,x:o[n.index].x,y:o[n.index].y}))})}function S8(s){var e=function(t,r){var i,n=document.createElement("div");XL(Fe(s,Object.assign({},{ref:function(o){return i=o}},r)),n);function a(){var o=t instanceof Element?t:document.querySelector(t);o.appendChild(i.base),i.onMount(o)}return document.readyState!=="loading"?a():document.addEventListener("DOMContentLoaded",a),i};return e.prototype=s.prototype,Object.assign(e,s),e.__component=s,e}var N0=function(s){function e(t){var r=this;s.call(this,t),this.colors=[],this.inputActive=!1,this.events={},this.activeEvents={},this.deferredEvents={},this.id=t.id;var i=t.colors.length>0?t.colors:[t.color];i.forEach(function(n){return r.addColor(n)}),this.setActiveColor(0),this.state=Object.assign({},t,{color:this.color,colors:this.colors,layout:t.layout})}return s&&(e.__proto__=s),e.prototype=Object.create(s&&s.prototype),e.prototype.constructor=e,e.prototype.addColor=function(r,i){i===void 0&&(i=this.colors.length);var n=new vi(r,this.onColorChange.bind(this));this.colors.splice(i,0,n),this.colors.forEach(function(a,o){return a.index=o}),this.state&&this.setState({colors:this.colors}),this.deferredEmit("color:init",n)},e.prototype.removeColor=function(r){var i=this.colors.splice(r,1)[0];i.unbind(),this.colors.forEach(function(n,a){return n.index=a}),this.state&&this.setState({colors:this.colors}),i.index===this.color.index&&this.setActiveColor(0),this.emit("color:remove",i)},e.prototype.setActiveColor=function(r){this.color=this.colors[r],this.state&&this.setState({color:this.color}),this.emit("color:setActive",this.color)},e.prototype.setColors=function(r,i){var n=this;i===void 0&&(i=0),this.colors.forEach(function(a){return a.unbind()}),this.colors=[],r.forEach(function(a){return n.addColor(a)}),this.setActiveColor(i),this.emit("color:setAll",this.colors)},e.prototype.on=function(r,i){var n=this,a=this.events;(Array.isArray(r)?r:[r]).forEach(function(o){(a[o]||(a[o]=[])).push(i),n.deferredEvents[o]&&(n.deferredEvents[o].forEach(function(l){i.apply(null,l)}),n.deferredEvents[o]=[])})},e.prototype.off=function(r,i){var n=this;(Array.isArray(r)?r:[r]).forEach(function(a){var o=n.events[a];o&&o.splice(o.indexOf(i),1)})},e.prototype.emit=function(r){for(var i=this,n=[],a=arguments.length-1;a-- >0;)n[a]=arguments[a+1];var o=this.activeEvents,l=o.hasOwnProperty(r)?o[r]:!1;if(!l){o[r]=!0;var u=this.events[r]||[];u.forEach(function(c){return c.apply(i,n)}),o[r]=!1}},e.prototype.deferredEmit=function(r){for(var i,n=[],a=arguments.length-1;a-- >0;)n[a]=arguments[a+1];var o=this.deferredEvents;(i=this).emit.apply(i,[r].concat(n)),(o[r]||(o[r]=[])).push(n)},e.prototype.setOptions=function(r){this.setState(r)},e.prototype.resize=function(r){this.setOptions({width:r})},e.prototype.reset=function(){this.colors.forEach(function(r){return r.reset()}),this.setState({colors:this.colors})},e.prototype.onMount=function(r){this.el=r,this.deferredEmit("mount",this)},e.prototype.onColorChange=function(r,i){this.setState({color:this.color}),this.inputActive&&(this.inputActive=!1,this.emit("input:change",r,i)),this.emit("color:change",r,i)},e.prototype.emitInputEvent=function(r,i){r===0?this.emit("input:start",this.color,i):r===1?this.emit("input:move",this.color,i):r===2&&this.emit("input:end",this.color,i)},e.prototype.render=function(r,i){var n=this,a=i.layout;if(!Array.isArray(a)){switch(a){default:a=[{component:I0},{component:dc}]}i.transparency&&a.push({component:dc,options:{sliderType:"alpha"}})}return Fe("div",{class:"IroColorPicker",id:i.id,style:{display:i.display}},a.map(function(o,l){var u=o.component,c=o.options;return Fe(u,Object.assign({},i,c,{ref:void 0,onInput:n.emitInputEvent.bind(n),parent:n,index:l}))}))},e}($i);N0.defaultProps=Object.assign({},C8,{colors:[],display:"block",id:null,layout:"default",margin:null});var P8=S8(N0),fh;(function(s){s.version="5.5.2",s.Color=vi,s.ColorPicker=P8,function(e){e.h=Fe,e.ComponentBase=Uu,e.Handle=Gr,e.Slider=dc,e.Wheel=I0,e.Box=$8}(s.ui||(s.ui={}))})(fh||(fh={}));var Ut=fh,D8=Object.defineProperty,T8=Object.getOwnPropertyDescriptor,no=(s,e,t,r)=>{for(var i=r>1?void 0:r?T8(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&D8(e,t,i),i};let Zr=class extends k(L){constructor(){super(...arguments),this.colorPicker=null}colorChanged(s){this.colorPicker&&this.colorPicker.color.rgbString!==s&&(this.colorPicker.color.rgbString=s)}get internalOptions(){return{...this.options,color:this.color,borderWidth:2,sliderSize:16}}emitColorChange(s){this.$emit("change",s),this.$emit("update:color",s)}onColorChange(s){this.emitColorChange(s)}mounted(){this.colorPicker=Ut.ColorPicker(this.picker,this.internalOptions),this.colorPicker.on("color:change",this.onColorChange)}beforeDestroy(){var s;(s=this.colorPicker)==null||s.off("color:change",this.onColorChange)}};no([Ts("picker")],Zr.prototype,"picker",2);no([w({type:[Object,String],default:"#ffffff"})],Zr.prototype,"color",2);no([w({type:Object,default:()=>({})})],Zr.prototype,"options",2);no([he("color",{deep:!0})],Zr.prototype,"colorChanged",1);Zr=no([S],Zr);var O8=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t("div",{ref:"picker"})])},M8=[],k8=E(Zr,O8,M8,!1,null,"133d9be7");const _a=k8.exports;var E8=Object.defineProperty,L8=Object.getOwnPropertyDescriptor,ii=(s,e,t,r)=>{for(var i=r>1?void 0:r?L8(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&E8(e,t,i),i};let Vs=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiLightbulbOutline=zp,this.mdiLightbulbOnOutline=lv,this.boolDialog=!1,this.inputValue=0}get name(){return this.group?Ye(this.group.name):Ye(this.object.name)}get colorPickerOptions(){let s={width:200,margin:15,layout:[]};return this.existRed&&(s==null||s.layout.push({component:Ut.ui.Slider,options:{sliderType:"red"}})),this.existGreen&&(s==null||s.layout.push({component:Ut.ui.Slider,options:{sliderType:"green"}})),this.existBlue&&(s==null||s.layout.push({component:Ut.ui.Slider,options:{sliderType:"blue"}})),this.existRed&&this.existGreen&&this.existBlue&&(s.layout=[{component:Ut.ui.Wheel},{component:Ut.ui.Slider,options:{sliderType:"value"}}]),s}get colorPickerWhiteOptions(){return{width:200,margin:15,layout:[{component:Ut.ui.Slider,options:{sliderType:"alpha"}}]}}get optionsColors(){let s=[];return this.presets.forEach(e=>{s.push("rgb(".concat(e.red,"%, ").concat(e.green,"%, ").concat(e.blue,"%)"))}),s}get current(){var t,r;const s={red:0,green:0,blue:0,white:null};if(this.existWhite&&(s.white=0),this.object.colorData.length===0)return s;const e=this.object.colorData[((r=(t=this.group)==null?void 0:t.start)!=null?r:1)-1];return s.red=e[0]*255,s.green=e[1]*255,s.blue=e[2]*255,this.object.colorOrder.indexOf("W")!==-1&&(s.white=e[3]*255),s}get isOn(){var s,e,t,r,i;return((s=this.current.red)!=null?s:0)+((t=(e=this.current)==null?void 0:e.green)!=null?t:0)+((r=this.current.blue)!=null?r:0)+((i=this.current.white)!=null?i:0)>0}get existRed(){return this.object.colorOrder.indexOf("R")!==-1}get existGreen(){return this.object.colorOrder.indexOf("G")!==-1}get existBlue(){return this.object.colorOrder.indexOf("B")!==-1}get existWhite(){return this.object.colorOrder.indexOf("W")!==-1}get currentStateStyle(){let s=this.colorRGB;return this.current.white!==null&&this.current.red==0&&this.current.green==0&&this.current.blue==0&&(s="rgb(".concat(this.current.white*255,", ").concat(this.current.white*255,", ").concat(this.current.white*255,")")),{"background-color":s}}get colorRGB(){var s,e,t;return"rgb(".concat(Math.round((s=this.current.red)!=null?s:0),", ").concat(Math.round((e=this.current.green)!=null?e:0),", ").concat(Math.round((t=this.current.blue)!=null?t:0),")")}get colorRGBW(){var s;return"rgba(255, 255, 255, ".concat(((s=this.current.white)!=null?s:0)/255,")")}get redInt(){var s;return Math.round((s=this.current.red)!=null?s:0)}get greenInt(){var s;return Math.round((s=this.current.green)!=null?s:0)}get blueInt(){var s;return Math.round((s=this.current.blue)!=null?s:0)}get whiteInt(){var s;return Math.round((s=this.current.white)!=null?s:0)}get groups(){var s;return this.root?(s=this.$store.getters["gui/miscellaneous/getEntryLightgroups"]({type:this.object.type,name:this.object.name}))!=null?s:[]:[]}get presets(){var s;return(s=this.$store.getters["gui/miscellaneous/getEntryPresets"]({type:this.object.type,name:this.object.name}))!=null?s:[]}get containerClass(){let s=["px-0"];return s.push(this.root?"py-2":"pt-2 pb-0"),s}colorChanged(s){var a,o,l,u,c,d,m,h,f,p,v,C;if(Math.round((a=s.red)!=null?a:0)===Math.round((o=this.current.red)!=null?o:0)&&Math.round((l=s.green)!=null?l:0)===Math.round((u=this.current.green)!=null?u:0)&&Math.round((c=s.blue)!=null?c:0)===Math.round((d=this.current.blue)!=null?d:0)&&Math.round((m=s.white)!=null?m:0)===Math.round((h=this.current.white)!=null?h:0))return;const e=Math.round(((f=s.red)!=null?f:0)/255*1e4)/1e4,t=Math.round(((p=s.green)!=null?p:0)/255*1e4)/1e4,r=Math.round(((v=s.blue)!=null?v:0)/255*1e4)/1e4,i=Math.round(((C=s.white)!=null?C:0)/255*1e4)/1e4;let n='SET_LED LED="'.concat(this.object.name,'" RED=').concat(e," GREEN=").concat(t," BLUE=").concat(r);if(this.existWhite&&(n+=" WHITE=".concat(i)),n+=" SYNC=0",this.group){const P=n;for(let M=this.group.start;M<=this.group.end;M++){if(M===this.group.start){n+=" INDEX=".concat(M);continue}n+="\n".concat(P," INDEX=").concat(M)}}n+=" TRANSMIT=1",this.$store.dispatch("server/addEvent",{message:n,type:"command"}),this.$socket.emit("printer.gcode.script",{script:n})}onColorRGBChanged(s){const e={red:s.red,green:s.green,blue:s.blue,white:this.current.white};this.colorChanged(e)}onColorWhiteChanged(s){const e={red:this.current.red,green:this.current.green,blue:this.current.blue,white:this.current.white};e.white=s.alpha*255,this.colorChanged(e)}onColorInput(s){const e={red:this.current.red,green:this.current.green,blue:this.current.blue,white:this.current.white};e[s.name]=s.value,this.colorChanged(e)}off(){const s={red:0,green:0,blue:0,white:0};this.colorChanged(s)}on(){const s={red:255,green:255,blue:255,white:255};this.colorChanged(s)}presetStyle(s){var e,t,r,i;return((e=s==null?void 0:s.red)!=null?e:0)+((t=s==null?void 0:s.green)!=null?t:0)+((r=s==null?void 0:s.blue)!=null?r:0)===0&&((i=s==null?void 0:s.white)!=null?i:0)>0?{backgroundColor:"rgb(".concat(s.white,"%, ").concat(s.white,"%, ").concat(s.white,"%)")}:{backgroundColor:"rgb(".concat(s.red,"%, ").concat(s.green,"%, ").concat(s.blue,"%)")}}usePreset(s){const e={...s};this.colorChanged(e)}};ii([w({type:Object,required:!0})],Vs.prototype,"object",2);ii([w({type:Boolean,default:!1})],Vs.prototype,"root",2);ii([w(Object)],Vs.prototype,"group",2);ii([Ke({time:500})],Vs.prototype,"onColorRGBChanged",1);ii([Ke({time:500})],Vs.prototype,"onColorWhiteChanged",1);ii([Ke({time:500})],Vs.prototype,"onColorInput",1);Vs=ii([S({components:{ColorPicker:_a}})],Vs);var A8=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Ee,{class:e.containerClass},[t(x,[t(b,{staticClass:"pb-3"},[t(cs,{staticClass:"_light-subheader"},[(!e.root||e.groups.length===0)&&e.isOn?t(_,{attrs:{small:"",left:""},on:{click:e.off}},[e._v(" "+e._s(e.mdiLightbulbOnOutline)+" ")]):!e.root||e.groups.length===0?t(_,{attrs:{small:"",left:""},on:{click:e.on}},[e._v(" "+e._s(e.mdiLightbulbOutline)+" ")]):e._e(),t("span",[e._v(e._s(e.name))]),t(ae),!e.root||e.groups.length===0?t("span",{staticClass:"_currentState",style:e.currentStateStyle,on:{click:function(r){e.boolDialog=!0}}}):e._e()],1)],1)],1),e._l(e.groups,function(r){return t("miscellaneous-light",{key:r.id,attrs:{object:e.object,group:r}})}),t(le,{attrs:{persistent:"",width:400},model:{value:e.boolDialog,callback:function(r){e.boolDialog=r},expression:"boolDialog"}},[t(U,{attrs:{title:e.name,icon:e.mdiLightbulbOutline,"card-class":"temperature-edit-heater-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.boolDialog=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{staticClass:"pt-6"},[e.presets.length?[t(x,[t(b,{staticClass:"light-presets-container pt-0 d-flex flex-wrap flex-row justify-center"},e._l(e.presets,function(r){return t(de,{key:r.id,attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:i,attrs:n}){return[t("div",e._g(e._b({style:e.presetStyle(r),on:{click:function(a){return e.usePreset(r)}}},"div",n,!1),i))]}}],null,!0)},[t("span",[e._v(e._s(r.name))])])}),1)],1),t(I,{staticClass:"my-3"})]:e._e(),t(x,[t(b,{staticClass:"text-center"},[t(_a,{attrs:{color:e.colorRGB,options:e.colorPickerOptions},on:{"update:color":e.onColorRGBChanged}}),e.existWhite?t(_a,{staticClass:"mt-3",attrs:{color:e.colorRGBW,options:e.colorPickerWhiteOptions},on:{"update:color":e.onColorWhiteChanged}}):e._e()],1),t(b,[e.existRed?t(x,[t(b,[t(He,{attrs:{label:e.$t("Panels.MiscellaneousPanel.Light.Red"),param:"red",target:e.redInt,"default-value":Math.round(e.object.initialRed*255),min:0,max:255,dec:1,step:1,"output-error-msg":!0,"has-spinner":!0},on:{submit:e.onColorInput}})],1)],1):e._e(),e.existGreen?t(x,[t(b,[t(He,{attrs:{label:e.$t("Panels.MiscellaneousPanel.Light.Green"),param:"green",target:e.greenInt,"default-value":Math.round(e.object.initialGreen*255),min:0,max:255,dec:1,step:1,"has-spinner":!0},on:{submit:e.onColorInput}})],1)],1):e._e(),e.existBlue?t(x,[t(b,[t(He,{attrs:{label:e.$t("Panels.MiscellaneousPanel.Light.Blue"),param:"blue",target:e.blueInt,"default-value":Math.round(e.object.initialBlue*255),min:0,max:255,dec:1,step:1,"has-spinner":!0},on:{submit:e.onColorInput}})],1)],1):e._e(),e.existWhite?t(x,[t(b,[t(He,{attrs:{label:e.$t("Panels.MiscellaneousPanel.Light.White"),param:"white",target:e.whiteInt,"default-value":Math.round(e.object.initialWhite*255),min:0,max:255,dec:1,step:1,"has-spinner":!0},on:{submit:e.onColorInput}})],1)],1):e._e()],1)],1)],2)],1)],1)],2)},F8=[],R8=E(Vs,A8,F8,!1,null,"422e078f");const V0=R8.exports;var H8=Object.defineProperty,j8=Object.getOwnPropertyDescriptor,wt=(s,e,t,r)=>{for(var i=r>1?void 0:r?j8(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&H8(e,t,i),i};let mt=class extends k(L){constructor(){super(...arguments),this.mdiFan=Ip,this.mdiToggleSwitch=Yp,this.mdiToggleSwitchOffOutline=Ov,this.mdiLockOutline=fu,this.mdiLockOpenVariantOutline=uv,this.mdiMinus=mv,this.mdiPlus=qp,this.mdiLightbulbOutline=zp,this.mdiLightbulbOnOutline=lv,this.convertName=Ye,this.isLocked=!1,this.invalidChars=["e","E","+"],this.min=0,this.inputValue=0,this.sliderValue=0}get value(){return Math.round(this.target/this.max*100)/100}lockSlidersChanged(){this.isLocked=this.lockSliders&&this.isTouchDevice}startLockTimer(){let s=this.lockSlidersDelay;!this.isTouchDevice||!this.lockSliders||s<=0||(this.timeout=setTimeout(()=>this.isLocked=!0,s*1e3))}resetLockTimer(){clearTimeout(this.timeout)}get lockSliders(){return this.$store.state.gui.uiSettings.lockSlidersOnTouchDevices}get lockSlidersDelay(){return this.$store.state.gui.uiSettings.lockSlidersDelay}changeSliderValue(){this.value!==this.sliderValue&&(this.sliderValue<this.value&&this.sliderValue<this.off_below?this.sliderValue=0:this.sliderValue>this.value&&this.sliderValue<this.off_below&&(this.sliderValue=this.off_below),this.sendCmd(this.sliderValue))}sendCmd(s){if(this.value===s)return;s<this.min&&(s=0),s=s*this.multi;let e="SET_PIN PIN=".concat(this.name," VALUE=").concat(s.toFixed(2));this.type==="fan"&&(e="M106 S".concat(s.toFixed(0))),this.type==="fan_generic"&&(e="SET_FAN_SPEED FAN=".concat(this.name," SPEED=").concat(s)),this.type==="led"&&(e="SET_LED LED=".concat(this.name," ").concat(this.ledChannelName,"=").concat(s.toFixed(2)," SYNC=0 TRANSMIT=1")),e!==""&&(this.$store.dispatch("server/addEvent",{message:e,type:"command"}),this.$socket.emit("printer.gcode.script",{script:e})),this.startLockTimer()}ledOff(){this.sendCmd(0)}ledOn(){this.sendCmd(1)}switchOutputPin(){const s=this.value?0:1,e="SET_PIN PIN=".concat(this.name," VALUE=").concat((s*this.multi).toFixed(2));this.$store.dispatch("server/addEvent",{message:e,type:"command"}),this.$socket.emit("printer.gcode.script",{script:e})}decrement(){let s=this.value>0?Math.round((this.value-.01)*100)/100:0;this.value<this.off_below&&(s=0),this.sendCmd(s)}increment(){let s=this.value<1?Math.round((this.value+.01)*100)/100:1;this.value<this.off_below&&(s=this.off_below),this.sendCmd(s)}mounted(){this.sliderValue=this.value}valueChanged(s){this.sliderValue=s}sliderValueChanged(s){this.inputValue=Math.round(s*100)}checkInvalidChars(s){this.min>=0&&this.invalidChars.push("-"),this.invalidChars.includes(s.key)&&s.preventDefault()}get errors(){const s=[],e=this.inputValue/100;return this.inputValue.toString()===""&&s.push(this.$t("App.NumberInput.NoEmptyAllowedError")),e<this.min&&s.push(this.$t("App.NumberInput.GreaterOrEqualError",{min:this.min*100})),s}get disableFanAnimation(){var s;return(s=this.$store.state.gui.uiSettings.disableFanAnimation)!=null?s:!1}get fanClasses(){const s=["mr-2"];return!this.disableFanAnimation&&this.value>=this.off_below&&this.value>0&&s.push("icon-rotate"),s}get rpmClasses(){const s=[];return this.controllable?s.push(["mt-2"]):s.push(["mr-3","mt-1"]),this.rpm===0&&this.value>0&&s.push("red--text"),s}get ledChannelName(){return this.colorOrder==="R"?"RED":this.colorOrder==="G"?"GREEN":this.colorOrder==="B"?"BLUE":"WHITE"}submitInput(){if(this.errors.length>0)return;let s=this.inputValue/100;this.value===0&&s<this.off_below?s=this.off_below:this.value>=this.off_below&&s<this.off_below&&(s=0),this.sendCmd(s)}};wt([w({type:Number,required:!0})],mt.prototype,"target",2);wt([w({type:Number,default:1})],mt.prototype,"max",2);wt([w({type:String,default:""})],mt.prototype,"name",2);wt([w({type:String,default:""})],mt.prototype,"type",2);wt([w({type:Boolean,default:!1})],mt.prototype,"controllable",2);wt([w({type:Boolean,default:!1})],mt.prototype,"pwm",2);wt([w({type:[Number,Boolean],default:!1})],mt.prototype,"rpm",2);wt([w({type:Number,default:1})],mt.prototype,"multi",2);wt([w({type:Number,default:0})],mt.prototype,"off_below",2);wt([w({type:String,default:""})],mt.prototype,"colorOrder",2);wt([he("lockSliders",{immediate:!0})],mt.prototype,"lockSlidersChanged",1);wt([Ke(500)],mt.prototype,"changeSliderValue",1);wt([he("value")],mt.prototype,"valueChanged",1);wt([he("sliderValue",{immediate:!0})],mt.prototype,"sliderValueChanged",1);mt=wt([S],mt);var I8=function(){var r,i;var e=this,t=e._self._c;return e._self._setupProxy,t(Ee,{staticClass:"px-0 py-2"},[t(x,[t(b,{class:e.pwm?"pb-1":"pb-3"},[t(cs,{staticClass:"_fan-slider-subheader"},[e.type==="led"&&e.target>0?t(_,{staticClass:"mr-2",attrs:{small:"","retain-focus-on-click":!0},on:{click:e.ledOff}},[e._v(" "+e._s(e.mdiLightbulbOnOutline)+" ")]):e.type==="led"?t(_,{staticClass:"mr-2",attrs:{small:"","retain-focus-on-click":!0},on:{click:e.ledOn}},[e._v(" "+e._s(e.mdiLightbulbOutline)+" ")]):e.type.includes("fan")?t(_,{class:e.fanClasses,attrs:{small:""}},[e._v(e._s(e.mdiFan))]):e._e(),t("span",[e._v(e._s(e.convertName(e.name)))]),t(ae),e.rpm!==null?t("small",{class:e.rpmClasses},[e._v(e._s(Math.round((r=e.rpm)!=null?r:0))+" RPM")]):e._e(),e.controllable?e._e():t("span",{staticClass:"font-weight-bold"},[e._v(" "+e._s(Math.round(parseFloat(e.value)*100))+" % ")]),e.controllable&&!e.pwm?t(_,{on:{click:e.switchOutputPin}},[e._v(" "+e._s(e.value?e.mdiToggleSwitch:e.mdiToggleSwitchOffOutline)+" ")]):e._e(),t("form",{on:{submit:function(n){return n.preventDefault(),e.submitInput.apply(null,arguments)}}},[e.controllable&&e.pwm?t(se,{staticClass:"_slider-input pt-1",attrs:{error:e.errors.length>0,suffix:"%",type:"number","hide-spin-buttons":"","hide-details":"",outlined:"",dense:""},on:{blur:function(n){e.inputValue=Math.round(parseFloat(e.sliderValue)*100)},focus:function(n){return n.target.select()},keydown:e.checkInvalidChars},model:{value:e.inputValue,callback:function(n){e.inputValue=n},expression:"inputValue"}}):e._e()],1)],1),e.controllable&&e.pwm?t("transition",{attrs:{name:"fade"}},[t("div",{directives:[{name:"show",rawName:"v-show",value:e.errors.length>0,expression:"errors.length > 0"}],staticClass:"_error-msg d-flex justify-end"},[e._v(" "+e._s((i=e.errors[0])!=null?i:"")+" ")])]):e._e(),e.controllable&&e.pwm?t(Z,{staticClass:"py-0 pb-2 d-flex align-center"},[e.lockSliders&&e.isTouchDevice&&e.pwm?t(g,{staticClass:"_lock-button",attrs:{plain:"",small:"",icon:""},on:{click:function(n){e.isLocked=!e.isLocked}}},[t(_,{attrs:{small:"",color:e.isLocked?"red":""}},[e._v(" "+e._s(e.isLocked?e.mdiLockOutline:e.mdiLockOpenVariantOutline)+" ")])],1):e._e(),t(Lr,{directives:[{name:"touch",rawName:"v-touch",value:{start:e.resetLockTimer},expression:"{ start: resetLockTimer }"}],attrs:{disabled:e.isLocked,min:0,max:1,step:.01,color:e.sliderValue<e.off_below&&e.sliderValue>0?"red":void 0,"hide-details":""},on:{change:e.changeSliderValue},scopedSlots:e._u([{key:"prepend",fn:function(){return[t(_,{attrs:{disabled:e.isLocked||e.sliderValue<=e.min},on:{click:e.decrement}},[e._v(" "+e._s(e.mdiMinus)+" ")])]},proxy:!0},{key:"append",fn:function(){return[t(_,{attrs:{disabled:e.isLocked||e.sliderValue>=1},on:{click:e.increment}},[e._v(e._s(e.mdiPlus))])]},proxy:!0}],null,!1,3774030646),model:{value:e.sliderValue,callback:function(n){e.sliderValue=n},expression:"sliderValue"}})],1):e._e()],1)],1)],1)},N8=[],V8=E(mt,I8,N8,!1,null,"31338421");const gh=V8.exports;var B8=Object.getOwnPropertyDescriptor,U8=(s,e,t,r)=>{for(var i=r>1?void 0:r?B8(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let _h=class extends k(L){constructor(){super(...arguments),this.mdiDipSwitch=Hp}get filamentSensors(){var e;return(e=this.$store.getters["printer/getFilamentSensors"])!=null?e:[]}get miscellaneous(){var e;return(e=this.$store.getters["printer/getMiscellaneous"])!=null?e:[]}get lights(){var e;return(e=this.$store.getters["printer/getLights"])!=null?e:[]}get miscellaneousSensors(){var e;return(e=this.$store.getters["printer/getMiscellaneousSensors"])!=null?e:[]}get moonrakerSensors(){var e;return(e=this.$store.getters["server/sensor/getSensors"])!=null?e:[]}get showMiscellaneousPanel(){return this.klipperReadyForGui&&(this.miscellaneous.length||this.filamentSensors.length||this.lights.length)}};_h=U8([S({components:{Panel:U,FilamentSensor:x0,MiscellaneousSlider:gh,MiscellaneousLight:V0,MiscellaneousSensor:$0,MoonrakerSensor:C0}})],_h);var W8=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.showMiscellaneousPanel?t(U,{attrs:{icon:e.mdiDipSwitch,title:e.$t("Panels.MiscellaneousPanel.Headline"),collapsible:!0,"card-class":"miscellaneous-panel"}},[e._l(e.miscellaneous,function(r,i){return t("div",{key:i},[i?t(I):e._e(),t(gh,{attrs:{name:r.name,type:r.type,target:r.power,rpm:r.rpm,controllable:r.controllable,pwm:r.pwm,off_below:r.off_below,max:r.max_power,multi:parseInt(r.scale)}})],1)}),e._l(e.lights,function(r,i){return t("div",{key:"light_"+r.name},[i||e.miscellaneous.length?t(I):e._e(),r.type==="led"&&r.colorOrder.length===1?t(gh,{attrs:{name:r.name,type:"led",rpm:null,controllable:!0,pwm:!0,target:r.singleChannelTarget,"color-order":r.colorOrder}}):t(V0,{attrs:{object:r,root:!0}})],1)}),e._l(e.filamentSensors,function(r,i){return t("div",{key:"sensor_"+i},[i||e.miscellaneous.length||e.lights.length?t(I):e._e(),t(x0,{attrs:{type:r.type,name:r.name,enabled:r.enabled,filament_detected:r.filament_detected,filament_diameter:r.filament_diameter}})],1)}),e._l(e.miscellaneousSensors,function(r,i){return t("div",{key:"miscellaneous_sensor_"+i},[i||e.miscellaneous.length||e.lights.length||e.filamentSensors.length?t(I):e._e(),t($0,{attrs:{name:r.name,value:r.value,unit:r.unit}})],1)}),e._l(e.moonrakerSensors,function(r,i){return t("div",{key:"moonraker_sensor_"+i},[i||e.miscellaneous.length||e.lights.length||e.filamentSensors.length||e.miscellaneousSensors.length?t(I):e._e(),t(C0,{attrs:{name:r}})],1)})],2):e._e()},z8=[],G8=E(_h,W8,z8,!1,null,"16616b01");const Z8=G8.exports;var q8=Object.defineProperty,X8=Object.getOwnPropertyDescriptor,B0=(s,e,t,r)=>{for(var i=r>1?void 0:r?X8(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&q8(e,t,i),i};let mc=class extends k(L){constructor(){super(...arguments),this.showChangeSpoolDialog=!1}get name(){var s;return((s=this.objectName.split(" ")[1])!=null?s:"Unknown").toUpperCase()}get color(){var s,e,t;return(t=(e=(s=this.spool)==null?void 0:s.filament)==null?void 0:e.color_hex)!=null?t:"000000"}get dotStyle(){return{"background-color":"#"+this.color}}get spoolId(){var e,t;return(t=((e=this.$store.state.printer[this.objectName])!=null?e:{}).spool_id)!=null?t:null}get spool(){var s;return(s=this.spools.find(e=>e.id===this.spoolId))!=null?s:null}get spools(){var s;return(s=this.$store.state.server.spoolman.spools)!=null?s:[]}};B0([w({required:!1,default:!1})],mc.prototype,"objectName",2);mc=B0([S({components:{}})],mc);var Y8=function(){var r,i,n;var e=this,t=e._self._c;return e._self._setupProxy,t(J,[t(g,{attrs:{small:""},on:{click:function(a){e.showChangeSpoolDialog=!0}}},[e.color!=null?t("span",{staticClass:"_extruderColorState mr-2",style:e.dotStyle}):e._e(),e._v(" "+e._s(e.name)+" "),e.spoolId===null?t("span",{staticClass:"font-italic ml-1"},[e._v("("+e._s(e.$t("Panels.SpoolmanPanel.NoSpool"))+")")]):t("span",{staticClass:"ml-1"},[e._v("("+e._s((n=(i=(r=e.spool)==null?void 0:r.filament)==null?void 0:i.name)!=null?n:"--")+")")])]),t(cn,{attrs:{"show-dialog":e.showChangeSpoolDialog,tool:e.name},on:{close:function(a){e.showChangeSpoolDialog=!1}}})],1)},J8=[],K8=E(mc,Y8,J8,!1,null,"262bd3e3");const U0=K8.exports;var Q8=Object.defineProperty,eA=Object.getOwnPropertyDescriptor,W0=(s,e,t,r)=>{for(var i=r>1?void 0:r?eA(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&Q8(e,t,i),i};let hc=class extends k(L){constructor(){super(...arguments),this.mdiSwapVertical=xv,this.showChangeSpoolDialog=!1}};W0([w({required:!1,default:!1})],hc.prototype,"tools",2);hc=W0([S({components:{SpoolmanToolsDropdownItem:U0}})],hc);var tA=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(ye,{attrs:{"offset-y":!0,"close-on-content-click":!1,left:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{icon:"",tile:""}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiSwapVertical))])],1)]}}])},[t(Me,{attrs:{dense:""}},[t(J,[t(g,{attrs:{small:""},on:{click:function(r){e.showChangeSpoolDialog=!0}}},[t(_,{attrs:{left:""}},[e._v(e._s(e.mdiSwapVertical))]),e._v(" "+e._s(e.$t("Panels.SpoolmanPanel.ActiveSpool"))+" ")],1)],1),e._l(e.tools,function(r){return t(U0,{key:r,attrs:{"object-name":r}})})],2),t(cn,{attrs:{"show-dialog":e.showChangeSpoolDialog},on:{close:function(r){e.showChangeSpoolDialog=!1}}})],1)},sA=[],rA=E(hc,tA,sA,!1,null,null);const iA=rA.exports;var nA=Object.getOwnPropertyDescriptor,aA=(s,e,t,r)=>{for(var i=r>1?void 0:r?nA(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let vh=class extends k(L){constructor(){super(...arguments),this.mdiAdjust=tn,this.mdiDotsVertical=mu,this.mdiEject=Q_,this.mdiOpenInNew=gv,this.mdiSwapVertical=xv,this.showChangeSpoolDialog=!1,this.showEjectSpoolDialog=!1}get health(){var e;return(e=this.$store.state.server.spoolman.health)!=null?e:""}get title(){const e=this.$t("Panels.SpoolmanPanel.Headline");return this.health===""||this.health==="healthy"?e:"".concat(e," (").concat(this.health,")")}get changeSpoolTooltip(){return this.active_spool===null?this.$t("Panels.SpoolmanPanel.SelectSpool"):this.$t("Panels.SpoolmanPanel.ChangeSpool")}get active_spool(){var e;return(e=this.$store.state.server.spoolman.active_spool)!=null?e:null}get spoolManagerUrl(){var e,t,r;return(r=(t=(e=this.$store.state.server.config.config)==null?void 0:e.spoolman)==null?void 0:t.server)!=null?r:null}get toolsWithSpoolId(){return Object.keys(this.$store.state.printer).filter(e=>/^gcode_macro T\d+$/i.test(e.toLowerCase())).filter(e=>{var r;const t=(r=this.$store.state.printer[e])!=null?r:{};return Object.keys(t).some(i=>i.toLowerCase()==="spool_id")})}openSpoolManager(){window.open(this.spoolManagerUrl,"_blank")}};vh=aA([S({components:{SpoolmanPanelActiveSpool:Mu,Panel:U,SpoolmanChangeSpoolDialog:cn,SpoolmanEjectSpoolDialog:$f}})],vh);var oA=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(U,{attrs:{icon:e.mdiAdjust,title:e.title,"card-class":"spoolman-panel",collapsible:!0},scopedSlots:e._u([{key:"buttons",fn:function(){return[e.toolsWithSpoolId.length>0?t(iA,{attrs:{tools:e.toolsWithSpoolId}}):t(g,{attrs:{icon:"",tile:"",title:e.changeSpoolTooltip},on:{click:function(r){e.showChangeSpoolDialog=!0}}},[t(_,[e._v(e._s(e.mdiSwapVertical))])],1),t(ye,{attrs:{"offset-y":!0,"close-on-content-click":!1,left:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{icon:"",tile:""}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiDotsVertical))])],1)]}}])},[t(Me,{attrs:{dense:""}},[t(J,[t(g,{staticStyle:{width:"100%"},attrs:{small:""},on:{click:function(r){e.showEjectSpoolDialog=!0}}},[t(_,{attrs:{left:""}},[e._v(e._s(e.mdiEject))]),e._v(" "+e._s(e.$t("Panels.SpoolmanPanel.EjectSpool"))+" ")],1)],1),t(J,[t(g,{staticStyle:{width:"100%"},attrs:{small:""},on:{click:e.openSpoolManager}},[t(_,{attrs:{left:""}},[e._v(e._s(e.mdiOpenInNew))]),e._v(" "+e._s(e.$t("Panels.SpoolmanPanel.OpenSpoolManager"))+" ")],1)],1)],1)],1)]},proxy:!0}])},[e.active_spool===null?t(Z,[t(x,[t(b,{staticClass:"text-center"},[t("p",{staticClass:"text--disabled"},[e._v(e._s(e.$t("Panels.SpoolmanPanel.NoActiveSpool")))]),t(g,{attrs:{small:"",color:"primary"},on:{click:function(r){e.showChangeSpoolDialog=!0}}},[e._v(" "+e._s(e.$t("Panels.SpoolmanPanel.SelectSpool"))+" ")])],1)],1)],1):t(Mu,{on:{"change-spool":function(r){e.showChangeSpoolDialog=!0}}})],1),t(cn,{attrs:{"show-dialog":e.showChangeSpoolDialog},on:{close:function(r){e.showChangeSpoolDialog=!1}}}),t($f,{attrs:{"show-dialog":e.showEjectSpoolDialog},on:{close:function(r){e.showEjectSpoolDialog=!1}}})],1)},lA=[],cA=E(vh,oA,lA,!1,null,"a5e75b8b");const uA=cA.exports;var dA=Object.getOwnPropertyDescriptor,mA=(s,e,t,r)=>{for(var i=r>1?void 0:r?dA(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let bh=class extends k(L,Hl){constructor(){super(...arguments),this.mdiBroom=G_,this.mdiContentSave=Rp,this.mdiArrowCollapseDown=cu,this.mdiInformation=Ht,this.mdiArrowExpandUp=z_,this.mdiLayersOutline=Qw,this.saveOffsetDialog=!1}get offsetsZ(){return this.$store.state.gui.control.offsetsZ}get homed_axis(){var s,e;return(e=(s=this.$store.state.printer.toolhead)==null?void 0:s.homed_axes)!=null?e:""}get offsetZSaveOption(){var s;return(s=this.$store.state.gui.control.offsetZSaveOption)!=null?s:null}sendBabyStepDown(s){const e="SET_GCODE_OFFSET Z_ADJUST=-".concat(s," ").concat(this.homed_axis==="xyz"?"MOVE=1":"");this.$store.dispatch("server/addEvent",{message:e,type:"command"}),this.$socket.emit("printer.gcode.script",{script:e},{loading:"babyStepDown"})}sendBabyStepUp(s){const e="SET_GCODE_OFFSET Z_ADJUST=+".concat(s," ").concat(this.homed_axis==="xyz"?"MOVE=1":"");this.$store.dispatch("server/addEvent",{message:e,type:"command"}),this.$socket.emit("printer.gcode.script",{script:e},{loading:"babyStepUp"})}clearZOffset(){const s="SET_GCODE_OFFSET Z=0"+(this.homed_axis==="xyz"?" MOVE=1":"");this.$store.dispatch("server/addEvent",{message:s,type:"command"}),this.$socket.emit("printer.gcode.script",{script:s},{loading:"babySteppingClear"})}saveZOffset(){let s=this.offsetZSaveOption;s===null&&(s=this.autoSaveZOffsetOption),this.$store.dispatch("server/addEvent",{message:s,type:"command"}),this.$socket.emit("printer.gcode.script",{script:s}),this.saveOffsetDialog=!0}saveConfig(){const s="SAVE_CONFIG";this.$store.dispatch("server/addEvent",{message:s,type:"command"}),this.$socket.emit("printer.gcode.script",{script:s},{loading:"topbarSaveConfig"}),this.saveOffsetDialog=!1}};bh=mA([S({components:{Panel:U,Responsive:tt}})],bh);var hA=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(tt,{attrs:{breakpoints:{xsmall:r=>r.width<=285,medium:r=>r.width<=510}},scopedSlots:e._u([{key:"default",fn:function({el:r}){return[t(Ee,{staticClass:"pa-0"},[t(x,[t(b,{staticClass:"v-subheader text--secondary pr-0"},[t(_,{staticClass:"mr-2",attrs:{small:""}},[e._v(" "+e._s(e.mdiLayersOutline)+" ")]),t("span",[e._v(e._s(e.$t("Panels.ZoffsetPanel.Headline"))+": "+e._s(e.zOffset))])],1),t(b,{staticClass:"v-subheader justify-end pl-0"},[t("div",{staticClass:"d-flex align-center"},[e.z_gcode_offset!==0?t(g,{staticClass:"px-2 mr-1",attrs:{loading:e.loadings.includes("babySteppingClear"),text:"",small:"",plain:""},on:{click:function(i){return e.clearZOffset()}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiBroom))]),r.is.xsmall?e._e():t("span",{staticClass:"ml-1"},[e._v(e._s(e.$t("Panels.ZoffsetPanel.Clear")))])],1):e._e(),e.showSaveButton?t(g,{staticClass:"px-2",attrs:{color:"primary",text:"",small:"",plain:""},on:{click:e.saveZOffset}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiContentSave))]),r.is.xsmall?e._e():t("span",{staticClass:"ml-1"},[e._v(e._s(e.$t("Panels.ZoffsetPanel.Save")))])],1):e._e()],1)])],1),t(x,{attrs:{dense:""}},[t(b,{class:r.is.medium?"col-12":"order-1 col-6"},[t("div",{staticClass:"d-flex align-center"},[t(Wt,{staticClass:"_btn-group"},e._l(e.offsetsZ,function(i,n){return t(g,{key:"offsetsUp-".concat(n),staticClass:"_btn-qs flex-grow-1 px-1",attrs:{small:""},on:{click:function(a){return e.sendBabyStepUp(i)}}},[n===0&&!r.is.xsmall?t(_,{staticClass:"mr-1 ml-n1",attrs:{left:"",small:""}},[e._v(" "+e._s(e.mdiArrowExpandUp)+" ")]):e._e(),t("span",[e._v("+"+e._s(i))])],1)}),1)],1)]),t(b,{class:r.is.medium?"col-12":"order-0 col-6"},[r.is.medium?t(Wt,{staticClass:"_btn-group"},e._l(e.offsetsZ,function(i,n){return t(g,{key:"offsetsDown-".concat(n),staticClass:"_btn-qs flex-grow-1 px-1",attrs:{small:""},on:{click:function(a){return e.sendBabyStepDown(i)}}},[n===0&&!r.is.xsmall?t(_,{staticClass:"mr-1 ml-n1",attrs:{left:"",small:""}},[e._v(" "+e._s(e.mdiArrowCollapseDown)+" ")]):e._e(),t("span",[e._v("−"+e._s(i))])],1)}),1):t(Wt,{staticClass:"_btn-group"},e._l(e.offsetsZ.slice().reverse(),function(i,n){return t(g,{key:"offsetsDown-".concat(n),staticClass:"_btn-qs flex-grow-1 px-1",attrs:{small:""},on:{click:function(a){return e.sendBabyStepDown(i)}}},[t("span",[e._v("−"+e._s(i))]),n===e.offsetsZ.length-1&&!r.is.xsmall?t(_,{staticClass:"mr-n1 ml-1",attrs:{left:"",small:""}},[e._v(" "+e._s(e.mdiArrowCollapseDown)+" ")]):e._e()],1)}),1)],1)],1),t(le,{attrs:{"max-width":"290"},model:{value:e.saveOffsetDialog,callback:function(i){e.saveOffsetDialog=i},expression:"saveOffsetDialog"}},[t(U,{attrs:{title:e.$t("Panels.ZoffsetPanel.SaveInfoHeadline"),icon:e.mdiInformation,"card-class":"zoffset-saveinfo-dialog","margin-bottom":!1}},[e.printerIsPrinting?t(Z,{staticClass:"mt-3"},[e._v(" "+e._s(e.$t("Panels.ZoffsetPanel.SaveInfoDescriptionPrint"))+" ")]):t(Z,{staticClass:"mt-3"},[e._v(" "+e._s(e.$t("Panels.ZoffsetPanel.SaveInfoDescription"))+" ")]),e.printerIsPrinting?t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:function(i){e.saveOffsetDialog=!1}}},[e._v(e._s(e.$t("Panels.ZoffsetPanel.Ok")))])],1):t(oe,[t(ae),t(g,{attrs:{color:"primary",text:""},on:{click:e.saveConfig}},[e._v(" "+e._s(e.$t("Panels.ZoffsetPanel.SaveConfig"))+" ")]),t(g,{attrs:{text:""},on:{click:function(i){e.saveOffsetDialog=!1}}},[e._v(e._s(e.$t("Panels.ZoffsetPanel.Later")))])],1)],1)],1)],1)]}}])})},pA=[],fA=E(bh,hA,pA,!1,null,"9ea80ab7");const z0=fA.exports;var gA=Object.defineProperty,_A=Object.getOwnPropertyDescriptor,vr=(s,e,t,r)=>{for(var i=r>1?void 0:r?_A(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&gA(e,t,i),i};let Ps=class extends k(L){onBlur(){this.position!==this.currentPos&&(this.position=this.currentPos)}submit(){this.$emit("submit")}};vr([Ix({type:String})],Ps.prototype,"position",2);vr([w({type:String,required:!0})],Ps.prototype,"currentPos",2);vr([w({type:String,required:!1})],Ps.prototype,"label",2);vr([w({type:String,required:!1})],Ps.prototype,"suffix",2);vr([w({type:Number,required:!1,default:1})],Ps.prototype,"step",2);vr([w({type:Boolean,required:!1})],Ps.prototype,"disabled",2);vr([w({type:Boolean,required:!1})],Ps.prototype,"readonly",2);Ps=vr([S({components:{}})],Ps);var vA=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("form",{on:{submit:function(r){return r.preventDefault(),e.submit.apply(null,arguments)}}},[t(se,{attrs:{label:"[ ".concat(e.label," ]"),suffix:e.suffix,disabled:e.disabled,step:e.step,readonly:e.readonly,"hide-details":"auto",type:"number","hide-spin-buttons":"",outlined:"",reverse:"",dense:""},on:{blur:e.onBlur,focus:function(r){e.readonly||r.target.select()}},model:{value:e.position,callback:function(r){e.position=r},expression:"position"}})],1)},bA=[],yA=E(Ps,vA,bA,!1,null,null);const zo=yA.exports;var CA=Object.defineProperty,$A=Object.getOwnPropertyDescriptor,Wu=(s,e,t,r)=>{for(var i=r>1?void 0:r?$A(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&CA(e,t,i),i};let ji=class extends k(L,Je){constructor(){super(...arguments),this.mdiCrosshairsGps=Aw,this.mdiGrid=hu,this.input={x:{pos:"",valid:!0},y:{pos:"",valid:!0},z:{pos:"",valid:!0}}}updatePositionX(s){this.input.x.pos=s}updatePositionY(s){this.input.y.pos=s}updatePositionZ(s){this.input.z.pos=s}get displayPositionAbsolute(){return this.positionAbsolute?this.$t("Panels.ToolheadControlPanel.Absolute"):this.$t("Panels.ToolheadControlPanel.Relative")}get positionAbsolute(){var s,e;return(e=(s=this.$store.state.printer.gcode_move)==null?void 0:s.absolute_coordinates)!=null?e:!0}get livePositions(){var e,t,r,i,n,a,o,l;const s=(t=(e=this.$store.state.printer.motion_report)==null?void 0:e.live_position)!=null?t:[0,0,0];return{x:(i=(r=s[0])==null?void 0:r.toFixed(2))!=null?i:"--",y:(a=(n=s[1])==null?void 0:n.toFixed(2))!=null?a:"--",z:(l=(o=s[2])==null?void 0:o.toFixed(3))!=null?l:"--"}}get gcodePositions(){var e,t,r,i,n,a,o,l;const s=(t=(e=this.$store.state.printer.gcode_move)==null?void 0:e.gcode_position)!=null?t:[0,0,0];return{x:(i=(r=s[0])==null?void 0:r.toFixed(2))!=null?i:"--",y:(a=(n=s[1])==null?void 0:n.toFixed(2))!=null?a:"--",z:(l=(o=s[2])==null?void 0:o.toFixed(3))!=null?l:"--"}}get bed_mesh(){var s;return(s=this.$store.state.printer.bed_mesh)!=null?s:null}get currentProfileName(){var s,e;return(e=(s=this.bed_mesh)==null?void 0:s.profile_name)!=null?e:""}get showPosition(){var s;return(s=this.$store.state.gui.view.toolhead.showPosition)!=null?s:!0}get showCoordinates(){var s;return(s=this.$store.state.gui.view.toolhead.showCoordinates)!=null?s:!0}get showControl(){var s;return(s=this.$store.state.gui.view.toolhead.showControl)!=null?s:!0}get containerClass(){return this.showControl?"pb-0":""}sendCmd(){let s=[];if(this.existsClientLinearMoveMacro||(s.push("SAVE_GCODE_STATE NAME=_ui_movement"),s.push("G90")),this.input.z.pos!==this.gcodePositions.z&&(this.existsClientLinearMoveMacro?s.push("_CLIENT_LINEAR_MOVE Z=".concat(this.input.z.pos," F=").concat(this.feedrateZ*60," ABSOLUTE=1")):s.push("G1 Z".concat(this.input.z.pos," F").concat(this.feedrateZ*60))),this.input.x.pos!==this.gcodePositions.x||this.input.y.pos!==this.gcodePositions.y){let t="",r="";this.existsClientLinearMoveMacro?(this.input.x.pos!==this.gcodePositions.x&&(t=" X=".concat(this.input.x.pos)),this.input.y.pos!==this.gcodePositions.y&&(r=" Y=".concat(this.input.y.pos)),s.push("_CLIENT_LINEAR_MOVE".concat(t).concat(r," F=").concat(this.feedrateXY*60," ABSOLUTE=1"))):(this.input.x.pos!==this.gcodePositions.x&&(t=" X".concat(this.input.x.pos)),this.input.y.pos!==this.gcodePositions.y&&(r=" Y".concat(this.input.y.pos)),s.push("G1".concat(t).concat(r," F").concat(this.feedrateXY*60)))}this.existsClientLinearMoveMacro||s.push("RESTORE_GCODE_STATE NAME=_ui_movement");const e=s.join("\n");this.input.x.valid&&this.input.y.valid&&this.input.z.valid&&(this.$store.dispatch("server/addEvent",{message:e,type:"command"}),this.$socket.emit("printer.gcode.script",{script:e}))}};Wu([he("gcodePositions.x",{immediate:!0})],ji.prototype,"updatePositionX",1);Wu([he("gcodePositions.y",{immediate:!0})],ji.prototype,"updatePositionY",1);Wu([he("gcodePositions.z",{immediate:!0})],ji.prototype,"updatePositionZ",1);ji=Wu([S({components:{MoveToInput:zo,Responsive:tt}})],ji);var xA=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.showCoordinates||e.showPosition?t(Ee,{class:e.containerClass},[t(tt,{attrs:{breakpoints:{xsmall:r=>r.width<=320,small:r=>r.width>320&&r.width<=460,medium:r=>r.width>460&&r.width<=560,large:r=>r.width>560}},scopedSlots:e._u([{key:"default",fn:function({el:r}){return[e.showPosition?t(x,{staticClass:"flex-nowrap pb-1"},[t(b,{staticClass:"v-subheader text--secondary mr-2",class:{"col-5":r.is.small,"col-4":r.is.xsmall||r.is.medium,"col-3":r.is.large}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiCrosshairsGps))]),r.is.xsmall?e._e():t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.$t("Panels.ToolheadControlPanel.Position"))+": ")]),t("span",{staticClass:"text-no-wrap"},[e._v(e._s(e.displayPositionAbsolute))])],1),e.currentProfileName?t(b,{staticClass:"v-subheader text--secondary pl-2 justify-end text-no-wrap text-truncate"},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiGrid))]),t("span",{staticClass:"text-no-wrap text-truncate"},[e._v(e._s(e.currentProfileName))])],1):e._e()],1):e._e(),e.showCoordinates?t(x,{attrs:{dense:""}},[t(b,{class:r.is.xsmall?"col-12":"col-4"},[t(zo,{attrs:{label:e.livePositions.x,suffix:"X",step:.01,"current-pos":e.gcodePositions.x,readonly:["printing"].includes(e.printer_state),disabled:!e.xAxisHomed},on:{submit:e.sendCmd},model:{value:e.input.x.pos,callback:function(i){e.$set(e.input.x,"pos",i)},expression:"input.x.pos"}})],1),t(b,{class:r.is.xsmall?"col-12":"col-4"},[t(zo,{attrs:{label:e.livePositions.y,suffix:"Y",step:.01,"current-pos":e.gcodePositions.y,readonly:["printing"].includes(e.printer_state),disabled:!e.yAxisHomed},on:{submit:e.sendCmd},model:{value:e.input.y.pos,callback:function(i){e.$set(e.input.y,"pos",i)},expression:"input.y.pos"}})],1),t(b,{class:r.is.xsmall?"col-12":"col-4"},[t(zo,{attrs:{label:e.livePositions.z,suffix:"Z",step:.001,"current-pos":e.gcodePositions.z,readonly:["printing"].includes(e.printer_state),disabled:!e.zAxisHomed},on:{submit:e.sendCmd},model:{value:e.input.z.pos,callback:function(i){e.$set(e.input.z,"pos",i)},expression:"input.z.pos"}})],1)],1):e._e()]}}],null,!1,3225060219)})],1):e._e()},wA=[],SA=E(ji,xA,wA,!1,null,null);const G0=SA.exports;var PA=Object.getOwnPropertyDescriptor,DA=(s,e,t,r)=>{for(var i=r>1?void 0:r?PA(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let yh=class extends k(L){constructor(){super(...arguments),this.mdiCog=ss}get showPosition(){var s;return(s=this.$store.state.gui.view.toolhead.showPosition)!=null?s:!0}set showPosition(s){this.$store.dispatch("gui/saveSetting",{name:"view.toolhead.showPosition",value:s})}get showCoordinates(){var s;return(s=this.$store.state.gui.view.toolhead.showCoordinates)!=null?s:!0}set showCoordinates(s){this.$store.dispatch("gui/saveSetting",{name:"view.toolhead.showCoordinates",value:s})}get showControl(){var s;return(s=this.$store.state.gui.view.toolhead.showControl)!=null?s:!0}set showControl(s){this.$store.dispatch("gui/saveSetting",{name:"view.toolhead.showControl",value:s})}get showZOffset(){var s;return(s=this.$store.state.gui.view.toolhead.showZOffset)!=null?s:!0}set showZOffset(s){this.$store.dispatch("gui/saveSetting",{name:"view.toolhead.showZOffset",value:s})}get showSpeedFactor(){var s;return(s=this.$store.state.gui.view.toolhead.showSpeedFactor)!=null?s:!0}set showSpeedFactor(s){this.$store.dispatch("gui/saveSetting",{name:"view.toolhead.showSpeedFactor",value:s})}};yh=DA([S],yh);var TA=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(ye,{attrs:{"offset-y":!0,left:!0,"close-on-content-click":!1},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{icon:"",tile:""}},"v-btn",i,!1),r),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiCog))])],1)]}}])},[t(Me,[t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.ToolheadControlPanel.PositionOutput")},model:{value:e.showPosition,callback:function(r){e.showPosition=r},expression:"showPosition"}})],1),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.ToolheadControlPanel.CoordinateFields")},model:{value:e.showCoordinates,callback:function(r){e.showCoordinates=r},expression:"showCoordinates"}})],1),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.ToolheadControlPanel.ControlButtons")},model:{value:e.showControl,callback:function(r){e.showControl=r},expression:"showControl"}})],1),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.ToolheadControlPanel.ZOffset")},model:{value:e.showZOffset,callback:function(r){e.showZOffset=r},expression:"showZOffset"}})],1),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.ToolheadControlPanel.SpeedFactor")},model:{value:e.showSpeedFactor,callback:function(r){e.showSpeedFactor=r},expression:"showSpeedFactor"}})],1)],1)],1)},OA=[],MA=E(yh,TA,OA,!1,null,null);const kA=MA.exports;var EA=Object.getOwnPropertyDescriptor,LA=(s,e,t,r)=>{for(var i=r>1?void 0:r?EA(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Ch=class extends k(L,Je){constructor(){super(...arguments),this.mdiEngineOff=jp,this.mdiHome=av}get enableXYHoming(){return this.$store.state.gui.control.enableXYHoming}get stepsXYsorted(){return[...this.$store.state.gui.control.stepsXY].sort(function(e,t){return t-e})}get stepsXYsortedReverse(){return[...this.$store.state.gui.control.stepsXY].sort(function(e,t){return e-t})}get stepsZsorted(){return[...this.$store.state.gui.control.stepsZ].sort(function(e,t){return t-e})}get stepsZsortedReverse(){return[...this.$store.state.gui.control.stepsZ].sort(function(e,t){return e-t})}};Ch=LA([S],Ch);var AA=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(x,{attrs:{"no-gutters":""}},[t(b,{staticClass:"col-12 pb-0 text-center"},[t(g,{attrs:{small:"",disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("homeAll"),color:e.homedAxes.includes("xyz")?"primary":"warning"},on:{click:e.doHome}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiHome))]),e._v(" "+e._s(e.$t("Panels.ToolheadControlPanel.ALL"))+" ")],1),e.enableXYHoming?t(g,{staticClass:"ml-2",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("homeAll"),color:e.homedAxes.includes("xy")?"primary":"warning",small:""},on:{click:e.doHomeXY}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiHome))]),e._v(" XY ")],1):e._e(),e.existsQGL?t(g,{staticClass:"ml-2",attrs:{disabled:["printing"].includes(e.printer_state),small:"",loading:e.loadings.includes("qgl"),color:e.colorQuadGantryLevel},on:{click:e.doQGL}},[e._v(" "+e._s(e.$t("Panels.ToolheadControlPanel.QGL"))+" ")]):e._e(),e.existsZtilt?t(g,{staticClass:"ml-2",attrs:{disabled:["printing"].includes(e.printer_state),small:"",loading:e.loadings.includes("zTilt"),color:e.colorZTilt},on:{click:e.doZtilt}},[e._v(" "+e._s(e.$t("Panels.ToolheadControlPanel.ZTilt"))+" ")]):e._e(),t(g,{staticClass:"ml-2",attrs:{small:"",disabled:["printing"].includes(e.printer_state),color:e.homedAxes!==""?"primary":"warning"},on:{click:function(r){return e.doSend("M84")}}},[t(_,[e._v(e._s(e.mdiEngineOff))])],1)],1)],1),t(x,{attrs:{dense:""}},[t(b,{staticClass:"text-center"},[t(Wt,{staticClass:"_btn-group row no-gutters"},[e._l(e.stepsXYsorted,function(r){return t(g,{key:"x-"+r,staticClass:"btnMinWidthAuto col btnGroup",attrs:{disabled:["printing"].includes(e.printer_state)},on:{click:function(i){return e.doSendMove("X-"+r,e.feedrateXY)}}},[t("span",{staticClass:"body-2"},[e._v("–"+e._s(r))])])}),t(g,{staticClass:"font-weight-bold btnHomeAxis btnGroup",attrs:{disabled:["printing"].includes(e.printer_state),color:e.homedAxes.includes("x")?"primary":"warning",loading:e.loadings.includes("homeX")},on:{click:e.doHomeX}},[e._v(" X ")]),e._l(e.stepsXYsortedReverse,function(r){return t(g,{key:"x+"+r,staticClass:"btnMinWidthAuto col btnGroup",attrs:{disabled:["printing"].includes(e.printer_state)},on:{click:function(i){return e.doSendMove("X+"+r,e.feedrateXY)}}},[t("span",{staticClass:"body-2"},[e._v("+"+e._s(r))])])})],2)],1)],1),t(x,{attrs:{dense:""}},[t(b,{staticClass:"text-center"},[t(Wt,{staticClass:"_btn-group row no-gutters"},[e._l(e.stepsXYsorted,function(r){return t(g,{key:"y-"+r,staticClass:"btnMinWidthAuto col btnGroup",attrs:{disabled:["printing"].includes(e.printer_state)},on:{click:function(i){return e.doSendMove("Y-"+r,e.feedrateXY)}}},[t("span",{staticClass:"body-2"},[e._v("–"+e._s(r))])])}),t(g,{staticClass:"font-weight-bold btnHomeAxis btnGroup",attrs:{disabled:["printing"].includes(e.printer_state),color:e.homedAxes.includes("y")?"primary":"warning",loading:e.loadings.includes("homeY")},on:{click:e.doHomeY}},[e._v(" Y ")]),e._l(e.stepsXYsortedReverse,function(r){return t(g,{key:"y+"+r,staticClass:"btnMinWidthAuto col btnGroup",attrs:{disabled:["printing"].includes(e.printer_state)},on:{click:function(i){return e.doSendMove("Y+"+r,e.feedrateXY)}}},[t("span",{staticClass:"body-2"},[e._v("+"+e._s(r))])])})],2)],1)],1),t(x,{attrs:{dense:""}},[t(b,{staticClass:"text-center"},[t(Wt,{staticClass:"_btn-group row no-gutters"},[e._l(e.stepsZsorted,function(r){return t(g,{key:"z-"+r,staticClass:"btnMinWidthAuto col btnGroup",attrs:{disabled:["printing"].includes(e.printer_state)},on:{click:function(i){return e.doSendMove("Z-"+r,e.feedrateZ)}}},[t("span",{staticClass:"body-2"},[e._v("–"+e._s(r))])])}),t(g,{staticClass:"font-weight-bold btnHomeAxis btnGroup",attrs:{disabled:["printing"].includes(e.printer_state),color:e.homedAxes.includes("z")?"primary":"warning",loading:e.loadings.includes("homeZ")},on:{click:e.doHomeZ}},[e._v(" Z ")]),e._l(e.stepsZsortedReverse,function(r){return t(g,{key:"z+"+r,staticClass:"btnMinWidthAuto col btnGroup",attrs:{disabled:["printing"].includes(e.printer_state)},on:{click:function(i){return e.doSendMove("Z+"+r,e.feedrateZ)}}},[t("span",{staticClass:"body-2"},[e._v("+"+e._s(r))])])})],2)],1)],1)],1)},FA=[],RA=E(Ch,AA,FA,!1,null,"1465edd3");const HA=RA.exports;var jA=Object.getOwnPropertyDescriptor,IA=(s,e,t,r)=>{for(var i=r>1?void 0:r?jA(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let $h=class extends k(L,Je){constructor(){super(...arguments),this.homeIcon="M10,20L10,14L14,14L14,20L19,20L19,12L22,12L12,3L2,12L5,12L5,20L10,20Z",this.pathHomeButtonTop="M9.188,-0C9.634,0.001 10.028,0.291 10.162,0.717C10.295,1.142 10.136,1.605 9.77,1.86C6.722,4.035 4.05,6.701 1.869,9.743C1.614,10.11 1.151,10.269 0.724,10.135C0.298,10.002 0.008,9.607 0.008,9.16C0,6.418 0,2.781 0,1.029C-0,0.756 0.108,0.495 0.302,0.302C0.495,0.108 0.756,-0 1.029,0L9.188,-0Z",this.pathHomeButtonBottom="M9.188,0C9.634,0.001 10.028,0.291 10.162,0.717C10.295,1.142 10.136,1.605 9.77,1.86C6.722,4.035 4.05,6.701 1.869,9.743C1.614,10.11 1.151,10.269 0.724,10.135C0.298,10.002 0.008,9.607 0.008,9.16C0,6.418 0,2.781 0,1.029C-0,0.756 0.108,0.495 0.302,0.302C0.495,0.108 0.756,-0 1.029,0L9.188,0Z",this.xyStepOuter="M43.181,8.535C43.262,8.453 43.373,8.409 43.488,8.412C43.602,8.415 43.711,8.466 43.787,8.551C47.661,12.933 50,18.695 50,25C50,31.291 47.672,37.042 43.811,41.42C43.735,41.505 43.627,41.556 43.512,41.559C43.398,41.562 43.287,41.518 43.206,41.437C42.343,40.575 39.981,38.213 39.981,38.213C43.11,34.7 45,30.069 45,25C45,19.918 43.1,15.276 39.956,11.759C39.956,11.759 42.319,9.397 43.181,8.535Z",this.xyStepOuterMid="M47.418,4.777C57.663,18.688 57.829,31.029 47.304,45.072L39.308,37.098C42.081,33.838 43.75,29.612 43.75,25C43.75,20.371 42.069,16.132 39.277,12.868L47.418,4.777Z",this.xyStepInnerMid="M54.897,-1.964C68.991,16.277 68.542,32.764 54.738,51.763L44.077,41.131L38.115,35.169C40.361,32.389 41.667,28.846 41.667,25C41.667,21.132 40.346,17.57 38.076,14.784L54.897,-1.964Z",this.xyStepInner="M36.096,19.243C35.88,18.839 35.954,18.342 36.278,18.019C40.686,13.619 69.84,-15.445 69.84,-15.445C90.891,13.786 89.845,38.467 69.564,65.144C69.564,65.144 40.684,36.265 36.318,31.899C35.996,31.576 35.922,31.081 36.134,30.678C37.008,28.975 37.5,27.044 37.5,25C37.5,22.925 36.993,20.967 36.096,19.243Z",this.zStepOuter="M66.037,2.5C66.037,1.672 66.709,1 67.537,1L74.537,1C75.365,1 76.037,1.672 76.037,2.5L76.037,7.521C74.428,7.179 72.759,7 71.048,7C69.33,7 67.654,7.181 66.037,7.525L66.037,2.5Z",this.zStepOuterMid="M66.037,7.221C69.367,6.597 72.7,6.583 76.037,7.192L76.037,13.702C74.453,13.245 72.778,13 71.048,13C69.309,13 67.627,13.247 66.037,13.708L66.037,7.221Z",this.zStepInnerMid="M66.037,13.244C69.353,12.66 72.687,12.7 76.037,13.355L76.037,20.099C74.523,19.39 72.831,19 71.048,19C69.256,19 67.556,19.393 66.037,20.109L66.037,13.244Z",this.zStepInner="M66.037,19.186C69.409,18.542 72.742,18.52 76.037,19.102L76.037,23.682C76.037,23.815 75.984,23.942 75.891,24.036C75.564,24.362 74.774,25.153 74.359,25.567C74.204,25.722 73.967,25.757 73.773,25.656C72.955,25.236 72.029,25 71.048,25C70.051,25 69.112,25.243 68.284,25.674C68.09,25.777 67.852,25.742 67.697,25.586C67.283,25.175 66.506,24.395 66.183,24.071C66.09,23.977 66.037,23.85 66.037,23.718C66.037,22.806 66.037,19.186 66.037,19.186Z",this.zTiltIcon1="M74.189,31.503L67.751,30.009L67.638,30.496L74.076,31.99L74.189,31.503Z",this.zTiltIcon2="M74.361,32.85L74.034,32.676L74.939,32.188L75.039,33.211L74.745,33.055C74.386,33.724 73.858,34.288 73.213,34.69L72.983,34.321C73.563,33.959 74.038,33.452 74.361,32.85ZM67.193,28.75C67.586,28.1 68.142,27.564 68.807,27.196L69.018,27.576C68.42,27.907 67.919,28.389 67.565,28.974L67.883,29.165L66.954,29.605L66.907,28.578L67.193,28.75Z",this.engineOffIcon="M3.78 2.5L21.5 20.22l-1.27 1.28L18 19.27V20h-8l-2-2H5v-3H3v3H1v-8h2v3h2v-3l1.87-1.86L2.5 3.77L3.78 2.5M20 9v3h-2V8h-6V6h3V4H7.82l15 15H23V9h-3Z"}get enableXYHoming(){return this.$store.state.gui.control.enableXYHoming}get reverseX(){return this.$store.state.gui.control.reverseX}get reverseY(){return this.$store.state.gui.control.reverseY}get reverseZ(){return this.$store.state.gui.control.reverseZ}get stepsXY(){var t,r;const e=(r=(t=this.$store.state.gui.control)==null?void 0:t.stepsCircleXY)!=null?r:[];return Array.from(new Set([...e!=null?e:[]])).sort((i,n)=>i-n)}get stepsZ(){var t,r;const e=(r=(t=this.$store.state.gui.control)==null?void 0:t.stepsCircleZ)!=null?r:[];return Array.from(new Set([...e!=null?e:[]])).sort((i,n)=>i-n)}get isPrinting(){return["printing"].includes(this.printer_state)}get stepTextClass(){return!this.homedAxes.includes("xy")||this.isPrinting?["disabled"]:[]}get xStepClass(){return!this.homedAxes.includes("x")||this.isPrinting?["disabled"]:[]}get yStepClass(){return!this.homedAxes.includes("y")||this.isPrinting?["disabled"]:[]}get zStepClass(){return!this.homedAxes.includes("z")||this.isPrinting?["disabled"]:[]}get xHomeClass(){let e=[];return this.homedAxes.includes("x")&&e.push("homed"),this.isPrinting&&e.push("disabled"),e}get yHomeClass(){let e=[];return this.homedAxes.includes("y")&&e.push("homed"),this.isPrinting&&e.push("disabled"),e}get xyHomeClass(){let e=[];return this.homedAxes.includes("xy")&&e.push("homed"),this.isPrinting&&e.push("disabled"),e}get xyzHomeClass(){let e=[];return this.homedAxes.includes("xyz")&&e.push("homed"),this.isPrinting&&e.push("disabled"),e}get zHomeClass(){let e=[];return this.homedAxes.includes("z")&&e.push("homed"),this.isPrinting&&e.push("disabled"),e}get colorSpecialButton(){let e=[];return this.isPrinting&&e.push("disabled"),this.existsQGL?e.push(this.colorQuadGantryLevel):this.existsZtilt&&e.push(this.colorZTilt),e}get motorsOffClass(){let e=[];return e.push(this.homedAxes!==""?"primary":"warning"),this.isPrinting&&e.push("disabled"),e}clickSpecialButton(){if(this.existsQGL)this.doQGL();else if(this.existsZtilt)return this.doZtilt()}};$h=IA([S],$h);var NA=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(x,[t(b,{staticClass:"pa-0 mt-1"},[t("svg",{staticStyle:{"fill-rule":"evenodd","clip-rule":"evenodd","stroke-linejoin":"round","stroke-miterlimit":"2"},attrs:{width:"100%",height:"100%",viewBox:"0 0 78 62",xmlns:"http://www.w3.org/2000/svg","xml:space":"preserve"}},[t("g",{attrs:{id:"ArtBoard1",transform:"matrix(1.24239,0,0,1,0,0)"}},[t("rect",{staticStyle:{fill:"none"},attrs:{x:"0",y:"0",width:"62",height:"62"}}),t("g",{attrs:{id:"home_buttons",transform:"matrix(0.804902,0,0,1,0.0430241,0)"}},[t("a",{class:e.xHomeClass,on:{click:e.doHomeX}},[t("g",{attrs:{id:"home_x",transform:"matrix(0.707107,-0.707107,0.707107,0.707107,-1.41799,4.05689)"}},[t("g",{staticClass:"home_button",attrs:{id:"home_button_x",transform:"matrix(0.68689,0.68689,-0.68689,0.68689,3.87132,0.962447)"}},[t("path",{attrs:{d:e.pathHomeButtonTop}})]),t("g",{attrs:{transform:"matrix(0.654426,0,0,0.654426,0.298666,4.01315)"}},[t("text",{attrs:{x:"3.789px",y:"6.089px"}},[e._v("X")])]),t("g",{staticClass:"home_icon",attrs:{id:"Icon",transform:"matrix(0.147059,0,0,0.147059,2.10662,2.08254)"}},[t("path",{staticStyle:{"fill-rule":"nonzero"},attrs:{d:e.homeIcon}})])])]),t("a",{class:e.yHomeClass,on:{click:e.doHomeY}},[t("g",{attrs:{id:"home_y",transform:"matrix(0.707107,0.707107,-0.707107,0.707107,57.8807,-1.41799)"}},[t("g",{staticClass:"home_button",attrs:{id:"home_button_y",transform:"matrix(0.68689,0.68689,-0.68689,0.68689,3.87132,0.962447)"}},[t("path",{attrs:{d:e.pathHomeButtonTop}})]),t("g",{attrs:{transform:"matrix(0.654426,0,0,0.654426,0.298666,4.01315)"}},[t("text",{attrs:{x:"3.789px",y:"6.089px"}},[e._v("Y")])]),t("g",{staticClass:"home_icon",attrs:{id:"icon",transform:"matrix(0.147059,0,0,0.147059,2.10662,2.08254)"}},[t("path",{staticStyle:{"fill-rule":"nonzero"},attrs:{d:e.homeIcon}})])])]),t("a",{class:e.zHomeClass,on:{click:e.doHomeZ}},[t("g",{attrs:{id:"home_z",transform:"matrix(-0.707107,0.707107,-0.707107,-0.707107,63.3555,57.8807)"}},[t("g",{staticClass:"home_button",attrs:{id:"home_button_z",transform:"matrix(0.68689,0.68689,-0.68689,0.68689,3.87132,0.962447)"}},[t("path",{attrs:{d:e.pathHomeButtonBottom}})]),t("g",{attrs:{transform:"matrix(0.654426,0,0,0.654426,0.298666,4.01315)"}},[t("text",{attrs:{x:"3.93px",y:"6.089px"}},[e._v("Z")])]),t("g",{staticClass:"home_icon",attrs:{id:"icon1",transform:"matrix(0.147059,0,0,0.147059,2.10662,2.08254)"}},[t("path",{staticStyle:{"fill-rule":"nonzero"},attrs:{d:e.homeIcon}})])])]),e.enableXYHoming?t("a",{class:e.xyHomeClass,on:{click:e.doHomeXY}},[t("g",{attrs:{id:"home_xy",transform:"matrix(-0.707107,-0.707107,0.707107,-0.707107,4.05689,63.3555)"}},[t("g",{staticClass:"home_button",attrs:{id:"home_button_xy",transform:"matrix(0.68689,0.68689,-0.68689,0.68689,3.87132,0.962447)"}},[t("path",{attrs:{d:e.pathHomeButtonBottom}})]),t("g",{attrs:{transform:"matrix(0.654426,0,0,0.654426,0.298666,4.01315)"}},[t("text",{attrs:{x:"2.3px",y:"6.089px"}},[e._v("XY")])]),t("g",{staticClass:"home_icon",attrs:{id:"icon2",transform:"matrix(0.147059,0,0,0.147059,2.10662,2.08254)"}},[t("path",{staticStyle:{"fill-rule":"nonzero"},attrs:{d:e.homeIcon}})])])]):t("a",{class:e.xyzHomeClass,on:{click:e.doHome}},[t("g",{attrs:{id:"home_all",transform:"matrix(-0.707107,-0.707107,0.707107,-0.707107,4.05689,63.3555)"}},[t("g",{staticClass:"home_button",attrs:{id:"home_button_all",transform:"matrix(0.68689,0.68689,-0.68689,0.68689,3.87132,0.962447)"}},[t("path",{attrs:{d:e.pathHomeButtonBottom}})]),t("g",{staticClass:"home_icon",attrs:{id:"icon3",transform:"matrix(0.29377,0,0,0.29377,0.346087,1.64241)"}},[t("path",{staticStyle:{"fill-rule":"nonzero"},attrs:{d:e.homeIcon}})])])]),e.enableXYHoming?t("a",{class:e.xyzHomeClass,on:{click:e.doHome}},[t("g",{staticClass:"home_button",attrs:{id:"home_all_center"}},[t("circle",{attrs:{id:"home_button_all_center",cx:"31",cy:"31",r:"5"}})]),t("g",{staticClass:"home-icon",attrs:{id:"icon4",transform:"scale(0.3) translate(91.25,91.25)"}},[t("path",{staticStyle:{"fill-rule":"nonzero"},attrs:{d:e.homeIcon}})])]):e._e()]),t("g",{attrs:{id:"step_buttons",transform:"matrix(0.804902,0,0,1,0.0430241,0)"}},[t("g",{attrs:{id:"Z",transform:"matrix(1.24239,0,0,1,-0.0534526,0)"}},[t("g",{class:e.zStepClass,attrs:{id:"Bottom",transform:"matrix(-1,-1.52149e-16,9.85721e-17,-1,114.34,62)"}},[t("a",{staticClass:"step inner",on:{click:function(r){return e.doSendMove("Z".concat(e.reverseZ?"+":"-").concat(e.stepsZ.length>=0?e.stepsZ[0]:0),e.feedrateZ)}}},[t("g",{attrs:{transform:"matrix(0.804902,0,0,1,0,0)"}},[t("path",{attrs:{d:e.zStepInner}})])]),t("a",{staticClass:"step inner-mid",on:{click:function(r){return e.doSendMove("Z".concat(e.reverseZ?"+":"-").concat(e.stepsZ.length>=1?e.stepsZ[1]:0),e.feedrateZ)}}},[t("g",{attrs:{transform:"matrix(0.804902,1.2326e-32,-9.92118e-33,1,-5.71917e-15,-7.10543e-15)"}},[t("path",{attrs:{d:e.zStepInnerMid}})])]),t("a",{staticClass:"step outer-mid",on:{click:function(r){return e.doSendMove("Z".concat(e.reverseZ?"+":"-").concat(e.stepsZ.length>=2?e.stepsZ[2]:0),e.feedrateZ)}}},[t("g",{attrs:{transform:"matrix(0.804902,0,0,1,0,0)"}},[t("path",{attrs:{d:e.zStepOuterMid}})])]),t("a",{staticClass:"step outer",on:{click:function(r){return e.doSendMove("Z".concat(e.reverseZ?"+":"-").concat(e.stepsZ.length>=3?e.stepsZ[3]:0),e.feedrateZ)}}},[t("g",{attrs:{transform:"matrix(0.804902,0,0,1,0,0)"}},[t("path",{attrs:{d:e.zStepOuter}})])])]),t("g",{class:e.zStepClass,attrs:{id:"Top"}},[t("a",{staticClass:"step inner",on:{click:function(r){return e.doSendMove("Z".concat(e.reverseZ?"-":"+").concat(e.stepsZ.length>=0?e.stepsZ[0]:0),e.feedrateZ)}}},[t("g",{attrs:{transform:"matrix(0.804902,0,0,1,0,0)"}},[t("path",{attrs:{d:e.zStepInner}})])]),t("a",{staticClass:"step inner-mid",on:{click:function(r){return e.doSendMove("Z".concat(e.reverseZ?"-":"+").concat(e.stepsZ.length>=1?e.stepsZ[1]:0),e.feedrateZ)}}},[t("g",{attrs:{transform:"matrix(0.804902,1.2326e-32,-9.92118e-33,1,-5.71917e-15,-7.10543e-15)"}},[t("path",{attrs:{d:e.zStepInnerMid}})])]),t("a",{staticClass:"step outer-mid",on:{click:function(r){return e.doSendMove("Z".concat(e.reverseZ?"-":"+").concat(e.stepsZ.length>=2?e.stepsZ[2]:0),e.feedrateZ)}}},[t("g",{attrs:{transform:"matrix(0.804902,0,0,1,0,0)"}},[t("path",{attrs:{d:e.zStepOuterMid}})])]),t("a",{staticClass:"step outer",on:{click:function(r){return e.doSendMove("Z".concat(e.reverseZ?"-":"+").concat(e.stepsZ.length>=3?e.stepsZ[3]:0),e.feedrateZ)}}},[t("g",{attrs:{transform:"matrix(0.804902,0,0,1,0,0)"}},[t("path",{attrs:{d:e.zStepOuter}})])])])]),t("g",{class:e.zStepClass,attrs:{id:"stepsZ",transform:"matrix(1,0,0,1,40,0)"}},[t("g",{attrs:{transform:"matrix(1,0,0,1,0.483899,4.07983)"}},[t("text",{attrs:{x:"30.7px",y:"19.056px","text-anchor":"middle"}},[e._v(" "+e._s(e.stepsZ.length>=0?e.stepsZ[0]:"--")+" ")])]),t("g",{attrs:{transform:"matrix(1,0,0,1,0.220227,-1.95729)"}},[t("text",{attrs:{x:"30.7px",y:"19.056px","text-anchor":"middle"}},[e._v(" "+e._s(e.stepsZ.length>=1?e.stepsZ[1]:"--")+" ")])]),t("g",{attrs:{transform:"matrix(1,0,0,1,0.220227,-7.99441)"}},[t("text",{attrs:{x:"30.7px",y:"19.056px","text-anchor":"middle"}},[e._v(" "+e._s(e.stepsZ.length>=2?e.stepsZ[2]:"--")+" ")])]),t("g",{attrs:{transform:"matrix(1,0,0,1,0.220227,-14.0315)"}},[t("text",{attrs:{x:"30.7px",y:"19.056px","text-anchor":"middle"}},[e._v(" "+e._s(e.stepsZ.length>=3?e.stepsZ[3]:"--")+" ")])])]),t("g",{attrs:{id:"XY"}},[t("g",{class:e.xStepClass,attrs:{id:"Right"}},[t("a",{staticClass:"step inner",on:{click:function(r){return e.doSendMove("X".concat(e.reverseX?"-":"+").concat(e.stepsXY.length>=0?e.stepsXY[0]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(0.48,0,0,0.48,19,19)"}},[t("path",{attrs:{d:e.xyStepInner}})])]),t("a",{staticClass:"step inner-mid",on:{click:function(r){return e.doSendMove("X".concat(e.reverseX?"-":"+").concat(e.stepsXY.length>=1?e.stepsXY[1]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(0.72,0,0,0.72,13,13)"}},[t("path",{attrs:{d:e.xyStepInnerMid}})])]),t("a",{staticClass:"step outer-mid",on:{click:function(r){return e.doSendMove("X".concat(e.reverseX?"-":"+").concat(e.stepsXY.length>=2?e.stepsXY[2]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(0.96,0,0,0.96,7,7)"}},[t("path",{attrs:{d:e.xyStepOuterMid}})])]),t("a",{staticClass:"step outer",on:{click:function(r){return e.doSendMove("X".concat(e.reverseX?"-":"+").concat(e.stepsXY.length>=3?e.stepsXY[3]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(1.2,0,0,1.2,1,1)"}},[t("path",{attrs:{d:e.xyStepOuter}})])])]),t("g",{class:e.xStepClass,attrs:{id:"Left",transform:"matrix(-1,-1.22465e-16,1.22465e-16,-1,61.9767,61.9767)"}},[t("a",{staticClass:"step inner",on:{click:function(r){return e.doSendMove("X".concat(e.reverseX?"+":"-").concat(e.stepsXY.length>=0?e.stepsXY[0]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(0.48,0,0,0.48,19,19)"}},[t("path",{attrs:{d:e.xyStepInner}})])]),t("a",{staticClass:"step inner-mid",on:{click:function(r){return e.doSendMove("X".concat(e.reverseX?"+":"-").concat(e.stepsXY.length>=1?e.stepsXY[1]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(0.72,0,0,0.72,13,13)"}},[t("path",{attrs:{d:e.xyStepInnerMid}})])]),t("a",{staticClass:"step outer-mid",on:{click:function(r){return e.doSendMove("X".concat(e.reverseX?"+":"-").concat(e.stepsXY.length>=2?e.stepsXY[2]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(0.96,0,0,0.96,7,7)"}},[t("path",{attrs:{d:e.xyStepOuterMid}})])]),t("a",{staticClass:"step outer",on:{click:function(r){return e.doSendMove("X".concat(e.reverseX?"+":"-").concat(e.stepsXY.length>=3?e.stepsXY[3]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(1.2,0,0,1.2,1,1)"}},[t("path",{attrs:{d:e.xyStepOuter}})])])]),t("g",{class:e.yStepClass,attrs:{id:"Bottom1",transform:"matrix(6.12323e-17,1,-1,6.12323e-17,61.9767,-1.77705e-14)"}},[t("a",{staticClass:"step inner",on:{click:function(r){return e.doSendMove("Y".concat(e.reverseY?"+":"-").concat(e.stepsXY.length>=0?e.stepsXY[0]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(0.48,0,0,0.48,19,19)"}},[t("path",{attrs:{d:e.xyStepInner}})])]),t("a",{staticClass:"step inner-mid",on:{click:function(r){return e.doSendMove("Y".concat(e.reverseY?"+":"-").concat(e.stepsXY.length>=1?e.stepsXY[1]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(0.72,0,0,0.72,13,13)"}},[t("path",{attrs:{d:e.xyStepInnerMid}})])]),t("a",{staticClass:"step outer-mid",on:{click:function(r){return e.doSendMove("Y".concat(e.reverseY?"+":"-").concat(e.stepsXY.length>=2?e.stepsXY[2]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(0.96,0,0,0.96,7,7)"}},[t("path",{attrs:{d:e.xyStepOuterMid}})])]),t("a",{staticClass:"step outer",on:{click:function(r){return e.doSendMove("Y".concat(e.reverseY?"+":"-").concat(e.stepsXY.length>=3?e.stepsXY[3]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(1.2,0,0,1.2,1,1)"}},[t("path",{attrs:{d:e.xyStepOuter}})])])]),t("g",{class:e.yStepClass,attrs:{id:"Top1",transform:"matrix(6.12323e-17,-1,1,6.12323e-17,7.10543e-15,61.9767)"}},[t("a",{staticClass:"step inner",on:{click:function(r){return e.doSendMove("Y".concat(e.reverseY?"-":"+").concat(e.stepsXY.length>=0?e.stepsXY[0]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(0.48,0,0,0.48,19,19)"}},[t("path",{attrs:{d:e.xyStepInner}})])]),t("a",{staticClass:"step inner-mid",on:{click:function(r){return e.doSendMove("Y".concat(e.reverseY?"-":"+").concat(e.stepsXY.length>=1?e.stepsXY[1]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(0.72,0,0,0.72,13,13)"}},[t("path",{attrs:{d:e.xyStepInnerMid}})])]),t("a",{staticClass:"step outer-mid",on:{click:function(r){return e.doSendMove("Y".concat(e.reverseY?"-":"+").concat(e.stepsXY.length>=2?e.stepsXY[2]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(0.96,0,0,0.96,7,7)"}},[t("path",{attrs:{d:e.xyStepOuterMid}})])]),t("a",{staticClass:"step outer",on:{click:function(r){return e.doSendMove("Y".concat(e.reverseY?"-":"+").concat(e.stepsXY.length>=3?e.stepsXY[3]:0),e.feedrateXY)}}},[t("g",{attrs:{transform:"matrix(1.2,0,0,1.2,1,1)"}},[t("path",{attrs:{d:e.xyStepOuter}})])])])]),t("g",{class:e.stepTextClass,attrs:{id:"stepsXY"}},[t("g",{attrs:{transform:"matrix(1,0,0,1,0.483899,4.07983)"}},[t("text",{attrs:{x:"30.5px",y:"19.056px","text-anchor":"middle"}},[e._v(" "+e._s(e.stepsXY.length>=0?e.stepsXY[0]:"--")+" ")])]),t("g",{attrs:{transform:"matrix(1,0,0,1,0.220227,-1.95729)"}},[t("text",{attrs:{x:"30.5px",y:"19.056px","text-anchor":"middle"}},[e._v(" "+e._s(e.stepsXY.length>=1?e.stepsXY[1]:"--")+" ")])]),t("g",{attrs:{transform:"matrix(1,0,0,1,0.220227,-7.99441)"}},[t("text",{attrs:{x:"30.5px",y:"19.056px","text-anchor":"middle"}},[e._v(" "+e._s(e.stepsXY.length>=2?e.stepsXY[2]:"--")+" ")])]),t("g",{attrs:{transform:"matrix(1,0,0,1,0.220227,-14.0315)"}},[t("text",{attrs:{x:"30.5px",y:"19.056px","text-anchor":"middle"}},[e._v(" "+e._s(e.stepsXY.length>=3?e.stepsXY[3]:"--")+" ")])])])])]),e.existsQGL&&e.actionButton==="qgl"?t("a",{class:e.colorSpecialButton,attrs:{id:"tilt_adjust"},on:{click:e.clickSpecialButton}},[t("circle",{attrs:{id:"qgl_button",cx:"70.92",cy:"31",r:"5"}}),t("text",{attrs:{x:"66.776px",y:"32.066px"}},[e._v("QGL")]),t("g",{attrs:{id:"tilt_icon"}},[t("path",{attrs:{d:e.zTiltIcon1}}),t("path",{attrs:{d:e.zTiltIcon2}})])]):e.existsZtilt&&e.actionButton==="ztilt"?t("a",{class:e.colorSpecialButton,attrs:{id:"tilt_adjust"},on:{click:e.clickSpecialButton}},[t("circle",{attrs:{id:"tilt_button",cx:"70.92",cy:"31",r:"5"}}),t("text",{attrs:{x:"66.776px",y:"32.066px"}},[e._v("Z-TILT")]),t("g",{attrs:{id:"tilt_icon"}},[t("path",{attrs:{d:e.zTiltIcon1}}),t("path",{attrs:{d:e.zTiltIcon2}})])]):t("a",{class:e.motorsOffClass,attrs:{id:"stepper_off"},on:{click:function(r){return e.doSend("M84")}}},[t("circle",{attrs:{id:"stepper_off_button",cx:"70.92",cy:"31",r:"5"}}),t("g",{attrs:{id:"stepper_off_icon",transform:"scale(0.3) translate(224,91)"}},[t("path",{attrs:{d:e.engineOffIcon}})])])])])],1)],1)},VA=[],BA=E($h,NA,VA,!1,null,"c8151d8a");const UA=BA.exports;var WA=Object.getOwnPropertyDescriptor,zA=(s,e,t,r)=>{for(var i=r>1?void 0:r?WA(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let xh=class extends k(L,Je){constructor(){super(...arguments),this.mdiChevronUp=du,this.mdiChevronLeft=Sw,this.mdiChevronRight=Pw,this.mdiChevronDown=fr,this.mdiEngineOff=jp,this.mdiHome=av}get selectedCrossStep(){return this.$store.state.gui.control.selectedCrossStep}set selectedCrossStep(e){this.$store.dispatch("gui/saveSetting",{name:"control.selectedCrossStep",value:e})}get stepSize(){return this.stepsReversed[this.selectedCrossStep]}get reverseX(){return this.$store.state.gui.control.reverseX}get reverseY(){return this.$store.state.gui.control.reverseY}get reverseZ(){return this.$store.state.gui.control.reverseZ}get stepsAll(){var e,t;return(t=(e=this.$store.state.gui.control)==null?void 0:e.stepsAll)!=null?t:[]}get stepsReversed(){var e;return Array.from(new Set([...(e=this.stepsAll)!=null?e:[]])).sort((t,r)=>t-r)}};xh=zA([S({components:{Responsive:tt}})],xh);var GA=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(tt,{attrs:{breakpoints:{small:r=>r.width<=300}},scopedSlots:e._u([{key:"default",fn:function({el:r}){return[t("div",[t(x,[t(b,[t(x,{staticClass:"mb-1",attrs:{dense:""}},[t(b,{attrs:{cols:"3"}}),t(b,{attrs:{cols:"3"}},[t(g,{staticClass:"btnMinWidthAuto fill-width",attrs:{disabled:!e.yAxisHomed||e.selectedCrossStep===null||e.selectedCrossStep===void 0||["printing"].includes(e.printer_state)},on:{click:function(i){return e.doSendMove("Y".concat(e.reverseY?"-":"+").concat(e.stepSize),e.feedrateXY)}}},[t(_,[e._v(e._s(e.mdiChevronUp))])],1)],1),t(b,{attrs:{cols:"3"}}),t(b,{attrs:{cols:"3"}},[t(g,{staticClass:"btnMinWidthAuto fill-width",attrs:{disabled:!e.zAxisHomed||e.selectedCrossStep===null||e.selectedCrossStep===void 0||["printing"].includes(e.printer_state)},on:{click:function(i){return e.doSendMove("Z".concat(e.reverseZ?"-":"+").concat(e.stepSize),e.feedrateZ)}}},[t(_,[e._v(e._s(e.mdiChevronUp))])],1)],1)],1),t(x,{attrs:{dense:""}},[t(b,{staticClass:"position-relative",attrs:{cols:"3"}},[t(g,{staticClass:"btnMinWidthAuto fill-width position-absolute",staticStyle:{top:"-50%",width:"calc(100% - 8px)"},attrs:{disabled:!e.xAxisHomed||e.selectedCrossStep===null||e.selectedCrossStep===void 0||["printing"].includes(e.printer_state)},on:{click:function(i){return e.doSendMove("X".concat(e.reverseX?"+":"-").concat(e.stepSize),e.feedrateXY)}}},[t(_,[e._v(e._s(e.mdiChevronLeft))])],1)],1),t(b,{attrs:{cols:"3"}},[t(g,{staticClass:"btnMinWidthAuto fill-width",attrs:{disabled:!e.yAxisHomed||e.selectedCrossStep===null||e.selectedCrossStep===void 0||["printing"].includes(e.printer_state)},on:{click:function(i){return e.doSendMove("Y".concat(e.reverseY?"+":"-").concat(e.stepSize),e.feedrateXY)}}},[t(_,[e._v(e._s(e.mdiChevronDown))])],1)],1),t(b,{staticClass:"position-relative",attrs:{cols:"3"}},[t(g,{staticClass:"btnMinWidthAuto fill-width position-absolute",staticStyle:{top:"-50%",width:"calc(100% - 8px)"},attrs:{disabled:!e.xAxisHomed||e.selectedCrossStep===null||e.selectedCrossStep===void 0||["printing"].includes(e.printer_state)},on:{click:function(i){return e.doSendMove("X".concat(e.reverseX?"-":"+").concat(e.stepSize),e.feedrateXY)}}},[t(_,[e._v(e._s(e.mdiChevronRight))])],1)],1),t(b,{attrs:{cols:"3"}},[t(g,{staticClass:"btnMinWidthAuto fill-width",attrs:{disabled:!e.zAxisHomed||e.selectedCrossStep===null||e.selectedCrossStep===void 0||["printing"].includes(e.printer_state)},on:{click:function(i){return e.doSendMove("Z".concat(e.reverseZ?"+":"-").concat(e.stepSize),e.feedrateZ)}}},[t(_,[e._v(e._s(e.mdiChevronDown))])],1)],1)],1)],1),r.is.small?e._e():t(b,{staticClass:"d-flex align-center"},[t("div",{staticClass:"flex-grow-1",staticStyle:{"border-radius":"4px",overflow:"hidden"}},[t(x,{staticStyle:{"margin-bottom":"-2px !important"},attrs:{dense:""}},[t(b,{attrs:{cols:"6"}},[t(g,{staticClass:"w-100",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("homeAll"),color:e.homedAxes.includes("xyz")?"primary":"warning",height:"30",tile:""},on:{click:e.doHome}},[t("div",{staticClass:"d-flex align-center"},[t(_,[e._v(e._s(e.mdiHome))]),t("span",[e._v(e._s(e.$t("Panels.ToolheadControlPanel.ALL")))])],1)])],1),t(b,{staticClass:"d-flex",attrs:{cols:"6"}},[e.actionButton==="qgl"?t(g,{staticClass:"btnMinWidthAuto flex-grow-1 px-0",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("qgl"),color:e.colorQuadGantryLevel,height:"30",dense:"",tile:""},on:{click:e.doQGL}},[e._v(" "+e._s(e.$t("Panels.ToolheadControlPanel.QGL"))+" ")]):e.actionButton==="ztilt"?t(g,{staticClass:"btnMinWidthAuto flex-grow-1 px-0",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("zTilt"),color:e.colorZTilt,height:"30",dense:"",tile:""},on:{click:e.doZtilt}},[e._v(" "+e._s(e.$t("Panels.ToolheadControlPanel.ZTilt"))+" ")]):t(g,{staticClass:"flex-grow-1 px-0",attrs:{disabled:["printing"].includes(e.printer_state),color:e.homedAxes!==""?"primary":"warning",height:"30",dense:"",tile:""},on:{click:function(i){return e.doSend("M84")}}},[t(_,[e._v(e._s(e.mdiEngineOff))])],1)],1)],1),t(x,{attrs:{dense:""}},[e.enableXYHoming?e._e():t(b,{staticClass:"flex-grow-1",attrs:{cols:"4"}},[t(g,{staticClass:"btnMinWidthAuto w-100",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("homeX"),color:e.homedAxes.includes("x")?"primary":"warning",tile:"",height:"30"},on:{click:e.doHomeX}},[e._v(" X ")])],1),e.enableXYHoming?t(b,{staticClass:"flex-grow-1",attrs:{cols:"6"}},[t(g,{staticClass:"btnMinWidthAuto w-100",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("homeY"),color:e.homedAxes.includes("xy")?"primary":"warning",tile:"",height:"30"},on:{click:e.doHomeXY}},[e._v(" XY ")])],1):t(b,{staticClass:"flex-grow-1",attrs:{cols:"4"}},[t(g,{staticClass:"btnMinWidthAuto w-100",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("homeY"),color:e.homedAxes.includes("y")?"primary":"warning",tile:"",height:"30"},on:{click:e.doHomeY}},[e._v(" Y ")])],1),t(b,{staticClass:"flex-grow-1",class:e.enableXYHoming?"col-6":"col-4"},[t(g,{staticClass:"btnMinWidthAuto w-100",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("homeZ"),color:e.homedAxes.includes("z")?"primary":"warning",tile:"",height:"30"},on:{click:e.doHomeZ}},[e._v(" Z ")])],1)],1)],1)])],1),r.is.small?t(x,[t(b,{staticClass:"d-flex align-center"},[t("div",{staticClass:"flex-grow-1",staticStyle:{"border-radius":"4px",overflow:"hidden"}},[t(x,{staticStyle:{"margin-bottom":"-2px !important"},attrs:{dense:""}},[t(b,{attrs:{cols:"6"}},[t(g,{staticClass:"w-100",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("homeAll"),color:e.homedAxes.includes("xyz")?"primary":"warning",height:"30",tile:""},on:{click:e.doHome}},[t("div",{staticClass:"d-flex align-center"},[t(_,[e._v(e._s(e.mdiHome))]),t("span",[e._v(e._s(e.$t("Panels.ToolheadControlPanel.ALL")))])],1)])],1),t(b,{staticClass:"d-flex",attrs:{cols:"6"}},[e.actionButton==="qgl"?t(g,{staticClass:"btnMinWidthAuto flex-grow-1 px-0",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("qgl"),color:e.colorQuadGantryLevel,height:"30",dense:"",tile:""},on:{click:e.doQGL}},[e._v(" "+e._s(e.$t("Panels.ToolheadControlPanel.QGL"))+" ")]):e.actionButton==="ztilt"?t(g,{staticClass:"btnMinWidthAuto flex-grow-1 px-0",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("zTilt"),color:e.colorZTilt,height:"30",dense:"",tile:""},on:{click:e.doZtilt}},[e._v(" "+e._s(e.$t("Panels.ToolheadControlPanel.ZTilt"))+" ")]):t(g,{staticClass:"flex-grow-1 px-0",attrs:{disabled:["printing"].includes(e.printer_state),color:e.homedAxes!==""?"primary":"warning",height:"30",dense:"",tile:""},on:{click:function(i){return e.doSend("M84")}}},[t(_,[e._v(e._s(e.mdiEngineOff))])],1)],1)],1),t(x,{attrs:{dense:""}},[e.enableXYHoming?e._e():t(b,{staticClass:"flex-grow-1",attrs:{cols:"4"}},[t(g,{staticClass:"btnMinWidthAuto w-100",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("homeX"),color:e.homedAxes.includes("x")?"primary":"warning",tile:"",height:"30"},on:{click:e.doHomeX}},[e._v(" X ")])],1),e.enableXYHoming?t(b,{staticClass:"flex-grow-1",attrs:{cols:"6"}},[t(g,{staticClass:"btnMinWidthAuto w-100",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("homeY"),color:e.homedAxes.includes("xy")?"primary":"warning",tile:"",height:"30"},on:{click:e.doHomeXY}},[e._v(" XY ")])],1):t(b,{staticClass:"flex-grow-1",attrs:{cols:"4"}},[t(g,{staticClass:"btnMinWidthAuto w-100",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("homeY"),color:e.homedAxes.includes("y")?"primary":"warning",tile:"",height:"30"},on:{click:e.doHomeY}},[e._v(" Y ")])],1),t(b,{staticClass:"flex-grow-1",class:e.enableXYHoming?"col-6":"col-4"},[t(g,{staticClass:"btnMinWidthAuto w-100",attrs:{disabled:["printing"].includes(e.printer_state),loading:e.loadings.includes("homeZ"),color:e.homedAxes.includes("z")?"primary":"warning",tile:"",height:"30"},on:{click:e.doHomeZ}},[e._v(" Z ")])],1)],1)],1)])],1):e._e(),t(x,{staticClass:"mt-3",attrs:{"no-gutters":""}},[t(b,[e.stepsReversed.length>0?t(Nn,{key:"all-steps-".concat(e.stepsReversed.join("_")),staticStyle:{"flex-wrap":"nowrap",width:"100%"},attrs:{dense:"",mandatory:""},model:{value:e.selectedCrossStep,callback:function(i){e.selectedCrossStep=i},expression:"selectedCrossStep"}},e._l(e.stepsReversed,function(i){return t(g,{key:"step-".concat(i),staticClass:"btnMinWidthAuto flex-grow-1 px-0",staticStyle:{height:"28px"},attrs:{disabled:["printing"].includes(e.printer_state),dense:""}},[t("span",{staticClass:"body-2"},[e._v(e._s(i))])])}),1):t("div",{staticClass:"font-weight-bold warning rounded pa-2"},[e._v(" "+e._s(e.$t("Panels.ToolheadControlPanel.PleaseConfigureSteps"))+" "),t("br"),t("router-link",{staticStyle:{color:"white"},attrs:{to:"/settings/interface"}},[e._v(" "+e._s(e.$t("Panels.ToolheadControlPanel.SettingsInterfaceControl"))+" ")])],1)],1)],1)],1)]}}])})},ZA=[],qA=E(xh,GA,ZA,!1,null,"55a7e126");const XA=qA.exports;var YA=Object.getOwnPropertyDescriptor,JA=(s,e,t,r)=>{for(var i=r>1?void 0:r?YA(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let wh=class extends k(L,Je){constructor(){super(...arguments),this.mdiDotsVertical=mu,this.mdiEngineOff=jp,this.mdiGamepad=Up,this.mdiSpeedometer=Cv,this.mdiRestore=bS,this.mdiMenuDown=gr}get controlStyle(){var e;return(e=this.$store.state.gui.control.style)!=null?e:"bars"}get actionButton(){var e;return(e=this.$store.state.gui.control.actionButton)!=null?e:this.defaultActionButton}get speedFactor(){var e,t,r;return(r=(t=(e=this.$store.state.printer)==null?void 0:e.gcode_move)==null?void 0:t.speed_factor)!=null?r:1}get isPrinting(){return["printing"].includes(this.printer_state)}get axisControlVisible(){var e;return this.showControl?!(this.isPrinting&&((e=this.$store.state.gui.control.hideDuringPrint)!=null&&e)):!1}get showButtons(){return this.controlStyle!=="bars"&&(this.existsZtilt||this.existsQGL)?!0:this.existsBedScrews||this.existsBedTilt||this.existsDeltaCalibrate||this.existsScrewsTilt}get showControl(){var e;return(e=this.$store.state.gui.view.toolhead.showControl)!=null?e:!0}get showZOffset(){var e;return(e=this.$store.state.gui.view.toolhead.showZOffset)!=null?e:!0}get showSpeedFactor(){var e;return(e=this.$store.state.gui.view.toolhead.showSpeedFactor)!=null?e:!0}};wh=JA([S({components:{BarsControl:HA,CircleControl:UA,CrossControl:XA,MoveToControl:G0,Panel:U,ToolSlider:Fu,ZoffsetControl:z0}})],wh);var KA=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.klipperReadyForGui?t(U,{attrs:{icon:e.mdiGamepad,title:e.$t("Panels.ToolheadControlPanel.Headline"),collapsible:!0,"card-class":"toolhead-control-panel"},scopedSlots:e._u([{key:"buttons",fn:function(){return[e.showButtons?t(ye,{staticClass:"pa-0",attrs:{left:"","offset-y":"","close-on-content-click":!1},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{icon:"",tile:"",disabled:["printing"].includes(e.printer_state)}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiDotsVertical))])],1)]}}],null,!1,3697264518)},[t(Me,{attrs:{dense:""}},[e.controlStyle!=="bars"&&e.actionButton!=="m84"?t(J,[t(g,{staticStyle:{width:"100%"},attrs:{small:""},on:{click:function(r){return e.doSend("M84")}}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiEngineOff))]),e._v(" "+e._s(e.$t("Settings.ControlTab.MotorsOff",{isDefault:""}))+" ")],1)],1):e._e(),e.controlStyle!=="bars"&&e.existsZtilt&&e.actionButton!=="ztilt"?t(J,[t(g,{staticStyle:{width:"100%"},attrs:{small:""},on:{click:e.doZtilt}},[e._v("Z-Tilt Adjust")])],1):e._e(),e.controlStyle!=="bars"&&e.existsQGL&&e.actionButton!=="qgl"?t(J,[t(g,{staticStyle:{width:"100%"},attrs:{small:""},on:{click:e.doQGL}},[e._v("Quad Gantry Level")])],1):e._e(),e.existsBedTilt?t(J,[t(g,{staticStyle:{width:"100%"},attrs:{small:""},on:{click:function(r){return e.doSend("BED_TILT_CALIBRATE")}}},[e._v(" BED TILT CALIBRATE ")])],1):e._e(),e.existsBedScrews?t(J,[t(g,{staticStyle:{width:"100%"},attrs:{small:""},on:{click:function(r){return e.doSend("BED_SCREWS_ADJUST")}}},[e._v("BED SCREWS ADJUST")])],1):e._e(),e.existsDeltaCalibrate?t(J,[t(g,{staticStyle:{width:"100%"},attrs:{small:""},on:{click:function(r){return e.doSend("DELTA_CALIBRATE")}}},[e._v("DELTA CALIBRATE")])],1):e._e(),e.existsScrewsTilt?t(J,[t("div",{staticClass:"d-flex align-center",staticStyle:{width:"100%"}},[t(g,{staticStyle:{"border-top-right-radius":"0","border-bottom-right-radius":"0"},attrs:{small:""},on:{click:function(r){return e.doSend("SCREWS_TILT_CALCULATE")}}},[e._v(" SCREWS TILT CALCULATE ")]),t(ye,{attrs:{"offset-y":"",left:"","close-on-content-click":!1},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"px-0",staticStyle:{"min-width":"32px","border-top-left-radius":"0","border-bottom-left-radius":"0"},attrs:{small:""}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiMenuDown))])],1)]}}],null,!1,274928364)},[t(Me,{attrs:{dense:""}},[t(J,[t(g,{staticStyle:{width:"100%"},attrs:{small:""},on:{click:function(r){return e.doSend("SCREWS_TILT_CALCULATE DIRECTION=CW")}}},[t(_,{staticStyle:{transform:"scaleX(-1)"},attrs:{left:"",small:""}},[e._v(e._s(e.mdiRestore))]),t("span",[e._v("CW")])],1)],1),t(J,[t(g,{staticStyle:{width:"100%"},attrs:{small:""},on:{click:function(r){return e.doSend("SCREWS_TILT_CALCULATE DIRECTION=CCW")}}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiRestore))]),t("span",[e._v("CCW")])],1)],1)],1)],1)],1)]):e._e()],1)],1):e._e(),t(kA)]},proxy:!0}],null,!1,2619595342)},[t(G0),e.axisControlVisible?t(Ee,[t("".concat(e.controlStyle,"-control"),{tag:"component"})],1):e._e(),e.showZOffset?t(I):e._e(),e.showZOffset?t(Ee,[t(z0)],1):e._e(),e.showSpeedFactor?t(I):e._e(),e.showSpeedFactor?t(Ee,[t(Fu,{attrs:{label:e.$t("Panels.ToolheadControlPanel.SpeedFactor"),icon:e.mdiSpeedometer,target:e.speedFactor,min:1,max:200,multi:100,step:5,"dynamic-range":!0,"has-input-field":!0,command:"M220","attribute-name":"S"}})],1):e._e()],1):e._e()},QA=[],eF=E(wh,KA,QA,!1,null,null);const tF=eF.exports;var sF=Object.defineProperty,rF=Object.getOwnPropertyDescriptor,Ef=(s,e,t,r)=>{for(var i=r>1?void 0:r?rF(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&sF(e,t,i),i};let va=class extends k(L,vt){constructor(){super(...arguments),this.hoverChart=!1,this.isVisible=!0}get chartOptions(){return{renderer:"svg",animation:!1,tooltip:this.tooltip,grid:{top:35,right:this.gridRight,bottom:30,left:25},legend:{animation:!1,show:!1,selected:this.selectedLegends},xAxis:{type:"time",splitNumber:5,minInterval:60*1e3,splitLine:{show:!0,lineStyle:{color:this.fgColorFaint}},axisLabel:{color:this.fgColorLow,margin:10,formatter:this.timeFormat}},yAxis:this.yAxis,media:this.media,dataset:{source:[]},series:this.series}}get tooltip(){return{animation:!1,trigger:"axis",backgroundColor:this.bgColor(1),borderWidth:0,textStyle:{color:this.fgColorHi,fontSize:"14px"},padding:15,formatter:this.tooltipFormatter,confine:!0,className:"echarts-tooltip",position:function(s,e,t,r,i){const n={top:60};return n[["left","right"][+(s[0]<i.viewSize[0]/2)]]=5,n}}}get yAxis(){return[{name:this.$t("Panels.TemperaturePanel.TemperaturesInChart"),type:"value",min:0,max:s=>this.autoscale?Math.ceil((s.max+5)/20)*20:this.maxTemp,minInterval:20,maxInterval:100,nameLocation:"end",nameGap:5,nameTextStyle:{color:this.fgColorMid,align:"left"},splitLine:{lineStyle:{color:this.fgColorFaint}},axisLabel:{color:this.fgColorMid,formatter:"{value}",rotate:90,showMinLabel:!0,margin:5},axisLine:{show:!0,lineStyle:{color:this.fgColorLow}}},{show:this.boolDisplayPwmAxis,name:"PWM [%]",min:0,max:1,minInterval:.25,type:"value",nameLocation:"end",nameGap:5,nameTextStyle:{color:this.fgColorMid,align:"right"},splitLine:{show:!1},axisLabel:{color:this.fgColorMid,formatter:s=>s*100,showMinLabel:!0,rotate:90,margin:5},axisLine:{show:!0,lineStyle:{color:this.fgColorLow}}}]}get media(){return[{query:{minWidth:500},option:{grid:{right:this.optionGridRight,left:40},yAxis:[{maxInterval:50,axisLabel:{showMinLabel:!1,showMaxLabel:!0,rotate:0}},{maxInterval:25,axisLabel:{showMinLabel:!1,rotate:0}}]}}]}get chart(){var s,e;return(e=(s=this.$refs.tempchart)==null?void 0:s.chart)!=null?e:null}get maxHistory(){return this.$store.getters["printer/tempHistory/getTemperatureStoreSize"]}get series(){var s;return(s=this.$store.state.printer.tempHistory.series)!=null?s:{}}get source(){var s;return(s=this.$store.state.printer.tempHistory.source)!=null?s:[]}get autoscale(){var s;return(s=this.$store.state.gui.view.tempchart.autoscale)!=null?s:!0}get maxTemp(){var s;return(s=this.$store.getters["printer/getMaxTemp"])!=null?s:300}get boolDisplayPwmAxis(){return this.$store.getters["printer/tempHistory/getBoolDisplayPwmAxis"]}get selectedLegends(){return this.$store.getters["printer/tempHistory/getSelectedLegends"]}get timeFormat(){return this.hours12Format?"{hh}:{mm}":"{HH}:{mm}"}get tempchartHeight(){var s;return(s=this.$store.state.gui.uiSettings.tempchartHeight)!=null?s:250}get tempchartStyle(){return{height:this.tempchartHeight+"px"}}get gridRight(){return this.boolDisplayPwmAxis?25:15}get optionGridRight(){return this.boolDisplayPwmAxis?35:15}beforeDestroy(){typeof window>"u"||this.chart&&this.chart.dispose()}visibilityChanged(s){this.isVisible=s}tooltipFormatter(s){let e="";const t=s.filter(r=>r.seriesName.endsWith("-temperature"));if(s.length){let r=s[0].axisValueLabel;r=r.substring(r.indexOf(" "));const i=this.$vuetify.theme.dark?"theme-dark":"";e+='<div class="row"><div class="col py-1" style=\'border-bottom: 1px solid rgba(255, 255, 255, 0.24);\'><span class="v-icon mdi '.concat(i,'" style="margin-right: 5px;"><svg xmlns="http://www.w3.org/2000/svg" role="img" aria-hidden="true" viewBox="0 0 24 24" class="v-icon__svg" style="font-size: 12px; width: 12px; height: 12px;"><path d="').concat(Ow,'"></path></svg></span><span class="font-weight-bold">')+r+"</span></div></div>"}return t.forEach(r=>{const i=r.seriesName.substring(0,r.seriesName.lastIndexOf("-"));let n=i;n.indexOf(" ")!==-1&&(n=n.substring(n.indexOf(" ")+1)),e+='<div class="row">',e+='<div class="col-auto py-0">',e+=r.marker,e+="<span class='ml-2'>"+Ye(n)+":</span>",e+="</div>",e+='<div class="col text-right py-0 font-weight-bold">';const a="".concat(i,"-temperature"),o="".concat(i,"-target");if(a in r.value){const l=r.value[a];e+=l!==null?l.toFixed(1):"--"}if(o in r.value){e+=" / ";const l=r.value[o];e+=l!==null?l.toFixed(1):"--"}e+="°C",Xn.forEach(l=>{const u="".concat(i,"-").concat(l);if(!(u in r.value))return;let c=r.value[u];c=c!==null?(r.value[u]*100).toFixed(0):"--",e+=" [ ".concat(c,"% ]")}),e+="</div>",e+="</div>"}),e}selectedLegendsChanged(s){var e,t;((e=this.chart)==null?void 0:e.isDisposed())!==!0&&((t=this.chart)==null||t.setOption({legend:{selected:s}}))}sourceChanged(s){var r;if(!this.chart||!this.isVisible||this.hoverChart)return;(r=this.chart)==null||r.setOption({dataset:{source:s}});const e=new Date(Date.now()-this.maxHistory*1e3);let t=s.filter(i=>i.date>=e);s.length>0&&t.length<this.maxHistory*.8&&this.$socket.emit("server.temperature_store",{include_monitors:!0},{action:"printer/tempHistory/init"})}};Ef([he("selectedLegends")],va.prototype,"selectedLegendsChanged",1);Ef([he("source")],va.prototype,"sourceChanged",1);va=Ef([S({components:{}})],va);var iF=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("e-chart",{directives:[{name:"observe-visibility",rawName:"v-observe-visibility",value:e.visibilityChanged,expression:"visibilityChanged"}],ref:"tempchart",staticClass:"tempchart",style:e.tempchartStyle,attrs:{option:e.chartOptions,"init-options":{renderer:"svg"},autoresize:!0},nativeOn:{mouseenter:function(r){e.hoverChart=!0},mouseleave:function(r){e.hoverChart=!1}}})},nF=[],aF=E(va,iF,nF,!1,null,"017bae86");const Z0=aF.exports;var oF=Object.defineProperty,lF=Object.getOwnPropertyDescriptor,Lf=(s,e,t,r)=>{for(var i=r>1?void 0:r?lF(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&oF(e,t,i),i};let ba=class extends k(L){get value(){return this.$store.getters["gui/getDatasetAdditionalSensorValue"]({name:this.objectName,type:this.additionalSensor})}set value(s){this.$store.dispatch("gui/setDatasetAdditionalSensorStatus",{objectName:this.objectName,dataset:this.additionalSensor,value:s})}get label(){return this.$t("Panels.TemperaturePanel.ShowNameInList",{name:this.additionalSensor})}};Lf([w({type:String,required:!0})],ba.prototype,"objectName",2);Lf([w({type:String,required:!0})],ba.prototype,"additionalSensor",2);ba=Lf([S],ba);var cF=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,[t(b,{staticClass:"col-12 py-1"},[t(ge,{staticClass:"mt-0",attrs:{label:e.label,"hide-details":""},model:{value:e.value,callback:function(r){e.value=r},expression:"value"}})],1)],1)},uF=[],dF=E(ba,cF,uF,!1,null,null);const q0=dF.exports;var mF=Object.defineProperty,hF=Object.getOwnPropertyDescriptor,Af=(s,e,t,r)=>{for(var i=r>1?void 0:r?hF(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&mF(e,t,i),i};let ya=class extends k(L){get value(){return this.$store.getters["gui/getDatasetValue"]({name:this.objectName,type:this.serieName})}get label(){return this.$t("Panels.TemperaturePanel.ShowNameInChart",{name:this.formatSerieName})}set value(s){this.$store.dispatch("gui/setChartDatasetStatus",{objectName:this.objectName,dataset:this.serieName,value:s})}get formatSerieName(){return lr(this.serieName)}};Af([w({type:String,required:!0})],ya.prototype,"objectName",2);Af([w({type:String,required:!0})],ya.prototype,"serieName",2);ya=Af([S],ya);var pF=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,[t(b,{staticClass:"py-1"},[t(ge,{staticClass:"mt-0",attrs:{label:e.label,"hide-details":""},model:{value:e.value,callback:function(r){e.value=r},expression:"value"}})],1)],1)},fF=[],gF=E(ya,pF,fF,!1,null,null);const X0=gF.exports;var _F=Object.defineProperty,vF=Object.getOwnPropertyDescriptor,zs=(s,e,t,r)=>{for(var i=r>1?void 0:r?vF(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&_F(e,t,i),i};let ms=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe}get chartSeries(){var s;return(s=this.$store.getters["printer/tempHistory/getSerieNames"](this.objectName))!=null?s:[]}get printerObjectAdditionalSensor(){return this.additionalSensorName===null||!(this.additionalSensorName in this.$store.state.printer)?{}:this.$store.state.printer[this.additionalSensorName]}get additionalValues(){return this.objectName==="z_thermal_adjust"?["current_z_adjust"]:this.objectName.startsWith("nevermore")?["temperature","pressure","humidity","rpm"]:Object.keys(this.printerObjectAdditionalSensor).filter(s=>s!=="temperature")}setChartColor(s){typeof s=="object"&&"hex"in s&&(s=s.hex),this.$store.dispatch("gui/setChartColor",{objectName:this.objectName,value:s}),this.$store.dispatch("printer/tempHistory/setColor",{name:this.objectName,value:s})}closeDialog(){this.$emit("close-dialog")}};zs([w({type:Boolean,required:!0})],ms.prototype,"boolShow",2);zs([w({type:String,required:!0})],ms.prototype,"objectName",2);zs([w({type:String,required:!0})],ms.prototype,"name",2);zs([w({required:!0})],ms.prototype,"additionalSensorName",2);zs([w({type:String,required:!0})],ms.prototype,"formatName",2);zs([w({type:String,required:!0})],ms.prototype,"icon",2);zs([w({type:String,required:!0})],ms.prototype,"color",2);zs([Ke(500)],ms.prototype,"setChartColor",1);ms=zs([S({components:{TemperaturePanelListItemEditAdditionalSensor:q0,TemperaturePanelListItemEditChartSerie:X0}})],ms);var bF=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{persistent:"",width:400},model:{value:e.boolShow,callback:function(r){e.boolShow=r},expression:"boolShow"}},[t(U,{attrs:{title:e.formatName,icon:e.icon,"card-class":"temperature-edit-heater-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{staticClass:"pt-6"},[e._l(e.chartSeries,function(r){return t(X0,{key:r,attrs:{"object-name":e.objectName,"serie-name":r}})}),e._l(e.additionalValues,function(r){return t(q0,{key:r,attrs:{"object-name":e.objectName,"additional-sensor":r}})}),t(x,[t(b,{staticClass:"col-12 text-center pb-0"},[t(Xt,{staticClass:"mx-auto",attrs:{"hide-mode-switch":"",mode:"hexa",value:e.color},on:{"update:color":e.setChartColor}})],1)],1)],2)],1)],1)},yF=[],CF=E(ms,bF,yF,!1,null,null);const Y0=CF.exports;var $F=Object.defineProperty,xF=Object.getOwnPropertyDescriptor,Gs=(s,e,t,r)=>{for(var i=r>1?void 0:r?xF(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&$F(e,t,i),i};let hs=class extends k(L,Je){constructor(){super(...arguments),this.mdiSnowflake=bu,this.mdiFire=sn,this.mdiMenuDown=gr,this.value=0}setTemps(){var e;if(typeof this.value=="object"&&(this.value=(e=this.value.value)!=null?e:0),this.value===null&&(this.value=0),this.value>this.max_temp)this.value={value:this.target,text:this.target},this.$toast.error(this.$t("Panels.TemperaturePanel.TempTooHigh",{name:this.name,max:this.max_temp})+"");else if(this.value<this.min_temp&&this.value!=0)this.value={value:this.target,text:this.target},this.$toast.error(this.$t("Panels.TemperaturePanel.TempTooLow",{name:this.name,min:this.min_temp})+"");else if(this.target!==parseFloat(this.value)){const t=this.command+" "+this.attributeName+"="+this.name+" TARGET="+this.value;this.$store.dispatch("server/addEvent",{message:t,type:"command"}),this.$socket.emit("printer.gcode.script",{script:t})}}mounted(){this.value=this.target}targetChanged(e){this.value=e}};Gs([w({type:String,required:!0})],hs.prototype,"name",2);Gs([w({type:Number,required:!0,default:0})],hs.prototype,"target",2);Gs([w({type:Number,required:!0})],hs.prototype,"min_temp",2);Gs([w({type:Number,required:!0})],hs.prototype,"max_temp",2);Gs([w({type:String,required:!0})],hs.prototype,"command",2);Gs([w({type:String,required:!0})],hs.prototype,"attributeName",2);Gs([w({type:Array,default:[]})],hs.prototype,"presets",2);Gs([he("target")],hs.prototype,"targetChanged",1);hs=Gs([S],hs);var wF=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",{staticClass:"d-flex align-center"},[t("form",{on:{submit:function(r){return r.preventDefault(),e.setTemps.apply(null,arguments)}}},[t(se,{staticClass:"_temp-input pr-1",attrs:{suffix:"°C",type:"number",dense:"",outlined:"","hide-details":"","hide-spin-buttons":""},on:{blur:function(r){e.value=e.target},focus:function(r){return r.target.select()}},model:{value:e.value,callback:function(r){e.value=r},expression:"value"}})],1),e.presets?t(ye,{attrs:{"offset-y":!0,left:"",title:"Preheat"},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"pa-0",staticStyle:{"min-width":"24px"},attrs:{disabled:["printing","paused"].includes(e.printer_state),tabindex:"-1","x-small":"",plain:""}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiMenuDown))])],1)]}}],null,!1,165235721)},[t(Me,{staticClass:"py-0",attrs:{dense:""}},e._l(e.presets,function(r){return t(J,{key:r.index,staticStyle:{"min-height":"32px"},attrs:{link:""},on:{click:function(i){return e.doSend("".concat(e.command," ").concat(e.attributeName,"=").concat(e.name," TARGET=").concat(r.value))}}},[t("div",{staticClass:"_preset"},[r.value===0?t(_,{staticClass:"_preset-icon",attrs:{else:"",color:"primary",small:""}},[e._v(" "+e._s(e.mdiSnowflake)+" ")]):t(_,{staticClass:"_preset-icon",attrs:{small:""}},[e._v(e._s(e.mdiFire))]),t("span",{staticStyle:{"padding-top":"2px"}},[e._v(e._s(r.value)+"°C")])],1)])}),1)],1):e._e()],1)},SF=[],PF=E(hs,wF,SF,!1,null,"5e992cba");const J0=PF.exports;var DF=Object.defineProperty,TF=Object.getOwnPropertyDescriptor,zu=(s,e,t,r)=>{for(var i=r>1?void 0:r?TF(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&DF(e,t,i),i};let Ii=class extends k(L){get value(){var e;const s=(e=this.printerObject[this.keyName])!=null?e:null;return isNaN(s)?null:s}get formatValue(){var t;let s=(t=this.value)==null?void 0:t.toFixed(1);this.value===null&&(s="--");let e=null;switch(this.keyName){case"pressure":e="hPa";break;case"humidity":e="%";break;case"current_z_adjust":e="mm";break}return this.keyName==="current_z_adjust"&&this.value&&(s=this.value.toFixed(3),Math.abs(this.value)<.1&&(s=Math.round(this.value*1e3).toString(),e="μm")),e?"".concat(s," ").concat(e):s}get guiSetting(){return this.$store.getters["gui/getDatasetAdditionalSensorValue"]({name:this.objectName,sensor:this.keyName})}get isVisible(){return this.value===null?!1:this.guiSetting}};zu([w({type:Object,required:!0})],Ii.prototype,"printerObject",2);zu([w({type:String,required:!0})],Ii.prototype,"objectName",2);zu([w({type:String,required:!0})],Ii.prototype,"keyName",2);Ii=zu([S],Ii);var OF=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.isVisible?t("div",[t("small",[e._v(e._s(e.formatValue))])]):e._e()},MF=[],kF=E(Ii,OF,MF,!1,null,null);const EF=kF.exports;var LF=Object.defineProperty,AF=Object.getOwnPropertyDescriptor,Ff=(s,e,t,r)=>{for(var i=r>1?void 0:r?AF(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&LF(e,t,i),i};let Ca=class extends k(L){get printerObject(){return this.additionalObjectName in this.$store.state.printer?this.$store.state.printer[this.additionalObjectName]:{}}get additionalValues(){return this.objectName==="z_thermal_adjust"?["current_z_adjust"]:Object.keys(this.printerObject).filter(s=>s!=="temperature")}};Ff([w({type:String,required:!0})],Ca.prototype,"objectName",2);Ff([w({type:String,required:!0})],Ca.prototype,"additionalObjectName",2);Ca=Ff([S],Ca);var FF=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",e._l(e.additionalValues,function(r){return t(EF,{key:r,attrs:{"printer-object":e.printerObject,"object-name":e.objectName,"key-name":r}})}),1)},RF=[],HF=E(Ca,FF,RF,!1,null,null);const jF=HF.exports,zd=new y,Gd="close-temperature-context-menu";var IF=Object.defineProperty,NF=Object.getOwnPropertyDescriptor,Rf=(s,e,t,r)=>{for(var i=r>1?void 0:r?NF(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&IF(e,t,i),i};let $a=class extends k(L){constructor(){super(...arguments),this.mdiCog=ss,this.mdiSnowflake=bu,this.showEditDialog=!1,this.showContextMenu=!1,this.contextMenuX=0,this.contextMenuY=0}get printerObject(){return this.objectName in this.$store.state.printer?this.$store.state.printer[this.objectName]:{}}get printerObjectSettings(){var e,t,r,i,n;const s=this.objectName.toLowerCase();return s in((r=(t=(e=this.$store.state.printer)==null?void 0:e.configfile)==null?void 0:t.settings)!=null?r:{})?(n=(i=this.$store.state.printer)==null?void 0:i.configfile)==null?void 0:n.settings[s]:{}}get name(){const s=this.objectName.split(" ");return s.length===1?this.objectName:s[1]}get formatName(){return Ye(this.name)}get icon(){var s;return this.objectName.startsWith("extruder")?(s=this.printerObject.can_extrude)!=null&&s?Us:vv:this.objectName==="heater_bed"?this.temperature!==null&&this.temperature>50||this.target&&this.temperature&&this.temperature>this.target-5?gS:yv:this.objectName.startsWith("heater_generic")?sn:this.objectName.startsWith("tmc")?dv:this.isFan?Ip:fi}get color(){var s;return(s=this.$store.getters["printer/tempHistory/getDatasetColor"](this.objectName))!=null?s:"#FFFFFF"}get iconColor(){return this.target===null||this.target>0?"".concat(this.color).concat(N_):"".concat(this.color).concat(V_)}get iconClass(){var e,t,r;const s=["_no-focus-style","cursor-pointer"];return this.isFan&&!((t=(e=this.$store.state.gui)==null?void 0:e.uiSettings.disableFanAnimation)!=null&&t)&&((r=this.state)!=null?r:0)>0&&s.push("icon-rotate"),s}get isFan(){return this.objectName.startsWith("temperature_fan")}get state(){var s,e;return(e=(s=this.printerObject.power)!=null?s:this.printerObject.speed)!=null?e:null}get formatState(){return this.state===null?null:this.target===0&&this.state===0?"off":"".concat(Math.round(this.state*100)," %")}get avgPower(){var s;return(s=this.$store.getters["printer/tempHistory/getAvgPower"](this.name))!=null?s:0}get avgSpeed(){var s;return(s=this.$store.getters["printer/tempHistory/getAvgSpeed"](this.name))!=null?s:0}get avgState(){return"power"in this.printerObject?Math.round(this.avgPower):"speed"in this.printerObject?Math.round(this.avgSpeed):null}get temperature(){var s,e;return(e=(s=this.printerObject)==null?void 0:s.temperature)!=null?e:null}get formatTemperature(){var s,e;return"".concat((e=(s=this.temperature)==null?void 0:s.toFixed(1))!=null?e:"--","°C")}get min_temp(){var s;return parseInt((s=this.printerObjectSettings.min_temp)!=null?s:0)}get max_temp(){var s;return parseInt((s=this.printerObjectSettings.max_temp)!=null?s:0)}get measured_min_temp(){var s,e,t;return(t=(e=(s=this.printerObject)==null?void 0:s.measured_min_temp)==null?void 0:e.toFixed(1))!=null?t:null}get measured_max_temp(){var s,e,t;return(t=(e=(s=this.printerObject)==null?void 0:s.measured_max_temp)==null?void 0:e.toFixed(1))!=null?t:null}get target(){var s,e;return(e=(s=this.printerObject)==null?void 0:s.target)!=null?e:null}get additionalSensorName(){if(this.objectName==="z_thermal_adjust")return"z_thermal_adjust";const s=Kx.find(e=>{if("".concat(e," ").concat(this.name)in this.$store.state.printer)return!0});return s?"".concat(s," ").concat(this.name):null}get rpm(){var e;return((e=this.printerObject.rpm)!=null?e:null)===null?null:parseInt(this.printerObject.rpm)}get rpmClass(){var s;return this.rpm===0&&((s=this.printerObject.speed)!=null?s:0)>0?"red--text":""}get presets(){var s;return(s=this.$store.getters["gui/presets/getPresetsFromHeater"]({name:this.objectName}))!=null?s:[]}get command(){return this.objectName.startsWith("temperature_fan")?"SET_TEMPERATURE_FAN_TARGET":this.objectName.startsWith("extruder")||this.objectName.startsWith("heater_")?"SET_HEATER_TEMPERATURE":null}get commandAttributeName(){return this.command==="SET_HEATER_TEMPERATURE"?"HEATER":this.command==="SET_TEMPERATURE_FAN_TARGET"?"TEMPERATURE_FAN":""}get availableHeaters(){var s,e;return(e=(s=this.$store.state.printer.heaters)==null?void 0:s.available_heaters)!=null?e:[]}get isHeater(){return this.availableHeaters.includes(this.objectName)}get isHeaterActive(){return this.target>0}mounted(){zd.$on(Gd,this.closeContextMenu)}beforeDestroy(){zd.$off(Gd,this.closeContextMenu)}openContextMenu(s){zd.$emit(Gd),this.showContextMenu=!0,this.contextMenuX=(s==null?void 0:s.clientX)||(s==null?void 0:s.pageX)||window.screenX/2,this.contextMenuY=(s==null?void 0:s.clientY)||(s==null?void 0:s.pageY)||window.screenY/2}closeContextMenu(){this.showContextMenu=!1}openEditDialog(){this.closeContextMenu(),this.showEditDialog=!0}turnOffHeater(){const s="SET_HEATER_TEMPERATURE HEATER=".concat(this.name," TARGET=0");this.$store.dispatch("server/addEvent",{message:s,type:"command"}),this.$socket.emit("printer.gcode.script",{script:s})}};Rf([w({type:String,required:!0})],$a.prototype,"objectName",2);Rf([w({type:Boolean,required:!0})],$a.prototype,"isResponsiveMobile",2);$a=Rf([S],$a);var VF=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("tr",{directives:[{name:"longpress",rawName:"v-longpress:600",value:r=>e.openContextMenu(r),expression:"(e) => openContextMenu(e)",arg:"600"}],on:{contextmenu:function(r){return r.preventDefault(),e.openContextMenu(r)}}},[t("td",{staticClass:"icon"},[t(_,{class:e.iconClass,attrs:{color:e.iconColor,tabindex:"-1"},on:{click:e.openEditDialog}},[e._v(" "+e._s(e.icon)+" ")])],1),t("td",{staticClass:"name"},[t("span",{staticClass:"cursor-pointer",on:{click:e.openEditDialog}},[e._v(e._s(e.formatName))])]),e.isResponsiveMobile?e._e():t("td",{staticClass:"state"},[e.state!==null?t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("div",e._g(e._b({},"div",i,!1),r),[e._v(e._s(e.formatState))])]}}],null,!1,938967334)},[t("span",[e._v(e._s(e.$t("Panels.TemperaturePanel.Avg"))+": "+e._s(e.avgState)+" %")])]):e._e()],1),t("td",{staticClass:"current"},[t(de,{attrs:{top:"",disabled:!(e.measured_min_temp!==null||e.measured_max_temp!==null)},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("span",e._g(e._b({staticStyle:{cursor:"default"}},"span",i,!1),r),[e._v(" "+e._s(e.formatTemperature)+" ")])]}}])},[t("span",[e._v(" "+e._s(e.$t("Panels.TemperaturePanel.Max"))+": "+e._s(e.measured_max_temp)+"°C "),t("br"),e._v(" "+e._s(e.$t("Panels.TemperaturePanel.Min"))+": "+e._s(e.measured_min_temp)+"°C ")])]),e.rpm!==null?t("div",[t("small",{class:e.rpmClass},[e._v(e._s(e.rpm)+" RPM")])]):e._e(),e.additionalSensorName?t(jF,{attrs:{"object-name":e.objectName,"additional-object-name":e.additionalSensorName}}):e._e()],1),t("td",{staticClass:"target"},[e.command!==null?t(J0,{attrs:{name:e.name,target:e.target,presets:e.presets,min_temp:e.min_temp,max_temp:e.max_temp,command:e.command,"attribute-name":e.commandAttributeName}}):e._e()],1),t(Y0,{attrs:{"bool-show":e.showEditDialog,"object-name":e.objectName,name:e.name,"format-name":e.formatName,"additional-sensor-name":e.additionalSensorName,icon:e.icon,color:e.color},on:{"close-dialog":function(r){e.showEditDialog=!1}}}),t(ye,{attrs:{"position-x":e.contextMenuX,"position-y":e.contextMenuY,absolute:"","offset-y":""},model:{value:e.showContextMenu,callback:function(r){e.showContextMenu=r},expression:"showContextMenu"}},[t(Me,[e.isHeater?t(J,{attrs:{disabled:!e.isHeaterActive},on:{click:e.turnOffHeater}},[t(_,{attrs:{left:""}},[e._v(e._s(e.mdiSnowflake))]),e._v(" "+e._s(e.$t("Panels.TemperaturePanel.TurnHeaterOff"))+" ")],1):e._e(),t(J,{on:{click:e.openEditDialog}},[t(_,{attrs:{left:""}},[e._v(e._s(e.mdiCog))]),e._v(" "+e._s(e.$t("Panels.TemperaturePanel.Settings"))+" ")],1)],1)],1)],1)},BF=[],UF=E($a,VF,BF,!1,null,"420c2d54");const Zd=UF.exports;var WF=Object.defineProperty,zF=Object.getOwnPropertyDescriptor,ao=(s,e,t,r)=>{for(var i=r>1?void 0:r?zF(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&WF(e,t,i),i};let qr=class extends k(L){get cssStyle(){let s={cursor:"default",fontSize:"1em"};return this.small&&(s.fontSize="0.8em"),s}get value(){var e;const s=(e=this.printerObject[this.keyName])!=null?e:null;return isNaN(s)?null:s}get intake_value(){var e;const s="intake_".concat(this.keyName);return(e=this.printerObject[s])!=null?e:null}get intake_value_min(){var e;const s="intake_".concat(this.keyName,"_min");return(e=this.printerObject[s])!=null?e:null}get intake_value_max(){var e;const s="intake_".concat(this.keyName,"_max");return(e=this.printerObject[s])!=null?e:null}get exhaust_value(){var e;const s="exhaust_".concat(this.keyName);return(e=this.printerObject[s])!=null?e:null}get exhaust_value_min(){var e;const s="exhaust_".concat(this.keyName,"_min");return(e=this.printerObject[s])!=null?e:null}get exhaust_value_max(){var e;const s="exhaust_".concat(this.keyName,"_max");return(e=this.printerObject[s])!=null?e:null}get unit(){switch(this.keyName){case"temperature":return"°C";case"pressure":return"hPa";case"humidity":return"%"}return null}get digits(){return["gas","pressure"].includes(this.keyName)?0:1}get formatValue(){return this.getFormatedValue(this.intake_value,this.exhaust_value)}get formatValue_min(){return this.getFormatedValue(this.intake_value_min,this.exhaust_value_min)}get formatValue_max(){return this.getFormatedValue(this.intake_value_max,this.exhaust_value_max)}getFormatedValue(s,e){let t=s==null?void 0:s.toFixed(this.digits),r=e==null?void 0:e.toFixed(this.digits);return this.intake_value===null&&(t="--"),this.exhaust_value===null&&(r="--"),this.unit===null?"".concat(t," > ").concat(r):"".concat(t," ").concat(this.unit," > ").concat(r," ").concat(this.unit)}get disableTooltip(){return this.intake_value_min===null||this.exhaust_value_min===null||this.intake_value_max===null||this.exhaust_value_max===null}get guiSetting(){return this.$store.getters["gui/getDatasetAdditionalSensorValue"]({name:this.objectName,sensor:this.keyName})}get isVisible(){return this.intake_value===null&&this.exhaust_value===null?!1:this.guiSetting}};ao([w({type:Object,required:!0})],qr.prototype,"printerObject",2);ao([w({type:String,required:!0})],qr.prototype,"objectName",2);ao([w({type:String,required:!0})],qr.prototype,"keyName",2);ao([w({type:Boolean,required:!1,default:!0})],qr.prototype,"small",2);qr=ao([S],qr);var GF=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.isVisible?t("div",[t(de,{attrs:{top:"",disabled:e.disableTooltip},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("span",e._g(e._b({style:e.cssStyle},"span",i,!1),r),[e._v(e._s(e.formatValue))])]}}],null,!1,2376366562)},[t("span",[e._v(" "+e._s(e.$t("Panels.TemperaturePanel.Max"))+": "+e._s(e.formatValue_max)+" "),t("br"),e._v(" "+e._s(e.$t("Panels.TemperaturePanel.Min"))+": "+e._s(e.formatValue_min)+" ")])])],1):e._e()},ZF=[],qF=E(qr,GF,ZF,!1,null,null);const u1=qF.exports;var XF=Object.defineProperty,YF=Object.getOwnPropertyDescriptor,Hf=(s,e,t,r)=>{for(var i=r>1?void 0:r?YF(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&XF(e,t,i),i};let xa=class extends k(L){constructor(){super(...arguments),this.mdiFan=Ip,this.showEditDialog=!1,this.nevermoreValues=["temperature","pressure","humidity"]}get printerObject(){var s;return(s=this.$store.state.printer[this.objectName])!=null?s:{}}get name(){const s=this.objectName.split(" ");return s.length===1?s[0]:s[1]}get formatName(){return Ye(this.name)}get color(){var s,e,t,r,i,n;return(n=(i=(r=(t=(e=(s=this.$store.state.gui)==null?void 0:s.view)==null?void 0:e.tempchart)==null?void 0:t.datasetSettings)==null?void 0:r[this.objectName])==null?void 0:i.color)!=null?n:"#ffffff"}get iconColor(){return this.state===null||this.state>0?"".concat(this.color).concat(N_):"".concat(this.color).concat(V_)}get iconClass(){var t,r,i;const s=["_no-focus-style","cursor-pointer"];return!((r=(t=this.$store.state.gui)==null?void 0:t.uiSettings.disableFanAnimation)!=null?r:!1)&&((i=this.state)!=null?i:0)>0&&s.push("icon-rotate"),s}get state(){var s;return(s=this.printerObject.speed)!=null?s:null}get rpm(){var e;return((e=this.printerObject.rpm)!=null?e:null)===null?null:parseInt(this.printerObject.rpm)}get rpmClass(){var s;return this.rpm===0&&((s=this.printerObject.speed)!=null?s:0)>0?"red--text":""}};Hf([w({type:String,required:!0})],xa.prototype,"objectName",2);Hf([w({type:Boolean,required:!0})],xa.prototype,"isResponsiveMobile",2);xa=Hf([S],xa);var JF=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("tr",[t("td",{staticClass:"icon"},[t(_,{class:e.iconClass,attrs:{color:e.iconColor,tabindex:"-1"},on:{click:function(r){e.showEditDialog=!0}}},[e._v(" "+e._s(e.mdiFan)+" ")])],1),t("td",{staticClass:"name"},[t("span",{staticClass:"cursor-pointer",on:{click:function(r){e.showEditDialog=!0}}},[e._v(e._s(e.formatName))])]),t("td",{staticClass:"text-no-wrap text-center",attrs:{colspan:"3"}},[t(u1,{attrs:{"printer-object":e.printerObject,"object-name":e.objectName,small:!1,"key-name":"gas"}}),e._l(e.nevermoreValues,function(r){return t(u1,{key:r,attrs:{"printer-object":e.printerObject,"object-name":e.objectName,"key-name":r}})}),e.rpm!==null?t("div",[t("small",{class:e.rpmClass},[e._v(e._s(e.rpm)+" RPM")])]):e._e()],2),t(Y0,{attrs:{"bool-show":e.showEditDialog,"object-name":e.objectName,name:e.name,"format-name":e.formatName,"additional-sensor-name":"nevermore",icon:e.mdiFan,color:e.color},on:{"close-dialog":function(r){e.showEditDialog=!1}}})],1)},KF=[],QF=E(xa,JF,KF,!1,null,"ca9b3c12");const K0=QF.exports;var eR=Object.getOwnPropertyDescriptor,tR=(s,e,t,r)=>{for(var i=r>1?void 0:r?eR(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Sh=class extends k(L){get available_heaters(){var s,e,t;return(t=(e=(s=this.$store.state.printer)==null?void 0:s.heaters)==null?void 0:e.available_heaters)!=null?t:[]}get filteredHeaters(){return this.filterNamesAndSort(this.available_heaters)}get available_sensors(){var s,e,t;return(t=(e=(s=this.$store.state.printer)==null?void 0:s.heaters)==null?void 0:e.available_sensors)!=null?t:[]}get available_monitors(){var s,e,t;return(t=(e=(s=this.$store.state.printer)==null?void 0:s.heaters)==null?void 0:e.available_monitors)!=null?t:[]}get available_nevermores(){return Object.keys(this.$store.state.printer).filter(s=>s.startsWith("nevermore"))}get monitors(){return this.available_monitors.sort(this.sortObjectName)}get temperature_fans(){return this.available_sensors.filter(s=>s.startsWith("temperature_fan")&&!s.startsWith("temperature_fan _")).sort(this.sortObjectName)}get hideMcuHostSensors(){var s;return(s=this.$store.state.gui.view.tempchart.hideMcuHostSensors)!=null?s:!1}get hideMonitors(){var s;return(s=this.$store.state.gui.view.tempchart.hideMonitors)!=null?s:!1}get temperature_sensors(){return this.filterNamesAndSort(this.available_sensors).filter(s=>!(this.available_heaters.includes(s)||this.temperature_fans.includes(s)||this.hideMcuHostSensors&&this.checkMcuHostSensor(s)))}get heaterObjects(){return[...this.filteredHeaters,...this.temperature_fans]}get nevermoreObjects(){return this.filterNamesAndSort(this.available_nevermores)}get settings(){var s,e,t;return(t=(e=(s=this.$store.state.printer)==null?void 0:s.configfile)==null?void 0:e.settings)!=null?t:{}}checkMcuHostSensor(s){var r,i;const t=(i=((r=this.settings[s.toLowerCase()])!=null?r:{}).sensor_type)!=null?i:"";return["temperature_mcu","temperature_host"].includes(t)}filterNamesAndSort(s){return s.filter(this.isVisibleName).sort(this.sortObjectName)}isVisibleName(s){return!this.shortName(s).startsWith("_")}sortObjectName(s,e){const t=this.shortName(s).toUpperCase(),r=this.shortName(e).toUpperCase();return t<r?-1:t>r?1:0}shortName(s){const e=s.split(" ");return e.length==1?e[0]:e[1]}};Sh=tR([S({components:{TemperaturePanelListItemNevermore:K0}})],Sh);var sR=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(tt,{attrs:{breakpoints:{mobile:r=>r.width<=395}},scopedSlots:e._u([{key:"default",fn:function({el:r}){return[t(Mp,{staticClass:"temperature-panel-table"},[t("thead",[t("tr",[t("th",{staticClass:"icon"},[e._v(" ")]),t("th",{staticClass:"name"},[e._v(e._s(e.$t("Panels.TemperaturePanel.Name")))]),r.is.mobile?e._e():t("th",{staticClass:"state"},[e._v(" "+e._s(e.$t("Panels.TemperaturePanel.State"))+" ")]),t("th",{staticClass:"current"},[e._v(" "+e._s(e.$t("Panels.TemperaturePanel.Current"))+" ")]),t("th",{staticClass:"target"},[e._v(" "+e._s(e.$t("Panels.TemperaturePanel.Target"))+" ")])])]),t("tbody",[e._l(e.heaterObjects,function(i){var n;return t(Zd,{key:i,attrs:{"object-name":i,"is-responsive-mobile":(n=r.is.mobile)!=null?n:!1}})}),e._l(e.nevermoreObjects,function(i){var n;return t(K0,{key:i,attrs:{"object-name":i,"is-responsive-mobile":(n=r.is.mobile)!=null?n:!1}})}),e._l(e.temperature_sensors,function(i){var n;return t(Zd,{key:i,attrs:{"object-name":i,"is-responsive-mobile":(n=r.is.mobile)!=null?n:!1}})}),e.hideMonitors?e._e():e._l(e.monitors,function(i){var n;return t(Zd,{key:i,attrs:{"object-name":i,"is-responsive-mobile":(n=r.is.mobile)!=null?n:!1}})})],2)])]}}])})},rR=[],iR=E(Sh,sR,rR,!1,null,"6b5c1548");const nR=iR.exports;var aR=Object.getOwnPropertyDescriptor,oR=(s,e,t,r)=>{for(var i=r>1?void 0:r?aR(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Ph=class extends k(L){constructor(){super(...arguments),this.mdiCog=ss}get boolTempchart(){var s;return(s=this.$store.state.gui.view.tempchart.boolTempchart)!=null?s:!1}set boolTempchart(s){this.$store.dispatch("gui/saveSetting",{name:"view.tempchart.boolTempchart",value:s})}get autoscaleTempchart(){var s;return(s=this.$store.state.gui.view.tempchart.autoscale)!=null?s:!1}set autoscaleTempchart(s){this.$store.dispatch("gui/saveSetting",{name:"view.tempchart.autoscale",value:s})}get hideMcuHostSensors(){var s;return(s=this.$store.state.gui.view.tempchart.hideMcuHostSensors)!=null?s:!1}set hideMcuHostSensors(s){this.$store.dispatch("gui/saveSetting",{name:"view.tempchart.hideMcuHostSensors",value:s})}get hideMonitors(){var s;return(s=this.$store.state.gui.view.tempchart.hideMonitors)!=null?s:!1}set hideMonitors(s){this.$store.dispatch("gui/saveSetting",{name:"view.tempchart.hideMonitors",value:s})}};Ph=oR([S],Ph);var lR=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(ye,{attrs:{"offset-y":!0,"close-on-content-click":!1,title:e.$t("Panels.TemperaturePanel.SetupTemperatures")},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{icon:"",tile:""}},"v-btn",i,!1),r),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiCog))])],1)]}}])},[t(Me,[t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.TemperaturePanel.ShowChart")},model:{value:e.boolTempchart,callback:function(r){e.boolTempchart=r},expression:"boolTempchart"}})],1),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.TemperaturePanel.HideMcuHostSensors")},model:{value:e.hideMcuHostSensors,callback:function(r){e.hideMcuHostSensors=r},expression:"hideMcuHostSensors"}})],1),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.TemperaturePanel.HideMonitors")},model:{value:e.hideMonitors,callback:function(r){e.hideMonitors=r},expression:"hideMonitors"}})],1),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.TemperaturePanel.AutoscaleChart")},model:{value:e.autoscaleTempchart,callback:function(r){e.autoscaleTempchart=r},expression:"autoscaleTempchart"}})],1)],1)],1)},cR=[],uR=E(Ph,lR,cR,!1,null,null);const dR=uR.exports;var mR=Object.defineProperty,hR=Object.getOwnPropertyDescriptor,Q0=(s,e,t,r)=>{for(var i=r>1?void 0:r?hR(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&mR(e,t,i),i};let pc=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiSnowflake=bu}get cooldownGcode(){return this.$store.getters["gui/presets/getCooldownGcode"]}cooldown(){this.$store.dispatch("server/addEvent",{message:this.cooldownGcode,type:"command"}),this.$socket.emit("printer.gcode.script",{script:this.cooldownGcode}),this.closePrompt()}closePrompt(){this.$emit("close")}};Q0([w({type:Boolean,default:!1})],pc.prototype,"showDialog",2);pc=Q0([S({components:{Panel:U}})],pc);var pR=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.showDialog,width:"400",persistent:""}},[t(U,{attrs:{title:e.$t("CoolDownDialog.CoolDown"),"card-class":"cool-down-dialog",icon:e.mdiSnowflake,"margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closePrompt}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[e._v(e._s(e.$t("CoolDownDialog.AreYouSure")))]),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.closePrompt}},[e._v(e._s(e.$t("CoolDownDialog.No")))]),t(g,{attrs:{color:"primary",text:""},on:{click:e.cooldown}},[e._v(e._s(e.$t("CoolDownDialog.Yes")))])],1)],1)],1)},fR=[],gR=E(pc,pR,fR,!1,null,"4acf0c79");const ey=gR.exports;var _R=Object.getOwnPropertyDescriptor,vR=(s,e,t,r)=>{for(var i=r>1?void 0:r?_R(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Dh=class extends k(L){constructor(){super(...arguments),this.mdiFire=sn,this.mdiMenuDown=gr,this.mdiSnowflake=bu,this.mdiCloseThick=pe,this.showCoolDownDialog=!1}get presets(){var s;return(s=this.$store.getters["gui/presets/getPresets"])!=null?s:[]}get cooldownGcode(){return this.$store.getters["gui/presets/getCooldownGcode"]}get confirmOnCoolDown(){return this.$store.state.gui.uiSettings.confirmOnCoolDown}preheat(s){var e;for(const[t,r]of Object.entries(s.values))if(r.bool){const i=t.split(" "),n=i[0];let a=(e=i[1])!=null?e:i[0],o="SET_HEATER_TEMPERATURE",l="HEATER";n==="temperature_fan"&&(o="SET_TEMPERATURE_FAN_TARGET",l="TEMPERATURE_FAN");const u="".concat(o," ").concat(l,"=").concat(a," TARGET=").concat(r.value);this.$store.dispatch("server/addEvent",{message:u,type:"command"}),this.$socket.emit("printer.gcode.script",{script:u})}s.gcode!==""&&setTimeout(()=>{this.$store.dispatch("server/addEvent",{message:s.gcode,type:"command"}),this.$socket.emit("printer.gcode.script",{script:s.gcode})},100)}btnCoolDown(){if(this.confirmOnCoolDown){this.showCoolDownDialog=!0;return}this.cooldown()}cooldown(){this.showCoolDownDialog=!1,this.$store.dispatch("server/addEvent",{message:this.cooldownGcode,type:"command"}),this.$socket.emit("printer.gcode.script",{script:this.cooldownGcode})}};Dh=vR([S({components:{CoolDownDialog:ey}})],Dh);var bR=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",{staticStyle:{height:"100%"}},[e.presets.length?t(ye,{attrs:{"offset-y":!0,left:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"pa-1",attrs:{text:"",tile:"",color:"primary",disabled:["printing","paused"].includes(e.printer_state)}},"v-btn",i,!1),r),[t("span",{staticClass:"d-none ml-1 d-md-block"},[e._v(e._s(e.$t("Panels.TemperaturePanel.Presets")))]),t(_,{staticClass:"d-md-none"},[e._v(e._s(e.mdiFire))]),t(_,[e._v(e._s(e.mdiMenuDown))])],1)]}}],null,!1,1208155870)},[t(Me,{staticClass:"py-0",attrs:{dense:""}},e._l(e.presets,function(r,i){return t(J,{key:i,attrs:{link:""},on:{click:function(n){return e.preheat(r)}}},[t("div",{staticClass:"d-flex align-center _preset-title"},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiFire))]),t("span",{staticStyle:{"padding-top":"2px"}},[e._v(e._s(r.name))])],1)])}),1),t(I,{staticClass:"_fix_transparency"}),t(Me,{staticClass:"py-0",attrs:{dense:""}},[t(J,{attrs:{link:""},on:{click:e.btnCoolDown}},[t("div",{staticClass:"d-flex align-center _preset-title"},[t(_,{staticClass:"mr-1",attrs:{small:"",color:"primary"}},[e._v(e._s(e.mdiSnowflake))]),t("span",{staticClass:"primary--text"},[e._v(e._s(e.$t("Panels.TemperaturePanel.Cooldown")))])],1)])],1)],1):t(g,{attrs:{icon:e.$vuetify.breakpoint.smAndDown,text:e.$vuetify.breakpoint.mdAndUp,tile:"",color:"primary"},on:{click:e.btnCoolDown}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiSnowflake))]),t("span",{staticClass:"d-none ml-1 d-md-inline"},[e._v(e._s(e.$t("Panels.TemperaturePanel.Cooldown")))])],1),t(ey,{attrs:{"show-dialog":e.showCoolDownDialog},on:{close:function(r){e.showCoolDownDialog=!1}}})],1)},yR=[],CR=E(Dh,bR,yR,!1,null,"0097691a");const ty=CR.exports;var $R=Object.getOwnPropertyDescriptor,xR=(s,e,t,r)=>{for(var i=r>1?void 0:r?$R(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Th=class extends k(L,Je){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiThermometerLines=Dv,this.convertName=Ye,this.capitalize=lr}get boolTempchart(){var e;return(e=this.$store.state.gui.view.tempchart.boolTempchart)!=null?e:!1}};Th=xR([S({components:{Panel:U,TempChart:Z0,TemperatureInput:J0,Responsive:tt,TemperaturePanelPresets:ty}})],Th);var wR=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.klipperReadyForGui?t(U,{attrs:{icon:e.mdiThermometerLines,title:e.$t("Panels.TemperaturePanel.Headline"),collapsible:!0,"card-class":"temperature-panel"},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(ty),t(dR)]},proxy:!0}],null,!1,3208382191)},[t(Z,{staticClass:"pa-0"},[t(nR),e.boolTempchart?[t(I,{staticClass:"my-0"}),t(Z0)]:e._e()],2)],1):e._e()},SR=[],PR=E(Th,wR,SR,!1,null,null);const DR=PR.exports;var TR=Object.defineProperty,OR=Object.getOwnPropertyDescriptor,sy=(s,e,t,r)=>{for(var i=r>1?void 0:r?OR(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&TR(e,t,i),i};let fc=class extends k(L,ur){constructor(){super(...arguments),this.mdiWebcam=on,this.mdiMenuDown=gr,this.mdiViewGrid=Bg}get webcams(){return this.$store.getters["gui/webcams/getWebcams"]}get showSwitch(){return this.webcams.length>1}get currentCamId(){var e,t,r,i;if(this.webcams.length===1)return(e=this.webcams[0].name)!=null?e:"all";let s=(r=this.$store.state.gui.view.webcam.currentCam[(t=this.currentPage)!=null?t:""])!=null?r:"all";return this.webcams.findIndex(n=>n.name===s)!==-1?s:s!==void 0&&this.webcams.length===1?(i=this.webcams[0].name)!=null?i:"":"all"}set currentCamId(s){this.$store.dispatch("gui/setCurrentWebcam",{page:this.currentPage,value:s})}get currentCam(){const s=this.webcams.find(e=>e.name===this.currentCamId);return s!=null?s:{name:this.$t("Panels.WebcamPanel.All"),service:"grid",icon:Bg}}};sy([w({default:"dashboard"})],fc.prototype,"currentPage",2);fc=sy([S({components:{Panel:U}})],fc);var MR=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.socketIsConnected?t(U,{attrs:{icon:e.mdiWebcam,title:e.$t("Panels.WebcamPanel.Headline"),collapsible:e.$route.fullPath!=="/cam","card-class":"webcam-panel","margin-bottom":e.currentPage!=="page"},scopedSlots:e._u([{key:"buttons",fn:function(){return[e.showSwitch?t(ye,{attrs:{"offset-y":!0},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{text:"",tile:""}},"v-btn",i,!1),r),["icon"in e.currentCam?t(_,{staticClass:"mr-2",attrs:{small:""}},[e._v(" "+e._s(e.convertWebcamIcon(e.currentCam.icon))+" ")]):e._e(),t("span",{staticClass:"d-none d-md-block"},[e._v(e._s("name"in e.currentCam?e.currentCam.name:"unknown"))]),t(_,{attrs:{small:""}},[e._v(e._s(e.mdiMenuDown))])],1)]}}],null,!1,150688541)},[t(Me,{staticClass:"py-0",attrs:{dense:""}},[t(J,{attrs:{link:""},on:{click:function(r){e.currentCamId="all"}}},[t(Hs,{staticClass:"mr-2"},[t(_,{staticClass:"mt-1",attrs:{small:""}},[e._v(e._s(e.mdiViewGrid))])],1),t(_t,[t(Ze,[e._v(e._s(e.$t("Panels.WebcamPanel.All")))])],1)],1),e._l(e.webcams,function(r){return t(J,{key:r.name,attrs:{link:""},on:{click:function(i){e.currentCamId=r.name}}},[t(Hs,{staticClass:"mr-2"},[t(_,{staticClass:"mt-1",attrs:{small:""}},[e._v(e._s(e.convertWebcamIcon(r.icon)))])],1),t(_t,[t(Ze,{domProps:{textContent:e._s(r.name)}})],1)],1)})],2)],1):e._e()]},proxy:!0}],null,!1,467766518)},[e.webcams.length?t(Z,{staticClass:"px-0 py-0 content d-inline-block"},[t(x,[t(b,{staticClass:"pb-0",staticStyle:{position:"relative"}},[t(Cu,{attrs:{webcam:e.currentCam,page:e.currentPage}})],1)],1)],1):t(Z,[t("p",{staticClass:"text-center mb-0 text--disabled"},[e._v(e._s(e.$t("Panels.WebcamPanel.NoWebcam")))])])],1):e._e()},kR=[],ER=E(fc,MR,kR,!1,null,"c38c67ee");const jf=ER.exports;var LR=Object.getOwnPropertyDescriptor,AR=(s,e,t,r)=>{for(var i=r>1?void 0:r?LR(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Oh=class extends k(Ns){get mobileLayout(){return this.$store.getters["gui/getPanels"]("mobile",0,!0)}get tabletLayout1(){return this.$store.getters["gui/getPanels"]("tablet",1,!0)}get tabletLayout2(){return this.$store.getters["gui/getPanels"]("tablet",2,!0)}get desktopLayout1(){return this.$store.getters["gui/getPanels"]("desktop",1,!0)}get desktopLayout2(){return this.$store.getters["gui/getPanels"]("desktop",2,!0)}get widescreenLayout1(){return this.$store.getters["gui/getPanels"]("widescreen",1,!0)}get widescreenLayout2(){return this.$store.getters["gui/getPanels"]("widescreen",2,!0)}get widescreenLayout3(){return this.$store.getters["gui/getPanels"]("widescreen",3,!0)}extractPanelName(s){return s.split("_")[0]+"-panel"}extractPanelId(s){var e;return(e=s.split("_")[1])!=null?e:null}};Oh=AR([S({components:{ExtruderControlPanel:S7,KlippyStatePanel:so,MachineSettingsPanel:k7,MacrogroupPanel:H7,MacrosPanel:U7,MiniconsolePanel:$L,MinSettingsPanel:yf,MiscellaneousPanel:Z8,SpoolmanPanel:uA,StatusPanel:jn,ToolheadControlPanel:tF,TemperaturePanel:DR,WebcamPanel:jf}})],Oh);var FR=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e.isMobile?t(x,[t(b,[t(jn),e._l(e.mobileLayout,function(r){return[t(e.extractPanelName(r.name),{key:"dashboard-mobileLayout-"+r.name,tag:"component",attrs:{"panel-id":e.extractPanelId(r.name)}})]})],2)],1):e.isTablet?t(x,[t(b,{staticClass:"col-6"},[t(jn),e._l(e.tabletLayout1,function(r){return[t(e.extractPanelName(r.name),{key:"dashboard-tabletLayout1-"+r.name,tag:"component",attrs:{"panel-id":e.extractPanelId(r.name)}})]})],2),t(b,{staticClass:"col-6"},[e._l(e.tabletLayout2,function(r){return[t(e.extractPanelName(r.name),{key:"dashboard-tabletLayout2-"+r.name,tag:"component",attrs:{"panel-id":e.extractPanelId(r.name)}})]})],2)],1):e.isDesktop?t(x,[t(b,{staticClass:"col-5"},[t(jn),e._l(e.desktopLayout1,function(r){return[t(e.extractPanelName(r.name),{key:"dashboard-desktopLayout1-"+r.name,tag:"component",attrs:{"panel-id":e.extractPanelId(r.name)}})]})],2),t(b,{staticClass:"col-7"},[e._l(e.desktopLayout2,function(r){return[t(e.extractPanelName(r.name),{key:"dashboard-desktopLayout2-"+r.name,tag:"component",attrs:{"panel-id":e.extractPanelId(r.name)}})]})],2)],1):e.isWidescreen?t(x,[t(b,{staticClass:"col-3"},[t(jn),e._l(e.widescreenLayout1,function(r){return[t(e.extractPanelName(r.name),{key:"dashboard-desktopLayout1-"+r.name,tag:"component",attrs:{"panel-id":e.extractPanelId(r.name)}})]})],2),t(b,{staticClass:"col-5"},[e._l(e.widescreenLayout2,function(r){return[t(e.extractPanelName(r.name),{key:"dashboard-desktopLayout2-"+r.name,tag:"component",attrs:{"panel-id":e.extractPanelId(r.name)}})]})],2),t(b,{staticClass:"col-4"},[e._l(e.widescreenLayout3,function(r){return[t(e.extractPanelName(r.name),{key:"dashboard-desktopLayout3-"+r.name,tag:"component",attrs:{"panel-id":e.extractPanelId(r.name)}})]})],2)],1):e._e()],1)},RR=[],HR=E(Oh,FR,RR,!1,null,null);const jR=HR.exports;var IR=Object.getOwnPropertyDescriptor,NR=(s,e,t,r)=>{for(var i=r>1?void 0:r?IR(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Mh=class extends k(L){};Mh=NR([S({components:{WebcamPanel:jf}})],Mh);var VR=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(x,[t(b,{attrs:{"col-12":""}},[t(jf,{attrs:{"current-page":"page"}})],1)],1)],1)},BR=[],UR=E(Mh,VR,BR,!1,null,"bd1524f8");const WR=UR.exports;var zR=Object.defineProperty,GR=Object.getOwnPropertyDescriptor,If=(s,e,t,r)=>{for(var i=r>1?void 0:r?GR(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&zR(e,t,i),i};let wa=class extends k(L){constructor(){super(...arguments),this.internalColor=Ir}colorChanged(s){this.internalColor=s!==""?s:Ir}created(){this.color!==""&&(this.internalColor=this.color)}};If([w({required:!1,default:""})],wa.prototype,"color",2);If([he("color")],wa.prototype,"colorChanged",1);wa=If([S],wa);var ZR=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("svg",{attrs:{version:"1.1",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",x:"0px",y:"0px",viewBox:"0 0 599.38 523.11","xml:space":"preserve"}},[t("g",[t("path",{style:"fill:"+e.color+";",attrs:{d:"M382.29,142.98L132.98,522.82L0,522.68L344.3,0l0,0C352.18,49.06,365.2,97.68,382.29,142.98"}}),t("path",{style:"fill:"+e.color+";",attrs:{d:"M413.28,213.54L208.5,522.92l132.94,0.19l135.03-206.33l0,0C452.69,284.29,431.53,249.77,413.28,213.54 L413.28,213.54"}}),t("path",{style:"fill:"+e.color+";",attrs:{d:"M599.38,447.69l-49.25,75.42L417,522.82l101.6-153.67l0,0C543.48,397.35,570.49,423.61,599.38,447.69 L599.38,447.69z"}})])])},qR=[],XR=E(wa,ZR,qR,!1,null,null);const mn=XR.exports;var YR=Object.defineProperty,JR=Object.getOwnPropertyDescriptor,Gu=(s,e,t,r)=>{for(var i=r>1?void 0:r?JR(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&YR(e,t,i),i};let Ni=class extends k(L,vt,ur){constructor(){super(...arguments),this.mdiPrinter3d=qa,this.mdiWebcam=on,this.mdiMenuDown=gr,this.mdiWebcamOff=AS,this.mdiFileOutline=tv,this.imageHeight=200}get printerUrl(){let t=window.location.href.split("/")[0]+"//"+this.printer.socket.hostname;return this.printer.socket.webPort!==80&&(t+=":"+this.printer.socket.webPort),t}get isCurrentPrinter(){return this.$store.getters["farm/"+this.printer._namespace+"/isCurrentPrinter"]}get currentCamName(){return this.$store.getters["farm/"+this.printer._namespace+"/getSetting"]("currentCamName","off")}set currentCamName(s){this.$store.dispatch("farm/"+this.printer._namespace+"/setSettings",{currentCamName:s})}get printer_name(){return this.$store.getters["farm/"+this.printer._namespace+"/getPrinterName"]}get printer_status(){return this.$store.getters["farm/"+this.printer._namespace+"/getStatus"]}get printer_current_filename(){return this.$store.getters["farm/"+this.printer._namespace+"/getCurrentFilename"]}get printer_image(){var s;return this.currentWebcam?this.sidebarBgImage:(s=this.$store.getters["farm/"+this.printer._namespace+"/getImage"])!=null?s:this.sidebarBgImage}get printer_logo(){return this.$store.getters["farm/"+this.printer._namespace+"/getLogo"]}get printerLogoColor(){return this.$store.getters["farm/"+this.printer._namespace+"/getLogoColor"]}get printer_position(){return this.$store.getters["farm/"+this.printer._namespace+"/getPosition"]}get printer_preview(){return this.$store.getters["farm/"+this.printer._namespace+"/getPrinterPreview"]}get showWebcamSwitch(){return this.printer_webcams.length==0?!1:this.printer.socket.isConnected}get printer_webcams(){return this.$store.getters["farm/"+this.printer._namespace+"/getPrinterWebcams"]}get currentWebcam(){var e;const s=(e=this.printer_webcams)==null?void 0:e.find(t=>t.name===this.currentCamName);return s||null}get panelClass(){let s=[];return!this.printer.socket.isConnected&&!this.printer.socket.isConnecting&&s.push("disabledPrinter"),s}clickPrinter(){if(this.printer.socket.isConnected){this.$store.dispatch("changePrinter",{printer:this.printer._namespace});return}this.$store.dispatch("farm/"+this.printer._namespace+"/reconnect")}mounted(){this.calcImageHeight()}calcImageHeight(){var s,e;if((e=(s=this.imageDiv)==null?void 0:s.$el)!=null&&e.clientWidth){this.imageHeight=Math.round(this.imageDiv.$el.clientWidth/3*2);return}this.imageHeight=200}handleResize(){this.$nextTick(()=>{this.calcImageHeight()})}};Gu([w({type:Object,required:!0})],Ni.prototype,"printer",2);Gu([Ts()],Ni.prototype,"imageDiv",2);Gu([Ke(200)],Ni.prototype,"handleResize",1);Ni=Gu([S({components:{Panel:U,"webcam-wrapper":Cu,"mainsail-logo":mn}})],Ni);var KR=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(U,{class:e.panelClass,attrs:{icon:e.mdiPrinter3d,title:e.printer_name,"card-class":"farmprinter-panel",loading:e.printer.socket.isConnecting,"toolbar-color":e.isCurrentPrinter?"primary":""},scopedSlots:e._u([{key:"buttons",fn:function(){return[e.showWebcamSwitch?t(ye,{attrs:{"offset-y":!0,title:"Webcam"},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{text:""}},"v-btn",i,!1),r),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiWebcam))]),t(_,{attrs:{small:""}},[e._v(e._s(e.mdiMenuDown))])],1)]}}],null,!1,505444931)},[t(Me,{staticClass:"py-0",attrs:{dense:""}},[t(J,{attrs:{link:""},on:{click:function(r){e.currentCamName="off"}}},[t(Hs,{staticClass:"mr-2"},[t(_,{staticClass:"mt-1",attrs:{small:""}},[e._v(e._s(e.mdiWebcamOff))])],1),t(_t,[t(Ze,[e._v(e._s(e.$t("Panels.FarmPrinterPanel.WebcamOff")))])],1)],1),e._l(e.printer_webcams,function(r){return t(J,{key:r.name,attrs:{link:""},on:{click:function(i){e.currentCamName=r.name}}},[t(Hs,{staticClass:"mr-2"},[t(_,{staticClass:"mt-1",attrs:{small:""}},[e._v(e._s(e.convertWebcamIcon(r.icon)))])],1),t(_t,[t(Ze,{domProps:{textContent:e._s(r.name)}})],1)],1)})],2)],1):e._e()]},proxy:!0}])},[t(M$,{scopedSlots:e._u([{key:"default",fn:function({hover:r}){return[t("div",[t(nu,{ref:"imageDiv",staticClass:"d-flex align-end",attrs:{height:e.imageHeight,src:e.printer_image}},[e.printer.socket.isConnected&&e.currentCamName!=="off"&&e.currentWebcam&&"service"in e.currentWebcam?t("div",{staticClass:"webcamContainer"},[t(Cu,{attrs:{webcam:e.currentWebcam,"printer-url":e.printerUrl,"show-fps":!1}})],1):e._e(),t(gt,{staticClass:"white--text py-2",staticStyle:{"background-color":"rgba(0, 0, 0, 0.3)","backdrop-filter":"blur(3px)"}},[t(x,[t(b,{staticClass:"col-auto pr-0 d-flex align-center",staticStyle:{width:"58px"}},[e.printer_logo?t("img",{staticClass:"my-auto",staticStyle:{width:"100%"},attrs:{src:e.printer_logo,alt:"Logo"}}):t(mn,{staticClass:"my-auto",staticStyle:{width:"100%"},attrs:{color:e.printerLogoColor}})],1),t(b,{staticClass:"col",staticStyle:{width:"100px"}},[t("h3",{staticClass:"font-weight-regular"},[e._v(e._s(e.printer_status))]),e.printer_current_filename!==""?t("span",{staticClass:"subtitle-2 text-truncate px-0 text--disabled d-block"},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiFileOutline))]),e._v(" "+e._s(e.printer_current_filename)+" ")],1):e._e()])],1)],1)],1),e.printer_preview.length?t(Z,{staticClass:"px-0 py-2"},[t(Ee,{staticClass:"py-0"},[t(x,e._l(e.printer_preview,function(i){return t(b,{key:i.name,class:i.name==="ETA"?"col-auto":"col px-2"},[t("strong",{staticClass:"d-block text-center"},[e._v(e._s(i.name))]),t("span",{staticClass:"d-block text-center"},[e._v(e._s(i.value))])])}),1)],1)],1):e._e(),t(k$,[r?t(E$,{attrs:{absolute:"","z-index":4}},[t(g,{attrs:{color:"primary"},on:{click:e.clickPrinter}},[e._v(" "+e._s(e.printer.socket.isConnected?e.$t("Panels.FarmPrinterPanel.SwitchToPrinter"):e.$t("Panels.FarmPrinterPanel.ReconnectToPrinter"))+" ")])],1):e._e()],1)],1)]}}])}),t("resize-observer",{on:{notify:e.handleResize}})],1)},QR=[],eH=E(Ni,KR,QR,!1,null,"05f75be0");const ry=eH.exports;var tH=Object.getOwnPropertyDescriptor,sH=(s,e,t,r)=>{for(var i=r>1?void 0:r?tH(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let kh=class extends k(L){get printers(){return this.$store.getters["farm/getPrinters"]}};kh=sH([S({components:{FarmPrinterPanel:ry}})],kh);var rH=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,e._l(e.printers,function(r,i){return t(b,{key:i,staticClass:"col-12 col-sm-6 col-md-4 pb-0"},[t(ry,{attrs:{printer:r}})],1)}),1)},iH=[],nH=E(kh,rH,iH,!1,null,null);const aH=nH.exports;var oH=Object.defineProperty,lH=Object.getOwnPropertyDescriptor,oo=(s,e,t,r)=>{for(var i=r>1?void 0:r?lH(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&oH(e,t,i),i};let Xr=class extends k(L,fa){constructor(){super(...arguments),this.mdiCog=ss,this.mdiTrashCan=Mv}get events(){return this.$store.getters["server/getConsoleEvents"](this.consoleDirection==="table")}eventsChanged(){this.consoleDirection==="shell"&&this.autoscroll&&setTimeout(()=>{this.scrollToBottom()},50)}autoscrollChanged(s){s&&this.scrollToBottom()}commandClick(s){this.gcodeCommandField.setGcode(s)}mounted(){this.consoleDirection==="shell"&&this.scrollToBottom()}scrollToBottom(){this.$nextTick(()=>{if(!this.consoleScroll)return;const s=this.consoleScroll.osInstance();s==null||s.scroll({y:"100%"})})}};oo([Ts()],Xr.prototype,"consoleScroll",2);oo([Ts()],Xr.prototype,"gcodeCommandField",2);oo([he("events")],Xr.prototype,"eventsChanged",1);oo([he("autoscroll")],Xr.prototype,"autoscrollChanged",1);Xr=oo([S({components:{CommandHelpModal:ju,ConsoleTable:Ru}})],Xr);var cH=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",{staticClass:"d-flex flex-column"},[t(x,{class:e.consoleDirection==="table"?"order-0":"order-1 mt-3"},[t(b,[t(g0,{ref:"gcodeCommandField"})],1),t(b,{staticClass:"col-auto d-flex align-center"},[t(g,{staticClass:"mr-3 px-2 minwidth-0",attrs:{color:"lightgray"},on:{click:e.clearConsole}},[t(_,[e._v(e._s(e.mdiTrashCan))])],1),t(ju,{on:{onCommand:function(r){return e.commandClick(r)}}}),t(ye,{attrs:{"offset-y":"",top:e.consoleDirection==="shell","close-on-content-click":!1,title:e.$t("Console.SetupConsole")},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"ml-3 px-2 minwidth-0",attrs:{color:"lightgray"}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiCog))])],1)]}}])},[t(Me,[e.consoleDirection==="shell"?t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.MiniconsolePanel.Autoscroll")},model:{value:e.autoscroll,callback:function(r){e.autoscroll=r},expression:"autoscroll"}})],1):e._e(),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Console.HideTemperatures")},model:{value:e.hideWaitTemperatures,callback:function(r){e.hideWaitTemperatures=r},expression:"hideWaitTemperatures"}})],1),e.moonrakerComponents.includes("timelapse")?t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Console.HideTimelapse")},model:{value:e.hideTlCommands,callback:function(r){e.hideTlCommands=r},expression:"hideTlCommands"}})],1):e._e(),e._l(e.customFilters,function(r,i){return t(J,{key:i,staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:r.name},on:{change:function(n){return e.toggleFilter(i,r)}},model:{value:r.bool,callback:function(n){e.$set(r,"bool",n)},expression:"filter.bool"}})],1)}),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Panels.MiniconsolePanel.RawOutput")},model:{value:e.rawOutput,callback:function(r){e.rawOutput=r},expression:"rawOutput"}})],1)],2)],1)],1)],1),t(x,{class:e.consoleDirection==="table"?"order-1":"order-0 mt-0"},[t(b,{class:e.consoleDirection==="table"?"col":"col pt-0"},[t(Pe,[t(Z,{staticClass:"pa-0"},[t("overlay-scrollbars",{ref:"consoleScroll",staticClass:"consoleScrollContainer d-flex flex-column"},[t(Ru,{ref:"console",attrs:{"is-mini":!1,events:e.events},on:{"command-click":e.commandClick}})],1)],1)],1)],1)],1)],1)},uH=[],dH=E(Xr,cH,uH,!1,null,"63e954e1");const mH=dH.exports;var hH=Object.defineProperty,pH=Object.getOwnPropertyDescriptor,iy=(s,e,t,r)=>{for(var i=r>1?void 0:r?pH(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&hH(e,t,i),i};let gc=class extends k(L){get sums(){const s={filamentLength:0,filamentWeight:0,estimatedTime:0};return this.jobs.forEach(e=>{var r,i,n,a,o,l,u,c;const t=((i=(r=e.combinedIds)==null?void 0:r.length)!=null?i:0)+1;s.filamentLength+=((a=(n=e.metadata)==null?void 0:n.filament_total)!=null?a:0)*t,s.filamentWeight+=((l=(o=e.metadata)==null?void 0:o.filament_weight_total)!=null?l:0)*t,s.estimatedTime+=((c=(u=e.metadata)==null?void 0:u.estimated_time)!=null?c:0)*t}),s}get count(){let s=0;return this.jobs.forEach(e=>{var t,r;s+=((r=(t=e.combinedIds)==null?void 0:t.length)!=null?r:0)+1}),s}get filamentLength(){const s=this.sums.filamentLength;return s===0?null:s>=1e3?(s/1e3).toFixed(1)+" m":s.toFixed(0)+" mm"}get filamentWeight(){const s=this.sums.filamentWeight;return s===0?null:s>=1e3?(s/1e3).toFixed(1)+" kg":s.toFixed(0)+" g"}get filamentOutput(){const s=[];return this.filamentLength&&s.push(this.filamentLength),this.filamentWeight&&s.push(this.filamentWeight),s.length?s.join(" / "):"--"}get estimatedTime(){let s=this.sums.estimatedTime;if(s==0)return"--";const e=[],t=Math.floor(s/(3600*24));t&&(s%=3600*24,e.push(t+"d"));const r=Math.floor(s/3600);s%=3600,r&&e.push(r+"h");const i=Math.floor(s/60);if(i&&e.push(i+"m"),r>0)return e.join(" ");const n=s%60;return n&&e.push(n.toFixed(0)+"s"),e.join(" ")}get currentPrintEta(){var e,t,r;let s=this.$store.getters["printer/getEstimatedTimeETA"];return s||(this.printerIsPrinting&&((e=this.$store.state.printer.print_stats)==null?void 0:e.print_duration)===0?Date.now()+((r=(t=this.$store.state.printer.current_file)==null?void 0:t.estimated_time)!=null?r:0)*1e3:Date.now())}get eta(){var l;if(this.sums.estimatedTime===0)return"--";let s=this.currentPrintEta+this.sums.estimatedTime*1e3;const e=(l=this.$store.getters["gui/getHours12Format"])!=null?l:!1,t=new Date(s);let r=!0,i=t.getHours();e&&i>11&&(r=!1),e&&i>12&&(i-=12),e&&i==0&&(i+=12),i<10&&(i="0"+i);const n=t.getMinutes()>=10?t.getMinutes():"0"+t.getMinutes(),a=s-new Date().getTime();let o=i+":"+n;return e&&(o+=" ".concat(r?"AM":"PM")),a>60*60*24*1e3&&(o+="+".concat(Math.trunc(a/(60*60*24*1e3)))),o}};iy([w({type:Array,required:!0})],gc.prototype,"jobs",2);gc=iy([S],gc);var fH=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,{staticClass:"jobqueue-entry-sum"},[t(b,{staticClass:"py-2",staticStyle:{"font-size":"0.875em"}},[t("small",[t("span",{staticClass:"text-no-wrap mr-1"},[e._v(e._s(e.$t("Panels.StatusPanel.Filament"))+": "+e._s(e.filamentOutput)+",")]),t("span",{staticClass:"text-no-wrap mr-1"},[e._v(e._s(e.$t("Panels.StatusPanel.PrintTime"))+": "+e._s(e.estimatedTime)+",")]),t("span",{staticClass:"text-no-wrap mr-1"},[e._v(e._s(e.$t("Panels.StatusPanel.ETA"))+": "+e._s(e.eta))])])])],1)},gH=[],_H=E(gc,fH,gH,!1,null,"e3a87c1b");const ny=_H.exports;var vH=Object.getOwnPropertyDescriptor,bH=(s,e,t,r)=>{for(var i=r>1?void 0:r?vH(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Eh=class extends k(L){constructor(){super(...arguments),this.mdiPlay=nn,this.mdiPause=Zp,this.mdiTrayFull=kv,this.joblist=[]}get jobs(){return this.$store.getters["server/jobQueue/getJobs"]}get queueState(){var s;return(s=this.$store.state.server.jobQueue.queue_state)!=null?s:""}startJobqueue(){this.$store.dispatch("server/jobQueue/start")}pauseJobqueue(){this.$store.dispatch("server/jobQueue/pause")}updateOrder(s){this.$store.dispatch("server/jobQueue/changePosition",{newIndex:s.newIndex,oldIndex:s.oldIndex})}};Eh=bH([S({components:{JobqueueEntrySum:ny,draggable:si,JobqueueEntry:Tu,Panel:U}})],Eh);var yH=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(U,{attrs:{icon:e.mdiTrayFull,title:e.$t("JobQueue.JobQueue"),"card-class":"jobqueue-panel"},scopedSlots:e._u([{key:"buttons",fn:function(){return[e.queueState==="paused"?t(g,{attrs:{color:"success",loading:e.loadings.includes("startJobqueue"),icon:"",tile:"",disabled:!e.klipperReadyForGui},on:{click:e.startJobqueue}},[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(_,e._g(e._b({},"v-icon",i,!1),r),[e._v(e._s(e.mdiPlay))])]}}],null,!1,2134053718)},[t("span",[e._v(e._s(e.$t("JobQueue.Start")))])])],1):e._e(),["ready","loading"].includes(e.queueState)?t(g,{attrs:{color:"warning",loading:e.loadings.includes("pauseJobqueue"),icon:"",tile:""},on:{click:e.pauseJobqueue}},[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(_,e._g(e._b({},"v-icon",i,!1),r),[e._v(e._s(e.mdiPause))])]}}],null,!1,1749587264)},[t("span",[e._v(e._s(e.$t("JobQueue.Pause")))])])],1):e._e()]},proxy:!0}])},[e.jobs.length?t(x,{staticClass:"mx-0 mt-0"},[t(b,[t("draggable",{staticClass:"jobqueue-list mb-3",attrs:{handle:".handle","ghost-class":"ghost",group:"jobs"},on:{end:e.updateOrder},model:{value:e.joblist,callback:function(r){e.joblist=r},expression:"joblist"}},e._l(e.jobs,function(r){return t(Tu,{key:r.job_id,attrs:{job:r,"show-handle":!0}})}),1),t(ny,{attrs:{jobs:e.jobs}})],1)],1):t(Z,[t("p",[e._v(e._s(e.$t("JobQueue.Empty")))])])],1)},CH=[],$H=E(Eh,yH,CH,!1,null,null);const ay=$H.exports;var xH=Object.defineProperty,wH=Object.getOwnPropertyDescriptor,Zu=(s,e,t,r)=>{for(var i=r>1?void 0:r?wH(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&xH(e,t,i),i};let Vi=class extends k(L){constructor(){super(...arguments),this.segmentSeparator="/"}get pathSegments(){const[s,...e]=(this.path||"").split(this.segmentSeparator),t={directoryName:s,location:s};return e.reduce((r,i)=>{const n=r[r.length-1].location,a="".concat(n).concat(this.segmentSeparator).concat(i),o={directoryName:i,location:a};return r.push(o),r},[t])}};Zu([w({default:!1})],Vi.prototype,"path",2);Zu([w({default:!1})],Vi.prototype,"baseDirectoryLabel",2);Zu([w({default:!1})],Vi.prototype,"onSegmentClick",2);Vi=Zu([S],Vi);var SH=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("span",e._l(e.pathSegments,function({directoryName:r,location:i},n){return t("span",{key:i,staticClass:"navigation-container"},[n!==0?[t("span",{staticClass:"navigation-divider text--disabled"},[e._v(e._s(e.segmentSeparator))])]:e._e(),n!==e.pathSegments.length-1?[t("span",{staticClass:"cursor-pointer navigation-segment",attrs:{tabindex:"0",role:"button"},on:{click:function(a){return e.onSegmentClick({location:i})},keyup:function(a){return!a.type.indexOf("key")&&e._k(a.keyCode,"enter",13,a.key,"Enter")?null:e.onSegmentClick({location:i})}}},[r?[e._v(e._s(r))]:[e._v(e._s(e.baseDirectoryLabel))]],2)]:[t("span",[r?[e._v(e._s(r))]:[e._v(e._s(e.baseDirectoryLabel))]],2)]],2)}),0)},PH=[],DH=E(Vi,SH,PH,!1,null,"057e3ba1");const hn=DH.exports;var TH=Object.defineProperty,OH=Object.getOwnPropertyDescriptor,oy=(s,e,t,r)=>{for(var i=r>1?void 0:r?OH(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&TH(e,t,i),i};let _c=class extends k(L,Je){constructor(){super(...arguments),this.mdiContentCopy=Fp,this.mdiFile=Bs,this.mdiFileDocumentMultipleOutline=Ga,this.mdiMagnify=rn,this.mdiUpload=ES,this.mdiFolderPlus=Vp,this.mdiRefresh=an,this.mdiCog=ss,this.mdiFolderUpload=Bp,this.mdiFolder=Np,this.mdiPlay=nn,this.mdiPlaylistPlus=Za,this.mdiFire=sn,this.mdiVideo3d=yu,this.mdiCloudDownload=Kn,this.mdiRenameBox=vu,this.mdiFileDocumentEditOutline=za,this.mdiDelete=Ue,this.mdiCloseThick=pe,this.mdiCheckboxBlankOutline=Ep,this.mdiCheckboxMarked=Lp,this.mdiDragVertical=Wa,this.formatFilesize=Xe,this.sortFiles=rf,this.search="",this.dialogCreateDirectory={show:!1,name:""},this.contextMenu={shown:!1,isDirectory:!1,touchTimer:void 0,x:0,y:0,item:{isDirectory:!1,filename:"",permissions:"",modified:new Date,preheat_gcode:null,small_thumbnail:null,big_thumbnail:null,big_thumbnail_width:null,count_printed:0,last_filament_used:null,last_start_time:null,last_end_time:null,last_print_duration:null,last_status:null,last_total_duration:null}},this.draggingFile={item:{...this.contextMenu.item}},this.dialogPrintFile={show:!1,item:{...this.contextMenu.item}},this.dialogAddBatchToQueue={isVisible:!1,filename:""},this.dialogRenameFile={show:!1,newName:"",item:{...this.contextMenu.item}},this.dialogDuplicateFile={show:!1,newName:"",item:{...this.contextMenu.item}},this.dialogRenameDirectory={show:!1,newName:"",item:{...this.contextMenu.item}},this.dialogDeleteDirectory={show:!1,newName:"",item:{...this.contextMenu.item}},this.deleteDialog=!1,this.deleteSelectedDialog=!1,this.isInvalidName=!0,this.nameInputRules=[s=>!!s||this.$t("Files.InvalidNameEmpty"),s=>!this.existsFilename(s)||this.$t("Files.InvalidNameAlreadyExists")],this.countInputRules=[s=>!!s||this.$t("JobQueue.InvalidCountEmpty"),s=>parseInt(s)>0||this.$t("JobQueue.InvalidCountGreaterZero")]}existsFilename(s){return this.files.findIndex(e=>e.filename===s)>=0}get gcodeInputFileAccept(){return this.isIOS?[]:Pi}get currentPath(){const s=this.$store.state.gui.view.gcodefiles.currentPath;return s==="gcodes"?"":s}set currentPath(s){this.$store.dispatch("gui/saveSettingWithoutUpload",{name:"view.gcodefiles.currentPath",value:s})}get selectedFiles(){var s;return(s=this.$store.state.gui.view.gcodefiles.selectedFiles)!=null?s:[]}set selectedFiles(s){this.$store.dispatch("gui/saveSettingWithoutUpload",{name:"view.gcodefiles.selectedFiles",value:s})}get fixedHeaders(){return[{text:"",value:"",visible:!0,sortable:!1},{text:this.$t("Files.Name").toString(),value:"filename",visible:!0,class:"text-no-wrap"},{text:"",value:"status",visible:!0,class:"text-no-wrap",sortable:!1}]}get configurableHeaders(){const s=[{text:this.$t("Files.Filesize").toString(),value:"size",visible:!0,class:"text-no-wrap",outputType:"filesize"},{text:this.$t("Files.LastModified").toString(),value:"modified",visible:!0,class:"text-no-wrap",outputType:"date"},{text:this.$t("Files.ObjectHeight").toString(),value:"object_height",visible:!0,class:"text-no-wrap",outputType:"length"},{text:this.$t("Files.LayerHeight").toString(),value:"layer_height",visible:!0,class:"text-no-wrap",outputType:"length"},{text:this.$t("Files.NozzleDiameter").toString(),value:"nozzle_diameter",visible:!0,class:"text-no-wrap",outputType:"length"},{text:this.$t("Files.ExtruderTemp").toString(),value:"first_layer_extr_temp",visible:!0,class:"text-no-wrap",outputType:"temp"},{text:this.$t("Files.BedTemp").toString(),value:"first_layer_bed_temp",visible:!0,class:"text-no-wrap",outputType:"temp"},{text:this.$t("Files.ChamberTemp").toString(),value:"chamber_temp",visible:!0,class:"text-no-wrap",outputType:"temp"},{text:this.$t("Files.FilamentName").toString(),value:"filament_name",visible:!0,class:"text-no-wrap"},{text:this.$t("Files.FilamentType").toString(),value:"filament_type",visible:!0,class:"text-no-wrap",outputType:"string"},{text:this.$t("Files.FilamentUsage").toString(),value:"filament_total",visible:!0,class:"text-no-wrap",outputType:"length"},{text:this.$t("Files.FilamentWeight").toString(),value:"filament_weight_total",visible:!0,class:"text-no-wrap",outputType:"weight"},{text:this.$t("Files.PrintTime").toString(),value:"estimated_time",visible:!0,class:"text-no-wrap",outputType:"time"},{text:this.$t("Files.LastStartTime").toString(),value:"last_start_time",visible:!0,class:"text-no-wrap",outputType:"date"},{text:this.$t("Files.LastEndTime").toString(),value:"last_end_time",visible:!0,class:"text-no-wrap",outputType:"date"},{text:this.$t("Files.LastPrintDuration").toString(),value:"last_print_duration",visible:!0,class:"text-no-wrap",outputType:"time"},{text:this.$t("Files.LastTotalDuration").toString(),value:"last_total_duration",visible:!0,class:"text-no-wrap",outputType:"time"},{text:this.$t("Files.LastFilamentUsed").toString(),value:"last_filament_used",visible:!0,class:"text-no-wrap",outputType:"length"},{text:this.$t("Files.Slicer").toString(),value:"slicer",visible:!0,class:"text-no-wrap",outputType:"string"}];let e=0;return s.forEach(t=>{var i;t.visible=!this.hideMetadataColumns.includes(t.value);let r=(i=this.orderMetadataColumns)==null?void 0:i.findIndex(n=>n===t.value);r===-1&&(e++,r=this.orderMetadataColumns.length+e),t.pos=r}),s.sort((t,r)=>{var i,n;return((i=t.pos)!=null?i:0)-((n=r.pos)!=null?n:0)})}set configurableHeaders(s){const e=[];s.forEach(t=>e.push(t.value)),this.orderMetadataColumns=e}get headers(){return[...this.fixedHeaders,...this.configurableHeaders]}get tableColumns(){return this.configurableHeaders.filter(s=>s.visible)}get directory(){return this.$store.getters["files/getDirectory"]("gcodes"+this.currentPath)}get disk_usage(){var s,e;return(e=(s=this.directory)==null?void 0:s.disk_usage)!=null?e:{used:0,free:0,total:0}}get files(){return this.$store.getters["files/getGcodeFiles"](this.currentPath,this.showHiddenFiles,this.showPrintedFiles)}get filteredHeaders(){return this.headers.filter(s=>s.visible)}get orderMetadataColumns(){var s;return(s=this.$store.state.gui.view.gcodefiles.orderMetadataColumns)!=null?s:[]}set orderMetadataColumns(s){this.$store.dispatch("gui/saveSetting",{name:"view.gcodefiles.orderMetadataColumns",value:s})}get hideMetadataColumns(){var s;return(s=this.$store.state.gui.view.gcodefiles.hideMetadataColumns)!=null?s:[]}set hideMetadataColumns(s){this.$store.dispatch("gui/saveSetting",{name:"view.gcodefiles.hideMetadataColumns",value:s})}get showHiddenFiles(){return this.$store.state.gui.view.gcodefiles.showHiddenFiles}set showHiddenFiles(s){this.$store.dispatch("gui/saveSetting",{name:"view.gcodefiles.showHiddenFiles",value:s})}get showPrintedFiles(){return this.$store.state.gui.view.gcodefiles.showPrintedFiles}set showPrintedFiles(s){this.$store.dispatch("gui/saveSetting",{name:"view.gcodefiles.showPrintedFiles",value:s})}get sortBy(){return this.$store.state.gui.view.gcodefiles.sortBy}set sortBy(s){s===void 0&&(s="modified"),this.$store.dispatch("gui/saveSetting",{name:"view.gcodefiles.sortBy",value:s})}get sortDesc(){return this.$store.state.gui.view.gcodefiles.sortDesc}set sortDesc(s){s===void 0&&(s=!1),this.$store.dispatch("gui/saveSetting",{name:"view.gcodefiles.sortDesc",value:s})}get countPerPage(){return this.$store.state.gui.view.gcodefiles.countPerPage}set countPerPage(s){this.$store.dispatch("gui/saveSetting",{name:"view.gcodefiles.countPerPage",value:s})}get bigThumbnailBackground(){var s;return(s=this.$store.state.gui.uiSettings.bigThumbnailBackground)!=null?s:At}get bigThumbnailTooltipColor(){if(At.toLowerCase()!==this.bigThumbnailBackground.toLowerCase())return this.bigThumbnailBackground}getStatusIcon(s){return this.$store.getters["server/history/getPrintStatusIcon"](s)}getStatusTextColor(s){return this.$store.getters["server/history/getPrintStatusTextColor"](s)}getStatusColor(s){return this.$store.getters["server/history/getPrintStatusIconColor"](s)}dragOverFilelist(s,e){s.preventDefault(),e.isDirectory&&(s.target.parentElement.style.backgroundColor="#43A04720")}dragLeaveFilelist(s){s.preventDefault(),s.stopPropagation(),s.target.parentElement.style.backgroundColor="transparent"}async dragDropFilelist(s,e){s.preventDefault(),s.target.parentElement.style.backgroundColor="transparent";let t;e.filename===".."?t=this.currentPath.substring(0,this.currentPath.lastIndexOf("/")+1)+this.draggingFile.item.filename:t=this.currentPath+"/"+e.filename+"/"+this.draggingFile.item.filename,this.$socket.emit("server.files.move",{source:"gcodes"+this.currentPath+"/"+this.draggingFile.item.filename,dest:"gcodes"+t},{action:"files/getMove"})}async uploadFile(){var s;if((s=this.$refs.fileUpload.files)!=null&&s.length){const e=[...this.$refs.fileUpload.files];this.$refs.fileUpload.value="",await this.$store.dispatch("socket/addLoading",{name:"gcodeUpload"}),await this.$store.dispatch("files/uploadSetCurrentNumber",0),await this.$store.dispatch("files/uploadSetMaxNumber",this.$refs.fileUpload.files.length);for(const t of e){await this.$store.dispatch("files/uploadIncrementCurrentNumber");const r=this.currentPath.slice(0,1)==="/"?this.currentPath.slice(1):this.currentPath,i=await this.$store.dispatch("files/uploadFile",{file:t,path:r,root:"gcodes"});i!==!1&&this.$toast.success(this.$t("Files.SuccessfullyUploaded",{filename:i}).toString())}await this.$store.dispatch("socket/removeLoading",{name:"gcodeUpload"})}}clickUploadButton(){this.$refs.fileUpload.click()}createDirectory(){this.dialogCreateDirectory.name="",this.dialogCreateDirectory.show=!0,setTimeout(()=>{var s;(s=this.$refs.inputFieldCreateDirectory)==null||s.focus()},200)}createDirectoryAction(){this.dialogCreateDirectory.name.length&&(this.dialogCreateDirectory.show=!1,this.$socket.emit("server.files.post_directory",{path:"gcodes"+this.currentPath+"/"+this.dialogCreateDirectory.name},{action:"files/getCreateDir"}))}refreshFileList(){this.$socket.emit("server.files.get_directory",{path:"gcodes"+this.currentPath},{action:"files/getDirectory"})}advancedSearch(s,e){if(e===null||typeof s!="string")return!1;s=s.toString().toLowerCase();const t=e.toLowerCase().split(" ");for(const r of t)if(!s.includes(r))return!1;return!0}refreshMetadata(s){const e=s.filter(t=>!t.isDirectory&&!t.metadataRequested&&!t.metadataPulled);this.$store.dispatch("files/requestMetadata",e.map(t=>({filename:"gcodes"+this.currentPath+"/"+t.filename})))}clickRow(s,e=!1){(!this.contextMenu.shown||e)&&(e&&(this.contextMenu.shown=!1),s.isDirectory?this.currentPath+="/"+s.filename:!["error","printing","paused"].includes(this.printer_state)&&this.isGcodeFile(s)&&(this.dialogPrintFile.show=!0,this.dialogPrintFile.item=s))}clickRowGoBack(){this.currentPath=this.currentPath.slice(0,this.currentPath.lastIndexOf("/"))}clickPathNavGoToDirectory(s){this.currentPath=s.location}async addToQueue(s){let e=[this.currentPath,s.filename].join("/");e.startsWith("/")&&(e=e.slice(1)),await this.$store.dispatch("server/jobQueue/addToQueue",[e])}openAddBatchToQueueDialog(s){let e=[this.currentPath,s.filename].join("/");e.startsWith("/")&&(e=e.slice(1)),this.dialogAddBatchToQueue.isVisible=!0,this.dialogAddBatchToQueue.filename=e}closeAddBatchToQueueDialog(){this.dialogAddBatchToQueue.isVisible=!1}changeMetadataVisible(s,e){this.$store.dispatch("gui/setGcodefilesMetadata",{name:s,value:e})}showContextMenu(s,e){this.contextMenu.shown||(s==null||s.preventDefault(),this.contextMenu.shown=!0,this.contextMenu.x=(s==null?void 0:s.clientX)||(s==null?void 0:s.pageX)||window.screenX/2,this.contextMenu.y=(s==null?void 0:s.clientY)||(s==null?void 0:s.pageY)||window.screenY/2,this.contextMenu.item=e,this.$nextTick(()=>{this.contextMenu.shown=!0}))}editFile(s){this.$store.dispatch("editor/openFile",{root:"gcodes",path:this.currentPath,filename:s.filename,size:s.size,permissions:s.permissions})}downloadFile(){const s=this.currentPath+"/"+this.contextMenu.item.filename,e=this.apiUrl+"/server/files/gcodes"+Ie(s);window.open(e)}async downloadSelectedFiles(){let s=[];const e=async(i,n)=>{for(const a of n){const o="".concat(i,"/").concat(Ie(a.filename));if(a.isDirectory&&a.childrens){await e(o,a.childrens);continue}s.push(o)}};await e("gcodes/"+this.currentPath,this.selectedFiles);const t=new Date,r="".concat(t.getFullYear()).concat(t.getMonth()).concat(t.getDate(),"-").concat(t.getHours()).concat(t.getMinutes()).concat(t.getSeconds());this.$socket.emit("server.files.zip",{items:s,dest:"config/gcodes-".concat(r,".zip")},{action:"files/downloadZip",loading:"gcodeDownloadZip"}),this.selectedFiles=[]}renameFile(s){this.dialogRenameFile.item=s,this.dialogRenameFile.newName=s.filename,this.dialogRenameFile.show=!0,setTimeout(()=>{var e;(e=this.$refs.inputFieldRenameFile)==null||e.focus()},200)}renameFileAction(){this.dialogRenameFile.show=!1,this.$socket.emit("server.files.move",{source:"gcodes"+this.currentPath+"/"+this.dialogRenameFile.item.filename,dest:"gcodes"+this.currentPath+"/"+this.dialogRenameFile.newName},{action:"files/getMove"})}duplicateFile(s){this.dialogDuplicateFile.item=s,this.dialogDuplicateFile.newName=s.filename,this.dialogDuplicateFile.show=!0,setTimeout(()=>{var e;(e=this.$refs.inputFieldDuplicateFile)==null||e.focus()},200)}duplicateFileAction(){this.dialogDuplicateFile.show=!1,this.$socket.emit("server.files.copy",{source:"gcodes"+this.currentPath+"/"+this.dialogDuplicateFile.item.filename,dest:"gcodes"+this.currentPath+"/"+this.dialogDuplicateFile.newName})}renameDirectory(s){this.dialogRenameDirectory.item=s,this.dialogRenameDirectory.newName=s.filename,this.dialogRenameDirectory.show=!0,setTimeout(()=>{var e;(e=this.$refs.inputFieldRenameDirectory)==null||e.focus()},200)}renameDirectoryAction(){this.dialogRenameDirectory.show=!1,this.$socket.emit("server.files.move",{source:"gcodes"+this.currentPath+"/"+this.dialogRenameDirectory.item.filename,dest:"gcodes"+this.currentPath+"/"+this.dialogRenameDirectory.newName},{action:"files/getMove"})}removeFile(){this.$socket.emit("server.files.delete_file",{path:"gcodes"+this.currentPath+"/"+this.contextMenu.item.filename},{action:"files/getDeleteFile"}),this.deleteDialog=!1}deleteDirectory(s){this.dialogDeleteDirectory.item=s,this.dialogDeleteDirectory.show=!0}deleteDirectoryAction(){this.dialogDeleteDirectory.show=!1,this.$socket.emit("server.files.delete_directory",{path:"gcodes"+this.currentPath+"/"+this.contextMenu.item.filename,force:!0},{action:"files/getDeleteDir"})}closeStartPrint(){this.dialogPrintFile.show=!1}dragFile(s,e){s.preventDefault(),this.draggingFile.item=e}dragendFile(s){s.preventDefault(),this.draggingFile.item={isDirectory:!1,filename:"",permissions:"",modified:new Date,count_printed:0,preheat_gcode:null,small_thumbnail:null,big_thumbnail:null,big_thumbnail_width:null,last_filament_used:null,last_start_time:null,last_end_time:null,last_print_duration:null,last_status:null,last_total_duration:null}}hideMetadataColumsCanged(s){s.forEach(e=>{let t=this.headers.find(r=>r.value===e);t&&(t.visible=!1)})}isGcodeFile(s){const e=s.filename.slice(s.filename.lastIndexOf("."));return Pi.includes(e)}view3D(s){this.$router.push({path:"/viewer",query:{filename:"gcodes"+this.currentPath+"/"+s.filename}})}scanMeta(s){this.$store.dispatch("files/scanMetadata",{filename:"gcodes"+this.currentPath+"/"+s.filename})}deleteSelectedFiles(){this.selectedFiles.forEach(s=>{s.isDirectory?this.$socket.emit("server.files.delete_directory",{path:"gcodes"+this.currentPath+"/"+s.filename,force:!0},{action:"files/getDeleteDir"}):this.$socket.emit("server.files.delete_file",{path:"gcodes"+this.currentPath+"/"+s.filename},{action:"files/getDeleteFile"})}),this.selectedFiles=[],this.deleteSelectedDialog=!1}outputValue(s,e){const t=s.value in e?e[s.value]:null;if(t===null)return"--";switch(s.outputType){case"filesize":return Xe(t);case"date":return this.formatDateTime(t);case"time":return Is(t);case"temp":return t.toFixed()+" °C";case"length":return t>1e3?(t/1e3).toFixed(2)+" m":t.toFixed(2)+" mm";case"weight":return t.toFixed(2)+" g";default:return t}}};oy([he("hideMetadataColums")],_c.prototype,"hideMetadataColumsCanged",1);_c=oy([S({components:{StartPrintDialog:Eu,AddBatchToQueueDialog:ri,Panel:U,SettingsRow:j,PathNavigation:hn,draggable:si}})],_c);var MH=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(U,{attrs:{title:e.$t("Files.GCodeFiles"),icon:e.mdiFileDocumentMultipleOutline,"card-class":"gcode-files-panel"}},[t(Z,[t(x,[t(b,{staticClass:"col-12 d-flex align-center"},[t(se,{staticStyle:{"max-width":"300px"},attrs:{"append-icon":e.mdiMagnify,label:e.$t("Files.Search"),"single-line":"",outlined:"",clearable:"","hide-details":"",dense:""},model:{value:e.search,callback:function(r){e.search=r},expression:"search"}}),t(ae),e.selectedFiles.length?t(g,{staticClass:"px-2 minwidth-0 ml-3",attrs:{title:e.$t("Files.Download"),color:"primary",loading:e.loadings.includes("gcodeDownloadZip")},on:{click:e.downloadSelectedFiles}},[t(_,[e._v(e._s(e.mdiCloudDownload))])],1):e._e(),e.selectedFiles.length?t(g,{staticClass:"px-2 minwidth-0 ml-3",attrs:{title:e.$t("Files.Delete"),color:"error"},on:{click:function(r){e.deleteSelectedDialog=!0}}},[t(_,[e._v(e._s(e.mdiDelete))])],1):e._e(),t("input",{ref:"fileUpload",staticStyle:{display:"none"},attrs:{type:"file",accept:e.gcodeInputFileAccept.join(", "),multiple:""},on:{change:e.uploadFile}}),t(g,{staticClass:"primary--text px-2 minwidth-0 ml-3",attrs:{title:e.$t("Files.UploadNewGcode"),loading:e.loadings.includes("gcodeUpload")},on:{click:e.clickUploadButton}},[t(_,[e._v(e._s(e.mdiUpload))])],1),t(g,{staticClass:"px-2 minwidth-0 ml-3",attrs:{title:e.$t("Files.CreateNewDirectory")},on:{click:e.createDirectory}},[t(_,[e._v(e._s(e.mdiFolderPlus))])],1),t(g,{staticClass:"px-2 minwidth-0 ml-3",attrs:{title:e.$t("Files.RefreshCurrentDirectory")},on:{click:e.refreshFileList}},[t(_,[e._v(e._s(e.mdiRefresh))])],1),t(ye,{attrs:{"offset-y":"",left:"","close-on-content-click":!1,title:e.$t("Files.SetupCurrentList")},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"px-2 minwidth-0 ml-3"},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiCog))])],1)]}}])},[t(Me,[t(J,{staticClass:"minHeight36",attrs:{link:""}},[t(x,[t(b,{staticClass:"pr-0"},[e._v(" "+e._s(e.$t("Files.HiddenFiles"))+" ")]),t(b,{staticClass:"col-auto pl-0"},[e.showHiddenFiles?t(_,{attrs:{color:"primary"},on:{click:function(r){r.stopPropagation(),e.showHiddenFiles=!1}}},[e._v(" "+e._s(e.mdiCheckboxMarked)+" ")]):t(_,{attrs:{color:"grey lighten-1"},on:{click:function(r){r.stopPropagation(),e.showHiddenFiles=!0}}},[e._v(" "+e._s(e.mdiCheckboxBlankOutline)+" ")])],1)],1)],1),t(J,{staticClass:"minHeight36",attrs:{link:""}},[t(x,[t(b,{staticClass:"pr-0"},[e._v(" "+e._s(e.$t("Files.PrintedFiles"))+" ")]),t(b,{staticClass:"col-auto pl-0"},[e.showPrintedFiles?t(_,{attrs:{color:"primary"},on:{click:function(r){r.stopPropagation(),e.showPrintedFiles=!1}}},[e._v(" "+e._s(e.mdiCheckboxMarked)+" ")]):t(_,{attrs:{color:"grey lighten-1"},on:{click:function(r){r.stopPropagation(),e.showPrintedFiles=!0}}},[e._v(" "+e._s(e.mdiCheckboxBlankOutline)+" ")])],1)],1)],1),t(I),t("draggable",{staticClass:"v-list-item-group",attrs:{handle:".handle","ghost-class":"ghost",group:"gcodeFilesColumnOrder"},model:{value:e.configurableHeaders,callback:function(r){e.configurableHeaders=r},expression:"configurableHeaders"}},e._l(e.configurableHeaders,function(r){return t(J,{key:r.value,staticClass:"minHeight36"},[t(x,[t(b,{staticClass:"col-auto pr-0"},[t(_,{staticClass:"handle"},[e._v(e._s(e.mdiDragVertical))])],1),t(b,[e._v(" "+e._s(r.text)+" ")]),t(b,{staticClass:"col-auto pl-0"},[r.visible?t(_,{attrs:{color:"primary"},on:{click:function(i){return i.stopPropagation(),e.changeMetadataVisible(r.value,!1)}}},[e._v(" "+e._s(e.mdiCheckboxMarked)+" ")]):t(_,{attrs:{color:"grey lighten-1"},on:{click:function(i){return i.stopPropagation(),e.changeMetadataVisible(r.value,!0)}}},[e._v(" "+e._s(e.mdiCheckboxBlankOutline)+" ")])],1)],1)],1)}),1)],1)],1)],1)],1)],1),t(Z,[t(x,[t(b,{staticClass:"col-12 py-2 d-flex align-center"},[t("span",[t("b",{staticClass:"mr-1"},[e._v(e._s(e.$t("Files.CurrentPath"))+":")]),t(hn,{attrs:{path:e.currentPath,"base-directory-label":"/gcodes","on-segment-click":e.clickPathNavGoToDirectory}})],1),t(ae),e.disk_usage!==null?[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("span",e._g(e._b({},"span",i,!1),r),[t("b",[e._v(e._s(e.$t("Files.FreeDisk"))+":")]),e._v(" "+e._s(e.formatFilesize(e.disk_usage.free))+" ")])]}}],null,!1,1145199616)},[t("span",[e._v(" "+e._s(e.$t("Files.Used"))+": "+e._s(e.formatFilesize(e.disk_usage.used))+" "),t("br"),e._v(" "+e._s(e.$t("Files.Free"))+": "+e._s(e.formatFilesize(e.disk_usage.free))+" "),t("br"),e._v(" "+e._s(e.$t("Files.Total"))+": "+e._s(e.formatFilesize(e.disk_usage.total))+" ")])])]:e._e()],2)],1)],1),t(I,{staticClass:"mb-3"}),t(Qr,{staticClass:"files-table",attrs:{items:e.files,headers:e.filteredHeaders,"custom-sort":e.sortFiles,"sort-by":e.sortBy,"sort-desc":e.sortDesc,"items-per-page":e.countPerPage,"footer-props":{itemsPerPageText:e.$t("Files.Files"),itemsPerPageAllText:e.$t("Files.AllFiles"),itemsPerPageOptions:[10,25,50,100,-1]},"item-key":"filename",search:e.search,"custom-filter":e.advancedSearch,"mobile-breakpoint":"0","show-select":""},on:{"update:sortBy":function(r){e.sortBy=r},"update:sort-by":function(r){e.sortBy=r},"update:sortDesc":function(r){e.sortDesc=r},"update:sort-desc":function(r){e.sortDesc=r},"update:itemsPerPage":function(r){e.countPerPage=r},"update:items-per-page":function(r){e.countPerPage=r},"current-items":e.refreshMetadata},scopedSlots:e._u([{key:"no-data",fn:function(){return[t("div",{staticClass:"text-center"},[e._v(e._s(e.$t("Files.Empty")))])]},proxy:!0},e.currentPath!==""?{key:"body.prepend",fn:function(){return[t("tr",{staticClass:"file-list-cursor",on:{click:e.clickRowGoBack,dragover:function(r){return e.dragOverFilelist(r,{isDirectory:!0,filename:".."})},dragleave:e.dragLeaveFilelist,drop:function(r){return r.preventDefault(),r.stopPropagation(),e.dragDropFilelist(r,{isDirectory:!0,filename:".."})}}},[t("td",{staticClass:"file-list__select-td pr-0"},[t(jr,{directives:[{name:"ripple",rawName:"v-ripple"}],staticClass:"pa-0 mr-0",attrs:{disabled:""}})],1),t("td",{staticClass:"px-0 text-center",staticStyle:{width:"32px"}},[t(_,[e._v(e._s(e.mdiFolderUpload))])],1),t("td",{staticClass:"",attrs:{colspan:e.filteredHeaders.length}},[e._v("..")])])]},proxy:!0}:null,{key:"item",fn:function({index:r,item:i,isSelected:n,select:a}){return[t("tr",{directives:[{name:"longpress",rawName:"v-longpress:600",value:o=>e.showContextMenu(o,i),expression:"(e) => showContextMenu(e, item)",arg:"600"}],key:"".concat(r," ").concat(i.filename),staticClass:"file-list-cursor user-select-none",attrs:{draggable:"true","data-name":i.filename},on:{contextmenu:function(o){return e.showContextMenu(o,i)},click:function(o){return e.clickRow(i)},drag:function(o){return e.dragFile(o,i)},dragend:function(o){return e.dragendFile(o)},dragover:function(o){return e.dragOverFilelist(o,i)},dragleave:e.dragLeaveFilelist,drop:function(o){return o.preventDefault(),o.stopPropagation(),e.dragDropFilelist(o,i)}}},[t("td",{staticClass:"file-list__select-td pr-0"},[t(jr,{directives:[{name:"ripple",rawName:"v-ripple"}],staticClass:"pa-0 mr-0",attrs:{value:n},on:{click:function(o){return o.stopPropagation(),a(!n)}}})],1),t("td",{staticClass:"px-0 text-center",staticStyle:{width:"32px"}},[i.isDirectory?[t(_,[e._v(e._s(e.mdiFolder))])]:i.small_thumbnail?[t(de,{attrs:{top:"","content-class":"tooltip__content-opacity1",color:e.bigThumbnailTooltipColor,disabled:!i.big_thumbnail},scopedSlots:e._u([{key:"activator",fn:function({on:o,attrs:l}){return[t("vue-load-image",[t("img",e._g(e._b({attrs:{slot:"image",src:i.small_thumbnail,width:"32",height:"32",alt:i.filename},slot:"image"},"img",l,!1),o)),t("div",{attrs:{slot:"preloader"},slot:"preloader"},[t(ot,{attrs:{indeterminate:"",color:"primary"}})],1),t("div",{attrs:{slot:"error"},slot:"error"},[t(_,[e._v(e._s(e.mdiFile))])],1)])]}}],null,!0)},[t("span",[t("img",{attrs:{src:i.big_thumbnail,width:"250",alt:i.filename}})])])]:[t(_,[e._v(e._s(e.mdiFile))])]],2),t("td",{staticClass:""},[e._v(e._s(i.filename))]),t("td",{staticClass:"text-right text-no-wrap"},[i.last_status?t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:o,attrs:l}){return[t("span",e._g(e._b({},"span",l,!1),o),[i.count_printed>0?t("span",{class:"file-list__count_printed ".concat(e.getStatusTextColor(i.last_status))},[e._v(" "+e._s(i.count_printed)+" ")]):e._e(),t(_,{attrs:{small:"",color:e.getStatusColor(i.last_status)}},[e._v(" "+e._s(e.getStatusIcon(i.last_status))+" ")])],1)]}}],null,!0)},[t("span",[e._v(e._s(i.last_status.replace(/_/g," ")))])]):e._e()],1),e._l(e.tableColumns,function(o){return t("td",{key:o.value,class:o.outputType!=="date"?"text-no-wrap":""},[e._v(" "+e._s(e.outputValue(o,i))+" "),o.value==="slicer"?[t("br"),i.slicer_version?t("small",[e._v(e._s(i.slicer_version))]):e._e()]:e._e()],2)})],2)]}}],null,!0),model:{value:e.selectedFiles,callback:function(r){e.selectedFiles=r},expression:"selectedFiles"}})],1),t(Eu,{attrs:{bool:e.dialogPrintFile.show,file:e.dialogPrintFile.item,"current-path":e.currentPath},on:{closeDialog:e.closeStartPrint}}),t(ye,{attrs:{"position-x":e.contextMenu.x,"position-y":e.contextMenu.y,absolute:"","offset-y":""},model:{value:e.contextMenu.shown,callback:function(r){e.$set(e.contextMenu,"shown",r)},expression:"contextMenu.shown"}},[t(Me,[e.contextMenu.item.isDirectory?e._e():t(J,{attrs:{disabled:e.printerIsPrinting||!e.klipperReadyForGui||!e.isGcodeFile(e.contextMenu.item)},on:{click:function(r){return e.clickRow(e.contextMenu.item,!0)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPlay))]),e._v(" "+e._s(e.$t("Files.PrintStart"))+" ")],1),!e.contextMenu.item.isDirectory&&e.moonrakerComponents.includes("job_queue")?t(J,{attrs:{disabled:!e.isGcodeFile(e.contextMenu.item)},on:{click:function(r){return e.addToQueue(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPlaylistPlus))]),e._v(" "+e._s(e.$t("Files.AddToQueue"))+" ")],1):e._e(),!e.contextMenu.item.isDirectory&&e.moonrakerComponents.includes("job_queue")?t(J,{attrs:{disabled:!e.isGcodeFile(e.contextMenu.item)},on:{click:function(r){return e.openAddBatchToQueueDialog(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPlaylistPlus))]),e._v(" "+e._s(e.$t("Files.AddBatchToQueue"))+" ")],1):e._e(),e.contextMenu.item.preheat_gcode!==null?t(J,{attrs:{disabled:["error","printing","paused"].includes(e.printer_state)},on:{click:function(r){return e.doSend(e.contextMenu.item.preheat_gcode)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiFire))]),e._v(" "+e._s(e.$t("Files.Preheat"))+" ")],1):e._e(),e.contextMenu.item.isDirectory?e._e():t(J,{attrs:{disabled:!e.isGcodeFile(e.contextMenu.item)},on:{click:function(r){return e.view3D(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiVideo3d))]),e._v(" "+e._s(e.$t("Files.View3D"))+" ")],1),e.contextMenu.item.isDirectory?e._e():t(J,{attrs:{disabled:!e.isGcodeFile(e.contextMenu.item)},on:{click:function(r){return e.scanMeta(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiMagnify))]),e._v(" "+e._s(e.$t("Files.ScanMeta"))+" ")],1),e.contextMenu.item.isDirectory?e._e():t(J,{on:{click:e.downloadFile}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiCloudDownload))]),e._v(" "+e._s(e.$t("Files.Download"))+" ")],1),e.contextMenu.item.isDirectory?t(J,{on:{click:function(r){return e.renameDirectory(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiRenameBox))]),e._v(" "+e._s(e.$t("Files.Rename"))+" ")],1):e._e(),e.contextMenu.item.isDirectory?e._e():t(J,{on:{click:function(r){return e.editFile(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiFileDocumentEditOutline))]),e._v(" "+e._s(e.$t("Files.EditFile"))+" ")],1),e.contextMenu.item.isDirectory?e._e():t(J,{on:{click:function(r){return e.renameFile(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiRenameBox))]),e._v(" "+e._s(e.$t("Files.Rename"))+" ")],1),e.contextMenu.item.isDirectory?e._e():t(J,{on:{click:function(r){return e.duplicateFile(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiContentCopy))]),e._v(" "+e._s(e.$t("Files.Duplicate"))+" ")],1),e.contextMenu.item.isDirectory?e._e():t(J,{staticClass:"red--text",on:{click:function(r){e.deleteDialog=!0}}},[t(_,{staticClass:"mr-1",attrs:{color:"error"}},[e._v(e._s(e.mdiDelete))]),e._v(" "+e._s(e.$t("Files.Delete"))+" ")],1),e.contextMenu.item.isDirectory?t(J,{staticClass:"red--text",on:{click:function(r){return e.deleteDirectory(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1",attrs:{color:"error"}},[e._v(e._s(e.mdiDelete))]),e._v(" "+e._s(e.$t("Files.Delete"))+" ")],1):e._e()],1)],1),t(le,{attrs:{"max-width":400},model:{value:e.dialogCreateDirectory.show,callback:function(r){e.$set(e.dialogCreateDirectory,"show",r)},expression:"dialogCreateDirectory.show"}},[t(U,{attrs:{title:e.$t("Files.NewDirectory"),"card-class":"gcode-files-new-directory-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.dialogCreateDirectory.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputFieldCreateDirectory",attrs:{label:e.$t("Files.Name"),required:"",rules:e.nameInputRules},on:{"update:error":r=>e.isInvalidName=r,keypress:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"enter",13,r.key,"Enter")?null:e.createDirectoryAction.apply(null,arguments)}},model:{value:e.dialogCreateDirectory.name,callback:function(r){e.$set(e.dialogCreateDirectory,"name",r)},expression:"dialogCreateDirectory.name"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.dialogCreateDirectory.show=!1}}},[e._v(e._s(e.$t("Files.Cancel")))]),t(g,{attrs:{disabled:e.isInvalidName,color:"primary",text:""},on:{click:e.createDirectoryAction}},[e._v(" "+e._s(e.$t("Files.Create"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":400},model:{value:e.dialogRenameFile.show,callback:function(r){e.$set(e.dialogRenameFile,"show",r)},expression:"dialogRenameFile.show"}},[t(U,{attrs:{title:e.$t("Files.RenameFile"),"card-class":"gcode-files-rename-file-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.dialogRenameFile.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputFieldRenameFile",attrs:{label:e.$t("Files.Name"),required:"",rules:e.nameInputRules},on:{"update:error":r=>e.isInvalidName=r,keyup:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"enter",13,r.key,"Enter")?null:e.renameFileAction.apply(null,arguments)}},model:{value:e.dialogRenameFile.newName,callback:function(r){e.$set(e.dialogRenameFile,"newName",r)},expression:"dialogRenameFile.newName"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.dialogRenameFile.show=!1}}},[e._v(e._s(e.$t("Files.Cancel")))]),t(g,{attrs:{disabled:e.isInvalidName,color:"primary",text:""},on:{click:e.renameFileAction}},[e._v(" "+e._s(e.$t("Files.Rename"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":400},model:{value:e.dialogDuplicateFile.show,callback:function(r){e.$set(e.dialogDuplicateFile,"show",r)},expression:"dialogDuplicateFile.show"}},[t(U,{attrs:{title:e.$t("Files.DuplicateFile"),"card-class":"gcode-files-duplicate-file-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.dialogDuplicateFile.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputFieldDuplicateFile",attrs:{label:e.$t("Files.Name"),required:"",rules:e.nameInputRules},on:{"update:error":r=>e.isInvalidName=r,keyup:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"enter",13,r.key,"Enter")?null:e.duplicateFileAction.apply(null,arguments)}},model:{value:e.dialogDuplicateFile.newName,callback:function(r){e.$set(e.dialogDuplicateFile,"newName",r)},expression:"dialogDuplicateFile.newName"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.dialogDuplicateFile.show=!1}}},[e._v(e._s(e.$t("Files.Cancel")))]),t(g,{attrs:{disabled:e.isInvalidName,color:"primary",text:""},on:{click:e.duplicateFileAction}},[e._v(" "+e._s(e.$t("Files.Duplicate"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.dialogRenameDirectory.show,callback:function(r){e.$set(e.dialogRenameDirectory,"show",r)},expression:"dialogRenameDirectory.show"}},[t(U,{attrs:{title:e.$t("Files.RenameDirectory"),"card-class":"gcode-files-rename-directory-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.dialogRenameDirectory.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputFieldRenameDirectory",attrs:{label:e.$t("Files.Name"),required:"",rules:e.nameInputRules},on:{"update:error":r=>e.isInvalidName=r,keyup:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"enter",13,r.key,"Enter")?null:e.renameDirectoryAction.apply(null,arguments)}},model:{value:e.dialogRenameDirectory.newName,callback:function(r){e.$set(e.dialogRenameDirectory,"newName",r)},expression:"dialogRenameDirectory.newName"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.dialogRenameDirectory.show=!1}}},[e._v(e._s(e.$t("Files.Cancel")))]),t(g,{attrs:{disabled:e.isInvalidName,color:"primary",text:""},on:{click:e.renameDirectoryAction}},[e._v(" "+e._s(e.$t("Files.Rename"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.dialogDeleteDirectory.show,callback:function(r){e.$set(e.dialogDeleteDirectory,"show",r)},expression:"dialogDeleteDirectory.show"}},[t(U,{attrs:{title:e.$t("Files.DeleteDirectory"),"card-class":"gcode-files-delete-directory-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.dialogDeleteDirectory.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t("p",{staticClass:"mb-0"},[e._v(" "+e._s(e.$t("Files.DeleteDirectoryQuestion",{name:e.dialogDeleteDirectory.item.filename}))+" ")])]),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.dialogDeleteDirectory.show=!1}}},[e._v(e._s(e.$t("Files.Cancel")))]),t(g,{attrs:{color:"error",text:""},on:{click:e.deleteDirectoryAction}},[e._v(e._s(e.$t("Files.Delete")))])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.deleteDialog,callback:function(r){e.deleteDialog=r},expression:"deleteDialog"}},[t(U,{attrs:{title:e.$t("Files.Delete"),"card-class":"gcode-files-delete-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.deleteDialog=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t("p",{staticClass:"mb-0"},[e._v(" "+e._s(e.$t("Files.DeleteSingleFileQuestion",{name:e.contextMenu.item.filename}))+" ")])]),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.deleteDialog=!1}}},[e._v(" "+e._s(e.$t("Files.Cancel"))+" ")]),t(g,{attrs:{color:"error",text:""},on:{click:e.removeFile}},[e._v(" "+e._s(e.$t("Files.Delete"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.deleteSelectedDialog,callback:function(r){e.deleteSelectedDialog=r},expression:"deleteSelectedDialog"}},[t(U,{attrs:{title:e.$t("Files.Delete"),"card-class":"gcode-files-delete-selected-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.deleteSelectedDialog=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[e.selectedFiles.length===1?t("p",{staticClass:"mb-0"},[e._v(" "+e._s(e.$t("Files.DeleteSingleFileQuestion",{name:e.selectedFiles[0].filename}))+" ")]):t("p",{staticClass:"mb-0"},[e._v(e._s(e.$t("Files.DeleteSelectedQuestion",{count:e.selectedFiles.length})))])]),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.deleteSelectedDialog=!1}}},[e._v(e._s(e.$t("Files.Cancel")))]),t(g,{attrs:{color:"error",text:""},on:{click:e.deleteSelectedFiles}},[e._v(e._s(e.$t("Files.Delete")))])],1)],1)],1),t(ri,{attrs:{"is-visible":e.dialogAddBatchToQueue.isVisible,filename:e.dialogAddBatchToQueue.filename},on:{close:e.closeAddBatchToQueueDialog}})],1)},kH=[],EH=E(_c,MH,kH,!1,null,null);const ly=EH.exports;var LH=Object.getOwnPropertyDescriptor,AH=(s,e,t,r)=>{for(var i=r>1?void 0:r?LH(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Lh=class extends k(L){constructor(){super(...arguments),this.mdiLockOutline=fu}get queued_jobs(){var s;return(s=this.$store.state.server.jobQueue.queued_jobs)!=null?s:[]}get showJobQueue(){return this.moonrakerComponents.includes("job_queue")&&this.queued_jobs.length}};Lh=AH([S({components:{JobqueuePanel:ay,GcodefilesPanel:ly}})],Lh);var FH=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.existGcodesRootDirectory?t(x,[t(b,{class:e.showJobQueue?"col-12 col-md-8 pt-0 pt-md-3 order-1 order-md-0":"col-12"},[t(ly)],1),e.showJobQueue?t(b,{staticClass:"col-12 col-md-4 pb-0 pb-sm-3 order-0 order-md-1"},[t(ay)],1):e._e()],1):t(x,[t(it,{staticClass:"mx-auto mt-6",attrs:{dense:"",text:"",type:"warning",elevation:"2","max-width":"500",icon:e.mdiLockOutline}},[e._v(" "+e._s(e.$t("Files.GcodesRootDirectoryDoesntExists"))+" ")])],1)},RH=[],HH=E(Lh,FH,RH,!1,null,null);const jH=HH.exports;var IH=Object.defineProperty,NH=Object.getOwnPropertyDescriptor,Nf=(s,e,t,r)=>{for(var i=r>1?void 0:r?NH(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&IH(e,t,i),i};let Sa=class extends k(L){constructor(){super(...arguments),this.mdiAdjust=tn,this.mdiAlarm=Yn,this.mdiCalendar=uu,this.mdiCloseThick=pe,this.mdiNotebookPlus=fv,this.name="",this.note="",this.reminder=null,this.reminderFilament=!1,this.reminderFilamentValue=0,this.reminderPrinttime=!1,this.reminderPrinttimeValue=0,this.reminderDate=!1,this.reminderDateValue=0,this.nameInputRules=[e=>!!e||this.$t("History.InvalidNameEmpty")]}get reminderItems(){return[{text:this.$t("History.NoReminder").toString(),value:null},{text:this.$t("History.OneTime").toString(),value:"one-time"},{text:this.$t("History.Repeat").toString(),value:"repeat"}]}get totalFilamentUsed(){var e,t;return(t=(e=this.$store.state.server.history.job_totals)==null?void 0:e.total_filament_used)!=null?t:0}get totalPrinttime(){var e,t;return(t=(e=this.$store.state.server.history.job_totals)==null?void 0:e.total_print_time)!=null?t:0}get isValid(){return!(this.name===""||this.reminder!==null&&(!this.reminderFilament&&!this.reminderPrinttime&&!this.reminderDate||this.reminderFilament&&this.reminderFilamentValue<=0||this.reminderPrinttime&&this.reminderPrinttimeValue<=0||this.reminderDate&&this.reminderDateValue<=0))}closeDialog(){this.$emit("close")}save(){const e=new Date;this.$store.dispatch("gui/maintenance/store",{entry:{name:this.name,note:this.note,start_time:e.getTime()/1e3,end_time:null,start_filament:this.totalFilamentUsed,end_filament:null,start_printtime:this.totalPrinttime,end_printtime:null,reminder:{type:this.reminder,filament:{bool:this.reminderFilament,value:this.reminderFilamentValue},printtime:{bool:this.reminderPrinttime,value:this.reminderPrinttimeValue},date:{bool:this.reminderDate,value:this.reminderDateValue}}}}),this.closeDialog()}resetValues(){this.name="",this.note="",this.reminder=null,this.reminderFilament=!1,this.reminderFilamentValue=0,this.reminderPrinttime=!1,this.reminderPrinttimeValue=0,this.reminderDate=!1,this.reminderDateValue=0}onShowChanged(){this.show&&this.resetValues()}};Nf([w({type:Boolean,default:!1})],Sa.prototype,"show",2);Nf([he("show")],Sa.prototype,"onShowChanged",1);Sa=Nf([S({components:{Panel:U,SettingsRow:j}})],Sa);var VH=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.show,"max-width":600,persistent:""},on:{keydown:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"esc",27,r.key,["Esc","Escape"])?null:e.closeDialog.apply(null,arguments)}}},[t(U,{attrs:{title:e.$t("History.AddMaintenance"),icon:e.mdiNotebookPlus,"card-class":"history-add-maintenance-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{staticClass:"pb-0"},[t(x,[t(b,[t(se,{attrs:{rules:e.nameInputRules,label:e.$t("History.Name"),"hide-details":"auto",outlined:"",dense:""},model:{value:e.name,callback:function(r){e.name=r},expression:"name"}})],1)],1),t(x,[t(b,[t(pr,{attrs:{outlined:"","hide-details":"auto",label:e.$t("History.Note")},model:{value:e.note,callback:function(r){e.note=r},expression:"note"}})],1)],1),t(x,[t(b,[t(j,{attrs:{title:e.$t("History.Reminder")}},[t(ke,{staticClass:"mt-0",attrs:{items:e.reminderItems,outlined:"",dense:"","hide-details":""},model:{value:e.reminder,callback:function(r){e.reminder=r},expression:"reminder"}})],1)],1)],1),e.reminder?[t(x,[t(b,[t(j,{attrs:{icon:e.mdiAdjust,title:e.$t("History.FilamentBasedReminder"),"sub-title":e.$t("History.FilamentBasedReminderDescription")}},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.reminderFilament,callback:function(r){e.reminderFilament=r},expression:"reminderFilament"}}),t(se,{staticClass:"mt-0",attrs:{"hide-details":"auto",type:"number",outlined:"",dense:"",suffix:e.$t("History.Meter")},model:{value:e.reminderFilamentValue,callback:function(r){e.reminderFilamentValue=e._n(r)},expression:"reminderFilamentValue"}})],1)],1)],1),t(x,[t(b,[t(j,{attrs:{icon:e.mdiAlarm,title:e.$t("History.PrinttimeBasedReminder"),"sub-title":e.$t("History.PrinttimeBasedReminderDescription")}},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.reminderPrinttime,callback:function(r){e.reminderPrinttime=r},expression:"reminderPrinttime"}}),t(se,{staticClass:"mt-0",attrs:{"hide-details":"auto",type:"number",outlined:"",dense:"",suffix:e.$t("History.Hours")},model:{value:e.reminderPrinttimeValue,callback:function(r){e.reminderPrinttimeValue=e._n(r)},expression:"reminderPrinttimeValue"}})],1)],1)],1),t(x,[t(b,[t(j,{attrs:{icon:e.mdiCalendar,title:e.$t("History.DateBasedReminder"),"sub-title":e.$t("History.DateBasedReminderDescription")}},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.reminderDate,callback:function(r){e.reminderDate=r},expression:"reminderDate"}}),t(se,{staticClass:"mt-0",attrs:{"hide-details":"auto",type:"number",outlined:"",dense:"",suffix:e.$t("History.Days")},model:{value:e.reminderDateValue,callback:function(r){e.reminderDateValue=e._n(r)},expression:"reminderDateValue"}})],1)],1)],1)]:e._e()],2),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.closeDialog}},[e._v(e._s(e.$t("History.Cancel")))]),t(g,{attrs:{color:"primary",text:"",disabled:!e.isValid},on:{click:e.save}},[e._v(e._s(e.$t("History.Save")))])],1)],1)],1)},BH=[],UH=E(Sa,VH,BH,!1,null,null);const cy=UH.exports;var WH=Object.defineProperty,zH=Object.getOwnPropertyDescriptor,uy=(s,e,t,r)=>{for(var i=r>1?void 0:r?zH(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&WH(e,t,i),i};let vc=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe}get selectedJobs(){var s;return(s=this.$store.state.gui.view.history.selectedJobs)!=null?s:[]}set selectedJobs(s){this.$store.dispatch("gui/saveSettingWithoutUpload",{name:"view.history.selectedJobs",value:s})}get question(){return this.selectedJobs.length===1?this.$t("History.DeleteSingleJobQuestion"):this.$t("History.DeleteSelectedQuestion",{count:this.selectedJobs.length})}closeDialog(){this.$emit("close")}deleteSelectedJobs(){this.selectedJobs.forEach(s=>{if(s.type==="maintenance"){this.$store.dispatch("gui/maintenance/delete",s.id);return}"job_id"in s&&this.$socket.emit("server.history.delete_job",{uid:s.job_id},{action:"server/history/getDeletedJobs"})}),this.selectedJobs=[],this.closeDialog()}};uy([w({type:Boolean,required:!0})],vc.prototype,"show",2);vc=uy([S({components:{Panel:U}})],vc);var GH=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.show,"max-width":"400"}},[t(U,{attrs:{title:e.$t("History.Delete"),"card-class":"history-delete-selected-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t("p",{staticClass:"mb-0"},[e._v(e._s(e.question))])]),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:e.closeDialog}},[e._v(e._s(e.$t("History.Cancel")))]),t(g,{attrs:{color:"error",text:""},on:{click:e.deleteSelectedJobs}},[e._v(e._s(e.$t("History.Delete")))])],1)],1)],1)},ZH=[],qH=E(vc,GH,ZH,!1,null,null);const dy=qH.exports;var XH=Object.defineProperty,YH=Object.getOwnPropertyDescriptor,qu=(s,e,t,r)=>{for(var i=r>1?void 0:r?YH(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&XH(e,t,i),i};let Bi=class extends k(L){constructor(){super(...arguments),this.mdiAdjust=tn,this.mdiAlarm=Yn,this.mdiCalendar=uu,this.mdiCloseThick=pe,this.mdiNotebook=gu,this.name="",this.note="",this.reminder=null,this.reminderFilament=!1,this.reminderFilamentValue=0,this.reminderPrinttime=!1,this.reminderPrinttimeValue=0,this.reminderDate=!1,this.reminderDateValue=0,this.nameInputRules=[s=>!!s||this.$t("History.InvalidNameEmpty")]}get reminderItems(){return[{text:this.$t("History.NoReminder").toString(),value:null},{text:this.$t("History.OneTime").toString(),value:"one-time"},{text:this.$t("History.Repeat").toString(),value:"repeat"}]}get totalFilamentUsed(){var s,e;return(e=(s=this.$store.state.server.history.job_totals)==null?void 0:s.total_filament_used)!=null?e:0}get totalPrinttime(){var s,e;return(e=(s=this.$store.state.server.history.job_totals)==null?void 0:s.total_print_time)!=null?e:0}get isValid(){return!(this.name===""||this.reminder!==null&&(!this.reminderFilament&&!this.reminderPrinttime&&!this.reminderDate||this.reminderFilament&&this.reminderFilamentValue<=0||this.reminderPrinttime&&this.reminderPrinttimeValue<=0||this.reminderDate&&this.reminderDateValue<=0))}closeDialog(){this.$emit("close")}save(){const s={...this.item};"type"in s&&delete s.type,s.name=this.name,s.note=this.note,s.reminder={type:this.reminder,filament:{bool:this.reminderFilament,value:this.reminderFilamentValue},printtime:{bool:this.reminderPrinttime,value:this.reminderPrinttimeValue},date:{bool:this.reminderDate,value:this.reminderDateValue}},this.$store.dispatch("gui/maintenance/update",s),this.closeDialog()}onShowChanged(){var s,e,t,r,i,n,a,o,l,u,c,d,m,h;this.show&&(this.name=this.item.name,this.note=this.item.note,this.reminder=(e=(s=this.item.reminder)==null?void 0:s.type)!=null?e:null,this.reminderFilament=(r=(t=this.item.reminder)==null?void 0:t.filament.bool)!=null?r:!1,this.reminderFilamentValue=(n=(i=this.item.reminder)==null?void 0:i.filament.value)!=null?n:0,this.reminderPrinttime=(o=(a=this.item.reminder)==null?void 0:a.printtime.bool)!=null?o:!1,this.reminderPrinttimeValue=(u=(l=this.item.reminder)==null?void 0:l.printtime.value)!=null?u:0,this.reminderDate=(d=(c=this.item.reminder)==null?void 0:c.date.bool)!=null?d:!1,this.reminderDateValue=(h=(m=this.item.reminder)==null?void 0:m.date.value)!=null?h:0)}};qu([w({type:Boolean,default:!1})],Bi.prototype,"show",2);qu([w({type:Object,required:!0})],Bi.prototype,"item",2);qu([he("show")],Bi.prototype,"onShowChanged",1);Bi=qu([S({components:{Panel:U,SettingsRow:j}})],Bi);var JH=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.show,"max-width":600,persistent:""},on:{keydown:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"esc",27,r.key,["Esc","Escape"])?null:e.closeDialog.apply(null,arguments)}}},[t(U,{attrs:{title:e.$t("History.EditMaintenance"),icon:e.mdiNotebook,"card-class":"history-edit-maintenance-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{staticClass:"pb-0"},[t(x,[t(b,[t(se,{attrs:{rules:e.nameInputRules,label:e.$t("History.Name"),"hide-details":"auto",outlined:"",dense:""},model:{value:e.name,callback:function(r){e.name=r},expression:"name"}})],1)],1),t(x,[t(b,[t(pr,{attrs:{outlined:"","hide-details":"auto",label:e.$t("History.Note")},model:{value:e.note,callback:function(r){e.note=r},expression:"note"}})],1)],1),t(x,[t(b,[t(j,{attrs:{title:e.$t("History.Reminder")}},[t(ke,{staticClass:"mt-0",attrs:{items:e.reminderItems,disabled:e.item.end_time!==null,outlined:"",dense:"","hide-details":""},model:{value:e.reminder,callback:function(r){e.reminder=r},expression:"reminder"}})],1)],1)],1),e.reminder?[t(x,[t(b,[t(j,{attrs:{icon:e.mdiAdjust,title:e.$t("History.FilamentBasedReminder"),"sub-title":e.$t("History.FilamentBasedReminderDescription")}},[t(ge,{staticClass:"mt-0",attrs:{disabled:e.item.end_time!==null,"hide-details":""},model:{value:e.reminderFilament,callback:function(r){e.reminderFilament=r},expression:"reminderFilament"}}),t(se,{staticClass:"mt-0",attrs:{disabled:e.item.end_time!==null,"hide-details":"auto",type:"number",outlined:"",dense:"",suffix:e.$t("History.Meter")},model:{value:e.reminderFilamentValue,callback:function(r){e.reminderFilamentValue=e._n(r)},expression:"reminderFilamentValue"}})],1)],1)],1),t(x,[t(b,[t(j,{attrs:{icon:e.mdiAlarm,title:e.$t("History.PrinttimeBasedReminder"),"sub-title":e.$t("History.PrinttimeBasedReminderDescription")}},[t(ge,{staticClass:"mt-0",attrs:{disabled:e.item.end_time!==null,"hide-details":""},model:{value:e.reminderPrinttime,callback:function(r){e.reminderPrinttime=r},expression:"reminderPrinttime"}}),t(se,{staticClass:"mt-0",attrs:{disabled:e.item.end_time!==null,"hide-details":"auto",type:"number",outlined:"",dense:"",suffix:e.$t("History.Hours")},model:{value:e.reminderPrinttimeValue,callback:function(r){e.reminderPrinttimeValue=e._n(r)},expression:"reminderPrinttimeValue"}})],1)],1)],1),t(x,[t(b,[t(j,{attrs:{icon:e.mdiCalendar,title:e.$t("History.DateBasedReminder"),"sub-title":e.$t("History.DateBasedReminderDescription")}},[t(ge,{staticClass:"mt-0",attrs:{disabled:e.item.end_time!==null,"hide-details":""},model:{value:e.reminderDate,callback:function(r){e.reminderDate=r},expression:"reminderDate"}}),t(se,{staticClass:"mt-0",attrs:{disabled:e.item.end_time!==null,"hide-details":"auto",type:"number",outlined:"",dense:"",suffix:e.$t("History.Days")},model:{value:e.reminderDateValue,callback:function(r){e.reminderDateValue=e._n(r)},expression:"reminderDateValue"}})],1)],1)],1)]:e._e()],2),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.closeDialog}},[e._v(e._s(e.$t("History.Cancel")))]),t(g,{attrs:{color:"primary",text:"",disabled:!e.isValid},on:{click:e.save}},[e._v(e._s(e.$t("History.Save")))])],1)],1)],1)},KH=[],QH=E(Bi,JH,KH,!1,null,null);const ej=QH.exports;var tj=Object.defineProperty,sj=Object.getOwnPropertyDescriptor,Xu=(s,e,t,r)=>{for(var i=r>1?void 0:r?sj(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&tj(e,t,i),i};let Ui=class extends k(L){constructor(){super(...arguments),this.mdiAdjust=tn,this.mdiAlarm=Yn,this.mdiCalendar=uu,this.mdiCloseThick=pe}get date(){return this.formatDateTime(this.item.start_time*1e3,!1)}get dateText(){return this.last?this.$t("History.EntryCreatedAt",{date:this.date}):this.$t("History.EntryPerformedAt",{date:this.date})}get showGoals(){return this.item.reminder.type===null?!1:this.current&&this.item.end_time===null}get restFilament(){var i,n,a,o,l;const s=(n=(i=this.item)==null?void 0:i.start_filament)!=null?n:0,e=(a=this.item.end_filament)!=null?a:0;let r=((l=(o=this.$store.state.server.history.job_totals)==null?void 0:o.total_filament_used)!=null?l:0)-s;return e&&(r=e-s),r/=1e3,r}get restFilamentText(){var e,t;const s=(t=(e=this.item.reminder.filament)==null?void 0:e.value)!=null?t:0;return this.showGoals?this.item.reminder.filament.bool?"".concat(this.restFilament.toFixed(0)," / ").concat(s," m"):!1:"".concat(this.restFilament.toFixed(0)," m")}get restFilamentClass(){var t,r;const s=["mr-3"];if(!this.showGoals||!this.item.reminder.filament.bool)return s;const e=(r=(t=this.item.reminder.filament)==null?void 0:t.value)!=null?r:0;return this.restFilament>e?[...s,"error--text","font-weight-bold"]:s}get restPrinttime(){var i,n,a,o;const s=(i=this.item.start_printtime)!=null?i:0,e=(n=this.item.end_printtime)!=null?n:0;let r=((o=(a=this.$store.state.server.history.job_totals)==null?void 0:a.total_print_time)!=null?o:0)-s;return e&&(r=e-s),r/=3600,r}get restPrinttimeText(){var e,t;const s=(t=(e=this.item.reminder.printtime)==null?void 0:e.value)!=null?t:0;return this.showGoals?this.item.reminder.printtime.bool?"".concat(this.restPrinttime.toFixed(1)," / ").concat(s," h"):!1:"".concat(this.restPrinttime.toFixed(1)," h")}get restPrinttimeClass(){var t,r;const s=["mr-3"];if(!this.showGoals||!this.item.reminder.printtime.bool)return s;const e=(r=(t=this.item.reminder.printtime)==null?void 0:t.value)!=null?r:0;return this.restPrinttime>e?[...s,"error--text","font-weight-bold"]:s}get restDays(){var i,n;const s=(i=this.item.start_time)!=null?i:0,e=(n=this.item.end_time)!=null?n:0;let r=new Date().getTime()/1e3-s;return e&&(r=e-s),r/(60*60*24)}get restDaysText(){var e,t;const s=(t=(e=this.item.reminder.date)==null?void 0:e.value)!=null?t:0;return this.showGoals?this.item.reminder.date.bool?"".concat(this.restDays.toFixed(0)," / ").concat(s," days"):!1:"".concat(this.restDays.toFixed(0)," days")}get restDaysClass(){var t,r;const s=["mr-3"];if(!this.showGoals||!this.item.reminder.date.bool)return s;const e=(r=(t=this.item.reminder.date)==null?void 0:t.value)!=null?r:0;return this.restDays>e?[...s,"error--text","font-weight-bold"]:s}get classDateItem(){return{"pb-2":!this.last,"pb-5":this.last}}get note(){var s;return(s=this.item.perform_note)==null?void 0:s.replaceAll("\n","<br>")}};Xu([w({type:Object,default:!1})],Ui.prototype,"item",2);Xu([w({type:Boolean,default:!1})],Ui.prototype,"current",2);Xu([w({type:Boolean,default:!1})],Ui.prototype,"last",2);Ui=Xu([S({components:{Panel:U}})],Ui);var rj=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(Zn,{staticClass:"pb-2",attrs:{small:"","hide-dot":""}},[t("div",[e.restFilamentText?t("span",{class:e.restFilamentClass},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiAdjust))]),e._v(" "+e._s(e.restFilamentText)+" ")],1):e._e(),e.restPrinttimeText?t("span",{class:e.restPrinttimeClass},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiAlarm))]),e._v(" "+e._s(e.restPrinttimeText)+" ")],1):e._e(),e.restDaysText?t("span",{class:e.restDaysClass},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiCalendar))]),e._v(" "+e._s(e.restDaysText)+" ")],1):e._e()]),e.note?t("p",{staticClass:"mt-2 mb-0",domProps:{innerHTML:e._s(e.note)}}):e._e()]),t(Zn,{class:e.classDateItem,attrs:{small:""}},[t("strong",[e._v(e._s(e.dateText))])])],1)},ij=[],nj=E(Ui,rj,ij,!1,null,null);const Vf=nj.exports;var aj=Object.defineProperty,oj=Object.getOwnPropertyDescriptor,Yu=(s,e,t,r)=>{for(var i=r>1?void 0:r?oj(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&aj(e,t,i),i};let Wi=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiNotebook=gu,this.note=""}get showPerformButton(){var s,e;return this.item.end_time?!1:(e=(s=this.item.reminder)==null?void 0:s.type)!=null?e:!1}get performButtonText(){var s;return((s=this.item.reminder)==null?void 0:s.type)==="repeat"?this.$t("History.PerformedAndReschedule"):this.$t("History.Performed")}closeDialog(){this.$emit("close")}perform(){this.$store.dispatch("gui/maintenance/perform",{id:this.item.id,note:this.note}),this.$emit("close-both")}onShowChanged(s){s&&(this.note="")}};Yu([w({type:Boolean,default:!1})],Wi.prototype,"show",2);Yu([w({type:Object,default:!1})],Wi.prototype,"item",2);Yu([he("show")],Wi.prototype,"onShowChanged",1);Wi=Yu([S({components:{Panel:U,HistoryListPanelDetailMaintenanceHistoryEntry:Vf}})],Wi);var lj=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.show,"max-width":400,persistent:""},on:{keydown:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"esc",27,r.key,["Esc","Escape"])?null:e.closeDialog.apply(null,arguments)}}},[t(U,{attrs:{title:e.$t("History.PerformMaintenance"),icon:e.mdiNotebook,"card-class":"history-perform-maintenance-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{staticClass:"pb-0"},[t(x,[t(b,[t(pr,{attrs:{outlined:"","hide-details":"auto",label:e.$t("History.AddANote")},model:{value:e.note,callback:function(r){e.note=r},expression:"note"}})],1)],1)],1),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.closeDialog}},[e._v(e._s(e.$t("History.Cancel")))]),e.showPerformButton?t(g,{attrs:{text:"",color:"primary"},on:{click:e.perform}},[e._v(e._s(e.performButtonText))]):e._e()],1)],1)],1)},cj=[],uj=E(Wi,lj,cj,!1,null,null);const my=uj.exports;var dj=Object.defineProperty,mj=Object.getOwnPropertyDescriptor,Bf=(s,e,t,r)=>{for(var i=r>1?void 0:r?mj(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&dj(e,t,i),i};let Pa=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiNotebook=gu,this.mdiPencil=bt,this.showEditDialog=!1,this.showPerformDialog=!1}get date(){return this.formatDateTime(this.item.start_time*1e3,!1)}get note(){return this.item.note.replaceAll("\n","<br>")}get showPerformButton(){var s,e;return this.item.end_time?!1:(e=(s=this.item.reminder)==null?void 0:s.type)!=null?e:!1}get allEntries(){var s;return(s=this.$store.getters["gui/maintenance/getEntries"])!=null?s:[]}get history(){const s=[];let e=this.item.id;for(;e;){const t=this.allEntries.find(r=>r.id===e);if(!t)break;s.push(t),e=t.last_entry}return s}get outputFirstPointOfHistory(){return this.item.reminder.type===null?this.$t("History.EntrySince"):this.item.end_time===null?this.$t("History.EntryNextPerform"):this.$t("History.EntryPerformedAt",{date:this.formatDateTime(this.item.end_time*1e3)})}closeDialog(){this.$emit("close")}closePerform(){this.showPerformDialog=!1,this.closeDialog()}};Bf([w({type:Boolean,default:!1})],Pa.prototype,"show",2);Bf([w({type:Object,default:!1})],Pa.prototype,"item",2);Pa=Bf([S({components:{HistoryListPanelPerformMaintenance:my,Panel:U,HistoryListPanelDetailMaintenanceHistoryEntry:Vf}})],Pa);var hj=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.show,"max-width":500,persistent:""},on:{keydown:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"esc",27,r.key,["Esc","Escape"])?null:e.closeDialog.apply(null,arguments)}}},[t(U,{attrs:{title:e.$t("History.Maintenance"),icon:e.mdiNotebook,"card-class":"history-maintenance-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.showEditDialog=!0}}},[t(_,[e._v(e._s(e.mdiPencil))])],1),t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t("overlay-scrollbars",{staticStyle:{height:"350px"}},[t(Z,{staticClass:"pb-0"},[t(x,[t(b,[t("div",[e._v(e._s(e.date))]),t("p",{staticClass:"text-h4 text--primary"},[e._v(e._s(e.item.name))]),e.note?t("div",{staticClass:"text--primary",domProps:{innerHTML:e._s(e.note)}}):e._e()])],1)],1),t(I,{staticClass:"mt-3 mb-0"}),t(Z,{staticClass:"pt-0 mb-0 pb-0"},[t(M_,{attrs:{"align-top":"",dense:""}},[t(Zn,{staticClass:"pb-1",attrs:{small:""}},[t("strong",[e._v(e._s(e.outputFirstPointOfHistory))])]),e._l(e.history,function(r){return t(Vf,{key:r.id,attrs:{item:r,current:r.id===e.item.id,last:r.id===e.history[e.history.length-1].id}})})],2)],1)],1),t(I,{staticClass:"mt-0"}),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.closeDialog}},[e._v(e._s(e.$t("History.Cancel")))]),e.showPerformButton?t(g,{attrs:{text:"",color:"primary"},on:{click:function(r){e.showPerformDialog=!0}}},[e._v(" "+e._s(e.$t("History.Perform"))+" ")]):e._e()],1)],1),t(my,{attrs:{show:e.showPerformDialog,item:e.item},on:{close:function(r){e.showPerformDialog=!1},"close-both":e.closePerform}}),t(ej,{attrs:{show:e.showEditDialog,item:e.item},on:{close:function(r){e.showEditDialog=!1}}})],1)},pj=[],fj=E(Pa,hj,pj,!1,null,null);const Uf=fj.exports;var gj=Object.defineProperty,_j=Object.getOwnPropertyDescriptor,Ju=(s,e,t,r)=>{for(var i=r>1?void 0:r?_j(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&gj(e,t,i),i};let zi=class extends k(L){constructor(){super(...arguments),this.mdiAdjust=tn,this.mdiAlarm=Yn,this.mdiCalendar=uu,this.mdiDelete=Ue,this.mdiTextBoxSearch=Sv,this.detailsDialogBool=!1,this.contextMenuBool=!1,this.contextMenuX=0,this.contextMenuY=0}get cssClasses(){return["file-list-cursor","user-select-none"]}get restFilament(){var n,a,o,l,u;const e=(a=(n=this.item)==null?void 0:n.start_filament)!=null?a:0,t=(o=this.item.end_filament)!=null?o:0;let i=((u=(l=this.$store.state.server.history.job_totals)==null?void 0:l.total_filament_used)!=null?u:0)-e;return t&&(i=t-e),i/=1e3,i}get restTextFilament(){var t,r;if(!this.item.reminder.filament.bool)return!1;const e=(r=(t=this.item.reminder.filament)==null?void 0:t.value)!=null?r:0;return"".concat(this.restFilament.toFixed(0)," / ").concat(e," m")}get restPrinttime(){var n,a,o,l;const e=(n=this.item.start_printtime)!=null?n:0,t=(a=this.item.end_printtime)!=null?a:0;let i=((l=(o=this.$store.state.server.history.job_totals)==null?void 0:o.total_print_time)!=null?l:0)-e;return t&&(i=t-e),i/=3600,i}get restTextPrinttime(){var t,r;if(!this.item.reminder.printtime.bool)return!1;const e=(r=(t=this.item.reminder.printtime)==null?void 0:t.value)!=null?r:0;return"".concat(this.restPrinttime.toFixed(1)," / ").concat(e," h")}get restDays(){var n,a;const e=(n=this.item.start_time)!=null?n:0,t=(a=this.item.end_time)!=null?a:0;let i=new Date().getTime()/1e3-e;return t&&(i=t-e),i/(60*60*24)}get restTextDays(){var t,r;if(!this.item.reminder.date.bool)return!1;const e=(r=(t=this.item.reminder.date)==null?void 0:t.value)!=null?r:0;return"".concat(this.restDays.toFixed(0)," / ").concat(e," days")}get reminder(){var e,t;return(t=(e=this.item.reminder)==null?void 0:e.type)!=null?t:null}get alarmIcon(){return this.reminder==="repeat"?uw:Yn}get icon(){return this.item.end_time!==null?cS:gu}select(e){this.$emit("select",e)}showContextMenu(e){e==null||e.preventDefault(),!this.contextMenuBool&&(this.contextMenuBool=!0,this.contextMenuX=(e==null?void 0:e.clientX)||(e==null?void 0:e.pageX)||window.screenX/2,this.contextMenuY=(e==null?void 0:e.clientY)||(e==null?void 0:e.pageY)||window.screenY/2,this.$nextTick(()=>{this.contextMenuBool=!0}))}deleteEntry(){this.$store.dispatch("gui/maintenance/delete",this.item.id)}};Ju([w({type:Object,required:!0})],zi.prototype,"item",2);Ju([w({type:Array,required:!0})],zi.prototype,"tableFields",2);Ju([w({type:Boolean,required:!0})],zi.prototype,"isSelected",2);zi=Ju([S({components:{HistoryListPanelDetailMaintenance:Uf,Panel:U}})],zi);var vj=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("tr",{directives:[{name:"longpress",rawName:"v-longpress:600",value:r=>e.showContextMenu(r),expression:"(e) => showContextMenu(e)",arg:"600"}],key:e.item.id,class:e.cssClasses,on:{contextmenu:function(r){return e.showContextMenu(r)},click:function(r){e.detailsDialogBool=!0}}},[t("td",{staticClass:"pr-0"},[t(jr,{directives:[{name:"ripple",rawName:"v-ripple"}],staticClass:"pa-0 mr-0",attrs:{value:e.isSelected},on:{click:function(r){return r.stopPropagation(),e.select(!e.isSelected)}}})],1),t("td",{staticClass:"px-0 text-center",staticStyle:{width:"32px"}},[t(_,{attrs:{color:"primary"}},[e._v(e._s(e.icon))])],1),t("td",[e._v(e._s(e.item.name))]),t("td",{staticClass:"text-right text-no-wrap"},[e.reminder!==null?t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(_,e._g(e._b({attrs:{small:"",color:"primary"}},"v-icon",i,!1),r),[e._v(" "+e._s(e.alarmIcon)+" ")])]}}],null,!1,95998964)},[t("div",[e.restTextFilament?t("div",[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiAdjust))]),e._v(" "+e._s(e.restTextFilament)+" ")],1):e._e(),e.restTextPrinttime?t("div",[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiAlarm))]),e._v(" "+e._s(e.restTextPrinttime)+" ")],1):e._e(),e.restTextDays?t("div",[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiCalendar))]),e._v(" "+e._s(e.restTextDays)+" ")],1):e._e()])]):e._e()],1),t("td",{staticClass:"text-left text-no-wrap"},[e._v(" "+e._s(e.formatDateTime(e.item.start_time*1e3,!1))+" ")]),t("td",{attrs:{colspan:e.tableFields.length-1}}),t(ye,{attrs:{"position-x":e.contextMenuX,"position-y":e.contextMenuY,absolute:"","offset-y":""},model:{value:e.contextMenuBool,callback:function(r){e.contextMenuBool=r},expression:"contextMenuBool"}},[t(Me,[t(J,{on:{click:function(r){e.detailsDialogBool=!0}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiTextBoxSearch))]),e._v(" "+e._s(e.$t("History.Details"))+" ")],1),t(J,{staticClass:"red--text",on:{click:e.deleteEntry}},[t(_,{staticClass:"mr-1",attrs:{color:"error"}},[e._v(e._s(e.mdiDelete))]),e._v(" "+e._s(e.$t("History.Delete"))+" ")],1)],1)],1),t(Uf,{attrs:{show:e.detailsDialogBool,item:e.item},on:{close:function(r){e.detailsDialogBool=!1}}})],1)},bj=[],yj=E(zi,vj,bj,!1,null,null);const hy=yj.exports;var Cj=Object.defineProperty,$j=Object.getOwnPropertyDescriptor,lo=(s,e,t,r)=>{for(var i=r>1?void 0:r?$j(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&Cj(e,t,i),i};let Yr=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.note=""}get panelTitle(){return this.type==="create"?this.$t("History.CreateNote").toString():this.$t("History.EditNote").toString()}get icon(){return this.type==="create"?pv:hv}saveNote(){var s;this.$store.dispatch("server/history/saveHistoryNote",{job_id:(s=this.job)==null?void 0:s.job_id,note:this.note}),this.closeDialog()}closeDialog(){this.$emit("close-dialog")}onShowChanged(){var s;this.show&&(this.note=(s=this.job.note)!=null?s:"")}};lo([w({type:Boolean,required:!0})],Yr.prototype,"show",2);lo([w({type:String,required:!0})],Yr.prototype,"type",2);lo([w({type:Object,required:!0})],Yr.prototype,"job",2);lo([he("show",{immediate:!0})],Yr.prototype,"onShowChanged",1);Yr=lo([S({components:{Panel:U,SettingsRow:j}})],Yr);var xj=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{"max-width":600,persistent:""},on:{keydown:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"esc",27,r.key,["Esc","Escape"])?null:e.closeDialog.apply(null,arguments)}},model:{value:e.show,callback:function(r){e.show=r},expression:"show"}},[t(U,{attrs:{title:e.panelTitle,icon:e.icon,"card-class":"history-note-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{staticClass:"pb-0"},[t(x,[t(b,[t(pr,{attrs:{outlined:"","hide-details":"",label:e.$t("History.Note")},model:{value:e.note,callback:function(r){e.note=r},expression:"note"}})],1)],1)],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:e.closeDialog}},[e._v(e._s(e.$t("History.Cancel")))]),t(g,{attrs:{color:"primary",text:""},on:{click:e.saveNote}},[e._v(e._s(e.$t("History.Save")))])],1)],1)],1)},wj=[],Sj=E(Yr,xj,wj,!1,null,"5377fa07");const py=Sj.exports;var Pj=Object.defineProperty,Dj=Object.getOwnPropertyDescriptor,Wf=(s,e,t,r)=>{for(var i=r>1?void 0:r?Dj(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&Pj(e,t,i),i};let Da=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiUpdate=Xa,this.formatFilesize=Xe,this.formatPrintTime=Is}get entries(){var t,r,i,n,a,o,l,u,c,d,m,h,f,p,v,C,P,M,F,O,$,D,V,N,W,G,te,X,q,z,K,Q,re;let e=[{name:this.$t("History.Filename").toString(),value:this.job.filename,exists:!0},{name:this.$t("History.Filesize").toString(),value:Xe((r=(t=this.job.metadata)==null?void 0:t.filesize)!=null?r:0),exists:((n=(i=this.job.metadata)==null?void 0:i.filesize)!=null?n:0)>0},{name:this.$t("History.LastModified").toString(),value:this.formatDateTime(((o=(a=this.job.metadata)==null?void 0:a.modified)!=null?o:0)*1e3),exists:((u=(l=this.job.metadata)==null?void 0:l.modified)!=null?u:0)>0},{name:this.$t("History.Status").toString(),value:this.$te("History.StatusValues.".concat(this.job.status),"en")?this.$t("History.StatusValues.".concat(this.job.status)).toString():this.job.status,exists:!0},{name:this.$t("History.StartTime").toString(),value:this.formatDateTime(this.job.start_time*1e3),exists:!0},{name:this.$t("History.EndTime").toString(),value:this.formatDateTime(this.job.end_time*1e3),exists:this.job.end_time>0},{name:this.$t("History.EstimatedTime").toString(),value:this.formatPrintTime((d=(c=this.job.metadata)==null?void 0:c.estimated_time)!=null?d:0),exists:this.job.metadata&&"estimated_time"in this.job.metadata},{name:this.$t("History.PrintDuration").toString(),value:this.formatPrintTime((m=this.job.print_duration)!=null?m:0),exists:this.job.print_duration>0},{name:this.$t("History.TotalDuration").toString(),value:this.formatPrintTime((h=this.job.total_duration)!=null?h:0),exists:this.job.total_duration>0},{name:this.$t("History.EstimatedFilamentWeight").toString(),value:"".concat(Math.round(((p=(f=this.job.metadata)==null?void 0:f.filament_weight_total)!=null?p:0)*100)/100," g"),exists:this.job.metadata&&"filament_weight_total"in this.job.metadata},{name:this.$t("History.EstimatedFilament").toString(),value:"".concat(Math.round((C=(v=this.job.metadata)==null?void 0:v.filament_total)!=null?C:0)," mm"),exists:this.job.metadata&&"filament_total"in this.job.metadata},{name:this.$t("History.FilamentUsed").toString(),value:"".concat(Math.round((M=(P=this.job.metadata)==null?void 0:P.filament_used)!=null?M:0)," mm"),exists:this.job.metadata&&"filament_used"in this.job.metadata},{name:this.$t("History.FirstLayerExtTemp").toString(),value:"".concat((O=(F=this.job.metadata)==null?void 0:F.first_layer_extr_temp)!=null?O:0," °C"),exists:this.job.metadata&&"first_layer_extr_temp"in this.job.metadata},{name:this.$t("History.FirstLayerBedTemp").toString(),value:"".concat((D=($=this.job.metadata)==null?void 0:$.first_layer_bed_temp)!=null?D:0," °C"),exists:this.job.metadata&&"first_layer_bed_temp"in this.job.metadata},{name:this.$t("History.FirstLayerHeight").toString(),value:"".concat((N=(V=this.job.metadata)==null?void 0:V.first_layer_height)!=null?N:0," mm"),exists:this.job.metadata&&"first_layer_height"in this.job.metadata},{name:this.$t("History.LayerHeight").toString(),value:"".concat((G=(W=this.job.metadata)==null?void 0:W.layer_height)!=null?G:0," mm"),exists:this.job.metadata&&"layer_height"in this.job.metadata},{name:this.$t("History.ObjectHeight").toString(),value:"".concat((X=(te=this.job.metadata)==null?void 0:te.object_height)!=null?X:0," mm"),exists:this.job.metadata&&"object_height"in this.job.metadata},{name:this.$t("History.Slicer").toString(),value:(z=(q=this.job.metadata)==null?void 0:q.slicer)!=null?z:"--",exists:this.job.metadata&&"slicer"in this.job.metadata},{name:this.$t("History.SlicerVersion").toString(),value:(Q=(K=this.job.metadata)==null?void 0:K.slicer_version)!=null?Q:"--",exists:this.job.metadata&&"slicer_version"in this.job.metadata}];return"auxiliary_data"in this.job&&((re=this.job.auxiliary_data)==null||re.forEach(R=>{let B=R.value.toString();Array.isArray(R.value)||(B="".concat(Math.round(R.value*1e3)/1e3," ").concat(R.units)),B===""&&(B="--"),e.push({name:R.description,value:B,exists:!0})})),e.filter(R=>R.exists)}closeDialog(){this.$emit("close-dialog")}};Wf([w({type:Boolean,required:!0})],Da.prototype,"show",2);Wf([w({type:Object,required:!0})],Da.prototype,"job",2);Da=Wf([S({components:{Panel:U,SettingsRow:j}})],Da);var Tj=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{"max-width":600,persistent:""},on:{keydown:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"esc",27,r.key,["Esc","Escape"])?null:e.closeDialog.apply(null,arguments)}},model:{value:e.show,callback:function(r){e.show=r},expression:"show"}},[t(U,{attrs:{title:e.$t("History.JobDetails").toString(),icon:e.mdiUpdate,"card-class":"history-detail-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{staticClass:"pa-0"},[t("overlay-scrollbars",{staticClass:"px-6",staticStyle:{height:"350px"}},[e._l(e.entries,function(r,i){return[i>0?t(I,{key:"history_detail_entry_divider_"+i,staticClass:"my-3"}):e._e(),t(x,{key:"history_detail_entry_"+i},[t(b,[e._v(e._s(r.name))]),t(b,{staticClass:"text-right"},[e._v(e._s(r.value))])],1)]})],2)],1)],1)],1)},Oj=[],Mj=E(Da,Tj,Oj,!1,null,"5124be47");const zf=Mj.exports;var kj=Object.defineProperty,Ej=Object.getOwnPropertyDescriptor,Ku=(s,e,t,r)=>{for(var i=r>1?void 0:r?Ej(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&kj(e,t,i),i};let Gi=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiDelete=Ue,this.mdiFile=Bs,this.mdiFileCancel=Vw,this.mdiNoteEditOutline=hv,this.mdiNotePlusOutline=pv,this.mdiNoteTextOutline=lS,this.mdiPrinter=Xp,this.mdiTextBoxSearch=Sv,this.mdiPlaylistPlus=Za,this.detailsDialogBool=!1,this.contextMenuBool=!1,this.contextMenuX=0,this.contextMenuY=0,this.noteDialogBool=!1,this.noteDialogType="create",this.addBatchToQueueDialogBool=!1}get smallThumbnail(){var t,r,i,n,a;if(((i=(r=(t=this.item.metadata)==null?void 0:t.thumbnails)==null?void 0:r.length)!=null?i:0)<1)return!1;const e=(a=(n=this.item.metadata)==null?void 0:n.thumbnails)==null?void 0:a.find(o=>o.width>=Yt&&o.width<=Jt&&o.height>=Yt&&o.height<=Jt);return e?this.createThumbnailUrl(e):!1}get bigThumbnail(){var t,r,i,n,a;if(((i=(r=(t=this.item.metadata)==null?void 0:t.thumbnails)==null?void 0:r.length)!=null?i:0)<1)return!1;const e=(a=(n=this.item.metadata)==null?void 0:n.thumbnails)==null?void 0:a.find(o=>o.width>=Ls);return e?this.createThumbnailUrl(e):!1}get statusIcon(){return this.$store.getters["server/history/getPrintStatusIcon"](this.item.status)}get statusColor(){return this.$store.getters["server/history/getPrintStatusIconColor"](this.item.status)}get statusName(){return this.$t("History.StatusValues.".concat(this.item.status),"en")?this.$t("History.StatusValues.".concat(this.item.status)):this.item.status.replace(/_/g," ")}get cssClasses(){let e=["file-list-cursor","user-select-none"];return this.item.exists||e.push("text--disabled"),e}get isJobQueueAvailable(){return this.moonrakerComponents.includes("job_queue")}select(e){this.$emit("select",e)}showContextMenu(e){e==null||e.preventDefault(),!this.contextMenuBool&&(this.contextMenuBool=!0,this.contextMenuX=(e==null?void 0:e.clientX)||(e==null?void 0:e.pageX)||window.screenX/2,this.contextMenuY=(e==null?void 0:e.clientY)||(e==null?void 0:e.pageY)||window.screenY/2,this.$nextTick(()=>{this.contextMenuBool=!0}))}startPrint(){this.item.exists&&this.$socket.emit("printer.print.start",{filename:this.item.filename},{action:"switchToDashboard"})}createNote(){this.noteDialogType="create",this.noteDialogBool=!0}editNote(){this.noteDialogType="edit",this.noteDialogBool=!0}addToQueue(){this.$store.dispatch("server/jobQueue/addToQueue",[this.item.filename]),this.$toast.info(this.$t("History.AddToQueueSuccessful",{filename:this.item.filename}).toString())}deleteJob(){this.$socket.emit("server.history.delete_job",{uid:this.item.job_id},{action:"server/history/getDeletedJobs"})}outputValue(e,t){var i;let r=e.value in t?t[e.value]:null;if(r===null&&(r=e.value in t.metadata?t.metadata[e.value]:null),e.value.startsWith("history_field_")){const n=e.value.replace("history_field_",""),a=(i=t.auxiliary_data)==null?void 0:i.find(o=>o.name===n);if(a&&!Array.isArray(a.value))return"".concat(Math.round(a.value*1e3)/1e3," ").concat(a.units)}if(r===null)return"--";switch(e.value==="slicer"&&(r+="<br />"+t.metadata.slicer_version),e.outputType){case"filesize":return Xe(r);case"date":return this.formatDateTime(r*1e3);case"time":return Is(r,!1);case"temp":return(r==null?void 0:r.toFixed())+" °C";case"length":return r>1e3?(r/1e3).toFixed(2)+" m":(r==null?void 0:r.toFixed(2))+" mm";default:return r}}createThumbnailUrl(e){let t="";return this.item.filename.lastIndexOf("/")!==-1&&(t=this.item.filename.substring(0,this.item.filename.lastIndexOf("/")+1)),"".concat(this.apiUrl,"/server/files/gcodes/").concat(Ie(t+e.relative_path),"?timestamp=").concat(this.item.metadata.modified)}};Ku([w({type:Object,required:!0})],Gi.prototype,"item",2);Ku([w({type:Array,required:!0})],Gi.prototype,"tableFields",2);Ku([w({type:Boolean,required:!0})],Gi.prototype,"isSelected",2);Gi=Ku([S({components:{AddBatchToQueueDialog:ri,HistoryListPanelNoteDialog:py,HistoryListPanelDetailsDialog:zf,Panel:U}})],Gi);var Lj=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("tr",{directives:[{name:"longpress",rawName:"v-longpress:600",value:r=>e.showContextMenu(r),expression:"(e) => showContextMenu(e)",arg:"600"}],key:e.item.job_id,class:e.cssClasses,on:{contextmenu:function(r){return e.showContextMenu(r)},click:function(r){e.detailsDialogBool=!0}}},[t("td",{staticClass:"pr-0"},[t(jr,{directives:[{name:"ripple",rawName:"v-ripple"}],staticClass:"pa-0 mr-0",attrs:{value:e.isSelected},on:{click:function(r){return r.stopPropagation(),e.select(!e.isSelected)}}})],1),t("td",{staticClass:"px-0 text-center",staticStyle:{width:"32px"}},[e.item.exists?e.smallThumbnail&&e.bigThumbnail?[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("vue-load-image",[t("img",e._g(e._b({attrs:{slot:"image",alt:e.item.filename,src:e.smallThumbnail,width:"32",height:"32"},slot:"image"},"img",i,!1),r)),t("div",{attrs:{slot:"preloader"},slot:"preloader"},[t(ot,{attrs:{indeterminate:"",color:"primary"}})],1),t("div",{attrs:{slot:"error"},slot:"error"},[t(_,[e._v(e._s(e.mdiFile))])],1)])]}}])},[t("span",[t("img",{attrs:{alt:e.item.filename,src:e.bigThumbnail,width:"250"}})])])]:e.smallThumbnail?[t("vue-load-image",[t("img",{attrs:{slot:"image",alt:e.item.filename,src:e.smallThumbnail,width:"32",height:"32"},slot:"image"}),t("div",{attrs:{slot:"preloader"},slot:"preloader"},[t(ot,{attrs:{indeterminate:"",color:"primary"}})],1),t("div",{attrs:{slot:"error"},slot:"error"},[t(_,[e._v(e._s(e.mdiFile))])],1)])]:[t(_,[e._v(e._s(e.mdiFile))])]:[t(_,{staticClass:"text--disabled"},[e._v(e._s(e.mdiFileCancel))])]],2),t("td",[e._v(e._s(e.item.filename))]),t("td",{staticClass:"text-right text-no-wrap"},["note"in e.item&&e.item.note?[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(_,e._g(e._b({staticClass:"mr-2",attrs:{small:""}},"v-icon",i,!1),r),[e._v(" "+e._s(e.mdiNoteTextOutline)+" ")])]}}],null,!1,3447416518)},[t("span",{domProps:{innerHTML:e._s(e.item.note.replaceAll("\n","<br />"))}})])]:e._e(),t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("span",e._g(e._b({},"span",i,!1),r),[t(_,{attrs:{small:"",color:e.statusColor,disabled:!e.item.exists}},[e._v(" "+e._s(e.statusIcon)+" ")])],1)]}}])},[t("span",[e._v(e._s(e.statusName))])])],2),e._l(e.tableFields,function(r){return t("td",{key:r.value,staticClass:"text-no-wrap",domProps:{innerHTML:e._s(e.outputValue(r,e.item))}})}),t(ye,{attrs:{"position-x":e.contextMenuX,"position-y":e.contextMenuY,absolute:"","offset-y":""},model:{value:e.contextMenuBool,callback:function(r){e.contextMenuBool=r},expression:"contextMenuBool"}},[t(Me,[t(J,{on:{click:function(r){e.detailsDialogBool=!0}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiTextBoxSearch))]),e._v(" "+e._s(e.$t("History.Details"))+" ")],1),e.item.note?t(J,{on:{click:e.editNote}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiNoteEditOutline))]),e._v(" "+e._s(e.$t("History.EditNote"))+" ")],1):t(J,{on:{click:e.createNote}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiNotePlusOutline))]),e._v(" "+e._s(e.$t("History.AddNote"))+" ")],1),e.item.exists?t(J,{attrs:{disabled:e.printerIsPrinting||!e.klipperReadyForGui},on:{click:e.startPrint}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPrinter))]),e._v(" "+e._s(e.$t("History.Reprint"))+" ")],1):e._e(),e.item.exists&&e.isJobQueueAvailable?t(J,{on:{click:e.addToQueue}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPlaylistPlus))]),e._v(" "+e._s(e.$t("Files.AddToQueue"))+" ")],1):e._e(),e.item.exists&&e.isJobQueueAvailable?t(J,{on:{click:function(r){e.addBatchToQueueDialogBool=!0}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiPlaylistPlus))]),e._v(" "+e._s(e.$t("Files.AddBatchToQueue"))+" ")],1):e._e(),t(J,{staticClass:"red--text",on:{click:e.deleteJob}},[t(_,{staticClass:"mr-1",attrs:{color:"error"}},[e._v(e._s(e.mdiDelete))]),e._v(" "+e._s(e.$t("History.Delete"))+" ")],1)],1)],1),t(zf,{attrs:{show:e.detailsDialogBool,job:e.item},on:{"close-dialog":function(r){e.detailsDialogBool=!1}}}),t(py,{attrs:{show:e.noteDialogBool,type:e.noteDialogType,job:e.item},on:{"close-dialog":function(r){e.noteDialogBool=!1}}}),t(ri,{attrs:{"is-visible":e.addBatchToQueueDialogBool,"show-toast":!0,filename:e.item.filename},on:{close:function(r){e.addBatchToQueueDialogBool=!1}}})],2)},Aj=[],Fj=E(Gi,Lj,Aj,!1,null,null);const fy=Fj.exports;var Rj=Object.getOwnPropertyDescriptor,Hj=(s,e,t,r)=>{for(var i=r>1?void 0:r?Rj(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Jr=class extends y{get hidePrintStatus(){var s;return(s=this.$store.state.gui.view.history.hidePrintStatus)!=null?s:[]}get allJobs(){var s;return(s=this.$store.state.server.history.jobs)!=null?s:[]}get jobs(){return this.allJobs.filter(s=>!this.hidePrintStatus.includes(s.status))}get selectedJobs(){var e;return((e=this.$store.state.gui.view.history.selectedJobs)!=null?e:[]).filter(t=>t.type==="job")}get moonrakerHistoryFields(){var r,i;const s=(i=(r=this.$store.state.server.config)==null?void 0:r.config)!=null?i:{},e=Object.keys(s).filter(n=>n.startsWith("sensor ")),t=[];return e.forEach(n=>{var o;const a=(o=s[n])!=null?o:{};Object.keys(a).filter(l=>l.startsWith("history_field_")).forEach(l=>{const u=a[l];t.push({desc:u.desc,unit:u.units,provider:n,parameter:u.parameter,name:l})})}),t}};Jr=Hj([S],Jr);const jj=(s,e,t)=>{const r=s[e];return r?typeof r=="function"?r():Promise.resolve(r):new Promise((i,n)=>{(typeof queueMicrotask=="function"?queueMicrotask:setTimeout)(n.bind(null,new Error("Unknown variable dynamic import: "+e+(e.split("/").length!==t?". Note that variables only represent file names one level deep.":""))))})};/*!
|
||
* vue-i18n v8.28.2
|
||
* (c) 2022 kazuya kawaguchi
|
||
* Released under the MIT License.
|
||
*/var gy=["compactDisplay","currency","currencyDisplay","currencySign","localeMatcher","notation","numberingSystem","signDisplay","style","unit","unitDisplay","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits"],Ij=["dateStyle","timeStyle","calendar","localeMatcher","hour12","hourCycle","timeZone","formatMatcher","weekday","era","year","month","day","hour","minute","second","timeZoneName"];function Zi(s,e){typeof console<"u"&&console.warn("[vue-i18n] "+s)}function Nj(s,e){typeof console<"u"&&console.error("[vue-i18n] "+s)}var Ds=Array.isArray;function ts(s){return s!==null&&typeof s=="object"}function Vj(s){return typeof s=="boolean"}function lt(s){return typeof s=="string"}var Bj=Object.prototype.toString,Uj="[object Object]";function ws(s){return Bj.call(s)===Uj}function Et(s){return s==null}function Ah(s){return typeof s=="function"}function Qu(){for(var s=[],e=arguments.length;e--;)s[e]=arguments[e];var t=null,r=null;return s.length===1?ts(s[0])||Ds(s[0])?r=s[0]:typeof s[0]=="string"&&(t=s[0]):s.length===2&&(typeof s[0]=="string"&&(t=s[0]),(ts(s[1])||Ds(s[1]))&&(r=s[1])),{locale:t,params:r}}function pn(s){return JSON.parse(JSON.stringify(s))}function Wj(s,e){if(s.delete(e))return s}function zj(s){var e=[];return s.forEach(function(t){return e.push(t)}),e}function co(s,e){return!!~s.indexOf(e)}var Gj=Object.prototype.hasOwnProperty;function Zj(s,e){return Gj.call(s,e)}function Fr(s){for(var e=arguments,t=Object(s),r=1;r<arguments.length;r++){var i=e[r];if(i!=null){var n=void 0;for(n in i)Zj(i,n)&&(ts(i[n])?t[n]=Fr(t[n],i[n]):t[n]=i[n])}}return t}function bc(s,e){if(s===e)return!0;var t=ts(s),r=ts(e);if(t&&r)try{var i=Ds(s),n=Ds(e);if(i&&n)return s.length===e.length&&s.every(function(l,u){return bc(l,e[u])});if(!i&&!n){var a=Object.keys(s),o=Object.keys(e);return a.length===o.length&&a.every(function(l){return bc(s[l],e[l])})}else return!1}catch{return!1}else return!t&&!r?String(s)===String(e):!1}function qj(s){return s.replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function Xj(s){return s!=null&&Object.keys(s).forEach(function(e){typeof s[e]=="string"&&(s[e]=qj(s[e]))}),s}function Yj(s){s.prototype.hasOwnProperty("$i18n")||Object.defineProperty(s.prototype,"$i18n",{get:function(){return this._i18n}}),s.prototype.$t=function(e){for(var t=[],r=arguments.length-1;r-- >0;)t[r]=arguments[r+1];var i=this.$i18n;return i._t.apply(i,[e,i.locale,i._getMessages(),this].concat(t))},s.prototype.$tc=function(e,t){for(var r=[],i=arguments.length-2;i-- >0;)r[i]=arguments[i+2];var n=this.$i18n;return n._tc.apply(n,[e,n.locale,n._getMessages(),this,t].concat(r))},s.prototype.$te=function(e,t){var r=this.$i18n;return r._te(e,r.locale,r._getMessages(),t)},s.prototype.$d=function(e){for(var t,r=[],i=arguments.length-1;i-- >0;)r[i]=arguments[i+1];return(t=this.$i18n).d.apply(t,[e].concat(r))},s.prototype.$n=function(e){for(var t,r=[],i=arguments.length-1;i-- >0;)r[i]=arguments[i+1];return(t=this.$i18n).n.apply(t,[e].concat(r))}}function Jj(s){s===void 0&&(s=!1);function e(){this!==this.$root&&this.$options.__INTLIFY_META__&&this.$el&&this.$el.setAttribute("data-intlify",this.$options.__INTLIFY_META__)}return s?{mounted:e}:{beforeCreate:function(){var r=this.$options;if(r.i18n=r.i18n||(r.__i18nBridge||r.__i18n?{}:null),r.i18n){if(r.i18n instanceof ce){if(r.__i18nBridge||r.__i18n)try{var i=r.i18n&&r.i18n.messages?r.i18n.messages:{},n=r.__i18nBridge||r.__i18n;n.forEach(function(d){i=Fr(i,JSON.parse(d))}),Object.keys(i).forEach(function(d){r.i18n.mergeLocaleMessage(d,i[d])})}catch{}this._i18n=r.i18n,this._i18nWatcher=this._i18n.watchI18nData()}else if(ws(r.i18n)){var a=this.$root&&this.$root.$i18n&&this.$root.$i18n instanceof ce?this.$root.$i18n:null;if(a&&(r.i18n.root=this.$root,r.i18n.formatter=a.formatter,r.i18n.fallbackLocale=a.fallbackLocale,r.i18n.formatFallbackMessages=a.formatFallbackMessages,r.i18n.silentTranslationWarn=a.silentTranslationWarn,r.i18n.silentFallbackWarn=a.silentFallbackWarn,r.i18n.pluralizationRules=a.pluralizationRules,r.i18n.preserveDirectiveContent=a.preserveDirectiveContent),r.__i18nBridge||r.__i18n)try{var o=r.i18n&&r.i18n.messages?r.i18n.messages:{},l=r.__i18nBridge||r.__i18n;l.forEach(function(d){o=Fr(o,JSON.parse(d))}),r.i18n.messages=o}catch{}var u=r.i18n,c=u.sharedMessages;c&&ws(c)&&(r.i18n.messages=Fr(r.i18n.messages,c)),this._i18n=new ce(r.i18n),this._i18nWatcher=this._i18n.watchI18nData(),(r.i18n.sync===void 0||r.i18n.sync)&&(this._localeWatcher=this.$i18n.watchLocale()),a&&a.onComponentInstanceCreated(this._i18n)}}else this.$root&&this.$root.$i18n&&this.$root.$i18n instanceof ce?this._i18n=this.$root.$i18n:r.parent&&r.parent.$i18n&&r.parent.$i18n instanceof ce&&(this._i18n=r.parent.$i18n)},beforeMount:function(){var r=this.$options;r.i18n=r.i18n||(r.__i18nBridge||r.__i18n?{}:null),r.i18n?r.i18n instanceof ce?(this._i18n.subscribeDataChanging(this),this._subscribing=!0):ws(r.i18n)&&(this._i18n.subscribeDataChanging(this),this._subscribing=!0):this.$root&&this.$root.$i18n&&this.$root.$i18n instanceof ce?(this._i18n.subscribeDataChanging(this),this._subscribing=!0):r.parent&&r.parent.$i18n&&r.parent.$i18n instanceof ce&&(this._i18n.subscribeDataChanging(this),this._subscribing=!0)},mounted:e,beforeDestroy:function(){if(this._i18n){var r=this;this.$nextTick(function(){r._subscribing&&(r._i18n.unsubscribeDataChanging(r),delete r._subscribing),r._i18nWatcher&&(r._i18nWatcher(),r._i18n.destroyVM(),delete r._i18nWatcher),r._localeWatcher&&(r._localeWatcher(),delete r._localeWatcher)})}}}}var d1={name:"i18n",functional:!0,props:{tag:{type:[String,Boolean,Object],default:"span"},path:{type:String,required:!0},locale:{type:String},places:{type:[Array,Object]}},render:function(e,t){var r=t.data,i=t.parent,n=t.props,a=t.slots,o=i.$i18n;if(o){var l=n.path,u=n.locale,c=n.places,d=a(),m=o.i(l,u,Kj(d)||c?Qj(d.default,c):d),h=n.tag&&n.tag!==!0||n.tag===!1?n.tag:"span";return h?e(h,r,m):m}}};function Kj(s){var e;for(e in s)if(e!=="default")return!1;return!!e}function Qj(s,e){var t=e?eI(e):{};if(!s)return t;s=s.filter(function(i){return i.tag||i.text.trim()!==""});var r=s.every(sI);return s.reduce(r?tI:_y,t)}function eI(s){return Array.isArray(s)?s.reduce(_y,{}):Object.assign({},s)}function tI(s,e){return e.data&&e.data.attrs&&e.data.attrs.place&&(s[e.data.attrs.place]=e),s}function _y(s,e,t){return s[t]=e,s}function sI(s){return!!(s.data&&s.data.attrs&&s.data.attrs.place)}var m1={name:"i18n-n",functional:!0,props:{tag:{type:[String,Boolean,Object],default:"span"},value:{type:Number,required:!0},format:{type:[String,Object]},locale:{type:String}},render:function(e,t){var r=t.props,i=t.parent,n=t.data,a=i.$i18n;if(!a)return null;var o=null,l=null;lt(r.format)?o=r.format:ts(r.format)&&(r.format.key&&(o=r.format.key),l=Object.keys(r.format).reduce(function(h,f){var p;return co(gy,f)?Object.assign({},h,(p={},p[f]=r.format[f],p)):h},null));var u=r.locale||a.locale,c=a._ntp(r.value,u,o,l),d=c.map(function(h,f){var p,v=n.scopedSlots&&n.scopedSlots[h.type];return v?v((p={},p[h.type]=h.value,p.index=f,p.parts=c,p)):h.value}),m=r.tag&&r.tag!==!0||r.tag===!1?r.tag:"span";return m?e(m,{attrs:n.attrs,class:n.class,staticClass:n.staticClass},d):d}};function rI(s,e,t){vy(s,t)&&by(s,e,t)}function iI(s,e,t,r){if(vy(s,t)){var i=t.context.$i18n;aI(s,t)&&bc(e.value,e.oldValue)&&bc(s._localeMessage,i.getLocaleMessage(i.locale))||by(s,e,t)}}function nI(s,e,t,r){var i=t.context;if(!i){Zi("Vue instance does not exists in VNode context");return}var n=t.context.$i18n||{};!e.modifiers.preserve&&!n.preserveDirectiveContent&&(s.textContent=""),s._vt=void 0,delete s._vt,s._locale=void 0,delete s._locale,s._localeMessage=void 0,delete s._localeMessage}function vy(s,e){var t=e.context;return t?t.$i18n?!0:(Zi("VueI18n instance does not exists in Vue instance"),!1):(Zi("Vue instance does not exists in VNode context"),!1)}function aI(s,e){var t=e.context;return s._locale===t.$i18n.locale}function by(s,e,t){var r,i,n=e.value,a=oI(n),o=a.path,l=a.locale,u=a.args,c=a.choice;if(!o&&!l&&!u){Zi("value type not supported");return}if(!o){Zi("`path` is required in v-t directive");return}var d=t.context;c!=null?s._vt=s.textContent=(r=d.$i18n).tc.apply(r,[o,c].concat(h1(l,u))):s._vt=s.textContent=(i=d.$i18n).t.apply(i,[o].concat(h1(l,u))),s._locale=d.$i18n.locale,s._localeMessage=d.$i18n.getLocaleMessage(d.$i18n.locale)}function oI(s){var e,t,r,i;return lt(s)?e=s:ws(s)&&(e=s.path,t=s.locale,r=s.args,i=s.choice),{path:e,locale:t,args:r,choice:i}}function h1(s,e){var t=[];return s&&t.push(s),e&&(Array.isArray(e)||ws(e))&&t.push(e),t}var Ct;function Gf(s,e){e===void 0&&(e={bridge:!1}),Gf.installed=!0,Ct=s,Ct.version&&Number(Ct.version.split(".")[0]),Yj(Ct),Ct.mixin(Jj(e.bridge)),Ct.directive("t",{bind:rI,update:iI,unbind:nI}),Ct.component(d1.name,d1),Ct.component(m1.name,m1);var t=Ct.config.optionMergeStrategies;t.i18n=function(r,i){return i===void 0?r:i}}var yy=function(){this._caches=Object.create(null)};yy.prototype.interpolate=function(e,t){if(!t)return[e];var r=this._caches[e];return r||(r=uI(e),this._caches[e]=r),dI(r,t)};var lI=/^(?:\d)+/,cI=/^(?:\w)+/;function uI(s){for(var e=[],t=0,r="";t<s.length;){var i=s[t++];if(i==="{"){r&&e.push({type:"text",value:r}),r="";var n="";for(i=s[t++];i!==void 0&&i!=="}";)n+=i,i=s[t++];var a=i==="}",o=lI.test(n)?"list":a&&cI.test(n)?"named":"unknown";e.push({value:n,type:o})}else i==="%"?s[t]!=="{"&&(r+=i):r+=i}return r&&e.push({type:"text",value:r}),e}function dI(s,e){var t=[],r=0,i=Array.isArray(e)?"list":ts(e)?"named":"unknown";if(i==="unknown")return t;for(;r<s.length;){var n=s[r];switch(n.type){case"text":t.push(n.value);break;case"list":t.push(e[parseInt(n.value,10)]);break;case"named":i==="named"&&t.push(e[n.value]);break}r++}return t}var at=0,bi=1,Cy=2,$y=3,Fh=0,yc=1,Cc=2,er=3,Fs=4,$c=5,xc=6,ed=7,Ta=8,br=[];br[Fh]={ws:[Fh],ident:[er,at],"[":[Fs],eof:[ed]};br[yc]={ws:[yc],".":[Cc],"[":[Fs],eof:[ed]};br[Cc]={ws:[Cc],ident:[er,at],0:[er,at],number:[er,at]};br[er]={ident:[er,at],0:[er,at],number:[er,at],ws:[yc,bi],".":[Cc,bi],"[":[Fs,bi],eof:[ed,bi]};br[Fs]={"'":[$c,at],'"':[xc,at],"[":[Fs,Cy],"]":[yc,$y],eof:Ta,else:[Fs,at]};br[$c]={"'":[Fs,at],eof:Ta,else:[$c,at]};br[xc]={'"':[Fs,at],eof:Ta,else:[xc,at]};var mI=/^\s?(?:true|false|-?[\d.]+|'[^']*'|"[^"]*")\s?$/;function hI(s){return mI.test(s)}function pI(s){var e=s.charCodeAt(0),t=s.charCodeAt(s.length-1);return e===t&&(e===34||e===39)?s.slice(1,-1):s}function fI(s){if(s==null)return"eof";var e=s.charCodeAt(0);switch(e){case 91:case 93:case 46:case 34:case 39:return s;case 95:case 36:case 45:return"ident";case 9:case 10:case 13:case 160:case 65279:case 8232:case 8233:return"ws"}return"ident"}function gI(s){var e=s.trim();return s.charAt(0)==="0"&&isNaN(s)?!1:hI(e)?pI(e):"*"+e}function _I(s){var e=[],t=-1,r=Fh,i=0,n,a,o,l,u,c,d,m=[];m[bi]=function(){a!==void 0&&(e.push(a),a=void 0)},m[at]=function(){a===void 0?a=o:a+=o},m[Cy]=function(){m[at](),i++},m[$y]=function(){if(i>0)i--,r=Fs,m[at]();else{if(i=0,a===void 0||(a=gI(a),a===!1))return!1;m[bi]()}};function h(){var f=s[t+1];if(r===$c&&f==="'"||r===xc&&f==='"')return t++,o="\\"+f,m[at](),!0}for(;r!==null;)if(t++,n=s[t],!(n==="\\"&&h())){if(l=fI(n),d=br[r],u=d[l]||d.else||Ta,u===Ta||(r=u[0],c=m[u[1]],c&&(o=u[2],o=o===void 0?n:o,c()===!1)))return;if(r===ed)return e}}var Zf=function(){this._cache=Object.create(null)};Zf.prototype.parsePath=function(e){var t=this._cache[e];return t||(t=_I(e),t&&(this._cache[e]=t)),t||[]};Zf.prototype.getPathValue=function(e,t){if(!ts(e))return null;var r=this.parsePath(t);if(r.length===0)return null;for(var i=r.length,n=e,a=0;a<i;){var o=n[r[a]];if(o==null)return null;n=o,a++}return n};var vI=/<\/?[\w\s="/.':;#-\/]+>/,bI=/(?:@(?:\.[a-zA-Z]+)?:(?:[\w\-_|./]+|\([\w\-_:|./]+\)))/g,yI=/^@(?:\.([a-zA-Z]+))?:/,CI=/[()]/g,p1={upper:function(s){return s.toLocaleUpperCase()},lower:function(s){return s.toLocaleLowerCase()},capitalize:function(s){return""+s.charAt(0).toLocaleUpperCase()+s.substr(1)}},Rh=new yy,ce=function(e){var t=this;e===void 0&&(e={}),!Ct&&typeof window<"u"&&window.Vue&&Gf(window.Vue);var r=e.locale||"en-US",i=e.fallbackLocale===!1?!1:e.fallbackLocale||"en-US",n=e.messages||{},a=e.dateTimeFormats||e.datetimeFormats||{},o=e.numberFormats||{};this._vm=null,this._formatter=e.formatter||Rh,this._modifiers=e.modifiers||{},this._missing=e.missing||null,this._root=e.root||null,this._sync=e.sync===void 0?!0:!!e.sync,this._fallbackRoot=e.fallbackRoot===void 0?!0:!!e.fallbackRoot,this._fallbackRootWithEmptyString=e.fallbackRootWithEmptyString===void 0?!0:!!e.fallbackRootWithEmptyString,this._formatFallbackMessages=e.formatFallbackMessages===void 0?!1:!!e.formatFallbackMessages,this._silentTranslationWarn=e.silentTranslationWarn===void 0?!1:e.silentTranslationWarn,this._silentFallbackWarn=e.silentFallbackWarn===void 0?!1:!!e.silentFallbackWarn,this._dateTimeFormatters={},this._numberFormatters={},this._path=new Zf,this._dataListeners=new Set,this._componentInstanceCreatedListener=e.componentInstanceCreatedListener||null,this._preserveDirectiveContent=e.preserveDirectiveContent===void 0?!1:!!e.preserveDirectiveContent,this.pluralizationRules=e.pluralizationRules||{},this._warnHtmlInMessage=e.warnHtmlInMessage||"off",this._postTranslation=e.postTranslation||null,this._escapeParameterHtml=e.escapeParameterHtml||!1,"__VUE_I18N_BRIDGE__"in e&&(this.__VUE_I18N_BRIDGE__=e.__VUE_I18N_BRIDGE__),this.getChoiceIndex=function(l,u){var c=Object.getPrototypeOf(t);if(c&&c.getChoiceIndex){var d=c.getChoiceIndex;return d.call(t,l,u)}var m=function(h,f){return h=Math.abs(h),f===2?h?h>1?1:0:1:h?Math.min(h,2):0};return t.locale in t.pluralizationRules?t.pluralizationRules[t.locale].apply(t,[l,u]):m(l,u)},this._exist=function(l,u){return!l||!u?!1:!!(!Et(t._path.getPathValue(l,u))||l[u])},(this._warnHtmlInMessage==="warn"||this._warnHtmlInMessage==="error")&&Object.keys(n).forEach(function(l){t._checkLocaleMessage(l,t._warnHtmlInMessage,n[l])}),this._initVM({locale:r,fallbackLocale:i,messages:n,dateTimeFormats:a,numberFormats:o})},Ae={vm:{configurable:!0},messages:{configurable:!0},dateTimeFormats:{configurable:!0},numberFormats:{configurable:!0},availableLocales:{configurable:!0},locale:{configurable:!0},fallbackLocale:{configurable:!0},formatFallbackMessages:{configurable:!0},missing:{configurable:!0},formatter:{configurable:!0},silentTranslationWarn:{configurable:!0},silentFallbackWarn:{configurable:!0},preserveDirectiveContent:{configurable:!0},warnHtmlInMessage:{configurable:!0},postTranslation:{configurable:!0},sync:{configurable:!0}};ce.prototype._checkLocaleMessage=function(e,t,r){var i=[],n=function(a,o,l,u){if(ws(l))Object.keys(l).forEach(function(m){var h=l[m];ws(h)?(u.push(m),u.push("."),n(a,o,h,u),u.pop(),u.pop()):(u.push(m),n(a,o,h,u),u.pop())});else if(Ds(l))l.forEach(function(m,h){ws(m)?(u.push("["+h+"]"),u.push("."),n(a,o,m,u),u.pop(),u.pop()):(u.push("["+h+"]"),n(a,o,m,u),u.pop())});else if(lt(l)){var c=vI.test(l);if(c){var d="Detected HTML in message '"+l+"' of keypath '"+u.join("")+"' at '"+o+"'. Consider component interpolation with '<i18n>' to avoid XSS. See https://bit.ly/2ZqJzkp";a==="warn"?Zi(d):a==="error"&&Nj(d)}}};n(t,e,r,i)};ce.prototype._initVM=function(e){var t=Ct.config.silent;Ct.config.silent=!0,this._vm=new Ct({data:e,__VUE18N__INSTANCE__:!0}),Ct.config.silent=t};ce.prototype.destroyVM=function(){this._vm.$destroy()};ce.prototype.subscribeDataChanging=function(e){this._dataListeners.add(e)};ce.prototype.unsubscribeDataChanging=function(e){Wj(this._dataListeners,e)};ce.prototype.watchI18nData=function(){var e=this;return this._vm.$watch("$data",function(){for(var t=zj(e._dataListeners),r=t.length;r--;)Ct.nextTick(function(){t[r]&&t[r].$forceUpdate()})},{deep:!0})};ce.prototype.watchLocale=function(e){if(e){if(!this.__VUE_I18N_BRIDGE__)return null;var r=this,i=this._vm;return this.vm.$watch("locale",function(n){i.$set(i,"locale",n),r.__VUE_I18N_BRIDGE__&&e&&(e.locale.value=n),i.$forceUpdate()},{immediate:!0})}else{if(!this._sync||!this._root)return null;var t=this._vm;return this._root.$i18n.vm.$watch("locale",function(n){t.$set(t,"locale",n),t.$forceUpdate()},{immediate:!0})}};ce.prototype.onComponentInstanceCreated=function(e){this._componentInstanceCreatedListener&&this._componentInstanceCreatedListener(e,this)};Ae.vm.get=function(){return this._vm};Ae.messages.get=function(){return pn(this._getMessages())};Ae.dateTimeFormats.get=function(){return pn(this._getDateTimeFormats())};Ae.numberFormats.get=function(){return pn(this._getNumberFormats())};Ae.availableLocales.get=function(){return Object.keys(this.messages).sort()};Ae.locale.get=function(){return this._vm.locale};Ae.locale.set=function(s){this._vm.$set(this._vm,"locale",s)};Ae.fallbackLocale.get=function(){return this._vm.fallbackLocale};Ae.fallbackLocale.set=function(s){this._localeChainCache={},this._vm.$set(this._vm,"fallbackLocale",s)};Ae.formatFallbackMessages.get=function(){return this._formatFallbackMessages};Ae.formatFallbackMessages.set=function(s){this._formatFallbackMessages=s};Ae.missing.get=function(){return this._missing};Ae.missing.set=function(s){this._missing=s};Ae.formatter.get=function(){return this._formatter};Ae.formatter.set=function(s){this._formatter=s};Ae.silentTranslationWarn.get=function(){return this._silentTranslationWarn};Ae.silentTranslationWarn.set=function(s){this._silentTranslationWarn=s};Ae.silentFallbackWarn.get=function(){return this._silentFallbackWarn};Ae.silentFallbackWarn.set=function(s){this._silentFallbackWarn=s};Ae.preserveDirectiveContent.get=function(){return this._preserveDirectiveContent};Ae.preserveDirectiveContent.set=function(s){this._preserveDirectiveContent=s};Ae.warnHtmlInMessage.get=function(){return this._warnHtmlInMessage};Ae.warnHtmlInMessage.set=function(s){var e=this,t=this._warnHtmlInMessage;if(this._warnHtmlInMessage=s,t!==s&&(s==="warn"||s==="error")){var r=this._getMessages();Object.keys(r).forEach(function(i){e._checkLocaleMessage(i,e._warnHtmlInMessage,r[i])})}};Ae.postTranslation.get=function(){return this._postTranslation};Ae.postTranslation.set=function(s){this._postTranslation=s};Ae.sync.get=function(){return this._sync};Ae.sync.set=function(s){this._sync=s};ce.prototype._getMessages=function(){return this._vm.messages};ce.prototype._getDateTimeFormats=function(){return this._vm.dateTimeFormats};ce.prototype._getNumberFormats=function(){return this._vm.numberFormats};ce.prototype._warnDefault=function(e,t,r,i,n,a){if(!Et(r))return r;if(this._missing){var o=this._missing.apply(null,[e,t,i,n]);if(lt(o))return o}if(this._formatFallbackMessages){var l=Qu.apply(void 0,n);return this._render(t,a,l.params,t)}else return t};ce.prototype._isFallbackRoot=function(e){return(this._fallbackRootWithEmptyString?!e:Et(e))&&!Et(this._root)&&this._fallbackRoot};ce.prototype._isSilentFallbackWarn=function(e){return this._silentFallbackWarn instanceof RegExp?this._silentFallbackWarn.test(e):this._silentFallbackWarn};ce.prototype._isSilentFallback=function(e,t){return this._isSilentFallbackWarn(t)&&(this._isFallbackRoot()||e!==this.fallbackLocale)};ce.prototype._isSilentTranslationWarn=function(e){return this._silentTranslationWarn instanceof RegExp?this._silentTranslationWarn.test(e):this._silentTranslationWarn};ce.prototype._interpolate=function(e,t,r,i,n,a,o){if(!t)return null;var l=this._path.getPathValue(t,r);if(Ds(l)||ws(l))return l;var u;if(Et(l))if(ws(t)){if(u=t[r],!(lt(u)||Ah(u)))return null}else return null;else if(lt(l)||Ah(l))u=l;else return null;return lt(u)&&(u.indexOf("@:")>=0||u.indexOf("@.")>=0)&&(u=this._link(e,t,u,i,"raw",a,o)),this._render(u,n,a,r)};ce.prototype._link=function(e,t,r,i,n,a,o){var l=r,u=l.match(bI);for(var c in u)if(u.hasOwnProperty(c)){var d=u[c],m=d.match(yI),h=m[0],f=m[1],p=d.replace(h,"").replace(CI,"");if(co(o,p))return l;o.push(p);var v=this._interpolate(e,t,p,i,n==="raw"?"string":n,n==="raw"?void 0:a,o);if(this._isFallbackRoot(v)){if(!this._root)throw Error("unexpected error");var C=this._root.$i18n;v=C._translate(C._getMessages(),C.locale,C.fallbackLocale,p,i,n,a)}v=this._warnDefault(e,p,v,i,Ds(a)?a:[a],n),this._modifiers.hasOwnProperty(f)?v=this._modifiers[f](v):p1.hasOwnProperty(f)&&(v=p1[f](v)),o.pop(),l=v?l.replace(d,v):l}return l};ce.prototype._createMessageContext=function(e,t,r,i){var n=this,a=Ds(e)?e:[],o=ts(e)?e:{},l=function(m){return a[m]},u=function(m){return o[m]},c=this._getMessages(),d=this.locale;return{list:l,named:u,values:e,formatter:t,path:r,messages:c,locale:d,linked:function(m){return n._interpolate(d,c[d]||{},m,null,i,void 0,[m])}}};ce.prototype._render=function(e,t,r,i){if(Ah(e))return e(this._createMessageContext(r,this._formatter||Rh,i,t));var n=this._formatter.interpolate(e,r,i);return n||(n=Rh.interpolate(e,r,i)),t==="string"&&!lt(n)?n.join(""):n};ce.prototype._appendItemToChain=function(e,t,r){var i=!1;return co(e,t)||(i=!0,t&&(i=t[t.length-1]!=="!",t=t.replace(/!/g,""),e.push(t),r&&r[t]&&(i=r[t]))),i};ce.prototype._appendLocaleToChain=function(e,t,r){var i,n=t.split("-");do{var a=n.join("-");i=this._appendItemToChain(e,a,r),n.splice(-1,1)}while(n.length&&i===!0);return i};ce.prototype._appendBlockToChain=function(e,t,r){for(var i=!0,n=0;n<t.length&&Vj(i);n++){var a=t[n];lt(a)&&(i=this._appendLocaleToChain(e,a,r))}return i};ce.prototype._getLocaleChain=function(e,t){if(e==="")return[];this._localeChainCache||(this._localeChainCache={});var r=this._localeChainCache[e];if(!r){t||(t=this.fallbackLocale),r=[];for(var i=[e];Ds(i);)i=this._appendBlockToChain(r,i,t);var n;Ds(t)?n=t:ts(t)?t.default?n=t.default:n=null:n=t,lt(n)?i=[n]:i=n,i&&this._appendBlockToChain(r,i,null),this._localeChainCache[e]=r}return r};ce.prototype._translate=function(e,t,r,i,n,a,o){for(var l=this._getLocaleChain(t,r),u,c=0;c<l.length;c++){var d=l[c];if(u=this._interpolate(d,e[d],i,n,a,o,[i]),!Et(u))return u}return null};ce.prototype._t=function(e,t,r,i){for(var n,a=[],o=arguments.length-4;o-- >0;)a[o]=arguments[o+4];if(!e)return"";var l=Qu.apply(void 0,a);this._escapeParameterHtml&&(l.params=Xj(l.params));var u=l.locale||t,c=this._translate(r,u,this.fallbackLocale,e,i,"string",l.params);if(this._isFallbackRoot(c)){if(!this._root)throw Error("unexpected error");return(n=this._root).$t.apply(n,[e].concat(a))}else return c=this._warnDefault(u,e,c,i,a,"string"),this._postTranslation&&c!==null&&c!==void 0&&(c=this._postTranslation(c,e)),c};ce.prototype.t=function(e){for(var t,r=[],i=arguments.length-1;i-- >0;)r[i]=arguments[i+1];return(t=this)._t.apply(t,[e,this.locale,this._getMessages(),null].concat(r))};ce.prototype._i=function(e,t,r,i,n){var a=this._translate(r,t,this.fallbackLocale,e,i,"raw",n);if(this._isFallbackRoot(a)){if(!this._root)throw Error("unexpected error");return this._root.$i18n.i(e,t,n)}else return this._warnDefault(t,e,a,i,[n],"raw")};ce.prototype.i=function(e,t,r){return e?(lt(t)||(t=this.locale),this._i(e,t,this._getMessages(),null,r)):""};ce.prototype._tc=function(e,t,r,i,n){for(var a,o=[],l=arguments.length-5;l-- >0;)o[l]=arguments[l+5];if(!e)return"";n===void 0&&(n=1);var u={count:n,n},c=Qu.apply(void 0,o);return c.params=Object.assign(u,c.params),o=c.locale===null?[c.params]:[c.locale,c.params],this.fetchChoice((a=this)._t.apply(a,[e,t,r,i].concat(o)),n)};ce.prototype.fetchChoice=function(e,t){if(!e||!lt(e))return null;var r=e.split("|");return t=this.getChoiceIndex(t,r.length),r[t]?r[t].trim():e};ce.prototype.tc=function(e,t){for(var r,i=[],n=arguments.length-2;n-- >0;)i[n]=arguments[n+2];return(r=this)._tc.apply(r,[e,this.locale,this._getMessages(),null,t].concat(i))};ce.prototype._te=function(e,t,r){for(var i=[],n=arguments.length-3;n-- >0;)i[n]=arguments[n+3];var a=Qu.apply(void 0,i).locale||t;return this._exist(r[a],e)};ce.prototype.te=function(e,t){return this._te(e,this.locale,this._getMessages(),t)};ce.prototype.getLocaleMessage=function(e){return pn(this._vm.messages[e]||{})};ce.prototype.setLocaleMessage=function(e,t){(this._warnHtmlInMessage==="warn"||this._warnHtmlInMessage==="error")&&this._checkLocaleMessage(e,this._warnHtmlInMessage,t),this._vm.$set(this._vm.messages,e,t)};ce.prototype.mergeLocaleMessage=function(e,t){(this._warnHtmlInMessage==="warn"||this._warnHtmlInMessage==="error")&&this._checkLocaleMessage(e,this._warnHtmlInMessage,t),this._vm.$set(this._vm.messages,e,Fr(typeof this._vm.messages[e]<"u"&&Object.keys(this._vm.messages[e]).length?Object.assign({},this._vm.messages[e]):{},t))};ce.prototype.getDateTimeFormat=function(e){return pn(this._vm.dateTimeFormats[e]||{})};ce.prototype.setDateTimeFormat=function(e,t){this._vm.$set(this._vm.dateTimeFormats,e,t),this._clearDateTimeFormat(e,t)};ce.prototype.mergeDateTimeFormat=function(e,t){this._vm.$set(this._vm.dateTimeFormats,e,Fr(this._vm.dateTimeFormats[e]||{},t)),this._clearDateTimeFormat(e,t)};ce.prototype._clearDateTimeFormat=function(e,t){for(var r in t){var i=e+"__"+r;this._dateTimeFormatters.hasOwnProperty(i)&&delete this._dateTimeFormatters[i]}};ce.prototype._localizeDateTime=function(e,t,r,i,n,a){for(var o=t,l=i[o],u=this._getLocaleChain(t,r),c=0;c<u.length;c++){var d=u[c];if(l=i[d],o=d,!(Et(l)||Et(l[n])))break}if(Et(l)||Et(l[n]))return null;var m=l[n],h;if(a)h=new Intl.DateTimeFormat(o,Object.assign({},m,a));else{var f=o+"__"+n;h=this._dateTimeFormatters[f],h||(h=this._dateTimeFormatters[f]=new Intl.DateTimeFormat(o,m))}return h.format(e)};ce.prototype._d=function(e,t,r,i){if(!r){var n=i?new Intl.DateTimeFormat(t,i):new Intl.DateTimeFormat(t);return n.format(e)}var a=this._localizeDateTime(e,t,this.fallbackLocale,this._getDateTimeFormats(),r,i);if(this._isFallbackRoot(a)){if(!this._root)throw Error("unexpected error");return this._root.$i18n.d(e,r,t)}else return a||""};ce.prototype.d=function(e){for(var t=[],r=arguments.length-1;r-- >0;)t[r]=arguments[r+1];var i=this.locale,n=null,a=null;return t.length===1?(lt(t[0])?n=t[0]:ts(t[0])&&(t[0].locale&&(i=t[0].locale),t[0].key&&(n=t[0].key)),a=Object.keys(t[0]).reduce(function(o,l){var u;return co(Ij,l)?Object.assign({},o,(u={},u[l]=t[0][l],u)):o},null)):t.length===2&&(lt(t[0])&&(n=t[0]),lt(t[1])&&(i=t[1])),this._d(e,i,n,a)};ce.prototype.getNumberFormat=function(e){return pn(this._vm.numberFormats[e]||{})};ce.prototype.setNumberFormat=function(e,t){this._vm.$set(this._vm.numberFormats,e,t),this._clearNumberFormat(e,t)};ce.prototype.mergeNumberFormat=function(e,t){this._vm.$set(this._vm.numberFormats,e,Fr(this._vm.numberFormats[e]||{},t)),this._clearNumberFormat(e,t)};ce.prototype._clearNumberFormat=function(e,t){for(var r in t){var i=e+"__"+r;this._numberFormatters.hasOwnProperty(i)&&delete this._numberFormatters[i]}};ce.prototype._getNumberFormatter=function(e,t,r,i,n,a){for(var o=t,l=i[o],u=this._getLocaleChain(t,r),c=0;c<u.length;c++){var d=u[c];if(l=i[d],o=d,!(Et(l)||Et(l[n])))break}if(Et(l)||Et(l[n]))return null;var m=l[n],h;if(a)h=new Intl.NumberFormat(o,Object.assign({},m,a));else{var f=o+"__"+n;h=this._numberFormatters[f],h||(h=this._numberFormatters[f]=new Intl.NumberFormat(o,m))}return h};ce.prototype._n=function(e,t,r,i){if(!ce.availabilities.numberFormat)return"";if(!r){var n=i?new Intl.NumberFormat(t,i):new Intl.NumberFormat(t);return n.format(e)}var a=this._getNumberFormatter(e,t,this.fallbackLocale,this._getNumberFormats(),r,i),o=a&&a.format(e);if(this._isFallbackRoot(o)){if(!this._root)throw Error("unexpected error");return this._root.$i18n.n(e,Object.assign({},{key:r,locale:t},i))}else return o||""};ce.prototype.n=function(e){for(var t=[],r=arguments.length-1;r-- >0;)t[r]=arguments[r+1];var i=this.locale,n=null,a=null;return t.length===1?lt(t[0])?n=t[0]:ts(t[0])&&(t[0].locale&&(i=t[0].locale),t[0].key&&(n=t[0].key),a=Object.keys(t[0]).reduce(function(o,l){var u;return co(gy,l)?Object.assign({},o,(u={},u[l]=t[0][l],u)):o},null)):t.length===2&&(lt(t[0])&&(n=t[0]),lt(t[1])&&(i=t[1])),this._n(e,i,n,a)};ce.prototype._ntp=function(e,t,r,i){if(!ce.availabilities.numberFormat)return[];if(!r){var n=i?new Intl.NumberFormat(t,i):new Intl.NumberFormat(t);return n.formatToParts(e)}var a=this._getNumberFormatter(e,t,this.fallbackLocale,this._getNumberFormats(),r,i),o=a&&a.formatToParts(e);if(this._isFallbackRoot(o)){if(!this._root)throw Error("unexpected error");return this._root.$i18n._ntp(e,t,r,i)}else return o||[]};Object.defineProperties(ce.prototype,Ae);var qd;Object.defineProperty(ce,"availabilities",{get:function(){if(!qd){var e=typeof Intl<"u";qd={dateTimeFormat:e&&typeof Intl.DateTimeFormat<"u",numberFormat:e&&typeof Intl.NumberFormat<"u"}}return qd}});ce.install=Gf;ce.version="8.28.2";y.use(ce);const $I="en",ve=new ce({locale:$I,fallbackLocale:"en",messages:{},warnHtmlInMessage:"off"});async function xy(s){const e=await jj(Object.assign({"../locales/cz.json":()=>fe(()=>import("./cz-D8m9rjS3.js"),[]),"../locales/da.json":()=>fe(()=>import("./da-DYgaz82Z.js"),[]),"../locales/de.json":()=>fe(()=>import("./de-P4W13_SZ.js"),[]),"../locales/en.json":()=>fe(()=>import("./en-o7vnTKjO.js"),[]),"../locales/es.json":()=>fe(()=>import("./es-DJtSPj3U.js"),[]),"../locales/fr.json":()=>fe(()=>import("./fr-BgUf3CTX.js"),[]),"../locales/hu.json":()=>fe(()=>import("./hu-B1cvWa_J.js"),[]),"../locales/it.json":()=>fe(()=>import("./it-CPOq0Dki.js"),[]),"../locales/ja.json":()=>fe(()=>import("./ja-CS5xLYiw.js"),[]),"../locales/ko.json":()=>fe(()=>import("./ko-D481bVT5.js"),[]),"../locales/nl.json":()=>fe(()=>import("./nl-B9Xo5zsI.js"),[]),"../locales/pl.json":()=>fe(()=>import("./pl-bBR_77jy.js"),[]),"../locales/pt.json":()=>fe(()=>import("./pt-D716Rj3y.js"),[]),"../locales/ru.json":()=>fe(()=>import("./ru-BYzx4dUn.js"),[]),"../locales/se.json":()=>fe(()=>import("./se-Dt3G_241.js"),[]),"../locales/tr.json":()=>fe(()=>import("./tr-cyYpyxgv.js"),[]),"../locales/uk.json":()=>fe(()=>import("./uk-DIP7xo0c.js"),[]),"../locales/zh.json":()=>fe(()=>import("./zh-T9gotgQQ.js"),[]),"../locales/zh_TW.json":()=>fe(()=>import("./zh_TW-BFyG3P84.js"),[])}),"../locales/".concat(s,".json"),3);return ve.setLocaleMessage(s,e.default),ve.locale=s,e}var xI=Object.getOwnPropertyDescriptor,wI=(s,e,t,r)=>{for(var i=r>1?void 0:r?xI(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Oa=class extends k(Jr){getStatusColor(s){var t;const e={completed:"#BDBDBD",in_progress:"#EEEEEE",cancelled:"#616161",default:"#424242"};return(t=e[s])!=null?t:e.default}getLocalizedStatusName(s){return ve.te("History.StatusValues.".concat(s),"en")?ve.t("History.StatusValues.".concat(s)).toString():s}groupSmallEntries(s,e){const r=s.reduce((l,u)=>l+u.value,0)*e,i=s.filter(l=>l.value<r);if(i.length<2)return s;const n=i.reduce((l,u)=>l+u.value,0),a=s.filter(l=>l.value>=r),o=ve.t("History.StatusValues.Others").toString()+" (".concat(i.length,")");return a.push({name:o,displayName:o,value:n,valueFilament:0,valueTime:0,itemStyle:{opacity:.9,color:"#616161",borderColor:"#1E1E1E",borderWidth:2,borderRadius:3},showInTable:!0}),a}get allPrintStati(){let s=this.allJobs.map(e=>e.status);return s=s.filter((e,t)=>s.indexOf(e)===t),s}get printStatusArray(){return this.allPrintStati.map(s=>{const e=this.allJobs.filter(t=>t.status===s);return{name:s,displayName:this.getLocalizedStatusName(s),showInTable:!this.hidePrintStatus.includes(s),value:e.length,itemStyle:{opacity:.9,color:this.getStatusColor(s),borderColor:"#1E1E1E",borderWidth:2,borderRadius:3}}})}get printStatusArrayChart(){if(this.valueName==="filament"){const s=this.selectedJobs.length?this.selectedJobs:this.jobs;return this.printStatusArray.map(e=>{const t=s.reduce((r,i)=>i.status===e.name?r+i.filament_used:r,0);return{...e,value:t}}).filter(e=>e.value>0)}if(this.valueName==="time"){const s=this.selectedJobs.length?this.selectedJobs:this.jobs;return this.printStatusArray.map(e=>{const t=s.reduce((r,i)=>i.status===e.name?r+i.total_duration:r,0);return{...e,value:t}}).filter(e=>e.value>0)}return this.printStatusArray}get groupedPrintStatusArray(){return this.groupSmallEntries(this.printStatusArrayChart,.05)}};Oa=wI([S],Oa);var SI=Object.getOwnPropertyDescriptor,PI=(s,e,t,r)=>{for(var i=r>1?void 0:r?SI(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Hh=class extends k(L,Jr,Oa){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiCog=ss,this.mdiDatabaseArrowDownOutline=J_,this.mdiDatabaseExportOutline=Rw,this.mdiDelete=Ue,this.mdiFileDocumentMultipleOutline=Ga,this.mdiMagnify=rn,this.mdiNotebookPlus=fv,this.formatFilesize=Xe,this.search="",this.sortBy="start_time",this.sortDesc=!0,this.addMaintenanceDialog=!1,this.deleteSelectedDialog=!1}get allLoaded(){var s;return(s=this.$store.state.server.history.all_loaded)!=null?s:!1}get maintenanceEntries(){var s;return(s=this.$store.getters["gui/maintenance/getEntries"])!=null?s:[]}get entries(){let s=[];return this.showPrintJobs&&(s=[...this.jobs].map(e=>({...e,type:"job",select_id:"job_".concat(e.job_id)}))),this.sortBy!=="start_time"||this.showMaintenanceEntries&&(s=[...s,...this.maintenanceEntries.map(e=>({...e,type:"maintenance",select_id:"maintenance_".concat(e.id)}))]),s}get headers(){const s=[{text:"",value:"",align:"left",configable:!1,visible:!0,filterable:!1},{text:this.$t("History.Filename").toString(),value:"filename",align:"left",configable:!1,visible:!0},{text:"",value:"status",align:"left",configable:!1,visible:!0,filterable:!1},{text:this.$t("History.Filesize").toString(),value:"size",align:"left",configable:!0,visible:!0,outputType:"filesize"},{text:this.$t("History.LastModified").toString(),value:"modified",align:"left",configable:!0,visible:!0,outputType:"date"},{text:this.$t("History.StartTime").toString(),value:"start_time",align:"left",configable:!0,visible:!0,outputType:"date"},{text:this.$t("History.EndTime").toString(),value:"end_time",align:"left",configable:!0,visible:!0,outputType:"date"},{text:this.$t("History.EstimatedTime").toString(),value:"estimated_time",align:"left",configable:!0,visible:!0,outputType:"time"},{text:this.$t("History.PrintTime").toString(),value:"print_duration",align:"left",configable:!0,visible:!0,outputType:"time"},{text:this.$t("History.TotalTime").toString(),value:"total_duration",align:"left",configable:!0,visible:!0,outputType:"time"},{text:this.$t("History.FilamentCalc").toString(),value:"filament_total",align:"left",configable:!0,visible:!0,outputType:"length"},{text:this.$t("History.FilamentUsed").toString(),value:"filament_used",align:"left",configable:!0,visible:!0,outputType:"length"},{text:this.$t("History.FirstLayerExtTemp").toString(),value:"first_layer_extr_temp",align:"left",configable:!0,visible:!0,outputType:"temp"},{text:this.$t("History.FirstLayerBedTemp").toString(),value:"first_layer_bed_temp",align:"left",configable:!0,visible:!0,outputType:"temp"},{text:this.$t("History.FirstLayerHeight").toString(),value:"first_layer_height",align:"left",configable:!0,visible:!0,outputType:"length"},{text:this.$t("History.LayerHeight").toString(),value:"layer_height",align:"left",configable:!0,visible:!0,outputType:"length"},{text:this.$t("History.ObjectHeight").toString(),value:"object_height",align:"left",configable:!0,visible:!0,outputType:"length"},{text:this.$t("History.Slicer").toString(),value:"slicer",align:"left",configable:!0,visible:!0}];return this.moonrakerHistoryFields.forEach(e=>{s.push({text:e.desc,value:e.name,align:"left",configable:!0,visible:!1})}),s.forEach(e=>{e.visible&&this.hideColums.includes(e.value)?e.visible=!1:!e.visible&&!this.hideColums.includes(e.value)&&(e.visible=!0)}),s}get tableFields(){return this.filteredHeaders.filter(s=>!["filename","status"].includes(s.value)&&s.value!=="")}get configHeaders(){return this.headers.filter(s=>s.configable===!0)}get filteredHeaders(){return this.headers.filter(s=>s.visible===!0)}get allPrintStatusArray(){var s;return Ft((s=this.$store.getters["server/history/getAllPrintStatusArray"])!=null?s:[],"name")}get countPerPage(){var s;return(s=this.$store.state.gui.view.history.countPerPage)!=null?s:10}set countPerPage(s){this.$store.dispatch("gui/saveSetting",{name:"view.history.countPerPage",value:s})}get hideColums(){var s;return(s=this.$store.state.gui.view.history.hideColums)!=null?s:[]}set hideColums(s){this.$store.dispatch("gui/saveSetting",{name:"view.history.hideColums",value:s})}get showMaintenanceEntries(){return this.$store.state.gui.view.history.showMaintenanceEntries}set showMaintenanceEntries(s){this.$store.dispatch("gui/saveSetting",{name:"view.history.showMaintenanceEntries",value:s})}get showPrintJobs(){return this.$store.state.gui.view.history.showPrintJobs}set showPrintJobs(s){this.$store.dispatch("gui/saveSetting",{name:"view.history.showPrintJobs",value:s})}get selectedJobsTable(){var s;return(s=this.$store.state.gui.view.history.selectedJobs)!=null?s:[]}set selectedJobsTable(s){this.$store.dispatch("gui/saveSettingWithoutUpload",{name:"view.history.selectedJobs",value:s})}refreshHistory(){this.$store.dispatch("socket/addLoading",{name:"historyLoadAll"}),this.$socket.emit("server.history.list",{start:0,limit:50},{action:"server/history/getHistory"})}sortFiles(s,e,t){const r=e.length?e[0]:"filename",i=t[0];return s!==void 0&&(s.sort(function(n,a){if(n[r]===a[r])return 0;if(n[r]===null||n[r]===void 0)return-1;if(a[r]===null||a[r]===void 0)return 1;if(n[r].constructor===String&&a[r].constructor===String)return n[r].localeCompare(a[r],void 0,{sensivity:"base"});if(n[r]instanceof Array&&a[r]instanceof Array){const o=n[r].length?n.filament.reduce((u,c)=>u+c):0,l=a[r].length?a.filament.reduce((u,c)=>u+c):0;return o-l}return n[r]-a[r]}),i&&s.reverse()),s}advancedSearch(s,e){return s!=null&&e!=null&&s.toString().toLowerCase().indexOf(e.toLowerCase())!==-1}changeColumnVisible(s){if(this.headers.filter(e=>e.value===s).length){let e=this.headers.filter(t=>t.value===s)[0].visible;this.$store.dispatch("gui/setHistoryColumns",{name:s,value:e})}}changeStatusVisible(s){this.$store.dispatch("gui/toggleStatusInHistoryList",s.name)}exportHistory(){const t=(parseFloat("1.23").toLocaleString(this.browserLocale).indexOf(",")>=0?",":".")===","?";":",",r=[],i=[];i.push("filename"),i.push("type"),i.push("status"),this.tableFields.forEach(l=>{if(l.value.startsWith("history_field_")){const u=l.value.replace("history_field_","");i.push(u);return}i.push(l.value)}),r.push(i);let n=[...this.entries];this.selectedJobs.length&&(n=[...this.selectedJobs]),n.length&&n.sort((l,u)=>u.start_time-l.start_time).forEach(l=>{var h,f;const u=[];if(((h=l.type)!=null?h:"job")==="maintenance"){const p=l;u.push(p.name),u.push("maintenance"),u.push(p.end_time!==null?"performed":"open"),this.tableFields.filter(v=>v.value!=="slicer").forEach(v=>{if(v.value==="start_time"){u.push(this.formatDateTime(p.start_time*1e3));return}if(v.value==="end_time"&&p.end_time!==null){u.push(this.formatDateTime(p.end_time*1e3));return}if(v.value==="print_duration"&&p.end_printtime!==null){const C=p.end_printtime-p.start_printtime;u.push(C.toLocaleString(this.browserLocale,{useGrouping:!1}));return}if(v.value==="filament_used"&&p.end_filament!==null){const C=p.end_filament-p.start_filament;u.push(C.toLocaleString(this.browserLocale,{useGrouping:!1}));return}u.push("")}),(f=this.tableFields.find(v=>v.value==="slicer"))!=null&&f.visible&&u.push(""),r.push(u);return}const d=l;let m=d.filename;m.includes(t)&&(m='"'+m+'"'),u.push(m),u.push("job"),u.push(d.status),this.tableFields.forEach(p=>{u.push(this.outputValue(p,d,t))}),r.push(u)});const a="data:text/csv;charset=utf-8,"+r.map(l=>l.map(u=>(u==null?void 0:u.indexOf(t))===-1?u:'"'.concat(u,'"')).join(t)).join("\n"),o=document.createElement("a");o.setAttribute("href",encodeURI(a)),o.setAttribute("download","print_history.csv"),document.body.appendChild(o),o.click(),o.remove()}outputValue(s,e,t=null){var i,n,a,o,l,u;let r=s.value in e?e[s.value]:null;if(r===null&&(r=s.value in e.metadata?e.metadata[s.value]:null),s.value==="slicer"){let c="slicer"in e.metadata&&e.metadata.slicer?e.metadata.slicer:"--";return"slicer_version"in e.metadata&&e.metadata.slicer_version&&(c+=" "+e.metadata.slicer_version),t!==null&&r.includes(t)?'"'+c+'"':c}if(s.value.startsWith("history_field_")){const c=s.value.replace("history_field_",""),d=(i=e.auxiliary_data)==null?void 0:i.find(h=>h.name===c);let m=(n=d==null?void 0:d.value)==null?void 0:n.toString();return d&&!Array.isArray(d.value)&&(m=(o=(a=d.value)==null?void 0:a.toLocaleString(this.browserLocale,{useGrouping:!1}))!=null?o:0),m?t!==null&&(m!=null&&m.includes(t))?'"'.concat(m,'"'):m:"--"}switch(s.outputType){case"date":return this.formatDateTime(r*1e3);case"time":return(l=r==null?void 0:r.toFixed())!=null?l:"";default:switch(typeof r){case"number":return(u=r==null?void 0:r.toLocaleString(this.browserLocale,{useGrouping:!1}))!=null?u:0;case"string":return t!==null&&r.includes(t)&&(r='"'+r+'"'),r;default:return r}}}};Hh=PI([S({components:{HistoryListPanelDeleteSelectedDialog:dy,HistoryListEntryMaintenance:hy,HistoryListPanelAddMaintenance:cy,HistoryListEntryJob:fy,HistoryListPanelDetailsDialog:zf,Panel:U}})],Hh);var DI=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(U,{attrs:{icon:e.mdiFileDocumentMultipleOutline,title:e.$t("History.PrintHistory"),"card-class":"history-list-panel"}},[t(Z,[t(x,[t(b,{staticClass:"col-4 d-flex align-center"},[t(se,{attrs:{"append-icon":e.mdiMagnify,label:e.$t("History.Search"),"single-line":"",outlined:"",clearable:"","hide-details":"",dense:""},model:{value:e.search,callback:function(r){e.search=r},expression:"search"}})],1),t(b,{staticClass:"offset-4 col-4 d-flex align-center justify-end"},[e.selectedJobs.length?t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"px-2 minwidth-0 ml-3",attrs:{color:"error"},on:{click:function(n){e.deleteSelectedDialog=!0}}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiDelete))])],1)]}}],null,!1,3710056784)},[t("span",[e._v(e._s(e.$t("History.Delete")))])]):e._e(),t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"px-2 minwidth-0 ml-3",on:{click:function(n){e.addMaintenanceDialog=!0}}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiNotebookPlus))])],1)]}}])},[t("span",[e._v(e._s(e.$t("History.AddMaintenance")))])]),e.allLoaded?e._e():t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"px-2 minwidth-0 ml-3",attrs:{loading:e.loadings.includes("historyLoadAll")},on:{click:e.refreshHistory}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiDatabaseArrowDownOutline))])],1)]}}],null,!1,788240949)},[t("span",[e._v(e._s(e.$t("History.LoadCompleteHistory")))])]),t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"px-2 minwidth-0 ml-3",on:{click:e.exportHistory}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiDatabaseExportOutline))])],1)]}}])},[t("span",[e._v(e._s(e.$t("History.TitleExportHistory")))])]),t(ye,{attrs:{"offset-y":!0,"close-on-content-click":!1},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:n}){return[t(g,e._g(e._b({staticClass:"px-2 minwidth-0 ml-3"},"v-btn",i,!1),{...r,...n}),[t(_,[e._v(e._s(e.mdiCog))])],1)]}}],null,!0)},[t("span",[e._v(e._s(e.$t("History.Settings")))])])]}}])},[t(Me,[t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"","input-value":e.showMaintenanceEntries,label:e.$t("History.MaintenanceEntries")},on:{change:function(r){e.showMaintenanceEntries=!e.showMaintenanceEntries}}})],1),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"","input-value":e.showPrintJobs,label:e.$t("History.PrintJobs")},on:{change:function(r){e.showPrintJobs=!e.showPrintJobs}}})],1),t(I),e.printStatusArray.length?[e._l(e.printStatusArray,function(r){return t(J,{key:r.name,staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"","input-value":r.showInTable,label:"".concat(r.displayName," (").concat(r.value,")")},on:{change:function(i){return e.changeStatusVisible(r)}}})],1)}),t(I)]:e._e(),e._l(e.configHeaders,function(r,i){return t(J,{key:"history-list-panel-header-option-"+i,staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:r.text},on:{change:function(n){return e.changeColumnVisible(r.value)}},model:{value:r.visible,callback:function(n){e.$set(r,"visible",n)},expression:"header.visible"}})],1)})],2)],1)],1)],1)],1),t(I,{staticClass:"mb-3"}),t(Qr,{staticClass:"history-jobs-table",attrs:{items:e.entries,headers:e.filteredHeaders,"custom-sort":e.sortFiles,"sort-by":e.sortBy,"sort-desc":e.sortDesc,"items-per-page":e.countPerPage,"footer-props":{itemsPerPageText:e.$t("History.Jobs"),itemsPerPageAllText:e.$t("History.AllJobs"),itemsPerPageOptions:[10,25,50,100,-1]},"item-key":"select_id",search:e.search,"custom-filter":e.advancedSearch,"mobile-breakpoint":"0","show-select":""},on:{"update:sortBy":function(r){e.sortBy=r},"update:sort-by":function(r){e.sortBy=r},"update:sortDesc":function(r){e.sortDesc=r},"update:sort-desc":function(r){e.sortDesc=r},"update:itemsPerPage":function(r){e.countPerPage=r},"update:items-per-page":function(r){e.countPerPage=r}},scopedSlots:e._u([{key:"no-data",fn:function(){return[t("div",{staticClass:"text-center"},[e._v(e._s(e.$t("History.Empty")))])]},proxy:!0},{key:"item",fn:function({item:r,isSelected:i,select:n}){return[r.type==="job"?t(fy,{key:r.select_id,attrs:{"is-selected":i,item:r,"table-fields":e.tableFields},on:{select:n}}):r.type==="maintenance"?t(hy,{key:r.select_id,attrs:{"is-selected":i,item:r,"table-fields":e.tableFields},on:{select:n}}):e._e()]}}]),model:{value:e.selectedJobsTable,callback:function(r){e.selectedJobsTable=r},expression:"selectedJobsTable"}}),t(dy,{attrs:{show:e.deleteSelectedDialog},on:{close:function(r){e.deleteSelectedDialog=!1}}}),t(cy,{attrs:{show:e.addMaintenanceDialog},on:{close:function(r){e.addMaintenanceDialog=!1}}})],1)},TI=[],OI=E(Hh,DI,TI,!1,null,"00a01d41");const wy=OI.exports;var MI=Object.defineProperty,kI=Object.getOwnPropertyDescriptor,Sy=(s,e,t,r)=>{for(var i=r>1?void 0:r?kI(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&MI(e,t,i),i};let wc=class extends k(L,Jr,vt){get chartOptions(){return{animation:!1,grid:{top:25,right:40,bottom:30,left:40},tooltip:{trigger:"item",borderWidth:0},xAxis:{type:"category",data:["0-2h","2-6h","6-12h","12-24h",">24h"],splitLine:{show:!0,lineStyle:{color:this.fgColorFaint}},axisLabel:{color:this.fgColorLow,margin:10}},yAxis:{name:this.$t("History.HistoryPrinttimeAVG"),type:"value",minInterval:10,maxInterval:100,nameLocation:"end",nameGap:5,nameTextStyle:{color:this.fgColorLow,align:"left"},splitLine:{lineStyle:{color:this.fgColorLow}},axisLabel:{color:this.fgColorLow,formatter:"{value}",showMinLabel:!0,margin:5},axisLine:{show:!0,lineStyle:{color:this.fgColorLow}}},series:[{type:"bar",data:this.printtimeAvgArray,itemStyle:{color:"#BDBDBD"}}]}}get printtimeAvgArray(){const e=[0,0,0,0,0],t=new Date(new Date().getTime()-60*60*24*14*1e3);let r=[...this.allJobs.filter(i=>new Date(i.start_time*1e3)>=t&&i.status==="completed")];if(this.selectedJobs.length&&(r=[...this.selectedJobs.filter(i=>new Date(i.start_time*1e3)>=t&&i.status==="completed")]),r.length){const i=n=>n/3600;r.forEach(n=>{const a=i(n.print_duration);a>0&&a<=2?e[0]++:a<=6?e[1]++:a<=12?e[2]++:a<=24?e[3]++:e[4]++})}return e}get chart(){var e,t;return(t=(e=this.$refs.historyPrinttimeAvg)==null?void 0:e.chart)!=null?t:null}beforeDestroy(){typeof window>"u"||this.chart&&this.chart.dispose()}printtimeAvgArrayChanged(e){var t;(t=this.chart)==null||t.setOption({series:{data:e}},!1,!0)}visibilityChanged(e){var t;e&&((t=this.chart)==null||t.resize())}};Sy([he("printtimeAvgArray")],wc.prototype,"printtimeAvgArrayChanged",1);wc=Sy([S({components:{}})],wc);var EI=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("e-chart",{directives:[{name:"observe-visibility",rawName:"v-observe-visibility",value:e.visibilityChanged,expression:"visibilityChanged"}],ref:"historyPrinttimeAvg",staticStyle:{height:"175px",width:"100%"},attrs:{option:e.chartOptions,"init-options":{renderer:"svg"}}})},LI=[],AI=E(wc,EI,LI,!1,null,null);const Py=AI.exports;var FI=Object.defineProperty,RI=Object.getOwnPropertyDescriptor,Dy=(s,e,t,r)=>{for(var i=r>1?void 0:r?RI(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&FI(e,t,i),i};let Sc=class extends k(L,Jr,vt){get chartOptions(){return{animation:!1,grid:{top:25,right:40,bottom:30,left:40},tooltip:{trigger:"axis",borderWidth:0,formatter:s=>{let e="";if(s.length){e=s[0].marker;const r=s[0].axisValueLabel.split(/[^0-9]/),i=new Date(r[0],r[1]-1,r[2]),n=Math.round(s[0].data[1]*10)/10;e+=i.toLocaleDateString()+": "+n+"m"}return e}},xAxis:{type:"time",min:new Date().setHours(0,0,0)-60*60*24*14*1e3,max:new Date().setHours(0,0,0),minInterval:60*60*24*1e3,splitLine:{show:!0,lineStyle:{color:this.fgColorLow}},axisLabel:{color:this.fgColorLow,margin:10}},yAxis:{name:this.$t("History.HistoryFilamentUsage"),type:"value",minInterval:10,maxInterval:100,nameLocation:"end",nameGap:5,nameTextStyle:{color:this.fgColorLow,align:"left"},splitLine:{lineStyle:{color:this.fgColorLow}},axisLabel:{color:this.fgColorLow,formatter:"{value}",showMinLabel:!0,margin:5},axisLine:{show:!0,lineStyle:{color:this.fgColorMid}}},color:["#BDBDBD"],series:[{type:"bar",data:this.filamentUsageArray,showSymbol:!1}]}}get filamentUsageArray(){const s=[],e=new Date;e.setDate(e.getDate()-14),e.setHours(0,0,0,0);let t=[...this.allJobs.filter(r=>new Date(r.start_time*1e3)>=e&&r.filament_used>0)];this.selectedJobs.length&&(t=[...this.selectedJobs.filter(r=>new Date(r.start_time*1e3)>=e&&r.filament_used>0)]);for(let r=0;r<=14;r++){const i=new Date(e.getTime());i.setDate(i.getDate()+r),i.setHours(0,0,0,0),s.push([i.getTime(),0])}return t.length&&t.forEach(r=>{const i=new Date(r.start_time*1e3).setHours(0,0,0,0),n=s.findIndex(a=>a[0]===i);n!==-1&&(s[n][1]+=Math.round(r.filament_used)/1e3)}),s.sort((r,i)=>i[0]-r[0])}get chart(){var s,e;return(e=(s=this.$refs.historyFilamentUsage)==null?void 0:s.chart)!=null?e:null}beforeDestroy(){typeof window>"u"||this.chart&&this.chart.dispose()}filamentUsageArrayChanged(s){var e;(e=this.chart)==null||e.setOption({series:{data:s}},!1,!0)}visibilityChanged(s){var e;s&&((e=this.chart)==null||e.resize())}};Dy([he("filamentUsageArray")],Sc.prototype,"filamentUsageArrayChanged",1);Sc=Dy([S({})],Sc);var HI=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("e-chart",{directives:[{name:"observe-visibility",rawName:"v-observe-visibility",value:e.visibilityChanged,expression:"visibilityChanged"}],ref:"historyFilamentUsage",staticStyle:{height:"175px",width:"100%"},attrs:{option:e.chartOptions,autoresize:!0,"init-options":{renderer:"svg"}}})},jI=[],II=E(Sc,HI,jI,!1,null,null);const Ty=II.exports;var NI=Object.defineProperty,VI=Object.getOwnPropertyDescriptor,qf=(s,e,t,r)=>{for(var i=r>1?void 0:r?VI(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&NI(e,t,i),i};let Ma=class extends k(L){get value(){return this.valueName==="filament"?this.item.value>1e3?Math.round(this.item.value/1e3).toFixed(2)+" m":this.item.value.toFixed(0)+" mm":this.valueName==="time"?Is(this.item.value,!1):this.item.value.toString()}};qf([w({type:Object})],Ma.prototype,"item",2);qf([w({type:String,default:"amount"})],Ma.prototype,"valueName",2);Ma=qf([S({components:{}})],Ma);var BI=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("tr",[t("td",[e._v(e._s(e.item.displayName))]),t("td",{staticClass:"text-right"},[e._v(e._s(e.value))])])},UI=[],WI=E(Ma,BI,UI,!1,null,null);const Oy=WI.exports;var zI=Object.defineProperty,GI=Object.getOwnPropertyDescriptor,My=(s,e,t,r)=>{for(var i=r>1?void 0:r?GI(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&zI(e,t,i),i};let Pc=class extends k(L,Oa){};My([w({type:String,default:"amount"})],Pc.prototype,"valueName",2);Pc=My([S({components:{HistoryAllPrintStatusTableItem:Oy}})],Pc);var ZI=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Mp,[t("tbody",e._l(e.printStatusArrayChart,function(r){return t(Oy,{key:r.name,attrs:{item:r,"value-name":e.valueName}})}),1)])},qI=[],XI=E(Pc,ZI,qI,!1,null,null);const YI=XI.exports;var JI=Object.defineProperty,KI=Object.getOwnPropertyDescriptor,td=(s,e,t,r)=>{for(var i=r>1?void 0:r?KI(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&JI(e,t,i),i};let qi=class extends k(L,vt,Oa){get chartOptions(){return{animation:!1,grid:{top:10,right:0,bottom:0,left:10},tooltip:{trigger:"item",borderWidth:0,valueFormatter:s=>this.valueName==="filament"?s>1e3?Math.round(s/1e3).toString()+" m":s.toString()+" mm":this.valueName==="time"?Is(s,!1):s.toString()},series:[{type:"pie",data:this.groupedPrintStatusArray,avoidLabelOverlap:!1,minAngle:5,radius:["35%","60%"],emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}},label:{color:this.fgColorHi}}]}}get chart(){var s,e;return(e=(s=this.historyAllPrintStatus)==null?void 0:s.chart)!=null?e:null}beforeDestroy(){typeof window>"u"||this.chart&&this.chart.dispose()}groupedPrintStatusArrayChanged(s){var e;(e=this.chart)==null||e.setOption({series:{data:s}},!1,!0)}visibilityChanged(s){var e;s&&((e=this.chart)==null||e.resize())}};td([w({type:String,default:"jobs"})],qi.prototype,"valueName",2);td([Ts("historyAllPrintStatus")],qi.prototype,"historyAllPrintStatus",2);td([he("groupedPrintStatusArray")],qi.prototype,"groupedPrintStatusArrayChanged",1);qi=td([S({components:{}})],qi);var QI=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("e-chart",{directives:[{name:"observe-visibility",rawName:"v-observe-visibility",value:e.visibilityChanged,expression:"visibilityChanged"}],ref:"historyAllPrintStatus",staticStyle:{height:"200px",width:"100%"},attrs:{option:e.chartOptions,autoresize:!0,"init-options":{renderer:"svg"}}})},eN=[],tN=E(qi,QI,eN,!1,null,null);const ky=tN.exports;var sN=Object.getOwnPropertyDescriptor,rN=(s,e,t,r)=>{for(var i=r>1?void 0:r?sN(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let jh=class extends k(L,Jr){constructor(){super(...arguments),this.mdiChartAreaspline=$w,this.mdiDatabaseArrowDownOutline=J_,this.formatPrintTime=Is,this.toggleValue="jobs"}get toggleValueOptions(){return[{text:this.$t("History.Jobs"),value:"jobs"},{text:this.$t("History.Filament"),value:"filament"},{text:this.$t("History.Time"),value:"time"}]}get existsSelectedJobs(){return this.selectedJobs.length>0}get totalPrintTime(){var s,e;return(e=(s=this.$store.state.server.history.job_totals)==null?void 0:s.total_print_time)!=null?e:0}get selectedPrintTime(){let s=0;return this.selectedJobs.forEach(e=>{s+=e.print_duration}),s}get longestPrintTime(){var s,e;return(e=(s=this.$store.state.server.history.job_totals)==null?void 0:s.longest_print)!=null?e:0}get selectedLongestPrintTime(){let s=0;return this.selectedJobs.forEach(e=>{e.print_duration>s&&(s=e.print_duration)}),s}get avgPrintTime(){return this.totalJobsCount>0&&this.totalPrintTime>0?Math.round(this.totalPrintTime/this.totalJobsCount):0}get selectedAvgPrintTime(){return this.selectedJobs.length>0&&this.selectedPrintTime>0?Math.round(this.selectedPrintTime/this.selectedJobs.length):0}get totalFilamentUsed(){var s,e;return(e=(s=this.$store.state.server.history.job_totals)==null?void 0:s.total_filament_used)!=null?e:0}get totalFilamentUsedFormat(){const s=Math.round(this.totalFilamentUsed/100)/10;return"".concat(s," m")}get selectedFilamentUsed(){let s=0;return this.selectedJobs.forEach(e=>{s+=e.filament_used}),s}get selectedFilamentUsedFormat(){const s=Math.round(this.selectedFilamentUsed/100)/10;return"".concat(s," m")}get totalJobsCount(){var s,e;return(e=(s=this.$store.state.server.history.job_totals)==null?void 0:s.total_jobs)!=null?e:0}get toggleChart(){return this.$store.state.gui.view.history.toggleChartCol3}set toggleChart(s){this.$store.dispatch("gui/saveSetting",{name:"view.history.toggleChartCol3",value:s})}get togglePrintStatus(){return this.$store.state.gui.view.history.toggleChartCol2}set togglePrintStatus(s){this.$store.dispatch("gui/saveSetting",{name:"view.history.toggleChartCol2",value:s})}get allLoaded(){var s;return(s=this.$store.state.server.history.all_loaded)!=null?s:!1}get selectedTotals(){const s=[{title:this.$t("History.SelectedPrinttime"),value:this.formatPrintTime(this.selectedPrintTime,!1)},{title:this.$t("History.LongestPrinttime"),value:this.formatPrintTime(this.selectedLongestPrintTime,!1)},{title:this.$t("History.AvgPrinttime"),value:this.formatPrintTime(this.selectedAvgPrintTime,!1)},{title:this.$t("History.SelectedFilamentUsed"),value:this.selectedFilamentUsedFormat},{title:this.$t("History.SelectedJobs"),value:this.selectedJobs.length.toString()}];return s.push(...this.auxiliarySelectedTotals),s}get auxiliarySelectedTotals(){const s=[];return this.moonrakerHistoryFields.forEach(e=>{const t=this.selectedJobs.reduce((r,i)=>{var o;const n=e.name.replace("history_field_",""),a=(o=i.auxiliary_data)==null?void 0:o.find(l=>l.provider===e.provider&&l.name===n);return!a||typeof a.value!="number"?r:r+a.value},0);s.push({title:e.desc,value:"".concat(Math.round(t*1e3)/1e3," ").concat(e.unit)})}),s}get genericTotals(){const s=[{title:this.$t("History.TotalPrinttime"),value:this.formatPrintTime(this.totalPrintTime,!1)},{title:this.$t("History.LongestPrinttime"),value:this.formatPrintTime(this.longestPrintTime,!1)},{title:this.$t("History.AvgPrinttime"),value:this.formatPrintTime(this.avgPrintTime,!1)},{title:this.$t("History.TotalFilamentUsed"),value:this.totalFilamentUsedFormat},{title:this.$t("History.TotalJobs"),value:this.totalJobsCount.toString()}];return s.push(...this.auxiliaryTotals),s}get auxiliaryTotals(){var t;const s=(t=this.$store.state.server.history.auxiliary_totals)!=null?t:[],e=[];return s.forEach(r=>{var o,l;const i="history_field_".concat(r.field),n=this.moonrakerHistoryFields.find(u=>u.provider===r.provider&&u.name===i),a=Math.round(((o=r.total)!=null?o:0)*1e3)/1e3;e.push({title:(l=n==null?void 0:n.desc)!=null?l:r.field,value:"".concat(a," ").concat(n==null?void 0:n.unit)})}),e}get totals(){return this.existsSelectedJobs?this.selectedTotals:this.genericTotals}refreshHistory(){this.$store.dispatch("socket/addLoading",{name:"historyLoadAll"}),this.$socket.emit("server.history.list",{start:0,limit:50},{action:"server/history/getHistory"})}};jh=rN([S({components:{Panel:U,HistoryFilamentUsage:Ty,HistoryPrinttimeAvg:Py,HistoryAllPrintStatusChart:ky}})],jh);var iN=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(U,{attrs:{icon:e.mdiChartAreaspline,title:e.$t("History.Statistics"),"card-class":"history-statistics-panel",collapsible:!0}},[t(Z,{staticClass:"pa-0"},[t(x,{attrs:{align:"center"}},[t(b,{staticClass:"col-12 col-sm-6 col-md-4"},[t(Mp,[t("tbody",e._l(e.totals,function(r){return t("tr",{key:r.title},[t("td",[e._v(e._s(r.title))]),t("td",{staticClass:"text-right"},[e._v(e._s(r.value))])])}),0)])],1),t(b,{staticClass:"col-12 col-sm-6 col-md-4"},[e.togglePrintStatus==="chart"?t(ky,{attrs:{"value-name":e.toggleValue}}):t(YI,{attrs:{"value-name":e.toggleValue}}),t("div",{staticClass:"text-center mb-3"},[t(Nn,{attrs:{small:"",mandatory:""},model:{value:e.togglePrintStatus,callback:function(r){e.togglePrintStatus=r},expression:"togglePrintStatus"}},[t(g,{attrs:{small:"",value:"chart"}},[e._v(e._s(e.$t("History.Chart")))]),t(g,{attrs:{small:"",value:"table"}},[e._v(e._s(e.$t("History.Table")))])],1),e.allLoaded?e._e():t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"ml-3 minwidth-0 px-2",attrs:{outlined:"",small:"",loading:e.loadings.includes("historyLoadAll"),color:"primary"},on:{click:e.refreshHistory}},"v-btn",i,!1),r),[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiDatabaseArrowDownOutline))])],1)]}}],null,!1,1343318810)},[t("span",[e._v(e._s(e.$t("History.LoadCompleteHistory")))])])],1),t("div",{staticClass:"text-center mb-3"},[t(Nn,{attrs:{small:"",mandatory:""},model:{value:e.toggleValue,callback:function(r){e.toggleValue=r},expression:"toggleValue"}},e._l(e.toggleValueOptions,function(r){return t(g,{key:r.value,attrs:{small:"",value:r.value}},[e._v(" "+e._s(r.text)+" ")])}),1)],1)],1),t(b,{staticClass:"col-12 col-sm-12 col-md-4"},[e.toggleChart==="filament_usage"?t(Ty):e.toggleChart==="printtime_avg"?t(Py):e._e(),t("div",{staticClass:"text-center mt-3"},[t(Nn,{attrs:{small:"",mandatory:""},model:{value:e.toggleChart,callback:function(r){e.toggleChart=r},expression:"toggleChart"}},[t(g,{attrs:{small:"",value:"filament_usage"}},[e._v(e._s(e.$t("History.FilamentUsage")))]),t(g,{attrs:{small:"",value:"printtime_avg"}},[e._v(e._s(e.$t("History.PrinttimeAvg")))])],1)],1)],1)],1)],1)],1)},nN=[],aN=E(jh,iN,nN,!1,null,null);const Ey=aN.exports;var oN=Object.getOwnPropertyDescriptor,lN=(s,e,t,r)=>{for(var i=r>1?void 0:r?oN(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Ih=class extends k(L){};Ih=lN([S({components:{HistoryListPanel:wy,HistoryStatisticsPanel:Ey}})],Ih);var cN=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(x,[t(b,[t(Ey)],1)],1),t(x,{staticClass:"mt-0"},[t(b,[t(wy)],1)],1)],1)},uN=[],dN=E(Ih,cN,uN,!1,null,null);const mN=dN.exports;var hN=Object.getOwnPropertyDescriptor,pN=(s,e,t,r)=>{for(var i=r>1?void 0:r?hN(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Dc=class extends y{get variable_fps(){var s,e,t;return(t=(e=(s=this.$store.state.server.timelapse)==null?void 0:s.settings)==null?void 0:e.variable_fps)!=null?t:!1}set variable_fps(s){this.$store.dispatch("server/timelapse/saveSetting",{variable_fps:s})}get variable_fps_min(){var s,e,t;return(t=(e=(s=this.$store.state.server.timelapse)==null?void 0:s.settings)==null?void 0:e.variable_fps_min)!=null?t:5}set variable_fps_min(s){this.$store.dispatch("server/timelapse/saveSetting",{variable_fps_min:s})}get variable_fps_max(){var s,e,t;return(t=(e=(s=this.$store.state.server.timelapse)==null?void 0:s.settings)==null?void 0:e.variable_fps_max)!=null?t:60}set variable_fps_max(s){this.$store.dispatch("server/timelapse/saveSetting",{variable_fps_max:s})}get targetlength(){var s,e,t;return(t=(e=(s=this.$store.state.server.timelapse)==null?void 0:s.settings)==null?void 0:e.targetlength)!=null?t:10}set targetlength(s){this.$store.dispatch("server/timelapse/saveSetting",{targetlength:s})}get output_framerate(){var s,e,t;return(t=(e=(s=this.$store.state.server.timelapse)==null?void 0:s.settings)==null?void 0:e.output_framerate)!=null?t:30}set output_framerate(s){this.$store.dispatch("server/timelapse/saveSetting",{output_framerate:s})}get duplicatelastframe(){var s,e,t;return(t=(e=(s=this.$store.state.server.timelapse)==null?void 0:s.settings)==null?void 0:e.duplicatelastframe)!=null?t:0}set duplicatelastframe(s){this.$store.dispatch("server/timelapse/saveSetting",{duplicatelastframe:s})}get framesCount(){var s,e,t;return(t=(e=(s=this.$store.state.server.timelapse)==null?void 0:s.lastFrame)==null?void 0:e.count)!=null?t:0}get estimatedVideoLength(){let s=Math.round((this.framesCount+this.duplicatelastframe)/this.output_framerate);return this.variable_fps&&(s=Math.round((this.framesCount+this.duplicatelastframe)/this.variableTargetFps),s<this.targetlength&&(s=this.targetlength)),s>60?Math.floor(s/60)+"m "+(s-Math.floor(s/60)*60)+"s":s+"s"}get variableTargetFps(){let s=Math.floor(this.framesCount/this.targetlength);return s=Math.max(s,this.variable_fps_min),s=Math.min(s,this.variable_fps_max),s}};Dc=pN([S],Dc);var fN=Object.defineProperty,gN=Object.getOwnPropertyDescriptor,Ly=(s,e,t,r)=>{for(var i=r>1?void 0:r?gN(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&fN(e,t,i),i};let Tc=class extends k(L,Dc){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiTextBoxSearchOutline=Pv}get framerateTypeOptions(){return[{value:!1,text:this.$t("Timelapse.Fixed")},{value:!0,text:this.$t("Timelapse.Variable")}]}startRender(){this.$socket.emit("machine.timelapse.render",{}),this.close()}close(){this.$emit("close")}};Ly([w({type:Boolean,default:!1})],Tc.prototype,"show",2);Tc=Ly([S({components:{Panel:U,SettingsRow:j}})],Tc);var _N=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.show,"max-width":700,"max-height":500}},[t(U,{attrs:{title:e.$t("Timelapse.RenderSettings"),icon:e.mdiTextBoxSearchOutline,"card-class":"timelapse-rendersettings-dialog-panel","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:""},on:{click:e.close}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{},[t(x,[t(b,{staticClass:"col-4"},[t(ke,{attrs:{label:e.$t("Timelapse.Type"),items:e.framerateTypeOptions,outlined:"",dense:"","hide-details":""},model:{value:e.variable_fps,callback:function(r){e.variable_fps=r},expression:"variable_fps"}})],1),t(b,{staticClass:"col-4"},[e.variable_fps?[t(se,{attrs:{label:e.$t("Timelapse.MinFramerate"),type:"number",outlined:"",dense:"","hide-details":"","hide-spin-buttons":""},model:{value:e.variable_fps_min,callback:function(r){e.variable_fps_min=r},expression:"variable_fps_min"}}),t(se,{staticClass:"mt-3",attrs:{label:e.$t("Timelapse.MaxFramerate"),type:"number",outlined:"",dense:"","hide-details":"","hide-spin-buttons":""},model:{value:e.variable_fps_max,callback:function(r){e.variable_fps_max=r},expression:"variable_fps_max"}}),t(se,{staticClass:"mt-3",attrs:{label:e.$t("Timelapse.Targetlength"),type:"number",outlined:"",dense:"","hide-details":"","hide-spin-buttons":""},model:{value:e.targetlength,callback:function(r){e.targetlength=r},expression:"targetlength"}})]:t(se,{attrs:{label:e.$t("Timelapse.Framerate"),type:"number",outlined:"",dense:"","hide-details":"","hide-spin-buttons":""},model:{value:e.output_framerate,callback:function(r){e.output_framerate=r},expression:"output_framerate"}}),t(se,{staticClass:"mt-3",attrs:{label:e.$t("Timelapse.DuplicateLastframe"),type:"number",outlined:"",dense:"","hide-details":"","hide-spin-buttons":""},model:{value:e.duplicatelastframe,callback:function(r){e.duplicatelastframe=r},expression:"duplicatelastframe"}})],2),t(b,{staticClass:"col-4"},[e.variable_fps?t(se,{staticClass:"mb-3",attrs:{label:e.$t("Timelapse.TargetFps"),type:"number",outlined:"",dense:"","hide-details":"",readonly:""},model:{value:e.variableTargetFps,callback:function(r){e.variableTargetFps=r},expression:"variableTargetFps"}}):e._e(),t(se,{attrs:{label:e.$t("Timelapse.EstimatedLength"),outlined:"",dense:"","hide-details":"",readonly:""},model:{value:e.estimatedVideoLength,callback:function(r){e.estimatedVideoLength=r},expression:"estimatedVideoLength"}})],1)],1)],1),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.close}},[e._v(e._s(e.$t("Timelapse.Cancel")))]),t(g,{attrs:{text:"",color:"primary"},on:{click:e.startRender}},[e._v(e._s(e.$t("Timelapse.StartRender")))])],1)],1)],1)},vN=[],bN=E(Tc,_N,vN,!1,null,null);const Ay=bN.exports;var yN=Object.defineProperty,CN=Object.getOwnPropertyDescriptor,Fy=(s,e,t,r)=>{for(var i=r>1?void 0:r?CN(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&yN(e,t,i),i};let Oc=class extends k(L,Dc,ur){constructor(){super(...arguments),this.mdiInformation=Ht,this.mdiFile=Bs,this.mdiCloseThick=pe,this.boolDialogRendersettings=!1,this.scale=1}get frameUrl(){var e,t,r;const s=(r=(t=(e=this.$store.state.server.timelapse)==null?void 0:e.lastFrame)==null?void 0:t.file)!=null?r:null;return s?this.apiUrl+"/server/files/timelapse_frames/"+s:null}get enabled(){var s,e,t;return(t=(e=(s=this.$store.state.server.timelapse)==null?void 0:s.settings)==null?void 0:e.enabled)!=null?t:!1}set enabled(s){this.$socket.emit("machine.timelapse.post_settings",{enabled:s},{action:"server/timelapse/initSettings"})}get autorender(){var s,e,t;return(t=(e=(s=this.$store.state.server.timelapse)==null?void 0:s.settings)==null?void 0:e.autorender)!=null?t:!1}set autorender(s){this.$socket.emit("machine.timelapse.post_settings",{autorender:s},{action:"server/timelapse/initSettings"})}get disableRenderButton(){var s,e;return((e=(s=this.$store.state.server.timelapse)==null?void 0:s.rendering.status)!=null?e:"")==="running"}get existsSnapshoturlInMoonrakerConfig(){return"snapshoturl"in this.$store.state.server.config.orig.timelapse}get moonrakerTimelapseConfig(){var s;return(s=this.$store.state.server.config.config.timelapse)!=null?s:{}}get camId(){var s;return(s=this.$store.state.server.timelapse.settings.camera)!=null?s:""}get camSettings(){return this.$store.getters["gui/webcams/getWebcam"](this.camId)}get webcamStyle(){var s,e,t,r,i;return this.existsSnapshoturlInMoonrakerConfig?{transform:this.generateTransform((s=this.moonrakerTimelapseConfig.flip_x)!=null?s:!1,(e=this.moonrakerTimelapseConfig.flip_y)!=null?e:!1,0)}:this.camSettings?{transform:this.generateTransform((t=this.camSettings.flip_horizontal)!=null?t:!1,(r=this.camSettings.flip_vertical)!=null?r:!1,(i=this.camSettings.rotation)!=null?i:0)}:{}}saveFrames(){this.$socket.emit("machine.timelapse.saveframes",{},{loading:"timelapse_saveframes"})}calcRatio(){this.scale=this.timelapsePreview.naturalHeight/this.timelapsePreview.naturalWidth,this.scale>1&&(this.scale=this.timelapsePreview.naturalWidth/this.timelapsePreview.naturalHeight)}};Fy([Ts("timelapsePreview")],Oc.prototype,"timelapsePreview",2);Oc=Fy([S({components:{TimelapseRenderingsettingsDialog:Ay,Panel:U,SettingsRow:j}})],Oc);var $N=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(U,{attrs:{title:e.$t("Timelapse.Status"),icon:e.mdiInformation,"card-class":"timelapse-status-panel"}},[e.framesCount?t(Z,[e.frameUrl?t(x,[t(b,{staticClass:"pb-0"},[t("vue-load-image",{staticClass:"d-flex align-center justify-center"},[t("img",{ref:"timelapsePreview",staticClass:"w-100",style:e.webcamStyle,attrs:{slot:"image",src:e.frameUrl,alt:e.$t("Timelapse.Preview").toString()},on:{load:e.calcRatio},slot:"image"}),t("div",{attrs:{slot:"preloader"},slot:"preloader"},[t(ot,{attrs:{indeterminate:"",color:"primary"}})],1),t("div",{attrs:{slot:"error"},slot:"error"},[t(_,[e._v(e._s(e.mdiFile))])],1)])],1)],1):e._e(),t(x,[t(b,{staticClass:"text--secondary"},[t(j,{attrs:{title:e.$t("Timelapse.Frames"),"dynamic-slot-width":!0}},[e._v(" "+e._s(e.framesCount)+" ")]),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Timelapse.EstimatedLength"),"dynamic-slot-width":!0}},[e._v(" "+e._s(e.estimatedVideoLength)+" ")]),["printing","paused"].includes(e.printer_state)?e._e():[t(I,{staticClass:"mt-2 mb-4"}),t(x,[t(b,{staticClass:"text-center py-1"},[t(g,{attrs:{text:"",color:"primary",disabled:e.disableRenderButton},on:{click:function(r){e.boolDialogRendersettings=!0}}},[e._v(" "+e._s(e.$t("Timelapse.Render"))+" ")]),t(g,{attrs:{text:"",color:"primary",loading:e.loadings.includes("timelapse_saveframes")},on:{click:e.saveFrames}},[e._v(" "+e._s(e.$t("Timelapse.SaveFrames"))+" ")])],1)],1)]],2)],1)],1):t(Z,{},[t("p",{staticClass:"text-center my-0 font-italic"},[e._v(e._s(e.$t("Timelapse.NoActiveTimelapse")))])]),["printing","paused"].includes(e.printer_state)?t(Z,{staticClass:"pt-0"},[t(I,{staticClass:"mt-0 mb-2"}),t(j,{attrs:{title:e.$t("Timelapse.Enabled"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.enabled,callback:function(r){e.enabled=r},expression:"enabled"}})],1),e.enabled?[t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Timelapse.Autorender"),"dynamic-slot-width":!0}},[t(we,{staticClass:"mt-0",attrs:{"hide-details":""},model:{value:e.autorender,callback:function(r){e.autorender=r},expression:"autorender"}})],1)]:e._e()],2):e._e(),t(Ay,{attrs:{show:e.boolDialogRendersettings},on:{close:function(r){e.boolDialogRendersettings=!1}}})],1)},xN=[],wN=E(Oc,$N,xN,!1,null,null);const Ry=wN.exports;var SN=Object.getOwnPropertyDescriptor,PN=(s,e,t,r)=>{for(var i=r>1?void 0:r?SN(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Nh=class extends k(L){constructor(){super(...arguments),this.formatFilesize=Xe,this.sortFiles=rf,this.mdiFileVideo=Gw,this.mdiCloseThick=pe,this.mdiFileDocumentMultipleOutline=Ga,this.mdiMagnify=rn,this.mdiFolderPlus=Vp,this.mdiRefresh=an,this.mdiFolderUpload=Bp,this.mdiFolder=Np,this.mdiFolderZipOutline=Xw,this.mdiFile=Bs,this.mdiCloudDownload=Kn,this.mdiRenameBox=vu,this.mdiDelete=Ue,this.search="",this.boolVideoDialog=!1,this.videoDialogFilename="",this.dialogCreateDirectory={show:!1,name:""},this.contextMenu={shown:!1,isDirectory:!1,touchTimer:void 0,x:0,y:0,item:{isDirectory:!1,filename:"",permissions:"",modified:new Date}},this.dialogRenameFile={show:!1,newName:"",item:{isDirectory:!1,filename:"",permissions:"",modified:new Date}},this.dialogRenameDirectory={show:!1,newName:"",item:{isDirectory:!1,filename:"",permissions:"",modified:new Date}},this.dialogDeleteDirectory={show:!1,newName:"",item:{isDirectory:!1,filename:"",permissions:"",modified:new Date}},this.deleteDialog=!1,this.deleteSelectedDialog=!1,this.isInvalidName=!0,this.nameInputRules=[s=>!!s||this.$t("Files.InvalidNameEmpty"),s=>!this.existsFilename(s)||this.$t("Files.InvalidNameAlreadyExists")],this.rootDirectory="timelapse"}existsFilename(s){return this.files.findIndex(e=>e.filename===s)>=0}get headers(){return[{text:"",value:"",align:"left",configable:!1,visible:!0,sortable:!1},{text:this.$t("Timelapse.Name"),value:"filename",align:"left",configable:!1,visible:!0},{text:this.$t("Timelapse.Filesize"),value:"size",align:"right",configable:!0,visible:!0},{text:this.$t("Timelapse.LastModified"),value:"modified",align:"right",configable:!0,visible:!0}]}get directory(){return this.$store.getters["files/getDirectory"](this.currentPath)}get disk_usage(){var s,e;return(e=(s=this.directory)==null?void 0:s.disk_usage)!=null?e:{used:0,free:0,total:0}}get directoryPermissions(){var s,e;return(e=(s=this.directory)==null?void 0:s.permissions)!=null?e:"r"}get files(){var s,e;return[...(e=(s=this.directory)==null?void 0:s.childrens)!=null?e:[]]}get sortBy(){var s;return(s=this.$store.state.gui.view.gcodefiles.sortBy)!=null?s:"modified"}set sortBy(s){s===void 0&&(s="modified"),this.$store.dispatch("gui/saveSetting",{name:"view.timelapse.sortBy",value:s})}get sortDesc(){var s;return(s=this.$store.state.gui.view.gcodefiles.sortDesc)!=null?s:!0}set sortDesc(s){s===void 0&&(s=!1),this.$store.dispatch("gui/saveSetting",{name:"view.timelapse.sortDesc",value:s})}get countPerPage(){var s,e;return(e=(s=this.$store.state.gui.view.timelapse)==null?void 0:s.countPerPage)!=null?e:10}set countPerPage(s){this.$store.dispatch("gui/saveSetting",{name:"view.timelapse.countPerPage",value:s})}get displayFiles(){var s,e;return(e=(s=this.files)==null?void 0:s.filter(t=>t.isDirectory?!0:t.filename.endsWith("mp4")||t.filename.endsWith("zip")))!=null?e:[]}get currentPath(){return this.$store.state.gui.view.timelapse.currentPath}get currentPathForNavigation(){return this.currentPath===this.rootDirectory?"":this.currentPath.substring(this.rootDirectory.length)}set currentPath(s){this.$store.dispatch("gui/saveSettingWithoutUpload",{name:"view.timelapse.currentPath",value:s})}get selectedFiles(){var s;return(s=this.$store.state.gui.view.timelapse.selectedFiles)!=null?s:[]}set selectedFiles(s){this.$store.dispatch("gui/saveSettingWithoutUpload",{name:"view.timelapse.selectedFiles",value:s})}createDirectory(){this.dialogCreateDirectory.name="",this.dialogCreateDirectory.show=!0,setTimeout(()=>{var s;(s=this.$refs.inputFieldCreateDirectory)==null||s.focus()},200)}createDirectoryAction(){this.dialogCreateDirectory.show=!1,this.$socket.emit("server.files.post_directory",{path:this.currentPath+"/"+this.dialogCreateDirectory.name},{action:"files/getCreateDir"})}refreshFileList(){this.$socket.emit("server.files.get_directory",{path:this.currentPath},{action:"files/getDirectory"})}advancedSearch(s,e){return s!=null&&e!=null&&typeof s=="string"&&s.toString().toLowerCase().indexOf(e.toLowerCase())!==-1}getThumbnail(s){var r;const e=s.filename.slice(0,s.filename.lastIndexOf(".")),t=(r=this.files)==null?void 0:r.find(i=>i.filename===e+".jpg");return t?"".concat(this.apiUrl,"/server/files/").concat(Ie(this.currentPath),"/").concat(Ie(t.filename),"?timestamp=").concat(t.modified.getTime()):""}clickRow(s,e=!1){(!this.contextMenu.shown||e)&&(e&&(this.contextMenu.shown=!1),s.isDirectory?this.currentPath+="/"+s.filename:s.filename.endsWith("zip")?this.downloadFile(s.filename):s.filename.endsWith("mp4")&&(this.videoDialogFilename=Ie("".concat(this.currentPath,"/").concat(s.filename)),this.boolVideoDialog=!0))}clickRowGoBack(){this.currentPath=this.currentPath.slice(0,this.currentPath.lastIndexOf("/"))}clickPathNavGoToDirectory(s){this.currentPath="".concat(this.rootDirectory).concat(s.location)}showContextMenu(s,e){this.contextMenu.shown||(s==null||s.preventDefault(),this.contextMenu.shown=!0,this.contextMenu.x=(s==null?void 0:s.clientX)||(s==null?void 0:s.pageX)||window.screenX/2,this.contextMenu.y=(s==null?void 0:s.clientY)||(s==null?void 0:s.pageY)||window.screenY/2,this.contextMenu.item=e,this.$nextTick(()=>{this.contextMenu.shown=!0}))}existsFramesZip(s){const e=s.filename.lastIndexOf("."),t=s.filename.slice(0,e)+".zip";return this.files.findIndex(r=>r.filename===t)!==-1}downloadFile(s){const e=this.currentPath+"/"+s,t=this.apiUrl+"/server/files/"+Ie(e);window.open(t)}async downloadSelectedFiles(){let s=[];const e=async(i,n)=>{for(const a of n){const o="".concat(i,"/").concat(a.filename);if(a.isDirectory&&a.childrens){await e(o,a.childrens);continue}if(s.push(o),a.filename.endsWith(".mp4")){const l=a.filename.lastIndexOf("."),u=a.filename.slice(0,l),c="".concat(u,".jpg");this.files.indexOf(d=>d.filename===c)!==-1&&s.push("".concat(i,"/").concat(c))}}};await e(this.currentPath,this.selectedFiles);const t=new Date,r="".concat(t.getFullYear()).concat(t.getMonth()).concat(t.getDate(),"-").concat(t.getHours()).concat(t.getMinutes()).concat(t.getSeconds());this.$socket.emit("server.files.zip",{items:s,dest:"timelapse/timelapse-".concat(r,".zip")},{action:"files/downloadZip",loading:"timelapseDownloadZip"}),this.selectedFiles=[]}renameFile(s){const e=s.filename.lastIndexOf(".");this.dialogRenameFile.newName=s.filename.slice(0,e),this.dialogRenameFile.item=s,this.dialogRenameFile.show=!0,setTimeout(()=>{var t;(t=this.$refs.inputFieldRenameFile)==null||t.focus()},200)}renameFileAction(){const s=this.dialogRenameFile.item.filename.lastIndexOf("."),e=this.dialogRenameFile.item.filename.slice(0,s),t=this.dialogRenameFile.item.filename.split(".").pop();if(this.dialogRenameFile.show=!1,this.$socket.emit("server.files.move",{source:"".concat(this.currentPath,"/").concat(this.dialogRenameFile.item.filename),dest:"".concat(this.currentPath,"/").concat(this.dialogRenameFile.newName,".").concat(t)},{action:"files/getMove"}),t!=="mp4")return;this.files.find(i=>i.filename==="".concat(e,".jpg"))&&this.$socket.emit("server.files.move",{source:"".concat(this.currentPath,"/").concat(e,".jpg"),dest:"".concat(this.currentPath,"/").concat(this.dialogRenameFile.newName,".jpg")})}renameDirectory(s){this.dialogRenameDirectory.item=s,this.dialogRenameDirectory.newName=s.filename,this.dialogRenameDirectory.show=!0,setTimeout(()=>{var e;(e=this.$refs.inputFieldRenameDirectory)==null||e.focus()},200)}renameDirectoryAction(){this.dialogRenameDirectory.show=!1,this.$socket.emit("server.files.move",{source:this.currentPath+"/"+this.dialogRenameDirectory.item.filename,dest:this.currentPath+"/"+this.dialogRenameDirectory.newName},{action:"files/getMove"})}removeFile(){const s=this.contextMenu.item.filename.slice(0,this.contextMenu.item.filename.lastIndexOf(".")),e=this.contextMenu.item.filename.split(".").pop();if(this.$socket.emit("server.files.delete_file",{path:this.currentPath+"/"+this.contextMenu.item.filename},{action:"files/getDeleteFile"}),e!=="mp4")return;const t=s+".jpg";this.files.findIndex(i=>i.filename===t)!==-1&&this.$socket.emit("server.files.delete_file",{path:this.currentPath+"/"+t},{action:"files/getDeleteFile"}),this.deleteDialog=!1}deleteDirectory(s){this.dialogDeleteDirectory.item=s,this.dialogDeleteDirectory.show=!0}deleteDirectoryAction(){this.dialogDeleteDirectory.show=!1,this.$socket.emit("server.files.delete_directory",{path:this.currentPath+"/"+this.contextMenu.item.filename,force:!0},{action:"files/getDeleteDir"})}deleteSelectedFiles(){this.selectedFiles.forEach(s=>{if(s.isDirectory)this.$socket.emit("server.files.delete_directory",{path:this.currentPath+"/"+s.filename,force:!0},{action:"files/getDeleteDir"});else{const e=s.filename.slice(0,s.filename.lastIndexOf(".")),t=s.filename.split(".").pop();if(this.$socket.emit("server.files.delete_file",{path:this.currentPath+"/"+s.filename},{action:"files/getDeleteFile"}),t!=="mp4")return;const r=e+".jpg";this.files.findIndex(n=>n.filename===r)!==-1&&this.$socket.emit("server.files.delete_file",{path:this.currentPath+"/"+r},{action:"files/getDeleteFile"})}}),this.selectedFiles=[],this.deleteSelectedDialog=!1}};Nh=PN([S({components:{Panel:U,PathNavigation:hn}})],Nh);var DN=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(U,{attrs:{title:e.$t("Timelapse.TimelapseFiles"),icon:e.mdiFileDocumentMultipleOutline,"card-class":"timelapse-files-panel"}},[t(Z,[t(x,[t(b,{staticClass:"col-12 d-flex align-center"},[t(se,{staticStyle:{"max-width":"300px"},attrs:{"append-icon":e.mdiMagnify,label:e.$t("Timelapse.Search"),"single-line":"",outlined:"",clearable:"","hide-details":"",dense:""},model:{value:e.search,callback:function(r){e.search=r},expression:"search"}}),t(ae),e.selectedFiles.length?t(g,{staticClass:"px-2 minwidth-0 ml-3",attrs:{title:e.$t("Timelapse.Download"),color:"primary",loading:e.loadings.includes("timelapseDownloadZip")},on:{click:e.downloadSelectedFiles}},[t(_,[e._v(e._s(e.mdiCloudDownload))])],1):e._e(),e.selectedFiles.length?t(g,{staticClass:"px-2 minwidth-0 ml-3",attrs:{title:e.$t("Timelapse.Delete"),color:"error"},on:{click:function(r){e.deleteSelectedDialog=!0}}},[t(_,[e._v(e._s(e.mdiDelete))])],1):e._e(),e.directoryPermissions.includes("w")?t(g,{staticClass:"px-2 minwidth-0 ml-3",attrs:{title:e.$t("Timelapse.CreateNewDirectory")},on:{click:e.createDirectory}},[t(_,[e._v(e._s(e.mdiFolderPlus))])],1):e._e(),t(g,{staticClass:"px-2 minwidth-0 ml-3",attrs:{title:e.$t("Timelapse.RefreshCurrentDirectory")},on:{click:e.refreshFileList}},[t(_,[e._v(e._s(e.mdiRefresh))])],1)],1)],1)],1),t(Z,[t(x,[t(b,{staticClass:"col-12 py-2 d-flex align-center"},[t("span",[t("b",{staticClass:"mr-1"},[e._v(e._s(e.$t("Timelapse.CurrentPath"))+":")]),t(hn,{attrs:{path:e.currentPathForNavigation,"base-directory-label":"/".concat(e.rootDirectory),"on-segment-click":e.clickPathNavGoToDirectory}})],1),t(ae),e.disk_usage!==null?[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("span",e._g(e._b({},"span",i,!1),r),[t("b",[e._v(e._s(e.$t("Timelapse.FreeDisk"))+":")]),e._v(" "+e._s(e.formatFilesize(e.disk_usage.free))+" ")])]}}],null,!1,2240604619)},[t("span",[e._v(" "+e._s(e.$t("Timelapse.Used"))+": "+e._s(e.formatFilesize(e.disk_usage.used))+" "),t("br"),e._v(" "+e._s(e.$t("Timelapse.Free"))+": "+e._s(e.formatFilesize(e.disk_usage.free))+" "),t("br"),e._v(" "+e._s(e.$t("Timelapse.Total"))+": "+e._s(e.formatFilesize(e.disk_usage.total))+" ")])])]:e._e()],2)],1)],1),t(I,{staticClass:"mb-3"}),t(Qr,{staticClass:"files-table",attrs:{items:e.displayFiles,headers:e.headers,"custom-sort":e.sortFiles,"sort-by":e.sortBy,"sort-desc":e.sortDesc,"items-per-page":e.countPerPage,"footer-props":{itemsPerPageText:e.$t("Timelapse.Files"),itemsPerPageAllText:e.$t("Timelapse.AllFiles"),itemsPerPageOptions:[10,25,50,100,-1]},"item-key":"filename",search:e.search,"custom-filter":e.advancedSearch,"mobile-breakpoint":"0","show-select":""},on:{"update:sortBy":function(r){e.sortBy=r},"update:sort-by":function(r){e.sortBy=r},"update:sortDesc":function(r){e.sortDesc=r},"update:sort-desc":function(r){e.sortDesc=r},"update:itemsPerPage":function(r){e.countPerPage=r},"update:items-per-page":function(r){e.countPerPage=r}},scopedSlots:e._u([{key:"no-data",fn:function(){return[t("div",{staticClass:"text-center font-italic"},[e._v(e._s(e.$t("Timelapse.Empty")))])]},proxy:!0},{key:"item",fn:function({index:r,item:i,isSelected:n,select:a}){return[t("tr",{directives:[{name:"longpress",rawName:"v-longpress:600",value:o=>e.showContextMenu(o,i),expression:"(e) => showContextMenu(e, item)",arg:"600"}],key:"".concat(r," ").concat(i.filename),staticClass:"file-list-cursor user-select-none",on:{contextmenu:function(o){return e.showContextMenu(o,i)},click:function(o){return e.clickRow(i)}}},[t("td",{staticClass:"file-list__select-td pr-0"},[t(jr,{directives:[{name:"ripple",rawName:"v-ripple"}],staticClass:"pa-0 mr-0",attrs:{value:n},on:{click:function(o){return o.stopPropagation(),a(!n)}}})],1),t("td",{staticClass:"px-0 text-center",staticStyle:{width:"32px"}},[i.isDirectory?[t(_,{attrs:{width:"32"}},[e._v(e._s(e.mdiFolder))])]:i.filename.endsWith("zip")?[t(_,{attrs:{width:"32"}},[e._v(e._s(e.mdiFolderZipOutline))])]:e.getThumbnail(i)?[!i.isDirectory&&e.getThumbnail(i)?t(de,{attrs:{top:"","content-class":"tooltip__content-opacity1"},scopedSlots:e._u([{key:"activator",fn:function({on:o,attrs:l}){return[t("vue-load-image",[t("img",e._g(e._b({attrs:{slot:"image",src:e.getThumbnail(i),alt:i.filename,width:"32"},slot:"image"},"img",l,!1),o)),t("div",{attrs:{slot:"preloader"},slot:"preloader"},[t(ot,{attrs:{slot:"preloader",indeterminate:"",color:"primary"},slot:"preloader"})],1),t("div",{attrs:{slot:"error"},slot:"error"},[t(_,[e._v(e._s(e.mdiFile))])],1)])]}}],null,!0)},[t("span",[t("img",{attrs:{src:e.getThumbnail(i),alt:i.filename,width:"250"}})])]):e._e()]:[t(_,[e._v(e._s(e.mdiFile))])]],2),t("td",{staticClass:""},[e._v(e._s(i.filename))]),e.headers.find(o=>o.value==="size").visible?t("td",{staticClass:"text-no-wrap text-right"},[e._v(" "+e._s(i.isDirectory?"--":e.formatFilesize(i.size))+" ")]):e._e(),e.headers.find(o=>o.value==="modified").visible?t("td",{staticClass:"text-right"},[e._v(" "+e._s(e.formatDateTime(i.modified))+" ")]):e._e()])]}}]),model:{value:e.selectedFiles,callback:function(r){e.selectedFiles=r},expression:"selectedFiles"}},[t("template",{slot:"items"},e._l(e.headers,function(r){return t("td",{key:r.value},[e._v(e._s(r.text))])}),0),e.currentPath!==e.rootDirectory?t("template",{slot:"body.prepend"},[t("tr",{staticClass:"file-list-cursor",on:{click:e.clickRowGoBack}},[t("td",{staticClass:"pr-0 text-center",staticStyle:{width:"32px"}},[t(_,[e._v(e._s(e.mdiFolderUpload))])],1),t("td",{staticClass:"",attrs:{colspan:e.headers.length}},[e._v("..")])])]):e._e()],2)],1),t(ye,{attrs:{"position-x":e.contextMenu.x,"position-y":e.contextMenu.y,absolute:"","offset-y":""},model:{value:e.contextMenu.shown,callback:function(r){e.$set(e.contextMenu,"shown",r)},expression:"contextMenu.shown"}},[t(Me,[e.contextMenu.item.isDirectory?e._e():t(J,{on:{click:function(r){return e.downloadFile(e.contextMenu.item.filename)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiCloudDownload))]),e._v(" "+e._s(e.$t("Timelapse.Download"))+" ")],1),e.contextMenu.item.isDirectory&&e.contextMenu.item.permissions.includes("w")?t(J,{on:{click:function(r){return e.renameDirectory(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiRenameBox))]),e._v(" "+e._s(e.$t("Timelapse.Rename"))+" ")],1):e._e(),!e.contextMenu.item.isDirectory&&e.contextMenu.item.permissions.includes("w")?t(J,{on:{click:function(r){return e.renameFile(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiRenameBox))]),e._v(" "+e._s(e.$t("Timelapse.Rename"))+" ")],1):e._e(),!e.contextMenu.item.isDirectory&&e.contextMenu.item.permissions.includes("w")?t(J,{staticClass:"red--text",on:{click:function(r){e.deleteDialog=!0}}},[t(_,{staticClass:"mr-1",attrs:{color:"error"}},[e._v(e._s(e.mdiDelete))]),e._v(" "+e._s(e.$t("Timelapse.Delete"))+" ")],1):e._e(),e.contextMenu.item.isDirectory&&e.contextMenu.item.permissions.includes("w")?t(J,{staticClass:"red--text",on:{click:function(r){return e.deleteDirectory(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1",attrs:{color:"error"}},[e._v(e._s(e.mdiDelete))]),e._v(" "+e._s(e.$t("Timelapse.Delete"))+" ")],1):e._e()],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.dialogRenameFile.show,callback:function(r){e.$set(e.dialogRenameFile,"show",r)},expression:"dialogRenameFile.show"}},[t(U,{attrs:{title:e.$t("Timelapse.RenameFile"),"card-class":"gcode-files-rename-file-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.dialogRenameFile.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputFieldRenameFile",attrs:{label:e.$t("Timelapse.Name"),required:"",rules:e.nameInputRules},on:{"update:error":r=>e.isInvalidName=r,keypress:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"enter",13,r.key,"Enter")?null:e.renameFileAction.apply(null,arguments)}},model:{value:e.dialogRenameFile.newName,callback:function(r){e.$set(e.dialogRenameFile,"newName",r)},expression:"dialogRenameFile.newName"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.dialogRenameFile.show=!1}}},[e._v(e._s(e.$t("Timelapse.Cancel")))]),t(g,{attrs:{disabled:e.isInvalidName,color:"primary",text:""},on:{click:e.renameFileAction}},[e._v(" "+e._s(e.$t("Timelapse.Rename"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.dialogCreateDirectory.show,callback:function(r){e.$set(e.dialogCreateDirectory,"show",r)},expression:"dialogCreateDirectory.show"}},[t(U,{attrs:{title:e.$t("Timelapse.NewDirectory"),"card-class":"gcode-files-new-directory-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.dialogCreateDirectory.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputFieldCreateDirectory",attrs:{label:e.$t("Timelapse.Name"),required:"",rules:e.nameInputRules},on:{"update:error":r=>e.isInvalidName=r,keypress:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"enter",13,r.key,"Enter")?null:e.createDirectoryAction.apply(null,arguments)}},model:{value:e.dialogCreateDirectory.name,callback:function(r){e.$set(e.dialogCreateDirectory,"name",r)},expression:"dialogCreateDirectory.name"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.dialogCreateDirectory.show=!1}}},[e._v(" "+e._s(e.$t("Timelapse.Cancel"))+" ")]),t(g,{attrs:{disabled:e.isInvalidName,color:"primary",text:""},on:{click:e.createDirectoryAction}},[e._v(" "+e._s(e.$t("Timelapse.Create"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.dialogRenameDirectory.show,callback:function(r){e.$set(e.dialogRenameDirectory,"show",r)},expression:"dialogRenameDirectory.show"}},[t(U,{attrs:{title:e.$t("Timelapse.RenameDirectory"),"card-class":"gcode-files-rename-directory-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.dialogRenameDirectory.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputFieldRenameDirectory",attrs:{label:e.$t("Timelapse.Name"),required:"",rules:e.nameInputRules},on:{"update:error":r=>e.isInvalidName=r,keyup:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"enter",13,r.key,"Enter")?null:e.renameDirectoryAction.apply(null,arguments)}},model:{value:e.dialogRenameDirectory.newName,callback:function(r){e.$set(e.dialogRenameDirectory,"newName",r)},expression:"dialogRenameDirectory.newName"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.dialogRenameDirectory.show=!1}}},[e._v(" "+e._s(e.$t("Timelapse.Cancel"))+" ")]),t(g,{attrs:{disabled:e.isInvalidName,color:"primary",text:""},on:{click:e.renameDirectoryAction}},[e._v(" "+e._s(e.$t("Timelapse.Rename"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.dialogDeleteDirectory.show,callback:function(r){e.$set(e.dialogDeleteDirectory,"show",r)},expression:"dialogDeleteDirectory.show"}},[t(U,{attrs:{title:e.$t("Timelapse.DeleteDirectory"),"card-class":"gcode-files-delete-directory-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.dialogDeleteDirectory.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t("p",{staticClass:"mb-0"},[e._v(" "+e._s(e.$t("Timelapse.DeleteDirectoryQuestion",{name:e.dialogDeleteDirectory.item.filename}))+" ")])]),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.dialogDeleteDirectory.show=!1}}},[e._v(" "+e._s(e.$t("Timelapse.Cancel"))+" ")]),t(g,{attrs:{color:"error",text:""},on:{click:e.deleteDirectoryAction}},[e._v(e._s(e.$t("Timelapse.Delete")))])],1)],1)],1),t(le,{attrs:{"max-width":700},model:{value:e.boolVideoDialog,callback:function(r){e.boolVideoDialog=r},expression:"boolVideoDialog"}},[t(U,{attrs:{title:e.$t("Timelapse.Video"),icon:e.mdiFileVideo,"card-class":"timelapse-video-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.boolVideoDialog=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{},[t(x,[t(b,{staticClass:"pb-0"},[t("video",{staticStyle:{width:"100%"},attrs:{src:e.apiUrl+"/server/files/"+e.videoDialogFilename,controls:""}},[e._v(" Sorry, your browser doesn't support embedded videos, but don't worry, you can "),t("a",{attrs:{href:e.apiUrl+"/server/files/"+e.videoDialogFilename}},[e._v("download it")]),e._v(" and watch it with your favorite video player! ")])])],1),t(x,[t(b,{staticClass:"text-center"},[t(g,{attrs:{text:"",color:"primary",href:e.apiUrl+"/server/files/"+e.videoDialogFilename,target:"_blank"}},[e._v(" "+e._s(e.$t("Timelapse.Download"))+" ")])],1)],1)],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.deleteDialog,callback:function(r){e.deleteDialog=r},expression:"deleteDialog"}},[t(U,{attrs:{title:e.$t("Timelapse.Delete"),"card-class":"timelapse-delete-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.deleteDialog=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t("p",{staticClass:"mb-0"},[e._v(" "+e._s(e.$t("Timelapse.DeleteSingleFileQuestion",{name:e.contextMenu.item.filename}))+" ")])]),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.deleteDialog=!1}}},[e._v(" "+e._s(e.$t("Timelapse.Cancel"))+" ")]),t(g,{attrs:{color:"error",text:""},on:{click:e.removeFile}},[e._v(" "+e._s(e.$t("Timelapse.Delete"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.deleteSelectedDialog,callback:function(r){e.deleteSelectedDialog=r},expression:"deleteSelectedDialog"}},[t(U,{attrs:{title:e.$t("Timelapse.Delete"),"card-class":"timelapse-delete-selected-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.deleteSelectedDialog=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[e.selectedFiles.length===1?t("p",{staticClass:"mb-0"},[e._v(" "+e._s(e.$t("Timelapse.DeleteSingleFileQuestion",{name:e.selectedFiles[0].filename}))+" ")]):t("p",{staticClass:"mb-0"},[e._v(" "+e._s(e.$t("Timelapse.DeleteSelectedQuestion",{count:e.selectedFiles.length}))+" ")])]),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(r){e.deleteSelectedDialog=!1}}},[e._v(e._s(e.$t("Timelapse.Cancel")))]),t(g,{attrs:{color:"error",text:""},on:{click:e.deleteSelectedFiles}},[e._v(e._s(e.$t("Timelapse.Delete")))])],1)],1)],1)],1)},TN=[],ON=E(Nh,DN,TN,!1,null,"594d4cbf");const Hy=ON.exports;var MN=Object.getOwnPropertyDescriptor,kN=(s,e,t,r)=>{for(var i=r>1?void 0:r?MN(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Vh=class extends k(L){};Vh=kN([S({components:{TimelapseStatusPanel:Ry,TimelapseFilesPanel:Hy}})],Vh);var EN=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,[t(b,{staticClass:"col-12 col-md-8 pt-0 pt-md-3",attrs:{order:e.$vuetify.breakpoint.mdAndUp?"":"2"}},[t(Hy)],1),t(b,{staticClass:"col-12 col-md-4",attrs:{order:e.$vuetify.breakpoint.mdAndUp?"":"1"}},[t(Ry)],1)],1)},LN=[],AN=E(Vh,EN,LN,!1,null,"b10baa86");const FN=AN.exports;var RN=Object.defineProperty,HN=Object.getOwnPropertyDescriptor,jy=(s,e,t,r)=>{for(var i=r>1?void 0:r?HN(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&RN(e,t,i),i};let Mc=class extends k(L){constructor(){super(...arguments),this.mdiDownload=K_}get logfiles(){var e,t;return(t=(e=this.$store.getters["files/getDirectory"]("logs"))==null?void 0:e.childrens)!=null?t:[]}get filename(){return this.name+".log"}get exists(){return["klippy","moonraker"].includes(this.name)?!0:this.logfiles.findIndex(e=>e.filename===this.filename)!==-1}get href(){let e="/server/files/logs/";return["klippy","moonraker"].includes(this.name)&&(e="/server/files/"),this.apiUrl+e+this.filename}get classes(){const e=["col-12","pt-0"];return this.klipperState!=="ready"?(e.push("col-md-6"),e.push("mt-md-3")):e.push("col-md-12"),e}downloadLog(e){e.preventDefault();let t="";"href"in e.target.attributes&&(t=e.target.attributes.href.value),"href"in e.target.parentElement.attributes&&(t=e.target.parentElement.attributes.href.value),window.open(t)}};jy([w({type:String,required:!0})],Mc.prototype,"name",2);Mc=jy([S({components:{Panel:U}})],Mc);var jN=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.exists?t(b,{class:e.classes},[t(g,{staticClass:"primary--text",attrs:{href:e.href,block:""},on:{click:e.downloadLog}},[t(_,{staticClass:"mr-2"},[e._v(e._s(e.mdiDownload))]),e._v(" "+e._s(e.name)+" ")],1)],1):e._e()},IN=[],NN=E(Mc,jN,IN,!1,null,null);const Xf=NN.exports;var VN=Object.defineProperty,BN=Object.getOwnPropertyDescriptor,Yf=(s,e,t,r)=>{for(var i=r>1?void 0:r?BN(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&VN(e,t,i),i};let ka=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiFileSyncOutline=sv,this.rolloverLogfiles=cw,this.capitalize=lr,this.selectedRolloverLogs=[]}get loadingRolloverLogs(){return this.loadings.filter(s=>s==null?void 0:s.startsWith("rolloverLog_")).length>0}loadingRolloverLogsChanged(s){s&&this.closeDialog()}btnRolloverLogs(){this.selectedRolloverLogs.length!==0&&(this.selectedRolloverLogs.forEach(s=>{this.$socket.emit("server.logs.rollover",{application:s},{loading:"rolloverLog_"+s,action:"files/rolloverLog"})}),this.selectedRolloverLogs=[])}closeDialog(){this.$emit("close-dialog")}};Yf([w({type:Boolean,default:!1})],ka.prototype,"show",2);Yf([he("loadingRolloverLogs")],ka.prototype,"loadingRolloverLogsChanged",1);ka=Yf([S({components:{LogfilesPanelGenericLog:Xf,Panel:U}})],ka);var UN=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{value:e.show,persistent:"",width:"400",fullscreen:e.isMobile}},[t(U,{attrs:{title:e.$t("Machine.LogfilesPanel.Rollover"),"card-class":"machine_rollover_logfiles-dialog",icon:e.mdiFileSyncOutline,"margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(x,[t(b,[t("p",{staticClass:"mb-0"},[e._v(e._s(e.$t("Machine.LogfilesPanel.RolloverDescription")))])])],1),t(x,{staticClass:"mt-0"},[t(b,e._l(e.rolloverLogfiles,function(r){return t(ge,{key:r,staticClass:"mt-0",attrs:{label:e.capitalize(r),value:r,"hide-details":""},model:{value:e.selectedRolloverLogs,callback:function(i){e.selectedRolloverLogs=i},expression:"selectedRolloverLogs"}})}),1)],1)],1),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.closeDialog}},[e._v(" "+e._s(e.$t("Machine.LogfilesPanel.Cancel"))+" ")]),t(g,{attrs:{color:"primary",text:""},on:{click:e.btnRolloverLogs}},[e._v(" "+e._s(e.$t("Machine.LogfilesPanel.Accept"))+" ")])],1)],1)],1)},WN=[],zN=E(ka,UN,WN,!1,null,null);const GN=zN.exports;var ZN=Object.getOwnPropertyDescriptor,qN=(s,e,t,r)=>{for(var i=r>1?void 0:r?ZN(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Bh=class extends k(L){constructor(){super(...arguments),this.mdiFileDocumentEdit=Bw,this.mdiFileSyncOutline=sv,this.genericLogfiles=lw,this.showRolloverDialog=!1}};Bh=qN([S({components:{LogfilesPanelGenericLog:Xf,Panel:U}})],Bh);var XN=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(U,{attrs:{title:e.$t("Machine.LogfilesPanel.Logfiles"),icon:e.mdiFileDocumentEdit,"card-class":"machine-logfiles-panel",collapsible:!0},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{icon:"",tile:"",color:"primary",ripple:!0,loading:e.loadings.includes("loadingBtnRolloverLogs"),disabled:["printing","paused"].includes(e.printer_state)},on:{click:function(n){e.showRolloverDialog=!0}}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiFileSyncOutline))])],1)]}}])},[t("span",[e._v(e._s(e.$t("Machine.LogfilesPanel.Rollover")))])])]},proxy:!0}])},[t(Z,{class:"text-center text-lg-left"},[t(x,{staticClass:"pt-3"},e._l(e.genericLogfiles,function(r){return t(Xf,{key:r,attrs:{name:r}})}),1)],1)],1),t(GN,{attrs:{show:e.showRolloverDialog},on:{"close-dialog":function(r){e.showRolloverDialog=!1}}})],1)},YN=[],JN=E(Bh,XN,YN,!1,null,null);const Iy=JN.exports;var KN=Object.defineProperty,QN=Object.getOwnPropertyDescriptor,Ny=(s,e,t,r)=>{for(var i=r>1?void 0:r?QN(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&KN(e,t,i),i};let kc=class extends k(L){get name(){return this.item.type==="endstop"?this.item.name.toUpperCase():Ye(this.item.name)}get chipColor(){return this.item.value==="open"?"green":"red"}get value(){return this.item.value==="open"?this.$t("Machine.EndstopPanel.open"):this.$t("Machine.EndstopPanel.TRIGGERED")}};Ny([w({type:Object})],kc.prototype,"item",2);kc=Ny([S({components:{Panel:U}})],kc);var eV=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,[t(b,{staticClass:"py-1"},[t("label",{staticClass:"mt-1 d-inline-block"},[e.item.type==="endstop"?t("span",{staticClass:"mr-2"},[e._v(e._s(e.$t("Machine.EndstopPanel.Endstop")))]):e._e(),t("b",[e._v(e._s(e.name))])]),t($s,{staticClass:"float-right",attrs:{small:"",label:"",color:e.chipColor,"text-color":"white"}},[e._v(e._s(e.value))])],1)],1)},tV=[],sV=E(kc,eV,tV,!1,null,null);const rV=sV.exports;var iV=Object.getOwnPropertyDescriptor,nV=(s,e,t,r)=>{for(var i=r>1?void 0:r?iV(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Uh=class extends k(L){constructor(){super(...arguments),this.mdiArrowExpandVertical=fw,this.mdiSync=wv}get items(){var t,r;let s=[];const e=(t=this.$store.state.printer.endstops)!=null?t:{};if(Object.keys(e).forEach(i=>{s.push({type:"endstop",name:i,value:e[i]})}),s.length===0)return[];if(s=s.sort((i,n)=>i.name.localeCompare(n.name)),"probe"in this.$store.state.printer&&"last_query"in this.$store.state.printer.probe){const i=this.$store.state.printer.probe.last_query?"TRIGGERED":"open";s.push({type:"probe",name:(r=this.$store.state.printer.probe.name)!=null?r:"probe",value:i})}return s}get existsQueryProbe(){var e,t;const s=(t=(e=this.$store.state.printer.gcode)==null?void 0:e.commands)!=null?t:null;return s?"QUERY_PROBE"in s:"probe"in this.$store.state.printer}syncEndstops(){this.$socket.emit("printer.query_endstops.status",{},{action:"printer/getEndstopStatus",loading:"queryEndstops"}),this.existsQueryProbe&&(this.$store.dispatch("server/addEvent",{message:"QUERY_PROBE",type:"command"}),this.$socket.emit("printer.gcode.script",{script:"QUERY_PROBE"}))}};Uh=nV([S({components:{Panel:U}})],Uh);var aV=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(U,{attrs:{title:e.$t("Machine.EndstopPanel.Endstops"),icon:e.mdiArrowExpandVertical,"card-class":"machine-endstop-panel",collapsible:!0}},[t(Z,{staticClass:"pb-0 pt-6"},[e._l(e.items,function(r){return t(rV,{key:r.name,attrs:{item:r}})}),e.items.length===0?t(x,[t(b,{staticClass:"pt-0"},[t("p",{staticClass:"mb-0"},[e._v(e._s(e.$t("Machine.EndstopPanel.EndstopInfo")))])])],1):e._e()],2),t(oe,{staticClass:"pt-3"},[t(ae),t(g,{attrs:{icon:"",loading:e.loadings.includes("queryEndstops")},on:{click:e.syncEndstops}},[t(_,[e._v(e._s(e.mdiSync))])],1)],1)],1)},oV=[],lV=E(Uh,aV,oV,!1,null,null);const Vy=lV.exports;var cV=Object.defineProperty,uV=Object.getOwnPropertyDescriptor,Jf=(s,e,t,r)=>{for(var i=r>1?void 0:r?uV(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&cV(e,t,i),i};let Ea=class extends k(L){constructor(){super(...arguments),this.mdiDotsHorizontal=Iw,this.showDetails=!1}get title(){return this.commit.subject}get message(){return this.commit.message}get author(){return this.commit.author}get commitFormatDate(){const s=new Date(this.commit.date*1e3);s.setHours(0,0,0,0);const e=new Date;e.setHours(0,0,0,0);const t=Math.floor((e.getTime()-s.getTime())/(1e3*60*60*24));if(t===0){const r=Math.floor((new Date().getTime()-this.commit.date*1e3)/36e5);return this.$t("Machine.UpdatePanel.CommittedHoursAgo",{hours:r})}else return t===1?this.$t("Machine.UpdatePanel.CommittedYesterday"):t<29?this.$t("Machine.UpdatePanel.CommittedDaysAgo",{days:t}):this.$t("Machine.UpdatePanel.CommittedOnDate",{date:s.toLocaleDateString(this.browserLocale,{year:"numeric",month:"short",day:"numeric"})})}get repo_name(){var s,e;return(e=(s=this.repo.repo_name)!=null?s:this.repo.name)!=null?e:""}get commitHref(){return"https://github.com/".concat(this.repo.owner,"/").concat(this.repo_name,"/commit/").concat(this.commit.sha)}get commitShortSha(){return this.commit.sha.substring(0,6)}};Jf([w({required:!0})],Ea.prototype,"commit",2);Jf([w({required:!0})],Ea.prototype,"repo",2);Ea=Jf([S({components:{Panel:U}})],Ea);var dV=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("li",{staticClass:"commit px-3 py-2"},[t(x,{staticClass:"flex-column flex-sm-row"},[t(b,[t("h4",{staticClass:"subtitle-2 text--white mb-0"},[e._v(" "+e._s(e.title)+" "),t($s,{staticClass:"ml-2 px-2",attrs:{outlined:"",label:"","x-small":""},on:{click:function(r){e.showDetails=!e.showDetails}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiDotsHorizontal))])],1)],1),e.showDetails?t("p",{staticClass:"caption text--secondary mb-2",staticStyle:{"white-space":"pre-line"},domProps:{innerHTML:e._s(e.message)}}):e._e(),t("p",{staticClass:"caption mb-0"},[t("span",{staticClass:"font-weight-bold text-decoration-none white--text"},[e._v(" "+e._s(e.author)+" ")]),t("span",[e._v(e._s(e.commitFormatDate))])])]),t(b,{staticClass:"col-auto pt-0 pt-sm-4"},[t($s,{attrs:{outlined:"",label:"",small:"",href:e.commitHref,target:"_blank"}},[e._v(" "+e._s(e.commitShortSha)+" ")])],1)],1)],1)},mV=[],hV=E(Ea,dV,mV,!1,null,"92f7e2cd");const By=hV.exports;var pV=Object.defineProperty,fV=Object.getOwnPropertyDescriptor,Kf=(s,e,t,r)=>{for(var i=r>1?void 0:r?fV(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&pV(e,t,i),i};let La=class extends k(L){get groupedCommitsDate(){return new Date(this.groupedCommits.date).toLocaleDateString(this.browserLocale,{year:"numeric",month:"short",day:"numeric"})}};Kf([w({required:!0})],La.prototype,"groupedCommits",2);Kf([w({required:!0})],La.prototype,"repo",2);La=Kf([S({components:{Panel:U,GitCommitsListDayCommit:By}})],La);var gV=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(Zn,{staticClass:"git-commit-list-day",attrs:{small:""}},[t(x,{staticClass:"pt-0"},[t(b,{staticClass:"pr-12"},[t("h3",{staticClass:"caption"},[e._v(" "+e._s(e.$t("Machine.UpdatePanel.CommitsOnDate",{date:e.groupedCommitsDate}))+" ")]),t("ul",{staticClass:"commits mt-3 pl-0"},e._l(e.groupedCommits.commits,function(r){return t(By,{key:r.sha,attrs:{commit:r,repo:e.repo}})}),1)])],1)],1)],1)},_V=[],vV=E(La,gV,_V,!1,null,"16ae9399");const uo=vV.exports;var bV=Object.defineProperty,yV=Object.getOwnPropertyDescriptor,Qf=(s,e,t,r)=>{for(var i=r>1?void 0:r?yV(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&bV(e,t,i),i};let Aa=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiAlertCircle=U_,this.mdiEye=Nw,this.mdiOpenInNew=gv}get name(){var s,e;return(e=(s=this.repo)==null?void 0:s.name)!=null?e:"UNKNOWN"}get formatName(){return lr(this.name)}get configured_type(){var s,e;return(e=(s=this.repo)==null?void 0:s.configured_type)!=null?e:"UNKNOWN"}get description1(){return this.name==="klipper"?this.$t("Machine.UpdatePanel.KlipperUpdateQuestionFirmware"):this.name==="moonraker"?this.$t("Machine.UpdatePanel.MoonrakerUpdateQuestion"):this.configured_type==="web"?this.$t("Machine.UpdatePanel.WebClientUpdateQuestion"):this.$t("Machine.UpdatePanel.GenericUpdateQuestion")}get description2(){return this.name==="klipper"?this.$t("Machine.UpdatePanel.KlipperUpdateQuestionConfig"):null}get repo_name(){var s,e;return(e=(s=this.repo.repo_name)!=null?s:this.repo.name)!=null?e:""}get externalLink(){var s;return this.name==="klipper"?"//www.klipper3d.org/Config_Changes.html":this.name==="moonraker"?"//moonraker.readthedocs.io/en/latest/changelog/":((s=this.repo)==null?void 0:s.configured_type)==="web"?"//github.com/".concat(this.repo.owner,"/").concat(this.repo_name,"/releases/tag/").concat(this.repo.remote_version):"//github.com/".concat(this.repo.owner,"/").concat(this.repo_name)}get externalLinkText(){return["klipper","moonraker"].includes(this.name)?this.$t("Machine.UpdatePanel.ConfigChanges"):this.$t("Machine.UpdatePanel.GitHubPage")}openCommitHistory(){this.$emit("open-commit-history")}};Qf([w({required:!0})],Aa.prototype,"repo",2);Qf([w({required:!1,default:!1})],Aa.prototype,"boolTitle",2);Aa=Qf([S({components:{GitCommitsListDay:uo,Panel:U}})],Aa);var CV=function(){var r;var e=this,t=e._self._c;return e._self._setupProxy,t(it,{attrs:{text:"",dense:"",border:"left",color:"orange",icon:e.mdiAlertCircle}},[e.boolTitle?[t("strong",[e._v(e._s(e.$t("Machine.UpdatePanel.UpdateWarning",{name:e.formatName})))]),t("br")]:e._e(),e.description1?t("p",[e._v(e._s(e.description1))]):e._e(),e.description2?t("p",[e._v(e._s(e.description2))]):e._e(),t("div",{staticClass:"text-center"},[e.configured_type==="git_repo"&&((r=e.repo.commits_behind)!=null&&r.length)?t(g,{staticClass:"mx-2 mt-3 mt-sm-0",on:{click:e.openCommitHistory}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiEye))]),e._v(" "+e._s(e.$t("Machine.UpdatePanel.CommitHistory"))+" ")],1):e._e(),e.externalLink?t(g,{staticClass:"mx-2 mt-3 mt-sm-0",attrs:{href:e.externalLink,target:"_blank"}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiOpenInNew))]),e._v(" "+e._s(e.externalLinkText)+" ")],1):e._e()],1)],2)},$V=[],xV=E(Aa,CV,$V,!1,null,null);const sd=xV.exports;var wV=Object.defineProperty,SV=Object.getOwnPropertyDescriptor,eg=(s,e,t,r)=>{for(var i=r>1?void 0:r?SV(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&wV(e,t,i),i};let Fa=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiProgressQuestion=bv,this.checkboxUpdateQuestion=!1}doUpdate(){this.$emit("do-update")}openCommitHistory(){this.$emit("open-commit-history")}closeDialog(){this.$emit("close-dialog")}};eg([w({required:!0})],Fa.prototype,"boolShowDialog",2);eg([w({required:!0})],Fa.prototype,"repo",2);Fa=eg([S({components:{GitCommitsListDay:uo,Panel:U,UpdateHintAlert:sd}})],Fa);var PV=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{persistent:"","max-width":"600"},model:{value:e.boolShowDialog,callback:function(r){e.boolShowDialog=r},expression:"boolShowDialog"}},[t(U,{attrs:{title:e.$t("Machine.UpdatePanel.AreYouSure"),icon:e.mdiProgressQuestion,"margin-bottom":!1,"card-class":"machine-update-hint-dialog"},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(x,[t(b,[t(sd,{attrs:{repo:e.repo},on:{"open-commit-history":e.openCommitHistory}}),t("div",[t(ge,{attrs:{label:e.$t("Machine.UpdatePanel.IUnderstandTheRisks"),"hide-details":""},model:{value:e.checkboxUpdateQuestion,callback:function(r){e.checkboxUpdateQuestion=r},expression:"checkboxUpdateQuestion"}})],1)],1)],1)],1),t(I),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.closeDialog}},[e._v(e._s(e.$t("Machine.UpdatePanel.Abort")))]),t(g,{attrs:{text:"",color:"primary",disabled:!e.checkboxUpdateQuestion},on:{click:e.doUpdate}},[e._v(" "+e._s(e.$t("Machine.UpdatePanel.StartUpdate"))+" ")])],1)],1)],1)},DV=[],TV=E(Fa,PV,DV,!1,null,null);const Uy=TV.exports;var OV=Object.defineProperty,MV=Object.getOwnPropertyDescriptor,tg=(s,e,t,r)=>{for(var i=r>1?void 0:r?MV(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&OV(e,t,i),i};let Ra=class extends k(L){constructor(){super(...arguments),this.mdiUpdate=Xa,this.mdiCloseThick=pe}get commitsBehind(){var s,e;return(e=(s=this.repo)==null?void 0:s.commits_behind)!=null?e:[]}get groupedCommits(){let s=[],e=null;return this.commitsBehind.forEach(t=>{var n;const r=new Date(((n=e==null?void 0:e.date)!=null?n:0)*1e3),i=new Date(t.date*1e3);(i.getFullYear()!==r.getFullYear()||i.getMonth()!==r.getMonth()||i.getDate()!==r.getDate())&&s.push({date:i,commits:[]}),s[s.length-1].commits.push(t),e=t}),s}get displayFullHistoryWaring(){return this.commitsBehind.length>=30}get lastCommit(){return this.commitsBehind.slice(-1)[0]}get linkToGithub(){var s,e,t,r;return"https://github.com/".concat((s=this.repo)==null?void 0:s.owner,"/").concat((e=this.repo)==null?void 0:e.repo_name,"/commits/").concat((t=this.repo)==null?void 0:t.branch,"/?after=").concat((r=this.lastCommit)==null?void 0:r.sha,"+0")}get overlayScrollbarsStyle(){return this.isMobile?{height:"calc(100vh - 48px)"}:{height:"400px"}}get timelineClassName(){return this.isMobile?["groupedCommits","mobile"]:["groupedCommits"]}closeDialog(){this.$emit("close-dialog")}};tg([w({required:!0})],Ra.prototype,"boolShowDialog",2);tg([w({required:!0})],Ra.prototype,"repo",2);Ra=tg([S({components:{GitCommitsListDay:uo,Panel:U}})],Ra);var kV=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{persistent:"","max-width":800,fullscreen:e.isMobile},model:{value:e.boolShowDialog,callback:function(r){e.boolShowDialog=r},expression:"boolShowDialog"}},[t(U,{attrs:{title:e.$t("Machine.UpdatePanel.Commits"),icon:e.mdiUpdate,"margin-bottom":!1,"card-class":"machine-update-commits-dialog"},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{staticClass:"py-0 px-0"},[t("overlay-scrollbars",{style:e.overlayScrollbarsStyle,attrs:{options:{overflowBehavior:{x:"hidden"}}}},[t(M_,{class:e.timelineClassName,staticStyle:{"min-height":"100%"},attrs:{"align-top":"",dense:""}},[e._l(e.groupedCommits,function(r){return t(uo,{key:r.date.getTime(),attrs:{repo:e.repo,"grouped-commits":r}})}),e.displayFullHistoryWaring?t(Zn,{staticClass:"git-commit-list-day git-commit-list-warning",attrs:{small:""}},[t(x,{staticClass:"pt-0"},[t(b,{staticClass:"pr-12"},[t(it,{attrs:{dense:"",text:"",type:"info"}},[t("p",[e._v(e._s(e.$t("Machine.UpdatePanel.MoreCommitsInfo")))]),t("div",{staticClass:"text-center mb-3"},[t(g,{attrs:{href:e.linkToGithub,target:"_blank"}},[e._v(" "+e._s(e.$t("Machine.UpdatePanel.LinkToGithub"))+" ")])],1)])],1)],1)],1):e._e()],2)],1)],1)],1)],1)},EV=[],LV=E(Ra,kV,EV,!1,null,"d66de5bf");const sg=LV.exports;var Wh={exports:{}};const AV="2.0.0",Wy=256,FV=Number.MAX_SAFE_INTEGER||9007199254740991,RV=16,HV=Wy-6,jV=["major","premajor","minor","preminor","patch","prepatch","prerelease"];var rd={MAX_LENGTH:Wy,MAX_SAFE_COMPONENT_LENGTH:RV,MAX_SAFE_BUILD_LENGTH:HV,MAX_SAFE_INTEGER:FV,RELEASE_TYPES:jV,SEMVER_SPEC_VERSION:AV,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2},Xd={};const IV=typeof process=="object"&&Xd&&Xd.NODE_DEBUG&&/\bsemver\b/i.test(Xd.NODE_DEBUG)?(...s)=>console.error("SEMVER",...s):()=>{};var id=IV;(function(s,e){const{MAX_SAFE_COMPONENT_LENGTH:t,MAX_SAFE_BUILD_LENGTH:r,MAX_LENGTH:i}=rd,n=id;e=s.exports={};const a=e.re=[],o=e.safeRe=[],l=e.src=[],u=e.safeSrc=[],c=e.t={};let d=0;const m="[a-zA-Z0-9-]",h=[["\\s",1],["\\d",i],[m,r]],f=v=>{for(const[C,P]of h)v=v.split("".concat(C,"*")).join("".concat(C,"{0,").concat(P,"}")).split("".concat(C,"+")).join("".concat(C,"{1,").concat(P,"}"));return v},p=(v,C,P)=>{const M=f(C),F=d++;n(v,F,C),c[v]=F,l[F]=C,u[F]=M,a[F]=new RegExp(C,P?"g":void 0),o[F]=new RegExp(M,P?"g":void 0)};p("NUMERICIDENTIFIER","0|[1-9]\\d*"),p("NUMERICIDENTIFIERLOOSE","\\d+"),p("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-]".concat(m,"*")),p("MAINVERSION","(".concat(l[c.NUMERICIDENTIFIER],")\\.")+"(".concat(l[c.NUMERICIDENTIFIER],")\\.")+"(".concat(l[c.NUMERICIDENTIFIER],")")),p("MAINVERSIONLOOSE","(".concat(l[c.NUMERICIDENTIFIERLOOSE],")\\.")+"(".concat(l[c.NUMERICIDENTIFIERLOOSE],")\\.")+"(".concat(l[c.NUMERICIDENTIFIERLOOSE],")")),p("PRERELEASEIDENTIFIER","(?:".concat(l[c.NUMERICIDENTIFIER],"|").concat(l[c.NONNUMERICIDENTIFIER],")")),p("PRERELEASEIDENTIFIERLOOSE","(?:".concat(l[c.NUMERICIDENTIFIERLOOSE],"|").concat(l[c.NONNUMERICIDENTIFIER],")")),p("PRERELEASE","(?:-(".concat(l[c.PRERELEASEIDENTIFIER],"(?:\\.").concat(l[c.PRERELEASEIDENTIFIER],")*))")),p("PRERELEASELOOSE","(?:-?(".concat(l[c.PRERELEASEIDENTIFIERLOOSE],"(?:\\.").concat(l[c.PRERELEASEIDENTIFIERLOOSE],")*))")),p("BUILDIDENTIFIER","".concat(m,"+")),p("BUILD","(?:\\+(".concat(l[c.BUILDIDENTIFIER],"(?:\\.").concat(l[c.BUILDIDENTIFIER],")*))")),p("FULLPLAIN","v?".concat(l[c.MAINVERSION]).concat(l[c.PRERELEASE],"?").concat(l[c.BUILD],"?")),p("FULL","^".concat(l[c.FULLPLAIN],"$")),p("LOOSEPLAIN","[v=\\s]*".concat(l[c.MAINVERSIONLOOSE]).concat(l[c.PRERELEASELOOSE],"?").concat(l[c.BUILD],"?")),p("LOOSE","^".concat(l[c.LOOSEPLAIN],"$")),p("GTLT","((?:<|>)?=?)"),p("XRANGEIDENTIFIERLOOSE","".concat(l[c.NUMERICIDENTIFIERLOOSE],"|x|X|\\*")),p("XRANGEIDENTIFIER","".concat(l[c.NUMERICIDENTIFIER],"|x|X|\\*")),p("XRANGEPLAIN","[v=\\s]*(".concat(l[c.XRANGEIDENTIFIER],")")+"(?:\\.(".concat(l[c.XRANGEIDENTIFIER],")")+"(?:\\.(".concat(l[c.XRANGEIDENTIFIER],")")+"(?:".concat(l[c.PRERELEASE],")?").concat(l[c.BUILD],"?")+")?)?"),p("XRANGEPLAINLOOSE","[v=\\s]*(".concat(l[c.XRANGEIDENTIFIERLOOSE],")")+"(?:\\.(".concat(l[c.XRANGEIDENTIFIERLOOSE],")")+"(?:\\.(".concat(l[c.XRANGEIDENTIFIERLOOSE],")")+"(?:".concat(l[c.PRERELEASELOOSE],")?").concat(l[c.BUILD],"?")+")?)?"),p("XRANGE","^".concat(l[c.GTLT],"\\s*").concat(l[c.XRANGEPLAIN],"$")),p("XRANGELOOSE","^".concat(l[c.GTLT],"\\s*").concat(l[c.XRANGEPLAINLOOSE],"$")),p("COERCEPLAIN","(^|[^\\d])(\\d{1,".concat(t,"})")+"(?:\\.(\\d{1,".concat(t,"}))?")+"(?:\\.(\\d{1,".concat(t,"}))?")),p("COERCE","".concat(l[c.COERCEPLAIN],"(?:$|[^\\d])")),p("COERCEFULL",l[c.COERCEPLAIN]+"(?:".concat(l[c.PRERELEASE],")?")+"(?:".concat(l[c.BUILD],")?")+"(?:$|[^\\d])"),p("COERCERTL",l[c.COERCE],!0),p("COERCERTLFULL",l[c.COERCEFULL],!0),p("LONETILDE","(?:~>?)"),p("TILDETRIM","(\\s*)".concat(l[c.LONETILDE],"\\s+"),!0),e.tildeTrimReplace="$1~",p("TILDE","^".concat(l[c.LONETILDE]).concat(l[c.XRANGEPLAIN],"$")),p("TILDELOOSE","^".concat(l[c.LONETILDE]).concat(l[c.XRANGEPLAINLOOSE],"$")),p("LONECARET","(?:\\^)"),p("CARETTRIM","(\\s*)".concat(l[c.LONECARET],"\\s+"),!0),e.caretTrimReplace="$1^",p("CARET","^".concat(l[c.LONECARET]).concat(l[c.XRANGEPLAIN],"$")),p("CARETLOOSE","^".concat(l[c.LONECARET]).concat(l[c.XRANGEPLAINLOOSE],"$")),p("COMPARATORLOOSE","^".concat(l[c.GTLT],"\\s*(").concat(l[c.LOOSEPLAIN],")$|^$")),p("COMPARATOR","^".concat(l[c.GTLT],"\\s*(").concat(l[c.FULLPLAIN],")$|^$")),p("COMPARATORTRIM","(\\s*)".concat(l[c.GTLT],"\\s*(").concat(l[c.LOOSEPLAIN],"|").concat(l[c.XRANGEPLAIN],")"),!0),e.comparatorTrimReplace="$1$2$3",p("HYPHENRANGE","^\\s*(".concat(l[c.XRANGEPLAIN],")")+"\\s+-\\s+"+"(".concat(l[c.XRANGEPLAIN],")")+"\\s*$"),p("HYPHENRANGELOOSE","^\\s*(".concat(l[c.XRANGEPLAINLOOSE],")")+"\\s+-\\s+"+"(".concat(l[c.XRANGEPLAINLOOSE],")")+"\\s*$"),p("STAR","(<|>)?=?\\s*\\*"),p("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),p("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")})(Wh,Wh.exports);var mo=Wh.exports;const NV=Object.freeze({loose:!0}),VV=Object.freeze({}),BV=s=>s?typeof s!="object"?NV:s:VV;var rg=BV;const f1=/^[0-9]+$/,zy=(s,e)=>{const t=f1.test(s),r=f1.test(e);return t&&r&&(s=+s,e=+e),s===e?0:t&&!r?-1:r&&!t?1:s<e?-1:1},UV=(s,e)=>zy(e,s);var Gy={compareIdentifiers:zy,rcompareIdentifiers:UV};const Oo=id,{MAX_LENGTH:g1,MAX_SAFE_INTEGER:Mo}=rd,{safeRe:_1,safeSrc:v1,t:ko}=mo,WV=rg,{compareIdentifiers:di}=Gy;let zV=class Cs{constructor(e,t){if(t=WV(t),e instanceof Cs){if(e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease)return e;e=e.version}else if(typeof e!="string")throw new TypeError('Invalid version. Must be a string. Got type "'.concat(typeof e,'".'));if(e.length>g1)throw new TypeError("version is longer than ".concat(g1," characters"));Oo("SemVer",e,t),this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease;const r=e.trim().match(t.loose?_1[ko.LOOSE]:_1[ko.FULL]);if(!r)throw new TypeError("Invalid Version: ".concat(e));if(this.raw=e,this.major=+r[1],this.minor=+r[2],this.patch=+r[3],this.major>Mo||this.major<0)throw new TypeError("Invalid major version");if(this.minor>Mo||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>Mo||this.patch<0)throw new TypeError("Invalid patch version");r[4]?this.prerelease=r[4].split(".").map(i=>{if(/^[0-9]+$/.test(i)){const n=+i;if(n>=0&&n<Mo)return n}return i}):this.prerelease=[],this.build=r[5]?r[5].split("."):[],this.format()}format(){return this.version="".concat(this.major,".").concat(this.minor,".").concat(this.patch),this.prerelease.length&&(this.version+="-".concat(this.prerelease.join("."))),this.version}toString(){return this.version}compare(e){if(Oo("SemVer.compare",this.version,this.options,e),!(e instanceof Cs)){if(typeof e=="string"&&e===this.version)return 0;e=new Cs(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof Cs||(e=new Cs(e,this.options)),di(this.major,e.major)||di(this.minor,e.minor)||di(this.patch,e.patch)}comparePre(e){if(e instanceof Cs||(e=new Cs(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let t=0;do{const r=this.prerelease[t],i=e.prerelease[t];if(Oo("prerelease compare",t,r,i),r===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(r===void 0)return-1;if(r===i)continue;return di(r,i)}while(++t)}compareBuild(e){e instanceof Cs||(e=new Cs(e,this.options));let t=0;do{const r=this.build[t],i=e.build[t];if(Oo("build compare",t,r,i),r===void 0&&i===void 0)return 0;if(i===void 0)return 1;if(r===void 0)return-1;if(r===i)continue;return di(r,i)}while(++t)}inc(e,t,r){if(e.startsWith("pre")){if(!t&&r===!1)throw new Error("invalid increment argument: identifier is empty");if(t){const i=new RegExp("^".concat(this.options.loose?v1[ko.PRERELEASELOOSE]:v1[ko.PRERELEASE],"$")),n="-".concat(t).match(i);if(!n||n[1]!==t)throw new Error("invalid identifier: ".concat(t))}}switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t,r);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t,r);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t,r),this.inc("pre",t,r);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",t,r),this.inc("pre",t,r);break;case"release":if(this.prerelease.length===0)throw new Error("version ".concat(this.raw," is not a prerelease"));this.prerelease.length=0;break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":{const i=Number(r)?1:0;if(this.prerelease.length===0)this.prerelease=[i];else{let n=this.prerelease.length;for(;--n>=0;)typeof this.prerelease[n]=="number"&&(this.prerelease[n]++,n=-2);if(n===-1){if(t===this.prerelease.join(".")&&r===!1)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(i)}}if(t){let n=[t,i];r===!1&&(n=[t]),di(this.prerelease[0],t)===0?isNaN(this.prerelease[1])&&(this.prerelease=n):this.prerelease=n}break}default:throw new Error("invalid increment argument: ".concat(e))}return this.raw=this.format(),this.build.length&&(this.raw+="+".concat(this.build.join("."))),this}};var St=zV;const b1=St,GV=(s,e,t=!1)=>{if(s instanceof b1)return s;try{return new b1(s,e)}catch(r){if(!t)return null;throw r}};var fn=GV;const ZV=fn,qV=(s,e)=>{const t=ZV(s,e);return t?t.version:null};var XV=qV;const YV=fn,JV=(s,e)=>{const t=YV(s.trim().replace(/^[=v]+/,""),e);return t?t.version:null};var KV=JV;const y1=St,QV=(s,e,t,r,i)=>{typeof t=="string"&&(i=r,r=t,t=void 0);try{return new y1(s instanceof y1?s.version:s,t).inc(e,r,i).version}catch{return null}};var eB=QV;const C1=fn,tB=(s,e)=>{const t=C1(s,null,!0),r=C1(e,null,!0),i=t.compare(r);if(i===0)return null;const n=i>0,a=n?t:r,o=n?r:t,l=!!a.prerelease.length;if(!!o.prerelease.length&&!l){if(!o.patch&&!o.minor)return"major";if(o.compareMain(a)===0)return o.minor&&!o.patch?"minor":"patch"}const c=l?"pre":"";return t.major!==r.major?c+"major":t.minor!==r.minor?c+"minor":t.patch!==r.patch?c+"patch":"prerelease"};var sB=tB;const rB=St,iB=(s,e)=>new rB(s,e).major;var nB=iB;const aB=St,oB=(s,e)=>new aB(s,e).minor;var lB=oB;const cB=St,uB=(s,e)=>new cB(s,e).patch;var dB=uB;const mB=fn,hB=(s,e)=>{const t=mB(s,e);return t&&t.prerelease.length?t.prerelease:null};var pB=hB;const $1=St,fB=(s,e,t)=>new $1(s,t).compare(new $1(e,t));var ps=fB;const gB=ps,_B=(s,e,t)=>gB(e,s,t);var vB=_B;const bB=ps,yB=(s,e)=>bB(s,e,!0);var CB=yB;const x1=St,$B=(s,e,t)=>{const r=new x1(s,t),i=new x1(e,t);return r.compare(i)||r.compareBuild(i)};var ig=$B;const xB=ig,wB=(s,e)=>s.sort((t,r)=>xB(t,r,e));var SB=wB;const PB=ig,DB=(s,e)=>s.sort((t,r)=>PB(r,t,e));var TB=DB;const OB=ps,MB=(s,e,t)=>OB(s,e,t)>0;var nd=MB;const kB=ps,EB=(s,e,t)=>kB(s,e,t)<0;var ng=EB;const LB=ps,AB=(s,e,t)=>LB(s,e,t)===0;var Zy=AB;const FB=ps,RB=(s,e,t)=>FB(s,e,t)!==0;var qy=RB;const HB=ps,jB=(s,e,t)=>HB(s,e,t)>=0;var ag=jB;const IB=ps,NB=(s,e,t)=>IB(s,e,t)<=0;var og=NB;const VB=Zy,BB=qy,UB=nd,WB=ag,zB=ng,GB=og,ZB=(s,e,t,r)=>{switch(e){case"===":return typeof s=="object"&&(s=s.version),typeof t=="object"&&(t=t.version),s===t;case"!==":return typeof s=="object"&&(s=s.version),typeof t=="object"&&(t=t.version),s!==t;case"":case"=":case"==":return VB(s,t,r);case"!=":return BB(s,t,r);case">":return UB(s,t,r);case">=":return WB(s,t,r);case"<":return zB(s,t,r);case"<=":return GB(s,t,r);default:throw new TypeError("Invalid operator: ".concat(e))}};var Xy=ZB;const qB=St,XB=fn,{safeRe:Eo,t:Lo}=mo,YB=(s,e)=>{if(s instanceof qB)return s;if(typeof s=="number"&&(s=String(s)),typeof s!="string")return null;e=e||{};let t=null;if(!e.rtl)t=s.match(e.includePrerelease?Eo[Lo.COERCEFULL]:Eo[Lo.COERCE]);else{const l=e.includePrerelease?Eo[Lo.COERCERTLFULL]:Eo[Lo.COERCERTL];let u;for(;(u=l.exec(s))&&(!t||t.index+t[0].length!==s.length);)(!t||u.index+u[0].length!==t.index+t[0].length)&&(t=u),l.lastIndex=u.index+u[1].length+u[2].length;l.lastIndex=-1}if(t===null)return null;const r=t[2],i=t[3]||"0",n=t[4]||"0",a=e.includePrerelease&&t[5]?"-".concat(t[5]):"",o=e.includePrerelease&&t[6]?"+".concat(t[6]):"";return XB("".concat(r,".").concat(i,".").concat(n).concat(a).concat(o),e)};var JB=YB;class KB{constructor(){this.max=1e3,this.map=new Map}get(e){const t=this.map.get(e);if(t!==void 0)return this.map.delete(e),this.map.set(e,t),t}delete(e){return this.map.delete(e)}set(e,t){if(!this.delete(e)&&t!==void 0){if(this.map.size>=this.max){const i=this.map.keys().next().value;this.delete(i)}this.map.set(e,t)}return this}}var QB=KB,Yd,w1;function fs(){if(w1)return Yd;w1=1;const s=/\s+/g;class e{constructor(z,K){if(K=i(K),z instanceof e)return z.loose===!!K.loose&&z.includePrerelease===!!K.includePrerelease?z:new e(z.raw,K);if(z instanceof n)return this.raw=z.value,this.set=[[z]],this.formatted=void 0,this;if(this.options=K,this.loose=!!K.loose,this.includePrerelease=!!K.includePrerelease,this.raw=z.trim().replace(s," "),this.set=this.raw.split("||").map(Q=>this.parseRange(Q.trim())).filter(Q=>Q.length),!this.set.length)throw new TypeError("Invalid SemVer Range: ".concat(this.raw));if(this.set.length>1){const Q=this.set[0];if(this.set=this.set.filter(re=>!p(re[0])),this.set.length===0)this.set=[Q];else if(this.set.length>1){for(const re of this.set)if(re.length===1&&v(re[0])){this.set=[re];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted="";for(let z=0;z<this.set.length;z++){z>0&&(this.formatted+="||");const K=this.set[z];for(let Q=0;Q<K.length;Q++)Q>0&&(this.formatted+=" "),this.formatted+=K[Q].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(z){const Q=((this.options.includePrerelease&&h)|(this.options.loose&&f))+":"+z,re=r.get(Q);if(re)return re;const R=this.options.loose,B=R?l[u.HYPHENRANGELOOSE]:l[u.HYPHENRANGE];z=z.replace(B,te(this.options.includePrerelease)),a("hyphen replace",z),z=z.replace(l[u.COMPARATORTRIM],c),a("comparator trim",z),z=z.replace(l[u.TILDETRIM],d),a("tilde trim",z),z=z.replace(l[u.CARETTRIM],m),a("caret trim",z);let T=z.split(" ").map(ie=>P(ie,this.options)).join(" ").split(/\s+/).map(ie=>G(ie,this.options));R&&(T=T.filter(ie=>(a("loose invalid filter",ie,this.options),!!ie.match(l[u.COMPARATORLOOSE])))),a("range list",T);const A=new Map,H=T.map(ie=>new n(ie,this.options));for(const ie of H){if(p(ie))return[ie];A.set(ie.value,ie)}A.size>1&&A.has("")&&A.delete("");const ee=[...A.values()];return r.set(Q,ee),ee}intersects(z,K){if(!(z instanceof e))throw new TypeError("a Range is required");return this.set.some(Q=>C(Q,K)&&z.set.some(re=>C(re,K)&&Q.every(R=>re.every(B=>R.intersects(B,K)))))}test(z){if(!z)return!1;if(typeof z=="string")try{z=new o(z,this.options)}catch{return!1}for(let K=0;K<this.set.length;K++)if(X(this.set[K],z,this.options))return!0;return!1}}Yd=e;const t=QB,r=new t,i=rg,n=ad(),a=id,o=St,{safeRe:l,t:u,comparatorTrimReplace:c,tildeTrimReplace:d,caretTrimReplace:m}=mo,{FLAG_INCLUDE_PRERELEASE:h,FLAG_LOOSE:f}=rd,p=q=>q.value==="<0.0.0-0",v=q=>q.value==="",C=(q,z)=>{let K=!0;const Q=q.slice();let re=Q.pop();for(;K&&Q.length;)K=Q.every(R=>re.intersects(R,z)),re=Q.pop();return K},P=(q,z)=>(a("comp",q,z),q=$(q,z),a("caret",q),q=F(q,z),a("tildes",q),q=V(q,z),a("xrange",q),q=W(q,z),a("stars",q),q),M=q=>!q||q.toLowerCase()==="x"||q==="*",F=(q,z)=>q.trim().split(/\s+/).map(K=>O(K,z)).join(" "),O=(q,z)=>{const K=z.loose?l[u.TILDELOOSE]:l[u.TILDE];return q.replace(K,(Q,re,R,B,T)=>{a("tilde",q,Q,re,R,B,T);let A;return M(re)?A="":M(R)?A=">=".concat(re,".0.0 <").concat(+re+1,".0.0-0"):M(B)?A=">=".concat(re,".").concat(R,".0 <").concat(re,".").concat(+R+1,".0-0"):T?(a("replaceTilde pr",T),A=">=".concat(re,".").concat(R,".").concat(B,"-").concat(T," <").concat(re,".").concat(+R+1,".0-0")):A=">=".concat(re,".").concat(R,".").concat(B," <").concat(re,".").concat(+R+1,".0-0"),a("tilde return",A),A})},$=(q,z)=>q.trim().split(/\s+/).map(K=>D(K,z)).join(" "),D=(q,z)=>{a("caret",q,z);const K=z.loose?l[u.CARETLOOSE]:l[u.CARET],Q=z.includePrerelease?"-0":"";return q.replace(K,(re,R,B,T,A)=>{a("caret",q,re,R,B,T,A);let H;return M(R)?H="":M(B)?H=">=".concat(R,".0.0").concat(Q," <").concat(+R+1,".0.0-0"):M(T)?R==="0"?H=">=".concat(R,".").concat(B,".0").concat(Q," <").concat(R,".").concat(+B+1,".0-0"):H=">=".concat(R,".").concat(B,".0").concat(Q," <").concat(+R+1,".0.0-0"):A?(a("replaceCaret pr",A),R==="0"?B==="0"?H=">=".concat(R,".").concat(B,".").concat(T,"-").concat(A," <").concat(R,".").concat(B,".").concat(+T+1,"-0"):H=">=".concat(R,".").concat(B,".").concat(T,"-").concat(A," <").concat(R,".").concat(+B+1,".0-0"):H=">=".concat(R,".").concat(B,".").concat(T,"-").concat(A," <").concat(+R+1,".0.0-0")):(a("no pr"),R==="0"?B==="0"?H=">=".concat(R,".").concat(B,".").concat(T).concat(Q," <").concat(R,".").concat(B,".").concat(+T+1,"-0"):H=">=".concat(R,".").concat(B,".").concat(T).concat(Q," <").concat(R,".").concat(+B+1,".0-0"):H=">=".concat(R,".").concat(B,".").concat(T," <").concat(+R+1,".0.0-0")),a("caret return",H),H})},V=(q,z)=>(a("replaceXRanges",q,z),q.split(/\s+/).map(K=>N(K,z)).join(" ")),N=(q,z)=>{q=q.trim();const K=z.loose?l[u.XRANGELOOSE]:l[u.XRANGE];return q.replace(K,(Q,re,R,B,T,A)=>{a("xRange",q,Q,re,R,B,T,A);const H=M(R),ee=H||M(B),ie=ee||M(T),ue=ie;return re==="="&&ue&&(re=""),A=z.includePrerelease?"-0":"",H?re===">"||re==="<"?Q="<0.0.0-0":Q="*":re&&ue?(ee&&(B=0),T=0,re===">"?(re=">=",ee?(R=+R+1,B=0,T=0):(B=+B+1,T=0)):re==="<="&&(re="<",ee?R=+R+1:B=+B+1),re==="<"&&(A="-0"),Q="".concat(re+R,".").concat(B,".").concat(T).concat(A)):ee?Q=">=".concat(R,".0.0").concat(A," <").concat(+R+1,".0.0-0"):ie&&(Q=">=".concat(R,".").concat(B,".0").concat(A," <").concat(R,".").concat(+B+1,".0-0")),a("xRange return",Q),Q})},W=(q,z)=>(a("replaceStars",q,z),q.trim().replace(l[u.STAR],"")),G=(q,z)=>(a("replaceGTE0",q,z),q.trim().replace(l[z.includePrerelease?u.GTE0PRE:u.GTE0],"")),te=q=>(z,K,Q,re,R,B,T,A,H,ee,ie,ue)=>(M(Q)?K="":M(re)?K=">=".concat(Q,".0.0").concat(q?"-0":""):M(R)?K=">=".concat(Q,".").concat(re,".0").concat(q?"-0":""):B?K=">=".concat(K):K=">=".concat(K).concat(q?"-0":""),M(H)?A="":M(ee)?A="<".concat(+H+1,".0.0-0"):M(ie)?A="<".concat(H,".").concat(+ee+1,".0-0"):ue?A="<=".concat(H,".").concat(ee,".").concat(ie,"-").concat(ue):q?A="<".concat(H,".").concat(ee,".").concat(+ie+1,"-0"):A="<=".concat(A),"".concat(K," ").concat(A).trim()),X=(q,z,K)=>{for(let Q=0;Q<q.length;Q++)if(!q[Q].test(z))return!1;if(z.prerelease.length&&!K.includePrerelease){for(let Q=0;Q<q.length;Q++)if(a(q[Q].semver),q[Q].semver!==n.ANY&&q[Q].semver.prerelease.length>0){const re=q[Q].semver;if(re.major===z.major&&re.minor===z.minor&&re.patch===z.patch)return!0}return!1}return!0};return Yd}var Jd,S1;function ad(){if(S1)return Jd;S1=1;const s=Symbol("SemVer ANY");class e{static get ANY(){return s}constructor(c,d){if(d=t(d),c instanceof e){if(c.loose===!!d.loose)return c;c=c.value}c=c.trim().split(/\s+/).join(" "),a("comparator",c,d),this.options=d,this.loose=!!d.loose,this.parse(c),this.semver===s?this.value="":this.value=this.operator+this.semver.version,a("comp",this)}parse(c){const d=this.options.loose?r[i.COMPARATORLOOSE]:r[i.COMPARATOR],m=c.match(d);if(!m)throw new TypeError("Invalid comparator: ".concat(c));this.operator=m[1]!==void 0?m[1]:"",this.operator==="="&&(this.operator=""),m[2]?this.semver=new o(m[2],this.options.loose):this.semver=s}toString(){return this.value}test(c){if(a("Comparator.test",c,this.options.loose),this.semver===s||c===s)return!0;if(typeof c=="string")try{c=new o(c,this.options)}catch{return!1}return n(c,this.operator,this.semver,this.options)}intersects(c,d){if(!(c instanceof e))throw new TypeError("a Comparator is required");return this.operator===""?this.value===""?!0:new l(c.value,d).test(this.value):c.operator===""?c.value===""?!0:new l(this.value,d).test(c.semver):(d=t(d),d.includePrerelease&&(this.value==="<0.0.0-0"||c.value==="<0.0.0-0")||!d.includePrerelease&&(this.value.startsWith("<0.0.0")||c.value.startsWith("<0.0.0"))?!1:!!(this.operator.startsWith(">")&&c.operator.startsWith(">")||this.operator.startsWith("<")&&c.operator.startsWith("<")||this.semver.version===c.semver.version&&this.operator.includes("=")&&c.operator.includes("=")||n(this.semver,"<",c.semver,d)&&this.operator.startsWith(">")&&c.operator.startsWith("<")||n(this.semver,">",c.semver,d)&&this.operator.startsWith("<")&&c.operator.startsWith(">")))}}Jd=e;const t=rg,{safeRe:r,t:i}=mo,n=Xy,a=id,o=St,l=fs();return Jd}const eU=fs(),tU=(s,e,t)=>{try{e=new eU(e,t)}catch{return!1}return e.test(s)};var od=tU;const sU=fs(),rU=(s,e)=>new sU(s,e).set.map(t=>t.map(r=>r.value).join(" ").trim().split(" "));var iU=rU;const nU=St,aU=fs(),oU=(s,e,t)=>{let r=null,i=null,n=null;try{n=new aU(e,t)}catch{return null}return s.forEach(a=>{n.test(a)&&(!r||i.compare(a)===-1)&&(r=a,i=new nU(r,t))}),r};var lU=oU;const cU=St,uU=fs(),dU=(s,e,t)=>{let r=null,i=null,n=null;try{n=new uU(e,t)}catch{return null}return s.forEach(a=>{n.test(a)&&(!r||i.compare(a)===1)&&(r=a,i=new cU(r,t))}),r};var mU=dU;const Kd=St,hU=fs(),P1=nd,pU=(s,e)=>{s=new hU(s,e);let t=new Kd("0.0.0");if(s.test(t)||(t=new Kd("0.0.0-0"),s.test(t)))return t;t=null;for(let r=0;r<s.set.length;++r){const i=s.set[r];let n=null;i.forEach(a=>{const o=new Kd(a.semver.version);switch(a.operator){case">":o.prerelease.length===0?o.patch++:o.prerelease.push(0),o.raw=o.format();case"":case">=":(!n||P1(o,n))&&(n=o);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: ".concat(a.operator))}}),n&&(!t||P1(t,n))&&(t=n)}return t&&s.test(t)?t:null};var fU=pU;const gU=fs(),_U=(s,e)=>{try{return new gU(s,e).range||"*"}catch{return null}};var vU=_U;const bU=St,Yy=ad(),{ANY:yU}=Yy,CU=fs(),$U=od,D1=nd,T1=ng,xU=og,wU=ag,SU=(s,e,t,r)=>{s=new bU(s,r),e=new CU(e,r);let i,n,a,o,l;switch(t){case">":i=D1,n=xU,a=T1,o=">",l=">=";break;case"<":i=T1,n=wU,a=D1,o="<",l="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if($U(s,e,r))return!1;for(let u=0;u<e.set.length;++u){const c=e.set[u];let d=null,m=null;if(c.forEach(h=>{h.semver===yU&&(h=new Yy(">=0.0.0")),d=d||h,m=m||h,i(h.semver,d.semver,r)?d=h:a(h.semver,m.semver,r)&&(m=h)}),d.operator===o||d.operator===l||(!m.operator||m.operator===o)&&n(s,m.semver))return!1;if(m.operator===l&&a(s,m.semver))return!1}return!0};var lg=SU;const PU=lg,DU=(s,e,t)=>PU(s,e,">",t);var TU=DU;const OU=lg,MU=(s,e,t)=>OU(s,e,"<",t);var kU=MU;const O1=fs(),EU=(s,e,t)=>(s=new O1(s,t),e=new O1(e,t),s.intersects(e,t));var LU=EU;const AU=od,FU=ps;var RU=(s,e,t)=>{const r=[];let i=null,n=null;const a=s.sort((c,d)=>FU(c,d,t));for(const c of a)AU(c,e,t)?(n=c,i||(i=c)):(n&&r.push([i,n]),n=null,i=null);i&&r.push([i,null]);const o=[];for(const[c,d]of r)c===d?o.push(c):!d&&c===a[0]?o.push("*"):d?c===a[0]?o.push("<=".concat(d)):o.push("".concat(c," - ").concat(d)):o.push(">=".concat(c));const l=o.join(" || "),u=typeof e.raw=="string"?e.raw:String(e);return l.length<u.length?l:e};const M1=fs(),cg=ad(),{ANY:Qd}=cg,Pn=od,ug=ps,HU=(s,e,t={})=>{if(s===e)return!0;s=new M1(s,t),e=new M1(e,t);let r=!1;e:for(const i of s.set){for(const n of e.set){const a=IU(i,n,t);if(r=r||a!==null,a)continue e}if(r)return!1}return!0},jU=[new cg(">=0.0.0-0")],k1=[new cg(">=0.0.0")],IU=(s,e,t)=>{if(s===e)return!0;if(s.length===1&&s[0].semver===Qd){if(e.length===1&&e[0].semver===Qd)return!0;t.includePrerelease?s=jU:s=k1}if(e.length===1&&e[0].semver===Qd){if(t.includePrerelease)return!0;e=k1}const r=new Set;let i,n;for(const h of s)h.operator===">"||h.operator===">="?i=E1(i,h,t):h.operator==="<"||h.operator==="<="?n=L1(n,h,t):r.add(h.semver);if(r.size>1)return null;let a;if(i&&n){if(a=ug(i.semver,n.semver,t),a>0)return null;if(a===0&&(i.operator!==">="||n.operator!=="<="))return null}for(const h of r){if(i&&!Pn(h,String(i),t)||n&&!Pn(h,String(n),t))return null;for(const f of e)if(!Pn(h,String(f),t))return!1;return!0}let o,l,u,c,d=n&&!t.includePrerelease&&n.semver.prerelease.length?n.semver:!1,m=i&&!t.includePrerelease&&i.semver.prerelease.length?i.semver:!1;d&&d.prerelease.length===1&&n.operator==="<"&&d.prerelease[0]===0&&(d=!1);for(const h of e){if(c=c||h.operator===">"||h.operator===">=",u=u||h.operator==="<"||h.operator==="<=",i){if(m&&h.semver.prerelease&&h.semver.prerelease.length&&h.semver.major===m.major&&h.semver.minor===m.minor&&h.semver.patch===m.patch&&(m=!1),h.operator===">"||h.operator===">="){if(o=E1(i,h,t),o===h&&o!==i)return!1}else if(i.operator===">="&&!Pn(i.semver,String(h),t))return!1}if(n){if(d&&h.semver.prerelease&&h.semver.prerelease.length&&h.semver.major===d.major&&h.semver.minor===d.minor&&h.semver.patch===d.patch&&(d=!1),h.operator==="<"||h.operator==="<="){if(l=L1(n,h,t),l===h&&l!==n)return!1}else if(n.operator==="<="&&!Pn(n.semver,String(h),t))return!1}if(!h.operator&&(n||i)&&a!==0)return!1}return!(i&&u&&!n&&a!==0||n&&c&&!i&&a!==0||m||d)},E1=(s,e,t)=>{if(!s)return e;const r=ug(s.semver,e.semver,t);return r>0?s:r<0||e.operator===">"&&s.operator===">="?e:s},L1=(s,e,t)=>{if(!s)return e;const r=ug(s.semver,e.semver,t);return r<0?s:r>0||e.operator==="<"&&s.operator==="<="?e:s};var NU=HU;const em=mo,A1=rd,VU=St,F1=Gy,BU=fn,UU=XV,WU=KV,zU=eB,GU=sB,ZU=nB,qU=lB,XU=dB,YU=pB,JU=ps,KU=vB,QU=CB,eW=ig,tW=SB,sW=TB,rW=nd,iW=ng,nW=Zy,aW=qy,oW=ag,lW=og,cW=Xy,uW=JB,dW=ad(),mW=fs(),hW=od,pW=iU,fW=lU,gW=mU,_W=fU,vW=vU,bW=lg,yW=TU,CW=kU,$W=LU,xW=RU,wW=NU;var SW={parse:BU,valid:UU,clean:WU,inc:zU,diff:GU,major:ZU,minor:qU,patch:XU,prerelease:YU,compare:JU,rcompare:KU,compareLoose:QU,compareBuild:eW,sort:tW,rsort:sW,gt:rW,lt:iW,eq:nW,neq:aW,gte:oW,lte:lW,cmp:cW,coerce:uW,Comparator:dW,Range:mW,satisfies:hW,toComparators:pW,maxSatisfying:fW,minSatisfying:gW,minVersion:_W,validRange:vW,outside:bW,gtr:yW,ltr:CW,intersects:$W,simplifyRange:xW,subset:wW,SemVer:VU,re:em.re,src:em.src,tokens:em.t,SEMVER_SPEC_VERSION:A1.SEMVER_SPEC_VERSION,RELEASE_TYPES:A1.RELEASE_TYPES,compareIdentifiers:F1.compareIdentifiers,rcompareIdentifiers:F1.rcompareIdentifiers};const nt=en(SW);var PW=Object.defineProperty,DW=Object.getOwnPropertyDescriptor,Jy=(s,e,t,r)=>{for(var i=r>1?void 0:r?DW(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&PW(e,t,i),i};let Ec=class extends k(L){constructor(){super(...arguments),this.mdiInformation=Ht,this.mdiMenuDown=gr,this.mdiReload=vS,this.mdiCloseCircle=ol,this.mdiUpdate=Xa,this.mdiInformationOutline=ov,this.boolShowCommitList=!1,this.boolShowUpdateHint=!1,this.toggleAnomalies=!1}get name(){var r,i;const t=((r=this.repo.info_tags)!=null?r:[]).find(n=>n.startsWith("desc="));return t&&t.trim()!=="desc="?t.replace("desc=","").trim():(i=this.repo.name)!=null?i:"UNKNOWN"}get type(){return this.repo.configured_type}get localVersion(){var t;const e=(t=this.repo.version)!=null?t:"?";return nt.valid(e,{loose:!0})?e:null}get remoteVersion(){var t;const e=(t=this.repo.remote_version)!=null?t:"?";return nt.valid(e,{loose:!0})?e:null}get branch(){var e;return(e=this.repo.branch)!=null?e:"master"}get remoteAlias(){var e;return(e=this.repo.remote_alias)!=null?e:"origin"}get branchOutput(){return this.remoteAlias!=="origin"?"".concat(this.remoteAlias,"/").concat(this.branch):["master","main"].includes(this.branch)?null:this.branch}get commitsBehind(){var e;return(e=this.repo.commits_behind)!=null?e:[]}get fullVersionString(){var e;return(e=this.repo.full_version_string)!=null?e:null}get versionOutput(){let e=this.branchOutput?"".concat(this.branchOutput,": "):"";if(this.semverUpdatable)return"".concat(e).concat(this.localVersion," > ").concat(this.remoteVersion);if(this.commitsBehind.length){const t=this.$tc("Machine.UpdatePanel.CommitsAvailable",this.commitsBehind.length,{count:this.commitsBehind.length}).toString();return this.localVersion?"".concat(e).concat(this.localVersion," > ").concat(t):"".concat(e).concat(t)}return this.fullVersionString?this.fullVersionString:this.localVersion?this.localVersion:"UNKNOWN"}get configuredType(){var e;return(e=this.repo.configured_type)!=null?e:"git_repo"}get isValid(){var e;return(e=this.repo.is_valid)!=null?e:!0}get isDirty(){var e;return(e=this.repo.is_dirty)!=null?e:!1}get isCorrupt(){var e;return this.configuredType!=="git_repo"?!1:(e=this.repo.corrupt)!=null?e:!1}get debugEnabled(){var e;return(e=this.repo.debug_enabled)!=null?e:!1}get isDetached(){var e;return this.configuredType!=="git_repo"?!1:!this.debugEnabled&&((e=this.repo.detached)!=null?e:!1)}get existsRecoveryUrl(){var t;return((t=this.repo.recovery_url)!=null?t:"?")!=="?"}get btnDisabled(){return["printing","paused"].includes(this.printer_state)?!0:!this.isValid||this.isCorrupt||this.isDirty||this.commitsBehind.length?!1:["python","web"].includes(this.type)?!this.semverUpdatable:this.commitsBehind.length===0}get btnIcon(){if(this.isDetached||!this.isValid||this.isCorrupt||this.isDirty)return ol;if(["python","web"].includes(this.type)){if(this.semverUpdatable)return ll;if(this.localVersion===null||this.remoteVersion===null)return iv}return this.type==="git_repo"&&this.commitsBehind.length?ll:q_}get btnColor(){return this.isCorrupt||this.isDetached||this.isDirty||!this.isValid?"orange":["python","web"].includes(this.type)&&this.semverUpdatable||this.type==="git_repo"&&this.commitsBehind.length?"primary":"green"}get btnText(){if(this.isCorrupt)return this.$t("Machine.UpdatePanel.Corrupt");if(this.isDetached)return this.$t("Machine.UpdatePanel.Detached");if(this.isDirty)return this.$t("Machine.UpdatePanel.Dirty");if(!this.isValid)return this.$t("Machine.UpdatePanel.Invalid");if(["python","web"].includes(this.type)){if(this.semverUpdatable)return this.$t("Machine.UpdatePanel.Update");if(this.localVersion===null||this.remoteVersion===null)return this.$t("Machine.UpdatePanel.Unknown")}return this.type==="git_repo"&&this.commitsBehind.length?this.$t("Machine.UpdatePanel.Update"):this.$t("Machine.UpdatePanel.UpToDate")}get anomalies(){var e;return(e=this.repo.anomalies)!=null?e:[]}get warnings(){var e;return(e=this.repo.warnings)!=null?e:[]}get semverUpdatable(){return!this.localVersion||!this.remoteVersion?!1:nt.gt(this.remoteVersion,this.localVersion,{loose:!0})}get repo_name(){var e,t;return(t=(e=this.repo.repo_name)!=null?e:this.repo.name)!=null?t:""}get githubRepoUrl(){return"https://github.com/".concat(this.repo.owner,"/").concat(this.repo_name)}get webLinkRelease(){return"".concat(this.githubRepoUrl,"/releases/tag/").concat(this.repo.remote_version)}get pythonChangelog(){return this.repo.channel==="dev"?"".concat(this.githubRepoUrl,"/compare/").concat(this.repo.current_hash,"..").concat(this.repo.remote_hash):this.repo.changelog_url?this.repo.changelog_url:this.webLinkRelease}get hideUpdateWarning(){var e;return(e=this.$store.state.gui.uiSettings.hideUpdateWarnings)!=null?e:!1}clickUpdate(){if(this.hideUpdateWarning){this.doUpdate();return}this.boolShowUpdateHint=!0}doUpdate(){if(["klipper","moonraker"].includes(this.repo.name)){this.$socket.emit("machine.update."+this.repo.name,{});return}this.$socket.emit("machine.update.client",{name:this.repo.name})}doRecovery(e){this.$socket.emit("machine.update.recover",{name:this.repo.name,hard:e})}closeCommitList(){this.boolShowCommitList=!1}closeShowUpdateHint(){this.boolShowUpdateHint=!1}};Jy([w({required:!0})],Ec.prototype,"repo",2);Ec=Jy([S({components:{GitCommitsList:sg,UpdateHint:Uy}})],Ec);var TW=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(x,{staticClass:"py-2"},[t(b,{staticClass:"pl-6"},[t("strong",[e._v(e._s(e.name))]),t("br"),e.type==="git_repo"&&e.commitsBehind.length?[t("a",{staticClass:"info--text cursor--pointer",on:{click:function(r){e.boolShowCommitList=!0}}},[t(_,{staticClass:"mr-1",attrs:{small:"",color:"info"}},[e._v(e._s(e.mdiUpdate))]),e._v(" "+e._s(e.versionOutput)+" ")],1)]:e.type==="web"&&e.semverUpdatable?[t("a",{staticClass:"info--text text-decoration-none",attrs:{href:e.webLinkRelease,target:"_blank"}},[t(_,{staticClass:"mr-1",attrs:{small:"",color:"info"}},[e._v(e._s(e.mdiUpdate))]),e._v(" "+e._s(e.versionOutput)+" ")],1)]:e.type==="python"&&e.semverUpdatable?[t("a",{staticClass:"info--text text-decoration-none",attrs:{href:e.pythonChangelog,target:"_blank"}},[t(_,{staticClass:"mr-1",attrs:{small:"",color:"info"}},[e._v(e._s(e.mdiUpdate))]),e._v(" "+e._s(e.versionOutput)+" ")],1)]:t("span",[e._v(e._s(e.versionOutput))])],2),t(b,{staticClass:"col-auto pr-6 text-right",attrs:{"align-self":"center"}},[e.anomalies.length>0?t($s,{staticClass:"minwidth-0 px-1 mr-2",attrs:{small:"",label:"",outlined:!e.toggleAnomalies,color:"grey"},on:{click:function(r){e.toggleAnomalies=!e.toggleAnomalies}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.toggleAnomalies?e.mdiInformationOutline:e.mdiInformation))])],1):e._e(),e.isValid?t($s,{staticClass:"minwidth-0 px-2 text-uppercase",attrs:{small:"",label:"",outlined:"",color:e.btnColor,disabled:e.btnDisabled},on:{click:e.clickUpdate}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.btnIcon))]),e._v(" "+e._s(e.btnText)+" ")],1):[t(ye,{attrs:{"offset-y":!0},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t($s,e._g(e._b({staticClass:"minwidth-0 px-2 text-uppercase",attrs:{small:"",label:"",outlined:"",color:e.btnColor,disabled:e.btnDisabled}},"v-chip",i,!1),r),[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.btnIcon))]),e._v(" "+e._s(e.btnText)+" "),t(_,{attrs:{small:""}},[e._v(e._s(e.mdiMenuDown))])],1)]}}],null,!1,56479232)},[t(Me,{staticClass:"py-0",attrs:{dense:""}},[e.isCorrupt?e._e():t(J,{on:{click:function(r){return e.doRecovery(!1)}}},[t(Hs,{staticClass:"mr-0 pt-1"},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiReload))])],1),t(_t,[t(Ze,[e._v(e._s(e.$t("Machine.UpdatePanel.SoftRecovery")))])],1)],1),t(J,{attrs:{disabled:!e.existsRecoveryUrl},on:{click:function(r){return e.doRecovery(!0)}}},[t(Hs,{staticClass:"mr-0 pt-1"},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiReload))])],1),t(_t,[t(Ze,[e._v(e._s(e.$t("Machine.UpdatePanel.HardRecovery")))])],1)],1)],1)],1)]],2)],1),e.warnings.length?t(x,{staticClass:"mt-0"},[t(b,{staticClass:"px-6 pt-0"},e._l(e.warnings,function(r,i){return t(it,{key:"warnings_"+i,attrs:{dense:"",text:"",color:"orange",border:"left",icon:e.mdiCloseCircle}},[t("p",{staticClass:"text--disabled mb-0"},[e._v(e._s(r))])])}),1)],1):e._e(),t(x,{directives:[{name:"show",rawName:"v-show",value:e.toggleAnomalies,expression:"toggleAnomalies"}],staticClass:"mt-0"},[t(b,{staticClass:"px-6 pt-0"},e._l(e.anomalies,function(r,i){return t(it,{key:"anomalies_"+i,attrs:{dense:"",text:"",color:"grey",border:"left",icon:e.mdiInformation}},[e._v(" "+e._s(r)+" ")])}),1)],1),e.type==="git_repo"?t(sg,{attrs:{"bool-show-dialog":e.boolShowCommitList,repo:e.repo},on:{"close-dialog":e.closeCommitList}}):e._e(),t(Uy,{attrs:{"bool-show-dialog":e.boolShowUpdateHint,repo:e.repo},on:{"open-commit-history":function(r){e.boolShowCommitList=!0},"do-update":e.doUpdate,"close-dialog":e.closeShowUpdateHint}})],1)},OW=[],MW=E(Ec,TW,OW,!1,null,"d5c4f3f3");const kW=MW.exports;var EW=Object.defineProperty,LW=Object.getOwnPropertyDescriptor,dg=(s,e,t,r)=>{for(var i=r>1?void 0:r?LW(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&EW(e,t,i),i};let Ha=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiPackageVariantClosed=uS}closeDialog(){this.$emit("close-dialog")}};dg([w({required:!0})],Ha.prototype,"boolShowDialog",2);dg([w({required:!0})],Ha.prototype,"packagesList",2);Ha=dg([S({components:{Panel:U}})],Ha);var AW=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{persistent:"","max-width":"800"},model:{value:e.boolShowDialog,callback:function(r){e.boolShowDialog=r},expression:"boolShowDialog"}},[t(U,{attrs:{title:e.$t("Machine.UpdatePanel.UpgradeableSystemPackages"),icon:e.mdiPackageVariantClosed,"margin-bottom":!1,"card-class":"machine-update-system-packages-list-dialog"},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(x,[t(b,[t("p",[e._v(e._s(e.$t("Machine.UpdatePanel.ThesePackagesCanBeUpgrade")))]),t("p",{staticClass:"system-packages-list"},[e._v(e._s(e.packagesList.join(", ")))])])],1)],1),t(oe,[t(ae),t(g,{attrs:{text:"",color:"primary"},on:{click:e.closeDialog}},[e._v(e._s(e.$t("Machine.UpdatePanel.Close")))])],1)],1)],1)},FW=[],RW=E(Ha,AW,FW,!1,null,"3976e09a");const HW=RW.exports;var jW=Object.getOwnPropertyDescriptor,IW=(s,e,t,r)=>{for(var i=r>1?void 0:r?jW(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let zh=class extends k(L){constructor(){super(...arguments),this.mdiInformation=Ht,this.boolShowPackageList=!1}get package_count(){var e,t,r;return(r=(t=(e=this.$store.state.server.updateManager)==null?void 0:e.system)==null?void 0:t.package_count)!=null?r:0}get package_list(){var e,t,r;return(r=(t=(e=this.$store.state.server.updateManager)==null?void 0:e.system)==null?void 0:t.package_list)!=null?r:[]}get btnDisabled(){return["printing","paused"].includes(this.printer_state)?!0:this.package_count===0}get btnIcon(){return this.package_count?ll:q_}get btnColor(){return this.package_count?"primary":"green"}get btnText(){return this.package_count?this.$t("Machine.UpdatePanel.Upgrade"):this.$t("Machine.UpdatePanel.UpToDate")}doUpdate(){this.$socket.emit("machine.update.system",{})}closePackagesList(){this.boolShowPackageList=!1}};zh=IW([S],zh);var NW=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(x,{staticClass:"py-2"},[t(b,{staticClass:"pl-6"},[t("strong",[e._v(e._s(e.$t("Machine.UpdatePanel.System")))]),t("br"),e.package_count?[t("a",{staticClass:"info--text cursor--pointer",on:{click:function(r){e.boolShowPackageList=!0}}},[t(_,{staticClass:"mr-1",attrs:{small:"",color:"info"}},[e._v(e._s(e.mdiInformation))]),e._v(" "+e._s(e.$t("Machine.UpdatePanel.CountPackagesCanBeUpgraded",{count:e.package_count}))+" ")],1)]:t("span",[e._v(e._s(e.$t("Machine.UpdatePanel.OSPackages")))])],2),t(b,{staticClass:"col-auto pr-6 text-right",attrs:{"align-self":"center"}},[t($s,{staticClass:"minwidth-0 px-2 text-uppercase",attrs:{small:"",label:"",outlined:"",color:e.btnColor,disabled:e.btnDisabled},on:{click:e.doUpdate}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.btnIcon))]),e._v(" "+e._s(e.btnText)+" ")],1)],1)],1),t(HW,{attrs:{"bool-show-dialog":e.boolShowPackageList,"packages-list":e.package_list},on:{"close-dialog":e.closePackagesList}})],1)},VW=[],BW=E(zh,NW,VW,!1,null,"22cffe3a");const UW=BW.exports;var WW=Object.defineProperty,zW=Object.getOwnPropertyDescriptor,Ky=(s,e,t,r)=>{for(var i=r>1?void 0:r?zW(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&WW(e,t,i),i};let Lc=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiProgressQuestion=bv,this.checkboxUpdateQuestion=!1,this.boolShowCommitHistory=!1,this.showCommitsRepo=null}get modules(){var s;return(s=this.$store.getters["server/updateManager/getUpdateManagerList"])!=null?s:[]}get filteredModules(){return this.modules.filter(s=>{var e,t,r,i,n,a;return!!(s.type==="git"&&((t=(e=s.data)==null?void 0:e.commits_behind)!=null&&t.length)||s.type==="web"&&nt.valid((r=s.data)==null?void 0:r.remote_version,{loose:!0})&&nt.valid((i=s.data)==null?void 0:i.version,{loose:!0})&&nt.gt((n=s.data)==null?void 0:n.remote_version,(a=s.data)==null?void 0:a.version,{loose:!0}))})}openCommitHistory(s){this.showCommitsRepo=s,this.boolShowCommitHistory=!0}closeDialog(){this.$emit("close-dialog")}updateAll(){this.$emit("update-all")}};Ky([w({required:!0})],Lc.prototype,"boolShowDialog",2);Lc=Ky([S({components:{GitCommitsListDay:uo,Panel:U,UpdateHintAlert:sd}})],Lc);var GW=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(le,{attrs:{persistent:"","max-width":"600"},model:{value:e.boolShowDialog,callback:function(r){e.boolShowDialog=r},expression:"boolShowDialog"}},[t(U,{attrs:{title:e.$t("Machine.UpdatePanel.AreYouSure"),icon:e.mdiProgressQuestion,"margin-bottom":!1,"card-class":"machine-update-hint-dialog"},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:e.closeDialog}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(x,[t(b,[e._l(e.filteredModules,function(r){return t(sd,{key:r.name,attrs:{repo:r.data,"bool-title":!0},on:{"open-commit-history":function(i){return e.openCommitHistory(r.data)}}})}),t("div",[t(ge,{attrs:{label:e.$t("Machine.UpdatePanel.IUnderstandTheRisks"),"hide-details":""},model:{value:e.checkboxUpdateQuestion,callback:function(r){e.checkboxUpdateQuestion=r},expression:"checkboxUpdateQuestion"}})],1)],2)],1)],1),t(I),t(oe,[t(ae),t(g,{attrs:{text:""},on:{click:e.closeDialog}},[e._v(e._s(e.$t("Machine.UpdatePanel.Abort")))]),t(g,{attrs:{text:"",color:"primary",disabled:!e.checkboxUpdateQuestion},on:{click:e.updateAll}},[e._v(" "+e._s(e.$t("Machine.UpdatePanel.StartUpdate"))+" ")])],1)],1),t(sg,{attrs:{"bool-show-dialog":e.boolShowCommitHistory,repo:e.showCommitsRepo},on:{"close-dialog":function(r){e.boolShowCommitHistory=!1}}})],1)},ZW=[],qW=E(Lc,GW,ZW,!1,null,null);const Qy=qW.exports;var XW=Object.getOwnPropertyDescriptor,YW=(s,e,t,r)=>{for(var i=r>1?void 0:r?XW(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Gh=class extends k(L){constructor(){super(...arguments),this.mdiProgressUpload=ll,this.boolShowDialog=!1}get hideUpdateWarning(){var e;return(e=this.$store.state.gui.uiSettings.hideUpdateWarnings)!=null?e:!1}clickUpdate(){if(this.hideUpdateWarning){this.updateAll();return}this.boolShowDialog=!0}updateAll(){this.$socket.emit("machine.update.full",{})}};Gh=YW([S({components:{UpdateHintAll:Qy}})],Gh);var JW=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(x,{staticClass:"pt-3"},[t(b,{staticClass:"text-center"},[t(g,{attrs:{text:"",color:"primary",small:"",disabled:["printing","paused"].includes(e.printer_state)},on:{click:e.clickUpdate}},[t(_,{attrs:{left:""}},[e._v(e._s(e.mdiProgressUpload))]),e._v(" "+e._s(e.$t("Machine.UpdatePanel.UpdateAll"))+" ")],1)],1)],1),t(Qy,{attrs:{"bool-show-dialog":e.boolShowDialog},on:{"close-dialog":function(r){e.boolShowDialog=!1},"update-all":e.updateAll}})],1)},KW=[],QW=E(Gh,JW,KW,!1,null,"8d21c134");const ez=QW.exports;var tz=Object.getOwnPropertyDescriptor,sz=(s,e,t,r)=>{for(var i=r>1?void 0:r?tz(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Zh=class extends k(L){constructor(){super(...arguments),this.mdiRefresh=an,this.mdiInformation=Ht,this.mdiCloseThick=pe,this.mdiUpdate=Xa}get enableUpdateManager(){return this.$store.state.server.components.includes("update_manager")}get modules(){var s;return(s=this.$store.getters["server/updateManager/getUpdateManagerList"])!=null?s:[]}get existsSystemModul(){return"system"in this.$store.state.server.updateManager}get systemPackagesCount(){var s,e,t;return(t=(e=(s=this.$store.state.server.updateManager)==null?void 0:s.system)==null?void 0:e.package_count)!=null?t:0}get checkInitState(){return this.modules.filter(e=>e.data.remote_version!=="?").length>0}get showUpdateAll(){let s=0;return this.modules.forEach(e=>{var t,r,i,n,a,o;if(e.type==="git"&&((r=(t=e.data)==null?void 0:t.commits_behind)!=null&&r.length)){s++;return}if(e.type==="web"&&nt.valid((i=e.data)==null?void 0:i.remote_version,{loose:!0})&&nt.valid((n=e.data)==null?void 0:n.version,{loose:!0})&&nt.gt((a=e.data)==null?void 0:a.remote_version,(o=e.data)==null?void 0:o.version,{loose:!0})){s++;return}}),this.systemPackagesCount>0&&s++,s>1}btnSync(){this.$socket.emit("machine.update.status",{refresh:!0},{action:"server/updateManager/onUpdateStatus",loading:"loadingBtnSyncUpdateManager"})}};Zh=sz([S({components:{Panel:U,UpdatePanelEntry:kW,UpdatePanelEntrySystem:UW,UpdatePanelEntryAll:ez}})],Zh);var rz=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e.enableUpdateManager?t(U,{attrs:{title:e.$t("Machine.UpdatePanel.UpdateManager"),icon:e.mdiUpdate,"card-class":"machine-update-panel",collapsible:!0},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({attrs:{icon:"",tile:"",color:"primary",ripple:!0,loading:e.loadings.includes("loadingBtnSyncUpdateManager"),disabled:["printing","paused"].includes(e.printer_state)},on:{click:e.btnSync}},"v-btn",i,!1),r),[t(_,[e._v(e._s(e.mdiRefresh))])],1)]}}],null,!1,3363156462)},[t("span",[e._v(e._s(e.$t("Machine.UpdatePanel.CheckForUpdates")))])])]},proxy:!0}],null,!1,150962712)},[t(Z,{staticClass:"px-0 py-0 update-manager-list"},[e.checkInitState?[e._l(e.modules,function(r,i){return[i?t(I,{key:"divider_"+r.name,staticClass:"my-0"}):e._e(),t("update-panel-entry",{key:r.name,attrs:{repo:r.data}})]}),e.existsSystemModul?[e.modules.length?t(I,{staticClass:"my-0"}):e._e(),t("update-panel-entry-system")]:e._e(),e.showUpdateAll?[t(I,{staticClass:"mb-0 mt-2 border-top-2"}),t("update-panel-entry-all")]:e._e()]:[t(x,{staticClass:"mt-0 mb-0"},[t(b,{staticClass:"px-6"},[t(it,{staticClass:"mb-0",attrs:{text:"",dense:"",type:"info",border:"left"}},[e._v(" "+e._s(e.$t("Machine.UpdatePanel.InitUpdateManager"))+" ")])],1)],1)]],2)],1):e._e()],1)},iz=[],nz=E(Zh,rz,iz,!1,null,"7d04e052");const e2=nz.exports;var az=Object.getOwnPropertyDescriptor,oz=(s,e,t,r)=>{for(var i=r>1?void 0:r?az(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let qh=class extends k(L){constructor(){super(...arguments),this.formatFilesize=Xe,this.mdiCloseThick=pe,this.mdiTextBoxSearchOutline=Pv,this.hostDetailsDialog=!1}get hostStats(){var s;return(s=this.$store.getters["server/getHostStats"])!=null?s:null}get systemInfo(){var s,e;return(e=(s=this.$store.state.server)==null?void 0:s.system_info)!=null?e:{}}get releaseName(){var e,t,r,i;let s=(t=(e=this.hostStats.release_info)==null?void 0:e.name)!=null?t:"";return s.startsWith("#")?(i=(r=this.hostStats.release_info)==null?void 0:r.id)!=null?i:null:s.startsWith("0.")?null:s}get directory(){return this.$store.getters["files/getDirectory"]("gcodes")}get disk_usage(){var s,e;return(e=(s=this.directory)==null?void 0:s.disk_usage)!=null?e:{used:0,free:0,total:0}}get cpuUsage(){var s;return(s=this.$store.getters["server/getCpuUsage"])!=null?s:null}get cpuUsageColor(){let s="primary";return this.cpuUsage>95?s="error":this.cpuUsage>80&&(s="warning"),s}get networkInterfaces(){var s;return(s=this.$store.getters["server/getNetworkInterfaces"])!=null?s:null}getIpAddress(s){const e=s.find(r=>r.family==="ipv4");if(e)return" (".concat(e.address,")");const t=s.find(r=>r.family==="ipv6");return t?" (".concat(t.address,")"):null}get cpuDesc(){return this.hostStats.cpuDesc}get cpuName(){let s=this.hostStats.cpuName;return this.hostStats.bits&&(s+=", ".concat(this.hostStats.bits)),s}};qh=oz([S({components:{Panel:U}})],qh);var lz=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(x,{staticClass:"py-0 pr-4"},[t(b,{staticClass:"pl-6"},[t("strong",{staticStyle:{cursor:"pointer"},on:{click:function(r){e.hostDetailsDialog=!0}}},[e._v("Host")]),t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[e.hostStats.cpuName?t("small",e._g(e._b({staticClass:"ml-2"},"small",i,!1),r),[e._v("("+e._s(e.cpuName)+")")]):e._e()]}}])},[t("span",[e._v(e._s(e.cpuDesc))])]),t("br"),t("div",{staticClass:"text-body-2"},[e.hostStats.version?t("div",[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Version",{version:e.hostStats.version}))+" ")]):e._e(),e.hostStats.os?t("div",[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Os",{os:e.hostStats.os}))+" ")]):e._e(),e.releaseName?t("div",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Distro",{name:e.releaseName,version_id:e.hostStats.release_info.version_id}))+" "),e.hostStats.release_info.codename?[e._v(" ("+e._s(e.hostStats.release_info.codename)+") ")]:e._e()],2):e._e(),t("div",[t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Load",{load:e.hostStats.load}))+", ")]),e.hostStats.memoryFormat?t("span",{staticClass:"d-inline-block text-no-wrap"},[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Memory",{memory:e.hostStats.memoryFormat}))+" ")]):e._e(),t("span",{staticClass:"text-no-wrap"},[e.hostStats.tempSensor?[e.hostStats.tempSensor.measured_min_temp!==null&&e.hostStats.tempSensor.measured_max_temp!==null?[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("span",e._g(e._b({},"span",i,!1),r),[e._v(" , "+e._s(e.$t("Machine.SystemPanel.Values.Temp",{temp:e.hostStats.tempSensor.temperature}))+" ")])]}}],null,!1,2813579108)},[t("span",[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.TempMax",{temp:e.hostStats.tempSensor.measured_max_temp}))+" "),t("br"),e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.TempMin",{temp:e.hostStats.tempSensor.measured_min_temp}))+" ")])])]:t("span",[e._v(" , "+e._s(e.$t("Machine.SystemPanel.Values.Temp",{temp:e.hostStats.tempSensor.temperature}))+" ")])]:e._e()],2)]),e.networkInterfaces?e._l(e.networkInterfaces,function(r,i){return t("div",{key:i},[t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(i)+" "),"details"in r?[e._v(" "+e._s(e.getIpAddress(r.details.ip_addresses))+" ")]:e._e(),e._v(" : ")],2),t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Bandwidth",{bandwidth:e.formatFilesize(r.bandwidth)}))+" ")]),e._v(" , "),t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Received",{received:e.formatFilesize(r.rx_bytes)}))+" ")]),e._v(" , "),t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Transmitted",{transmitted:e.formatFilesize(r.tx_bytes)}))+" ")])])}):e._e()],2)],1),e.cpuUsage!==null?t(b,{staticClass:"px-2 col-auto d-flex flex-column justify-center align-center"},[t(ot,{attrs:{rotate:-90,size:55,width:7,value:e.cpuUsage,color:e.cpuUsageColor}},[e._v(" "+e._s(e.cpuUsage)+" ")]),t("span",{staticClass:"mt-2"},[e._v(e._s(e.$t("Machine.SystemPanel.Cpu")))])],1):t(b,{staticClass:"px-2 col-auto d-flex flex-column justify-center align-center"},[t(ot,{attrs:{rotate:-90,size:55,width:7,value:e.hostStats.loadPercent,color:e.hostStats.loadProgressColor}},[e._v(" "+e._s(e.hostStats.loadPercent)+" ")]),t("span",{staticClass:"mt-2"},[e._v(e._s(e.$t("Machine.SystemPanel.Load")))])],1),e.hostStats.memUsage!==null?t(b,{staticClass:"px-2 col-auto d-flex flex-column justify-center align-center"},[t(ot,{attrs:{rotate:-90,size:55,width:7,value:e.hostStats.memUsage,color:e.hostStats.memUsageColor}},[e._v(" "+e._s(e.hostStats.memUsage)+" ")]),t("span",{staticClass:"mt-2"},[e._v(e._s(e.$t("Machine.SystemPanel.Memory")))])],1):e._e()],1),t(le,{attrs:{"max-width":600,"max-height":500,scrollable:""},model:{value:e.hostDetailsDialog,callback:function(r){e.hostDetailsDialog=r},expression:"hostDetailsDialog"}},[t(U,{attrs:{title:e.$t("Machine.SystemPanel.HostDetails"),icon:e.mdiTextBoxSearchOutline,"card-class":"machine-systemload-host-details-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.hostDetailsDialog=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{staticClass:"pt-5 px-0"},[t("overlay-scrollbars",{staticClass:"px-6",staticStyle:{height:"350px"}},[Object.keys(e.systemInfo).length?e._l(e.systemInfo,function(r,i,n){return t("div",{key:i},[i!=="available_services"?[t(x,{class:n?"mt-5":""},[t(b,[t("span",{staticClass:"headline"},[e._v(e._s(i))])])],1),e._l(r,function(a,o,l){return t("div",{key:o},[l?t(I,{staticClass:"my-3"}):e._e(),t(x,[t(b,[e._v(e._s(o))]),t(b,{staticClass:"text-right"},[e._v(e._s(a))])],1)],1)})]:e._e()],2)}):[t(x,{staticClass:"mt-5"},[t(b,[t("p",[e._v(e._s(e.$t("Machine.SystemPanel.NoMoreInfos")))])])],1)]],2)],1)],1)],1)],1)},cz=[],uz=E(qh,lz,cz,!1,null,"e5f7e7ba");const t2=uz.exports;var dz=Object.defineProperty,mz=Object.getOwnPropertyDescriptor,s2=(s,e,t,r)=>{for(var i=r>1?void 0:r?mz(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&dz(e,t,i),i};let Ac=class extends k(L){constructor(){super(...arguments),this.formatFilesize=Xe,this.mdiCloseThick=pe,this.mcuDetailsDialog=!1}};s2([w({required:!0})],Ac.prototype,"mcu",2);Ac=s2([S({components:{Panel:U}})],Ac);var hz=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(x,{staticClass:"py-0 pr-4"},[t(b,{staticClass:"pl-6"},[t("strong",{staticStyle:{cursor:"pointer"},on:{click:function(r){e.mcuDetailsDialog=!0}}},[e._v(e._s(e.mcu.name))]),e.mcu.chip?t("small",{staticClass:"ml-2"},[e._v("("+e._s(e.mcu.chip)+")")]):e._e(),t("br"),t("div",{staticClass:"text-body-2"},[t("div",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Version",{version:e.mcu.version}))+" ")]),t("div",[t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Load",{load:e.mcu.load}))+", ")]),t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Awake",{awake:e.mcu.awake}))+", ")]),e.mcu.freq!==null?t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Frequency",{frequency:e.mcu.freqFormat}))+", ")]):e._e(),e.mcu.tempSensor?[e.mcu.tempSensor.measured_min_temp!==null&&e.mcu.tempSensor.measured_max_temp!==null?[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t("span",e._g(e._b({},"span",i,!1),r),[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Temp",{temp:e.mcu.tempSensor.temperature}))+" ")])]}}],null,!1,1093946258)},[t("span",[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.TempMax",{temp:e.mcu.tempSensor.measured_max_temp}))+" "),t("br"),e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.TempMin",{temp:e.mcu.tempSensor.measured_min_temp}))+" ")])])]:t("span",{staticClass:"text-no-wrap"},[e._v(" "+e._s(e.$t("Machine.SystemPanel.Values.Temp",{temp:e.mcu.tempSensor.temperature}))+" ")])]:e._e()],2)])]),t(b,{staticClass:"px-2 col-auto d-flex justify-center align-center"},[t(ot,{attrs:{rotate:-90,size:55,width:7,value:e.mcu.loadPercent,color:e.mcu.loadProgressColor}},[e._v(" "+e._s(e.mcu.loadPercent)+" ")])],1)],1),t(le,{attrs:{"max-width":400,"max-height":500,scrollable:""},model:{value:e.mcuDetailsDialog,callback:function(r){e.mcuDetailsDialog=r},expression:"mcuDetailsDialog"}},[t(U,{attrs:{title:e.mcu.name,icon:"mdi-text-box-search-outline","card-class":"machine-systemload-mcu-details-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.mcuDetailsDialog=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,{staticClass:"pt-5 px-0"},[t("overlay-scrollbars",{staticClass:"px-6",staticStyle:{height:"350px"}},[e.mcu.mcu_constants?[t(x,[t(b,[t("span",{staticClass:"headline"},[e._v(e._s(e.$t("Machine.SystemPanel.Constants")))])])],1),e._l(e.mcu.mcu_constants,function(r,i,n){return t("div",{key:i},[n?t(I,{staticClass:"my-3"}):e._e(),t(x,[t(b,[e._v(e._s(i))]),t(b,{staticClass:"text-right"},[e._v(e._s(r))])],1)],1)})]:e._e(),e.mcu.last_stats?[t(x,{staticClass:"mt-5"},[t(b,[t("span",{staticClass:"headline"},[e._v(e._s(e.$t("Machine.SystemPanel.LastStats")))])])],1),e._l(e.mcu.last_stats,function(r,i,n){return t("div",{key:i},[n?t(I,{staticClass:"my-3"}):e._e(),t(x,[t(b,[e._v(e._s(i))]),t(b,{staticClass:"text-right"},[e._v(e._s(r))])],1)],1)})]:e._e()],2)],1)],1)],1)],1)},pz=[],fz=E(Ac,hz,pz,!1,null,null);const r2=fz.exports;var gz=Object.getOwnPropertyDescriptor,_z=(s,e,t,r)=>{for(var i=r>1?void 0:r?gz(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let Xh=class extends k(L){constructor(){super(...arguments),this.mdiCloseThick=pe,this.mdiMemory=dv,this.mdiUsb=Jp,this.dialogDevices=!1}get mcus(){var e;if(!this.klipperReadyForGui)return[];const s=(e=this.$store.getters["printer/getMcus"])!=null?e:[];return Ft(s,"name")}get hostStats(){var s;return(s=this.$store.getters["server/getHostStats"])!=null?s:null}get showPanel(){return this.mcus.length>0||this.hostStats}};Xh=_z([S({components:{SystemPanelMcu:r2,SystemPanelHost:t2,Panel:U}})],Xh);var vz=function(){var e=this,t=e._self._c;return e._self._setupProxy,e.showPanel?t(U,{attrs:{title:e.$t("Machine.SystemPanel.SystemLoad"),icon:e.mdiMemory,"card-class":"machine-systemload-panel",collapsible:!0},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{staticClass:"d-none d-md-flex",attrs:{text:"",tile:""},on:{click:function(r){e.dialogDevices=!0}}},[t(_,{staticClass:"mr-1",attrs:{small:""}},[e._v(e._s(e.mdiUsb))]),e._v(" "+e._s(e.$t("Editor.DeviceDialog"))+" ")],1)]},proxy:!0}],null,!1,3386324002)},[t(Z,{staticClass:"px-0 py-2"},[e._l(e.mcus,function(r,i){return t("div",{key:r.name},[i?t(I,{staticClass:"my-2"}):e._e(),t(r2,{attrs:{mcu:r}})],1)}),e.hostStats?t("div",[e.mcus.length?t(I,{staticClass:"my-2"}):e._e(),t(t2)],1):e._e()],2),t(of,{attrs:{"show-dialog":e.dialogDevices},on:{close:function(r){e.dialogDevices=!1}}})],1):e._e()},bz=[],yz=E(Xh,vz,bz,!1,null,"6f940e6d");const i2=yz.exports;function n2(s,e){return function(){return s.apply(e,arguments)}}const{toString:Cz}=Object.prototype,{getPrototypeOf:mg}=Object,ld=(s=>e=>{const t=Cz.call(e);return s[t]||(s[t]=t.slice(8,-1).toLowerCase())})(Object.create(null)),gs=s=>(s=s.toLowerCase(),e=>ld(e)===s),cd=s=>e=>typeof e===s,{isArray:gn}=Array,ja=cd("undefined");function $z(s){return s!==null&&!ja(s)&&s.constructor!==null&&!ja(s.constructor)&&zt(s.constructor.isBuffer)&&s.constructor.isBuffer(s)}const a2=gs("ArrayBuffer");function xz(s){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(s):e=s&&s.buffer&&a2(s.buffer),e}const wz=cd("string"),zt=cd("function"),o2=cd("number"),ud=s=>s!==null&&typeof s=="object",Sz=s=>s===!0||s===!1,Go=s=>{if(ld(s)!=="object")return!1;const e=mg(s);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in s)&&!(Symbol.iterator in s)},Pz=gs("Date"),Dz=gs("File"),Tz=gs("Blob"),Oz=gs("FileList"),Mz=s=>ud(s)&&zt(s.pipe),kz=s=>{let e;return s&&(typeof FormData=="function"&&s instanceof FormData||zt(s.append)&&((e=ld(s))==="formdata"||e==="object"&&zt(s.toString)&&s.toString()==="[object FormData]"))},Ez=gs("URLSearchParams"),[Lz,Az,Fz,Rz]=["ReadableStream","Request","Response","Headers"].map(gs),Hz=s=>s.trim?s.trim():s.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function ho(s,e,{allOwnKeys:t=!1}={}){if(s===null||typeof s>"u")return;let r,i;if(typeof s!="object"&&(s=[s]),gn(s))for(r=0,i=s.length;r<i;r++)e.call(null,s[r],r,s);else{const n=t?Object.getOwnPropertyNames(s):Object.keys(s),a=n.length;let o;for(r=0;r<a;r++)o=n[r],e.call(null,s[o],o,s)}}function l2(s,e){e=e.toLowerCase();const t=Object.keys(s);let r=t.length,i;for(;r-- >0;)if(i=t[r],e===i.toLowerCase())return i;return null}const Er=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,c2=s=>!ja(s)&&s!==Er;function Yh(){const{caseless:s}=c2(this)&&this||{},e={},t=(r,i)=>{const n=s&&l2(e,i)||i;Go(e[n])&&Go(r)?e[n]=Yh(e[n],r):Go(r)?e[n]=Yh({},r):gn(r)?e[n]=r.slice():e[n]=r};for(let r=0,i=arguments.length;r<i;r++)arguments[r]&&ho(arguments[r],t);return e}const jz=(s,e,t,{allOwnKeys:r}={})=>(ho(e,(i,n)=>{t&&zt(i)?s[n]=n2(i,t):s[n]=i},{allOwnKeys:r}),s),Iz=s=>(s.charCodeAt(0)===65279&&(s=s.slice(1)),s),Nz=(s,e,t,r)=>{s.prototype=Object.create(e.prototype,r),s.prototype.constructor=s,Object.defineProperty(s,"super",{value:e.prototype}),t&&Object.assign(s.prototype,t)},Vz=(s,e,t,r)=>{let i,n,a;const o={};if(e=e||{},s==null)return e;do{for(i=Object.getOwnPropertyNames(s),n=i.length;n-- >0;)a=i[n],(!r||r(a,s,e))&&!o[a]&&(e[a]=s[a],o[a]=!0);s=t!==!1&&mg(s)}while(s&&(!t||t(s,e))&&s!==Object.prototype);return e},Bz=(s,e,t)=>{s=String(s),(t===void 0||t>s.length)&&(t=s.length),t-=e.length;const r=s.indexOf(e,t);return r!==-1&&r===t},Uz=s=>{if(!s)return null;if(gn(s))return s;let e=s.length;if(!o2(e))return null;const t=new Array(e);for(;e-- >0;)t[e]=s[e];return t},Wz=(s=>e=>s&&e instanceof s)(typeof Uint8Array<"u"&&mg(Uint8Array)),zz=(s,e)=>{const r=(s&&s[Symbol.iterator]).call(s);let i;for(;(i=r.next())&&!i.done;){const n=i.value;e.call(s,n[0],n[1])}},Gz=(s,e)=>{let t;const r=[];for(;(t=s.exec(e))!==null;)r.push(t);return r},Zz=gs("HTMLFormElement"),qz=s=>s.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(t,r,i){return r.toUpperCase()+i}),R1=(({hasOwnProperty:s})=>(e,t)=>s.call(e,t))(Object.prototype),Xz=gs("RegExp"),u2=(s,e)=>{const t=Object.getOwnPropertyDescriptors(s),r={};ho(t,(i,n)=>{let a;(a=e(i,n,s))!==!1&&(r[n]=a||i)}),Object.defineProperties(s,r)},Yz=s=>{u2(s,(e,t)=>{if(zt(s)&&["arguments","caller","callee"].indexOf(t)!==-1)return!1;const r=s[t];if(zt(r)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+t+"'")})}})},Jz=(s,e)=>{const t={},r=i=>{i.forEach(n=>{t[n]=!0})};return gn(s)?r(s):r(String(s).split(e)),t},Kz=()=>{},Qz=(s,e)=>s!=null&&Number.isFinite(s=+s)?s:e;function eG(s){return!!(s&&zt(s.append)&&s[Symbol.toStringTag]==="FormData"&&s[Symbol.iterator])}const tG=s=>{const e=new Array(10),t=(r,i)=>{if(ud(r)){if(e.indexOf(r)>=0)return;if(!("toJSON"in r)){e[i]=r;const n=gn(r)?[]:{};return ho(r,(a,o)=>{const l=t(a,i+1);!ja(l)&&(n[o]=l)}),e[i]=void 0,n}}return r};return t(s,0)},sG=gs("AsyncFunction"),rG=s=>s&&(ud(s)||zt(s))&&zt(s.then)&&zt(s.catch),d2=((s,e)=>s?setImmediate:e?((t,r)=>(Er.addEventListener("message",({source:i,data:n})=>{i===Er&&n===t&&r.length&&r.shift()()},!1),i=>{r.push(i),Er.postMessage(t,"*")}))("axios@".concat(Math.random()),[]):t=>setTimeout(t))(typeof setImmediate=="function",zt(Er.postMessage)),iG=typeof queueMicrotask<"u"?queueMicrotask.bind(Er):typeof process<"u"&&process.nextTick||d2,Y={isArray:gn,isArrayBuffer:a2,isBuffer:$z,isFormData:kz,isArrayBufferView:xz,isString:wz,isNumber:o2,isBoolean:Sz,isObject:ud,isPlainObject:Go,isReadableStream:Lz,isRequest:Az,isResponse:Fz,isHeaders:Rz,isUndefined:ja,isDate:Pz,isFile:Dz,isBlob:Tz,isRegExp:Xz,isFunction:zt,isStream:Mz,isURLSearchParams:Ez,isTypedArray:Wz,isFileList:Oz,forEach:ho,merge:Yh,extend:jz,trim:Hz,stripBOM:Iz,inherits:Nz,toFlatObject:Vz,kindOf:ld,kindOfTest:gs,endsWith:Bz,toArray:Uz,forEachEntry:zz,matchAll:Gz,isHTMLForm:Zz,hasOwnProperty:R1,hasOwnProp:R1,reduceDescriptors:u2,freezeMethods:Yz,toObjectSet:Jz,toCamelCase:qz,noop:Kz,toFiniteNumber:Qz,findKey:l2,global:Er,isContextDefined:c2,isSpecCompliantForm:eG,toJSONObject:tG,isAsyncFn:sG,isThenable:rG,setImmediate:d2,asap:iG};function xe(s,e,t,r,i){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=s,this.name="AxiosError",e&&(this.code=e),t&&(this.config=t),r&&(this.request=r),i&&(this.response=i,this.status=i.status?i.status:null)}Y.inherits(xe,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:Y.toJSONObject(this.config),code:this.code,status:this.status}}});const m2=xe.prototype,h2={};["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(s=>{h2[s]={value:s}});Object.defineProperties(xe,h2);Object.defineProperty(m2,"isAxiosError",{value:!0});xe.from=(s,e,t,r,i,n)=>{const a=Object.create(m2);return Y.toFlatObject(s,a,function(l){return l!==Error.prototype},o=>o!=="isAxiosError"),xe.call(a,s.message,e,t,r,i),a.cause=s,a.name=s.name,n&&Object.assign(a,n),a};const nG=null;function Jh(s){return Y.isPlainObject(s)||Y.isArray(s)}function p2(s){return Y.endsWith(s,"[]")?s.slice(0,-2):s}function H1(s,e,t){return s?s.concat(e).map(function(i,n){return i=p2(i),!t&&n?"["+i+"]":i}).join(t?".":""):e}function aG(s){return Y.isArray(s)&&!s.some(Jh)}const oG=Y.toFlatObject(Y,{},null,function(e){return/^is[A-Z]/.test(e)});function dd(s,e,t){if(!Y.isObject(s))throw new TypeError("target must be an object");e=e||new FormData,t=Y.toFlatObject(t,{metaTokens:!0,dots:!1,indexes:!1},!1,function(p,v){return!Y.isUndefined(v[p])});const r=t.metaTokens,i=t.visitor||c,n=t.dots,a=t.indexes,l=(t.Blob||typeof Blob<"u"&&Blob)&&Y.isSpecCompliantForm(e);if(!Y.isFunction(i))throw new TypeError("visitor must be a function");function u(f){if(f===null)return"";if(Y.isDate(f))return f.toISOString();if(!l&&Y.isBlob(f))throw new xe("Blob is not supported. Use a Buffer instead.");return Y.isArrayBuffer(f)||Y.isTypedArray(f)?l&&typeof Blob=="function"?new Blob([f]):Buffer.from(f):f}function c(f,p,v){let C=f;if(f&&!v&&typeof f=="object"){if(Y.endsWith(p,"{}"))p=r?p:p.slice(0,-2),f=JSON.stringify(f);else if(Y.isArray(f)&&aG(f)||(Y.isFileList(f)||Y.endsWith(p,"[]"))&&(C=Y.toArray(f)))return p=p2(p),C.forEach(function(M,F){!(Y.isUndefined(M)||M===null)&&e.append(a===!0?H1([p],F,n):a===null?p:p+"[]",u(M))}),!1}return Jh(f)?!0:(e.append(H1(v,p,n),u(f)),!1)}const d=[],m=Object.assign(oG,{defaultVisitor:c,convertValue:u,isVisitable:Jh});function h(f,p){if(!Y.isUndefined(f)){if(d.indexOf(f)!==-1)throw Error("Circular reference detected in "+p.join("."));d.push(f),Y.forEach(f,function(C,P){(!(Y.isUndefined(C)||C===null)&&i.call(e,C,Y.isString(P)?P.trim():P,p,m))===!0&&h(C,p?p.concat(P):[P])}),d.pop()}}if(!Y.isObject(s))throw new TypeError("data must be an object");return h(s),e}function j1(s){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(s).replace(/[!'()~]|%20|%00/g,function(r){return e[r]})}function hg(s,e){this._pairs=[],s&&dd(s,this,e)}const f2=hg.prototype;f2.append=function(e,t){this._pairs.push([e,t])};f2.toString=function(e){const t=e?function(r){return e.call(this,r,j1)}:j1;return this._pairs.map(function(i){return t(i[0])+"="+t(i[1])},"").join("&")};function lG(s){return encodeURIComponent(s).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function g2(s,e,t){if(!e)return s;const r=t&&t.encode||lG;Y.isFunction(t)&&(t={serialize:t});const i=t&&t.serialize;let n;if(i?n=i(e,t):n=Y.isURLSearchParams(e)?e.toString():new hg(e,t).toString(r),n){const a=s.indexOf("#");a!==-1&&(s=s.slice(0,a)),s+=(s.indexOf("?")===-1?"?":"&")+n}return s}class I1{constructor(){this.handlers=[]}use(e,t,r){return this.handlers.push({fulfilled:e,rejected:t,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){Y.forEach(this.handlers,function(r){r!==null&&e(r)})}}const _2={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},cG=typeof URLSearchParams<"u"?URLSearchParams:hg,uG=typeof FormData<"u"?FormData:null,dG=typeof Blob<"u"?Blob:null,mG={isBrowser:!0,classes:{URLSearchParams:cG,FormData:uG,Blob:dG},protocols:["http","https","file","blob","url","data"]},pg=typeof window<"u"&&typeof document<"u",Kh=typeof navigator=="object"&&navigator||void 0,hG=pg&&(!Kh||["ReactNative","NativeScript","NS"].indexOf(Kh.product)<0),pG=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",fG=pg&&window.location.href||"http://localhost",gG=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:pg,hasStandardBrowserEnv:hG,hasStandardBrowserWebWorkerEnv:pG,navigator:Kh,origin:fG},Symbol.toStringTag,{value:"Module"})),ft={...gG,...mG};function _G(s,e){return dd(s,new ft.classes.URLSearchParams,Object.assign({visitor:function(t,r,i,n){return ft.isNode&&Y.isBuffer(t)?(this.append(r,t.toString("base64")),!1):n.defaultVisitor.apply(this,arguments)}},e))}function vG(s){return Y.matchAll(/\w+|\[(\w*)]/g,s).map(e=>e[0]==="[]"?"":e[1]||e[0])}function bG(s){const e={},t=Object.keys(s);let r;const i=t.length;let n;for(r=0;r<i;r++)n=t[r],e[n]=s[n];return e}function v2(s){function e(t,r,i,n){let a=t[n++];if(a==="__proto__")return!0;const o=Number.isFinite(+a),l=n>=t.length;return a=!a&&Y.isArray(i)?i.length:a,l?(Y.hasOwnProp(i,a)?i[a]=[i[a],r]:i[a]=r,!o):((!i[a]||!Y.isObject(i[a]))&&(i[a]=[]),e(t,r,i[a],n)&&Y.isArray(i[a])&&(i[a]=bG(i[a])),!o)}if(Y.isFormData(s)&&Y.isFunction(s.entries)){const t={};return Y.forEachEntry(s,(r,i)=>{e(vG(r),i,t,0)}),t}return null}function yG(s,e,t){if(Y.isString(s))try{return(e||JSON.parse)(s),Y.trim(s)}catch(r){if(r.name!=="SyntaxError")throw r}return(t||JSON.stringify)(s)}const po={transitional:_2,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){const r=t.getContentType()||"",i=r.indexOf("application/json")>-1,n=Y.isObject(e);if(n&&Y.isHTMLForm(e)&&(e=new FormData(e)),Y.isFormData(e))return i?JSON.stringify(v2(e)):e;if(Y.isArrayBuffer(e)||Y.isBuffer(e)||Y.isStream(e)||Y.isFile(e)||Y.isBlob(e)||Y.isReadableStream(e))return e;if(Y.isArrayBufferView(e))return e.buffer;if(Y.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let o;if(n){if(r.indexOf("application/x-www-form-urlencoded")>-1)return _G(e,this.formSerializer).toString();if((o=Y.isFileList(e))||r.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return dd(o?{"files[]":e}:e,l&&new l,this.formSerializer)}}return n||i?(t.setContentType("application/json",!1),yG(e)):e}],transformResponse:[function(e){const t=this.transitional||po.transitional,r=t&&t.forcedJSONParsing,i=this.responseType==="json";if(Y.isResponse(e)||Y.isReadableStream(e))return e;if(e&&Y.isString(e)&&(r&&!this.responseType||i)){const a=!(t&&t.silentJSONParsing)&&i;try{return JSON.parse(e)}catch(o){if(a)throw o.name==="SyntaxError"?xe.from(o,xe.ERR_BAD_RESPONSE,this,null,this.response):o}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:ft.classes.FormData,Blob:ft.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};Y.forEach(["delete","get","head","post","put","patch"],s=>{po.headers[s]={}});const CG=Y.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"]),$G=s=>{const e={};let t,r,i;return s&&s.split("\n").forEach(function(a){i=a.indexOf(":"),t=a.substring(0,i).trim().toLowerCase(),r=a.substring(i+1).trim(),!(!t||e[t]&&CG[t])&&(t==="set-cookie"?e[t]?e[t].push(r):e[t]=[r]:e[t]=e[t]?e[t]+", "+r:r)}),e},N1=Symbol("internals");function Dn(s){return s&&String(s).trim().toLowerCase()}function Zo(s){return s===!1||s==null?s:Y.isArray(s)?s.map(Zo):String(s)}function xG(s){const e=Object.create(null),t=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=t.exec(s);)e[r[1]]=r[2];return e}const wG=s=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(s.trim());function tm(s,e,t,r,i){if(Y.isFunction(r))return r.call(this,e,t);if(i&&(e=t),!!Y.isString(e)){if(Y.isString(r))return e.indexOf(r)!==-1;if(Y.isRegExp(r))return r.test(e)}}function SG(s){return s.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,r)=>t.toUpperCase()+r)}function PG(s,e){const t=Y.toCamelCase(" "+e);["get","set","has"].forEach(r=>{Object.defineProperty(s,r+t,{value:function(i,n,a){return this[r].call(this,e,i,n,a)},configurable:!0})})}let Lt=class{constructor(e){e&&this.set(e)}set(e,t,r){const i=this;function n(o,l,u){const c=Dn(l);if(!c)throw new Error("header name must be a non-empty string");const d=Y.findKey(i,c);(!d||i[d]===void 0||u===!0||u===void 0&&i[d]!==!1)&&(i[d||l]=Zo(o))}const a=(o,l)=>Y.forEach(o,(u,c)=>n(u,c,l));if(Y.isPlainObject(e)||e instanceof this.constructor)a(e,t);else if(Y.isString(e)&&(e=e.trim())&&!wG(e))a($G(e),t);else if(Y.isHeaders(e))for(const[o,l]of e.entries())n(l,o,r);else e!=null&&n(t,e,r);return this}get(e,t){if(e=Dn(e),e){const r=Y.findKey(this,e);if(r){const i=this[r];if(!t)return i;if(t===!0)return xG(i);if(Y.isFunction(t))return t.call(this,i,r);if(Y.isRegExp(t))return t.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=Dn(e),e){const r=Y.findKey(this,e);return!!(r&&this[r]!==void 0&&(!t||tm(this,this[r],r,t)))}return!1}delete(e,t){const r=this;let i=!1;function n(a){if(a=Dn(a),a){const o=Y.findKey(r,a);o&&(!t||tm(r,r[o],o,t))&&(delete r[o],i=!0)}}return Y.isArray(e)?e.forEach(n):n(e),i}clear(e){const t=Object.keys(this);let r=t.length,i=!1;for(;r--;){const n=t[r];(!e||tm(this,this[n],n,e,!0))&&(delete this[n],i=!0)}return i}normalize(e){const t=this,r={};return Y.forEach(this,(i,n)=>{const a=Y.findKey(r,n);if(a){t[a]=Zo(i),delete t[n];return}const o=e?SG(n):String(n).trim();o!==n&&delete t[n],t[o]=Zo(i),r[o]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return Y.forEach(this,(r,i)=>{r!=null&&r!==!1&&(t[i]=e&&Y.isArray(r)?r.join(", "):r)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,t])=>e+": "+t).join("\n")}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const r=new this(e);return t.forEach(i=>r.set(i)),r}static accessor(e){const r=(this[N1]=this[N1]={accessors:{}}).accessors,i=this.prototype;function n(a){const o=Dn(a);r[o]||(PG(i,a),r[o]=!0)}return Y.isArray(e)?e.forEach(n):n(e),this}};Lt.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);Y.reduceDescriptors(Lt.prototype,({value:s},e)=>{let t=e[0].toUpperCase()+e.slice(1);return{get:()=>s,set(r){this[t]=r}}});Y.freezeMethods(Lt);function sm(s,e){const t=this||po,r=e||t,i=Lt.from(r.headers);let n=r.data;return Y.forEach(s,function(o){n=o.call(t,n,i.normalize(),e?e.status:void 0)}),i.normalize(),n}function b2(s){return!!(s&&s.__CANCEL__)}function _n(s,e,t){xe.call(this,s==null?"canceled":s,xe.ERR_CANCELED,e,t),this.name="CanceledError"}Y.inherits(_n,xe,{__CANCEL__:!0});function y2(s,e,t){const r=t.config.validateStatus;!t.status||!r||r(t.status)?s(t):e(new xe("Request failed with status code "+t.status,[xe.ERR_BAD_REQUEST,xe.ERR_BAD_RESPONSE][Math.floor(t.status/100)-4],t.config,t.request,t))}function DG(s){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(s);return e&&e[1]||""}function TG(s,e){s=s||10;const t=new Array(s),r=new Array(s);let i=0,n=0,a;return e=e!==void 0?e:1e3,function(l){const u=Date.now(),c=r[n];a||(a=u),t[i]=l,r[i]=u;let d=n,m=0;for(;d!==i;)m+=t[d++],d=d%s;if(i=(i+1)%s,i===n&&(n=(n+1)%s),u-a<e)return;const h=c&&u-c;return h?Math.round(m*1e3/h):void 0}}function OG(s,e){let t=0,r=1e3/e,i,n;const a=(u,c=Date.now())=>{t=c,i=null,n&&(clearTimeout(n),n=null),s.apply(null,u)};return[(...u)=>{const c=Date.now(),d=c-t;d>=r?a(u,c):(i=u,n||(n=setTimeout(()=>{n=null,a(i)},r-d)))},()=>i&&a(i)]}const Fc=(s,e,t=3)=>{let r=0;const i=TG(50,250);return OG(n=>{const a=n.loaded,o=n.lengthComputable?n.total:void 0,l=a-r,u=i(l),c=a<=o;r=a;const d={loaded:a,total:o,progress:o?a/o:void 0,bytes:l,rate:u||void 0,estimated:u&&o&&c?(o-a)/u:void 0,event:n,lengthComputable:o!=null,[e?"download":"upload"]:!0};s(d)},t)},V1=(s,e)=>{const t=s!=null;return[r=>e[0]({lengthComputable:t,total:s,loaded:r}),e[1]]},B1=s=>(...e)=>Y.asap(()=>s(...e)),MG=ft.hasStandardBrowserEnv?((s,e)=>t=>(t=new URL(t,ft.origin),s.protocol===t.protocol&&s.host===t.host&&(e||s.port===t.port)))(new URL(ft.origin),ft.navigator&&/(msie|trident)/i.test(ft.navigator.userAgent)):()=>!0,kG=ft.hasStandardBrowserEnv?{write(s,e,t,r,i,n){const a=[s+"="+encodeURIComponent(e)];Y.isNumber(t)&&a.push("expires="+new Date(t).toGMTString()),Y.isString(r)&&a.push("path="+r),Y.isString(i)&&a.push("domain="+i),n===!0&&a.push("secure"),document.cookie=a.join("; ")},read(s){const e=document.cookie.match(new RegExp("(^|;\\s*)("+s+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove(s){this.write(s,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function EG(s){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(s)}function LG(s,e){return e?s.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):s}function C2(s,e,t){let r=!EG(e);return s&&r||t==!1?LG(s,e):e}const U1=s=>s instanceof Lt?{...s}:s;function Kr(s,e){e=e||{};const t={};function r(u,c,d,m){return Y.isPlainObject(u)&&Y.isPlainObject(c)?Y.merge.call({caseless:m},u,c):Y.isPlainObject(c)?Y.merge({},c):Y.isArray(c)?c.slice():c}function i(u,c,d,m){if(Y.isUndefined(c)){if(!Y.isUndefined(u))return r(void 0,u,d,m)}else return r(u,c,d,m)}function n(u,c){if(!Y.isUndefined(c))return r(void 0,c)}function a(u,c){if(Y.isUndefined(c)){if(!Y.isUndefined(u))return r(void 0,u)}else return r(void 0,c)}function o(u,c,d){if(d in e)return r(u,c);if(d in s)return r(void 0,u)}const l={url:n,method:n,data:n,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:o,headers:(u,c,d)=>i(U1(u),U1(c),d,!0)};return Y.forEach(Object.keys(Object.assign({},s,e)),function(c){const d=l[c]||i,m=d(s[c],e[c],c);Y.isUndefined(m)&&d!==o||(t[c]=m)}),t}const $2=s=>{const e=Kr({},s);let{data:t,withXSRFToken:r,xsrfHeaderName:i,xsrfCookieName:n,headers:a,auth:o}=e;e.headers=a=Lt.from(a),e.url=g2(C2(e.baseURL,e.url,e.allowAbsoluteUrls),s.params,s.paramsSerializer),o&&a.set("Authorization","Basic "+btoa((o.username||"")+":"+(o.password?unescape(encodeURIComponent(o.password)):"")));let l;if(Y.isFormData(t)){if(ft.hasStandardBrowserEnv||ft.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if((l=a.getContentType())!==!1){const[u,...c]=l?l.split(";").map(d=>d.trim()).filter(Boolean):[];a.setContentType([u||"multipart/form-data",...c].join("; "))}}if(ft.hasStandardBrowserEnv&&(r&&Y.isFunction(r)&&(r=r(e)),r||r!==!1&&MG(e.url))){const u=i&&n&&kG.read(n);u&&a.set(i,u)}return e},AG=typeof XMLHttpRequest<"u",FG=AG&&function(s){return new Promise(function(t,r){const i=$2(s);let n=i.data;const a=Lt.from(i.headers).normalize();let{responseType:o,onUploadProgress:l,onDownloadProgress:u}=i,c,d,m,h,f;function p(){h&&h(),f&&f(),i.cancelToken&&i.cancelToken.unsubscribe(c),i.signal&&i.signal.removeEventListener("abort",c)}let v=new XMLHttpRequest;v.open(i.method.toUpperCase(),i.url,!0),v.timeout=i.timeout;function C(){if(!v)return;const M=Lt.from("getAllResponseHeaders"in v&&v.getAllResponseHeaders()),O={data:!o||o==="text"||o==="json"?v.responseText:v.response,status:v.status,statusText:v.statusText,headers:M,config:s,request:v};y2(function(D){t(D),p()},function(D){r(D),p()},O),v=null}"onloadend"in v?v.onloadend=C:v.onreadystatechange=function(){!v||v.readyState!==4||v.status===0&&!(v.responseURL&&v.responseURL.indexOf("file:")===0)||setTimeout(C)},v.onabort=function(){v&&(r(new xe("Request aborted",xe.ECONNABORTED,s,v)),v=null)},v.onerror=function(){r(new xe("Network Error",xe.ERR_NETWORK,s,v)),v=null},v.ontimeout=function(){let F=i.timeout?"timeout of "+i.timeout+"ms exceeded":"timeout exceeded";const O=i.transitional||_2;i.timeoutErrorMessage&&(F=i.timeoutErrorMessage),r(new xe(F,O.clarifyTimeoutError?xe.ETIMEDOUT:xe.ECONNABORTED,s,v)),v=null},n===void 0&&a.setContentType(null),"setRequestHeader"in v&&Y.forEach(a.toJSON(),function(F,O){v.setRequestHeader(O,F)}),Y.isUndefined(i.withCredentials)||(v.withCredentials=!!i.withCredentials),o&&o!=="json"&&(v.responseType=i.responseType),u&&([m,f]=Fc(u,!0),v.addEventListener("progress",m)),l&&v.upload&&([d,h]=Fc(l),v.upload.addEventListener("progress",d),v.upload.addEventListener("loadend",h)),(i.cancelToken||i.signal)&&(c=M=>{v&&(r(!M||M.type?new _n(null,s,v):M),v.abort(),v=null)},i.cancelToken&&i.cancelToken.subscribe(c),i.signal&&(i.signal.aborted?c():i.signal.addEventListener("abort",c)));const P=DG(i.url);if(P&&ft.protocols.indexOf(P)===-1){r(new xe("Unsupported protocol "+P+":",xe.ERR_BAD_REQUEST,s));return}v.send(n||null)})},RG=(s,e)=>{const{length:t}=s=s?s.filter(Boolean):[];if(e||t){let r=new AbortController,i;const n=function(u){if(!i){i=!0,o();const c=u instanceof Error?u:this.reason;r.abort(c instanceof xe?c:new _n(c instanceof Error?c.message:c))}};let a=e&&setTimeout(()=>{a=null,n(new xe("timeout ".concat(e," of ms exceeded"),xe.ETIMEDOUT))},e);const o=()=>{s&&(a&&clearTimeout(a),a=null,s.forEach(u=>{u.unsubscribe?u.unsubscribe(n):u.removeEventListener("abort",n)}),s=null)};s.forEach(u=>u.addEventListener("abort",n));const{signal:l}=r;return l.unsubscribe=()=>Y.asap(o),l}},HG=function*(s,e){let t=s.byteLength;if(t<e){yield s;return}let r=0,i;for(;r<t;)i=r+e,yield s.slice(r,i),r=i},jG=async function*(s,e){for await(const t of IG(s))yield*HG(t,e)},IG=async function*(s){if(s[Symbol.asyncIterator]){yield*s;return}const e=s.getReader();try{for(;;){const{done:t,value:r}=await e.read();if(t)break;yield r}}finally{await e.cancel()}},W1=(s,e,t,r)=>{const i=jG(s,e);let n=0,a,o=l=>{a||(a=!0,r&&r(l))};return new ReadableStream({async pull(l){try{const{done:u,value:c}=await i.next();if(u){o(),l.close();return}let d=c.byteLength;if(t){let m=n+=d;t(m)}l.enqueue(new Uint8Array(c))}catch(u){throw o(u),u}},cancel(l){return o(l),i.return()}},{highWaterMark:2})},md=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",x2=md&&typeof ReadableStream=="function",NG=md&&(typeof TextEncoder=="function"?(s=>e=>s.encode(e))(new TextEncoder):async s=>new Uint8Array(await new Response(s).arrayBuffer())),w2=(s,...e)=>{try{return!!s(...e)}catch{return!1}},VG=x2&&w2(()=>{let s=!1;const e=new Request(ft.origin,{body:new ReadableStream,method:"POST",get duplex(){return s=!0,"half"}}).headers.has("Content-Type");return s&&!e}),z1=64*1024,Qh=x2&&w2(()=>Y.isReadableStream(new Response("").body)),Rc={stream:Qh&&(s=>s.body)};md&&(s=>{["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!Rc[e]&&(Rc[e]=Y.isFunction(s[e])?t=>t[e]():(t,r)=>{throw new xe("Response type '".concat(e,"' is not supported"),xe.ERR_NOT_SUPPORT,r)})})})(new Response);const BG=async s=>{if(s==null)return 0;if(Y.isBlob(s))return s.size;if(Y.isSpecCompliantForm(s))return(await new Request(ft.origin,{method:"POST",body:s}).arrayBuffer()).byteLength;if(Y.isArrayBufferView(s)||Y.isArrayBuffer(s))return s.byteLength;if(Y.isURLSearchParams(s)&&(s=s+""),Y.isString(s))return(await NG(s)).byteLength},UG=async(s,e)=>{const t=Y.toFiniteNumber(s.getContentLength());return t==null?BG(e):t},WG=md&&(async s=>{let{url:e,method:t,data:r,signal:i,cancelToken:n,timeout:a,onDownloadProgress:o,onUploadProgress:l,responseType:u,headers:c,withCredentials:d="same-origin",fetchOptions:m}=$2(s);u=u?(u+"").toLowerCase():"text";let h=RG([i,n&&n.toAbortSignal()],a),f;const p=h&&h.unsubscribe&&(()=>{h.unsubscribe()});let v;try{if(l&&VG&&t!=="get"&&t!=="head"&&(v=await UG(c,r))!==0){let O=new Request(e,{method:"POST",body:r,duplex:"half"}),$;if(Y.isFormData(r)&&($=O.headers.get("content-type"))&&c.setContentType($),O.body){const[D,V]=V1(v,Fc(B1(l)));r=W1(O.body,z1,D,V)}}Y.isString(d)||(d=d?"include":"omit");const C="credentials"in Request.prototype;f=new Request(e,{...m,signal:h,method:t.toUpperCase(),headers:c.normalize().toJSON(),body:r,duplex:"half",credentials:C?d:void 0});let P=await fetch(f);const M=Qh&&(u==="stream"||u==="response");if(Qh&&(o||M&&p)){const O={};["status","statusText","headers"].forEach(N=>{O[N]=P[N]});const $=Y.toFiniteNumber(P.headers.get("content-length")),[D,V]=o&&V1($,Fc(B1(o),!0))||[];P=new Response(W1(P.body,z1,D,()=>{V&&V(),p&&p()}),O)}u=u||"text";let F=await Rc[Y.findKey(Rc,u)||"text"](P,s);return!M&&p&&p(),await new Promise((O,$)=>{y2(O,$,{data:F,headers:Lt.from(P.headers),status:P.status,statusText:P.statusText,config:s,request:f})})}catch(C){throw p&&p(),C&&C.name==="TypeError"&&/fetch/i.test(C.message)?Object.assign(new xe("Network Error",xe.ERR_NETWORK,s,f),{cause:C.cause||C}):xe.from(C,C&&C.code,s,f)}}),ep={http:nG,xhr:FG,fetch:WG};Y.forEach(ep,(s,e)=>{if(s){try{Object.defineProperty(s,"name",{value:e})}catch{}Object.defineProperty(s,"adapterName",{value:e})}});const G1=s=>"- ".concat(s),zG=s=>Y.isFunction(s)||s===null||s===!1,S2={getAdapter:s=>{s=Y.isArray(s)?s:[s];const{length:e}=s;let t,r;const i={};for(let n=0;n<e;n++){t=s[n];let a;if(r=t,!zG(t)&&(r=ep[(a=String(t)).toLowerCase()],r===void 0))throw new xe("Unknown adapter '".concat(a,"'"));if(r)break;i[a||"#"+n]=r}if(!r){const n=Object.entries(i).map(([o,l])=>"adapter ".concat(o," ")+(l===!1?"is not supported by the environment":"is not available in the build"));let a=e?n.length>1?"since :\n"+n.map(G1).join("\n"):" "+G1(n[0]):"as no adapter specified";throw new xe("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return r},adapters:ep};function rm(s){if(s.cancelToken&&s.cancelToken.throwIfRequested(),s.signal&&s.signal.aborted)throw new _n(null,s)}function Z1(s){return rm(s),s.headers=Lt.from(s.headers),s.data=sm.call(s,s.transformRequest),["post","put","patch"].indexOf(s.method)!==-1&&s.headers.setContentType("application/x-www-form-urlencoded",!1),S2.getAdapter(s.adapter||po.adapter)(s).then(function(r){return rm(s),r.data=sm.call(s,s.transformResponse,r),r.headers=Lt.from(r.headers),r},function(r){return b2(r)||(rm(s),r&&r.response&&(r.response.data=sm.call(s,s.transformResponse,r.response),r.response.headers=Lt.from(r.response.headers))),Promise.reject(r)})}const P2="1.8.3",hd={};["object","boolean","number","function","string","symbol"].forEach((s,e)=>{hd[s]=function(r){return typeof r===s||"a"+(e<1?"n ":" ")+s}});const q1={};hd.transitional=function(e,t,r){function i(n,a){return"[Axios v"+P2+"] Transitional option '"+n+"'"+a+(r?". "+r:"")}return(n,a,o)=>{if(e===!1)throw new xe(i(a," has been removed"+(t?" in "+t:"")),xe.ERR_DEPRECATED);return t&&!q1[a]&&(q1[a]=!0,console.warn(i(a," has been deprecated since v"+t+" and will be removed in the near future"))),e?e(n,a,o):!0}};hd.spelling=function(e){return(t,r)=>(console.warn("".concat(r," is likely a misspelling of ").concat(e)),!0)};function GG(s,e,t){if(typeof s!="object")throw new xe("options must be an object",xe.ERR_BAD_OPTION_VALUE);const r=Object.keys(s);let i=r.length;for(;i-- >0;){const n=r[i],a=e[n];if(a){const o=s[n],l=o===void 0||a(o,n,s);if(l!==!0)throw new xe("option "+n+" must be "+l,xe.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new xe("Unknown option "+n,xe.ERR_BAD_OPTION)}}const qo={assertOptions:GG,validators:hd},ys=qo.validators;let Rr=class{constructor(e){this.defaults=e,this.interceptors={request:new I1,response:new I1}}async request(e,t){try{return await this._request(e,t)}catch(r){if(r instanceof Error){let i={};Error.captureStackTrace?Error.captureStackTrace(i):i=new Error;const n=i.stack?i.stack.replace(/^.+\n/,""):"";try{r.stack?n&&!String(r.stack).endsWith(n.replace(/^.+\n.+\n/,""))&&(r.stack+="\n"+n):r.stack=n}catch{}}throw r}}_request(e,t){typeof e=="string"?(t=t||{},t.url=e):t=e||{},t=Kr(this.defaults,t);const{transitional:r,paramsSerializer:i,headers:n}=t;r!==void 0&&qo.assertOptions(r,{silentJSONParsing:ys.transitional(ys.boolean),forcedJSONParsing:ys.transitional(ys.boolean),clarifyTimeoutError:ys.transitional(ys.boolean)},!1),i!=null&&(Y.isFunction(i)?t.paramsSerializer={serialize:i}:qo.assertOptions(i,{encode:ys.function,serialize:ys.function},!0)),t.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),qo.assertOptions(t,{baseUrl:ys.spelling("baseURL"),withXsrfToken:ys.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let a=n&&Y.merge(n.common,n[t.method]);n&&Y.forEach(["delete","get","head","post","put","patch","common"],f=>{delete n[f]}),t.headers=Lt.concat(a,n);const o=[];let l=!0;this.interceptors.request.forEach(function(p){typeof p.runWhen=="function"&&p.runWhen(t)===!1||(l=l&&p.synchronous,o.unshift(p.fulfilled,p.rejected))});const u=[];this.interceptors.response.forEach(function(p){u.push(p.fulfilled,p.rejected)});let c,d=0,m;if(!l){const f=[Z1.bind(this),void 0];for(f.unshift.apply(f,o),f.push.apply(f,u),m=f.length,c=Promise.resolve(t);d<m;)c=c.then(f[d++],f[d++]);return c}m=o.length;let h=t;for(d=0;d<m;){const f=o[d++],p=o[d++];try{h=f(h)}catch(v){p.call(this,v);break}}try{c=Z1.call(this,h)}catch(f){return Promise.reject(f)}for(d=0,m=u.length;d<m;)c=c.then(u[d++],u[d++]);return c}getUri(e){e=Kr(this.defaults,e);const t=C2(e.baseURL,e.url,e.allowAbsoluteUrls);return g2(t,e.params,e.paramsSerializer)}};Y.forEach(["delete","get","head","options"],function(e){Rr.prototype[e]=function(t,r){return this.request(Kr(r||{},{method:e,url:t,data:(r||{}).data}))}});Y.forEach(["post","put","patch"],function(e){function t(r){return function(n,a,o){return this.request(Kr(o||{},{method:e,headers:r?{"Content-Type":"multipart/form-data"}:{},url:n,data:a}))}}Rr.prototype[e]=t(),Rr.prototype[e+"Form"]=t(!0)});let ZG=class D2{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let t;this.promise=new Promise(function(n){t=n});const r=this;this.promise.then(i=>{if(!r._listeners)return;let n=r._listeners.length;for(;n-- >0;)r._listeners[n](i);r._listeners=null}),this.promise.then=i=>{let n;const a=new Promise(o=>{r.subscribe(o),n=o}).then(i);return a.cancel=function(){r.unsubscribe(n)},a},e(function(n,a,o){r.reason||(r.reason=new _n(n,a,o),t(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);t!==-1&&this._listeners.splice(t,1)}toAbortSignal(){const e=new AbortController,t=r=>{e.abort(r)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let e;return{token:new D2(function(i){e=i}),cancel:e}}};function qG(s){return function(t){return s.apply(null,t)}}function XG(s){return Y.isObject(s)&&s.isAxiosError===!0}const tp={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(tp).forEach(([s,e])=>{tp[e]=s});function T2(s){const e=new Rr(s),t=n2(Rr.prototype.request,e);return Y.extend(t,Rr.prototype,e,{allOwnKeys:!0}),Y.extend(t,e,null,{allOwnKeys:!0}),t.create=function(i){return T2(Kr(s,i))},t}const Le=T2(po);Le.Axios=Rr;Le.CanceledError=_n;Le.CancelToken=ZG;Le.isCancel=b2;Le.VERSION=P2;Le.toFormData=dd;Le.AxiosError=xe;Le.Cancel=Le.CanceledError;Le.all=function(e){return Promise.all(e)};Le.spread=qG;Le.isAxiosError=XG;Le.mergeConfig=Kr;Le.AxiosHeaders=Lt;Le.formToJSON=s=>v2(Y.isHTMLForm(s)?new FormData(s):s);Le.getAdapter=S2.getAdapter;Le.HttpStatusCode=tp;Le.default=Le;const{Axios:Nse,AxiosError:Vse,CanceledError:Bse,isCancel:Use,CancelToken:Wse,VERSION:zse,all:Gse,Cancel:Zse,isAxiosError:qse,spread:Xse,toFormData:Yse,AxiosHeaders:Jse,HttpStatusCode:Kse,formToJSON:Qse,getAdapter:ere,mergeConfig:tre}=Le;var YG=Object.getOwnPropertyDescriptor,JG=(s,e,t,r)=>{for(var i=r>1?void 0:r?YG(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let sp=class extends k(L,vt){constructor(){super(...arguments),this.mdiInformation=Ht,this.mdiClose=Ba,this.mdiCog=ss,this.mdiFolder=Np,this.mdiFolderUpload=Bp,this.mdiFileDocumentEditOutline=za,this.mdiFile=Bs,this.mdiCloudDownload=Kn,this.mdiRenameBox=vu,this.mdiDelete=Ue,this.mdiCloseThick=pe,this.mdiLockOutline=fu,this.mdiContentCopy=Fp,this.sortFiles=rf,this.formatFilesize=Xe,this.currentPage=1,this.contextMenu={shown:!1,isDirectory:!1,touchTimer:null,x:0,y:0,item:{isDirectory:!1,filename:"",permissions:"",modified:new Date}},this.dialogImage={show:!1,item:{name:null,url:null,svg:null}},this.dialogCreateFile={show:!1,name:""},this.dialogRenameFile={show:!1,newName:"",item:{isDirectory:!1,filename:"",permissions:"",modified:new Date}},this.dialogDuplicateFile={show:!1,newName:"",item:{isDirectory:!1,filename:"",permissions:"",modified:new Date}},this.dialogCreateDirectory={show:!1,name:""},this.dialogRenameDirectory={show:!1,newName:"",item:{isDirectory:!1,filename:"",permissions:"",modified:new Date}},this.dialogDeleteDirectory={show:!1,item:{isDirectory:!1,filename:"",permissions:"",modified:new Date}},this.uploadSnackbar={status:!1,filename:"",percent:0,speed:0,total:0,number:0,max:0,cancelTokenSource:{}},this.draggingFile={item:{isDirectory:!1,filename:"",permissions:"",modified:new Date}},this.deleteDialog=!1,this.deleteSelectedDialog=!1,this.isInvalidName=!0,this.nameInputRules=[s=>!!s||this.$t("Files.InvalidNameEmpty"),s=>!this.existsFilename(s)||this.$t("Files.InvalidNameAlreadyExists")]}existsFilename(s){return this.files.findIndex(e=>e.filename===s)>=0}get blockFileUpload(){var s;return(s=this.$store.state.gui.view.blockFileUpload)!=null?s:!1}set blockFileUpload(s){this.$store.dispatch("gui/saveSettingWithoutUpload",{name:"view.blockFileUpload",value:s})}get toolbarButtons(){return[{text:this.$t("Machine.ConfigFilesPanel.Download"),color:"primary",icon:Kn,loadingName:"configDownloadZip",onlyWriteable:!1,condition:this.selectedFiles.length>0,click:()=>{this.downloadSelectedFiles()}},{text:this.$t("Machine.ConfigFilesPanel.Delete"),color:"error",icon:Ue,loadingName:null,onlyWriteable:!0,condition:this.selectedFiles.length>0,click:()=>{this.deleteSelectedDialog=!0}},{text:this.$t("Machine.ConfigFilesPanel.UploadFile"),color:this.machineButtonCol,icon:rv,loadingName:null,onlyWriteable:!0,condition:!0,click:this.uploadFileButton},{text:this.$t("Machine.ConfigFilesPanel.CreateFile"),color:this.machineButtonCol,icon:zw,loadingName:null,onlyWriteable:!0,condition:!0,click:this.createFile},{text:this.$t("Machine.ConfigFilesPanel.CreateDirectory"),color:this.machineButtonCol,icon:Vp,loadingName:null,onlyWriteable:!0,condition:!0,click:this.createDirectory},{text:this.$t("Machine.ConfigFilesPanel.RefreshDirectory"),color:this.machineButtonCol,icon:an,loadingName:null,onlyWriteable:!1,condition:!0,click:this.refreshFileList}].filter(s=>s.condition)}get filteredToolbarButtons(){return this.toolbarButtons.filter(s=>this.directoryPermissions.includes("w")&&s.onlyWriteable||!s.onlyWriteable)}get absolutePath(){let s="/"+this.root;return this.currentPath&&(s+=this.currentPath),s}get directory(){return this.$store.getters["files/getDirectory"](this.absolutePath)}get disk_usage(){var s,e;return(e=(s=this.directory)==null?void 0:s.disk_usage)!=null?e:{used:0,free:0,total:0}}get directoryPermissions(){var s,e;return(e=(s=this.directory)==null?void 0:s.permissions)!=null?e:"r"}get files(){var e,t;let s=[...(t=(e=this.directory)==null?void 0:e.childrens)!=null?t:[]];if(this.showHiddenFiles||(s=s.filter(r=>r.filename.slice(0,1)!==".")),this.hideBackupFiles){const r=/^printer-\d{8}_\d{6}\.cfg$/,i=/^crowsnest\.conf\.\d{4}-\d{2}-\d{2}-\d{4}$/;s=s.filter(n=>!n.filename.match(r)&&!n.filename.match(i)&&!n.filename.endsWith(".bkp"))}return s}get headers(){return[{text:"",value:"",sortable:!1},{text:this.$t("Machine.ConfigFilesPanel.Name"),value:"filename"},{text:this.$t("Machine.ConfigFilesPanel.Filesize"),value:"size",align:"right"},{text:this.$t("Machine.ConfigFilesPanel.LastModified"),value:"modified",align:"right"}]}get selectedFiles(){var s;return(s=this.$store.state.gui.view.configfiles.selectedFiles)!=null?s:[]}set selectedFiles(s){this.$store.dispatch("gui/saveSettingWithoutUpload",{name:"view.configfiles.selectedFiles",value:s})}get countPerPage(){return this.$store.state.gui.view.configfiles.countPerPage}set countPerPage(s){this.$store.dispatch("gui/saveSetting",{name:"view.configfiles.countPerPage",value:s})}get showHiddenFiles(){return this.$store.state.gui.view.configfiles.showHiddenFiles}set showHiddenFiles(s){this.$store.dispatch("gui/saveSetting",{name:"view.configfiles.showHiddenFiles",value:s})}get hideBackupFiles(){return this.$store.state.gui.view.configfiles.hideBackupFiles}set hideBackupFiles(s){this.$store.dispatch("gui/saveSetting",{name:"view.configfiles.hideBackupFiles",value:s})}get sortBy(){return this.$store.state.gui.view.configfiles.sortBy}set sortBy(s){s===void 0&&(s="filename"),this.$store.dispatch("gui/saveSetting",{name:"view.configfiles.sortBy",value:s})}get sortDesc(){return this.$store.state.gui.view.configfiles.sortDesc}set sortDesc(s){s===void 0&&(s=!1),this.$store.dispatch("gui/saveSetting",{name:"view.configfiles.sortDesc",value:s})}get registeredDirectories(){var s;return(s=this.$store.state.server.registered_directories)!=null?s:[]}get existConfigRoot(){return this.registeredDirectories.findIndex(s=>s==="config")!==-1}get showMissingConfigRootWarning(){return this.absolutePath.startsWith("/config")&&!this.absolutePath.startsWith("/config_example")&&!this.existConfigRoot}get registeredDirectoriesSelectItems(){const s=this.registeredDirectories.filter(e=>!aw.includes(e)).sort();return this.existConfigRoot||s.push("config"),s}get root(){return this.$store.state.gui.view.configfiles.rootPath}set root(s){this.$store.dispatch("gui/saveSettingWithoutUpload",{name:"view.configfiles.rootPath",value:s})}get currentPath(){return this.$store.state.gui.view.configfiles.currentPath}set currentPath(s){this.selectedFiles=[],this.$store.dispatch("gui/saveSettingWithoutUpload",{name:"view.configfiles.currentPath",value:s})}refreshFileList(){this.$socket.emit("server.files.get_directory",{path:this.absolutePath.substring(1)},{action:"files/getDirectory"})}changeRoot(){this.currentPath=""}clickRow(s,e=!1){var t,r,i,n;if(!this.contextMenu.shown||e)if(e&&(this.contextMenu.shown=!1),s.isDirectory)this.currentPath+="/"+s.filename,this.currentPage=1;else if(["png","jpeg","jpg","gif","bmp","tif","svg"].includes((r=(t=s.filename.split(".").pop())==null?void 0:t.toLowerCase())!=null?r:"")){const a="".concat(this.apiUrl,"/server/files").concat(this.absolutePath,"/").concat(s.filename,"?t=").concat(Date.now());this.dialogImage.item.name=s.filename,["svg"].includes((n=(i=s.filename.split(".").pop())==null?void 0:i.toLowerCase())!=null?n:"")?fetch(a).then(o=>o.text()).then(o=>{this.dialogImage.show=!0,this.dialogImage.item.svg=o}):(this.dialogImage.show=!0,this.dialogImage.item.url=a)}else this.$store.dispatch("editor/openFile",{root:this.root,path:this.currentPath,filename:s.filename,size:s.size,permissions:s.permissions})}clickRowGoBack(){this.currentPath=this.currentPath.slice(0,this.currentPath.lastIndexOf("/"))}clickPathNavGoToDirectory(s){this.currentPath=s.location}showContextMenu(s,e){this.contextMenu.shown||(s==null||s.preventDefault(),this.contextMenu.shown=!0,this.contextMenu.x=(s==null?void 0:s.clientX)||(s==null?void 0:s.pageX)||window.screenX/2,this.contextMenu.y=(s==null?void 0:s.clientY)||(s==null?void 0:s.pageY)||window.screenY/2,this.contextMenu.item=e,this.$nextTick(()=>{this.contextMenu.shown=!0}))}downloadFile(){const s=this.absolutePath+"/"+this.contextMenu.item.filename,e="".concat(this.apiUrl,"/server/files").concat(Ie(s));window.open(e)}async downloadSelectedFiles(){let s=[];const e=async(u,c)=>{for(const d of c){const m="".concat(u,"/").concat(d.filename);if(d.isDirectory&&d.childrens){await e(m,d.childrens);continue}s.push(m)}};await e(this.absolutePath,this.selectedFiles);const t=new Date,r=(t.getMonth()+1).toString().padStart(2,"0"),i=t.getDate().toString().padStart(2,"0"),n=t.getHours().toString().padStart(2,"0"),a=t.getMinutes().toString().padStart(2,"0"),o=t.getSeconds().toString().padStart(2,"0"),l="".concat(t.getFullYear()).concat(r).concat(i,"-").concat(n).concat(a).concat(o);this.$socket.emit("server.files.zip",{items:s,dest:"config/".concat(this.root,"-").concat(l,".zip")},{action:"files/downloadZip",loading:"configDownloadZip"}),this.selectedFiles=[]}createDirectory(){this.dialogCreateDirectory.name="",this.dialogCreateDirectory.show=!0,setTimeout(()=>{var s;(s=this.$refs.inputDialogCreateDirectoryName)==null||s.focus()},200)}createDirectoryAction(){this.dialogCreateDirectory.show=!1,this.$socket.emit("server.files.post_directory",{path:this.absolutePath.substring(1)+"/"+this.dialogCreateDirectory.name},{action:"files/getCreateDir"})}renameDirectory(s){this.dialogRenameDirectory.item=s,this.dialogRenameDirectory.newName=s.filename,this.dialogRenameDirectory.show=!0,setTimeout(()=>{var e;(e=this.$refs.inputDialogRenameDirectoryName)==null||e.focus()},200)}renameDirectoryAction(){this.dialogRenameDirectory.show=!1,this.$socket.emit("server.files.move",{source:(this.absolutePath+"/"+this.dialogRenameDirectory.item.filename).slice(1),dest:(this.absolutePath+"/"+this.dialogRenameDirectory.newName).slice(1)},{action:"files/getMove"})}deleteDirectory(s){this.dialogDeleteDirectory.item=s,this.dialogDeleteDirectory.show=!0}deleteDirectoryAction(){this.dialogDeleteDirectory.show=!1,this.$socket.emit("server.files.delete_directory",{path:this.absolutePath+"/"+this.dialogDeleteDirectory.item.filename,force:!0},{action:"files/getDeleteDir"})}createFile(){this.dialogCreateFile.name="",this.dialogCreateFile.show=!0,setTimeout(()=>{var s;(s=this.$refs.inputDialogCreateFileName)==null||s.focus()},200)}createFileAction(){const s=new File([""],this.dialogCreateFile.name);let e=new FormData;e.append("file",s),e.append("root",this.root),this.currentPath.length&&e.append("path",this.currentPath.slice(1)),Le.post(this.apiUrl+"/server/files/upload",e,{headers:{"Content-Type":"multipart/form-data"}}).then(()=>{this.$toast.success(this.$t("Files.SuccessfullyCreated",{filename:this.dialogCreateFile.name}).toString()),this.dialogCreateFile.show=!1,this.dialogCreateFile.name=""}).catch(()=>{window.console.error("Error create file: "+this.dialogCreateFile.name)})}renameFile(s){this.dialogRenameFile.item=s,this.dialogRenameFile.newName=s.filename,this.dialogRenameFile.show=!0,setTimeout(()=>{var e;(e=this.$refs.inputDialogRenameFileName)==null||e.focus()},200)}renameFileAction(){this.dialogRenameFile.show=!1,this.$socket.emit("server.files.move",{source:(this.absolutePath+"/"+this.dialogRenameFile.item.filename).slice(1),dest:(this.absolutePath+"/"+this.dialogRenameFile.newName).slice(1)},{action:"files/getMove"})}duplicateFile(s){this.dialogDuplicateFile.item=s,this.dialogDuplicateFile.newName=s.filename,this.dialogDuplicateFile.show=!0,setTimeout(()=>{var e;(e=this.$refs.inputDialogDuplicateFileName)==null||e.focus()},200)}duplicateFileAction(){this.dialogDuplicateFile.show=!1,this.$socket.emit("server.files.copy",{source:(this.absolutePath+"/"+this.dialogDuplicateFile.item.filename).slice(1),dest:(this.absolutePath+"/"+this.dialogDuplicateFile.newName).slice(1)})}removeFile(){this.$socket.emit("server.files.delete_file",{path:this.absolutePath+"/"+this.contextMenu.item.filename},{action:"files/getDeleteFile"}),this.deleteDialog=!1}deleteSelectedFiles(){this.selectedFiles.forEach(s=>{s.isDirectory?this.$socket.emit("server.files.delete_directory",{path:this.absolutePath+"/"+s.filename,force:!0},{action:"files/getDeleteDir"}):this.$socket.emit("server.files.delete_file",{path:this.absolutePath+"/"+s.filename},{action:"files/getDeleteFile"})}),this.selectedFiles=[],this.deleteSelectedDialog=!1}uploadFileButton(){this.$refs.fileUpload.click()}async uploadFile(){var s;if((s=this.$refs.fileUpload.files)!=null&&s.length){const e=[...this.$refs.fileUpload.files];this.$refs.fileUpload.value="",await this.$store.dispatch("socket/addLoading",{name:"configFileUpload"}),await this.$store.dispatch("files/uploadSetCurrentNumber",0),await this.$store.dispatch("files/uploadSetMaxNumber",this.$refs.fileUpload.files.length);for(const t of e){await this.$store.dispatch("files/uploadIncrementCurrentNumber");const r=this.currentPath.slice(0,1)==="/"?this.currentPath.slice(1):this.currentPath,i=await this.$store.dispatch("files/uploadFile",{file:t,path:r,root:"config"});i!==!1&&this.$toast.success(this.$t("Files.SuccessfullyUploaded",{filename:i}).toString())}await this.$store.dispatch("socket/removeLoading",{name:"configFileUpload"})}}cancelUpload(){this.uploadSnackbar.cancelTokenSource.cancel(),this.uploadSnackbar.status=!1}dragFile(s,e){s.preventDefault(),this.blockFileUpload=!0,this.draggingFile.item=e}dragendFile(s){s.preventDefault(),this.blockFileUpload=!1,this.draggingFile.item={isDirectory:!1,filename:"",permissions:"",modified:new Date}}dragOverFilelist(s,e){this.blockFileUpload&&(s.preventDefault(),e.isDirectory&&(s.target.parentElement.style.backgroundColor="#43A04720"))}dragLeaveFilelist(s){this.blockFileUpload&&(s.preventDefault(),s.stopPropagation(),s.target.parentElement.style.backgroundColor="transparent")}async dragDropFilelist(s,e){if(this.blockFileUpload){s.preventDefault(),s.target.parentElement.style.backgroundColor="transparent";let t;e.filename===".."?t=this.absolutePath.slice(1,this.absolutePath.lastIndexOf("/")+1)+this.draggingFile.item.filename:t=this.absolutePath+"/"+e.filename+"/"+this.draggingFile.item.filename,this.$socket.emit("server.files.move",{source:this.absolutePath.slice(1)+"/"+this.draggingFile.item.filename,dest:t},{action:"files/getMove"})}}};sp=JG([S({components:{Panel:U,PathNavigation:hn}})],sp);var KG=function(){var r;var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(U,{attrs:{title:e.$t("Machine.ConfigFilesPanel.ConfigFiles"),"card-class":"machine-configfiles-panel",icon:e.mdiInformation,collapsible:!0}},[t(Z,[t(x,[t(b,{staticClass:"col-12 col-lg pr-lg-0"},[t(ke,{staticClass:"machine-configfiles-panel__root-select",attrs:{items:e.registeredDirectoriesSelectItems,label:e.$t("Machine.ConfigFilesPanel.Root"),outlined:"","hide-details":"",dense:"",attach:".machine-configfiles-panel__root-select"},on:{change:e.changeRoot},model:{value:e.root,callback:function(i){e.root=i},expression:"root"}})],1),t(b,{staticClass:"col col-lg-auto pl-lg-0 text-right"},[t("input",{ref:"fileUpload",staticStyle:{display:"none"},attrs:{type:"file",multiple:""},on:{change:e.uploadFile}}),e._l(e.filteredToolbarButtons,function(i){return t(g,{key:i.loadingName,staticClass:"px-2 minwidth-0 ml-3",attrs:{color:i.color,loading:i.loadingName!==null&&e.loadings.includes(i.loadingName)},on:{click:i.click}},[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:n,attrs:a}){return[t(_,e._g(e._b({},"v-icon",a,!1),n),[e._v(e._s(i.icon))])]}}],null,!0)},[t("span",[e._v(e._s(i.text))])])],1)}),t(ye,{attrs:{"offset-y":"",left:"",title:e.$t("Machine.ConfigFilesPanel.SetupCurrentList")},scopedSlots:e._u([{key:"activator",fn:function({on:i,attrs:n}){return[t(g,e._g(e._b({staticClass:"px-2 minwidth-0 ml-3"},"v-btn",n,!1),i),[t(_,{staticClass:"machine-configfiles-panel__settings-icon"},[e._v(e._s(e.mdiCog))])],1)]}}])},[t(Me,[t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Machine.ConfigFilesPanel.HiddenFiles")},model:{value:e.showHiddenFiles,callback:function(i){e.showHiddenFiles=i},expression:"showHiddenFiles"}})],1),t(J,{staticClass:"minHeight36"},[t(ge,{staticClass:"mt-0",attrs:{"hide-details":"",label:e.$t("Machine.ConfigFilesPanel.HideBackupFiles")},model:{value:e.hideBackupFiles,callback:function(i){e.hideBackupFiles=i},expression:"hideBackupFiles"}})],1)],1)],1)],2)],1)],1),t(Z,[t(x,[t(b,{staticClass:"col-12 py-2 d-flex align-center"},[t("span",[t("b",{staticClass:"mr-1"},[e._v(e._s(e.$t("Machine.ConfigFilesPanel.CurrentPath"))+":")]),t(hn,{attrs:{path:e.currentPath,"base-directory-label":"/".concat(e.root),"on-segment-click":e.clickPathNavGoToDirectory}})],1),t(ae),e.disk_usage!==null&&!e.showMissingConfigRootWarning?[t(de,{attrs:{top:""},scopedSlots:e._u([{key:"activator",fn:function({on:i,attrs:n}){return[t("span",e._g(e._b({},"span",n,!1),i),[t("b",[e._v(e._s(e.$t("Machine.ConfigFilesPanel.FreeDisk"))+":")]),e._v(" "+e._s(e.formatFilesize(e.disk_usage.free))+" ")])]}}],null,!1,3140322967)},[t("span",[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Used"))+": "+e._s(e.formatFilesize(e.disk_usage.used))+" "),t("br"),e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Free"))+": "+e._s(e.formatFilesize(e.disk_usage.free))+" "),t("br"),e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Total"))+": "+e._s(e.formatFilesize(e.disk_usage.total))+" ")])])]:e._e()],2)],1)],1),t(I),e.showMissingConfigRootWarning?t(Z,[t(x,[t(b,{staticClass:"col-12 col-lg pr-lg-0"},[t(it,{staticClass:"mx-auto mt-6",attrs:{dense:"",text:"",type:"warning",elevation:"2","max-width":"500",icon:e.mdiLockOutline}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.ConfigRootDirectoryDoesntExists"))+" ")])],1)],1)],1):t(Qr,{staticClass:"files-table",attrs:{items:e.files,headers:e.headers,page:e.currentPage,"custom-sort":e.sortFiles,"sort-by":e.sortBy,"sort-desc":e.sortDesc,"items-per-page":e.countPerPage,"footer-props":{itemsPerPageText:e.$t("Machine.ConfigFilesPanel.Files"),itemsPerPageAllText:e.$t("Machine.ConfigFilesPanel.AllFiles"),itemsPerPageOptions:[10,25,50,100,-1]},"mobile-breakpoint":"0","item-key":"filename","show-select":""},on:{"update:page":function(i){e.currentPage=i},"update:sortBy":function(i){e.sortBy=i},"update:sort-by":function(i){e.sortBy=i},"update:sortDesc":function(i){e.sortDesc=i},"update:sort-desc":function(i){e.sortDesc=i},"update:itemsPerPage":function(i){e.countPerPage=i},"update:items-per-page":function(i){e.countPerPage=i}},scopedSlots:e._u([{key:"no-data",fn:function(){return[t("div",{staticClass:"text-center"},[e._v(e._s(e.$t("Machine.ConfigFilesPanel.Empty")))])]},proxy:!0},{key:"item",fn:function({index:i,item:n,isSelected:a,select:o}){return[t("tr",{directives:[{name:"longpress",rawName:"v-longpress:600",value:l=>e.showContextMenu(l,n),expression:"(e) => showContextMenu(e, item)",arg:"600"}],key:"".concat(i," ").concat(n.filename),staticClass:"file-list-cursor user-select-none",attrs:{"data-name":n.filename,draggable:"true"},on:{contextmenu:function(l){return e.showContextMenu(l,n)},click:function(l){return e.clickRow(n)},drag:function(l){return e.dragFile(l,n)},dragend:function(l){return e.dragendFile(l)},dragover:function(l){return e.dragOverFilelist(l,n)},dragleave:e.dragLeaveFilelist,drop:function(l){return l.preventDefault(),l.stopPropagation(),e.dragDropFilelist(l,n)}}},[t("td",{staticClass:"file-list__select-td pr-0"},[t(jr,{directives:[{name:"ripple",rawName:"v-ripple"}],staticClass:"pa-0 mr-0",attrs:{value:a},on:{click:function(l){return l.stopPropagation(),o(!a)}}})],1),t("td",{staticClass:"px-0 text-center",staticStyle:{width:"32px"}},[n.isDirectory?t(_,[e._v(e._s(e.mdiFolder))]):e._e(),n.isDirectory?e._e():t(_,[e._v(e._s(e.mdiFile))])],1),t("td",{staticClass:""},[e._v(e._s(n.filename))]),t("td",{staticClass:"text-no-wrap text-right"},[e._v(" "+e._s(n.isDirectory?"--":e.formatFilesize(n.size))+" ")]),t("td",{staticClass:"text-right"},[e._v(e._s(e.formatDateTime(n.modified)))])])]}}],null,!1,1962952882),model:{value:e.selectedFiles,callback:function(i){e.selectedFiles=i},expression:"selectedFiles"}},[e.currentPath!==""?t("template",{slot:"body.prepend"},[t("tr",{staticClass:"file-list-cursor",on:{click:e.clickRowGoBack,dragover:function(i){return e.dragOverFilelist(i,{isDirectory:!0,filename:".."})},dragleave:e.dragLeaveFilelist,drop:function(i){return i.preventDefault(),i.stopPropagation(),e.dragDropFilelist(i,{isDirectory:!0,filename:".."})}}},[t("td",{staticClass:"file-list__select-td pr-0"},[t(jr,{directives:[{name:"ripple",rawName:"v-ripple"}],staticClass:"pa-0 mr-0",attrs:{disabled:""}})],1),t("td",{staticClass:"px-0 text-center",staticStyle:{width:"32px"}},[t(_,[e._v(e._s(e.mdiFolderUpload))])],1),t("td",{staticClass:"",attrs:{colspan:"4"}},[e._v("..")])])]):e._e()],2)],1),t(ye,{attrs:{"position-x":e.contextMenu.x,"position-y":e.contextMenu.y,absolute:"","offset-y":""},model:{value:e.contextMenu.shown,callback:function(i){e.$set(e.contextMenu,"shown",i)},expression:"contextMenu.shown"}},[t(Me,[e.contextMenu.item.isDirectory?e._e():t(J,{on:{click:function(i){return e.clickRow(e.contextMenu.item,!0)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiFileDocumentEditOutline))]),e._v(" "+e._s(e.contextMenu.item.permissions.includes("w")?e.$t("Machine.ConfigFilesPanel.EditFile"):e.$t("Machine.ConfigFilesPanel.ShowFile"))+" ")],1),e.contextMenu.item.isDirectory?e._e():t(J,{on:{click:e.downloadFile}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiCloudDownload))]),e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Download"))+" ")],1),!e.contextMenu.item.isDirectory&&e.contextMenu.item.permissions.includes("w")?t(J,{on:{click:function(i){return e.renameFile(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiRenameBox))]),e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Rename"))+" ")],1):e._e(),e.contextMenu.item.isDirectory?e._e():t(J,{on:{click:function(i){return e.duplicateFile(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiContentCopy))]),e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Duplicate"))+" ")],1),e.contextMenu.item.isDirectory&&e.contextMenu.item.permissions.includes("w")?t(J,{on:{click:function(i){return e.renameDirectory(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1"},[e._v(e._s(e.mdiRenameBox))]),e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Rename"))+" ")],1):e._e(),!e.contextMenu.item.isDirectory&&e.contextMenu.item.permissions.includes("w")?t(J,{staticClass:"red--text",on:{click:function(i){e.deleteDialog=!0}}},[t(_,{staticClass:"mr-1",attrs:{color:"error"}},[e._v(e._s(e.mdiDelete))]),e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Delete"))+" ")],1):e._e(),e.contextMenu.item.isDirectory&&e.contextMenu.item.permissions.includes("w")?t(J,{staticClass:"red--text",on:{click:function(i){return e.deleteDirectory(e.contextMenu.item)}}},[t(_,{staticClass:"mr-1",attrs:{color:"error"}},[e._v(e._s(e.mdiDelete))]),e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Delete"))+" ")],1):e._e()],1)],1),t(le,{staticClass:"fill-height",attrs:{"hide-overlay":"",fullscreen:""},on:{keydown:function(i){if(!i.type.indexOf("key")&&e._k(i.keyCode,"esc",27,i.key,["Esc","Escape"]))return null;e.dialogImage.show=!1,e.dialogImage.item.url=null,e.dialogImage.item.svg=null}},model:{value:e.dialogImage.show,callback:function(i){e.$set(e.dialogImage,"show",i)},expression:"dialogImage.show"}},[t(U,{staticStyle:{position:"relative"},attrs:{title:(r=e.dialogImage.item.name)!=null?r:"","card-class":"maschine-configfiles-imageviewer-dialog"},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(i){e.dialogImage.show=!1,e.dialogImage.item.url=null,e.dialogImage.item.svg=null}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t("div",{staticClass:"d-flex justify-center",staticStyle:{"max-height":"calc(var(--app-height) - 64px)",overflow:"auto"}},[e.dialogImage.item.url?t("img",{staticStyle:{"max-height":"100%",width:"auto","max-width":"100%","object-fit":"contain"},attrs:{src:e.dialogImage.item.url,alt:"image"}}):e.dialogImage.item.svg?t("div",{staticClass:"fill-width",domProps:{innerHTML:e._s(e.dialogImage.item.svg)}}):e._e()])])],1),t(le,{attrs:{"max-width":"400"},model:{value:e.dialogCreateFile.show,callback:function(i){e.$set(e.dialogCreateFile,"show",i)},expression:"dialogCreateFile.show"}},[t(U,{attrs:{title:e.$t("Machine.ConfigFilesPanel.CreateFile"),"card-class":"maschine-configfiles-create-file-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(i){e.dialogCreateFile.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputDialogCreateFileName",attrs:{label:e.$t("Machine.ConfigFilesPanel.Name"),required:"",rules:e.nameInputRules},on:{"update:error":i=>e.isInvalidName=i,keyup:function(i){return!i.type.indexOf("key")&&e._k(i.keyCode,"enter",13,i.key,"Enter")?null:e.createFileAction.apply(null,arguments)}},model:{value:e.dialogCreateFile.name,callback:function(i){e.$set(e.dialogCreateFile,"name",i)},expression:"dialogCreateFile.name"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(i){e.dialogCreateFile.show=!1}}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Cancel"))+" ")]),t(g,{attrs:{disabled:e.isInvalidName,color:"primary",text:""},on:{click:e.createFileAction}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Create"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.dialogRenameFile.show,callback:function(i){e.$set(e.dialogRenameFile,"show",i)},expression:"dialogRenameFile.show"}},[t(U,{attrs:{title:e.$t("Machine.ConfigFilesPanel.RenameFile"),"card-class":"maschine-configfiles-rename-file-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(i){e.dialogRenameFile.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputDialogRenameFileName",attrs:{label:e.$t("Machine.ConfigFilesPanel.Name"),required:"",rules:e.nameInputRules},on:{"update:error":i=>e.isInvalidName=i,keyup:function(i){return!i.type.indexOf("key")&&e._k(i.keyCode,"enter",13,i.key,"Enter")?null:e.renameFileAction.apply(null,arguments)}},model:{value:e.dialogRenameFile.newName,callback:function(i){e.$set(e.dialogRenameFile,"newName",i)},expression:"dialogRenameFile.newName"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(i){e.dialogRenameFile.show=!1}}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Cancel"))+" ")]),t(g,{attrs:{disabled:e.isInvalidName,color:"primary",text:""},on:{click:e.renameFileAction}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Rename"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.dialogDuplicateFile.show,callback:function(i){e.$set(e.dialogDuplicateFile,"show",i)},expression:"dialogDuplicateFile.show"}},[t(U,{attrs:{title:e.$t("Machine.ConfigFilesPanel.DuplicateFile"),"card-class":"maschine-configfiles-duplicate-file-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(i){e.dialogDuplicateFile.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputDialoDuplicateFileName",attrs:{label:e.$t("Machine.ConfigFilesPanel.Name"),required:"",rules:e.nameInputRules},on:{"update:error":i=>e.isInvalidName=i,keyup:function(i){return!i.type.indexOf("key")&&e._k(i.keyCode,"enter",13,i.key,"Enter")?null:e.duplicateFileAction.apply(null,arguments)}},model:{value:e.dialogDuplicateFile.newName,callback:function(i){e.$set(e.dialogDuplicateFile,"newName",i)},expression:"dialogDuplicateFile.newName"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(i){e.dialogDuplicateFile.show=!1}}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Cancel"))+" ")]),t(g,{attrs:{disabled:e.isInvalidName,color:"primary",text:""},on:{click:e.duplicateFileAction}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Duplicate"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.dialogCreateDirectory.show,callback:function(i){e.$set(e.dialogCreateDirectory,"show",i)},expression:"dialogCreateDirectory.show"}},[t(U,{attrs:{title:e.$t("Machine.ConfigFilesPanel.CreateDirectory"),"card-class":"maschine-configfiles-create-directory-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(i){e.dialogCreateDirectory.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputDialogCreateDirectoryName",attrs:{label:e.$t("Machine.ConfigFilesPanel.Name"),required:"",rules:e.nameInputRules},on:{"update:error":i=>e.isInvalidName=i,keyup:function(i){return!i.type.indexOf("key")&&e._k(i.keyCode,"enter",13,i.key,"Enter")?null:e.createDirectoryAction.apply(null,arguments)}},model:{value:e.dialogCreateDirectory.name,callback:function(i){e.$set(e.dialogCreateDirectory,"name",i)},expression:"dialogCreateDirectory.name"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(i){e.dialogCreateDirectory.show=!1}}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Cancel"))+" ")]),t(g,{attrs:{disabled:e.isInvalidName,color:"primary",text:""},on:{click:e.createDirectoryAction}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Create"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.dialogRenameDirectory.show,callback:function(i){e.$set(e.dialogRenameDirectory,"show",i)},expression:"dialogRenameDirectory.show"}},[t(U,{attrs:{title:e.$t("Machine.ConfigFilesPanel.RenameDirectory"),"card-class":"maschine-configfiles-rename-directory-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(i){e.dialogRenameDirectory.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t(se,{ref:"inputDialogRenameDirectoryName",attrs:{label:e.$t("Machine.ConfigFilesPanel.Name"),required:"",rules:e.nameInputRules},on:{"update:error":i=>e.isInvalidName=i,keyup:function(i){return!i.type.indexOf("key")&&e._k(i.keyCode,"enter",13,i.key,"Enter")?null:e.renameDirectoryAction.apply(null,arguments)}},model:{value:e.dialogRenameDirectory.newName,callback:function(i){e.$set(e.dialogRenameDirectory,"newName",i)},expression:"dialogRenameDirectory.newName"}})],1),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(i){e.dialogRenameDirectory.show=!1}}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Cancel"))+" ")]),t(g,{attrs:{disabled:e.isInvalidName,color:"primary",text:""},on:{click:e.renameDirectoryAction}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Rename"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.dialogDeleteDirectory.show,callback:function(i){e.$set(e.dialogDeleteDirectory,"show",i)},expression:"dialogDeleteDirectory.show"}},[t(U,{attrs:{title:e.$t("Machine.ConfigFilesPanel.DeleteDirectory"),"card-class":"maschine-configfiles-delete-directory-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(i){e.dialogDeleteDirectory.show=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t("p",{staticClass:"mb-0"},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.DeleteDirectoryQuestion",{name:e.dialogDeleteDirectory.item.filename}))+" ")])]),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(i){e.dialogDeleteDirectory.show=!1}}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Cancel"))+" ")]),t(g,{attrs:{color:"error",text:""},on:{click:e.deleteDirectoryAction}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Delete"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.deleteDialog,callback:function(i){e.deleteDialog=i},expression:"deleteDialog"}},[t(U,{attrs:{title:e.$t("Machine.ConfigFilesPanel.Delete"),"card-class":"maschine-configfiles-delete-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(i){e.deleteDialog=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[t("p",{staticClass:"mb-0"},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.DeleteSingleFileQuestion",{name:e.contextMenu.item.filename}))+" ")])]),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(i){e.deleteDialog=!1}}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Cancel"))+" ")]),t(g,{attrs:{color:"error",text:""},on:{click:e.removeFile}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Delete"))+" ")])],1)],1)],1),t(le,{attrs:{"max-width":"400"},model:{value:e.deleteSelectedDialog,callback:function(i){e.deleteSelectedDialog=i},expression:"deleteSelectedDialog"}},[t(U,{attrs:{title:e.$t("Machine.ConfigFilesPanel.Delete"),"card-class":"maschine-configfiles-delete-selected-dialog","margin-bottom":!1},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(i){e.deleteSelectedDialog=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[t(Z,[e.selectedFiles.length===1?t("p",{staticClass:"mb-0"},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.DeleteSingleFileQuestion",{name:e.selectedFiles[0].filename}))+" ")]):t("p",{staticClass:"mb-0"},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.DeleteSelectedQuestion",{count:e.selectedFiles.length}))+" ")])]),t(oe,[t(ae),t(g,{attrs:{color:"",text:""},on:{click:function(i){e.deleteSelectedDialog=!1}}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Cancel"))+" ")]),t(g,{attrs:{color:"error",text:""},on:{click:e.deleteSelectedFiles}},[e._v(" "+e._s(e.$t("Machine.ConfigFilesPanel.Delete"))+" ")])],1)],1)],1),t(xi,{attrs:{timeout:-1,value:!0,fixed:"",right:"",bottom:""},scopedSlots:e._u([{key:"action",fn:function({attrs:i}){return[t(g,e._b({staticStyle:{"min-width":"auto"},attrs:{color:"red",text:""},on:{click:e.cancelUpload}},"v-btn",i,!1),[t(_,{staticClass:"0"},[e._v(e._s(e.mdiClose))])],1)]}}]),model:{value:e.uploadSnackbar.status,callback:function(i){e.$set(e.uploadSnackbar,"status",i)},expression:"uploadSnackbar.status"}},[e.uploadSnackbar.max>1?t("span",{staticClass:"mr-1"},[e._v(" ("+e._s(e.uploadSnackbar.number)+"/"+e._s(e.uploadSnackbar.max)+") ")]):e._e(),t("strong",[e._v(e._s(e.$t("Machine.ConfigFilesPanel.Uploading"))+" "+e._s(e.uploadSnackbar.filename))]),t("br"),e._v(" "+e._s(Math.round(e.uploadSnackbar.percent))+" % @ "+e._s(e.formatFilesize(Math.round(e.uploadSnackbar.speed)))+"/s "),t("br"),t(Ss,{staticClass:"mt-2",attrs:{value:e.uploadSnackbar.percent}})],1)],1)},QG=[],eZ=E(sp,KG,QG,!1,null,null);const O2=eZ.exports;var tZ=Object.getOwnPropertyDescriptor,sZ=(s,e,t,r)=>{for(var i=r>1?void 0:r?tZ(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let rp=class extends k(L){};rp=sZ([S({components:{SystemPanel:i2,ConfigFilesPanel:O2,EndstopPanel:Vy,LogfilesPanel:Iy,UpdatePanel:e2,KlippyStatePanel:so}})],rp);var rZ=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(Ee,{attrs:{fluid:"","py-0":"","px-0":""}},[t(x,[t(b,{staticClass:"col-12 col-md-6 pb-0 pb-md-3"},[t(O2)],1),t(b,{staticClass:"col-12 col-md-6 pt-0 pt-md-3"},[t(so),t(i2),t(e2),t(x,[e.klipperState==="ready"?t(b,{staticClass:"col-12 col-sm-6 pb-0 pb-md-3"},[t(Vy)],1):e._e(),t(b,{class:e.klipperState!=="ready"?"col-12":"col-12 col-sm-6 pt-0 pt-sm-3"},[t(Iy)],1)],1)],1)],1)],1)},iZ=[],nZ=E(rp,rZ,iZ,!1,null,null);const aZ=nZ.exports,M2=[{name:"dashboard",title:"Dashboard",path:"/",icon:Gp,component:jR,alwaysShow:!0,showInNavi:!0,position:10},{name:"farm",title:"Printers",path:"/allPrinters",component:aH,alwaysShow:!1,showInNavi:!1},{name:"webcam",title:"Webcam",path:"/cam",icon:on,component:WR,alwaysShow:!0,showInNavi:!0,position:20,fullscreen:!0},{name:"console",title:"Console",path:"/console",icon:Ua,component:mH,alwaysShow:!0,showInNavi:!0,klipperIsConnected:!0,position:30},{name:"heightmap",title:"Heightmap",path:"/heightmap",icon:hu,component:()=>fe(()=>import("./Heightmap-1ReT1M6e.js"),__vite__mapDeps([30,2,3,4,5,6,31])),alwaysShow:!1,showInNavi:!0,klipperComponent:"bed_mesh",position:40},{name:"gcodefiles",title:"G-Code Files",path:"/files",icon:Ga,component:jH,alwaysShow:!0,showInNavi:!0,registeredDirectory:"gcodes",position:50,fullscreen:!0},{name:"gcodeviewer",title:"G-Code Viewer",path:"/viewer",icon:yu,component:()=>fe(()=>import("./Viewer-DVCEMRp5.js").then(s=>s.i),__vite__mapDeps([32,2,3,4,5,1,33])),alwaysShow:!0,showInNavi:!0,position:60,fullscreen:!0},{name:"history",title:"History",path:"/history",icon:nv,component:mN,alwaysShow:!0,showInNavi:!0,moonrakerComponent:"history",position:70},{name:"timelapse",title:"Timelapse",path:"/timelapse",icon:Tv,component:FN,alwaysShow:!0,showInNavi:!0,moonrakerComponent:"timelapse",position:80},{name:"machine",title:"Machine",path:"/config",icon:FS,component:aZ,alwaysShow:!0,showInNavi:!0,position:90},{title:null,component:null,alwaysShow:!1,showInNavi:!1,path:"/settings/machine",redirect:"/config"}];var oZ=Object.defineProperty,lZ=Object.getOwnPropertyDescriptor,k2=(s,e,t,r)=>{for(var i=r>1?void 0:r?lZ(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&oZ(e,t,i),i};let Xi=class extends k(L){constructor(){super(...arguments),this.customNaviLinks=[]}get countPrinters(){return this.$store.getters["farm/countPrinters"]}get routesNaviPoints(){const s=[];return this.countPrinters&&s.push({title:this.$t("App.Printers"),icon:LS,to:"/allPrinters",position:0,visible:!0}),M2.filter(e=>e.showInNavi&&this.showInNavi(e)).forEach(e=>{var i,n;const[t,r]=this.getUiSettings({type:"route",title:(i=e.title)!=null?i:"unknown",visible:!0,position:(n=e.position)!=null?n:999});s.push({type:"route",title:this.$t("Router.".concat(e.title)),orgTitle:e.title,icon:e.icon,to:e.path,position:t,visible:r})}),this.customNaviLinks.length&&this.customNaviLinks.forEach(e=>{var i,n,a;const[t,r]=this.getUiSettings({type:"link",title:(i=e.title)!=null?i:"unknown",visible:(n=e.visible)!=null?n:!0,position:(a=e.position)!=null?a:999});s.push({type:"link",title:e.title,icon:e.icon,href:e.href,target:e.target,position:t,visible:r})}),s}get naviPoints(){return this.routesNaviPoints.sort((s,e)=>s.position-e.position)}get visibleNaviPoints(){return this.naviPoints.filter(s=>s.visible)}get uiSettings(){return this.$store.state.gui.navigation.entries}get klippy_state(){return this.$store.state.server.klippy_state}get boolNaviWebcam(){return this.$store.state.gui.uiSettings.boolWebcamNavi}get moonrakerComponents(){return this.$store.state.server.components}get registeredDirectories(){return this.$store.state.server.registered_directories}get klipperConfigfileSettings(){var s,e;return(e=(s=this.$store.state.printer.configfile)==null?void 0:s.settings)!=null?e:{}}get sidebarNaviFile(){return this.$store.getters["files/getCustomNaviPoints"]}get webcamCount(){return this.$store.getters["gui/webcams/getWebcams"].length}async sidebarNaviFileChanged(s){if(this.customNaviLinks=[],!s)return;(await fetch(s).then(t=>t.json()).catch(t=>{throw window.console.error("Unable to parse .theme/navi.json."),t})).forEach(t=>{var r,i,n,a,o;this.customNaviLinks.push({title:(r=t.title)!=null?r:"Unknown",icon:(i=t.icon)!=null?i:cv,href:(n=t.href)!=null?n:"#",target:(a=t.target)!=null?a:void 0,position:(o=t.position)!=null?o:999})})}showInNavi(s){return["shutdown","error","disconnected"].includes(this.klippy_state)&&!s.alwaysShow||s.title==="Webcam"&&this.webcamCount===0||s.moonrakerComponent&&!this.moonrakerComponents.includes(s.moonrakerComponent)||s.registeredDirectory&&!this.registeredDirectories.includes(s.registeredDirectory)||s.klipperComponent&&!(s.klipperComponent in this.klipperConfigfileSettings)?!1:!(s.klipperIsConnected&&!this.klippyIsConnected)}getUiSettings(s){const e=this.uiSettings.findIndex(t=>t.title===s.title&&t.type===s.type);return e===-1?[s.position,s.visible]:[this.uiSettings[e].position,this.uiSettings[e].visible]}};k2([he("sidebarNaviFile",{immediate:!0})],Xi.prototype,"sidebarNaviFileChanged",1);Xi=k2([S],Xi);var cZ=Object.defineProperty,uZ=Object.getOwnPropertyDescriptor,E2=(s,e,t,r)=>{for(var i=r>1?void 0:r?uZ(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&cZ(e,t,i),i};let Hc=class extends k(Xi,L,vt){constructor(){super(...arguments),this.mdiDragVertical=Wa}get title(){return this.naviPoint.title}get subtitle(){var e;if(this.naviPoint.type==="link")return"URL: ".concat((e=this.naviPoint.href)!=null?e:"Unknown")}get checkboxColor(){return this.naviPoint.visible?"primary":"grey lighten-1"}get checkboxIcon(){return this.naviPoint.visible?Lp:Ep}changeVisibility(){this.$store.dispatch("gui/navigation/changeVisibility",this.naviPoint)}};E2([w({type:Object,required:!0})],Hc.prototype,"naviPoint",2);Hc=E2([S({components:{SettingsRow:j,draggable:si}})],Hc);var dZ=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(x,{staticClass:"my-2 mx-0",style:e.draggableBgStyle},[t(b,{staticClass:"col-auto pr-0 d-flex py-2"},[t(_,{staticClass:"handle"},[e._v(e._s(e.mdiDragVertical))])],1),t(b,{staticClass:"py-2"},[t(j,{attrs:{title:e.title,"sub-title":e.subtitle,"dynamic-slot-width":!0}},[t(_,{attrs:{color:e.checkboxColor},domProps:{innerHTML:e._s(e.checkboxIcon)},on:{click:e.changeVisibility}})],1)],1)],1)},mZ=[],hZ=E(Hc,dZ,mZ,!1,null,null);const L2=hZ.exports;var pZ=Object.getOwnPropertyDescriptor,fZ=(s,e,t,r)=>{for(var i=r>1?void 0:r?pZ(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let ip=class extends k(Xi,L,vt){get sortableNaviPoints(){return this.naviPoints.filter(e=>e.position>0)}set sortableNaviPoints(e){e.forEach((t,r)=>{var i;this.$store.dispatch("gui/navigation/updatePos",{type:t.type,title:(i=t.orgTitle)!=null?i:t.title,visible:t.visible,position:r+1})}),this.$store.dispatch("gui/navigation/upload")}};ip=fZ([S({components:{SettingsNavigationTabItem:L2,SettingsRow:j,draggable:si}})],ip);var gZ=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(Z,[t("h3",{staticClass:"text-h5 mb-3"},[e._v(e._s(e.$t("Settings.NavigationTab.Navigation")))]),t("draggable",{attrs:{handle:".handle","ghost-class":"ghost",group:"navigation-points"},model:{value:e.sortableNaviPoints,callback:function(r){e.sortableNaviPoints=r},expression:"sortableNaviPoints"}},e._l(e.sortableNaviPoints,function(r,i){return t(L2,{key:i,staticClass:"my-2 mx-0",style:e.draggableBgStyle,attrs:{"navi-point":r}})}),1)],1)],1)},_Z=[],vZ=E(ip,gZ,_Z,!1,null,null);const bZ=vZ.exports;var yZ=Object.defineProperty,CZ=Object.getOwnPropertyDescriptor,pd=(s,e,t,r)=>{for(var i=r>1?void 0:r?CZ(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&yZ(e,t,i),i};let Yi=class extends k(L){constructor(){super(...arguments),this.mdiDelete=Ue,this.mdiPencil=bt,this.convertName=Ye,this.boolForm=!1,this.form={id:null,name:"",red:null,green:null,blue:null,white:null},this.rules={required:s=>s!==""||"required",presetUnique:s=>!this.existsPresetName(s)||"Name already exists",min:s=>s>=0||"Must be minimum 0",max:s=>s<=255||"Must be smaller then 256"}}get entry(){var s,e;return this.$store.getters["gui/miscellaneous/getEntry"]({type:(s=this.light)==null?void 0:s.type,name:(e=this.light)==null?void 0:e.name})}get presets(){if(!this.entry)return[];const s=[];return Object.entries(this.entry.presets).forEach(([e,t])=>{s.push({...t,id:e})}),window.console.log("getEntryPresets",s),Ft(s,"name")}get existRed(){var s;return((s=this.light)==null?void 0:s.colorOrder.indexOf("R"))!==-1}get existGreen(){var s;return((s=this.light)==null?void 0:s.colorOrder.indexOf("G"))!==-1}get existBlue(){var s;return((s=this.light)==null?void 0:s.colorOrder.indexOf("B"))!==-1}get existWhite(){var s;return((s=this.light)==null?void 0:s.colorOrder.indexOf("W"))!==-1}get colorRGB(){var s,e,t;return"rgb(".concat(Math.round((s=this.form.red)!=null?s:0),", ").concat(Math.round((e=this.form.green)!=null?e:0),", ").concat(Math.round((t=this.form.blue)!=null?t:0),")")}get colorRGBW(){var s;return"rgba(255, 255, 255, ".concat(((s=this.form.white)!=null?s:0)/255,")")}get redInt(){var s;return Math.round((s=this.form.red)!=null?s:0)}get greenInt(){var s;return Math.round((s=this.form.green)!=null?s:0)}get blueInt(){var s;return Math.round((s=this.form.blue)!=null?s:0)}get whiteInt(){var s;return Math.round((s=this.form.white)!=null?s:0)}get colorPickerOptions(){let s={width:200,margin:15,layout:[]};return this.existRed&&(s==null||s.layout.push({component:Ut.ui.Slider,options:{sliderType:"red"}})),this.existGreen&&(s==null||s.layout.push({component:Ut.ui.Slider,options:{sliderType:"green"}})),this.existBlue&&(s==null||s.layout.push({component:Ut.ui.Slider,options:{sliderType:"blue"}})),this.existRed&&this.existGreen&&this.existBlue&&(s.layout=[{component:Ut.ui.Wheel},{component:Ut.ui.Slider,options:{sliderType:"value"}}]),s}get colorPickerWhiteOptions(){return{width:200,margin:15,layout:[{component:Ut.ui.Slider,options:{sliderType:"alpha"}}]}}entryDescriptionText(s){var t,r,i,n;let e=[];return(t=this.light)!=null&&t.colorOrder.includes("R")&&e.push("R: ".concat(s.red)),(r=this.light)!=null&&r.colorOrder.includes("G")&&e.push("G: ".concat(s.green)),(i=this.light)!=null&&i.colorOrder.includes("B")&&e.push("B: ".concat(s.blue)),(n=this.light)!=null&&n.colorOrder.includes("W")&&e.push("W: ".concat(s.white)),e.join(", ")}createPreset(){var s,e,t,r;this.form.id=null,this.form.name="",this.form.red=((s=this.light)==null?void 0:s.colorOrder.indexOf("R"))!=-1?0:null,this.form.green=((e=this.light)==null?void 0:e.colorOrder.indexOf("G"))!=-1?0:null,this.form.blue=((t=this.light)==null?void 0:t.colorOrder.indexOf("B"))!=-1?0:null,this.form.white=((r=this.light)==null?void 0:r.colorOrder.indexOf("W"))!=-1?0:null,this.boolForm=!0}editPreset(s){var e,t,r,i,n;this.form.id=(e=s.id)!=null?e:null,this.form.name=s.name,this.form.red=((t=this.light)==null?void 0:t.colorOrder.indexOf("R"))!=-1?s.red:null,this.form.green=((r=this.light)==null?void 0:r.colorOrder.indexOf("G"))!=-1?s.green:null,this.form.blue=((i=this.light)==null?void 0:i.colorOrder.indexOf("B"))!=-1?s.blue:null,this.form.white=((n=this.light)==null?void 0:n.colorOrder.indexOf("W"))!=-1?s.white:null,this.boolForm=!0}closeForm(){this.boolForm=!1}storePreset(){this.$store.dispatch("gui/miscellaneous/storePreset",{entry:this.light,preset:this.form}),this.boolForm=!1}updatePreset(){this.$store.dispatch("gui/miscellaneous/updatePreset",{entry:this.light,preset:this.form}),this.boolForm=!1}deletePreset(s){this.$store.dispatch("gui/miscellaneous/deletePreset",{entry:this.light,presetId:s})}existsPresetName(s){return this.presets.findIndex(e=>e.name===s&&e.id!=this.form.id)>=0}onColorRGBChanged(s){const e={red:s.red,green:s.green,blue:s.blue,white:this.form.white};this.colorChanged(e)}onColorWhiteChanged(s){const e={red:this.form.red,green:this.form.green,blue:this.form.blue,white:this.form.white};e.white=s.alpha*255,this.colorChanged(e)}onColorInput(s){const e={red:this.form.red,green:this.form.green,blue:this.form.blue,white:this.form.white};e[s.name]=s.value,this.colorChanged(e)}colorChanged(s){this.form.red=s.red,this.form.green=s.green,this.form.blue=s.blue,this.form.white=s.white}};pd([w({type:Object,default:null})],Yi.prototype,"light",2);pd([Ke({time:250})],Yi.prototype,"onColorRGBChanged",1);pd([Ke({time:250})],Yi.prototype,"onColorWhiteChanged",1);Yi=pd([S({components:{SettingsRow:j}})],Yi);var $Z=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e.boolForm?[t(Z,[t("h3",{staticClass:"text-h5 mb-3"},[e._v(e._s(e.$t("Settings.MiscellaneousTab.CreatePreset")))]),t(j,{attrs:{title:e.$t("Settings.MiscellaneousTab.Name").toString()}},[t(se,{attrs:{"hide-details":"auto",rules:[e.rules.required,e.rules.presetUnique],dense:"",outlined:""},model:{value:e.form.name,callback:function(r){e.$set(e.form,"name",r)},expression:"form.name"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.MiscellaneousTab.Color").toString()}},[t(x,[t(b,{staticClass:"text-center"},[t(_a,{attrs:{color:e.colorRGB,options:e.colorPickerOptions},on:{"update:color":e.onColorRGBChanged}}),e.existWhite?t(_a,{staticClass:"mt-3",attrs:{color:e.colorRGBW,options:e.colorPickerWhiteOptions},on:{"update:color":e.onColorWhiteChanged}}):e._e()],1),t(b,[e.existRed?t(x,[t(b,[t(He,{attrs:{label:e.$t("Panels.MiscellaneousPanel.Light.Red"),param:"red",target:e.redInt,min:0,max:255,dec:1,step:1,"output-error-msg":!0,"has-spinner":!0},on:{submit:e.onColorInput}})],1)],1):e._e(),e.existGreen?t(x,[t(b,[t(He,{attrs:{label:e.$t("Panels.MiscellaneousPanel.Light.Green"),param:"green",target:e.greenInt,min:0,max:255,dec:1,step:1,"has-spinner":!0},on:{submit:e.onColorInput}})],1)],1):e._e(),e.existBlue?t(x,[t(b,[t(He,{attrs:{label:e.$t("Panels.MiscellaneousPanel.Light.Blue"),param:"blue",target:e.blueInt,min:0,max:255,dec:1,step:1,"has-spinner":!0},on:{submit:e.onColorInput}})],1)],1):e._e(),e.existWhite?t(x,[t(b,[t(He,{attrs:{label:e.$t("Panels.MiscellaneousPanel.Light.White"),param:"white",target:e.whiteInt,min:0,max:255,dec:1,step:1,"has-spinner":!0},on:{submit:e.onColorInput}})],1)],1):e._e()],1)],1)],1)],1),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:""},on:{click:e.closeForm}},[e._v(e._s(e.$t("Settings.Cancel")))]),e.form.id!==null?t(g,{attrs:{text:"",color:"primary"},on:{click:e.updatePreset}},[e._v(" "+e._s(e.$t("Settings.Update"))+" ")]):t(g,{attrs:{text:"",color:"primary"},on:{click:e.storePreset}},[e._v(e._s(e.$t("Settings.Store")))])],1)]:[t(Z,[t("h3",{staticClass:"text-h5 mb-3"},[e._v(e._s(e.$t("Settings.MiscellaneousTab.LightPresets",{name:e.light.name})))]),e.light?[e.presets.length?e._l(e.presets,function(r,i){return t("div",{key:r.id},[i?t(I,{staticClass:"my-2"}):e._e(),t(j,{attrs:{title:r.name,"sub-title":e.entryDescriptionText(r),"dynamic-slot-width":!0}},[t(g,{staticClass:"ml-3",attrs:{small:"",outlined:""},on:{click:function(n){return e.editPreset(r)}}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiPencil))]),e._v(" "+e._s(e.$t("Settings.Edit"))+" ")],1),t(g,{staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:"error"},on:{click:function(n){return e.deletePreset(r.id)}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiDelete))])],1)],1)],1)}):[t(x,[t(b,[t("p",{staticClass:"mb-0 text-center font-italic"},[e._v(" "+e._s(e.$t("Settings.MiscellaneousTab.NoPresetFound"))+" ")])])],1)]]:[t(x,[t(b,[t("p",{staticClass:"mb-0 text-center font-italic"},[e._v(" "+e._s(e.$t("Settings.MiscellaneousTab.UnableToLoadPreset"))+" ")])])],1)]],2),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:""},on:{click:function(r){return e.$emit("close")}}},[e._v(e._s(e.$t("Settings.Close")))]),t(g,{attrs:{text:"",color:"primary"},on:{click:e.createPreset}},[e._v(" "+e._s(e.$t("Settings.MiscellaneousTab.AddPreset"))+" ")])],1)]],2)},xZ=[],wZ=E(Yi,$Z,xZ,!1,null,"fb8b76be");const A2=wZ.exports;var SZ=Object.defineProperty,PZ=Object.getOwnPropertyDescriptor,F2=(s,e,t,r)=>{for(var i=r>1?void 0:r?PZ(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&SZ(e,t,i),i};let jc=class extends k(L){constructor(){super(...arguments),this.mdiDelete=Ue,this.mdiPalette=_u,this.mdiPencil=bt,this.convertName=Ye,this.boolForm=!1,this.form={id:null,name:"",start:1,end:1},this.rules={required:s=>s!==""||"required",groupUnique:s=>!this.existsGroupName(s)||"Name already exists",minStart:s=>s>0||"smaller than 1",minEnd:s=>s>=this.form.start||"smaller than start value",max:s=>{var e,t;return s<=((t=(e=this.light)==null?void 0:e.chainCount)!=null?t:1)||"higher than chain_count"}}}get entry(){var s,e;return this.$store.getters["gui/miscellaneous/getEntry"]({type:(s=this.light)==null?void 0:s.type,name:(e=this.light)==null?void 0:e.name})}get groups(){if(!this.entry)return[];const s=[];return Object.entries(this.entry.lightgroups).forEach(([e,t])=>{s.push({name:t.name,start:t.start,end:t.end,id:e})}),window.console.log("getEntryLightgroups",s),Ft(s,"name")}createGroup(){var s,e;this.form.id=null,this.form.name="",this.form.start=1,this.form.end=(e=(s=this.light)==null?void 0:s.chainCount)!=null?e:1,this.boolForm=!0}editGroup(s){var e;this.form.id=(e=s.id)!=null?e:null,this.form.name=s.name,this.form.start=s.start,this.form.end=s.end,this.boolForm=!0}closeForm(){this.boolForm=!1}storeGroup(){this.$store.dispatch("gui/miscellaneous/storeLightgroup",{entry:this.light,lightgroup:this.form}),this.boolForm=!1}updateGroup(){this.$store.dispatch("gui/miscellaneous/updateLightgroup",{entry:this.light,lightgroup:this.form}),this.boolForm=!1}deleteGroup(s){this.$store.dispatch("gui/miscellaneous/deleteLightgroup",{entry:this.light,lightgroupId:s})}existsGroupName(s){return this.groups.findIndex(e=>e.name===s&&e.id!=this.form.id)>=0}};F2([w({type:Object,default:null})],jc.prototype,"light",2);jc=F2([S({components:{SettingsRow:j}})],jc);var DZ=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e.boolForm?[t(Z,[t("h3",{staticClass:"text-h5 mb-3"},[e._v(e._s(e.$t("Settings.MiscellaneousTab.CreateGroup")))]),t(j,{attrs:{title:e.$t("Settings.MiscellaneousTab.Name").toString()}},[t(se,{attrs:{"hide-details":"auto",rules:[e.rules.required,e.rules.groupUnique],dense:"",outlined:""},model:{value:e.form.name,callback:function(r){e.$set(e.form,"name",r)},expression:"form.name"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.MiscellaneousTab.Start").toString(),"sub-title":e.$t("Settings.MiscellaneousTab.StartDescription").toString()}},[t(se,{attrs:{"hide-details":"auto",type:"number",step:"1",rules:[e.rules.minStart,e.rules.max],dense:"",outlined:""},model:{value:e.form.start,callback:function(r){e.$set(e.form,"start",r)},expression:"form.start"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.MiscellaneousTab.End").toString(),"sub-title":e.$t("Settings.MiscellaneousTab.EndDescription").toString()}},[t(se,{attrs:{"hide-details":"auto",type:"number",step:"1",rules:[e.rules.minEnd,e.rules.max],dense:"",outlined:""},model:{value:e.form.end,callback:function(r){e.$set(e.form,"end",r)},expression:"form.end"}})],1)],1),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:""},on:{click:e.closeForm}},[e._v(e._s(e.$t("Settings.Cancel")))]),e.form.id!==null?t(g,{attrs:{text:"",color:"primary"},on:{click:e.updateGroup}},[e._v(" "+e._s(e.$t("Settings.Update"))+" ")]):t(g,{attrs:{text:"",color:"primary"},on:{click:e.storeGroup}},[e._v(e._s(e.$t("Settings.Store")))])],1)]:[t(Z,[t("h3",{staticClass:"text-h5 mb-3"},[e._v(e._s(e.$t("Settings.MiscellaneousTab.LightGroups",{name:e.light.name})))]),e.light?[e.groups.length?e._l(e.groups,function(r,i){return t("div",{key:r.id},[i?t(I,{staticClass:"my-2"}):e._e(),t(j,{attrs:{title:r.name,"sub-title":e.$t("Settings.MiscellaneousTab.GroupSubTitle",{start:r.start,end:r.end}).toString(),"dynamic-slot-width":!0}},[t(g,{staticClass:"ml-3",attrs:{small:"",outlined:""},on:{click:function(n){return e.editGroup(r)}}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiPencil))]),e._v(" "+e._s(e.$t("Settings.Edit"))+" ")],1),t(g,{staticClass:"ml-3 minwidth-0 px-2",attrs:{small:"",outlined:"",color:"error"},on:{click:function(n){return e.deleteGroup(r.id)}}},[t(_,{attrs:{small:""}},[e._v(e._s(e.mdiDelete))])],1)],1)],1)}):[t(x,[t(b,[t("p",{staticClass:"mb-0 text-center font-italic"},[e._v(" "+e._s(e.$t("Settings.MiscellaneousTab.NoGroupFound"))+" ")])])],1)]]:[t(x,[t(b,[t("p",{staticClass:"mb-0 text-center font-italic"},[e._v(" "+e._s(e.$t("Settings.MiscellaneousTab.UnableToLoadLight"))+" ")])])],1)]],2),t(oe,{staticClass:"d-flex justify-end"},[t(g,{attrs:{text:""},on:{click:function(r){return e.$emit("close")}}},[e._v(e._s(e.$t("Settings.Close")))]),t(g,{attrs:{text:"",color:"primary"},on:{click:e.createGroup}},[e._v(" "+e._s(e.$t("Settings.MiscellaneousTab.AddGroup"))+" ")])],1)]],2)},TZ=[],OZ=E(jc,DZ,TZ,!1,null,"c53ad212");const R2=OZ.exports;var MZ=Object.getOwnPropertyDescriptor,kZ=(s,e,t,r)=>{for(var i=r>1?void 0:r?MZ(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let np=class extends k(L){constructor(){super(...arguments),this.mdiDelete=Ue,this.mdiPalette=_u,this.mdiPencil=bt,this.convertName=Ye,this.editLightGroupObject=null,this.editLightPresetObject=null}get lights(){var e;return(e=this.$store.getters["printer/getLights"])!=null?e:[]}get filteredLights(){return this.lights.filter(e=>e.colorOrder.length>1)}};np=kZ([S({components:{SettingsRow:j,SettingsMiscellaneousTabLightGroups:R2,SettingsMiscellaneousTabLightPresets:A2}})],np);var EZ=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[e.editLightGroupObject?t(R2,{attrs:{light:e.editLightGroupObject},on:{close:function(r){e.editLightGroupObject=null}}}):e.editLightPresetObject?t(A2,{attrs:{light:e.editLightPresetObject},on:{close:function(r){e.editLightPresetObject=null}}}):t(Z,[t("h3",{staticClass:"text-h5 mb-3"},[e._v(e._s(e.$t("Settings.MiscellaneousTab.Miscellaneous")))]),e.filteredLights.length?e._l(e.filteredLights,function(r,i){return t("div",{key:i},[i?t(I,{staticClass:"my-2"}):e._e(),t(j,{attrs:{title:e.convertName(r.name),"dynamic-slot-width":!0}},[r.chainCount>1?t(g,{staticClass:"ml-3",attrs:{small:"",outlined:""},on:{click:function(n){e.editLightGroupObject=r}}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiPencil))]),e._v(" "+e._s(e.$t("Settings.MiscellaneousTab.Groups"))+" ")],1):e._e(),t(g,{staticClass:"ml-3",attrs:{small:"",outlined:""},on:{click:function(n){e.editLightPresetObject=r}}},[t(_,{attrs:{left:"",small:""}},[e._v(e._s(e.mdiPalette))]),e._v(" "+e._s(e.$t("Settings.MiscellaneousTab.Presets"))+" ")],1)],1)],1)}):[t(x,[t(b,[t("p",{staticClass:"mb-0 text-center font-italic"},[e._v(e._s(e.$t("Settings.MiscellaneousTab.NoDevicesFound")))])])],1)]],2)],1)},LZ=[],AZ=E(np,EZ,LZ,!1,null,"0d286071");const FZ=AZ.exports;var RZ=Object.defineProperty,HZ=Object.getOwnPropertyDescriptor,H2=(s,e,t,r)=>{for(var i=r>1?void 0:r?HZ(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&RZ(e,t,i),i};let Ic=class extends k(L){constructor(){super(...arguments),this.mdiGrid=hu}get availableOrientations(){return[{text:this.$t("Settings.HeightmapTab.Orientations.RightFront"),value:"rightFront"},{text:this.$t("Settings.HeightmapTab.Orientations.LeftFront"),value:"leftFront"},{text:this.$t("Settings.HeightmapTab.Orientations.Front"),value:"front"},{text:this.$t("Settings.HeightmapTab.Orientations.Top"),value:"top"}]}get defaultOrientation(){return this.$store.state.gui.heightmap.defaultOrientation}set defaultOrientation(e){this.$store.dispatch("gui/heightmap/saveSetting",{name:"defaultOrientation",value:e})}get availableColorSchemes(){return[{text:this.$t("Settings.HeightmapTab.Schemes.Portland")+" "+this.$t("Settings.HeightmapTab.IsDefault"),value:"portland"},{text:this.$t("Settings.HeightmapTab.Schemes.Spring"),value:"spring"},{text:this.$t("Settings.HeightmapTab.Schemes.Hot"),value:"hot"},{text:this.$t("Settings.HeightmapTab.Schemes.Hsv"),value:"hsv"},{text:this.$t("Settings.HeightmapTab.Schemes.GrayScale"),value:"grayScale"}]}get colorScheme(){return this.$store.state.gui.heightmap.activecolorscheme}set colorScheme(e){this.$store.dispatch("gui/heightmap/saveSetting",{name:"activecolorscheme",value:e})}colorSchemeChanged(e){this.colorScheme=e}};H2([he("colorScheme")],Ic.prototype,"colorSchemeChanged",1);Ic=H2([S({components:{Panel:U,SettingsRow:j}})],Ic);var jZ=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(Pe,{attrs:{flat:""}},[t(Z,[t("div",{staticClass:"d-flex align-center"},[t(_,{staticStyle:{opacity:"0.7"}},[e._v(e._s(e.mdiGrid))]),t(gt,{staticClass:"mx-n2"},[e._v(" "+e._s(e.$t("Settings.HeightmapTab.Heightmap"))+" ")]),t(I,{staticClass:"ml-3"})],1),t(j,{attrs:{title:e.$t("Settings.HeightmapTab.DefaultOrientation"),"sub-title":e.$t("Settings.HeightmapTab.DefaultOrientationDescription")}},[t(ke,{attrs:{items:e.availableOrientations,"hide-details":"",outlined:"",dense:""},model:{value:e.defaultOrientation,callback:function(r){e.defaultOrientation=r},expression:"defaultOrientation"}})],1),t(I,{staticClass:"my-2"}),t(j,{attrs:{title:e.$t("Settings.HeightmapTab.ColorSchemes")}},[t(ke,{attrs:{items:e.availableColorSchemes,"hide-details":"",outlined:"",dense:""},model:{value:e.colorScheme,callback:function(r){e.colorScheme=r},expression:"colorScheme"}})],1)],1)],1)],1)},IZ=[],NZ=E(Ic,jZ,IZ,!1,null,null);const VZ=NZ.exports;var BZ=Object.defineProperty,UZ=Object.getOwnPropertyDescriptor,j2=(s,e,t,r)=>{for(var i=r>1?void 0:r?UZ(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&BZ(e,t,i),i};let Nc=class extends k(L){constructor(){super(...arguments),this.showSettings=!1,this.activeTab="general",this.mdiCloseThick=pe,this.mdiCogs=Lw}get tabTitles(){const s=[{icon:ss,name:"general",title:this.$t("Settings.GeneralTab.General")},{icon:_u,name:"ui-settings",title:this.$t("Settings.UiSettingsTab.UiSettings")},{icon:Gp,name:"dashboard",title:this.$t("Settings.DashboardTab.Dashboard")},{icon:on,name:"webcams",title:this.$t("Settings.WebcamsTab.Webcams")},{icon:Qn,name:"macros",title:this.$t("Settings.MacrosTab.Macros")},{icon:kS,name:"control",title:this.$t("Settings.ControlTab.Control")},{icon:Ua,name:"console",title:this.$t("Settings.ConsoleTab.Console")},{icon:sn,name:"presets",title:this.$t("Settings.PresetsTab.PreheatPresets")},{icon:qa,name:"remote-printers",title:this.$t("Settings.RemotePrintersTab.RemotePrinters")},{icon:yu,name:"g-code-viewer",title:this.$t("Settings.GCodeViewerTab.GCodeViewer")},{icon:za,name:"editor",title:this.$t("Settings.EditorTab.Editor")},{icon:Hp,name:"miscellaneous",title:this.$t("Settings.MiscellaneousTab.Miscellaneous")},{icon:tS,name:"navigation",title:this.$t("Settings.NavigationTab.Navigation")},{icon:hu,name:"heightmap",title:this.$t("Settings.HeightmapTab.Heightmap")}];return this.moonrakerComponents.includes("timelapse")&&s.push({icon:Tv,name:"timelapse",title:this.$t("Settings.TimelapseTab.Timelapse")}),s.sort((e,t)=>{if(e.name==="general")return-1;if(t.name==="general")return 1;const r=e.title.toString().toLowerCase(),i=t.title.toString().toLowerCase();return r<i?-1:r>i?1:0})}activeTabWatch(){this.scrollToTop()}scrollToTop(){if(this.$refs.settingsScroll){const s=this.$refs.settingsScroll.osInstance();s==null||s.scroll({y:"0%"})}}};j2([he("activeTab")],Nc.prototype,"activeTabWatch",1);Nc=j2([S({components:{Panel:U,SettingsUiSettingsTab:nM,SettingsRemotePrintersTab:Q4,SettingsPresetsTab:Z4,SettingsConsoleTab:y4,SettingsControlTab:p4,SettingsMacrosTab:a4,SettingsWebcamsTab:KT,SettingsGeneralTab:xT,SettingsDashboardTab:qM,SettingsGCodeViewerTab:e6,SettingsEditorTab:a6,SettingsTimelapseTab:m6,SettingsMiscellaneousTab:FZ,SettingsNavigationTab:bZ,SettingsHeightmapTab:VZ}})],Nc);var WZ=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.showSettings=!0}}},[t(_,[e._v(e._s(e.mdiCogs))])],1),t(le,{attrs:{width:"900",persistent:"",fullscreen:e.isMobile,scrollable:""},on:{keydown:function(r){if(!r.type.indexOf("key")&&e._k(r.keyCode,"esc",27,r.key,["Esc","Escape"]))return null;e.showSettings=!1}},model:{value:e.showSettings,callback:function(r){e.showSettings=r},expression:"showSettings"}},[t(U,{staticStyle:{overflow:"hidden"},attrs:{title:e.$t("Settings.InterfaceSettings"),icon:e.mdiCogs,"card-class":"settings-menu-dialog","margin-bottom":!1,height:e.isMobile?0:548},scopedSlots:e._u([{key:"buttons",fn:function(){return[t(g,{attrs:{icon:"",tile:""},on:{click:function(r){e.showSettings=!1}}},[t(_,[e._v(e._s(e.mdiCloseThick))])],1)]},proxy:!0}])},[e.isMobile?[t(rl,{attrs:{"center-active":!0,"show-arrows":!0},model:{value:e.activeTab,callback:function(r){e.activeTab=r},expression:"activeTab"}},e._l(e.tabTitles,function(r,i){return t(Dr,{key:i,staticClass:"justify-start",attrs:{href:"#"+r.name}},[t(_,{attrs:{left:""},domProps:{innerHTML:e._s(r.icon)}}),e._v(" "+e._s(r.title)+" ")],1)}),1)]:e._e(),t(x,{staticClass:"flex-row flex-nowrap"},[e.isMobile?e._e():t(b,{staticClass:"col-auto pr-0"},[t("overlay-scrollbars",{ref:"settingsTabsScroll",staticClass:"settings-tabs-bar height500"},[t(rl,{attrs:{vertical:!0},model:{value:e.activeTab,callback:function(r){e.activeTab=r},expression:"activeTab"}},e._l(e.tabTitles,function(r,i){return t(Dr,{key:i,staticClass:"justify-start",staticStyle:{width:"200px"},attrs:{href:"#"+r.name}},[t(_,{attrs:{left:""},domProps:{innerHTML:e._s(r.icon)}}),t("span",{staticClass:"text-truncate"},[e._v(e._s(r.title))])],1)}),1)],1)],1),t(b,{class:e.isMobile?"":"pl-0",style:e.isMobile?"":"min-width: 500px;"},[t("overlay-scrollbars",{ref:"settingsScroll",class:"settings-tabs "+(e.isMobile?"":"height500"),attrs:{options:{overflowBehavior:{x:"hidden"}}}},[t("settings-"+e.activeTab+"-tab",{tag:"component",on:{scrollToTop:e.scrollToTop}})],1)],1)],1)],2)],1)],1)},zZ=[],GZ=E(Nc,WZ,zZ,!1,null,"a3a673cb");const I2=GZ.exports;var ZZ=Object.defineProperty,qZ=Object.getOwnPropertyDescriptor,fd=(s,e,t,r)=>{for(var i=r>1?void 0:r?qZ(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&ZZ(e,t,i),i};let Ji=class extends k(L){constructor(){super(...arguments),this.mdiClose=Ba,this.mdiLinkVariant=cv,this.mdiBellOffOutline=vw,this.expand=!1,this.showMaintenanceDetails=!1}get formatedText(){return this.entry.description.replace(/(\bhttps?:\/\/[-A-Z0-9+&@#/%?=~_|!:,.;]*[-A-Z0-9+&@#/%=~_|])/gim,'<a href="$1" target="_blank" class="'+this.alertColor+'--text">$1</a>')}get alertColor(){return this.entry.priority==="critical"?"error":this.entry.priority==="high"?"warning":"info"}get entryType(){const s=this.entry.id.indexOf("/");return s===-1?"":this.entry.id.slice(0,s)}get maintenanceEntry(){if(this.entryType!=="maintenance")return null;const s=this.entry.id.replace("maintenance/","");return this.$store.getters["gui/maintenance/getEntries"].find(t=>t.id===s)}get reminderTimes(){let s=[{text:this.$t("App.Notifications.NextReboot"),clickFunction:()=>this.dismiss("reboot",null)},{text:this.$t("App.Notifications.Never"),clickFunction:()=>this.close()}];return["announcement","maintenance"].includes(this.entryType)&&(s=[],s.push({text:this.$t("App.Notifications.OneHourShort"),clickFunction:()=>this.dismiss("time",60*60)}),s.push({text:this.$t("App.Notifications.OneDayShort"),clickFunction:()=>this.dismiss("time",60*60*24)}),s.push({text:this.$t("App.Notifications.OneWeekShort"),clickFunction:()=>this.dismiss("time",60*60*24*7)})),s}xButtonAction(){if(this.entryType==="announcement")return this.close();this.dismiss("reboot",null)}close(){this.$store.dispatch("gui/notifications/close",{id:this.entry.id})}dismiss(s,e){this.$store.dispatch("gui/notifications/dismiss",{id:this.entry.id,type:s,time:e})}parentStateUpdate(s){s||(this.expand=!1)}};fd([w({required:!0})],Ji.prototype,"entry",2);fd([w({default:!0})],Ji.prototype,"parentState",2);fd([he("parentState")],Ji.prototype,"parentStateUpdate",1);Ji=fd([S({components:{}})],Ji);var XZ=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(it,{class:"notification-menu-entry--priority-".concat(e.entry.priority),attrs:{text:"",color:e.alertColor,border:"left"}},[t(x,{staticClass:"flex-nowrap",attrs:{align:"start"}},[t(b,{staticClass:"grow pb-2"},[t("div",{staticClass:"notification-menu-entry__headline mb-1 text-subtitle-1"},["url"in e.entry?t("a",{class:"text-decoration-none ".concat(e.alertColor,"--text "),attrs:{href:e.entry.url,target:"_blank"}},[t(_,{class:"".concat(e.alertColor,"--text pb-1"),attrs:{small:""}},[e._v(" "+e._s(e.mdiLinkVariant)+" ")]),e._v(" "+e._s(e.entry.title)+" ")],1):t("span",{class:"".concat(e.alertColor,"--text")},[e._v(e._s(e.entry.title))])]),t("p",{staticClass:"notification-menu-entry__description text-body-2 mb-0 text--disabled font-weight-light",domProps:{innerHTML:e._s(e.formatedText)}}),e.entryType==="maintenance"?t(g,{staticClass:"mt-3 mb-0 w-100",attrs:{outlined:"",small:"",color:e.alertColor},on:{click:function(r){e.showMaintenanceDetails=!0}}},[e._v(" "+e._s(e.$t("App.Notifications.ShowDetails"))+" ")]):e._e()],1),e.entry.priority!=="critical"?t(b,{staticClass:"shrink pl-0 pb-1 pt-1 pr-2 d-flex flex-column align-self-stretch justify-space-between"},[e.entryType!=="maintenance"?t(g,{staticClass:"mb-2",attrs:{icon:"",plain:"",color:e.alertColor},on:{click:e.xButtonAction}},[t(_,[e._v(e._s(e.mdiClose))])],1):e._e(),t(ae),t(g,{attrs:{icon:"",plain:"","retain-focus-on-click":"",color:e.alertColor},on:{click:function(r){e.expand=!e.expand}}},[t(_,[e._v(e._s(e.mdiBellOffOutline))])],1)],1):e._e()],1),e.entry.priority!=="critical"?t(x,[t(iu,[t("div",{directives:[{name:"show",rawName:"v-show",value:e.expand,expression:"expand"}],staticClass:"pt-1 w-100"},[t(I,{staticClass:"pb-1 ml-2"}),t("div",{staticClass:"text-right py-1",staticStyle:{"font-size":"0.875rem"}},[t("span",{staticClass:"text--disabled text-caption font-weight-light"},[e._v(" "+e._s(e.$t("App.Notifications.Remind"))+" ")]),e._l(e.reminderTimes,function(r){return t(g,{key:r.text,staticClass:"mx-1",attrs:{color:e.alertColor,"x-small":"",plain:"",text:"",outlined:""},on:{click:r.clickFunction}},[e._v(" "+e._s(r.text)+" ")])})],2)],1)])],1):e._e(),e.entryType==="maintenance"?t(Uf,{attrs:{show:e.showMaintenanceDetails,item:e.maintenanceEntry},on:{close:function(r){e.showMaintenanceDetails=!1}}}):e._e()],1)},YZ=[],JZ=E(Ji,XZ,YZ,!1,null,"bbbb3459");const N2=JZ.exports;var KZ=Object.getOwnPropertyDescriptor,QZ=(s,e,t,r)=>{for(var i=r>1?void 0:r?KZ(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let ap=class extends k(L){constructor(){super(...arguments),this.mdiBell=_w,this.mdiBellOutline=bw,this.mdiCloseBoxMultipleOutline=Mw,this.boolMenu=!1}get notifications(){var s;return(s=this.$store.getters["gui/notifications/getNotifications"])!=null?s:[]}get existsCriticalAnnouncements(){return this.notifications.filter(s=>s.priority==="critical").length>0}get existsHighAnnouncements(){return this.notifications.filter(s=>s.priority==="high").length>0}get countNormalAnnouncements(){return this.notifications.filter(s=>s.priority==="normal").length}get colorBadge(){return this.existsCriticalAnnouncements?"error":this.existsHighAnnouncements?"warning":"primary"}dismissAll(){this.notifications.forEach(async s=>{s.id.startsWith("announcement")&&await this.$store.dispatch("gui/notifications/close",{id:s.id}),await this.$store.dispatch("gui/notifications/dismiss",{id:s.id,type:"reboot",time:null})})}};ap=QZ([S({components:{NotificationMenuEntry:N2}})],ap);var eq=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(ye,{attrs:{bottom:"",left:!e.isMobile,"offset-y":"","close-on-click":!0,"close-on-content-click":!1,origin:"center center",transition:"slide-y-transition","min-width":e.isMobile?"100%":null},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(g,e._g(e._b({staticClass:"minwidth-0",attrs:{icon:"",tile:""}},"v-btn",i,!1),r),[t(O_,{attrs:{content:e.notifications.length<=9?e.notifications.length:"9+",value:e.notifications.length>0,color:e.colorBadge,overlap:""}},[t(_,[e._v(e._s(i["aria-expanded"]==="false"?e.mdiBellOutline:e.mdiBell))])],1)],1)]}}]),model:{value:e.boolMenu,callback:function(r){e.boolMenu=r},expression:"boolMenu"}},[t(Pe,{attrs:{flat:"","min-width":300,"max-width":e.isMobile?null:400}},[e.notifications.length?[t("overlay-scrollbars",{staticClass:"announcement-menu__scrollbar"},[t(Z,[e._l(e.notifications,function(r,i){return[t(N2,{key:r.id,class:i<e.notifications.length-1?"":"mb-0",attrs:{entry:r,"parent-state":e.boolMenu}})]})],2)],1),e.notifications.length>1?[t(I),t(oe,[t(ae),t(g,{staticClass:"mr-2",attrs:{text:"",color:"primary"},on:{click:e.dismissAll}},[t(_,{attrs:{left:""}},[e._v(e._s(e.mdiCloseBoxMultipleOutline))]),e._v(" "+e._s(e.$t("App.Notifications.DismissAll"))+" ")],1)],1)]:e._e()]:t(Z,{staticClass:"text-center"},[t("span",{staticClass:"text-disabled"},[e._v(e._s(e.$t("App.Notifications.NoNotification")))])])],2)],1)},tq=[],sq=E(ap,eq,tq,!1,null,"19169a29");const V2=sq.exports;/*!
|
||
* vue-router v3.6.5
|
||
* (c) 2022 Evan You
|
||
* @license MIT
|
||
*/function ls(s,e){for(var t in e)s[t]=e[t];return s}var rq=/[!'()*]/g,iq=function(s){return"%"+s.charCodeAt(0).toString(16)},nq=/%2C/g,mi=function(s){return encodeURIComponent(s).replace(rq,iq).replace(nq,",")};function op(s){try{return decodeURIComponent(s)}catch{}return s}function aq(s,e,t){e===void 0&&(e={});var r=t||oq,i;try{i=r(s||"")}catch{i={}}for(var n in e){var a=e[n];i[n]=Array.isArray(a)?a.map(X1):X1(a)}return i}var X1=function(s){return s==null||typeof s=="object"?s:String(s)};function oq(s){var e={};return s=s.trim().replace(/^(\?|#|&)/,""),s&&s.split("&").forEach(function(t){var r=t.replace(/\+/g," ").split("="),i=op(r.shift()),n=r.length>0?op(r.join("=")):null;e[i]===void 0?e[i]=n:Array.isArray(e[i])?e[i].push(n):e[i]=[e[i],n]}),e}function lq(s){var e=s?Object.keys(s).map(function(t){var r=s[t];if(r===void 0)return"";if(r===null)return mi(t);if(Array.isArray(r)){var i=[];return r.forEach(function(n){n!==void 0&&(n===null?i.push(mi(t)):i.push(mi(t)+"="+mi(n)))}),i.join("&")}return mi(t)+"="+mi(r)}).filter(function(t){return t.length>0}).join("&"):null;return e?"?"+e:""}var Vc=/\/?$/;function Bc(s,e,t,r){var i=r&&r.options.stringifyQuery,n=e.query||{};try{n=lp(n)}catch{}var a={name:e.name||s&&s.name,meta:s&&s.meta||{},path:e.path||"/",hash:e.hash||"",query:n,params:e.params||{},fullPath:Y1(e,i),matched:s?cq(s):[]};return t&&(a.redirectedFrom=Y1(t,i)),Object.freeze(a)}function lp(s){if(Array.isArray(s))return s.map(lp);if(s&&typeof s=="object"){var e={};for(var t in s)e[t]=lp(s[t]);return e}else return s}var yr=Bc(null,{path:"/"});function cq(s){for(var e=[];s;)e.unshift(s),s=s.parent;return e}function Y1(s,e){var t=s.path,r=s.query;r===void 0&&(r={});var i=s.hash;i===void 0&&(i="");var n=e||lq;return(t||"/")+n(r)+i}function B2(s,e,t){return e===yr?s===e:e?s.path&&e.path?s.path.replace(Vc,"")===e.path.replace(Vc,"")&&(t||s.hash===e.hash&&Xo(s.query,e.query)):s.name&&e.name?s.name===e.name&&(t||s.hash===e.hash&&Xo(s.query,e.query)&&Xo(s.params,e.params)):!1:!1}function Xo(s,e){if(s===void 0&&(s={}),e===void 0&&(e={}),!s||!e)return s===e;var t=Object.keys(s).sort(),r=Object.keys(e).sort();return t.length!==r.length?!1:t.every(function(i,n){var a=s[i],o=r[n];if(o!==i)return!1;var l=e[i];return a==null||l==null?a===l:typeof a=="object"&&typeof l=="object"?Xo(a,l):String(a)===String(l)})}function uq(s,e){return s.path.replace(Vc,"/").indexOf(e.path.replace(Vc,"/"))===0&&(!e.hash||s.hash===e.hash)&&dq(s.query,e.query)}function dq(s,e){for(var t in e)if(!(t in s))return!1;return!0}function U2(s){for(var e=0;e<s.matched.length;e++){var t=s.matched[e];for(var r in t.instances){var i=t.instances[r],n=t.enteredCbs[r];if(!(!i||!n)){delete t.enteredCbs[r];for(var a=0;a<n.length;a++)i._isBeingDestroyed||n[a](i)}}}}var mq={name:"RouterView",functional:!0,props:{name:{type:String,default:"default"}},render:function(e,t){var r=t.props,i=t.children,n=t.parent,a=t.data;a.routerView=!0;for(var o=n.$createElement,l=r.name,u=n.$route,c=n._routerViewCache||(n._routerViewCache={}),d=0,m=!1;n&&n._routerRoot!==n;){var h=n.$vnode?n.$vnode.data:{};h.routerView&&d++,h.keepAlive&&n._directInactive&&n._inactive&&(m=!0),n=n.$parent}if(a.routerViewDepth=d,m){var f=c[l],p=f&&f.component;return p?(f.configProps&&J1(p,a,f.route,f.configProps),o(p,a,i)):o()}var v=u.matched[d],C=v&&v.components[l];if(!v||!C)return c[l]=null,o();c[l]={component:C},a.registerRouteInstance=function(M,F){var O=v.instances[l];(F&&O!==M||!F&&O===M)&&(v.instances[l]=F)},(a.hook||(a.hook={})).prepatch=function(M,F){v.instances[l]=F.componentInstance},a.hook.init=function(M){M.data.keepAlive&&M.componentInstance&&M.componentInstance!==v.instances[l]&&(v.instances[l]=M.componentInstance),U2(u)};var P=v.props&&v.props[l];return P&&(ls(c[l],{route:u,configProps:P}),J1(C,a,u,P)),o(C,a,i)}};function J1(s,e,t,r){var i=e.props=hq(t,r);if(i){i=e.props=ls({},i);var n=e.attrs=e.attrs||{};for(var a in i)(!s.props||!(a in s.props))&&(n[a]=i[a],delete i[a])}}function hq(s,e){switch(typeof e){case"undefined":return;case"object":return e;case"function":return e(s);case"boolean":return e?s.params:void 0}}function W2(s,e,t){var r=s.charAt(0);if(r==="/")return s;if(r==="?"||r==="#")return e+s;var i=e.split("/");(!t||!i[i.length-1])&&i.pop();for(var n=s.replace(/^\//,"").split("/"),a=0;a<n.length;a++){var o=n[a];o===".."?i.pop():o!=="."&&i.push(o)}return i[0]!==""&&i.unshift(""),i.join("/")}function pq(s){var e="",t="",r=s.indexOf("#");r>=0&&(e=s.slice(r),s=s.slice(0,r));var i=s.indexOf("?");return i>=0&&(t=s.slice(i+1),s=s.slice(0,i)),{path:s,query:t,hash:e}}function rr(s){return s.replace(/\/(?:\s*\/)+/g,"/")}var Uc=Array.isArray||function(s){return Object.prototype.toString.call(s)=="[object Array]"},vn=Z2,fq=fg,gq=yq,_q=z2,vq=G2,bq=new RegExp(["(\\\\.)","([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))"].join("|"),"g");function fg(s,e){for(var t=[],r=0,i=0,n="",a=e&&e.delimiter||"/",o;(o=bq.exec(s))!=null;){var l=o[0],u=o[1],c=o.index;if(n+=s.slice(i,c),i=c+l.length,u){n+=u[1];continue}var d=s[i],m=o[2],h=o[3],f=o[4],p=o[5],v=o[6],C=o[7];n&&(t.push(n),n="");var P=m!=null&&d!=null&&d!==m,M=v==="+"||v==="*",F=v==="?"||v==="*",O=o[2]||a,$=f||p;t.push({name:h||r++,prefix:m||"",delimiter:O,optional:F,repeat:M,partial:P,asterisk:!!C,pattern:$?xq($):C?".*":"[^"+Yo(O)+"]+?"})}return i<s.length&&(n+=s.substr(i)),n&&t.push(n),t}function yq(s,e){return z2(fg(s,e),e)}function Cq(s){return encodeURI(s).replace(/[\/?#]/g,function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()})}function $q(s){return encodeURI(s).replace(/[?#]/g,function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()})}function z2(s,e){for(var t=new Array(s.length),r=0;r<s.length;r++)typeof s[r]=="object"&&(t[r]=new RegExp("^(?:"+s[r].pattern+")$",_g(e)));return function(i,n){for(var a="",o=i||{},l=n||{},u=l.pretty?Cq:encodeURIComponent,c=0;c<s.length;c++){var d=s[c];if(typeof d=="string"){a+=d;continue}var m=o[d.name],h;if(m==null)if(d.optional){d.partial&&(a+=d.prefix);continue}else throw new TypeError('Expected "'+d.name+'" to be defined');if(Uc(m)){if(!d.repeat)throw new TypeError('Expected "'+d.name+'" to not repeat, but received `'+JSON.stringify(m)+"`");if(m.length===0){if(d.optional)continue;throw new TypeError('Expected "'+d.name+'" to not be empty')}for(var f=0;f<m.length;f++){if(h=u(m[f]),!t[c].test(h))throw new TypeError('Expected all "'+d.name+'" to match "'+d.pattern+'", but received `'+JSON.stringify(h)+"`");a+=(f===0?d.prefix:d.delimiter)+h}continue}if(h=d.asterisk?$q(m):u(m),!t[c].test(h))throw new TypeError('Expected "'+d.name+'" to match "'+d.pattern+'", but received "'+h+'"');a+=d.prefix+h}return a}}function Yo(s){return s.replace(/([.+*?=^!:${}()[\]|\/\\])/g,"\\$1")}function xq(s){return s.replace(/([=!:$\/()])/g,"\\$1")}function gg(s,e){return s.keys=e,s}function _g(s){return s&&s.sensitive?"":"i"}function wq(s,e){var t=s.source.match(/\((?!\?)/g);if(t)for(var r=0;r<t.length;r++)e.push({name:r,prefix:null,delimiter:null,optional:!1,repeat:!1,partial:!1,asterisk:!1,pattern:null});return gg(s,e)}function Sq(s,e,t){for(var r=[],i=0;i<s.length;i++)r.push(Z2(s[i],e,t).source);var n=new RegExp("(?:"+r.join("|")+")",_g(t));return gg(n,e)}function Pq(s,e,t){return G2(fg(s,t),e,t)}function G2(s,e,t){Uc(e)||(t=e||t,e=[]),t=t||{};for(var r=t.strict,i=t.end!==!1,n="",a=0;a<s.length;a++){var o=s[a];if(typeof o=="string")n+=Yo(o);else{var l=Yo(o.prefix),u="(?:"+o.pattern+")";e.push(o),o.repeat&&(u+="(?:"+l+u+")*"),o.optional?o.partial?u=l+"("+u+")?":u="(?:"+l+"("+u+"))?":u=l+"("+u+")",n+=u}}var c=Yo(t.delimiter||"/"),d=n.slice(-c.length)===c;return r||(n=(d?n.slice(0,-c.length):n)+"(?:"+c+"(?=$))?"),i?n+="$":n+=r&&d?"":"(?="+c+"|$)",gg(new RegExp("^"+n,_g(t)),e)}function Z2(s,e,t){return Uc(e)||(t=e||t,e=[]),t=t||{},s instanceof RegExp?wq(s,e):Uc(s)?Sq(s,e,t):Pq(s,e,t)}vn.parse=fq;vn.compile=gq;vn.tokensToFunction=_q;vn.tokensToRegExp=vq;var K1=Object.create(null);function Jo(s,e,t){e=e||{};try{var r=K1[s]||(K1[s]=vn.compile(s));return typeof e.pathMatch=="string"&&(e[0]=e.pathMatch),r(e,{pretty:!0})}catch{return""}finally{delete e[0]}}function vg(s,e,t,r){var i=typeof s=="string"?{path:s}:s;if(i._normalized)return i;if(i.name){i=ls({},s);var n=i.params;return n&&typeof n=="object"&&(i.params=ls({},n)),i}if(!i.path&&i.params&&e){i=ls({},i),i._normalized=!0;var a=ls(ls({},e.params),i.params);if(e.name)i.name=e.name,i.params=a;else if(e.matched.length){var o=e.matched[e.matched.length-1].path;i.path=Jo(o,a,"path "+e.path)}return i}var l=pq(i.path||""),u=e&&e.path||"/",c=l.path?W2(l.path,u,t||i.append):u,d=aq(l.query,i.query,r&&r.options.parseQuery),m=i.hash||l.hash;return m&&m.charAt(0)!=="#"&&(m="#"+m),{_normalized:!0,path:c,query:d,hash:m}}var Dq=[String,Object],Tq=[String,Array],Q1=function(){},Oq={name:"RouterLink",props:{to:{type:Dq,required:!0},tag:{type:String,default:"a"},custom:Boolean,exact:Boolean,exactPath:Boolean,append:Boolean,replace:Boolean,activeClass:String,exactActiveClass:String,ariaCurrentValue:{type:String,default:"page"},event:{type:Tq,default:"click"}},render:function(e){var t=this,r=this.$router,i=this.$route,n=r.resolve(this.to,i,this.append),a=n.location,o=n.route,l=n.href,u={},c=r.options.linkActiveClass,d=r.options.linkExactActiveClass,m=c==null?"router-link-active":c,h=d==null?"router-link-exact-active":d,f=this.activeClass==null?m:this.activeClass,p=this.exactActiveClass==null?h:this.exactActiveClass,v=o.redirectedFrom?Bc(null,vg(o.redirectedFrom),null,r):o;u[p]=B2(i,v,this.exactPath),u[f]=this.exact||this.exactPath?u[p]:uq(i,v);var C=u[p]?this.ariaCurrentValue:null,P=function(te){e_(te)&&(t.replace?r.replace(a,Q1):r.push(a,Q1))},M={click:e_};Array.isArray(this.event)?this.event.forEach(function(te){M[te]=P}):M[this.event]=P;var F={class:u},O=!this.$scopedSlots.$hasNormal&&this.$scopedSlots.default&&this.$scopedSlots.default({href:l,route:o,navigate:P,isActive:u[f],isExactActive:u[p]});if(O){if(O.length===1)return O[0];if(O.length>1||!O.length)return O.length===0?e():e("span",{},O)}if(this.tag==="a")F.on=M,F.attrs={href:l,"aria-current":C};else{var $=q2(this.$slots.default);if($){$.isStatic=!1;var D=$.data=ls({},$.data);D.on=D.on||{};for(var V in D.on){var N=D.on[V];V in M&&(D.on[V]=Array.isArray(N)?N:[N])}for(var W in M)W in D.on?D.on[W].push(M[W]):D.on[W]=P;var G=$.data.attrs=ls({},$.data.attrs);G.href=l,G["aria-current"]=C}else F.on=M}return e(this.tag,F,this.$slots.default)}};function e_(s){if(!(s.metaKey||s.altKey||s.ctrlKey||s.shiftKey)&&!s.defaultPrevented&&!(s.button!==void 0&&s.button!==0)){if(s.currentTarget&&s.currentTarget.getAttribute){var e=s.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(e))return}return s.preventDefault&&s.preventDefault(),!0}}function q2(s){if(s){for(var e,t=0;t<s.length;t++)if(e=s[t],e.tag==="a"||e.children&&(e=q2(e.children)))return e}}var Wc;function cp(s){if(!(cp.installed&&Wc===s)){cp.installed=!0,Wc=s;var e=function(i){return i!==void 0},t=function(i,n){var a=i.$options._parentVnode;e(a)&&e(a=a.data)&&e(a=a.registerRouteInstance)&&a(i,n)};s.mixin({beforeCreate:function(){e(this.$options.router)?(this._routerRoot=this,this._router=this.$options.router,this._router.init(this),s.util.defineReactive(this,"_route",this._router.history.current)):this._routerRoot=this.$parent&&this.$parent._routerRoot||this,t(this,this)},destroyed:function(){t(this)}}),Object.defineProperty(s.prototype,"$router",{get:function(){return this._routerRoot._router}}),Object.defineProperty(s.prototype,"$route",{get:function(){return this._routerRoot._route}}),s.component("RouterView",mq),s.component("RouterLink",Oq);var r=s.config.optionMergeStrategies;r.beforeRouteEnter=r.beforeRouteLeave=r.beforeRouteUpdate=r.created}}var fo=typeof window<"u";function Ao(s,e,t,r,i){var n=e||[],a=t||Object.create(null),o=r||Object.create(null);s.forEach(function(c){up(n,a,o,c,i)});for(var l=0,u=n.length;l<u;l++)n[l]==="*"&&(n.push(n.splice(l,1)[0]),u--,l--);return{pathList:n,pathMap:a,nameMap:o}}function up(s,e,t,r,i,n){var a=r.path,o=r.name,l=r.pathToRegexpOptions||{},u=kq(a,i,l.strict);typeof r.caseSensitive=="boolean"&&(l.sensitive=r.caseSensitive);var c={path:u,regex:Mq(u,l),components:r.components||{default:r.component},alias:r.alias?typeof r.alias=="string"?[r.alias]:r.alias:[],instances:{},enteredCbs:{},name:o,parent:i,matchAs:n,redirect:r.redirect,beforeEnter:r.beforeEnter,meta:r.meta||{},props:r.props==null?{}:r.components?r.props:{default:r.props}};if(r.children&&r.children.forEach(function(p){var v=n?rr(n+"/"+p.path):void 0;up(s,e,t,p,c,v)}),e[c.path]||(s.push(c.path),e[c.path]=c),r.alias!==void 0)for(var d=Array.isArray(r.alias)?r.alias:[r.alias],m=0;m<d.length;++m){var h=d[m],f={path:h,children:r.children};up(s,e,t,f,i,c.path||"/")}o&&(t[o]||(t[o]=c))}function Mq(s,e){var t=vn(s,[],e);return t}function kq(s,e,t){return t||(s=s.replace(/\/$/,"")),s[0]==="/"||e==null?s:rr(e.path+"/"+s)}function Eq(s,e){var t=Ao(s),r=t.pathList,i=t.pathMap,n=t.nameMap;function a(h){Ao(h,r,i,n)}function o(h,f){var p=typeof h!="object"?n[h]:void 0;Ao([f||h],r,i,n,p),p&&p.alias.length&&Ao(p.alias.map(function(v){return{path:v,children:[f]}}),r,i,n,p)}function l(){return r.map(function(h){return i[h]})}function u(h,f,p){var v=vg(h,f,!1,e),C=v.name;if(C){var P=n[C];if(!P)return m(null,v);var M=P.regex.keys.filter(function(V){return!V.optional}).map(function(V){return V.name});if(typeof v.params!="object"&&(v.params={}),f&&typeof f.params=="object")for(var F in f.params)!(F in v.params)&&M.indexOf(F)>-1&&(v.params[F]=f.params[F]);return v.path=Jo(P.path,v.params),m(P,v,p)}else if(v.path){v.params={};for(var O=0;O<r.length;O++){var $=r[O],D=i[$];if(Lq(D.regex,v.path,v.params))return m(D,v,p)}}return m(null,v)}function c(h,f){var p=h.redirect,v=typeof p=="function"?p(Bc(h,f,null,e)):p;if(typeof v=="string"&&(v={path:v}),!v||typeof v!="object")return m(null,f);var C=v,P=C.name,M=C.path,F=f.query,O=f.hash,$=f.params;if(F=C.hasOwnProperty("query")?C.query:F,O=C.hasOwnProperty("hash")?C.hash:O,$=C.hasOwnProperty("params")?C.params:$,P)return n[P],u({_normalized:!0,name:P,query:F,hash:O,params:$},void 0,f);if(M){var D=Aq(M,h),V=Jo(D,$);return u({_normalized:!0,path:V,query:F,hash:O},void 0,f)}else return m(null,f)}function d(h,f,p){var v=Jo(p,f.params),C=u({_normalized:!0,path:v});if(C){var P=C.matched,M=P[P.length-1];return f.params=C.params,m(M,f)}return m(null,f)}function m(h,f,p){return h&&h.redirect?c(h,p||f):h&&h.matchAs?d(h,f,h.matchAs):Bc(h,f,p,e)}return{match:u,addRoute:o,getRoutes:l,addRoutes:a}}function Lq(s,e,t){var r=e.match(s);if(r){if(!t)return!0}else return!1;for(var i=1,n=r.length;i<n;++i){var a=s.keys[i-1];a&&(t[a.name||"pathMatch"]=typeof r[i]=="string"?op(r[i]):r[i])}return!0}function Aq(s,e){return W2(s,e.parent?e.parent.path:"/",!0)}var Fq=fo&&window.performance&&window.performance.now?window.performance:Date;function X2(){return Fq.now().toFixed(3)}var Y2=X2();function gd(){return Y2}function J2(s){return Y2=s}var K2=Object.create(null);function Q2(){"scrollRestoration"in window.history&&(window.history.scrollRestoration="manual");var s=window.location.protocol+"//"+window.location.host,e=window.location.href.replace(s,""),t=ls({},window.history.state);return t.key=gd(),window.history.replaceState(t,"",e),window.addEventListener("popstate",t_),function(){window.removeEventListener("popstate",t_)}}function ir(s,e,t,r){if(s.app){var i=s.options.scrollBehavior;i&&s.app.$nextTick(function(){var n=Rq(),a=i.call(s,e,t,r?n:null);a&&(typeof a.then=="function"?a.then(function(o){i_(o,n)}).catch(function(o){}):i_(a,n))})}}function eC(){var s=gd();s&&(K2[s]={x:window.pageXOffset,y:window.pageYOffset})}function t_(s){eC(),s.state&&s.state.key&&J2(s.state.key)}function Rq(){var s=gd();if(s)return K2[s]}function Hq(s,e){var t=document.documentElement,r=t.getBoundingClientRect(),i=s.getBoundingClientRect();return{x:i.left-r.left-e.x,y:i.top-r.top-e.y}}function s_(s){return Ki(s.x)||Ki(s.y)}function r_(s){return{x:Ki(s.x)?s.x:window.pageXOffset,y:Ki(s.y)?s.y:window.pageYOffset}}function jq(s){return{x:Ki(s.x)?s.x:0,y:Ki(s.y)?s.y:0}}function Ki(s){return typeof s=="number"}var Iq=/^#\d/;function i_(s,e){var t=typeof s=="object";if(t&&typeof s.selector=="string"){var r=Iq.test(s.selector)?document.getElementById(s.selector.slice(1)):document.querySelector(s.selector);if(r){var i=s.offset&&typeof s.offset=="object"?s.offset:{};i=jq(i),e=Hq(r,i)}else s_(s)&&(e=r_(s))}else t&&s_(s)&&(e=r_(s));e&&("scrollBehavior"in document.documentElement.style?window.scrollTo({left:e.x,top:e.y,behavior:s.behavior}):window.scrollTo(e.x,e.y))}var nr=fo&&function(){var s=window.navigator.userAgent;return(s.indexOf("Android 2.")!==-1||s.indexOf("Android 4.0")!==-1)&&s.indexOf("Mobile Safari")!==-1&&s.indexOf("Chrome")===-1&&s.indexOf("Windows Phone")===-1?!1:window.history&&typeof window.history.pushState=="function"}();function zc(s,e){eC();var t=window.history;try{if(e){var r=ls({},t.state);r.key=gd(),t.replaceState(r,"",s)}else t.pushState({key:J2(X2())},"",s)}catch{window.location[e?"replace":"assign"](s)}}function dp(s){zc(s,!0)}var ni={redirected:2,aborted:4,cancelled:8,duplicated:16};function Nq(s,e){return _d(s,e,ni.redirected,'Redirected when going from "'+s.fullPath+'" to "'+Wq(e)+'" via a navigation guard.')}function Vq(s,e){var t=_d(s,e,ni.duplicated,'Avoided redundant navigation to current location: "'+s.fullPath+'".');return t.name="NavigationDuplicated",t}function n_(s,e){return _d(s,e,ni.cancelled,'Navigation cancelled from "'+s.fullPath+'" to "'+e.fullPath+'" with a new navigation.')}function Bq(s,e){return _d(s,e,ni.aborted,'Navigation aborted from "'+s.fullPath+'" to "'+e.fullPath+'" via a navigation guard.')}function _d(s,e,t,r){var i=new Error(r);return i._isRouter=!0,i.from=s,i.to=e,i.type=t,i}var Uq=["params","query","hash"];function Wq(s){if(typeof s=="string")return s;if("path"in s)return s.path;var e={};return Uq.forEach(function(t){t in s&&(e[t]=s[t])}),JSON.stringify(e,null,2)}function Gc(s){return Object.prototype.toString.call(s).indexOf("Error")>-1}function vd(s,e){return Gc(s)&&s._isRouter&&(e==null||s.type===e)}function a_(s,e,t){var r=function(i){i>=s.length?t():s[i]?e(s[i],function(){r(i+1)}):r(i+1)};r(0)}function zq(s){return function(e,t,r){var i=!1,n=0,a=null;tC(s,function(o,l,u,c){if(typeof o=="function"&&o.cid===void 0){i=!0,n++;var d=o_(function(p){Zq(p)&&(p=p.default),o.resolved=typeof p=="function"?p:Wc.extend(p),u.components[c]=p,n--,n<=0&&r()}),m=o_(function(p){var v="Failed to resolve async component "+c+": "+p;a||(a=Gc(p)?p:new Error(v),r(a))}),h;try{h=o(d,m)}catch(p){m(p)}if(h)if(typeof h.then=="function")h.then(d,m);else{var f=h.component;f&&typeof f.then=="function"&&f.then(d,m)}}}),i||r()}}function tC(s,e){return sC(s.map(function(t){return Object.keys(t.components).map(function(r){return e(t.components[r],t.instances[r],t,r)})}))}function sC(s){return Array.prototype.concat.apply([],s)}var Gq=typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol";function Zq(s){return s.__esModule||Gq&&s[Symbol.toStringTag]==="Module"}function o_(s){var e=!1;return function(){for(var t=[],r=arguments.length;r--;)t[r]=arguments[r];if(!e)return e=!0,s.apply(this,t)}}var _s=function(e,t){this.router=e,this.base=qq(t),this.current=yr,this.pending=null,this.ready=!1,this.readyCbs=[],this.readyErrorCbs=[],this.errorCbs=[],this.listeners=[]};_s.prototype.listen=function(e){this.cb=e};_s.prototype.onReady=function(e,t){this.ready?e():(this.readyCbs.push(e),t&&this.readyErrorCbs.push(t))};_s.prototype.onError=function(e){this.errorCbs.push(e)};_s.prototype.transitionTo=function(e,t,r){var i=this,n;try{n=this.router.match(e,this.current)}catch(o){throw this.errorCbs.forEach(function(l){l(o)}),o}var a=this.current;this.confirmTransition(n,function(){i.updateRoute(n),t&&t(n),i.ensureURL(),i.router.afterHooks.forEach(function(o){o&&o(n,a)}),i.ready||(i.ready=!0,i.readyCbs.forEach(function(o){o(n)}))},function(o){r&&r(o),o&&!i.ready&&(!vd(o,ni.redirected)||a!==yr)&&(i.ready=!0,i.readyErrorCbs.forEach(function(l){l(o)}))})};_s.prototype.confirmTransition=function(e,t,r){var i=this,n=this.current;this.pending=e;var a=function(p){!vd(p)&&Gc(p)&&(i.errorCbs.length?i.errorCbs.forEach(function(v){v(p)}):console.error(p)),r&&r(p)},o=e.matched.length-1,l=n.matched.length-1;if(B2(e,n)&&o===l&&e.matched[o]===n.matched[l])return this.ensureURL(),e.hash&&ir(this.router,n,e,!1),a(Vq(n,e));var u=Xq(this.current.matched,e.matched),c=u.updated,d=u.deactivated,m=u.activated,h=[].concat(Jq(d),this.router.beforeHooks,Kq(c),m.map(function(p){return p.beforeEnter}),zq(m)),f=function(p,v){if(i.pending!==e)return a(n_(n,e));try{p(e,n,function(C){C===!1?(i.ensureURL(!0),a(Bq(n,e))):Gc(C)?(i.ensureURL(!0),a(C)):typeof C=="string"||typeof C=="object"&&(typeof C.path=="string"||typeof C.name=="string")?(a(Nq(n,e)),typeof C=="object"&&C.replace?i.replace(C):i.push(C)):v(C)})}catch(C){a(C)}};a_(h,f,function(){var p=Qq(m),v=p.concat(i.router.resolveHooks);a_(v,f,function(){if(i.pending!==e)return a(n_(n,e));i.pending=null,t(e),i.router.app&&i.router.app.$nextTick(function(){U2(e)})})})};_s.prototype.updateRoute=function(e){this.current=e,this.cb&&this.cb(e)};_s.prototype.setupListeners=function(){};_s.prototype.teardown=function(){this.listeners.forEach(function(e){e()}),this.listeners=[],this.current=yr,this.pending=null};function qq(s){if(!s)if(fo){var e=document.querySelector("base");s=e&&e.getAttribute("href")||"/",s=s.replace(/^https?:\/\/[^\/]+/,"")}else s="/";return s.charAt(0)!=="/"&&(s="/"+s),s.replace(/\/$/,"")}function Xq(s,e){var t,r=Math.max(s.length,e.length);for(t=0;t<r&&s[t]===e[t];t++);return{updated:e.slice(0,t),activated:e.slice(t),deactivated:s.slice(t)}}function bg(s,e,t,r){var i=tC(s,function(n,a,o,l){var u=Yq(n,e);if(u)return Array.isArray(u)?u.map(function(c){return t(c,a,o,l)}):t(u,a,o,l)});return sC(r?i.reverse():i)}function Yq(s,e){return typeof s!="function"&&(s=Wc.extend(s)),s.options[e]}function Jq(s){return bg(s,"beforeRouteLeave",rC,!0)}function Kq(s){return bg(s,"beforeRouteUpdate",rC)}function rC(s,e){if(e)return function(){return s.apply(e,arguments)}}function Qq(s){return bg(s,"beforeRouteEnter",function(e,t,r,i){return eX(e,r,i)})}function eX(s,e,t){return function(i,n,a){return s(i,n,function(o){typeof o=="function"&&(e.enteredCbs[t]||(e.enteredCbs[t]=[]),e.enteredCbs[t].push(o)),a(o)})}}var iC=function(s){function e(t,r){s.call(this,t,r),this._startLocation=In(this.base)}return s&&(e.__proto__=s),e.prototype=Object.create(s&&s.prototype),e.prototype.constructor=e,e.prototype.setupListeners=function(){var r=this;if(!(this.listeners.length>0)){var i=this.router,n=i.options.scrollBehavior,a=nr&&n;a&&this.listeners.push(Q2());var o=function(){var l=r.current,u=In(r.base);r.current===yr&&u===r._startLocation||r.transitionTo(u,function(c){a&&ir(i,c,l,!0)})};window.addEventListener("popstate",o),this.listeners.push(function(){window.removeEventListener("popstate",o)})}},e.prototype.go=function(r){window.history.go(r)},e.prototype.push=function(r,i,n){var a=this,o=this,l=o.current;this.transitionTo(r,function(u){zc(rr(a.base+u.fullPath)),ir(a.router,u,l,!1),i&&i(u)},n)},e.prototype.replace=function(r,i,n){var a=this,o=this,l=o.current;this.transitionTo(r,function(u){dp(rr(a.base+u.fullPath)),ir(a.router,u,l,!1),i&&i(u)},n)},e.prototype.ensureURL=function(r){if(In(this.base)!==this.current.fullPath){var i=rr(this.base+this.current.fullPath);r?zc(i):dp(i)}},e.prototype.getCurrentLocation=function(){return In(this.base)},e}(_s);function In(s){var e=window.location.pathname,t=e.toLowerCase(),r=s.toLowerCase();return s&&(t===r||t.indexOf(rr(r+"/"))===0)&&(e=e.slice(s.length)),(e||"/")+window.location.search+window.location.hash}var nC=function(s){function e(t,r,i){s.call(this,t,r),!(i&&tX(this.base))&&l_()}return s&&(e.__proto__=s),e.prototype=Object.create(s&&s.prototype),e.prototype.constructor=e,e.prototype.setupListeners=function(){var r=this;if(!(this.listeners.length>0)){var i=this.router,n=i.options.scrollBehavior,a=nr&&n;a&&this.listeners.push(Q2());var o=function(){var u=r.current;l_()&&r.transitionTo(Ko(),function(c){a&&ir(r.router,c,u,!0),nr||Qo(c.fullPath)})},l=nr?"popstate":"hashchange";window.addEventListener(l,o),this.listeners.push(function(){window.removeEventListener(l,o)})}},e.prototype.push=function(r,i,n){var a=this,o=this,l=o.current;this.transitionTo(r,function(u){c_(u.fullPath),ir(a.router,u,l,!1),i&&i(u)},n)},e.prototype.replace=function(r,i,n){var a=this,o=this,l=o.current;this.transitionTo(r,function(u){Qo(u.fullPath),ir(a.router,u,l,!1),i&&i(u)},n)},e.prototype.go=function(r){window.history.go(r)},e.prototype.ensureURL=function(r){var i=this.current.fullPath;Ko()!==i&&(r?c_(i):Qo(i))},e.prototype.getCurrentLocation=function(){return Ko()},e}(_s);function tX(s){var e=In(s);if(!/^\/#/.test(e))return window.location.replace(rr(s+"/#"+e)),!0}function l_(){var s=Ko();return s.charAt(0)==="/"?!0:(Qo("/"+s),!1)}function Ko(){var s=window.location.href,e=s.indexOf("#");return e<0?"":(s=s.slice(e+1),s)}function mp(s){var e=window.location.href,t=e.indexOf("#"),r=t>=0?e.slice(0,t):e;return r+"#"+s}function c_(s){nr?zc(mp(s)):window.location.hash=s}function Qo(s){nr?dp(mp(s)):window.location.replace(mp(s))}var sX=function(s){function e(t,r){s.call(this,t,r),this.stack=[],this.index=-1}return s&&(e.__proto__=s),e.prototype=Object.create(s&&s.prototype),e.prototype.constructor=e,e.prototype.push=function(r,i,n){var a=this;this.transitionTo(r,function(o){a.stack=a.stack.slice(0,a.index+1).concat(o),a.index++,i&&i(o)},n)},e.prototype.replace=function(r,i,n){var a=this;this.transitionTo(r,function(o){a.stack=a.stack.slice(0,a.index).concat(o),i&&i(o)},n)},e.prototype.go=function(r){var i=this,n=this.index+r;if(!(n<0||n>=this.stack.length)){var a=this.stack[n];this.confirmTransition(a,function(){var o=i.current;i.index=n,i.updateRoute(a),i.router.afterHooks.forEach(function(l){l&&l(a,o)})},function(o){vd(o,ni.duplicated)&&(i.index=n)})}},e.prototype.getCurrentLocation=function(){var r=this.stack[this.stack.length-1];return r?r.fullPath:"/"},e.prototype.ensureURL=function(){},e}(_s),je=function(e){e===void 0&&(e={}),this.app=null,this.apps=[],this.options=e,this.beforeHooks=[],this.resolveHooks=[],this.afterHooks=[],this.matcher=Eq(e.routes||[],this);var t=e.mode||"hash";switch(this.fallback=t==="history"&&!nr&&e.fallback!==!1,this.fallback&&(t="hash"),fo||(t="abstract"),this.mode=t,t){case"history":this.history=new iC(this,e.base);break;case"hash":this.history=new nC(this,e.base,this.fallback);break;case"abstract":this.history=new sX(this,e.base);break}},aC={currentRoute:{configurable:!0}};je.prototype.match=function(e,t,r){return this.matcher.match(e,t,r)};aC.currentRoute.get=function(){return this.history&&this.history.current};je.prototype.init=function(e){var t=this;if(this.apps.push(e),e.$once("hook:destroyed",function(){var a=t.apps.indexOf(e);a>-1&&t.apps.splice(a,1),t.app===e&&(t.app=t.apps[0]||null),t.app||t.history.teardown()}),!this.app){this.app=e;var r=this.history;if(r instanceof iC||r instanceof nC){var i=function(a){var o=r.current,l=t.options.scrollBehavior,u=nr&&l;u&&"fullPath"in a&&ir(t,a,o,!1)},n=function(a){r.setupListeners(),i(a)};r.transitionTo(r.getCurrentLocation(),n,n)}r.listen(function(a){t.apps.forEach(function(o){o._route=a})})}};je.prototype.beforeEach=function(e){return yg(this.beforeHooks,e)};je.prototype.beforeResolve=function(e){return yg(this.resolveHooks,e)};je.prototype.afterEach=function(e){return yg(this.afterHooks,e)};je.prototype.onReady=function(e,t){this.history.onReady(e,t)};je.prototype.onError=function(e){this.history.onError(e)};je.prototype.push=function(e,t,r){var i=this;if(!t&&!r&&typeof Promise<"u")return new Promise(function(n,a){i.history.push(e,n,a)});this.history.push(e,t,r)};je.prototype.replace=function(e,t,r){var i=this;if(!t&&!r&&typeof Promise<"u")return new Promise(function(n,a){i.history.replace(e,n,a)});this.history.replace(e,t,r)};je.prototype.go=function(e){this.history.go(e)};je.prototype.back=function(){this.go(-1)};je.prototype.forward=function(){this.go(1)};je.prototype.getMatchedComponents=function(e){var t=e?e.matched?e:this.resolve(e).route:this.currentRoute;return t?[].concat.apply([],t.matched.map(function(r){return Object.keys(r.components).map(function(i){return r.components[i]})})):[]};je.prototype.resolve=function(e,t,r){t=t||this.history.current;var i=vg(e,t,r,this),n=this.match(i,t),a=n.redirectedFrom||n.fullPath,o=this.history.base,l=rX(o,a,this.mode);return{location:i,route:n,href:l,normalizedTo:i,resolved:n}};je.prototype.getRoutes=function(){return this.matcher.getRoutes()};je.prototype.addRoute=function(e,t){this.matcher.addRoute(e,t),this.history.current!==yr&&this.history.transitionTo(this.history.getCurrentLocation())};je.prototype.addRoutes=function(e){this.matcher.addRoutes(e),this.history.current!==yr&&this.history.transitionTo(this.history.getCurrentLocation())};Object.defineProperties(je.prototype,aC);var oC=je;function yg(s,e){return s.push(e),function(){var t=s.indexOf(e);t>-1&&s.splice(t,1)}}function rX(s,e,t){var r=t==="hash"?"#"+e:e;return s?rr(s+"/"+r):r}je.install=cp;je.version="3.6.5";je.isNavigationFailure=vd;je.NavigationFailureType=ni;je.START_LOCATION=yr;fo&&window.Vue&&window.Vue.use(je);y.use(oC);const Ia=new oC({base:"/",mode:"history",routes:M2});var iX=Object.getOwnPropertyDescriptor,nX=(s,e,t,r)=>{for(var i=r>1?void 0:r?iX(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let hp=class extends k(L){constructor(){super(...arguments),this.mdiChevronDown=fr}get displayMenuPoint(){return this.instancesDB!=="moonraker"&&this.countPrinters>1||this.instancesDB==="moonraker"&&this.countPrinters}get printers(){return this.$store.getters["farm/getPrinters"]}get countPrinters(){return this.$store.getters["farm/countPrinters"]}get currentPage(){return this.$route.fullPath}switchToPrinters(){Ia.push("/allPrinters")}getPrinterName(s){return this.$store.getters["farm/"+s+"/getPrinterName"]}getPrinterDescription(s){return this.$store.getters["farm/"+s._namespace+"/getStatus"]}changePrinter(s){s.socket.isConnected&&this.$store.dispatch("changePrinter",{printer:s._namespace})}};hp=nX([S],hp);var aX=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(ye,{attrs:{bottom:"","offset-x":!0},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(_,e._g(e._b({staticClass:"nav-arrow right"},"v-icon",i,!1),r),[e._v(e._s(e.mdiChevronDown))])]}}])},[t(Me,{attrs:{dense:""}},e._l(e.printers,function(r){return t(J,{key:r._namespace,attrs:{"two-line":"",disabled:!r.socket.isConnected,link:""},on:{click:function(i){return e.changePrinter(r)}}},[t(_t,[t(Ze,[e._v(e._s(e.getPrinterName(r._namespace)))]),t(Va,[e._v(e._s(e.getPrinterDescription(r)))])],1)],1)}),1)],1)},oX=[],lX=E(hp,aX,oX,!1,null,"e755d818");const lC=lX.exports,Tn={};function cX(s){return Object.keys(s).reduce((e,t)=>(s[t]!==!1&&s[t]!==null&&s[t]!==void 0&&(e[t]=s[t]),e),{})}const uX={name:"InlineSvg",inheritAttrs:!1,render(s){return this.svgElSource?s("svg",{on:this.$listeners,attrs:Object.assign(this.getSvgAttrs(this.svgElSource),cX(this.$attrs)),domProps:{innerHTML:this.getSvgContent(this.svgElSource)}}):null},props:{src:{type:String,required:!0},title:{type:String},transformSource:{type:Function,default:s=>s},keepDuringLoading:{type:Boolean,default:!0}},data(){return{svgElSource:null}},watch:{src(s){this.getSource(s)}},mounted(){this.getSource(this.src)},methods:{getSvgAttrs(s){let e={};const t=s.attributes;if(!t)return e;for(let r=t.length-1;r>=0;r--)e[t[r].name]=t[r].value;return e},getSvgContent(s){return s=s.cloneNode(!0),s=this.transformSource(s),this.title&&dX(s,this.title),s.innerHTML},getSource(s){Tn[s]||(Tn[s]=this.download(s)),this.svgElSource&&Tn[s].getIsPending()&&!this.keepDuringLoading&&(this.svgElSource=null,this.$emit("unloaded")),Tn[s].then(e=>{this.svgElSource=e,this.$nextTick(()=>{this.$emit("loaded",this.$el)})}).catch(e=>{this.svgElSource&&(this.svgElSource=null,this.$emit("unloaded")),delete Tn[s],this.$emit("error",e)})},download(s){return mX(new Promise((e,t)=>{const r=new XMLHttpRequest;r.open("GET",s,!0),r.onload=()=>{if(r.status>=200&&r.status<400)try{let a=new DOMParser().parseFromString(r.responseText,"text/xml").getElementsByTagName("svg")[0];a?e(a):t(new Error('Loaded file is not valid SVG"'))}catch(i){t(i)}else t(new Error("Error loading SVG"))},r.onerror=t,r.send()}))}}};function dX(s,e){const t=s.getElementsByTagName("title");if(t.length)t[0].textContent=e;else{const r=document.createElementNS("http://www.w3.org/2000/svg","title");r.textContent=e,s.insertBefore(r,s.firstChild)}}function mX(s){if(s.getIsPending)return s;let e=!0,t=s.then(r=>(e=!1,r),r=>{throw e=!1,r});return t.getIsPending=function(){return e},t}var hX=Object.getOwnPropertyDescriptor,pX=(s,e,t,r)=>{for(var i=r>1?void 0:r?hX(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let pp=class extends k(L,vt){constructor(){super(...arguments),this.mdiAlertOctagonOutline=W_,this.mdiContentSave=Rp,this.mdiFileUpload=rv,this.mdiClose=Ba,this.mdiCloseThick=pe,this.topbarHeight=Vn,this.showEmergencyStopDialog=!1,this.uploadSnackbar={status:!1,filename:"",percent:0,speed:0,total:0,cancelTokenSource:null},this.formatFilesize=Xe}get gcodeInputFileAccept(){return this.isIOS?[]:Pi}get naviDrawer(){return this.$store.state.naviDrawer}set naviDrawer(s){this.$store.dispatch("setNaviDrawer",s)}get currentPage(){return this.$route.fullPath}get saveConfigPending(){var s,e;return(e=(s=this.$store.state.printer.configfile)==null?void 0:s.save_config_pending)!=null?e:!1}get hideSaveConfigForBedMash(){var s;return(s=this.$store.state.gui.uiSettings.hideSaveConfigForBedMash)!=null?s:!1}get showSaveConfigButton(){var e,t;if(!this.klipperReadyForGui)return!1;if(!this.hideSaveConfigForBedMash)return this.saveConfigPending;let s=Object.keys((t=(e=this.$store.state.printer.configfile)==null?void 0:e.save_config_pending_items)!=null?t:{});return s=s.filter(r=>!r.startsWith("bed_mesh ")),s.length>0}get printerName(){return this.$store.state.gui.general.printername.length?this.$store.state.gui.general.printername:this.$store.state.printer.hostname}get countPrinters(){return this.$store.getters["farm/countPrinters"]}get boolHideUploadAndPrintButton(){var s;return(s=this.$store.state.gui.uiSettings.boolHideUploadAndPrintButton)!=null?s:!1}get isSvgLogo(){return this.sidebarLogo.includes(".svg?timestamp=")||this.sidebarLogo.endsWith(".svg")}get logoColor(){return this.$store.state.gui.uiSettings.logo}get logoClasses(){return["nav-logo","ml-2","mr-1","d-none","d-sm-flex"]}get boolShowUploadAndPrint(){return this.klippyIsConnected&&this.existGcodesRootDirectory&&["standby","complete","cancelled"].includes(this.printer_state)&&!this.boolHideUploadAndPrintButton}get defaultNavigationStateSetting(){var s,e,t;return(t=(e=(s=this.$store.state.gui)==null?void 0:s.uiSettings)==null?void 0:e.defaultNavigationStateSetting)!=null?t:"alwaysOpen"}mounted(){var s;switch(this.defaultNavigationStateSetting){case"alwaysClosed":this.naviDrawer=!1;break;case"lastState":this.naviDrawer=((s=localStorage.getItem("naviDrawer"))!=null?s:"true")==="true";break;default:this.naviDrawer=this.$vuetify.breakpoint.lgAndUp}}btnEmergencyStop(){if(this.$store.state.gui.uiSettings.confirmOnEmergencyStop){this.showEmergencyStopDialog=!0;return}this.emergencyStop()}emergencyStop(){this.showEmergencyStopDialog=!1,this.$socket.emit("printer.emergency_stop",{},{loading:"topbarEmergencyStop"})}saveConfig(){this.$store.dispatch("server/addEvent",{message:"SAVE_CONFIG",type:"command"}),this.$socket.emit("printer.gcode.script",{script:"SAVE_CONFIG"},{loading:"topbarSaveConfig"})}btnUploadAndStart(){this.$refs.fileUploadAndStart.click()}async uploadAndStart(){var s,e;if((s=this.$refs.fileUploadAndStart)!=null&&s.files.length){await this.$store.dispatch("socket/addLoading",{name:"btnUploadAndStart"});let t=[];for(const r of((e=this.$refs.fileUploadAndStart)==null?void 0:e.files)||[]){const i=await this.doUploadAndStart(r);t.push(i)}await this.$store.dispatch("socket/removeLoading",{name:"btnUploadAndStart"});for(const r of t){const i=this.$t("App.TopBar.UploadOfFileSuccessful",{file:r}).toString();this.$toast.success(i)}this.$refs.fileUploadAndStart.value="",this.currentPage!=="/"&&await this.$router.push("/")}}doUploadAndStart(s){const e=new FormData,t=s.name;return this.uploadSnackbar.filename=t,this.uploadSnackbar.status=!0,this.uploadSnackbar.percent=0,this.uploadSnackbar.speed=0,e.append("file",s,t),e.append("print","true"),new Promise(r=>{this.uploadSnackbar.cancelTokenSource=Le.CancelToken.source(),Le.post(this.apiUrl+"/server/files/upload",e,{cancelToken:this.uploadSnackbar.cancelTokenSource.token,headers:{"Content-Type":"multipart/form-data"},onUploadProgress:i=>{var n,a,o;this.uploadSnackbar.percent=((n=i.progress)!=null?n:0)*100,this.uploadSnackbar.speed=(a=i.rate)!=null?a:0,this.uploadSnackbar.total=(o=i.total)!=null?o:0}}).then(i=>{this.uploadSnackbar.status=!1,r(i.data.result)}).catch(()=>{this.uploadSnackbar.status=!1,this.$store.dispatch("socket/removeLoading",{name:"btnUploadAndStart"});const i=this.$t("App.TopBar.CannotUploadTheFile").toString();this.$toast.error(i)})})}cancelUpload(){this.uploadSnackbar.cancelTokenSource.cancel(),this.uploadSnackbar.status=!1}};pp=pX([S({components:{EmergencyStopDialog:pb,InlineSvg:uX,Panel:U,TheSettingsMenu:I2,TheTopCornerMenu:_b,PrinterSelector:lC,MainsailLogo:mn,TheNotificationMenu:V2}})],pp);var fX=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(L$,{staticClass:"topbar pa-0",attrs:{app:"","elevate-on-scroll":"",height:e.topbarHeight,"clipped-left":""}},[t(A$,{attrs:{tile:""},on:{click:function(r){r.stopPropagation(),e.naviDrawer=!e.naviDrawer}}}),t("router-link",{attrs:{to:"/"}},[e.sidebarLogo&&e.isSvgLogo?t("inline-svg",{class:e.logoClasses,attrs:{src:e.sidebarLogo}}):e.sidebarLogo?t("img",{class:e.logoClasses,attrs:{src:e.sidebarLogo,alt:"Logo"}}):t(mn,{class:e.logoClasses,attrs:{color:e.logoColor,router:"",to:"/",ripple:!1}})],1),t(ru,{staticClass:"text-no-wrap ml-0 pl-2 mr-2"},[e._v(e._s(e.printerName))]),e.countPrinters?t(lC):e._e(),t(ae),t("input",{ref:"fileUploadAndStart",staticStyle:{display:"none"},attrs:{type:"file",accept:e.gcodeInputFileAccept.join(", ")},on:{change:e.uploadAndStart}}),e.showSaveConfigButton?t(g,{staticClass:"button-min-width-auto px-3 d-none d-sm-flex save-config-button",attrs:{tile:"",icon:e.$vuetify.breakpoint.smAndDown,text:e.$vuetify.breakpoint.mdAndUp,color:"primary",disabled:e.printerIsPrinting,loading:e.loadings.includes("topbarSaveConfig")},on:{click:e.saveConfig}},[t(_,{staticClass:"d-md-none"},[e._v(e._s(e.mdiContentSave))]),t("span",{staticClass:"d-none d-md-inline"},[e._v(e._s(e.$t("App.TopBar.SAVE_CONFIG")))])],1):e._e(),e.boolShowUploadAndPrint?t(g,{staticClass:"button-min-width-auto px-3 d-none d-sm-flex upload-and-start-button",attrs:{tile:"",icon:e.$vuetify.breakpoint.smAndDown,text:e.$vuetify.breakpoint.mdAndUp,color:"primary",loading:e.loadings.includes("btnUploadAndStart")},on:{click:e.btnUploadAndStart}},[t(_,{staticClass:"mr-md-2"},[e._v(e._s(e.mdiFileUpload))]),t("span",{staticClass:"d-none d-md-inline"},[e._v(e._s(e.$t("App.TopBar.UploadPrint")))])],1):e._e(),e.klippyIsConnected?t(g,{staticClass:"button-min-width-auto px-3 emergency-button",attrs:{tile:"",icon:e.$vuetify.breakpoint.smAndDown,text:e.$vuetify.breakpoint.mdAndUp,color:"error",loading:e.loadings.includes("topbarEmergencyStop")},on:{click:e.btnEmergencyStop}},[t(_,{staticClass:"mr-md-2"},[e._v(e._s(e.mdiAlertOctagonOutline))]),t("span",{staticClass:"d-none d-md-inline"},[e._v(e._s(e.$t("App.TopBar.EmergencyStop")))])],1):e._e(),t(V2),t(I2),t(_b)],1),t(xi,{attrs:{timeout:-1,fixed:"",right:"",bottom:""},scopedSlots:e._u([{key:"action",fn:function({attrs:r}){return[t(g,e._b({staticStyle:{"min-width":"auto"},attrs:{color:"red",text:""},on:{click:e.cancelUpload}},"v-btn",r,!1),[t(_,{staticClass:"0"},[e._v(e._s(e.mdiClose))])],1)]}}]),model:{value:e.uploadSnackbar.status,callback:function(r){e.$set(e.uploadSnackbar,"status",r)},expression:"uploadSnackbar.status"}},[t("strong",[e._v(e._s(e.$t("App.TopBar.Uploading"))+" "+e._s(e.uploadSnackbar.filename))]),t("br"),e._v(" "+e._s(Math.round(e.uploadSnackbar.percent))+" % @ "+e._s(e.formatFilesize(Math.round(e.uploadSnackbar.speed)))+"/s "),t("br"),t(Ss,{staticClass:"mt-2",attrs:{value:e.uploadSnackbar.percent}})],1),t(pb,{attrs:{"show-dialog":e.showEmergencyStopDialog},on:{close:function(r){e.showEmergencyStopDialog=!1}}})],1)},gX=[],_X=E(pp,fX,gX,!1,null,"40a2ce29");const cC=_X.exports;var vX=Object.defineProperty,bX=Object.getOwnPropertyDescriptor,uC=(s,e,t,r)=>{for(var i=r>1?void 0:r?bX(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&vX(e,t,i),i};let Zc=class extends k(L){get navigationStyle(){return this.$store.state.gui.uiSettings.navigationStyle}get icon(){return this.item.icon}get title(){return this.item.title}get to(){var s;return(s=this.item.to)!=null?s:void 0}get href(){var s;return(s=this.item.href)!=null?s:void 0}get target(){var s;return(s=this.item.target)!=null?s:void 0}get borderBottom(){return this.item.to==="/allPrinters"}};uC([w({type:Object,required:!0})],Zc.prototype,"item",2);Zc=uC([S],Zc);var yX=function(){var e=this,t=e._self._c;return e._self._setupProxy,t("div",[t(de,{attrs:{right:"","open-delay":500,disabled:e.navigationStyle!=="iconsOnly"},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(J,e._g(e._b({staticClass:"small-list-item",attrs:{router:"",to:e.to,href:e.href,target:e.target}},"v-list-item",i,!1),r),[t(Hs,{staticClass:"my-3 mr-3 menu-item-icon"},[t(_,[e._v(e._s(e.icon))])],1),t(_t,[t(Ze,{staticClass:"menu-item-title",attrs:{tile:""}},[e._v(" "+e._s(e.title)+" ")])],1)],1)]}}])},[t("span",[e._v(e._s(e.title))])]),e.borderBottom?t(I,{staticClass:"my-1"}):e._e()],1)},CX=[],$X=E(Zc,yX,CX,!1,null,"e1a7b3d5");const dC=$X.exports;var xX=Object.getOwnPropertyDescriptor,wX=(s,e,t,r)=>{for(var i=r>1?void 0:r?xX(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let fp=class extends k(L){constructor(){super(...arguments),this.mdiHelpCircleOutline=iv,this.mdiCloseThick=pe,this.mdiMoonWaningCrescent=oS}get mainsailVersion(){return this.$store.state.packageVersion}get klipperVersion(){var s,e;return(e=(s=this.$store.state.printer)==null?void 0:s.software_version)!=null?e:""}get moonrakerVersion(){var s,e;return(e=(s=this.$store.state.server)==null?void 0:s.moonraker_version)!=null?e:""}};fp=wX([S({})],fp);const SX="/img/logo.svg",PX="/img/klipper.svg";var DX=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(de,{attrs:{right:"",color:"panel"},scopedSlots:e._u([{key:"activator",fn:function({on:r,attrs:i}){return[t(_,e._g(e._b({},"v-icon",i,!1),r),[e._v(" "+e._s(e.mdiHelpCircleOutline)+" ")])]}}])},[t(Ee,{staticClass:"version-container pa-0"},[t("div",[t("img",{attrs:{height:"12",src:SX,alt:"mainsail-logo"}})]),t("div",[e._v("v"+e._s(e.mainsailVersion))]),t("div",[t(_,{staticClass:"moonraker-logo",attrs:{small:""}},[e._v(e._s(e.mdiMoonWaningCrescent))])],1),t("div",[e._v(e._s(e.moonrakerVersion))]),t("div",[t("img",{staticClass:"klipper-logo",attrs:{height:"12",src:PX,alt:"klipper-logo"}})]),t("div",[e._v(e._s(e.klipperVersion))])])],1)},TX=[],OX=E(fp,DX,TX,!1,null,"cc6926c6");const mC=OX.exports;var MX=Object.getOwnPropertyDescriptor,kX=(s,e,t,r)=>{for(var i=r>1?void 0:r?MX(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=a(i)||i);return i};let gp=class extends k(Xi,L,vt){constructor(){super(...arguments),this.navigationWidth=rw,this.topbarHeight=Vn}get naviDrawer(){return this.$store.state.naviDrawer}set naviDrawer(s){this.$store.dispatch("setNaviDrawer",s)}get navigationStyle(){return this.$store.state.gui.uiSettings.navigationStyle}get sidebarBackground(){var s;return(s=this.$store.getters["files/getCustomSidebarBackground"])!=null?s:this.sidebarBgImage}get currentPage(){return this.$route.fullPath}get boolNaviTemp(){return!this.isMobile&&this.$vuetify.breakpoint.mdAndDown}get sidebarCssVars(){return this.boolNaviTemp?{top:"".concat(Vn,"px !important"),"padding-bottom":"".concat(Vn,"px")}:{}}get sidebarLogo(){return this.$store.getters["files/getSidebarLogo"]}get logoColor(){return this.$store.state.gui.uiSettings.logo}get printerName(){return this.$store.state.gui.general.printername.length?this.$store.state.gui.general.printername:this.$store.state.printer.hostname}get logoCssVars(){return this.navigationStyle!=="iconsOnly"?{"margin-right":"16px"}:{}}get mobileLogoClass(){const s=["sidebar-logo","no-text-decoration","no-background","no-border"];return this.navigationStyle==="iconsOnly"&&(s.push("pa-0"),s.push("justify-center")),s}};gp=kX([S({components:{SidebarItem:dC,TheSelectPrinterDialog:Kp,AboutDialog:mC,MainsailLogo:mn}})],gp);var EX=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(F$,{key:e.navigationStyle,style:e.sidebarCssVars,attrs:{"mini-variant":e.navigationStyle==="iconsOnly",width:e.navigationWidth,temporary:e.boolNaviTemp,clipped:"",app:""},scopedSlots:e._u([{key:"img",fn:function(){return[t(nu,{attrs:{src:e.sidebarBackground,height:"100%"}})]},proxy:!0},{key:"append",fn:function(){return[t(J,{staticClass:"small-list-item mb-2"},[t(Hs,{staticClass:"menu-item-icon"},[t(mC)],1)],1)]},proxy:!0}]),model:{value:e.naviDrawer,callback:function(r){e.naviDrawer=r},expression:"naviDrawer"}},[t("overlay-scrollbars",{staticClass:"nav-scrollbar"},[t(Me,{staticClass:"pr-0 pt-0 ml-0"},[t(R$,{attrs:{"active-class":"active-nav-item"}},[e.isMobile?t(J,{class:e.mobileLogoClass,style:"height: "+e.topbarHeight+"px",attrs:{router:"",to:"/",ripple:!1}},[e.sidebarLogo?[t("img",{staticClass:"nav-logo",style:e.logoCssVars,attrs:{src:e.sidebarLogo,alt:"Logo"}})]:[t(mn,{staticClass:"nav-logo",style:e.logoCssVars,attrs:{color:e.logoColor,ripple:!1}})],e.navigationStyle!=="iconsOnly"?[t("span",{staticClass:"text-h6 font-weight-regular text-truncate"},[e._v(e._s(e.printerName))])]:e._e()],2):e._e(),e._l(e.visibleNaviPoints,function(r,i){return t(dC,{key:i,attrs:{item:r}})})],2)],1)],1)],1)},LX=[],AX=E(gp,EX,LX,!1,null,"3a20d60a");const hC=AX.exports;var FX=Object.defineProperty,RX=Object.getOwnPropertyDescriptor,rs=(s,e,t,r)=>{for(var i=r>1?void 0:r?RX(e,t):e,n=s.length-1,a;n>=0;n--)(a=s[n])&&(i=(r?a(e,t,i):a(i))||i);return r&&i&&FX(e,t,i),i};S.registerHooks(["metaInfo"]);let Rt=class extends k(L,vt){metaInfo(){let e=this.$store.getters.getTitle;return this.isPrinterPowerOff&&(e=this.$t("App.Titles.PrinterOff")),{title:e,titleTemplate:"%s"}}get title(){return this.$store.getters.getTitle}get naviDrawer(){return this.$store.state.naviDrawer}get navigationStyle(){return this.$store.state.gui.uiSettings.navigationStyle}get mainStyle(){let e={paddingLeft:"0"};return this.mainBgImage!==null&&(e.backgroundImage="url("+this.mainBgImage+")"),this.naviDrawer&&!this.$vuetify.breakpoint.mdAndDown&&(this.navigationStyle==="iconsAndText"&&(e.paddingLeft="220px"),this.navigationStyle==="iconsOnly"&&(e.paddingLeft="56px")),e}get customStylesheet(){return this.$store.getters["files/getCustomStylesheet"]}get customFavicons(){var e;return(e=this.$store.getters["files/getCustomFavicons"])!=null?e:null}get language(){return this.$store.state.gui.general.language}get current_file(){var e,t;return(t=(e=this.$store.state.printer.print_stats)==null?void 0:e.filename)!=null?t:""}get mode(){return this.$store.state.gui.uiSettings.mode}get logoColor(){return this.$store.state.gui.uiSettings.logo}get primaryColor(){return this.$store.state.gui.uiSettings.primary}get warningColor(){var e,t,r,i,n;return(n=(i=(r=(t=(e=this.$vuetify)==null?void 0:e.theme)==null?void 0:t.currentTheme)==null?void 0:r.warning)==null?void 0:i.toString())!=null?n:"#ff8300"}get primaryTextColor(){let e=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(this.primaryColor);if(e){const t=parseInt(e[1],16)*.2126,r=parseInt(e[2],16)*.7152,i=parseInt(e[3],16)*.0722;return(t+r+i)/255>.7?"#222":"#fff"}return"#ffffff"}get cssVars(){return{"--v-btn-text-primary":this.primaryTextColor,"--color-logo":this.logoColor,"--color-primary":this.primaryColor,"--color-warning":this.warningColor,"--panel-toolbar-icon-btn-width":mm+"px","--panel-toolbar-text-btn-height":mm+"px","--topbar-icon-btn-width":Vn+"px","--sidebar-menu-item-height":iw+"px"}}get print_percent(){return Math.floor(this.$store.getters["printer/getPrintPercent"]*100)}get containerClasses(){var t,r;const e=(t=this.$router.options.routes)==null?void 0:t.find(i=>i.name===this.$route.name);return{"px-3":!0,"px-sm-6":!0,"py-sm-6":!0,"mx-auto":!0,fullscreen:(r=e==null?void 0:e.fullscreen)!=null?r:!1}}get progressAsFavicon(){return this.$store.state.gui.uiSettings.progressAsFavicon}async languageChanged(e){await xy(e)}customStylesheetChanged(e){const t=document.getElementById("customStylesheet");if(e!==null&&t===null){const r=document.createElement("link");r.id="customStylesheet",r.type="text/css",r.rel="stylesheet",r.href=e,document.head.appendChild(r)}else e!==null&&t?t.setAttribute("href",e):t&&t.remove()}current_fileChanged(e){e!==""&&this.$socket.emit("server.files.metadata",{filename:e},{action:"files/getMetadataCurrentFile"})}primaryColorChanged(e){this.$nextTick(()=>{this.$vuetify.theme.currentTheme.primary=e})}modeChanged(e){const t=e!=="light";this.$vuetify.theme.dark=t;const r=document.documentElement;r.className=t?"theme--dark":"theme--light"}async drawFavicon(e){var n,a,o;const t=document.querySelector("link[rel*='icon'][sizes='16x16']"),r=document.querySelector("link[rel*='icon'][sizes='32x32']");if(!t||!r)return;if(this.progressAsFavicon&&this.printerIsPrinting){let l=64,u=document.createElement("canvas");u.width=l,u.height=l;const c=u.getContext("2d"),d=u.width/2,m=u.height/2,h=32;if(!c)return;c.beginPath(),c.moveTo(d,m),c.arc(d,m,h,0,2*Math.PI,!1),c.closePath(),c.fillStyle="#ddd",c.fill(),c.strokeStyle="rgba(200, 208, 218, 0.66)",c.stroke();let f=1.5*Math.PI,p=0,v=(Math.PI-.5*Math.PI)/25;(e>=0&&e<=25||e>25&&e<=50||e>50&&e<=75||e>75&&e<=100)&&(p=f+e*v),c.beginPath(),c.moveTo(d,m),c.arc(d,m,h,f,p,!1),c.closePath(),c.fillStyle=this.logoColor,c.fill(),t.href=u.toDataURL("image/png"),r.href=u.toDataURL("image/png");return}if(this.customFavicons){const[l,u]=this.customFavicons;t.href=l,r.href=u;return}if((o=(a=(n=this.theme)==null?void 0:n.logo)==null?void 0:a.show)!=null&&o&&this.sidebarLogo.endsWith(".svg")){const l=await fetch(this.sidebarLogo);if(!l.ok)return;const c=(await l.text()).replace(/fill="var\(--color-logo, #[0-9a-fA-F]{6}\)"/g,'fill="'.concat(this.logoColor,'"')),d=new Blob([c],{type:"image/svg+xml"}),m=new FileReader;m.onloadend=()=>{const h=m.result;t.href=h,r.href=h},m.readAsDataURL(d);return}const i="data:image/svg+xml;base64,"+window.btoa('\n <svg xmlns="http://www.w3.org/2000/svg" x="0px" y="0px" viewBox="0 0 599.38 523.11" xml:space="preserve">\n <g>\n <path style="fill:'.concat(this.logoColor,';" d="M382.29,142.98L132.98,522.82L0,522.68L344.3,0l0,0C352.18,49.06,365.2,97.68,382.29,142.98"/>\n <path style="fill:').concat(this.logoColor,';" d="M413.28,213.54L208.5,522.92l132.94,0.19l135.03-206.33l0,0C452.69,284.29,431.53,249.77,413.28,213.54 L413.28,213.54"/>\n <path style="fill:').concat(this.logoColor,';" d="M599.38,447.69l-49.25,75.42L417,522.82l101.6-153.67l0,0C543.48,397.35,570.49,423.61,599.38,447.69 L599.38,447.69z"/>\n </g>\n </svg>\n '));t.href=i,r.href=i}customFaviconsChanged(){this.drawFavicon(this.print_percent)}progressAsFaviconChanged(){this.drawFavicon(this.print_percent)}logoColorChanged(){this.drawFavicon(this.print_percent)}themeCssChanged(e){const t=document.getElementById("theme-css");t&&t.remove(),e!==null&&fetch(e).then(r=>r.text()).then(r=>{const i=document.createElement("style");i.id="theme-css",i.innerHTML=r,document.head.appendChild(i)})}print_percentChanged(e){this.drawFavicon(e),this.refreshSpoolman()}printerIsPrintingChanged(){this.drawFavicon(this.print_percent)}refreshSpoolman(){this.moonrakerComponents.includes("spoolman")&&this.$store.dispatch("server/spoolman/refreshActiveSpool",null,{root:!0})}appHeight(){this.$nextTick(()=>{document.documentElement.style.setProperty("--app-height",window.innerHeight+"px")})}mounted(){this.drawFavicon(this.print_percent),this.appHeight(),window.addEventListener("resize",this.appHeight),window.addEventListener("orientationchange",this.appHeight)}};rs([he("language")],Rt.prototype,"languageChanged",1);rs([he("customStylesheet")],Rt.prototype,"customStylesheetChanged",1);rs([he("current_file")],Rt.prototype,"current_fileChanged",1);rs([he("primaryColor")],Rt.prototype,"primaryColorChanged",1);rs([he("mode")],Rt.prototype,"modeChanged",1);rs([he("customFavicons")],Rt.prototype,"customFaviconsChanged",1);rs([he("progressAsFavicon")],Rt.prototype,"progressAsFaviconChanged",1);rs([he("logoColor")],Rt.prototype,"logoColorChanged",1);rs([he("themeCss")],Rt.prototype,"themeCssChanged",1);rs([he("print_percent")],Rt.prototype,"print_percentChanged",1);rs([he("printerIsPrinting")],Rt.prototype,"printerIsPrintingChanged",1);Rt=rs([S({components:{TheMacroPrompt:Iv,TheTimelapseRenderingSnackbar:Qv,TheEditor:ub,TheSelectPrinterDialog:Kp,TheConnectingDialog:Ev,TheUpdateDialog:mb,TheTopbar:cC,TheSidebar:hC,TheFullscreenUpload:Kv,TheUploadSnackbar:Jv,TheManualProbeDialog:Zv,TheBedScrewsDialog:Gv,TheScrewsTiltAdjustDialog:zv}})],Rt);var HX=function(){var e=this,t=e._self._c;return e._self._setupProxy,t(H$,{style:e.cssVars},[e.socketIsConnected&&e.guiIsReady?[t(hC),t(cC),t(j$,{style:e.mainStyle,attrs:{id:"content"}},[t(Ee,{class:e.containerClasses,attrs:{id:"page-container",fluid:""}},[t("router-view")],1)],1),t(S5),t(mb),t(ub),t(Qv),t(Kv),t(Jv),t(Zv),t(Gv),t(zv),t(Iv)]:e.instancesDB!=="moonraker"?t(Kp):t(Ev)],2)},jX=[],IX=E(Rt,HX,jX,!1,null,null);const NX=IX.exports;y.use(k_,{directives:{Touch:N$,Ripple:I$}});const pC=new k_({theme:{dark:!0,options:{customProperties:!0}},icons:{iconfont:"mdiSvg"},breakpoint:{mobileBreakpoint:768}});/*!
|
||
* vuex v3.6.2
|
||
* (c) 2021 Evan You
|
||
* @license MIT
|
||
*/function VX(s){var e=Number(s.version.split(".")[0]);if(e>=2)s.mixin({beforeCreate:r});else{var t=s.prototype._init;s.prototype._init=function(i){i===void 0&&(i={}),i.init=i.init?[r].concat(i.init):r,t.call(this,i)}}function r(){var i=this.$options;i.store?this.$store=typeof i.store=="function"?i.store():i.store:i.parent&&i.parent.$store&&(this.$store=i.parent.$store)}}var BX=typeof window<"u"?window:typeof global<"u"?global:{},hi=BX.__VUE_DEVTOOLS_GLOBAL_HOOK__;function UX(s){hi&&(s._devtoolHook=hi,hi.emit("vuex:init",s),hi.on("vuex:travel-to-state",function(e){s.replaceState(e)}),s.subscribe(function(e,t){hi.emit("vuex:mutation",e,t)},{prepend:!0}),s.subscribeAction(function(e,t){hi.emit("vuex:action",e,t)},{prepend:!0}))}function WX(s,e){return s.filter(e)[0]}function _p(s,e){if(e===void 0&&(e=[]),s===null||typeof s!="object")return s;var t=WX(e,function(i){return i.original===s});if(t)return t.copy;var r=Array.isArray(s)?[]:{};return e.push({original:s,copy:r}),Object.keys(s).forEach(function(i){r[i]=_p(s[i],e)}),r}function bn(s,e){Object.keys(s).forEach(function(t){return e(s[t],t)})}function fC(s){return s!==null&&typeof s=="object"}function zX(s){return s&&typeof s.then=="function"}function GX(s,e){return function(){return s(e)}}var vs=function(e,t){this.runtime=t,this._children=Object.create(null),this._rawModule=e;var r=e.state;this.state=(typeof r=="function"?r():r)||{}},gC={namespaced:{configurable:!0}};gC.namespaced.get=function(){return!!this._rawModule.namespaced};vs.prototype.addChild=function(e,t){this._children[e]=t};vs.prototype.removeChild=function(e){delete this._children[e]};vs.prototype.getChild=function(e){return this._children[e]};vs.prototype.hasChild=function(e){return e in this._children};vs.prototype.update=function(e){this._rawModule.namespaced=e.namespaced,e.actions&&(this._rawModule.actions=e.actions),e.mutations&&(this._rawModule.mutations=e.mutations),e.getters&&(this._rawModule.getters=e.getters)};vs.prototype.forEachChild=function(e){bn(this._children,e)};vs.prototype.forEachGetter=function(e){this._rawModule.getters&&bn(this._rawModule.getters,e)};vs.prototype.forEachAction=function(e){this._rawModule.actions&&bn(this._rawModule.actions,e)};vs.prototype.forEachMutation=function(e){this._rawModule.mutations&&bn(this._rawModule.mutations,e)};Object.defineProperties(vs.prototype,gC);var ai=function(e){this.register([],e,!1)};ai.prototype.get=function(e){return e.reduce(function(t,r){return t.getChild(r)},this.root)};ai.prototype.getNamespace=function(e){var t=this.root;return e.reduce(function(r,i){return t=t.getChild(i),r+(t.namespaced?i+"/":"")},"")};ai.prototype.update=function(e){_C([],this.root,e)};ai.prototype.register=function(e,t,r){var i=this;r===void 0&&(r=!0);var n=new vs(t,r);if(e.length===0)this.root=n;else{var a=this.get(e.slice(0,-1));a.addChild(e[e.length-1],n)}t.modules&&bn(t.modules,function(o,l){i.register(e.concat(l),o,r)})};ai.prototype.unregister=function(e){var t=this.get(e.slice(0,-1)),r=e[e.length-1],i=t.getChild(r);i&&i.runtime&&t.removeChild(r)};ai.prototype.isRegistered=function(e){var t=this.get(e.slice(0,-1)),r=e[e.length-1];return t?t.hasChild(r):!1};function _C(s,e,t){if(e.update(t),t.modules)for(var r in t.modules){if(!e.getChild(r))return;_C(s.concat(r),e.getChild(r),t.modules[r])}}var kt,Gt=function(e){var t=this;e===void 0&&(e={}),!kt&&typeof window<"u"&&window.Vue&&yC(window.Vue);var r=e.plugins;r===void 0&&(r=[]);var i=e.strict;i===void 0&&(i=!1),this._committing=!1,this._actions=Object.create(null),this._actionSubscribers=[],this._mutations=Object.create(null),this._wrappedGetters=Object.create(null),this._modules=new ai(e),this._modulesNamespaceMap=Object.create(null),this._subscribers=[],this._watcherVM=new kt,this._makeLocalGettersCache=Object.create(null);var n=this,a=this,o=a.dispatch,l=a.commit;this.dispatch=function(m,h){return o.call(n,m,h)},this.commit=function(m,h,f){return l.call(n,m,h,f)},this.strict=i;var u=this._modules.root.state;bd(this,u,[],this._modules.root),$g(this,u),r.forEach(function(d){return d(t)});var c=e.devtools!==void 0?e.devtools:kt.config.devtools;c&&UX(this)},Cg={state:{configurable:!0}};Cg.state.get=function(){return this._vm._data.$$state};Cg.state.set=function(s){};Gt.prototype.commit=function(e,t,r){var i=this,n=qc(e,t,r),a=n.type,o=n.payload,l={type:a,payload:o},u=this._mutations[a];u&&(this._withCommit(function(){u.forEach(function(d){d(o)})}),this._subscribers.slice().forEach(function(c){return c(l,i.state)}))};Gt.prototype.dispatch=function(e,t){var r=this,i=qc(e,t),n=i.type,a=i.payload,o={type:n,payload:a},l=this._actions[n];if(l){try{this._actionSubscribers.slice().filter(function(c){return c.before}).forEach(function(c){return c.before(o,r.state)})}catch{}var u=l.length>1?Promise.all(l.map(function(c){return c(a)})):l[0](a);return new Promise(function(c,d){u.then(function(m){try{r._actionSubscribers.filter(function(h){return h.after}).forEach(function(h){return h.after(o,r.state)})}catch{}c(m)},function(m){try{r._actionSubscribers.filter(function(h){return h.error}).forEach(function(h){return h.error(o,r.state,m)})}catch{}d(m)})})}};Gt.prototype.subscribe=function(e,t){return vC(e,this._subscribers,t)};Gt.prototype.subscribeAction=function(e,t){var r=typeof e=="function"?{before:e}:e;return vC(r,this._actionSubscribers,t)};Gt.prototype.watch=function(e,t,r){var i=this;return this._watcherVM.$watch(function(){return e(i.state,i.getters)},t,r)};Gt.prototype.replaceState=function(e){var t=this;this._withCommit(function(){t._vm._data.$$state=e})};Gt.prototype.registerModule=function(e,t,r){r===void 0&&(r={}),typeof e=="string"&&(e=[e]),this._modules.register(e,t),bd(this,this.state,e,this._modules.get(e),r.preserveState),$g(this,this.state)};Gt.prototype.unregisterModule=function(e){var t=this;typeof e=="string"&&(e=[e]),this._modules.unregister(e),this._withCommit(function(){var r=xg(t.state,e.slice(0,-1));kt.delete(r,e[e.length-1])}),bC(this)};Gt.prototype.hasModule=function(e){return typeof e=="string"&&(e=[e]),this._modules.isRegistered(e)};Gt.prototype.hotUpdate=function(e){this._modules.update(e),bC(this,!0)};Gt.prototype._withCommit=function(e){var t=this._committing;this._committing=!0,e(),this._committing=t};Object.defineProperties(Gt.prototype,Cg);function vC(s,e,t){return e.indexOf(s)<0&&(t&&t.prepend?e.unshift(s):e.push(s)),function(){var r=e.indexOf(s);r>-1&&e.splice(r,1)}}function bC(s,e){s._actions=Object.create(null),s._mutations=Object.create(null),s._wrappedGetters=Object.create(null),s._modulesNamespaceMap=Object.create(null);var t=s.state;bd(s,t,[],s._modules.root,!0),$g(s,t,e)}function $g(s,e,t){var r=s._vm;s.getters={},s._makeLocalGettersCache=Object.create(null);var i=s._wrappedGetters,n={};bn(i,function(o,l){n[l]=GX(o,s),Object.defineProperty(s.getters,l,{get:function(){return s._vm[l]},enumerable:!0})});var a=kt.config.silent;kt.config.silent=!0,s._vm=new kt({data:{$$state:e},computed:n}),kt.config.silent=a,s.strict&&KX(s),r&&(t&&s._withCommit(function(){r._data.$$state=null}),kt.nextTick(function(){return r.$destroy()}))}function bd(s,e,t,r,i){var n=!t.length,a=s._modules.getNamespace(t);if(r.namespaced&&(s._modulesNamespaceMap[a],s._modulesNamespaceMap[a]=r),!n&&!i){var o=xg(e,t.slice(0,-1)),l=t[t.length-1];s._withCommit(function(){kt.set(o,l,r.state)})}var u=r.context=ZX(s,a,t);r.forEachMutation(function(c,d){var m=a+d;XX(s,m,c,u)}),r.forEachAction(function(c,d){var m=c.root?d:a+d,h=c.handler||c;YX(s,m,h,u)}),r.forEachGetter(function(c,d){var m=a+d;JX(s,m,c,u)}),r.forEachChild(function(c,d){bd(s,e,t.concat(d),c,i)})}function ZX(s,e,t){var r=e==="",i={dispatch:r?s.dispatch:function(n,a,o){var l=qc(n,a,o),u=l.payload,c=l.options,d=l.type;return(!c||!c.root)&&(d=e+d),s.dispatch(d,u)},commit:r?s.commit:function(n,a,o){var l=qc(n,a,o),u=l.payload,c=l.options,d=l.type;(!c||!c.root)&&(d=e+d),s.commit(d,u,c)}};return Object.defineProperties(i,{getters:{get:r?function(){return s.getters}:function(){return qX(s,e)}},state:{get:function(){return xg(s.state,t)}}}),i}function qX(s,e){if(!s._makeLocalGettersCache[e]){var t={},r=e.length;Object.keys(s.getters).forEach(function(i){if(i.slice(0,r)===e){var n=i.slice(r);Object.defineProperty(t,n,{get:function(){return s.getters[i]},enumerable:!0})}}),s._makeLocalGettersCache[e]=t}return s._makeLocalGettersCache[e]}function XX(s,e,t,r){var i=s._mutations[e]||(s._mutations[e]=[]);i.push(function(a){t.call(s,r.state,a)})}function YX(s,e,t,r){var i=s._actions[e]||(s._actions[e]=[]);i.push(function(a){var o=t.call(s,{dispatch:r.dispatch,commit:r.commit,getters:r.getters,state:r.state,rootGetters:s.getters,rootState:s.state},a);return zX(o)||(o=Promise.resolve(o)),s._devtoolHook?o.catch(function(l){throw s._devtoolHook.emit("vuex:error",l),l}):o})}function JX(s,e,t,r){s._wrappedGetters[e]||(s._wrappedGetters[e]=function(n){return t(r.state,r.getters,n.state,n.getters)})}function KX(s){s._vm.$watch(function(){return this._data.$$state},function(){},{deep:!0,sync:!0})}function xg(s,e){return e.reduce(function(t,r){return t[r]},s)}function qc(s,e,t){return fC(s)&&s.type&&(t=e,e=s,s=s.type),{type:s,payload:e,options:t}}function yC(s){kt&&s===kt||(kt=s,VX(kt))}var CC=Cd(function(s,e){var t={};return yd(e).forEach(function(r){var i=r.key,n=r.val;t[i]=function(){var o=this.$store.state,l=this.$store.getters;if(s){var u=$d(this.$store,"mapState",s);if(!u)return;o=u.context.state,l=u.context.getters}return typeof n=="function"?n.call(this,o,l):o[n]},t[i].vuex=!0}),t}),$C=Cd(function(s,e){var t={};return yd(e).forEach(function(r){var i=r.key,n=r.val;t[i]=function(){for(var o=[],l=arguments.length;l--;)o[l]=arguments[l];var u=this.$store.commit;if(s){var c=$d(this.$store,"mapMutations",s);if(!c)return;u=c.context.commit}return typeof n=="function"?n.apply(this,[u].concat(o)):u.apply(this.$store,[n].concat(o))}}),t}),xC=Cd(function(s,e){var t={};return yd(e).forEach(function(r){var i=r.key,n=r.val;n=s+n,t[i]=function(){if(!(s&&!$d(this.$store,"mapGetters",s)))return this.$store.getters[n]},t[i].vuex=!0}),t}),wC=Cd(function(s,e){var t={};return yd(e).forEach(function(r){var i=r.key,n=r.val;t[i]=function(){for(var o=[],l=arguments.length;l--;)o[l]=arguments[l];var u=this.$store.dispatch;if(s){var c=$d(this.$store,"mapActions",s);if(!c)return;u=c.context.dispatch}return typeof n=="function"?n.apply(this,[u].concat(o)):u.apply(this.$store,[n].concat(o))}}),t}),QX=function(s){return{mapState:CC.bind(null,s),mapGetters:xC.bind(null,s),mapMutations:$C.bind(null,s),mapActions:wC.bind(null,s)}};function yd(s){return eY(s)?Array.isArray(s)?s.map(function(e){return{key:e,val:e}}):Object.keys(s).map(function(e){return{key:e,val:s[e]}}):[]}function eY(s){return Array.isArray(s)||fC(s)}function Cd(s){return function(e,t){return typeof e!="string"?(t=e,e=""):e.charAt(e.length-1)!=="/"&&(e+="/"),s(e,t)}}function $d(s,e,t){var r=s._modulesNamespaceMap[t];return r}function tY(s){s===void 0&&(s={});var e=s.collapsed;e===void 0&&(e=!0);var t=s.filter;t===void 0&&(t=function(c,d,m){return!0});var r=s.transformer;r===void 0&&(r=function(c){return c});var i=s.mutationTransformer;i===void 0&&(i=function(c){return c});var n=s.actionFilter;n===void 0&&(n=function(c,d){return!0});var a=s.actionTransformer;a===void 0&&(a=function(c){return c});var o=s.logMutations;o===void 0&&(o=!0);var l=s.logActions;l===void 0&&(l=!0);var u=s.logger;return u===void 0&&(u=console),function(c){var d=_p(c.state);typeof u>"u"||(o&&c.subscribe(function(m,h){var f=_p(h);if(t(m,d,f)){var p=m_(),v=i(m),C="mutation "+m.type+p;u_(u,C,e),u.log("%c prev state","color: #9E9E9E; font-weight: bold",r(d)),u.log("%c mutation","color: #03A9F4; font-weight: bold",v),u.log("%c next state","color: #4CAF50; font-weight: bold",r(f)),d_(u)}d=f}),l&&c.subscribeAction(function(m,h){if(n(m,h)){var f=m_(),p=a(m),v="action "+m.type+f;u_(u,v,e),u.log("%c action","color: #03A9F4; font-weight: bold",p),d_(u)}}))}}function u_(s,e,t){var r=t?s.groupCollapsed:s.group;try{r.call(s,e)}catch{s.log(e)}}function d_(s){try{s.groupEnd()}catch{s.log("—— log end ——")}}function m_(){var s=new Date;return" @ "+Fo(s.getHours(),2)+":"+Fo(s.getMinutes(),2)+":"+Fo(s.getSeconds(),2)+"."+Fo(s.getMilliseconds(),3)}function sY(s,e){return new Array(e+1).join(s)}function Fo(s,e){return sY("0",e-s.toString().length)+s}var SC={Store:Gt,install:yC,version:"3.6.2",mapState:CC,mapMutations:$C,mapGetters:xC,mapActions:wC,createNamespacedHelpers:QX,createLogger:tY};const rY={switchToDashboard(){Ia.currentRoute.fullPath!=="/"&&Ia.push("/")},changePrinter({dispatch:s,getters:e},t){s("files/reset"),s("gui/reset"),s("printer/reset"),s("server/reset"),s("socket/reset");const r=e["farm/"+t.printer+"/getSocketData"];s("socket/setSocket",{hostname:r.hostname,port:r.port,path:r.path})},setNaviDrawer({commit:s},e){s("setNaviDrawer",e)},async importConfigJson({commit:s},e){var r;let t=(r=e.instancesDB)!=null?r:"moonraker";if(t!=="moonraker"){s("setInstancesDB",t),t==="json"&&"instances"in e&&Array.isArray(e.instances)&&e.instances.length&&s("setConfigInstances",e.instances);return}e.hostname&&s("socket/setData",{hostname:e.hostname}),e.port&&s("socket/setData",{port:parseInt(e.port.toString())}),e.path&&s("socket/setData",{route_prefix:e.path})}},iY={setNaviDrawer(s,e){y.set(s,"naviDrawer",e),localStorage.setItem("naviDrawer",e)},setInstancesDB(s,e){y.set(s,"instancesDB",e)},setConfigInstances(s,e){y.set(s,"configInstances",e)}},nY={getVersion:s=>s.packageVersion,getTitle:(s,e)=>{var r,i,n,a,o,l,u,c,d,m,h,f,p,v,C,P,M,F,O,$,D,V;if(!((r=s.socket)!=null&&r.isConnected))return"Mainsail";if(((i=s.server)==null?void 0:i.klippy_state)!=="ready")return ve.t("App.Titles.Error");let t=(o=(a=(n=s.printer)==null?void 0:n.print_stats)==null?void 0:a.state)!=null?o:"";if(s.printer&&((l=s.printer["gcode_macro TIMELAPSE_TAKE_FRAME"])!=null&&l.is_paused)&&t==="paused"&&(t="printing"),t==="paused")return ve.t("App.Titles.Pause");if(((c=(u=s.printer)==null?void 0:u.print_stats)==null?void 0:c.state)==="complete"){let N=ve.t("App.Titles.Complete",{filename:s.printer.print_stats.filename});return(d=s.gui)!=null&&d.general.printername&&(N+="- ".concat((m=s.gui)==null?void 0:m.general.printername)),N}if(t==="printing"){const N=e["printer/getEstimatedTimeETAFormat"],W=Math.floor(e["printer/getPrintPercent"]*100);if(N!=="--"){let te=ve.t("App.Titles.PrintingETA",{percent:W,filename:(f=(h=s.printer)==null?void 0:h.print_stats)==null?void 0:f.filename,eta:N});return(p=s.gui)!=null&&p.general.printername&&(te+="- ".concat((v=s.gui)==null?void 0:v.general.printername)),te}let G=ve.t("App.Titles.Printing",{percent:W,filename:(P=(C=s.printer)==null?void 0:C.print_stats)==null?void 0:P.filename});return(M=s.gui)!=null&&M.general.printername&&(G+="- ".concat((F=s.gui)==null?void 0:F.general.printername)),G}return(V=(D=(O=s.gui)==null?void 0:O.general.printername)!=null?D:($=s.printer)==null?void 0:$.hostname)!=null?V:"Mainsail"},getDependencies:s=>{var v,C,P,M,F,O,$,D,V,N,W,G;const e=[],t=(C=(v=s.printer)==null?void 0:v.software_version)!=null?C:"",r=t.split("-"),i=(P=r[0])!=null?P:"",n=parseInt((M=r[1])!=null?M:0),a=jg.split("-"),o=(F=a[0])!=null?F:"",l=parseInt((O=a[1])!=null?O:0);nt.valid(i)&&(nt.gt(o,i)||nt.eq(o,i)&&n<l)&&e.push({serviceName:"Klipper",installedVersion:t,neededVersion:jg});const u=(D=($=s.server)==null?void 0:$.moonraker_version)!=null?D:"",c=u.split("-"),d=(V=c[0])!=null?V:"",m=parseInt((N=c[1])!=null?N:0),h=Ig.split("-"),f=(W=h[0])!=null?W:"",p=parseInt((G=h[1])!=null?G:0);return nt.valid(d)&&(nt.gt(f,d)||nt.eq(f,d)&&m<p)&&e.push({serviceName:"Moonraker",installedVersion:u,neededVersion:Ig}),e}},aY={reset({commit:s}){s("setDisconnected"),s("clearLoadings"),s("reset")},setData({commit:s},e){s("setData",e)},async setSocket({commit:s,state:e},t){if(s("setData",t),"$socket"in y.prototype){const r=t.path.replaceAll(/(^\/*)|(\/*$)/g,""),i=r.length>0?"/".concat(r):"";await y.prototype.$socket.close(),await y.prototype.$socket.setUrl(e.protocol+"://"+t.hostname+":"+t.port+i+"/websocket"),await y.prototype.$socket.connect()}},onOpen({commit:s,dispatch:e,rootState:t}){var r,i;s("setConnected"),e("server/init",null,{root:!0}),(i=(r=t==null?void 0:t.server)==null?void 0:r.updateManager)!=null&&i.updateResponse.complete||s("server/updateManager/setStatus",{busy:!1},{root:!0})},onClose({commit:s}){s("setDisconnected")},onMessage({commit:s,dispatch:e},t){switch(t.method){case"notify_status_update":e("printer/getData",t.params[0],{root:!0});break;case"notify_gcode_response":e("server/addEvent",Object.assign({result:t.params[0]},{send:!1}),{root:!0});break;case"notify_klippy_ready":s("server/setKlippyConnected",null,{root:!0}),e("server/stopKlippyConnectedInterval",null,{root:!0}),e("server/stopKlippyStateInterval",null,{root:!0}),e("printer/init",null,{root:!0});break;case"notify_klippy_disconnected":e("server/setKlippyDisconnected",null,{root:!0});break;case"notify_klippy_shutdown":e("server/setKlippyShutdown",null,{root:!0});break;case"notify_proc_stat_update":e("server/updateProcStats",t.params[0],{root:!0});break;case"notify_cpu_throttled":s("server/setThrottledState",t.params[0],{root:!0});break;case"notify_filelist_changed":e("files/filelist_changed",t.params[0],{root:!0});break;case"notify_metadata_update":s("files/setMetadata",t.params[0],{root:!0});break;case"notify_power_changed":s("server/power/setStatus",t.params[0],{root:!0});break;case"notify_update_response":s("server/updateManager/addUpdateResponse",t.params[0],{root:!0});break;case"notify_update_refreshed":e("server/updateManager/onUpdateStatus",t.params[0],{root:!0});break;case"notify_history_changed":e("server/history/getChanged",t.params[0],{root:!0});break;case"notify_service_state_changed":e("server/serviceStateChanged",t.params[0],{root:!0});break;case"notify_timelapse_event":e("server/timelapse/getEvent",t.params[0],{root:!0});break;case"notify_job_queue_changed":e("server/jobQueue/getEvent",t.params[0],{root:!0});break;case"notify_announcement_update":e("server/announcements/getList",t.params[0],{root:!0});break;case"notify_announcement_dismissed":e("server/announcements/getDismissed",t.params[0],{root:!0});break;case"notify_announcement_wake":e("server/announcements/getWaked",t.params[0],{root:!0});break;case"notify_webcams_changed":e("gui/webcams/initStore",t.params[0],{root:!0});break;case"notify_active_spool_set":e("server/spoolman/getActiveSpoolId",t.params[0],{root:!0});break;case"notify_sensor_update":e("server/sensor/updateSensors",t.params[0],{root:!0});break;default:window.console.debug(t)}},addLoading({commit:s},e){s("addLoading",e)},removeLoading({commit:s},e){s("removeLoading",e)},clearLoadings({commit:s}){s("clearLoadings")},addInitModule({commit:s},e){s("addInitModule",e)},removeInitModule({commit:s},e){s("removeInitModule",e)},removeInitComponent({commit:s},e){s("removeInitComponent",e)},reportDebug(s,e){window.console.log(e)},setConnectionFailed({commit:s},e){s("setDisconnected",e)}},oY={reset(s){const e=PC();y.set(s,"initializationList",e.initializationList)},setConnected(s){y.set(s,"isConnected",!0),y.set(s,"isConnecting",!1),y.set(s,"connectingFailed",!1)},setDisconnected(s,e){y.set(s,"isConnected",!1),y.set(s,"isConnecting",!1),y.set(s,"connectingFailed",!0),y.set(s,"connection_id",null),e&&y.set(s,"connectionFailedMessage",e)},setData(s,e){"socket"in e&&(e=e.socket),Object.entries(e).forEach(([t,r])=>{y.set(s,t,r)})},addLoading(s,e){s.loadings.push(e.name)},removeLoading(s,e){const t=s.loadings.indexOf(e.name);t>-1&&s.loadings.splice(t,1)},clearLoadings(s){s.loadings.length&&y.set(s,"loadings",[])},addInitModule(s,e){const t=[...s.initializationList];t.indexOf(e)>-1||(t.push(e),y.set(s,"initializationList",t))},removeInitModule(s,e){const t=[...s.initializationList],r=t.indexOf(e);r!==-1&&(t.splice(r,1),y.set(s,"initializationList",t))},removeInitComponent(s,e){const t=[...s.initializationList],r=t.reduce((i,n,a)=>(n.startsWith(e)&&i.push(a),i),[]);r.length&&(r.forEach(i=>t.splice(i,1)),y.set(s,"initializationList",t))}},lY={getUrl:s=>{const e=s.port!==80?":"+s.port:"";let t="/"+s.path.replace(/^\/|\/$/g,"");return t.endsWith("/")&&(t=t.slice(0,-1)),"//".concat(s.hostname).concat(e).concat(t)},getHostUrl:s=>{const e=s.protocol==="wss"?"https":"http";return"".concat(e,"://").concat(s.hostname,"/")},getWebsocketUrl:(s,e)=>s.protocol+":"+e.getUrl+"/websocket"},PC=()=>{const s=window.location.hostname,e=window.location.port||(window.location.protocol==="https:"?443:80),t=Number(e);return{hostname:s,port:t,path:"",protocol:document.location.protocol==="https:"?"wss":"ws",reconnectInterval:2e3,isConnected:!1,isConnecting:!1,connectingFailed:!1,connectionFailedMessage:null,loadings:[],initializationList:["server"],connection_id:null}},cY=PC(),uY={namespaced:!0,state:cY,getters:lY,actions:aY,mutations:oY},dY={reset({commit:s,dispatch:e}){e("stopKlippyConnectedInterval"),e("stopKlippyStateInterval"),s("reset"),e("power/reset"),e("updateManager/reset")},async init({commit:s,dispatch:e,rootState:t}){window.console.debug("init Server");try{const r=await y.$socket.emitAndWait("server.connection.identify",{client_name:"mainsail",version:t.packageVersion,type:"web",url:"https://github.com/mainsail-crew/mainsail"});s("setConnectionId",r.connection_id)}catch(r){r.message==="Unauthorized"&&this.dispatch("socket/setConnectionFailed",r.message),window.console.error("Error while identifying client: "+r.message);return}e("socket/addInitModule","server/info",{root:!0}),e("socket/addInitModule","server/config",{root:!0}),e("socket/addInitModule","server/systemInfo",{root:!0}),e("socket/addInitModule","server/procStats",{root:!0}),e("socket/addInitModule","server/databaseList",{root:!0}),y.$socket.emit("server.info",{},{action:"server/initServerInfo"}),y.$socket.emit("server.config",{},{action:"server/initServerConfig"}),y.$socket.emit("machine.system_info",{},{action:"server/initSystemInfo"}),y.$socket.emit("machine.proc_stats",{},{action:"server/initProcStats"}),y.$socket.emit("server.database.list",{root:"config"},{action:"server/checkDatabases"}),await e("socket/removeInitModule","server",{root:!0})},checkDatabases({dispatch:s,commit:e},t){var r,i;(r=t.namespaces)!=null&&r.includes("mainsail")?(s("socket/addInitModule","gui/init",{root:!0}),s("gui/init",null,{root:!0})):s("gui/initDb",null,{root:!0}),(i=t.namespaces)!=null&&i.includes("maintenance")?(s("socket/addInitModule","gui/maintenance/init",{root:!0}),s("gui/maintenance/init",null,{root:!0})):s("gui/maintenance/initDb",null,{root:!0}),s("socket/addInitModule","gui/webcam/init",{root:!0}),s("gui/webcams/init",null,{root:!0}),e("saveDbNamespaces",t.namespaces),y.$socket.emit("server.info",{},{action:"server/checkKlippyConnected"}),s("socket/removeInitModule","server/databaseList",{root:!0})},initServerInfo({dispatch:s,commit:e},t){var r,i;if("plugins"in t&&delete t.plugins,"failed_plugins"in t&&delete t.failed_plugins,(r=t.components)!=null&&r.length)for(let n of t.components)n=T3(n),B_.includes(n)&&(window.console.debug("init server component: "+n),s("socket/addInitModule","server/"+n+"/init",{root:!0}),s("server/"+n+"/init",{},{root:!0}));(i=t.registered_directories)!=null&&i.length&&s("files/initRootDirs",t.registered_directories,{root:!0}),e("setData",t),s("socket/removeInitModule","server/info",{root:!0})},initServerConfig({commit:s,dispatch:e},t){s("setConfig",t),e("socket/removeInitModule","server/config",{root:!0})},initSystemInfo({commit:s,dispatch:e},t){s("setSystemInfo",t.system_info),e("socket/removeInitModule","server/systemInfo",{root:!0})},initProcStats({commit:s,dispatch:e},t){if(t.throttled_state!==null&&s("setThrottledState",t.throttled_state),t.system_uptime){const r=new Date(new Date().getTime()-t.system_uptime*1e3);s("setSystemBootAt",r)}e("socket/removeInitModule","server/procStats",{root:!0})},updateProcStats({commit:s},e){"cpu_temp"in e&&s("setCpuTemp",e.cpu_temp),"moonraker_stats"in e&&s("setMoonrakerStats",e.moonraker_stats),"network"in e&&s("setNetworkStats",e.network),"system_cpu_usage"in e&&s("setCpuStats",e.system_cpu_usage)},setKlippyReady({dispatch:s}){s("stopKlippyConnectedInterval"),s("stopKlippyStateInterval"),s("printer/reset",null,{root:!0}),s("printer/init",null,{root:!0})},setKlippyDisconnected({commit:s,dispatch:e}){s("setKlippyDisconnected",null),e("stopKlippyStateInterval"),e("startKlippyConnectedInterval")},setKlippyShutdown({commit:s,dispatch:e}){s("setKlippyShutdown",null),e("stopKlippyStateInterval"),e("startKlippyConnectedInterval")},startKlippyConnectedInterval({commit:s,state:e}){if(e.klippy_connected_timer)return;const t=setInterval(()=>{y.$socket.emit("server.info",{},{action:"server/checkKlippyConnected"})},2e3);s("setKlippyConnectedTimer",t)},stopKlippyConnectedInterval({commit:s,state:e}){e.klippy_connected_timer!==null&&(clearInterval(e.klippy_connected_timer),s("setKlippyConnectedTimer",null))},checkKlippyConnected({commit:s,dispatch:e},t){if(!t.klippy_connected){e("startKlippyConnectedInterval");return}e("stopKlippyConnectedInterval"),s("setKlippyConnected"),e("printer/initGcodes",null,{root:!0}),e("checkKlippyState",{state:t.klippy_state,state_message:null})},startKlippyStateInterval({commit:s,state:e}){if(e.klippy_state_timer)return;const t=setInterval(()=>{y.$socket.emit("printer.info",{},{action:"server/checkKlippyState"})},2e3);s("setKlippyStateTimer",t)},stopKlippyStateInterval({commit:s,state:e}){e.klippy_state_timer!==null&&(clearInterval(e.klippy_state_timer),s("setKlippyStateTimer",null))},checkKlippyState({commit:s,dispatch:e},t){if(s("setKlippyState",t.state),s("setKlippyMessage",t.state_message),t.state!=="ready"){e("startKlippyStateInterval");return}e("stopKlippyConnectedInterval"),e("stopKlippyStateInterval"),e("printer/init",null,{root:!0})},getData({commit:s},e){s("setData",e)},getGcodeStore({commit:s,dispatch:e,rootGetters:t},r){s("clearGcodeStore");let i=r.gcode_store;t["gui/console/getConsolefilterRules"].forEach(o=>{try{const l=new RegExp(o);i=i.filter(u=>!l.test(u.message))}catch{window.console.error("Custom console filter '"+o+"' doesn't work")}});const a=t["gui/console/getConsoleClearedSince"];i=i.filter(o=>a?o.time&&o.time*1e3<a?!1:!(o.date&&new Date(o.date).valueOf()<a):!0),s("setGcodeStore",i),e("socket/removeInitModule","server/gcode_store",{root:!0})},addRootDirectory({commit:s,state:e},t){e.registered_directories.includes(t.item.root)||s("addRootDirectory",{name:t.item.root})},addEvent({commit:s,rootGetters:e},t){let r=t,i="response";typeof t=="object"&&"type"in t&&(i=t.type),"message"in t?r=t.message:"result"in t?r=t.result:"error"in t&&(r=r.error.message);let n=sf(r);i==="response"&&(r.startsWith("// action:")?i="action":r.startsWith("// debug:")&&(i="debug"));const a=e["gui/console/getConsolefilterRules"];let o=!0;a.every(l=>{try{new RegExp(l).test(n)&&(o=!1)}catch{window.console.error("Custom console filter '"+l+"' doesn't work!")}return o}),o&&(t.type==="command"&&(n='<a class="command text--blue">'+n+"</a>"),s("addEvent",{date:new Date,message:r,formatMessage:n,type:i}),["error","response"].includes(i)&&!["/","/console"].includes(Ia.currentRoute.path)&&r.startsWith("!! ")&&y.$toast.error(n))},serviceStateChanged({commit:s},e){s("updateServiceState",e)},addFailedInitComponent({commit:s},e){s("removeComponent",e),s("addFailedInitComponent",e)}},mY={reset(s){Object.assign(s,FC())},setKlippyConnected(s){y.set(s,"klippy_connected",!0)},setKlippyState(s,e){y.set(s,"klippy_state",e)},setKlippyStateTimer(s,e){y.set(s,"klippy_state_timer",e)},setKlippyMessage(s,e){y.set(s,"klippy_message",e)},setKlippyDisconnected(s){y.set(s,"klippy_connected",!1),y.set(s,"klippy_state","disconnected"),y.set(s,"klippy_message","Disconnected...")},setKlippyShutdown(s){y.set(s,"klippy_state","shutdown"),y.set(s,"klippy_message","Shutdown...")},setCpuTemp(s,e){y.set(s,"cpu_temp",e)},setMoonrakerStats(s,e){y.set(s,"moonraker_stats",e)},setNetworkStats(s,e){y.set(s,"network_stats",e)},setCpuStats(s,e){y.set(s,"system_cpu_usage",e)},setKlippyConnectedTimer(s,e){y.set(s,"klippy_connected_timer",e)},setProcStats(s,e){y.set(s,"cpu_temp",e.cpu_temp),y.set(s,"moonraker_stats",e.moonraker_stats)},setConnectionId(s,e){y.set(s,"connection_id",e)},setData(s,e){"requestParams"in e&&delete e.requestParams,Object.entries(e).forEach(([t,r])=>{y.set(s,t,r)})},saveDbNamespaces(s,e){y.set(s,"dbNamespaces",e)},setConfig(s,e){y.set(s,"config",e)},setConsoleClearedThisSession(s){y.set(s,"console_cleared_this_session",!0)},clearGcodeStore(s){y.set(s,"events",[])},setGcodeStore(s,e){e.length>=yo&&(e=e.slice(e.length-yo)),e.forEach(t=>{const r=new Date(t.time*1e3);let i=sf(t.message),n=t.type;n==="command"&&(i='<a class="command text--blue">'+i+"</a>"),n==="response"&&(t.message.startsWith("// action:")?n="action":t.message.startsWith("// debug:")&&(n="debug")),s.events.push({date:r,message:t.message,formatMessage:i,type:n})})},addEvent(s,e){var t;["command","autocomplete"].includes(e.type)&&((t=s.events[s.events.length-1])==null?void 0:t.type)==="autocomplete"&&s.events.pop(),s.events.push({date:e.date,message:e.message,formatMessage:e.formatMessage,type:e.type}),s.events.length>=yo&&(s.events=s.events.slice(s.events.length-yo))},setSystemInfo(s,e){y.set(s,"system_info",e)},setThrottledState(s,e){e&&"bits"in e&&y.set(s.throttled_state,"bits",e.bits),e&&"flags"in e&&y.set(s.throttled_state,"flags",e.flags)},setSystemBootAt(s,e){y.set(s,"system_boot_at",e)},addRootDirectory(s,e){s.registered_directories.push(e.name)},updateServiceState(s,e){var r;const t=Object.keys(e)[0];(r=s.system_info)!=null&&r.service_state&&y.set(s.system_info.service_state,t,e[t])},addFailedInitComponent(s,e){const t=s.failed_init_components;t.includes(e)||t.push(e),y.set(s,"failed_init_components",t)},removeComponent(s,e){const t=s.components,r=t.indexOf(e);r!==-1&&(t.splice(r,1),y.set(s,"components",t))}},hY={getConsoleEvents:s=>(e=!0,t=500)=>{var i;const r=(i=[...s.events].slice(t*-1))!=null?i:[];if(r.length<20&&!s.console_cleared_this_session){const n=r.length?r[0].date:new Date;let a="";a+='- Type <a class="command text--blue">HELP</a> to get a list of available commands.\n',a+='- Click on the "?" button to get a searchable list.\n',a+="- Commands in the console are clickable and will be placed into the input field.\n",a+="- Use the tab key to complete your inputs. If there are several options, a list is displayed.\n",a+="- Use the ⇵ arrow keys to navigate through the previous entries.\n",r.unshift({date:n,message:a,formatMessage:sf(a),type:"response"})}return e?r.reverse():r},getConfig:s=>(e,t)=>{var i,n;const r=(n=(i=s.config)==null?void 0:i.config)!=null?n:{};return e in r&&t in r[e]?r[e][t]:null},getHostStats:(s,e,t,r)=>{var n,a,o,l,u,c,d,m,h,f,p,v,C,P,M,F,O,$,D,V,N,W,G,te,X,q,z,K,Q,re,R,B,T,A,H,ee;let i=null;if("system_info"in s){let ie=null;(n=t.printer)!=null&&n.software_version&&(ie=(a=t.printer)==null?void 0:a.software_version.split("-").slice(0,4).join("-")),(o=t.printer)!=null&&o.app_name&&(ie=((l=t.printer)==null?void 0:l.app_name)+" "+ie);let ue=null;if((c=(u=s.system_info)==null?void 0:u.python)!=null&&c.version_string){const w$=(m=(d=s.system_info)==null?void 0:d.python)==null?void 0:m.version_string.indexOf(" ");ue=(f=(h=s.system_info)==null?void 0:h.python)==null?void 0:f.version_string.slice(0,w$+1)}const be=(C=(v=(p=s.system_info)==null?void 0:p.cpu_info)==null?void 0:v.cpu_count)!=null?C:1,Se=Math.round(((M=(P=t.printer.system_stats)==null?void 0:P.sysload)!=null?M:0)*100)/100,rt=Math.round(Se/be*100);let Pt="primary";rt>95?Pt="error":rt>80&&(Pt="warning");let jt=null,oi=null;const yn=((O=(F=t.printer.system_stats)==null?void 0:F.memavail)!=null?O:0)*1024,Ms=((V=(D=($=s.system_info)==null?void 0:$.cpu_info)==null?void 0:D.total_memory)!=null?V:0)*1024;yn>0&&Ms>0?(jt=Xe(Ms-yn)+" / "+Xe(Ms),oi=Math.round((Ms-yn)/Ms*100)):Ms&&(jt=Xe(Ms));let Dd="primary";oi&&oi>95?Dd="error":oi&&oi>80&&(Dd="warning");let Td=r["printer/getHostTempSensor"];Td===null&&s.cpu_temp!==null&&(Td={temperature:(N=s.cpu_temp)==null?void 0:N.toFixed(0),measured_min_temp:null,measured_max_temp:null}),i={cpuName:(te=(G=(W=s.system_info)==null?void 0:W.cpu_info)==null?void 0:G.processor)!=null?te:null,cpuDesc:(z=(q=(X=s.system_info)==null?void 0:X.cpu_info)==null?void 0:q.cpu_desc)!=null?z:null,bits:(re=(Q=(K=s.system_info)==null?void 0:K.cpu_info)==null?void 0:Q.bits)!=null?re:null,version:ie,pythonVersion:ue,os:(T=(B=(R=s.system_info)==null?void 0:R.distribution)==null?void 0:B.name)!=null?T:null,release_info:(ee=(H=(A=s.system_info)==null?void 0:A.distribution)==null?void 0:H.release_info)!=null?ee:null,load:Se,loadPercent:rt<100?rt:100,loadProgressColor:Pt,memoryFormat:jt,memUsed:Xe(Ms-yn),memAvail:Xe(yn),memTotal:Xe(Ms),memUsage:oi,memUsageColor:Dd,tempSensor:Td}}return i},getCpuUsage:s=>"cpu"in s.system_cpu_usage?Math.round(s.system_cpu_usage.cpu):null,getNetworkInterfaces:s=>{const e={};return Object.keys(s.network_stats).forEach(t=>{var r,i,n,a,o;t!=="lo"&&(t in((i=(r=s.system_info)==null?void 0:r.network)!=null?i:{})||t.startsWith("can"))&&(e[t]={...s.network_stats[t]},(n=s.system_info)!=null&&n.network&&t in((o=(a=s.system_info)==null?void 0:a.network)!=null?o:{})&&(e[t].details={...s.system_info.network[t]}))}),e},getThrottledStateFlags:s=>{let e=s.throttled_state.flags.filter(t=>t!=="?");return e=e.map(t=>(t=t.replace(/ /g,"").replace(/-/g,""),t.charAt(0).toUpperCase()+t.slice(1))),e}},pY={reset({commit:s}){s("reset")},init(){y.$socket.emit("machine.device_power.devices",{},{action:"server/power/getDevices"})},async getDevices({commit:s,dispatch:e},t){t.error||await s("setDevices",t.devices),await e("socket/removeInitModule","server/power/init",{root:!0})},getStatus({commit:s},e){e.error||s("setStatus",e)},responseToggle({commit:s},e){"requestParams"in e&&delete e.requestParams;for(const[t,r]of Object.entries(e))s("setStatus",{device:t,status:r})}},fY={reset(s){Object.assign(s,DC())},setDevices(s,e){y.set(s,"devices",e)},setStatus(s,e){const t=s.devices.findIndex(r=>r.device===e.device);t>=0&&y.set(s.devices[t],"status",e.status)}},gY={getDevices:s=>s.devices},DC=()=>({devices:[]}),_Y=DC(),vY={namespaced:!0,state:_Y,getters:gY,actions:pY,mutations:fY},bY={reset({commit:s}){s("reset")},init(){y.$socket.emit("machine.update.status",{},{action:"server/updateManager/onUpdateStatus"})},async onUpdateStatus({commit:s,dispatch:e},t){var r,i;await s("resetRepos");for(const n of Object.keys(t.version_info)){const a=(r=t.version_info[n])!=null?r:{},o=(i=a.configured_type)!=null?i:null;if(["git_repo","zip"].includes(o)){await s("storeGitRepo",{...a,name:n});continue}if(["web","web_beta","python"].includes(o)){await s("storeWebRepo",{...a,name:n});continue}n==="system"&&await s("updateSystem",{...a})}await e("socket/removeInitModule","server/updateManager/init",{root:!0})}},yY={reset(s){Object.assign(s,TC())},resetRepos(s){y.set(s,"git_repos",[]),y.set(s,"web_repos",[]),y.set(s,"system",{package_count:0,package_list:[]})},storeGitRepo(s,e){const t=[...s.git_repos];t.push({...e}),y.set(s,"git_repos",t)},storeWebRepo(s,e){const t=[...s.web_repos];t.push({...e}),y.set(s,"web_repos",t)},updateSystem(s,e){const t={...s.system};t.package_count=e.package_count,t.package_list=e.package_list,y.set(s,"system",t)},addUpdateResponse(s,e){s.updateResponse.application!==e.application&&y.set(s.updateResponse,"application",e.application),s.updateResponse.complete!==e.complete&&y.set(s.updateResponse,"complete",e.complete),"complete"in e&&e.complete&&y.$socket.emit("machine.update.status",{refresh:!1},{action:"server/updateManager/onUpdateStatus"}),s.updateResponse.messages.push({date:new Date,message:e.message})},resetUpdateResponse(s){y.set(s,"updateResponse",{application:"",complete:!0,messages:[]})}},CY={getUpdateManagerList(s){const e=[];return s.git_repos.forEach(t=>{e.push({name:t.name,type:"git",data:{...t}})}),s.web_repos.forEach(t=>{e.push({name:t.name,type:"web",data:{...t}})}),Ft(e,"name")}},TC=()=>({busy:!1,github_rate_limit:null,github_requests_remaining:null,github_limit_reset_time:null,git_repos:[],web_repos:[],system:{package_count:0,package_list:[]},updateResponse:{application:"",complete:!0,messages:[]}}),$Y=TC(),xY={namespaced:!0,state:$Y,getters:CY,actions:bY,mutations:yY},wY={reset({commit:s}){s("reset")},init(){y.$socket.emit("server.history.list",{start:0,limit:50,max:100},{action:"server/history/getHistory"}),y.$socket.emit("server.history.totals",{},{action:"server/history/getTotals"})},getTotals({commit:s},e){var r;s("setTotals",e.job_totals);const t=(r=e.auxiliary_totals)!=null?r:[];t.length&&s("setAuxiliaryTotals",t)},async getHistory({commit:s,dispatch:e,state:t},r){var o,l,u,c,d,m,h,f,p,v,C;"requestParams"in r&&((l=(o=r.requestParams)==null?void 0:o.start)!=null?l:0)===0&&s("resetJobs"),(u=r.jobs)==null||u.forEach(P=>{t.jobs.findIndex(M=>M.job_id===P.job_id)===-1&&s("addJob",P)});const i=(d=(c=r.requestParams)==null?void 0:c.start)!=null?d:0,n=(h=(m=r.requestParams)==null?void 0:m.limit)!=null?h:50,a=(p=(f=r.requestParams)==null?void 0:f.max)!=null?p:null;if(n>0&&(a===null||a>i+n)&&((v=r.jobs)==null?void 0:v.length)===n){y.$socket.emit("server.history.list",{start:i+n,limit:n,max:a},{action:"server/history/getHistory"});return}((C=r.jobs)==null?void 0:C.length)<n&&(e("socket/removeLoading",{name:"historyLoadAll"},{root:!0}),s("setAllLoaded")),e("loadHistoryNotes")},loadHistoryNotes({dispatch:s,rootState:e}){var t;(t=e.server)!=null&&t.dbNamespaces.includes("history_notes")?y.$socket.emit("server.database.get_item",{namespace:"history_notes"},{action:"server/history/initHistoryNotes"}):s("socket/removeInitModule","server/history/init",{root:!0})},async initHistoryNotes({commit:s,dispatch:e},t){const r=Object.keys(t.value);for(const i of r){const n=t.value[i];await s("setHistoryNotes",{job_id:i,text:n.text})}await e("socket/removeInitModule","server/history/init",{root:!0})},getChanged({commit:s},e){e.action==="added"?s("addJob",e.job):e.action==="finished"&&s("updateJob",e.job),y.$socket.emit("server.history.totals",{},{action:"server/history/getTotals"})},getDeletedJobs({commit:s},e){"deleted_jobs"in e&&Array.isArray(e.deleted_jobs)&&e.deleted_jobs.forEach(t=>{s("destroyJob",t)})},saveHistoryNote({commit:s},e){y.$socket.emit("server.database.post_item",{namespace:"history_notes",key:e.job_id,value:{text:e.note}}),s("setHistoryNotes",{job_id:e.job_id,text:e.note})}},SY={reset(s){Object.assign(s,OC())},resetJobs(s){y.set(s,"jobs",[])},setTotals(s,e){y.set(s,"job_totals",e)},setAuxiliaryTotals(s,e){y.set(s,"auxiliary_totals",e)},setHistoryNotes(s,e){const t=s.jobs.find(r=>r.job_id===e.job_id);t&&y.set(t,"note",e.text)},addJob(s,e){const t=[...s.jobs];t.push(e),y.set(s,"jobs",t)},updateJob(s,e){const t=s.jobs.findIndex(r=>r.job_id===e.job_id);t!==-1&&y.set(s.jobs,t,e)},destroyJob(s,e){const t=s.jobs.findIndex(r=>r.job_id===e);t!==-1&&s.jobs.splice(t,1)},setAllLoaded(s){y.set(s,"all_loaded",!0)}},PY={getTotalPrintTime(s){let e=0;return s.jobs.forEach(t=>{e+=t.print_duration}),e},getTotalCompletedPrintTime(s){let e=0;return s.jobs.forEach(t=>{t.status==="completed"&&(e+=t.print_duration)}),e},getLongestPrintTime(s){let e=0;return s.jobs.forEach(t=>{t.print_duration>e&&(e=t.print_duration)}),e},getTotalFilamentUsed(s){let e=0;return s.jobs.forEach(t=>{e+=t.filament_used}),e},getTotalJobsCount(s){return s.jobs.length},getTotalCompletedJobsCount(s){return s.jobs.filter(e=>e.status==="completed").length},getAvgPrintTime(s,e){const t=e.getTotalCompletedPrintTime,r=e.getTotalCompletedJobsCount;return t>0&&r>0?Math.round(t/r):0},getPrintStatus:s=>e=>{var t;if(s.jobs.length){const r=s.jobs.find(i=>i.job_id===e);return(t=r==null?void 0:r.status)!=null?t:""}return""},getPrintJobById:s=>e=>{if(s.jobs.length!==0)return s.jobs.find(t=>t.job_id===e)},getPrintJobsForGcodes:s=>(e,t,r,i,n)=>{if(s.jobs.length===0)return[];if(i)return s.jobs.filter(o=>{var l;return((l=o.metadata)==null?void 0:l.uuid)===i});const a=s.jobs.filter(o=>{var l,u,c;return((l=o.metadata)==null?void 0:l.size)===r&&Math.round(((c=(u=o.metadata)==null?void 0:u.modified)!=null?c:0)*1e3)===t});return a.length?a:n?a.filter(o=>o.job_id===n):[]},getPrintStatusByFilename:s=>(e,t)=>{var r;if(s.jobs.length){const i=s.jobs.find(n=>{var a,o;return n.filename===e&&Math.round(((o=(a=n.metadata)==null?void 0:a.modified)!=null?o:0)*1e3)===t});return(r=i==null?void 0:i.status)!=null?r:""}return""},getPrintStatusIconColor:()=>s=>{switch(s){case"in_progress":return"blue accent-3";case"completed":return"green";case"cancelled":return"red";default:return"orange"}},getPrintStatusTextColor:()=>s=>{switch(s){case"in_progress":return"blue--text";case"completed":return"green--text";case"cancelled":return"red--text";default:return"orange--text"}},getPrintStatusIcon:()=>s=>{switch(s){case"in_progress":return fS;case"completed":return xw;case"cancelled":return kw;default:return Jn}},getFilteredJobList:(s,e,t)=>{const r=t.gui.view.history.hidePrintStatus;return s.jobs.filter(i=>!r.includes(i.status))}},OC=()=>({jobs:[],job_totals:{total_jobs:0,total_time:0,total_print_time:0,total_filament_used:0,longest_job:0,longest_print:0},auxiliary_totals:[],all_loaded:!1}),DY=OC(),TY={namespaced:!0,state:DY,getters:PY,actions:wY,mutations:SY},OY={reset({commit:s}){s("reset")},init(){y.$socket.emit("machine.timelapse.get_settings",{},{action:"server/timelapse/initSettings"}),y.$socket.emit("machine.timelapse.lastframeinfo",{},{action:"server/timelapse/initLastFrameinfo"})},async initSettings({commit:s,dispatch:e},t){"requestParams"in t&&delete t.requestParams,await s("setSettings",t),await e("socket/removeInitModule","server/timelapse/init",{root:!0})},initLastFrameinfo({commit:s},e){s("setLastFrame",{count:e.framecount,file:e.lastframefile})},getEvent({commit:s},e){switch(e.action){case"newframe":s("setLastFrame",{count:parseInt(e.frame),file:e.framefile});break;case"render":e.status==="error"?(y.$toast.error(e.msg),s("resetSnackbar")):s("setRenderStatus",e);break;default:window.console.log("unknown timelapse event",e)}},saveSetting(s,e){y.$socket.emit("machine.timelapse.post_settings",e,{action:"server/timelapse/initSettings"})},updateCamSettings({dispatch:s,state:e},t){e.settings.camera===t.oldName&&s("saveSetting",{camera:t.newName})},resetSnackbar({commit:s}){s("resetSnackbar")}},MY={reset(s){Object.assign(s,MC())},setSettings(s,e){Object.keys(e).forEach(t=>{t in s.settings&&s.settings[t]!==e[t]&&y.set(s.settings,t,e[t])})},setLastFrame(s,e){y.set(s.lastFrame,"count",e.count),y.set(s.lastFrame,"file",e.file)},setRenderStatus(s,e){var t,r;y.set(s,"rendering",{status:e.status,progress:(t=e.progress)!=null?t:0,filename:(r=e.filename)!=null?r:""})},resetSnackbar(s){y.set(s,"rendering",{status:"",progress:0,filename:""})}},kY={},MC=()=>({settings:{enabled:!0,camera:"",mode:"layermacro",autorender:!0,autorenderOnce:!1,saveframes:!1,stream_delay_compensation:.05,gcode_verbose:!0,parkhead:!1,parkpos:"back_left",park_custom_pos_x:0,park_custom_pos_y:0,park_custom_pos_dz:0,park_travel_speed:100,park_retract_speed:15,park_retract_distance:1,park_extrude_speed:15,park_extrude_distance:1,park_time:.1,fw_retract:!1,hyperlapse_cycle:30,constant_rate_factor:23,output_framerate:30,pixelformat:"yuv420p",extraoutputparams:"",variable_fps:!1,targetlength:60,variable_fps_min:5,variable_fps_max:60,rotation:0,duplicatelastframe:0,previewimage:!0,time_format_code:"%Y%m%d_%H%M",blockedsettings:[]},lastFrame:{count:0,file:""},rendering:{status:"",progress:0,filename:""}}),EY=MC(),LY={namespaced:!0,state:EY,getters:kY,actions:OY,mutations:MY},AY={reset({commit:s}){s("reset")},init(){y.$socket.emit("server.job_queue.status",{},{action:"server/jobQueue/getStatus"})},getEvent({commit:s},e){"updated_queue"in e&&e.updated_queue!==null&&s("setQueuedJobs",e.updated_queue),"queue_state"in e&&s("setQueueState",e.queue_state)},async getStatus({commit:s,dispatch:e},t){"queued_jobs"in t&&s("setQueuedJobs",t.queued_jobs),"queue_state"in t&&s("setQueueState",t.queue_state),await e("socket/removeInitModule","server/jobQueue/init",{root:!0})},async addToQueue(s,e){y.$socket.emit("server.job_queue.post_job",{filenames:e})},changeCount({dispatch:s,getters:e},t){const r=e.getJobs,i=r.findIndex(n=>n.job_id===t.job_id);i!==-1&&(r[i].combinedIds=Array(t.count-1).fill(t.job_id),s("sendNewQueueList",{jobs:r}))},changePosition({dispatch:s,getters:e},t){const r=e.getJobs,i=r.splice(t.oldIndex,1)[0];r.splice(t.newIndex,0,i),s("sendNewQueueList",{jobs:r})},startByJobId({dispatch:s,getters:e},t){const r=e.getJobs,i=r.findIndex(a=>a.job_id===t);if(i===-1)return;const n=r.splice(i,1)[0];r.splice(0,0,n),s("sendNewQueueList",{jobs:r,printStart:!0})},sendNewQueueList(s,e){const t=e.jobs.map(i=>{var a,o;const n=((o=(a=i.combinedIds)==null?void 0:a.length)!=null?o:0)+1;return n===1?i.filename:Array(n).fill(i.filename)}).flat(),r={};e.printStart&&(r.action="server/jobQueue/start"),y.$socket.emit("server.job_queue.post_job",{filenames:t,reset:!0},r)},deleteFromQueue(s,e){y.$socket.emit("server.job_queue.delete_job",{job_ids:e})},clearQueue(){y.$socket.emit("server.job_queue.delete_job",{all:!0})},start(){y.$socket.emit("server.job_queue.start",{},{loading:"startJobqueue"})},pause(){y.$socket.emit("server.job_queue.pause",{},{loading:"pauseJobqueue"})}},FY={reset(s){Object.assign(s,kC())},setQueuedJobs(s,e){y.set(s,"queued_jobs",e)},setQueueState(s,e){y.set(s,"queue_state",e)}},RY={getJobs:(s,e,t,r)=>{const i=[];return s.queued_jobs.forEach(n=>{var l;const a={...n};if(i.length&&i[i.length-1].filename===a.filename){(l=i[i.length-1].combinedIds)==null||l.push(a.job_id);return}const o=r["files/getFile"]("gcodes/"+a.filename);o!=null&&o.metadataPulled||y.$socket.emit("server.files.metadata",{filename:a.filename},{action:"files/getMetadata"}),a.metadata=o,a.combinedIds=[],i.push(a)}),i},getJobsCount:s=>s.queued_jobs.length,getSmallThumbnail:(s,e,t,r)=>i=>{var n,a,o,l;if((a=(n=i==null?void 0:i.metadata)==null?void 0:n.thumbnails)!=null&&a.length){const u=(o=i==null?void 0:i.metadata)==null?void 0:o.thumbnails.find(d=>d.width>=Yt&&d.width<=Jt&&d.height>=Yt&&d.height<=Jt),c=i.filename.lastIndexOf("/")!==-1?"gcodes/"+i.filename.slice(0,i.filename.lastIndexOf("/")):"gcodes";if(u&&"relative_path"in u)return r["socket/getUrl"]+"/server/files/"+Ie(c)+"/"+Ie(u.relative_path)+"?timestamp="+((l=i.metadata)==null?void 0:l.modified.getTime())}return""},getBigThumbnail:(s,e,t,r)=>i=>{var n,a,o,l;if((a=(n=i==null?void 0:i.metadata)==null?void 0:n.thumbnails)!=null&&a.length){const u=(o=i==null?void 0:i.metadata)==null?void 0:o.thumbnails.find(d=>d.width>=Ls),c=i.filename.lastIndexOf("/")!==-1?"gcodes/"+i.filename.slice(0,i.filename.lastIndexOf("/")):"gcodes";if(u&&"relative_path"in u)return r["socket/getUrl"]+"/server/files/"+Ie(c)+"/"+Ie(u.relative_path)+"?timestamp="+((l=i.metadata)==null?void 0:l.modified.getTime())}return""}},kC=()=>({queued_jobs:[],queue_state:""}),HY=kC(),jY={namespaced:!0,state:HY,getters:RY,actions:AY,mutations:FY},IY={reset({commit:s}){s("reset")},init(){y.$socket.emit("server.announcements.list",{},{action:"server/announcements/getList"})},async getList({commit:s,dispatch:e},t){if("entries"in t){const r=t.entries.map(i=>{const n=new Date(i.date*1e3),a=t.date_dismissed?new Date(i.date_dismissed*1e3):null,o=t.dismiss_wake?new Date(i.dismiss_wake*1e3):null;return{...i,date:n,date_dismissed:a,dismiss_wake:o}});await s("setEntries",r)}"feeds"in t&&await s("setFeeds",t.feeds),await e("socket/removeInitModule","server/announcements/init",{root:!0})},getDismissed({commit:s},e){s("setDismissed",{entry_id:e.entry_id,status:!0})},getWaked({commit:s},e){s("setDismissed",{entry_id:e.entry_id,status:!1})},close(s,e){y.$socket.emit("server.announcements.dismiss",{entry_id:e.entry_id})},dismiss(s,e){y.$socket.emit("server.announcements.dismiss",{entry_id:e.entry_id,wake_time:e.time})}},NY={reset(s){Object.assign(s,EC())},setEntries(s,e){y.set(s,"entries",e)},setFeeds(s,e){y.set(s,"feeds",e)},setDismissed(s,e){const t=[...s.entries],r=t.findIndex(i=>i.entry_id===e.entry_id);r>-1&&(t[r].dismissed=e.status,e.status?t[r].date_dismissed=new Date:(t[r].date_dismissed=null,t[r].dismiss_wake=null)),y.set(s,"entries",t)}},VY={getAnnouncements:s=>s.entries.filter(e=>!e.dismissed)},EC=()=>({entries:[],feeds:[]}),BY=EC(),UY={namespaced:!0,state:BY,getters:VY,actions:IY,mutations:NY};function On(s){var e,t,r,i;return((t=(e=s.error)==null?void 0:e.message)!=null?t:null)!==null?(y.$toast.error((i=(r=s.error)==null?void 0:r.message)!=null?i:"unknown spoolman error"),null):"response"in s?s.response:s}const WY={reset({commit:s}){s("reset")},init({dispatch:s}){y.$socket.emit("server.spoolman.get_spool_id",{},{action:"server/spoolman/getActiveSpoolId"}),y.$socket.emit("server.spoolman.proxy",{request_method:"GET",path:"/v1/info",use_v2_response:!0},{action:"server/spoolman/getInfo"}),y.$socket.emit("server.spoolman.proxy",{request_method:"GET",path:"/v1/health",use_v2_response:!0},{action:"server/spoolman/getHealth"}),y.$socket.emit("server.spoolman.proxy",{request_method:"GET",path:"/v1/vendor",use_v2_response:!0},{action:"server/spoolman/getVendors"}),s("socket/addInitModule","server/spoolman/getActiveSpoolId",{root:!0}),s("socket/addInitModule","server/spoolman/getHealth",{root:!0}),s("socket/addInitModule","server/spoolman/getInfo",{root:!0}),s("socket/addInitModule","server/spoolman/getVendors",{root:!0}),s("socket/removeInitModule","server/spoolman/init",{root:!0})},getActiveSpoolId({commit:s,dispatch:e},t){if(s("setActiveSpoolId",t.spool_id),e("socket/removeInitModule","server/spoolman/getActiveSpoolId",{root:!0}),[null,0].includes(t.spool_id)){s("setActiveSpool",null);return}y.$socket.emit("server.spoolman.proxy",{request_method:"GET",use_v2_response:!0,path:"/v1/spool/".concat(t.spool_id)},{action:"server/spoolman/getActiveSpool"})},getActiveSpool({commit:s},e){"requestParams"in e&&delete e.requestParams,e=On(e),e!==null&&s("setActiveSpool",e)},getHealth({commit:s,dispatch:e},t){delete t.requestParams,e("socket/removeInitModule","server/spoolman/getHealth",{root:!0}),t=On(t),t!==null&&s("setHealth",t.status)},getInfo({commit:s,dispatch:e},t){delete t.requestParams,e("socket/removeInitModule","server/spoolman/getInfo",{root:!0}),t=On(t),t!==null&&s("setInfo",t)},getVendors({commit:s,dispatch:e},t){delete t.requestParams,e("socket/removeInitModule","server/spoolman/getVendors",{root:!0}),t=On(t),t!==null&&s("setVendors",Object.entries(t).map(r=>r))},refreshSpools({dispatch:s}){y.$socket.emit("server.spoolman.proxy",{request_method:"GET",path:"/v1/spool"},{action:"server/spoolman/getSpools"}),s("socket/addLoading","refreshSpools",{root:!0})},getSpools({commit:s,dispatch:e},t){if("requestParams"in t&&delete t.requestParams,e("socket/removeLoading","refreshSpools",{root:!0}),t=On(t),t===null)return;const r=Object.entries(t).map(i=>i[1]);s("setSpools",r)},setActiveSpool(s,e){const t={};e!==null&&(t.spool_id=e),y.$socket.emit("server.spoolman.post_spool_id",t)},refreshActiveSpool({state:s}){s.active_spool_id!==null&&y.$socket.emit("server.spoolman.proxy",{request_method:"GET",path:"/v1/spool/".concat(s.active_spool_id)},{action:"server/spoolman/getActiveSpool"})}},zY={reset(s){Object.assign(s,LC())},setActiveSpoolId(s,e){y.set(s,"active_spool_id",e)},setActiveSpool(s,e){y.set(s,"active_spool",e)},setHealth(s,e){y.set(s,"health",e)},setInfo(s,e){y.set(s,"info",e)},setVendors(s,e){y.set(s,"vendors",e)},setSpools(s,e){y.set(s,"spools",e)}},GY={},LC=()=>({health:"",info:{automatic_backups:!1,backups_dir:"",data_dir:"",debug_mode:!1,version:""},active_spool_id:null,active_spool:null,vendors:[],feeds:[]}),ZY=LC(),qY={namespaced:!0,state:ZY,getters:GY,actions:WY,mutations:zY},XY={reset({commit:s}){s("reset")},init(){y.$socket.emit("server.sensors.list",{},{action:"server/sensor/getSensors"})},getSensors({commit:s,dispatch:e},t){s("setSensors",t.sensors),e("socket/removeInitModule","server/sensor/init",{root:!0})},updateSensors({commit:s},e){Object.keys(e).forEach(t=>{s("updateSensor",{key:t,value:e[t]})})}},YY={reset(s){Object.assign(s,AC())},setSensors(s,e){y.set(s,"sensors",e)},updateSensor(s,e){e.key in s.sensors&&y.set(s.sensors[e.key],"values",e.value)}},JY={getSensors:s=>Object.keys(s.sensors)},AC=()=>({sensors:{}}),KY=AC(),QY={namespaced:!0,state:KY,getters:JY,actions:XY,mutations:YY},FC=()=>({klippy_connected:!1,klippy_connected_timer:null,klippy_state:"",klippy_state_timer:null,klippy_message:"",components:[],failed_components:[],failed_init_components:[],warnings:[],registered_directories:[],events:[],config:{},system_info:null,system_boot_at:null,cpu_temp:0,moonraker_stats:null,throttled_state:{bits:0,flags:[]},network_stats:{},system_cpu_usage:{},dbNamespaces:[],websocket_count:0,moonraker_version:""}),eJ=FC(),tJ={namespaced:!0,state:eJ,getters:hY,actions:dY,mutations:mY,modules:{power:vY,updateManager:xY,history:TY,timelapse:LY,jobQueue:jY,announcements:UY,spoolman:qY,sensor:QY}},sJ={reset({commit:s}){s("reset"),s("tempHistory/reset"),s("socket/clearLoadings",null,{root:!0})},init({dispatch:s}){window.console.debug("init printer"),s("reset"),s("socket/addInitModule","printer/info",{root:!0}),s("socket/addInitModule","printer/initSubscripts",{root:!0}),s("socket/addInitModule","printer/initTempHistory",{root:!0}),s("socket/addInitModule","server/gcode_store",{root:!0}),y.$socket.emit("printer.info",{},{action:"printer/getInfo"}),y.$socket.emit("server.gcode_store",{},{action:"server/getGcodeStore"}),s("initSubscripts")},getInfo({commit:s,dispatch:e},t){var r;s("server/setData",{klippy_state:t.state,klippy_message:t.state_message},{root:!0}),s("setData",{app_name:(r=t.app)!=null?r:null,hostname:t.hostname,software_version:t.software_version,cpu_info:t.cpu_info}),e("socket/removeInitModule","printer/info",{root:!0})},async initSubscripts({dispatch:s}){const e=await y.$socket.emitAndWait("printer.objects.list");let t={};const r=["menu"];if(e.objects.forEach(i=>{const n=i.split(" ");r.includes(n[0])||(t={...t,[i]:null})}),Object.keys(t).length>0){const i=await y.$socket.emitAndWait("printer.objects.subscribe",{objects:t},{});"screws_tilt_adjust"in i.status&&(i.status.screws_tilt_adjust.error=!1,i.status.screws_tilt_adjust.results={}),s("getData",i),setTimeout(()=>{s("initExtruderCanExtrude")},200)}y.$socket.emit("server.temperature_store",{include_monitors:!0},{action:"printer/tempHistory/init"}),s("socket/removeInitModule","printer/initSubscripts",{root:!0})},getData({commit:s,dispatch:e,state:t},r){var i,n,a,o,l,u,c,d,m,h;"status"in r&&(r=r.status),"requestParams"in r&&delete r.requestParams,"webhooks"in r&&(this.dispatch("server/getData",{klippy_state:r.webhooks.state,klippy_message:r.webhooks.state_message},{root:!0}),delete r.webhooks),"bed_mesh"in t&&"bed_mesh"in r&&"profiles"in r.bed_mesh&&(s("setBedMeshProfiles",r.bed_mesh.profiles),delete r.bed_mesh.profiles),(a=(n=(i=r.configfile)==null?void 0:i.settings)==null?void 0:n.printer)!=null&&a.kinematics&&e("gui/updateGcodeviewerCache",{kinematics:(u=(l=(o=r.configfile)==null?void 0:o.settings)==null?void 0:l.printer)==null?void 0:u.kinematics},{root:!0}),(c=r.toolhead)!=null&&c.axis_maximum&&e("gui/updateGcodeviewerCache",{axis_maximum:(d=r.toolhead)==null?void 0:d.axis_maximum},{root:!0}),(m=r.toolhead)!=null&&m.axis_minimum&&e("gui/updateGcodeviewerCache",{axis_minimum:(h=r.toolhead)==null?void 0:h.axis_minimum},{root:!0}),s("setData",r)},async initGcodes({commit:s}){const e=await y.$socket.emitAndWait("printer.objects.query",{objects:{gcode:["commands"]}},{});s("setData",e.status)},async initExtruderCanExtrude({dispatch:s,state:e}){const t=Object.keys(e).filter(n=>n.startsWith("extruder")),r={};t.forEach(n=>{r[n]=["can_extrude"]});const i=await y.$socket.emitAndWait("printer.objects.query",{objects:r},{});s("getData",i.status)},getEndstopStatus({commit:s},e){s("setEndstopStatus",e)},removeBedMeshProfile({commit:s},e){s("removeBedMeshProfile",e)},sendGcode({dispatch:s},e){if(s("server/addEvent",{message:e,type:"command"},{root:!0}),e.toLowerCase().trim()==="m112"){y.$socket.emit("printer.emergency_stop",{},{loading:"sendGcode"});return}y.$socket.emit("printer.gcode.script",{script:e},{loading:"sendGcode"})},clearScrewsTiltAdjust({commit:s}){s("clearScrewsTiltAdjust")}},rJ={reset(s){const e=HC();for(const t of Object.keys(s))!(t in e)&&t!=="tempHistory"&&delete s[t];for(const[t,r]of Object.entries(e))y.set(s,t,r)},setData(s,e){Object.keys(e).forEach(t=>{const r=e[t];if(typeof r!="object"||r===null||!(t in s)){y.set(s,t,r);return}typeof r=="object"&&Object.keys(r).forEach(i=>{y.set(s[t],i,r[i])})})},setBedMeshProfiles(s,e){"bed_mesh"in s&&y.set(s.bed_mesh,"profiles",e)},clearCurrentFile(s){y.set(s,"current_file",{})},setEndstopStatus(s,e){delete e.requestParams,y.set(s,"endstops",e)},removeBedMeshProfile(s,e){"bed_mesh "+e.name in s.configfile.config&&Object.assign(s.configfile.config["bed_mesh "+e.name],{deleted:!0})},clearScrewsTiltAdjust(s){y.set(s.screws_tilt_adjust,"error",!1),y.set(s.screws_tilt_adjust,"results",{})}},iJ={getPrintPercent:(s,e,t)=>{var i,n,a;switch((a=(n=(i=t==null?void 0:t.gui)==null?void 0:i.general)==null?void 0:n.calcPrintProgress)!=null?a:"file-relative"){case"file-relative":return e.getPrintPercentByFilepositionRelative;case"file-absolute":return e.getPrintPercentByFilepositionAbsolute;case"slicer":return e.getPrintPercentBySlicer;case"filament":return e.getPrintPercentByFilament;default:return e.getPrintPercentByFilepositionRelative}},getPrintPercentByFilepositionRelative:s=>{var e,t,r,i,n;if((e=s.current_file)!=null&&e.filename&&((t=s.current_file)!=null&&t.gcode_start_byte)&&((r=s.current_file)!=null&&r.gcode_end_byte)&&s.current_file.filename===s.print_stats.filename){if(s.virtual_sdcard.file_position<=s.current_file.gcode_start_byte)return 0;if(s.virtual_sdcard.file_position>=s.current_file.gcode_end_byte)return 1;const a=s.virtual_sdcard.file_position-s.current_file.gcode_start_byte,o=s.current_file.gcode_end_byte-s.current_file.gcode_start_byte;if(a>0&&o>0)return 1/o*a}return(n=(i=s.virtual_sdcard)==null?void 0:i.progress)!=null?n:0},getPrintPercentByFilepositionAbsolute:s=>{var e,t;return(t=(e=s.virtual_sdcard)==null?void 0:e.progress)!=null?t:0},getPrintPercentBySlicer:s=>{var e,t;return(t=(e=s.display_status)==null?void 0:e.progress)!=null?t:0},getPrintPercentByFilament:s=>{var r,i,n,a,o,l;const e=(i=(r=s.print_stats)==null?void 0:r.filament_used)!=null?i:null,t=(a=(n=s.current_file)==null?void 0:n.filament_total)!=null?a:null;if(e!==null&&t!==null){if(t==0)return 0;const u=e/t;return u>1?1:u}return(l=(o=s.virtual_sdcard)==null?void 0:o.progress)!=null?l:0},getPrintMaxLayers:s=>{var e,t,r,i,n,a,o;if(((r=(t=(e=s.print_stats)==null?void 0:e.info)==null?void 0:t.total_layer)!=null?r:null)!==null)return s.print_stats.info.total_layer;if((i=s.current_file)!=null&&i.layer_count)return s.current_file.layer_count;if(((n=s.current_file)==null?void 0:n.first_layer_height)!==void 0&&((a=s.current_file)==null?void 0:a.layer_height)!==void 0&&((o=s.current_file)==null?void 0:o.object_height)!==void 0){const l=Math.ceil((s.current_file.object_height-s.current_file.first_layer_height)/s.current_file.layer_height+1);return l>0?l:0}return 0},getPrintCurrentLayer:(s,e)=>{var t,r,i,n,a,o,l,u;if(((i=(r=(t=s.print_stats)==null?void 0:t.info)==null?void 0:r.current_layer)!=null?i:null)!==null)return s.print_stats.info.current_layer;if(((n=s.print_stats)==null?void 0:n.print_duration)>0&&((a=s.current_file)==null?void 0:a.first_layer_height)!==void 0&&((o=s.current_file)==null?void 0:o.layer_height)!==void 0){const c=(u=(l=s.gcode_move)==null?void 0:l.gcode_position[2])!=null?u:0,d=Math.ceil((c-s.current_file.first_layer_height)/s.current_file.layer_height+1);if(d>e.getPrintMaxLayers)return e.getPrintMaxLayers;if(d>0)return d}return 0},getPrinterObjects:s=>e=>{var r,i,n,a;const t=[];for(const[o,l]of Object.entries(s)){let u=o.substring(0,o.indexOf(" ")).trimEnd(),c=o.substring(o.indexOf(" ")+1).trimStart();o.indexOf(" ")===-1&&(u=c=o),e.includes(u)&&t.push({name:c,type:u,state:{...l},config:(i=(r=s.configfile)==null?void 0:r.config[o])!=null?i:{},settings:(a=(n=s.configfile)==null?void 0:n.settings[o.toLowerCase()])!=null?a:{}})}return t},getMacros:s=>{var a,o,l,u;const e=[],t=(o=(a=s.configfile)==null?void 0:a.settings)!=null?o:null,r=(u=(l=s.gcode)==null?void 0:l.commands)!=null?u:{},i="gcode_macro ",n=i.length;return Object.keys(s).filter(c=>c.toLowerCase().startsWith(i)).forEach(c=>{var v,C,P,M;const d=c.slice(n),m=(v=r[d.toUpperCase()])!=null?v:{};if(d.startsWith("_"))return;const h=c.toLowerCase(),f=(C=t[h])!=null?C:{};if("rename_existing"in f)return;const p=(P=s[c])!=null?P:{};e.push({name:d,description:(M=m==null?void 0:m.help)!=null?M:null,prop:f,params:k3(f),variables:p})}),Ft(e,"name")},getMacro:(s,e)=>t=>{const r=t.toLowerCase();return e.getMacros.find(i=>i.name.toLowerCase()===r)},getPartFanSpeed:s=>"fan"in s?s.fan.speed:0,getFans:(s,e)=>{const t=[],r=["temperature_fan","controller_fan","heater_fan","fan_generic","fan"],i=e.getPrinterObjects(r),n=["fan_generic","fan"];return i.foreach(a=>{var o;t.push({name:a.name,type:a.type,speed:(o=a.state.speed)!=null?o:0,controllable:n.includes(a.type)})}),t.sort((a,o)=>{if(a.controllable<o.controllable)return 1;if(a.controllable>o.controllable)return-1;const l=a.name.toUpperCase(),u=o.name.toUpperCase();return l<u?-1:l>u?1:0})},getLights:(s,e)=>{const t=[],r=["dotstar","led","neopixel","pca9533","pca9632"];return e.getPrinterObjects(r).filter(n=>!n.name.startsWith("_")).forEach(n=>{var h,f,p,v,C,P,M,F,O,$,D;let a="RGB",o=null;const l=(h=n.state.color_data)!=null?h:[];"color_order"in n.settings&&(typeof n.settings.color_order=="string"?a=n.settings.color_order:Array.isArray(n.settings.color_order)&&n.settings.color_order.length>0&&(a=n.settings.color_order[0])),n.type==="led"&&(a="","red_pin"in n.config&&(a+="R"),"green_pin"in n.config&&(a+="G"),"blue_pin"in n.config&&(a+="B"),"white_pin"in n.config&&(a+="W"));let u=(f=n.settings.initial_red)!=null?f:null;"initial_red"in n.config||(u=null);let c=(p=n.settings.initial_green)!=null?p:null;"initial_green"in n.config||(c=null);let d=(v=n.settings.initial_blue)!=null?v:null;"initial_blue"in n.config||(d=null);let m=(C=n.settings.initial_white)!=null?C:null;if("initial_white"in n.config||(m=null),n.type==="led"&&a.length===1){const V=(P=l[0])!=null?P:[];switch(a){case"R":o=(M=V[0])!=null?M:0;break;case"G":o=(F=V[1])!=null?F:0;break;case"B":o=(O=V[2])!=null?O:0;break;case"W":o=($=V[3])!=null?$:0;break}}t.push({name:n.name,type:n.type,chainCount:(D=n.settings.chain_count)!=null?D:1,colorOrder:a,initialRed:u,initialGreen:c,initialBlue:d,initialWhite:m,colorData:l,singleChannelTarget:o})}),t.sort((n,a)=>{const o=n.name.toUpperCase(),l=a.name.toUpperCase();return o<l?-1:o>l?1:0})},getMiscellaneous:s=>{var i,n,a,o,l,u;const e=[],t=["controller_fan","heater_fan","fan_generic","fan","output_pin","pwm_tool","pwm_cycle_time"],r=["fan_generic","fan"];for(const[c,d]of Object.entries(s)){const m=c.split(" ");if(t.includes(m[0])){const h=m.length>1?m[1]:m[0];if(!h.startsWith("_")){let f=r.includes(m[0].toLowerCase());const p=(n=(i=s.configfile)==null?void 0:i.settings[c.toLowerCase()])!=null?n:{},v="speed"in d?d.speed:"value"in d?d.value:0,C="rpm"in d?d.rpm:null;let P=f,M=1;m[0].toLowerCase()==="fan"&&(M=255),["output_pin","pwm_tool","pwm_cycle_time"].includes(m[0])&&(f=!0,P=!1,"pwm"in p&&(P=(a=p==null?void 0:p.pwm)!=null?a:!1),["pwm_tool","pwm_cycle_time"].includes(m[0])&&(P=!0),"scale"in p&&(M=(o=p==null?void 0:p.scale)!=null?o:1));const F={name:h,type:m[0],power:v,controllable:f,pwm:P,rpm:C,scale:M,object:d,config:p,off_below:void 0,max_power:void 0};"configfile"in s&&"settings"in s.configfile&&c.toLowerCase()in s.configfile.settings&&("off_below"in p&&(F.off_below=(l=p==null?void 0:p.off_below)!=null?l:0),"max_power"in p&&(F.max_power=(u=p==null?void 0:p.max_power)!=null?u:1)),e.push(F)}}}return e.sort((c,d)=>{if(c.type==="fan")return-1;if(d.type==="fan"||c.pwm<d.pwm)return 1;if(c.pwm>d.pwm)return-1;if(c.controllable<d.controllable)return 1;if(c.controllable>d.controllable)return-1;const m=c.name.toUpperCase(),h=d.name.toUpperCase();return m<h?-1:m>h?1:0})},getMiscellaneousSensors:s=>{var r;const e=[],t=["load_cell"];for(const[i,n]of Object.entries(s)){const a=i.split(" ");if(!t.includes(a[0]))continue;const o=a.length>1?a[1]:a[0];if(o.startsWith("_"))continue;const l={name:o,type:a[0],value:"value"in n?n.value:null,unit:"unit"in n?n.unit:""};a[0]=="load_cell"?e.push({...l,value:(r=n.force_g)!=null?r:NaN,unit:"g"}):e.push(l)}return e.sort((i,n)=>{if(i.type<n.type)return-1;if(i.type>n.type)return 1;if(i.unit<n.unit)return-1;if(i.unit>n.unit)return 1;const a=i.name.toUpperCase(),o=n.name.toUpperCase();return a<o?-1:a>o?1:0}),e},getAvailableHeaters:s=>{var e,t;return(t=(e=s.heaters)==null?void 0:e.available_heaters)!=null?t:[]},getAvailableSensors:s=>{var e,t;return(t=(e=s.heaters)==null?void 0:e.available_sensors)!=null?t:[]},getAvailableMonitors:s=>{var e,t;return(t=(e=s.heaters)==null?void 0:e.available_monitors)!=null?t:[]},getFilamentSensors:s=>{var r;const e=["filament_switch_sensor","filament_motion_sensor","hall_filament_width_sensor"],t=[];for(const[i,n]of Object.entries(s)){const a=i.split(" ");e.includes(a[0])&&t.push({type:a[0],name:(r=a[1])!=null?r:a[0],enabled:n.enabled,filament_detected:n.filament_detected,filament_diameter:n.Diameter})}return Ft(t,"name")},getMcus:(s,e)=>{const t=[];return Object.keys(s).forEach(r=>{var i,n,a,o,l,u,c,d,m,h,f,p;if(r==="mcu"||r.startsWith("mcu ")){const v=s[r];let C=((i=v.mcu_version)!=null?i:"unknown").split("-").slice(0,4).join("-");"app"in v&&v.app!=="Klipper"&&(C=v.app+" "+C);let P=0;(n=v.last_stats)!=null&&n.mcu_task_avg&&((a=v.last_stats)!=null&&a.mcu_task_stddev)&&(P=v.last_stats.mcu_task_avg+3*((o=v.last_stats)==null?void 0:o.mcu_task_stddev)/.0025);let M="primary";P>.95?M="error":P>.8&&(M="warning"),t.push({name:r,mcu_constants:v.mcu_constants,last_stats:v.last_stats,version:C,chip:(u=(l=v.mcu_constants)==null?void 0:l.MCU)!=null?u:null,freq:(d=(c=v.last_stats)==null?void 0:c.freq)!=null?d:null,freqFormat:O3((h=(m=v.last_stats)==null?void 0:m.freq)!=null?h:0),awake:(((p=(f=v.last_stats)==null?void 0:f.mcu_awake)!=null?p:0)/5).toFixed(2),load:P.toFixed(2),loadPercent:P<1?Math.round(P*100):100,loadProgressColor:M,tempSensor:e.getMcuTempSensor(r)})}}),t},getPrinterObject:s=>e=>e in s?s[e]:null,getPrinterConfigObjects:s=>e=>{var r;const t={};return(r=s.configfile)!=null&&r.settings&&Object.keys(s.configfile.settings).forEach(i=>{const n=i.split(" ");e.includes(n[0])&&(t[i]=s.configfile.settings[i])}),t},getHostTempSensor:(s,e)=>{const t=["rpi_temperature","temperature_host"],r=["temperature_sensor","temperature_fan"];let i=null;const n=e.getPrinterConfigObjects(r);return Object.keys(n).forEach(a=>{var u,c,d;const o=n[a],l=Object.keys(s).find(m=>m.toLowerCase()===a.toLowerCase())||"";if("sensor_type"in o&&t.includes(o.sensor_type)&&l in s){const m=s[l];i={temperature:(u=m.temperature)==null?void 0:u.toFixed(0),measured_min_temp:(c=m.measured_min_temp)==null?void 0:c.toFixed(1),measured_max_temp:(d=m.measured_max_temp)==null?void 0:d.toFixed(1)}}}),i},getMcuTempSensors:(s,e)=>{const t=["temperature_sensor","temperature_fan"],r=[],i=e.getPrinterConfigObjects(t);return Object.keys(i).forEach(n=>{const a=i[n],o=Object.keys(s).find(l=>l.toLowerCase()===n.toLowerCase())||"";"sensor_type"in a&&a.sensor_type==="temperature_mcu"&&"sensor_mcu"in a&&r.push({key:o,settings:a,object:o in s?s[o]:{}})}),r},getMcuTempSensor:(s,e)=>t=>{let r=null;return e.getMcuTempSensors.forEach(n=>{var a,o,l,u,c,d;t.endsWith((a=n.settings)==null?void 0:a.sensor_mcu)&&((o=n.object)!=null&&o.temperature)&&(r={temperature:n.object.temperature.toFixed(0),measured_min_temp:(u=(l=n.object.measured_min_temp)==null?void 0:l.toFixed(1))!=null?u:null,measured_max_temp:(d=(c=n.object.measured_max_temp)==null?void 0:c.toFixed(1))!=null?d:null})}),r},getExtruders:s=>{var t,r;const e=[];return(t=s.configfile)!=null&&t.settings&&Object.keys((r=s.configfile)==null?void 0:r.settings).filter(i=>i.match(/^(extruder)\d?$/g)).sort().forEach(i=>{var a;const n=(a=s.configfile)==null?void 0:a.settings[i];e.push({key:i,name:"Extruder ".concat(i=="extruder"?"0":i.replace("extruder","")),filamentDiameter:n.filament_diameter,nozzleDiameter:n.nozzle_diameter,minExtrudeTemp:n.min_extrude_temp,maxExtrudeOnlyDistance:n.max_extrude_only_distance})}),e},getExtruderSteppers:s=>{var t,r;const e=[];return(t=s.configfile)!=null&&t.settings&&Object.keys((r=s.configfile)==null?void 0:r.settings).filter(i=>i.match(/^extruder_stepper/g)).sort().forEach(i=>{var a;const n=(a=s.configfile)==null?void 0:a.settings[i];e.push({key:i,name:i.replace("extruder_stepper ",""),extruder:n.extruder})}),e},getExtrudePossible:s=>{var t,r,i,n;const e=(r=(t=s.toolhead)==null?void 0:t.extruder)!=null?r:"extruder";return(n=(i=s[e])==null?void 0:i.can_extrude)!=null?n:!1},getBedMeshProfileName:s=>"bed_mesh"in s&&"profile_name"in s.bed_mesh?s.bed_mesh.profile_name:"",getMaxTemp:s=>{var t,r;let e=0;return(r=(t=s.heaters)==null?void 0:t.available_sensors)==null||r.forEach(i=>{var a;const n=(a=s.configfile)==null?void 0:a.settings[i];n&&"max_temp"in n&&Math.round(n.max_temp)>e&&Math.round(n.max_temp)<1e4&&(e=Math.round(n.max_temp))}),e>0?e+10:300},existPrinterConfig:s=>{var e;return(e=s.configfile)!=null&&e.config?Object.keys(s.configfile.config).length>0:!1},checkConfig:s=>e=>s.configfile.config?Object.keys(s.configfile.config).findIndex(r=>r.toLowerCase()===e.toLowerCase())!==-1:!1,checkNecessaryConfig:(s,e)=>{const t=[];return Qx.forEach(r=>{e.checkConfig(r)||t.push(r)}),!e.checkConfig("display")&&!e.checkConfig("display_status")&&t.push("display_status"),t},getEstimatedTimeFile:(s,e)=>"print_stats"in s&&"print_duration"in s.print_stats&&s.print_stats.print_duration>0&&e.getPrintPercent>0?(s.print_stats.print_duration/e.getPrintPercent-s.print_stats.print_duration).toFixed(0):0,getEstimatedTimeFilament:s=>"print_stats"in s&&"print_duration"in s.print_stats&&"filament_used"in s.print_stats&&"current_file"in s&&"filament_total"in s.current_file&&s.print_stats.print_duration>0&&s.current_file.filament_total>0&&s.current_file.filament_total>s.print_stats.filament_used?(s.print_stats.print_duration/(s.print_stats.filament_used/s.current_file.filament_total)-s.print_stats.print_duration).toFixed(0):0,getEstimatedTimeSlicer:s=>"print_stats"in s&&"print_duration"in s.print_stats&&"current_file"in s&&"estimated_time"in s.current_file&&s.print_stats.print_duration>0&&s.current_file.estimated_time>0?(s.current_file.estimated_time-s.print_stats.print_duration).toFixed(0):0,getEstimatedTimeAvg:(s,e,t)=>{var o,l,u,c,d,m,h,f;let r=0,i=0;const n=(c=(u=(l=(o=t.gui)==null?void 0:o.general)==null?void 0:l.calcEstimateTime)==null?void 0:u.includes("file"))!=null?c:!1,a=(f=(h=(m=(d=t.gui)==null?void 0:d.general)==null?void 0:m.calcEstimateTime)==null?void 0:h.includes("filament"))!=null?f:!1;return n&&e.getEstimatedTimeFile>0&&(r+=parseInt(e.getEstimatedTimeFile),i++),a&&e.getEstimatedTimeFilament>0&&(r+=parseInt(e.getEstimatedTimeFilament),i++),r&&i?r/i:0},getEstimatedTimeETA:(s,e,t)=>{var l,u,c,d,m,h,f,p,v,C,P,M;let r=0,i=0;const n=(d=(c=(u=(l=t.gui)==null?void 0:l.general)==null?void 0:u.calcEtaTime)==null?void 0:c.includes("file"))!=null?d:!1,a=(p=(f=(h=(m=t.gui)==null?void 0:m.general)==null?void 0:h.calcEtaTime)==null?void 0:f.includes("filament"))!=null?p:!1,o=(M=(P=(C=(v=t.gui)==null?void 0:v.general)==null?void 0:C.calcEtaTime)==null?void 0:P.includes("slicer"))!=null?M:!1;return n&&e.getEstimatedTimeFile>0&&(r+=parseInt(e.getEstimatedTimeFile),i++),a&&e.getEstimatedTimeFilament>0&&(r+=parseInt(e.getEstimatedTimeFilament),i++),o&&e.getEstimatedTimeSlicer>0&&(r+=parseInt(e.getEstimatedTimeSlicer),i++),r&&i?Math.round(Date.now()+r/i*1e3):0},getEstimatedTimeETAFormat:(s,e,t,r)=>{var m;const i=(m=r["gui/getHours12Format"])!=null?m:!1,n=e.getEstimatedTimeETA;if(n===0)return"--";const a=new Date(n);let o=!0,l=a.getHours();i&&l>11&&(o=!1),i&&l>12&&(l-=12),i&&l==0&&(l+=12),l<10&&(l="0"+l);const u=a.getMinutes()>=10?a.getMinutes():"0"+a.getMinutes(),c=n-new Date().getTime();let d=l+":"+u;return i&&(d+=" ".concat(o?"AM":"PM")),c>60*60*24*1e3&&(d+="+".concat(Math.trunc(c/(60*60*24*1e3)))),d},getKinematics:s=>{var e,t,r,i,n;return(t=(e=s.configfile)==null?void 0:e.settings)!=null&&t.printer?(n=(i=(r=s.configfile)==null?void 0:r.settings)==null?void 0:i.printer.kinematics)!=null?n:"none":!1},existsQGL:s=>{var e;return(e=s.configfile)!=null&&e.settings?"quad_gantry_level"in s.configfile.settings:!1},existsZtilt:s=>{var r,i,n,a;const e=(i=(r=s.gcode)==null?void 0:r.commands)!=null?i:null;if(e)return"Z_TILT_ADJUST"in e;const t=(a=(n=s.configfile)==null?void 0:n.settings)!=null?a:null;return t?"z_tilt"in t:!1},existsBedTilt:s=>{var e;return(e=s.configfile)!=null&&e.settings?"bed_tilt"in s.configfile.settings:!1},existsBedScrews:s=>{var e;return(e=s.configfile)!=null&&e.settings?"bed_screws"in s.configfile.settings:!1},existsDeltaCalibrate:s=>{var e;return(e=s.configfile)!=null&&e.settings?"delta_calibrate"in s.configfile.settings:!1},existsScrewsTilt:s=>{var e;return(e=s.configfile)!=null&&e.settings?"screws_tilt_adjust"in s.configfile.settings:!1},existsFirmwareRetraction:s=>{var e;return(e=s.configfile)!=null&&e.settings?"firmware_retraction"in s.configfile.settings:!1}},nJ={reset({commit:s,state:e}){e.updateSourceInterval!==null&&clearInterval(e.updateSourceInterval),s("reset")},init({commit:s,rootGetters:e,dispatch:t},r){var u,c,d;window.console.debug("init printer/tempHistory"),t("reset");const i=new Date,n=(u=e["printer/getAvailableHeaters"])!=null?u:[],a=(c=e["printer/getAvailableSensors"])!=null?c:[],o=(d=e["printer/getAvailableMonitors"])!=null?d:[],l=e["printer/tempHistory/getTemperatureStoreSize"];if(r!==void 0){"requestParams"in r&&delete r.requestParams;const m=Object.keys(r),h={};m.forEach(O=>{let $=O;if($.indexOf(" ")!==-1&&($=$.substring($.indexOf(" ")+1)),!(a.includes(O)||o.includes(O))||$.startsWith("_")){delete r[O];return}const D=r[O];Ln.forEach(V=>{if(V+"s"in D){const N=l-D[V+"s"].length;D[V+"s"]=[...Array.from({length:N},()=>null),...D[V+"s"]]}}),h[O]={...D}}),a.concat(o).forEach(O=>{if(O in r)return;let $=O,D=O;const V=O.indexOf(" ");if(V!==-1&&($=O.substring(V+1),D=O.substring(0,V)),$.startsWith("_"))return;const N={temperatures:Array(l).fill(null)};n.includes(O)?(N.targets=Array(l).fill(null),N.powers=Array(l).fill(null)):["temperature_fan"].includes(D)&&(N.targets=Array(l).fill(null),N.speeds=Array(l).fill(null)),h[O]={...N}});const p=[];for(let O=0;O<l;O++){const $={date:new Date(i.getTime()-1e3*(l-O))};Object.keys(h).forEach(D=>{Ln.forEach(V=>{const N="".concat(V,"s");N in h[D]&&($["".concat(D,"-").concat(V)]=h[D][N][O])})}),p.push($)}s("setInitSource",p);const v=Object.keys(p[0]).filter(O=>O!=="date"),C=v.filter(O=>O.endsWith("-temperature")).map(O=>O.slice(0,O.length-12)).sort(),P=[];let M=0;C.forEach(O=>{let $=e["gui/getDatasetValue"]({name:O,type:"color"});$||(O==="heater_bed"&&($=Xx),O.endsWith(" chamber")&&($=Yx),$||($=qx[M],M++,$===void 0&&($="#"+Math.floor(16777215*Math.random()).toString(16))));const D={id:P.length+1,color:$,type:"line",name:"".concat(O,"-temperature"),encode:{x:"date",y:"".concat(O,"-temperature")},animation:!1,yAxisIndex:0,lineStyle:{color:$,width:2,opacity:.9},showSymbol:!1,emphasis:{lineStyle:{color:$,width:2,opacity:.9}}};P.push(D),Ln.forEach(V=>{if(V==="temperature")return;const N=O+"-"+V;if(!v.includes(N))return;const W=JSON.parse(JSON.stringify(D));W.id=P.length+1,W.name=N,W.encode.y=N,V==="target"&&(W.lineStyle.width=0,W.emphasis.lineStyle.width=0,W.areaStyle={color:$,opacity:.1},W.emphasis.areaStyle={color:$,opacity:.1}),Xn.includes(V)&&(W.yAxisIndex=1,W.lineStyle.width=1.5,W.lineStyle.opacity=.75,W.lineStyle.type="dotted",W.emphasis.lineStyle.width=1.5,W.emphasis.lineStyle.opacity=.75,W.emphasis.lineStyle.type="dotted"),P.push(W)})}),s("setInitSeries",P);const F=setInterval(()=>{t("updateSource")},Jx);s("setUpdateSourceInterval",F)}t("socket/removeInitModule","printer/initTempHistory",{root:!0})},async updateSource({commit:s,rootState:e,rootGetters:t,state:r}){var o,l;const i=(o=t["printer/getAvailableSensors"])!=null?o:[],n=(l=t["printer/getAvailableMonitors"])!=null?l:[],a=i.concat(n);if(a.length){const u=new Date;if(r.source.length){const d=r.source[r.source.length-1],m=d.date.getSeconds(),h=u.getSeconds(),f=u.getTime()-d.date.getTime();if(m===h&&f<1e3)return}const c={date:u};a.forEach(d=>{if(!(e.printer&&d in e.printer))return;const m={...e.printer[d]};Ln.forEach(h=>{if(!(h in m))return;let f=m[h];f!==null&&(f=Math.round(m[h]*10)/10),Xn.includes(h)&&(f=Math.round(m[h]*1e3)/1e3),c["".concat(d,"-").concat(h)]=f})}),s("addToSource",{data:c,maxHistory:t["printer/tempHistory/getTemperatureStoreSize"]})}},setColor({commit:s},e){s("setColor",e)}},aJ={reset(s){Object.assign(s,RC())},setInitSource(s,e){y.set(s,"source",e)},setInitSeries(s,e){y.set(s,"series",e)},addToSource(s,e){const t=[...s.source];for(t.push(e.data);t.length>e.maxHistory;)t.splice(0,1);y.set(s,"source",t)},saveLastDate(s,e){y.set(s,"timeLastUpdate",e)},setUpdateSourceInterval(s,e){y.set(s,"updateSourceInterval",e)},setColor(s,e){s.series.filter(t=>e.name===t.name||t.name.startsWith(e.name+"-")).forEach(t=>{var r;if(t.color=e.value,t.lineStyle.color=e.value,t.emphasis.lineStyle.color=e.value,t.name.endsWith("-target")){const i=t.areaStyle;i&&(i.color=e.value);const n=(r=t.emphasis)==null?void 0:r.areaStyle;n&&(n.color=e.value)}})}},oJ={getDatasetColor:(s,e)=>t=>{var i,n;const r=e.getSeries("".concat(t,"-temperature"));return(n=(i=r==null?void 0:r.lineStyle)==null?void 0:i.color)!=null?n:null},getSeries:s=>e=>s.series.find(t=>t.name===e),getSerieNames:s=>e=>{const t=[];return s.series.map(i=>i.name).filter(i=>i.startsWith("".concat(e,"-"))).forEach(i=>{t.push(i.slice(e.length+1))}),t},getBoolDisplayPwmAxis:(s,e)=>{const t=e.getSelectedLegends;return Object.keys(t).find(r=>t[r]===!0&&(r.endsWith("-power")||r.endsWith("-speed")))!==void 0},getAvg:s=>(e,t)=>{const r=t&&t!=="temperature"?e+"-"+t:e,i=new Date().getTime()-1e3*60;let n=0,a=0;return s.source.filter(o=>o.date>i).forEach(o=>{r in o&&(n+=o[r],a++)}),a&&Xn.includes(t)?n/a*100:a?n/a:0},getAvgPower:(s,e)=>t=>e.getAvg(t,"power"),getAvgSpeed:(s,e)=>t=>e.getAvg(t,"speed"),getHostMcuSensors:(s,e,t)=>{var a,o,l,u,c,d,m,h,f;const r=(l=(o=(a=t.printer)==null?void 0:a.configfile)==null?void 0:o.settings)!=null?l:{},i=(d=(c=(u=t.printer)==null?void 0:u.heaters)==null?void 0:c.available_heaters)!=null?d:[];return((f=(h=(m=t.printer)==null?void 0:m.heaters)==null?void 0:h.available_sensors)!=null?f:[]).filter(p=>{var P;if(i.includes(p)||p.startsWith("temperature_fan"))return!1;const v=r[p.toLowerCase()];if(!v)return!1;const C=(P=v.sensor_type)!=null?P:"";return["temperature_mcu","temperature_host"].includes(C)})},getSelectedLegends:(s,e,t)=>{var u,c,d,m,h,f,p,v,C,P,M,F,O,$,D,V,N,W,G,te,X,q;const r={},i=(d=(c=(u=t.printer)==null?void 0:u.heaters)==null?void 0:c.available_sensors)!=null?d:[],n=(f=(h=(m=t.printer)==null?void 0:m.heaters)==null?void 0:h.available_monitors)!=null?f:[],a=(P=(C=(v=(p=t.gui)==null?void 0:p.view)==null?void 0:v.tempchart)==null?void 0:C.datasetSettings)!=null?P:{};if(Object.keys(a).forEach(z=>{!i.includes(z)&&!n.includes(z)||Object.keys(a[z]).forEach(K=>{if(!Ln.includes(K))return;const Q="".concat(z,"-").concat(K);s.series.findIndex(re=>re.name===Q)!==-1&&(r[Q]=a[z][K])})}),s.series.forEach(z=>{if(Object.keys(r).includes(z.name))return;const K=z.name.slice(z.name.lastIndexOf("-")+1);r[z.name]=!Xn.includes(K)}),($=(O=(F=(M=t.gui)==null?void 0:M.view)==null?void 0:F.tempchart)==null?void 0:O.hideMcuHostSensors)!=null?$:!1){const z=(D=e.getHostMcuSensors)!=null?D:[];Object.keys(r).filter(K=>{const Q=K.slice(0,K.lastIndexOf("-"));return z.includes(Q)}).forEach(K=>{r[K]=!1})}if((G=(W=(N=(V=t.gui)==null?void 0:V.view)==null?void 0:N.tempchart)==null?void 0:W.hideMonitors)!=null?G:!1){const z=(q=(X=(te=t.printer)==null?void 0:te.heaters)==null?void 0:X.available_monitors)!=null?q:[];Object.keys(r).filter(K=>{const Q=K.slice(0,K.lastIndexOf("-"));return z.includes(Q)}).forEach(K=>{r[K]=!1})}return r},getTemperatureStoreSize:(s,e,t,r)=>{const i=r["server/getConfig"]("data_store","temperature_store_size");return i!=null?i:1200}},RC=()=>({source:[],series:[],timeLastUpdate:null,updateSourceInterval:null}),lJ=RC(),cJ={namespaced:!0,state:lJ,getters:oJ,actions:nJ,mutations:aJ},HC=()=>({}),uJ=HC(),dJ={namespaced:!0,state:uJ,getters:iJ,actions:sJ,mutations:rJ,modules:{tempHistory:cJ}},mJ={reset({commit:s}){s("reset")},initRootDirs({state:s,commit:e},t){t.forEach(r=>{s.filetree.findIndex(i=>i.filename===r)===-1&&(e("createRootDir",{name:r,permissions:"r"}),y.$socket.emit("server.files.get_directory",{path:r},{action:"files/getDirectory"}))})},getDirectory({state:s,commit:e,getters:t},r){var u,c,d,m,h,f;const i=r.requestParams.path.split("/"),n=i.length?i[0]:r.requestParams.path,a=r.requestParams.path.indexOf("/"),o=a>1?r.requestParams.path.slice(a+1):"",l=t.getDirectory(n+"/"+o);if((u=l==null?void 0:l.childrens)!=null&&u.length&&(l==null||l.childrens.forEach(p=>{var v,C;p!=null&&p.isDirectory&&((v=r.dirs)==null?void 0:v.findIndex(P=>P.dirname===p.filename))<0?e("setDeleteDir",{item:{path:o.length?o+"/"+p.filename:p.filename,root:n}}):!(p!=null&&p.isDirectory)&&((C=r.files)==null?void 0:C.findIndex(P=>P.filename===p.filename))<0&&e("setDeleteFile",{item:{path:o.length?o+"/"+p.filename:p.filename,root:n}})})),(c=r.dirs)!=null&&c.length&&r.dirs.filter(p=>!ow.includes(p.dirname)).forEach(p=>{var v;((v=l==null?void 0:l.childrens)==null?void 0:v.findIndex(C=>C.isDirectory&&C.filename===p.dirname))===-1&&(e("setCreateDir",{item:{path:o.length?o+"/"+p.dirname:p.dirname,root:n,permissions:p.permissions,modified:p.modified*1e3}}),y.$socket.emit("server.files.get_directory",{path:r.requestParams.path+"/"+p.dirname},{action:"files/getDirectory"}))}),(d=r.files)!=null&&d.length&&r.files.forEach(p=>{var C;const v=(C=l==null?void 0:l.childrens)==null?void 0:C.find(P=>!P.isDirectory&&P.filename===p.filename);v&&(v.size!==p.size||v.modified.getTime()!==new Date(p.modified*1e3).getTime())?e("setModifyFile",{item:{path:o.length?o+"/"+p.filename:p.filename,root:n,modified:p.modified,size:p.size}}):v||e("setCreateFile",{item:{path:o.length?o+"/"+p.filename:p.filename,root:n,permissions:p.permissions,modified:p.modified,size:p.size}})}),(m=r==null?void 0:r.root_info)!=null&&m.name){const p=s.filetree.find(v=>{var C;return v.filename===((C=r==null?void 0:r.root_info)==null?void 0:C.name)});p&&p.permissions!==((h=r.root_info)==null?void 0:h.permissions)&&e("setRootPermissions",r.root_info)}(f=r.requestParams)!=null&&f.path&&r.disk_usage&&e("setDiskUsage",{disk_usage:r.disk_usage,path:r.requestParams.path})},scanMetadata({commit:s},e){if(e.filename.slice(0,e.filename.indexOf("/"))==="gcodes"){const r=e.filename.slice(7);s("setMetadataRequested",{filename:r}),y.$socket.emit("server.files.metascan",{filename:r},{action:"files/getScanMetadata"})}},getScanMetadata({dispatch:s},e){if(e!==void 0&&e.filename!==""){s("getMetadata",e);const t=e.filename;y.$toast.success(ve.t("Files.ScanMetaSuccess",{filename:t}).toString())}},requestMetadata({commit:s},e){let t=[];for(const{filename:r}of e)if(t.length>=100&&(y.$socket.emitBatch(t),t=[]),r.slice(0,r.indexOf("/"))==="gcodes"){const n=r.slice(7);s("setMetadataRequested",{filename:n}),t.push({method:"server.files.metadata",params:{filename:n},emitOptions:{action:"files/getMetadata"}})}y.$socket.emitBatch(t)},getMetadata({commit:s,rootState:e},t){var r,i;t!==void 0&&t.filename!==""&&(t.filename===((i=(r=e==null?void 0:e.printer)==null?void 0:r.print_stats)==null?void 0:i.filename)&&(s("printer/clearCurrentFile",null,{root:!0}),s("printer/setData",{current_file:t},{root:!0})),s("setMetadata",t))},getMetadataCurrentFile({commit:s},e){s("printer/clearCurrentFile",null,{root:!0}),s("printer/setData",{current_file:e},{root:!0})},async filelist_changed({commit:s,dispatch:e},t){var r,i;switch(t.action){case"create_file":s("setCreateFile",t);break;case"move_file":if(((r=t.source_item)==null?void 0:r.path)==="printer_autosave.cfg"&&((i=t.source_item)==null?void 0:i.root)==="config"){s("setCreateFile",t);return}await s("setMoveFile",t),t.item.root==="gcodes"&&Pi.includes(t.item.path.slice(t.item.path.lastIndexOf(".")))&&await e("requestMetadata",[{filename:"gcodes/"+t.item.path}]);break;case"delete_file":s("setDeleteFile",t);break;case"modify_file":s("setModifyFile",t);break;case"create_dir":s("setCreateDir",t);break;case"move_dir":s("setMoveDir",t);break;case"delete_dir":s("setDeleteDir",t);break;case"root_update":e("server/addRootDirectory",t,{root:!0}),s("setRootUpdate",t);break;default:window.console.error("Unknown filelist_changed action: "+t.action);break}},getMove(s,e){if(e.error)y.$toast.error(e.error.message);else{const t=e.requestParams.dest.substr(e.requestParams.dest.lastIndexOf("/")).replace("/",""),r=e.requestParams.source.substr(0,e.requestParams.source.lastIndexOf("/")),i=e.requestParams.dest.substr(0,e.requestParams.dest.lastIndexOf("/"));r===i?y.$toast.success(ve.t("Files.SuccessfullyRenamed",{filename:t})):y.$toast.success(ve.t("Files.SuccessfullyMoved",{filename:t}))}},getCreateDir(s,e){if(e.error)y.$toast.error(e.error.message);else{const t=e.requestParams.path.substr(e.requestParams.path.lastIndexOf("/")+1);y.$toast.success(ve.t("Files.SuccessfullyCreated",{filename:t}))}},getDeleteDir(s,e){if(e.error)y.$toast.error(e.error.message);else{const t=e.requestParams.path.substr(e.requestParams.path.lastIndexOf("/")+1);y.$toast.success(ve.t("Files.SuccessfullyDeleted",{filename:t}))}},getDeleteFile(s,e){if(e.error)y.$toast.error(e.error.message);else{const t=e.item.path.substr(e.item.path.lastIndexOf("/")+1),r=e.item.path.substr(e.item.path.lastIndexOf(".")+1);e.item.root==="timelapse"&&r==="jpg"||y.$toast.success(ve.t("Files.SuccessfullyDeleted",{filename:t}))}},async uploadFile({commit:s,rootGetters:e},t){const r=e["socket/getUrl"],i=new FormData;i.append("file",t.file,t.file.name),i.append("root",t.root),i.append("path",t.path);const n=Le.CancelToken.source();return await s("uploadClearState"),await s("uploadSetCancelTokenSource",n),await s("uploadSetFilename",t.file.name),await s("uploadSetShow",!0),new Promise(a=>{Le.post(r+"/server/files/upload",i,{cancelToken:n.token,headers:{"Content-Type":"multipart/form-data"},onUploadProgress:o=>{var c,d;const l=((c=o.progress)!=null?c:0)*100;s("uploadSetPercent",l);const u=(d=o.rate)!=null?d:0;s("uploadSetSpeed",u)}}).then(o=>{s("uploadSetShow",!1);const l=o.data.item.path.lastIndexOf("/"),u=o.data.item.path.slice(l+1);a(u)}).catch(()=>{s("uploadSetShow",!1),y.$toast.error(ve.t("FullscreenUpload.CannotUploadFile").toString()),a(!1)})})},uploadSetShow({commit:s},e){s("uploadSetShow",e)},uploadSetCurrentNumber({commit:s},e){s("uploadSetCurrentNumber",e)},uploadIncrementCurrentNumber({state:s,commit:e}){e("uploadSetCurrentNumber",s.upload.currentNumber+1)},uploadSetMaxNumber({commit:s},e){s("uploadSetMaxNumber",e)},downloadZip({rootGetters:s},e){const t=s["socket/getUrl"],r="".concat(t,"/server/files/").concat(e.destination.root,"/").concat(encodeURI(e.destination.path));window.open(r)},rolloverLog(s,e){e.rolled_over.forEach(t=>{y.$toast.success(ve.t("Machine.LogfilesPanel.RolloverToastSuccessful",{name:t}))}),Object.keys(e.failed).forEach(t=>{const r=e.failed[t];y.$toast.error(ve.t("Machine.LogfilesPanel.RolloverToastFailed",{name:t,message:r}))}),setTimeout(()=>{y.$socket.emit("server.files.get_directory",{path:"logs"},{action:"files/getDirectory"})},500)}},hJ={reset(s){Object.assign(s,jC())},createRootDir(s,e){s.filetree.push({isDirectory:!0,filename:e.name,modified:new Date,permissions:e.permissions,childrens:[],disk_usage:{free:0,total:0,used:0}})},setMetadataRequested(s,e){let t="gcodes/"+e.filename;const r=t.split("/");t=r[r.length-1];const i=Nt(s.filetree,r),n=i==null?void 0:i.findIndex(a=>a.filename===t);if(i&&n!==void 0&&n!==-1){const a={...i[n]};a.metadataRequested=!0,y.set(i,n,a)}else window.console.error("file not found in filetree: "+e.filename)},setMetadata(s,e){let t="gcodes/"+e.filename;const r=t.split("/");t=r[r.length-1];const i=Nt(s.filetree,r),n=i==null?void 0:i.findIndex(a=>a.filename===t);if(i&&n!==void 0&&n!==-1){const a={...i[n]};ew.forEach(o=>{o in e&&(a[o]=e[o])}),a.metadataRequested=!0,a.metadataPulled=!0,y.set(i,n,a)}else window.console.error("file not found in filetree: "+e.filename)},setCreateFile(s,e){let t=e.item.path;e.item.path.lastIndexOf("/")>=0&&(t=e.item.path.substr(e.item.path.lastIndexOf("/")).replace("/",""));const r=e.item.path.substr(0,e.item.path.lastIndexOf("/")),i=Nt(s.filetree,(e.item.root+"/"+r).split("/"));if(i){const n=i.findIndex(a=>!a.isDirectory&&a.filename===t);if(n===-1){const a=new Date(e.item.modified*1e3);i.push({isDirectory:!1,filename:t,modified:a,permissions:e.item.permissions,size:e.item.size,metadataRequested:!1,metadataPulled:!1})}else{i[n].modified=new Date(e.item.modified*1e3),i[n].size=e.item.size,i[n].metadataRequested=!1,i[n].metadataPulled=!1;const a=t.substring(t.lastIndexOf(".")+1);e.item.root==="gcodes"&&a==="gcode"&&y.$socket.emit("server.files.metadata",{filename:e.item.path},{action:"files/getMetadata"})}}},setMoveFile(s,e){let t=e.source_item.path,r=e.source_item.root;const i=e.source_item.path.lastIndexOf("/");i!==-1&&(t=e.source_item.path.substring(i+1),r=e.source_item.root+"/"+e.source_item.path.substring(0,i));let n=e.item.path,a=e.item.root;const o=e.item.path.lastIndexOf("/");o!==-1&&(n=e.item.path.substring(o+1),a=e.item.root+"/"+e.item.path.substring(0,o));const l=Nt(s.filetree,r.split("/")),u=l==null?void 0:l.findIndex(m=>m.filename===t);if(u===void 0||u===-1||l===null)return;const c=l.splice(u,1)[0];c.filename=n,r!==a&&"metadataPulled"in c&&c.metadataPulled&&"thumbnails"in c&&(c.metadataPulled=!1,delete c.thumbnails);const d=Nt(s.filetree,a.split("/"));d==null||d.push(c)},setModifyFile(s,e){let t=e.item.path,r=e.item.root;const i=e.item.path.lastIndexOf("/");i!==-1&&(t=e.item.path.substr(i+1),r=e.item.root+"/"+e.item.path.substr(0,i+1));const n=Nt(s.filetree,r.split("/")),a=n==null?void 0:n.findIndex(o=>o.filename===t);a!==void 0&&a>-1&&n&&n[a]&&("metadataPulled"in n[a]&&n[a].metadataPulled&&(n[a].metadataPulled=!1,"thumbnails"in n[a]&&delete n[a].thumbnails),n[a].modified=new Date(e.item.modified*1e3),n[a].size=e.item.size)},setMoveDir(s,e){let t=e.source_item.path,r=e.source_item.root;const i=e.source_item.path.lastIndexOf("/");i!==-1&&(t=e.source_item.path.substr(i+1),r=e.source_item.root+"/"+e.source_item.path.substr(0,i+1));let n=e.item.path,a=e.item.root;const o=e.item.path.lastIndexOf("/");o!==-1&&(n=e.item.path.substr(o+1),a=e.item.root+"/"+e.item.path.substr(0,o+1));const l=Nt(s.filetree,r.split("/")),u=l==null?void 0:l.findIndex(c=>c.filename===t);if(u!==void 0&&l&&l[u]){const c=l.splice(u,1)[0];c.filename=n;const d=Nt(s.filetree,a.split("/"));d==null||d.push(c)}},setDeleteFile(s,e){let t=e.item.path.substr(0,e.item.path.lastIndexOf("/"));const r=e.item.path.substr(e.item.path.lastIndexOf("/")+1);t=Nt(s.filetree,(e.item.root+"/"+t).split("/"));const i=t.findIndex(n=>n.filename===r);i>=0&&t[i]&&t.splice(i,1)},setCreateDir(s,e){var n;const t=e.item.path.substr(e.item.path.lastIndexOf("/")+1),r=e.item.path.substr(0,e.item.path.lastIndexOf("/")),i=Nt(s.filetree,(e.item.root+"/"+r).split("/"));i&&i.push({isDirectory:!0,filename:t,modified:(n=e.item.modified)!=null?n:new Date,permissions:e.item.permissions,childrens:[]})},setDeleteDir(s,e){let t=e.item.path.substr(0,e.item.path.lastIndexOf("/"));const r=e.item.path.substr(e.item.path.lastIndexOf("/")+1);t=Nt(s.filetree,(e.item.root+"/"+t).split("/"));const i=t.findIndex(n=>n.filename===r);i>=0&&t[i]&&t.splice(i,1)},setRootUpdate(s,e){var r,i,n;const t=s.filetree.findIndex(a=>a.filename===e.item.root);t!==-1&&((r=s.filetree[t].childrens)!=null&&r.length)&&((n=s.filetree[t].childrens)==null||n.splice(0,(i=s.filetree[t].childrens)==null?void 0:i.length))},setDiskUsage(s,e){const t=e.path.substr(0,e.path.lastIndexOf("/")),r=e.path.substr(e.path.lastIndexOf("/")+1),i=Nt(s.filetree,t.split("/")),n=i==null?void 0:i.find(a=>a.isDirectory&&a.filename===r);n&&y.set(n,"disk_usage",e.disk_usage)},setRootPermissions(s,e){const t=s.filetree.find(r=>r.filename===e.name);t&&y.set(t,"permissions",e.permissions)},uploadClearState(s){const e={...s.upload};e.show=!1,e.filename="",e.cancelTokenSource=null,e.speed=0,e.percent=0,y.set(s,"upload",e)},uploadSetShow(s,e){y.set(s.upload,"show",e)},uploadSetFilename(s,e){y.set(s.upload,"filename",e)},uploadSetCancelTokenSource(s,e){y.set(s.upload,"cancelTokenSource",e)},uploadSetCurrentNumber(s,e){y.set(s.upload,"currentNumber",e)},uploadSetMaxNumber(s,e){y.set(s.upload,"maxNumber",e)},uploadSetPercent(s,e){s.upload.percent!==e&&y.set(s.upload,"percent",e)},uploadSetSpeed(s,e){s.upload.speed!==e&&y.set(s.upload,"speed",e)}},pJ={getDirectory:s=>e=>{e.startsWith("/")&&(e=e.substr(1)),e.endsWith("/")&&(e=e.substr(0,e.length-1));const t=function(r,i){var n;if(i.length){const a=(n=r==null?void 0:r.childrens)==null?void 0:n.find(o=>o.isDirectory&&o.filename===i[0]);return a?(i.shift(),t(a,i)):null}return r};return t({childrens:s.filetree},e.split("/"))},getFile:(s,e)=>t=>{var a;const r=t.slice(0,t.lastIndexOf("/")),i=t.slice(t.lastIndexOf("/")+1),n=e.getDirectory(r);return(a=n==null?void 0:n.childrens)==null?void 0:a.find(o=>o.filename===i&&!o.isDirectory)},getGcodeFiles:(s,e,t,r)=>(i,n,a)=>{var d;const o=e.getDirectory("gcodes");if(o===null)return[];let l="".concat(r["socket/getUrl"],"/server/files/gcodes"),u=[];if(i!==null){l+=Ie(i);const m=e.getDirectory("gcodes"+i);u=(d=m==null?void 0:m.childrens)!=null?d:[]}else{const m=(h,f)=>{var p,v;h.isDirectory&&((p=h.childrens)!=null&&p.length)&&((v=h.childrens)==null||v.forEach(C=>{if(C.isDirectory)m(C,f+C.filename+"/");else{const P={...C};P.filename=f+C.filename,u.push(P)}}))};m(o,"")}u=u.filter(m=>{if(!n&&(m.filename==="thumbs"||m.filename.startsWith(".")))return!1;if(m.isDirectory)return!0;const h=m.filename.lastIndexOf("."),f=m.filename.slice(h);return Pi.includes(f)});const c=[];return u.forEach(m=>{var M,F;const h=typeof m.modified.getTime=="function"?m.modified.getTime():0,f={...m,preheat_gcode:null,small_thumbnail:null,big_thumbnail:null,big_thumbnail_width:null,count_printed:0,last_start_time:null,last_end_time:null,last_filament_used:null,last_status:null,last_print_duration:null,last_total_duration:null},p=[];if([{name:"first_layer_extr_temp",gcode:"M104"},{name:"first_layer_bed_temp",gcode:"M140"}].forEach(O=>{O.name in m&&m[O.name]>1&&p.push("".concat(O.gcode," S").concat(m[O.name]))}),p.length&&(f.preheat_gcode=p.join("\n")),(M=m.thumbnails)!=null&&M.length){let O="";if(i===null){const V=m.filename.lastIndexOf("/");V>0&&(O="/"+m.filename.slice(0,V))}const $=m.thumbnails.find(V=>V.width>=Yt&&V.width<=Jt&&V.height>=Yt&&V.height<=Jt);$&&"relative_path"in $&&(f.small_thumbnail="".concat(l).concat(Ie(O+"/"+$.relative_path),"?timestamp=").concat(h));const D=m.thumbnails.find(V=>V.width>=Ls);D&&"relative_path"in D&&(f.big_thumbnail="".concat(l).concat(Ie(O+"/"+D.relative_path),"?timestamp=").concat(h),f.big_thumbnail_width=D.width)}const C=i&&i.length?i+"/"+m.filename:m.filename;let P=r["server/history/getPrintJobsForGcodes"](C,h,m.size,(F=m.uuid)!=null?F:null,m.job_id);if(P&&P.length){P=P.sort((D,V)=>V.start_time-D.start_time);const O=P.filter(D=>D.status==="completed"),$=[...P].shift();if(f.last_status=$.status,f.count_printed=O.length,f.last_start_time=new Date($.start_time*1e3),f.count_printed>0){const D=O[0];f.last_start_time=new Date(D.start_time*1e3),f.last_end_time=new Date(D.end_time*1e3),f.last_filament_used=D.filament_used,f.last_print_duration=D.print_duration,f.last_total_duration=D.total_duration}}(a||f.count_printed===0)&&c.push(f)}),c},getAllGcodes:(s,e)=>e.getGcodeFiles(null,!1,!0),getThemeFileUrl:(s,e,t,r)=>(i,n)=>{var l;const a=e.getDirectory("config/"+Si),o=(l=a==null?void 0:a.childrens)==null?void 0:l.find(u=>{var c,d,m,h;return((d=u.filename)==null?void 0:d.slice(0,(c=u.filename)==null?void 0:c.lastIndexOf(".")))===i&&n.includes((h=u.filename)==null?void 0:h.slice(((m=u.filename)==null?void 0:m.lastIndexOf("."))+1))});return o?"".concat(r["socket/getUrl"],"/server/files/config/").concat(Si,"/").concat(o.filename,"?timestamp=").concat(o.modified.getTime()):null},getSidebarLogo:(s,e)=>{var i;const t="sidebar-logo",r=["svg","jpg","jpeg","png","gif"];return(i=e.getThemeFileUrl(t,r))!=null?i:""},getCustomSidebarBackground:(s,e)=>{var i;const t="sidebar-background",r=["jpg","jpeg","png","gif","svg"];return(i=e.getThemeFileUrl(t,r))!=null?i:null},getMainBackground:(s,e)=>{const t="main-background",r=["jpg","jpeg","png","gif","svg"];return e.getThemeFileUrl(t,r)},getCustomStylesheet:(s,e)=>{var i;const t="custom",r=["css"];return(i=e.getThemeFileUrl(t,r))!=null?i:null},getCustomNaviPoints:(s,e)=>{var i;const t="navi",r=["json"];return(i=e.getThemeFileUrl(t,r))!=null?i:null},getCustomFavicons:(s,e)=>{const t="favicon-32x32",r="favicon-32x32",i=["png","svg"],n=e.getThemeFileUrl(t,i),a=e.getThemeFileUrl(r,i);return n&&a?[n,a]:n?[n,n]:a?[a,a]:null},getDiskUsage:s=>e=>{e.indexOf("/")===0&&(e=e.substr(1)),e.indexOf("/")!==-1&&(e=e.substr(0,e.indexOf("/")));const t=s.filetree.find(r=>r.filename===e);return t&&"disk_usage"in t?t.disk_usage:null},checkConfigFile:(s,e)=>t=>{var i;const r=e.getDirectory("config");return((i=r==null?void 0:r.childrens)==null?void 0:i.findIndex(n=>n.filename!==void 0&&n.filename===t))!==-1},getSmallThumbnail:(s,e,t,r)=>(i,n)=>{var a;if("thumbnails"in i&&((a=i.thumbnails)!=null&&a.length)){const o=i.thumbnails.find(l=>l.width>=Yt&&l.width<=Jt&&l.height>=Yt&&l.height<=Jt);if(o&&"relative_path"in o)return"".concat(r["socket/getUrl"],"/server/files/").concat(Ie(n),"/").concat(Ie(o.relative_path),"?timestamp=").concat(i.modified.getTime())}return""},getBigThumbnail:(s,e,t,r)=>(i,n)=>{var a;if("thumbnails"in i&&((a=i.thumbnails)!=null&&a.length)){const o=i.thumbnails.find(l=>l.width>=Ls);if(o&&"relative_path"in o)return"".concat(r["socket/getUrl"],"/server/files/").concat(Ie(n),"/").concat(Ie(o.relative_path),"?timestamp=").concat(i.modified.getTime())}return""}},jC=()=>({filetree:[],upload:{show:!1,filename:"",currentNumber:0,maxNumber:0,cancelTokenSource:null,percent:0,speed:0}}),fJ=jC(),gJ={namespaced:!0,state:fJ,getters:pJ,actions:mJ,mutations:hJ},_J={reset({commit:s,dispatch:e}){s("reset"),e("console/reset"),e("gcodehistory/reset"),e("macros/reset"),e("presets/reset"),e("webcams/reset")},init(){window.console.debug("init gui"),y.$socket.emit("server.database.get_item",{namespace:"mainsail"},{action:"gui/initStore"})},async initStore({commit:s,dispatch:e,rootGetters:t,rootState:r},i){var o,l,u,c,d,m;const a=t["socket/getUrl"]+"/server/database/item"+"?namespace=mainsail";if("remoteprinters"in i.value&&(r.instancesDB==="moonraker"&&e("remoteprinters/initStore",i.value.remoteprinters.printers),delete i.value.remoteprinters),(u=(l=(o=i.value)==null?void 0:o.view)==null?void 0:l.gcodefiles)!=null&&u.currentPath&&(window.console.debug("remove currentPath from gui namespace"),await fetch(a+"&key=view.gcodefiles.currentPath",{method:"DELETE"})),(m=(d=(c=i.value)==null?void 0:c.view)==null?void 0:d.configfiles)!=null&&m.currentPath&&(window.console.debug("remove currentPath from gui namespace"),await fetch(a+"&key=view.configfiles.currentPath",{method:"DELETE"})),"cooldownGcode"in i.value&&(window.console.debug("update cooldownGcode to new namespace"),e("saveSetting",{name:"presets.cooldownGcode",value:i.value.cooldownGcode}),await fetch(a+"&key=cooldownGcode",{method:"DELETE"}),delete i.value.cooldownGcode),"presets"in i.value&&Array.isArray(i.value.presets)&&(window.console.debug("update presets to new namespace"),i.value.presets.forEach(h=>{e("presets/store",{values:h})}),delete i.value.presets),"dashboard"in i.value&&"nonExpandPanels"in i.value.dashboard&&Array.isArray(i.value.dashboard.nonExpandPanels)&&(await fetch(a+"&key=dashboard.nonExpandPanels",{method:"DELETE"}),e("saveSetting",{name:"dashboard.nonExpandPanels.widescreen",value:i.value.dashboard.nonExpandPanels}),delete i.value.dashboard.nonExpandPanels),"dashboard"in i.value){const h=i.value.dashboard;["mobileLayout","tabletLayout1","tabletLayout2","desktopLayout1","desktopLayout2","widescreenLayout1","widescreenLayout2","widescreenLayout3"].forEach(p=>{if(p in h){const v=h[p].findIndex(C=>C.name==="tools");v!==-1&&(h[p][v].name="temperature",e("saveSetting",{name:"dashboard."+p,value:h[p]}))}})}await s("setData",i.value),await e("socket/removeInitModule","gui/init",{root:!0})},async initDb({dispatch:s,rootGetters:e}){var a;const t=e["socket/getUrl"]+"/server/database/item",r=e["socket/getUrl"]+"/server/files/config/"+Si+"/default.json?time="+Date.now(),i=await fetch(r);let n={};i&&(n=await i.json(),((a=n.error)==null?void 0:a.code)===404&&(n={}));for(const o in n)if(["webcams","timelapse"].includes(o))for(const l of n[o])await fetch(t,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({namespace:o,key:l,value:n[o][l]})});else await fetch(t,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({namespace:"mainsail",key:o,value:n[o]})});await fetch(t,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({namespace:"mainsail",key:"initVersion",value:e.getVersion})}),s("init")},saveSetting({commit:s},e){s("saveSetting",e),y.$socket.emit("server.database.post_item",{namespace:"mainsail",key:e.name,value:e.value})},saveSettingWithoutUpload({commit:s},e){s("saveSetting",e)},updateSettings(s,e){const t=e.keyName;let r=e.newVal;"value"in e&&t in e.value&&typeof e.value[t]!="string"&&!Array.isArray(e.value[t])&&(r=Object.assign(e.value[t],{...r})),y.$socket.emit("server.database.post_item",{namespace:"mainsail",key:t,value:r})},setGcodefilesMetadata({commit:s,dispatch:e,state:t},r){s("setGcodefilesMetadata",r),e("updateSettings",{keyName:"view.gcodefiles.hideMetadataColumns",newVal:t.view.gcodefiles.hideMetadataColumns})},setGcodefilesShowHiddenFiles({commit:s,dispatch:e,state:t},r){s("setGcodefilesShowHiddenFiles",r),e("updateSettings",{keyName:"view.gcodefiles.showHiddenFiles",newVal:t.view.gcodefiles.showHiddenFiles})},setCurrentWebcam({commit:s,dispatch:e,state:t},r){s("setCurrentWebcam",r),e("updateSettings",{keyName:"view.webcam.currentCam",newVal:t.view.webcam.currentCam})},setTempchartDatasetAdditionalSensorSetting({commit:s,dispatch:e,state:t},r){s("setTempchartDatasetAdditionalSensorSetting",r),e("updateSettings",{keyName:"view.tempchart",newVal:t.view.tempchart})},async resetMoonrakerDB({rootGetters:s},e){var n,a;const t=s["socket/getUrl"]+"/server/database/item",r=s["socket/getUrl"]+"/server/files/config/"+Si+"/default.json?time="+Date.now();let i={};try{i=await fetch(r).then(o=>o.json())}catch(o){window.console.error("Error while fetching/parsing default.json",o),i={}}for(const o of e)if(["maintenance","timelapse","webcams"].includes(o)){const l=t+"?namespace="+o,c=await(await fetch(l)).json();if((n=c==null?void 0:c.result)!=null&&n.value)for(const d of Object.keys((a=c==null?void 0:c.result)==null?void 0:a.value))await fetch(l+"&key="+d,{method:"DELETE"});if(o in i)for(const d of i[o])await fetch(t,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({namespace:o,key:d,value:i[o][d]})})}else o==="history_jobs"?await fetch(s["socket/getUrl"]+"/server/history/job?all=true",{method:"DELETE"}):o==="history_totals"?await fetch(s["socket/getUrl"]+"/server/history/reset_totals",{method:"POST"}):(await fetch(s["socket/getUrl"]+"/server/database/item?namespace=mainsail&key="+o,{method:"DELETE"}),o in i&&await fetch(t,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({namespace:"mainsail",key:o,value:i[o]})}));window.location.reload()},async backupMoonrakerDB({rootGetters:s},e){var o,l,u,c;const t={},i=await(await fetch(s["socket/getUrl"]+"/server/database/item?namespace=mainsail")).json(),n=(l=(o=i==null?void 0:i.result)==null?void 0:o.value)!=null?l:{};for(const d of e)if(["timelapse","webcams"].includes(d)){const m=s["socket/getUrl"]+"/server/database/item?namespace="+d,f=await(await fetch(m)).json();(u=f==null?void 0:f.result)!=null&&u.value&&(t[d]={...(c=f==null?void 0:f.result)==null?void 0:c.value})}else d in n&&(t[d]={...n[d]});const a=document.createElement("a");a.setAttribute("href","data:text/plain;charset=utf-8,"+encodeURIComponent(JSON.stringify(t))),a.setAttribute("download","backup-mainsail.json"),a.style.display="none",document.body.appendChild(a),a.click(),document.body.removeChild(a)},async restoreMoonrakerDB({rootGetters:s},e){var l,u,c,d,m,h;const t=s["socket/getUrl"]+"/server/database/item",r=t+"?namespace=mainsail",n=await(await fetch(s["socket/getUrl"]+"/server/database/list")).json(),a=(u=(l=n==null?void 0:n.result)==null?void 0:l.namespaces)!=null?u:[];let o=[];if(a.includes("mainsail")){const p=await(await fetch(r)).json();o=Object.keys((d=(c=p==null?void 0:p.result)==null?void 0:c.value)!=null?d:{})}for(const f of e.dbCheckboxes)if(["timelapse","webcams"].includes(f)){if(a.includes(f)){const p=t+"?namespace="+f,C=await(await fetch(p)).json();if((m=C==null?void 0:C.result)!=null&&m.value)for(const P of Object.keys((h=C==null?void 0:C.result)==null?void 0:h.value))await fetch(p+"&key="+P,{method:"DELETE"})}for(const p of Object.keys(e.restoreObjects[f])){const v=e.restoreObjects[f][p];await fetch(t,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({namespace:f,key:p,value:v})})}}else o.includes(f)&&await fetch(r+"&key="+f,{method:"DELETE"}),await fetch(r,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({namespace:"mainsail",key:f,value:e.restoreObjects[f]})});window.location.reload()},setHistoryColumns({commit:s,dispatch:e,state:t},r){s("setHistoryColumns",r),e("updateSettings",{keyName:"view.history",newVal:t.view.history})},toggleStatusInHistoryList({commit:s,dispatch:e,state:t},r){const i=[...t.view.history.hidePrintStatus],n=i.indexOf(r);n===-1?i.push(r):i.splice(n,1),s("setHistoryHidePrintStatus",i),e("updateSettings",{keyName:"view.history.hidePrintStatus",newVal:i})},saveExpandPanel({commit:s,dispatch:e,state:t},r){r.value?s("removeClosePanel",{name:r.name,viewport:r.viewport}):s("addClosePanel",{name:r.name,viewport:r.viewport}),e("updateSettings",{keyName:"dashboard.nonExpandPanels.".concat(r.viewport),newVal:t.dashboard.nonExpandPanels[r.viewport]})},resetLayout({dispatch:s},e){var i;const r=(i=xd().dashboard[e])!=null?i:[];s("saveSetting",{name:"dashboard."+e,value:r})},updateGcodeviewerCache({dispatch:s,state:e},t){var i;const r=(i=e.gcodeViewer.klipperCache)!=null?i:{};Object.keys(t).forEach(n=>{const a=t[n],o=n in r?r[n]:null;JSON.stringify(a)!==JSON.stringify(o)&&s("saveSetting",{name:"gcodeViewer.klipperCache.".concat(n),value:a})})},announcementDismissFlag(s,e){window.console.log(e)},setChartDatasetStatus({commit:s,dispatch:e,state:t},r){s("setChartDatasetStatus",r),e("updateSettings",{keyName:"view.tempchart.datasetSettings",newVal:t.view.tempchart.datasetSettings})},setDatasetAdditionalSensorStatus({commit:s,dispatch:e,state:t},r){s("setDatasetAdditionalSensorStatus",r),e("updateSettings",{keyName:"view.tempchart.datasetSettings",newVal:t.view.tempchart.datasetSettings})},setChartColor({commit:s,dispatch:e,state:t},r){s("setChartDatasetStatus",{objectName:r.objectName,dataset:"color",value:r.value}),e("updateSettings",{keyName:"view.tempchart.datasetSettings",newVal:t.view.tempchart.datasetSettings})}},vJ={reset(s){Object.assign(s,xd())},setData(s,e){tf(s,e)},saveSetting(s,e){const t=(r,i,n)=>i!==void 0&&typeof i=="string"?t(r,i.split("."),n):i.length==1&&n!==void 0?r[i[0]]=n:i.length==0?r:(i[0]in r||(r[i[0]]={}),t(r[i[0]],i.slice(1),n));t(s,e.name,e.value)},setHeaterChartVisibility(s,e){const t=s.view.tempchart.hiddenDataset.indexOf(e.name.toUpperCase());e.hidden&&t===-1?s.view.tempchart.hiddenDataset.push(e.name.toUpperCase()):e.hidden!==!0&&t>-1&&s.view.tempchart.hiddenDataset.splice(t,1)},setGcodefilesMetadata(s,e){const t=[...s.view.gcodefiles.hideMetadataColumns],r=t.findIndex(i=>i===e.name);e.value&&r!==-1?t.splice(r,1):!e.value&&r===-1&&t.push(e.name),y.set(s.view.gcodefiles,"hideMetadataColumns",t)},setGcodefilesShowHiddenFiles(s,e){y.set(s.view.gcodefiles,"showHiddenFiles",e)},setCurrentWebcam(s,e){y.set(s.view.webcam.currentCam,e.page,e.value)},setHistoryColumns(s,e){e.value&&s.view.history.hideColums.includes(e.name)?s.view.history.hideColums.splice(s.view.history.hideColums.indexOf(e.name),1):!e.value&&!s.view.history.hideColums.includes(e.name)&&s.view.history.hideColums.push(e.name)},setHistoryHidePrintStatus(s,e){y.set(s.view.history,"hidePrintStatus",e)},addClosePanel(s,e){const t=[...s.dashboard.nonExpandPanels[e.viewport]];t.includes(e.name)||(t.push(e.name),y.set(s.dashboard.nonExpandPanels,e.viewport,t))},removeClosePanel(s,e){const t=[...s.dashboard.nonExpandPanels[e.viewport]],r=t.indexOf(e.name);r>-1&&(t.splice(r,1),y.set(s.dashboard.nonExpandPanels,e.viewport,t))},deleteFromDashboardLayout(s,e){const t=[...s.dashboard[e.layoutname]];t.splice(e.index,1),y.set(s.dashboard,e.layoutname,t)},setChartDatasetStatus(s,e){if(!(e.objectName in s.view.tempchart.datasetSettings)){const t={};t[e.dataset]=e.value,y.set(s.view.tempchart.datasetSettings,e.objectName,t);return}y.set(s.view.tempchart.datasetSettings[e.objectName],e.dataset,e.value)},setDatasetAdditionalSensorStatus(s,e){if(!(e.objectName in s.view.tempchart.datasetSettings)){const t={additionalSensors:{}};t.additionalSensors[e.dataset]=e.value,y.set(s.view.tempchart.datasetSettings,e.objectName,t);return}if(!("additionalSensors"in s.view.tempchart.datasetSettings[e.objectName])){const t={};t[e.dataset]=e.value,y.set(s.view.tempchart.datasetSettings[e.objectName],"additionalSensors",t);return}y.set(s.view.tempchart.datasetSettings[e.objectName].additionalSensors,e.dataset,e.value)}},bJ={theme:s=>{const e=s.uiSettings.theme;return Ci.findIndex(t=>t.name===e)===-1?I_:e},getTheme:(s,e)=>{var t;return(t=Ci.find(r=>r.name===e.theme))!=null?t:Ci[0]},getDatasetValue:s=>e=>e.name in s.view.tempchart.datasetSettings&&e.type in s.view.tempchart.datasetSettings[e.name]?s.view.tempchart.datasetSettings[e.name][e.type]:["temperature","target"].includes(e.type),getDatasetAdditionalSensorValue:s=>e=>e.name in s.view.tempchart.datasetSettings&&"additionalSensors"in s.view.tempchart.datasetSettings[e.name]&&e.sensor in s.view.tempchart.datasetSettings[e.name].additionalSensors?s.view.tempchart.datasetSettings[e.name].additionalSensors[e.sensor]:!0,getPanelExpand:s=>(e,t)=>"dashboard"in s&&t in s.dashboard.nonExpandPanels?!s.dashboard.nonExpandPanels[t].includes(e):!0,getAllPossiblePanels:(s,e,t,r)=>{var u,c,d,m;let i=[...sw];return((u=s.macros)==null?void 0:u.mode)==="expert"&&(e["macros/getAllMacrogroups"].forEach(f=>{i.push("macrogroup_"+f.id)}),i=i.filter(f=>f!=="macros")),r["printer/getKinematics"]==="none"&&(i=i.filter(h=>!["toolhead-control","machine-settings"].includes(h))),r["printer/getExtruders"].length<1&&(i=i.filter(h=>h!=="extruder-control")),((m=(d=(c=t.printer)==null?void 0:c.heaters)==null?void 0:d.available_sensors)!=null?m:[]).length<1&&(i=i.filter(h=>h!=="temperature")),e["webcams/getWebcams"].length===0&&(i=i.filter(h=>h!=="webcam")),t.server.components.includes("spoolman")||(i=i.filter(h=>h!=="spoolman")),i},getPanels:(s,e,t)=>(r,i,n=!1)=>{var u,c;const a=i?"".concat(r,"Layout").concat(i):"".concat(r,"Layout");let o=(c=(u=s.dashboard[a])==null?void 0:u.filter(d=>d!==null))!=null?c:[];const l=e.getAllPossiblePanels;if(i<2){const d=e.getAllPanelsFromViewport(r),m=[];l.forEach(h=>{d.find(f=>f.name===h)||m.push({name:h,visible:!0})}),o=o.concat(m)}if(n&&(o=o.filter(d=>d.visible)),t.gui.macros.mode==="simple")o=o.filter(d=>!d.name.startsWith("macrogroup_"));else{o=o.filter(m=>m.name!=="macros");const d=e["macros/getAllMacrogroups"];d.length&&(o=o.filter(m=>{if(!m.name.startsWith("macrogroup_"))return!0;const h=m.name.slice(11);return d.findIndex(f=>f.id===h)!==-1}))}return o.filter(d=>l.includes(d.name))},getAllPanelsFromViewport:s=>e=>{let t=[];"".concat(e,"Layout")in s.dashboard&&(t=t.concat(s.dashboard["".concat(e,"Layout")]));let r=1;for(;"".concat(e,"Layout").concat(r)in s.dashboard;)t=t.concat(s.dashboard["".concat(e,"Layout").concat(r)]),r++;return t},getDefaultControlActionButton:(s,e,t,r)=>r["printer/existsQGL"]?"qgl":r["printer/existsZtilt"]?"ztilt":"m84",getHours12Format:s=>{const e=s.general.timeFormat;return e==="12hours"?!0:e===null?Intl.DateTimeFormat(navigator.language,{hour:"numeric"}).resolvedOptions().hour12:!1}},yJ={reset({commit:s}){s("reset")},clear({commit:s}){const e=new Date().valueOf();y.$socket.emit("server.database.post_item",{namespace:"mainsail",key:"console.cleared_since",value:e}),s("clear",{cleared_since:e}),s("server/clearGcodeStore",{},{root:!0}),s("server/setConsoleClearedThisSession",{},{root:!0})},saveSetting({dispatch:s},e){s("gui/saveSetting",{name:"console."+e.name,value:e.value},{root:!0})},filterUpload(s,e){y.$socket.emit("server.database.post_item",{namespace:"mainsail",key:"console.consolefilters."+e.id,value:e.value})},filterStore({commit:s,dispatch:e,state:t},r){const i=ds();s("filterStore",{id:i,values:r.values}),e("filterUpload",{id:i,value:t.consolefilters[i]})},filterUpdate({commit:s,dispatch:e,state:t},r){s("filterUpdate",r),e("filterUpload",{id:r.id,value:t.consolefilters[r.id]})},filterDelete({commit:s},e){s("filterDelete",e),y.$socket.emit("server.database.delete_item",{namespace:"mainsail",key:"console.consolefilters."+e})}},CJ={reset(s){Object.assign(s,IC())},clear(s,e){y.set(s,"cleared_since",e.cleared_since)},filterStore(s,e){y.set(s.consolefilters,e.id,e.values)},filterUpdate(s,e){if(!(e.id in s.consolefilters))return;const t={...s.consolefilters[e.id]};Object.assign(t,e.values),y.set(s.consolefilters,e.id,t)},filterDelete(s,e){e in s.consolefilters&&y.delete(s.consolefilters,e)}},$J={getConsolefilters:s=>{const e=[];return Object.keys(s.consolefilters).forEach(t=>{e.push({...s.consolefilters[t],id:t})}),Ft(e,"name")},getConsolefilterRules:(s,e,t)=>{const r=[];return t.gui.console.hideWaitTemperatures&&r.push("^(?:ok\\s+)?(B|C|T\\d*):"),t.gui.console.hideTlCommands&&nw.forEach(i=>{r.push(i)}),Object.keys(s.consolefilters).forEach(i=>{const n=s.consolefilters[i];n.bool&&n.regex.split("\n").forEach(a=>{a!==""&&r.push(a)})}),r},getConsoleClearedSince:s=>s.cleared_since},IC=()=>({hideWaitTemperatures:!0,hideTlCommands:!0,direction:"table",entryStyle:"default",height:300,autoscroll:!0,consolefilters:{},rawOutput:!1}),xJ=IC(),wJ={namespaced:!0,state:xJ,getters:$J,actions:yJ,mutations:CJ},SJ={reset({commit:s}){s("reset")},upload({state:s}){y.$socket.emit("server.database.post_item",{namespace:"mainsail",key:"gcodehistory.entries",value:s.entries})},async addToHistory({commit:s,dispatch:e,state:t},r){const i=[...t.entries];for(i.push(r);i.length>tw;)i.splice(0,1);await s("updateHistory",i),await e("upload")}},PJ={reset(s){Object.assign(s,NC())},updateHistory(s,e){y.set(s,"entries",e)}},DJ={},NC=()=>({entries:[]}),TJ=NC(),OJ={namespaced:!0,state:TJ,getters:DJ,actions:SJ,mutations:PJ},MJ={reset({commit:s}){s("reset")},saveSetting({dispatch:s},e){s("gui/saveSetting",{name:"macros."+e.name,value:e.value},{root:!0})},groupUpload({state:s},e){y.$socket.emit("server.database.post_item",{namespace:"mainsail",key:"macros.macrogroups."+e,value:s.macrogroups[e]})},async groupStore({commit:s,dispatch:e},t){const r=ds();return await s("groupStore",{id:r,values:t.values}),await e("groupUpload",r),r},groupUpdate({commit:s,dispatch:e},t){s("groupUpdate",t),e("groupUpload",t.id)},addMacroToMacrogroup({commit:s,dispatch:e},t){s("addMacroToMacrogroup",t),e("groupUpload",t.id)},updateMacroFromMacrogroup({commit:s,dispatch:e},t){s("updateMacroFromMacrogroup",t),e("groupUpload",t.id)},removeMacroFromMacrogroup({commit:s,dispatch:e},t){s("removeMacroFromMacrogroup",t),e("groupUpload",t.id)},groupDelete({commit:s,dispatch:e,rootState:t},r){s("groupDelete",r),y.$socket.emit("server.database.delete_item",{namespace:"mainsail",key:"macros.macrogroups."+r}),["mobileLayout","tabletLayout1","tabletLayout2","desktopLayout1","desktopLayout2","widescreenLayout1","widescreenLayout2","widescreenLayout3"].forEach(n=>{var l;const o=(t.gui?[...t.gui.dashboard[n]]:[]).findIndex(u=>u.name==="macrogroup_"+r);o!==-1&&(s("gui/deleteFromDashboardLayout",{layoutname:n,index:o},{root:!0}),e("gui/updateSettings",{keyName:"dashboard."+n,newVal:(l=t.gui)==null?void 0:l.dashboard[n]},{root:!0}))})}},kJ={reset(s){Object.assign(s,VC())},groupStore(s,e){y.set(s.macrogroups,e.id,e.values)},groupUpdate(s,e){if(e.id in s.macrogroups){const t={...s.macrogroups[e.id]};Object.assign(t,e.values),y.set(s.macrogroups,e.id,t)}},addMacroToMacrogroup(s,e){var i,n;const t=[...(n=(i=s.macrogroups[e.id])==null?void 0:i.macros)!=null?n:[]],r={pos:1,name:e.macro,color:"group",showInStandby:!0,showInPrinting:!0,showInPause:!0};t.length&&(r.pos=Math.max(...t.map(a=>a.pos))+1),t.push(r),y.set(s.macrogroups[e.id],"macros",t)},updateMacroFromMacrogroup(s,e){var i,n;const t=[...(n=(i=s.macrogroups[e.id])==null?void 0:i.macros)!=null?n:[]],r=t.findIndex(a=>a.name===e.macro);if(r!==-1){const a=t[r];a[e.option]=e.value,y.set(s.macrogroups[e.id],"macros",t)}},removeMacroFromMacrogroup(s,e){var i,n;const t=[...(n=(i=s.macrogroups[e.id])==null?void 0:i.macros)!=null?n:[]],r=t.findIndex(a=>a.name===e.macro);if(r!==-1){const a=t[r].pos;t.splice(r,1),t.filter(o=>o.pos>a).forEach(o=>{o.pos=o.pos-1})}y.set(s.macrogroups[e.id],"macros",t)},groupDelete(s,e){e in s.macrogroups&&y.delete(s.macrogroups,e)}},EJ={getAllMacrogroups:s=>{const e=[];return Object.keys(s.macrogroups).forEach(t=>{e.push({...s.macrogroups[t],id:t})}),Ft(e,"name")},getMacrogroup:s=>e=>s.macrogroups[e]},VC=()=>({mode:"simple",hiddenMacros:[],macrogroups:{}}),LJ=VC(),AJ={namespaced:!0,state:LJ,getters:EJ,actions:MJ,mutations:kJ},FJ={reset({commit:s}){s("reset")},upload({state:s},e){y.$socket.emit("server.database.post_item",{namespace:"mainsail",key:"miscellaneous.entries."+e,value:s.entries[e]})},async store({commit:s,dispatch:e},t){const r=ds();return await s("store",{id:r,values:t}),await e("upload",r),r},async storeLightgroup({commit:s,dispatch:e,getters:t},r){let i=t.getId(r.entry);i===null&&(i=await e("store",r.entry));const n=ds();return await s("updateLightgroup",{entryId:i,lightgroupId:n,values:r.lightgroup}),await e("upload",i),n},async updateLightgroup({commit:s,dispatch:e,getters:t},r){const i=t.getId(r.entry);if(i!==null)return await s("updateLightgroup",{entryId:i,lightgroupId:r.lightgroup.id,values:r.lightgroup}),await e("upload",i),r.lightgroup.id},async deleteLightgroup({commit:s,dispatch:e,getters:t},r){const i=t.getId(r.entry);i!==null&&(await s("destroyLightgroup",{entryId:i,lightgroupId:r.lightgroupId}),await e("upload",i))},async storePreset({commit:s,dispatch:e,getters:t},r){let i=t.getId(r.entry);i===null&&(i=await e("store",r.entry));const n=ds();return await s("updatePreset",{entryId:i,presetId:n,values:r.preset}),await e("upload",i),n},async updatePreset({commit:s,dispatch:e,getters:t},r){const i=t.getId(r.entry);if(i!==null)return await s("updatePreset",{entryId:i,presetId:r.preset.id,values:r.preset}),await e("upload",i),r.preset.id},async deletePreset({commit:s,dispatch:e,getters:t},r){const i=t.getId(r.entry);i!==null&&(await s("destroyPreset",{entryId:i,presetId:r.presetId}),await e("upload",i))}},RJ={reset(s){Object.assign(s,BC())},store(s,e){const t={name:e.values.name,type:e.values.type,lightgroups:{},presets:{}};y.set(s.entries,e.id,t)},updateLightgroup(s,e){const t={name:e.values.name,start:parseInt(e.values.start.toString()),end:parseInt(e.values.end.toString())};y.set(s.entries[e.entryId].lightgroups,e.lightgroupId,t)},destroyLightgroup(s,e){const t={...s.entries};delete t[e.entryId].lightgroups[e.lightgroupId],y.set(s,"entries",t)},updatePreset(s,e){const t={name:e.values.name,red:e.values.red,green:e.values.green,blue:e.values.blue,white:e.values.white};y.set(s.entries[e.entryId].presets,e.presetId,t)},destroyPreset(s,e){const t={...s.entries};delete t[e.entryId].presets[e.presetId],y.set(s,"entries",t)}},HJ={getEntries:s=>{const e=[];return Object.entries(s.entries).forEach(([t,r])=>{e.push({id:t,name:r.name,type:r.type,lightgroups:{...r.lightgroups},presets:{...r.presets}})}),e},getEntry:(s,e)=>t=>e.getEntries.find(r=>r.name===t.name&&r.type===t.type),getId:(s,e)=>t=>{var r,i;return(i=(r=e.getEntry(t))==null?void 0:r.id)!=null?i:null},getEntryLightgroups:(s,e)=>t=>{const r=e.getEntry(t);if(!r)return[];const i=[];return Object.entries(r.lightgroups).forEach(([n,a])=>{i.push({name:a.name,start:a.start,end:a.end,id:n})}),Ft(i,"name")},getEntryPresets:(s,e)=>t=>{const r=e.getEntry(t);if(!r)return[];const i=[];return Object.entries(r.presets).forEach(([n,a])=>{i.push({name:a.name,red:a.red,green:a.green,blue:a.blue,white:a.white,id:n})}),Ft(i,"name")}},BC=()=>({entries:{}}),jJ=BC(),IJ={namespaced:!0,state:jJ,getters:HJ,actions:FJ,mutations:RJ},NJ={reset({commit:s}){s("reset")},upload({state:s}){y.$socket.emit("server.database.post_item",{namespace:"mainsail",key:"navigation.entries",value:s.entries})},updatePos({commit:s},e){s("updatePos",e)},changeVisibility({commit:s,dispatch:e},t){s("changeVisibility",t),e("upload")}},VJ={reset(s){Object.assign(s,UC())},updatePos(s,e){const t=s.entries.findIndex(n=>n.type===e.type&&n.title===e.title);if(t!==-1){s.entries[t].position=e.position;return}const r={type:e.type,title:e.title,visible:e.visible,position:e.position},i=[...s.entries];i.push(r),y.set(s,"entries",i)},changeVisibility(s,e){var a;const t=(a=e.orgTitle)!=null?a:e.title,r=s.entries.findIndex(o=>o.type===e.type&&o.title===t);if(r!==-1){s.entries[r].visible=!e.visible;return}const i={type:e.type,title:t,visible:!e.visible,position:e.position},n=[...s.entries];n.push(i),y.set(s,"entries",n)}},BJ={},UC=()=>({entries:[]}),UJ=UC(),WJ={namespaced:!0,state:UJ,getters:BJ,actions:NJ,mutations:VJ},zJ={reset({commit:s}){s("reset")},upload({state:s}){y.$socket.emit("server.database.post_item",{namespace:"mainsail",key:"notifications.dismiss",value:s.dismiss})},close({dispatch:s},e){const t=e.id.indexOf("/");if(t===-1)return;const r=e.id.slice(0,t),i=e.id.slice(t+1);if(r==="announcement"){s("server/announcements/close",{entry_id:i},{root:!0});return}s("storeDismiss",{entry_id:i,category:r,type:"ever",time:null})},dismiss({dispatch:s},e){const t=e.id.indexOf("/");if(t===-1)return;const r=e.id.slice(0,t),i=e.id.slice(t+1);if(r==="announcement"){s("server/announcements/dismiss",{entry_id:i,time:e.time},{root:!0});return}s("storeDismiss",{entry_id:i,category:r,type:e.type,time:e.time})},async storeDismiss({commit:s,dispatch:e,state:t},r){var a;let i=new Date().getTime();r.type==="time"&&(i=new Date().getTime()+((a=r.time)!=null?a:0)*1e3);const n={id:r.entry_id,category:r.category,type:r.type,date:i};t.dismiss.filter(o=>o.id===n.id&&o.category===n.category&&o.type===n.type).length&&await s("removeDismiss",n),await s("addDismiss",n),await e("upload")}},GJ={reset(s){Object.assign(s,zC())},addDismiss(s,e){const t=[...s.dismiss];t.push(e),y.set(s,"dismiss",t)},removeDismiss(s,e){const t=[...s.dismiss],r=t.findIndex(i=>i.id===e.id&&i.category===e.category&&i.type===e.type);r!==-1&&t.splice(r),y.set(s,"dismiss",t)}};var WC={exports:{}};const ZJ={},qJ=Object.freeze(Object.defineProperty({__proto__:null,default:ZJ},Symbol.toStringTag,{value:"Module"})),h_=E_(qJ);/**
|
||
* [js-sha256]{@link https://github.com/emn178/js-sha256}
|
||
*
|
||
* @version 0.10.1
|
||
* @author Chen, Yi-Cyuan [emn178@gmail.com]
|
||
* @copyright Chen, Yi-Cyuan 2014-2023
|
||
* @license MIT
|
||
*/(function(s){(function(){var e="input is invalid type",t=typeof window=="object",r=t?window:{};r.JS_SHA256_NO_WINDOW&&(t=!1);var i=!t&&typeof self=="object",n=!r.JS_SHA256_NO_NODE_JS&&typeof process=="object"&&process.versions&&process.versions.node;n?r=Tr:i&&(r=self);var a=!r.JS_SHA256_NO_COMMON_JS&&!0&&s.exports,o=!r.JS_SHA256_NO_ARRAY_BUFFER&&typeof ArrayBuffer<"u",l="0123456789abcdef".split(""),u=[-2147483648,8388608,32768,128],c=[24,16,8,0],d=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],m=["hex","array","digest","arrayBuffer"],h=[];(r.JS_SHA256_NO_NODE_JS||!Array.isArray)&&(Array.isArray=function($){return Object.prototype.toString.call($)==="[object Array]"}),o&&(r.JS_SHA256_NO_ARRAY_BUFFER_IS_VIEW||!ArrayBuffer.isView)&&(ArrayBuffer.isView=function($){return typeof $=="object"&&$.buffer&&$.buffer.constructor===ArrayBuffer});var f=function($,D){return function(V){return new M(D,!0).update(V)[$]()}},p=function($){var D=f("hex",$);n&&(D=v(D,$)),D.create=function(){return new M($)},D.update=function(W){return D.create().update(W)};for(var V=0;V<m.length;++V){var N=m[V];D[N]=f(N,$)}return D},v=function($,D){var V=h_,N=h_.Buffer,W=D?"sha224":"sha256",G;N.from&&!r.JS_SHA256_NO_BUFFER_FROM?G=N.from:G=function(X){return new N(X)};var te=function(X){if(typeof X=="string")return V.createHash(W).update(X,"utf8").digest("hex");if(X==null)throw new Error(e);return X.constructor===ArrayBuffer&&(X=new Uint8Array(X)),Array.isArray(X)||ArrayBuffer.isView(X)||X.constructor===N?V.createHash(W).update(G(X)).digest("hex"):$(X)};return te},C=function($,D){return function(V,N){return new F(V,D,!0).update(N)[$]()}},P=function($){var D=C("hex",$);D.create=function(W){return new F(W,$)},D.update=function(W,G){return D.create(W).update(G)};for(var V=0;V<m.length;++V){var N=m[V];D[N]=C(N,$)}return D};function M($,D){D?(h[0]=h[16]=h[1]=h[2]=h[3]=h[4]=h[5]=h[6]=h[7]=h[8]=h[9]=h[10]=h[11]=h[12]=h[13]=h[14]=h[15]=0,this.blocks=h):this.blocks=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],$?(this.h0=3238371032,this.h1=914150663,this.h2=812702999,this.h3=4144912697,this.h4=4290775857,this.h5=1750603025,this.h6=1694076839,this.h7=3204075428):(this.h0=1779033703,this.h1=3144134277,this.h2=1013904242,this.h3=2773480762,this.h4=1359893119,this.h5=2600822924,this.h6=528734635,this.h7=1541459225),this.block=this.start=this.bytes=this.hBytes=0,this.finalized=this.hashed=!1,this.first=!0,this.is224=$}M.prototype.update=function($){if(!this.finalized){var D,V=typeof $;if(V!=="string"){if(V==="object"){if($===null)throw new Error(e);if(o&&$.constructor===ArrayBuffer)$=new Uint8Array($);else if(!Array.isArray($)&&(!o||!ArrayBuffer.isView($)))throw new Error(e)}else throw new Error(e);D=!0}for(var N,W=0,G,te=$.length,X=this.blocks;W<te;){if(this.hashed&&(this.hashed=!1,X[0]=this.block,X[16]=X[1]=X[2]=X[3]=X[4]=X[5]=X[6]=X[7]=X[8]=X[9]=X[10]=X[11]=X[12]=X[13]=X[14]=X[15]=0),D)for(G=this.start;W<te&&G<64;++W)X[G>>2]|=$[W]<<c[G++&3];else for(G=this.start;W<te&&G<64;++W)N=$.charCodeAt(W),N<128?X[G>>2]|=N<<c[G++&3]:N<2048?(X[G>>2]|=(192|N>>6)<<c[G++&3],X[G>>2]|=(128|N&63)<<c[G++&3]):N<55296||N>=57344?(X[G>>2]|=(224|N>>12)<<c[G++&3],X[G>>2]|=(128|N>>6&63)<<c[G++&3],X[G>>2]|=(128|N&63)<<c[G++&3]):(N=65536+((N&1023)<<10|$.charCodeAt(++W)&1023),X[G>>2]|=(240|N>>18)<<c[G++&3],X[G>>2]|=(128|N>>12&63)<<c[G++&3],X[G>>2]|=(128|N>>6&63)<<c[G++&3],X[G>>2]|=(128|N&63)<<c[G++&3]);this.lastByteIndex=G,this.bytes+=G-this.start,G>=64?(this.block=X[16],this.start=G-64,this.hash(),this.hashed=!0):this.start=G}return this.bytes>4294967295&&(this.hBytes+=this.bytes/4294967296<<0,this.bytes=this.bytes%4294967296),this}},M.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var $=this.blocks,D=this.lastByteIndex;$[16]=this.block,$[D>>2]|=u[D&3],this.block=$[16],D>=56&&(this.hashed||this.hash(),$[0]=this.block,$[16]=$[1]=$[2]=$[3]=$[4]=$[5]=$[6]=$[7]=$[8]=$[9]=$[10]=$[11]=$[12]=$[13]=$[14]=$[15]=0),$[14]=this.hBytes<<3|this.bytes>>>29,$[15]=this.bytes<<3,this.hash()}},M.prototype.hash=function(){var $=this.h0,D=this.h1,V=this.h2,N=this.h3,W=this.h4,G=this.h5,te=this.h6,X=this.h7,q=this.blocks,z,K,Q,re,R,B,T,A,H,ee,ie;for(z=16;z<64;++z)R=q[z-15],K=(R>>>7|R<<25)^(R>>>18|R<<14)^R>>>3,R=q[z-2],Q=(R>>>17|R<<15)^(R>>>19|R<<13)^R>>>10,q[z]=q[z-16]+K+q[z-7]+Q<<0;for(ie=D&V,z=0;z<64;z+=4)this.first?(this.is224?(A=300032,R=q[0]-1413257819,X=R-150054599<<0,N=R+24177077<<0):(A=704751109,R=q[0]-210244248,X=R-1521486534<<0,N=R+143694565<<0),this.first=!1):(K=($>>>2|$<<30)^($>>>13|$<<19)^($>>>22|$<<10),Q=(W>>>6|W<<26)^(W>>>11|W<<21)^(W>>>25|W<<7),A=$&D,re=A^$&V^ie,T=W&G^~W&te,R=X+Q+T+d[z]+q[z],B=K+re,X=N+R<<0,N=R+B<<0),K=(N>>>2|N<<30)^(N>>>13|N<<19)^(N>>>22|N<<10),Q=(X>>>6|X<<26)^(X>>>11|X<<21)^(X>>>25|X<<7),H=N&$,re=H^N&D^A,T=X&W^~X&G,R=te+Q+T+d[z+1]+q[z+1],B=K+re,te=V+R<<0,V=R+B<<0,K=(V>>>2|V<<30)^(V>>>13|V<<19)^(V>>>22|V<<10),Q=(te>>>6|te<<26)^(te>>>11|te<<21)^(te>>>25|te<<7),ee=V&N,re=ee^V&$^H,T=te&X^~te&W,R=G+Q+T+d[z+2]+q[z+2],B=K+re,G=D+R<<0,D=R+B<<0,K=(D>>>2|D<<30)^(D>>>13|D<<19)^(D>>>22|D<<10),Q=(G>>>6|G<<26)^(G>>>11|G<<21)^(G>>>25|G<<7),ie=D&V,re=ie^D&N^ee,T=G&te^~G&X,R=W+Q+T+d[z+3]+q[z+3],B=K+re,W=$+R<<0,$=R+B<<0,this.chromeBugWorkAround=!0;this.h0=this.h0+$<<0,this.h1=this.h1+D<<0,this.h2=this.h2+V<<0,this.h3=this.h3+N<<0,this.h4=this.h4+W<<0,this.h5=this.h5+G<<0,this.h6=this.h6+te<<0,this.h7=this.h7+X<<0},M.prototype.hex=function(){this.finalize();var $=this.h0,D=this.h1,V=this.h2,N=this.h3,W=this.h4,G=this.h5,te=this.h6,X=this.h7,q=l[$>>28&15]+l[$>>24&15]+l[$>>20&15]+l[$>>16&15]+l[$>>12&15]+l[$>>8&15]+l[$>>4&15]+l[$&15]+l[D>>28&15]+l[D>>24&15]+l[D>>20&15]+l[D>>16&15]+l[D>>12&15]+l[D>>8&15]+l[D>>4&15]+l[D&15]+l[V>>28&15]+l[V>>24&15]+l[V>>20&15]+l[V>>16&15]+l[V>>12&15]+l[V>>8&15]+l[V>>4&15]+l[V&15]+l[N>>28&15]+l[N>>24&15]+l[N>>20&15]+l[N>>16&15]+l[N>>12&15]+l[N>>8&15]+l[N>>4&15]+l[N&15]+l[W>>28&15]+l[W>>24&15]+l[W>>20&15]+l[W>>16&15]+l[W>>12&15]+l[W>>8&15]+l[W>>4&15]+l[W&15]+l[G>>28&15]+l[G>>24&15]+l[G>>20&15]+l[G>>16&15]+l[G>>12&15]+l[G>>8&15]+l[G>>4&15]+l[G&15]+l[te>>28&15]+l[te>>24&15]+l[te>>20&15]+l[te>>16&15]+l[te>>12&15]+l[te>>8&15]+l[te>>4&15]+l[te&15];return this.is224||(q+=l[X>>28&15]+l[X>>24&15]+l[X>>20&15]+l[X>>16&15]+l[X>>12&15]+l[X>>8&15]+l[X>>4&15]+l[X&15]),q},M.prototype.toString=M.prototype.hex,M.prototype.digest=function(){this.finalize();var $=this.h0,D=this.h1,V=this.h2,N=this.h3,W=this.h4,G=this.h5,te=this.h6,X=this.h7,q=[$>>24&255,$>>16&255,$>>8&255,$&255,D>>24&255,D>>16&255,D>>8&255,D&255,V>>24&255,V>>16&255,V>>8&255,V&255,N>>24&255,N>>16&255,N>>8&255,N&255,W>>24&255,W>>16&255,W>>8&255,W&255,G>>24&255,G>>16&255,G>>8&255,G&255,te>>24&255,te>>16&255,te>>8&255,te&255];return this.is224||q.push(X>>24&255,X>>16&255,X>>8&255,X&255),q},M.prototype.array=M.prototype.digest,M.prototype.arrayBuffer=function(){this.finalize();var $=new ArrayBuffer(this.is224?28:32),D=new DataView($);return D.setUint32(0,this.h0),D.setUint32(4,this.h1),D.setUint32(8,this.h2),D.setUint32(12,this.h3),D.setUint32(16,this.h4),D.setUint32(20,this.h5),D.setUint32(24,this.h6),this.is224||D.setUint32(28,this.h7),$};function F($,D,V){var N,W=typeof $;if(W==="string"){var G=[],te=$.length,X=0,q;for(N=0;N<te;++N)q=$.charCodeAt(N),q<128?G[X++]=q:q<2048?(G[X++]=192|q>>6,G[X++]=128|q&63):q<55296||q>=57344?(G[X++]=224|q>>12,G[X++]=128|q>>6&63,G[X++]=128|q&63):(q=65536+((q&1023)<<10|$.charCodeAt(++N)&1023),G[X++]=240|q>>18,G[X++]=128|q>>12&63,G[X++]=128|q>>6&63,G[X++]=128|q&63);$=G}else if(W==="object"){if($===null)throw new Error(e);if(o&&$.constructor===ArrayBuffer)$=new Uint8Array($);else if(!Array.isArray($)&&(!o||!ArrayBuffer.isView($)))throw new Error(e)}else throw new Error(e);$.length>64&&($=new M(D,!0).update($).array());var z=[],K=[];for(N=0;N<64;++N){var Q=$[N]||0;z[N]=92^Q,K[N]=54^Q}M.call(this,D,V),this.update(K),this.oKeyPad=z,this.inner=!0,this.sharedMemory=V}F.prototype=new M,F.prototype.finalize=function(){if(M.prototype.finalize.call(this),this.inner){this.inner=!1;var $=this.array();M.call(this,this.is224,this.sharedMemory),this.update(this.oKeyPad),this.update($),M.prototype.finalize.call(this)}};var O=p();O.sha256=O,O.sha224=p(!0),O.sha256.hmac=P(),O.sha224.hmac=P(!0),a?s.exports=O:(r.sha256=O.sha256,r.sha224=O.sha224)})()})(WC);var tr=WC.exports,p_=function(s,e,t){if(t||arguments.length===2)for(var r=0,i=e.length,n;r<i;r++)(n||!(r in e))&&(n||(n=Array.prototype.slice.call(e,0,r)),n[r]=e[r]);return s.concat(n||Array.prototype.slice.call(e))},XJ=function(){function s(e,t,r){this.name=e,this.version=t,this.os=r,this.type="browser"}return s}(),YJ=function(){function s(e){this.version=e,this.type="node",this.name="node",this.os=process.platform}return s}(),JJ=function(){function s(e,t,r,i){this.name=e,this.version=t,this.os=r,this.bot=i,this.type="bot-device"}return s}(),KJ=function(){function s(){this.type="bot",this.bot=!0,this.name="bot",this.version=null,this.os=null}return s}(),QJ=function(){function s(){this.type="react-native",this.name="react-native",this.version=null,this.os=null}return s}(),eK=/alexa|bot|crawl(er|ing)|facebookexternalhit|feedburner|google web preview|nagios|postrank|pingdom|slurp|spider|yahoo!|yandex/,tK=/(nuhk|curl|Googlebot|Yammybot|Openbot|Slurp|MSNBot|Ask\ Jeeves\/Teoma|ia_archiver)/,f_=3,sK=[["aol",/AOLShield\/([0-9\._]+)/],["edge",/Edge\/([0-9\._]+)/],["edge-ios",/EdgiOS\/([0-9\._]+)/],["yandexbrowser",/YaBrowser\/([0-9\._]+)/],["kakaotalk",/KAKAOTALK\s([0-9\.]+)/],["samsung",/SamsungBrowser\/([0-9\.]+)/],["silk",/\bSilk\/([0-9._-]+)\b/],["miui",/MiuiBrowser\/([0-9\.]+)$/],["beaker",/BeakerBrowser\/([0-9\.]+)/],["edge-chromium",/EdgA?\/([0-9\.]+)/],["chromium-webview",/(?!Chrom.*OPR)wv\).*Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["chrome",/(?!Chrom.*OPR)Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["phantomjs",/PhantomJS\/([0-9\.]+)(:?\s|$)/],["crios",/CriOS\/([0-9\.]+)(:?\s|$)/],["firefox",/Firefox\/([0-9\.]+)(?:\s|$)/],["fxios",/FxiOS\/([0-9\.]+)/],["opera-mini",/Opera Mini.*Version\/([0-9\.]+)/],["opera",/Opera\/([0-9\.]+)(?:\s|$)/],["opera",/OPR\/([0-9\.]+)(:?\s|$)/],["pie",/^Microsoft Pocket Internet Explorer\/(\d+\.\d+)$/],["pie",/^Mozilla\/\d\.\d+\s\(compatible;\s(?:MSP?IE|MSInternet Explorer) (\d+\.\d+);.*Windows CE.*\)$/],["netfront",/^Mozilla\/\d\.\d+.*NetFront\/(\d.\d)/],["ie",/Trident\/7\.0.*rv\:([0-9\.]+).*\).*Gecko$/],["ie",/MSIE\s([0-9\.]+);.*Trident\/[4-7].0/],["ie",/MSIE\s(7\.0)/],["bb10",/BB10;\sTouch.*Version\/([0-9\.]+)/],["android",/Android\s([0-9\.]+)/],["ios",/Version\/([0-9\._]+).*Mobile.*Safari.*/],["safari",/Version\/([0-9\._]+).*Safari/],["facebook",/FB[AS]V\/([0-9\.]+)/],["instagram",/Instagram\s([0-9\.]+)/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Mobile/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Gecko\)$/],["curl",/^curl\/([0-9\.]+)$/],["searchbot",eK]],g_=[["iOS",/iP(hone|od|ad)/],["Android OS",/Android/],["BlackBerry OS",/BlackBerry|BB10/],["Windows Mobile",/IEMobile/],["Amazon OS",/Kindle/],["Windows 3.11",/Win16/],["Windows 95",/(Windows 95)|(Win95)|(Windows_95)/],["Windows 98",/(Windows 98)|(Win98)/],["Windows 2000",/(Windows NT 5.0)|(Windows 2000)/],["Windows XP",/(Windows NT 5.1)|(Windows XP)/],["Windows Server 2003",/(Windows NT 5.2)/],["Windows Vista",/(Windows NT 6.0)/],["Windows 7",/(Windows NT 6.1)/],["Windows 8",/(Windows NT 6.2)/],["Windows 8.1",/(Windows NT 6.3)/],["Windows 10",/(Windows NT 10.0)/],["Windows ME",/Windows ME/],["Windows CE",/Windows CE|WinCE|Microsoft Pocket Internet Explorer/],["Open BSD",/OpenBSD/],["Sun OS",/SunOS/],["Chrome OS",/CrOS/],["Linux",/(Linux)|(X11)/],["Mac OS",/(Mac_PowerPC)|(Macintosh)/],["QNX",/QNX/],["BeOS",/BeOS/],["OS/2",/OS\/2/]];function rK(s){return typeof document>"u"&&typeof navigator<"u"&&navigator.product==="ReactNative"?new QJ:typeof navigator<"u"?nK(navigator.userAgent):oK()}function iK(s){return s!==""&&sK.reduce(function(e,t){var r=t[0],i=t[1];if(e)return e;var n=i.exec(s);return!!n&&[r,n]},!1)}function nK(s){var e=iK(s);if(!e)return null;var t=e[0],r=e[1];if(t==="searchbot")return new KJ;var i=r[1]&&r[1].split(".").join("_").split("_").slice(0,3);i?i.length<f_&&(i=p_(p_([],i,!0),lK(f_-i.length),!0)):i=[];var n=i.join("."),a=aK(s),o=tK.exec(s);return o&&o[1]?new JJ(t,n,a,o[1]):new XJ(t,n,a)}function aK(s){for(var e=0,t=g_.length;e<t;e++){var r=g_[e],i=r[0],n=r[1],a=n.exec(s);if(a)return i}return null}function oK(){var s=typeof process<"u"&&process.version;return s?new YJ(process.version.slice(1)):null}function lK(s){for(var e=[],t=0;t<s;t++)e.push("0");return e}const cK={getNotifications:(s,e)=>{let t=[];t=t.concat(e.getNotificationsAnnouncements),t=t.concat(e.getNotificationsFlags),t=t.concat(e.getNotificationsDependencies),t=t.concat(e.getNotificationsMoonrakerWarnings),t=t.concat(e.getNotificationsMoonrakerFailedComponents),t=t.concat(e.getNotificationsMoonrakerFailedInitComponents),t=t.concat(e.getNotificationsKlipperWarnings),t=t.concat(e.getNotificationsOverdueMaintenance),t=t.concat(e.getNotificationsBrowserWarnings),t=t.concat(e.getNotificationsOverheatDrivers);const r={normal:2,high:1,critical:0};return t.sort((i,n)=>r[i.priority]<r[n.priority]?-1:r[i.priority]>r[n.priority]?1:n.date.getTime()-i.date.getTime())},getNotificationsAnnouncements:(s,e,t,r)=>{const i=[],n=r["server/announcements/getAnnouncements"];return n.length&&n.forEach(a=>{i.push({id:"announcement/"+a.entry_id,priority:a.priority,title:a.title,description:a.description,date:a.date,dismissed:a.dismissed,url:a.url})}),i},getNotificationsFlags:(s,e,t,r)=>{var a;const i=[];let n=r["server/getThrottledStateFlags"];if(n.length){const o=(a=t.server.system_boot_at)!=null?a:new Date,l=r["gui/notifications/getDismissByCategory"]("flag").map(u=>u.id);n=n.filter(u=>!l.includes(u)),n.forEach(u=>{i.push({id:"flag/"+u,priority:u.startsWith("Previously")?"high":"critical",title:ve.t("App.ThrottledStates.Title".concat(u)),description:ve.t("App.ThrottledStates.Description".concat(u)),date:o,dismissed:!1})})}return i},getNotificationsDependencies:(s,e,t,r)=>{var a;const i=[];let n=r.getDependencies;if(n.length){const o=(a=t.server.system_boot_at)!=null?a:new Date,l=r["gui/notifications/getDismissByCategory"]("dependency").map(u=>u.id);n=n.filter(u=>!l.includes("".concat(u.serviceName,"/").concat(u.neededVersion))),n.forEach(u=>{i.push({id:"dependency/".concat(u.serviceName,"/").concat(u.neededVersion),priority:"high",title:ve.t("App.Notifications.DependencyName",{name:u.serviceName}).toString(),description:ve.t("App.Notifications.DependencyDescription",{name:u.serviceName,installedVersion:u.installedVersion,neededVersion:u.neededVersion}).toString(),date:o,dismissed:!1})})}return i},getNotificationsMoonrakerWarnings:(s,e,t,r)=>{var a,o;const i=[];let n=(a=t.server.warnings)!=null?a:[];if(n.length){const l=(o=t.server.system_boot_at)!=null?o:new Date,u=r["gui/notifications/getDismissByCategory"]("moonrakerWarning").map(c=>c.id);n=n.filter(c=>!u.includes(tr.sha256(c))),n.forEach(c=>{var m,h,f,p;let d=c;if(c.startsWith("Unparsed config option")){const C=(h=(m=RegExp(/'(?<option>.+): (?<value>.+)'.+\[(?<section>.+)\]/).exec(c))==null?void 0:m.groups)!=null?h:{option:"",section:"",value:""};d=ve.t("App.Notifications.MoonrakerWarnings.UnparsedConfigOption",C).toString()}else if(c.startsWith("Unparsed config section")){const C=(p=(f=RegExp(/\[(?<section>.+)\]/).exec(c))==null?void 0:f.groups)!=null?p:{section:""};d=ve.t("App.Notifications.MoonrakerWarnings.UnparsedConfigSection",C).toString()}i.push({id:"moonrakerWarning/".concat(tr.sha256(c)),priority:"high",title:ve.t("App.Notifications.MoonrakerWarnings.MoonrakerWarning").toString(),description:d,date:l,dismissed:!1})})}return i},getNotificationsMoonrakerFailedComponents:(s,e,t,r)=>{var a,o;const i=[];let n=(a=t.server.failed_components)!=null?a:[];if(n.length){const l=(o=t.server.system_boot_at)!=null?o:new Date,u=r["gui/notifications/getDismissByCategory"]("moonrakerFailedComponent").map(c=>c.id);n=n.filter(c=>!u.includes(c)),n.forEach(c=>{i.push({id:"moonrakerFailedComponent/".concat(c),priority:"high",title:ve.t("App.Notifications.MoonrakerWarnings.MoonrakerComponent",{component:c}).toString(),description:ve.t("App.Notifications.MoonrakerWarnings.MoonrakerFailedComponentDescription",{component:c}).toString(),date:l,dismissed:!1})})}return i},getNotificationsMoonrakerFailedInitComponents:(s,e,t,r)=>{var a,o;const i=[];let n=(a=t.server.failed_init_components)!=null?a:[];if(n.length){const l=(o=t.server.system_boot_at)!=null?o:new Date,u=r["gui/notifications/getDismissByCategory"]("moonrakerFailedInitComponent").map(c=>c.id);n=n.filter(c=>!u.includes(c)),n.forEach(c=>{i.push({id:"moonrakerFailedInitComponent/".concat(c),priority:"high",title:ve.t("App.Notifications.MoonrakerWarnings.MoonrakerInitComponent",{component:c}).toString(),description:ve.t("App.Notifications.MoonrakerWarnings.MoonrakerFailedInitComponentDescription",{component:c}).toString(),date:l,dismissed:!1})})}return i},getNotificationsKlipperWarnings:(s,e,t,r)=>{var a,o,l;const i=[];let n=(o=(a=t.printer.configfile)==null?void 0:a.warnings)!=null?o:[];if(n.length){const u=(l=t.server.system_boot_at)!=null?l:new Date,c=r["gui/notifications/getDismissByCategory"]("klipperWarning").map(d=>d.id);n=n.filter(d=>!c.includes(tr.sha256(d.message))),n.forEach(d=>{let m=ve.t("App.Notifications.KlipperWarnings.KlipperWarning").toString(),h=d.message;d.type==="deprecated_value"?(m=ve.t("App.Notifications.KlipperWarnings.DeprecatedValueHeadline").toString(),h=ve.t("App.Notifications.KlipperWarnings.DeprecatedValue",d).toString()):d.type==="deprecated_option"?(m=ve.t("App.Notifications.KlipperWarnings.DeprecatedOptionHeadline").toString(),h=ve.t("App.Notifications.KlipperWarnings.DeprecatedOption",d).toString()):d.type==="runtime_warning"&&(m=ve.t("App.Notifications.KlipperWarnings.KlipperRuntimeWarning").toString());let f="https://docs.mainsail.xyz/faq/klipper_warnings/"+d.type;d.type==="deprecated_option"&&d.option.startsWith("default_parameter")?f+="#default_parameter":d.type==="deprecated_option"?f+="#"+d.option:d.type==="deprecated_value"&&(f+="#"+d.value),i.push({id:"klipperWarning/".concat(tr.sha256(d.message)),priority:"high",title:m,description:h,date:u,url:f,dismissed:!1})})}return i},getNotificationsBrowserWarnings:(s,e,t)=>{var o,l;const r=[],i=rK(),n=(o=t.server.system_boot_at)!=null?o:new Date;if(i===null)return r;window.console.debug("Browser: ".concat(i.name," ").concat(i.version,", OS: ").concat(i.os));const a=Zx.find(u=>u.name.toLowerCase()===i.name.toLowerCase());return a===void 0||nt.valid(i.version)&&nt.valid(a.version)&&nt.gt(a.version,(l=i.version)!=null?l:"0.0.0")&&r.push({id:"browserWarning/".concat(a.name,"/").concat(a.version),priority:"critical",title:ve.t("App.Notifications.BrowserWarnings.Headline").toString(),description:ve.t("App.Notifications.BrowserWarnings.Description",{name:a.name,version:i.version,minVersion:a.version}).toString(),date:n,dismissed:!1}),r},getNotificationsOverdueMaintenance:(s,e,t,r)=>{var l;const i=[];let n=r["gui/maintenance/getOverdueEntries"];if(n.length==0)return[];const a=(l=t.server.system_boot_at)!=null?l:new Date,o=r["gui/notifications/getDismissByCategory"]("maintenance").map(u=>u.id);return n=n.filter(u=>!o.includes(u.id)),n.forEach(u=>{i.push({id:"maintenance/".concat(u.id),priority:"high",title:ve.t("App.Notifications.MaintenanceReminder").toString(),description:ve.t("App.Notifications.MaintenanceReminderText",{name:u.name}).toString(),date:a,dismissed:!1})}),i},getNotificationsOverheatDrivers:(s,e,t)=>{var a;const r=[],i=(a=t.server.system_boot_at)!=null?a:new Date;Object.keys(t.printer).filter(o=>o.startsWith("tmc")).forEach(o=>{var c,d,m,h;const l=t.printer[o],u=o.split(" ")[1];((d=(c=l.drv_status)==null?void 0:c.ot)!=null?d:null)===1&&r.push({id:"tmcwarning/".concat(o,"-ot"),priority:"critical",title:ve.t("App.Notifications.TmcOtFlag").toString(),description:ve.t("App.Notifications.TmcOtFlagText",{name:u}).toString(),date:i,dismissed:!1,url:"https://www.klipper3d.org/TMC_Drivers.html#tmc-reports-error-ot1overtemperror"}),((h=(m=l.drv_status)==null?void 0:m.otpw)!=null?h:null)===1&&r.push({id:"tmcwarning/".concat(o,"-otpw"),priority:"high",title:ve.t("App.Notifications.TmcOtpwFlag").toString(),description:ve.t("App.Notifications.TmcOtpwFlagText",{name:u}).toString(),date:i,dismissed:!1,url:"https://www.klipper3d.org/TMC_Drivers.html#tmc-reports-error-ot1overtemperror"})});const n=e.getDismissByCategory("tmcwarning").map(o=>"tmcwarning/".concat(o.id));return r.filter(o=>!n.includes(o.id))},getDismiss:(s,e,t)=>{var a;const r=new Date,i=(a=t.server.system_boot_at)!=null?a:new Date;let n=[...s.dismiss];return n=n.filter(o=>o.type==="reboot"?i.getTime()<o.date:o.type==="time"?r.getTime()<o.date:!0),n},getDismissByCategory:(s,e)=>t=>{let r=e.getDismiss;return r=r.filter(i=>i.category===t),r}},zC=()=>({dismiss:[]}),uK=zC(),dK={namespaced:!0,state:uK,getters:cK,actions:zJ,mutations:GJ},mK={reset({commit:s}){s("reset")},saveSetting({dispatch:s},e){s("gui/saveSetting",{name:"presets."+e.name,value:e.value},{root:!0})},upload(s,e){y.$socket.emit("server.database.post_item",{namespace:"mainsail",key:"presets.presets."+e.id,value:e.value})},store({commit:s,dispatch:e,state:t},r){const i=ds();s("store",{id:i,values:{...r.values}}),e("upload",{id:i,value:t.presets[i]})},update({commit:s,dispatch:e,state:t},r){s("update",r),e("upload",{id:r.id,value:t.presets[r.id]})},delete({commit:s},e){s("delete",e),y.$socket.emit("server.database.delete_item",{namespace:"mainsail",key:"presets.presets."+e})}},hK={reset(s){Object.assign(s,GC())},initStore(s,e){"cooldownGcode"in e.value&&(y.set(s,"cooldownGcode",e.value.cooldownGcode),delete e.value.cooldownGcode),y.set(s,"presets",e.value)},store(s,e){y.set(s.presets,e.id,e.values)},update(s,e){e.id in s.presets&&y.set(s.presets,e.id,e.values)},updateCooldownGcode(s,e){y.set(s,"cooldownGcode",e)},delete(s,e){e in s.presets&&y.delete(s.presets,e)}},pK={getCooldownGcode:s=>{var e;return(e=s.cooldownGcode)!=null?e:"TURN_OFF_HEATERS"},getPresets:s=>{const e=[];return"presets"in s&&Object.keys(s.presets).forEach(t=>{e.push({...s.presets[t],id:t})}),Ft(e,"name")},getPresetsFromHeater:s=>e=>{const t=[];return t.push({value:0,text:"0 °C"}),"presets"in s?(Object.keys(s.presets).forEach(r=>{var n;const i=s.presets[r];(n=i.values[e.name])!=null&&n.bool&&t.findIndex(a=>{var o,l,u;return a.value===parseFloat((u=(l=(o=i.values[e.name])==null?void 0:o.value)==null?void 0:l.toString())!=null?u:"0")})===-1&&t.push({value:parseFloat(i.values[e.name].value),text:i.values[e.name].value+" °C"})}),t.sort((r,i)=>r.value>i.value?-1:r.value<i.value?1:0)):t}},GC=()=>({presets:{},cooldownGcode:"TURN_OFF_HEATERS"}),fK=GC(),gK={namespaced:!0,state:fK,getters:pK,actions:mK,mutations:hK},_K={reset({commit:s,dispatch:e,state:t}){Object.keys(t.printers).forEach(r=>{e("farm/unregisterPrinter",r,{root:!0})}),s("reset")},initFromLocalstorage({dispatch:s,rootState:e}){var r,i;let t=(r=e.configInstances)!=null?r:[];if(e.instancesDB==="browser"&&(t=JSON.parse((i=localStorage.getItem("printers"))!=null?i:"{}")),Array.isArray(t)){const n={};t.forEach(a=>{const o=ds();n[o]=a}),s("initStore",n)}},async initStore({commit:s,dispatch:e},t){e("reset"),Object.keys(t).forEach(r=>{var n,a,o,l;const i=t[r];s("store",{id:r,values:i}),e("farm/registerPrinter",{id:r,hostname:(n=i.hostname)!=null?n:"",port:(a=i.port)!=null?a:7125,path:(o=i.path)!=null?o:"",settings:(l=i.settings)!=null?l:{}},{root:!0})})},upload({state:s,rootState:e},t){var r;if(e.instancesDB==="browser"){const i=[];Object.keys(s.printers).forEach(n=>{i.push({hostname:s.printers[n].hostname,port:s.printers[n].port,name:s.printers[n].name,path:s.printers[n].path,settings:s.printers[n].settings})}),localStorage.setItem("printers",JSON.stringify(i))}else if(e.instancesDB==="moonraker"&&t in s.printers){const i={hostname:s.printers[t].hostname,port:s.printers[t].port,path:s.printers[t].path,settings:(r=s.printers[t].settings)!=null?r:{}};y.$socket.emit("server.database.post_item",{namespace:"mainsail",key:"remoteprinters.printers."+t,value:i})}},store({commit:s,dispatch:e},t){var i,n,a;const r=ds();s("store",{id:r,values:t.values}),e("farm/registerPrinter",{id:r,hostname:(i=t.values.hostname)!=null?i:"",port:(n=t.values.port)!=null?n:7125,path:(a=t.values.path)!=null?a:"",name:t.values.name},{root:!0}),e("upload",r)},update({commit:s,dispatch:e},t){s("update",t),e("farm/updatePrinter",t,{root:!0}),e("upload",t.id)},updateSettings({commit:s,dispatch:e},t){s("update",{id:t.id,values:{settings:t.values}}),e("upload",t.id)},delete({commit:s,dispatch:e,rootState:t},r){s("delete",r),e("farm/unregisterPrinter",r,{root:!0}),t.instancesDB==="browser"?e("upload"):y.$socket.emit("server.database.delete_item",{namespace:"mainsail",key:"remoteprinters.printers."+r})}},vK={reset(s){Object.assign(s,ZC())},store(s,e){y.set(s.printers,e.id,e.values)},update(s,e){if(e.id in s.printers){const t={...s.printers[e.id]};Object.assign(t,e.values),y.set(s.printers,e.id,t)}},delete(s,e){e in s.printers&&y.delete(s.printers,e)}},bK={getRemoteprinters:(s,e,t,r)=>{const i=[];return Object.keys(s.printers).forEach(n=>{const a={...r["farm/getPrinterSocketState"](n)};i.push({...s.printers[n],id:n,socket:a})}),Ft(i,"hostname")}},ZC=()=>({printers:{}}),yK=ZC(),CK={namespaced:!0,state:yK,getters:bK,actions:_K,mutations:vK},$K={reset({commit:s}){s("reset")},init(){y.$socket.emit("server.database.get_item",{namespace:"maintenance"},{action:"gui/maintenance/initStore"})},async initDb({dispatch:s,rootGetters:e}){var c,d,m;const t=e["socket/getUrl"],r="".concat(t,"/server/files/config/").concat(Si,"/maintenance.json?time=").concat(Date.now()),n=(c=(await fetch(r).then(h=>h.status!==200?{entries:[]}:h.json()).catch(h=>(window.console.error("maintenance.json cannot be parsed",h),{entries:[]}))).entries)!=null?c:[];if((n==null?void 0:n.length)===0){y.$socket.emit("server.database.post_item",{namespace:"maintenance",key:ds(),value:{name:"MAINTENANCE_INIT"}});return}const a=await fetch("".concat(t,"/server/history/totals")).then(h=>h.status!==200?{}:h.json()).then(h=>{var f,p;return(p=(f=h.result)==null?void 0:f.job_totals)!=null?p:{}}).catch(h=>{window.console.debug("History totals could not be loaded",h)}),o=(d=a.total_filament_used)!=null?d:0,l=(m=a.total_print_time)!=null?m:0,u=new Date().getTime()/1e3;n.forEach(h=>{var f,p,v,C,P,M,F,O,$,D,V,N,W,G,te,X,q,z,K,Q,re;s("store",{entry:{name:h.name,note:(f=h.note)!=null?f:"",start_time:u,end_time:null,start_filament:o,end_filament:null,start_printtime:l,end_printtime:null,last_entry:null,reminder:{type:(v=(p=h.reminder)==null?void 0:p.type)!=null?v:null,filament:{bool:(M=(P=(C=h.reminder)==null?void 0:C.filament)==null?void 0:P.bool)!=null?M:!1,value:($=(O=(F=h.reminder)==null?void 0:F.filament)==null?void 0:O.value)!=null?$:null},printtime:{bool:(N=(V=(D=h.reminder)==null?void 0:D.printtime)==null?void 0:V.bool)!=null?N:!1,value:(te=(G=(W=h.reminder)==null?void 0:W.printtime)==null?void 0:G.value)!=null?te:null},date:{bool:(z=(q=(X=h.reminder)==null?void 0:X.date)==null?void 0:q.bool)!=null?z:!1,value:(re=(Q=(K=h.reminder)==null?void 0:K.date)==null?void 0:Q.value)!=null?re:null}}}})})},async initStore({commit:s,dispatch:e},t){var n;await s("reset");const r=(n=t.value)!=null?n:{},i=Object.keys(r).find(a=>{var o;return((o=r[a])==null?void 0:o.name)==="MAINTENANCE_INIT"});i&&delete r[i],await s("initStore",r),await e("socket/removeInitModule","gui/maintenance/init",{root:!0})},upload(s,e){y.$socket.emit("server.database.post_item",{namespace:"maintenance",key:e.id,value:e.value})},store({commit:s,dispatch:e,state:t},r){const i=ds();s("store",{id:i,values:r.entry}),e("upload",{id:i,value:t.entries[i]})},update({commit:s,dispatch:e},t){const r=t.id;delete t.id,s("update",{id:r,entry:t}),e("upload",{id:r,value:t})},delete({commit:s},e){s("delete",e),y.$socket.emit("server.database.delete_item",{namespace:"maintenance",key:e})},perform({dispatch:s,state:e,rootState:t},r){var o,l,u,c,d,m,h,f;const i=e.entries[r.id];if(!i)return;const n=(c=(u=(l=(o=t.server)==null?void 0:o.history)==null?void 0:l.job_totals)==null?void 0:u.total_filament_used)!=null?c:0,a=(f=(h=(m=(d=t.server)==null?void 0:d.history)==null?void 0:m.job_totals)==null?void 0:h.total_print_time)!=null?f:0;if(i.id=r.id,i.end_time=Date.now()/1e3,i.end_filament=n,i.end_printtime=a,i.perform_note=r.note.trim()||null,s("update",i),i.reminder.type==="repeat"){const p=new Date;s("store",{entry:{name:i.name,note:i.note,start_time:p.getTime()/1e3,end_time:null,start_filament:n,end_filament:null,start_printtime:a,end_printtime:null,last_entry:r.id,reminder:{...i.reminder}}})}}},xK={reset(s){Object.assign(s,qC())},initStore(s,e){y.set(s,"entries",e)},store(s,e){y.set(s.entries,e.id,e.values)},update(s,e){if(!(e.id in s.entries))return;const t={...s.entries[e.id]};Object.assign(t,e.entry),y.set(s.entries,e.id,t)},delete(s,e){e in s.entries&&y.delete(s.entries,e)}},wK={getEntries:s=>{const e=[];return Object.keys(s.entries).forEach(t=>{e.push({...s.entries[t],id:t})}),e},getOverdueEntries:(s,e,t)=>{var o,l,u;const r=(o=t.server.history.job_totals.total_print_time)!=null?o:0,i=(l=t.server.history.job_totals.total_filament_used)!=null?l:0,n=new Date().getTime()/1e3;return((u=e.getEntries)!=null?u:[]).filter(c=>{var d,m,h;return c.reminder.type===null||c.end_time!==null?!1:!!(c.reminder.filament.bool&&c.start_filament+((d=c.reminder.filament.value)!=null?d:0)*1e3<=i||c.reminder.printtime.bool&&c.start_printtime+((m=c.reminder.printtime.value)!=null?m:0)*3600<=r||c.reminder.date.bool&&c.start_time+((h=c.reminder.date.value)!=null?h:0)*24*60*60<=n)})}},qC=()=>({entries:{}}),SK=qC(),PK={namespaced:!0,state:SK,getters:wK,actions:$K,mutations:xK},DK={reset({commit:s}){s("reset")},init(){window.console.debug("init gui/webcams"),y.$socket.emit("server.webcams.list",{},{action:"gui/webcams/initStore"})},async initStore({commit:s,dispatch:e},t){await s("reset"),await s("initStore",t.webcams),await e("socket/removeInitModule","gui/webcam/init",{root:!0})},store(s,e){y.$socket.emit("server.webcams.post_item",e)},update({dispatch:s,rootState:e},t){var r;y.$socket.emit("server.webcams.post_item",t.webcam),t.webcam.name!==t.oldWebcamName&&s("delete",t.oldWebcamName),(r=e.server)!=null&&r.components.includes("timelapse")&&s("server/timelapse/updateCamSettings",{newName:t.webcam.name,oldName:t.oldWebcamName},{root:!0})},delete(s,e){y.$socket.emit("server.webcams.delete_item",{name:e})}},TK={reset(s){Object.assign(s,XC())},initStore(s,e){y.set(s,"webcams",e)}},OK={getWebcams:s=>s.webcams.filter(e=>e.enabled),getWebcam:(s,e)=>t=>{var i;return((i=e.getWebcams)!=null?i:[]).find(n=>n.name===t)}},XC=()=>({webcams:[]}),MK=XC(),kK={namespaced:!0,state:MK,getters:OK,actions:DK,mutations:TK},EK={getActiveColorSchemeList:s=>{switch(s.activecolorscheme.toLowerCase()){case"hsv":return["#0000ff","#00ffff","#00ff00","#ffff00","#ff0000"];case"spring":return["#ff00ff","#ffff00"];case"hot":return["#000000","#ff0000","#ffff00","#ffffff"];case"grayscale":return["#ffffff","#000000"];default:return["#313695","#4575b4","#74add1","#abd9e9","#e0f3f8","#ffffbf","#fee090","#fdae61","#f46d43","#d73027","#a50026"]}}},LK={saveActiveColorScheme({commit:s},e){s("saveActiveColorScheme",e)},saveSetting({dispatch:s},e){s("gui/saveSetting",{name:"heightmap."+e.name,value:e.value},{root:!0})}},AK=()=>({activecolorscheme:"portland",defaultOrientation:"rightFront"}),FK=AK(),RK={namespaced:!0,state:FK,getters:EK,actions:LK},xd=()=>({general:{printername:"",language:"en",dateFormat:null,timeFormat:null,calcPrintProgress:"file-relative",calcEstimateTime:["file","filament"],calcEtaTime:["file","filament","slicer"]},control:{style:"bars",actionButton:null,hideDuringPrint:!1,enableXYHoming:!1,feedrateXY:100,stepsXY:[100,10,1],feedrateZ:25,offsetsZ:[.005,.01,.025,.05],offsetZSaveOption:null,stepsZ:[25,1,.1],stepsAll:[.1,1,10,25,50,100],stepsCircleXY:[1,10,50,100],stepsCircleZ:[.1,1,10,50],selectedCrossStep:null,reverseX:!1,reverseY:!1,reverseZ:!1,extruder:{feedamount:25,feedamounts:[50,25,10,5,1],feedrate:5,feedrates:[10,5,2,1],showEstimatedExtrusionInfo:!0}},dashboard:{nonExpandPanels:{mobile:[],tablet:[],desktop:[],widescreen:[]},mobileLayout:[{name:"webcam",visible:!1},{name:"toolhead-control",visible:!0},{name:"extruder-control",visible:!0},{name:"macros",visible:!0},{name:"machine-settings",visible:!0},{name:"miscellaneous",visible:!0},{name:"temperature",visible:!0},{name:"miniconsole",visible:!1}],tabletLayout1:[{name:"webcam",visible:!0},{name:"toolhead-control",visible:!0},{name:"extruder-control",visible:!0},{name:"macros",visible:!0},{name:"machine-settings",visible:!0},{name:"miscellaneous",visible:!0}],tabletLayout2:[{name:"temperature",visible:!0},{name:"miniconsole",visible:!0}],desktopLayout1:[{name:"webcam",visible:!0},{name:"toolhead-control",visible:!0},{name:"extruder-control",visible:!0},{name:"macros",visible:!0},{name:"machine-settings",visible:!0},{name:"miscellaneous",visible:!0}],desktopLayout2:[{name:"temperature",visible:!0},{name:"miniconsole",visible:!0}],widescreenLayout1:[{name:"toolhead-control",visible:!0},{name:"extruder-control",visible:!0},{name:"macros",visible:!0},{name:"miscellaneous",visible:!0}],widescreenLayout2:[{name:"temperature",visible:!0},{name:"machine-settings",visible:!0}],widescreenLayout3:[{name:"webcam",visible:!0},{name:"miniconsole",visible:!0}]},editor:{escToClose:!0,confirmUnsavedChanges:!0,klipperRestartMethod:"FIRMWARE_RESTART",tabSize:2,fileStructureSidebar:!0},gcodeViewer:{extruderColors:["#E76F51FF","#F4A261FF","#E9C46AFF","#2A9D8FFF","#264653FF"],gridColor:"#B3B3B3",backgroundColor:"#121212",colorMode:2,showAxes:!0,minFeed:20,maxFeed:100,minFeedColor:"#2196f3",maxFeedColor:"#D41216",progressColor:"#ECECEC",showCursor:!0,showTravelMoves:!1,showObjectSelection:!1,hdRendering:!1,forceLineRendering:!1,transparency:!1,voxelMode:!1,voxelWidth:1,voxelHeight:1,specularLighting:!1,klipperCache:{kinematics:null,axis_minimum:null,axis_maximum:null},showGCodePanel:!1,cncMode:!1},navigation:{entries:[]},uiSettings:{mode:j_,theme:I_,logo:Ir,primary:al,displayCancelPrint:!1,lockSlidersOnTouchDevices:!0,lockSlidersDelay:1.5,confirmOnEmergencyStop:!1,confirmOnCoolDown:!1,confirmOnPowerDeviceChange:!1,confirmOnCancelJob:!1,boolBigThumbnail:!0,bigThumbnailBackground:At,boolWideNavDrawer:!1,boolHideUploadAndPrintButton:!1,navigationStyle:"iconsAndText",defaultNavigationStateSetting:"alwaysOpen",powerDeviceName:null,progressAsFavicon:!0,hideSaveConfigForBedMash:!1,disableFanAnimation:!1,boolManualProbeDialog:!0,boolBedScrewsDialog:!0,boolScrewsTiltAdjustDialog:!0,tempchartHeight:250,hideUpdateWarnings:!1,printstatusThumbnailZoom:!0,dashboardFilesLimit:5,dashboardFilesFilter:["new","failed","completed"],dashboardHistoryLimit:5,hideOtherInstances:!1},view:{blockFileUpload:!1,configfiles:{countPerPage:10,sortBy:"filename",sortDesc:!1,showHiddenFiles:!1,hideBackupFiles:!1,currentPath:"",rootPath:"config",selectedFiles:[]},extruder:{showTools:!0,showExtrusionFactor:!0,showPressureAdvance:!0,showFirmwareRetraction:!0,showExtruderControl:!0},gcodefiles:{countPerPage:10,sortBy:"modified",sortDesc:!0,showHiddenFiles:!1,showPrintedFiles:!0,hideMetadataColumns:[],orderMetadataColumns:["size","modified","object_height","layer_height","nozzle_diameter","filament_name","filament_type","filament_total","filament_weight_total","estimated_time","last_print_duration","slicer"],currentPath:"",selectedFiles:[]},heightmap:{probed:!0,mesh:!1,flat:!1,wireframe:!0,scaleGradient:!1,scaleZMax:.5},history:{countPerPage:10,toggleChartCol2:"chart",toggleChartCol3:"filament_usage",hidePrintStatus:[],hideColums:["size","modified","end_time","total_duration","filament_total","first_layer_extr_temp","first_layer_bed_temp","first_layer_height","layer_height","object_height"],selectedJobs:[],showMaintenanceEntries:!0,showPrintJobs:!0},jobqueue:{countPerPage:10},lockedSliders:[],tempchart:{boolTempchart:!0,hiddenDataset:[],hideMcuHostSensors:!1,hideMonitors:!1,autoscale:!1,datasetSettings:{}},timelapse:{countPerPage:10,sortBy:"modified",sortDesc:!0,showHiddenFiles:!1,currentPath:"timelapse",selectedFiles:[]},toolhead:{showPosition:!0,showCoordinates:!0,showControl:!0,showZOffset:!0,showSpeedFactor:!0},webcam:{currentCam:{dashboard:"all",page:"all"}}}}),HK=xd(),jK={namespaced:!0,state:HK,getters:bJ,actions:_J,mutations:vJ,modules:{console:wJ,gcodehistory:OJ,macros:AJ,maintenance:PK,miscellaneous:IJ,navigation:WJ,notifications:dK,presets:gK,remoteprinters:CK,webcams:kK,heightmap:RK}},IK={reset({commit:s}){s("reset")},connect({state:s,commit:e,dispatch:t,getters:r,rootGetters:i}){e("setSocketData",{isConnecting:!0});const n=new WebSocket(r.getSocketUrl);n.onopen=()=>{e("setSocketData",{instance:n,reconnects:0,isConnecting:!1,isConnected:!0}),t("sendObj",{method:"server.info",action:"getServerInfo"})},n.onclose=a=>{i["farm/existsPrinter"](s._namespace)&&(!a.wasClean&&s.socket.reconnects<s.socket.maxReconnects?(e("setSocketData",{reconnects:s.socket.reconnects+1}),setTimeout(()=>{t("connect")},s.socket.reconnectInterval)):e("setSocketData",{isConnecting:!1,isConnected:!1,reconnects:0}))},n.onerror=()=>{window.console.error("Farm Printer WebSocket Error")},n.onmessage=a=>{const o=JSON.parse(a.data);if(o&&o.method)switch(o.method){case"notify_status_update":t("getData",o.params[0]);break;case"notify_klippy_disconnected":t("disconnectKlippy");break;case"notify_klippy_ready":t("connectKlippy");break}else if("result"in o){const l=s.socket.wsData.findIndex(u=>u.id===o.id);if(l!==-1&&s.socket.wsData[l].action!==void 0&&s.socket.wsData[l].action!==""){let u=o.result;u==="ok"&&(u={result:u}),typeof u=="string"&&(u={result:u});const c={},d=s.socket.wsData[l];d.actionPreload&&Object.assign(c,d.actionPreload),Object.assign(c,{requestParams:d.params}),Object.assign(c,u),t(d.action,c)}l!==-1&&e("removeWsData",l)}}},reconnect({state:s,dispatch:e}){s.socket.instance&&s.socket.instance.close(),e("connect")},sendObj({state:s,commit:e},t){if(s.socket.instance&&s.socket.instance.readyState===WebSocket.OPEN){const r=Math.floor(Math.random()*1e4)+1;e("addWsData",{id:r,action:t.action,params:t.params||{},actionPreload:t.actionPreload||null}),s.socket.instance.send(JSON.stringify({jsonrpc:"2.0",method:t.method,params:t.params||{},id:r}))}},connectKlippy({commit:s,dispatch:e}){s("setKlippyConnected",!0),e("initPrinter")},disconnectKlippy({commit:s}){s("setKlippyConnected",!1)},getServerInfo({commit:s,dispatch:e},t){s("setKlippyConnected",t.klippy_connected),e("initPrinter")},initPrinter({state:s,commit:e,dispatch:t}){e("resetData"),s.server.klippy_connected&&t("sendObj",{method:"printer.objects.list",action:"getObjectsList"}),t("sendObj",{method:"server.files.list",action:"getConfigDir",params:{root:"config"}}),t("sendObj",{method:"server.database.list",action:"getDatabases"})},getObjectsList({dispatch:s},e){var i;const t=["webhooks","print_stats","virtual_sdcard","display_status","heaters","heater_bed","heater_fan","fan","temperature_fan","temperature_sensor","idle_timeout","toolhead"];let r={};(i=e.objects)==null||i.forEach(n=>{const o=n.split(" ")[0];(t.includes(o)||o.startsWith("extruder"))&&(r={...r,[n]:null})}),Object.keys(r).length>0&&s("sendObj",{method:"printer.objects.subscribe",params:{objects:r},action:"getData"})},getData({commit:s,dispatch:e},t){var i,n,a;const r="status"in t?{...t.status}:{...t};s("setData",r),((n=(i=r.print_stats)==null?void 0:i.filename)!=null?n:"")!==""&&e("sendObj",{method:"server.files.metadata",params:{filename:(a=r.print_stats)==null?void 0:a.filename},action:"getMetadataCurrentFile"})},setSettings({commit:s,dispatch:e,state:t},r){s("setSettings",r),e("gui/remoteprinters/updateSettings",{id:t._namespace,values:t.settings},{root:!0})},getMetadataCurrentFile({commit:s},e){s("setCurrentFile",e)},getConfigDir({commit:s},e){s("setConfigDir",e)},getDatabases({commit:s,dispatch:e},t){s("setDatabases",t.namespaces),t.namespaces.includes("mainsail")&&e("sendObj",{method:"server.database.get_item",params:{namespace:"mainsail"},action:"getMainsailData"}),e("sendObj",{method:"server.webcams.list",action:"getWebcamsData"})},getMainsailData({commit:s},e){s("setMainsailData",e.value)},getWebcamsData({commit:s},e){s("setWebcamsData",e.webcams)}},NK={reset(s){Object.assign(s,vp())},resetData(s){Object.assign(s.data,vp().data)},setSocketData(s,e){"status"in e&&(e=e.status),"requestParams"in e&&delete e.requestParams,"_namespace"in e&&(y.set(s,"_namespace",e._namespace),delete e._namespace),Object.entries(e).forEach(([t,r])=>{y.set(s.socket,t,r)})},setData(s,e){"requestParams"in e&&delete e.requestParams,Object.entries(e).forEach(([t,r])=>{typeof r=="object"?y.set(s.data,t,{...s.data[t],...r}):y.set(s.data,t,r)})},setSettings(s,e){y.set(s,"settings",{...s.settings,...e})},addWsData(s,e){const t=[...s.socket.wsData];t.push(e),y.set(s.socket,"wsData",t)},removeWsData(s,e){const t=[...s.socket.wsData];t.splice(e,1),y.set(s.socket,"wsData",t)},setKlippyConnected(s,e){y.set(s.server,"klippy_connected",e)},setCurrentFile(s,e){"requestParams"in e&&delete e.requestParams,y.set(s,"current_file",e)},setConfigDir(s,e){Object.values(e).forEach(t=>{var r;(r=t.path)!=null&&r.startsWith(".theme/")&&s.theme_files.push(t.path)})},setDatabases(s,e){y.set(s,"databases",e)},setMainsailData(s,e){tf(s.data.gui,e)},setWebcamsData(s,e){y.set(s.data,"webcams",e)}},VK={getSocketUrl:s=>{const e=s.socket.path.replaceAll(/(^\/*)|(\/*$)/g,""),t=e.length>0?"/".concat(e):"";return s.socket.protocol+"://"+s.socket.hostname+":"+s.socket.port+t+"/websocket"},getSocketData:s=>s.socket,isCurrentPrinter:(s,e,t)=>t.socket.hostname===s.socket.hostname&&t.socket.port===s.socket.port,getSetting:s=>(e,t)=>{var r;return(r=s.settings[e])!=null?r:t},getPrinterName:s=>"gui"in s.data&&"general"in s.data.gui&&"printername"in s.data.gui.general&&s.data.gui.general.printername!==""?s.data.gui.general.printername:s.socket.hostname+(s.socket.port!=80?":"+s.socket.port:"")+s.socket.path,getPrinterSocketState:s=>s.socket,getLogoColor:s=>{var e,t,r;return(r=(t=(e=s.data.gui)==null?void 0:e.uiSettings)==null?void 0:t.logo)!=null?r:Ir},getStatus:(s,e)=>{var t,r;if(s.socket.isConnected)if(s.server.klippy_connected){if((r=(t=s.data)==null?void 0:t.print_stats)!=null&&r.state){if(s.data.print_stats.state==="printing"){const i=e.getPrintPercent;return Math.floor(i*100)+"% Printing"}return s.data.print_stats.state.charAt(0).toUpperCase()+s.data.print_stats.state.slice(1)}}else return"ERROR";else return s.socket.isConnecting?"Connecting...":"Disconnected";return"Unknown"},getCurrentFilename:s=>{var e,t;return(t=(e=s.data.print_stats)==null?void 0:e.filename)!=null?t:""},getPrintPercent:(s,e)=>{var r,i,n;switch((n=(i=(r=s.data.gui)==null?void 0:r.general)==null?void 0:i.calcPrintProgress)!=null?n:"file-relative"){case"file-relative":return e.getPrintPercentByFilepositionRelative;case"file-absolute":return e.getPrintPercentByFilepositionAbsolute;case"slicer":return e.getPrintPercentBySlicer;case"filament":return e.getPrintPercentByFilament;default:return e.getPrintPercentByFilepositionRelative}},getPrintPercentByFilepositionRelative:s=>{var e,t,r,i,n,a;if((e=s.current_file)!=null&&e.filename&&((t=s.current_file)!=null&&t.gcode_start_byte)&&((r=s.current_file)!=null&&r.gcode_end_byte)&&s.current_file.filename===s.data.print_stats.filename){if(s.data.virtual_sdcard.file_position<=s.current_file.gcode_start_byte)return 0;if(s.data.virtual_sdcard.file_position>=((i=s.current_file)==null?void 0:i.gcode_end_byte))return 1;const o=s.data.virtual_sdcard.file_position-s.current_file.gcode_start_byte,l=s.current_file.gcode_end_byte-s.current_file.gcode_start_byte;if(o>0&&l>0)return 1/l*o}return(a=(n=s.data.virtual_sdcard)==null?void 0:n.progress)!=null?a:0},getPrintPercentByFilepositionAbsolute:s=>{var e,t;return(t=(e=s.data.virtual_sdcard)==null?void 0:e.progress)!=null?t:0},getPrintPercentBySlicer:s=>{var e,t;return(t=(e=s.data.display_status)==null?void 0:e.progress)!=null?t:0},getPrintPercentByFilament:s=>{var r,i,n,a,o,l;const e=(i=(r=s.data.print_stats)==null?void 0:r.filament_used)!=null?i:null,t=(a=(n=s.current_file)==null?void 0:n.filament_total)!=null?a:null;return e!==null&&t!==null?t==0?0:e/t:(l=(o=s.data.virtual_sdcard)==null?void 0:o.progress)!=null?l:0},getImage:s=>{var e;if(s.current_file.filename&&((e=s.current_file.thumbnails)!=null&&e.length)){const t=s.current_file.filename.lastIndexOf("/"),r=t!==-1?s.current_file.filename.substring(0,t)+"/":"",i=s.current_file.thumbnails.find(o=>o.width>=Ls),n=s.socket.path.replaceAll(/(^\/*)|(\/*$)/g,""),a=n.length>0?"/".concat(n):"";if(i&&"relative_path"in i)return"//"+s.socket.hostname+":"+s.socket.port+a+"/server/files/gcodes/"+r+i.relative_path}return null},getThemeFileUrl:s=>(e,t)=>{const r=s.theme_files.find(a=>a.substr(0,a.lastIndexOf("."))===Si+"/"+e&&t.includes(a.substr(a.lastIndexOf(".")+1))),i=s.socket.path.replaceAll(/(^\/*)|(\/*$)/g,""),n=i.length>0?"/".concat(i):"";return r?"//"+s.socket.hostname+":"+s.socket.port+n+"/server/files/config/"+r:null},getLogo:(s,e)=>{const t="sidebar-logo",r=["gif","jpg","png","gif","svg"];return e.getThemeFileUrl(t,r)},getPosition:s=>"toolhead"in s.data&&"position"in s.data.toolhead?s.data.toolhead.position:[],getPrinterPreview:(s,e,t,r)=>{var n,a,o,l,u,c,d,m;if(!s.server.klippy_connected)return[];const i=[];if(Object.keys(s.data).filter(h=>h.startsWith("extruder")).forEach(h=>{var f,p,v,C;((f=s.data[h])==null?void 0:f.temperature)!==void 0&&((p=s.data[h])==null?void 0:p.target)!==void 0&&i.push({name:Ye(h),value:((v=s.data[h].temperature)==null?void 0:v.toFixed(0))+"° / "+((C=s.data[h].target)==null?void 0:C.toFixed(0))+"°"})}),((n=s.data.heater_bed)==null?void 0:n.temperature)!==void 0&&((a=s.data.heater_bed)==null?void 0:a.target)!==void 0&&i.push({name:Ye("heater_bed"),value:s.data.heater_bed.temperature.toFixed(0)+"° / "+s.data.heater_bed.target.toFixed(0)+"°"}),((o=s.data["temperature_fan chamber"])==null?void 0:o.temperature)!==void 0&&((l=s.data["temperature_fan chamber"])==null?void 0:l.target)!==void 0&&i.push({name:Ye("chamber"),value:s.data["temperature_fan chamber"].temperature.toFixed(0)+"° / "+s.data["temperature_fan chamber"].target.toFixed(0)+"°"}),"temperature_sensor chamber"in s.data&&i.push({name:Ye("chamber"),value:s.data["temperature_sensor chamber"].temperature.toFixed(0)+"°"}),((d=(c=(u=s.data)==null?void 0:u.print_stats)==null?void 0:c.state)!=null?d:"")==="printing"&&e.getPrintPercent>0){const h=(m=r["gui/getHours12Format"])!=null?m:!1,f=new Date(e.estimated_time_eta),p=new Date(f);let v=!0,C=p.getHours();h&&C>11&&(v=!1),h&&C>12&&(C-=12),C<10&&(C="0"+C);const P=p.getMinutes()>=10?p.getMinutes():"0"+p.getMinutes(),M=p.getTime()-new Date().getTime();let F=C+":"+P;h&&(F+=" ".concat(v?"AM":"PM")),M>60*60*24*1e3&&(F+="+".concat(Math.trunc(M/(60*60*24*1e3)))),i.push({name:"ETA",value:e.estimated_time_eta>0?F:"--",file:e.estimated_time_file,filament:e.estimated_time_filament,slicer:e.estimated_time_slicer,eta:e.estimated_time_eta})}return i},estimated_time_file:(s,e)=>{var t;return((t=s.data.print_stats)==null?void 0:t.print_duration)>0&&e.getPrintPercent>0?(s.data.print_stats.print_duration/e.getPrintPercent-s.data.print_stats.print_duration).toFixed(0):0},estimated_time_filament:s=>{var e,t;return(e=s.data.print_stats)!=null&&e.print_duration&&((t=s.data.print_stats)!=null&&t.filament_used)&&s.current_file.filament_total&&s.data.print_stats.filament_used>0&&s.current_file.filament_total>s.data.print_stats.filament_used?(s.data.print_stats.print_duration/(s.data.print_stats.filament_used/s.current_file.filament_total)-s.data.print_stats.print_duration).toFixed(0):0},estimated_time_slicer:s=>{var e,t,r;return s.data.print_stats&&((e=s.data.print_stats)!=null&&e.print_duration)&&((t=s.current_file)!=null&&t.estimated_time)&&((r=s.current_file)==null?void 0:r.estimated_time)>s.data.print_stats.print_duration?(s.current_file.estimated_time-s.data.print_stats.print_duration).toFixed(0):0},estimated_time_eta:(s,e)=>{var o,l,u,c,d,m,h,f,p,v,C,P;let t=0,r=0;const i=(c=(u=(l=(o=s.data.gui)==null?void 0:o.general)==null?void 0:l.calcEtaTime)==null?void 0:u.includes("file"))!=null?c:!0,n=(f=(h=(m=(d=s.data.gui)==null?void 0:d.general)==null?void 0:m.calcEtaTime)==null?void 0:h.includes("filament"))!=null?f:!0,a=(P=(C=(v=(p=s.data.gui)==null?void 0:p.general)==null?void 0:v.calcEtaTime)==null?void 0:C.includes("slicer"))!=null?P:!0;return i&&e.estimated_time_file>0&&(t+=parseInt(e.estimated_time_file),r++),n&&e.estimated_time_filament>0&&(t+=parseInt(e.estimated_time_filament),r++),a&&e.estimated_time_slicer>0&&(t+=parseInt(e.estimated_time_slicer),r++),t&&r?Date.now()+t/r*1e3:0},getPrinterWebcams:s=>s.data.webcams.filter(e=>e.enabled)},vp=()=>({_namespace:"",socket:{instance:null,hostname:"",port:7125,path:"",webPort:80,protocol:document.location.protocol==="https:"?"wss":"ws",isConnected:!1,isConnecting:!1,reconnects:0,maxReconnects:2,reconnectInterval:1e3,wsData:[]},server:{klippy_connected:!1},data:{gui:xd(),webcams:[]},settings:{},databases:[],current_file:{isDirectory:!1,filename:"",modified:new Date,permissions:""},theme_files:[]}),BK=()=>vp(),UK={namespaced:!0,state:BK,getters:VK,actions:IK,mutations:NK},WK=()=>({}),zK=()=>WK(),GK={namespaced:!0,state:zK,getters:{countPrinters:s=>Object.keys(s).length,getPrinters:s=>s,getPrinterName:(s,e)=>t=>e[t+"/getPrinterName"],getPrinterSocketState:(s,e)=>t=>{var r;return(r=e[t+"/getPrinterSocketState"])!=null?r:{isConnecting:!1,isConnected:!1}},existsPrinter:s=>e=>Object.keys(s).includes(e)},actions:{registerPrinter({commit:s,dispatch:e},t){this.hasModule(["farm",t.id])||(this.registerModule(["farm",t.id],UK),s("farm/"+t.id+"/setSocketData",{...t,_namespace:t.id},{root:!0}),"settings"in t&&s("farm/"+t.id+"/setSettings",t.settings,{root:!0}),e("farm/"+t.id+"/connect",{},{root:!0}))},updatePrinter({dispatch:s,commit:e},t){e(t.id+"/setSocketData",{hostname:t.values.hostname,port:t.values.port,path:t.values.path,isConnecting:!0}),s(t.id+"/reconnect")},unregisterPrinter({state:s},e){var t,r;e in s&&((r=(t=s[e].socket)==null?void 0:t.instance)==null||r.close(),this.unregisterModule(["farm",e]))}},mutations:{}},ZK={reset({commit:s}){s("reset")},downloadProgress({commit:s},e){var t,r;s("updateLoader",{direction:e.direction,speed:Xe((t=e.progressEvent.rate)!=null?t:0),loaded:e.progressEvent.loaded,total:(r=e.filesize)!=null?r:e.progressEvent.total})},openFile({state:s,dispatch:e,commit:t,rootGetters:r},i){const n=[];n.push(i.root);let a=i.path;a.slice(0,1)==="/"&&(a=a.slice(1)),a.slice(-1)==="/"&&(a=a.slice(0,-1)),a!==""&&n.push(a),n.push(i.filename);const o=n.join("/"),l=r["socket/getUrl"]+"/server/files/"+Ie(o)+"?".concat(Date.now());s.cancelToken&&e("cancelLoad");const c=Le.CancelToken.source();t("updateCancelTokenSource",c),t("updateLoaderState",!0),t("setFilename",i.filename),t("setPermissions",i.permissions),Le.get(l,{cancelToken:c.token,onDownloadProgress:d=>e("downloadProgress",{progressEvent:d,direction:"downloading",filesize:i.size}),responseType:"blob"}).then(d=>d.data.text()).then(d=>{t("openFile",{filename:i.filename,fileroot:i.root,filepath:a,file:d})}).finally(()=>{setTimeout(()=>{e("clearLoader")},100)})},async saveFile({state:s,commit:e,getters:t,rootGetters:r,dispatch:i},n){const a=new Blob([n.content],{type:"text/plain"}),o=new FormData;o.append("file",a,s.filename),o.append("root",s.fileroot),o.append("path",s.filepath),o.append("checksum",tr.sha256(n.content));const l=r["socket/getUrl"]+"/server/files/upload";s.cancelToken&&i("cancelLoad");const c=Le.CancelToken.source();e("updateCancelTokenSource",c),e("updateLoaderState",!0),Le.post(l,o,{cancelToken:c.token,onUploadProgress:d=>i("downloadProgress",{progressEvent:d,direction:"uploading",filesize:null})}).then(d=>d.data).then(d=>{if(i("clearLoader"),y.$toast.success(ve.t("Editor.SuccessfullySaved",{filename:d.item.path}).toString()),n.restartServiceName==="klipper"){const m=t.getKlipperRestartMethod;y.$socket.emit("printer.gcode.script",{script:m})}else n.restartServiceName==="moonraker"?y.$socket.emit("server.restart",{}):n.restartServiceName!==null&&y.$socket.emit("machine.services.restart",{service:n.restartServiceName});e("updateLoadedHash",n.content),n.restartServiceName!==null&&i("close")}).catch(d=>{var m;window.console.log((m=d.response)==null?void 0:m.data.error),i("clearLoader"),y.$toast.error(ve.t("Editor.FailedSave",{filename:s.filename}).toString())})},cancelLoad({state:s,commit:e,dispatch:t}){s.cancelToken&&(s.cancelToken.cancel("User canceled upload/download"),e("updateCancelTokenSource",null),t("clearLoader"))},clearLoader({commit:s}){s("updateLoaderState",!1),s("updateLoader",{direction:"downloading",loaded:0,total:0,speed:""})},close({commit:s}){s("reset"),window.removeEventListener("beforeunload",Cm)},updateSourcecode({commit:s},e){s("updateSourcecode",e)}},qK={reset(s){Object.assign(s,YC())},updateCancelTokenSource(s,e){y.set(s,"cancelToken",e)},updateLoaderState(s,e){y.set(s,"loaderBool",e)},updateLoader(s,e){y.set(s,"loaderProgress",e)},openFile(s,e){y.set(s,"filename",e.filename),y.set(s,"fileroot",e.fileroot),y.set(s,"filepath",e.filepath),y.set(s,"sourcecode",e.file),y.set(s,"loadedHash",tr.sha256(e.file.replace(/(?:\r\n|\r|\n)/g,"\n"))),y.set(s,"changed",!1),y.set(s,"bool",!0)},showEditor(s){y.set(s,"bool",!0)},setFilename(s,e){y.set(s,"filename",e)},setPermissions(s,e){y.set(s,"permissions",e)},hideEditor(s){y.set(s,"bool",!1)},updateSourcecode(s,e){y.set(s,"sourcecode",e),s.changed=tr.sha256(e)!=s.loadedHash},updateLoadedHash(s,e){y.set(s,"loadedHash",tr.sha256(e.replace(/(?:\r\n|\r|\n)/g,"\n"))),y.set(s,"changed",!1)}},XK={getKlipperRestartMethod:(s,e,t)=>{var r,i;return(i=(r=t.gui.editor)==null?void 0:r.klipperRestartMethod)!=null?i:"FIRMWARE_RESTART"}},YC=()=>({bool:!1,filename:"",permissions:"",fileroot:"",filepath:"",sourcecode:"",loaderBool:!1,loaderProgress:{direction:"downloading",loaded:0,total:0,speed:""},cancelToken:null,loadedHash:"",changed:!1}),YK=YC(),JK={namespaced:!0,state:YK,getters:XK,actions:ZK,mutations:qK},KK={reset({commit:s}){s("reset")},setViewerBackup({commit:s},e){s("setViewerBackup",e)},setCanvasBackup({commit:s},e){s("setCanvasBackup",e)},setLoadedFileBackup({commit:s},e){s("setLoadedFileBackup",e)}},QK={reset(s){Object.assign(s,JC())},setViewerBackup(s,e){y.set(s,"viewerBackup",V$(e))},setCanvasBackup(s,e){y.set(s,"canvasBackup",e)},setLoadedFileBackup(s,e){y.set(s,"loadedFileBackup",e)}},eQ={},JC=()=>({viewerBackup:null,canvasBackup:null,loadedFileBackup:null}),tQ=JC(),sQ={namespaced:!0,state:tQ,getters:eQ,actions:KK,mutations:QK};y.use(SC);const rQ=()=>({packageVersion:"2.14.0",debugMode:!1,naviDrawer:null,instancesDB:"moonraker",configInstances:[]}),iQ=rQ(),Pr=new SC.Store({state:iQ,modules:{socket:uY,server:tJ,printer:dJ,files:gJ,gui:jK,farm:GK,editor:JK,gcodeviewer:sQ},getters:nY,mutations:iY,actions:rY});class nQ{constructor(e){this.url="",this.instance=null,this.maxReconnects=5,this.reconnectInterval=1e3,this.reconnects=0,this.keepAliveTimeout=1e3,this.messageId=0,this.timerId=null,this.store=null,this.waits=[],this.heartbeatTimer=null,this.url=e.url,this.maxReconnects=e.maxReconnects||5,this.reconnectInterval=e.reconnectInterval||1e3,this.store=e.store}setUrl(e){this.url=e}handleMessage(e){var r,i,n,a,o,l,u,c,d,m,h,f,p;const t=this.getWaitById(e.id);if("error"in e&&(t!=null&&t.reject)){t.reject(e.error),this.removeWaitById(t.id);return}if((r=e.error)!=null&&r.message){if(((i=e.error)==null?void 0:i.message)!=="Klippy Disconnected"&&window.console.error("Response Error: ".concat(e.error.message," (").concat((n=t==null?void 0:t.action)!=null?n:"no action",")")),t){const v=(o=(a=t.action)==null?void 0:a.split("/")[1])!=null?o:null;if(v&&((l=t.action)!=null&&l.startsWith("server/"))&&B_.includes(v)&&((c=(u=this.store)==null?void 0:u.state.socket)!=null&&c.initializationList.length)){const C=t.action.replace("server/","").split("/")[0];window.console.error("init server component ".concat(C," failed")),(d=this.store)==null||d.dispatch("server/addFailedInitComponent",C),(m=this.store)==null||m.dispatch("socket/removeInitComponent","server/".concat(C,"/"))}this.removeWaitById(t.id)}return}if(!t){(h=this.store)==null||h.dispatch("socket/onMessage",e);return}if(t!=null&&t.resolve&&t.resolve((f=e.result)!=null?f:{}),t.action){let v=e.result;v==="ok"&&(v={result:v}),typeof v=="string"&&(v={result:v});const C={};t.actionPayload&&Object.assign(C,t.actionPayload),Object.assign(C,{requestParams:t.params}),Object.assign(C,v),(p=this.store)==null||p.dispatch(t.action,C)}this.removeWaitById(t.id)}async connect(){var e,t;(e=this.store)==null||e.dispatch("socket/setData",{isConnecting:!0}),(t=this.instance)==null||t.close(),this.instance=new WebSocket(this.url),this.instance.onopen=()=>{var r;this.reconnects=0,(r=this.store)==null||r.dispatch("socket/onOpen",event)},this.instance.onclose=r=>{var i;if(r.wasClean||this.reconnects>=this.maxReconnects){(i=this.store)==null||i.dispatch("socket/onClose",r);return}this.reconnects++,setTimeout(()=>{this.connect()},this.reconnectInterval)},this.instance.onerror=()=>{var r;(r=this.instance)==null||r.close()},this.instance.onmessage=r=>{if(this.store===null)return;this.heartbeat();const i=JSON.parse(r.data);if(Array.isArray(i)){for(const n of i)this.handleMessage(n);return}this.handleMessage(i)}}close(){var e;(e=this.instance)==null||e.close()}getWaitById(e){var t;return(t=this.waits.find(r=>r.id===e))!=null?t:null}removeWaitById(e){var r;const t=this.waits.findIndex(i=>i.id===e);if(t){const i=this.waits[t];i.loading&&((r=this.store)==null||r.dispatch("socket/removeLoading",{name:i.loading})),this.waits.splice(t,1)}}emit(e,t,r={}){var n,a,o,l,u,c;if(((n=this.instance)==null?void 0:n.readyState)!==WebSocket.OPEN)return;const i=this.messageId++;this.waits.push({id:i,params:t,action:(a=r.action)!=null?a:null,actionPayload:(o=r.actionPayload)!=null?o:{},loading:(l=r.loading)!=null?l:null}),r.loading&&((u=this.store)==null||u.dispatch("socket/addLoading",{name:r.loading})),(c=this.instance)==null||c.send(JSON.stringify({jsonrpc:"2.0",method:e,params:t,id:i}))}async emitAndWait(e,t=void 0,r={}){return new Promise((i,n)=>{var o,l,u,c,d,m;((o=this.instance)==null?void 0:o.readyState)!==WebSocket.OPEN&&n();const a=this.messageId++;this.waits.push({id:a,params:t,action:(l=r.action)!=null?l:null,actionPayload:(u=r.actionPayload)!=null?u:{},loading:(c=r.loading)!=null?c:null,resolve:i,reject:n}),r.loading&&((d=this.store)==null||d.dispatch("socket/addLoading",{name:r.loading})),(m=this.instance)==null||m.send(JSON.stringify({jsonrpc:"2.0",method:e,params:t,id:a}))})}emitBatch(e){var r,i,n,a,o;if(e.length===0||((r=this.instance)==null?void 0:r.readyState)!==WebSocket.OPEN)return;const t=[];for(const{method:l,params:u,emitOptions:c={}}of e){const d=this.messageId++;this.waits.push({id:d,params:u,action:(i=c.action)!=null?i:null,actionPayload:(n=c.actionPayload)!=null?n:{},loading:(a=c.loading)!=null?a:null}),c.loading&&((o=this.store)==null||o.dispatch("socket/addLoading",{name:c.loading})),t.push({jsonrpc:"2.0",method:l,params:u,id:d})}this.instance.send(JSON.stringify(t))}heartbeat(){this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.heartbeatTimer=window.setTimeout(()=>{var e,t;((e=this.instance)==null?void 0:e.readyState)!==WebSocket.OPEN||!this.store||(this.close(),(t=this.store)==null||t.dispatch("socket/onClose"))},1e4)}}function aQ(s,e){const t=new nQ(e);s.prototype.$socket=t,s.$socket=t}function el(s){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?el=function(e){return typeof e}:el=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},el(s)}function oQ(s,e){if(!(s instanceof e))throw new TypeError("Cannot call a class as a function")}function lQ(s,e){for(var t=0;t<e.length;t++){var r=e[t];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(s,r.key,r)}}function cQ(s,e,t){return e&&lQ(s.prototype,e),s}function __(s){return uQ(s)||dQ(s)||mQ()}function uQ(s){if(Array.isArray(s)){for(var e=0,t=new Array(s.length);e<s.length;e++)t[e]=s[e];return t}}function dQ(s){if(Symbol.iterator in Object(s)||Object.prototype.toString.call(s)==="[object Arguments]")return Array.from(s)}function mQ(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function hQ(s){var e;return typeof s=="function"?e={callback:s}:e=s,e}function pQ(s,e){var t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r,i,n,a=function(l){for(var u=arguments.length,c=new Array(u>1?u-1:0),d=1;d<u;d++)c[d-1]=arguments[d];if(n=c,!(r&&l===i)){var m=t.leading;typeof m=="function"&&(m=m(l,i)),(!r||l!==i)&&m&&s.apply(void 0,[l].concat(__(n))),i=l,clearTimeout(r),r=setTimeout(function(){s.apply(void 0,[l].concat(__(n))),r=0},e)}};return a._clear=function(){clearTimeout(r),r=null},a}function KC(s,e){if(s===e)return!0;if(el(s)==="object"){for(var t in s)if(!KC(s[t],e[t]))return!1;return!0}return!1}var fQ=function(){function s(e,t,r){oQ(this,s),this.el=e,this.observer=null,this.frozen=!1,this.createObserver(t,r)}return cQ(s,[{key:"createObserver",value:function(t,r){var i=this;if(this.observer&&this.destroyObserver(),!this.frozen){if(this.options=hQ(t),this.callback=function(o,l){i.options.callback(o,l),o&&i.options.once&&(i.frozen=!0,i.destroyObserver())},this.callback&&this.options.throttle){var n=this.options.throttleOptions||{},a=n.leading;this.callback=pQ(this.callback,this.options.throttle,{leading:function(l){return a==="both"||a==="visible"&&l||a==="hidden"&&!l}})}this.oldResult=void 0,this.observer=new IntersectionObserver(function(o){var l=o[0];if(o.length>1){var u=o.find(function(d){return d.isIntersecting});u&&(l=u)}if(i.callback){var c=l.isIntersecting&&l.intersectionRatio>=i.threshold;if(c===i.oldResult)return;i.oldResult=c,i.callback(c,l)}},this.options.intersection),r.context.$nextTick(function(){i.observer&&i.observer.observe(i.el)})}}},{key:"destroyObserver",value:function(){this.observer&&(this.observer.disconnect(),this.observer=null),this.callback&&this.callback._clear&&(this.callback._clear(),this.callback=null)}},{key:"threshold",get:function(){return this.options.intersection&&typeof this.options.intersection.threshold=="number"?this.options.intersection.threshold:0}}]),s}();function QC(s,e,t){var r=e.value;if(r)if(typeof IntersectionObserver>"u")console.warn("[vue-observe-visibility] IntersectionObserver API is not available in your browser. Please install this polyfill: https://github.com/w3c/IntersectionObserver/tree/master/polyfill");else{var i=new fQ(s,r,t);s._vue_visibilityState=i}}function gQ(s,e,t){var r=e.value,i=e.oldValue;if(!KC(r,i)){var n=s._vue_visibilityState;if(!r){e$(s);return}n?n.createObserver(r,t):QC(s,{value:r},t)}}function e$(s){var e=s._vue_visibilityState;e&&(e.destroyObserver(),delete s._vue_visibilityState)}var t$={bind:QC,update:gQ,unbind:e$};function _Q(s){s.directive("observe-visibility",t$)}var vQ={version:"1.0.0",install:_Q},Xc=null;typeof window<"u"?Xc=window.Vue:typeof global<"u"&&(Xc=global.Vue);Xc&&Xc.use(vQ);var bQ=function(e){return yQ(e)&&!CQ(e)};function yQ(s){return!!s&&typeof s=="object"}function CQ(s){var e=Object.prototype.toString.call(s);return e==="[object RegExp]"||e==="[object Date]"||wQ(s)}var $Q=typeof Symbol=="function"&&Symbol.for,xQ=$Q?Symbol.for("react.element"):60103;function wQ(s){return s.$$typeof===xQ}function SQ(s){return Array.isArray(s)?[]:{}}function Na(s,e){return e.clone!==!1&&e.isMergeableObject(s)?Qi(SQ(s),s,e):s}function PQ(s,e,t){return s.concat(e).map(function(r){return Na(r,t)})}function DQ(s,e){if(!e.customMerge)return Qi;var t=e.customMerge(s);return typeof t=="function"?t:Qi}function TQ(s){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(s).filter(function(e){return Object.propertyIsEnumerable.call(s,e)}):[]}function v_(s){return Object.keys(s).concat(TQ(s))}function s$(s,e){try{return e in s}catch{return!1}}function OQ(s,e){return s$(s,e)&&!(Object.hasOwnProperty.call(s,e)&&Object.propertyIsEnumerable.call(s,e))}function MQ(s,e,t){var r={};return t.isMergeableObject(s)&&v_(s).forEach(function(i){r[i]=Na(s[i],t)}),v_(e).forEach(function(i){OQ(s,i)||(s$(s,i)&&t.isMergeableObject(e[i])?r[i]=DQ(i,t)(s[i],e[i],t):r[i]=Na(e[i],t))}),r}function Qi(s,e,t){t=t||{},t.arrayMerge=t.arrayMerge||PQ,t.isMergeableObject=t.isMergeableObject||bQ,t.cloneUnlessOtherwiseSpecified=Na;var r=Array.isArray(e),i=Array.isArray(s),n=r===i;return n?r?t.arrayMerge(s,e,t):MQ(s,e,t):Na(e,t)}Qi.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(r,i){return Qi(r,i,t)},{})};var kQ=Qi,EQ=kQ;const LQ=en(EQ);/**
|
||
* vue-meta v2.4.0
|
||
* (c) 2020
|
||
* - Declan de Wet
|
||
* - Sébastien Chopin (@Atinux)
|
||
* - Pim (@pimlie)
|
||
* - All the amazing contributors
|
||
* @license MIT
|
||
*/var AQ="2.4.0";function Gn(s){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Gn=function(e){return typeof e}:Gn=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Gn(s)}function bp(s,e,t){return e in s?Object.defineProperty(s,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):s[e]=t,s}function b_(s,e){var t=Object.keys(s);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(s);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(s,i).enumerable})),t.push.apply(t,r)}return t}function as(s){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?b_(Object(t),!0).forEach(function(r){bp(s,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(s,Object.getOwnPropertyDescriptors(t)):b_(Object(t)).forEach(function(r){Object.defineProperty(s,r,Object.getOwnPropertyDescriptor(t,r))})}return s}function r$(s){return FQ(s)||RQ(s)||i$(s)||HQ()}function FQ(s){if(Array.isArray(s))return yp(s)}function RQ(s){if(typeof Symbol<"u"&&Symbol.iterator in Object(s))return Array.from(s)}function i$(s,e){if(s){if(typeof s=="string")return yp(s,e);var t=Object.prototype.toString.call(s).slice(8,-1);if(t==="Object"&&s.constructor&&(t=s.constructor.name),t==="Map"||t==="Set")return Array.from(s);if(t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return yp(s,e)}}function yp(s,e){(e==null||e>s.length)&&(e=s.length);for(var t=0,r=new Array(e);t<e;t++)r[t]=s[t];return r}function HQ(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function jQ(s,e){var t;if(typeof Symbol>"u"||s[Symbol.iterator]==null){if(Array.isArray(s)||(t=i$(s))||e){t&&(s=t);var r=0,i=function(){};return{s:i,n:function(){return r>=s.length?{done:!0}:{done:!1,value:s[r++]}},e:function(l){throw l},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var n=!0,a=!1,o;return{s:function(){t=s[Symbol.iterator]()},n:function(){var l=t.next();return n=l.done,l},e:function(l){a=!0,o=l},f:function(){try{!n&&t.return!=null&&t.return()}finally{if(a)throw o}}}}function Yc(s){return Array.isArray(s)}function Rs(s){return typeof s>"u"}function wd(s){return Gn(s)==="object"}function y_(s){return Gn(s)==="object"&&s!==null}function Sd(s){return typeof s=="function"}function IQ(s){return typeof s=="string"}function NQ(){try{return!Rs(window)}catch{return!1}}var VQ=NQ(),BQ=VQ?window:global,im=BQ.console||{};function Jc(s){!im||!im.warn||im.warn(s)}var n$=function(){return Jc("This vue app/component has no vue-meta configuration")},wg={title:void 0,titleChunk:"",titleTemplate:"%s",htmlAttrs:{},bodyAttrs:{},headAttrs:{},base:[],link:[],meta:[],style:[],script:[],noscript:[],__dangerouslyDisableSanitizers:[],__dangerouslyDisableSanitizersByTagID:{}},Te="_vueMeta",UQ="metaInfo",WQ="data-vue-meta",zQ="data-vue-meta-server-rendered",GQ="vmid",ZQ="template",qQ="content",XQ="ssr",YQ=10,JQ=!0,ks={keyName:UQ,attribute:WQ,ssrAttribute:zQ,tagIDKeyName:GQ,contentKeyName:qQ,metaTemplateKeyName:ZQ,waitOnDestroyed:JQ,debounceWait:YQ,ssrAppId:XQ},Hr=Object.keys(wg),Kc=[Hr[12],Hr[13]],Sg=[Hr[1],Hr[2],"changed"].concat(Kc),Pd=[Hr[3],Hr[4],Hr[5]],KQ=["link","style","script"],QQ=["base","meta","link"],eee=["noscript","script","style"],tee=["innerHTML","cssText","json"],a$=["once","skip","template"],o$=["body","pbody"],go=["allowfullscreen","amp","amp-boilerplate","async","autofocus","autoplay","checked","compact","controls","declare","default","defaultchecked","defaultmuted","defaultselected","defer","disabled","enabled","formnovalidate","hidden","indeterminate","inert","ismap","itemscope","loop","multiple","muted","nohref","noresize","noshade","novalidate","nowrap","open","pauseonexit","readonly","required","reversed","scoped","seamless","selected","sortable","truespeed","typemustmatch","visible"],nm=null;function Mn(s,e,t){var r=s.debounceWait;!e[Te].initialized&&(e[Te].initializing||t==="watcher")&&(e[Te].initialized=null),e[Te].initialized&&!e[Te].pausing&&see(function(){return void e.$meta().refresh()},r)}function see(s,e){if(e=e===void 0?10:e,!e){s();return}return clearTimeout(nm),nm=setTimeout(function(){s()},e),nm}function ree(s,e,t){if(!Array.prototype.find){for(var r=0;r<s.length;r++)if(e.call(t,s[r],r,s))return s[r];return}return s.find(e,t)}function l$(s,e,t){if(!Array.prototype.findIndex){for(var r=0;r<s.length;r++)if(e.call(t,s[r],r,s))return r;return-1}return s.findIndex(e,t)}function Pg(s){return Array.from?Array.from(s):Array.prototype.slice.call(s)}function us(s,e){if(!Array.prototype.includes){for(var t in s)if(s[t]===e)return!0;return!1}return s.includes(e)}var Dg=function(e,t){return(t||document).querySelectorAll(e)};function yi(s,e){return s[e]||(s[e]=document.getElementsByTagName(e)[0]),s[e]}function iee(s){var e=s.body,t=s.pbody;return e?"body":t?"pbody":"head"}function am(s,e,t){var r=e.appId,i=e.attribute,n=e.type,a=e.tagIDKeyName;t=t||{};var o=["".concat(n,"[").concat(i,'="').concat(r,'"]'),"".concat(n,"[data-").concat(a,"]")].map(function(l){for(var u in t){var c=t[u],d=c&&c!==!0?'="'.concat(c,'"'):"";l+="[data-".concat(u).concat(d,"]")}return l});return Pg(Dg(o.join(", "),s))}function nee(s,e){var t=s.attribute;Pg(Dg("[".concat(t,'="').concat(e,'"]'))).map(function(r){return r.remove()})}function Qc(s,e){s.removeAttribute(e)}function Cp(s){return s=s||this,s&&(s[Te]===!0||wd(s[Te]))}function aee(s){return s=s||this,s&&!Rs(s[Te])}function c$(s,e){return s[Te].pausing=!0,function(){return Tg(s)}}function Tg(s,e){return s[Te].pausing=!1,s.$meta().refresh()}function $p(s){var e=s.$router;s[Te].navGuards||!e||(s[Te].navGuards=!0,e.beforeEach(function(t,r,i){c$(s),i()}),e.afterEach(function(){s.$nextTick(function(){var t=Tg(s),r=t.metaInfo;r&&Sd(r.afterNavigation)&&r.afterNavigation(r)})}))}var C_=1;function oee(s,e){var t=["activated","deactivated","beforeMount"],r=!1;return{beforeCreate:function(){var n=this,a="$root",o=this[a],l=this.$options,u=s.config.devtools;if(Object.defineProperty(this,"_hasMetaInfo",{configurable:!0,get:function(){return u&&!o[Te].deprecationWarningShown&&(Jc("VueMeta DeprecationWarning: _hasMetaInfo has been deprecated and will be removed in a future version. Please use hasMetaInfo(vm) instead"),o[Te].deprecationWarningShown=!0),Cp(this)}}),this===o&&o.$once("hook:beforeMount",function(){if(r=this.$el&&this.$el.nodeType===1&&this.$el.hasAttribute("data-server-rendered"),!r&&o[Te]&&o[Te].appId===1){var d=yi({},"html");r=d&&d.hasAttribute(e.ssrAttribute)}}),!(Rs(l[e.keyName])||l[e.keyName]===null)){if(o[Te]||(o[Te]={appId:C_},C_++,u&&o.$options[e.keyName]&&this.$nextTick(function(){var d=ree(o.$children,function(m){return m.$vnode&&m.$vnode.fnOptions});d&&d.$vnode.fnOptions[e.keyName]&&Jc("VueMeta has detected a possible global mixin which adds a ".concat(e.keyName," property to all Vue components on the page. This could cause severe performance issues. If possible, use $meta().addApp to add meta information instead"))})),!this[Te]){this[Te]=!0;for(var c=this.$parent;c&&c!==o;)Rs(c[Te])&&(c[Te]=!1),c=c.$parent}Sd(l[e.keyName])&&(l.computed=l.computed||{},l.computed.$metaInfo=l[e.keyName],this.$isServer||this.$on("hook:created",function(){this.$watch("$metaInfo",function(){Mn(e,this[a],"watcher")})})),Rs(o[Te].initialized)&&(o[Te].initialized=this.$isServer,o[Te].initialized||(o[Te].initializedSsr||(o[Te].initializedSsr=!0,this.$on("hook:beforeMount",function(){var d=this[a];r&&(d[Te].appId=e.ssrAppId)})),this.$on("hook:mounted",function(){var d=this[a];d[Te].initialized||(d[Te].initializing=!0,this.$nextTick(function(){var m=d.$meta().refresh(),h=m.tags,f=m.metaInfo;h===!1&&d[Te].initialized===null&&this.$nextTick(function(){return Mn(e,d,"init")}),d[Te].initialized=!0,delete d[Te].initializing,!e.refreshOnceOnNavigation&&f.afterNavigation&&$p(d)}))}),e.refreshOnceOnNavigation&&$p(o))),this.$on("hook:destroyed",function(){var d=this;!this.$parent||!Cp(this)||(delete this._hasMetaInfo,this.$nextTick(function(){if(!e.waitOnDestroyed||!d.$el||!d.$el.offsetParent){Mn(e,d.$root,"destroyed");return}var m=setInterval(function(){d.$el&&d.$el.offsetParent!==null||(clearInterval(m),Mn(e,d.$root,"destroyed"))},50)}))}),!this.$isServer&&t.forEach(function(d){n.$on("hook:".concat(d),function(){Mn(e,this[a],d)})})}}}}function u$(s){return s=wd(s)?s:{},{keyName:s.keyName||ks.keyName,attribute:s.attribute||ks.attribute,ssrAttribute:s.ssrAttribute||ks.ssrAttribute,tagIDKeyName:s.tagIDKeyName||ks.tagIDKeyName,contentKeyName:s.contentKeyName||ks.contentKeyName,metaTemplateKeyName:s.metaTemplateKeyName||ks.metaTemplateKeyName,debounceWait:Rs(s.debounceWait)?ks.debounceWait:s.debounceWait,waitOnDestroyed:Rs(s.waitOnDestroyed)?ks.waitOnDestroyed:s.waitOnDestroyed,ssrAppId:s.ssrAppId||ks.ssrAppId,refreshOnceOnNavigation:!!s.refreshOnceOnNavigation}}function lee(s){var e={};for(var t in s)e[t]=s[t];return e}function $_(s,e){return!e||!wd(s)?Yc(s)?s:[]:(Yc(s[e])||(s[e]=[]),s)}var d$=[[/&/g,"&"],[/</g,"<"],[/>/g,">"],[/"/g,"""],[/'/g,"'"]],cee=[[/&/g,"&"],[/</g,"<"],[/>/g,">"],[/"/g,'"'],[/'/g,"'"]];function xp(s,e,t,r){var i=e.tagIDKeyName,n=t.doEscape,a=n===void 0?function(h){return h}:n,o={};for(var l in s){var u=s[l];if(us(Sg,l)){o[l]=u;continue}var c=Kc[0];if(t[c]&&us(t[c],l)){o[l]=u;continue}var d=s[i];if(d&&(c=Kc[1],t[c]&&t[c][d]&&us(t[c][d],l))){o[l]=u;continue}if(IQ(u)?o[l]=a(u):Yc(u)?o[l]=u.map(function(h){return y_(h)?xp(h,e,t,!0):a(h)}):y_(u)?o[l]=xp(u,e,t,!0):o[l]=u,r){var m=a(l);l!==m&&(o[m]=o[l],delete o[l])}}return o}function uee(s,e,t){t=t||[];var r={doEscape:function(n){return t.reduce(function(a,o){return a.replace(o[0],o[1])},n)}};return Kc.forEach(function(i,n){if(n===0)$_(e,i);else if(n===1)for(var a in e[i])$_(e[i],a);r[i]=e[i]}),xp(e,s,r)}function eu(s,e,t,r){var i=s.component,n=s.metaTemplateKeyName,a=s.contentKeyName;return t===!0||e[n]===!0?!1:(Rs(t)&&e[n]&&(t=e[n],e[n]=!0),t?(Rs(r)&&(r=e[a]),e[a]=Sd(t)?t.call(i,r):t.replace(/%s/g,r),!0):(delete e[n],!1))}function dee(s,e,t){var r=s.component,i=s.tagIDKeyName,n=s.metaTemplateKeyName,a=s.contentKeyName,o=[];return!e.length&&!t.length?o:(e.forEach(function(l,u){if(!l[i]){o.push(l);return}var c=l$(t,function(f){return f[i]===l[i]}),d=t[c];if(c===-1){o.push(l);return}if(a in d&&d[a]===void 0||"innerHTML"in d&&d.innerHTML===void 0){o.push(l),t.splice(c,1);return}if(d[a]===null||d.innerHTML===null){t.splice(c,1);return}var m=l[n];if(m){var h=d[n];if(!h){eu({component:r,metaTemplateKeyName:n,contentKeyName:a},d,m),d.template=!0;return}d[a]||eu({component:r,metaTemplateKeyName:n,contentKeyName:a},d,void 0,l[a])}}),o.concat(t))}var x_=!1;function mee(s,e,t){return t=t||{},e.title===void 0&&delete e.title,Pd.forEach(function(r){if(e[r])for(var i in e[r])i in e[r]&&e[r][i]===void 0&&(us(go,i)&&!x_&&(Jc("VueMeta: Please note that since v2 the value undefined is not used to indicate boolean attributes anymore, see migration guide for details"),x_=!0),delete e[r][i])}),LQ(s,e,{arrayMerge:function(i,n){return dee(t,i,n)}})}function m$(s,e){return h$(s||{},e,wg)}function h$(s,e,t){if(t=t||{},e._inactive)return t;s=s||{};var r=s,i=r.keyName,n=e.$metaInfo,a=e.$options,o=e.$children;if(a[i]){var l=n||a[i];wd(l)&&(t=mee(t,l,s))}return o.length&&o.forEach(function(u){aee(u)&&(t=h$(s,u,t))}),t}var p$=[];function hee(s){return document.readyState==="complete"}function pee(s,e){arguments.length===1&&(e=s,s=""),p$.push([s,e])}function fee(s,e,t,r){var i=s.tagIDKeyName,n=!1;return t.forEach(function(a){!a[i]||!a.callback||(n=!0,pee("".concat(e,"[data-").concat(i,'="').concat(a[i],'"]'),a.callback))}),n}function gee(){if(hee()){w_();return}document.onreadystatechange=function(){w_()}}function w_(s){p$.forEach(function(e){var t=e[0],r=e[1],i="".concat(t,'[onload="this.__vm_l=1"]'),n=[];n=Pg(Dg(i)),n.forEach(function(a){if(!a.__vm_cb){var o=function(){a.__vm_cb=!0,Qc(a,"onload"),r(a)};if(a.__vm_l){o();return}a.__vm_ev||(a.__vm_ev=!0,a.addEventListener("load",o))}})})}var om={};function f$(s,e,t,r,i){var n=e||{},a=n.attribute,o=i.getAttribute(a);o&&(om[t]=JSON.parse(decodeURI(o)),Qc(i,a));var l=om[t]||{},u=[];for(var c in l)l[c]!==void 0&&s in l[c]&&(u.push(c),r[c]||delete l[c][s]);for(var d in r){var m=l[d];(!m||m[s]!==r[d])&&(u.push(d),r[d]!==void 0&&(l[d]=l[d]||{},l[d][s]=r[d]))}for(var h=0,f=u;h<f.length;h++){var p=f[h],v=l[p],C=[];for(var P in v)Array.prototype.push.apply(C,[].concat(v[P]));if(C.length){var M=us(go,p)&&C.some(Boolean)?"":C.filter(function(F){return F!==void 0}).join(" ");i.setAttribute(p,M)}else Qc(i,p)}om[t]=l}function _ee(s){!s&&s!==""||(document.title=s)}function vee(s,e,t,r,i,n){var a=e||{},o=a.attribute,l=a.tagIDKeyName,u=o$.slice();u.push(l);var c=[],d={appId:s,attribute:o,type:t,tagIDKeyName:l},m={head:am(i,d),pbody:am(n,d,{pbody:!0}),body:am(n,d,{body:!0})};if(r.length>1){var h=[];r=r.filter(function(v){var C=JSON.stringify(v),P=!us(h,C);return h.push(C),P})}r.forEach(function(v){if(!v.skip){var C=document.createElement(t);v.once||C.setAttribute(o,s),Object.keys(v).forEach(function(O){if(!us(a$,O)){if(O==="innerHTML"){C.innerHTML=v.innerHTML;return}if(O==="json"){C.innerHTML=JSON.stringify(v.json);return}if(O==="cssText"){C.styleSheet?C.styleSheet.cssText=v.cssText:C.appendChild(document.createTextNode(v.cssText));return}if(O==="callback"){C.onload=function(){return v[O](C)};return}var $=us(u,O)?"data-".concat(O):O,D=us(go,O);if(!(D&&!v[O])){var V=D?"":v[O];C.setAttribute($,V)}}});var P=m[iee(v)],M,F=P.some(function(O,$){return M=$,C.isEqualNode(O)});F&&(M||M===0)?P.splice(M,1):c.push(C)}});var f=[];for(var p in m)Array.prototype.push.apply(f,m[p]);return f.forEach(function(v){v.parentNode.removeChild(v)}),c.forEach(function(v){if(v.hasAttribute("data-body")){n.appendChild(v);return}if(v.hasAttribute("data-pbody")){n.insertBefore(v,n.firstChild);return}i.appendChild(v)}),{oldTags:f,newTags:c}}function wp(s,e,t){e=e||{};var r=e,i=r.ssrAttribute,n=r.ssrAppId,a={},o=yi(a,"html");if(s===n&&o.hasAttribute(i)){Qc(o,i);var l=!1;return KQ.forEach(function(v){t[v]&&fee(e,v,t[v])&&(l=!0)}),l&&gee(),!1}var u={},c={};for(var d in t)if(!us(Sg,d)){if(d==="title"){_ee(t.title);continue}if(us(Pd,d)){var m=d.substr(0,4);f$(s,e,d,t[d],yi(a,m));continue}if(Yc(t[d])){var h=vee(s,e,d,t[d],yi(a,"head"),yi(a,"body")),f=h.oldTags,p=h.newTags;p.length&&(u[d]=p,c[d]=f)}}return{tagsAdded:u,tagsRemoved:c}}var ar;function bee(s,e,t){return{set:function(i){return yee(s,e,t,i)},remove:function(){return Cee(s,e,t)}}}function yee(s,e,t,r){if(s&&s.$el)return wp(e,t,r);ar=ar||{},ar[e]=r}function Cee(s,e,t){if(s&&s.$el){var r={},i=jQ(Pd),n;try{for(i.s();!(n=i.n()).done;){var a=n.value,o=a.substr(0,4);f$(e,t,a,{},yi(r,o))}}catch(l){i.e(l)}finally{i.f()}return nee(t,e)}ar[e]&&(delete ar[e],Og())}function g$(){return ar}function Og(s){(s||!Object.keys(ar).length)&&(ar=void 0)}function Mg(s,e,t,r){s=s||{},t=t||[];var i=s,n=i.tagIDKeyName;return e.title&&(e.titleChunk=e.title),e.titleTemplate&&e.titleTemplate!=="%s"&&eu({component:r,contentKeyName:"title"},e,e.titleTemplate,e.titleChunk||""),e.base&&(e.base=Object.keys(e.base).length?[e.base]:[]),e.meta&&(e.meta=e.meta.filter(function(a,o,l){var u=!!a[n];if(!u)return!0;var c=o===l$(l,function(d){return d[n]===a[n]});return c}),e.meta.forEach(function(a){return eu(s,a)})),uee(s,e,t)}function $ee(s,e){if(e=e||{},!s[Te])return n$(),{};var t=m$(e,s),r=Mg(e,t,cee,s),i=s[Te].appId,n=wp(i,e,r);n&&Sd(r.changed)&&(r.changed(r,n.tagsAdded,n.tagsRemoved),n={addedTags:n.tagsAdded,removedTags:n.tagsRemoved});var a=g$();if(a){for(var o in a)wp(o,e,a[o]),delete a[o];Og(!0)}return{vm:s,metaInfo:r,tags:n}}function xee(s,e,t,r){var i=r.addSsrAttribute,n=s||{},a=n.attribute,o=n.ssrAttribute,l="";for(var u in t){var c=t[u],d=[];for(var m in c)d.push.apply(d,r$([].concat(c[m])));d.length&&(l+=go.includes(u)&&d.some(Boolean)?"".concat(u):"".concat(u,'="').concat(d.join(" "),'"'),l+=" ")}return l&&(l+="".concat(a,'="').concat(encodeURI(JSON.stringify(t)),'"')),e==="htmlAttrs"&&i?"".concat(o).concat(l?" ":"").concat(l):l}function wee(s,e,t,r){var i=r||{},n=i.ln;return t?"<".concat(e,">").concat(t,"</").concat(e,">").concat(n?"\n":""):""}function S_(s,e,t,r){var i=s||{},n=i.ssrAppId,a=i.attribute,o=i.tagIDKeyName,l=r||{},u=l.appId,c=l.isSSR,d=c===void 0?!0:c,m=l.body,h=m===void 0?!1:m,f=l.pbody,p=f===void 0?!1:f,v=l.ln,C=v===void 0?!1:v,P=[o].concat(r$(o$));return!t||!t.length?"":t.reduce(function(M,F){if(F.skip)return M;var O=Object.keys(F);if(O.length===0||!!F.body!==h||!!F.pbody!==p)return M;var $=F.once?"":" ".concat(a,'="').concat(u||(d===!1?"1":n),'"');for(var D in F)if(!(tee.includes(D)||a$.includes(D))){if(D==="callback"){$+=' onload="this.__vm_l=1"';continue}var V="";P.includes(D)&&(V="data-");var N=!V&&go.includes(D);N&&!F[D]||($+=" ".concat(V).concat(D)+(N?"":'="'.concat(F[D],'"')))}var W="";F.json&&(W=JSON.stringify(F.json));var G=F.innerHTML||F.cssText||W,te=!QQ.includes(e),X=te&&eee.includes(e);return"".concat(M,"<").concat(e).concat($).concat(!X&&te?"/":"",">")+(X?"".concat(G,"</").concat(e,">"):"")+(C?"\n":"")},"")}function _$(s,e,t){var r={data:e,extraData:void 0,addInfo:function(l,u){this.extraData=this.extraData||{},this.extraData[l]=u},callInjectors:function(l){var u=this.injectors;return(l.body||l.pbody?"":u.title.text(l))+u.meta.text(l)+u.base.text(l)+u.link.text(l)+u.style.text(l)+u.script.text(l)+u.noscript.text(l)},injectors:{head:function(l){return r.callInjectors(as(as({},t),{},{ln:l}))},bodyPrepend:function(l){return r.callInjectors(as(as({},t),{},{ln:l,pbody:!0}))},bodyAppend:function(l){return r.callInjectors(as(as({},t),{},{ln:l,body:!0}))}}},i=function(l){if(Sg.includes(l))return"continue";r.injectors[l]={text:function(c){var d=c===!0;if(c=as(as({addSsrAttribute:d},t),c),l==="title")return wee(s,l,r.data[l],c);if(Pd.includes(l)){var m={},h=r.data[l];if(h){var f=c.isSSR===!1?"1":s.ssrAppId;for(var p in h)m[p]=bp({},f,h[p])}if(r.extraData)for(var v in r.extraData){var C=r.extraData[v][l];if(C)for(var P in C)m[P]=as(as({},m[P]),{},bp({},v,C[P]))}return xee(s,l,m,c)}var M=S_(s,l,r.data[l],c);if(r.extraData)for(var F in r.extraData){var O=r.extraData[F][l],$=S_(s,l,O,as({appId:F},c));M="".concat(M).concat($)}return M}}};for(var n in wg)var a=i(n);return r}function See(s,e,t){if(!s[Te])return n$(),{};var r=m$(e,s),i=Mg(e,r,d$,s),n=_$(e,i,t),a=g$();if(a){for(var o in a)n.addInfo(o,a[o]),delete a[o];Og(!0)}return n.injectors}function Pee(s){s=s||{};var e=this.$root;return{getOptions:function(){return lee(s)},setOptions:function(r){var i="refreshOnceOnNavigation";r&&r[i]&&(s.refreshOnceOnNavigation=!!r[i],$p(e));var n="debounceWait";if(r&&n in r){var a=parseInt(r[n]);isNaN(a)||(s.debounceWait=a)}var o="waitOnDestroyed";r&&o in r&&(s.waitOnDestroyed=!!r[o])},refresh:function(){return $ee(e,s)},inject:function(r){return See(e,s,r)},pause:function(){return c$(e)},resume:function(){return Tg(e)},addApp:function(r){return bee(e,r,s)}}}function Dee(s,e){e=u$(e);var t=Mg(e,s,d$),r=_$(e,t);return r.injectors}function Tee(s,e){s.__vuemeta_installed||(s.__vuemeta_installed=!0,e=u$(e),s.prototype.$meta=function(){return Pee.call(this,e)},s.mixin(oee(s,e)))}var Oee={version:AQ,install:Tee,generate:function(e,t){return Dee(e,t)},hasMetaInfo:Cp},v$={exports:{}};/*!
|
||
* vue-load-image v0.2.0
|
||
* (c) 2021 Sangwon Lee <lsw0150305@gmail.com>
|
||
* Released under the MIT License.
|
||
*/(function(s,e){(function(t,r){s.exports=r()})(window,function(){return function(t){var r={};function i(n){if(r[n])return r[n].exports;var a=r[n]={i:n,l:!1,exports:{}};return t[n].call(a.exports,a,a.exports,i),a.l=!0,a.exports}return i.m=t,i.c=r,i.d=function(n,a,o){i.o(n,a)||Object.defineProperty(n,a,{enumerable:!0,get:o})},i.r=function(n){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(n,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(n,"__esModule",{value:!0})},i.t=function(n,a){if(1&a&&(n=i(n)),8&a||4&a&&typeof n=="object"&&n&&n.__esModule)return n;var o=Object.create(null);if(i.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:n}),2&a&&typeof n!="string")for(var l in n)i.d(o,l,(function(u){return n[u]}).bind(null,l));return o},i.n=function(n){var a=n&&n.__esModule?function(){return n.default}:function(){return n};return i.d(a,"a",a),a},i.o=function(n,a){return Object.prototype.hasOwnProperty.call(n,a)},i.p="",i(i.s=0)}([function(t,r,i){i.r(r);var n="pending",a="loading",o="loaded",l="failed",u=function(d,m,h,f,p,v,C,P){var M,F=typeof d=="function"?d.options:d;return m&&(F.render=m,F.staticRenderFns=h,F._compiled=!0),{exports:d,options:F}}({data:function(){return{status:null,img:null,src:null}},created:function(){var d=this.$slots.image[0].data.attrs;if(this.src=d.src||d["data-src"],this.src)return this.status=a,this.crossOrigin=d.crossorigin,void this.createLoader();this.status=n},updated:function(){var d=this.$slots.image[0].data.attrs,m=d.src||d["data-src"];this.status!==a||this.img?this.src!==m&&(this.src=m,this.crossOrigin=d.crossorigin,this.createLoader()):this.createLoader()},watch:{src:function(d){this.status=d?a:n}},methods:{createLoader:function(){this.destroyLoader(),this.img=new Image,this.img.onload=this.handleLoad,this.img.onerror=this.handleError,this.img.crossOrigin=this.crossOrigin,this.img.src=this.src},destroyLoader:function(){this.img&&(this.img.onload=null,this.img.onerror=null,this.img=null)},handleLoad:function(){this.destroyLoader(),this.status=o,this.$emit("onLoad")},handleError:function(d){this.destroyLoader(),this.status=l,this.$emit("onError",d)}}},function(){var d=this.$createElement;return(this._self._c||d)("div",{staticClass:"vue-load-image"},[this.status==="loaded"?this._t("image"):this.status==="failed"?this._t("error"):this.status==="loading"?this._t("preloader"):this._e()],2)},[]);u.options.__file="VueLoadImage.vue";var c=u.exports;r.default=c}])})})(v$);var Mee=v$.exports;const kee=en(Mee);var b$={exports:{}};(function(s,e){(function(r,i){s.exports=i()})(Tr,()=>(()=>{var t={};t.d=(F,O)=>{for(var $ in O)t.o(O,$)&&!t.o(F,$)&&Object.defineProperty(F,$,{enumerable:!0,get:O[$]})},t.o=(F,O)=>Object.prototype.hasOwnProperty.call(F,O);var r={};t.d(r,{default:()=>M});var i=function(){var O=this,$=O._self._c;return $("transition",{attrs:{"enter-active-class":O.transition.enter,"leave-active-class":O.transition.leave}},[$("div",{directives:[{name:"show",rawName:"v-show",value:O.isActive,expression:"isActive"}],staticClass:"v-toast__item",class:["v-toast__item--".concat(O.type),"v-toast__item--".concat(O.position)],attrs:{role:"alert"},on:{mouseover:function(D){return O.toggleTimer(!0)},mouseleave:function(D){return O.toggleTimer(!1)},click:O.whenClicked}},[$("div",{staticClass:"v-toast__icon"}),O._v(" "),$("p",{staticClass:"v-toast__text",domProps:{innerHTML:O._s(O.message)}})])])},n=[];const a=F=>{typeof F.remove<"u"?F.remove():F.parentNode.removeChild(F)};class o{constructor(O,$){this.startedAt=Date.now(),this.callback=O,this.delay=$,this.timer=setTimeout(O,$)}pause(){this.stop(),this.delay-=Date.now()-this.startedAt}resume(){this.stop(),this.startedAt=Date.now(),this.timer=setTimeout(this.callback,this.delay)}stop(){clearTimeout(this.timer)}}const l=Object.freeze({TOP_RIGHT:"top-right",TOP:"top",TOP_LEFT:"top-left",BOTTOM_RIGHT:"bottom-right",BOTTOM:"bottom",BOTTOM_LEFT:"bottom-left"});function u(F){return{all:F=F||new Map,on:function(O,$){var D=F.get(O);D?D.push($):F.set(O,[$])},off:function(O,$){var D=F.get(O);D&&($?D.splice(D.indexOf($)>>>0,1):F.set(O,[]))},emit:function(O,$){var D=F.get(O);D&&D.slice().map(function(V){V($)}),(D=F.get("*"))&&D.slice().map(function(V){V(O,$)})}}}const c=u(),m={name:"toast",props:{message:{type:String,required:!0},type:{type:String,default:"success"},position:{type:String,default:l.BOTTOM_RIGHT,validator(F){return Object.values(l).includes(F)}},duration:{type:Number,default:3e3},dismissible:{type:Boolean,default:!0},onDismiss:{type:Function,default:()=>{}},onClick:{type:Function,default:()=>{}},queue:Boolean,pauseOnHover:{type:Boolean,default:!0}},data(){return{isActive:!1,parentTop:null,parentBottom:null,isHovered:!1}},beforeMount(){this.setupContainer()},mounted(){this.showNotice(),c.on("toast-clear",this.dismiss)},methods:{setupContainer(){if(this.parentTop=document.querySelector(".v-toast.v-toast--top"),this.parentBottom=document.querySelector(".v-toast.v-toast--bottom"),this.parentTop&&this.parentBottom)return;this.parentTop||(this.parentTop=document.createElement("div"),this.parentTop.className="v-toast v-toast--top"),this.parentBottom||(this.parentBottom=document.createElement("div"),this.parentBottom.className="v-toast v-toast--bottom");const F=document.body;F.appendChild(this.parentTop),F.appendChild(this.parentBottom)},shouldQueue(){return this.queue?this.parentTop.childElementCount>0||this.parentBottom.childElementCount>0:!1},dismiss(){this.timer&&this.timer.stop(),clearTimeout(this.queueTimer),this.isActive=!1,setTimeout(()=>{this.onDismiss.apply(null,arguments),this.$destroy(),a(this.$el)},150)},showNotice(){if(this.shouldQueue()){this.queueTimer=setTimeout(this.showNotice,250);return}this.correctParent.insertAdjacentElement("afterbegin",this.$el),this.isActive=!0,this.duration&&(this.timer=new o(this.dismiss,this.duration))},whenClicked(){this.dismissible&&(this.onClick.apply(null,arguments),this.dismiss())},toggleTimer(F){!this.pauseOnHover||!this.timer||(F?this.timer.pause():this.timer.resume())}},computed:{correctParent(){switch(this.position){case l.TOP:case l.TOP_RIGHT:case l.TOP_LEFT:return this.parentTop;case l.BOTTOM:case l.BOTTOM_RIGHT:case l.BOTTOM_LEFT:return this.parentBottom}},transition(){switch(this.position){case l.TOP:case l.TOP_RIGHT:case l.TOP_LEFT:return{enter:"v-toast--fade-in-down",leave:"v-toast--fade-out"};case l.BOTTOM:case l.BOTTOM_RIGHT:case l.BOTTOM_LEFT:return{enter:"v-toast--fade-in-up",leave:"v-toast--fade-out"}}}},beforeDestroy(){c.off("toast-clear",this.dismiss)}};function h(F,O,$,D,V,N,W,G){var te=typeof F=="function"?F.options:F;return O&&(te.render=O,te.staticRenderFns=$,te._compiled=!0),{exports:F,options:te}}var f=h(m,i,n);const p=f.exports,C=function(F){let O=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return{open($){let D;typeof $=="string"&&(D=$);const N=Object.assign({},{message:D},O,$);return new(F.extend(p))({el:document.createElement("div"),propsData:N})},clear(){c.emit("toast-clear")},success($){let D=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return this.open(Object.assign({},{message:$,type:"success"},D))},error($){let D=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return this.open(Object.assign({},{message:$,type:"error"},D))},info($){let D=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return this.open(Object.assign({},{message:$,type:"info"},D))},warning($){let D=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return this.open(Object.assign({},{message:$,type:"warning"},D))},default($){let D=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return this.open(Object.assign({},{message:$,type:"default"},D))}}},P=function(F){let O=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},$=C(F,O);F.$toast=$,F.prototype.$toast=$};p.install=P;const M=p;return r=r.default,r})())})(b$);var Eee=b$.exports;const Lee=en(Eee);class Aee extends y.extend({name:"overlay-scrollbars",props:{options:{type:Object},extensions:{type:[String,Array,Object]}},methods:{osInstance(){return this._osInstace},osTarget(){return this.$el||null}},watch:{options(e,t){let r=this._osInstace;jo.valid(r)&&r.options(e)}},data(){return{}},mounted(){this._osInstace=jo(this.osTarget(),this.options||{},this.extensions)},beforeDestroy(){const e=this._osInstace;jo.valid(e)&&(e.destroy(),this._osInstace=null)}}){constructor(){super(...arguments),this._osInstace=null}}function Fee(s,e,t,r,i,n,a,o,l,u){const c=typeof t=="function"?t.options:t;return s&&s.render&&(c.render=s.render,c.staticRenderFns=s.staticRenderFns,c._compiled=!0),t}const Ree=Aee;var y$=function(){var s=this,e=s.$createElement,t=s._self._c||e;return t("div",{staticClass:"os-host"},[t("div",{staticClass:"os-resize-observer-host"}),s._v(" "),t("div",{staticClass:"os-padding"},[t("div",{staticClass:"os-viewport"},[t("div",{staticClass:"os-content"},[s._t("default")],2)])]),s._v(" "),s._m(0),s._v(" "),s._m(1),s._v(" "),t("div",{staticClass:"os-scrollbar-corner"})])},Hee=[function(){var s=this,e=s.$createElement,t=s._self._c||e;return t("div",{staticClass:"os-scrollbar os-scrollbar-horizontal "},[t("div",{staticClass:"os-scrollbar-track"},[t("div",{staticClass:"os-scrollbar-handle"})])])},function(){var s=this,e=s.$createElement,t=s._self._c||e;return t("div",{staticClass:"os-scrollbar os-scrollbar-vertical"},[t("div",{staticClass:"os-scrollbar-track"},[t("div",{staticClass:"os-scrollbar-handle"})])])}];y$._withStripped=!0;const jee=void 0,Iee=Fee({render:y$,staticRenderFns:Hee},jee,Ree),Nee={install(s,e){e&&jo.defaultOptions(e),s.component("overlay-scrollbars",Iee)}};y.directive("longpress",{bind:function(s,e,t){var l,u;if(typeof e.value!="function"){const c=(l=t.context)==null?void 0:l.$options.name;let d="[longpress:] provided expression '".concat(e.expression,"' is not a function, but has to be");c&&(d+=" Found in component '".concat(c,"' ")),console.warn(d)}const r=Number((u=e.arg)!=null?u:1e3),i=c=>{e.value(c)};let n=null;const a=c=>{var d;if(c.type!=="click"&&!(!c.touches||c.touches.length<1))return(d=document.querySelector("body"))==null||d.setAttribute("style","user-select: none; -webkit-user-select: none; -moz-user-select: none;"),setTimeout(()=>{var m;(m=document.querySelector("body"))==null||m.setAttribute("style","")},r+200),n===null&&(n=window.setTimeout(()=>{c.preventDefault(),c.stopPropagation(),c.stopImmediatePropagation(),c.cancelBubble=!0,i({clientX:c.touches[0].clientX,clientY:c.touches[0].clientY,force:c.touches[0].force,identifier:c.touches[0].identifier,pageX:c.touches[0].pageX,pageY:c.touches[0].pageY,radiusX:c.touches[0].radiusX,radiusY:c.touches[0].radiusY,rotationAngle:c.touches[0].rotationAngle,screenX:c.touches[0].screenX,screenY:c.touches[0].screenY,preventDefault:()=>c.preventDefault()})},r)),!1},o=()=>{n!==null&&(clearTimeout(n),n=null)};s.addEventListener("touchstart",a),s.addEventListener("touchmove",o),s.addEventListener("touchend",o),s.addEventListener("touchcancel",o),document.addEventListener("scroll",o,{passive:!0})}});y.directive("responsive-class",{inserted(s,e){const t=Vv(i=>{const n=i[0].contentRect;for(const a in e.value)s.classList.toggle(a,e.value[a](n))},50);new ResizeObserver(t).observe(s)}});var Sp=y;y.util.warn;var lm=null;function Vee(s){return lm||(lm=(window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(e){return setTimeout(e,16)}).bind(window)),lm(s)}var cm=null;function Bee(s){cm||(cm=(window.cancelAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame||function(e){clearTimeout(e)}).bind(window)),cm(s)}function Uee(s){var e=document.createElement("style");return e.styleSheet?e.styleSheet.cssText=s:e.appendChild(document.createTextNode(s)),(document.querySelector("head")||document.body).appendChild(e),e}function Ro(s,e){e===void 0&&(e={});var t=document.createElement(s);return Object.keys(e).forEach(function(r){t[r]=e[r]}),t}function C$(s,e,t){var r=window.getComputedStyle(s,null)||{display:"none"};return r[e]}function Pp(s){if(!document.documentElement.contains(s))return{detached:!0,rendered:!1};for(var e=s;e!==document;){if(C$(e,"display")==="none")return{detached:!1,rendered:!1};e=e.parentNode}return{detached:!1,rendered:!0}}var Wee='.resize-triggers{visibility:hidden;opacity:0;pointer-events:none}.resize-contract-trigger,.resize-contract-trigger:before,.resize-expand-trigger,.resize-triggers{content:"";position:absolute;top:0;left:0;height:100%;width:100%;overflow:hidden}.resize-contract-trigger,.resize-expand-trigger{background:#eee;overflow:auto}.resize-contract-trigger:before{width:200%;height:200%}',Dp=0,tl=null;function zee(s,e){s.__resize_mutation_handler__||(s.__resize_mutation_handler__=qee.bind(s));var t=s.__resize_listeners__;if(!t){if(s.__resize_listeners__=[],window.ResizeObserver){var r=s.offsetWidth,i=s.offsetHeight,n=new ResizeObserver(function(){!s.__resize_observer_triggered__&&(s.__resize_observer_triggered__=!0,s.offsetWidth===r&&s.offsetHeight===i)||tu(s)}),a=Pp(s),o=a.detached,l=a.rendered;s.__resize_observer_triggered__=o===!1&&l===!1,s.__resize_observer__=n,n.observe(s)}else if(s.attachEvent&&s.addEventListener)s.__resize_legacy_resize_handler__=function(){tu(s)},s.attachEvent("onresize",s.__resize_legacy_resize_handler__),document.addEventListener("DOMSubtreeModified",s.__resize_mutation_handler__);else if(Dp||(tl=Uee(Wee)),Xee(s),s.__resize_rendered__=Pp(s).rendered,window.MutationObserver){var u=new MutationObserver(s.__resize_mutation_handler__);u.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0}),s.__resize_mutation_observer__=u}}s.__resize_listeners__.push(e),Dp++}function Gee(s,e){var t=s.__resize_listeners__;if(t){if(e&&t.splice(t.indexOf(e),1),!t.length||!e){if(s.detachEvent&&s.removeEventListener){s.detachEvent("onresize",s.__resize_legacy_resize_handler__),document.removeEventListener("DOMSubtreeModified",s.__resize_mutation_handler__);return}s.__resize_observer__?(s.__resize_observer__.unobserve(s),s.__resize_observer__.disconnect(),s.__resize_observer__=null):(s.__resize_mutation_observer__&&(s.__resize_mutation_observer__.disconnect(),s.__resize_mutation_observer__=null),s.removeEventListener("scroll",kg),s.removeChild(s.__resize_triggers__.triggers),s.__resize_triggers__=null),s.__resize_listeners__=null}!--Dp&&tl&&tl.parentNode.removeChild(tl)}}function Zee(s){var e=s.__resize_last__,t=e.width,r=e.height,i=s.offsetWidth,n=s.offsetHeight;return i!==t||n!==r?{width:i,height:n}:null}function qee(){var s=Pp(this),e=s.rendered,t=s.detached;e!==this.__resize_rendered__&&(!t&&this.__resize_triggers__&&(Eg(this),this.addEventListener("scroll",kg,!0)),this.__resize_rendered__=e,tu(this))}function kg(){var s=this;Eg(this),this.__resize_raf__&&Bee(this.__resize_raf__),this.__resize_raf__=Vee(function(){var e=Zee(s);e&&(s.__resize_last__=e,tu(s))})}function tu(s){!s||!s.__resize_listeners__||s.__resize_listeners__.forEach(function(e){e.call(s,s)})}function Xee(s){var e=C$(s,"position");(!e||e==="static")&&(s.style.position="relative"),s.__resize_old_position__=e,s.__resize_last__={};var t=Ro("div",{className:"resize-triggers"}),r=Ro("div",{className:"resize-expand-trigger"}),i=Ro("div"),n=Ro("div",{className:"resize-contract-trigger"});r.appendChild(i),t.appendChild(r),t.appendChild(n),s.appendChild(t),s.__resize_triggers__={triggers:t,expand:r,expandChild:i,contract:n},Eg(s),s.addEventListener("scroll",kg,!0),s.__resize_last__={width:s.offsetWidth,height:s.offsetHeight}}function Eg(s){var e=s.__resize_triggers__,t=e.expand,r=e.expandChild,i=e.contract,n=i.scrollWidth,a=i.scrollHeight,o=t.offsetWidth,l=t.offsetHeight,u=t.scrollWidth,c=t.scrollHeight;i.scrollLeft=n,i.scrollTop=a,r.style.width=o+1+"px",r.style.height=l+1+"px",t.scrollLeft=u,t.scrollTop=c}var Es=function(){return Es=Object.assign||function(s){for(var e,t=1,r=arguments.length;t<r;t++)for(var i in e=arguments[t])Object.prototype.hasOwnProperty.call(e,i)&&(s[i]=e[i]);return s},Es.apply(this,arguments)};var Yee=["getWidth","getHeight","getDom","getOption","resize","dispatchAction","convertToPixel","convertFromPixel","containPixel","getDataURL","getConnectedDataURL","appendData","clear","isDisposed","dispose"];function Jee(s){return e=Object.create(null),Yee.forEach(function(t){e[t]=function(r){return function(){for(var i=[],n=0;n<arguments.length;n++)i[n]=arguments[n];if(!s.value)throw new Error("ECharts is not initialized yet.");return s.value[r].apply(s.value,i)}}(t)}),e;var e}var Kee={autoresize:[Boolean,Object]},Qee=/^on[^a-z]/,ete=function(s){return Qee.test(s)};function Ho(s,e){var t=q$(s);return t&&typeof t=="object"&&"value"in t?t.value||e:t||e}var tte="ecLoadingOptions",ste={loading:Boolean,loadingOptions:Object},kn=null,Lg="x-vue-echarts",P_=[],En=[];(function(s,e){if(s&&typeof document<"u"){var t,r=e.prepend===!0?"prepend":"append",i=e.singleTag===!0,n=typeof e.container=="string"?document.querySelector(e.container):document.getElementsByTagName("head")[0];if(i){var a=P_.indexOf(n);a===-1&&(a=P_.push(n)-1,En[a]={}),t=En[a]&&En[a][r]?En[a][r]:En[a][r]=o()}else t=o();s.charCodeAt(0)===65279&&(s=s.substring(1)),t.styleSheet?t.styleSheet.cssText+=s:t.appendChild(document.createTextNode(s))}function o(){var l=document.createElement("style");if(l.setAttribute("type","text/css"),e.attributes)for(var u=Object.keys(e.attributes),c=0;c<u.length;c++)l.setAttribute(u[c],e.attributes[u[c]]);var d=r==="prepend"?"afterbegin":"beforeend";return n.insertAdjacentElement(d,l),l}})("x-vue-echarts{display:block;width:100%;height:100%;min-width:0}x-vue-echarts>div{width:100%;height:100%}\n",{});var rte=function(){if(kn!=null)return kn;if(typeof HTMLElement>"u"||typeof customElements>"u")return kn=!1;try{new Function("tag","class EChartsElement extends HTMLElement {\n __dispose = null;\n\n disconnectedCallback() {\n if (this.__dispose) {\n this.__dispose();\n this.__dispose = null;\n }\n }\n}\n\nif (customElements.get(tag) == null) {\n customElements.define(tag, EChartsElement);\n}\n")(Lg)}catch{return kn=!1}return kn=!0}();Sp&&Sp.config.ignoredElements.push(Lg);var ite="ecTheme",nte="ecInitOptions",ate="ecUpdateOptions",ote=B$({name:"echarts",props:Es(Es({option:Object,theme:{type:[Object,String]},initOptions:Object,updateOptions:Object,group:String,manualUpdate:Boolean},Kee),ste),emits:{},inheritAttrs:!1,setup:function(s,e){var t=e.attrs,r=_o(),i=_o(),n=_o(),a=_o(),o=vo(ite,null),l=vo(nte,null),u=vo(ate,null),c=U$(s),d=c.autoresize,m=c.manualUpdate,h=c.loading,f=c.loadingOptions,p=wr(function(){return a.value||s.option||null}),v=wr(function(){return s.theme||Ho(o,{})}),C=wr(function(){return s.initOptions||Ho(l,{})}),P=wr(function(){return s.updateOptions||Ho(u,{})}),M=wr(function(){return function(N){var W={};for(var G in N)ete(G)||(W[G]=N[G]);return W}(t)}),F=W$().proxy.$listeners;function O(N){if(i.value){var W=n.value=X$(i.value,v.value,C.value);s.group&&(W.group=s.group);var G=F;G||(G={},Object.keys(t).filter(function(X){return X.indexOf("on")===0&&X.length>2}).forEach(function(X){var q=X.charAt(2).toLowerCase()+X.slice(3);q.substring(q.length-4)==="Once"&&(q="~".concat(q.substring(0,q.length-4))),G[q]=t[X]})),Object.keys(G).forEach(function(X){var q=G[X];if(q){var z=X.toLowerCase();z.charAt(0)==="~"&&(z=z.substring(1),q.__once__=!0);var K=W;if(z.indexOf("zr:")===0&&(K=W.getZr(),z=z.substring(3)),q.__once__){delete q.__once__;var Q=q;q=function(){for(var re=[],R=0;R<arguments.length;R++)re[R]=arguments[R];Q.apply(void 0,re),K.off(z,q)}}K.on(z,q)}}),d.value?Z$(function(){W&&!W.isDisposed()&&W.resize(),te()}):te()}function te(){var X=N||p.value;X&&W.setOption(X,P.value)}}function $(){n.value&&(n.value.dispose(),n.value=void 0)}var D=null;bo(m,function(N){typeof D=="function"&&(D(),D=null),N||(D=bo(function(){return s.option},function(W,G){W&&(n.value?n.value.setOption(W,Es({notMerge:W!==G},P.value)):O())},{deep:!0}))},{immediate:!0}),bo([v,C],function(){$(),O()},{deep:!0}),Fg(function(){s.group&&n.value&&(n.value.group=s.group)});var V=Jee(n);return function(N,W,G){var te=vo(tte,{}),X=wr(function(){return Es(Es({},Ho(te,{})),G==null?void 0:G.value)});Fg(function(){var q=N.value;q&&(W.value?q.showLoading(X.value):q.hideLoading())})}(n,h,f),function(N,W,G){var te=null;bo([G,N,W],function(X,q,z){var K=X[0],Q=X[1],re=X[2];if(K&&Q&&re){var R=re===!0?{}:re,B=R.throttle,T=B===void 0?100:B,A=R.onResize,H=function(){Q.resize(),A==null||A()};te=T?Y$(H,T):H,zee(K,te)}z(function(){K&&te&&Gee(K,te)})})}(n,d,i),z$(function(){O()}),G$(function(){rte&&r.value?r.value.__dispose=$:$()}),Es({chart:n,root:r,inner:i,setOption:function(N,W){s.manualUpdate&&(a.value=N),n.value?n.value.setOption(N,W||{}):O(N)},nonEventAttrs:M},V)},render:function(){var s=Sp?{attrs:this.nonEventAttrs}:Es({},this.nonEventAttrs);return s.ref="root",s.class=s.class?["echarts"].concat(s.class):"echarts",Ag(Lg,s,[Ag("div",{ref:"inner"})])}});function lte(){var s=window.navigator.userAgent,e=s.indexOf("MSIE ");if(e>0)return parseInt(s.substring(e+5,s.indexOf(".",e)),10);var t=s.indexOf("Trident/");if(t>0){var r=s.indexOf("rv:");return parseInt(s.substring(r+3,s.indexOf(".",r)),10)}var i=s.indexOf("Edge/");return i>0?parseInt(s.substring(i+5,s.indexOf(".",i)),10):-1}var sl;function Tp(){Tp.init||(Tp.init=!0,sl=lte()!==-1)}var cte={name:"ResizeObserver",props:{emitOnMount:{type:Boolean,default:!1},ignoreWidth:{type:Boolean,default:!1},ignoreHeight:{type:Boolean,default:!1}},mounted:function(){var e=this;Tp(),this.$nextTick(function(){e._w=e.$el.offsetWidth,e._h=e.$el.offsetHeight,e.emitOnMount&&e.emitSize()});var t=document.createElement("object");this._resizeObject=t,t.setAttribute("aria-hidden","true"),t.setAttribute("tabindex",-1),t.onload=this.addResizeHandlers,t.type="text/html",sl&&this.$el.appendChild(t),t.data="about:blank",sl||this.$el.appendChild(t)},beforeDestroy:function(){this.removeResizeHandlers()},methods:{compareAndNotify:function(){(!this.ignoreWidth&&this._w!==this.$el.offsetWidth||!this.ignoreHeight&&this._h!==this.$el.offsetHeight)&&(this._w=this.$el.offsetWidth,this._h=this.$el.offsetHeight,this.emitSize())},emitSize:function(){this.$emit("notify",{width:this._w,height:this._h})},addResizeHandlers:function(){this._resizeObject.contentDocument.defaultView.addEventListener("resize",this.compareAndNotify),this.compareAndNotify()},removeResizeHandlers:function(){this._resizeObject&&this._resizeObject.onload&&(!sl&&this._resizeObject.contentDocument&&this._resizeObject.contentDocument.defaultView.removeEventListener("resize",this.compareAndNotify),this.$el.removeChild(this._resizeObject),this._resizeObject.onload=null,this._resizeObject=null)}}};function ute(s,e,t,r,i,n,a,o,l,u){var c=typeof t=="function"?t.options:t;return s&&s.render&&(c.render=s.render,c.staticRenderFns=s.staticRenderFns,c._compiled=!0),c._scopeId=r,t}var dte=cte,$$=function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"resize-observer",attrs:{tabindex:"-1"}})},mte=[];$$._withStripped=!0;var hte=void 0,pte="data-v-8859cc6c",D_=ute({render:$$,staticRenderFns:mte},hte,dte,pte);function fte(s){s.component("resize-observer",D_),s.component("ResizeObserver",D_)}var x$={version:"1.0.1",install:fte},su=null;typeof window<"u"?su=window.Vue:typeof global<"u"&&(su=global.Vue);su&&su.use(x$);y.config.productionTip=!1;y.directive("observe-visibility",t$);y.use(Oee);y.component("VueLoadImage",kee);y.use(Lee,{duration:3e3});const gte=navigator.userAgent.includes("Safari")&&navigator.userAgent.search("Chrome")===-1,_te="ontouchstart"in window||navigator.maxTouchPoints>0&&navigator.maxTouchPoints!==256;y.use(Nee,{className:"os-theme-light",scrollbars:{visibility:"auto",autoHide:gte&&_te?"scroll":"move"}});J$([K$,Q$,ex,tx,sx,rx,ix,nx]);y.component("EChart",ote);y.use(x$);const vte=async()=>{var e,t,r;try{const a=await(await fetch("".concat("/","config.json"))).json();window.console.debug("Loaded config.json"),await Pr.dispatch("importConfigJson",a);const o=(e=a.defaultLocale)!=null?e:"en";await xy(o);const l=(t=a.defaultMode)!=null?t:j_;pC.framework.theme.dark=l!=="light"}catch(i){window.console.error("Failed to load config.json"),window.console.error(i)}const s=Pr.getters["socket/getWebsocketUrl"];y.use(aQ,{url:s,store:Pr}),((r=Pr==null?void 0:Pr.state)==null?void 0:r.instancesDB)==="moonraker"&&y.$socket.connect()};vte().then(()=>new y({vuetify:pC,router:Ia,store:Pr,i18n:ve,render:s=>s(NX)}).$mount("#app"));export{cl as A,L as B,S as C,Xe as D,Le as E,Ie as F,Ke as G,ur as H,h_ as I,lr as J,w as P,Ts as R,vt as T,he as W,U as _,pe as a,hu as b,Ue as c,bt as d,ll as e,Ste as f,Ht as g,Je as h,av as i,fu as j,jx as k,ou as l,k as m,E as n,fe as o,wte as p,$te as q,Yp as r,Ov as s,Ba as t,ss as u,yu as v,nn as w,Zp as x,xte as y,G_ as z};
|