Popups

Popups present context information on demand at a specific place.

Let's look at an example of a popup. Active the popup by using a context (right) click. Note that the position of the open command must be in the coordinates of the parent node.


oncontextmenu="Popup.open(content, 
    {x: event.offsetX, y: event.offsetY}, 
    {parent: example,
    keepWithin: example}); return false;"

Sometimes popups are used within scaled, rotated, and translated DOM containers. Left click into the following scaled (0.5) and rotated container.

Another complication results from links that are too long to fit within one line and which break if the page gets smaller. This can be solved by using the Popup.targetCenter(event) as provider for the popup position.