From c1fe94a630a88c4f7203d54f34985c109030791c Mon Sep 17 00:00:00 2001 From: Daniel Weipert Date: Sat, 19 Aug 2023 15:32:48 +0200 Subject: translations --- resources/js/helpers.js | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'resources/js/helpers.js') diff --git a/resources/js/helpers.js b/resources/js/helpers.js index 1622eb2..53a5c87 100644 --- a/resources/js/helpers.js +++ b/resources/js/helpers.js @@ -50,3 +50,10 @@ function mixColors(...colors) { function randomString () { return (Math.random() + 1).toString(36).substring(2); } + +/** + * @param {string} msgid + */ +function translate (msgid) { + return DB.translations[Memory.state.language][msgid]; +} -- cgit v1.2.3