OpenXE/www/js/ckeditor/ckeditor.js
2021-05-21 08:49:41 +02:00

1202 lines
612 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/*
Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.md or http://ckeditor.com/license
*/
(function(){window.CKEDITOR&&window.CKEDITOR.dom||(window.CKEDITOR||(window.CKEDITOR=function(){var a=/(^|.*[\\\/])ckeditor\.js(?:\?.*|;.*)?$/i,e={timestamp:"HBDG",version:"4.8.0 (Standard)",revision:"230f715",rnd:Math.floor(900*Math.random())+100,_:{pending:[],basePathSrcPattern:a},status:"unloaded",basePath:function(){var b=window.CKEDITOR_BASEPATH||"";if(!b)for(var d=document.getElementsByTagName("script"),e=0;e<d.length;e++){var h=d[e].src.match(a);if(h){b=h[1];break}}-1==b.indexOf(":/")&&"//"!=
b.slice(0,2)&&(b=0===b.indexOf("/")?location.href.match(/^.*?:\/\/[^\/]*/)[0]+b:location.href.match(/^[^\?]*\/(?:)/)[0]+b);if(!b)throw'The CKEditor installation path could not be automatically detected. Please set the global variable "CKEDITOR_BASEPATH" before creating editor instances.';return b}(),getUrl:function(a){-1==a.indexOf(":/")&&0!==a.indexOf("/")&&(a=this.basePath+a);this.timestamp&&"/"!=a.charAt(a.length-1)&&!/[&?]t=/.test(a)&&(a+=(0<=a.indexOf("?")?"\x26":"?")+"t\x3d"+this.timestamp);
return a},domReady:function(){function a(){try{document.addEventListener?(document.removeEventListener("DOMContentLoaded",a,!1),b()):document.attachEvent&&"complete"===document.readyState&&(document.detachEvent("onreadystatechange",a),b())}catch(h){}}function b(){for(var a;a=d.shift();)a()}var d=[];return function(h){function c(){try{document.documentElement.doScroll("left")}catch(f){setTimeout(c,1);return}a()}d.push(h);"complete"===document.readyState&&setTimeout(a,1);if(1==d.length)if(document.addEventListener)document.addEventListener("DOMContentLoaded",
a,!1),window.addEventListener("load",a,!1);else if(document.attachEvent){document.attachEvent("onreadystatechange",a);window.attachEvent("onload",a);h=!1;try{h=!window.frameElement}catch(m){}document.documentElement.doScroll&&h&&c()}}}()},b=window.CKEDITOR_GETURL;if(b){var d=e.getUrl;e.getUrl=function(a){return b.call(e,a)||d.call(e,a)}}return e}()),CKEDITOR.event||(CKEDITOR.event=function(){},CKEDITOR.event.implementOn=function(a){var e=CKEDITOR.event.prototype,b;for(b in e)null==a[b]&&(a[b]=e[b])},
CKEDITOR.event.prototype=function(){function a(a){var g=e(this);return g[a]||(g[a]=new b(a))}var e=function(a){a=a.getPrivate&&a.getPrivate()||a._||(a._={});return a.events||(a.events={})},b=function(a){this.name=a;this.listeners=[]};b.prototype={getListenerIndex:function(a){for(var b=0,e=this.listeners;b<e.length;b++)if(e[b].fn==a)return b;return-1}};return{define:function(b,g){var e=a.call(this,b);CKEDITOR.tools.extend(e,g,!0)},on:function(b,g,e,k,h){function c(f,a,c,h){f={name:b,sender:this,editor:f,
data:a,listenerData:k,stop:c,cancel:h,removeListener:m};return!1===g.call(e,f)?!1:f.data}function m(){n.removeListener(b,g)}var f=a.call(this,b);if(0>f.getListenerIndex(g)){f=f.listeners;e||(e=this);isNaN(h)&&(h=10);var n=this;c.fn=g;c.priority=h;for(var p=f.length-1;0<=p;p--)if(f[p].priority<=h)return f.splice(p+1,0,c),{removeListener:m};f.unshift(c)}return{removeListener:m}},once:function(){var a=Array.prototype.slice.call(arguments),b=a[1];a[1]=function(a){a.removeListener();return b.apply(this,
arguments)};return this.on.apply(this,a)},capture:function(){CKEDITOR.event.useCapture=1;var a=this.on.apply(this,arguments);CKEDITOR.event.useCapture=0;return a},fire:function(){var a=0,b=function(){a=1},l=0,k=function(){l=1};return function(h,c,m){var f=e(this)[h];h=a;var n=l;a=l=0;if(f){var p=f.listeners;if(p.length)for(var p=p.slice(0),q,v=0;v<p.length;v++){if(f.errorProof)try{q=p[v].call(this,m,c,b,k)}catch(y){}else q=p[v].call(this,m,c,b,k);!1===q?l=1:"undefined"!=typeof q&&(c=q);if(a||l)break}}c=
l?!1:"undefined"==typeof c?!0:c;a=h;l=n;return c}}(),fireOnce:function(a,b,l){b=this.fire(a,b,l);delete e(this)[a];return b},removeListener:function(a,b){var l=e(this)[a];if(l){var k=l.getListenerIndex(b);0<=k&&l.listeners.splice(k,1)}},removeAllListeners:function(){var a=e(this),b;for(b in a)delete a[b]},hasListeners:function(a){return(a=e(this)[a])&&0<a.listeners.length}}}()),CKEDITOR.editor||(CKEDITOR.editor=function(){CKEDITOR._.pending.push([this,arguments]);CKEDITOR.event.call(this)},CKEDITOR.editor.prototype.fire=
function(a,e){a in{instanceReady:1,loaded:1}&&(this[a]=!0);return CKEDITOR.event.prototype.fire.call(this,a,e,this)},CKEDITOR.editor.prototype.fireOnce=function(a,e){a in{instanceReady:1,loaded:1}&&(this[a]=!0);return CKEDITOR.event.prototype.fireOnce.call(this,a,e,this)},CKEDITOR.event.implementOn(CKEDITOR.editor.prototype)),CKEDITOR.env||(CKEDITOR.env=function(){var a=navigator.userAgent.toLowerCase(),e=a.match(/edge[ \/](\d+.?\d*)/),b=-1<a.indexOf("trident/"),b=!(!e&&!b),b={ie:b,edge:!!e,webkit:!b&&
-1<a.indexOf(" applewebkit/"),air:-1<a.indexOf(" adobeair/"),mac:-1<a.indexOf("macintosh"),quirks:"BackCompat"==document.compatMode&&(!document.documentMode||10>document.documentMode),mobile:-1<a.indexOf("mobile"),iOS:/(ipad|iphone|ipod)/.test(a),isCustomDomain:function(){if(!this.ie)return!1;var a=document.domain,b=window.location.hostname;return a!=b&&a!="["+b+"]"},secure:"https:"==location.protocol};b.gecko="Gecko"==navigator.product&&!b.webkit&&!b.ie;b.webkit&&(-1<a.indexOf("chrome")?b.chrome=
!0:b.safari=!0);var d=0;b.ie&&(d=e?parseFloat(e[1]):b.quirks||!document.documentMode?parseFloat(a.match(/msie (\d+)/)[1]):document.documentMode,b.ie9Compat=9==d,b.ie8Compat=8==d,b.ie7Compat=7==d,b.ie6Compat=7>d||b.quirks);b.gecko&&(e=a.match(/rv:([\d\.]+)/))&&(e=e[1].split("."),d=1E4*e[0]+100*(e[1]||0)+1*(e[2]||0));b.air&&(d=parseFloat(a.match(/ adobeair\/(\d+)/)[1]));b.webkit&&(d=parseFloat(a.match(/ applewebkit\/(\d+)/)[1]));b.version=d;b.isCompatible=!(b.ie&&7>d)&&!(b.gecko&&4E4>d)&&!(b.webkit&&
534>d);b.hidpi=2<=window.devicePixelRatio;b.needsBrFiller=b.gecko||b.webkit||b.ie&&10<d;b.needsNbspFiller=b.ie&&11>d;b.cssClass="cke_browser_"+(b.ie?"ie":b.gecko?"gecko":b.webkit?"webkit":"unknown");b.quirks&&(b.cssClass+=" cke_browser_quirks");b.ie&&(b.cssClass+=" cke_browser_ie"+(b.quirks?"6 cke_browser_iequirks":b.version));b.air&&(b.cssClass+=" cke_browser_air");b.iOS&&(b.cssClass+=" cke_browser_ios");b.hidpi&&(b.cssClass+=" cke_hidpi");return b}()),"unloaded"==CKEDITOR.status&&function(){CKEDITOR.event.implementOn(CKEDITOR);
CKEDITOR.loadFullCore=function(){if("basic_ready"!=CKEDITOR.status)CKEDITOR.loadFullCore._load=1;else{delete CKEDITOR.loadFullCore;var a=document.createElement("script");a.type="text/javascript";a.src=CKEDITOR.basePath+"ckeditor.js";document.getElementsByTagName("head")[0].appendChild(a)}};CKEDITOR.loadFullCoreTimeout=0;CKEDITOR.add=function(a){(this._.pending||(this._.pending=[])).push(a)};(function(){CKEDITOR.domReady(function(){var a=CKEDITOR.loadFullCore,e=CKEDITOR.loadFullCoreTimeout;a&&(CKEDITOR.status=
"basic_ready",a&&a._load?a():e&&setTimeout(function(){CKEDITOR.loadFullCore&&CKEDITOR.loadFullCore()},1E3*e))})})();CKEDITOR.status="basic_loaded"}(),"use strict",CKEDITOR.VERBOSITY_WARN=1,CKEDITOR.VERBOSITY_ERROR=2,CKEDITOR.verbosity=CKEDITOR.VERBOSITY_WARN|CKEDITOR.VERBOSITY_ERROR,CKEDITOR.warn=function(a,e){CKEDITOR.verbosity&CKEDITOR.VERBOSITY_WARN&&CKEDITOR.fire("log",{type:"warn",errorCode:a,additionalData:e})},CKEDITOR.error=function(a,e){CKEDITOR.verbosity&CKEDITOR.VERBOSITY_ERROR&&CKEDITOR.fire("log",
{type:"error",errorCode:a,additionalData:e})},CKEDITOR.on("log",function(a){if(window.console&&window.console.log){var e=console[a.data.type]?a.data.type:"log",b=a.data.errorCode;if(a=a.data.additionalData)console[e]("[CKEDITOR] Error code: "+b+".",a);else console[e]("[CKEDITOR] Error code: "+b+".");console[e]("[CKEDITOR] For more information about this error go to https://docs.ckeditor.com/ckeditor4/docs/#!/guide/dev_errors-section-"+b)}},null,null,999),CKEDITOR.dom={},function(){var a=[],e=CKEDITOR.env.gecko?
"-moz-":CKEDITOR.env.webkit?"-webkit-":CKEDITOR.env.ie?"-ms-":"",b=/&/g,d=/>/g,g=/</g,l=/"/g,k=/&(lt|gt|amp|quot|nbsp|shy|#\d{1,5});/g,h={lt:"\x3c",gt:"\x3e",amp:"\x26",quot:'"',nbsp:" ",shy:"­"},c=function(a,f){return"#"==f[0]?String.fromCharCode(parseInt(f.slice(1),10)):h[f]};CKEDITOR.on("reset",function(){a=[]});CKEDITOR.tools={arrayCompare:function(a,f){if(!a&&!f)return!0;if(!a||!f||a.length!=f.length)return!1;for(var c=0;c<a.length;c++)if(a[c]!=f[c])return!1;return!0},getIndex:function(a,f){for(var c=
0;c<a.length;++c)if(f(a[c]))return c;return-1},clone:function(a){var f;if(a&&a instanceof Array){f=[];for(var c=0;c<a.length;c++)f[c]=CKEDITOR.tools.clone(a[c]);return f}if(null===a||"object"!=typeof a||a instanceof String||a instanceof Number||a instanceof Boolean||a instanceof Date||a instanceof RegExp||a.nodeType||a.window===a)return a;f=new a.constructor;for(c in a)f[c]=CKEDITOR.tools.clone(a[c]);return f},capitalize:function(a,f){return a.charAt(0).toUpperCase()+(f?a.slice(1):a.slice(1).toLowerCase())},
extend:function(a){var f=arguments.length,c,b;"boolean"==typeof(c=arguments[f-1])?f--:"boolean"==typeof(c=arguments[f-2])&&(b=arguments[f-1],f-=2);for(var h=1;h<f;h++){var d=arguments[h],g;for(g in d)if(!0===c||null==a[g])if(!b||g in b)a[g]=d[g]}return a},prototypedCopy:function(a){var f=function(){};f.prototype=a;return new f},copy:function(a){var f={},c;for(c in a)f[c]=a[c];return f},isArray:function(a){return"[object Array]"==Object.prototype.toString.call(a)},isEmpty:function(a){for(var f in a)if(a.hasOwnProperty(f))return!1;
return!0},cssVendorPrefix:function(a,f,c){if(c)return e+a+":"+f+";"+a+":"+f;c={};c[a]=f;c[e+a]=f;return c},cssStyleToDomStyle:function(){var a=document.createElement("div").style,f="undefined"!=typeof a.cssFloat?"cssFloat":"undefined"!=typeof a.styleFloat?"styleFloat":"float";return function(a){return"float"==a?f:a.replace(/-./g,function(f){return f.substr(1).toUpperCase()})}}(),buildStyleHtml:function(a){a=[].concat(a);for(var f,c=[],b=0;b<a.length;b++)if(f=a[b])/@import|[{}]/.test(f)?c.push("\x3cstyle\x3e"+
f+"\x3c/style\x3e"):c.push('\x3clink type\x3d"text/css" rel\x3dstylesheet href\x3d"'+f+'"\x3e');return c.join("")},htmlEncode:function(a){return void 0===a||null===a?"":String(a).replace(b,"\x26amp;").replace(d,"\x26gt;").replace(g,"\x26lt;")},htmlDecode:function(a){return a.replace(k,c)},htmlEncodeAttr:function(a){return CKEDITOR.tools.htmlEncode(a).replace(l,"\x26quot;")},htmlDecodeAttr:function(a){return CKEDITOR.tools.htmlDecode(a)},transformPlainTextToHtml:function(a,f){var c=f==CKEDITOR.ENTER_BR,
b=this.htmlEncode(a.replace(/\r\n/g,"\n")),b=b.replace(/\t/g,"\x26nbsp;\x26nbsp; \x26nbsp;"),h=f==CKEDITOR.ENTER_P?"p":"div";if(!c){var d=/\n{2}/g;if(d.test(b))var g="\x3c"+h+"\x3e",e="\x3c/"+h+"\x3e",b=g+b.replace(d,function(){return e+g})+e}b=b.replace(/\n/g,"\x3cbr\x3e");c||(b=b.replace(new RegExp("\x3cbr\x3e(?\x3d\x3c/"+h+"\x3e)"),function(f){return CKEDITOR.tools.repeat(f,2)}));b=b.replace(/^ | $/g,"\x26nbsp;");return b=b.replace(/(>|\s) /g,function(f,a){return a+"\x26nbsp;"}).replace(/ (?=<)/g,
"\x26nbsp;")},getNextNumber:function(){var a=0;return function(){return++a}}(),getNextId:function(){return"cke_"+this.getNextNumber()},getUniqueId:function(){for(var a="e",f=0;8>f;f++)a+=Math.floor(65536*(1+Math.random())).toString(16).substring(1);return a},override:function(a,f){var c=f(a);c.prototype=a.prototype;return c},setTimeout:function(a,f,c,b,h){h||(h=window);c||(c=h);return h.setTimeout(function(){b?a.apply(c,[].concat(b)):a.apply(c)},f||0)},trim:function(){var a=/(?:^[ \t\n\r]+)|(?:[ \t\n\r]+$)/g;
return function(f){return f.replace(a,"")}}(),ltrim:function(){var a=/^[ \t\n\r]+/g;return function(f){return f.replace(a,"")}}(),rtrim:function(){var a=/[ \t\n\r]+$/g;return function(f){return f.replace(a,"")}}(),indexOf:function(a,f){if("function"==typeof f)for(var c=0,b=a.length;c<b;c++){if(f(a[c]))return c}else{if(a.indexOf)return a.indexOf(f);c=0;for(b=a.length;c<b;c++)if(a[c]===f)return c}return-1},search:function(a,f){var c=CKEDITOR.tools.indexOf(a,f);return 0<=c?a[c]:null},bind:function(a,
f){return function(){return a.apply(f,arguments)}},createClass:function(a){var f=a.$,c=a.base,b=a.privates||a._,h=a.proto;a=a.statics;!f&&(f=function(){c&&this.base.apply(this,arguments)});if(b)var d=f,f=function(){var f=this._||(this._={}),a;for(a in b){var c=b[a];f[a]="function"==typeof c?CKEDITOR.tools.bind(c,this):c}d.apply(this,arguments)};c&&(f.prototype=this.prototypedCopy(c.prototype),f.prototype.constructor=f,f.base=c,f.baseProto=c.prototype,f.prototype.base=function(){this.base=c.prototype.base;
c.apply(this,arguments);this.base=arguments.callee});h&&this.extend(f.prototype,h,!0);a&&this.extend(f,a,!0);return f},addFunction:function(c,f){return a.push(function(){return c.apply(f||this,arguments)})-1},removeFunction:function(c){a[c]=null},callFunction:function(c){var f=a[c];return f&&f.apply(window,Array.prototype.slice.call(arguments,1))},cssLength:function(){var a=/^-?\d+\.?\d*px$/,f;return function(c){f=CKEDITOR.tools.trim(c+"")+"px";return a.test(f)?f:c||""}}(),convertToPx:function(){var a;
return function(f){a||(a=CKEDITOR.dom.element.createFromHtml('\x3cdiv style\x3d"position:absolute;left:-9999px;top:-9999px;margin:0px;padding:0px;border:0px;"\x3e\x3c/div\x3e',CKEDITOR.document),CKEDITOR.document.getBody().append(a));return/%$/.test(f)?f:(a.setStyle("width",f),a.$.clientWidth)}}(),repeat:function(a,f){return Array(f+1).join(a)},tryThese:function(){for(var a,f=0,c=arguments.length;f<c;f++){var b=arguments[f];try{a=b();break}catch(h){}}return a},genKey:function(){return Array.prototype.slice.call(arguments).join("-")},
defer:function(a){return function(){var f=arguments,c=this;window.setTimeout(function(){a.apply(c,f)},0)}},normalizeCssText:function(a,f){var c=[],b,h=CKEDITOR.tools.parseCssText(a,!0,f);for(b in h)c.push(b+":"+h[b]);c.sort();return c.length?c.join(";")+";":""},convertRgbToHex:function(a){return a.replace(/(?:rgb\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*\))/gi,function(f,a,c,b){f=[a,c,b];for(a=0;3>a;a++)f[a]=("0"+parseInt(f[a],10).toString(16)).slice(-2);return"#"+f.join("")})},normalizeHex:function(a){return a.replace(/#(([0-9a-f]{3}){1,2})($|;|\s+)/gi,
function(a,c,b,h){a=c.toLowerCase();3==a.length&&(a=a.split(""),a=[a[0],a[0],a[1],a[1],a[2],a[2]].join(""));return"#"+a+h})},parseCssText:function(a,f,c){var b={};c&&(a=(new CKEDITOR.dom.element("span")).setAttribute("style",a).getAttribute("style")||"");a&&(a=CKEDITOR.tools.normalizeHex(CKEDITOR.tools.convertRgbToHex(a)));if(!a||";"==a)return b;a.replace(/&quot;/g,'"').replace(/\s*([^:;\s]+)\s*:\s*([^;]+)\s*(?=;|$)/g,function(a,c,h){f&&(c=c.toLowerCase(),"font-family"==c&&(h=h.replace(/\s*,\s*/g,
",")),h=CKEDITOR.tools.trim(h));b[c]=h});return b},writeCssText:function(a,f){var c,b=[];for(c in a)b.push(c+":"+a[c]);f&&b.sort();return b.join("; ")},objectCompare:function(a,f,c){var b;if(!a&&!f)return!0;if(!a||!f)return!1;for(b in a)if(a[b]!=f[b])return!1;if(!c)for(b in f)if(a[b]!=f[b])return!1;return!0},objectKeys:function(a){var f=[],c;for(c in a)f.push(c);return f},convertArrayToObject:function(a,f){var c={};1==arguments.length&&(f=!0);for(var b=0,h=a.length;b<h;++b)c[a[b]]=f;return c},fixDomain:function(){for(var a;;)try{a=
window.parent.document.domain;break}catch(f){a=a?a.replace(/.+?(?:\.|$)/,""):document.domain;if(!a)break;document.domain=a}return!!a},eventsBuffer:function(a,f,c){function b(){d=(new Date).getTime();h=!1;c?f.call(c):f()}var h,d=0;return{input:function(){if(!h){var f=(new Date).getTime()-d;f<a?h=setTimeout(b,a-f):b()}},reset:function(){h&&clearTimeout(h);h=d=0}}},enableHtml5Elements:function(a,f){for(var c="abbr article aside audio bdi canvas data datalist details figcaption figure footer header hgroup main mark meter nav output progress section summary time video".split(" "),
b=c.length,h;b--;)h=a.createElement(c[b]),f&&a.appendChild(h)},checkIfAnyArrayItemMatches:function(a,f){for(var c=0,b=a.length;c<b;++c)if(a[c].match(f))return!0;return!1},checkIfAnyObjectPropertyMatches:function(a,f){for(var c in a)if(c.match(f))return!0;return!1},keystrokeToString:function(a,f){var c=this.keystrokeToArray(a,f);c.display=c.display.join("+");c.aria=c.aria.join("+");return c},keystrokeToArray:function(a,f){var c=f&16711680,b=f&65535,h=CKEDITOR.env.mac,d=[],g=[];c&CKEDITOR.CTRL&&(d.push(h?
"⌘":a[17]),g.push(h?a[224]:a[17]));c&CKEDITOR.ALT&&(d.push(h?"⌥":a[18]),g.push(a[18]));c&CKEDITOR.SHIFT&&(d.push(h?"⇧":a[16]),g.push(a[16]));b&&(a[b]?(d.push(a[b]),g.push(a[b])):(d.push(String.fromCharCode(b)),g.push(String.fromCharCode(b))));return{display:d,aria:g}},transparentImageData:"data:image/gif;base64,R0lGODlhAQABAPABAP///wAAACH5BAEKAAAALAAAAAABAAEAAAICRAEAOw\x3d\x3d",getCookie:function(a){a=a.toLowerCase();for(var f=document.cookie.split(";"),c,b,h=0;h<f.length;h++)if(c=f[h].split("\x3d"),
b=decodeURIComponent(CKEDITOR.tools.trim(c[0]).toLowerCase()),b===a)return decodeURIComponent(1<c.length?c[1]:"");return null},setCookie:function(a,f){document.cookie=encodeURIComponent(a)+"\x3d"+encodeURIComponent(f)+";path\x3d/"},getCsrfToken:function(){var a=CKEDITOR.tools.getCookie("ckCsrfToken");if(!a||40!=a.length){var a=[],f="";if(window.crypto&&window.crypto.getRandomValues)a=new Uint8Array(40),window.crypto.getRandomValues(a);else for(var c=0;40>c;c++)a.push(Math.floor(256*Math.random()));
for(c=0;c<a.length;c++)var b="abcdefghijklmnopqrstuvwxyz0123456789".charAt(a[c]%36),f=f+(.5<Math.random()?b.toUpperCase():b);a=f;CKEDITOR.tools.setCookie("ckCsrfToken",a)}return a},escapeCss:function(a){return a?window.CSS&&CSS.escape?CSS.escape(a):isNaN(parseInt(a.charAt(0),10))?a:"\\3"+a.charAt(0)+" "+a.substring(1,a.length):""},getMouseButton:function(a){var f=(a=a.data)&&a.$;return a&&f?CKEDITOR.env.ie&&9>CKEDITOR.env.version?4===f.button?CKEDITOR.MOUSE_BUTTON_MIDDLE:1===f.button?CKEDITOR.MOUSE_BUTTON_LEFT:
CKEDITOR.MOUSE_BUTTON_RIGHT:f.button:!1},convertHexStringToBytes:function(a){var f=[],c=a.length/2,b;for(b=0;b<c;b++)f.push(parseInt(a.substr(2*b,2),16));return f},convertBytesToBase64:function(a){var f="",c=a.length,b;for(b=0;b<c;b+=3){var h=a.slice(b,b+3),d=h.length,g=[],e;if(3>d)for(e=d;3>e;e++)h[e]=0;g[0]=(h[0]&252)>>2;g[1]=(h[0]&3)<<4|h[1]>>4;g[2]=(h[1]&15)<<2|(h[2]&192)>>6;g[3]=h[2]&63;for(e=0;4>e;e++)f=e<=d?f+"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(g[e]):f+
"\x3d"}return f},style:{parse:{_colors:{aliceblue:"#F0F8FF",antiquewhite:"#FAEBD7",aqua:"#00FFFF",aquamarine:"#7FFFD4",azure:"#F0FFFF",beige:"#F5F5DC",bisque:"#FFE4C4",black:"#000000",blanchedalmond:"#FFEBCD",blue:"#0000FF",blueviolet:"#8A2BE2",brown:"#A52A2A",burlywood:"#DEB887",cadetblue:"#5F9EA0",chartreuse:"#7FFF00",chocolate:"#D2691E",coral:"#FF7F50",cornflowerblue:"#6495ED",cornsilk:"#FFF8DC",crimson:"#DC143C",cyan:"#00FFFF",darkblue:"#00008B",darkcyan:"#008B8B",darkgoldenrod:"#B8860B",darkgray:"#A9A9A9",
darkgreen:"#006400",darkgrey:"#A9A9A9",darkkhaki:"#BDB76B",darkmagenta:"#8B008B",darkolivegreen:"#556B2F",darkorange:"#FF8C00",darkorchid:"#9932CC",darkred:"#8B0000",darksalmon:"#E9967A",darkseagreen:"#8FBC8F",darkslateblue:"#483D8B",darkslategray:"#2F4F4F",darkslategrey:"#2F4F4F",darkturquoise:"#00CED1",darkviolet:"#9400D3",deeppink:"#FF1493",deepskyblue:"#00BFFF",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1E90FF",firebrick:"#B22222",floralwhite:"#FFFAF0",forestgreen:"#228B22",fuchsia:"#FF00FF",
gainsboro:"#DCDCDC",ghostwhite:"#F8F8FF",gold:"#FFD700",goldenrod:"#DAA520",gray:"#808080",green:"#008000",greenyellow:"#ADFF2F",grey:"#808080",honeydew:"#F0FFF0",hotpink:"#FF69B4",indianred:"#CD5C5C",indigo:"#4B0082",ivory:"#FFFFF0",khaki:"#F0E68C",lavender:"#E6E6FA",lavenderblush:"#FFF0F5",lawngreen:"#7CFC00",lemonchiffon:"#FFFACD",lightblue:"#ADD8E6",lightcoral:"#F08080",lightcyan:"#E0FFFF",lightgoldenrodyellow:"#FAFAD2",lightgray:"#D3D3D3",lightgreen:"#90EE90",lightgrey:"#D3D3D3",lightpink:"#FFB6C1",
lightsalmon:"#FFA07A",lightseagreen:"#20B2AA",lightskyblue:"#87CEFA",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#B0C4DE",lightyellow:"#FFFFE0",lime:"#00FF00",limegreen:"#32CD32",linen:"#FAF0E6",magenta:"#FF00FF",maroon:"#800000",mediumaquamarine:"#66CDAA",mediumblue:"#0000CD",mediumorchid:"#BA55D3",mediumpurple:"#9370DB",mediumseagreen:"#3CB371",mediumslateblue:"#7B68EE",mediumspringgreen:"#00FA9A",mediumturquoise:"#48D1CC",mediumvioletred:"#C71585",midnightblue:"#191970",mintcream:"#F5FFFA",
mistyrose:"#FFE4E1",moccasin:"#FFE4B5",navajowhite:"#FFDEAD",navy:"#000080",oldlace:"#FDF5E6",olive:"#808000",olivedrab:"#6B8E23",orange:"#FFA500",orangered:"#FF4500",orchid:"#DA70D6",palegoldenrod:"#EEE8AA",palegreen:"#98FB98",paleturquoise:"#AFEEEE",palevioletred:"#DB7093",papayawhip:"#FFEFD5",peachpuff:"#FFDAB9",peru:"#CD853F",pink:"#FFC0CB",plum:"#DDA0DD",powderblue:"#B0E0E6",purple:"#800080",rebeccapurple:"#663399",red:"#FF0000",rosybrown:"#BC8F8F",royalblue:"#4169E1",saddlebrown:"#8B4513",salmon:"#FA8072",
sandybrown:"#F4A460",seagreen:"#2E8B57",seashell:"#FFF5EE",sienna:"#A0522D",silver:"#C0C0C0",skyblue:"#87CEEB",slateblue:"#6A5ACD",slategray:"#708090",slategrey:"#708090",snow:"#FFFAFA",springgreen:"#00FF7F",steelblue:"#4682B4",tan:"#D2B48C",teal:"#008080",thistle:"#D8BFD8",tomato:"#FF6347",turquoise:"#40E0D0",violet:"#EE82EE",wheat:"#F5DEB3",white:"#FFFFFF",whitesmoke:"#F5F5F5",yellow:"#FFFF00",yellowgreen:"#9ACD32"},_borderStyle:"none hidden dotted dashed solid double groove ridge inset outset".split(" "),
_widthRegExp:/^(thin|medium|thick|[\+-]?\d+(\.\d+)?[a-z%]+|[\+-]?0+(\.0+)?|\.\d+[a-z%]+)$/,_rgbaRegExp:/rgba?\(\s*\d+%?\s*,\s*\d+%?\s*,\s*\d+%?\s*(?:,\s*[0-9.]+\s*)?\)/gi,_hslaRegExp:/hsla?\(\s*[0-9.]+\s*,\s*\d+%\s*,\s*\d+%\s*(?:,\s*[0-9.]+\s*)?\)/gi,background:function(a){var f={},c=this._findColor(a);c.length&&(f.color=c[0],CKEDITOR.tools.array.forEach(c,function(f){a=a.replace(f,"")}));if(a=CKEDITOR.tools.trim(a))f.unprocessed=a;return f},margin:function(a){function f(a){c.top=b[a[0]];c.right=
b[a[1]];c.bottom=b[a[2]];c.left=b[a[3]]}var c={},b=a.match(/(?:\-?[\.\d]+(?:%|\w*)|auto|inherit|initial|unset)/g)||["0px"];switch(b.length){case 1:f([0,0,0,0]);break;case 2:f([0,1,0,1]);break;case 3:f([0,1,2,1]);break;case 4:f([0,1,2,3])}return c},border:function(a){var f={};a=a.split(/\s+/);CKEDITOR.tools.array.forEach(a,function(a){if(!f.color){var c=CKEDITOR.tools.style.parse._findColor(a);if(c.length){f.color=c[0];return}}f.style||-1===CKEDITOR.tools.indexOf(CKEDITOR.tools.style.parse._borderStyle,
a)?!f.width&&CKEDITOR.tools.style.parse._widthRegExp.test(a)&&(f.width=a):f.style=a});return f},_findColor:function(a){var f=[],c=CKEDITOR.tools.array,f=f.concat(a.match(this._rgbaRegExp)||[]),f=f.concat(a.match(this._hslaRegExp)||[]);return f=f.concat(c.filter(a.split(/\s+/),function(a){return a.match(/^\#[a-f0-9]{3}(?:[a-f0-9]{3})?$/gi)?!0:a.toLowerCase()in CKEDITOR.tools.style.parse._colors}))}}},array:{filter:function(a,f,c){var b=[];this.forEach(a,function(h,d){f.call(c,h,d,a)&&b.push(h)});return b},
forEach:function(a,f,c){var b=a.length,h;for(h=0;h<b;h++)f.call(c,a[h],h,a)},map:function(a,f,c){for(var b=[],h=0;h<a.length;h++)b.push(f.call(c,a[h],h,a));return b},reduce:function(a,f,c,b){for(var h=0;h<a.length;h++)c=f.call(b,c,a[h],h,a);return c},every:function(a,f,c){if(!a.length)return!0;f=this.filter(a,f,c);return a.length===f.length}},object:{findKey:function(a,f){if("object"!==typeof a)return null;for(var c in a)if(a[c]===f)return c;return null},merge:function(a,f){var c=CKEDITOR.tools,b=
c.clone(a),h=c.clone(f);c.array.forEach(c.objectKeys(h),function(a){b[a]="object"===typeof h[a]&&"object"===typeof b[a]?c.object.merge(b[a],h[a]):h[a]});return b}}};CKEDITOR.tools.array.indexOf=CKEDITOR.tools.indexOf;CKEDITOR.tools.array.isArray=CKEDITOR.tools.isArray;CKEDITOR.MOUSE_BUTTON_LEFT=0;CKEDITOR.MOUSE_BUTTON_MIDDLE=1;CKEDITOR.MOUSE_BUTTON_RIGHT=2}(),CKEDITOR.dtd=function(){var a=CKEDITOR.tools.extend,e=function(a,f){for(var c=CKEDITOR.tools.clone(a),b=1;b<arguments.length;b++){f=arguments[b];
for(var h in f)delete c[h]}return c},b={},d={},g={address:1,article:1,aside:1,blockquote:1,details:1,div:1,dl:1,fieldset:1,figure:1,footer:1,form:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1,header:1,hgroup:1,hr:1,main:1,menu:1,nav:1,ol:1,p:1,pre:1,section:1,table:1,ul:1},l={command:1,link:1,meta:1,noscript:1,script:1,style:1},k={},h={"#":1},c={center:1,dir:1,noframes:1};a(b,{a:1,abbr:1,area:1,audio:1,b:1,bdi:1,bdo:1,br:1,button:1,canvas:1,cite:1,code:1,command:1,datalist:1,del:1,dfn:1,em:1,embed:1,i:1,iframe:1,
img:1,input:1,ins:1,kbd:1,keygen:1,label:1,map:1,mark:1,meter:1,noscript:1,object:1,output:1,progress:1,q:1,ruby:1,s:1,samp:1,script:1,select:1,small:1,span:1,strong:1,sub:1,sup:1,textarea:1,time:1,u:1,"var":1,video:1,wbr:1},h,{acronym:1,applet:1,basefont:1,big:1,font:1,isindex:1,strike:1,style:1,tt:1});a(d,g,b,c);e={a:e(b,{a:1,button:1}),abbr:b,address:d,area:k,article:d,aside:d,audio:a({source:1,track:1},d),b:b,base:k,bdi:b,bdo:b,blockquote:d,body:d,br:k,button:e(b,{a:1,button:1}),canvas:b,caption:d,
cite:b,code:b,col:k,colgroup:{col:1},command:k,datalist:a({option:1},b),dd:d,del:b,details:a({summary:1},d),dfn:b,div:d,dl:{dt:1,dd:1},dt:d,em:b,embed:k,fieldset:a({legend:1},d),figcaption:d,figure:a({figcaption:1},d),footer:d,form:d,h1:b,h2:b,h3:b,h4:b,h5:b,h6:b,head:a({title:1,base:1},l),header:d,hgroup:{h1:1,h2:1,h3:1,h4:1,h5:1,h6:1},hr:k,html:a({head:1,body:1},d,l),i:b,iframe:h,img:k,input:k,ins:b,kbd:b,keygen:k,label:b,legend:b,li:d,link:k,main:d,map:d,mark:b,menu:a({li:1},d),meta:k,meter:e(b,
{meter:1}),nav:d,noscript:a({link:1,meta:1,style:1},b),object:a({param:1},b),ol:{li:1},optgroup:{option:1},option:h,output:b,p:b,param:k,pre:b,progress:e(b,{progress:1}),q:b,rp:b,rt:b,ruby:a({rp:1,rt:1},b),s:b,samp:b,script:h,section:d,select:{optgroup:1,option:1},small:b,source:k,span:b,strong:b,style:h,sub:b,summary:a({h1:1,h2:1,h3:1,h4:1,h5:1,h6:1},b),sup:b,table:{caption:1,colgroup:1,thead:1,tfoot:1,tbody:1,tr:1},tbody:{tr:1},td:d,textarea:h,tfoot:{tr:1},th:d,thead:{tr:1},time:e(b,{time:1}),title:h,
tr:{th:1,td:1},track:k,u:b,ul:{li:1},"var":b,video:a({source:1,track:1},d),wbr:k,acronym:b,applet:a({param:1},d),basefont:k,big:b,center:d,dialog:k,dir:{li:1},font:b,isindex:k,noframes:d,strike:b,tt:b};a(e,{$block:a({audio:1,dd:1,dt:1,figcaption:1,li:1,video:1},g,c),$blockLimit:{article:1,aside:1,audio:1,body:1,caption:1,details:1,dir:1,div:1,dl:1,fieldset:1,figcaption:1,figure:1,footer:1,form:1,header:1,hgroup:1,main:1,menu:1,nav:1,ol:1,section:1,table:1,td:1,th:1,tr:1,ul:1,video:1},$cdata:{script:1,
style:1},$editable:{address:1,article:1,aside:1,blockquote:1,body:1,details:1,div:1,fieldset:1,figcaption:1,footer:1,form:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1,header:1,hgroup:1,main:1,nav:1,p:1,pre:1,section:1},$empty:{area:1,base:1,basefont:1,br:1,col:1,command:1,dialog:1,embed:1,hr:1,img:1,input:1,isindex:1,keygen:1,link:1,meta:1,param:1,source:1,track:1,wbr:1},$inline:b,$list:{dl:1,ol:1,ul:1},$listItem:{dd:1,dt:1,li:1},$nonBodyContent:a({body:1,head:1,html:1},e.head),$nonEditable:{applet:1,audio:1,
button:1,embed:1,iframe:1,map:1,object:1,option:1,param:1,script:1,textarea:1,video:1},$object:{applet:1,audio:1,button:1,hr:1,iframe:1,img:1,input:1,object:1,select:1,table:1,textarea:1,video:1},$removeEmpty:{abbr:1,acronym:1,b:1,bdi:1,bdo:1,big:1,cite:1,code:1,del:1,dfn:1,em:1,font:1,i:1,ins:1,label:1,kbd:1,mark:1,meter:1,output:1,q:1,ruby:1,s:1,samp:1,small:1,span:1,strike:1,strong:1,sub:1,sup:1,time:1,tt:1,u:1,"var":1},$tabIndex:{a:1,area:1,button:1,input:1,object:1,select:1,textarea:1},$tableContent:{caption:1,
col:1,colgroup:1,tbody:1,td:1,tfoot:1,th:1,thead:1,tr:1},$transparent:{a:1,audio:1,canvas:1,del:1,ins:1,map:1,noscript:1,object:1,video:1},$intermediate:{caption:1,colgroup:1,dd:1,dt:1,figcaption:1,legend:1,li:1,optgroup:1,option:1,rp:1,rt:1,summary:1,tbody:1,td:1,tfoot:1,th:1,thead:1,tr:1}});return e}(),CKEDITOR.dom.event=function(a){this.$=a},CKEDITOR.dom.event.prototype={getKey:function(){return this.$.keyCode||this.$.which},getKeystroke:function(){var a=this.getKey();if(this.$.ctrlKey||this.$.metaKey)a+=
CKEDITOR.CTRL;this.$.shiftKey&&(a+=CKEDITOR.SHIFT);this.$.altKey&&(a+=CKEDITOR.ALT);return a},preventDefault:function(a){var e=this.$;e.preventDefault?e.preventDefault():e.returnValue=!1;a&&this.stopPropagation()},stopPropagation:function(){var a=this.$;a.stopPropagation?a.stopPropagation():a.cancelBubble=!0},getTarget:function(){var a=this.$.target||this.$.srcElement;return a?new CKEDITOR.dom.node(a):null},getPhase:function(){return this.$.eventPhase||2},getPageOffset:function(){var a=this.getTarget().getDocument().$;
return{x:this.$.pageX||this.$.clientX+(a.documentElement.scrollLeft||a.body.scrollLeft),y:this.$.pageY||this.$.clientY+(a.documentElement.scrollTop||a.body.scrollTop)}}},CKEDITOR.CTRL=1114112,CKEDITOR.SHIFT=2228224,CKEDITOR.ALT=4456448,CKEDITOR.EVENT_PHASE_CAPTURING=1,CKEDITOR.EVENT_PHASE_AT_TARGET=2,CKEDITOR.EVENT_PHASE_BUBBLING=3,CKEDITOR.dom.domObject=function(a){a&&(this.$=a)},CKEDITOR.dom.domObject.prototype=function(){var a=function(a,b){return function(d){"undefined"!=typeof CKEDITOR&&a.fire(b,
new CKEDITOR.dom.event(d))}};return{getPrivate:function(){var a;(a=this.getCustomData("_"))||this.setCustomData("_",a={});return a},on:function(e){var b=this.getCustomData("_cke_nativeListeners");b||(b={},this.setCustomData("_cke_nativeListeners",b));b[e]||(b=b[e]=a(this,e),this.$.addEventListener?this.$.addEventListener(e,b,!!CKEDITOR.event.useCapture):this.$.attachEvent&&this.$.attachEvent("on"+e,b));return CKEDITOR.event.prototype.on.apply(this,arguments)},removeListener:function(a){CKEDITOR.event.prototype.removeListener.apply(this,
arguments);if(!this.hasListeners(a)){var b=this.getCustomData("_cke_nativeListeners"),d=b&&b[a];d&&(this.$.removeEventListener?this.$.removeEventListener(a,d,!1):this.$.detachEvent&&this.$.detachEvent("on"+a,d),delete b[a])}},removeAllListeners:function(){var a=this.getCustomData("_cke_nativeListeners"),b;for(b in a){var d=a[b];this.$.detachEvent?this.$.detachEvent("on"+b,d):this.$.removeEventListener&&this.$.removeEventListener(b,d,!1);delete a[b]}CKEDITOR.event.prototype.removeAllListeners.call(this)}}}(),
function(a){var e={};CKEDITOR.on("reset",function(){e={}});a.equals=function(a){try{return a&&a.$===this.$}catch(d){return!1}};a.setCustomData=function(a,d){var g=this.getUniqueId();(e[g]||(e[g]={}))[a]=d;return this};a.getCustomData=function(a){var d=this.$["data-cke-expando"];return(d=d&&e[d])&&a in d?d[a]:null};a.removeCustomData=function(a){var d=this.$["data-cke-expando"],d=d&&e[d],g,l;d&&(g=d[a],l=a in d,delete d[a]);return l?g:null};a.clearCustomData=function(){this.removeAllListeners();var a=
this.$["data-cke-expando"];a&&delete e[a]};a.getUniqueId=function(){return this.$["data-cke-expando"]||(this.$["data-cke-expando"]=CKEDITOR.tools.getNextNumber())};CKEDITOR.event.implementOn(a)}(CKEDITOR.dom.domObject.prototype),CKEDITOR.dom.node=function(a){return a?new CKEDITOR.dom[a.nodeType==CKEDITOR.NODE_DOCUMENT?"document":a.nodeType==CKEDITOR.NODE_ELEMENT?"element":a.nodeType==CKEDITOR.NODE_TEXT?"text":a.nodeType==CKEDITOR.NODE_COMMENT?"comment":a.nodeType==CKEDITOR.NODE_DOCUMENT_FRAGMENT?
"documentFragment":"domObject"](a):this},CKEDITOR.dom.node.prototype=new CKEDITOR.dom.domObject,CKEDITOR.NODE_ELEMENT=1,CKEDITOR.NODE_DOCUMENT=9,CKEDITOR.NODE_TEXT=3,CKEDITOR.NODE_COMMENT=8,CKEDITOR.NODE_DOCUMENT_FRAGMENT=11,CKEDITOR.POSITION_IDENTICAL=0,CKEDITOR.POSITION_DISCONNECTED=1,CKEDITOR.POSITION_FOLLOWING=2,CKEDITOR.POSITION_PRECEDING=4,CKEDITOR.POSITION_IS_CONTAINED=8,CKEDITOR.POSITION_CONTAINS=16,CKEDITOR.tools.extend(CKEDITOR.dom.node.prototype,{appendTo:function(a,e){a.append(this,e);
return a},clone:function(a,e){function b(d){d["data-cke-expando"]&&(d["data-cke-expando"]=!1);if(d.nodeType==CKEDITOR.NODE_ELEMENT||d.nodeType==CKEDITOR.NODE_DOCUMENT_FRAGMENT)if(e||d.nodeType!=CKEDITOR.NODE_ELEMENT||d.removeAttribute("id",!1),a){d=d.childNodes;for(var g=0;g<d.length;g++)b(d[g])}}function d(b){if(b.type==CKEDITOR.NODE_ELEMENT||b.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT){if(b.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT){var g=b.getName();":"==g[0]&&b.renameNode(g.substring(1))}if(a)for(g=0;g<
b.getChildCount();g++)d(b.getChild(g))}}var g=this.$.cloneNode(a);b(g);g=new CKEDITOR.dom.node(g);CKEDITOR.env.ie&&9>CKEDITOR.env.version&&(this.type==CKEDITOR.NODE_ELEMENT||this.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT)&&d(g);return g},hasPrevious:function(){return!!this.$.previousSibling},hasNext:function(){return!!this.$.nextSibling},insertAfter:function(a){a.$.parentNode.insertBefore(this.$,a.$.nextSibling);return a},insertBefore:function(a){a.$.parentNode.insertBefore(this.$,a.$);return a},insertBeforeMe:function(a){this.$.parentNode.insertBefore(a.$,
this.$);return a},getAddress:function(a){for(var e=[],b=this.getDocument().$.documentElement,d=this.$;d&&d!=b;){var g=d.parentNode;g&&e.unshift(this.getIndex.call({$:d},a));d=g}return e},getDocument:function(){return new CKEDITOR.dom.document(this.$.ownerDocument||this.$.parentNode.ownerDocument)},getIndex:function(a){function e(a,h){var c=h?a.nextSibling:a.previousSibling;return c&&c.nodeType==CKEDITOR.NODE_TEXT?b(c)?e(c,h):c:null}function b(a){return!a.nodeValue||a.nodeValue==CKEDITOR.dom.selection.FILLING_CHAR_SEQUENCE}
var d=this.$,g=-1,l;if(!this.$.parentNode||a&&d.nodeType==CKEDITOR.NODE_TEXT&&b(d)&&!e(d)&&!e(d,!0))return-1;do a&&d!=this.$&&d.nodeType==CKEDITOR.NODE_TEXT&&(l||b(d))||(g++,l=d.nodeType==CKEDITOR.NODE_TEXT);while(d=d.previousSibling);return g},getNextSourceNode:function(a,e,b){if(b&&!b.call){var d=b;b=function(a){return!a.equals(d)}}a=!a&&this.getFirst&&this.getFirst();var g;if(!a){if(this.type==CKEDITOR.NODE_ELEMENT&&b&&!1===b(this,!0))return null;a=this.getNext()}for(;!a&&(g=(g||this).getParent());){if(b&&
!1===b(g,!0))return null;a=g.getNext()}return!a||b&&!1===b(a)?null:e&&e!=a.type?a.getNextSourceNode(!1,e,b):a},getPreviousSourceNode:function(a,e,b){if(b&&!b.call){var d=b;b=function(a){return!a.equals(d)}}a=!a&&this.getLast&&this.getLast();var g;if(!a){if(this.type==CKEDITOR.NODE_ELEMENT&&b&&!1===b(this,!0))return null;a=this.getPrevious()}for(;!a&&(g=(g||this).getParent());){if(b&&!1===b(g,!0))return null;a=g.getPrevious()}return!a||b&&!1===b(a)?null:e&&a.type!=e?a.getPreviousSourceNode(!1,e,b):
a},getPrevious:function(a){var e=this.$,b;do b=(e=e.previousSibling)&&10!=e.nodeType&&new CKEDITOR.dom.node(e);while(b&&a&&!a(b));return b},getNext:function(a){var e=this.$,b;do b=(e=e.nextSibling)&&new CKEDITOR.dom.node(e);while(b&&a&&!a(b));return b},getParent:function(a){var e=this.$.parentNode;return e&&(e.nodeType==CKEDITOR.NODE_ELEMENT||a&&e.nodeType==CKEDITOR.NODE_DOCUMENT_FRAGMENT)?new CKEDITOR.dom.node(e):null},getParents:function(a){var e=this,b=[];do b[a?"push":"unshift"](e);while(e=e.getParent());
return b},getCommonAncestor:function(a){if(a.equals(this))return this;if(a.contains&&a.contains(this))return a;var e=this.contains?this:this.getParent();do if(e.contains(a))return e;while(e=e.getParent());return null},getPosition:function(a){var e=this.$,b=a.$;if(e.compareDocumentPosition)return e.compareDocumentPosition(b);if(e==b)return CKEDITOR.POSITION_IDENTICAL;if(this.type==CKEDITOR.NODE_ELEMENT&&a.type==CKEDITOR.NODE_ELEMENT){if(e.contains){if(e.contains(b))return CKEDITOR.POSITION_CONTAINS+
CKEDITOR.POSITION_PRECEDING;if(b.contains(e))return CKEDITOR.POSITION_IS_CONTAINED+CKEDITOR.POSITION_FOLLOWING}if("sourceIndex"in e)return 0>e.sourceIndex||0>b.sourceIndex?CKEDITOR.POSITION_DISCONNECTED:e.sourceIndex<b.sourceIndex?CKEDITOR.POSITION_PRECEDING:CKEDITOR.POSITION_FOLLOWING}e=this.getAddress();a=a.getAddress();for(var b=Math.min(e.length,a.length),d=0;d<b;d++)if(e[d]!=a[d])return e[d]<a[d]?CKEDITOR.POSITION_PRECEDING:CKEDITOR.POSITION_FOLLOWING;return e.length<a.length?CKEDITOR.POSITION_CONTAINS+
CKEDITOR.POSITION_PRECEDING:CKEDITOR.POSITION_IS_CONTAINED+CKEDITOR.POSITION_FOLLOWING},getAscendant:function(a,e){var b=this.$,d,g;e||(b=b.parentNode);"function"==typeof a?(g=!0,d=a):(g=!1,d=function(b){b="string"==typeof b.nodeName?b.nodeName.toLowerCase():"";return"string"==typeof a?b==a:b in a});for(;b;){if(d(g?new CKEDITOR.dom.node(b):b))return new CKEDITOR.dom.node(b);try{b=b.parentNode}catch(l){b=null}}return null},hasAscendant:function(a,e){var b=this.$;e||(b=b.parentNode);for(;b;){if(b.nodeName&&
b.nodeName.toLowerCase()==a)return!0;b=b.parentNode}return!1},move:function(a,e){a.append(this.remove(),e)},remove:function(a){var e=this.$,b=e.parentNode;if(b){if(a)for(;a=e.firstChild;)b.insertBefore(e.removeChild(a),e);b.removeChild(e)}return this},replace:function(a){this.insertBefore(a);a.remove()},trim:function(){this.ltrim();this.rtrim()},ltrim:function(){for(var a;this.getFirst&&(a=this.getFirst());){if(a.type==CKEDITOR.NODE_TEXT){var e=CKEDITOR.tools.ltrim(a.getText()),b=a.getLength();if(e)e.length<
b&&(a.split(b-e.length),this.$.removeChild(this.$.firstChild));else{a.remove();continue}}break}},rtrim:function(){for(var a;this.getLast&&(a=this.getLast());){if(a.type==CKEDITOR.NODE_TEXT){var e=CKEDITOR.tools.rtrim(a.getText()),b=a.getLength();if(e)e.length<b&&(a.split(e.length),this.$.lastChild.parentNode.removeChild(this.$.lastChild));else{a.remove();continue}}break}CKEDITOR.env.needsBrFiller&&(a=this.$.lastChild)&&1==a.type&&"br"==a.nodeName.toLowerCase()&&a.parentNode.removeChild(a)},isReadOnly:function(a){var e=
this;this.type!=CKEDITOR.NODE_ELEMENT&&(e=this.getParent());CKEDITOR.env.edge&&e&&e.is("textarea","input")&&(a=!0);if(!a&&e&&"undefined"!=typeof e.$.isContentEditable)return!(e.$.isContentEditable||e.data("cke-editable"));for(;e;){if(e.data("cke-editable"))return!1;if(e.hasAttribute("contenteditable"))return"false"==e.getAttribute("contenteditable");e=e.getParent()}return!0}}),CKEDITOR.dom.window=function(a){CKEDITOR.dom.domObject.call(this,a)},CKEDITOR.dom.window.prototype=new CKEDITOR.dom.domObject,
CKEDITOR.tools.extend(CKEDITOR.dom.window.prototype,{focus:function(){this.$.focus()},getViewPaneSize:function(){var a=this.$.document,e="CSS1Compat"==a.compatMode;return{width:(e?a.documentElement.clientWidth:a.body.clientWidth)||0,height:(e?a.documentElement.clientHeight:a.body.clientHeight)||0}},getScrollPosition:function(){var a=this.$;if("pageXOffset"in a)return{x:a.pageXOffset||0,y:a.pageYOffset||0};a=a.document;return{x:a.documentElement.scrollLeft||a.body.scrollLeft||0,y:a.documentElement.scrollTop||
a.body.scrollTop||0}},getFrame:function(){var a=this.$.frameElement;return a?new CKEDITOR.dom.element.get(a):null}}),CKEDITOR.dom.document=function(a){CKEDITOR.dom.domObject.call(this,a)},CKEDITOR.dom.document.prototype=new CKEDITOR.dom.domObject,CKEDITOR.tools.extend(CKEDITOR.dom.document.prototype,{type:CKEDITOR.NODE_DOCUMENT,appendStyleSheet:function(a){if(this.$.createStyleSheet)this.$.createStyleSheet(a);else{var e=new CKEDITOR.dom.element("link");e.setAttributes({rel:"stylesheet",type:"text/css",
href:a});this.getHead().append(e)}},appendStyleText:function(a){if(this.$.createStyleSheet){var e=this.$.createStyleSheet("");e.cssText=a}else{var b=new CKEDITOR.dom.element("style",this);b.append(new CKEDITOR.dom.text(a,this));this.getHead().append(b)}return e||b.$.sheet},createElement:function(a,e){var b=new CKEDITOR.dom.element(a,this);e&&(e.attributes&&b.setAttributes(e.attributes),e.styles&&b.setStyles(e.styles));return b},createText:function(a){return new CKEDITOR.dom.text(a,this)},focus:function(){this.getWindow().focus()},
getActive:function(){var a;try{a=this.$.activeElement}catch(e){return null}return new CKEDITOR.dom.element(a)},getById:function(a){return(a=this.$.getElementById(a))?new CKEDITOR.dom.element(a):null},getByAddress:function(a,e){for(var b=this.$.documentElement,d=0;b&&d<a.length;d++){var g=a[d];if(e)for(var l=-1,k=0;k<b.childNodes.length;k++){var h=b.childNodes[k];if(!0!==e||3!=h.nodeType||!h.previousSibling||3!=h.previousSibling.nodeType)if(l++,l==g){b=h;break}}else b=b.childNodes[g]}return b?new CKEDITOR.dom.node(b):
null},getElementsByTag:function(a,e){CKEDITOR.env.ie&&8>=document.documentMode||!e||(a=e+":"+a);return new CKEDITOR.dom.nodeList(this.$.getElementsByTagName(a))},getHead:function(){var a=this.$.getElementsByTagName("head")[0];return a=a?new CKEDITOR.dom.element(a):this.getDocumentElement().append(new CKEDITOR.dom.element("head"),!0)},getBody:function(){return new CKEDITOR.dom.element(this.$.body)},getDocumentElement:function(){return new CKEDITOR.dom.element(this.$.documentElement)},getWindow:function(){return new CKEDITOR.dom.window(this.$.parentWindow||
this.$.defaultView)},write:function(a){this.$.open("text/html","replace");CKEDITOR.env.ie&&(a=a.replace(/(?:^\s*<!DOCTYPE[^>]*?>)|^/i,'$\x26\n\x3cscript data-cke-temp\x3d"1"\x3e('+CKEDITOR.tools.fixDomain+")();\x3c/script\x3e"));this.$.write(a);this.$.close()},find:function(a){return new CKEDITOR.dom.nodeList(this.$.querySelectorAll(a))},findOne:function(a){return(a=this.$.querySelector(a))?new CKEDITOR.dom.element(a):null},_getHtml5ShivFrag:function(){var a=this.getCustomData("html5ShivFrag");a||
(a=this.$.createDocumentFragment(),CKEDITOR.tools.enableHtml5Elements(a,!0),this.setCustomData("html5ShivFrag",a));return a}}),CKEDITOR.dom.nodeList=function(a){this.$=a},CKEDITOR.dom.nodeList.prototype={count:function(){return this.$.length},getItem:function(a){return 0>a||a>=this.$.length?null:(a=this.$[a])?new CKEDITOR.dom.node(a):null},toArray:function(){return CKEDITOR.tools.array.map(this.$,function(a){return new CKEDITOR.dom.node(a)})}},CKEDITOR.dom.element=function(a,e){"string"==typeof a&&
(a=(e?e.$:document).createElement(a));CKEDITOR.dom.domObject.call(this,a)},CKEDITOR.dom.element.get=function(a){return(a="string"==typeof a?document.getElementById(a)||document.getElementsByName(a)[0]:a)&&(a.$?a:new CKEDITOR.dom.element(a))},CKEDITOR.dom.element.prototype=new CKEDITOR.dom.node,CKEDITOR.dom.element.createFromHtml=function(a,e){var b=new CKEDITOR.dom.element("div",e);b.setHtml(a);return b.getFirst().remove()},CKEDITOR.dom.element.setMarker=function(a,e,b,d){var g=e.getCustomData("list_marker_id")||
e.setCustomData("list_marker_id",CKEDITOR.tools.getNextNumber()).getCustomData("list_marker_id"),l=e.getCustomData("list_marker_names")||e.setCustomData("list_marker_names",{}).getCustomData("list_marker_names");a[g]=e;l[b]=1;return e.setCustomData(b,d)},CKEDITOR.dom.element.clearAllMarkers=function(a){for(var e in a)CKEDITOR.dom.element.clearMarkers(a,a[e],1)},CKEDITOR.dom.element.clearMarkers=function(a,e,b){var d=e.getCustomData("list_marker_names"),g=e.getCustomData("list_marker_id"),l;for(l in d)e.removeCustomData(l);
e.removeCustomData("list_marker_names");b&&(e.removeCustomData("list_marker_id"),delete a[g])},function(){function a(a,c){return-1<(" "+a+" ").replace(l," ").indexOf(" "+c+" ")}function e(a){var c=!0;a.$.id||(a.$.id="cke_tmp_"+CKEDITOR.tools.getNextNumber(),c=!1);return function(){c||a.removeAttribute("id")}}function b(a,c){var b=CKEDITOR.tools.escapeCss(a.$.id);return"#"+b+" "+c.split(/,\s*/).join(", #"+b+" ")}function d(a){for(var c=0,b=0,f=k[a].length;b<f;b++)c+=parseFloat(this.getComputedStyle(k[a][b])||
0,10)||0;return c}var g=document.createElement("_").classList,g="undefined"!==typeof g&&null!==String(g.add).match(/\[Native code\]/gi),l=/[\n\t\r]/g;CKEDITOR.tools.extend(CKEDITOR.dom.element.prototype,{type:CKEDITOR.NODE_ELEMENT,addClass:g?function(a){this.$.classList.add(a);return this}:function(b){var c=this.$.className;c&&(a(c,b)||(c+=" "+b));this.$.className=c||b;return this},removeClass:g?function(a){var c=this.$;c.classList.remove(a);c.className||c.removeAttribute("class");return this}:function(b){var c=
this.getAttribute("class");c&&a(c,b)&&((c=c.replace(new RegExp("(?:^|\\s+)"+b+"(?\x3d\\s|$)"),"").replace(/^\s+/,""))?this.setAttribute("class",c):this.removeAttribute("class"));return this},hasClass:function(b){return a(this.$.className,b)},append:function(a,c){"string"==typeof a&&(a=this.getDocument().createElement(a));c?this.$.insertBefore(a.$,this.$.firstChild):this.$.appendChild(a.$);return a},appendHtml:function(a){if(this.$.childNodes.length){var c=new CKEDITOR.dom.element("div",this.getDocument());
c.setHtml(a);c.moveChildren(this)}else this.setHtml(a)},appendText:function(a){null!=this.$.text&&CKEDITOR.env.ie&&9>CKEDITOR.env.version?this.$.text+=a:this.append(new CKEDITOR.dom.text(a))},appendBogus:function(a){if(a||CKEDITOR.env.needsBrFiller){for(a=this.getLast();a&&a.type==CKEDITOR.NODE_TEXT&&!CKEDITOR.tools.rtrim(a.getText());)a=a.getPrevious();a&&a.is&&a.is("br")||(a=this.getDocument().createElement("br"),CKEDITOR.env.gecko&&a.setAttribute("type","_moz"),this.append(a))}},breakParent:function(a,
c){var b=new CKEDITOR.dom.range(this.getDocument());b.setStartAfter(this);b.setEndAfter(a);var f=b.extractContents(!1,c||!1),d;b.insertNode(this.remove());if(CKEDITOR.env.ie&&!CKEDITOR.env.edge){for(b=new CKEDITOR.dom.element("div");d=f.getFirst();)d.$.style.backgroundColor&&(d.$.style.backgroundColor=d.$.style.backgroundColor),b.append(d);b.insertAfter(this);b.remove(!0)}else f.insertAfterNode(this)},contains:document.compareDocumentPosition?function(a){return!!(this.$.compareDocumentPosition(a.$)&
16)}:function(a){var c=this.$;return a.type!=CKEDITOR.NODE_ELEMENT?c.contains(a.getParent().$):c!=a.$&&c.contains(a.$)},focus:function(){function a(){try{this.$.focus()}catch(c){}}return function(c){c?CKEDITOR.tools.setTimeout(a,100,this):a.call(this)}}(),getHtml:function(){var a=this.$.innerHTML;return CKEDITOR.env.ie?a.replace(/<\?[^>]*>/g,""):a},getOuterHtml:function(){if(this.$.outerHTML)return this.$.outerHTML.replace(/<\?[^>]*>/,"");var a=this.$.ownerDocument.createElement("div");a.appendChild(this.$.cloneNode(!0));
return a.innerHTML},getClientRect:function(){var a=CKEDITOR.tools.extend({},this.$.getBoundingClientRect());!a.width&&(a.width=a.right-a.left);!a.height&&(a.height=a.bottom-a.top);return a},setHtml:CKEDITOR.env.ie&&9>CKEDITOR.env.version?function(a){try{var c=this.$;if(this.getParent())return c.innerHTML=a;var b=this.getDocument()._getHtml5ShivFrag();b.appendChild(c);c.innerHTML=a;b.removeChild(c);return a}catch(f){this.$.innerHTML="";c=new CKEDITOR.dom.element("body",this.getDocument());c.$.innerHTML=
a;for(c=c.getChildren();c.count();)this.append(c.getItem(0));return a}}:function(a){return this.$.innerHTML=a},setText:function(){var a=document.createElement("p");a.innerHTML="x";a=a.textContent;return function(c){this.$[a?"textContent":"innerText"]=c}}(),getAttribute:function(){var a=function(a){return this.$.getAttribute(a,2)};return CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)?function(a){switch(a){case "class":a="className";break;case "http-equiv":a="httpEquiv";break;case "name":return this.$.name;
case "tabindex":return a=this.$.getAttribute(a,2),0!==a&&0===this.$.tabIndex&&(a=null),a;case "checked":return a=this.$.attributes.getNamedItem(a),(a.specified?a.nodeValue:this.$.checked)?"checked":null;case "hspace":case "value":return this.$[a];case "style":return this.$.style.cssText;case "contenteditable":case "contentEditable":return this.$.attributes.getNamedItem("contentEditable").specified?this.$.getAttribute("contentEditable"):null}return this.$.getAttribute(a,2)}:a}(),getAttributes:function(a){var c=
{},b=this.$.attributes,f;a=CKEDITOR.tools.isArray(a)?a:[];for(f=0;f<b.length;f++)-1===CKEDITOR.tools.indexOf(a,b[f].name)&&(c[b[f].name]=b[f].value);return c},getChildren:function(){return new CKEDITOR.dom.nodeList(this.$.childNodes)},getComputedStyle:document.defaultView&&document.defaultView.getComputedStyle?function(a){var c=this.getWindow().$.getComputedStyle(this.$,null);return c?c.getPropertyValue(a):""}:function(a){return this.$.currentStyle[CKEDITOR.tools.cssStyleToDomStyle(a)]},getDtd:function(){var a=
CKEDITOR.dtd[this.getName()];this.getDtd=function(){return a};return a},getElementsByTag:CKEDITOR.dom.document.prototype.getElementsByTag,getTabIndex:function(){var a=this.$.tabIndex;return 0!==a||CKEDITOR.dtd.$tabIndex[this.getName()]||0===parseInt(this.getAttribute("tabindex"),10)?a:-1},getText:function(){return this.$.textContent||this.$.innerText||""},getWindow:function(){return this.getDocument().getWindow()},getId:function(){return this.$.id||null},getNameAtt:function(){return this.$.name||
null},getName:function(){var a=this.$.nodeName.toLowerCase();if(CKEDITOR.env.ie&&8>=document.documentMode){var c=this.$.scopeName;"HTML"!=c&&(a=c.toLowerCase()+":"+a)}this.getName=function(){return a};return this.getName()},getValue:function(){return this.$.value},getFirst:function(a){var c=this.$.firstChild;(c=c&&new CKEDITOR.dom.node(c))&&a&&!a(c)&&(c=c.getNext(a));return c},getLast:function(a){var c=this.$.lastChild;(c=c&&new CKEDITOR.dom.node(c))&&a&&!a(c)&&(c=c.getPrevious(a));return c},getStyle:function(a){return this.$.style[CKEDITOR.tools.cssStyleToDomStyle(a)]},
is:function(){var a=this.getName();if("object"==typeof arguments[0])return!!arguments[0][a];for(var c=0;c<arguments.length;c++)if(arguments[c]==a)return!0;return!1},isEditable:function(a){var c=this.getName();return this.isReadOnly()||"none"==this.getComputedStyle("display")||"hidden"==this.getComputedStyle("visibility")||CKEDITOR.dtd.$nonEditable[c]||CKEDITOR.dtd.$empty[c]||this.is("a")&&(this.data("cke-saved-name")||this.hasAttribute("name"))&&!this.getChildCount()?!1:!1!==a?(a=CKEDITOR.dtd[c]||
CKEDITOR.dtd.span,!(!a||!a["#"])):!0},isIdentical:function(a){var c=this.clone(0,1);a=a.clone(0,1);c.removeAttributes(["_moz_dirty","data-cke-expando","data-cke-saved-href","data-cke-saved-name"]);a.removeAttributes(["_moz_dirty","data-cke-expando","data-cke-saved-href","data-cke-saved-name"]);if(c.$.isEqualNode)return c.$.style.cssText=CKEDITOR.tools.normalizeCssText(c.$.style.cssText),a.$.style.cssText=CKEDITOR.tools.normalizeCssText(a.$.style.cssText),c.$.isEqualNode(a.$);c=c.getOuterHtml();a=
a.getOuterHtml();if(CKEDITOR.env.ie&&9>CKEDITOR.env.version&&this.is("a")){var b=this.getParent();b.type==CKEDITOR.NODE_ELEMENT&&(b=b.clone(),b.setHtml(c),c=b.getHtml(),b.setHtml(a),a=b.getHtml())}return c==a},isVisible:function(){var a=(this.$.offsetHeight||this.$.offsetWidth)&&"hidden"!=this.getComputedStyle("visibility"),c,b;a&&CKEDITOR.env.webkit&&(c=this.getWindow(),!c.equals(CKEDITOR.document.getWindow())&&(b=c.$.frameElement)&&(a=(new CKEDITOR.dom.element(b)).isVisible()));return!!a},isEmptyInlineRemoveable:function(){if(!CKEDITOR.dtd.$removeEmpty[this.getName()])return!1;
for(var a=this.getChildren(),c=0,b=a.count();c<b;c++){var f=a.getItem(c);if(f.type!=CKEDITOR.NODE_ELEMENT||!f.data("cke-bookmark"))if(f.type==CKEDITOR.NODE_ELEMENT&&!f.isEmptyInlineRemoveable()||f.type==CKEDITOR.NODE_TEXT&&CKEDITOR.tools.trim(f.getText()))return!1}return!0},hasAttributes:CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)?function(){for(var a=this.$.attributes,c=0;c<a.length;c++){var b=a[c];switch(b.nodeName){case "class":if(this.getAttribute("class"))return!0;case "data-cke-expando":continue;
default:if(b.specified)return!0}}return!1}:function(){var a=this.$.attributes,c=a.length,b={"data-cke-expando":1,_moz_dirty:1};return 0<c&&(2<c||!b[a[0].nodeName]||2==c&&!b[a[1].nodeName])},hasAttribute:function(){function a(c){var b=this.$.attributes.getNamedItem(c);if("input"==this.getName())switch(c){case "class":return 0<this.$.className.length;case "checked":return!!this.$.checked;case "value":return c=this.getAttribute("type"),"checkbox"==c||"radio"==c?"on"!=this.$.value:!!this.$.value}return b?
b.specified:!1}return CKEDITOR.env.ie?8>CKEDITOR.env.version?function(c){return"name"==c?!!this.$.name:a.call(this,c)}:a:function(a){return!!this.$.attributes.getNamedItem(a)}}(),hide:function(){this.setStyle("display","none")},moveChildren:function(a,c){var b=this.$;a=a.$;if(b!=a){var f;if(c)for(;f=b.lastChild;)a.insertBefore(b.removeChild(f),a.firstChild);else for(;f=b.firstChild;)a.appendChild(b.removeChild(f))}},mergeSiblings:function(){function a(c,b,f){if(b&&b.type==CKEDITOR.NODE_ELEMENT){for(var d=
[];b.data("cke-bookmark")||b.isEmptyInlineRemoveable();)if(d.push(b),b=f?b.getNext():b.getPrevious(),!b||b.type!=CKEDITOR.NODE_ELEMENT)return;if(c.isIdentical(b)){for(var h=f?c.getLast():c.getFirst();d.length;)d.shift().move(c,!f);b.moveChildren(c,!f);b.remove();h&&h.type==CKEDITOR.NODE_ELEMENT&&h.mergeSiblings()}}}return function(b){if(!1===b||CKEDITOR.dtd.$removeEmpty[this.getName()]||this.is("a"))a(this,this.getNext(),!0),a(this,this.getPrevious())}}(),show:function(){this.setStyles({display:"",
visibility:""})},setAttribute:function(){var a=function(a,b){this.$.setAttribute(a,b);return this};return CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)?function(b,d){"class"==b?this.$.className=d:"style"==b?this.$.style.cssText=d:"tabindex"==b?this.$.tabIndex=d:"checked"==b?this.$.checked=d:"contenteditable"==b?a.call(this,"contentEditable",d):a.apply(this,arguments);return this}:CKEDITOR.env.ie8Compat&&CKEDITOR.env.secure?function(b,d){if("src"==b&&d.match(/^http:\/\//))try{a.apply(this,
arguments)}catch(f){}else a.apply(this,arguments);return this}:a}(),setAttributes:function(a){for(var b in a)this.setAttribute(b,a[b]);return this},setValue:function(a){this.$.value=a;return this},removeAttribute:function(){var a=function(a){this.$.removeAttribute(a)};return CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)?function(a){"class"==a?a="className":"tabindex"==a?a="tabIndex":"contenteditable"==a&&(a="contentEditable");this.$.removeAttribute(a)}:a}(),removeAttributes:function(a){if(CKEDITOR.tools.isArray(a))for(var b=
0;b<a.length;b++)this.removeAttribute(a[b]);else for(b in a=a||this.getAttributes(),a)a.hasOwnProperty(b)&&this.removeAttribute(b)},removeStyle:function(a){var b=this.$.style;if(b.removeProperty||"border"!=a&&"margin"!=a&&"padding"!=a)b.removeProperty?b.removeProperty(a):b.removeAttribute(CKEDITOR.tools.cssStyleToDomStyle(a)),this.$.style.cssText||this.removeAttribute("style");else{var d=["top","left","right","bottom"],f;"border"==a&&(f=["color","style","width"]);for(var b=[],g=0;g<d.length;g++)if(f)for(var e=
0;e<f.length;e++)b.push([a,d[g],f[e]].join("-"));else b.push([a,d[g]].join("-"));for(a=0;a<b.length;a++)this.removeStyle(b[a])}},setStyle:function(a,b){this.$.style[CKEDITOR.tools.cssStyleToDomStyle(a)]=b;return this},setStyles:function(a){for(var b in a)this.setStyle(b,a[b]);return this},setOpacity:function(a){CKEDITOR.env.ie&&9>CKEDITOR.env.version?(a=Math.round(100*a),this.setStyle("filter",100<=a?"":"progid:DXImageTransform.Microsoft.Alpha(opacity\x3d"+a+")")):this.setStyle("opacity",a)},unselectable:function(){this.setStyles(CKEDITOR.tools.cssVendorPrefix("user-select",
"none"));if(CKEDITOR.env.ie){this.setAttribute("unselectable","on");for(var a,b=this.getElementsByTag("*"),d=0,f=b.count();d<f;d++)a=b.getItem(d),a.setAttribute("unselectable","on")}},getPositionedAncestor:function(){for(var a=this;"html"!=a.getName();){if("static"!=a.getComputedStyle("position"))return a;a=a.getParent()}return null},getDocumentPosition:function(a){var b=0,d=0,f=this.getDocument(),g=f.getBody(),e="BackCompat"==f.$.compatMode;if(document.documentElement.getBoundingClientRect&&(CKEDITOR.env.ie?
8!==CKEDITOR.env.version:1)){var l=this.$.getBoundingClientRect(),k=f.$.documentElement,y=k.clientTop||g.$.clientTop||0,r=k.clientLeft||g.$.clientLeft||0,t=!0;CKEDITOR.env.ie&&(t=f.getDocumentElement().contains(this),f=f.getBody().contains(this),t=e&&f||!e&&t);t&&(CKEDITOR.env.webkit||CKEDITOR.env.ie&&12<=CKEDITOR.env.version?(b=g.$.scrollLeft||k.scrollLeft,d=g.$.scrollTop||k.scrollTop):(d=e?g.$:k,b=d.scrollLeft,d=d.scrollTop),b=l.left+b-r,d=l.top+d-y)}else for(y=this,r=null;y&&"body"!=y.getName()&&
"html"!=y.getName();){b+=y.$.offsetLeft-y.$.scrollLeft;d+=y.$.offsetTop-y.$.scrollTop;y.equals(this)||(b+=y.$.clientLeft||0,d+=y.$.clientTop||0);for(;r&&!r.equals(y);)b-=r.$.scrollLeft,d-=r.$.scrollTop,r=r.getParent();r=y;y=(l=y.$.offsetParent)?new CKEDITOR.dom.element(l):null}a&&(l=this.getWindow(),y=a.getWindow(),!l.equals(y)&&l.$.frameElement&&(a=(new CKEDITOR.dom.element(l.$.frameElement)).getDocumentPosition(a),b+=a.x,d+=a.y));document.documentElement.getBoundingClientRect||!CKEDITOR.env.gecko||
e||(b+=this.$.clientLeft?1:0,d+=this.$.clientTop?1:0);return{x:b,y:d}},scrollIntoView:function(a){var b=this.getParent();if(b){do if((b.$.clientWidth&&b.$.clientWidth<b.$.scrollWidth||b.$.clientHeight&&b.$.clientHeight<b.$.scrollHeight)&&!b.is("body")&&this.scrollIntoParent(b,a,1),b.is("html")){var d=b.getWindow();try{var f=d.$.frameElement;f&&(b=new CKEDITOR.dom.element(f))}catch(g){}}while(b=b.getParent())}},scrollIntoParent:function(a,b,d){var f,g,e,l;function k(f,b){/body|html/.test(a.getName())?
a.getWindow().$.scrollBy(f,b):(a.$.scrollLeft+=f,a.$.scrollTop+=b)}function y(a,f){var b={x:0,y:0};if(!a.is(t?"body":"html")){var c=a.$.getBoundingClientRect();b.x=c.left;b.y=c.top}c=a.getWindow();c.equals(f)||(c=y(CKEDITOR.dom.element.get(c.$.frameElement),f),b.x+=c.x,b.y+=c.y);return b}function r(a,f){return parseInt(a.getComputedStyle("margin-"+f)||0,10)||0}!a&&(a=this.getWindow());e=a.getDocument();var t="BackCompat"==e.$.compatMode;a instanceof CKEDITOR.dom.window&&(a=t?e.getBody():e.getDocumentElement());
CKEDITOR.env.webkit&&(e=this.getEditor(!1))&&(e._.previousScrollTop=null);e=a.getWindow();g=y(this,e);var w=y(a,e),A=this.$.offsetHeight;f=this.$.offsetWidth;var x=a.$.clientHeight,u=a.$.clientWidth;e=g.x-r(this,"left")-w.x||0;l=g.y-r(this,"top")-w.y||0;f=g.x+f+r(this,"right")-(w.x+u)||0;g=g.y+A+r(this,"bottom")-(w.y+x)||0;(0>l||0<g)&&k(0,!0===b?l:!1===b?g:0>l?l:g);d&&(0>e||0<f)&&k(0>e?e:f,0)},setState:function(a,b,d){b=b||"cke";switch(a){case CKEDITOR.TRISTATE_ON:this.addClass(b+"_on");this.removeClass(b+
"_off");this.removeClass(b+"_disabled");d&&this.setAttribute("aria-pressed",!0);d&&this.removeAttribute("aria-disabled");break;case CKEDITOR.TRISTATE_DISABLED:this.addClass(b+"_disabled");this.removeClass(b+"_off");this.removeClass(b+"_on");d&&this.setAttribute("aria-disabled",!0);d&&this.removeAttribute("aria-pressed");break;default:this.addClass(b+"_off"),this.removeClass(b+"_on"),this.removeClass(b+"_disabled"),d&&this.removeAttribute("aria-pressed"),d&&this.removeAttribute("aria-disabled")}},
getFrameDocument:function(){var a=this.$;try{a.contentWindow.document}catch(b){a.src=a.src}return a&&new CKEDITOR.dom.document(a.contentWindow.document)},copyAttributes:function(a,b){var d=this.$.attributes;b=b||{};for(var f=0;f<d.length;f++){var g=d[f],e=g.nodeName.toLowerCase(),l;if(!(e in b))if("checked"==e&&(l=this.getAttribute(e)))a.setAttribute(e,l);else if(!CKEDITOR.env.ie||this.hasAttribute(e))l=this.getAttribute(e),null===l&&(l=g.nodeValue),a.setAttribute(e,l)}""!==this.$.style.cssText&&
(a.$.style.cssText=this.$.style.cssText)},renameNode:function(a){if(this.getName()!=a){var b=this.getDocument();a=new CKEDITOR.dom.element(a,b);this.copyAttributes(a);this.moveChildren(a);this.getParent(!0)&&this.$.parentNode.replaceChild(a.$,this.$);a.$["data-cke-expando"]=this.$["data-cke-expando"];this.$=a.$;delete this.getName}},getChild:function(){function a(b,d){var f=b.childNodes;if(0<=d&&d<f.length)return f[d]}return function(b){var d=this.$;if(b.slice)for(b=b.slice();0<b.length&&d;)d=a(d,
b.shift());else d=a(d,b);return d?new CKEDITOR.dom.node(d):null}}(),getChildCount:function(){return this.$.childNodes.length},disableContextMenu:function(){function a(b){return b.type==CKEDITOR.NODE_ELEMENT&&b.hasClass("cke_enable_context_menu")}this.on("contextmenu",function(b){b.data.getTarget().getAscendant(a,!0)||b.data.preventDefault()})},getDirection:function(a){return a?this.getComputedStyle("direction")||this.getDirection()||this.getParent()&&this.getParent().getDirection(1)||this.getDocument().$.dir||
"ltr":this.getStyle("direction")||this.getAttribute("dir")},data:function(a,b){a="data-"+a;if(void 0===b)return this.getAttribute(a);!1===b?this.removeAttribute(a):this.setAttribute(a,b);return null},getEditor:function(a){var b=CKEDITOR.instances,d,f,g;a=a||void 0===a;for(d in b)if(f=b[d],f.element.equals(this)&&f.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO||!a&&(g=f.editable())&&(g.equals(this)||g.contains(this)))return f;return null},find:function(a){var c=e(this);a=new CKEDITOR.dom.nodeList(this.$.querySelectorAll(b(this,
a)));c();return a},findOne:function(a){var c=e(this);a=this.$.querySelector(b(this,a));c();return a?new CKEDITOR.dom.element(a):null},forEach:function(a,b,d){if(!(d||b&&this.type!=b))var f=a(this);if(!1!==f){d=this.getChildren();for(var g=0;g<d.count();g++)f=d.getItem(g),f.type==CKEDITOR.NODE_ELEMENT?f.forEach(a,b):b&&f.type!=b||a(f)}}});var k={width:["border-left-width","border-right-width","padding-left","padding-right"],height:["border-top-width","border-bottom-width","padding-top","padding-bottom"]};
CKEDITOR.dom.element.prototype.setSize=function(a,b,g){"number"==typeof b&&(!g||CKEDITOR.env.ie&&CKEDITOR.env.quirks||(b-=d.call(this,a)),this.setStyle(a,b+"px"))};CKEDITOR.dom.element.prototype.getSize=function(a,b){var g=Math.max(this.$["offset"+CKEDITOR.tools.capitalize(a)],this.$["client"+CKEDITOR.tools.capitalize(a)])||0;b&&(g-=d.call(this,a));return g}}(),CKEDITOR.dom.documentFragment=function(a){a=a||CKEDITOR.document;this.$=a.type==CKEDITOR.NODE_DOCUMENT?a.$.createDocumentFragment():a},CKEDITOR.tools.extend(CKEDITOR.dom.documentFragment.prototype,
CKEDITOR.dom.element.prototype,{type:CKEDITOR.NODE_DOCUMENT_FRAGMENT,insertAfterNode:function(a){a=a.$;a.parentNode.insertBefore(this.$,a.nextSibling)},getHtml:function(){var a=new CKEDITOR.dom.element("div");this.clone(1,1).appendTo(a);return a.getHtml().replace(/\s*data-cke-expando=".*?"/g,"")}},!0,{append:1,appendBogus:1,clone:1,getFirst:1,getHtml:1,getLast:1,getParent:1,getNext:1,getPrevious:1,appendTo:1,moveChildren:1,insertBefore:1,insertAfterNode:1,replace:1,trim:1,type:1,ltrim:1,rtrim:1,getDocument:1,
getChildCount:1,getChild:1,getChildren:1}),function(){function a(a,f){var b=this.range;if(this._.end)return null;if(!this._.start){this._.start=1;if(b.collapsed)return this.end(),null;b.optimize()}var c,d=b.startContainer;c=b.endContainer;var g=b.startOffset,h=b.endOffset,e,m=this.guard,n=this.type,l=a?"getPreviousSourceNode":"getNextSourceNode";if(!a&&!this._.guardLTR){var k=c.type==CKEDITOR.NODE_ELEMENT?c:c.getParent(),B=c.type==CKEDITOR.NODE_ELEMENT?c.getChild(h):c.getNext();this._.guardLTR=function(a,
f){return(!f||!k.equals(a))&&(!B||!a.equals(B))&&(a.type!=CKEDITOR.NODE_ELEMENT||!f||!a.equals(b.root))}}if(a&&!this._.guardRTL){var G=d.type==CKEDITOR.NODE_ELEMENT?d:d.getParent(),F=d.type==CKEDITOR.NODE_ELEMENT?g?d.getChild(g-1):null:d.getPrevious();this._.guardRTL=function(a,f){return(!f||!G.equals(a))&&(!F||!a.equals(F))&&(a.type!=CKEDITOR.NODE_ELEMENT||!f||!a.equals(b.root))}}var E=a?this._.guardRTL:this._.guardLTR;e=m?function(a,f){return!1===E(a,f)?!1:m(a,f)}:E;this.current?c=this.current[l](!1,
n,e):(a?c.type==CKEDITOR.NODE_ELEMENT&&(c=0<h?c.getChild(h-1):!1===e(c,!0)?null:c.getPreviousSourceNode(!0,n,e)):(c=d,c.type==CKEDITOR.NODE_ELEMENT&&((c=c.getChild(g))||(c=!1===e(d,!0)?null:d.getNextSourceNode(!0,n,e)))),c&&!1===e(c)&&(c=null));for(;c&&!this._.end;){this.current=c;if(!this.evaluator||!1!==this.evaluator(c)){if(!f)return c}else if(f&&this.evaluator)return!1;c=c[l](!1,n,e)}this.end();return this.current=null}function e(f){for(var b,c=null;b=a.call(this,f);)c=b;return c}CKEDITOR.dom.walker=
CKEDITOR.tools.createClass({$:function(a){this.range=a;this._={}},proto:{end:function(){this._.end=1},next:function(){return a.call(this)},previous:function(){return a.call(this,1)},checkForward:function(){return!1!==a.call(this,0,1)},checkBackward:function(){return!1!==a.call(this,1,1)},lastForward:function(){return e.call(this)},lastBackward:function(){return e.call(this,1)},reset:function(){delete this.current;this._={}}}});var b={block:1,"list-item":1,table:1,"table-row-group":1,"table-header-group":1,
"table-footer-group":1,"table-row":1,"table-column-group":1,"table-column":1,"table-cell":1,"table-caption":1},d={absolute:1,fixed:1};CKEDITOR.dom.element.prototype.isBlockBoundary=function(a){return"none"!=this.getComputedStyle("float")||this.getComputedStyle("position")in d||!b[this.getComputedStyle("display")]?!!(this.is(CKEDITOR.dtd.$block)||a&&this.is(a)):!0};CKEDITOR.dom.walker.blockBoundary=function(a){return function(f){return!(f.type==CKEDITOR.NODE_ELEMENT&&f.isBlockBoundary(a))}};CKEDITOR.dom.walker.listItemBoundary=
function(){return this.blockBoundary({br:1})};CKEDITOR.dom.walker.bookmark=function(a,f){function b(a){return a&&a.getName&&"span"==a.getName()&&a.data("cke-bookmark")}return function(c){var d,g;d=c&&c.type!=CKEDITOR.NODE_ELEMENT&&(g=c.getParent())&&b(g);d=a?d:d||b(c);return!!(f^d)}};CKEDITOR.dom.walker.whitespaces=function(a){return function(f){var b;f&&f.type==CKEDITOR.NODE_TEXT&&(b=!CKEDITOR.tools.trim(f.getText())||CKEDITOR.env.webkit&&f.getText()==CKEDITOR.dom.selection.FILLING_CHAR_SEQUENCE);
return!!(a^b)}};CKEDITOR.dom.walker.invisible=function(a){var f=CKEDITOR.dom.walker.whitespaces(),b=CKEDITOR.env.webkit?1:0;return function(c){f(c)?c=1:(c.type==CKEDITOR.NODE_TEXT&&(c=c.getParent()),c=c.$.offsetWidth<=b);return!!(a^c)}};CKEDITOR.dom.walker.nodeType=function(a,f){return function(b){return!!(f^b.type==a)}};CKEDITOR.dom.walker.bogus=function(a){function f(a){return!l(a)&&!k(a)}return function(b){var c=CKEDITOR.env.needsBrFiller?b.is&&b.is("br"):b.getText&&g.test(b.getText());c&&(c=b.getParent(),
b=b.getNext(f),c=c.isBlockBoundary()&&(!b||b.type==CKEDITOR.NODE_ELEMENT&&b.isBlockBoundary()));return!!(a^c)}};CKEDITOR.dom.walker.temp=function(a){return function(f){f.type!=CKEDITOR.NODE_ELEMENT&&(f=f.getParent());f=f&&f.hasAttribute("data-cke-temp");return!!(a^f)}};var g=/^[\t\r\n ]*(?:&nbsp;|\xa0)$/,l=CKEDITOR.dom.walker.whitespaces(),k=CKEDITOR.dom.walker.bookmark(),h=CKEDITOR.dom.walker.temp(),c=function(a){return k(a)||l(a)||a.type==CKEDITOR.NODE_ELEMENT&&a.is(CKEDITOR.dtd.$inline)&&!a.is(CKEDITOR.dtd.$empty)};
CKEDITOR.dom.walker.ignored=function(a){return function(f){f=l(f)||k(f)||h(f);return!!(a^f)}};var m=CKEDITOR.dom.walker.ignored();CKEDITOR.dom.walker.empty=function(a){return function(f){for(var b=0,c=f.getChildCount();b<c;++b)if(!m(f.getChild(b)))return!!a;return!a}};var f=CKEDITOR.dom.walker.empty(),n=CKEDITOR.dom.walker.validEmptyBlockContainers=CKEDITOR.tools.extend(function(a){var f={},b;for(b in a)CKEDITOR.dtd[b]["#"]&&(f[b]=1);return f}(CKEDITOR.dtd.$block),{caption:1,td:1,th:1});CKEDITOR.dom.walker.editable=
function(a){return function(b){b=m(b)?!1:b.type==CKEDITOR.NODE_TEXT||b.type==CKEDITOR.NODE_ELEMENT&&(b.is(CKEDITOR.dtd.$inline)||b.is("hr")||"false"==b.getAttribute("contenteditable")||!CKEDITOR.env.needsBrFiller&&b.is(n)&&f(b))?!0:!1;return!!(a^b)}};CKEDITOR.dom.element.prototype.getBogus=function(){var a=this;do a=a.getPreviousSourceNode();while(c(a));return a&&(CKEDITOR.env.needsBrFiller?a.is&&a.is("br"):a.getText&&g.test(a.getText()))?a:!1}}(),CKEDITOR.dom.range=function(a){this.endOffset=this.endContainer=
this.startOffset=this.startContainer=null;this.collapsed=!0;var e=a instanceof CKEDITOR.dom.document;this.document=e?a:a.getDocument();this.root=e?a.getBody():a},function(){function a(a){a.collapsed=a.startContainer&&a.endContainer&&a.startContainer.equals(a.endContainer)&&a.startOffset==a.endOffset}function e(a,b,c,d,g){function h(a,f,b,c){var d=b?a.getPrevious():a.getNext();if(c&&l)return d;x||c?f.append(a.clone(!0,g),b):(a.remove(),k&&f.append(a,b));return d}function e(){var a,f,b,c=Math.min(K.length,
D.length);for(a=0;a<c;a++)if(f=K[a],b=D[a],!f.equals(b))return a;return a-1}function m(){var b=R-1,c=E&&J&&!u.equals(C);b<L-1||b<S-1||c?(c?a.moveToPosition(C,CKEDITOR.POSITION_BEFORE_START):S==b+1&&F?a.moveToPosition(D[b],CKEDITOR.POSITION_BEFORE_END):a.moveToPosition(D[b+1],CKEDITOR.POSITION_BEFORE_START),d&&(b=K[b+1])&&b.type==CKEDITOR.NODE_ELEMENT&&(c=CKEDITOR.dom.element.createFromHtml('\x3cspan data-cke-bookmark\x3d"1" style\x3d"display:none"\x3e\x26nbsp;\x3c/span\x3e',a.document),c.insertAfter(b),
b.mergeSiblings(!1),a.moveToBookmark({startNode:c}))):a.collapse(!0)}a.optimizeBookmark();var l=0===b,k=1==b,x=2==b;b=x||k;var u=a.startContainer,C=a.endContainer,z=a.startOffset,B=a.endOffset,G,F,E,J,H,M;if(x&&C.type==CKEDITOR.NODE_TEXT&&(u.equals(C)||u.type===CKEDITOR.NODE_ELEMENT&&u.getFirst().equals(C)))c.append(a.document.createText(C.substring(z,B)));else{C.type==CKEDITOR.NODE_TEXT?x?M=!0:C=C.split(B):0<C.getChildCount()?B>=C.getChildCount()?(C=C.getChild(B-1),F=!0):C=C.getChild(B):J=F=!0;u.type==
CKEDITOR.NODE_TEXT?x?H=!0:u.split(z):0<u.getChildCount()?0===z?(u=u.getChild(z),G=!0):u=u.getChild(z-1):E=G=!0;for(var K=u.getParents(),D=C.getParents(),R=e(),L=K.length-1,S=D.length-1,N=c,V,Z,X,da=-1,P=R;P<=L;P++){Z=K[P];X=Z.getNext();for(P!=L||Z.equals(D[P])&&L<S?b&&(V=N.append(Z.clone(0,g))):G?h(Z,N,!1,E):H&&N.append(a.document.createText(Z.substring(z)));X;){if(X.equals(D[P])){da=P;break}X=h(X,N)}N=V}N=c;for(P=R;P<=S;P++)if(c=D[P],X=c.getPrevious(),c.equals(K[P]))b&&(N=N.getChild(0));else{P!=
S||c.equals(K[P])&&S<L?b&&(V=N.append(c.clone(0,g))):F?h(c,N,!1,J):M&&N.append(a.document.createText(c.substring(0,B)));if(P>da)for(;X;)X=h(X,N,!0);N=V}x||m()}}function b(){var a=!1,b=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.dom.walker.bookmark(!0),d=CKEDITOR.dom.walker.bogus();return function(g){return c(g)||b(g)?!0:d(g)&&!a?a=!0:g.type==CKEDITOR.NODE_TEXT&&(g.hasAscendant("pre")||CKEDITOR.tools.trim(g.getText()).length)||g.type==CKEDITOR.NODE_ELEMENT&&!g.is(l)?!1:!0}}function d(a){var b=CKEDITOR.dom.walker.whitespaces(),
c=CKEDITOR.dom.walker.bookmark(1);return function(d){return c(d)||b(d)?!0:!a&&k(d)||d.type==CKEDITOR.NODE_ELEMENT&&d.is(CKEDITOR.dtd.$removeEmpty)}}function g(a){return function(){var b;return this[a?"getPreviousNode":"getNextNode"](function(a){!b&&m(a)&&(b=a);return c(a)&&!(k(a)&&a.equals(b))})}}var l={abbr:1,acronym:1,b:1,bdo:1,big:1,cite:1,code:1,del:1,dfn:1,em:1,font:1,i:1,ins:1,label:1,kbd:1,q:1,samp:1,small:1,span:1,strike:1,strong:1,sub:1,sup:1,tt:1,u:1,"var":1},k=CKEDITOR.dom.walker.bogus(),
h=/^[\t\r\n ]*(?:&nbsp;|\xa0)$/,c=CKEDITOR.dom.walker.editable(),m=CKEDITOR.dom.walker.ignored(!0);CKEDITOR.dom.range.prototype={clone:function(){var a=new CKEDITOR.dom.range(this.root);a._setStartContainer(this.startContainer);a.startOffset=this.startOffset;a._setEndContainer(this.endContainer);a.endOffset=this.endOffset;a.collapsed=this.collapsed;return a},collapse:function(a){a?(this._setEndContainer(this.startContainer),this.endOffset=this.startOffset):(this._setStartContainer(this.endContainer),
this.startOffset=this.endOffset);this.collapsed=!0},cloneContents:function(a){var b=new CKEDITOR.dom.documentFragment(this.document);this.collapsed||e(this,2,b,!1,"undefined"==typeof a?!0:a);return b},deleteContents:function(a){this.collapsed||e(this,0,null,a)},extractContents:function(a,b){var c=new CKEDITOR.dom.documentFragment(this.document);this.collapsed||e(this,1,c,a,"undefined"==typeof b?!0:b);return c},createBookmark:function(a){var b,c,d,g,h=this.collapsed;b=this.document.createElement("span");
b.data("cke-bookmark",1);b.setStyle("display","none");b.setHtml("\x26nbsp;");a&&(d="cke_bm_"+CKEDITOR.tools.getNextNumber(),b.setAttribute("id",d+(h?"C":"S")));h||(c=b.clone(),c.setHtml("\x26nbsp;"),a&&c.setAttribute("id",d+"E"),g=this.clone(),g.collapse(),g.insertNode(c));g=this.clone();g.collapse(!0);g.insertNode(b);c?(this.setStartAfter(b),this.setEndBefore(c)):this.moveToPosition(b,CKEDITOR.POSITION_AFTER_END);return{startNode:a?d+(h?"C":"S"):b,endNode:a?d+"E":c,serializable:a,collapsed:h}},createBookmark2:function(){function a(b){var f=
b.container,d=b.offset,g;g=f;var h=d;g=g.type!=CKEDITOR.NODE_ELEMENT||0===h||h==g.getChildCount()?0:g.getChild(h-1).type==CKEDITOR.NODE_TEXT&&g.getChild(h).type==CKEDITOR.NODE_TEXT;g&&(f=f.getChild(d-1),d=f.getLength());if(f.type==CKEDITOR.NODE_ELEMENT&&0<d){a:{for(g=f;d--;)if(h=g.getChild(d).getIndex(!0),0<=h){d=h;break a}d=-1}d+=1}if(f.type==CKEDITOR.NODE_TEXT){g=f;for(h=0;(g=g.getPrevious())&&g.type==CKEDITOR.NODE_TEXT;)h+=g.getText().replace(CKEDITOR.dom.selection.FILLING_CHAR_SEQUENCE,"").length;
g=h;f.getText()?d+=g:(h=f.getPrevious(c),g?(d=g,f=h?h.getNext():f.getParent().getFirst()):(f=f.getParent(),d=h?h.getIndex(!0)+1:0))}b.container=f;b.offset=d}function b(a,f){var c=f.getCustomData("cke-fillingChar");if(c){var d=a.container;c.equals(d)&&(a.offset-=CKEDITOR.dom.selection.FILLING_CHAR_SEQUENCE.length,0>=a.offset&&(a.offset=d.getIndex(),a.container=d.getParent()))}}var c=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_TEXT,!0);return function(c){var d=this.collapsed,g={container:this.startContainer,
offset:this.startOffset},h={container:this.endContainer,offset:this.endOffset};c&&(a(g),b(g,this.root),d||(a(h),b(h,this.root)));return{start:g.container.getAddress(c),end:d?null:h.container.getAddress(c),startOffset:g.offset,endOffset:h.offset,normalized:c,collapsed:d,is2:!0}}}(),moveToBookmark:function(a){if(a.is2){var b=this.document.getByAddress(a.start,a.normalized),c=a.startOffset,d=a.end&&this.document.getByAddress(a.end,a.normalized);a=a.endOffset;this.setStart(b,c);d?this.setEnd(d,a):this.collapse(!0)}else b=
(c=a.serializable)?this.document.getById(a.startNode):a.startNode,a=c?this.document.getById(a.endNode):a.endNode,this.setStartBefore(b),b.remove(),a?(this.setEndBefore(a),a.remove()):this.collapse(!0)},getBoundaryNodes:function(){var a=this.startContainer,b=this.endContainer,c=this.startOffset,d=this.endOffset,g;if(a.type==CKEDITOR.NODE_ELEMENT)if(g=a.getChildCount(),g>c)a=a.getChild(c);else if(1>g)a=a.getPreviousSourceNode();else{for(a=a.$;a.lastChild;)a=a.lastChild;a=new CKEDITOR.dom.node(a);a=
a.getNextSourceNode()||a}if(b.type==CKEDITOR.NODE_ELEMENT)if(g=b.getChildCount(),g>d)b=b.getChild(d).getPreviousSourceNode(!0);else if(1>g)b=b.getPreviousSourceNode();else{for(b=b.$;b.lastChild;)b=b.lastChild;b=new CKEDITOR.dom.node(b)}a.getPosition(b)&CKEDITOR.POSITION_FOLLOWING&&(a=b);return{startNode:a,endNode:b}},getCommonAncestor:function(a,b){var c=this.startContainer,d=this.endContainer,c=c.equals(d)?a&&c.type==CKEDITOR.NODE_ELEMENT&&this.startOffset==this.endOffset-1?c.getChild(this.startOffset):
c:c.getCommonAncestor(d);return b&&!c.is?c.getParent():c},optimize:function(){var a=this.startContainer,b=this.startOffset;a.type!=CKEDITOR.NODE_ELEMENT&&(b?b>=a.getLength()&&this.setStartAfter(a):this.setStartBefore(a));a=this.endContainer;b=this.endOffset;a.type!=CKEDITOR.NODE_ELEMENT&&(b?b>=a.getLength()&&this.setEndAfter(a):this.setEndBefore(a))},optimizeBookmark:function(){var a=this.startContainer,b=this.endContainer;a.is&&a.is("span")&&a.data("cke-bookmark")&&this.setStartAt(a,CKEDITOR.POSITION_BEFORE_START);
b&&b.is&&b.is("span")&&b.data("cke-bookmark")&&this.setEndAt(b,CKEDITOR.POSITION_AFTER_END)},trim:function(a,b){var c=this.startContainer,d=this.startOffset,g=this.collapsed;if((!a||g)&&c&&c.type==CKEDITOR.NODE_TEXT){if(d)if(d>=c.getLength())d=c.getIndex()+1,c=c.getParent();else{var h=c.split(d),d=c.getIndex()+1,c=c.getParent();this.startContainer.equals(this.endContainer)?this.setEnd(h,this.endOffset-this.startOffset):c.equals(this.endContainer)&&(this.endOffset+=1)}else d=c.getIndex(),c=c.getParent();
this.setStart(c,d);if(g){this.collapse(!0);return}}c=this.endContainer;d=this.endOffset;b||g||!c||c.type!=CKEDITOR.NODE_TEXT||(d?(d>=c.getLength()||c.split(d),d=c.getIndex()+1):d=c.getIndex(),c=c.getParent(),this.setEnd(c,d))},enlarge:function(a,b){function c(a){return a&&a.type==CKEDITOR.NODE_ELEMENT&&a.hasAttribute("contenteditable")?null:a}var d=new RegExp(/[^\s\ufeff]/);switch(a){case CKEDITOR.ENLARGE_INLINE:var g=1;case CKEDITOR.ENLARGE_ELEMENT:var h=function(a,b){var f=new CKEDITOR.dom.range(m);
f.setStart(a,b);f.setEndAt(m,CKEDITOR.POSITION_BEFORE_END);var f=new CKEDITOR.dom.walker(f),c;for(f.guard=function(a){return!(a.type==CKEDITOR.NODE_ELEMENT&&a.isBlockBoundary())};c=f.next();){if(c.type!=CKEDITOR.NODE_TEXT)return!1;G=c!=a?c.getText():c.substring(b);if(d.test(G))return!1}return!0};if(this.collapsed)break;var e=this.getCommonAncestor(),m=this.root,l,k,x,u,C,z=!1,B,G;B=this.startContainer;var F=this.startOffset;B.type==CKEDITOR.NODE_TEXT?(F&&(B=!CKEDITOR.tools.trim(B.substring(0,F)).length&&
B,z=!!B),B&&((u=B.getPrevious())||(x=B.getParent()))):(F&&(u=B.getChild(F-1)||B.getLast()),u||(x=B));for(x=c(x);x||u;){if(x&&!u){!C&&x.equals(e)&&(C=!0);if(g?x.isBlockBoundary():!m.contains(x))break;z&&"inline"==x.getComputedStyle("display")||(z=!1,C?l=x:this.setStartBefore(x));u=x.getPrevious()}for(;u;)if(B=!1,u.type==CKEDITOR.NODE_COMMENT)u=u.getPrevious();else{if(u.type==CKEDITOR.NODE_TEXT)G=u.getText(),d.test(G)&&(u=null),B=/[\s\ufeff]$/.test(G);else if((u.$.offsetWidth>(CKEDITOR.env.webkit?1:
0)||b&&u.is("br"))&&!u.data("cke-bookmark"))if(z&&CKEDITOR.dtd.$removeEmpty[u.getName()]){G=u.getText();if(d.test(G))u=null;else for(var F=u.$.getElementsByTagName("*"),E=0,J;J=F[E++];)if(!CKEDITOR.dtd.$removeEmpty[J.nodeName.toLowerCase()]){u=null;break}u&&(B=!!G.length)}else u=null;B&&(z?C?l=x:x&&this.setStartBefore(x):z=!0);if(u){B=u.getPrevious();if(!x&&!B){x=u;u=null;break}u=B}else x=null}x&&(x=c(x.getParent()))}B=this.endContainer;F=this.endOffset;x=u=null;C=z=!1;B.type==CKEDITOR.NODE_TEXT?
CKEDITOR.tools.trim(B.substring(F)).length?z=!0:(z=!B.getLength(),F==B.getLength()?(u=B.getNext())||(x=B.getParent()):h(B,F)&&(x=B.getParent())):(u=B.getChild(F))||(x=B);for(;x||u;){if(x&&!u){!C&&x.equals(e)&&(C=!0);if(g?x.isBlockBoundary():!m.contains(x))break;z&&"inline"==x.getComputedStyle("display")||(z=!1,C?k=x:x&&this.setEndAfter(x));u=x.getNext()}for(;u;){B=!1;if(u.type==CKEDITOR.NODE_TEXT)G=u.getText(),h(u,0)||(u=null),B=/^[\s\ufeff]/.test(G);else if(u.type==CKEDITOR.NODE_ELEMENT){if((0<u.$.offsetWidth||
b&&u.is("br"))&&!u.data("cke-bookmark"))if(z&&CKEDITOR.dtd.$removeEmpty[u.getName()]){G=u.getText();if(d.test(G))u=null;else for(F=u.$.getElementsByTagName("*"),E=0;J=F[E++];)if(!CKEDITOR.dtd.$removeEmpty[J.nodeName.toLowerCase()]){u=null;break}u&&(B=!!G.length)}else u=null}else B=1;B&&z&&(C?k=x:this.setEndAfter(x));if(u){B=u.getNext();if(!x&&!B){x=u;u=null;break}u=B}else x=null}x&&(x=c(x.getParent()))}l&&k&&(e=l.contains(k)?k:l,this.setStartBefore(e),this.setEndAfter(e));break;case CKEDITOR.ENLARGE_BLOCK_CONTENTS:case CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS:x=
new CKEDITOR.dom.range(this.root);m=this.root;x.setStartAt(m,CKEDITOR.POSITION_AFTER_START);x.setEnd(this.startContainer,this.startOffset);x=new CKEDITOR.dom.walker(x);var H,M,K=CKEDITOR.dom.walker.blockBoundary(a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS?{br:1}:null),D=null,R=function(a){if(a.type==CKEDITOR.NODE_ELEMENT&&"false"==a.getAttribute("contenteditable"))if(D){if(D.equals(a)){D=null;return}}else D=a;else if(D)return;var b=K(a);b||(H=a);return b},g=function(a){var b=R(a);!b&&a.is&&a.is("br")&&
(M=a);return b};x.guard=R;x=x.lastBackward();H=H||m;this.setStartAt(H,!H.is("br")&&(!x&&this.checkStartOfBlock()||x&&H.contains(x))?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_AFTER_END);if(a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS){x=this.clone();x=new CKEDITOR.dom.walker(x);var L=CKEDITOR.dom.walker.whitespaces(),S=CKEDITOR.dom.walker.bookmark();x.evaluator=function(a){return!L(a)&&!S(a)};if((x=x.previous())&&x.type==CKEDITOR.NODE_ELEMENT&&x.is("br"))break}x=this.clone();x.collapse();x.setEndAt(m,
CKEDITOR.POSITION_BEFORE_END);x=new CKEDITOR.dom.walker(x);x.guard=a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS?g:R;H=D=M=null;x=x.lastForward();H=H||m;this.setEndAt(H,!x&&this.checkEndOfBlock()||x&&H.contains(x)?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_BEFORE_START);M&&this.setEndAfter(M)}},shrink:function(a,b,c){var d="boolean"===typeof c?c:c&&"boolean"===typeof c.shrinkOnBlockBoundary?c.shrinkOnBlockBoundary:!0,g=c&&c.skipBogus;if(!this.collapsed){a=a||CKEDITOR.SHRINK_TEXT;var h=this.clone(),e=
this.startContainer,m=this.endContainer,l=this.startOffset,k=this.endOffset,x=c=1;e&&e.type==CKEDITOR.NODE_TEXT&&(l?l>=e.getLength()?h.setStartAfter(e):(h.setStartBefore(e),c=0):h.setStartBefore(e));m&&m.type==CKEDITOR.NODE_TEXT&&(k?k>=m.getLength()?h.setEndAfter(m):(h.setEndAfter(m),x=0):h.setEndBefore(m));var h=new CKEDITOR.dom.walker(h),u=CKEDITOR.dom.walker.bookmark(),C=CKEDITOR.dom.walker.bogus();h.evaluator=function(b){return b.type==(a==CKEDITOR.SHRINK_ELEMENT?CKEDITOR.NODE_ELEMENT:CKEDITOR.NODE_TEXT)};
var z;h.guard=function(b,c){if(g&&C(b)||u(b))return!0;if(a==CKEDITOR.SHRINK_ELEMENT&&b.type==CKEDITOR.NODE_TEXT||c&&b.equals(z)||!1===d&&b.type==CKEDITOR.NODE_ELEMENT&&b.isBlockBoundary()||b.type==CKEDITOR.NODE_ELEMENT&&b.hasAttribute("contenteditable"))return!1;c||b.type!=CKEDITOR.NODE_ELEMENT||(z=b);return!0};c&&(e=h[a==CKEDITOR.SHRINK_ELEMENT?"lastForward":"next"]())&&this.setStartAt(e,b?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_START);x&&(h.reset(),(h=h[a==CKEDITOR.SHRINK_ELEMENT?
"lastBackward":"previous"]())&&this.setEndAt(h,b?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_AFTER_END));return!(!c&&!x)}},insertNode:function(a){this.optimizeBookmark();this.trim(!1,!0);var b=this.startContainer,c=b.getChild(this.startOffset);c?a.insertBefore(c):b.append(a);a.getParent()&&a.getParent().equals(this.endContainer)&&this.endOffset++;this.setStartBefore(a)},moveToPosition:function(a,b){this.setStartAt(a,b);this.collapse(!0)},moveToRange:function(a){this.setStart(a.startContainer,a.startOffset);
this.setEnd(a.endContainer,a.endOffset)},selectNodeContents:function(a){this.setStart(a,0);this.setEnd(a,a.type==CKEDITOR.NODE_TEXT?a.getLength():a.getChildCount())},setStart:function(b,c){b.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$empty[b.getName()]&&(c=b.getIndex(),b=b.getParent());this._setStartContainer(b);this.startOffset=c;this.endContainer||(this._setEndContainer(b),this.endOffset=c);a(this)},setEnd:function(b,c){b.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$empty[b.getName()]&&(c=b.getIndex()+
1,b=b.getParent());this._setEndContainer(b);this.endOffset=c;this.startContainer||(this._setStartContainer(b),this.startOffset=c);a(this)},setStartAfter:function(a){this.setStart(a.getParent(),a.getIndex()+1)},setStartBefore:function(a){this.setStart(a.getParent(),a.getIndex())},setEndAfter:function(a){this.setEnd(a.getParent(),a.getIndex()+1)},setEndBefore:function(a){this.setEnd(a.getParent(),a.getIndex())},setStartAt:function(b,c){switch(c){case CKEDITOR.POSITION_AFTER_START:this.setStart(b,0);
break;case CKEDITOR.POSITION_BEFORE_END:b.type==CKEDITOR.NODE_TEXT?this.setStart(b,b.getLength()):this.setStart(b,b.getChildCount());break;case CKEDITOR.POSITION_BEFORE_START:this.setStartBefore(b);break;case CKEDITOR.POSITION_AFTER_END:this.setStartAfter(b)}a(this)},setEndAt:function(b,c){switch(c){case CKEDITOR.POSITION_AFTER_START:this.setEnd(b,0);break;case CKEDITOR.POSITION_BEFORE_END:b.type==CKEDITOR.NODE_TEXT?this.setEnd(b,b.getLength()):this.setEnd(b,b.getChildCount());break;case CKEDITOR.POSITION_BEFORE_START:this.setEndBefore(b);
break;case CKEDITOR.POSITION_AFTER_END:this.setEndAfter(b)}a(this)},fixBlock:function(a,b){var c=this.createBookmark(),d=this.document.createElement(b);this.collapse(a);this.enlarge(CKEDITOR.ENLARGE_BLOCK_CONTENTS);this.extractContents().appendTo(d);d.trim();this.insertNode(d);var g=d.getBogus();g&&g.remove();d.appendBogus();this.moveToBookmark(c);return d},splitBlock:function(a,b){var c=new CKEDITOR.dom.elementPath(this.startContainer,this.root),d=new CKEDITOR.dom.elementPath(this.endContainer,this.root),
g=c.block,h=d.block,e=null;if(!c.blockLimit.equals(d.blockLimit))return null;"br"!=a&&(g||(g=this.fixBlock(!0,a),h=(new CKEDITOR.dom.elementPath(this.endContainer,this.root)).block),h||(h=this.fixBlock(!1,a)));c=g&&this.checkStartOfBlock();d=h&&this.checkEndOfBlock();this.deleteContents();g&&g.equals(h)&&(d?(e=new CKEDITOR.dom.elementPath(this.startContainer,this.root),this.moveToPosition(h,CKEDITOR.POSITION_AFTER_END),h=null):c?(e=new CKEDITOR.dom.elementPath(this.startContainer,this.root),this.moveToPosition(g,
CKEDITOR.POSITION_BEFORE_START),g=null):(h=this.splitElement(g,b||!1),g.is("ul","ol")||g.appendBogus()));return{previousBlock:g,nextBlock:h,wasStartOfBlock:c,wasEndOfBlock:d,elementPath:e}},splitElement:function(a,b){if(!this.collapsed)return null;this.setEndAt(a,CKEDITOR.POSITION_BEFORE_END);var c=this.extractContents(!1,b||!1),d=a.clone(!1,b||!1);c.appendTo(d);d.insertAfter(a);this.moveToPosition(a,CKEDITOR.POSITION_AFTER_END);return d},removeEmptyBlocksAtEnd:function(){function a(f){return function(a){return b(a)||
c(a)||a.type==CKEDITOR.NODE_ELEMENT&&a.isEmptyInlineRemoveable()||f.is("table")&&a.is("caption")?!1:!0}}var b=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.dom.walker.bookmark(!1);return function(b){for(var c=this.createBookmark(),d=this[b?"endPath":"startPath"](),g=d.block||d.blockLimit,h;g&&!g.equals(d.root)&&!g.getFirst(a(g));)h=g.getParent(),this[b?"setEndAt":"setStartAt"](g,CKEDITOR.POSITION_AFTER_END),g.remove(1),g=h;this.moveToBookmark(c)}}(),startPath:function(){return new CKEDITOR.dom.elementPath(this.startContainer,
this.root)},endPath:function(){return new CKEDITOR.dom.elementPath(this.endContainer,this.root)},checkBoundaryOfElement:function(a,b){var c=b==CKEDITOR.START,g=this.clone();g.collapse(c);g[c?"setStartAt":"setEndAt"](a,c?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_END);g=new CKEDITOR.dom.walker(g);g.evaluator=d(c);return g[c?"checkBackward":"checkForward"]()},checkStartOfBlock:function(){var a=this.startContainer,c=this.startOffset;CKEDITOR.env.ie&&c&&a.type==CKEDITOR.NODE_TEXT&&(a=CKEDITOR.tools.ltrim(a.substring(0,
c)),h.test(a)&&this.trim(0,1));this.trim();a=new CKEDITOR.dom.elementPath(this.startContainer,this.root);c=this.clone();c.collapse(!0);c.setStartAt(a.block||a.blockLimit,CKEDITOR.POSITION_AFTER_START);a=new CKEDITOR.dom.walker(c);a.evaluator=b();return a.checkBackward()},checkEndOfBlock:function(){var a=this.endContainer,c=this.endOffset;CKEDITOR.env.ie&&a.type==CKEDITOR.NODE_TEXT&&(a=CKEDITOR.tools.rtrim(a.substring(c)),h.test(a)&&this.trim(1,0));this.trim();a=new CKEDITOR.dom.elementPath(this.endContainer,
this.root);c=this.clone();c.collapse(!1);c.setEndAt(a.block||a.blockLimit,CKEDITOR.POSITION_BEFORE_END);a=new CKEDITOR.dom.walker(c);a.evaluator=b();return a.checkForward()},getPreviousNode:function(a,b,c){var d=this.clone();d.collapse(1);d.setStartAt(c||this.root,CKEDITOR.POSITION_AFTER_START);c=new CKEDITOR.dom.walker(d);c.evaluator=a;c.guard=b;return c.previous()},getNextNode:function(a,b,c){var d=this.clone();d.collapse();d.setEndAt(c||this.root,CKEDITOR.POSITION_BEFORE_END);c=new CKEDITOR.dom.walker(d);
c.evaluator=a;c.guard=b;return c.next()},checkReadOnly:function(){function a(b,c){for(;b;){if(b.type==CKEDITOR.NODE_ELEMENT){if("false"==b.getAttribute("contentEditable")&&!b.data("cke-editable"))return 0;if(b.is("html")||"true"==b.getAttribute("contentEditable")&&(b.contains(c)||b.equals(c)))break}b=b.getParent()}return 1}return function(){var b=this.startContainer,c=this.endContainer;return!(a(b,c)&&a(c,b))}}(),moveToElementEditablePosition:function(a,b){if(a.type==CKEDITOR.NODE_ELEMENT&&!a.isEditable(!1))return this.moveToPosition(a,
b?CKEDITOR.POSITION_AFTER_END:CKEDITOR.POSITION_BEFORE_START),!0;for(var c=0;a;){if(a.type==CKEDITOR.NODE_TEXT){b&&this.endContainer&&this.checkEndOfBlock()&&h.test(a.getText())?this.moveToPosition(a,CKEDITOR.POSITION_BEFORE_START):this.moveToPosition(a,b?CKEDITOR.POSITION_AFTER_END:CKEDITOR.POSITION_BEFORE_START);c=1;break}if(a.type==CKEDITOR.NODE_ELEMENT)if(a.isEditable())this.moveToPosition(a,b?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_AFTER_START),c=1;else if(b&&a.is("br")&&this.endContainer&&
this.checkEndOfBlock())this.moveToPosition(a,CKEDITOR.POSITION_BEFORE_START);else if("false"==a.getAttribute("contenteditable")&&a.is(CKEDITOR.dtd.$block))return this.setStartBefore(a),this.setEndAfter(a),!0;var d=a,g=c,e=void 0;d.type==CKEDITOR.NODE_ELEMENT&&d.isEditable(!1)&&(e=d[b?"getLast":"getFirst"](m));g||e||(e=d[b?"getPrevious":"getNext"](m));a=e}return!!c},moveToClosestEditablePosition:function(a,b){var c,d=0,g,h,e=[CKEDITOR.POSITION_AFTER_END,CKEDITOR.POSITION_BEFORE_START];a?(c=new CKEDITOR.dom.range(this.root),
c.moveToPosition(a,e[b?0:1])):c=this.clone();if(a&&!a.is(CKEDITOR.dtd.$block))d=1;else if(g=c[b?"getNextEditableNode":"getPreviousEditableNode"]())d=1,(h=g.type==CKEDITOR.NODE_ELEMENT)&&g.is(CKEDITOR.dtd.$block)&&"false"==g.getAttribute("contenteditable")?(c.setStartAt(g,CKEDITOR.POSITION_BEFORE_START),c.setEndAt(g,CKEDITOR.POSITION_AFTER_END)):!CKEDITOR.env.needsBrFiller&&h&&g.is(CKEDITOR.dom.walker.validEmptyBlockContainers)?(c.setEnd(g,0),c.collapse()):c.moveToPosition(g,e[b?1:0]);d&&this.moveToRange(c);
return!!d},moveToElementEditStart:function(a){return this.moveToElementEditablePosition(a)},moveToElementEditEnd:function(a){return this.moveToElementEditablePosition(a,!0)},getEnclosedNode:function(){var a=this.clone();a.optimize();if(a.startContainer.type!=CKEDITOR.NODE_ELEMENT||a.endContainer.type!=CKEDITOR.NODE_ELEMENT)return null;var a=new CKEDITOR.dom.walker(a),b=CKEDITOR.dom.walker.bookmark(!1,!0),c=CKEDITOR.dom.walker.whitespaces(!0);a.evaluator=function(a){return c(a)&&b(a)};var d=a.next();
a.reset();return d&&d.equals(a.previous())?d:null},getTouchedStartNode:function(){var a=this.startContainer;return this.collapsed||a.type!=CKEDITOR.NODE_ELEMENT?a:a.getChild(this.startOffset)||a},getTouchedEndNode:function(){var a=this.endContainer;return this.collapsed||a.type!=CKEDITOR.NODE_ELEMENT?a:a.getChild(this.endOffset-1)||a},getNextEditableNode:g(),getPreviousEditableNode:g(1),_getTableElement:function(a){a=a||{td:1,th:1,tr:1,tbody:1,thead:1,tfoot:1,table:1};var b=this.startContainer,c=
this.endContainer,d=b.getAscendant("table",!0),g=c.getAscendant("table",!0);return CKEDITOR.env.safari&&d&&c.equals(this.root)?b.getAscendant(a,!0):this.getEnclosedNode()?this.getEnclosedNode().getAscendant(a,!0):d&&g&&(d.equals(g)||d.contains(g)||g.contains(d))?b.getAscendant(a,!0):null},scrollIntoView:function(){var a=new CKEDITOR.dom.element.createFromHtml("\x3cspan\x3e\x26nbsp;\x3c/span\x3e",this.document),b,c,d,g=this.clone();g.optimize();(d=g.startContainer.type==CKEDITOR.NODE_TEXT)?(c=g.startContainer.getText(),
b=g.startContainer.split(g.startOffset),a.insertAfter(g.startContainer)):g.insertNode(a);a.scrollIntoView();d&&(g.startContainer.setText(c),b.remove());a.remove()},_setStartContainer:function(a){this.startContainer=a},_setEndContainer:function(a){this.endContainer=a},_find:function(a,b){var c=this.getCommonAncestor(),d=this.getBoundaryNodes(),g=[],h,e,m,l;if(c&&c.find)for(e=c.find(a),h=0;h<e.count();h++)if(c=e.getItem(h),b||!c.isReadOnly())m=c.getPosition(d.startNode)&CKEDITOR.POSITION_FOLLOWING||
d.startNode.equals(c),l=c.getPosition(d.endNode)&CKEDITOR.POSITION_PRECEDING+CKEDITOR.POSITION_IS_CONTAINED||d.endNode.equals(c),m&&l&&g.push(c);return g}};CKEDITOR.dom.range.mergeRanges=function(a){return CKEDITOR.tools.array.reduce(a,function(a,b){var c=a[a.length-1],d=!1;b=b.clone();b.enlarge(CKEDITOR.ENLARGE_ELEMENT);if(c){var f=new CKEDITOR.dom.range(b.root),d=new CKEDITOR.dom.walker(f),g=CKEDITOR.dom.walker.whitespaces();f.setStart(c.endContainer,c.endOffset);f.setEnd(b.startContainer,b.startOffset);
for(f=d.next();g(f)||b.endContainer.equals(f);)f=d.next();d=!f}d?c.setEnd(b.endContainer,b.endOffset):a.push(b);return a},[])}}(),CKEDITOR.POSITION_AFTER_START=1,CKEDITOR.POSITION_BEFORE_END=2,CKEDITOR.POSITION_BEFORE_START=3,CKEDITOR.POSITION_AFTER_END=4,CKEDITOR.ENLARGE_ELEMENT=1,CKEDITOR.ENLARGE_BLOCK_CONTENTS=2,CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS=3,CKEDITOR.ENLARGE_INLINE=4,CKEDITOR.START=1,CKEDITOR.END=2,CKEDITOR.SHRINK_ELEMENT=1,CKEDITOR.SHRINK_TEXT=2,"use strict",function(){function a(a){1>
arguments.length||(this.range=a,this.forceBrBreak=0,this.enlargeBr=1,this.enforceRealBlocks=0,this._||(this._={}))}function e(a){var b=[];a.forEach(function(a){if("true"==a.getAttribute("contenteditable"))return b.push(a),!1},CKEDITOR.NODE_ELEMENT,!0);return b}function b(a,c,d,g){a:{null==g&&(g=e(d));for(var h;h=g.shift();)if(h.getDtd().p){g={element:h,remaining:g};break a}g=null}if(!g)return 0;if((h=CKEDITOR.filter.instances[g.element.data("cke-filter")])&&!h.check(c))return b(a,c,d,g.remaining);
c=new CKEDITOR.dom.range(g.element);c.selectNodeContents(g.element);c=c.createIterator();c.enlargeBr=a.enlargeBr;c.enforceRealBlocks=a.enforceRealBlocks;c.activeFilter=c.filter=h;a._.nestedEditable={element:g.element,container:d,remaining:g.remaining,iterator:c};return 1}function d(a,b,c){if(!b)return!1;a=a.clone();a.collapse(!c);return a.checkBoundaryOfElement(b,c?CKEDITOR.START:CKEDITOR.END)}var g=/^[\r\n\t ]+$/,l=CKEDITOR.dom.walker.bookmark(!1,!0),k=CKEDITOR.dom.walker.whitespaces(!0),h=function(a){return l(a)&&
k(a)},c={dd:1,dt:1,li:1};a.prototype={getNextParagraph:function(a){var f,e,k,q,v;a=a||"p";if(this._.nestedEditable){if(f=this._.nestedEditable.iterator.getNextParagraph(a))return this.activeFilter=this._.nestedEditable.iterator.activeFilter,f;this.activeFilter=this.filter;if(b(this,a,this._.nestedEditable.container,this._.nestedEditable.remaining))return this.activeFilter=this._.nestedEditable.iterator.activeFilter,this._.nestedEditable.iterator.getNextParagraph(a);this._.nestedEditable=null}if(!this.range.root.getDtd()[a])return null;
if(!this._.started){var y=this.range.clone();e=y.startPath();var r=y.endPath(),t=!y.collapsed&&d(y,e.block),w=!y.collapsed&&d(y,r.block,1);y.shrink(CKEDITOR.SHRINK_ELEMENT,!0);t&&y.setStartAt(e.block,CKEDITOR.POSITION_BEFORE_END);w&&y.setEndAt(r.block,CKEDITOR.POSITION_AFTER_START);e=y.endContainer.hasAscendant("pre",!0)||y.startContainer.hasAscendant("pre",!0);y.enlarge(this.forceBrBreak&&!e||!this.enlargeBr?CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS:CKEDITOR.ENLARGE_BLOCK_CONTENTS);y.collapsed||(e=new CKEDITOR.dom.walker(y.clone()),
r=CKEDITOR.dom.walker.bookmark(!0,!0),e.evaluator=r,this._.nextNode=e.next(),e=new CKEDITOR.dom.walker(y.clone()),e.evaluator=r,e=e.previous(),this._.lastNode=e.getNextSourceNode(!0,null,y.root),this._.lastNode&&this._.lastNode.type==CKEDITOR.NODE_TEXT&&!CKEDITOR.tools.trim(this._.lastNode.getText())&&this._.lastNode.getParent().isBlockBoundary()&&(r=this.range.clone(),r.moveToPosition(this._.lastNode,CKEDITOR.POSITION_AFTER_END),r.checkEndOfBlock()&&(r=new CKEDITOR.dom.elementPath(r.endContainer,
r.root),this._.lastNode=(r.block||r.blockLimit).getNextSourceNode(!0))),this._.lastNode&&y.root.contains(this._.lastNode)||(this._.lastNode=this._.docEndMarker=y.document.createText(""),this._.lastNode.insertAfter(e)),y=null);this._.started=1;e=y}r=this._.nextNode;y=this._.lastNode;for(this._.nextNode=null;r;){var t=0,w=r.hasAscendant("pre"),A=r.type!=CKEDITOR.NODE_ELEMENT,x=0;if(A)r.type==CKEDITOR.NODE_TEXT&&g.test(r.getText())&&(A=0);else{var u=r.getName();if(CKEDITOR.dtd.$block[u]&&"false"==r.getAttribute("contenteditable")){f=
r;b(this,a,f);break}else if(r.isBlockBoundary(this.forceBrBreak&&!w&&{br:1})){if("br"==u)A=1;else if(!e&&!r.getChildCount()&&"hr"!=u){f=r;k=r.equals(y);break}e&&(e.setEndAt(r,CKEDITOR.POSITION_BEFORE_START),"br"!=u&&(this._.nextNode=r));t=1}else{if(r.getFirst()){e||(e=this.range.clone(),e.setStartAt(r,CKEDITOR.POSITION_BEFORE_START));r=r.getFirst();continue}A=1}}A&&!e&&(e=this.range.clone(),e.setStartAt(r,CKEDITOR.POSITION_BEFORE_START));k=(!t||A)&&r.equals(y);if(e&&!t)for(;!r.getNext(h)&&!k;){u=
r.getParent();if(u.isBlockBoundary(this.forceBrBreak&&!w&&{br:1})){t=1;A=0;k||u.equals(y);e.setEndAt(u,CKEDITOR.POSITION_BEFORE_END);break}r=u;A=1;k=r.equals(y);x=1}A&&e.setEndAt(r,CKEDITOR.POSITION_AFTER_END);r=this._getNextSourceNode(r,x,y);if((k=!r)||t&&e)break}if(!f){if(!e)return this._.docEndMarker&&this._.docEndMarker.remove(),this._.nextNode=null;f=new CKEDITOR.dom.elementPath(e.startContainer,e.root);r=f.blockLimit;t={div:1,th:1,td:1};f=f.block;!f&&r&&!this.enforceRealBlocks&&t[r.getName()]&&
e.checkStartOfBlock()&&e.checkEndOfBlock()&&!r.equals(e.root)?f=r:!f||this.enforceRealBlocks&&f.is(c)?(f=this.range.document.createElement(a),e.extractContents().appendTo(f),f.trim(),e.insertNode(f),q=v=!0):"li"!=f.getName()?e.checkStartOfBlock()&&e.checkEndOfBlock()||(f=f.clone(!1),e.extractContents().appendTo(f),f.trim(),v=e.splitBlock(),q=!v.wasStartOfBlock,v=!v.wasEndOfBlock,e.insertNode(f)):k||(this._.nextNode=f.equals(y)?null:this._getNextSourceNode(e.getBoundaryNodes().endNode,1,y))}q&&(q=
f.getPrevious())&&q.type==CKEDITOR.NODE_ELEMENT&&("br"==q.getName()?q.remove():q.getLast()&&"br"==q.getLast().$.nodeName.toLowerCase()&&q.getLast().remove());v&&(q=f.getLast())&&q.type==CKEDITOR.NODE_ELEMENT&&"br"==q.getName()&&(!CKEDITOR.env.needsBrFiller||q.getPrevious(l)||q.getNext(l))&&q.remove();this._.nextNode||(this._.nextNode=k||f.equals(y)||!y?null:this._getNextSourceNode(f,1,y));return f},_getNextSourceNode:function(a,b,c){function d(a){return!(a.equals(c)||a.equals(g))}var g=this.range.root;
for(a=a.getNextSourceNode(b,null,d);!l(a);)a=a.getNextSourceNode(b,null,d);return a}};CKEDITOR.dom.range.prototype.createIterator=function(){return new a(this)}}(),CKEDITOR.command=function(a,e){this.uiItems=[];this.exec=function(b){if(this.state==CKEDITOR.TRISTATE_DISABLED||!this.checkAllowed())return!1;this.editorFocus&&a.focus();return!1===this.fire("exec")?!0:!1!==e.exec.call(this,a,b)};this.refresh=function(a,b){if(!this.readOnly&&a.readOnly)return!0;if(this.context&&!b.isContextFor(this.context)||
!this.checkAllowed(!0))return this.disable(),!0;this.startDisabled||this.enable();this.modes&&!this.modes[a.mode]&&this.disable();return!1===this.fire("refresh",{editor:a,path:b})?!0:e.refresh&&!1!==e.refresh.apply(this,arguments)};var b;this.checkAllowed=function(d){return d||"boolean"!=typeof b?b=a.activeFilter.checkFeature(this):b};CKEDITOR.tools.extend(this,e,{modes:{wysiwyg:1},editorFocus:1,contextSensitive:!!e.context,state:CKEDITOR.TRISTATE_DISABLED});CKEDITOR.event.call(this)},CKEDITOR.command.prototype=
{enable:function(){this.state==CKEDITOR.TRISTATE_DISABLED&&this.checkAllowed()&&this.setState(this.preserveState&&"undefined"!=typeof this.previousState?this.previousState:CKEDITOR.TRISTATE_OFF)},disable:function(){this.setState(CKEDITOR.TRISTATE_DISABLED)},setState:function(a){if(this.state==a||a!=CKEDITOR.TRISTATE_DISABLED&&!this.checkAllowed())return!1;this.previousState=this.state;this.state=a;this.fire("state");return!0},toggleState:function(){this.state==CKEDITOR.TRISTATE_OFF?this.setState(CKEDITOR.TRISTATE_ON):
this.state==CKEDITOR.TRISTATE_ON&&this.setState(CKEDITOR.TRISTATE_OFF)}},CKEDITOR.event.implementOn(CKEDITOR.command.prototype),CKEDITOR.ENTER_P=1,CKEDITOR.ENTER_BR=2,CKEDITOR.ENTER_DIV=3,CKEDITOR.config={customConfig:"config.js",autoUpdateElement:!0,language:"",defaultLanguage:"en",contentsLangDirection:"",enterMode:CKEDITOR.ENTER_P,forceEnterMode:!1,shiftEnterMode:CKEDITOR.ENTER_BR,docType:"\x3c!DOCTYPE html\x3e",bodyId:"",bodyClass:"",fullPage:!1,height:200,contentsCss:CKEDITOR.getUrl("contents.css"),
extraPlugins:"",removePlugins:"",protectedSource:[],tabIndex:0,width:"",baseFloatZIndex:1E4,blockedKeystrokes:[CKEDITOR.CTRL+66,CKEDITOR.CTRL+73,CKEDITOR.CTRL+85]},function(){function a(a,b,c,d,f){var g,h;a=[];for(g in b){h=b[g];h="boolean"==typeof h?{}:"function"==typeof h?{match:h}:E(h);"$"!=g.charAt(0)&&(h.elements=g);c&&(h.featureName=c.toLowerCase());var e=h;e.elements=k(e.elements,/\s+/)||null;e.propertiesOnly=e.propertiesOnly||!0===e.elements;var m=/\s*,\s*/,l=void 0;for(l in M){e[l]=k(e[l],
m)||null;var r=e,n=K[l],D=k(e[K[l]],m),x=e[l],u=[],z=!0,L=void 0;D?z=!1:D={};for(L in x)"!"==L.charAt(0)&&(L=L.slice(1),u.push(L),D[L]=!0,z=!1);for(;L=u.pop();)x[L]=x["!"+L],delete x["!"+L];r[n]=(z?!1:D)||null}e.match=e.match||null;d.push(h);a.push(h)}b=f.elements;f=f.generic;var w;c=0;for(d=a.length;c<d;++c){g=E(a[c]);h=!0===g.classes||!0===g.styles||!0===g.attributes;e=g;l=n=m=void 0;for(m in M)e[m]=t(e[m]);r=!0;for(l in K){m=K[l];n=e[m];D=[];x=void 0;for(x in n)-1<x.indexOf("*")?D.push(new RegExp("^"+
x.replace(/\*/g,".*")+"$")):D.push(x);n=D;n.length&&(e[m]=n,r=!1)}e.nothingRequired=r;e.noProperties=!(e.attributes||e.classes||e.styles);if(!0===g.elements||null===g.elements)f[h?"unshift":"push"](g);else for(w in e=g.elements,delete g.elements,e)if(b[w])b[w][h?"unshift":"push"](g);else b[w]=[g]}}function e(a,c,d,f){if(!a.match||a.match(c))if(f||h(a,c))if(a.propertiesOnly||(d.valid=!0),d.allAttributes||(d.allAttributes=b(a.attributes,c.attributes,d.validAttributes)),d.allStyles||(d.allStyles=b(a.styles,
c.styles,d.validStyles)),!d.allClasses){a=a.classes;c=c.classes;f=d.validClasses;if(a)if(!0===a)a=!0;else{for(var g=0,e=c.length,m;g<e;++g)m=c[g],f[m]||(f[m]=a(m));a=!1}else a=!1;d.allClasses=a}}function b(a,b,c){if(!a)return!1;if(!0===a)return!0;for(var d in b)c[d]||(c[d]=a(d));return!1}function d(a,b,c){if(!a.match||a.match(b)){if(a.noProperties)return!1;c.hadInvalidAttribute=g(a.attributes,b.attributes)||c.hadInvalidAttribute;c.hadInvalidStyle=g(a.styles,b.styles)||c.hadInvalidStyle;a=a.classes;
b=b.classes;if(a){for(var d=!1,f=!0===a,h=b.length;h--;)if(f||a(b[h]))b.splice(h,1),d=!0;a=d}else a=!1;c.hadInvalidClass=a||c.hadInvalidClass}}function g(a,b){if(!a)return!1;var c=!1,d=!0===a,f;for(f in b)if(d||a(f))delete b[f],c=!0;return c}function l(a,b,c){if(a.disabled||a.customConfig&&!c||!b)return!1;a._.cachedChecks={};return!0}function k(a,b){if(!a)return!1;if(!0===a)return a;if("string"==typeof a)return a=J(a),"*"==a?!0:CKEDITOR.tools.convertArrayToObject(a.split(b));if(CKEDITOR.tools.isArray(a))return a.length?
CKEDITOR.tools.convertArrayToObject(a):!1;var c={},d=0,f;for(f in a)c[f]=a[f],d++;return d?c:!1}function h(a,b){if(a.nothingRequired)return!0;var d,f,g,h;if(g=a.requiredClasses)for(h=b.classes,d=0;d<g.length;++d)if(f=g[d],"string"==typeof f){if(-1==CKEDITOR.tools.indexOf(h,f))return!1}else if(!CKEDITOR.tools.checkIfAnyArrayItemMatches(h,f))return!1;return c(b.styles,a.requiredStyles)&&c(b.attributes,a.requiredAttributes)}function c(a,b){if(!b)return!0;for(var c=0,d;c<b.length;++c)if(d=b[c],"string"==
typeof d){if(!(d in a))return!1}else if(!CKEDITOR.tools.checkIfAnyObjectPropertyMatches(a,d))return!1;return!0}function m(a){if(!a)return{};a=a.split(/\s*,\s*/).sort();for(var b={};a.length;)b[a.shift()]="cke-test";return b}function f(a){var b,c,d,f,g={},h=1;for(a=J(a);b=a.match(D);)(c=b[2])?(d=n(c,"styles"),f=n(c,"attrs"),c=n(c,"classes")):d=f=c=null,g["$"+h++]={elements:b[1],classes:c,styles:d,attributes:f},a=a.slice(b[0].length);return g}function n(a,b){var c=a.match(R[b]);return c?J(c[1]):null}
function p(a){var b=a.styleBackup=a.attributes.style,c=a.classBackup=a.attributes["class"];a.styles||(a.styles=CKEDITOR.tools.parseCssText(b||"",1));a.classes||(a.classes=c?c.split(/\s+/):[])}function q(a,b,c,f){var g=0,h;f.toHtml&&(b.name=b.name.replace(L,"$1"));if(f.doCallbacks&&a.elementCallbacks){a:{h=a.elementCallbacks;for(var m=0,l=h.length,k;m<l;++m)if(k=h[m](b)){h=k;break a}h=void 0}if(h)return h}if(f.doTransform&&(h=a._.transformations[b.name])){p(b);for(m=0;m<h.length;++m)u(a,b,h[m]);y(b)}if(f.doFilter){a:{m=
b.name;l=a._;a=l.allowedRules.elements[m];h=l.allowedRules.generic;m=l.disallowedRules.elements[m];l=l.disallowedRules.generic;k=f.skipRequired;var n={valid:!1,validAttributes:{},validClasses:{},validStyles:{},allAttributes:!1,allClasses:!1,allStyles:!1,hadInvalidAttribute:!1,hadInvalidClass:!1,hadInvalidStyle:!1},D,x;if(a||h){p(b);if(m)for(D=0,x=m.length;D<x;++D)if(!1===d(m[D],b,n)){a=null;break a}if(l)for(D=0,x=l.length;D<x;++D)d(l[D],b,n);if(a)for(D=0,x=a.length;D<x;++D)e(a[D],b,n,k);if(h)for(D=
0,x=h.length;D<x;++D)e(h[D],b,n,k);a=n}else a=null}if(!a||!a.valid)return c.push(b),1;x=a.validAttributes;var K=a.validStyles;h=a.validClasses;var m=b.attributes,t=b.styles,l=b.classes;k=b.classBackup;var z=b.styleBackup,w,F,C=[],n=[],E=/^data-cke-/;D=!1;delete m.style;delete m["class"];delete b.classBackup;delete b.styleBackup;if(!a.allAttributes)for(w in m)x[w]||(E.test(w)?w==(F=w.replace(/^data-cke-saved-/,""))||x[F]||(delete m[w],D=!0):(delete m[w],D=!0));if(!a.allStyles||a.hadInvalidStyle){for(w in t)a.allStyles||
K[w]?C.push(w+":"+t[w]):D=!0;C.length&&(m.style=C.sort().join("; "))}else z&&(m.style=z);if(!a.allClasses||a.hadInvalidClass){for(w=0;w<l.length;++w)(a.allClasses||h[l[w]])&&n.push(l[w]);n.length&&(m["class"]=n.sort().join(" "));k&&n.length<k.split(/\s+/).length&&(D=!0)}else k&&(m["class"]=k);D&&(g=1);if(!f.skipFinalValidation&&!r(b))return c.push(b),1}f.toHtml&&(b.name=b.name.replace(S,"cke:$1"));return g}function v(a){var b=[],c;for(c in a)-1<c.indexOf("*")&&b.push(c.replace(/\*/g,".*"));return b.length?
new RegExp("^(?:"+b.join("|")+")$"):null}function y(a){var b=a.attributes,c;delete b.style;delete b["class"];if(c=CKEDITOR.tools.writeCssText(a.styles,!0))b.style=c;a.classes.length&&(b["class"]=a.classes.sort().join(" "))}function r(a){switch(a.name){case "a":if(!(a.children.length||a.attributes.name||a.attributes.id))return!1;break;case "img":if(!a.attributes.src)return!1}return!0}function t(a){if(!a)return!1;if(!0===a)return!0;var b=v(a);return function(c){return c in a||b&&c.match(b)}}function w(){return new CKEDITOR.htmlParser.element("br")}
function A(a){return a.type==CKEDITOR.NODE_ELEMENT&&("br"==a.name||F.$block[a.name])}function x(a,b,c){var d=a.name;if(F.$empty[d]||!a.children.length)"hr"==d&&"br"==b?a.replaceWith(w()):(a.parent&&c.push({check:"it",el:a.parent}),a.remove());else if(F.$block[d]||"tr"==d)if("br"==b)a.previous&&!A(a.previous)&&(b=w(),b.insertBefore(a)),a.next&&!A(a.next)&&(b=w(),b.insertAfter(a)),a.replaceWithChildren();else{var d=a.children,f;b:{f=F[b];for(var g=0,h=d.length,e;g<h;++g)if(e=d[g],e.type==CKEDITOR.NODE_ELEMENT&&
!f[e.name]){f=!1;break b}f=!0}if(f)a.name=b,a.attributes={},c.push({check:"parent-down",el:a});else{f=a.parent;for(var g=f.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT||"body"==f.name,m,l,h=d.length;0<h;)e=d[--h],g&&(e.type==CKEDITOR.NODE_TEXT||e.type==CKEDITOR.NODE_ELEMENT&&F.$inline[e.name])?(m||(m=new CKEDITOR.htmlParser.element(b),m.insertAfter(a),c.push({check:"parent-down",el:m})),m.add(e,0)):(m=null,l=F[f.name]||F.span,e.insertAfter(a),f.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT||e.type!=CKEDITOR.NODE_ELEMENT||
l[e.name]||c.push({check:"el-up",el:e}));a.remove()}}else d in{style:1,script:1}?a.remove():(a.parent&&c.push({check:"it",el:a.parent}),a.replaceWithChildren())}function u(a,b,c){var d,f;for(d=0;d<c.length;++d)if(f=c[d],!(f.check&&!a.check(f.check,!1)||f.left&&!f.left(b))){f.right(b,N);break}}function C(a,b){var c=b.getDefinition(),d=c.attributes,f=c.styles,g,h,e,m;if(a.name!=c.element)return!1;for(g in d)if("class"==g)for(c=d[g].split(/\s+/),e=a.classes.join("|");m=c.pop();){if(-1==e.indexOf(m))return!1}else if(a.attributes[g]!=
d[g])return!1;for(h in f)if(a.styles[h]!=f[h])return!1;return!0}function z(a,b){var c,d;"string"==typeof a?c=a:a instanceof CKEDITOR.style?d=a:(c=a[0],d=a[1]);return[{element:c,left:d,right:function(a,c){c.transform(a,b)}}]}function B(a){return function(b){return C(b,a)}}function G(a){return function(b,c){c[a](b)}}var F=CKEDITOR.dtd,E=CKEDITOR.tools.copy,J=CKEDITOR.tools.trim,H=["","p","br","div"];CKEDITOR.FILTER_SKIP_TREE=2;CKEDITOR.filter=function(a){this.allowedContent=[];this.disallowedContent=
[];this.elementCallbacks=null;this.disabled=!1;this.editor=null;this.id=CKEDITOR.tools.getNextNumber();this._={allowedRules:{elements:{},generic:[]},disallowedRules:{elements:{},generic:[]},transformations:{},cachedTests:{},cachedChecks:{}};CKEDITOR.filter.instances[this.id]=this;if(a instanceof CKEDITOR.editor){a=this.editor=a;this.customConfig=!0;var b=a.config.allowedContent;!0===b?this.disabled=!0:(b||(this.customConfig=!1),this.allow(b,"config",1),this.allow(a.config.extraAllowedContent,"extra",
1),this.allow(H[a.enterMode]+" "+H[a.shiftEnterMode],"default",1),this.disallow(a.config.disallowedContent))}else this.customConfig=!1,this.allow(a,"default",1)};CKEDITOR.filter.instances={};CKEDITOR.filter.prototype={allow:function(b,c,d){if(!l(this,b,d))return!1;var g,h;if("string"==typeof b)b=f(b);else if(b instanceof CKEDITOR.style){if(b.toAllowedContentRules)return this.allow(b.toAllowedContentRules(this.editor),c,d);g=b.getDefinition();b={};d=g.attributes;b[g.element]=g={styles:g.styles,requiredStyles:g.styles&&
CKEDITOR.tools.objectKeys(g.styles)};d&&(d=E(d),g.classes=d["class"]?d["class"].split(/\s+/):null,g.requiredClasses=g.classes,delete d["class"],g.attributes=d,g.requiredAttributes=d&&CKEDITOR.tools.objectKeys(d))}else if(CKEDITOR.tools.isArray(b)){for(g=0;g<b.length;++g)h=this.allow(b[g],c,d);return h}a(this,b,c,this.allowedContent,this._.allowedRules);return!0},applyTo:function(a,b,c,d){if(this.disabled)return!1;var f=this,g=[],h=this.editor&&this.editor.config.protectedSource,e,m=!1,l={doFilter:!c,
doTransform:!0,doCallbacks:!0,toHtml:b};a.forEach(function(a){if(a.type==CKEDITOR.NODE_ELEMENT){if("off"==a.attributes["data-cke-filter"])return!1;if(!b||"span"!=a.name||!~CKEDITOR.tools.objectKeys(a.attributes).join("|").indexOf("data-cke-"))if(e=q(f,a,g,l),e&1)m=!0;else if(e&2)return!1}else if(a.type==CKEDITOR.NODE_COMMENT&&a.value.match(/^\{cke_protected\}(?!\{C\})/)){var c;a:{var d=decodeURIComponent(a.value.replace(/^\{cke_protected\}/,""));c=[];var k,r,n;if(h)for(r=0;r<h.length;++r)if((n=d.match(h[r]))&&
n[0].length==d.length){c=!0;break a}d=CKEDITOR.htmlParser.fragment.fromHtml(d);1==d.children.length&&(k=d.children[0]).type==CKEDITOR.NODE_ELEMENT&&q(f,k,c,l);c=!c.length}c||g.push(a)}},null,!0);g.length&&(m=!0);var k;a=[];d=H[d||(this.editor?this.editor.enterMode:CKEDITOR.ENTER_P)];for(var n;c=g.pop();)c.type==CKEDITOR.NODE_ELEMENT?x(c,d,a):c.remove();for(;k=a.pop();)if(c=k.el,c.parent)switch(n=F[c.parent.name]||F.span,k.check){case "it":F.$removeEmpty[c.name]&&!c.children.length?x(c,d,a):r(c)||
x(c,d,a);break;case "el-up":c.parent.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT||n[c.name]||x(c,d,a);break;case "parent-down":c.parent.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT||n[c.name]||x(c.parent,d,a)}return m},checkFeature:function(a){if(this.disabled||!a)return!0;a.toFeature&&(a=a.toFeature(this.editor));return!a.requiredContent||this.check(a.requiredContent)},disable:function(){this.disabled=!0},disallow:function(b){if(!l(this,b,!0))return!1;"string"==typeof b&&(b=f(b));a(this,b,null,this.disallowedContent,
this._.disallowedRules);return!0},addContentForms:function(a){if(!this.disabled&&a){var b,c,d=[],f;for(b=0;b<a.length&&!f;++b)c=a[b],("string"==typeof c||c instanceof CKEDITOR.style)&&this.check(c)&&(f=c);if(f){for(b=0;b<a.length;++b)d.push(z(a[b],f));this.addTransformations(d)}}},addElementCallback:function(a){this.elementCallbacks||(this.elementCallbacks=[]);this.elementCallbacks.push(a)},addFeature:function(a){if(this.disabled||!a)return!0;a.toFeature&&(a=a.toFeature(this.editor));this.allow(a.allowedContent,
a.name);this.addTransformations(a.contentTransformations);this.addContentForms(a.contentForms);return a.requiredContent&&(this.customConfig||this.disallowedContent.length)?this.check(a.requiredContent):!0},addTransformations:function(a){var b,c;if(!this.disabled&&a){var d=this._.transformations,f;for(f=0;f<a.length;++f){b=a[f];var g=void 0,h=void 0,e=void 0,m=void 0,l=void 0,k=void 0;c=[];for(h=0;h<b.length;++h)e=b[h],"string"==typeof e?(e=e.split(/\s*:\s*/),m=e[0],l=null,k=e[1]):(m=e.check,l=e.left,
k=e.right),g||(g=e,g=g.element?g.element:m?m.match(/^([a-z0-9]+)/i)[0]:g.left.getDefinition().element),l instanceof CKEDITOR.style&&(l=B(l)),c.push({check:m==g?null:m,left:l,right:"string"==typeof k?G(k):k});b=g;d[b]||(d[b]=[]);d[b].push(c)}}},check:function(a,b,c){if(this.disabled)return!0;if(CKEDITOR.tools.isArray(a)){for(var d=a.length;d--;)if(this.check(a[d],b,c))return!0;return!1}var g,h;if("string"==typeof a){h=a+"\x3c"+(!1===b?"0":"1")+(c?"1":"0")+"\x3e";if(h in this._.cachedChecks)return this._.cachedChecks[h];
d=f(a).$1;g=d.styles;var e=d.classes;d.name=d.elements;d.classes=e=e?e.split(/\s*,\s*/):[];d.styles=m(g);d.attributes=m(d.attributes);d.children=[];e.length&&(d.attributes["class"]=e.join(" "));g&&(d.attributes.style=CKEDITOR.tools.writeCssText(d.styles));g=d}else d=a.getDefinition(),g=d.styles,e=d.attributes||{},g&&!CKEDITOR.tools.isEmpty(g)?(g=E(g),e.style=CKEDITOR.tools.writeCssText(g,!0)):g={},g={name:d.element,attributes:e,classes:e["class"]?e["class"].split(/\s+/):[],styles:g,children:[]};var e=
CKEDITOR.tools.clone(g),l=[],k;if(!1!==b&&(k=this._.transformations[g.name])){for(d=0;d<k.length;++d)u(this,g,k[d]);y(g)}q(this,e,l,{doFilter:!0,doTransform:!1!==b,skipRequired:!c,skipFinalValidation:!c});b=0<l.length?!1:CKEDITOR.tools.objectCompare(g.attributes,e.attributes,!0)?!0:!1;"string"==typeof a&&(this._.cachedChecks[h]=b);return b},getAllowedEnterMode:function(){var a=["p","div","br"],b={p:CKEDITOR.ENTER_P,div:CKEDITOR.ENTER_DIV,br:CKEDITOR.ENTER_BR};return function(c,d){var f=a.slice(),
g;if(this.check(H[c]))return c;for(d||(f=f.reverse());g=f.pop();)if(this.check(g))return b[g];return CKEDITOR.ENTER_BR}}(),clone:function(){var a=new CKEDITOR.filter,b=CKEDITOR.tools.clone;a.allowedContent=b(this.allowedContent);a._.allowedRules=b(this._.allowedRules);a.disallowedContent=b(this.disallowedContent);a._.disallowedRules=b(this._.disallowedRules);a._.transformations=b(this._.transformations);a.disabled=this.disabled;a.editor=this.editor;return a},destroy:function(){delete CKEDITOR.filter.instances[this.id];
delete this._;delete this.allowedContent;delete this.disallowedContent}};var M={styles:1,attributes:1,classes:1},K={styles:"requiredStyles",attributes:"requiredAttributes",classes:"requiredClasses"},D=/^([a-z0-9\-*\s]+)((?:\s*\{[!\w\-,\s\*]+\}\s*|\s*\[[!\w\-,\s\*]+\]\s*|\s*\([!\w\-,\s\*]+\)\s*){0,3})(?:;\s*|$)/i,R={styles:/{([^}]+)}/,attrs:/\[([^\]]+)\]/,classes:/\(([^\)]+)\)/},L=/^cke:(object|embed|param)$/,S=/^(object|embed|param)$/,N;N=CKEDITOR.filter.transformationsTools={sizeToStyle:function(a){this.lengthToStyle(a,
"width");this.lengthToStyle(a,"height")},sizeToAttribute:function(a){this.lengthToAttribute(a,"width");this.lengthToAttribute(a,"height")},lengthToStyle:function(a,b,c){c=c||b;if(!(c in a.styles)){var d=a.attributes[b];d&&(/^\d+$/.test(d)&&(d+="px"),a.styles[c]=d)}delete a.attributes[b]},lengthToAttribute:function(a,b,c){c=c||b;if(!(c in a.attributes)){var d=a.styles[b],f=d&&d.match(/^(\d+)(?:\.\d*)?px$/);f?a.attributes[c]=f[1]:"cke-test"==d&&(a.attributes[c]="cke-test")}delete a.styles[b]},alignmentToStyle:function(a){if(!("float"in
a.styles)){var b=a.attributes.align;if("left"==b||"right"==b)a.styles["float"]=b}delete a.attributes.align},alignmentToAttribute:function(a){if(!("align"in a.attributes)){var b=a.styles["float"];if("left"==b||"right"==b)a.attributes.align=b}delete a.styles["float"]},splitBorderShorthand:function(a){function b(d){a.styles["border-top-width"]=c[d[0]];a.styles["border-right-width"]=c[d[1]];a.styles["border-bottom-width"]=c[d[2]];a.styles["border-left-width"]=c[d[3]]}if(a.styles.border){var c=a.styles.border.match(/([\.\d]+\w+)/g)||
["0px"];switch(c.length){case 1:a.styles["border-width"]=c[0];break;case 2:b([0,1,0,1]);break;case 3:b([0,1,2,1]);break;case 4:b([0,1,2,3])}a.styles["border-style"]=a.styles["border-style"]||(a.styles.border.match(/(none|hidden|dotted|dashed|solid|double|groove|ridge|inset|outset|initial|inherit)/)||[])[0];a.styles["border-style"]||delete a.styles["border-style"];delete a.styles.border}},listTypeToStyle:function(a){if(a.attributes.type)switch(a.attributes.type){case "a":a.styles["list-style-type"]=
"lower-alpha";break;case "A":a.styles["list-style-type"]="upper-alpha";break;case "i":a.styles["list-style-type"]="lower-roman";break;case "I":a.styles["list-style-type"]="upper-roman";break;case "1":a.styles["list-style-type"]="decimal";break;default:a.styles["list-style-type"]=a.attributes.type}},splitMarginShorthand:function(a){function b(d){a.styles["margin-top"]=c[d[0]];a.styles["margin-right"]=c[d[1]];a.styles["margin-bottom"]=c[d[2]];a.styles["margin-left"]=c[d[3]]}if(a.styles.margin){var c=
a.styles.margin.match(/(\-?[\.\d]+\w+)/g)||["0px"];switch(c.length){case 1:b([0,0,0,0]);break;case 2:b([0,1,0,1]);break;case 3:b([0,1,2,1]);break;case 4:b([0,1,2,3])}delete a.styles.margin}},matchesStyle:C,transform:function(a,b){if("string"==typeof b)a.name=b;else{var c=b.getDefinition(),d=c.styles,f=c.attributes,g,h,e,m;a.name=c.element;for(g in f)if("class"==g)for(c=a.classes.join("|"),e=f[g].split(/\s+/);m=e.pop();)-1==c.indexOf(m)&&a.classes.push(m);else a.attributes[g]=f[g];for(h in d)a.styles[h]=
d[h]}}}}(),function(){CKEDITOR.focusManager=function(a){if(a.focusManager)return a.focusManager;this.hasFocus=!1;this.currentActive=null;this._={editor:a};return this};CKEDITOR.focusManager._={blurDelay:200};CKEDITOR.focusManager.prototype={focus:function(a){this._.timer&&clearTimeout(this._.timer);a&&(this.currentActive=a);this.hasFocus||this._.locked||((a=CKEDITOR.currentInstance)&&a.focusManager.blur(1),this.hasFocus=!0,(a=this._.editor.container)&&a.addClass("cke_focus"),this._.editor.fire("focus"))},
lock:function(){this._.locked=1},unlock:function(){delete this._.locked},blur:function(a){function e(){if(this.hasFocus){this.hasFocus=!1;var a=this._.editor.container;a&&a.removeClass("cke_focus");this._.editor.fire("blur")}}if(!this._.locked){this._.timer&&clearTimeout(this._.timer);var b=CKEDITOR.focusManager._.blurDelay;a||!b?e.call(this):this._.timer=CKEDITOR.tools.setTimeout(function(){delete this._.timer;e.call(this)},b,this)}},add:function(a,e){var b=a.getCustomData("focusmanager");if(!b||
b!=this){b&&b.remove(a);var b="focus",d="blur";e&&(CKEDITOR.env.ie?(b="focusin",d="focusout"):CKEDITOR.event.useCapture=1);var g={blur:function(){a.equals(this.currentActive)&&this.blur()},focus:function(){this.focus(a)}};a.on(b,g.focus,this);a.on(d,g.blur,this);e&&(CKEDITOR.event.useCapture=0);a.setCustomData("focusmanager",this);a.setCustomData("focusmanager_handlers",g)}},remove:function(a){a.removeCustomData("focusmanager");var e=a.removeCustomData("focusmanager_handlers");a.removeListener("blur",
e.blur);a.removeListener("focus",e.focus)}}}(),CKEDITOR.keystrokeHandler=function(a){if(a.keystrokeHandler)return a.keystrokeHandler;this.keystrokes={};this.blockedKeystrokes={};this._={editor:a};return this},function(){var a,e=function(b){b=b.data;var g=b.getKeystroke(),e=this.keystrokes[g],k=this._.editor;a=!1===k.fire("key",{keyCode:g,domEvent:b});a||(e&&(a=!1!==k.execCommand(e,{from:"keystrokeHandler"})),a||(a=!!this.blockedKeystrokes[g]));a&&b.preventDefault(!0);return!a},b=function(b){a&&(a=
!1,b.data.preventDefault(!0))};CKEDITOR.keystrokeHandler.prototype={attach:function(a){a.on("keydown",e,this);if(CKEDITOR.env.gecko&&CKEDITOR.env.mac)a.on("keypress",b,this)}}}(),function(){CKEDITOR.lang={languages:{af:1,ar:1,az:1,bg:1,bn:1,bs:1,ca:1,cs:1,cy:1,da:1,de:1,"de-ch":1,el:1,"en-au":1,"en-ca":1,"en-gb":1,en:1,eo:1,es:1,"es-mx":1,et:1,eu:1,fa:1,fi:1,fo:1,"fr-ca":1,fr:1,gl:1,gu:1,he:1,hi:1,hr:1,hu:1,id:1,is:1,it:1,ja:1,ka:1,km:1,ko:1,ku:1,lt:1,lv:1,mk:1,mn:1,ms:1,nb:1,nl:1,no:1,oc:1,pl:1,
"pt-br":1,pt:1,ro:1,ru:1,si:1,sk:1,sl:1,sq:1,"sr-latn":1,sr:1,sv:1,th:1,tr:1,tt:1,ug:1,uk:1,vi:1,"zh-cn":1,zh:1},rtl:{ar:1,fa:1,he:1,ku:1,ug:1},load:function(a,e,b){a&&CKEDITOR.lang.languages[a]||(a=this.detect(e,a));var d=this;e=function(){d[a].dir=d.rtl[a]?"rtl":"ltr";b(a,d[a])};this[a]?e():CKEDITOR.scriptLoader.load(CKEDITOR.getUrl("lang/"+a+".js"),e,this)},detect:function(a,e){var b=this.languages;e=e||navigator.userLanguage||navigator.language||a;var d=e.toLowerCase().match(/([a-z]+)(?:-([a-z]+))?/),
g=d[1],d=d[2];b[g+"-"+d]?g=g+"-"+d:b[g]||(g=null);CKEDITOR.lang.detect=g?function(){return g}:function(a){return a};return g||a}}}(),CKEDITOR.scriptLoader=function(){var a={},e={};return{load:function(b,d,g,l){var k="string"==typeof b;k&&(b=[b]);g||(g=CKEDITOR);var h=b.length,c=[],m=[],f=function(a){d&&(k?d.call(g,a):d.call(g,c,m))};if(0===h)f(!0);else{var n=function(a,b){(b?c:m).push(a);0>=--h&&(l&&CKEDITOR.document.getDocumentElement().removeStyle("cursor"),f(b))},p=function(b,c){a[b]=1;var d=e[b];
delete e[b];for(var f=0;f<d.length;f++)d[f](b,c)},q=function(b){if(a[b])n(b,!0);else{var c=e[b]||(e[b]=[]);c.push(n);if(!(1<c.length)){var f=new CKEDITOR.dom.element("script");f.setAttributes({type:"text/javascript",src:b});d&&(CKEDITOR.env.ie&&(8>=CKEDITOR.env.version||CKEDITOR.env.ie9Compat)?f.$.onreadystatechange=function(){if("loaded"==f.$.readyState||"complete"==f.$.readyState)f.$.onreadystatechange=null,p(b,!0)}:(f.$.onload=function(){setTimeout(function(){p(b,!0)},0)},f.$.onerror=function(){p(b,
!1)}));f.appendTo(CKEDITOR.document.getHead())}}};l&&CKEDITOR.document.getDocumentElement().setStyle("cursor","wait");for(var v=0;v<h;v++)q(b[v])}},queue:function(){function a(){var b;(b=d[0])&&this.load(b.scriptUrl,b.callback,CKEDITOR,0)}var d=[];return function(g,e){var k=this;d.push({scriptUrl:g,callback:function(){e&&e.apply(this,arguments);d.shift();a.call(k)}});1==d.length&&a.call(this)}}()}}(),CKEDITOR.resourceManager=function(a,e){this.basePath=a;this.fileName=e;this.registered={};this.loaded=
{};this.externals={};this._={waitingList:{}}},CKEDITOR.resourceManager.prototype={add:function(a,e){if(this.registered[a])throw Error('[CKEDITOR.resourceManager.add] The resource name "'+a+'" is already registered.');var b=this.registered[a]=e||{};b.name=a;b.path=this.getPath(a);CKEDITOR.fire(a+CKEDITOR.tools.capitalize(this.fileName)+"Ready",b);return this.get(a)},get:function(a){return this.registered[a]||null},getPath:function(a){var e=this.externals[a];return CKEDITOR.getUrl(e&&e.dir||this.basePath+
a+"/")},getFilePath:function(a){var e=this.externals[a];return CKEDITOR.getUrl(this.getPath(a)+(e?e.file:this.fileName+".js"))},addExternal:function(a,e,b){a=a.split(",");for(var d=0;d<a.length;d++){var g=a[d];b||(e=e.replace(/[^\/]+$/,function(a){b=a;return""}));this.externals[g]={dir:e,file:b||this.fileName+".js"}}},load:function(a,e,b){CKEDITOR.tools.isArray(a)||(a=a?[a]:[]);for(var d=this.loaded,g=this.registered,l=[],k={},h={},c=0;c<a.length;c++){var m=a[c];if(m)if(d[m]||g[m])h[m]=this.get(m);
else{var f=this.getFilePath(m);l.push(f);f in k||(k[f]=[]);k[f].push(m)}}CKEDITOR.scriptLoader.load(l,function(a,c){if(c.length)throw Error('[CKEDITOR.resourceManager.load] Resource name "'+k[c[0]].join(",")+'" was not found at "'+c[0]+'".');for(var f=0;f<a.length;f++)for(var g=k[a[f]],m=0;m<g.length;m++){var l=g[m];h[l]=this.get(l);d[l]=1}e.call(b,h)},this)}},CKEDITOR.plugins=new CKEDITOR.resourceManager("plugins/","plugin"),CKEDITOR.plugins.load=CKEDITOR.tools.override(CKEDITOR.plugins.load,function(a){var e=
{};return function(b,d,g){var l={},k=function(b){a.call(this,b,function(a){CKEDITOR.tools.extend(l,a);var b=[],f;for(f in a){var h=a[f],p=h&&h.requires;if(!e[f]){if(h.icons)for(var q=h.icons.split(","),v=q.length;v--;)CKEDITOR.skin.addIcon(q[v],h.path+"icons/"+(CKEDITOR.env.hidpi&&h.hidpi?"hidpi/":"")+q[v]+".png");e[f]=1}if(p)for(p.split&&(p=p.split(",")),h=0;h<p.length;h++)l[p[h]]||b.push(p[h])}if(b.length)k.call(this,b);else{for(f in l)h=l[f],h.onLoad&&!h.onLoad._called&&(!1===h.onLoad()&&delete l[f],
h.onLoad._called=1);d&&d.call(g||window,l)}},this)};k.call(this,b)}}),CKEDITOR.plugins.setLang=function(a,e,b){var d=this.get(a);a=d.langEntries||(d.langEntries={});d=d.lang||(d.lang=[]);d.split&&(d=d.split(","));-1==CKEDITOR.tools.indexOf(d,e)&&d.push(e);a[e]=b},CKEDITOR.ui=function(a){if(a.ui)return a.ui;this.items={};this.instances={};this.editor=a;this._={handlers:{}};return this},CKEDITOR.ui.prototype={add:function(a,e,b){b.name=a.toLowerCase();var d=this.items[a]={type:e,command:b.command||
null,args:Array.prototype.slice.call(arguments,2)};CKEDITOR.tools.extend(d,b)},get:function(a){return this.instances[a]},create:function(a){var e=this.items[a],b=e&&this._.handlers[e.type],d=e&&e.command&&this.editor.getCommand(e.command),b=b&&b.create.apply(this,e.args);this.instances[a]=b;d&&d.uiItems.push(b);b&&!b.type&&(b.type=e.type);return b},addHandler:function(a,e){this._.handlers[a]=e},space:function(a){return CKEDITOR.document.getById(this.spaceId(a))},spaceId:function(a){return this.editor.id+
"_"+a}},CKEDITOR.event.implementOn(CKEDITOR.ui),function(){function a(a,c,f){CKEDITOR.event.call(this);a=a&&CKEDITOR.tools.clone(a);if(void 0!==c){if(!(c instanceof CKEDITOR.dom.element))throw Error("Expect element of type CKEDITOR.dom.element.");if(!f)throw Error("One of the element modes must be specified.");if(CKEDITOR.env.ie&&CKEDITOR.env.quirks&&f==CKEDITOR.ELEMENT_MODE_INLINE)throw Error("Inline element mode is not supported on IE quirks.");if(!b(c,f))throw Error('The specified element mode is not supported on element: "'+
c.getName()+'".');this.element=c;this.elementMode=f;this.name=this.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO&&(c.getId()||c.getNameAtt())}else this.elementMode=CKEDITOR.ELEMENT_MODE_NONE;this._={};this.commands={};this.templates={};this.name=this.name||e();this.id=CKEDITOR.tools.getNextId();this.status="unloaded";this.config=CKEDITOR.tools.prototypedCopy(CKEDITOR.config);this.ui=new CKEDITOR.ui(this);this.focusManager=new CKEDITOR.focusManager(this);this.keystrokeHandler=new CKEDITOR.keystrokeHandler(this);
this.on("readOnly",d);this.on("selectionChange",function(a){l(this,a.data.path)});this.on("activeFilterChange",function(){l(this,this.elementPath(),!0)});this.on("mode",d);this.on("instanceReady",function(){this.config.startupFocus&&this.focus()});CKEDITOR.fire("instanceCreated",null,this);CKEDITOR.add(this);CKEDITOR.tools.setTimeout(function(){"destroyed"!==this.status?h(this,a):CKEDITOR.warn("editor-incorrect-destroy")},0,this)}function e(){do var a="editor"+ ++v;while(CKEDITOR.instances[a]);return a}
function b(a,b){return b==CKEDITOR.ELEMENT_MODE_INLINE?a.is(CKEDITOR.dtd.$editable)||a.is("textarea"):b==CKEDITOR.ELEMENT_MODE_REPLACE?!a.is(CKEDITOR.dtd.$nonBodyContent):1}function d(){var a=this.commands,b;for(b in a)g(this,a[b])}function g(a,b){b[b.startDisabled?"disable":a.readOnly&&!b.readOnly?"disable":b.modes[a.mode]?"enable":"disable"]()}function l(a,b,c){if(b){var d,f,g=a.commands;for(f in g)d=g[f],(c||d.contextSensitive)&&d.refresh(a,b)}}function k(a){var b=a.config.customConfig;if(!b)return!1;
var b=CKEDITOR.getUrl(b),c=y[b]||(y[b]={});c.fn?(c.fn.call(a,a.config),CKEDITOR.getUrl(a.config.customConfig)!=b&&k(a)||a.fireOnce("customConfigLoaded")):CKEDITOR.scriptLoader.queue(b,function(){c.fn=CKEDITOR.editorConfig?CKEDITOR.editorConfig:function(){};k(a)});return!0}function h(a,b){a.on("customConfigLoaded",function(){if(b){if(b.on)for(var d in b.on)a.on(d,b.on[d]);CKEDITOR.tools.extend(a.config,b,!0);delete a.config.on}d=a.config;a.readOnly=d.readOnly?!0:a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?
a.element.is("textarea")?a.element.hasAttribute("disabled")||a.element.hasAttribute("readonly"):a.element.isReadOnly():a.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE?a.element.hasAttribute("disabled")||a.element.hasAttribute("readonly"):!1;a.blockless=a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?!(a.element.is("textarea")||CKEDITOR.dtd[a.element.getName()].p):!1;a.tabIndex=d.tabIndex||a.element&&a.element.getAttribute("tabindex")||0;a.activeEnterMode=a.enterMode=a.blockless?CKEDITOR.ENTER_BR:d.enterMode;
a.activeShiftEnterMode=a.shiftEnterMode=a.blockless?CKEDITOR.ENTER_BR:d.shiftEnterMode;d.skin&&(CKEDITOR.skinName=d.skin);a.fireOnce("configLoaded");a.dataProcessor=new CKEDITOR.htmlDataProcessor(a);a.filter=a.activeFilter=new CKEDITOR.filter(a);c(a)});b&&null!=b.customConfig&&(a.config.customConfig=b.customConfig);k(a)||a.fireOnce("customConfigLoaded")}function c(a){CKEDITOR.skin.loadPart("editor",function(){m(a)})}function m(a){CKEDITOR.lang.load(a.config.language,a.config.defaultLanguage,function(b,
c){var d=a.config.title;a.langCode=b;a.lang=CKEDITOR.tools.prototypedCopy(c);a.title="string"==typeof d||!1===d?d:[a.lang.editor,a.name].join(", ");a.config.contentsLangDirection||(a.config.contentsLangDirection=a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?a.element.getDirection(1):a.lang.dir);a.fire("langLoaded");f(a)})}function f(a){a.getStylesSet(function(b){a.once("loaded",function(){a.fire("stylesSet",{styles:b})},null,null,1);n(a)})}function n(a){var b=a.config,c=b.plugins,d=b.extraPlugins,f=
b.removePlugins;if(d)var g=new RegExp("(?:^|,)(?:"+d.replace(/\s*,\s*/g,"|")+")(?\x3d,|$)","g"),c=c.replace(g,""),c=c+(","+d);if(f)var h=new RegExp("(?:^|,)(?:"+f.replace(/\s*,\s*/g,"|")+")(?\x3d,|$)","g"),c=c.replace(h,"");CKEDITOR.env.air&&(c+=",adobeair");CKEDITOR.plugins.load(c.split(","),function(c){var d=[],f=[],g=[];a.plugins=c;for(var e in c){var m=c[e],l=m.lang,k=null,n=m.requires,D;CKEDITOR.tools.isArray(n)&&(n=n.join(","));if(n&&(D=n.match(h)))for(;n=D.pop();)CKEDITOR.error("editor-plugin-required",
{plugin:n.replace(",",""),requiredBy:e});l&&!a.lang[e]&&(l.split&&(l=l.split(",")),0<=CKEDITOR.tools.indexOf(l,a.langCode)?k=a.langCode:(k=a.langCode.replace(/-.*/,""),k=k!=a.langCode&&0<=CKEDITOR.tools.indexOf(l,k)?k:0<=CKEDITOR.tools.indexOf(l,"en")?"en":l[0]),m.langEntries&&m.langEntries[k]?(a.lang[e]=m.langEntries[k],k=null):g.push(CKEDITOR.getUrl(m.path+"lang/"+k+".js")));f.push(k);d.push(m)}CKEDITOR.scriptLoader.load(g,function(){for(var c=["beforeInit","init","afterInit"],g=0;g<c.length;g++)for(var h=
0;h<d.length;h++){var e=d[h];0===g&&f[h]&&e.lang&&e.langEntries&&(a.lang[e.name]=e.langEntries[f[h]]);if(e[c[g]])e[c[g]](a)}a.fireOnce("pluginsLoaded");b.keystrokes&&a.setKeystroke(a.config.keystrokes);for(h=0;h<a.config.blockedKeystrokes.length;h++)a.keystrokeHandler.blockedKeystrokes[a.config.blockedKeystrokes[h]]=1;a.status="loaded";a.fireOnce("loaded");CKEDITOR.fire("instanceLoaded",null,a)})})}function p(){var a=this.element;if(a&&this.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO){var b=this.getData();
this.config.htmlEncodeOutput&&(b=CKEDITOR.tools.htmlEncode(b));a.is("textarea")?a.setValue(b):a.setHtml(b);return!0}return!1}function q(a,b){function c(a){var b=a.startContainer,d=a.endContainer;return b.is&&(b.is("tr")||b.is("td")&&b.equals(d)&&a.endOffset===b.getChildCount())?!0:!1}function d(a){var b=a.startContainer;return b.is("tr")?a.cloneContents():b.clone(!0)}for(var f=new CKEDITOR.dom.documentFragment,g,h,e,m=0;m<a.length;m++){var l=a[m],k=l.startContainer.getAscendant("tr",!0);c(l)?(g||
(g=k.getAscendant("table").clone(),g.append(k.getAscendant({thead:1,tbody:1,tfoot:1}).clone()),f.append(g),g=g.findOne("thead, tbody, tfoot")),h&&h.equals(k)||(h=k,e=k.clone(),g.append(e)),e.append(d(l))):f.append(l.cloneContents())}return g?f:b.getHtmlFromRange(a[0])}a.prototype=CKEDITOR.editor.prototype;CKEDITOR.editor=a;var v=0,y={};CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{addCommand:function(a,b){b.name=a.toLowerCase();var c=new CKEDITOR.command(this,b);this.mode&&g(this,c);return this.commands[a]=
c},_attachToForm:function(){function a(b){c.updateElement();c._.required&&!d.getValue()&&!1===c.fire("required")&&b.data.preventDefault()}function b(a){return!!(a&&a.call&&a.apply)}var c=this,d=c.element,f=new CKEDITOR.dom.element(d.$.form);d.is("textarea")&&f&&(f.on("submit",a),b(f.$.submit)&&(f.$.submit=CKEDITOR.tools.override(f.$.submit,function(b){return function(){a();b.apply?b.apply(this):b()}})),c.on("destroy",function(){f.removeListener("submit",a)}))},destroy:function(a){this.fire("beforeDestroy");
!a&&p.call(this);this.editable(null);this.filter&&(this.filter.destroy(),delete this.filter);delete this.activeFilter;this.status="destroyed";this.fire("destroy");this.removeAllListeners();CKEDITOR.remove(this);CKEDITOR.fire("instanceDestroyed",null,this)},elementPath:function(a){if(!a){a=this.getSelection();if(!a)return null;a=a.getStartElement()}return a?new CKEDITOR.dom.elementPath(a,this.editable()):null},createRange:function(){var a=this.editable();return a?new CKEDITOR.dom.range(a):null},execCommand:function(a,
b){var c=this.getCommand(a),d={name:a,commandData:b||{},command:c};return c&&c.state!=CKEDITOR.TRISTATE_DISABLED&&!1!==this.fire("beforeCommandExec",d)&&(d.returnValue=c.exec(d.commandData),!c.async&&!1!==this.fire("afterCommandExec",d))?d.returnValue:!1},getCommand:function(a){return this.commands[a]},getData:function(a){!a&&this.fire("beforeGetData");var b=this._.data;"string"!=typeof b&&(b=(b=this.element)&&this.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE?b.is("textarea")?b.getValue():b.getHtml():
"");b={dataValue:b};!a&&this.fire("getData",b);return b.dataValue},getSnapshot:function(){var a=this.fire("getSnapshot");"string"!=typeof a&&(a=(a=this.element)&&this.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE?a.is("textarea")?a.getValue():a.getHtml():"");return a},loadSnapshot:function(a){this.fire("loadSnapshot",a)},setData:function(a,b,c){var d=!0,f=b;b&&"object"==typeof b&&(c=b.internal,f=b.callback,d=!b.noSnapshot);!c&&d&&this.fire("saveSnapshot");if(f||!c)this.once("dataReady",function(a){!c&&
d&&this.fire("saveSnapshot");f&&f.call(a.editor)});a={dataValue:a};!c&&this.fire("setData",a);this._.data=a.dataValue;!c&&this.fire("afterSetData",a)},setReadOnly:function(a){a=null==a||a;this.readOnly!=a&&(this.readOnly=a,this.keystrokeHandler.blockedKeystrokes[8]=+a,this.editable().setReadOnly(a),this.fire("readOnly"))},insertHtml:function(a,b,c){this.fire("insertHtml",{dataValue:a,mode:b,range:c})},insertText:function(a){this.fire("insertText",a)},insertElement:function(a){this.fire("insertElement",
a)},getSelectedHtml:function(a){var b=this.editable(),c=this.getSelection(),c=c&&c.getRanges();if(!b||!c||0===c.length)return null;b=q(c,b);return a?b.getHtml():b},extractSelectedHtml:function(a,b){var c=this.editable(),d=this.getSelection().getRanges(),f=new CKEDITOR.dom.documentFragment,g;if(!c||0===d.length)return null;for(g=0;g<d.length;g++)f.append(c.extractHtmlFromRange(d[g],b));b||this.getSelection().selectRanges([d[0]]);return a?f.getHtml():f},focus:function(){this.fire("beforeFocus")},checkDirty:function(){return"ready"==
this.status&&this._.previousValue!==this.getSnapshot()},resetDirty:function(){this._.previousValue=this.getSnapshot()},updateElement:function(){return p.call(this)},setKeystroke:function(){for(var a=this.keystrokeHandler.keystrokes,b=CKEDITOR.tools.isArray(arguments[0])?arguments[0]:[[].slice.call(arguments,0)],c,d,f=b.length;f--;)c=b[f],d=0,CKEDITOR.tools.isArray(c)&&(d=c[1],c=c[0]),d?a[c]=d:delete a[c]},getCommandKeystroke:function(a){if(a="string"===typeof a?this.getCommand(a):a){var b=CKEDITOR.tools.object.findKey(this.commands,
a),c=this.keystrokeHandler.keystrokes,d;if(a.fakeKeystroke)return a.fakeKeystroke;for(d in c)if(c.hasOwnProperty(d)&&c[d]==b)return d}return null},addFeature:function(a){return this.filter.addFeature(a)},setActiveFilter:function(a){a||(a=this.filter);this.activeFilter!==a&&(this.activeFilter=a,this.fire("activeFilterChange"),a===this.filter?this.setActiveEnterMode(null,null):this.setActiveEnterMode(a.getAllowedEnterMode(this.enterMode),a.getAllowedEnterMode(this.shiftEnterMode,!0)))},setActiveEnterMode:function(a,
b){a=a?this.blockless?CKEDITOR.ENTER_BR:a:this.enterMode;b=b?this.blockless?CKEDITOR.ENTER_BR:b:this.shiftEnterMode;if(this.activeEnterMode!=a||this.activeShiftEnterMode!=b)this.activeEnterMode=a,this.activeShiftEnterMode=b,this.fire("activeEnterModeChange")},showNotification:function(a){alert(a)}})}(),CKEDITOR.ELEMENT_MODE_NONE=0,CKEDITOR.ELEMENT_MODE_REPLACE=1,CKEDITOR.ELEMENT_MODE_APPENDTO=2,CKEDITOR.ELEMENT_MODE_INLINE=3,CKEDITOR.htmlParser=function(){this._={htmlPartsRegex:/<(?:(?:\/([^>]+)>)|(?:!--([\S|\s]*?)--\x3e)|(?:([^\/\s>]+)((?:\s+[\w\-:.]+(?:\s*=\s*?(?:(?:"[^"]*")|(?:'[^']*')|[^\s"'\/>]+))?)*)[\S\s]*?(\/?)>))/g}},
function(){var a=/([\w\-:.]+)(?:(?:\s*=\s*(?:(?:"([^"]*)")|(?:'([^']*)')|([^\s>]+)))|(?=\s|$))/g,e={checked:1,compact:1,declare:1,defer:1,disabled:1,ismap:1,multiple:1,nohref:1,noresize:1,noshade:1,nowrap:1,readonly:1,selected:1};CKEDITOR.htmlParser.prototype={onTagOpen:function(){},onTagClose:function(){},onText:function(){},onCDATA:function(){},onComment:function(){},parse:function(b){for(var d,g,l=0,k;d=this._.htmlPartsRegex.exec(b);){g=d.index;if(g>l)if(l=b.substring(l,g),k)k.push(l);else this.onText(l);
l=this._.htmlPartsRegex.lastIndex;if(g=d[1])if(g=g.toLowerCase(),k&&CKEDITOR.dtd.$cdata[g]&&(this.onCDATA(k.join("")),k=null),!k){this.onTagClose(g);continue}if(k)k.push(d[0]);else if(g=d[3]){if(g=g.toLowerCase(),!/="/.test(g)){var h={},c,m=d[4];d=!!d[5];if(m)for(;c=a.exec(m);){var f=c[1].toLowerCase();c=c[2]||c[3]||c[4]||"";h[f]=!c&&e[f]?f:CKEDITOR.tools.htmlDecodeAttr(c)}this.onTagOpen(g,h,d);!k&&CKEDITOR.dtd.$cdata[g]&&(k=[])}}else if(g=d[2])this.onComment(g)}if(b.length>l)this.onText(b.substring(l,
b.length))}}}(),CKEDITOR.htmlParser.basicWriter=CKEDITOR.tools.createClass({$:function(){this._={output:[]}},proto:{openTag:function(a){this._.output.push("\x3c",a)},openTagClose:function(a,e){e?this._.output.push(" /\x3e"):this._.output.push("\x3e")},attribute:function(a,e){"string"==typeof e&&(e=CKEDITOR.tools.htmlEncodeAttr(e));this._.output.push(" ",a,'\x3d"',e,'"')},closeTag:function(a){this._.output.push("\x3c/",a,"\x3e")},text:function(a){this._.output.push(a)},comment:function(a){this._.output.push("\x3c!--",
a,"--\x3e")},write:function(a){this._.output.push(a)},reset:function(){this._.output=[];this._.indent=!1},getHtml:function(a){var e=this._.output.join("");a&&this.reset();return e}}}),"use strict",function(){CKEDITOR.htmlParser.node=function(){};CKEDITOR.htmlParser.node.prototype={remove:function(){var a=this.parent.children,e=CKEDITOR.tools.indexOf(a,this),b=this.previous,d=this.next;b&&(b.next=d);d&&(d.previous=b);a.splice(e,1);this.parent=null},replaceWith:function(a){var e=this.parent.children,
b=CKEDITOR.tools.indexOf(e,this),d=a.previous=this.previous,g=a.next=this.next;d&&(d.next=a);g&&(g.previous=a);e[b]=a;a.parent=this.parent;this.parent=null},insertAfter:function(a){var e=a.parent.children,b=CKEDITOR.tools.indexOf(e,a),d=a.next;e.splice(b+1,0,this);this.next=a.next;this.previous=a;a.next=this;d&&(d.previous=this);this.parent=a.parent},insertBefore:function(a){var e=a.parent.children,b=CKEDITOR.tools.indexOf(e,a);e.splice(b,0,this);this.next=a;(this.previous=a.previous)&&(a.previous.next=
this);a.previous=this;this.parent=a.parent},getAscendant:function(a){var e="function"==typeof a?a:"string"==typeof a?function(b){return b.name==a}:function(b){return b.name in a},b=this.parent;for(;b&&b.type==CKEDITOR.NODE_ELEMENT;){if(e(b))return b;b=b.parent}return null},wrapWith:function(a){this.replaceWith(a);a.add(this);return a},getIndex:function(){return CKEDITOR.tools.indexOf(this.parent.children,this)},getFilterContext:function(a){return a||{}}}}(),"use strict",CKEDITOR.htmlParser.comment=
function(a){this.value=a;this._={isBlockLike:!1}},CKEDITOR.htmlParser.comment.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_COMMENT,filter:function(a,e){var b=this.value;if(!(b=a.onComment(e,b,this)))return this.remove(),!1;if("string"!=typeof b)return this.replaceWith(b),!1;this.value=b;return!0},writeHtml:function(a,e){e&&this.filter(e);a.comment(this.value)}}),"use strict",function(){CKEDITOR.htmlParser.text=function(a){this.value=a;this._={isBlockLike:!1}};CKEDITOR.htmlParser.text.prototype=
CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_TEXT,filter:function(a,e){if(!(this.value=a.onText(e,this.value,this)))return this.remove(),!1},writeHtml:function(a,e){e&&this.filter(e);a.text(this.value)}})}(),"use strict",function(){CKEDITOR.htmlParser.cdata=function(a){this.value=a};CKEDITOR.htmlParser.cdata.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_TEXT,filter:function(){},writeHtml:function(a){a.write(this.value)}})}(),"use strict",
CKEDITOR.htmlParser.fragment=function(){this.children=[];this.parent=null;this._={isBlockLike:!0,hasInlineStarted:!1}},function(){function a(a){return a.attributes["data-cke-survive"]?!1:"a"==a.name&&a.attributes.href||CKEDITOR.dtd.$removeEmpty[a.name]}var e=CKEDITOR.tools.extend({table:1,ul:1,ol:1,dl:1},CKEDITOR.dtd.table,CKEDITOR.dtd.ul,CKEDITOR.dtd.ol,CKEDITOR.dtd.dl),b={ol:1,ul:1},d=CKEDITOR.tools.extend({},{html:1},CKEDITOR.dtd.html,CKEDITOR.dtd.body,CKEDITOR.dtd.head,{style:1,script:1}),g={ul:"li",
ol:"li",dl:"dd",table:"tbody",tbody:"tr",thead:"tr",tfoot:"tr",tr:"td"};CKEDITOR.htmlParser.fragment.fromHtml=function(l,k,h){function c(a){var b;if(0<r.length)for(var c=0;c<r.length;c++){var d=r[c],f=d.name,g=CKEDITOR.dtd[f],h=w.name&&CKEDITOR.dtd[w.name];h&&!h[f]||a&&g&&!g[a]&&CKEDITOR.dtd[a]?f==w.name&&(n(w,w.parent,1),c--):(b||(m(),b=1),d=d.clone(),d.parent=w,w=d,r.splice(c,1),c--)}}function m(){for(;t.length;)n(t.shift(),w)}function f(a){if(a._.isBlockLike&&"pre"!=a.name&&"textarea"!=a.name){var b=
a.children.length,c=a.children[b-1],d;c&&c.type==CKEDITOR.NODE_TEXT&&((d=CKEDITOR.tools.rtrim(c.value))?c.value=d:a.children.length=b-1)}}function n(b,c,d){c=c||w||y;var g=w;void 0===b.previous&&(p(c,b)&&(w=c,v.onTagOpen(h,{}),b.returnPoint=c=w),f(b),a(b)&&!b.children.length||c.add(b),"pre"==b.name&&(x=!1),"textarea"==b.name&&(A=!1));b.returnPoint?(w=b.returnPoint,delete b.returnPoint):w=d?c:g}function p(a,b){if((a==y||"body"==a.name)&&h&&(!a.name||CKEDITOR.dtd[a.name][h])){var c,d;return(c=b.attributes&&
(d=b.attributes["data-cke-real-element-type"])?d:b.name)&&c in CKEDITOR.dtd.$inline&&!(c in CKEDITOR.dtd.head)&&!b.isOrphan||b.type==CKEDITOR.NODE_TEXT}}function q(a,b){return a in CKEDITOR.dtd.$listItem||a in CKEDITOR.dtd.$tableContent?a==b||"dt"==a&&"dd"==b||"dd"==a&&"dt"==b:!1}var v=new CKEDITOR.htmlParser,y=k instanceof CKEDITOR.htmlParser.element?k:"string"==typeof k?new CKEDITOR.htmlParser.element(k):new CKEDITOR.htmlParser.fragment,r=[],t=[],w=y,A="textarea"==y.name,x="pre"==y.name;v.onTagOpen=
function(f,g,h,l){g=new CKEDITOR.htmlParser.element(f,g);g.isUnknown&&h&&(g.isEmpty=!0);g.isOptionalClose=l;if(a(g))r.push(g);else{if("pre"==f)x=!0;else{if("br"==f&&x){w.add(new CKEDITOR.htmlParser.text("\n"));return}"textarea"==f&&(A=!0)}if("br"==f)t.push(g);else{for(;!(l=(h=w.name)?CKEDITOR.dtd[h]||(w._.isBlockLike?CKEDITOR.dtd.div:CKEDITOR.dtd.span):d,g.isUnknown||w.isUnknown||l[f]);)if(w.isOptionalClose)v.onTagClose(h);else if(f in b&&h in b)h=w.children,(h=h[h.length-1])&&"li"==h.name||n(h=new CKEDITOR.htmlParser.element("li"),
w),!g.returnPoint&&(g.returnPoint=w),w=h;else if(f in CKEDITOR.dtd.$listItem&&!q(f,h))v.onTagOpen("li"==f?"ul":"dl",{},0,1);else if(h in e&&!q(f,h))!g.returnPoint&&(g.returnPoint=w),w=w.parent;else if(h in CKEDITOR.dtd.$inline&&r.unshift(w),w.parent)n(w,w.parent,1);else{g.isOrphan=1;break}c(f);m();g.parent=w;g.isEmpty?n(g):w=g}}};v.onTagClose=function(a){for(var b=r.length-1;0<=b;b--)if(a==r[b].name){r.splice(b,1);return}for(var c=[],d=[],f=w;f!=y&&f.name!=a;)f._.isBlockLike||d.unshift(f),c.push(f),
f=f.returnPoint||f.parent;if(f!=y){for(b=0;b<c.length;b++){var g=c[b];n(g,g.parent)}w=f;f._.isBlockLike&&m();n(f,f.parent);f==w&&(w=w.parent);r=r.concat(d)}"body"==a&&(h=!1)};v.onText=function(a){if(!(w._.hasInlineStarted&&!t.length||x||A)&&(a=CKEDITOR.tools.ltrim(a),0===a.length))return;var b=w.name,f=b?CKEDITOR.dtd[b]||(w._.isBlockLike?CKEDITOR.dtd.div:CKEDITOR.dtd.span):d;if(!A&&!f["#"]&&b in e)v.onTagOpen(g[b]||""),v.onText(a);else{m();c();x||A||(a=a.replace(/[\t\r\n ]{2,}|[\t\r\n]/g," "));a=
new CKEDITOR.htmlParser.text(a);if(p(w,a))this.onTagOpen(h,{},0,1);w.add(a)}};v.onCDATA=function(a){w.add(new CKEDITOR.htmlParser.cdata(a))};v.onComment=function(a){m();c();w.add(new CKEDITOR.htmlParser.comment(a))};v.parse(l);for(m();w!=y;)n(w,w.parent,1);f(y);return y};CKEDITOR.htmlParser.fragment.prototype={type:CKEDITOR.NODE_DOCUMENT_FRAGMENT,add:function(a,b){isNaN(b)&&(b=this.children.length);var d=0<b?this.children[b-1]:null;if(d){if(a._.isBlockLike&&d.type==CKEDITOR.NODE_TEXT&&(d.value=CKEDITOR.tools.rtrim(d.value),
0===d.value.length)){this.children.pop();this.add(a);return}d.next=a}a.previous=d;a.parent=this;this.children.splice(b,0,a);this._.hasInlineStarted||(this._.hasInlineStarted=a.type==CKEDITOR.NODE_TEXT||a.type==CKEDITOR.NODE_ELEMENT&&!a._.isBlockLike)},filter:function(a,b){b=this.getFilterContext(b);a.onRoot(b,this);this.filterChildren(a,!1,b)},filterChildren:function(a,b,d){if(this.childrenFilteredBy!=a.id){d=this.getFilterContext(d);if(b&&!this.parent)a.onRoot(d,this);this.childrenFilteredBy=a.id;
for(b=0;b<this.children.length;b++)!1===this.children[b].filter(a,d)&&b--}},writeHtml:function(a,b){b&&this.filter(b);this.writeChildrenHtml(a)},writeChildrenHtml:function(a,b,d){var c=this.getFilterContext();if(d&&!this.parent&&b)b.onRoot(c,this);b&&this.filterChildren(b,!1,c);b=0;d=this.children;for(c=d.length;b<c;b++)d[b].writeHtml(a)},forEach:function(a,b,d){if(!(d||b&&this.type!=b))var c=a(this);if(!1!==c){d=this.children;for(var g=0;g<d.length;g++)c=d[g],c.type==CKEDITOR.NODE_ELEMENT?c.forEach(a,
b):b&&c.type!=b||a(c)}},getFilterContext:function(a){return a||{}}}}(),"use strict",function(){function a(){this.rules=[]}function e(b,d,g,e){var k,h;for(k in d)(h=b[k])||(h=b[k]=new a),h.add(d[k],g,e)}CKEDITOR.htmlParser.filter=CKEDITOR.tools.createClass({$:function(b){this.id=CKEDITOR.tools.getNextNumber();this.elementNameRules=new a;this.attributeNameRules=new a;this.elementsRules={};this.attributesRules={};this.textRules=new a;this.commentRules=new a;this.rootRules=new a;b&&this.addRules(b,10)},
proto:{addRules:function(a,d){var g;"number"==typeof d?g=d:d&&"priority"in d&&(g=d.priority);"number"!=typeof g&&(g=10);"object"!=typeof d&&(d={});a.elementNames&&this.elementNameRules.addMany(a.elementNames,g,d);a.attributeNames&&this.attributeNameRules.addMany(a.attributeNames,g,d);a.elements&&e(this.elementsRules,a.elements,g,d);a.attributes&&e(this.attributesRules,a.attributes,g,d);a.text&&this.textRules.add(a.text,g,d);a.comment&&this.commentRules.add(a.comment,g,d);a.root&&this.rootRules.add(a.root,
g,d)},applyTo:function(a){a.filter(this)},onElementName:function(a,d){return this.elementNameRules.execOnName(a,d)},onAttributeName:function(a,d){return this.attributeNameRules.execOnName(a,d)},onText:function(a,d,g){return this.textRules.exec(a,d,g)},onComment:function(a,d,g){return this.commentRules.exec(a,d,g)},onRoot:function(a,d){return this.rootRules.exec(a,d)},onElement:function(a,d){for(var g=[this.elementsRules["^"],this.elementsRules[d.name],this.elementsRules.$],e,k=0;3>k;k++)if(e=g[k]){e=
e.exec(a,d,this);if(!1===e)return null;if(e&&e!=d)return this.onNode(a,e);if(d.parent&&!d.name)break}return d},onNode:function(a,d){var g=d.type;return g==CKEDITOR.NODE_ELEMENT?this.onElement(a,d):g==CKEDITOR.NODE_TEXT?new CKEDITOR.htmlParser.text(this.onText(a,d.value)):g==CKEDITOR.NODE_COMMENT?new CKEDITOR.htmlParser.comment(this.onComment(a,d.value)):null},onAttribute:function(a,d,g,e){return(g=this.attributesRules[g])?g.exec(a,e,d,this):e}}});CKEDITOR.htmlParser.filterRulesGroup=a;a.prototype=
{add:function(a,d,g){this.rules.splice(this.findIndex(d),0,{value:a,priority:d,options:g})},addMany:function(a,d,g){for(var e=[this.findIndex(d),0],k=0,h=a.length;k<h;k++)e.push({value:a[k],priority:d,options:g});this.rules.splice.apply(this.rules,e)},findIndex:function(a){for(var d=this.rules,g=d.length-1;0<=g&&a<d[g].priority;)g--;return g+1},exec:function(a,d){var g=d instanceof CKEDITOR.htmlParser.node||d instanceof CKEDITOR.htmlParser.fragment,e=Array.prototype.slice.call(arguments,1),k=this.rules,
h=k.length,c,m,f,n;for(n=0;n<h;n++)if(g&&(c=d.type,m=d.name),f=k[n],!(a.nonEditable&&!f.options.applyToAll||a.nestedEditable&&f.options.excludeNestedEditable)){f=f.value.apply(null,e);if(!1===f||g&&f&&(f.name!=m||f.type!=c))return f;null!=f&&(e[0]=d=f)}return d},execOnName:function(a,d){for(var g=0,e=this.rules,k=e.length,h;d&&g<k;g++)h=e[g],a.nonEditable&&!h.options.applyToAll||a.nestedEditable&&h.options.excludeNestedEditable||(d=d.replace(h.value[0],h.value[1]));return d}}}(),function(){function a(a,
c){function f(a){return a||CKEDITOR.env.needsNbspFiller?new CKEDITOR.htmlParser.text(" "):new CKEDITOR.htmlParser.element("br",{"data-cke-bogus":1})}function h(a,c){return function(g){if(g.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT){var h=[],m=b(g),k,D;if(m)for(e(m,1)&&h.push(m);m;)l(m)&&(k=d(m))&&e(k)&&((D=d(k))&&!l(D)?h.push(k):(f(n).insertAfter(k),k.remove())),m=m.previous;for(m=0;m<h.length;m++)h[m].remove();if(h=!a||!1!==("function"==typeof c?c(g):c))n||CKEDITOR.env.needsBrFiller||g.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT?
n||CKEDITOR.env.needsBrFiller||!(7<document.documentMode||g.name in CKEDITOR.dtd.tr||g.name in CKEDITOR.dtd.$listItem)?(h=b(g),h=!h||"form"==g.name&&"input"==h.name):h=!1:h=!1;h&&g.add(f(a))}}}function e(a,b){if((!n||CKEDITOR.env.needsBrFiller)&&a.type==CKEDITOR.NODE_ELEMENT&&"br"==a.name&&!a.attributes["data-cke-eol"])return!0;var c;return a.type==CKEDITOR.NODE_TEXT&&(c=a.value.match(r))&&(c.index&&((new CKEDITOR.htmlParser.text(a.value.substring(0,c.index))).insertBefore(a),a.value=c[0]),!CKEDITOR.env.needsBrFiller&&
n&&(!b||a.parent.name in D)||!n&&((c=a.previous)&&"br"==c.name||!c||l(c)))?!0:!1}var m={elements:{}},n="html"==c,D=CKEDITOR.tools.extend({},x),K;for(K in D)"#"in w[K]||delete D[K];for(K in D)m.elements[K]=h(n,a.config.fillEmptyBlocks);m.root=h(n,!1);m.elements.br=function(a){return function(b){if(b.parent.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT){var c=b.attributes;if("data-cke-bogus"in c||"data-cke-eol"in c)delete c["data-cke-bogus"];else{for(c=b.next;c&&g(c);)c=c.next;var h=d(b);!c&&l(b.parent)?k(b.parent,
f(a)):l(c)&&h&&!l(h)&&f(a).insertBefore(c)}}}}(n);return m}function e(a,b){return a!=CKEDITOR.ENTER_BR&&!1!==b?a==CKEDITOR.ENTER_DIV?"div":"p":!1}function b(a){for(a=a.children[a.children.length-1];a&&g(a);)a=a.previous;return a}function d(a){for(a=a.previous;a&&g(a);)a=a.previous;return a}function g(a){return a.type==CKEDITOR.NODE_TEXT&&!CKEDITOR.tools.trim(a.value)||a.type==CKEDITOR.NODE_ELEMENT&&a.attributes["data-cke-bookmark"]}function l(a){return a&&(a.type==CKEDITOR.NODE_ELEMENT&&a.name in
x||a.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT)}function k(a,b){var c=a.children[a.children.length-1];a.children.push(b);b.parent=a;c&&(c.next=b,b.previous=c)}function h(a){a=a.attributes;"false"!=a.contenteditable&&(a["data-cke-editable"]=a.contenteditable?"true":1);a.contenteditable="false"}function c(a){a=a.attributes;switch(a["data-cke-editable"]){case "true":a.contenteditable="true";break;case "1":delete a.contenteditable}}function m(a){return a.replace(G,function(a,b,c){return"\x3c"+b+c.replace(F,
function(a,b){return E.test(b)&&-1==c.indexOf("data-cke-saved-"+b)?" data-cke-saved-"+a+" data-cke-"+CKEDITOR.rnd+"-"+a:a})+"\x3e"})}function f(a,b){return a.replace(b,function(a,b,c){0===a.indexOf("\x3ctextarea")&&(a=b+q(c).replace(/</g,"\x26lt;").replace(/>/g,"\x26gt;")+"\x3c/textarea\x3e");return"\x3ccke:encoded\x3e"+encodeURIComponent(a)+"\x3c/cke:encoded\x3e"})}function n(a){return a.replace(M,function(a,b){return decodeURIComponent(b)})}function p(a){return a.replace(/\x3c!--(?!{cke_protected})[\s\S]+?--\x3e/g,
function(a){return"\x3c!--"+t+"{C}"+encodeURIComponent(a).replace(/--/g,"%2D%2D")+"--\x3e"})}function q(a){return a.replace(/\x3c!--\{cke_protected\}\{C\}([\s\S]+?)--\x3e/g,function(a,b){return decodeURIComponent(b)})}function v(a,b){var c=b._.dataStore;return a.replace(/\x3c!--\{cke_protected\}([\s\S]+?)--\x3e/g,function(a,b){return decodeURIComponent(b)}).replace(/\{cke_protected_(\d+)\}/g,function(a,b){return c&&c[b]||""})}function y(a,b){var c=[],d=b.config.protectedSource,f=b._.dataStore||(b._.dataStore=
{id:1}),g=/<\!--\{cke_temp(comment)?\}(\d*?)--\x3e/g,d=[/<script[\s\S]*?(<\/script>|$)/gi,/<noscript[\s\S]*?<\/noscript>/gi,/<meta[\s\S]*?\/?>/gi].concat(d);a=a.replace(/\x3c!--[\s\S]*?--\x3e/g,function(a){return"\x3c!--{cke_tempcomment}"+(c.push(a)-1)+"--\x3e"});for(var h=0;h<d.length;h++)a=a.replace(d[h],function(a){a=a.replace(g,function(a,b,d){return c[d]});return/cke_temp(comment)?/.test(a)?a:"\x3c!--{cke_temp}"+(c.push(a)-1)+"--\x3e"});a=a.replace(g,function(a,b,d){return"\x3c!--"+t+(b?"{C}":
"")+encodeURIComponent(c[d]).replace(/--/g,"%2D%2D")+"--\x3e"});a=a.replace(/<\w+(?:\s+(?:(?:[^\s=>]+\s*=\s*(?:[^'"\s>]+|'[^']*'|"[^"]*"))|[^\s=\/>]+))+\s*\/?>/g,function(a){return a.replace(/\x3c!--\{cke_protected\}([^>]*)--\x3e/g,function(a,b){f[f.id]=decodeURIComponent(b);return"{cke_protected_"+f.id++ +"}"})});return a=a.replace(/<(title|iframe|textarea)([^>]*)>([\s\S]*?)<\/\1>/g,function(a,c,d,f){return"\x3c"+c+d+"\x3e"+v(q(f),b)+"\x3c/"+c+"\x3e"})}CKEDITOR.htmlDataProcessor=function(b){var c,
d,g=this;this.editor=b;this.dataFilter=c=new CKEDITOR.htmlParser.filter;this.htmlFilter=d=new CKEDITOR.htmlParser.filter;this.writer=new CKEDITOR.htmlParser.basicWriter;c.addRules(u);c.addRules(C,{applyToAll:!0});c.addRules(a(b,"data"),{applyToAll:!0});d.addRules(z);d.addRules(B,{applyToAll:!0});d.addRules(a(b,"html"),{applyToAll:!0});b.on("toHtml",function(a){a=a.data;var c=a.dataValue,d,c=y(c,b),c=f(c,H),c=m(c),c=f(c,J),c=c.replace(K,"$1cke:$2"),c=c.replace(R,"\x3ccke:$1$2\x3e\x3c/cke:$1\x3e"),
c=c.replace(/(<pre\b[^>]*>)(\r\n|\n)/g,"$1$2$2"),c=c.replace(/([^a-z0-9<\-])(on\w{3,})(?!>)/gi,"$1data-cke-"+CKEDITOR.rnd+"-$2");d=a.context||b.editable().getName();var g;CKEDITOR.env.ie&&9>CKEDITOR.env.version&&"pre"==d&&(d="div",c="\x3cpre\x3e"+c+"\x3c/pre\x3e",g=1);d=b.document.createElement(d);d.setHtml("a"+c);c=d.getHtml().substr(1);c=c.replace(new RegExp("data-cke-"+CKEDITOR.rnd+"-","ig"),"");g&&(c=c.replace(/^<pre>|<\/pre>$/gi,""));c=c.replace(D,"$1$2");c=n(c);c=q(c);d=!1===a.fixForBody?!1:
e(a.enterMode,b.config.autoParagraph);c=CKEDITOR.htmlParser.fragment.fromHtml(c,a.context,d);d&&(g=c,!g.children.length&&CKEDITOR.dtd[g.name][d]&&(d=new CKEDITOR.htmlParser.element(d),g.add(d)));a.dataValue=c},null,null,5);b.on("toHtml",function(a){a.data.filter.applyTo(a.data.dataValue,!0,a.data.dontFilter,a.data.enterMode)&&b.fire("dataFiltered")},null,null,6);b.on("toHtml",function(a){a.data.dataValue.filterChildren(g.dataFilter,!0)},null,null,10);b.on("toHtml",function(a){a=a.data;var b=a.dataValue,
c=new CKEDITOR.htmlParser.basicWriter;b.writeChildrenHtml(c);b=c.getHtml(!0);a.dataValue=p(b)},null,null,15);b.on("toDataFormat",function(a){var c=a.data.dataValue;a.data.enterMode!=CKEDITOR.ENTER_BR&&(c=c.replace(/^<br *\/?>/i,""));a.data.dataValue=CKEDITOR.htmlParser.fragment.fromHtml(c,a.data.context,e(a.data.enterMode,b.config.autoParagraph))},null,null,5);b.on("toDataFormat",function(a){a.data.dataValue.filterChildren(g.htmlFilter,!0)},null,null,10);b.on("toDataFormat",function(a){a.data.filter.applyTo(a.data.dataValue,
!1,!0)},null,null,11);b.on("toDataFormat",function(a){var c=a.data.dataValue,d=g.writer;d.reset();c.writeChildrenHtml(d);c=d.getHtml(!0);c=q(c);c=v(c,b);a.data.dataValue=c},null,null,15)};CKEDITOR.htmlDataProcessor.prototype={toHtml:function(a,b,c,d){var f=this.editor,g,h,e,m;b&&"object"==typeof b?(g=b.context,c=b.fixForBody,d=b.dontFilter,h=b.filter,e=b.enterMode,m=b.protectedWhitespaces):g=b;g||null===g||(g=f.editable().getName());return f.fire("toHtml",{dataValue:a,context:g,fixForBody:c,dontFilter:d,
filter:h||f.filter,enterMode:e||f.enterMode,protectedWhitespaces:m}).dataValue},toDataFormat:function(a,b){var c,d,f;b&&(c=b.context,d=b.filter,f=b.enterMode);c||null===c||(c=this.editor.editable().getName());return this.editor.fire("toDataFormat",{dataValue:a,filter:d||this.editor.filter,context:c,enterMode:f||this.editor.enterMode}).dataValue}};var r=/(?:&nbsp;|\xa0)$/,t="{cke_protected}",w=CKEDITOR.dtd,A="caption colgroup col thead tfoot tbody".split(" "),x=CKEDITOR.tools.extend({},w.$blockLimit,
w.$block),u={elements:{input:h,textarea:h}},C={attributeNames:[[/^on/,"data-cke-pa-on"],[/^srcdoc/,"data-cke-pa-srcdoc"],[/^data-cke-expando$/,""]],elements:{iframe:function(a){if(a.attributes&&a.attributes.src){var b=a.attributes.src.toLowerCase().replace(/[^a-z]/gi,"");if(0===b.indexOf("javascript")||0===b.indexOf("data"))a.attributes["data-cke-pa-src"]=a.attributes.src,delete a.attributes.src}}}},z={elements:{embed:function(a){var b=a.parent;if(b&&"object"==b.name){var c=b.attributes.width,b=b.attributes.height;
c&&(a.attributes.width=c);b&&(a.attributes.height=b)}},a:function(a){var b=a.attributes;if(!(a.children.length||b.name||b.id||a.attributes["data-cke-saved-name"]))return!1}}},B={elementNames:[[/^cke:/,""],[/^\?xml:namespace$/,""]],attributeNames:[[/^data-cke-(saved|pa)-/,""],[/^data-cke-.*/,""],["hidefocus",""]],elements:{$:function(a){var b=a.attributes;if(b){if(b["data-cke-temp"])return!1;for(var c=["name","href","src"],d,f=0;f<c.length;f++)d="data-cke-saved-"+c[f],d in b&&delete b[c[f]]}return a},
table:function(a){a.children.slice(0).sort(function(a,b){var c,d;a.type==CKEDITOR.NODE_ELEMENT&&b.type==a.type&&(c=CKEDITOR.tools.indexOf(A,a.name),d=CKEDITOR.tools.indexOf(A,b.name));-1<c&&-1<d&&c!=d||(c=a.parent?a.getIndex():-1,d=b.parent?b.getIndex():-1);return c>d?1:-1})},param:function(a){a.children=[];a.isEmpty=!0;return a},span:function(a){"Apple-style-span"==a.attributes["class"]&&delete a.name},html:function(a){delete a.attributes.contenteditable;delete a.attributes["class"]},body:function(a){delete a.attributes.spellcheck;
delete a.attributes.contenteditable},style:function(a){var b=a.children[0];b&&b.value&&(b.value=CKEDITOR.tools.trim(b.value));a.attributes.type||(a.attributes.type="text/css")},title:function(a){var b=a.children[0];!b&&k(a,b=new CKEDITOR.htmlParser.text);b.value=a.attributes["data-cke-title"]||""},input:c,textarea:c},attributes:{"class":function(a){return CKEDITOR.tools.ltrim(a.replace(/(?:^|\s+)cke_[^\s]*/g,""))||!1}}};CKEDITOR.env.ie&&(B.attributes.style=function(a){return a.replace(/(^|;)([^\:]+)/g,
function(a){return a.toLowerCase()})});var G=/<(a|area|img|input|source)\b([^>]*)>/gi,F=/([\w-:]+)\s*=\s*(?:(?:"[^"]*")|(?:'[^']*')|(?:[^ "'>]+))/gi,E=/^(href|src|name)$/i,J=/(?:<style(?=[ >])[^>]*>[\s\S]*?<\/style>)|(?:<(:?link|meta|base)[^>]*>)/gi,H=/(<textarea(?=[ >])[^>]*>)([\s\S]*?)(?:<\/textarea>)/gi,M=/<cke:encoded>([^<]*)<\/cke:encoded>/gi,K=/(<\/?)((?:object|embed|param|html|body|head|title)[^>]*>)/gi,D=/(<\/?)cke:((?:html|body|head|title)[^>]*>)/gi,R=/<cke:(param|embed)([^>]*?)\/?>(?!\s*<\/cke:\1)/gi}(),
"use strict",CKEDITOR.htmlParser.element=function(a,e){this.name=a;this.attributes=e||{};this.children=[];var b=a||"",d=b.match(/^cke:(.*)/);d&&(b=d[1]);b=!!(CKEDITOR.dtd.$nonBodyContent[b]||CKEDITOR.dtd.$block[b]||CKEDITOR.dtd.$listItem[b]||CKEDITOR.dtd.$tableContent[b]||CKEDITOR.dtd.$nonEditable[b]||"br"==b);this.isEmpty=!!CKEDITOR.dtd.$empty[a];this.isUnknown=!CKEDITOR.dtd[a];this._={isBlockLike:b,hasInlineStarted:this.isEmpty||!b}},CKEDITOR.htmlParser.cssStyle=function(a){var e={};((a instanceof
CKEDITOR.htmlParser.element?a.attributes.style:a)||"").replace(/&quot;/g,'"').replace(/\s*([^ :;]+)\s*:\s*([^;]+)\s*(?=;|$)/g,function(a,d,g){"font-family"==d&&(g=g.replace(/["']/g,""));e[d.toLowerCase()]=g});return{rules:e,populate:function(a){var d=this.toString();d&&(a instanceof CKEDITOR.dom.element?a.setAttribute("style",d):a instanceof CKEDITOR.htmlParser.element?a.attributes.style=d:a.style=d)},toString:function(){var a=[],d;for(d in e)e[d]&&a.push(d,":",e[d],";");return a.join("")}}},function(){function a(a){return function(b){return b.type==
CKEDITOR.NODE_ELEMENT&&("string"==typeof a?b.name==a:b.name in a)}}var e=function(a,b){a=a[0];b=b[0];return a<b?-1:a>b?1:0},b=CKEDITOR.htmlParser.fragment.prototype;CKEDITOR.htmlParser.element.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_ELEMENT,add:b.add,clone:function(){return new CKEDITOR.htmlParser.element(this.name,this.attributes)},filter:function(a,b){var e=this,k,h;b=e.getFilterContext(b);if(b.off)return!0;if(!e.parent)a.onRoot(b,e);for(;;){k=e.name;if(!(h=
a.onElementName(b,k)))return this.remove(),!1;e.name=h;if(!(e=a.onElement(b,e)))return this.remove(),!1;if(e!==this)return this.replaceWith(e),!1;if(e.name==k)break;if(e.type!=CKEDITOR.NODE_ELEMENT)return this.replaceWith(e),!1;if(!e.name)return this.replaceWithChildren(),!1}k=e.attributes;var c,m;for(c in k){for(h=k[c];;)if(m=a.onAttributeName(b,c))if(m!=c)delete k[c],c=m;else break;else{delete k[c];break}m&&(!1===(h=a.onAttribute(b,e,m,h))?delete k[m]:k[m]=h)}e.isEmpty||this.filterChildren(a,!1,
b);return!0},filterChildren:b.filterChildren,writeHtml:function(a,b){b&&this.filter(b);var l=this.name,k=[],h=this.attributes,c,m;a.openTag(l,h);for(c in h)k.push([c,h[c]]);a.sortAttributes&&k.sort(e);c=0;for(m=k.length;c<m;c++)h=k[c],a.attribute(h[0],h[1]);a.openTagClose(l,this.isEmpty);this.writeChildrenHtml(a);this.isEmpty||a.closeTag(l)},writeChildrenHtml:b.writeChildrenHtml,replaceWithChildren:function(){for(var a=this.children,b=a.length;b;)a[--b].insertAfter(this);this.remove()},forEach:b.forEach,
getFirst:function(b){if(!b)return this.children.length?this.children[0]:null;"function"!=typeof b&&(b=a(b));for(var g=0,e=this.children.length;g<e;++g)if(b(this.children[g]))return this.children[g];return null},getHtml:function(){var a=new CKEDITOR.htmlParser.basicWriter;this.writeChildrenHtml(a);return a.getHtml()},setHtml:function(a){a=this.children=CKEDITOR.htmlParser.fragment.fromHtml(a).children;for(var b=0,e=a.length;b<e;++b)a[b].parent=this},getOuterHtml:function(){var a=new CKEDITOR.htmlParser.basicWriter;
this.writeHtml(a);return a.getHtml()},split:function(a){for(var b=this.children.splice(a,this.children.length-a),e=this.clone(),k=0;k<b.length;++k)b[k].parent=e;e.children=b;b[0]&&(b[0].previous=null);0<a&&(this.children[a-1].next=null);this.parent.add(e,this.getIndex()+1);return e},find:function(a,b){void 0===b&&(b=!1);var e=[],k;for(k=0;k<this.children.length;k++){var h=this.children[k];"function"==typeof a&&a(h)?e.push(h):"string"==typeof a&&h.name===a&&e.push(h);b&&h.find&&(e=e.concat(h.find(a,
b)))}return e},addClass:function(a){if(!this.hasClass(a)){var b=this.attributes["class"]||"";this.attributes["class"]=b+(b?" ":"")+a}},removeClass:function(a){var b=this.attributes["class"];b&&((b=CKEDITOR.tools.trim(b.replace(new RegExp("(?:\\s+|^)"+a+"(?:\\s+|$)")," ")))?this.attributes["class"]=b:delete this.attributes["class"])},hasClass:function(a){var b=this.attributes["class"];return b?(new RegExp("(?:^|\\s)"+a+"(?\x3d\\s|$)")).test(b):!1},getFilterContext:function(a){var b=[];a||(a={off:!1,
nonEditable:!1,nestedEditable:!1});a.off||"off"!=this.attributes["data-cke-processor"]||b.push("off",!0);a.nonEditable||"false"!=this.attributes.contenteditable?a.nonEditable&&!a.nestedEditable&&"true"==this.attributes.contenteditable&&b.push("nestedEditable",!0):b.push("nonEditable",!0);if(b.length){a=CKEDITOR.tools.copy(a);for(var e=0;e<b.length;e+=2)a[b[e]]=b[e+1]}return a}},!0)}(),function(){var a=/{([^}]+)}/g;CKEDITOR.template=function(a){this.source=String(a)};CKEDITOR.template.prototype.output=
function(e,b){var d=this.source.replace(a,function(a,b){return void 0!==e[b]?e[b]:a});return b?b.push(d):d}}(),delete CKEDITOR.loadFullCore,CKEDITOR.instances={},CKEDITOR.document=new CKEDITOR.dom.document(document),CKEDITOR.add=function(a){CKEDITOR.instances[a.name]=a;a.on("focus",function(){CKEDITOR.currentInstance!=a&&(CKEDITOR.currentInstance=a,CKEDITOR.fire("currentInstance"))});a.on("blur",function(){CKEDITOR.currentInstance==a&&(CKEDITOR.currentInstance=null,CKEDITOR.fire("currentInstance"))});
CKEDITOR.fire("instance",null,a)},CKEDITOR.remove=function(a){delete CKEDITOR.instances[a.name]},function(){var a={};CKEDITOR.addTemplate=function(e,b){var d=a[e];if(d)return d;d={name:e,source:b};CKEDITOR.fire("template",d);return a[e]=new CKEDITOR.template(d.source)};CKEDITOR.getTemplate=function(e){return a[e]}}(),function(){var a=[];CKEDITOR.addCss=function(e){a.push(e)};CKEDITOR.getCss=function(){return a.join("\n")}}(),CKEDITOR.on("instanceDestroyed",function(){CKEDITOR.tools.isEmpty(this.instances)&&
CKEDITOR.fire("reset")}),CKEDITOR.TRISTATE_ON=1,CKEDITOR.TRISTATE_OFF=2,CKEDITOR.TRISTATE_DISABLED=0,function(){CKEDITOR.inline=function(a,e){if(!CKEDITOR.env.isCompatible)return null;a=CKEDITOR.dom.element.get(a);if(a.getEditor())throw'The editor instance "'+a.getEditor().name+'" is already attached to the provided element.';var b=new CKEDITOR.editor(e,a,CKEDITOR.ELEMENT_MODE_INLINE),d=a.is("textarea")?a:null;d?(b.setData(d.getValue(),null,!0),a=CKEDITOR.dom.element.createFromHtml('\x3cdiv contenteditable\x3d"'+
!!b.readOnly+'" class\x3d"cke_textarea_inline"\x3e'+d.getValue()+"\x3c/div\x3e",CKEDITOR.document),a.insertAfter(d),d.hide(),d.$.form&&b._attachToForm()):b.setData(a.getHtml(),null,!0);b.on("loaded",function(){b.fire("uiReady");b.editable(a);b.container=a;b.ui.contentsElement=a;b.setData(b.getData(1));b.resetDirty();b.fire("contentDom");b.mode="wysiwyg";b.fire("mode");b.status="ready";b.fireOnce("instanceReady");CKEDITOR.fire("instanceReady",null,b)},null,null,1E4);b.on("destroy",function(){d&&(b.container.clearCustomData(),
b.container.remove(),d.show());b.element.clearCustomData();delete b.element});return b};CKEDITOR.inlineAll=function(){var a,e,b;for(b in CKEDITOR.dtd.$editable)for(var d=CKEDITOR.document.getElementsByTag(b),g=0,l=d.count();g<l;g++)a=d.getItem(g),"true"==a.getAttribute("contenteditable")&&(e={element:a,config:{}},!1!==CKEDITOR.fire("inline",e)&&CKEDITOR.inline(a,e.config))};CKEDITOR.domReady(function(){!CKEDITOR.disableAutoInline&&CKEDITOR.inlineAll()})}(),CKEDITOR.replaceClass="ckeditor",function(){function a(a,
g,l,k){if(!CKEDITOR.env.isCompatible)return null;a=CKEDITOR.dom.element.get(a);if(a.getEditor())throw'The editor instance "'+a.getEditor().name+'" is already attached to the provided element.';var h=new CKEDITOR.editor(g,a,k);k==CKEDITOR.ELEMENT_MODE_REPLACE&&(a.setStyle("visibility","hidden"),h._.required=a.hasAttribute("required"),a.removeAttribute("required"));l&&h.setData(l,null,!0);h.on("loaded",function(){b(h);k==CKEDITOR.ELEMENT_MODE_REPLACE&&h.config.autoUpdateElement&&a.$.form&&h._attachToForm();
h.setMode(h.config.startupMode,function(){h.resetDirty();h.status="ready";h.fireOnce("instanceReady");CKEDITOR.fire("instanceReady",null,h)})});h.on("destroy",e);return h}function e(){var a=this.container,b=this.element;a&&(a.clearCustomData(),a.remove());b&&(b.clearCustomData(),this.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE&&(b.show(),this._.required&&b.setAttribute("required","required")),delete this.element)}function b(a){var b=a.name,e=a.element,k=a.elementMode,h=a.fire("uiSpace",{space:"top",
html:""}).html,c=a.fire("uiSpace",{space:"bottom",html:""}).html,m=new CKEDITOR.template('\x3c{outerEl} id\x3d"cke_{name}" class\x3d"{id} cke cke_reset cke_chrome cke_editor_{name} cke_{langDir} '+CKEDITOR.env.cssClass+'" dir\x3d"{langDir}" lang\x3d"{langCode}" role\x3d"application"'+(a.title?' aria-labelledby\x3d"cke_{name}_arialbl"':"")+"\x3e"+(a.title?'\x3cspan id\x3d"cke_{name}_arialbl" class\x3d"cke_voice_label"\x3e{voiceLabel}\x3c/span\x3e':"")+'\x3c{outerEl} class\x3d"cke_inner cke_reset" role\x3d"presentation"\x3e{topHtml}\x3c{outerEl} id\x3d"{contentId}" class\x3d"cke_contents cke_reset" role\x3d"presentation"\x3e\x3c/{outerEl}\x3e{bottomHtml}\x3c/{outerEl}\x3e\x3c/{outerEl}\x3e'),
b=CKEDITOR.dom.element.createFromHtml(m.output({id:a.id,name:b,langDir:a.lang.dir,langCode:a.langCode,voiceLabel:a.title,topHtml:h?'\x3cspan id\x3d"'+a.ui.spaceId("top")+'" class\x3d"cke_top cke_reset_all" role\x3d"presentation" style\x3d"height:auto"\x3e'+h+"\x3c/span\x3e":"",contentId:a.ui.spaceId("contents"),bottomHtml:c?'\x3cspan id\x3d"'+a.ui.spaceId("bottom")+'" class\x3d"cke_bottom cke_reset_all" role\x3d"presentation"\x3e'+c+"\x3c/span\x3e":"",outerEl:CKEDITOR.env.ie?"span":"div"}));k==CKEDITOR.ELEMENT_MODE_REPLACE?
(e.hide(),b.insertAfter(e)):e.append(b);a.container=b;a.ui.contentsElement=a.ui.space("contents");h&&a.ui.space("top").unselectable();c&&a.ui.space("bottom").unselectable();e=a.config.width;k=a.config.height;e&&b.setStyle("width",CKEDITOR.tools.cssLength(e));k&&a.ui.space("contents").setStyle("height",CKEDITOR.tools.cssLength(k));b.disableContextMenu();CKEDITOR.env.webkit&&b.on("focus",function(){a.focus()});a.fireOnce("uiReady")}CKEDITOR.replace=function(b,g){return a(b,g,null,CKEDITOR.ELEMENT_MODE_REPLACE)};
CKEDITOR.appendTo=function(b,g,e){return a(b,g,e,CKEDITOR.ELEMENT_MODE_APPENDTO)};CKEDITOR.replaceAll=function(){for(var a=document.getElementsByTagName("textarea"),b=0;b<a.length;b++){var e=null,k=a[b];if(k.name||k.id){if("string"==typeof arguments[0]){if(!(new RegExp("(?:^|\\s)"+arguments[0]+"(?:$|\\s)")).test(k.className))continue}else if("function"==typeof arguments[0]&&(e={},!1===arguments[0](k,e)))continue;this.replace(k,e)}}};CKEDITOR.editor.prototype.addMode=function(a,b){(this._.modes||(this._.modes=
{}))[a]=b};CKEDITOR.editor.prototype.setMode=function(a,b){var e=this,k=this._.modes;if(a!=e.mode&&k&&k[a]){e.fire("beforeSetMode",a);if(e.mode){var h=e.checkDirty(),k=e._.previousModeData,c,m=0;e.fire("beforeModeUnload");e.editable(0);e._.previousMode=e.mode;e._.previousModeData=c=e.getData(1);"source"==e.mode&&k==c&&(e.fire("lockSnapshot",{forceUpdate:!0}),m=1);e.ui.space("contents").setHtml("");e.mode=""}else e._.previousModeData=e.getData(1);this._.modes[a](function(){e.mode=a;void 0!==h&&!h&&
e.resetDirty();m?e.fire("unlockSnapshot"):"wysiwyg"==a&&e.fire("saveSnapshot");setTimeout(function(){e.fire("mode");b&&b.call(e)},0)})}};CKEDITOR.editor.prototype.resize=function(a,b,e,k){var h=this.container,c=this.ui.space("contents"),m=CKEDITOR.env.webkit&&this.document&&this.document.getWindow().$.frameElement;k=k?this.container.getFirst(function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasClass("cke_inner")}):h;k.setSize("width",a,!0);m&&(m.style.width="1%");var f=(k.$.offsetHeight||0)-(c.$.clientHeight||
0),h=Math.max(b-(e?0:f),0);b=e?b+f:b;c.setStyle("height",h+"px");m&&(m.style.width="100%");this.fire("resize",{outerHeight:b,contentsHeight:h,outerWidth:a||k.getSize("width")})};CKEDITOR.editor.prototype.getResizable=function(a){return a?this.ui.space("contents"):this.container};CKEDITOR.domReady(function(){CKEDITOR.replaceClass&&CKEDITOR.replaceAll(CKEDITOR.replaceClass)})}(),CKEDITOR.config.startupMode="wysiwyg",function(){function a(a){var b=a.editor,c=a.data.path,f=c.blockLimit,g=a.data.selection,
h=g.getRanges()[0],m;if(CKEDITOR.env.gecko||CKEDITOR.env.ie&&CKEDITOR.env.needsBrFiller)if(g=e(g,c))g.appendBogus(),m=CKEDITOR.env.ie;k(b,c.block,f)&&h.collapsed&&!h.getCommonAncestor().isReadOnly()&&(c=h.clone(),c.enlarge(CKEDITOR.ENLARGE_BLOCK_CONTENTS),f=new CKEDITOR.dom.walker(c),f.guard=function(a){return!d(a)||a.type==CKEDITOR.NODE_COMMENT||a.isReadOnly()},!f.checkForward()||c.checkStartOfBlock()&&c.checkEndOfBlock())&&(b=h.fixBlock(!0,b.activeEnterMode==CKEDITOR.ENTER_DIV?"div":"p"),CKEDITOR.env.needsBrFiller||
(b=b.getFirst(d))&&b.type==CKEDITOR.NODE_TEXT&&CKEDITOR.tools.trim(b.getText()).match(/^(?:&nbsp;|\xa0)$/)&&b.remove(),m=1,a.cancel());m&&h.select()}function e(a,b){if(a.isFake)return 0;var c=b.block||b.blockLimit,f=c&&c.getLast(d);if(!(!c||!c.isBlockBoundary()||f&&f.type==CKEDITOR.NODE_ELEMENT&&f.isBlockBoundary()||c.is("pre")||c.getBogus()))return c}function b(a){var b=a.data.getTarget();b.is("input")&&(b=b.getAttribute("type"),"submit"!=b&&"reset"!=b||a.data.preventDefault())}function d(a){return f(a)&&
n(a)}function g(a,b){return function(c){var f=c.data.$.toElement||c.data.$.fromElement||c.data.$.relatedTarget;(f=f&&f.nodeType==CKEDITOR.NODE_ELEMENT?new CKEDITOR.dom.element(f):null)&&(b.equals(f)||b.contains(f))||a.call(this,c)}}function l(a){function b(a){return function(b,f){f&&b.type==CKEDITOR.NODE_ELEMENT&&b.is(g)&&(c=b);if(!(f||!d(b)||a&&q(b)))return!1}}var c,f=a.getRanges()[0];a=a.root;var g={table:1,ul:1,ol:1,dl:1};if(f.startPath().contains(g)){var e=f.clone();e.collapse(1);e.setStartAt(a,
CKEDITOR.POSITION_AFTER_START);a=new CKEDITOR.dom.walker(e);a.guard=b();a.checkBackward();if(c)return e=f.clone(),e.collapse(),e.setEndAt(c,CKEDITOR.POSITION_AFTER_END),a=new CKEDITOR.dom.walker(e),a.guard=b(!0),c=!1,a.checkForward(),c}return null}function k(a,b,c){return!1!==a.config.autoParagraph&&a.activeEnterMode!=CKEDITOR.ENTER_BR&&(a.editable().equals(c)&&!b||b&&"true"==b.getAttribute("contenteditable"))}function h(a){return a.activeEnterMode!=CKEDITOR.ENTER_BR&&!1!==a.config.autoParagraph?
a.activeEnterMode==CKEDITOR.ENTER_DIV?"div":"p":!1}function c(a){var b=a.editor;b.getSelection().scrollIntoView();setTimeout(function(){b.fire("saveSnapshot")},0)}function m(a,b,c){var f=a.getCommonAncestor(b);for(b=a=c?b:a;(a=a.getParent())&&!f.equals(a)&&1==a.getChildCount();)b=a;b.remove()}var f,n,p,q,v,y,r,t,w,A;CKEDITOR.editable=CKEDITOR.tools.createClass({base:CKEDITOR.dom.element,$:function(a,b){this.base(b.$||b);this.editor=a;this.status="unloaded";this.hasFocus=!1;this.setup()},proto:{focus:function(){var a;
if(CKEDITOR.env.webkit&&!this.hasFocus&&(a=this.editor._.previousActive||this.getDocument().getActive(),this.contains(a))){a.focus();return}CKEDITOR.env.edge&&14<CKEDITOR.env.version&&!this.hasFocus&&this.getDocument().equals(CKEDITOR.document)&&(this.editor._.previousScrollTop=this.$.scrollTop);try{if(!CKEDITOR.env.ie||CKEDITOR.env.edge&&14<CKEDITOR.env.version||!this.getDocument().equals(CKEDITOR.document))if(CKEDITOR.env.chrome){var b=this.$.scrollTop;this.$.focus();this.$.scrollTop=b}else this.$.focus();
else this.$.setActive()}catch(c){if(!CKEDITOR.env.ie)throw c;}CKEDITOR.env.safari&&!this.isInline()&&(a=CKEDITOR.document.getActive(),a.equals(this.getWindow().getFrame())||this.getWindow().focus())},on:function(a,b){var c=Array.prototype.slice.call(arguments,0);CKEDITOR.env.ie&&/^focus|blur$/.exec(a)&&(a="focus"==a?"focusin":"focusout",b=g(b,this),c[0]=a,c[1]=b);return CKEDITOR.dom.element.prototype.on.apply(this,c)},attachListener:function(a){!this._.listeners&&(this._.listeners=[]);var b=Array.prototype.slice.call(arguments,
1),b=a.on.apply(a,b);this._.listeners.push(b);return b},clearListeners:function(){var a=this._.listeners;try{for(;a.length;)a.pop().removeListener()}catch(b){}},restoreAttrs:function(){var a=this._.attrChanges,b,c;for(c in a)a.hasOwnProperty(c)&&(b=a[c],null!==b?this.setAttribute(c,b):this.removeAttribute(c))},attachClass:function(a){var b=this.getCustomData("classes");this.hasClass(a)||(!b&&(b=[]),b.push(a),this.setCustomData("classes",b),this.addClass(a))},changeAttr:function(a,b){var c=this.getAttribute(a);
b!==c&&(!this._.attrChanges&&(this._.attrChanges={}),a in this._.attrChanges||(this._.attrChanges[a]=c),this.setAttribute(a,b))},insertText:function(a){this.editor.focus();this.insertHtml(this.transformPlainTextToHtml(a),"text")},transformPlainTextToHtml:function(a){var b=this.editor.getSelection().getStartElement().hasAscendant("pre",!0)?CKEDITOR.ENTER_BR:this.editor.activeEnterMode;return CKEDITOR.tools.transformPlainTextToHtml(a,b)},insertHtml:function(a,b,f){var d=this.editor;d.focus();d.fire("saveSnapshot");
f||(f=d.getSelection().getRanges()[0]);y(this,b||"html",a,f);f.select();c(this);this.editor.fire("afterInsertHtml",{})},insertHtmlIntoRange:function(a,b,c){y(this,c||"html",a,b);this.editor.fire("afterInsertHtml",{intoRange:b})},insertElement:function(a,b){var f=this.editor;f.focus();f.fire("saveSnapshot");var g=f.activeEnterMode,f=f.getSelection(),e=a.getName(),e=CKEDITOR.dtd.$block[e];b||(b=f.getRanges()[0]);this.insertElementIntoRange(a,b)&&(b.moveToPosition(a,CKEDITOR.POSITION_AFTER_END),e&&((e=
a.getNext(function(a){return d(a)&&!q(a)}))&&e.type==CKEDITOR.NODE_ELEMENT&&e.is(CKEDITOR.dtd.$block)?e.getDtd()["#"]?b.moveToElementEditStart(e):b.moveToElementEditEnd(a):e||g==CKEDITOR.ENTER_BR||(e=b.fixBlock(!0,g==CKEDITOR.ENTER_DIV?"div":"p"),b.moveToElementEditStart(e))));f.selectRanges([b]);c(this)},insertElementIntoSelection:function(a){this.insertElement(a)},insertElementIntoRange:function(a,b){var c=this.editor,f=c.config.enterMode,d=a.getName(),g=CKEDITOR.dtd.$block[d];if(b.checkReadOnly())return!1;
b.deleteContents(1);b.startContainer.type==CKEDITOR.NODE_ELEMENT&&(b.startContainer.is({tr:1,table:1,tbody:1,thead:1,tfoot:1})?r(b):b.startContainer.is(CKEDITOR.dtd.$list)&&t(b));var e,h;if(g)for(;(e=b.getCommonAncestor(0,1))&&(h=CKEDITOR.dtd[e.getName()])&&(!h||!h[d]);)e.getName()in CKEDITOR.dtd.span?b.splitElement(e):b.checkStartOfBlock()&&b.checkEndOfBlock()?(b.setStartBefore(e),b.collapse(!0),e.remove()):b.splitBlock(f==CKEDITOR.ENTER_DIV?"div":"p",c.editable());b.insertNode(a);return!0},setData:function(a,
b){b||(a=this.editor.dataProcessor.toHtml(a));this.setHtml(a);this.fixInitialSelection();"unloaded"==this.status&&(this.status="ready");this.editor.fire("dataReady")},getData:function(a){var b=this.getHtml();a||(b=this.editor.dataProcessor.toDataFormat(b));return b},setReadOnly:function(a){this.setAttribute("contenteditable",!a)},detach:function(){this.removeClass("cke_editable");this.status="detached";var a=this.editor;this._.detach();delete a.document;delete a.window},isInline:function(){return this.getDocument().equals(CKEDITOR.document)},
fixInitialSelection:function(){function a(){var b=c.getDocument().$,f=b.getSelection(),d;a:if(f.anchorNode&&f.anchorNode==c.$)d=!0;else{if(CKEDITOR.env.webkit&&(d=c.getDocument().getActive())&&d.equals(c)&&!f.anchorNode){d=!0;break a}d=void 0}d&&(d=new CKEDITOR.dom.range(c),d.moveToElementEditStart(c),b=b.createRange(),b.setStart(d.startContainer.$,d.startOffset),b.collapse(!0),f.removeAllRanges(),f.addRange(b))}function b(){var a=c.getDocument().$,f=a.selection,d=c.getDocument().getActive();"None"==
f.type&&d.equals(c)&&(f=new CKEDITOR.dom.range(c),a=a.body.createTextRange(),f.moveToElementEditStart(c),f=f.startContainer,f.type!=CKEDITOR.NODE_ELEMENT&&(f=f.getParent()),a.moveToElementText(f.$),a.collapse(!0),a.select())}var c=this;if(CKEDITOR.env.ie&&(9>CKEDITOR.env.version||CKEDITOR.env.quirks))this.hasFocus&&(this.focus(),b());else if(this.hasFocus)this.focus(),a();else this.once("focus",function(){a()},null,null,-999)},getHtmlFromRange:function(a){if(a.collapsed)return new CKEDITOR.dom.documentFragment(a.document);
a={doc:this.getDocument(),range:a.clone()};w.eol.detect(a,this);w.bogus.exclude(a);w.cell.shrink(a);a.fragment=a.range.cloneContents();w.tree.rebuild(a,this);w.eol.fix(a,this);return new CKEDITOR.dom.documentFragment(a.fragment.$)},extractHtmlFromRange:function(a,b){var c=A,f={range:a,doc:a.document},d=this.getHtmlFromRange(a);if(a.collapsed)return a.optimize(),d;a.enlarge(CKEDITOR.ENLARGE_INLINE,1);c.table.detectPurge(f);f.bookmark=a.createBookmark();delete f.range;var g=this.editor.createRange();
g.moveToPosition(f.bookmark.startNode,CKEDITOR.POSITION_BEFORE_START);f.targetBookmark=g.createBookmark();c.list.detectMerge(f,this);c.table.detectRanges(f,this);c.block.detectMerge(f,this);f.tableContentsRanges?(c.table.deleteRanges(f),a.moveToBookmark(f.bookmark),f.range=a):(a.moveToBookmark(f.bookmark),f.range=a,a.extractContents(c.detectExtractMerge(f)));a.moveToBookmark(f.targetBookmark);a.optimize();c.fixUneditableRangePosition(a);c.list.merge(f,this);c.table.purge(f,this);c.block.merge(f,this);
if(b){c=a.startPath();if(f=a.checkStartOfBlock()&&a.checkEndOfBlock()&&c.block&&!a.root.equals(c.block)){a:{var f=c.block.getElementsByTag("span"),g=0,e;if(f)for(;e=f.getItem(g++);)if(!n(e)){f=!0;break a}f=!1}f=!f}f&&(a.moveToPosition(c.block,CKEDITOR.POSITION_BEFORE_START),c.block.remove())}else c.autoParagraph(this.editor,a),p(a.startContainer)&&a.startContainer.appendBogus();a.startContainer.mergeSiblings();return d},setup:function(){var a=this.editor;this.attachListener(a,"beforeGetData",function(){var b=
this.getData();this.is("textarea")||!1!==a.config.ignoreEmptyParagraph&&(b=b.replace(v,function(a,b){return b}));a.setData(b,null,1)},this);this.attachListener(a,"getSnapshot",function(a){a.data=this.getData(1)},this);this.attachListener(a,"afterSetData",function(){this.setData(a.getData(1))},this);this.attachListener(a,"loadSnapshot",function(a){this.setData(a.data,1)},this);this.attachListener(a,"beforeFocus",function(){var b=a.getSelection();(b=b&&b.getNative())&&"Control"==b.type||this.focus()},
this);this.attachListener(a,"insertHtml",function(a){this.insertHtml(a.data.dataValue,a.data.mode,a.data.range)},this);this.attachListener(a,"insertElement",function(a){this.insertElement(a.data)},this);this.attachListener(a,"insertText",function(a){this.insertText(a.data)},this);this.setReadOnly(a.readOnly);this.attachClass("cke_editable");a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?this.attachClass("cke_editable_inline"):a.elementMode!=CKEDITOR.ELEMENT_MODE_REPLACE&&a.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO||
this.attachClass("cke_editable_themed");this.attachClass("cke_contents_"+a.config.contentsLangDirection);a.keystrokeHandler.blockedKeystrokes[8]=+a.readOnly;a.keystrokeHandler.attach(this);this.on("blur",function(){this.hasFocus=!1},null,null,-1);this.on("focus",function(){this.hasFocus=!0},null,null,-1);if(CKEDITOR.env.webkit)this.on("scroll",function(){a._.previousScrollTop=a.editable().$.scrollTop},null,null,-1);if(CKEDITOR.env.edge&&14<CKEDITOR.env.version){var c=function(){var b=a.editable();
null!=a._.previousScrollTop&&b.getDocument().equals(CKEDITOR.document)&&(b.$.scrollTop=a._.previousScrollTop,a._.previousScrollTop=null,this.removeListener("scroll",c))};this.on("scroll",c)}a.focusManager.add(this);this.equals(CKEDITOR.document.getActive())&&(this.hasFocus=!0,a.once("contentDom",function(){a.focusManager.focus(this)},this));this.isInline()&&this.changeAttr("tabindex",a.tabIndex);if(!this.is("textarea")){a.document=this.getDocument();a.window=this.getWindow();var g=a.document;this.changeAttr("spellcheck",
!a.config.disableNativeSpellChecker);var e=a.config.contentsLangDirection;this.getDirection(1)!=e&&this.changeAttr("dir",e);var h=CKEDITOR.getCss();if(h){var e=g.getHead(),k=e.getCustomData("stylesheet");k?h!=k.getText()&&(CKEDITOR.env.ie&&9>CKEDITOR.env.version?k.$.styleSheet.cssText=h:k.setText(h)):(h=g.appendStyleText(h),h=new CKEDITOR.dom.element(h.ownerNode||h.owningElement),e.setCustomData("stylesheet",h),h.data("cke-temp",1))}e=g.getCustomData("stylesheet_ref")||0;g.setCustomData("stylesheet_ref",
e+1);this.setCustomData("cke_includeReadonly",!a.config.disableReadonlyStyling);this.attachListener(this,"click",function(a){a=a.data;var b=(new CKEDITOR.dom.elementPath(a.getTarget(),this)).contains("a");b&&2!=a.$.button&&b.isReadOnly()&&a.preventDefault()});var n={8:1,46:1};this.attachListener(a,"key",function(b){if(a.readOnly)return!0;var c=b.data.domEvent.getKey(),d;b=a.getSelection();if(0!==b.getRanges().length){if(c in n){var g,e=b.getRanges()[0],h=e.startPath(),m,k,r,c=8==c;CKEDITOR.env.ie&&
11>CKEDITOR.env.version&&(g=b.getSelectedElement())||(g=l(b))?(a.fire("saveSnapshot"),e.moveToPosition(g,CKEDITOR.POSITION_BEFORE_START),g.remove(),e.select(),a.fire("saveSnapshot"),d=1):e.collapsed&&((m=h.block)&&(r=m[c?"getPrevious":"getNext"](f))&&r.type==CKEDITOR.NODE_ELEMENT&&r.is("table")&&e[c?"checkStartOfBlock":"checkEndOfBlock"]()?(a.fire("saveSnapshot"),e[c?"checkEndOfBlock":"checkStartOfBlock"]()&&m.remove(),e["moveToElementEdit"+(c?"End":"Start")](r),e.select(),a.fire("saveSnapshot"),
d=1):h.blockLimit&&h.blockLimit.is("td")&&(k=h.blockLimit.getAscendant("table"))&&e.checkBoundaryOfElement(k,c?CKEDITOR.START:CKEDITOR.END)&&(r=k[c?"getPrevious":"getNext"](f))?(a.fire("saveSnapshot"),e["moveToElementEdit"+(c?"End":"Start")](r),e.checkStartOfBlock()&&e.checkEndOfBlock()?r.remove():e.select(),a.fire("saveSnapshot"),d=1):(k=h.contains(["td","th","caption"]))&&e.checkBoundaryOfElement(k,c?CKEDITOR.START:CKEDITOR.END)&&(d=1))}return!d}});a.blockless&&CKEDITOR.env.ie&&CKEDITOR.env.needsBrFiller&&
this.attachListener(this,"keyup",function(b){b.data.getKeystroke()in n&&!this.getFirst(d)&&(this.appendBogus(),b=a.createRange(),b.moveToPosition(this,CKEDITOR.POSITION_AFTER_START),b.select())});this.attachListener(this,"dblclick",function(b){if(a.readOnly)return!1;b={element:b.data.getTarget()};a.fire("doubleclick",b)});CKEDITOR.env.ie&&this.attachListener(this,"click",b);CKEDITOR.env.ie&&!CKEDITOR.env.edge||this.attachListener(this,"mousedown",function(b){var c=b.data.getTarget();c.is("img","hr",
"input","textarea","select")&&!c.isReadOnly()&&(a.getSelection().selectElement(c),c.is("input","textarea","select")&&b.data.preventDefault())});CKEDITOR.env.edge&&this.attachListener(this,"mouseup",function(b){(b=b.data.getTarget())&&b.is("img")&&a.getSelection().selectElement(b)});CKEDITOR.env.gecko&&this.attachListener(this,"mouseup",function(b){if(2==b.data.$.button&&(b=b.data.getTarget(),!b.getOuterHtml().replace(v,""))){var c=a.createRange();c.moveToElementEditStart(b);c.select(!0)}});CKEDITOR.env.webkit&&
(this.attachListener(this,"click",function(a){a.data.getTarget().is("input","select")&&a.data.preventDefault()}),this.attachListener(this,"mouseup",function(a){a.data.getTarget().is("input","textarea")&&a.data.preventDefault()}));CKEDITOR.env.webkit&&this.attachListener(a,"key",function(b){if(a.readOnly)return!0;var c=b.data.domEvent.getKey();if(c in n&&(b=a.getSelection(),0!==b.getRanges().length)){var c=8==c,f=b.getRanges()[0];b=f.startPath();if(f.collapsed)a:{var d=b.block;if(d&&f[c?"checkStartOfBlock":
"checkEndOfBlock"]()&&f.moveToClosestEditablePosition(d,!c)&&f.collapsed){if(f.startContainer.type==CKEDITOR.NODE_ELEMENT){var g=f.startContainer.getChild(f.startOffset-(c?1:0));if(g&&g.type==CKEDITOR.NODE_ELEMENT&&g.is("hr")){a.fire("saveSnapshot");g.remove();b=!0;break a}}f=f.startPath().block;if(!f||f&&f.contains(d))b=void 0;else{a.fire("saveSnapshot");var e;(e=(c?f:d).getBogus())&&e.remove();e=a.getSelection();g=e.createBookmarks();(c?d:f).moveChildren(c?f:d,!1);b.lastElement.mergeSiblings();
m(d,f,!c);e.selectBookmarks(g);b=!0}}else b=!1}else c=f,e=b.block,f=c.endPath().block,e&&f&&!e.equals(f)?(a.fire("saveSnapshot"),(d=e.getBogus())&&d.remove(),c.enlarge(CKEDITOR.ENLARGE_INLINE),c.deleteContents(),f.getParent()&&(f.moveChildren(e,!1),b.lastElement.mergeSiblings(),m(e,f,!0)),c=a.getSelection().getRanges()[0],c.collapse(1),c.optimize(),""===c.startContainer.getHtml()&&c.startContainer.appendBogus(),c.select(),b=!0):b=!1;if(!b)return;a.getSelection().scrollIntoView();a.fire("saveSnapshot");
return!1}},this,null,100)}}},_:{detach:function(){this.editor.setData(this.editor.getData(),0,1);this.clearListeners();this.restoreAttrs();var a;if(a=this.removeCustomData("classes"))for(;a.length;)this.removeClass(a.pop());if(!this.is("textarea")){a=this.getDocument();var b=a.getHead();if(b.getCustomData("stylesheet")){var c=a.getCustomData("stylesheet_ref");--c?a.setCustomData("stylesheet_ref",c):(a.removeCustomData("stylesheet_ref"),b.removeCustomData("stylesheet").remove())}}this.editor.fire("contentDomUnload");
delete this.editor}}});CKEDITOR.editor.prototype.editable=function(a){var b=this._.editable;if(b&&a)return 0;arguments.length&&(b=this._.editable=a?a instanceof CKEDITOR.editable?a:new CKEDITOR.editable(this,a):(b&&b.detach(),null));return b};CKEDITOR.on("instanceLoaded",function(b){var c=b.editor;c.on("insertElement",function(a){a=a.data;a.type==CKEDITOR.NODE_ELEMENT&&(a.is("input")||a.is("textarea"))&&("false"!=a.getAttribute("contentEditable")&&a.data("cke-editable",a.hasAttribute("contenteditable")?
"true":"1"),a.setAttribute("contentEditable",!1))});c.on("selectionChange",function(b){if(!c.readOnly){var f=c.getSelection();f&&!f.isLocked&&(f=c.checkDirty(),c.fire("lockSnapshot"),a(b),c.fire("unlockSnapshot"),!f&&c.resetDirty())}})});CKEDITOR.on("instanceCreated",function(a){var b=a.editor;b.on("mode",function(){var a=b.editable();if(a&&a.isInline()){var c=b.title;a.changeAttr("role","textbox");a.changeAttr("aria-label",c);c&&a.changeAttr("title",c);var f=b.fire("ariaEditorHelpLabel",{}).label;
if(f&&(c=this.ui.space(this.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?"top":"contents"))){var d=CKEDITOR.tools.getNextId(),f=CKEDITOR.dom.element.createFromHtml('\x3cspan id\x3d"'+d+'" class\x3d"cke_voice_label"\x3e'+f+"\x3c/span\x3e");c.append(f);a.changeAttr("aria-describedby",d)}}})});CKEDITOR.addCss(".cke_editable{cursor:text}.cke_editable img,.cke_editable input,.cke_editable textarea{cursor:default}");f=CKEDITOR.dom.walker.whitespaces(!0);n=CKEDITOR.dom.walker.bookmark(!1,!0);p=CKEDITOR.dom.walker.empty();
q=CKEDITOR.dom.walker.bogus();v=/(^|<body\b[^>]*>)\s*<(p|div|address|h\d|center|pre)[^>]*>\s*(?:<br[^>]*>|&nbsp;|\u00A0|&#160;)?\s*(:?<\/\2>)?\s*(?=$|<\/body>)/gi;y=function(){function a(b){return b.type==CKEDITOR.NODE_ELEMENT}function b(c,f){var d,g,e,h,m=[],k=f.range.startContainer;d=f.range.startPath();for(var k=l[k.getName()],n=0,r=c.getChildren(),p=r.count(),w=-1,t=-1,F=0,z=d.contains(l.$list);n<p;++n)d=r.getItem(n),a(d)?(e=d.getName(),z&&e in CKEDITOR.dtd.$list?m=m.concat(b(d,f)):(h=!!k[e],
"br"!=e||!d.data("cke-eol")||n&&n!=p-1||(F=(g=n?m[n-1].node:r.getItem(n+1))&&(!a(g)||!g.is("br")),g=g&&a(g)&&l.$block[g.getName()]),-1!=w||h||(w=n),h||(t=n),m.push({isElement:1,isLineBreak:F,isBlock:d.isBlockBoundary(),hasBlockSibling:g,node:d,name:e,allowed:h}),g=F=0)):m.push({isElement:0,node:d,allowed:1});-1<w&&(m[w].firstNotAllowed=1);-1<t&&(m[t].lastNotAllowed=1);return m}function c(b,f){var d=[],g=b.getChildren(),e=g.count(),h,m=0,k=l[f],n=!b.is(l.$inline)||b.is("br");for(n&&d.push(" ");m<e;m++)h=
g.getItem(m),a(h)&&!h.is(k)?d=d.concat(c(h,f)):d.push(h);n&&d.push(" ");return d}function f(b){return a(b.startContainer)&&b.startContainer.getChild(b.startOffset-1)}function g(b){return b&&a(b)&&(b.is(l.$removeEmpty)||b.is("a")&&!b.isBlockBoundary())}function e(b,c,f,d){var g=b.clone(),h,m;g.setEndAt(c,CKEDITOR.POSITION_BEFORE_END);(h=(new CKEDITOR.dom.walker(g)).next())&&a(h)&&n[h.getName()]&&(m=h.getPrevious())&&a(m)&&!m.getParent().equals(b.startContainer)&&f.contains(m)&&d.contains(h)&&h.isIdentical(m)&&
(h.moveChildren(m),h.remove(),e(b,c,f,d))}function m(b,c){function f(b,c){if(c.isBlock&&c.isElement&&!c.node.is("br")&&a(b)&&b.is("br"))return b.remove(),1}var d=c.endContainer.getChild(c.endOffset),g=c.endContainer.getChild(c.endOffset-1);d&&f(d,b[b.length-1]);g&&f(g,b[0])&&(c.setEnd(c.endContainer,c.endOffset-1),c.collapse())}var l=CKEDITOR.dtd,n={p:1,div:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1,ul:1,ol:1,li:1,pre:1,dl:1,blockquote:1},r={p:1,div:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1},p=CKEDITOR.tools.extend({},
l.$inline);delete p.br;return function(n,D,w,t){var v=n.editor,J=!1;"unfiltered_html"==D&&(D="html",J=!0);if(!t.checkReadOnly()){var A=(new CKEDITOR.dom.elementPath(t.startContainer,t.root)).blockLimit||t.root;n={type:D,dontFilter:J,editable:n,editor:v,range:t,blockLimit:A,mergeCandidates:[],zombies:[]};D=n.range;t=n.mergeCandidates;var q,y;"text"==n.type&&D.shrink(CKEDITOR.SHRINK_ELEMENT,!0,!1)&&(q=CKEDITOR.dom.element.createFromHtml("\x3cspan\x3e\x26nbsp;\x3c/span\x3e",D.document),D.insertNode(q),
D.setStartAfter(q));J=new CKEDITOR.dom.elementPath(D.startContainer);n.endPath=A=new CKEDITOR.dom.elementPath(D.endContainer);if(!D.collapsed){var v=A.block||A.blockLimit,da=D.getCommonAncestor();v&&!v.equals(da)&&!v.contains(da)&&D.checkEndOfBlock()&&n.zombies.push(v);D.deleteContents()}for(;(y=f(D))&&a(y)&&y.isBlockBoundary()&&J.contains(y);)D.moveToPosition(y,CKEDITOR.POSITION_BEFORE_END);e(D,n.blockLimit,J,A);q&&(D.setEndBefore(q),D.collapse(),q.remove());q=D.startPath();if(v=q.contains(g,!1,
1))D.splitElement(v),n.inlineStylesRoot=v,n.inlineStylesPeak=q.lastElement;q=D.createBookmark();(v=q.startNode.getPrevious(d))&&a(v)&&g(v)&&t.push(v);(v=q.startNode.getNext(d))&&a(v)&&g(v)&&t.push(v);for(v=q.startNode;(v=v.getParent())&&g(v);)t.push(v);D.moveToBookmark(q);if(q=w){q=n.range;if("text"==n.type&&n.inlineStylesRoot){y=n.inlineStylesPeak;D=y.getDocument().createText("{cke-peak}");for(t=n.inlineStylesRoot.getParent();!y.equals(t);)D=D.appendTo(y.clone()),y=y.getParent();w=D.getOuterHtml().split("{cke-peak}").join(w)}y=
n.blockLimit.getName();if(/^\s+|\s+$/.test(w)&&"span"in CKEDITOR.dtd[y]){var P='\x3cspan data-cke-marker\x3d"1"\x3e\x26nbsp;\x3c/span\x3e';w=P+w+P}w=n.editor.dataProcessor.toHtml(w,{context:null,fixForBody:!1,protectedWhitespaces:!!P,dontFilter:n.dontFilter,filter:n.editor.activeFilter,enterMode:n.editor.activeEnterMode});y=q.document.createElement("body");y.setHtml(w);P&&(y.getFirst().remove(),y.getLast().remove());if((P=q.startPath().block)&&(1!=P.getChildCount()||!P.getBogus()))a:{var Q;if(1==
y.getChildCount()&&a(Q=y.getFirst())&&Q.is(r)&&!Q.hasAttribute("contenteditable")){P=Q.getElementsByTag("*");q=0;for(t=P.count();q<t;q++)if(D=P.getItem(q),!D.is(p))break a;Q.moveChildren(Q.getParent(1));Q.remove()}}n.dataWrapper=y;q=w}if(q){Q=n.range;q=Q.document;var O;y=n.blockLimit;t=0;var U,P=[],T,I;w=v=0;var W,aa;D=Q.startContainer;var J=n.endPath.elements[0],ba,A=J.getPosition(D),da=!!J.getCommonAncestor(D)&&A!=CKEDITOR.POSITION_IDENTICAL&&!(A&CKEDITOR.POSITION_CONTAINS+CKEDITOR.POSITION_IS_CONTAINED);
D=b(n.dataWrapper,n);for(m(D,Q);t<D.length;t++){A=D[t];if(O=A.isLineBreak){O=Q;W=y;var Y=void 0,ca=void 0;A.hasBlockSibling?O=1:(Y=O.startContainer.getAscendant(l.$block,1))&&Y.is({div:1,p:1})?(ca=Y.getPosition(W),ca==CKEDITOR.POSITION_IDENTICAL||ca==CKEDITOR.POSITION_CONTAINS?O=0:(W=O.splitElement(Y),O.moveToPosition(W,CKEDITOR.POSITION_AFTER_START),O=1)):O=0}if(O)w=0<t;else{O=Q.startPath();!A.isBlock&&k(n.editor,O.block,O.blockLimit)&&(I=h(n.editor))&&(I=q.createElement(I),I.appendBogus(),Q.insertNode(I),
CKEDITOR.env.needsBrFiller&&(U=I.getBogus())&&U.remove(),Q.moveToPosition(I,CKEDITOR.POSITION_BEFORE_END));if((O=Q.startPath().block)&&!O.equals(T)){if(U=O.getBogus())U.remove(),P.push(O);T=O}A.firstNotAllowed&&(v=1);if(v&&A.isElement){O=Q.startContainer;for(W=null;O&&!l[O.getName()][A.name];){if(O.equals(y)){O=null;break}W=O;O=O.getParent()}if(O)W&&(aa=Q.splitElement(W),n.zombies.push(aa),n.zombies.push(W));else{W=y.getName();ba=!t;O=t==D.length-1;W=c(A.node,W);for(var Y=[],ca=W.length,ea=0,ha=void 0,
ia=0,fa=-1;ea<ca;ea++)ha=W[ea]," "==ha?(ia||ba&&!ea||(Y.push(new CKEDITOR.dom.text(" ")),fa=Y.length),ia=1):(Y.push(ha),ia=0);O&&fa==Y.length&&Y.pop();ba=Y}}if(ba){for(;O=ba.pop();)Q.insertNode(O);ba=0}else Q.insertNode(A.node);A.lastNotAllowed&&t<D.length-1&&((aa=da?J:aa)&&Q.setEndAt(aa,CKEDITOR.POSITION_AFTER_START),v=0);Q.collapse()}}1!=D.length?U=!1:(U=D[0],U=U.isElement&&"false"==U.node.getAttribute("contenteditable"));U&&(w=!0,O=D[0].node,Q.setStartAt(O,CKEDITOR.POSITION_BEFORE_START),Q.setEndAt(O,
CKEDITOR.POSITION_AFTER_END));n.dontMoveCaret=w;n.bogusNeededBlocks=P}U=n.range;var ga;aa=n.bogusNeededBlocks;for(ba=U.createBookmark();T=n.zombies.pop();)T.getParent()&&(I=U.clone(),I.moveToElementEditStart(T),I.removeEmptyBlocksAtEnd());if(aa)for(;T=aa.pop();)CKEDITOR.env.needsBrFiller?T.appendBogus():T.append(U.document.createText(" "));for(;T=n.mergeCandidates.pop();)T.mergeSiblings();U.moveToBookmark(ba);if(!n.dontMoveCaret){for(T=f(U);T&&a(T)&&!T.is(l.$empty);){if(T.isBlockBoundary())U.moveToPosition(T,
CKEDITOR.POSITION_BEFORE_END);else{if(g(T)&&T.getHtml().match(/(\s|&nbsp;)$/g)){ga=null;break}ga=U.clone();ga.moveToPosition(T,CKEDITOR.POSITION_BEFORE_END)}T=T.getLast(d)}ga&&U.moveToRange(ga)}}}}();r=function(){function a(b){b=new CKEDITOR.dom.walker(b);b.guard=function(a,b){if(b)return!1;if(a.type==CKEDITOR.NODE_ELEMENT)return a.is(CKEDITOR.dtd.$tableContent)};b.evaluator=function(a){return a.type==CKEDITOR.NODE_ELEMENT};return b}function b(a,c,f){c=a.getDocument().createElement(c);a.append(c,
f);return c}function c(a){var b=a.count(),f;for(b;0<b--;)f=a.getItem(b),CKEDITOR.tools.trim(f.getHtml())||(f.appendBogus(),CKEDITOR.env.ie&&9>CKEDITOR.env.version&&f.getChildCount()&&f.getFirst().remove())}return function(f){var d=f.startContainer,g=d.getAscendant("table",1),e=!1;c(g.getElementsByTag("td"));c(g.getElementsByTag("th"));g=f.clone();g.setStart(d,0);g=a(g).lastBackward();g||(g=f.clone(),g.setEndAt(d,CKEDITOR.POSITION_BEFORE_END),g=a(g).lastForward(),e=!0);g||(g=d);g.is("table")?(f.setStartAt(g,
CKEDITOR.POSITION_BEFORE_START),f.collapse(!0),g.remove()):(g.is({tbody:1,thead:1,tfoot:1})&&(g=b(g,"tr",e)),g.is("tr")&&(g=b(g,g.getParent().is("thead")?"th":"td",e)),(d=g.getBogus())&&d.remove(),f.moveToPosition(g,e?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_END))}}();t=function(){function a(b){b=new CKEDITOR.dom.walker(b);b.guard=function(a,b){if(b)return!1;if(a.type==CKEDITOR.NODE_ELEMENT)return a.is(CKEDITOR.dtd.$list)||a.is(CKEDITOR.dtd.$listItem)};b.evaluator=function(a){return a.type==
CKEDITOR.NODE_ELEMENT&&a.is(CKEDITOR.dtd.$listItem)};return b}return function(b){var c=b.startContainer,f=!1,d;d=b.clone();d.setStart(c,0);d=a(d).lastBackward();d||(d=b.clone(),d.setEndAt(c,CKEDITOR.POSITION_BEFORE_END),d=a(d).lastForward(),f=!0);d||(d=c);d.is(CKEDITOR.dtd.$list)?(b.setStartAt(d,CKEDITOR.POSITION_BEFORE_START),b.collapse(!0),d.remove()):((c=d.getBogus())&&c.remove(),b.moveToPosition(d,f?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_END),b.select())}}();w={eol:{detect:function(a,
b){var c=a.range,f=c.clone(),d=c.clone(),g=new CKEDITOR.dom.elementPath(c.startContainer,b),e=new CKEDITOR.dom.elementPath(c.endContainer,b);f.collapse(1);d.collapse();g.block&&f.checkBoundaryOfElement(g.block,CKEDITOR.END)&&(c.setStartAfter(g.block),a.prependEolBr=1);e.block&&d.checkBoundaryOfElement(e.block,CKEDITOR.START)&&(c.setEndBefore(e.block),a.appendEolBr=1)},fix:function(a,b){var c=b.getDocument(),f;a.appendEolBr&&(f=this.createEolBr(c),a.fragment.append(f));!a.prependEolBr||f&&!f.getPrevious()||
a.fragment.append(this.createEolBr(c),1)},createEolBr:function(a){return a.createElement("br",{attributes:{"data-cke-eol":1}})}},bogus:{exclude:function(a){var b=a.range.getBoundaryNodes(),c=b.startNode,b=b.endNode;!b||!q(b)||c&&c.equals(b)||a.range.setEndBefore(b)}},tree:{rebuild:function(a,b){var c=a.range,f=c.getCommonAncestor(),d=new CKEDITOR.dom.elementPath(f,b),g=new CKEDITOR.dom.elementPath(c.startContainer,b),c=new CKEDITOR.dom.elementPath(c.endContainer,b),e;f.type==CKEDITOR.NODE_TEXT&&(f=
f.getParent());if(d.blockLimit.is({tr:1,table:1})){var h=d.contains("table").getParent();e=function(a){return!a.equals(h)}}else if(d.block&&d.block.is(CKEDITOR.dtd.$listItem)&&(g=g.contains(CKEDITOR.dtd.$list),c=c.contains(CKEDITOR.dtd.$list),!g.equals(c))){var m=d.contains(CKEDITOR.dtd.$list).getParent();e=function(a){return!a.equals(m)}}e||(e=function(a){return!a.equals(d.block)&&!a.equals(d.blockLimit)});this.rebuildFragment(a,b,f,e)},rebuildFragment:function(a,b,c,f){for(var d;c&&!c.equals(b)&&
f(c);)d=c.clone(0,1),a.fragment.appendTo(d),a.fragment=d,c=c.getParent()}},cell:{shrink:function(a){a=a.range;var b=a.startContainer,c=a.endContainer,f=a.startOffset,d=a.endOffset;b.type==CKEDITOR.NODE_ELEMENT&&b.equals(c)&&b.is("tr")&&++f==d&&a.shrink(CKEDITOR.SHRINK_TEXT)}}};A=function(){function a(b,c){var f=b.getParent();if(f.is(CKEDITOR.dtd.$inline))b[c?"insertBefore":"insertAfter"](f)}function b(c,f,d){a(f);a(d,1);for(var g;g=d.getNext();)g.insertAfter(f),f=g;p(c)&&c.remove()}function c(a,b){var f=
new CKEDITOR.dom.range(a);f.setStartAfter(b.startNode);f.setEndBefore(b.endNode);return f}return{list:{detectMerge:function(a,b){var f=c(b,a.bookmark),d=f.startPath(),g=f.endPath(),e=d.contains(CKEDITOR.dtd.$list),h=g.contains(CKEDITOR.dtd.$list);a.mergeList=e&&h&&e.getParent().equals(h.getParent())&&!e.equals(h);a.mergeListItems=d.block&&g.block&&d.block.is(CKEDITOR.dtd.$listItem)&&g.block.is(CKEDITOR.dtd.$listItem);if(a.mergeList||a.mergeListItems)f=f.clone(),f.setStartBefore(a.bookmark.startNode),
f.setEndAfter(a.bookmark.endNode),a.mergeListBookmark=f.createBookmark()},merge:function(a,c){if(a.mergeListBookmark){var f=a.mergeListBookmark.startNode,d=a.mergeListBookmark.endNode,g=new CKEDITOR.dom.elementPath(f,c),e=new CKEDITOR.dom.elementPath(d,c);if(a.mergeList){var h=g.contains(CKEDITOR.dtd.$list),m=e.contains(CKEDITOR.dtd.$list);h.equals(m)||(m.moveChildren(h),m.remove())}a.mergeListItems&&(g=g.contains(CKEDITOR.dtd.$listItem),e=e.contains(CKEDITOR.dtd.$listItem),g.equals(e)||b(e,f,d));
f.remove();d.remove()}}},block:{detectMerge:function(a,b){if(!a.tableContentsRanges&&!a.mergeListBookmark){var c=new CKEDITOR.dom.range(b);c.setStartBefore(a.bookmark.startNode);c.setEndAfter(a.bookmark.endNode);a.mergeBlockBookmark=c.createBookmark()}},merge:function(a,c){if(a.mergeBlockBookmark&&!a.purgeTableBookmark){var f=a.mergeBlockBookmark.startNode,d=a.mergeBlockBookmark.endNode,g=new CKEDITOR.dom.elementPath(f,c),e=new CKEDITOR.dom.elementPath(d,c),g=g.block,e=e.block;g&&e&&!g.equals(e)&&
b(e,f,d);f.remove();d.remove()}}},table:function(){function a(c){var d=[],g,e=new CKEDITOR.dom.walker(c),h=c.startPath().contains(f),m=c.endPath().contains(f),k={};e.guard=function(a,e){if(a.type==CKEDITOR.NODE_ELEMENT){var l="visited_"+(e?"out":"in");if(a.getCustomData(l))return;CKEDITOR.dom.element.setMarker(k,a,l,1)}if(e&&h&&a.equals(h))g=c.clone(),g.setEndAt(h,CKEDITOR.POSITION_BEFORE_END),d.push(g);else if(!e&&m&&a.equals(m))g=c.clone(),g.setStartAt(m,CKEDITOR.POSITION_AFTER_START),d.push(g);
else{if(l=!e)l=a.type==CKEDITOR.NODE_ELEMENT&&a.is(f)&&(!h||b(a,h))&&(!m||b(a,m));if(!l&&(l=e))if(a.is(f))var l=h&&h.getAscendant("table",!0),n=m&&m.getAscendant("table",!0),r=a.getAscendant("table",!0),l=l&&l.contains(r)||n&&n.contains(r);else l=void 0;l&&(g=c.clone(),g.selectNodeContents(a),d.push(g))}};e.lastForward();CKEDITOR.dom.element.clearAllMarkers(k);return d}function b(a,c){var f=CKEDITOR.POSITION_CONTAINS+CKEDITOR.POSITION_IS_CONTAINED,d=a.getPosition(c);return d===CKEDITOR.POSITION_IDENTICAL?
!1:0===(d&f)}var f={td:1,th:1,caption:1};return{detectPurge:function(a){var b=a.range,c=b.clone();c.enlarge(CKEDITOR.ENLARGE_ELEMENT);var c=new CKEDITOR.dom.walker(c),d=0;c.evaluator=function(a){a.type==CKEDITOR.NODE_ELEMENT&&a.is(f)&&++d};c.checkForward();if(1<d){var c=b.startPath().contains("table"),g=b.endPath().contains("table");c&&g&&b.checkBoundaryOfElement(c,CKEDITOR.START)&&b.checkBoundaryOfElement(g,CKEDITOR.END)&&(b=a.range.clone(),b.setStartBefore(c),b.setEndAfter(g),a.purgeTableBookmark=
b.createBookmark())}},detectRanges:function(d,g){var e=c(g,d.bookmark),h=e.clone(),m,k,l=e.getCommonAncestor();l.is(CKEDITOR.dtd.$tableContent)&&!l.is(f)&&(l=l.getAscendant("table",!0));k=l;l=new CKEDITOR.dom.elementPath(e.startContainer,k);k=new CKEDITOR.dom.elementPath(e.endContainer,k);l=l.contains("table");k=k.contains("table");if(l||k)l&&k&&b(l,k)?(d.tableSurroundingRange=h,h.setStartAt(l,CKEDITOR.POSITION_AFTER_END),h.setEndAt(k,CKEDITOR.POSITION_BEFORE_START),h=e.clone(),h.setEndAt(l,CKEDITOR.POSITION_AFTER_END),
m=e.clone(),m.setStartAt(k,CKEDITOR.POSITION_BEFORE_START),m=a(h).concat(a(m))):l?k||(d.tableSurroundingRange=h,h.setStartAt(l,CKEDITOR.POSITION_AFTER_END),e.setEndAt(l,CKEDITOR.POSITION_AFTER_END)):(d.tableSurroundingRange=h,h.setEndAt(k,CKEDITOR.POSITION_BEFORE_START),e.setStartAt(k,CKEDITOR.POSITION_AFTER_START)),d.tableContentsRanges=m?m:a(e)},deleteRanges:function(a){for(var b;b=a.tableContentsRanges.pop();)b.extractContents(),p(b.startContainer)&&b.startContainer.appendBogus();a.tableSurroundingRange&&
a.tableSurroundingRange.extractContents()},purge:function(a){if(a.purgeTableBookmark){var b=a.doc,c=a.range.clone(),b=b.createElement("p");b.insertBefore(a.purgeTableBookmark.startNode);c.moveToBookmark(a.purgeTableBookmark);c.deleteContents();a.range.moveToPosition(b,CKEDITOR.POSITION_AFTER_START)}}}}(),detectExtractMerge:function(a){return!(a.range.startPath().contains(CKEDITOR.dtd.$listItem)&&a.range.endPath().contains(CKEDITOR.dtd.$listItem))},fixUneditableRangePosition:function(a){a.startContainer.getDtd()["#"]||
a.moveToClosestEditablePosition(null,!0)},autoParagraph:function(a,b){var c=b.startPath(),f;k(a,c.block,c.blockLimit)&&(f=h(a))&&(f=b.document.createElement(f),f.appendBogus(),b.insertNode(f),b.moveToPosition(f,CKEDITOR.POSITION_AFTER_START))}}}()}(),function(){function a(a){return CKEDITOR.plugins.widget&&CKEDITOR.plugins.widget.isDomWidget(a)}function e(b,c){if(0===b.length||a(b[0].getEnclosedNode()))return!1;var f,d;if((f=!c&&1===b.length)&&!(f=b[0].collapsed)){var g=b[0];f=g.startContainer.getAscendant({td:1,
th:1},!0);var e=g.endContainer.getAscendant({td:1,th:1},!0);d=CKEDITOR.tools.trim;f&&f.equals(e)&&!f.findOne("td, th, tr, tbody, table")?(g=g.cloneContents(),f=g.getFirst()?d(g.getFirst().getText())!==d(f.getText()):!0):f=!1}if(f)return!1;for(d=0;d<b.length;d++)if(f=b[d]._getTableElement(),!f)return!1;return!0}function b(a){function b(a){a=a.find("td, th");var c=[],f;for(f=0;f<a.count();f++)c.push(a.getItem(f));return c}var c=[],f,d;for(d=0;d<a.length;d++)f=a[d]._getTableElement(),f.is&&f.is({td:1,
th:1})?c.push(f):c=c.concat(b(f));return c}function d(a){a=b(a);var c="",f=[],d,g;for(g=0;g<a.length;g++)d&&!d.equals(a[g].getAscendant("tr"))?(c+=f.join("\t")+"\n",d=a[g].getAscendant("tr"),f=[]):0===g&&(d=a[g].getAscendant("tr")),f.push(a[g].getText());return c+=f.join("\t")}function g(a){var b=this.root.editor,c=b.getSelection(1);this.reset();x=!0;c.root.once("selectionchange",function(a){a.cancel()},null,null,0);c.selectRanges([a[0]]);c=this._.cache;c.ranges=new CKEDITOR.dom.rangeList(a);c.type=
CKEDITOR.SELECTION_TEXT;c.selectedElement=a[0]._getTableElement();c.selectedText=d(a);c.nativeSel=null;this.isFake=1;this.rev=t++;b._.fakeSelection=this;x=!1;this.root.fire("selectionchange")}function l(){var b=this._.fakeSelection,c;if(b){c=this.getSelection(1);var f;if(!(f=!c)&&(f=!c.isHidden())){f=b;var d=c.getRanges(),g=f.getRanges(),h=d.length&&d[0]._getTableElement()&&d[0]._getTableElement().getAscendant("table",!0),m=g.length&&g[0]._getTableElement()&&g[0]._getTableElement().getAscendant("table",
!0),k=1===d.length&&d[0]._getTableElement()&&d[0]._getTableElement().is("table"),l=1===g.length&&g[0]._getTableElement()&&g[0]._getTableElement().is("table");if(a(f.getSelectedElement()))f=!1;else{var n=1===d.length&&d[0].collapsed,g=e(d,!!CKEDITOR.env.webkit)&&e(g);h=h&&m?h.equals(m)||m.contains(h):!1;h&&(n||g)?(k&&!l&&f.selectRanges(d),f=!0):f=!1}f=!f}f&&(b.reset(),b=0)}if(!b&&(b=c||this.getSelection(1),!b||b.getType()==CKEDITOR.SELECTION_NONE))return;this.fire("selectionCheck",b);c=this.elementPath();
c.compare(this._.selectionPreviousPath)||(f=this._.selectionPreviousPath&&this._.selectionPreviousPath.blockLimit.equals(c.blockLimit),CKEDITOR.env.webkit&&!f&&(this._.previousActive=this.document.getActive()),this._.selectionPreviousPath=c,this.fire("selectionChange",{selection:b,path:c}))}function k(){C=!0;u||(h.call(this),u=CKEDITOR.tools.setTimeout(h,200,this))}function h(){u=null;C&&(CKEDITOR.tools.setTimeout(l,0,this),C=!1)}function c(a){return z(a)||a.type==CKEDITOR.NODE_ELEMENT&&!a.is(CKEDITOR.dtd.$empty)?
!0:!1}function m(a){function b(c,f){return c&&c.type!=CKEDITOR.NODE_TEXT?a.clone()["moveToElementEdit"+(f?"End":"Start")](c):!1}if(!(a.root instanceof CKEDITOR.editable))return!1;var f=a.startContainer,d=a.getPreviousNode(c,null,f),g=a.getNextNode(c,null,f);return b(d)||b(g,1)||!(d||g||f.type==CKEDITOR.NODE_ELEMENT&&f.isBlockBoundary()&&f.getBogus())?!0:!1}function f(a){n(a,!1);var b=a.getDocument().createText(w);a.setCustomData("cke-fillingChar",b);return b}function n(a,b){var c=a&&a.removeCustomData("cke-fillingChar");
if(c){if(!1!==b){var f=a.getDocument().getSelection().getNative(),d=f&&"None"!=f.type&&f.getRangeAt(0),g=w.length;if(c.getLength()>g&&d&&d.intersectsNode(c.$)){var e=[{node:f.anchorNode,offset:f.anchorOffset},{node:f.focusNode,offset:f.focusOffset}];f.anchorNode==c.$&&f.anchorOffset>g&&(e[0].offset-=g);f.focusNode==c.$&&f.focusOffset>g&&(e[1].offset-=g)}}c.setText(p(c.getText(),1));e&&(c=a.getDocument().$,f=c.getSelection(),c=c.createRange(),c.setStart(e[0].node,e[0].offset),c.collapse(!0),f.removeAllRanges(),
f.addRange(c),f.extend(e[1].node,e[1].offset))}}function p(a,b){return b?a.replace(A,function(a,b){return b?" ":""}):a.replace(w,"")}function q(a,b){var c=CKEDITOR.dom.element.createFromHtml('\x3cdiv data-cke-hidden-sel\x3d"1" data-cke-temp\x3d"1" style\x3d"'+(CKEDITOR.env.ie&&14>CKEDITOR.env.version?"display:none":"position:fixed;top:0;left:-1000px")+'"\x3e'+(b||"\x26nbsp;")+"\x3c/div\x3e",a.document);a.fire("lockSnapshot");a.editable().append(c);var f=a.getSelection(1),d=a.createRange(),g=f.root.on("selectionchange",
function(a){a.cancel()},null,null,0);d.setStartAt(c,CKEDITOR.POSITION_AFTER_START);d.setEndAt(c,CKEDITOR.POSITION_BEFORE_END);f.selectRanges([d]);g.removeListener();a.fire("unlockSnapshot");a._.hiddenSelectionContainer=c}function v(a){var b={37:1,39:1,8:1,46:1};return function(c){var f=c.data.getKeystroke();if(b[f]){var d=a.getSelection().getRanges(),g=d[0];1==d.length&&g.collapsed&&(f=g[38>f?"getPreviousEditableNode":"getNextEditableNode"]())&&f.type==CKEDITOR.NODE_ELEMENT&&"false"==f.getAttribute("contenteditable")&&
(a.getSelection().fake(f),c.data.preventDefault(),c.cancel())}}}function y(a){for(var b=0;b<a.length;b++){var c=a[b];c.getCommonAncestor().isReadOnly()&&a.splice(b,1);if(!c.collapsed){if(c.startContainer.isReadOnly())for(var f=c.startContainer,d;f&&!((d=f.type==CKEDITOR.NODE_ELEMENT)&&f.is("body")||!f.isReadOnly());)d&&"false"==f.getAttribute("contentEditable")&&c.setStartAfter(f),f=f.getParent();f=c.startContainer;d=c.endContainer;var g=c.startOffset,e=c.endOffset,h=c.clone();f&&f.type==CKEDITOR.NODE_TEXT&&
(g>=f.getLength()?h.setStartAfter(f):h.setStartBefore(f));d&&d.type==CKEDITOR.NODE_TEXT&&(e?h.setEndAfter(d):h.setEndBefore(d));f=new CKEDITOR.dom.walker(h);f.evaluator=function(f){if(f.type==CKEDITOR.NODE_ELEMENT&&f.isReadOnly()){var d=c.clone();c.setEndBefore(f);c.collapsed&&a.splice(b--,1);f.getPosition(h.endContainer)&CKEDITOR.POSITION_CONTAINS||(d.setStartAfter(f),d.collapsed||a.splice(b+1,0,d));return!0}return!1};f.next()}}return a}var r="function"!=typeof window.getSelection,t=1,w=CKEDITOR.tools.repeat("",
7),A=new RegExp(w+"( )?","g"),x,u,C,z=CKEDITOR.dom.walker.invisible(1),B=function(){function a(b){return function(a){var c=a.editor.createRange();c.moveToClosestEditablePosition(a.selected,b)&&a.editor.getSelection().selectRanges([c]);return!1}}function b(a){return function(b){var c=b.editor,f=c.createRange(),d;(d=f.moveToClosestEditablePosition(b.selected,a))||(d=f.moveToClosestEditablePosition(b.selected,!a));d&&c.getSelection().selectRanges([f]);c.fire("saveSnapshot");b.selected.remove();d||(f.moveToElementEditablePosition(c.editable()),
c.getSelection().selectRanges([f]));c.fire("saveSnapshot");return!1}}var c=a(),f=a(1);return{37:c,38:c,39:f,40:f,8:b(),46:b(1)}}();CKEDITOR.on("instanceCreated",function(a){function b(){var a=c.getSelection();a&&a.removeAllRanges()}var c=a.editor;c.on("contentDom",function(){function a(){w=new CKEDITOR.dom.selection(c.getSelection());w.lock()}function b(){g.removeListener("mouseup",b);m.removeListener("mouseup",b);var a=CKEDITOR.document.$.selection,c=a.createRange();"None"!=a.type&&c.parentElement()&&
c.parentElement().ownerDocument==d.$&&c.select()}function f(a){if(CKEDITOR.env.ie){var b=(a=a.getRanges()[0])?a.startContainer.getAscendant(function(a){return a.type==CKEDITOR.NODE_ELEMENT&&("false"==a.getAttribute("contenteditable")||"true"==a.getAttribute("contenteditable"))},!0):null;return a&&"false"==b.getAttribute("contenteditable")&&b}}var d=c.document,g=CKEDITOR.document,e=c.editable(),h=d.getBody(),m=d.getDocumentElement(),p=e.isInline(),t,w;CKEDITOR.env.gecko&&e.attachListener(e,"focus",
function(a){a.removeListener();0!==t&&(a=c.getSelection().getNative())&&a.isCollapsed&&a.anchorNode==e.$&&(a=c.createRange(),a.moveToElementEditStart(e),a.select())},null,null,-2);e.attachListener(e,CKEDITOR.env.webkit?"DOMFocusIn":"focus",function(){t&&CKEDITOR.env.webkit&&(t=c._.previousActive&&c._.previousActive.equals(d.getActive()))&&null!=c._.previousScrollTop&&c._.previousScrollTop!=e.$.scrollTop&&(e.$.scrollTop=c._.previousScrollTop);c.unlockSelection(t);t=0},null,null,-1);e.attachListener(e,
"mousedown",function(){t=0});if(CKEDITOR.env.ie||p)r?e.attachListener(e,"beforedeactivate",a,null,null,-1):e.attachListener(c,"selectionCheck",a,null,null,-1),e.attachListener(e,CKEDITOR.env.webkit?"DOMFocusOut":"blur",function(){c.lockSelection(w);t=1},null,null,-1),e.attachListener(e,"mousedown",function(){t=0});if(CKEDITOR.env.ie&&!p){var u;e.attachListener(e,"mousedown",function(a){2==a.data.$.button&&((a=c.document.getSelection())&&a.getType()!=CKEDITOR.SELECTION_NONE||(u=c.window.getScrollPosition()))});
e.attachListener(e,"mouseup",function(a){2==a.data.$.button&&u&&(c.document.$.documentElement.scrollLeft=u.x,c.document.$.documentElement.scrollTop=u.y);u=null});if("BackCompat"!=d.$.compatMode){if(CKEDITOR.env.ie7Compat||CKEDITOR.env.ie6Compat){var A,q;m.on("mousedown",function(a){function b(a){a=a.data.$;if(A){var c=h.$.createTextRange();try{c.moveToPoint(a.clientX,a.clientY)}catch(f){}A.setEndPoint(0>q.compareEndPoints("StartToStart",c)?"EndToEnd":"StartToStart",c);A.select()}}function c(){m.removeListener("mousemove",
b);g.removeListener("mouseup",c);m.removeListener("mouseup",c);A.select()}a=a.data;if(a.getTarget().is("html")&&a.$.y<m.$.clientHeight&&a.$.x<m.$.clientWidth){A=h.$.createTextRange();try{A.moveToPoint(a.$.clientX,a.$.clientY)}catch(f){}q=A.duplicate();m.on("mousemove",b);g.on("mouseup",c);m.on("mouseup",c)}})}if(7<CKEDITOR.env.version&&11>CKEDITOR.env.version)m.on("mousedown",function(a){a.data.getTarget().is("html")&&(g.on("mouseup",b),m.on("mouseup",b))})}}e.attachListener(e,"selectionchange",l,
c);e.attachListener(e,"keyup",k,c);e.attachListener(e,"keydown",function(a){var b=this.getSelection(1);f(b)&&(b.selectElement(f(b)),a.data.preventDefault())},c);e.attachListener(e,CKEDITOR.env.webkit?"DOMFocusIn":"focus",function(){c.forceNextSelectionCheck();c.selectionChange(1)});if(p&&(CKEDITOR.env.webkit||CKEDITOR.env.gecko)){var x;e.attachListener(e,"mousedown",function(){x=1});e.attachListener(d.getDocumentElement(),"mouseup",function(){x&&k.call(c);x=0})}else e.attachListener(CKEDITOR.env.ie?
e:d.getDocumentElement(),"mouseup",k,c);CKEDITOR.env.webkit&&e.attachListener(d,"keydown",function(a){switch(a.data.getKey()){case 13:case 33:case 34:case 35:case 36:case 37:case 39:case 8:case 45:case 46:e.hasFocus&&n(e)}},null,null,-1);e.attachListener(e,"keydown",v(c),null,null,-1)});c.on("setData",function(){c.unlockSelection();CKEDITOR.env.webkit&&b()});c.on("contentDomUnload",function(){c.unlockSelection()});if(CKEDITOR.env.ie9Compat)c.on("beforeDestroy",b,null,null,9);c.on("dataReady",function(){delete c._.fakeSelection;
delete c._.hiddenSelectionContainer;c.selectionChange(1)});c.on("loadSnapshot",function(){var a=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_ELEMENT),b=c.editable().getLast(a);b&&b.hasAttribute("data-cke-hidden-sel")&&(b.remove(),CKEDITOR.env.gecko&&(a=c.editable().getFirst(a))&&a.is("br")&&a.getAttribute("_moz_editor_bogus_node")&&a.remove())},null,null,100);c.on("key",function(a){if("wysiwyg"==c.mode){var b=c.getSelection();if(b.isFake){var f=B[a.data.keyCode];if(f)return f({editor:c,selected:b.getSelectedElement(),
selection:b,keyEvent:a})}}})});if(CKEDITOR.env.webkit)CKEDITOR.on("instanceReady",function(a){var b=a.editor;b.on("selectionChange",function(){var a=b.editable(),c=a.getCustomData("cke-fillingChar");c&&(c.getCustomData("ready")?(n(a),a.editor.fire("selectionCheck")):c.setCustomData("ready",1))},null,null,-1);b.on("beforeSetMode",function(){n(b.editable())},null,null,-1);b.on("getSnapshot",function(a){a.data&&(a.data=p(a.data))},b,null,20);b.on("toDataFormat",function(a){a.data.dataValue=p(a.data.dataValue)},
null,null,0)});CKEDITOR.editor.prototype.selectionChange=function(a){(a?l:k).call(this)};CKEDITOR.editor.prototype.getSelection=function(a){return!this._.savedSelection&&!this._.fakeSelection||a?(a=this.editable())&&"wysiwyg"==this.mode?new CKEDITOR.dom.selection(a):null:this._.savedSelection||this._.fakeSelection};CKEDITOR.editor.prototype.lockSelection=function(a){a=a||this.getSelection(1);return a.getType()!=CKEDITOR.SELECTION_NONE?(!a.isLocked&&a.lock(),this._.savedSelection=a,!0):!1};CKEDITOR.editor.prototype.unlockSelection=
function(a){var b=this._.savedSelection;return b?(b.unlock(a),delete this._.savedSelection,!0):!1};CKEDITOR.editor.prototype.forceNextSelectionCheck=function(){delete this._.selectionPreviousPath};CKEDITOR.dom.document.prototype.getSelection=function(){return new CKEDITOR.dom.selection(this)};CKEDITOR.dom.range.prototype.select=function(){var a=this.root instanceof CKEDITOR.editable?this.root.editor.getSelection():new CKEDITOR.dom.selection(this.root);a.selectRanges([this]);return a};CKEDITOR.SELECTION_NONE=
1;CKEDITOR.SELECTION_TEXT=2;CKEDITOR.SELECTION_ELEMENT=3;CKEDITOR.dom.selection=function(a){if(a instanceof CKEDITOR.dom.selection){var b=a;a=a.root}var c=a instanceof CKEDITOR.dom.element;this.rev=b?b.rev:t++;this.document=a instanceof CKEDITOR.dom.document?a:a.getDocument();this.root=c?a:this.document.getBody();this.isLocked=0;this._={cache:{}};if(b)return CKEDITOR.tools.extend(this._.cache,b._.cache),this.isFake=b.isFake,this.isLocked=b.isLocked,this;a=this.getNative();var f,d;if(a)if(a.getRangeAt)f=
(d=a.rangeCount&&a.getRangeAt(0))&&new CKEDITOR.dom.node(d.commonAncestorContainer);else{try{d=a.createRange()}catch(g){}f=d&&CKEDITOR.dom.element.get(d.item&&d.item(0)||d.parentElement())}if(!f||f.type!=CKEDITOR.NODE_ELEMENT&&f.type!=CKEDITOR.NODE_TEXT||!this.root.equals(f)&&!this.root.contains(f))this._.cache.type=CKEDITOR.SELECTION_NONE,this._.cache.startElement=null,this._.cache.selectedElement=null,this._.cache.selectedText="",this._.cache.ranges=new CKEDITOR.dom.rangeList;return this};var G=
{img:1,hr:1,li:1,table:1,tr:1,td:1,th:1,embed:1,object:1,ol:1,ul:1,a:1,input:1,form:1,select:1,textarea:1,button:1,fieldset:1,thead:1,tfoot:1};CKEDITOR.tools.extend(CKEDITOR.dom.selection,{_removeFillingCharSequenceString:p,_createFillingCharSequenceNode:f,FILLING_CHAR_SEQUENCE:w});CKEDITOR.dom.selection.prototype={getNative:function(){return void 0!==this._.cache.nativeSel?this._.cache.nativeSel:this._.cache.nativeSel=r?this.document.$.selection:this.document.getWindow().$.getSelection()},getType:r?
function(){var a=this._.cache;if(a.type)return a.type;var b=CKEDITOR.SELECTION_NONE;try{var c=this.getNative(),f=c.type;"Text"==f&&(b=CKEDITOR.SELECTION_TEXT);"Control"==f&&(b=CKEDITOR.SELECTION_ELEMENT);c.createRange().parentElement()&&(b=CKEDITOR.SELECTION_TEXT)}catch(d){}return a.type=b}:function(){var a=this._.cache;if(a.type)return a.type;var b=CKEDITOR.SELECTION_TEXT,c=this.getNative();if(!c||!c.rangeCount)b=CKEDITOR.SELECTION_NONE;else if(1==c.rangeCount){var c=c.getRangeAt(0),f=c.startContainer;
f==c.endContainer&&1==f.nodeType&&1==c.endOffset-c.startOffset&&G[f.childNodes[c.startOffset].nodeName.toLowerCase()]&&(b=CKEDITOR.SELECTION_ELEMENT)}return a.type=b},getRanges:function(){var a=r?function(){function a(b){return(new CKEDITOR.dom.node(b)).getIndex()}var b=function(b,c){b=b.duplicate();b.collapse(c);var f=b.parentElement();if(!f.hasChildNodes())return{container:f,offset:0};for(var d=f.children,g,e,h=b.duplicate(),m=0,k=d.length-1,l=-1,n,r;m<=k;)if(l=Math.floor((m+k)/2),g=d[l],h.moveToElementText(g),
n=h.compareEndPoints("StartToStart",b),0<n)k=l-1;else if(0>n)m=l+1;else return{container:f,offset:a(g)};if(-1==l||l==d.length-1&&0>n){h.moveToElementText(f);h.setEndPoint("StartToStart",b);h=h.text.replace(/(\r\n|\r)/g,"\n").length;d=f.childNodes;if(!h)return g=d[d.length-1],g.nodeType!=CKEDITOR.NODE_TEXT?{container:f,offset:d.length}:{container:g,offset:g.nodeValue.length};for(f=d.length;0<h&&0<f;)e=d[--f],e.nodeType==CKEDITOR.NODE_TEXT&&(r=e,h-=e.nodeValue.length);return{container:r,offset:-h}}h.collapse(0<
n?!0:!1);h.setEndPoint(0<n?"StartToStart":"EndToStart",b);h=h.text.replace(/(\r\n|\r)/g,"\n").length;if(!h)return{container:f,offset:a(g)+(0<n?0:1)};for(;0<h;)try{e=g[0<n?"previousSibling":"nextSibling"],e.nodeType==CKEDITOR.NODE_TEXT&&(h-=e.nodeValue.length,r=e),g=e}catch(p){return{container:f,offset:a(g)}}return{container:r,offset:0<n?-h:r.nodeValue.length+h}};return function(){var a=this.getNative(),c=a&&a.createRange(),f=this.getType();if(!a)return[];if(f==CKEDITOR.SELECTION_TEXT)return a=new CKEDITOR.dom.range(this.root),
f=b(c,!0),a.setStart(new CKEDITOR.dom.node(f.container),f.offset),f=b(c),a.setEnd(new CKEDITOR.dom.node(f.container),f.offset),a.endContainer.getPosition(a.startContainer)&CKEDITOR.POSITION_PRECEDING&&a.endOffset<=a.startContainer.getIndex()&&a.collapse(),[a];if(f==CKEDITOR.SELECTION_ELEMENT){for(var f=[],d=0;d<c.length;d++){for(var g=c.item(d),e=g.parentNode,h=0,a=new CKEDITOR.dom.range(this.root);h<e.childNodes.length&&e.childNodes[h]!=g;h++);a.setStart(new CKEDITOR.dom.node(e),h);a.setEnd(new CKEDITOR.dom.node(e),
h+1);f.push(a)}return f}return[]}}():function(){var a=[],b,c=this.getNative();if(!c)return a;for(var f=0;f<c.rangeCount;f++){var d=c.getRangeAt(f);b=new CKEDITOR.dom.range(this.root);b.setStart(new CKEDITOR.dom.node(d.startContainer),d.startOffset);b.setEnd(new CKEDITOR.dom.node(d.endContainer),d.endOffset);a.push(b)}return a};return function(b){var c=this._.cache,f=c.ranges;f||(c.ranges=f=new CKEDITOR.dom.rangeList(a.call(this)));return b?y(new CKEDITOR.dom.rangeList(f.slice())):f}}(),getStartElement:function(){var a=
this._.cache;if(void 0!==a.startElement)return a.startElement;var b;switch(this.getType()){case CKEDITOR.SELECTION_ELEMENT:return this.getSelectedElement();case CKEDITOR.SELECTION_TEXT:var c=this.getRanges()[0];if(c){if(c.collapsed)b=c.startContainer,b.type!=CKEDITOR.NODE_ELEMENT&&(b=b.getParent());else{for(c.optimize();b=c.startContainer,c.startOffset==(b.getChildCount?b.getChildCount():b.getLength())&&!b.isBlockBoundary();)c.setStartAfter(b);b=c.startContainer;if(b.type!=CKEDITOR.NODE_ELEMENT)return b.getParent();
if((b=b.getChild(c.startOffset))&&b.type==CKEDITOR.NODE_ELEMENT)for(c=b.getFirst();c&&c.type==CKEDITOR.NODE_ELEMENT;)b=c,c=c.getFirst();else b=c.startContainer}b=b.$}}return a.startElement=b?new CKEDITOR.dom.element(b):null},getSelectedElement:function(){var a=this._.cache;if(void 0!==a.selectedElement)return a.selectedElement;var b=this,c=CKEDITOR.tools.tryThese(function(){return b.getNative().createRange().item(0)},function(){for(var a=b.getRanges()[0].clone(),c,f,d=2;d&&!((c=a.getEnclosedNode())&&
c.type==CKEDITOR.NODE_ELEMENT&&G[c.getName()]&&(f=c));d--)a.shrink(CKEDITOR.SHRINK_ELEMENT);return f&&f.$});return a.selectedElement=c?new CKEDITOR.dom.element(c):null},getSelectedText:function(){var a=this._.cache;if(void 0!==a.selectedText)return a.selectedText;var b=this.getNative(),b=r?"Control"==b.type?"":b.createRange().text:b.toString();return a.selectedText=b},lock:function(){this.getRanges();this.getStartElement();this.getSelectedElement();this.getSelectedText();this._.cache.nativeSel=null;
this.isLocked=1},unlock:function(a){if(this.isLocked){if(a)var b=this.getSelectedElement(),c=this.getRanges(),f=this.isFake;this.isLocked=0;this.reset();a&&(a=b||c[0]&&c[0].getCommonAncestor())&&a.getAscendant("body",1)&&(e(c)?g.call(this,c):f?this.fake(b):b?this.selectElement(b):this.selectRanges(c))}},reset:function(){this._.cache={};this.isFake=0;var a=this.root.editor;if(a&&a._.fakeSelection)if(this.rev==a._.fakeSelection.rev){delete a._.fakeSelection;var b=a._.hiddenSelectionContainer;if(b){var c=
a.checkDirty();a.fire("lockSnapshot");b.remove();a.fire("unlockSnapshot");!c&&a.resetDirty()}delete a._.hiddenSelectionContainer}else CKEDITOR.warn("selection-fake-reset");this.rev=t++},selectElement:function(a){var b=new CKEDITOR.dom.range(this.root);b.setStartBefore(a);b.setEndAfter(a);this.selectRanges([b])},selectRanges:function(a){var b=this.root.editor,c=b&&b._.hiddenSelectionContainer;this.reset();if(c)for(var c=this.root,d,h=0;h<a.length;++h)d=a[h],d.endContainer.equals(c)&&(d.endOffset=Math.min(d.endOffset,
c.getChildCount()));if(a.length)if(this.isLocked){var k=CKEDITOR.document.getActive();this.unlock();this.selectRanges(a);this.lock();k&&!k.equals(this.root)&&k.focus()}else{var l;a:{var p,t;if(1==a.length&&!(t=a[0]).collapsed&&(l=t.getEnclosedNode())&&l.type==CKEDITOR.NODE_ELEMENT&&(t=t.clone(),t.shrink(CKEDITOR.SHRINK_ELEMENT,!0),(p=t.getEnclosedNode())&&p.type==CKEDITOR.NODE_ELEMENT&&(l=p),"false"==l.getAttribute("contenteditable")))break a;l=void 0}if(l)this.fake(l);else if(b&&b.plugins.tableselection&&
CKEDITOR.plugins.tableselection.isSupportedEnvironment&&e(a)&&!x)g.call(this,a);else{if(r){p=CKEDITOR.dom.walker.whitespaces(!0);l=/\ufeff|\u00a0/;t={table:1,tbody:1,tr:1};1<a.length&&(b=a[a.length-1],a[0].setEnd(b.endContainer,b.endOffset));b=a[0];a=b.collapsed;var w,v,u;if((c=b.getEnclosedNode())&&c.type==CKEDITOR.NODE_ELEMENT&&c.getName()in G&&(!c.is("a")||!c.getText()))try{u=c.$.createControlRange();u.addElement(c.$);u.select();return}catch(A){}if(b.startContainer.type==CKEDITOR.NODE_ELEMENT&&
b.startContainer.getName()in t||b.endContainer.type==CKEDITOR.NODE_ELEMENT&&b.endContainer.getName()in t)b.shrink(CKEDITOR.NODE_ELEMENT,!0),a=b.collapsed;u=b.createBookmark();t=u.startNode;a||(k=u.endNode);u=b.document.$.body.createTextRange();u.moveToElementText(t.$);u.moveStart("character",1);k?(l=b.document.$.body.createTextRange(),l.moveToElementText(k.$),u.setEndPoint("EndToEnd",l),u.moveEnd("character",-1)):(w=t.getNext(p),v=t.hasAscendant("pre"),w=!(w&&w.getText&&w.getText().match(l))&&(v||
!t.hasPrevious()||t.getPrevious().is&&t.getPrevious().is("br")),v=b.document.createElement("span"),v.setHtml("\x26#65279;"),v.insertBefore(t),w&&b.document.createText("").insertBefore(t));b.setStartBefore(t);t.remove();a?(w?(u.moveStart("character",-1),u.select(),b.document.$.selection.clear()):u.select(),b.moveToPosition(v,CKEDITOR.POSITION_BEFORE_START),v.remove()):(b.setEndBefore(k),k.remove(),u.select())}else{k=this.getNative();if(!k)return;this.removeAllRanges();for(u=0;u<a.length;u++){if(u<
a.length-1&&(w=a[u],v=a[u+1],l=w.clone(),l.setStart(w.endContainer,w.endOffset),l.setEnd(v.startContainer,v.startOffset),!l.collapsed&&(l.shrink(CKEDITOR.NODE_ELEMENT,!0),b=l.getCommonAncestor(),l=l.getEnclosedNode(),b.isReadOnly()||l&&l.isReadOnly()))){v.setStart(w.startContainer,w.startOffset);a.splice(u--,1);continue}b=a[u];v=this.document.$.createRange();b.collapsed&&CKEDITOR.env.webkit&&m(b)&&(l=f(this.root),b.insertNode(l),(w=l.getNext())&&!l.getPrevious()&&w.type==CKEDITOR.NODE_ELEMENT&&"br"==
w.getName()?(n(this.root),b.moveToPosition(w,CKEDITOR.POSITION_BEFORE_START)):b.moveToPosition(l,CKEDITOR.POSITION_AFTER_END));v.setStart(b.startContainer.$,b.startOffset);try{v.setEnd(b.endContainer.$,b.endOffset)}catch(q){if(0<=q.toString().indexOf("NS_ERROR_ILLEGAL_VALUE"))b.collapse(1),v.setEnd(b.endContainer.$,b.endOffset);else throw q;}k.addRange(v)}}this.reset();this.root.fire("selectionchange")}}},fake:function(a,b){var c=this.root.editor;void 0===b&&a.hasAttribute("aria-label")&&(b=a.getAttribute("aria-label"));
this.reset();q(c,b);var f=this._.cache,d=new CKEDITOR.dom.range(this.root);d.setStartBefore(a);d.setEndAfter(a);f.ranges=new CKEDITOR.dom.rangeList(d);f.selectedElement=f.startElement=a;f.type=CKEDITOR.SELECTION_ELEMENT;f.selectedText=f.nativeSel=null;this.isFake=1;this.rev=t++;c._.fakeSelection=this;this.root.fire("selectionchange")},isHidden:function(){var a=this.getCommonAncestor();a&&a.type==CKEDITOR.NODE_TEXT&&(a=a.getParent());return!(!a||!a.data("cke-hidden-sel"))},isInTable:function(a){return e(this.getRanges(),
a)},isCollapsed:function(){var a=this.getRanges();return 1===a.length&&a[0].collapsed},createBookmarks:function(a){a=this.getRanges().createBookmarks(a);this.isFake&&(a.isFake=1);return a},createBookmarks2:function(a){a=this.getRanges().createBookmarks2(a);this.isFake&&(a.isFake=1);return a},selectBookmarks:function(a){for(var b=[],c,f=0;f<a.length;f++){var d=new CKEDITOR.dom.range(this.root);d.moveToBookmark(a[f]);b.push(d)}a.isFake&&(c=e(b)?b[0]._getTableElement():b[0].getEnclosedNode(),c&&c.type==
CKEDITOR.NODE_ELEMENT||(CKEDITOR.warn("selection-not-fake"),a.isFake=0));a.isFake&&!e(b)?this.fake(c):this.selectRanges(b);return this},getCommonAncestor:function(){var a=this.getRanges();return a.length?a[0].startContainer.getCommonAncestor(a[a.length-1].endContainer):null},scrollIntoView:function(){this.type!=CKEDITOR.SELECTION_NONE&&this.getRanges()[0].scrollIntoView()},removeAllRanges:function(){if(this.getType()!=CKEDITOR.SELECTION_NONE){var a=this.getNative();try{a&&a[r?"empty":"removeAllRanges"]()}catch(b){}this.reset()}}}}(),
"use strict",CKEDITOR.STYLE_BLOCK=1,CKEDITOR.STYLE_INLINE=2,CKEDITOR.STYLE_OBJECT=3,function(){function a(a,b){for(var c,f;(a=a.getParent())&&!a.equals(b);)if(a.getAttribute("data-nostyle"))c=a;else if(!f){var d=a.getAttribute("contentEditable");"false"==d?c=a:"true"==d&&(f=1)}return c}function e(a,b,c,f){return(a.getPosition(b)|f)==f&&(!c.childRule||c.childRule(a))}function b(c){var f=c.document;if(c.collapsed)f=t(this,f),c.insertNode(f),c.moveToPosition(f,CKEDITOR.POSITION_BEFORE_END);else{var d=
this.element,h=this._.definition,m,k=h.ignoreReadonly,l=k||h.includeReadonly;null==l&&(l=c.root.getCustomData("cke_includeReadonly"));var n=CKEDITOR.dtd[d];n||(m=!0,n=CKEDITOR.dtd.span);c.enlarge(CKEDITOR.ENLARGE_INLINE,1);c.trim();var r=c.createBookmark(),p=r.startNode,w=r.endNode,u=p,A;if(!k){var q=c.getCommonAncestor(),k=a(p,q),q=a(w,q);k&&(u=k.getNextSourceNode(!0));q&&(w=q)}for(u.getPosition(w)==CKEDITOR.POSITION_FOLLOWING&&(u=0);u;){k=!1;if(u.equals(w))u=null,k=!0;else{var I=u.type==CKEDITOR.NODE_ELEMENT?
u.getName():null,q=I&&"false"==u.getAttribute("contentEditable"),x=I&&u.getAttribute("data-nostyle");if(I&&u.data("cke-bookmark")){u=u.getNextSourceNode(!0);continue}if(q&&l&&CKEDITOR.dtd.$block[I])for(var y=u,z=g(y),B=void 0,C=z.length,ea=0,y=C&&new CKEDITOR.dom.range(y.getDocument());ea<C;++ea){var B=z[ea],G=CKEDITOR.filter.instances[B.data("cke-filter")];if(G?G.check(this):1)y.selectNodeContents(B),b.call(this,y)}z=I?!n[I]||x?0:q&&!l?0:e(u,w,h,M):1;if(z)if(B=u.getParent(),z=h,C=d,ea=m,!B||!(B.getDtd()||
CKEDITOR.dtd.span)[C]&&!ea||z.parentRule&&!z.parentRule(B))k=!0;else{if(A||I&&CKEDITOR.dtd.$removeEmpty[I]&&(u.getPosition(w)|M)!=M||(A=c.clone(),A.setStartBefore(u)),I=u.type,I==CKEDITOR.NODE_TEXT||q||I==CKEDITOR.NODE_ELEMENT&&!u.getChildCount()){for(var I=u,F;(k=!I.getNext(J))&&(F=I.getParent(),n[F.getName()])&&e(F,p,h,K);)I=F;A.setEndAfter(I)}}else k=!0;u=u.getNextSourceNode(x||q)}if(k&&A&&!A.collapsed){for(var k=t(this,f),q=k.hasAttributes(),x=A.getCommonAncestor(),I={},z={},B={},C={},fa,E,H;k&&
x;){if(x.getName()==d){for(fa in h.attributes)!C[fa]&&(H=x.getAttribute(E))&&(k.getAttribute(fa)==H?z[fa]=1:C[fa]=1);for(E in h.styles)!B[E]&&(H=x.getStyle(E))&&(k.getStyle(E)==H?I[E]=1:B[E]=1)}x=x.getParent()}for(fa in z)k.removeAttribute(fa);for(E in I)k.removeStyle(E);q&&!k.hasAttributes()&&(k=null);k?(A.extractContents().appendTo(k),A.insertNode(k),v.call(this,k),k.mergeSiblings(),CKEDITOR.env.ie||k.$.normalize()):(k=new CKEDITOR.dom.element("span"),A.extractContents().appendTo(k),A.insertNode(k),
v.call(this,k),k.remove(!0));A=null}}c.moveToBookmark(r);c.shrink(CKEDITOR.SHRINK_TEXT);c.shrink(CKEDITOR.NODE_ELEMENT,!0)}}function d(a){function b(){for(var a=new CKEDITOR.dom.elementPath(f.getParent()),c=new CKEDITOR.dom.elementPath(l.getParent()),d=null,g=null,e=0;e<a.elements.length;e++){var h=a.elements[e];if(h==a.block||h==a.blockLimit)break;n.checkElementRemovable(h,!0)&&(d=h)}for(e=0;e<c.elements.length;e++){h=c.elements[e];if(h==c.block||h==c.blockLimit)break;n.checkElementRemovable(h,!0)&&
(g=h)}g&&l.breakParent(g);d&&f.breakParent(d)}a.enlarge(CKEDITOR.ENLARGE_INLINE,1);var c=a.createBookmark(),f=c.startNode,d=this._.definition.alwaysRemoveElement;if(a.collapsed){for(var g=new CKEDITOR.dom.elementPath(f.getParent(),a.root),e,h=0,m;h<g.elements.length&&(m=g.elements[h])&&m!=g.block&&m!=g.blockLimit;h++)if(this.checkElementRemovable(m)){var k;!d&&a.collapsed&&(a.checkBoundaryOfElement(m,CKEDITOR.END)||(k=a.checkBoundaryOfElement(m,CKEDITOR.START)))?(e=m,e.match=k?"start":"end"):(m.mergeSiblings(),
m.is(this.element)?q.call(this,m):y(m,x(this)[m.getName()]))}if(e){d=f;for(h=0;;h++){m=g.elements[h];if(m.equals(e))break;else if(m.match)continue;else m=m.clone();m.append(d);d=m}d["start"==e.match?"insertBefore":"insertAfter"](e)}}else{var l=c.endNode,n=this;b();for(g=f;!g.equals(l);)e=g.getNextSourceNode(),g.type==CKEDITOR.NODE_ELEMENT&&this.checkElementRemovable(g)&&(g.getName()==this.element?q.call(this,g):y(g,x(this)[g.getName()]),e.type==CKEDITOR.NODE_ELEMENT&&e.contains(f)&&(b(),e=f.getNext())),
g=e}a.moveToBookmark(c);a.shrink(CKEDITOR.NODE_ELEMENT,!0)}function g(a){var b=[];a.forEach(function(a){if("true"==a.getAttribute("contenteditable"))return b.push(a),!1},CKEDITOR.NODE_ELEMENT,!0);return b}function l(a){var b=a.getEnclosedNode()||a.getCommonAncestor(!1,!0);(a=(new CKEDITOR.dom.elementPath(b,a.root)).contains(this.element,1))&&!a.isReadOnly()&&w(a,this)}function k(a){var b=a.getCommonAncestor(!0,!0);if(a=(new CKEDITOR.dom.elementPath(b,a.root)).contains(this.element,1)){var b=this._.definition,
c=b.attributes;if(c)for(var f in c)a.removeAttribute(f,c[f]);if(b.styles)for(var d in b.styles)b.styles.hasOwnProperty(d)&&a.removeStyle(d)}}function h(a){var b=a.createBookmark(!0),c=a.createIterator();c.enforceRealBlocks=!0;this._.enterMode&&(c.enlargeBr=this._.enterMode!=CKEDITOR.ENTER_BR);for(var f,d=a.document,g;f=c.getNextParagraph();)!f.isReadOnly()&&(c.activeFilter?c.activeFilter.check(this):1)&&(g=t(this,d,f),m(f,g));a.moveToBookmark(b)}function c(a){var b=a.createBookmark(1),c=a.createIterator();
c.enforceRealBlocks=!0;c.enlargeBr=this._.enterMode!=CKEDITOR.ENTER_BR;for(var f,d;f=c.getNextParagraph();)this.checkElementRemovable(f)&&(f.is("pre")?((d=this._.enterMode==CKEDITOR.ENTER_BR?null:a.document.createElement(this._.enterMode==CKEDITOR.ENTER_P?"p":"div"))&&f.copyAttributes(d),m(f,d)):q.call(this,f));a.moveToBookmark(b)}function m(a,b){var c=!b;c&&(b=a.getDocument().createElement("div"),a.copyAttributes(b));var d=b&&b.is("pre"),g=a.is("pre"),e=!d&&g;if(d&&!g){g=b;(e=a.getBogus())&&e.remove();
e=a.getHtml();e=n(e,/(?:^[ \t\n\r]+)|(?:[ \t\n\r]+$)/g,"");e=e.replace(/[ \t\r\n]*(<br[^>]*>)[ \t\r\n]*/gi,"$1");e=e.replace(/([ \t\n\r]+|&nbsp;)/g," ");e=e.replace(/<br\b[^>]*>/gi,"\n");if(CKEDITOR.env.ie){var h=a.getDocument().createElement("div");h.append(g);g.$.outerHTML="\x3cpre\x3e"+e+"\x3c/pre\x3e";g.copyAttributes(h.getFirst());g=h.getFirst().remove()}else g.setHtml(e);b=g}else e?b=p(c?[a.getHtml()]:f(a),b):a.moveChildren(b);b.replace(a);if(d){var c=b,m;(m=c.getPrevious(H))&&m.type==CKEDITOR.NODE_ELEMENT&&
m.is("pre")&&(d=n(m.getHtml(),/\n$/,"")+"\n\n"+n(c.getHtml(),/^\n/,""),CKEDITOR.env.ie?c.$.outerHTML="\x3cpre\x3e"+d+"\x3c/pre\x3e":c.setHtml(d),m.remove())}else c&&r(b)}function f(a){var b=[];n(a.getOuterHtml(),/(\S\s*)\n(?:\s|(<span[^>]+data-cke-bookmark.*?\/span>))*\n(?!$)/gi,function(a,b,c){return b+"\x3c/pre\x3e"+c+"\x3cpre\x3e"}).replace(/<pre\b.*?>([\s\S]*?)<\/pre>/gi,function(a,c){b.push(c)});return b}function n(a,b,c){var f="",d="";a=a.replace(/(^<span[^>]+data-cke-bookmark.*?\/span>)|(<span[^>]+data-cke-bookmark.*?\/span>$)/gi,
function(a,b,c){b&&(f=b);c&&(d=c);return""});return f+a.replace(b,c)+d}function p(a,b){var c;1<a.length&&(c=new CKEDITOR.dom.documentFragment(b.getDocument()));for(var f=0;f<a.length;f++){var d=a[f],d=d.replace(/(\r\n|\r)/g,"\n"),d=n(d,/^[ \t]*\n/,""),d=n(d,/\n$/,""),d=n(d,/^[ \t]+|[ \t]+$/g,function(a,b){return 1==a.length?"\x26nbsp;":b?" "+CKEDITOR.tools.repeat("\x26nbsp;",a.length-1):CKEDITOR.tools.repeat("\x26nbsp;",a.length-1)+" "}),d=d.replace(/\n/g,"\x3cbr\x3e"),d=d.replace(/[ \t]{2,}/g,function(a){return CKEDITOR.tools.repeat("\x26nbsp;",
a.length-1)+" "});if(c){var g=b.clone();g.setHtml(d);c.append(g)}else b.setHtml(d)}return c||b}function q(a,b){var c=this._.definition,f=c.attributes,c=c.styles,d=x(this)[a.getName()],g=CKEDITOR.tools.isEmpty(f)&&CKEDITOR.tools.isEmpty(c),e;for(e in f)if("class"!=e&&!this._.definition.fullMatch||a.getAttribute(e)==u(e,f[e]))b&&"data-"==e.slice(0,5)||(g=a.hasAttribute(e),a.removeAttribute(e));for(var h in c)this._.definition.fullMatch&&a.getStyle(h)!=u(h,c[h],!0)||(g=g||!!a.getStyle(h),a.removeStyle(h));
y(a,d,B[a.getName()]);g&&(this._.definition.alwaysRemoveElement?r(a,1):!CKEDITOR.dtd.$block[a.getName()]||this._.enterMode==CKEDITOR.ENTER_BR&&!a.hasAttributes()?r(a):a.renameNode(this._.enterMode==CKEDITOR.ENTER_P?"p":"div"))}function v(a){for(var b=x(this),c=a.getElementsByTag(this.element),f,d=c.count();0<=--d;)f=c.getItem(d),f.isReadOnly()||q.call(this,f,!0);for(var g in b)if(g!=this.element)for(c=a.getElementsByTag(g),d=c.count()-1;0<=d;d--)f=c.getItem(d),f.isReadOnly()||y(f,b[g])}function y(a,
b,c){if(b=b&&b.attributes)for(var f=0;f<b.length;f++){var d=b[f][0],g;if(g=a.getAttribute(d)){var e=b[f][1];(null===e||e.test&&e.test(g)||"string"==typeof e&&g==e)&&a.removeAttribute(d)}}c||r(a)}function r(a,b){if(!a.hasAttributes()||b)if(CKEDITOR.dtd.$block[a.getName()]){var c=a.getPrevious(H),f=a.getNext(H);!c||c.type!=CKEDITOR.NODE_TEXT&&c.isBlockBoundary({br:1})||a.append("br",1);!f||f.type!=CKEDITOR.NODE_TEXT&&f.isBlockBoundary({br:1})||a.append("br");a.remove(!0)}else c=a.getFirst(),f=a.getLast(),
a.remove(!0),c&&(c.type==CKEDITOR.NODE_ELEMENT&&c.mergeSiblings(),f&&!c.equals(f)&&f.type==CKEDITOR.NODE_ELEMENT&&f.mergeSiblings())}function t(a,b,c){var f;f=a.element;"*"==f&&(f="span");f=new CKEDITOR.dom.element(f,b);c&&c.copyAttributes(f);f=w(f,a);b.getCustomData("doc_processing_style")&&f.hasAttribute("id")?f.removeAttribute("id"):b.setCustomData("doc_processing_style",1);return f}function w(a,b){var c=b._.definition,f=c.attributes,c=CKEDITOR.style.getStyleText(c);if(f)for(var d in f)a.setAttribute(d,
f[d]);c&&a.setAttribute("style",c);return a}function A(a,b){for(var c in a)a[c]=a[c].replace(E,function(a,c){return b[c]})}function x(a){if(a._.overrides)return a._.overrides;var b=a._.overrides={},c=a._.definition.overrides;if(c){CKEDITOR.tools.isArray(c)||(c=[c]);for(var f=0;f<c.length;f++){var d=c[f],g,e;"string"==typeof d?g=d.toLowerCase():(g=d.element?d.element.toLowerCase():a.element,e=d.attributes);d=b[g]||(b[g]={});if(e){var d=d.attributes=d.attributes||[],h;for(h in e)d.push([h.toLowerCase(),
e[h]])}}}return b}function u(a,b,c){var f=new CKEDITOR.dom.element("span");f[c?"setStyle":"setAttribute"](a,b);return f[c?"getStyle":"getAttribute"](a)}function C(a,b){function c(a,b){return"font-family"==b.toLowerCase()?a.replace(/["']/g,""):a}"string"==typeof a&&(a=CKEDITOR.tools.parseCssText(a));"string"==typeof b&&(b=CKEDITOR.tools.parseCssText(b,!0));for(var f in a)if(!(f in b)||c(b[f],f)!=c(a[f],f)&&"inherit"!=a[f]&&"inherit"!=b[f])return!1;return!0}function z(a,b,c){var f=a.document,d=a.getRanges();
b=b?this.removeFromRange:this.applyToRange;var g,e;if(a.isFake&&a.isInTable())for(g=[],e=0;e<d.length;e++)g.push(d[e].clone());for(var h=d.createIterator();e=h.getNextRange();)b.call(this,e,c);a.selectRanges(g||d);f.removeCustomData("doc_processing_style")}var B={address:1,div:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1,p:1,pre:1,section:1,header:1,footer:1,nav:1,article:1,aside:1,figure:1,dialog:1,hgroup:1,time:1,meter:1,menu:1,command:1,keygen:1,output:1,progress:1,details:1,datagrid:1,datalist:1},G={a:1,blockquote:1,
embed:1,hr:1,img:1,li:1,object:1,ol:1,table:1,td:1,tr:1,th:1,ul:1,dl:1,dt:1,dd:1,form:1,audio:1,video:1},F=/\s*(?:;\s*|$)/,E=/#\((.+?)\)/g,J=CKEDITOR.dom.walker.bookmark(0,1),H=CKEDITOR.dom.walker.whitespaces(1);CKEDITOR.style=function(a,b){if("string"==typeof a.type)return new CKEDITOR.style.customHandlers[a.type](a);var c=a.attributes;c&&c.style&&(a.styles=CKEDITOR.tools.extend({},a.styles,CKEDITOR.tools.parseCssText(c.style)),delete c.style);b&&(a=CKEDITOR.tools.clone(a),A(a.attributes,b),A(a.styles,
b));c=this.element=a.element?"string"==typeof a.element?a.element.toLowerCase():a.element:"*";this.type=a.type||(B[c]?CKEDITOR.STYLE_BLOCK:G[c]?CKEDITOR.STYLE_OBJECT:CKEDITOR.STYLE_INLINE);"object"==typeof this.element&&(this.type=CKEDITOR.STYLE_OBJECT);this._={definition:a}};CKEDITOR.style.prototype={apply:function(a){if(a instanceof CKEDITOR.dom.document)return z.call(this,a.getSelection());if(this.checkApplicable(a.elementPath(),a)){var b=this._.enterMode;b||(this._.enterMode=a.activeEnterMode);
z.call(this,a.getSelection(),0,a);this._.enterMode=b}},remove:function(a){if(a instanceof CKEDITOR.dom.document)return z.call(this,a.getSelection(),1);if(this.checkApplicable(a.elementPath(),a)){var b=this._.enterMode;b||(this._.enterMode=a.activeEnterMode);z.call(this,a.getSelection(),1,a);this._.enterMode=b}},applyToRange:function(a){this.applyToRange=this.type==CKEDITOR.STYLE_INLINE?b:this.type==CKEDITOR.STYLE_BLOCK?h:this.type==CKEDITOR.STYLE_OBJECT?l:null;return this.applyToRange(a)},removeFromRange:function(a){this.removeFromRange=
this.type==CKEDITOR.STYLE_INLINE?d:this.type==CKEDITOR.STYLE_BLOCK?c:this.type==CKEDITOR.STYLE_OBJECT?k:null;return this.removeFromRange(a)},applyToObject:function(a){w(a,this)},checkActive:function(a,b){switch(this.type){case CKEDITOR.STYLE_BLOCK:return this.checkElementRemovable(a.block||a.blockLimit,!0,b);case CKEDITOR.STYLE_OBJECT:case CKEDITOR.STYLE_INLINE:for(var c=a.elements,f=0,d;f<c.length;f++)if(d=c[f],this.type!=CKEDITOR.STYLE_INLINE||d!=a.block&&d!=a.blockLimit){if(this.type==CKEDITOR.STYLE_OBJECT){var g=
d.getName();if(!("string"==typeof this.element?g==this.element:g in this.element))continue}if(this.checkElementRemovable(d,!0,b))return!0}}return!1},checkApplicable:function(a,b,c){b&&b instanceof CKEDITOR.filter&&(c=b);if(c&&!c.check(this))return!1;switch(this.type){case CKEDITOR.STYLE_OBJECT:return!!a.contains(this.element);case CKEDITOR.STYLE_BLOCK:return!!a.blockLimit.getDtd()[this.element]}return!0},checkElementMatch:function(a,b){var c=this._.definition;if(!a||!c.ignoreReadonly&&a.isReadOnly())return!1;
var f=a.getName();if("string"==typeof this.element?f==this.element:f in this.element){if(!b&&!a.hasAttributes())return!0;if(f=c._AC)c=f;else{var f={},d=0,g=c.attributes;if(g)for(var e in g)d++,f[e]=g[e];if(e=CKEDITOR.style.getStyleText(c))f.style||d++,f.style=e;f._length=d;c=c._AC=f}if(c._length){for(var h in c)if("_length"!=h)if(f=a.getAttribute(h)||"","style"==h?C(c[h],f):c[h]==f){if(!b)return!0}else if(b)return!1;if(b)return!0}else return!0}return!1},checkElementRemovable:function(a,b,c){if(this.checkElementMatch(a,
b,c))return!0;if(b=x(this)[a.getName()]){var f;if(!(b=b.attributes))return!0;for(c=0;c<b.length;c++)if(f=b[c][0],f=a.getAttribute(f)){var d=b[c][1];if(null===d)return!0;if("string"==typeof d){if(f==d)return!0}else if(d.test(f))return!0}}return!1},buildPreview:function(a){var b=this._.definition,c=[],f=b.element;"bdo"==f&&(f="span");var c=["\x3c",f],d=b.attributes;if(d)for(var g in d)c.push(" ",g,'\x3d"',d[g],'"');(d=CKEDITOR.style.getStyleText(b))&&c.push(' style\x3d"',d,'"');c.push("\x3e",a||b.name,
"\x3c/",f,"\x3e");return c.join("")},getDefinition:function(){return this._.definition}};CKEDITOR.style.getStyleText=function(a){var b=a._ST;if(b)return b;var b=a.styles,c=a.attributes&&a.attributes.style||"",f="";c.length&&(c=c.replace(F,";"));for(var d in b){var g=b[d],e=(d+":"+g).replace(F,";");"inherit"==g?f+=e:c+=e}c.length&&(c=CKEDITOR.tools.normalizeCssText(c,!0));return a._ST=c+f};CKEDITOR.style.customHandlers={};CKEDITOR.style.addCustomHandler=function(a){var b=function(a){this._={definition:a};
this.setup&&this.setup(a)};b.prototype=CKEDITOR.tools.extend(CKEDITOR.tools.prototypedCopy(CKEDITOR.style.prototype),{assignedTo:CKEDITOR.STYLE_OBJECT},a,!0);return this.customHandlers[a.type]=b};var M=CKEDITOR.POSITION_PRECEDING|CKEDITOR.POSITION_IDENTICAL|CKEDITOR.POSITION_IS_CONTAINED,K=CKEDITOR.POSITION_FOLLOWING|CKEDITOR.POSITION_IDENTICAL|CKEDITOR.POSITION_IS_CONTAINED}(),CKEDITOR.styleCommand=function(a,e){this.requiredContent=this.allowedContent=this.style=a;CKEDITOR.tools.extend(this,e,!0)},
CKEDITOR.styleCommand.prototype.exec=function(a){a.focus();this.state==CKEDITOR.TRISTATE_OFF?a.applyStyle(this.style):this.state==CKEDITOR.TRISTATE_ON&&a.removeStyle(this.style)},CKEDITOR.stylesSet=new CKEDITOR.resourceManager("","stylesSet"),CKEDITOR.addStylesSet=CKEDITOR.tools.bind(CKEDITOR.stylesSet.add,CKEDITOR.stylesSet),CKEDITOR.loadStylesSet=function(a,e,b){CKEDITOR.stylesSet.addExternal(a,e,"");CKEDITOR.stylesSet.load(a,b)},CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{attachStyleStateChange:function(a,
e){var b=this._.styleStateChangeCallbacks;b||(b=this._.styleStateChangeCallbacks=[],this.on("selectionChange",function(a){for(var g=0;g<b.length;g++){var e=b[g],k=e.style.checkActive(a.data.path,this)?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF;e.fn.call(this,k)}}));b.push({style:a,fn:e})},applyStyle:function(a){a.apply(this)},removeStyle:function(a){a.remove(this)},getStylesSet:function(a){if(this._.stylesDefinitions)a(this._.stylesDefinitions);else{var e=this,b=e.config.stylesCombo_stylesSet||e.config.stylesSet;
if(!1===b)a(null);else if(b instanceof Array)e._.stylesDefinitions=b,a(b);else{b||(b="default");var b=b.split(":"),d=b[0];CKEDITOR.stylesSet.addExternal(d,b[1]?b.slice(1).join(":"):CKEDITOR.getUrl("styles.js"),"");CKEDITOR.stylesSet.load(d,function(b){e._.stylesDefinitions=b[d];a(e._.stylesDefinitions)})}}}}),CKEDITOR.dom.comment=function(a,e){"string"==typeof a&&(a=(e?e.$:document).createComment(a));CKEDITOR.dom.domObject.call(this,a)},CKEDITOR.dom.comment.prototype=new CKEDITOR.dom.node,CKEDITOR.tools.extend(CKEDITOR.dom.comment.prototype,
{type:CKEDITOR.NODE_COMMENT,getOuterHtml:function(){return"\x3c!--"+this.$.nodeValue+"--\x3e"}}),"use strict",function(){var a={},e={},b;for(b in CKEDITOR.dtd.$blockLimit)b in CKEDITOR.dtd.$list||(a[b]=1);for(b in CKEDITOR.dtd.$block)b in CKEDITOR.dtd.$blockLimit||b in CKEDITOR.dtd.$empty||(e[b]=1);CKEDITOR.dom.elementPath=function(b,g){var l=null,k=null,h=[],c=b,m;g=g||b.getDocument().getBody();c||(c=g);do if(c.type==CKEDITOR.NODE_ELEMENT){h.push(c);if(!this.lastElement&&(this.lastElement=c,c.is(CKEDITOR.dtd.$object)||
"false"==c.getAttribute("contenteditable")))continue;if(c.equals(g))break;if(!k&&(m=c.getName(),"true"==c.getAttribute("contenteditable")?k=c:!l&&e[m]&&(l=c),a[m])){if(m=!l&&"div"==m){a:{m=c.getChildren();for(var f=0,n=m.count();f<n;f++){var p=m.getItem(f);if(p.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$block[p.getName()]){m=!0;break a}}m=!1}m=!m}m?l=c:k=c}}while(c=c.getParent());k||(k=g);this.block=l;this.blockLimit=k;this.root=g;this.elements=h}}(),CKEDITOR.dom.elementPath.prototype={compare:function(a){var e=
this.elements;a=a&&a.elements;if(!a||e.length!=a.length)return!1;for(var b=0;b<e.length;b++)if(!e[b].equals(a[b]))return!1;return!0},contains:function(a,e,b){var d=0,g;"string"==typeof a&&(g=function(b){return b.getName()==a});a instanceof CKEDITOR.dom.element?g=function(b){return b.equals(a)}:CKEDITOR.tools.isArray(a)?g=function(b){return-1<CKEDITOR.tools.indexOf(a,b.getName())}:"function"==typeof a?g=a:"object"==typeof a&&(g=function(b){return b.getName()in a});var l=this.elements,k=l.length;e&&
(b?d+=1:--k);b&&(l=Array.prototype.slice.call(l,0),l.reverse());for(;d<k;d++)if(g(l[d]))return l[d];return null},isContextFor:function(a){var e;return a in CKEDITOR.dtd.$block?(e=this.contains(CKEDITOR.dtd.$intermediate)||this.root.equals(this.block)&&this.block||this.blockLimit,!!e.getDtd()[a]):!0},direction:function(){return(this.block||this.blockLimit||this.root).getDirection(1)}},CKEDITOR.dom.text=function(a,e){"string"==typeof a&&(a=(e?e.$:document).createTextNode(a));this.$=a},CKEDITOR.dom.text.prototype=
new CKEDITOR.dom.node,CKEDITOR.tools.extend(CKEDITOR.dom.text.prototype,{type:CKEDITOR.NODE_TEXT,getLength:function(){return this.$.nodeValue.length},getText:function(){return this.$.nodeValue},setText:function(a){this.$.nodeValue=a},split:function(a){var e=this.$.parentNode,b=e.childNodes.length,d=this.getLength(),g=this.getDocument(),l=new CKEDITOR.dom.text(this.$.splitText(a),g);e.childNodes.length==b&&(a>=d?(l=g.createText(""),l.insertAfter(this)):(a=g.createText(""),a.insertAfter(l),a.remove()));
return l},substring:function(a,e){return"number"!=typeof e?this.$.nodeValue.substr(a):this.$.nodeValue.substring(a,e)}}),function(){function a(a,d,g){var e=a.serializable,k=d[g?"endContainer":"startContainer"],h=g?"endOffset":"startOffset",c=e?d.document.getById(a.startNode):a.startNode;a=e?d.document.getById(a.endNode):a.endNode;k.equals(c.getPrevious())?(d.startOffset=d.startOffset-k.getLength()-a.getPrevious().getLength(),k=a.getNext()):k.equals(a.getPrevious())&&(d.startOffset-=k.getLength(),
k=a.getNext());k.equals(c.getParent())&&d[h]++;k.equals(a.getParent())&&d[h]++;d[g?"endContainer":"startContainer"]=k;return d}CKEDITOR.dom.rangeList=function(a){if(a instanceof CKEDITOR.dom.rangeList)return a;a?a instanceof CKEDITOR.dom.range&&(a=[a]):a=[];return CKEDITOR.tools.extend(a,e)};var e={createIterator:function(){var a=this,d=CKEDITOR.dom.walker.bookmark(),g=[],e;return{getNextRange:function(k){e=void 0===e?0:e+1;var h=a[e];if(h&&1<a.length){if(!e)for(var c=a.length-1;0<=c;c--)g.unshift(a[c].createBookmark(!0));
if(k)for(var m=0;a[e+m+1];){var f=h.document;k=0;c=f.getById(g[m].endNode);for(f=f.getById(g[m+1].startNode);;){c=c.getNextSourceNode(!1);if(f.equals(c))k=1;else if(d(c)||c.type==CKEDITOR.NODE_ELEMENT&&c.isBlockBoundary())continue;break}if(!k)break;m++}for(h.moveToBookmark(g.shift());m--;)c=a[++e],c.moveToBookmark(g.shift()),h.setEnd(c.endContainer,c.endOffset)}return h}}},createBookmarks:function(b){for(var d=[],g,e=0;e<this.length;e++){d.push(g=this[e].createBookmark(b,!0));for(var k=e+1;k<this.length;k++)this[k]=
a(g,this[k]),this[k]=a(g,this[k],!0)}return d},createBookmarks2:function(a){for(var d=[],g=0;g<this.length;g++)d.push(this[g].createBookmark2(a));return d},moveToBookmarks:function(a){for(var d=0;d<this.length;d++)this[d].moveToBookmark(a[d])}}}(),function(){function a(){return CKEDITOR.getUrl(CKEDITOR.skinName.split(",")[1]||"skins/"+CKEDITOR.skinName.split(",")[0]+"/")}function e(b){var c=CKEDITOR.skin["ua_"+b],d=CKEDITOR.env;if(c)for(var c=c.split(",").sort(function(a,b){return a>b?-1:1}),g=0,
e;g<c.length;g++)if(e=c[g],d.ie&&(e.replace(/^ie/,"")==d.version||d.quirks&&"iequirks"==e)&&(e="ie"),d[e]){b+="_"+c[g];break}return CKEDITOR.getUrl(a()+b+".css")}function b(a,b){l[a]||(CKEDITOR.document.appendStyleSheet(e(a)),l[a]=1);b&&b()}function d(a){var b=a.getById(k);b||(b=a.getHead().append("style"),b.setAttribute("id",k),b.setAttribute("type","text/css"));return b}function g(a,b,c){var d,g,e;if(CKEDITOR.env.webkit)for(b=b.split("}").slice(0,-1),g=0;g<b.length;g++)b[g]=b[g].split("{");for(var h=
0;h<a.length;h++)if(CKEDITOR.env.webkit)for(g=0;g<b.length;g++){e=b[g][1];for(d=0;d<c.length;d++)e=e.replace(c[d][0],c[d][1]);a[h].$.sheet.addRule(b[g][0],e)}else{e=b;for(d=0;d<c.length;d++)e=e.replace(c[d][0],c[d][1]);CKEDITOR.env.ie&&11>CKEDITOR.env.version?a[h].$.styleSheet.cssText+=e:a[h].$.innerHTML+=e}}var l={};CKEDITOR.skin={path:a,loadPart:function(c,f){CKEDITOR.skin.name!=CKEDITOR.skinName.split(",")[0]?CKEDITOR.scriptLoader.load(CKEDITOR.getUrl(a()+"skin.js"),function(){b(c,f)}):b(c,f)},
getPath:function(a){return CKEDITOR.getUrl(e(a))},icons:{},addIcon:function(a,b,c,d){a=a.toLowerCase();this.icons[a]||(this.icons[a]={path:b,offset:c||0,bgsize:d||"16px"})},getIconStyle:function(a,b,c,d,g){var e;a&&(a=a.toLowerCase(),b&&(e=this.icons[a+"-rtl"]),e||(e=this.icons[a]));a=c||e&&e.path||"";d=d||e&&e.offset;g=g||e&&e.bgsize||"16px";a&&(a=a.replace(/'/g,"\\'"));return a&&"background-image:url('"+CKEDITOR.getUrl(a)+"');background-position:0 "+d+"px;background-size:"+g+";"}};CKEDITOR.tools.extend(CKEDITOR.editor.prototype,
{getUiColor:function(){return this.uiColor},setUiColor:function(a){var b=d(CKEDITOR.document);return(this.setUiColor=function(a){this.uiColor=a;var d=CKEDITOR.skin.chameleon,e="",m="";"function"==typeof d&&(e=d(this,"editor"),m=d(this,"panel"));a=[[c,a]];g([b],e,a);g(h,m,a)}).call(this,a)}});var k="cke_ui_color",h=[],c=/\$color/g;CKEDITOR.on("instanceLoaded",function(a){if(!CKEDITOR.env.ie||!CKEDITOR.env.quirks){var b=a.editor;a=function(a){a=(a.data[0]||a.data).element.getElementsByTag("iframe").getItem(0).getFrameDocument();
if(!a.getById("cke_ui_color")){a=d(a);h.push(a);var e=b.getUiColor();e&&g([a],CKEDITOR.skin.chameleon(b,"panel"),[[c,e]])}};b.on("panelShow",a);b.on("menuShow",a);b.config.uiColor&&b.setUiColor(b.config.uiColor)}})}(),function(){if(CKEDITOR.env.webkit)CKEDITOR.env.hc=!1;else{var a=CKEDITOR.dom.element.createFromHtml('\x3cdiv style\x3d"width:0;height:0;position:absolute;left:-10000px;border:1px solid;border-color:red blue"\x3e\x3c/div\x3e',CKEDITOR.document);a.appendTo(CKEDITOR.document.getHead());
try{var e=a.getComputedStyle("border-top-color"),b=a.getComputedStyle("border-right-color");CKEDITOR.env.hc=!(!e||e!=b)}catch(d){CKEDITOR.env.hc=!1}a.remove()}CKEDITOR.env.hc&&(CKEDITOR.env.cssClass+=" cke_hc");CKEDITOR.document.appendStyleText(".cke{visibility:hidden;}");CKEDITOR.status="loaded";CKEDITOR.fireOnce("loaded");if(a=CKEDITOR._.pending)for(delete CKEDITOR._.pending,e=0;e<a.length;e++)CKEDITOR.editor.prototype.constructor.apply(a[e][0],a[e][1]),CKEDITOR.add(a[e][0])}(),CKEDITOR.skin.name=
"moono-lisa",CKEDITOR.skin.ua_editor="ie,iequirks,ie8,gecko",CKEDITOR.skin.ua_dialog="ie,iequirks,ie8",CKEDITOR.skin.chameleon=function(){var a=function(){return function(a,d){for(var g=a.match(/[^#]./g),e=0;3>e;e++){var k=e,h;h=parseInt(g[e],16);h=("0"+(0>d?0|h*(1+d):0|h+(255-h)*d).toString(16)).slice(-2);g[k]=h}return"#"+g.join("")}}(),e={editor:new CKEDITOR.template("{id}.cke_chrome [border-color:{defaultBorder};] {id} .cke_top [ background-color:{defaultBackground};border-bottom-color:{defaultBorder};] {id} .cke_bottom [background-color:{defaultBackground};border-top-color:{defaultBorder};] {id} .cke_resizer [border-right-color:{ckeResizer}] {id} .cke_dialog_title [background-color:{defaultBackground};border-bottom-color:{defaultBorder};] {id} .cke_dialog_footer [background-color:{defaultBackground};outline-color:{defaultBorder};] {id} .cke_dialog_tab [background-color:{dialogTab};border-color:{defaultBorder};] {id} .cke_dialog_tab:hover [background-color:{lightBackground};] {id} .cke_dialog_contents [border-top-color:{defaultBorder};] {id} .cke_dialog_tab_selected, {id} .cke_dialog_tab_selected:hover [background:{dialogTabSelected};border-bottom-color:{dialogTabSelectedBorder};] {id} .cke_dialog_body [background:{dialogBody};border-color:{defaultBorder};] {id} a.cke_button_off:hover,{id} a.cke_button_off:focus,{id} a.cke_button_off:active [background-color:{darkBackground};border-color:{toolbarElementsBorder};] {id} .cke_button_on [background-color:{ckeButtonOn};border-color:{toolbarElementsBorder};] {id} .cke_toolbar_separator,{id} .cke_toolgroup a.cke_button:last-child:after,{id} .cke_toolgroup a.cke_button.cke_button_disabled:hover:last-child:after [background-color: {toolbarElementsBorder};border-color: {toolbarElementsBorder};] {id} a.cke_combo_button:hover,{id} a.cke_combo_button:focus,{id} .cke_combo_on a.cke_combo_button [border-color:{toolbarElementsBorder};background-color:{darkBackground};] {id} .cke_combo:after [border-color:{toolbarElementsBorder};] {id} .cke_path_item [color:{elementsPathColor};] {id} a.cke_path_item:hover,{id} a.cke_path_item:focus,{id} a.cke_path_item:active [background-color:{darkBackground};] {id}.cke_panel [border-color:{defaultBorder};] "),
panel:new CKEDITOR.template(".cke_panel_grouptitle [background-color:{lightBackground};border-color:{defaultBorder};] .cke_menubutton_icon [background-color:{menubuttonIcon};] .cke_menubutton:hover,.cke_menubutton:focus,.cke_menubutton:active [background-color:{menubuttonHover};] .cke_menubutton:hover .cke_menubutton_icon, .cke_menubutton:focus .cke_menubutton_icon, .cke_menubutton:active .cke_menubutton_icon [background-color:{menubuttonIconHover};] .cke_menubutton_disabled:hover .cke_menubutton_icon,.cke_menubutton_disabled:focus .cke_menubutton_icon,.cke_menubutton_disabled:active .cke_menubutton_icon [background-color:{menubuttonIcon};] .cke_menuseparator [background-color:{menubuttonIcon};] a:hover.cke_colorbox, a:active.cke_colorbox [border-color:{defaultBorder};] a:hover.cke_colorauto, a:hover.cke_colormore, a:active.cke_colorauto, a:active.cke_colormore [background-color:{ckeColorauto};border-color:{defaultBorder};] ")};
return function(b,d){var g=a(b.uiColor,.4),g={id:"."+b.id,defaultBorder:a(g,-.2),toolbarElementsBorder:a(g,-.25),defaultBackground:g,lightBackground:a(g,.8),darkBackground:a(g,-.15),ckeButtonOn:a(g,.4),ckeResizer:a(g,-.4),ckeColorauto:a(g,.8),dialogBody:a(g,.7),dialogTab:a(g,.65),dialogTabSelected:"#FFF",dialogTabSelectedBorder:"#FFF",elementsPathColor:a(g,-.6),menubuttonHover:a(g,.1),menubuttonIcon:a(g,.5),menubuttonIconHover:a(g,.3)};return e[d].output(g).replace(/\[/g,"{").replace(/\]/g,"}")}}(),
CKEDITOR.plugins.add("dialogui",{onLoad:function(){var a=function(a){this._||(this._={});this._["default"]=this._.initValue=a["default"]||"";this._.required=a.required||!1;for(var b=[this._],f=1;f<arguments.length;f++)b.push(arguments[f]);b.push(!0);CKEDITOR.tools.extend.apply(CKEDITOR.tools,b);return this._},e={build:function(a,b,f){return new CKEDITOR.ui.dialog.textInput(a,b,f)}},b={build:function(a,b,f){return new CKEDITOR.ui.dialog[b.type](a,b,f)}},d={isChanged:function(){return this.getValue()!=
this.getInitValue()},reset:function(a){this.setValue(this.getInitValue(),a)},setInitValue:function(){this._.initValue=this.getValue()},resetInitValue:function(){this._.initValue=this._["default"]},getInitValue:function(){return this._.initValue}},g=CKEDITOR.tools.extend({},CKEDITOR.ui.dialog.uiElement.prototype.eventProcessors,{onChange:function(a,b){this._.domOnChangeRegistered||(a.on("load",function(){this.getInputElement().on("change",function(){a.parts.dialog.isVisible()&&this.fire("change",{value:this.getValue()})},
this)},this),this._.domOnChangeRegistered=!0);this.on("change",b)}},!0),l=/^on([A-Z]\w+)/,k=function(a){for(var b in a)(l.test(b)||"title"==b||"type"==b)&&delete a[b];return a},h=function(a){a=a.data.getKeystroke();a==CKEDITOR.SHIFT+CKEDITOR.ALT+36?this.setDirectionMarker("ltr"):a==CKEDITOR.SHIFT+CKEDITOR.ALT+35&&this.setDirectionMarker("rtl")};CKEDITOR.tools.extend(CKEDITOR.ui.dialog,{labeledElement:function(b,d,f,g){if(!(4>arguments.length)){var e=a.call(this,d);e.labelId=CKEDITOR.tools.getNextId()+
"_label";this._.children=[];var h={role:d.role||"presentation"};d.includeLabel&&(h["aria-labelledby"]=e.labelId);CKEDITOR.ui.dialog.uiElement.call(this,b,d,f,"div",null,h,function(){var a=[],f=d.required?" cke_required":"";"horizontal"!=d.labelLayout?a.push('\x3clabel class\x3d"cke_dialog_ui_labeled_label'+f+'" ',' id\x3d"'+e.labelId+'"',e.inputId?' for\x3d"'+e.inputId+'"':"",(d.labelStyle?' style\x3d"'+d.labelStyle+'"':"")+"\x3e",d.label,"\x3c/label\x3e",'\x3cdiv class\x3d"cke_dialog_ui_labeled_content"',
d.controlStyle?' style\x3d"'+d.controlStyle+'"':"",' role\x3d"presentation"\x3e',g.call(this,b,d),"\x3c/div\x3e"):(f={type:"hbox",widths:d.widths,padding:0,children:[{type:"html",html:'\x3clabel class\x3d"cke_dialog_ui_labeled_label'+f+'" id\x3d"'+e.labelId+'" for\x3d"'+e.inputId+'"'+(d.labelStyle?' style\x3d"'+d.labelStyle+'"':"")+"\x3e"+CKEDITOR.tools.htmlEncode(d.label)+"\x3c/label\x3e"},{type:"html",html:'\x3cspan class\x3d"cke_dialog_ui_labeled_content"'+(d.controlStyle?' style\x3d"'+d.controlStyle+
'"':"")+"\x3e"+g.call(this,b,d)+"\x3c/span\x3e"}]},CKEDITOR.dialog._.uiElementBuilders.hbox.build(b,f,a));return a.join("")})}},textInput:function(b,d,f){if(!(3>arguments.length)){a.call(this,d);var g=this._.inputId=CKEDITOR.tools.getNextId()+"_textInput",e={"class":"cke_dialog_ui_input_"+d.type,id:g,type:d.type};d.validate&&(this.validate=d.validate);d.maxLength&&(e.maxlength=d.maxLength);d.size&&(e.size=d.size);d.inputStyle&&(e.style=d.inputStyle);var k=this,l=!1;b.on("load",function(){k.getInputElement().on("keydown",
function(a){13==a.data.getKeystroke()&&(l=!0)});k.getInputElement().on("keyup",function(a){13==a.data.getKeystroke()&&l&&(b.getButton("ok")&&setTimeout(function(){b.getButton("ok").click()},0),l=!1);k.bidi&&h.call(k,a)},null,null,1E3)});CKEDITOR.ui.dialog.labeledElement.call(this,b,d,f,function(){var a=['\x3cdiv class\x3d"cke_dialog_ui_input_',d.type,'" role\x3d"presentation"'];d.width&&a.push('style\x3d"width:'+d.width+'" ');a.push("\x3e\x3cinput ");e["aria-labelledby"]=this._.labelId;this._.required&&
(e["aria-required"]=this._.required);for(var b in e)a.push(b+'\x3d"'+e[b]+'" ');a.push(" /\x3e\x3c/div\x3e");return a.join("")})}},textarea:function(b,d,f){if(!(3>arguments.length)){a.call(this,d);var g=this,e=this._.inputId=CKEDITOR.tools.getNextId()+"_textarea",k={};d.validate&&(this.validate=d.validate);k.rows=d.rows||5;k.cols=d.cols||20;k["class"]="cke_dialog_ui_input_textarea "+(d["class"]||"");"undefined"!=typeof d.inputStyle&&(k.style=d.inputStyle);d.dir&&(k.dir=d.dir);if(g.bidi)b.on("load",
function(){g.getInputElement().on("keyup",h)},g);CKEDITOR.ui.dialog.labeledElement.call(this,b,d,f,function(){k["aria-labelledby"]=this._.labelId;this._.required&&(k["aria-required"]=this._.required);var a=['\x3cdiv class\x3d"cke_dialog_ui_input_textarea" role\x3d"presentation"\x3e\x3ctextarea id\x3d"',e,'" '],b;for(b in k)a.push(b+'\x3d"'+CKEDITOR.tools.htmlEncode(k[b])+'" ');a.push("\x3e",CKEDITOR.tools.htmlEncode(g._["default"]),"\x3c/textarea\x3e\x3c/div\x3e");return a.join("")})}},checkbox:function(b,
d,f){if(!(3>arguments.length)){var g=a.call(this,d,{"default":!!d["default"]});d.validate&&(this.validate=d.validate);CKEDITOR.ui.dialog.uiElement.call(this,b,d,f,"span",null,null,function(){var a=CKEDITOR.tools.extend({},d,{id:d.id?d.id+"_checkbox":CKEDITOR.tools.getNextId()+"_checkbox"},!0),f=[],e=CKEDITOR.tools.getNextId()+"_label",h={"class":"cke_dialog_ui_checkbox_input",type:"checkbox","aria-labelledby":e};k(a);d["default"]&&(h.checked="checked");"undefined"!=typeof a.inputStyle&&(a.style=a.inputStyle);
g.checkbox=new CKEDITOR.ui.dialog.uiElement(b,a,f,"input",null,h);f.push(' \x3clabel id\x3d"',e,'" for\x3d"',h.id,'"'+(d.labelStyle?' style\x3d"'+d.labelStyle+'"':"")+"\x3e",CKEDITOR.tools.htmlEncode(d.label),"\x3c/label\x3e");return f.join("")})}},radio:function(b,d,f){if(!(3>arguments.length)){a.call(this,d);this._["default"]||(this._["default"]=this._.initValue=d.items[0][1]);d.validate&&(this.validate=d.validate);var g=[],e=this;d.role="radiogroup";d.includeLabel=!0;CKEDITOR.ui.dialog.labeledElement.call(this,
b,d,f,function(){for(var a=[],f=[],h=(d.id?d.id:CKEDITOR.tools.getNextId())+"_radio",l=0;l<d.items.length;l++){var t=d.items[l],w=void 0!==t[2]?t[2]:t[0],A=void 0!==t[1]?t[1]:t[0],x=CKEDITOR.tools.getNextId()+"_radio_input",u=x+"_label",x=CKEDITOR.tools.extend({},d,{id:x,title:null,type:null},!0),w=CKEDITOR.tools.extend({},x,{title:w},!0),C={type:"radio","class":"cke_dialog_ui_radio_input",name:h,value:A,"aria-labelledby":u},z=[];e._["default"]==A&&(C.checked="checked");k(x);k(w);"undefined"!=typeof x.inputStyle&&
(x.style=x.inputStyle);x.keyboardFocusable=!0;g.push(new CKEDITOR.ui.dialog.uiElement(b,x,z,"input",null,C));z.push(" ");new CKEDITOR.ui.dialog.uiElement(b,w,z,"label",null,{id:u,"for":C.id},t[0]);a.push(z.join(""))}new CKEDITOR.ui.dialog.hbox(b,g,a,f);return f.join("")});this._.children=g}},button:function(b,d,f){if(arguments.length){"function"==typeof d&&(d=d(b.getParentEditor()));a.call(this,d,{disabled:d.disabled||!1});CKEDITOR.event.implementOn(this);var g=this;b.on("load",function(){var a=this.getElement();
(function(){a.on("click",function(a){g.click();a.data.preventDefault()});a.on("keydown",function(a){a.data.getKeystroke()in{32:1}&&(g.click(),a.data.preventDefault())})})();a.unselectable()},this);var e=CKEDITOR.tools.extend({},d);delete e.style;var h=CKEDITOR.tools.getNextId()+"_label";CKEDITOR.ui.dialog.uiElement.call(this,b,e,f,"a",null,{style:d.style,href:"javascript:void(0)",title:d.label,hidefocus:"true","class":d["class"],role:"button","aria-labelledby":h},'\x3cspan id\x3d"'+h+'" class\x3d"cke_dialog_ui_button"\x3e'+
CKEDITOR.tools.htmlEncode(d.label)+"\x3c/span\x3e")}},select:function(b,d,f){if(!(3>arguments.length)){var g=a.call(this,d);d.validate&&(this.validate=d.validate);g.inputId=CKEDITOR.tools.getNextId()+"_select";CKEDITOR.ui.dialog.labeledElement.call(this,b,d,f,function(){var a=CKEDITOR.tools.extend({},d,{id:d.id?d.id+"_select":CKEDITOR.tools.getNextId()+"_select"},!0),f=[],e=[],h={id:g.inputId,"class":"cke_dialog_ui_input_select","aria-labelledby":this._.labelId};f.push('\x3cdiv class\x3d"cke_dialog_ui_input_',
d.type,'" role\x3d"presentation"');d.width&&f.push('style\x3d"width:'+d.width+'" ');f.push("\x3e");void 0!==d.size&&(h.size=d.size);void 0!==d.multiple&&(h.multiple=d.multiple);k(a);for(var l=0,t;l<d.items.length&&(t=d.items[l]);l++)e.push('\x3coption value\x3d"',CKEDITOR.tools.htmlEncode(void 0!==t[1]?t[1]:t[0]).replace(/"/g,"\x26quot;"),'" /\x3e ',CKEDITOR.tools.htmlEncode(t[0]));"undefined"!=typeof a.inputStyle&&(a.style=a.inputStyle);g.select=new CKEDITOR.ui.dialog.uiElement(b,a,f,"select",null,
h,e.join(""));f.push("\x3c/div\x3e");return f.join("")})}},file:function(b,d,f){if(!(3>arguments.length)){void 0===d["default"]&&(d["default"]="");var g=CKEDITOR.tools.extend(a.call(this,d),{definition:d,buttons:[]});d.validate&&(this.validate=d.validate);b.on("load",function(){CKEDITOR.document.getById(g.frameId).getParent().addClass("cke_dialog_ui_input_file")});CKEDITOR.ui.dialog.labeledElement.call(this,b,d,f,function(){g.frameId=CKEDITOR.tools.getNextId()+"_fileInput";var a=['\x3ciframe frameborder\x3d"0" allowtransparency\x3d"0" class\x3d"cke_dialog_ui_input_file" role\x3d"presentation" id\x3d"',
g.frameId,'" title\x3d"',d.label,'" src\x3d"javascript:void('];a.push(CKEDITOR.env.ie?"(function(){"+encodeURIComponent("document.open();("+CKEDITOR.tools.fixDomain+")();document.close();")+"})()":"0");a.push(')"\x3e\x3c/iframe\x3e');return a.join("")})}},fileButton:function(b,d,f){var g=this;if(!(3>arguments.length)){a.call(this,d);d.validate&&(this.validate=d.validate);var e=CKEDITOR.tools.extend({},d),h=e.onClick;e.className=(e.className?e.className+" ":"")+"cke_dialog_ui_button";e.onClick=function(a){var f=
d["for"];h&&!1===h.call(this,a)||(b.getContentElement(f[0],f[1]).submit(),this.disable())};b.on("load",function(){b.getContentElement(d["for"][0],d["for"][1])._.buttons.push(g)});CKEDITOR.ui.dialog.button.call(this,b,e,f)}},html:function(){var a=/^\s*<[\w:]+\s+([^>]*)?>/,b=/^(\s*<[\w:]+(?:\s+[^>]*)?)((?:.|\r|\n)+)$/,f=/\/$/;return function(d,g,e){if(!(3>arguments.length)){var h=[],k=g.html;"\x3c"!=k.charAt(0)&&(k="\x3cspan\x3e"+k+"\x3c/span\x3e");var l=g.focus;if(l){var t=this.focus;this.focus=function(){("function"==
typeof l?l:t).call(this);this.fire("focus")};g.isFocusable&&(this.isFocusable=this.isFocusable);this.keyboardFocusable=!0}CKEDITOR.ui.dialog.uiElement.call(this,d,g,h,"span",null,null,"");h=h.join("").match(a);k=k.match(b)||["","",""];f.test(k[1])&&(k[1]=k[1].slice(0,-1),k[2]="/"+k[2]);e.push([k[1]," ",h[1]||"",k[2]].join(""))}}}(),fieldset:function(a,b,f,d,g){var e=g.label;this._={children:b};CKEDITOR.ui.dialog.uiElement.call(this,a,g,d,"fieldset",null,null,function(){var a=[];e&&a.push("\x3clegend"+
(g.labelStyle?' style\x3d"'+g.labelStyle+'"':"")+"\x3e"+e+"\x3c/legend\x3e");for(var b=0;b<f.length;b++)a.push(f[b]);return a.join("")})}},!0);CKEDITOR.ui.dialog.html.prototype=new CKEDITOR.ui.dialog.uiElement;CKEDITOR.ui.dialog.labeledElement.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,{setLabel:function(a){var b=CKEDITOR.document.getById(this._.labelId);1>b.getChildCount()?(new CKEDITOR.dom.text(a,CKEDITOR.document)).appendTo(b):b.getChild(0).$.nodeValue=a;return this},getLabel:function(){var a=
CKEDITOR.document.getById(this._.labelId);return!a||1>a.getChildCount()?"":a.getChild(0).getText()},eventProcessors:g},!0);CKEDITOR.ui.dialog.button.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,{click:function(){return this._.disabled?!1:this.fire("click",{dialog:this._.dialog})},enable:function(){this._.disabled=!1;var a=this.getElement();a&&a.removeClass("cke_disabled")},disable:function(){this._.disabled=!0;this.getElement().addClass("cke_disabled")},isVisible:function(){return this.getElement().getFirst().isVisible()},
isEnabled:function(){return!this._.disabled},eventProcessors:CKEDITOR.tools.extend({},CKEDITOR.ui.dialog.uiElement.prototype.eventProcessors,{onClick:function(a,b){this.on("click",function(){b.apply(this,arguments)})}},!0),accessKeyUp:function(){this.click()},accessKeyDown:function(){this.focus()},keyboardFocusable:!0},!0);CKEDITOR.ui.dialog.textInput.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.labeledElement,{getInputElement:function(){return CKEDITOR.document.getById(this._.inputId)},
focus:function(){var a=this.selectParentTab();setTimeout(function(){var b=a.getInputElement();b&&b.$.focus()},0)},select:function(){var a=this.selectParentTab();setTimeout(function(){var b=a.getInputElement();b&&(b.$.focus(),b.$.select())},0)},accessKeyUp:function(){this.select()},setValue:function(a){if(this.bidi){var b=a&&a.charAt(0);(b=""==b?"ltr":""==b?"rtl":null)&&(a=a.slice(1));this.setDirectionMarker(b)}a||(a="");return CKEDITOR.ui.dialog.uiElement.prototype.setValue.apply(this,arguments)},
getValue:function(){var a=CKEDITOR.ui.dialog.uiElement.prototype.getValue.call(this);if(this.bidi&&a){var b=this.getDirectionMarker();b&&(a=("ltr"==b?"":"")+a)}return a},setDirectionMarker:function(a){var b=this.getInputElement();a?b.setAttributes({dir:a,"data-cke-dir-marker":a}):this.getDirectionMarker()&&b.removeAttributes(["dir","data-cke-dir-marker"])},getDirectionMarker:function(){return this.getInputElement().data("cke-dir-marker")},keyboardFocusable:!0},d,!0);CKEDITOR.ui.dialog.textarea.prototype=
new CKEDITOR.ui.dialog.textInput;CKEDITOR.ui.dialog.select.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.labeledElement,{getInputElement:function(){return this._.select.getElement()},add:function(a,b,f){var d=new CKEDITOR.dom.element("option",this.getDialog().getParentEditor().document),g=this.getInputElement().$;d.$.text=a;d.$.value=void 0===b||null===b?a:b;void 0===f||null===f?CKEDITOR.env.ie?g.add(d.$):g.add(d.$,null):g.add(d.$,f);return this},remove:function(a){this.getInputElement().$.remove(a);
return this},clear:function(){for(var a=this.getInputElement().$;0<a.length;)a.remove(0);return this},keyboardFocusable:!0},d,!0);CKEDITOR.ui.dialog.checkbox.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,{getInputElement:function(){return this._.checkbox.getElement()},setValue:function(a,b){this.getInputElement().$.checked=a;!b&&this.fire("change",{value:a})},getValue:function(){return this.getInputElement().$.checked},accessKeyUp:function(){this.setValue(!this.getValue())},eventProcessors:{onChange:function(a,
b){if(!CKEDITOR.env.ie||8<CKEDITOR.env.version)return g.onChange.apply(this,arguments);a.on("load",function(){var a=this._.checkbox.getElement();a.on("propertychange",function(b){b=b.data.$;"checked"==b.propertyName&&this.fire("change",{value:a.$.checked})},this)},this);this.on("change",b);return null}},keyboardFocusable:!0},d,!0);CKEDITOR.ui.dialog.radio.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,{setValue:function(a,b){for(var f=this._.children,d,g=0;g<f.length&&(d=f[g]);g++)d.getElement().$.checked=
d.getValue()==a;!b&&this.fire("change",{value:a})},getValue:function(){for(var a=this._.children,b=0;b<a.length;b++)if(a[b].getElement().$.checked)return a[b].getValue();return null},accessKeyUp:function(){var a=this._.children,b;for(b=0;b<a.length;b++)if(a[b].getElement().$.checked){a[b].getElement().focus();return}a[0].getElement().focus()},eventProcessors:{onChange:function(a,b){if(!CKEDITOR.env.ie||8<CKEDITOR.env.version)return g.onChange.apply(this,arguments);a.on("load",function(){for(var a=
this._.children,b=this,c=0;c<a.length;c++)a[c].getElement().on("propertychange",function(a){a=a.data.$;"checked"==a.propertyName&&this.$.checked&&b.fire("change",{value:this.getAttribute("value")})})},this);this.on("change",b);return null}}},d,!0);CKEDITOR.ui.dialog.file.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.labeledElement,d,{getInputElement:function(){var a=CKEDITOR.document.getById(this._.frameId).getFrameDocument();return 0<a.$.forms.length?new CKEDITOR.dom.element(a.$.forms[0].elements[0]):
this.getElement()},submit:function(){this.getInputElement().getParent().$.submit();return this},getAction:function(){return this.getInputElement().getParent().$.action},registerEvents:function(a){var b=/^on([A-Z]\w+)/,f,d=function(a,b,c,f){a.on("formLoaded",function(){a.getInputElement().on(c,f,a)})},g;for(g in a)if(f=g.match(b))this.eventProcessors[g]?this.eventProcessors[g].call(this,this._.dialog,a[g]):d(this,this._.dialog,f[1].toLowerCase(),a[g]);return this},reset:function(){function a(){f.$.open();
var c="";d.size&&(c=d.size-(CKEDITOR.env.ie?7:0));var w=b.frameId+"_input";f.$.write(['\x3chtml dir\x3d"'+k+'" lang\x3d"'+l+'"\x3e\x3chead\x3e\x3ctitle\x3e\x3c/title\x3e\x3c/head\x3e\x3cbody style\x3d"margin: 0; overflow: hidden; background: transparent;"\x3e','\x3cform enctype\x3d"multipart/form-data" method\x3d"POST" dir\x3d"'+k+'" lang\x3d"'+l+'" action\x3d"',CKEDITOR.tools.htmlEncode(d.action),'"\x3e\x3clabel id\x3d"',b.labelId,'" for\x3d"',w,'" style\x3d"display:none"\x3e',CKEDITOR.tools.htmlEncode(d.label),
'\x3c/label\x3e\x3cinput style\x3d"width:100%" id\x3d"',w,'" aria-labelledby\x3d"',b.labelId,'" type\x3d"file" name\x3d"',CKEDITOR.tools.htmlEncode(d.id||"cke_upload"),'" size\x3d"',CKEDITOR.tools.htmlEncode(0<c?c:""),'" /\x3e\x3c/form\x3e\x3c/body\x3e\x3c/html\x3e\x3cscript\x3e',CKEDITOR.env.ie?"("+CKEDITOR.tools.fixDomain+")();":"","window.parent.CKEDITOR.tools.callFunction("+e+");","window.onbeforeunload \x3d function() {window.parent.CKEDITOR.tools.callFunction("+h+")}","\x3c/script\x3e"].join(""));
f.$.close();for(c=0;c<g.length;c++)g[c].enable()}var b=this._,f=CKEDITOR.document.getById(b.frameId).getFrameDocument(),d=b.definition,g=b.buttons,e=this.formLoadedNumber,h=this.formUnloadNumber,k=b.dialog._.editor.lang.dir,l=b.dialog._.editor.langCode;e||(e=this.formLoadedNumber=CKEDITOR.tools.addFunction(function(){this.fire("formLoaded")},this),h=this.formUnloadNumber=CKEDITOR.tools.addFunction(function(){this.getInputElement().clearCustomData()},this),this.getDialog()._.editor.on("destroy",function(){CKEDITOR.tools.removeFunction(e);
CKEDITOR.tools.removeFunction(h)}));CKEDITOR.env.gecko?setTimeout(a,500):a()},getValue:function(){return this.getInputElement().$.value||""},setInitValue:function(){this._.initValue=""},eventProcessors:{onChange:function(a,b){this._.domOnChangeRegistered||(this.on("formLoaded",function(){this.getInputElement().on("change",function(){this.fire("change",{value:this.getValue()})},this)},this),this._.domOnChangeRegistered=!0);this.on("change",b)}},keyboardFocusable:!0},!0);CKEDITOR.ui.dialog.fileButton.prototype=
new CKEDITOR.ui.dialog.button;CKEDITOR.ui.dialog.fieldset.prototype=CKEDITOR.tools.clone(CKEDITOR.ui.dialog.hbox.prototype);CKEDITOR.dialog.addUIElement("text",e);CKEDITOR.dialog.addUIElement("password",e);CKEDITOR.dialog.addUIElement("textarea",b);CKEDITOR.dialog.addUIElement("checkbox",b);CKEDITOR.dialog.addUIElement("radio",b);CKEDITOR.dialog.addUIElement("button",b);CKEDITOR.dialog.addUIElement("select",b);CKEDITOR.dialog.addUIElement("file",b);CKEDITOR.dialog.addUIElement("fileButton",b);CKEDITOR.dialog.addUIElement("html",
b);CKEDITOR.dialog.addUIElement("fieldset",{build:function(a,b,d){for(var g=b.children,e,h=[],k=[],l=0;l<g.length&&(e=g[l]);l++){var r=[];h.push(r);k.push(CKEDITOR.dialog._.uiElementBuilders[e.type].build(a,e,r))}return new CKEDITOR.ui.dialog[b.type](a,k,h,d,b)}})}}),CKEDITOR.DIALOG_RESIZE_NONE=0,CKEDITOR.DIALOG_RESIZE_WIDTH=1,CKEDITOR.DIALOG_RESIZE_HEIGHT=2,CKEDITOR.DIALOG_RESIZE_BOTH=3,CKEDITOR.DIALOG_STATE_IDLE=1,CKEDITOR.DIALOG_STATE_BUSY=2,function(){function a(){for(var a=this._.tabIdList.length,
b=CKEDITOR.tools.indexOf(this._.tabIdList,this._.currentTabId)+a,c=b-1;c>b-a;c--)if(this._.tabs[this._.tabIdList[c%a]][0].$.offsetHeight)return this._.tabIdList[c%a];return null}function e(){for(var a=this._.tabIdList.length,b=CKEDITOR.tools.indexOf(this._.tabIdList,this._.currentTabId),c=b+1;c<b+a;c++)if(this._.tabs[this._.tabIdList[c%a]][0].$.offsetHeight)return this._.tabIdList[c%a];return null}function b(a,b){for(var c=a.$.getElementsByTagName("input"),d=0,f=c.length;d<f;d++){var g=new CKEDITOR.dom.element(c[d]);
"text"==g.getAttribute("type").toLowerCase()&&(b?(g.setAttribute("value",g.getCustomData("fake_value")||""),g.removeCustomData("fake_value")):(g.setCustomData("fake_value",g.getAttribute("value")),g.setAttribute("value","")))}}function d(a,b){var c=this.getInputElement();c&&(a?c.removeAttribute("aria-invalid"):c.setAttribute("aria-invalid",!0));a||(this.select?this.select():this.focus());b&&alert(b);this.fire("validated",{valid:a,msg:b})}function g(){var a=this.getInputElement();a&&a.removeAttribute("aria-invalid")}
function l(a){var b=CKEDITOR.dom.element.createFromHtml(CKEDITOR.addTemplate("dialog",y).output({id:CKEDITOR.tools.getNextNumber(),editorId:a.id,langDir:a.lang.dir,langCode:a.langCode,editorDialogClass:"cke_editor_"+a.name.replace(/\./g,"\\.")+"_dialog",closeTitle:a.lang.common.close,hidpi:CKEDITOR.env.hidpi?"cke_hidpi":""})),c=b.getChild([0,0,0,0,0]),d=c.getChild(0),f=c.getChild(1);a.plugins.clipboard&&CKEDITOR.plugins.clipboard.preventDefaultDropOnElement(c);!CKEDITOR.env.ie||CKEDITOR.env.quirks||
CKEDITOR.env.edge||(a="javascript:void(function(){"+encodeURIComponent("document.open();("+CKEDITOR.tools.fixDomain+")();document.close();")+"}())",CKEDITOR.dom.element.createFromHtml('\x3ciframe frameBorder\x3d"0" class\x3d"cke_iframe_shim" src\x3d"'+a+'" tabIndex\x3d"-1"\x3e\x3c/iframe\x3e').appendTo(c.getParent()));d.unselectable();f.unselectable();return{element:b,parts:{dialog:b.getChild(0),title:d,close:f,tabs:c.getChild(2),contents:c.getChild([3,0,0,0]),footer:c.getChild([3,0,1,0])}}}function k(a,
b,c){this.element=b;this.focusIndex=c;this.tabIndex=0;this.isFocusable=function(){return!b.getAttribute("disabled")&&b.isVisible()};this.focus=function(){a._.currentFocusIndex=this.focusIndex;this.element.focus()};b.on("keydown",function(a){a.data.getKeystroke()in{32:1,13:1}&&this.fire("click")});b.on("focus",function(){this.fire("mouseover")});b.on("blur",function(){this.fire("mouseout")})}function h(a){function b(){a.layout()}var c=CKEDITOR.document.getWindow();c.on("resize",b);a.on("hide",function(){c.removeListener("resize",
b)})}function c(a,b){this._={dialog:a};CKEDITOR.tools.extend(this,b)}function m(a){function b(c){var k=a.getSize(),m=CKEDITOR.document.getWindow().getViewPaneSize(),l=c.data.$.screenX,n=c.data.$.screenY,r=l-d.x,w=n-d.y;d={x:l,y:n};f.x+=r;f.y+=w;a.move(f.x+h[3]<e?-h[3]:f.x-h[1]>m.width-k.width-e?m.width-k.width+("rtl"==g.lang.dir?0:h[1]):f.x,f.y+h[0]<e?-h[0]:f.y-h[2]>m.height-k.height-e?m.height-k.height+h[2]:f.y,1);c.data.preventDefault()}function c(){CKEDITOR.document.removeListener("mousemove",
b);CKEDITOR.document.removeListener("mouseup",c);if(CKEDITOR.env.ie6Compat){var a=z.getChild(0).getFrameDocument();a.removeListener("mousemove",b);a.removeListener("mouseup",c)}}var d=null,f=null,g=a.getParentEditor(),e=g.config.dialog_magnetDistance,h=CKEDITOR.skin.margins||[0,0,0,0];"undefined"==typeof e&&(e=20);a.parts.title.on("mousedown",function(g){d={x:g.data.$.screenX,y:g.data.$.screenY};CKEDITOR.document.on("mousemove",b);CKEDITOR.document.on("mouseup",c);f=a.getPosition();if(CKEDITOR.env.ie6Compat){var e=
z.getChild(0).getFrameDocument();e.on("mousemove",b);e.on("mouseup",c)}g.data.preventDefault()},a)}function f(a){function b(c){var n="rtl"==g.lang.dir,r=l.width,w=l.height,t=r+(c.data.$.screenX-m.x)*(n?-1:1)*(a._.moved?1:2),u=w+(c.data.$.screenY-m.y)*(a._.moved?1:2),p=a._.element.getFirst(),p=n&&p.getComputedStyle("right"),A=a.getPosition();A.y+u>k.height&&(u=k.height-A.y);(n?p:A.x)+t>k.width&&(t=k.width-(n?p:A.x));if(f==CKEDITOR.DIALOG_RESIZE_WIDTH||f==CKEDITOR.DIALOG_RESIZE_BOTH)r=Math.max(d.minWidth||
0,t-e);if(f==CKEDITOR.DIALOG_RESIZE_HEIGHT||f==CKEDITOR.DIALOG_RESIZE_BOTH)w=Math.max(d.minHeight||0,u-h);a.resize(r,w);a._.moved||a.layout();c.data.preventDefault()}function c(){CKEDITOR.document.removeListener("mouseup",c);CKEDITOR.document.removeListener("mousemove",b);n&&(n.remove(),n=null);if(CKEDITOR.env.ie6Compat){var a=z.getChild(0).getFrameDocument();a.removeListener("mouseup",c);a.removeListener("mousemove",b)}}var d=a.definition,f=d.resizable;if(f!=CKEDITOR.DIALOG_RESIZE_NONE){var g=a.getParentEditor(),
e,h,k,m,l,n,r=CKEDITOR.tools.addFunction(function(f){l=a.getSize();var d=a.parts.contents;d.$.getElementsByTagName("iframe").length&&(n=CKEDITOR.dom.element.createFromHtml('\x3cdiv class\x3d"cke_dialog_resize_cover" style\x3d"height: 100%; position: absolute; width: 100%;"\x3e\x3c/div\x3e'),d.append(n));h=l.height-a.parts.contents.getSize("height",!(CKEDITOR.env.gecko||CKEDITOR.env.ie&&CKEDITOR.env.quirks));e=l.width-a.parts.contents.getSize("width",1);m={x:f.screenX,y:f.screenY};k=CKEDITOR.document.getWindow().getViewPaneSize();
CKEDITOR.document.on("mousemove",b);CKEDITOR.document.on("mouseup",c);CKEDITOR.env.ie6Compat&&(d=z.getChild(0).getFrameDocument(),d.on("mousemove",b),d.on("mouseup",c));f.preventDefault&&f.preventDefault()});a.on("load",function(){var b="";f==CKEDITOR.DIALOG_RESIZE_WIDTH?b=" cke_resizer_horizontal":f==CKEDITOR.DIALOG_RESIZE_HEIGHT&&(b=" cke_resizer_vertical");b=CKEDITOR.dom.element.createFromHtml('\x3cdiv class\x3d"cke_resizer'+b+" cke_resizer_"+g.lang.dir+'" title\x3d"'+CKEDITOR.tools.htmlEncode(g.lang.common.resize)+
'" onmousedown\x3d"CKEDITOR.tools.callFunction('+r+', event )"\x3e'+("ltr"==g.lang.dir?"◢":"◣")+"\x3c/div\x3e");a.parts.footer.append(b,1)});g.on("destroy",function(){CKEDITOR.tools.removeFunction(r)})}}function n(a){a.data.preventDefault(1)}function p(a){var b=CKEDITOR.document.getWindow(),c=a.config,f=CKEDITOR.skinName||a.config.skin,d=c.dialog_backgroundCoverColor||("moono-lisa"==f?"black":"white"),f=c.dialog_backgroundCoverOpacity,g=c.baseFloatZIndex,c=CKEDITOR.tools.genKey(d,f,g),e=C[c];e?e.show():
(g=['\x3cdiv tabIndex\x3d"-1" style\x3d"position: ',CKEDITOR.env.ie6Compat?"absolute":"fixed","; z-index: ",g,"; top: 0px; left: 0px; ",CKEDITOR.env.ie6Compat?"":"background-color: "+d,'" class\x3d"cke_dialog_background_cover"\x3e'],CKEDITOR.env.ie6Compat&&(d="\x3chtml\x3e\x3cbody style\x3d\\'background-color:"+d+";\\'\x3e\x3c/body\x3e\x3c/html\x3e",g.push('\x3ciframe hidefocus\x3d"true" frameborder\x3d"0" id\x3d"cke_dialog_background_iframe" src\x3d"javascript:'),g.push("void((function(){"+encodeURIComponent("document.open();("+
CKEDITOR.tools.fixDomain+")();document.write( '"+d+"' );document.close();")+"})())"),g.push('" style\x3d"position:absolute;left:0;top:0;width:100%;height: 100%;filter: progid:DXImageTransform.Microsoft.Alpha(opacity\x3d0)"\x3e\x3c/iframe\x3e')),g.push("\x3c/div\x3e"),e=CKEDITOR.dom.element.createFromHtml(g.join("")),e.setOpacity(void 0!==f?f:.5),e.on("keydown",n),e.on("keypress",n),e.on("keyup",n),e.appendTo(CKEDITOR.document.getBody()),C[c]=e);a.focusManager.add(e);z=e;a=function(){var a=b.getViewPaneSize();
e.setStyles({width:a.width+"px",height:a.height+"px"})};var h=function(){var a=b.getScrollPosition(),c=CKEDITOR.dialog._.currentTop;e.setStyles({left:a.x+"px",top:a.y+"px"});if(c){do a=c.getPosition(),c.move(a.x,a.y);while(c=c._.parentDialog)}};u=a;b.on("resize",a);a();CKEDITOR.env.mac&&CKEDITOR.env.webkit||e.focus();if(CKEDITOR.env.ie6Compat){var k=function(){h();arguments.callee.prevScrollHandler.apply(this,arguments)};b.$.setTimeout(function(){k.prevScrollHandler=window.onscroll||function(){};
window.onscroll=k},0);h()}}function q(a){z&&(a.focusManager.remove(z),a=CKEDITOR.document.getWindow(),z.hide(),a.removeListener("resize",u),CKEDITOR.env.ie6Compat&&a.$.setTimeout(function(){window.onscroll=window.onscroll&&window.onscroll.prevScrollHandler||null},0),u=null)}var v=CKEDITOR.tools.cssLength,y='\x3cdiv class\x3d"cke_reset_all {editorId} {editorDialogClass} {hidpi}" dir\x3d"{langDir}" lang\x3d"{langCode}" role\x3d"dialog" aria-labelledby\x3d"cke_dialog_title_{id}"\x3e\x3ctable class\x3d"cke_dialog '+
CKEDITOR.env.cssClass+' cke_{langDir}" style\x3d"position:absolute" role\x3d"presentation"\x3e\x3ctr\x3e\x3ctd role\x3d"presentation"\x3e\x3cdiv class\x3d"cke_dialog_body" role\x3d"presentation"\x3e\x3cdiv id\x3d"cke_dialog_title_{id}" class\x3d"cke_dialog_title" role\x3d"presentation"\x3e\x3c/div\x3e\x3ca id\x3d"cke_dialog_close_button_{id}" class\x3d"cke_dialog_close_button" href\x3d"javascript:void(0)" title\x3d"{closeTitle}" role\x3d"button"\x3e\x3cspan class\x3d"cke_label"\x3eX\x3c/span\x3e\x3c/a\x3e\x3cdiv id\x3d"cke_dialog_tabs_{id}" class\x3d"cke_dialog_tabs" role\x3d"tablist"\x3e\x3c/div\x3e\x3ctable class\x3d"cke_dialog_contents" role\x3d"presentation"\x3e\x3ctr\x3e\x3ctd id\x3d"cke_dialog_contents_{id}" class\x3d"cke_dialog_contents_body" role\x3d"presentation"\x3e\x3c/td\x3e\x3c/tr\x3e\x3ctr\x3e\x3ctd id\x3d"cke_dialog_footer_{id}" class\x3d"cke_dialog_footer" role\x3d"presentation"\x3e\x3c/td\x3e\x3c/tr\x3e\x3c/table\x3e\x3c/div\x3e\x3c/td\x3e\x3c/tr\x3e\x3c/table\x3e\x3c/div\x3e';
CKEDITOR.dialog=function(b,c){function h(){var a=B._.focusList;a.sort(function(a,b){return a.tabIndex!=b.tabIndex?b.tabIndex-a.tabIndex:a.focusIndex-b.focusIndex});for(var b=a.length,c=0;c<b;c++)a[c].focusIndex=c}function k(a){var b=B._.focusList;a=a||0;if(!(1>b.length)){var c=B._.currentFocusIndex;B._.tabBarMode&&0>a&&(c=0);try{b[c].getInputElement().$.blur()}catch(f){}var d=c,g=1<B._.pageCount;do{d+=a;if(g&&!B._.tabBarMode&&(d==b.length||-1==d)){B._.tabBarMode=!0;B._.tabs[B._.currentTabId][0].focus();
B._.currentFocusIndex=-1;return}d=(d+b.length)%b.length;if(d==c)break}while(a&&!b[d].isFocusable());b[d].focus();"text"==b[d].type&&b[d].select()}}function n(c){if(B==CKEDITOR.dialog._.currentTop){var d=c.data.getKeystroke(),f="rtl"==b.lang.dir,g=[37,38,39,40];z=q=0;if(9==d||d==CKEDITOR.SHIFT+9)k(d==CKEDITOR.SHIFT+9?-1:1),z=1;else if(d==CKEDITOR.ALT+121&&!B._.tabBarMode&&1<B.getPageCount())B._.tabBarMode=!0,B._.tabs[B._.currentTabId][0].focus(),B._.currentFocusIndex=-1,z=1;else if(-1!=CKEDITOR.tools.indexOf(g,
d)&&B._.tabBarMode)d=-1!=CKEDITOR.tools.indexOf([f?39:37,38],d)?a.call(B):e.call(B),B.selectPage(d),B._.tabs[d][0].focus(),z=1;else if(13!=d&&32!=d||!B._.tabBarMode)if(13==d)d=c.data.getTarget(),d.is("a","button","select","textarea")||d.is("input")&&"button"==d.$.type||((d=this.getButton("ok"))&&CKEDITOR.tools.setTimeout(d.click,0,d),z=1),q=1;else if(27==d)(d=this.getButton("cancel"))?CKEDITOR.tools.setTimeout(d.click,0,d):!1!==this.fire("cancel",{hide:!0}).hide&&this.hide(),q=1;else return;else this.selectPage(this._.currentTabId),
this._.tabBarMode=!1,this._.currentFocusIndex=-1,k(1),z=1;w(c)}}function w(a){z?a.data.preventDefault(1):q&&a.data.stopPropagation()}var t=CKEDITOR.dialog._.dialogDefinitions[c],u=CKEDITOR.tools.clone(r),p=b.config.dialog_buttonsOrder||"OS",A=b.lang.dir,v={},z,q;("OS"==p&&CKEDITOR.env.mac||"rtl"==p&&"ltr"==A||"ltr"==p&&"rtl"==A)&&u.buttons.reverse();t=CKEDITOR.tools.extend(t(b),u);t=CKEDITOR.tools.clone(t);t=new x(this,t);u=l(b);this._={editor:b,element:u.element,name:c,contentSize:{width:0,height:0},
size:{width:0,height:0},contents:{},buttons:{},accessKeyMap:{},tabs:{},tabIdList:[],currentTabId:null,currentTabIndex:null,pageCount:0,lastTab:null,tabBarMode:!1,focusList:[],currentFocusIndex:0,hasFocus:!1};this.parts=u.parts;CKEDITOR.tools.setTimeout(function(){b.fire("ariaWidget",this.parts.contents)},0,this);u={position:CKEDITOR.env.ie6Compat?"absolute":"fixed",top:0,visibility:"hidden"};u["rtl"==A?"right":"left"]=0;this.parts.dialog.setStyles(u);CKEDITOR.event.call(this);this.definition=t=CKEDITOR.fire("dialogDefinition",
{name:c,definition:t},b).definition;if(!("removeDialogTabs"in b._)&&b.config.removeDialogTabs){u=b.config.removeDialogTabs.split(";");for(A=0;A<u.length;A++)if(p=u[A].split(":"),2==p.length){var y=p[0];v[y]||(v[y]=[]);v[y].push(p[1])}b._.removeDialogTabs=v}if(b._.removeDialogTabs&&(v=b._.removeDialogTabs[c]))for(A=0;A<v.length;A++)t.removeContents(v[A]);if(t.onLoad)this.on("load",t.onLoad);if(t.onShow)this.on("show",t.onShow);if(t.onHide)this.on("hide",t.onHide);if(t.onOk)this.on("ok",function(a){b.fire("saveSnapshot");
setTimeout(function(){b.fire("saveSnapshot")},0);!1===t.onOk.call(this,a)&&(a.data.hide=!1)});this.state=CKEDITOR.DIALOG_STATE_IDLE;if(t.onCancel)this.on("cancel",function(a){!1===t.onCancel.call(this,a)&&(a.data.hide=!1)});var B=this,I=function(a){var b=B._.contents,c=!1,d;for(d in b)for(var f in b[d])if(c=a.call(this,b[d][f]))return};this.on("ok",function(a){I(function(b){if(b.validate){var c=b.validate(this),f="string"==typeof c||!1===c;f&&(a.data.hide=!1,a.stop());d.call(b,!f,"string"==typeof c?
c:void 0);return f}})},this,null,0);this.on("cancel",function(a){I(function(c){if(c.isChanged())return b.config.dialog_noConfirmCancel||confirm(b.lang.common.confirmCancel)||(a.data.hide=!1),!0})},this,null,0);this.parts.close.on("click",function(a){!1!==this.fire("cancel",{hide:!0}).hide&&this.hide();a.data.preventDefault()},this);this.changeFocus=k;var C=this._.element;b.focusManager.add(C,1);this.on("show",function(){C.on("keydown",n,this);if(CKEDITOR.env.gecko)C.on("keypress",w,this)});this.on("hide",
function(){C.removeListener("keydown",n);CKEDITOR.env.gecko&&C.removeListener("keypress",w);I(function(a){g.apply(a)})});this.on("iframeAdded",function(a){(new CKEDITOR.dom.document(a.data.iframe.$.contentWindow.document)).on("keydown",n,this,null,0)});this.on("show",function(){h();var a=1<B._.pageCount;b.config.dialog_startupFocusTab&&a?(B._.tabBarMode=!0,B._.tabs[B._.currentTabId][0].focus(),B._.currentFocusIndex=-1):this._.hasFocus||(this._.currentFocusIndex=a?-1:this._.focusList.length-1,t.onFocus?
(a=t.onFocus.call(this))&&a.focus():k(1))},this,null,4294967295);if(CKEDITOR.env.ie6Compat)this.on("load",function(){var a=this.getElement(),b=a.getFirst();b.remove();b.appendTo(a)},this);m(this);f(this);(new CKEDITOR.dom.text(t.title,CKEDITOR.document)).appendTo(this.parts.title);for(A=0;A<t.contents.length;A++)(v=t.contents[A])&&this.addPage(v);this.parts.tabs.on("click",function(a){var b=a.data.getTarget();b.hasClass("cke_dialog_tab")&&(b=b.$.id,this.selectPage(b.substring(4,b.lastIndexOf("_"))),
this._.tabBarMode&&(this._.tabBarMode=!1,this._.currentFocusIndex=-1,k(1)),a.data.preventDefault())},this);A=[];v=CKEDITOR.dialog._.uiElementBuilders.hbox.build(this,{type:"hbox",className:"cke_dialog_footer_buttons",widths:[],children:t.buttons},A).getChild();this.parts.footer.setHtml(A.join(""));for(A=0;A<v.length;A++)this._.buttons[v[A].id]=v[A]};CKEDITOR.dialog.prototype={destroy:function(){this.hide();this._.element.remove()},resize:function(){return function(a,b){this._.contentSize&&this._.contentSize.width==
a&&this._.contentSize.height==b||(CKEDITOR.dialog.fire("resize",{dialog:this,width:a,height:b},this._.editor),this.fire("resize",{width:a,height:b},this._.editor),this.parts.contents.setStyles({width:a+"px",height:b+"px"}),"rtl"==this._.editor.lang.dir&&this._.position&&(this._.position.x=CKEDITOR.document.getWindow().getViewPaneSize().width-this._.contentSize.width-parseInt(this._.element.getFirst().getStyle("right"),10)),this._.contentSize={width:a,height:b})}}(),getSize:function(){var a=this._.element.getFirst();
return{width:a.$.offsetWidth||0,height:a.$.offsetHeight||0}},move:function(a,b,c){var d=this._.element.getFirst(),f="rtl"==this._.editor.lang.dir,g="fixed"==d.getComputedStyle("position");CKEDITOR.env.ie&&d.setStyle("zoom","100%");g&&this._.position&&this._.position.x==a&&this._.position.y==b||(this._.position={x:a,y:b},g||(g=CKEDITOR.document.getWindow().getScrollPosition(),a+=g.x,b+=g.y),f&&(g=this.getSize(),a=CKEDITOR.document.getWindow().getViewPaneSize().width-g.width-a),b={top:(0<b?b:0)+"px"},
b[f?"right":"left"]=(0<a?a:0)+"px",d.setStyles(b),c&&(this._.moved=1))},getPosition:function(){return CKEDITOR.tools.extend({},this._.position)},show:function(){var a=this._.element,b=this.definition;a.getParent()&&a.getParent().equals(CKEDITOR.document.getBody())?a.setStyle("display","block"):a.appendTo(CKEDITOR.document.getBody());this.resize(this._.contentSize&&this._.contentSize.width||b.width||b.minWidth,this._.contentSize&&this._.contentSize.height||b.height||b.minHeight);this.reset();null===
this._.currentTabId&&this.selectPage(this.definition.contents[0].id);null===CKEDITOR.dialog._.currentZIndex&&(CKEDITOR.dialog._.currentZIndex=this._.editor.config.baseFloatZIndex);this._.element.getFirst().setStyle("z-index",CKEDITOR.dialog._.currentZIndex+=10);null===CKEDITOR.dialog._.currentTop?(CKEDITOR.dialog._.currentTop=this,this._.parentDialog=null,p(this._.editor)):(this._.parentDialog=CKEDITOR.dialog._.currentTop,this._.parentDialog.getElement().getFirst().$.style.zIndex-=Math.floor(this._.editor.config.baseFloatZIndex/
2),CKEDITOR.dialog._.currentTop=this);a.on("keydown",G);a.on("keyup",F);this._.hasFocus=!1;for(var c in b.contents)if(b.contents[c]){var a=b.contents[c],d=this._.tabs[a.id],f=a.requiredContent,g=0;if(d){for(var e in this._.contents[a.id]){var k=this._.contents[a.id][e];"hbox"!=k.type&&"vbox"!=k.type&&k.getInputElement()&&(k.requiredContent&&!this._.editor.activeFilter.check(k.requiredContent)?k.disable():(k.enable(),g++))}!g||f&&!this._.editor.activeFilter.check(f)?d[0].addClass("cke_dialog_tab_disabled"):
d[0].removeClass("cke_dialog_tab_disabled")}}CKEDITOR.tools.setTimeout(function(){this.layout();h(this);this.parts.dialog.setStyle("visibility","");this.fireOnce("load",{});CKEDITOR.ui.fire("ready",this);this.fire("show",{});this._.editor.fire("dialogShow",this);this._.parentDialog||this._.editor.focusManager.lock();this.foreach(function(a){a.setInitValue&&a.setInitValue()})},100,this)},layout:function(){var a=this.parts.dialog,b=this.getSize(),c=CKEDITOR.document.getWindow().getViewPaneSize(),d=
(c.width-b.width)/2,f=(c.height-b.height)/2;CKEDITOR.env.ie6Compat||(b.height+(0<f?f:0)>c.height||b.width+(0<d?d:0)>c.width?a.setStyle("position","absolute"):a.setStyle("position","fixed"));this.move(this._.moved?this._.position.x:d,this._.moved?this._.position.y:f)},foreach:function(a){for(var b in this._.contents)for(var c in this._.contents[b])a.call(this,this._.contents[b][c]);return this},reset:function(){var a=function(a){a.reset&&a.reset(1)};return function(){this.foreach(a);return this}}(),
setupContent:function(){var a=arguments;this.foreach(function(b){b.setup&&b.setup.apply(b,a)})},commitContent:function(){var a=arguments;this.foreach(function(b){CKEDITOR.env.ie&&this._.currentFocusIndex==b.focusIndex&&b.getInputElement().$.blur();b.commit&&b.commit.apply(b,a)})},hide:function(){if(this.parts.dialog.isVisible()){this.fire("hide",{});this._.editor.fire("dialogHide",this);this.selectPage(this._.tabIdList[0]);var a=this._.element;a.setStyle("display","none");this.parts.dialog.setStyle("visibility",
"hidden");for(J(this);CKEDITOR.dialog._.currentTop!=this;)CKEDITOR.dialog._.currentTop.hide();if(this._.parentDialog){var b=this._.parentDialog.getElement().getFirst();b.setStyle("z-index",parseInt(b.$.style.zIndex,10)+Math.floor(this._.editor.config.baseFloatZIndex/2))}else q(this._.editor);if(CKEDITOR.dialog._.currentTop=this._.parentDialog)CKEDITOR.dialog._.currentZIndex-=10;else{CKEDITOR.dialog._.currentZIndex=null;a.removeListener("keydown",G);a.removeListener("keyup",F);var c=this._.editor;
c.focus();setTimeout(function(){c.focusManager.unlock();CKEDITOR.env.iOS&&c.window.focus()},0)}delete this._.parentDialog;this.foreach(function(a){a.resetInitValue&&a.resetInitValue()});this.setState(CKEDITOR.DIALOG_STATE_IDLE)}},addPage:function(a){if(!a.requiredContent||this._.editor.filter.check(a.requiredContent)){for(var b=[],c=a.label?' title\x3d"'+CKEDITOR.tools.htmlEncode(a.label)+'"':"",d=CKEDITOR.dialog._.uiElementBuilders.vbox.build(this,{type:"vbox",className:"cke_dialog_page_contents",
children:a.elements,expand:!!a.expand,padding:a.padding,style:a.style||"width: 100%;"},b),f=this._.contents[a.id]={},g=d.getChild(),e=0;d=g.shift();)d.notAllowed||"hbox"==d.type||"vbox"==d.type||e++,f[d.id]=d,"function"==typeof d.getChild&&g.push.apply(g,d.getChild());e||(a.hidden=!0);b=CKEDITOR.dom.element.createFromHtml(b.join(""));b.setAttribute("role","tabpanel");d=CKEDITOR.env;f="cke_"+a.id+"_"+CKEDITOR.tools.getNextNumber();c=CKEDITOR.dom.element.createFromHtml(['\x3ca class\x3d"cke_dialog_tab"',
0<this._.pageCount?" cke_last":"cke_first",c,a.hidden?' style\x3d"display:none"':"",' id\x3d"',f,'"',d.gecko&&!d.hc?"":' href\x3d"javascript:void(0)"',' tabIndex\x3d"-1" hidefocus\x3d"true" role\x3d"tab"\x3e',a.label,"\x3c/a\x3e"].join(""));b.setAttribute("aria-labelledby",f);this._.tabs[a.id]=[c,b];this._.tabIdList.push(a.id);!a.hidden&&this._.pageCount++;this._.lastTab=c;this.updateStyle();b.setAttribute("name",a.id);b.appendTo(this.parts.contents);c.unselectable();this.parts.tabs.append(c);a.accessKey&&
(E(this,this,"CTRL+"+a.accessKey,M,H),this._.accessKeyMap["CTRL+"+a.accessKey]=a.id)}},selectPage:function(a){if(this._.currentTabId!=a&&!this._.tabs[a][0].hasClass("cke_dialog_tab_disabled")&&!1!==this.fire("selectPage",{page:a,currentPage:this._.currentTabId})){for(var c in this._.tabs){var d=this._.tabs[c][0],f=this._.tabs[c][1];c!=a&&(d.removeClass("cke_dialog_tab_selected"),f.hide());f.setAttribute("aria-hidden",c!=a)}var g=this._.tabs[a];g[0].addClass("cke_dialog_tab_selected");CKEDITOR.env.ie6Compat||
CKEDITOR.env.ie7Compat?(b(g[1]),g[1].show(),setTimeout(function(){b(g[1],1)},0)):g[1].show();this._.currentTabId=a;this._.currentTabIndex=CKEDITOR.tools.indexOf(this._.tabIdList,a)}},updateStyle:function(){this.parts.dialog[(1===this._.pageCount?"add":"remove")+"Class"]("cke_single_page")},hidePage:function(b){var c=this._.tabs[b]&&this._.tabs[b][0];c&&1!=this._.pageCount&&c.isVisible()&&(b==this._.currentTabId&&this.selectPage(a.call(this)),c.hide(),this._.pageCount--,this.updateStyle())},showPage:function(a){if(a=
this._.tabs[a]&&this._.tabs[a][0])a.show(),this._.pageCount++,this.updateStyle()},getElement:function(){return this._.element},getName:function(){return this._.name},getContentElement:function(a,b){var c=this._.contents[a];return c&&c[b]},getValueOf:function(a,b){return this.getContentElement(a,b).getValue()},setValueOf:function(a,b,c){return this.getContentElement(a,b).setValue(c)},getButton:function(a){return this._.buttons[a]},click:function(a){return this._.buttons[a].click()},disableButton:function(a){return this._.buttons[a].disable()},
enableButton:function(a){return this._.buttons[a].enable()},getPageCount:function(){return this._.pageCount},getParentEditor:function(){return this._.editor},getSelectedElement:function(){return this.getParentEditor().getSelection().getSelectedElement()},addFocusable:function(a,b){if("undefined"==typeof b)b=this._.focusList.length,this._.focusList.push(new k(this,a,b));else{this._.focusList.splice(b,0,new k(this,a,b));for(var c=b+1;c<this._.focusList.length;c++)this._.focusList[c].focusIndex++}},
setState:function(a){if(this.state!=a){this.state=a;if(a==CKEDITOR.DIALOG_STATE_BUSY){if(!this.parts.spinner){var b=this.getParentEditor().lang.dir,c={attributes:{"class":"cke_dialog_spinner"},styles:{"float":"rtl"==b?"right":"left"}};c.styles["margin-"+("rtl"==b?"left":"right")]="8px";this.parts.spinner=CKEDITOR.document.createElement("div",c);this.parts.spinner.setHtml("\x26#8987;");this.parts.spinner.appendTo(this.parts.title,1)}this.parts.spinner.show();this.getButton("ok").disable()}else a==
CKEDITOR.DIALOG_STATE_IDLE&&(this.parts.spinner&&this.parts.spinner.hide(),this.getButton("ok").enable());this.fire("state",a)}}};CKEDITOR.tools.extend(CKEDITOR.dialog,{add:function(a,b){this._.dialogDefinitions[a]&&"function"!=typeof b||(this._.dialogDefinitions[a]=b)},exists:function(a){return!!this._.dialogDefinitions[a]},getCurrent:function(){return CKEDITOR.dialog._.currentTop},isTabEnabled:function(a,b,c){a=a.config.removeDialogTabs;return!(a&&a.match(new RegExp("(?:^|;)"+b+":"+c+"(?:$|;)",
"i")))},okButton:function(){var a=function(a,b){b=b||{};return CKEDITOR.tools.extend({id:"ok",type:"button",label:a.lang.common.ok,"class":"cke_dialog_ui_button_ok",onClick:function(a){a=a.data.dialog;!1!==a.fire("ok",{hide:!0}).hide&&a.hide()}},b,!0)};a.type="button";a.override=function(b){return CKEDITOR.tools.extend(function(c){return a(c,b)},{type:"button"},!0)};return a}(),cancelButton:function(){var a=function(a,b){b=b||{};return CKEDITOR.tools.extend({id:"cancel",type:"button",label:a.lang.common.cancel,
"class":"cke_dialog_ui_button_cancel",onClick:function(a){a=a.data.dialog;!1!==a.fire("cancel",{hide:!0}).hide&&a.hide()}},b,!0)};a.type="button";a.override=function(b){return CKEDITOR.tools.extend(function(c){return a(c,b)},{type:"button"},!0)};return a}(),addUIElement:function(a,b){this._.uiElementBuilders[a]=b}});CKEDITOR.dialog._={uiElementBuilders:{},dialogDefinitions:{},currentTop:null,currentZIndex:null};CKEDITOR.event.implementOn(CKEDITOR.dialog);CKEDITOR.event.implementOn(CKEDITOR.dialog.prototype);
var r={resizable:CKEDITOR.DIALOG_RESIZE_BOTH,minWidth:600,minHeight:400,buttons:[CKEDITOR.dialog.okButton,CKEDITOR.dialog.cancelButton]},t=function(a,b,c){for(var d=0,f;f=a[d];d++)if(f.id==b||c&&f[c]&&(f=t(f[c],b,c)))return f;return null},w=function(a,b,c,d,f){if(c){for(var g=0,e;e=a[g];g++){if(e.id==c)return a.splice(g,0,b),b;if(d&&e[d]&&(e=w(e[d],b,c,d,!0)))return e}if(f)return null}a.push(b);return b},A=function(a,b,c){for(var d=0,f;f=a[d];d++){if(f.id==b)return a.splice(d,1);if(c&&f[c]&&(f=A(f[c],
b,c)))return f}return null},x=function(a,b){this.dialog=a;for(var d=b.contents,f=0,g;g=d[f];f++)d[f]=g&&new c(a,g);CKEDITOR.tools.extend(this,b)};x.prototype={getContents:function(a){return t(this.contents,a)},getButton:function(a){return t(this.buttons,a)},addContents:function(a,b){return w(this.contents,a,b)},addButton:function(a,b){return w(this.buttons,a,b)},removeContents:function(a){A(this.contents,a)},removeButton:function(a){A(this.buttons,a)}};c.prototype={get:function(a){return t(this.elements,
a,"children")},add:function(a,b){return w(this.elements,a,b,"children")},remove:function(a){A(this.elements,a,"children")}};var u,C={},z,B={},G=function(a){var b=a.data.$.ctrlKey||a.data.$.metaKey,c=a.data.$.altKey,d=a.data.$.shiftKey,f=String.fromCharCode(a.data.$.keyCode);(b=B[(b?"CTRL+":"")+(c?"ALT+":"")+(d?"SHIFT+":"")+f])&&b.length&&(b=b[b.length-1],b.keydown&&b.keydown.call(b.uiElement,b.dialog,b.key),a.data.preventDefault())},F=function(a){var b=a.data.$.ctrlKey||a.data.$.metaKey,c=a.data.$.altKey,
d=a.data.$.shiftKey,f=String.fromCharCode(a.data.$.keyCode);(b=B[(b?"CTRL+":"")+(c?"ALT+":"")+(d?"SHIFT+":"")+f])&&b.length&&(b=b[b.length-1],b.keyup&&(b.keyup.call(b.uiElement,b.dialog,b.key),a.data.preventDefault()))},E=function(a,b,c,d,f){(B[c]||(B[c]=[])).push({uiElement:a,dialog:b,key:c,keyup:f||a.accessKeyUp,keydown:d||a.accessKeyDown})},J=function(a){for(var b in B){for(var c=B[b],d=c.length-1;0<=d;d--)c[d].dialog!=a&&c[d].uiElement!=a||c.splice(d,1);0===c.length&&delete B[b]}},H=function(a,
b){a._.accessKeyMap[b]&&a.selectPage(a._.accessKeyMap[b])},M=function(){};(function(){CKEDITOR.ui.dialog={uiElement:function(a,b,c,d,f,g,e){if(!(4>arguments.length)){var h=(d.call?d(b):d)||"div",k=["\x3c",h," "],m=(f&&f.call?f(b):f)||{},l=(g&&g.call?g(b):g)||{},n=(e&&e.call?e.call(this,a,b):e)||"",r=this.domId=l.id||CKEDITOR.tools.getNextId()+"_uiElement";b.requiredContent&&!a.getParentEditor().filter.check(b.requiredContent)&&(m.display="none",this.notAllowed=!0);l.id=r;var t={};b.type&&(t["cke_dialog_ui_"+
b.type]=1);b.className&&(t[b.className]=1);b.disabled&&(t.cke_disabled=1);for(var w=l["class"]&&l["class"].split?l["class"].split(" "):[],r=0;r<w.length;r++)w[r]&&(t[w[r]]=1);w=[];for(r in t)w.push(r);l["class"]=w.join(" ");b.title&&(l.title=b.title);t=(b.style||"").split(";");b.align&&(w=b.align,m["margin-left"]="left"==w?0:"auto",m["margin-right"]="right"==w?0:"auto");for(r in m)t.push(r+":"+m[r]);b.hidden&&t.push("display:none");for(r=t.length-1;0<=r;r--)""===t[r]&&t.splice(r,1);0<t.length&&(l.style=
(l.style?l.style+"; ":"")+t.join("; "));for(r in l)k.push(r+'\x3d"'+CKEDITOR.tools.htmlEncode(l[r])+'" ');k.push("\x3e",n,"\x3c/",h,"\x3e");c.push(k.join(""));(this._||(this._={})).dialog=a;"boolean"==typeof b.isChanged&&(this.isChanged=function(){return b.isChanged});"function"==typeof b.isChanged&&(this.isChanged=b.isChanged);"function"==typeof b.setValue&&(this.setValue=CKEDITOR.tools.override(this.setValue,function(a){return function(c){a.call(this,b.setValue.call(this,c))}}));"function"==typeof b.getValue&&
(this.getValue=CKEDITOR.tools.override(this.getValue,function(a){return function(){return b.getValue.call(this,a.call(this))}}));CKEDITOR.event.implementOn(this);this.registerEvents(b);this.accessKeyUp&&this.accessKeyDown&&b.accessKey&&E(this,a,"CTRL+"+b.accessKey);var u=this;a.on("load",function(){var b=u.getInputElement();if(b){var c=u.type in{checkbox:1,ratio:1}&&CKEDITOR.env.ie&&8>CKEDITOR.env.version?"cke_dialog_ui_focused":"";b.on("focus",function(){a._.tabBarMode=!1;a._.hasFocus=!0;u.fire("focus");
c&&this.addClass(c)});b.on("blur",function(){u.fire("blur");c&&this.removeClass(c)})}});CKEDITOR.tools.extend(this,b);this.keyboardFocusable&&(this.tabIndex=b.tabIndex||0,this.focusIndex=a._.focusList.push(this)-1,this.on("focus",function(){a._.currentFocusIndex=u.focusIndex}))}},hbox:function(a,b,c,d,f){if(!(4>arguments.length)){this._||(this._={});var g=this._.children=b,e=f&&f.widths||null,h=f&&f.height||null,k,m={role:"presentation"};f&&f.align&&(m.align=f.align);CKEDITOR.ui.dialog.uiElement.call(this,
a,f||{type:"hbox"},d,"table",{},m,function(){var a=['\x3ctbody\x3e\x3ctr class\x3d"cke_dialog_ui_hbox"\x3e'];for(k=0;k<c.length;k++){var b="cke_dialog_ui_hbox_child",d=[];0===k&&(b="cke_dialog_ui_hbox_first");k==c.length-1&&(b="cke_dialog_ui_hbox_last");a.push('\x3ctd class\x3d"',b,'" role\x3d"presentation" ');e?e[k]&&d.push("width:"+v(e[k])):d.push("width:"+Math.floor(100/c.length)+"%");h&&d.push("height:"+v(h));f&&void 0!==f.padding&&d.push("padding:"+v(f.padding));CKEDITOR.env.ie&&CKEDITOR.env.quirks&&
g[k].align&&d.push("text-align:"+g[k].align);0<d.length&&a.push('style\x3d"'+d.join("; ")+'" ');a.push("\x3e",c[k],"\x3c/td\x3e")}a.push("\x3c/tr\x3e\x3c/tbody\x3e");return a.join("")})}},vbox:function(a,b,c,d,f){if(!(3>arguments.length)){this._||(this._={});var g=this._.children=b,e=f&&f.width||null,h=f&&f.heights||null;CKEDITOR.ui.dialog.uiElement.call(this,a,f||{type:"vbox"},d,"div",null,{role:"presentation"},function(){var b=['\x3ctable role\x3d"presentation" cellspacing\x3d"0" border\x3d"0" '];
b.push('style\x3d"');f&&f.expand&&b.push("height:100%;");b.push("width:"+v(e||"100%"),";");CKEDITOR.env.webkit&&b.push("float:none;");b.push('"');b.push('align\x3d"',CKEDITOR.tools.htmlEncode(f&&f.align||("ltr"==a.getParentEditor().lang.dir?"left":"right")),'" ');b.push("\x3e\x3ctbody\x3e");for(var d=0;d<c.length;d++){var k=[];b.push('\x3ctr\x3e\x3ctd role\x3d"presentation" ');e&&k.push("width:"+v(e||"100%"));h?k.push("height:"+v(h[d])):f&&f.expand&&k.push("height:"+Math.floor(100/c.length)+"%");
f&&void 0!==f.padding&&k.push("padding:"+v(f.padding));CKEDITOR.env.ie&&CKEDITOR.env.quirks&&g[d].align&&k.push("text-align:"+g[d].align);0<k.length&&b.push('style\x3d"',k.join("; "),'" ');b.push(' class\x3d"cke_dialog_ui_vbox_child"\x3e',c[d],"\x3c/td\x3e\x3c/tr\x3e")}b.push("\x3c/tbody\x3e\x3c/table\x3e");return b.join("")})}}}})();CKEDITOR.ui.dialog.uiElement.prototype={getElement:function(){return CKEDITOR.document.getById(this.domId)},getInputElement:function(){return this.getElement()},getDialog:function(){return this._.dialog},
setValue:function(a,b){this.getInputElement().setValue(a);!b&&this.fire("change",{value:a});return this},getValue:function(){return this.getInputElement().getValue()},isChanged:function(){return!1},selectParentTab:function(){for(var a=this.getInputElement();(a=a.getParent())&&-1==a.$.className.search("cke_dialog_page_contents"););if(!a)return this;a=a.getAttribute("name");this._.dialog._.currentTabId!=a&&this._.dialog.selectPage(a);return this},focus:function(){this.selectParentTab().getInputElement().focus();
return this},registerEvents:function(a){var b=/^on([A-Z]\w+)/,c,d=function(a,b,c,d){b.on("load",function(){a.getInputElement().on(c,d,a)})},f;for(f in a)if(c=f.match(b))this.eventProcessors[f]?this.eventProcessors[f].call(this,this._.dialog,a[f]):d(this,this._.dialog,c[1].toLowerCase(),a[f]);return this},eventProcessors:{onLoad:function(a,b){a.on("load",b,this)},onShow:function(a,b){a.on("show",b,this)},onHide:function(a,b){a.on("hide",b,this)}},accessKeyDown:function(){this.focus()},accessKeyUp:function(){},
disable:function(){var a=this.getElement();this.getInputElement().setAttribute("disabled","true");a.addClass("cke_disabled")},enable:function(){var a=this.getElement();this.getInputElement().removeAttribute("disabled");a.removeClass("cke_disabled")},isEnabled:function(){return!this.getElement().hasClass("cke_disabled")},isVisible:function(){return this.getInputElement().isVisible()},isFocusable:function(){return this.isEnabled()&&this.isVisible()?!0:!1}};CKEDITOR.ui.dialog.hbox.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,
{getChild:function(a){if(1>arguments.length)return this._.children.concat();a.splice||(a=[a]);return 2>a.length?this._.children[a[0]]:this._.children[a[0]]&&this._.children[a[0]].getChild?this._.children[a[0]].getChild(a.slice(1,a.length)):null}},!0);CKEDITOR.ui.dialog.vbox.prototype=new CKEDITOR.ui.dialog.hbox;(function(){var a={build:function(a,b,c){for(var d=b.children,f,g=[],e=[],h=0;h<d.length&&(f=d[h]);h++){var k=[];g.push(k);e.push(CKEDITOR.dialog._.uiElementBuilders[f.type].build(a,f,k))}return new CKEDITOR.ui.dialog[b.type](a,
e,g,c,b)}};CKEDITOR.dialog.addUIElement("hbox",a);CKEDITOR.dialog.addUIElement("vbox",a)})();CKEDITOR.dialogCommand=function(a,b){this.dialogName=a;CKEDITOR.tools.extend(this,b,!0)};CKEDITOR.dialogCommand.prototype={exec:function(a){var b=this.tabId;a.openDialog(this.dialogName,function(a){b&&a.selectPage(b)})},canUndo:!1,editorFocus:1};(function(){var a=/^([a]|[^a])+$/,b=/^\d*$/,c=/^\d*(?:\.\d+)?$/,d=/^(((\d*(\.\d+))|(\d*))(px|\%)?)?$/,f=/^(((\d*(\.\d+))|(\d*))(px|em|ex|in|cm|mm|pt|pc|\%)?)?$/i,
g=/^(\s*[\w-]+\s*:\s*[^:;]+(?:;|$))*$/;CKEDITOR.VALIDATE_OR=1;CKEDITOR.VALIDATE_AND=2;CKEDITOR.dialog.validate={functions:function(){var a=arguments;return function(){var b=this&&this.getValue?this.getValue():a[0],c,d=CKEDITOR.VALIDATE_AND,f=[],g;for(g=0;g<a.length;g++)if("function"==typeof a[g])f.push(a[g]);else break;g<a.length&&"string"==typeof a[g]&&(c=a[g],g++);g<a.length&&"number"==typeof a[g]&&(d=a[g]);var e=d==CKEDITOR.VALIDATE_AND?!0:!1;for(g=0;g<f.length;g++)e=d==CKEDITOR.VALIDATE_AND?e&&
f[g](b):e||f[g](b);return e?!0:c}},regex:function(a,b){return function(c){c=this&&this.getValue?this.getValue():c;return a.test(c)?!0:b}},notEmpty:function(b){return this.regex(a,b)},integer:function(a){return this.regex(b,a)},number:function(a){return this.regex(c,a)},cssLength:function(a){return this.functions(function(a){return f.test(CKEDITOR.tools.trim(a))},a)},htmlLength:function(a){return this.functions(function(a){return d.test(CKEDITOR.tools.trim(a))},a)},inlineStyle:function(a){return this.functions(function(a){return g.test(CKEDITOR.tools.trim(a))},
a)},equals:function(a,b){return this.functions(function(b){return b==a},b)},notEqual:function(a,b){return this.functions(function(b){return b!=a},b)}};CKEDITOR.on("instanceDestroyed",function(a){if(CKEDITOR.tools.isEmpty(CKEDITOR.instances)){for(var b;b=CKEDITOR.dialog._.currentTop;)b.hide();for(var c in C)C[c].remove();C={}}a=a.editor._.storedDialogs;for(var d in a)a[d].destroy()})})();CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{openDialog:function(a,b){var c=null,d=CKEDITOR.dialog._.dialogDefinitions[a];
null===CKEDITOR.dialog._.currentTop&&p(this);if("function"==typeof d)c=this._.storedDialogs||(this._.storedDialogs={}),c=c[a]||(c[a]=new CKEDITOR.dialog(this,a)),b&&b.call(c,c),c.show();else{if("failed"==d)throw q(this),Error('[CKEDITOR.dialog.openDialog] Dialog "'+a+'" failed when loading definition.');"string"==typeof d&&CKEDITOR.scriptLoader.load(CKEDITOR.getUrl(d),function(){"function"!=typeof CKEDITOR.dialog._.dialogDefinitions[a]&&(CKEDITOR.dialog._.dialogDefinitions[a]="failed");this.openDialog(a,
b)},this,0,1)}CKEDITOR.skin.loadPart("dialog");return c}})}(),CKEDITOR.plugins.add("dialog",{requires:"dialogui",init:function(a){a.on("doubleclick",function(e){e.data.dialog&&a.openDialog(e.data.dialog)},null,null,999)}}),function(){CKEDITOR.plugins.add("a11yhelp",{requires:"dialog",availableLangs:{af:1,ar:1,az:1,bg:1,ca:1,cs:1,cy:1,da:1,de:1,"de-ch":1,el:1,en:1,"en-au":1,"en-gb":1,eo:1,es:1,"es-mx":1,et:1,eu:1,fa:1,fi:1,fo:1,fr:1,"fr-ca":1,gl:1,gu:1,he:1,hi:1,hr:1,hu:1,id:1,it:1,ja:1,km:1,ko:1,
ku:1,lt:1,lv:1,mk:1,mn:1,nb:1,nl:1,no:1,oc:1,pl:1,pt:1,"pt-br":1,ro:1,ru:1,si:1,sk:1,sl:1,sq:1,sr:1,"sr-latn":1,sv:1,th:1,tr:1,tt:1,ug:1,uk:1,vi:1,zh:1,"zh-cn":1},init:function(a){var e=this;a.addCommand("a11yHelp",{exec:function(){var b=a.langCode,b=e.availableLangs[b]?b:e.availableLangs[b.replace(/-.*/,"")]?b.replace(/-.*/,""):"en";CKEDITOR.scriptLoader.load(CKEDITOR.getUrl(e.path+"dialogs/lang/"+b+".js"),function(){a.lang.a11yhelp=e.langEntries[b];a.openDialog("a11yHelp")})},modes:{wysiwyg:1,source:1},
readOnly:1,canUndo:!1});a.setKeystroke(CKEDITOR.ALT+48,"a11yHelp");CKEDITOR.dialog.add("a11yHelp",this.path+"dialogs/a11yhelp.js");a.on("ariaEditorHelpLabel",function(b){b.data.label=a.lang.common.editorHelp})}})}(),CKEDITOR.plugins.add("about",{requires:"dialog",init:function(a){var e=a.addCommand("about",new CKEDITOR.dialogCommand("about"));e.modes={wysiwyg:1,source:1};e.canUndo=!1;e.readOnly=1;a.ui.addButton&&a.ui.addButton("About",{label:a.lang.about.dlgTitle,command:"about",toolbar:"about"});
CKEDITOR.dialog.add("about",this.path+"dialogs/about.js")}}),CKEDITOR.plugins.add("basicstyles",{init:function(a){var e=0,b=function(b,g,c,m){if(m){m=new CKEDITOR.style(m);var f=d[c];f.unshift(m);a.attachStyleStateChange(m,function(b){!a.readOnly&&a.getCommand(c).setState(b)});a.addCommand(c,new CKEDITOR.styleCommand(m,{contentForms:f}));a.ui.addButton&&a.ui.addButton(b,{label:g,command:c,toolbar:"basicstyles,"+(e+=10)})}},d={bold:["strong","b",["span",function(a){a=a.styles["font-weight"];return"bold"==
a||700<=+a}]],italic:["em","i",["span",function(a){return"italic"==a.styles["font-style"]}]],underline:["u",["span",function(a){return"underline"==a.styles["text-decoration"]}]],strike:["s","strike",["span",function(a){return"line-through"==a.styles["text-decoration"]}]],subscript:["sub"],superscript:["sup"]},g=a.config,l=a.lang.basicstyles;b("Bold",l.bold,"bold",g.coreStyles_bold);b("Italic",l.italic,"italic",g.coreStyles_italic);b("Underline",l.underline,"underline",g.coreStyles_underline);b("Strike",
l.strike,"strike",g.coreStyles_strike);b("Subscript",l.subscript,"subscript",g.coreStyles_subscript);b("Superscript",l.superscript,"superscript",g.coreStyles_superscript);a.setKeystroke([[CKEDITOR.CTRL+66,"bold"],[CKEDITOR.CTRL+73,"italic"],[CKEDITOR.CTRL+85,"underline"]])}}),CKEDITOR.config.coreStyles_bold={element:"strong",overrides:"b"},CKEDITOR.config.coreStyles_italic={element:"em",overrides:"i"},CKEDITOR.config.coreStyles_underline={element:"u"},CKEDITOR.config.coreStyles_strike={element:"s",
overrides:"strike"},CKEDITOR.config.coreStyles_subscript={element:"sub"},CKEDITOR.config.coreStyles_superscript={element:"sup"},function(){var a={exec:function(a){var b=a.getCommand("blockquote").state,d=a.getSelection(),g=d&&d.getRanges()[0];if(g){var l=d.createBookmarks();if(CKEDITOR.env.ie){var k=l[0].startNode,h=l[0].endNode,c;if(k&&"blockquote"==k.getParent().getName())for(c=k;c=c.getNext();)if(c.type==CKEDITOR.NODE_ELEMENT&&c.isBlockBoundary()){k.move(c,!0);break}if(h&&"blockquote"==h.getParent().getName())for(c=
h;c=c.getPrevious();)if(c.type==CKEDITOR.NODE_ELEMENT&&c.isBlockBoundary()){h.move(c);break}}var m=g.createIterator();m.enlargeBr=a.config.enterMode!=CKEDITOR.ENTER_BR;if(b==CKEDITOR.TRISTATE_OFF){for(k=[];b=m.getNextParagraph();)k.push(b);1>k.length&&(b=a.document.createElement(a.config.enterMode==CKEDITOR.ENTER_P?"p":"div"),h=l.shift(),g.insertNode(b),b.append(new CKEDITOR.dom.text("",a.document)),g.moveToBookmark(h),g.selectNodeContents(b),g.collapse(!0),h=g.createBookmark(),k.push(b),l.unshift(h));
c=k[0].getParent();g=[];for(h=0;h<k.length;h++)b=k[h],c=c.getCommonAncestor(b.getParent());for(b={table:1,tbody:1,tr:1,ol:1,ul:1};b[c.getName()];)c=c.getParent();for(h=null;0<k.length;){for(b=k.shift();!b.getParent().equals(c);)b=b.getParent();b.equals(h)||g.push(b);h=b}for(;0<g.length;)if(b=g.shift(),"blockquote"==b.getName()){for(h=new CKEDITOR.dom.documentFragment(a.document);b.getFirst();)h.append(b.getFirst().remove()),k.push(h.getLast());h.replace(b)}else k.push(b);g=a.document.createElement("blockquote");
for(g.insertBefore(k[0]);0<k.length;)b=k.shift(),g.append(b)}else if(b==CKEDITOR.TRISTATE_ON){h=[];for(c={};b=m.getNextParagraph();){for(k=g=null;b.getParent();){if("blockquote"==b.getParent().getName()){g=b.getParent();k=b;break}b=b.getParent()}g&&k&&!k.getCustomData("blockquote_moveout")&&(h.push(k),CKEDITOR.dom.element.setMarker(c,k,"blockquote_moveout",!0))}CKEDITOR.dom.element.clearAllMarkers(c);b=[];k=[];for(c={};0<h.length;)m=h.shift(),g=m.getParent(),m.getPrevious()?m.getNext()?(m.breakParent(m.getParent()),
k.push(m.getNext())):m.remove().insertAfter(g):m.remove().insertBefore(g),g.getCustomData("blockquote_processed")||(k.push(g),CKEDITOR.dom.element.setMarker(c,g,"blockquote_processed",!0)),b.push(m);CKEDITOR.dom.element.clearAllMarkers(c);for(h=k.length-1;0<=h;h--){g=k[h];a:{c=g;for(var m=0,f=c.getChildCount(),n=void 0;m<f&&(n=c.getChild(m));m++)if(n.type==CKEDITOR.NODE_ELEMENT&&n.isBlockBoundary()){c=!1;break a}c=!0}c&&g.remove()}if(a.config.enterMode==CKEDITOR.ENTER_BR)for(g=!0;b.length;)if(m=b.shift(),
"div"==m.getName()){h=new CKEDITOR.dom.documentFragment(a.document);!g||!m.getPrevious()||m.getPrevious().type==CKEDITOR.NODE_ELEMENT&&m.getPrevious().isBlockBoundary()||h.append(a.document.createElement("br"));for(g=m.getNext()&&!(m.getNext().type==CKEDITOR.NODE_ELEMENT&&m.getNext().isBlockBoundary());m.getFirst();)m.getFirst().remove().appendTo(h);g&&h.append(a.document.createElement("br"));h.replace(m);g=!1}}d.selectBookmarks(l);a.focus()}},refresh:function(a,b){this.setState(a.elementPath(b.block||
b.blockLimit).contains("blockquote",1)?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF)},context:"blockquote",allowedContent:"blockquote",requiredContent:"blockquote"};CKEDITOR.plugins.add("blockquote",{init:function(e){e.blockless||(e.addCommand("blockquote",a),e.ui.addButton&&e.ui.addButton("Blockquote",{label:e.lang.blockquote.toolbar,command:"blockquote",toolbar:"blocks,10"}))}})}(),"use strict",function(){function a(a,d){CKEDITOR.tools.extend(this,d,{editor:a,id:"cke-"+CKEDITOR.tools.getUniqueId(),
area:a._.notificationArea});d.type||(this.type="info");this.element=this._createElement();a.plugins.clipboard&&CKEDITOR.plugins.clipboard.preventDefaultDropOnElement(this.element)}function e(a){var d=this;this.editor=a;this.notifications=[];this.element=this._createElement();this._uiBuffer=CKEDITOR.tools.eventsBuffer(10,this._layout,this);this._changeBuffer=CKEDITOR.tools.eventsBuffer(500,this._layout,this);a.on("destroy",function(){d._removeListeners();d.element.remove()})}CKEDITOR.plugins.add("notification",
{init:function(a){function d(a){var b=new CKEDITOR.dom.element("div");b.setStyles({position:"fixed","margin-left":"-9999px"});b.setAttributes({"aria-live":"assertive","aria-atomic":"true"});b.setText(a);CKEDITOR.document.getBody().append(b);setTimeout(function(){b.remove()},100)}a._.notificationArea=new e(a);a.showNotification=function(d,e,k){var h,c;"progress"==e?h=k:c=k;d=new CKEDITOR.plugins.notification(a,{message:d,type:e,progress:h,duration:c});d.show();return d};a.on("key",function(g){if(27==
g.data.keyCode){var e=a._.notificationArea.notifications;e.length&&(d(a.lang.notification.closed),e[e.length-1].hide(),g.cancel())}})}});a.prototype={show:function(){!1!==this.editor.fire("notificationShow",{notification:this})&&(this.area.add(this),this._hideAfterTimeout())},update:function(a){var d=!0;!1===this.editor.fire("notificationUpdate",{notification:this,options:a})&&(d=!1);var g=this.element,e=g.findOne(".cke_notification_message"),k=g.findOne(".cke_notification_progress"),h=a.type;g.removeAttribute("role");
a.progress&&"progress"!=this.type&&(h="progress");h&&(g.removeClass(this._getClass()),g.removeAttribute("aria-label"),this.type=h,g.addClass(this._getClass()),g.setAttribute("aria-label",this.type),"progress"!=this.type||k?"progress"!=this.type&&k&&k.remove():(k=this._createProgressElement(),k.insertBefore(e)));void 0!==a.message&&(this.message=a.message,e.setHtml(this.message));void 0!==a.progress&&(this.progress=a.progress,k&&k.setStyle("width",this._getPercentageProgress()));d&&a.important&&(g.setAttribute("role",
"alert"),this.isVisible()||this.area.add(this));this.duration=a.duration;this._hideAfterTimeout()},hide:function(){!1!==this.editor.fire("notificationHide",{notification:this})&&this.area.remove(this)},isVisible:function(){return 0<=CKEDITOR.tools.indexOf(this.area.notifications,this)},_createElement:function(){var a=this,d,g,e=this.editor.lang.common.close;d=new CKEDITOR.dom.element("div");d.addClass("cke_notification");d.addClass(this._getClass());d.setAttributes({id:this.id,role:"alert","aria-label":this.type});
"progress"==this.type&&d.append(this._createProgressElement());g=new CKEDITOR.dom.element("p");g.addClass("cke_notification_message");g.setHtml(this.message);d.append(g);g=CKEDITOR.dom.element.createFromHtml('\x3ca class\x3d"cke_notification_close" href\x3d"javascript:void(0)" title\x3d"'+e+'" role\x3d"button" tabindex\x3d"-1"\x3e\x3cspan class\x3d"cke_label"\x3eX\x3c/span\x3e\x3c/a\x3e');d.append(g);g.on("click",function(){a.editor.focus();a.hide()});return d},_getClass:function(){return"progress"==
this.type?"cke_notification_info":"cke_notification_"+this.type},_createProgressElement:function(){var a=new CKEDITOR.dom.element("span");a.addClass("cke_notification_progress");a.setStyle("width",this._getPercentageProgress());return a},_getPercentageProgress:function(){return Math.round(100*(this.progress||0))+"%"},_hideAfterTimeout:function(){var a=this,d;this._hideTimeoutId&&clearTimeout(this._hideTimeoutId);if("number"==typeof this.duration)d=this.duration;else if("info"==this.type||"success"==
this.type)d="number"==typeof this.editor.config.notification_duration?this.editor.config.notification_duration:5E3;d&&(a._hideTimeoutId=setTimeout(function(){a.hide()},d))}};e.prototype={add:function(a){this.notifications.push(a);this.element.append(a.element);1==this.element.getChildCount()&&(CKEDITOR.document.getBody().append(this.element),this._attachListeners());this._layout()},remove:function(a){var d=CKEDITOR.tools.indexOf(this.notifications,a);0>d||(this.notifications.splice(d,1),a.element.remove(),
this.element.getChildCount()||(this._removeListeners(),this.element.remove()))},_createElement:function(){var a=this.editor,d=a.config,g=new CKEDITOR.dom.element("div");g.addClass("cke_notifications_area");g.setAttribute("id","cke_notifications_area_"+a.name);g.setStyle("z-index",d.baseFloatZIndex-2);return g},_attachListeners:function(){var a=CKEDITOR.document.getWindow(),d=this.editor;a.on("scroll",this._uiBuffer.input);a.on("resize",this._uiBuffer.input);d.on("change",this._changeBuffer.input);
d.on("floatingSpaceLayout",this._layout,this,null,20);d.on("blur",this._layout,this,null,20)},_removeListeners:function(){var a=CKEDITOR.document.getWindow(),d=this.editor;a.removeListener("scroll",this._uiBuffer.input);a.removeListener("resize",this._uiBuffer.input);d.removeListener("change",this._changeBuffer.input);d.removeListener("floatingSpaceLayout",this._layout);d.removeListener("blur",this._layout)},_layout:function(){function a(){d.setStyle("left",t(w+e.width-n-p))}var d=this.element,g=
this.editor,e=g.ui.contentsElement.getClientRect(),k=g.ui.contentsElement.getDocumentPosition(),h,c,m=d.getClientRect(),f,n=this._notificationWidth,p=this._notificationMargin;f=CKEDITOR.document.getWindow();var q=f.getScrollPosition(),v=f.getViewPaneSize(),y=CKEDITOR.document.getBody(),r=y.getDocumentPosition(),t=CKEDITOR.tools.cssLength;n&&p||(f=this.element.getChild(0),n=this._notificationWidth=f.getClientRect().width,p=this._notificationMargin=parseInt(f.getComputedStyle("margin-left"),10)+parseInt(f.getComputedStyle("margin-right"),
10));g.toolbar&&(h=g.ui.space("top"),c=h.getClientRect());h&&h.isVisible()&&c.bottom>e.top&&c.bottom<e.bottom-m.height?d.setStyles({position:"fixed",top:t(c.bottom)}):0<e.top?d.setStyles({position:"absolute",top:t(k.y)}):k.y+e.height-m.height>q.y?d.setStyles({position:"fixed",top:0}):d.setStyles({position:"absolute",top:t(k.y+e.height-m.height)});var w="fixed"==d.getStyle("position")?e.left:"static"!=y.getComputedStyle("position")?k.x-r.x:k.x;e.width<n+p?k.x+n+p>q.x+v.width?a():d.setStyle("left",
t(w)):k.x+n+p>q.x+v.width?d.setStyle("left",t(w)):k.x+e.width/2+n/2+p>q.x+v.width?d.setStyle("left",t(w-k.x+q.x+v.width-n-p)):0>e.left+e.width-n-p?a():0>e.left+e.width/2-n/2?d.setStyle("left",t(w-k.x+q.x)):d.setStyle("left",t(w+e.width/2-n/2-p/2))}};CKEDITOR.plugins.notification=a}(),function(){var a='\x3ca id\x3d"{id}" class\x3d"cke_button cke_button__{name} cke_button_{state} {cls}"'+(CKEDITOR.env.gecko&&!CKEDITOR.env.hc?"":" href\x3d\"javascript:void('{titleJs}')\"")+' title\x3d"{title}" tabindex\x3d"-1" hidefocus\x3d"true" role\x3d"button" aria-labelledby\x3d"{id}_label" aria-describedby\x3d"{id}_description" aria-haspopup\x3d"{hasArrow}" aria-disabled\x3d"{ariaDisabled}"';
CKEDITOR.env.gecko&&CKEDITOR.env.mac&&(a+=' onkeypress\x3d"return false;"');CKEDITOR.env.gecko&&(a+=' onblur\x3d"this.style.cssText \x3d this.style.cssText;"');var a=a+(' onkeydown\x3d"return CKEDITOR.tools.callFunction({keydownFn},event);" onfocus\x3d"return CKEDITOR.tools.callFunction({focusFn},event);" '+(CKEDITOR.env.ie?'onclick\x3d"return false;" onmouseup':"onclick")+'\x3d"CKEDITOR.tools.callFunction({clickFn},this);return false;"\x3e\x3cspan class\x3d"cke_button_icon cke_button__{iconName}_icon" style\x3d"{style}"'),
a=a+'\x3e\x26nbsp;\x3c/span\x3e\x3cspan id\x3d"{id}_label" class\x3d"cke_button_label cke_button__{name}_label" aria-hidden\x3d"false"\x3e{label}\x3c/span\x3e\x3cspan id\x3d"{id}_description" class\x3d"cke_button_label" aria-hidden\x3d"false"\x3e{ariaShortcut}\x3c/span\x3e{arrowHtml}\x3c/a\x3e',e=CKEDITOR.addTemplate("buttonArrow",'\x3cspan class\x3d"cke_button_arrow"\x3e'+(CKEDITOR.env.hc?"\x26#9660;":"")+"\x3c/span\x3e"),b=CKEDITOR.addTemplate("button",a);CKEDITOR.plugins.add("button",{beforeInit:function(a){a.ui.addHandler(CKEDITOR.UI_BUTTON,
CKEDITOR.ui.button.handler)}});CKEDITOR.UI_BUTTON="button";CKEDITOR.ui.button=function(a){CKEDITOR.tools.extend(this,a,{title:a.label,click:a.click||function(b){b.execCommand(a.command)}});this._={}};CKEDITOR.ui.button.handler={create:function(a){return new CKEDITOR.ui.button(a)}};CKEDITOR.ui.button.prototype={render:function(a,g){function l(){var b=a.mode;b&&(b=this.modes[b]?void 0!==t[b]?t[b]:CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,b=a.readOnly&&!this.readOnly?CKEDITOR.TRISTATE_DISABLED:
b,this.setState(b),this.refresh&&this.refresh())}var k=CKEDITOR.env,h=this._.id=CKEDITOR.tools.getNextId(),c="",m=this.command,f,n,p;this._.editor=a;var q={id:h,button:this,editor:a,focus:function(){CKEDITOR.document.getById(h).focus()},execute:function(){this.button.click(a)},attach:function(a){this.button.attach(a)}},v=CKEDITOR.tools.addFunction(function(a){if(q.onkey)return a=new CKEDITOR.dom.event(a),!1!==q.onkey(q,a.getKeystroke())}),y=CKEDITOR.tools.addFunction(function(a){var b;q.onfocus&&
(b=!1!==q.onfocus(q,new CKEDITOR.dom.event(a)));return b}),r=0;q.clickFn=f=CKEDITOR.tools.addFunction(function(){r&&(a.unlockSelection(1),r=0);q.execute();k.iOS&&a.focus()});if(this.modes){var t={};a.on("beforeModeUnload",function(){a.mode&&this._.state!=CKEDITOR.TRISTATE_DISABLED&&(t[a.mode]=this._.state)},this);a.on("activeFilterChange",l,this);a.on("mode",l,this);!this.readOnly&&a.on("readOnly",l,this)}else m&&(m=a.getCommand(m))&&(m.on("state",function(){this.setState(m.state)},this),c+=m.state==
CKEDITOR.TRISTATE_ON?"on":m.state==CKEDITOR.TRISTATE_DISABLED?"disabled":"off");if(this.directional)a.on("contentDirChanged",function(b){var c=CKEDITOR.document.getById(this._.id),f=c.getFirst();b=b.data;b!=a.lang.dir?c.addClass("cke_"+b):c.removeClass("cke_ltr").removeClass("cke_rtl");f.setAttribute("style",CKEDITOR.skin.getIconStyle(w,"rtl"==b,this.icon,this.iconOffset))},this);m?(n=a.getCommandKeystroke(m))&&(p=CKEDITOR.tools.keystrokeToString(a.lang.common.keyboard,n)):c+="off";var w=n=this.name||
this.command;this.icon&&!/\./.test(this.icon)&&(w=this.icon,this.icon=null);c={id:h,name:n,iconName:w,label:this.label,cls:this.className||"",state:c,ariaDisabled:"disabled"==c?"true":"false",title:this.title+(p?" ("+p.display+")":""),ariaShortcut:p?a.lang.common.keyboardShortcut+" "+p.aria:"",titleJs:k.gecko&&!k.hc?"":(this.title||"").replace("'",""),hasArrow:this.hasArrow?"true":"false",keydownFn:v,focusFn:y,clickFn:f,style:CKEDITOR.skin.getIconStyle(w,"rtl"==a.lang.dir,this.icon,this.iconOffset),
arrowHtml:this.hasArrow?e.output():""};b.output(c,g);if(this.onRender)this.onRender();return q},setState:function(a){if(this._.state==a)return!1;this._.state=a;var b=CKEDITOR.document.getById(this._.id);return b?(b.setState(a,"cke_button"),a==CKEDITOR.TRISTATE_DISABLED?b.setAttribute("aria-disabled",!0):b.removeAttribute("aria-disabled"),this.hasArrow?(a=a==CKEDITOR.TRISTATE_ON?this._.editor.lang.button.selectedLabel.replace(/%1/g,this.label):this.label,CKEDITOR.document.getById(this._.id+"_label").setText(a)):
a==CKEDITOR.TRISTATE_ON?b.setAttribute("aria-pressed",!0):b.removeAttribute("aria-pressed"),!0):!1},getState:function(){return this._.state},toFeature:function(a){if(this._.feature)return this._.feature;var b=this;this.allowedContent||this.requiredContent||!this.command||(b=a.getCommand(this.command)||b);return this._.feature=b}};CKEDITOR.ui.prototype.addButton=function(a,b){this.add(a,CKEDITOR.UI_BUTTON,b)}}(),function(){function a(a){function b(){for(var c=d(),f=CKEDITOR.tools.clone(a.config.toolbarGroups)||
e(a),m=0;m<f.length;m++){var l=f[m];if("/"!=l){"string"==typeof l&&(l=f[m]={name:l});var y,r=l.groups;if(r)for(var t=0;t<r.length;t++)y=r[t],(y=c[y])&&h(l,y);(y=c[l.name])&&h(l,y)}}return f}function d(){var b={},c,f,e;for(c in a.ui.items)f=a.ui.items[c],e=f.toolbar||"others",e=e.split(","),f=e[0],e=parseInt(e[1]||-1,10),b[f]||(b[f]=[]),b[f].push({name:c,order:e});for(f in b)b[f]=b[f].sort(function(a,b){return a.order==b.order?0:0>b.order?-1:0>a.order?1:a.order<b.order?-1:1});return b}function h(b,
c){if(c.length){b.items?b.items.push(a.ui.create("-")):b.items=[];for(var f;f=c.shift();)f="string"==typeof f?f:f.name,m&&-1!=CKEDITOR.tools.indexOf(m,f)||(f=a.ui.create(f))&&a.addFeature(f)&&b.items.push(f)}}function c(a){var b=[],c,f,d;for(c=0;c<a.length;++c)f=a[c],d={},"/"==f?b.push(f):CKEDITOR.tools.isArray(f)?(h(d,CKEDITOR.tools.clone(f)),b.push(d)):f.items&&(h(d,CKEDITOR.tools.clone(f.items)),d.name=f.name,b.push(d));return b}var m=a.config.removeButtons,m=m&&m.split(","),f=a.config.toolbar;
"string"==typeof f&&(f=a.config["toolbar_"+f]);return a.toolbar=f?c(f):b()}function e(a){return a._.toolbarGroups||(a._.toolbarGroups=[{name:"document",groups:["mode","document","doctools"]},{name:"clipboard",groups:["clipboard","undo"]},{name:"editing",groups:["find","selection","spellchecker"]},{name:"forms"},"/",{name:"basicstyles",groups:["basicstyles","cleanup"]},{name:"paragraph",groups:["list","indent","blocks","align","bidi"]},{name:"links"},{name:"insert"},"/",{name:"styles"},{name:"colors"},
{name:"tools"},{name:"others"},{name:"about"}])}var b=function(){this.toolbars=[];this.focusCommandExecuted=!1};b.prototype.focus=function(){for(var a=0,b;b=this.toolbars[a++];)for(var d=0,e;e=b.items[d++];)if(e.focus){e.focus();return}};var d={modes:{wysiwyg:1,source:1},readOnly:1,exec:function(a){a.toolbox&&(a.toolbox.focusCommandExecuted=!0,CKEDITOR.env.ie||CKEDITOR.env.air?setTimeout(function(){a.toolbox.focus()},100):a.toolbox.focus())}};CKEDITOR.plugins.add("toolbar",{requires:"button",init:function(g){var e,
k=function(a,b){var d,f="rtl"==g.lang.dir,n=g.config.toolbarGroupCycling,p=f?37:39,f=f?39:37,n=void 0===n||n;switch(b){case 9:case CKEDITOR.SHIFT+9:for(;!d||!d.items.length;)if(d=9==b?(d?d.next:a.toolbar.next)||g.toolbox.toolbars[0]:(d?d.previous:a.toolbar.previous)||g.toolbox.toolbars[g.toolbox.toolbars.length-1],d.items.length)for(a=d.items[e?d.items.length-1:0];a&&!a.focus;)(a=e?a.previous:a.next)||(d=0);a&&a.focus();return!1;case p:d=a;do d=d.next,!d&&n&&(d=a.toolbar.items[0]);while(d&&!d.focus);
d?d.focus():k(a,9);return!1;case 40:return a.button&&a.button.hasArrow?a.execute():k(a,40==b?p:f),!1;case f:case 38:d=a;do d=d.previous,!d&&n&&(d=a.toolbar.items[a.toolbar.items.length-1]);while(d&&!d.focus);d?d.focus():(e=1,k(a,CKEDITOR.SHIFT+9),e=0);return!1;case 27:return g.focus(),!1;case 13:case 32:return a.execute(),!1}return!0};g.on("uiSpace",function(d){if(d.data.space==g.config.toolbarLocation){d.removeListener();g.toolbox=new b;var c=CKEDITOR.tools.getNextId(),e=['\x3cspan id\x3d"',c,'" class\x3d"cke_voice_label"\x3e',
g.lang.toolbar.toolbars,"\x3c/span\x3e",'\x3cspan id\x3d"'+g.ui.spaceId("toolbox")+'" class\x3d"cke_toolbox" role\x3d"group" aria-labelledby\x3d"',c,'" onmousedown\x3d"return false;"\x3e'],c=!1!==g.config.toolbarStartupExpanded,f,l;g.config.toolbarCanCollapse&&g.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE&&e.push('\x3cspan class\x3d"cke_toolbox_main"'+(c?"\x3e":' style\x3d"display:none"\x3e'));for(var p=g.toolbox.toolbars,q=a(g),v=q.length,y=0;y<v;y++){var r,t=0,w,A=q[y],x="/"!==A&&("/"===q[y+1]||y==
v-1),u;if(A)if(f&&(e.push("\x3c/span\x3e"),l=f=0),"/"===A)e.push('\x3cspan class\x3d"cke_toolbar_break"\x3e\x3c/span\x3e');else{u=A.items||A;for(var C=0;C<u.length;C++){var z=u[C],B;if(z){var G=function(a){a=a.render(g,e);F=t.items.push(a)-1;0<F&&(a.previous=t.items[F-1],a.previous.next=a);a.toolbar=t;a.onkey=k;a.onfocus=function(){g.toolbox.focusCommandExecuted||g.focus()}};if(z.type==CKEDITOR.UI_SEPARATOR)l=f&&z;else{B=!1!==z.canGroup;if(!t){r=CKEDITOR.tools.getNextId();t={id:r,items:[]};w=A.name&&
(g.lang.toolbar.toolbarGroups[A.name]||A.name);e.push('\x3cspan id\x3d"',r,'" class\x3d"cke_toolbar'+(x?' cke_toolbar_last"':'"'),w?' aria-labelledby\x3d"'+r+'_label"':"",' role\x3d"toolbar"\x3e');w&&e.push('\x3cspan id\x3d"',r,'_label" class\x3d"cke_voice_label"\x3e',w,"\x3c/span\x3e");e.push('\x3cspan class\x3d"cke_toolbar_start"\x3e\x3c/span\x3e');var F=p.push(t)-1;0<F&&(t.previous=p[F-1],t.previous.next=t)}B?f||(e.push('\x3cspan class\x3d"cke_toolgroup" role\x3d"presentation"\x3e'),f=1):f&&(e.push("\x3c/span\x3e"),
f=0);l&&(G(l),l=0);G(z)}}}f&&(e.push("\x3c/span\x3e"),l=f=0);t&&e.push('\x3cspan class\x3d"cke_toolbar_end"\x3e\x3c/span\x3e\x3c/span\x3e')}}g.config.toolbarCanCollapse&&e.push("\x3c/span\x3e");if(g.config.toolbarCanCollapse&&g.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE){var E=CKEDITOR.tools.addFunction(function(){g.execCommand("toolbarCollapse")});g.on("destroy",function(){CKEDITOR.tools.removeFunction(E)});g.addCommand("toolbarCollapse",{readOnly:1,exec:function(a){var b=a.ui.space("toolbar_collapser"),
c=b.getPrevious(),d=a.ui.space("contents"),f=c.getParent(),g=parseInt(d.$.style.height,10),e=f.$.offsetHeight,h=b.hasClass("cke_toolbox_collapser_min");h?(c.show(),b.removeClass("cke_toolbox_collapser_min"),b.setAttribute("title",a.lang.toolbar.toolbarCollapse)):(c.hide(),b.addClass("cke_toolbox_collapser_min"),b.setAttribute("title",a.lang.toolbar.toolbarExpand));b.getFirst().setText(h?"▲":"◀");d.setStyle("height",g-(f.$.offsetHeight-e)+"px");a.fire("resize",{outerHeight:a.container.$.offsetHeight,
contentsHeight:d.$.offsetHeight,outerWidth:a.container.$.offsetWidth})},modes:{wysiwyg:1,source:1}});g.setKeystroke(CKEDITOR.ALT+(CKEDITOR.env.ie||CKEDITOR.env.webkit?189:109),"toolbarCollapse");e.push('\x3ca title\x3d"'+(c?g.lang.toolbar.toolbarCollapse:g.lang.toolbar.toolbarExpand)+'" id\x3d"'+g.ui.spaceId("toolbar_collapser")+'" tabIndex\x3d"-1" class\x3d"cke_toolbox_collapser');c||e.push(" cke_toolbox_collapser_min");e.push('" onclick\x3d"CKEDITOR.tools.callFunction('+E+')"\x3e','\x3cspan class\x3d"cke_arrow"\x3e\x26#9650;\x3c/span\x3e',
"\x3c/a\x3e")}e.push("\x3c/span\x3e");d.data.html+=e.join("")}});g.on("destroy",function(){if(this.toolbox){var a,b=0,d,f,g;for(a=this.toolbox.toolbars;b<a.length;b++)for(f=a[b].items,d=0;d<f.length;d++)g=f[d],g.clickFn&&CKEDITOR.tools.removeFunction(g.clickFn),g.keyDownFn&&CKEDITOR.tools.removeFunction(g.keyDownFn)}});g.on("uiReady",function(){var a=g.ui.space("toolbox");a&&g.focusManager.add(a,1)});g.addCommand("toolbarFocus",d);g.setKeystroke(CKEDITOR.ALT+121,"toolbarFocus");g.ui.add("-",CKEDITOR.UI_SEPARATOR,
{});g.ui.addHandler(CKEDITOR.UI_SEPARATOR,{create:function(){return{render:function(a,b){b.push('\x3cspan class\x3d"cke_toolbar_separator" role\x3d"separator"\x3e\x3c/span\x3e');return{}}}}})}});CKEDITOR.ui.prototype.addToolbarGroup=function(a,b,d){var h=e(this.editor),c=0===b,m={name:a};if(d){if(d=CKEDITOR.tools.search(h,function(a){return a.name==d})){!d.groups&&(d.groups=[]);if(b&&(b=CKEDITOR.tools.indexOf(d.groups,b),0<=b)){d.groups.splice(b+1,0,a);return}c?d.groups.splice(0,0,a):d.groups.push(a);
return}b=null}b&&(b=CKEDITOR.tools.indexOf(h,function(a){return a.name==b}));c?h.splice(0,0,a):"number"==typeof b?h.splice(b+1,0,m):h.push(a)}}(),CKEDITOR.UI_SEPARATOR="separator",CKEDITOR.config.toolbarLocation="top","use strict",function(){function a(a,b,c){b.type||(b.type="auto");if(c&&!1===a.fire("beforePaste",b)||!b.dataValue&&b.dataTransfer.isEmpty())return!1;b.dataValue||(b.dataValue="");if(CKEDITOR.env.gecko&&"drop"==b.method&&a.toolbox)a.once("afterPaste",function(){a.toolbox.focus()});return a.fire("paste",
b)}function e(b){function c(){var a=b.editable();if(CKEDITOR.plugins.clipboard.isCustomCopyCutSupported){var d=function(a){b.readOnly&&"cut"==a.name||B.initPasteDataTransfer(a,b);a.data.preventDefault()};a.on("copy",d);a.on("cut",d);a.on("cut",function(){b.readOnly||b.extractSelectedHtml()},null,null,999)}a.on(B.mainPasteEvent,function(a){"beforepaste"==B.mainPasteEvent&&G||u(a)});"beforepaste"==B.mainPasteEvent&&(a.on("paste",function(a){F||(e(),a.data.preventDefault(),u(a),k("paste"))}),a.on("contextmenu",
h,null,null,0),a.on("beforepaste",function(a){!a.data||a.data.$.ctrlKey||a.data.$.shiftKey||h()},null,null,0));a.on("beforecut",function(){!G&&m(b)});var g;a.attachListener(CKEDITOR.env.ie?a:b.document.getDocumentElement(),"mouseup",function(){g=setTimeout(function(){C()},0)});b.on("destroy",function(){clearTimeout(g)});a.on("keyup",C)}function d(a){return{type:a,canUndo:"cut"==a,startDisabled:!0,fakeKeystroke:"cut"==a?CKEDITOR.CTRL+88:CKEDITOR.CTRL+67,exec:function(){"cut"==this.type&&m();var a;
var c=this.type;if(CKEDITOR.env.ie)a=k(c);else try{a=b.document.$.execCommand(c,!1,null)}catch(d){a=!1}a||b.showNotification(b.lang.clipboard[this.type+"Error"]);return a}}}function g(){return{canUndo:!1,async:!0,fakeKeystroke:CKEDITOR.CTRL+86,exec:function(b,c){function d(c,e){e="undefined"!==typeof e?e:!0;c?(c.method="paste",c.dataTransfer||(c.dataTransfer=B.initPasteDataTransfer()),a(b,c,e)):g&&b.showNotification(k,"info",b.config.clipboard_notificationDuration);b.fire("afterCommandExec",{name:"paste",
command:f,returnValue:!!c})}c="undefined"!==typeof c&&null!==c?c:{};var f=this,g="undefined"!==typeof c.notification?c.notification:!0,e=c.type,h=CKEDITOR.tools.keystrokeToString(b.lang.common.keyboard,b.getCommandKeystroke(this)),k="string"===typeof g?g:b.lang.clipboard.pasteNotification.replace(/%1/,'\x3ckbd aria-label\x3d"'+h.aria+'"\x3e'+h.display+"\x3c/kbd\x3e"),h="string"===typeof c?c:c.dataValue;e?b._.nextPasteType=e:delete b._.nextPasteType;"string"===typeof h?d({dataValue:h}):b.getClipboardData(d)}}}
function e(){F=1;setTimeout(function(){F=0},100)}function h(){G=1;setTimeout(function(){G=0},10)}function k(a){var c=b.document,d=c.getBody(),g=!1,e=function(){g=!0};d.on(a,e);7<CKEDITOR.env.version?c.$.execCommand(a):c.$.selection.createRange().execCommand(a);d.removeListener(a,e);return g}function m(){if(CKEDITOR.env.ie&&!CKEDITOR.env.quirks){var a=b.getSelection(),c,d,g;a.getType()==CKEDITOR.SELECTION_ELEMENT&&(c=a.getSelectedElement())&&(d=a.getRanges()[0],g=b.document.createText(""),g.insertBefore(c),
d.setStartBefore(g),d.setEndAfter(c),a.selectRanges([d]),setTimeout(function(){c.getParent()&&(g.remove(),a.selectElement(c))},0))}}function l(a,c){var d=b.document,g=b.editable(),e=function(a){a.cancel()},h;if(!d.getById("cke_pastebin")){var k=b.getSelection(),m=k.createBookmarks();CKEDITOR.env.ie&&k.root.fire("selectionchange");var n=new CKEDITOR.dom.element(!CKEDITOR.env.webkit&&!g.is("body")||CKEDITOR.env.ie?"div":"body",d);n.setAttributes({id:"cke_pastebin","data-cke-temp":"1"});var r=0,d=d.getWindow();
CKEDITOR.env.webkit?(g.append(n),n.addClass("cke_editable"),g.is("body")||(r="static"!=g.getComputedStyle("position")?g:CKEDITOR.dom.element.get(g.$.offsetParent),r=r.getDocumentPosition().y)):g.getAscendant(CKEDITOR.env.ie?"body":"html",1).append(n);n.setStyles({position:"absolute",top:d.getScrollPosition().y-r+10+"px",width:"1px",height:Math.max(1,d.getViewPaneSize().height-20)+"px",overflow:"hidden",margin:0,padding:0});CKEDITOR.env.safari&&n.setStyles(CKEDITOR.tools.cssVendorPrefix("user-select",
"text"));(r=n.getParent().isReadOnly())?(n.setOpacity(0),n.setAttribute("contenteditable",!0)):n.setStyle("ltr"==b.config.contentsLangDirection?"left":"right","-10000px");b.on("selectionChange",e,null,null,0);if(CKEDITOR.env.webkit||CKEDITOR.env.gecko)h=g.once("blur",e,null,null,-100);r&&n.focus();r=new CKEDITOR.dom.range(n);r.selectNodeContents(n);var t=r.select();CKEDITOR.env.ie&&(h=g.once("blur",function(){b.lockSelection(t)}));var w=CKEDITOR.document.getWindow().getScrollPosition().y;setTimeout(function(){CKEDITOR.env.webkit&&
(CKEDITOR.document.getBody().$.scrollTop=w);h&&h.removeListener();CKEDITOR.env.ie&&g.focus();k.selectBookmarks(m);n.remove();var a;CKEDITOR.env.webkit&&(a=n.getFirst())&&a.is&&a.hasClass("Apple-style-span")&&(n=a);b.removeListener("selectionChange",e);c(n.getHtml())},0)}}function A(){if("paste"==B.mainPasteEvent)return b.fire("beforePaste",{type:"auto",method:"paste"}),!1;b.focus();e();var a=b.focusManager;a.lock();if(b.editable().fire(B.mainPasteEvent)&&!k("paste"))return a.unlock(),!1;a.unlock();
return!0}function x(a){if("wysiwyg"==b.mode)switch(a.data.keyCode){case CKEDITOR.CTRL+86:case CKEDITOR.SHIFT+45:a=b.editable();e();"paste"==B.mainPasteEvent&&a.fire("beforepaste");break;case CKEDITOR.CTRL+88:case CKEDITOR.SHIFT+46:b.fire("saveSnapshot"),setTimeout(function(){b.fire("saveSnapshot")},50)}}function u(c){var d={type:"auto",method:"paste",dataTransfer:B.initPasteDataTransfer(c)};d.dataTransfer.cacheData();var g=!1!==b.fire("beforePaste",d);g&&B.canClipboardApiBeTrusted(d.dataTransfer,
b)?(c.data.preventDefault(),setTimeout(function(){a(b,d)},0)):l(c,function(c){d.dataValue=c.replace(/<span[^>]+data-cke-bookmark[^<]*?<\/span>/ig,"");g&&a(b,d)})}function C(){if("wysiwyg"==b.mode){var a=z("paste");b.getCommand("cut").setState(z("cut"));b.getCommand("copy").setState(z("copy"));b.getCommand("paste").setState(a);b.fire("pasteState",a)}}function z(a){if(E&&a in{paste:1,cut:1})return CKEDITOR.TRISTATE_DISABLED;if("paste"==a)return CKEDITOR.TRISTATE_OFF;a=b.getSelection();var c=a.getRanges();
return a.getType()==CKEDITOR.SELECTION_NONE||1==c.length&&c[0].collapsed?CKEDITOR.TRISTATE_DISABLED:CKEDITOR.TRISTATE_OFF}var B=CKEDITOR.plugins.clipboard,G=0,F=0,E=0;(function(){b.on("key",x);b.on("contentDom",c);b.on("selectionChange",function(a){E=a.data.selection.getRanges()[0].checkReadOnly();C()});b.contextMenu&&b.contextMenu.addListener(function(a,b){E=b.getRanges()[0].checkReadOnly();return{cut:z("cut"),copy:z("copy"),paste:z("paste")}})})();(function(){function a(c,d,g,e,h){var k=b.lang.clipboard[d];
b.addCommand(d,g);b.ui.addButton&&b.ui.addButton(c,{label:k,command:d,toolbar:"clipboard,"+e});b.addMenuItems&&b.addMenuItem(d,{label:k,command:d,group:"clipboard",order:h})}a("Cut","cut",d("cut"),10,1);a("Copy","copy",d("copy"),20,4);a("Paste","paste",g(),30,8)})();b.getClipboardData=function(a,c){function d(a){a.removeListener();a.cancel();c(a.data)}c||(c=a,a=null);b.on("paste",d,null,null,0);!1===A()&&(b.removeListener("paste",d),c(null))}}function b(a){if(CKEDITOR.env.webkit){if(!a.match(/^[^<]*$/g)&&
!a.match(/^(<div><br( ?\/)?><\/div>|<div>[^<]*<\/div>)*$/gi))return"html"}else if(CKEDITOR.env.ie){if(!a.match(/^([^<]|<br( ?\/)?>)*$/gi)&&!a.match(/^(<p>([^<]|<br( ?\/)?>)*<\/p>|(\r\n))*$/gi))return"html"}else if(CKEDITOR.env.gecko){if(!a.match(/^([^<]|<br( ?\/)?>)*$/gi))return"html"}else return"html";return"htmlifiedtext"}function d(a,b){function c(a){return CKEDITOR.tools.repeat("\x3c/p\x3e\x3cp\x3e",~~(a/2))+(1==a%2?"\x3cbr\x3e":"")}b=b.replace(/\s+/g," ").replace(/> +</g,"\x3e\x3c").replace(/<br ?\/>/gi,
"\x3cbr\x3e");b=b.replace(/<\/?[A-Z]+>/g,function(a){return a.toLowerCase()});if(b.match(/^[^<]$/))return b;CKEDITOR.env.webkit&&-1<b.indexOf("\x3cdiv\x3e")&&(b=b.replace(/^(<div>(<br>|)<\/div>)(?!$|(<div>(<br>|)<\/div>))/g,"\x3cbr\x3e").replace(/^(<div>(<br>|)<\/div>){2}(?!$)/g,"\x3cdiv\x3e\x3c/div\x3e"),b.match(/<div>(<br>|)<\/div>/)&&(b="\x3cp\x3e"+b.replace(/(<div>(<br>|)<\/div>)+/g,function(a){return c(a.split("\x3c/div\x3e\x3cdiv\x3e").length+1)})+"\x3c/p\x3e"),b=b.replace(/<\/div><div>/g,"\x3cbr\x3e"),
b=b.replace(/<\/?div>/g,""));CKEDITOR.env.gecko&&a.enterMode!=CKEDITOR.ENTER_BR&&(CKEDITOR.env.gecko&&(b=b.replace(/^<br><br>$/,"\x3cbr\x3e")),-1<b.indexOf("\x3cbr\x3e\x3cbr\x3e")&&(b="\x3cp\x3e"+b.replace(/(<br>){2,}/g,function(a){return c(a.length/4)})+"\x3c/p\x3e"));return k(a,b)}function g(){function a(){var b={},c;for(c in CKEDITOR.dtd)"$"!=c.charAt(0)&&"div"!=c&&"span"!=c&&(b[c]=1);return b}var b={};return{get:function(c){return"plain-text"==c?b.plainText||(b.plainText=new CKEDITOR.filter("br")):
"semantic-content"==c?((c=b.semanticContent)||(c=new CKEDITOR.filter,c.allow({$1:{elements:a(),attributes:!0,styles:!1,classes:!1}}),c=b.semanticContent=c),c):c?new CKEDITOR.filter(c):null}}}function l(a,b,c){b=CKEDITOR.htmlParser.fragment.fromHtml(b);var d=new CKEDITOR.htmlParser.basicWriter;c.applyTo(b,!0,!1,a.activeEnterMode);b.writeHtml(d);return d.getHtml()}function k(a,b){a.enterMode==CKEDITOR.ENTER_BR?b=b.replace(/(<\/p><p>)+/g,function(a){return CKEDITOR.tools.repeat("\x3cbr\x3e",a.length/
7*2)}).replace(/<\/?p>/g,""):a.enterMode==CKEDITOR.ENTER_DIV&&(b=b.replace(/<(\/)?p>/g,"\x3c$1div\x3e"));return b}function h(a){a.data.preventDefault();a.data.$.dataTransfer.dropEffect="none"}function c(b){var c=CKEDITOR.plugins.clipboard;b.on("contentDom",function(){function d(c,g,e){g.select();a(b,{dataTransfer:e,method:"drop"},1);e.sourceEditor.fire("saveSnapshot");e.sourceEditor.editable().extractHtmlFromRange(c);e.sourceEditor.getSelection().selectRanges([c]);e.sourceEditor.fire("saveSnapshot")}
function g(d,e){d.select();a(b,{dataTransfer:e,method:"drop"},1);c.resetDragDataTransfer()}function e(a,c,d){var g={$:a.data.$,target:a.data.getTarget()};c&&(g.dragRange=c);d&&(g.dropRange=d);!1===b.fire(a.name,g)&&a.data.preventDefault()}function h(a){a.type!=CKEDITOR.NODE_ELEMENT&&(a=a.getParent());return a.getChildCount()}var k=b.editable(),m=CKEDITOR.plugins.clipboard.getDropTarget(b),l=b.ui.space("top"),A=b.ui.space("bottom");c.preventDefaultDropOnElement(l);c.preventDefaultDropOnElement(A);
k.attachListener(m,"dragstart",e);k.attachListener(b,"dragstart",c.resetDragDataTransfer,c,null,1);k.attachListener(b,"dragstart",function(a){c.initDragDataTransfer(a,b)},null,null,2);k.attachListener(b,"dragstart",function(){var a=c.dragRange=b.getSelection().getRanges()[0];CKEDITOR.env.ie&&10>CKEDITOR.env.version&&(c.dragStartContainerChildCount=a?h(a.startContainer):null,c.dragEndContainerChildCount=a?h(a.endContainer):null)},null,null,100);k.attachListener(m,"dragend",e);k.attachListener(b,"dragend",
c.initDragDataTransfer,c,null,1);k.attachListener(b,"dragend",c.resetDragDataTransfer,c,null,100);k.attachListener(m,"dragover",function(a){if(CKEDITOR.env.edge)a.data.preventDefault();else{var b=a.data.getTarget();b&&b.is&&b.is("html")?a.data.preventDefault():CKEDITOR.env.ie&&CKEDITOR.plugins.clipboard.isFileApiSupported&&a.data.$.dataTransfer.types.contains("Files")&&a.data.preventDefault()}});k.attachListener(m,"drop",function(a){if(!a.data.$.defaultPrevented){a.data.preventDefault();var d=a.data.getTarget();
if(!d.isReadOnly()||d.type==CKEDITOR.NODE_ELEMENT&&d.is("html")){var d=c.getRangeAtDropPosition(a,b),g=c.dragRange;d&&e(a,g,d)}}},null,null,9999);k.attachListener(b,"drop",c.initDragDataTransfer,c,null,1);k.attachListener(b,"drop",function(a){if(a=a.data){var e=a.dropRange,h=a.dragRange,k=a.dataTransfer;k.getTransferType(b)==CKEDITOR.DATA_TRANSFER_INTERNAL?setTimeout(function(){c.internalDrop(h,e,k,b)},0):k.getTransferType(b)==CKEDITOR.DATA_TRANSFER_CROSS_EDITORS?d(h,e,k):g(e,k)}},null,null,9999)})}
var m;CKEDITOR.plugins.add("clipboard",{requires:"notification,toolbar",init:function(a){var h,k=g();a.config.forcePasteAsPlainText?h="plain-text":a.config.pasteFilter?h=a.config.pasteFilter:!CKEDITOR.env.webkit||"pasteFilter"in a.config||(h="semantic-content");a.pasteFilter=k.get(h);e(a);c(a);if(CKEDITOR.env.gecko){var m=["image/png","image/jpeg","image/gif"],v;a.on("paste",function(b){var c=b.data,d=c.dataTransfer;if(!c.dataValue&&"paste"==c.method&&d&&1==d.getFilesCount()&&v!=d.id&&(d=d.getFile(0),
-1!=CKEDITOR.tools.indexOf(m,d.type))){var g=new FileReader;g.addEventListener("load",function(){b.data.dataValue='\x3cimg src\x3d"'+g.result+'" /\x3e';a.fire("paste",b.data)},!1);g.addEventListener("abort",function(){a.fire("paste",b.data)},!1);g.addEventListener("error",function(){a.fire("paste",b.data)},!1);g.readAsDataURL(d);v=c.dataTransfer.id;b.stop()}},null,null,1)}a.on("paste",function(b){b.data.dataTransfer||(b.data.dataTransfer=new CKEDITOR.plugins.clipboard.dataTransfer);if(!b.data.dataValue){var c=
b.data.dataTransfer,d=c.getData("text/html");if(d)b.data.dataValue=d,b.data.type="html";else if(d=c.getData("text/plain"))b.data.dataValue=a.editable().transformPlainTextToHtml(d),b.data.type="text"}},null,null,1);a.on("paste",function(a){var b=a.data.dataValue,c=CKEDITOR.dtd.$block;-1<b.indexOf("Apple-")&&(b=b.replace(/<span class="Apple-converted-space">&nbsp;<\/span>/gi," "),"html"!=a.data.type&&(b=b.replace(/<span class="Apple-tab-span"[^>]*>([^<]*)<\/span>/gi,function(a,b){return b.replace(/\t/g,
"\x26nbsp;\x26nbsp; \x26nbsp;")})),-1<b.indexOf('\x3cbr class\x3d"Apple-interchange-newline"\x3e')&&(a.data.startsWithEOL=1,a.data.preSniffing="html",b=b.replace(/<br class="Apple-interchange-newline">/,"")),b=b.replace(/(<[^>]+) class="Apple-[^"]*"/gi,"$1"));if(b.match(/^<[^<]+cke_(editable|contents)/i)){var d,f,g=new CKEDITOR.dom.element("div");for(g.setHtml(b);1==g.getChildCount()&&(d=g.getFirst())&&d.type==CKEDITOR.NODE_ELEMENT&&(d.hasClass("cke_editable")||d.hasClass("cke_contents"));)g=f=d;
f&&(b=f.getHtml().replace(/<br>$/i,""))}CKEDITOR.env.ie?b=b.replace(/^&nbsp;(?: |\r\n)?<(\w+)/g,function(b,d){return d.toLowerCase()in c?(a.data.preSniffing="html","\x3c"+d):b}):CKEDITOR.env.webkit?b=b.replace(/<\/(\w+)><div><br><\/div>$/,function(b,d){return d in c?(a.data.endsWithEOL=1,"\x3c/"+d+"\x3e"):b}):CKEDITOR.env.gecko&&(b=b.replace(/(\s)<br>$/,"$1"));a.data.dataValue=b},null,null,3);a.on("paste",function(c){c=c.data;var g=a._.nextPasteType||c.type,e=c.dataValue,h,m=a.config.clipboard_defaultContentType||
"html",n=c.dataTransfer.getTransferType(a);h="html"==g||"html"==c.preSniffing?"html":b(e);delete a._.nextPasteType;"htmlifiedtext"==h&&(e=d(a.config,e));"text"==g&&"html"==h?e=l(a,e,k.get("plain-text")):n==CKEDITOR.DATA_TRANSFER_EXTERNAL&&a.pasteFilter&&!c.dontFilter&&(e=l(a,e,a.pasteFilter));c.startsWithEOL&&(e='\x3cbr data-cke-eol\x3d"1"\x3e'+e);c.endsWithEOL&&(e+='\x3cbr data-cke-eol\x3d"1"\x3e');"auto"==g&&(g="html"==h||"html"==m?"html":"text");c.type=g;c.dataValue=e;delete c.preSniffing;delete c.startsWithEOL;
delete c.endsWithEOL},null,null,6);a.on("paste",function(b){b=b.data;b.dataValue&&(a.insertHtml(b.dataValue,b.type,b.range),setTimeout(function(){a.fire("afterPaste")},0))},null,null,1E3)}});CKEDITOR.plugins.clipboard={isCustomCopyCutSupported:(!CKEDITOR.env.ie||16<=CKEDITOR.env.version)&&!CKEDITOR.env.iOS,isCustomDataTypesSupported:!CKEDITOR.env.ie||16<=CKEDITOR.env.version,isFileApiSupported:!CKEDITOR.env.ie||9<CKEDITOR.env.version,mainPasteEvent:CKEDITOR.env.ie&&!CKEDITOR.env.edge?"beforepaste":
"paste",canClipboardApiBeTrusted:function(a,b){return a.getTransferType(b)!=CKEDITOR.DATA_TRANSFER_EXTERNAL||CKEDITOR.env.chrome&&!a.isEmpty()||CKEDITOR.env.gecko&&(a.getData("text/html")||a.getFilesCount())||CKEDITOR.env.safari&&603<=CKEDITOR.env.version&&!CKEDITOR.env.iOS||CKEDITOR.env.edge&&16<=CKEDITOR.env.version?!0:!1},getDropTarget:function(a){var b=a.editable();return CKEDITOR.env.ie&&9>CKEDITOR.env.version||b.isInline()?b:a.document},fixSplitNodesAfterDrop:function(a,b,c,d){function g(a,
c,d){var f=a;f.type==CKEDITOR.NODE_TEXT&&(f=a.getParent());if(f.equals(c)&&d!=c.getChildCount())return a=b.startContainer.getChild(b.startOffset-1),c=b.startContainer.getChild(b.startOffset),a&&a.type==CKEDITOR.NODE_TEXT&&c&&c.type==CKEDITOR.NODE_TEXT&&(d=a.getLength(),a.setText(a.getText()+c.getText()),c.remove(),b.setStart(a,d),b.collapse(!0)),!0}var e=b.startContainer;"number"==typeof d&&"number"==typeof c&&e.type==CKEDITOR.NODE_ELEMENT&&(g(a.startContainer,e,c)||g(a.endContainer,e,d))},isDropRangeAffectedByDragRange:function(a,
b){var c=b.startContainer,d=b.endOffset;return a.endContainer.equals(c)&&a.endOffset<=d||a.startContainer.getParent().equals(c)&&a.startContainer.getIndex()<d||a.endContainer.getParent().equals(c)&&a.endContainer.getIndex()<d?!0:!1},internalDrop:function(b,c,d,g){var e=CKEDITOR.plugins.clipboard,h=g.editable(),k,m;g.fire("saveSnapshot");g.fire("lockSnapshot",{dontUpdate:1});CKEDITOR.env.ie&&10>CKEDITOR.env.version&&this.fixSplitNodesAfterDrop(b,c,e.dragStartContainerChildCount,e.dragEndContainerChildCount);
(m=this.isDropRangeAffectedByDragRange(b,c))||(k=b.createBookmark(!1));e=c.clone().createBookmark(!1);m&&(k=b.createBookmark(!1));b=k.startNode;c=k.endNode;m=e.startNode;c&&b.getPosition(m)&CKEDITOR.POSITION_PRECEDING&&c.getPosition(m)&CKEDITOR.POSITION_FOLLOWING&&m.insertBefore(b);b=g.createRange();b.moveToBookmark(k);h.extractHtmlFromRange(b,1);c=g.createRange();c.moveToBookmark(e);a(g,{dataTransfer:d,method:"drop",range:c},1);g.fire("unlockSnapshot")},getRangeAtDropPosition:function(a,b){var c=
a.data.$,d=c.clientX,g=c.clientY,e=b.getSelection(!0).getRanges()[0],h=b.createRange();if(a.data.testRange)return a.data.testRange;if(document.caretRangeFromPoint&&b.document.$.caretRangeFromPoint(d,g))c=b.document.$.caretRangeFromPoint(d,g),h.setStart(CKEDITOR.dom.node(c.startContainer),c.startOffset),h.collapse(!0);else if(c.rangeParent)h.setStart(CKEDITOR.dom.node(c.rangeParent),c.rangeOffset),h.collapse(!0);else{if(CKEDITOR.env.ie&&8<CKEDITOR.env.version&&e&&b.editable().hasFocus)return e;if(document.body.createTextRange){b.focus();
c=b.document.getBody().$.createTextRange();try{for(var k=!1,m=0;20>m&&!k;m++){if(!k)try{c.moveToPoint(d,g-m),k=!0}catch(l){}if(!k)try{c.moveToPoint(d,g+m),k=!0}catch(x){}}if(k){var u="cke-temp-"+(new Date).getTime();c.pasteHTML('\x3cspan id\x3d"'+u+'"\x3e\x3c/span\x3e');var C=b.document.getById(u);h.moveToPosition(C,CKEDITOR.POSITION_BEFORE_START);C.remove()}else{var z=b.document.$.elementFromPoint(d,g),B=new CKEDITOR.dom.element(z),G;if(B.equals(b.editable())||"html"==B.getName())return e&&e.startContainer&&
!e.startContainer.equals(b.editable())?e:null;G=B.getClientRect();d<G.left?h.setStartAt(B,CKEDITOR.POSITION_AFTER_START):h.setStartAt(B,CKEDITOR.POSITION_BEFORE_END);h.collapse(!0)}}catch(F){return null}}else return null}return h},initDragDataTransfer:function(a,b){var c=a.data.$?a.data.$.dataTransfer:null,d=new this.dataTransfer(c,b);"dragstart"===a.name&&d.storeId();c?this.dragData&&d.id==this.dragData.id?d=this.dragData:this.dragData=d:this.dragData?d=this.dragData:this.dragData=d;a.data.dataTransfer=
d},resetDragDataTransfer:function(){this.dragData=null},initPasteDataTransfer:function(a,b){if(this.isCustomCopyCutSupported){if(a&&a.data&&a.data.$){var c=a.data.$.clipboardData,d=new this.dataTransfer(c,b);"copy"!==a.name&&"cut"!==a.name||d.storeId();this.copyCutData&&d.id==this.copyCutData.id?(d=this.copyCutData,d.$=c):this.copyCutData=d;return d}return new this.dataTransfer(null,b)}return new this.dataTransfer(CKEDITOR.env.edge&&a&&a.data.$&&a.data.$.clipboardData||null,b)},preventDefaultDropOnElement:function(a){a&&
a.on("dragover",h)}};m=CKEDITOR.plugins.clipboard.isCustomDataTypesSupported?"cke/id":"Text";CKEDITOR.plugins.clipboard.dataTransfer=function(a,b){a&&(this.$=a);this._={metaRegExp:/^<meta.*?>/i,bodyRegExp:/<body(?:[\s\S]*?)>([\s\S]*)<\/body>/i,fragmentRegExp:/\x3c!--(?:Start|End)Fragment--\x3e/g,data:{},files:[],nativeHtmlCache:"",normalizeType:function(a){a=a.toLowerCase();return"text"==a||"text/plain"==a?"Text":"url"==a?"URL":a}};this._.fallbackDataTransfer=new CKEDITOR.plugins.clipboard.fallbackDataTransfer(this);
this.id=this.getData(m);this.id||(this.id="Text"==m?"":"cke-"+CKEDITOR.tools.getUniqueId());b&&(this.sourceEditor=b,this.setData("text/html",b.getSelectedHtml(1)),"Text"==m||this.getData("text/plain")||this.setData("text/plain",b.getSelection().getSelectedText()))};CKEDITOR.DATA_TRANSFER_INTERNAL=1;CKEDITOR.DATA_TRANSFER_CROSS_EDITORS=2;CKEDITOR.DATA_TRANSFER_EXTERNAL=3;CKEDITOR.plugins.clipboard.dataTransfer.prototype={getData:function(a,b){a=this._.normalizeType(a);var c="text/html"==a&&b?this._.nativeHtmlCache:
this._.data[a];if(void 0===c||null===c||""===c){if(this._.fallbackDataTransfer.isRequired())c=this._.fallbackDataTransfer.getData(a,b);else try{c=this.$.getData(a)||""}catch(d){c=""}"text/html"!=a||b||(c=this._stripHtml(c))}"Text"==a&&CKEDITOR.env.gecko&&this.getFilesCount()&&"file://"==c.substring(0,7)&&(c="");if("string"===typeof c)var g=c.indexOf("\x3c/html\x3e"),c=-1!==g?c.substring(0,g+7):c;return c},setData:function(a,b){a=this._.normalizeType(a);"text/html"==a?(this._.data[a]=this._stripHtml(b),
this._.nativeHtmlCache=b):this._.data[a]=b;if(CKEDITOR.plugins.clipboard.isCustomDataTypesSupported||"URL"==a||"Text"==a)if("Text"==m&&"Text"==a&&(this.id=b),this._.fallbackDataTransfer.isRequired())this._.fallbackDataTransfer.setData(a,b);else try{this.$.setData(a,b)}catch(c){}},storeId:function(){"Text"!==m&&this.setData(m,this.id)},getTransferType:function(a){return this.sourceEditor?this.sourceEditor==a?CKEDITOR.DATA_TRANSFER_INTERNAL:CKEDITOR.DATA_TRANSFER_CROSS_EDITORS:CKEDITOR.DATA_TRANSFER_EXTERNAL},
cacheData:function(){function a(c){c=b._.normalizeType(c);var d=b.getData(c);"text/html"==c&&(b._.nativeHtmlCache=b.getData(c,!0),d=b._stripHtml(d));d&&(b._.data[c]=d)}if(this.$){var b=this,c,d;if(CKEDITOR.plugins.clipboard.isCustomDataTypesSupported){if(this.$.types)for(c=0;c<this.$.types.length;c++)a(this.$.types[c])}else a("Text"),a("URL");d=this._getImageFromClipboard();if(this.$&&this.$.files||d){this._.files=[];if(this.$.files&&this.$.files.length)for(c=0;c<this.$.files.length;c++)this._.files.push(this.$.files[c]);
0===this._.files.length&&d&&this._.files.push(d)}}},getFilesCount:function(){return this._.files.length?this._.files.length:this.$&&this.$.files&&this.$.files.length?this.$.files.length:this._getImageFromClipboard()?1:0},getFile:function(a){return this._.files.length?this._.files[a]:this.$&&this.$.files&&this.$.files.length?this.$.files[a]:0===a?this._getImageFromClipboard():void 0},isEmpty:function(){var a={},b;if(this.getFilesCount())return!1;CKEDITOR.tools.array.forEach(CKEDITOR.tools.objectKeys(this._.data),
function(b){a[b]=1});if(this.$)if(CKEDITOR.plugins.clipboard.isCustomDataTypesSupported){if(this.$.types)for(var c=0;c<this.$.types.length;c++)a[this.$.types[c]]=1}else a.Text=1,a.URL=1;"Text"!=m&&(a[m]=0);for(b in a)if(a[b]&&""!==this.getData(b))return!1;return!0},_getImageFromClipboard:function(){var a;if(this.$&&this.$.items&&this.$.items[0])try{if((a=this.$.items[0].getAsFile())&&a.type)return a}catch(b){}},_stripHtml:function(a){if(a&&a.length){a=a.replace(this._.metaRegExp,"");var b=this._.bodyRegExp.exec(a);
b&&b.length&&(a=b[1],a=a.replace(this._.fragmentRegExp,""))}return a}};CKEDITOR.plugins.clipboard.fallbackDataTransfer=function(a){this._dataTransfer=a;this._customDataFallbackType="text/html"};CKEDITOR.plugins.clipboard.fallbackDataTransfer._isCustomMimeTypeSupported=null;CKEDITOR.plugins.clipboard.fallbackDataTransfer._customTypes=[];CKEDITOR.plugins.clipboard.fallbackDataTransfer.prototype={isRequired:function(){var a=CKEDITOR.plugins.clipboard.fallbackDataTransfer,b=this._dataTransfer.$;if(null===
a._isCustomMimeTypeSupported)if(b){a._isCustomMimeTypeSupported=!1;try{b.setData("cke/mimetypetest","cke test value"),a._isCustomMimeTypeSupported="cke test value"===b.getData("cke/mimetypetest"),b.clearData("cke/mimetypetest")}catch(c){}}else return!1;return!a._isCustomMimeTypeSupported},getData:function(a,b){var c=this._getData(this._customDataFallbackType,!0);if(b)return c;var c=this._extractDataComment(c),d=null,d=a===this._customDataFallbackType?c.content:c.data&&c.data[a]?c.data[a]:this._getData(a,
!0);return null!==d?d:""},setData:function(a,b){var c=a===this._customDataFallbackType;c&&(b=this._applyDataComment(b,this._getFallbackTypeData()));var d=b,g=this._dataTransfer.$;try{g.setData(a,d),c&&(this._dataTransfer._.nativeHtmlCache=d)}catch(e){if(this._isUnsupportedMimeTypeError(e)){c=CKEDITOR.plugins.clipboard.fallbackDataTransfer;-1===CKEDITOR.tools.indexOf(c._customTypes,a)&&c._customTypes.push(a);var c=this._getFallbackTypeContent(),h=this._getFallbackTypeData();h[a]=d;try{d=this._applyDataComment(c,
h),g.setData(this._customDataFallbackType,d),this._dataTransfer._.nativeHtmlCache=d}catch(k){d=""}}}return d},_getData:function(a,b){var c=this._dataTransfer._.data;if(!b&&c[a])return c[a];try{return this._dataTransfer.$.getData(a)}catch(d){return null}},_getFallbackTypeContent:function(){var a=this._dataTransfer._.data[this._customDataFallbackType];a||(a=this._extractDataComment(this._getData(this._customDataFallbackType,!0)).content);return a},_getFallbackTypeData:function(){var a=CKEDITOR.plugins.clipboard.fallbackDataTransfer._customTypes,
b=this._extractDataComment(this._getData(this._customDataFallbackType,!0)).data||{},c=this._dataTransfer._.data;CKEDITOR.tools.array.forEach(a,function(a){void 0!==c[a]?b[a]=c[a]:void 0!==b[a]&&(b[a]=b[a])},this);return b},_isUnsupportedMimeTypeError:function(a){return a.message&&-1!==a.message.search(/element not found/gi)},_extractDataComment:function(a){var b={data:null,content:a||""};if(a&&16<a.length){var c;(c=/\x3c!--cke-data:(.*?)--\x3e/g.exec(a))&&c[1]&&(b.data=JSON.parse(decodeURIComponent(c[1])),
b.content=a.replace(c[0],""))}return b},_applyDataComment:function(a,b){var c="";b&&CKEDITOR.tools.objectKeys(b).length&&(c="\x3c!--cke-data:"+encodeURIComponent(JSON.stringify(b))+"--\x3e");return c+(a&&a.length?a:"")}}}(),CKEDITOR.config.clipboard_notificationDuration=1E4,function(){CKEDITOR.plugins.add("panel",{beforeInit:function(a){a.ui.addHandler(CKEDITOR.UI_PANEL,CKEDITOR.ui.panel.handler)}});CKEDITOR.UI_PANEL="panel";CKEDITOR.ui.panel=function(a,b){b&&CKEDITOR.tools.extend(this,b);CKEDITOR.tools.extend(this,
{className:"",css:[]});this.id=CKEDITOR.tools.getNextId();this.document=a;this.isFramed=this.forceIFrame||this.css.length;this._={blocks:{}}};CKEDITOR.ui.panel.handler={create:function(a){return new CKEDITOR.ui.panel(a)}};var a=CKEDITOR.addTemplate("panel",'\x3cdiv lang\x3d"{langCode}" id\x3d"{id}" dir\x3d{dir} class\x3d"cke cke_reset_all {editorId} cke_panel cke_panel {cls} cke_{dir}" style\x3d"z-index:{z-index}" role\x3d"presentation"\x3e{frame}\x3c/div\x3e'),e=CKEDITOR.addTemplate("panel-frame",
'\x3ciframe id\x3d"{id}" class\x3d"cke_panel_frame" role\x3d"presentation" frameborder\x3d"0" src\x3d"{src}"\x3e\x3c/iframe\x3e'),b=CKEDITOR.addTemplate("panel-frame-inner",'\x3c!DOCTYPE html\x3e\x3chtml class\x3d"cke_panel_container {env}" dir\x3d"{dir}" lang\x3d"{langCode}"\x3e\x3chead\x3e{css}\x3c/head\x3e\x3cbody class\x3d"cke_{dir}" style\x3d"margin:0;padding:0" onload\x3d"{onload}"\x3e\x3c/body\x3e\x3c/html\x3e');CKEDITOR.ui.panel.prototype={render:function(d,g){this.getHolderElement=function(){var a=
this._.holder;if(!a){if(this.isFramed){var a=this.document.getById(this.id+"_frame"),c=a.getParent(),a=a.getFrameDocument();CKEDITOR.env.iOS&&c.setStyles({overflow:"scroll","-webkit-overflow-scrolling":"touch"});c=CKEDITOR.tools.addFunction(CKEDITOR.tools.bind(function(){this.isLoaded=!0;if(this.onLoad)this.onLoad()},this));a.write(b.output(CKEDITOR.tools.extend({css:CKEDITOR.tools.buildStyleHtml(this.css),onload:"window.parent.CKEDITOR.tools.callFunction("+c+");"},l)));a.getWindow().$.CKEDITOR=CKEDITOR;
a.on("keydown",function(a){var b=a.data.getKeystroke(),c=this.document.getById(this.id).getAttribute("dir");this._.onKeyDown&&!1===this._.onKeyDown(b)?a.data.preventDefault():(27==b||b==("rtl"==c?39:37))&&this.onEscape&&!1===this.onEscape(b)&&a.data.preventDefault()},this);a=a.getBody();a.unselectable();CKEDITOR.env.air&&CKEDITOR.tools.callFunction(c)}else a=this.document.getById(this.id);this._.holder=a}return a};var l={editorId:d.id,id:this.id,langCode:d.langCode,dir:d.lang.dir,cls:this.className,
frame:"",env:CKEDITOR.env.cssClass,"z-index":d.config.baseFloatZIndex+1};if(this.isFramed){var k=CKEDITOR.env.air?"javascript:void(0)":CKEDITOR.env.ie?"javascript:void(function(){"+encodeURIComponent("document.open();("+CKEDITOR.tools.fixDomain+")();document.close();")+"}())":"";l.frame=e.output({id:this.id+"_frame",src:k})}k=a.output(l);g&&g.push(k);return k},addBlock:function(a,b){b=this._.blocks[a]=b instanceof CKEDITOR.ui.panel.block?b:new CKEDITOR.ui.panel.block(this.getHolderElement(),b);this._.currentBlock||
this.showBlock(a);return b},getBlock:function(a){return this._.blocks[a]},showBlock:function(a){a=this._.blocks[a];var b=this._.currentBlock,e=!this.forceIFrame||CKEDITOR.env.ie?this._.holder:this.document.getById(this.id+"_frame");b&&b.hide();this._.currentBlock=a;CKEDITOR.fire("ariaWidget",e);a._.focusIndex=-1;this._.onKeyDown=a.onKeyDown&&CKEDITOR.tools.bind(a.onKeyDown,a);a.show();return a},destroy:function(){this.element&&this.element.remove()}};CKEDITOR.ui.panel.block=CKEDITOR.tools.createClass({$:function(a,
b){this.element=a.append(a.getDocument().createElement("div",{attributes:{tabindex:-1,"class":"cke_panel_block"},styles:{display:"none"}}));b&&CKEDITOR.tools.extend(this,b);this.element.setAttributes({role:this.attributes.role||"presentation","aria-label":this.attributes["aria-label"],title:this.attributes.title||this.attributes["aria-label"]});this.keys={};this._.focusIndex=-1;this.element.disableContextMenu()},_:{markItem:function(a){-1!=a&&(a=this.element.getElementsByTag("a").getItem(this._.focusIndex=
a),CKEDITOR.env.webkit&&a.getDocument().getWindow().focus(),a.focus(),this.onMark&&this.onMark(a))},markFirstDisplayed:function(a){for(var b=function(a){return a.type==CKEDITOR.NODE_ELEMENT&&"none"==a.getStyle("display")},e=this._.getItems(),k,h,c=e.count()-1;0<=c;c--)if(k=e.getItem(c),k.getAscendant(b)||(h=k,this._.focusIndex=c),"true"==k.getAttribute("aria-selected")){h=k;this._.focusIndex=c;break}h&&(a&&a(),CKEDITOR.env.webkit&&h.getDocument().getWindow().focus(),h.focus(),this.onMark&&this.onMark(h))},
getItems:function(){return this.element.getElementsByTag("a")}},proto:{show:function(){this.element.setStyle("display","")},hide:function(){this.onHide&&!0===this.onHide.call(this)||this.element.setStyle("display","none")},onKeyDown:function(a,b){var e=this.keys[a];switch(e){case "next":for(var k=this._.focusIndex,e=this.element.getElementsByTag("a"),h;h=e.getItem(++k);)if(h.getAttribute("_cke_focus")&&h.$.offsetWidth){this._.focusIndex=k;h.focus();break}return h||b?!1:(this._.focusIndex=-1,this.onKeyDown(a,
1));case "prev":k=this._.focusIndex;for(e=this.element.getElementsByTag("a");0<k&&(h=e.getItem(--k));){if(h.getAttribute("_cke_focus")&&h.$.offsetWidth){this._.focusIndex=k;h.focus();break}h=null}return h||b?!1:(this._.focusIndex=e.count(),this.onKeyDown(a,1));case "click":case "mouseup":return k=this._.focusIndex,(h=0<=k&&this.element.getElementsByTag("a").getItem(k))&&(h.$[e]?h.$[e]():h.$["on"+e]()),!1}return!0}}})}(),CKEDITOR.plugins.add("floatpanel",{requires:"panel"}),function(){function a(a,
d,g,l,k){k=CKEDITOR.tools.genKey(d.getUniqueId(),g.getUniqueId(),a.lang.dir,a.uiColor||"",l.css||"",k||"");var h=e[k];h||(h=e[k]=new CKEDITOR.ui.panel(d,l),h.element=g.append(CKEDITOR.dom.element.createFromHtml(h.render(a),d)),h.element.setStyles({display:"none",position:"absolute"}));return h}var e={};CKEDITOR.ui.floatPanel=CKEDITOR.tools.createClass({$:function(b,d,g,e){function k(){f.hide()}g.forceIFrame=1;g.toolbarRelated&&b.elementMode==CKEDITOR.ELEMENT_MODE_INLINE&&(d=CKEDITOR.document.getById("cke_"+
b.name));var h=d.getDocument();e=a(b,h,d,g,e||0);var c=e.element,m=c.getFirst(),f=this;c.disableContextMenu();this.element=c;this._={editor:b,panel:e,parentElement:d,definition:g,document:h,iframe:m,children:[],dir:b.lang.dir,showBlockParams:null};b.on("mode",k);b.on("resize",k);h.getWindow().on("resize",function(){this.reposition()},this)},proto:{addBlock:function(a,d){return this._.panel.addBlock(a,d)},addListBlock:function(a,d){return this._.panel.addListBlock(a,d)},getBlock:function(a){return this._.panel.getBlock(a)},
showBlock:function(a,d,g,e,k,h){var c=this._.panel,m=c.showBlock(a);this._.showBlockParams=[].slice.call(arguments);this.allowBlur(!1);var f=this._.editor.editable();this._.returnFocus=f.hasFocus?f:new CKEDITOR.dom.element(CKEDITOR.document.$.activeElement);this._.hideTimeout=0;var n=this.element,f=this._.iframe,f=CKEDITOR.env.ie&&!CKEDITOR.env.edge?f:new CKEDITOR.dom.window(f.$.contentWindow),p=n.getDocument(),q=this._.parentElement.getPositionedAncestor(),v=d.getDocumentPosition(p),p=q?q.getDocumentPosition(p):
{x:0,y:0},y="rtl"==this._.dir,r=v.x+(e||0)-p.x,t=v.y+(k||0)-p.y;!y||1!=g&&4!=g?y||2!=g&&3!=g||(r+=d.$.offsetWidth-1):r+=d.$.offsetWidth;if(3==g||4==g)t+=d.$.offsetHeight-1;this._.panel._.offsetParentId=d.getId();n.setStyles({top:t+"px",left:0,display:""});n.setOpacity(0);n.getFirst().removeStyle("width");this._.editor.focusManager.add(f);this._.blurSet||(CKEDITOR.event.useCapture=!0,f.on("blur",function(a){function b(){delete this._.returnFocus;this.hide()}this.allowBlur()&&a.data.getPhase()==CKEDITOR.EVENT_PHASE_AT_TARGET&&
this.visible&&!this._.activeChild&&(CKEDITOR.env.iOS?this._.hideTimeout||(this._.hideTimeout=CKEDITOR.tools.setTimeout(b,0,this)):b.call(this))},this),f.on("focus",function(){this._.focused=!0;this.hideChild();this.allowBlur(!0)},this),CKEDITOR.env.iOS&&(f.on("touchstart",function(){clearTimeout(this._.hideTimeout)},this),f.on("touchend",function(){this._.hideTimeout=0;this.focus()},this)),CKEDITOR.event.useCapture=!1,this._.blurSet=1);c.onEscape=CKEDITOR.tools.bind(function(a){if(this.onEscape&&
!1===this.onEscape(a))return!1},this);CKEDITOR.tools.setTimeout(function(){var a=CKEDITOR.tools.bind(function(){var a=n;a.removeStyle("width");if(m.autoSize){var b=m.element.getDocument(),b=(CKEDITOR.env.webkit||CKEDITOR.env.edge?m.element:b.getBody()).$.scrollWidth;CKEDITOR.env.ie&&CKEDITOR.env.quirks&&0<b&&(b+=(a.$.offsetWidth||0)-(a.$.clientWidth||0)+3);a.setStyle("width",b+10+"px");b=m.element.$.scrollHeight;CKEDITOR.env.ie&&CKEDITOR.env.quirks&&0<b&&(b+=(a.$.offsetHeight||0)-(a.$.clientHeight||
0)+3);a.setStyle("height",b+"px");c._.currentBlock.element.setStyle("display","none").removeStyle("display")}else a.removeStyle("height");y&&(r-=n.$.offsetWidth);n.setStyle("left",r+"px");var b=c.element.getWindow(),a=n.$.getBoundingClientRect(),b=b.getViewPaneSize(),d=a.width||a.right-a.left,f=a.height||a.bottom-a.top,g=y?a.right:b.width-a.left,e=y?b.width-a.right:a.left;y?g<d&&(r=e>d?r+d:b.width>d?r-a.left:r-a.right+b.width):g<d&&(r=e>d?r-d:b.width>d?r-a.right+b.width:r-a.left);d=a.top;b.height-
a.top<f&&(t=d>f?t-f:b.height>f?t-a.bottom+b.height:t-a.top);CKEDITOR.env.ie&&(b=a=new CKEDITOR.dom.element(n.$.offsetParent),"html"==b.getName()&&(b=b.getDocument().getBody()),"rtl"==b.getComputedStyle("direction")&&(r=CKEDITOR.env.ie8Compat?r-2*n.getDocument().getDocumentElement().$.scrollLeft:r-(a.$.scrollWidth-a.$.clientWidth)));var a=n.getFirst(),k;(k=a.getCustomData("activePanel"))&&k.onHide&&k.onHide.call(this,1);a.setCustomData("activePanel",this);n.setStyles({top:t+"px",left:r+"px"});n.setOpacity(1);
h&&h()},this);c.isLoaded?a():c.onLoad=a;CKEDITOR.tools.setTimeout(function(){var a=CKEDITOR.env.webkit&&CKEDITOR.document.getWindow().getScrollPosition().y;this.focus();m.element.focus();CKEDITOR.env.webkit&&(CKEDITOR.document.getBody().$.scrollTop=a);this.allowBlur(!0);CKEDITOR.env.ie?CKEDITOR.tools.setTimeout(function(){m.markFirstDisplayed?m.markFirstDisplayed():m._.markFirstDisplayed()},0):m.markFirstDisplayed?m.markFirstDisplayed():m._.markFirstDisplayed();this._.editor.fire("panelShow",this)},
0,this)},CKEDITOR.env.air?200:0,this);this.visible=1;this.onShow&&this.onShow.call(this)},reposition:function(){var a=this._.showBlockParams;this.visible&&this._.showBlockParams&&(this.hide(),this.showBlock.apply(this,a))},focus:function(){if(CKEDITOR.env.webkit){var a=CKEDITOR.document.getActive();a&&!a.equals(this._.iframe)&&a.$.blur()}(this._.lastFocused||this._.iframe.getFrameDocument().getWindow()).focus()},blur:function(){var a=this._.iframe.getFrameDocument().getActive();a&&a.is("a")&&(this._.lastFocused=
a)},hide:function(a){if(this.visible&&(!this.onHide||!0!==this.onHide.call(this))){this.hideChild();CKEDITOR.env.gecko&&this._.iframe.getFrameDocument().$.activeElement.blur();this.element.setStyle("display","none");this.visible=0;this.element.getFirst().removeCustomData("activePanel");if(a=a&&this._.returnFocus)CKEDITOR.env.webkit&&a.type&&a.getWindow().$.focus(),a.focus();delete this._.lastFocused;this._.showBlockParams=null;this._.editor.fire("panelHide",this)}},allowBlur:function(a){var d=this._.panel;
void 0!==a&&(d.allowBlur=a);return d.allowBlur},showAsChild:function(a,d,g,e,k,h){if(this._.activeChild!=a||a._.panel._.offsetParentId!=g.getId())this.hideChild(),a.onHide=CKEDITOR.tools.bind(function(){CKEDITOR.tools.setTimeout(function(){this._.focused||this.hide()},0,this)},this),this._.activeChild=a,this._.focused=!1,a.showBlock(d,g,e,k,h),this.blur(),(CKEDITOR.env.ie7Compat||CKEDITOR.env.ie6Compat)&&setTimeout(function(){a.element.getChild(0).$.style.cssText+=""},100)},hideChild:function(a){var d=
this._.activeChild;d&&(delete d.onHide,delete this._.activeChild,d.hide(),a&&this.focus())}}});CKEDITOR.on("instanceDestroyed",function(){var a=CKEDITOR.tools.isEmpty(CKEDITOR.instances),d;for(d in e){var g=e[d];a?g.destroy():g.element.hide()}a&&(e={})})}(),CKEDITOR.plugins.add("menu",{requires:"floatpanel",beforeInit:function(a){for(var e=a.config.menu_groups.split(","),b=a._.menuGroups={},d=a._.menuItems={},g=0;g<e.length;g++)b[e[g]]=g+1;a.addMenuGroup=function(a,d){b[a]=d||100};a.addMenuItem=function(a,
g){b[g.group]&&(d[a]=new CKEDITOR.menuItem(this,a,g))};a.addMenuItems=function(a){for(var b in a)this.addMenuItem(b,a[b])};a.getMenuItem=function(a){return d[a]};a.removeMenuItem=function(a){delete d[a]}}}),function(){function a(a){a.sort(function(a,b){return a.group<b.group?-1:a.group>b.group?1:a.order<b.order?-1:a.order>b.order?1:0})}var e='\x3cspan class\x3d"cke_menuitem"\x3e\x3ca id\x3d"{id}" class\x3d"cke_menubutton cke_menubutton__{name} cke_menubutton_{state} {cls}" href\x3d"{href}" title\x3d"{title}" tabindex\x3d"-1" _cke_focus\x3d1 hidefocus\x3d"true" role\x3d"{role}" aria-label\x3d"{label}" aria-describedby\x3d"{id}_description" aria-haspopup\x3d"{hasPopup}" aria-disabled\x3d"{disabled}" {ariaChecked} draggable\x3d"false"';
CKEDITOR.env.gecko&&CKEDITOR.env.mac&&(e+=' onkeypress\x3d"return false;"');CKEDITOR.env.gecko&&(e+=' onblur\x3d"this.style.cssText \x3d this.style.cssText;" ondragstart\x3d"return false;"');var e=e+(' onmouseover\x3d"CKEDITOR.tools.callFunction({hoverFn},{index});" onmouseout\x3d"CKEDITOR.tools.callFunction({moveOutFn},{index});" '+(CKEDITOR.env.ie?'onclick\x3d"return false;" onmouseup':"onclick")+'\x3d"CKEDITOR.tools.callFunction({clickFn},{index}); return false;"\x3e'),b=CKEDITOR.addTemplate("menuItem",
e+'\x3cspan class\x3d"cke_menubutton_inner"\x3e\x3cspan class\x3d"cke_menubutton_icon"\x3e\x3cspan class\x3d"cke_button_icon cke_button__{iconName}_icon" style\x3d"{iconStyle}"\x3e\x3c/span\x3e\x3c/span\x3e\x3cspan class\x3d"cke_menubutton_label"\x3e{label}\x3c/span\x3e{shortcutHtml}{arrowHtml}\x3c/span\x3e\x3c/a\x3e\x3cspan id\x3d"{id}_description" class\x3d"cke_voice_label" aria-hidden\x3d"false"\x3e{ariaShortcut}\x3c/span\x3e\x3c/span\x3e'),d=CKEDITOR.addTemplate("menuArrow",'\x3cspan class\x3d"cke_menuarrow"\x3e\x3cspan\x3e{label}\x3c/span\x3e\x3c/span\x3e'),
g=CKEDITOR.addTemplate("menuShortcut",'\x3cspan class\x3d"cke_menubutton_label cke_menubutton_shortcut"\x3e{shortcut}\x3c/span\x3e');CKEDITOR.menu=CKEDITOR.tools.createClass({$:function(a,b){b=this._.definition=b||{};this.id=CKEDITOR.tools.getNextId();this.editor=a;this.items=[];this._.listeners=[];this._.level=b.level||1;var d=CKEDITOR.tools.extend({},b.panel,{css:[CKEDITOR.skin.getPath("editor")],level:this._.level-1,block:{}}),c=d.block.attributes=d.attributes||{};!c.role&&(c.role="menu");this._.panelDefinition=
d},_:{onShow:function(){var a=this.editor.getSelection(),b=a&&a.getStartElement(),d=this.editor.elementPath(),c=this._.listeners;this.removeAll();for(var g=0;g<c.length;g++){var f=c[g](b,a,d);if(f)for(var e in f){var p=this.editor.getMenuItem(e);!p||p.command&&!this.editor.getCommand(p.command).state||(p.state=f[e],this.add(p))}}},onClick:function(a){this.hide();if(a.onClick)a.onClick();else a.command&&this.editor.execCommand(a.command)},onEscape:function(a){var b=this.parent;b?b._.panel.hideChild(1):
27==a&&this.hide(1);return!1},onHide:function(){this.onHide&&this.onHide()},showSubMenu:function(a){var b=this._.subMenu,d=this.items[a];if(d=d.getItems&&d.getItems()){b?b.removeAll():(b=this._.subMenu=new CKEDITOR.menu(this.editor,CKEDITOR.tools.extend({},this._.definition,{level:this._.level+1},!0)),b.parent=this,b._.onClick=CKEDITOR.tools.bind(this._.onClick,this));for(var c in d){var g=this.editor.getMenuItem(c);g&&(g.state=d[c],b.add(g))}var f=this._.panel.getBlock(this.id).element.getDocument().getById(this.id+
String(a));setTimeout(function(){b.show(f,2)},0)}else this._.panel.hideChild(1)}},proto:{add:function(a){a.order||(a.order=this.items.length);this.items.push(a)},removeAll:function(){this.items=[]},show:function(b,d,g,c){if(!this.parent&&(this._.onShow(),!this.items.length))return;d=d||("rtl"==this.editor.lang.dir?2:1);var e=this.items,f=this.editor,n=this._.panel,p=this._.element;if(!n){n=this._.panel=new CKEDITOR.ui.floatPanel(this.editor,CKEDITOR.document.getBody(),this._.panelDefinition,this._.level);
n.onEscape=CKEDITOR.tools.bind(function(a){if(!1===this._.onEscape(a))return!1},this);n.onShow=function(){n._.panel.getHolderElement().getParent().addClass("cke").addClass("cke_reset_all")};n.onHide=CKEDITOR.tools.bind(function(){this._.onHide&&this._.onHide()},this);p=n.addBlock(this.id,this._.panelDefinition.block);p.autoSize=!0;var q=p.keys;q[40]="next";q[9]="next";q[38]="prev";q[CKEDITOR.SHIFT+9]="prev";q["rtl"==f.lang.dir?37:39]=CKEDITOR.env.ie?"mouseup":"click";q[32]=CKEDITOR.env.ie?"mouseup":
"click";CKEDITOR.env.ie&&(q[13]="mouseup");p=this._.element=p.element;q=p.getDocument();q.getBody().setStyle("overflow","hidden");q.getElementsByTag("html").getItem(0).setStyle("overflow","hidden");this._.itemOverFn=CKEDITOR.tools.addFunction(function(a){clearTimeout(this._.showSubTimeout);this._.showSubTimeout=CKEDITOR.tools.setTimeout(this._.showSubMenu,f.config.menu_subMenuDelay||400,this,[a])},this);this._.itemOutFn=CKEDITOR.tools.addFunction(function(){clearTimeout(this._.showSubTimeout)},this);
this._.itemClickFn=CKEDITOR.tools.addFunction(function(a){var b=this.items[a];if(b.state==CKEDITOR.TRISTATE_DISABLED)this.hide(1);else if(b.getItems)this._.showSubMenu(a);else this._.onClick(b)},this)}a(e);for(var q=f.elementPath(),q=['\x3cdiv class\x3d"cke_menu'+(q&&q.direction()!=f.lang.dir?" cke_mixed_dir_content":"")+'" role\x3d"presentation"\x3e'],v=e.length,y=v&&e[0].group,r=0;r<v;r++){var t=e[r];y!=t.group&&(q.push('\x3cdiv class\x3d"cke_menuseparator" role\x3d"separator"\x3e\x3c/div\x3e'),
y=t.group);t.render(this,r,q)}q.push("\x3c/div\x3e");p.setHtml(q.join(""));CKEDITOR.ui.fire("ready",this);this.parent?this.parent._.panel.showAsChild(n,this.id,b,d,g,c):n.showBlock(this.id,b,d,g,c);f.fire("menuShow",[n])},addListener:function(a){this._.listeners.push(a)},hide:function(a){this._.onHide&&this._.onHide();this._.panel&&this._.panel.hide(a)}}});CKEDITOR.menuItem=CKEDITOR.tools.createClass({$:function(a,b,d){CKEDITOR.tools.extend(this,d,{order:0,className:"cke_menubutton__"+b});this.group=
a._.menuGroups[this.group];this.editor=a;this.name=b},proto:{render:function(a,e,h){var c=a.id+String(e),m="undefined"==typeof this.state?CKEDITOR.TRISTATE_OFF:this.state,f="",n=this.editor,p,q,v=m==CKEDITOR.TRISTATE_ON?"on":m==CKEDITOR.TRISTATE_DISABLED?"disabled":"off";this.role in{menuitemcheckbox:1,menuitemradio:1}&&(f=' aria-checked\x3d"'+(m==CKEDITOR.TRISTATE_ON?"true":"false")+'"');var y=this.getItems,r="\x26#"+("rtl"==this.editor.lang.dir?"9668":"9658")+";",t=this.name;this.icon&&!/\./.test(this.icon)&&
(t=this.icon);this.command&&(p=n.getCommand(this.command),(p=n.getCommandKeystroke(p))&&(q=CKEDITOR.tools.keystrokeToString(n.lang.common.keyboard,p)));a={id:c,name:this.name,iconName:t,label:this.label,cls:this.className||"",state:v,hasPopup:y?"true":"false",disabled:m==CKEDITOR.TRISTATE_DISABLED,title:this.label+(q?" ("+q.display+")":""),ariaShortcut:q?n.lang.common.keyboardShortcut+" "+q.aria:"",href:"javascript:void('"+(this.label||"").replace("'")+"')",hoverFn:a._.itemOverFn,moveOutFn:a._.itemOutFn,
clickFn:a._.itemClickFn,index:e,iconStyle:CKEDITOR.skin.getIconStyle(t,"rtl"==this.editor.lang.dir,t==this.icon?null:this.icon,this.iconOffset),shortcutHtml:q?g.output({shortcut:q.display}):"",arrowHtml:y?d.output({label:r}):"",role:this.role?this.role:"menuitem",ariaChecked:f};b.output(a,h)}}})}(),CKEDITOR.config.menu_groups="clipboard,form,tablecell,tablecellproperties,tablerow,tablecolumn,table,anchor,link,image,flash,checkbox,radio,textfield,hiddenfield,imagebutton,button,select,textarea,div",
CKEDITOR.plugins.add("contextmenu",{requires:"menu",onLoad:function(){CKEDITOR.plugins.contextMenu=CKEDITOR.tools.createClass({base:CKEDITOR.menu,$:function(a){this.base.call(this,a,{panel:{className:"cke_menu_panel",attributes:{"aria-label":a.lang.contextmenu.options}}})},proto:{addTarget:function(a,e){a.on("contextmenu",function(a){a=a.data;var d=CKEDITOR.env.webkit?b:CKEDITOR.env.mac?a.$.metaKey:a.$.ctrlKey;if(!e||!d){a.preventDefault();if(CKEDITOR.env.mac&&CKEDITOR.env.webkit){var d=this.editor,
k=(new CKEDITOR.dom.elementPath(a.getTarget(),d.editable())).contains(function(a){return a.hasAttribute("contenteditable")},!0);k&&"false"==k.getAttribute("contenteditable")&&d.getSelection().fake(k)}var k=a.getTarget().getDocument(),h=a.getTarget().getDocument().getDocumentElement(),d=!k.equals(CKEDITOR.document),k=k.getWindow().getScrollPosition(),c=d?a.$.clientX:a.$.pageX||k.x+a.$.clientX,m=d?a.$.clientY:a.$.pageY||k.y+a.$.clientY;CKEDITOR.tools.setTimeout(function(){this.open(h,null,c,m)},CKEDITOR.env.ie?
200:0,this)}},this);if(CKEDITOR.env.webkit){var b,d=function(){b=0};a.on("keydown",function(a){b=CKEDITOR.env.mac?a.data.$.metaKey:a.data.$.ctrlKey});a.on("keyup",d);a.on("contextmenu",d)}},open:function(a,e,b,d){!1!==this.editor.config.enableContextMenu&&(this.editor.focus(),a=a||CKEDITOR.document.getDocumentElement(),this.editor.selectionChange(1),this.show(a,e,b,d))}}})},beforeInit:function(a){var e=a.contextMenu=new CKEDITOR.plugins.contextMenu(a);a.on("contentDom",function(){e.addTarget(a.editable(),
!1!==a.config.browserContextMenuOnCtrl)});a.addCommand("contextMenu",{exec:function(){a.contextMenu.open(a.document.getBody())}});a.setKeystroke(CKEDITOR.SHIFT+121,"contextMenu");a.setKeystroke(CKEDITOR.CTRL+CKEDITOR.SHIFT+121,"contextMenu")}}),function(){function a(a,b){function k(b){b=f.list[b];var c;b.equals(a.editable())||"true"==b.getAttribute("contenteditable")?(c=a.createRange(),c.selectNodeContents(b),c=c.select()):(c=a.getSelection(),c.selectElement(b));CKEDITOR.env.ie&&a.fire("selectionChange",
{selection:c,path:new CKEDITOR.dom.elementPath(b)});a.focus()}function h(){m&&m.setHtml('\x3cspan class\x3d"cke_path_empty"\x3e\x26nbsp;\x3c/span\x3e');delete f.list}var c=a.ui.spaceId("path"),m,f=a._.elementsPath,n=f.idBase;b.html+='\x3cspan id\x3d"'+c+'_label" class\x3d"cke_voice_label"\x3e'+a.lang.elementspath.eleLabel+'\x3c/span\x3e\x3cspan id\x3d"'+c+'" class\x3d"cke_path" role\x3d"group" aria-labelledby\x3d"'+c+'_label"\x3e\x3cspan class\x3d"cke_path_empty"\x3e\x26nbsp;\x3c/span\x3e\x3c/span\x3e';
a.on("uiReady",function(){var b=a.ui.space("path");b&&a.focusManager.add(b,1)});f.onClick=k;var p=CKEDITOR.tools.addFunction(k),q=CKEDITOR.tools.addFunction(function(b,c){var d=f.idBase,e;c=new CKEDITOR.dom.event(c);e="rtl"==a.lang.dir;switch(c.getKeystroke()){case e?39:37:case 9:return(e=CKEDITOR.document.getById(d+(b+1)))||(e=CKEDITOR.document.getById(d+"0")),e.focus(),!1;case e?37:39:case CKEDITOR.SHIFT+9:return(e=CKEDITOR.document.getById(d+(b-1)))||(e=CKEDITOR.document.getById(d+(f.list.length-
1))),e.focus(),!1;case 27:return a.focus(),!1;case 13:case 32:return k(b),!1}return!0});a.on("selectionChange",function(b){for(var e=[],h=f.list=[],k=[],l=f.filters,A=!0,x=b.data.path.elements,u=x.length;u--;){var C=x[u],z=0;b=C.data("cke-display-name")?C.data("cke-display-name"):C.data("cke-real-element-type")?C.data("cke-real-element-type"):C.getName();(A=C.hasAttribute("contenteditable")?"true"==C.getAttribute("contenteditable"):A)||C.hasAttribute("contenteditable")||(z=1);for(var B=0;B<l.length;B++){var G=
l[B](C,b);if(!1===G){z=1;break}b=G||b}z||(h.unshift(C),k.unshift(b))}h=h.length;for(l=0;l<h;l++)b=k[l],A=a.lang.elementspath.eleTitle.replace(/%1/,b),b=d.output({id:n+l,label:A,text:b,jsTitle:"javascript:void('"+b+"')",index:l,keyDownFn:q,clickFn:p}),e.unshift(b);m||(m=CKEDITOR.document.getById(c));k=m;k.setHtml(e.join("")+'\x3cspan class\x3d"cke_path_empty"\x3e\x26nbsp;\x3c/span\x3e');a.fire("elementsPathUpdate",{space:k})});a.on("readOnly",h);a.on("contentDomUnload",h);a.addCommand("elementsPathFocus",
e.toolbarFocus);a.setKeystroke(CKEDITOR.ALT+122,"elementsPathFocus")}var e={toolbarFocus:{editorFocus:!1,readOnly:1,exec:function(a){(a=CKEDITOR.document.getById(a._.elementsPath.idBase+"0"))&&a.focus(CKEDITOR.env.ie||CKEDITOR.env.air)}}},b="";CKEDITOR.env.gecko&&CKEDITOR.env.mac&&(b+=' onkeypress\x3d"return false;"');CKEDITOR.env.gecko&&(b+=' onblur\x3d"this.style.cssText \x3d this.style.cssText;"');var d=CKEDITOR.addTemplate("pathItem",'\x3ca id\x3d"{id}" href\x3d"{jsTitle}" tabindex\x3d"-1" class\x3d"cke_path_item" title\x3d"{label}"'+
b+' hidefocus\x3d"true" onkeydown\x3d"return CKEDITOR.tools.callFunction({keyDownFn},{index}, event );" onclick\x3d"CKEDITOR.tools.callFunction({clickFn},{index}); return false;" role\x3d"button" aria-label\x3d"{label}"\x3e{text}\x3c/a\x3e');CKEDITOR.plugins.add("elementspath",{init:function(b){b._.elementsPath={idBase:"cke_elementspath_"+CKEDITOR.tools.getNextNumber()+"_",filters:[]};b.on("uiSpace",function(d){"bottom"==d.data.space&&a(b,d.data)})}})}(),function(){function a(a,g){var l,k;g.on("refresh",
function(a){var c=[e],d;for(d in a.data.states)c.push(a.data.states[d]);this.setState(CKEDITOR.tools.search(c,b)?b:e)},g,null,100);g.on("exec",function(b){l=a.getSelection();k=l.createBookmarks(1);b.data||(b.data={});b.data.done=!1},g,null,0);g.on("exec",function(){a.forceNextSelectionCheck();l.selectBookmarks(k)},g,null,100)}var e=CKEDITOR.TRISTATE_DISABLED,b=CKEDITOR.TRISTATE_OFF;CKEDITOR.plugins.add("indent",{init:function(b){var e=CKEDITOR.plugins.indent.genericDefinition;a(b,b.addCommand("indent",
new e(!0)));a(b,b.addCommand("outdent",new e));b.ui.addButton&&(b.ui.addButton("Indent",{label:b.lang.indent.indent,command:"indent",directional:!0,toolbar:"indent,20"}),b.ui.addButton("Outdent",{label:b.lang.indent.outdent,command:"outdent",directional:!0,toolbar:"indent,10"}));b.on("dirChanged",function(a){var e=b.createRange(),g=a.data.node;e.setStartBefore(g);e.setEndAfter(g);for(var c=new CKEDITOR.dom.walker(e),m;m=c.next();)if(m.type==CKEDITOR.NODE_ELEMENT)if(!m.equals(g)&&m.getDirection())e.setStartAfter(m),
c=new CKEDITOR.dom.walker(e);else{var f=b.config.indentClasses;if(f)for(var n="ltr"==a.data.dir?["_rtl",""]:["","_rtl"],p=0;p<f.length;p++)m.hasClass(f[p]+n[0])&&(m.removeClass(f[p]+n[0]),m.addClass(f[p]+n[1]));f=m.getStyle("margin-right");n=m.getStyle("margin-left");f?m.setStyle("margin-left",f):m.removeStyle("margin-left");n?m.setStyle("margin-right",n):m.removeStyle("margin-right")}})}});CKEDITOR.plugins.indent={genericDefinition:function(a){this.isIndent=!!a;this.startDisabled=!this.isIndent},
specificDefinition:function(a,b,e){this.name=b;this.editor=a;this.jobs={};this.enterBr=a.config.enterMode==CKEDITOR.ENTER_BR;this.isIndent=!!e;this.relatedGlobal=e?"indent":"outdent";this.indentKey=e?9:CKEDITOR.SHIFT+9;this.database={}},registerCommands:function(a,b){a.on("pluginsLoaded",function(){for(var a in b)(function(a,b){var c=a.getCommand(b.relatedGlobal),d;for(d in b.jobs)c.on("exec",function(c){c.data.done||(a.fire("lockSnapshot"),b.execJob(a,d)&&(c.data.done=!0),a.fire("unlockSnapshot"),
CKEDITOR.dom.element.clearAllMarkers(b.database))},this,null,d),c.on("refresh",function(c){c.data.states||(c.data.states={});c.data.states[b.name+"@"+d]=b.refreshJob(a,d,c.data.path)},this,null,d);a.addFeature(b)})(this,b[a])})}};CKEDITOR.plugins.indent.genericDefinition.prototype={context:"p",exec:function(){}};CKEDITOR.plugins.indent.specificDefinition.prototype={execJob:function(a,b){var l=this.jobs[b];if(l.state!=e)return l.exec.call(this,a)},refreshJob:function(a,b,l){b=this.jobs[b];a.activeFilter.checkFeature(this)?
b.state=b.refresh.call(this,a,l):b.state=e;return b.state},getContext:function(a){return a.contains(this.context)}}}(),function(){function a(a){function c(c){for(var e=k.startContainer,l=k.endContainer;e&&!e.getParent().equals(c);)e=e.getParent();for(;l&&!l.getParent().equals(c);)l=l.getParent();if(!e||!l)return!1;for(var A=[],x=!1;!x;)e.equals(l)&&(x=!0),A.push(e),e=e.getNext();if(1>A.length)return!1;e=c.getParents(!0);for(l=0;l<e.length;l++)if(e[l].getName&&g[e[l].getName()]){c=e[l];break}for(var e=
d.isIndent?1:-1,l=A[0],A=A[A.length-1],x=CKEDITOR.plugins.list.listToArray(c,f),u=x[A.getCustomData("listarray_index")].indent,l=l.getCustomData("listarray_index");l<=A.getCustomData("listarray_index");l++)if(x[l].indent+=e,0<e){for(var v=x[l].parent,z=l-1;0<=z;z--)if(x[z].indent===e){v=x[z].parent;break}x[l].parent=new CKEDITOR.dom.element(v.getName(),v.getDocument())}for(l=A.getCustomData("listarray_index")+1;l<x.length&&x[l].indent>u;l++)x[l].indent+=e;e=CKEDITOR.plugins.list.arrayToList(x,f,null,
a.config.enterMode,c.getDirection());if(!d.isIndent){var B;if((B=c.getParent())&&B.is("li"))for(var A=e.listNode.getChildren(),y=[],q,l=A.count()-1;0<=l;l--)(q=A.getItem(l))&&q.is&&q.is("li")&&y.push(q)}e&&e.listNode.replace(c);if(y&&y.length)for(l=0;l<y.length;l++){for(q=c=y[l];(q=q.getNext())&&q.is&&q.getName()in g;)CKEDITOR.env.needsNbspFiller&&!c.getFirst(b)&&c.append(k.document.createText(" ")),c.append(q);c.insertAfter(B)}e&&a.fire("contentDomInvalidated");return!0}for(var d=this,f=this.database,
g=this.context,k,l=a.getSelection(),l=(l&&l.getRanges()).createIterator();k=l.getNextRange();){for(var v=k.getCommonAncestor();v&&(v.type!=CKEDITOR.NODE_ELEMENT||!g[v.getName()]);){if(a.editable().equals(v)){v=!1;break}v=v.getParent()}v||(v=k.startPath().contains(g))&&k.setEndAt(v,CKEDITOR.POSITION_BEFORE_END);if(!v){var y=k.getEnclosedNode();y&&y.type==CKEDITOR.NODE_ELEMENT&&y.getName()in g&&(k.setStartAt(y,CKEDITOR.POSITION_AFTER_START),k.setEndAt(y,CKEDITOR.POSITION_BEFORE_END),v=y)}v&&k.startContainer.type==
CKEDITOR.NODE_ELEMENT&&k.startContainer.getName()in g&&(y=new CKEDITOR.dom.walker(k),y.evaluator=e,k.startContainer=y.next());v&&k.endContainer.type==CKEDITOR.NODE_ELEMENT&&k.endContainer.getName()in g&&(y=new CKEDITOR.dom.walker(k),y.evaluator=e,k.endContainer=y.previous());if(v)return c(v)}return 0}function e(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.is("li")}function b(a){return d(a)&&g(a)}var d=CKEDITOR.dom.walker.whitespaces(!0),g=CKEDITOR.dom.walker.bookmark(!1,!0),l=CKEDITOR.TRISTATE_DISABLED,
k=CKEDITOR.TRISTATE_OFF;CKEDITOR.plugins.add("indentlist",{requires:"indent",init:function(b){function c(b){d.specificDefinition.apply(this,arguments);this.requiredContent=["ul","ol"];b.on("key",function(a){var c=b.elementPath();if("wysiwyg"==b.mode&&a.data.keyCode==this.indentKey&&c){var d=this.getContext(c);!d||this.isIndent&&CKEDITOR.plugins.indentList.firstItemInPath(this.context,c,d)||(b.execCommand(this.relatedGlobal),a.cancel())}},this);this.jobs[this.isIndent?10:30]={refresh:this.isIndent?
function(a,b){var c=this.getContext(b),d=CKEDITOR.plugins.indentList.firstItemInPath(this.context,b,c);return c&&this.isIndent&&!d?k:l}:function(a,b){return!this.getContext(b)||this.isIndent?l:k},exec:CKEDITOR.tools.bind(a,this)}}var d=CKEDITOR.plugins.indent;d.registerCommands(b,{indentlist:new c(b,"indentlist",!0),outdentlist:new c(b,"outdentlist")});CKEDITOR.tools.extend(c.prototype,d.specificDefinition.prototype,{context:{ol:1,ul:1}})}});CKEDITOR.plugins.indentList={};CKEDITOR.plugins.indentList.firstItemInPath=
function(a,b,d){var f=b.contains(e);d||(d=b.contains(a));return d&&f&&f.equals(d.getFirst(e))}}(),function(){function a(a,b,c){function d(c){if(!(!(m=k[c?"getFirst":"getLast"]())||m.is&&m.isBlockBoundary()||!(l=b.root[c?"getPrevious":"getNext"](CKEDITOR.dom.walker.invisible(!0)))||l.is&&l.isBlockBoundary({br:1})))a.document.createElement("br")[c?"insertBefore":"insertAfter"](m)}for(var f=CKEDITOR.plugins.list.listToArray(b.root,c),e=[],g=0;g<b.contents.length;g++){var h=b.contents[g];(h=h.getAscendant("li",
!0))&&!h.getCustomData("list_item_processed")&&(e.push(h),CKEDITOR.dom.element.setMarker(c,h,"list_item_processed",!0))}h=null;for(g=0;g<e.length;g++)h=e[g].getCustomData("listarray_index"),f[h].indent=-1;for(g=h+1;g<f.length;g++)if(f[g].indent>f[g-1].indent+1){e=f[g-1].indent+1-f[g].indent;for(h=f[g].indent;f[g]&&f[g].indent>=h;)f[g].indent+=e,g++;g--}var k=CKEDITOR.plugins.list.arrayToList(f,c,null,a.config.enterMode,b.root.getAttribute("dir")).listNode,m,l;d(!0);d();k.replace(b.root);a.fire("contentDomInvalidated")}
function e(a,b){this.name=a;this.context=this.type=b;this.allowedContent=b+" li";this.requiredContent=b}function b(a,b,c,d){for(var f,e;f=a[d?"getLast":"getFirst"](q);)(e=f.getDirection(1))!==b.getDirection(1)&&f.setAttribute("dir",e),f.remove(),c?f[d?"insertBefore":"insertAfter"](c):b.append(f,d)}function d(a){function c(d){var e=a[d?"getPrevious":"getNext"](f);e&&e.type==CKEDITOR.NODE_ELEMENT&&e.is(a.getName())&&(b(a,e,null,!d),a.remove(),a=e)}c();c(1)}function g(a){return a.type==CKEDITOR.NODE_ELEMENT&&
(a.getName()in CKEDITOR.dtd.$block||a.getName()in CKEDITOR.dtd.$listItem)&&CKEDITOR.dtd[a.getName()]["#"]}function l(a,c,e){a.fire("saveSnapshot");e.enlarge(CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS);var g=e.extractContents();c.trim(!1,!0);var h=c.createBookmark(),m=new CKEDITOR.dom.elementPath(c.startContainer),l=m.block,m=m.lastElement.getAscendant("li",1)||l,u=new CKEDITOR.dom.elementPath(e.startContainer),p=u.contains(CKEDITOR.dtd.$listItem),u=u.contains(CKEDITOR.dtd.$list);l?(l=l.getBogus())&&l.remove():
u&&(l=u.getPrevious(f))&&n(l)&&l.remove();(l=g.getLast())&&l.type==CKEDITOR.NODE_ELEMENT&&l.is("br")&&l.remove();(l=c.startContainer.getChild(c.startOffset))?g.insertBefore(l):c.startContainer.append(g);p&&(g=k(p))&&(m.contains(p)?(b(g,p.getParent(),p),g.remove()):m.append(g));for(;e.checkStartOfBlock()&&e.checkEndOfBlock();){u=e.startPath();g=u.block;if(!g)break;g.is("li")&&(m=g.getParent(),g.equals(m.getLast(f))&&g.equals(m.getFirst(f))&&(g=m));e.moveToPosition(g,CKEDITOR.POSITION_BEFORE_START);
g.remove()}e=e.clone();g=a.editable();e.setEndAt(g,CKEDITOR.POSITION_BEFORE_END);e=new CKEDITOR.dom.walker(e);e.evaluator=function(a){return f(a)&&!n(a)};(e=e.next())&&e.type==CKEDITOR.NODE_ELEMENT&&e.getName()in CKEDITOR.dtd.$list&&d(e);c.moveToBookmark(h);c.select();a.fire("saveSnapshot")}function k(a){return(a=a.getLast(f))&&a.type==CKEDITOR.NODE_ELEMENT&&a.getName()in h?a:null}var h={ol:1,ul:1},c=CKEDITOR.dom.walker.whitespaces(),m=CKEDITOR.dom.walker.bookmark(),f=function(a){return!(c(a)||m(a))},
n=CKEDITOR.dom.walker.bogus();CKEDITOR.plugins.list={listToArray:function(a,b,c,d,f){if(!h[a.getName()])return[];d||(d=0);c||(c=[]);for(var e=0,g=a.getChildCount();e<g;e++){var k=a.getChild(e);k.type==CKEDITOR.NODE_ELEMENT&&k.getName()in CKEDITOR.dtd.$list&&CKEDITOR.plugins.list.listToArray(k,b,c,d+1);if("li"==k.$.nodeName.toLowerCase()){var m={parent:a,indent:d,element:k,contents:[]};f?m.grandparent=f:(m.grandparent=a.getParent(),m.grandparent&&"li"==m.grandparent.$.nodeName.toLowerCase()&&(m.grandparent=
m.grandparent.getParent()));b&&CKEDITOR.dom.element.setMarker(b,k,"listarray_index",c.length);c.push(m);for(var l=0,n=k.getChildCount(),p;l<n;l++)p=k.getChild(l),p.type==CKEDITOR.NODE_ELEMENT&&h[p.getName()]?CKEDITOR.plugins.list.listToArray(p,b,c,d+1,m.grandparent):m.contents.push(p)}}return c},arrayToList:function(a,b,c,d,e){c||(c=0);if(!a||a.length<c+1)return null;for(var g,k=a[c].parent.getDocument(),l=new CKEDITOR.dom.documentFragment(k),n=null,z=c,B=Math.max(a[c].indent,0),p=null,q,E,J=d==CKEDITOR.ENTER_P?
"p":"div";;){var H=a[z];g=H.grandparent;q=H.element.getDirection(1);if(H.indent==B){n&&a[z].parent.getName()==n.getName()||(n=a[z].parent.clone(!1,1),e&&n.setAttribute("dir",e),l.append(n));p=n.append(H.element.clone(0,1));q!=n.getDirection(1)&&p.setAttribute("dir",q);for(g=0;g<H.contents.length;g++)p.append(H.contents[g].clone(1,1));z++}else if(H.indent==Math.max(B,0)+1)H=a[z-1].element.getDirection(1),z=CKEDITOR.plugins.list.arrayToList(a,null,z,d,H!=q?q:null),!p.getChildCount()&&CKEDITOR.env.needsNbspFiller&&
7>=k.$.documentMode&&p.append(k.createText(" ")),p.append(z.listNode),z=z.nextIndex;else if(-1==H.indent&&!c&&g){h[g.getName()]?(p=H.element.clone(!1,!0),q!=g.getDirection(1)&&p.setAttribute("dir",q)):p=new CKEDITOR.dom.documentFragment(k);var n=g.getDirection(1)!=q,M=H.element,K=M.getAttribute("class"),D=M.getAttribute("style"),R=p.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT&&(d!=CKEDITOR.ENTER_BR||n||D||K),L,S=H.contents.length,N;for(g=0;g<S;g++)if(L=H.contents[g],m(L)&&1<S)R?N=L.clone(1,1):p.append(L.clone(1,
1));else if(L.type==CKEDITOR.NODE_ELEMENT&&L.isBlockBoundary()){n&&!L.getDirection()&&L.setAttribute("dir",q);E=L;var V=M.getAttribute("style");V&&E.setAttribute("style",V.replace(/([^;])$/,"$1;")+(E.getAttribute("style")||""));K&&L.addClass(K);E=null;N&&(p.append(N),N=null);p.append(L.clone(1,1))}else R?(E||(E=k.createElement(J),p.append(E),n&&E.setAttribute("dir",q)),D&&E.setAttribute("style",D),K&&E.setAttribute("class",K),N&&(E.append(N),N=null),E.append(L.clone(1,1))):p.append(L.clone(1,1));
N&&((E||p).append(N),N=null);p.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT&&z!=a.length-1&&(CKEDITOR.env.needsBrFiller&&(q=p.getLast())&&q.type==CKEDITOR.NODE_ELEMENT&&q.is("br")&&q.remove(),(q=p.getLast(f))&&q.type==CKEDITOR.NODE_ELEMENT&&q.is(CKEDITOR.dtd.$block)||p.append(k.createElement("br")));q=p.$.nodeName.toLowerCase();"div"!=q&&"p"!=q||p.appendBogus();l.append(p);n=null;z++}else return null;E=null;if(a.length<=z||Math.max(a[z].indent,0)<B)break}if(b)for(a=l.getFirst();a;){if(a.type==CKEDITOR.NODE_ELEMENT&&
(CKEDITOR.dom.element.clearMarkers(b,a),a.getName()in CKEDITOR.dtd.$listItem&&(c=a,k=e=d=void 0,d=c.getDirection()))){for(e=c.getParent();e&&!(k=e.getDirection());)e=e.getParent();d==k&&c.removeAttribute("dir")}a=a.getNextSourceNode()}return{listNode:l,nextIndex:z}}};var p=/^h[1-6]$/,q=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_ELEMENT);e.prototype={exec:function(b){this.refresh(b,b.elementPath());var c=b.config,e=b.getSelection(),g=e&&e.getRanges();if(this.state==CKEDITOR.TRISTATE_OFF){var k=b.editable();
if(k.getFirst(f)){var m=1==g.length&&g[0];(c=m&&m.getEnclosedNode())&&c.is&&this.type==c.getName()&&this.setState(CKEDITOR.TRISTATE_ON)}else c.enterMode==CKEDITOR.ENTER_BR?k.appendBogus():g[0].fixBlock(1,c.enterMode==CKEDITOR.ENTER_P?"p":"div"),e.selectRanges(g)}for(var c=e.createBookmarks(!0),k=[],l={},g=g.createIterator(),n=0;(m=g.getNextRange())&&++n;){var q=m.getBoundaryNodes(),z=q.startNode,B=q.endNode;z.type==CKEDITOR.NODE_ELEMENT&&"td"==z.getName()&&m.setStartAt(q.startNode,CKEDITOR.POSITION_AFTER_START);
B.type==CKEDITOR.NODE_ELEMENT&&"td"==B.getName()&&m.setEndAt(q.endNode,CKEDITOR.POSITION_BEFORE_END);m=m.createIterator();for(m.forceBrBreak=this.state==CKEDITOR.TRISTATE_OFF;q=m.getNextParagraph();)if(!q.getCustomData("list_block")){CKEDITOR.dom.element.setMarker(l,q,"list_block",1);for(var G=b.elementPath(q),z=G.elements,B=0,G=G.blockLimit,F,E=z.length-1;0<=E&&(F=z[E]);E--)if(h[F.getName()]&&G.contains(F)){G.removeCustomData("list_group_object_"+n);(z=F.getCustomData("list_group_object"))?z.contents.push(q):
(z={root:F,contents:[q]},k.push(z),CKEDITOR.dom.element.setMarker(l,F,"list_group_object",z));B=1;break}B||(B=G,B.getCustomData("list_group_object_"+n)?B.getCustomData("list_group_object_"+n).contents.push(q):(z={root:B,contents:[q]},CKEDITOR.dom.element.setMarker(l,B,"list_group_object_"+n,z),k.push(z)))}}for(F=[];0<k.length;)if(z=k.shift(),this.state==CKEDITOR.TRISTATE_OFF)if(h[z.root.getName()]){g=b;n=z;z=l;m=F;B=CKEDITOR.plugins.list.listToArray(n.root,z);G=[];for(q=0;q<n.contents.length;q++)E=
n.contents[q],(E=E.getAscendant("li",!0))&&!E.getCustomData("list_item_processed")&&(G.push(E),CKEDITOR.dom.element.setMarker(z,E,"list_item_processed",!0));for(var E=n.root.getDocument(),J=void 0,H=void 0,q=0;q<G.length;q++){var M=G[q].getCustomData("listarray_index"),J=B[M].parent;J.is(this.type)||(H=E.createElement(this.type),J.copyAttributes(H,{start:1,type:1}),H.removeStyle("list-style-type"),B[M].parent=H)}z=CKEDITOR.plugins.list.arrayToList(B,z,null,g.config.enterMode);B=void 0;G=z.listNode.getChildCount();
for(q=0;q<G&&(B=z.listNode.getChild(q));q++)B.getName()==this.type&&m.push(B);z.listNode.replace(n.root);g.fire("contentDomInvalidated")}else{B=b;m=z;q=F;G=m.contents;g=m.root.getDocument();n=[];1==G.length&&G[0].equals(m.root)&&(z=g.createElement("div"),G[0].moveChildren&&G[0].moveChildren(z),G[0].append(z),G[0]=z);m=m.contents[0].getParent();for(E=0;E<G.length;E++)m=m.getCommonAncestor(G[E].getParent());J=B.config.useComputedState;B=z=void 0;J=void 0===J||J;for(E=0;E<G.length;E++)for(H=G[E];M=H.getParent();){if(M.equals(m)){n.push(H);
!B&&H.getDirection()&&(B=1);H=H.getDirection(J);null!==z&&(z=z&&z!=H?null:H);break}H=M}if(!(1>n.length)){G=n[n.length-1].getNext();E=g.createElement(this.type);q.push(E);for(J=q=void 0;n.length;)q=n.shift(),J=g.createElement("li"),H=q,H.is("pre")||p.test(H.getName())||"false"==H.getAttribute("contenteditable")?q.appendTo(J):(q.copyAttributes(J),z&&q.getDirection()&&(J.removeStyle("direction"),J.removeAttribute("dir")),q.moveChildren(J),q.remove()),J.appendTo(E);z&&B&&E.setAttribute("dir",z);G?E.insertBefore(G):
E.appendTo(m)}}else this.state==CKEDITOR.TRISTATE_ON&&h[z.root.getName()]&&a.call(this,b,z,l);for(E=0;E<F.length;E++)d(F[E]);CKEDITOR.dom.element.clearAllMarkers(l);e.selectBookmarks(c);b.focus()},refresh:function(a,b){var c=b.contains(h,1),d=b.blockLimit||b.root;c&&d.contains(c)?this.setState(c.is(this.type)?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF):this.setState(CKEDITOR.TRISTATE_OFF)}};CKEDITOR.plugins.add("list",{requires:"indentlist",init:function(a){a.blockless||(a.addCommand("numberedlist",
new e("numberedlist","ol")),a.addCommand("bulletedlist",new e("bulletedlist","ul")),a.ui.addButton&&(a.ui.addButton("NumberedList",{label:a.lang.list.numberedlist,command:"numberedlist",directional:!0,toolbar:"list,10"}),a.ui.addButton("BulletedList",{label:a.lang.list.bulletedlist,command:"bulletedlist",directional:!0,toolbar:"list,20"})),a.on("key",function(b){var c=b.data.domEvent.getKey(),d;if("wysiwyg"==a.mode&&c in{8:1,46:1}){var e=a.getSelection().getRanges()[0],m=e&&e.startPath();if(e&&e.collapsed){var p=
8==c,u=a.editable(),q=new CKEDITOR.dom.walker(e.clone());q.evaluator=function(a){return f(a)&&!n(a)};q.guard=function(a,b){return!(b&&a.type==CKEDITOR.NODE_ELEMENT&&a.is("table"))};c=e.clone();if(p){var z;(z=m.contains(h))&&e.checkBoundaryOfElement(z,CKEDITOR.START)&&(z=z.getParent())&&z.is("li")&&(z=k(z))?(d=z,z=z.getPrevious(f),c.moveToPosition(z&&n(z)?z:d,CKEDITOR.POSITION_BEFORE_START)):(q.range.setStartAt(u,CKEDITOR.POSITION_AFTER_START),q.range.setEnd(e.startContainer,e.startOffset),(z=q.previous())&&
z.type==CKEDITOR.NODE_ELEMENT&&(z.getName()in h||z.is("li"))&&(z.is("li")||(q.range.selectNodeContents(z),q.reset(),q.evaluator=g,z=q.previous()),d=z,c.moveToElementEditEnd(d),c.moveToPosition(c.endPath().block,CKEDITOR.POSITION_BEFORE_END)));if(d)l(a,c,e),b.cancel();else{var B=m.contains(h);B&&e.checkBoundaryOfElement(B,CKEDITOR.START)&&(d=B.getFirst(f),e.checkBoundaryOfElement(d,CKEDITOR.START)&&(z=B.getPrevious(f),k(d)?z&&(e.moveToElementEditEnd(z),e.select()):a.execCommand("outdent"),b.cancel()))}}else if(d=
m.contains("li")){if(q.range.setEndAt(u,CKEDITOR.POSITION_BEFORE_END),p=(u=d.getLast(f))&&g(u)?u:d,m=0,(z=q.next())&&z.type==CKEDITOR.NODE_ELEMENT&&z.getName()in h&&z.equals(u)?(m=1,z=q.next()):e.checkBoundaryOfElement(p,CKEDITOR.END)&&(m=2),m&&z){e=e.clone();e.moveToElementEditStart(z);if(1==m&&(c.optimize(),!c.startContainer.equals(d))){for(d=c.startContainer;d.is(CKEDITOR.dtd.$inline);)B=d,d=d.getParent();B&&c.moveToPosition(B,CKEDITOR.POSITION_AFTER_END)}2==m&&(c.moveToPosition(c.endPath().block,
CKEDITOR.POSITION_BEFORE_END),e.endPath().block&&e.moveToPosition(e.endPath().block,CKEDITOR.POSITION_AFTER_START));l(a,c,e);b.cancel()}}else q.range.setEndAt(u,CKEDITOR.POSITION_BEFORE_END),(z=q.next())&&z.type==CKEDITOR.NODE_ELEMENT&&z.is(h)&&(z=z.getFirst(f),m.block&&e.checkStartOfBlock()&&e.checkEndOfBlock()?(m.block.remove(),e.moveToElementEditStart(z),e.select()):k(z)?(e.moveToElementEditStart(z),e.select()):(e=e.clone(),e.moveToElementEditStart(z),l(a,c,e)),b.cancel());setTimeout(function(){a.selectionChange(1)})}}}))}})}(),
function(){function a(a,b,c){c=a.config.forceEnterMode||c;if("wysiwyg"==a.mode){b||(b=a.activeEnterMode);var d=a.elementPath();d&&!d.isContextFor("p")&&(b=CKEDITOR.ENTER_BR,c=1);a.fire("saveSnapshot");b==CKEDITOR.ENTER_BR?k(a,b,null,c):h(a,b,null,c);a.fire("saveSnapshot")}}function e(a){a=a.getSelection().getRanges(!0);for(var b=a.length-1;0<b;b--)a[b].deleteContents();return a[0]}function b(a){var b=a.startContainer.getAscendant(function(a){return a.type==CKEDITOR.NODE_ELEMENT&&"true"==a.getAttribute("contenteditable")},
!0);if(a.root.equals(b))return a;b=new CKEDITOR.dom.range(b);b.moveToRange(a);return b}CKEDITOR.plugins.add("enterkey",{init:function(b){b.addCommand("enter",{modes:{wysiwyg:1},editorFocus:!1,exec:function(b){a(b)}});b.addCommand("shiftEnter",{modes:{wysiwyg:1},editorFocus:!1,exec:function(b){a(b,b.activeShiftEnterMode,1)}});b.setKeystroke([[13,"enter"],[CKEDITOR.SHIFT+13,"shiftEnter"]])}});var d=CKEDITOR.dom.walker.whitespaces(),g=CKEDITOR.dom.walker.bookmark();CKEDITOR.plugins.enterkey={enterBlock:function(a,
f,h,l){if(h=h||e(a)){h=b(h);var q=h.document,v=h.checkStartOfBlock(),y=h.checkEndOfBlock(),r=a.elementPath(h.startContainer),t=r.block,w=f==CKEDITOR.ENTER_DIV?"div":"p",A;if(v&&y){if(t&&(t.is("li")||t.getParent().is("li"))){t.is("li")||(t=t.getParent());h=t.getParent();A=h.getParent();l=!t.hasPrevious();var x=!t.hasNext(),w=a.getSelection(),u=w.createBookmarks(),v=t.getDirection(1),y=t.getAttribute("class"),C=t.getAttribute("style"),z=A.getDirection(1)!=v;a=a.enterMode!=CKEDITOR.ENTER_BR||z||C||y;
if(A.is("li"))l||x?(l&&x&&h.remove(),t[x?"insertAfter":"insertBefore"](A)):t.breakParent(A);else{if(a)if(r.block.is("li")?(A=q.createElement(f==CKEDITOR.ENTER_P?"p":"div"),z&&A.setAttribute("dir",v),C&&A.setAttribute("style",C),y&&A.setAttribute("class",y),t.moveChildren(A)):A=r.block,l||x)A[l?"insertBefore":"insertAfter"](h);else t.breakParent(h),A.insertAfter(h);else if(t.appendBogus(!0),l||x)for(;q=t[l?"getFirst":"getLast"]();)q[l?"insertBefore":"insertAfter"](h);else for(t.breakParent(h);q=t.getLast();)q.insertAfter(h);
t.remove()}w.selectBookmarks(u);return}if(t&&t.getParent().is("blockquote")){t.breakParent(t.getParent());t.getPrevious().getFirst(CKEDITOR.dom.walker.invisible(1))||t.getPrevious().remove();t.getNext().getFirst(CKEDITOR.dom.walker.invisible(1))||t.getNext().remove();h.moveToElementEditStart(t);h.select();return}}else if(t&&t.is("pre")&&!y){k(a,f,h,l);return}if(v=h.splitBlock(w)){f=v.previousBlock;t=v.nextBlock;r=v.wasStartOfBlock;a=v.wasEndOfBlock;t?(u=t.getParent(),u.is("li")&&(t.breakParent(u),
t.move(t.getNext(),1))):f&&(u=f.getParent())&&u.is("li")&&(f.breakParent(u),u=f.getNext(),h.moveToElementEditStart(u),f.move(f.getPrevious()));if(r||a){if(f){if(f.is("li")||!c.test(f.getName())&&!f.is("pre"))A=f.clone()}else t&&(A=t.clone());A?l&&!A.is("li")&&A.renameNode(w):u&&u.is("li")?A=u:(A=q.createElement(w),f&&(x=f.getDirection())&&A.setAttribute("dir",x));if(q=v.elementPath)for(l=0,w=q.elements.length;l<w;l++){u=q.elements[l];if(u.equals(q.block)||u.equals(q.blockLimit))break;CKEDITOR.dtd.$removeEmpty[u.getName()]&&
(u=u.clone(),A.moveChildren(u),A.append(u))}A.appendBogus();A.getParent()||h.insertNode(A);A.is("li")&&A.removeAttribute("value");!CKEDITOR.env.ie||!r||a&&f.getChildCount()||(h.moveToElementEditStart(a?f:A),h.select());h.moveToElementEditStart(r&&!a?t:A)}else t.is("li")&&(A=h.clone(),A.selectNodeContents(t),A=new CKEDITOR.dom.walker(A),A.evaluator=function(a){return!(g(a)||d(a)||a.type==CKEDITOR.NODE_ELEMENT&&a.getName()in CKEDITOR.dtd.$inline&&!(a.getName()in CKEDITOR.dtd.$empty))},(u=A.next())&&
u.type==CKEDITOR.NODE_ELEMENT&&u.is("ul","ol")&&(CKEDITOR.env.needsBrFiller?q.createElement("br"):q.createText(" ")).insertBefore(u)),t&&h.moveToElementEditStart(t);h.select();h.scrollIntoView()}}},enterBr:function(a,b,d,g){if(d=d||e(a)){var k=d.document,l=d.checkEndOfBlock(),y=new CKEDITOR.dom.elementPath(a.getSelection().getStartElement()),r=y.block,t=r&&y.block.getName();g||"li"!=t?(!g&&l&&c.test(t)?(l=r.getDirection())?(k=k.createElement("div"),k.setAttribute("dir",l),k.insertAfter(r),d.setStart(k,
0)):(k.createElement("br").insertAfter(r),CKEDITOR.env.gecko&&k.createText("").insertAfter(r),d.setStartAt(r.getNext(),CKEDITOR.env.ie?CKEDITOR.POSITION_BEFORE_START:CKEDITOR.POSITION_AFTER_START)):(a="pre"==t&&CKEDITOR.env.ie&&8>CKEDITOR.env.version?k.createText("\r"):k.createElement("br"),d.deleteContents(),d.insertNode(a),CKEDITOR.env.needsBrFiller?(k.createText("").insertAfter(a),l&&(r||y.blockLimit).appendBogus(),a.getNext().$.nodeValue="",d.setStartAt(a.getNext(),CKEDITOR.POSITION_AFTER_START)):
d.setStartAt(a,CKEDITOR.POSITION_AFTER_END)),d.collapse(!0),d.select(),d.scrollIntoView()):h(a,b,d,g)}}};var l=CKEDITOR.plugins.enterkey,k=l.enterBr,h=l.enterBlock,c=/^h[1-6]$/}(),function(){function a(a,b){var d={},g=[],l={nbsp:" ",shy:"­",gt:"\x3e",lt:"\x3c",amp:"\x26",apos:"'",quot:'"'};a=a.replace(/\b(nbsp|shy|gt|lt|amp|apos|quot)(?:,|$)/g,function(a,c){var e=b?"\x26"+c+";":l[c];d[e]=b?l[c]:"\x26"+c+";";g.push(e);return""});if(!b&&a){a=a.split(",");var k=document.createElement("div"),h;k.innerHTML=
"\x26"+a.join(";\x26")+";";h=k.innerHTML;k=null;for(k=0;k<h.length;k++){var c=h.charAt(k);d[c]="\x26"+a[k]+";";g.push(c)}}d.regex=g.join(b?"|":"");return d}CKEDITOR.plugins.add("entities",{afterInit:function(e){function b(a){return c[a]}function d(a){return"force"!=g.entities_processNumerical&&k[a]?k[a]:"\x26#"+a.charCodeAt(0)+";"}var g=e.config;if(e=(e=e.dataProcessor)&&e.htmlFilter){var l=[];!1!==g.basicEntities&&l.push("nbsp,gt,lt,amp");g.entities&&(l.length&&l.push("quot,iexcl,cent,pound,curren,yen,brvbar,sect,uml,copy,ordf,laquo,not,shy,reg,macr,deg,plusmn,sup2,sup3,acute,micro,para,middot,cedil,sup1,ordm,raquo,frac14,frac12,frac34,iquest,times,divide,fnof,bull,hellip,prime,Prime,oline,frasl,weierp,image,real,trade,alefsym,larr,uarr,rarr,darr,harr,crarr,lArr,uArr,rArr,dArr,hArr,forall,part,exist,empty,nabla,isin,notin,ni,prod,sum,minus,lowast,radic,prop,infin,ang,and,or,cap,cup,int,there4,sim,cong,asymp,ne,equiv,le,ge,sub,sup,nsub,sube,supe,oplus,otimes,perp,sdot,lceil,rceil,lfloor,rfloor,lang,rang,loz,spades,clubs,hearts,diams,circ,tilde,ensp,emsp,thinsp,zwnj,zwj,lrm,rlm,ndash,mdash,lsquo,rsquo,sbquo,ldquo,rdquo,bdquo,dagger,Dagger,permil,lsaquo,rsaquo,euro"),
g.entities_latin&&l.push("Agrave,Aacute,Acirc,Atilde,Auml,Aring,AElig,Ccedil,Egrave,Eacute,Ecirc,Euml,Igrave,Iacute,Icirc,Iuml,ETH,Ntilde,Ograve,Oacute,Ocirc,Otilde,Ouml,Oslash,Ugrave,Uacute,Ucirc,Uuml,Yacute,THORN,szlig,agrave,aacute,acirc,atilde,auml,aring,aelig,ccedil,egrave,eacute,ecirc,euml,igrave,iacute,icirc,iuml,eth,ntilde,ograve,oacute,ocirc,otilde,ouml,oslash,ugrave,uacute,ucirc,uuml,yacute,thorn,yuml,OElig,oelig,Scaron,scaron,Yuml"),g.entities_greek&&l.push("Alpha,Beta,Gamma,Delta,Epsilon,Zeta,Eta,Theta,Iota,Kappa,Lambda,Mu,Nu,Xi,Omicron,Pi,Rho,Sigma,Tau,Upsilon,Phi,Chi,Psi,Omega,alpha,beta,gamma,delta,epsilon,zeta,eta,theta,iota,kappa,lambda,mu,nu,xi,omicron,pi,rho,sigmaf,sigma,tau,upsilon,phi,chi,psi,omega,thetasym,upsih,piv"),
g.entities_additional&&l.push(g.entities_additional));var k=a(l.join(",")),h=k.regex?"["+k.regex+"]":"a^";delete k.regex;g.entities&&g.entities_processNumerical&&(h="[^ -~]|"+h);var h=new RegExp(h,"g"),c=a("nbsp,gt,lt,amp,shy",!0),m=new RegExp(c.regex,"g");e.addRules({text:function(a){return a.replace(m,b).replace(h,d)}},{applyToAll:!0,excludeNestedEditable:!0})}}})}(),CKEDITOR.config.basicEntities=!0,CKEDITOR.config.entities=!0,CKEDITOR.config.entities_latin=!0,CKEDITOR.config.entities_greek=!0,
CKEDITOR.config.entities_additional="#39",CKEDITOR.plugins.add("popup"),CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{popup:function(a,e,b,d){e=e||"80%";b=b||"70%";"string"==typeof e&&1<e.length&&"%"==e.substr(e.length-1,1)&&(e=parseInt(window.screen.width*parseInt(e,10)/100,10));"string"==typeof b&&1<b.length&&"%"==b.substr(b.length-1,1)&&(b=parseInt(window.screen.height*parseInt(b,10)/100,10));640>e&&(e=640);420>b&&(b=420);var g=parseInt((window.screen.height-b)/2,10),l=parseInt((window.screen.width-
e)/2,10);d=(d||"location\x3dno,menubar\x3dno,toolbar\x3dno,dependent\x3dyes,minimizable\x3dno,modal\x3dyes,alwaysRaised\x3dyes,resizable\x3dyes,scrollbars\x3dyes")+",width\x3d"+e+",height\x3d"+b+",top\x3d"+g+",left\x3d"+l;var k=window.open("",null,d,!0);if(!k)return!1;try{-1==navigator.userAgent.toLowerCase().indexOf(" chrome/")&&(k.moveTo(l,g),k.resizeTo(e,b)),k.focus(),k.location.href=a}catch(h){window.open(a,null,d,!0)}return!0}}),function(){function a(a,b){var d=[];if(b)for(var e in b)d.push(e+
"\x3d"+encodeURIComponent(b[e]));else return a;return a+(-1!=a.indexOf("?")?"\x26":"?")+d.join("\x26")}function e(a){a+="";return a.charAt(0).toUpperCase()+a.substr(1)}function b(){var b=this.getDialog(),d=b.getParentEditor();d._.filebrowserSe=this;var f=d.config["filebrowser"+e(b.getName())+"WindowWidth"]||d.config.filebrowserWindowWidth||"80%",b=d.config["filebrowser"+e(b.getName())+"WindowHeight"]||d.config.filebrowserWindowHeight||"70%",g=this.filebrowser.params||{};g.CKEditor=d.name;g.CKEditorFuncNum=
d._.filebrowserFn;g.langCode||(g.langCode=d.langCode);g=a(this.filebrowser.url,g);d.popup(g,f,b,d.config.filebrowserWindowFeatures||d.config.fileBrowserWindowFeatures)}function d(){var a=this.getDialog();a.getParentEditor()._.filebrowserSe=this;return a.getContentElement(this["for"][0],this["for"][1]).getInputElement().$.value&&a.getContentElement(this["for"][0],this["for"][1]).getAction()?!0:!1}function g(b,d,e){var g=e.params||{};g.CKEditor=b.name;g.CKEditorFuncNum=b._.filebrowserFn;g.langCode||
(g.langCode=b.langCode);d.action=a(e.url,g);d.filebrowser=e}function l(a,h,f,k){if(k&&k.length)for(var p,q=k.length;q--;)if(p=k[q],"hbox"!=p.type&&"vbox"!=p.type&&"fieldset"!=p.type||l(a,h,f,p.children),p.filebrowser)if("string"==typeof p.filebrowser&&(p.filebrowser={action:"fileButton"==p.type?"QuickUpload":"Browse",target:p.filebrowser}),"Browse"==p.filebrowser.action){var v=p.filebrowser.url;void 0===v&&(v=a.config["filebrowser"+e(h)+"BrowseUrl"],void 0===v&&(v=a.config.filebrowserBrowseUrl));
v&&(p.onClick=b,p.filebrowser.url=v,p.hidden=!1)}else if("QuickUpload"==p.filebrowser.action&&p["for"]&&(v=p.filebrowser.url,void 0===v&&(v=a.config["filebrowser"+e(h)+"UploadUrl"],void 0===v&&(v=a.config.filebrowserUploadUrl)),v)){var y=p.onClick;p.onClick=function(a){var b=a.sender;if(y&&!1===y.call(b,a))return!1;if(d.call(b,a)){a=b.getDialog().getContentElement(this["for"][0],this["for"][1]).getInputElement();if(b=new CKEDITOR.dom.element(a.$.form))(a=b.$.elements.ckCsrfToken)?a=new CKEDITOR.dom.element(a):
(a=new CKEDITOR.dom.element("input"),a.setAttributes({name:"ckCsrfToken",type:"hidden"}),b.append(a)),a.setAttribute("value",CKEDITOR.tools.getCsrfToken());return!0}return!1};p.filebrowser.url=v;p.hidden=!1;g(a,f.getContents(p["for"][0]).get(p["for"][1]),p.filebrowser)}}function k(a,b,d){if(-1!==d.indexOf(";")){d=d.split(";");for(var e=0;e<d.length;e++)if(k(a,b,d[e]))return!0;return!1}return(a=a.getContents(b).get(d).filebrowser)&&a.url}function h(a,b){var d=this._.filebrowserSe.getDialog(),e=this._.filebrowserSe["for"],
g=this._.filebrowserSe.filebrowser.onSelect;e&&d.getContentElement(e[0],e[1]).reset();if("function"!=typeof b||!1!==b.call(this._.filebrowserSe))if(!g||!1!==g.call(this._.filebrowserSe,a,b))if("string"==typeof b&&b&&alert(b),a&&(e=this._.filebrowserSe,d=e.getDialog(),e=e.filebrowser.target||null))if(e=e.split(":"),g=d.getContentElement(e[0],e[1]))g.setValue(a),d.selectPage(e[0])}CKEDITOR.plugins.add("filebrowser",{requires:"popup",init:function(a){a._.filebrowserFn=CKEDITOR.tools.addFunction(h,a);
a.on("destroy",function(){CKEDITOR.tools.removeFunction(this._.filebrowserFn)})}});CKEDITOR.on("dialogDefinition",function(a){if(a.editor.plugins.filebrowser)for(var b=a.data.definition,d,e=0;e<b.contents.length;++e)if(d=b.contents[e])l(a.editor,a.data.name,b,d.elements),d.hidden&&d.filebrowser&&(d.hidden=!k(b,d.id,d.filebrowser))})}(),function(){function a(a){var g=a.config,l=a.fire("uiSpace",{space:"top",html:""}).html,k=function(){function f(a,d,e){c.setStyle(d,b(e));c.setStyle("position",a)}function h(a){var b=
m.getDocumentPosition();switch(a){case "top":f("absolute","top",b.y-w-u);break;case "pin":f("fixed","top",z);break;case "bottom":f("absolute","top",b.y+(r.height||r.bottom-r.top)+u)}l=a}var l,m,y,r,t,w,A,x=g.floatSpaceDockedOffsetX||0,u=g.floatSpaceDockedOffsetY||0,C=g.floatSpacePinnedOffsetX||0,z=g.floatSpacePinnedOffsetY||0;return function(f){if(m=a.editable()){var n=f&&"focus"==f.name;n&&c.show();a.fire("floatingSpaceLayout",{show:n});c.removeStyle("left");c.removeStyle("right");y=c.getClientRect();
r=m.getClientRect();t=e.getViewPaneSize();w=y.height;A="pageXOffset"in e.$?e.$.pageXOffset:CKEDITOR.document.$.documentElement.scrollLeft;l?(w+u<=r.top?h("top"):w+u>t.height-r.bottom?h("pin"):h("bottom"),f=t.width/2,f=g.floatSpacePreferRight?"right":0<r.left&&r.right<t.width&&r.width>y.width?"rtl"==g.contentsLangDirection?"right":"left":f-r.left>r.right-f?"left":"right",y.width>t.width?(f="left",n=0):(n="left"==f?0<r.left?r.left:0:r.right<t.width?t.width-r.right:0,n+y.width>t.width&&(f="left"==f?
"right":"left",n=0)),c.setStyle(f,b(("pin"==l?C:x)+n+("pin"==l?0:"left"==f?A:-A)))):(l="pin",h("pin"),k(f))}}}();if(l){var h=new CKEDITOR.template('\x3cdiv id\x3d"cke_{name}" class\x3d"cke {id} cke_reset_all cke_chrome cke_editor_{name} cke_float cke_{langDir} '+CKEDITOR.env.cssClass+'" dir\x3d"{langDir}" title\x3d"'+(CKEDITOR.env.gecko?" ":"")+'" lang\x3d"{langCode}" role\x3d"application" style\x3d"{style}"'+(a.title?' aria-labelledby\x3d"cke_{name}_arialbl"':" ")+"\x3e"+(a.title?'\x3cspan id\x3d"cke_{name}_arialbl" class\x3d"cke_voice_label"\x3e{voiceLabel}\x3c/span\x3e':
" ")+'\x3cdiv class\x3d"cke_inner"\x3e\x3cdiv id\x3d"{topId}" class\x3d"cke_top" role\x3d"presentation"\x3e{content}\x3c/div\x3e\x3c/div\x3e\x3c/div\x3e'),c=CKEDITOR.document.getBody().append(CKEDITOR.dom.element.createFromHtml(h.output({content:l,id:a.id,langDir:a.lang.dir,langCode:a.langCode,name:a.name,style:"display:none;z-index:"+(g.baseFloatZIndex-1),topId:a.ui.spaceId("top"),voiceLabel:a.title}))),m=CKEDITOR.tools.eventsBuffer(500,k),f=CKEDITOR.tools.eventsBuffer(100,k);c.unselectable();c.on("mousedown",
function(a){a=a.data;a.getTarget().hasAscendant("a",1)||a.preventDefault()});a.on("focus",function(b){k(b);a.on("change",m.input);e.on("scroll",f.input);e.on("resize",f.input)});a.on("blur",function(){c.hide();a.removeListener("change",m.input);e.removeListener("scroll",f.input);e.removeListener("resize",f.input)});a.on("destroy",function(){e.removeListener("scroll",f.input);e.removeListener("resize",f.input);c.clearCustomData();c.remove()});a.focusManager.hasFocus&&c.show();a.focusManager.add(c,
1)}}var e=CKEDITOR.document.getWindow(),b=CKEDITOR.tools.cssLength;CKEDITOR.plugins.add("floatingspace",{init:function(b){b.on("loaded",function(){a(this)},null,null,20)}})}(),CKEDITOR.plugins.add("listblock",{requires:"panel",onLoad:function(){var a=CKEDITOR.addTemplate("panel-list",'\x3cul role\x3d"presentation" class\x3d"cke_panel_list"\x3e{items}\x3c/ul\x3e'),e=CKEDITOR.addTemplate("panel-list-item",'\x3cli id\x3d"{id}" class\x3d"cke_panel_listItem" role\x3dpresentation\x3e\x3ca id\x3d"{id}_option" _cke_focus\x3d1 hidefocus\x3dtrue title\x3d"{title}" href\x3d"javascript:void(\'{val}\')" {onclick}\x3d"CKEDITOR.tools.callFunction({clickFn},\'{val}\'); return false;" role\x3d"option"\x3e{text}\x3c/a\x3e\x3c/li\x3e'),
b=CKEDITOR.addTemplate("panel-list-group",'\x3ch1 id\x3d"{id}" class\x3d"cke_panel_grouptitle" role\x3d"presentation" \x3e{label}\x3c/h1\x3e'),d=/\'/g;CKEDITOR.ui.panel.prototype.addListBlock=function(a,b){return this.addBlock(a,new CKEDITOR.ui.listBlock(this.getHolderElement(),b))};CKEDITOR.ui.listBlock=CKEDITOR.tools.createClass({base:CKEDITOR.ui.panel.block,$:function(a,b){b=b||{};var d=b.attributes||(b.attributes={});(this.multiSelect=!!b.multiSelect)&&(d["aria-multiselectable"]=!0);!d.role&&
(d.role="listbox");this.base.apply(this,arguments);this.element.setAttribute("role",d.role);d=this.keys;d[40]="next";d[9]="next";d[38]="prev";d[CKEDITOR.SHIFT+9]="prev";d[32]=CKEDITOR.env.ie?"mouseup":"click";CKEDITOR.env.ie&&(d[13]="mouseup");this._.pendingHtml=[];this._.pendingList=[];this._.items={};this._.groups={}},_:{close:function(){if(this._.started){var b=a.output({items:this._.pendingList.join("")});this._.pendingList=[];this._.pendingHtml.push(b);delete this._.started}},getClick:function(){this._.click||
(this._.click=CKEDITOR.tools.addFunction(function(a){var b=this.toggle(a);if(this.onClick)this.onClick(a,b)},this));return this._.click}},proto:{add:function(a,b,k){var h=CKEDITOR.tools.getNextId();this._.started||(this._.started=1,this._.size=this._.size||0);this._.items[a]=h;var c;c=CKEDITOR.tools.htmlEncodeAttr(a).replace(d,"\\'");a={id:h,val:c,onclick:CKEDITOR.env.ie?'onclick\x3d"return false;" onmouseup':"onclick",clickFn:this._.getClick(),title:CKEDITOR.tools.htmlEncodeAttr(k||a),text:b||a};
this._.pendingList.push(e.output(a))},startGroup:function(a){this._.close();var d=CKEDITOR.tools.getNextId();this._.groups[a]=d;this._.pendingHtml.push(b.output({id:d,label:a}))},commit:function(){this._.close();this.element.appendHtml(this._.pendingHtml.join(""));delete this._.size;this._.pendingHtml=[]},toggle:function(a){var b=this.isMarked(a);b?this.unmark(a):this.mark(a);return!b},hideGroup:function(a){var b=(a=this.element.getDocument().getById(this._.groups[a]))&&a.getNext();a&&(a.setStyle("display",
"none"),b&&"ul"==b.getName()&&b.setStyle("display","none"))},hideItem:function(a){this.element.getDocument().getById(this._.items[a]).setStyle("display","none")},showAll:function(){var a=this._.items,b=this._.groups,d=this.element.getDocument(),e;for(e in a)d.getById(a[e]).setStyle("display","");for(var c in b)a=d.getById(b[c]),e=a.getNext(),a.setStyle("display",""),e&&"ul"==e.getName()&&e.setStyle("display","")},mark:function(a){this.multiSelect||this.unmarkAll();a=this._.items[a];var b=this.element.getDocument().getById(a);
b.addClass("cke_selected");this.element.getDocument().getById(a+"_option").setAttribute("aria-selected",!0);this.onMark&&this.onMark(b)},markFirstDisplayed:function(){var a=this;this._.markFirstDisplayed(function(){a.multiSelect||a.unmarkAll()})},unmark:function(a){var b=this.element.getDocument();a=this._.items[a];var d=b.getById(a);d.removeClass("cke_selected");b.getById(a+"_option").removeAttribute("aria-selected");this.onUnmark&&this.onUnmark(d)},unmarkAll:function(){var a=this._.items,b=this.element.getDocument(),
d;for(d in a){var e=a[d];b.getById(e).removeClass("cke_selected");b.getById(e+"_option").removeAttribute("aria-selected")}this.onUnmark&&this.onUnmark()},isMarked:function(a){return this.element.getDocument().getById(this._.items[a]).hasClass("cke_selected")},focus:function(a){this._.focusIndex=-1;var b=this.element.getElementsByTag("a"),d,e=-1;if(a)for(d=this.element.getDocument().getById(this._.items[a]).getFirst();a=b.getItem(++e);){if(a.equals(d)){this._.focusIndex=e;break}}else this.element.focus();
d&&setTimeout(function(){d.focus()},0)}}})}}),CKEDITOR.plugins.add("richcombo",{requires:"floatpanel,listblock,button",beforeInit:function(a){a.ui.addHandler(CKEDITOR.UI_RICHCOMBO,CKEDITOR.ui.richCombo.handler)}}),function(){var a='\x3cspan id\x3d"{id}" class\x3d"cke_combo cke_combo__{name} {cls}" role\x3d"presentation"\x3e\x3cspan id\x3d"{id}_label" class\x3d"cke_combo_label"\x3e{label}\x3c/span\x3e\x3ca class\x3d"cke_combo_button" title\x3d"{title}" tabindex\x3d"-1"'+(CKEDITOR.env.gecko&&!CKEDITOR.env.hc?
"":" href\x3d\"javascript:void('{titleJs}')\"")+' hidefocus\x3d"true" role\x3d"button" aria-labelledby\x3d"{id}_label" aria-haspopup\x3d"true"';CKEDITOR.env.gecko&&CKEDITOR.env.mac&&(a+=' onkeypress\x3d"return false;"');CKEDITOR.env.gecko&&(a+=' onblur\x3d"this.style.cssText \x3d this.style.cssText;"');var a=a+(' onkeydown\x3d"return CKEDITOR.tools.callFunction({keydownFn},event,this);" onfocus\x3d"return CKEDITOR.tools.callFunction({focusFn},event);" '+(CKEDITOR.env.ie?'onclick\x3d"return false;" onmouseup':
"onclick")+'\x3d"CKEDITOR.tools.callFunction({clickFn},this);return false;"\x3e\x3cspan id\x3d"{id}_text" class\x3d"cke_combo_text cke_combo_inlinelabel"\x3e{label}\x3c/span\x3e\x3cspan class\x3d"cke_combo_open"\x3e\x3cspan class\x3d"cke_combo_arrow"\x3e'+(CKEDITOR.env.hc?"\x26#9660;":CKEDITOR.env.air?"\x26nbsp;":"")+"\x3c/span\x3e\x3c/span\x3e\x3c/a\x3e\x3c/span\x3e"),e=CKEDITOR.addTemplate("combo",a);CKEDITOR.UI_RICHCOMBO="richcombo";CKEDITOR.ui.richCombo=CKEDITOR.tools.createClass({$:function(a){CKEDITOR.tools.extend(this,
a,{canGroup:!1,title:a.label,modes:{wysiwyg:1},editorFocus:1});a=this.panel||{};delete this.panel;this.id=CKEDITOR.tools.getNextNumber();this.document=a.parent&&a.parent.getDocument()||CKEDITOR.document;a.className="cke_combopanel";a.block={multiSelect:a.multiSelect,attributes:a.attributes};a.toolbarRelated=!0;this._={panelDefinition:a,items:{}}},proto:{renderHtml:function(a){var d=[];this.render(a,d);return d.join("")},render:function(a,d){function g(){if(this.getState()!=CKEDITOR.TRISTATE_ON){var c=
this.modes[a.mode]?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED;a.readOnly&&!this.readOnly&&(c=CKEDITOR.TRISTATE_DISABLED);this.setState(c);this.setValue("");c!=CKEDITOR.TRISTATE_DISABLED&&this.refresh&&this.refresh()}}var l=CKEDITOR.env,k="cke_"+this.id,h=CKEDITOR.tools.addFunction(function(c){p&&(a.unlockSelection(1),p=0);m.execute(c)},this),c=this,m={id:k,combo:this,focus:function(){CKEDITOR.document.getById(k).getChild(1).focus()},execute:function(d){var e=c._;if(e.state!=CKEDITOR.TRISTATE_DISABLED)if(c.createPanel(a),
e.on)e.panel.hide();else{c.commit();var f=c.getValue();f?e.list.mark(f):e.list.unmarkAll();e.panel.showBlock(c.id,new CKEDITOR.dom.element(d),4)}},clickFn:h};a.on("activeFilterChange",g,this);a.on("mode",g,this);a.on("selectionChange",g,this);!this.readOnly&&a.on("readOnly",g,this);var f=CKEDITOR.tools.addFunction(function(a,b){a=new CKEDITOR.dom.event(a);var c=a.getKeystroke();switch(c){case 13:case 32:case 40:CKEDITOR.tools.callFunction(h,b);break;default:m.onkey(m,c)}a.preventDefault()}),n=CKEDITOR.tools.addFunction(function(){m.onfocus&&
m.onfocus()}),p=0;m.keyDownFn=f;l={id:k,name:this.name||this.command,label:this.label,title:this.title,cls:this.className||"",titleJs:l.gecko&&!l.hc?"":(this.title||"").replace("'",""),keydownFn:f,focusFn:n,clickFn:h};e.output(l,d);if(this.onRender)this.onRender();return m},createPanel:function(a){if(!this._.panel){var d=this._.panelDefinition,e=this._.panelDefinition.block,l=d.parent||CKEDITOR.document.getBody(),k="cke_combopanel__"+this.name,h=new CKEDITOR.ui.floatPanel(a,l,d),d=h.addListBlock(this.id,
e),c=this;h.onShow=function(){this.element.addClass(k);c.setState(CKEDITOR.TRISTATE_ON);c._.on=1;c.editorFocus&&!a.focusManager.hasFocus&&a.focus();if(c.onOpen)c.onOpen()};h.onHide=function(d){this.element.removeClass(k);c.setState(c.modes&&c.modes[a.mode]?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED);c._.on=0;if(!d&&c.onClose)c.onClose()};h.onEscape=function(){h.hide(1)};d.onClick=function(a,b){c.onClick&&c.onClick.call(c,a,b);h.hide()};this._.panel=h;this._.list=d;h.getBlock(this.id).onHide=
function(){c._.on=0;c.setState(CKEDITOR.TRISTATE_OFF)};this.init&&this.init()}},setValue:function(a,d){this._.value=a;var e=this.document.getById("cke_"+this.id+"_text");e&&(a||d?e.removeClass("cke_combo_inlinelabel"):(d=this.label,e.addClass("cke_combo_inlinelabel")),e.setText("undefined"!=typeof d?d:a))},getValue:function(){return this._.value||""},unmarkAll:function(){this._.list.unmarkAll()},mark:function(a){this._.list.mark(a)},hideItem:function(a){this._.list.hideItem(a)},hideGroup:function(a){this._.list.hideGroup(a)},
showAll:function(){this._.list.showAll()},add:function(a,d,e){this._.items[a]=e||a;this._.list.add(a,d,e)},startGroup:function(a){this._.list.startGroup(a)},commit:function(){this._.committed||(this._.list.commit(),this._.committed=1,CKEDITOR.ui.fire("ready",this));this._.committed=1},setState:function(a){if(this._.state!=a){var d=this.document.getById("cke_"+this.id);d.setState(a,"cke_combo");a==CKEDITOR.TRISTATE_DISABLED?d.setAttribute("aria-disabled",!0):d.removeAttribute("aria-disabled");this._.state=
a}},getState:function(){return this._.state},enable:function(){this._.state==CKEDITOR.TRISTATE_DISABLED&&this.setState(this._.lastState)},disable:function(){this._.state!=CKEDITOR.TRISTATE_DISABLED&&(this._.lastState=this._.state,this.setState(CKEDITOR.TRISTATE_DISABLED))}},statics:{handler:{create:function(a){return new CKEDITOR.ui.richCombo(a)}}}});CKEDITOR.ui.prototype.addRichCombo=function(a,d){this.add(a,CKEDITOR.UI_RICHCOMBO,d)}}(),CKEDITOR.plugins.add("format",{requires:"richcombo",init:function(a){if(!a.blockless){for(var e=
a.config,b=a.lang.format,d=e.format_tags.split(";"),g={},l=0,k=[],h=0;h<d.length;h++){var c=d[h],m=new CKEDITOR.style(e["format_"+c]);if(!a.filter.customConfig||a.filter.check(m))l++,g[c]=m,g[c]._.enterMode=a.config.enterMode,k.push(m)}0!==l&&a.ui.addRichCombo("Format",{label:b.label,title:b.panelTitle,toolbar:"styles,20",allowedContent:k,panel:{css:[CKEDITOR.skin.getPath("editor")].concat(e.contentsCss),multiSelect:!1,attributes:{"aria-label":b.panelTitle}},init:function(){this.startGroup(b.panelTitle);
for(var a in g){var c=b["tag_"+a];this.add(a,g[a].buildPreview(c),c)}},onClick:function(b){a.focus();a.fire("saveSnapshot");b=g[b];var c=a.elementPath();b.checkActive(c,a)||a.applyStyle(b);setTimeout(function(){a.fire("saveSnapshot")},0)},onRender:function(){a.on("selectionChange",function(b){var c=this.getValue();b=b.data.path;this.refresh();for(var d in g)if(g[d].checkActive(b,a)){d!=c&&this.setValue(d,a.lang.format["tag_"+d]);return}this.setValue("")},this)},onOpen:function(){this.showAll();for(var b in g)a.activeFilter.check(g[b])||
this.hideItem(b)},refresh:function(){var b=a.elementPath();if(b){if(b.isContextFor("p"))for(var c in g)if(a.activeFilter.check(g[c]))return;this.setState(CKEDITOR.TRISTATE_DISABLED)}}})}}}),CKEDITOR.config.format_tags="p;h1;h2;h3;h4;h5;h6;pre;address;div",CKEDITOR.config.format_p={element:"p"},CKEDITOR.config.format_div={element:"div"},CKEDITOR.config.format_pre={element:"pre"},CKEDITOR.config.format_address={element:"address"},CKEDITOR.config.format_h1={element:"h1"},CKEDITOR.config.format_h2={element:"h2"},
CKEDITOR.config.format_h3={element:"h3"},CKEDITOR.config.format_h4={element:"h4"},CKEDITOR.config.format_h5={element:"h5"},CKEDITOR.config.format_h6={element:"h6"},function(){var a={canUndo:!1,exec:function(a){var b=a.document.createElement("hr");a.insertElement(b)},allowedContent:"hr",requiredContent:"hr"};CKEDITOR.plugins.add("horizontalrule",{init:function(e){e.blockless||(e.addCommand("horizontalrule",a),e.ui.addButton&&e.ui.addButton("HorizontalRule",{label:e.lang.horizontalrule.toolbar,command:"horizontalrule",
toolbar:"insert,40"}))}})}(),CKEDITOR.plugins.add("htmlwriter",{init:function(a){var e=new CKEDITOR.htmlWriter;e.forceSimpleAmpersand=a.config.forceSimpleAmpersand;e.indentationChars=a.config.dataIndentationChars||"\t";a.dataProcessor.writer=e}}),CKEDITOR.htmlWriter=CKEDITOR.tools.createClass({base:CKEDITOR.htmlParser.basicWriter,$:function(){this.base();this.indentationChars="\t";this.selfClosingEnd=" /\x3e";this.lineBreakChars="\n";this.sortAttributes=1;this._.indent=0;this._.indentation="";this._.inPre=
0;this._.rules={};var a=CKEDITOR.dtd,e;for(e in CKEDITOR.tools.extend({},a.$nonBodyContent,a.$block,a.$listItem,a.$tableContent))this.setRules(e,{indent:!a[e]["#"],breakBeforeOpen:1,breakBeforeClose:!a[e]["#"],breakAfterClose:1,needsSpace:e in a.$block&&!(e in{li:1,dt:1,dd:1})});this.setRules("br",{breakAfterOpen:1});this.setRules("title",{indent:0,breakAfterOpen:0});this.setRules("style",{indent:0,breakBeforeClose:1});this.setRules("pre",{breakAfterOpen:1,indent:0})},proto:{openTag:function(a){var e=
this._.rules[a];this._.afterCloser&&e&&e.needsSpace&&this._.needsSpace&&this._.output.push("\n");this._.indent?this.indentation():e&&e.breakBeforeOpen&&(this.lineBreak(),this.indentation());this._.output.push("\x3c",a);this._.afterCloser=0},openTagClose:function(a,e){var b=this._.rules[a];e?(this._.output.push(this.selfClosingEnd),b&&b.breakAfterClose&&(this._.needsSpace=b.needsSpace)):(this._.output.push("\x3e"),b&&b.indent&&(this._.indentation+=this.indentationChars));b&&b.breakAfterOpen&&this.lineBreak();
"pre"==a&&(this._.inPre=1)},attribute:function(a,e){"string"==typeof e&&(this.forceSimpleAmpersand&&(e=e.replace(/&amp;/g,"\x26")),e=CKEDITOR.tools.htmlEncodeAttr(e));this._.output.push(" ",a,'\x3d"',e,'"')},closeTag:function(a){var e=this._.rules[a];e&&e.indent&&(this._.indentation=this._.indentation.substr(this.indentationChars.length));this._.indent?this.indentation():e&&e.breakBeforeClose&&(this.lineBreak(),this.indentation());this._.output.push("\x3c/",a,"\x3e");"pre"==a&&(this._.inPre=0);e&&
e.breakAfterClose&&(this.lineBreak(),this._.needsSpace=e.needsSpace);this._.afterCloser=1},text:function(a){this._.indent&&(this.indentation(),!this._.inPre&&(a=CKEDITOR.tools.ltrim(a)));this._.output.push(a)},comment:function(a){this._.indent&&this.indentation();this._.output.push("\x3c!--",a,"--\x3e")},lineBreak:function(){!this._.inPre&&0<this._.output.length&&this._.output.push(this.lineBreakChars);this._.indent=1},indentation:function(){!this._.inPre&&this._.indentation&&this._.output.push(this._.indentation);
this._.indent=0},reset:function(){this._.output=[];this._.indent=0;this._.indentation="";this._.afterCloser=0;this._.inPre=0;this._.needsSpace=0},setRules:function(a,e){var b=this._.rules[a];b?CKEDITOR.tools.extend(b,e,!0):this._.rules[a]=e}}}),function(){function a(a,d){d||(d=a.getSelection().getSelectedElement());if(d&&d.is("img")&&!d.data("cke-realelement")&&!d.isReadOnly())return d}function e(a){var d=a.getStyle("float");if("inherit"==d||"none"==d)d=0;d||(d=a.getAttribute("align"));return d}CKEDITOR.plugins.add("image",
{requires:"dialog",init:function(b){if(!b.plugins.image2){CKEDITOR.dialog.add("image",this.path+"dialogs/image.js");var d="img[alt,!src]{border-style,border-width,float,height,margin,margin-bottom,margin-left,margin-right,margin-top,width}";CKEDITOR.dialog.isTabEnabled(b,"image","advanced")&&(d="img[alt,dir,id,lang,longdesc,!src,title]{*}(*)");b.addCommand("image",new CKEDITOR.dialogCommand("image",{allowedContent:d,requiredContent:"img[alt,src]",contentTransformations:[["img{width}: sizeToStyle",
"img[width]: sizeToAttribute"],["img{float}: alignmentToStyle","img[align]: alignmentToAttribute"]]}));b.ui.addButton&&b.ui.addButton("Image",{label:b.lang.common.image,command:"image",toolbar:"insert,10"});b.on("doubleclick",function(a){var b=a.data.element;!b.is("img")||b.data("cke-realelement")||b.isReadOnly()||(a.data.dialog="image")});b.addMenuItems&&b.addMenuItems({image:{label:b.lang.image.menu,command:"image",group:"image"}});b.contextMenu&&b.contextMenu.addListener(function(d){if(a(b,d))return{image:CKEDITOR.TRISTATE_OFF}})}},
afterInit:function(b){function d(d){var l=b.getCommand("justify"+d);if(l){if("left"==d||"right"==d)l.on("exec",function(k){var h=a(b),c;h&&(c=e(h),c==d?(h.removeStyle("float"),d==e(h)&&h.removeAttribute("align")):h.setStyle("float",d),k.cancel())});l.on("refresh",function(k){var h=a(b);h&&(h=e(h),this.setState(h==d?CKEDITOR.TRISTATE_ON:"right"==d||"left"==d?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED),k.cancel())})}}b.plugins.image2||(d("left"),d("right"),d("center"),d("block"))}})}(),CKEDITOR.config.image_removeLinkByEmptyURL=
!0,function(){function a(a,b){var e=d.exec(a),c=d.exec(b);if(e){if(!e[2]&&"px"==c[2])return c[1];if("px"==e[2]&&!c[2])return c[1]+"px"}return b}var e=CKEDITOR.htmlParser.cssStyle,b=CKEDITOR.tools.cssLength,d=/^((?:\d*(?:\.\d+))|(?:\d+))(.*)?$/i,g={elements:{$:function(b){var d=b.attributes;if((d=(d=(d=d&&d["data-cke-realelement"])&&new CKEDITOR.htmlParser.fragment.fromHtml(decodeURIComponent(d)))&&d.children[0])&&b.attributes["data-cke-resizable"]){var g=(new e(b)).rules;b=d.attributes;var c=g.width,
g=g.height;c&&(b.width=a(b.width,c));g&&(b.height=a(b.height,g))}return d}}};CKEDITOR.plugins.add("fakeobjects",{init:function(a){a.filter.allow("img[!data-cke-realelement,src,alt,title](*){*}","fakeobjects")},afterInit:function(a){(a=(a=a.dataProcessor)&&a.htmlFilter)&&a.addRules(g,{applyToAll:!0})}});CKEDITOR.editor.prototype.createFakeElement=function(a,d,g,c){var m=this.lang.fakeobjects,m=m[g]||m.unknown;d={"class":d,"data-cke-realelement":encodeURIComponent(a.getOuterHtml()),"data-cke-real-node-type":a.type,
alt:m,title:m,align:a.getAttribute("align")||""};CKEDITOR.env.hc||(d.src=CKEDITOR.tools.transparentImageData);g&&(d["data-cke-real-element-type"]=g);c&&(d["data-cke-resizable"]=c,g=new e,c=a.getAttribute("width"),a=a.getAttribute("height"),c&&(g.rules.width=b(c)),a&&(g.rules.height=b(a)),g.populate(d));return this.document.createElement("img",{attributes:d})};CKEDITOR.editor.prototype.createFakeParserElement=function(a,d,g,c){var m=this.lang.fakeobjects,m=m[g]||m.unknown,f;f=new CKEDITOR.htmlParser.basicWriter;
a.writeHtml(f);f=f.getHtml();d={"class":d,"data-cke-realelement":encodeURIComponent(f),"data-cke-real-node-type":a.type,alt:m,title:m,align:a.attributes.align||""};CKEDITOR.env.hc||(d.src=CKEDITOR.tools.transparentImageData);g&&(d["data-cke-real-element-type"]=g);c&&(d["data-cke-resizable"]=c,c=a.attributes,a=new e,g=c.width,c=c.height,void 0!==g&&(a.rules.width=b(g)),void 0!==c&&(a.rules.height=b(c)),a.populate(d));return new CKEDITOR.htmlParser.element("img",d)};CKEDITOR.editor.prototype.restoreRealElement=
function(b){if(b.data("cke-real-node-type")!=CKEDITOR.NODE_ELEMENT)return null;var d=CKEDITOR.dom.element.createFromHtml(decodeURIComponent(b.data("cke-realelement")),this.document);if(b.data("cke-resizable")){var e=b.getStyle("width");b=b.getStyle("height");e&&d.setAttribute("width",a(d.getAttribute("width"),e));b&&d.setAttribute("height",a(d.getAttribute("height"),b))}return d}}(),"use strict",function(){function a(a){return a.replace(/'/g,"\\$\x26")}function e(a){for(var b,c=a.length,d=[],e=0;e<
c;e++)b=a.charCodeAt(e),d.push(b);return"String.fromCharCode("+d.join(",")+")"}function b(b,c){var d=b.plugins.link,e=d.compiledProtectionFunction.params,f,g;g=[d.compiledProtectionFunction.name,"("];for(var h=0;h<e.length;h++)d=e[h].toLowerCase(),f=c[d],0<h&&g.push(","),g.push("'",f?a(encodeURIComponent(c[d])):"","'");g.push(")");return g.join("")}function d(a){a=a.config.emailProtection||"";var b;a&&"encode"!=a&&(b={},a.replace(/^([^(]+)\(([^)]+)\)$/,function(a,c,d){b.name=c;b.params=[];d.replace(/[^,\s]+/g,
function(a){b.params.push(a)})}));return b}CKEDITOR.plugins.add("link",{requires:"dialog,fakeobjects",onLoad:function(){function a(b){return c.replace(/%1/g,"rtl"==b?"right":"left").replace(/%2/g,"cke_contents_"+b)}var b="background:url("+CKEDITOR.getUrl(this.path+"images"+(CKEDITOR.env.hidpi?"/hidpi":"")+"/anchor.png")+") no-repeat %1 center;border:1px dotted #00f;background-size:16px;",c=".%2 a.cke_anchor,.%2 a.cke_anchor_empty,.cke_editable.%2 a[name],.cke_editable.%2 a[data-cke-saved-name]{"+
b+"padding-%1:18px;cursor:auto;}.%2 img.cke_anchor{"+b+"width:16px;min-height:15px;height:1.15em;vertical-align:text-bottom;}";CKEDITOR.addCss(a("ltr")+a("rtl"))},init:function(a){var b="a[!href]";CKEDITOR.dialog.isTabEnabled(a,"link","advanced")&&(b=b.replace("]",",accesskey,charset,dir,id,lang,name,rel,tabindex,title,type,download]{*}(*)"));CKEDITOR.dialog.isTabEnabled(a,"link","target")&&(b=b.replace("]",",target,onclick]"));a.addCommand("link",new CKEDITOR.dialogCommand("link",{allowedContent:b,
requiredContent:"a[href]"}));a.addCommand("anchor",new CKEDITOR.dialogCommand("anchor",{allowedContent:"a[!name,id]",requiredContent:"a[name]"}));a.addCommand("unlink",new CKEDITOR.unlinkCommand);a.addCommand("removeAnchor",new CKEDITOR.removeAnchorCommand);a.setKeystroke(CKEDITOR.CTRL+76,"link");a.ui.addButton&&(a.ui.addButton("Link",{label:a.lang.link.toolbar,command:"link",toolbar:"links,10"}),a.ui.addButton("Unlink",{label:a.lang.link.unlink,command:"unlink",toolbar:"links,20"}),a.ui.addButton("Anchor",
{label:a.lang.link.anchor.toolbar,command:"anchor",toolbar:"links,30"}));CKEDITOR.dialog.add("link",this.path+"dialogs/link.js");CKEDITOR.dialog.add("anchor",this.path+"dialogs/anchor.js");a.on("doubleclick",function(b){var c=b.data.element.getAscendant({a:1,img:1},!0);c&&!c.isReadOnly()&&(c.is("a")?(b.data.dialog=!c.getAttribute("name")||c.getAttribute("href")&&c.getChildCount()?"link":"anchor",b.data.link=c):CKEDITOR.plugins.link.tryRestoreFakeAnchor(a,c)&&(b.data.dialog="anchor"))},null,null,0);
a.on("doubleclick",function(b){b.data.dialog in{link:1,anchor:1}&&b.data.link&&a.getSelection().selectElement(b.data.link)},null,null,20);a.addMenuItems&&a.addMenuItems({anchor:{label:a.lang.link.anchor.menu,command:"anchor",group:"anchor",order:1},removeAnchor:{label:a.lang.link.anchor.remove,command:"removeAnchor",group:"anchor",order:5},link:{label:a.lang.link.menu,command:"link",group:"link",order:1},unlink:{label:a.lang.link.unlink,command:"unlink",group:"link",order:5}});a.contextMenu&&a.contextMenu.addListener(function(b){if(!b||
b.isReadOnly())return null;b=CKEDITOR.plugins.link.tryRestoreFakeAnchor(a,b);if(!b&&!(b=CKEDITOR.plugins.link.getSelectedLink(a)))return null;var c={};b.getAttribute("href")&&b.getChildCount()&&(c={link:CKEDITOR.TRISTATE_OFF,unlink:CKEDITOR.TRISTATE_OFF});b&&b.hasAttribute("name")&&(c.anchor=c.removeAnchor=CKEDITOR.TRISTATE_OFF);return c});this.compiledProtectionFunction=d(a)},afterInit:function(a){a.dataProcessor.dataFilter.addRules({elements:{a:function(b){return b.attributes.name?b.children.length?
null:a.createFakeParserElement(b,"cke_anchor","anchor"):null}}});var b=a._.elementsPath&&a._.elementsPath.filters;b&&b.push(function(b,c){if("a"==c&&(CKEDITOR.plugins.link.tryRestoreFakeAnchor(a,b)||b.getAttribute("name")&&(!b.getAttribute("href")||!b.getChildCount())))return"anchor"})}});var g=/^javascript:/,l=/^mailto:([^?]+)(?:\?(.+))?$/,k=/subject=([^;?:@&=$,\/]*)/i,h=/body=([^;?:@&=$,\/]*)/i,c=/^#(.*)$/,m=/^((?:http|https|ftp|news):\/\/)?(.*)$/,f=/^(_(?:self|top|parent|blank))$/,n=/^javascript:void\(location\.href='mailto:'\+String\.fromCharCode\(([^)]+)\)(?:\+'(.*)')?\)$/,
p=/^javascript:([^(]+)\(([^)]+)\)$/,q=/\s*window.open\(\s*this\.href\s*,\s*(?:'([^']*)'|null)\s*,\s*'([^']*)'\s*\)\s*;\s*return\s*false;*\s*/,v=/(?:^|,)([^=]+)=(\d+|yes|no)/gi,y={id:"advId",dir:"advLangDir",accessKey:"advAccessKey",name:"advName",lang:"advLangCode",tabindex:"advTabIndex",title:"advTitle",type:"advContentType","class":"advCSSClasses",charset:"advCharset",style:"advStyles",rel:"advRel"};CKEDITOR.plugins.link={getSelectedLink:function(a,b){var c=a.getSelection(),d=c.getSelectedElement(),
e=c.getRanges(),f=[],g;if(!b&&d&&d.is("a"))return d;for(d=0;d<e.length;d++)if(g=c.getRanges()[d],g.shrink(CKEDITOR.SHRINK_TEXT,!1,{skipBogus:!0}),(g=a.elementPath(g.getCommonAncestor()).contains("a",1))&&b)f.push(g);else if(g)return g;return b?f:null},getEditorAnchors:function(a){for(var b=a.editable(),c=b.isInline()&&!a.plugins.divarea?a.document:b,b=c.getElementsByTag("a"),c=c.getElementsByTag("img"),d=[],e=0,f;f=b.getItem(e++);)(f.data("cke-saved-name")||f.hasAttribute("name"))&&d.push({name:f.data("cke-saved-name")||
f.getAttribute("name"),id:f.getAttribute("id")});for(e=0;f=c.getItem(e++);)(f=this.tryRestoreFakeAnchor(a,f))&&d.push({name:f.getAttribute("name"),id:f.getAttribute("id")});return d},fakeAnchor:!0,tryRestoreFakeAnchor:function(a,b){if(b&&b.data("cke-real-element-type")&&"anchor"==b.data("cke-real-element-type")){var c=a.restoreRealElement(b);if(c.data("cke-saved-name"))return c}},parseLinkAttributes:function(a,b){var d=b&&(b.data("cke-saved-href")||b.getAttribute("href"))||"",e=a.plugins.link.compiledProtectionFunction,
x=a.config.emailProtection,u,C={};d.match(g)&&("encode"==x?d=d.replace(n,function(a,b,c){c=c||"";return"mailto:"+String.fromCharCode.apply(String,b.split(","))+c.replace(/\\'/g,"'")}):x&&d.replace(p,function(a,b,c){if(b==e.name){C.type="email";a=C.email={};b=/(^')|('$)/g;c=c.match(/[^,\s]+/g);for(var d=c.length,f,g,h=0;h<d;h++)f=decodeURIComponent,g=c[h].replace(b,"").replace(/\\'/g,"'"),g=f(g),f=e.params[h].toLowerCase(),a[f]=g;a.address=[a.name,a.domain].join("@")}}));if(!C.type)if(x=d.match(c))C.type=
"anchor",C.anchor={},C.anchor.name=C.anchor.id=x[1];else if(x=d.match(l)){u=d.match(k);d=d.match(h);C.type="email";var z=C.email={};z.address=x[1];u&&(z.subject=decodeURIComponent(u[1]));d&&(z.body=decodeURIComponent(d[1]))}else d&&(u=d.match(m))&&(C.type="url",C.url={},C.url.protocol=u[1],C.url.url=u[2]);if(b){if(d=b.getAttribute("target"))C.target={type:d.match(f)?d:"frame",name:d};else if(d=(d=b.data("cke-pa-onclick")||b.getAttribute("onclick"))&&d.match(q))for(C.target={type:"popup",name:d[1]};x=
v.exec(d[2]);)"yes"!=x[2]&&"1"!=x[2]||x[1]in{height:1,width:1,top:1,left:1}?isFinite(x[2])&&(C.target[x[1]]=x[2]):C.target[x[1]]=!0;null!==b.getAttribute("download")&&(C.download=!0);var d={},B;for(B in y)(x=b.getAttribute(B))&&(d[y[B]]=x);if(B=b.data("cke-saved-name")||d.advName)d.advName=B;CKEDITOR.tools.isEmpty(d)||(C.advanced=d)}return C},getLinkAttributes:function(c,d){var f=c.config.emailProtection||"",g={};switch(d.type){case "url":var f=d.url&&void 0!==d.url.protocol?d.url.protocol:"http://",
h=d.url&&CKEDITOR.tools.trim(d.url.url)||"";g["data-cke-saved-href"]=0===h.indexOf("/")?h:f+h;break;case "anchor":f=d.anchor&&d.anchor.id;g["data-cke-saved-href"]="#"+(d.anchor&&d.anchor.name||f||"");break;case "email":var k=d.email,h=k.address;switch(f){case "":case "encode":var m=encodeURIComponent(k.subject||""),l=encodeURIComponent(k.body||""),k=[];m&&k.push("subject\x3d"+m);l&&k.push("body\x3d"+l);k=k.length?"?"+k.join("\x26"):"";"encode"==f?(f=["javascript:void(location.href\x3d'mailto:'+",
e(h)],k&&f.push("+'",a(k),"'"),f.push(")")):f=["mailto:",h,k];break;default:f=h.split("@",2),k.name=f[0],k.domain=f[1],f=["javascript:",b(c,k)]}g["data-cke-saved-href"]=f.join("")}if(d.target)if("popup"==d.target.type){for(var f=["window.open(this.href, '",d.target.name||"","', '"],n="resizable status location toolbar menubar fullscreen scrollbars dependent".split(" "),h=n.length,m=function(a){d.target[a]&&n.push(a+"\x3d"+d.target[a])},k=0;k<h;k++)n[k]+=d.target[n[k]]?"\x3dyes":"\x3dno";m("width");
m("left");m("height");m("top");f.push(n.join(","),"'); return false;");g["data-cke-pa-onclick"]=f.join("")}else"notSet"!=d.target.type&&d.target.name&&(g.target=d.target.name);d.download&&(g.download="");if(d.advanced){for(var p in y)(f=d.advanced[y[p]])&&(g[p]=f);g.name&&(g["data-cke-saved-name"]=g.name)}g["data-cke-saved-href"]&&(g.href=g["data-cke-saved-href"]);p={target:1,onclick:1,"data-cke-pa-onclick":1,"data-cke-saved-name":1,download:1};d.advanced&&CKEDITOR.tools.extend(p,y);for(var q in g)delete p[q];
return{set:g,removed:CKEDITOR.tools.objectKeys(p)}},showDisplayTextForElement:function(a,b){var c={img:1,table:1,tbody:1,thead:1,tfoot:1,input:1,select:1,textarea:1},d=b.getSelection();return b.widgets&&b.widgets.focused||d&&1<d.getRanges().length?!1:!a||!a.getName||!a.is(c)}};CKEDITOR.unlinkCommand=function(){};CKEDITOR.unlinkCommand.prototype={exec:function(a){if(CKEDITOR.env.ie){var b=a.getSelection().getRanges()[0],c=b.getPreviousEditableNode()&&b.getPreviousEditableNode().getAscendant("a",!0)||
b.getNextEditableNode()&&b.getNextEditableNode().getAscendant("a",!0),d;b.collapsed&&c&&(d=b.createBookmark(),b.selectNodeContents(c),b.select())}c=new CKEDITOR.style({element:"a",type:CKEDITOR.STYLE_INLINE,alwaysRemoveElement:1});a.removeStyle(c);d&&(b.moveToBookmark(d),b.select())},refresh:function(a,b){var c=b.lastElement&&b.lastElement.getAscendant("a",!0);c&&"a"==c.getName()&&c.getAttribute("href")&&c.getChildCount()?this.setState(CKEDITOR.TRISTATE_OFF):this.setState(CKEDITOR.TRISTATE_DISABLED)},
contextSensitive:1,startDisabled:1,requiredContent:"a[href]",editorFocus:1};CKEDITOR.removeAnchorCommand=function(){};CKEDITOR.removeAnchorCommand.prototype={exec:function(a){var b=a.getSelection(),c=b.createBookmarks(),d;if(b&&(d=b.getSelectedElement())&&(d.getChildCount()?d.is("a"):CKEDITOR.plugins.link.tryRestoreFakeAnchor(a,d)))d.remove(1);else if(d=CKEDITOR.plugins.link.getSelectedLink(a))d.hasAttribute("href")?(d.removeAttributes({name:1,"data-cke-saved-name":1}),d.removeClass("cke_anchor")):
d.remove(1);b.selectBookmarks(c)},requiredContent:"a[name]"};CKEDITOR.tools.extend(CKEDITOR.config,{linkShowAdvancedTab:!0,linkShowTargetTab:!0})}(),"use strict",function(){function a(a,b,c){return n(b)&&n(c)&&c.equals(b.getNext(function(a){return!(aa(a)||ba(a)||p(a))}))}function e(a){this.upper=a[0];this.lower=a[1];this.set.apply(this,a.slice(2))}function b(a){var b=a.element;if(b&&n(b)&&(b=b.getAscendant(a.triggers,!0))&&a.editable.contains(b)){var c=k(b);if("true"==c.getAttribute("contenteditable"))return b;
if(c.is(a.triggers))return c}return null}function d(a,b,c){x(a,b);x(a,c);a=b.size.bottom;c=c.size.top;return a&&c?0|(a+c)/2:a||c}function g(a,b,c){return b=b[c?"getPrevious":"getNext"](function(b){return b&&b.type==CKEDITOR.NODE_TEXT&&!aa(b)||n(b)&&!p(b)&&!f(a,b)})}function l(a,b,c){return a>b&&a<c}function k(a,b){if(a.data("cke-editable"))return null;for(b||(a=a.getParent());a&&!a.data("cke-editable");){if(a.hasAttribute("contenteditable"))return a;a=a.getParent()}return null}function h(a){var b=
a.doc,d=F('\x3cspan contenteditable\x3d"false" style\x3d"'+U+"position:absolute;border-top:1px dashed "+a.boxColor+'"\x3e\x3c/span\x3e',b),e=CKEDITOR.getUrl(this.path+"images/"+(E.hidpi?"hidpi/":"")+"icon"+(a.rtl?"-rtl":"")+".png");B(d,{attach:function(){this.wrap.getParent()||this.wrap.appendTo(a.editable,!0);return this},lineChildren:[B(F('\x3cspan title\x3d"'+a.editor.lang.magicline.title+'" contenteditable\x3d"false"\x3e\x26#8629;\x3c/span\x3e',b),{base:U+"height:17px;width:17px;"+(a.rtl?"left":
"right")+":17px;background:url("+e+") center no-repeat "+a.boxColor+";cursor:pointer;"+(E.hc?"font-size: 15px;line-height:14px;border:1px solid #fff;text-align:center;":"")+(E.hidpi?"background-size: 9px 10px;":""),looks:["top:-8px; border-radius: 2px;","top:-17px; border-radius: 2px 2px 0px 0px;","top:-1px; border-radius: 0px 0px 2px 2px;"]}),B(F(I,b),{base:T+"left:0px;border-left-color:"+a.boxColor+";",looks:["border-width:8px 0 8px 8px;top:-8px","border-width:8px 0 0 8px;top:-8px","border-width:0 0 8px 8px;top:0px"]}),
B(F(I,b),{base:T+"right:0px;border-right-color:"+a.boxColor+";",looks:["border-width:8px 8px 8px 0;top:-8px","border-width:8px 8px 0 0;top:-8px","border-width:0 8px 8px 0;top:0px"]})],detach:function(){this.wrap.getParent()&&this.wrap.remove();return this},mouseNear:function(){x(a,this);var b=a.holdDistance,c=this.size;return c&&l(a.mouse.y,c.top-b,c.bottom+b)&&l(a.mouse.x,c.left-b,c.right+b)?!0:!1},place:function(){var b=a.view,c=a.editable,d=a.trigger,e=d.upper,f=d.lower,g=e||f,h=g.getParent(),
k={};this.trigger=d;e&&x(a,e,!0);f&&x(a,f,!0);x(a,h,!0);a.inInlineMode&&u(a,!0);h.equals(c)?(k.left=b.scroll.x,k.right=-b.scroll.x,k.width=""):(k.left=g.size.left-g.size.margin.left+b.scroll.x-(a.inInlineMode?b.editable.left+b.editable.border.left:0),k.width=g.size.outerWidth+g.size.margin.left+g.size.margin.right+b.scroll.x,k.right="");e&&f?k.top=e.size.margin.bottom===f.size.margin.top?0|e.size.bottom+e.size.margin.bottom/2:e.size.margin.bottom<f.size.margin.top?e.size.bottom+e.size.margin.bottom:
e.size.bottom+e.size.margin.bottom-f.size.margin.top:e?f||(k.top=e.size.bottom+e.size.margin.bottom):k.top=f.size.top-f.size.margin.top;d.is(S)||l(k.top,b.scroll.y-15,b.scroll.y+5)?(k.top=a.inInlineMode?0:b.scroll.y,this.look(S)):d.is(N)||l(k.top,b.pane.bottom-5,b.pane.bottom+15)?(k.top=a.inInlineMode?b.editable.height+b.editable.padding.top+b.editable.padding.bottom:b.pane.bottom-1,this.look(N)):(a.inInlineMode&&(k.top-=b.editable.top+b.editable.border.top),this.look(V));a.inInlineMode&&(k.top--,
k.top+=b.editable.scroll.top,k.left+=b.editable.scroll.left);for(var m in k)k[m]=CKEDITOR.tools.cssLength(k[m]);this.setStyles(k)},look:function(a){if(this.oldLook!=a){for(var b=this.lineChildren.length,c;b--;)(c=this.lineChildren[b]).setAttribute("style",c.base+c.looks[0|a/2]);this.oldLook=a}},wrap:new G("span",a.doc)});for(b=d.lineChildren.length;b--;)d.lineChildren[b].appendTo(d);d.look(V);d.appendTo(d.wrap);d.unselectable();d.lineChildren[0].on("mouseup",function(b){d.detach();c(a,function(b){var c=
a.line.trigger;b[c.is(K)?"insertBefore":"insertAfter"](c.is(K)?c.lower:c.upper)},!0);a.editor.focus();E.ie||a.enterMode==CKEDITOR.ENTER_BR||a.hotNode.scrollIntoView();b.data.preventDefault(!0)});d.on("mousedown",function(a){a.data.preventDefault(!0)});a.line=d}function c(a,b,c){var d=new CKEDITOR.dom.range(a.doc),e=a.editor,f;E.ie&&a.enterMode==CKEDITOR.ENTER_BR?f=a.doc.createText(Z):(f=(f=k(a.element,!0))&&f.data("cke-enter-mode")||a.enterMode,f=new G(M[f],a.doc),f.is("br")||a.doc.createText(Z).appendTo(f));
c&&e.fire("saveSnapshot");b(f);d.moveToPosition(f,CKEDITOR.POSITION_AFTER_START);e.getSelection().selectRanges([d]);a.hotNode=f;c&&e.fire("saveSnapshot")}function m(a,d){return{canUndo:!0,modes:{wysiwyg:1},exec:function(){function e(b){var f=E.ie&&9>E.version?" ":Z,g=a.hotNode&&a.hotNode.getText()==f&&a.element.equals(a.hotNode)&&a.lastCmdDirection===!!d;c(a,function(c){g&&a.hotNode&&a.hotNode.remove();c[d?"insertAfter":"insertBefore"](b);c.setAttributes({"data-cke-magicline-hot":1,"data-cke-magicline-dir":!!d});
a.lastCmdDirection=!!d});E.ie||a.enterMode==CKEDITOR.ENTER_BR||a.hotNode.scrollIntoView();a.line.detach()}return function(c){c=c.getSelection().getStartElement();var f;c=c.getAscendant(Q,1);if(!y(a,c)&&c&&!c.equals(a.editable)&&!c.contains(a.editable)){(f=k(c))&&"false"==f.getAttribute("contenteditable")&&(c=f);a.element=c;f=g(a,c,!d);var h;n(f)&&f.is(a.triggers)&&f.is(P)&&(!g(a,f,!d)||(h=g(a,f,!d))&&n(h)&&h.is(a.triggers))?e(f):(h=b(a,c),n(h)&&(g(a,h,!d)?(c=g(a,h,!d))&&n(c)&&c.is(a.triggers)&&e(h):
e(h)))}}}()}}function f(a,b){if(!b||b.type!=CKEDITOR.NODE_ELEMENT||!b.$)return!1;var c=a.line;return c.wrap.equals(b)||c.wrap.contains(b)}function n(a){return a&&a.type==CKEDITOR.NODE_ELEMENT&&a.$}function p(a){if(!n(a))return!1;var b;(b=q(a))||(n(a)?(b={left:1,right:1,center:1},b=!(!b[a.getComputedStyle("float")]&&!b[a.getAttribute("align")])):b=!1);return b}function q(a){return!!{absolute:1,fixed:1}[a.getComputedStyle("position")]}function v(a,b){return n(b)?b.is(a.triggers):null}function y(a,b){if(!b)return!1;
for(var c=b.getParents(1),d=c.length;d--;)for(var e=a.tabuList.length;e--;)if(c[d].hasAttribute(a.tabuList[e]))return!0;return!1}function r(a,b,c){b=b[c?"getLast":"getFirst"](function(b){return a.isRelevant(b)&&!b.is(da)});if(!b)return!1;x(a,b);return c?b.size.top>a.mouse.y:b.size.bottom<a.mouse.y}function t(a){var b=a.editable,c=a.mouse,d=a.view,g=a.triggerOffset;u(a);var h=c.y>(a.inInlineMode?d.editable.top+d.editable.height/2:Math.min(d.editable.height,d.pane.height)/2),b=b[h?"getLast":"getFirst"](function(a){return!(aa(a)||
ba(a))});if(!b)return null;f(a,b)&&(b=a.line.wrap[h?"getPrevious":"getNext"](function(a){return!(aa(a)||ba(a))}));if(!n(b)||p(b)||!v(a,b))return null;x(a,b);return!h&&0<=b.size.top&&l(c.y,0,b.size.top+g)?(a=a.inInlineMode||0===d.scroll.y?S:V,new e([null,b,K,L,a])):h&&b.size.bottom<=d.pane.height&&l(c.y,b.size.bottom-g,d.pane.height)?(a=a.inInlineMode||l(b.size.bottom,d.pane.height-g,d.pane.height)?N:V,new e([b,null,D,L,a])):null}function w(a){var c=a.mouse,d=a.view,f=a.triggerOffset,h=b(a);if(!h)return null;
x(a,h);var f=Math.min(f,0|h.size.outerHeight/2),k=[],m,I;if(l(c.y,h.size.top-1,h.size.top+f))I=!1;else if(l(c.y,h.size.bottom-f,h.size.bottom+1))I=!0;else return null;if(p(h)||r(a,h,I)||h.getParent().is(X))return null;var z=g(a,h,!I);if(z){if(z&&z.type==CKEDITOR.NODE_TEXT)return null;if(n(z)){if(p(z)||!v(a,z)||z.getParent().is(X))return null;k=[z,h][I?"reverse":"concat"]().concat([R,L])}}else h.equals(a.editable[I?"getLast":"getFirst"](a.isRelevant))?(u(a),I&&l(c.y,h.size.bottom-f,d.pane.height)&&
l(h.size.bottom,d.pane.height-f,d.pane.height)?m=N:l(c.y,0,h.size.top+f)&&(m=S)):m=V,k=[null,h][I?"reverse":"concat"]().concat([I?D:K,L,m,h.equals(a.editable[I?"getLast":"getFirst"](a.isRelevant))?I?N:S:V]);return 0 in k?new e(k):null}function A(a,b,c,d){for(var e=b.getDocumentPosition(),f={},g={},h={},k={},m=ca.length;m--;)f[ca[m]]=parseInt(b.getComputedStyle.call(b,"border-"+ca[m]+"-width"),10)||0,h[ca[m]]=parseInt(b.getComputedStyle.call(b,"padding-"+ca[m]),10)||0,g[ca[m]]=parseInt(b.getComputedStyle.call(b,
"margin-"+ca[m]),10)||0;c&&!d||C(a,d);k.top=e.y-(c?0:a.view.scroll.y);k.left=e.x-(c?0:a.view.scroll.x);k.outerWidth=b.$.offsetWidth;k.outerHeight=b.$.offsetHeight;k.height=k.outerHeight-(h.top+h.bottom+f.top+f.bottom);k.width=k.outerWidth-(h.left+h.right+f.left+f.right);k.bottom=k.top+k.outerHeight;k.right=k.left+k.outerWidth;a.inInlineMode&&(k.scroll={top:b.$.scrollTop,left:b.$.scrollLeft});return B({border:f,padding:h,margin:g,ignoreScroll:c},k,!0)}function x(a,b,c){if(!n(b))return b.size=null;
if(!b.size)b.size={};else if(b.size.ignoreScroll==c&&b.size.date>new Date-O)return null;return B(b.size,A(a,b,c),{date:+new Date},!0)}function u(a,b){a.view.editable=A(a,a.editable,b,!0)}function C(a,b){a.view||(a.view={});var c=a.view;if(!(!b&&c&&c.date>new Date-O)){var d=a.win,c=d.getScrollPosition(),d=d.getViewPaneSize();B(a.view,{scroll:{x:c.x,y:c.y,width:a.doc.$.documentElement.scrollWidth-d.width,height:a.doc.$.documentElement.scrollHeight-d.height},pane:{width:d.width,height:d.height,bottom:d.height+
c.y},date:+new Date},!0)}}function z(a,b,c,d){for(var f=d,g=d,h=0,k=!1,m=!1,l=a.view.pane.height,n=a.mouse;n.y+h<l&&0<n.y-h;){k||(k=b(f,d));m||(m=b(g,d));!k&&0<n.y-h&&(f=c(a,{x:n.x,y:n.y-h}));!m&&n.y+h<l&&(g=c(a,{x:n.x,y:n.y+h}));if(k&&m)break;h+=2}return new e([f,g,null,null])}CKEDITOR.plugins.add("magicline",{init:function(a){var d=a.config,k=d.magicline_triggerOffset||30,l={editor:a,enterMode:d.enterMode,triggerOffset:k,holdDistance:0|k*(d.magicline_holdDistance||.5),boxColor:d.magicline_color||
"#ff0000",rtl:"rtl"==d.contentsLangDirection,tabuList:["data-cke-hidden-sel"].concat(d.magicline_tabuList||[]),triggers:d.magicline_everywhere?Q:{table:1,hr:1,div:1,ul:1,ol:1,dl:1,form:1,blockquote:1}},I,z,r;l.isRelevant=function(a){return n(a)&&!f(l,a)&&!p(a)};a.on("contentDom",function(){var k=a.editable(),n=a.document,p=a.window;B(l,{editable:k,inInlineMode:k.isInline(),doc:n,win:p,hotNode:null},!0);l.boundary=l.inInlineMode?l.editable:l.doc.getDocumentElement();k.is(H.$inline)||(l.inInlineMode&&
!q(k)&&k.setStyles({position:"relative",top:null,left:null}),h.call(this,l),C(l),k.attachListener(a,"beforeUndoImage",function(){l.line.detach()}),k.attachListener(a,"beforeGetData",function(){l.line.wrap.getParent()&&(l.line.detach(),a.once("getData",function(){l.line.attach()},null,null,1E3))},null,null,0),k.attachListener(l.inInlineMode?n:n.getWindow().getFrame(),"mouseout",function(b){if("wysiwyg"==a.mode)if(l.inInlineMode){var c=b.data.$.clientX;b=b.data.$.clientY;C(l);u(l,!0);var d=l.view.editable,
e=l.view.scroll;c>d.left-e.x&&c<d.right-e.x&&b>d.top-e.y&&b<d.bottom-e.y||(clearTimeout(r),r=null,l.line.detach())}else clearTimeout(r),r=null,l.line.detach()}),k.attachListener(k,"keyup",function(){l.hiddenMode=0}),k.attachListener(k,"keydown",function(b){if("wysiwyg"==a.mode)switch(b.data.getKeystroke()){case 2228240:case 16:l.hiddenMode=1,l.line.detach()}}),k.attachListener(l.inInlineMode?k:n,"mousemove",function(b){z=!0;if("wysiwyg"==a.mode&&!a.readOnly&&!r){var c={x:b.data.$.clientX,y:b.data.$.clientY};
r=setTimeout(function(){l.mouse=c;r=l.trigger=null;C(l);z&&!l.hiddenMode&&a.focusManager.hasFocus&&!l.line.mouseNear()&&(l.element=W(l,!0))&&((l.trigger=t(l)||w(l)||Y(l))&&!y(l,l.trigger.upper||l.trigger.lower)?l.line.attach().place():(l.trigger=null,l.line.detach()),z=!1)},30)}}),k.attachListener(p,"scroll",function(){"wysiwyg"==a.mode&&(l.line.detach(),E.webkit&&(l.hiddenMode=1,clearTimeout(I),I=setTimeout(function(){l.mouseDown||(l.hiddenMode=0)},50)))}),k.attachListener(J?n:p,"mousedown",function(){"wysiwyg"==
a.mode&&(l.line.detach(),l.hiddenMode=1,l.mouseDown=1)}),k.attachListener(J?n:p,"mouseup",function(){l.hiddenMode=0;l.mouseDown=0}),a.addCommand("accessPreviousSpace",m(l)),a.addCommand("accessNextSpace",m(l,!0)),a.setKeystroke([[d.magicline_keystrokePrevious,"accessPreviousSpace"],[d.magicline_keystrokeNext,"accessNextSpace"]]),a.on("loadSnapshot",function(){var b,c,d,e;for(e in{p:1,br:1,div:1})for(b=a.document.getElementsByTag(e),d=b.count();d--;)if((c=b.getItem(d)).data("cke-magicline-hot")){l.hotNode=
c;l.lastCmdDirection="true"===c.data("cke-magicline-dir")?!0:!1;return}}),this.backdoor={accessFocusSpace:c,boxTrigger:e,isLine:f,getAscendantTrigger:b,getNonEmptyNeighbour:g,getSize:A,that:l,triggerEdge:w,triggerEditable:t,triggerExpand:Y})},this)}});var B=CKEDITOR.tools.extend,G=CKEDITOR.dom.element,F=G.createFromHtml,E=CKEDITOR.env,J=CKEDITOR.env.ie&&9>CKEDITOR.env.version,H=CKEDITOR.dtd,M={},K=128,D=64,R=32,L=16,S=4,N=2,V=1,Z=" ",X=H.$listItem,da=H.$tableContent,P=B({},H.$nonEditable,H.$empty),
Q=H.$block,O=100,U="width:0px;height:0px;padding:0px;margin:0px;display:block;z-index:9999;color:#fff;position:absolute;font-size: 0px;line-height:0px;",T=U+"border-color:transparent;display:block;border-style:solid;",I="\x3cspan\x3e"+Z+"\x3c/span\x3e";M[CKEDITOR.ENTER_BR]="br";M[CKEDITOR.ENTER_P]="p";M[CKEDITOR.ENTER_DIV]="div";e.prototype={set:function(a,b,c){this.properties=a+b+(c||V);return this},is:function(a){return(this.properties&a)==a}};var W=function(){function a(b,c){var d=b.$.elementFromPoint(c.x,
c.y);return d&&d.nodeType?new CKEDITOR.dom.element(d):null}return function(b,c,d){if(!b.mouse)return null;var e=b.doc,g=b.line.wrap;d=d||b.mouse;var h=a(e,d);c&&f(b,h)&&(g.hide(),h=a(e,d),g.show());return!h||h.type!=CKEDITOR.NODE_ELEMENT||!h.$||E.ie&&9>E.version&&!b.boundary.equals(h)&&!b.boundary.contains(h)?null:h}}(),aa=CKEDITOR.dom.walker.whitespaces(),ba=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_COMMENT),Y=function(){function b(e){var f=e.element,g,h,k;if(!n(f)||f.contains(e.editable)||f.isReadOnly())return null;
k=z(e,function(a,b){return!b.equals(a)},function(a,b){return W(a,!0,b)},f);g=k.upper;h=k.lower;if(a(e,g,h))return k.set(R,8);if(g&&f.contains(g))for(;!g.getParent().equals(f);)g=g.getParent();else g=f.getFirst(function(a){return c(e,a)});if(h&&f.contains(h))for(;!h.getParent().equals(f);)h=h.getParent();else h=f.getLast(function(a){return c(e,a)});if(!g||!h)return null;x(e,g);x(e,h);if(!l(e.mouse.y,g.size.top,h.size.bottom))return null;for(var f=Number.MAX_VALUE,m,I,u,r;h&&!h.equals(g)&&(I=g.getNext(e.isRelevant));)m=
Math.abs(d(e,g,I)-e.mouse.y),m<f&&(f=m,u=g,r=I),g=I,x(e,g);if(!u||!r||!l(e.mouse.y,u.size.top,r.size.bottom))return null;k.upper=u;k.lower=r;return k.set(R,8)}function c(a,b){return!(b&&b.type==CKEDITOR.NODE_TEXT||ba(b)||p(b)||f(a,b)||b.type==CKEDITOR.NODE_ELEMENT&&b.$&&b.is("br"))}return function(c){var d=b(c),e;if(e=d){e=d.upper;var f=d.lower;e=!e||!f||p(f)||p(e)||f.equals(e)||e.equals(f)||f.contains(e)||e.contains(f)?!1:v(c,e)&&v(c,f)&&a(c,e,f)?!0:!1}return e?d:null}}(),ca=["top","left","right",
"bottom"]}(),CKEDITOR.config.magicline_keystrokePrevious=CKEDITOR.CTRL+CKEDITOR.SHIFT+51,CKEDITOR.config.magicline_keystrokeNext=CKEDITOR.CTRL+CKEDITOR.SHIFT+52,function(){function a(a){if(!a||a.type!=CKEDITOR.NODE_ELEMENT||"form"!=a.getName())return[];for(var b=[],d=["style","className"],c=0;c<d.length;c++){var e=a.$.elements.namedItem(d[c]);e&&(e=new CKEDITOR.dom.element(e),b.push([e,e.nextSibling]),e.remove())}return b}function e(a,b){if(a&&a.type==CKEDITOR.NODE_ELEMENT&&"form"==a.getName()&&0<
b.length)for(var d=b.length-1;0<=d;d--){var c=b[d][0],e=b[d][1];e?c.insertBefore(e):c.appendTo(a)}}function b(b,d){var g=a(b),c={},m=b.$;d||(c["class"]=m.className||"",m.className="");c.inline=m.style.cssText||"";d||(m.style.cssText="position: static; overflow: visible");e(g);return c}function d(b,d){var g=a(b),c=b.$;"class"in d&&(c.className=d["class"]);"inline"in d&&(c.style.cssText=d.inline);e(g)}function g(a){if(!a.editable().isInline()){var b=CKEDITOR.instances,d;for(d in b){var c=b[d];"wysiwyg"!=
c.mode||c.readOnly||(c=c.document.getBody(),c.setAttribute("contentEditable",!1),c.setAttribute("contentEditable",!0))}a.editable().hasFocus&&(a.toolbox.focus(),a.focus())}}CKEDITOR.plugins.add("maximize",{init:function(a){function e(){var b=m.getViewPaneSize();a.resize(b.width,b.height,null,!0)}if(a.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE){var h=a.lang,c=CKEDITOR.document,m=c.getWindow(),f,n,p,q=CKEDITOR.TRISTATE_OFF;a.addCommand("maximize",{modes:{wysiwyg:!CKEDITOR.env.iOS,source:!CKEDITOR.env.iOS},
readOnly:1,editorFocus:!1,exec:function(){var v=a.container.getFirst(function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasClass("cke_inner")}),y=a.ui.space("contents");if("wysiwyg"==a.mode){var r=a.getSelection();f=r&&r.getRanges();n=m.getScrollPosition()}else{var t=a.editable().$;f=!CKEDITOR.env.ie&&[t.selectionStart,t.selectionEnd];n=[t.scrollLeft,t.scrollTop]}if(this.state==CKEDITOR.TRISTATE_OFF){m.on("resize",e);p=m.getScrollPosition();for(r=a.container;r=r.getParent();)r.setCustomData("maximize_saved_styles",
b(r)),r.setStyle("z-index",a.config.baseFloatZIndex-5);y.setCustomData("maximize_saved_styles",b(y,!0));v.setCustomData("maximize_saved_styles",b(v,!0));y={overflow:CKEDITOR.env.webkit?"":"hidden",width:0,height:0};c.getDocumentElement().setStyles(y);!CKEDITOR.env.gecko&&c.getDocumentElement().setStyle("position","fixed");CKEDITOR.env.gecko&&CKEDITOR.env.quirks||c.getBody().setStyles(y);CKEDITOR.env.ie?setTimeout(function(){m.$.scrollTo(0,0)},0):m.$.scrollTo(0,0);v.setStyle("position",CKEDITOR.env.gecko&&
CKEDITOR.env.quirks?"fixed":"absolute");v.$.offsetLeft;v.setStyles({"z-index":a.config.baseFloatZIndex-5,left:"0px",top:"0px"});v.addClass("cke_maximized");e();y=v.getDocumentPosition();v.setStyles({left:-1*y.x+"px",top:-1*y.y+"px"});CKEDITOR.env.gecko&&g(a)}else if(this.state==CKEDITOR.TRISTATE_ON){m.removeListener("resize",e);for(var r=[y,v],w=0;w<r.length;w++)d(r[w],r[w].getCustomData("maximize_saved_styles")),r[w].removeCustomData("maximize_saved_styles");for(r=a.container;r=r.getParent();)d(r,
r.getCustomData("maximize_saved_styles")),r.removeCustomData("maximize_saved_styles");CKEDITOR.env.ie?setTimeout(function(){m.$.scrollTo(p.x,p.y)},0):m.$.scrollTo(p.x,p.y);v.removeClass("cke_maximized");CKEDITOR.env.webkit&&(v.setStyle("display","inline"),setTimeout(function(){v.setStyle("display","block")},0));a.fire("resize",{outerHeight:a.container.$.offsetHeight,contentsHeight:y.$.offsetHeight,outerWidth:a.container.$.offsetWidth})}this.toggleState();if(r=this.uiItems[0])y=this.state==CKEDITOR.TRISTATE_OFF?
h.maximize.maximize:h.maximize.minimize,r=CKEDITOR.document.getById(r._.id),r.getChild(1).setHtml(y),r.setAttribute("title",y),r.setAttribute("href",'javascript:void("'+y+'");');"wysiwyg"==a.mode?f?(CKEDITOR.env.gecko&&g(a),a.getSelection().selectRanges(f),(t=a.getSelection().getStartElement())&&t.scrollIntoView(!0)):m.$.scrollTo(n.x,n.y):(f&&(t.selectionStart=f[0],t.selectionEnd=f[1]),t.scrollLeft=n[0],t.scrollTop=n[1]);f=n=null;q=this.state;a.fire("maximize",this.state)},canUndo:!1});a.ui.addButton&&
a.ui.addButton("Maximize",{label:h.maximize.maximize,command:"maximize",toolbar:"tools,10"});a.on("mode",function(){var b=a.getCommand("maximize");b.setState(b.state==CKEDITOR.TRISTATE_DISABLED?CKEDITOR.TRISTATE_DISABLED:q)},null,null,100)}}})}(),function(){function a(a,b,d){var g=CKEDITOR.cleanWord;g?d():(a=CKEDITOR.getUrl(a.config.pasteFromWordCleanupFile||b+"filter/default.js"),CKEDITOR.scriptLoader.load(a,d,null,!0));return!g}CKEDITOR.plugins.add("pastefromword",{requires:"clipboard",init:function(e){function b(a){var b=
CKEDITOR.plugins.pastefromword&&CKEDITOR.plugins.pastefromword.images,c,d=[];if(b&&a.editor.filter.check("img[src]")&&(c=b.extractTagsFromHtml(a.data.dataValue),0!==c.length&&(b=b.extractFromRtf(a.data.dataTransfer["text/rtf"]),0!==b.length&&(CKEDITOR.tools.array.forEach(b,function(a){d.push(a.type?"data:"+a.type+";base64,"+CKEDITOR.tools.convertBytesToBase64(CKEDITOR.tools.convertHexStringToBytes(a.hex)):null)},this),c.length===d.length))))for(b=0;b<c.length;b++)0===c[b].indexOf("file://")&&d[b]&&
(a.data.dataValue=a.data.dataValue.replace(c[b],d[b]))}var d=0,g=this.path,l=void 0===e.config.pasteFromWord_inlineImages?!0:e.config.pasteFromWord_inlineImages;e.addCommand("pastefromword",{canUndo:!1,async:!0,exec:function(a,b){d=1;a.execCommand("paste",{type:"html",notification:b&&"undefined"!==typeof b.notification?b.notification:!0})}});e.ui.addButton&&e.ui.addButton("PasteFromWord",{label:e.lang.pastefromword.toolbar,command:"pastefromword",toolbar:"clipboard,50"});e.on("paste",function(b){var h=
b.data,c=CKEDITOR.plugins.clipboard.isCustomDataTypesSupported?h.dataTransfer.getData("text/html",!0):null,m=CKEDITOR.plugins.clipboard.isCustomDataTypesSupported?h.dataTransfer.getData("text/rtf"):null,c=c||h.dataValue,f={dataValue:c,dataTransfer:{"text/rtf":m}},m=/(class=\"?Mso|style=(?:\"|\')[^\"]*?\bmso\-|w:WordDocument|<o:\w+>|<\/font>)/,m=/<meta\s*name=(?:\"|\')?generator(?:\"|\')?\s*content=(?:\"|\')?microsoft/gi.test(c)||m.test(c);if(c&&(d||m)&&(!1!==e.fire("pasteFromWord",f)||d)){h.dontFilter=
!0;var l=a(e,g,function(){if(l)e.fire("paste",h);else if(!e.config.pasteFromWordPromptCleanup||d||confirm(e.lang.pastefromword.confirmCleanup))f.dataValue=CKEDITOR.cleanWord(f.dataValue,e),e.fire("afterPasteFromWord",f),h.dataValue=f.dataValue;d=0});l&&b.cancel()}},null,null,3);if(CKEDITOR.plugins.clipboard.isCustomDataTypesSupported&&l)e.on("afterPasteFromWord",b)}})}(),function(){var a={canUndo:!1,async:!0,exec:function(a,b){var d=a.lang,g=CKEDITOR.tools.keystrokeToString(d.common.keyboard,a.getCommandKeystroke(CKEDITOR.env.ie?
a.commands.paste:this)),l=b&&"undefined"!==typeof b.notification?b.notification:!b||!b.from||"keystrokeHandler"===b.from&&CKEDITOR.env.ie,d=l&&"string"===typeof l?l:d.pastetext.pasteNotification.replace(/%1/,'\x3ckbd aria-label\x3d"'+g.aria+'"\x3e'+g.display+"\x3c/kbd\x3e");a.execCommand("paste",{type:"text",notification:l?d:!1})}};CKEDITOR.plugins.add("pastetext",{requires:"clipboard",init:function(e){var b=CKEDITOR.env.safari?CKEDITOR.CTRL+CKEDITOR.ALT+CKEDITOR.SHIFT+86:CKEDITOR.CTRL+CKEDITOR.SHIFT+
86;e.addCommand("pastetext",a);e.setKeystroke(b,"pastetext");e.ui.addButton&&e.ui.addButton("PasteText",{label:e.lang.pastetext.button,command:"pastetext",toolbar:"clipboard,40"});if(e.config.forcePasteAsPlainText)e.on("beforePaste",function(a){"html"!=a.data.type&&(a.data.type="text")});e.on("pasteState",function(a){e.getCommand("pastetext").setState(a.data)})}})}(),CKEDITOR.plugins.add("removeformat",{init:function(a){a.addCommand("removeFormat",CKEDITOR.plugins.removeformat.commands.removeformat);
a.ui.addButton&&a.ui.addButton("RemoveFormat",{label:a.lang.removeformat.toolbar,command:"removeFormat",toolbar:"cleanup,10"})}}),CKEDITOR.plugins.removeformat={commands:{removeformat:{exec:function(a){for(var e=a._.removeFormatRegex||(a._.removeFormatRegex=new RegExp("^(?:"+a.config.removeFormatTags.replace(/,/g,"|")+")$","i")),b=a._.removeAttributes||(a._.removeAttributes=a.config.removeFormatAttributes.split(",")),d=CKEDITOR.plugins.removeformat.filter,g=a.getSelection().getRanges(),l=g.createIterator(),
k=function(a){return a.type==CKEDITOR.NODE_ELEMENT},h;h=l.getNextRange();){h.collapsed||h.enlarge(CKEDITOR.ENLARGE_ELEMENT);var c=h.createBookmark(),m=c.startNode,f=c.endNode,n=function(b){for(var c=a.elementPath(b),f=c.elements,g=1,h;(h=f[g])&&!h.equals(c.block)&&!h.equals(c.blockLimit);g++)e.test(h.getName())&&d(a,h)&&b.breakParent(h)};n(m);if(f)for(n(f),m=m.getNextSourceNode(!0,CKEDITOR.NODE_ELEMENT);m&&!m.equals(f);)if(m.isReadOnly()){if(m.getPosition(f)&CKEDITOR.POSITION_CONTAINS)break;m=m.getNext(k)}else n=
m.getNextSourceNode(!1,CKEDITOR.NODE_ELEMENT),"img"==m.getName()&&m.data("cke-realelement")||!d(a,m)||(e.test(m.getName())?m.remove(1):(m.removeAttributes(b),a.fire("removeFormatCleanup",m))),m=n;h.moveToBookmark(c)}a.forceNextSelectionCheck();a.getSelection().selectRanges(g)}}},filter:function(a,e){for(var b=a._.removeFormatFilters||[],d=0;d<b.length;d++)if(!1===b[d](e))return!1;return!0}},CKEDITOR.editor.prototype.addRemoveFormatFilter=function(a){this._.removeFormatFilters||(this._.removeFormatFilters=
[]);this._.removeFormatFilters.push(a)},CKEDITOR.config.removeFormatTags="b,big,cite,code,del,dfn,em,font,i,ins,kbd,q,s,samp,small,span,strike,strong,sub,sup,tt,u,var",CKEDITOR.config.removeFormatAttributes="class,style,lang,width,height,align,hspace,valign",CKEDITOR.plugins.add("resize",{init:function(a){function e(b){var e=c.width,g=c.height,k=e+(b.data.$.screenX-h.x)*("rtl"==l?-1:1);b=g+(b.data.$.screenY-h.y);m&&(e=Math.max(d.resize_minWidth,Math.min(k,d.resize_maxWidth)));f&&(g=Math.max(d.resize_minHeight,
Math.min(b,d.resize_maxHeight)));a.resize(m?e:null,g)}function b(){CKEDITOR.document.removeListener("mousemove",e);CKEDITOR.document.removeListener("mouseup",b);a.document&&(a.document.removeListener("mousemove",e),a.document.removeListener("mouseup",b))}var d=a.config,g=a.ui.spaceId("resizer"),l=a.element?a.element.getDirection(1):"ltr";!d.resize_dir&&(d.resize_dir="vertical");void 0===d.resize_maxWidth&&(d.resize_maxWidth=3E3);void 0===d.resize_maxHeight&&(d.resize_maxHeight=3E3);void 0===d.resize_minWidth&&
(d.resize_minWidth=750);void 0===d.resize_minHeight&&(d.resize_minHeight=250);if(!1!==d.resize_enabled){var k=null,h,c,m=("both"==d.resize_dir||"horizontal"==d.resize_dir)&&d.resize_minWidth!=d.resize_maxWidth,f=("both"==d.resize_dir||"vertical"==d.resize_dir)&&d.resize_minHeight!=d.resize_maxHeight,n=CKEDITOR.tools.addFunction(function(f){k||(k=a.getResizable());c={width:k.$.offsetWidth||0,height:k.$.offsetHeight||0};h={x:f.screenX,y:f.screenY};d.resize_minWidth>c.width&&(d.resize_minWidth=c.width);
d.resize_minHeight>c.height&&(d.resize_minHeight=c.height);CKEDITOR.document.on("mousemove",e);CKEDITOR.document.on("mouseup",b);a.document&&(a.document.on("mousemove",e),a.document.on("mouseup",b));f.preventDefault&&f.preventDefault()});a.on("destroy",function(){CKEDITOR.tools.removeFunction(n)});a.on("uiSpace",function(b){if("bottom"==b.data.space){var c="";m&&!f&&(c=" cke_resizer_horizontal");!m&&f&&(c=" cke_resizer_vertical");var d='\x3cspan id\x3d"'+g+'" class\x3d"cke_resizer'+c+" cke_resizer_"+
l+'" title\x3d"'+CKEDITOR.tools.htmlEncode(a.lang.common.resize)+'" onmousedown\x3d"CKEDITOR.tools.callFunction('+n+', event)"\x3e'+("ltr"==l?"◢":"◣")+"\x3c/span\x3e";"ltr"==l&&"ltr"==c?b.data.html+=d:b.data.html=d+b.data.html}},a,null,100);a.on("maximize",function(b){a.ui.space("resizer")[b.data==CKEDITOR.TRISTATE_ON?"hide":"show"]()})}}}),CKEDITOR.plugins.add("menubutton",{requires:"button,menu",onLoad:function(){var a=function(a){var b=this._,d=b.menu;b.state!==CKEDITOR.TRISTATE_DISABLED&&(b.on&&
d?d.hide():(b.previousState=b.state,d||(d=b.menu=new CKEDITOR.menu(a,{panel:{className:"cke_menu_panel",attributes:{"aria-label":a.lang.common.options}}}),d.onHide=CKEDITOR.tools.bind(function(){var d=this.command?a.getCommand(this.command).modes:this.modes;this.setState(!d||d[a.mode]?b.previousState:CKEDITOR.TRISTATE_DISABLED);b.on=0},this),this.onMenu&&d.addListener(this.onMenu)),this.setState(CKEDITOR.TRISTATE_ON),b.on=1,setTimeout(function(){d.show(CKEDITOR.document.getById(b.id),4)},0)))};CKEDITOR.ui.menuButton=
CKEDITOR.tools.createClass({base:CKEDITOR.ui.button,$:function(e){delete e.panel;this.base(e);this.hasArrow=!0;this.click=a},statics:{handler:{create:function(a){return new CKEDITOR.ui.menuButton(a)}}}})},beforeInit:function(a){a.ui.addHandler(CKEDITOR.UI_MENUBUTTON,CKEDITOR.ui.menuButton.handler)}}),CKEDITOR.UI_MENUBUTTON="menubutton","use strict",CKEDITOR.plugins.add("scayt",{requires:"menubutton,dialog",tabToOpen:null,dialogName:"scaytDialog",onLoad:function(a){CKEDITOR.plugins.scayt.onLoadTimestamp=
(new Date).getTime();"moono-lisa"==(CKEDITOR.skinName||a.config.skin)&&CKEDITOR.document.appendStyleSheet(this.path+"skins/"+CKEDITOR.skin.name+"/scayt.css");CKEDITOR.document.appendStyleSheet(this.path+"dialogs/dialog.css")},init:function(a){var e=this,b=CKEDITOR.plugins.scayt;this.bindEvents(a);this.parseConfig(a);this.addRule(a);CKEDITOR.dialog.add(this.dialogName,CKEDITOR.getUrl(this.path+"dialogs/options.js"));this.addMenuItems(a);var d=a.lang.scayt,g=CKEDITOR.env;a.ui.add("Scayt",CKEDITOR.UI_MENUBUTTON,
{label:d.text_title,title:a.plugins.wsc?a.lang.wsc.title:d.text_title,modes:{wysiwyg:!(g.ie&&(8>g.version||g.quirks))},toolbar:"spellchecker,20",refresh:function(){var d=a.ui.instances.Scayt.getState();a.scayt&&(d=b.state.scayt[a.name]?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF);a.fire("scaytButtonState",d)},onRender:function(){var b=this;a.on("scaytButtonState",function(a){void 0!==typeof a.data&&b.setState(a.data)})},onMenu:function(){var d=a.scayt;a.getMenuItem("scaytToggle").label=a.lang.scayt[d&&
b.state.scayt[a.name]?"btn_disable":"btn_enable"];var e={scaytToggle:CKEDITOR.TRISTATE_OFF,scaytOptions:d?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,scaytLangs:d?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,scaytDict:d?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,scaytAbout:d?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,WSC:a.plugins.wsc?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED};a.config.scayt_uiTabs[0]||delete e.scaytOptions;a.config.scayt_uiTabs[1]||delete e.scaytLangs;
a.config.scayt_uiTabs[2]||delete e.scaytDict;d&&!CKEDITOR.plugins.scayt.isNewUdSupported(d)&&(delete e.scaytDict,a.config.scayt_uiTabs[2]=0,CKEDITOR.plugins.scayt.alarmCompatibilityMessage());return e}});a.contextMenu&&a.addMenuItems&&(a.contextMenu.addListener(function(b,d){var g=a.scayt,c,m;g&&(m=g.getSelectionNode())&&(c=e.menuGenerator(a,m),g.showBanner("."+a.contextMenu._.definition.panel.className.split(" ").join(" .")));return c}),a.contextMenu._.onHide=CKEDITOR.tools.override(a.contextMenu._.onHide,
function(b){return function(){var d=a.scayt;d&&d.hideBanner();return b.apply(this)}}))},addMenuItems:function(a){var e=this,b=CKEDITOR.plugins.scayt;a.addMenuGroup("scaytButton");for(var d=a.config.scayt_contextMenuItemsOrder.split("|"),g=0;g<d.length;g++)d[g]="scayt_"+d[g];if((d=["grayt_description","grayt_suggest","grayt_control"].concat(d))&&d.length)for(g=0;g<d.length;g++)a.addMenuGroup(d[g],g-10);a.addCommand("scaytToggle",{exec:function(a){var d=a.scayt;b.state.scayt[a.name]=!b.state.scayt[a.name];
!0===b.state.scayt[a.name]?d||b.createScayt(a):d&&b.destroy(a)}});a.addCommand("scaytAbout",{exec:function(a){a.scayt.tabToOpen="about";a.lockSelection();a.openDialog(e.dialogName)}});a.addCommand("scaytOptions",{exec:function(a){a.scayt.tabToOpen="options";a.lockSelection();a.openDialog(e.dialogName)}});a.addCommand("scaytLangs",{exec:function(a){a.scayt.tabToOpen="langs";a.lockSelection();a.openDialog(e.dialogName)}});a.addCommand("scaytDict",{exec:function(a){a.scayt.tabToOpen="dictionaries";a.lockSelection();
a.openDialog(e.dialogName)}});d={scaytToggle:{label:a.lang.scayt.btn_enable,group:"scaytButton",command:"scaytToggle"},scaytAbout:{label:a.lang.scayt.btn_about,group:"scaytButton",command:"scaytAbout"},scaytOptions:{label:a.lang.scayt.btn_options,group:"scaytButton",command:"scaytOptions"},scaytLangs:{label:a.lang.scayt.btn_langs,group:"scaytButton",command:"scaytLangs"},scaytDict:{label:a.lang.scayt.btn_dictionaries,group:"scaytButton",command:"scaytDict"}};a.plugins.wsc&&(d.WSC={label:a.lang.wsc.toolbar,
group:"scaytButton",onClick:function(){var b=CKEDITOR.plugins.scayt,d=a.scayt,e=a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?a.container.getText():a.document.getBody().getText();(e=e.replace(/\s/g,""))?(d&&b.state.scayt[a.name]&&d.setMarkupPaused&&d.setMarkupPaused(!0),a.lockSelection(),a.execCommand("checkspell")):alert("Nothing to check!")}});a.addMenuItems(d)},bindEvents:function(a){var e=CKEDITOR.plugins.scayt,b=a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE,d=function(){e.destroy(a)},g=function(){!e.state.scayt[a.name]||
a.readOnly||a.scayt||e.createScayt(a)},l=function(){var d=a.editable();d.attachListener(d,"focus",function(c){CKEDITOR.plugins.scayt&&!a.scayt&&setTimeout(g,0);c=CKEDITOR.plugins.scayt&&CKEDITOR.plugins.scayt.state.scayt[a.name]&&a.scayt;var d,e;if((b||c)&&a._.savedSelection){c=a._.savedSelection.getSelectedElement();c=!c&&a._.savedSelection.getRanges();for(var h=0;h<c.length;h++)e=c[h],"string"===typeof e.startContainer.$.nodeValue&&(d=e.startContainer.getText().length,(d<e.startOffset||d<e.endOffset)&&
a.unlockSelection(!1))}},this,null,-10)},k=function(){b?a.config.scayt_inlineModeImmediateMarkup?g():(a.on("blur",function(){setTimeout(d,0)}),a.on("focus",g),a.focusManager.hasFocus&&g()):g();l();var e=a.editable();e.attachListener(e,"mousedown",function(b){b=b.data.getTarget();var d=a.widgets&&a.widgets.getByElement(b);d&&(d.wrapper=b.getAscendant(function(a){return a.hasAttribute("data-cke-widget-wrapper")},!0))},this,null,-10)};a.on("contentDom",k);a.on("beforeCommandExec",function(b){var c=a.scayt,
d=!1,f=!1,g=!0;b.data.name in e.options.disablingCommandExec&&"wysiwyg"==a.mode?c&&(e.destroy(a),a.fire("scaytButtonState",CKEDITOR.TRISTATE_DISABLED)):"bold"!==b.data.name&&"italic"!==b.data.name&&"underline"!==b.data.name&&"strike"!==b.data.name&&"subscript"!==b.data.name&&"superscript"!==b.data.name&&"enter"!==b.data.name&&"cut"!==b.data.name&&"language"!==b.data.name||!c||("cut"===b.data.name&&(g=!1,f=!0),"language"===b.data.name&&(f=d=!0),a.fire("reloadMarkupScayt",{removeOptions:{removeInside:g,
forceBookmark:f,language:d},timeout:0}))});a.on("beforeSetMode",function(b){if("source"==b.data){if(b=a.scayt)e.destroy(a),a.fire("scaytButtonState",CKEDITOR.TRISTATE_DISABLED);a.document&&a.document.getBody().removeAttribute("_jquid")}});a.on("afterCommandExec",function(b){"wysiwyg"!=a.mode||"undo"!=b.data.name&&"redo"!=b.data.name||setTimeout(function(){e.reloadMarkup(a.scayt)},250)});a.on("readOnly",function(b){var c;b&&(c=a.scayt,!0===b.editor.readOnly?c&&c.fire("removeMarkupInDocument",{}):c?
e.reloadMarkup(c):"wysiwyg"==b.editor.mode&&!0===e.state.scayt[b.editor.name]&&(e.createScayt(a),b.editor.fire("scaytButtonState",CKEDITOR.TRISTATE_ON)))});a.on("beforeDestroy",d);a.on("setData",function(){d();(a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE||a.plugins.divarea)&&k()},this,null,50);a.on("reloadMarkupScayt",function(b){var c=b.data&&b.data.removeOptions,d=b.data&&b.data.timeout,f=b.data&&b.data.language,g=a.scayt;g&&setTimeout(function(){f&&(c.selectionNode=a.plugins.language.getCurrentLangElement(a),
c.selectionNode=c.selectionNode&&c.selectionNode.$||null);g.removeMarkupInSelectionNode(c);e.reloadMarkup(g)},d||0)});a.on("insertElement",function(){a.fire("reloadMarkupScayt",{removeOptions:{forceBookmark:!0}})},this,null,50);a.on("insertHtml",function(){a.scayt&&a.scayt.setFocused&&a.scayt.setFocused(!0);a.fire("reloadMarkupScayt")},this,null,50);a.on("insertText",function(){a.scayt&&a.scayt.setFocused&&a.scayt.setFocused(!0);a.fire("reloadMarkupScayt")},this,null,50);a.on("scaytDialogShown",function(b){b.data.selectPage(a.scayt.tabToOpen)})},
parseConfig:function(a){var e=CKEDITOR.plugins.scayt;e.replaceOldOptionsNames(a.config);"boolean"!==typeof a.config.scayt_autoStartup&&(a.config.scayt_autoStartup=!1);e.state.scayt[a.name]=a.config.scayt_autoStartup;"boolean"!==typeof a.config.grayt_autoStartup&&(a.config.grayt_autoStartup=!1);"boolean"!==typeof a.config.scayt_inlineModeImmediateMarkup&&(a.config.scayt_inlineModeImmediateMarkup=!1);e.state.grayt[a.name]=a.config.grayt_autoStartup;a.config.scayt_contextCommands||(a.config.scayt_contextCommands=
"ignoreall|add");a.config.scayt_contextMenuItemsOrder||(a.config.scayt_contextMenuItemsOrder="suggest|moresuggest|control");a.config.scayt_sLang||(a.config.scayt_sLang="en_US");if(void 0===a.config.scayt_maxSuggestions||"number"!=typeof a.config.scayt_maxSuggestions||0>a.config.scayt_maxSuggestions)a.config.scayt_maxSuggestions=5;if(void 0===a.config.scayt_minWordLength||"number"!=typeof a.config.scayt_minWordLength||1>a.config.scayt_minWordLength)a.config.scayt_minWordLength=4;if(void 0===a.config.scayt_customDictionaryIds||
"string"!==typeof a.config.scayt_customDictionaryIds)a.config.scayt_customDictionaryIds="";if(void 0===a.config.scayt_userDictionaryName||"string"!==typeof a.config.scayt_userDictionaryName)a.config.scayt_userDictionaryName=null;if("string"===typeof a.config.scayt_uiTabs&&3===a.config.scayt_uiTabs.split(",").length){var b=[],d=[];a.config.scayt_uiTabs=a.config.scayt_uiTabs.split(",");CKEDITOR.tools.search(a.config.scayt_uiTabs,function(a){1===Number(a)||0===Number(a)?(d.push(!0),b.push(Number(a))):
d.push(!1)});null===CKEDITOR.tools.search(d,!1)?a.config.scayt_uiTabs=b:a.config.scayt_uiTabs=[1,1,1]}else a.config.scayt_uiTabs=[1,1,1];"string"!=typeof a.config.scayt_serviceProtocol&&(a.config.scayt_serviceProtocol=null);"string"!=typeof a.config.scayt_serviceHost&&(a.config.scayt_serviceHost=null);"string"!=typeof a.config.scayt_servicePort&&(a.config.scayt_servicePort=null);"string"!=typeof a.config.scayt_servicePath&&(a.config.scayt_servicePath=null);a.config.scayt_moreSuggestions||(a.config.scayt_moreSuggestions=
"on");"string"!==typeof a.config.scayt_customerId&&(a.config.scayt_customerId="1:WvF0D4-UtPqN1-43nkD4-NKvUm2-daQqk3-LmNiI-z7Ysb4-mwry24-T8YrS3-Q2tpq2");"string"!==typeof a.config.scayt_customPunctuation&&(a.config.scayt_customPunctuation="-");"string"!==typeof a.config.scayt_srcUrl&&(e=document.location.protocol,e=-1!=e.search(/https?:/)?e:"http:",a.config.scayt_srcUrl=e+"//svc.webspellchecker.net/spellcheck31/lf/scayt3/ckscayt/ckscayt.js");"boolean"!==typeof CKEDITOR.config.scayt_handleCheckDirty&&
(CKEDITOR.config.scayt_handleCheckDirty=!0);"boolean"!==typeof CKEDITOR.config.scayt_handleUndoRedo&&(CKEDITOR.config.scayt_handleUndoRedo=!0);CKEDITOR.config.scayt_handleUndoRedo=CKEDITOR.plugins.undo?CKEDITOR.config.scayt_handleUndoRedo:!1;"boolean"!==typeof a.config.scayt_multiLanguageMode&&(a.config.scayt_multiLanguageMode=!1);"object"!==typeof a.config.scayt_multiLanguageStyles&&(a.config.scayt_multiLanguageStyles={});a.config.scayt_ignoreAllCapsWords&&"boolean"!==typeof a.config.scayt_ignoreAllCapsWords&&
(a.config.scayt_ignoreAllCapsWords=!1);a.config.scayt_ignoreDomainNames&&"boolean"!==typeof a.config.scayt_ignoreDomainNames&&(a.config.scayt_ignoreDomainNames=!1);a.config.scayt_ignoreWordsWithMixedCases&&"boolean"!==typeof a.config.scayt_ignoreWordsWithMixedCases&&(a.config.scayt_ignoreWordsWithMixedCases=!1);a.config.scayt_ignoreWordsWithNumbers&&"boolean"!==typeof a.config.scayt_ignoreWordsWithNumbers&&(a.config.scayt_ignoreWordsWithNumbers=!1);if(a.config.scayt_disableOptionsStorage){var e=CKEDITOR.tools.isArray(a.config.scayt_disableOptionsStorage)?
a.config.scayt_disableOptionsStorage:"string"===typeof a.config.scayt_disableOptionsStorage?[a.config.scayt_disableOptionsStorage]:void 0,g="all options lang ignore-all-caps-words ignore-domain-names ignore-words-with-mixed-cases ignore-words-with-numbers".split(" "),l=["lang","ignore-all-caps-words","ignore-domain-names","ignore-words-with-mixed-cases","ignore-words-with-numbers"],k=CKEDITOR.tools.search,h=CKEDITOR.tools.indexOf;a.config.scayt_disableOptionsStorage=function(a){for(var b=[],d=0;d<
a.length;d++){var e=a[d],p=!!k(a,"options");if(!k(g,e)||p&&k(l,function(a){if("lang"===a)return!1}))return;k(l,e)&&l.splice(h(l,e),1);if("all"===e||p&&k(a,"lang"))return[];"options"===e&&(l=["lang"])}return b=b.concat(l)}(e)}},addRule:function(a){var e=CKEDITOR.plugins.scayt,b=a.dataProcessor,d=b&&b.htmlFilter,g=a._.elementsPath&&a._.elementsPath.filters,b=b&&b.dataFilter,l=a.addRemoveFormatFilter,k=function(b){if(a.scayt&&(b.hasAttribute(e.options.data_attribute_name)||b.hasAttribute(e.options.problem_grammar_data_attribute)))return!1},
h=function(b){var d=!0;a.scayt&&(b.hasAttribute(e.options.data_attribute_name)||b.hasAttribute(e.options.problem_grammar_data_attribute))&&(d=!1);return d};g&&g.push(k);b&&b.addRules({elements:{span:function(a){var b=a.hasClass(e.options.misspelled_word_class)&&a.attributes[e.options.data_attribute_name],d=a.hasClass(e.options.problem_grammar_class)&&a.attributes[e.options.problem_grammar_data_attribute];e&&(b||d)&&delete a.name;return a}}});d&&d.addRules({elements:{span:function(a){var b=a.hasClass(e.options.misspelled_word_class)&&
a.attributes[e.options.data_attribute_name],d=a.hasClass(e.options.problem_grammar_class)&&a.attributes[e.options.problem_grammar_data_attribute];e&&(b||d)&&delete a.name;return a}}});l&&l.call(a,h)},scaytMenuDefinition:function(a){var e=this;a=a.scayt;return{scayt:{scayt_ignore:{label:a.getLocal("btn_ignore"),group:"scayt_control",order:1,exec:function(a){a.scayt.ignoreWord()}},scayt_ignoreall:{label:a.getLocal("btn_ignoreAll"),group:"scayt_control",order:2,exec:function(a){a.scayt.ignoreAllWords()}},
scayt_add:{label:a.getLocal("btn_addWord"),group:"scayt_control",order:3,exec:function(a){var d=a.scayt;setTimeout(function(){d.addWordToUserDictionary()},10)}},scayt_option:{label:a.getLocal("btn_options"),group:"scayt_control",order:4,exec:function(a){a.scayt.tabToOpen="options";a.lockSelection();a.openDialog(e.dialogName)},verification:function(a){return 1==a.config.scayt_uiTabs[0]?!0:!1}},scayt_language:{label:a.getLocal("btn_langs"),group:"scayt_control",order:5,exec:function(a){a.scayt.tabToOpen=
"langs";a.lockSelection();a.openDialog(e.dialogName)},verification:function(a){return 1==a.config.scayt_uiTabs[1]?!0:!1}},scayt_dictionary:{label:a.getLocal("btn_dictionaries"),group:"scayt_control",order:6,exec:function(a){a.scayt.tabToOpen="dictionaries";a.lockSelection();a.openDialog(e.dialogName)},verification:function(a){return 1==a.config.scayt_uiTabs[2]?!0:!1}},scayt_about:{label:a.getLocal("btn_about"),group:"scayt_control",order:7,exec:function(a){a.scayt.tabToOpen="about";a.lockSelection();
a.openDialog(e.dialogName)}}},grayt:{grayt_problemdescription:{label:"Grammar problem description",group:"grayt_description",order:1,state:CKEDITOR.TRISTATE_DISABLED,exec:function(a){}},grayt_ignore:{label:a.getLocal("btn_ignore"),group:"grayt_control",order:2,exec:function(a){a.scayt.ignorePhrase()}},grayt_ignoreall:{label:a.getLocal("btn_ignoreAll"),group:"grayt_control",order:3,exec:function(a){a.scayt.ignoreAllPhrases()}}}}},buildSuggestionMenuItems:function(a,e,b){var d={},g={},l=b?"word":"phrase",
k=b?"startGrammarCheck":"startSpellCheck",h=a.scayt;if(0<e.length&&"no_any_suggestions"!==e[0])if(b)for(b=0;b<e.length;b++){var c="scayt_suggest_"+CKEDITOR.plugins.scayt.suggestions[b].replace(" ","_");a.addCommand(c,this.createCommand(CKEDITOR.plugins.scayt.suggestions[b],l,k));b<a.config.scayt_maxSuggestions?(a.addMenuItem(c,{label:e[b],command:c,group:"scayt_suggest",order:b+1}),d[c]=CKEDITOR.TRISTATE_OFF):(a.addMenuItem(c,{label:e[b],command:c,group:"scayt_moresuggest",order:b+1}),g[c]=CKEDITOR.TRISTATE_OFF,
"on"===a.config.scayt_moreSuggestions&&(a.addMenuItem("scayt_moresuggest",{label:h.getLocal("btn_moreSuggestions"),group:"scayt_moresuggest",order:10,getItems:function(){return g}}),d.scayt_moresuggest=CKEDITOR.TRISTATE_OFF))}else for(b=0;b<e.length;b++)c="grayt_suggest_"+CKEDITOR.plugins.scayt.suggestions[b].replace(" ","_"),a.addCommand(c,this.createCommand(CKEDITOR.plugins.scayt.suggestions[b],l,k)),a.addMenuItem(c,{label:e[b],command:c,group:"grayt_suggest",order:b+1}),d[c]=CKEDITOR.TRISTATE_OFF;
else d.no_scayt_suggest=CKEDITOR.TRISTATE_DISABLED,a.addCommand("no_scayt_suggest",{exec:function(){}}),a.addMenuItem("no_scayt_suggest",{label:h.getLocal("btn_noSuggestions")||"no_scayt_suggest",command:"no_scayt_suggest",group:"scayt_suggest",order:0});return d},menuGenerator:function(a,e){var b=a.scayt,d=this.scaytMenuDefinition(a),g={},l=a.config.scayt_contextCommands.split("|"),k=e.getAttribute(b.getLangAttribute())||b.getLang(),h,c,m;h=b.isScaytNode(e);c=b.isGraytNode(e);h?(d=d.scayt,g=e.getAttribute(b.getScaytNodeAttributeName()),
b.fire("getSuggestionsList",{lang:k,word:g}),g=this.buildSuggestionMenuItems(a,CKEDITOR.plugins.scayt.suggestions,h)):c&&(d=d.grayt,g=e.getAttribute(b.getGraytNodeAttributeName()),m=b.getProblemDescriptionText(g,k),d.grayt_problemdescription&&m&&(d.grayt_problemdescription.label=m),b.fire("getGrammarSuggestionsList",{lang:k,phrase:g}),g=this.buildSuggestionMenuItems(a,CKEDITOR.plugins.scayt.suggestions,h));if(h&&"off"==a.config.scayt_contextCommands)return g;for(var f in d)h&&-1==CKEDITOR.tools.indexOf(l,
f.replace("scayt_",""))&&"all"!=a.config.scayt_contextCommands||c&&"grayt_problemdescription"!==f&&-1==CKEDITOR.tools.indexOf(l,f.replace("grayt_",""))&&"all"!=a.config.scayt_contextCommands||(g[f]="undefined"!=typeof d[f].state?d[f].state:CKEDITOR.TRISTATE_OFF,"function"!==typeof d[f].verification||d[f].verification(a)||delete g[f],a.addCommand(f,{exec:d[f].exec}),a.addMenuItem(f,{label:a.lang.scayt[d[f].label]||d[f].label,command:f,group:d[f].group,order:d[f].order}));return g},createCommand:function(a,
e,b){return{exec:function(d){d=d.scayt;var g={};g[e]=a;d.replaceSelectionNode(g);"startGrammarCheck"===b&&d.removeMarkupInSelectionNode({grammarOnly:!0});d.fire(b)}}}}),CKEDITOR.plugins.scayt={charsToObserve:[{charName:"cke-fillingChar",charCode:function(){var a=CKEDITOR.version.match(/^\d(\.\d*)*/),a=a&&a[0],e;if(a){e="4.5.7";var b,a=a.replace(/\./g,"");e=e.replace(/\./g,"");b=a.length-e.length;b=0<=b?b:0;e=parseInt(a)>=parseInt(e)*Math.pow(10,b)}return e?Array(7).join(String.fromCharCode(8203)):
String.fromCharCode(8203)}()}],onLoadTimestamp:"",state:{scayt:{},grayt:{}},warningCounter:0,suggestions:[],options:{disablingCommandExec:{source:!0,newpage:!0,templates:!0},data_attribute_name:"data-scayt-word",misspelled_word_class:"scayt-misspell-word",problem_grammar_data_attribute:"data-grayt-phrase",problem_grammar_class:"gramm-problem"},backCompatibilityMap:{scayt_service_protocol:"scayt_serviceProtocol",scayt_service_host:"scayt_serviceHost",scayt_service_port:"scayt_servicePort",scayt_service_path:"scayt_servicePath",
scayt_customerid:"scayt_customerId"},alarmCompatibilityMessage:function(){5>this.warningCounter&&(console.warn("You are using the latest version of SCAYT plugin for CKEditor with the old application version. In order to have access to the newest features, it is recommended to upgrade the application version to latest one as well. Contact us for more details at support@webspellchecker.net."),this.warningCounter+=1)},isNewUdSupported:function(a){return a.getUserDictionary?!0:!1},reloadMarkup:function(a){var e;
a&&(e=a.getScaytLangList(),a.reloadMarkup?a.reloadMarkup():(this.alarmCompatibilityMessage(),e&&e.ltr&&e.rtl&&a.fire("startSpellCheck, startGrammarCheck")))},replaceOldOptionsNames:function(a){for(var e in a)e in this.backCompatibilityMap&&(a[this.backCompatibilityMap[e]]=a[e],delete a[e])},createScayt:function(a){var e=this,b=CKEDITOR.plugins.scayt;this.loadScaytLibrary(a,function(a){function g(a){return new SCAYT.CKSCAYT(a,function(){},function(){})}var l=a.window&&a.window.getFrame()||a.editable();
if(l){l={lang:a.config.scayt_sLang,container:l.$,customDictionary:a.config.scayt_customDictionaryIds,userDictionaryName:a.config.scayt_userDictionaryName,localization:a.langCode,customer_id:a.config.scayt_customerId,customPunctuation:a.config.scayt_customPunctuation,debug:a.config.scayt_debug,data_attribute_name:e.options.data_attribute_name,misspelled_word_class:e.options.misspelled_word_class,problem_grammar_data_attribute:e.options.problem_grammar_data_attribute,problem_grammar_class:e.options.problem_grammar_class,
"options-to-restore":a.config.scayt_disableOptionsStorage,focused:a.editable().hasFocus,ignoreElementsRegex:a.config.scayt_elementsToIgnore,ignoreGraytElementsRegex:a.config.grayt_elementsToIgnore,minWordLength:a.config.scayt_minWordLength,multiLanguageMode:a.config.scayt_multiLanguageMode,multiLanguageStyles:a.config.scayt_multiLanguageStyles,graytAutoStartup:a.config.grayt_autoStartup,charsToObserve:b.charsToObserve};a.config.scayt_serviceProtocol&&(l.service_protocol=a.config.scayt_serviceProtocol);
a.config.scayt_serviceHost&&(l.service_host=a.config.scayt_serviceHost);a.config.scayt_servicePort&&(l.service_port=a.config.scayt_servicePort);a.config.scayt_servicePath&&(l.service_path=a.config.scayt_servicePath);"boolean"===typeof a.config.scayt_ignoreAllCapsWords&&(l["ignore-all-caps-words"]=a.config.scayt_ignoreAllCapsWords);"boolean"===typeof a.config.scayt_ignoreDomainNames&&(l["ignore-domain-names"]=a.config.scayt_ignoreDomainNames);"boolean"===typeof a.config.scayt_ignoreWordsWithMixedCases&&
(l["ignore-words-with-mixed-cases"]=a.config.scayt_ignoreWordsWithMixedCases);"boolean"===typeof a.config.scayt_ignoreWordsWithNumbers&&(l["ignore-words-with-numbers"]=a.config.scayt_ignoreWordsWithNumbers);var k;try{k=g(l)}catch(h){e.alarmCompatibilityMessage(),delete l.charsToObserve,k=g(l)}k.subscribe("suggestionListSend",function(a){for(var b={},d=[],e=0;e<a.suggestionList.length;e++)b["word_"+a.suggestionList[e]]||(b["word_"+a.suggestionList[e]]=a.suggestionList[e],d.push(a.suggestionList[e]));
CKEDITOR.plugins.scayt.suggestions=d});k.subscribe("selectionIsChanged",function(b){a.getSelection().isLocked&&a.lockSelection()});k.subscribe("graytStateChanged",function(c){b.state.grayt[a.name]=c.state});k.addMarkupHandler&&k.addMarkupHandler(function(b){var e=a.editable(),f=e.getCustomData(b.charName);f&&(f.$=b.node,e.setCustomData(b.charName,f))});a.scayt=k;a.fire("scaytButtonState",a.readOnly?CKEDITOR.TRISTATE_DISABLED:CKEDITOR.TRISTATE_ON)}else b.state.scayt[a.name]=!1})},destroy:function(a){a.scayt&&
a.scayt.destroy();delete a.scayt;a.fire("scaytButtonState",CKEDITOR.TRISTATE_OFF)},loadScaytLibrary:function(a,e){var b,d=function(){CKEDITOR.fireOnce("scaytReady");a.scayt||"function"===typeof e&&e(a)};"undefined"===typeof window.SCAYT||"function"!==typeof window.SCAYT.CKSCAYT?(b=a.config.scayt_srcUrl+"?"+this.onLoadTimestamp,CKEDITOR.scriptLoader.load(b,function(a){a&&d()})):window.SCAYT&&"function"===typeof window.SCAYT.CKSCAYT&&d()}},CKEDITOR.on("dialogDefinition",function(a){var e=a.data.name;
a=a.data.definition.dialog;if("scaytDialog"===e)a.on("cancel",function(a){return!1},this,null,-1);if("checkspell"===e)a.on("cancel",function(a){a=a.sender&&a.sender.getParentEditor();var d=CKEDITOR.plugins.scayt,e=a.scayt;e&&d.state.scayt[a.name]&&e.setMarkupPaused&&e.setMarkupPaused(!1);a.unlockSelection()},this,null,-2);if("link"===e)a.on("ok",function(a){var d=a.sender&&a.sender.getParentEditor();d&&setTimeout(function(){d.fire("reloadMarkupScayt",{removeOptions:{removeInside:!0,forceBookmark:!0},
timeout:0})},0)});if("replace"===e)a.on("hide",function(a){a=a.sender&&a.sender.getParentEditor();var d=CKEDITOR.plugins.scayt,e=a.scayt;a&&setTimeout(function(){e&&(e.fire("removeMarkupInDocument",{}),d.reloadMarkup(e))},0)})}),CKEDITOR.on("scaytReady",function(){if(!0===CKEDITOR.config.scayt_handleCheckDirty){var a=CKEDITOR.editor.prototype;a.checkDirty=CKEDITOR.tools.override(a.checkDirty,function(a){return function(){var d=null,e=this.scayt;if(CKEDITOR.plugins.scayt&&CKEDITOR.plugins.scayt.state.scayt[this.name]&&
this.scayt){if(d="ready"==this.status)var l=e.removeMarkupFromString(this.getSnapshot()),e=e.removeMarkupFromString(this._.previousValue),d=d&&e!==l}else d=a.call(this);return d}});a.resetDirty=CKEDITOR.tools.override(a.resetDirty,function(a){return function(){var d=this.scayt;CKEDITOR.plugins.scayt&&CKEDITOR.plugins.scayt.state.scayt[this.name]&&this.scayt?this._.previousValue=d.removeMarkupFromString(this.getSnapshot()):a.call(this)}})}if(!0===CKEDITOR.config.scayt_handleUndoRedo){var a=CKEDITOR.plugins.undo.Image.prototype,
e="function"==typeof a.equalsContent?"equalsContent":"equals";a[e]=CKEDITOR.tools.override(a[e],function(a){return function(d){var e=d.editor.scayt,l=this.contents,k=d.contents,h=null;CKEDITOR.plugins.scayt&&CKEDITOR.plugins.scayt.state.scayt[d.editor.name]&&d.editor.scayt&&(this.contents=e.removeMarkupFromString(l)||"",d.contents=e.removeMarkupFromString(k)||"");h=a.apply(this,arguments);this.contents=l;d.contents=k;return h}})}}),function(){var a={preserveState:!0,editorFocus:!1,readOnly:1,exec:function(a){this.toggleState();
this.refresh(a)},refresh:function(a){if(a.document){var b=this.state==CKEDITOR.TRISTATE_ON?"attachClass":"removeClass";a.editable()[b]("cke_show_borders")}}};CKEDITOR.plugins.add("showborders",{modes:{wysiwyg:1},onLoad:function(){var a;a=(CKEDITOR.env.ie6Compat?[".%1 table.%2,",".%1 table.%2 td, .%1 table.%2 th","{","border : #d3d3d3 1px dotted","}"]:".%1 table.%2,;.%1 table.%2 \x3e tr \x3e td, .%1 table.%2 \x3e tr \x3e th,;.%1 table.%2 \x3e tbody \x3e tr \x3e td, .%1 table.%2 \x3e tbody \x3e tr \x3e th,;.%1 table.%2 \x3e thead \x3e tr \x3e td, .%1 table.%2 \x3e thead \x3e tr \x3e th,;.%1 table.%2 \x3e tfoot \x3e tr \x3e td, .%1 table.%2 \x3e tfoot \x3e tr \x3e th;{;border : #d3d3d3 1px dotted;}".split(";")).join("").replace(/%2/g,
"cke_show_border").replace(/%1/g,"cke_show_borders ");CKEDITOR.addCss(a)},init:function(e){var b=e.addCommand("showborders",a);b.canUndo=!1;!1!==e.config.startupShowBorders&&b.setState(CKEDITOR.TRISTATE_ON);e.on("mode",function(){b.state!=CKEDITOR.TRISTATE_DISABLED&&b.refresh(e)},null,null,100);e.on("contentDom",function(){b.state!=CKEDITOR.TRISTATE_DISABLED&&b.refresh(e)});e.on("removeFormatCleanup",function(a){a=a.data;e.getCommand("showborders").state==CKEDITOR.TRISTATE_ON&&a.is("table")&&(!a.hasAttribute("border")||
0>=parseInt(a.getAttribute("border"),10))&&a.addClass("cke_show_border")})},afterInit:function(a){var b=a.dataProcessor;a=b&&b.dataFilter;b=b&&b.htmlFilter;a&&a.addRules({elements:{table:function(a){a=a.attributes;var b=a["class"],e=parseInt(a.border,10);e&&!(0>=e)||b&&-1!=b.indexOf("cke_show_border")||(a["class"]=(b||"")+" cke_show_border")}}});b&&b.addRules({elements:{table:function(a){a=a.attributes;var b=a["class"];b&&(a["class"]=b.replace("cke_show_border","").replace(/\s{2}/," ").replace(/^\s+|\s+$/,
""))}}})}});CKEDITOR.on("dialogDefinition",function(a){var b=a.data.name;if("table"==b||"tableProperties"==b)if(a=a.data.definition,b=a.getContents("info").get("txtBorder"),b.commit=CKEDITOR.tools.override(b.commit,function(a){return function(b,e){a.apply(this,arguments);var k=parseInt(this.getValue(),10);e[!k||0>=k?"addClass":"removeClass"]("cke_show_border")}}),a=(a=a.getContents("advanced"))&&a.get("advCSSClasses"))a.setup=CKEDITOR.tools.override(a.setup,function(a){return function(){a.apply(this,
arguments);this.setValue(this.getValue().replace(/cke_show_border/,""))}}),a.commit=CKEDITOR.tools.override(a.commit,function(a){return function(b,e){a.apply(this,arguments);parseInt(e.getAttribute("border"),10)||e.addClass("cke_show_border")}})})}(),function(){CKEDITOR.plugins.add("sourcearea",{init:function(e){function b(){var a=g&&this.equals(CKEDITOR.document.getActive());this.hide();this.setStyle("height",this.getParent().$.clientHeight+"px");this.setStyle("width",this.getParent().$.clientWidth+
"px");this.show();a&&this.focus()}if(e.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE){var d=CKEDITOR.plugins.sourcearea;e.addMode("source",function(d){var g=e.ui.space("contents").getDocument().createElement("textarea");g.setStyles(CKEDITOR.tools.extend({width:CKEDITOR.env.ie7Compat?"99%":"100%",height:"100%",resize:"none",outline:"none","text-align":"left"},CKEDITOR.tools.cssVendorPrefix("tab-size",e.config.sourceAreaTabSize||4)));g.setAttribute("dir","ltr");g.addClass("cke_source").addClass("cke_reset").addClass("cke_enable_context_menu");
e.ui.space("contents").append(g);g=e.editable(new a(e,g));g.setData(e.getData(1));CKEDITOR.env.ie&&(g.attachListener(e,"resize",b,g),g.attachListener(CKEDITOR.document.getWindow(),"resize",b,g),CKEDITOR.tools.setTimeout(b,0,g));e.fire("ariaWidget",this);d()});e.addCommand("source",d.commands.source);e.ui.addButton&&e.ui.addButton("Source",{label:e.lang.sourcearea.toolbar,command:"source",toolbar:"mode,10"});e.on("mode",function(){e.getCommand("source").setState("source"==e.mode?CKEDITOR.TRISTATE_ON:
CKEDITOR.TRISTATE_OFF)});var g=CKEDITOR.env.ie&&9==CKEDITOR.env.version}}});var a=CKEDITOR.tools.createClass({base:CKEDITOR.editable,proto:{setData:function(a){this.setValue(a);this.status="ready";this.editor.fire("dataReady")},getData:function(){return this.getValue()},insertHtml:function(){},insertElement:function(){},insertText:function(){},setReadOnly:function(a){this[(a?"set":"remove")+"Attribute"]("readOnly","readonly")},detach:function(){a.baseProto.detach.call(this);this.clearCustomData();
this.remove()}}})}(),CKEDITOR.plugins.sourcearea={commands:{source:{modes:{wysiwyg:1,source:1},editorFocus:!1,readOnly:1,exec:function(a){"wysiwyg"==a.mode&&a.fire("saveSnapshot");a.getCommand("source").setState(CKEDITOR.TRISTATE_DISABLED);a.setMode("source"==a.mode?"wysiwyg":"source")},canUndo:!1}}},CKEDITOR.plugins.add("specialchar",{availableLangs:{af:1,ar:1,az:1,bg:1,ca:1,cs:1,cy:1,da:1,de:1,"de-ch":1,el:1,en:1,"en-au":1,"en-ca":1,"en-gb":1,eo:1,es:1,"es-mx":1,et:1,eu:1,fa:1,fi:1,fr:1,"fr-ca":1,
gl:1,he:1,hr:1,hu:1,id:1,it:1,ja:1,km:1,ko:1,ku:1,lt:1,lv:1,nb:1,nl:1,no:1,oc:1,pl:1,pt:1,"pt-br":1,ro:1,ru:1,si:1,sk:1,sl:1,sq:1,sv:1,th:1,tr:1,tt:1,ug:1,uk:1,vi:1,zh:1,"zh-cn":1},requires:"dialog",init:function(a){var e=this;CKEDITOR.dialog.add("specialchar",this.path+"dialogs/specialchar.js");a.addCommand("specialchar",{exec:function(){var b=a.langCode,b=e.availableLangs[b]?b:e.availableLangs[b.replace(/-.*/,"")]?b.replace(/-.*/,""):"en";CKEDITOR.scriptLoader.load(CKEDITOR.getUrl(e.path+"dialogs/lang/"+
b+".js"),function(){CKEDITOR.tools.extend(a.lang.specialchar,e.langEntries[b]);a.openDialog("specialchar")})},modes:{wysiwyg:1},canUndo:!1});a.ui.addButton&&a.ui.addButton("SpecialChar",{label:a.lang.specialchar.toolbar,command:"specialchar",toolbar:"insert,50"})}}),CKEDITOR.config.specialChars="! \x26quot; # $ % \x26amp; ' ( ) * + - . / 0 1 2 3 4 5 6 7 8 9 : ; \x26lt; \x3d \x26gt; ? @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z [ ] ^ _ ` a b c d e f g h i j k l m n o p q r s t u v w x y z { | } ~ \x26euro; \x26lsquo; \x26rsquo; \x26ldquo; \x26rdquo; \x26ndash; \x26mdash; \x26iexcl; \x26cent; \x26pound; \x26curren; \x26yen; \x26brvbar; \x26sect; \x26uml; \x26copy; \x26ordf; \x26laquo; \x26not; \x26reg; \x26macr; \x26deg; \x26sup2; \x26sup3; \x26acute; \x26micro; \x26para; \x26middot; \x26cedil; \x26sup1; \x26ordm; \x26raquo; \x26frac14; \x26frac12; \x26frac34; \x26iquest; \x26Agrave; \x26Aacute; \x26Acirc; \x26Atilde; \x26Auml; \x26Aring; \x26AElig; \x26Ccedil; \x26Egrave; \x26Eacute; \x26Ecirc; \x26Euml; \x26Igrave; \x26Iacute; \x26Icirc; \x26Iuml; \x26ETH; \x26Ntilde; \x26Ograve; \x26Oacute; \x26Ocirc; \x26Otilde; \x26Ouml; \x26times; \x26Oslash; \x26Ugrave; \x26Uacute; \x26Ucirc; \x26Uuml; \x26Yacute; \x26THORN; \x26szlig; \x26agrave; \x26aacute; \x26acirc; \x26atilde; \x26auml; \x26aring; \x26aelig; \x26ccedil; \x26egrave; \x26eacute; \x26ecirc; \x26euml; \x26igrave; \x26iacute; \x26icirc; \x26iuml; \x26eth; \x26ntilde; \x26ograve; \x26oacute; \x26ocirc; \x26otilde; \x26ouml; \x26divide; \x26oslash; \x26ugrave; \x26uacute; \x26ucirc; \x26uuml; \x26yacute; \x26thorn; \x26yuml; \x26OElig; \x26oelig; \x26#372; \x26#374 \x26#373 \x26#375; \x26sbquo; \x26#8219; \x26bdquo; \x26hellip; \x26trade; \x26#9658; \x26bull; \x26rarr; \x26rArr; \x26hArr; \x26diams; \x26asymp;".split(" "),
function(){CKEDITOR.plugins.add("stylescombo",{requires:"richcombo",init:function(a){var e=a.config,b=a.lang.stylescombo,d={},g=[],l=[];a.on("stylesSet",function(b){if(b=b.data.styles){for(var h,c,m,f=0,n=b.length;f<n;f++)(h=b[f],a.blockless&&h.element in CKEDITOR.dtd.$block||"string"==typeof h.type&&!CKEDITOR.style.customHandlers[h.type]||(c=h.name,h=new CKEDITOR.style(h),a.filter.customConfig&&!a.filter.check(h)))||(h._name=c,h._.enterMode=e.enterMode,h._.type=m=h.assignedTo||h.type,h._.weight=
f+1E3*(m==CKEDITOR.STYLE_OBJECT?1:m==CKEDITOR.STYLE_BLOCK?2:3),d[c]=h,g.push(h),l.push(h));g.sort(function(a,b){return a._.weight-b._.weight})}});a.ui.addRichCombo("Styles",{label:b.label,title:b.panelTitle,toolbar:"styles,10",allowedContent:l,panel:{css:[CKEDITOR.skin.getPath("editor")].concat(e.contentsCss),multiSelect:!0,attributes:{"aria-label":b.panelTitle}},init:function(){var a,d,c,e,f,l;f=0;for(l=g.length;f<l;f++)a=g[f],d=a._name,e=a._.type,e!=c&&(this.startGroup(b["panelTitle"+String(e)]),
c=e),this.add(d,a.type==CKEDITOR.STYLE_OBJECT?d:a.buildPreview(),d);this.commit()},onClick:function(b){a.focus();a.fire("saveSnapshot");b=d[b];var e=a.elementPath();if(b.group&&b.removeStylesFromSameGroup(a))a.applyStyle(b);else a[b.checkActive(e,a)?"removeStyle":"applyStyle"](b);a.fire("saveSnapshot")},onRender:function(){a.on("selectionChange",function(b){var e=this.getValue();b=b.data.path.elements;for(var c=0,g=b.length,f;c<g;c++){f=b[c];for(var l in d)if(d[l].checkElementRemovable(f,!0,a)){l!=
e&&this.setValue(l);return}}this.setValue("")},this)},onOpen:function(){var e=a.getSelection(),e=e.getSelectedElement()||e.getStartElement()||a.editable(),e=a.elementPath(e),g=[0,0,0,0];this.showAll();this.unmarkAll();for(var c in d){var m=d[c],f=m._.type;m.checkApplicable(e,a,a.activeFilter)?g[f]++:this.hideItem(c);m.checkActive(e,a)&&this.mark(c)}g[CKEDITOR.STYLE_BLOCK]||this.hideGroup(b["panelTitle"+String(CKEDITOR.STYLE_BLOCK)]);g[CKEDITOR.STYLE_INLINE]||this.hideGroup(b["panelTitle"+String(CKEDITOR.STYLE_INLINE)]);
g[CKEDITOR.STYLE_OBJECT]||this.hideGroup(b["panelTitle"+String(CKEDITOR.STYLE_OBJECT)])},refresh:function(){var b=a.elementPath();if(b){for(var e in d)if(d[e].checkApplicable(b,a,a.activeFilter))return;this.setState(CKEDITOR.TRISTATE_DISABLED)}},reset:function(){d={};g=[]}})}})}(),function(){function a(a){return{editorFocus:!1,canUndo:!1,modes:{wysiwyg:1},exec:function(b){if(b.editable().hasFocus){var d=b.getSelection(),e;if(e=(new CKEDITOR.dom.elementPath(d.getCommonAncestor(),d.root)).contains({td:1,
th:1},1)){var d=b.createRange(),c=CKEDITOR.tools.tryThese(function(){var b=e.getParent().$.cells[e.$.cellIndex+(a?-1:1)];b.parentNode.parentNode;return b},function(){var b=e.getParent(),b=b.getAscendant("table").$.rows[b.$.rowIndex+(a?-1:1)];return b.cells[a?b.cells.length-1:0]});if(c||a)if(c)c=new CKEDITOR.dom.element(c),d.moveToElementEditStart(c),d.checkStartOfBlock()&&d.checkEndOfBlock()||d.selectNodeContents(c);else return!0;else{for(var m=e.getAscendant("table").$,c=e.getParent().$.cells,m=
new CKEDITOR.dom.element(m.insertRow(-1),b.document),f=0,n=c.length;f<n;f++)m.append((new CKEDITOR.dom.element(c[f],b.document)).clone(!1,!1)).appendBogus();d.moveToElementEditStart(m)}d.select(!0);return!0}}return!1}}}var e={editorFocus:!1,modes:{wysiwyg:1,source:1}},b={exec:function(a){a.container.focusNext(!0,a.tabIndex)}},d={exec:function(a){a.container.focusPrevious(!0,a.tabIndex)}};CKEDITOR.plugins.add("tab",{init:function(g){for(var l=!1!==g.config.enableTabKeyTools,k=g.config.tabSpaces||0,
h="";k--;)h+=" ";if(h)g.on("key",function(a){9==a.data.keyCode&&(g.insertText(h),a.cancel())});if(l)g.on("key",function(a){(9==a.data.keyCode&&g.execCommand("selectNextCell")||a.data.keyCode==CKEDITOR.SHIFT+9&&g.execCommand("selectPreviousCell"))&&a.cancel()});g.addCommand("blur",CKEDITOR.tools.extend(b,e));g.addCommand("blurBack",CKEDITOR.tools.extend(d,e));g.addCommand("selectNextCell",a());g.addCommand("selectPreviousCell",a(!0))}})}(),CKEDITOR.dom.element.prototype.focusNext=function(a,e){var b=
void 0===e?this.getTabIndex():e,d,g,l,k,h,c;if(0>=b)for(h=this.getNextSourceNode(a,CKEDITOR.NODE_ELEMENT);h;){if(h.isVisible()&&0===h.getTabIndex()){l=h;break}h=h.getNextSourceNode(!1,CKEDITOR.NODE_ELEMENT)}else for(h=this.getDocument().getBody().getFirst();h=h.getNextSourceNode(!1,CKEDITOR.NODE_ELEMENT);){if(!d)if(!g&&h.equals(this)){if(g=!0,a){if(!(h=h.getNextSourceNode(!0,CKEDITOR.NODE_ELEMENT)))break;d=1}}else g&&!this.contains(h)&&(d=1);if(h.isVisible()&&!(0>(c=h.getTabIndex()))){if(d&&c==b){l=
h;break}c>b&&(!l||!k||c<k)?(l=h,k=c):l||0!==c||(l=h,k=c)}}l&&l.focus()},CKEDITOR.dom.element.prototype.focusPrevious=function(a,e){for(var b=void 0===e?this.getTabIndex():e,d,g,l,k=0,h,c=this.getDocument().getBody().getLast();c=c.getPreviousSourceNode(!1,CKEDITOR.NODE_ELEMENT);){if(!d)if(!g&&c.equals(this)){if(g=!0,a){if(!(c=c.getPreviousSourceNode(!0,CKEDITOR.NODE_ELEMENT)))break;d=1}}else g&&!this.contains(c)&&(d=1);if(c.isVisible()&&!(0>(h=c.getTabIndex())))if(0>=b){if(d&&0===h){l=c;break}h>k&&
(l=c,k=h)}else{if(d&&h==b){l=c;break}h<b&&(!l||h>k)&&(l=c,k=h)}}l&&l.focus()},CKEDITOR.plugins.add("table",{requires:"dialog",init:function(a){function e(a){return CKEDITOR.tools.extend(a||{},{contextSensitive:1,refresh:function(a,b){this.setState(b.contains("table",1)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED)}})}if(!a.blockless){var b=a.lang.table;a.addCommand("table",new CKEDITOR.dialogCommand("table",{context:"table",allowedContent:"table{width,height}[align,border,cellpadding,cellspacing,summary];caption tbody thead tfoot;th td tr[scope];"+
(a.plugins.dialogadvtab?"table"+a.plugins.dialogadvtab.allowedContent():""),requiredContent:"table",contentTransformations:[["table{width}: sizeToStyle","table[width]: sizeToAttribute"],["td: splitBorderShorthand"],[{element:"table",right:function(a){if(a.styles){var b;if(a.styles.border)b=CKEDITOR.tools.style.parse.border(a.styles.border);else if(CKEDITOR.env.ie&&8===CKEDITOR.env.version){var e=a.styles;e["border-left"]&&e["border-left"]===e["border-right"]&&e["border-right"]===e["border-top"]&&
e["border-top"]===e["border-bottom"]&&(b=CKEDITOR.tools.style.parse.border(e["border-top"]))}b&&b.style&&"solid"===b.style&&b.width&&0!==parseFloat(b.width)&&(a.attributes.border=1);"collapse"==a.styles["border-collapse"]&&(a.attributes.cellspacing=0)}}}]]}));a.addCommand("tableProperties",new CKEDITOR.dialogCommand("tableProperties",e()));a.addCommand("tableDelete",e({exec:function(a){var b=a.elementPath().contains("table",1);if(b){var e=b.getParent(),k=a.editable();1!=e.getChildCount()||e.is("td",
"th")||e.equals(k)||(b=e);a=a.createRange();a.moveToPosition(b,CKEDITOR.POSITION_BEFORE_START);b.remove();a.select()}}}));a.ui.addButton&&a.ui.addButton("Table",{label:b.toolbar,command:"table",toolbar:"insert,30"});CKEDITOR.dialog.add("table",this.path+"dialogs/table.js");CKEDITOR.dialog.add("tableProperties",this.path+"dialogs/table.js");a.addMenuItems&&a.addMenuItems({table:{label:b.menu,command:"tableProperties",group:"table",order:5},tabledelete:{label:b.deleteTable,command:"tableDelete",group:"table",
order:1}});a.on("doubleclick",function(a){a.data.element.is("table")&&(a.data.dialog="tableProperties")});a.contextMenu&&a.contextMenu.addListener(function(){return{tabledelete:CKEDITOR.TRISTATE_OFF,table:CKEDITOR.TRISTATE_OFF}})}}}),function(){function a(a,b){function c(a){return b?b.contains(a)&&a.getAscendant("table",!0).equals(b):!0}function d(a){0<e.length||a.type!=CKEDITOR.NODE_ELEMENT||!v.test(a.getName())||a.getCustomData("selected_cell")||(CKEDITOR.dom.element.setMarker(f,a,"selected_cell",
!0),e.push(a))}var e=[],f={};if(!a)return e;for(var g=a.getRanges(),h=0;h<g.length;h++){var k=g[h];if(k.collapsed)(k=k.getCommonAncestor().getAscendant({td:1,th:1},!0))&&c(k)&&e.push(k);else{var k=new CKEDITOR.dom.walker(k),m;for(k.guard=d;m=k.next();)m.type==CKEDITOR.NODE_ELEMENT&&m.is(CKEDITOR.dtd.table)||(m=m.getAscendant({td:1,th:1},!0))&&!m.getCustomData("selected_cell")&&c(m)&&(CKEDITOR.dom.element.setMarker(f,m,"selected_cell",!0),e.push(m))}}CKEDITOR.dom.element.clearAllMarkers(f);return e}
function e(b,c){for(var d=y(b)?b:a(b),e=d[0],f=e.getAscendant("table"),e=e.getDocument(),g=d[0].getParent(),h=g.$.rowIndex,d=d[d.length-1],k=d.getParent().$.rowIndex+d.$.rowSpan-1,d=new CKEDITOR.dom.element(f.$.rows[k]),h=c?h:k,g=c?g:d,d=CKEDITOR.tools.buildTableMap(f),f=d[h],h=c?d[h-1]:d[h+1],d=d[0].length,e=e.createElement("tr"),k=0;f[k]&&k<d;k++){var m;1<f[k].rowSpan&&h&&f[k]==h[k]?(m=f[k],m.rowSpan+=1):(m=(new CKEDITOR.dom.element(f[k])).clone(),m.removeAttribute("rowSpan"),m.appendBogus(),e.append(m),
m=m.$);k+=m.colSpan-1}c?e.insertBefore(g):e.insertAfter(g);return e}function b(c){if(c instanceof CKEDITOR.dom.selection){var d=c.getRanges(),e=a(c),f=e[0].getAscendant("table"),g=CKEDITOR.tools.buildTableMap(f),h=e[0].getParent().$.rowIndex,e=e[e.length-1],k=e.getParent().$.rowIndex+e.$.rowSpan-1,e=[];c.reset();for(c=h;c<=k;c++){for(var m=g[c],l=new CKEDITOR.dom.element(f.$.rows[c]),n=0;n<m.length;n++){var p=new CKEDITOR.dom.element(m[n]),q=p.getParent().$.rowIndex;1==p.$.rowSpan?p.remove():(--p.$.rowSpan,
q==c&&(q=g[c+1],q[n-1]?p.insertAfter(new CKEDITOR.dom.element(q[n-1])):(new CKEDITOR.dom.element(f.$.rows[c+1])).append(p,1)));n+=p.$.colSpan-1}e.push(l)}g=f.$.rows;d[0].moveToPosition(f,CKEDITOR.POSITION_BEFORE_START);h=new CKEDITOR.dom.element(g[k+1]||(0<h?g[h-1]:null)||f.$.parentNode);for(c=e.length;0<=c;c--)b(e[c]);return f.$.parentNode?h:(d[0].select(),null)}c instanceof CKEDITOR.dom.element&&(f=c.getAscendant("table"),1==f.$.rows.length?f.remove():c.remove());return null}function d(a){for(var b=
a.getParent().$.cells,c=0,d=0;d<b.length;d++){var e=b[d],c=c+e.colSpan;if(e==a.$)break}return c-1}function g(a,b){for(var c=b?Infinity:0,e=0;e<a.length;e++){var f=d(a[e]);if(b?f<c:f>c)c=f}return c}function l(b,c){for(var d=y(b)?b:a(b),e=d[0].getAscendant("table"),f=g(d,1),d=g(d),h=c?f:d,k=CKEDITOR.tools.buildTableMap(e),e=[],f=[],d=[],m=k.length,l=0;l<m;l++)e.push(k[l][h]),f.push(c?k[l][h-1]:k[l][h+1]);for(l=0;l<m;l++)e[l]&&(1<e[l].colSpan&&f[l]==e[l]?(k=e[l],k.colSpan+=1):(h=new CKEDITOR.dom.element(e[l]),
k=h.clone(),k.removeAttribute("colSpan"),k.appendBogus(),k[c?"insertBefore":"insertAfter"].call(k,h),d.push(k),k=k.$),l+=k.rowSpan-1);return d}function k(b){function c(a){var b,d,e;b=a.getRanges();if(1!==b.length)return a;b=b[0];if(b.collapsed||0!==b.endOffset)return a;d=b.endContainer;e=d.getName().toLowerCase();if("td"!==e&&"th"!==e)return a;for((e=d.getPrevious())||(e=d.getParent().getPrevious().getLast());e.type!==CKEDITOR.NODE_TEXT&&"br"!==e.getName().toLowerCase();)if(e=e.getLast(),!e)return a;
b.setEndAt(e,CKEDITOR.POSITION_BEFORE_END);return b.select()}CKEDITOR.env.webkit&&!b.isFake&&(b=c(b));var d=b.getRanges(),e=a(b),f=e[0],g=e[e.length-1],e=f.getAscendant("table"),h=CKEDITOR.tools.buildTableMap(e),k,m,l=[];b.reset();var n=0;for(b=h.length;n<b;n++)for(var p=0,q=h[n].length;p<q;p++)void 0===k&&h[n][p]==f.$&&(k=p),h[n][p]==g.$&&(m=p);for(n=k;n<=m;n++)for(p=0;p<h.length;p++)g=h[p],f=new CKEDITOR.dom.element(e.$.rows[p]),g=new CKEDITOR.dom.element(g[n]),g.$&&(1==g.$.colSpan?g.remove():--g.$.colSpan,
p+=g.$.rowSpan-1,f.$.cells.length||l.push(f));k=h[0].length-1>m?new CKEDITOR.dom.element(h[0][m+1]):k&&-1!==h[0][k-1].cellIndex?new CKEDITOR.dom.element(h[0][k-1]):new CKEDITOR.dom.element(e.$.parentNode);l.length==b&&(d[0].moveToPosition(e,CKEDITOR.POSITION_AFTER_END),d[0].select(),e.remove());return k}function h(a,b){var c=a.getStartElement().getAscendant({td:1,th:1},!0);if(c){var d=c.clone();d.appendBogus();b?d.insertBefore(c):d.insertAfter(c)}}function c(b){if(b instanceof CKEDITOR.dom.selection){var d=
b.getRanges(),e=a(b),f=e[0]&&e[0].getAscendant("table"),g;a:{var h=0;g=e.length-1;for(var k={},l,n;l=e[h++];)CKEDITOR.dom.element.setMarker(k,l,"delete_cell",!0);for(h=0;l=e[h++];)if((n=l.getPrevious())&&!n.getCustomData("delete_cell")||(n=l.getNext())&&!n.getCustomData("delete_cell")){CKEDITOR.dom.element.clearAllMarkers(k);g=n;break a}CKEDITOR.dom.element.clearAllMarkers(k);h=e[0].getParent();(h=h.getPrevious())?g=h.getLast():(h=e[g].getParent(),g=(h=h.getNext())?h.getChild(0):null)}b.reset();for(b=
e.length-1;0<=b;b--)c(e[b]);g?m(g,!0):f&&(d[0].moveToPosition(f,CKEDITOR.POSITION_BEFORE_START),d[0].select(),f.remove())}else b instanceof CKEDITOR.dom.element&&(d=b.getParent(),1==d.getChildCount()?d.remove():b.remove())}function m(a,b){var c=a.getDocument(),d=CKEDITOR.document;CKEDITOR.env.ie&&10==CKEDITOR.env.version&&(d.focus(),c.focus());c=new CKEDITOR.dom.range(c);c["moveToElementEdit"+(b?"End":"Start")](a)||(c.selectNodeContents(a),c.collapse(b?!1:!0));c.select(!0)}function f(a,b,c){a=a[b];
if("undefined"==typeof c)return a;for(b=0;a&&b<a.length;b++){if(c.is&&a[b]==c.$)return b;if(b==c)return new CKEDITOR.dom.element(a[b])}return c.is?-1:null}function n(b,c,d){var e=a(b),g;if((c?1!=e.length:2>e.length)||(g=b.getCommonAncestor())&&g.type==CKEDITOR.NODE_ELEMENT&&g.is("table"))return!1;var h;b=e[0];g=b.getAscendant("table");var k=CKEDITOR.tools.buildTableMap(g),m=k.length,l=k[0].length,n=b.getParent().$.rowIndex,p=f(k,n,b);if(c){var q;try{var v=parseInt(b.getAttribute("rowspan"),10)||1;
h=parseInt(b.getAttribute("colspan"),10)||1;q=k["up"==c?n-v:"down"==c?n+v:n]["left"==c?p-h:"right"==c?p+h:p]}catch(y){return!1}if(!q||b.$==q)return!1;e["up"==c||"left"==c?"unshift":"push"](new CKEDITOR.dom.element(q))}c=b.getDocument();var M=n,v=q=0,K=!d&&new CKEDITOR.dom.documentFragment(c),D=0;for(c=0;c<e.length;c++){h=e[c];var R=h.getParent(),L=h.getFirst(),S=h.$.colSpan,N=h.$.rowSpan,R=R.$.rowIndex,V=f(k,R,h),D=D+S*N,v=Math.max(v,V-p+S);q=Math.max(q,R-n+N);d||(S=h,(N=S.getBogus())&&N.remove(),
S.trim(),h.getChildren().count()&&(R==M||!L||L.isBlockBoundary&&L.isBlockBoundary({br:1})||(M=K.getLast(CKEDITOR.dom.walker.whitespaces(!0)),!M||M.is&&M.is("br")||K.append("br")),h.moveChildren(K)),c?h.remove():h.setHtml(""));M=R}if(d)return q*v==D;K.moveChildren(b);b.appendBogus();v>=l?b.removeAttribute("rowSpan"):b.$.rowSpan=q;q>=m?b.removeAttribute("colSpan"):b.$.colSpan=v;d=new CKEDITOR.dom.nodeList(g.$.rows);e=d.count();for(c=e-1;0<=c;c--)g=d.getItem(c),g.$.cells.length||(g.remove(),e++);return b}
function p(b,c){var d=a(b);if(1<d.length)return!1;if(c)return!0;var d=d[0],e=d.getParent(),g=e.getAscendant("table"),h=CKEDITOR.tools.buildTableMap(g),k=e.$.rowIndex,m=f(h,k,d),l=d.$.rowSpan,n;if(1<l){n=Math.ceil(l/2);for(var l=Math.floor(l/2),e=k+n,g=new CKEDITOR.dom.element(g.$.rows[e]),h=f(h,e),p,e=d.clone(),k=0;k<h.length;k++)if(p=h[k],p.parentNode==g.$&&k>m){e.insertBefore(new CKEDITOR.dom.element(p));break}else p=null;p||g.append(e)}else for(l=n=1,g=e.clone(),g.insertAfter(e),g.append(e=d.clone()),
p=f(h,k),m=0;m<p.length;m++)p[m].rowSpan++;e.appendBogus();d.$.rowSpan=n;e.$.rowSpan=l;1==n&&d.removeAttribute("rowSpan");1==l&&e.removeAttribute("rowSpan");return e}function q(b,c){var d=a(b);if(1<d.length)return!1;if(c)return!0;var d=d[0],e=d.getParent(),g=e.getAscendant("table"),g=CKEDITOR.tools.buildTableMap(g),h=f(g,e.$.rowIndex,d),k=d.$.colSpan;if(1<k)e=Math.ceil(k/2),k=Math.floor(k/2);else{for(var k=e=1,m=[],l=0;l<g.length;l++){var n=g[l];m.push(n[h]);1<n[h].rowSpan&&(l+=n[h].rowSpan-1)}for(g=
0;g<m.length;g++)m[g].colSpan++}g=d.clone();g.insertAfter(d);g.appendBogus();d.$.colSpan=e;g.$.colSpan=k;1==e&&d.removeAttribute("colSpan");1==k&&g.removeAttribute("colSpan");return g}var v=/^(?:td|th)$/,y=CKEDITOR.tools.isArray;CKEDITOR.plugins.tabletools={requires:"table,dialog,contextmenu",init:function(d){function f(a){return CKEDITOR.tools.extend(a||{},{contextSensitive:1,refresh:function(a,b){this.setState(b.contains({td:1,th:1},1)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED)}})}function g(a,
b){var c=d.addCommand(a,b);d.addFeature(c)}var v=d.lang.table,y=CKEDITOR.tools.style.parse;g("cellProperties",new CKEDITOR.dialogCommand("cellProperties",f({allowedContent:"td th{width,height,border-color,background-color,white-space,vertical-align,text-align}[colspan,rowspan]",requiredContent:"table",contentTransformations:[[{element:"td",left:function(a){return a.styles.background&&y.background(a.styles.background).color},right:function(a){a.styles["background-color"]=y.background(a.styles.background).color}},
{element:"td",check:"td{vertical-align}",left:function(a){return a.attributes&&a.attributes.valign},right:function(a){a.styles["vertical-align"]=a.attributes.valign;delete a.attributes.valign}}],[{element:"tr",check:"td{height}",left:function(a){return a.styles&&a.styles.height},right:function(a){CKEDITOR.tools.array.forEach(a.children,function(b){b.name in{td:1,th:1}&&(b.attributes["cke-row-height"]=a.styles.height)});delete a.styles.height}}],[{element:"td",check:"td{height}",left:function(a){return(a=
a.attributes)&&a["cke-row-height"]},right:function(a){a.styles.height=a.attributes["cke-row-height"];delete a.attributes["cke-row-height"]}}]]})));CKEDITOR.dialog.add("cellProperties",this.path+"dialogs/tableCell.js");g("rowDelete",f({requiredContent:"table",exec:function(a){a=a.getSelection();(a=b(a))&&m(a)}}));g("rowInsertBefore",f({requiredContent:"table",exec:function(b){b=b.getSelection();b=a(b);e(b,!0)}}));g("rowInsertAfter",f({requiredContent:"table",exec:function(b){b=b.getSelection();b=a(b);
e(b)}}));g("columnDelete",f({requiredContent:"table",exec:function(a){a=a.getSelection();(a=k(a))&&m(a,!0)}}));g("columnInsertBefore",f({requiredContent:"table",exec:function(b){b=b.getSelection();b=a(b);l(b,!0)}}));g("columnInsertAfter",f({requiredContent:"table",exec:function(b){b=b.getSelection();b=a(b);l(b)}}));g("cellDelete",f({requiredContent:"table",exec:function(a){a=a.getSelection();c(a)}}));g("cellMerge",f({allowedContent:"td[colspan,rowspan]",requiredContent:"td[colspan,rowspan]",exec:function(a,
b){b.cell=n(a.getSelection());m(b.cell,!0)}}));g("cellMergeRight",f({allowedContent:"td[colspan]",requiredContent:"td[colspan]",exec:function(a,b){b.cell=n(a.getSelection(),"right");m(b.cell,!0)}}));g("cellMergeDown",f({allowedContent:"td[rowspan]",requiredContent:"td[rowspan]",exec:function(a,b){b.cell=n(a.getSelection(),"down");m(b.cell,!0)}}));g("cellVerticalSplit",f({allowedContent:"td[rowspan]",requiredContent:"td[rowspan]",exec:function(a){m(q(a.getSelection()))}}));g("cellHorizontalSplit",
f({allowedContent:"td[colspan]",requiredContent:"td[colspan]",exec:function(a){m(p(a.getSelection()))}}));g("cellInsertBefore",f({requiredContent:"table",exec:function(a){a=a.getSelection();h(a,!0)}}));g("cellInsertAfter",f({requiredContent:"table",exec:function(a){a=a.getSelection();h(a)}}));d.addMenuItems&&d.addMenuItems({tablecell:{label:v.cell.menu,group:"tablecell",order:1,getItems:function(){var b=d.getSelection(),c=a(b);return{tablecell_insertBefore:CKEDITOR.TRISTATE_OFF,tablecell_insertAfter:CKEDITOR.TRISTATE_OFF,
tablecell_delete:CKEDITOR.TRISTATE_OFF,tablecell_merge:n(b,null,!0)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,tablecell_merge_right:n(b,"right",!0)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,tablecell_merge_down:n(b,"down",!0)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,tablecell_split_vertical:q(b,!0)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,tablecell_split_horizontal:p(b,!0)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,tablecell_properties:0<c.length?CKEDITOR.TRISTATE_OFF:
CKEDITOR.TRISTATE_DISABLED}}},tablecell_insertBefore:{label:v.cell.insertBefore,group:"tablecell",command:"cellInsertBefore",order:5},tablecell_insertAfter:{label:v.cell.insertAfter,group:"tablecell",command:"cellInsertAfter",order:10},tablecell_delete:{label:v.cell.deleteCell,group:"tablecell",command:"cellDelete",order:15},tablecell_merge:{label:v.cell.merge,group:"tablecell",command:"cellMerge",order:16},tablecell_merge_right:{label:v.cell.mergeRight,group:"tablecell",command:"cellMergeRight",
order:17},tablecell_merge_down:{label:v.cell.mergeDown,group:"tablecell",command:"cellMergeDown",order:18},tablecell_split_horizontal:{label:v.cell.splitHorizontal,group:"tablecell",command:"cellHorizontalSplit",order:19},tablecell_split_vertical:{label:v.cell.splitVertical,group:"tablecell",command:"cellVerticalSplit",order:20},tablecell_properties:{label:v.cell.title,group:"tablecellproperties",command:"cellProperties",order:21},tablerow:{label:v.row.menu,group:"tablerow",order:1,getItems:function(){return{tablerow_insertBefore:CKEDITOR.TRISTATE_OFF,
tablerow_insertAfter:CKEDITOR.TRISTATE_OFF,tablerow_delete:CKEDITOR.TRISTATE_OFF}}},tablerow_insertBefore:{label:v.row.insertBefore,group:"tablerow",command:"rowInsertBefore",order:5},tablerow_insertAfter:{label:v.row.insertAfter,group:"tablerow",command:"rowInsertAfter",order:10},tablerow_delete:{label:v.row.deleteRow,group:"tablerow",command:"rowDelete",order:15},tablecolumn:{label:v.column.menu,group:"tablecolumn",order:1,getItems:function(){return{tablecolumn_insertBefore:CKEDITOR.TRISTATE_OFF,
tablecolumn_insertAfter:CKEDITOR.TRISTATE_OFF,tablecolumn_delete:CKEDITOR.TRISTATE_OFF}}},tablecolumn_insertBefore:{label:v.column.insertBefore,group:"tablecolumn",command:"columnInsertBefore",order:5},tablecolumn_insertAfter:{label:v.column.insertAfter,group:"tablecolumn",command:"columnInsertAfter",order:10},tablecolumn_delete:{label:v.column.deleteColumn,group:"tablecolumn",command:"columnDelete",order:15}});d.contextMenu&&d.contextMenu.addListener(function(a,b,c){return(a=c.contains({td:1,th:1},
1))&&!a.isReadOnly()?{tablecell:CKEDITOR.TRISTATE_OFF,tablerow:CKEDITOR.TRISTATE_OFF,tablecolumn:CKEDITOR.TRISTATE_OFF}:null})},getCellColIndex:d,insertRow:e,insertColumn:l,getSelectedCells:a};CKEDITOR.plugins.add("tabletools",CKEDITOR.plugins.tabletools)}(),CKEDITOR.tools.buildTableMap=function(a,e,b,d,g){a=a.$.rows;b=b||0;d="number"===typeof d?d:a.length-1;g="number"===typeof g?g:-1;var l=-1,k=[];for(e=e||0;e<=d;e++){l++;!k[l]&&(k[l]=[]);for(var h=-1,c=b;c<=(-1===g?a[e].cells.length-1:g);c++){var m=
a[e].cells[c];if(!m)break;for(h++;k[l][h];)h++;for(var f=isNaN(m.colSpan)?1:m.colSpan,m=isNaN(m.rowSpan)?1:m.rowSpan,n=0;n<m&&!(e+n>d);n++){k[l+n]||(k[l+n]=[]);for(var p=0;p<f;p++)k[l+n][h+p]=a[e].cells[c]}h+=f-1;if(-1!==g&&h>=g)break}}return k},function(){function a(a){return CKEDITOR.plugins.widget&&CKEDITOR.plugins.widget.isDomWidget(a)}function e(a,b){var c=a.getAscendant("table"),d=b.getAscendant("table"),e=CKEDITOR.tools.buildTableMap(c),f=m(a),g=m(b),h=[],k={},l,n;c.contains(d)&&(b=b.getAscendant({td:1,
th:1}),g=m(b));f>g&&(c=f,f=g,g=c,c=a,a=b,b=c);for(c=0;c<e[f].length;c++)if(a.$===e[f][c]){l=c;break}for(c=0;c<e[g].length;c++)if(b.$===e[g][c]){n=c;break}l>n&&(c=l,l=n,n=c);for(c=f;c<=g;c++)for(f=l;f<=n;f++)d=new CKEDITOR.dom.element(e[c][f]),d.$&&!d.getCustomData("selected_cell")&&(h.push(d),CKEDITOR.dom.element.setMarker(k,d,"selected_cell",!0));CKEDITOR.dom.element.clearAllMarkers(k);return h}function b(a){if(a)return a=a.clone(),a.enlarge(CKEDITOR.ENLARGE_ELEMENT),(a=a.getEnclosedNode())&&a.is&&
a.is(CKEDITOR.dtd.$tableContent)}function d(a){return(a=a.editable().findOne(".cke_table-faked-selection"))&&a.getAscendant("table")}function g(a,b){var c=a.editable().find(".cke_table-faked-selection"),d;a.fire("lockSnapshot");a.editable().removeClass("cke_table-faked-selection-editor");for(d=0;d<c.count();d++)c.getItem(d).removeClass("cke_table-faked-selection");0<c.count()&&c.getItem(0).getAscendant("table").data("cke-table-faked-selection-table",!1);a.fire("unlockSnapshot");b&&(r={active:!1},
a.getSelection().isInTable()&&a.getSelection().reset())}function l(a,b){var c=[],d,e;for(e=0;e<b.length;e++)d=a.createRange(),d.setStartBefore(b[e]),d.setEndAfter(b[e]),c.push(d);a.getSelection().selectRanges(c)}function k(a){var b=a.editable().find(".cke_table-faked-selection");1>b.count()||(b=e(b.getItem(0),b.getItem(b.count()-1)),l(a,b))}function h(b,c,d){var f=w(b.getSelection(!0));c=c.is("table")?null:c;var h;(h=r.active&&!r.first)&&!(h=c)&&(h=b.getSelection().getRanges(),h=1<f.length||h[0]&&
!h[0].collapsed?!0:!1);if(h)r.first=c||f[0],r.dirty=c?!1:1!==f.length;else if(r.active&&c&&r.first.getAscendant("table").equals(c.getAscendant("table"))){f=e(r.first,c);if(!r.dirty&&1===f.length&&!a(d.data.getTarget()))return g(b,"mouseup"===d.name);r.dirty=!0;r.last=c;l(b,f)}}function c(a){var b=(a=a.editor||a.sender.editor)&&a.getSelection(),c=b&&b.getRanges()||[],d;if(b&&(g(a),b.isInTable()&&b.isFake)){1===c.length&&c[0]._getTableElement()&&c[0]._getTableElement().is("table")&&(d=c[0]._getTableElement());
d=w(b,d);a.fire("lockSnapshot");for(b=0;b<d.length;b++)d[b].addClass("cke_table-faked-selection");0<d.length&&(a.editable().addClass("cke_table-faked-selection-editor"),d[0].getAscendant("table").data("cke-table-faked-selection-table",""));a.fire("unlockSnapshot")}}function m(a){return a.getAscendant("tr",!0).$.rowIndex}function f(b){function c(a,b){return a&&b?a.equals(b)||a.contains(b)||b.contains(a)||a.getCommonAncestor(b).is(t):!1}function e(a){return!a.getAscendant("table",!0)&&a.getDocument().equals(l.document)}
function m(a,b,d,f){return("mousedown"!==a.name||CKEDITOR.tools.getMouseButton(a)!==CKEDITOR.MOUSE_BUTTON_LEFT&&f)&&("mouseup"!==a.name||e(a.data.getTarget())||c(d,f))?!1:!0}if(b.data.getTarget().getName&&("mouseup"===b.name||!a(b.data.getTarget()))){var l=b.editor||b.listenerData.editor,n=l.getSelection(1),p=d(l),q=b.data.getTarget(),v=q&&q.getAscendant({td:1,th:1},!0),q=q&&q.getAscendant("table",!0),t={table:1,thead:1,tbody:1,tfoot:1,tr:1,td:1,th:1};m(b,n,p,q)&&g(l,!0);!r.active&&"mousedown"===
b.name&&CKEDITOR.tools.getMouseButton(b)===CKEDITOR.MOUSE_BUTTON_LEFT&&q&&(r={active:!0},CKEDITOR.document.on("mouseup",f,null,{editor:l}));(v||q)&&h(l,v||q,b);"mouseup"===b.name&&(CKEDITOR.tools.getMouseButton(b)===CKEDITOR.MOUSE_BUTTON_LEFT&&(e(b.data.getTarget())||c(p,q))&&k(l),r={active:!1},CKEDITOR.document.removeListener("mouseup",f))}}function n(a){var b=a.data.getTarget().getAscendant({td:1,th:1},!0);b&&!b.hasClass("cke_table-faked-selection")&&(a.cancel(),a.data.preventDefault())}function p(a,
b){function c(a){a.cancel()}var d=a.getSelection(),e=d.createBookmarks(),f=a.document,g=a.createRange(),h=f.getDocumentElement().$,k=CKEDITOR.env.ie&&9>CKEDITOR.env.version,m=a.blockless||CKEDITOR.env.ie?"span":"div",l,n,p,q;f.getById("cke_table_copybin")||(l=f.createElement(m),n=f.createElement(m),n.setAttributes({id:"cke_table_copybin","data-cke-temp":"1"}),l.setStyles({position:"absolute",width:"1px",height:"1px",overflow:"hidden"}),l.setStyle("ltr"==a.config.contentsLangDirection?"left":"right",
"-5000px"),l.setHtml(a.getSelectedHtml(!0)),a.fire("lockSnapshot"),n.append(l),a.editable().append(n),q=a.on("selectionChange",c,null,null,0),k&&(p=h.scrollTop),g.selectNodeContents(l),g.select(),k&&(h.scrollTop=p),setTimeout(function(){n.remove();d.selectBookmarks(e);q.removeListener();a.fire("unlockSnapshot");b&&(a.extractSelectedHtml(),a.fire("saveSnapshot"))},100))}function q(a){var b=a.editor||a.sender.editor;b.getSelection().isInTable()&&p(b,"cut"===a.name)}function v(a){this._reset();a&&this.setSelectedCells(a)}
function y(a,b,c){a.on("beforeCommandExec",function(c){-1!==CKEDITOR.tools.array.indexOf(b,c.data.name)&&(c.data.selectedCells=w(a.getSelection()))});a.on("afterCommandExec",function(d){-1!==CKEDITOR.tools.array.indexOf(b,d.data.name)&&c(a,d.data)})}var r={active:!1},t,w,A,x,u;v.prototype={};v.prototype._reset=function(){this.cells={first:null,last:null,all:[]};this.rows={first:null,last:null}};v.prototype.setSelectedCells=function(a){this._reset();a=a.slice(0);this._arraySortByDOMOrder(a);this.cells.all=
a;this.cells.first=a[0];this.cells.last=a[a.length-1];this.rows.first=a[0].getAscendant("tr");this.rows.last=this.cells.last.getAscendant("tr")};v.prototype.getTableMap=function(){var a=A(this.cells.first),b;a:{b=this.cells.last;var c=b.getAscendant("table"),d=m(b),c=CKEDITOR.tools.buildTableMap(c),e;for(e=0;e<c[d].length;e++)if((new CKEDITOR.dom.element(c[d][e])).equals(b)){b=e;break a}b=void 0}return CKEDITOR.tools.buildTableMap(this._getTable(),m(this.rows.first),a,m(this.rows.last),b)};v.prototype._getTable=
function(){return this.rows.first.getAscendant("table")};v.prototype.insertRow=function(a,b,c){if("undefined"===typeof a)a=1;else if(0>=a)return;for(var d=this.cells.first.$.cellIndex,e=this.cells.last.$.cellIndex,f=c?[]:this.cells.all,g,h=0;h<a;h++)g=x(c?this.cells.all:f,b),g=CKEDITOR.tools.array.filter(g.find("td, th").toArray(),function(a){return c?!0:a.$.cellIndex>=d&&a.$.cellIndex<=e}),f=b?g.concat(f):f.concat(g);this.setSelectedCells(f)};v.prototype.insertColumn=function(a){function b(a){a=
m(a);return a>=e&&a<=f}if("undefined"===typeof a)a=1;else if(0>=a)return;for(var c=this.cells,d=c.all,e=m(c.first),f=m(c.last),c=0;c<a;c++)d=d.concat(CKEDITOR.tools.array.filter(u(d),b));this.setSelectedCells(d)};v.prototype.emptyCells=function(a){a=a||this.cells.all;for(var b=0;b<a.length;b++)a[b].setHtml("")};v.prototype._arraySortByDOMOrder=function(a){a.sort(function(a,b){return a.getPosition(b)&CKEDITOR.POSITION_PRECEDING?-1:1})};var C={onPaste:function(a){function c(a){return Math.max.apply(null,
CKEDITOR.tools.array.map(a,function(a){return a.length},0))}function d(a){var b=f.createRange();b.selectNodeContents(a);b.select()}var f=a.editor,g=f.getSelection(),h=w(g),k=this.findTableInPastedContent(f,a.data.dataValue),m=g.isInTable(!0)&&this.isBoundarySelection(g),n,p;!h.length||1===h.length&&!b(g.getRanges()[0])&&!m||m&&!k||(h=h[0].getAscendant("table"),n=new v(w(g,h)),f.once("afterPaste",function(){var a;if(p){a=new CKEDITOR.dom.element(p[0][0]);var b=p[p.length-1];a=e(a,new CKEDITOR.dom.element(b[b.length-
1]))}else a=n.cells.all;l(f,a)}),k?(a.stop(),m?(n.insertRow(1,1===m,!0),g.selectElement(n.rows.first)):(n.emptyCells(),l(f,n.cells.all)),a=n.getTableMap(),p=CKEDITOR.tools.buildTableMap(k),n.insertRow(p.length-a.length),n.insertColumn(c(p)-c(a)),a=n.getTableMap(),this.pasteTable(n,a,p),f.fire("saveSnapshot"),setTimeout(function(){f.fire("afterPaste")},0)):(d(n.cells.first),f.once("afterPaste",function(){f.fire("lockSnapshot");n.emptyCells(n.cells.all.slice(1));l(f,n.cells.all);f.fire("unlockSnapshot")})))},
isBoundarySelection:function(a){a=a.getRanges()[0];var b=a.endContainer.getAscendant("tr",!0);if(b&&a.collapsed){if(a.checkBoundaryOfElement(b,CKEDITOR.START))return 1;if(a.checkBoundaryOfElement(b,CKEDITOR.END))return 2}return 0},findTableInPastedContent:function(a,b){var c=a.dataProcessor,d=new CKEDITOR.dom.element("body");c||(c=new CKEDITOR.htmlDataProcessor(a));d.setHtml(c.toHtml(b),{fixForBody:!1});return 1<d.getChildCount()?null:d.findOne("table")},pasteTable:function(a,b,c){var d,e=A(a.cells.first),
f=a._getTable(),g={},h,k,m,l;for(m=0;m<c.length;m++)for(h=new CKEDITOR.dom.element(f.$.rows[a.rows.first.$.rowIndex+m]),l=0;l<c[m].length;l++)if(k=new CKEDITOR.dom.element(c[m][l]),d=b[m]&&b[m][l]?new CKEDITOR.dom.element(b[m][l]):null,k&&!k.getCustomData("processed")){if(d&&d.getParent())k.replace(d);else if(0===l||c[m][l-1])(d=0!==l?new CKEDITOR.dom.element(c[m][l-1]):null)&&h.equals(d.getParent())?k.insertAfter(d):0<e?h.$.cells[e]?k.insertAfter(new CKEDITOR.dom.element(h.$.cells[e])):h.append(k):
h.append(k,!0);CKEDITOR.dom.element.setMarker(g,k,"processed",!0)}else k.getCustomData("processed")&&d&&d.remove();CKEDITOR.dom.element.clearAllMarkers(g)}};CKEDITOR.plugins.tableselection={getCellsBetween:e,keyboardIntegration:function(a){function b(a){var c=a.getEnclosedNode();c&&c.is({td:1,th:1})?a.getEnclosedNode().setText(""):a.deleteContents();CKEDITOR.tools.array.forEach(a._find("td"),function(a){a.appendBogus()})}var c=a.editable();c.attachListener(c,"keydown",function(a){function c(b,d){if(!d.length)return null;
var f=a.createRange(),g=CKEDITOR.dom.range.mergeRanges(d);CKEDITOR.tools.array.forEach(g,function(a){a.enlarge(CKEDITOR.ENLARGE_ELEMENT)});var h=g[0].getBoundaryNodes(),k=h.startNode,h=h.endNode;if(k&&k.is&&k.is(e)){for(var m=k.getAscendant("table",!0),l=k.getPreviousSourceNode(!1,CKEDITOR.NODE_ELEMENT,m),n=!1,p=function(a){return!k.contains(a)&&a.is&&a.is("td","th")};l&&!p(l);)l=l.getPreviousSourceNode(!1,CKEDITOR.NODE_ELEMENT,m);!l&&h&&h.is&&!h.is("table")&&h.getNext()&&(l=h.getNext().findOne("td, th"),
n=!0);if(l)f["moveToElementEdit"+(n?"Start":"End")](l);else f.setStartBefore(k.getAscendant("table",!0)),f.collapse(!0);g[0].deleteContents();return[f]}if(k)return f.moveToElementEditablePosition(k),[f]}var d={37:1,38:1,39:1,40:1,8:1,46:1},e=CKEDITOR.tools.extend({table:1},CKEDITOR.dtd.$tableContent);delete e.td;delete e.th;return function(e){var f=e.data.getKey(),g,h=37===f||38==f,k,m,l;if(d[f]&&(g=a.getSelection())&&g.isInTable()&&g.isFake)if(k=g.getRanges(),m=k[0]._getTableElement(),l=k[k.length-
1]._getTableElement(),e.data.preventDefault(),e.cancel(),8<f&&46>f)k[0].moveToElementEditablePosition(h?m:l,!h),g.selectRanges([k[0]]);else{for(e=0;e<k.length;e++)b(k[e]);(e=c(m,k))?k=e:k[0].moveToElementEditablePosition(m);g.selectRanges(k);a.fire("saveSnapshot")}}}(a),null,null,-1);c.attachListener(c,"keypress",function(c){var d=a.getSelection(),e=c.data.$.charCode||13===c.data.getKey(),f;if(d&&d.isInTable()&&d.isFake&&e&&!(c.data.getKeystroke()&CKEDITOR.CTRL)){c=d.getRanges();e=c[0].getEnclosedNode().getAscendant({td:1,
th:1},!0);for(f=0;f<c.length;f++)b(c[f]);e&&(c[0].moveToElementEditablePosition(e),d.selectRanges([c[0]]))}},null,null,-1)},isSupportedEnvironment:!(CKEDITOR.env.ie&&11>CKEDITOR.env.version)};CKEDITOR.plugins.add("tableselection",{requires:"clipboard,tabletools",onLoad:function(){t=CKEDITOR.plugins.tabletools;w=t.getSelectedCells;A=t.getCellColIndex;x=t.insertRow;u=t.insertColumn;CKEDITOR.document.appendStyleSheet(this.path+"styles/tableselection.css")},init:function(a){CKEDITOR.plugins.tableselection.isSupportedEnvironment&&
(a.addContentsCss&&a.addContentsCss(this.path+"styles/tableselection.css"),a.on("contentDom",function(){var b=a.editable(),d=b.isInline()?b:a.document,e={editor:a};b.attachListener(d,"mousedown",f,null,e);b.attachListener(d,"mousemove",f,null,e);b.attachListener(d,"mouseup",f,null,e);b.attachListener(b,"dragstart",n);b.attachListener(a,"selectionCheck",c);CKEDITOR.plugins.tableselection.keyboardIntegration(a);CKEDITOR.plugins.clipboard&&!CKEDITOR.plugins.clipboard.isCustomCopyCutSupported&&(b.attachListener(b,
"cut",q),b.attachListener(b,"copy",q))}),a.on("paste",C.onPaste,C),y(a,"rowInsertBefore rowInsertAfter columnInsertBefore columnInsertAfter cellInsertBefore cellInsertAfter".split(" "),function(a,b){l(a,b.selectedCells)}),y(a,["cellMerge","cellMergeRight","cellMergeDown"],function(a,b){l(a,[b.commandData.cell])}),y(a,["cellDelete"],function(a){g(a,!0)}))}})}(),"use strict",function(){var a=[CKEDITOR.CTRL+90,CKEDITOR.CTRL+89,CKEDITOR.CTRL+CKEDITOR.SHIFT+90],e={8:1,46:1};CKEDITOR.plugins.add("undo",
{init:function(d){function c(a){f.enabled&&!1!==a.data.command.canUndo&&f.save()}function e(){f.enabled=d.readOnly?!1:"wysiwyg"==d.mode;f.onChange()}var f=d.undoManager=new b(d),g=f.editingHandler=new l(f),k=d.addCommand("undo",{exec:function(){f.undo()&&(d.selectionChange(),this.fire("afterUndo"))},startDisabled:!0,canUndo:!1}),q=d.addCommand("redo",{exec:function(){f.redo()&&(d.selectionChange(),this.fire("afterRedo"))},startDisabled:!0,canUndo:!1});d.setKeystroke([[a[0],"undo"],[a[1],"redo"],[a[2],
"redo"]]);f.onChange=function(){k.setState(f.undoable()?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED);q.setState(f.redoable()?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED)};d.on("beforeCommandExec",c);d.on("afterCommandExec",c);d.on("saveSnapshot",function(a){f.save(a.data&&a.data.contentOnly)});d.on("contentDom",g.attachListeners,g);d.on("instanceReady",function(){d.fire("saveSnapshot")});d.on("beforeModeUnload",function(){"wysiwyg"==d.mode&&f.save(!0)});d.on("mode",e);d.on("readOnly",e);
d.ui.addButton&&(d.ui.addButton("Undo",{label:d.lang.undo.undo,command:"undo",toolbar:"undo,10"}),d.ui.addButton("Redo",{label:d.lang.undo.redo,command:"redo",toolbar:"undo,20"}));d.resetUndo=function(){f.reset();d.fire("saveSnapshot")};d.on("updateSnapshot",function(){f.currentImage&&f.update()});d.on("lockSnapshot",function(a){a=a.data;f.lock(a&&a.dontUpdate,a&&a.forceUpdate)});d.on("unlockSnapshot",f.unlock,f)}});CKEDITOR.plugins.undo={};var b=CKEDITOR.plugins.undo.UndoManager=function(a){this.strokesRecorded=
[0,0];this.locked=null;this.previousKeyGroup=-1;this.limit=a.config.undoStackSize||20;this.strokesLimit=25;this.editor=a;this.reset()};b.prototype={type:function(a,c){var d=b.getKeyGroup(a),e=this.strokesRecorded[d]+1;c=c||e>=this.strokesLimit;this.typing||(this.hasUndo=this.typing=!0,this.hasRedo=!1,this.onChange());c?(e=0,this.editor.fire("saveSnapshot")):this.editor.fire("change");this.strokesRecorded[d]=e;this.previousKeyGroup=d},keyGroupChanged:function(a){return b.getKeyGroup(a)!=this.previousKeyGroup},
reset:function(){this.snapshots=[];this.index=-1;this.currentImage=null;this.hasRedo=this.hasUndo=!1;this.locked=null;this.resetType()},resetType:function(){this.strokesRecorded=[0,0];this.typing=!1;this.previousKeyGroup=-1},refreshState:function(){this.hasUndo=!!this.getNextImage(!0);this.hasRedo=!!this.getNextImage(!1);this.resetType();this.onChange()},save:function(a,b,e){var f=this.editor;if(this.locked||"ready"!=f.status||"wysiwyg"!=f.mode)return!1;var g=f.editable();if(!g||"ready"!=g.status)return!1;
g=this.snapshots;b||(b=new d(f));if(!1===b.contents)return!1;if(this.currentImage)if(b.equalsContent(this.currentImage)){if(a||b.equalsSelection(this.currentImage))return!1}else!1!==e&&f.fire("change");g.splice(this.index+1,g.length-this.index-1);g.length==this.limit&&g.shift();this.index=g.push(b)-1;this.currentImage=b;!1!==e&&this.refreshState();return!0},restoreImage:function(a){var b=this.editor,d;a.bookmarks&&(b.focus(),d=b.getSelection());this.locked={level:999};this.editor.loadSnapshot(a.contents);
a.bookmarks?d.selectBookmarks(a.bookmarks):CKEDITOR.env.ie&&(d=this.editor.document.getBody().$.createTextRange(),d.collapse(!0),d.select());this.locked=null;this.index=a.index;this.currentImage=this.snapshots[this.index];this.update();this.refreshState();b.fire("change")},getNextImage:function(a){var b=this.snapshots,d=this.currentImage,e;if(d)if(a)for(e=this.index-1;0<=e;e--){if(a=b[e],!d.equalsContent(a))return a.index=e,a}else for(e=this.index+1;e<b.length;e++)if(a=b[e],!d.equalsContent(a))return a.index=
e,a;return null},redoable:function(){return this.enabled&&this.hasRedo},undoable:function(){return this.enabled&&this.hasUndo},undo:function(){if(this.undoable()){this.save(!0);var a=this.getNextImage(!0);if(a)return this.restoreImage(a),!0}return!1},redo:function(){if(this.redoable()&&(this.save(!0),this.redoable())){var a=this.getNextImage(!1);if(a)return this.restoreImage(a),!0}return!1},update:function(a){if(!this.locked){a||(a=new d(this.editor));for(var b=this.index,e=this.snapshots;0<b&&this.currentImage.equalsContent(e[b-
1]);)--b;e.splice(b,this.index-b+1,a);this.index=b;this.currentImage=a}},updateSelection:function(a){if(!this.snapshots.length)return!1;var b=this.snapshots,d=b[b.length-1];return d.equalsContent(a)&&!d.equalsSelection(a)?(this.currentImage=b[b.length-1]=a,!0):!1},lock:function(a,b){if(this.locked)this.locked.level++;else if(a)this.locked={level:1};else{var e=null;if(b)e=!0;else{var f=new d(this.editor,!0);this.currentImage&&this.currentImage.equalsContent(f)&&(e=f)}this.locked={update:e,level:1}}},
unlock:function(){if(this.locked&&!--this.locked.level){var a=this.locked.update;this.locked=null;if(!0===a)this.update();else if(a){var b=new d(this.editor,!0);a.equalsContent(b)||this.update()}}}};b.navigationKeyCodes={37:1,38:1,39:1,40:1,36:1,35:1,33:1,34:1};b.keyGroups={PRINTABLE:0,FUNCTIONAL:1};b.isNavigationKey=function(a){return!!b.navigationKeyCodes[a]};b.getKeyGroup=function(a){var c=b.keyGroups;return e[a]?c.FUNCTIONAL:c.PRINTABLE};b.getOppositeKeyGroup=function(a){var c=b.keyGroups;return a==
c.FUNCTIONAL?c.PRINTABLE:c.FUNCTIONAL};b.ieFunctionalKeysBug=function(a){return CKEDITOR.env.ie&&b.getKeyGroup(a)==b.keyGroups.FUNCTIONAL};var d=CKEDITOR.plugins.undo.Image=function(a,b){this.editor=a;a.fire("beforeUndoImage");var d=a.getSnapshot();CKEDITOR.env.ie&&d&&(d=d.replace(/\s+data-cke-expando=".*?"/g,""));this.contents=d;b||(this.bookmarks=(d=d&&a.getSelection())&&d.createBookmarks2(!0));a.fire("afterUndoImage")},g=/\b(?:href|src|name)="[^"]*?"/gi;d.prototype={equalsContent:function(a){var b=
this.contents;a=a.contents;CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)&&(b=b.replace(g,""),a=a.replace(g,""));return b!=a?!1:!0},equalsSelection:function(a){var b=this.bookmarks;a=a.bookmarks;if(b||a){if(!b||!a||b.length!=a.length)return!1;for(var d=0;d<b.length;d++){var e=b[d],g=a[d];if(e.startOffset!=g.startOffset||e.endOffset!=g.endOffset||!CKEDITOR.tools.arrayCompare(e.start,g.start)||!CKEDITOR.tools.arrayCompare(e.end,g.end))return!1}}return!0}};var l=CKEDITOR.plugins.undo.NativeEditingHandler=
function(a){this.undoManager=a;this.ignoreInputEvent=!1;this.keyEventsStack=new k;this.lastKeydownImage=null};l.prototype={onKeydown:function(e){var c=e.data.getKey();if(229!==c)if(-1<CKEDITOR.tools.indexOf(a,e.data.getKeystroke()))e.data.preventDefault();else if(this.keyEventsStack.cleanUp(e),e=this.undoManager,this.keyEventsStack.getLast(c)||this.keyEventsStack.push(c),this.lastKeydownImage=new d(e.editor),b.isNavigationKey(c)||this.undoManager.keyGroupChanged(c))if(e.strokesRecorded[0]||e.strokesRecorded[1])e.save(!1,
this.lastKeydownImage,!1),e.resetType()},onInput:function(){if(this.ignoreInputEvent)this.ignoreInputEvent=!1;else{var a=this.keyEventsStack.getLast();a||(a=this.keyEventsStack.push(0));this.keyEventsStack.increment(a.keyCode);this.keyEventsStack.getTotalInputs()>=this.undoManager.strokesLimit&&(this.undoManager.type(a.keyCode,!0),this.keyEventsStack.resetInputs())}},onKeyup:function(a){var c=this.undoManager;a=a.data.getKey();var e=this.keyEventsStack.getTotalInputs();this.keyEventsStack.remove(a);
if(!(b.ieFunctionalKeysBug(a)&&this.lastKeydownImage&&this.lastKeydownImage.equalsContent(new d(c.editor,!0))))if(0<e)c.type(a);else if(b.isNavigationKey(a))this.onNavigationKey(!0)},onNavigationKey:function(a){var b=this.undoManager;!a&&b.save(!0,null,!1)||b.updateSelection(new d(b.editor));b.resetType()},ignoreInputEventListener:function(){this.ignoreInputEvent=!0},activateInputEventListener:function(){this.ignoreInputEvent=!1},attachListeners:function(){var a=this.undoManager.editor,c=a.editable(),
d=this;c.attachListener(c,"keydown",function(a){d.onKeydown(a);if(b.ieFunctionalKeysBug(a.data.getKey()))d.onInput()},null,null,999);c.attachListener(c,CKEDITOR.env.ie?"keypress":"input",d.onInput,d,null,999);c.attachListener(c,"keyup",d.onKeyup,d,null,999);c.attachListener(c,"paste",d.ignoreInputEventListener,d,null,999);c.attachListener(c,"drop",d.ignoreInputEventListener,d,null,999);a.on("afterPaste",d.activateInputEventListener,d,null,999);c.attachListener(c.isInline()?c:a.document.getDocumentElement(),
"click",function(){d.onNavigationKey()},null,null,999);c.attachListener(this.undoManager.editor,"blur",function(){d.keyEventsStack.remove(9)},null,null,999)}};var k=CKEDITOR.plugins.undo.KeyEventsStack=function(){this.stack=[]};k.prototype={push:function(a){a=this.stack.push({keyCode:a,inputs:0});return this.stack[a-1]},getLastIndex:function(a){if("number"!=typeof a)return this.stack.length-1;for(var b=this.stack.length;b--;)if(this.stack[b].keyCode==a)return b;return-1},getLast:function(a){a=this.getLastIndex(a);
return-1!=a?this.stack[a]:null},increment:function(a){this.getLast(a).inputs++},remove:function(a){a=this.getLastIndex(a);-1!=a&&this.stack.splice(a,1)},resetInputs:function(a){if("number"==typeof a)this.getLast(a).inputs=0;else for(a=this.stack.length;a--;)this.stack[a].inputs=0},getTotalInputs:function(){for(var a=this.stack.length,b=0;a--;)b+=this.stack[a].inputs;return b},cleanUp:function(a){a=a.data.$;a.ctrlKey||a.metaKey||this.remove(17);a.shiftKey||this.remove(16);a.altKey||this.remove(18)}}}(),
"use strict",function(){function a(a,b){CKEDITOR.tools.extend(this,{editor:a,editable:a.editable(),doc:a.document,win:a.window},b,!0);this.inline=this.editable.isInline();this.inline||(this.frame=this.win.getFrame());this.target=this[this.inline?"editable":"doc"]}function e(a,b){CKEDITOR.tools.extend(this,b,{editor:a},!0)}function b(a,b){var d=a.editable();CKEDITOR.tools.extend(this,{editor:a,editable:d,inline:d.isInline(),doc:a.document,win:a.window,container:CKEDITOR.document.getBody(),winTop:CKEDITOR.document.getWindow()},
b,!0);this.hidden={};this.visible={};this.inline||(this.frame=this.win.getFrame());this.queryViewport();var e=CKEDITOR.tools.bind(this.queryViewport,this),h=CKEDITOR.tools.bind(this.hideVisible,this),k=CKEDITOR.tools.bind(this.removeAll,this);d.attachListener(this.winTop,"resize",e);d.attachListener(this.winTop,"scroll",e);d.attachListener(this.winTop,"resize",h);d.attachListener(this.win,"scroll",h);d.attachListener(this.inline?d:this.frame,"mouseout",function(a){var b=a.data.$.clientX;a=a.data.$.clientY;
this.queryViewport();(b<=this.rect.left||b>=this.rect.right||a<=this.rect.top||a>=this.rect.bottom)&&this.hideVisible();(0>=b||b>=this.winTopPane.width||0>=a||a>=this.winTopPane.height)&&this.hideVisible()},this);d.attachListener(a,"resize",e);d.attachListener(a,"mode",k);a.on("destroy",k);this.lineTpl=(new CKEDITOR.template('\x3cdiv data-cke-lineutils-line\x3d"1" class\x3d"cke_reset_all" style\x3d"{lineStyle}"\x3e\x3cspan style\x3d"{tipLeftStyle}"\x3e\x26nbsp;\x3c/span\x3e\x3cspan style\x3d"{tipRightStyle}"\x3e\x26nbsp;\x3c/span\x3e\x3c/div\x3e')).output({lineStyle:CKEDITOR.tools.writeCssText(CKEDITOR.tools.extend({},
l,this.lineStyle,!0)),tipLeftStyle:CKEDITOR.tools.writeCssText(CKEDITOR.tools.extend({},g,{left:"0px","border-left-color":"red","border-width":"6px 0 6px 6px"},this.tipCss,this.tipLeftStyle,!0)),tipRightStyle:CKEDITOR.tools.writeCssText(CKEDITOR.tools.extend({},g,{right:"0px","border-right-color":"red","border-width":"6px 6px 6px 0"},this.tipCss,this.tipRightStyle,!0))})}function d(a){var b;if(b=a&&a.type==CKEDITOR.NODE_ELEMENT)b=!(k[a.getComputedStyle("float")]||k[a.getAttribute("align")]);return b&&
!h[a.getComputedStyle("position")]}CKEDITOR.plugins.add("lineutils");CKEDITOR.LINEUTILS_BEFORE=1;CKEDITOR.LINEUTILS_AFTER=2;CKEDITOR.LINEUTILS_INSIDE=4;a.prototype={start:function(a){var b=this,d=this.editor,e=this.doc,g,h,k,l,r=CKEDITOR.tools.eventsBuffer(50,function(){d.readOnly||"wysiwyg"!=d.mode||(b.relations={},(h=e.$.elementFromPoint(k,l))&&h.nodeType&&(g=new CKEDITOR.dom.element(h),b.traverseSearch(g),isNaN(k+l)||b.pixelSearch(g,k,l),a&&a(b.relations,k,l)))});this.listener=this.editable.attachListener(this.target,
"mousemove",function(a){k=a.data.$.clientX;l=a.data.$.clientY;r.input()});this.editable.attachListener(this.inline?this.editable:this.frame,"mouseout",function(){r.reset()})},stop:function(){this.listener&&this.listener.removeListener()},getRange:function(){var a={};a[CKEDITOR.LINEUTILS_BEFORE]=CKEDITOR.POSITION_BEFORE_START;a[CKEDITOR.LINEUTILS_AFTER]=CKEDITOR.POSITION_AFTER_END;a[CKEDITOR.LINEUTILS_INSIDE]=CKEDITOR.POSITION_AFTER_START;return function(b){var d=this.editor.createRange();d.moveToPosition(this.relations[b.uid].element,
a[b.type]);return d}}(),store:function(){function a(b,c,d){var e=b.getUniqueId();e in d?d[e].type|=c:d[e]={element:b,type:c}}return function(b,e){var g;e&CKEDITOR.LINEUTILS_AFTER&&d(g=b.getNext())&&g.isVisible()&&(a(g,CKEDITOR.LINEUTILS_BEFORE,this.relations),e^=CKEDITOR.LINEUTILS_AFTER);e&CKEDITOR.LINEUTILS_INSIDE&&d(g=b.getFirst())&&g.isVisible()&&(a(g,CKEDITOR.LINEUTILS_BEFORE,this.relations),e^=CKEDITOR.LINEUTILS_INSIDE);a(b,e,this.relations)}}(),traverseSearch:function(a){var b,e,g;do if(g=a.$["data-cke-expando"],
!(g&&g in this.relations)){if(a.equals(this.editable))break;if(d(a))for(b in this.lookups)(e=this.lookups[b](a))&&this.store(a,e)}while((!a||a.type!=CKEDITOR.NODE_ELEMENT||"true"!=a.getAttribute("contenteditable"))&&(a=a.getParent()))},pixelSearch:function(){function a(c,e,g,h,k){for(var l=0,r;k(g);){g+=h;if(25==++l)break;if(r=this.doc.$.elementFromPoint(e,g))if(r==c)l=0;else if(b(c,r)&&(l=0,d(r=new CKEDITOR.dom.element(r))))return r}}var b=CKEDITOR.env.ie||CKEDITOR.env.webkit?function(a,b){return a.contains(b)}:
function(a,b){return!!(a.compareDocumentPosition(b)&16)};return function(b,e,g){var h=this.win.getViewPaneSize().height,k=a.call(this,b.$,e,g,-1,function(a){return 0<a});e=a.call(this,b.$,e,g,1,function(a){return a<h});if(k)for(this.traverseSearch(k);!k.getParent().equals(b);)k=k.getParent();if(e)for(this.traverseSearch(e);!e.getParent().equals(b);)e=e.getParent();for(;k||e;){k&&(k=k.getNext(d));if(!k||k.equals(e))break;this.traverseSearch(k);e&&(e=e.getPrevious(d));if(!e||e.equals(k))break;this.traverseSearch(e)}}}(),
greedySearch:function(){this.relations={};for(var a=this.editable.getElementsByTag("*"),b=0,e,g,h;e=a.getItem(b++);)if(!e.equals(this.editable)&&e.type==CKEDITOR.NODE_ELEMENT&&(e.hasAttribute("contenteditable")||!e.isReadOnly())&&d(e)&&e.isVisible())for(h in this.lookups)(g=this.lookups[h](e))&&this.store(e,g);return this.relations}};e.prototype={locate:function(){function a(b,c){var e=b.element[c===CKEDITOR.LINEUTILS_BEFORE?"getPrevious":"getNext"]();return e&&d(e)?(b.siblingRect=e.getClientRect(),
c==CKEDITOR.LINEUTILS_BEFORE?(b.siblingRect.bottom+b.elementRect.top)/2:(b.elementRect.bottom+b.siblingRect.top)/2):c==CKEDITOR.LINEUTILS_BEFORE?b.elementRect.top:b.elementRect.bottom}return function(b){var d;this.locations={};for(var e in b)d=b[e],d.elementRect=d.element.getClientRect(),d.type&CKEDITOR.LINEUTILS_BEFORE&&this.store(e,CKEDITOR.LINEUTILS_BEFORE,a(d,CKEDITOR.LINEUTILS_BEFORE)),d.type&CKEDITOR.LINEUTILS_AFTER&&this.store(e,CKEDITOR.LINEUTILS_AFTER,a(d,CKEDITOR.LINEUTILS_AFTER)),d.type&
CKEDITOR.LINEUTILS_INSIDE&&this.store(e,CKEDITOR.LINEUTILS_INSIDE,(d.elementRect.top+d.elementRect.bottom)/2);return this.locations}}(),sort:function(){var a,b,d,e;return function(g,h){a=this.locations;b=[];for(var k in a)for(var l in a[k])if(d=Math.abs(g-a[k][l]),b.length){for(e=0;e<b.length;e++)if(d<b[e].dist){b.splice(e,0,{uid:+k,type:l,dist:d});break}e==b.length&&b.push({uid:+k,type:l,dist:d})}else b.push({uid:+k,type:l,dist:d});return"undefined"!=typeof h?b.slice(0,h):b}}(),store:function(a,
b,d){this.locations[a]||(this.locations[a]={});this.locations[a][b]=d}};var g={display:"block",width:"0px",height:"0px","border-color":"transparent","border-style":"solid",position:"absolute",top:"-6px"},l={height:"0px","border-top":"1px dashed red",position:"absolute","z-index":9999};b.prototype={removeAll:function(){for(var a in this.hidden)this.hidden[a].remove(),delete this.hidden[a];for(a in this.visible)this.visible[a].remove(),delete this.visible[a]},hideLine:function(a){var b=a.getUniqueId();
a.hide();this.hidden[b]=a;delete this.visible[b]},showLine:function(a){var b=a.getUniqueId();a.show();this.visible[b]=a;delete this.hidden[b]},hideVisible:function(){for(var a in this.visible)this.hideLine(this.visible[a])},placeLine:function(a,b){var d,e,g;if(d=this.getStyle(a.uid,a.type)){for(g in this.visible)if(this.visible[g].getCustomData("hash")!==this.hash){e=this.visible[g];break}if(!e)for(g in this.hidden)if(this.hidden[g].getCustomData("hash")!==this.hash){this.showLine(e=this.hidden[g]);
break}e||this.showLine(e=this.addLine());e.setCustomData("hash",this.hash);this.visible[e.getUniqueId()]=e;e.setStyles(d);b&&b(e)}},getStyle:function(a,b){var d=this.relations[a],e=this.locations[a][b],g={};g.width=d.siblingRect?Math.max(d.siblingRect.width,d.elementRect.width):d.elementRect.width;g.top=this.inline?e+this.winTopScroll.y-this.rect.relativeY:this.rect.top+this.winTopScroll.y+e;if(g.top-this.winTopScroll.y<this.rect.top||g.top-this.winTopScroll.y>this.rect.bottom)return!1;this.inline?
g.left=d.elementRect.left-this.rect.relativeX:(0<d.elementRect.left?g.left=this.rect.left+d.elementRect.left:(g.width+=d.elementRect.left,g.left=this.rect.left),0<(d=g.left+g.width-(this.rect.left+this.winPane.width))&&(g.width-=d));g.left+=this.winTopScroll.x;for(var h in g)g[h]=CKEDITOR.tools.cssLength(g[h]);return g},addLine:function(){var a=CKEDITOR.dom.element.createFromHtml(this.lineTpl);a.appendTo(this.container);return a},prepare:function(a,b){this.relations=a;this.locations=b;this.hash=Math.random()},
cleanup:function(){var a,b;for(b in this.visible)a=this.visible[b],a.getCustomData("hash")!==this.hash&&this.hideLine(a)},queryViewport:function(){this.winPane=this.win.getViewPaneSize();this.winTopScroll=this.winTop.getScrollPosition();this.winTopPane=this.winTop.getViewPaneSize();this.rect=this.getClientRect(this.inline?this.editable:this.frame)},getClientRect:function(a){a=a.getClientRect();var b=this.container.getDocumentPosition(),d=this.container.getComputedStyle("position");a.relativeX=a.relativeY=
0;"static"!=d&&(a.relativeY=b.y,a.relativeX=b.x,a.top-=a.relativeY,a.bottom-=a.relativeY,a.left-=a.relativeX,a.right-=a.relativeX);return a}};var k={left:1,right:1,center:1},h={absolute:1,fixed:1};CKEDITOR.plugins.lineutils={finder:a,locator:e,liner:b}}(),function(){function a(a){return a.getName&&!a.hasAttribute("data-cke-temp")}CKEDITOR.plugins.add("widgetselection",{init:function(a){if(CKEDITOR.env.webkit){var b=CKEDITOR.plugins.widgetselection;a.on("contentDom",function(a){a=a.editor;var e=a.document,
l=a.editable();l.attachListener(e,"keydown",function(a){var d=a.data.$;65==a.data.getKey()&&(CKEDITOR.env.mac&&d.metaKey||!CKEDITOR.env.mac&&d.ctrlKey)&&CKEDITOR.tools.setTimeout(function(){b.addFillers(l)||b.removeFillers(l)},0)},null,null,-1);a.on("selectionCheck",function(a){b.removeFillers(a.editor.editable())});a.on("paste",function(a){a.data.dataValue=b.cleanPasteData(a.data.dataValue)});"selectall"in a.plugins&&b.addSelectAllIntegration(a)})}}});CKEDITOR.plugins.widgetselection={startFiller:null,
endFiller:null,fillerAttribute:"data-cke-filler-webkit",fillerContent:"\x26nbsp;",fillerTagName:"div",addFillers:function(e){var b=e.editor;if(!this.isWholeContentSelected(e)&&0<e.getChildCount()){var d=e.getFirst(a),g=e.getLast(a);d&&d.type==CKEDITOR.NODE_ELEMENT&&!d.isEditable()&&(this.startFiller=this.createFiller(),e.append(this.startFiller,1));g&&g.type==CKEDITOR.NODE_ELEMENT&&!g.isEditable()&&(this.endFiller=this.createFiller(!0),e.append(this.endFiller,0));if(this.hasFiller(e))return b=b.createRange(),
b.selectNodeContents(e),b.select(),!0}return!1},removeFillers:function(a){if(this.hasFiller(a)&&!this.isWholeContentSelected(a)){var b=a.findOne(this.fillerTagName+"["+this.fillerAttribute+"\x3dstart]"),d=a.findOne(this.fillerTagName+"["+this.fillerAttribute+"\x3dend]");this.startFiller&&b&&this.startFiller.equals(b)?this.removeFiller(this.startFiller,a):this.startFiller=b;this.endFiller&&d&&this.endFiller.equals(d)?this.removeFiller(this.endFiller,a):this.endFiller=d}},cleanPasteData:function(a){a&&
a.length&&(a=a.replace(this.createFillerRegex(),"").replace(this.createFillerRegex(!0),""));return a},isWholeContentSelected:function(a){var b=a.editor.getSelection().getRanges()[0];return!b||b&&b.collapsed?!1:(b=b.clone(),b.enlarge(CKEDITOR.ENLARGE_ELEMENT),!!(b&&a&&b.startContainer&&b.endContainer&&0===b.startOffset&&b.endOffset===a.getChildCount()&&b.startContainer.equals(a)&&b.endContainer.equals(a)))},hasFiller:function(a){return 0<a.find(this.fillerTagName+"["+this.fillerAttribute+"]").count()},
createFiller:function(a){var b=new CKEDITOR.dom.element(this.fillerTagName);b.setHtml(this.fillerContent);b.setAttribute(this.fillerAttribute,a?"end":"start");b.setAttribute("data-cke-temp",1);b.setStyles({display:"block",width:0,height:0,padding:0,border:0,margin:0,position:"absolute",top:0,left:"-9999px",opacity:0,overflow:"hidden"});return b},removeFiller:function(a,b){if(a){var d=b.editor,g=b.editor.getSelection().getRanges()[0].startPath(),l=d.createRange(),k,h;g.contains(a)&&(k=a.getHtml(),
h=!0);g="start"==a.getAttribute(this.fillerAttribute);a.remove();k&&0<k.length&&k!=this.fillerContent?(b.insertHtmlIntoRange(k,d.getSelection().getRanges()[0]),l.setStartAt(b.getChild(b.getChildCount()-1),CKEDITOR.POSITION_BEFORE_END),d.getSelection().selectRanges([l])):h&&(g?l.setStartAt(b.getFirst().getNext(),CKEDITOR.POSITION_AFTER_START):l.setEndAt(b.getLast().getPrevious(),CKEDITOR.POSITION_BEFORE_END),b.editor.getSelection().selectRanges([l]))}},createFillerRegex:function(a){var b=this.createFiller(a).getOuterHtml().replace(/style="[^"]*"/gi,
'style\x3d"[^"]*"').replace(/>[^<]*</gi,"\x3e[^\x3c]*\x3c");return new RegExp((a?"":"^")+b+(a?"$":""))},addSelectAllIntegration:function(a){var b=this;a.editable().attachListener(a,"beforeCommandExec",function(d){var g=a.editable();"selectAll"==d.data.name&&g&&b.addFillers(g)},null,null,9999)}}}(),"use strict",function(){function a(a){this.editor=a;this.registered={};this.instances={};this.selected=[];this.widgetHoldingFocusedEditable=this.focused=null;this._={nextId:0,upcasts:[],upcastCallbacks:[],
filters:{}};G(this);B(this);this.on("checkWidgets",k);this.editor.on("contentDomInvalidated",this.checkWidgets,this);z(this);x(this);u(this);A(this);C(this)}function e(a,b,c,d,g){var f=a.editor;CKEDITOR.tools.extend(this,d,{editor:f,id:b,inline:"span"==c.getParent().getName(),element:c,data:CKEDITOR.tools.extend({},"function"==typeof d.defaults?d.defaults():d.defaults),dataReady:!1,inited:!1,ready:!1,edit:e.prototype.edit,focusedEditable:null,definition:d,repository:a,draggable:!1!==d.draggable,_:{downcastFn:d.downcast&&
"string"==typeof d.downcast?d.downcasts[d.downcast]:d.downcast}},!0);a.fire("instanceCreated",this);da(this,d);this.init&&this.init();this.inited=!0;(a=this.element.data("cke-widget-data"))&&this.setData(JSON.parse(decodeURIComponent(a)));g&&this.setData(g);this.data.classes||this.setData("classes",this.getClasses());this.dataReady=!0;Q(this);this.fire("data",this.data);this.isInited()&&f.editable().contains(this.wrapper)&&(this.ready=!0,this.fire("ready"))}function b(a,b,c){CKEDITOR.dom.element.call(this,
b.$);this.editor=a;this._={};b=this.filter=c.filter;CKEDITOR.dtd[this.getName()].p?(this.enterMode=b?b.getAllowedEnterMode(a.enterMode):a.enterMode,this.shiftEnterMode=b?b.getAllowedEnterMode(a.shiftEnterMode,!0):a.shiftEnterMode):this.enterMode=this.shiftEnterMode=CKEDITOR.ENTER_BR}function d(a,b){a.addCommand(b.name,{exec:function(a,c){function d(){a.widgets.finalizeCreation(h)}var e=a.widgets.focused;if(e&&e.name==b.name)e.edit();else if(b.insert)b.insert();else if(b.template){var e="function"==
typeof b.defaults?b.defaults():b.defaults,e=CKEDITOR.dom.element.createFromHtml(b.template.output(e)),g,f=a.widgets.wrapElement(e,b.name),h=new CKEDITOR.dom.documentFragment(f.getDocument());h.append(f);(g=a.widgets.initOn(e,b,c&&c.startupData))?(e=g.once("edit",function(b){if(b.data.dialog)g.once("dialog",function(b){b=b.data;var c,e;c=b.once("ok",d,null,null,20);e=b.once("cancel",function(b){b.data&&!1===b.data.hide||a.widgets.destroy(g,!0)});b.once("hide",function(){c.removeListener();e.removeListener()})});
else d()},null,null,999),g.edit(),e.removeListener()):d()}},allowedContent:b.allowedContent,requiredContent:b.requiredContent,contentForms:b.contentForms,contentTransformations:b.contentTransformations})}function g(a,b){function c(a,d){var e=b.upcast.split(","),g,f;for(f=0;f<e.length;f++)if(g=e[f],g===a.name)return b.upcasts[g].call(this,a,d);return!1}function d(b,c,e){var g=CKEDITOR.tools.getIndex(a._.upcasts,function(a){return a[2]>e});0>g&&(g=a._.upcasts.length);a._.upcasts.splice(g,0,[CKEDITOR.tools.bind(b,
c),c.name,e])}var e=b.upcast,g=b.upcastPriority||10;e&&("string"==typeof e?d(c,b,g):d(e,b,g))}function l(a,b){a.focused=null;if(b.isInited()){var c=b.editor.checkDirty();a.fire("widgetBlurred",{widget:b});b.setFocused(!1);!c&&b.editor.resetDirty()}}function k(a){a=a.data;if("wysiwyg"==this.editor.mode){var b=this.editor.editable(),c=this.instances,d,g,f,h;if(b){for(d in c)c[d].isReady()&&!b.contains(c[d].wrapper)&&this.destroy(c[d],!0);if(a&&a.initOnlyNew)c=this.initOnAll();else{var k=b.find(".cke_widget_wrapper"),
c=[];d=0;for(g=k.count();d<g;d++){f=k.getItem(d);if(h=!this.getByElement(f,!0)){a:{h=y;for(var l=f;l=l.getParent();)if(h(l)){h=!0;break a}h=!1}h=!h}h&&b.contains(f)&&(f.addClass("cke_widget_new"),c.push(this.initOn(f.getFirst(e.isDomWidgetElement))))}}a&&a.focusInited&&1==c.length&&c[0].focus()}}}function h(a){if("undefined"!=typeof a.attributes&&a.attributes["data-widget"]){var b=c(a),d=m(a),e=!1;b&&b.value&&b.value.match(/^\s/g)&&(b.parent.attributes["data-cke-white-space-first"]=1,b.value=b.value.replace(/^\s/g,
"\x26nbsp;"),e=!0);d&&d.value&&d.value.match(/\s$/g)&&(d.parent.attributes["data-cke-white-space-last"]=1,d.value=d.value.replace(/\s$/g,"\x26nbsp;"),e=!0);e&&(a.attributes["data-cke-widget-white-space"]=1)}}function c(a){return a.find(function(a){return 3===a.type},!0).shift()}function m(a){return a.find(function(a){return 3===a.type},!0).pop()}function f(a,b,c){if(!c.allowedContent&&!c.disallowedContent)return null;var d=this._.filters[a];d||(this._.filters[a]=d={});a=d[b];a||(a=c.allowedContent?
new CKEDITOR.filter(c.allowedContent):this.editor.filter.clone(),d[b]=a,c.disallowedContent&&a.disallow(c.disallowedContent));return a}function n(a){var b=[],c=a._.upcasts,d=a._.upcastCallbacks;return{toBeWrapped:b,iterator:function(a){var g,f,h,k,l;if("data-cke-widget-wrapper"in a.attributes)return(a=a.getFirst(e.isParserWidgetElement))&&b.push([a]),!1;if("data-widget"in a.attributes)return b.push([a]),!1;if(l=c.length){if(a.attributes["data-cke-widget-upcasted"])return!1;k=0;for(g=d.length;k<g;++k)if(!1===
d[k](a))return;for(k=0;k<l;++k)if(g=c[k],h={},f=g[0](a,h))return f instanceof CKEDITOR.htmlParser.element&&(a=f),a.attributes["data-cke-widget-data"]=encodeURIComponent(JSON.stringify(h)),a.attributes["data-cke-widget-upcasted"]=1,b.push([a,g[1]]),!1}}}}function p(a,b){return{tabindex:-1,contenteditable:"false","data-cke-widget-wrapper":1,"data-cke-filter":"off","class":"cke_widget_wrapper cke_widget_new cke_widget_"+(a?"inline":"block")+(b?" cke_widget_"+b:"")}}function q(a,b,c){if(a.type==CKEDITOR.NODE_ELEMENT){var d=
CKEDITOR.dtd[a.name];if(d&&!d[c.name]){var d=a.split(b),e=a.parent;b=d.getIndex();a.children.length||(--b,a.remove());d.children.length||d.remove();return q(e,b,c)}}a.add(c,b)}function v(a,b){return"boolean"==typeof a.inline?a.inline:!!CKEDITOR.dtd.$inline[b]}function y(a){return a.hasAttribute("data-cke-temp")}function r(a,b,c,d){var e=a.editor;e.fire("lockSnapshot");c?(d=c.data("cke-widget-editable"),d=b.editables[d],a.widgetHoldingFocusedEditable=b,b.focusedEditable=d,c.addClass("cke_widget_editable_focused"),
d.filter&&e.setActiveFilter(d.filter),e.setActiveEnterMode(d.enterMode,d.shiftEnterMode)):(d||b.focusedEditable.removeClass("cke_widget_editable_focused"),b.focusedEditable=null,a.widgetHoldingFocusedEditable=null,e.setActiveFilter(null),e.setActiveEnterMode(null,null));e.fire("unlockSnapshot")}function t(a){a.contextMenu&&a.contextMenu.addListener(function(b){if(b=a.widgets.getByElement(b,!0))return b.fire("contextMenu",{})})}function w(a,b){return CKEDITOR.tools.trim(b)}function A(a){var b=a.editor,
c=CKEDITOR.plugins.lineutils;b.on("dragstart",function(c){var d=c.data.target;e.isDomDragHandler(d)&&(d=a.getByElement(d),c.data.dataTransfer.setData("cke/widget-id",d.id),b.focus(),d.focus())});b.on("drop",function(c){var d=c.data.dataTransfer,e=d.getData("cke/widget-id"),g=d.getTransferType(b),d=b.createRange();""!==e&&g===CKEDITOR.DATA_TRANSFER_CROSS_EDITORS?c.cancel():""!==e&&g==CKEDITOR.DATA_TRANSFER_INTERNAL&&(e=a.instances[e])&&(d.setStartBefore(e.wrapper),d.setEndAfter(e.wrapper),c.data.dragRange=
d,delete CKEDITOR.plugins.clipboard.dragStartContainerChildCount,delete CKEDITOR.plugins.clipboard.dragEndContainerChildCount,c.data.dataTransfer.setData("text/html",b.editable().getHtmlFromRange(d).getHtml()),b.widgets.destroy(e,!0))});b.on("contentDom",function(){var d=b.editable();CKEDITOR.tools.extend(a,{finder:new c.finder(b,{lookups:{"default":function(b){if(!b.is(CKEDITOR.dtd.$listItem)&&b.is(CKEDITOR.dtd.$block)&&!e.isDomNestedEditable(b)&&!a._.draggedWidget.wrapper.contains(b)){var c=e.getNestedEditable(d,
b);if(c){b=a._.draggedWidget;if(a.getByElement(c)==b)return;c=CKEDITOR.filter.instances[c.data("cke-filter")];b=b.requiredContent;if(c&&b&&!c.check(b))return}return CKEDITOR.LINEUTILS_BEFORE|CKEDITOR.LINEUTILS_AFTER}}}}),locator:new c.locator(b),liner:new c.liner(b,{lineStyle:{cursor:"move !important","border-top-color":"#666"},tipLeftStyle:{"border-left-color":"#666"},tipRightStyle:{"border-right-color":"#666"}})},!0)})}function x(a){var b=a.editor;b.on("contentDom",function(){var c=b.editable(),
d=c.isInline()?c:b.document,g,f;c.attachListener(d,"mousedown",function(c){var d=c.data.getTarget();g=d instanceof CKEDITOR.dom.element?a.getByElement(d):null;f=0;g&&(g.inline&&d.type==CKEDITOR.NODE_ELEMENT&&d.hasAttribute("data-cke-widget-drag-handler")?(f=1,a.focused!=g&&b.getSelection().removeAllRanges()):e.getNestedEditable(g.wrapper,d)?g=null:(c.data.preventDefault(),CKEDITOR.env.ie||g.focus()))});c.attachListener(d,"mouseup",function(){f&&g&&g.wrapper&&(f=0,g.focus())});CKEDITOR.env.ie&&c.attachListener(d,
"mouseup",function(){setTimeout(function(){g&&g.wrapper&&c.contains(g.wrapper)&&(g.focus(),g=null)})})});b.on("doubleclick",function(b){var c=a.getByElement(b.data.element);if(c&&!e.getNestedEditable(c.wrapper,b.data.element))return c.fire("doubleclick",{element:b.data.element})},null,null,1)}function u(a){a.editor.on("key",function(b){var c=a.focused,d=a.widgetHoldingFocusedEditable,e;c?e=c.fire("key",{keyCode:b.data.keyCode}):d&&(c=b.data.keyCode,b=d.focusedEditable,c==CKEDITOR.CTRL+65?(c=b.getBogus(),
d=d.editor.createRange(),d.selectNodeContents(b),c&&d.setEndAt(c,CKEDITOR.POSITION_BEFORE_START),d.select(),e=!1):8==c||46==c?(e=d.editor.getSelection().getRanges(),d=e[0],e=!(1==e.length&&d.collapsed&&d.checkBoundaryOfElement(b,CKEDITOR[8==c?"START":"END"]))):e=void 0);return e},null,null,1)}function C(a){function b(c){a.focused&&H(a.focused,"cut"==c.name)}var c=a.editor;c.on("contentDom",function(){var a=c.editable();a.attachListener(a,"copy",b);a.attachListener(a,"cut",b)})}function z(a){var b=
a.editor;b.on("selectionCheck",function(){a.fire("checkSelection")});a.on("checkSelection",a.checkSelection,a);b.on("selectionChange",function(c){var d=(c=e.getNestedEditable(b.editable(),c.data.selection.getStartElement()))&&a.getByElement(c),g=a.widgetHoldingFocusedEditable;g?g===d&&g.focusedEditable.equals(c)||(r(a,g,null),d&&c&&r(a,d,c)):d&&c&&r(a,d,c)});b.on("dataReady",function(){F(a).commit()});b.on("blur",function(){var b;(b=a.focused)&&l(a,b);(b=a.widgetHoldingFocusedEditable)&&r(a,b,null)})}
function B(a){var b=a.editor,d={};b.on("toDataFormat",function(b){var g=CKEDITOR.tools.getNextNumber(),f=[];b.data.downcastingSessionId=g;d[g]=f;b.data.dataValue.forEach(function(b){var d=b.attributes,g;if("data-cke-widget-white-space"in d){g=c(b);var h=m(b);g.parent.attributes["data-cke-white-space-first"]&&(g.value=g.value.replace(/^&nbsp;/g," "));h.parent.attributes["data-cke-white-space-last"]&&(h.value=h.value.replace(/&nbsp;$/g," "))}if("data-cke-widget-id"in d){if(d=a.instances[d["data-cke-widget-id"]])g=
b.getFirst(e.isParserWidgetElement),f.push({wrapper:b,element:g,widget:d,editables:{}}),"1"!=g.attributes["data-cke-widget-keep-attr"]&&delete g.attributes["data-widget"]}else if("data-cke-widget-editable"in d)return f[f.length-1].editables[d["data-cke-widget-editable"]]=b,!1},CKEDITOR.NODE_ELEMENT,!0)},null,null,8);b.on("toDataFormat",function(a){if(a.data.downcastingSessionId){a=d[a.data.downcastingSessionId];for(var b,c,e,g,f,h;b=a.shift();){c=b.widget;e=b.element;g=c._.downcastFn&&c._.downcastFn.call(c,
e);for(h in b.editables)f=b.editables[h],delete f.attributes.contenteditable,f.setHtml(c.editables[h].getData());g||(g=e);b.wrapper.replaceWith(g)}}},null,null,13);b.on("contentDomUnload",function(){a.destroyAll(!0)})}function G(a){var b=a.editor,c,d;b.on("toHtml",function(b){var d=n(a),g;for(b.data.dataValue.forEach(d.iterator,CKEDITOR.NODE_ELEMENT,!0);g=d.toBeWrapped.pop();){var f=g[0],h=f.parent;h.type==CKEDITOR.NODE_ELEMENT&&h.attributes["data-cke-widget-wrapper"]&&h.replaceWith(f);a.wrapElement(g[0],
g[1])}c=b.data.protectedWhitespaces?3==b.data.dataValue.children.length&&e.isParserWidgetWrapper(b.data.dataValue.children[1]):1==b.data.dataValue.children.length&&e.isParserWidgetWrapper(b.data.dataValue.children[0])},null,null,8);b.on("dataReady",function(){if(d)for(var c=b.editable().find(".cke_widget_wrapper"),g,f,h=0,k=c.count();h<k;++h)g=c.getItem(h),f=g.getFirst(e.isDomWidgetElement),f.type==CKEDITOR.NODE_ELEMENT&&f.data("widget")?(f.replace(g),a.wrapElement(f)):g.remove();d=0;a.destroyAll(!0);
a.initOnAll()});b.on("loadSnapshot",function(b){/data-cke-widget/.test(b.data)&&(d=1);a.destroyAll(!0)},null,null,9);b.on("paste",function(a){a=a.data;a.dataValue=a.dataValue.replace(U,w);a.range&&(a=e.getNestedEditable(b.editable(),a.range.startContainer))&&(a=CKEDITOR.filter.instances[a.data("cke-filter")])&&b.setActiveFilter(a)});b.on("afterInsertHtml",function(d){d.data.intoRange?a.checkWidgets({initOnlyNew:!0}):(b.fire("lockSnapshot"),a.checkWidgets({initOnlyNew:!0,focusInited:c}),b.fire("unlockSnapshot"))})}
function F(a){var b=a.selected,c=[],d=b.slice(0),e=null;return{select:function(a){0>CKEDITOR.tools.indexOf(b,a)&&c.push(a);a=CKEDITOR.tools.indexOf(d,a);0<=a&&d.splice(a,1);return this},focus:function(a){e=a;return this},commit:function(){var g=a.focused!==e,f,h;a.editor.fire("lockSnapshot");for(g&&(f=a.focused)&&l(a,f);f=d.pop();)b.splice(CKEDITOR.tools.indexOf(b,f),1),f.isInited()&&(h=f.editor.checkDirty(),f.setSelected(!1),!h&&f.editor.resetDirty());g&&e&&(h=a.editor.checkDirty(),a.focused=e,a.fire("widgetFocused",
{widget:e}),e.setFocused(!0),!h&&a.editor.resetDirty());for(;f=c.pop();)b.push(f),f.setSelected(!0);a.editor.fire("unlockSnapshot")}}}function E(a,b,c){var d=0;b=M(b);var e=a.data.classes||{},g;if(b){for(e=CKEDITOR.tools.clone(e);g=b.pop();)c?e[g]||(d=e[g]=1):e[g]&&(delete e[g],d=1);d&&a.setData("classes",e)}}function J(a){a.cancel()}function H(a,b){var c=a.editor,d=c.document,e=CKEDITOR.env.edge&&16<=CKEDITOR.env.version;if(!d.getById("cke_copybin")){var g=!c.blockless&&!CKEDITOR.env.ie||e?"div":
"span",e=d.createElement(g),f=d.createElement(g),g=CKEDITOR.env.ie&&9>CKEDITOR.env.version;f.setAttributes({id:"cke_copybin","data-cke-temp":"1"});e.setStyles({position:"absolute",width:"1px",height:"1px",overflow:"hidden"});e.setStyle("ltr"==c.config.contentsLangDirection?"left":"right","-5000px");var h=c.createRange();h.setStartBefore(a.wrapper);h.setEndAfter(a.wrapper);e.setHtml('\x3cspan data-cke-copybin-start\x3d"1"\x3e\x3c/span\x3e'+c.editable().getHtmlFromRange(h).getHtml()+'\x3cspan data-cke-copybin-end\x3d"1"\x3e\x3c/span\x3e');
c.fire("saveSnapshot");c.fire("lockSnapshot");f.append(e);c.editable().append(f);var k=c.on("selectionChange",J,null,null,0),l=a.repository.on("checkSelection",J,null,null,0);if(g)var m=d.getDocumentElement().$,n=m.scrollTop;h=c.createRange();h.selectNodeContents(e);h.select();g&&(m.scrollTop=n);setTimeout(function(){b||a.focus();f.remove();k.removeListener();l.removeListener();c.fire("unlockSnapshot");b&&(a.repository.del(a),c.fire("saveSnapshot"))},100)}}function M(a){return(a=(a=a.getDefinition().attributes)&&
a["class"])?a.split(/\s+/):null}function K(){var a=CKEDITOR.document.getActive(),b=this.editor,c=b.editable();(c.isInline()?c:b.document.getWindow().getFrame()).equals(a)&&b.focusManager.focus(c)}function D(){CKEDITOR.env.gecko&&this.editor.unlockSelection();CKEDITOR.env.webkit||(this.editor.forceNextSelectionCheck(),this.editor.selectionChange(1))}function R(a){var b=null;a.on("data",function(){var a=this.data.classes,c;if(b!=a){for(c in b)a&&a[c]||this.removeClass(c);for(c in a)this.addClass(c);
b=a}})}function L(a){a.on("data",function(){if(a.wrapper){var b=this.getLabel?this.getLabel():this.editor.lang.widget.label.replace(/%1/,this.pathName||this.element.getName());a.wrapper.setAttribute("role","region");a.wrapper.setAttribute("aria-label",b)}},null,null,9999)}function S(a){if(a.draggable){var b=a.editor,c=a.wrapper.getLast(e.isDomDragHandlerContainer),d;c?d=c.findOne("img"):(c=new CKEDITOR.dom.element("span",b.document),c.setAttributes({"class":"cke_reset cke_widget_drag_handler_container",
style:"background:rgba(220,220,220,0.5);background-image:url("+b.plugins.widget.path+"images/handle.png)"}),d=new CKEDITOR.dom.element("img",b.document),d.setAttributes({"class":"cke_reset cke_widget_drag_handler","data-cke-widget-drag-handler":"1",src:CKEDITOR.tools.transparentImageData,width:15,title:b.lang.widget.move,height:15,role:"presentation"}),a.inline&&d.setAttribute("draggable","true"),c.append(d),a.wrapper.append(c));a.wrapper.on("dragover",function(a){a.data.preventDefault()});a.wrapper.on("mouseenter",
a.updateDragHandlerPosition,a);setTimeout(function(){a.on("data",a.updateDragHandlerPosition,a)},50);if(!a.inline&&(d.on("mousedown",N,a),CKEDITOR.env.ie&&9>CKEDITOR.env.version))d.on("dragstart",function(a){a.data.preventDefault(!0)});a.dragHandlerContainer=c}}function N(a){function b(){var c;for(p.reset();c=h.pop();)c.removeListener();var d=k;c=a.sender;var e=this.repository.finder,g=this.repository.liner,f=this.editor,l=this.editor.editable();CKEDITOR.tools.isEmpty(g.visible)||(d=e.getRange(d[0]),
this.focus(),f.fire("drop",{dropRange:d,target:d.startContainer}));l.removeClass("cke_widget_dragging");g.hideVisible();f.fire("dragend",{target:c})}if(CKEDITOR.tools.getMouseButton(a)===CKEDITOR.MOUSE_BUTTON_LEFT){var c=this.repository.finder,d=this.repository.locator,e=this.repository.liner,g=this.editor,f=g.editable(),h=[],k=[],l,m;this.repository._.draggedWidget=this;var n=c.greedySearch(),p=CKEDITOR.tools.eventsBuffer(50,function(){l=d.locate(n);k=d.sort(m,1);k.length&&(e.prepare(n,l),e.placeLine(k[0]),
e.cleanup())});f.addClass("cke_widget_dragging");h.push(f.on("mousemove",function(a){m=a.data.$.clientY;p.input()}));g.fire("dragstart",{target:a.sender});h.push(g.document.once("mouseup",b,this));f.isInline()||h.push(CKEDITOR.document.once("mouseup",b,this))}}function V(a){var b,c,d=a.editables;a.editables={};if(a.editables)for(b in d)c=d[b],a.initEditable(b,"string"==typeof c?{selector:c}:c)}function Z(a){if(a.mask){var b=a.wrapper.findOne(".cke_widget_mask");b||(b=new CKEDITOR.dom.element("img",
a.editor.document),b.setAttributes({src:CKEDITOR.tools.transparentImageData,"class":"cke_reset cke_widget_mask"}),a.wrapper.append(b));a.mask=b}}function X(a){if(a.parts){var b={},c,d;for(d in a.parts)c=a.wrapper.findOne(a.parts[d]),b[d]=c;a.parts=b}}function da(a,b){P(a);X(a);V(a);Z(a);S(a);R(a);L(a);if(CKEDITOR.env.ie&&9>CKEDITOR.env.version)a.wrapper.on("dragstart",function(b){var c=b.data.getTarget();e.getNestedEditable(a,c)||a.inline&&e.isDomDragHandler(c)||b.data.preventDefault()});a.wrapper.removeClass("cke_widget_new");
a.element.addClass("cke_widget_element");a.on("key",function(b){b=b.data.keyCode;if(13==b)a.edit();else{if(b==CKEDITOR.CTRL+67||b==CKEDITOR.CTRL+88){H(a,b==CKEDITOR.CTRL+88);return}if(b in T||CKEDITOR.CTRL&b||CKEDITOR.ALT&b)return}return!1},null,null,999);a.on("doubleclick",function(b){a.edit()&&b.cancel()});if(b.data)a.on("data",b.data);if(b.edit)a.on("edit",b.edit)}function P(a){(a.wrapper=a.element.getParent()).setAttribute("data-cke-widget-id",a.id)}function Q(a){a.element.data("cke-widget-data",
encodeURIComponent(JSON.stringify(a.data)))}function O(){function a(){}function b(a,c,d){return d&&this.checkElement(a)?(a=d.widgets.getByElement(a,!0))&&a.checkStyleActive(this):!1}var c={};CKEDITOR.style.addCustomHandler({type:"widget",setup:function(a){this.widget=a.widget;if(this.group="string"==typeof a.group?[a.group]:a.group){a=this.widget;var b;c[a]||(c[a]={});for(var d=0,e=this.group.length;d<e;d++)b=this.group[d],c[a][b]||(c[a][b]=[]),c[a][b].push(this)}},apply:function(a){var b;a instanceof
CKEDITOR.editor&&this.checkApplicable(a.elementPath(),a)&&(b=a.widgets.focused,this.group&&this.removeStylesFromSameGroup(a),b.applyStyle(this))},remove:function(a){a instanceof CKEDITOR.editor&&this.checkApplicable(a.elementPath(),a)&&a.widgets.focused.removeStyle(this)},removeStylesFromSameGroup:function(a){var b,d,e=!1;if(!(a instanceof CKEDITOR.editor))return!1;d=a.elementPath();if(this.checkApplicable(d,a))for(var g=0,f=this.group.length;g<f;g++){b=c[this.widget][this.group[g]];for(var h=0;h<
b.length;h++)b[h]!==this&&b[h].checkActive(d,a)&&(a.widgets.focused.removeStyle(b[h]),e=!0)}return e},checkActive:function(a,b){return this.checkElementMatch(a.lastElement,0,b)},checkApplicable:function(a,b){return b instanceof CKEDITOR.editor?this.checkElement(a.lastElement):!1},checkElementMatch:b,checkElementRemovable:b,checkElement:function(a){return e.isDomWidgetWrapper(a)?(a=a.getFirst(e.isDomWidgetElement))&&a.data("widget")==this.widget:!1},buildPreview:function(a){return a||this._.definition.name},
toAllowedContentRules:function(a){if(!a)return null;a=a.widgets.registered[this.widget];var b,c={};if(!a)return null;if(a.styleableElements){b=this.getClassesArray();if(!b)return null;c[a.styleableElements]={classes:b,propertiesOnly:!0};return c}return a.styleToAllowedContentRules?a.styleToAllowedContentRules(this):null},getClassesArray:function(){var a=this._.definition.attributes&&this._.definition.attributes["class"];return a?CKEDITOR.tools.trim(a).split(/\s+/):null},applyToRange:a,removeFromRange:a,
applyToObject:a})}CKEDITOR.plugins.add("widget",{requires:"lineutils,clipboard,widgetselection",onLoad:function(){void 0!==CKEDITOR.document.$.querySelectorAll&&(CKEDITOR.addCss(".cke_widget_wrapper{position:relative;outline:none}.cke_widget_inline{display:inline-block}.cke_widget_wrapper:hover\x3e.cke_widget_element{outline:2px solid yellow;cursor:default}.cke_widget_wrapper:hover .cke_widget_editable{outline:2px solid yellow}.cke_widget_wrapper.cke_widget_focused\x3e.cke_widget_element,.cke_widget_wrapper .cke_widget_editable.cke_widget_editable_focused{outline:2px solid #ace}.cke_widget_editable{cursor:text}.cke_widget_drag_handler_container{position:absolute;width:15px;height:0;display:none;opacity:0.75;transition:height 0s 0.2s;line-height:0}.cke_widget_wrapper:hover\x3e.cke_widget_drag_handler_container{height:15px;transition:none}.cke_widget_drag_handler_container:hover{opacity:1}img.cke_widget_drag_handler{cursor:move;width:15px;height:15px;display:inline-block}.cke_widget_mask{position:absolute;top:0;left:0;width:100%;height:100%;display:block}.cke_editable.cke_widget_dragging, .cke_editable.cke_widget_dragging *{cursor:move !important}"),
O())},beforeInit:function(b){void 0!==CKEDITOR.document.$.querySelectorAll&&(b.widgets=new a(b))},afterInit:function(a){if(void 0!==CKEDITOR.document.$.querySelectorAll){var b=a.widgets.registered,c,d,e;for(d in b)c=b[d],(e=c.button)&&a.ui.addButton&&a.ui.addButton(CKEDITOR.tools.capitalize(c.name,!0),{label:e,command:c.name,toolbar:"insert,10"});t(a)}}});a.prototype={MIN_SELECTION_CHECK_INTERVAL:500,add:function(a,b){b=CKEDITOR.tools.prototypedCopy(b);b.name=a;b._=b._||{};this.editor.fire("widgetDefinition",
b);b.template&&(b.template=new CKEDITOR.template(b.template));d(this.editor,b);g(this,b);return this.registered[a]=b},addUpcastCallback:function(a){this._.upcastCallbacks.push(a)},checkSelection:function(){var a=this.editor.getSelection(),b=a.getSelectedElement(),c=F(this),d;if(b&&(d=this.getByElement(b,!0)))return c.focus(d).select(d).commit();a=a.getRanges()[0];if(!a||a.collapsed)return c.commit();a=new CKEDITOR.dom.walker(a);for(a.evaluator=e.isDomWidgetWrapper;b=a.next();)c.select(this.getByElement(b));
c.commit()},checkWidgets:function(a){this.fire("checkWidgets",CKEDITOR.tools.copy(a||{}))},del:function(a){if(this.focused===a){var b=a.editor,c=b.createRange(),d;(d=c.moveToClosestEditablePosition(a.wrapper,!0))||(d=c.moveToClosestEditablePosition(a.wrapper,!1));d&&b.getSelection().selectRanges([c])}a.wrapper.remove();this.destroy(a,!0)},destroy:function(a,b){this.widgetHoldingFocusedEditable===a&&r(this,a,null,b);a.destroy(b);delete this.instances[a.id];this.fire("instanceDestroyed",a)},destroyAll:function(a,
b){var c,d,e=this.instances;if(b&&!a){d=b.find(".cke_widget_wrapper");for(var e=d.count(),g=0;g<e;++g)(c=this.getByElement(d.getItem(g),!0))&&this.destroy(c)}else for(d in e)c=e[d],this.destroy(c,a)},finalizeCreation:function(a){(a=a.getFirst())&&e.isDomWidgetWrapper(a)&&(this.editor.insertElement(a),a=this.getByElement(a),a.ready=!0,a.fire("ready"),a.focus())},getByElement:function(){function a(c){return c.is(b)&&c.data("cke-widget-id")}var b={div:1,span:1};return function(b,c){if(!b)return null;
var d=a(b);if(!c&&!d){var e=this.editor.editable();do b=b.getParent();while(b&&!b.equals(e)&&!(d=a(b)))}return this.instances[d]||null}}(),initOn:function(a,b,c){b?"string"==typeof b&&(b=this.registered[b]):b=this.registered[a.data("widget")];if(!b)return null;var d=this.wrapElement(a,b.name);return d?d.hasClass("cke_widget_new")?(a=new e(this,this._.nextId++,a,b,c),a.isInited()?this.instances[a.id]=a:null):this.getByElement(a):null},initOnAll:function(a){a=(a||this.editor.editable()).find(".cke_widget_new");
for(var b=[],c,d=a.count();d--;)(c=this.initOn(a.getItem(d).getFirst(e.isDomWidgetElement)))&&b.push(c);return b},onWidget:function(a){var b=Array.prototype.slice.call(arguments);b.shift();for(var c in this.instances){var d=this.instances[c];d.name==a&&d.on.apply(d,b)}this.on("instanceCreated",function(c){c=c.data;c.name==a&&c.on.apply(c,b)})},parseElementClasses:function(a){if(!a)return null;a=CKEDITOR.tools.trim(a).split(/\s+/);for(var b,c={},d=0;b=a.pop();)-1==b.indexOf("cke_")&&(c[b]=d=1);return d?
c:null},wrapElement:function(a,b){var c=null,d,e;if(a instanceof CKEDITOR.dom.element){b=b||a.data("widget");d=this.registered[b];if(!d)return null;if((c=a.getParent())&&c.type==CKEDITOR.NODE_ELEMENT&&c.data("cke-widget-wrapper"))return c;a.hasAttribute("data-cke-widget-keep-attr")||a.data("cke-widget-keep-attr",a.data("widget")?1:0);a.data("widget",b);(e=v(d,a.getName()))&&h(a);c=new CKEDITOR.dom.element(e?"span":"div");c.setAttributes(p(e,b));c.data("cke-display-name",d.pathName?d.pathName:a.getName());
a.getParent(!0)&&c.replace(a);a.appendTo(c)}else if(a instanceof CKEDITOR.htmlParser.element){b=b||a.attributes["data-widget"];d=this.registered[b];if(!d)return null;if((c=a.parent)&&c.type==CKEDITOR.NODE_ELEMENT&&c.attributes["data-cke-widget-wrapper"])return c;"data-cke-widget-keep-attr"in a.attributes||(a.attributes["data-cke-widget-keep-attr"]=a.attributes["data-widget"]?1:0);b&&(a.attributes["data-widget"]=b);(e=v(d,a.name))&&h(a);c=new CKEDITOR.htmlParser.element(e?"span":"div",p(e,b));c.attributes["data-cke-display-name"]=
d.pathName?d.pathName:a.name;d=a.parent;var g;d&&(g=a.getIndex(),a.remove());c.add(a);d&&q(d,g,c)}return c},_tests_createEditableFilter:f};CKEDITOR.event.implementOn(a.prototype);e.prototype={addClass:function(a){this.element.addClass(a);this.wrapper.addClass(e.WRAPPER_CLASS_PREFIX+a)},applyStyle:function(a){E(this,a,1)},checkStyleActive:function(a){a=M(a);var b;if(!a)return!1;for(;b=a.pop();)if(!this.hasClass(b))return!1;return!0},destroy:function(a){this.fire("destroy");if(this.editables)for(var b in this.editables)this.destroyEditable(b,
a);a||("0"==this.element.data("cke-widget-keep-attr")&&this.element.removeAttribute("data-widget"),this.element.removeAttributes(["data-cke-widget-data","data-cke-widget-keep-attr"]),this.element.removeClass("cke_widget_element"),this.element.replace(this.wrapper));this.wrapper=null},destroyEditable:function(a,b){var c=this.editables[a];c.removeListener("focus",D);c.removeListener("blur",K);this.editor.focusManager.remove(c);b||(this.repository.destroyAll(!1,c),c.removeClass("cke_widget_editable"),
c.removeClass("cke_widget_editable_focused"),c.removeAttributes(["contenteditable","data-cke-widget-editable","data-cke-enter-mode"]));delete this.editables[a]},edit:function(){var a={dialog:this.dialog},b=this;if(!1===this.fire("edit",a)||!a.dialog)return!1;this.editor.openDialog(a.dialog,function(a){var c,d;!1!==b.fire("dialog",a)&&(c=a.on("show",function(){a.setupContent(b)}),d=a.on("ok",function(){var c,d=b.on("data",function(a){c=1;a.cancel()},null,null,0);b.editor.fire("saveSnapshot");a.commitContent(b);
d.removeListener();c&&(b.fire("data",b.data),b.editor.fire("saveSnapshot"))}),a.once("hide",function(){c.removeListener();d.removeListener()}))});return!0},getClasses:function(){return this.repository.parseElementClasses(this.element.getAttribute("class"))},hasClass:function(a){return this.element.hasClass(a)},initEditable:function(a,c){var d=this._findOneNotNested(c.selector);return d&&d.is(CKEDITOR.dtd.$editable)?(d=new b(this.editor,d,{filter:f.call(this.repository,this.name,a,c)}),this.editables[a]=
d,d.setAttributes({contenteditable:"true","data-cke-widget-editable":a,"data-cke-enter-mode":d.enterMode}),d.filter&&d.data("cke-filter",d.filter.id),d.addClass("cke_widget_editable"),d.removeClass("cke_widget_editable_focused"),c.pathName&&d.data("cke-display-name",c.pathName),this.editor.focusManager.add(d),d.on("focus",D,this),CKEDITOR.env.ie&&d.on("blur",K,this),d._.initialSetData=!0,d.setData(d.getHtml()),!0):!1},_findOneNotNested:function(a){a=this.wrapper.find(a);for(var b,c,d=0;d<a.count();d++)if(b=
a.getItem(d),c=b.getAscendant(e.isDomWidgetWrapper),this.wrapper.equals(c))return b;return null},isInited:function(){return!(!this.wrapper||!this.inited)},isReady:function(){return this.isInited()&&this.ready},focus:function(){var a=this.editor.getSelection();if(a){var b=this.editor.checkDirty();a.fake(this.wrapper);!b&&this.editor.resetDirty()}this.editor.focus()},removeClass:function(a){this.element.removeClass(a);this.wrapper.removeClass(e.WRAPPER_CLASS_PREFIX+a)},removeStyle:function(a){E(this,
a,0)},setData:function(a,b){var c=this.data,d=0;if("string"==typeof a)c[a]!==b&&(c[a]=b,d=1);else{var e=a;for(a in e)c[a]!==e[a]&&(d=1,c[a]=e[a])}d&&this.dataReady&&(Q(this),this.fire("data",c));return this},setFocused:function(a){this.wrapper[a?"addClass":"removeClass"]("cke_widget_focused");this.fire(a?"focus":"blur");return this},setSelected:function(a){this.wrapper[a?"addClass":"removeClass"]("cke_widget_selected");this.fire(a?"select":"deselect");return this},updateDragHandlerPosition:function(){var a=
this.editor,b=this.element.$,c=this._.dragHandlerOffset,b={x:b.offsetLeft,y:b.offsetTop-15};c&&b.x==c.x&&b.y==c.y||(c=a.checkDirty(),a.fire("lockSnapshot"),this.dragHandlerContainer.setStyles({top:b.y+"px",left:b.x+"px",display:"block"}),a.fire("unlockSnapshot"),!c&&a.resetDirty(),this._.dragHandlerOffset=b)}};CKEDITOR.event.implementOn(e.prototype);e.getNestedEditable=function(a,b){return!b||b.equals(a)?null:e.isDomNestedEditable(b)?b:e.getNestedEditable(a,b.getParent())};e.isDomDragHandler=function(a){return a.type==
CKEDITOR.NODE_ELEMENT&&a.hasAttribute("data-cke-widget-drag-handler")};e.isDomDragHandlerContainer=function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasClass("cke_widget_drag_handler_container")};e.isDomNestedEditable=function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasAttribute("data-cke-widget-editable")};e.isDomWidgetElement=function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasAttribute("data-widget")};e.isDomWidgetWrapper=function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasAttribute("data-cke-widget-wrapper")};
e.isDomWidget=function(a){return a?this.isDomWidgetWrapper(a)||this.isDomWidgetElement(a):!1};e.isParserWidgetElement=function(a){return a.type==CKEDITOR.NODE_ELEMENT&&!!a.attributes["data-widget"]};e.isParserWidgetWrapper=function(a){return a.type==CKEDITOR.NODE_ELEMENT&&!!a.attributes["data-cke-widget-wrapper"]};e.WRAPPER_CLASS_PREFIX="cke_widget_wrapper_";b.prototype=CKEDITOR.tools.extend(CKEDITOR.tools.prototypedCopy(CKEDITOR.dom.element.prototype),{setData:function(a){this._.initialSetData||
this.editor.widgets.destroyAll(!1,this);this._.initialSetData=!1;a=this.editor.dataProcessor.toHtml(a,{context:this.getName(),filter:this.filter,enterMode:this.enterMode});this.setHtml(a);this.editor.widgets.initOnAll(this)},getData:function(){return this.editor.dataProcessor.toDataFormat(this.getHtml(),{context:this.getName(),filter:this.filter,enterMode:this.enterMode})}});var U=/^(?:<(?:div|span)(?: data-cke-temp="1")?(?: id="cke_copybin")?(?: data-cke-temp="1")?>)?(?:<(?:div|span)(?: style="[^"]+")?>)?<span [^>]*data-cke-copybin-start="1"[^>]*>.?<\/span>([\s\S]+)<span [^>]*data-cke-copybin-end="1"[^>]*>.?<\/span>(?:<\/(?:div|span)>)?(?:<\/(?:div|span)>)?$/i,
T={37:1,38:1,39:1,40:1,8:1,46:1};CKEDITOR.plugins.widget=e;e.repository=a;e.nestedEditable=b}(),"use strict",function(){function a(a){this.editor=a;this.loaders=[]}function e(a,d,e){var h=a.config.fileTools_defaultFileName;this.editor=a;this.lang=a.lang;"string"===typeof d?(this.data=d,this.file=b(this.data),this.loaded=this.total=this.file.size):(this.data=null,this.file=d,this.total=this.file.size,this.loaded=0);e?this.fileName=e:this.file.name?this.fileName=this.file.name:(a=this.file.type.split("/"),
h&&(a[0]=h),this.fileName=a.join("."));this.uploaded=0;this.responseData=this.uploadTotal=null;this.status="created";this.abort=function(){this.changeStatus("abort")}}function b(a){var b=a.match(d)[1];a=a.replace(d,"");a=atob(a);var e=[],h,c,m,f;for(h=0;h<a.length;h+=512){c=a.slice(h,h+512);m=Array(c.length);for(f=0;f<c.length;f++)m[f]=c.charCodeAt(f);c=new Uint8Array(m);e.push(c)}return new Blob(e,{type:b})}CKEDITOR.plugins.add("filetools",{beforeInit:function(b){b.uploadRepository=new a(b);b.on("fileUploadRequest",
function(a){var b=a.data.fileLoader;b.xhr.open("POST",b.uploadUrl,!0);a.data.requestData.upload={file:b.file,name:b.fileName}},null,null,5);b.on("fileUploadRequest",function(a){var b=a.data.fileLoader,d=new FormData;a=a.data.requestData;for(var c in a){var e=a[c];"object"===typeof e&&e.file?d.append(c,e.file,e.name):d.append(c,e)}d.append("ckCsrfToken",CKEDITOR.tools.getCsrfToken());b.xhr.send(d)},null,null,999);b.on("fileUploadResponse",function(a){var b=a.data.fileLoader,d=b.xhr,c=a.data;try{var e=
JSON.parse(d.responseText);e.error&&e.error.message&&(c.message=e.error.message);if(e.uploaded)for(var g in e)c[g]=e[g];else a.cancel()}catch(n){c.message=b.lang.filetools.responseError,CKEDITOR.warn("filetools-response-error",{responseText:d.responseText}),a.cancel()}},null,null,999)}});a.prototype={create:function(a,b){var d=this.loaders.length,h=new e(this.editor,a,b);h.id=d;this.loaders[d]=h;this.fire("instanceCreated",h);return h},isFinished:function(){for(var a=0;a<this.loaders.length;++a)if(!this.loaders[a].isFinished())return!1;
return!0}};e.prototype={loadAndUpload:function(a,b){var d=this;this.once("loaded",function(e){e.cancel();d.once("update",function(a){a.cancel()},null,null,0);d.upload(a,b)},null,null,0);this.load()},load:function(){var a=this,b=this.reader=new FileReader;a.changeStatus("loading");this.abort=function(){a.reader.abort()};b.onabort=function(){a.changeStatus("abort")};b.onerror=function(){a.message=a.lang.filetools.loadError;a.changeStatus("error")};b.onprogress=function(b){a.loaded=b.loaded;a.update()};
b.onload=function(){a.loaded=a.total;a.data=b.result;a.changeStatus("loaded")};b.readAsDataURL(this.file)},upload:function(a,b){var d=b||{};a?(this.uploadUrl=a,this.xhr=new XMLHttpRequest,this.attachRequestListeners(),this.editor.fire("fileUploadRequest",{fileLoader:this,requestData:d})&&this.changeStatus("uploading")):(this.message=this.lang.filetools.noUrlError,this.changeStatus("error"))},attachRequestListeners:function(){function a(){"error"!=d.status&&(d.message=d.lang.filetools.networkError,
d.changeStatus("error"))}function b(){"abort"!=d.status&&d.changeStatus("abort")}var d=this,e=this.xhr;d.abort=function(){e.abort();b()};e.onerror=a;e.onabort=b;e.upload?(e.upload.onprogress=function(a){a.lengthComputable&&(d.uploadTotal||(d.uploadTotal=a.total),d.uploaded=a.loaded,d.update())},e.upload.onerror=a,e.upload.onabort=b):(d.uploadTotal=d.total,d.update());e.onload=function(){d.update();if("abort"!=d.status)if(d.uploaded=d.uploadTotal,200>e.status||299<e.status)d.message=d.lang.filetools["httpError"+
e.status],d.message||(d.message=d.lang.filetools.httpError.replace("%1",e.status)),d.changeStatus("error");else{for(var a={fileLoader:d},b=["message","fileName","url"],g=d.editor.fire("fileUploadResponse",a),l=0;l<b.length;l++){var p=b[l];"string"===typeof a[p]&&(d[p]=a[p])}d.responseData=a;delete d.responseData.fileLoader;!1===g?d.changeStatus("error"):d.changeStatus("uploaded")}}},changeStatus:function(a){this.status=a;if("error"==a||"abort"==a||"loaded"==a||"uploaded"==a)this.abort=function(){};
this.fire(a);this.update()},update:function(){this.fire("update")},isFinished:function(){return!!this.status.match(/^(?:loaded|uploaded|error|abort)$/)}};CKEDITOR.event.implementOn(a.prototype);CKEDITOR.event.implementOn(e.prototype);var d=/^data:(\S*?);base64,/;CKEDITOR.fileTools||(CKEDITOR.fileTools={});CKEDITOR.tools.extend(CKEDITOR.fileTools,{uploadRepository:a,fileLoader:e,getUploadUrl:function(a,b){var d=CKEDITOR.tools.capitalize;return b&&a[b+"UploadUrl"]?a[b+"UploadUrl"]:a.uploadUrl?a.uploadUrl:
b&&a["filebrowser"+d(b,1)+"UploadUrl"]?a["filebrowser"+d(b,1)+"UploadUrl"]+"\x26responseType\x3djson":a.filebrowserUploadUrl?a.filebrowserUploadUrl+"\x26responseType\x3djson":null},isTypeSupported:function(a,b){return!!a.type.match(b)}})}(),function(){function a(a,d,e){this.editor=a;this.notification=null;this._message=new CKEDITOR.template(d);this._singularMessage=e?new CKEDITOR.template(e):null;this._tasks=[];this._doneTasks=this._doneWeights=this._totalWeights=0}function e(a){this._weight=a||1;
this._doneWeight=0;this._isCanceled=!1}CKEDITOR.plugins.add("notificationaggregator",{requires:"notification"});a.prototype={createTask:function(a){a=a||{};var d=!this.notification,e;d&&(this.notification=this._createNotification());e=this._addTask(a);e.on("updated",this._onTaskUpdate,this);e.on("done",this._onTaskDone,this);e.on("canceled",function(){this._removeTask(e)},this);this.update();d&&this.notification.show();return e},update:function(){this._updateNotification();this.isFinished()&&this.fire("finished")},
getPercentage:function(){return 0===this.getTaskCount()?1:this._doneWeights/this._totalWeights},isFinished:function(){return this.getDoneTaskCount()===this.getTaskCount()},getTaskCount:function(){return this._tasks.length},getDoneTaskCount:function(){return this._doneTasks},_updateNotification:function(){this.notification.update({message:this._getNotificationMessage(),progress:this.getPercentage()})},_getNotificationMessage:function(){var a=this.getTaskCount(),d={current:this.getDoneTaskCount(),max:a,
percentage:Math.round(100*this.getPercentage())};return(1==a&&this._singularMessage?this._singularMessage:this._message).output(d)},_createNotification:function(){return new CKEDITOR.plugins.notification(this.editor,{type:"progress"})},_addTask:function(a){a=new e(a.weight);this._tasks.push(a);this._totalWeights+=a._weight;return a},_removeTask:function(a){var d=CKEDITOR.tools.indexOf(this._tasks,a);-1!==d&&(a._doneWeight&&(this._doneWeights-=a._doneWeight),this._totalWeights-=a._weight,this._tasks.splice(d,
1),this.update())},_onTaskUpdate:function(a){this._doneWeights+=a.data;this.update()},_onTaskDone:function(){this._doneTasks+=1;this.update()}};CKEDITOR.event.implementOn(a.prototype);e.prototype={done:function(){this.update(this._weight)},update:function(a){if(!this.isDone()&&!this.isCanceled()){a=Math.min(this._weight,a);var d=a-this._doneWeight;this._doneWeight=a;this.fire("updated",d);this.isDone()&&this.fire("done")}},cancel:function(){this.isDone()||this.isCanceled()||(this._isCanceled=!0,this.fire("canceled"))},
isDone:function(){return this._weight===this._doneWeight},isCanceled:function(){return this._isCanceled}};CKEDITOR.event.implementOn(e.prototype);CKEDITOR.plugins.notificationAggregator=a;CKEDITOR.plugins.notificationAggregator.task=e}(),"use strict",function(){CKEDITOR.plugins.add("uploadwidget",{requires:"widget,clipboard,filetools,notificationaggregator",init:function(a){a.filter.allow("*[!data-widget,!data-cke-upload-id]")}});CKEDITOR.fileTools||(CKEDITOR.fileTools={});CKEDITOR.tools.extend(CKEDITOR.fileTools,
{addUploadWidget:function(a,e,b){var d=CKEDITOR.fileTools,g=a.uploadRepository,l=b.supportedTypes?10:20;if(b.fileToElement)a.on("paste",function(b){b=b.data;var h=a.widgets.registered[e],c=b.dataTransfer,l=c.getFilesCount(),f=h.loadMethod||"loadAndUpload",n,p;if(!b.dataValue&&l)for(p=0;p<l;p++)if(n=c.getFile(p),!h.supportedTypes||d.isTypeSupported(n,h.supportedTypes)){var q=h.fileToElement(n);n=g.create(n);q&&(n[f](h.uploadUrl,h.additionalRequestParameters),CKEDITOR.fileTools.markElement(q,e,n.id),
"loadAndUpload"!=f&&"upload"!=f||h.skipNotifications||CKEDITOR.fileTools.bindNotifications(a,n),b.dataValue+=q.getOuterHtml())}},null,null,l);CKEDITOR.tools.extend(b,{downcast:function(){return new CKEDITOR.htmlParser.text("")},init:function(){var b=this,d=this.wrapper.findOne("[data-cke-upload-id]").data("cke-upload-id"),c=g.loaders[d],e=CKEDITOR.tools.capitalize,f,l;c.on("update",function(g){if(b.wrapper&&b.wrapper.getParent()){a.fire("lockSnapshot");g="on"+e(c.status);if("function"!==typeof b[g]||
!1!==b[g](c))l="cke_upload_"+c.status,b.wrapper&&l!=f&&(f&&b.wrapper.removeClass(f),b.wrapper.addClass(l),f=l),"error"!=c.status&&"abort"!=c.status||a.widgets.del(b);a.fire("unlockSnapshot")}else a.editable().find('[data-cke-upload-id\x3d"'+d+'"]').count()||c.abort(),g.removeListener()});c.update()},replaceWith:function(b,d){if(""===b.trim())a.widgets.del(this);else{var c=this==a.widgets.focused,e=a.editable(),g=a.createRange(),l,p;c||(p=a.getSelection().createBookmarks());g.setStartBefore(this.wrapper);
g.setEndAfter(this.wrapper);c&&(l=g.createBookmark());e.insertHtmlIntoRange(b,g,d);a.widgets.checkWidgets({initOnlyNew:!0});a.widgets.destroy(this,!0);c?(g.moveToBookmark(l),g.select()):a.getSelection().selectBookmarks(p)}}});a.widgets.add(e,b)},markElement:function(a,e,b){a.setAttributes({"data-cke-upload-id":b,"data-widget":e})},bindNotifications:function(a,e){function b(){d=a._.uploadWidgetNotificaionAggregator;if(!d||d.isFinished())d=a._.uploadWidgetNotificaionAggregator=new CKEDITOR.plugins.notificationAggregator(a,
a.lang.uploadwidget.uploadMany,a.lang.uploadwidget.uploadOne),d.once("finished",function(){var b=d.getTaskCount();0===b?d.notification.hide():d.notification.update({message:1==b?a.lang.uploadwidget.doneOne:a.lang.uploadwidget.doneMany.replace("%1",b),type:"success",important:1})})}var d,g=null;e.on("update",function(){!g&&e.uploadTotal&&(b(),g=d.createTask({weight:e.uploadTotal}));g&&"uploading"==e.status&&g.update(e.uploaded)});e.on("uploaded",function(){g&&g.done()});e.on("error",function(){g&&
g.cancel();a.showNotification(e.message,"warning")});e.on("abort",function(){g&&g.cancel();a.showNotification(a.lang.uploadwidget.abort,"info")})}})}(),"use strict",function(){function a(a){9>=a&&(a="0"+a);return String(a)}function e(d){var e=new Date,e=[e.getFullYear(),e.getMonth()+1,e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds()];b+=1;return"image-"+CKEDITOR.tools.array.map(e,a).join("")+"-"+b+"."+d}var b=0;CKEDITOR.plugins.add("uploadimage",{requires:"uploadwidget",onLoad:function(){CKEDITOR.addCss(".cke_upload_uploading img{opacity: 0.3}")},
init:function(a){if(CKEDITOR.plugins.clipboard.isFileApiSupported){var b=CKEDITOR.fileTools,l=b.getUploadUrl(a.config,"image");l&&(b.addUploadWidget(a,"uploadimage",{supportedTypes:/image\/(jpeg|png|gif|bmp)/,uploadUrl:l,fileToElement:function(){var a=new CKEDITOR.dom.element("img");a.setAttribute("src","data:image/gif;base64,R0lGODlhDgAOAIAAAAAAAP///yH5BAAAAAAALAAAAAAOAA4AAAIMhI+py+0Po5y02qsKADs\x3d");return a},parts:{img:"img"},onUploading:function(a){this.parts.img.setAttribute("src",a.data)},
onUploaded:function(a){var b=this.parts.img.$;this.replaceWith('\x3cimg src\x3d"'+a.url+'" width\x3d"'+(a.responseData.width||b.naturalWidth)+'" height\x3d"'+(a.responseData.height||b.naturalHeight)+'"\x3e')}}),a.on("paste",function(k){if(k.data.dataValue.match(/<img[\s\S]+data:/i)){k=k.data;var h=document.implementation.createHTMLDocument(""),h=new CKEDITOR.dom.element(h.body),c,m,f;h.data("cke-editable",1);h.appendHtml(k.dataValue);c=h.find("img");for(f=0;f<c.count();f++){m=c.getItem(f);var n=m.getAttribute("src"),
p=n&&"data:"==n.substring(0,5),q=null===m.data("cke-realelement");p&&q&&!m.data("cke-upload-id")&&!m.isReadOnly(1)&&(p=(p=n.match(/image\/([a-z]+?);/i))&&p[1]||"jpg",n=a.uploadRepository.create(n,e(p)),n.upload(l),b.markElement(m,"uploadimage",n.id),b.bindNotifications(a,n))}k.dataValue=h.getHtml()}}))}}})}(),CKEDITOR.plugins.add("wsc",{requires:"dialog",parseApi:function(a){a.config.wsc_onFinish="function"===typeof a.config.wsc_onFinish?a.config.wsc_onFinish:function(){};a.config.wsc_onClose="function"===
typeof a.config.wsc_onClose?a.config.wsc_onClose:function(){}},parseConfig:function(a){a.config.wsc_customerId=a.config.wsc_customerId||CKEDITOR.config.wsc_customerId||"1:ua3xw1-2XyGJ3-GWruD3-6OFNT1-oXcuB1-nR6Bp4-hgQHc-EcYng3-sdRXG3-NOfFk";a.config.wsc_customDictionaryIds=a.config.wsc_customDictionaryIds||CKEDITOR.config.wsc_customDictionaryIds||"";a.config.wsc_userDictionaryName=a.config.wsc_userDictionaryName||CKEDITOR.config.wsc_userDictionaryName||"";a.config.wsc_customLoaderScript=a.config.wsc_customLoaderScript||
CKEDITOR.config.wsc_customLoaderScript;a.config.wsc_interfaceLang=a.config.wsc_interfaceLang;CKEDITOR.config.wsc_cmd=a.config.wsc_cmd||CKEDITOR.config.wsc_cmd||"spell";CKEDITOR.config.wsc_version="v4.3.0-master-d769233";CKEDITOR.config.wsc_removeGlobalVariable=!0},onLoad:function(a){"moono-lisa"==(CKEDITOR.skinName||a.config.skin)&&CKEDITOR.document.appendStyleSheet(this.path+"skins/"+CKEDITOR.skin.name+"/wsc.css")},init:function(a){var e=CKEDITOR.env;this.parseConfig(a);this.parseApi(a);a.addCommand("checkspell",
new CKEDITOR.dialogCommand("checkspell")).modes={wysiwyg:!CKEDITOR.env.opera&&!CKEDITOR.env.air&&document.domain==window.location.hostname&&!(e.ie&&(8>e.version||e.quirks))};"undefined"==typeof a.plugins.scayt&&a.ui.addButton&&a.ui.addButton("SpellChecker",{label:a.lang.wsc.toolbar,click:function(a){var d=a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?a.container.getText():a.document.getBody().getText();(d=d.replace(/\s/g,""))?a.execCommand("checkspell"):alert("Nothing to check!")},toolbar:"spellchecker,10"});
CKEDITOR.dialog.add("checkspell",this.path+(CKEDITOR.env.ie&&7>=CKEDITOR.env.version?"dialogs/wsc_ie.js":window.postMessage?"dialogs/wsc.js":"dialogs/wsc_ie.js"))}}),function(){function a(a){function b(a){var c=!1;f.attachListener(f,"keydown",function(){var b=h.getBody().getElementsByTag(a);if(!c){for(var d=0;d<b.count();d++)b.getItem(d).setCustomData("retain",!0);c=!0}},null,null,1);f.attachListener(f,"keyup",function(){var b=h.getElementsByTag(a);c&&(1==b.count()&&!b.getItem(0).getCustomData("retain")&&
CKEDITOR.tools.isEmpty(b.getItem(0).getAttributes())&&b.getItem(0).remove(1),c=!1)})}var d=this.editor,h=a.document,c=h.body,m=h.getElementById("cke_actscrpt");m&&m.parentNode.removeChild(m);(m=h.getElementById("cke_shimscrpt"))&&m.parentNode.removeChild(m);(m=h.getElementById("cke_basetagscrpt"))&&m.parentNode.removeChild(m);c.contentEditable=!0;CKEDITOR.env.ie&&(c.hideFocus=!0,c.disabled=!0,c.removeAttribute("disabled"));delete this._.isLoadingData;this.$=c;h=new CKEDITOR.dom.document(h);this.setup();
this.fixInitialSelection();var f=this;CKEDITOR.env.ie&&!CKEDITOR.env.edge&&h.getDocumentElement().addClass(h.$.compatMode);CKEDITOR.env.ie&&!CKEDITOR.env.edge&&d.enterMode!=CKEDITOR.ENTER_P?b("p"):CKEDITOR.env.edge&&15>CKEDITOR.env.version&&d.enterMode!=CKEDITOR.ENTER_DIV&&b("div");if(CKEDITOR.env.webkit||CKEDITOR.env.ie&&10<CKEDITOR.env.version)h.getDocumentElement().on("mousedown",function(a){a.data.getTarget().is("html")&&setTimeout(function(){d.editable().focus()})});e(d);try{d.document.$.execCommand("2D-position",
!1,!0)}catch(n){}(CKEDITOR.env.gecko||CKEDITOR.env.ie&&"CSS1Compat"==d.document.$.compatMode)&&this.attachListener(this,"keydown",function(a){var b=a.data.getKeystroke();if(33==b||34==b)if(CKEDITOR.env.ie)setTimeout(function(){d.getSelection().scrollIntoView()},0);else if(d.window.$.innerHeight>this.$.offsetHeight){var c=d.createRange();c[33==b?"moveToElementEditStart":"moveToElementEditEnd"](this);c.select();a.data.preventDefault()}});CKEDITOR.env.ie&&this.attachListener(h,"blur",function(){try{h.$.selection.empty()}catch(a){}});
CKEDITOR.env.iOS&&this.attachListener(h,"touchend",function(){a.focus()});c=d.document.getElementsByTag("title").getItem(0);c.data("cke-title",c.getText());CKEDITOR.env.ie&&(d.document.$.title=this._.docTitle);CKEDITOR.tools.setTimeout(function(){"unloaded"==this.status&&(this.status="ready");d.fire("contentDom");this._.isPendingFocus&&(d.focus(),this._.isPendingFocus=!1);setTimeout(function(){d.fire("dataReady")},0)},0,this)}function e(a){function b(){var c;a.editable().attachListener(a,"selectionChange",
function(){var b=a.getSelection().getSelectedElement();b&&(c&&(c.detachEvent("onresizestart",d),c=null),b.$.attachEvent("onresizestart",d),c=b.$)})}function d(a){a.returnValue=!1}if(CKEDITOR.env.gecko)try{var e=a.document.$;e.execCommand("enableObjectResizing",!1,!a.config.disableObjectResizing);e.execCommand("enableInlineTableEditing",!1,!a.config.disableNativeTableHandles)}catch(c){}else CKEDITOR.env.ie&&11>CKEDITOR.env.version&&a.config.disableObjectResizing&&b(a)}function b(){var a=[];if(8<=CKEDITOR.document.$.documentMode){a.push("html.CSS1Compat [contenteditable\x3dfalse]{min-height:0 !important}");
var b=[],d;for(d in CKEDITOR.dtd.$removeEmpty)b.push("html.CSS1Compat "+d+"[contenteditable\x3dfalse]");a.push(b.join(",")+"{display:inline-block}")}else CKEDITOR.env.gecko&&(a.push("html{height:100% !important}"),a.push("img:-moz-broken{-moz-force-broken-image-icon:1;min-width:24px;min-height:24px}"));a.push("html{cursor:text;*cursor:auto}");a.push("img,input,textarea{cursor:default}");return a.join("\n")}var d;CKEDITOR.plugins.add("wysiwygarea",{init:function(a){a.config.fullPage&&a.addFeature({allowedContent:"html head title; style [media,type]; body (*)[id]; meta link [*]",
requiredContent:"body"});a.addMode("wysiwyg",function(b){function e(f){f&&f.removeListener();a.editable(new d(a,c.$.contentWindow.document.body));a.setData(a.getData(1),b)}var h="document.open();"+(CKEDITOR.env.ie?"("+CKEDITOR.tools.fixDomain+")();":"")+"document.close();",h=CKEDITOR.env.air?"javascript:void(0)":CKEDITOR.env.ie&&!CKEDITOR.env.edge?"javascript:void(function(){"+encodeURIComponent(h)+"}())":"",c=CKEDITOR.dom.element.createFromHtml('\x3ciframe src\x3d"'+h+'" frameBorder\x3d"0"\x3e\x3c/iframe\x3e');
c.setStyles({width:"100%",height:"100%"});c.addClass("cke_wysiwyg_frame").addClass("cke_reset");h=a.ui.space("contents");h.append(c);var m=CKEDITOR.env.ie&&!CKEDITOR.env.edge||CKEDITOR.env.gecko;if(m)c.on("load",e);var f=a.title,n=a.fire("ariaEditorHelpLabel",{}).label;f&&(CKEDITOR.env.ie&&n&&(f+=", "+n),c.setAttribute("title",f));if(n){var f=CKEDITOR.tools.getNextId(),p=CKEDITOR.dom.element.createFromHtml('\x3cspan id\x3d"'+f+'" class\x3d"cke_voice_label"\x3e'+n+"\x3c/span\x3e");h.append(p,1);c.setAttribute("aria-describedby",
f)}a.on("beforeModeUnload",function(a){a.removeListener();p&&p.remove()});c.setAttributes({tabIndex:a.tabIndex,allowTransparency:"true"});!m&&e();a.fire("ariaWidget",c)})}});CKEDITOR.editor.prototype.addContentsCss=function(a){var b=this.config,d=b.contentsCss;CKEDITOR.tools.isArray(d)||(b.contentsCss=d?[d]:[]);b.contentsCss.push(a)};d=CKEDITOR.tools.createClass({$:function(){this.base.apply(this,arguments);this._.frameLoadedHandler=CKEDITOR.tools.addFunction(function(b){CKEDITOR.tools.setTimeout(a,
0,this,b)},this);this._.docTitle=this.getWindow().getFrame().getAttribute("title")},base:CKEDITOR.editable,proto:{setData:function(a,d){var e=this.editor;if(d)this.setHtml(a),this.fixInitialSelection(),e.fire("dataReady");else{this._.isLoadingData=!0;e._.dataStore={id:1};var h=e.config,c=h.fullPage,m=h.docType,f=CKEDITOR.tools.buildStyleHtml(b()).replace(/<style>/,'\x3cstyle data-cke-temp\x3d"1"\x3e');c||(f+=CKEDITOR.tools.buildStyleHtml(e.config.contentsCss));var n=h.baseHref?'\x3cbase href\x3d"'+
h.baseHref+'" data-cke-temp\x3d"1" /\x3e':"";c&&(a=a.replace(/<!DOCTYPE[^>]*>/i,function(a){e.docType=m=a;return""}).replace(/<\?xml\s[^\?]*\?>/i,function(a){e.xmlDeclaration=a;return""}));a=e.dataProcessor.toHtml(a);c?(/<body[\s|>]/.test(a)||(a="\x3cbody\x3e"+a),/<html[\s|>]/.test(a)||(a="\x3chtml\x3e"+a+"\x3c/html\x3e"),/<head[\s|>]/.test(a)?/<title[\s|>]/.test(a)||(a=a.replace(/<head[^>]*>/,"$\x26\x3ctitle\x3e\x3c/title\x3e")):a=a.replace(/<html[^>]*>/,"$\x26\x3chead\x3e\x3ctitle\x3e\x3c/title\x3e\x3c/head\x3e"),
n&&(a=a.replace(/<head[^>]*?>/,"$\x26"+n)),a=a.replace(/<\/head\s*>/,f+"$\x26"),a=m+a):a=h.docType+'\x3chtml dir\x3d"'+h.contentsLangDirection+'" lang\x3d"'+(h.contentsLanguage||e.langCode)+'"\x3e\x3chead\x3e\x3ctitle\x3e'+this._.docTitle+"\x3c/title\x3e"+n+f+"\x3c/head\x3e\x3cbody"+(h.bodyId?' id\x3d"'+h.bodyId+'"':"")+(h.bodyClass?' class\x3d"'+h.bodyClass+'"':"")+"\x3e"+a+"\x3c/body\x3e\x3c/html\x3e";CKEDITOR.env.gecko&&(a=a.replace(/<body/,'\x3cbody contenteditable\x3d"true" '),2E4>CKEDITOR.env.version&&
(a=a.replace(/<body[^>]*>/,"$\x26\x3c!-- cke-content-start --\x3e")));h='\x3cscript id\x3d"cke_actscrpt" type\x3d"text/javascript"'+(CKEDITOR.env.ie?' defer\x3d"defer" ':"")+"\x3evar wasLoaded\x3d0;function onload(){if(!wasLoaded)window.parent.CKEDITOR.tools.callFunction("+this._.frameLoadedHandler+",window);wasLoaded\x3d1;}"+(CKEDITOR.env.ie?"onload();":'document.addEventListener("DOMContentLoaded", onload, false );')+"\x3c/script\x3e";CKEDITOR.env.ie&&9>CKEDITOR.env.version&&(h+='\x3cscript id\x3d"cke_shimscrpt"\x3ewindow.parent.CKEDITOR.tools.enableHtml5Elements(document)\x3c/script\x3e');
n&&CKEDITOR.env.ie&&10>CKEDITOR.env.version&&(h+='\x3cscript id\x3d"cke_basetagscrpt"\x3evar baseTag \x3d document.querySelector( "base" );baseTag.href \x3d baseTag.href;\x3c/script\x3e');a=a.replace(/(?=\s*<\/(:?head)>)/,h);this.clearCustomData();this.clearListeners();e.fire("contentDomUnload");var p=this.getDocument();try{p.write(a)}catch(q){setTimeout(function(){p.write(a)},0)}}},getData:function(a){if(a)return this.getHtml();a=this.editor;var b=a.config,d=b.fullPage,e=d&&a.docType,c=d&&a.xmlDeclaration,
m=this.getDocument(),d=d?m.getDocumentElement().getOuterHtml():m.getBody().getHtml();CKEDITOR.env.gecko&&b.enterMode!=CKEDITOR.ENTER_BR&&(d=d.replace(/<br>(?=\s*(:?$|<\/body>))/,""));d=a.dataProcessor.toDataFormat(d);c&&(d=c+"\n"+d);e&&(d=e+"\n"+d);return d},focus:function(){this._.isLoadingData?this._.isPendingFocus=!0:d.baseProto.focus.call(this)},detach:function(){var a=this.editor,b=a.document,e;try{e=a.window.getFrame()}catch(h){}d.baseProto.detach.call(this);this.clearCustomData();b.getDocumentElement().clearCustomData();
CKEDITOR.tools.removeFunction(this._.frameLoadedHandler);e&&e.getParent()?(e.clearCustomData(),(a=e.removeCustomData("onResize"))&&a.removeListener(),e.remove()):CKEDITOR.warn("editor-destroy-iframe")}}})}(),CKEDITOR.config.disableObjectResizing=!1,CKEDITOR.config.disableNativeTableHandles=!0,CKEDITOR.config.disableNativeSpellChecker=!0,CKEDITOR.config.plugins="dialogui,dialog,a11yhelp,about,basicstyles,blockquote,notification,button,toolbar,clipboard,panel,floatpanel,menu,contextmenu,elementspath,indent,indentlist,list,enterkey,entities,popup,filebrowser,floatingspace,listblock,richcombo,format,horizontalrule,htmlwriter,image,fakeobjects,link,magicline,maximize,pastefromword,pastetext,removeformat,resize,menubutton,scayt,showborders,sourcearea,specialchar,stylescombo,tab,table,tabletools,tableselection,undo,lineutils,widgetselection,widget,filetools,notificationaggregator,uploadwidget,uploadimage,wsc,wysiwygarea",
CKEDITOR.config.skin="moono-lisa",function(){var a=function(a,b){var d=CKEDITOR.getUrl("plugins/"+b);a=a.split(",");for(var g=0;g<a.length;g++)CKEDITOR.skin.icons[a[g]]={path:d,offset:-a[++g],bgsize:a[++g]}};CKEDITOR.env.hidpi?a("about,0,,bold,24,,italic,48,,strike,72,,subscript,96,,superscript,120,,underline,144,,bidiltr,168,,bidirtl,192,,blockquote,216,,copy-rtl,240,,copy,264,,cut-rtl,288,,cut,312,,paste-rtl,336,,paste,360,,codesnippet,384,,bgcolor,408,,textcolor,432,,copyformatting,456,,creatediv,480,,docprops-rtl,504,,docprops,528,,embed,552,,embedsemantic,576,,find-rtl,600,,find,624,,replace,648,,flash,672,,button,696,,checkbox,720,,form,744,,hiddenfield,768,,imagebutton,792,,radio,816,,select-rtl,840,,select,864,,textarea-rtl,888,,textarea,912,,textfield-rtl,936,,textfield,960,,horizontalrule,984,,iframe,1008,,image,1032,,indent-rtl,1056,,indent,1080,,outdent-rtl,1104,,outdent,1128,,justifyblock,1152,,justifycenter,1176,,justifyleft,1200,,justifyright,1224,,language,1248,,anchor-rtl,1272,,anchor,1296,,link,1320,,unlink,1344,,bulletedlist-rtl,1368,,bulletedlist,1392,,numberedlist-rtl,1416,,numberedlist,1440,,mathjax,1464,,maximize,1488,,newpage-rtl,1512,,newpage,1536,,pagebreak-rtl,1560,,pagebreak,1584,,pastefromword-rtl,1608,,pastefromword,1632,,pastetext-rtl,1656,,pastetext,1680,,placeholder,1704,,preview-rtl,1728,,preview,1752,,print,1776,,removeformat,1800,,save,1824,,scayt,1848,,selectall,1872,,showblocks-rtl,1896,,showblocks,1920,,smiley,1944,,source-rtl,1968,,source,1992,,sourcedialog-rtl,2016,,sourcedialog,2040,,specialchar,2064,,table,2088,,templates-rtl,2112,,templates,2136,,uicolor,2160,,redo-rtl,2184,,redo,2208,,undo-rtl,2232,,undo,2256,,simplebox,4560,auto,spellchecker,2304,",
"icons_hidpi.png"):a("about,0,auto,bold,24,auto,italic,48,auto,strike,72,auto,subscript,96,auto,superscript,120,auto,underline,144,auto,bidiltr,168,auto,bidirtl,192,auto,blockquote,216,auto,copy-rtl,240,auto,copy,264,auto,cut-rtl,288,auto,cut,312,auto,paste-rtl,336,auto,paste,360,auto,codesnippet,384,auto,bgcolor,408,auto,textcolor,432,auto,copyformatting,456,auto,creatediv,480,auto,docprops-rtl,504,auto,docprops,528,auto,embed,552,auto,embedsemantic,576,auto,find-rtl,600,auto,find,624,auto,replace,648,auto,flash,672,auto,button,696,auto,checkbox,720,auto,form,744,auto,hiddenfield,768,auto,imagebutton,792,auto,radio,816,auto,select-rtl,840,auto,select,864,auto,textarea-rtl,888,auto,textarea,912,auto,textfield-rtl,936,auto,textfield,960,auto,horizontalrule,984,auto,iframe,1008,auto,image,1032,auto,indent-rtl,1056,auto,indent,1080,auto,outdent-rtl,1104,auto,outdent,1128,auto,justifyblock,1152,auto,justifycenter,1176,auto,justifyleft,1200,auto,justifyright,1224,auto,language,1248,auto,anchor-rtl,1272,auto,anchor,1296,auto,link,1320,auto,unlink,1344,auto,bulletedlist-rtl,1368,auto,bulletedlist,1392,auto,numberedlist-rtl,1416,auto,numberedlist,1440,auto,mathjax,1464,auto,maximize,1488,auto,newpage-rtl,1512,auto,newpage,1536,auto,pagebreak-rtl,1560,auto,pagebreak,1584,auto,pastefromword-rtl,1608,auto,pastefromword,1632,auto,pastetext-rtl,1656,auto,pastetext,1680,auto,placeholder,1704,auto,preview-rtl,1728,auto,preview,1752,auto,print,1776,auto,removeformat,1800,auto,save,1824,auto,scayt,1848,auto,selectall,1872,auto,showblocks-rtl,1896,auto,showblocks,1920,auto,smiley,1944,auto,source-rtl,1968,auto,source,1992,auto,sourcedialog-rtl,2016,auto,sourcedialog,2040,auto,specialchar,2064,auto,table,2088,auto,templates-rtl,2112,auto,templates,2136,auto,uicolor,2160,auto,redo-rtl,2184,auto,redo,2208,auto,undo-rtl,2232,auto,undo,2256,auto,simplebox,2280,auto,spellchecker,2304,auto",
"icons.png")}())})();