chipairon / i18nline-rails

Translation management engine for Rails applications.
MIT License
0 stars 0 forks source link

Do not change client/browser UI behaviour if the current user is not a translator #22

Closed chipairon closed 10 years ago

chipairon commented 10 years ago

The JS code is looking for translation spans and overriding the left mouse click event to open the translation popup.

Translations are appearing green or red to everyone. They should only appear that way to translators.

In the #ti method, we should add the translation missing class and the span wrapper if the current user can translate. Otherwise, just show the text (translated or nor), but don't add the span. This way, the JS code will not hook up because the selector will not be there.