Skip to content

Commit

Permalink
a
Browse files Browse the repository at this point in the history
  • Loading branch information
zizdlp committed Aug 24, 2024
1 parent c7af5e5 commit 9d55721
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import { MdBook } from "react-icons/md";
import { usePathname } from "@/navigation";
import SideBarLiContent from "./SideBarLiContent";
import { useTranslations } from "next-intl";
import { Lexend_Tera } from "next/font/google";
export default function UserSideBarSocial({
username,
count_following,
Expand Down
19 changes: 4 additions & 15 deletions zbook_frontend/src/components/wrappers/UpdateVisibilityButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@
import { fetchServerWithAuthWrapper } from "@/fetchs/server_with_auth";
import { FetchServerWithAuthWrapperEndPoint } from "@/fetchs/server_with_auth_util";
import React, { useState } from "react";
import { MdVisibility } from "react-icons/md";

import { MdOutlineVisibilityOff, MdVisibility } from "react-icons/md";
export default function UpdateVisibleButton({
username,
repo_name,
Expand Down Expand Up @@ -49,23 +48,13 @@ export default function UpdateVisibleButton({
});
}
}
// return (
// <>
// {isVisible && (
// <MdVisibility
// onClick={async () => {
// // await actionUpdateUserBlock();
// }}
// className="p-1 w-7 h-7 cursor-pointer text-gray-500 border dark:border-0 border-gray-200 rounded dark:bg-[#263142] hover:bg-sky-500 hover:text-white dark:hover:bg-gray-900 dark:text-gray-400"
// />
// )}
// </>
// );

return (
<div
className="bg-green-500 dark:bg-green-700 text-white rounded-lg py-2 px-4 font-semibold text-sm cursor-pointer hover:bg-green-600 dark:hover:bg-green-500"
className="bg-green-500 dark:bg-green-700 flex space-x-2 items-center text-white rounded-lg py-2 px-4 font-semibold text-sm cursor-pointer hover:bg-green-600 dark:hover:bg-green-500"
onClick={() => updateFollowStatus()}
>
{isVisible ? <MdVisibility /> : <MdOutlineVisibilityOff />}
<span className="flex-1 whitespace-nowrap">
{isVisible ? "取消" : "添加"}
</span>
Expand Down

0 comments on commit 9d55721

Please sign in to comment.