diff options
author | Jonas <jonas@freesources.org> | 2023-11-13 18:28:20 +0100 |
---|---|---|
committer | Jonas <jonas@freesources.org> | 2023-11-14 08:40:44 +0100 |
commit | ee5c444e9cadf20b3339d6e1c0c0ccd286d974cc (patch) | |
tree | 884b0706565dc9c957af5e1c4f4fdc9c689d6950 /apps/files | |
parent | 6284009fa024005df591f2308fefc49e68728e49 (diff) | |
download | nextcloud-server-ee5c444e9cadf20b3339d6e1c0c0ccd286d974cc.tar.gz nextcloud-server-ee5c444e9cadf20b3339d6e1c0c0ccd286d974cc.zip |
fix(files): Show Collectives icon in Collectives folders
Signed-off-by: Jonas <jonas@freesources.org>
Diffstat (limited to 'apps/files')
-rw-r--r-- | apps/files/src/components/FileEntry/CollectivesIcon.vue | 41 | ||||
-rw-r--r-- | apps/files/src/components/FileEntry/FileEntryPreview.vue | 4 |
2 files changed, 45 insertions, 0 deletions
diff --git a/apps/files/src/components/FileEntry/CollectivesIcon.vue b/apps/files/src/components/FileEntry/CollectivesIcon.vue new file mode 100644 index 00000000000..4316183e3ff --- /dev/null +++ b/apps/files/src/components/FileEntry/CollectivesIcon.vue @@ -0,0 +1,41 @@ +<template> + <span :aria-hidden="!title" + :aria-label="title" + class="material-design-icon collectives-icon" + role="img" + v-bind="$attrs" + @click="$emit('click', $event)"> + <svg :fill="fillColor" + class="material-design-icon__svg" + :width="size" + :height="size" + viewBox="0 0 16 16"> + <path d="M2.9,8.8c0-1.2,0.4-2.4,1.2-3.3L0.3,6c-0.2,0-0.3,0.3-0.1,0.4l2.7,2.6C2.9,9,2.9,8.9,2.9,8.8z" /> + <path d="M8,3.7c0.7,0,1.3,0.1,1.9,0.4L8.2,0.6c-0.1-0.2-0.3-0.2-0.4,0L6.1,4C6.7,3.8,7.3,3.7,8,3.7z" /> + <path d="M3.7,11.5L3,15.2c0,0.2,0.2,0.4,0.4,0.3l3.3-1.7C5.4,13.4,4.4,12.6,3.7,11.5z" /> + <path d="M15.7,6l-3.7-0.5c0.7,0.9,1.2,2,1.2,3.3c0,0.1,0,0.2,0,0.3l2.7-2.6C15.9,6.3,15.9,6.1,15.7,6z" /> + <path d="M12.3,11.5c-0.7,1.1-1.8,1.9-3,2.2l3.3,1.7c0.2,0.1,0.4-0.1,0.4-0.3L12.3,11.5z" /> + <path d="M9.6,10.1c-0.4,0.5-1,0.8-1.6,0.8c-1.1,0-2-0.9-2.1-2C5.9,7.7,6.8,6.7,8,6.7c0.6,0,1.1,0.3,1.5,0.7 c0.1,0.1,0.1,0.1,0.2,0.1h1.4c0.2,0,0.4-0.2,0.3-0.5c-0.7-1.3-2.1-2.2-3.8-2.1C5.8,5,4.3,6.6,4.1,8.5C4,10.8,5.8,12.7,8,12.7 c1.6,0,2.9-0.9,3.5-2.3c0.1-0.2-0.1-0.4-0.3-0.4H9.9C9.8,10,9.7,10,9.6,10.1z" /> + </svg> + </span> +</template> + +<script> +export default { + name: 'CollectivesIcon', + props: { + title: { + type: String, + default: '', + }, + fillColor: { + type: String, + default: 'currentColor', + }, + size: { + type: Number, + default: 24, + }, + }, +} +</script> diff --git a/apps/files/src/components/FileEntry/FileEntryPreview.vue b/apps/files/src/components/FileEntry/FileEntryPreview.vue index 35eb3c8804d..ddf5f5fb74c 100644 --- a/apps/files/src/components/FileEntry/FileEntryPreview.vue +++ b/apps/files/src/components/FileEntry/FileEntryPreview.vue @@ -78,6 +78,7 @@ import TagIcon from 'vue-material-design-icons/Tag.vue' import PlayCircleIcon from 'vue-material-design-icons/PlayCircle.vue' import { useUserConfigStore } from '../../store/userconfig.ts' +import CollectivesIcon from './CollectivesIcon.vue' import FavoriteIcon from './FavoriteIcon.vue' import { isLivePhoto } from '../../services/LivePhotos' @@ -87,6 +88,7 @@ export default Vue.extend({ components: { AccountGroupIcon, AccountPlusIcon, + CollectivesIcon, FavoriteIcon, FileIcon, FolderIcon, @@ -209,6 +211,8 @@ export default Vue.extend({ return NetworkIcon case 'group': return AccountGroupIcon + case 'collective': + return CollectivesIcon } return null |