2024-04-01 18:44:39 -04:00
|
|
|
(()=>{var e,t={51301:(e,t,n)=>{"use strict";var i=n(93379),s=n.n(i),r=n(7795),o=n.n(r),a=n(90569),l=n.n(a),d=n(3565),c=n.n(d),u=n(19216),j=n.n(u),f=n(44589),h=n.n(f),m=n(24197),v={};v.styleTagTransform=h(),v.setAttributes=c(),v.insert=l().bind(null,"head"),v.domAPI=o(),v.insertStyleElement=j(),s()(m.Z,v),m.Z&&m.Z.locals&&m.Z.locals;var p,b=n(31352),g=n(61137),y=n(80351),w=n.n(y),_=n(77958),k=n(91770),x=n(79753),I=n(14596);const z="/trashbin/".concat(null===(p=(0,_.ts)())||void 0===p?void 0:p.uid,"/trash"),E=(0,x.generateRemoteUrl)("dav"+z),O=(0,I.eI)(E,{headers:{requesttoken:(0,_.IH)()}}),A='<?xml version="1.0"?>\n<d:propfind xmlns:d="DAV:"\n\txmlns:oc="http://owncloud.org/ns"\n\txmlns:nc="http://nextcloud.org/ns">\n\t<d:prop>\n\t\t<nc:trashbin-filename />\n\t\t<nc:trashbin-deletion-time />\n\t\t<nc:trashbin-original-location />\n\t\t<nc:trashbin-title />\n\t\t<d:getlastmodified />\n\t\t<d:getetag />\n\t\t<d:getcontenttype />\n\t\t<d:resourcetype />\n\t\t<oc:fileid />\n\t\t<oc:permissions />\n\t\t<oc:size />\n\t\t<d:getcontentlength />\n\t</d:prop>\n</d:propfind>',S=function(e){var t,n,i,s,r;const o=(0,k.wE)(null===(t=e.props)||void 0===t?void 0:t.permissions),a=null===(n=(0,_.ts)())||void 0===n?void 0:n.uid,l=(0,x.generateUrl)("/apps/files_trashbin/preview?fileId={fileid}&x=32&y=32",e.props),d={id:(null===(i=e.props)||void 0===i?void 0:i.fileid)||0,source:(0,x.generateRemoteUrl)("dav"+z+e.filename),mtime:new Date(e.lastmod),mime:e.mime,size:(null===(s=e.props)||void 0===s?void 0:s.size)||0,permissions:o,owner:a,root:z,attributes:{...e,...e.props,displayName:null===(r=e.props)||void 0===r?void 0:r["trashbin-filename"],previewUrl:l}};return"file"===e.type?new k.$B(d):new k.gt(d)};var C=n(69183),N=n(4820),P=n(64009);const U=(0,n(17499).IY)().setApp("files").detectUser().build();var R,B=n(65358);R=new class{constructor(e){var t,n,i;t=this,i=void 0,(n=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(n="_action"))in t?Object.defineProperty(t,n,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[n]=i,this.validateAction(e),this._action=e}get id(){return this._action.id}get displayName(){return this._action.displayName}get iconSvgInline(){return this._action.iconSvgInline}get enabled(){return this._action.enabled}get exec(){return this._action.exec}get execBatch(){return this._action.execBatch}get order(){return this._action.order}get default(){return this._action.default}get inline(){return this._action.inline}get renderInline(){return this._action.renderInline}validateAction(e){if(!e.id||"string"!=typeof e.id)throw new Error("Invalid id");if(!e.displayName||"function"!=typeof e.displayName)throw new Error("Invalid displayName function");if(!e.iconSvgInline||"function"!=typeof e.iconSvgInline)throw new Error("Invalid iconSvgInline function");if(!e.exec||"function"!=typeof e.exec)throw new Error("Invalid exec function");if("enabled"in e&&"function"!=typeof e.enabled)throw new Error("Invalid enabled function");if("execBatch"in e&&"function"!=typeof e.execBatch)throw new Error("Invalid execBatch function");if("order"in e&&"number"!=typeof e.order)throw new Error("Invalid order");if("default"in e&&"boolean"!=typeof e.default)throw new Error("Invalid default");if("inline"in e&&"function"!=typeof e.inline)throw new Error("Invalid inline function");if("renderInline"in e&&"function"!=typeof e.renderInline)throw new Error("Invalid renderInline function")}}({id:"restore",displayName:()=>(0,b.Iu)("files_trashbin","Restore"),iconSvgInline:()=>P,enabled:(e,t)=>"trashbin"===t.id&&e.length>0&&e.map((e=>e.permissions)).every((e=>0!=(e&k.y3.READ))),async exec(e){const{origin:t}=new URL(e.source),n=t+(0,B.Ec)(e.source.slice(t.length));try{var i;const t=(0,x.generateRemoteUrl)((0,B.Ec)("dav/trashbin/".concat(null===(i=(0,_.ts)())||void 0===i?void 0:i.uid,"/restore/").concat(e.basename)));return
|