'use client';
import type { MenuNode } from '@/lib/api/types/menu';
function MenuNodes({ nodes, depth }: { nodes: MenuNode[]; depth: number }) {
return (
{nodes.map((n) => (
-
{n.menu_name}
{n.path ? (
{n.path}
) : null}
{n.perms ? (
[{n.perms}]
) : null}
{n.children?.length ? : null}
))}
);
}
export function MenuTreeView(props: { tree: MenuNode[] }) {
if (!props.tree.length) {
return 暂无数据
;
}
return ;
}