Class: Forma::EmailField
- Inherits:
-
TextField
- Object
- Field
- SimpleField
- TextField
- Forma::EmailField
- Defined in:
- lib/forma/field.rb
Overview
Email field.
Instance Attribute Summary
Attributes inherited from TextField
Attributes inherited from Field
#actions, #after, #autofocus, #before, #child_model_name, #height, #hint, #i18n, #icon, #inline_hint, #label, #model, #model_name, #name, #parent, #readonly, #required, #tag, #turbolink, #url, #value, #width
Instance Method Summary collapse
Methods inherited from TextField
Methods inherited from SimpleField
#errors, #has_errors?, #initialize, #value
Methods inherited from Field
#action, #id, #initialize, #localization_key, #localized_hint, #localized_label, #name_as_chain, #parameter_name, #to_html
Methods included from Html
Methods included from Utils
extract_value, number_format, #simple_value, singular_name
Constructor Details
This class inherits a constructor from Forma::TextField
Instance Method Details
#view_element(val) ⇒ Object
324 325 326 |
# File 'lib/forma/field.rb', line 324 def view_element(val) el('a', attrs: { href: "mailto:#{val}" }, text: val) end |