Fix CircleDropdown
This commit is contained in:
parent
30be912026
commit
cf642b0b8f
1 changed files with 5 additions and 10 deletions
|
@ -2,16 +2,11 @@ import { connect } from 'react-redux';
|
||||||
import CircleDropdown from '../components/circle_dropdown';
|
import CircleDropdown from '../components/circle_dropdown';
|
||||||
import { changeComposeCircle } from '../../../actions/compose';
|
import { changeComposeCircle } from '../../../actions/compose';
|
||||||
|
|
||||||
const mapStateToProps = state => {
|
const mapStateToProps = state => ({
|
||||||
let value = state.getIn(['compose', 'circle_id']);
|
value: state.getIn(['compose', 'circle_id']) ?? '',
|
||||||
value = value === null ? '' : value;
|
visible: state.getIn(['compose', 'privacy']) === 'limited',
|
||||||
|
limitedReply: state.getIn(['compose', 'privacy']) === 'limited' && state.getIn(['compose', 'reply_status', 'visibility']) === 'limited',
|
||||||
return {
|
});
|
||||||
value: value,
|
|
||||||
visible: state.getIn(['compose', 'privacy']) === 'limited',
|
|
||||||
limitedReply: state.getIn(['compose', 'privacy']) === 'limited' && state.getIn(['compose', 'reply_status', 'visibility']) === 'limited',
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
const mapDispatchToProps = dispatch => ({
|
const mapDispatchToProps = dispatch => ({
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue