diff options
author | ThibG <thib@sitedethib.com> | 2019-08-20 19:46:41 +0200 |
---|---|---|
committer | Thibaut Girka <thib@sitedethib.com> | 2019-08-20 20:38:42 +0200 |
commit | f1528ea3c4b81dbc3f7bb8b5b5ae7734eeda989f (patch) | |
tree | 70f3571cd1d3b117df3363072740ea4423803165 /app/javascript/flavours/glitch/features/account_gallery/components/media_item.js | |
parent | 81d2d7109414d232d79446633fc9556ad0f1632b (diff) |
[Glitch] Fix handling of audio files in account media gallery
Port b48c7ee059d0e08fff4bdf7fe7b0e09565288252 to glitch-soc Signed-off-by: Thibaut Girka <thib@sitedethib.com>
Diffstat (limited to 'app/javascript/flavours/glitch/features/account_gallery/components/media_item.js')
-rw-r--r-- | app/javascript/flavours/glitch/features/account_gallery/components/media_item.js | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/app/javascript/flavours/glitch/features/account_gallery/components/media_item.js b/app/javascript/flavours/glitch/features/account_gallery/components/media_item.js index 026136b2c..d60e06715 100644 --- a/app/javascript/flavours/glitch/features/account_gallery/components/media_item.js +++ b/app/javascript/flavours/glitch/features/account_gallery/components/media_item.js @@ -94,6 +94,12 @@ export default class MediaItem extends ImmutablePureComponent { if (attachment.get('type') === 'unknown') { // Skip + } else if (attachment.get('type') === 'audio') { + thumbnail = ( + <span className='account-gallery__item__icons'> + <i className='fa fa-music' /> + </span> + ); } else if (attachment.get('type') === 'image') { const focusX = attachment.getIn(['meta', 'focus', 'x']) || 0; const focusY = attachment.getIn(['meta', 'focus', 'y']) || 0; |