-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* fix: import errors * notification provider * feat: removed style prop for notification * fix: package issue * fix: package issue * fix: package issue * fix: package issue * package.json changes * feat: dashboard route * feat: authlayout * feat: sidebar * feat: authlayout width * feat: dashboard design * fix: route fix * feat: Binded all routes with DashboardLayout * feat: removed unwanted routes * feat: dashboardlayout changes * feat: dashboard * feat: removed dashboardlayout wroking as wrapper * feat: dashboard card title changes * feat: moved to dashboard layout to privatelayout * feat: auth * feat: sidebar resposive
- Loading branch information
Showing
10 changed files
with
24,605 additions
and
24,720 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { Outlet } from "react-router-dom"; | ||
|
||
import Sidebar from "./Sidebar"; | ||
|
||
const AuthLayout = () => { | ||
return ( | ||
<div className="flex w-screen bg-[#F9FAFB]"> | ||
<aside className="pl-2 py-2 w-60 h-screen"> | ||
<div className="pl-2 pt-10 rounded-2xl bg-white h-full"> | ||
<Sidebar /> | ||
</div> | ||
</aside> | ||
<div className="w-[calc(100vw_-_240px)] p-6 max-w-6xl mx-auto"> | ||
<Outlet /> | ||
</div> | ||
</div> | ||
); | ||
}; | ||
|
||
export default AuthLayout; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
import { Link, useLocation } from "react-router-dom"; | ||
import { | ||
ArrowLeftOnRectangleIcon, | ||
Cog6ToothIcon, | ||
FlagIcon, | ||
FolderIcon, | ||
HomeIcon, | ||
} from "@heroicons/react/24/outline"; | ||
|
||
const Sidebar = () => { | ||
const location = useLocation(); | ||
|
||
const routes = [ | ||
{ | ||
id: 1, | ||
link: "/dashboard", | ||
name: "Dashboard", | ||
icon: <HomeIcon className="h-5 w-5 font-extrabold" />, | ||
}, | ||
{ | ||
id: 2, | ||
link: "/flags", | ||
name: "Flags", | ||
icon: <FlagIcon className="h-5 w-5 font-extrabold" />, | ||
}, | ||
{ | ||
id: 3, | ||
link: "/segments", | ||
name: "Segments", | ||
icon: <FolderIcon className="h-5 w-5 font-extrabold" />, | ||
}, | ||
{ | ||
id: 4, | ||
link: "/settings/apikeys", | ||
name: "Settings", | ||
icon: <Cog6ToothIcon className="h-5 w-5 font-extrabold" />, | ||
}, | ||
]; | ||
|
||
return ( | ||
<div className="flex flex-col justify-between h-full"> | ||
<ul className="flex flex-col gap-8"> | ||
{routes.map((el) => ( | ||
<li key={el.id}> | ||
<Link | ||
to={el.link} | ||
className={`flex items-center text-base gap-4 pl-8 ${ | ||
el.link === location.pathname | ||
? "text-black font-bold" | ||
: "text-[#2563EB]" | ||
} hover:text-black`} | ||
> | ||
{el.icon} | ||
<span>{el.name}</span> | ||
</Link> | ||
</li> | ||
))} | ||
</ul> | ||
<div className="bg-[#2563EB] hover:bg-blue-700 text-white py-3 rounded-b-2xl"> | ||
<Link | ||
to="/" | ||
className="flex items-center text-base gap-4 pl-8 text-white hover:" | ||
> | ||
<ArrowLeftOnRectangleIcon className="h-5 w-5 font-extrabold" /> | ||
<span>Logout</span> | ||
</Link> | ||
</div> | ||
</div> | ||
); | ||
}; | ||
|
||
export default Sidebar; |
Oops, something went wrong.