Class Input

Define a Input block to be displayed into a JBlocks.

Class Summary
Constructor Attributes Constructor Name and Description
 
Input()

An Input block displays an HTML input field.

Method Summary

Class Detail

Input()

An Input block displays an HTML input field.

The constructor should not be invoked directly but JBlocks#newBlock or JBlocks#addNewBlock should be used instead.

Method Detail

  • init(layout, options)
    Initializes an Input block. The method is invoked by the jBlocks core and must never be called directly.
    Parameters:
    {Object} layout Optional
    see Block#init.
    {Object} options Optional
    in addition to base class options Block#init:
    {Function} options.onCR Optional
    a function to be called when carriage return is pressed inside the input field.
    {Function} options.onKeyDown Optional
    a function(keyCode) to be called when a key is pressed.
    {Function} options.text Optional, Default: ""
    the initial text value to display in the input field.