Add shortcuts for forward/delete selected/targeted messages
This commit is contained in:
parent
dd16be13b0
commit
d0f17a1398
9 changed files with 106 additions and 35 deletions
|
@ -10,7 +10,8 @@ type ConfirmationDialogViewProps = {
|
|||
dialogName: string;
|
||||
cancelText?: string;
|
||||
confirmStyle?: 'affirmative' | 'negative';
|
||||
message: string;
|
||||
title: string;
|
||||
description?: string;
|
||||
okText: string;
|
||||
reject?: (error: Error) => void;
|
||||
resolve: () => void;
|
||||
|
@ -24,6 +25,8 @@ function removeConfirmationDialog() {
|
|||
return;
|
||||
}
|
||||
|
||||
window.reduxActions.globalModals.toggleConfirmationModal(false);
|
||||
|
||||
unmountComponentAtNode(confirmationDialogViewNode);
|
||||
document.body.removeChild(confirmationDialogViewNode);
|
||||
|
||||
|
@ -43,6 +46,8 @@ export function showConfirmationDialog(
|
|||
removeConfirmationDialog();
|
||||
}
|
||||
|
||||
window.reduxActions.globalModals.toggleConfirmationModal(true);
|
||||
|
||||
confirmationDialogViewNode = document.createElement('div');
|
||||
document.body.appendChild(confirmationDialogViewNode);
|
||||
|
||||
|
@ -71,8 +76,10 @@ export function showConfirmationDialog(
|
|||
onClose={() => {
|
||||
removeConfirmationDialog();
|
||||
}}
|
||||
title={options.message}
|
||||
/>,
|
||||
title={options.title}
|
||||
>
|
||||
{options.description}
|
||||
</ConfirmationDialog>,
|
||||
confirmationDialogViewNode
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue