lint
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
import { cn } from "@/lib/utils";
|
||||
import Link from "next/link";
|
||||
import { usePathname, useRouter } from "next/navigation";
|
||||
import { useCallback, useState } from "react";
|
||||
import { useState } from "react";
|
||||
import {
|
||||
Drawer,
|
||||
DrawerContent,
|
||||
|
||||
@@ -46,7 +46,7 @@ export function NavUser({ user, isUserLoading }: { user: User | undefined, isUse
|
||||
localStorage.removeItem(UserApi.USER_ME_CACHE_KEY)
|
||||
toast.success('登出成功');
|
||||
router.replace('/console/login');
|
||||
} catch (error) {
|
||||
} catch {
|
||||
toast.error('登出失败,请稍后再试');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
'use client';
|
||||
|
||||
import { SeparatorProps } from "@radix-ui/react-separator";
|
||||
import { Button } from "@/components/ui/button"
|
||||
import {
|
||||
Dialog,
|
||||
@@ -9,7 +8,6 @@ import {
|
||||
DialogFooter,
|
||||
DialogHeader,
|
||||
DialogTitle,
|
||||
DialogTrigger,
|
||||
} from "@/components/ui/dialog"
|
||||
import { Input } from "@/components/ui/input"
|
||||
import { Label } from "@/components/ui/label"
|
||||
|
||||
@@ -10,11 +10,7 @@ import {
|
||||
} from "@/components/ui/dialog"
|
||||
import { Button } from "../ui/button";
|
||||
|
||||
interface UserProfileProps {
|
||||
|
||||
}
|
||||
|
||||
export default function ({ onOpenChange, ...props }: UserProfileProps & React.ComponentProps<FC<DialogProps>>) {
|
||||
export default function UserProfile({ onOpenChange, ...props }: React.ComponentProps<FC<DialogProps>>) {
|
||||
return (
|
||||
<Dialog onOpenChange={onOpenChange} {...props}>
|
||||
<DialogContent className="sm:max-w-[425px]">
|
||||
|
||||
Reference in New Issue
Block a user