← Back
Editing: feature-FileEditor-legacy.js
(function(){System.register([`./rolldown-runtime-legacy.js?v=1795169270504`,`./vendor-utils-legacy.js?v=1795169270504`,`./vendor-vue-legacy.js?v=1795169270504`,`./vendor-naive-legacy.js?v=1795169270504`,`./app-legacy.js?v=1795169270504`,`./app-components-legacy.js?v=1795169270504`,`./app-shared-legacy.js?v=1795169270504`,`./vendor-pdf-legacy.js?v=1795169270504`,`./app-base-legacy.js?v=1795169270504`,`./vendor-ace-legacy.js?v=1795169270504`,`./feature-EmailEditor-legacy.js?v=1795169270504`],function(e,t){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,C,w,T,ee,E,te,ne,re,ie,D,ae,oe,se,ce,le,ue,de,fe,pe,me,he,ge,_e,O,ve,ye,be,xe,Se,Ce,we,Te,Ee,De,Oe,ke,Ae,je,Me,Ne,Pe,Fe,Ie,Le,Re,ze,Be,Ve,He,Ue,We,Ge,Ke,qe,Je,Ye,Xe,Ze,Qe,$e,et,tt,nt,rt,it,at,ot,st,ct,lt,ut,dt,ft,pt,mt,ht,gt,_t,vt,yt,bt,xt,St,Ct,wt,Tt,Et,Dt,Ot,kt,At,jt,Mt,Nt,Pt,Ft,It,Lt,Rt,zt,Bt,Vt,Ht,Ut,Wt,Gt,Kt,qt,Jt,Yt,Xt,Zt,Qt,$t,en,tn,nn,rn,an,on,sn,cn,ln,un,dn,fn,pn,mn,hn,gn,_n,vn,yn,bn,xn,Sn,Cn,wn,Tn,En,Dn,On,kn,An,jn,Mn,Nn,Pn,Fn,In,Ln,Rn,zn,Bn,Vn,Hn,Un,Wn,Gn,Kn,qn,Jn,Yn,Xn,Zn,Qn,$n,er,tr,nr,rr,ir,ar,or,sr,cr,lr,ur,dr,k,fr,pr,mr,hr,gr,_r,vr,yr,br,xr,Sr,Cr,wr,Tr,Er,Dr,Or,kr,A,Ar,jr,j,Mr,Nr,Pr,Fr,M,Ir,Lr,Rr,N,P,zr,Br,Vr,Hr,F,I,Ur,Wr,Gr,Kr,qr,Jr,Yr,Xr,Zr,Qr,$r,ei,ti,ni,ri,ii,ai,oi,si,ci,li,ui,di,fi,pi,mi,hi,gi,_i,vi,yi,bi,xi,Si,Ci,wi,Ti,Ei,Di,Oi,ki,Ai,ji,Mi,Ni,Pi,Fi,Ii,Li,Ri,zi,Bi,Vi,Hi,L,R,Ui,z,Wi,B,Gi,Ki,qi,Ji,V,Yi,H,Xi,Zi,Qi,$i,ea,U,ta,na,ra,ia,aa,oa,W,sa,ca,la,G,ua,da,fa,pa,ma,ha,ga,_a,va,ya,ba,xa,Sa,Ca,wa,Ta,Ea,K,Da,Oa,ka,Aa,ja,Ma,Na,Pa,q,Fa,Ia,J,La,Ra,za,Ba,Va,Y,Ha,Ua,Wa,Ga,Ka,qa,Ja,Ya,Xa,Za,Qa,$a,eo,X,to,no,ro;function io(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function ao(e){if(Array.isArray(e))return e}function oo(e){if(Array.isArray(e))return io(e)}function so(e,t,n,r,i,a,o){try{var s=e[a](o),c=s.value}catch(e){n(e);return}s.done?t(c):Promise.resolve(c).then(r,i)}function Z(e){return function(){var t=this,n=arguments;return new Promise(function(r,i){var a=e.apply(t,n);function o(e){so(a,r,i,o,s,`next`,e)}function s(e){so(a,r,i,o,s,`throw`,e)}o(void 0)})}}function co(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function lo(e,t){"@swc/helpers - instanceof";return t!=null&&typeof Symbol<`u`&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}function uo(e){if(typeof Symbol<`u`&&e[Symbol.iterator]!=null||e[`@@iterator`]!=null)return Array.from(e)}function fo(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r=[],i=!0,a=!1,o,s;try{for(n=n.call(e);!(i=(o=n.next()).done)&&(r.push(o.value),!(t&&r.length===t));i=!0);}catch(e){a=!0,s=e}finally{try{!i&&n.return!=null&&n.return()}finally{if(a)throw s}}return r}}function po(){throw TypeError(`Invalid attempt to destructure non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function mo(){throw TypeError(`Invalid attempt to spread non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ho(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t],r=Object.keys(n);typeof Object.getOwnPropertySymbols==`function`&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),r.forEach(function(t){co(e,t,n[t])})}return e}function go(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function _o(e,t){return t=t==null?{}:t,Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):go(Object(t)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}),e}function vo(e,t){return ao(e)||fo(e,t)||bo(e,t)||po()}function yo(e){return oo(e)||uo(e)||bo(e)||mo()}function Q(e,t){var n,r,i,a={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},o=Object.create((typeof Iterator==`function`?Iterator:Object).prototype),s=Object.defineProperty;return s(o,`next`,{value:c(0)}),s(o,`throw`,{value:c(1)}),s(o,`return`,{value:c(2)}),typeof Symbol==`function`&&s(o,Symbol.iterator,{value:function(){return this}}),o;function c(e){return function(t){return l([e,t])}}function l(s){if(n)throw TypeError(`Generator is already executing.`);for(;o&&(o=0,s[0]&&(a=0)),a;)try{if(n=1,r&&(i=s[0]&2?r.return:s[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,s[1])).done)return i;switch(r=0,i&&(s=[s[0]&2,i.value]),s[0]){case 0:case 1:i=s;break;case 4:return a.label++,{value:s[1],done:!1};case 5:a.label++,r=s[1],s=[0];continue;case 7:s=a.ops.pop(),a.trys.pop();continue;default:if(i=a.trys,!(i=i.length>0&&i[i.length-1])&&(s[0]===6||s[0]===2)){a=0;continue}if(s[0]===3&&(!i||s[1]>i[0]&&s[1]<i[3])){a.label=s[1];break}if(s[0]===6&&a.label<i[1]){a.label=i[1],i=s;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(s);break}i[2]&&a.ops.pop(),a.trys.pop();continue}s=t.call(e,a)}catch(e){s=[6,e],r=0}finally{n=i=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}}function bo(e,t){if(e){if(typeof e==`string`)return io(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`)return Array.from(n);if(n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return io(e,t)}}function xo(e,t,n){var r=W(!0),i=W(0),a=W(0),o=W(0),s=W(0),c=W(0),l=W(0),u=W(0),d=W(0);function f(){var e=null;return t?function(){e||(e=setTimeout(function(){t({m_flag:r,m_left:i,m_right:a,m_bottom:s,m_top:o,m_x:u,m_y:d,m_height:c,m_width:l}),clearTimeout(e),e=null},10))}:!1}var p;Gi(e)?p=e.value:typeof e==`string`?p=document.querySelector(e):lo(e,Element)&&(p=e);var m=f();function h(e){var t=e.getBoundingClientRect(),n=t.left,r=t.right,f=t.top,p=t.bottom,m=t.height,h=t.width,g=t.x,_=t.y;i.value=n,a.value=r,o.value=f,s.value=p,c.value=m,l.value=h,u.value=g,d.value=_}return p&&(p.onmousedown=function(e){if(n&&n(e,{m_flag:r,m_left:i,m_right:a,m_bottom:s,m_top:o,m_x:u,m_y:d,m_height:c,m_width:l}),r.value){var t=p.getBoundingClientRect(),f=t.left,g=t.right,_=t.top,v=t.bottom,y=document.createElement(`div`),b=e.clientX,x=e.clientY;y.style.position=`absolute`,y.style.left=b-f+`px`,y.style.top=x-_+`px`,y.style.width=`0px`,y.style.height=`0px`,y.style.backgroundColor=`rgba(135, 182, 130, 0.1)`,y.classList.add(`district-wrapper`),p.appendChild(y),e.preventDefault();var S=function(e){e.preventDefault(),!ee.value&&!re.value&&(b<=e.clientX?y.style.width=e.clientX-b+`px`:(y.style.width=b-e.clientX+`px`,y.style.marginLeft=-(b-e.clientX)+`px`),x<=e.clientY?(y.style.height=e.clientY-x+D+`px`,y.style.marginTop=-D+`px`):(y.style.height=x-e.clientY+ae+`px`,y.style.marginTop=-(x-e.clientY)+`px`),e.clientX<f&&(y.style.width=b-f+`px`,y.style.marginLeft=-(b-f)+`px`),e.clientX>g&&(y.style.width=g-b+`px`)),e.clientY>v&&T(),e.clientY<_&&ne(),h(y),m&&m()},C=qa(function(){ie.scrollTop>=ie.scrollHeight-ie.clientHeight?w():(y.style.height=y.offsetHeight+10+`px`,y.style.marginTop=parseInt(getComputedStyle(y).marginTop)-10+`px`,ie.scrollTop+=10,D=ie.scrollTop,h(y),m&&m())},{immediate:!1}),w=C.pause,T=C.resume,ee=C.isActive,E=qa(function(){ie.scrollTop<=0?te():(y.style.height=y.offsetHeight+10+`px`,ie.scrollTop-=10,ae+=10,h(y),m&&m())},{immediate:!1}),te=E.pause,ne=E.resume,re=E.isActive,ie=p.querySelector(`.n-scrollbar-container`),D=0,ae=0;document.onmousemove=S,document.onmouseup=function(){document.onmousemove=null,p.contains(y)&&p.removeChild(y)}}}),{m_flag:r,m_x:u,m_y:d,m_left:i,m_right:a,m_top:o,m_bottom:s,m_height:c,m_width:l}}function So(e,t){var n=Ia(e.m_left),r=Ia(e.m_right),i=Ia(e.m_top),a=Ia(e.m_bottom),o=Ia(t.left),s=Ia(t.right),c=Ia(t.top),l=Ia(t.bottom);return!(s<n||o>r||l<i||c>a)}function Co(e){e.card_hover=!0}function wo(e){e.card_hover=!1}function $(e,t){return Z(function(){var n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,C,w;return Q(this,function(T){switch(T.label){case 0:n=e.tableLoading,r=e.currentPath,i=e.favoriteList,a=e.fileRecycle,o=e.fileList,s=e.filesView,c=e.directoryCount,l=e.fileCount,u=e.total,d=e.page,f=e.size,p=e.sort,m=e.reverse,h=e.diskMountPoint,g=e.currentFile,_=e.currentDirSize,v=e.uploadFileList,y=e.dragUploadRef,n.value=!0,T.label=1;case 1:return T.trys.push([1,4,5,6]),[4,yc(r.value,function(e){i.value=e.store,a.value=e.file_recycle,c.value=e.dir.length,l.value=e.files.length,u.value=hi(e.page),h.value=e.disk,r.value=e.path},ho(_o(ho({p:d.value,showRow:f.value},p.value?{sort:p.value,reverse:m.value}:{}),{disk:!0}),t))];case 2:return x=T.sent(),g.value=null,_.value=-1,[4,Eo(e)];case 3:return S=T.sent(),C=[],S.length&&(C=S.map(function(e){return e.key})),o.value=x.map(function(e){return e.remarks_hover=!1,e.isEditRemarks=!1,e.isCreate=!1,e.card_hover=!1,e.card_choosed=!1,e.isRenameForCard=!1,e.operation_show=!1,e.isFavorite=!!C.includes(e.path),e.isShare=Number(e.durl)===0?0:Number(e.durl),e}),v.value=[],(b=y.value)==null||b.listenDragEvent(),Yi(function(){s.value==`list`&&(To(e),Mo(e))}),Cc(e),[3,6];case 4:return w=T.sent(),console.warn(w),[3,6];case 5:return n.value=!1,[7];case 6:return[2]}})})()}function To(e){var t=e.tableRef;t.value&&xo(t.value.querySelector(`.n-data-table-base-table-body`),function(t){return Do(e,t)},function(t,n){return Oo(t,n,e)})}function Eo(e){return Z(function(){var t,n,r,i;return Q(this,function(a){switch(a.label){case 0:t=e.resetFavoriteOptions,n=e.favoriteOptions,a.label=1;case 1:return a.trys.push([1,3,,4]),[4,G.post(`/files?action=get_files_store`,{},{requestOptions:{isOriginalResult:!0}})];case 2:return r=a.sent().message.map(function(e){return{type:e.type,icon:e.type,label:e.name,key:e.path}}),t(),n.value=yo(r).concat(yo(n.value)),[2,n.value];case 3:return i=a.sent(),console.warn(i),[2,[]];case 4:return[2]}})})()}function Do(e,t){for(var n=e.trRectArr,r=e.choosedKeys,i=[],a=0;a<n.value.length;a++){var o=vo(vo(Object.entries(n.value[a]),1)[0],2),s=o[0],c=o[1];So(t,c.getClientRects()[0])&&i.push(s)}r.value=yo(new Set(i))}function Oo(e,t,n){var r=n.choosedKeys;if(!e.target.closest(`.n-checkbox-box`)){if(e.target.classList.contains(`file-checkbox`)){var i=e.target.closest(`tr`).dataset.key;r.value.includes(i)?r.value=r.value.filter(function(e){return e!==i}):r.value.push(i)}else{if(ko(n),e.target.closest(`tr`)){var a=e.target.closest(`tr`).dataset.key;if(e.button==0&&(r.value=[a]),e.button==2){if(r.value.includes(a))return;r.value=[a]}}e.target.nodeName==`INPUT`?t.m_flag.value=!1:t.m_flag.value=!0}}}function ko(e){var t,n=e.normalTrList,r=e.trRectArr,i=(t=e.tableRef.value)==null?void 0:t.querySelector(`.n-data-table-base-table-body`);n.value=i?i.querySelectorAll(`tr[data-key]`):[];for(var a=[],o=0;o<n.value.length;o++){var s=n.value[o].dataset.key;a.push(co({},s,n.value[o]))}r.value=a}function Ao(e,t){var n=e.currentPath;t.type==`dir`?(n.value=n.value==`/`?`/`.concat(t.nm):n.value+`/`+t.nm,$(e)):gc(t)?Bo(e,t.path):vc(t.ext)?Sc(e,`Decompress`,function(e){return e.value.open()}):hc(t.ext)?Vo(e,t):Us(e)}function jo(e,t,n){var r=e.currentPath,i=n.type,a=n.name,o=uc(a,i);if(i==`dir`)r.value=t,$(e);else if(_c(o))Bo(e,t);else if(vc(o))Sc(e,`Decompress`,function(e){return e.value.open(t,o)});else if(hc(o))Vo(e,{path:t,nm:n.name});else{var s=t.substring(0,t.lastIndexOf(`/`));ea(t,s)}}function Mo(e){var t=e.tableRef,n=e.choosePathRef,r=0,i=setInterval(function(){if(r<10?r++:clearInterval(i),t.value){var a=t.value;a.querySelector(`.n-data-table-base-table-body`)&&To(e),a.oncontextmenu=function(t){t.preventDefault(),No(t,e)},a.onclick=function(t){t.target.nodeName!=`INPUT`&&(Vr(e),n.value.handleEnterDown())},clearInterval(i)}else return},1e3)}function No(e,t){var n=t.choosedKeys,r=t.contextRef,i=`empty`;e.target.closest(`tr`)&&(i=n.value.length>1?`multiple`:n.value.length==1?`single`:`empty`),r.value.filesOperation(e,i)}function Po(){var e,t=(e=document.querySelector(`#createInput`))==null?void 0:e.querySelector(`input`);t==null||t.focus(),t==null||t.select()}function Fo(e,t){return Z(function(){var n,r,i;return Q(this,function(a){switch(a.label){case 0:if(xi().isFree)return na(71),[2];n=V.loading(`Processing, please wait...`).close,a.label=1;case 1:return a.trys.push([1,,4,5]),[4,Tr(`tamper_core`,71)];case 2:return a.sent(),[4,G.post(`/tamper_core/get_effective_path.json`,{path:t.path},{requestOptions:{isOriginalResult:!0}})];case 3:return r=a.sent().message,B(r)&&r.status&&(i=r.data,t.type===`dir`?Io(e,t,i):Lo(e,t,i)),[3,5];case 4:return n(),[7];case 5:return[2]}})})()}function Io(e,t,n){var r=n.pid,i=n.lock,a=n.action,o=(i?`Turning off protection `:`Turning on protection `)+`[`.concat(t.path,`]`),s=Ma(i?`file.tableController.afterTurningOffProtectionDir`:`file.tableController.afterTurningOnProtectionDir`);za({width:480,title:o,content:s,onConfirm:function(){return Z(function(){var n;return Q(this,function(o){switch(o.label){case 0:return a[0]!==`create`||r!==0?[3,2]:[4,Ro(t.path,[])];case 1:return o.sent(),$(e),[2];case 2:return n=[],i?n.push({key:t.path.indexOf(`/www/server/panel/class`)==-1?a[0]:`add_wd`,values:[t.path]}):n.push({key:a[0],values:[t.path]}),[4,zo(r,n)];case 3:return o.sent(),$(e),[2]}})})()}})}function Lo(e,t,n){var r=n.pid,i=n.lock,a=n.action,o=Ma(i?`file.tableController.turningOffProtection`:`file.tableController.turningOnProtection`,{path:t.path}),s=Ma(i?`file.tableController.afterTurningOffProtectionFile`:`file.tableController.afterTurningOnProtectionFile`),c=W(!1),l=W(!0);za({title:o,width:480,content:function(){return P(S,null,[P(`div`,null,[s]),P(`div`,{class:`mt-8px`},[P(u,{checked:l.value,"onUpdate:checked":function(e){return l.value=e}},{default:function(){return[P(`span`,null,[Ma(i?`file.tableController.turningOffProtectionFile`:`file.tableController.turningOnProtectionFile`,{path:t.nm})])]}})]),P(`div`,{class:`mt-8px`},[P(u,{checked:c.value,"onUpdate:checked":function(e){return c.value=e}},{default:function(){return[P(`span`,null,[Ma(i?`file.tableController.turningOffProtectionSuffix`:`file.tableController.turningOnProtectionSuffix`,{suffix:t.ext})])]}})])])},onConfirm:function(){return Z(function(){var n,o,s,u,d;return Q(this,function(f){switch(f.label){case 0:return a[0]!==`create`||r!==0?[3,2]:(n=t.path.substring(0,t.path.lastIndexOf(`/`)),o=[],l.value&&(s=t.path.split(`/`),u=s.length>=2?s[s.length-2]:``,o.push(``.concat(u,`/`,t.nm))),c.value&&o.push(`.`+t.ext),[4,Ro(n,o)]);case 1:return f.sent(),$(e),[2];case 2:return d=[],i?(l.value&&(d.push({key:`remove_bf`,values:[t.path]}),d.push({key:`add_wf`,values:[t.path]})),c.value&&d.push({key:`remove_bf`,values:[`.`+t.ext]})):(l.value&&(d.push({key:`add_bf`,values:[t.path]}),d.push({key:`remove_wf`,values:[t.path]})),c.value&&d.push({key:`add_bf`,values:[`.`+t.ext]})),[4,zo(r,d)];case 3:return f.sent(),$(e),[2]}})})()}})}function Ro(e,t){return Z(function(){var n,r;return Q(this,function(i){switch(i.label){case 0:return[4,G.post(`/tamper_core/create_path.json`,{path:e,exts:JSON.stringify(t)},{requestOptions:{loading:Ma(`file.tableController.creatingDirectoryProtection`),isOriginalResult:!0}})];case 1:if(n=i.sent(),r=n.message,B(r)){if(r.status)V.success(r.msg);else return V.error(r.msg),[2,Promise.reject()]}return[2]}})})()}function zo(e,t){return Z(function(){var n,r;return Q(this,function(i){switch(i.label){case 0:return[4,G.post(`/tamper_core/batch_setting.json`,{pid:e,settings:JSON.stringify(t)},{requestOptions:{loading:Ma(`file.tableController.executing`),isOriginalResult:!0}})];case 1:if(n=i.sent(),r=n.message,B(r)){if(r.status)V.success(r.msg);else return V.error(r.msg),[2,Promise.reject()]}return[2]}})})()}function Bo(e,t){var n=e.currentPreviewImg,r=e.previewShow;n.value=t,r.value=!0}function Vo(e,t){var n=e.currentPreviewVideo,r=e.previewVideoShow;n.value={path:t.path,name:t.nm},r.value=!0}function Ho(e){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return[4,G.post(`/files?action=set_file_ps`,e,{requestOptions:{successMessage:!0}})];case 1:return t.sent(),[2]}})})()}function Uo(e){return Z(function(){var t,n,r;return Q(this,function(i){switch(i.label){case 0:if(t=e.currentFile,n=e.currentPath,!t.value||!(t.value.isCreate&&t.value.isRename||t.value.isRenameForCard)||(t.value.editName||(t.value.isCreate=!1),t.value.editName==t.value.nm&&(t.value.isCreate=!1),!(t.value.isCreate&&t.value.isRename||t.value.isRenameForCard)))return[3,7];if(t.value.editName===t.value.nm)return[3,6];i.label=1;case 1:return i.trys.push([1,3,4,5]),[4,Rs(t.value.path,n.value+`/`+t.value.editName)];case 2:return i.sent(),$(e),[3,5];case 3:return r=i.sent(),console.log(r),[3,5];case 4:return t.value.isCreate=!1,t.value.isRenameForCard=!1,t.value.isRename=!1,[7];case 5:return[2,!0];case 6:t.value.isCreate=!1,t.value.isRenameForCard=!1,t.value.isRename=!1,i.label=7;case 7:return[2]}})})()}function Wo(e){return Z(function(){var t,n,r,i;return Q(this,function(a){switch(a.label){case 0:return t=e.currentFile,n=e.currentPath,r=e.fileList,!t.value||!t.value.isCreate||t.value.isRename?[3,8]:t.value.editName==``?(r.value.shift(),[3,8]):[3,1];case 1:return a.trys.push([1,7,,8]),t.value.type==`dir`?[4,ts(n.value+`/`+t.value.editName)]:[3,3];case 2:return a.sent(),[3,5];case 3:return[4,ns(n.value+`/`+t.value.editName)];case 4:a.sent(),a.label=5;case 5:return[4,$(e)];case 6:return a.sent(),[2,!0];case 7:return i=a.sent(),r.value.shift(),console.warn(i),[3,8];case 8:return[2]}})})()}function Go(e){return Z(function(){var t;return Q(this,function(n){switch(n.label){case 0:return t=e.currentFile,!t.value||!t.value.isEditRemarks?[3,4]:t.value.editRemarks==t.value.rmk?[3,3]:[4,Ho({filename:t.value.path,ps_type:0,ps_body:t.value.editRemarks})];case 1:return n.sent(),[4,$(e)];case 2:return n.sent(),[2,!0];case 3:return t.value.isEditRemarks=!1,t.value.remarks_hover=!1,[2,!1];case 4:return[2]}})})()}function Ko(e){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return[4,Go(e)];case 1:return t.sent()?[2]:[4,Uo(e)];case 2:return t.sent()?[2]:[4,Wo(e)];case 3:return t.sent(),[2]}})})()}function qo(){return Z(function(){return Q(this,function(e){return[2,G.post(`/task?action=get_task_lists`,{status:-3})]})})()}function Jo(e){return Z(function(){var n;return Q(this,function(r){switch(r.label){case 0:return document.querySelector(`.file-task-modal`)?[2]:[4,qo()];case 1:return n=r.sent().message,Wi(n)&&n.length>0&&Wa({title:Ma(`file.tableController.realtimeTaskQueue`),width:510,class:`file-task-modal`,unstableShowMask:!1,data:{store:e,taskList:n},component:F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.O})},void 0)})}),[2]}})})()}function Yo(e){return Z(function(){return Q(this,function(t){return[2,G.post(`/task?action=remove_task`,{id:e},{requestOptions:{loading:Ma(`file.tableController.deletingTask`),successMessage:!0}})]})})()}function Xo(e){return Wa({title:Aa(`file.shareListModal.title`),width:850,data:{fileStore:e},component:Sa})}function Zo(e){var t=e.fileList.value.find(function(t){return t.nm===e.choosedKeys.value[0]});if(t)return Wa({title:t.type==`dir`?Aa(`file.shareModal.setShareFolder`,{name:t.nm}):Aa(`file.shareModal.setShareFile`,{name:t.nm}),width:560,footer:!0,confirmText:Aa(`file.shareModal.create`),data:{file:t,fileStore:e},component:zr})}function Qo(e,t){return Wa({title:Aa(`file.shareModal.shareDetails`,{name:e.ps||e.filename||e.id}),width:560,footer:!0,confirmType:`error`,confirmText:Aa(`file.shareModal.closeSharingChain`),data:{detail:e,fileStore:t},component:Jr})}function $o(e,t){Qo({id:e},t)}function es(e,t){var n=Number(e.isShare||e.durl);n&&$o(n,t)}function ts(e){return Z(function(){var t;return Q(this,function(n){switch(n.label){case 0:return n.trys.push([0,2,,3]),[4,G.post(`/files?action=CreateDir`,{path:e},{requestOptions:{loading:ka(`file.buttonGroup.loading.creatingDirectory`),successMessage:!0}})];case 1:return n.sent(),[3,3];case 2:return t=n.sent(),console.warn(t),[3,3];case 3:return[2]}})})()}function ns(e){return Z(function(){var t;return Q(this,function(n){switch(n.label){case 0:return n.trys.push([0,2,,3]),[4,G.post(`/files?action=CreateFile`,{path:e},{requestOptions:{loading:ka(`file.buttonGroup.loading.creatingFile`),successMessage:!0}})];case 1:return n.sent(),[3,3];case 2:return t=n.sent(),console.warn(t),[3,3];case 3:return[2]}})})()}function rs(e,t){return Z(function(){var n;return Q(this,function(r){switch(r.label){case 0:return r.trys.push([0,2,,3]),[4,G.post(`/files?action=CreateLink`,{sfile:e,dfile:t},{requestOptions:{loading:ka(`file.buttonGroup.loading.creatingSoftlink`),successMessage:!0}})];case 1:return r.sent(),[3,3];case 2:return n=r.sent(),console.warn(n),[3,3];case 3:return[2]}})})()}function is(e,t){var n=e.filesView;n.value=t}function as(e){Sc(e,`UploadFile`,function(e){e.value.open()})}function os(e){Sc(e,`RemoteDownload`,function(e){e.value.open()})}function ss(e){return Wa({title:ka(`file.searchFileContentModal.title`),width:1100,height:686,footer:!1,data:{fileStore:e,currentPath:e.currentPath.value},component:F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.t})},void 0)})})}function cs(e){ss(e)}function ls(e,t,n){t==`management`?ta(e):jo(e,t,n)}function us(e){Xo(e)}function ds(e){var t=e.currentPath;t.value=`/`,$(e)}function fs(e){Sc(e,`Backup`,function(e){e.value.open()})}function ps(e){return Wa({title:ka(`file.recycle.title`),width:1100,height:686,data:{fileStore:e},component:F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.n})},void 0)})})}function ms(e){ps(e)}function hs(){return Wa({title:ka(`file.buttonGroup.fileOperationRecord`),width:1100,height:640,footer:!1,component:F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.r})},void 0)})})}function gs(e){Sc(e,`Terminal`,function(e){e.value.open()})}function _s(e,t,n,r){var i=e.fileList,a=e.currentFile;a.value={nm:t,isCreate:!0,type:n,ext:r,path:``,editName:t},a.value.editName=a.value.nm,i.value.unshift(a.value),Yi(Po)}function vs(e,t){switch(t){case`dir`:_s(e,ka(`file.buttonGroup.defaultNames.untitledDirectory`),`dir`,`folder`);break;case`file`:_s(e,ka(`file.buttonGroup.defaultNames.untitledFile`),`file`,`unknown`);break;case`softlink`:Sc(e,`Softlink`,function(e){e.value.open()})}}function ys(e){var t=e.isMiniScreen;t.value=window.innerWidth<1560}function bs(e,t){return Z(function(){var n;return Q(this,function(r){switch(r.label){case 0:return r.trys.push([0,2,,3]),[4,G.post(`/files?action=del_files_store`,{path:t},{requestOptions:{loading:ka(`file.buttonGroup.loading.deletingFavorite`),successMessage:!0}})];case 1:return r.sent(),$(e),[3,3];case 2:return n=r.sent(),console.warn(n),[3,3];case 3:return[2]}})})()}function xs(e,t){return Z(function(){return Q(this,function(n){switch(n.label){case 0:return[4,G.post(`/files?action=`.concat(t===`dir`?`DeleteDir`:`DeleteFile`),{path:e},{requestOptions:{loading:Oa(`file.deleteController.deletingSingle`),successMessage:!0}})];case 1:return n.sent(),[2]}})})()}function Ss(e,t){return Z(function(){return Q(this,function(n){switch(n.label){case 0:return[4,G.post(`/files?action=SetBatchData`,{data:JSON.stringify(e),type:4,path:t},{requestOptions:{loading:Oa(`file.deleteController.deletingBatch`),successMessage:!0}})];case 1:return n.sent(),[2]}})})()}function Cs(e){return mr.includes(e.toLowerCase())}function ws(e){var t=e.toLowerCase();return hr[t]||t.split(`.`).pop().toUpperCase()}function Ts(e){return K(`file.contextMenu.archivePreviewWithType`,{type:ws(e)})}function Es(e){return e in kr}function Ds(e,t){var n=t.value.trim().toLowerCase();return Or[e].includes(n)}function Os(e,t){return(t==null?void 0:t.name)||K(kr[e].labelKey)}function ks(e){return Z(function(){var t;return Q(this,function(n){switch(n.label){case 0:return[4,li(e)];case 1:return t=n.sent(),t&&Xa(t.row,void 0,t.softInfo),[2]}})})()}function As(e,t){var n=Os(e,t);t!=null&&t.install?Ca(t)?ks(e):Ja({name:e,title:n,admin:!0}):Ha(e)}function js(e){return Z(function(){var t;return Q(this,function(n){switch(n.label){case 0:return[4,ui()];case 1:return t=n.sent().message,[2,(Array.isArray(t)?t:B(t)&&Array.isArray(t.list)?t.list:[]).find(function(t){return Ds(e,t)})]}})})()}function Ms(e,t){return Z(function(){var n;return Q(this,function(r){switch(r.label){case 0:return xi().isFree?(ra({component:$r,data:{storageName:Os(t)}}),[2]):[4,js(t)];case 1:return n=r.sent(),n!=null&&n.install?Ca(n)?[4,ks(t)]:[3,3]:(As(t,n),[2]);case 2:return r.sent(),[2];case 3:return n.config?(oc(e,t),[2]):(As(t,n),[2])}})})()}function Ns(e,t){return Z(function(){return Q(this,function(n){switch(n.label){case 0:return[4,G.post(`/files?action=CheckExistsFiles`,{dfile:e,filename:t},{requestOptions:{isOriginalResult:!0}})];case 1:return[2,n.sent().message.length>0]}})})()}function Ps(e,t,n){return Z(function(){return Q(this,function(r){switch(r.label){case 0:return[4,G.post(`/files?action=SetBatchData`,{data:JSON.stringify(e),type:t,path:n},{requestOptions:{loading:K(`file.contextMenu.loading.batchSetting`),successMessage:!0}})];case 1:return[2,r.sent()]}})})()}function Fs(e,t){return Z(function(){return Q(this,function(n){switch(n.label){case 0:return[4,G.post(`/files?action=CopyFile`,{sfile:e,dfile:t},{requestOptions:{loading:K(`file.contextMenu.loading.copying`),successMessage:!0}})];case 1:return[2,n.sent()]}})})()}function Is(e,t){return Z(function(){return Q(this,function(n){switch(n.label){case 0:return[4,G.post(`/files?action=BatchPaste`,{type:e,path:t},{requestOptions:{loading:K(`file.contextMenu.loading.pasting`),successMessage:!0}})];case 1:return[2,n.sent()]}})})()}function Ls(e,t,n){return Z(function(){return Q(this,function(r){switch(r.label){case 0:return[4,G.post(`/files?action=MvFile`,ho({sfile:e,dfile:t},n),{requestOptions:{loading:K(`file.contextMenu.loading.moving`),successMessage:!0}})];case 1:return[2,r.sent()]}})})()}function Rs(e,t){return Ls(e,t,{rename:!0})}function zs(e,t,n,r){var i=arguments.length>4&&arguments[4]!==void 0&&arguments[4];return Z(function(){var a;return Q(this,function(o){switch(o.label){case 0:return[4,G.post(`/files?action=`.concat(i?`ZipAndDownload`:`Zip`),{sfile:e,dfile:t,z_type:n,path:r},{requestOptions:{loading:K(`file.contextMenu.loading.compressing`),successMessage:!i}})];case 1:if(a=o.sent().message,i&&B(a)){if(a.task_id)return[2,a.msg];Qr(a.result)}return[2,``]}})})()}function Bs(e){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return[4,G.post(`/files?action=UnZip`,e,{requestOptions:{loading:K(`file.contextMenu.loading.decompressing`),successMessage:!0}})];case 1:return t.sent(),[2]}})})()}function Vs(e,t){return t.map(function(t){return e[t]})}function Hs(e,t){var n=e.fileList,r=e.choosedKeys,i=xc(n.value,r.value)[0],a=[`share`,`favorite`,`permission`,`copy`,`copyPath`,`cut`,`rename`,`del`,`compression`,`attrs`];if(!i)return Vs(t.value,[`refresh`,`upload`,`create`,`terminal`]);i.type==`dir`?a.unshift(`open`,`openNewWindow`):a.unshift(`edit`,`download`);var o=a.findIndex(function(e){return e===`permission`});if(a.splice(o,0,`uploadToCloud`),gc(i)&&(a.unshift(`preview`),a=a.filter(function(e){return e!==`edit`})),hc(i.ext)&&(a.unshift(`playVideo`),a=a.filter(function(e){return e!==`edit`})),i.isFavorite){var s=a.findIndex(function(e){return e==`favorite`});a[s]=`unfavorite`}if(i.isShare){var c=a.findIndex(function(e){return e==`share`});a[c]=`unShare`}vc(i.ext)&&(a.unshift(`decompress`),Cs(i.ext)&&a.splice(1,0,`compressionPreview`),a=a.filter(function(e){return e!==`edit`}));var l=Vs(t.value,a),u=l.findIndex(function(e){return e.key===`compressionPreview`});return u>-1&&(l[u]=_o(ho({},l[u]),{label:Ts(i.ext)})),l}function Us(e){var t=e.choosedKeys,n=e.currentPath,r=e.fileList.value.find(function(e){return e.nm==t.value[0]});r&&ea(r.path,n.value)}function Ws(e){var t=e.choosedKeys,n=e.currentPath,r=e.fileList.value.find(function(e){return e.nm==t.value[0]});e.page.value=1,n.value=r.path,$(e)}function Gs(e){return Z(function(){var t,n,r,i;return Q(this,function(a){switch(a.label){case 0:t=e.choosedKeys,n=e.fileList,r=n.value.find(function(e){return e.nm==t.value[0]}),a.label=1;case 1:return a.trys.push([1,3,,4]),[4,G.post(`/files?action=add_files_store`,{path:r.path},{requestOptions:{loading:K(`file.contextMenu.loading.addingToFavorites`),successMessage:!0}})];case 2:return a.sent(),Eo(e),$(e),[3,4];case 3:return i=a.sent(),console.warn(i),[3,4];case 4:return[2]}})})()}function Ks(e){return Z(function(){var t,n,r;return Q(this,function(i){return t=e.choosedKeys,n=e.fileList,r=xc(n.value,t.value)[0],r&&za({title:K(`file.favoriteListModal.cancelFavoriteTitle`),content:K(`file.favoriteListModal.cancelFavoriteMessage`,{name:r.nm}),onConfirm:function(){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return[4,bs(e,r.path)];case 1:return t.sent(),[2]}})})()}}),[2]})})()}function qs(e,t,n){return Z(function(){var r,i,a,o,s,c,l;return Q(this,function(u){switch(u.label){case 0:return r=e.choosedKeys,i=e.fileList,a=e.fileCopyCache,o=e.waitForPaste,s=e.copiedFile,c=e.currentPath,r.value.length==1?(V.success(t),a.value=JSON.parse(JSON.stringify(r.value)),s.value=xc(i.value,a.value)[0],o.value=!0,[3,4]):[3,1];case 1:return u.trys.push([1,3,,4]),[4,Ps(r.value,n,c.value)];case 2:return u.sent().status==0&&(a.value=JSON.parse(JSON.stringify(r.value)),o.value=!0),[3,4];case 3:return l=u.sent(),console.warn(l),[3,4];case 4:return[2]}})})()}function Js(e){return Z(function(){var t,n,r,i,a;return Q(this,function(o){switch(o.label){case 0:return t=e.fileCopyCache,n=e.fileOperationFlag,r=e.currentPath,i=e.copiedFile,a=e.waitForPaste,t.value.length>1?[4,Is(n.value,r.value)]:[3,2];case 1:return o.sent(),[3,6];case 2:return t.value.length==1?n.value==1?[4,Fs(i.value.path,r.value+`/`+i.value.nm)]:[3,4]:[3,6];case 3:return o.sent(),[3,6];case 4:return n.value==2?[4,Ls(i.value.path,r.value+`/`+i.value.nm)]:[3,6];case 5:o.sent(),o.label=6;case 6:return $(e),a.value=!1,[2]}})})()}function Ys(e){return Z(function(){var t,n;return Q(this,function(r){switch(r.label){case 0:return t=e.fileOperationFlag,n=e.waitForPaste,t.value=1,[4,qs(e,K(`file.contextMenu.messages.copySuccess`),1)];case 1:return r.sent(),n.value=!0,[2]}})})()}function Xs(e){return Z(function(){var t,n,r;return Q(this,function(i){return t=e.choosedKeys,n=e.fileList,r=xc(n.value,t.value)[0],r&&jr(r.path),[2]})})()}function Zs(e){return Z(function(){var t,n;return Q(this,function(r){switch(r.label){case 0:return t=e.fileOperationFlag,n=e.waitForPaste,t.value=2,[4,qs(e,K(`file.contextMenu.messages.cutSuccess`),2)];case 1:return r.sent(),n.value=!0,[2]}})})()}function Qs(e){return Z(function(){var t,n,r,i;return Q(this,function(a){switch(a.label){case 0:return t=e.fileCopyCache,n=e.currentPath,r=e.waitForPaste,r.value?(i=!1,t.value.length==1?[4,Ns(n.value,t.value[0])]:[3,2]):[2];case 1:return i=a.sent(),[3,4];case 2:return t.value.length>1?[4,Ns(n.value)]:[3,4];case 3:i=a.sent(),a.label=4;case 4:return i?t.value.length==1?Sc(e,`PasteSingleConfirm`,function(e){return e.value.open()}):t.value.length>1&&Sc(e,`PasteConfirm`,function(e){return e.value.open()}):Js(e),[2]}})})()}function $s(e){return Z(function(){var t,n;return Q(this,function(r){return t=e.currentPath,n=e.choosedKeys,Qr(``.concat(t.value===`/`?``:t.value,`/`,n.value[0])),[2]})})()}function ec(e){return Z(function(){var t,n,r,i,a;return Q(this,function(o){return t=e.choosedKeys,n=e.fileList,r=e.currentFile,i=e.filesView,a=xc(n.value,t.value)[0],r.value=a,i.value===`card`?(r.value.isRenameForCard=!0,r.value.editName=r.value.nm):(a.isCreate=!0,a.isRename=!0,a.editName=a.nm,Yi(Po)),[2]})})()}function tc(e){Sc(e,`Compression`,function(e){return e.value.open()})}function nc(e){var n=e.choosedKeys,r=e.fileList,i=xc(r.value,n.value)[0];i&&Wa({title:K(`file.archivePreviewModal.titleWithTypeFile`,{type:ws(i.ext),name:i.nm}),width:720,height:560,footer:!1,data:{file:i,fileStore:e},component:F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.a})},void 0)})})}function rc(e){var t=e.choosedKeys,n=e.fileList,r=xc(n.value,t.value)[0];Bo(e,r.path)}function ic(e){return Z(function(){var t,n,r,i;return Q(this,function(a){switch(a.label){case 0:return t=e.choosedKeys,n=e.fileList,r=xc(n.value,t.value)[0],i=Number((r==null?void 0:r.isShare)||(r==null?void 0:r.durl)),i?[4,sa({id:i})]:[2];case 1:return a.sent(),$(e),[2]}})})()}function ac(e){var t=e.choosedKeys,n=e.fileList,r=xc(n.value,t.value)[0];Vo(e,r)}function oc(e,n){var r=kr[n];Wa({title:function(){return Si(`div`,{class:`flex items-center gap-8px`},[Si(`img`,{class:`inline-block h-18px max-h-18px max-w-18px w-18px object-contain align-middle`,src:r.icon,alt:``}),Si(`span`,K(r.labelKey))])},width:1100,height:686,footer:!1,data:{initialLocalPath:e.currentPath.value,providerKey:n},component:F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.i})},void 0)})})}function sc(e,t){var n=t.menuShow;if(typeof e==`string`&&e.startsWith(`uploadToCloud:`)){var r=e.slice(14);Es(r)?Ms(t,r):V.warning(K(`file.contextMenu.messages.cloudUploadNotConnected`)),n.value=!1}else{switch(e){case`edit`:Us(t);break;case`copy`:Ys(t);break;case`copyPath`:Xs(t);break;case`cut`:Zs(t);break;case`paste`:Qs(t);break;case`permission`:Sc(t,`Permission`,function(e){return e.value.open()});break;case`compression`:tc(t);break;case`decompress`:Sc(t,`Decompress`,function(e){return e.value.open()});break;case`compressionPreview`:nc(t);break;case`conversion`:console.log(`conversion`);break;case`del`:Wr(t);break;case`refresh`:$(t);break;case`upload`:Sc(t,`UploadFile`,function(e){return e.value.open()});break;case`createFile`:_s(t,K(`file.contextMenu.defaultNames.untitledFile`),`file`,`file`);break;case`createDir`:_s(t,K(`file.contextMenu.defaultNames.untitledDirectory`),`dir`,`folder`);break;case`download`:$s(t);break;case`terminal`:Sc(t,`Terminal`,function(e){return e.value.open()});break;case`open`:Ws(t);break;case`share`:Zo(t);break;case`unShare`:ic(t);break;case`favorite`:Gs(t);break;case`unfavorite`:Ks(t);break;case`rename`:ec(t);break;case`attrs`:Sc(t,`Properties`,function(e){return e.value.open()});break;case`preview`:rc(t);break;case`playVideo`:ac(t)}n.value=!1}}function cc(e){var t=e.type,n=e.list,r=e.path,i=[],a=!0,o=!1,s=void 0;try{for(var c=n[Symbol.iterator](),l;!(a=(l=c.next()).done);a=!0){var u=l.value;i.push(lc({type:t,item:u,path:r}))}}catch(e){o=!0,s=e}finally{try{!a&&c.return!=null&&c.return()}finally{if(o)throw s}}return i}function lc(e){var t=e.type,n=e.item,r=e.path,i=n.nm,a=n.sz,o=n.is_link,s=n.lnk,c=n.mt,l=n.ctime,u=n.atime,d=n.gid,f=n.uid,p=n.group,m=n.user,h=n.acc,g=n.rmk,_=n.durl,v=n.cmp,y=n.fav,b=n.top,x=n.sn;return{ext:uc(n.nm,t),nm:i,sz:a,mt:c,acc:h,user:m,is_link:o?s:``,lnk:s,durl:_,cmp:v,fav:y,rmk:g,top:b,sn:x,path:dc(r,i),ctime:l,atime:u,gid:d,uid:f,group:p,type:t}}function uc(e,t){if(t===`dir`)return`folder`;var n=[`tar.gz`],r=e.toLowerCase(),i=!0,a=!1,o=void 0;try{for(var s=n[Symbol.iterator](),c;!(i=(c=s.next()).done);i=!0){var l=c.value;if(r.endsWith(l))return l}}catch(e){a=!0,o=e}finally{try{!i&&s.return!=null&&s.return()}finally{if(a)throw o}}var u=r.lastIndexOf(`.`);return u===-1?`file`:r.substring(u+1)}function dc(e,t){return fc(``.concat(e,`/`,t))}function fc(e){return e.replace(/\/\//g,`/`)}function pc(e){var t=[`folder`],n=[`txt`,`rtf`,`md`,`log`,`conf`],r=[`json`],i=[`htm`,`html`,`xhtml`],a=[`css`,`less`,`scss`],o=[`js`,`ts`],s=[`php`],c=[`pdf`,`pdfa`,`pdfx`,`pdfu`],l=[`doc`,`docx`,`docm`,`dot`,`dotx`,`dotm`],u=[`xlsx`,`xlsm`,`xltx`,`xltm`],d=`jpg.jpeg.png.gif.bmp.webp.tiff.tif.psd.ai.eps.cr2.cr3.nef.nrw.dng.svg.cdr.wmf.emf.apng.heic.ico.xbm.xpm.xcf.iff.pnm`.split(`.`),f=`py.java.js.ts.c.cpp.cs.php.rb.go.swift.kt.html.css.jsx.vue.scss.less.tsx.json.xml.yaml.yml.ini.properties.env.sql.pl.sh.bat.ps1.m.swift.kt.gradle.makefile.cmake.jar.war.exe.md.gitignore.dockerfile.yml.ipynb.asm.lua.rs.hs`.split(`.`);return t.includes(e)?`file-dir`:n.includes(e)?`file-txt`:r.includes(e)?`file-json`:i.includes(e)?`file-html`:a.includes(e)?`file-css`:o.includes(e)?`file-js`:s.includes(e)?`file-php`:l.includes(e)?`file-doc`:c.includes(e)?`file-pdf`:u.includes(e)?`file-excel`:d.includes(e)?`file-img`:f.includes(e)?`file-sh`:[`zip`,`rar`,`7z`,`tar`,`tar.gz`,`gz`,`tgz`,`tar.bz2`,`tar.xz`,`cab`,`iso`,`msi`,`rpm`,`deb`,`xz`,`zipx`,`lz4`,`zst`,`rar5`,`part1.rar`,`rar.part1`,`z01`,`z02`].includes(e)?`file-compression`:`file-unknown-file`}function mc(e){return!![`file-txt`,`file-json`,`file-html`,`file-css`,`file-js`,`file-php`,`file-doc`,`file-sh`].includes(pc(e.ext))}function hc(e){return[`mp3`,`mp4`,`avi`,`mov`,`mkv`,`wmv`,`flv`,`3gp`,`3g2`,`vob`,`webm`,`ogv`].includes(e)}function gc(e){return pc(e.ext)===`file-img`}function _c(e){return pc(e)===`file-img`}function vc(e){return pc(e)===`file-compression`}function yc(e,t,n){return Z(function(){var r,i,a,o;return Q(this,function(s){switch(s.label){case 0:return s.trys.push([0,2,,3]),[4,G.post(`/files?action=GetDirNew`,ho({path:e,is_operating:!0},n))];case 1:return r=s.sent().message,t&&t(r),i=cc({type:`dir`,list:r.dir,path:r.path}),a=cc({type:`file`,list:r.files,path:r.path}),i=i.map(function(e,t){return _o(ho({},e),{protected:r.tamper_data.dirs&&r.tamper_data.dirs[t]?Number(r.tamper_data.dirs[t].split(`;`)[0]):0,protected_rule:r.tamper_data.dirs&&r.tamper_data.dirs[t]?Number(r.tamper_data.dirs[t].split(`;`)[1]):0})}),a=a.map(function(e,t){return _o(ho({},e),{protected:r.tamper_data.files&&r.tamper_data.files[t]?Number(r.tamper_data.files[t].split(`;`)[0]):0,protected_rule:r.tamper_data.files&&r.tamper_data.files[t]?Number(r.tamper_data.files[t].split(`;`)[1]):0})}),[2,yo(i).concat(yo(a))];case 2:return o=s.sent(),console.warn(o),[2,[]];case 3:return[2]}})})()}function bc(e,t,n,r,i,a){return Z(function(){var o,s,c,l,u,d,f,p,m,h;return Q(this,function(g){switch(g.label){case 0:for(o=[],s=Math.ceil(e.size/n),c=0;c<s;c++)l=c*n,u=Math.min(l+n,e.size),d=e.slice(l,u),f=new FormData,f.append(`f_path`,r),f.append(`f_name`,e.name),f.append(`f_size`,``.concat(e.size)),f.append(`f_start`,``.concat(l)),f.append(`blob`,d),o.push(f);g.label=1;case 1:g.trys.push([1,6,,7]),p=0,g.label=2;case 2:return p<o.length?[4,G.post(t,o[p],{headers:{"Content-Type":`multipart/form-data`},requestOptions:{isOriginalResult:!0}})]:[3,5];case 3:m=g.sent(),typeof m.message==`number`&&a&&a(m),i(Math.round(p/o.length*100),m),g.label=4;case 4:return p++,[3,2];case 5:return i(100,null),[3,7];case 6:return h=g.sent(),console.log(h),[2,Promise.reject({msg:h.message})];case 7:return[2]}})})()}function xc(e,t){return e.filter(function(e){return t.includes(e.nm)})}function Sc(e,t,n){return Z(function(){var r,i,a,o;return Q(this,function(s){switch(s.label){case 0:return r=e.dynamicCmptObj,i=e.dynamicCmpt,a=e.dynamicCmptRef,o=r[t](),[4,o.__asyncLoader()];case 1:return s.sent(),i.value=o,Yi(function(){n&&n(a)}),[2]}})})()}function Cc(e){var t=e.choosedKeys;t.value=[]}function wc(){var e=W(),n=W(`list`),r=W(`/www`),i=W([]),a=W(!1),o=W([]),s=W([]),c=W([]),l=W(),u=W(),d=W(),f=W([]),p=W([]),m=W({url:`http://`,path:r.value,filename:``}),h=W({reference:``,per:0,speed:`0`,used:`0`,except:`--`,total:0}),g=W(!1),_=W([]),v=W({text:``,exts:`html,php`,path:r.value,is_subdir:0,mode:0,isword:0,iscase:1,noword:0});function y(){v.value={text:``,exts:`html,php`,path:r.value,is_subdir:0,mode:0,isword:0,iscase:1,noword:0}}var b=W({}),x=W({files:0,times:0}),S=W([]),C=W([{label:Ea(`file.favoriteListModal.management`),key:`management`,icon:`settings`}]);function w(){C.value=[{label:Ea(`file.favoriteListModal.management`),key:`management`,icon:`settings`}]}var T=W([]),ee=W({back_sub_dir:1,path:``,remark:``}),E=ii,te=ri,ne=Qa,re=Ar,ie={PasteConfirm:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.d})},void 0)})},PasteSingleConfirm:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.u})},void 0)})},UploadFile:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.D})},void 0)})},RemoteDownload:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.w})},void 0)})},SearchFileContent:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.C})},void 0)})},FavoriteList:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.T})},void 0)})},Backup:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.E})},void 0)})},Terminal:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.h})},void 0)})},Softlink:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.S})},void 0)})},Permission:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.l})},void 0)})},Properties:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.s})},void 0)})},Del:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.f})},void 0)})},Compression:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.m})},void 0)})},Decompress:function(){return F(function(){return O(function(){return t.import(`./view-files-legacy.js?v=1795169270504`).then(function(e){return e.p})},void 0)})}},D=xa(null),ae=W(),oe=W(!1),se=W(!1),ce=W([]),le=W(!1),ue=W(!1),de=W(!1),fe=W(!1),pe=W(),me=W(!1),he=A(function(){return i.value.filter(function(e){return gc(e)}).map(function(e){return e.path})}),ge=A(function(){return i.value.filter(function(e){return hc(e.ext)}).map(function(e){return{path:e.path,name:e.nm}})}),_e=W(``),ve=W({path:``,name:``}),ye=W(!1),be=W(!1),xe=W(1),Se=W(0),Ce=W(0),we=W(1),Te=W(100),Ee=function(){try{return JSON.parse(sessionStorage.getItem(`fileSortState`)||`{}`)}catch(e){return{}}}(),De=W(Ee.sort||``),Oe=W(Ee.reverse||`False`),ke=W(0),Ae=W(null),je=W(),Me=W([]),Ne=W(-1),Pe=W(),Fe=W({reqEnd:!1,isSetup:!1,isBuy:!1});function Ie(){return Z(function(){var e;return Q(this,function(t){switch(t.label){case 0:if(Fe.value.reqEnd)return[2];t.label=1;case 1:return t.trys.push([1,3,4,5]),[4,_i({sName:`disk_analysis`})];case 2:return e=t.sent().message,B(e)?(Fe.value={reqEnd:!0,isSetup:e.status&&e.setup&&e.endtime>-1,isBuy:e.endtime>-1},[2]):[3,5];case 3:return t.sent(),[3,5];case 4:return Fe.value.reqEnd=!0,[7];case 5:return[2]}})})()}return{mainRef:e,filesView:n,currentPath:r,fileList:i,tableLoading:a,normalTrList:o,trRectArr:s,choosedKeys:c,tableRef:l,dataTableRef:u,contextRef:d,normalCardList:f,cardRectArr:p,downloadFileFormData:m,downloadProgressData:h,downloadProgressShow:g,resourceManagerWindow:_,searchFileContentFormData:v,resetSearchFileContentFormData:y,searchRes:b,searchStatistics:x,favoriteList:S,favoriteOptions:C,resetFavoriteOptions:w,backupList:T,backupForm:ee,fileOperationFlag:E,fileCopyCache:te,waitForPaste:ne,copiedFile:re,dynamicCmptObj:ie,dynamicCmpt:D,dynamicCmptRef:ae,fileRecycle:oe,menuShow:se,uploadFileList:ce,uploadShow:le,uploadComplete:ue,startUpload:de,fileConflictShow:fe,optionToolsRef:pe,isMiniScreen:me,imgWaitPreview:he,videoWaitPreview:ge,currentPreviewImg:_e,currentPreviewVideo:ve,previewShow:ye,previewVideoShow:be,operationType:xe,directoryCount:Se,fileCount:Ce,page:we,size:Te,sort:De,reverse:Oe,total:ke,currentFile:Ae,choosePathRef:je,diskMountPoint:Me,currentDirSize:Ne,dragUploadRef:Pe,diskAnalysis:Fe,initDiskAnalysis:Ie}}function Tc(e,t){return U(),M(`div`,je,[j(`div`,ht,[j(`div`,Nt,[j(`div`,null,[j(`div`,tn,q(e.$t(`fileEditor.shortcut.common.title`)),1),j(`div`,bn,[j(`div`,In,[t[0]||(t[0]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`S`)],-1)),j(`div`,Zn,q(e.$t(`fileEditor.shortcut.common.saveFile`)),1)]),j(`div`,er,[t[1]||(t[1]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`C`)],-1)),j(`div`,nr,q(e.$t(`fileEditor.shortcut.common.copy`)),1)]),j(`div`,We,[t[2]||(t[2]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`X`)],-1)),j(`div`,Ke,q(e.$t(`fileEditor.shortcut.common.cut`)),1)]),j(`div`,Je,[t[3]||(t[3]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`V`)],-1)),j(`div`,Xe,q(e.$t(`fileEditor.shortcut.common.paste`)),1)]),j(`div`,Ze,[t[4]||(t[4]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`A`)],-1)),j(`div`,Qe,q(e.$t(`fileEditor.shortcut.common.selectAll`)),1)]),j(`div`,$e,[t[5]||(t[5]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`Z`)],-1)),j(`div`,et,q(e.$t(`fileEditor.shortcut.common.undo`)),1)]),j(`div`,tt,[t[6]||(t[6]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`Y`)],-1)),j(`div`,nt,q(e.$t(`fileEditor.shortcut.common.redo`)),1)]),j(`div`,Ct,[t[7]||(t[7]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`F`)],-1)),j(`div`,wt,q(e.$t(`fileEditor.shortcut.common.find`)),1)]),j(`div`,Tt,[t[8]||(t[8]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`H`)],-1)),j(`div`,Et,q(e.$t(`fileEditor.shortcut.common.replace`)),1)]),j(`div`,Dt,[t[9]||(t[9]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Esc`)],-1)),j(`div`,Ot,q(e.$t(`fileEditor.shortcut.common.esc`)),1)])])]),j(`div`,kt,[j(`div`,At,q(e.$t(`fileEditor.shortcut.cursorMove.title`)),1),j(`div`,jt,[t[14]||(t[14]=j(`div`,{class:`flex items-center`},[j(`div`,{class:`flex items-center flex-wrap gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Home`),N(` / `),j(`kbd`,null,`End`),N(` / `),j(`kbd`,null,`Up`),N(` / `),j(`kbd`,null,`Left`),N(` / `),j(`kbd`,null,`Down`),N(` / `),j(`kbd`,null,`Right`)])],-1)),j(`div`,Mt,[t[10]||(t[10]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`Home`),N(` / `),j(`kbd`,null,`End`)],-1)),j(`div`,Gt,q(e.$t(`fileEditor.shortcut.cursorMove.docStartEnd`)),1)]),j(`div`,Kt,[t[11]||(t[11]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`P`)],-1)),j(`div`,qt,q(e.$t(`fileEditor.shortcut.cursorMove.matchingTag`)),1)]),j(`div`,Jt,[t[12]||(t[12]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`PageUp`),N(` / `),j(`kbd`,null,`PageDown`)],-1)),j(`div`,Yt,q(e.$t(`fileEditor.shortcut.cursorMove.pageUpDown`)),1)]),j(`div`,Xt,[t[13]||(t[13]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Alt`),N(` + `),j(`kbd`,null,`Left`),N(` / `),j(`kbd`,null,`Right`)],-1)),j(`div`,Zt,q(e.$t(`fileEditor.shortcut.cursorMove.lineStartEnd`)),1)])])])]),j(`div`,Qt,[j(`div`,null,[j(`div`,$t,q(e.$t(`fileEditor.shortcut.selection.title`)),1),j(`div`,en,[j(`div`,un,[j(`div`,dn,[j(`kbd`,null,q(e.$t(`fileEditor.shortcut.selection.mouseBox`)),1),t[15]||(t[15]=N(` —— `,-1)),j(`kbd`,null,q(e.$t(`fileEditor.shortcut.selection.drag`)),1)])]),t[20]||(t[20]=Rr(`<div class="flex items-center" data-v-38e00b50><div class="flex items-center flex-wrap gap-[6px] min-w-[260px] text-white" data-v-38e00b50><kbd data-v-38e00b50>Shift</kbd> + <kbd data-v-38e00b50>Home</kbd> / <kbd data-v-38e00b50>End</kbd> / <kbd data-v-38e00b50>Up</kbd> / <kbd data-v-38e00b50>Left</kbd> / <kbd data-v-38e00b50>Down</kbd> / <kbd data-v-38e00b50>Right</kbd></div></div>`,1)),j(`div`,fn,[t[16]||(t[16]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Shift`),N(` + `),j(`kbd`,null,`PageUp`),N(` / `),j(`kbd`,null,`PageDown`)],-1)),j(`div`,pn,q(e.$t(`fileEditor.shortcut.selection.pageSelect`)),1)]),j(`div`,mn,[t[17]||(t[17]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`Shift`),N(` + `),j(`kbd`,null,`Home`),N(` / `),j(`kbd`,null,`End`)],-1)),j(`div`,hn,q(e.$t(`fileEditor.shortcut.selection.cursorToStartEnd`)),1)]),j(`div`,gn,[j(`div`,_n,[t[18]||(t[18]=j(`kbd`,null,`Alt`,-1)),t[19]||(t[19]=N(` + `,-1)),j(`kbd`,null,q(e.$t(`fileEditor.shortcut.selection.mouseDrag`)),1)]),j(`div`,vn,q(e.$t(`fileEditor.shortcut.selection.blockSelect`)),1)])])]),j(`div`,yn,[j(`div`,En,q(e.$t(`fileEditor.shortcut.edit.title`)),1),j(`div`,Dn,[j(`div`,On,[t[21]||(t[21]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`/`)],-1)),j(`div`,kn,q(e.$t(`fileEditor.shortcut.edit.toggleComment`)),1)]),j(`div`,An,[t[22]||(t[22]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Tab`)],-1)),j(`div`,jn,q(e.$t(`fileEditor.shortcut.edit.indent`)),1)]),j(`div`,Mn,[t[23]||(t[23]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Shift`),N(` + `),j(`kbd`,null,`Tab`)],-1)),j(`div`,Nn,q(e.$t(`fileEditor.shortcut.edit.outdent`)),1)]),j(`div`,Pn,[t[24]||(t[24]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Delete`)],-1)),j(`div`,Fn,q(e.$t(`fileEditor.shortcut.edit.delete`)),1)]),j(`div`,Vn,[t[25]||(t[25]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`D`)],-1)),j(`div`,Hn,q(e.$t(`fileEditor.shortcut.edit.deleteLine`)),1)]),j(`div`,Un,[t[26]||(t[26]=j(`div`,{class:`flex items-center flex-wrap gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Alt`),N(` + `),j(`kbd`,null,`Shift`),N(` + `),j(`kbd`,null,`Up`),N(` / `),j(`kbd`,null,`Down`)],-1)),j(`div`,Wn,q(e.$t(`fileEditor.shortcut.edit.copyLineUpDown`)),1)]),j(`div`,Gn,[t[27]||(t[27]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Alt`),N(` + `),j(`kbd`,null,`Delete`)],-1)),j(`div`,Kn,q(e.$t(`fileEditor.shortcut.edit.deleteRight`)),1)]),j(`div`,qn,[t[28]||(t[28]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Alt`),N(` + `),j(`kbd`,null,`Up`),N(` / `),j(`kbd`,null,`Down`)],-1)),j(`div`,Jn,q(e.$t(`fileEditor.shortcut.edit.swapLineUpDown`)),1)]),j(`div`,Yn,[t[29]||(t[29]=j(`div`,{class:`flex items-center gap-[6px] min-w-[260px] text-white`},[j(`kbd`,null,`Ctrl`),N(` + `),j(`kbd`,null,`Shift`),N(` + `),j(`kbd`,null,`D`)],-1)),j(`div`,Xn,q(e.$t(`fileEditor.shortcut.edit.copyLineDown`)),1)])])])])])])}return e({$:es,A:void 0,B:cs,C:sc,D:void 0,E:Hs,F:void 0,G:us,H:vs,I:ys,J:as,K:ms,L:ts,M:void 0,N:void 0,O:void 0,P:void 0,Q:is,R:rs,S:Ms,T:Qs,U:ds,V:ls,W:fs,X:hs,Y:void 0,Z:gs,_:Fs,_t:void 0,a:uc,at:void 0,b:Us,c:gc,ct:jo,d:bc,dt:Fo,et:Ko,f:Is,ft:void 0,g:Ys,gt:xo,h:Bs,ht:So,i:xc,it:Ao,j:void 0,k:void 0,l:cc,lt:Bo,m:zs,mt:wo,n:wc,nt:Jo,o:mc,ot:To,p:Ns,pt:Co,q:os,r:Sc,rt:qo,s:vc,st:No,t:void 0,tt:$,u:yc,ut:Yo,v:tc,vt:void 0,w:Ws,x:Vs,y:Zs,z:bs}),{setters:[function(e){ge=e.r,_e=e.a},function(e){S=e._n,Er=e.Ft,A=e.Sn,j=e.Cn,Mr=e.wn,Pr=e.Tn,M=e.En,Rr=e.On,N=e.kn,P=e.An,F=e.jn,I=e.Mn,Si=e.Fn,L=e.gr,R=e.Ln,Ui=e.ln,z=e.Br,Gi=e.yr,Ji=e.Bn,Yi=e.Hn,H=e.$r,Xi=e.ti,Zi=e.Gn,Qi=e.Jn,$i=e.Yn,U=e.Zn,ia=e.Sr,W=e.wr,la=e.$n,va=e.nr,xa=e.Dr,q=e.ii,Fa=e.Or,Ia=e.jr,J=e.Mr,Ba=e.S,Ga=e.sr,qa=e.p,Ya=e.lr,Za=e.pn,$a=e.ur,eo=e.dr,X=e.fr,to=e.pr,no=e.mn,ro=e.hn},function(e){Ur=e.f,wa=e.p,Y=e.l},function(e){l=e._t,u=e.ft,f=e.J,p=e.X,y=e.R,x=e.I,w=e.j,T=e.Tt,ne=e.Q,re=e.et,ie=e.x,D=e.nt,se=e.v,pe=e.s,wr=e.Nt,si=e.Mt},function(e){k=e.Jf,_r=e.qf,vr=e.vn,yr=e.Mf,Cr=e.pn,Tr=e.jn,Dr=e.Rf,jr=e.hn,Qr=e.mp,ci=e.op,hi=e.yp,gi=e.wp,xi=e.i,Ti=e.Yf,Wi=e.Tp,B=e.Op,V=e.Gf,G=e.If,Pa=e.Pf,La=e.en,Ra=e.Bf,za=e.Vf,Ha=e.Oa,Ua=e.Pa,Wa=e.Hf,Ka=e.o,Ja=e.kn,Xa=e.ja},function(e){i=e._a,gr=e.na,xr=e.ra,Sr=e.aa,li=e.ei,_i=e.Ei,na=e.ha,ra=e.va,Ca=e.ti},function(e){Fr=e.Kd,Ir=e.qd,Gr=e.Jd,di=e.cf,fi=e.Xd,mi=e.$d,aa=e.ef,oa=e.tf,ca=e.nf,ya=e.lf,ba=e.rf},function(e){O=e.i,Hi=e.a},function(e){br=e.c},function(e){n=e.t,he=e.l,ua=e.u,da=e.c,fa=e.a,pa=e.o,ma=e.s,ha=e.i,ga=e.r,_a=e.n},function(e){vi=e.o}],execute:function(){ve=document.createElement(`style`),ve.textContent=`.aceBox[data-v-4f3e3417]{border:1px solid var(--site-ace-editor-border);border-radius:4px;width:100%;line-height:1.4}.editor-title[data-v-e102193c]{color:#333;z-index:1;cursor:move;background-color:#fff;justify-content:space-between;align-items:center;height:42px;padding-left:16px;display:flex;position:relative;box-shadow:0 1px 4px rgba(0,0,0,.1)}.editor-title .title-left[data-v-e102193c]{font-size:14px}.editor-title .title-right[data-v-e102193c]{align-items:center;height:100%;display:flex}.editor-title .title-right .action-btn[data-v-e102193c]{cursor:pointer;justify-content:center;align-items:center;width:48px;height:100%;transition:background-color .2s;display:flex}.editor-title .title-right .action-btn div[data-v-e102193c]{color:#555;font-size:18px}.editor-title .title-right .action-btn[data-v-e102193c]:hover{background-color:#e5e5e5}.editor-title .title-right .action-btn.close-btn[data-v-e102193c]:hover{background-color:var(--color-error)}.editor-title .title-right .action-btn.close-btn:hover div[data-v-e102193c]{color:#fff}.toolbar-dialog[data-v-eefb830e]{background-color:#444}.toolbar-dialog .toolbar-title[data-v-eefb830e]{color:#9e9e9e;border-bottom:1px solid #666;padding:12px 16px;font-size:14px}.toolbar-dialog .fontsize-content[data-v-eefb830e]{padding:16px}.toolbar-dialog .fontsize-input[data-v-eefb830e]{flex:1}.toolbar-dialog .fontsize-input[data-v-eefb830e] .n-input{--n-color:transparent;--n-color-focus:transparent;--n-border:1px solid #fff;--n-border-hover:1px solid #fff;--n-border-active:1px solid #fff;--n-border-focus:1px solid #fff;--n-text-color:#fff;--n-caret-color:#fff}.line-ending-select[data-v-9f1abe69]{padding:16px}.line-ending-item[data-v-9f1abe69]{cursor:pointer;--un-text-opacity:1;height:30px;color:rgba(255,255,255,var(--un-text-opacity));justify-content:space-between;align-items:center;font-size:14px;display:flex}.line-ending-item[data-v-9f1abe69]:hover,.line-ending-item.active[data-v-9f1abe69]{background-color:#333}.toolbar-dialog[data-v-a095d4d8]{background-color:#444}.toolbar-dialog .toolbar-title[data-v-a095d4d8]{color:#9e9e9e;border-bottom:1px solid #666;padding:12px 16px;font-size:14px}.toolbar-dialog[data-v-81a9b969]{background-color:#444}.toolbar-dialog .toolbar-title[data-v-81a9b969]{color:#9e9e9e;border-bottom:1px solid #666;padding:12px 16px;font-size:14px}.setting-list[data-v-81a9b969]{padding:16px}.setting-item[data-v-81a9b969]{cursor:pointer;--un-text-opacity:1;height:30px;color:rgba(255,255,255,var(--un-text-opacity));justify-content:space-between;align-items:center;font-size:14px;display:flex}.setting-item[data-v-81a9b969]:hover{background-color:#333}.toolbar-dialog[data-v-4c82ec83]{background-color:#444}.toolbar-dialog .toolbar-title[data-v-4c82ec83]{color:#9e9e9e;border-bottom:1px solid #666;padding:12px 16px;font-size:14px}.toolbar-dialog[data-v-efb6ea19]{background-color:#444}.toolbar-dialog .toolbar-title[data-v-efb6ea19]{color:#9e9e9e;border-bottom:1px solid #666;padding:12px 16px;font-size:14px}.toolbar-dialog[data-v-9ccb6b4e]{background-color:#444}.toolbar-dialog .toolbar-title[data-v-9ccb6b4e]{color:#9e9e9e;border-bottom:1px solid #666;padding:12px 16px;font-size:14px}.toolbar-dialog[data-v-cb231c72]{background-color:#444}.toolbar-dialog .toolbar-title[data-v-cb231c72]{color:#9e9e9e;border-bottom:1px solid #666;padding:12px 16px;font-size:14px}.toolbar-dialog .goto-content[data-v-cb231c72]{padding:16px}.toolbar-dialog .goto-input[data-v-cb231c72]{width:100%}.toolbar-dialog .goto-input[data-v-cb231c72] .n-input{--n-color:transparent;--n-color-focus:transparent;--n-border:1px solid #fff;--n-border-hover:1px solid #fff;--n-border-active:1px solid #fff;--n-border-focus:1px solid #fff;--n-text-color:#fff;--n-caret-color:#fff}.toolbar-dialog .goto-hint[data-v-cb231c72]{color:#fff;margin-top:12px;font-size:14px}.toolbar-wrapper[data-v-0064f6ea]{position:relative}.toolbar-list[data-v-0064f6ea]{color:#fff;background-color:#565656;align-items:center;height:32px;min-height:32px;display:flex}.tools-btn[data-v-0064f6ea]{cursor:pointer;border-right:1px solid #4c4c4c;justify-content:center;align-items:center;gap:4px;height:32px;padding:0 16px;font-size:13px;display:flex;position:relative}.tools-btn[data-v-0064f6ea]:hover{background-color:#2f2f2f}.breadcrumb-wrapper[data-v-0123ab4c]{color:#fff;background-color:#383838;align-items:center;height:40px;padding:0 16px;font-size:14px;display:flex}.action-wrapper[data-v-4b13f5e5]{color:#fff;background-color:#565656;justify-content:space-between;align-items:center;width:100%;height:32px;min-height:32px;display:flex}.action-wrapper.is-search-mode[data-v-4b13f5e5]{height:auto;min-height:auto;display:block}.action-btn[data-v-4b13f5e5]{cursor:pointer;color:#fff;justify-content:center;align-items:center;gap:4px;height:32px;padding:0 8px;font-size:12px;line-height:1.1;transition:all .2s;display:flex;position:relative}.action-btn[data-v-4b13f5e5]:hover{background-color:#2f2f2f}.action-btn i[data-v-4b13f5e5]{font-size:13px}.action-btn i.is-loading[data-v-4b13f5e5]{animation:1s linear infinite rotate-4b13f5e5}@keyframes rotate-4b13f5e5{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.search-panel[data-v-4b13f5e5]{flex-direction:column;padding:12px;display:flex}.search-title[data-v-4b13f5e5]{color:#aaa;justify-content:space-between;align-items:center;margin-bottom:12px;font-size:13px;display:flex}.search-title .close-btn[data-v-4b13f5e5]{color:#f44336;cursor:pointer;align-items:center;gap:4px;display:flex}.search-title .close-btn[data-v-4b13f5e5]:hover{opacity:.8}.search-input-wrap[data-v-4b13f5e5]{margin-bottom:12px}.search-input-wrap[data-v-4b13f5e5] .n-input{--n-text-color:#333;--n-caret-color:#333;--n-border:1px solid transparent;--n-border-hover:1px solid transparent;--n-border-focus:1px solid transparent;--n-padding-right:0;background-color:#fff;border:none;border-radius:4px}.search-input-wrap[data-v-4b13f5e5] .n-input .n-input__suffix{color:#666;align-items:center;height:100%;margin-left:0;display:flex}.search-input-wrap[data-v-4b13f5e5] .n-input .search-icon-btn{cursor:pointer;border-left:1px solid #eee;justify-content:center;align-items:center;height:28px;padding:0 10px;display:flex}.search-input-wrap[data-v-4b13f5e5] .n-input .search-icon-btn:hover{background-color:#f5f5f5}.search-input-wrap[data-v-4b13f5e5] .n-input .search-icon-btn i{font-size:16px}.search-options .n-checkbox[data-v-4b13f5e5]{--n-text-color:#fff;--n-font-size:13px}.share-list-modal[data-v-6846c345]{width:100%;padding:20px}.ftp-storage-demo[data-v-d856ba35]{aspect-ratio:500/510;width:100%;max-width:500px;color:var(--color-text-4);font-size:max(8px,min(1.1vw,10.7px));font-weight:500;position:relative}.ftp-storage-demo[data-v-d856ba35]:before{background:var(--color-modal);content:"";border-radius:16px;position:absolute;top:6.27%;bottom:6.27%;left:.6%;right:.6%;box-shadow:0 22px 52px rgba(39,57,72,.13)}.ftp-storage-demo .surface-header[data-v-d856ba35]{align-items:center;width:98.8%;height:9.02%;padding:0 13px;font-size:1.12em;font-weight:700;display:flex;position:absolute;top:6.27%;left:.6%}.ftp-storage-demo .file-pane[data-v-d856ba35]{border:1px solid var(--color-border);background:var(--color-modal);border-radius:11px;flex-direction:column;width:45.2%;display:flex;position:absolute;top:17.25%;bottom:9.02%;overflow:hidden;box-shadow:0 4px 14px rgba(39,57,72,.043)}.ftp-storage-demo .file-pane.local[data-v-d856ba35]{left:3.2%}.ftp-storage-demo .file-pane.ftp[data-v-d856ba35]{left:51.6%}.ftp-storage-demo .pane-head[data-v-d856ba35]{border-bottom:1px solid var(--color-border);align-items:center;min-height:3.52em;padding:0 12px;font-size:1.17em;font-weight:700;display:flex}.ftp-storage-demo .file-list[data-v-d856ba35]{flex:1;min-height:0}.ftp-storage-demo .table-head[data-v-d856ba35],.ftp-storage-demo .file-row[data-v-d856ba35]{grid-template-columns:18px minmax(0,1fr) 46px;align-items:center;gap:4px;padding:0 8px;display:grid}.ftp-storage-demo .table-head[data-v-d856ba35]>:last-child,.ftp-storage-demo .file-row[data-v-d856ba35]>:last-child{justify-self:center}.ftp-storage-demo .table-head[data-v-d856ba35]{height:2.8em;color:var(--color-text-desc);background:var(--color-bg-1);white-space:nowrap;font-size:.89em}.ftp-storage-demo .file-row[data-v-d856ba35]{border-bottom:1px solid var(--color-border);height:3.64em}.ftp-storage-demo .file-row.selected[data-v-d856ba35]{background:color-mix(in srgb, var(--color-primary) 7%, transparent)}.ftp-storage-demo .file-row.selected .box[data-v-d856ba35],.ftp-storage-demo .file-row.incoming .box[data-v-d856ba35]{border-color:var(--color-primary);background:var(--color-primary)}.ftp-storage-demo .file-row.selected .box i[data-v-d856ba35],.ftp-storage-demo .file-row.incoming .box i[data-v-d856ba35]{opacity:1}.ftp-storage-demo .file-row.incoming .box[data-v-d856ba35]{border-radius:50%}.ftp-storage-demo .file-row.editing .file-name[data-v-d856ba35]{border:1px solid var(--color-primary);box-shadow:0 0 0 2px color-mix(in srgb, var(--color-primary) 10%, transparent);border-radius:4px;padding:2px 5px}.ftp-storage-demo .file-row.editing .file-name[data-v-d856ba35]:after{border-right:1px solid var(--color-primary);vertical-align:middle;content:"";height:1.2em;margin-left:1px;animation:.72s step-end infinite caret-blink-d856ba35;display:inline-block}.ftp-storage-demo .header-check[data-v-d856ba35],.ftp-storage-demo .box[data-v-d856ba35]{border:1px solid var(--color-border);background:var(--color-modal);color:#fff;border-radius:3px;place-items:center;width:14px;height:14px;padding:0;display:grid}.ftp-storage-demo .header-check i[data-v-d856ba35],.ftp-storage-demo .box i[data-v-d856ba35]{opacity:0;font-size:11px}.ftp-storage-demo .header-check[data-v-d856ba35]{cursor:pointer}.ftp-storage-demo .header-check.checked[data-v-d856ba35]{border-color:var(--color-primary);background:var(--color-primary)}.ftp-storage-demo .header-check.checked i[data-v-d856ba35]{opacity:1}.ftp-storage-demo .file-main[data-v-d856ba35]{align-items:center;gap:6px;min-width:0;display:flex}.ftp-storage-demo .file-main>i[data-v-d856ba35]{flex-shrink:0;font-size:1.68em}.ftp-storage-demo .file-name[data-v-d856ba35]{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.ftp-storage-demo .row-action[data-v-d856ba35]{width:22px;height:22px;color:var(--color-primary);cursor:pointer;background:0 0;border:0;border-radius:4px;place-items:center;padding:0;display:grid}.ftp-storage-demo .pane-footer[data-v-d856ba35]{border-top:1px solid var(--color-border);align-items:center;min-height:4.48em;padding:0 10px;display:flex}.ftp-storage-demo .send-button[data-v-d856ba35]{background:var(--color-primary);color:#fff;height:3.06em;font:inherit;cursor:pointer;border:0;border-radius:5px;padding:0 11px;font-size:.92em;font-weight:600}.ftp-storage-demo .send-button.is-clicked[data-v-d856ba35]{box-shadow:0 0 0 5px color-mix(in srgb, var(--color-primary) 12%, transparent)}.ftp-storage-demo .transfer-layer[data-v-d856ba35]{z-index:3;pointer-events:none;width:39.6%;height:66px;position:absolute;top:54%;left:50%;transform:translate(-50%,-50%)}.ftp-storage-demo .transfer-layer.right .transfer-file[data-v-d856ba35]{animation:1.1s ease-in-out forwards file-to-right-d856ba35;left:3px}.ftp-storage-demo .transfer-layer.left .transfer-file[data-v-d856ba35]{animation:1.1s ease-in-out forwards file-to-left-d856ba35;right:3px}.ftp-storage-demo .transfer-line[data-v-d856ba35]{background:color-mix(in srgb, var(--color-primary) 25%, var(--color-modal));height:3px;box-shadow:0 0 0 6px var(--color-modal);position:absolute;top:32px;left:17px;right:17px}.ftp-storage-demo .transfer-file[data-v-d856ba35]{border:1px solid color-mix(in srgb, var(--color-primary) 25%, var(--color-border));background:var(--color-modal);white-space:nowrap;border-radius:9px;align-items:center;gap:7px;height:41px;padding:0 12px;font-weight:600;display:flex;position:absolute;top:12px;box-shadow:0 10px 26px rgba(32,116,51,.2)}.ftp-storage-demo .transfer-file i[data-v-d856ba35]{font-size:18px}.ftp-storage-demo .demo-cursor[data-v-d856ba35]{z-index:4;fill:#fff;stroke:#263344;stroke-width:1.6px;stroke-linejoin:round;filter:drop-shadow(0 3px 3px rgba(25,35,45,.22));pointer-events:none;width:25px;height:30px;transition:left .3s,top .3s;position:absolute}.ftp-storage-demo .demo-cursor.clicking[data-v-d856ba35]{transform:scale(.88)}.ftp-storage-demo button[data-v-d856ba35]:focus-visible{outline:2px solid var(--color-primary);outline-offset:2px}@media not (min-width:500px){.ftp-storage-demo .table-head[data-v-d856ba35],.ftp-storage-demo .file-row[data-v-d856ba35]{grid-template-columns:14px minmax(0,1fr) 35px;gap:2px;padding:0 4px}.ftp-storage-demo .pane-head[data-v-d856ba35]{padding:0 8px}.ftp-storage-demo .pane-footer[data-v-d856ba35]{padding:0 6px}.ftp-storage-demo .send-button[data-v-d856ba35]{padding:0 7px}}@media (prefers-reduced-motion:reduce){.ftp-storage-demo[data-v-d856ba35] *,.ftp-storage-demo[data-v-d856ba35] :after{transition:none!important;animation:none!important}}@keyframes file-to-right-d856ba35{0%{transform:translate(0)scale(.94)}to{transform:translate(70%)scale(.96)}}@keyframes file-to-left-d856ba35{0%{transform:translate(0)scale(.94)}to{transform:translate(-70%)scale(.96)}}@keyframes caret-blink-d856ba35{0%,48%{opacity:1}49%,to{opacity:0}}.tree-wrapper[data-v-f79b7cfa]{background-color:#222;flex:1;overflow:hidden}.n-tree[data-v-f79b7cfa]{--n-node-text-color:#ccc;--n-node-color-hover:#37373d;--n-node-color-active:transparent;--n-arrow-color:#ccc;--n-loading-color:#ccc;--n-line-height:1.2;--n-bezier:cubic-bezier(.4, 0, .2, 1);--n-font-size:13px;background-color:transparent;height:100%;padding:6px;overflow:auto}.n-tree[data-v-f79b7cfa] .n-tree-node{border-radius:4px}.n-tree[data-v-f79b7cfa] .n-tree-node.n-tree-node--selected:hover{background-color:var(--n-node-color-hover)}.n-tree[data-v-f79b7cfa] .n-tree-node .tree-icon{align-items:center;font-size:16px;font-style:normal;display:inline-flex}.n-tree[data-v-f79b7cfa] .n-tree-node .n-tree-node-content__text{border-bottom:none;width:0}.n-tree[data-v-f79b7cfa] .n-tree-node .n-tree-node-content{padding:0}.n-tree[data-v-f79b7cfa] .n-tree-node .creating-node{align-items:center;width:100%;display:flex}.n-tree[data-v-f79b7cfa] .n-tree-node .creating-node .creating-input{color:#000;background-color:#fff;border:1px solid #4caf50;border-radius:2px;outline:none;flex:1;width:120px;height:22px;padding:0 4px;line-height:22px}.n-tree[data-v-f79b7cfa] .n-tree-node .creating-node i{cursor:pointer;margin-left:4px;font-size:16px;font-weight:700}.sidebar-wrapper[data-v-c942a726]{flex-shrink:0;width:260px;height:100%;transition:width .3s cubic-bezier(.25,.8,.25,1);position:relative}.sidebar-wrapper.is-collapsed[data-v-c942a726]{width:0}.sidebar-wrapper.is-collapsed .sidebar-content[data-v-c942a726]{display:none}.sidebar-wrapper.is-collapsed .toggle-btn[data-v-c942a726]:after{margin-left:-7px;transform:rotate(45deg)}.sidebar-content[data-v-c942a726]{background-color:#2f2f2f;flex-direction:column;width:260px;height:100%;display:flex;overflow:hidden}.toggle-btn[data-v-c942a726]{cursor:pointer;z-index:998;background-color:#222;border:1px solid #525252;border-left:none;border-radius:0 9999px 9999px 0;justify-content:center;align-items:center;width:14px;height:50px;transition:all .2s;display:flex;position:absolute;top:40%;right:-14px}.toggle-btn[data-v-c942a726]:hover{background-color:#888}.toggle-btn[data-v-c942a726]:after{content:"";border-top:2px solid #fff;border-bottom:none;border-left:none;border-right:2px solid #fff;width:10px;height:10px;margin-left:2px;display:block;transform:rotate(-135deg)}.editor-header-wrapper[data-v-59f49b3b]{--un-bg-opacity:1;background-color:rgba(0,0,0,var(--un-bg-opacity));width:100%;height:40px;overflow:hidden}.editor-header[data-v-59f49b3b]{align-items:center;height:40px;display:flex}[data-v-59f49b3b] .n-scrollbar{--n-scrollbar-color:#444;--n-scrollbar-color-hover:#444}.editor-tab[data-v-59f49b3b]{cursor:pointer;--un-text-opacity:1;max-width:300px;height:100%;color:rgba(153,153,153,var(--un-text-opacity));border-right:1px solid #222;flex-shrink:0;align-items:center;padding-left:10px;padding-right:36px;font-size:15px;display:flex;position:relative}.editor-tab[data-v-59f49b3b]:hover,.editor-tab.active[data-v-59f49b3b]{--un-bg-opacity:1;background-color:rgba(34,34,34,var(--un-bg-opacity));--un-text-opacity:1;color:rgba(236,236,236,var(--un-text-opacity))}.editor-tab.active[data-v-59f49b3b]:before{content:"";background-color:var(--color-primary);height:2px;position:absolute;top:0;left:0;right:0}.editor-tab .tab-close[data-v-59f49b3b]{position:absolute;right:10px}.editor-tab .tab-dirty[data-v-59f49b3b]{background-color:#f4c26b;border-radius:50%;width:8px;height:8px;position:absolute;top:50%;right:10px;transform:translateY(-50%)}.editor-tab .tree-icon[data-v-59f49b3b]{align-items:center;margin-right:4px;font-size:16px;font-style:normal;display:inline-flex}.ace-editor[data-v-cd594c09] .ace_scrollbar::-webkit-scrollbar{width:14px;height:10px}.ace-editor[data-v-cd594c09] .ace_scrollbar::-webkit-scrollbar-thumb{background:#777;border-radius:0;box-shadow:inset 0 0 5px rgba(0,0,0,.2)}.ace-editor[data-v-cd594c09] .ace_scrollbar::-webkit-scrollbar-track{background:#333;border-radius:0;box-shadow:inset 0 0 5px rgba(0,0,0,.2)}.file-history[data-v-1701a30e]{width:550px;padding:20px}.editor-footer[data-v-f3c99d32]{--un-bg-opacity:1;background-color:rgba(86,86,86,var(--un-bg-opacity));--un-text-opacity:1;height:36px;color:rgba(255,255,255,var(--un-text-opacity));justify-content:space-between;align-items:center;gap:16px;padding-left:16px;padding-right:16px;font-size:14px;display:flex}.editor-footer .footer-path[data-v-f3c99d32]{flex:1;min-width:0;max-width:50%}.editor-footer .footer-tools[data-v-f3c99d32]{align-items:center;height:100%;display:flex}.editor-footer .footer-item[data-v-f3c99d32]{cursor:pointer;border-right:1px solid #4c4c4c;align-items:center;height:100%;padding-left:16px;padding-right:16px;display:flex}.editor-footer .footer-item[data-v-f3c99d32]:hover{background-color:#2f2f2f}.editor-footer .readonly-badge[data-v-f3c99d32]{cursor:default;background-color:#eb7c20;border-right:none}.editor-footer .readonly-badge[data-v-f3c99d32]:hover{background-color:#eb7c20}.editor-footer.diff-footer[data-v-f3c99d32]{color:#fff;background-color:#eb7c20}.editor-footer.diff-footer .footer-tools .footer-item[data-v-f3c99d32]{background-color:transparent;border-right:none}.editor-footer.diff-footer .footer-tools .footer-item[data-v-f3c99d32]:hover{background-color:transparent}.editor-footer.diff-footer .diff-path[data-v-f3c99d32]{max-width:80%}.ace-diff-container[data-v-3cd40f25]{width:100%;height:100%}.ace-diff-container[data-v-3cd40f25] .ace_scrollbar::-webkit-scrollbar{width:14px;height:10px}.ace-diff-container[data-v-3cd40f25] .ace_scrollbar::-webkit-scrollbar-thumb{background:#777;border-radius:0;box-shadow:inset 0 0 5px rgba(0,0,0,.2)}.ace-diff-container[data-v-3cd40f25] .ace_scrollbar::-webkit-scrollbar-track{background:#333;border-radius:0;box-shadow:inset 0 0 5px rgba(0,0,0,.2)}.ace-diff-container[data-v-3cd40f25] .acediff__gutter{background-color:#333}.ace-diff-container[data-v-3cd40f25] .acediff__left .ace_content{background-color:rgba(255,0,0,.05)}.ace-diff-container[data-v-3cd40f25] .acediff__right .ace_content{background-color:rgba(0,255,0,.05)}kbd[data-v-38e00b50]{--un-border-opacity:1;border-width:1px;border-color:rgba(119,119,119,var(--un-border-opacity));--un-text-opacity:1;color:rgba(255,255,255,var(--un-text-opacity));background-color:transparent;border-style:solid;border-radius:2px;padding:4px 10px;font-family:inherit;font-size:13px;line-height:1;display:inline-block}.editor-container[data-v-615a4f3c]{color:#fff;background-color:#292929;flex-direction:column;height:100%;display:flex}.editor-body[data-v-615a4f3c]{flex:1;display:flex;overflow:hidden} /*$vite$:1*/`,document.head.appendChild(ve),R(),z(),L(),da(),ma(),pa(),fa(),ha(),ga(),_a(),Ie={style:{color:`var(--ace-editor-tip-color)`}},mt={key:0,class:`w-140px`},Ni=I({__name:`index`,props:Ji({height:{default:`100%`},showTips:{type:Boolean,default:!0},showEncoding:{type:Boolean,default:!1},lang:{default:`nginx`},theme:{default:`chrome`},init:{type:Boolean,default:!1},readOnly:{type:Boolean,default:!1},load:{type:Boolean,default:!1}},{path:{default:``},pathModifiers:{},value:{default:``},valueModifiers:{},encoding:{default:`utf-8`},encodingModifiers:{}}),emits:Ji([`saved`],[`update:path`,`update:value`,`update:encoding`]),setup:function(e,t){var n=t.expose,r=t.emit,i=Pa(),a=wa(i).theme,o=e,s=r,c=Ga(e,`path`),l=Ga(e,`value`),u=Ga(e,`encoding`),d=W({wrap:!0,showInvisibles:!1,showPrintMargin:!1,showFoldWidgets:!1,useSoftTabs:!0,tabSize:2,readOnly:o.readOnly}),f=[{label:`utf-8`,value:`utf-8`},{label:`GBK`,value:`GBK`},{label:`GB2312`,value:`GB2312`},{label:`BIG5`,value:`BIG5`}],p=function(e){(e.ctrlKey||e.metaKey)&&e.keyCode===83&&!o.readOnly&&(e.preventDefault(),v())},m=Ua(),h=m.loading,g=m.setLoading,_=function(){return Z(function(){var e;return Q(this,function(t){switch(t.label){case 0:return t.trys.push([0,,3,4]),g(!0),[4,Yi()];case 1:return t.sent(),[4,di({path:c.value})];case 2:return e=t.sent().message,B(e)&&(l.value=e.data,u.value=e.encoding),[3,4];case 3:return g(!1),[7];case 4:return[2]}})})()},v=function(){return Z(function(){var e,t;return Q(this,function(n){switch(n.label){case 0:return c.value===``?[2]:[4,ya({path:c.value,data:l.value,encoding:u.value})];case 1:return e=n.sent(),t=e.message,B(t)&&V.success(t.msg),s(`saved`,l.value),[2]}})})()};return o.init&&_(),n({getContent:_,saveFile:v}),function(t,n){var r=D,i=y,o=se;return U(),M(`div`,null,[e.showTips?(U(),Mr(i,{key:0,class:`items-center mb-8px`,justify:`space-between`},{default:X(function(){return[j(`div`,Ie,q(t.$t(`Component.Editor.index_1`)),1),e.showEncoding?(U(),M(`div`,mt,[P(r,{value:u.value,"onUpdate:value":n[0]||(n[0]=function(e){return u.value=e}),options:f},null,8,[`value`])])):Pr(``,!0)]}),_:1})):Pr(``,!0),P(o,{class:`h-full`,show:e.load||J(h)},{default:X(function(){return[P(J(he),{class:`aceBox`,value:l.value,"onUpdate:value":n[1]||(n[1]=function(e){return l.value=e}),lang:e.lang,theme:J(a)===`dark`?`monokai`:e.theme,options:J(d),style:Xi({height:J(si)(e.height)}),onKeydown:p},null,8,[`value`,`lang`,`theme`,`options`,`style`])]}),_:1},8,[`show`])])}}}),e(`vt`,ge({default:function(){return pr}})),e(`_t`,pr=k(Ni,[[`__scopeId`,`data-v-4f3e3417`]])),Hr={supportedModes:{Apache_Conf:[`^htaccess|^htgroups|^htpasswd|^conf|htaccess|htgroups|htpasswd`],CSS:[`css`],HTML:[`html|htm|xhtml|vue|we|wpy`],Java:[`java`],JavaScript:[`js|jsm|jsx`],JSON:[`json`],JSP:[`jsp`],Makefile:[`^Makefile|^GNUmakefile|^makefile|^OCamlMakefile|make`],Markdown:[`md|markdown`],MySQL:[`mysql`],Nginx:[`nginx|conf`],PHP:[`php|inc|phtml|shtml|php3|php4|php5|phps|phpt|aw|ctp|module`],Powershell:[`ps1`],Python:[`py`],SQL:[`sql`],SQLServer:[`sqlserver`],Text:[`txt`],XML:[`xml|rdf|rss|wsdl|xslt|atom|mathml|mml|xul|xbl|xaml`],YAML:[`yaml|yml`],images:[`icon|jpg|jpeg|png|bmp|gif|tif|emf`]},nameOverrides:{PHP_Laravel_blade:`PHP (Blade Template)`},encodingList:[`ASCII`,`UTF-8`,`GBK`,`GB2312`,`BIG5`],themeList:[`chrome`,`monokai`,`tomorrow_night_bright`],aceEditor:{editorTheme:`monokai`,fontSize:14,lineHeight:1.5,softLabel:!1,useSoftTabs:!0,tabSize:4,wrap:!0,indentedSoftWrap:!0,enableSnippets:!0,enableLiveAutocompletion:!0,enableBasicAutocompletion:!0,highlightActiveLine:!0,highlightSelectedWord:!0,animatedScroll:!1,showInvisibles:!0,showFoldWidgets:!0,showLineNumbers:!0,showGutter:!0,displayIndentGuides:!1},fontFamily:`'Consolas', 'Menlo', 'Monaco', 'Ubuntu Mono', 'source-code-pro', 'Courier New', monospace`,encoding:`utf-8`},L(),R(),r=`/www/server/panel/BTPanel/static/ace/ace.editor.config.json`,ar=Ti.global,Na=ar.t,Va=Ur(`fileEditor`,function(){var e=W(!1),t=W(!1),n=W(null),i=W({show:!1,type:null,data:{}}),a=W([]),o=W(-1),s=W(`/www`),c=W(0),l=W(!1),u=W(!1),d=W(Er(Hr)),f=W(null),p=W(!1),m=W(``),h=W(!1),g=A(function(){return o.value>=0&&o.value<a.value.length?a.value[o.value]:null}),_=function(e){var t=e.split(`/`).pop()||Na(`fileEditor.store.untitled`);return{path:e,type:e.split(`.`).pop()||`text`,name:t,loading:!1,lineEnding:`LF`,content:``,originalContent:``,encoding:``,st_mtime:0,onlyRead:!1,history:[]}},v=function(e){return Z(function(){var t,n,r,i,s,c;return Q(this,function(l){switch(l.label){case 0:return t=a.value.findIndex(function(t){return t.path===e}),t===-1?[4,fi({path:e})]:(o.value=t,[2]);case 1:return n=l.sent(),r=n.message,B(r)&&(i=_(e),s=o.value+1,a.value.splice(s,0,i),o.value=s,c=a.value[s],c.content=r.data,c.originalContent=r.data,c.encoding=r.encoding,c.st_mtime=Number(r.st_mtime),c.onlyRead=r.only_read,c.history=r.historys||[],c.onlyRead&&V.warning(Na(`fileEditor.store.fileTooLarge`))),[2]}})})()},y=function(){var e=`__shortcut__`,t=a.value.findIndex(function(t){return t.path===e});if(t!==-1)o.value=t;else{var n={path:e,type:`shortcut`,name:Na(`fileEditor.store.shortcutTabName`),loading:!1,lineEnding:`LF`,content:``,originalContent:``,encoding:`UTF-8`,st_mtime:0,onlyRead:!1,history:[]},r=o.value+1;a.value.splice(r,0,n),o.value=r}},b=function(e,t){return Z(function(){var n,r,i,s,c,l,u,d,f,p,m,h;return Q(this,function(g){switch(g.label){case 0:if(n=e.split(`/`).pop()||`Untitled`,r=`__diff__`.concat(e,`__`,t),i=a.value.findIndex(function(e){return e.path===r}),i!==-1)return o.value=i,[2];s={path:r,type:`diff`,name:``.concat(n,` <-> `,n),loading:!0,lineEnding:`LF`,content:``,originalContent:``,encoding:`UTF-8`,st_mtime:0,onlyRead:!0,history:[],originalPath:e,historyTime:t},c=o.value+1,a.value.splice(c,0,s),o.value=c,g.label=1;case 1:return g.trys.push([1,3,,4]),[4,Promise.all([fi({path:e}),aa({filename:e,history:t})])];case 2:return d=vo.apply(void 0,[g.sent(),2]),f=d[0],p=d[1],m=a.value[o.value],f.message&&B(f.message)&&(m.rightContent=f.message.data,m.encoding=f.message.encoding),p.message&&B(p.message),m.leftContent=typeof p.message==`string`?p.message:(l=(u=p.message)==null?void 0:u.data)==null?``:l,m.loading=!1,[3,4];case 3:return g.sent(),h=a.value[o.value],h&&(h.loading=!1),[3,4];case 4:return[2]}})})()},x=function(e){return Z(function(){var t,n,r;return Q(this,function(i){switch(i.label){case 0:return[4,fi({path:e})];case 1:return t=i.sent().message,B(t)&&(n=a.value.findIndex(function(t){return t.path===e}),n!==-1&&(r=a.value[n],r.content=t.data,r.originalContent=t.data,r.encoding=t.encoding,r.st_mtime=Number(t.st_mtime),r.history=t.historys||[])),[2]}})})()},S=function(){return Z(function(){return Q(this,function(e){switch(e.label){case 0:return g.value&&g.value.type!==`shortcut`?[4,x(g.value.path)]:[3,2];case 1:e.sent(),e.label=2;case 2:return[2]}})})()},C=function(e){a.value.splice(e,1),o.value>=a.value.length&&(o.value=Math.max(0,a.value.length-1)),a.value.length===0&&(o.value=-1)},w=function(e,t){var n=a.value[e];n&&(n.content=t)},T=function(e){s.value=e},ee=function(){var e=s.value,t=e.lastIndexOf(`/`);s.value=t>0?e.substring(0,t):`/`},E=function(){c.value++},te=function(e){p.value=e,e||(m.value=``,E())},ne=function(e,t){m.value=e,h.value=t,E()},re=function(e){l.value=e},ie=function(e){u.value=e},D=function(){return Z(function(){var e,t;return Q(this,function(n){switch(n.label){case 0:return[4,fi({path:r})];case 1:return e=n.sent().message,B(e)&&(t=JSON.parse(e.data),Object.assign(d.value,ho({},Hr,t))),[2]}})})()},ae=function(){return Z(function(){return Q(this,function(e){switch(e.label){case 0:return[4,ba({data:JSON.stringify({supportedModes:d.value.supportedModes,nameOverrides:d.value.nameOverrides,encodingList:d.value.encodingList,themeList:d.value.themeList,aceEditor:d.value.aceEditor,fontFamily:d.value.fontFamily,encoding:d.value.encoding}),path:r,encoding:d.value.encoding||`UTF-8`,force:1})];case 1:return e.sent(),[2]}})})()},oe=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;return new Promise(function(r,i){return Z(function(){var o,s,c,l;return Q(this,function(u){switch(u.label){case 0:if(o=a.value[e],o.type===`shortcut`)return r(),[2];u.label=1;case 1:return u.trys.push([1,3,,4]),[4,ba({data:o.content,path:o.path,encoding:o.encoding,st_mtime:o.st_mtime,force:0},t)];case 2:return s=u.sent(),c=s.message,B(c)&&(c.status?(o.originalContent=o.content,o.history=c.historys||[],o.st_mtime=Number(c.st_mtime),n&&V.success(c.msg),r()):za({title:Na(`fileEditor.store.conflictTitle`),content:c.result||Na(`fileEditor.store.conflictContentFallback`),confirmText:Na(`fileEditor.store.forceSave`),confirmType:`warning`,onConfirm:function(){return Z(function(){var e,t,a;return Q(this,function(s){switch(s.label){case 0:return s.trys.push([0,2,,3]),[4,ba({data:o.content,path:o.path,encoding:o.encoding,st_mtime:o.st_mtime,force:1},!0)];case 1:return e=s.sent(),t=e.message,B(t)&&(o.originalContent=o.content,o.history=t.historys||[],o.st_mtime=Number(t.st_mtime),n&&V.success(t.msg),r()),[3,3];case 2:return a=s.sent(),i(a),[3,3];case 3:return[2]}})})()},onCancel:function(){return i(Error(`User cancelled override.`))}})),[3,4];case 3:return l=u.sent(),i(l),[3,4];case 4:return[2]}})})()})},se=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;return Z(function(){return Q(this,function(r){switch(r.label){case 0:return[4,oe(e,t,n)];case 1:return r.sent(),C(e),[2]}})})()},ce=function(){return Z(function(){return Q(this,function(e){switch(e.label){case 0:return!g.value||g.value.content===g.value.originalContent?[2]:[4,oe(o.value)];case 1:return e.sent(),[2]}})})()},le=function(){return Z(function(){var e,t;return Q(this,function(n){switch(n.label){case 0:e=V.loading(Na(`fileEditor.store.saveAllLoading`)),n.label=1;case 1:return n.trys.push([1,,4,5]),t=a.value.map(function(e,t){return e.content!==e.originalContent&&e.type!==`shortcut`?oe(t,!1,!1):null}).filter(Boolean),t.length>0?[4,Promise.all(t)]:[3,3];case 2:n.sent(),V.success(Na(`fileEditor.store.saveAllSuccess`)),n.label=3;case 3:return[3,5];case 4:return e.close(),[7];case 5:return[2]}})})()},ue=function(e,t){return t===`CRLF`?e.replace(/\r?\n/g,`\r `):t===`LF`?e.replace(/\r\n/g,` `):e};return{isOpen:e,isMinimize:t,unminimize:n,toolsModal:i,currentPath:s,fileList:a,currentFileIndex:o,currentFile:g,refreshKey:c,isLoading:l,isListLoading:u,editorConfig:d,creatingType:f,isSearchMode:p,searchWord:m,searchAll:h,openFile:v,openShortcutTab:y,openDiffTab:b,closeTab:C,updateTabContent:w,setCurrentPath:T,goToParent:ee,refreshFileList:E,setLoading:re,setListLoading:ie,getEditorConfig:D,saveEditorConfig:ae,saveFileContent:oe,saveFileContentAndClose:se,saveCurrentFileContent:ce,saveAllFile:le,getFileContent:x,changeLineEnding:function(e){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return!g.value||g.value.type===`shortcut`?[2]:(g.value.content=ue(g.value.content,e),[4,ce()]);case 1:return t.sent(),g.value.lineEnding=e,[2]}})})()},changeEncoding:function(e){return Z(function(){var t;return Q(this,function(n){switch(n.label){case 0:return!g.value||g.value.type===`shortcut`?[2]:(t=g.value.path,d.value.aceEditor.encoding=e,[4,ae()]);case 1:return n.sent(),g.value.encoding=e,[4,oe(o.value,!0,!0)];case 2:return n.sent(),x(t),[2]}})})()},changeTheme:function(e){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return d.value.aceEditor.editorTheme=e,[4,ae()];case 1:return t.sent(),[2]}})})()},toggleSetting:function(e){return Z(function(){var t;return Q(this,function(n){switch(n.label){case 0:return t=d.value.aceEditor,t[e]=!t[e],[4,ae()];case 1:return n.sent(),[2]}})})()},updateTabSettings:function(e,t){return Z(function(){return Q(this,function(n){switch(n.label){case 0:return d.value.aceEditor.useSoftTabs=e!==`tab`,d.value.aceEditor.tabSize=t,[4,ae()];case 1:return n.sent(),V.success(Na(`fileEditor.store.tabSettingsRefreshed`)),[2]}})})()},getCurrentFileContent:S,startCreateNewItem:function(e){f.value=e},cancelCreateNewItem:function(){f.value=null},confirmCreateNewItem:function(e){return Z(function(){var t;return Q(this,function(n){switch(n.label){case 0:return e.trim()?(t=f.value,t===`file`?[4,Ir({path:``.concat(s.value,`/`,e)})]:[3,2]):(V.warning(Na(`fileEditor.store.nameRequired`)),[2]);case 1:return n.sent(),[3,4];case 2:return t===`folder`?[4,Fr({path:``.concat(s.value,`/`,e)})]:[3,4];case 3:n.sent(),n.label=4;case 4:return V.success(Na(`fileEditor.store.createSuccess`,{type:Na(t===`file`?`fileEditor.store.newFile`:`fileEditor.store.newFolder`)})),f.value=null,E(),[2]}})})()},toggleSearchMode:te,executeSearch:ne,openToolsModal:function(e,t){i.value={show:!0,type:e,data:t||{}}},closeToolsModal:function(){i.value={show:!1,type:null,data:{}}}}}),R(),z(),L(),Fe={class:`title-left`},pt={class:`title-right`},It=[`title`],ln=[`title`],Tn={key:0,class:`i-ant-design-switcher-outlined`},Bn={key:1,class:`i-ant-design-border-outlined`},$n=[`title`],Mi=I({__name:`index`,props:{isMinimize:{type:Boolean},isMaximize:{type:Boolean}},emits:[`minimize`,`maximize`,`close`],setup:function(e,t){var n=t.emit,r=e,i=n,a=Va(),o=W(null),s=function(){i(`minimize`);var e=!r.isMinimize;o.value&&Yi(function(){var t=gi(o.value,`n-dialog`);if(t){if(!e)t.style.left=``,t.style.top=``;else{var n=document.documentElement.clientHeight,r=t.offsetHeight,i=216,a=n-r-68,s=parseFloat(t.style.left)||0,c=parseFloat(t.style.top)||0;t.style.left=``.concat(s+i-t.offsetLeft,`px`),t.style.top=``.concat(c+a-t.offsetTop,`px`)}}})},c=function(){i(`maximize`),!r.isMaximize&&o.value&&Yi(function(){var e=gi(o.value,`n-dialog`);e&&(e.style.left=``,e.style.top=``)})},l=function(){i(`close`)};return Qi(function(){a.unminimize=function(){r.isMinimize&&s()}}),$i(function(){a.unminimize=null}),function(t,n){var r=va(`modal-drag`);return to((U(),M(`div`,{ref_key:`titleRef`,ref:o,class:`editor-title`},[j(`div`,Fe,[j(`span`,null,q(t.$t(`fileEditor.title.onlineTextEditor`)),1)]),j(`div`,pt,[!e.isMaximize&&!e.isMinimize?(U(),M(`div`,{key:0,class:`action-btn`,title:t.$t(`fileEditor.title.minimize`),onClick:s},yo(n[1]||(n[1]=[j(`div`,{class:`i-ant-design-minus-outlined`},null,-1)])),8,It)):Pr(``,!0),j(`div`,{class:`action-btn`,title:e.isMinimize?t.$t(`fileEditor.title.restore`):e.isMaximize?t.$t(`fileEditor.title.restoreDown`):t.$t(`fileEditor.title.maximize`),onClick:n[0]||(n[0]=function(t){return e.isMinimize?s():c()})},[e.isMinimize||e.isMaximize?(U(),M(`div`,Tn)):(U(),M(`div`,Bn))],8,ln),j(`div`,{class:`action-btn close-btn`,onClick:l,title:t.$t(`fileEditor.title.close`)},yo(n[2]||(n[2]=[j(`div`,{class:`i-ant-design-close-outlined`},null,-1)])),8,$n)])])),[[r]])}}}),ue=k(Mi,[[`__scopeId`,`data-v-e102193c`]]),R(),z(),L(),Ui(),Pe={class:`toolbar-dialog`},ft={class:`toolbar-title`},Ft={class:`fontsize-content flex items-center gap-16px`},ji=I({__name:`index`,props:{currentSize:{type:Number,default:14},onChange:{type:Function}},emits:[`close`],setup:function(e,t){var n=t.emit,r=e,i=n,a=W(r.currentSize),o=W(null),s=function(){var e=Number(a.value);if(!isNaN(e)&&e>0){var t;(t=r.onChange)==null||t.call(r,e),i(`close`)}};return Qi(function(){var e;(e=o.value)==null||e.focus()}),function(e,t){var n=w,r=l;return U(),M(`div`,Pe,[j(`div`,ft,q(e.$t(`fileEditor.dialogs.fontSizeTitle`)),1),j(`div`,Ft,[P(n,{ref_key:`inputRef`,ref:o,value:J(a),"onUpdate:value":t[0]||(t[0]=function(e){return Gi(a)?a.value=e:null}),"show-button":!1,class:`fontsize-input`,onKeyup:no(s,[`enter`])},null,8,[`value`]),P(r,{type:`primary`,class:`fontsize-btn`,onClick:s},{default:X(function(){return[N(q(e.$t(`fileEditor.common.save`)),1)]}),_:1})])])}}}),b=k(ji,[[`__scopeId`,`data-v-eefb830e`]]),R(),z(),Ne={class:`line-ending-select`},dt=[`onClick`],Wt={key:0,class:`i-fa6-solid-check`},te=I({__name:`LineSelect`,props:{value:{type:[String,Number,Array],default:``},options:{type:Array,default:function(){return[]}},onUpdateValue:[Function,Array],"onUpdate:value":[Function,Array]},setup:function(e){var t=e,n=function(e,n){var r=t.onUpdateValue,i=t[`onUpdate:value`];r&&wr(r,e,n),i&&wr(i,e,n)};return function(t,r){return U(),M(`div`,Ne,[(U(!0),M(S,null,la(e.options,function(t){return U(),M(`div`,{key:t.value,class:H([`line-ending-item`,{active:e.value===t.value}]),onClick:function(e){return n(t.value,t)}},[j(`span`,null,q(t.label),1),e.value===t.value?(U(),M(`i`,Wt)):Pr(``,!0)],10,dt)}),128))])}}}),E=k(te,[[`__scopeId`,`data-v-9f1abe69`]]),R(),z(),L(),Me={class:`toolbar-dialog`},ut={class:`toolbar-title`},Ai=I({__name:`index`,props:{theme:{type:String,default:`monokai`},onChange:{type:Function}},setup:function(e){var t=Y().t,n=Va(),r=wa(n).editorConfig,i=e,a=W(i.theme||`monokai`),o=A(function(){return{chrome:t(`fileEditor.dialogs.theme.chrome`),monokai:t(`fileEditor.dialogs.theme.monokai`)}}),s=A(function(){return r.value.themeList.map(function(e){return{label:o.value[e]||e,value:e}})}),c=function(e){var t;(t=i.onChange)==null||t.call(i,e)};return function(e,t){return U(),M(`div`,Me,[j(`div`,ut,q(e.$t(`fileEditor.dialogs.themeTitle`)),1),P(E,{value:J(a),"onUpdate:value":[t[0]||(t[0]=function(e){return Gi(a)?a.value=e:null}),c],options:J(s)},null,8,[`value`,`options`])])}}}),le=k(Ai,[[`__scopeId`,`data-v-a095d4d8`]]),R(),z(),Ae={class:`toolbar-dialog`},lt={class:`toolbar-title`},Ut={class:`setting-list`},cn=[`onClick`],wn={key:0,class:`i-fa6-solid-check`},ki=I({__name:`index`,setup:function(e){var t=Y().t,n=Va(),r=wa(n).editorConfig,i=A(function(){return r.value.aceEditor}),a=A(function(){return[{key:`wrap`,label:t(`fileEditor.dialogs.setting.wrap`)},{key:`enableLiveAutocompletion`,label:t(`fileEditor.dialogs.setting.enableLiveAutocompletion`)},{key:`enableSnippets`,label:t(`fileEditor.dialogs.setting.enableSnippets`)},{key:`showInvisibles`,label:t(`fileEditor.dialogs.setting.showInvisibles`)},{key:`showLineNumbers`,label:t(`fileEditor.dialogs.setting.showLineNumbers`)}]}),o=function(e){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return[4,n.toggleSetting(e)];case 1:return t.sent(),[2]}})})()};return function(e,t){return U(),M(`div`,Ae,[j(`div`,lt,q(e.$t(`fileEditor.dialogs.settingTitle`)),1),j(`div`,Ut,[(U(!0),M(S,null,la(a.value,function(e){return U(),M(`div`,{key:e.key,class:`setting-item`,onClick:function(t){return o(e.key)}},[j(`span`,null,q(e.label),1),i.value[e.key]?(U(),M(`i`,wn)):Pr(``,!0)],8,cn)}),128))])])}}}),ae=k(ki,[[`__scopeId`,`data-v-81a9b969`]]),R(),z(),L(),ke={class:`toolbar-dialog`},ct={class:`toolbar-title`},Vi=I({__name:`index`,props:{fileName:{type:String,default:``},lineEnding:{type:String,default:`LF`},onChange:{type:Function}},emits:[`close`],setup:function(e,t){var n=t.emit,r=e,i=Y().t,a=n,o=W(r.lineEnding),s=[{label:`CRLF`,value:`CRLF`},{label:`LF`,value:`LF`}],c=function(e){za({title:i(`fileEditor.dialogs.lineEndingChangeTitle`),confirmText:i(`fileEditor.common.save`),content:function(){return P(S,null,[P(`div`,null,[i(`fileEditor.dialogs.lineEndingChangeContent1`,{file:r.fileName||``,from:o.value,to:e})]),P(`div`,{class:`mt-8px`},[i(`fileEditor.dialogs.lineEndingChangeContent2`,{save:i(`fileEditor.common.save`)})])])},onConfirm:function(){return Z(function(){var t;return Q(this,function(n){switch(n.label){case 0:return[4,(t=r.onChange)==null?void 0:t.call(r,e)];case 1:return n.sent(),a(`close`),[2]}})})()}})};return function(e,t){return U(),M(`div`,ke,[j(`div`,ct,q(e.$t(`fileEditor.dialogs.lineEndingTitle`)),1),P(E,{value:J(o),options:s,"onUpdate:value":c},null,8,[`value`])])}}}),ee=k(Vi,[[`__scopeId`,`data-v-4c82ec83`]]),R(),z(),L(),Oe={class:`toolbar-dialog`},st={class:`toolbar-title`},Ht={class:`toolbar-title`},Bi=I({__name:`index`,props:{useSoftTabs:{type:String,default:`tab`},tabSize:{type:Number,default:4},onChange:{type:Function}},setup:function(e){var t=Y().t,n=e,r=W(n.useSoftTabs),i=W(n.tabSize),a=A(function(){return[{label:t(`fileEditor.dialogs.tabSize.useSpaces`),value:`space`},{label:t(`fileEditor.dialogs.tabSize.useTabs`),value:`tab`}]}),o=[{label:`1`,value:1},{label:`2`,value:2},{label:`3`,value:3},{label:`4`,value:4},{label:`5`,value:5},{label:`6`,value:6}],s=function(){l()},c=function(){l()},l=function(){var e;(e=n.onChange)==null||e.call(n,r.value,i.value)};return function(e,t){return U(),M(`div`,Oe,[j(`div`,st,q(e.$t(`fileEditor.dialogs.tabSizeTitle`)),1),P(E,{value:J(r),"onUpdate:value":[t[0]||(t[0]=function(e){return Gi(r)?r.value=e:null}),s],options:J(a)},null,8,[`value`,`options`]),j(`div`,Ht,q(e.$t(`fileEditor.dialogs.tabSizeLengthTitle`)),1),P(E,{value:J(i),"onUpdate:value":[t[1]||(t[1]=function(e){return Gi(i)?i.value=e:null}),c],options:o},null,8,[`value`])])}}}),ce=k(Bi,[[`__scopeId`,`data-v-efb6ea19`]]),R(),z(),L(),De={class:`toolbar-dialog`},ot={class:`toolbar-title`},zi=I({__name:`index`,props:{encoding:{type:String,default:`UTF-8`},onChange:{type:Function}},setup:function(e){var t,n=Va(),r=wa(n).editorConfig,i=e,a=W(((t=i.encoding)==null?void 0:t.toUpperCase())||`UTF-8`),o=A(function(){return r.value.encodingList.map(function(e){return{label:e.toUpperCase(),value:e.toUpperCase()}})}),s=function(e){var t;(t=i.onChange)==null||t.call(i,e)};return function(e,t){return U(),M(`div`,De,[j(`div`,ot,q(e.$t(`fileEditor.dialogs.encodingTitle`)),1),P(E,{value:J(a),"onUpdate:value":[t[0]||(t[0]=function(e){return Gi(a)?a.value=e:null}),s],options:J(o)},null,8,[`value`,`options`])])}}}),m=k(zi,[[`__scopeId`,`data-v-9ccb6b4e`]]),R(),z(),L(),Ui(),Ee={class:`toolbar-dialog`},at={class:`toolbar-title`},Vt={class:`goto-content`},sn={class:`goto-hint`},Ri=I({__name:`index`,props:{currentLine:{type:Number,default:1},currentColumn:{type:Number,default:1},maxLine:{type:Number,default:1},onChange:{type:Function}},emits:[`close`],setup:function(e,t){var n=t.expose,r=t.emit,i=e,a=r,o=W(i.currentLine),s=W(null),c=function(){var e=Number(o.value);if(!isNaN(e)&&e>=1&&e<=i.maxLine){var t;(t=i.onChange)==null||t.call(i,e),a(`close`)}};return Qi(function(){var e;(e=s.value)==null||e.focus()}),n({onClose:function(){a(`close`)}}),function(t,n){return U(),M(`div`,Ee,[j(`div`,at,q(t.$t(`fileEditor.dialogs.goToLineTitle`)),1),j(`div`,Vt,[P(J(w),{value:o.value,"onUpdate:value":n[0]||(n[0]=function(e){return o.value=e}),ref_key:`inputRef`,ref:s,"show-button":!1,class:`goto-input`,placeholder:``,onKeydown:no(c,[`enter`])},null,8,[`value`]),j(`div`,sn,q(t.$t(`fileEditor.dialogs.goToLineHint`,{line:e.currentLine,column:e.currentColumn,max:e.maxLine})),1)])])}}}),C=k(Ri,[[`__scopeId`,`data-v-cb231c72`]]),R(),L(),z(),Te={class:`toolbar-list`},St=[`onClick`],Li=I({__name:`index`,emits:[`action`],setup:function(e,t){var n=t.emit,r=Y().t,i=Va(),a=wa(i),o=a.editorConfig,s=a.toolsModal,c=Ya(`toolbarWrapperRef`),l=A(function(){var e;return(e=c.value)==null?void 0:e}),u=A(function(){switch(s.value.type){case`fontSize`:return b;case`theme`:return le;case`setting`:return ae;case`lineEnding`:return ee;case`tabSize`:return ce;case`encoding`:return m;case`goToLine`:return C;default:return}}),d=A(function(){switch(s.value.type){case`fontSize`:return{currentSize:Number(o.value.aceEditor.fontSize),onChange:g};case`theme`:return{theme:o.value.aceEditor.editorTheme,onChange:_};case`setting`:return{};case`lineEnding`:case`tabSize`:case`encoding`:case`goToLine`:return s.value.data;default:return{}}}),f=A(function(){return[{key:`save`,label:r(`fileEditor.toolbar.save`),icon:`i-ep-select`},{key:`saveAll`,label:r(`fileEditor.toolbar.saveAll`),icon:`i-ep-document-copy`},{key:`refresh`,label:r(`fileEditor.toolbar.refresh`),icon:`i-ep-refresh-right`},{key:`search`,label:r(`fileEditor.toolbar.search`),icon:`i-ep-search`},{key:`replace`,label:r(`fileEditor.toolbar.replace`),icon:`i-ep-document`},{key:`goToLine`,label:r(`fileEditor.toolbar.jumpLine`),icon:`i-ep-location`},{key:`fontSize`,label:r(`fileEditor.toolbar.fontSize`),icon:`i-ep-monitor`},{key:`theme`,label:r(`fileEditor.toolbar.theme`),icon:`i-ep-operation`},{key:`setting`,label:r(`fileEditor.toolbar.setting`),icon:`i-ep-setting`},{key:`shortcut`,label:r(`fileEditor.toolbar.shortcut`),icon:`i-ep-question-filled`}]}),p=function(e){switch(e){case`save`:i.saveCurrentFileContent();break;case`saveAll`:i.saveAllFile();break;case`refresh`:h();break;case`search`:case`replace`:n(`action`,e);break;case`goToLine`:n(`action`,e);break;case`fontSize`:case`theme`:case`setting`:i.openToolsModal(e);break;case`shortcut`:i.openShortcutTab()}},h=function(){return Z(function(){var e;return Q(this,function(t){switch(t.label){case 0:e=V.loading(r(`fileEditor.toolbar.refreshing`)),t.label=1;case 1:return t.trys.push([1,,3,4]),[4,i.getCurrentFileContent()];case 2:return t.sent(),V.success(r(`fileEditor.toolbar.refreshed`)),[3,4];case 3:return e.close(),[7];case 4:return[2]}})})()},g=function(e){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return o.value.aceEditor.fontSize=e,[4,i.saveEditorConfig()];case 1:return t.sent(),V.success(r(`fileEditor.toolbar.fontSizeSaved`)),i.closeToolsModal(),[2]}})})()},_=function(e){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return[4,i.changeTheme(e)];case 1:return t.sent(),i.closeToolsModal(),[2]}})})()};return function(e,t){var n=yr;return U(),M(`div`,{ref_key:`toolbarWrapperRef`,ref:c,class:`toolbar-wrapper`},[j(`div`,Te,[(U(!0),M(S,null,la(J(f),function(e){return U(),M(`div`,{key:e.key,class:`tools-btn`,onClick:function(t){return p(e.key)}},[j(`i`,{class:H(e.icon)},null,2),j(`span`,null,q(e.label),1)],8,St)}),128))]),P(n,{show:J(s).show,"onUpdate:show":t[0]||(t[0]=function(e){return J(s).show=e}),component:J(u),data:J(d),to:J(l),width:420,footer:!1,"show-mask":!1,"hide-close":!0,"mask-closable":!0},null,8,[`show`,`component`,`data`,`to`])],512)}}}),de=k(Li,[[`__scopeId`,`data-v-0064f6ea`]]),R(),z(),L(),we={class:`breadcrumb-wrapper`},xt={class:`flex-1 w-0`},c=I({__name:`Breadcrumb`,setup:function(e){var t=Va(),n=wa(t).currentPath;return function(e,t){var r=p;return U(),M(`div`,we,[j(`div`,null,q(e.$t(`fileEditor.fileExplorer.directory`))+`:`,1),j(`div`,xt,[P(r,null,{default:X(function(){return[N(q(J(n)),1)]}),_:1})])])}}}),s=k(c,[[`__scopeId`,`data-v-0123ab4c`]]),Ta={Apache_Conf:[`^htaccess|^htgroups|^htpasswd|^conf|htaccess|htgroups|htpasswd`],BatchFile:[`bat|cmd`],C_Cpp:[`cpp|c|cc|cxx|h|hh|hpp|ino`],CSharp:[`cs`],CSS:[`css`],Dockerfile:[`^Dockerfile`],golang:[`go`],HTML:[`html|htm|xhtml|vue|we|wpy`],Java:[`java`],JavaScript:[`js|jsm|jsx`],JSON:[`json`],JSP:[`jsp`],LESS:[`less`],Lua:[`lua`],Makefile:[`^Makefile|^GNUmakefile|^makefile|^OCamlMakefile|make`],Markdown:[`md|markdown`],MySQL:[`mysql`],Nginx:[`nginx|conf`],INI:[`ini|conf|cfg|prefs`],ObjectiveC:[`m|mm`],Perl:[`pl|pm`],Perl6:[`p6|pl6|pm6`],pgSQL:[`pgsql`],PHP_Laravel_blade:[`blade.php`],PHP:[`php|inc|phtml|shtml|php3|php4|php5|phps|phpt|aw|ctp|module`],Powershell:[`ps1`],Python:[`py`],R:[`r`],Ruby:[`rb|ru|gemspec|rake|^Guardfile|^Rakefile|^Gemfile`],Rust:[`rs`],SASS:[`sass`],SCSS:[`scss`],SH:[`sh|bash|^.bashrc`],SQL:[`sql`],SQLServer:[`sqlserver`],Swift:[`swift`],Text:[`txt`],Typescript:[`ts|typescript|str`],VBScript:[`vbs|vb`],Verilog:[`v|vh|sv|svh`],XML:[`xml|rdf|rss|wsdl|xslt|atom|mathml|mml|xul|xbl|xaml`],YAML:[`yaml|yml`],Compress:[`tar|zip|7z|rar|gz|arj|z`],images:[`icon|jpg|jpeg|png|bmp|gif|tif|emf`]},Nr=function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:300,t=new Map;return function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:`default`,r,i=Date.now();return i-((r=t.get(n))==null?-1/0:r)<e?!1:(t.set(n,i),!0)}},pi=function(e){var t=e.match(/\.([0-9A-z]*)$/),n=Array.isArray(t)?t[1]:`text`;for(var r in Ta)for(var i=Ta[r][0].split(`|`),a=r.toLowerCase(),o=0;o<i.length;o++)if(n.toLowerCase()==i[o].toLowerCase())return{name:r,mode:a};return{name:`Text`,mode:`text`}},R(),L(),z(),Ui(),Ce={class:`action-btn`},bt={key:1,class:`search-panel`},Bt={class:`search-title`},on={class:`title-text`},Cn={class:`search-input-wrap`},zn={class:`search-options`},o=I({__name:`Action`,setup:function(e){var t=Y().t,n=Va(),r=wa(n),i=r.isLoading,a=r.creatingType,o=r.isListLoading,s=function(e){return function(){return Si(`i`,{class:[`tree-icon`,e],style:`font-size: 16px; font-style: normal; display: inline-flex; align-items: center;`})}},c=A(function(){return[{label:t(`fileEditor.fileExplorer.newFolder`),key:`folder`,icon:s(`folder-icon`)},{label:t(`fileEditor.fileExplorer.newFile`),key:`file`,icon:s(`text-icon`)}]}),l=function(e){n.startCreateNewItem(e)},d=Nr(400),p=function(){if(!o.value&&d()){var e=n.currentPath,t=e.substring(0,e.lastIndexOf(`/`))||`/`;n.setCurrentPath(t===``?`/`:t)}},m=function(){n.refreshFileList()},h=W(n.searchWord),g=W(n.searchAll),_=function(){h.value=n.searchWord,g.value=n.searchAll,n.toggleSearchMode(!0)},v=function(){n.toggleSearchMode(!1),h.value=``,g.value=!1},y=function(){n.executeSearch(h.value,g.value)};return function(e,t){var r=f,o=T,s=u;return U(),M(`div`,{class:H([`action-wrapper`,{"is-search-mode":J(n).isSearchMode}])},[J(n).isSearchMode?(U(),M(`div`,bt,[j(`div`,Bt,[j(`span`,on,q(e.$t(`fileEditor.fileExplorer.searchPanelTitle`)),1),j(`span`,{class:`close-btn`,onClick:v},[t[5]||(t[5]=j(`i`,{class:`i-ep-close`},null,-1)),N(` `+q(e.$t(`fileEditor.fileExplorer.close`)),1)])]),j(`div`,Cn,[P(o,{value:J(h),"onUpdate:value":t[0]||(t[0]=function(e){return Gi(h)?h.value=e:null}),placeholder:e.$t(`fileEditor.fileExplorer.searchPlaceholder`),onKeydown:no(y,[`enter`])},{suffix:X(function(){return[j(`div`,{class:`search-icon-btn`,onClick:y},yo(t[6]||(t[6]=[j(`i`,{class:`i-ep-search`},null,-1)])))]}),_:1},8,[`value`,`placeholder`])]),j(`div`,zn,[P(s,{checked:J(g),"onUpdate:checked":t[1]||(t[1]=function(e){return Gi(g)?g.value=e:null})},{default:X(function(){return[N(q(e.$t(`fileEditor.fileExplorer.includeSubdir`)),1)]}),_:1},8,[`checked`])])])):(U(),M(S,{key:0},[j(`div`,{class:`action-btn`,onClick:p},[t[2]||(t[2]=j(`i`,{class:`i-ep-top`},null,-1)),j(`span`,null,q(e.$t(`fileEditor.fileExplorer.up`)),1)]),j(`div`,{class:`action-btn`,onClick:m},[j(`i`,{class:H([`i-ep-refresh-right`,{"is-loading":J(i)}])},null,2),j(`span`,null,q(e.$t(`fileEditor.fileExplorer.refresh`)),1)]),P(r,{trigger:`click`,disabled:J(a)!==null,options:J(c),placement:`bottom`,"show-arrow":!0,"arrow-point-to-center":!0,onSelect:l},{default:X(function(){return[j(`div`,Ce,[t[3]||(t[3]=j(`i`,{class:`i-ep-plus`},null,-1)),j(`span`,null,q(e.$t(`fileEditor.fileExplorer.new`)),1)])]}),_:1},8,[`disabled`,`options`]),j(`div`,{class:`action-btn`,onClick:_},[t[4]||(t[4]=j(`i`,{class:`i-ep-search`},null,-1)),j(`span`,null,q(e.$t(`fileEditor.fileExplorer.search`)),1)])],64))],2)}}}),a=k(o,[[`__scopeId`,`data-v-4b13f5e5`]]),L(),R(),Hi(),e(`ft`,ea=function(e,t){var n=Va();n.isOpen?(n.openFile(e),n.unminimize&&n.unminimize()):Wa({width:`1440px`,height:`80vh`,bgColor:`transparent`,hideClose:!0,showMask:!1,data:{filePath:e,currentPath:t},component:F(function(){return O(function(){return Promise.resolve().then(function(){return g})},void 0)})})}),R(),L(),Hi(),Vr=Ba(function(e){return Ko(e)},100),or=Ti.global,Ma=or.t,e(`at`,Ba(function(e,t){var n=e.choosedKeys;if(t.type==`dir`)n.value=[t.nm],Ws(e);else return},200)),ir=Ti.global,ja=ir.t,bi=function(e){return G.post(`/files?action=get_download_url_list`,e)},Lr=function(e){return G.post(`/files?action=create_download_url`,e,{requestOptions:{loading:ja(`file.shareModal.creatingShareLink`)}})},sa=function(e){return G.post(`/files?action=remove_download_url`,e,{requestOptions:{loading:ja(`file.shareModal.deletingShare`),successMessage:!0}})},yi=function(e){return G.post(`/files?action=get_download_url_find`,e)},R(),L(),Se={class:`share-list-modal`},yt={class:`flex justify-end items-center mb-10px`},zt={class:`mt-10px flex justify-end items-center`},Ii=I({__name:`index`,props:{fileStore:{}},setup:function(e){var t=e,n=Y().t,r=A(function(){return t.fileStore}),i=W([]),a=W(``),o=W(1),s=W(12),c=W(0),l=W(!1),u=function(){return Z(function(){var e,t;return Q(this,function(n){switch(n.label){case 0:return n.trys.push([0,,2,3]),l.value=!0,e=a.value.trim(),[4,bi(ho({p:o.value,row:s.value},e?{filename:e}:{}))];case 1:return t=n.sent().message,i.value=t.data,c.value=hi(t.page),[3,3];case 2:return l.value=!1,[7];case 3:return[2]}})})()};function d(){o.value=1,Yi(function(){u()})}var f=W([{key:`ps`,title:n(`file.shareListModal.shareName`)},{key:`filename`,title:n(`file.shareListModal.shareAddress`)},{key:`expire`,title:n(`file.shareListModal.expirationDate`),render:function(e){return ci(e.expire)}},La({width:120,options:function(e){return[{label:n(`Public.Btn.Details`),onClick:function(){m(e)}},{label:n(`Public.Btn.Delete`),onClick:function(){p(e)}}]}})]);function p(e){var t=r.value;za({title:n(`file.shareListModal.cancelShareTitle`),content:n(`file.shareListModal.cancelShareMessage`,{filename:e.filename}),onConfirm:function(){return Z(function(){return Q(this,function(n){switch(n.label){case 0:return[4,sa({id:e.id})];case 1:return n.sent(),t?[4,$(t)]:[3,3];case 2:n.sent(),n.label=3;case 3:return[4,u()];case 4:return n.sent(),[2]}})})()}})}function m(e){return Z(function(){return Q(this,function(t){return Qo(e,r.value),[2]})})()}return Qi(u),function(e,t){var r=br,p=xr,m=Sr;return U(),M(`section`,Se,[j(`div`,yt,[P(r,{value:J(a),"onUpdate:value":t[0]||(t[0]=function(e){return Gi(a)?a.value=e:null}),width:`240`,clearable:``,placeholder:J(n)(`file.shareListModal.searchPlaceholder`),onSearch:d,onClear:d},null,8,[`value`,`placeholder`])]),P(p,{loading:J(l),data:J(i),columns:J(f)},null,8,[`loading`,`data`,`columns`]),j(`div`,zt,[P(m,{page:J(o),"onUpdate:page":t[1]||(t[1]=function(e){return Gi(o)?o.value=e:null}),"page-size":J(s),"onUpdate:pageSize":t[2]||(t[2]=function(e){return Gi(s)?s.value=e:null}),"item-count":J(c),"show-size-picker":!1,"show-quick-jumper":!1,onRefresh:u},null,8,[`page`,`page-size`,`item-count`])])])}}}),Sa=k(Ii,[[`__scopeId`,`data-v-6846c345`]]),R(),L(),z(),xe={class:`p-20px`},Yr=I({__name:`details`,props:{detail:{},fileStore:{}},emits:[`close`],setup:function(e,t){var n=t.expose,r=t.emit,i=e,a=r,o=Y().t,s=``.concat(window.location.origin,`/down/`),c=A(function(){return i.fileStore}),u=i.detail,d=W({filename:``,ps:``,token:``,expire:``,total:0,password:``,addtime:0,id:0});function f(e){return!!(e.filename&&e.ps&&e.token)}function p(e){d.value={filename:e.filename,ps:e.ps,token:e.token,expire:ci(e.expire),total:e.total,password:e.password,addtime:e.addtime,id:e.id}}function m(e){return Z(function(){var t;return Q(this,function(n){switch(n.label){case 0:return[4,yi({id:e})];case 1:return t=n.sent().message,p(t),[2]}})})()}function h(){u&&(f(u)?p(u):u.id&&m(u.id))}h();function g(){return Z(function(){return Q(this,function(e){return za({title:o(`file.shareModal.cancelSharing`),content:o(`file.shareModal.confirmStopSharing`,{filename:d.value.filename}),onConfirm:function(){return Z(function(){return Q(this,function(e){switch(e.label){case 0:return[4,sa({id:d.value.id})];case 1:return e.sent(),a(`close`),c.value&&$(c.value),[2]}})})()}}),[2,!1]})})()}var _=A(function(){return``.concat(s,d.value.token)});function v(){jr(_.value)}function y(){jr(o(`file.shareModal.linkAndCode`,{link:_.value,code:d.value.password}))}return n({onConfirm:g}),function(e,t){var n=T,r=x,i=_r,a=l,s=gr,c=Cr;return U(),M(`div`,xe,[P(s,null,{default:X(function(){return[P(r,{label:J(o)(`file.shareModal.shareName`)},{default:X(function(){return[P(n,{value:J(d).ps,"onUpdate:value":t[0]||(t[0]=function(e){return J(d).ps=e})},null,8,[`value`])]}),_:1},8,[`label`]),P(r,{label:J(o)(`file.shareModal.shareChain`)},{default:X(function(){return[P(n,{class:`mr-10px`,readonly:!0,value:J(_)},null,8,[`value`]),P(a,{type:`primary`,onClick:v},{icon:X(function(){return[P(i,{name:`common-copy`,size:`16`})]}),_:1})]}),_:1},8,[`label`]),J(d).password?(U(),Mr(r,{key:0,label:J(o)(`file.shareModal.extractionCode`)},{default:X(function(){return[P(n,{class:`mr-10px`,value:``.concat(J(d).password),readonly:``},null,8,[`value`]),P(a,{type:`primary`,onClick:y},{default:X(function(){return[N(q(J(o)(`file.shareModal.copyLinkAndCode`)),1)]}),_:1})]}),_:1},8,[`label`])):Pr(``,!0),P(r,{label:J(o)(`file.shareModal.expirationDate`)},{default:X(function(){return[N(q(J(d).expire),1)]}),_:1},8,[`label`])]}),_:1}),P(c,null,{default:X(function(){return[j(`li`,null,q(J(o)(`file.shareModal.securityTip`)),1)]}),_:1})])}}}),Jr=Yr,R(),L(),z(),Ue={class:`p-20px`},Br=I({__name:`create`,props:{file:{},fileStore:{}},setup:function(e,t){var n=t.expose,r=e,i=Y().t,a=A(function(){return r.fileStore}),o=r.file,s=W({filename:(o==null?void 0:o.path)||``,ps:(o==null?void 0:o.nm)||``,password:``,expire:24});function c(){return Z(function(){var e;return Q(this,function(t){switch(t.label){case 0:return[4,Lr(Fa(s.value))];case 1:return e=t.sent().message,B(e)?(Qo(e,a.value),a.value&&$(a.value),[2]):[2,!1]}})})()}function u(){s.value.password=vi(8)}return n({onConfirm:c}),function(e,t){var n=T,r=x,a=re,o=ne,c=l,d=gr,f=Cr;return U(),M(`div`,Ue,[P(d,null,{default:X(function(){return[P(r,{label:J(i)(`file.shareModal.shareName`)},{default:X(function(){return[P(n,{value:J(s).ps,"onUpdate:value":t[0]||(t[0]=function(e){return J(s).ps=e})},null,8,[`value`])]}),_:1},8,[`label`]),P(r,{label:J(i)(`file.shareModal.expirationDate`)},{default:X(function(){return[P(o,{value:J(s).expire,"onUpdate:value":t[1]||(t[1]=function(e){return J(s).expire=e})},{default:X(function(){return[P(a,{value:24},{default:X(function(){return[N(q(J(i)(`file.shareModal.aDay`)),1)]}),_:1}),P(a,{value:168},{default:X(function(){return[N(q(J(i)(`file.shareModal.aWeek`)),1)]}),_:1}),P(a,{value:1130800},{default:X(function(){return[N(q(J(i)(`file.shareModal.permanent`)),1)]}),_:1})]}),_:1},8,[`value`])]}),_:1},8,[`label`]),P(r,{label:J(i)(`file.shareModal.extractionCode`)},{default:X(function(){return[P(n,{value:J(s).password,"onUpdate:value":t[2]||(t[2]=function(e){return J(s).password=e})},null,8,[`value`]),P(c,{class:`ml-10px`,type:`primary`,onClick:u},{default:X(function(){return[N(q(J(i)(`file.shareModal.random`)),1)]}),_:1})]}),_:1},8,[`label`])]}),_:1}),P(f,null,{default:X(function(){return[j(`li`,null,q(J(i)(`file.shareModal.securityTip`)),1)]}),_:1})])}}}),zr=Br,sr=Ti.global,Aa=sr.t,R(),Hi(),cr=Ti.global,ka=cr.t,e(`Y`,ta=function(e){Sc(e,`FavoriteList`,function(e){e.value.open()})}),R(),lr=Ti.global,Oa=lr.t,e(`F`,Wr=function(e,t){return e.fileRecycle.value?qr(e,t):Kr(e,t)}),qr=function(e,t){return new Promise(function(n){var r=e.currentPath,i=e.choosedKeys,a=e.fileList,o=t||a.value.filter(function(e){return i.value.includes(e.nm)});za({title:o.length===1?Oa(`file.deleteController.deleteSingleFileTitle`,{name:o[0].nm}):Oa(`file.deleteController.batchDeleteTitle`),content:Oa(`file.deleteController.recycleBinMessage`),width:400,onConfirm:function(){return Z(function(){var i,a;return Q(this,function(s){switch(s.label){case 0:return o.length===1?[4,xs(o[0].path,o[0].type)]:[3,2];case 1:return s.sent(),[3,4];case 2:return i=r.value,t&&o.length>0&&(a=o[0].path.lastIndexOf(`/`),a!==-1&&(i=o[0].path.substring(0,a))),[4,Ss(o.map(function(e){return e.nm}),i)];case 3:s.sent(),s.label=4;case 4:return $(e),n(),[2]}})})()}})})},Kr=function(e,t){return new Promise(function(n){var r=e.currentPath,i=e.choosedKeys,a=e.fileList,o=t||a.value.filter(function(e){return i.value.includes(e.nm)});Ra({title:o.length===1?Oa(`file.deleteController.deleteSingleFileTitle`,{name:o[0].nm}):Oa(`file.deleteController.batchDeleteTitle`),content:function(){return P(`span`,{class:`text-error`},[Oa(`file.deleteController.permanentDeleteMessage`)])},width:400,onConfirm:function(){return Z(function(){var i,a;return Q(this,function(s){switch(s.label){case 0:return o.length===1?[4,xs(o[0].path,o[0].type)]:[3,2];case 1:return s.sent(),[3,4];case 2:return i=r.value,t&&o.length>0&&(a=o[0].path.lastIndexOf(`/`),a!==-1&&(i=o[0].path.substring(0,a))),[4,Ss(o.map(function(e){return e.nm}),i)];case 3:s.sent(),s.label=4;case 4:return $(e),n(),[2]}})})()}})})},e(`P`,kr={ftp:{key:`ftp`,labelKey:`file.contextMenu.cloudStorage.ftp`,icon:`/static/img/soft_ico/ico-ftp.png`,defaultPath:`/`,capabilities:{canUpload:!0,canCreateFolder:!0,canSearch:!0,canDelete:!0}},aws_s3:{key:`aws_s3`,labelKey:`file.contextMenu.cloudStorage.awsS3`,icon:`/static/img/soft_ico/ico-aws_s3.png`,defaultPath:`/`,capabilities:{canUpload:!0,canCreateFolder:!0,canSearch:!0,canDelete:!0}},gdrive:{key:`gdrive`,labelKey:`file.contextMenu.cloudStorage.gdrive`,icon:`/static/img/soft_ico/ico-gdrive.png`,defaultPath:`/`,capabilities:{canUpload:!0,canCreateFolder:!0,canSearch:!0,canDelete:!1}},gcloud_storage:{key:`gcloud_storage`,labelKey:`file.contextMenu.cloudStorage.gcloudStorage`,icon:`/static/img/soft_ico/ico-gcloud_storage.png`,defaultPath:`/`,capabilities:{canUpload:!0,canCreateFolder:!0,canSearch:!0,canDelete:!1}}}),ur=Ti.global,Da=ur.t,ui=function(){return G.post(`/mod/cloud_storage/cloud_storage/GetProviders`)},e(`A`,function(e){return G.post(`/mod/cloud_storage/cloud_storage/List`,e)}),e(`D`,function(e){return G.post(`/mod/cloud_storage/cloud_storage/CreateFolder`,e,{requestOptions:{loading:Da(`file.buttonGroup.loading.creatingDirectory`),successMessage:!0}})}),e(`O`,function(e){return G.post(`/mod/cloud_storage/cloud_storage/Delete`,_o(ho({},e),{items:JSON.stringify(e.items)}),{requestOptions:{loading:Da(`file.deleteController.deletingSingle`)}})}),e(`N`,function(e){var t;return G.post(`/mod/cloud_storage/cloud_storage/UploadLocal`,_o(ho({},e),{local_paths:JSON.stringify(e.local_paths),background:(t=e.background)==null||t}),{requestOptions:{loading:Da(`file.uploadModal.statusUploading`)}})}),e(`M`,function(e,t){return G.post(`/mod/cloud_storage/cloud_storage/file_upload`,e,{headers:{"Content-Type":`multipart/form-data`},onUploadProgress:function(e){t==null||t(e)}})}),e(`k`,function(e){var t,n;return G.post(`/mod/cloud_storage/cloud_storage/DownloadToLocal`,_o(ho({},e),{items:JSON.stringify(e.items),background:(t=e.background)==null||t}),{requestOptions:{loading:Da(`file.uploadModal.statusUploading`),successMessage:!((n=e.background)==null||n)}})}),e(`j`,function(){return G.post(`/mod/cloud_storage/cloud_storage/TaskStatus`)}),R(),z(),L(),Ui(),He={class:`ftp-storage-demo`},vt={class:`surface-header`},Rt={class:`pane-head`},an={class:`file-list`},Sn={class:`table-head`},Rn=[`aria-checked`,`aria-label`,`onClick`],Qn={class:`file-main`},tr={class:`file-name`},rr=[`aria-label`,`onClick`],Ge={class:`pane-footer`},qe=[`onClick`],Ye={class:`transfer-file`},ti=I({__name:`feature-demo`,props:{storageName:{}},setup:function(e){var t=e,n=Y().t,r=A(function(){return n(`proFeatureFile.file.ftpStorageFeature.sendToStorage`,{storage:t.storageName})}),i=[{key:`local`,source:`wp-content`,files:[{name:`wp-content`,appearsAt:0},{name:`wp-admin`,appearsAt:0},{name:`wp-includes`,appearsAt:0},{name:`backup`,appearsAt:4930},{name:`index.php`,appearsAt:0}]},{key:`ftp`,source:`backup`,files:[{name:`wp-content`,appearsAt:2650},{name:`wordpress`,appearsAt:0},{name:`backup`,appearsAt:0},{name:`site`,appearsAt:0},{name:`aaPanel`,appearsAt:5350},{name:`ftp_main.py`,appearsAt:0}]}],a=W(0),o=W({local:!1,ftp:!1}),s=A(function(){return a.value>=800&&a.value<2650?`local`:a.value>=3160&&a.value<4930?`ftp`:null}),c=A(function(){return a.value>=1500&&a.value<2650?`right`:a.value>=3780&&a.value<4930?`left`:null}),l=A(function(){return a.value>=6510?`aaPanel`:`aaPanel`.slice(0,Math.max(0,Math.floor((a.value-5520)/125)+1))}),u=A(function(){return a.value>=360&&a.value<1e3?{x:6.4,y:35.5,clicking:a.value>=800}:a.value>=1e3&&a.value<1500?{x:12,y:87,clicking:a.value>=1370}:a.value>=2800&&a.value<3330?{x:54.2,y:51,clicking:a.value>=3160}:a.value>=3330&&a.value<3780?{x:60.5,y:87,clicking:a.value>=3660}:null}),d,f,p=function(){d!==void 0&&clearInterval(d),d=void 0,a.value=7e3},m=function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;if(d!==void 0&&clearInterval(d),d=void 0,o.value={local:!1,ftp:!1},f!=null&&f.matches)p();else{a.value=e;var t=performance.now()-e;d=setInterval(function(){a.value=performance.now()-t,a.value>=7e3&&p()},50)}},h=function(){f!=null&&f.matches?p():m()};return Qi(function(){f=window.matchMedia(`(prefers-reduced-motion: reduce)`),f.addEventListener(`change`,h),m()}),$i(function(){d!==void 0&&clearInterval(d),f==null||f.removeEventListener(`change`,h)}),function(e,d){return U(),M(`div`,He,[j(`div`,vt,q(t.storageName),1),(U(),M(S,null,la(i,function(e){return j(`section`,{key:e.key,class:H([`file-pane`,e.key])},[j(`div`,Rt,q(e.key===`local`?J(n)(`proFeatureFile.file.ftpStorageFeature.localFiles`):t.storageName),1),j(`div`,an,[j(`div`,Sn,[j(`button`,{type:`button`,class:H([`header-check`,{checked:o.value[e.key]}]),role:`checkbox`,"aria-checked":o.value[e.key],"aria-label":e.key===`local`?J(n)(`proFeatureFile.file.ftpStorageFeature.selectLocal`):J(n)(`proFeatureFile.file.ftpStorageFeature.selectRemote`),onClick:function(t){return o.value[e.key]=!o.value[e.key]}},yo(d[0]||(d[0]=[j(`i`,{class:`i-lucide:check`,"aria-hidden":`true`},null,-1)])),10,Rn),j(`span`,null,q(J(n)(`proFeatureFile.file.ftpStorageFeature.fileName`)),1),j(`span`,null,q(J(n)(`proFeatureFile.file.ftpStorageFeature.operation`)),1)]),(U(!0),M(S,null,la(e.files,function(t){return to((U(),M(`div`,{key:t.name,class:H([`file-row`,{selected:o.value[e.key]||s.value===e.key&&t.name===e.source,incoming:t.appearsAt>0&&(t.name!==`aaPanel`||a.value>=6510),editing:t.name===`aaPanel`&&a.value<6510}])},[d[1]||(d[1]=j(`span`,{class:`box`,"aria-hidden":`true`},[j(`i`,{class:`i-lucide:check`})],-1)),j(`span`,Qn,[j(`i`,{class:H(t.name.includes(`.`)?`i-mdi:file-document text-#86a9c6`:`i-mdi:folder text-#efb448`),"aria-hidden":`true`},null,2),j(`span`,tr,q(t.name===`aaPanel`?l.value:t.name),1)]),t.appearsAt===0||t.name===`aaPanel`?(U(),M(`button`,{key:0,type:`button`,class:`row-action`,"aria-label":e.key===`local`?r.value:J(n)(`proFeatureFile.file.ftpStorageFeature.sendToLocal`),onClick:function(t){return m(e.key===`local`?1370:3660)}},[j(`i`,{class:H(e.key===`local`?`i-lucide:arrow-right`:`i-lucide:arrow-left`),"aria-hidden":`true`},null,2)],8,rr)):Pr(``,!0)],2)),[[Za,a.value>=t.appearsAt]])}),128))]),j(`div`,Ge,[j(`button`,{type:`button`,class:H([`send-button`,{"is-clicked":e.key===`local`?a.value>=1370&&a.value<1500:a.value>=3660&&a.value<3780}]),onClick:function(t){return m(e.key===`local`?0:3160)}},q(e.key===`local`?r.value:J(n)(`proFeatureFile.file.ftpStorageFeature.sendToLocal`)),11,qe)])],2)}),64)),c.value?(U(),M(`div`,{key:0,class:H([`transfer-layer`,c.value]),"aria-hidden":`true`},[d[3]||(d[3]=j(`div`,{class:`transfer-line`},null,-1)),j(`div`,Ye,[d[2]||(d[2]=j(`i`,{class:`i-mdi:folder text-#efb448`},null,-1)),N(` `+q(c.value===`right`?`wp-content`:`backup`),1)])],2)):Pr(``,!0),u.value?(U(),M(`svg`,{key:1,class:H([`demo-cursor`,{clicking:u.value.clicking}]),style:Xi({left:``.concat(u.value.x,`%`),top:``.concat(u.value.y,`%`)}),viewBox:`0 0 26 32`,"aria-hidden":`true`},yo(d[4]||(d[4]=[j(`path`,{d:`M3 2.5v22l5.4-5.2 4.2 9.2 4.3-2-4.1-8.8h7.7L3 2.5z`},null,-1)])),6)):Pr(``,!0)])}}}),ei=k(ti,[[`__scopeId`,`data-v-d856ba35`]]),R(),L(),z(),ni=I({__name:`feature`,props:{storageName:{}},setup:function(e){var t=e,n=Y().t,r=xi();return function(e,a){return U(),Mr(i,{title:J(n)(`proFeatureFile.file.ftpStorageFeature.title`),description:J(n)(`proFeatureFile.file.ftpStorageFeature.description`,{storage:t.storageName}),benefits:[J(n)(`proFeatureFile.file.ftpStorageFeature.benefitTransfer`),J(n)(`proFeatureFile.file.ftpStorageFeature.benefitFolders`,{storage:t.storageName})],"demo-label":J(n)(`proFeatureFile.file.ftpStorageFeature.demo`,{storage:t.storageName}),"show-purchase":J(r).isFree,"action-text":J(n)(`proFeatureCommon.common.proFeature.upgrade`),"voucher-text":J(n)(`proFeatureFile.file.ftpStorageFeature.voucher`),"redeem-text":J(n)(`proFeatureFile.file.ftpStorageFeature.redeem`),onAction:a[0]||(a[0]=function(e){return J(Ka)({source:73})}),onRedeem:a[1]||(a[1]=function(e){return J(Ka)({source:73})})},{title:X(function(){return[N(q(J(n)(`proFeatureFile.file.ftpStorageFeature.title`))+` `,1),j(`span`,null,q(J(n)(`proFeatureFile.file.ftpStorageFeature.highlight`,{storage:t.storageName})),1)]}),demo:X(function(){return[P(ei,{"storage-name":t.storageName},null,8,[`storage-name`])]}),_:1},8,[`title`,`description`,`benefits`,`demo-label`,`show-purchase`,`action-text`,`voucher-text`,`redeem-text`])}}}),$r=ni,R(),Hi(),dr=Ti.global,K=dr.t,hr={zip:`ZIP`,rar:`RAR`,gz:`GZ`,"tar.gz":`GZ`,tgz:`GZ`},mr=Object.keys(hr),Or={ftp:[`ftp`],aws_s3:[`aws_s3`],gdrive:[`gdrive`],gcloud_storage:[`gcloud_storage`,`gcloud`,`google_cloud`,`google_cloud_storage`]},R(),L(),ri=W([]),Qa=W(!1),Ar=W(null),ii=W(1),L(),R(),Hi(),Ea=Ti.global.t,R(),L(),Ve={class:`tree-wrapper`},me=I({__name:`Tree`,setup:function(e){var t=Y().t,n=wc(),r=Va(),i=wa(r),a=i.currentPath,o=i.refreshKey,s=i.fileList,c=i.creatingType,l=i.isSearchMode,u=i.searchWord,d=i.searchAll,m=i.currentFile,h=W([]),g=W(``),_=W([]),v=W(null),y=W(null),b=W(null),x=W(``),S=W(null),C=W(!1),w=W(0),T=W(0),ee=W([]),E=W(null),te=function(){var e=new Set;return function(t,n){return Z(function(){return Q(this,function(r){switch(r.label){case 0:if(e.has(t))return[2];e.add(t),r.label=1;case 1:return r.trys.push([1,,3,4]),[4,n()];case 2:return r.sent(),[3,4];case 3:return e.delete(t),[7];case 4:return[2]}})})()}},ne=te(),re=te(),ie=Nr(),D=function(e,t){return function(){return P(`i`,{class:[e,t,`text-16px`]},null)}},ae=[{label:t(`fileEditor.tree.rename`),key:`rename`,icon:D(`i-lucide-text-cursor-input`,`text-gray-500`)},{label:t(`fileEditor.tree.download`),key:`download`,icon:D(`i-lucide-arrow-down`,`text-[#2080f0]`)},{label:t(`fileEditor.tree.delete`),key:`delete`,icon:D(`i-lucide-x`,`text-[#d03050]`)}],oe=[{label:t(`fileEditor.tree.refresh`),key:`refresh`,icon:D(`i-lucide-refresh-cw`,`text-gray-500`)},{label:t(`fileEditor.tree.openDir`),key:`open_dir`,icon:D(`i-lucide-search`,`text-[#2080f0]`)},{label:t(`fileEditor.tree.newFolder`),key:`new_folder`,icon:D(`i-lucide-folder-plus`,`text-[#f0a020]`)},{label:t(`fileEditor.tree.newFile`),key:`new_file`,icon:D(`i-lucide-file-plus`,`text-gray-500`)},{label:t(`fileEditor.tree.rename`),key:`rename`,icon:D(`i-lucide-text-cursor-input`,`text-gray-500`)},{label:t(`fileEditor.tree.delete`),key:`delete`,icon:D(`i-lucide-x`,`text-[#d03050]`)}],se=function(e){C.value=!1;var t=E.value;if(t&&ie(e))switch(e){case`refresh`:re(t.key,function(){return Ce(t)});break;case`download`:Qr(t.key);break;case`rename`:me();break;case`delete`:ce();break;case`new_folder`:ue(`folder`);break;case`new_file`:ue(`file`);break;case`open_dir`:r.setCurrentPath(t.key)}},ce=function(){return Z(function(){var e,t;return Q(this,function(i){switch(i.label){case 0:return E.value?(e={path:E.value.key,type:E.value.type===`dir`||E.value.type===`folder`?`dir`:`file`,nm:E.value.label},t=ge(h.value,e.path),[4,Wr(n,[e])]):[2];case 1:return i.sent(),s.value.map(function(e,t){return{path:e.path,index:t}}).filter(function(t){return t.path===e.path||t.path.startsWith(``.concat(e.path,`/`))}).sort(function(e,t){return t.index-e.index}).forEach(function(e){r.closeTab(e.index)}),t?Ce(t):Oe(!0),[2]}})})()},le=function(){C.value=!1},ue=function(e){return Z(function(){var t,n,r;return Q(this,function(i){switch(i.label){case 0:return t=E.value,t?t.children||t.type!==`dir`?[3,2]:[4,Ce(t)]:[2];case 1:i.sent(),i.label=2;case 2:return n=t.key,_.value.includes(n)||_.value.push(n),de(),v.value=e,y.value=t,g.value=``,r={key:`__local_creating__`,label:``,type:e,isLeaf:!0,isCreating:!0,__isLocal:!0},t.children||(t.children=[]),t.children.unshift(r),[2]}})})()},de=function(){y.value&&y.value.children&&(y.value.children=y.value.children.filter(function(e){return e.key!==`__local_creating__`})),v.value=null,y.value=null},fe=function(){return Z(function(){var e,n,i,a;return Q(this,function(o){switch(o.label){case 0:if(e=g.value,!e.trim())return V.warning(t(`fileEditor.store.nameRequired`)),[2];if(n=v.value,i=y.value,!i)return[2];a=``.concat(i.key,`/`,e),o.label=1;case 1:return o.trys.push([1,,7,8]),r.setLoading(!0),n===`file`?[4,Ir({path:a})]:[3,3];case 2:return o.sent(),[3,5];case 3:return n===`folder`?[4,Fr({path:a})]:[3,5];case 4:o.sent(),o.label=5;case 5:return V.success(t(`fileEditor.store.createSuccess`,{type:t(n===`file`?`fileEditor.store.newFile`:`fileEditor.store.newFolder`)})),de(),[4,Ce(i)];case 6:return o.sent(),[3,8];case 7:return r.setLoading(!1),[7];case 8:return[2]}})})()},me=function(){if(E.value){var e=E.value.key;s.value.some(function(t){return t.path===e||t.path.startsWith(``.concat(e,`/`))})?V.warning(t(`fileEditor.tree.renameOpenedWarning`)):(b.value=e,x.value=E.value.label,S.value=ge(h.value,b.value))}},he=function(){b.value=null,x.value=``,S.value=null},ge=function(e,t){var n=!0,r=!1,i=void 0;try{for(var a=e[Symbol.iterator](),o;!(n=(o=a.next()).done);n=!0){var s=o.value;if(s.children){if(s.children.some(function(e){return e.key===t}))return s;var c=ge(s.children,t);if(c)return c}}}catch(e){r=!0,i=e}finally{try{!n&&a.return!=null&&a.return()}finally{if(r)throw i}}return null},_e=function(){return Z(function(){var e,n,i,a,o;return Q(this,function(s){switch(s.label){case 0:if(e=x.value,!e.trim())return V.warning(t(`fileEditor.store.nameRequired`)),[2];if(!b.value)return[2];if(n=b.value,i=n.lastIndexOf(`/`),a=``.concat(n.substring(0,i),`/`,e),n===a)return he(),[2];s.label=1;case 1:return s.trys.push([1,,7,8]),r.setLoading(!0),[4,ca({sfile:n,dfile:a})];case 2:return s.sent(),o=S.value,he(),o?[4,Ce(o)]:[3,4];case 3:return s.sent(),[3,6];case 4:return[4,Oe(!0)];case 5:s.sent(),s.label=6;case 6:return[3,8];case 7:return r.setLoading(!1),[7];case 8:return[2]}})})()},O=A(function(){return s.value.map(function(e){return e.path})}),ve=function(e,t,n){var r=(e||[]).map(function(e){var t=(n===`/`?`/`:``.concat(n,`/`))+e.nm;return{label:e.nm,key:t,type:`dir`,isLeaf:!1}}),i=(t||[]).map(function(e){var t=(n===`/`?`/`:``.concat(n,`/`))+e.nm;return{label:e.nm,key:t,type:`file`,isLeaf:!0}});return yo(r).concat(yo(i))},ye=function(e){var t=e.option;if(t.type===`dir`||t.type===`folder`)return P(`i`,{class:`tree-icon folder-icon`},null);var n=b.value===t.key,r=t.isCreating?g.value:n?x.value:t.label,i=pi(``.concat(r)).mode;return P(`i`,{class:[`tree-icon`,``.concat(i,`-icon`)]},null)},be=function(e){var n=e.option,i=e.selected,a=b.value===n.key;return n.isCreating||a?P(`div`,{class:`creating-node`},[P(`input`,{class:`creating-input`,value:a?x.value:g.value,onInput:function(e){return a?x.value=e.target.value:g.value=e.target.value},onKeyup:function(e){e.key===`Enter`?(e.stopPropagation(),a?_e():n.__isLocal?fe():r.confirmCreateNewItem(g.value)):e.key===`Escape`&&(e.stopPropagation(),a?he():n.__isLocal?de():r.cancelCreateNewItem())},onClick:function(e){return e.stopPropagation()},placeholder:n.type===`file`?t(`fileEditor.tree.newFilePlaceholder`):t(`fileEditor.tree.newFolderPlaceholder`),ref:function(e){e&&setTimeout(function(){return e.focus()},50)}},null),P(`i`,{class:`i-ep-check text-primary`,onClick:function(e){e.stopPropagation(),a?_e():n.__isLocal?fe():r.confirmCreateNewItem(g.value)}},null),P(`i`,{class:`i-ep-close text-error`,onClick:function(e){e.stopPropagation(),a?he():n.__isLocal?de():r.cancelCreateNewItem()}},null)]):P(p,{class:i?`text-[#cca700]`:``},{default:function(){return[n.label]}})},xe=function(e){return e.option.type===`dir`?`toggleExpand`:`default`},Se=function(e){var t=e.option;return{onClick:function(){if(t.type===`file`&&!t.isCreating){var e=t.key;ne(e,function(){return r.openFile(e)})}},onContextmenu:function(e){e.preventDefault(),C.value=!1,Yi(function(){E.value=t,w.value=e.clientX,T.value=e.clientY,ee.value=t.type===`dir`||t.type===`folder`?oe:ae,C.value=!0})}}},Ce=function(e){return Z(function(){var t,n;return Q(this,function(r){switch(r.label){case 0:return r.trys.push([0,,2,3]),e.isLoading=!0,t=e.key,[4,mi({path:t,p:1,showRow:99999,sort:`name`,reverse:`False`})];case 1:return n=r.sent().message,B(n)&&(e.children=ve(n.dir,n.files,n.path),(!n.dir||n.dir.length===0)&&(e.hideSwitcher=!0)),[3,3];case 2:return e.isLoading=!1,[7];case 3:return[2]}})})()},we=``,Te=!1,Ee=function(){return``.concat(a.value,`|`,l.value,`|`,u.value,`|`,d.value)},De=function(){return Z(function(){var e,t;return Q(this,function(i){switch(i.label){case 0:r.setLoading(!0),i.label=1;case 1:return i.trys.push([1,,3,4]),e={path:a.value,p:1,showRow:99999,sort:`name`,reverse:`False`},l.value&&u.value&&(e.search=u.value,d.value&&(e.all=`True`)),[4,mi(e)];case 2:return t=i.sent().message,B(t)&&(n.fileRecycle.value=t.file_recycle,h.value=ve(t.dir,t.files,t.path),c.value&&ke()),[3,4];case 3:return r.setLoading(!1),[7];case 4:return[2]}})})()},Oe=function(){var e=arguments.length>0&&arguments[0]!==void 0&&arguments[0];return Z(function(){return Q(this,function(t){switch(t.label){case 0:if(r.isListLoading)return(e||Ee()!==we)&&(Te=!0),[2];r.setListLoading(!0),t.label=1;case 1:t.trys.push([1,,6,7]),t.label=2;case 2:return Te=!1,we=Ee(),[4,De()];case 3:t.sent(),t.label=4;case 4:if(Te)return[3,2];t.label=5;case 5:return[3,7];case 6:return r.setListLoading(!1),[7];case 7:return[2]}})})()},ke=function(){if(c.value&&!h.value.find(function(e){return e.key===`__creating__`})){g.value=``;var e={key:`__creating__`,label:``,type:c.value,isLeaf:!0,isCreating:!0};h.value.unshift(e)}},Ae=function(){h.value=h.value.filter(function(e){return e.key!==`__creating__`})};$a(c,function(e){e?ke():Ae()}),$a([a,o],function(){Oe()}),$a(l,function(e){e&&(h.value=[])});var je=function(){m.value&&Yi(function(){setTimeout(function(){var e=document.querySelector(`.tree-wrapper .n-tree-node--selected`);e&&e.scrollIntoView({behavior:`smooth`,block:`center`})},500)})};return Qi(function(){return Z(function(){return Q(this,function(e){switch(e.label){case 0:return[4,Oe()];case 1:return e.sent(),[4,Yi()];case 2:return e.sent(),je(),[2]}})})()}),function(e,t){var n=pe,r=f;return U(),M(`div`,Ve,[P(n,{ref:`treeRef`,"block-line":``,data:J(h),"on-load":Ce,"expand-on-click":``,selectable:``,"expanded-keys":J(_),"onUpdate:expandedKeys":t[0]||(t[0]=function(e){return Gi(_)?_.value=e:null}),"render-prefix":ye,"render-label":be,"override-default-node-click-behavior":xe,"selected-keys":J(O),"node-props":Se},null,8,[`data`,`expanded-keys`,`selected-keys`]),P(r,{trigger:`manual`,placement:`bottom-start`,show:J(C),options:J(ee),x:J(w),y:J(T),onSelect:se,onClickoutside:le},null,8,[`show`,`options`,`x`,`y`])])}}}),fe=k(me,[[`__scopeId`,`data-v-f79b7cfa`]]),R(),L(),z(),Be={class:`sidebar-content`},Fi=I({__name:`index`,setup:function(e){var t=W(!1),n=function(){t.value=!t.value};return function(e,r){return U(),M(`aside`,{class:H([`sidebar-wrapper`,{"is-collapsed":J(t)}])},[j(`div`,Be,[P(s),P(a),P(fe)]),j(`div`,{class:`toggle-btn`,onClick:n})],2)}}}),_=k(Fi,[[`__scopeId`,`data-v-c942a726`]]),R(),z(),Ui(),L(),ze={class:`editor-header-wrapper`},_t=[`title`,`onClick`,`onContextmenu`],Lt=[`onClick`],rn=[`onClick`],wi=I({__name:`header`,props:Ji({data:{default:function(){return[]}},save:{}},{value:{},valueModifiers:{}}),emits:Ji([`select`,`close`],[`update:value`]),setup:function(e,t){var n=t.emit,r=e,i=Ga(e,`value`),a=Y().t,o=n,s=Ya(`headerRef`),c=function(){Yi(function(){setTimeout(function(){if(s.value){var e=s.value.querySelector(`.editor-tab.active`);e&&e.scrollIntoView({behavior:`smooth`,block:`nearest`,inline:`center`})}},100)})};$a(i,function(){c()}),Qi(function(){c()});var l=function(e){i.value=e,o(`select`,e)},u=function(e){var t=pi(e).mode;return``.concat(t,`-icon`)},d=function(e){i.value!==void 0&&e<i.value&&--i.value,o(`close`,e)},m=function(e){za({title:a(`fileEditor.editorHeader.tipTitle`),content:a(`fileEditor.editorHeader.modifiedSaveConfirm`),confirmText:a(`fileEditor.common.save`),cancelText:a(`fileEditor.editorHeader.dontSave`),onConfirm:function(){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return[4,r.save(e)];case 1:return t.sent(),d(e),[2]}})})()},onCancel:function(){d(e)}})},h=function(e){return e.type===`shortcut`||e.type===`diff`||e.onlyRead?!1:e.content!==e.originalContent},g=W(!1),_=W(0),v=W(0),y=W(-1),b=[{label:a(`fileEditor.editorHeader.close`),key:`close`},{label:a(`fileEditor.editorHeader.closeOthers`),key:`closeOthers`},{label:a(`fileEditor.editorHeader.closeAll`),key:`closeAll`}],x=function(e,t){g.value=!1,Yi(function(){g.value=!0,_.value=e.clientX,v.value=e.clientY,y.value=t})},C=function(){g.value=!1},w=function(e){g.value=!1;var t=y.value;if(t!==-1){if(e===`close`){var n=r.data[t];h(n)?m(t):d(t)}else if(e===`closeOthers`){for(var i=r.data.length-1;i>=0;i--)if(i!==t){var a=r.data[i];h(a)||d(i)}}else if(e===`closeAll`)for(var o=r.data.length-1;o>=0;o--){var s=r.data[o];h(s)||d(o)}}};return function(t,n){var r=p,a=ie,o=f;return U(),M(`div`,ze,[P(a,{"x-scrollable":``,trigger:`none`},{default:X(function(){return[j(`div`,{class:`editor-header`,ref_key:`headerRef`,ref:s},[(U(!0),M(S,null,la(e.data,function(e,t){return U(),M(`div`,{key:t,class:H([`editor-tab`,{active:i.value===t}]),title:e.path,onClick:function(e){return l(t)},onContextmenu:ro(function(e){return x(e,t)},[`prevent`])},[j(`div`,{class:H([`tree-icon tab-icon`,u(e.name)])},null,2),P(r,{class:`mx-10px`},{default:X(function(){return[j(`span`,null,q(e.name),1)]}),_:2},1024),h(e)?(U(),M(`div`,{key:0,class:`tab-dirty`,onClick:ro(function(e){return m(t)},[`stop`])},null,8,Lt)):(U(),M(`div`,{key:1,class:`tab-close i-ep-close-bold`,onClick:ro(function(e){return d(t)},[`stop`])},null,8,rn))],42,_t)}),128))],512)]}),_:1}),P(o,{placement:`bottom-start`,trigger:`manual`,x:J(_),y:J(v),options:b,show:J(g),"on-clickoutside":C,onSelect:w},null,8,[`x`,`y`,`show`])])}}}),Ci=k(wi,[[`__scopeId`,`data-v-59f49b3b`]]),R(),Ei=_e(ua(),1),qi=I({__name:`main`,props:Ji({mode:{type:String,default:`Text`}},{value:{},valueModifiers:{}}),emits:Ji([`cursor-change`],[`update:value`]),setup:function(e,t){var n=t.expose,r=t.emit,i=e,a=r,o=Va(),s=wa(o),c=s.editorConfig,l=s.currentFile,u=Ga(e,`value`),d=Ya(`editorRef`),f=null,p=new Map,m=function(e){return new Promise(function(t){Ei.default.config.loadModule(e,function(){return t()})})},h=function(){var e,t;if(f){var n=(e=l.value)==null?void 0:e.path;if(n){var r=o.fileList.map(function(e){return e.path}),a=!0,s=!1,d=void 0;try{for(var m=p.keys()[Symbol.iterator](),h;!(a=(h=m.next()).done);a=!0){var g=h.value;r.includes(g)||p.delete(g)}}catch(e){s=!0,d=e}finally{try{!a&&m.return!=null&&m.return()}finally{if(s)throw d}}var _=p.get(n);if(!_){var v;_=Ei.default.createEditSession((v=u.value)==null?``:v,f.session.getMode()),_.setUndoManager(new Ei.default.UndoManager);var y=c.value.aceEditor,b=y.useSoftTabs,x=y.tabSize,S=y.wrap;_.setUseSoftTabs(b),_.setTabSize(x),_.setUseWrapMode(S),p.set(n,_)}if(_.setMode(`ace/mode/`.concat((t=i.mode)==null?void 0:t.toLocaleLowerCase())),f.getSession()!==_){var C;f.setSession(_),f.setReadOnly(((C=l.value)==null?void 0:C.onlyRead)||!1);var w=c.value.aceEditor,T=w.useSoftTabs,ee=w.tabSize,E=w.wrap;_.setUseSoftTabs(T),_.setTabSize(ee),_.setUseWrapMode(E)}}}};$a(function(){var e;return(e=l.value)==null?void 0:e.path},function(){h()}),$a(function(){return u.value},function(e){if(f){var t=f.getValue();if(e!==void 0&&e!==t){var n=f.getSession(),r=n.selection.getCursor(),i=n.getScrollTop(),a=n.getScrollLeft();f.setValue(e,-1),f.moveCursorToPosition(r),n.setScrollTop(i),n.setScrollLeft(a)}}});var g=function(){return Z(function(){var e,t,n,r,o,s,p,g,v,y,b,x,S,C,w,T,ee,E,te,ne,re,ie,D,ae,oe;return Q(this,function(se){switch(se.label){case 0:return Ei.default.config.set(`basePath`,`/static/ace`),[4,m(`ace/ext/language_tools`)];case 1:return se.sent(),d.value?(n=c.value.aceEditor.editorTheme,r=`ace/theme/`.concat(n),[4,m(r)]):[2];case 2:return se.sent(),d.value&&(o=c.value.aceEditor,s=o.fontSize,p=o.lineHeight,g=o.fontFamily,v=o.showInvisibles,y=o.showLineNumbers,b=o.useSoftTabs,x=o.tabSize,S=o.keyboardHandler,C=o.enableLiveAutocompletion,w=o.enableSnippets,T=o.enableBasicAutocompletion,ee=o.wrap,E=o.indentedSoftWrap,te=o.highlightActiveLine,ne=o.highlightSelectedWord,re=o.animatedScroll,ie=o.showFoldWidgets,D=o.showGutter,ae=o.displayIndentGuides,f=Ei.default.edit(d.value,{value:u.value,theme:r,mode:`ace/mode/`.concat((e=i.mode)==null?void 0:e.toLocaleLowerCase()),fontSize:s,fontFamily:g,showInvisibles:v,showLineNumbers:y,useSoftTabs:b,tabSize:x,showPrintMargin:!1,keyboardHandler:S,enableLiveAutocompletion:C,enableSnippets:w,enableBasicAutocompletion:T,wrap:ee,indentedSoftWrap:E,highlightActiveLine:te,highlightSelectedWord:ne,animatedScroll:re,showFoldWidgets:ie,showGutter:D,displayIndentGuides:ae,readOnly:((t=l.value)==null?void 0:t.onlyRead)||!1}),f.container.style.lineHeight=p,f.renderer.updateFontSize(),oe=function(){if(f){var e=f.getCursorPosition();a(`cursor-change`,{line:e.row+1,column:e.column+1})}},h(),oe(),f.selection.on(`changeCursor`,function(){oe()}),f.on(`change`,function(){u.value=f==null?void 0:f.getValue()}),_(f)),[2]}})})()},_=function(e){e.commands.addCommand({name:`saveFile`,bindKey:{win:`Ctrl-S`,mac:`Command-S`},readOnly:!0,exec:function(){o.saveCurrentFileContent()}}),e.commands.addCommand({name:`saveAllFile`,bindKey:{win:`Ctrl-Shift-S`,mac:`Command-Shift-S`},readOnly:!0,exec:function(){o.saveAllFile()}}),e.commands.addCommand({name:`closeFile`,bindKey:{win:`Alt-W`,mac:`Option-W`},readOnly:!0,exec:function(){o.closeTab(o.currentFileIndex)}}),e.commands.addCommand({name:`undo`,bindKey:{win:`Ctrl-Z`,mac:`Command-Z`},readOnly:!0,exec:function(){e.undo()}})};return eo(function(){var e=c.value.aceEditor,t=e.editorTheme,n=e.fontSize,r=e.lineHeight,i=e.fontFamily,a=e.showInvisibles,o=e.showLineNumbers,s=e.useSoftTabs,u=e.tabSize,d=e.keyboardHandler,p=e.enableLiveAutocompletion,m=e.enableSnippets,h=e.enableBasicAutocompletion,g=e.wrap,_=e.indentedSoftWrap,v=e.highlightActiveLine,y=e.highlightSelectedWord,b=e.animatedScroll,x=e.showFoldWidgets,S=e.showGutter,C=e.displayIndentGuides;if(f){var w;f.setTheme(`ace/theme/`.concat(t)),f.setOptions({fontSize:n,fontFamily:i,showInvisibles:a,showLineNumbers:o,useSoftTabs:s,tabSize:u,keyboardHandler:d,enableLiveAutocompletion:p,enableSnippets:m,enableBasicAutocompletion:h,wrap:g,indentedSoftWrap:_,highlightActiveLine:v,highlightSelectedWord:y,animatedScroll:b,showFoldWidgets:x,showGutter:S,displayIndentGuides:C,readOnly:((w=l.value)==null?void 0:w.onlyRead)||!1}),f.container.style.lineHeight=r,f.renderer.updateFontSize()}}),Qi(function(){g()}),n({execCommand:function(e){f&&f.execCommand(e)},jumpToLine:function(e){f.gotoLine(e,0,!0),requestAnimationFrame(function(){f.focus()})}}),function(e,t){return U(),M(`div`,{ref_key:`editorRef`,ref:d,class:`ace-editor w-full h-full`},null,512)}}}),Ki=k(qi,[[`__scopeId`,`data-v-cd594c09`]]),R(),L(),Re={class:`file-history`},Pi=I({__name:`index`,emits:[`close`],setup:function(e,t){var n=t.emit,r=Y().t,i=n,a=Va(),o=wa(a).currentFile,s=A(function(){var e=o.value;return e?e.history.map(function(t){return{time:t,path:e.path}}):[]}),c=[{key:`time`,title:r(`fileEditor.dialogs.fileHistory.time`),render:function(e){return ci(e.time)}},La({title:r(`fileEditor.dialogs.fileHistory.actions`),width:210,options:function(e){return[{label:r(`fileEditor.dialogs.fileHistory.diff`),onClick:function(){i(`close`),a.openDiffTab(e.path,e.time)}},{label:r(`fileEditor.dialogs.fileHistory.recover`),onClick:function(){za({title:r(`fileEditor.dialogs.fileHistory.recoverTitle`),content:r(`fileEditor.dialogs.fileHistory.recoverContent`,{time:ci(e.time)}),onConfirm:function(){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return[4,oa({filename:e.path,history:e.time})];case 1:return t.sent(),V.success(r(`fileEditor.dialogs.fileHistory.fileContentUpdated`)),a.getFileContent(e.path),[2]}})})()}})}},{label:r(`fileEditor.dialogs.fileHistory.delete`),onClick:function(){za({title:r(`fileEditor.dialogs.fileHistory.deleteTitle`),content:r(`fileEditor.dialogs.fileHistory.deleteContent`,{time:ci(e.time)}),onConfirm:function(){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return[4,Gr({filename:e.path,history:e.time})];case 1:return t.sent(),u(e.path),[2]}})})()}})}}]}})],l=W(!1),u=function(e){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return t.trys.push([0,,2,3]),l.value=!0,[4,a.getFileContent(e)];case 1:return t.sent(),[3,3];case 2:return l.value=!1,[7];case 3:return[2]}})})()};return function(e,t){var n=xr;return U(),M(`div`,Re,[P(n,{loading:J(l),columns:c,data:J(s),"max-height":400},null,8,[`loading`,`data`])])}}}),v=k(Pi,[[`__scopeId`,`data-v-1701a30e`]]),R(),L(),z(),Le={key:0,class:`footer-path`},gt={key:1,class:`footer-path diff-path`},Pt={class:`mr-6px`},nn={key:2,class:`footer-tools`},xn={class:`footer-item`},Ln={key:0,class:`footer-item readonly-badge`},oi=I({__name:`footer`,props:{filePath:{default:``},encoding:{default:`UTF-8`},lineEnding:{default:`LF`},cursor:{default:function(){return{line:1,column:1}}},tabSize:{default:4},useSoftTabs:{type:Boolean,default:!0},language:{default:`Text`}},emits:[`jump-line`],setup:function(e,t){var n=t.emit,r=e,i=n,a=Va(),o=wa(a),s=o.currentFile,c=o.editorConfig,l=Y().t,u=A(function(){return s.value?s.value.history.length:0}),d=A(function(){var e;return((e=s.value)==null?void 0:e.onlyRead)||!1}),f=function(){Wa({title:l(`fileEditor.dialogs.fileHistory.title`),component:v})},m=function(){a.openToolsModal(`lineEnding`,{lineEnding:r.lineEnding,onChange:function(e){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return[4,a.changeLineEnding(e)];case 1:return t.sent(),[2]}})})()}})},h=function(){a.openToolsModal(`tabSize`,{useSoftTabs:r.useSoftTabs?`space`:`tab`,tabSize:r.tabSize,onChange:function(e,t){a.updateTabSettings(e,t)}})},g=function(){a.openToolsModal(`encoding`,{encoding:c.value.aceEditor.encoding,onChange:function(e){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return[4,a.changeEncoding(e)];case 1:return t.sent(),[2]}})})()}})},_=function(){var e,t,n;a.openToolsModal(`goToLine`,{currentLine:(e=r.cursor)==null?void 0:e.line,currentColumn:(t=r.cursor)==null?void 0:t.column,maxLine:(n=s.value)!=null&&n.content?s.value.content.split(` `).length:1,onChange:function(e){i(`jump-line`,e)}})},y=function(){if(s.value&&s.value.type===`diff`){var e={path:s.value.originalPath,time:s.value.historyTime};za({title:l(`fileEditor.dialogs.fileHistory.recoverTitle`),content:l(`fileEditor.dialogs.fileHistory.recoverContent`,{time:ci(e.time)}),onConfirm:function(){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return[4,oa({filename:e.path,history:e.time})];case 1:return t.sent(),V.success(l(`fileEditor.dialogs.fileHistory.fileContentUpdated`)),a.getFileContent(e.path),a.closeTab(a.currentFileIndex),[2]}})})()}})}};return function(t,n){var r,i,a,o,c,l=p,v=vr;return U(),M(`div`,{class:H([`editor-footer`,{"diff-footer":((r=J(s))==null?void 0:r.type)===`diff`}])},[((i=J(s))==null?void 0:i.type)===`diff`?(U(),M(`div`,gt,[j(`span`,Pt,q(t.$t(`fileEditor.editorFooter.readOnlyHistory`,{path:(a=J(s))==null?void 0:a.originalPath,time:J(ci)((o=J(s))==null?void 0:o.historyTime)})),1),P(v,{onClick:y},{default:X(function(){return[N(q(t.$t(`fileEditor.editorFooter.clickRecoverLeft`)),1)]}),_:1})])):(U(),M(`div`,Le,[P(l,null,{default:X(function(){return[N(q(t.$t(`fileEditor.editorFooter.fileLocation`,{path:e.filePath})),1)]}),_:1})])),((c=J(s))==null?void 0:c.type)===`diff`?Pr(``,!0):(U(),M(`div`,nn,[j(`span`,{class:`footer-item`,onClick:m},q(e.lineEnding),1),j(`span`,{class:`footer-item`,onClick:_},q(t.$t(`fileEditor.editorFooter.lineColumn`,{line:e.cursor.line,column:e.cursor.column})),1),j(`span`,{class:`footer-item`,onClick:f},q(t.$t(`fileEditor.editorFooter.historyCount`,{count:J(u)})),1),j(`span`,{class:`footer-item`,onClick:h},q(t.$t(`fileEditor.editorFooter.tabSize`,{size:e.tabSize})),1),j(`span`,{class:`footer-item`,onClick:g},q(t.$t(`fileEditor.editorFooter.encoding`,{encoding:e.encoding})),1),j(`span`,xn,q(t.$t(`fileEditor.editorFooter.language`,{language:e.language})),1),J(d)?(U(),M(`span`,Ln,q(t.$t(`fileEditor.editorFooter.readOnlyMode`)),1)):Pr(``,!0)]))],2)}}}),ai=k(oi,[[`__scopeId`,`data-v-f3c99d32`]]),R(),Zr=I({__name:`diff`,props:{mode:{type:String,default:`Text`}},setup:function(e){var t=e,r=Va(),i=wa(r),a=i.editorConfig,o=i.currentFile,s=Ya(`diffRef`),c=null,l=function(e){return new Promise(function(t){Ei.default.config.loadModule(e,function(){return t()})})},u=function(){return Z(function(){var e,r,i,u,d,f,p,m,h,g,_,v,y,b;return Q(this,function(x){switch(x.label){case 0:return Ei.default.config.set(`basePath`,`/static/ace`),[4,l(`ace/ext/language_tools`)];case 1:return x.sent(),s.value?(u=a.value.aceEditor.editorTheme,d=`ace/theme/`.concat(u),[4,l(d)]):[2];case 2:return x.sent(),s.value&&(f=a.value.aceEditor,p=f.fontSize,m=f.fontFamily,h=f.showInvisibles,g=f.showLineNumbers,_=f.useSoftTabs,v=f.tabSize,y=`ace/mode/`.concat((e=t.mode)==null?void 0:e.toLocaleLowerCase()),c=new n({ace:Ei.default,element:s.value,theme:d,mode:y,left:{content:((r=o.value)==null?void 0:r.leftContent)||``,editable:!1,copyLinkEnabled:!1},right:{content:((i=o.value)==null?void 0:i.rightContent)||``,editable:!1,copyLinkEnabled:!1}}),b=c.getEditors(),[b.left,b.right].forEach(function(e){e.setOptions({fontSize:p,fontFamily:m,showInvisibles:h,showLineNumbers:g,useSoftTabs:_,tabSize:v,showPrintMargin:!1,wrap:!0,indentedSoftWrap:!0})}),$a(function(){var e;return(e=o.value)==null?void 0:e.leftContent},function(e){c&&c.getEditors().left.setValue(e||``,-1)}),$a(function(){var e;return(e=o.value)==null?void 0:e.rightContent},function(e){c&&c.getEditors().right.setValue(e||``,-1)})),[2]}})})()};return Qi(function(){u()}),Zi(function(){c&&c.destroy()}),eo(function(){var e=a.value.aceEditor,t=e.editorTheme,n=e.fontSize,r=e.fontFamily,i=e.showInvisibles,o=e.showLineNumbers,s=e.useSoftTabs,l=e.tabSize;if(c){var u=c.getEditors();[u.left,u.right].forEach(function(e){e.setTheme(`ace/theme/`.concat(t)),e.setOptions({fontSize:n,fontFamily:r,showInvisibles:i,showLineNumbers:o,useSoftTabs:s,tabSize:l})})}}),function(e,t){return U(),M(`div`,{ref_key:`diffRef`,ref:s,class:`ace-diff-container w-full h-full`},null,512)}}}),Xr=k(Zr,[[`__scopeId`,`data-v-3cd40f25`]]),z(),R(),fr={},je={class:`flex-1 bg-[#262626] overflow-y-auto w-full h-full text-[#ccc]`},ht={class:`flex gap-60px max-w-[1200px] mx-auto py-30px px-50px justify-center`},Nt={class:`flex-1`},tn={class:`text-[20px] text-[#e0e0e0] mb-[24px] pl-[12px] border-l-[3px] border-l-solid border-l-primary`},bn={class:`flex flex-col gap-[14px] text-[14px]`},In={class:`flex items-center`},Zn={class:`text-[#a4a4a4] ml-[16px]`},er={class:`flex items-center`},nr={class:`text-[#a4a4a4] ml-[16px]`},We={class:`flex items-center`},Ke={class:`text-[#a4a4a4] ml-[16px]`},Je={class:`flex items-center`},Xe={class:`text-[#a4a4a4] ml-[16px]`},Ze={class:`flex items-center`},Qe={class:`text-[#a4a4a4] ml-[16px]`},$e={class:`flex items-center`},et={class:`text-[#a4a4a4] ml-[16px]`},tt={class:`flex items-center`},nt={class:`text-[#a4a4a4] ml-[16px]`},Ct={class:`flex items-center`},wt={class:`text-[#a4a4a4] ml-[16px]`},Tt={class:`flex items-center`},Et={class:`text-[#a4a4a4] ml-[16px]`},Dt={class:`flex items-center`},Ot={class:`text-[#a4a4a4] ml-[16px]`},kt={class:`mt-[40px]`},At={class:`text-[20px] text-[#e0e0e0] mb-[24px] pl-[12px] border-l-[3px] border-l-solid border-l-primary`},jt={class:`flex flex-col gap-[14px] text-[14px]`},Mt={class:`flex items-center`},Gt={class:`text-[#a4a4a4] ml-[16px]`},Kt={class:`flex items-center`},qt={class:`text-[#a4a4a4] ml-[16px]`},Jt={class:`flex items-center`},Yt={class:`text-[#a4a4a4] ml-[16px]`},Xt={class:`flex items-center`},Zt={class:`text-[#a4a4a4] ml-[16px]`},Qt={class:`flex-1`},$t={class:`text-[20px] text-[#e0e0e0] mb-[24px] pl-[12px] border-l-[3px] border-l-solid border-l-primary`},en={class:`flex flex-col gap-[14px] text-[14px]`},un={class:`flex items-center`},dn={class:`flex items-center gap-[6px] min-w-[260px] text-white`},fn={class:`flex items-center`},pn={class:`text-[#a4a4a4] ml-[16px]`},mn={class:`flex items-center`},hn={class:`text-[#a4a4a4] ml-[16px]`},gn={class:`flex items-center`},_n={class:`flex items-center gap-[6px] min-w-[260px] text-white`},vn={class:`text-[#a4a4a4] ml-[16px]`},yn={class:`mt-[40px]`},En={class:`text-[20px] text-[#e0e0e0] mb-[24px] pl-[12px] border-l-[3px] border-l-solid border-l-primary`},Dn={class:`flex flex-col gap-[14px] text-[14px]`},On={class:`flex items-center`},kn={class:`text-[#a4a4a4] ml-[16px]`},An={class:`flex items-center`},jn={class:`text-[#a4a4a4] ml-[16px]`},Mn={class:`flex items-center`},Nn={class:`text-[#a4a4a4] ml-[16px]`},Pn={class:`flex items-center`},Fn={class:`text-[#a4a4a4] ml-[16px]`},Vn={class:`flex items-center`},Hn={class:`text-[#a4a4a4] ml-[16px]`},Un={class:`flex items-center`},Wn={class:`text-[#a4a4a4] ml-[16px]`},Gn={class:`flex items-center`},Kn={class:`text-[#a4a4a4] ml-[16px]`},qn={class:`flex items-center`},Jn={class:`text-[#a4a4a4] ml-[16px]`},Yn={class:`flex items-center`},Xn={class:`text-[#a4a4a4] ml-[16px]`},oe=k(fr,[[`render`,Tc],[`__scopeId`,`data-v-38e00b50`]]),R(),L(),be={class:`flex-1 flex flex-col h-full bg-[#1e1e1e] overflow-hidden`},it={class:`flex-1 overflow-hidden relative`},Oi=I({__name:`index`,setup:function(e,t){var n=t.expose,r=Va(),i=wa(r),a=i.fileList,o=i.currentFileIndex,s=i.currentFile,c=i.editorConfig,l=r.saveFileContentAndClose,u=r.closeTab,d=r.updateTabContent,f=Ya(`editorMainRef`),p=A({get:function(){var e;return((e=s.value)==null?void 0:e.content)||``},set:function(e){o.value!==-1&&d(o.value,e)}}),m=ia({line:1,column:1}),h=A(function(){return Number(c.value.aceEditor.tabSize)}),g=A(function(){return c.value.aceEditor.useSoftTabs}),_=A(function(){var e;return((e=s.value)==null?void 0:e.encoding)||``}),v=A(function(){var e=new Map,t=Object.entries(c.value.supportedModes||{}),n=!0,r=!1,i=void 0;try{for(var a=t[Symbol.iterator](),o;!(n=(o=a.next()).done);n=!0){var s=vo(o.value,2),l=s[0],u=s[1][0].split(`|`),d=!0,f=!1,p=void 0;try{for(var m=u[Symbol.iterator](),h;!(d=(h=m.next()).done);d=!0){var g=h.value;e.set(g,l)}}catch(e){f=!0,p=e}finally{try{!d&&m.return!=null&&m.return()}finally{if(f)throw p}}}}catch(e){r=!0,i=e}finally{try{!n&&a.return!=null&&a.return()}finally{if(r)throw i}}return e}),y=A(function(){var e,t=(e=s.value)==null?void 0:e.type;return t&&v.value.get(t)||`Text`}),b=A(function(){var e,t,n=y.value;return(e=(t=c.value.nameOverrides)==null?void 0:t[n])==null?n:e}),x=function(e){return Z(function(){return Q(this,function(t){switch(t.label){case 0:return[4,l(e)];case 1:return t.sent(),[2]}})})()},C=function(e){u(e)},w=function(e){m.line=e.line,m.column=e.column},T=function(e){if(e===`search`){var t;(t=f.value)==null||t.execCommand(`find`)}else if(e===`replace`){var n;(n=f.value)==null||n.execCommand(`replace`)}else if(e===`goToLine`){var i;r.openToolsModal(`goToLine`,{currentLine:m.line,currentColumn:m.column,maxLine:(i=s.value)!=null&&i.content?s.value.content.split(` `).length:1,onChange:function(e){var t;(t=f.value)==null||t.jumpToLine(e)}})}},ee=function(e){var t;(t=f.value)==null||t.jumpToLine(e)};return n({handleToolbarAction:T}),r.getEditorConfig(),function(e,t){return U(),M(`div`,be,[P(Ci,{value:J(o),"onUpdate:value":t[0]||(t[0]=function(e){return Gi(o)?o.value=e:null}),data:J(a),save:x,onClose:C},null,8,[`value`,`data`]),J(s)?(U(),M(S,{key:0},[j(`div`,it,[J(s).type===`shortcut`?(U(),Mr(oe,{key:0})):J(s).type===`diff`?(U(),Mr(Xr,{key:1,mode:J(y)},null,8,[`mode`])):(U(),Mr(Ki,{key:2,ref_key:`editorMainRef`,ref:f,value:J(p),"onUpdate:value":t[1]||(t[1]=function(e){return Gi(p)?p.value=e:null}),mode:J(y),onCursorChange:w},null,8,[`value`,`mode`]))]),J(s).type===`shortcut`?Pr(``,!0):(U(),Mr(ai,{key:0,"file-path":J(s).path,encoding:J(_),"line-ending":J(s).lineEnding,cursor:J(m),"tab-size":J(h),"use-soft-tabs":J(g),language:J(b),onJumpLine:ee},null,8,[`file-path`,`encoding`,`line-ending`,`cursor`,`tab-size`,`use-soft-tabs`,`language`]))],64)):Pr(``,!0)])}}}),d=Oi,R(),L(),Ui(),ye={class:`editor-container`},rt={class:`editor-body`},Di=I({__name:`index`,props:{filePath:{type:String,required:!0},currentPath:{type:String,required:!0},onClose:{type:Function,required:!0},onMaximize:{type:Function,required:!0},onMinimize:{type:Function,required:!0}},setup:function(e){var t=e,n=Ya(`codeEditorRef`),r=Y().t,i=Va(),a=wa(i).isMinimize,o=function(e){(e.key===`F5`||e.key===`r`&&(e.metaKey||e.ctrlKey))&&(e.preventDefault(),V.info(r(`fileEditor.messages.noRefresh`)))};i.setCurrentPath(t.currentPath),Qi(function(){window.addEventListener(`keydown`,o,{capture:!0}),i.isOpen=!0,i.openFile(t.filePath)}),$i(function(){window.removeEventListener(`keydown`,o,{capture:!0}),i.isOpen=!1,i.isMinimize=!1,i.fileList=[],i.currentFileIndex=-1,i.currentPath=``,i.creatingType=null,i.isSearchMode=!1,i.closeToolsModal()});var s=W(!1),c=A({get:function(){return a.value},set:function(e){a.value=e}}),l=function(e){n.value&&n.value.handleToolbarAction(e)},u=function(){c.value=!c.value,t.onMinimize()},f=function(){s.value=!s.value,t.onMaximize()},p=function(){var e=i.fileList.some(function(e){return e.content!==e.originalContent&&e.type!==`shortcut`}),n=function(){Dr(),t.onClose&&t.onClose()};e?za({title:r(`fileEditor.editorHeader.tipTitle`),content:r(`fileEditor.editorHeader.modifiedSaveConfirm`),confirmText:r(`fileEditor.common.save`),cancelText:r(`fileEditor.editorHeader.dontSave`),onConfirm:function(){return Z(function(){return Q(this,function(e){switch(e.label){case 0:return[4,i.saveAllFile()];case 1:return e.sent(),n(),[2]}})})()},onCancel:function(){n()}}):n()};return function(e,t){return U(),M(`div`,ye,[P(ue,{"is-minimize":J(c),"is-maximize":J(s),onMinimize:u,onMaximize:f,onClose:p},null,8,[`is-minimize`,`is-maximize`]),to(P(de,{onAction:l},null,512),[[Za,!J(c)]]),to(j(`main`,rt,[P(_),P(d,{ref_key:`codeEditorRef`,ref:n},null,512)],512),[[Za,!J(c)]])])}}}),e(`t`,g=ge({default:function(){return h}})),h=k(Di,[[`__scopeId`,`data-v-615a4f3c`]])}}})})();
Save File
Cancel