Fix reblogs of reblogs in UI, add follow form in UI
This commit is contained in:
parent
f24cb32e99
commit
d0e2733f63
10 changed files with 113 additions and 21 deletions
|
@ -1,5 +1,5 @@
|
|||
import { connect } from 'react-redux';
|
||||
import ComposerDrawer from '../components/composer_drawer';
|
||||
import ComposeForm from '../components/compose_form';
|
||||
import { changeCompose, submitCompose, cancelReplyCompose } from '../actions/compose';
|
||||
|
||||
const mapStateToProps = function (state, props) {
|
||||
|
@ -26,4 +26,4 @@ const mapDispatchToProps = function (dispatch) {
|
|||
}
|
||||
};
|
||||
|
||||
export default connect(mapStateToProps, mapDispatchToProps)(ComposerDrawer);
|
||||
export default connect(mapStateToProps, mapDispatchToProps)(ComposeForm);
|
|
@ -0,0 +1,24 @@
|
|||
import { connect } from 'react-redux';
|
||||
import FollowForm from '../components/follow_form';
|
||||
import { changeFollow, submitFollow } from '../actions/follow';
|
||||
|
||||
const mapStateToProps = function (state, props) {
|
||||
return {
|
||||
text: state.getIn(['follow', 'text']),
|
||||
is_submitting: state.getIn(['follow', 'is_submitting'])
|
||||
};
|
||||
};
|
||||
|
||||
const mapDispatchToProps = function (dispatch) {
|
||||
return {
|
||||
onChange: function (text) {
|
||||
dispatch(changeFollow(text));
|
||||
},
|
||||
|
||||
onSubmit: function () {
|
||||
dispatch(submitFollow());
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
export default connect(mapStateToProps, mapDispatchToProps)(FollowForm);
|
Loading…
Add table
Add a link
Reference in a new issue