【发布时间】:2014-10-21 13:07:59
【问题描述】:
我正在使用 CKEditor 版本 4。我正在制作自定义样式。问题是,当样式显示在下拉列表中时,任何带有 float:right 的样式都会像这样在显示屏上移动:
Item 1
Item 2
FLoat right item
Normal Item
我一直在尝试覆盖样式,但它不起作用。它们是用 JavaScript 动态创建的,我什至不确定类名会影响这一点。
有人知道我该如何解决这个问题吗?
我的样式代码是这样的:
{ name: 'Image 25% Right', element: 'span', attributes: { 'class': 'img_right_25' } },
{ name: 'Image 25% Left', element: 'span', attributes: { 'class': 'img_left_25' } },
{ name: 'Image 50% Right', element: 'span', attributes: { 'class': 'img_right_50' } },
{ name: 'Image 50% Left', element: 'span', attributes: { 'class': 'img_left_50' } },
然后
.img_right_25 {
float:right;
margin-left:10px;
}
.img_left_25 {
float:left;
margin-right:10px
}
【问题讨论】:
标签: ckeditor