@carbon/react
Version:
React components for the Carbon Design System
41 lines (40 loc) • 1.4 kB
TypeScript
/**
* 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 PropTypes from 'prop-types';
import type { TranslateWithId } from '../../types/common';
declare const translationIds: {
readonly 'close.menu': "close.menu";
readonly 'open.menu': "open.menu";
};
type TranslationKey = keyof typeof translationIds;
export interface ListBoxMenuIconProps extends TranslateWithId<TranslationKey> {
/**
* Specify whether the menu is currently open, which will influence the
* direction of the menu icon
*/
isOpen: boolean;
}
export type ListBoxMenuIconComponent = typeof ListBoxMenuIcon;
/**
* `ListBoxMenuIcon` is used to orient the icon up or down depending on the
* state of the menu for a given `ListBox`
*/
declare const ListBoxMenuIcon: {
({ isOpen, translateWithId: t, }: ListBoxMenuIconProps): import("react/jsx-runtime").JSX.Element;
propTypes: {
/**
* Specify whether the menu is currently open, which will influence the
* direction of the menu icon
*/
isOpen: PropTypes.Validator<boolean>;
/**
* Translates component strings using your i18n tool.
*/
translateWithId: PropTypes.Requireable<(...args: any[]) => any>;
};
};
export default ListBoxMenuIcon;