@@ -39,7 +39,7 @@ import { Separator } from '@/components/ui/separator';
3939const formSchema = z . object ( {
4040 email : z . string ( ) . email ( 'Please enter a valid email address' ) ,
4141 password : z . string ( ) . min ( 1 , 'Password is required' ) ,
42- confirmText : z . literal ( ' DELETE') ,
42+ confirmText : z . string ( ) . min ( 1 , 'Please type " DELETE" to confirm ') ,
4343} ) ;
4444
4545export function AccountDeletion ( ) {
@@ -53,7 +53,7 @@ export function AccountDeletion() {
5353 defaultValues : {
5454 email : '' ,
5555 password : '' ,
56- confirmText : 'DELETE ' ,
56+ confirmText : '' ,
5757 } ,
5858 } ) ;
5959
@@ -105,11 +105,11 @@ export function AccountDeletion() {
105105 Account Deletion
106106 </ h3 >
107107 </ div >
108- < p className = "text-slate-300 text-sm" >
108+ < p className = "text-slate-700 text-sm" >
109109 Deleting your account will remove all your data and cannot be
110110 reversed after the grace period.
111111 </ p >
112- < div className = "mt-1 hidden text-slate-400 text-xs italic md:block" >
112+ < div className = "mt-1 hidden text-slate-600 text-xs italic md:block" >
113113 A 30-day recovery window will be available before permanent
114114 deletion.
115115 </ div >
@@ -126,13 +126,16 @@ export function AccountDeletion() {
126126 </ Button >
127127 </ AlertDialogTrigger >
128128 < AlertDialogContent className = "max-w-xl border border-red-900/30 bg-slate-950" >
129- < div className = "-top-12 -translate-x-1/2 absolute left-1/2 transform rounded-full bg-red-500 p-3 text-white" >
130- < WarningIcon className = "h-6 w-6" size = { 24 } weight = "duotone" />
131- </ div >
132-
133129 < AlertDialogHeader className = "pt-6" >
134130 < AlertDialogTitle className = "text-center text-red-400 text-xl" >
135- Delete Your Account
131+ < div className = "flex items-center justify-center gap-2 rounded-full bg-red-500 p-2 text-white" >
132+ < WarningIcon
133+ className = "h-6 w-6 bg-red-500 text-white"
134+ size = { 24 }
135+ weight = "duotone"
136+ />
137+ Delete Your Account
138+ </ div >
136139 </ AlertDialogTitle >
137140 < AlertDialogDescription className = "text-center text-slate-300" >
138141 This action will schedule your account for deletion after a
@@ -255,12 +258,12 @@ export function AccountDeletion() {
255258 ) }
256259 />
257260
258- < AlertDialogFooter className = "gap-3 pt-2 sm:gap-0 " >
259- < AlertDialogCancel className = "mt-0 border-slate-700 bg-transparent text-slate-300 hover:bg-slate-800 hover:text-white" >
261+ < AlertDialogFooter className = "gap-0 sm:gap-3 " >
262+ < AlertDialogCancel className = "border-slate-700 bg-transparent text-slate-300 hover:bg-slate-800 hover:text-white" >
260263 Cancel
261264 </ AlertDialogCancel >
262265 < Button
263- className = "border-red-600 bg-red-700 text-white hover:bg-red-600 "
266+ className = "border-red-600 bg-red-700 text-white hover:bg-red-800 "
264267 disabled = { isLoading }
265268 type = "submit"
266269 variant = "destructive"
0 commit comments