@papernote/ui
Version:
A modern React component library with a paper notebook aesthetic - minimal, professional, and expressive
24 lines • 696 B
TypeScript
import { ReactNode } from 'react';
export interface MenuItem {
id: string;
label: string;
icon?: ReactNode;
onClick?: () => void;
disabled?: boolean;
danger?: boolean;
divider?: boolean;
submenu?: MenuItem[];
}
export interface MenuProps {
items: MenuItem[];
className?: string;
onClose?: () => void;
position?: {
x: number;
y: number;
};
anchor?: 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right';
}
export default function Menu({ items, className, onClose, position, anchor, }: MenuProps): import("react/jsx-runtime").JSX.Element;
export declare function MenuDivider(): MenuItem;
//# sourceMappingURL=Menu.d.ts.map