UNPKG

@carbon/react

Version:

React components for the Carbon Design System

61 lines (60 loc) 1.66 kB
/** * Copyright IBM Corp. 2016, 2025 * * This source code is licensed under the Apache-2.0 license found in the * LICENSE file in the root directory of this source tree. */ import React from 'react'; export interface OverflowMenuItemProps extends React.HTMLAttributes<HTMLElement> { /** * The CSS class name to be placed on the button element */ className?: string; /** * A callback to tell the parent menu component that the menu should be closed. */ closeMenu?: () => void; /** * `true` to make this menu item disabled. */ disabled?: boolean; handleOverflowMenuItemFocus?: (options: { currentIndex?: number; direction: number; }) => void; /** * `true` to make this menu item a divider. */ hasDivider?: boolean; /** * If given, overflow item will render as a link with the given href */ href?: string; index?: number; /** * The text to show for the menu item */ itemText?: React.ReactNode; /** * `true` to make this menu item a danger button. */ isDelete?: boolean; /** * accepts a ref to the button element */ ref?: (element: HTMLElement) => void; /** * `true` to require the title attribute. */ requireTitle?: boolean; /** * The title attribute. */ title?: string; /** * The CSS class name to be placed on the wrapper element */ wrapperClassName?: string; } declare const OverflowMenuItem: React.ForwardRefExoticComponent<Omit<OverflowMenuItemProps, "ref"> & React.RefAttributes<HTMLElement>>; export default OverflowMenuItem;