Files
contact-front/src/config/menu.types.ts

25 lines
569 B
TypeScript

import type { LucideIcon } from "lucide-react";
export type TopMenuItem = {
id: string;
label: string;
path: string;
/** 현재 경로가 이 탭에 해당하는지 판별하는 함수 */
match?: (pathname: string) => boolean;
};
export type SideSubMenuItem = {
id: string;
label: string;
path: string;
};
export type SideMenuItem = {
id: string;
label: string;
icon: LucideIcon;
/** 단일 메뉴일 경우 path 사용 */
path?: string;
/** children이 있으면 2단 메뉴(접었다 펴는 타입) */
children?: SideSubMenuItem[];
};