Skip to main content

ElementMenu

Namespace for constructing menu bars

Index

Functions

AppendButton

  • AppendButton(div: HTMLDivElement, menuitem: HTMLElement): void
  • Parameters

    • div: HTMLDivElement
    • menuitem: HTMLElement

    Returns void

Create

  • Create(id: string, menuItems: readonly (string | Node | HTMLOptions<keyof HTMLElementTagNameMap>)[], options?: { direction: ltr | rtl }, htmlOptions?: Partial<Record<menu, Omit<HTMLOptions<any>, tag>>>): HTMLDivElement
  • Parameters

    • id: string
    • menuItems: readonly (string | Node | HTMLOptions<keyof HTMLElementTagNameMap>)[]
    • optionaloptions: { direction: ltr | rtl } = null
      • direction: ltr | rtl
    • htmlOptions: Partial<Record<menu, Omit<HTMLOptions<any>, tag>>> = null

    Returns HTMLDivElement

PrependItem

  • PrependItem(div: HTMLDivElement, menuitem: HTMLElement): void
  • Parameters

    • div: HTMLDivElement
    • menuitem: HTMLElement

    Returns void

_KeyDown

  • _KeyDown(...this: any, ev: KeyboardEvent): Promise<void>
  • Parameters

    • rest...this: any
    • ev: KeyboardEvent

    Returns Promise<void>