Context Menus
Context Menus are active when the user right clicks on an component that has a Context Menu attached to that component.
A basic Context Menu.
Right click anywhere in this panel. On mobile, click and hold.
const demoMenuChoiceOptions: MenuChoiceOption[] = [
{
title: "Home",
href: "/",
},
...
{
title: "Submenus",
href: "/",
subMenu: [
{ title: "Sub 1", href: "/" },
{
title: "Sub 2",
href: "/",
subMenu: [
{ title: "Sub-Sub 1", href: "/" },
{ title: "Sub-Sub 2", href: "/" },
{ title: "Sub-Sub 3", href: "/" },
],
},
{ title: "Sub 3", href: "/" },
],
},
...
];

...

const menuList = (
<MenuList
menuListSettings={menuListSettings}
menuChoiceOptions={demoMenuChoiceOptions}
isLoggedIn={session !== null}
/>
);

...

<ContextMenu menuChildren={menuList}>
<Panel>
Right click anywhere in this panel. On mobile, click and hold.
</Panel>
</ContextMenu>

FUTORO