CKEditor从样式下拉列表中删除样式预览 [英] CKEditor remove style preview from Styles dropdown

查看:81
本文介绍了CKEditor从样式下拉列表中删除样式预览的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在寻找这个问题的答案,但是找不到解决方法.

I've been searching and searching for an answer to this problem and cannot found a solution.

我在CKEditor中添加了一些自定义样式,这些样式在所选文本的左边添加了空白.问题在于,这会导致样式预览在样式列表中向右移动.如此之多,以至于它们偏离了下拉菜单的右侧.我没有足够的代表来发布屏幕截图.

I have added some custom styles to the CKEditor that add a margin-left to the selected text. The problem is that this causes the style previews to move to the right in the styles list. So much so, that they go off the right side of the dropdown. I don't quite have enough rep to post a screenshot unfortunately.

我希望列表中的样式尽可能不预览.

I would just like the styles in the list to have no preview at all if possible.

我尝试将 .cke_panel_listItem p {margin-left:0px!important;} 添加到我的global.css和editor.css中.无论做什么,我都无法覆盖内联样式.

I have tried to add .cke_panel_listItem p {margin-left: 0px !important;} to my global.css and to the editor.css. I cannot override the inline style no matter what I do.

有什么建议吗?预先感谢!

Any suggestions? Thanks in advance!

推荐答案

我能够使用然后在wysiwyg.css中放入您的CSS代码:

then in wysiwyg.css put your CSS code:

.cke_panel_listItem p {
  margin-left: 0px !important;
}

这篇关于CKEditor从样式下拉列表中删除样式预览的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆