UFTrackState can be used to track a property and update an element whenever the property changes.

Type Parameters

  • T extends Element

Hierarchy (View Summary)

Constructors

Methods

Constructors

  • Creates instance of UFTrackState

    Type Parameters

    • T extends Element

    Parameters

    • anElement: string | T

      DOM element to add the enabled/disabled css class to. If the anElement is a string, the method will find

    • aData: UFModel

      An instance extending UFModel

    • aPropertyName: string

      The property name to track.

    • aCallback: UFTrackStateCallback<T>

      A callback function that gets called whenever the property changes. It passes the element, the property value and the value of aData.

    Returns UFTrackState<T>

Methods