files_versions-files_versions.js 44 KB

123
  1. /*! For license information please see files_versions-files_versions.js.LICENSE.txt */
  2. (()=>{var e,i,s,n={46462:(e,i,s)=>{"use strict";var n=s(20144),r=s(31352),o=s(62520),a=s.n(o),l=s(64024),c=s(40946),d=s(69183),u=s(77958),p=s(65358),f=s(79753),m=s(80351),h=s.n(m);s(5656);const v=function(t){const e=(t.startsWith("/")?t:`/${t}`).split("/");let i="";return e.forEach((t=>{""!==t&&(i+="/"+encodeURIComponent(t))})),i};var g=s(14596);const b=(0,f.generateRemoteUrl)("dav"),A=(0,g.eI)(b,{headers:{"X-Requested-With":"XMLHttpRequest",requesttoken:(0,u.IH)()??""}}),w=(0,s(17499).IY)().setApp("files_version").detectUser().build();const y={name:"BackupRestoreIcon",emits:["click"],props:{title:{type:String},fillColor:{type:String,default:"currentColor"},size:{type:Number,default:24}}};var _=s(51900);const j=(0,_.Z)(y,(function(){var t=this,e=t._self._c;return e("span",t._b({staticClass:"material-design-icon backup-restore-icon",attrs:{"aria-hidden":!t.title,"aria-label":t.title,role:"img"},on:{click:function(e){return t.$emit("click",e)}}},"span",t.$attrs,!1),[e("svg",{staticClass:"material-design-icon__svg",attrs:{fill:t.fillColor,width:t.size,height:t.size,viewBox:"0 0 24 24"}},[e("path",{attrs:{d:"M12,3A9,9 0 0,0 3,12H0L4,16L8,12H5A7,7 0 0,1 12,5A7,7 0 0,1 19,12A7,7 0 0,1 12,19C10.5,19 9.09,18.5 7.94,17.7L6.5,19.14C8.04,20.3 9.94,21 12,21A9,9 0 0,0 21,12A9,9 0 0,0 12,3M14,12A2,2 0 0,0 12,10A2,2 0 0,0 10,12A2,2 0 0,0 12,14A2,2 0 0,0 14,12Z"}},[t.title?e("title",[t._v(t._s(t.title))]):t._e()])])])}),[],!1,null,null,null).exports,x={name:"DownloadIcon",emits:["click"],props:{title:{type:String},fillColor:{type:String,default:"currentColor"},size:{type:Number,default:24}}},C=(0,_.Z)(x,(function(){var t=this,e=t._self._c;return e("span",t._b({staticClass:"material-design-icon download-icon",attrs:{"aria-hidden":!t.title,"aria-label":t.title,role:"img"},on:{click:function(e){return t.$emit("click",e)}}},"span",t.$attrs,!1),[e("svg",{staticClass:"material-design-icon__svg",attrs:{fill:t.fillColor,width:t.size,height:t.size,viewBox:"0 0 24 24"}},[e("path",{attrs:{d:"M5,20H19V18H5M19,9H15V3H9V9H5L12,16L19,9Z"}},[t.title?e("title",[t._v(t._s(t.title))]):t._e()])])])}),[],!1,null,null,null).exports,N={name:"FileCompareIcon",emits:["click"],props:{title:{type:String},fillColor:{type:String,default:"currentColor"},size:{type:Number,default:24}}},E=(0,_.Z)(N,(function(){var t=this,e=t._self._c;return e("span",t._b({staticClass:"material-design-icon file-compare-icon",attrs:{"aria-hidden":!t.title,"aria-label":t.title,role:"img"},on:{click:function(e){return t.$emit("click",e)}}},"span",t.$attrs,!1),[e("svg",{staticClass:"material-design-icon__svg",attrs:{fill:t.fillColor,width:t.size,height:t.size,viewBox:"0 0 24 24"}},[e("path",{attrs:{d:"M10,18H6V16H10V18M10,14H6V12H10V14M10,1V2H6C4.89,2 4,2.89 4,4V20A2,2 0 0,0 6,22H10V23H12V1H10M20,8V20C20,21.11 19.11,22 18,22H14V20H18V11H14V9H18.5L14,4.5V2L20,8M16,14H14V12H16V14M16,18H14V16H16V18Z"}},[t.title?e("title",[t._v(t._s(t.title))]):t._e()])])])}),[],!1,null,null,null).exports;var V=s(77531),k=s(11734),L=s(42588);const I={name:"ImageOffOutlineIcon",emits:["click"],props:{title:{type:String},fillColor:{type:String,default:"currentColor"},size:{type:Number,default:24}}},O=(0,_.Z)(I,(function(){var t=this,e=t._self._c;return e("span",t._b({staticClass:"material-design-icon image-off-outline-icon",attrs:{"aria-hidden":!t.title,"aria-label":t.title,role:"img"},on:{click:function(e){return t.$emit("click",e)}}},"span",t.$attrs,!1),[e("svg",{staticClass:"material-design-icon__svg",attrs:{fill:t.fillColor,width:t.size,height:t.size,viewBox:"0 0 24 24"}},[e("path",{attrs:{d:"M22 20.7L3.3 2L2 3.3L3 4.3V19C3 20.1 3.9 21 5 21H19.7L20.7 22L22 20.7M5 19V6.3L12.6 13.9L11.1 15.8L9 13.1L6 17H15.7L17.7 19H5M8.8 5L6.8 3H19C20.1 3 21 3.9 21 5V17.2L19 15.2V5H8.8"}},[t.title?e("title",[t._v(t._s(t.title))]):t._e()])])])}),[],!1,null,null,null).exports;var $=s(99059),D=s(41989),P=s(3172),R=s(25475),z=s(74628),F=s(49368),S=s(79845),T=s(43554);const B={name:"Version",components:{NcActionLink:D.Z,NcActionButton:$.Z,NcListItem:P.Z,NcModal:R.Z,NcButton:z.Z,NcTextField:F.Z,BackupRestore:j,Download:C,FileCompare:E,Pencil:V.default,Check:k.default,Delete:L.Z,ImageOffOutline:O},directives:{tooltip:S.Z},filters:{humanReadableSize:t=>OC.Util.humanFileSize(t),humanDateFromNow:t=>h()(t).fromNow()},props:{version:{type:Object,required:!0},fileInfo:{type:Object,required:!0},isCurrent:{type:Boolean,default:!1},isFirstVersion:{type:Boolean,default:!1},loadPreview:{type:Boolean,default:!1},canView:{type:Boolean,default:!1},canCompare:{type:Boolean,default:!1}},data(){return{previewLoaded:!1,previewErrored:!1,showVersionLabelForm:!1,formVersionLabelValue:this.version.label,capabilities:(0,T.j)("core","capabilities",{files:{version_labeling:!1,version_deletion:!1}})}},computed:{versionLabel(){const t=this.version.label??"";return this.isCurrent?""===t?(0,r.Iu)("files_versions","Current version"):`${t} (${(0,r.Iu)("files_versions","Current version")})`:this.isFirstVersion&&""===t?(0,r.Iu)("files_versions","Initial version"):t},downloadURL(){return this.isCurrent?(0,f.getRootUrl)()+(0,p.RQ)("/remote.php/webdav",this.fileInfo.path,this.fileInfo.name):(0,f.getRootUrl)()+this.version.url},formattedDate(){return h()(this.version.mtime).format("LLL")},enableLabeling(){return!0===this.capabilities.files.version_labeling},enableDeletion(){return!0===this.capabilities.files.version_deletion}},methods:{openVersionLabelModal(){this.showVersionLabelForm=!0,this.$nextTick((()=>{this.$refs.labelInput.$el.getElementsByTagName("input")[0].focus()}))},restoreVersion(){this.$emit("restore",this.version)},setVersionLabel(t){this.formVersionLabelValue=t,this.showVersionLabelForm=!1,this.$emit("label-update",this.version,t)},deleteVersion(){this.$emit("delete",this.version)},click(){this.canView?this.$emit("click",{version:this.version}):window.location=this.downloadURL},compareVersion(){if(!this.canView)throw new Error("Cannot compare version of this file");this.$emit("compare",{version:this.version})},t:r.Iu}};var M=s(93379),H=s.n(M),U=s(7795),Z=s.n(U),q=s(90569),G=s.n(q),W=s(3565),Y=s.n(W),K=s(19216),X=s.n(K),Q=s(44589),J=s.n(Q),tt=s(91493),et={};et.styleTagTransform=J(),et.setAttributes=Y(),et.insert=G().bind(null,"head"),et.domAPI=Z(),et.insertStyleElement=X(),H()(tt.Z,et),tt.Z&&tt.Z.locals&&tt.Z.locals;const it={name:"VersionTab",components:{Version:(0,_.Z)(B,(function(){var t=this,e=t._self._c;return e("div",[e("NcListItem",{staticClass:"version",attrs:{name:t.versionLabel,"force-display-actions":!0,"data-files-versions-version":""},on:{click:t.click},scopedSlots:t._u([{key:"icon",fn:function(){return[t.loadPreview||t.previewLoaded?!t.isCurrent&&!t.version.hasPreview||t.previewErrored?e("div",{staticClass:"version__image"},[e("ImageOffOutline",{attrs:{size:20}})],1):e("img",{staticClass:"version__image",attrs:{src:t.version.previewUrl,alt:"",decoding:"async",fetchpriority:"low",loading:"lazy"},on:{load:function(e){t.previewLoaded=!0},error:function(e){t.previewErrored=!0}}}):e("div",{staticClass:"version__image"})]},proxy:!0},{key:"subname",fn:function(){return[e("div",{staticClass:"version__info"},[e("span",{attrs:{title:t.formattedDate}},[t._v(t._s(t._f("humanDateFromNow")(t.version.mtime)))]),t._v(" "),e("span",{staticClass:"version__info__size"},[t._v("•")]),t._v(" "),e("span",{staticClass:"version__info__size"},[t._v(t._s(t._f("humanReadableSize")(t.version.size)))])])]},proxy:!0},{key:"actions",fn:function(){return[t.enableLabeling?e("NcActionButton",{attrs:{"close-after-click":!0},on:{click:t.openVersionLabelModal},scopedSlots:t._u([{key:"icon",fn:function(){return[e("Pencil",{attrs:{size:22}})]},proxy:!0}],null,!1,3072546167)},[t._v("\n\t\t\t\t"+t._s(""===t.version.label?t.t("files_versions","Name this version"):t.t("files_versions","Edit version name"))+"\n\t\t\t")]):t._e(),t._v(" "),!t.isCurrent&&t.canView&&t.canCompare?e("NcActionButton",{attrs:{"close-after-click":!0},on:{click:t.compareVersion},scopedSlots:t._u([{key:"icon",fn:function(){return[e("FileCompare",{attrs:{size:22}})]},proxy:!0}],null,!1,1958207595)},[t._v("\n\t\t\t\t"+t._s(t.t("files_versions","Compare to current version"))+"\n\t\t\t")]):t._e(),t._v(" "),t.isCurrent?t._e():e("NcActionButton",{attrs:{"close-after-click":!0},on:{click:t.restoreVersion},scopedSlots:t._u([{key:"icon",fn:function(){return[e("BackupRestore",{attrs:{size:22}})]},proxy:!0}],null,!1,2239038444)},[t._v("\n\t\t\t\t"+t._s(t.t("files_versions","Restore version"))+"\n\t\t\t")]),t._v(" "),e("NcActionLink",{attrs:{href:t.downloadURL,"close-after-click":!0,download:t.downloadURL},scopedSlots:t._u([{key:"icon",fn:function(){return[e("Download",{attrs:{size:22}})]},proxy:!0}])},[t._v("\n\t\t\t\t"+t._s(t.t("files_versions","Download version"))+"\n\t\t\t")]),t._v(" "),!t.isCurrent&&t.enableDeletion?e("NcActionButton",{attrs:{"close-after-click":!0},on:{click:t.deleteVersion},scopedSlots:t._u([{key:"icon",fn:function(){return[e("Delete",{attrs:{size:22}})]},proxy:!0}],null,!1,2429175571)},[t._v("\n\t\t\t\t"+t._s(t.t("files_versions","Delete version"))+"\n\t\t\t")]):t._e()]},proxy:!0}])}),t._v(" "),t.showVersionLabelForm?e("NcModal",{attrs:{title:t.t("files_versions","Name this version")},on:{close:function(e){t.showVersionLabelForm=!1}}},[e("form",{staticClass:"version-label-modal",on:{submit:function(e){return e.preventDefault(),t.setVersionLabel(t.formVersionLabelValue)}}},[e("label",[e("div",{staticClass:"version-label-modal__title"},[t._v(t._s(t.t("files_versions","Version name")))]),t._v(" "),e("NcTextField",{ref:"labelInput",attrs:{value:t.formVersionLabelValue,placeholder:t.t("files_versions","Version name"),"label-outside":!0},on:{"update:value":function(e){t.formVersionLabelValue=e}}})],1),t._v(" "),e("div",{staticClass:"version-label-modal__info"},[t._v("\n\t\t\t\t"+t._s(t.t("files_versions","Named versions are persisted, and excluded from automatic cleanups when your storage quota is full."))+"\n\t\t\t")]),t._v(" "),e("div",{staticClass:"version-label-modal__actions"},[e("NcButton",{attrs:{disabled:0===t.formVersionLabelValue.trim().length},on:{click:function(e){return t.setVersionLabel("")}}},[t._v("\n\t\t\t\t\t"+t._s(t.t("files_versions","Remove version name"))+"\n\t\t\t\t")]),t._v(" "),e("NcButton",{attrs:{type:"primary","native-type":"submit"},scopedSlots:t._u([{key:"icon",fn:function(){return[e("Check")]},proxy:!0}],null,!1,2308323205)},[t._v("\n\t\t\t\t\t"+t._s(t.t("files_versions","Save version name"))+"\n\t\t\t\t")])],1)])]):t._e()],1)}),[],!1,null,"82ff3254",null).exports},mixins:[c.Z],data:()=>({fileInfo:null,isActive:!1,versions:[],loading:!1}),mounted(){(0,d.Ld)("files_versions:restore:restored",this.fetchVersions)},beforeUnmount(){(0,d.r1)("files_versions:restore:restored",this.fetchVersions)},computed:{orderedVersions(){return[...this.versions].sort(((t,e)=>t.mtime===this.fileInfo.mtime?-1:e.mtime===this.fileInfo.mtime?1:e.mtime-t.mtime))},initialVersionMtime(){return this.versions.map((t=>t.mtime)).reduce(((t,e)=>Math.min(t,e)))},viewerFileInfo(){let t="";return 1&this.fileInfo.permissions&&(t+="R"),2&this.fileInfo.permissions&&(t+="W"),8&this.fileInfo.permissions&&(t+="D"),{...this.fileInfo,mime:this.fileInfo.mimetype,basename:this.fileInfo.name,filename:this.fileInfo.path+"/"+this.fileInfo.name,permissions:t,fileid:this.fileInfo.id}},canView(){return window.OCA.Viewer?.mimetypesCompare?.includes(this.fileInfo.mimetype)},canCompare(){return!this.isMobile}},methods:{async update(t){this.fileInfo=t,this.resetState(),this.fetchVersions()},async setIsActive(t){this.isActive=t},async fetchVersions(){try{this.loading=!0,this.versions=await async function(t){const e=`/versions/${(0,u.ts)()?.uid}/versions/${t.id}`;try{return(await A.getDirectoryContents(e,{data:'<?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\txmlns:ocs="http://open-collaboration-services.org/ns">\n\t<d:prop>\n\t\t<d:getcontentlength />\n\t\t<d:getcontenttype />\n\t\t<d:getlastmodified />\n\t\t<d:getetag />\n\t\t<nc:version-label />\n\t\t<nc:has-preview />\n\t</d:prop>\n</d:propfind>',details:!0})).data.filter((t=>{let{mime:e}=t;return""!==e})).map((e=>function(t,e){const i=1e3*h()(t.lastmod).unix();let s="";return s=i===e.mtime?(0,f.generateUrl)("/core/preview?fileId={fileId}&c={fileEtag}&x=250&y=250&forceIcon=0&a=0",{fileId:e.id,fileEtag:e.etag}):(0,f.generateUrl)("/apps/files_versions/preview?file={file}&version={fileVersion}",{file:(0,p.RQ)(e.path,e.name),fileVersion:t.basename}),{fileId:e.id,label:t.props["version-label"],filename:t.filename,basename:h()(i).format("LLL"),mime:t.mime,etag:`${t.props.getetag}`,size:t.size,type:t.type,mtime:i,permissions:"R",hasPreview:1===t.props["has-preview"],previewUrl:s,url:(0,p.RQ)("/remote.php/dav",t.filename),source:(0,f.generateRemoteUrl)("dav")+v(t.filename),fileVersion:t.basename}}(e,t)))}catch(t){throw w.error("Could not fetch version",{exception:t}),t}}(this.fileInfo)}finally{this.loading=!1}},async handleRestore(e){const i=this.fileInfo;this.fileInfo={...this.fileInfo,size:e.size,mtime:e.mtime};const s={preventDefault:!1,fileInfo:this.fileInfo,version:e};if((0,d.j8)("files_versions:restore:requested",s),!s.preventDefault)try{await async function(t){try{w.debug("Restoring version",{url:t.url}),await A.moveFile(`/versions/${(0,u.ts)()?.uid}/versions/${t.fileId}/${t.fileVersion}`,`/versions/${(0,u.ts)()?.uid}/restore/target`)}catch(t){throw w.error("Could not restore version",{exception:t}),t}}(e),""!==e.label?(0,l.s$)(t("files_versions",`${e.label} restored`)):e.mtime===this.initialVersionMtime?(0,l.s$)(t("files_versions","Initial version restored")):(0,l.s$)(t("files_versions","Version restored")),(0,d.j8)("files_versions:restore:restored",e)}catch(s){this.fileInfo=i,(0,l.x2)(t("files_versions","Could not restore version")),(0,d.j8)("files_versions:restore:failed",e)}},async handleLabelUpdate(e,i){const s=e.label;e.label=i;try{await async function(t,e){return await A.customRequest(t.filename,{method:"PROPPATCH",data:`<?xml version="1.0"?>\n\t\t\t\t\t<d:propertyupdate xmlns:d="DAV:"\n\t\t\t\t\t\txmlns:oc="http://owncloud.org/ns"\n\t\t\t\t\t\txmlns:nc="http://nextcloud.org/ns"\n\t\t\t\t\t\txmlns:ocs="http://open-collaboration-services.org/ns">\n\t\t\t\t\t<d:set>\n\t\t\t\t\t\t<d:prop>\n\t\t\t\t\t\t\t<nc:version-label>${e}</nc:version-label>\n\t\t\t\t\t\t</d:prop>\n\t\t\t\t\t</d:set>\n\t\t\t\t\t</d:propertyupdate>`})}(e,i)}catch(i){e.label=s,(0,l.x2)(t("files_versions","Could not set version name"))}},async handleDelete(e){const i=this.versions.indexOf(e);this.versions.splice(i,1);try{await async function(t){await A.deleteFile(t.filename)}(e)}catch(i){this.versions.push(e),(0,l.x2)(t("files_versions","Could not delete version"))}},resetState(){this.$set(this,"versions",[])},openVersion(t){let{version:e}=t;if(e.mtime===this.fileInfo.mtime)return void OCA.Viewer.open({fileInfo:this.viewerFileInfo});const i=this.versions.map((t=>({...t,filename:t.mtime===this.fileInfo.mtime?a().join("files",(0,u.ts)()?.uid??"",this.fileInfo.path,this.fileInfo.name):t.filename,hasPreview:!1,previewUrl:void 0})));OCA.Viewer.open({fileInfo:i.find((t=>t.source===e.source)),enableSidebar:!1})},compareVersion(t){let{version:e}=t;const i=this.versions.map((t=>({...t,hasPreview:!1,previewUrl:void 0})));OCA.Viewer.compare(this.viewerFileInfo,i.find((t=>t.source===e.source)))}}},st=(0,_.Z)(it,(function(){var t=this,e=t._self._c;return e("ul",{attrs:{"data-files-versions-versions-list":""}},t._l(t.orderedVersions,(function(i){return e("Version",{key:i.mtime,attrs:{"can-view":t.canView,"can-compare":t.canCompare,"load-preview":t.isActive,version:i,"file-info":t.fileInfo,"is-current":i.mtime===t.fileInfo.mtime,"is-first-version":i.mtime===t.initialVersionMtime},on:{click:t.openVersion,compare:t.compareVersion,restore:t.handleRestore,"label-update":t.handleLabelUpdate,delete:t.handleDelete}})})),1)}),[],!1,null,null,null).exports;var nt=s(2324);n.default.prototype.t=r.Iu,n.default.prototype.n=r.uN,n.default.use(nt.ZP);const rt=n.default.extend(st);let ot=null;window.addEventListener("DOMContentLoaded",(function(){void 0!==OCA.Files?.Sidebar&&OCA.Files.Sidebar.registerTab(new OCA.Files.Sidebar.Tab({id:"version_vue",name:(0,r.Iu)("files_versions","Versions"),iconSvg:'<svg xmlns="http://www.w3.org/2000/svg" id="mdi-backup-restore" viewBox="0 0 24 24"><path d="M12,3A9,9 0 0,0 3,12H0L4,16L8,12H5A7,7 0 0,1 12,5A7,7 0 0,1 19,12A7,7 0 0,1 12,19C10.5,19 9.09,18.5 7.94,17.7L6.5,19.14C8.04,20.3 9.94,21 12,21A9,9 0 0,0 21,12A9,9 0 0,0 12,3M14,12A2,2 0 0,0 12,10A2,2 0 0,0 10,12A2,2 0 0,0 12,14A2,2 0 0,0 14,12Z" /></svg>',async mount(t,e,i){ot&&ot.$destroy(),ot=new rt({parent:i}),await ot.update(e),ot.$mount(t)},update(t){ot.update(t)},setIsActive(t){ot&&ot.setIsActive(t)},destroy(){ot.$destroy(),ot=null},enabled:t=>!(t?.isDirectory()??1)}))}))},91493:(t,e,i)=>{"use strict";i.d(e,{Z:()=>a});var s=i(87537),n=i.n(s),r=i(23645),o=i.n(r)()(n());o.push([t.id,".version[data-v-82ff3254]{display:flex;flex-direction:row}.version__info[data-v-82ff3254]{display:flex;flex-direction:row;align-items:center;gap:.5rem}.version__info__size[data-v-82ff3254]{color:var(--color-text-lighter)}.version__image[data-v-82ff3254]{width:3rem;height:3rem;border:1px solid var(--color-border);border-radius:var(--border-radius-large);display:flex;justify-content:center;color:var(--color-text-light)}.version-label-modal[data-v-82ff3254]{display:flex;justify-content:space-between;flex-direction:column;height:250px;padding:16px}.version-label-modal__title[data-v-82ff3254]{margin-bottom:12px;font-weight:600}.version-label-modal__info[data-v-82ff3254]{margin-top:12px;color:var(--color-text-maxcontrast)}.version-label-modal__actions[data-v-82ff3254]{display:flex;justify-content:space-between;margin-top:64px}","",{version:3,sources:["webpack://./apps/files_versions/src/components/Version.vue"],names:[],mappings:"AACA,0BACC,YAAA,CACA,kBAAA,CAEA,gCACC,YAAA,CACA,kBAAA,CACA,kBAAA,CACA,SAAA,CAEA,sCACC,+BAAA,CAIF,iCACC,UAAA,CACA,WAAA,CACA,oCAAA,CACA,wCAAA,CAGA,YAAA,CACA,sBAAA,CACA,6BAAA,CAIF,sCACC,YAAA,CACA,6BAAA,CACA,qBAAA,CACA,YAAA,CACA,YAAA,CAEA,6CACC,kBAAA,CACA,eAAA,CAGD,4CACC,eAAA,CACA,mCAAA,CAGD,+CACC,YAAA,CACA,6BAAA,CACA,eAAA",sourcesContent:["\n.version {\n\tdisplay: flex;\n\tflex-direction: row;\n\n\t&__info {\n\t\tdisplay: flex;\n\t\tflex-direction: row;\n\t\talign-items: center;\n\t\tgap: 0.5rem;\n\n\t\t&__size {\n\t\t\tcolor: var(--color-text-lighter);\n\t\t}\n\t}\n\n\t&__image {\n\t\twidth: 3rem;\n\t\theight: 3rem;\n\t\tborder: 1px solid var(--color-border);\n\t\tborder-radius: var(--border-radius-large);\n\n\t\t// Useful to display no preview icon.\n\t\tdisplay: flex;\n\t\tjustify-content: center;\n\t\tcolor: var(--color-text-light);\n\t}\n}\n\n.version-label-modal {\n\tdisplay: flex;\n\tjustify-content: space-between;\n\tflex-direction: column;\n\theight: 250px;\n\tpadding: 16px;\n\n\t&__title {\n\t\tmargin-bottom: 12px;\n\t\tfont-weight: 600;\n\t}\n\n\t&__info {\n\t\tmargin-top: 12px;\n\t\tcolor: var(--color-text-maxcontrast);\n\t}\n\n\t&__actions {\n\t\tdisplay: flex;\n\t\tjustify-content: space-between;\n\t\tmargin-top: 64px;\n\t}\n}\n"],sourceRoot:""}]);const a=o},46700:(t,e,i)=>{var s={"./af":42786,"./af.js":42786,"./ar":30867,"./ar-dz":14130,"./ar-dz.js":14130,"./ar-kw":96135,"./ar-kw.js":96135,"./ar-ly":56440,"./ar-ly.js":56440,"./ar-ma":47702,"./ar-ma.js":47702,"./ar-sa":16040,"./ar-sa.js":16040,"./ar-tn":37100,"./ar-tn.js":37100,"./ar.js":30867,"./az":31083,"./az.js":31083,"./be":9808,"./be.js":9808,"./bg":68338,"./bg.js":68338,"./bm":67438,"./bm.js":67438,"./bn":8905,"./bn-bd":76225,"./bn-bd.js":76225,"./bn.js":8905,"./bo":11560,"./bo.js":11560,"./br":1278,"./br.js":1278,"./bs":80622,"./bs.js":80622,"./ca":2468,"./ca.js":2468,"./cs":5822,"./cs.js":5822,"./cv":50877,"./cv.js":50877,"./cy":47373,"./cy.js":47373,"./da":24780,"./da.js":24780,"./de":59740,"./de-at":60217,"./de-at.js":60217,"./de-ch":60894,"./de-ch.js":60894,"./de.js":59740,"./dv":5300,"./dv.js":5300,"./el":50837,"./el.js":50837,"./en-au":78348,"./en-au.js":78348,"./en-ca":77925,"./en-ca.js":77925,"./en-gb":22243,"./en-gb.js":22243,"./en-ie":46436,"./en-ie.js":46436,"./en-il":47207,"./en-il.js":47207,"./en-in":44175,"./en-in.js":44175,"./en-nz":76319,"./en-nz.js":76319,"./en-sg":31662,"./en-sg.js":31662,"./eo":92915,"./eo.js":92915,"./es":55655,"./es-do":55251,"./es-do.js":55251,"./es-mx":96112,"./es-mx.js":96112,"./es-us":71146,"./es-us.js":71146,"./es.js":55655,"./et":5603,"./et.js":5603,"./eu":77763,"./eu.js":77763,"./fa":76959,"./fa.js":76959,"./fi":11897,"./fi.js":11897,"./fil":42549,"./fil.js":42549,"./fo":94694,"./fo.js":94694,"./fr":94470,"./fr-ca":63049,"./fr-ca.js":63049,"./fr-ch":52330,"./fr-ch.js":52330,"./fr.js":94470,"./fy":5044,"./fy.js":5044,"./ga":29295,"./ga.js":29295,"./gd":2101,"./gd.js":2101,"./gl":38794,"./gl.js":38794,"./gom-deva":27884,"./gom-deva.js":27884,"./gom-latn":23168,"./gom-latn.js":23168,"./gu":95349,"./gu.js":95349,"./he":24206,"./he.js":24206,"./hi":30094,"./hi.js":30094,"./hr":30316,"./hr.js":30316,"./hu":22138,"./hu.js":22138,"./hy-am":11423,"./hy-am.js":11423,"./id":29218,"./id.js":29218,"./is":90135,"./is.js":90135,"./it":90626,"./it-ch":10150,"./it-ch.js":10150,"./it.js":90626,"./ja":39183,"./ja.js":39183,"./jv":24286,"./jv.js":24286,"./ka":12105,"./ka.js":12105,"./kk":47772,"./kk.js":47772,"./km":18758,"./km.js":18758,"./kn":79282,"./kn.js":79282,"./ko":33730,"./ko.js":33730,"./ku":1408,"./ku.js":1408,"./ky":33291,"./ky.js":33291,"./lb":36841,"./lb.js":36841,"./lo":55466,"./lo.js":55466,"./lt":57010,"./lt.js":57010,"./lv":37595,"./lv.js":37595,"./me":39861,"./me.js":39861,"./mi":35493,"./mi.js":35493,"./mk":95966,"./mk.js":95966,"./ml":87341,"./ml.js":87341,"./mn":5115,"./mn.js":5115,"./mr":10370,"./mr.js":10370,"./ms":9847,"./ms-my":41237,"./ms-my.js":41237,"./ms.js":9847,"./mt":72126,"./mt.js":72126,"./my":56165,"./my.js":56165,"./nb":64924,"./nb.js":64924,"./ne":16744,"./ne.js":16744,"./nl":93901,"./nl-be":59814,"./nl-be.js":59814,"./nl.js":93901,"./nn":83877,"./nn.js":83877,"./oc-lnc":92135,"./oc-lnc.js":92135,"./pa-in":15858,"./pa-in.js":15858,"./pl":64495,"./pl.js":64495,"./pt":89520,"./pt-br":57971,"./pt-br.js":57971,"./pt.js":89520,"./ro":96459,"./ro.js":96459,"./ru":21793,"./ru.js":21793,"./sd":40950,"./sd.js":40950,"./se":10490,"./se.js":10490,"./si":90124,"./si.js":90124,"./sk":64249,"./sk.js":64249,"./sl":14985,"./sl.js":14985,"./sq":51104,"./sq.js":51104,"./sr":49131,"./sr-cyrl":79915,"./sr-cyrl.js":79915,"./sr.js":49131,"./ss":85893,"./ss.js":85893,"./sv":98760,"./sv.js":98760,"./sw":91172,"./sw.js":91172,"./ta":27333,"./ta.js":27333,"./te":23110,"./te.js":23110,"./tet":52095,"./tet.js":52095,"./tg":27321,"./tg.js":27321,"./th":9041,"./th.js":9041,"./tk":19005,"./tk.js":19005,"./tl-ph":75768,"./tl-ph.js":75768,"./tlh":89444,"./tlh.js":89444,"./tr":72397,"./tr.js":72397,"./tzl":28254,"./tzl.js":28254,"./tzm":51106,"./tzm-latn":30699,"./tzm-latn.js":30699,"./tzm.js":51106,"./ug-cn":9288,"./ug-cn.js":9288,"./uk":67691,"./uk.js":67691,"./ur":13795,"./ur.js":13795,"./uz":6791,"./uz-latn":60588,"./uz-latn.js":60588,"./uz.js":6791,"./vi":65666,"./vi.js":65666,"./x-pseudo":14378,"./x-pseudo.js":14378,"./yo":75805,"./yo.js":75805,"./zh-cn":83839,"./zh-cn.js":83839,"./zh-hk":55726,"./zh-hk.js":55726,"./zh-mo":99807,"./zh-mo.js":99807,"./zh-tw":74152,"./zh-tw.js":74152};function n(t){var e=r(t);return i(e)}function r(t){if(!i.o(s,t)){var e=new Error("Cannot find module '"+t+"'");throw e.code="MODULE_NOT_FOUND",e}return s[t]}n.keys=function(){return Object.keys(s)},n.resolve=r,t.exports=n,n.id=46700},5656:(t,e,i)=>{"use strict";i.d(e,{RL:()=>O,Tv:()=>y,_o:()=>V,h7:()=>A,pC:()=>I,rp:()=>L,sS:()=>f,tB:()=>w});var s,n=i(77958),r=i(17499),o=i(31352),a=i(62520),l=i(65358),c=i(79753),d=i(14596);null===(s=(0,n.ts)())?(0,r.IY)().setApp("files").build():(0,r.IY)().setApp("files").setUid(s.uid).build();const u=["B","KB","MB","GB","TB","PB"],p=["B","KiB","MiB","GiB","TiB","PiB"];function f(t,e=!1,i=!1,s=!1){i=i&&!s,"string"==typeof t&&(t=Number(t));let n=t>0?Math.floor(Math.log(t)/Math.log(s?1e3:1024)):0;n=Math.min((i?p.length:u.length)-1,n);const r=i?p[n]:u[n];let a=(t/Math.pow(s?1e3:1024,n)).toFixed(1);return!0===e&&0===n?("0.0"!==a?"< 1 ":"0 ")+(i?p[1]:u[1]):(a=n<2?parseFloat(a).toFixed(0):parseFloat(a).toLocaleString((0,o.aj)()),a+" "+r)}var m=(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))(m||{});const h=["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"],v={d:"DAV:",nc:"http://nextcloud.org/ns",oc:"http://owncloud.org/ns",ocs:"http://open-collaboration-services.org/ns"},g=function(){return typeof window._nc_dav_properties>"u"&&(window._nc_dav_properties=[...h]),window._nc_dav_properties.map((t=>`<${t} />`)).join(" ")},b=function(){return typeof window._nc_dav_namespaces>"u"&&(window._nc_dav_namespaces={...v}),Object.keys(window._nc_dav_namespaces).map((t=>`xmlns:${t}="${window._nc_dav_namespaces?.[t]}"`)).join(" ")},A=function(){return`<?xml version="1.0"?>\n\t\t<d:propfind ${b()}>\n\t\t\t<d:prop>\n\t\t\t\t${g()}\n\t\t\t</d:prop>\n\t\t</d:propfind>`},w=function(t){return`<?xml version="1.0" encoding="UTF-8"?>\n<d:searchrequest ${b()}\n\txmlns:ns="https://github.com/icewind1991/SearchDAV/ns">\n\t<d:basicsearch>\n\t\t<d:select>\n\t\t\t<d:prop>\n\t\t\t\t${g()}\n\t\t\t</d:prop>\n\t\t</d:select>\n\t\t<d:from>\n\t\t\t<d:scope>\n\t\t\t\t<d:href>/files/${(0,n.ts)()?.uid}/</d:href>\n\t\t\t\t<d:depth>infinity</d:depth>\n\t\t\t</d:scope>\n\t\t</d:from>\n\t\t<d:where>\n\t\t\t<d:and>\n\t\t\t\t<d:or>\n\t\t\t\t\t<d:not>\n\t\t\t\t\t\t<d:eq>\n\t\t\t\t\t\t\t<d:prop>\n\t\t\t\t\t\t\t\t<d:getcontenttype/>\n\t\t\t\t\t\t\t</d:prop>\n\t\t\t\t\t\t\t<d:literal>httpd/unix-directory</d:literal>\n\t\t\t\t\t\t</d:eq>\n\t\t\t\t\t</d:not>\n\t\t\t\t\t<d:eq>\n\t\t\t\t\t\t<d:prop>\n\t\t\t\t\t\t\t<oc:size/>\n\t\t\t\t\t\t</d:prop>\n\t\t\t\t\t\t<d:literal>0</d:literal>\n\t\t\t\t\t</d:eq>\n\t\t\t\t</d:or>\n\t\t\t\t<d:gt>\n\t\t\t\t\t<d:prop>\n\t\t\t\t\t\t<d:getlastmodified/>\n\t\t\t\t\t</d:prop>\n\t\t\t\t\t<d:literal>${t}</d:literal>\n\t\t\t\t</d:gt>\n\t\t\t</d:and>\n\t\t</d:where>\n\t\t<d:orderby>\n\t\t\t<d:order>\n\t\t\t\t<d:prop>\n\t\t\t\t\t<d:getlastmodified/>\n\t\t\t\t</d:prop>\n\t\t\t\t<d:descending/>\n\t\t\t</d:order>\n\t\t</d:orderby>\n\t\t<d:limit>\n\t\t\t<d:nresults>100</d:nresults>\n\t\t\t<ns:firstresult>0</ns:firstresult>\n\t\t</d:limit>\n\t</d:basicsearch>\n</d:searchrequest>`};var y=(t=>(t.Folder="folder",t.File="file",t))(y||{});const _=function(t,e){return null!==t.match(e)},j=(t,e)=>{if(t.id&&"number"!=typeof t.id)throw new Error("Invalid id type of value");if(!t.source)throw new Error("Missing mandatory source");try{new URL(t.source)}catch{throw new Error("Invalid source format, source must be a valid URL")}if(!t.source.startsWith("http"))throw new Error("Invalid source format, only http(s) is supported");if(t.mtime&&!(t.mtime instanceof Date))throw new Error("Invalid mtime type");if(t.crtime&&!(t.crtime instanceof Date))throw new Error("Invalid crtime type");if(!t.mime||"string"!=typeof t.mime||!t.mime.match(/^[-\w.]+\/[-+\w.]+$/gi))throw new Error("Missing or invalid mandatory mime");if("size"in t&&"number"!=typeof t.size&&void 0!==t.size)throw new Error("Invalid size type");if("permissions"in t&&void 0!==t.permissions&&!("number"==typeof t.permissions&&t.permissions>=m.NONE&&t.permissions<=m.ALL))throw new Error("Invalid permissions");if(t.owner&&null!==t.owner&&"string"!=typeof t.owner)throw new Error("Invalid owner type");if(t.attributes&&"object"!=typeof t.attributes)throw new Error("Invalid attributes type");if(t.root&&"string"!=typeof t.root)throw new Error("Invalid root type");if(t.root&&!t.root.startsWith("/"))throw new Error("Root must start with a leading slash");if(t.root&&!t.source.includes(t.root))throw new Error("Root must be part of the source");if(t.root&&_(t.source,e)){const i=t.source.match(e)[0];if(!t.source.includes((0,a.join)(i,t.root)))throw new Error("The root must be relative to the service. e.g /files/emma")}if(t.status&&!Object.values(x).includes(t.status))throw new Error("Status must be a valid NodeStatus")};var x=(t=>(t.NEW="new",t.FAILED="failed",t.LOADING="loading",t.LOCKED="locked",t))(x||{});class C{_data;_attributes;_knownDavService=/(remote|public)\.php\/(web)?dav/i;constructor(t,e){j(t,e||this._knownDavService),this._data=t;const i={set:(t,e,i)=>(this.updateMtime(),Reflect.set(t,e,i)),deleteProperty:(t,e)=>(this.updateMtime(),Reflect.deleteProperty(t,e))};this._attributes=new Proxy(t.attributes||{},i),delete this._data.attributes,e&&(this._knownDavService=e)}get source(){return this._data.source.replace(/\/$/i,"")}get encodedSource(){const{origin:t}=new URL(this.source);return t+(0,l.Ec)(this.source.slice(t.length))}get basename(){return(0,a.basename)(this.source)}get extension(){return(0,a.extname)(this.source)}get dirname(){if(this.root){const t=this.source.indexOf(this.root);return(0,a.dirname)(this.source.slice(t+this.root.length)||"/")}const t=new URL(this.source);return(0,a.dirname)(t.pathname)}get mime(){return this._data.mime}get mtime(){return this._data.mtime}get crtime(){return this._data.crtime}get size(){return this._data.size}get attributes(){return this._attributes}get permissions(){return null!==this.owner||this.isDavRessource?void 0!==this._data.permissions?this._data.permissions:m.NONE:m.READ}get owner(){return this.isDavRessource?this._data.owner:null}get isDavRessource(){return _(this.source,this._knownDavService)}get root(){return this._data.root?this._data.root.replace(/^(.+)\/$/,"$1"):this.isDavRessource&&(0,a.dirname)(this.source).split(this._knownDavService).pop()||null}get path(){if(this.root){const t=this.source.indexOf(this.root);return this.source.slice(t+this.root.length)||"/"}return(this.dirname+"/"+this.basename).replace(/\/\//g,"/")}get fileid(){return this._data?.id||this.attributes?.fileid}get status(){return this._data?.status}set status(t){this._data.status=t}move(t){j({...this._data,source:t},this._knownDavService),this._data.source=t,this.updateMtime()}rename(t){if(t.includes("/"))throw new Error("Invalid basename");this.move((0,a.dirname)(this.source)+"/"+t)}updateMtime(){this._data.mtime&&(this._data.mtime=new Date)}}class N extends C{get type(){return y.File}}class E extends C{constructor(t){super({...t,mime:"httpd/unix-directory"})}get type(){return y.Folder}get extension(){return null}get mime(){return"httpd/unix-directory"}}const V=`/files/${(0,n.ts)()?.uid}`,k=(0,c.generateRemoteUrl)("dav"),L=function(t=k){const e=(0,d.eI)(t);function i(t){e.setHeaders({"X-Requested-With":"XMLHttpRequest",requesttoken:t??""})}return(0,n._S)(i),i((0,n.IH)()),(0,d.lD)().patch("fetch",((t,e)=>{const i=e.headers;return i?.method&&(e.method=i.method,delete i.method),fetch(t,e)})),e},I=async(t,e="/",i=V)=>(await t.getDirectoryContents(`${i}${e}`,{details:!0,data:`<?xml version="1.0"?>\n\t\t<oc:filter-files ${b()}>\n\t\t\t<d:prop>\n\t\t\t\t${g()}\n\t\t\t</d:prop>\n\t\t\t<oc:filter-rules>\n\t\t\t\t<oc:favorite>1</oc:favorite>\n\t\t\t</oc:filter-rules>\n\t\t</oc:filter-files>`,headers:{method:"REPORT"},includeSelf:!0})).data.filter((t=>t.filename!==e)).map((t=>O(t,i))),O=function(t,e=V,i=k){const s=t.props,r=function(t=""){let e=m.NONE;return t&&((t.includes("C")||t.includes("K"))&&(e|=m.CREATE),t.includes("G")&&(e|=m.READ),(t.includes("W")||t.includes("N")||t.includes("V"))&&(e|=m.UPDATE),t.includes("D")&&(e|=m.DELETE),t.includes("R")&&(e|=m.SHARE)),e}(s?.permissions),o=(0,n.ts)()?.uid,a={id:s?.fileid||0,source:`${i}${t.filename}`,mtime:new Date(Date.parse(t.lastmod)),mime:t.mime,size:s?.size||Number.parseInt(s.getcontentlength||"0"),permissions:r,owner:o,root:e,attributes:{...t,...s,hasPreview:s?.["has-preview"]}};return delete a.attributes?.props,"file"===t.type?new N(a):new E(a)};var $={};!function(t){const e=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",i="["+e+"]["+e+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*",s=new RegExp("^"+i+"$");t.isExist=function(t){return typeof t<"u"},t.isEmptyObject=function(t){return 0===Object.keys(t).length},t.merge=function(t,e,i){if(e){const s=Object.keys(e),n=s.length;for(let r=0;r<n;r++)t[s[r]]="strict"===i?[e[s[r]]]:e[s[r]]}},t.getValue=function(e){return t.isExist(e)?e:""},t.isName=function(t){const e=s.exec(t);return!(null===e||typeof e>"u")},t.getAllMatches=function(t,e){const i=[];let s=e.exec(t);for(;s;){const n=[];n.startIndex=e.lastIndex-s[0].length;const r=s.length;for(let t=0;t<r;t++)n.push(s[t]);i.push(n),s=e.exec(t)}return i},t.nameRegexp=i}($);new RegExp("(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['\"])(([\\s\\S])*?)\\5)?","g");var D={};const P={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(t,e){return e},attributeValueProcessor:function(t,e){return e},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(t,e,i){return t}};D.buildOptions=function(t){return Object.assign({},P,t)},D.defaultOptions=P,!Number.parseInt&&window.parseInt&&(Number.parseInt=window.parseInt),!Number.parseFloat&&window.parseFloat&&(Number.parseFloat=window.parseFloat);"<((!\\[CDATA\\[([\\s\\S]*?)(]]>))|((NAME:)?(NAME))([^>]*)>|((\\/)(NAME)\\s*>))([^<]*)".replace(/NAME/g,$.nameRegexp),new RegExp("([^\\s=]+)\\s*(=\\s*(['\"])([\\s\\S]*?)\\3)?","gm");var R={};function z(t,e,i){let s;const n={};for(let r=0;r<t.length;r++){const o=t[r],a=F(o);let l="";if(l=void 0===i?a:i+"."+a,a===e.textNodeName)void 0===s?s=o[a]:s+=""+o[a];else{if(void 0===a)continue;if(o[a]){let t=z(o[a],e,l);const i=T(t,e);o[":@"]?S(t,o[":@"],l,e):1!==Object.keys(t).length||void 0===t[e.textNodeName]||e.alwaysCreateTextNode?0===Object.keys(t).length&&(e.alwaysCreateTextNode?t[e.textNodeName]="":t=""):t=t[e.textNodeName],void 0!==n[a]&&n.hasOwnProperty(a)?(Array.isArray(n[a])||(n[a]=[n[a]]),n[a].push(t)):e.isArray(a,l,i)?n[a]=[t]:n[a]=t}}}return"string"==typeof s?s.length>0&&(n[e.textNodeName]=s):void 0!==s&&(n[e.textNodeName]=s),n}function F(t){const e=Object.keys(t);for(let t=0;t<e.length;t++){const i=e[t];if(":@"!==i)return i}}function S(t,e,i,s){if(e){const n=Object.keys(e),r=n.length;for(let o=0;o<r;o++){const r=n[o];s.isArray(r,i+"."+r,!0,!0)?t[r]=[e[r]]:t[r]=e[r]}}}function T(t,e){const{textNodeName:i}=e,s=Object.keys(t).length;return!(0!==s&&(1!==s||!t[i]&&"boolean"!=typeof t[i]&&0!==t[i]))}R.prettify=function(t,e){return z(t,e)};const{buildOptions:B}=D,{prettify:M}=R;function H(t,e,i,s){let n="",r=!1;for(let o=0;o<t.length;o++){const a=t[o],l=U(a);if(void 0===l)continue;let c="";if(c=0===i.length?l:`${i}.${l}`,l===e.textNodeName){let t=a[l];q(c,e)||(t=e.tagValueProcessor(l,t),t=G(t,e)),r&&(n+=s),n+=t,r=!1;continue}if(l===e.cdataPropName){r&&(n+=s),n+=`<![CDATA[${a[l][0][e.textNodeName]}]]>`,r=!1;continue}if(l===e.commentPropName){n+=s+`\x3c!--${a[l][0][e.textNodeName]}--\x3e`,r=!0;continue}if("?"===l[0]){const t=Z(a[":@"],e),i="?xml"===l?"":s;let o=a[l][0][e.textNodeName];o=0!==o.length?" "+o:"",n+=i+`<${l}${o}${t}?>`,r=!0;continue}let d=s;""!==d&&(d+=e.indentBy);const u=s+`<${l}${Z(a[":@"],e)}`,p=H(a[l],e,c,d);-1!==e.unpairedTags.indexOf(l)?e.suppressUnpairedNode?n+=u+">":n+=u+"/>":p&&0!==p.length||!e.suppressEmptyNode?p&&p.endsWith(">")?n+=u+`>${p}${s}</${l}>`:(n+=u+">",p&&""!==s&&(p.includes("/>")||p.includes("</"))?n+=s+e.indentBy+p+s:n+=p,n+=`</${l}>`):n+=u+"/>",r=!0}return n}function U(t){const e=Object.keys(t);for(let i=0;i<e.length;i++){const s=e[i];if(t.hasOwnProperty(s)&&":@"!==s)return s}}function Z(t,e){let i="";if(t&&!e.ignoreAttributes)for(let s in t){if(!t.hasOwnProperty(s))continue;let n=e.attributeValueProcessor(s,t[s]);n=G(n,e),!0===n&&e.suppressBooleanAttributes?i+=` ${s.substr(e.attributeNamePrefix.length)}`:i+=` ${s.substr(e.attributeNamePrefix.length)}="${n}"`}return i}function q(t,e){let i=(t=t.substr(0,t.length-e.textNodeName.length-1)).substr(t.lastIndexOf(".")+1);for(let s in e.stopNodes)if(e.stopNodes[s]===t||e.stopNodes[s]==="*."+i)return!0;return!1}function G(t,e){if(t&&t.length>0&&e.processEntities)for(let i=0;i<e.entities.length;i++){const s=e.entities[i];t=t.replace(s.regex,s.val)}return t}const W=function(t,e){let i="";return e.format&&e.indentBy.length>0&&(i="\n"),H(t,e,"",i)},Y={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(t,e){return e},attributeValueProcessor:function(t,e){return e},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&amp;"},{regex:new RegExp(">","g"),val:"&gt;"},{regex:new RegExp("<","g"),val:"&lt;"},{regex:new RegExp("'","g"),val:"&apos;"},{regex:new RegExp('"',"g"),val:"&quot;"}],processEntities:!0,stopNodes:[],oneListGroup:!1};function K(t){this.options=Object.assign({},Y,t),this.options.ignoreAttributes||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=J),this.processTextOrObjNode=X,this.options.format?(this.indentate=Q,this.tagEndChar=">\n",this.newLine="\n"):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function X(t,e,i){const s=this.j2x(t,i+1);return void 0!==t[this.options.textNodeName]&&1===Object.keys(t).length?this.buildTextValNode(t[this.options.textNodeName],e,s.attrStr,i):this.buildObjectNode(s.val,e,s.attrStr,i)}function Q(t){return this.options.indentBy.repeat(t)}function J(t){return!(!t.startsWith(this.options.attributeNamePrefix)||t===this.options.textNodeName)&&t.substr(this.attrPrefixLen)}K.prototype.build=function(t){return this.options.preserveOrder?W(t,this.options):(Array.isArray(t)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(t={[this.options.arrayNodeName]:t}),this.j2x(t,0).val)},K.prototype.j2x=function(t,e){let i="",s="";for(let n in t)if(Object.prototype.hasOwnProperty.call(t,n))if(typeof t[n]>"u")this.isAttribute(n)&&(s+="");else if(null===t[n])this.isAttribute(n)?s+="":"?"===n[0]?s+=this.indentate(e)+"<"+n+"?"+this.tagEndChar:s+=this.indentate(e)+"<"+n+"/"+this.tagEndChar;else if(t[n]instanceof Date)s+=this.buildTextValNode(t[n],n,"",e);else if("object"!=typeof t[n]){const r=this.isAttribute(n);if(r)i+=this.buildAttrPairStr(r,""+t[n]);else if(n===this.options.textNodeName){let e=this.options.tagValueProcessor(n,""+t[n]);s+=this.replaceEntitiesValue(e)}else s+=this.buildTextValNode(t[n],n,"",e)}else if(Array.isArray(t[n])){const i=t[n].length;let r="";for(let o=0;o<i;o++){const i=t[n][o];typeof i>"u"||(null===i?"?"===n[0]?s+=this.indentate(e)+"<"+n+"?"+this.tagEndChar:s+=this.indentate(e)+"<"+n+"/"+this.tagEndChar:"object"==typeof i?this.options.oneListGroup?r+=this.j2x(i,e+1).val:r+=this.processTextOrObjNode(i,n,e):r+=this.buildTextValNode(i,n,"",e))}this.options.oneListGroup&&(r=this.buildObjectNode(r,n,"",e)),s+=r}else if(this.options.attributesGroupName&&n===this.options.attributesGroupName){const e=Object.keys(t[n]),s=e.length;for(let r=0;r<s;r++)i+=this.buildAttrPairStr(e[r],""+t[n][e[r]])}else s+=this.processTextOrObjNode(t[n],n,e);return{attrStr:i,val:s}},K.prototype.buildAttrPairStr=function(t,e){return e=this.options.attributeValueProcessor(t,""+e),e=this.replaceEntitiesValue(e),this.options.suppressBooleanAttributes&&"true"===e?" "+t:" "+t+'="'+e+'"'},K.prototype.buildObjectNode=function(t,e,i,s){if(""===t)return"?"===e[0]?this.indentate(s)+"<"+e+i+"?"+this.tagEndChar:this.indentate(s)+"<"+e+i+this.closeTag(e)+this.tagEndChar;{let n="</"+e+this.tagEndChar,r="";return"?"===e[0]&&(r="?",n=""),!i&&""!==i||-1!==t.indexOf("<")?!1!==this.options.commentPropName&&e===this.options.commentPropName&&0===r.length?this.indentate(s)+`\x3c!--${t}--\x3e`+this.newLine:this.indentate(s)+"<"+e+i+r+this.tagEndChar+t+this.indentate(s)+n:this.indentate(s)+"<"+e+i+r+">"+t+n}},K.prototype.closeTag=function(t){let e="";return-1!==this.options.unpairedTags.indexOf(t)?this.options.suppressUnpairedNode||(e="/"):e=this.options.suppressEmptyNode?"/":`></${t}`,e},K.prototype.buildTextValNode=function(t,e,i,s){if(!1!==this.options.cdataPropName&&e===this.options.cdataPropName)return this.indentate(s)+`<![CDATA[${t}]]>`+this.newLine;if(!1!==this.options.commentPropName&&e===this.options.commentPropName)return this.indentate(s)+`\x3c!--${t}--\x3e`+this.newLine;if("?"===e[0])return this.indentate(s)+"<"+e+i+"?"+this.tagEndChar;{let n=this.options.tagValueProcessor(e,t);return n=this.replaceEntitiesValue(n),""===n?this.indentate(s)+"<"+e+i+this.closeTag(e)+this.tagEndChar:this.indentate(s)+"<"+e+i+">"+n+"</"+e+this.tagEndChar}},K.prototype.replaceEntitiesValue=function(t){if(t&&t.length>0&&this.options.processEntities)for(let e=0;e<this.options.entities.length;e++){const i=this.options.entities[e];t=t.replace(i.regex,i.val)}return t}}},r={};function o(t){var e=r[t];if(void 0!==e)return e.exports;var i=r[t]={id:t,loaded:!1,exports:{}};return n[t].call(i.exports,i,i.exports,o),i.loaded=!0,i.exports}o.m=n,e=[],o.O=(t,i,s,n)=>{if(!i){var r=1/0;for(d=0;d<e.length;d++){i=e[d][0],s=e[d][1],n=e[d][2];for(var a=!0,l=0;l<i.length;l++)(!1&n||r>=n)&&Object.keys(o.O).every((t=>o.O[t](i[l])))?i.splice(l--,1):(a=!1,n<r&&(r=n));if(a){e.splice(d--,1);var c=s();void 0!==c&&(t=c)}}return t}n=n||0;for(var d=e.length;d>0&&e[d-1][2]>n;d--)e[d]=e[d-1];e[d]=[i,s,n]},o.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return o.d(e,{a:e}),e},o.d=(t,e)=>{for(var i in e)o.o(e,i)&&!o.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:e[i]})},o.f={},o.e=t=>Promise.all(Object.keys(o.f).reduce(((e,i)=>(o.f[i](t,e),e)),[])),o.u=t=>t+"-"+t+".js?v="+{2048:"78a82614529a3cefcde7",4180:"fe82f3a2dac70d6b82bc"}[t],o.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),o.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),i={},s="nextcloud:",o.l=(t,e,n,r)=>{if(i[t])i[t].push(e);else{var a,l;if(void 0!==n)for(var c=document.getElementsByTagName("script"),d=0;d<c.length;d++){var u=c[d];if(u.getAttribute("src")==t||u.getAttribute("data-webpack")==s+n){a=u;break}}a||(l=!0,(a=document.createElement("script")).charset="utf-8",a.timeout=120,o.nc&&a.setAttribute("nonce",o.nc),a.setAttribute("data-webpack",s+n),a.src=t),i[t]=[e];var p=(e,s)=>{a.onerror=a.onload=null,clearTimeout(f);var n=i[t];if(delete i[t],a.parentNode&&a.parentNode.removeChild(a),n&&n.forEach((t=>t(s))),e)return e(s)},f=setTimeout(p.bind(null,void 0,{type:"timeout",target:a}),12e4);a.onerror=p.bind(null,a.onerror),a.onload=p.bind(null,a.onload),l&&document.head.appendChild(a)}},o.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},o.nmd=t=>(t.paths=[],t.children||(t.children=[]),t),o.j=1358,(()=>{var t;o.g.importScripts&&(t=o.g.location+"");var e=o.g.document;if(!t&&e&&(e.currentScript&&(t=e.currentScript.src),!t)){var i=e.getElementsByTagName("script");if(i.length)for(var s=i.length-1;s>-1&&!t;)t=i[s--].src}if(!t)throw new Error("Automatic publicPath is not supported in this browser");t=t.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),o.p=t})(),(()=>{o.b=document.baseURI||self.location.href;var t={1358:0};o.f.j=(e,i)=>{var s=o.o(t,e)?t[e]:void 0;if(0!==s)if(s)i.push(s[2]);else{var n=new Promise(((i,n)=>s=t[e]=[i,n]));i.push(s[2]=n);var r=o.p+o.u(e),a=new Error;o.l(r,(i=>{if(o.o(t,e)&&(0!==(s=t[e])&&(t[e]=void 0),s)){var n=i&&("load"===i.type?"missing":i.type),r=i&&i.target&&i.target.src;a.message="Loading chunk "+e+" failed.\n("+n+": "+r+")",a.name="ChunkLoadError",a.type=n,a.request=r,s[1](a)}}),"chunk-"+e,e)}},o.O.j=e=>0===t[e];var e=(e,i)=>{var s,n,r=i[0],a=i[1],l=i[2],c=0;if(r.some((e=>0!==t[e]))){for(s in a)o.o(a,s)&&(o.m[s]=a[s]);if(l)var d=l(o)}for(e&&e(i);c<r.length;c++)n=r[c],o.o(t,n)&&t[n]&&t[n][0](),t[n]=0;return o.O(d)},i=self.webpackChunknextcloud=self.webpackChunknextcloud||[];i.forEach(e.bind(null,0)),i.push=e.bind(null,i.push.bind(i))})(),o.nc=void 0;var a=o.O(void 0,[7874],(()=>o(46462)));a=o.O(a)})();
  3. //# sourceMappingURL=files_versions-files_versions.js.map?v=0639d18e4d1181186020