You'll have to enter these name to retrieve the according translation. Make sure you choose simple names otherwise you'll have to keep an eye every time on your transaltion file.
Inside these names, you will have to enter the translation according to a key:value system.
Where key is your language and value is the translation.
I think it's all for this part :)
Now, let's go to the construct part !
The first you have to do, is to load the translation file you've just made.
For this, there are two ways.
Retrieving the file - Local
Put the file inside your project files and make an AJAX request (it's a native plugin) to retrieve it's data
Then load the retrieved value with the Load action of the transalte plugin.
Just put AJAX.LastData inside the field.
Retrieving the file - Distant
Imagine you don't want to translate the file yourself.
Put the file on a communautary website like github and instead of making an ajax request to a project file, make it to the raw url to the transaltion file.
You now just have to let people do the work on you public repository, validate the changes and the project is translated. No need to update the project.
CAUTION : If your project can also run offline make sure to have a copy of the file inside the project, otherwise, there probably be a problem when your user have no connection, haha ...
Make an update function that you can call directly on the begining of the layout and also when the user change the language.
Set the text of each of your object to
Note that this function take two parameters.
The first parameter is the string you defined in your JSON file.
The second parameters is to pass parameter to the string.
In my JSON file, I have defined that a field will take parameters :
The parameter are between "$"
To replace these parameters, fill the second parameter of the plugion action like this :
I think now you are ready ! If you have any questions fell free to ask onthe forum or on the c2 discord server
Based on a TheRealDannyyy idea.