Fix sidebar (again)

This commit is contained in:
keannu125 2023-02-21 14:25:55 +08:00
parent c08d927f01
commit 308f193756
2 changed files with 32 additions and 22 deletions

View file

@ -57,34 +57,45 @@ export default function Sidebar() {
); );
} else { } else {
return ( return (
<div style={styles.sidebar_wrapper}> <div style={styles.sidebar_container}>
<div <div
style={{ style={{
position: "relative",
display: "flex", display: "flex",
flexDirection: "column", flexDirection: "row",
justifyContent: "flex-end",
}} }}
> >
<SidebarButton onClick={() => navigate("/")} name="Dashboard"> <div
<HomeIcon size={4} color="white" /> style={{
</SidebarButton> position: "relative",
<SidebarButton onClick={() => navigate("/Products")} name="Products"> display: "flex",
<ProductsIcon size={4} color="white" /> flexDirection: "column",
</SidebarButton> justifyContent: "flex-start",
<SidebarButton }}
onClick={() => navigate("/Inventory")}
name="Inventory"
> >
<InventoryIcon size={4} color="white" /> <SidebarButton onClick={() => navigate("/")} name="Dashboard">
</SidebarButton> <HomeIcon size={4} color="white" />
<SidebarButton onClick={() => navigate("/Logs")} name="Logs"> </SidebarButton>
<LogsIcon size={4} color="white" /> <SidebarButton
</SidebarButton> onClick={() => navigate("/Products")}
name="Products"
>
<ProductsIcon size={4} color="white" />
</SidebarButton>
<SidebarButton
onClick={() => navigate("/Inventory")}
name="Inventory"
>
<InventoryIcon size={4} color="white" />
</SidebarButton>
<SidebarButton onClick={() => navigate("/Logs")} name="Logs">
<LogsIcon size={4} color="white" />
</SidebarButton>
<Logout>
<LogoutIcon size={4} color="white" />
</Logout>
</div>
</div> </div>
<Logout>
<LogoutIcon size={4} color="white" />
</Logout>
</div> </div>
); );
} }

View file

@ -141,7 +141,6 @@ const styles: { [key: string]: React.CSSProperties } = {
paddingLeft: "2vh", paddingLeft: "2vh",
backgroundColor: "#3d4848", backgroundColor: "#3d4848",
}, },
sidebar_wrapper: {},
}; };
export default styles; export default styles;