Fixed some minor issues
authorAlexander Ebert <ebert@woltlab.com>
Mon, 2 Feb 2015 16:48:38 +0000 (17:48 +0100)
committerAlexander Ebert <ebert@woltlab.com>
Mon, 2 Feb 2015 16:48:38 +0000 (17:48 +0100)
wcfsetup/install/files/js/3rdParty/redactor/plugins/wbbcode.js
wcfsetup/install/files/js/3rdParty/redactor/plugins/wmonkeypatch.js

index cfe22109595278cb9305cabf04a8b1c43e285532..0f309e8cb8f145c9962181d001553607faec9d25 100644 (file)
@@ -586,7 +586,10 @@ RedactorPlugins.wbbcode = function() {
                        
                        // drop newline between [/list] and [*]
                        html = html.replace(/\[\/list\]\n\[\*\]/g, '[/list][*]');
-                       console.debug(html);
+                       
+                       // drop newline between two [/list]
+                       html = html.replace(/\[\/list\]\n\[\/list\]/g, '[/list][/list]');
+                       
                        // [table]
                        html = html.replace(/<table[^>]*>/gi, '[table]\n');
                        html = html.replace(/<\/table>/gi, '[/table]\n');
index 746c82006d60b85f88ea1d48cbc7b77b77676d33..89d12fbb0573075f64311e2cabae4a97a283375c 100644 (file)
@@ -189,7 +189,7 @@ RedactorPlugins.wmonkeypatch = function() {
                                                }
                                                else {
                                                        var $height = $element.outerHeight() + (parseInt($element.css('margin-bottom'), 10) || 0);
-                                                       if ((event.pageY <= $offset.top + $height) || (index + 1) === $elements.length) {
+                                                       if (event.pageY <= $offset.top + $height) {
                                                                $setCaretBeforeOrAfter(element, false);
                                                                
                                                                return false;