带有 Summernote 的自定义工具栏 [英] Custom toolbar with Summernote
本文介绍了带有 Summernote 的自定义工具栏的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何知道summernote的工具栏可以启用哪些功能,以及如何启用?
How do I know which functions can be enabled for the toolbar of summernote, and how to do it?
在 API 文档中,我只能找到工具栏:数组(可选)",没有进一步解释.
In the API docs all I can find is "toolbar : Array (optional)" without further explanation.
由于其中一个示例,我已经设法启用了一些功能,但是我怎样才能同时启用:代码、缩进和缩进?
I've managed to enable some features thanks to one of the examples, but how can I also enable: code, indent and outdent?
$(".summernote").summernote({
styleWithSpan: false,
toolbar: [
['style', ['bold', 'italic', 'underline', 'clear']],
['color', ['color']],
['para', ['ul', 'ol']]
]
});
推荐答案
在 settings.js 你有基本设置(所有功能都打开):
in settings.js You have basic setting (with all features on):
toolbar: [
['style', ['style']],
['font', ['bold', 'italic', 'underline', 'clear']],
['fontname', ['fontname']],
['color', ['color']],
['para', ['ul', 'ol', 'paragraph']],
['height', ['height']],
['table', ['table']],
['insert', ['link', 'picture', 'hr']],
['view', ['fullscreen', 'codeview']],
['help', ['help']]
],
缩进在'段落'
这篇关于带有 Summernote 的自定义工具栏的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文