From ccc496319d6f0187eb82711d0c24f2b2f447acbf Mon Sep 17 00:00:00 2001 From: wibus-wee <1596355173@qq.com> Date: Tue, 29 Oct 2024 14:11:22 +0800 Subject: [PATCH] style: lint fix --- .../widgets/ThemeComponent/ThemeTextarea.tsx | 3 ++- src/components/widgets/ThemeComponent/index.tsx | 8 ++++---- src/pages/Categories/index.tsx | 2 -- src/pages/Comments/component.tsx | 12 +++--------- 4 files changed, 9 insertions(+), 16 deletions(-) diff --git a/src/components/widgets/ThemeComponent/ThemeTextarea.tsx b/src/components/widgets/ThemeComponent/ThemeTextarea.tsx index 32e70b4..7dcd237 100644 --- a/src/components/widgets/ThemeComponent/ThemeTextarea.tsx +++ b/src/components/widgets/ThemeComponent/ThemeTextarea.tsx @@ -1,4 +1,5 @@ -import { Textarea, TextareaProps } from "@components/ui/textarea"; +import type { TextareaProps } from "@components/ui/textarea"; +import { Textarea } from "@components/ui/textarea"; import { Label } from "@components/ui/label"; export const ThemeTextarea: React.FC< diff --git a/src/components/widgets/ThemeComponent/index.tsx b/src/components/widgets/ThemeComponent/index.tsx index 09ad480..f8d06c5 100644 --- a/src/components/widgets/ThemeComponent/index.tsx +++ b/src/components/widgets/ThemeComponent/index.tsx @@ -4,13 +4,13 @@ import type { RadioProps } from "@components/universal/Radio"; import { Radio } from "@components/universal/Radio"; import type { ColorProps } from "@components/universal/Color"; import { Color } from "@components/universal/Color"; -import { ModalBody } from "@components/universal/Modal"; import type { SelectProps } from "./ThemeSelect"; import { Select } from "./ThemeSelect"; -import { Input, InputProps } from "@components/ui/input"; -import { TextareaProps } from "@components/ui/textarea"; +import type { InputProps } from "@components/ui/input"; +import { Input } from "@components/ui/input"; +import type { TextareaProps } from "@components/ui/textarea"; import { Checkbox } from "@components/ui/checkbox"; -import { CheckboxProps } from "@radix-ui/react-checkbox"; +import type { CheckboxProps } from "@radix-ui/react-checkbox"; import { ThemeTextarea } from "./ThemeTextarea"; import { Label } from "@components/ui/label"; diff --git a/src/pages/Categories/index.tsx b/src/pages/Categories/index.tsx index 7f23b3c..687e8f4 100644 --- a/src/pages/Categories/index.tsx +++ b/src/pages/Categories/index.tsx @@ -4,7 +4,6 @@ import { useEffect, useState } from "react"; import { useNavigate } from "react-router-dom"; import { useSnapshot } from "valtio"; import { Loading } from "@components/universal/Loading"; -import { Modal } from "@components/universal/Modal"; import { Title } from "@components/universal/Title"; import { server } from "@states/app"; import type { BasicPage } from "@type/basic"; @@ -14,7 +13,6 @@ import { useSeo } from "@hooks/useSeo"; import { toast } from "sonner"; import useSWR from "swr"; import { ActionButton, ActionButtons } from "@components/widgets/ActionButtons"; -import { jump } from "@utils/path"; import { Dialog, DialogContent, diff --git a/src/pages/Comments/component.tsx b/src/pages/Comments/component.tsx index 5b66abb..ab0a35d 100644 --- a/src/pages/Comments/component.tsx +++ b/src/pages/Comments/component.tsx @@ -1,16 +1,10 @@ -import postStyles from "@pages/Posts/Index/index.module.css"; -import styles from "./index.module.css"; import { Modal, ModalBody } from "@components/universal/Modal"; -import { - TableContainer, - TableItem, - TableItemValue, -} from "@pages/Home/universal"; + + import { Input } from "@components/ui/input"; import { Textarea } from "@components/ui/textarea"; import { apiClient } from "@utils/request"; -import clsx from "clsx"; -import { useCallback, useEffect, useMemo, useState } from "react"; +import { useEffect, useState } from "react"; import useSWR from "swr"; import useSWRMutation from "swr/mutation"; import { Select } from "@components/widgets/ThemeComponent/ThemeSelect";