diff options
| author | Henry Jameson <me@hjkos.com> | 2021-02-01 19:39:57 +0200 |
|---|---|---|
| committer | Henry Jameson <me@hjkos.com> | 2021-02-01 19:39:57 +0200 |
| commit | 8958f386bef9317ff5782fa0f16164d7fbc2af21 (patch) | |
| tree | 8c33fed5331c18023d608fbb366c464783559220 /src/components/attachment/attachment.js | |
| parent | e695506c514e49964dfd81c7db5c5b4d4918f47d (diff) | |
| parent | de66267a07eb018cc0309ff6f9dd896d53ba3ff4 (diff) | |
Merge remote-tracking branch 'origin/develop' into settings-changed
* origin/develop: (306 commits)
fallback if shadows aren't defined
Translated using Weblate (Chinese (Traditional))
Translated using Weblate (Ukrainian)
Translated using Weblate (Italian)
Translated using Weblate (Ukrainian)
Translated using Weblate (Portuguese)
Translated using Weblate (Italian)
Translated using Weblate (Russian)
Translated using Weblate (Portuguese)
Translated using Weblate (Russian)
Translated using Weblate (Portuguese)
Translated using Weblate (Portuguese)
Translated using Weblate (Portuguese)
Translated using Weblate (Portuguese)
Translated using Weblate (Portuguese)
Translated using Weblate (Portuguese)
Translated using Weblate (Portuguese)
Translated using Weblate (Portuguese)
Translated using Weblate (Portuguese)
Translated using Weblate (Portuguese)
...
Diffstat (limited to 'src/components/attachment/attachment.js')
| -rw-r--r-- | src/components/attachment/attachment.js | 26 |
1 files changed, 22 insertions, 4 deletions
diff --git a/src/components/attachment/attachment.js b/src/components/attachment/attachment.js index cb31020d..5f5779a0 100644 --- a/src/components/attachment/attachment.js +++ b/src/components/attachment/attachment.js @@ -3,6 +3,24 @@ 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, + faPlayCircle, + faTimes +} from '@fortawesome/free-solid-svg-icons' + +library.add( + faFile, + faMusic, + faImage, + faVideo, + faPlayCircle, + faTimes +) const Attachment = { props: [ @@ -39,10 +57,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' |
