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
7 years ago
|
// Package imports //
|
||
8 years ago
|
import { connect } from 'react-redux';
|
||
7 years ago
|
|
||
|
// Mastodon imports //
|
||
7 years ago
|
import { closeModal } from 'mastodon/actions/modal';
|
||
7 years ago
|
|
||
|
// Our imports //
|
||
7 years ago
|
import { changeLocalSetting } from 'glitch/actions/local_settings';
|
||
7 years ago
|
import LocalSettings from '.';
|
||
8 years ago
|
|
||
|
const mapStateToProps = state => ({
|
||
|
settings: state.get('local_settings'),
|
||
|
});
|
||
|
|
||
|
const mapDispatchToProps = dispatch => ({
|
||
7 years ago
|
onChange (setting, value) {
|
||
|
dispatch(changeLocalSetting(setting, value));
|
||
8 years ago
|
},
|
||
8 years ago
|
onClose () {
|
||
|
dispatch(closeModal());
|
||
|
},
|
||
|
});
|
||
|
|
||
7 years ago
|
export default connect(mapStateToProps, mapDispatchToProps)(LocalSettings);
|