(()=>{"use strict";vart,e={43275:(t,e,i)=>{varn=i(85072),r=i.n(n),s=i(97825),o=i.n(s),a=i(77659),l=i.n(a),d=i(55056),u=i.n(d),c=i(10540),h=i.n(c),p=i(41113),f=i.n(p),g=i(98290),m={};m.styleTagTransform=f(),m.setAttributes=u(),m.insert=l().bind(null,"head"),m.domAPI=o(),m.insertStyleElement=h(),r()(g.A,m),g.A&&g.A.locals&&g.A.locals;varE=i(53334),N=i(35947),w=i(21777),b=i(43627),v=i(71225),I=i(63814),x=(i(36117),i(44719)),y=i(82680),A=(i(87485),i(380)),O=i(65606),T=i(96763);const_=(0,N.YK)().setApp("@nextcloud/files").detectUser().build();varR=(t=>(t.DEFAULT="default",t.HIDDEN="hidden",t))(R||{}),L=(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))(L||{});const$=["d:getcontentlength","d:getcontenttype","d:getetag","d:getlastmodified","d:creationdate","d:displayname","d:quota-available-bytes","d:resourcetype","nc:has-preview","nc:is-encrypted","nc:mount-type","oc:comments-unread","oc:favorite","oc:fileid","oc:owner-display-name","oc:owner-id","oc:permissions","oc:size"],S={d:"DAV:",nc:"http://nextcloud.org/ns",oc:"http://owncloud.org/ns",ocs:"http://open-collaboration-services.org/ns"};varC=(t=>(t.Folder="folder",t.File="file",t))(C||{});constP=function(t,e){returnnull!==t.match(e)},D=(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(t){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.displayname&&"string"!=typeoft.displayname)thrownewError("Invalid displayname type");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>=L.NONE&&t.permissions<=L.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&&P(t.source,e)){consti=t.source.match(e)[0];if(!t.source.includes((0,b.join)(i,t.root)))thrownewError("The root must be relative to the service. e.g /files/emma")}if(t.status&&!Object.values(F).includes(t.status))thrownewError("Status must be a valid NodeStatus")};varF=(t=>(t.NEW="new",t.FAILED="failed",t.LOADING="loading",t.LOCKED="locked",t))(F||{});classV{_data;_attributes;_knownDavService=/(remote|public)\.php\/(web)?dav/i;readonlyAttributes=Object.entries(Object.getOwnPropertyDescriptors(V.prototype)).filter((t=>"function"==typeoft[1].get&&"__proto__"!==t[0])).map((t=>t[0]));handler={set:(t,e,i)=>!this.readonlyAttributes.includes(e)&&Reflect.set(t,e,i),deleteProperty:(t,e)=>!this.readonlyAttributes.includes(e)&&Reflect.deleteProperty(t,e),get:(t,e,i)=>this.readonlyAttributes.includes(e)?(_.warn(`Accessing "Node.attributes.${e}" is deprecated, access it directly on the Node instance.`),Reflect.get(this,e)):Reflect.get(t,e,i)};constructor(t,e){D(t,e||this._knownDavService),this._data={displayname:t.attributes?.displayname,...t,attributes:{}},this._attributes=newProxy(this._data.attributes,this.handler),this.update(t.attributes??{}),e&&(this._knownDavService=e)}getsource(){returnthis._data.source.replace(/\/$/i,"")}getencodedSource(){const{origin:t}=newURL(this.source);returnt+(0,v.O0)(this.source.slice(t.length))}getbase