Updated components, style modules
This commit is contained in:
@@ -1,11 +1,7 @@
|
||||
import ImmutablePropTypes from 'react-immutable-proptypes';
|
||||
import { defineMessages, injectIntl, FormattedMessage } from 'react-intl';
|
||||
import ImmutablePureComponent from 'react-immutable-pure-component';
|
||||
import Avatar from '../../avatar';
|
||||
import ComposeFormContainer from '../../../features/compose/containers/compose_form_container';
|
||||
import { openModal } from '../../../actions/modal';
|
||||
import { cancelReplyCompose } from '../../../actions/compose';
|
||||
import { me } from '../../../initial_state';
|
||||
import ModalLayout from '../modal_layout';
|
||||
|
||||
const messages = defineMessages({
|
||||
@@ -15,7 +11,6 @@ const messages = defineMessages({
|
||||
|
||||
const mapStateToProps = state => {
|
||||
return {
|
||||
account: state.getIn(['accounts', me]),
|
||||
composeText: state.getIn(['compose', 'text']),
|
||||
};
|
||||
};
|
||||
@@ -25,7 +20,6 @@ export default @connect(mapStateToProps)
|
||||
class ComposeModal extends ImmutablePureComponent {
|
||||
|
||||
static propTypes = {
|
||||
account: ImmutablePropTypes.map,
|
||||
intl: PropTypes.object.isRequired,
|
||||
onClose: PropTypes.func.isRequired,
|
||||
composeText: PropTypes.string,
|
||||
@@ -49,16 +43,11 @@ class ComposeModal extends ImmutablePureComponent {
|
||||
};
|
||||
|
||||
render () {
|
||||
const { intl, account } = this.props;
|
||||
const { intl } = this.props;
|
||||
|
||||
return (
|
||||
<ModalLayout title={intl.formatMessage(messages.title)} onClose={onClickClose}>
|
||||
<div className='timeline-compose-block'>
|
||||
<div className='timeline-compose-block__avatar'>
|
||||
<Avatar account={account} size={32} />
|
||||
</div>
|
||||
<ComposeFormContainer />
|
||||
</div>
|
||||
<TimelineComposeBlock />
|
||||
</ModalLayout>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user