Skip to content

Commit

Permalink
chore: add some loading indications
Browse files Browse the repository at this point in the history
  • Loading branch information
itsjoeoui committed May 5, 2024
1 parent 73461a0 commit 89baec2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -348,6 +348,7 @@ function DeleteCategoryButton({ id }: { id: string }) {
<AlertDialogAction
onClick={() =>
toast.promise(deleteCategory.mutateAsync({ id }), {
loading: "Deleting category...",
success: "Category deleted!",
error: "Failed to delete category",
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,8 @@ function CategoryForm({ category }: { category: TransactionTypeEnum }) {
categoryType: tsTransactionTypeToProto(category),
}),
{
loading: "Working on it...",
error: "Something went wrong :(",
success: "Success!",
},
);
Expand Down

0 comments on commit 89baec2

Please sign in to comment.