From 22870985dac47d4162bbe63d445cee8f7a1567bb Mon Sep 17 00:00:00 2001 From: Thibaut Girka Date: Mon, 12 Mar 2018 19:32:47 +0100 Subject: Add close modal icon to report dialog (#6591) Port 379cdfaac5838c7008b80c8f317ca6403da683a9 to glitch-soc flavour --- .../flavours/glitch/features/ui/components/report_modal.js | 5 ++++- app/javascript/flavours/glitch/styles/components/modal.scss | 5 +++++ 2 files changed, 9 insertions(+), 1 deletion(-) (limited to 'app') diff --git a/app/javascript/flavours/glitch/features/ui/components/report_modal.js b/app/javascript/flavours/glitch/features/ui/components/report_modal.js index fcd76165d..b5fc33d03 100644 --- a/app/javascript/flavours/glitch/features/ui/components/report_modal.js +++ b/app/javascript/flavours/glitch/features/ui/components/report_modal.js @@ -11,8 +11,10 @@ import { OrderedSet } from 'immutable'; import ImmutablePureComponent from 'react-immutable-pure-component'; import Button from 'flavours/glitch/components/button'; import Toggle from 'react-toggle'; +import IconButton from '../../../components/icon_button'; const messages = defineMessages({ + close: { id: 'lightbox.close', defaultMessage: 'Close' }, placeholder: { id: 'report.placeholder', defaultMessage: 'Additional comments' }, submit: { id: 'report.submit', defaultMessage: 'Submit' }, }); @@ -72,7 +74,7 @@ export default class ReportModal extends ImmutablePureComponent { } render () { - const { account, comment, intl, statusIds, isSubmitting, forward } = this.props; + const { account, comment, intl, statusIds, isSubmitting, forward, onClose } = this.props; if (!account) { return null; @@ -83,6 +85,7 @@ export default class ReportModal extends ImmutablePureComponent { return (
+ {account.get('acct')} }} />
diff --git a/app/javascript/flavours/glitch/styles/components/modal.scss b/app/javascript/flavours/glitch/styles/components/modal.scss index e85c54bea..d424b1eda 100644 --- a/app/javascript/flavours/glitch/styles/components/modal.scss +++ b/app/javascript/flavours/glitch/styles/components/modal.scss @@ -615,6 +615,11 @@ .report-modal__target { padding: 20px; + + .media-modal__close { + top: 19px; + right: 15px; + } } .actions-modal { -- cgit