diff --git a/package.json b/package.json index 85d2c20..61f93bd 100644 --- a/package.json +++ b/package.json @@ -1,48 +1,48 @@ { - "name": "yellowbird", - "version": "0.1.0", - "private": true, - "scripts": { - "dev": "next dev", - "build": "next build", - "start": "next start", - "lint": "next lint" - }, - "dependencies": { - "@dnd-kit/core": "^6.1.0", - "@dnd-kit/sortable": "^8.0.0", - "@dnd-kit/utilities": "^3.2.2", - "@nivo/bar": "^0.85.1", - "@nivo/calendar": "^0.85.0", - "@nivo/line": "^0.84.0", - "@nivo/treemap": "^0.84.0", - "@radix-ui/react-dialog": "^1.0.5", - "@radix-ui/react-separator": "^1.0.3", - "@radix-ui/react-slot": "^1.0.2", - "@tanstack/react-table": "^8.13.2", - "class-variance-authority": "^0.7.0", - "clsx": "^2.1.0", - "cmdk": "^1.0.0", - "date-fns": "^3.3.1", - "lightweight-charts": "^4.1.3", - "lucide-react": "^0.338.0", - "next": "14.1.0", - "next-themes": "^0.2.1", - "react": "^18", - "react-dom": "^18", - "tailwind-merge": "^2.2.1", - "tailwindcss-animate": "^1.0.7" - }, - "devDependencies": { - "@types/node": "^20", - "@types/react": "^18", - "@types/react-dom": "^18", - "autoprefixer": "^10.0.1", - "eslint": "^8", - "eslint-config-next": "14.1.0", - "postcss": "^8", - "prettier-plugin-tailwindcss": "^0.5.14", - "tailwindcss": "^3.3.0", - "typescript": "^5" - } + "name": "yellowbird", + "version": "0.1.0", + "private": true, + "scripts": { + "dev": "next dev --turbo", + "build": "next build", + "start": "next start", + "lint": "next lint" + }, + "dependencies": { + "@dnd-kit/core": "^6.1.0", + "@dnd-kit/sortable": "^8.0.0", + "@dnd-kit/utilities": "^3.2.2", + "@nivo/bar": "^0.85.1", + "@nivo/calendar": "^0.85.0", + "@nivo/line": "^0.84.0", + "@nivo/treemap": "^0.84.0", + "@radix-ui/react-dialog": "^1.0.5", + "@radix-ui/react-separator": "^1.0.3", + "@radix-ui/react-slot": "^1.0.2", + "@tanstack/react-table": "^8.13.2", + "class-variance-authority": "^0.7.0", + "clsx": "^2.1.0", + "cmdk": "^1.0.0", + "date-fns": "^3.3.1", + "lightweight-charts": "^4.1.3", + "lucide-react": "^0.338.0", + "next": "14.1.0", + "next-themes": "^0.2.1", + "react": "^18", + "react-dom": "^18", + "tailwind-merge": "^2.2.1", + "tailwindcss-animate": "^1.0.7" + }, + "devDependencies": { + "@types/node": "^20", + "@types/react": "^18", + "@types/react-dom": "^18", + "autoprefixer": "^10.0.1", + "eslint": "^8", + "eslint-config-next": "14.1.0", + "postcss": "^8", + "prettier-plugin-tailwindcss": "^0.5.14", + "tailwindcss": "^3.3.0", + "typescript": "^5" + } } diff --git a/public/yellowbird-black.svg b/public/yellowbird-black.svg deleted file mode 100644 index 54dbf7c..0000000 --- a/public/yellowbird-black.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/public/yellowbird.svg b/public/yellowbird.svg deleted file mode 100644 index be8e2de..0000000 --- a/public/yellowbird.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/src/components/sidebar/Sidebar.tsx b/src/components/sidebar/Sidebar.tsx index 14fb974..2ef0cc0 100644 --- a/src/components/sidebar/Sidebar.tsx +++ b/src/components/sidebar/Sidebar.tsx @@ -31,27 +31,34 @@ import { CommandSeparator, CommandShortcut, } from "../ui/command"; +import { useRouter } from "next/navigation"; function Sidebar() { const [isCollapsed, setIsCollapsed] = useState(false); + const router = useRouter(); + + const handleClick = (redirectLink: any) => { + router.push(redirectLink); + }; + const menuList = [ { group: "Navigation", items: [ { - link: "/dashboard", - icon: , + link: "/", + icon: , text: "Dashboard", }, { link: "/calendar", - icon: , + icon: , text: "Calendar", }, { link: "/porfolio", - icon: , + icon: , text: "Portfolio", }, ], @@ -61,17 +68,17 @@ function Sidebar() { items: [ { link: "/", - icon: , + icon: , text: "Earnings", }, { link: "/", - icon: , + icon: , text: "Insider Trades", }, { link: "/", - icon: , + icon: , text: "Filings", }, ], @@ -81,20 +88,35 @@ function Sidebar() { return ( - - + + {isCollapsed ? ( + + ) : ( + + )} - + + {/* {menuList.map((menu: any, key: number) => ( @@ -112,7 +134,49 @@ function Sidebar() { ))} - + */} + + + + {menuList.map((menu: any, key: number) => ( + <> + + + {!isCollapsed && menu.group} + + {menu.items.map((option: any, optionKey: number) => ( + handleClick(option.link)} + > + + + {option.icon} + + {!isCollapsed && ( + {option.text} + )} + + + ))} + + + > + ))} + + + {