mirror of
https://git.kescher.at/CatCatNya/catstodon.git
synced 2024-11-27 19:41:37 +01:00
Add close modal icon to report dialog (#6591)
Port 379cdfaac5
to glitch-soc flavour
This commit is contained in:
parent
9cf574d0d2
commit
22870985da
2 changed files with 9 additions and 1 deletions
|
@ -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 (
|
||||
<div className='modal-root__modal report-modal'>
|
||||
<div className='report-modal__target'>
|
||||
<IconButton className='media-modal__close' title={intl.formatMessage(messages.close)} icon='times' onClick={onClose} size={16} />
|
||||
<FormattedMessage id='report.target' defaultMessage='Report {target}' values={{ target: <strong>{account.get('acct')}</strong> }} />
|
||||
</div>
|
||||
|
||||
|
|
|
@ -615,6 +615,11 @@
|
|||
|
||||
.report-modal__target {
|
||||
padding: 20px;
|
||||
|
||||
.media-modal__close {
|
||||
top: 19px;
|
||||
right: 15px;
|
||||
}
|
||||
}
|
||||
|
||||
.actions-modal {
|
||||
|
|
Loading…
Reference in a new issue