/** * @license * Copyright 2022 Google LLC * SPDX-License-Identifier: Apache-2.0 */ import {customElement} from 'lit/decorators.js'; import {styles as forcedColors} from './internal/forced-colors-styles.css.js'; import {Menu} from './internal/menu.js'; import {styles} from './internal/menu-styles.css.js'; export {ListItem} from '../list/internal/listitem/list-item.js'; export {Corner, DefaultFocusState} from './internal/menu.js'; export {CloseMenuEvent, MenuItem} from './internal/shared.js'; declare global { interface HTMLElementTagNameMap { 'md-menu': MdMenu; } } /** * @summary Menus display a list of choices on a temporary surface. * * @description * Menus appear when users interact with a button, action, or other control. * * They can be opened from a variety of elements, most commonly icon buttons, * buttons, and text fields. * * md-menu listens for the `close-menu` and `deselect-items` events. * * - `close-menu` closes the menu when dispatched from a child element. * - `deselect-items` deselects all of its immediate menu-item children. * * @example * ```html *
* * * * * * * * * * *
* ``` * * @final * @suppress {visibility} */ @customElement('md-menu') export class MdMenu extends Menu { static override styles = [styles, forcedColors]; }