Sha256: 5d83c9bb461029c1fa8f3e5b716aa2a04c717139ca63293d68acd18219df7f3b

Contents?: true

Size: 322 Bytes

Versions: 12

Compression:

Stored size: 322 Bytes

Contents

#= require i18n_screwdriver/md5

interpolate = (message, data) ->
  message.replace(/%{([^{}]*)}/g, (a, b) -> data[b])

I18n.screw = (message, data) ->
  md5 = window.md5(message)
  translation = I18n.translations[I18n.locale][md5]
  translation ?= I18n.onMissingTranslation(md5, message)
  interpolate(translation, data)

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
i18n_screwdriver-10.4.0 app/assets/javascrips/i18n_screwdriver/screw.coffee
i18n_screwdriver-10.3.0 app/assets/javascrips/i18n_screwdriver/screw.coffee
i18n_screwdriver-10.2.1 app/assets/javascrips/i18n_screwdriver/screw.coffee
i18n_screwdriver-10.2.0 app/assets/javascrips/i18n_screwdriver/screw.coffee
i18n_screwdriver-10.1.0 app/assets/javascrips/i18n_screwdriver/screw.coffee
i18n_screwdriver-10.0.1 app/assets/javascrips/i18n_screwdriver/screw.coffee
i18n_screwdriver-10.0.0 app/assets/javascrips/i18n_screwdriver/screw.coffee
i18n_screwdriver-9.7 app/assets/javascrips/i18n_screwdriver/screw.coffee
i18n_screwdriver-9.6 app/assets/javascrips/i18n_screwdriver/screw.coffee
i18n_screwdriver-9.5 app/assets/javascrips/i18n_screwdriver/screw.coffee
i18n_screwdriver-9.4 app/assets/javascrips/i18n_screwdriver/screw.coffee
i18n_screwdriver-9.3 app/assets/javascrips/i18n_screwdriver/screw.coffee