SCEditor
SCEditor copied to clipboard
Paragraph bug in bbeditor
The bb editor is initiated in paragraph mode. So every press of the Enter key for a new line creates a double spacing. Then when toggling source and back to wysiwyg mode all paragraphs are removed and lines are compacted.
If there are no zones the select field should become optional. Try to reproduce this in the demo. http://demo.litecart.net/
<script src="/ext/sceditor/jquery.sceditor.bbcode.min.js"></script>
<script src="/ext/sceditor/formats/bbcode.min.js"></script>
<script src="/ext/sceditor/plugins/plaintext.min.js"></script>
<script src="/ext/sceditor/languages/en.js"></script>
<script>
$("textarea[name='message']").sceditor({
"format": "bbcode",
"plugins": "plaintext",
pastetext: {
addButton: true,
enabled: true,
},
"style": "/includes/templates/default/css/framework.min.css",
"locale": "en",
"emoticonsEnabled": false,
"enablePasteFiltering ": true,
"toolbar": "bold,italic,underline,strike|removeformat|bulletlist,orderedlist,table|code,quote|horizontalrule,image,link,unlink|source",
bbcodeTrim : true,
parserOptions: {
breakBeforeBlock: false,
breakStartBlock: false
},
width: "auto"
});
</script>
No errors logged.
Any idea what causes this? Using latest version 2.1.2.
I have the same issue with 3.1.1, double spacing whenever I press enter key. Toggling between code and back removes the double spacing.
Update: Make sure the path for the "style" option is correct. This corrected the double spacing issue for me.
I also ran into this, and it appears to be harmless as long as the path for the style option points to a style sheet that specifies zero margin for P tags. If you do that everything works and appears as expected.
I noticed you appear to be pointing at the full framework style in the style option. This is almost certainly not going to work right. It really needs its own special stylesheet, because it's only styling the content in the iframe that is the WYSIWYG editor.