Module: Lit::LocalizationsHelper
- Defined in:
- app/helpers/lit/localizations_helper.rb
Instance Method Summary collapse
Instance Method Details
#allow_wysiwyg_editor?(key) ⇒ Boolean
11 12 13 |
# File 'app/helpers/lit/localizations_helper.rb', line 11 def allow_wysiwyg_editor?(key) Lit.all_translations_are_html_safe || key.to_s =~ /(\b|_|\.)html$/ end |
#draw_icon(icon, opts = {}) ⇒ Object
3 4 5 |
# File 'app/helpers/lit/localizations_helper.rb', line 3 def draw_icon(icon, opts={}) raw("<i class=\"fa fa-#{icon} #{opts[:class]}\" title=\"#{opts[:title]}\" ></i>") end |
#ejs(val) ⇒ Object
7 8 9 |
# File 'app/helpers/lit/localizations_helper.rb', line 7 def ejs(val) escape_javascript val.to_s end |