0
0
Fork 0

Fix keyboard shortcuts and navigation in grouped notifications (#31076)

This commit is contained in:
Claire 2024-07-23 08:20:17 +02:00 committed by GitHub
parent 55705d8191
commit af06d74574
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 188 additions and 66 deletions

View file

@ -122,6 +122,18 @@ export function replyCompose(status) {
};
}
export function replyComposeById(statusId) {
return (dispatch, getState) => {
const state = getState();
const status = state.statuses.get(statusId);
if (status) {
const account = state.accounts.get(status.get('account'));
dispatch(replyCompose(status.set('account', account)));
}
};
}
export function cancelReplyCompose() {
return {
type: COMPOSE_REPLY_CANCEL,
@ -154,6 +166,12 @@ export function mentionCompose(account) {
};
}
export function mentionComposeById(accountId) {
return (dispatch, getState) => {
dispatch(mentionCompose(getState().accounts.get(accountId)));
};
}
export function directCompose(account) {
return (dispatch, getState) => {
dispatch({