Module: SimpleForm::Components::Labels::ClassMethods
- Defined in:
- lib/simple_form/components/labels.rb
Overview
:nodoc:
Instance Method Summary collapse
- #translate_required_html ⇒ Object
- #translate_required_mark ⇒ Object
- #translate_required_text ⇒ Object
Instance Method Details
#translate_required_html ⇒ Object
9 10 11 12 13 14 15 |
# File 'lib/simple_form/components/labels.rb', line 9 def translate_required_html i18n_cache :translate_required_html do I18n.t(:"simple_form.required.html", :default => %[<abbr title="#{translate_required_text}">#{translate_required_mark}</abbr>] ) end end |
#translate_required_mark ⇒ Object
21 22 23 |
# File 'lib/simple_form/components/labels.rb', line 21 def translate_required_mark I18n.t(:"simple_form.required.mark", :default => '*') end |
#translate_required_text ⇒ Object
17 18 19 |
# File 'lib/simple_form/components/labels.rb', line 17 def translate_required_text I18n.t(:"simple_form.required.text", :default => 'required') end |