aboutsummaryrefslogtreecommitdiffstats
path: root/apps/files_sharing
diff options
context:
space:
mode:
authorJulius Härtl <jus@bitgrid.net>2019-08-21 17:00:21 +0200
committernpmbuildbot[bot] <npmbuildbot[bot]@users.noreply.github.com>2019-08-21 20:07:42 +0000
commit09efc4d6cf3cc10d478b8bf869ead83e2dbcb9f0 (patch)
treeed9876af528b69c6ff42ea4953cd6fc793f09656 /apps/files_sharing
parentf5352b9c6738e22f94115ffe6afdd0a792cc6834 (diff)
downloadnextcloud-server-09efc4d6cf3cc10d478b8bf869ead83e2dbcb9f0.tar.gz
nextcloud-server-09efc4d6cf3cc10d478b8bf869ead83e2dbcb9f0.zip
Properly handle failures and allow choosing folders for projects
Signed-off-by: Julius Härtl <jus@bitgrid.net> Signed-off-by: npmbuildbot[bot] <npmbuildbot[bot]@users.noreply.github.com>
Diffstat (limited to 'apps/files_sharing')
-rw-r--r--apps/files_sharing/js/dist/additionalScripts.js2
-rw-r--r--apps/files_sharing/js/dist/additionalScripts.js.map2
-rw-r--r--apps/files_sharing/js/dist/collaboration.js2
-rw-r--r--apps/files_sharing/js/dist/collaboration.js.map2
-rw-r--r--apps/files_sharing/src/collaborationresourceshandler.js4
5 files changed, 6 insertions, 6 deletions
diff --git a/apps/files_sharing/js/dist/additionalScripts.js b/apps/files_sharing/js/dist/additionalScripts.js
index 4318a790dc8..168d6bed4be 100644
--- a/apps/files_sharing/js/dist/additionalScripts.js
+++ b/apps/files_sharing/js/dist/additionalScripts.js
@@ -1,4 +1,4 @@
-!function(e){function n(n){for(var t,r,a=n[0],o=n[1],s=0,l=[];s<a.length;s++)r=a[s],Object.prototype.hasOwnProperty.call(i,r)&&i[r]&&l.push(i[r][0]),i[r]=0;for(t in o)Object.prototype.hasOwnProperty.call(o,t)&&(e[t]=o[t]);for(h&&h(n);l.length;)l.shift()()}var t={},i={0:0,1:0};function r(n){if(t[n])return t[n].exports;var i=t[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}r.e=function(e){var n=[],t=i[e];if(0!==t)if(t)n.push(t[2]);else{var a=new Promise(function(n,r){t=i[e]=[n,r]});n.push(t[2]=a);var o,s=document.createElement("script");s.charset="utf-8",s.timeout=120,r.nc&&s.setAttribute("nonce",r.nc),s.src=function(e){return r.p+"files_sharing."+e+".js?v="+{3:"022dc237b9d1013f3548",4:"9213d711eb16a194a232"}[e]}(e);var h=new Error;o=function(n){s.onerror=s.onload=null,clearTimeout(l);var t=i[e];if(0!==t){if(t){var r=n&&("load"===n.type?"missing":n.type),a=n&&n.target&&n.target.src;h.message="Loading chunk "+e+" failed.\n("+r+": "+a+")",h.name="ChunkLoadError",h.type=r,h.request=a,t[1](h)}i[e]=void 0}};var l=setTimeout(function(){o({type:"timeout",target:s})},12e4);s.onerror=s.onload=o,document.head.appendChild(s)}return Promise.all(n)},r.m=e,r.c=t,r.d=function(e,n,t){r.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:t})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,n){if(1&n&&(e=r(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(r.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var i in e)r.d(t,i,function(n){return e[n]}.bind(null,i));return t},r.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(n,"a",n),n},r.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},r.p="/js/",r.oe=function(e){throw console.error(e),e};var a=window.webpackJsonp=window.webpackJsonp||[],o=a.push.bind(a);a.push=n,a=a.slice();for(var s=0;s<a.length;s++)n(a[s]);var h=o;r(r.s=3)}([function(e,n,i){i.p=OC.linkTo("files_sharing","js/dist/"),i.nc=btoa(OC.requestToken),window.OCP.Collaboration.registerType("file",{action:function(){return new Promise(function(e,n){OC.dialogs.filepicker(t("files_sharing","Link to a file"),function(t){OC.Files.getClient().getFileInfo(t).then(function(n,t){e(t.id)},function(){n()})},!1)})},typeString:t("files_sharing","Link to a file"),typeIconClass:"icon-files-dark"})},function(e,n,t){"use strict";e.exports=function(e){var n=[];return n.toString=function(){return this.map(function(n){var t=function(e,n){var t=e[1]||"",i=e[3];if(!i)return t;if(n&&"function"==typeof btoa){var r=(o=i,s=btoa(unescape(encodeURIComponent(JSON.stringify(o)))),h="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(s),"/*# ".concat(h," */")),a=i.sources.map(function(e){return"/*# sourceURL=".concat(i.sourceRoot).concat(e," */")});return[t].concat(a).concat([r]).join("\n")}var o,s,h;return[t].join("\n")}(n,e);return n[2]?"@media ".concat(n[2],"{").concat(t,"}"):t}).join("")},n.i=function(e,t){"string"==typeof e&&(e=[[null,e,""]]);for(var i={},r=0;r<this.length;r++){var a=this[r][0];null!=a&&(i[a]=!0)}for(var o=0;o<e.length;o++){var s=e[o];null!=s[0]&&i[s[0]]||(t&&!s[2]?s[2]=t:t&&(s[2]="(".concat(s[2],") and (").concat(t,")")),n.push(s))}},n}},function(e,n,t){"use strict";var i,r={},a=function(){return void 0===i&&(i=Boolean(window&&document&&document.all&&!window.atob)),i},o=function(){var e={};return function(n){if(void 0===e[n]){var t=document.querySelector(n);if(window.HTMLIFrameElement&&t instanceof window.HTMLIFrameElement)try{t=t.contentDocument.head}catch(e){t=null}e[n]=t}return e[n]}}();function s(e,n){for(var t=[],i={},r=0;r<e.length;r++){var a=e[r],o=n.base?a[0]+n.base:a[0],s={css:a[1],media:a[2],sourceMap:a[3]};i[o]?i[o].parts.push(s):t.push(i[o]={id:o,parts:[s]})}return t}function h(e,n){for(var t=0;t<e.length;t++){var i=e[t],a=r[i.id],o=0;if(a){for(a.refs++;o<a.parts.length;o++)a.parts[o](i.parts[o]);for(;o<i.parts.length;o++)a.parts.push(m(i.parts[o],n))}else{for(var s=[];o<i.parts.length;o++)s.push(m(i.parts[o],n));r[i.id]={id:i.id,refs:1,parts:s}}}}function l(e){var n=document.createElement("style");if(void 0===e.attributes.nonce){var i=t.nc;i&&(e.attributes.nonce=i)}if(Object.keys(e.attributes).forEach(function(t){n.setAttribute(t,e.attributes[t])}),"function"==typeof e.insert)e.insert(n);else{var r=o(e.insert||"head");if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}return n}var p,d=(p=[],function(e,n){return p[e]=n,p.filter(Boolean).join("\n")});function c(e,n,t,i){var r=t?"":i.css;if(e.styleSheet)e.styleSheet.cssText=d(n,r);else{var a=document.createTextNode(r),o=e.childNodes;o[n]&&e.removeChild(o[n]),o.length?e.insertBefore(a,o[n]):e.appendChild(a)}}var u=null,f=0;function m(e,n){var t,i,r;if(n.singleton){var a=f++;t=u||(u=l(n)),i=c.bind(null,t,a,!1),r=c.bind(null,t,a,!0)}else t=l(n),i=function(e,n,t){var i=t.css,r=t.media,a=t.sourceMap;if(r&&e.setAttribute("media",r),a&&btoa&&(i+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),e.styleSheet)e.styleSheet.cssText=i;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(i))}}.bind(null,t,n),r=function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)};return i(e),function(n){if(n){if(n.css===e.css&&n.media===e.media&&n.sourceMap===e.sourceMap)return;i(e=n)}else r()}}e.exports=function(e,n){(n=n||{}).attributes="object"==typeof n.attributes?n.attributes:{},n.singleton||"boolean"==typeof n.singleton||(n.singleton=a());var t=s(e,n);return h(t,n),function(e){for(var i=[],a=0;a<t.length;a++){var o=t[a],l=r[o.id];l&&(l.refs--,i.push(l))}e&&h(s(e,n),n);for(var p=0;p<i.length;p++){var d=i[p];if(0===d.refs){for(var c=0;c<d.parts.length;c++)d.parts[c]();delete r[d.id]}}}}},function(e,n,t){"use strict";t.r(n);t(4),t(5),t(6),t(7),t(9),t(0);t.p=OC.linkTo("files_sharing","js/dist/"),t.nc=btoa(OC.requestToken),window.OCA.Sharing=OCA.Sharing},function(e,n){_.extend(OC.Files.Client,{PROPERTY_SHARE_TYPES:"{"+OC.Files.Client.NS_OWNCLOUD+"}share-types",PROPERTY_OWNER_ID:"{"+OC.Files.Client.NS_OWNCLOUD+"}owner-id",PROPERTY_OWNER_DISPLAY_NAME:"{"+OC.Files.Client.NS_OWNCLOUD+"}owner-display-name"}),OCA.Sharing||(OCA.Sharing={}),OCA.Sharing.Util={attach:function(e){if(OC.Share&&"trashbin"!==e.id&&"files.public"!==e.id){var n=e.fileActions,i=e._createRow;e._createRow=function(e){var t=i.apply(this,arguments),r=OCA.Sharing.Util.getSharePermissions(e);return 0===e.permissions&&(delete n.actions.all.Comment,delete n.actions.all.Details,delete n.actions.all.Goto),t.attr("data-share-permissions",r),e.shareOwner&&(t.attr("data-share-owner",e.shareOwner),t.attr("data-share-owner-id",e.shareOwnerId),"shared-root"===e.mountType&&t.attr("data-permissions",e.permissions|OC.PERMISSION_UPDATE)),e.recipientData&&!_.isEmpty(e.recipientData)&&t.attr("data-share-recipient-data",JSON.stringify(e.recipientData)),e.shareTypes&&t.attr("data-share-types",e.shareTypes.join(",")),t};var r=e.elementToFile;e.elementToFile=function(e){var n=r.apply(this,arguments);if(n.sharePermissions=e.attr("data-share-permissions")||void 0,n.shareOwner=e.attr("data-share-owner")||void 0,n.shareOwnerId=e.attr("data-share-owner-id")||void 0,e.attr("data-share-types")&&(n.shareTypes=e.attr("data-share-types").split(",")),e.attr("data-expiration")){var t=parseInt(e.attr("data-expiration"));n.shares=[],n.shares.push({expiration:t})}return n};var a=e._getWebdavProperties;e._getWebdavProperties=function(){var e=a.apply(this,arguments);return e.push(OC.Files.Client.PROPERTY_OWNER_ID),e.push(OC.Files.Client.PROPERTY_OWNER_DISPLAY_NAME),e.push(OC.Files.Client.PROPERTY_SHARE_TYPES),e},e.filesClient.addFileInfoParser(function(e){var n={},t=e.propStat[0].properties,i=t[OC.Files.Client.PROPERTY_PERMISSIONS];i&&i.indexOf("S")>=0&&(n.shareOwner=t[OC.Files.Client.PROPERTY_OWNER_DISPLAY_NAME],n.shareOwnerId=t[OC.Files.Client.PROPERTY_OWNER_ID]);var r=t[OC.Files.Client.PROPERTY_SHARE_TYPES];return r&&(n.shareTypes=_.chain(r).filter(function(e){return e.namespaceURI===OC.Files.Client.NS_OWNCLOUD&&"share-type"===e.nodeName.split(":")[1]}).map(function(e){return parseInt(e.textContent||e.text,10)}).value()),n}),e.$el.on("fileActionsReady",function(e){var n=e.$files;_.each(n,function(e){var n=$(e),t=n.attr("data-share-types")||"",i=n.attr("data-share-owner");if(t||i){var r=!1,a=!1;_.each(t.split(",")||[],function(e){(e=parseInt(e,10))===OC.Share.SHARE_TYPE_LINK?r=!0:e===OC.Share.SHARE_TYPE_EMAIL?r=!0:e===OC.Share.SHARE_TYPE_USER?a=!0:e===OC.Share.SHARE_TYPE_GROUP?a=!0:e===OC.Share.SHARE_TYPE_REMOTE?a=!0:e===OC.Share.SHARE_TYPE_CIRCLE?a=!0:e===OC.Share.SHARE_TYPE_ROOM&&(a=!0)}),OCA.Sharing.Util._updateFileActionIcon(n,a,r)}})}),e.$el.on("changeDirectory",function(){OCA.Sharing.sharesLoaded=!1}),n.registerAction({name:"Share",displayName:function(e){if(e&&e.$file){var n=parseInt(e.$file.data("share-types"),10),i=e.$file.data("share-owner-id");if(n>=0||i)return t("core","Shared")}return t("core","Share")},altText:t("core","Share"),mime:"all",order:-150,permissions:OC.PERMISSION_ALL,iconClass:function(e,n){var t=parseInt(n.$file.data("share-types"),10);return t===OC.Share.SHARE_TYPE_EMAIL||t===OC.Share.SHARE_TYPE_LINK?"icon-public":"icon-shared"},icon:function(e,n){var t=n.$file.data("share-owner-id");if(t)return OC.generateUrl("/avatar/".concat(t,"/32"))},type:OCA.Files.FileActions.TYPE_INLINE,actionHandler:function(n,t){var i=parseInt(t.$file.data("share-permissions"),10);(isNaN(i)||i>0)&&e.showDetailsView(n,"shareTabView")},render:function(e,t,i){return 0!=(parseInt(i.$file.data("permissions"),10)&OC.PERMISSION_SHARE)||i.$file.attr("data-share-owner")?n._defaultRenderAction.call(n,e,t,i):null}});var o=new OCA.Sharing.ShareTabView("shareTabView",{order:-20});o.on("sharesChanged",function(n){var t=n.fileInfoModel,i=e.findFileEl(t.get("name")),r=n.hasLinkShares();n.get("shares").forEach(function(e){e.share_type===OC.Share.SHARE_TYPE_EMAIL&&(r=!0)}),OCA.Sharing.Util._updateFileListDataAttributes(e,i,n),OCA.Sharing.Util._updateFileActionIcon(i,n.hasUserShares(),r)||OC.Share.markFileAsShared(i,!1,!1),t.set({shareTypes:n.getShareTypes(),icon:i.attr("data-icon")})}),e.registerTabView(o);var s=new OCA.Sharing.ShareBreadCrumbView({shareTab:o});e.registerBreadCrumbDetailView(s)}},_updateFileListDataAttributes:function(e,n,t){if("files"!==e.id)if(_.pluck(t.get("shares"),"share_with_displayname").length){var i=_.mapObject(t.get("shares"),function(e){return{shareWith:e.share_with,shareWithDisplayName:e.share_with_displayname}});n.attr("data-share-recipient-data",JSON.stringify(i))}else n.removeAttr("data-share-recipient-data")},_updateFileActionIcon:function(e,n,t){return!!(n||t||e.attr("data-share-recipient-data")||e.attr("data-share-owner"))&&(OC.Share.markFileAsShared(e,!0,t),!0)},getSharePermissions:function(e){return e.sharePermissions}},OC.Plugins.register("OCA.Files.FileList",OCA.Sharing.Util)},function(e,n,i){var r;r=OCA.Files.DetailTabView.extend({id:"shareTabView",className:"tab shareTabView",initialize:function(e,n){OCA.Files.DetailTabView.prototype.initialize.call(this,e,n),OC.Plugins.attach("OCA.Sharing.ShareTabView",this)},template:function(e){return'<div><div class="dialogContainer"></div><div id="collaborationResources"></div></div>'},getLabel:function(){return t("files_sharing","Sharing")},getIcon:function(){return"icon-shared"},render:function(){var e=this,n=this;if(this._dialog&&(this._dialog.model.off(),this._dialog.remove(),this._dialog=null),this.model){this.$el.html(this.template()),_.isUndefined(this.model.get("sharePermissions"))&&this.model.set("sharePermissions",OCA.Sharing.Util.getSharePermissions(this.model.attributes));var t={itemType:this.model.isDirectory()?"folder":"file",itemSource:this.model.get("id"),possiblePermissions:this.model.get("sharePermissions")},r=new OC.Share.ShareConfigModel,a=new OC.Share.ShareItemModel(t,{configModel:r,fileInfoModel:this.model});this._dialog=new OC.Share.ShareDialogView({configModel:r,model:a}),this.$el.find(".dialogContainer").append(this._dialog.$el),this._dialog.render(),this._dialog.model.fetch(),this._dialog.model.on("change",function(){n.trigger("sharesChanged",a)}),Promise.all([i.e(3),i.e(4)]).then(i.bind(null,14)).then(function(n){var t=new n.Vue({el:"#collaborationResources",render:function(e){return e(n.View)},data:{model:e.model.toJSON()}});e.model.on("change",function(){t.data=e.model.toJSON()})})}else this.$el.empty();this.trigger("rendered")}}),OCA.Sharing.ShareTabView=r},function(e,n){
+!function(e){function n(n){for(var t,r,a=n[0],o=n[1],s=0,h=[];s<a.length;s++)r=a[s],Object.prototype.hasOwnProperty.call(i,r)&&i[r]&&h.push(i[r][0]),i[r]=0;for(t in o)Object.prototype.hasOwnProperty.call(o,t)&&(e[t]=o[t]);for(l&&l(n);h.length;)h.shift()()}var t={},i={0:0,1:0};function r(n){if(t[n])return t[n].exports;var i=t[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}r.e=function(e){var n=[],t=i[e];if(0!==t)if(t)n.push(t[2]);else{var a=new Promise(function(n,r){t=i[e]=[n,r]});n.push(t[2]=a);var o,s=document.createElement("script");s.charset="utf-8",s.timeout=120,r.nc&&s.setAttribute("nonce",r.nc),s.src=function(e){return r.p+"files_sharing."+e+".js?v="+{3:"022dc237b9d1013f3548",4:"9213d711eb16a194a232"}[e]}(e);var l=new Error;o=function(n){s.onerror=s.onload=null,clearTimeout(h);var t=i[e];if(0!==t){if(t){var r=n&&("load"===n.type?"missing":n.type),a=n&&n.target&&n.target.src;l.message="Loading chunk "+e+" failed.\n("+r+": "+a+")",l.name="ChunkLoadError",l.type=r,l.request=a,t[1](l)}i[e]=void 0}};var h=setTimeout(function(){o({type:"timeout",target:s})},12e4);s.onerror=s.onload=o,document.head.appendChild(s)}return Promise.all(n)},r.m=e,r.c=t,r.d=function(e,n,t){r.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:t})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,n){if(1&n&&(e=r(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(r.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var i in e)r.d(t,i,function(n){return e[n]}.bind(null,i));return t},r.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(n,"a",n),n},r.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},r.p="/js/",r.oe=function(e){throw console.error(e),e};var a=window.webpackJsonp=window.webpackJsonp||[],o=a.push.bind(a);a.push=n,a=a.slice();for(var s=0;s<a.length;s++)n(a[s]);var l=o;r(r.s=3)}([function(e,n,i){i.p=OC.linkTo("files_sharing","js/dist/"),i.nc=btoa(OC.requestToken),window.OCP.Collaboration.registerType("file",{action:function(){return new Promise(function(e,n){OC.dialogs.filepicker(t("files_sharing","Link to a file"),function(t){OC.Files.getClient().getFileInfo(t).then(function(n,t){e(t.id)}).fail(function(){n()})},!1,null,!1,OC.dialogs.FILEPICKER_TYPE_CHOOSE,"",{allowDirectoryChooser:!0})})},typeString:t("files_sharing","Link to a file"),typeIconClass:"icon-files-dark"})},function(e,n,t){"use strict";e.exports=function(e){var n=[];return n.toString=function(){return this.map(function(n){var t=function(e,n){var t=e[1]||"",i=e[3];if(!i)return t;if(n&&"function"==typeof btoa){var r=(o=i,s=btoa(unescape(encodeURIComponent(JSON.stringify(o)))),l="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(s),"/*# ".concat(l," */")),a=i.sources.map(function(e){return"/*# sourceURL=".concat(i.sourceRoot).concat(e," */")});return[t].concat(a).concat([r]).join("\n")}var o,s,l;return[t].join("\n")}(n,e);return n[2]?"@media ".concat(n[2],"{").concat(t,"}"):t}).join("")},n.i=function(e,t){"string"==typeof e&&(e=[[null,e,""]]);for(var i={},r=0;r<this.length;r++){var a=this[r][0];null!=a&&(i[a]=!0)}for(var o=0;o<e.length;o++){var s=e[o];null!=s[0]&&i[s[0]]||(t&&!s[2]?s[2]=t:t&&(s[2]="(".concat(s[2],") and (").concat(t,")")),n.push(s))}},n}},function(e,n,t){"use strict";var i,r={},a=function(){return void 0===i&&(i=Boolean(window&&document&&document.all&&!window.atob)),i},o=function(){var e={};return function(n){if(void 0===e[n]){var t=document.querySelector(n);if(window.HTMLIFrameElement&&t instanceof window.HTMLIFrameElement)try{t=t.contentDocument.head}catch(e){t=null}e[n]=t}return e[n]}}();function s(e,n){for(var t=[],i={},r=0;r<e.length;r++){var a=e[r],o=n.base?a[0]+n.base:a[0],s={css:a[1],media:a[2],sourceMap:a[3]};i[o]?i[o].parts.push(s):t.push(i[o]={id:o,parts:[s]})}return t}function l(e,n){for(var t=0;t<e.length;t++){var i=e[t],a=r[i.id],o=0;if(a){for(a.refs++;o<a.parts.length;o++)a.parts[o](i.parts[o]);for(;o<i.parts.length;o++)a.parts.push(m(i.parts[o],n))}else{for(var s=[];o<i.parts.length;o++)s.push(m(i.parts[o],n));r[i.id]={id:i.id,refs:1,parts:s}}}}function h(e){var n=document.createElement("style");if(void 0===e.attributes.nonce){var i=t.nc;i&&(e.attributes.nonce=i)}if(Object.keys(e.attributes).forEach(function(t){n.setAttribute(t,e.attributes[t])}),"function"==typeof e.insert)e.insert(n);else{var r=o(e.insert||"head");if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}return n}var p,d=(p=[],function(e,n){return p[e]=n,p.filter(Boolean).join("\n")});function c(e,n,t,i){var r=t?"":i.css;if(e.styleSheet)e.styleSheet.cssText=d(n,r);else{var a=document.createTextNode(r),o=e.childNodes;o[n]&&e.removeChild(o[n]),o.length?e.insertBefore(a,o[n]):e.appendChild(a)}}var u=null,f=0;function m(e,n){var t,i,r;if(n.singleton){var a=f++;t=u||(u=h(n)),i=c.bind(null,t,a,!1),r=c.bind(null,t,a,!0)}else t=h(n),i=function(e,n,t){var i=t.css,r=t.media,a=t.sourceMap;if(r&&e.setAttribute("media",r),a&&btoa&&(i+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),e.styleSheet)e.styleSheet.cssText=i;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(i))}}.bind(null,t,n),r=function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)};return i(e),function(n){if(n){if(n.css===e.css&&n.media===e.media&&n.sourceMap===e.sourceMap)return;i(e=n)}else r()}}e.exports=function(e,n){(n=n||{}).attributes="object"==typeof n.attributes?n.attributes:{},n.singleton||"boolean"==typeof n.singleton||(n.singleton=a());var t=s(e,n);return l(t,n),function(e){for(var i=[],a=0;a<t.length;a++){var o=t[a],h=r[o.id];h&&(h.refs--,i.push(h))}e&&l(s(e,n),n);for(var p=0;p<i.length;p++){var d=i[p];if(0===d.refs){for(var c=0;c<d.parts.length;c++)d.parts[c]();delete r[d.id]}}}}},function(e,n,t){"use strict";t.r(n);t(4),t(5),t(6),t(7),t(9),t(0);t.p=OC.linkTo("files_sharing","js/dist/"),t.nc=btoa(OC.requestToken),window.OCA.Sharing=OCA.Sharing},function(e,n){_.extend(OC.Files.Client,{PROPERTY_SHARE_TYPES:"{"+OC.Files.Client.NS_OWNCLOUD+"}share-types",PROPERTY_OWNER_ID:"{"+OC.Files.Client.NS_OWNCLOUD+"}owner-id",PROPERTY_OWNER_DISPLAY_NAME:"{"+OC.Files.Client.NS_OWNCLOUD+"}owner-display-name"}),OCA.Sharing||(OCA.Sharing={}),OCA.Sharing.Util={attach:function(e){if(OC.Share&&"trashbin"!==e.id&&"files.public"!==e.id){var n=e.fileActions,i=e._createRow;e._createRow=function(e){var t=i.apply(this,arguments),r=OCA.Sharing.Util.getSharePermissions(e);return 0===e.permissions&&(delete n.actions.all.Comment,delete n.actions.all.Details,delete n.actions.all.Goto),t.attr("data-share-permissions",r),e.shareOwner&&(t.attr("data-share-owner",e.shareOwner),t.attr("data-share-owner-id",e.shareOwnerId),"shared-root"===e.mountType&&t.attr("data-permissions",e.permissions|OC.PERMISSION_UPDATE)),e.recipientData&&!_.isEmpty(e.recipientData)&&t.attr("data-share-recipient-data",JSON.stringify(e.recipientData)),e.shareTypes&&t.attr("data-share-types",e.shareTypes.join(",")),t};var r=e.elementToFile;e.elementToFile=function(e){var n=r.apply(this,arguments);if(n.sharePermissions=e.attr("data-share-permissions")||void 0,n.shareOwner=e.attr("data-share-owner")||void 0,n.shareOwnerId=e.attr("data-share-owner-id")||void 0,e.attr("data-share-types")&&(n.shareTypes=e.attr("data-share-types").split(",")),e.attr("data-expiration")){var t=parseInt(e.attr("data-expiration"));n.shares=[],n.shares.push({expiration:t})}return n};var a=e._getWebdavProperties;e._getWebdavProperties=function(){var e=a.apply(this,arguments);return e.push(OC.Files.Client.PROPERTY_OWNER_ID),e.push(OC.Files.Client.PROPERTY_OWNER_DISPLAY_NAME),e.push(OC.Files.Client.PROPERTY_SHARE_TYPES),e},e.filesClient.addFileInfoParser(function(e){var n={},t=e.propStat[0].properties,i=t[OC.Files.Client.PROPERTY_PERMISSIONS];i&&i.indexOf("S")>=0&&(n.shareOwner=t[OC.Files.Client.PROPERTY_OWNER_DISPLAY_NAME],n.shareOwnerId=t[OC.Files.Client.PROPERTY_OWNER_ID]);var r=t[OC.Files.Client.PROPERTY_SHARE_TYPES];return r&&(n.shareTypes=_.chain(r).filter(function(e){return e.namespaceURI===OC.Files.Client.NS_OWNCLOUD&&"share-type"===e.nodeName.split(":")[1]}).map(function(e){return parseInt(e.textContent||e.text,10)}).value()),n}),e.$el.on("fileActionsReady",function(e){var n=e.$files;_.each(n,function(e){var n=$(e),t=n.attr("data-share-types")||"",i=n.attr("data-share-owner");if(t||i){var r=!1,a=!1;_.each(t.split(",")||[],function(e){(e=parseInt(e,10))===OC.Share.SHARE_TYPE_LINK?r=!0:e===OC.Share.SHARE_TYPE_EMAIL?r=!0:e===OC.Share.SHARE_TYPE_USER?a=!0:e===OC.Share.SHARE_TYPE_GROUP?a=!0:e===OC.Share.SHARE_TYPE_REMOTE?a=!0:e===OC.Share.SHARE_TYPE_CIRCLE?a=!0:e===OC.Share.SHARE_TYPE_ROOM&&(a=!0)}),OCA.Sharing.Util._updateFileActionIcon(n,a,r)}})}),e.$el.on("changeDirectory",function(){OCA.Sharing.sharesLoaded=!1}),n.registerAction({name:"Share",displayName:function(e){if(e&&e.$file){var n=parseInt(e.$file.data("share-types"),10),i=e.$file.data("share-owner-id");if(n>=0||i)return t("core","Shared")}return t("core","Share")},altText:t("core","Share"),mime:"all",order:-150,permissions:OC.PERMISSION_ALL,iconClass:function(e,n){var t=parseInt(n.$file.data("share-types"),10);return t===OC.Share.SHARE_TYPE_EMAIL||t===OC.Share.SHARE_TYPE_LINK?"icon-public":"icon-shared"},icon:function(e,n){var t=n.$file.data("share-owner-id");if(t)return OC.generateUrl("/avatar/".concat(t,"/32"))},type:OCA.Files.FileActions.TYPE_INLINE,actionHandler:function(n,t){var i=parseInt(t.$file.data("share-permissions"),10);(isNaN(i)||i>0)&&e.showDetailsView(n,"shareTabView")},render:function(e,t,i){return 0!=(parseInt(i.$file.data("permissions"),10)&OC.PERMISSION_SHARE)||i.$file.attr("data-share-owner")?n._defaultRenderAction.call(n,e,t,i):null}});var o=new OCA.Sharing.ShareTabView("shareTabView",{order:-20});o.on("sharesChanged",function(n){var t=n.fileInfoModel,i=e.findFileEl(t.get("name")),r=n.hasLinkShares();n.get("shares").forEach(function(e){e.share_type===OC.Share.SHARE_TYPE_EMAIL&&(r=!0)}),OCA.Sharing.Util._updateFileListDataAttributes(e,i,n),OCA.Sharing.Util._updateFileActionIcon(i,n.hasUserShares(),r)||OC.Share.markFileAsShared(i,!1,!1),t.set({shareTypes:n.getShareTypes(),icon:i.attr("data-icon")})}),e.registerTabView(o);var s=new OCA.Sharing.ShareBreadCrumbView({shareTab:o});e.registerBreadCrumbDetailView(s)}},_updateFileListDataAttributes:function(e,n,t){if("files"!==e.id)if(_.pluck(t.get("shares"),"share_with_displayname").length){var i=_.mapObject(t.get("shares"),function(e){return{shareWith:e.share_with,shareWithDisplayName:e.share_with_displayname}});n.attr("data-share-recipient-data",JSON.stringify(i))}else n.removeAttr("data-share-recipient-data")},_updateFileActionIcon:function(e,n,t){return!!(n||t||e.attr("data-share-recipient-data")||e.attr("data-share-owner"))&&(OC.Share.markFileAsShared(e,!0,t),!0)},getSharePermissions:function(e){return e.sharePermissions}},OC.Plugins.register("OCA.Files.FileList",OCA.Sharing.Util)},function(e,n,i){var r;r=OCA.Files.DetailTabView.extend({id:"shareTabView",className:"tab shareTabView",initialize:function(e,n){OCA.Files.DetailTabView.prototype.initialize.call(this,e,n),OC.Plugins.attach("OCA.Sharing.ShareTabView",this)},template:function(e){return'<div><div class="dialogContainer"></div><div id="collaborationResources"></div></div>'},getLabel:function(){return t("files_sharing","Sharing")},getIcon:function(){return"icon-shared"},render:function(){var e=this,n=this;if(this._dialog&&(this._dialog.model.off(),this._dialog.remove(),this._dialog=null),this.model){this.$el.html(this.template()),_.isUndefined(this.model.get("sharePermissions"))&&this.model.set("sharePermissions",OCA.Sharing.Util.getSharePermissions(this.model.attributes));var t={itemType:this.model.isDirectory()?"folder":"file",itemSource:this.model.get("id"),possiblePermissions:this.model.get("sharePermissions")},r=new OC.Share.ShareConfigModel,a=new OC.Share.ShareItemModel(t,{configModel:r,fileInfoModel:this.model});this._dialog=new OC.Share.ShareDialogView({configModel:r,model:a}),this.$el.find(".dialogContainer").append(this._dialog.$el),this._dialog.render(),this._dialog.model.fetch(),this._dialog.model.on("change",function(){n.trigger("sharesChanged",a)}),Promise.all([i.e(3),i.e(4)]).then(i.bind(null,14)).then(function(n){var t=new n.Vue({el:"#collaborationResources",render:function(e){return e(n.View)},data:{model:e.model.toJSON()}});e.model.on("change",function(){t.data=e.model.toJSON()})})}else this.$el.empty();this.trigger("rendered")}}),OCA.Sharing.ShareTabView=r},function(e,n){
/**
* @copyright 2016 Christoph Wurst <christoph@winzerhof-wurst.at>
*
diff --git a/apps/files_sharing/js/dist/additionalScripts.js.map b/apps/files_sharing/js/dist/additionalScripts.js.map
index 151b00004bb..3f7917e7d57 100644
--- a/apps/files_sharing/js/dist/additionalScripts.js.map
+++ b/apps/files_sharing/js/dist/additionalScripts.js.map
@@ -1 +1 @@
-{"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///./apps/files_sharing/src/collaborationresourceshandler.js","webpack:///./node_modules/css-loader/dist/runtime/api.js","webpack:///./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js","webpack:///./apps/files_sharing/src/additionalScripts.js","webpack:///./apps/files_sharing/src/share.js","webpack:///./apps/files_sharing/src/sharetabview.js","webpack:///./apps/files_sharing/src/sharebreadcrumbview.js","webpack:///./apps/files_sharing/src/style/sharetabview.scss?91ba","webpack:///./apps/files_sharing/src/style/sharetabview.scss","webpack:///./apps/files_sharing/src/style/sharebreadcrumb.scss?eb86","webpack:///./apps/files_sharing/src/style/sharebreadcrumb.scss"],"names":["webpackJsonpCallback","data","moduleId","chunkId","chunkIds","moreModules","i","resolves","length","Object","prototype","hasOwnProperty","call","installedChunks","push","modules","parentJsonpFunction","shift","installedModules","0","1","__webpack_require__","exports","module","l","e","promises","installedChunkData","promise","Promise","resolve","reject","onScriptComplete","script","document","createElement","charset","timeout","nc","setAttribute","src","p","jsonpScriptSrc","error","Error","event","onerror","onload","clearTimeout","chunk","errorType","type","realSrc","target","message","name","request","undefined","setTimeout","head","appendChild","all","m","c","d","getter","o","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","oe","err","console","jsonpArray","window","oldJsonpFunction","slice","s","__webpack_public_path__","OC","linkTo","__webpack_nonce__","btoa","requestToken","OCP","Collaboration","registerType","action","dialogs","filepicker","f","Files","getClient","getFileInfo","then","status","fileInfo","id","typeString","typeIconClass","useSourceMap","list","toString","this","map","item","content","cssMapping","sourceMapping","sourceMap","base64","unescape","encodeURIComponent","JSON","stringify","concat","sourceURLs","sources","source","sourceRoot","join","cssWithMappingToString","mediaQuery","alreadyImportedModules","_i","memo","stylesInDom","isOldIE","Boolean","atob","getTarget","styleTarget","querySelector","HTMLIFrameElement","contentDocument","listToStyles","options","styles","newStyles","base","part","css","media","parts","addStylesToDom","domStyle","j","refs","addStyle","insertStyleElement","style","attributes","nonce","keys","forEach","insert","textStore","replaceText","index","replacement","filter","applyToSingletonTag","remove","obj","styleSheet","cssText","cssNode","createTextNode","childNodes","removeChild","insertBefore","singleton","singletonCounter","update","styleIndex","firstChild","parentNode","removeStyleElement","newObj","newList","mayRemove","_domStyle","OCA","Sharing","_","extend","Client","PROPERTY_SHARE_TYPES","NS_OWNCLOUD","PROPERTY_OWNER_ID","PROPERTY_OWNER_DISPLAY_NAME","Util","attach","fileList","Share","fileActions","oldCreateRow","_createRow","fileData","tr","apply","arguments","sharePermissions","getSharePermissions","permissions","actions","Comment","Details","Goto","attr","shareOwner","shareOwnerId","mountType","PERMISSION_UPDATE","recipientData","isEmpty","shareTypes","oldElementToFile","elementToFile","$el","split","expirationTimestamp","parseInt","shares","expiration","oldGetWebdavProperties","_getWebdavProperties","props","filesClient","addFileInfoParser","response","propStat","properties","permissionsProp","PROPERTY_PERMISSIONS","indexOf","shareTypesProp","chain","xmlvalue","namespaceURI","nodeName","textContent","text","on","ev","$files","each","file","$tr","$","hasLink","hasShares","shareType","SHARE_TYPE_LINK","SHARE_TYPE_EMAIL","SHARE_TYPE_USER","SHARE_TYPE_GROUP","SHARE_TYPE_REMOTE","SHARE_TYPE_CIRCLE","SHARE_TYPE_ROOM","_updateFileActionIcon","sharesLoaded","registerAction","displayName","context","$file","altText","mime","order","PERMISSION_ALL","iconClass","fileName","icon","generateUrl","FileActions","TYPE_INLINE","actionHandler","isNaN","showDetailsView","render","actionSpec","isDefault","PERMISSION_SHARE","_defaultRenderAction","shareTab","ShareTabView","shareModel","fileInfoModel","findFileEl","hasLinkShares","share","share_type","_updateFileListDataAttributes","hasUserShares","markFileAsShared","set","getShareTypes","registerTabView","breadCrumbSharingDetailView","ShareBreadCrumbView","registerBreadCrumbDetailView","pluck","mapObject","shareWith","share_with","shareWithDisplayName","share_with_displayname","removeAttr","Plugins","register","DetailTabView","className","initialize","template","params","getLabel","getIcon","self","_dialog","model","off","html","isUndefined","itemType","isDirectory","itemSource","possiblePermissions","configModel","ShareConfigModel","ShareItemModel","ShareDialogView","find","append","fetch","trigger","Resources","vm","Vue","el","h","View","toJSON","empty","BreadCrumbView","Backbone","tagName","events","click","_dirInfo","_shareTab","dirInfo","path","removeClass","hide","isShared","addClass","show","delegateEvents","_onClick","preventDefault","FileInfoModel","getSharesWithCurrentItem","App","locals"],"mappings":"aACE,SAASA,EAAqBC,GAQ7B,IAPA,IAMIC,EAAUC,EANVC,EAAWH,EAAK,GAChBI,EAAcJ,EAAK,GAKAK,EAAI,EAAGC,EAAW,GACpCD,EAAIF,EAASI,OAAQF,IACzBH,EAAUC,EAASE,GAChBG,OAAOC,UAAUC,eAAeC,KAAKC,EAAiBV,IAAYU,EAAgBV,IACpFI,EAASO,KAAKD,EAAgBV,GAAS,IAExCU,EAAgBV,GAAW,EAE5B,IAAID,KAAYG,EACZI,OAAOC,UAAUC,eAAeC,KAAKP,EAAaH,KACpDa,EAAQb,GAAYG,EAAYH,IAKlC,IAFGc,GAAqBA,EAAoBf,GAEtCM,EAASC,QACdD,EAASU,OAATV,GAOF,IAAIW,EAAmB,GAKnBL,EAAkB,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Callback(data) {\n \t\tvar chunkIds = data[0];\n \t\tvar moreModules = data[1];\n\n\n \t\t// add \"moreModules\" to the modules object,\n \t\t// then flag all \"chunkIds\" as loaded and fire callback\n \t\tvar moduleId, chunkId, i = 0, resolves = [];\n \t\tfor(;i < chunkIds.length; i++) {\n \t\t\tchunkId = chunkIds[i];\n \t\t\tif(Object.prototype.hasOwnProperty.call(installedChunks, chunkId) && installedChunks[chunkId]) {\n \t\t\t\tresolves.push(installedChunks[chunkId][0]);\n \t\t\t}\n \t\t\tinstalledChunks[chunkId] = 0;\n \t\t}\n \t\tfor(moduleId in moreModules) {\n \t\t\tif(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) {\n \t\t\t\tmodules[moduleId] = moreModules[moduleId];\n \t\t\t}\n \t\t}\n \t\tif(parentJsonpFunction) parentJsonpFunction(data);\n\n \t\twhile(resolves.length) {\n \t\t\tresolves.shift()();\n \t\t}\n\n \t};\n\n\n \t// The module cache\n \tvar installedModules = {};\n\n \t// object to store loaded and loading chunks\n \t// undefined = chunk not loaded, null = chunk preloaded/prefetched\n \t// Promise = chunk loading, 0 = chunk loaded\n \tvar installedChunks = {\n \t\t0: 0,\n \t\t1: 0\n \t};\n\n\n\n \t// script path function\n \tfunction jsonpScriptSrc(chunkId) {\n \t\treturn __webpack_require__.p + \"files_sharing.\" + chunkId + \".js?v=\" + {\"3\":\"022dc237b9d1013f3548\",\"4\":\"9213d711eb16a194a232\"}[chunkId] + \"\"\n \t}\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n \t// This file contains only the entry chunk.\n \t// The chunk loading function for additional chunks\n \t__webpack_require__.e = function requireEnsure(chunkId) {\n \t\tvar promises = [];\n\n\n \t\t// JSONP chunk loading for javascript\n\n \t\tvar installedChunkData = installedChunks[chunkId];\n \t\tif(installedChunkData !== 0) { // 0 means \"already installed\".\n\n \t\t\t// a Promise means \"currently loading\".\n \t\t\tif(installedChunkData) {\n \t\t\t\tpromises.push(installedChunkData[2]);\n \t\t\t} else {\n \t\t\t\t// setup Promise in chunk cache\n \t\t\t\tvar promise = new Promise(function(resolve, reject) {\n \t\t\t\t\tinstalledChunkData = installedChunks[chunkId] = [resolve, reject];\n \t\t\t\t});\n \t\t\t\tpromises.push(installedChunkData[2] = promise);\n\n \t\t\t\t// start chunk loading\n \t\t\t\tvar script = document.createElement('script');\n \t\t\t\tvar onScriptComplete;\n\n \t\t\t\tscript.charset = 'utf-8';\n \t\t\t\tscript.timeout = 120;\n \t\t\t\tif (__webpack_require__.nc) {\n \t\t\t\t\tscript.setAttribute(\"nonce\", __webpack_require__.nc);\n \t\t\t\t}\n \t\t\t\tscript.src = jsonpScriptSrc(chunkId);\n\n \t\t\t\t// create error before stack unwound to get useful stacktrace later\n \t\t\t\tvar error = new Error();\n \t\t\t\tonScriptComplete = function (event) {\n \t\t\t\t\t// avoid mem leaks in IE.\n \t\t\t\t\tscript.onerror = script.onload = null;\n \t\t\t\t\tclearTimeout(timeout);\n \t\t\t\t\tvar chunk = installedChunks[chunkId];\n \t\t\t\t\tif(chunk !== 0) {\n \t\t\t\t\t\tif(chunk) {\n \t\t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n \t\t\t\t\t\t\tvar realSrc = event && event.target && event.target.src;\n \t\t\t\t\t\t\terror.message = 'Loading chunk ' + chunkId + ' failed.\\n(' + errorType + ': ' + realSrc + ')';\n \t\t\t\t\t\t\terror.name = 'ChunkLoadError';\n \t\t\t\t\t\t\terror.type = errorType;\n \t\t\t\t\t\t\terror.request = realSrc;\n \t\t\t\t\t\t\tchunk[1](error);\n \t\t\t\t\t\t}\n \t\t\t\t\t\tinstalledChunks[chunkId] = undefined;\n \t\t\t\t\t}\n \t\t\t\t};\n \t\t\t\tvar timeout = setTimeout(function(){\n \t\t\t\t\tonScriptComplete({ type: 'timeout', target: script });\n \t\t\t\t}, 120000);\n \t\t\t\tscript.onerror = script.onload = onScriptComplete;\n \t\t\t\tdocument.head.appendChild(script);\n \t\t\t}\n \t\t}\n \t\treturn Promise.all(promises);\n \t};\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"/js/\";\n\n \t// on error function for async loading\n \t__webpack_require__.oe = function(err) { console.error(err); throw err; };\n\n \tvar jsonpArray = window[\"webpackJsonp\"] = window[\"webpackJsonp\"] || [];\n \tvar oldJsonpFunction = jsonpArray.push.bind(jsonpArray);\n \tjsonpArray.push = webpackJsonpCallback;\n \tjsonpArray = jsonpArray.slice();\n \tfor(var i = 0; i < jsonpArray.length; i++) webpackJsonpCallback(jsonpArray[i]);\n \tvar parentJsonpFunction = oldJsonpFunction;\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 3);\n","__webpack_public_path__ = OC.linkTo('files_sharing', 'js/dist/');\n__webpack_nonce__ = btoa(OC.requestToken);\n\nwindow.OCP.Collaboration.registerType('file', {\n\taction: () => {\n\t\treturn new Promise((resolve, reject) => {\n\t\t\tOC.dialogs.filepicker(t('files_sharing', 'Link to a file'), function (f) {\n\t\t\t\tconst client = OC.Files.getClient();\n\t\t\t\tclient.getFileInfo(f).then((status, fileInfo) => {\n\t\t\t\t\tresolve(fileInfo.id);\n\t\t\t\t}, () => {\n\t\t\t\t\treject();\n\t\t\t\t});\n\t\t\t}, false);\n\t\t});\n\t},\n\ttypeString: t('files_sharing', 'Link to a file'),\n\ttypeIconClass: 'icon-files-dark'\n});\n","\"use strict\";\n\n/*\n MIT License http://www.opensource.org/licenses/mit-license.php\n Author Tobias Koppers @sokra\n*/\n// css base code, injected by the css-loader\n// eslint-disable-next-line func-names\nmodule.exports = function (useSourceMap) {\n var list = []; // return the list of modules as css string\n\n list.toString = function toString() {\n return this.map(function (item) {\n var content = cssWithMappingToString(item, useSourceMap);\n\n if (item[2]) {\n return \"@media \".concat(item[2], \"{\").concat(content, \"}\");\n }\n\n return content;\n }).join('');\n }; // import a list of modules into the list\n // eslint-disable-next-line func-names\n\n\n list.i = function (modules, mediaQuery) {\n if (typeof modules === 'string') {\n // eslint-disable-next-line no-param-reassign\n modules = [[null, modules, '']];\n }\n\n var alreadyImportedModules = {};\n\n for (var i = 0; i < this.length; i++) {\n // eslint-disable-next-line prefer-destructuring\n var id = this[i][0];\n\n if (id != null) {\n alreadyImportedModules[id] = true;\n }\n }\n\n for (var _i = 0; _i < modules.length; _i++) {\n var item = modules[_i]; // skip already imported module\n // this implementation is not 100% perfect for weird media query combinations\n // when a module is imported multiple times with different media queries.\n // I hope this will never occur (Hey this way we have smaller bundles)\n\n if (item[0] == null || !alreadyImportedModules[item[0]]) {\n if (mediaQuery && !item[2]) {\n item[2] = mediaQuery;\n } else if (mediaQuery) {\n item[2] = \"(\".concat(item[2], \") and (\").concat(mediaQuery, \")\");\n }\n\n list.push(item);\n }\n }\n };\n\n return list;\n};\n\nfunction cssWithMappingToString(item, useSourceMap) {\n var content = item[1] || ''; // eslint-disable-next-line prefer-destructuring\n\n var cssMapping = item[3];\n\n if (!cssMapping) {\n return content;\n }\n\n if (useSourceMap && typeof btoa === 'function') {\n var sourceMapping = toComment(cssMapping);\n var sourceURLs = cssMapping.sources.map(function (source) {\n return \"/*# sourceURL=\".concat(cssMapping.sourceRoot).concat(source, \" */\");\n });\n return [content].concat(sourceURLs).concat([sourceMapping]).join('\\n');\n }\n\n return [content].join('\\n');\n} // Adapted from convert-source-map (MIT)\n\n\nfunction toComment(sourceMap) {\n // eslint-disable-next-line no-undef\n var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap))));\n var data = \"sourceMappingURL=data:application/json;charset=utf-8;base64,\".concat(base64);\n return \"/*# \".concat(data, \" */\");\n}","\"use strict\";\n\nvar stylesInDom = {};\n\nvar isOldIE = function isOldIE() {\n var memo;\n return function memorize() {\n if (typeof memo === 'undefined') {\n // Test for IE <= 9 as proposed by Browserhacks\n // @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805\n // Tests for existence of standard globals is to allow style-loader\n // to operate correctly into non-standard environments\n // @see https://github.com/webpack-contrib/style-loader/issues/177\n memo = Boolean(window && document && document.all && !window.atob);\n }\n\n return memo;\n };\n}();\n\nvar getTarget = function getTarget() {\n var memo = {};\n return function memorize(target) {\n if (typeof memo[target] === 'undefined') {\n var styleTarget = document.querySelector(target); // Special case to return head of iframe instead of iframe itself\n\n if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {\n try {\n // This will throw an exception if access to iframe is blocked\n // due to cross-origin restrictions\n styleTarget = styleTarget.contentDocument.head;\n } catch (e) {\n // istanbul ignore next\n styleTarget = null;\n }\n }\n\n memo[target] = styleTarget;\n }\n\n return memo[target];\n };\n}();\n\nfunction listToStyles(list, options) {\n var styles = [];\n var newStyles = {};\n\n for (var i = 0; i < list.length; i++) {\n var item = list[i];\n var id = options.base ? item[0] + options.base : item[0];\n var css = item[1];\n var media = item[2];\n var sourceMap = item[3];\n var part = {\n css: css,\n media: media,\n sourceMap: sourceMap\n };\n\n if (!newStyles[id]) {\n styles.push(newStyles[id] = {\n id: id,\n parts: [part]\n });\n } else {\n newStyles[id].parts.push(part);\n }\n }\n\n return styles;\n}\n\nfunction addStylesToDom(styles, options) {\n for (var i = 0; i < styles.length; i++) {\n var item = styles[i];\n var domStyle = stylesInDom[item.id];\n var j = 0;\n\n if (domStyle) {\n domStyle.refs++;\n\n for (; j < domStyle.parts.length; j++) {\n domStyle.parts[j](item.parts[j]);\n }\n\n for (; j < item.parts.length; j++) {\n domStyle.parts.push(addStyle(item.parts[j], options));\n }\n } else {\n var parts = [];\n\n for (; j < item.parts.length; j++) {\n parts.push(addStyle(item.parts[j], options));\n }\n\n stylesInDom[item.id] = {\n id: item.id,\n refs: 1,\n parts: parts\n };\n }\n }\n}\n\nfunction insertStyleElement(options) {\n var style = document.createElement('style');\n\n if (typeof options.attributes.nonce === 'undefined') {\n var nonce = typeof __webpack_nonce__ !== 'undefined' ? __webpack_nonce__ : null;\n\n if (nonce) {\n options.attributes.nonce = nonce;\n }\n }\n\n Object.keys(options.attributes).forEach(function (key) {\n style.setAttribute(key, options.attributes[key]);\n });\n\n if (typeof options.insert === 'function') {\n options.insert(style);\n } else {\n var target = getTarget(options.insert || 'head');\n\n if (!target) {\n throw new Error(\"Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.\");\n }\n\n target.appendChild(style);\n }\n\n return style;\n}\n\nfunction removeStyleElement(style) {\n // istanbul ignore if\n if (style.parentNode === null) {\n return false;\n }\n\n style.parentNode.removeChild(style);\n}\n/* istanbul ignore next */\n\n\nvar replaceText = function replaceText() {\n var textStore = [];\n return function replace(index, replacement) {\n textStore[index] = replacement;\n return textStore.filter(Boolean).join('\\n');\n };\n}();\n\nfunction applyToSingletonTag(style, index, remove, obj) {\n var css = remove ? '' : obj.css; // For old IE\n\n /* istanbul ignore if */\n\n if (style.styleSheet) {\n style.styleSheet.cssText = replaceText(index, css);\n } else {\n var cssNode = document.createTextNode(css);\n var childNodes = style.childNodes;\n\n if (childNodes[index]) {\n style.removeChild(childNodes[index]);\n }\n\n if (childNodes.length) {\n style.insertBefore(cssNode, childNodes[index]);\n } else {\n style.appendChild(cssNode);\n }\n }\n}\n\nfunction applyToTag(style, options, obj) {\n var css = obj.css;\n var media = obj.media;\n var sourceMap = obj.sourceMap;\n\n if (media) {\n style.setAttribute('media', media);\n }\n\n if (sourceMap && btoa) {\n css += \"\\n/*# sourceMappingURL=data:application/json;base64,\".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), \" */\");\n } // For old IE\n\n /* istanbul ignore if */\n\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n while (style.firstChild) {\n style.removeChild(style.firstChild);\n }\n\n style.appendChild(document.createTextNode(css));\n }\n}\n\nvar singleton = null;\nvar singletonCounter = 0;\n\nfunction addStyle(obj, options) {\n var style;\n var update;\n var remove;\n\n if (options.singleton) {\n var styleIndex = singletonCounter++;\n style = singleton || (singleton = insertStyleElement(options));\n update = applyToSingletonTag.bind(null, style, styleIndex, false);\n remove = applyToSingletonTag.bind(null, style, styleIndex, true);\n } else {\n style = insertStyleElement(options);\n update = applyToTag.bind(null, style, options);\n\n remove = function remove() {\n removeStyleElement(style);\n };\n }\n\n update(obj);\n return function updateStyle(newObj) {\n if (newObj) {\n if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap) {\n return;\n }\n\n update(obj = newObj);\n } else {\n remove();\n }\n };\n}\n\nmodule.exports = function (list, options) {\n options = options || {};\n options.attributes = typeof options.attributes === 'object' ? options.attributes : {}; // Force single-tag solution on IE6-9, which has a hard limit on the # of <style>\n // tags it will allow on a page\n\n if (!options.singleton && typeof options.singleton !== 'boolean') {\n options.singleton = isOldIE();\n }\n\n var styles = listToStyles(list, options);\n addStylesToDom(styles, options);\n return function update(newList) {\n var mayRemove = [];\n\n for (var i = 0; i < styles.length; i++) {\n var item = styles[i];\n var domStyle = stylesInDom[item.id];\n\n if (domStyle) {\n domStyle.refs--;\n mayRemove.push(domStyle);\n }\n }\n\n if (newList) {\n var newStyles = listToStyles(newList, options);\n addStylesToDom(newStyles, options);\n }\n\n for (var _i = 0; _i < mayRemove.length; _i++) {\n var _domStyle = mayRemove[_i];\n\n if (_domStyle.refs === 0) {\n for (var j = 0; j < _domStyle.parts.length; j++) {\n _domStyle.parts[j]();\n }\n\n delete stylesInDom[_domStyle.id];\n }\n }\n };\n};","__webpack_public_path__ = OC.linkTo('files_sharing', 'js/dist/');\n__webpack_nonce__ = btoa(OC.requestToken);\n\nimport './share'\nimport './sharetabview'\nimport './sharebreadcrumbview'\n\nimport './style/sharetabview.scss'\nimport './style/sharebreadcrumb.scss'\n\nimport './collaborationresourceshandler.js'\n\nwindow.OCA.Sharing = OCA.Sharing;\n","/*\n * Copyright (c) 2014\n *\n * This file is licensed under the Affero General Public License version 3\n * or later.\n *\n * See the COPYING-README file.\n *\n */\n\n(function() {\n\n\t_.extend(OC.Files.Client, {\n\t\tPROPERTY_SHARE_TYPES:\t'{' + OC.Files.Client.NS_OWNCLOUD + '}share-types',\n\t\tPROPERTY_OWNER_ID:\t'{' + OC.Files.Client.NS_OWNCLOUD + '}owner-id',\n\t\tPROPERTY_OWNER_DISPLAY_NAME:\t'{' + OC.Files.Client.NS_OWNCLOUD + '}owner-display-name'\n\t});\n\n\tif (!OCA.Sharing) {\n\t\tOCA.Sharing = {};\n\t}\n\t/**\n\t * @namespace\n\t */\n\tOCA.Sharing.Util = {\n\t\t/**\n\t\t * Initialize the sharing plugin.\n\t\t *\n\t\t * Registers the \"Share\" file action and adds additional\n\t\t * DOM attributes for the sharing file info.\n\t\t *\n\t\t * @param {OCA.Files.FileList} fileList file list to be extended\n\t\t */\n\t\tattach: function(fileList) {\n\t\t\t// core sharing is disabled/not loaded\n\t\t\tif (!OC.Share) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tif (fileList.id === 'trashbin' || fileList.id === 'files.public') {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tvar fileActions = fileList.fileActions;\n\t\t\tvar oldCreateRow = fileList._createRow;\n\t\t\tfileList._createRow = function(fileData) {\n\n\t\t\t\tvar tr = oldCreateRow.apply(this, arguments);\n\t\t\t\tvar sharePermissions = OCA.Sharing.Util.getSharePermissions(fileData);\n\t\t\t\t\n\t\t\t\tif (fileData.permissions === 0) {\n\t\t\t\t\t// no permission, disabling sidebar\n\t\t\t\t\tdelete fileActions.actions.all.Comment;\n\t\t\t\t\tdelete fileActions.actions.all.Details;\n\t\t\t\t\tdelete fileActions.actions.all.Goto;\n\t\t\t\t}\n\t\t\t\ttr.attr('data-share-permissions', sharePermissions);\n\t\t\t\tif (fileData.shareOwner) {\n\t\t\t\t\ttr.attr('data-share-owner', fileData.shareOwner);\n\t\t\t\t\ttr.attr('data-share-owner-id', fileData.shareOwnerId);\n\t\t\t\t\t// user should always be able to rename a mount point\n\t\t\t\t\tif (fileData.mountType === 'shared-root') {\n\t\t\t\t\t\ttr.attr('data-permissions', fileData.permissions | OC.PERMISSION_UPDATE);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (fileData.recipientData && !_.isEmpty(fileData.recipientData)) {\n\t\t\t\t\ttr.attr('data-share-recipient-data', JSON.stringify(fileData.recipientData));\n\t\t\t\t}\n\t\t\t\tif (fileData.shareTypes) {\n\t\t\t\t\ttr.attr('data-share-types', fileData.shareTypes.join(','));\n\t\t\t\t}\n\t\t\t\treturn tr;\n\t\t\t};\n\n\t\t\tvar oldElementToFile = fileList.elementToFile;\n\t\t\tfileList.elementToFile = function($el) {\n\t\t\t\tvar fileInfo = oldElementToFile.apply(this, arguments);\n\t\t\t\tfileInfo.sharePermissions = $el.attr('data-share-permissions') || undefined;\n\t\t\t\tfileInfo.shareOwner = $el.attr('data-share-owner') || undefined;\n\t\t\t\tfileInfo.shareOwnerId = $el.attr('data-share-owner-id') || undefined;\n\n\t\t\t\tif( $el.attr('data-share-types')){\n\t\t\t\t\tfileInfo.shareTypes = $el.attr('data-share-types').split(',');\n\t\t\t\t}\n\n\t\t\t\tif( $el.attr('data-expiration')){\n\t\t\t\t\tvar expirationTimestamp = parseInt($el.attr('data-expiration'));\n\t\t\t\t\tfileInfo.shares = [];\n\t\t\t\t\tfileInfo.shares.push({expiration: expirationTimestamp});\n\t\t\t\t}\n\n\t\t\t\treturn fileInfo;\n\t\t\t};\n\n\t\t\tvar oldGetWebdavProperties = fileList._getWebdavProperties;\n\t\t\tfileList._getWebdavProperties = function() {\n\t\t\t\tvar props = oldGetWebdavProperties.apply(this, arguments);\n\t\t\t\tprops.push(OC.Files.Client.PROPERTY_OWNER_ID);\n\t\t\t\tprops.push(OC.Files.Client.PROPERTY_OWNER_DISPLAY_NAME);\n\t\t\t\tprops.push(OC.Files.Client.PROPERTY_SHARE_TYPES);\n\t\t\t\treturn props;\n\t\t\t};\n\n\t\t\tfileList.filesClient.addFileInfoParser(function(response) {\n\t\t\t\tvar data = {};\n\t\t\t\tvar props = response.propStat[0].properties;\n\t\t\t\tvar permissionsProp = props[OC.Files.Client.PROPERTY_PERMISSIONS];\n\n\t\t\t\tif (permissionsProp && permissionsProp.indexOf('S') >= 0) {\n\t\t\t\t\tdata.shareOwner = props[OC.Files.Client.PROPERTY_OWNER_DISPLAY_NAME];\n\t\t\t\t\tdata.shareOwnerId = props[OC.Files.Client.PROPERTY_OWNER_ID];\n\t\t\t\t}\n\n\t\t\t\tvar shareTypesProp = props[OC.Files.Client.PROPERTY_SHARE_TYPES];\n\t\t\t\tif (shareTypesProp) {\n\t\t\t\t\tdata.shareTypes = _.chain(shareTypesProp).filter(function(xmlvalue) {\n\t\t\t\t\t\treturn (xmlvalue.namespaceURI === OC.Files.Client.NS_OWNCLOUD && xmlvalue.nodeName.split(':')[1] === 'share-type');\n\t\t\t\t\t}).map(function(xmlvalue) {\n\t\t\t\t\t\treturn parseInt(xmlvalue.textContent || xmlvalue.text, 10);\n\t\t\t\t\t}).value();\n\t\t\t\t}\n\n\t\t\t\treturn data;\n\t\t\t});\n\n\t\t\t// use delegate to catch the case with multiple file lists\n\t\t\tfileList.$el.on('fileActionsReady', function(ev){\n\t\t\t\tvar $files = ev.$files;\n\n\t\t\t\t_.each($files, function(file) {\n\t\t\t\t\tvar $tr = $(file);\n\t\t\t\t\tvar shareTypes = $tr.attr('data-share-types') || '';\n\t\t\t\t\tvar shareOwner = $tr.attr('data-share-owner');\n\t\t\t\t\tif (shareTypes || shareOwner) {\n\t\t\t\t\t\tvar hasLink = false;\n\t\t\t\t\t\tvar hasShares = false;\n\t\t\t\t\t\t_.each(shareTypes.split(',') || [], function(shareType) {\n\t\t\t\t\t\t\tshareType = parseInt(shareType, 10);\n\t\t\t\t\t\t\tif (shareType === OC.Share.SHARE_TYPE_LINK) {\n\t\t\t\t\t\t\t\thasLink = true;\n\t\t\t\t\t\t\t} else if (shareType === OC.Share.SHARE_TYPE_EMAIL) {\n\t\t\t\t\t\t\t\thasLink = true;\n\t\t\t\t\t\t\t} else if (shareType === OC.Share.SHARE_TYPE_USER) {\n\t\t\t\t\t\t\t\thasShares = true;\n\t\t\t\t\t\t\t} else if (shareType === OC.Share.SHARE_TYPE_GROUP) {\n\t\t\t\t\t\t\t\thasShares = true;\n\t\t\t\t\t\t\t} else if (shareType === OC.Share.SHARE_TYPE_REMOTE) {\n\t\t\t\t\t\t\t\thasShares = true;\n\t\t\t\t\t\t\t} else if (shareType === OC.Share.SHARE_TYPE_CIRCLE) {\n\t\t\t\t\t\t\t\thasShares = true;\n\t\t\t\t\t\t\t} else if (shareType === OC.Share.SHARE_TYPE_ROOM) {\n\t\t\t\t\t\t\t\thasShares = true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t\tOCA.Sharing.Util._updateFileActionIcon($tr, hasShares, hasLink);\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t});\n\n\n\t\t\tfileList.$el.on('changeDirectory', function() {\n\t\t\t\tOCA.Sharing.sharesLoaded = false;\n\t\t\t});\n\n\t\t\tfileActions.registerAction({\n\t\t\t\tname: 'Share',\n\t\t\t\tdisplayName: function(context) {\n\t\t\t\t\tif (context && context.$file) {\n\t\t\t\t\t\tvar shareType = parseInt(context.$file.data('share-types'), 10)\n\t\t\t\t\t\tvar shareOwner = context.$file.data('share-owner-id')\n\t\t\t\t\t\tif (shareType >= 0 || shareOwner) {\n\t\t\t\t\t\t\treturn t('core', 'Shared')\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\treturn t('core', 'Share')\n\t\t\t\t},\n\t\t\t\taltText: t('core', 'Share'),\n\t\t\t\tmime: 'all',\n\t\t\t\torder: -150,\n\t\t\t\tpermissions: OC.PERMISSION_ALL,\n\t\t\t\ticonClass: function(fileName, context) {\n\t\t\t\t\tvar shareType = parseInt(context.$file.data('share-types'), 10)\n\t\t\t\t\tif (shareType === OC.Share.SHARE_TYPE_EMAIL\n\t\t\t\t\t\t|| shareType === OC.Share.SHARE_TYPE_LINK) {\n\t\t\t\t\t\treturn 'icon-public'\n\t\t\t\t\t}\n\t\t\t\t\treturn 'icon-shared'\n\t\t\t\t},\n\t\t\t\ticon: function(fileName, context) {\n\t\t\t\t\tvar shareOwner = context.$file.data('share-owner-id')\n\t\t\t\t\tif (shareOwner) {\n\t\t\t\t\t\treturn OC.generateUrl(`/avatar/${shareOwner}/32`)\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\ttype: OCA.Files.FileActions.TYPE_INLINE,\n\t\t\t\tactionHandler: function(fileName, context) {\n\t\t\t\t\t// do not open sidebar if permission is set and equal to 0\n\t\t\t\t\tvar permissions = parseInt(context.$file.data('share-permissions'), 10);\n\t\t\t\t\tif (isNaN(permissions) || permissions > 0) {\n\t\t\t\t\t\tfileList.showDetailsView(fileName, 'shareTabView');\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\trender: function(actionSpec, isDefault, context) {\n\t\t\t\t\tvar permissions = parseInt(context.$file.data('permissions'), 10);\n\t\t\t\t\t// if no share permissions but share owner exists, still show the link\n\t\t\t\t\tif ((permissions & OC.PERMISSION_SHARE) !== 0 || context.$file.attr('data-share-owner')) {\n\t\t\t\t\t\treturn fileActions._defaultRenderAction.call(fileActions, actionSpec, isDefault, context);\n\t\t\t\t\t}\n\t\t\t\t\t// don't render anything\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t});\n\n\t\t\tvar shareTab = new OCA.Sharing.ShareTabView('shareTabView', {order: -20});\n\t\t\t// detect changes and change the matching list entry\n\t\t\tshareTab.on('sharesChanged', function(shareModel) {\n\t\t\t\tvar fileInfoModel = shareModel.fileInfoModel;\n\t\t\t\tvar $tr = fileList.findFileEl(fileInfoModel.get('name'));\n\n\t\t\t\t// We count email shares as link share\n\t\t\t\tvar hasLinkShares = shareModel.hasLinkShares();\n\t\t\t\tshareModel.get('shares').forEach(function (share) {\n\t\t\t\t\tif (share.share_type === OC.Share.SHARE_TYPE_EMAIL) {\n\t\t\t\t\t\thasLinkShares = true;\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tOCA.Sharing.Util._updateFileListDataAttributes(fileList, $tr, shareModel);\n\t\t\t\tif (!OCA.Sharing.Util._updateFileActionIcon($tr, shareModel.hasUserShares(), hasLinkShares)) {\n\t\t\t\t\t// remove icon, if applicable\n\t\t\t\t\tOC.Share.markFileAsShared($tr, false, false);\n\t\t\t\t}\n\n\t\t\t\t// FIXME: this is too convoluted. We need to get rid of the above updates\n\t\t\t\t// and only ever update the model and let the events take care of rerendering\n\t\t\t\tfileInfoModel.set({\n\t\t\t\t\tshareTypes: shareModel.getShareTypes(),\n\t\t\t\t\t// in case markFileAsShared decided to change the icon,\n\t\t\t\t\t// we need to modify the model\n\t\t\t\t\t// (FIXME: yes, this is hacky)\n\t\t\t\t\ticon: $tr.attr('data-icon')\n\t\t\t\t});\n\t\t\t});\n\t\t\tfileList.registerTabView(shareTab);\n\n\t\t\tvar breadCrumbSharingDetailView = new OCA.Sharing.ShareBreadCrumbView({shareTab: shareTab});\n\t\t\tfileList.registerBreadCrumbDetailView(breadCrumbSharingDetailView);\n\t\t},\n\n\t\t/**\n\t\t * Update file list data attributes\n\t\t */\n\t\t_updateFileListDataAttributes: function(fileList, $tr, shareModel) {\n\t\t\t// files app current cannot show recipients on load, so we don't update the\n\t\t\t// icon when changed for consistency\n\t\t\tif (fileList.id === 'files') {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tvar recipients = _.pluck(shareModel.get('shares'), 'share_with_displayname');\n\t\t\t// note: we only update the data attribute because updateIcon()\n\t\t\tif (recipients.length) {\n\t\t\t\tvar recipientData = _.mapObject(shareModel.get('shares'), function (share) {\n\t\t\t\t\treturn {shareWith: share.share_with, shareWithDisplayName: share.share_with_displayname};\n\t\t\t\t});\n\t\t\t\t$tr.attr('data-share-recipient-data', JSON.stringify(recipientData));\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$tr.removeAttr('data-share-recipient-data');\n\t\t\t}\n\t\t},\n\n\t\t/**\n\t\t * Update the file action share icon for the given file\n\t\t *\n\t\t * @param $tr file element of the file to update\n\t\t * @param {boolean} hasUserShares true if a user share exists\n\t\t * @param {boolean} hasLinkShares true if a link share exists\n\t\t *\n\t\t * @return {boolean} true if the icon was set, false otherwise\n\t\t */\n\t\t_updateFileActionIcon: function($tr, hasUserShares, hasLinkShares) {\n\t\t\t// if the statuses are loaded already, use them for the icon\n\t\t\t// (needed when scrolling to the next page)\n\t\t\tif (hasUserShares || hasLinkShares || $tr.attr('data-share-recipient-data') || $tr.attr('data-share-owner')) {\n\t\t\t\tOC.Share.markFileAsShared($tr, true, hasLinkShares);\n\t\t\t\treturn true;\n\t\t\t}\n\t\t\treturn false;\n\t\t},\n\n\t\t/**\n\t\t * @param {Array} fileData\n\t\t * @returns {String}\n\t\t */\n\t\tgetSharePermissions: function(fileData) {\n\t\t\treturn fileData.sharePermissions;\n\t\t}\n\t};\n})();\n\nOC.Plugins.register('OCA.Files.FileList', OCA.Sharing.Util);\n","/*\n * Copyright (c) 2015\n *\n * This file is licensed under the Affero General Public License version 3\n * or later.\n *\n * See the COPYING-README file.\n *\n */\n\n/* @global Handlebars */\n\n(function() {\n\tvar TEMPLATE =\n\t\t'<div>' +\n\t\t'<div class=\"dialogContainer\"></div>' +\n\t\t'<div id=\"collaborationResources\"></div>' +\n\t\t'</div>';\n\n\t/**\n\t * @memberof OCA.Sharing\n\t */\n\tvar ShareTabView = OCA.Files.DetailTabView.extend(\n\t\t/** @lends OCA.Sharing.ShareTabView.prototype */ {\n\t\tid: 'shareTabView',\n\t\tclassName: 'tab shareTabView',\n\n\t\tinitialize: function(name, options) {\n\t\t\tOCA.Files.DetailTabView.prototype.initialize.call(this, name, options);\n\t\t\tOC.Plugins.attach('OCA.Sharing.ShareTabView', this);\n\t\t},\n\n\t\ttemplate: function(params) {\n\t\t\treturn \tTEMPLATE;\n\t\t},\n\n\t\tgetLabel: function() {\n\t\t\treturn t('files_sharing', 'Sharing');\n\t\t},\n\n\t\tgetIcon: function() {\n\t\t\treturn 'icon-shared';\n\t\t},\n\n\t\t/**\n\t\t * Renders this details view\n\t\t */\n\t\trender: function() {\n\t\t\tvar self = this;\n\t\t\tif (this._dialog) {\n\t\t\t\t// remove/destroy older instance\n\t\t\t\tthis._dialog.model.off();\n\t\t\t\tthis._dialog.remove();\n\t\t\t\tthis._dialog = null;\n\t\t\t}\n\n\t\t\tif (this.model) {\n\t\t\t\tthis.$el.html(this.template());\n\n\t\t\t\tif (_.isUndefined(this.model.get('sharePermissions'))) {\n\t\t\t\t\tthis.model.set('sharePermissions', OCA.Sharing.Util.getSharePermissions(this.model.attributes));\n\t\t\t\t}\n\n\t\t\t\t// TODO: the model should read these directly off the passed fileInfoModel\n\t\t\t\tvar attributes = {\n\t\t\t\t\titemType: this.model.isDirectory() ? 'folder' : 'file',\n\t\t\t\t \titemSource: this.model.get('id'),\n\t\t\t\t\tpossiblePermissions: this.model.get('sharePermissions')\n\t\t\t\t};\n\t\t\t\tvar configModel = new OC.Share.ShareConfigModel();\n\t\t\t\tvar shareModel = new OC.Share.ShareItemModel(attributes, {\n\t\t\t\t\tconfigModel: configModel,\n\t\t\t\t\tfileInfoModel: this.model\n\t\t\t\t});\n\t\t\t\tthis._dialog = new OC.Share.ShareDialogView({\n\t\t\t\t\tconfigModel: configModel,\n\t\t\t\t\tmodel: shareModel\n\t\t\t\t});\n\t\t\t\tthis.$el.find('.dialogContainer').append(this._dialog.$el);\n\t\t\t\tthis._dialog.render();\n\t\t\t\tthis._dialog.model.fetch();\n\t\t\t\tthis._dialog.model.on('change', function() {\n\t\t\t\t\tself.trigger('sharesChanged', shareModel);\n\t\t\t\t});\n\n\t\t\t\timport('./collaborationresources').then((Resources) => {\n\t\t\t\t\tvar vm = new Resources.Vue({\n\t\t\t\t\t\tel: '#collaborationResources',\n\t\t\t\t\t\trender: h => h(Resources.View),\n\t\t\t\t\t\tdata: {\n\t\t\t\t\t\t\tmodel: this.model.toJSON()\n\t\t\t\t\t\t},\n\t\t\t\t\t});\n\t\t\t\t\tthis.model.on('change', () => { vm.data = this.model.toJSON() })\n\n\t\t\t\t})\n\n\t\t\t} else {\n\t\t\t\tthis.$el.empty();\n\t\t\t\t// TODO: render placeholder text?\n\t\t\t}\n\t\t\tthis.trigger('rendered');\n\t\t}\n\t});\n\n\tOCA.Sharing.ShareTabView = ShareTabView;\n})();\n\n","/* global Handlebars, OC */\n\n/**\n * @copyright 2016 Christoph Wurst <christoph@winzerhof-wurst.at>\n *\n * @author 2016 Christoph Wurst <christoph@winzerhof-wurst.at>\n *\n * @license GNU AGPL version 3 or any later version\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\n(function() {\n\t'use strict';\n\n\tvar BreadCrumbView = OC.Backbone.View.extend({\n\t\ttagName: 'span',\n\t\tevents: {\n\t\t\tclick: '_onClick'\n\t\t},\n\t\t_dirInfo: undefined,\n\n\t\t/** @type OCA.Sharing.ShareTabView */\n\t\t_shareTab: undefined,\n\n\t\tinitialize: function(options) {\n\t\t\tthis._shareTab = options.shareTab;\n\t\t},\n\n\t\trender: function(data) {\n\t\t\tthis._dirInfo = data.dirInfo || null;\n\n\t\t\tif (this._dirInfo !== null && (this._dirInfo.path !== '/' || this._dirInfo.name !== '')) {\n\t\t\t\tvar isShared = data.dirInfo && data.dirInfo.shareTypes && data.dirInfo.shareTypes.length > 0;\n\t\t\t\tthis.$el.removeClass('shared icon-public icon-shared');\n\t\t\t\tif (isShared) {\n\t\t\t\t\tthis.$el.addClass('shared');\n\t\t\t\t\tif (data.dirInfo.shareTypes.indexOf(OC.Share.SHARE_TYPE_LINK) !== -1) {\n\t\t\t\t\t\tthis.$el.addClass('icon-public');\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthis.$el.addClass('icon-shared');\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tthis.$el.addClass('icon-shared');\n\t\t\t\t}\n\t\t\t\tthis.$el.show();\n\t\t\t\tthis.delegateEvents();\n\t\t\t} else {\n\t\t\t\tthis.$el.removeClass('shared icon-public icon-shared');\n\t\t\t\tthis.$el.hide();\n\t\t\t}\n\n\t\t\treturn this;\n\t\t},\n\t\t_onClick: function(e) {\n\t\t\te.preventDefault();\n\n\t\t\tvar fileInfoModel = new OCA.Files.FileInfoModel(this._dirInfo);\n\t\t\tvar self = this;\n\t\t\tfileInfoModel.on('change', function() {\n\t\t\t\tself.render({\n\t\t\t\t\tdirInfo: self._dirInfo\n\t\t\t\t});\n\t\t\t});\n\t\t\tthis._shareTab.on('sharesChanged', function(shareModel) {\n\t\t\t\tvar shareTypes = [];\n\t\t\t\tvar shares = shareModel.getSharesWithCurrentItem();\n\n\t\t\t\tfor(var i = 0; i < shares.length; i++) {\n\t\t\t\t\tif (shareTypes.indexOf(shares[i].share_type) === -1) {\n\t\t\t\t\t\tshareTypes.push(shares[i].share_type);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (shareModel.hasLinkShares()) {\n\t\t\t\t\tshareTypes.push(OC.Share.SHARE_TYPE_LINK);\n\t\t\t\t}\n\n\t\t\t\t// Since the dirInfo isn't updated we need to do this dark hackery\n\t\t\t\tself._dirInfo.shareTypes = shareTypes;\n\n\t\t\t\tself.render({\n\t\t\t\t\tdirInfo: self._dirInfo\n\t\t\t\t});\n\t\t\t});\n\t\t\tOCA.Files.App.fileList.showDetailsView(fileInfoModel, 'shareTabView');\n\t\t}\n\t});\n\n\tOCA.Sharing.ShareBreadCrumbView = BreadCrumbView;\n})();\n","var content = require(\"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/sass-loader/lib/loader.js!./sharetabview.scss\");\n\nif (typeof content === 'string') {\n content = [[module.id, content, '']];\n}\n\nvar options = {}\n\noptions.insert = \"head\";\noptions.singleton = false;\n\nvar update = require(\"!../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\")(content, options);\n\nif (content.locals) {\n module.exports = content.locals;\n}\n","exports = module.exports = require(\"../../../../node_modules/css-loader/dist/runtime/api.js\")(false);\n// Module\nexports.push([module.id, \".app-files .shareTabView {\\n min-height: 100px; }\\n\\n.share-autocomplete-item {\\n display: flex; }\\n .share-autocomplete-item.merged {\\n margin-left: 32px; }\\n .share-autocomplete-item .autocomplete-item-text {\\n margin-left: 10px;\\n margin-right: 10px;\\n white-space: nowrap;\\n text-overflow: ellipsis;\\n overflow: hidden;\\n line-height: 32px;\\n vertical-align: middle;\\n flex-grow: 1; }\\n .share-autocomplete-item .autocomplete-item-text .ui-state-highlight {\\n border: none;\\n margin: 0; }\\n .share-autocomplete-item.with-description .autocomplete-item-text {\\n line-height: 100%; }\\n .share-autocomplete-item .autocomplete-item-details {\\n display: block;\\n line-height: 130%;\\n font-size: 90%;\\n opacity: 0.7; }\\n .share-autocomplete-item .icon {\\n opacity: .7;\\n margin-right: 7px; }\\n .share-autocomplete-item .icon.search-globally {\\n width: 32px;\\n height: 32px;\\n margin-right: 0; }\\n\\n.shareTabView .oneline {\\n white-space: nowrap;\\n position: relative; }\\n\\n.shareTabView .shareWithLoading {\\n padding-left: 10px;\\n right: 35px;\\n top: 3px; }\\n\\n.shareTabView .shareWithConfirm {\\n position: absolute;\\n right: 2px;\\n top: 6px;\\n padding: 14px;\\n opacity: 0.5; }\\n\\n.shareTabView .shareWithField:focus ~ .shareWithConfirm {\\n opacity: 1; }\\n\\n.shareTabView .linkMore {\\n position: absolute;\\n right: -7px;\\n top: -4px;\\n padding: 14px; }\\n\\n.shareTabView .popovermenu {\\n /* Border above last entry '+ Add another share' to separate it from current link settings */ }\\n .shareTabView .popovermenu .linkPassMenu input.error {\\n border-color: var(--color-error) !important; }\\n .shareTabView .popovermenu .linkPassMenu input.error[type=\\\"submit\\\"] {\\n border-left: none; }\\n .shareTabView .popovermenu .linkPassMenu .share-pass-submit {\\n width: auto !important; }\\n .shareTabView .popovermenu .linkPassMenu .icon-loading-small {\\n background-color: var(--color-main-background);\\n position: absolute;\\n right: 8px;\\n margin: 3px;\\n padding: 10px;\\n width: 32px;\\n height: 32px;\\n z-index: 10; }\\n .shareTabView .popovermenu .datepicker {\\n margin-left: 35px; }\\n .shareTabView .popovermenu .share-add input.share-note-delete {\\n border: none;\\n background-color: transparent;\\n width: 44px !important;\\n padding: 0;\\n flex: 0 0 44px;\\n margin-left: auto; }\\n .shareTabView .popovermenu .share-add input.share-note-delete.hidden {\\n display: none; }\\n .shareTabView .popovermenu .share-note-form span.icon-note {\\n position: relative; }\\n .shareTabView .popovermenu .share-note-form textarea.share-note {\\n margin: 0;\\n width: 200px;\\n min-height: 70px;\\n resize: none; }\\n .shareTabView .popovermenu .share-note-form textarea.share-note + input.share-note-submit {\\n position: absolute;\\n width: 44px !important;\\n height: 44px;\\n bottom: 0px;\\n right: 10px;\\n margin: 0;\\n background-color: transparent;\\n border: none;\\n opacity: .7; }\\n .shareTabView .popovermenu .share-note-form textarea.share-note + input.share-note-submit:hover, .shareTabView .popovermenu .share-note-form textarea.share-note + input.share-note-submit:focus, .shareTabView .popovermenu .share-note-form textarea.share-note + input.share-note-submit:active {\\n opacity: 1; }\\n .shareTabView .popovermenu .share-note-form.share-note-link {\\n margin-bottom: 10px; }\\n .shareTabView .popovermenu .new-share {\\n border-top: 1px solid var(--color-border); }\\n\\n.shareTabView .linkPass .icon-loading-small {\\n margin-right: 0px; }\\n\\n.shareTabView .icon {\\n background-size: 16px 16px; }\\n\\n.shareTabView .shareWithList .icon-loading-small:not(.hidden) + span,\\n.shareTabView .linkShareView .icon-loading-small:not(.hidden) + input + label:before {\\n /* Hide if loader is visible */\\n display: none !important; }\\n\\n.shareTabView input[type='checkbox'] {\\n margin: 0 3px 0 8px;\\n vertical-align: middle; }\\n\\n.shareTabView input[type='text'].shareWithField, .shareTabView input[type='text'].emailField {\\n width: 100%;\\n box-sizing: border-box;\\n padding-right: 32px;\\n text-overflow: ellipsis; }\\n\\n.shareTabView input[type='text'].linkText .shareTabView input[type='password'].linkPassText, .shareTabView input[type='password'].passwordField {\\n width: 180px !important; }\\n\\n.shareTabView form {\\n font-size: 100%;\\n margin-left: 0;\\n margin-right: 0; }\\n\\n.shareTabView .share-note {\\n border-radius: var(--border-radius);\\n margin-bottom: 10px;\\n margin-left: 37px; }\\n\\n.shareWithList {\\n list-style-type: none;\\n display: flex;\\n flex-direction: column; }\\n .shareWithList > li {\\n height: 44px;\\n white-space: normal;\\n display: inline-flex;\\n align-items: center;\\n position: relative; }\\n .shareWithList > li .avatar {\\n width: 32px;\\n height: 32px;\\n background-color: var(--color-primary); }\\n .shareWithList .unshare img {\\n vertical-align: text-bottom;\\n /* properly align icons */ }\\n .shareWithList .sharingOptionsGroup {\\n margin-left: auto;\\n display: flex;\\n align-items: center;\\n white-space: nowrap; }\\n .shareWithList .sharingOptionsGroup > .icon:not(.hidden),\\n .shareWithList .sharingOptionsGroup .share-menu > .icon:not(.hidden) {\\n padding: 14px;\\n height: 44px;\\n width: 44px;\\n opacity: .5;\\n display: block;\\n cursor: pointer; }\\n .shareWithList .sharingOptionsGroup > .icon:not(.hidden):hover, .shareWithList .sharingOptionsGroup > .icon:not(.hidden):focus, .shareWithList .sharingOptionsGroup > .icon:not(.hidden):active,\\n .shareWithList .sharingOptionsGroup .share-menu > .icon:not(.hidden):hover,\\n .shareWithList .sharingOptionsGroup .share-menu > .icon:not(.hidden):focus,\\n .shareWithList .sharingOptionsGroup .share-menu > .icon:not(.hidden):active {\\n opacity: .7; }\\n .shareWithList .sharingOptionsGroup > .share-menu {\\n position: relative;\\n display: block; }\\n .shareWithList .username {\\n padding: 0 8px;\\n overflow: hidden;\\n white-space: nowrap;\\n text-overflow: ellipsis; }\\n\\n.ui-autocomplete {\\n /* limit dropdown height to 6 1/2 entries */\\n max-height: calc(36px * 6.5);\\n overflow-y: auto;\\n overflow-x: hidden;\\n z-index: 1550 !important; }\\n\\n.notCreatable {\\n padding-left: 12px;\\n padding-top: 12px;\\n color: var(--color-text-lighter); }\\n\\n.contactsmenu-popover {\\n left: -6px;\\n right: auto;\\n padding: 3px 6px;\\n top: 100%;\\n margin-top: 0; }\\n .contactsmenu-popover li.hidden {\\n display: none !important; }\\n .contactsmenu-popover:after {\\n left: 8px;\\n right: auto; }\\n\\n.reshare,\\n#link label,\\n#expiration label {\\n display: inline-flex;\\n align-items: center; }\\n .reshare .avatar,\\n #link label .avatar,\\n #expiration label .avatar {\\n margin-right: 5px; }\\n\\n.resharerInfoView.subView {\\n position: relative; }\\n\", \"\"]);\n","var content = require(\"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/sass-loader/lib/loader.js!./sharebreadcrumb.scss\");\n\nif (typeof content === 'string') {\n content = [[module.id, content, '']];\n}\n\nvar options = {}\n\noptions.insert = \"head\";\noptions.singleton = false;\n\nvar update = require(\"!../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\")(content, options);\n\nif (content.locals) {\n module.exports = content.locals;\n}\n","exports = module.exports = require(\"../../../../node_modules/css-loader/dist/runtime/api.js\")(false);\n// Module\nexports.push([module.id, \"/**\\n * @copyright 2016 Christoph Wurst <christoph@winzerhof-wurst.at>\\n *\\n * @author 2016 Christoph Wurst <christoph@winzerhof-wurst.at>\\n *\\n * @license GNU AGPL version 3 or any later version\\n *\\n * This program is free software: you can redistribute it and/or modify\\n * it under the terms of the GNU Affero General Public License as\\n * published by the Free Software Foundation, either version 3 of the\\n * License, or (at your option) any later version.\\n *\\n * This program is distributed in the hope that it will be useful,\\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\\n * GNU Affero General Public License for more details.\\n *\\n * You should have received a copy of the GNU Affero General Public License\\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\\n *\\n */\\ndiv.crumb span.icon-shared,\\ndiv.crumb span.icon-public {\\n display: inline-block;\\n cursor: pointer;\\n opacity: 0.2;\\n margin-right: 6px; }\\n\\ndiv.crumb span.icon-shared.shared,\\ndiv.crumb span.icon-public.shared {\\n opacity: 0.7; }\\n\", \"\"]);\n"],"sourceRoot":""} \ No newline at end of file
+{"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///./apps/files_sharing/src/collaborationresourceshandler.js","webpack:///./node_modules/css-loader/dist/runtime/api.js","webpack:///./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js","webpack:///./apps/files_sharing/src/additionalScripts.js","webpack:///./apps/files_sharing/src/share.js","webpack:///./apps/files_sharing/src/sharetabview.js","webpack:///./apps/files_sharing/src/sharebreadcrumbview.js","webpack:///./apps/files_sharing/src/style/sharetabview.scss?91ba","webpack:///./apps/files_sharing/src/style/sharetabview.scss","webpack:///./apps/files_sharing/src/style/sharebreadcrumb.scss?eb86","webpack:///./apps/files_sharing/src/style/sharebreadcrumb.scss"],"names":["webpackJsonpCallback","data","moduleId","chunkId","chunkIds","moreModules","i","resolves","length","Object","prototype","hasOwnProperty","call","installedChunks","push","modules","parentJsonpFunction","shift","installedModules","0","1","__webpack_require__","exports","module","l","e","promises","installedChunkData","promise","Promise","resolve","reject","onScriptComplete","script","document","createElement","charset","timeout","nc","setAttribute","src","p","jsonpScriptSrc","error","Error","event","onerror","onload","clearTimeout","chunk","errorType","type","realSrc","target","message","name","request","undefined","setTimeout","head","appendChild","all","m","c","d","getter","o","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","oe","err","console","jsonpArray","window","oldJsonpFunction","slice","s","__webpack_public_path__","OC","linkTo","__webpack_nonce__","btoa","requestToken","OCP","Collaboration","registerType","action","dialogs","filepicker","f","Files","getClient","getFileInfo","then","status","fileInfo","id","fail","FILEPICKER_TYPE_CHOOSE","allowDirectoryChooser","typeString","typeIconClass","useSourceMap","list","toString","this","map","item","content","cssMapping","sourceMapping","sourceMap","base64","unescape","encodeURIComponent","JSON","stringify","concat","sourceURLs","sources","source","sourceRoot","join","cssWithMappingToString","mediaQuery","alreadyImportedModules","_i","memo","stylesInDom","isOldIE","Boolean","atob","getTarget","styleTarget","querySelector","HTMLIFrameElement","contentDocument","listToStyles","options","styles","newStyles","base","part","css","media","parts","addStylesToDom","domStyle","j","refs","addStyle","insertStyleElement","style","attributes","nonce","keys","forEach","insert","textStore","replaceText","index","replacement","filter","applyToSingletonTag","remove","obj","styleSheet","cssText","cssNode","createTextNode","childNodes","removeChild","insertBefore","singleton","singletonCounter","update","styleIndex","firstChild","parentNode","removeStyleElement","newObj","newList","mayRemove","_domStyle","OCA","Sharing","_","extend","Client","PROPERTY_SHARE_TYPES","NS_OWNCLOUD","PROPERTY_OWNER_ID","PROPERTY_OWNER_DISPLAY_NAME","Util","attach","fileList","Share","fileActions","oldCreateRow","_createRow","fileData","tr","apply","arguments","sharePermissions","getSharePermissions","permissions","actions","Comment","Details","Goto","attr","shareOwner","shareOwnerId","mountType","PERMISSION_UPDATE","recipientData","isEmpty","shareTypes","oldElementToFile","elementToFile","$el","split","expirationTimestamp","parseInt","shares","expiration","oldGetWebdavProperties","_getWebdavProperties","props","filesClient","addFileInfoParser","response","propStat","properties","permissionsProp","PROPERTY_PERMISSIONS","indexOf","shareTypesProp","chain","xmlvalue","namespaceURI","nodeName","textContent","text","on","ev","$files","each","file","$tr","$","hasLink","hasShares","shareType","SHARE_TYPE_LINK","SHARE_TYPE_EMAIL","SHARE_TYPE_USER","SHARE_TYPE_GROUP","SHARE_TYPE_REMOTE","SHARE_TYPE_CIRCLE","SHARE_TYPE_ROOM","_updateFileActionIcon","sharesLoaded","registerAction","displayName","context","$file","altText","mime","order","PERMISSION_ALL","iconClass","fileName","icon","generateUrl","FileActions","TYPE_INLINE","actionHandler","isNaN","showDetailsView","render","actionSpec","isDefault","PERMISSION_SHARE","_defaultRenderAction","shareTab","ShareTabView","shareModel","fileInfoModel","findFileEl","hasLinkShares","share","share_type","_updateFileListDataAttributes","hasUserShares","markFileAsShared","set","getShareTypes","registerTabView","breadCrumbSharingDetailView","ShareBreadCrumbView","registerBreadCrumbDetailView","pluck","mapObject","shareWith","share_with","shareWithDisplayName","share_with_displayname","removeAttr","Plugins","register","DetailTabView","className","initialize","template","params","getLabel","getIcon","self","_dialog","model","off","html","isUndefined","itemType","isDirectory","itemSource","possiblePermissions","configModel","ShareConfigModel","ShareItemModel","ShareDialogView","find","append","fetch","trigger","Resources","vm","Vue","el","h","View","toJSON","empty","BreadCrumbView","Backbone","tagName","events","click","_dirInfo","_shareTab","dirInfo","path","removeClass","hide","isShared","addClass","show","delegateEvents","_onClick","preventDefault","FileInfoModel","getSharesWithCurrentItem","App","locals"],"mappings":"aACE,SAASA,EAAqBC,GAQ7B,IAPA,IAMIC,EAAUC,EANVC,EAAWH,EAAK,GAChBI,EAAcJ,EAAK,GAKAK,EAAI,EAAGC,EAAW,GACpCD,EAAIF,EAASI,OAAQF,IACzBH,EAAUC,EAASE,GAChBG,OAAOC,UAAUC,eAAeC,KAAKC,EAAiBV,IAAYU,EAAgBV,IACpFI,EAASO,KAAKD,EAAgBV,GAAS,IAExCU,EAAgBV,GAAW,EAE5B,IAAID,KAAYG,EACZI,OAAOC,UAAUC,eAAeC,KAAKP,EAAaH,KACpDa,EAAQb,GAAYG,EAAYH,IAKlC,IAFGc,GAAqBA,EAAoBf,GAEtCM,EAASC,QACdD,EAASU,OAATV,GAOF,IAAIW,EAAmB,GAKnBL,EAAkB,CACrBM,EAAG,EACHC,EAAG,GAWJ,SAASC,EAAoBnB,GAG5B,GAAGgB,EAAiBhB,GACnB,OAAOgB,EAAiBhB,GAAUoB,QAGnC,IAAIC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BAAiB,SAAS2C,GAI3C,IAHA,IAAItE,EAAa,GACbO,EAAS+D,EAAW2E,2BAEhBpX,EAAI,EAAGA,EAAI0O,EAAOxO,OAAQF,KACiB,IAA9CmO,EAAWmB,QAAQZ,EAAO1O,GAAG8S,aAChC3E,EAAW3N,KAAKkO,EAAO1O,GAAG8S,YAIxBL,EAAWG,iBACdzE,EAAW3N,KAAK+E,GAAGsH,MAAM2D,iBAI1BgE,EAAK+B,SAASpI,WAAaA,EAE3BqG,EAAKtC,OAAO,CACXuE,QAASjC,EAAK+B,aAGhBtK,IAAI9F,MAAMkR,IAAIzK,SAASqF,gBAAgBS,EAAe,mBAIxDzG,IAAIC,QAAQoH,oBAAsB4C,EA7EnC,I,gBCxBA,IAAI7O,EAAU,EAAQ,GAEC,iBAAZA,IACTA,EAAU,CAAC,CAACpG,EAAOjB,EAAIqH,EAAS,MAGlC,IAAI8B,EAAU,CAEd,OAAiB,OACjB,WAAoB,GAEP,EAAQ,EAAR,CAA2F9B,EAAS8B,GAE7G9B,EAAQiQ,SACVrW,EAAOD,QAAUqG,EAAQiQ,S,iBCdjBrW,EAAOD,QAAU,EAAQ,EAAR,EAAmE,IAEtFR,KAAK,CAACS,EAAOjB,EAAI,k2NAAm2N,M,gBCF53N,IAAIqH,EAAU,EAAQ,IAEC,iBAAZA,IACTA,EAAU,CAAC,CAACpG,EAAOjB,EAAIqH,EAAS,MAGlC,IAAI8B,EAAU,CAEd,OAAiB,OACjB,WAAoB,GAEP,EAAQ,EAAR,CAA2F9B,EAAS8B,GAE7G9B,EAAQiQ,SACVrW,EAAOD,QAAUqG,EAAQiQ,S,iBCdjBrW,EAAOD,QAAU,EAAQ,EAAR,EAAmE,IAEtFR,KAAK,CAACS,EAAOjB,EAAI,4mCAA6mC","file":"additionalScripts.js","sourcesContent":[" \t// install a JSONP callback for chunk loading\n \tfunction webpackJsonpCallback(data) {\n \t\tvar chunkIds = data[0];\n \t\tvar moreModules = data[1];\n\n\n \t\t// add \"moreModules\" to the modules object,\n \t\t// then flag all \"chunkIds\" as loaded and fire callback\n \t\tvar moduleId, chunkId, i = 0, resolves = [];\n \t\tfor(;i < chunkIds.length; i++) {\n \t\t\tchunkId = chunkIds[i];\n \t\t\tif(Object.prototype.hasOwnProperty.call(installedChunks, chunkId) && installedChunks[chunkId]) {\n \t\t\t\tresolves.push(installedChunks[chunkId][0]);\n \t\t\t}\n \t\t\tinstalledChunks[chunkId] = 0;\n \t\t}\n \t\tfor(moduleId in moreModules) {\n \t\t\tif(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) {\n \t\t\t\tmodules[moduleId] = moreModules[moduleId];\n \t\t\t}\n \t\t}\n \t\tif(parentJsonpFunction) parentJsonpFunction(data);\n\n \t\twhile(resolves.length) {\n \t\t\tresolves.shift()();\n \t\t}\n\n \t};\n\n\n \t// The module cache\n \tvar installedModules = {};\n\n \t// object to store loaded and loading chunks\n \t// undefined = chunk not loaded, null = chunk preloaded/prefetched\n \t// Promise = chunk loading, 0 = chunk loaded\n \tvar installedChunks = {\n \t\t0: 0,\n \t\t1: 0\n \t};\n\n\n\n \t// script path function\n \tfunction jsonpScriptSrc(chunkId) {\n \t\treturn __webpack_require__.p + \"files_sharing.\" + chunkId + \".js?v=\" + {\"3\":\"022dc237b9d1013f3548\",\"4\":\"9213d711eb16a194a232\"}[chunkId] + \"\"\n \t}\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n \t// This file contains only the entry chunk.\n \t// The chunk loading function for additional chunks\n \t__webpack_require__.e = function requireEnsure(chunkId) {\n \t\tvar promises = [];\n\n\n \t\t// JSONP chunk loading for javascript\n\n \t\tvar installedChunkData = installedChunks[chunkId];\n \t\tif(installedChunkData !== 0) { // 0 means \"already installed\".\n\n \t\t\t// a Promise means \"currently loading\".\n \t\t\tif(installedChunkData) {\n \t\t\t\tpromises.push(installedChunkData[2]);\n \t\t\t} else {\n \t\t\t\t// setup Promise in chunk cache\n \t\t\t\tvar promise = new Promise(function(resolve, reject) {\n \t\t\t\t\tinstalledChunkData = installedChunks[chunkId] = [resolve, reject];\n \t\t\t\t});\n \t\t\t\tpromises.push(installedChunkData[2] = promise);\n\n \t\t\t\t// start chunk loading\n \t\t\t\tvar script = document.createElement('script');\n \t\t\t\tvar onScriptComplete;\n\n \t\t\t\tscript.charset = 'utf-8';\n \t\t\t\tscript.timeout = 120;\n \t\t\t\tif (__webpack_require__.nc) {\n \t\t\t\t\tscript.setAttribute(\"nonce\", __webpack_require__.nc);\n \t\t\t\t}\n \t\t\t\tscript.src = jsonpScriptSrc(chunkId);\n\n \t\t\t\t// create error before stack unwound to get useful stacktrace later\n \t\t\t\tvar error = new Error();\n \t\t\t\tonScriptComplete = function (event) {\n \t\t\t\t\t// avoid mem leaks in IE.\n \t\t\t\t\tscript.onerror = script.onload = null;\n \t\t\t\t\tclearTimeout(timeout);\n \t\t\t\t\tvar chunk = installedChunks[chunkId];\n \t\t\t\t\tif(chunk !== 0) {\n \t\t\t\t\t\tif(chunk) {\n \t\t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n \t\t\t\t\t\t\tvar realSrc = event && event.target && event.target.src;\n \t\t\t\t\t\t\terror.message = 'Loading chunk ' + chunkId + ' failed.\\n(' + errorType + ': ' + realSrc + ')';\n \t\t\t\t\t\t\terror.name = 'ChunkLoadError';\n \t\t\t\t\t\t\terror.type = errorType;\n \t\t\t\t\t\t\terror.request = realSrc;\n \t\t\t\t\t\t\tchunk[1](error);\n \t\t\t\t\t\t}\n \t\t\t\t\t\tinstalledChunks[chunkId] = undefined;\n \t\t\t\t\t}\n \t\t\t\t};\n \t\t\t\tvar timeout = setTimeout(function(){\n \t\t\t\t\tonScriptComplete({ type: 'timeout', target: script });\n \t\t\t\t}, 120000);\n \t\t\t\tscript.onerror = script.onload = onScriptComplete;\n \t\t\t\tdocument.head.appendChild(script);\n \t\t\t}\n \t\t}\n \t\treturn Promise.all(promises);\n \t};\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"/js/\";\n\n \t// on error function for async loading\n \t__webpack_require__.oe = function(err) { console.error(err); throw err; };\n\n \tvar jsonpArray = window[\"webpackJsonp\"] = window[\"webpackJsonp\"] || [];\n \tvar oldJsonpFunction = jsonpArray.push.bind(jsonpArray);\n \tjsonpArray.push = webpackJsonpCallback;\n \tjsonpArray = jsonpArray.slice();\n \tfor(var i = 0; i < jsonpArray.length; i++) webpackJsonpCallback(jsonpArray[i]);\n \tvar parentJsonpFunction = oldJsonpFunction;\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 3);\n","__webpack_public_path__ = OC.linkTo('files_sharing', 'js/dist/');\n__webpack_nonce__ = btoa(OC.requestToken);\n\nwindow.OCP.Collaboration.registerType('file', {\n\taction: () => {\n\t\treturn new Promise((resolve, reject) => {\n\t\t\tOC.dialogs.filepicker(t('files_sharing', 'Link to a file'), function (f) {\n\t\t\t\tconst client = OC.Files.getClient();\n\t\t\t\tclient.getFileInfo(f).then((status, fileInfo) => {\n\t\t\t\t\tresolve(fileInfo.id);\n\t\t\t\t}).fail(() => {\n\t\t\t\t\treject();\n\t\t\t\t});\n\t\t\t}, false, null, false, OC.dialogs.FILEPICKER_TYPE_CHOOSE, '', { allowDirectoryChooser: true });\n\t\t});\n\t},\n\ttypeString: t('files_sharing', 'Link to a file'),\n\ttypeIconClass: 'icon-files-dark'\n});\n","\"use strict\";\n\n/*\n MIT License http://www.opensource.org/licenses/mit-license.php\n Author Tobias Koppers @sokra\n*/\n// css base code, injected by the css-loader\n// eslint-disable-next-line func-names\nmodule.exports = function (useSourceMap) {\n var list = []; // return the list of modules as css string\n\n list.toString = function toString() {\n return this.map(function (item) {\n var content = cssWithMappingToString(item, useSourceMap);\n\n if (item[2]) {\n return \"@media \".concat(item[2], \"{\").concat(content, \"}\");\n }\n\n return content;\n }).join('');\n }; // import a list of modules into the list\n // eslint-disable-next-line func-names\n\n\n list.i = function (modules, mediaQuery) {\n if (typeof modules === 'string') {\n // eslint-disable-next-line no-param-reassign\n modules = [[null, modules, '']];\n }\n\n var alreadyImportedModules = {};\n\n for (var i = 0; i < this.length; i++) {\n // eslint-disable-next-line prefer-destructuring\n var id = this[i][0];\n\n if (id != null) {\n alreadyImportedModules[id] = true;\n }\n }\n\n for (var _i = 0; _i < modules.length; _i++) {\n var item = modules[_i]; // skip already imported module\n // this implementation is not 100% perfect for weird media query combinations\n // when a module is imported multiple times with different media queries.\n // I hope this will never occur (Hey this way we have smaller bundles)\n\n if (item[0] == null || !alreadyImportedModules[item[0]]) {\n if (mediaQuery && !item[2]) {\n item[2] = mediaQuery;\n } else if (mediaQuery) {\n item[2] = \"(\".concat(item[2], \") and (\").concat(mediaQuery, \")\");\n }\n\n list.push(item);\n }\n }\n };\n\n return list;\n};\n\nfunction cssWithMappingToString(item, useSourceMap) {\n var content = item[1] || ''; // eslint-disable-next-line prefer-destructuring\n\n var cssMapping = item[3];\n\n if (!cssMapping) {\n return content;\n }\n\n if (useSourceMap && typeof btoa === 'function') {\n var sourceMapping = toComment(cssMapping);\n var sourceURLs = cssMapping.sources.map(function (source) {\n return \"/*# sourceURL=\".concat(cssMapping.sourceRoot).concat(source, \" */\");\n });\n return [content].concat(sourceURLs).concat([sourceMapping]).join('\\n');\n }\n\n return [content].join('\\n');\n} // Adapted from convert-source-map (MIT)\n\n\nfunction toComment(sourceMap) {\n // eslint-disable-next-line no-undef\n var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap))));\n var data = \"sourceMappingURL=data:application/json;charset=utf-8;base64,\".concat(base64);\n return \"/*# \".concat(data, \" */\");\n}","\"use strict\";\n\nvar stylesInDom = {};\n\nvar isOldIE = function isOldIE() {\n var memo;\n return function memorize() {\n if (typeof memo === 'undefined') {\n // Test for IE <= 9 as proposed by Browserhacks\n // @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805\n // Tests for existence of standard globals is to allow style-loader\n // to operate correctly into non-standard environments\n // @see https://github.com/webpack-contrib/style-loader/issues/177\n memo = Boolean(window && document && document.all && !window.atob);\n }\n\n return memo;\n };\n}();\n\nvar getTarget = function getTarget() {\n var memo = {};\n return function memorize(target) {\n if (typeof memo[target] === 'undefined') {\n var styleTarget = document.querySelector(target); // Special case to return head of iframe instead of iframe itself\n\n if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {\n try {\n // This will throw an exception if access to iframe is blocked\n // due to cross-origin restrictions\n styleTarget = styleTarget.contentDocument.head;\n } catch (e) {\n // istanbul ignore next\n styleTarget = null;\n }\n }\n\n memo[target] = styleTarget;\n }\n\n return memo[target];\n };\n}();\n\nfunction listToStyles(list, options) {\n var styles = [];\n var newStyles = {};\n\n for (var i = 0; i < list.length; i++) {\n var item = list[i];\n var id = options.base ? item[0] + options.base : item[0];\n var css = item[1];\n var media = item[2];\n var sourceMap = item[3];\n var part = {\n css: css,\n media: media,\n sourceMap: sourceMap\n };\n\n if (!newStyles[id]) {\n styles.push(newStyles[id] = {\n id: id,\n parts: [part]\n });\n } else {\n newStyles[id].parts.push(part);\n }\n }\n\n return styles;\n}\n\nfunction addStylesToDom(styles, options) {\n for (var i = 0; i < styles.length; i++) {\n var item = styles[i];\n var domStyle = stylesInDom[item.id];\n var j = 0;\n\n if (domStyle) {\n domStyle.refs++;\n\n for (; j < domStyle.parts.length; j++) {\n domStyle.parts[j](item.parts[j]);\n }\n\n for (; j < item.parts.length; j++) {\n domStyle.parts.push(addStyle(item.parts[j], options));\n }\n } else {\n var parts = [];\n\n for (; j < item.parts.length; j++) {\n parts.push(addStyle(item.parts[j], options));\n }\n\n stylesInDom[item.id] = {\n id: item.id,\n refs: 1,\n parts: parts\n };\n }\n }\n}\n\nfunction insertStyleElement(options) {\n var style = document.createElement('style');\n\n if (typeof options.attributes.nonce === 'undefined') {\n var nonce = typeof __webpack_nonce__ !== 'undefined' ? __webpack_nonce__ : null;\n\n if (nonce) {\n options.attributes.nonce = nonce;\n }\n }\n\n Object.keys(options.attributes).forEach(function (key) {\n style.setAttribute(key, options.attributes[key]);\n });\n\n if (typeof options.insert === 'function') {\n options.insert(style);\n } else {\n var target = getTarget(options.insert || 'head');\n\n if (!target) {\n throw new Error(\"Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.\");\n }\n\n target.appendChild(style);\n }\n\n return style;\n}\n\nfunction removeStyleElement(style) {\n // istanbul ignore if\n if (style.parentNode === null) {\n return false;\n }\n\n style.parentNode.removeChild(style);\n}\n/* istanbul ignore next */\n\n\nvar replaceText = function replaceText() {\n var textStore = [];\n return function replace(index, replacement) {\n textStore[index] = replacement;\n return textStore.filter(Boolean).join('\\n');\n };\n}();\n\nfunction applyToSingletonTag(style, index, remove, obj) {\n var css = remove ? '' : obj.css; // For old IE\n\n /* istanbul ignore if */\n\n if (style.styleSheet) {\n style.styleSheet.cssText = replaceText(index, css);\n } else {\n var cssNode = document.createTextNode(css);\n var childNodes = style.childNodes;\n\n if (childNodes[index]) {\n style.removeChild(childNodes[index]);\n }\n\n if (childNodes.length) {\n style.insertBefore(cssNode, childNodes[index]);\n } else {\n style.appendChild(cssNode);\n }\n }\n}\n\nfunction applyToTag(style, options, obj) {\n var css = obj.css;\n var media = obj.media;\n var sourceMap = obj.sourceMap;\n\n if (media) {\n style.setAttribute('media', media);\n }\n\n if (sourceMap && btoa) {\n css += \"\\n/*# sourceMappingURL=data:application/json;base64,\".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), \" */\");\n } // For old IE\n\n /* istanbul ignore if */\n\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n while (style.firstChild) {\n style.removeChild(style.firstChild);\n }\n\n style.appendChild(document.createTextNode(css));\n }\n}\n\nvar singleton = null;\nvar singletonCounter = 0;\n\nfunction addStyle(obj, options) {\n var style;\n var update;\n var remove;\n\n if (options.singleton) {\n var styleIndex = singletonCounter++;\n style = singleton || (singleton = insertStyleElement(options));\n update = applyToSingletonTag.bind(null, style, styleIndex, false);\n remove = applyToSingletonTag.bind(null, style, styleIndex, true);\n } else {\n style = insertStyleElement(options);\n update = applyToTag.bind(null, style, options);\n\n remove = function remove() {\n removeStyleElement(style);\n };\n }\n\n update(obj);\n return function updateStyle(newObj) {\n if (newObj) {\n if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap) {\n return;\n }\n\n update(obj = newObj);\n } else {\n remove();\n }\n };\n}\n\nmodule.exports = function (list, options) {\n options = options || {};\n options.attributes = typeof options.attributes === 'object' ? options.attributes : {}; // Force single-tag solution on IE6-9, which has a hard limit on the # of <style>\n // tags it will allow on a page\n\n if (!options.singleton && typeof options.singleton !== 'boolean') {\n options.singleton = isOldIE();\n }\n\n var styles = listToStyles(list, options);\n addStylesToDom(styles, options);\n return function update(newList) {\n var mayRemove = [];\n\n for (var i = 0; i < styles.length; i++) {\n var item = styles[i];\n var domStyle = stylesInDom[item.id];\n\n if (domStyle) {\n domStyle.refs--;\n mayRemove.push(domStyle);\n }\n }\n\n if (newList) {\n var newStyles = listToStyles(newList, options);\n addStylesToDom(newStyles, options);\n }\n\n for (var _i = 0; _i < mayRemove.length; _i++) {\n var _domStyle = mayRemove[_i];\n\n if (_domStyle.refs === 0) {\n for (var j = 0; j < _domStyle.parts.length; j++) {\n _domStyle.parts[j]();\n }\n\n delete stylesInDom[_domStyle.id];\n }\n }\n };\n};","__webpack_public_path__ = OC.linkTo('files_sharing', 'js/dist/');\n__webpack_nonce__ = btoa(OC.requestToken);\n\nimport './share'\nimport './sharetabview'\nimport './sharebreadcrumbview'\n\nimport './style/sharetabview.scss'\nimport './style/sharebreadcrumb.scss'\n\nimport './collaborationresourceshandler.js'\n\nwindow.OCA.Sharing = OCA.Sharing;\n","/*\n * Copyright (c) 2014\n *\n * This file is licensed under the Affero General Public License version 3\n * or later.\n *\n * See the COPYING-README file.\n *\n */\n\n(function() {\n\n\t_.extend(OC.Files.Client, {\n\t\tPROPERTY_SHARE_TYPES:\t'{' + OC.Files.Client.NS_OWNCLOUD + '}share-types',\n\t\tPROPERTY_OWNER_ID:\t'{' + OC.Files.Client.NS_OWNCLOUD + '}owner-id',\n\t\tPROPERTY_OWNER_DISPLAY_NAME:\t'{' + OC.Files.Client.NS_OWNCLOUD + '}owner-display-name'\n\t});\n\n\tif (!OCA.Sharing) {\n\t\tOCA.Sharing = {};\n\t}\n\t/**\n\t * @namespace\n\t */\n\tOCA.Sharing.Util = {\n\t\t/**\n\t\t * Initialize the sharing plugin.\n\t\t *\n\t\t * Registers the \"Share\" file action and adds additional\n\t\t * DOM attributes for the sharing file info.\n\t\t *\n\t\t * @param {OCA.Files.FileList} fileList file list to be extended\n\t\t */\n\t\tattach: function(fileList) {\n\t\t\t// core sharing is disabled/not loaded\n\t\t\tif (!OC.Share) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tif (fileList.id === 'trashbin' || fileList.id === 'files.public') {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tvar fileActions = fileList.fileActions;\n\t\t\tvar oldCreateRow = fileList._createRow;\n\t\t\tfileList._createRow = function(fileData) {\n\n\t\t\t\tvar tr = oldCreateRow.apply(this, arguments);\n\t\t\t\tvar sharePermissions = OCA.Sharing.Util.getSharePermissions(fileData);\n\t\t\t\t\n\t\t\t\tif (fileData.permissions === 0) {\n\t\t\t\t\t// no permission, disabling sidebar\n\t\t\t\t\tdelete fileActions.actions.all.Comment;\n\t\t\t\t\tdelete fileActions.actions.all.Details;\n\t\t\t\t\tdelete fileActions.actions.all.Goto;\n\t\t\t\t}\n\t\t\t\ttr.attr('data-share-permissions', sharePermissions);\n\t\t\t\tif (fileData.shareOwner) {\n\t\t\t\t\ttr.attr('data-share-owner', fileData.shareOwner);\n\t\t\t\t\ttr.attr('data-share-owner-id', fileData.shareOwnerId);\n\t\t\t\t\t// user should always be able to rename a mount point\n\t\t\t\t\tif (fileData.mountType === 'shared-root') {\n\t\t\t\t\t\ttr.attr('data-permissions', fileData.permissions | OC.PERMISSION_UPDATE);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (fileData.recipientData && !_.isEmpty(fileData.recipientData)) {\n\t\t\t\t\ttr.attr('data-share-recipient-data', JSON.stringify(fileData.recipientData));\n\t\t\t\t}\n\t\t\t\tif (fileData.shareTypes) {\n\t\t\t\t\ttr.attr('data-share-types', fileData.shareTypes.join(','));\n\t\t\t\t}\n\t\t\t\treturn tr;\n\t\t\t};\n\n\t\t\tvar oldElementToFile = fileList.elementToFile;\n\t\t\tfileList.elementToFile = function($el) {\n\t\t\t\tvar fileInfo = oldElementToFile.apply(this, arguments);\n\t\t\t\tfileInfo.sharePermissions = $el.attr('data-share-permissions') || undefined;\n\t\t\t\tfileInfo.shareOwner = $el.attr('data-share-owner') || undefined;\n\t\t\t\tfileInfo.shareOwnerId = $el.attr('data-share-owner-id') || undefined;\n\n\t\t\t\tif( $el.attr('data-share-types')){\n\t\t\t\t\tfileInfo.shareTypes = $el.attr('data-share-types').split(',');\n\t\t\t\t}\n\n\t\t\t\tif( $el.attr('data-expiration')){\n\t\t\t\t\tvar expirationTimestamp = parseInt($el.attr('data-expiration'));\n\t\t\t\t\tfileInfo.shares = [];\n\t\t\t\t\tfileInfo.shares.push({expiration: expirationTimestamp});\n\t\t\t\t}\n\n\t\t\t\treturn fileInfo;\n\t\t\t};\n\n\t\t\tvar oldGetWebdavProperties = fileList._getWebdavProperties;\n\t\t\tfileList._getWebdavProperties = function() {\n\t\t\t\tvar props = oldGetWebdavProperties.apply(this, arguments);\n\t\t\t\tprops.push(OC.Files.Client.PROPERTY_OWNER_ID);\n\t\t\t\tprops.push(OC.Files.Client.PROPERTY_OWNER_DISPLAY_NAME);\n\t\t\t\tprops.push(OC.Files.Client.PROPERTY_SHARE_TYPES);\n\t\t\t\treturn props;\n\t\t\t};\n\n\t\t\tfileList.filesClient.addFileInfoParser(function(response) {\n\t\t\t\tvar data = {};\n\t\t\t\tvar props = response.propStat[0].properties;\n\t\t\t\tvar permissionsProp = props[OC.Files.Client.PROPERTY_PERMISSIONS];\n\n\t\t\t\tif (permissionsProp && permissionsProp.indexOf('S') >= 0) {\n\t\t\t\t\tdata.shareOwner = props[OC.Files.Client.PROPERTY_OWNER_DISPLAY_NAME];\n\t\t\t\t\tdata.shareOwnerId = props[OC.Files.Client.PROPERTY_OWNER_ID];\n\t\t\t\t}\n\n\t\t\t\tvar shareTypesProp = props[OC.Files.Client.PROPERTY_SHARE_TYPES];\n\t\t\t\tif (shareTypesProp) {\n\t\t\t\t\tdata.shareTypes = _.chain(shareTypesProp).filter(function(xmlvalue) {\n\t\t\t\t\t\treturn (xmlvalue.namespaceURI === OC.Files.Client.NS_OWNCLOUD && xmlvalue.nodeName.split(':')[1] === 'share-type');\n\t\t\t\t\t}).map(function(xmlvalue) {\n\t\t\t\t\t\treturn parseInt(xmlvalue.textContent || xmlvalue.text, 10);\n\t\t\t\t\t}).value();\n\t\t\t\t}\n\n\t\t\t\treturn data;\n\t\t\t});\n\n\t\t\t// use delegate to catch the case with multiple file lists\n\t\t\tfileList.$el.on('fileActionsReady', function(ev){\n\t\t\t\tvar $files = ev.$files;\n\n\t\t\t\t_.each($files, function(file) {\n\t\t\t\t\tvar $tr = $(file);\n\t\t\t\t\tvar shareTypes = $tr.attr('data-share-types') || '';\n\t\t\t\t\tvar shareOwner = $tr.attr('data-share-owner');\n\t\t\t\t\tif (shareTypes || shareOwner) {\n\t\t\t\t\t\tvar hasLink = false;\n\t\t\t\t\t\tvar hasShares = false;\n\t\t\t\t\t\t_.each(shareTypes.split(',') || [], function(shareType) {\n\t\t\t\t\t\t\tshareType = parseInt(shareType, 10);\n\t\t\t\t\t\t\tif (shareType === OC.Share.SHARE_TYPE_LINK) {\n\t\t\t\t\t\t\t\thasLink = true;\n\t\t\t\t\t\t\t} else if (shareType === OC.Share.SHARE_TYPE_EMAIL) {\n\t\t\t\t\t\t\t\thasLink = true;\n\t\t\t\t\t\t\t} else if (shareType === OC.Share.SHARE_TYPE_USER) {\n\t\t\t\t\t\t\t\thasShares = true;\n\t\t\t\t\t\t\t} else if (shareType === OC.Share.SHARE_TYPE_GROUP) {\n\t\t\t\t\t\t\t\thasShares = true;\n\t\t\t\t\t\t\t} else if (shareType === OC.Share.SHARE_TYPE_REMOTE) {\n\t\t\t\t\t\t\t\thasShares = true;\n\t\t\t\t\t\t\t} else if (shareType === OC.Share.SHARE_TYPE_CIRCLE) {\n\t\t\t\t\t\t\t\thasShares = true;\n\t\t\t\t\t\t\t} else if (shareType === OC.Share.SHARE_TYPE_ROOM) {\n\t\t\t\t\t\t\t\thasShares = true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t\tOCA.Sharing.Util._updateFileActionIcon($tr, hasShares, hasLink);\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t});\n\n\n\t\t\tfileList.$el.on('changeDirectory', function() {\n\t\t\t\tOCA.Sharing.sharesLoaded = false;\n\t\t\t});\n\n\t\t\tfileActions.registerAction({\n\t\t\t\tname: 'Share',\n\t\t\t\tdisplayName: function(context) {\n\t\t\t\t\tif (context && context.$file) {\n\t\t\t\t\t\tvar shareType = parseInt(context.$file.data('share-types'), 10)\n\t\t\t\t\t\tvar shareOwner = context.$file.data('share-owner-id')\n\t\t\t\t\t\tif (shareType >= 0 || shareOwner) {\n\t\t\t\t\t\t\treturn t('core', 'Shared')\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\treturn t('core', 'Share')\n\t\t\t\t},\n\t\t\t\taltText: t('core', 'Share'),\n\t\t\t\tmime: 'all',\n\t\t\t\torder: -150,\n\t\t\t\tpermissions: OC.PERMISSION_ALL,\n\t\t\t\ticonClass: function(fileName, context) {\n\t\t\t\t\tvar shareType = parseInt(context.$file.data('share-types'), 10)\n\t\t\t\t\tif (shareType === OC.Share.SHARE_TYPE_EMAIL\n\t\t\t\t\t\t|| shareType === OC.Share.SHARE_TYPE_LINK) {\n\t\t\t\t\t\treturn 'icon-public'\n\t\t\t\t\t}\n\t\t\t\t\treturn 'icon-shared'\n\t\t\t\t},\n\t\t\t\ticon: function(fileName, context) {\n\t\t\t\t\tvar shareOwner = context.$file.data('share-owner-id')\n\t\t\t\t\tif (shareOwner) {\n\t\t\t\t\t\treturn OC.generateUrl(`/avatar/${shareOwner}/32`)\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\ttype: OCA.Files.FileActions.TYPE_INLINE,\n\t\t\t\tactionHandler: function(fileName, context) {\n\t\t\t\t\t// do not open sidebar if permission is set and equal to 0\n\t\t\t\t\tvar permissions = parseInt(context.$file.data('share-permissions'), 10);\n\t\t\t\t\tif (isNaN(permissions) || permissions > 0) {\n\t\t\t\t\t\tfileList.showDetailsView(fileName, 'shareTabView');\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\trender: function(actionSpec, isDefault, context) {\n\t\t\t\t\tvar permissions = parseInt(context.$file.data('permissions'), 10);\n\t\t\t\t\t// if no share permissions but share owner exists, still show the link\n\t\t\t\t\tif ((permissions & OC.PERMISSION_SHARE) !== 0 || context.$file.attr('data-share-owner')) {\n\t\t\t\t\t\treturn fileActions._defaultRenderAction.call(fileActions, actionSpec, isDefault, context);\n\t\t\t\t\t}\n\t\t\t\t\t// don't render anything\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t});\n\n\t\t\tvar shareTab = new OCA.Sharing.ShareTabView('shareTabView', {order: -20});\n\t\t\t// detect changes and change the matching list entry\n\t\t\tshareTab.on('sharesChanged', function(shareModel) {\n\t\t\t\tvar fileInfoModel = shareModel.fileInfoModel;\n\t\t\t\tvar $tr = fileList.findFileEl(fileInfoModel.get('name'));\n\n\t\t\t\t// We count email shares as link share\n\t\t\t\tvar hasLinkShares = shareModel.hasLinkShares();\n\t\t\t\tshareModel.get('shares').forEach(function (share) {\n\t\t\t\t\tif (share.share_type === OC.Share.SHARE_TYPE_EMAIL) {\n\t\t\t\t\t\thasLinkShares = true;\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tOCA.Sharing.Util._updateFileListDataAttributes(fileList, $tr, shareModel);\n\t\t\t\tif (!OCA.Sharing.Util._updateFileActionIcon($tr, shareModel.hasUserShares(), hasLinkShares)) {\n\t\t\t\t\t// remove icon, if applicable\n\t\t\t\t\tOC.Share.markFileAsShared($tr, false, false);\n\t\t\t\t}\n\n\t\t\t\t// FIXME: this is too convoluted. We need to get rid of the above updates\n\t\t\t\t// and only ever update the model and let the events take care of rerendering\n\t\t\t\tfileInfoModel.set({\n\t\t\t\t\tshareTypes: shareModel.getShareTypes(),\n\t\t\t\t\t// in case markFileAsShared decided to change the icon,\n\t\t\t\t\t// we need to modify the model\n\t\t\t\t\t// (FIXME: yes, this is hacky)\n\t\t\t\t\ticon: $tr.attr('data-icon')\n\t\t\t\t});\n\t\t\t});\n\t\t\tfileList.registerTabView(shareTab);\n\n\t\t\tvar breadCrumbSharingDetailView = new OCA.Sharing.ShareBreadCrumbView({shareTab: shareTab});\n\t\t\tfileList.registerBreadCrumbDetailView(breadCrumbSharingDetailView);\n\t\t},\n\n\t\t/**\n\t\t * Update file list data attributes\n\t\t */\n\t\t_updateFileListDataAttributes: function(fileList, $tr, shareModel) {\n\t\t\t// files app current cannot show recipients on load, so we don't update the\n\t\t\t// icon when changed for consistency\n\t\t\tif (fileList.id === 'files') {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tvar recipients = _.pluck(shareModel.get('shares'), 'share_with_displayname');\n\t\t\t// note: we only update the data attribute because updateIcon()\n\t\t\tif (recipients.length) {\n\t\t\t\tvar recipientData = _.mapObject(shareModel.get('shares'), function (share) {\n\t\t\t\t\treturn {shareWith: share.share_with, shareWithDisplayName: share.share_with_displayname};\n\t\t\t\t});\n\t\t\t\t$tr.attr('data-share-recipient-data', JSON.stringify(recipientData));\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$tr.removeAttr('data-share-recipient-data');\n\t\t\t}\n\t\t},\n\n\t\t/**\n\t\t * Update the file action share icon for the given file\n\t\t *\n\t\t * @param $tr file element of the file to update\n\t\t * @param {boolean} hasUserShares true if a user share exists\n\t\t * @param {boolean} hasLinkShares true if a link share exists\n\t\t *\n\t\t * @return {boolean} true if the icon was set, false otherwise\n\t\t */\n\t\t_updateFileActionIcon: function($tr, hasUserShares, hasLinkShares) {\n\t\t\t// if the statuses are loaded already, use them for the icon\n\t\t\t// (needed when scrolling to the next page)\n\t\t\tif (hasUserShares || hasLinkShares || $tr.attr('data-share-recipient-data') || $tr.attr('data-share-owner')) {\n\t\t\t\tOC.Share.markFileAsShared($tr, true, hasLinkShares);\n\t\t\t\treturn true;\n\t\t\t}\n\t\t\treturn false;\n\t\t},\n\n\t\t/**\n\t\t * @param {Array} fileData\n\t\t * @returns {String}\n\t\t */\n\t\tgetSharePermissions: function(fileData) {\n\t\t\treturn fileData.sharePermissions;\n\t\t}\n\t};\n})();\n\nOC.Plugins.register('OCA.Files.FileList', OCA.Sharing.Util);\n","/*\n * Copyright (c) 2015\n *\n * This file is licensed under the Affero General Public License version 3\n * or later.\n *\n * See the COPYING-README file.\n *\n */\n\n/* @global Handlebars */\n\n(function() {\n\tvar TEMPLATE =\n\t\t'<div>' +\n\t\t'<div class=\"dialogContainer\"></div>' +\n\t\t'<div id=\"collaborationResources\"></div>' +\n\t\t'</div>';\n\n\t/**\n\t * @memberof OCA.Sharing\n\t */\n\tvar ShareTabView = OCA.Files.DetailTabView.extend(\n\t\t/** @lends OCA.Sharing.ShareTabView.prototype */ {\n\t\tid: 'shareTabView',\n\t\tclassName: 'tab shareTabView',\n\n\t\tinitialize: function(name, options) {\n\t\t\tOCA.Files.DetailTabView.prototype.initialize.call(this, name, options);\n\t\t\tOC.Plugins.attach('OCA.Sharing.ShareTabView', this);\n\t\t},\n\n\t\ttemplate: function(params) {\n\t\t\treturn \tTEMPLATE;\n\t\t},\n\n\t\tgetLabel: function() {\n\t\t\treturn t('files_sharing', 'Sharing');\n\t\t},\n\n\t\tgetIcon: function() {\n\t\t\treturn 'icon-shared';\n\t\t},\n\n\t\t/**\n\t\t * Renders this details view\n\t\t */\n\t\trender: function() {\n\t\t\tvar self = this;\n\t\t\tif (this._dialog) {\n\t\t\t\t// remove/destroy older instance\n\t\t\t\tthis._dialog.model.off();\n\t\t\t\tthis._dialog.remove();\n\t\t\t\tthis._dialog = null;\n\t\t\t}\n\n\t\t\tif (this.model) {\n\t\t\t\tthis.$el.html(this.template());\n\n\t\t\t\tif (_.isUndefined(this.model.get('sharePermissions'))) {\n\t\t\t\t\tthis.model.set('sharePermissions', OCA.Sharing.Util.getSharePermissions(this.model.attributes));\n\t\t\t\t}\n\n\t\t\t\t// TODO: the model should read these directly off the passed fileInfoModel\n\t\t\t\tvar attributes = {\n\t\t\t\t\titemType: this.model.isDirectory() ? 'folder' : 'file',\n\t\t\t\t \titemSource: this.model.get('id'),\n\t\t\t\t\tpossiblePermissions: this.model.get('sharePermissions')\n\t\t\t\t};\n\t\t\t\tvar configModel = new OC.Share.ShareConfigModel();\n\t\t\t\tvar shareModel = new OC.Share.ShareItemModel(attributes, {\n\t\t\t\t\tconfigModel: configModel,\n\t\t\t\t\tfileInfoModel: this.model\n\t\t\t\t});\n\t\t\t\tthis._dialog = new OC.Share.ShareDialogView({\n\t\t\t\t\tconfigModel: configModel,\n\t\t\t\t\tmodel: shareModel\n\t\t\t\t});\n\t\t\t\tthis.$el.find('.dialogContainer').append(this._dialog.$el);\n\t\t\t\tthis._dialog.render();\n\t\t\t\tthis._dialog.model.fetch();\n\t\t\t\tthis._dialog.model.on('change', function() {\n\t\t\t\t\tself.trigger('sharesChanged', shareModel);\n\t\t\t\t});\n\n\t\t\t\timport('./collaborationresources').then((Resources) => {\n\t\t\t\t\tvar vm = new Resources.Vue({\n\t\t\t\t\t\tel: '#collaborationResources',\n\t\t\t\t\t\trender: h => h(Resources.View),\n\t\t\t\t\t\tdata: {\n\t\t\t\t\t\t\tmodel: this.model.toJSON()\n\t\t\t\t\t\t},\n\t\t\t\t\t});\n\t\t\t\t\tthis.model.on('change', () => { vm.data = this.model.toJSON() })\n\n\t\t\t\t})\n\n\t\t\t} else {\n\t\t\t\tthis.$el.empty();\n\t\t\t\t// TODO: render placeholder text?\n\t\t\t}\n\t\t\tthis.trigger('rendered');\n\t\t}\n\t});\n\n\tOCA.Sharing.ShareTabView = ShareTabView;\n})();\n\n","/* global Handlebars, OC */\n\n/**\n * @copyright 2016 Christoph Wurst <christoph@winzerhof-wurst.at>\n *\n * @author 2016 Christoph Wurst <christoph@winzerhof-wurst.at>\n *\n * @license GNU AGPL version 3 or any later version\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\n(function() {\n\t'use strict';\n\n\tvar BreadCrumbView = OC.Backbone.View.extend({\n\t\ttagName: 'span',\n\t\tevents: {\n\t\t\tclick: '_onClick'\n\t\t},\n\t\t_dirInfo: undefined,\n\n\t\t/** @type OCA.Sharing.ShareTabView */\n\t\t_shareTab: undefined,\n\n\t\tinitialize: function(options) {\n\t\t\tthis._shareTab = options.shareTab;\n\t\t},\n\n\t\trender: function(data) {\n\t\t\tthis._dirInfo = data.dirInfo || null;\n\n\t\t\tif (this._dirInfo !== null && (this._dirInfo.path !== '/' || this._dirInfo.name !== '')) {\n\t\t\t\tvar isShared = data.dirInfo && data.dirInfo.shareTypes && data.dirInfo.shareTypes.length > 0;\n\t\t\t\tthis.$el.removeClass('shared icon-public icon-shared');\n\t\t\t\tif (isShared) {\n\t\t\t\t\tthis.$el.addClass('shared');\n\t\t\t\t\tif (data.dirInfo.shareTypes.indexOf(OC.Share.SHARE_TYPE_LINK) !== -1) {\n\t\t\t\t\t\tthis.$el.addClass('icon-public');\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthis.$el.addClass('icon-shared');\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tthis.$el.addClass('icon-shared');\n\t\t\t\t}\n\t\t\t\tthis.$el.show();\n\t\t\t\tthis.delegateEvents();\n\t\t\t} else {\n\t\t\t\tthis.$el.removeClass('shared icon-public icon-shared');\n\t\t\t\tthis.$el.hide();\n\t\t\t}\n\n\t\t\treturn this;\n\t\t},\n\t\t_onClick: function(e) {\n\t\t\te.preventDefault();\n\n\t\t\tvar fileInfoModel = new OCA.Files.FileInfoModel(this._dirInfo);\n\t\t\tvar self = this;\n\t\t\tfileInfoModel.on('change', function() {\n\t\t\t\tself.render({\n\t\t\t\t\tdirInfo: self._dirInfo\n\t\t\t\t});\n\t\t\t});\n\t\t\tthis._shareTab.on('sharesChanged', function(shareModel) {\n\t\t\t\tvar shareTypes = [];\n\t\t\t\tvar shares = shareModel.getSharesWithCurrentItem();\n\n\t\t\t\tfor(var i = 0; i < shares.length; i++) {\n\t\t\t\t\tif (shareTypes.indexOf(shares[i].share_type) === -1) {\n\t\t\t\t\t\tshareTypes.push(shares[i].share_type);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (shareModel.hasLinkShares()) {\n\t\t\t\t\tshareTypes.push(OC.Share.SHARE_TYPE_LINK);\n\t\t\t\t}\n\n\t\t\t\t// Since the dirInfo isn't updated we need to do this dark hackery\n\t\t\t\tself._dirInfo.shareTypes = shareTypes;\n\n\t\t\t\tself.render({\n\t\t\t\t\tdirInfo: self._dirInfo\n\t\t\t\t});\n\t\t\t});\n\t\t\tOCA.Files.App.fileList.showDetailsView(fileInfoModel, 'shareTabView');\n\t\t}\n\t});\n\n\tOCA.Sharing.ShareBreadCrumbView = BreadCrumbView;\n})();\n","var content = require(\"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/sass-loader/lib/loader.js!./sharetabview.scss\");\n\nif (typeof content === 'string') {\n content = [[module.id, content, '']];\n}\n\nvar options = {}\n\noptions.insert = \"head\";\noptions.singleton = false;\n\nvar update = require(\"!../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\")(content, options);\n\nif (content.locals) {\n module.exports = content.locals;\n}\n","exports = module.exports = require(\"../../../../node_modules/css-loader/dist/runtime/api.js\")(false);\n// Module\nexports.push([module.id, \".app-files .shareTabView {\\n min-height: 100px; }\\n\\n.share-autocomplete-item {\\n display: flex; }\\n .share-autocomplete-item.merged {\\n margin-left: 32px; }\\n .share-autocomplete-item .autocomplete-item-text {\\n margin-left: 10px;\\n margin-right: 10px;\\n white-space: nowrap;\\n text-overflow: ellipsis;\\n overflow: hidden;\\n line-height: 32px;\\n vertical-align: middle;\\n flex-grow: 1; }\\n .share-autocomplete-item .autocomplete-item-text .ui-state-highlight {\\n border: none;\\n margin: 0; }\\n .share-autocomplete-item.with-description .autocomplete-item-text {\\n line-height: 100%; }\\n .share-autocomplete-item .autocomplete-item-details {\\n display: block;\\n line-height: 130%;\\n font-size: 90%;\\n opacity: 0.7; }\\n .share-autocomplete-item .icon {\\n opacity: .7;\\n margin-right: 7px; }\\n .share-autocomplete-item .icon.search-globally {\\n width: 32px;\\n height: 32px;\\n margin-right: 0; }\\n\\n.shareTabView .oneline {\\n white-space: nowrap;\\n position: relative; }\\n\\n.shareTabView .shareWithLoading {\\n padding-left: 10px;\\n right: 35px;\\n top: 3px; }\\n\\n.shareTabView .shareWithConfirm {\\n position: absolute;\\n right: 2px;\\n top: 6px;\\n padding: 14px;\\n opacity: 0.5; }\\n\\n.shareTabView .shareWithField:focus ~ .shareWithConfirm {\\n opacity: 1; }\\n\\n.shareTabView .linkMore {\\n position: absolute;\\n right: -7px;\\n top: -4px;\\n padding: 14px; }\\n\\n.shareTabView .popovermenu {\\n /* Border above last entry '+ Add another share' to separate it from current link settings */ }\\n .shareTabView .popovermenu .linkPassMenu input.error {\\n border-color: var(--color-error) !important; }\\n .shareTabView .popovermenu .linkPassMenu input.error[type=\\\"submit\\\"] {\\n border-left: none; }\\n .shareTabView .popovermenu .linkPassMenu .share-pass-submit {\\n width: auto !important; }\\n .shareTabView .popovermenu .linkPassMenu .icon-loading-small {\\n background-color: var(--color-main-background);\\n position: absolute;\\n right: 8px;\\n margin: 3px;\\n padding: 10px;\\n width: 32px;\\n height: 32px;\\n z-index: 10; }\\n .shareTabView .popovermenu .datepicker {\\n margin-left: 35px; }\\n .shareTabView .popovermenu .share-add input.share-note-delete {\\n border: none;\\n background-color: transparent;\\n width: 44px !important;\\n padding: 0;\\n flex: 0 0 44px;\\n margin-left: auto; }\\n .shareTabView .popovermenu .share-add input.share-note-delete.hidden {\\n display: none; }\\n .shareTabView .popovermenu .share-note-form span.icon-note {\\n position: relative; }\\n .shareTabView .popovermenu .share-note-form textarea.share-note {\\n margin: 0;\\n width: 200px;\\n min-height: 70px;\\n resize: none; }\\n .shareTabView .popovermenu .share-note-form textarea.share-note + input.share-note-submit {\\n position: absolute;\\n width: 44px !important;\\n height: 44px;\\n bottom: 0px;\\n right: 10px;\\n margin: 0;\\n background-color: transparent;\\n border: none;\\n opacity: .7; }\\n .shareTabView .popovermenu .share-note-form textarea.share-note + input.share-note-submit:hover, .shareTabView .popovermenu .share-note-form textarea.share-note + input.share-note-submit:focus, .shareTabView .popovermenu .share-note-form textarea.share-note + input.share-note-submit:active {\\n opacity: 1; }\\n .shareTabView .popovermenu .share-note-form.share-note-link {\\n margin-bottom: 10px; }\\n .shareTabView .popovermenu .new-share {\\n border-top: 1px solid var(--color-border); }\\n\\n.shareTabView .linkPass .icon-loading-small {\\n margin-right: 0px; }\\n\\n.shareTabView .icon {\\n background-size: 16px 16px; }\\n\\n.shareTabView .shareWithList .icon-loading-small:not(.hidden) + span,\\n.shareTabView .linkShareView .icon-loading-small:not(.hidden) + input + label:before {\\n /* Hide if loader is visible */\\n display: none !important; }\\n\\n.shareTabView input[type='checkbox'] {\\n margin: 0 3px 0 8px;\\n vertical-align: middle; }\\n\\n.shareTabView input[type='text'].shareWithField, .shareTabView input[type='text'].emailField {\\n width: 100%;\\n box-sizing: border-box;\\n padding-right: 32px;\\n text-overflow: ellipsis; }\\n\\n.shareTabView input[type='text'].linkText .shareTabView input[type='password'].linkPassText, .shareTabView input[type='password'].passwordField {\\n width: 180px !important; }\\n\\n.shareTabView form {\\n font-size: 100%;\\n margin-left: 0;\\n margin-right: 0; }\\n\\n.shareTabView .share-note {\\n border-radius: var(--border-radius);\\n margin-bottom: 10px;\\n margin-left: 37px; }\\n\\n.shareWithList {\\n list-style-type: none;\\n display: flex;\\n flex-direction: column; }\\n .shareWithList > li {\\n height: 44px;\\n white-space: normal;\\n display: inline-flex;\\n align-items: center;\\n position: relative; }\\n .shareWithList > li .avatar {\\n width: 32px;\\n height: 32px;\\n background-color: var(--color-primary); }\\n .shareWithList .unshare img {\\n vertical-align: text-bottom;\\n /* properly align icons */ }\\n .shareWithList .sharingOptionsGroup {\\n margin-left: auto;\\n display: flex;\\n align-items: center;\\n white-space: nowrap; }\\n .shareWithList .sharingOptionsGroup > .icon:not(.hidden),\\n .shareWithList .sharingOptionsGroup .share-menu > .icon:not(.hidden) {\\n padding: 14px;\\n height: 44px;\\n width: 44px;\\n opacity: .5;\\n display: block;\\n cursor: pointer; }\\n .shareWithList .sharingOptionsGroup > .icon:not(.hidden):hover, .shareWithList .sharingOptionsGroup > .icon:not(.hidden):focus, .shareWithList .sharingOptionsGroup > .icon:not(.hidden):active,\\n .shareWithList .sharingOptionsGroup .share-menu > .icon:not(.hidden):hover,\\n .shareWithList .sharingOptionsGroup .share-menu > .icon:not(.hidden):focus,\\n .shareWithList .sharingOptionsGroup .share-menu > .icon:not(.hidden):active {\\n opacity: .7; }\\n .shareWithList .sharingOptionsGroup > .share-menu {\\n position: relative;\\n display: block; }\\n .shareWithList .username {\\n padding: 0 8px;\\n overflow: hidden;\\n white-space: nowrap;\\n text-overflow: ellipsis; }\\n\\n.ui-autocomplete {\\n /* limit dropdown height to 6 1/2 entries */\\n max-height: calc(36px * 6.5);\\n overflow-y: auto;\\n overflow-x: hidden;\\n z-index: 1550 !important; }\\n\\n.notCreatable {\\n padding-left: 12px;\\n padding-top: 12px;\\n color: var(--color-text-lighter); }\\n\\n.contactsmenu-popover {\\n left: -6px;\\n right: auto;\\n padding: 3px 6px;\\n top: 100%;\\n margin-top: 0; }\\n .contactsmenu-popover li.hidden {\\n display: none !important; }\\n .contactsmenu-popover:after {\\n left: 8px;\\n right: auto; }\\n\\n.reshare,\\n#link label,\\n#expiration label {\\n display: inline-flex;\\n align-items: center; }\\n .reshare .avatar,\\n #link label .avatar,\\n #expiration label .avatar {\\n margin-right: 5px; }\\n\\n.resharerInfoView.subView {\\n position: relative; }\\n\", \"\"]);\n","var content = require(\"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/sass-loader/lib/loader.js!./sharebreadcrumb.scss\");\n\nif (typeof content === 'string') {\n content = [[module.id, content, '']];\n}\n\nvar options = {}\n\noptions.insert = \"head\";\noptions.singleton = false;\n\nvar update = require(\"!../../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\")(content, options);\n\nif (content.locals) {\n module.exports = content.locals;\n}\n","exports = module.exports = require(\"../../../../node_modules/css-loader/dist/runtime/api.js\")(false);\n// Module\nexports.push([module.id, \"/**\\n * @copyright 2016 Christoph Wurst <christoph@winzerhof-wurst.at>\\n *\\n * @author 2016 Christoph Wurst <christoph@winzerhof-wurst.at>\\n *\\n * @license GNU AGPL version 3 or any later version\\n *\\n * This program is free software: you can redistribute it and/or modify\\n * it under the terms of the GNU Affero General Public License as\\n * published by the Free Software Foundation, either version 3 of the\\n * License, or (at your option) any later version.\\n *\\n * This program is distributed in the hope that it will be useful,\\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\\n * GNU Affero General Public License for more details.\\n *\\n * You should have received a copy of the GNU Affero General Public License\\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\\n *\\n */\\ndiv.crumb span.icon-shared,\\ndiv.crumb span.icon-public {\\n display: inline-block;\\n cursor: pointer;\\n opacity: 0.2;\\n margin-right: 6px; }\\n\\ndiv.crumb span.icon-shared.shared,\\ndiv.crumb span.icon-public.shared {\\n opacity: 0.7; }\\n\", \"\"]);\n"],"sourceRoot":""} \ No newline at end of file
diff --git a/apps/files_sharing/js/dist/collaboration.js b/apps/files_sharing/js/dist/collaboration.js
index c4532efc927..ecbc52090ba 100644
--- a/apps/files_sharing/js/dist/collaboration.js
+++ b/apps/files_sharing/js/dist/collaboration.js
@@ -1,2 +1,2 @@
-!function(e){var n={};function t(r){if(n[r])return n[r].exports;var i=n[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,t),i.l=!0,i.exports}t.m=e,t.c=n,t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:r})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,n){if(1&n&&(e=t(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(t.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var i in e)t.d(r,i,function(n){return e[n]}.bind(null,i));return r},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},t.p="/js/",t(t.s=0)}([function(e,n,r){r.p=OC.linkTo("files_sharing","js/dist/"),r.nc=btoa(OC.requestToken),window.OCP.Collaboration.registerType("file",{action:function(){return new Promise(function(e,n){OC.dialogs.filepicker(t("files_sharing","Link to a file"),function(t){OC.Files.getClient().getFileInfo(t).then(function(n,t){e(t.id)},function(){n()})},!1)})},typeString:t("files_sharing","Link to a file"),typeIconClass:"icon-files-dark"})}]);
+!function(e){var n={};function t(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,t),o.l=!0,o.exports}t.m=e,t.c=n,t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:r})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,n){if(1&n&&(e=t(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(t.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var o in e)t.d(r,o,function(n){return e[n]}.bind(null,o));return r},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},t.p="/js/",t(t.s=0)}([function(e,n,r){r.p=OC.linkTo("files_sharing","js/dist/"),r.nc=btoa(OC.requestToken),window.OCP.Collaboration.registerType("file",{action:function(){return new Promise(function(e,n){OC.dialogs.filepicker(t("files_sharing","Link to a file"),function(t){OC.Files.getClient().getFileInfo(t).then(function(n,t){e(t.id)}).fail(function(){n()})},!1,null,!1,OC.dialogs.FILEPICKER_TYPE_CHOOSE,"",{allowDirectoryChooser:!0})})},typeString:t("files_sharing","Link to a file"),typeIconClass:"icon-files-dark"})}]);
//# sourceMappingURL=collaboration.js.map \ No newline at end of file
diff --git a/apps/files_sharing/js/dist/collaboration.js.map b/apps/files_sharing/js/dist/collaboration.js.map
index 1f90ae04d34..d3cdc794713 100644
--- a/apps/files_sharing/js/dist/collaboration.js.map
+++ b/apps/files_sharing/js/dist/collaboration.js.map
@@ -1 +1 @@
-{"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///./apps/files_sharing/src/collaborationresourceshandler.js"],"names":["installedModules","__webpack_require__","moduleId","exports","module","i","l","modules","call","m","c","d","name","getter","o","Object","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","prototype","hasOwnProperty","p","s","__webpack_public_path__","OC","linkTo","__webpack_nonce__","btoa","requestToken","window","OCP","Collaboration","registerType","action","Promise","resolve","reject","dialogs","filepicker","f","Files","getClient","getFileInfo","then","status","fileInfo","id","typeString","typeIconClass"],"mappings":"aACE,IAAIA,EAAmB,GAGvB,SAASC,EAAoBC,GAG5B,GAAGF,EAAiBE,GACnB,OAAOF,EAAiBE,GAAUC,QAGnC,IAAIC,EAASJ,EAAiBE,GAAY,CACzCG,EAAGH,EACHI,GAAG,EACHH,QAAS,IAUV,OANAI,EAAQL,GAAUM,KAAKJ,EAAOD,QAASC,EAAQA,EAAOD,QAASF,GAG/DG,EAAOE,GAAI,EAGJF,EAAOD,QAKfF,EAAoBQ,EAAIF,EAGxBN,EAAoBS,EAAIV,EAGxBC,EAAoBU,EAAI,SAASR,EAASS,EAAMC,GAC3CZ,EAAoBa,EAAEX,EAASS,IAClCG,OAAOC,eAAeb,EAASS,EAAM,CAAEK,YAAY,EAAMC,IAAKL,KAKhEZ,EAAoBkB,EAAI,SAAShB,GACX,oBAAXiB,QAA0BA,OAAOC,aAC1CN,OAAOC,eAAeb,EAASiB,OAAOC,YAAa,CAAEC,MAAO,WAE7DP,OAAOC,eAAeb,EAAS,aAAc,CAAEmB,OAAO,KAQvDrB,EAAoBsB,EAAI,SAASD,EAAOE,GAEvC,GADU,EAAPA,IAAUF,EAAQrB,EAAoBqB,IAC/B,EAAPE,EAAU,OAAOF,EACpB,GAAW,EAAPE,GAA8B,iBAAVF,GAAsBA,GAASA,EAAMG,WAAY,OAAOH,EAChF,IAAII,EAAKX,OAAOY,OAAO,MAGvB,GAFA1B,EAAoBkB,EAAEO,GACtBX,OAAOC,eAAeU,EAAI,UAAW,CAAET,YAAY,EAAMK,MAAOA,IACtD,EAAPE,GAA4B,iBAATF,EAAmB,IAAI,IAAIM,KAAON,EAAOrB,EAAoBU,EAAEe,EAAIE,EAAK,SAASA,GAAO,OAAON,EAAMM,IAAQC,KAAK,KAAMD,IAC9I,OAAOF,GAIRzB,EAAoB6B,EAAI,SAAS1B,GAChC,IAAIS,EAAST,GAAUA,EAAOqB,WAC7B,WAAwB,OAAOrB,EAAgB,SAC/C,WAA8B,OAAOA,GAEtC,OADAH,EAAoBU,EAAEE,EAAQ,IAAKA,GAC5BA,GAIRZ,EAAoBa,EAAI,SAASiB,EAAQC,GAAY,OAAOjB,OAAOkB,UAAUC,eAAe1B,KAAKuB,EAAQC,IAGzG/B,EAAoBkC,EAAI,OAIjBlC,EAAoBA,EAAoBmC,EAAI,G,kBClFrDC,IAA0BC,GAAGC,OAAO,gBAAiB,YACrDC,KAAoBC,KAAKH,GAAGI,cAE5BC,OAAOC,IAAIC,cAAcC,aAAa,OAAQ,CAC7CC,OAAQ,WACP,OAAO,IAAIC,QAAQ,SAACC,EAASC,GAC5BZ,GAAGa,QAAQC,WAAW7B,EAAE,gBAAiB,kBAAmB,SAAU8B,GACtDf,GAAGgB,MAAMC,YACjBC,YAAYH,GAAGI,KAAK,SAACC,EAAQC,GACnCV,EAAQU,EAASC,KACf,WACFV,QAEC,MAGLW,WAAYtC,EAAE,gBAAiB,kBAC/BuC,cAAe","file":"collaboration.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"/js/\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 0);\n","__webpack_public_path__ = OC.linkTo('files_sharing', 'js/dist/');\n__webpack_nonce__ = btoa(OC.requestToken);\n\nwindow.OCP.Collaboration.registerType('file', {\n\taction: () => {\n\t\treturn new Promise((resolve, reject) => {\n\t\t\tOC.dialogs.filepicker(t('files_sharing', 'Link to a file'), function (f) {\n\t\t\t\tconst client = OC.Files.getClient();\n\t\t\t\tclient.getFileInfo(f).then((status, fileInfo) => {\n\t\t\t\t\tresolve(fileInfo.id);\n\t\t\t\t}, () => {\n\t\t\t\t\treject();\n\t\t\t\t});\n\t\t\t}, false);\n\t\t});\n\t},\n\ttypeString: t('files_sharing', 'Link to a file'),\n\ttypeIconClass: 'icon-files-dark'\n});\n"],"sourceRoot":""} \ No newline at end of file
+{"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///./apps/files_sharing/src/collaborationresourceshandler.js"],"names":["installedModules","__webpack_require__","moduleId","exports","module","i","l","modules","call","m","c","d","name","getter","o","Object","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","prototype","hasOwnProperty","p","s","__webpack_public_path__","OC","linkTo","__webpack_nonce__","btoa","requestToken","window","OCP","Collaboration","registerType","action","Promise","resolve","reject","dialogs","filepicker","f","Files","getClient","getFileInfo","then","status","fileInfo","id","fail","FILEPICKER_TYPE_CHOOSE","allowDirectoryChooser","typeString","typeIconClass"],"mappings":"aACE,IAAIA,EAAmB,GAGvB,SAASC,EAAoBC,GAG5B,GAAGF,EAAiBE,GACnB,OAAOF,EAAiBE,GAAUC,QAGnC,IAAIC,EAASJ,EAAiBE,GAAY,CACzCG,EAAGH,EACHI,GAAG,EACHH,QAAS,IAUV,OANAI,EAAQL,GAAUM,KAAKJ,EAAOD,QAASC,EAAQA,EAAOD,QAASF,GAG/DG,EAAOE,GAAI,EAGJF,EAAOD,QAKfF,EAAoBQ,EAAI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OAAQ,WACP,OAAO,IAAIC,QAAQ,SAACC,EAASC,GAC5BZ,GAAGa,QAAQC,WAAW7B,EAAE,gBAAiB,kBAAmB,SAAU8B,GACtDf,GAAGgB,MAAMC,YACjBC,YAAYH,GAAGI,KAAK,SAACC,EAAQC,GACnCV,EAAQU,EAASC,MACfC,KAAK,WACPX,QAEC,EAAO,MAAM,EAAOZ,GAAGa,QAAQW,uBAAwB,GAAI,CAAEC,uBAAuB,OAGzFC,WAAYzC,EAAE,gBAAiB,kBAC/B0C,cAAe","file":"collaboration.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"/js/\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 0);\n","__webpack_public_path__ = OC.linkTo('files_sharing', 'js/dist/');\n__webpack_nonce__ = btoa(OC.requestToken);\n\nwindow.OCP.Collaboration.registerType('file', {\n\taction: () => {\n\t\treturn new Promise((resolve, reject) => {\n\t\t\tOC.dialogs.filepicker(t('files_sharing', 'Link to a file'), function (f) {\n\t\t\t\tconst client = OC.Files.getClient();\n\t\t\t\tclient.getFileInfo(f).then((status, fileInfo) => {\n\t\t\t\t\tresolve(fileInfo.id);\n\t\t\t\t}).fail(() => {\n\t\t\t\t\treject();\n\t\t\t\t});\n\t\t\t}, false, null, false, OC.dialogs.FILEPICKER_TYPE_CHOOSE, '', { allowDirectoryChooser: true });\n\t\t});\n\t},\n\ttypeString: t('files_sharing', 'Link to a file'),\n\ttypeIconClass: 'icon-files-dark'\n});\n"],"sourceRoot":""} \ No newline at end of file
diff --git a/apps/files_sharing/src/collaborationresourceshandler.js b/apps/files_sharing/src/collaborationresourceshandler.js
index 8a668b3ce93..32e9f17ad77 100644
--- a/apps/files_sharing/src/collaborationresourceshandler.js
+++ b/apps/files_sharing/src/collaborationresourceshandler.js
@@ -8,10 +8,10 @@ window.OCP.Collaboration.registerType('file', {
const client = OC.Files.getClient();
client.getFileInfo(f).then((status, fileInfo) => {
resolve(fileInfo.id);
- }, () => {
+ }).fail(() => {
reject();
});
- }, false);
+ }, false, null, false, OC.dialogs.FILEPICKER_TYPE_CHOOSE, '', { allowDirectoryChooser: true });
});
},
typeString: t('files_sharing', 'Link to a file'),