1a3669ca76
- Missed the "Account Password" card that is used for authenticated case. - For cards that are only used in Settings, listen to the language change in "select" instead of passing in as a prop. I think this is cleaner.
18 lines
680 B
JavaScript
18 lines
680 B
JavaScript
import { connect } from 'react-redux';
|
|
import * as SETTINGS from 'constants/settings';
|
|
import { doSetAutoLaunch } from 'redux/actions/settings';
|
|
import { makeSelectClientSetting } from 'redux/selectors/settings';
|
|
import { doToast } from 'redux/actions/notifications';
|
|
import SettingAutoLaunch from './view';
|
|
|
|
const select = state => ({
|
|
autoLaunch: makeSelectClientSetting(SETTINGS.AUTO_LAUNCH)(state),
|
|
language: makeSelectClientSetting(SETTINGS.LANGUAGE)(state),
|
|
});
|
|
|
|
const perform = dispatch => ({
|
|
showToast: options => dispatch(doToast(options)),
|
|
setAutoLaunch: value => dispatch(doSetAutoLaunch(value)),
|
|
});
|
|
|
|
export default connect(select, perform)(SettingAutoLaunch);
|