36 lines
831 B
TypeScript
36 lines
831 B
TypeScript
export type SidebarItem = {
|
|
title: string;
|
|
mobileTitle?: string;
|
|
icon: any;
|
|
path: string;
|
|
aliases?: string[];
|
|
perm?: string | string[];
|
|
[key: string]: any;
|
|
};
|
|
|
|
export type SidebarProps = {
|
|
items?: SidebarItem[];
|
|
currentPath?: string;
|
|
linkComponent?: any;
|
|
onNavigate?: (item: SidebarItem) => void;
|
|
logoutTitle?: string;
|
|
logoutIcon?: any;
|
|
primaryMobileCount?: number;
|
|
moreTitle?: string;
|
|
moreDrawerTitle?: string;
|
|
desktopProps?: Record<string, any>;
|
|
mobileProps?: Record<string, any>;
|
|
};
|
|
|
|
export function Sidebar(props: SidebarProps): any;
|
|
export function isSidebarPathActive(
|
|
currentPath: string | undefined,
|
|
item: SidebarItem,
|
|
): boolean;
|
|
export function getActiveSidebarItem(
|
|
items: SidebarItem[],
|
|
currentPath: string | undefined,
|
|
): SidebarItem | undefined;
|
|
|
|
export const Header: any;
|