diff --git a/src/App.tsx b/src/App.tsx
index 788ab9d..3c7b0a7 100644
--- a/src/App.tsx
+++ b/src/App.tsx
@@ -2,7 +2,6 @@ import React from "react";
import Dashboard from "./Routes/Dashboard/Dashboard";
import Error from "./Routes/Error/Error";
import Products from "./Routes/Products/Products";
-import Header from "./Components/Header/Header";
import Container from "./Components/Container/Container";
import { createBrowserRouter, RouterProvider } from "react-router-dom";
import Store from "./Plugins/Redux/Store/Store";
@@ -11,12 +10,30 @@ import { Provider } from "react-redux";
const router = createBrowserRouter([
{
path: "/",
- element: ,
- errorElement: ,
+ element: (
+
+
+
+
+
+ ),
+ errorElement: (
+
+
+
+
+
+ ),
},
{
path: "/Products",
- element: ,
+ element: (
+
+
+
+
+
+ ),
},
]);
@@ -24,10 +41,7 @@ export default function App() {
return (
-
-
-
-
+
);
diff --git a/src/components/Container/Container.tsx b/src/components/Container/Container.tsx
index 0d2e182..89d6a63 100644
--- a/src/components/Container/Container.tsx
+++ b/src/components/Container/Container.tsx
@@ -1,5 +1,6 @@
import React from "react";
import Sidebar from "../Sidebar/Sidebar";
+import Header from "../Header/Header";
import styles from "../../styles";
export interface props {
@@ -9,12 +10,11 @@ export interface props {
export default function Container(props: props) {
return (
-
-
-
-
-
{props.children}
+
+
+
+
{props.children}
);
}
diff --git a/src/components/Sidebar/Sidebar.tsx b/src/components/Sidebar/Sidebar.tsx
index 767590c..38f1266 100644
--- a/src/components/Sidebar/Sidebar.tsx
+++ b/src/components/Sidebar/Sidebar.tsx
@@ -1,6 +1,8 @@
import React from "react";
import styles from "../../styles";
import SidebarButton from "../SidebarButton/SidebarButton";
+import { redirect } from "react-router-dom";
+import { useNavigate } from "react-router-dom";
export interface state {
minimized: {
value: boolean;
@@ -9,12 +11,13 @@ export interface state {
};
}
export default function Sidebar() {
+ const navigate = useNavigate();
return (
- console.log("WIP!")} name="Dashboard" />
- console.log("WIP!")} name="Products" />
- console.log("WIP!")} name="Inventory" />
- console.log("WIP!")} name="Logs" />
+ navigate("/")} name="Dashboard" />
+ navigate("/Products")} name="Products" />
+ navigate("/Inventory")} name="Inventory" />
+ navigate("/Logs")} name="Logs" />
);
}