mirror of
https://github.com/utopia-os/utopia-ui.git
synced 2025-12-13 07:46:10 +00:00
optional open links in new tab
This commit is contained in:
parent
690a069dbd
commit
e049152347
@ -14,6 +14,7 @@ type route = {
|
||||
icon: JSX.Element;
|
||||
name: string;
|
||||
submenu?: route;
|
||||
blank?: boolean
|
||||
}
|
||||
|
||||
|
||||
@ -102,6 +103,7 @@ export function SideBar({ routes, bottomRoutes }: { routes: route[], bottomRoute
|
||||
<SidebarSubmenu {...route} /> :
|
||||
(<NavLink
|
||||
end
|
||||
target={route.blank ? "_blank" : "_self"}
|
||||
to={route.path}
|
||||
className={({ isActive }) => `${isActive ? 'tw-font-semibold tw-bg-base-200 !tw-rounded-none' : 'tw-font-normal !tw-rounded-none'}`} onClick={() => {
|
||||
if (screen.width < 640 && !slim) instance.toggle();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user