diff options
Diffstat (limited to 'frontend/src/components/Sidebar.tsx')
| -rw-r--r-- | frontend/src/components/Sidebar.tsx | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/frontend/src/components/Sidebar.tsx b/frontend/src/components/Sidebar.tsx index a8834b6..d303927 100644 --- a/frontend/src/components/Sidebar.tsx +++ b/frontend/src/components/Sidebar.tsx | |||
| @@ -90,13 +90,13 @@ const Sidebar: React.FC<SidebarProps> = ({ setToken, profile, setProfile }) => { | |||
| 90 | 90 | ||
| 91 | React.useEffect(() => { | 91 | React.useEffect(() => { |
| 92 | if (path === "/") { handle_sidebar_click(1) } | 92 | if (path === "/") { handle_sidebar_click(1) } |
| 93 | else if (path.includes("news")) { handle_sidebar_click(2) } | 93 | else if (path.includes("games")) { handle_sidebar_click(2) } |
| 94 | else if (path.includes("games")) { handle_sidebar_click(3) } | 94 | else if (path.includes("rankings")) { handle_sidebar_click(3) } |
| 95 | else if (path.includes("leaderboards")) { handle_sidebar_click(4) } | 95 | // else if (path.includes("news")) { handle_sidebar_click(4) } |
| 96 | else if (path.includes("scorelog")) { handle_sidebar_click(5) } | 96 | // else if (path.includes("scorelog")) { handle_sidebar_click(5) } |
| 97 | else if (path.includes("profile")) { handle_sidebar_click(6) } | 97 | else if (path.includes("profile")) { handle_sidebar_click(4) } |
| 98 | else if (path.includes("rules")) { handle_sidebar_click(8) } | 98 | else if (path.includes("rules")) { handle_sidebar_click(5) } |
| 99 | else if (path.includes("about")) { handle_sidebar_click(9) } | 99 | else if (path.includes("about")) { handle_sidebar_click(6) } |
| 100 | }, [path]); | 100 | }, [path]); |
| 101 | 101 | ||
| 102 | return ( | 102 | return ( |
| @@ -121,21 +121,21 @@ const Sidebar: React.FC<SidebarProps> = ({ setToken, profile, setProfile }) => { | |||
| 121 | <button className='sidebar-button'><img src={HomeIcon} alt="homepage" /><span>Home Page</span></button> | 121 | <button className='sidebar-button'><img src={HomeIcon} alt="homepage" /><span>Home Page</span></button> |
| 122 | </Link> | 122 | </Link> |
| 123 | 123 | ||
| 124 | <Link to="/news" tabIndex={-1}> | ||
| 125 | <button className='sidebar-button'><img src={NewsIcon} alt="news" /><span>News</span></button> | ||
| 126 | </Link> | ||
| 127 | |||
| 128 | <Link to="/games" tabIndex={-1}> | 124 | <Link to="/games" tabIndex={-1}> |
| 129 | <button className='sidebar-button'><img src={PortalIcon} alt="games" /><span>Games</span></button> | 125 | <button className='sidebar-button'><img src={PortalIcon} alt="games" /><span>Games</span></button> |
| 130 | </Link> | 126 | </Link> |
| 131 | 127 | ||
| 132 | <Link to="/leaderboards" tabIndex={-1}> | 128 | <Link to="/rankings" tabIndex={-1}> |
| 133 | <button className='sidebar-button'><img src={FlagIcon} alt="leaderboards" /><span>Leaderboards</span></button> | 129 | <button className='sidebar-button'><img src={FlagIcon} alt="rankings" /><span>Rankings</span></button> |
| 134 | </Link> | 130 | </Link> |
| 135 | 131 | ||
| 136 | <Link to="/scorelog" tabIndex={-1}> | 132 | {/* <Link to="/news" tabIndex={-1}> |
| 133 | <button className='sidebar-button'><img src={NewsIcon} alt="news" /><span>News</span></button> | ||
| 134 | </Link> */} | ||
| 135 | |||
| 136 | {/* <Link to="/scorelog" tabIndex={-1}> | ||
| 137 | <button className='sidebar-button'><img src={TableIcon} alt="scorelogs" /><span>Score Logs</span></button> | 137 | <button className='sidebar-button'><img src={TableIcon} alt="scorelogs" /><span>Score Logs</span></button> |
| 138 | </Link> | 138 | </Link> */} |
| 139 | </div> | 139 | </div> |
| 140 | <div id='sidebar-bottomlist'> | 140 | <div id='sidebar-bottomlist'> |
| 141 | <span></span> | 141 | <span></span> |