From 97be0afd140c7c9e1fd03ba5ab4e486d90907129 Mon Sep 17 00:00:00 2001 From: Wolfboy248 Date: Tue, 19 Aug 2025 13:23:56 +0200 Subject: organised pages, started work on theme --- frontend/src/components/Sidebar.tsx | 43 +++++++++++++++++++++---------------- 1 file changed, 24 insertions(+), 19 deletions(-) (limited to 'frontend/src/components/Sidebar.tsx') diff --git a/frontend/src/components/Sidebar.tsx b/frontend/src/components/Sidebar.tsx index 88a5297..0083a3e 100644 --- a/frontend/src/components/Sidebar.tsx +++ b/frontend/src/components/Sidebar.tsx @@ -23,15 +23,15 @@ interface SidebarProps { onUploadRun: () => void; } -function OpenSidebarIcon(){ +function OpenSidebarIcon() { return ( - + ) } -function ClosedSidebarIcon(){ +function ClosedSidebarIcon() { return ( - ) + ) } const Sidebar: React.FC = ({ @@ -43,7 +43,7 @@ const Sidebar: React.FC = ({ const [searchData, setSearchData] = React.useState( undefined ); - const [isSidebarLocked, setIsSidebarLocked] = React.useState(false); + // const [isSidebarLocked, setIsSidebarLocked] = React.useState(false); const [isSidebarOpen, setSidebarOpen] = React.useState(false); const [selectedButtonIndex, setSelectedButtonIndex] = React.useState(1); @@ -100,17 +100,16 @@ const Sidebar: React.FC = ({ const getButtonClasses = (buttonIndex: number) => { const baseClasses = "flex items-center gap-3 w-full text-left bg-inherit cursor-pointer border-none rounded-lg py-3 px-3 transition-all duration-300 hover:bg-surface1"; const selectedClasses = selectedButtonIndex === buttonIndex ? "bg-primary text-background" : "bg-transparent text-foreground"; - + return `${baseClasses} ${selectedClasses}`; }; const iconClasses = "w-6 h-6 flex-shrink-0"; return ( -
-
+
+
Logo {isSidebarOpen && ( @@ -124,7 +123,7 @@ const Sidebar: React.FC = ({
)} - +
{/* Sidebar Content */} -
{isSidebarOpen && (
@@ -145,7 +144,7 @@ const Sidebar: React.FC = ({ Search Search
- +
= ({ ].map(({ to, refIndex, icon, alt, label }) => (
-