Need help to translate "You can only select " + limit + " item"

(Nam Nguyen) #1

Hi, :slight_smile:

I need support to translate this phrase, I cannot find it in client.en.yml and server.en.yml files, or Text Content

formatSelectionTooBig: function (limit) { return "You can only select " + limit + " item" + (limit == 1 ? "" : "s"); },

discourse/select2.js at 5dbd6a304bed5400be481d71061d3e3ebb4d6785 路 discourse/discourse 路 GitHub

Thank you!

(Mittineague) #2

As you have probably noticed, that is in "vendor"
That is, it is code that Discourse is using but did not write.

For something to be easily translatable (i.e. without 鈥渉acking鈥) text strings need to be mapped to a token - value pair.

Unfortunately, it appears that the text string is hard-coded.