mirror of
https://framagit.org/tykayn/mastodon.git
synced 2023-08-25 08:33:12 +02:00
🐛 remove logs
Signed-off-by: Baptiste Lemoine <contact@cipherbliss.com>
This commit is contained in:
parent
fa91d39338
commit
cda3febaac
@ -118,20 +118,20 @@ export function fetchAccount(id) {
|
||||
dispatch(fetchAccountFail(id, error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchAccountRequest(id) {
|
||||
return {
|
||||
type: ACCOUNT_FETCH_REQUEST,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchAccountSuccess() {
|
||||
return {
|
||||
type: ACCOUNT_FETCH_SUCCESS,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchAccountFail(id, error) {
|
||||
return {
|
||||
@ -140,7 +140,7 @@ export function fetchAccountFail(id, error) {
|
||||
error,
|
||||
skipAlert: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function followAccount(id, reblogs = true) {
|
||||
return (dispatch, getState) => {
|
||||
@ -155,7 +155,7 @@ export function followAccount(id, reblogs = true) {
|
||||
dispatch(followAccountFail(error, locked));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unfollowAccount(id) {
|
||||
return (dispatch, getState) => {
|
||||
@ -167,7 +167,7 @@ export function unfollowAccount(id) {
|
||||
dispatch(unfollowAccountFail(error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function followAccountRequest(id, locked) {
|
||||
return {
|
||||
@ -176,7 +176,7 @@ export function followAccountRequest(id, locked) {
|
||||
locked,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function followAccountSuccess(relationship, alreadyFollowing) {
|
||||
return {
|
||||
@ -185,7 +185,7 @@ export function followAccountSuccess(relationship, alreadyFollowing) {
|
||||
alreadyFollowing,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function followAccountFail(error, locked) {
|
||||
return {
|
||||
@ -194,7 +194,7 @@ export function followAccountFail(error, locked) {
|
||||
locked,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unfollowAccountRequest(id) {
|
||||
return {
|
||||
@ -202,7 +202,7 @@ export function unfollowAccountRequest(id) {
|
||||
id,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unfollowAccountSuccess(relationship, statuses) {
|
||||
return {
|
||||
@ -211,7 +211,7 @@ export function unfollowAccountSuccess(relationship, statuses) {
|
||||
statuses,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unfollowAccountFail(error) {
|
||||
return {
|
||||
@ -219,7 +219,7 @@ export function unfollowAccountFail(error) {
|
||||
error,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function blockAccount(id) {
|
||||
return (dispatch, getState) => {
|
||||
@ -232,7 +232,7 @@ export function blockAccount(id) {
|
||||
dispatch(blockAccountFail(id, error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unblockAccount(id) {
|
||||
return (dispatch, getState) => {
|
||||
@ -244,14 +244,14 @@ export function unblockAccount(id) {
|
||||
dispatch(unblockAccountFail(id, error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function blockAccountRequest(id) {
|
||||
return {
|
||||
type: ACCOUNT_BLOCK_REQUEST,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function blockAccountSuccess(relationship, statuses) {
|
||||
return {
|
||||
@ -259,35 +259,35 @@ export function blockAccountSuccess(relationship, statuses) {
|
||||
relationship,
|
||||
statuses,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function blockAccountFail(error) {
|
||||
return {
|
||||
type: ACCOUNT_BLOCK_FAIL,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unblockAccountRequest(id) {
|
||||
return {
|
||||
type: ACCOUNT_UNBLOCK_REQUEST,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unblockAccountSuccess(relationship) {
|
||||
return {
|
||||
type: ACCOUNT_UNBLOCK_SUCCESS,
|
||||
relationship,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unblockAccountFail(error) {
|
||||
return {
|
||||
type: ACCOUNT_UNBLOCK_FAIL,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function muteAccount(id, notifications) {
|
||||
return (dispatch, getState) => {
|
||||
@ -300,7 +300,7 @@ export function muteAccount(id, notifications) {
|
||||
dispatch(muteAccountFail(id, error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unmuteAccount(id) {
|
||||
return (dispatch, getState) => {
|
||||
@ -312,14 +312,14 @@ export function unmuteAccount(id) {
|
||||
dispatch(unmuteAccountFail(id, error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function muteAccountRequest(id) {
|
||||
return {
|
||||
type: ACCOUNT_MUTE_REQUEST,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function muteAccountSuccess(relationship, statuses) {
|
||||
return {
|
||||
@ -327,35 +327,35 @@ export function muteAccountSuccess(relationship, statuses) {
|
||||
relationship,
|
||||
statuses,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function muteAccountFail(error) {
|
||||
return {
|
||||
type: ACCOUNT_MUTE_FAIL,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unmuteAccountRequest(id) {
|
||||
return {
|
||||
type: ACCOUNT_UNMUTE_REQUEST,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unmuteAccountSuccess(relationship) {
|
||||
return {
|
||||
type: ACCOUNT_UNMUTE_SUCCESS,
|
||||
relationship,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unmuteAccountFail(error) {
|
||||
return {
|
||||
type: ACCOUNT_UNMUTE_FAIL,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchFollowers(id) {
|
||||
return (dispatch, getState) => {
|
||||
@ -371,14 +371,14 @@ export function fetchFollowers(id) {
|
||||
dispatch(fetchFollowersFail(id, error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchFollowersRequest(id) {
|
||||
return {
|
||||
type: FOLLOWERS_FETCH_REQUEST,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchFollowersSuccess(id, accounts, next) {
|
||||
return {
|
||||
@ -387,7 +387,7 @@ export function fetchFollowersSuccess(id, accounts, next) {
|
||||
accounts,
|
||||
next,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchFollowersFail(id, error) {
|
||||
return {
|
||||
@ -395,7 +395,7 @@ export function fetchFollowersFail(id, error) {
|
||||
id,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function expandFollowers(id) {
|
||||
return (dispatch, getState) => {
|
||||
@ -417,14 +417,14 @@ export function expandFollowers(id) {
|
||||
dispatch(expandFollowersFail(id, error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function expandFollowersRequest(id) {
|
||||
return {
|
||||
type: FOLLOWERS_EXPAND_REQUEST,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function expandFollowersSuccess(id, accounts, next) {
|
||||
return {
|
||||
@ -433,7 +433,7 @@ export function expandFollowersSuccess(id, accounts, next) {
|
||||
accounts,
|
||||
next,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function expandFollowersFail(id, error) {
|
||||
return {
|
||||
@ -441,7 +441,7 @@ export function expandFollowersFail(id, error) {
|
||||
id,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchFollowing(id) {
|
||||
return (dispatch, getState) => {
|
||||
@ -457,24 +457,23 @@ export function fetchFollowing(id) {
|
||||
dispatch(fetchFollowingFail(id, error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchFollowingRequest(id) {
|
||||
return {
|
||||
type: FOLLOWING_FETCH_REQUEST,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchFollowingSuccess(id, accounts, next) {
|
||||
console.log('id,accounts,next', id, accounts, next);
|
||||
return {
|
||||
type: FOLLOWING_FETCH_SUCCESS,
|
||||
id,
|
||||
accounts,
|
||||
next,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchFollowingFail(id, error) {
|
||||
return {
|
||||
@ -482,7 +481,7 @@ export function fetchFollowingFail(id, error) {
|
||||
id,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function expandFollowing(id) {
|
||||
return (dispatch, getState) => {
|
||||
@ -504,14 +503,14 @@ export function expandFollowing(id) {
|
||||
dispatch(expandFollowingFail(id, error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function expandFollowingRequest(id) {
|
||||
return {
|
||||
type: FOLLOWING_EXPAND_REQUEST,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function expandFollowingSuccess(id, accounts, next) {
|
||||
return {
|
||||
@ -520,7 +519,7 @@ export function expandFollowingSuccess(id, accounts, next) {
|
||||
accounts,
|
||||
next,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function expandFollowingFail(id, error) {
|
||||
return {
|
||||
@ -528,7 +527,7 @@ export function expandFollowingFail(id, error) {
|
||||
id,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchRelationships(accountIds) {
|
||||
return (dispatch, getState) => {
|
||||
@ -547,7 +546,7 @@ export function fetchRelationships(accountIds) {
|
||||
dispatch(fetchRelationshipsFail(error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchRelationshipsRequest(ids) {
|
||||
return {
|
||||
@ -555,7 +554,7 @@ export function fetchRelationshipsRequest(ids) {
|
||||
ids,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchRelationshipsSuccess(relationships) {
|
||||
return {
|
||||
@ -563,7 +562,7 @@ export function fetchRelationshipsSuccess(relationships) {
|
||||
relationships,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchRelationshipsFail(error) {
|
||||
return {
|
||||
@ -571,7 +570,7 @@ export function fetchRelationshipsFail(error) {
|
||||
error,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchFollowRequests() {
|
||||
return (dispatch, getState) => {
|
||||
@ -583,13 +582,13 @@ export function fetchFollowRequests() {
|
||||
dispatch(fetchFollowRequestsSuccess(response.data, next ? next.uri : null));
|
||||
}).catch(error => dispatch(fetchFollowRequestsFail(error)));
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchFollowRequestsRequest() {
|
||||
return {
|
||||
type: FOLLOW_REQUESTS_FETCH_REQUEST,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchFollowRequestsSuccess(accounts, next) {
|
||||
return {
|
||||
@ -597,14 +596,14 @@ export function fetchFollowRequestsSuccess(accounts, next) {
|
||||
accounts,
|
||||
next,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function fetchFollowRequestsFail(error) {
|
||||
return {
|
||||
type: FOLLOW_REQUESTS_FETCH_FAIL,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function expandFollowRequests() {
|
||||
return (dispatch, getState) => {
|
||||
@ -622,13 +621,13 @@ export function expandFollowRequests() {
|
||||
dispatch(expandFollowRequestsSuccess(response.data, next ? next.uri : null));
|
||||
}).catch(error => dispatch(expandFollowRequestsFail(error)));
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function expandFollowRequestsRequest() {
|
||||
return {
|
||||
type: FOLLOW_REQUESTS_EXPAND_REQUEST,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function expandFollowRequestsSuccess(accounts, next) {
|
||||
return {
|
||||
@ -636,14 +635,14 @@ export function expandFollowRequestsSuccess(accounts, next) {
|
||||
accounts,
|
||||
next,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function expandFollowRequestsFail(error) {
|
||||
return {
|
||||
type: FOLLOW_REQUESTS_EXPAND_FAIL,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function authorizeFollowRequest(id) {
|
||||
return (dispatch, getState) => {
|
||||
@ -654,21 +653,21 @@ export function authorizeFollowRequest(id) {
|
||||
.then(() => dispatch(authorizeFollowRequestSuccess(id)))
|
||||
.catch(error => dispatch(authorizeFollowRequestFail(id, error)));
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function authorizeFollowRequestRequest(id) {
|
||||
return {
|
||||
type: FOLLOW_REQUEST_AUTHORIZE_REQUEST,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function authorizeFollowRequestSuccess(id) {
|
||||
return {
|
||||
type: FOLLOW_REQUEST_AUTHORIZE_SUCCESS,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function authorizeFollowRequestFail(id, error) {
|
||||
return {
|
||||
@ -676,7 +675,7 @@ export function authorizeFollowRequestFail(id, error) {
|
||||
id,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function rejectFollowRequest(id) {
|
||||
return (dispatch, getState) => {
|
||||
@ -687,21 +686,21 @@ export function rejectFollowRequest(id) {
|
||||
.then(() => dispatch(rejectFollowRequestSuccess(id)))
|
||||
.catch(error => dispatch(rejectFollowRequestFail(id, error)));
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function rejectFollowRequestRequest(id) {
|
||||
return {
|
||||
type: FOLLOW_REQUEST_REJECT_REQUEST,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function rejectFollowRequestSuccess(id) {
|
||||
return {
|
||||
type: FOLLOW_REQUEST_REJECT_SUCCESS,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function rejectFollowRequestFail(id, error) {
|
||||
return {
|
||||
@ -709,7 +708,7 @@ export function rejectFollowRequestFail(id, error) {
|
||||
id,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function pinAccount(id) {
|
||||
return (dispatch, getState) => {
|
||||
@ -721,7 +720,7 @@ export function pinAccount(id) {
|
||||
dispatch(pinAccountFail(error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unpinAccount(id) {
|
||||
return (dispatch, getState) => {
|
||||
@ -733,46 +732,46 @@ export function unpinAccount(id) {
|
||||
dispatch(unpinAccountFail(error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function pinAccountRequest(id) {
|
||||
return {
|
||||
type: ACCOUNT_PIN_REQUEST,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function pinAccountSuccess(relationship) {
|
||||
return {
|
||||
type: ACCOUNT_PIN_SUCCESS,
|
||||
relationship,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function pinAccountFail(error) {
|
||||
return {
|
||||
type: ACCOUNT_PIN_FAIL,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unpinAccountRequest(id) {
|
||||
return {
|
||||
type: ACCOUNT_UNPIN_REQUEST,
|
||||
id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unpinAccountSuccess(relationship) {
|
||||
return {
|
||||
type: ACCOUNT_UNPIN_SUCCESS,
|
||||
relationship,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unpinAccountFail(error) {
|
||||
return {
|
||||
type: ACCOUNT_UNPIN_FAIL,
|
||||
error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
@ -75,7 +75,7 @@ export function changeCompose(text) {
|
||||
type: COMPOSE_CHANGE,
|
||||
text: text,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function replyCompose(status, routerHistory) {
|
||||
return (dispatch, getState) => {
|
||||
@ -86,19 +86,19 @@ export function replyCompose(status, routerHistory) {
|
||||
|
||||
ensureComposeIsVisible(getState, routerHistory);
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function cancelReplyCompose() {
|
||||
return {
|
||||
type: COMPOSE_REPLY_CANCEL,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function resetCompose() {
|
||||
return {
|
||||
type: COMPOSE_RESET,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function mentionCompose(account, routerHistory) {
|
||||
return (dispatch, getState) => {
|
||||
@ -109,7 +109,7 @@ export function mentionCompose(account, routerHistory) {
|
||||
|
||||
ensureComposeIsVisible(getState, routerHistory);
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function directCompose(account, routerHistory) {
|
||||
return (dispatch, getState) => {
|
||||
@ -120,7 +120,7 @@ export function directCompose(account, routerHistory) {
|
||||
|
||||
ensureComposeIsVisible(getState, routerHistory);
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function submitCompose(routerHistory) {
|
||||
return function (dispatch, getState) {
|
||||
@ -178,27 +178,27 @@ export function submitCompose(routerHistory) {
|
||||
dispatch(submitComposeFail(error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function submitComposeRequest() {
|
||||
return {
|
||||
type: COMPOSE_SUBMIT_REQUEST,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function submitComposeSuccess(status) {
|
||||
return {
|
||||
type : COMPOSE_SUBMIT_SUCCESS,
|
||||
status: status,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function submitComposeFail(error) {
|
||||
return {
|
||||
type : COMPOSE_SUBMIT_FAIL,
|
||||
error: error,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function uploadCompose(files) {
|
||||
return function (dispatch, getState) {
|
||||
@ -237,9 +237,9 @@ export function uploadCompose(files) {
|
||||
}).then(({ data }) => dispatch(uploadComposeSuccess(data, f)));
|
||||
}).catch(error => dispatch(uploadComposeFail(error)));
|
||||
}
|
||||
;
|
||||
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function changeUploadCompose(id, params) {
|
||||
return (dispatch, getState) => {
|
||||
@ -251,14 +251,14 @@ export function changeUploadCompose(id, params) {
|
||||
dispatch(changeUploadComposeFail(id, error));
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function changeUploadComposeRequest() {
|
||||
return {
|
||||
type : COMPOSE_UPLOAD_CHANGE_REQUEST,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function changeUploadComposeSuccess(media) {
|
||||
return {
|
||||
@ -266,7 +266,7 @@ export function changeUploadComposeSuccess(media) {
|
||||
media : media,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function changeUploadComposeFail(error) {
|
||||
return {
|
||||
@ -274,14 +274,14 @@ export function changeUploadComposeFail(error) {
|
||||
error : error,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function uploadComposeRequest() {
|
||||
return {
|
||||
type : COMPOSE_UPLOAD_REQUEST,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function uploadComposeProgress(loaded, total) {
|
||||
return {
|
||||
@ -289,7 +289,7 @@ export function uploadComposeProgress(loaded, total) {
|
||||
loaded: loaded,
|
||||
total : total,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function uploadComposeSuccess(media, file) {
|
||||
return {
|
||||
@ -298,7 +298,7 @@ export function uploadComposeSuccess(media, file) {
|
||||
file : file,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function uploadComposeFail(error) {
|
||||
return {
|
||||
@ -306,14 +306,14 @@ export function uploadComposeFail(error) {
|
||||
error : error,
|
||||
skipLoading: true,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function undoUploadCompose(media_id) {
|
||||
return {
|
||||
type : COMPOSE_UPLOAD_UNDO,
|
||||
media_id: media_id,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function clearComposeSuggestions() {
|
||||
if (cancelFetchComposeSuggestionsAccounts) {
|
||||
@ -322,7 +322,7 @@ export function clearComposeSuggestions() {
|
||||
return {
|
||||
type: COMPOSE_SUGGESTIONS_CLEAR,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
const fetchComposeSuggestionsAccounts = throttle((dispatch, getState, token) => {
|
||||
if (cancelFetchComposeSuggestionsAccounts) {
|
||||
@ -396,7 +396,7 @@ export function fetchComposeSuggestions(token) {
|
||||
break;
|
||||
}
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function readyComposeSuggestionsEmojis(token, emojis) {
|
||||
return {
|
||||
@ -404,7 +404,7 @@ export function readyComposeSuggestionsEmojis(token, emojis) {
|
||||
token,
|
||||
emojis,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function readyComposeSuggestionsAccounts(token, accounts) {
|
||||
return {
|
||||
@ -412,7 +412,7 @@ export function readyComposeSuggestionsAccounts(token, accounts) {
|
||||
token,
|
||||
accounts,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export const readyComposeSuggestionsTags = (token, tags) => ({
|
||||
type: COMPOSE_SUGGESTIONS_READY,
|
||||
@ -445,7 +445,7 @@ export function selectComposeSuggestion(position, token, suggestion, path) {
|
||||
path,
|
||||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function updateSuggestionTags(token) {
|
||||
return {
|
||||
@ -464,7 +464,6 @@ export function updateTagHistory(tags) {
|
||||
export function hydrateCompose() {
|
||||
return (dispatch, getState) => {
|
||||
const me = getState().getIn(['meta', 'me']);
|
||||
console.log('my user id:', me);
|
||||
const history = tagHistory.get(me);
|
||||
|
||||
if (history !== null) {
|
||||
@ -494,39 +493,39 @@ export function mountCompose() {
|
||||
return {
|
||||
type: COMPOSE_MOUNT,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function unmountCompose() {
|
||||
return {
|
||||
type: COMPOSE_UNMOUNT,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function changeComposeSensitivity() {
|
||||
return {
|
||||
type: COMPOSE_SENSITIVITY_CHANGE,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function changeComposeSpoilerness() {
|
||||
return {
|
||||
type: COMPOSE_SPOILERNESS_CHANGE,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function changeComposeSpoilerText(text) {
|
||||
return {
|
||||
type: COMPOSE_SPOILER_TEXT_CHANGE,
|
||||
text,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function changeComposeVisibility(value) {
|
||||
return {
|
||||
type: COMPOSE_VISIBILITY_CHANGE,
|
||||
value,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function insertEmojiCompose(position, emoji, needsSpace) {
|
||||
return {
|
||||
@ -535,33 +534,33 @@ export function insertEmojiCompose(position, emoji, needsSpace) {
|
||||
emoji,
|
||||
needsSpace,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function changeComposing(value) {
|
||||
return {
|
||||
type: COMPOSE_COMPOSING_CHANGE,
|
||||
value,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function addPoll() {
|
||||
return {
|
||||
type: COMPOSE_POLL_ADD,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function removePoll() {
|
||||
return {
|
||||
type: COMPOSE_POLL_REMOVE,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function addPollOption(title) {
|
||||
return {
|
||||
type: COMPOSE_POLL_OPTION_ADD,
|
||||
title,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function changePollOption(index, title) {
|
||||
return {
|
||||
@ -569,14 +568,14 @@ export function changePollOption(index, title) {
|
||||
index,
|
||||
title,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function removePollOption(index) {
|
||||
return {
|
||||
type: COMPOSE_POLL_OPTION_REMOVE,
|
||||
index,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
export function changePollSettings(expiresIn, isMultiple) {
|
||||
return {
|
||||
@ -584,4 +583,4 @@ export function changePollSettings(expiresIn, isMultiple) {
|
||||
expiresIn,
|
||||
isMultiple,
|
||||
};
|
||||
};
|
||||
}
|
||||
|
@ -20,7 +20,6 @@ const emptyList = ImmutableList();
|
||||
const mapStateToProps = (state, { params: { accountId }, withReplies = false }) => {
|
||||
const path = withReplies ? `${accountId}:with_replies` : accountId;
|
||||
|
||||
console.log('state.getIn([\'accounts\', accountId])', state.getIn(['accounts', accountId]));
|
||||
return {
|
||||
isAccount : !!state.getIn(['accounts', accountId]),
|
||||
account : state.getIn(['accounts', accountId]),
|
||||
|
@ -63,7 +63,6 @@ class LinkFooter extends React.PureComponent {
|
||||
|
||||
var weekNumber = (new Date()).getWeek();
|
||||
// display snow during the last two weeks of the year
|
||||
console.log('week', weekNumber);
|
||||
const shouldWeDisplaySnow = (weekNumber > props.minimumWeekToShowSnow) && props.enableChristmasSnow;
|
||||
|
||||
this.state = {
|
||||
@ -77,7 +76,6 @@ class LinkFooter extends React.PureComponent {
|
||||
.then((snowstorm) => {
|
||||
Window.snowstorm = snowstorm.default;
|
||||
this.state.snow = Window.snowstorm;
|
||||
console.log('this.state.snow ', this.state.snow);
|
||||
// snowstorm.start();
|
||||
this.state.snowActive = true;
|
||||
})
|
||||
@ -87,7 +85,6 @@ class LinkFooter extends React.PureComponent {
|
||||
}
|
||||
|
||||
toggleSnow = () => {
|
||||
console.log('toggle snow');
|
||||
if (this.state.snow) {
|
||||
if (this.state.snowActive) {
|
||||
this.state.snow.stop();
|
||||
|
@ -34,7 +34,6 @@ export default class ContactsList extends ImmutablePureComponent {
|
||||
contactList : mockContactList,
|
||||
conversationList: mockContactList,
|
||||
};
|
||||
console.log('this.state', this.state);
|
||||
// this.fetchContacts(1);
|
||||
}
|
||||
|
||||
@ -63,13 +62,11 @@ export default class ContactsList extends ImmutablePureComponent {
|
||||
|
||||
render() {
|
||||
|
||||
console.log('this.state', this.state);
|
||||
let renderedList = (
|
||||
<span >no contacts</span >
|
||||
);
|
||||
if (this.props.contactList) {
|
||||
renderedList = this.props.contactList.map(account => {
|
||||
console.log('elem', account);
|
||||
return (
|
||||
<li
|
||||
className='contact-item'
|
||||
|
@ -2,6 +2,8 @@ import React from 'react';
|
||||
|
||||
import PropTypes from 'prop-types';
|
||||
import { mockContactList } from './mockContactList';
|
||||
import Contact from './Contact';
|
||||
import ConversationItem from './conversation-item';
|
||||
|
||||
const following = mockContactList;
|
||||
|
||||
@ -25,13 +27,15 @@ export default class ConversationStack extends React.Component {
|
||||
return this.props.following.map(elem =>
|
||||
|
||||
(<li className='user-item'>
|
||||
<div
|
||||
className='username'
|
||||
onClick={this.openConversationWith(elem)}
|
||||
>
|
||||
Machin {elem.username}
|
||||
<div className='conversation-box'>
|
||||
<div
|
||||
className='conversation-header'
|
||||
onClick={this.openConversationWith(elem)}
|
||||
>
|
||||
<Contact account={elem} />
|
||||
</div >
|
||||
<ConversationItem />
|
||||
</div >
|
||||
<div className='last-active'>3 min</div >
|
||||
</li >),
|
||||
);
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user