General usability

This commit is contained in:
2015-03-05 12:24:45 +01:00
parent 3cf8d3c896
commit d061814989
30 changed files with 125 additions and 74 deletions
@@ -3,5 +3,5 @@ Ember.Handlebars.helper 't', (path, params..., options)->
if params.length and typeof(params[0].serialize) is 'function'
$.extend toptions, params[0].serialize()
text = t(path, options.hash)
tag = if options.hash.bare then text else "<span data-t='#{path}' data-t-attributes='#{JSON.stringify(options.hash)}'>#{text}</span>"
tag = if options.hash.bare then text else "<span data-t='#{path}' class='translation' data-t-attributes='#{JSON.stringify(options.hash)}'>#{text}</span>"
tag.htmlSafe()