lbry-desktop/ui/component/settingLanguage/index.js
2019-11-13 09:53:01 -05:00

18 lines
501 B
JavaScript

import { connect } from 'react-redux';
import * as SETTINGS from 'constants/settings';
import { doSetLanguage } from 'redux/actions/settings';
import { makeSelectClientSetting } from 'redux/selectors/settings';
import SettingLanguage from './view';
const select = state => ({
language: makeSelectClientSetting(SETTINGS.LANGUAGE)(state),
});
const perform = dispatch => ({
setLanguage: value => dispatch(doSetLanguage(value)),
});
export default connect(
select,
perform
)(SettingLanguage);