Class: ButtonField

Picasso.form.field. ButtonField

new ButtonField()

Default buttons constructor
Source:

Extends

Members

<protected> _element :HTMLElement

The html of the field
Type:
  • HTMLElement
Inherited From:
Source:

<protected> _formIgnore :boolean

If this field is ignored in a form final value
Type:
  • boolean
Inherited From:
Source:

<protected> _id :string|number

The id of the field
Type:
  • string | number
Inherited From:
Source:

<protected> _label :string

The field label
Type:
  • string
Inherited From:
Source:

<protected> _required :boolean

The flag to mark this field as required
Type:
  • boolean
Inherited From:
Source:

<protected> _type :string

The type of this field
Type:
  • string
Inherited From:
Source:

<inner> htmlUtils :utils/html

Type:
  • utils/html
Source:

Methods

addClass(_class)

Add one or more classes (separated by space) to the field
Parameters:
Name Type Description
_class string
Inherited From:
Source:

build(field)

Builds the button field
Parameters:
Name Type Description
field Picasso.pjo.Field
Source:

getHTMLElement() → {HTMLElement}

Get the HTMLElement of this field
Inherited From:
Source:
Returns:
Type
HTMLElement

getId() → {string|number}

Get this field id
Inherited From:
Source:
Returns:
Type
string | number

getLabel() → {string}

Get the field label
Inherited From:
Source:
Returns:
Type
string

getType() → {string}

Get the field type
Inherited From:
Source:
Returns:
Type
string

isEmpty() → {boolean}

Verify if the button is empty
Source:
Returns:
Type
boolean

isFormIgnored() → {boolean}

Verify if the field is ignored in the form
Inherited From:
Source:
Returns:
Type
boolean

isRequired() → {boolean}

Verify if the field is required
Inherited From:
Source:
Returns:
Type
boolean

removeClass(_class)

Removes one or more classes (separated by space) to the field
Parameters:
Name Type Description
_class string
Inherited From:
Source:

<abstract> reset()

Resets the field
Inherited From:
Source:
Throws:

setHTMLElement(element)

Sets the HTMLElement of this field
Parameters:
Name Type Description
element HTMLElement
Inherited From:
Source:

setId(id)

Sets this field id, if not is given generates the id based on a sequence
Parameters:
Name Type Description
id string | number
Inherited From:
Source:

value() → {*}

Gets the value of the button
Source:
Returns:
Type
*