Popup | context-menu

### Hierarchy

- AbstractPostable
  - Popup

### Implements

- KeyNavigatable
- MouseNavigatable
- Element
- Postable

## Index

### Constructors

- constructor

### Properties

- active
- className
- content
- menu
- mobileFlag
- role
- title
- window
- windowList

### Methods

- addAttributes
- addEvents
- attachMenu
- bubbleKey
- click
- display
- down
- escape
- focus
- generateContent
- generateHtml
- getHtml
- isPosted
- keydown
- left
- mousedown
- mouseout
- mouseover
- mouseup
- post
- resize
- right
- setHtml
- space
- stop
- unfocus
- unpost
- up

### Object literals

- popupSettings

## Constructors

### constructor

- new Popup(title: string, content: Function): Popup

- - Defined in popup.ts:64
  constructor
  extends

    {AbstractPostable}

  #### Parameters

  - ##### title: string

    The title of the popup window.

  - ##### content: Function

    Function generating the content.

  #### Returns Popup

## Properties

### Private active

active: HTMLElement = null

- Defined in popup.ts:64

### Protected className

className: HtmlClass

Inherited from MenuElement.className

- Defined in menu_element.ts:42

override

### Private content

content: Function

- Defined in popup.ts:49

### Private menu

menu: ContextMenu

- Defined in popup.ts:47

### Private mobileFlag

mobileFlag: boolean = false

- Defined in popup.ts:63

### Protected role

role: string

Inherited from MenuElement.role

- Defined in menu_element.ts:37

override

### Private title

title: string = ""

- Defined in popup.ts:48

### Private window

window: Window = null

- Defined in popup.ts:55

The last opened window.

type

  {Window}

### Private windowList

windowList: Window[] = []

- Defined in popup.ts:61

The list of all windows opened by this object.

type

  {Array.}

## Methods

### addAttributes

- addAttributes(attributes: object): void

- Inherited from MenuElement.addAttributes

  - Defined in menu_element.ts:50

  Adds a attributes and values to the HTML element.

  #### Parameters

  - ##### attributes: object

    A dictionary of attributes.

    - ##### [attr: string]: string

  #### Returns void

### addEvents

- addEvents(element: HTMLElement): void

- Inherited from AbstractNavigatable.addEvents

  - Defined in abstract_navigatable.ts:153

  Adds navigation events to an HTML element.

  #### Parameters

  - ##### element: HTMLElement

    The HTML element for navigation.

  #### Returns void

### attachMenu

- attachMenu(menu: ContextMenu): void

- - Defined in popup.ts:82

  Attaches the widget to a context menu.

  #### Parameters

  - ##### menu: ContextMenu

    The parent menu.

  #### Returns void

### bubbleKey

- bubbleKey(): void

- Inherited from AbstractNavigatable.bubbleKey

  - Defined in abstract_navigatable.ts:38

  Bubble this key event.

  #### Returns void

### click

- click(event: MouseEvent): void

- Implementation of MouseNavigatable.click

  Inherited from AbstractNavigatable.click

  - Defined in abstract_navigatable.ts:145
  override

  #### Parameters

  - ##### event: MouseEvent

  #### Returns void

### Protected display

- display(): void

- Overwrites AbstractPostable.display

  - Defined in popup.ts:96
  override

  #### Returns void

### down

- down(event: KeyboardEvent): void

- Implementation of KeyNavigatable.down

  Inherited from AbstractNavigatable.down

  - Defined in abstract_navigatable.ts:100
  override

  #### Parameters

  - ##### event: KeyboardEvent

  #### Returns void

### escape

- escape(event: KeyboardEvent): void

- Implementation of KeyNavigatable.escape

  Inherited from AbstractNavigatable.escape

  - Defined in abstract_navigatable.ts:75
  override

  #### Parameters

  - ##### event: KeyboardEvent

  #### Returns void

### focus

- focus(): void

- Inherited from MenuElement.focus

  - Defined in menu_element.ts:88
  override

  #### Returns void

### Private generateContent

- generateContent(): string

- - Defined in popup.ts:141

  Generates the content of the window.

  #### Returns string

  The generated content.

### generateHtml

- generateHtml(): void

- Implementation of Element.generateHtml

  Inherited from MenuElement.generateHtml

  - Defined in menu_element.ts:77
  override

  #### Returns void

### getHtml

- getHtml(): HTMLElement

- Implementation of Element.getHtml

  Inherited from MenuElement.getHtml

  - Defined in menu_element.ts:59
  override

  #### Returns HTMLElement

### isPosted

- isPosted(): boolean

- Implementation of Postable.isPosted

  Inherited from AbstractPostable.isPosted

  - Defined in abstract_postable.ts:41
  override

  #### Returns boolean

### keydown

- keydown(event: KeyboardEvent): void

- Implementation of KeyNavigatable.keydown

  Inherited from AbstractNavigatable.keydown

  - Defined in abstract_navigatable.ts:45
  override

  #### Parameters

  - ##### event: KeyboardEvent

  #### Returns void

### left

- left(event: KeyboardEvent): void

- Implementation of KeyNavigatable.left

  Inherited from AbstractNavigatable.left

  - Defined in abstract_navigatable.ts:85
  override

  #### Parameters

  - ##### event: KeyboardEvent

  #### Returns void

### mousedown

- mousedown(event: MouseEvent): void

- Implementation of MouseNavigatable.mousedown

  Inherited from AbstractNavigatable.mousedown

  - Defined in abstract_navigatable.ts:117
  override

  #### Parameters

  - ##### event: MouseEvent

  #### Returns void

### mouseout

- mouseout(event: MouseEvent): void

- Implementation of MouseNavigatable.mouseout

  Inherited from AbstractNavigatable.mouseout

  - Defined in abstract_navigatable.ts:138
  override

  #### Parameters

  - ##### event: MouseEvent

  #### Returns void

### mouseover

- mouseover(event: MouseEvent): void

- Implementation of MouseNavigatable.mouseover

  Inherited from AbstractNavigatable.mouseover

  - Defined in abstract_navigatable.ts:131
  override

  #### Parameters

  - ##### event: MouseEvent

  #### Returns void

### mouseup

- mouseup(event: MouseEvent): void

- Implementation of MouseNavigatable.mouseup

  Inherited from AbstractNavigatable.mouseup

  - Defined in abstract_navigatable.ts:124
  override

  #### Parameters

  - ##### event: MouseEvent

  #### Returns void

### post

- post(): void

- Implementation of Postable.post

  Overwrites AbstractPostable.post

  - Defined in popup.ts:89
  override

  #### Returns void

### Private resize

- resize(): void

- - Defined in popup.ts:149

  Resizes the window so it fits snuggly around the content.

  #### Returns void

### right

- right(event: KeyboardEvent): void

- Implementation of KeyNavigatable.right

  Inherited from AbstractNavigatable.right

  - Defined in abstract_navigatable.ts:90
  override

  #### Parameters

  - ##### event: KeyboardEvent

  #### Returns void

### setHtml

- setHtml(html: HTMLElement): void

- Implementation of Element.setHtml

  Inherited from MenuElement.setHtml

  - Defined in menu_element.ts:69
  override

  #### Parameters

  - ##### html: HTMLElement

  #### Returns void

### space

- space(event: KeyboardEvent): void

- Implementation of KeyNavigatable.space

  Inherited from AbstractNavigatable.space

  - Defined in abstract_navigatable.ts:80
  override

  #### Parameters

  - ##### event: KeyboardEvent

  #### Returns void

### Protected stop

- stop(event: Event): void

- Inherited from AbstractNavigatable.stop

  - Defined in abstract_navigatable.ts:106

  Stops event propagation and bubbling.

  #### Parameters

  - ##### event: Event

    The keyboard event that fired.

  #### Returns void

### unfocus

- unfocus(): void

- Inherited from MenuElement.unfocus

  - Defined in menu_element.ts:97
  override

  #### Returns void

### unpost

- unpost(): void

- Implementation of Postable.unpost

  Overwrites AbstractPostable.unpost

  - Defined in popup.ts:132
  override

  #### Returns void

### up

- up(event: KeyboardEvent): void

- Implementation of KeyNavigatable.up

  Inherited from AbstractNavigatable.up

  - Defined in abstract_navigatable.ts:95
  override

  #### Parameters

  - ##### event: KeyboardEvent

  #### Returns void

## Object literals

### Static Private popupSettings

popupSettings: object

- Defined in popup.ts:33

### directories

directories: string = "no"

- Defined in popup.ts:38

### height

height: number = 300

- Defined in popup.ts:43

### left

left: number = Math.round((screen.width - 400) / 2)

- Defined in popup.ts:44

### locationbar

locationbar: string = "no"

- Defined in popup.ts:36

### menubar

menubar: string = "no"

- Defined in popup.ts:37

### personalbar

personalbar: string = "no"

- Defined in popup.ts:39

### resizable

resizable: string = "yes"

- Defined in popup.ts:40

### scrollbars

scrollbars: string = "yes"

- Defined in popup.ts:41

### status

status: string = "no"

- Defined in popup.ts:34

### toolbar

toolbar: string = "no"

- Defined in popup.ts:35

### top

top: number = Math.round((screen.height - 300) / 3)

- Defined in popup.ts:45

### width

width: number = 400

- Defined in popup.ts:42

Generated using TypeDoc