Module: alfresco/misc/AlfTooltip

alfresco/misc/AlfTooltip

This widget provides a way in which a widget model can be displayed when the mouse moves over another
widget. To use this tooltip you need to define a
widgets model to immediately render and then another
widget model that will be displayed in the
tooltip when the mouse moves over any of the widgets in the first model.

Type:

_tooltip :object

Type:

anchorSelector :string

This is an optional CSS selector that can be provided to identify a child node that the tooltip
should be anchored to. Ideally this should only match a single node, but if it matches multiple
nodes then the first result will be used. This selector is only used within the DOM that descends
from this widget - not across the entire page.

PLEASE NOTE: Use of this attribute is potentially fragile depending
upon the selector used - there are no guarantees that the CSS classes or HTML structure of widgets
will not change between releases of Aikau! It is strongly recommended that if future proof selectors
are required that feature requests are made to add them.

triggeringEvent :string

Type:

widgets :array

This is the widget model that will be immediately rendered. When the mouse is moved over any
of the widgets in this model then the tooltip will be created (if it hasn't previously been created)
and will then be displayed.

onTooltipMouseEnter()

onTooltipMouseLeave()

postCreate()

Sets up the mouse over listener for displaying the tooltip (if
[widgetsForTooltip]{@link module:alfresco/misc/AlfTooltipDialog#widgetsForTooltip} contains a widget
model) and then processes [widgets]{@link module:alfresco/misc/AlfTooltipDialog#widgets}.

resize(dimensions)

The tooltip needs to take responsibility for delegating any resize requests that its child widgets
would usually get if they were not contained within the tooltip. This is particularly important
when widgets are placed in a grid that will request
to resize those widgets. Without this delegation the widgets intended to be resized will stay their
original size. If the widget does not have a resize function then its DOM node will be resized.
If the widget has mixed in the ResizeMixin then its
alfPublishResizeEvent will be called.