This commit is contained in:
mgabdev
2020-04-23 02:13:29 -04:00
parent fed036be08
commit e2e7e8c0af
177 changed files with 1231 additions and 1326 deletions

View File

@@ -18,8 +18,6 @@ const mapStateToProps = (state, { replyToId }) => {
const reduxReplyToId = state.getIn(['compose', 'in_reply_to'])
const isMatch = reduxReplyToId || replyToId ? reduxReplyToId === replyToId : true
// console.log("isMatch:", isMatch, reduxReplyToId, replyToId)
return {
isMatch,
edit: !isMatch ? null : state.getIn(['compose', 'id']) !== null,
@@ -41,6 +39,7 @@ const mapStateToProps = (state, { replyToId }) => {
scheduledAt: !isMatch ? null : state.getIn(['compose', 'scheduled_at']),
account: state.getIn(['accounts', me]),
hasPoll: !isMatch ? false : state.getIn(['compose', 'poll']),
reduxReplyToId,
}
}
@@ -50,8 +49,8 @@ const mapDispatchToProps = (dispatch) => ({
dispatch(changeCompose(text, markdown))
},
onSubmit(router, group) {
dispatch(submitCompose(router, group))
onSubmit(group, replyToId) {
dispatch(submitCompose(group, replyToId))
},
onClearSuggestions() {

View File

@@ -14,8 +14,8 @@ const mapStateToProps = (state) => ({
});
const mapDispatchToProps = (dispatch) => ({
onAddOption(title) {
dispatch(addPollOption(title));
onAddOption() {
dispatch(addPollOption(''))
},
onRemoveOption(index) {