You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
601 B
25 lines
601 B
8 years ago
|
// Package imports //
|
||
8 years ago
|
import { connect } from 'react-redux';
|
||
8 years ago
|
|
||
|
// Mastodon imports //
|
||
8 years ago
|
import { closeModal } from 'mastodon/actions/modal';
|
||
8 years ago
|
|
||
|
// Our imports //
|
||
8 years ago
|
import { changeLocalSetting } from 'glitch/actions/local_settings';
|
||
8 years ago
|
import LocalSettings from '.';
|
||
8 years ago
|
|
||
|
const mapStateToProps = state => ({
|
||
|
settings: state.get('local_settings'),
|
||
|
});
|
||
|
|
||
|
const mapDispatchToProps = dispatch => ({
|
||
8 years ago
|
onChange (setting, value) {
|
||
|
dispatch(changeLocalSetting(setting, value));
|
||
8 years ago
|
},
|
||
8 years ago
|
onClose () {
|
||
|
dispatch(closeModal());
|
||
|
},
|
||
|
});
|
||
|
|
||
8 years ago
|
export default connect(mapStateToProps, mapDispatchToProps)(LocalSettings);
|