APIs

Show:

Widget to display live editor of label / input Will fire LIVE_INPUT_CHANGED on data changed and also will fire a custom event if one was give via options.customEvent Powered by the awesome validator: https://github.com/chriso/validator.js

Constructor

LiveInput

() Object

Returns:

Object:

instantiated LiveInput

Methods

_extendValidator

() Boolean

Adding our own validation rules

Returns:

Boolean:

pass or fail

_listenUp

()

Listen to up button increasing meters

_listenUp

(
  • i_value
  • i_announce
  • i_ignoreValidation
)

Set value and announce the change only announce if set to true

Parameters:

  • i_value String
  • i_announce Boolean
  • i_ignoreValidation Boolean

_validated

(
  • i_value
)
Array

Validate against all the given rules per instance

Parameters:

  • i_value Number

Returns:

Array:

status of array of error messages

getValidator

() Object

Return the validator object so caller can reference the isXXX functions as validation rules

Returns:

Object:

validator object

getValue

() String

Get current input value

Returns:

String:

value

initialize

()

Constructor

rules

(
  • the
)

Enable validation via config object

Parameters:

  • the Object

    config objects uses a AND rule and so ALL rules must match for no error message to display. if any error we return it in the array of errors.