2017-07-12 04:02:51 -04:00
|
|
|
// Package imports //
|
|
|
|
import { connect } from 'react-redux';
|
|
|
|
|
|
|
|
// Mastodon imports //
|
2017-07-13 05:40:16 -04:00
|
|
|
import { toggleComposeAdvancedOption } from '../../../../mastodon/actions/compose';
|
2017-07-12 04:02:51 -04:00
|
|
|
|
|
|
|
// Our imports //
|
2017-07-13 05:40:16 -04:00
|
|
|
import ComposeAdvancedOptions from '.';
|
2017-07-12 04:02:51 -04:00
|
|
|
|
|
|
|
const mapStateToProps = state => ({
|
|
|
|
values: state.getIn(['compose', 'advanced_options']),
|
|
|
|
});
|
|
|
|
|
|
|
|
const mapDispatchToProps = dispatch => ({
|
|
|
|
|
|
|
|
onChange (option) {
|
2017-07-12 01:50:50 -04:00
|
|
|
dispatch(toggleComposeAdvancedOption(option));
|
2017-07-12 04:02:51 -04:00
|
|
|
},
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
export default connect(mapStateToProps, mapDispatchToProps)(ComposeAdvancedOptions);
|