// WoltLabDropdown.js
$.Redactor.prototype.WoltLabDropdown=function(){"use strict";return{init:function(){this.utils.disableBodyScroll=function(){},this.utils.enableBodyScroll=function(){},this.WoltLabDropdown._hideAll(),this.WoltLabDropdown._show()},_hideAll:function(){var o=this.dropdown.hideAll;this.dropdown.hideAll=function(t,i){o.call(this,t,i),$(".redactor-dropdown-"+this.uuid).stop(!0,!0).hide()}.bind(this)},_show:function(){var o=this.dropdown.show;this.dropdown.show=function(t,i){var l=this.button.get(i),d=l.data("dropdown");if(!elDataBool(d[0],"woltlab")){var n=elCreate("ul");for(n.className="dropdownMenu";d[0].childElementCount;)n.appendChild(d[0].children[0]);d[0].appendChild(n),elData(d[0],"woltlab",!0)}var s=l.hasClass("dropact");o.call(this,t,i),s||d.stop(!0).show()}.bind(this)}}};
// WoltLabEvent.js
-$.Redactor.prototype.WoltLabEvent=function(){"use strict";return{init:function(){this._callbacks=[],this._elementId=this.$element[0].id,require(["EventHandler"],function(t){this.WoltLabEvent._setEvents(t);t.add("com.woltlab.wcf.redactor2","showEditor",function(){}.bind(this))}.bind(this))},_setEvents:function(t){var e=this.$element[0].id,i=this.observe.load;this.observe.load=function(){i.call(this),t.fire("com.woltlab.wcf.redactor2","observe_load_"+e,{editor:this.$editor[0]})}.bind(this),this.opts.callbacks.keyup=function(i){var n={cancel:!1,event:i};return t.fire("com.woltlab.wcf.redactor","keyup_"+e,n),n.cancel===!1},t.add("com.woltlab.wcf.redactor2","getText_"+e,function(t){t.message=this.code.get()}.bind(this)),t.add("com.woltlab.wcf.redactor2","reset_"+e,function(){this.code.set("")}.bind(this))},register:function(t,e){require(["EventHandler"],function(i){var n=this.uuid;-1===this._callbacks.indexOf(t)&&(this.opts.callbacks[t]=function(e){var c={cancel:!1,event:e,redactor:this};return i.fire("com.woltlab.wcf.redactor2",t+"_"+n+"_"+this.WoltLabEvent._elementId,c),c.cancel===!1}.bind(this),this._callbacks.push(t)),require(["EventHandler"],function(i){i.add("com.woltlab.wcf.redactor2",t+"_"+n+"_"+this.WoltLabEvent._elementId,e)}.bind(this))}.bind(this))}}};
+$.Redactor.prototype.WoltLabEvent=function(){"use strict";var t=0;return{init:function(){this._callbacks=[],this._elementId=this.$element[0].id,require(["EventHandler"],function(t){this.WoltLabEvent._setEvents(t);t.add("com.woltlab.wcf.redactor2","showEditor",function(){}.bind(this))}.bind(this)),this.$editor[0].addEventListener("focus",function(){t++,document.documentElement.classList.add("redactorActive")}),this.$editor[0].addEventListener("blur",function(){t--,window.setTimeout(function(){0===t&&document.documentElement.classList.remove("redactorActive")},100)})},_setEvents:function(t){var e=this.$element[0].id,i=this.observe.load;this.observe.load=function(){i.call(this),t.fire("com.woltlab.wcf.redactor2","observe_load_"+e,{editor:this.$editor[0]})}.bind(this),this.opts.callbacks.keyup=function(i){var n={cancel:!1,event:i};return t.fire("com.woltlab.wcf.redactor","keyup_"+e,n),n.cancel===!1},t.add("com.woltlab.wcf.redactor2","getText_"+e,function(t){t.message=this.code.get()}.bind(this)),t.add("com.woltlab.wcf.redactor2","reset_"+e,function(){this.code.set("")}.bind(this))},register:function(t,e){require(["EventHandler"],function(i){var n=this.uuid;-1===this._callbacks.indexOf(t)&&(this.opts.callbacks[t]=function(e){var c={cancel:!1,event:e,redactor:this};return i.fire("com.woltlab.wcf.redactor2",t+"_"+n+"_"+this.WoltLabEvent._elementId,c),c.cancel===!1}.bind(this),this._callbacks.push(t)),require(["EventHandler"],function(i){i.add("com.woltlab.wcf.redactor2",t+"_"+n+"_"+this.WoltLabEvent._elementId,e)}.bind(this))}.bind(this))}}};
// WoltLabFont.js
$.Redactor.prototype.WoltLabFont=function(){"use strict";return{init:function(){var t=["arial","comicSansMs","courierNew","georgia","lucidaSansUnicode","tahoma","timesNewRoman","trebuchetMs","verdana"],o=["Arial","Comic Sans MS","Courier New","Georgia","Lucida Sans Unicode","Tahoma","Times New Roman","Trebuchet MS","Verdana"],e=this.WoltLabFont.setFont.bind(this),a={};t.forEach(function(t,n){a[t]={title:o[n],func:e}}),a.removeFont={title:this.lang.get("remove-font"),func:this.WoltLabFont.removeFont.bind(this)};var n=this.button.add("woltlabFont","");this.button.addDropdown(n,a),n.data("dropdown").find("a").each(function(t,o){o.className&&"redactor-dropdown-removeFont"!==o.className&&(o.parentNode.classList.add("woltlab-font-"+o.className.replace(/^redactor-dropdown-/,"")),o.parentNode.classList.add("woltlab-font-selection"))})},setFont:function(t){require(["WoltLabSuite/Core/Ui/Redactor/Format"],function(o){this.buffer.set(),o.format(this.$editor[0],"woltlab-font","woltlab-font-"+t)}.bind(this))},removeFont:function(){require(["WoltLabSuite/Core/Ui/Redactor/Format"],function(t){this.buffer.set(),t.removeFormat(this.$editor[0],"woltlab-font")}.bind(this))}}};
// WoltLabImage.js