ckeditor - 在 CKEditor 中更改插件标题的语言
问题描述
我想根据语言更改标题“表情符号列表”的值。说法语,它来自 fr.js
如何修改语言值
CKEDITOR.lang['fr']['emoji']['title'] = 'abcd';
我正在这样做,
CKEDITOR.on('instanceLoaded', function(evt) {
CKEDITOR.lang['fr']['emoji']['title'] = 'abcd';
});
解决方案
From what I have checked the Emoji plugin only has the English translation: https://github.com/ckeditor/ckeditor-dev/tree/major/plugins/emoji/lang.
If you want to add French language manually to that plugin, here is how:
- Download CKEditor repo from Github - https://github.com/ckeditor/ckeditor-dev
- Go to https://github.com/ckeditor/ckeditor-dev/tree/major/plugins/emoji/lang and copy-paste
en.js
file - Rename it to
fr.js
- Open
fr.js
, change the language code inCKEDITOR.plugins.setLang( 'emoji', 'en', {
tofr
and change all the translations ofkey:translation
pairs from English to French (please remember to leave the keys untouched). - Go to https://github.com/ckeditor/ckeditor-dev/blob/major/plugins/emoji/plugin.js#L548 and change
lang: 'en',
tolang: 'en,fr',
. - Once this is done, you can build your own editor instance - https://ckeditor.com/docs/ckeditor4/latest/guide/dev_build.html
If you would like to also help the community, you can join the CKEditor translation center and provide your translations there: https://ckeditor.com/docs/ckeditor4/latest/guide/dev_uilanguage.html
推荐阅读
- node.js - 使用 SSL 的 Nginx 安全性不会阻止 Postman/Http 客户端请求
- android - 尝试更新列表视图android中按钮的可见性
- python - 如何在给定其轴对齐边界框坐标Python的情况下获得对象的旋转
- r - 在 R 中,如果满足条件(等于 1),是否可以提取每个 ID 具有最早日期的行,如果不满足条件,则提取最晚日期?
- node.js - 我收到此错误:无法读取 null 的属性“喜欢”
- reactjs - redux-logger 突然不显示动作名称只有“对象,对象”
- linux - time + sftp 命令脚本:如何正确地将输出重定向到日志文件
- javascript - 访问 Zendesk 票证 api 时未经身份验证访问
- django - 如何将自定义查询的结果添加到 Django 管理站点 change_form 模板?
- java - Java 中的消费者类没有从注册的主题中获取消息。带有 Spring Boot 应用程序的 Kafka