Warning

Warning

Source:

Adds the class "aux-warn" on this.element for a certain period of time. It is used e.g. in ChartHandle or Knob when the value exceeds the range.

Methods

warning(element, timeoutopt)

Source:

Adds the class .aux-warn to the given element and sets a timeout after which the class is removed again. If there already is a timeout waiting it gets updated.

Parameters:
Name Type Attributes Default Description
element HTMLElement | SVGElement

The DOM node the class should be set on.

timeout Number <optional>
250

The timeout in milliseconds until the class should be removed again.

Fires:

Events

warning

Source:

Gets fired when Warning#warning was called.

Parameters:
Name Type Description
element HTMLElement | SVGElement

The element which received the warning class.

warning_released

Source:

Gets fired when the warning class was removed.

Parameters:
Name Type Description
element HTMLElement | SVGElement

The element which lost the warning class.