chore: made requested changes

Signed-off-by: Adithya Krishna <adi@documenso.com>
This commit is contained in:
Adithya Krishna
2023-12-20 10:36:06 +05:30
parent 1af909835d
commit 84a0c39810

View File

@ -41,10 +41,16 @@ export const DeleteDocumentDialog = ({
const { mutateAsync: deleteDocument, isLoading } = trpcReact.document.deleteDocument.useMutation({
onSuccess: () => {
router.refresh();
const deletedFileToastDescription = (
<p>
Your document <span className="text-documenso">{documentTitle}</span> has been
successfully deleted.
</p>
);
toast({
title: 'Document deleted',
description: `Your document "${documentTitle}" has been successfully deleted.`,
description: deletedFileToastDescription,
duration: 5000,
});
@ -74,7 +80,10 @@ export const DeleteDocumentDialog = ({
<Dialog open={open} onOpenChange={(value) => !isLoading && onOpenChange(value)}>
<DialogContent>
<DialogHeader>
<DialogTitle>Do you want to delete this document?</DialogTitle>
<DialogTitle>
Do you want to delete the <span className="text-documenso">{documentTitle}</span>{' '}
document?
</DialogTitle>
<DialogDescription>
Please note that this action is irreversible. Once confirmed, your document will be
@ -83,7 +92,7 @@ export const DeleteDocumentDialog = ({
</DialogHeader>
{status !== DocumentStatus.DRAFT && (
<div className="mt-8">
<div className="mt-4">
<Input
type="text"
value={inputValue}