当前位置:网站首页>tinymce 如何实现动态国际化
tinymce 如何实现动态国际化
2022-08-03 12:53:00 【InfoQ】
tinymce 如何实现动态国际化
language
tinymce.init({
selector: 'textarea.tinymce',
plugins: `code image imagetools media`,
toolbar: `code`,
skin: false,
language: 'ja',
min_height:240,
skeletonScreen: true,
content_css: false,
}).then(()=>{
tinymce.init({
selector: 'div#mytextarea',
menubar: 'file edit insert view format table tools help',
skin: false,
plugins: 'tpImportword',
toolbar: 'tpImportword',
content_css: false,
min_height:240,
skeletonScreen: true
}).then(()=>{
tinymce.init({
selector: 'div#mytextarea3',
skin: false,
language: 'zh_CN',
content_css: false,
min_height:240,
skeletonScreen: true,
plugins: `code`,
toolbar: `code`,
})
})
});

tinymce.init({...}).then(()=>{ tinymce.init({...}).then(()=>{ ... })... })

那么这个问题该 如何解决
editor.editorContainer.onmouseover = () => {
let _language = editor.settings.language
let _currentCodeVal = editor.editorManager.i18n.getCode()
_currentCodeVal != _language && editor.editorManager.i18n.setCode(_language)
};
tinymce.init({
language: 'zh_CN',
content_css: false,
tp_i18n: true,
min_height:240,
plugins: `code`,
toolbar: `code`,
})

tp_i18n_langs: true
tpI18n
tinymce.init({
selector: 'div#mytextarea',
menubar: 'file edit insert view format table tools help mymenubar',
skin: false,
tp_i18n: true,
plugins: 'tpImportword',
toolbar: 'tpImportword',
tp_i18n_langs: true,
content_css: false,
menu: {
mymenubar: { title: 'Extension', items: 'tpI18n' },
},
min_height:240,
skeletonScreen: true,
setup: (
editor
)=>{
}
})


边栏推荐
猜你喜欢
OpenCV 透视变换
An动画基础之按钮动画与基础代码相结合
基于php旅游网站管理系统获取(php毕业设计)
An introduction to basic tools for selecting line tools (package church)
[Practical skills] APP video tutorial for updating APP in CANFD, I2C, SPI and serial port mode of single-chip bootloader (2022-08-01)
365天挑战LeetCode1000题——Day 048 有序队列 脑筋急转弯
An工具介绍之钢笔工具、铅笔工具与画笔工具
[微服务]多级缓存
Jmeter use
OpenCV perspective transform
随机推荐
数据库基础知识一(MySQL)[通俗易懂]
Tinymce plugins [Tinymce扩展插件集合]
Redis connection pool tool class
Golang Mutex
In order to counteract the drop in sales and explore the low-end market, Weilai's new brand products are priced as low as 100,000?
Golang sync.WaitGroup
IronOS, an open source system for portable soldering irons, supports a variety of portable DC, QC, PD powered soldering irons, and supports all standard functions of smart soldering irons
【深度学习】高效轻量级语义分割综述
Blog records life
为冲销量下探中低端市场,蔚来新品牌产品定价低至10万?
ECCV 2022|通往数据高效的Transformer目标检测器
Oracle安装完毕(系统盘),从系统盘转移到数据盘
shell编程之条件语句
[数据仓库]分层概念,ODS,DM,DWD,DWS,DIM的概念「建议收藏」
Free Internet fax platform fax _ don't show number
实数取整写入文件(C语言文件篇)
技术分享 | 接口自动化测试如何搞定 json 响应断言?
PyTorch builds a neural network to predict temperature (dataset comparison, CPU vs GPU comparison)
基于php旅游网站管理系统获取(php毕业设计)
HCIP第十五天笔记(企业网的三层架构、VLAN以及VLAN 的配置)