Updating minified JavaScript files
authorwoltlab.com <woltlab@woltlab.com>
Mon, 22 Aug 2016 11:02:23 +0000 (13:02 +0200)
committerwoltlab.com <woltlab@woltlab.com>
Mon, 22 Aug 2016 11:02:23 +0000 (13:02 +0200)
wcfsetup/install/files/js/3rdParty/redactor2/plugins/combined.min.js

index 34502862f4452a33c35a0317f151e440fcb6dbda..f0aef7d0ecc34e58bb7693a8943d0d66c18bbb88 100644 (file)
@@ -15,7 +15,7 @@ $.Redactor.prototype.WoltLabBlock=function(){"use strict";return{init:function()
 // WoltLabButton.js
 $.Redactor.prototype.WoltLabButton=function(){"use strict";return{init:function(){var t,o,s,e;for(s=0,e=this.opts.woltlab.customButtons.length;e>s;s++)o=this.opts.woltlab.customButtons[s],t=this.button.add(o,""),this.button.addCallback(t,this.WoltLabButton._handleCustomButton);var n;for(s=0,e=this.opts.buttons.length;e>s;s++)if(o=this.opts.buttons[s],"wcfSeparator"!==o){if(!this.opts.woltlab.buttons.hasOwnProperty(o))throw new Error("Missing button definition for '"+o+"'.");if(n=this.opts.woltlab.buttons[o],"subscript"===o||"superscript"===o?(t=this.button.addAfter(this.opts.buttons[s-1],o,""),this.button.setEvent(t,o,{func:"inline.format"})):t=this.button.get(o),this.button.setIcon(t,'<span class="icon icon16 '+n.icon+'"></span>'),!t[0])throw new Error("Missing button element for '"+o+"'.");elAttr(t[0],"title",n.title),t[0].classList.add("jsTooltip")}for(var i,r={},l=[],a=this.core.toolbar()[0];a.childElementCount;)i=a.removeChild(a.children[0]),o=elAttr(i.children[0],"rel"),r[o]=i,l.push(o);var h=!1;for(s=0,e=this.opts.buttons.length;e>s;s++)o=this.opts.buttons[s],"wcfSeparator"!==o?(i=r[o],a.appendChild(i),l.splice(l.indexOf(o),1),h&&(i.classList.add("redactor-toolbar-separator"),h=!1)):h=!0;for(s=0,e=a.childElementCount;e>s;s++)i=a.children[s],t=i.children[0],elData(i,"show-on-mobile",-1!==this.opts.woltlab.buttonMobile.indexOf(t.rel));l.forEach(function(t){a.appendChild(r[t])}),WCF.DOMNodeInsertedHandler.execute()},_handleCustomButton:function(t){var o={cancel:!1};if(WCF.System.Event.fireEvent("com.woltlab.wcf.redactor2","bbcode_"+t+"_"+this.$element[0].id,o),o.cancel!==!0){this.buffer.set();var s="["+t+"]"+this.selection.html()+(this.selection.is()?"":this.marker.html())+"[/"+t+"]";this.insert.html(s),this.selection.restore()}}}};
 // WoltLabCaret.js
-$.Redactor.prototype.WoltLabCaret=function(){"use strict";return{init:function(){var t=this.caret.after;this.caret.after=function(e){e=this.caret.prepare(e),this.utils.isBlockTag(e.tagName)&&this.WoltLabCaret._addParagraphAfterBlock(e),t.call(this,e)}.bind(this),this.$editor[0].addEventListener("mouseup",this.WoltLabCaret._handleEditorClick.bind(this))},_handleEditorClick:function(t){if(t.target===this.$editor[0]&&this.selection.get().isCollapsed){var e=this.selection.block();if(e!==!1&&"P"!==e.nodeName){this.buffer.set();var i=t.clientY<e.getBoundingClientRect().top,a=elCreate("p");a.textContent="​",e.parentNode.insertBefore(a,i?e:e.nextSibling),this.caret.end(a)}}},_addParagraphAfterBlock:function(t){var e=t.nextElementSibling;(!e||"P"!==e.nodeName&&!this.utils.isBlockTag(e.nodeName))&&(e=elCreate("p"),e.textContent="​",t.parentNode.insertBefore(e,t.nextSibling))}}};
+$.Redactor.prototype.WoltLabCaret=function(){"use strict";return{init:function(){var t=this.caret.after;this.caret.after=function(e){e=this.caret.prepare(e),this.utils.isBlockTag(e.tagName)&&this.WoltLabCaret._addParagraphAfterBlock(e),t.call(this,e)}.bind(this),this.$editor[0].addEventListener("mouseup",this.WoltLabCaret._handleEditorClick.bind(this))},_handleEditorClick:function(t){if(t.target===this.$editor[0]&&this.selection.get().isCollapsed){var e=this.selection.block();if(e!==!1&&("P"!==e.nodeName||(e=e.parentNode,e!==this.$editor[0]&&this.utils.isBlockTag(e.nodeName)))){this.buffer.set();var i=t.clientY<e.getBoundingClientRect().top,a=elCreate("p");a.textContent="​",e.parentNode.insertBefore(a,i?e:e.nextSibling),this.caret.end(a)}}},_addParagraphAfterBlock:function(t){var e=t.nextElementSibling;(!e||"P"!==e.nodeName&&!this.utils.isBlockTag(e.nodeName))&&(e=elCreate("p"),e.textContent="​",t.parentNode.insertBefore(e,t.nextSibling))}}};
 // WoltLabCode.js
 $.Redactor.prototype.WoltLabCode=function(){"use strict";return{init:function(){require(["WoltLabSuite/Core/Ui/Redactor/Code"],function(t){new t(this)}.bind(this))}}};
 // WoltLabColor.js
@@ -29,7 +29,7 @@ $.Redactor.prototype.WoltLabImage=function(){"use strict";return{init:function()
 // WoltLabInlineCode.js
 $.Redactor.prototype.WoltLabInlineCode=function(){"use strict";return{init:function(){this.opts.activeButtonsStates.kbd="tt",require(["EventHandler"],function(t){t.add("com.woltlab.wcf.redactor2","bbcode_tt_"+this.$element[0].id,function(t){t.cancel=!0,this.button.toggle({},"kbd","func","inline.format")}.bind(this))}.bind(this))}}};
 // WoltLabKeydown.js
-$.Redactor.prototype.WoltLabKeydown=function(){"use strict";var t=[];return{init:function(){this.keydown.onArrowDown=function(){for(var t=this.WoltLabKeydown._getBlocks(),n=0;n<t.length;n++)if(t[n])return this.keydown.insertAfterLastElement(t[n]),!1}.bind(this),this.keydown.onArrowUp=function(){for(var t=this.WoltLabKeydown._getBlocks(),n=0;n<t.length;n++)if(t[n])return this.keydown.insertBeforeFirstElement(t[n]),!1}.bind(this);var t=this.keydown.onEnter;this.keydown.onEnter=function(n){var o=this.keydown.blockquote;o&&(this.keydown.blockquote=!1),t.call(this,n),o&&(this.keydown.blockquote=o)}.bind(this)},register:function(n){-1===t.indexOf(n)&&t.push(n)},_getBlocks:function(){for(var n=[this.keydown.blockquote,this.keydown.pre,this.keydown.figcaption],o=0,e=t.length;e>o;o++)n.push(this.utils.isTag(this.keydown.current,t[o]));return n}}};
+$.Redactor.prototype.WoltLabKeydown=function(){"use strict";var t=[];return{init:function(){this.keydown.onArrowDown=function(){for(var t=this.WoltLabKeydown._getBlocks(),n=0;n<t.length;n++)if(t[n])return this.keydown.insertAfterLastElement(t[n]),!1}.bind(this),this.keydown.onArrowUp=function(){for(var t=this.WoltLabKeydown._getBlocks(),n=0;n<t.length;n++)if(t[n])return this.keydown.insertBeforeFirstElement(t[n]),!1}.bind(this);var t=this.keydown.onEnter;this.keydown.onEnter=function(n){var o=this.keydown.blockquote;o&&(this.keydown.blockquote=!1),t.call(this,n),o&&(this.keydown.blockquote=o)}.bind(this);var n=this.keydown.onTab;this.keydown.onTab=function(t,o){return this.keydown.pre||0!==$(this.selection.current()).closest("ul, ol",this.core.editor()[0]).length?n.call(this,t,o):!0}.bind(this)},register:function(n){-1===t.indexOf(n)&&t.push(n)},_getBlocks:function(){for(var n=[this.keydown.blockquote,this.keydown.pre,this.keydown.figcaption],o=0,e=t.length;e>o;o++)n.push(this.utils.isTag(this.keydown.current,t[o]));return n}}};
 // WoltLabLink.js
 $.Redactor.prototype.WoltLabLink=function(){"use strict";var i=null;return{init:function(){this.link.show=this.WoltLabLink.show.bind(this),require(["WoltLabSuite/Core/Ui/Redactor/Link"],function(t){i=t})},show:function(t){"undefined"!=typeof t&&t.preventDefault&&t.preventDefault(),this.selection.save(),this.observe.closeAllTooltip();var e=this.link.is();i.showDialog({insert:e===!1,submitCallback:function(){var i=this.link.buildLinkFromModal();return i===!1?!1:(this.link.insert(i,!0),!0)}.bind(this)});var n=this.link.buildLinkFromElement(e);n.url=this.link.removeSelfHostFromUrl(n.url),this.link.setModalValues(n),this.detect.isDesktop()&&$("#redactor-link-url").focus()}}};
 // WoltLabMedia.js