filecat 3.5.0 → 3.7.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,2 +1,2 @@
1
1
  /*! For license information please see 654.bundle.js.LICENSE.txt */
2
- (self.webpackChunkfilecat=self.webpackChunkfilecat||[]).push([[654],{542:()=>{},3146:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>P});var n,o=r(6540),a=r(2389),i=r(7444),c=r(6417),u=r(4944),s=r(4238),l=r(6007),A=r(3459),f=r(3033),h=r(5997),p=r(3029),d=r(7952),y=(r(2341),r(9879)),v=r(8257),m=r.n(v),g=r(8965),w=r(2042),Y=r(4777),x=r(8247),b=r(3430);function S(t){return S="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},S(t)}function j(){j=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",u=a.toStringTag||"@@toStringTag";function s(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,r){return t[e]=r}}function l(t,e,r,n){var a=e&&e.prototype instanceof v?e:v,i=Object.create(a.prototype),c=new G(n||[]);return o(i,"_invoke",{value:B(t,r,c)}),i}function A(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=l;var f="suspendedStart",h="suspendedYield",p="executing",d="completed",y={};function v(){}function m(){}function g(){}var w={};s(w,i,(function(){return this}));var Y=Object.getPrototypeOf,x=Y&&Y(Y(z([])));x&&x!==r&&n.call(x,i)&&(w=x);var b=g.prototype=v.prototype=Object.create(w);function L(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function E(t,e){function r(o,a,i,c){var u=A(t[o],t,a);if("throw"!==u.type){var s=u.arg,l=s.value;return l&&"object"==S(l)&&n.call(l,"__await")?e.resolve(l.__await).then((function(t){r("next",t,i,c)}),(function(t){r("throw",t,i,c)})):e.resolve(l).then((function(t){s.value=t,i(s)}),(function(t){return r("throw",t,i,c)}))}c(u.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return a=a?a.then(o,o):o()}})}function B(e,r,n){var o=f;return function(a,i){if(o===p)throw Error("Generator is already running");if(o===d){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var u=k(c,n);if(u){if(u===y)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===f)throw o=d,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=p;var s=A(e,r,n);if("normal"===s.type){if(o=n.done?d:h,s.arg===y)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(o=d,n.method="throw",n.arg=s.arg)}}}function k(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,k(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),y;var a=A(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,y;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,y):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y)}function P(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function N(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function G(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(P,this),this.reset(!0)}function z(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(S(e)+" is not iterable")}return m.prototype=g,o(b,"constructor",{value:g,configurable:!0}),o(g,"constructor",{value:m,configurable:!0}),m.displayName=s(g,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===m||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,s(t,u,"GeneratorFunction")),t.prototype=Object.create(b),t},e.awrap=function(t){return{__await:t}},L(E.prototype),s(E.prototype,c,(function(){return this})),e.AsyncIterator=E,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new E(l(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},L(b),s(b,u,"Generator"),s(b,i,(function(){return this})),s(b,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=z,G.prototype={constructor:G,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(N),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var u=n.call(i,"catchLoc"),s=n.call(i,"finallyLoc");if(u&&s){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,y):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),y},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),N(r),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:z(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),y}},e}function L(t,e,r,n,o,a,i){try{var c=t[a](i),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function E(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var a=t.apply(e,r);function i(t){L(a,n,o,i,c,"next",t)}function c(t){L(a,n,o,i,c,"throw",t)}i(void 0)}))}}function B(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],u=!0,s=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){s=!0,o=t}finally{try{if(!u&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(s)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return k(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?k(t,e):void 0}}(t,e)||function(){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 k(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function P(){var t=(0,a.Bd)().t,e=B((0,o.useState)(void 0),2),r=e[0],v=e[1],S=B((0,o.useState)(!1),2),L=S[0],k=S[1],P=B((0,i.L4)(c.A.user_base_info),2),N=P[0],G=(P[1],(0,x.MH)().check_user_auth),z=(0,o.useRef)(null),F=(0,o.useRef)(null),H=function(){var e=E(j().mark((function e(r){var o;return j().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(N.sysSoftWare&&N.sysSoftWare[Y.jk.ffmpeg]&&N.sysSoftWare[Y.jk.ffmpeg].installed){e.next=3;break}return(0,w.zN)(t("找不到ffmpeg")),e.abrupt("return");case 3:return o={controls:!0,width:640,height:360},F.current=(0,y.default)(z.current,o),m().isSupported()?((n=m().createPlayer({type:"flv",url:g.I.getOtherWebSocketUrl(s.HK.rtsp_get,{url:r}),isLive:!0})).attachMediaElement(z.current),n.load(),n.load()):(0,w.zN)("FLV.js is not supported in this browser."),e.abrupt("return",(function(){}));case 7:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}();(0,o.useEffect)((function(){return function(){n&&(n.pause(),n.unload(),n.detachMediaElement(),n.destroy(),n=null),F.current&&F.current.dispose()}}),[]);var M=function(t){k(!0),H(t.address?t.address:r)},O=function(){var t=E(j().mark((function t(){return j().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,u.ws.sendData(s.HK.rdp_disconnect,"");case 2:k(!1);case 3:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),K=function(){var t=E(j().mark((function t(){var e;return j().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,l.K4.get("tag");case 2:if((e=t.sent).code!==A.m.Sucess){t.next=5;break}return t.abrupt("return",e.data);case 5:return t.abrupt("return",[]);case 6:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),I=function(){var t=E(j().mark((function t(e){return j().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,l.K4.post("tag/save",e);case 2:t.sent.code!==A.m.Sucess&&(0,w.zN)("网络错误");case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),D=function(){var t=E(j().mark((function t(e){return j().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:v(e.address),M(e);case 2:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();return o.createElement("div",null,o.createElement(d.A,null,o.createElement(f.$Z,{max_width:"40rem",placeholder:t(" rtsp://username:password@ip:port/path"),icon:"link",value:r,handleInputChange:function(t){return v(t)}}),!L&&o.createElement(h.rA,{icon:"play_arrow",title:t("连接"),onClick:M}),L&&o.createElement(h.rA,{icon:"close",title:t("关闭"),onClick:O})),!L&&o.createElement(p.N,{have_auth_edit:G(b.oV.rtsp_proxy_tag_update),getItems:K,save:I,clickItem:D,items:[{key:"name",preName:t("名字")},{key:"address",preName:t("地址")}]}),o.createElement("canvas",{id:"rdpwebview",style:{display:"none"}}),o.createElement("div",{style:{display:L?"block":"none"}},o.createElement("video",{ref:z,className:"video-js vjs-default-skin"})))}},7422:t=>{"use strict";t.exports="data:application/font-woff;charset=utf-8;base64,d09GRgABAAAAABTsAAsAAAAAIpAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABHU1VCAAABCAAAADsAAABUIIslek9TLzIAAAFEAAAAPgAAAFZRiV32Y21hcAAAAYQAAAEJAAAD5p42+VxnbHlmAAACkAAADtIAABckI4l972hlYWQAABFkAAAAKwAAADYsvIjpaGhlYQAAEZAAAAAdAAAAJA+RCL1obXR4AAARsAAAABcAAAC8Q2YAAGxvY2EAABHIAAAAYAAAAGB7CIGGbWF4cAAAEigAAAAfAAAAIAFAAI9uYW1lAAASSAAAASUAAAIK1cf1oHBvc3QAABNwAAABfAAAAnXdFqh1eJxjYGRgYOBiMGCwY2BycfMJYeDLSSzJY5BiYGGAAJA8MpsxJzM9kYEDxgPKsYBpDiBmg4gCACY7BUgAeJxjYGR7yDiBgZWBgaWQ5RkDA8MvCM0cwxDOeI6BgYmBlZkBKwhIc01hcPjI+FGPHcRdyA4RZgQRADaGCyYAAHic7dPXbcMwAEXRK1vuvffem749XAbKV3bjBA6fXsaIgMMLEWoQJaAEFKNnlELyQ4K27zib5PNF6vl8yld+TKr5kH0+cUw0xv00Hwvx2DResUyFKrV4XoMmLdp06NKjz4AhI8ZMmDJjzoIlK9Zs2LJjz4EjJ85cuHLjziPe/0UWL17mf2tqKLz/9jK9f8tXpGCoRdPKhtS0RqFkWvVQNtSKoVYNtWaoddPXEBqG2jQ9XWgZattQO4baNdSeofYNdWCoQ0MdGerYUCeGOjXUmaHODXVhqEtDXRnq2lA3hro11J2h7g31YKhHQz0Z6tlQL4Z6NdSbod4N9WGoT9MfHF6GmhnZLxyDcRMAAAB4nJ1YC1hU17U+a5/HMA4iA3NmVBDmoQwP5TFnHlFeA4gYiUFRQINoSCBAyK3G2yi+0aipYtFcHYo2xsb4NiY3+VrNxSaX5uvt495ozNdoYoxmem2/L8HGpLc+InB279pnhlGr5mvL4eyz99nrrL32eu1/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YWa+zMxa13oKrA6Uoerqi/JwtpYxZXJ1coUVmeZUWVlTjq0/tHacjmdxuL90OR8O0UEDYMNdtiSEpz5XQGqzlm30kzUdAYFFOb8R7NOZk0q2lwAyz1i7oAr1xoXvrOgtYhZx8wY5KRV269JZ5yGpmzPTjQhvY9je6vEElPOuJP3mWKnP5M3V+YAAAB4nG2ReVPbMBDF/ULi2EkDBFqO3gdHLxUzDB9IkdexBllydRD49ihO3Ckz7B/a31utZnafkkGyiXnyclxhgB0MMUKKMTLkmGCKV5hhF3vYxxwHOMRrvMERjnGCU7zFO7zHB3zEJ3zGF3zFN5zhHBe4xHf8wE/8wm8w/MEVimTYKv44XR9MSCsUjVoeHE3vjQoNsSZ4mmxZmVWPjSz7jlou6/0qKOWEJdKMtCe793/hQfqxa6XWZHMXFl56RS4TvPXSaDeoy0zUUZB109KstDK8lHo5q6Qi1hcOnqkImubPS6aqRq7mlnaEWabub4iYblba3SRmgldS0+FWdhNtt04F14JUaqkl7tcpOpJtErvNt3Bd9HRT5JWxK25Ldjvp6br4hzfFiIdSmlzTg2fSUzNrLd1LE1ynxq4OVaVoKLjzJ60UPtj1RKzHzsbjly6inVnFBS2MucviPncU7Rr7lfTxRepDs1A2j3ZHRc7PuzFYSfE3ZOd4kjwBy227hA=="}}]);
2
+ (self.webpackChunkfilecat=self.webpackChunkfilecat||[]).push([[654],{542:()=>{},3146:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>N});var n,o=r(6540),a=r(2389),i=r(7444),c=r(6417),u=r(4944),s=r(4238),l=r(6007),A=r(3459),f=r(3033),h=r(5997),p=r(3029),d=r(7952),y=(r(2341),r(9879)),v=r(8257),m=r.n(v),g=r(8965),w=r(2042),Y=r(4777),x=r(8247),b=r(3430);function S(t){return S="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},S(t)}function j(){j=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",u=a.toStringTag||"@@toStringTag";function s(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,r){return t[e]=r}}function l(t,e,r,n){var a=e&&e.prototype instanceof v?e:v,i=Object.create(a.prototype),c=new G(n||[]);return o(i,"_invoke",{value:B(t,r,c)}),i}function A(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=l;var f="suspendedStart",h="suspendedYield",p="executing",d="completed",y={};function v(){}function m(){}function g(){}var w={};s(w,i,(function(){return this}));var Y=Object.getPrototypeOf,x=Y&&Y(Y(z([])));x&&x!==r&&n.call(x,i)&&(w=x);var b=g.prototype=v.prototype=Object.create(w);function L(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function E(t,e){function r(o,a,i,c){var u=A(t[o],t,a);if("throw"!==u.type){var s=u.arg,l=s.value;return l&&"object"==S(l)&&n.call(l,"__await")?e.resolve(l.__await).then((function(t){r("next",t,i,c)}),(function(t){r("throw",t,i,c)})):e.resolve(l).then((function(t){s.value=t,i(s)}),(function(t){return r("throw",t,i,c)}))}c(u.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return a=a?a.then(o,o):o()}})}function B(e,r,n){var o=f;return function(a,i){if(o===p)throw Error("Generator is already running");if(o===d){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var u=k(c,n);if(u){if(u===y)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===f)throw o=d,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=p;var s=A(e,r,n);if("normal"===s.type){if(o=n.done?d:h,s.arg===y)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(o=d,n.method="throw",n.arg=s.arg)}}}function k(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,k(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),y;var a=A(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,y;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,y):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y)}function N(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function P(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function G(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(N,this),this.reset(!0)}function z(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(S(e)+" is not iterable")}return m.prototype=g,o(b,"constructor",{value:g,configurable:!0}),o(g,"constructor",{value:m,configurable:!0}),m.displayName=s(g,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===m||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,s(t,u,"GeneratorFunction")),t.prototype=Object.create(b),t},e.awrap=function(t){return{__await:t}},L(E.prototype),s(E.prototype,c,(function(){return this})),e.AsyncIterator=E,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new E(l(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then((function(t){return t.done?t.value:i.next()}))},L(b),s(b,u,"Generator"),s(b,i,(function(){return this})),s(b,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=z,G.prototype={constructor:G,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(P),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var u=n.call(i,"catchLoc"),s=n.call(i,"finallyLoc");if(u&&s){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,y):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),y},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),P(r),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;P(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:z(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),y}},e}function L(t,e,r,n,o,a,i){try{var c=t[a](i),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function E(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var a=t.apply(e,r);function i(t){L(a,n,o,i,c,"next",t)}function c(t){L(a,n,o,i,c,"throw",t)}i(void 0)}))}}function B(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a,i,c=[],u=!0,s=!1;try{if(a=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=a.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){s=!0,o=t}finally{try{if(!u&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(s)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return k(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?k(t,e):void 0}}(t,e)||function(){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 k(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function N(){var t=(0,a.Bd)().t,e=B((0,o.useState)(void 0),2),r=e[0],v=e[1],S=B((0,o.useState)(!1),2),L=S[0],k=S[1],N=B((0,i.L4)(c.A.user_base_info),2),P=N[0],G=(N[1],(0,x.MH)().check_user_auth),z=(0,o.useRef)(null),F=(0,o.useRef)(null),H=function(){var e=E(j().mark((function e(r){var o;return j().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(P.sysSoftWare&&P.sysSoftWare[Y.jk.ffmpeg]&&P.sysSoftWare[Y.jk.ffmpeg].installed){e.next=3;break}return(0,w.zN)(t("找不到ffmpeg")),e.abrupt("return");case 3:return o={controls:!0,width:640,height:360},F.current=(0,y.default)(z.current,o),m().isSupported()?((n=m().createPlayer({type:"flv",url:g.I.getOtherWebSocketUrl(s.HK.rtsp_get,{url:r}),isLive:!0})).attachMediaElement(z.current),n.load(),n.load()):(0,w.zN)("FLV.js is not supported in this browser."),e.abrupt("return",(function(){}));case 7:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}();(0,o.useEffect)((function(){return function(){n&&(n.pause(),n.unload(),n.detachMediaElement(),n.destroy(),n=null),F.current&&F.current.dispose()}}),[]);var M=function(t){k(!0),H(t.address?t.address:r)},O=function(){var t=E(j().mark((function t(){return j().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,u.ws.sendData(s.HK.rdp_disconnect,"");case 2:k(!1);case 3:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),K=function(){var t=E(j().mark((function t(){var e;return j().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,l.K4.get("tag");case 2:if((e=t.sent).code!==A.m.Sucess){t.next=5;break}return t.abrupt("return",e.data);case 5:return t.abrupt("return",[]);case 6:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),I=function(){var t=E(j().mark((function t(e){return j().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,l.K4.post("tag/save",e);case 2:t.sent.code!==A.m.Sucess&&(0,w.zN)("网络错误");case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),D=function(){var t=E(j().mark((function t(e){return j().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:v(e.address),M(e);case 2:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();return o.createElement("div",null,o.createElement(d.A,null,o.createElement(f.$Z,{max_width:"40rem",placeholder:t(" rtsp://username:password@ip:port/path"),icon:"link",value:r,handleInputChange:function(t){return v(t)}}),!L&&o.createElement(h.rA,{icon:"play_arrow",title:t("连接"),onClick:M}),L&&o.createElement(h.rA,{icon:"close",title:t("关闭"),onClick:O})),!L&&o.createElement(p.N,{have_auth_edit:G(b.oV.rtsp_proxy_tag_update),getItems:K,save:I,clickItem:D,items:[{key:"name",preName:t("名字")},{key:"address",preName:t("地址")},{key:"color",preName:"color"}]}),o.createElement("canvas",{id:"rdpwebview",style:{display:"none"}}),o.createElement("div",{style:{display:L?"block":"none"}},o.createElement("video",{ref:z,className:"video-js vjs-default-skin"})))}},7422:t=>{"use strict";t.exports="data:application/font-woff;charset=utf-8;base64,d09GRgABAAAAABTsAAsAAAAAIpAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAABHU1VCAAABCAAAADsAAABUIIslek9TLzIAAAFEAAAAPgAAAFZRiV32Y21hcAAAAYQAAAEJAAAD5p42+VxnbHlmAAACkAAADtIAABckI4l972hlYWQAABFkAAAAKwAAADYsvIjpaGhlYQAAEZAAAAAdAAAAJA+RCL1obXR4AAARsAAAABcAAAC8Q2YAAGxvY2EAABHIAAAAYAAAAGB7CIGGbWF4cAAAEigAAAAfAAAAIAFAAI9uYW1lAAASSAAAASUAAAIK1cf1oHBvc3QAABNwAAABfAAAAnXdFqh1eJxjYGRgYOBiMGCwY2BycfMJYeDLSSzJY5BiYGGAAJA8MpsxJzM9kYEDxgPKsYBpDiBmg4gCACY7BUgAeJxjYGR7yDiBgZWBgaWQ5Rk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SRmgldS0+FWdhNtt04F14JUaqkl7tcpOpJtErvNt3Bd9HRT5JWxK25Ldjvp6br4hzfFiIdSmlzTg2fSUzNrLd1LE1ynxq4OVaVoKLjzJ60UPtj1RKzHzsbjly6inVnFBS2MucviPncU7Rr7lfTxRepDs1A2j3ZHRc7PuzFYSfE3ZOd4kjwBy227hA=="}}]);
@@ -1,2 +1,2 @@
1
1
  /*! For license information please see 663.bundle.js.LICENSE.txt */
2
- "use strict";(self.webpackChunkfilecat=self.webpackChunkfilecat||[]).push([[663],{3496:(t,e,r)=>{r.d(e,{s:()=>n});var n=function(t){return t.setting_sys_option_status_save="sys_option/status/save",t.setting_customer_router="customer_router",t.setting_customer_router_save="customer_router/save",t.setting_customer_workflow_router="customer_router/workflow",t.setting_customer_workflow_router_save="customer_router/workflow/save",t.user_save_user_file_list_show_type="save_user_file_list_show_type",t}({})},3663:(t,e,r)=>{r.r(e),r.d(e,{default:()=>Ut});var n=r(6540),o=r(7022),i=r(7444),a=r(6417),c=r(7767),u=r(4694),l=r(6007),s=r(4289),f=r(8844),h=r(7567),p=r(4251),d=r(2389),v=r(8247),m=r(9214);function y(t){return y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},y(t)}function w(){w=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof g?e:g,a=Object.create(i.prototype),c=new N(n||[]);return o(a,"_invoke",{value:j(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var h="suspendedStart",p="suspendedYield",d="executing",v="completed",m={};function g(){}function _(){}function b(){}var x={};l(x,a,(function(){return this}));var E=Object.getPrototypeOf,k=E&&E(E(C([])));k&&k!==r&&n.call(k,a)&&(x=k);var L=b.prototype=g.prototype=Object.create(x);function S(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function O(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==y(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function j(e,r,n){var o=h;return function(i,a){if(o===d)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=A(c,n);if(u){if(u===m)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?v:p,l.arg===m)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=v,n.method="throw",n.arg=l.arg)}}}function A(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,A(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,m;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function P(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function F(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function N(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(P,this),this.reset(!0)}function C(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(y(e)+" is not iterable")}return _.prototype=b,o(L,"constructor",{value:b,configurable:!0}),o(b,"constructor",{value:_,configurable:!0}),_.displayName=l(b,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===_||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,l(t,u,"GeneratorFunction")),t.prototype=Object.create(L),t},e.awrap=function(t){return{__await:t}},S(O.prototype),l(O.prototype,c,(function(){return this})),e.AsyncIterator=O,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new O(s(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},S(L),l(L,u,"Generator"),l(L,a,(function(){return this})),l(L,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=C,N.prototype={constructor:N,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(F),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!l)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),F(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;F(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:C(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function g(t){return function(t){if(Array.isArray(t))return k(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||E(t)||function(){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 _(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function b(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){_(i,n,o,a,c,"next",t)}function c(t){_(i,n,o,a,c,"throw",t)}a(void 0)}))}}function x(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,a,c=[],u=!0,l=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=i.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw o}}return c}}(t,e)||E(t,e)||function(){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 E(t,e){if(t){if("string"==typeof t)return k(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?k(t,e):void 0}}function k(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function L(t){var e=x((0,i.L4)(a.A.selectedFileList),2),r=e[0],y=e[1],_=x((0,i.L4)(a.A.clickFileList),2),E=_[0],k=_[1],L=x((0,i.L4)(a.A.nowFileList),2),S=L[0],O=L[1],j=x((0,i.L4)(a.A.confirm),2),A=(j[0],j[1]),P=x((0,i.L4)(a.A.enterKey),2),F=P[0],N=(P[1],(0,v.kZ)().click_file),C=((0,d.Bd)().t,(0,c.Zp)()),G=((0,c.zy)(),function(){var e=b(w().mark((function e(n,i){var a,c,l,f,h,p;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(null!==(0,u.kW)(r,n))y((0,u.P1)(r,n));else if("ctrl"===F)y([].concat(g(r),[n]));else if("shift"===F){if(a=(0,u.a7)(r),c=a.max,l=a.min,f=[],n>=c)for(h=c;h<=n;h++)f.push(h);else for(p=l;p>=n;p--)f.push(p);y(f)}else y([n]);if(k([].concat(g(E),[n])),setTimeout((function(){k((0,u.P1)(E,n))}),300),t.type!==o.Iw.folder){e.next=14;break}if(void 0===E.find((function(t){return t===n}))){e.next=12;break}return C((0,u.IO)((0,s.vX)(),i)),y([]),k([]),O({files:[],folders:[]}),e.abrupt("return");case 12:e.next=16;break;case 14:void 0!==E.find((function(t){return t===n}))&&N({name:i,size:t.origin_size,opt_shell:!0});case 16:case"end":return e.stop()}}),e)})));return function(t,r){return e.apply(this,arguments)}}()),I=x((0,i.L4)(a.A.showPrompt),2),T=(I[0],I[1]),M=function(){var t=b(w().mark((function t(e){var n,o;return w().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=(0,m.i)(S,r),o=n.map((function(t){return(0,m.O)(t.name)})),t.next=4,l.$M.post("cut",{files:o,to:"".concat((0,s.GG)("file",(0,s.vX)()),"/").concat(e)});case 4:t.sent,y([]),A({open:!1,handle:null}),C((0,s.vX)());case 8:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();return n.createElement(f.B,{extraAttr:{onContextMenu:function(e){!function(t,e,r,n){t.preventDefault(),t.stopPropagation();var i=new p.i;i.path=(0,u.IO)((0,s.vX)(),e),i.filename=e,i.x=t.clientX,i.y=t.clientY,i.type=r?o.Iw.folder:(0,p.u)(e),i.size=n,T({show:!0,type:h.PromptEnum.FileMenu,overlay:!1,data:i})}(e,t.name,t.type===o.Iw.folder,t.origin_size)}},draggable_handle:M,name:t.name,index:t.index,mtime:t.mtime,size:t.size,type:t.type,isLink:t.isLink,path:t.path,icon:t.icon,click:G,itemWidth:t.itemWidth})}var S=r(4976),O=r(3033);function j(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,a,c=[],u=!0,l=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=i.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return A(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?A(t,e):void 0}}(t,e)||function(){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 A(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function P(t){var e=(0,c.zy)(),r=j((0,n.useState)([]),2),o=r[0],i=r[1],a=j((0,n.useState)("/"),2),l=a[0],f=a[1],h=j((0,n.useState)(void 0),2),p=h[0],d=h[1];n.useEffect((function(){var e="",r=(0,s.vX)().split("/");r=r.filter((function(t){return t}));var n=r.indexOf(t.baseRoute),o=[];if(-1!=n){e=(0,u.IO)(r.slice(0,n),t.baseRoute);for(var a=r.slice(n+1),c=0;c<a.length;c++){var l=a[c];o.push({value:l,href:0===c?"".concat(e).concat(l,"/"):(0,u.IO)(o[c-1].href,l)})}f(e),i(o)}}),[e]);var v=function(e){e.stopPropagation(),t.clickFun(e)};return n.createElement("div",{className:"breadcrumbs",onClick:function(t){d(void 0!==p?void 0:"")}},n.createElement(n.Fragment,null,void 0===p?n.createElement(n.Fragment,null,n.createElement("span",{className:"chevron"},n.createElement(S.N_,{to:l,onClick:v},n.createElement("i",{className:"material-icons"},"home"))),o.map((function(t,e){return n.createElement("span",{className:"chevron",key:e},n.createElement("i",{className:"material-icons"},"keyboard_arrow_right"),n.createElement(S.N_,{to:t.href,onClick:v},decodeURIComponent(t.value)))}))):n.createElement(O.Sm,{width:"100%",maxWidth:"60%",placeholder:"输入跳转的目录回车(点击空白处取消)",handlerEnter:function(e){t.input_path_enter&&t.input_path_enter(e),d(void 0)}})))}var F=r(5997),N=r(7952),C=r(5726),G=r(3459),I=r(7856),T=r(4238),M=r(4944),z=r(7704),W=r(4405),X=r(505);function D(t){return D="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},D(t)}function K(){K=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof y?e:y,a=Object.create(i.prototype),c=new P(n||[]);return o(a,"_invoke",{value:S(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var h="suspendedStart",p="suspendedYield",d="executing",v="completed",m={};function y(){}function w(){}function g(){}var _={};l(_,a,(function(){return this}));var b=Object.getPrototypeOf,x=b&&b(b(F([])));x&&x!==r&&n.call(x,a)&&(_=x);var E=g.prototype=y.prototype=Object.create(_);function k(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function L(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==D(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function S(e,r,n){var o=h;return function(i,a){if(o===d)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=O(c,n);if(u){if(u===m)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?v:p,l.arg===m)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=v,n.method="throw",n.arg=l.arg)}}}function O(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,O(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,m;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function j(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function A(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function P(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function F(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(D(e)+" is not iterable")}return w.prototype=g,o(E,"constructor",{value:g,configurable:!0}),o(g,"constructor",{value:w,configurable:!0}),w.displayName=l(g,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===w||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,l(t,u,"GeneratorFunction")),t.prototype=Object.create(E),t},e.awrap=function(t){return{__await:t}},k(L.prototype),l(L.prototype,c,(function(){return this})),e.AsyncIterator=L,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new L(s(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},k(E),l(E,u,"Generator"),l(E,a,(function(){return this})),l(E,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=F,P.prototype={constructor:P,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(A),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!l)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),A(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;A(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function H(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function Y(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){H(i,n,o,a,c,"next",t)}function c(t){H(i,n,o,a,c,"throw",t)}a(void 0)}))}}function U(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,a,c=[],u=!0,l=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=i.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return $(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?$(t,e):void 0}}(t,e)||function(){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 $(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function B(t){var e=U((0,n.useState)(null),2),r=e[0],o=e[1],c=U((0,i.L4)(a.A.fileShellShow),2),u=c[0],l=(c[1],U((0,i.L4)(a.A.file_shell_hidden),2)),s=l[0],f=(l[1],U((0,n.useState)(!1),2)),h=f[0],p=f[1],d=function(){var t=Y(K().mark((function t(){var e,r,n;return K().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e=new I.Terminal({fontFamily:"Monaco, Menlo, Consolas, 'Courier New', monospace",theme:{background:"#FFFFFF",foreground:"#000000",cursor:"#000000",selectionBackground:"#a6d2ff"},cursorBlink:!0,cursorStyle:"bar",scrollback:1e3,scrollSensitivity:1,tabStopWidth:4}),n=function(t){e.write(t)},r=function(t){e.clear(),e.write(t),r=n},M.ws.addMsg(T.HK.shell_getting,(function(t){r(t.context)})),M.ws.addMsg(T.HK.shell_copy,(function(t){t.context&&(0,X.l)(t.context),e.focus()})),e.onData(function(){var t=Y(K().mark((function t(e){var r;return K().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return(r=new T.hf(T.HK.shell_send)).context=e,t.next=4,M.ws.send(r);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()),o(e);case 7:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),v=function(){Y(K().mark((function t(){return K().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:r&&(r.dispose(),o(null)),M.ws.isAilive()&&M.ws.setPromise(function(){var t=Y(K().mark((function t(e){return K().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,M.ws.unConnect();case 2:e();case 3:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}());case 2:case"end":return t.stop()}}),t)})))()};return(0,n.useEffect)((function(){return function(){v()}}),[]),(0,n.useEffect)((function(){if(u.show)if(r){if(h){var t=new T.hf(T.HK.shell_cd),e=new W.n;e.init_path=u.path,e.http_token=localStorage.getItem("token"),t.context=e,M.ws.send(t)}}else d(),p(!0);else v()}),[u]),n.createElement(z.$,{show:u.show,file_shell_hidden:s,terminal:r,init:function(t,e){r.writeln("open shell... ");var n=new T.hf(T.HK.shell_open),o=new W.n;o.init_path=u.path,o.rows=t,o.cols=e,o.http_token=localStorage.getItem("token"),n.context=o,M.ws.send(n)}})}var q,R,Z=r(5725),J=r(2042),V=r(7523),Q=r(8815),tt=r(2730),et=r(447),rt=r(7481),nt=r(7071),ot=r(8062);function it(t){return it="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},it(t)}function at(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=ht(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}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 i,a=!0,c=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return a=t.done,t},e:function(t){c=!0,i=t},f:function(){try{a||null==r.return||r.return()}finally{if(c)throw i}}}}function ct(t){return function(t){if(Array.isArray(t))return pt(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||ht(t)||function(){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 ut(){ut=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof y?e:y,a=Object.create(i.prototype),c=new P(n||[]);return o(a,"_invoke",{value:S(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var h="suspendedStart",p="suspendedYield",d="executing",v="completed",m={};function y(){}function w(){}function g(){}var _={};l(_,a,(function(){return this}));var b=Object.getPrototypeOf,x=b&&b(b(F([])));x&&x!==r&&n.call(x,a)&&(_=x);var E=g.prototype=y.prototype=Object.create(_);function k(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function L(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==it(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function S(e,r,n){var o=h;return function(i,a){if(o===d)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=O(c,n);if(u){if(u===m)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?v:p,l.arg===m)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=v,n.method="throw",n.arg=l.arg)}}}function O(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,O(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,m;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function j(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function A(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function P(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function F(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(it(e)+" is not iterable")}return w.prototype=g,o(E,"constructor",{value:g,configurable:!0}),o(g,"constructor",{value:w,configurable:!0}),w.displayName=l(g,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===w||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,l(t,u,"GeneratorFunction")),t.prototype=Object.create(E),t},e.awrap=function(t){return{__await:t}},k(L.prototype),l(L.prototype,c,(function(){return this})),e.AsyncIterator=L,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new L(s(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},k(E),l(E,u,"Generator"),l(E,a,(function(){return this})),l(E,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=F,P.prototype={constructor:P,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(A),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!l)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),A(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;A(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function lt(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function st(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){lt(i,n,o,a,c,"next",t)}function c(t){lt(i,n,o,a,c,"throw",t)}a(void 0)}))}}function ft(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,a,c=[],u=!0,l=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=i.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw o}}return c}}(t,e)||ht(t,e)||function(){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 ht(t,e){if(t){if("string"==typeof t)return pt(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?pt(t,e):void 0}}function pt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}var dt,vt,mt=-1;function yt(t){var e=(0,d.Bd)().t,r=ft((0,i.L4)(a.A.workflow_show),2),o=(r[0],r[1]),c=ft((0,n.useState)([]),2),u=c[0],l=c[1],f=ft((0,n.useState)([]),2),h=f[0],p=f[1],v=ft((0,n.useState)(!1),2),m=v[0],y=v[1],w=ft((0,n.useState)(void 0),2),g=w[0],_=w[1],b=ft((0,n.useState)([]),2),x=b[0],E=b[1],k=ft((0,n.useState)(-1),2),L=k[0],S=k[1],j=ft((0,n.useState)(10),2),A=j[0],P=(j[1],ft((0,n.useState)(0),2)),C=(P[0],P[1]),G=ft((0,n.useState)(0),2),W=G[0],X=G[1],D=ft((0,n.useState)(""),2),K=D[0],H=D[1],Y=ft((0,n.useState)(!1),2),U=Y[0],$=Y[1],B=[e("序号"),e("运行名称"),e("状态"),e("运行时长"),e("日期"),e("操作")],V=[e("名称"),e("状态"),e("cwd"),e("运行时长"),e("操作")],tt=function(){var t=st(ut().mark((function t(e){var r,n,o;return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return(r=new nt._).page_num=null!=e?e:L,r.page_size=A,r.dir_path="".concat((0,s.GG)("file",(0,s.vX)())),t.next=6,M.ws.sendData(T.HK.workflow_get,r);case 6:if(n=t.sent){t.next=9;break}return t.abrupt("return");case 9:o=n.context,l(o.list.map((function(t){var e="string"==typeof t.meta?JSON.parse(t.meta):t.meta;return e.index=t.index,e}))),C(o.total),X((0,Q.gw)(o.total,A));case 13:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),it=function(){var t=st(ut().mark((function t(e){var r,n,o;return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return(r=new nt._).search_name=e,r.dir_path="".concat((0,s.GG)("file",(0,s.vX)())),$(!0),t.next=6,M.ws.sendData(T.HK.workflow_search_by_run_name,r);case 6:if(n=t.sent){t.next=9;break}return t.abrupt("return");case 9:o=n.context,l(o.list.map((function(t){var e="string"==typeof t.meta?JSON.parse(t.meta):t.meta;return e.index=t.index,e}))),C(o.total),X((0,Q.gw)(o.total,A)),S(0),$(!1);case 15:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),lt=function(){var t=st(ut().mark((function t(){var e;return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e=new I.Terminal({fontFamily:"Monaco, Menlo, Consolas, 'Courier New', monospace",theme:{background:"#FFFFFF",foreground:"#000000",cursor:"#000000",selectionBackground:"#a6d2ff"},cursorBlink:!0,cursorStyle:"bar",scrollback:1e3,scrollSensitivity:1,tabStopWidth:4,convertEol:!0}),R=e,_(e);case 3:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();(0,n.useEffect)((function(){return y(!1),q=void 0,R=void 0,mt=-1,tt(),st(ut().mark((function t(){return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:R&&(R.dispose(),R=null);case 1:case"end":return t.stop()}}),t)})))}),[]);var ht=function(){var t=st(ut().mark((function t(e){var r,n,o,i,a,c;return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!e.is_running){t.next=2;break}return t.abrupt("return");case 2:return E([]),(r=new nt._).index=e.index,r.dir_path="".concat((0,s.GG)("file",(0,s.vX)())),t.next=8,M.ws.sendData(T.HK.workflow_get,r);case 8:n=t.sent,o=n.context,i="string"==typeof o.one_data.data?JSON.parse(o.one_data.data):o.one_data.data,a=i.success_list,c=i.fail_list,p([].concat(ct(c),ct(a)));case 14:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),pt=function(t,e,r){if(e){var o,i=at(null!=e?e:[]);try{for(i.s();!(o=i.n()).done;){var a,c,u,l=o.value,s=void 0,f=[];l["use-yml"]?(pt(f,void 0,l.use_job_children_list),s="".concat(l["use-yml"]," ;").concat(null!==(c=l.duration)&&void 0!==c?c:-1)):s="".concat(l.run," ;").concat(null!==(u=l.duration)&&void 0!==u?u:-1),s=n.createElement("div",null,n.createElement(et.fq,{success:void 0===l.code?void 0:0===l.code}),"$",s),t.push({name:s,children:f,extra_data:{code:l.code,context:null!==(a=l.success_message)&&void 0!==a?a:l.fail_message}})}}catch(t){i.e(t)}finally{i.f()}}else if(r){var h,p=at(null!=r?r:[]);try{for(p.s();!(h=p.n()).done;){var d=h.value,v=n.createElement("div",null,n.createElement(et.fq,{success:void 0===d.code?void 0:0===d.code}),"$",d.name);t.push({name:v,extra_data:{code:d.code,is_job:!0,job_data:d}})}}catch(t){p.e(t)}finally{p.f()}}},dt=function(){var t=st(ut().mark((function t(e){var r,n;return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:r=e.steps,pt(n=[],null!=r?r:[]),E(n);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),vt=function(){var t=st(ut().mark((function t(e){return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(R){t.next=3;break}return t.next=3,new Promise((function(t){q=t,y(!0),lt()}));case 3:e&&(R.reset(),R.write(e));case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),yt=function(){var t=st(ut().mark((function t(e){var r,n,o;return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(null==e||null===(r=e.extra_data)||void 0===r||!r.is_job){t.next=4;break}return t.next=3,dt(e.extra_data.job_data);case 3:return t.abrupt("return");case 4:if(null==e||null===(n=e.extra_data)||void 0===n||!n.context){t.next=8;break}vt(e.extra_data.context),t.next=11;break;case 8:if(null!=e&&e.extra_data.code){t.next=10;break}return t.abrupt("return");case 10:vt(null!==(o=e.extra_data.code)&&void 0!==o?o:"");case 11:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();return n.createElement("div",null,n.createElement(N.A,null,g&&n.createElement(F.rA,{icon:"print",title:"打印日志",onClick:function(){y(!m)}}),n.createElement(F.rA,{icon:"close",title:e("关闭"),onClick:function(){o(!1)}})),n.createElement(Z.jW,{isFull:!0,more:!0},n.createElement(Z.NN,null,n.createElement(Z.xh,null,n.createElement(Z.fI,null,n.createElement(Z.VP,null,n.createElement(et.uF,{self_title:n.createElement("span",{className:" div-row "},n.createElement("h2",null,e("历史记录"))),titleCom:n.createElement("div",{className:" div-row "},n.createElement(O.Sm,{disabled:U,value:K,placeholder:"搜索运行名称(支持正则)",handleInputChange:function(t){H(K)},handlerEnter:function(t){it(t)}})),rightBottomCom:n.createElement("span",{className:" div-row "},n.createElement("span",null,Math.abs(L),"/",W),n.createElement(O.Sm,{placeholder:"max page ".concat(W),handleInputChange:function(t){mt=parseInt(t)},handlerEnter:function(){if(mt<1||mt>W)(0,J.zN)("illegal page num");else{var t=0-mt;S(t),tt(t)}}}),n.createElement(F.rA,{icon:"navigate_before",onClick:function(){var t=L+1;t>-1?(0,J.zN)("max page num"):(S(t),tt(t))},title:"上一页"}),n.createElement(F.rA,{icon:"navigate_next",onClick:function(){var t=L-1;Math.abs(t)>W?(0,J.zN)("min page num"):(S(t),tt(t))},title:"下一页"}))},n.createElement(rt.X,{headers:B,rows:u.map((function(t,r){var o;return o=t.is_running?n.createElement("div",null,n.createElement(et.fq,null),e("正在运行")):n.createElement("div",null,n.createElement(et.fq,{success:t.is_success}),t.is_success?e("成功"):e("失败")),[n.createElement("p",null,t.index),n.createElement("p",{style:{wordWrap:"break-word"}},t["run-name"]),o,n.createElement("span",null,t.duration),n.createElement("span",null,t.timestamp),n.createElement("div",null,n.createElement(F.rA,{icon:"details",title:e("详情"),onClick:function(){ht(t)}}))]})),width:"10rem"}))),n.createElement(Z.VP,null,n.createElement(et.Zp,{title:e("Job")},n.createElement(rt.X,{headers:V,rows:h.map((function(t,r){return[n.createElement("p",null,t.name),n.createElement("div",null,n.createElement(et.fq,{success:void 0===t.code?void 0:0===t.code}),0===t.code?e("成功"):e("失败")),n.createElement(et.xP,null,t.cwd),n.createElement("span",null,t.duration),n.createElement("div",null,n.createElement(F.rA,{icon:"details",title:e("详情"),onClick:function(){dt(t)}}),(!!t.success_message||!!t.fail_message)&&n.createElement(F.rA,{icon:"print",title:e("日志"),onClick:function(){var e;vt(null!==(e=t.success_message)&&void 0!==e?e:t.fail_message)}}))]})),width:"10rem"})),n.createElement(et.Zp,{title:"Step"},n.createElement(ot.A,{list:x,click:function(t){yt(t)}}))))))),n.createElement("div",{style:{display:m?"":"none"}},n.createElement(z.$,{show:!0,terminal:g,init:function(){q&&(q(1),q=void 0)}})))}function wt(t){return wt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},wt(t)}function gt(){gt=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof y?e:y,a=Object.create(i.prototype),c=new P(n||[]);return o(a,"_invoke",{value:S(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var h="suspendedStart",p="suspendedYield",d="executing",v="completed",m={};function y(){}function w(){}function g(){}var _={};l(_,a,(function(){return this}));var b=Object.getPrototypeOf,x=b&&b(b(F([])));x&&x!==r&&n.call(x,a)&&(_=x);var E=g.prototype=y.prototype=Object.create(_);function k(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function L(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==wt(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function S(e,r,n){var o=h;return function(i,a){if(o===d)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=O(c,n);if(u){if(u===m)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?v:p,l.arg===m)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=v,n.method="throw",n.arg=l.arg)}}}function O(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,O(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,m;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function j(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function A(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function P(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function F(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(wt(e)+" is not iterable")}return w.prototype=g,o(E,"constructor",{value:g,configurable:!0}),o(g,"constructor",{value:w,configurable:!0}),w.displayName=l(g,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===w||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,l(t,u,"GeneratorFunction")),t.prototype=Object.create(E),t},e.awrap=function(t){return{__await:t}},k(L.prototype),l(L.prototype,c,(function(){return this})),e.AsyncIterator=L,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new L(s(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},k(E),l(E,u,"Generator"),l(E,a,(function(){return this})),l(E,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=F,P.prototype={constructor:P,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(A),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!l)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),A(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;A(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function _t(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function bt(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){_t(i,n,o,a,c,"next",t)}function c(t){_t(i,n,o,a,c,"throw",t)}a(void 0)}))}}function xt(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,a,c=[],u=!0,l=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=i.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw o}}return c}}(t,e)||Et(t,e)||function(){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 Et(t,e){if(t){if("string"==typeof t)return kt(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?kt(t,e):void 0}}function kt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function Lt(t){var e=(0,d.Bd)().t,r=xt((0,i.L4)(a.A.workflow_realtime_show),2),o=r[0],c=r[1],u=xt((0,n.useState)([]),2),l=(u[0],u[1],xt((0,n.useState)([]),2)),f=(l[0],l[1],xt((0,n.useState)(!1),2)),h=f[0],p=f[1],v=xt((0,n.useState)(void 0),2),m=v[0],y=v[1],w=xt((0,n.useState)([]),2),g=w[0],_=w[1],b=function(t){var e,r=function(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=Et(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}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 i,a=!0,c=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return a=t.done,t},e:function(t){c=!0,i=t},f:function(){try{a||null==r.return||r.return()}finally{if(c)throw i}}}}(t);try{for(r.s();!(e=r.n()).done;){var o,i,a,c=e.value;(null==c||null===(o=c.extra_data)||void 0===o?void 0:o.running_type)===nt.rl.success?c.name=n.createElement("div",null,n.createElement(et.fq,{success:!0}),c.name):(null==c||null===(i=c.extra_data)||void 0===i?void 0:i.running_type)===nt.rl.fail?c.name=n.createElement("div",null,n.createElement(et.fq,{success:!1}),c.name):(null==c||null===(a=c.extra_data)||void 0===a?void 0:a.running_type)===nt.rl.running&&(c.name=n.createElement("div",null,n.createElement(et.fq,{running:!0}),c.name)),c.children&&b(c.children)}}catch(t){r.e(t)}finally{r.f()}},x=function(){var t=bt(gt().mark((function t(e){var r;return gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:(r=new nt.v3).filename_path="".concat((0,s.GG)("file",(0,s.vX)())).concat(o.filename),M.ws.addMsg(T.HK.workflow_realtime_one_rsq,(function(t){if(t.context.list&&t.context.list.length>0){var e=t.context.list;b(e),_(e)}t.context.new_log&&k(t.context.new_log)})),M.ws.sendData(T.HK.workflow_realtime_one_req,r);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),E=function(){var t=bt(gt().mark((function t(){var e;return gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e=new I.Terminal({fontFamily:"Monaco, Menlo, Consolas, 'Courier New', monospace",theme:{background:"#FFFFFF",foreground:"#000000",cursor:"#000000",selectionBackground:"#a6d2ff"},cursorBlink:!0,cursorStyle:"bar",scrollback:1e3,scrollSensitivity:1,tabStopWidth:4,convertEol:!0}),vt=e,y(e);case 3:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();(0,n.useEffect)((function(){return p(!1),dt=void 0,vt=void 0,x(),bt(gt().mark((function t(){return gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:M.ws.removeMsg(T.HK.workflow_realtime_one_rsq),vt&&(vt.dispose(),vt=null);case 2:case"end":return t.stop()}}),t)})))}),[]);var k=function(){var t=bt(gt().mark((function t(e){return gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(vt){t.next=3;break}return t.next=3,new Promise((function(t){dt=t,p(!0),E()}));case 3:e&&vt.write(e);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();return n.createElement("div",null,n.createElement(N.A,null,m&&n.createElement(F.rA,{icon:"print",title:"打印日志",onClick:function(){p(!h)}}),n.createElement(F.rA,{icon:"close",title:e("关闭"),onClick:function(){c({open:!1})}})),n.createElement(Z.jW,{isFull:!0,more:!0},n.createElement(Z.NN,null,n.createElement(ot.A,{list:g,click:function(t){}}))),n.createElement("div",{style:{display:h?"":"none"}},n.createElement(z.$,{show:!0,terminal:m,init:function(){dt&&(dt(1),dt=void 0)}})))}var St=r(3430),Ot=r(2458),jt=r(3496);function At(t){return At="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},At(t)}function Pt(){return Pt=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)({}).hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},Pt.apply(null,arguments)}function Ft(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Nt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Ft(Object(r),!0).forEach((function(e){Ct(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Ft(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Ct(t,e,r){return(e=function(t){var e=function(t){if("object"!=At(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=At(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==At(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Gt(){Gt=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof y?e:y,a=Object.create(i.prototype),c=new P(n||[]);return o(a,"_invoke",{value:S(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var h="suspendedStart",p="suspendedYield",d="executing",v="completed",m={};function y(){}function w(){}function g(){}var _={};l(_,a,(function(){return this}));var b=Object.getPrototypeOf,x=b&&b(b(F([])));x&&x!==r&&n.call(x,a)&&(_=x);var E=g.prototype=y.prototype=Object.create(_);function k(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function L(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==At(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function S(e,r,n){var o=h;return function(i,a){if(o===d)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=O(c,n);if(u){if(u===m)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?v:p,l.arg===m)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=v,n.method="throw",n.arg=l.arg)}}}function O(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,O(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,m;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function j(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function A(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function P(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function F(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(At(e)+" is not iterable")}return w.prototype=g,o(E,"constructor",{value:g,configurable:!0}),o(g,"constructor",{value:w,configurable:!0}),w.displayName=l(g,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===w||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,l(t,u,"GeneratorFunction")),t.prototype=Object.create(E),t},e.awrap=function(t){return{__await:t}},k(L.prototype),l(L.prototype,c,(function(){return this})),e.AsyncIterator=L,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new L(s(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},k(E),l(E,u,"Generator"),l(E,a,(function(){return this})),l(E,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=F,P.prototype={constructor:P,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(A),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!l)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),A(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;A(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function It(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=Wt(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}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 i,a=!0,c=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return a=t.done,t},e:function(t){c=!0,i=t},f:function(){try{a||null==r.return||r.return()}finally{if(c)throw i}}}}function Tt(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function Mt(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){Tt(i,n,o,a,c,"next",t)}function c(t){Tt(i,n,o,a,c,"throw",t)}a(void 0)}))}}function zt(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,a,c=[],u=!0,l=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=i.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw o}}return c}}(t,e)||Wt(t,e)||function(){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 Wt(t,e){if(t){if("string"==typeof t)return Xt(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Xt(t,e):void 0}}function Xt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}var Dt,Kt=Object.values(St.UG),Ht=280,Yt={};function Ut(){var t,e,r=zt((0,i.L4)(a.A.editorSetting),2),f=(r[0],r[1]),y=zt((0,i.L4)(a.A.file_preview),2),w=(y[0],y[1]),g=(0,d.Bd)().t,_=(0,n.useRef)(null),b=(0,c.zy)(),x=(0,c.Zp)(),E=(0,v.MH)().check_user_auth,k=zt((0,i.L4)(a.A.nowFileList),2),S=k[0],j=k[1],A=zt((0,i.L4)(a.A.uploadFiles),2),I=(A[0],A[1]),z=zt((0,i.L4)(a.A.showPrompt),2),W=(z[0],z[1]),X=zt((0,i.L4)(a.A.selectedFileList),2),D=X[0],K=(X[1],zt((0,i.L4)(a.A.copyedFileList),2)),H=K[0],Y=K[1],U=zt((0,i.L4)(a.A.enterKey),2),$=(U[0],U[1]),q=zt((0,i.L4)(a.A.cutedFileList),2),R=q[0],rt=q[1],ot=zt((0,i.L4)(a.A.selectedFileList),2),it=(ot[0],ot[1]),at=zt((0,i.L4)(a.A.clickFileList),2),ct=(at[0],at[1]),ut=zt((0,i.L4)(a.A.fileShellShow),2),lt=ut[0],st=ut[1],ft=zt((0,i.L4)(a.A.file_root_list),2),ht=ft[0],pt=(ft[1],zt((0,i.L4)(a.A.file_root_index),2)),dt=(pt[0],pt[1]),vt=zt((0,n.useState)(void 0),2),mt=vt[0],wt=vt[1],gt=zt((0,n.useState)(""),2),_t=gt[0],bt=gt[1],xt=zt((0,i.L4)(a.A.workflow_show),2),Et=xt[0],kt=xt[1],At=zt((0,i.L4)(a.A.workflow_realtime_show),2),Ft=At[0],Ct=(At[1],zt((0,n.useState)(!1),2)),Tt=Ct[0],Wt=Ct[1],Xt=(0,n.useContext)(V.F).reloadUserInfo,Ut=(0,n.useContext)(V.F).initUserInfo,$t=zt((0,i.L4)(a.A.user_base_info),2),Bt=$t[0],qt=($t[1],(0,v.kZ)().click_file),Rt=zt((0,i.L4)(a.A.prompt_card),2),Zt=(Rt[0],Rt[1]),Jt=(0,v.hg)().file_is_running,Vt=zt((0,i.L4)(a.A.to_running_files),2),Qt=(Vt[0],Vt[1]),te=zt((0,i.L4)(a.A.router_jump),2),ee=(te[0],te[1]),re=function(){var t=Mt(Gt().mark((function t(){var e;return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return(e=new nt.Nd).dir_path="".concat((0,s.GG)("file",(0,s.vX)())),M.ws.addMsg(T.HK.workflow_realtime,(function(t){var e,r=t.context,n=It(r.sucess_file_list);try{for(n.s();!(e=n.n()).done;){var o=e.value;o.endsWith(".workflow.yml")?(0,J.LW)("".concat(o.slice(0,-13)," done!")):o.endsWith(".act")&&(0,J.LW)("".concat(o.slice(0,-4)," done!"))}}catch(t){n.e(t)}finally{n.f()}var i,a=It(r.failed_file_list);try{for(a.s();!(i=a.n()).done;){var c=i.value;c.endsWith(".workflow.yml")?(0,J.zN)("".concat(c.slice(0,-13)," failed!")):c.endsWith(".act")&&(0,J.zN)("".concat(c.slice(0,-4)," failed!"))}}catch(t){a.e(t)}finally{a.f()}Qt(new Set(r.running_file_list))})),t.next=5,M.ws.sendData(T.HK.workflow_realtime,e);case 5:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),ne=function(){var t=Mt(Gt().mark((function t(e){var r,n,o,i,a,c,f,h,p,d,v,m,y;return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e=e?encodeURIComponent(e)+"?is_sys_path=1":encodeURIComponent((0,s.GG)("file",(0,s.vX)())),t.next=3,l.$M.get(e);case 3:if((o=t.sent).code!==G.m.PreFile){t.next=7;break}return qt({name:o.message,context:o.data,opt_shell:!0}),t.abrupt("return");case 7:if(o.code===G.m.Sucess){t.next=10;break}return o.message&&(0,J.zN)(o.message),t.abrupt("return");case 10:i=o.data,t.t0=Bt.user_data.dir_show_type,t.next=t.t0===St.t8.size_max_min||t.t0===St.t8.size_min_max?14:t.t0===St.t8.time_minx_max||t.t0===St.t8.time_max_min?18:t.t0===St.t8.name?22:24;break;case 14:return a=Bt.user_data.dir_show_type===St.t8.size_min_max,(0,u.di)(i.files,(function(t){return t.size}),a),(0,u.di)(i.folders,(function(t){return t.size}),a),t.abrupt("break",25);case 18:return c=Bt.user_data.dir_show_type===St.t8.time_minx_max,(0,u.di)(i.files,(function(t){return t.mtime}),c),(0,u.di)(i.folders,(function(t){return t.mtime}),c),t.abrupt("break",25);case 22:return(0,u.di)(i.folders,(function(t){return t.name})),t.abrupt("break",25);case 24:return t.abrupt("break",25);case 25:f=!1,h=It(null!==(r=i.files)&&void 0!==r?r:[]);try{for(h.s();!(p=h.n()).done;)(d=p.value).mtime=d.mtime?(0,Q.s8)(d.mtime):"",d.origin_size=d.size,d.size=(0,Q.v7)(d.size),(!f&&d.name.endsWith(".workflow.yml")||d.name.endsWith(".act"))&&(f=!0,Promise.resolve().then((function(){re()})))}catch(t){h.e(t)}finally{h.f()}if(void 0===i.relative_user_path){t.next=32;break}return(i.relative_user_path.startsWith("\\")||i.relative_user_path.startsWith("/"))&&(i.relative_user_path=i.relative_user_path.slice(1)),x(i.relative_user_path),t.abrupt("return");case 32:f=!1,v=It(null!==(n=i.folders)&&void 0!==n?n:[]);try{for(v.s();!(m=v.n()).done;)(y=m.value).mtime=y.mtime?(0,Q.s8)(y.mtime):"",f||y.name!==nt.SB||(Wt(!0),f=!0)}catch(t){v.e(t)}finally{v.f()}j(o.data),Dt=o.data;case 37:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),oe=function(){var t=Math.floor(document.querySelector("main").offsetWidth/Ht);0===t&&(t=1),wt("calc(".concat(100/t,"% - 1em)"))};(0,n.useEffect)((function(){var t=function(){var t=Mt(Gt().mark((function t(){return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ne();case 2:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();t(),f({open:!1}),w({open:!1}),Wt(!1),Yt={}}),[b]),(0,n.useEffect)((function(){return Mt(Gt().mark((function t(){return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:Qt(new Set);case 1:case"end":return t.stop()}}),t)})))}),[]);var ie=function(){var t=Mt(Gt().mark((function t(e){var r,n,o,i;return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(e.preventDefault(),e.stopPropagation(),r=e.dataTransfer,n=e.target,!(r.files.length<=0)){t.next=6;break}return t.abrupt("return");case 6:for(o=0;o<5;o++)null===n||n.classList.contains("item")||(n=n.parentElement);return t.next=9,(0,C.T)(r);case 9:i=t.sent,I(i),W({show:!0,type:h.PromptEnum.FilesUpload,overlay:!1,data:{}});case 12:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),ae=function(t){t.preventDefault()};function ce(){return(ce=Mt(Gt().mark((function t(){var e,r,n;return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=(0,u.jH)(Kt,null!==(e=null==Bt||null===(r=Bt.user_data)||void 0===r?void 0:r.file_list_show_type)&&void 0!==e?e:""),t.next=3,l.wm.post(jt.s.user_save_user_file_list_show_type,{type:n});case 3:Ut();case 4:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function ue(t){(0,J.LW)(t)}(0,n.useEffect)((function(){var t=_.current.ownerDocument;return t.addEventListener("dragover",ae),t.addEventListener("drop",ie),oe(),window.addEventListener("resize",oe),function(){t.removeEventListener("dragover",ae),t.removeEventListener("drop",ie),window.removeEventListener("resize",oe),lt.show&&st({show:!1,path:""})}}),[]);var le=function(){var t=Mt(Gt().mark((function t(e){return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return dt(e),t.next=3,l.$M.post("base_switch",{root_index:e});case 3:return t.next=5,Xt();case 5:x("/file/"),it([]),ct([]);case 8:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),se=function(t){Zt({open:!0,title:"信息",context_div:n.createElement("div",{style:{maxWidth:"25rem"}},n.createElement(Z.Yh,{left:g("挂载位置磁盘"),right:null==t?void 0:t.total_size}),n.createElement(Z.Yh,{left:"".concat(g("磁盘剩余")),right:null==t?void 0:t.left_size}),n.createElement(Z.Yh,{left:"".concat(g("文件系统")),right:null==t?void 0:t.fs_type}),n.createElement(Z.Yh,{left:"".concat(g("文件夹数")),right:S.folders.length}),n.createElement(Z.Yh,{left:"".concat(g("文件数")),right:S.files.length}),n.createElement(Z.Yh,{left:"".concat(g("当前位置")),right:n.createElement(et.xP,{context:null==t?void 0:t.now_absolute_path})}))})},fe=function(){var t=Mt(Gt().mark((function t(){var e,r;return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(Yt.now_absolute_path){t.next=8;break}return M.ws.addMsg(T.HK.file_info,(function(t){var r=t.context;e&&(Yt=Nt(Nt({},Yt),r),M.ws.removeMsg(T.HK.file_info),se(Yt))})),t.next=4,M.ws.sendData(T.HK.file_info,{type:o.Iw.folder,path:(0,s.GG)("file",(0,s.vX)())});case 4:r=t.sent,e=r.context,se(Yt=e);case 8:se(Yt);case 9:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),he=zt((0,n.useState)(!1),2),pe=he[0],de=he[1];(0,n.useEffect)((function(){var t=function(t){if(pe)if(t.ctrlKey)if("a"===t.key||"A"===t.key){for(var e=S.files.length,r=S.folders.length,n=[],o=0;o<e+r;o++)n.push(o);it(n)}else $("ctrl");else"Escape"===t.key?it([]):"Shift"===t.key&&$("shift")},e=function(t){t.ctrlKey||$("")};return window.addEventListener("keydown",t),window.addEventListener("keyup",e),function(){window.removeEventListener("keydown",t),window.removeEventListener("keyup",e)}}),[S,pe]);var ve=function(t){t.target===t.currentTarget&&it([])};return n.createElement("div",{className:"not-select-div"},n.createElement(N.A,{left_children:n.createElement(O.$Z,{handleEnterPress:function(){var t,e;if(Dt){it([]),ct([]);var r,n=[],o=[],i=It(null!==(t=Dt.files)&&void 0!==t?t:[]);try{for(i.s();!(r=i.n()).done;){var a=r.value;a.name.includes(_t)&&n.push(a)}}catch(t){i.e(t)}finally{i.f()}var c,u=It(null!==(e=Dt.folders)&&void 0!==e?e:[]);try{for(u.s();!(c=u.n()).done;){var l=c.value;l.name.includes(_t)&&o.push(l)}}catch(t){u.e(t)}finally{u.f()}j({files:n,folders:o})}},placeholder:g("搜索当前目录"),icon:"search",value:"",handleInputChange:function(t){bt(t)},max_width:"25em"})},D.length>0&&n.createElement(F.rA,{icon:"delete",title:g("删除"),onClick:function(){W({show:!0,type:h.PromptEnum.FilesDelete,overlay:!0,data:{}})}}),D.length>0&&n.createElement(F.rA,{icon:"content_copy",title:g("复制"),onClick:function(){var t=(0,m.i)(S,D);Y(t.map((function(t){return(0,m.O)(t.name)}))),rt([]),ue("已复制")}}),D.length>0&&n.createElement(F.rA,{icon:"content_cut",title:g("剪切"),onClick:function(){var t=(0,m.i)(S,D);rt(t.map((function(t){return(0,m.O)(t.name)}))),Y([]),ue("已剪切")}}),(H.length>0||R.length>0)&&n.createElement(F.rA,{onClick:function(){W({show:!0,type:h.PromptEnum.Confirm,overlay:!0,data:{}})},icon:"content_paste",title:g("粘贴到此处"),tip:H.length+R.length}),D.length>0&&n.createElement(F.rA,{icon:"download",title:g("下载"),onClick:function(){for(var t=(0,m.i)(S,D),e=0;e<t.length;e++){var r=t[e];t[e]=encodeURIComponent((0,m.O)(r.name))}var n=l.$M.getDownloadUrl(t);window.open(n)}}),D.length>0&&n.createElement(F.rA,{icon:"compress",title:g("压缩"),onClick:function(){for(var t=(0,m.i)(S,D),e=0;e<t.length;e++){var r=t[e];t[e]=(0,m.O)(r.name)}t&&0!==t.length?W({show:!0,type:h.PromptEnum.Compress,overlay:!0,data:{files:t}}):(0,J.zN)("没有选中")}}),1===D.length&&n.createElement(F.rA,{icon:"edit_attributes",title:g("重命名"),onClick:function(){W({show:!0,type:h.PromptEnum.FileRename,overlay:!0,data:{}})}}),Tt&&n.createElement(F.rA,{icon:"api",title:"workflow",onClick:function(){kt(!Et)}}),n.createElement(F.rA,{icon:"terminal",title:"shell",onClick:function(){lt.show?st({show:!1,path:""}):st({show:!0,path:(0,s.GG)("file",(0,s.vX)())})}}),n.createElement(F.rA,{icon:"grid_view",title:g("切换样式"),onClick:function(){return ce.apply(this,arguments)}}),n.createElement(F.rA,{icon:"create_new_folder",title:g("创建文件夹"),onClick:function(){W({show:!0,type:h.PromptEnum.DirNew,overlay:!0,data:{dir:(0,s.GG)("file",(0,s.vX)())}})}}),n.createElement(F.rA,{icon:"note_add",title:g("创建文本文件"),onClick:function(){W({show:!0,type:h.PromptEnum.FileNew,overlay:!0,data:{dir:(0,s.GG)("file",(0,s.vX)())}})}}),n.createElement(F.rA,{icon:"upload_file",title:"上传",onClick:function(){W({show:!0,type:h.PromptEnum.UploadFile,overlay:!0,data:{call:function(t){var e,r=null===(e=t.currentTarget)||void 0===e?void 0:e.files;if(r){for(var n=!!r[0].webkitRelativePath,o=[],i=new Set,a=0;a<r.length;a++){var c=r[a],u=n?c.webkitRelativePath:"".concat(c.webkitRelativePath).concat(c.name);c.fullPath=u,n&&i.add((0,tt.S)(u)),o.push(c)}var l=[];if(n){var s,f=It(i);try{for(f.s();!(s=f.n()).done;){var p=s.value;l.push({isDir:!0,fullPath:p,name:p})}}catch(t){f.e(t)}finally{f.f()}}l.push.apply(l,o),I(l),W({show:!0,type:h.PromptEnum.FilesUpload,overlay:!1,data:{}})}}}})}}),n.createElement(F.rA,{icon:"info",title:g("信息"),onClick:fe}),n.createElement(F.rA,{icon:"more_vert",title:g("切换目录"),onClick:function(t){var e=new p.i;e.x=t.clientX,e.y=t.clientY,e.type=o.Iw.directory,e.items=ht,e.textClick=function(){var t=Mt(Gt().mark((function t(e){return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:le(e),W({data:void 0,overlay:!1,type:"",show:!1});case 2:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),W({show:!0,type:h.PromptEnum.FileMenu,overlay:!1,data:e})}})),n.createElement(P,{baseRoute:"file",clickFun:function(){it([]),ct([])},input_path_enter:function(t){(0,Ot.Z1)(t)?ne(t):x((0,Ot.Jn)((0,s.vX)(),t)),it([]),ct([]),j({files:[],folders:[]})}}),n.createElement("div",{onContextMenu:function(t){t.preventDefault(),t.stopPropagation();var e=new p.i;e.x=t.clientX,e.y=t.clientY,e.type=o.Iw.directory;var r=[{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.time_minx_max?"green":void 0}},"时间顺序"),v:St.t8.time_minx_max},{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.time_max_min?"green":void 0}},"时间逆序"),v:St.t8.time_max_min}],i=[{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.size_min_max?"green":void 0}},"大小顺序"),v:St.t8.size_min_max},{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.size_max_min?"green":void 0}},"大小逆序"),v:St.t8.size_max_min}],a=[{r:"文件排序",v:"",items:[{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type?void 0:"green"}},"系统默认"),v:St.t8.defualt},{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.name?"green":void 0}},"名字"),v:St.t8.name},{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.time_minx_max||Bt.user_data.dir_show_type===St.t8.time_max_min?"green":void 0}},"修改时间"),v:!1,items:r},{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.size_min_max||Bt.user_data.dir_show_type===St.t8.size_max_min?"green":void 0}},"文件大小"),v:!1,items:i}]}];E(St.oV.code_resource)&&a.push({r:"添加http资源根目录",v:"code_resource"}),E(St.oV.http_proxy)&&a.push({r:"在此目录下载http资源",v:"http_resource"}),e.items=a,e.textClick=function(){var t=Mt(Gt().mark((function t(e){var r,n;return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!1!==e){t.next=2;break}return t.abrupt("return");case 2:if("code_resource"!==e){t.next=12;break}return t.next=5,M.ws.sendData(T.HK.file_info,{path:(0,s.GG)("file",(0,s.vX)())});case 5:return r=t.sent,ee({page_self_router_api_data:["",r.context.now_absolute_path]}),W({data:void 0,overlay:!1,type:"",show:!1}),x("/setting/customer_router/"),t.abrupt("return");case 12:if("http_resource"!==e){t.next=20;break}return t.next=15,M.ws.sendData(T.HK.file_info,{path:(0,s.GG)("file",(0,s.vX)())});case 15:return n=t.sent,ee({http_download_map_path:n.context.now_absolute_path}),W({data:void 0,overlay:!1,type:"",show:!1}),x("/toolbox/http/"),t.abrupt("return");case 20:return t.next=22,l.wm.post(jt.s.user_save_user_file_list_show_type,{type:e,is_dir_list_type:!0});case 22:return t.next=24,Ut();case 24:W({data:void 0,overlay:!1,type:"",show:!1}),x((0,s.vX)());case 26:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),W({show:!0,type:h.PromptEnum.FileMenu,overlay:!1,data:e})},id:"listing",style:{paddingBottom:"10rem"},className:"mosaic file-icons ".concat(null!==(t=null==Bt||null===(e=Bt.user_data)||void 0===e?void 0:e.file_list_show_type)&&void 0!==t?t:""),ref:_,onMouseEnter:function(){de(!0)},onMouseLeave:function(){de(!1)}},S.folders&&S.folders.length>0&&n.createElement("h2",null,g("文件夹")),S.folders&&n.createElement("div",{onClick:ve},S.folders.map((function(t,e){return n.createElement(L,Pt({itemWidth:mt,index:e,key:e},t))}))),S.files&&S.files.length>0&&n.createElement("h2",{onClick:ve},g("文件")),S.files&&n.createElement("div",{onClick:ve},S.files.map((function(t,e){return n.createElement(L,Pt({icon:Jt(t.name)?"refresh":void 0,itemWidth:mt,index:e+S.folders.length,key:e},t))})))),n.createElement(B,null),Et&&n.createElement(yt,null),Ft.open&&n.createElement(Lt,null))}},8062:(t,e,r)=>{r.d(e,{A:()=>c});var n=r(6540);function o(){return o=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)({}).hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},o.apply(null,arguments)}function i(t){return n.createElement("div",{className:"black-tip",onClick:function(){t.click&&t.click(t)},onContextMenu:function(e){e.stopPropagation(),e.nativeEvent.stopImmediatePropagation(),t.onContextMenu&&t.onContextMenu(e,t)}},t.name)}var a=function(t){return n.createElement("li",null,t.click?n.createElement(i,o({},t.node,{name:t.render?t.render(t.node):t.node.name,click:t.click,onContextMenu:t.onContextMenu})):n.createElement("div",null,t.render?t.render(t.node):t.node.name),t.node.children&&t.node.children.length>0&&n.createElement("ul",null,t.node.children.map((function(e,r){return n.createElement(a,{key:r,node:e,click:t.click,onContextMenu:t.onContextMenu,render:t.render})}))))};const c=function(t){return n.createElement("div",{className:"card-tree-view"},n.createElement("ul",null,t.list&&t.list.map((function(e,r){return n.createElement(a,{key:r,node:e,click:t.click,onContextMenu:t.onContextMenu,render:t.render})}))))}}}]);
2
+ "use strict";(self.webpackChunkfilecat=self.webpackChunkfilecat||[]).push([[663],{3496:(t,e,r)=>{r.d(e,{s:()=>n});var n=function(t){return t.setting_sys_option_status_save="sys_option/status/save",t.setting_customer_router="customer_router",t.setting_customer_router_save="customer_router/save",t.setting_customer_workflow_router="customer_router/workflow",t.setting_customer_workflow_router_save="customer_router/workflow/save",t.user_save_user_file_list_show_type="save_user_file_list_show_type",t}({})},3663:(t,e,r)=>{r.r(e),r.d(e,{default:()=>Ut});var n=r(6540),o=r(7022),i=r(7444),a=r(6417),c=r(7767),u=r(4694),l=r(6007),s=r(4289),f=r(8844),h=r(7567),p=r(4251),d=r(2389),v=r(8247),m=r(9214);function y(t){return y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},y(t)}function w(){w=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof g?e:g,a=Object.create(i.prototype),c=new N(n||[]);return o(a,"_invoke",{value:j(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var h="suspendedStart",p="suspendedYield",d="executing",v="completed",m={};function g(){}function _(){}function b(){}var x={};l(x,a,(function(){return this}));var E=Object.getPrototypeOf,k=E&&E(E(C([])));k&&k!==r&&n.call(k,a)&&(x=k);var L=b.prototype=g.prototype=Object.create(x);function S(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function O(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==y(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function j(e,r,n){var o=h;return function(i,a){if(o===d)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=A(c,n);if(u){if(u===m)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?v:p,l.arg===m)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=v,n.method="throw",n.arg=l.arg)}}}function A(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,A(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,m;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function P(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function F(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function N(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(P,this),this.reset(!0)}function C(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(y(e)+" is not iterable")}return _.prototype=b,o(L,"constructor",{value:b,configurable:!0}),o(b,"constructor",{value:_,configurable:!0}),_.displayName=l(b,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===_||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,l(t,u,"GeneratorFunction")),t.prototype=Object.create(L),t},e.awrap=function(t){return{__await:t}},S(O.prototype),l(O.prototype,c,(function(){return this})),e.AsyncIterator=O,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new O(s(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},S(L),l(L,u,"Generator"),l(L,a,(function(){return this})),l(L,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=C,N.prototype={constructor:N,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(F),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!l)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),F(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;F(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:C(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function g(t){return function(t){if(Array.isArray(t))return k(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||E(t)||function(){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 _(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function b(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){_(i,n,o,a,c,"next",t)}function c(t){_(i,n,o,a,c,"throw",t)}a(void 0)}))}}function x(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,a,c=[],u=!0,l=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=i.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw o}}return c}}(t,e)||E(t,e)||function(){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 E(t,e){if(t){if("string"==typeof t)return k(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?k(t,e):void 0}}function k(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function L(t){var e=x((0,i.L4)(a.A.selectedFileList),2),r=e[0],y=e[1],_=x((0,i.L4)(a.A.clickFileList),2),E=_[0],k=_[1],L=x((0,i.L4)(a.A.nowFileList),2),S=L[0],O=L[1],j=x((0,i.L4)(a.A.confirm),2),A=(j[0],j[1]),P=x((0,i.L4)(a.A.enterKey),2),F=P[0],N=(P[1],(0,v.kZ)().click_file),C=((0,d.Bd)().t,(0,c.Zp)()),G=((0,c.zy)(),function(){var e=b(w().mark((function e(n,i){var a,c,l,f,h,p;return w().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(null!==(0,u.kW)(r,n))y((0,u.P1)(r,n));else if("ctrl"===F)y([].concat(g(r),[n]));else if("shift"===F){if(a=(0,u.a7)(r),c=a.max,l=a.min,f=[],n>=c)for(h=c;h<=n;h++)f.push(h);else for(p=l;p>=n;p--)f.push(p);y(f)}else y([n]);if(k([].concat(g(E),[n])),setTimeout((function(){k((0,u.P1)(E,n))}),300),t.type!==o.Iw.folder){e.next=14;break}if(void 0===E.find((function(t){return t===n}))){e.next=12;break}return C((0,u.IO)((0,s.vX)(),i)),y([]),k([]),O({files:[],folders:[]}),e.abrupt("return");case 12:e.next=16;break;case 14:void 0!==E.find((function(t){return t===n}))&&N({name:i,size:t.origin_size,opt_shell:!0});case 16:case"end":return e.stop()}}),e)})));return function(t,r){return e.apply(this,arguments)}}()),I=x((0,i.L4)(a.A.showPrompt),2),T=(I[0],I[1]),M=function(){var t=b(w().mark((function t(e){var n,o;return w().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=(0,m.i)(S,r),o=n.map((function(t){return(0,m.O)(t.name)})),t.next=4,l.$M.post("cut",{files:o,to:"".concat((0,s.GG)("file",(0,s.vX)()),"/").concat(e)});case 4:t.sent,y([]),A({open:!1,handle:null}),C((0,s.vX)());case 8:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();return n.createElement(f.B,{extraAttr:{onContextMenu:function(e){!function(t,e,r,n){t.preventDefault(),t.stopPropagation();var i=new p.i;i.path=(0,u.IO)((0,s.vX)(),e),i.filename=e,i.x=t.clientX,i.y=t.clientY,i.type=r?o.Iw.folder:(0,p.u)(e),i.size=n,T({show:!0,type:h.PromptEnum.FileMenu,overlay:!1,data:i})}(e,t.name,t.type===o.Iw.folder,t.origin_size)}},draggable_handle:M,name:t.name,index:t.index,mtime:t.mtime,size:t.size,type:t.type,isLink:t.isLink,path:t.path,icon:t.icon,click:G,itemWidth:t.itemWidth})}var S=r(4976),O=r(3033);function j(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,a,c=[],u=!0,l=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=i.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return A(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?A(t,e):void 0}}(t,e)||function(){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 A(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function P(t){var e=(0,c.zy)(),r=j((0,n.useState)([]),2),o=r[0],i=r[1],a=j((0,n.useState)("/"),2),l=a[0],f=a[1],h=j((0,n.useState)(void 0),2),p=h[0],d=h[1];n.useEffect((function(){var e="",r=(0,s.vX)().split("/");r=r.filter((function(t){return t}));var n=r.indexOf(t.baseRoute),o=[];if(-1!=n){e=(0,u.IO)(r.slice(0,n),t.baseRoute);for(var a=r.slice(n+1),c=0;c<a.length;c++){var l=a[c];o.push({value:l,href:0===c?"".concat(e).concat(l,"/"):(0,u.IO)(o[c-1].href,l)})}f(e),i(o)}}),[e]);var v=function(e){e.stopPropagation(),t.clickFun(e)};return n.createElement("div",{className:"breadcrumbs",onClick:function(t){d(void 0!==p?void 0:"")}},n.createElement(n.Fragment,null,void 0===p?n.createElement(n.Fragment,null,n.createElement("span",{className:"chevron"},n.createElement(S.N_,{to:l,onClick:v},n.createElement("i",{className:"material-icons"},"home"))),o.map((function(t,e){return n.createElement("span",{className:"chevron",key:e},n.createElement("i",{className:"material-icons"},"keyboard_arrow_right"),n.createElement(S.N_,{to:t.href,onClick:v},decodeURIComponent(t.value)))}))):n.createElement(O.Sm,{width:"100%",maxWidth:"60%",placeholder:"输入跳转的目录回车(点击空白处取消)",handlerEnter:function(e){t.input_path_enter&&t.input_path_enter(e),d(void 0)}})))}var F=r(5997),N=r(7952),C=r(5726),G=r(3459),I=r(7856),T=r(4238),M=r(4944),z=r(7704),W=r(4405),X=r(505);function K(t){return K="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},K(t)}function D(){D=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof y?e:y,a=Object.create(i.prototype),c=new P(n||[]);return o(a,"_invoke",{value:S(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var h="suspendedStart",p="suspendedYield",d="executing",v="completed",m={};function y(){}function w(){}function g(){}var _={};l(_,a,(function(){return this}));var b=Object.getPrototypeOf,x=b&&b(b(F([])));x&&x!==r&&n.call(x,a)&&(_=x);var E=g.prototype=y.prototype=Object.create(_);function k(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function L(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==K(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function S(e,r,n){var o=h;return function(i,a){if(o===d)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=O(c,n);if(u){if(u===m)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?v:p,l.arg===m)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=v,n.method="throw",n.arg=l.arg)}}}function O(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,O(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,m;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function j(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function A(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function P(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function F(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(K(e)+" is not iterable")}return w.prototype=g,o(E,"constructor",{value:g,configurable:!0}),o(g,"constructor",{value:w,configurable:!0}),w.displayName=l(g,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===w||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,l(t,u,"GeneratorFunction")),t.prototype=Object.create(E),t},e.awrap=function(t){return{__await:t}},k(L.prototype),l(L.prototype,c,(function(){return this})),e.AsyncIterator=L,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new L(s(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},k(E),l(E,u,"Generator"),l(E,a,(function(){return this})),l(E,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=F,P.prototype={constructor:P,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(A),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!l)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),A(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;A(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function H(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function Y(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){H(i,n,o,a,c,"next",t)}function c(t){H(i,n,o,a,c,"throw",t)}a(void 0)}))}}function U(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,a,c=[],u=!0,l=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=i.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw o}}return c}}(t,e)||function(t,e){if(t){if("string"==typeof t)return $(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?$(t,e):void 0}}(t,e)||function(){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 $(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function B(t){var e=U((0,n.useState)(null),2),r=e[0],o=e[1],c=U((0,i.L4)(a.A.fileShellShow),2),u=c[0],l=(c[1],U((0,i.L4)(a.A.file_shell_hidden),2)),s=l[0],f=(l[1],U((0,n.useState)(!1),2)),h=f[0],p=f[1],d=function(){var t=Y(D().mark((function t(){var e,r,n;return D().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e=new I.Terminal({fontFamily:"Monaco, Menlo, Consolas, 'Courier New', monospace",theme:{background:"#FFFFFF",foreground:"#000000",cursor:"#000000",selectionBackground:"#a6d2ff"},cursorBlink:!0,cursorStyle:"bar",scrollback:1e3,scrollSensitivity:1,tabStopWidth:4}),n=function(t){e.write(t)},r=function(t){e.clear(),e.write(t),r=n},M.ws.addMsg(T.HK.shell_getting,(function(t){r(t.context)})),M.ws.addMsg(T.HK.shell_copy,(function(t){t.context&&(0,X.l)(t.context),e.focus()})),e.onData(function(){var t=Y(D().mark((function t(e){var r;return D().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return(r=new T.hf(T.HK.shell_send)).context=e,t.next=4,M.ws.send(r);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()),o(e);case 7:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),v=function(){Y(D().mark((function t(){return D().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:r&&(r.dispose(),o(null)),M.ws.isAilive()&&M.ws.setPromise(function(){var t=Y(D().mark((function t(e){return D().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,M.ws.unConnect();case 2:e();case 3:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}());case 2:case"end":return t.stop()}}),t)})))()};return(0,n.useEffect)((function(){return function(){v()}}),[]),(0,n.useEffect)((function(){if(u.show)if(r){if(h){var t=new T.hf(T.HK.shell_cd),e=new W.n;e.init_path=u.path,e.http_token=localStorage.getItem("token"),t.context=e,M.ws.send(t)}}else d(),p(!0);else v()}),[u]),n.createElement(z.$,{show:u.show,file_shell_hidden:s,terminal:r,init:function(t,e){r.writeln("open shell... ");var n=new T.hf(T.HK.shell_open),o=new W.n;o.init_path=u.path,o.rows=t,o.cols=e,o.http_token=localStorage.getItem("token"),n.context=o,M.ws.send(n)}})}var q,R,Z=r(5725),J=r(2042),V=r(7523),Q=r(8815),tt=r(2730),et=r(447),rt=r(7481),nt=r(7071),ot=r(8062);function it(t){return it="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},it(t)}function at(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=ht(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}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 i,a=!0,c=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return a=t.done,t},e:function(t){c=!0,i=t},f:function(){try{a||null==r.return||r.return()}finally{if(c)throw i}}}}function ct(t){return function(t){if(Array.isArray(t))return pt(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||ht(t)||function(){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 ut(){ut=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof y?e:y,a=Object.create(i.prototype),c=new P(n||[]);return o(a,"_invoke",{value:S(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var h="suspendedStart",p="suspendedYield",d="executing",v="completed",m={};function y(){}function w(){}function g(){}var _={};l(_,a,(function(){return this}));var b=Object.getPrototypeOf,x=b&&b(b(F([])));x&&x!==r&&n.call(x,a)&&(_=x);var E=g.prototype=y.prototype=Object.create(_);function k(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function L(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==it(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function S(e,r,n){var o=h;return function(i,a){if(o===d)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=O(c,n);if(u){if(u===m)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?v:p,l.arg===m)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=v,n.method="throw",n.arg=l.arg)}}}function O(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,O(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,m;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function j(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function A(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function P(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function F(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(it(e)+" is not iterable")}return w.prototype=g,o(E,"constructor",{value:g,configurable:!0}),o(g,"constructor",{value:w,configurable:!0}),w.displayName=l(g,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===w||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,l(t,u,"GeneratorFunction")),t.prototype=Object.create(E),t},e.awrap=function(t){return{__await:t}},k(L.prototype),l(L.prototype,c,(function(){return this})),e.AsyncIterator=L,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new L(s(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},k(E),l(E,u,"Generator"),l(E,a,(function(){return this})),l(E,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=F,P.prototype={constructor:P,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(A),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!l)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),A(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;A(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function lt(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function st(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){lt(i,n,o,a,c,"next",t)}function c(t){lt(i,n,o,a,c,"throw",t)}a(void 0)}))}}function ft(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,a,c=[],u=!0,l=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=i.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw o}}return c}}(t,e)||ht(t,e)||function(){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 ht(t,e){if(t){if("string"==typeof t)return pt(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?pt(t,e):void 0}}function pt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}var dt,vt,mt=-1;function yt(t){var e=(0,d.Bd)().t,r=ft((0,i.L4)(a.A.workflow_show),2),o=(r[0],r[1]),c=ft((0,n.useState)([]),2),u=c[0],l=c[1],f=ft((0,n.useState)([]),2),h=f[0],p=f[1],v=ft((0,n.useState)(!1),2),m=v[0],y=v[1],w=ft((0,n.useState)(void 0),2),g=w[0],_=w[1],b=ft((0,n.useState)([]),2),x=b[0],E=b[1],k=ft((0,n.useState)(-1),2),L=k[0],S=k[1],j=ft((0,n.useState)(10),2),A=j[0],P=(j[1],ft((0,n.useState)(0),2)),C=(P[0],P[1]),G=ft((0,n.useState)(0),2),W=G[0],X=G[1],K=ft((0,n.useState)(""),2),D=K[0],H=K[1],Y=ft((0,n.useState)(!1),2),U=Y[0],$=Y[1],B=[e("序号"),e("运行名称"),e("状态"),e("运行时长"),e("日期"),e("操作")],V=[e("名称"),e("状态"),e("cwd"),e("运行时长"),e("操作")],tt=function(){var t=st(ut().mark((function t(e){var r,n,o;return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return(r=new nt._).page_num=null!=e?e:L,r.page_size=A,r.dir_path="".concat((0,s.GG)("file",(0,s.vX)())),t.next=6,M.ws.sendData(T.HK.workflow_get,r);case 6:if(n=t.sent){t.next=9;break}return t.abrupt("return");case 9:o=n.context,l(o.list.map((function(t){var e="string"==typeof t.meta?JSON.parse(t.meta):t.meta;return e.index=t.index,e}))),C(o.total),X((0,Q.gw)(o.total,A));case 13:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),it=function(){var t=st(ut().mark((function t(e){var r,n,o;return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return(r=new nt._).search_name=e,r.dir_path="".concat((0,s.GG)("file",(0,s.vX)())),$(!0),t.next=6,M.ws.sendData(T.HK.workflow_search_by_run_name,r);case 6:if(n=t.sent){t.next=9;break}return t.abrupt("return");case 9:o=n.context,l(o.list.map((function(t){var e="string"==typeof t.meta?JSON.parse(t.meta):t.meta;return e.index=t.index,e}))),C(o.total),X((0,Q.gw)(o.total,A)),S(0),$(!1);case 15:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),lt=function(){var t=st(ut().mark((function t(){var e;return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e=new I.Terminal({fontFamily:"Monaco, Menlo, Consolas, 'Courier New', monospace",theme:{background:"#FFFFFF",foreground:"#000000",cursor:"#000000",selectionBackground:"#a6d2ff"},cursorBlink:!0,cursorStyle:"bar",scrollback:1e3,scrollSensitivity:1,tabStopWidth:4,convertEol:!0}),R=e,_(e);case 3:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();(0,n.useEffect)((function(){return y(!1),q=void 0,R=void 0,mt=-1,tt(),st(ut().mark((function t(){return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:R&&(R.dispose(),R=null);case 1:case"end":return t.stop()}}),t)})))}),[]);var ht=function(){var t=st(ut().mark((function t(e){var r,n,o,i,a,c;return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!e.is_running){t.next=2;break}return t.abrupt("return");case 2:return E([]),(r=new nt._).index=e.index,r.dir_path="".concat((0,s.GG)("file",(0,s.vX)())),t.next=8,M.ws.sendData(T.HK.workflow_get,r);case 8:n=t.sent,o=n.context,i="string"==typeof o.one_data.data?JSON.parse(o.one_data.data):o.one_data.data,a=i.success_list,c=i.fail_list,p([].concat(ct(c),ct(a)));case 14:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),pt=function(t,e,r){if(e){var o,i=at(null!=e?e:[]);try{for(i.s();!(o=i.n()).done;){var a,c,u,l=o.value,s=void 0,f=[];l["use-yml"]?(pt(f,void 0,l.use_job_children_list),s="".concat(l["use-yml"]," ;").concat(null!==(c=l.duration)&&void 0!==c?c:-1)):s="".concat(l.run," ;").concat(null!==(u=l.duration)&&void 0!==u?u:-1),s=n.createElement("div",null,n.createElement(et.fq,{success:void 0===l.code?void 0:0===l.code}),"$",s),t.push({name:s,children:f,extra_data:{code:l.code,context:null!==(a=l.success_message)&&void 0!==a?a:l.fail_message}})}}catch(t){i.e(t)}finally{i.f()}}else if(r){var h,p=at(null!=r?r:[]);try{for(p.s();!(h=p.n()).done;){var d=h.value,v=n.createElement("div",null,n.createElement(et.fq,{success:void 0===d.code?void 0:0===d.code}),"$",d.name);t.push({name:v,extra_data:{code:d.code,is_job:!0,job_data:d}})}}catch(t){p.e(t)}finally{p.f()}}},dt=function(){var t=st(ut().mark((function t(e){var r,n;return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:r=e.steps,pt(n=[],null!=r?r:[]),E(n);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),vt=function(){var t=st(ut().mark((function t(e){return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(R){t.next=3;break}return t.next=3,new Promise((function(t){q=t,y(!0),lt()}));case 3:e&&(R.reset(),R.write(e));case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),yt=function(){var t=st(ut().mark((function t(e){var r,n,o;return ut().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(null==e||null===(r=e.extra_data)||void 0===r||!r.is_job){t.next=4;break}return t.next=3,dt(e.extra_data.job_data);case 3:return t.abrupt("return");case 4:if(null==e||null===(n=e.extra_data)||void 0===n||!n.context){t.next=8;break}vt(e.extra_data.context),t.next=11;break;case 8:if(null!=e&&e.extra_data.code){t.next=10;break}return t.abrupt("return");case 10:vt(null!==(o=e.extra_data.code)&&void 0!==o?o:"");case 11:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();return n.createElement("div",null,n.createElement(N.A,null,g&&n.createElement(F.rA,{icon:"print",title:"打印日志",onClick:function(){y(!m)}}),n.createElement(F.rA,{icon:"close",title:e("关闭"),onClick:function(){o(!1)}})),n.createElement(Z.jW,{isFull:!0,more:!0},n.createElement(Z.NN,null,n.createElement(Z.xh,null,n.createElement(Z.fI,null,n.createElement(Z.VP,null,n.createElement(et.uF,{self_title:n.createElement("span",{className:" div-row "},n.createElement("h2",null,e("历史记录"))),titleCom:n.createElement("div",{className:" div-row "},n.createElement(O.Sm,{disabled:U,value:D,placeholder:"搜索运行名称(支持正则)",handleInputChange:function(t){H(D)},handlerEnter:function(t){it(t)}})),rightBottomCom:n.createElement("span",{className:" div-row "},n.createElement("span",null,Math.abs(L),"/",W),n.createElement(O.Sm,{placeholder:"max page ".concat(W),handleInputChange:function(t){mt=parseInt(t)},handlerEnter:function(){if(mt<1||mt>W)(0,J.zN)("illegal page num");else{var t=0-mt;S(t),tt(t)}}}),n.createElement(F.rA,{icon:"navigate_before",onClick:function(){var t=L+1;t>-1?(0,J.zN)("max page num"):(S(t),tt(t))},title:"上一页"}),n.createElement(F.rA,{icon:"navigate_next",onClick:function(){var t=L-1;Math.abs(t)>W?(0,J.zN)("min page num"):(S(t),tt(t))},title:"下一页"}))},n.createElement(rt.X,{headers:B,rows:u.map((function(t,r){var o;return o=t.is_running?n.createElement("div",null,n.createElement(et.fq,null),e("正在运行")):n.createElement("div",null,n.createElement(et.fq,{success:t.is_success}),t.is_success?e("成功"):e("失败")),[n.createElement("p",null,t.index),n.createElement("p",{style:{wordWrap:"break-word"}},t["run-name"]),o,n.createElement("span",null,t.duration),n.createElement("span",null,t.timestamp),n.createElement("div",null,n.createElement(F.rA,{icon:"details",title:e("详情"),onClick:function(){ht(t)}}))]})),width:"10rem"}))),n.createElement(Z.VP,null,n.createElement(et.Zp,{title:e("Job")},n.createElement(rt.X,{headers:V,rows:h.map((function(t,r){return[n.createElement("p",null,t.name),n.createElement("div",null,n.createElement(et.fq,{success:void 0===t.code?void 0:0===t.code}),0===t.code?e("成功"):e("失败")),n.createElement(et.xP,null,t.cwd),n.createElement("span",null,t.duration),n.createElement("div",null,n.createElement(F.rA,{icon:"details",title:e("详情"),onClick:function(){dt(t)}}),(!!t.success_message||!!t.fail_message)&&n.createElement(F.rA,{icon:"print",title:e("日志"),onClick:function(){var e;vt(null!==(e=t.success_message)&&void 0!==e?e:t.fail_message)}}))]})),width:"10rem"})),n.createElement(et.Zp,{title:"Step"},n.createElement(ot.A,{list:x,click:function(t){yt(t)}}))))))),n.createElement("div",{style:{display:m?"":"none"}},n.createElement(z.$,{show:!0,terminal:g,init:function(){q&&(q(1),q=void 0)}})))}function wt(t){return wt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},wt(t)}function gt(){gt=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof y?e:y,a=Object.create(i.prototype),c=new P(n||[]);return o(a,"_invoke",{value:S(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var h="suspendedStart",p="suspendedYield",d="executing",v="completed",m={};function y(){}function w(){}function g(){}var _={};l(_,a,(function(){return this}));var b=Object.getPrototypeOf,x=b&&b(b(F([])));x&&x!==r&&n.call(x,a)&&(_=x);var E=g.prototype=y.prototype=Object.create(_);function k(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function L(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==wt(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function S(e,r,n){var o=h;return function(i,a){if(o===d)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=O(c,n);if(u){if(u===m)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?v:p,l.arg===m)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=v,n.method="throw",n.arg=l.arg)}}}function O(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,O(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,m;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function j(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function A(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function P(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function F(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(wt(e)+" is not iterable")}return w.prototype=g,o(E,"constructor",{value:g,configurable:!0}),o(g,"constructor",{value:w,configurable:!0}),w.displayName=l(g,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===w||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,l(t,u,"GeneratorFunction")),t.prototype=Object.create(E),t},e.awrap=function(t){return{__await:t}},k(L.prototype),l(L.prototype,c,(function(){return this})),e.AsyncIterator=L,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new L(s(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},k(E),l(E,u,"Generator"),l(E,a,(function(){return this})),l(E,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=F,P.prototype={constructor:P,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(A),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!l)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),A(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;A(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function _t(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function bt(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){_t(i,n,o,a,c,"next",t)}function c(t){_t(i,n,o,a,c,"throw",t)}a(void 0)}))}}function xt(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,a,c=[],u=!0,l=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=i.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw o}}return c}}(t,e)||Et(t,e)||function(){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 Et(t,e){if(t){if("string"==typeof t)return kt(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?kt(t,e):void 0}}function kt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function Lt(t){var e=(0,d.Bd)().t,r=xt((0,i.L4)(a.A.workflow_realtime_show),2),o=r[0],c=r[1],u=xt((0,n.useState)([]),2),l=(u[0],u[1],xt((0,n.useState)([]),2)),f=(l[0],l[1],xt((0,n.useState)(!1),2)),h=f[0],p=f[1],v=xt((0,n.useState)(void 0),2),m=v[0],y=v[1],w=xt((0,n.useState)([]),2),g=w[0],_=w[1],b=function(t){var e,r=function(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=Et(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}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 i,a=!0,c=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return a=t.done,t},e:function(t){c=!0,i=t},f:function(){try{a||null==r.return||r.return()}finally{if(c)throw i}}}}(t);try{for(r.s();!(e=r.n()).done;){var o,i,a,c=e.value;(null==c||null===(o=c.extra_data)||void 0===o?void 0:o.running_type)===nt.rl.success?c.name=n.createElement("div",null,n.createElement(et.fq,{success:!0}),c.name):(null==c||null===(i=c.extra_data)||void 0===i?void 0:i.running_type)===nt.rl.fail?c.name=n.createElement("div",null,n.createElement(et.fq,{success:!1}),c.name):(null==c||null===(a=c.extra_data)||void 0===a?void 0:a.running_type)===nt.rl.running&&(c.name=n.createElement("div",null,n.createElement(et.fq,{running:!0}),c.name)),c.children&&b(c.children)}}catch(t){r.e(t)}finally{r.f()}},x=function(){var t=bt(gt().mark((function t(e){var r;return gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:(r=new nt.v3).filename_path="".concat((0,s.GG)("file",(0,s.vX)())).concat(o.filename),M.ws.addMsg(T.HK.workflow_realtime_one_rsq,(function(t){if(t.context.list&&t.context.list.length>0){var e=t.context.list;b(e),_(e)}t.context.new_log&&k(t.context.new_log)})),M.ws.sendData(T.HK.workflow_realtime_one_req,r);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),E=function(){var t=bt(gt().mark((function t(){var e;return gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e=new I.Terminal({fontFamily:"Monaco, Menlo, Consolas, 'Courier New', monospace",theme:{background:"#FFFFFF",foreground:"#000000",cursor:"#000000",selectionBackground:"#a6d2ff"},cursorBlink:!0,cursorStyle:"bar",scrollback:1e3,scrollSensitivity:1,tabStopWidth:4,convertEol:!0}),vt=e,y(e);case 3:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();(0,n.useEffect)((function(){return p(!1),dt=void 0,vt=void 0,x(),bt(gt().mark((function t(){return gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:M.ws.removeMsg(T.HK.workflow_realtime_one_rsq),vt&&(vt.dispose(),vt=null);case 2:case"end":return t.stop()}}),t)})))}),[]);var k=function(){var t=bt(gt().mark((function t(e){return gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(vt){t.next=3;break}return t.next=3,new Promise((function(t){dt=t,p(!0),E()}));case 3:e&&vt.write(e);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();return n.createElement("div",null,n.createElement(N.A,null,m&&n.createElement(F.rA,{icon:"print",title:"打印日志",onClick:function(){p(!h)}}),n.createElement(F.rA,{icon:"close",title:e("关闭"),onClick:function(){c({open:!1})}})),n.createElement(Z.jW,{isFull:!0,more:!0},n.createElement(Z.NN,null,n.createElement(ot.A,{list:g,click:function(t){}}))),n.createElement("div",{style:{display:h?"":"none"}},n.createElement(z.$,{show:!0,terminal:m,init:function(){dt&&(dt(1),dt=void 0)}})))}var St=r(3430),Ot=r(2458),jt=r(3496);function At(t){return At="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},At(t)}function Pt(){return Pt=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)({}).hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},Pt.apply(null,arguments)}function Ft(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Nt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Ft(Object(r),!0).forEach((function(e){Ct(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Ft(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Ct(t,e,r){return(e=function(t){var e=function(t){if("object"!=At(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!=At(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==At(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Gt(){Gt=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function l(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{l({},"")}catch(t){l=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var i=e&&e.prototype instanceof y?e:y,a=Object.create(i.prototype),c=new P(n||[]);return o(a,"_invoke",{value:S(t,r,c)}),a}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=s;var h="suspendedStart",p="suspendedYield",d="executing",v="completed",m={};function y(){}function w(){}function g(){}var _={};l(_,a,(function(){return this}));var b=Object.getPrototypeOf,x=b&&b(b(F([])));x&&x!==r&&n.call(x,a)&&(_=x);var E=g.prototype=y.prototype=Object.create(_);function k(t){["next","throw","return"].forEach((function(e){l(t,e,(function(t){return this._invoke(e,t)}))}))}function L(t,e){function r(o,i,a,c){var u=f(t[o],t,i);if("throw"!==u.type){var l=u.arg,s=l.value;return s&&"object"==At(s)&&n.call(s,"__await")?e.resolve(s.__await).then((function(t){r("next",t,a,c)}),(function(t){r("throw",t,a,c)})):e.resolve(s).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,c)}))}c(u.arg)}var i;o(this,"_invoke",{value:function(t,n){function o(){return new e((function(e,o){r(t,n,e,o)}))}return i=i?i.then(o,o):o()}})}function S(e,r,n){var o=h;return function(i,a){if(o===d)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:t,done:!0}}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=O(c,n);if(u){if(u===m)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var l=f(e,r,n);if("normal"===l.type){if(o=n.done?v:p,l.arg===m)continue;return{value:l.arg,done:n.done}}"throw"===l.type&&(o=v,n.method="throw",n.arg=l.arg)}}}function O(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,O(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),m;var i=f(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,m;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,m):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,m)}function j(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function A(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function P(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(j,this),this.reset(!0)}function F(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return i.next=i}}throw new TypeError(At(e)+" is not iterable")}return w.prototype=g,o(E,"constructor",{value:g,configurable:!0}),o(g,"constructor",{value:w,configurable:!0}),w.displayName=l(g,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===w||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,l(t,u,"GeneratorFunction")),t.prototype=Object.create(E),t},e.awrap=function(t){return{__await:t}},k(L.prototype),l(L.prototype,c,(function(){return this})),e.AsyncIterator=L,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new L(s(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},k(E),l(E,u,"Generator"),l(E,a,(function(){return this})),l(E,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=F,P.prototype={constructor:P,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(A),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],c=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),l=n.call(a,"finallyLoc");if(u&&l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!l)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,m):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),A(r),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;A(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),m}},e}function It(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=Wt(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}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 i,a=!0,c=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return a=t.done,t},e:function(t){c=!0,i=t},f:function(){try{a||null==r.return||r.return()}finally{if(c)throw i}}}}function Tt(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function Mt(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){Tt(i,n,o,a,c,"next",t)}function c(t){Tt(i,n,o,a,c,"throw",t)}a(void 0)}))}}function zt(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,i,a,c=[],u=!0,l=!1;try{if(i=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;u=!1}else for(;!(u=(n=i.call(r)).done)&&(c.push(n.value),c.length!==e);u=!0);}catch(t){l=!0,o=t}finally{try{if(!u&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(l)throw o}}return c}}(t,e)||Wt(t,e)||function(){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 Wt(t,e){if(t){if("string"==typeof t)return Xt(t,e);var r={}.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Xt(t,e):void 0}}function Xt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}var Kt,Dt=Object.values(St.UG),Ht=280,Yt={};function Ut(){var t,e,r=zt((0,i.L4)(a.A.editorSetting),2),f=(r[0],r[1]),y=zt((0,i.L4)(a.A.file_preview),2),w=(y[0],y[1]),g=(0,d.Bd)().t,_=(0,n.useRef)(null),b=(0,c.zy)(),x=(0,c.Zp)(),E=(0,v.MH)().check_user_auth,k=zt((0,i.L4)(a.A.nowFileList),2),S=k[0],j=k[1],A=zt((0,i.L4)(a.A.uploadFiles),2),I=(A[0],A[1]),z=zt((0,i.L4)(a.A.showPrompt),2),W=(z[0],z[1]),X=zt((0,i.L4)(a.A.selectedFileList),2),K=X[0],D=(X[1],zt((0,i.L4)(a.A.copyedFileList),2)),H=D[0],Y=D[1],U=zt((0,i.L4)(a.A.enterKey),2),$=(U[0],U[1]),q=zt((0,i.L4)(a.A.cutedFileList),2),R=q[0],rt=q[1],ot=zt((0,i.L4)(a.A.selectedFileList),2),it=(ot[0],ot[1]),at=zt((0,i.L4)(a.A.clickFileList),2),ct=(at[0],at[1]),ut=zt((0,i.L4)(a.A.fileShellShow),2),lt=ut[0],st=ut[1],ft=zt((0,i.L4)(a.A.file_root_list),2),ht=ft[0],pt=(ft[1],zt((0,i.L4)(a.A.file_root_index),2)),dt=(pt[0],pt[1]),vt=zt((0,n.useState)(void 0),2),mt=vt[0],wt=vt[1],gt=zt((0,n.useState)(""),2),_t=gt[0],bt=gt[1],xt=zt((0,i.L4)(a.A.workflow_show),2),Et=xt[0],kt=xt[1],At=zt((0,i.L4)(a.A.workflow_realtime_show),2),Ft=At[0],Ct=(At[1],zt((0,n.useState)(!1),2)),Tt=Ct[0],Wt=Ct[1],Xt=(0,n.useContext)(V.F).reloadUserInfo,Ut=(0,n.useContext)(V.F).initUserInfo,$t=zt((0,i.L4)(a.A.user_base_info),2),Bt=$t[0],qt=($t[1],(0,v.kZ)().click_file),Rt=zt((0,i.L4)(a.A.prompt_card),2),Zt=(Rt[0],Rt[1]),Jt=(0,v.hg)().file_is_running,Vt=zt((0,i.L4)(a.A.to_running_files),2),Qt=(Vt[0],Vt[1]),te=zt((0,i.L4)(a.A.router_jump),2),ee=(te[0],te[1]),re=function(){var t=Mt(Gt().mark((function t(){var e;return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return(e=new nt.Nd).dir_path="".concat((0,s.GG)("file",(0,s.vX)())),M.ws.addMsg(T.HK.workflow_realtime,(function(t){var e,r=t.context,n=It(r.sucess_file_list);try{for(n.s();!(e=n.n()).done;){var o=e.value;o.endsWith(".workflow.yml")?(0,J.LW)("".concat(o.slice(0,-13)," done!")):o.endsWith(".act")&&(0,J.LW)("".concat(o.slice(0,-4)," done!"))}}catch(t){n.e(t)}finally{n.f()}var i,a=It(r.failed_file_list);try{for(a.s();!(i=a.n()).done;){var c=i.value;c.endsWith(".workflow.yml")?(0,J.zN)("".concat(c.slice(0,-13)," failed!")):c.endsWith(".act")&&(0,J.zN)("".concat(c.slice(0,-4)," failed!"))}}catch(t){a.e(t)}finally{a.f()}Qt(new Set(r.running_file_list))})),t.next=5,M.ws.sendData(T.HK.workflow_realtime,e);case 5:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),ne=function(){var t=Mt(Gt().mark((function t(e){var r,n,o,i,a,c,f,h,p,d,v,m,y;return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e=e?encodeURIComponent(e)+"?is_sys_path=1":encodeURIComponent((0,s.GG)("file",(0,s.vX)())),t.next=3,l.$M.get(e);case 3:if((o=t.sent).code!==G.m.PreFile){t.next=7;break}return qt({name:o.message,context:o.data,opt_shell:!0}),t.abrupt("return");case 7:if(o.code===G.m.Sucess){t.next=10;break}return o.message&&(0,J.zN)(o.message),t.abrupt("return");case 10:i=o.data,t.t0=Bt.user_data.dir_show_type,t.next=t.t0===St.t8.size_max_min||t.t0===St.t8.size_min_max?14:t.t0===St.t8.time_minx_max||t.t0===St.t8.time_max_min?18:t.t0===St.t8.name?22:24;break;case 14:return a=Bt.user_data.dir_show_type===St.t8.size_min_max,(0,u.di)(i.files,(function(t){return t.size}),a),(0,u.di)(i.folders,(function(t){return t.size}),a),t.abrupt("break",25);case 18:return c=Bt.user_data.dir_show_type===St.t8.time_minx_max,(0,u.di)(i.files,(function(t){return t.mtime}),c),(0,u.di)(i.folders,(function(t){return t.mtime}),c),t.abrupt("break",25);case 22:return(0,u.di)(i.folders,(function(t){return t.name})),t.abrupt("break",25);case 24:return t.abrupt("break",25);case 25:f=!1,h=It(null!==(r=i.files)&&void 0!==r?r:[]);try{for(h.s();!(p=h.n()).done;)(d=p.value).mtime=d.mtime?(0,Q.s8)(d.mtime):"",d.origin_size=d.size,d.size=(0,Q.v7)(d.size),(!f&&d.name.endsWith(".workflow.yml")||d.name.endsWith(".act"))&&(f=!0,Promise.resolve().then((function(){re()})))}catch(t){h.e(t)}finally{h.f()}if(void 0===i.relative_user_path){t.next=32;break}return(i.relative_user_path.startsWith("\\")||i.relative_user_path.startsWith("/"))&&(i.relative_user_path=i.relative_user_path.slice(1)),x(i.relative_user_path),t.abrupt("return");case 32:f=!1,v=It(null!==(n=i.folders)&&void 0!==n?n:[]);try{for(v.s();!(m=v.n()).done;)(y=m.value).mtime=y.mtime?(0,Q.s8)(y.mtime):"",f||y.name!==nt.SB||(Wt(!0),f=!0)}catch(t){v.e(t)}finally{v.f()}j(o.data),Kt=o.data;case 37:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),oe=function(){var t=Math.floor(document.querySelector("main").offsetWidth/Ht);0===t&&(t=1),wt("calc(".concat(100/t,"% - 1em)"))};(0,n.useEffect)((function(){var t=function(){var t=Mt(Gt().mark((function t(){return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ne();case 2:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();t(),f({open:!1}),w({open:!1}),Wt(!1),Yt={}}),[b]),(0,n.useEffect)((function(){return Mt(Gt().mark((function t(){return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:Qt(new Set);case 1:case"end":return t.stop()}}),t)})))}),[]);var ie=function(){var t=Mt(Gt().mark((function t(e){var r,n,o,i;return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(e.preventDefault(),e.stopPropagation(),r=e.dataTransfer,n=e.target,!(r.files.length<=0)){t.next=6;break}return t.abrupt("return");case 6:for(o=0;o<5;o++)null===n||n.classList.contains("item")||(n=n.parentElement);return t.next=9,(0,C.T)(r);case 9:i=t.sent,I(i),W({show:!0,type:h.PromptEnum.FilesUpload,overlay:!1,data:{}});case 12:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),ae=function(t){t.preventDefault()};function ce(){return(ce=Mt(Gt().mark((function t(){var e,r,n;return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=(0,u.jH)(Dt,null!==(e=null==Bt||null===(r=Bt.user_data)||void 0===r?void 0:r.file_list_show_type)&&void 0!==e?e:""),t.next=3,l.wm.post(jt.s.user_save_user_file_list_show_type,{type:n});case 3:Ut();case 4:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function ue(t){(0,J.LW)(t)}(0,n.useEffect)((function(){var t=_.current.ownerDocument;return t.addEventListener("dragover",ae),t.addEventListener("drop",ie),oe(),window.addEventListener("resize",oe),function(){t.removeEventListener("dragover",ae),t.removeEventListener("drop",ie),window.removeEventListener("resize",oe),lt.show&&st({show:!1,path:""})}}),[]);var le=function(){var t=Mt(Gt().mark((function t(e){return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return dt(e),t.next=3,l.$M.post("base_switch",{root_index:e});case 3:return t.next=5,Xt();case 5:x("/file/"),it([]),ct([]);case 8:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),se=function(t){Zt({open:!0,title:"信息",context_div:n.createElement("div",{style:{maxWidth:"25rem"}},n.createElement(Z.Yh,{left:g("挂载位置磁盘"),right:null==t?void 0:t.total_size}),n.createElement(Z.Yh,{left:"".concat(g("磁盘剩余")),right:null==t?void 0:t.left_size}),n.createElement(Z.Yh,{left:"".concat(g("文件系统")),right:null==t?void 0:t.fs_type}),n.createElement(Z.Yh,{left:"".concat(g("文件夹数")),right:S.folders.length}),n.createElement(Z.Yh,{left:"".concat(g("文件数")),right:S.files.length}),n.createElement(Z.Yh,{left:"".concat(g("当前位置")),right:n.createElement(et.xP,{context:null==t?void 0:t.now_absolute_path})})),cancel:function(){M.ws.removeMsg(T.HK.file_info)}})},fe=function(){var t=Mt(Gt().mark((function t(){var e,r;return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(Yt.now_absolute_path){t.next=8;break}return M.ws.addMsg(T.HK.file_info,(function(t){var r=t.context;e&&(Yt=Nt(Nt({},Yt),r),M.ws.removeMsg(T.HK.file_info),se(Yt))})),t.next=4,M.ws.sendData(T.HK.file_info,{type:o.Iw.folder,path:(0,s.GG)("file",(0,s.vX)())});case 4:r=t.sent,e=r.context,se(Yt=e);case 8:se(Yt);case 9:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),he=zt((0,n.useState)(!1),2),pe=he[0],de=he[1];(0,n.useEffect)((function(){var t=function(t){if(pe)if(t.ctrlKey)if("a"===t.key||"A"===t.key){for(var e=S.files.length,r=S.folders.length,n=[],o=0;o<e+r;o++)n.push(o);it(n)}else $("ctrl");else"Escape"===t.key?it([]):"Shift"===t.key&&$("shift")},e=function(t){t.ctrlKey||$("")};return window.addEventListener("keydown",t),window.addEventListener("keyup",e),function(){window.removeEventListener("keydown",t),window.removeEventListener("keyup",e)}}),[S,pe]);var ve=function(t){t.target===t.currentTarget&&it([])};return n.createElement("div",{className:"not-select-div"},n.createElement(N.A,{left_children:n.createElement(O.$Z,{handleEnterPress:function(){var t,e;if(Kt){it([]),ct([]);var r,n=[],o=[],i=It(null!==(t=Kt.files)&&void 0!==t?t:[]);try{for(i.s();!(r=i.n()).done;){var a=r.value;a.name.includes(_t)&&n.push(a)}}catch(t){i.e(t)}finally{i.f()}var c,u=It(null!==(e=Kt.folders)&&void 0!==e?e:[]);try{for(u.s();!(c=u.n()).done;){var l=c.value;l.name.includes(_t)&&o.push(l)}}catch(t){u.e(t)}finally{u.f()}j({files:n,folders:o})}},placeholder:g("搜索当前目录"),icon:"search",value:"",handleInputChange:function(t){bt(t)},max_width:"25em"})},K.length>0&&n.createElement(F.rA,{icon:"delete",title:g("删除"),onClick:function(){W({show:!0,type:h.PromptEnum.FilesDelete,overlay:!0,data:{}})}}),K.length>0&&n.createElement(F.rA,{icon:"content_copy",title:g("复制"),onClick:function(){var t=(0,m.i)(S,K);Y(t.map((function(t){return(0,m.O)(t.name)}))),rt([]),ue("已复制")}}),K.length>0&&n.createElement(F.rA,{icon:"content_cut",title:g("剪切"),onClick:function(){var t=(0,m.i)(S,K);rt(t.map((function(t){return(0,m.O)(t.name)}))),Y([]),ue("已剪切")}}),(H.length>0||R.length>0)&&n.createElement(F.rA,{onClick:function(){W({show:!0,type:h.PromptEnum.Confirm,overlay:!0,data:{}})},icon:"content_paste",title:g("粘贴到此处"),tip:H.length+R.length}),K.length>0&&n.createElement(F.rA,{icon:"download",title:g("下载"),onClick:function(){for(var t=(0,m.i)(S,K),e=0;e<t.length;e++){var r=t[e];t[e]=encodeURIComponent((0,m.O)(r.name))}var n=l.$M.getDownloadUrl(t);window.open(n)}}),K.length>0&&n.createElement(F.rA,{icon:"compress",title:g("压缩"),onClick:function(){for(var t=(0,m.i)(S,K),e=0;e<t.length;e++){var r=t[e];t[e]=(0,m.O)(r.name)}t&&0!==t.length?W({show:!0,type:h.PromptEnum.Compress,overlay:!0,data:{files:t}}):(0,J.zN)("没有选中")}}),1===K.length&&n.createElement(F.rA,{icon:"edit_attributes",title:g("重命名"),onClick:function(){W({show:!0,type:h.PromptEnum.FileRename,overlay:!0,data:{}})}}),Tt&&n.createElement(F.rA,{icon:"api",title:"workflow",onClick:function(){kt(!Et)}}),n.createElement(F.rA,{icon:"terminal",title:"shell",onClick:function(){lt.show?st({show:!1,path:""}):st({show:!0,path:(0,s.GG)("file",(0,s.vX)())})}}),n.createElement(F.rA,{icon:"grid_view",title:g("切换样式"),onClick:function(){return ce.apply(this,arguments)}}),n.createElement(F.rA,{icon:"create_new_folder",title:g("创建文件夹"),onClick:function(){W({show:!0,type:h.PromptEnum.DirNew,overlay:!0,data:{dir:(0,s.GG)("file",(0,s.vX)())}})}}),n.createElement(F.rA,{icon:"note_add",title:g("创建文本文件"),onClick:function(){W({show:!0,type:h.PromptEnum.FileNew,overlay:!0,data:{dir:(0,s.GG)("file",(0,s.vX)())}})}}),n.createElement(F.rA,{icon:"upload_file",title:"上传",onClick:function(){W({show:!0,type:h.PromptEnum.UploadFile,overlay:!0,data:{call:function(t){var e,r=null===(e=t.currentTarget)||void 0===e?void 0:e.files;if(r){for(var n=!!r[0].webkitRelativePath,o=[],i=new Set,a=0;a<r.length;a++){var c=r[a],u=n?c.webkitRelativePath:"".concat(c.webkitRelativePath).concat(c.name);c.fullPath=u,n&&i.add((0,tt.S)(u)),o.push(c)}var l=[];if(n){var s,f=It(i);try{for(f.s();!(s=f.n()).done;){var p=s.value;l.push({isDir:!0,fullPath:p,name:p})}}catch(t){f.e(t)}finally{f.f()}}l.push.apply(l,o),I(l),W({show:!0,type:h.PromptEnum.FilesUpload,overlay:!1,data:{}})}}}})}}),n.createElement(F.rA,{icon:"info",title:g("信息"),onClick:fe}),n.createElement(F.rA,{icon:"more_vert",title:g("切换目录"),onClick:function(t){var e=new p.i;e.x=t.clientX,e.y=t.clientY,e.type=o.Iw.directory,e.items=ht,e.textClick=function(){var t=Mt(Gt().mark((function t(e){return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:le(e),W({data:void 0,overlay:!1,type:"",show:!1});case 2:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),W({show:!0,type:h.PromptEnum.FileMenu,overlay:!1,data:e})}})),n.createElement(P,{baseRoute:"file",clickFun:function(){it([]),ct([])},input_path_enter:function(t){(0,Ot.Z1)(t)?ne(t):x((0,Ot.Jn)((0,s.vX)(),t)),it([]),ct([]),j({files:[],folders:[]})}}),n.createElement("div",{onContextMenu:function(t){t.preventDefault(),t.stopPropagation();var e=new p.i;e.x=t.clientX,e.y=t.clientY,e.type=o.Iw.directory;var r=[{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.time_minx_max?"green":void 0}},"时间顺序"),v:St.t8.time_minx_max},{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.time_max_min?"green":void 0}},"时间逆序"),v:St.t8.time_max_min}],i=[{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.size_min_max?"green":void 0}},"大小顺序"),v:St.t8.size_min_max},{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.size_max_min?"green":void 0}},"大小逆序"),v:St.t8.size_max_min}],a=[{r:"文件排序",v:"",items:[{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type?void 0:"green"}},"系统默认"),v:St.t8.defualt},{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.name?"green":void 0}},"名字"),v:St.t8.name},{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.time_minx_max||Bt.user_data.dir_show_type===St.t8.time_max_min?"green":void 0}},"修改时间"),v:!1,items:r},{r:n.createElement("span",{style:{color:Bt.user_data.dir_show_type===St.t8.size_min_max||Bt.user_data.dir_show_type===St.t8.size_max_min?"green":void 0}},"文件大小"),v:!1,items:i}]}];E(St.oV.code_resource)&&a.push({r:"添加http资源根目录",v:"code_resource"}),E(St.oV.http_proxy)&&a.push({r:"在此目录下载http资源",v:"http_resource"}),e.items=a,e.textClick=function(){var t=Mt(Gt().mark((function t(e){var r,n;return Gt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!1!==e){t.next=2;break}return t.abrupt("return");case 2:if("code_resource"!==e){t.next=12;break}return t.next=5,M.ws.sendData(T.HK.file_info,{path:(0,s.GG)("file",(0,s.vX)())});case 5:return r=t.sent,ee({page_self_router_api_data:["",r.context.now_absolute_path]}),W({data:void 0,overlay:!1,type:"",show:!1}),x("/setting/customer_router/"),t.abrupt("return");case 12:if("http_resource"!==e){t.next=20;break}return t.next=15,M.ws.sendData(T.HK.file_info,{path:(0,s.GG)("file",(0,s.vX)())});case 15:return n=t.sent,ee({http_download_map_path:n.context.now_absolute_path}),W({data:void 0,overlay:!1,type:"",show:!1}),x("/toolbox/http/"),t.abrupt("return");case 20:return t.next=22,l.wm.post(jt.s.user_save_user_file_list_show_type,{type:e,is_dir_list_type:!0});case 22:return t.next=24,Ut();case 24:W({data:void 0,overlay:!1,type:"",show:!1}),x((0,s.vX)());case 26:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),W({show:!0,type:h.PromptEnum.FileMenu,overlay:!1,data:e})},id:"listing",style:{paddingBottom:"10rem"},className:"mosaic file-icons ".concat(null!==(t=null==Bt||null===(e=Bt.user_data)||void 0===e?void 0:e.file_list_show_type)&&void 0!==t?t:""),ref:_,onMouseEnter:function(){de(!0)},onMouseLeave:function(){de(!1)}},S.folders&&S.folders.length>0&&n.createElement("h2",null,g("文件夹")),S.folders&&n.createElement("div",{onClick:ve},S.folders.map((function(t,e){return n.createElement(L,Pt({itemWidth:mt,index:e,key:e},t))}))),S.files&&S.files.length>0&&n.createElement("h2",{onClick:ve},g("文件")),S.files&&n.createElement("div",{onClick:ve},S.files.map((function(t,e){return n.createElement(L,Pt({icon:Jt(t.name)?"refresh":void 0,itemWidth:mt,index:e+S.folders.length,key:e},t))})))),n.createElement(B,null),Et&&n.createElement(yt,null),Ft.open&&n.createElement(Lt,null))}},8062:(t,e,r)=>{r.d(e,{A:()=>c});var n=r(6540);function o(){return o=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)({}).hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},o.apply(null,arguments)}function i(t){return n.createElement("div",{className:"black-tip",onClick:function(){t.click&&t.click(t)},onContextMenu:function(e){e.stopPropagation(),e.nativeEvent.stopImmediatePropagation(),t.onContextMenu&&t.onContextMenu(e,t)}},t.name)}var a=function(t){return n.createElement("li",null,t.click?n.createElement(i,o({},t.node,{name:t.render?t.render(t.node):t.node.name,click:t.click,onContextMenu:t.onContextMenu})):n.createElement("div",null,t.render?t.render(t.node):t.node.name),t.node.children&&t.node.children.length>0&&n.createElement("ul",null,t.node.children.map((function(e,r){return n.createElement(a,{key:r,node:e,click:t.click,onContextMenu:t.onContextMenu,render:t.render})}))))};const c=function(t){return n.createElement("div",{className:"card-tree-view"},n.createElement("ul",null,t.list&&t.list.map((function(e,r){return n.createElement(a,{key:r,node:e,click:t.click,onContextMenu:t.onContextMenu,render:t.render})}))))}}}]);