bigbuffet-rw/app/soapbox/features/account_timeline/containers/column_settings_container.js
2022-01-10 16:17:52 -06:00

17 lines
515 B
JavaScript

import { connect } from 'react-redux';
import { getSettings, changeSetting } from '../../../actions/settings';
import ColumnSettings from '../components/column_settings';
const mapStateToProps = state => ({
settings: getSettings(state).get('account_timeline'),
});
const mapDispatchToProps = (dispatch) => {
return {
onChange(key, checked) {
dispatch(changeSetting(['account_timeline', ...key], checked));
},
};
};
export default connect(mapStateToProps, mapDispatchToProps)(ColumnSettings);