Good day sirs,
I'm having problems trying to localize the DocumentEditor component using plain JavaScript.
I have loaded in the test page ej2.min.js and material.css.
In order to create the editor and its container I use the following code inside a function (a class really):
this._wordDocEditorContainer = new ej.documenteditor.DocumentEditorContainer();
this._wordDocEditorContainer.appendTo('#wordEditor');
ej.documenteditor.DocumentEditorContainer.Inject(ej.documenteditor.Toolbar);
Then, I open a test document:
this._wordDocEditorContainer.documentEditor.open(JSON.stringify(this._getTestDoc()));
This works ok, so I'm doing things right, up to here at least.
The problem is that I cannot find an example of how to set up localization for these components. I tried setting the .locale property of both DocumentEditor, and DocumentEditorContainer to "es" (for spanish) but not only the UI texts don't change, also the context menu wrecks and all sorts of js errors appear in the browser's console.
What is the correct way to localize these components?
Thank you in advance
Alex