1 |
- {"version":3,"file":"files_sharing-additionalScripts.mjs","sources":["../apps/files_sharing/src/share.js","../apps/files_sharing/src/sharebreadcrumbview.js","../apps/files_sharing/src/additionalScripts.js"],"sourcesContent":["/**\n * SPDX-FileCopyrightText: 2016-2024 Nextcloud GmbH and Nextcloud contributors\n * SPDX-FileCopyrightText: 2011-2016 ownCloud, Inc.\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\n/* eslint-disable */\nimport escapeHTML from 'escape-html'\n\nimport { Type as ShareTypes } from '@nextcloud/sharing'\nimport { getCapabilities } from '@nextcloud/capabilities'\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\n\t/**\n\t * @namespace\n\t */\n\tOCA.Sharing.Util = {\n\n\t\t/**\n\t\t * Regular expression for splitting parts of remote share owners:\n\t\t * \"user@example.com/\"\n\t\t * \"user@example.com/path/to/owncloud\"\n\t\t * \"user@anotherexample.com@example.com/path/to/owncloud\n\t\t */\n\t\t_REMOTE_OWNER_REGEXP: new RegExp('^(([^@]*)@(([^@^/\\\\s]*)@)?)((https://)?[^[\\\\s/]*)([/](.*))?$'),\n\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 (!getCapabilities().files_sharing?.api_enabled) {\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\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\tif (_.isFunction(fileData.canDownload) && !fileData.canDownload()) {\n\t\t\t\t\tdelete fileActions.actions.all.Download\n\t\t\t\t\tif ((fileData.permissions & OC.PERMISSION_UPDATE) === 0) {\n\t\t\t\t\t\t// neither move nor copy is allowed, remove the action completely\n\t\t\t\t\t\tdelete fileActions.actions.all.MoveCopy\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\ttr.attr('data-share-permissions', sharePermissions)\n\t\t\t\ttr.attr('data-share-attributes', JSON.stringify(fileData.shareAttributes))\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.shareAttributes = JSON.parse($el.attr('data-share-attributes') || '[]')\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 shareTypesStr = $tr.attr('data-share-types') || ''\n\t\t\t\t\tvar shareOwner = $tr.attr('data-share-owner')\n\t\t\t\t\tif (shareTypesStr || 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(shareTypesStr.split(',') || [], function(shareTypeStr) {\n\t\t\t\t\t\t\tlet shareType = parseInt(shareTypeStr, 10)\n\t\t\t\t\t\t\tif (shareType === ShareTypes.SHARE_TYPE_LINK) {\n\t\t\t\t\t\t\t\thasLink = true\n\t\t\t\t\t\t\t} else if (shareType === ShareTypes.SHARE_TYPE_EMAIL) {\n\t\t\t\t\t\t\t\thasLink = true\n\t\t\t\t\t\t\t} else if (shareType === ShareTypes.SHARE_TYPE_USER) {\n\t\t\t\t\t\t\t\thasShares = true\n\t\t\t\t\t\t\t} else if (shareType === ShareTypes.SHARE_TYPE_GROUP) {\n\t\t\t\t\t\t\t\thasShares = true\n\t\t\t\t\t\t\t} else if (shareType === ShareTypes.SHARE_TYPE_REMOTE) {\n\t\t\t\t\t\t\t\thasShares = true\n\t\t\t\t\t\t\t} else if (shareType === ShareTypes.SHARE_TYPE_REMOTE_GROUP) {\n\t\t\t\t\t\t\t\thasShares = true\n\t\t\t\t\t\t\t} else if (shareType === ShareTypes.SHARE_TYPE_CIRCLE) {\n\t\t\t\t\t\t\t\thasShares = true\n\t\t\t\t\t\t\t} else if (shareType === ShareTypes.SHARE_TYPE_ROOM) {\n\t\t\t\t\t\t\t\thasShares = true\n\t\t\t\t\t\t\t} else if (shareType === ShareTypes.SHARE_TYPE_DECK) {\n\t\t\t\t\t\t\t\thasShares = true\n\t\t\t\t\t\t\t} else if (shareType === ShareTypes.SHARE_TYPE_SCIENCEMESH) {\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\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('files_sharing', 'Shared')\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\treturn t('files_sharing', 'Share')\n\t\t\t\t},\n\t\t\t\taltText: t('files_sharing', '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 === ShareTypes.SHARE_TYPE_EMAIL\n\t\t\t\t\t\t|| shareType === ShareTypes.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// details view disabled in some share lists\n\t\t\t\t\tif (!fileList._detailsView) {\n\t\t\t\t\t\treturn\n\t\t\t\t\t}\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, 'sharing')\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\t// register share breadcrumbs component\n\t\t\tvar breadCrumbSharingDetailView = new OCA.Sharing.ShareBreadCrumbView()\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} else {\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 * @returns {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\tOCA.Sharing.Util._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 * Marks/unmarks a given file as shared by changing its action icon\n\t\t * and folder icon.\n\t\t *\n\t\t * @param $tr file element to mark as shared\n\t\t * @param hasShares whether shares are available\n\t\t * @param hasLink whether link share is available\n\t\t */\n\t\t_markFileAsShared: function($tr, hasShares, hasLink) {\n\t\t\tvar action = $tr.find('.fileactions .action[data-action=\"Share\"]')\n\t\t\tvar type = $tr.data('type')\n\t\t\tvar icon = action.find('.icon')\n\t\t\tvar message, recipients, avatars\n\t\t\tvar ownerId = $tr.attr('data-share-owner-id')\n\t\t\tvar owner = $tr.attr('data-share-owner')\n\t\t\tvar mountType = $tr.attr('data-mounttype')\n\t\t\tvar shareFolderIcon\n\t\t\tvar iconClass = 'icon-shared'\n\t\t\taction.removeClass('shared-style')\n\t\t\t// update folder icon\n\t\t\tvar isEncrypted = $tr.attr('data-e2eencrypted')\n\t\t\tif (type === 'dir' && isEncrypted === 'true') {\n\t\t\t\tshareFolderIcon = OC.MimeType.getIconUrl('dir-encrypted')\n\t\t\t\t$tr.attr('data-icon', shareFolderIcon)\n\t\t\t} else if (type === 'dir' && (hasShares || hasLink || ownerId)) {\n\t\t\t\tif (typeof mountType !== 'undefined' && mountType !== 'shared-root' && mountType !== 'shared') {\n\t\t\t\t\tshareFolderIcon = OC.MimeType.getIconUrl('dir-' + mountType)\n\t\t\t\t} else if (hasLink) {\n\t\t\t\t\tshareFolderIcon = OC.MimeType.getIconUrl('dir-public')\n\t\t\t\t} else {\n\t\t\t\t\tshareFolderIcon = OC.MimeType.getIconUrl('dir-shared')\n\t\t\t\t}\n\t\t\t\t$tr.find('.filename .thumbnail').css('background-image', 'url(' + shareFolderIcon + ')')\n\t\t\t\t$tr.attr('data-icon', shareFolderIcon)\n\t\t\t} else if (type === 'dir') {\n\t\t\t\t// FIXME: duplicate of FileList._createRow logic for external folder,\n\t\t\t\t// need to refactor the icon logic into a single code path eventually\n\t\t\t\tif (mountType && mountType.indexOf('external') === 0) {\n\t\t\t\t\tshareFolderIcon = OC.MimeType.getIconUrl('dir-external')\n\t\t\t\t\t$tr.attr('data-icon', shareFolderIcon)\n\t\t\t\t} else {\n\t\t\t\t\tshareFolderIcon = OC.MimeType.getIconUrl('dir')\n\t\t\t\t\t// back to default\n\t\t\t\t\t$tr.removeAttr('data-icon')\n\t\t\t\t}\n\t\t\t\t$tr.find('.filename .thumbnail').css('background-image', 'url(' + shareFolderIcon + ')')\n\t\t\t}\n\t\t\t// update share action text / icon\n\t\t\tif (hasShares || ownerId) {\n\t\t\t\trecipients = $tr.data('share-recipient-data')\n\t\t\t\taction.addClass('shared-style')\n\n\t\t\t\tavatars = '<span>' + t('files_sharing', 'Shared') + '</span>'\n\t\t\t\t// even if reshared, only show \"Shared by\"\n\t\t\t\tif (ownerId) {\n\t\t\t\t\tmessage = t('files_sharing', 'Shared by')\n\t\t\t\t\tavatars = OCA.Sharing.Util._formatRemoteShare(ownerId, owner, message)\n\t\t\t\t} else if (recipients) {\n\t\t\t\t\tavatars = OCA.Sharing.Util._formatShareList(recipients)\n\t\t\t\t}\n\t\t\t\taction.html(avatars).prepend(icon)\n\n\t\t\t\tif (ownerId || recipients) {\n\t\t\t\t\tvar avatarElement = action.find('.avatar')\n\t\t\t\t\tavatarElement.each(function() {\n\t\t\t\t\t\t$(this).avatar($(this).data('username'), 32)\n\t\t\t\t\t})\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\taction.html('<span class=\"hidden-visually\">' + t('files_sharing', 'Shared') + '</span>').prepend(icon)\n\t\t\t}\n\t\t\tif (hasLink) {\n\t\t\t\ticonClass = 'icon-public'\n\t\t\t}\n\t\t\ticon.removeClass('icon-shared icon-public').addClass(iconClass)\n\t\t},\n\t\t/**\n\t\t * Format a remote address\n\t\t *\n\t\t * @param {String} shareWith userid, full remote share, or whatever\n\t\t * @param {String} shareWithDisplayName\n\t\t * @param {String} message\n\t\t * @returns {String} HTML code to display\n\t\t */\n\t\t_formatRemoteShare: function(shareWith, shareWithDisplayName, message) {\n\t\t\tvar parts = OCA.Sharing.Util._REMOTE_OWNER_REGEXP.exec(shareWith)\n\t\t\tif (!parts || !parts[7]) {\n\t\t\t\t// display avatar of the user\n\t\t\t\tvar avatar = '<span class=\"avatar\" data-username=\"' + escapeHTML(shareWith) + '\" title=\"' + message + ' ' + escapeHTML(shareWithDisplayName) + '\"></span>'\n\t\t\t\tvar hidden = '<span class=\"hidden-visually\">' + message + ' ' + escapeHTML(shareWithDisplayName) + '</span> '\n\t\t\t\treturn avatar + hidden\n\t\t\t}\n\n\t\t\tvar userName = parts[2]\n\t\t\tvar userDomain = parts[4]\n\t\t\tvar server = parts[5]\n\t\t\tvar protocol = parts[6]\n\t\t\tvar serverPath = parts[8] ? parts[7] : ''; // no trailing slash on root\n\n\t\t\tvar tooltip = message + ' ' + userName\n\t\t\tif (userDomain) {\n\t\t\t\ttooltip += '@' + userDomain\n\t\t\t}\n\t\t\tif (server) {\n\t\t\t\ttooltip += '@' + server.replace(protocol, '') + serverPath\n\t\t\t}\n\n\t\t\tvar html = '<span class=\"remoteAddress\" title=\"' + escapeHTML(tooltip) + '\">'\n\t\t\thtml += '<span class=\"username\">' + escapeHTML(userName) + '</span>'\n\t\t\tif (userDomain) {\n\t\t\t\thtml += '<span class=\"userDomain\">@' + escapeHTML(userDomain) + '</span>'\n\t\t\t}\n\t\t\thtml += '</span> '\n\t\t\treturn html\n\t\t},\n\t\t/**\n\t\t * Loop over all recipients in the list and format them using\n\t\t * all kind of fancy magic.\n\t\t *\n\t\t* @param {Object} recipients array of all the recipients\n\t\t* @returns {String[]} modified list of recipients\n\t\t*/\n\t\t_formatShareList: function(recipients) {\n\t\t\tvar _parent = this\n\t\t\trecipients = _.toArray(recipients)\n\t\t\trecipients.sort(function(a, b) {\n\t\t\t\treturn a.shareWithDisplayName.localeCompare(b.shareWithDisplayName)\n\t\t\t})\n\t\t\treturn $.map(recipients, function(recipient) {\n\t\t\t\treturn _parent._formatRemoteShare(recipient.shareWith, recipient.shareWithDisplayName, t('files_sharing', 'Shared with'))\n\t\t\t})\n\t\t},\n\n\t\t/**\n\t\t * Marks/unmarks a given file as shared by changing its action icon\n\t\t * and folder icon.\n\t\t *\n\t\t* @param $tr file element to mark as shared\n\t\t* @param hasShares whether shares are available\n\t\t* @param hasLink whether link share is available\n\t\t*/\n\t\tmarkFileAsShared: function($tr, hasShares, hasLink) {\n\t\t\tvar action = $tr.find('.fileactions .action[data-action=\"Share\"]')\n\t\t\tvar type = $tr.data('type')\n\t\t\tvar icon = action.find('.icon')\n\t\t\tvar message, recipients, avatars\n\t\t\tvar ownerId = $tr.attr('data-share-owner-id')\n\t\t\tvar owner = $tr.attr('data-share-owner')\n\t\t\tvar mountType = $tr.attr('data-mounttype')\n\t\t\tvar shareFolderIcon\n\t\t\tvar iconClass = 'icon-shared'\n\t\t\taction.removeClass('shared-style')\n\t\t\t// update folder icon\n\t\t\tif (type === 'dir' && (hasShares || hasLink || ownerId)) {\n\t\t\t\tif (typeof mountType !== 'undefined' && mountType !== 'shared-root' && mountType !== 'shared') {\n\t\t\t\t\tshareFolderIcon = OC.MimeType.getIconUrl('dir-' + mountType)\n\t\t\t\t} else if (hasLink) {\n\t\t\t\t\tshareFolderIcon = OC.MimeType.getIconUrl('dir-public')\n\t\t\t\t} else {\n\t\t\t\t\tshareFolderIcon = OC.MimeType.getIconUrl('dir-shared')\n\t\t\t\t}\n\t\t\t\t$tr.find('.filename .thumbnail').css('background-image', 'url(' + shareFolderIcon + ')')\n\t\t\t\t$tr.attr('data-icon', shareFolderIcon)\n\t\t\t} else if (type === 'dir') {\n\t\t\t\tvar isEncrypted = $tr.attr('data-e2eencrypted')\n\t\t\t\t// FIXME: duplicate of FileList._createRow logic for external folder,\n\t\t\t\t// need to refactor the icon logic into a single code path eventually\n\t\t\t\tif (isEncrypted === 'true') {\n\t\t\t\t\tshareFolderIcon = OC.MimeType.getIconUrl('dir-encrypted')\n\t\t\t\t\t$tr.attr('data-icon', shareFolderIcon)\n\t\t\t\t} else if (mountType && mountType.indexOf('external') === 0) {\n\t\t\t\t\tshareFolderIcon = OC.MimeType.getIconUrl('dir-external')\n\t\t\t\t\t$tr.attr('data-icon', shareFolderIcon)\n\t\t\t\t} else {\n\t\t\t\t\tshareFolderIcon = OC.MimeType.getIconUrl('dir')\n\t\t\t\t\t// back to default\n\t\t\t\t\t$tr.removeAttr('data-icon')\n\t\t\t\t}\n\t\t\t\t$tr.find('.filename .thumbnail').css('background-image', 'url(' + shareFolderIcon + ')')\n\t\t\t}\n\t\t\t// update share action text / icon\n\t\t\tif (hasShares || ownerId) {\n\t\t\t\trecipients = $tr.data('share-recipient-data')\n\t\t\t\taction.addClass('shared-style')\n\n\t\t\t\tavatars = '<span>' + t('files_sharing', 'Shared') + '</span>'\n\t\t\t\t// even if reshared, only show \"Shared by\"\n\t\t\t\tif (ownerId) {\n\t\t\t\t\tmessage = t('files_sharing', 'Shared by')\n\t\t\t\t\tavatars = this._formatRemoteShare(ownerId, owner, message)\n\t\t\t\t} else if (recipients) {\n\t\t\t\t\tavatars = this._formatShareList(recipients)\n\t\t\t\t}\n\t\t\t\taction.html(avatars).prepend(icon)\n\n\t\t\t\tif (ownerId || recipients) {\n\t\t\t\t\tvar avatarElement = action.find('.avatar')\n\t\t\t\t\tavatarElement.each(function() {\n\t\t\t\t\t\t$(this).avatar($(this).data('username'), 32)\n\t\t\t\t\t})\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\taction.html('<span class=\"hidden-visually\">' + t('files_sharing', 'Shared') + '</span>').prepend(icon)\n\t\t\t}\n\t\t\tif (hasLink) {\n\t\t\t\ticonClass = 'icon-public'\n\t\t\t}\n\t\t\ticon.removeClass('icon-shared icon-public').addClass(iconClass)\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 * SPDX-FileCopyrightText: 2016 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport { Type as ShareTypes } from '@nextcloud/sharing'\n\n(function() {\n\t'use strict'\n\n\tconst 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\trender(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\tconst 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(ShareTypes.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(e) {\n\t\t\te.preventDefault()\n\t\t\te.stopPropagation()\n\n\t\t\tconst fileInfoModel = new OCA.Files.FileInfoModel(this._dirInfo)\n\t\t\tconst 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\n\t\t\tconst path = fileInfoModel.attributes.path + '/' + fileInfoModel.attributes.name\n\t\t\tOCA.Files.Sidebar.open(path)\n\t\t\tOCA.Files.Sidebar.setActiveTab('sharing')\n\t\t},\n\t})\n\n\tOCA.Sharing.ShareBreadCrumbView = BreadCrumbView\n})()\n","/**\n * SPDX-FileCopyrightText: 2016 Nextcloud GmbH and Nextcloud contributors\n * SPDX-License-Identifier: AGPL-3.0-or-later\n */\n\nimport './share.js'\nimport './sharebreadcrumbview.js'\nimport './style/sharebreadcrumb.scss'\nimport './collaborationresourceshandler.js'\n\nwindow.OCA.Sharing = OCA.Sharing\n"],"names":["fileList","getCapabilities","fileActions","oldCreateRow","fileData","tr","sharePermissions","oldElementToFile","$el","fileInfo","expirationTimestamp","oldGetWebdavProperties","props","response","data","permissionsProp","shareTypesProp","xmlvalue","ev","$files","file","$tr","shareTypesStr","shareOwner","hasLink","hasShares","shareTypeStr","shareType","ShareTypes","context","fileName","permissions","actionSpec","isDefault","breadCrumbSharingDetailView","shareModel","recipients","recipientData","share","hasUserShares","hasLinkShares","action","type","icon","message","avatars","ownerId","owner","mountType","shareFolderIcon","iconClass","isEncrypted","avatarElement","shareWith","shareWithDisplayName","parts","avatar","escapeHTML","hidden","userName","userDomain","server","protocol","serverPath","tooltip","html","_parent","a","b","recipient","BreadCrumbView","isShared","e","fileInfoModel","self","path"],"mappings":";0IAYC,UAAW,CAEX,EAAE,OAAO,GAAG,MAAM,OAAQ,CACzB,qBAAsB,IAAM,GAAG,MAAM,OAAO,YAAc,eAC1D,kBAAmB,IAAM,GAAG,MAAM,OAAO,YAAc,YACvD,4BAA6B,IAAM,GAAG,MAAM,OAAO,YAAc,qBACnE,CAAE,EAEI,IAAI,UACR,IAAI,QAAU,CAAE,GAMjB,IAAI,QAAQ,KAAO,CAQlB,qBAAsB,IAAI,OAAO,8DAA8D,EAU/F,OAAQ,SAASA,EAAU,OAE1B,IAAKC,EAAAA,EAAe,EAAG,gBAAlBA,MAAAA,EAAiC,aAGlC,EAAAD,EAAS,KAAO,YAAcA,EAAS,KAAO,gBAGlD,CAAIE,IAAAA,EAAcF,EAAS,YACvBG,EAAeH,EAAS,WAC5BA,EAAS,WAAa,SAASI,EAAU,CAExC,IAAIC,EAAKF,EAAa,MAAM,KAAM,SAAS,EACvCG,EAAmB,IAAI,QAAQ,KAAK,oBAAoBF,CAAQ,EAEpE,OAAIA,EAAS,cAAgB,IAE5B,OAAOF,EAAY,QAAQ,IAAI,QAC/B,OAAOA,EAAY,QAAQ,IAAI,QAC/B,OAAOA,EAAY,QAAQ,IAAI,MAE5B,EAAE,WAAWE,EAAS,WAAW,GAAK,CAACA,EAAS,gBACnD,OAAOF,EAAY,QAAQ,IAAI,SAC1BE,EAAS,YAAc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