diff options
Diffstat (limited to 'dist/files_sharing-files_sharing_tab.js')
-rw-r--r-- | dist/files_sharing-files_sharing_tab.js | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/dist/files_sharing-files_sharing_tab.js b/dist/files_sharing-files_sharing_tab.js new file mode 100644 index 00000000000..383a95b3848 --- /dev/null +++ b/dist/files_sharing-files_sharing_tab.js @@ -0,0 +1,3 @@ +/*! For license information please see files_sharing-files_sharing_tab.js.LICENSE.txt */ +(()=>{"use strict";var n,e={66647:(n,e,a)=>{var s=a(20144),i=a(72268),r=a.n(i),o=a(9944),h=a(1794),l=a(79753),c=a(28017),d=a.n(c),p=a(4820);class u{get isPublicUploadEnabled(){return document.getElementById("filestable")&&"yes"===document.getElementById("filestable").dataset.allowPublicUpload}get isShareWithLinkAllowed(){return document.getElementById("allowShareWithLink")&&"yes"===document.getElementById("allowShareWithLink").value}get federatedShareDocLink(){return OC.appConfig.core.federatedCloudShareDoc}get defaultExpirationDateString(){let n="";if(this.isDefaultExpireDateEnabled){const e=window.moment.utc(),t=this.defaultExpireDate;e.add(t,"days"),n=e.format("YYYY-MM-DD")}return n}get defaultInternalExpirationDateString(){let n="";if(this.isDefaultInternalExpireDateEnabled){const e=window.moment.utc(),t=this.defaultInternalExpireDate;e.add(t,"days"),n=e.format("YYYY-MM-DD")}return n}get defaultRemoteExpirationDateString(){let n="";if(this.isDefaultRemoteExpireDateEnabled){const e=window.moment.utc(),t=this.defaultRemoteExpireDate;e.add(t,"days"),n=e.format("YYYY-MM-DD")}return n}get enforcePasswordForPublicLink(){return!0===OC.appConfig.core.enforcePasswordForPublicLink}get enableLinkPasswordByDefault(){return!0===OC.appConfig.core.enableLinkPasswordByDefault}get isDefaultExpireDateEnforced(){return!0===OC.appConfig.core.defaultExpireDateEnforced}get isDefaultExpireDateEnabled(){return!0===OC.appConfig.core.defaultExpireDateEnabled}get isDefaultInternalExpireDateEnforced(){return!0===OC.appConfig.core.defaultInternalExpireDateEnforced}get isDefaultRemoteExpireDateEnforced(){return!0===OC.appConfig.core.defaultRemoteExpireDateEnforced}get isDefaultInternalExpireDateEnabled(){return!0===OC.appConfig.core.defaultInternalExpireDateEnabled}get isRemoteShareAllowed(){return!0===OC.appConfig.core.remoteShareAllowed}get isMailShareAllowed(){var n,e,t;const a=OC.getCapabilities();return void 0!==(null==a||null===(n=a.files_sharing)||void 0===n?void 0:n.sharebymail)&&!0===(null==a||null===(e=a.files_sharing)||void 0===e||null===(t=e.public)||void 0===t?void 0:t.enabled)}get defaultExpireDate(){return OC.appConfig.core.defaultExpireDate}get defaultInternalExpireDate(){return OC.appConfig.core.defaultInternalExpireDate}get defaultRemoteExpireDate(){return OC.appConfig.core.defaultRemoteExpireDate}get isResharingAllowed(){return!0===OC.appConfig.core.resharingAllowed}get isPasswordForMailSharesRequired(){return void 0!==OC.getCapabilities().files_sharing.sharebymail&&OC.getCapabilities().files_sharing.sharebymail.password.enforced}get shouldAlwaysShowUnique(){var n,e;return!0===(null===(n=OC.getCapabilities().files_sharing)||void 0===n||null===(e=n.sharee)||void 0===e?void 0:e.always_show_unique)}get allowGroupSharing(){return!0===OC.appConfig.core.allowGroupSharing}get maxAutocompleteResults(){return parseInt(OC.config["sharing.maxAutocompleteResults"],10)||25}get minSearchStringLength(){return parseInt(OC.config["sharing.minSearchStringLength"],10)||0}get passwordPolicy(){const n=OC.getCapabilities();return n.password_policy?n.password_policy:{}}}class g{constructor(n){var e,t;t=void 0,(e="_share")in this?Object.defineProperty(this,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):this[e]=t,n.ocs&&n.ocs.data&&n.ocs.data[0]&&(n=n.ocs.data[0]),n.hide_download=!!n.hide_download,n.mail_send=!!n.mail_send,this._share=n}get state(){return this._share}get id(){return this._share.id}get type(){return this._share.share_type}get permissions(){return this._share.permissions}set permissions(n){this._share.permissions=n}get owner(){return this._share.uid_owner}get ownerDisplayName(){return this._share.displayname_owner}get shareWith(){return this._share.share_with}get shareWithDisplayName(){return this._share.share_with_displayname||this._share.share_with}get shareWithDisplayNameUnique(){return this._share.share_with_displayname_unique||this._share.share_with}get shareWithLink(){return this._share.share_with_link}get shareWithAvatar(){return this._share.share_with_avatar}get uidFileOwner(){return this._share.uid_file_owner}get displaynameFileOwner(){return this._share.displayname_file_owner||this._share.uid_file_owner}get createdTime(){return this._share.stime}get expireDate(){return this._share.expiration}set expireDate(n){this._share.expiration=n}get token(){return this._share.token}get note(){return this._share.note}set note(n){this._share.note=n}get label(){return this._share.label}set label(n){this._share.label=n}get mailSend(){return!0===this._share.mail_send}get hideDownload(){return!0===this._share.hide_download}set hideDownload(n){this._share.hide_download=!0===n}get password(){return this._share.password}set password(n){this._share.password=n}get sendPasswordByTalk(){return this._share.send_password_by_talk}set sendPasswordByTalk(n){this._share.send_password_by_talk=n}get path(){return this._share.path}get itemType(){return this._share.item_type}get mimetype(){return this._share.mimetype}get fileSource(){return this._share.file_source}get fileTarget(){return this._share.file_target}get fileParent(){return this._share.file_parent}get hasReadPermission(){return!!(this.permissions&OC.PERMISSION_READ)}get hasCreatePermission(){return!!(this.permissions&OC.PERMISSION_CREATE)}get hasDeletePermission(){return!!(this.permissions&OC.PERMISSION_DELETE)}get hasUpdatePermission(){return!!(this.permissions&OC.PERMISSION_UPDATE)}get hasSharePermission(){return!!(this.permissions&OC.PERMISSION_SHARE)}get canEdit(){return!0===this._share.can_edit}get canDelete(){return!0===this._share.can_delete}get viaFileid(){return this._share.via_fileid}get viaPath(){return this._share.via_path}get parent(){return this._share.parent}get storageId(){return this._share.storage_id}get storage(){return this._share.storage}get itemSource(){return this._share.item_source}get status(){return this._share.status}}const f={data:()=>({SHARE_TYPES:{SHARE_TYPE_USER:OC.Share.SHARE_TYPE_USER,SHARE_TYPE_GROUP:OC.Share.SHARE_TYPE_GROUP,SHARE_TYPE_LINK:OC.Share.SHARE_TYPE_LINK,SHARE_TYPE_EMAIL:OC.Share.SHARE_TYPE_EMAIL,SHARE_TYPE_REMOTE:OC.Share.SHARE_TYPE_REMOTE,SHARE_TYPE_CIRCLE:OC.Share.SHARE_TYPE_CIRCLE,SHARE_TYPE_GUEST:OC.Share.SHARE_TYPE_GUEST,SHARE_TYPE_DECK:OC.Share.SHARE_TYPE_DECK,SHARE_TYPE_REMOTE_GROUP:OC.Share.SHARE_TYPE_REMOTE_GROUP,SHARE_TYPE_ROOM:OC.Share.SHARE_TYPE_ROOM}})};var _=a(74466),A=a.n(_),m=a(79440),E=a.n(m),S=a(15168),y=a.n(S);const v={name:"SharingEntrySimple",components:{Actions:E()},directives:{Tooltip:y()},props:{title:{type:String,default:"",required:!0},tooltip:{type:String,default:""},subtitle:{type:String,default:""},isUnique:{type:Boolean,default:!0}}};var w=a(93379),C=a.n(w),b=a(35917);C()(b.Z,{insert:"head",singleton:!1}),b.Z.locals;var P=a(51900);const x=(0,P.Z)(v,(function(){var n=this,e=n.$createElement,t=n._self._c||e;return t("li",{staticClass:"sharing-entry"},[n._t("avatar"),n._v(" "),t("div",{directives:[{name:"tooltip",rawName:"v-tooltip",value:n.tooltip,expression:"tooltip"}],staticClass:"sharing-entry__desc"},[t("h5",[n._v(n._s(n.title))]),n._v(" "),n.subtitle?t("p",[n._v("\n\t\t\t"+n._s(n.subtitle)+"\n\t\t")]):n._e()]),n._v(" "),n.$slots.default?t("Actions",{staticClass:"sharing-entry__actions",attrs:{"menu-align":"right"}},[n._t("default")],2):n._e()],2)}),[],!1,null,"1436bf4a",null).exports,R={name:"SharingEntryInternal",components:{ActionLink:A(),SharingEntrySimple:x},props:{fileInfo:{type:Object,default:()=>{},required:!0}},data:()=>({copied:!1,copySuccess:!1}),computed:{internalLink(){return window.location.protocol+"//"+window.location.host+(0,l.generateUrl)("/f/")+this.fileInfo.id},clipboardTooltip(){return this.copied?this.copySuccess?t("files_sharing","Link copied"):t("files_sharing","Cannot copy, please copy the link manually"):t("files_sharing","Copy to clipboard")},internalLinkSubtitle(){return"dir"===this.fileInfo.type?t("files_sharing","Only works for users with access to this folder"):t("files_sharing","Only works for users with access to this file")}},methods:{async copyLink(){try{await this.$copyText(this.internalLink),this.$refs.copyButton.$el.focus(),this.copySuccess=!0,this.copied=!0}catch(n){this.copySuccess=!1,this.copied=!0,console.error(n)}finally{setTimeout((()=>{this.copySuccess=!1,this.copied=!1}),4e3)}}}};var k=a(26554);C()(k.Z,{insert:"head",singleton:!1}),k.Z.locals;const T=(0,P.Z)(R,(function(){var n=this,e=n.$createElement,t=n._self._c||e;return t("SharingEntrySimple",{staticClass:"sharing-entry__internal",attrs:{title:n.t("files_sharing","Internal link"),subtitle:n.internalLinkSubtitle},scopedSlots:n._u([{key:"avatar",fn:function(){return[t("div",{staticClass:"avatar-external icon-external-white"})]},proxy:!0}])},[n._v(" "),t("ActionLink",{ref:"copyButton",attrs:{href:n.internalLink,target:"_blank",icon:n.copied&&n.copySuccess?"icon-checkmark-color":"icon-clippy"},on:{click:function(e){return e.preventDefault(),n.copyLink.apply(null,arguments)}}},[n._v("\n\t\t"+n._s(n.clipboardTooltip)+"\n\t")])],1)}),[],!1,null,"456815d3",null).exports;var D=a(22200),O=a(20296),I=a.n(O),Y=a(7811),H=a.n(Y);const L=new u,N="abcdefgijkmnopqrstwxyzABCDEFGHJKLMNPQRSTWXYZ23456789";async function M(){if(L.passwordPolicy.api&&L.passwordPolicy.api.generate)try{const n=await p.default.get(L.passwordPolicy.api.generate);if(n.data.ocs.data.password)return n.data.ocs.data.password}catch(n){console.info("Error generating password from password_policy",n)}return Array(10).fill(0).reduce(((n,e)=>n+N.charAt(Math.floor(Math.random()*N.length))),"")}a(35449);const U=(0,l.generateOcsUrl)("apps/files_sharing/api/v1/shares"),B={"Content-Type":"application/x-www-form-urlencoded;charset=UTF-8"},W={methods:{async createShare(n){let{path:e,permissions:a,shareType:s,shareWith:i,publicUpload:r,password:o,sendPasswordByTalk:h,expireDate:l,label:c}=n;try{var d;const n=await p.default.post(U,{path:e,permissions:a,shareType:s,shareWith:i,publicUpload:r,password:o,sendPasswordByTalk:h,expireDate:l,label:c});if(null==n||null===(d=n.data)||void 0===d||!d.ocs)throw n;return new g(n.data.ocs.data)}catch(n){var u,f,_,A;console.error("Error while creating share",n);const e=null==n||null===(u=n.response)||void 0===u||null===(f=u.data)||void 0===f||null===(_=f.ocs)||void 0===_||null===(A=_.meta)||void 0===A?void 0:A.message;throw OC.Notification.showTemporary(e?t("files_sharing","Error creating the share: {errorMessage}",{errorMessage:e}):t("files_sharing","Error creating the share"),{type:"error"}),n}},async deleteShare(n){try{var e;const t=await p.default.delete(U+"/".concat(n));if(null==t||null===(e=t.data)||void 0===e||!e.ocs)throw t;return!0}catch(n){var a,s,i,r;console.error("Error while deleting share",n);const e=null==n||null===(a=n.response)||void 0===a||null===(s=a.data)||void 0===s||null===(i=s.ocs)||void 0===i||null===(r=i.meta)||void 0===r?void 0:r.message;throw OC.Notification.showTemporary(e?t("files_sharing","Error deleting the share: {errorMessage}",{errorMessage:e}):t("files_sharing","Error deleting the share"),{type:"error"}),n}},async updateShare(n,e){try{var a;const t=await p.default.put(U+"/".concat(n),e,B);if(null==t||null===(a=t.data)||void 0===a||!a.ocs)throw t;return!0}catch(n){if(console.error("Error while updating share",n),400!==n.response.status){var s,i,r,o;const e=null==n||null===(s=n.response)||void 0===s||null===(i=s.data)||void 0===i||null===(r=i.ocs)||void 0===r||null===(o=r.meta)||void 0===o?void 0:o.message;OC.Notification.showTemporary(e?t("files_sharing","Error updating the share: {errorMessage}",{errorMessage:e}):t("files_sharing","Error updating the share"),{type:"error"})}const e=n.response.data.ocs.meta.message;throw new Error(e)}}}},q={name:"SharingInput",components:{Multiselect:H()},mixins:[f,W],props:{shares:{type:Array,default:()=>[],required:!0},linkShares:{type:Array,default:()=>[],required:!0},fileInfo:{type:Object,default:()=>{},required:!0},reshare:{type:g,default:null},canReshare:{type:Boolean,required:!0}},data:()=>({config:new u,loading:!1,query:"",recommendations:[],ShareSearch:OCA.Sharing.ShareSearch.state,suggestions:[]}),computed:{externalResults(){return this.ShareSearch.results},inputPlaceholder(){const n=this.config.isRemoteShareAllowed;return this.canReshare?n?t("files_sharing","Name, email, or Federated Cloud ID …"):t("files_sharing","Name or email …"):t("files_sharing","Resharing is not allowed")},isValidQuery(){return this.query&&""!==this.query.trim()&&this.query.length>this.config.minSearchStringLength},options(){return this.isValidQuery?this.suggestions:this.recommendations},noResultText(){return this.loading?t("files_sharing","Searching …"):t("files_sharing","No elements found.")}},mounted(){this.getRecommendations()},methods:{async asyncFind(n,e){this.query=n.trim(),this.isValidQuery&&(this.loading=!0,await this.debounceGetSuggestions(n))},async getSuggestions(n){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.loading=!0,!0===OC.getCapabilities().files_sharing.sharee.query_lookup_default&&(e=!0);const a=[this.SHARE_TYPES.SHARE_TYPE_USER,this.SHARE_TYPES.SHARE_TYPE_GROUP,this.SHARE_TYPES.SHARE_TYPE_REMOTE,this.SHARE_TYPES.SHARE_TYPE_REMOTE_GROUP,this.SHARE_TYPES.SHARE_TYPE_CIRCLE,this.SHARE_TYPES.SHARE_TYPE_ROOM,this.SHARE_TYPES.SHARE_TYPE_GUEST,this.SHARE_TYPES.SHARE_TYPE_DECK];!0===OC.getCapabilities().files_sharing.public.enabled&&a.push(this.SHARE_TYPES.SHARE_TYPE_EMAIL);let s=null;try{s=await p.default.get((0,l.generateOcsUrl)("apps/files_sharing/api/v1/sharees"),{params:{format:"json",itemType:"dir"===this.fileInfo.type?"folder":"file",search:n,lookup:e,perPage:this.config.maxAutocompleteResults,shareType:a}})}catch(n){return void console.error("Error fetching suggestions",n)}const i=s.data.ocs.data,r=s.data.ocs.data.exact;i.exact=[];const o=Object.values(r).reduce(((n,e)=>n.concat(e)),[]),h=Object.values(i).reduce(((n,e)=>n.concat(e)),[]),c=this.filterOutExistingShares(o).map((n=>this.formatForMultiselect(n))).sort(((n,e)=>n.shareType-e.shareType)),d=this.filterOutExistingShares(h).map((n=>this.formatForMultiselect(n))).sort(((n,e)=>n.shareType-e.shareType)),u=[];i.lookupEnabled&&!e&&u.push({id:"global-lookup",isNoUser:!0,displayName:t("files_sharing","Search globally"),lookup:!0});const g=this.externalResults.filter((n=>!n.condition||n.condition(this))),f=c.concat(d).concat(g).concat(u),_=f.reduce(((n,e)=>e.displayName?(n[e.displayName]||(n[e.displayName]=0),n[e.displayName]++,n):n),{});this.suggestions=f.map((n=>_[n.displayName]>1&&!n.desc?{...n,desc:n.shareWithDisplayNameUnique}:n)),this.loading=!1,console.info("suggestions",this.suggestions)},debounceGetSuggestions:I()((function(){this.getSuggestions(...arguments)}),300),async getRecommendations(){this.loading=!0;let n=null;try{n=await p.default.get((0,l.generateOcsUrl)("apps/files_sharing/api/v1/sharees_recommended"),{params:{format:"json",itemType:this.fileInfo.type}})}catch(n){return void console.error("Error fetching recommendations",n)}const e=this.externalResults.filter((n=>!n.condition||n.condition(this))),t=Object.values(n.data.ocs.data.exact).reduce(((n,e)=>n.concat(e)),[]);this.recommendations=this.filterOutExistingShares(t).map((n=>this.formatForMultiselect(n))).concat(e),this.loading=!1,console.info("recommendations",this.recommendations)},filterOutExistingShares(n){return n.reduce(((n,e)=>{if("object"!=typeof e)return n;try{if(e.value.shareType===this.SHARE_TYPES.SHARE_TYPE_USER){if(e.value.shareWith===(0,D.getCurrentUser)().uid)return n;if(this.reshare&&e.value.shareWith===this.reshare.owner)return n}if(e.value.shareType===this.SHARE_TYPES.SHARE_TYPE_EMAIL){if(-1!==this.linkShares.map((n=>n.shareWith)).indexOf(e.value.shareWith.trim()))return n}else{const t=this.shares.reduce(((n,e)=>(n[e.shareWith]=e.type,n)),{}),a=e.value.shareWith.trim();if(a in t&&t[a]===e.value.shareType)return n}n.push(e)}catch{return n}return n}),[])},shareTypeToIcon(n){switch(n){case this.SHARE_TYPES.SHARE_TYPE_GUEST:return"icon-user";case this.SHARE_TYPES.SHARE_TYPE_REMOTE_GROUP:case this.SHARE_TYPES.SHARE_TYPE_GROUP:return"icon-group";case this.SHARE_TYPES.SHARE_TYPE_EMAIL:return"icon-mail";case this.SHARE_TYPES.SHARE_TYPE_CIRCLE:return"icon-circle";case this.SHARE_TYPES.SHARE_TYPE_ROOM:return"icon-room";case this.SHARE_TYPES.SHARE_TYPE_DECK:return"icon-deck";default:return""}},formatForMultiselect(n){let e;var a;if(n.value.shareType===this.SHARE_TYPES.SHARE_TYPE_USER&&this.config.shouldAlwaysShowUnique)e=null!==(a=n.shareWithDisplayNameUnique)&&void 0!==a?a:"";else if(n.value.shareType!==this.SHARE_TYPES.SHARE_TYPE_REMOTE&&n.value.shareType!==this.SHARE_TYPES.SHARE_TYPE_REMOTE_GROUP||!n.value.server)if(n.value.shareType===this.SHARE_TYPES.SHARE_TYPE_EMAIL)e=n.value.shareWith;else{var s;e=null!==(s=n.shareWithDescription)&&void 0!==s?s:""}else e=t("files_sharing","on {server}",{server:n.value.server});return{id:"".concat(n.value.shareType,"-").concat(n.value.shareWith),shareWith:n.value.shareWith,shareType:n.value.shareType,user:n.uuid||n.value.shareWith,isNoUser:n.value.shareType!==this.SHARE_TYPES.SHARE_TYPE_USER,displayName:n.name||n.label,subtitle:e,shareWithDisplayNameUnique:n.shareWithDisplayNameUnique||"",icon:this.shareTypeToIcon(n.value.shareType)}},async addShare(n){if(n.lookup)return await this.getSuggestions(this.query,!0),this.$nextTick((()=>{this.$refs.multiselect.$el.querySelector(".multiselect__input").focus()})),!0;if(n.handler){const e=await n.handler(this);return this.$emit("add:share",new g(e)),!0}this.loading=!0,console.debug("Adding a new share from the input for",n);try{var e,t,a;let s=null;this.config.enforcePasswordForPublicLink&&n.shareType===this.SHARE_TYPES.SHARE_TYPE_EMAIL&&(s=await M());const i=(this.fileInfo.path+"/"+this.fileInfo.name).replace("//","/"),r=await this.createShare({path:i,shareType:n.shareType,shareWith:n.shareWith,password:s,permissions:this.fileInfo.sharePermissions&OC.getCapabilities().files_sharing.default_permissions});s?(r.newPassword=s,(await new Promise((n=>{this.$emit("add:share",r,n)}))).open=!0):this.$emit("add:share",r),null!==(e=this.$refs.multiselect)&&void 0!==e&&null!==(t=e.$refs)&&void 0!==t&&null!==(a=t.VueMultiselect)&&void 0!==a&&a.search&&(this.$refs.multiselect.$refs.VueMultiselect.search=""),await this.getRecommendations()}catch(e){const t=this.$refs.multiselect.$el.querySelector("input");t&&t.focus(),this.query=n.shareWith,console.error("Error while adding new share",e)}finally{this.loading=!1}}}};var $=a(84721);C()($.Z,{insert:"head",singleton:!1}),$.Z.locals;const F=(0,P.Z)(q,(function(){var n=this,e=n.$createElement;return(n._self._c||e)("Multiselect",{ref:"multiselect",staticClass:"sharing-input",attrs:{"clear-on-select":!0,disabled:!n.canReshare,"hide-selected":!0,"internal-search":!1,loading:n.loading,options:n.options,placeholder:n.inputPlaceholder,"preselect-first":!0,"preserve-search":!0,searchable:!0,"user-select":!0,"open-direction":"below",label:"displayName","track-by":"id"},on:{"search-change":n.asyncFind,select:n.addShare},scopedSlots:n._u([{key:"noOptions",fn:function(){return[n._v("\n\t\t"+n._s(n.t("files_sharing","No recommendations. Start typing."))+"\n\t")]},proxy:!0},{key:"noResult",fn:function(){return[n._v("\n\t\t"+n._s(n.noResultText)+"\n\t")]},proxy:!0}])})}),[],!1,null,null,null).exports;var j=a(56286),G=a.n(j),Z=a(76632),K=a(41009),V=a.n(K),Q=a(49811);const z={mixins:[W,f],props:{fileInfo:{type:Object,default:()=>{},required:!0},share:{type:g,default:null},isUnique:{type:Boolean,default:!0}},data(){var n;return{config:new u,errors:{},loading:!1,saving:!1,open:!1,updateQueue:new Q.Z({concurrency:1}),reactiveState:null===(n=this.share)||void 0===n?void 0:n.state,SHARE_TYPES:{SHARE_TYPE_USER:OC.Share.SHARE_TYPE_USER,SHARE_TYPE_GROUP:OC.Share.SHARE_TYPE_GROUP,SHARE_TYPE_LINK:OC.Share.SHARE_TYPE_LINK,SHARE_TYPE_EMAIL:OC.Share.SHARE_TYPE_EMAIL,SHARE_TYPE_REMOTE:OC.Share.SHARE_TYPE_REMOTE,SHARE_TYPE_CIRCLE:OC.Share.SHARE_TYPE_CIRCLE,SHARE_TYPE_GUEST:OC.Share.SHARE_TYPE_GUEST,SHARE_TYPE_REMOTE_GROUP:OC.Share.SHARE_TYPE_REMOTE_GROUP,SHARE_TYPE_ROOM:OC.Share.SHARE_TYPE_ROOM}}},computed:{hasNote:{get(){return""!==this.share.note},set(n){this.share.note=n?null:""}},dateTomorrow:()=>moment().add(1,"days"),firstDay:()=>window.firstDay?window.firstDay:0,lang:()=>({days:window.dayNamesShort?window.dayNamesShort:["Sun.","Mon.","Tue.","Wed.","Thu.","Fri.","Sat."],months:window.monthNamesShort?window.monthNamesShort:["Jan.","Feb.","Mar.","Apr.","May.","Jun.","Jul.","Aug.","Sep.","Oct.","Nov.","Dec."],placeholder:{date:"Select Date"}}),isShareOwner(){return this.share&&this.share.owner===(0,D.getCurrentUser)().uid}},methods:{checkShare:n=>(!n.password||"string"==typeof n.password&&""!==n.password.trim())&&!(n.expirationDate&&!moment(n.expirationDate).isValid()),onExpirationChange(n){const e=moment(n).format("YYYY-MM-DD");this.share.expireDate=e,this.queueUpdate("expireDate")},onExpirationDisable(){this.share.expireDate="",this.queueUpdate("expireDate")},onNoteChange(n){this.$set(this.share,"newNote",n.trim())},onNoteSubmit(){this.share.newNote&&(this.share.note=this.share.newNote,this.$delete(this.share,"newNote"),this.queueUpdate("note"))},async onDelete(){try{this.loading=!0,this.open=!1,await this.deleteShare(this.share.id),console.debug("Share deleted",this.share.id),this.$emit("remove:share",this.share)}catch(n){this.open=!0}finally{this.loading=!1}},queueUpdate(){for(var n=arguments.length,e=new Array(n),t=0;t<n;t++)e[t]=arguments[t];if(0!==e.length)if(this.share.id){const n={};e.map((e=>n[e]=this.share[e].toString())),this.updateQueue.add((async()=>{this.saving=!0,this.errors={};try{await this.updateShare(this.share.id,n),e.indexOf("password")>=0&&this.$delete(this.share,"newPassword"),this.$delete(this.errors,e[0])}catch({message:n}){n&&""!==n&&this.onSyncError(e[0],n)}finally{this.saving=!1}}))}else console.error("Cannot update share.",this.share,"No valid id")},onSyncError(n,e){switch(this.open=!0,n){case"password":case"pending":case"expireDate":case"label":case"note":{this.$set(this.errors,n,e);let t=this.$refs[n];if(t){t.$el&&(t=t.$el);const n=t.querySelector(".focusable");n&&n.focus()}break}case"sendPasswordByTalk":this.$set(this.errors,n,e),this.share.sendPasswordByTalk=!this.share.sendPasswordByTalk}},debounceQueueUpdate:I()((function(n){this.queueUpdate(n)}),500),disabledDate(n){const e=moment(n);return this.dateTomorrow&&e.isBefore(this.dateTomorrow,"day")||this.dateMaxEnforced&&e.isSameOrAfter(this.dateMaxEnforced,"day")}}},J={name:"SharingEntryInherited",components:{ActionButton:G(),ActionLink:A(),ActionText:V(),Avatar:d(),SharingEntrySimple:x},mixins:[z],props:{share:{type:g,required:!0}},computed:{viaFileTargetUrl(){return(0,l.generateUrl)("/f/{fileid}",{fileid:this.share.viaFileid})},viaFolderName(){return(0,Z.EZ)(this.share.viaPath)}}};var X=a(61923);C()(X.Z,{insert:"head",singleton:!1}),X.Z.locals;const nn=(0,P.Z)(J,(function(){var n=this,e=n.$createElement,t=n._self._c||e;return t("SharingEntrySimple",{key:n.share.id,staticClass:"sharing-entry__inherited",attrs:{title:n.share.shareWithDisplayName},scopedSlots:n._u([{key:"avatar",fn:function(){return[t("Avatar",{staticClass:"sharing-entry__avatar",attrs:{user:n.share.shareWith,"display-name":n.share.shareWithDisplayName,"tooltip-message":""}})]},proxy:!0}])},[n._v(" "),t("ActionText",{attrs:{icon:"icon-user"}},[n._v("\n\t\t"+n._s(n.t("files_sharing","Added by {initiator}",{initiator:n.share.ownerDisplayName}))+"\n\t")]),n._v(" "),n.share.viaPath&&n.share.viaFileid?t("ActionLink",{attrs:{icon:"icon-folder",href:n.viaFileTargetUrl}},[n._v("\n\t\t"+n._s(n.t("files_sharing","Via “{folder}”",{folder:n.viaFolderName}))+"\n\t")]):n._e(),n._v(" "),n.share.canDelete?t("ActionButton",{attrs:{icon:"icon-close"},on:{click:function(e){return e.preventDefault(),n.onDelete.apply(null,arguments)}}},[n._v("\n\t\t"+n._s(n.t("files_sharing","Unshare"))+"\n\t")]):n._e()],1)}),[],!1,null,"c58e421a",null).exports,en={name:"SharingInherited",components:{ActionButton:G(),SharingEntryInherited:nn,SharingEntrySimple:x},props:{fileInfo:{type:Object,default:()=>{},required:!0}},data:()=>({loaded:!1,loading:!1,showInheritedShares:!1,shares:[]}),computed:{showInheritedSharesIcon(){return this.loading?"icon-loading-small":this.showInheritedShares?"icon-triangle-n":"icon-triangle-s"},mainTitle:()=>t("files_sharing","Others with access"),subTitle(){return this.showInheritedShares&&0===this.shares.length?t("files_sharing","No other users with access found"):""},toggleTooltip(){return"dir"===this.fileInfo.type?t("files_sharing","Toggle list of others with access to this directory"):t("files_sharing","Toggle list of others with access to this file")},fullPath(){return"".concat(this.fileInfo.path,"/").concat(this.fileInfo.name).replace("//","/")}},watch:{fileInfo(){this.resetState()}},methods:{toggleInheritedShares(){this.showInheritedShares=!this.showInheritedShares,this.showInheritedShares?this.fetchInheritedShares():this.resetState()},async fetchInheritedShares(){this.loading=!0;try{const n=(0,l.generateOcsUrl)("apps/files_sharing/api/v1/shares/inherited?format=json&path={path}",{path:this.fullPath}),e=await p.default.get(n);this.shares=e.data.ocs.data.map((n=>new g(n))).sort(((n,e)=>e.createdTime-n.createdTime)),console.info(this.shares),this.loaded=!0}catch(n){OC.Notification.showTemporary(t("files_sharing","Unable to fetch inherited shares"),{type:"error"})}finally{this.loading=!1}},resetState(){this.loaded=!1,this.loading=!1,this.showInheritedShares=!1,this.shares=[]}}};var tn=a(61436);C()(tn.Z,{insert:"head",singleton:!1}),tn.Z.locals;const an=(0,P.Z)(en,(function(){var n=this,e=n.$createElement,t=n._self._c||e;return t("ul",{attrs:{id:"sharing-inherited-shares"}},[t("SharingEntrySimple",{staticClass:"sharing-entry__inherited",attrs:{title:n.mainTitle,subtitle:n.subTitle},scopedSlots:n._u([{key:"avatar",fn:function(){return[t("div",{staticClass:"avatar-shared icon-more-white"})]},proxy:!0}])},[n._v(" "),t("ActionButton",{attrs:{icon:n.showInheritedSharesIcon},on:{click:function(e){return e.preventDefault(),e.stopPropagation(),n.toggleInheritedShares.apply(null,arguments)}}},[n._v("\n\t\t\t"+n._s(n.toggleTooltip)+"\n\t\t")])],1),n._v(" "),n._l(n.shares,(function(e){return t("SharingEntryInherited",{key:e.id,attrs:{"file-info":n.fileInfo,share:e}})}))],2)}),[],!1,null,"1c2059ae",null).exports;var sn=a(83779),rn=a.n(sn),on=a(88408),hn=a.n(on),ln=a(10949),cn=a.n(ln),dn=a(97654),pn=a.n(dn);const un={name:"ExternalShareAction",props:{id:{type:String,required:!0},action:{type:Object,default:()=>({})},fileInfo:{type:Object,default:()=>{},required:!0},share:{type:g,default:null}},computed:{data(){return this.action.data(this)}}},gn=(0,P.Z)(un,(function(){var n=this,e=n.$createElement;return(n._self._c||e)(n.data.is,n._g(n._b({tag:"Component"},"Component",n.data,!1),n.action.handlers),[n._v("\n\t"+n._s(n.data.text)+"\n")])}),[],!1,null,null,null).exports,fn={name:"SharingEntryLink",components:{Actions:E(),ActionButton:G(),ActionCheckbox:rn(),ActionRadio:cn(),ActionInput:hn(),ActionLink:A(),ActionText:V(),ActionTextEditable:pn(),Avatar:d(),ExternalShareAction:gn},directives:{Tooltip:y()},mixins:[z],props:{canReshare:{type:Boolean,default:!0}},data:()=>({copySuccess:!0,copied:!1,pending:!1,publicUploadRWValue:OC.PERMISSION_UPDATE|OC.PERMISSION_CREATE|OC.PERMISSION_READ|OC.PERMISSION_DELETE,publicUploadRValue:OC.PERMISSION_READ,publicUploadWValue:OC.PERMISSION_CREATE,ExternalLegacyLinkActions:OCA.Sharing.ExternalLinkActions.state,ExternalShareActions:OCA.Sharing.ExternalShareActions.state}),computed:{sharePermissions(){return this.share.permissions&~OC.PERMISSION_SHARE},randomId:()=>Math.random().toString(27).substr(2),title(){if(this.share&&this.share.id){if(!this.isShareOwner&&this.share.ownerDisplayName)return this.isEmailShareType?t("files_sharing","{shareWith} by {initiator}",{shareWith:this.share.shareWith,initiator:this.share.ownerDisplayName}):t("files_sharing","Shared via link by {initiator}",{initiator:this.share.ownerDisplayName});if(this.share.label&&""!==this.share.label.trim())return this.isEmailShareType?t("files_sharing","Mail share ({label})",{label:this.share.label.trim()}):t("files_sharing","Share link ({label})",{label:this.share.label.trim()});if(this.isEmailShareType)return this.share.shareWith}return t("files_sharing","Share link")},subtitle(){return this.isEmailShareType&&this.title!==this.share.shareWith?this.share.shareWith:null},hasExpirationDate:{get(){return this.config.isDefaultExpireDateEnforced||!!this.share.expireDate},set(n){let e=moment(this.config.defaultExpirationDateString);e.isValid()||(e=moment()),this.share.state.expiration=n?e.format("YYYY-MM-DD"):"",console.debug("Expiration date status",n,this.share.expireDate)}},dateMaxEnforced(){return this.config.isDefaultExpireDateEnforced&&moment().add(1+this.config.defaultExpireDate,"days")},isPasswordProtected:{get(){return this.config.enforcePasswordForPublicLink||!!this.share.password},async set(n){s.default.set(this.share,"password",n?await M():""),s.default.set(this.share,"newPassword",this.share.password)}},isTalkEnabled:()=>void 0!==OC.appswebroots.spreed,isPasswordProtectedByTalkAvailable(){return this.isPasswordProtected&&this.isTalkEnabled},isPasswordProtectedByTalk:{get(){return this.share.sendPasswordByTalk},async set(n){this.share.sendPasswordByTalk=n}},isEmailShareType(){return!!this.share&&this.share.type===this.SHARE_TYPES.SHARE_TYPE_EMAIL},canTogglePasswordProtectedByTalkAvailable(){return!(!this.isPasswordProtected||this.isEmailShareType&&!this.hasUnsavedPassword)},pendingPassword(){return this.config.enforcePasswordForPublicLink&&this.share&&!this.share.id},pendingExpirationDate(){return this.config.isDefaultExpireDateEnforced&&this.share&&!this.share.id},canUpdate:{get(){return this.share.hasUpdatePermission},set(n){this.share.permissions=n?OC.PERMISSION_READ|OC.PERMISSION_UPDATE:OC.PERMISSION_READ}},hasUnsavedPassword(){return void 0!==this.share.newPassword},isFolder(){return"dir"===this.fileInfo.type},fileHasCreatePermission(){return!!(this.fileInfo.permissions&OC.PERMISSION_CREATE)},shareLink(){return window.location.protocol+"//"+window.location.host+(0,l.generateUrl)("/s/")+this.share.token},clipboardTooltip(){return this.copied?this.copySuccess?t("files_sharing","Link copied"):t("files_sharing","Cannot copy, please copy the link manually"):t("files_sharing","Copy to clipboard")},externalLegacyLinkActions(){return this.ExternalLegacyLinkActions.actions},externalLinkActions(){return this.ExternalShareActions.actions.filter((n=>n.shareType.includes(OC.Share.SHARE_TYPE_LINK)||n.shareType.includes(OC.Share.SHARE_TYPE_EMAIL)))},isPasswordPolicyEnabled(){return"object"==typeof this.config.passwordPolicy}},methods:{async onNewLinkShare(){if(this.loading)return;const n={share_type:OC.Share.SHARE_TYPE_LINK};if(this.config.isDefaultExpireDateEnforced&&(n.expiration=this.config.defaultExpirationDateString),this.config.enableLinkPasswordByDefault&&(n.password=await M()),this.config.enforcePasswordForPublicLink||this.config.isDefaultExpireDateEnforced){if(this.pending=!0,this.share&&!this.share.id)return this.checkShare(this.share)?(await this.pushNewLinkShare(this.share,!0),!0):(this.open=!0,OC.Notification.showTemporary(t("files_sharing","Error, please enter proper password and/or expiration date")),!1);this.config.enforcePasswordForPublicLink&&(n.password=await M());const e=new g(n),a=await new Promise((n=>{this.$emit("add:share",e,n)}));this.open=!1,this.pending=!1,a.open=!0}else{const e=new g(n);await this.pushNewLinkShare(e)}},async pushNewLinkShare(n,e){try{if(this.loading)return!0;this.loading=!0,this.errors={};const t=(this.fileInfo.path+"/"+this.fileInfo.name).replace("//","/"),a=await this.createShare({path:t,shareType:OC.Share.SHARE_TYPE_LINK,password:n.password,expireDate:n.expireDate});let s;this.open=!1,console.debug("Link share created",a),s=e?await new Promise((n=>{this.$emit("update:share",a,n)})):await new Promise((n=>{this.$emit("add:share",a,n)})),this.config.enforcePasswordForPublicLink||s.copyLink()}catch({response:n}){const e=n.data.ocs.meta.message;e.match(/password/i)?this.onSyncError("password",e):e.match(/date/i)?this.onSyncError("expireDate",e):this.onSyncError("pending",e)}finally{this.loading=!1}},togglePermissions(n){const e=parseInt(n.target.value,10);this.share.permissions=e,this.queueUpdate("permissions")},onLabelChange(n){this.$set(this.share,"newLabel",n.trim())},onLabelSubmit(){"string"==typeof this.share.newLabel&&(this.share.label=this.share.newLabel,this.$delete(this.share,"newLabel"),this.queueUpdate("label"))},async copyLink(){try{await this.$copyText(this.shareLink),this.$refs.copyButton.$el.focus(),this.copySuccess=!0,this.copied=!0}catch(n){this.copySuccess=!1,this.copied=!0,console.error(n)}finally{setTimeout((()=>{this.copySuccess=!1,this.copied=!1}),4e3)}},onPasswordChange(n){this.$set(this.share,"newPassword",n)},onPasswordDisable(){this.share.password="",this.$delete(this.share,"newPassword"),this.share.id&&this.queueUpdate("password")},onPasswordSubmit(){this.hasUnsavedPassword&&(this.share.password=this.share.newPassword.trim(),this.queueUpdate("password"))},onPasswordProtectedByTalkChange(){this.hasUnsavedPassword&&(this.share.password=this.share.newPassword.trim()),this.queueUpdate("sendPasswordByTalk","password")},onMenuClose(){this.onPasswordSubmit(),this.onNoteSubmit()},onCancel(){this.$emit("remove:share",this.share)}}};var _n=a(76167);C()(_n.Z,{insert:"head",singleton:!1}),_n.Z.locals;const An={name:"SharingLinkList",components:{SharingEntryLink:(0,P.Z)(fn,(function(){var n=this,e=n.$createElement,t=n._self._c||e;return t("li",{staticClass:"sharing-entry sharing-entry__link",class:{"sharing-entry--share":n.share}},[t("Avatar",{staticClass:"sharing-entry__avatar",attrs:{"is-no-user":!0,"icon-class":n.isEmailShareType?"avatar-link-share icon-mail-white":"avatar-link-share icon-public-white"}}),n._v(" "),t("div",{staticClass:"sharing-entry__desc"},[t("h5",{attrs:{title:n.title}},[n._v("\n\t\t\t"+n._s(n.title)+"\n\t\t")]),n._v(" "),n.subtitle?t("p",[n._v("\n\t\t\t"+n._s(n.subtitle)+"\n\t\t")]):n._e()]),n._v(" "),n.share&&!n.isEmailShareType&&n.share.token?t("Actions",{ref:"copyButton",staticClass:"sharing-entry__copy"},[t("ActionLink",{attrs:{href:n.shareLink,target:"_blank",icon:n.copied&&n.copySuccess?"icon-checkmark-color":"icon-clippy"},on:{click:function(e){return e.stopPropagation(),e.preventDefault(),n.copyLink.apply(null,arguments)}}},[n._v("\n\t\t\t"+n._s(n.clipboardTooltip)+"\n\t\t")])],1):n._e(),n._v(" "),n.pending||!n.pendingPassword&&!n.pendingExpirationDate?n.loading?t("div",{staticClass:"icon-loading-small sharing-entry__loading"}):t("Actions",{staticClass:"sharing-entry__actions",attrs:{"menu-align":"right",open:n.open},on:{"update:open":function(e){n.open=e},close:n.onMenuClose}},[n.share?[n.share.canEdit&&n.canReshare?[t("ActionInput",{directives:[{name:"tooltip",rawName:"v-tooltip.auto",value:{content:n.errors.label,show:n.errors.label,trigger:"manual",defaultContainer:".app-sidebar"},expression:"{\n\t\t\t\t\t\tcontent: errors.label,\n\t\t\t\t\t\tshow: errors.label,\n\t\t\t\t\t\ttrigger: 'manual',\n\t\t\t\t\t\tdefaultContainer: '.app-sidebar'\n\t\t\t\t\t}",modifiers:{auto:!0}}],ref:"label",class:{error:n.errors.label},attrs:{disabled:n.saving,"aria-label":n.t("files_sharing","Share label"),value:void 0!==n.share.newLabel?n.share.newLabel:n.share.label,icon:"icon-edit",maxlength:"255"},on:{"update:value":n.onLabelChange,submit:n.onLabelSubmit}},[n._v("\n\t\t\t\t\t"+n._s(n.t("files_sharing","Share label"))+"\n\t\t\t\t")]),n._v(" "),n.isFolder&&n.fileHasCreatePermission&&n.config.isPublicUploadEnabled?[t("ActionRadio",{attrs:{checked:n.sharePermissions===n.publicUploadRValue,value:n.publicUploadRValue,name:n.randomId,disabled:n.saving},on:{change:n.togglePermissions}},[n._v("\n\t\t\t\t\t\t"+n._s(n.t("files_sharing","Read only"))+"\n\t\t\t\t\t")]),n._v(" "),t("ActionRadio",{attrs:{checked:n.sharePermissions===n.publicUploadRWValue,value:n.publicUploadRWValue,disabled:n.saving,name:n.randomId},on:{change:n.togglePermissions}},[n._v("\n\t\t\t\t\t\t"+n._s(n.t("files_sharing","Allow upload and editing"))+"\n\t\t\t\t\t")]),n._v(" "),t("ActionRadio",{staticClass:"sharing-entry__action--public-upload",attrs:{checked:n.sharePermissions===n.publicUploadWValue,value:n.publicUploadWValue,disabled:n.saving,name:n.randomId},on:{change:n.togglePermissions}},[n._v("\n\t\t\t\t\t\t"+n._s(n.t("files_sharing","File drop (upload only)"))+"\n\t\t\t\t\t")])]:t("ActionCheckbox",{attrs:{checked:n.canUpdate,disabled:n.saving},on:{"update:checked":function(e){n.canUpdate=e},change:function(e){return n.queueUpdate("permissions")}}},[n._v("\n\t\t\t\t\t"+n._s(n.t("files_sharing","Allow editing"))+"\n\t\t\t\t")]),n._v(" "),t("ActionCheckbox",{attrs:{checked:n.share.hideDownload,disabled:n.saving},on:{"update:checked":function(e){return n.$set(n.share,"hideDownload",e)},change:function(e){return n.queueUpdate("hideDownload")}}},[n._v("\n\t\t\t\t\t"+n._s(n.t("files_sharing","Hide download"))+"\n\t\t\t\t")]),n._v(" "),t("ActionCheckbox",{staticClass:"share-link-password-checkbox",attrs:{checked:n.isPasswordProtected,disabled:n.config.enforcePasswordForPublicLink||n.saving},on:{"update:checked":function(e){n.isPasswordProtected=e},uncheck:n.onPasswordDisable}},[n._v("\n\t\t\t\t\t"+n._s(n.config.enforcePasswordForPublicLink?n.t("files_sharing","Password protection (enforced)"):n.t("files_sharing","Password protect"))+"\n\t\t\t\t")]),n._v(" "),n.isPasswordProtected?t("ActionInput",{directives:[{name:"tooltip",rawName:"v-tooltip.auto",value:{content:n.errors.password,show:n.errors.password,trigger:"manual",defaultContainer:"#app-sidebar"},expression:"{\n\t\t\t\t\t\tcontent: errors.password,\n\t\t\t\t\t\tshow: errors.password,\n\t\t\t\t\t\ttrigger: 'manual',\n\t\t\t\t\t\tdefaultContainer: '#app-sidebar'\n\t\t\t\t\t}",modifiers:{auto:!0}}],ref:"password",staticClass:"share-link-password",class:{error:n.errors.password},attrs:{disabled:n.saving,required:n.config.enforcePasswordForPublicLink,value:n.hasUnsavedPassword?n.share.newPassword:"***************",icon:"icon-password",autocomplete:"new-password",type:n.hasUnsavedPassword?"text":"password"},on:{"update:value":n.onPasswordChange,submit:n.onPasswordSubmit}},[n._v("\n\t\t\t\t\t"+n._s(n.t("files_sharing","Enter a password"))+"\n\t\t\t\t")]):n._e(),n._v(" "),n.isPasswordProtectedByTalkAvailable?t("ActionCheckbox",{staticClass:"share-link-password-talk-checkbox",attrs:{checked:n.isPasswordProtectedByTalk,disabled:!n.canTogglePasswordProtectedByTalkAvailable||n.saving},on:{"update:checked":function(e){n.isPasswordProtectedByTalk=e},change:n.onPasswordProtectedByTalkChange}},[n._v("\n\t\t\t\t\t"+n._s(n.t("files_sharing","Video verification"))+"\n\t\t\t\t")]):n._e(),n._v(" "),t("ActionCheckbox",{staticClass:"share-link-expire-date-checkbox",attrs:{checked:n.hasExpirationDate,disabled:n.config.isDefaultExpireDateEnforced||n.saving},on:{"update:checked":function(e){n.hasExpirationDate=e},uncheck:n.onExpirationDisable}},[n._v("\n\t\t\t\t\t"+n._s(n.config.isDefaultExpireDateEnforced?n.t("files_sharing","Expiration date (enforced)"):n.t("files_sharing","Set expiration date"))+"\n\t\t\t\t")]),n._v(" "),n.hasExpirationDate?t("ActionInput",{directives:[{name:"tooltip",rawName:"v-tooltip.auto",value:{content:n.errors.expireDate,show:n.errors.expireDate,trigger:"manual",defaultContainer:"#app-sidebar"},expression:"{\n\t\t\t\t\t\tcontent: errors.expireDate,\n\t\t\t\t\t\tshow: errors.expireDate,\n\t\t\t\t\t\ttrigger: 'manual',\n\t\t\t\t\t\tdefaultContainer: '#app-sidebar'\n\t\t\t\t\t}",modifiers:{auto:!0}}],ref:"expireDate",staticClass:"share-link-expire-date",class:{error:n.errors.expireDate},attrs:{disabled:n.saving,"first-day-of-week":n.firstDay,lang:n.lang,value:n.share.expireDate,"value-type":"format",icon:"icon-calendar-dark",type:"date","disabled-date":n.disabledDate},on:{"update:value":n.onExpirationChange}},[n._v("\n\t\t\t\t\t"+n._s(n.t("files_sharing","Enter a date"))+"\n\t\t\t\t")]):n._e(),n._v(" "),t("ActionCheckbox",{attrs:{checked:n.hasNote,disabled:n.saving},on:{"update:checked":function(e){n.hasNote=e},uncheck:function(e){return n.queueUpdate("note")}}},[n._v("\n\t\t\t\t\t"+n._s(n.t("files_sharing","Note to recipient"))+"\n\t\t\t\t")]),n._v(" "),n.hasNote?t("ActionTextEditable",{directives:[{name:"tooltip",rawName:"v-tooltip.auto",value:{content:n.errors.note,show:n.errors.note,trigger:"manual",defaultContainer:"#app-sidebar"},expression:"{\n\t\t\t\t\t\tcontent: errors.note,\n\t\t\t\t\t\tshow: errors.note,\n\t\t\t\t\t\ttrigger: 'manual',\n\t\t\t\t\t\tdefaultContainer: '#app-sidebar'\n\t\t\t\t\t}",modifiers:{auto:!0}}],ref:"note",class:{error:n.errors.note},attrs:{disabled:n.saving,placeholder:n.t("files_sharing","Enter a note for the share recipient"),value:n.share.newNote||n.share.note,icon:"icon-edit"},on:{"update:value":n.onNoteChange,submit:n.onNoteSubmit}}):n._e()]:n._e(),n._v(" "),n._l(n.externalLinkActions,(function(e){return t("ExternalShareAction",{key:e.id,attrs:{id:e.id,action:e,"file-info":n.fileInfo,share:n.share}})})),n._v(" "),n._l(n.externalLegacyLinkActions,(function(e,a){var s=e.icon,i=e.url,r=e.name;return t("ActionLink",{key:a,attrs:{href:i(n.shareLink),icon:s,target:"_blank"}},[n._v("\n\t\t\t\t"+n._s(r)+"\n\t\t\t")])})),n._v(" "),n.share.canDelete?t("ActionButton",{attrs:{icon:"icon-close",disabled:n.saving},on:{click:function(e){return e.preventDefault(),n.onDelete.apply(null,arguments)}}},[n._v("\n\t\t\t\t"+n._s(n.t("files_sharing","Unshare"))+"\n\t\t\t")]):n._e(),n._v(" "),!n.isEmailShareType&&n.canReshare?t("ActionButton",{staticClass:"new-share-link",attrs:{icon:"icon-add"},on:{click:function(e){return e.preventDefault(),e.stopPropagation(),n.onNewLinkShare.apply(null,arguments)}}},[n._v("\n\t\t\t\t"+n._s(n.t("files_sharing","Add another link"))+"\n\t\t\t")]):n._e()]:n.canReshare?t("ActionButton",{staticClass:"new-share-link",attrs:{icon:n.loading?"icon-loading-small":"icon-add"},on:{click:function(e){return e.preventDefault(),e.stopPropagation(),n.onNewLinkShare.apply(null,arguments)}}},[n._v("\n\t\t\t"+n._s(n.t("files_sharing","Create a new share link"))+"\n\t\t")]):n._e()],2):t("Actions",{staticClass:"sharing-entry__actions",attrs:{"menu-align":"right",open:n.open},on:{"update:open":function(e){n.open=e},close:n.onNewLinkShare}},[n.errors.pending?t("ActionText",{class:{error:n.errors.pending},attrs:{icon:"icon-error"}},[n._v("\n\t\t\t"+n._s(n.errors.pending)+"\n\t\t")]):t("ActionText",{attrs:{icon:"icon-info"}},[n._v("\n\t\t\t"+n._s(n.t("files_sharing","Please enter the following required information before creating the share"))+"\n\t\t")]),n._v(" "),n.pendingPassword?t("ActionText",{attrs:{icon:"icon-password"}},[n._v("\n\t\t\t"+n._s(n.t("files_sharing","Password protection (enforced)"))+"\n\t\t")]):n.config.enableLinkPasswordByDefault?t("ActionCheckbox",{staticClass:"share-link-password-checkbox",attrs:{checked:n.isPasswordProtected,disabled:n.config.enforcePasswordForPublicLink||n.saving},on:{"update:checked":function(e){n.isPasswordProtected=e},uncheck:n.onPasswordDisable}},[n._v("\n\t\t\t"+n._s(n.t("files_sharing","Password protection"))+"\n\t\t")]):n._e(),n._v(" "),n.pendingPassword||n.share.password?t("ActionInput",{directives:[{name:"tooltip",rawName:"v-tooltip.auto",value:{content:n.errors.password,show:n.errors.password,trigger:"manual",defaultContainer:"#app-sidebar"},expression:"{\n\t\t\t\tcontent: errors.password,\n\t\t\t\tshow: errors.password,\n\t\t\t\ttrigger: 'manual',\n\t\t\t\tdefaultContainer: '#app-sidebar'\n\t\t\t}",modifiers:{auto:!0}}],staticClass:"share-link-password",attrs:{value:n.share.password,disabled:n.saving,required:n.config.enableLinkPasswordByDefault||n.config.enforcePasswordForPublicLink,minlength:n.isPasswordPolicyEnabled&&n.config.passwordPolicy.minLength,icon:"",autocomplete:"new-password"},on:{"update:value":function(e){return n.$set(n.share,"password",e)},submit:n.onNewLinkShare}},[n._v("\n\t\t\t"+n._s(n.t("files_sharing","Enter a password"))+"\n\t\t")]):n._e(),n._v(" "),n.pendingExpirationDate?t("ActionText",{attrs:{icon:"icon-calendar-dark"}},[n._v("\n\t\t\t"+n._s(n.t("files_sharing","Expiration date (enforced)"))+"\n\t\t")]):n._e(),n._v(" "),n.pendingExpirationDate?t("ActionInput",{directives:[{name:"tooltip",rawName:"v-tooltip.auto",value:{content:n.errors.expireDate,show:n.errors.expireDate,trigger:"manual",defaultContainer:"#app-sidebar"},expression:"{\n\t\t\t\tcontent: errors.expireDate,\n\t\t\t\tshow: errors.expireDate,\n\t\t\t\ttrigger: 'manual',\n\t\t\t\tdefaultContainer: '#app-sidebar'\n\t\t\t}",modifiers:{auto:!0}}],staticClass:"share-link-expire-date",attrs:{disabled:n.saving,"first-day-of-week":n.firstDay,lang:n.lang,icon:"",type:"date","value-type":"format","disabled-date":n.disabledDate},model:{value:n.share.expireDate,callback:function(e){n.$set(n.share,"expireDate",e)},expression:"share.expireDate"}},[n._v("\n\t\t\t"+n._s(n.t("files_sharing","Enter a date"))+"\n\t\t")]):n._e(),n._v(" "),t("ActionButton",{attrs:{icon:"icon-checkmark"},on:{click:function(e){return e.preventDefault(),e.stopPropagation(),n.onNewLinkShare.apply(null,arguments)}}},[n._v("\n\t\t\t"+n._s(n.t("files_sharing","Create share"))+"\n\t\t")]),n._v(" "),t("ActionButton",{attrs:{icon:"icon-close"},on:{click:function(e){return e.preventDefault(),e.stopPropagation(),n.onCancel.apply(null,arguments)}}},[n._v("\n\t\t\t"+n._s(n.t("files_sharing","Cancel"))+"\n\t\t")])],1)],1)}),[],!1,null,"4d499362",null).exports},mixins:[f],props:{fileInfo:{type:Object,default:()=>{},required:!0},shares:{type:Array,default:()=>[],required:!0},canReshare:{type:Boolean,required:!0}},data:()=>({canLinkShare:OC.getCapabilities().files_sharing.public.enabled}),computed:{hasLinkShares(){return this.shares.filter((n=>n.type===this.SHARE_TYPES.SHARE_TYPE_LINK)).length>0},hasShares(){return this.shares.length>0}},methods:{addShare(n,e){this.shares.unshift(n),this.awaitForShare(n,e)},awaitForShare(n,e){this.$nextTick((()=>{const t=this.$children.find((e=>e.share===n));t&&e(t)}))},removeShare(n){const e=this.shares.findIndex((e=>e===n));this.shares.splice(e,1)}}},mn=(0,P.Z)(An,(function(){var n=this,e=n.$createElement,t=n._self._c||e;return n.canLinkShare?t("ul",{staticClass:"sharing-link-list"},[!n.hasLinkShares&&n.canReshare?t("SharingEntryLink",{attrs:{"can-reshare":n.canReshare,"file-info":n.fileInfo},on:{"add:share":n.addShare}}):n._e(),n._v(" "),n.hasShares?n._l(n.shares,(function(e,a){return t("SharingEntryLink",{key:e.id,attrs:{"can-reshare":n.canReshare,share:n.shares[a],"file-info":n.fileInfo},on:{"update:share":[function(e){return n.$set(n.shares,a,e)},function(e){return n.awaitForShare.apply(void 0,arguments)}],"add:share":function(e){return n.addShare.apply(void 0,arguments)},"remove:share":n.removeShare}})})):n._e()],2):n._e()}),[],!1,null,null,null).exports,En={name:"SharingEntry",components:{Actions:E(),ActionButton:G(),ActionCheckbox:rn(),ActionInput:hn(),ActionTextEditable:pn(),Avatar:d()},directives:{Tooltip:y()},mixins:[z],data:()=>({permissionsEdit:OC.PERMISSION_UPDATE,permissionsCreate:OC.PERMISSION_CREATE,permissionsDelete:OC.PERMISSION_DELETE,permissionsRead:OC.PERMISSION_READ,permissionsShare:OC.PERMISSION_SHARE}),computed:{title(){let n=this.share.shareWithDisplayName;return this.share.type===this.SHARE_TYPES.SHARE_TYPE_GROUP?n+=" (".concat(t("files_sharing","group"),")"):this.share.type===this.SHARE_TYPES.SHARE_TYPE_ROOM?n+=" (".concat(t("files_sharing","conversation"),")"):this.share.type===this.SHARE_TYPES.SHARE_TYPE_REMOTE?n+=" (".concat(t("files_sharing","remote"),")"):this.share.type===this.SHARE_TYPES.SHARE_TYPE_REMOTE_GROUP?n+=" (".concat(t("files_sharing","remote group"),")"):this.share.type===this.SHARE_TYPES.SHARE_TYPE_GUEST&&(n+=" (".concat(t("files_sharing","guest"),")")),n},tooltip(){if(this.share.owner!==this.share.uidFileOwner){const n={user:this.share.shareWithDisplayName,owner:this.share.ownerDisplayName};return this.share.type===this.SHARE_TYPES.SHARE_TYPE_GROUP?t("files_sharing","Shared with the group {user} by {owner}",n):this.share.type===this.SHARE_TYPES.SHARE_TYPE_ROOM?t("files_sharing","Shared with the conversation {user} by {owner}",n):t("files_sharing","Shared with {user} by {owner}",n)}return null},canHaveNote(){return!this.isRemote},isRemote(){return this.share.type===this.SHARE_TYPES.SHARE_TYPE_REMOTE||this.share.type===this.SHARE_TYPES.SHARE_TYPE_REMOTE_GROUP},canSetEdit(){return this.fileInfo.sharePermissions&OC.PERMISSION_UPDATE||this.canEdit},canSetCreate(){return this.fileInfo.sharePermissions&OC.PERMISSION_CREATE||this.canCreate},canSetDelete(){return this.fileInfo.sharePermissions&OC.PERMISSION_DELETE||this.canDelete},canSetReshare(){return this.fileInfo.sharePermissions&OC.PERMISSION_SHARE||this.canReshare},canEdit:{get(){return this.share.hasUpdatePermission},set(n){this.updatePermissions({isEditChecked:n})}},canCreate:{get(){return this.share.hasCreatePermission},set(n){this.updatePermissions({isCreateChecked:n})}},canDelete:{get(){return this.share.hasDeletePermission},set(n){this.updatePermissions({isDeleteChecked:n})}},canReshare:{get(){return this.share.hasSharePermission},set(n){this.updatePermissions({isReshareChecked:n})}},hasRead:{get(){return this.share.hasReadPermission}},isFolder(){return"dir"===this.fileInfo.type},hasExpirationDate:{get(){return this.config.isDefaultInternalExpireDateEnforced||!!this.share.expireDate},set(n){this.share.expireDate=n?""!==this.config.defaultInternalExpirationDateString?this.config.defaultInternalExpirationDateString:moment().format("YYYY-MM-DD"):""}},dateMaxEnforced(){return this.isRemote?this.config.isDefaultRemoteExpireDateEnforced&&moment().add(1+this.config.defaultRemoteExpireDate,"days"):this.config.isDefaultInternalExpireDateEnforced&&moment().add(1+this.config.defaultInternalExpireDate,"days")},hasStatus(){return this.share.type===this.SHARE_TYPES.SHARE_TYPE_USER&&"object"==typeof this.share.status&&!Array.isArray(this.share.status)}},methods:{updatePermissions(){let{isEditChecked:n=this.canEdit,isCreateChecked:e=this.canCreate,isDeleteChecked:t=this.canDelete,isReshareChecked:a=this.canReshare}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const s=0|(this.hasRead?this.permissionsRead:0)|(e?this.permissionsCreate:0)|(t?this.permissionsDelete:0)|(n?this.permissionsEdit:0)|(a?this.permissionsShare:0);this.share.permissions=s,this.queueUpdate("permissions")},onMenuClose(){this.onNoteSubmit()}}};var Sn=a(54490);C()(Sn.Z,{insert:"head",singleton:!1}),Sn.Z.locals;const yn={name:"SharingList",components:{SharingEntry:(0,P.Z)(En,(function(){var n=this,e=n.$createElement,t=n._self._c||e;return t("li",{staticClass:"sharing-entry"},[t("Avatar",{staticClass:"sharing-entry__avatar",attrs:{"is-no-user":n.share.type!==n.SHARE_TYPES.SHARE_TYPE_USER,user:n.share.shareWith,"display-name":n.share.shareWithDisplayName,"tooltip-message":n.share.type===n.SHARE_TYPES.SHARE_TYPE_USER?n.share.shareWith:"","menu-position":"left",url:n.share.shareWithAvatar}}),n._v(" "),t(n.share.shareWithLink?"a":"div",{directives:[{name:"tooltip",rawName:"v-tooltip.auto",value:n.tooltip,expression:"tooltip",modifiers:{auto:!0}}],tag:"component",staticClass:"sharing-entry__desc",attrs:{href:n.share.shareWithLink}},[t("h5",[n._v(n._s(n.title)),n.isUnique?n._e():t("span",{staticClass:"sharing-entry__desc-unique"},[n._v(" ("+n._s(n.share.shareWithDisplayNameUnique)+")")])]),n._v(" "),n.hasStatus?t("p",[t("span",[n._v(n._s(n.share.status.icon||""))]),n._v(" "),t("span",[n._v(n._s(n.share.status.message||""))])]):n._e()]),n._v(" "),t("Actions",{staticClass:"sharing-entry__actions",attrs:{"menu-align":"right"},on:{close:n.onMenuClose}},[n.share.canEdit?[t("ActionCheckbox",{ref:"canEdit",attrs:{checked:n.canEdit,value:n.permissionsEdit,disabled:n.saving||!n.canSetEdit},on:{"update:checked":function(e){n.canEdit=e}}},[n._v("\n\t\t\t\t"+n._s(n.t("files_sharing","Allow editing"))+"\n\t\t\t")]),n._v(" "),n.isFolder?t("ActionCheckbox",{ref:"canCreate",attrs:{checked:n.canCreate,value:n.permissionsCreate,disabled:n.saving||!n.canSetCreate},on:{"update:checked":function(e){n.canCreate=e}}},[n._v("\n\t\t\t\t"+n._s(n.t("files_sharing","Allow creating"))+"\n\t\t\t")]):n._e(),n._v(" "),n.isFolder?t("ActionCheckbox",{ref:"canDelete",attrs:{checked:n.canDelete,value:n.permissionsDelete,disabled:n.saving||!n.canSetDelete},on:{"update:checked":function(e){n.canDelete=e}}},[n._v("\n\t\t\t\t"+n._s(n.t("files_sharing","Allow deleting"))+"\n\t\t\t")]):n._e(),n._v(" "),n.config.isResharingAllowed?t("ActionCheckbox",{ref:"canReshare",attrs:{checked:n.canReshare,value:n.permissionsShare,disabled:n.saving||!n.canSetReshare},on:{"update:checked":function(e){n.canReshare=e}}},[n._v("\n\t\t\t\t"+n._s(n.t("files_sharing","Allow resharing"))+"\n\t\t\t")]):n._e(),n._v(" "),t("ActionCheckbox",{attrs:{checked:n.hasExpirationDate,disabled:n.config.isDefaultInternalExpireDateEnforced||n.saving},on:{"update:checked":function(e){n.hasExpirationDate=e},uncheck:n.onExpirationDisable}},[n._v("\n\t\t\t\t"+n._s(n.config.isDefaultInternalExpireDateEnforced?n.t("files_sharing","Expiration date enforced"):n.t("files_sharing","Set expiration date"))+"\n\t\t\t")]),n._v(" "),n.hasExpirationDate?t("ActionInput",{directives:[{name:"tooltip",rawName:"v-tooltip.auto",value:{content:n.errors.expireDate,show:n.errors.expireDate,trigger:"manual"},expression:"{\n\t\t\t\t\tcontent: errors.expireDate,\n\t\t\t\t\tshow: errors.expireDate,\n\t\t\t\t\ttrigger: 'manual'\n\t\t\t\t}",modifiers:{auto:!0}}],ref:"expireDate",class:{error:n.errors.expireDate},attrs:{disabled:n.saving,"first-day-of-week":n.firstDay,lang:n.lang,value:n.share.expireDate,"value-type":"format",icon:"icon-calendar-dark",type:"date","disabled-date":n.disabledDate},on:{"update:value":n.onExpirationChange}},[n._v("\n\t\t\t\t"+n._s(n.t("files_sharing","Enter a date"))+"\n\t\t\t")]):n._e(),n._v(" "),n.canHaveNote?[t("ActionCheckbox",{attrs:{checked:n.hasNote,disabled:n.saving},on:{"update:checked":function(e){n.hasNote=e},uncheck:function(e){return n.queueUpdate("note")}}},[n._v("\n\t\t\t\t\t"+n._s(n.t("files_sharing","Note to recipient"))+"\n\t\t\t\t")]),n._v(" "),n.hasNote?t("ActionTextEditable",{directives:[{name:"tooltip",rawName:"v-tooltip.auto",value:{content:n.errors.note,show:n.errors.note,trigger:"manual"},expression:"{\n\t\t\t\t\t\tcontent: errors.note,\n\t\t\t\t\t\tshow: errors.note,\n\t\t\t\t\t\ttrigger: 'manual'\n\t\t\t\t\t}",modifiers:{auto:!0}}],ref:"note",class:{error:n.errors.note},attrs:{disabled:n.saving,value:n.share.newNote||n.share.note,icon:"icon-edit"},on:{"update:value":n.onNoteChange,submit:n.onNoteSubmit}}):n._e()]:n._e()]:n._e(),n._v(" "),n.share.canDelete?t("ActionButton",{attrs:{icon:"icon-close",disabled:n.saving},on:{click:function(e){return e.preventDefault(),n.onDelete.apply(null,arguments)}}},[n._v("\n\t\t\t"+n._s(n.t("files_sharing","Unshare"))+"\n\t\t")]):n._e()],2)],1)}),[],!1,null,"77e841d0",null).exports},mixins:[f],props:{fileInfo:{type:Object,default:()=>{},required:!0},shares:{type:Array,default:()=>[],required:!0}},computed:{hasShares(){return 0===this.shares.length},isUnique(){return n=>[...this.shares].filter((e=>n.type===this.SHARE_TYPES.SHARE_TYPE_USER&&n.shareWithDisplayName===e.shareWithDisplayName)).length<=1}},methods:{removeShare(n){const e=this.shares.findIndex((e=>e===n));this.shares.splice(e,1)}}},vn=(0,P.Z)(yn,(function(){var n=this,e=n.$createElement,t=n._self._c||e;return t("ul",{staticClass:"sharing-sharee-list"},n._l(n.shares,(function(e){return t("SharingEntry",{key:e.id,attrs:{"file-info":n.fileInfo,share:e,"is-unique":n.isUnique(e)},on:{"remove:share":n.removeShare}})})),1)}),[],!1,null,null,null).exports,wn={name:"SharingTab",components:{Avatar:d(),CollectionList:h.G,SharingEntryInternal:T,SharingEntrySimple:x,SharingInherited:an,SharingInput:F,SharingLinkList:mn,SharingList:vn},mixins:[f],data:()=>({config:new u,error:"",expirationInterval:null,loading:!0,fileInfo:null,reshare:null,sharedWithMe:{},shares:[],linkShares:[],sections:OCA.Sharing.ShareTabSections.getSections()}),computed:{isSharedWithMe(){return Object.keys(this.sharedWithMe).length>0},canReshare(){return!!(this.fileInfo.permissions&OC.PERMISSION_SHARE)||!!(this.reshare&&this.reshare.hasSharePermission&&this.config.isResharingAllowed)}},methods:{async update(n){this.fileInfo=n,this.resetState(),this.getShares()},async getShares(){try{this.loading=!0;const n=(0,l.generateOcsUrl)("apps/files_sharing/api/v1/shares"),e="json",t=(this.fileInfo.path+"/"+this.fileInfo.name).replace("//","/"),a=p.default.get(n,{params:{format:e,path:t,reshares:!0}}),s=p.default.get(n,{params:{format:e,path:t,shared_with_me:!0}}),[i,r]=await Promise.all([a,s]);this.loading=!1,this.processSharedWithMe(r),this.processShares(i)}catch(n){this.error=t("files_sharing","Unable to load the shares list"),this.loading=!1,console.error("Error loading the shares list",n)}},resetState(){clearInterval(this.expirationInterval),this.loading=!0,this.error="",this.sharedWithMe={},this.shares=[],this.linkShares=[]},updateExpirationSubtitle(n){const e=moment(n.expireDate).unix();this.$set(this.sharedWithMe,"subtitle",t("files_sharing","Expires {relativetime}",{relativetime:OC.Util.relativeModifiedDate(1e3*e)})),moment().unix()>e&&(clearInterval(this.expirationInterval),this.$set(this.sharedWithMe,"subtitle",t("files_sharing","this share just expired.")))},processShares(n){let{data:e}=n;if(e.ocs&&e.ocs.data&&e.ocs.data.length>0){const n=e.ocs.data.map((n=>new g(n))).sort(((n,e)=>e.createdTime-n.createdTime));this.linkShares=n.filter((n=>n.type===this.SHARE_TYPES.SHARE_TYPE_LINK||n.type===this.SHARE_TYPES.SHARE_TYPE_EMAIL)),this.shares=n.filter((n=>n.type!==this.SHARE_TYPES.SHARE_TYPE_LINK&&n.type!==this.SHARE_TYPES.SHARE_TYPE_EMAIL)),console.debug("Processed",this.linkShares.length,"link share(s)"),console.debug("Processed",this.shares.length,"share(s)")}},processSharedWithMe(n){let{data:e}=n;if(e.ocs&&e.ocs.data&&e.ocs.data[0]){const n=new g(e),a=function(n){return n.type===OC.Share.SHARE_TYPE_GROUP?t("files_sharing","Shared with you and the group {group} by {owner}",{group:n.shareWithDisplayName,owner:n.ownerDisplayName},void 0,{escape:!1}):n.type===OC.Share.SHARE_TYPE_CIRCLE?t("files_sharing","Shared with you and {circle} by {owner}",{circle:n.shareWithDisplayName,owner:n.ownerDisplayName},void 0,{escape:!1}):n.type===OC.Share.SHARE_TYPE_ROOM?n.shareWithDisplayName?t("files_sharing","Shared with you and the conversation {conversation} by {owner}",{conversation:n.shareWithDisplayName,owner:n.ownerDisplayName},void 0,{escape:!1}):t("files_sharing","Shared with you in a conversation by {owner}",{owner:n.ownerDisplayName},void 0,{escape:!1}):t("files_sharing","Shared with you by {owner}",{owner:n.ownerDisplayName},void 0,{escape:!1})}(n),s=n.ownerDisplayName,i=n.owner;this.sharedWithMe={displayName:s,title:a,user:i},this.reshare=n,n.expireDate&&moment(n.expireDate).unix()>moment().unix()&&(this.updateExpirationSubtitle(n),this.expirationInterval=setInterval(this.updateExpirationSubtitle,1e4,n))}},addShare(n){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:()=>{};n.type===this.SHARE_TYPES.SHARE_TYPE_EMAIL?this.linkShares.unshift(n):this.shares.unshift(n),this.awaitForShare(n,e)},awaitForShare(n,e){let t=this.$refs.shareList;n.type===this.SHARE_TYPES.SHARE_TYPE_EMAIL&&(t=this.$refs.linkShareList),this.$nextTick((()=>{const a=t.$children.find((e=>e.share===n));a&&e(a)}))}}},Cn=wn,bn=(0,P.Z)(Cn,(function(){var n=this,e=n.$createElement,t=n._self._c||e;return t("div",{class:{"icon-loading":n.loading}},[n.error?t("div",{staticClass:"emptycontent"},[t("div",{staticClass:"icon icon-error"}),n._v(" "),t("h2",[n._v(n._s(n.error))])]):[n.isSharedWithMe?t("SharingEntrySimple",n._b({staticClass:"sharing-entry__reshare",scopedSlots:n._u([{key:"avatar",fn:function(){return[t("Avatar",{staticClass:"sharing-entry__avatar",attrs:{user:n.sharedWithMe.user,"display-name":n.sharedWithMe.displayName,"tooltip-message":""}})]},proxy:!0}],null,!1,1643724538)},"SharingEntrySimple",n.sharedWithMe,!1)):n._e(),n._v(" "),n.loading?n._e():t("SharingInput",{attrs:{"can-reshare":n.canReshare,"file-info":n.fileInfo,"link-shares":n.linkShares,reshare:n.reshare,shares:n.shares},on:{"add:share":n.addShare}}),n._v(" "),n.loading?n._e():t("SharingLinkList",{ref:"linkShareList",attrs:{"can-reshare":n.canReshare,"file-info":n.fileInfo,shares:n.linkShares}}),n._v(" "),n.loading?n._e():t("SharingList",{ref:"shareList",attrs:{shares:n.shares,"file-info":n.fileInfo}}),n._v(" "),n.canReshare&&!n.loading?t("SharingInherited",{attrs:{"file-info":n.fileInfo}}):n._e(),n._v(" "),t("SharingEntryInternal",{attrs:{"file-info":n.fileInfo}}),n._v(" "),n.fileInfo?t("CollectionList",{attrs:{id:""+n.fileInfo.id,type:"file",name:n.fileInfo.name}}):n._e(),n._v(" "),n._l(n.sections,(function(e,a){return t("div",{key:a,ref:"section-"+a,refInFor:!0,staticClass:"sharingTab__additionalContent"},[t(e(n.$refs["section-"+a],n.fileInfo),{tag:"component",attrs:{"file-info":n.fileInfo}})],1)}))]],2)}),[],!1,null,null,null).exports;window.OCA.Sharing||(window.OCA.Sharing={}),Object.assign(window.OCA.Sharing,{ShareSearch:new class{constructor(){var n,e;e=void 0,(n="_state")in this?Object.defineProperty(this,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):this[n]=e,this._state={},this._state.results=[],console.debug("OCA.Sharing.ShareSearch initialized")}get state(){return this._state}addNewResult(n){return""!==n.displayName.trim()&&"function"==typeof n.handler?(this._state.results.push(n),!0):(console.error("Invalid search result provided",n),!1)}}}),Object.assign(window.OCA.Sharing,{ExternalLinkActions:new class{constructor(){var n,e;e=void 0,(n="_state")in this?Object.defineProperty(this,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):this[n]=e,this._state={},this._state.actions=[],console.debug("OCA.Sharing.ExternalLinkActions initialized")}get state(){return this._state}registerAction(n){return console.warn("OCA.Sharing.ExternalLinkActions is deprecated, use OCA.Sharing.ExternalShareAction instead"),"object"==typeof n&&n.icon&&n.name&&n.url?(this._state.actions.push(n),!0):(console.error("Invalid action provided",n),!1)}}}),Object.assign(window.OCA.Sharing,{ExternalShareActions:new class{constructor(){var n,e;e=void 0,(n="_state")in this?Object.defineProperty(this,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):this[n]=e,this._state={},this._state.actions=[],console.debug("OCA.Sharing.ExternalShareActions initialized")}get state(){return this._state}registerAction(n){return"object"==typeof n&&"string"==typeof n.id&&"function"==typeof n.data&&Array.isArray(n.shareType)&&"object"==typeof n.handlers&&Object.values(n.handlers).every((n=>"function"==typeof n))?this._state.actions.findIndex((e=>e.id===n.id))>-1?(console.error("An action with the same id ".concat(n.id," already exists"),n),!1):(this._state.actions.push(n),!0):(console.error("Invalid action provided",n),!1)}}}),Object.assign(window.OCA.Sharing,{ShareTabSections:new class{constructor(){var n,e;e=void 0,(n="_sections")in this?Object.defineProperty(this,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):this[n]=e,this._sections=[]}registerSection(n){this._sections.push(n)}getSections(){return this._sections}}}),s.default.prototype.t=o.translate,s.default.prototype.n=o.translatePlural,s.default.use(r());const Pn=s.default.extend(bn);let xn=null;window.addEventListener("DOMContentLoaded",(function(){OCA.Files&&OCA.Files.Sidebar&&OCA.Files.Sidebar.registerTab(new OCA.Files.Sidebar.Tab({id:"sharing",name:(0,o.translate)("files_sharing","Sharing"),icon:"icon-share",async mount(n,e,t){xn&&xn.$destroy(),xn=new Pn({parent:t}),await xn.update(e),xn.$mount(n)},update(n){xn.update(n)},destroy(){xn.$destroy(),xn=null}}))}))},54490:(n,e,t)=>{t.d(e,{Z:()=>o});var a=t(94015),s=t.n(a),i=t(23645),r=t.n(i)()(s());r.push([n.id,".sharing-entry[data-v-77e841d0]{display:flex;align-items:center;height:44px}.sharing-entry__desc[data-v-77e841d0]{display:flex;flex-direction:column;justify-content:space-between;padding:8px;line-height:1.2em}.sharing-entry__desc p[data-v-77e841d0]{color:var(--color-text-maxcontrast)}.sharing-entry__desc-unique[data-v-77e841d0]{color:var(--color-text-maxcontrast)}.sharing-entry__actions[data-v-77e841d0]{margin-left:auto}","",{version:3,sources:["webpack://./apps/files_sharing/src/components/SharingEntry.vue"],names:[],mappings:"AA6ZA,gCACC,YAAA,CACA,kBAAA,CACA,WAAA,CACA,sCACC,YAAA,CACA,qBAAA,CACA,6BAAA,CACA,WAAA,CACA,iBAAA,CACA,wCACC,mCAAA,CAED,6CACC,mCAAA,CAGF,yCACC,gBAAA",sourcesContent:["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n.sharing-entry {\n\tdisplay: flex;\n\talign-items: center;\n\theight: 44px;\n\t&__desc {\n\t\tdisplay: flex;\n\t\tflex-direction: column;\n\t\tjustify-content: space-between;\n\t\tpadding: 8px;\n\t\tline-height: 1.2em;\n\t\tp {\n\t\t\tcolor: var(--color-text-maxcontrast);\n\t\t}\n\t\t&-unique {\n\t\t\tcolor: var(--color-text-maxcontrast);\n\t\t}\n\t}\n\t&__actions {\n\t\tmargin-left: auto;\n\t}\n}\n"],sourceRoot:""}]);const o=r},61923:(n,e,t)=>{t.d(e,{Z:()=>o});var a=t(94015),s=t.n(a),i=t(23645),r=t.n(i)()(s());r.push([n.id,".sharing-entry[data-v-c58e421a]{display:flex;align-items:center;height:44px}.sharing-entry__desc[data-v-c58e421a]{display:flex;flex-direction:column;justify-content:space-between;padding:8px;line-height:1.2em}.sharing-entry__desc p[data-v-c58e421a]{color:var(--color-text-maxcontrast)}.sharing-entry__actions[data-v-c58e421a]{margin-left:auto}","",{version:3,sources:["webpack://./apps/files_sharing/src/components/SharingEntryInherited.vue"],names:[],mappings:"AAkGA,gCACC,YAAA,CACA,kBAAA,CACA,WAAA,CACA,sCACC,YAAA,CACA,qBAAA,CACA,6BAAA,CACA,WAAA,CACA,iBAAA,CACA,wCACC,mCAAA,CAGF,yCACC,gBAAA",sourcesContent:["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n.sharing-entry {\n\tdisplay: flex;\n\talign-items: center;\n\theight: 44px;\n\t&__desc {\n\t\tdisplay: flex;\n\t\tflex-direction: column;\n\t\tjustify-content: space-between;\n\t\tpadding: 8px;\n\t\tline-height: 1.2em;\n\t\tp {\n\t\t\tcolor: var(--color-text-maxcontrast);\n\t\t}\n\t}\n\t&__actions {\n\t\tmargin-left: auto;\n\t}\n}\n"],sourceRoot:""}]);const o=r},26554:(n,e,t)=>{t.d(e,{Z:()=>o});var a=t(94015),s=t.n(a),i=t(23645),r=t.n(i)()(s());r.push([n.id,".sharing-entry__internal .avatar-external[data-v-456815d3]{width:32px;height:32px;line-height:32px;font-size:18px;background-color:var(--color-text-maxcontrast);border-radius:50%;flex-shrink:0}.sharing-entry__internal .icon-checkmark-color[data-v-456815d3]{opacity:1}","",{version:3,sources:["webpack://./apps/files_sharing/src/components/SharingEntryInternal.vue"],names:[],mappings:"AAyGC,2DACC,UAAA,CACA,WAAA,CACA,gBAAA,CACA,cAAA,CACA,8CAAA,CACA,iBAAA,CACA,aAAA,CAED,gEACC,SAAA",sourcesContent:["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n.sharing-entry__internal {\n\t.avatar-external {\n\t\twidth: 32px;\n\t\theight: 32px;\n\t\tline-height: 32px;\n\t\tfont-size: 18px;\n\t\tbackground-color: var(--color-text-maxcontrast);\n\t\tborder-radius: 50%;\n\t\tflex-shrink: 0;\n\t}\n\t.icon-checkmark-color {\n\t\topacity: 1;\n\t}\n}\n"],sourceRoot:""}]);const o=r},76167:(n,e,t)=>{t.d(e,{Z:()=>o});var a=t(94015),s=t.n(a),i=t(23645),r=t.n(i)()(s());r.push([n.id,".sharing-entry[data-v-4d499362]{display:flex;align-items:center;min-height:44px}.sharing-entry__desc[data-v-4d499362]{display:flex;flex-direction:column;justify-content:space-between;padding:8px;line-height:1.2em;overflow:hidden}.sharing-entry__desc h5[data-v-4d499362]{text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.sharing-entry__desc p[data-v-4d499362]{color:var(--color-text-maxcontrast)}.sharing-entry:not(.sharing-entry--share) .sharing-entry__actions .new-share-link[data-v-4d499362]{border-top:1px solid var(--color-border)}.sharing-entry[data-v-4d499362] .avatar-link-share{background-color:var(--color-primary)}.sharing-entry .sharing-entry__action--public-upload[data-v-4d499362]{border-bottom:1px solid var(--color-border)}.sharing-entry__loading[data-v-4d499362]{width:44px;height:44px;margin:0;padding:14px;margin-left:auto}.sharing-entry .action-item[data-v-4d499362]{margin-left:auto}.sharing-entry .action-item~.action-item[data-v-4d499362],.sharing-entry .action-item~.sharing-entry__loading[data-v-4d499362]{margin-left:0}.sharing-entry .icon-checkmark-color[data-v-4d499362]{opacity:1}","",{version:3,sources:["webpack://./apps/files_sharing/src/components/SharingEntryLink.vue"],names:[],mappings:"AAs7BA,gCACC,YAAA,CACA,kBAAA,CACA,eAAA,CACA,sCACC,YAAA,CACA,qBAAA,CACA,6BAAA,CACA,WAAA,CACA,iBAAA,CACA,eAAA,CAEA,yCACC,sBAAA,CACA,eAAA,CACA,kBAAA,CAED,wCACC,mCAAA,CAKD,mGACC,wCAAA,CAIF,oDACC,qCAAA,CAGD,sEACC,2CAAA,CAGD,yCACC,UAAA,CACA,WAAA,CACA,QAAA,CACA,YAAA,CACA,gBAAA,CAKD,6CACC,gBAAA,CACA,+HAEC,aAAA,CAIF,sDACC,SAAA",sourcesContent:["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n.sharing-entry {\n\tdisplay: flex;\n\talign-items: center;\n\tmin-height: 44px;\n\t&__desc {\n\t\tdisplay: flex;\n\t\tflex-direction: column;\n\t\tjustify-content: space-between;\n\t\tpadding: 8px;\n\t\tline-height: 1.2em;\n\t\toverflow: hidden;\n\n\t\th5 {\n\t\t\ttext-overflow: ellipsis;\n\t\t\toverflow: hidden;\n\t\t\twhite-space: nowrap;\n\t\t}\n\t\tp {\n\t\t\tcolor: var(--color-text-maxcontrast);\n\t\t}\n\t}\n\n\t&:not(.sharing-entry--share) &__actions {\n\t\t.new-share-link {\n\t\t\tborder-top: 1px solid var(--color-border);\n\t\t}\n\t}\n\n\t::v-deep .avatar-link-share {\n\t\tbackground-color: var(--color-primary);\n\t}\n\n\t.sharing-entry__action--public-upload {\n\t\tborder-bottom: 1px solid var(--color-border);\n\t}\n\n\t&__loading {\n\t\twidth: 44px;\n\t\theight: 44px;\n\t\tmargin: 0;\n\t\tpadding: 14px;\n\t\tmargin-left: auto;\n\t}\n\n\t// put menus to the left\n\t// but only the first one\n\t.action-item {\n\t\tmargin-left: auto;\n\t\t~ .action-item,\n\t\t~ .sharing-entry__loading {\n\t\t\tmargin-left: 0;\n\t\t}\n\t}\n\n\t.icon-checkmark-color {\n\t\topacity: 1;\n\t}\n}\n"],sourceRoot:""}]);const o=r},35917:(n,e,t)=>{t.d(e,{Z:()=>o});var a=t(94015),s=t.n(a),i=t(23645),r=t.n(i)()(s());r.push([n.id,".sharing-entry[data-v-1436bf4a]{display:flex;align-items:center;min-height:44px}.sharing-entry__desc[data-v-1436bf4a]{padding:8px;line-height:1.2em;position:relative;flex:1 1;min-width:0}.sharing-entry__desc h5[data-v-1436bf4a]{white-space:nowrap;text-overflow:ellipsis;overflow:hidden;max-width:inherit}.sharing-entry__desc p[data-v-1436bf4a]{color:var(--color-text-maxcontrast)}.sharing-entry__actions[data-v-1436bf4a]{margin-left:auto !important}","",{version:3,sources:["webpack://./apps/files_sharing/src/components/SharingEntrySimple.vue"],names:[],mappings:"AA4EA,gCACC,YAAA,CACA,kBAAA,CACA,eAAA,CACA,sCACC,WAAA,CACA,iBAAA,CACA,iBAAA,CACA,QAAA,CACA,WAAA,CACA,yCACC,kBAAA,CACA,sBAAA,CACA,eAAA,CACA,iBAAA,CAED,wCACC,mCAAA,CAGF,yCACC,2BAAA",sourcesContent:["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n.sharing-entry {\n\tdisplay: flex;\n\talign-items: center;\n\tmin-height: 44px;\n\t&__desc {\n\t\tpadding: 8px;\n\t\tline-height: 1.2em;\n\t\tposition: relative;\n\t\tflex: 1 1;\n\t\tmin-width: 0;\n\t\th5 {\n\t\t\twhite-space: nowrap;\n\t\t\ttext-overflow: ellipsis;\n\t\t\toverflow: hidden;\n\t\t\tmax-width: inherit;\n\t\t}\n\t\tp {\n\t\t\tcolor: var(--color-text-maxcontrast);\n\t\t}\n\t}\n\t&__actions {\n\t\tmargin-left: auto !important;\n\t}\n}\n"],sourceRoot:""}]);const o=r},84721:(n,e,t)=>{t.d(e,{Z:()=>o});var a=t(94015),s=t.n(a),i=t(23645),r=t.n(i)()(s());r.push([n.id,".sharing-input{width:100%;margin:10px 0}.sharing-input .multiselect__option span[lookup] .avatardiv{background-image:var(--icon-search-fff);background-repeat:no-repeat;background-position:center;background-color:var(--color-text-maxcontrast) !important}.sharing-input .multiselect__option span[lookup] .avatardiv div{display:none}","",{version:3,sources:["webpack://./apps/files_sharing/src/components/SharingInput.vue"],names:[],mappings:"AA0gBA,eACC,UAAA,CACA,aAAA,CAKE,4DACC,uCAAA,CACA,2BAAA,CACA,0BAAA,CACA,yDAAA,CACA,gEACC,YAAA",sourcesContent:["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n.sharing-input {\n\twidth: 100%;\n\tmargin: 10px 0;\n\n\t// properly style the lookup entry\n\t.multiselect__option {\n\t\tspan[lookup] {\n\t\t\t.avatardiv {\n\t\t\t\tbackground-image: var(--icon-search-fff);\n\t\t\t\tbackground-repeat: no-repeat;\n\t\t\t\tbackground-position: center;\n\t\t\t\tbackground-color: var(--color-text-maxcontrast) !important;\n\t\t\t\tdiv {\n\t\t\t\t\tdisplay: none;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const o=r},61436:(n,e,t)=>{t.d(e,{Z:()=>o});var a=t(94015),s=t.n(a),i=t(23645),r=t.n(i)()(s());r.push([n.id,".sharing-entry__inherited .avatar-shared[data-v-1c2059ae]{width:32px;height:32px;line-height:32px;font-size:18px;background-color:var(--color-text-maxcontrast);border-radius:50%;flex-shrink:0}","",{version:3,sources:["webpack://./apps/files_sharing/src/views/SharingInherited.vue"],names:[],mappings:"AA8JC,0DACC,UAAA,CACA,WAAA,CACA,gBAAA,CACA,cAAA,CACA,8CAAA,CACA,iBAAA,CACA,aAAA",sourcesContent:["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n.sharing-entry__inherited {\n\t.avatar-shared {\n\t\twidth: 32px;\n\t\theight: 32px;\n\t\tline-height: 32px;\n\t\tfont-size: 18px;\n\t\tbackground-color: var(--color-text-maxcontrast);\n\t\tborder-radius: 50%;\n\t\tflex-shrink: 0;\n\t}\n}\n"],sourceRoot:""}]);const o=r}},a={};function s(n){var t=a[n];if(void 0!==t)return t.exports;var i=a[n]={id:n,loaded:!1,exports:{}};return e[n].call(i.exports,i,i.exports,s),i.loaded=!0,i.exports}s.m=e,s.amdD=function(){throw new Error("define cannot be used indirect")},s.amdO={},n=[],s.O=(e,t,a,i)=>{if(!t){var r=1/0;for(c=0;c<n.length;c++){t=n[c][0],a=n[c][1],i=n[c][2];for(var o=!0,h=0;h<t.length;h++)(!1&i||r>=i)&&Object.keys(s.O).every((n=>s.O[n](t[h])))?t.splice(h--,1):(o=!1,i<r&&(r=i));if(o){n.splice(c--,1);var l=a();void 0!==l&&(e=l)}}return e}i=i||0;for(var c=n.length;c>0&&n[c-1][2]>i;c--)n[c]=n[c-1];n[c]=[t,a,i]},s.n=n=>{var e=n&&n.__esModule?()=>n.default:()=>n;return s.d(e,{a:e}),e},s.d=(n,e)=>{for(var t in e)s.o(e,t)&&!s.o(n,t)&&Object.defineProperty(n,t,{enumerable:!0,get:e[t]})},s.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(n){if("object"==typeof window)return window}}(),s.o=(n,e)=>Object.prototype.hasOwnProperty.call(n,e),s.r=n=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(n,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(n,"__esModule",{value:!0})},s.nmd=n=>(n.paths=[],n.children||(n.children=[]),n),s.j=870,(()=>{var n={870:0};s.O.j=e=>0===n[e];var e=(e,t)=>{var a,i,r=t[0],o=t[1],h=t[2],l=0;if(r.some((e=>0!==n[e]))){for(a in o)s.o(o,a)&&(s.m[a]=o[a]);if(h)var c=h(s)}for(e&&e(t);l<r.length;l++)i=r[l],s.o(n,i)&&n[i]&&n[i][0](),n[r[l]]=0;return s.O(c)},t=self.webpackChunknextcloud=self.webpackChunknextcloud||[];t.forEach(e.bind(null,0)),t.push=e.bind(null,t.push.bind(t))})();var i=s.O(void 0,[820],(()=>s(66647)));i=s.O(i)})(); +//# sourceMappingURL=files_sharing-files_sharing_tab.js.map?v=c517b53202f692a2d37b
\ No newline at end of file |