The rich text editor previously had no knowledge of the current localisation region. The complexity arrived from the $locale regions not having a direct mapping to TinyMce regions. $locale regions are in the format of "de-de", "ru-ru", "en-gb", "en-us", etc. The TinyMce locales are in the format of "de", "ru" and "en". I've added some code in rte.controller.js to map from the former to the latter, but a fallback to "en" will need to be added if the current locale isn't supported by TinyMce, otherwise a runtime crash will occur. The same is true of the codemirror plugin for TinyMce. Language files don't exist for the plugin, but they are expected when different locales are provided. I have therefore created placeholders that are equivalent to the TinyMce language files, but all are currently copied from english.
9 lines
216 B
JavaScript
9 lines
216 B
JavaScript
tinymce.addI18n('en',{
|
|
'HTML source code': 'HTML source code',
|
|
'Start search': 'Start search',
|
|
'Find next': 'Find next',
|
|
'Find previous': 'Find previous',
|
|
'Replace': 'Replace',
|
|
'Replace all': 'Replace all'
|
|
});
|