TinyMCE编辑器,拖放时自动调整图像大小

时间:2018-09-17 13:56:05

标签: javascript tinymce

当我将大图像拖放到编辑器中时,由于编辑器的大小,用户很难调整大小。

是否有办法使TinyMCE拖入一定大小的图像成为默认设置?

这是我的编辑器

tinymce.init({
selector: '#leftHalfTextArea',
height: 500,
force_br_newlines : false,
force_p_newlines : false,
invalid_elements:"div",
forced_root_block : false,
theme: 'modern',
plugins: 'print preview fullpage paste searchreplace autolink directionality code visualblocks visualchars fullscreen image link media template codesample table charmap hr pagebreak nonbreaking anchor toc insertdatetime advlist lists textcolor wordcount spellchecker imagetools media  link contextmenu colorpicker textpattern help',
toolbar1: 'preview | formatselect | bold italic strikethrough forecolor backcolor fontsizeselect fontselect | link | alignleft aligncenter alignright alignjustify  | numlist bullist outdent indent  | removeformat',
plugin_preview_width:1200,
image_advtab: true,
templates: [
{ title: 'Test template 1', content: 'Test 1' },
{ title: 'Test template 2', content: 'Test 2' }
],
image_dimenstions:false,
image_class_list:[
{title: 'Responsive', value: 'img-responsive'}
],
content_css: [
'//fonts.googleapis.com/css?family=Lato:300,300i,400,400i',
'//www.tinymce.com/css/codepen.min.css'
]
});

0 个答案:

没有答案