From f59973cc85d9e84bd484ca7c75f108ccbb5d17df Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Fri, 3 May 2019 04:34:55 +0200 Subject: [PATCH] [Glitch] Make the "mark media as sensitive" button more obvious in web UI Port 05ef3462ba0af7b147a7cfa8de2735e99dc59ac5 to glitch-soc Signed-off-by: Thibaut Girka --- .../glitch/components/media_gallery.js | 2 +- .../features/compose/components/options.js | 41 -------------- .../compose/components/upload_form.js | 3 ++ .../compose/containers/options_container.js | 5 -- .../containers/sensitive_button_container.js | 54 +++++++++++++++++++ .../flavours/glitch/features/video/index.js | 2 +- .../glitch/styles/components/composer.scss | 5 ++ 7 files changed, 64 insertions(+), 48 deletions(-) create mode 100644 app/javascript/flavours/glitch/features/compose/containers/sensitive_button_container.js diff --git a/app/javascript/flavours/glitch/components/media_gallery.js b/app/javascript/flavours/glitch/components/media_gallery.js index ab1cccc60..194800d52 100644 --- a/app/javascript/flavours/glitch/components/media_gallery.js +++ b/app/javascript/flavours/glitch/components/media_gallery.js @@ -345,7 +345,7 @@ export default class MediaGallery extends React.PureComponent { } if (visible) { - spoilerButton = ; + spoilerButton = ; } else { spoilerButton = ( + + ); + } + +} + +export default connect(mapStateToProps, mapDispatchToProps)(injectIntl(SensitiveButton)); diff --git a/app/javascript/flavours/glitch/features/video/index.js b/app/javascript/flavours/glitch/features/video/index.js index 381485802..8291ff3c8 100644 --- a/app/javascript/flavours/glitch/features/video/index.js +++ b/app/javascript/flavours/glitch/features/video/index.js @@ -500,7 +500,7 @@ export default class Video extends React.PureComponent {
- {!onCloseVideo && } + {!onCloseVideo && } {(!fullscreen && onOpenVideo) && } {onCloseVideo && } diff --git a/app/javascript/flavours/glitch/styles/components/composer.scss b/app/javascript/flavours/glitch/styles/components/composer.scss index e5eb6e64f..81c700737 100644 --- a/app/javascript/flavours/glitch/styles/components/composer.scss +++ b/app/javascript/flavours/glitch/styles/components/composer.scss @@ -57,6 +57,11 @@ } } +.compose-form__sensitive-button { + padding: 10px; + padding-top: 0; +} + .composer--reply { margin: 0 0 10px; border-radius: 4px;