From eb7da996a7c2d617d276f296cac07a6fd5648664 Mon Sep 17 00:00:00 2001
From: Mohamed Bassem
Date: Sun, 27 Oct 2024 12:03:14 +0000
Subject: ui: Redesign the settings page and move it to its own layout
---
.../components/dashboard/settings/DeleteApiKey.tsx | 55 ----------------------
1 file changed, 55 deletions(-)
delete mode 100644 apps/web/components/dashboard/settings/DeleteApiKey.tsx
(limited to 'apps/web/components/dashboard/settings/DeleteApiKey.tsx')
diff --git a/apps/web/components/dashboard/settings/DeleteApiKey.tsx b/apps/web/components/dashboard/settings/DeleteApiKey.tsx
deleted file mode 100644
index e2334c44..00000000
--- a/apps/web/components/dashboard/settings/DeleteApiKey.tsx
+++ /dev/null
@@ -1,55 +0,0 @@
-"use client";
-
-import { useRouter } from "next/navigation";
-import { ActionButton } from "@/components/ui/action-button";
-import ActionConfirmingDialog from "@/components/ui/action-confirming-dialog";
-import { Button } from "@/components/ui/button";
-import { toast } from "@/components/ui/use-toast";
-import { api } from "@/lib/trpc";
-import { Trash } from "lucide-react";
-
-export default function DeleteApiKey({
- name,
- id,
-}: {
- name: string;
- id: string;
-}) {
- const router = useRouter();
- const mutator = api.apiKeys.revoke.useMutation({
- onSuccess: () => {
- toast({
- description: "Key was successfully deleted",
- });
- router.refresh();
- },
- });
-
- return (
-
- Are you sure you want to delete the API key "{name}"? Any
- service using this API key will lose access.
-
- }
- actionButton={(setDialogOpen) => (
-
- mutator.mutate({ id }, { onSuccess: () => setDialogOpen(false) })
- }
- >
- Delete
-
- )}
- >
-
-
- );
-}
--
cgit v1.2.3-70-g09d2