Menu
A short list of actions that opens from a button.
Add it to your project
Or install the packages yourselfTerminal
npm install @mui/material
First time with Material UI? Set it up once.
The code
'use client';
import * as React from 'react';
import Button from '@mui/material/Button';
import Menu from '@mui/material/Menu';
import MenuItem from '@mui/material/MenuItem';
export default function BasicMenu() {
const id = React.useId();
const buttonId = `${id}-button`;
const menuId = `${id}-menu`;
const [anchorEl, setAnchorEl] = React.useState<null | HTMLElement>(null);
const open = Boolean(anchorEl);This comes with paid plans
The code for every component comes with paid plans, along with the rest of the AI toolkit. The first component under each heading is free.