Get translated labels for a javascript custom action
Posted: Fri Nov 10, 2023 4:08 pm
Hello,
I created a new action with javascript and I would like to use translated labels for my description.
How can I get, with javascript, the translation (stored in translation.xml) of my description.
In an action created by the UI I can use ${i18n(my.custom.action_description)}
Thanks.
Regards,
Nicolas
I created a new action with javascript and I would like to use translated labels for my description.
Code: Select all
//description
MyCustomAction.prototype.getDescription = function () {
return 'My custom action description'; //not translated for the moment
};
In an action created by the UI I can use ${i18n(my.custom.action_description)}
Thanks.
Regards,
Nicolas