[MM-53333] Modified the delete category modal to contain a cancel button #24290 (#24317)

* Added cancel button in the delete category modal

Co-authored-by: Mattermost Build <build@mattermost.com>
This commit is contained in:
Zubair Imtiaz
2023-08-28 18:49:33 +05:00
committed by GitHub
parent 895150050f
commit 61dae292f7

View File

@@ -40,6 +40,10 @@ export default class DeleteCategoryModal extends React.PureComponent<Props, Stat
this.props.actions.deleteCategory(this.props.category.id);
};
handleCancel = () => {
this.props.onExited();
};
render() {
return (
<GenericModal
@@ -51,6 +55,7 @@ export default class DeleteCategoryModal extends React.PureComponent<Props, Stat
defaultMessage='Delete this category?'
/>
)}
handleCancel={this.handleCancel}
handleConfirm={this.handleConfirm}
confirmButtonText={(
<FormattedMessage