diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2016-12-18 19:47:11 +0100 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2016-12-18 19:47:11 +0100 |
commit | 5ae1b39ec9b4d5269d2f01aeaa4304252b694519 (patch) | |
tree | 7b9f058c315189d2e557830b4108b5755ede5603 /app/assets/javascripts | |
parent | aed25932b528f16861c4e016cbeb7a3de6231fe7 (diff) |
Adjusting public display of statuses to look similar to logged-in UI,
fix #361 with rich OEmbed display via iframe, fix #237 by hiding sensitive content behind a spoiler on public pages
Diffstat (limited to 'app/assets/javascripts')
-rw-r--r-- | app/assets/javascripts/extras.jsx | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/app/assets/javascripts/extras.jsx b/app/assets/javascripts/extras.jsx index 93f827044..9fd769c0b 100644 --- a/app/assets/javascripts/extras.jsx +++ b/app/assets/javascripts/extras.jsx @@ -1,8 +1,20 @@ import emojify from './components/emoji' $(() => { - $.each($('.entry .content, .name, .account__header__content'), (_, content) => { + $.each($('.entry .content, .entry .status__content, .display-name, .name, .account__header__content'), (_, content) => { const $content = $(content); $content.html(emojify($content.html())); }); + + $('.video-player video').on('click', e => { + if (e.target.paused) { + e.target.play(); + } else { + e.target.pause(); + } + }); + + $('.media-spoiler').on('click', e => { + $(e.target).hide(); + }); }); |