Skip to content

Commit

Permalink
Add rank menu
Browse files Browse the repository at this point in the history
  • Loading branch information
slhmy committed Aug 3, 2024
1 parent 15b82d2 commit 0bad752
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 0 deletions.
26 changes: 26 additions & 0 deletions src/components/icons/tabler/AwardIcon.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
import { FC } from "react";
import { DefaultIconStrokeWidth } from "./defaults";

const AwardIcon: FC<{
className?: string;
}> = (props) => {
return (
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 24 24"
fill="none"
stroke="currentColor"
strokeWidth={DefaultIconStrokeWidth}
strokeLinecap="round"
strokeLinejoin="round"
className={props.className}
>
<path stroke="none" d="M0 0h24v24H0z" fill="none" />
<path d="M12 9m-6 0a6 6 0 1 0 12 0a6 6 0 1 0 -12 0" />
<path d="M12 15l3.4 5.89l1.598 -3.233l3.598 .232l-3.4 -5.889" />
<path d="M6.802 12l-3.4 5.89l3.598 -.233l1.598 3.232l3.4 -5.889" />
</svg>
);
};

export default AwardIcon;
2 changes: 2 additions & 0 deletions src/layouts/Menu.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import ActivityIcon from "@/components/icons/tabler/ActivityIcon";
import AwardIcon from "@/components/icons/tabler/AwardIcon";
import FileTextIcon from "@/components/icons/tabler/FileTextIcon";
import PackageIcon from "@/components/icons/tabler/PackageIcon";
import UsersIcon from "@/components/icons/tabler/UsersIcon";
Expand All @@ -9,6 +10,7 @@ import { useNavigate } from "react-router-dom";
const navigation = [
{ name: "Problems", href: "/problem", icon: FileTextIcon },
{ name: "Judges", href: "/judge", icon: ActivityIcon },
{ name: "Rank", href: "/rank", icon: AwardIcon },
];

const adminNavigation = [
Expand Down
2 changes: 2 additions & 0 deletions src/routes/Router.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ const PageRouter: React.FC = () => {
<Route path="problem/:slug" element={<Problem />} />
<Route path="/judge" element={<JudgeList />} />
<Route path="/judge/:uid" element={<Judge />} />
<Route path="/rank" element={<div>rank</div>} />
{/* Admin */}
<Route
path="admin"
element={<Navigate replace to="/admin/problem" />}
Expand Down

0 comments on commit 0bad752

Please sign in to comment.