aboutsummaryrefslogtreecommitdiff
path: root/src/components/attachment/attachment.js
diff options
context:
space:
mode:
authorHJ <30-hj@users.noreply.git.pleroma.social>2020-10-28 21:21:35 +0000
committerHJ <30-hj@users.noreply.git.pleroma.social>2020-10-28 21:21:35 +0000
commita84db4bd8f04bdfc14836f55f441aa8478265291 (patch)
treec5e08f042c0cbab4cc212e35c624d5afa65b85bc /src/components/attachment/attachment.js
parente2c4816feb700d25bbeaebee6c5a67ae5f478e90 (diff)
parentef36ca44f613c3d7d2ea11a9ad4f7fe828f7ae83 (diff)
Merge branch 'fontawesome5' into 'develop'
FontAwesome 5 Closes #982 See merge request pleroma/pleroma-fe!1260
Diffstat (limited to 'src/components/attachment/attachment.js')
-rw-r--r--src/components/attachment/attachment.js22
1 files changed, 18 insertions, 4 deletions
diff --git a/src/components/attachment/attachment.js b/src/components/attachment/attachment.js
index cb31020d..e23fcb1b 100644
--- a/src/components/attachment/attachment.js
+++ b/src/components/attachment/attachment.js
@@ -3,6 +3,20 @@ import VideoAttachment from '../video_attachment/video_attachment.vue'
import nsfwImage from '../../assets/nsfw.png'
import fileTypeService from '../../services/file_type/file_type.service.js'
import { mapGetters } from 'vuex'
+import { library } from '@fortawesome/fontawesome-svg-core'
+import {
+ faFile,
+ faMusic,
+ faImage,
+ faVideo
+} from '@fortawesome/free-solid-svg-icons'
+
+library.add(
+ faFile,
+ faMusic,
+ faImage,
+ faVideo
+)
const Attachment = {
props: [
@@ -39,10 +53,10 @@ const Attachment = {
return this.attachment.description
},
placeholderIconClass () {
- if (this.type === 'image') return 'icon-picture'
- if (this.type === 'video') return 'icon-video'
- if (this.type === 'audio') return 'icon-music'
- return 'icon-doc'
+ if (this.type === 'image') return 'image'
+ if (this.type === 'video') return 'video'
+ if (this.type === 'audio') return 'music'
+ return 'file'
},
referrerpolicy () {
return this.$store.state.instance.mediaProxyAvailable ? '' : 'no-referrer'