(()=>{vart,e={72620:(t,e,n)=>{"use strict";vari=n(31352),r=n(80351),s=n.n(r),o=n(77958),a=n(17499),l=n(62520),u=n(65358),d=n(79753),c=n(14596);consth=null===(p=(0,o.ts)())?(0,a.IY)().setApp("files").build():(0,a.IY)().setApp("files").setUid(p.uid).build();varp,f=(t=>(t.DEFAULT="default",t.HIDDEN="hidden",t))(f||{}),g=(t=>(t[t.NONE=0]="NONE",t[t.CREATE=4]="CREATE",t[t.READ=1]="READ",t[t.UPDATE=2]="UPDATE",t[t.DELETE=8]="DELETE",t[t.SHARE=16]="SHARE",t[t.ALL=31]="ALL",t))(g||{});constm=["d:getcontentlength","d:getcontenttype","d:getetag","d:getlastmodified","d:quota-available-bytes","d:resourcetype","nc:has-preview","nc:is-encrypted","nc:mount-type","nc:share-attributes","oc:comments-unread","oc:favorite","oc:fileid","oc:owner-display-name","oc:owner-id","oc:permissions","oc:share-types","oc:size","ocs:share-permissions"],w={d:"DAV:",nc:"http://nextcloud.org/ns",oc:"http://owncloud.org/ns",ocs:"http://open-collaboration-services.org/ns"};varb=(t=>(t.Folder="folder",t.File="file",t))(b||{});constv=function(t,e){returnnull!==t.match(e)},x=(t,e)=>{if(t.id&&"number"!=typeoft.id)thrownewError("Invalid id type of value");if(!t.source)thrownewError("Missing mandatory source");try{newURL(t.source)}catch{thrownewError("Invalid source format, source must be a valid URL")}if(!t.source.startsWith("http"))thrownewError("Invalid source format, only http(s) is supported");if(t.mtime&&!(t.mtimeinstanceofDate))thrownewError("Invalid mtime type");if(t.crtime&&!(t.crtimeinstanceofDate))thrownewError("Invalid crtime type");if(!t.mime||"string"!=typeoft.mime||!t.mime.match(/^[-\w.]+\/[-+\w.]+$/gi))thrownewError("Missing or invalid mandatory mime");if("size"int&&"number"!=typeoft.size&&void0!==t.size)thrownewError("Invalid size type");if("permissions"int&&void0!==t.permissions&&!("number"==typeoft.permissions&&t.permissions>=g.NONE&&t.permissions<=g.ALL))thrownewError("Invalid permissions");if(t.owner&&null!==t.owner&&"string"!=typeoft.owner)thrownewError("Invalid owner type");if(t.attributes&&"object"!=typeoft.attributes)thrownewError("Invalid attributes type");if(t.root&&"string"!=typeoft.root)thrownewError("Invalid root type");if(t.root&&!t.root.startsWith("/"))thrownewError("Root must start with a leading slash");if(t.root&&!t.source.includes(t.root))thrownewError("Root must be part of the source");if(t.root&&v(t.source,e)){constn=t.source.match(e)[0];if(!t.source.includes((0,l.join)(n,t.root)))thrownewError("The root must be relative to the service. e.g /files/emma")}if(t.status&&!Object.values(y).includes(t.status))thrownewError("Status must be a valid NodeStatus")};vary=(t=>(t.NEW="new",t.FAILED="failed",t.LOADING="loading",t.LOCKED="locked",t))(y||{});classE{_data;_attributes;_knownDavService=/(remote|public)\.php\/(web)?dav/i;constructor(t,e){x(t,e||this._knownDavService),this._data=t;constn={set:(t,e,n)=>(this.updateMtime(),Reflect.set(t,e,n)),deleteProperty:(t,e)=>(this.updateMtime(),Reflect.deleteProperty(t,e))};this._attributes=newProxy(t.attributes||{},n),deletethis._data.attributes,e&&(this._knownDavService=e)}getsource(){returnthis._data.source.replace(/\/$/i,"")}getencodedSource(){const{origin:t}=newURL(this.source);returnt+(0,u.Ec)(this.source.slice(t.length))}getbasename(){return(0,l.basename)(this.source)}getextension(){return(0,l.extname)(this.source)}getdirname(){if(this.root){lett=this.source;this.isDavRessource&&(t=t.split(this._knownDavService).pop());conste=t.indexOf(this.root),n=this.root.replace(/\/$/,"");return(0,l.dirname)(t.slice(e+n.length)||"/")}constt=newURL(this.source);return(0,l.dirname)(t.pathname)}getmime(){returnthis._data.mime}getmtime(){returnthis._data.mtime}getcrtime(){returnthis._data.crtime}getsize(){returnthis._data.size}getattributes(){returnthis._attributes}getpermissions(){returnnull!==this.owner||this.isDavRessource?void0!==this._data.permissions?this._data.permissions:g.NONE:g.READ}getowner(){returnthis.isDavRessource?this._data.owner:null}getisDavRessource(){returnv(this.source,this._knownDavService)}g