123 |
- /*! For license information please see files-main.js.LICENSE.txt */
- !function(){"use strict";var e,n={72738:function(e,n,i){var r=i(17499),o=i(79954),a=i(31352),s=i(79753),l=i(45994),c=function(){var t,e,n,i,r=(null===(t=OCA)||void 0===t||null===(e=t.Files)||void 0===e||null===(n=e.App)||void 0===n||null===(i=n.currentFileList)||void 0===i?void 0:i.dirInfo)||{path:"/",name:""};return"".concat(r.path,"/").concat(r.name).replace(/\/\//gi,"/")},u=i(4820),p=i(20144),d=i(62520),f=i(64024),v=i(93455),m=i.n(v),g=i(70110),h=i.n(g);function A(t,e,n,i,r,o,a){try{var s=t[o](a),l=s.value}catch(t){return void n(t)}s.done?e(l):Promise.resolve(l).then(i,r)}function y(t){return function(){var e=this,n=arguments;return new Promise((function(i,r){var o=t.apply(e,n);function a(t){A(o,i,r,a,s,"next",t)}function s(t){A(o,i,r,a,s,"throw",t)}a(void 0)}))}}var b=function(){var t=y(regeneratorRuntime.mark((function t(){var e;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,u.default.get((0,s.generateOcsUrl)("apps/files/api/v1/templates"));case 2:return e=t.sent,t.abrupt("return",e.data.ocs.data);case 4:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}(),w=function(){var t=y(regeneratorRuntime.mark((function t(e,n,i){var r;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,u.default.post((0,s.generateOcsUrl)("apps/files/api/v1/templates/create"),{filePath:e,templatePath:n,templateType:i});case 2:return r=t.sent,t.abrupt("return",r.data.ocs.data);case 4:case"end":return t.stop()}}),t)})));return function(e,n,i){return t.apply(this,arguments)}}(),C=256,_={name:"TemplatePreview",inheritAttrs:!1,props:{basename:{type:String,required:!0},checked:{type:Boolean,default:!1},fileid:{type:[String,Number],required:!0},filename:{type:String,required:!0},previewUrl:{type:String,default:null},hasPreview:{type:Boolean,default:!0},mime:{type:String,required:!0},ratio:{type:Number,default:null}},data:function(){return{failedPreview:!1}},computed:{nameWithoutExt:function(){return this.basename.indexOf(".")>-1?this.basename.split(".").slice(0,-1).join("."):this.basename},id:function(){return"template-picker-".concat(this.fileid)},realPreviewUrl:function(){return this.failedPreview&&this.mimeIcon?this.mimeIcon:this.previewUrl?this.previewUrl:(0,l.ts)()?(0,s.generateUrl)("/core/preview?fileId=".concat(this.fileid,"&x=").concat(C,"&y=").concat(C,"&a=1")):(0,s.generateUrl)("/apps/files_sharing/publicpreview/".concat(document.getElementById("sharingToken")&&document.getElementById("sharingToken").value,"?fileId=").concat(this.fileid,"&file=").concat(function(t){var e=(t.startsWith("/")?t:"/".concat(t)).split("/"),n="";return e.forEach((function(t){""!==t&&(n+="/"+encodeURIComponent(t))})),n}(this.filename),"&x=").concat(C,"&y=").concat(C,"&a=1"))},mimeIcon:function(){return OC.MimeType.getIconUrl(this.mime)}},methods:{onCheck:function(){this.$emit("check",this.fileid)},onFailure:function(){this.failedPreview=!0}}},S=_,k=i(93379),x=i.n(k),O=i(7795),P=i.n(O),j=i(90569),E=i.n(j),N=i(3565),T=i.n(N),F=i(19216),I=i.n(F),U=i(44589),D=i.n(U),B=i(87027),q={};q.styleTagTransform=D(),q.setAttributes=T(),q.insert=E().bind(null,"head"),q.domAPI=P(),q.insertStyleElement=I(),x()(B.Z,q),B.Z&&B.Z.locals&&B.Z.locals;var Z=i(51900),L=(0,Z.Z)(S,(function(){var t=this,e=t._self._c;return e("li",{staticClass:"template-picker__item"},[e("input",{staticClass:"radio",attrs:{id:t.id,type:"radio",name:"template-picker"},domProps:{checked:t.checked},on:{change:t.onCheck}}),t._v(" "),e("label",{staticClass:"template-picker__label",attrs:{for:t.id}},[e("div",{staticClass:"template-picker__preview",class:t.failedPreview?"template-picker__preview--failed":""},[e("img",{staticClass:"template-picker__image",attrs:{src:t.realPreviewUrl,alt:"",draggable:"false"},on:{error:t.onFailure}})]),t._v(" "),e("span",{staticClass:"template-picker__title"},[t._v("\n\t\t\t"+t._s(t.nameWithoutExt)+"\n\t\t")])])])}),[],!1,null,"440aea22",null).exports,R=i(25108);function V(t,e,n,i,r,o,a){try{var s=t[o](a),l=s.value}catch(t){return void n(t)}s.done?e(l):Promise.resolve(l).then(i,r)}function M(t){return function(){var e=this,n=arguments;return new Promise((function(i,r){var o=t.apply(e,n);function a(t){V(o,i,r,a,s,"next",t)}function s(t){V(o,i,r,a,s,"throw",t)}a(void 0)}))}}var Q={name:"TemplatePicker",components:{NcEmptyContent:m(),NcModal:h(),TemplatePreview:L},props:{logger:{type:Object,required:!0}},data:function(){return{checked:-1,loading:!1,name:null,opened:!1,provider:null}},computed:{nameWithoutExt:function(){return this.name.indexOf(".")>-1?this.name.split(".").slice(0,-1).join("."):this.name},emptyTemplate:function(){var e,n;return{basename:t("files","Blank"),fileid:-1,filename:this.t("files","Blank"),hasPreview:!1,mime:(null===(e=this.provider)||void 0===e?void 0:e.mimetypes[0])||(null===(n=this.provider)||void 0===n?void 0:n.mimetypes)}},selectedTemplate:function(){var t=this;return this.provider.templates.find((function(e){return e.fileid===t.checked}))},style:function(){return{"--margin":"8px","--width":"160px","--border":"2px","--fullwidth":"180px","--height":this.provider.ratio?Math.round(160/this.provider.ratio)+"px":null}}},methods:{open:function(t,e){var n=this;return M(regeneratorRuntime.mark((function i(){var r,o;return regeneratorRuntime.wrap((function(i){for(;;)switch(i.prev=i.next){case 0:return n.checked=n.emptyTemplate.fileid,n.name=t,n.provider=e,i.next=5,b();case 5:if(r=i.sent,null!==(o=r.find((function(t){return t.app===e.app&&t.label===e.label})))){i.next=9;break}throw new Error("Failed to match provider in results");case 9:if(n.provider=o,0!==o.templates.length){i.next=13;break}return n.onSubmit(),i.abrupt("return");case 13:n.opened=!0;case 14:case"end":return i.stop()}}),i)})))()},close:function(){this.checked=this.emptyTemplate.fileid,this.loading=!1,this.name=null,this.opened=!1,this.provider=null},onCheck:function(t){this.checked=t},onSubmit:function(){var t=this;return M(regeneratorRuntime.mark((function e(){var n,i,r,o,a,s,l,u,p,v,m,g,h;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t.loading=!0,o=c(),a=null===(n=OCA)||void 0===n||null===(i=n.Files)||void 0===i||null===(r=i.App)||void 0===r?void 0:r.currentFileList,t.nameWithoutExt===t.name&&(t.logger.debug("Fixed invalid filename",{name:t.name,extension:null===(s=t.provider)||void 0===s?void 0:s.extension}),t.name=t.name+(null===(l=t.provider)||void 0===l?void 0:l.extension)),e.prev=4,e.next=7,w((0,d.normalize)("".concat(o,"/").concat(t.name)),null===(u=t.selectedTemplate)||void 0===u?void 0:u.filename,null===(p=t.selectedTemplate)||void 0===p?void 0:p.templateType);case 7:return v=e.sent,t.logger.debug("Created new file",v),e.next=11,null==a?void 0:a.addAndFetchFileInfo(t.name).then((function(t,e){return e}));case 11:m=e.sent,g=new OCA.Files.FileInfoModel(m,{filesClient:null==a?void 0:a.filesClient}),(h=OCA.Files.fileActions.getDefaultFileAction(v.mime,"file",OC.PERMISSION_ALL))&&h.action(v.basename,{$file:null==a?void 0:a.findFileEl(t.name),dir:o,fileList:a,fileActions:null==a?void 0:a.fileActions,fileInfoModel:g}),t.close(),e.next=23;break;case 18:e.prev=18,e.t0=e.catch(4),t.logger.error("Error while creating the new file from template"),R.error(e.t0),(0,f.x2)(t.t("files","Unable to create new file from template"));case 23:return e.prev=23,t.loading=!1,e.finish(23);case 26:case"end":return e.stop()}}),e,null,[[4,18,23,26]])})))()}}},W=Q,z=i(74502),G={};G.styleTagTransform=D(),G.setAttributes=T(),G.insert=E().bind(null,"head"),G.domAPI=P(),G.insertStyleElement=I(),x()(z.Z,G),z.Z&&z.Z.locals&&z.Z.locals;var $=(0,Z.Z)(W,(function(){var t=this,e=t._self._c;return t.opened?e("NcModal",{staticClass:"templates-picker",attrs:{"clear-view-delay":-1,size:"normal"},on:{close:t.close}},[e("form",{staticClass:"templates-picker__form",style:t.style,on:{submit:function(e){return e.preventDefault(),e.stopPropagation(),t.onSubmit.apply(null,arguments)}}},[e("h2",[t._v(t._s(t.t("files","Pick a template for {name}",{name:t.nameWithoutExt})))]),t._v(" "),e("ul",{staticClass:"templates-picker__list"},[e("TemplatePreview",t._b({attrs:{checked:t.checked===t.emptyTemplate.fileid},on:{check:t.onCheck}},"TemplatePreview",t.emptyTemplate,!1)),t._v(" "),t._l(t.provider.templates,(function(n){return e("TemplatePreview",t._b({key:n.fileid,attrs:{checked:t.checked===n.fileid,ratio:t.provider.ratio},on:{check:t.onCheck}},"TemplatePreview",n,!1))}))],2),t._v(" "),e("div",{staticClass:"templates-picker__buttons"},[e("button",{on:{click:t.close}},[t._v("\n\t\t\t\t"+t._s(t.t("files","Cancel"))+"\n\t\t\t")]),t._v(" "),e("input",{staticClass:"primary",attrs:{type:"submit","aria-label":t.t("files","Create a new file with the selected template")},domProps:{value:t.t("files","Create")}})])]),t._v(" "),t.loading?e("NcEmptyContent",{staticClass:"templates-picker__loading",attrs:{icon:"icon-loading"}},[t._v("\n\t\t"+t._s(t.t("files","Creating file"))+"\n\t")]):t._e()],1):t._e()}),[],!1,null,"55dd9121",null),Y=$.exports;function H(t,e,n,i,r,o,a){try{var s=t[o](a),l=s.value}catch(t){return void n(t)}s.done?e(l):Promise.resolve(l).then(i,r)}var K=(0,r.IY)().setApp("files").detectUser().build();p.ZP.mixin({methods:{t:a.Iu,n:a.uN}});var J=document.createElement("div");J.id="template-picker",document.body.appendChild(J);var X=(0,o.j)("files","templates",[]),tt=(0,o.j)("files","templates_path",!1);K.debug("Templates providers",X),K.debug("Templates folder",{templatesPath:tt});var et=new(p.ZP.extend(Y))({name:"TemplatePicker",propsData:{logger:K}});et.$mount("#template-picker"),window.addEventListener("DOMContentLoaded",(function(){if(!tt){K.debug("Templates folder not initialized");var t={attach:function(t){t.addMenuEntry({id:"template-init",displayName:(0,a.Iu)("files","Set up templates folder"),templateName:(0,a.Iu)("files","Templates"),iconClass:"icon-template-add",fileType:"file",actionHandler:function(e){it(e),t.removeMenuEntry("template-init")}})}};OC.Plugins.register("OCA.Files.NewFileMenu",t)}})),X.forEach((function(t,e){var n={attach:function(n){var i=n.fileList;"files"!==i.id&&"files.public"!==i.id||n.addMenuEntry({id:"template-new-".concat(t.app,"-").concat(e),displayName:t.label,templateName:t.label+t.extension,iconClass:t.iconClass||"icon-file",fileType:"file",actionHandler:function(e){et.open(e,t)}})}};OC.Plugins.register("OCA.Files.NewFileMenu",n)}));var nt,it=function(){var t,e=(t=regeneratorRuntime.mark((function t(e){var n,i;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=(c()+"/".concat(e)).replace("//","/"),t.prev=1,K.debug("Initializing the templates directory",{templatePath:n}),t.next=5,u.default.post((0,s.generateOcsUrl)("apps/files/api/v1/templates/path"),{templatePath:n,copySystemTemplates:!0});case 5:i=t.sent,OCA.Files.App.currentFileList.changeDirectory(n,!0,!0),X=i.data.ocs.data.templates,tt=i.data.ocs.data.template_path,t.next=15;break;case 11:t.prev=11,t.t0=t.catch(1),K.error("Unable to initialize the templates directory"),(0,f.x2)((0,a.Iu)("files","Unable to initialize the templates directory"));case 15:case"end":return t.stop()}}),t,null,[[1,11]])})),function(){var e=this,n=arguments;return new Promise((function(i,r){var o=t.apply(e,n);function a(t){H(o,i,r,a,s,"next",t)}function s(t){H(o,i,r,a,s,"throw",t)}a(void 0)}))});return function(t){return e.apply(this,arguments)}}(),rt=i(78595);nt={attach:function(t){var e=this;(0,rt.Ld)("nextcloud:unified-search.search",(function(e){var n=e.query;t.setFilter(n)})),(0,rt.Ld)("nextcloud:unified-search.reset",(function(){e.query=null,t.setFilter("")}))}},window.OC.Plugins.register("OCA.Files.FileList",nt);var ot=(0,r.IY)().setApp("files").detectUser().build();function at(t){return at="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},at(t)}function st(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,i)}return n}function lt(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?st(Object(n),!0).forEach((function(e){ct(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):st(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function ct(t,e,n){return(e=function(t){var e=function(t,e){if("object"!==at(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var i=n.call(t,"string");if("object"!==at(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===at(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var ut=function(t){var e=t.id,n=t.name,i=t.order,r=t.icon,o=t.parent,a=t.classes,s=void 0===a?"":a,l=t.expanded,c=t.params;OCP.Files.Navigation.register({id:e,name:n,order:i,params:c,parent:o,expanded:!0===l,iconClass:r?"icon-".concat(r):"nav-icon-"+e,legacy:!0,sticky:s.includes("pinned")})},pt=i(41487),dt=i.n(pt);function ft(t){return ft="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ft(t)}function vt(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,gt(i.key),i)}}function mt(t,e,n){return(e=gt(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function gt(t){var e=function(t,e){if("object"!==ft(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var i=n.call(t,"string");if("object"!==ft(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===ft(e)?e:String(e)}var ht=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),mt(this,"_views",[]),mt(this,"_currentView",null),ot.debug("Navigation service initialized")}var e,n;return e=t,(n=[{key:"register",value:function(t){try{yt(t),At(t,this._views)}catch(e){throw e instanceof Error&&ot.error(e.message,{view:t}),e}t.legacy&&ot.warn("Legacy view detected, please migrate to Vue"),t.iconClass&&(t.legacy=!0),this._views.push(t)}},{key:"views",get:function(){return this._views}},{key:"setActive",value:function(t){this._currentView=t}},{key:"active",get:function(){return this._currentView}}])&&vt(e.prototype,n),Object.defineProperty(e,"prototype",{writable:!1}),t}(),At=function(t,e){if(e.find((function(e){return e.id===t.id})))throw new Error("Navigation id ".concat(t.id," is already registered"));return!0},yt=function(t){if(!t.id||"string"!=typeof t.id)throw new Error("Navigation id is required and must be a string");if(!t.name||"string"!=typeof t.name)throw new Error("Navigation name is required and must be a string");if(!t.legacy){if(!t.getFiles||"function"!=typeof t.getFiles)throw new Error("Navigation getFiles is required and must be a function");if(!t.icon||"string"!=typeof t.icon||!dt()(t.icon))throw new Error("Navigation icon is required and must be a valid svg string")}if(!("order"in t)||"number"!=typeof t.order)throw new Error("Navigation order is required and must be a number");if(t.columns&&t.columns.forEach(bt),t.emptyView&&"function"!=typeof t.emptyView)throw new Error("Navigation emptyView must be a function");if(t.parent&&"string"!=typeof t.parent)throw new Error("Navigation parent must be a string");if("sticky"in t&&"boolean"!=typeof t.sticky)throw new Error("Navigation sticky must be a boolean");if("expanded"in t&&"boolean"!=typeof t.expanded)throw new Error("Navigation expanded must be a boolean");return!0},bt=function(t){if(!t.id||"string"!=typeof t.id)throw new Error("Column id is required");if(!t.title||"string"!=typeof t.title)throw new Error("Column title is required");if(!t.property||"string"!=typeof t.property)throw new Error("Column property is required");if(t.sortFunction&&"function"!=typeof t.sortFunction)throw new Error("Column sortFunction must be a function");if(t.summary&&"function"!=typeof t.summary)throw new Error("Column summary must be a function");return!0},wt=i(57638),Ct=i(55209),_t=i.n(Ct),St=i(14032),kt=i.n(St),xt=i(91770),Ot=i(28615),Pt=i(74184),jt=i(48959),Et=i.n(jt);function Nt(t,e,n,i,r,o,a){try{var s=t[o](a),l=s.value}catch(t){return void n(t)}s.done?e(l):Promise.resolve(l).then(i,r)}var Tt={name:"NavigationQuota",components:{ChartPie:Pt.Z,NcAppNavigationItem:kt(),NcProgressBar:Et()},data:function(){return{loadingStorageStats:!1,storageStats:(0,o.j)("files","storageStats",null)}},computed:{storageStatsTitle:function(){var t,e,n,i=(0,xt.sS)(null===(t=this.storageStats)||void 0===t?void 0:t.used),r=(0,xt.sS)(null===(e=this.storageStats)||void 0===e?void 0:e.quota);return(null===(n=this.storageStats)||void 0===n?void 0:n.quota)<0?this.t("files","{usedQuotaByte} used",{usedQuotaByte:i}):this.t("files","{used} of {quota} used",{used:i,quota:r})},storageStatsTooltip:function(){return this.storageStats.relative?this.t("files","{relative}% used",this.storageStats):""}},beforeMount:function(){setInterval(this.throttleUpdateStorageStats,6e4),(0,rt.Ld)("files:file:created",this.throttleUpdateStorageStats),(0,rt.Ld)("files:file:deleted",this.throttleUpdateStorageStats),(0,rt.Ld)("files:file:moved",this.throttleUpdateStorageStats),(0,rt.Ld)("files:file:updated",this.throttleUpdateStorageStats),(0,rt.Ld)("files:folder:created",this.throttleUpdateStorageStats),(0,rt.Ld)("files:folder:deleted",this.throttleUpdateStorageStats),(0,rt.Ld)("files:folder:moved",this.throttleUpdateStorageStats),(0,rt.Ld)("files:folder:updated",this.throttleUpdateStorageStats)},methods:{debounceUpdateStorageStats:(0,Ot.D)(200,(function(t){this.updateStorageStats(t)})),throttleUpdateStorageStats:(0,Ot.P)(1e3,(function(t){this.updateStorageStats(t)})),updateStorageStats:function(){var e,n=arguments,i=this;return(e=regeneratorRuntime.mark((function e(){var r,o,a;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r=n.length>0&&void 0!==n[0]?n[0]:null,!i.loadingStorageStats){e.next=3;break}return e.abrupt("return");case 3:return i.loadingStorageStats=!0,e.prev=4,e.next=7,u.default.get((0,s.generateUrl)("/apps/files/api/v1/stats"));case 7:if(null!=(a=e.sent)&&null!==(o=a.data)&&void 0!==o&&o.data){e.next=10;break}throw new Error("Invalid storage stats");case 10:i.storageStats=a.data.data,e.next=17;break;case 13:e.prev=13,e.t0=e.catch(4),ot.error("Could not refresh storage stats",{error:e.t0}),r&&(0,f.x2)(t("files","Could not refresh storage stats"));case 17:return e.prev=17,i.loadingStorageStats=!1,e.finish(17);case 20:case"end":return e.stop()}}),e,null,[[4,13,17,20]])})),function(){var t=this,n=arguments;return new Promise((function(i,r){var o=e.apply(t,n);function a(t){Nt(o,i,r,a,s,"next",t)}function s(t){Nt(o,i,r,a,s,"throw",t)}a(void 0)}))})()},t:a.Iu}},Ft=Tt,It=i(358),Ut={};Ut.styleTagTransform=D(),Ut.setAttributes=T(),Ut.insert=E().bind(null,"head"),Ut.domAPI=P(),Ut.insertStyleElement=I(),x()(It.Z,Ut),It.Z&&It.Z.locals&&It.Z.locals;var Dt=(0,Z.Z)(Ft,(function(){var t=this,e=t._self._c;return t.storageStats?e("NcAppNavigationItem",{staticClass:"app-navigation-entry__settings-quota",class:{"app-navigation-entry__settings-quota--not-unlimited":t.storageStats.quota>=0},attrs:{"aria-label":t.t("files","Storage informations"),loading:t.loadingStorageStats,name:t.storageStatsTitle,title:t.storageStatsTooltip,"data-cy-files-navigation-settings-quota":""},on:{click:function(e){return e.stopPropagation(),e.preventDefault(),t.debounceUpdateStorageStats.apply(null,arguments)}}},[e("ChartPie",{attrs:{slot:"icon",size:20},slot:"icon"}),t._v(" "),t.storageStats.quota>=0?e("NcProgressBar",{attrs:{slot:"extra",error:t.storageStats.relative>80,value:Math.min(t.storageStats.relative,100)},slot:"extra"}):t._e()],1):t._e()}),[],!1,null,"26c061ec",null),Bt=Dt.exports,qt=i(68988),Zt=i.n(qt),Lt=i(16809),Rt=i.n(Lt),Vt=i(20571),Mt=i.n(Vt),Qt=i(70386),Wt=i(36029),zt=i.n(Wt),Gt={name:"Setting",props:{el:{type:Function,required:!0}},mounted:function(){this.$el.appendChild(this.el())}},$t=(0,Z.Z)(Gt,(function(){return(0,this._self._c)("div")}),[],!1,null,null,null).exports;function Yt(t){return Yt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Yt(t)}function Ht(t,e,n,i,r,o,a){try{var s=t[o](a),l=s.value}catch(t){return void n(t)}s.done?e(l):Promise.resolve(l).then(i,r)}function Kt(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,i)}return n}function Jt(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?Kt(Object(n),!0).forEach((function(e){Xt(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Kt(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function Xt(t,e,n){return(e=function(t){var e=function(t,e){if("object"!==Yt(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var i=n.call(t,"string");if("object"!==Yt(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===Yt(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}var te=(0,o.j)("files","config",{show_hidden:!1,crop_image_previews:!0}),ee={name:"Settings",components:{Clipboard:Qt.Z,NcAppSettingsDialog:Zt(),NcAppSettingsSection:Rt(),NcCheckboxRadioSwitch:Mt(),NcInputField:zt(),Setting:$t},props:{open:{type:Boolean,default:!1}},data:function(){var t,e,n,i;return Jt(Jt({},te),{},{settings:(null===(t=window.OCA)||void 0===t||null===(e=t.Files)||void 0===e||null===(n=e.Settings)||void 0===n?void 0:n.settings)||[],webdavUrl:(0,s.generateRemoteUrl)("dav/files/"+encodeURIComponent(null===(i=(0,l.ts)())||void 0===i?void 0:i.uid)),webdavDocs:"https://docs.nextcloud.com/server/stable/go.php?to=user-webdav",webdavUrlCopied:!1})},beforeMount:function(){this.settings.forEach((function(t){return t.open()}))},beforeDestroy:function(){this.settings.forEach((function(t){return t.close()}))},methods:{onClose:function(){this.$emit("close")},setConfig:function(t,e){(0,rt.j8)("files:config:updated",{key:t,value:e}),u.default.post((0,s.generateUrl)("/apps/files/api/v1/config/"+t),{value:e})},copyCloudId:function(){var e,n=this;return(e=regeneratorRuntime.mark((function e(){return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(document.querySelector("input#webdav-url-input").select(),navigator.clipboard){e.next=4;break}return(0,f.x2)(t("files","Clipboard is not available")),e.abrupt("return");case 4:return e.next=6,navigator.clipboard.writeText(n.webdavUrl);case 6:n.webdavUrlCopied=!0,(0,f.s$)(t("files","WebDAV URL copied to clipboard")),setTimeout((function(){n.webdavUrlCopied=!1}),5e3);case 9:case"end":return e.stop()}}),e)})),function(){var t=this,n=arguments;return new Promise((function(i,r){var o=e.apply(t,n);function a(t){Ht(o,i,r,a,s,"next",t)}function s(t){Ht(o,i,r,a,s,"throw",t)}a(void 0)}))})()},t:a.Iu}},ne=ee,ie=(0,Z.Z)(ne,(function(){var t=this,e=t._self._c;return e("NcAppSettingsDialog",{attrs:{open:t.open,"show-navigation":!0,title:t.t("files","Files settings")},on:{"update:open":t.onClose}},[e("NcAppSettingsSection",{attrs:{id:"settings",title:t.t("files","Files settings")}},[e("NcCheckboxRadioSwitch",{attrs:{checked:t.show_hidden},on:{"update:checked":[function(e){t.show_hidden=e},function(e){return t.setConfig("show_hidden",e)}]}},[t._v("\n\t\t\t"+t._s(t.t("files","Show hidden files"))+"\n\t\t")]),t._v(" "),e("NcCheckboxRadioSwitch",{attrs:{checked:t.crop_image_previews},on:{"update:checked":[function(e){t.crop_image_previews=e},function(e){return t.setConfig("crop_image_previews",e)}]}},[t._v("\n\t\t\t"+t._s(t.t("files","Crop image previews"))+"\n\t\t")])],1),t._v(" "),0!==t.settings.length?e("NcAppSettingsSection",{attrs:{id:"more-settings",title:t.t("files","Additional settings")}},[t._l(t.settings,(function(t){return[e("Setting",{key:t.name,attrs:{el:t.el}})]}))],2):t._e(),t._v(" "),e("NcAppSettingsSection",{attrs:{id:"webdav",title:t.t("files","WebDAV")}},[e("NcInputField",{attrs:{id:"webdav-url-input","show-trailing-button":!0,success:t.webdavUrlCopied,"trailing-button-label":t.t("files","Copy to clipboard"),value:t.webdavUrl,readonly:"readonly",type:"url"},on:{focus:function(t){return t.target.select()},"trailing-button-click":t.copyCloudId},scopedSlots:t._u([{key:"trailing-button-icon",fn:function(){return[e("Clipboard",{attrs:{size:20}})]},proxy:!0}])}),t._v(" "),e("em",[e("a",{attrs:{href:t.webdavDocs,target:"_blank",rel:"noreferrer noopener"}},[t._v("\n\t\t\t\t"+t._s(t.t("files","Use this address to access your Files via WebDAV"))+" ↗\n\t\t\t")])])],1)],1)}),[],!1,null,"54b74cff",null).exports;function re(t){return re="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},re(t)}function oe(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,i)}return n}function ae(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?oe(Object(n),!0).forEach((function(e){se(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):oe(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function se(t,e,n){return(e=function(t){var e=function(t,e){if("object"!==re(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var i=n.call(t,"string");if("object"!==re(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===re(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function le(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,i=new Array(e);n<e;n++)i[n]=t[n];return i}var ce={name:"Navigation",components:{Cog:wt.default,NcAppNavigation:_t(),NcAppNavigationItem:kt(),SettingsModal:ie,NavigationQuota:Bt},props:{Navigation:{type:ht,required:!0}},data:function(){return{settingsOpened:!1}},computed:{currentViewId:function(){var t,e;return(null===(t=this.$route)||void 0===t||null===(e=t.params)||void 0===e?void 0:e.view)||"files"},currentView:function(){var t=this;return this.views.find((function(e){return e.id===t.currentViewId}))},views:function(){return this.Navigation.views},parentViews:function(){return this.views.filter((function(t){return!t.parent})).sort((function(t,e){return t.order-e.order}))},childViews:function(){return this.views.filter((function(t){return!!t.parent})).reduce((function(t,e){return t[e.parent]=[].concat(function(t){if(Array.isArray(t))return le(t)}(n=t[e.parent]||[])||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(n)||function(t,e){if(t){if("string"==typeof t)return le(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?le(t,e):void 0}}(n)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),[e]),t[e.parent].sort((function(t,e){return t.order-e.order})),t;var n}),{})}},watch:{currentView:function(t,e){ot.debug("View changed",{id:t.id,view:t}),this.showView(t,e)}},beforeMount:function(){this.currentView&&(ot.debug("Navigation mounted. Showing requested view",{view:this.currentView}),this.showView(this.currentView)),(0,rt.Ld)("files:legacy-navigation:changed",this.onLegacyNavigationChanged)},methods:{showView:function(t,e){var n,i,r,o,a,s,l;if(null===(n=window)||void 0===n||null===(i=n.OCA)||void 0===i||null===(r=i.Files)||void 0===r||null===(o=r.Sidebar)||void 0===o||null===(a=o.close)||void 0===a||a.call(o),t.legacy){var c=document.querySelector("#app-content #app-content-"+this.currentView.id+".viewcontainer");document.querySelectorAll("#app-content .viewcontainer").forEach((function(t){t.classList.add("hidden")})),c.classList.remove("hidden");var u=OC.Util.History.parseUrlQuery().dir,p=void 0===u?"/":u,d={itemId:t.id,dir:p};ot.debug("Triggering legacy navigation event",d),window.jQuery(c).trigger(new window.jQuery.Event("show",d)),window.jQuery(c).trigger(new window.jQuery.Event("urlChanged",d))}this.Navigation.setActive(t),s=t.name,(l=document.getElementById("page-heading-level-1"))&&(l.textContent=s),(0,rt.j8)("files:navigation:changed",t)},onLegacyNavigationChanged:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.id,n=void 0===e?"files":e,i=t.silent,r=void 0!==i&&i,o=this.Navigation.views.find((function(t){return t.id===n}));o&&o.legacy&&o.id!==this.currentView.id&&(this.$router.replace(ae(ae({},this.$route),{},{params:{view:o.id}})),r||(this.Navigation.setActive(o),this.showView(o)))},onToggleExpand:function(t){t.expanded=!t.expanded,u.default.post((0,s.generateUrl)("/apps/files/api/v1/toggleShowFolder/".concat(t.id)),{show:t.expanded})},generateToNavigation:function(t){if(t.params){var e=t.params,n=e.dir,i=e.fileid;return{name:"filelist",params:t.params,query:{dir:n,fileid:i}}}return{name:"filelist",params:{view:t.id}}},openSettings:function(){this.settingsOpened=!0},onSettingsClose:function(){this.settingsOpened=!1},t:a.Iu}},ue=ce,pe=i(1778),de={};de.styleTagTransform=D(),de.setAttributes=T(),de.insert=E().bind(null,"head"),de.domAPI=P(),de.insertStyleElement=I(),x()(pe.Z,de),pe.Z&&pe.Z.locals&&pe.Z.locals;var fe=(0,Z.Z)(ue,(function(){var t=this,e=t._self._c;return e("NcAppNavigation",{attrs:{"data-cy-files-navigation":""},scopedSlots:t._u([{key:"list",fn:function(){return t._l(t.parentViews,(function(n){return e("NcAppNavigationItem",{key:n.id,attrs:{"allow-collapse":!0,"data-cy-files-navigation-item":n.id,icon:n.iconClass,open:n.expanded,pinned:n.sticky,title:n.name,to:t.generateToNavigation(n)},on:{"update:open":function(e){return t.onToggleExpand(n)}}},t._l(t.childViews[n.id],(function(n){return e("NcAppNavigationItem",{key:n.id,attrs:{"data-cy-files-navigation-item":n.id,exact:!0,icon:n.iconClass,title:n.name,to:t.generateToNavigation(n)}})})),1)}))},proxy:!0},{key:"footer",fn:function(){return[e("ul",{staticClass:"app-navigation-entry__settings"},[e("NavigationQuota"),t._v(" "),e("NcAppNavigationItem",{attrs:{"aria-label":t.t("files","Open the files app settings"),title:t.t("files","Files settings"),"data-cy-files-navigation-settings-button":""},on:{click:function(e){return e.preventDefault(),e.stopPropagation(),t.openSettings.apply(null,arguments)}}},[e("Cog",{attrs:{slot:"icon",size:20},slot:"icon"})],1)],1)]},proxy:!0}])},[t._v(" "),t._v(" "),e("SettingsModal",{attrs:{open:t.settingsOpened,"data-cy-files-navigation-settings":""},on:{close:t.onSettingsClose}})],1)}),[],!1,null,"4ce98462",null),ve=fe.exports,me=i(25108);function ge(t){return ge="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ge(t)}function he(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,Ae(i.key),i)}}function Ae(t){var e=function(t,e){if("object"!==ge(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var i=n.call(t,"string");if("object"!==ge(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===ge(e)?e:String(e)}var ye=function(){function t(){var e,n,i;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),e=this,i=void 0,(n=Ae(n="_settings"))in e?Object.defineProperty(e,n,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[n]=i,this._settings=[],me.debug("OCA.Files.Settings initialized")}var e,n;return e=t,(n=[{key:"register",value:function(t){return this._settings.filter((function(e){return e.name===t.name})).length>0?(me.error("A setting with the same name is already registered"),!1):(this._settings.push(t),!0)}},{key:"settings",get:function(){return this._settings}}])&&he(e.prototype,n),Object.defineProperty(e,"prototype",{writable:!1}),t}();function be(t){return be="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},be(t)}function we(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,_e(i.key),i)}}function Ce(t,e,n){return(e=_e(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function _e(t){var e=function(t,e){if("object"!==be(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var i=n.call(t,"string");if("object"!==be(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===be(e)?e:String(e)}var Se=function(){function t(e,n){var i=n.el,r=n.open,o=n.close;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),Ce(this,"_close",void 0),Ce(this,"_el",void 0),Ce(this,"_name",void 0),Ce(this,"_open",void 0),this._name=e,this._el=i,this._open=r,this._close=o,"function"!=typeof this._open&&(this._open=function(){}),"function"!=typeof this._close&&(this._close=function(){})}var e,n;return e=t,(n=[{key:"name",get:function(){return this._name}},{key:"el",get:function(){return this._el}},{key:"open",get:function(){return this._open}},{key:"close",get:function(){return this._close}}])&&we(e.prototype,n),Object.defineProperty(e,"prototype",{writable:!1}),t}(),ke=i(78345),xe=i(17563);p.ZP.use(ke.Z);var Oe,Pe,je=new ke.Z({mode:"history",base:(0,s.generateUrl)("/apps/files",""),linkActiveClass:"active",routes:[{path:"/",alias:"/files"},{path:"/:view/:fileid?",name:"filelist",props:!0}],stringifyQuery:function(t){var e=(0,xe.stringify)(t).replace(/%2F/gim,"/");return e?"?"+e:""}});window.OCA.Files=null!==(Oe=window.OCA.Files)&&void 0!==Oe?Oe:{},window.OCP.Files=null!==(Pe=window.OCP.Files)&&void 0!==Pe?Pe:{};var Ee=new ht;Object.assign(window.OCP.Files,{Navigation:Ee});var Ne,Te=new ye;Object.assign(window.OCA.Files,{Settings:Te}),Object.assign(window.OCA.Files.Settings,{Setting:Se}),new(p.ZP.extend(ve))({name:"FilesNavigationRoot",propsData:{Navigation:Ee},router:je}).$mount("#app-navigation-files"),(Ne=Object.values((0,o.j)("files","navigation",{}))).length>0&&(ot.debug("Legacy files views detected. Processing...",Ne),Ne.forEach((function(t){ut(t),t.sublist&&t.sublist.forEach((function(e){return ut(lt(lt({},e),{},{parent:t.id}))}))})))},358:function(t,e,n){var i=n(87537),r=n.n(i),o=n(23645),a=n.n(o)()(r());a.push([t.id,".app-navigation-entry__settings-quota--not-unlimited[data-v-26c061ec] .app-navigation-entry__title{margin-top:-4px}.app-navigation-entry__settings-quota progress[data-v-26c061ec]{position:absolute;bottom:10px;margin-left:44px;width:calc(100% - 44px - 22px)}","",{version:3,sources:["webpack://./apps/files/src/components/NavigationQuota.vue"],names:[],mappings:"AAIC,mGACC,eAAA,CAGD,gEACC,iBAAA,CACA,WAAA,CACA,gBAAA,CACA,8BAAA",sourcesContent:["\n// User storage stats display\n.app-navigation-entry__settings-quota {\n\t// Align title with progress and icon\n\t&--not-unlimited::v-deep .app-navigation-entry__title {\n\t\tmargin-top: -4px;\n\t}\n\n\tprogress {\n\t\tposition: absolute;\n\t\tbottom: 10px;\n\t\tmargin-left: 44px;\n\t\twidth: calc(100% - 44px - 22px);\n\t}\n}\n"],sourceRoot:""}]),e.Z=a},87027:function(t,e,n){var i=n(87537),r=n.n(i),o=n(23645),a=n.n(o)()(r());a.push([t.id,".template-picker__item[data-v-440aea22]{display:flex}.template-picker__label[data-v-440aea22]{display:flex;align-items:center;flex:1 1;flex-direction:column}.template-picker__label[data-v-440aea22],.template-picker__label *[data-v-440aea22]{cursor:pointer;user-select:none}.template-picker__label[data-v-440aea22]::before{display:none !important}.template-picker__preview[data-v-440aea22]{display:block;overflow:hidden;flex:1 1;width:var(--width);min-height:var(--height);max-height:var(--height);padding:0;border:var(--border) solid var(--color-border);border-radius:var(--border-radius-large)}input:checked+label>.template-picker__preview[data-v-440aea22]{border-color:var(--color-primary)}.template-picker__preview--failed[data-v-440aea22]{display:flex}.template-picker__image[data-v-440aea22]{max-width:100%;background-color:var(--color-main-background);object-fit:cover}.template-picker__preview--failed .template-picker__image[data-v-440aea22]{width:calc(var(--margin)*8);margin:auto;background-color:rgba(0,0,0,0) !important;object-fit:initial}.template-picker__title[data-v-440aea22]{overflow:hidden;max-width:calc(var(--width) + 4px);padding:var(--margin);white-space:nowrap;text-overflow:ellipsis}","",{version:3,sources:["webpack://./apps/files/src/components/TemplatePreview.vue"],names:[],mappings:"AAGC,wCACC,YAAA,CAGD,yCACC,YAAA,CAEA,kBAAA,CACA,QAAA,CACA,qBAAA,CAEA,oFACC,cAAA,CACA,gBAAA,CAGD,iDACC,uBAAA,CAIF,2CACC,aAAA,CACA,eAAA,CAEA,QAAA,CACA,kBAAA,CACA,wBAAA,CACA,wBAAA,CACA,SAAA,CACA,8CAAA,CACA,wCAAA,CAEA,+DACC,iCAAA,CAGD,mDAEC,YAAA,CAIF,yCACC,cAAA,CACA,6CAAA,CAEA,gBAAA,CAID,2EACC,2BAAA,CAEA,WAAA,CACA,yCAAA,CAEA,kBAAA,CAGD,yCACC,eAAA,CAEA,kCAAA,CACA,qBAAA,CACA,kBAAA,CACA,sBAAA",sourcesContent:["\n\n.template-picker {\n\t&__item {\n\t\tdisplay: flex;\n\t}\n\n\t&__label {\n\t\tdisplay: flex;\n\t\t// Align in the middle of the grid\n\t\talign-items: center;\n\t\tflex: 1 1;\n\t\tflex-direction: column;\n\n\t\t&, * {\n\t\t\tcursor: pointer;\n\t\t\tuser-select: none;\n\t\t}\n\n\t\t&::before {\n\t\t\tdisplay: none !important;\n\t\t}\n\t}\n\n\t&__preview {\n\t\tdisplay: block;\n\t\toverflow: hidden;\n\t\t// Stretch so all entries are the same width\n\t\tflex: 1 1;\n\t\twidth: var(--width);\n\t\tmin-height: var(--height);\n\t\tmax-height: var(--height);\n\t\tpadding: 0;\n\t\tborder: var(--border) solid var(--color-border);\n\t\tborder-radius: var(--border-radius-large);\n\n\t\tinput:checked + label > & {\n\t\t\tborder-color: var(--color-primary);\n\t\t}\n\n\t\t&--failed {\n\t\t\t// Make sure to properly center fallback icon\n\t\t\tdisplay: flex;\n\t\t}\n\t}\n\n\t&__image {\n\t\tmax-width: 100%;\n\t\tbackground-color: var(--color-main-background);\n\n\t\tobject-fit: cover;\n\t}\n\n\t// Failed preview, fallback to mime icon\n\t&__preview--failed &__image {\n\t\twidth: calc(var(--margin) * 8);\n\t\t// Center mime icon\n\t\tmargin: auto;\n\t\tbackground-color: transparent !important;\n\n\t\tobject-fit: initial;\n\t}\n\n\t&__title {\n\t\toverflow: hidden;\n\t\t// also count preview border\n\t\tmax-width: calc(var(--width) + 2*2px);\n\t\tpadding: var(--margin);\n\t\twhite-space: nowrap;\n\t\ttext-overflow: ellipsis;\n\t}\n}\n\n"],sourceRoot:""}]),e.Z=a},1778:function(t,e,n){var i=n(87537),r=n.n(i),o=n(23645),a=n.n(o)()(r());a.push([t.id,".app-navigation[data-v-4ce98462] .app-navigation-entry-icon{background-repeat:no-repeat;background-position:center}.app-navigation>ul.app-navigation__list[data-v-4ce98462]{padding-bottom:var(--default-grid-baseline, 4px)}.app-navigation-entry__settings[data-v-4ce98462]{height:auto !important;overflow:hidden !important;padding-top:0 !important;flex:0 0 auto}","",{version:3,sources:["webpack://./apps/files/src/views/Navigation.vue"],names:[],mappings:"AAEA,4DACC,2BAAA,CACA,0BAAA,CAGD,yDAEC,gDAAA,CAGD,iDACC,sBAAA,CACA,0BAAA,CACA,wBAAA,CAEA,aAAA",sourcesContent:["\n// TODO: remove when https://github.com/nextcloud/nextcloud-vue/pull/3539 is in\n.app-navigation::v-deep .app-navigation-entry-icon {\n\tbackground-repeat: no-repeat;\n\tbackground-position: center;\n}\n\n.app-navigation > ul.app-navigation__list {\n\t// Use flex gap value for more elegant spacing\n\tpadding-bottom: var(--default-grid-baseline, 4px);\n}\n\n.app-navigation-entry__settings {\n\theight: auto !important;\n\toverflow: hidden !important;\n\tpadding-top: 0 !important;\n\t// Prevent shrinking or growing\n\tflex: 0 0 auto;\n}\n"],sourceRoot:""}]),e.Z=a},74502:function(t,e,n){var i=n(87537),r=n.n(i),o=n(23645),a=n.n(o)()(r());a.push([t.id,".templates-picker__form[data-v-55dd9121]{padding:calc(var(--margin)*2);padding-bottom:0}.templates-picker__form h2[data-v-55dd9121]{text-align:center;font-weight:bold;margin:var(--margin) 0 calc(var(--margin)*2)}.templates-picker__list[data-v-55dd9121]{display:grid;grid-gap:calc(var(--margin)*2);grid-auto-columns:1fr;max-width:calc(var(--fullwidth)*6);grid-template-columns:repeat(auto-fit, var(--fullwidth));grid-auto-rows:1fr;justify-content:center}.templates-picker__buttons[data-v-55dd9121]{display:flex;justify-content:space-between;padding:calc(var(--margin)*2) var(--margin);position:sticky;bottom:0;background-image:linear-gradient(0, var(--gradient-main-background))}.templates-picker__buttons button[data-v-55dd9121],.templates-picker__buttons input[type=submit][data-v-55dd9121]{height:44px}.templates-picker[data-v-55dd9121] .modal-container{position:relative}.templates-picker__loading[data-v-55dd9121]{position:absolute;top:0;left:0;justify-content:center;width:100%;height:100%;margin:0;background-color:var(--color-main-background-translucent)}","",{version:3,sources:["webpack://./apps/files/src/views/TemplatePicker.vue"],names:[],mappings:"AAEC,yCACC,6BAAA,CAEA,gBAAA,CAEA,4CACC,iBAAA,CACA,gBAAA,CACA,4CAAA,CAIF,yCACC,YAAA,CACA,8BAAA,CACA,qBAAA,CAEA,kCAAA,CACA,wDAAA,CAEA,kBAAA,CAEA,sBAAA,CAGD,4CACC,YAAA,CACA,6BAAA,CACA,2CAAA,CACA,eAAA,CACA,QAAA,CACA,oEAAA,CAEA,kHACC,WAAA,CAKF,oDACC,iBAAA,CAGD,4CACC,iBAAA,CACA,KAAA,CACA,MAAA,CACA,sBAAA,CACA,UAAA,CACA,WAAA,CACA,QAAA,CACA,yDAAA",sourcesContent:["\n.templates-picker {\n\t&__form {\n\t\tpadding: calc(var(--margin) * 2);\n\t\t// Will be handled by the buttons\n\t\tpadding-bottom: 0;\n\n\t\th2 {\n\t\t\ttext-align: center;\n\t\t\tfont-weight: bold;\n\t\t\tmargin: var(--margin) 0 calc(var(--margin) * 2);\n\t\t}\n\t}\n\n\t&__list {\n\t\tdisplay: grid;\n\t\tgrid-gap: calc(var(--margin) * 2);\n\t\tgrid-auto-columns: 1fr;\n\t\t// We want maximum 5 columns. Putting 6 as we don't count the grid gap. So it will always be lower than 6\n\t\tmax-width: calc(var(--fullwidth) * 6);\n\t\tgrid-template-columns: repeat(auto-fit, var(--fullwidth));\n\t\t// Make sure all rows are the same height\n\t\tgrid-auto-rows: 1fr;\n\t\t// Center the columns set\n\t\tjustify-content: center;\n\t}\n\n\t&__buttons {\n\t\tdisplay: flex;\n\t\tjustify-content: space-between;\n\t\tpadding: calc(var(--margin) * 2) var(--margin);\n\t\tposition: sticky;\n\t\tbottom: 0;\n\t\tbackground-image: linear-gradient(0, var(--gradient-main-background));\n\n\t\tbutton, input[type='submit'] {\n\t\t\theight: 44px;\n\t\t}\n\t}\n\n\t// Make sure we're relative for the loading emptycontent on top\n\t::v-deep .modal-container {\n\t\tposition: relative;\n\t}\n\n\t&__loading {\n\t\tposition: absolute;\n\t\ttop: 0;\n\t\tleft: 0;\n\t\tjustify-content: center;\n\t\twidth: 100%;\n\t\theight: 100%;\n\t\tmargin: 0;\n\t\tbackground-color: var(--color-main-background-translucent);\n\t}\n}\n\n"],sourceRoot:""}]),e.Z=a}},i={};function r(t){var e=i[t];if(void 0!==e)return e.exports;var o=i[t]={id:t,loaded:!1,exports:{}};return n[t].call(o.exports,o,o.exports,r),o.loaded=!0,o.exports}r.m=n,e=[],r.O=function(t,n,i,o){if(!n){var a=1/0;for(u=0;u<e.length;u++){n=e[u][0],i=e[u][1],o=e[u][2];for(var s=!0,l=0;l<n.length;l++)(!1&o||a>=o)&&Object.keys(r.O).every((function(t){return r.O[t](n[l])}))?n.splice(l--,1):(s=!1,o<a&&(a=o));if(s){e.splice(u--,1);var c=i();void 0!==c&&(t=c)}}return t}o=o||0;for(var u=e.length;u>0&&e[u-1][2]>o;u--)e[u]=e[u-1];e[u]=[n,i,o]},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,{a:e}),e},r.d=function(t,e){for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.nmd=function(t){return t.paths=[],t.children||(t.children=[]),t},r.j=2181,function(){r.b=document.baseURI||self.location.href;var t={2181:0};r.O.j=function(e){return 0===t[e]};var e=function(e,n){var i,o,a=n[0],s=n[1],l=n[2],c=0;if(a.some((function(e){return 0!==t[e]}))){for(i in s)r.o(s,i)&&(r.m[i]=s[i]);if(l)var u=l(r)}for(e&&e(n);c<a.length;c++)o=a[c],r.o(t,o)&&t[o]&&t[o][0](),t[o]=0;return r.O(u)},n=self.webpackChunknextcloud=self.webpackChunknextcloud||[];n.forEach(e.bind(null,0)),n.push=e.bind(null,n.push.bind(n))}(),r.nc=void 0;var o=r.O(void 0,[7874],(function(){return r(72738)}));o=r.O(o)}();
- //# sourceMappingURL=files-main.js.map?v=2b657cf842600477490a
|