diff --git a/apps/renderer/src/modules/trending/index.tsx b/apps/renderer/src/modules/trending/index.tsx index 870fb63bb..511dd3e8c 100644 --- a/apps/renderer/src/modules/trending/index.tsx +++ b/apps/renderer/src/modules/trending/index.tsx @@ -1,5 +1,5 @@ import type { User } from "@auth/core/types" -import { isMobile } from "@follow/components/hooks/useMobile.js" +import { isMobile, useMobile } from "@follow/components/hooks/useMobile.js" import { PhUsersBold } from "@follow/components/icons/users.jsx" import { Avatar, AvatarFallback, AvatarImage } from "@follow/components/ui/avatar/index.jsx" import { ActionButton, Button } from "@follow/components/ui/button/index.js" @@ -33,7 +33,12 @@ export const TrendingButton = ({ language, className }: TrendingProps & { classN variant={"outline"} onClick={() => { present({ - title: t("words.trending"), + title: ( +
+ + {t("words.trending")} +
+ ), content: () => , CustomModalComponent: !isMobile() ? DrawerModalLayout : undefined, }) @@ -46,6 +51,8 @@ export const TrendingButton = ({ language, className }: TrendingProps & { classN ) } const TrendContent: FC = ({ language }) => { + const isMobile = useMobile() + const { data } = useQuery({ queryKey: ["trending", language], queryFn: () => { @@ -66,10 +73,12 @@ const TrendContent: FC = ({ language }) => { ) return (
-
- - {t("words.trending")} -
+ {!isMobile && ( +
+ + {t("words.trending")} +
+ )} = ({ language }) => {