/*
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 b=/(^|.*[\\\/])ckeditor\.js(?:\?.*|;.*)?$/i,g={timestamp:"H4AG",version:"DEV",revision:"0",rnd:Math.floor(900*Math.random())+100,_:{pending:[],basePathSrcPattern:b},status:"unloaded",basePath:function(){var a=window.CKEDITOR_BASEPATH||"";if(!a)for(var e=document.getElementsByTagName("script"),g=0;g<e.length;g++){var k=e[g].src.match(b);if(k){a=k[1];break}}-1==a.indexOf(":/")&&"//"!=a.slice(0,2)&&(a=
0===a.indexOf("/")?location.href.match(/^.*?:\/\/[^\/]*/)[0]+a:location.href.match(/^[^\?]*\/(?:)/)[0]+a);if(!a)throw'The CKEditor installation path could not be automatically detected. Please set the global variable "CKEDITOR_BASEPATH" before creating editor instances.';return a}(),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(k){}}function b(){for(var a;a=e.shift();)a()}var e=[];return function(k){function d(){try{document.documentElement.doScroll("left")}catch(f){setTimeout(d,1);return}a()}e.push(k);"complete"===document.readyState&&setTimeout(a,1);if(1==e.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);k=!1;try{k=!window.frameElement}catch(c){}document.documentElement.doScroll&&k&&d()}}}()},e=window.CKEDITOR_GETURL;if(e){var a=g.getUrl;g.getUrl=function(b){return e.call(g,b)||a.call(g,b)}}return g}()),CKEDITOR.event||(CKEDITOR.event=function(){},CKEDITOR.event.implementOn=function(b){var g=CKEDITOR.event.prototype,e;for(e in g)null==b[e]&&(b[e]=g[e])},CKEDITOR.event.prototype=function(){function b(a){var b=
g(this);return b[a]||(b[a]=new e(a))}var g=function(a){a=a.getPrivate&&a.getPrivate()||a._||(a._={});return a.events||(a.events={})},e=function(a){this.name=a;this.listeners=[]};e.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(a,e){var g=b.call(this,a);CKEDITOR.tools.extend(g,e,!0)},on:function(a,e,g,n,k){function d(f,m,d,b){f={name:a,sender:this,editor:f,data:m,listenerData:n,stop:d,cancel:b,removeListener:c};
return!1===e.call(g,f)?!1:f.data}function c(){m.removeListener(a,e)}var f=b.call(this,a);if(0>f.getListenerIndex(e)){f=f.listeners;g||(g=this);isNaN(k)&&(k=10);var m=this;d.fn=e;d.priority=k;for(var t=f.length-1;0<=t;t--)if(f[t].priority<=k)return f.splice(t+1,0,d),{removeListener:c};f.unshift(d)}return{removeListener:c}},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},e=0,n=function(){e=1};return function(k,d,c){var f=g(this)[k];k=a;var m=e;a=e=0;if(f){var t=f.listeners;if(t.length)for(var t=t.slice(0),x,A=0;A<t.length;A++){if(f.errorProof)try{x=t[A].call(this,c,d,b,n)}catch(r){}else x=t[A].call(this,c,d,b,n);!1===x?e=1:"undefined"!=typeof x&&(d=x);if(a||e)break}}d=e?!1:"undefined"==typeof d?!0:d;a=k;e=m;return d}}(),fireOnce:function(a,b,e){b=
this.fire(a,b,e);delete g(this)[a];return b},removeListener:function(a,b){var e=g(this)[a];if(e){var n=e.getListenerIndex(b);0<=n&&e.listeners.splice(n,1)}},removeAllListeners:function(){var a=g(this),b;for(b in a)delete a[b]},hasListeners:function(a){return(a=g(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(b,g){b in{instanceReady:1,loaded:1}&&(this[b]=
!0);return CKEDITOR.event.prototype.fire.call(this,b,g,this)},CKEDITOR.editor.prototype.fireOnce=function(b,g){b in{instanceReady:1,loaded:1}&&(this[b]=!0);return CKEDITOR.event.prototype.fireOnce.call(this,b,g,this)},CKEDITOR.event.implementOn(CKEDITOR.editor.prototype)),CKEDITOR.env||(CKEDITOR.env=function(){var b=navigator.userAgent.toLowerCase(),g=b.match(/edge[ \/](\d+.?\d*)/),e=-1<b.indexOf("trident/"),e=!(!g&&!e),e={ie:e,edge:!!g,webkit:!e&&-1<b.indexOf(" applewebkit/"),air:-1<b.indexOf(" adobeair/"),
mac:-1<b.indexOf("macintosh"),quirks:"BackCompat"==document.compatMode&&(!document.documentMode||10>document.documentMode),mobile:-1<b.indexOf("mobile"),iOS:/(ipad|iphone|ipod)/.test(b),isCustomDomain:function(){if(!this.ie)return!1;var a=document.domain,b=window.location.hostname;return a!=b&&a!="["+b+"]"},secure:"https:"==location.protocol};e.gecko="Gecko"==navigator.product&&!e.webkit&&!e.ie;e.webkit&&(-1<b.indexOf("chrome")?e.chrome=!0:e.safari=!0);var a=0;e.ie&&(a=g?parseFloat(g[1]):e.quirks||
!document.documentMode?parseFloat(b.match(/msie (\d+)/)[1]):document.documentMode,e.ie9Compat=9==a,e.ie8Compat=8==a,e.ie7Compat=7==a,e.ie6Compat=7>a||e.quirks);e.gecko&&(g=b.match(/rv:([\d\.]+)/))&&(g=g[1].split("."),a=1E4*g[0]+100*(g[1]||0)+1*(g[2]||0));e.air&&(a=parseFloat(b.match(/ adobeair\/(\d+)/)[1]));e.webkit&&(a=parseFloat(b.match(/ applewebkit\/(\d+)/)[1]));e.version=a;e.isCompatible=!(e.ie&&7>a)&&!(e.gecko&&4E4>a)&&!(e.webkit&&534>a);e.hidpi=2<=window.devicePixelRatio;e.needsBrFiller=e.gecko||
e.webkit||e.ie&&10<a;e.needsNbspFiller=e.ie&&11>a;e.cssClass="cke_browser_"+(e.ie?"ie":e.gecko?"gecko":e.webkit?"webkit":"unknown");e.quirks&&(e.cssClass+=" cke_browser_quirks");e.ie&&(e.cssClass+=" cke_browser_ie"+(e.quirks?"6 cke_browser_iequirks":e.version));e.air&&(e.cssClass+=" cke_browser_air");e.iOS&&(e.cssClass+=" cke_browser_ios");e.hidpi&&(e.cssClass+=" cke_hidpi");return e}()),"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 b=document.createElement("script");b.type="text/javascript";b.src=CKEDITOR.basePath+"ckeditor.js";document.getElementsByTagName("head")[0].appendChild(b)}};CKEDITOR.loadFullCoreTimeout=0;CKEDITOR.add=function(b){(this._.pending||(this._.pending=[])).push(b)};(function(){CKEDITOR.domReady(function(){var b=CKEDITOR.loadFullCore,g=CKEDITOR.loadFullCoreTimeout;b&&(CKEDITOR.status="basic_ready",b&&b._load?b():g&&setTimeout(function(){CKEDITOR.loadFullCore&&
CKEDITOR.loadFullCore()},1E3*g))})})();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(b,g){CKEDITOR.verbosity&CKEDITOR.VERBOSITY_WARN&&CKEDITOR.fire("log",{type:"warn",errorCode:b,additionalData:g})},CKEDITOR.error=function(b,g){CKEDITOR.verbosity&CKEDITOR.VERBOSITY_ERROR&&CKEDITOR.fire("log",{type:"error",errorCode:b,additionalData:g})},CKEDITOR.on("log",
function(b){if(window.console&&window.console.log){var g=console[b.data.type]?b.data.type:"log",e=b.data.errorCode;if(b=b.data.additionalData)console[g]("[CKEDITOR] Error code: "+e+".",b);else console[g]("[CKEDITOR] Error code: "+e+".");console[g]("[CKEDITOR] For more information about this error go to http://docs.ckeditor.com/#!/guide/dev_errors-section-"+e)}},null,null,999),CKEDITOR.dom={},function(){var b=[],g=CKEDITOR.env.gecko?"-moz-":CKEDITOR.env.webkit?"-webkit-":CKEDITOR.env.ie?"-ms-":"",
e=/&/g,a=/>/g,h=/</g,l=/"/g,n=/&(lt|gt|amp|quot|nbsp|shy|#\d{1,5});/g,k={lt:"\x3c",gt:"\x3e",amp:"\x26",quot:'"',nbsp:" ",shy:"­"},d=function(c,f){return"#"==f[0]?String.fromCharCode(parseInt(f.slice(1),10)):k[f]};CKEDITOR.on("reset",function(){b=[]});CKEDITOR.tools={arrayCompare:function(c,f){if(!c&&!f)return!0;if(!c||!f||c.length!=f.length)return!1;for(var m=0;m<c.length;m++)if(c[m]!=f[m])return!1;return!0},getIndex:function(c,f){for(var m=0;m<c.length;++m)if(f(c[m]))return m;return-1},clone:function(c){var f;
if(c&&c instanceof Array){f=[];for(var m=0;m<c.length;m++)f[m]=CKEDITOR.tools.clone(c[m]);return f}if(null===c||"object"!=typeof c||c instanceof String||c instanceof Number||c instanceof Boolean||c instanceof Date||c instanceof RegExp||c.nodeType||c.window===c)return c;f=new c.constructor;for(m in c)f[m]=CKEDITOR.tools.clone(c[m]);return f},capitalize:function(c,f){return c.charAt(0).toUpperCase()+(f?c.slice(1):c.slice(1).toLowerCase())},extend:function(c){var f=arguments.length,m,d;"boolean"==typeof(m=
arguments[f-1])?f--:"boolean"==typeof(m=arguments[f-2])&&(d=arguments[f-1],f-=2);for(var a=1;a<f;a++){var b=arguments[a],k;for(k in b)if(!0===m||null==c[k])if(!d||k in d)c[k]=b[k]}return c},prototypedCopy:function(c){var f=function(){};f.prototype=c;return new f},copy:function(c){var f={},m;for(m in c)f[m]=c[m];return f},isArray:function(c){return"[object Array]"==Object.prototype.toString.call(c)},isEmpty:function(c){for(var f in c)if(c.hasOwnProperty(f))return!1;return!0},cssVendorPrefix:function(c,
f,m){if(m)return g+c+":"+f+";"+c+":"+f;m={};m[c]=f;m[g+c]=f;return m},cssStyleToDomStyle:function(){var c=document.createElement("div").style,f="undefined"!=typeof c.cssFloat?"cssFloat":"undefined"!=typeof c.styleFloat?"styleFloat":"float";return function(c){return"float"==c?f:c.replace(/-./g,function(f){return f.substr(1).toUpperCase()})}}(),buildStyleHtml:function(c){c=[].concat(c);for(var f,m=[],d=0;d<c.length;d++)if(f=c[d])/@import|[{}]/.test(f)?m.push("\x3cstyle\x3e"+f+"\x3c/style\x3e"):m.push('\x3clink type\x3d"text/css" rel\x3dstylesheet href\x3d"'+
f+'"\x3e');return m.join("")},htmlEncode:function(c){return void 0===c||null===c?"":String(c).replace(e,"\x26amp;").replace(a,"\x26gt;").replace(h,"\x26lt;")},htmlDecode:function(c){return c.replace(n,d)},htmlEncodeAttr:function(c){return CKEDITOR.tools.htmlEncode(c).replace(l,"\x26quot;")},htmlDecodeAttr:function(c){return CKEDITOR.tools.htmlDecode(c)},transformPlainTextToHtml:function(c,f){var m=f==CKEDITOR.ENTER_BR,d=this.htmlEncode(c.replace(/\r\n/g,"\n")),d=d.replace(/\t/g,"\x26nbsp;\x26nbsp; \x26nbsp;"),
a=f==CKEDITOR.ENTER_P?"p":"div";if(!m){var b=/\n{2}/g;if(b.test(d))var k="\x3c"+a+"\x3e",e="\x3c/"+a+"\x3e",d=k+d.replace(b,function(){return e+k})+e}d=d.replace(/\n/g,"\x3cbr\x3e");m||(d=d.replace(new RegExp("\x3cbr\x3e(?\x3d\x3c/"+a+"\x3e)"),function(f){return CKEDITOR.tools.repeat(f,2)}));d=d.replace(/^ | $/g,"\x26nbsp;");return d=d.replace(/(>|\s) /g,function(f,c){return c+"\x26nbsp;"}).replace(/ (?=<)/g,"\x26nbsp;")},getNextNumber:function(){var c=0;return function(){return++c}}(),getNextId:function(){return"cke_"+
this.getNextNumber()},getUniqueId:function(){for(var c="e",f=0;8>f;f++)c+=Math.floor(65536*(1+Math.random())).toString(16).substring(1);return c},override:function(c,f){var m=f(c);m.prototype=c.prototype;return m},setTimeout:function(c,f,m,d,a){a||(a=window);m||(m=a);return a.setTimeout(function(){d?c.apply(m,[].concat(d)):c.apply(m)},f||0)},trim:function(){var c=/(?:^[ \t\n\r]+)|(?:[ \t\n\r]+$)/g;return function(f){return f.replace(c,"")}}(),ltrim:function(){var c=/^[ \t\n\r]+/g;return function(f){return f.replace(c,
"")}}(),rtrim:function(){var c=/[ \t\n\r]+$/g;return function(f){return f.replace(c,"")}}(),indexOf:function(c,f){if("function"==typeof f)for(var m=0,d=c.length;m<d;m++){if(f(c[m]))return m}else{if(c.indexOf)return c.indexOf(f);m=0;for(d=c.length;m<d;m++)if(c[m]===f)return m}return-1},search:function(c,f){var m=CKEDITOR.tools.indexOf(c,f);return 0<=m?c[m]:null},bind:function(c,f){return function(){return c.apply(f,arguments)}},createClass:function(c){var f=c.$,m=c.base,d=c.privates||c._,a=c.proto;
c=c.statics;!f&&(f=function(){m&&this.base.apply(this,arguments)});if(d)var b=f,f=function(){var f=this._||(this._={}),c;for(c in d){var m=d[c];f[c]="function"==typeof m?CKEDITOR.tools.bind(m,this):m}b.apply(this,arguments)};m&&(f.prototype=this.prototypedCopy(m.prototype),f.prototype.constructor=f,f.base=m,f.baseProto=m.prototype,f.prototype.base=function(){this.base=m.prototype.base;m.apply(this,arguments);this.base=arguments.callee});a&&this.extend(f.prototype,a,!0);c&&this.extend(f,c,!0);return f},
addFunction:function(c,f){return b.push(function(){return c.apply(f||this,arguments)})-1},removeFunction:function(c){b[c]=null},callFunction:function(c){var f=b[c];return f&&f.apply(window,Array.prototype.slice.call(arguments,1))},cssLength:function(){var c=/^-?\d+\.?\d*px$/,f;return function(m){f=CKEDITOR.tools.trim(m+"")+"px";return c.test(f)?f:m||""}}(),convertToPx:function(){var c;return function(f){c||(c=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(c));return/%$/.test(f)?f:(c.setStyle("width",f),c.$.clientWidth)}}(),repeat:function(c,f){return Array(f+1).join(c)},tryThese:function(){for(var c,f=0,m=arguments.length;f<m;f++){var d=arguments[f];try{c=d();break}catch(a){}}return c},genKey:function(){return Array.prototype.slice.call(arguments).join("-")},defer:function(c){return function(){var f=arguments,m=this;window.setTimeout(function(){c.apply(m,f)},0)}},normalizeCssText:function(c,f){var m=
[],d,a=CKEDITOR.tools.parseCssText(c,!0,f);for(d in a)m.push(d+":"+a[d]);m.sort();return m.length?m.join(";")+";":""},convertRgbToHex:function(c){return c.replace(/(?:rgb\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*\))/gi,function(f,c,d,a){f=[c,d,a];for(c=0;3>c;c++)f[c]=("0"+parseInt(f[c],10).toString(16)).slice(-2);return"#"+f.join("")})},normalizeHex:function(c){return c.replace(/#(([0-9a-f]{3}){1,2})($|;|\s+)/gi,function(f,c,d,a){f=c.toLowerCase();3==f.length&&(f=f.split(""),f=[f[0],f[0],f[1],f[1],f[2],
f[2]].join(""));return"#"+f+a})},parseCssText:function(c,f,d){var a={};d&&(c=(new CKEDITOR.dom.element("span")).setAttribute("style",c).getAttribute("style")||"");c&&(c=CKEDITOR.tools.normalizeHex(CKEDITOR.tools.convertRgbToHex(c)));if(!c||";"==c)return a;c.replace(/&quot;/g,'"').replace(/\s*([^:;\s]+)\s*:\s*([^;]+)\s*(?=;|$)/g,function(c,d,m){f&&(d=d.toLowerCase(),"font-family"==d&&(m=m.replace(/\s*,\s*/g,",")),m=CKEDITOR.tools.trim(m));a[d]=m});return a},writeCssText:function(c,f){var d,a=[];for(d in c)a.push(d+
":"+c[d]);f&&a.sort();return a.join("; ")},objectCompare:function(c,f,d){var a;if(!c&&!f)return!0;if(!c||!f)return!1;for(a in c)if(c[a]!=f[a])return!1;if(!d)for(a in f)if(c[a]!=f[a])return!1;return!0},objectKeys:function(c){var f=[],d;for(d in c)f.push(d);return f},convertArrayToObject:function(c,f){var d={};1==arguments.length&&(f=!0);for(var a=0,b=c.length;a<b;++a)d[c[a]]=f;return d},fixDomain:function(){for(var c;;)try{c=window.parent.document.domain;break}catch(f){c=c?c.replace(/.+?(?:\.|$)/,
""):document.domain;if(!c)break;document.domain=c}return!!c},eventsBuffer:function(c,f,d){function a(){k=(new Date).getTime();b=!1;d?f.call(d):f()}var b,k=0;return{input:function(){if(!b){var f=(new Date).getTime()-k;f<c?b=setTimeout(a,c-f):a()}},reset:function(){b&&clearTimeout(b);b=k=0}}},enableHtml5Elements:function(c,f){for(var d="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(" "),
a=d.length,b;a--;)b=c.createElement(d[a]),f&&c.appendChild(b)},checkIfAnyArrayItemMatches:function(c,f){for(var d=0,a=c.length;d<a;++d)if(c[d].match(f))return!0;return!1},checkIfAnyObjectPropertyMatches:function(c,f){for(var d in c)if(d.match(f))return!0;return!1},keystrokeToString:function(c,f){var d=f&16711680,a=f&65535,b=CKEDITOR.env.mac,k=[],e=[];d&CKEDITOR.CTRL&&(k.push(b?"⌘":c[17]),e.push(b?c[224]:c[17]));d&CKEDITOR.ALT&&(k.push(b?"⌥":c[18]),e.push(c[18]));d&CKEDITOR.SHIFT&&(k.push(b?"⇧":c[16]),
e.push(c[16]));a&&(c[a]?(k.push(c[a]),e.push(c[a])):(k.push(String.fromCharCode(a)),e.push(String.fromCharCode(a))));return{display:k.join("+"),aria:e.join("+")}},transparentImageData:"data:image/gif;base64,R0lGODlhAQABAPABAP///wAAACH5BAEKAAAALAAAAAABAAEAAAICRAEAOw\x3d\x3d",getCookie:function(c){c=c.toLowerCase();for(var f=document.cookie.split(";"),d,a,b=0;b<f.length;b++)if(d=f[b].split("\x3d"),a=decodeURIComponent(CKEDITOR.tools.trim(d[0]).toLowerCase()),a===c)return decodeURIComponent(1<d.length?
d[1]:"");return null},setCookie:function(c,f){document.cookie=encodeURIComponent(c)+"\x3d"+encodeURIComponent(f)+";path\x3d/"},getCsrfToken:function(){var c=CKEDITOR.tools.getCookie("ckCsrfToken");if(!c||40!=c.length){var c=[],f="";if(window.crypto&&window.crypto.getRandomValues)c=new Uint8Array(40),window.crypto.getRandomValues(c);else for(var d=0;40>d;d++)c.push(Math.floor(256*Math.random()));for(d=0;d<c.length;d++)var a="abcdefghijklmnopqrstuvwxyz0123456789".charAt(c[d]%36),f=f+(.5<Math.random()?
a.toUpperCase():a);c=f;CKEDITOR.tools.setCookie("ckCsrfToken",c)}return c},escapeCss:function(c){return c?window.CSS&&CSS.escape?CSS.escape(c):isNaN(parseInt(c.charAt(0),10))?c:"\\3"+c.charAt(0)+" "+c.substring(1,c.length):""},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"},_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(c){var f=[],d=[],d=this._findColor(c);d.length&&(f.color=d[0],CKEDITOR.tools.array.forEach(d,function(f){c=c.replace(f,"")}));if(c=CKEDITOR.tools.trim(c))f.unprocessed=c;return f},margin:function(c){function f(f){d.top=
a[f[0]];d.right=a[f[1]];d.bottom=a[f[2]];d.left=a[f[3]]}var d={},a=c.match(/(?:\-?[\.\d]+(?:%|\w*)|auto|inherit|initial|unset)/g)||["0px"];switch(a.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 d},_findColor:function(c){var f=[],d=CKEDITOR.tools.array,f=f.concat(c.match(this._rgbaRegExp)||[]),f=f.concat(c.match(this._hslaRegExp)||[]);return f=f.concat(d.filter(c.split(/\s+/),function(f){return f.match(/^\#[a-f0-9]{3}(?:[a-f0-9]{3})?$/gi)?
!0:f.toLowerCase()in CKEDITOR.tools.style.parse._colors}))}}},array:{filter:function(c,f,d){var a=[];this.forEach(c,function(b,k){f.call(d,b,k,c)&&a.push(b)});return a},forEach:function(c,f,d){var a=c.length,b;for(b=0;b<a;b++)f.call(d,c[b],b,c)},map:function(c,f,d){for(var a=[],b=0;b<c.length;b++)a.push(f.call(d,c[b],b,c));return a},reduce:function(c,f,d,a){for(var b=0;b<c.length;b++)d=f.call(a,d,c[b],b,c);return d}}};CKEDITOR.tools.array.indexOf=CKEDITOR.tools.indexOf;CKEDITOR.tools.array.isArray=
CKEDITOR.tools.isArray}(),CKEDITOR.dtd=function(){var b=CKEDITOR.tools.extend,g=function(c,f){for(var d=CKEDITOR.tools.clone(c),a=1;a<arguments.length;a++){f=arguments[a];for(var b in f)delete d[b]}return d},e={},a={},h={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},n={},k={"#":1},
d={center:1,dir:1,noframes:1};b(e,{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},k,{acronym:1,applet:1,basefont:1,big:1,font:1,isindex:1,strike:1,style:1,tt:1});b(a,h,e,d);g={a:g(e,{a:1,
button:1}),abbr:e,address:a,area:n,article:a,aside:a,audio:b({source:1,track:1},a),b:e,base:n,bdi:e,bdo:e,blockquote:a,body:a,br:n,button:g(e,{a:1,button:1}),canvas:e,caption:a,cite:e,code:e,col:n,colgroup:{col:1},command:n,datalist:b({option:1},e),dd:a,del:e,details:b({summary:1},a),dfn:e,div:a,dl:{dt:1,dd:1},dt:a,em:e,embed:n,fieldset:b({legend:1},a),figcaption:a,figure:b({figcaption:1},a),footer:a,form:a,h1:e,h2:e,h3:e,h4:e,h5:e,h6:e,head:b({title:1,base:1},l),header:a,hgroup:{h1:1,h2:1,h3:1,h4:1,
h5:1,h6:1},hr:n,html:b({head:1,body:1},a,l),i:e,iframe:k,img:n,input:n,ins:e,kbd:e,keygen:n,label:e,legend:e,li:a,link:n,main:a,map:a,mark:e,menu:b({li:1},a),meta:n,meter:g(e,{meter:1}),nav:a,noscript:b({link:1,meta:1,style:1},e),object:b({param:1},e),ol:{li:1},optgroup:{option:1},option:k,output:e,p:e,param:n,pre:e,progress:g(e,{progress:1}),q:e,rp:e,rt:e,ruby:b({rp:1,rt:1},e),s:e,samp:e,script:k,section:a,select:{optgroup:1,option:1},small:e,source:n,span:e,strong:e,style:k,sub:e,summary:b({h1:1,
h2:1,h3:1,h4:1,h5:1,h6:1},e),sup:e,table:{caption:1,colgroup:1,thead:1,tfoot:1,tbody:1,tr:1},tbody:{tr:1},td:a,textarea:k,tfoot:{tr:1},th:a,thead:{tr:1},time:g(e,{time:1}),title:k,tr:{th:1,td:1},track:n,u:e,ul:{li:1},"var":e,video:b({source:1,track:1},a),wbr:n,acronym:e,applet:b({param:1},a),basefont:n,big:e,center:a,dialog:n,dir:{li:1},font:e,isindex:n,noframes:a,strike:e,tt:e};b(g,{$block:b({audio:1,dd:1,dt:1,figcaption:1,li:1,video:1},h,d),$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:e,$list:{dl:1,ol:1,ul:1},$listItem:{dd:1,dt:1,li:1},$nonBodyContent:b({body:1,head:1,html:1},g.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 g}(),
CKEDITOR.dom.event=function(b){this.$=b},CKEDITOR.dom.event.prototype={getKey:function(){return this.$.keyCode||this.$.which},getKeystroke:function(){var b=this.getKey();if(this.$.ctrlKey||this.$.metaKey)b+=CKEDITOR.CTRL;this.$.shiftKey&&(b+=CKEDITOR.SHIFT);this.$.altKey&&(b+=CKEDITOR.ALT);return b},preventDefault:function(b){var g=this.$;g.preventDefault?g.preventDefault():g.returnValue=!1;b&&this.stopPropagation()},stopPropagation:function(){var b=this.$;b.stopPropagation?b.stopPropagation():b.cancelBubble=
!0},getTarget:function(){var b=this.$.target||this.$.srcElement;return b?new CKEDITOR.dom.node(b):null},getPhase:function(){return this.$.eventPhase||2},getPageOffset:function(){var b=this.getTarget().getDocument().$;return{x:this.$.pageX||this.$.clientX+(b.documentElement.scrollLeft||b.body.scrollLeft),y:this.$.pageY||this.$.clientY+(b.documentElement.scrollTop||b.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(b){b&&(this.$=b)},CKEDITOR.dom.domObject.prototype=function(){var b=function(b,e){return function(a){"undefined"!=typeof CKEDITOR&&b.fire(e,new CKEDITOR.dom.event(a))}};return{getPrivate:function(){var b;(b=this.getCustomData("_"))||this.setCustomData("_",b={});return b},on:function(g){var e=this.getCustomData("_cke_nativeListeners");e||(e={},this.setCustomData("_cke_nativeListeners",e));e[g]||(e=e[g]=b(this,g),this.$.addEventListener?
this.$.addEventListener(g,e,!!CKEDITOR.event.useCapture):this.$.attachEvent&&this.$.attachEvent("on"+g,e));return CKEDITOR.event.prototype.on.apply(this,arguments)},removeListener:function(b){CKEDITOR.event.prototype.removeListener.apply(this,arguments);if(!this.hasListeners(b)){var e=this.getCustomData("_cke_nativeListeners"),a=e&&e[b];a&&(this.$.removeEventListener?this.$.removeEventListener(b,a,!1):this.$.detachEvent&&this.$.detachEvent("on"+b,a),delete e[b])}},removeAllListeners:function(){var b=
this.getCustomData("_cke_nativeListeners"),e;for(e in b){var a=b[e];this.$.detachEvent?this.$.detachEvent("on"+e,a):this.$.removeEventListener&&this.$.removeEventListener(e,a,!1);delete b[e]}CKEDITOR.event.prototype.removeAllListeners.call(this)}}}(),function(b){var g={};CKEDITOR.on("reset",function(){g={}});b.equals=function(b){try{return b&&b.$===this.$}catch(a){return!1}};b.setCustomData=function(b,a){var h=this.getUniqueId();(g[h]||(g[h]={}))[b]=a;return this};b.getCustomData=function(b){var a=
this.$["data-cke-expando"];return(a=a&&g[a])&&b in a?a[b]:null};b.removeCustomData=function(b){var a=this.$["data-cke-expando"],a=a&&g[a],h,l;a&&(h=a[b],l=b in a,delete a[b]);return l?h:null};b.clearCustomData=function(){this.removeAllListeners();var b=this.$["data-cke-expando"];b&&delete g[b]};b.getUniqueId=function(){return this.$["data-cke-expando"]||(this.$["data-cke-expando"]=CKEDITOR.tools.getNextNumber())};CKEDITOR.event.implementOn(b)}(CKEDITOR.dom.domObject.prototype),CKEDITOR.dom.node=function(b){return b?
new CKEDITOR.dom[b.nodeType==CKEDITOR.NODE_DOCUMENT?"document":b.nodeType==CKEDITOR.NODE_ELEMENT?"element":b.nodeType==CKEDITOR.NODE_TEXT?"text":b.nodeType==CKEDITOR.NODE_COMMENT?"comment":b.nodeType==CKEDITOR.NODE_DOCUMENT_FRAGMENT?"documentFragment":"domObject"](b):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(b,g){b.append(this,g);return b},clone:function(b,g){function e(a){a["data-cke-expando"]&&(a["data-cke-expando"]=!1);if(a.nodeType==CKEDITOR.NODE_ELEMENT||a.nodeType==CKEDITOR.NODE_DOCUMENT_FRAGMENT)if(g||a.nodeType!=CKEDITOR.NODE_ELEMENT||a.removeAttribute("id",!1),b){a=a.childNodes;for(var h=0;h<a.length;h++)e(a[h])}}
function a(e){if(e.type==CKEDITOR.NODE_ELEMENT||e.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT){if(e.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT){var h=e.getName();":"==h[0]&&e.renameNode(h.substring(1))}if(b)for(h=0;h<e.getChildCount();h++)a(e.getChild(h))}}var h=this.$.cloneNode(b);e(h);h=new CKEDITOR.dom.node(h);CKEDITOR.env.ie&&9>CKEDITOR.env.version&&(this.type==CKEDITOR.NODE_ELEMENT||this.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT)&&a(h);return h},hasPrevious:function(){return!!this.$.previousSibling},hasNext:function(){return!!this.$.nextSibling},
insertAfter:function(b){b.$.parentNode.insertBefore(this.$,b.$.nextSibling);return b},insertBefore:function(b){b.$.parentNode.insertBefore(this.$,b.$);return b},insertBeforeMe:function(b){this.$.parentNode.insertBefore(b.$,this.$);return b},getAddress:function(b){for(var g=[],e=this.getDocument().$.documentElement,a=this.$;a&&a!=e;){var h=a.parentNode;h&&g.unshift(this.getIndex.call({$:a},b));a=h}return g},getDocument:function(){return new CKEDITOR.dom.document(this.$.ownerDocument||this.$.parentNode.ownerDocument)},
getIndex:function(b){function g(a,b){var d=b?a.nextSibling:a.previousSibling;return d&&d.nodeType==CKEDITOR.NODE_TEXT?e(d)?g(d,b):d:null}function e(a){return!a.nodeValue||a.nodeValue==CKEDITOR.dom.selection.FILLING_CHAR_SEQUENCE}var a=this.$,h=-1,l;if(!this.$.parentNode||b&&a.nodeType==CKEDITOR.NODE_TEXT&&e(a)&&!g(a)&&!g(a,!0))return-1;do b&&a!=this.$&&a.nodeType==CKEDITOR.NODE_TEXT&&(l||e(a))||(h++,l=a.nodeType==CKEDITOR.NODE_TEXT);while(a=a.previousSibling);return h},getNextSourceNode:function(b,
g,e){if(e&&!e.call){var a=e;e=function(b){return!b.equals(a)}}b=!b&&this.getFirst&&this.getFirst();var h;if(!b){if(this.type==CKEDITOR.NODE_ELEMENT&&e&&!1===e(this,!0))return null;b=this.getNext()}for(;!b&&(h=(h||this).getParent());){if(e&&!1===e(h,!0))return null;b=h.getNext()}return!b||e&&!1===e(b)?null:g&&g!=b.type?b.getNextSourceNode(!1,g,e):b},getPreviousSourceNode:function(b,g,e){if(e&&!e.call){var a=e;e=function(b){return!b.equals(a)}}b=!b&&this.getLast&&this.getLast();var h;if(!b){if(this.type==
CKEDITOR.NODE_ELEMENT&&e&&!1===e(this,!0))return null;b=this.getPrevious()}for(;!b&&(h=(h||this).getParent());){if(e&&!1===e(h,!0))return null;b=h.getPrevious()}return!b||e&&!1===e(b)?null:g&&b.type!=g?b.getPreviousSourceNode(!1,g,e):b},getPrevious:function(b){var g=this.$,e;do e=(g=g.previousSibling)&&10!=g.nodeType&&new CKEDITOR.dom.node(g);while(e&&b&&!b(e));return e},getNext:function(b){var g=this.$,e;do e=(g=g.nextSibling)&&new CKEDITOR.dom.node(g);while(e&&b&&!b(e));return e},getParent:function(b){var g=
this.$.parentNode;return g&&(g.nodeType==CKEDITOR.NODE_ELEMENT||b&&g.nodeType==CKEDITOR.NODE_DOCUMENT_FRAGMENT)?new CKEDITOR.dom.node(g):null},getParents:function(b){var g=this,e=[];do e[b?"push":"unshift"](g);while(g=g.getParent());return e},getCommonAncestor:function(b){if(b.equals(this))return this;if(b.contains&&b.contains(this))return b;var g=this.contains?this:this.getParent();do if(g.contains(b))return g;while(g=g.getParent());return null},getPosition:function(b){var g=this.$,e=b.$;if(g.compareDocumentPosition)return g.compareDocumentPosition(e);
if(g==e)return CKEDITOR.POSITION_IDENTICAL;if(this.type==CKEDITOR.NODE_ELEMENT&&b.type==CKEDITOR.NODE_ELEMENT){if(g.contains){if(g.contains(e))return CKEDITOR.POSITION_CONTAINS+CKEDITOR.POSITION_PRECEDING;if(e.contains(g))return CKEDITOR.POSITION_IS_CONTAINED+CKEDITOR.POSITION_FOLLOWING}if("sourceIndex"in g)return 0>g.sourceIndex||0>e.sourceIndex?CKEDITOR.POSITION_DISCONNECTED:g.sourceIndex<e.sourceIndex?CKEDITOR.POSITION_PRECEDING:CKEDITOR.POSITION_FOLLOWING}g=this.getAddress();b=b.getAddress();
for(var e=Math.min(g.length,b.length),a=0;a<e;a++)if(g[a]!=b[a])return g[a]<b[a]?CKEDITOR.POSITION_PRECEDING:CKEDITOR.POSITION_FOLLOWING;return g.length<b.length?CKEDITOR.POSITION_CONTAINS+CKEDITOR.POSITION_PRECEDING:CKEDITOR.POSITION_IS_CONTAINED+CKEDITOR.POSITION_FOLLOWING},getAscendant:function(b,g){var e=this.$,a,h;g||(e=e.parentNode);"function"==typeof b?(h=!0,a=b):(h=!1,a=function(a){a="string"==typeof a.nodeName?a.nodeName.toLowerCase():"";return"string"==typeof b?a==b:a in b});for(;e;){if(a(h?
new CKEDITOR.dom.node(e):e))return new CKEDITOR.dom.node(e);try{e=e.parentNode}catch(l){e=null}}return null},hasAscendant:function(b,g){var e=this.$;g||(e=e.parentNode);for(;e;){if(e.nodeName&&e.nodeName.toLowerCase()==b)return!0;e=e.parentNode}return!1},move:function(b,g){b.append(this.remove(),g)},remove:function(b){var g=this.$,e=g.parentNode;if(e){if(b)for(;b=g.firstChild;)e.insertBefore(g.removeChild(b),g);e.removeChild(g)}return this},replace:function(b){this.insertBefore(b);b.remove()},trim:function(){this.ltrim();
this.rtrim()},ltrim:function(){for(var b;this.getFirst&&(b=this.getFirst());){if(b.type==CKEDITOR.NODE_TEXT){var g=CKEDITOR.tools.ltrim(b.getText()),e=b.getLength();if(g)g.length<e&&(b.split(e-g.length),this.$.removeChild(this.$.firstChild));else{b.remove();continue}}break}},rtrim:function(){for(var b;this.getLast&&(b=this.getLast());){if(b.type==CKEDITOR.NODE_TEXT){var g=CKEDITOR.tools.rtrim(b.getText()),e=b.getLength();if(g)g.length<e&&(b.split(g.length),this.$.lastChild.parentNode.removeChild(this.$.lastChild));
else{b.remove();continue}}break}CKEDITOR.env.needsBrFiller&&(b=this.$.lastChild)&&1==b.type&&"br"==b.nodeName.toLowerCase()&&b.parentNode.removeChild(b)},isReadOnly:function(b){var g=this;this.type!=CKEDITOR.NODE_ELEMENT&&(g=this.getParent());CKEDITOR.env.edge&&g&&g.is("textarea","input")&&(b=!0);if(!b&&g&&"undefined"!=typeof g.$.isContentEditable)return!(g.$.isContentEditable||g.data("cke-editable"));for(;g;){if(g.data("cke-editable"))return!1;if(g.hasAttribute("contenteditable"))return"false"==
g.getAttribute("contenteditable");g=g.getParent()}return!0}}),CKEDITOR.dom.window=function(b){CKEDITOR.dom.domObject.call(this,b)},CKEDITOR.dom.window.prototype=new CKEDITOR.dom.domObject,CKEDITOR.tools.extend(CKEDITOR.dom.window.prototype,{focus:function(){this.$.focus()},getViewPaneSize:function(){var b=this.$.document,g="CSS1Compat"==b.compatMode;return{width:(g?b.documentElement.clientWidth:b.body.clientWidth)||0,height:(g?b.documentElement.clientHeight:b.body.clientHeight)||0}},getScrollPosition:function(){var b=
this.$;if("pageXOffset"in b)return{x:b.pageXOffset||0,y:b.pageYOffset||0};b=b.document;return{x:b.documentElement.scrollLeft||b.body.scrollLeft||0,y:b.documentElement.scrollTop||b.body.scrollTop||0}},getFrame:function(){var b=this.$.frameElement;return b?new CKEDITOR.dom.element.get(b):null}}),CKEDITOR.dom.document=function(b){CKEDITOR.dom.domObject.call(this,b)},CKEDITOR.dom.document.prototype=new CKEDITOR.dom.domObject,CKEDITOR.tools.extend(CKEDITOR.dom.document.prototype,{type:CKEDITOR.NODE_DOCUMENT,
appendStyleSheet:function(b){if(this.$.createStyleSheet)this.$.createStyleSheet(b);else{var g=new CKEDITOR.dom.element("link");g.setAttributes({rel:"stylesheet",type:"text/css",href:b});this.getHead().append(g)}},appendStyleText:function(b){if(this.$.createStyleSheet){var g=this.$.createStyleSheet("");g.cssText=b}else{var e=new CKEDITOR.dom.element("style",this);e.append(new CKEDITOR.dom.text(b,this));this.getHead().append(e)}return g||e.$.sheet},createElement:function(b,g){var e=new CKEDITOR.dom.element(b,
this);g&&(g.attributes&&e.setAttributes(g.attributes),g.styles&&e.setStyles(g.styles));return e},createText:function(b){return new CKEDITOR.dom.text(b,this)},focus:function(){this.getWindow().focus()},getActive:function(){var b;try{b=this.$.activeElement}catch(g){return null}return new CKEDITOR.dom.element(b)},getById:function(b){return(b=this.$.getElementById(b))?new CKEDITOR.dom.element(b):null},getByAddress:function(b,g){for(var e=this.$.documentElement,a=0;e&&a<b.length;a++){var h=b[a];if(g)for(var l=
-1,n=0;n<e.childNodes.length;n++){var k=e.childNodes[n];if(!0!==g||3!=k.nodeType||!k.previousSibling||3!=k.previousSibling.nodeType)if(l++,l==h){e=k;break}}else e=e.childNodes[h]}return e?new CKEDITOR.dom.node(e):null},getElementsByTag:function(b,g){CKEDITOR.env.ie&&8>=document.documentMode||!g||(b=g+":"+b);return new CKEDITOR.dom.nodeList(this.$.getElementsByTagName(b))},getHead:function(){var b=this.$.getElementsByTagName("head")[0];return b=b?new CKEDITOR.dom.element(b):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(b){this.$.open("text/html","replace");CKEDITOR.env.ie&&(b=b.replace(/(?:^\s*<!DOCTYPE[^>]*?>)|^/i,'$\x26\n\x3cscript data-cke-temp\x3d"1"\x3e('+CKEDITOR.tools.fixDomain+")();\x3c/script\x3e"));this.$.write(b);this.$.close()},find:function(b){return new CKEDITOR.dom.nodeList(this.$.querySelectorAll(b))},
findOne:function(b){return(b=this.$.querySelector(b))?new CKEDITOR.dom.element(b):null},_getHtml5ShivFrag:function(){var b=this.getCustomData("html5ShivFrag");b||(b=this.$.createDocumentFragment(),CKEDITOR.tools.enableHtml5Elements(b,!0),this.setCustomData("html5ShivFrag",b));return b}}),CKEDITOR.dom.nodeList=function(b){this.$=b},CKEDITOR.dom.nodeList.prototype={count:function(){return this.$.length},getItem:function(b){return 0>b||b>=this.$.length?null:(b=this.$[b])?new CKEDITOR.dom.node(b):null}},
CKEDITOR.dom.element=function(b,g){"string"==typeof b&&(b=(g?g.$:document).createElement(b));CKEDITOR.dom.domObject.call(this,b)},CKEDITOR.dom.element.get=function(b){return(b="string"==typeof b?document.getElementById(b)||document.getElementsByName(b)[0]:b)&&(b.$?b:new CKEDITOR.dom.element(b))},CKEDITOR.dom.element.prototype=new CKEDITOR.dom.node,CKEDITOR.dom.element.createFromHtml=function(b,g){var e=new CKEDITOR.dom.element("div",g);e.setHtml(b);return e.getFirst().remove()},CKEDITOR.dom.element.setMarker=
function(b,g,e,a){var h=g.getCustomData("list_marker_id")||g.setCustomData("list_marker_id",CKEDITOR.tools.getNextNumber()).getCustomData("list_marker_id"),l=g.getCustomData("list_marker_names")||g.setCustomData("list_marker_names",{}).getCustomData("list_marker_names");b[h]=g;l[e]=1;return g.setCustomData(e,a)},CKEDITOR.dom.element.clearAllMarkers=function(b){for(var g in b)CKEDITOR.dom.element.clearMarkers(b,b[g],1)},CKEDITOR.dom.element.clearMarkers=function(b,g,e){var a=g.getCustomData("list_marker_names"),
h=g.getCustomData("list_marker_id"),l;for(l in a)g.removeCustomData(l);g.removeCustomData("list_marker_names");e&&(g.removeCustomData("list_marker_id"),delete b[h])},function(){function b(a,d){return-1<(" "+a+" ").replace(l," ").indexOf(" "+d+" ")}function g(a){var d=!0;a.$.id||(a.$.id="cke_tmp_"+CKEDITOR.tools.getNextNumber(),d=!1);return function(){d||a.removeAttribute("id")}}function e(a,d){var c=CKEDITOR.tools.escapeCss(a.$.id);return"#"+c+" "+d.split(/,\s*/).join(", #"+c+" ")}function a(a){for(var d=
0,c=0,f=n[a].length;c<f;c++)d+=parseFloat(this.getComputedStyle(n[a][c])||0,10)||0;return d}var h=document.createElement("_").classList,h="undefined"!==typeof h&&null!==String(h.add).match(/\[Native code\]/gi),l=/[\n\t\r]/g;CKEDITOR.tools.extend(CKEDITOR.dom.element.prototype,{type:CKEDITOR.NODE_ELEMENT,addClass:h?function(a){this.$.classList.add(a);return this}:function(a){var d=this.$.className;d&&(b(d,a)||(d+=" "+a));this.$.className=d||a;return this},removeClass:h?function(a){var d=this.$;d.classList.remove(a);
d.className||d.removeAttribute("class");return this}:function(a){var d=this.getAttribute("class");d&&b(d,a)&&((d=d.replace(new RegExp("(?:^|\\s+)"+a+"(?\x3d\\s|$)"),"").replace(/^\s+/,""))?this.setAttribute("class",d):this.removeAttribute("class"));return this},hasClass:function(a){return b(this.$.className,a)},append:function(a,d){"string"==typeof a&&(a=this.getDocument().createElement(a));d?this.$.insertBefore(a.$,this.$.firstChild):this.$.appendChild(a.$);return a},appendHtml:function(a){if(this.$.childNodes.length){var d=
new CKEDITOR.dom.element("div",this.getDocument());d.setHtml(a);d.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,d){var c=new CKEDITOR.dom.range(this.getDocument());c.setStartAfter(this);c.setEndAfter(a);var f=c.extractContents(!1,d||!1),b;c.insertNode(this.remove());if(CKEDITOR.env.ie&&!CKEDITOR.env.edge){for(c=new CKEDITOR.dom.element("div");b=f.getFirst();)b.$.style.backgroundColor&&(b.$.style.backgroundColor=b.$.style.backgroundColor),c.append(b);c.insertAfter(this);c.remove(!0)}else f.insertAfterNode(this)},contains:document.compareDocumentPosition?function(a){return!!(this.$.compareDocumentPosition(a.$)&
16)}:function(a){var d=this.$;return a.type!=CKEDITOR.NODE_ELEMENT?d.contains(a.getParent().$):d!=a.$&&d.contains(a.$)},focus:function(){function a(){try{this.$.focus()}catch(d){}}return function(d){d?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 d=this.$;if(this.getParent())return d.innerHTML=a;var c=this.getDocument()._getHtml5ShivFrag();c.appendChild(d);d.innerHTML=a;c.removeChild(d);return a}catch(f){this.$.innerHTML="";d=new CKEDITOR.dom.element("body",this.getDocument());d.$.innerHTML=
a;for(d=d.getChildren();d.count();)this.append(d.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(d){this.$[a?"textContent":"innerText"]=d}}(),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 d=
{},c=this.$.attributes,f;a=CKEDITOR.tools.isArray(a)?a:[];for(f=0;f<c.length;f++)-1===CKEDITOR.tools.indexOf(a,c[f].name)&&(d[c[f].name]=c[f].value);return d},getChildren:function(){return new CKEDITOR.dom.nodeList(this.$.childNodes)},getComputedStyle:document.defaultView&&document.defaultView.getComputedStyle?function(a){var d=this.getWindow().$.getComputedStyle(this.$,null);return d?d.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 d=this.$.scopeName;"HTML"!=d&&(a=d.toLowerCase()+":"+a)}this.getName=function(){return a};return this.getName()},getValue:function(){return this.$.value},getFirst:function(a){var d=this.$.firstChild;(d=d&&new CKEDITOR.dom.node(d))&&a&&!a(d)&&(d=d.getNext(a));return d},getLast:function(a){var d=this.$.lastChild;(d=d&&new CKEDITOR.dom.node(d))&&a&&!a(d)&&(d=d.getPrevious(a));return d},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 d=0;d<arguments.length;d++)if(arguments[d]==a)return!0;return!1},isEditable:function(a){var d=this.getName();return this.isReadOnly()||"none"==this.getComputedStyle("display")||"hidden"==this.getComputedStyle("visibility")||CKEDITOR.dtd.$nonEditable[d]||CKEDITOR.dtd.$empty[d]||this.is("a")&&(this.data("cke-saved-name")||this.hasAttribute("name"))&&!this.getChildCount()?!1:!1!==a?(a=CKEDITOR.dtd[d]||
CKEDITOR.dtd.span,!(!a||!a["#"])):!0},isIdentical:function(a){var d=this.clone(0,1);a=a.clone(0,1);d.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(d.$.isEqualNode)return d.$.style.cssText=CKEDITOR.tools.normalizeCssText(d.$.style.cssText),a.$.style.cssText=CKEDITOR.tools.normalizeCssText(a.$.style.cssText),d.$.isEqualNode(a.$);d=d.getOuterHtml();a=
a.getOuterHtml();if(CKEDITOR.env.ie&&9>CKEDITOR.env.version&&this.is("a")){var c=this.getParent();c.type==CKEDITOR.NODE_ELEMENT&&(c=c.clone(),c.setHtml(d),d=c.getHtml(),c.setHtml(a),a=c.getHtml())}return d==a},isVisible:function(){var a=(this.$.offsetHeight||this.$.offsetWidth)&&"hidden"!=this.getComputedStyle("visibility"),d,c;a&&CKEDITOR.env.webkit&&(d=this.getWindow(),!d.equals(CKEDITOR.document.getWindow())&&(c=d.$.frameElement)&&(a=(new CKEDITOR.dom.element(c)).isVisible()));return!!a},isEmptyInlineRemoveable:function(){if(!CKEDITOR.dtd.$removeEmpty[this.getName()])return!1;
for(var a=this.getChildren(),d=0,c=a.count();d<c;d++){var f=a.getItem(d);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,d=0;d<a.length;d++){var c=a[d];switch(c.nodeName){case "class":if(this.getAttribute("class"))return!0;case "data-cke-expando":continue;
default:if(c.specified)return!0}}return!1}:function(){var a=this.$.attributes,d=a.length,c={"data-cke-expando":1,_moz_dirty:1};return 0<d&&(2<d||!c[a[0].nodeName]||2==d&&!c[a[1].nodeName])},hasAttribute:function(){function a(d){var c=this.$.attributes.getNamedItem(d);if("input"==this.getName())switch(d){case "class":return 0<this.$.className.length;case "checked":return!!this.$.checked;case "value":return d=this.getAttribute("type"),"checkbox"==d||"radio"==d?"on"!=this.$.value:!!this.$.value}return c?
c.specified:!1}return CKEDITOR.env.ie?8>CKEDITOR.env.version?function(d){return"name"==d?!!this.$.name:a.call(this,d)}:a:function(a){return!!this.$.attributes.getNamedItem(a)}}(),hide:function(){this.setStyle("display","none")},moveChildren:function(a,d){var c=this.$;a=a.$;if(c!=a){var f;if(d)for(;f=c.lastChild;)a.insertBefore(c.removeChild(f),a.firstChild);else for(;f=c.firstChild;)a.appendChild(c.removeChild(f))}},mergeSiblings:function(){function a(d,c,f){if(c&&c.type==CKEDITOR.NODE_ELEMENT){for(var b=
[];c.data("cke-bookmark")||c.isEmptyInlineRemoveable();)if(b.push(c),c=f?c.getNext():c.getPrevious(),!c||c.type!=CKEDITOR.NODE_ELEMENT)return;if(d.isIdentical(c)){for(var e=f?d.getLast():d.getFirst();b.length;)b.shift().move(d,!f);c.moveChildren(d,!f);c.remove();e&&e.type==CKEDITOR.NODE_ELEMENT&&e.mergeSiblings()}}}return function(d){if(!1===d||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,c){this.$.setAttribute(a,c);return this};return CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)?function(d,c){"class"==d?this.$.className=c:"style"==d?this.$.style.cssText=c:"tabindex"==d?this.$.tabIndex=c:"checked"==d?this.$.checked=c:"contenteditable"==d?a.call(this,"contentEditable",c):a.apply(this,arguments);return this}:CKEDITOR.env.ie8Compat&&CKEDITOR.env.secure?function(d,c){if("src"==d&&c.match(/^http:\/\//))try{a.apply(this,
arguments)}catch(f){}else a.apply(this,arguments);return this}:a}(),setAttributes:function(a){for(var d in a)this.setAttribute(d,a[d]);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 d=
0;d<a.length;d++)this.removeAttribute(a[d]);else for(d in a=a||this.getAttributes(),a)a.hasOwnProperty(d)&&this.removeAttribute(d)},removeStyle:function(a){var d=this.$.style;if(d.removeProperty||"border"!=a&&"margin"!=a&&"padding"!=a)d.removeProperty?d.removeProperty(a):d.removeAttribute(CKEDITOR.tools.cssStyleToDomStyle(a)),this.$.style.cssText||this.removeAttribute("style");else{var c=["top","left","right","bottom"],f;"border"==a&&(f=["color","style","width"]);for(var d=[],b=0;b<c.length;b++)if(f)for(var e=
0;e<f.length;e++)d.push([a,c[b],f[e]].join("-"));else d.push([a,c[b]].join("-"));for(a=0;a<d.length;a++)this.removeStyle(d[a])}},setStyle:function(a,d){this.$.style[CKEDITOR.tools.cssStyleToDomStyle(a)]=d;return this},setStyles:function(a){for(var d in a)this.setStyle(d,a[d]);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,d=this.getElementsByTag("*"),c=0,f=d.count();c<f;c++)a=d.getItem(c),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 d=0,c=0,f=this.getDocument(),b=f.getBody(),e="BackCompat"==f.$.compatMode;if(document.documentElement.getBoundingClientRect&&(CKEDITOR.env.ie?
8!==CKEDITOR.env.version:1)){var h=this.$.getBoundingClientRect(),g=f.$.documentElement,r=g.clientTop||b.$.clientTop||0,q=g.clientLeft||b.$.clientLeft||0,l=!0;CKEDITOR.env.ie&&(l=f.getDocumentElement().contains(this),f=f.getBody().contains(this),l=e&&f||!e&&l);l&&(CKEDITOR.env.webkit||CKEDITOR.env.ie&&12<=CKEDITOR.env.version?(d=b.$.scrollLeft||g.scrollLeft,c=b.$.scrollTop||g.scrollTop):(c=e?b.$:g,d=c.scrollLeft,c=c.scrollTop),d=h.left+d-q,c=h.top+c-r)}else for(r=this,q=null;r&&"body"!=r.getName()&&
"html"!=r.getName();){d+=r.$.offsetLeft-r.$.scrollLeft;c+=r.$.offsetTop-r.$.scrollTop;r.equals(this)||(d+=r.$.clientLeft||0,c+=r.$.clientTop||0);for(;q&&!q.equals(r);)d-=q.$.scrollLeft,c-=q.$.scrollTop,q=q.getParent();q=r;r=(h=r.$.offsetParent)?new CKEDITOR.dom.element(h):null}a&&(h=this.getWindow(),r=a.getWindow(),!h.equals(r)&&h.$.frameElement&&(a=(new CKEDITOR.dom.element(h.$.frameElement)).getDocumentPosition(a),d+=a.x,c+=a.y));document.documentElement.getBoundingClientRect||!CKEDITOR.env.gecko||
e||(d+=this.$.clientLeft?1:0,c+=this.$.clientTop?1:0);return{x:d,y:c}},scrollIntoView:function(a){var d=this.getParent();if(d){do if((d.$.clientWidth&&d.$.clientWidth<d.$.scrollWidth||d.$.clientHeight&&d.$.clientHeight<d.$.scrollHeight)&&!d.is("body")&&this.scrollIntoParent(d,a,1),d.is("html")){var c=d.getWindow();try{var f=c.$.frameElement;f&&(d=new CKEDITOR.dom.element(f))}catch(b){}}while(d=d.getParent())}},scrollIntoParent:function(a,d,c){var f,b,e,h;function g(f,c){/body|html/.test(a.getName())?
a.getWindow().$.scrollBy(f,c):(a.$.scrollLeft+=f,a.$.scrollTop+=c)}function r(f,a){var c={x:0,y:0};if(!f.is(l?"body":"html")){var d=f.$.getBoundingClientRect();c.x=d.left;c.y=d.top}d=f.getWindow();d.equals(a)||(d=r(CKEDITOR.dom.element.get(d.$.frameElement),a),c.x+=d.x,c.y+=d.y);return c}function q(f,a){return parseInt(f.getComputedStyle("margin-"+a)||0,10)||0}!a&&(a=this.getWindow());e=a.getDocument();var l="BackCompat"==e.$.compatMode;a instanceof CKEDITOR.dom.window&&(a=l?e.getBody():e.getDocumentElement());
CKEDITOR.env.webkit&&(e=this.getEditor(!1))&&(e._.previousScrollTop=null);e=a.getWindow();b=r(this,e);var n=r(a,e),z=this.$.offsetHeight;f=this.$.offsetWidth;var p=a.$.clientHeight,u=a.$.clientWidth;e=b.x-q(this,"left")-n.x||0;h=b.y-q(this,"top")-n.y||0;f=b.x+f+q(this,"right")-(n.x+u)||0;b=b.y+z+q(this,"bottom")-(n.y+p)||0;(0>h||0<b)&&g(0,!0===d?h:!1===d?b:0>h?h:b);c&&(0>e||0<f)&&g(0>e?e:f,0)},setState:function(a,d,c){d=d||"cke";switch(a){case CKEDITOR.TRISTATE_ON:this.addClass(d+"_on");this.removeClass(d+
"_off");this.removeClass(d+"_disabled");c&&this.setAttribute("aria-pressed",!0);c&&this.removeAttribute("aria-disabled");break;case CKEDITOR.TRISTATE_DISABLED:this.addClass(d+"_disabled");this.removeClass(d+"_off");this.removeClass(d+"_on");c&&this.setAttribute("aria-disabled",!0);c&&this.removeAttribute("aria-pressed");break;default:this.addClass(d+"_off"),this.removeClass(d+"_on"),this.removeClass(d+"_disabled"),c&&this.removeAttribute("aria-pressed"),c&&this.removeAttribute("aria-disabled")}},
getFrameDocument:function(){var a=this.$;try{a.contentWindow.document}catch(d){a.src=a.src}return a&&new CKEDITOR.dom.document(a.contentWindow.document)},copyAttributes:function(a,d){var c=this.$.attributes;d=d||{};for(var f=0;f<c.length;f++){var b=c[f],e=b.nodeName.toLowerCase(),h;if(!(e in d))if("checked"==e&&(h=this.getAttribute(e)))a.setAttribute(e,h);else if(!CKEDITOR.env.ie||this.hasAttribute(e))h=this.getAttribute(e),null===h&&(h=b.nodeValue),a.setAttribute(e,h)}""!==this.$.style.cssText&&
(a.$.style.cssText=this.$.style.cssText)},renameNode:function(a){if(this.getName()!=a){var d=this.getDocument();a=new CKEDITOR.dom.element(a,d);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(d,c){var f=d.childNodes;if(0<=c&&c<f.length)return f[c]}return function(d){var c=this.$;if(d.slice)for(d=d.slice();0<d.length&&c;)c=a(c,
d.shift());else c=a(c,d);return c?new CKEDITOR.dom.node(c):null}}(),getChildCount:function(){return this.$.childNodes.length},disableContextMenu:function(){function a(d){return d.type==CKEDITOR.NODE_ELEMENT&&d.hasClass("cke_enable_context_menu")}this.on("contextmenu",function(d){d.data.getTarget().getAscendant(a,!0)||d.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,d){a="data-"+a;if(void 0===d)return this.getAttribute(a);!1===d?this.removeAttribute(a):this.setAttribute(a,d);return null},getEditor:function(a){var d=CKEDITOR.instances,c,f,b;a=a||void 0===a;for(c in d)if(f=d[c],f.element.equals(this)&&f.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO||!a&&(b=f.editable())&&(b.equals(this)||b.contains(this)))return f;return null},find:function(a){var d=g(this);a=new CKEDITOR.dom.nodeList(this.$.querySelectorAll(e(this,
a)));d();return a},findOne:function(a){var d=g(this);a=this.$.querySelector(e(this,a));d();return a?new CKEDITOR.dom.element(a):null},forEach:function(a,d,c){if(!(c||d&&this.type!=d))var f=a(this);if(!1!==f){c=this.getChildren();for(var b=0;b<c.count();b++)f=c.getItem(b),f.type==CKEDITOR.NODE_ELEMENT?f.forEach(a,d):d&&f.type!=d||a(f)}}});var n={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(b,d,c){"number"==typeof d&&(!c||CKEDITOR.env.ie&&CKEDITOR.env.quirks||(d-=a.call(this,b)),this.setStyle(b,d+"px"))};CKEDITOR.dom.element.prototype.getSize=function(b,d){var c=Math.max(this.$["offset"+CKEDITOR.tools.capitalize(b)],this.$["client"+CKEDITOR.tools.capitalize(b)])||0;d&&(c-=a.call(this,b));return c}}(),CKEDITOR.dom.documentFragment=function(b){b=b||CKEDITOR.document;this.$=b.type==CKEDITOR.NODE_DOCUMENT?b.$.createDocumentFragment():b},CKEDITOR.tools.extend(CKEDITOR.dom.documentFragment.prototype,
CKEDITOR.dom.element.prototype,{type:CKEDITOR.NODE_DOCUMENT_FRAGMENT,insertAfterNode:function(b){b=b.$;b.parentNode.insertBefore(this.$,b.nextSibling)},getHtml:function(){var b=new CKEDITOR.dom.element("div");this.clone(1,1).appendTo(b);return b.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 b(f,a){var c=this.range;if(this._.end)return null;if(!this._.start){this._.start=1;if(c.collapsed)return this.end(),null;c.optimize()}var b,d=c.startContainer;b=c.endContainer;var e=c.startOffset,m=c.endOffset,h,p=this.guard,g=this.type,k=f?"getPreviousSourceNode":"getNextSourceNode";if(!f&&!this._.guardLTR){var w=b.type==CKEDITOR.NODE_ELEMENT?b:b.getParent(),l=b.type==CKEDITOR.NODE_ELEMENT?b.getChild(m):b.getNext();this._.guardLTR=function(f,
a){return(!a||!w.equals(f))&&(!l||!f.equals(l))&&(f.type!=CKEDITOR.NODE_ELEMENT||!a||!f.equals(c.root))}}if(f&&!this._.guardRTL){var n=d.type==CKEDITOR.NODE_ELEMENT?d:d.getParent(),F=d.type==CKEDITOR.NODE_ELEMENT?e?d.getChild(e-1):null:d.getPrevious();this._.guardRTL=function(f,a){return(!a||!n.equals(f))&&(!F||!f.equals(F))&&(f.type!=CKEDITOR.NODE_ELEMENT||!a||!f.equals(c.root))}}var G=f?this._.guardRTL:this._.guardLTR;h=p?function(f,a){return!1===G(f,a)?!1:p(f,a)}:G;this.current?b=this.current[k](!1,
g,h):(f?b.type==CKEDITOR.NODE_ELEMENT&&(b=0<m?b.getChild(m-1):!1===h(b,!0)?null:b.getPreviousSourceNode(!0,g,h)):(b=d,b.type==CKEDITOR.NODE_ELEMENT&&((b=b.getChild(e))||(b=!1===h(d,!0)?null:d.getNextSourceNode(!0,g,h)))),b&&!1===h(b)&&(b=null));for(;b&&!this._.end;){this.current=b;if(!this.evaluator||!1!==this.evaluator(b)){if(!a)return b}else if(a&&this.evaluator)return!1;b=b[k](!1,g,h)}this.end();return this.current=null}function g(f){for(var a,c=null;a=b.call(this,f);)c=a;return c}CKEDITOR.dom.walker=
CKEDITOR.tools.createClass({$:function(f){this.range=f;this._={}},proto:{end:function(){this._.end=1},next:function(){return b.call(this)},previous:function(){return b.call(this,1)},checkForward:function(){return!1!==b.call(this,0,1)},checkBackward:function(){return!1!==b.call(this,1,1)},lastForward:function(){return g.call(this)},lastBackward:function(){return g.call(this,1)},reset:function(){delete this.current;this._={}}}});var e={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},a={absolute:1,fixed:1};CKEDITOR.dom.element.prototype.isBlockBoundary=function(f){return"none"!=this.getComputedStyle("float")||this.getComputedStyle("position")in a||!e[this.getComputedStyle("display")]?!!(this.is(CKEDITOR.dtd.$block)||f&&this.is(f)):!0};CKEDITOR.dom.walker.blockBoundary=function(f){return function(a){return!(a.type==CKEDITOR.NODE_ELEMENT&&a.isBlockBoundary(f))}};CKEDITOR.dom.walker.listItemBoundary=
function(){return this.blockBoundary({br:1})};CKEDITOR.dom.walker.bookmark=function(f,a){function c(f){return f&&f.getName&&"span"==f.getName()&&f.data("cke-bookmark")}return function(b){var d,e;d=b&&b.type!=CKEDITOR.NODE_ELEMENT&&(e=b.getParent())&&c(e);d=f?d:d||c(b);return!!(a^d)}};CKEDITOR.dom.walker.whitespaces=function(f){return function(a){var c;a&&a.type==CKEDITOR.NODE_TEXT&&(c=!CKEDITOR.tools.trim(a.getText())||CKEDITOR.env.webkit&&a.getText()==CKEDITOR.dom.selection.FILLING_CHAR_SEQUENCE);
return!!(f^c)}};CKEDITOR.dom.walker.invisible=function(f){var a=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.env.webkit?1:0;return function(b){a(b)?b=1:(b.type==CKEDITOR.NODE_TEXT&&(b=b.getParent()),b=b.$.offsetWidth<=c);return!!(f^b)}};CKEDITOR.dom.walker.nodeType=function(f,a){return function(c){return!!(a^c.type==f)}};CKEDITOR.dom.walker.bogus=function(f){function a(f){return!l(f)&&!n(f)}return function(c){var b=CKEDITOR.env.needsBrFiller?c.is&&c.is("br"):c.getText&&h.test(c.getText());b&&(b=c.getParent(),
c=c.getNext(a),b=b.isBlockBoundary()&&(!c||c.type==CKEDITOR.NODE_ELEMENT&&c.isBlockBoundary()));return!!(f^b)}};CKEDITOR.dom.walker.temp=function(f){return function(a){a.type!=CKEDITOR.NODE_ELEMENT&&(a=a.getParent());a=a&&a.hasAttribute("data-cke-temp");return!!(f^a)}};var h=/^[\t\r\n ]*(?:&nbsp;|\xa0)$/,l=CKEDITOR.dom.walker.whitespaces(),n=CKEDITOR.dom.walker.bookmark(),k=CKEDITOR.dom.walker.temp(),d=function(f){return n(f)||l(f)||f.type==CKEDITOR.NODE_ELEMENT&&f.is(CKEDITOR.dtd.$inline)&&!f.is(CKEDITOR.dtd.$empty)};
CKEDITOR.dom.walker.ignored=function(f){return function(a){a=l(a)||n(a)||k(a);return!!(f^a)}};var c=CKEDITOR.dom.walker.ignored();CKEDITOR.dom.walker.empty=function(f){return function(a){for(var b=0,d=a.getChildCount();b<d;++b)if(!c(a.getChild(b)))return!!f;return!f}};var f=CKEDITOR.dom.walker.empty(),m=CKEDITOR.dom.walker.validEmptyBlockContainers=CKEDITOR.tools.extend(function(f){var a={},c;for(c in f)CKEDITOR.dtd[c]["#"]&&(a[c]=1);return a}(CKEDITOR.dtd.$block),{caption:1,td:1,th:1});CKEDITOR.dom.walker.editable=
function(a){return function(b){b=c(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(m)&&f(b))?!0:!1;return!!(a^b)}};CKEDITOR.dom.element.prototype.getBogus=function(){var f=this;do f=f.getPreviousSourceNode();while(d(f));return f&&(CKEDITOR.env.needsBrFiller?f.is&&f.is("br"):f.getText&&h.test(f.getText()))?f:!1}}(),CKEDITOR.dom.range=function(b){this.endOffset=this.endContainer=
this.startOffset=this.startContainer=null;this.collapsed=!0;var g=b instanceof CKEDITOR.dom.document;this.document=g?b:b.getDocument();this.root=g?b.getBody():b},function(){function b(f){f.collapsed=f.startContainer&&f.endContainer&&f.startContainer.equals(f.endContainer)&&f.startOffset==f.endOffset}function g(f,a,c,b,d){function e(f,a,c,b){var m=c?f.getPrevious():f.getNext();if(b&&k)return m;p||b?a.append(f.clone(!0,d),c):(f.remove(),l&&a.append(f));return m}function h(){var f,a,c,b=Math.min(H.length,
E.length);for(f=0;f<b;f++)if(a=H[f],c=E[f],!a.equals(c))return f;return f-1}function g(){var a=S-1,c=G&&L&&!u.equals(B);a<O-1||a<T-1||c?(c?f.moveToPosition(B,CKEDITOR.POSITION_BEFORE_START):T==a+1&&F?f.moveToPosition(E[a],CKEDITOR.POSITION_BEFORE_END):f.moveToPosition(E[a+1],CKEDITOR.POSITION_BEFORE_START),b&&(a=H[a+1])&&a.type==CKEDITOR.NODE_ELEMENT&&(c=CKEDITOR.dom.element.createFromHtml('\x3cspan data-cke-bookmark\x3d"1" style\x3d"display:none"\x3e\x26nbsp;\x3c/span\x3e',f.document),c.insertAfter(a),
a.mergeSiblings(!1),f.moveToBookmark({startNode:c}))):f.collapse(!0)}f.optimizeBookmark();var k=0===a,l=1==a,p=2==a;a=p||l;var u=f.startContainer,B=f.endContainer,w=f.startOffset,n=f.endOffset,D,F,G,L,I,P;if(p&&B.type==CKEDITOR.NODE_TEXT&&u.equals(B))u=f.document.createText(u.substring(w,n)),c.append(u);else{B.type==CKEDITOR.NODE_TEXT?p?P=!0:B=B.split(n):0<B.getChildCount()?n>=B.getChildCount()?(B=B.getChild(n-1),F=!0):B=B.getChild(n):L=F=!0;u.type==CKEDITOR.NODE_TEXT?p?I=!0:u.split(w):0<u.getChildCount()?
0===w?(u=u.getChild(w),D=!0):u=u.getChild(w-1):G=D=!0;for(var H=u.getParents(),E=B.getParents(),S=h(),O=H.length-1,T=E.length-1,Q=c,Z,aa,W,ea=-1,N=S;N<=O;N++){aa=H[N];W=aa.getNext();for(N!=O||aa.equals(E[N])&&O<T?a&&(Z=Q.append(aa.clone(0,d))):D?e(aa,Q,!1,G):I&&Q.append(f.document.createText(aa.substring(w)));W;){if(W.equals(E[N])){ea=N;break}W=e(W,Q)}Q=Z}Q=c;for(N=S;N<=T;N++)if(c=E[N],W=c.getPrevious(),c.equals(H[N]))a&&(Q=Q.getChild(0));else{N!=T||c.equals(H[N])&&T<O?a&&(Z=Q.append(c.clone(0,d))):
F?e(c,Q,!1,L):P&&Q.append(f.document.createText(c.substring(0,n)));if(N>ea)for(;W;)W=e(W,Q,!0);Q=Z}p||g()}}function e(){var f=!1,a=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.dom.walker.bookmark(!0),b=CKEDITOR.dom.walker.bogus();return function(d){return c(d)||a(d)?!0:b(d)&&!f?f=!0:d.type==CKEDITOR.NODE_TEXT&&(d.hasAscendant("pre")||CKEDITOR.tools.trim(d.getText()).length)||d.type==CKEDITOR.NODE_ELEMENT&&!d.is(l)?!1:!0}}function a(f){var a=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.dom.walker.bookmark(1);
return function(b){return c(b)||a(b)?!0:!f&&n(b)||b.type==CKEDITOR.NODE_ELEMENT&&b.is(CKEDITOR.dtd.$removeEmpty)}}function h(f){return function(){var a;return this[f?"getPreviousNode":"getNextNode"](function(f){!a&&c(f)&&(a=f);return d(f)&&!(n(f)&&f.equals(a))})}}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},n=CKEDITOR.dom.walker.bogus(),k=/^[\t\r\n ]*(?:&nbsp;|\xa0)$/,
d=CKEDITOR.dom.walker.editable(),c=CKEDITOR.dom.walker.ignored(!0);CKEDITOR.dom.range.prototype={clone:function(){var f=new CKEDITOR.dom.range(this.root);f._setStartContainer(this.startContainer);f.startOffset=this.startOffset;f._setEndContainer(this.endContainer);f.endOffset=this.endOffset;f.collapsed=this.collapsed;return f},collapse:function(f){f?(this._setEndContainer(this.startContainer),this.endOffset=this.startOffset):(this._setStartContainer(this.endContainer),this.startOffset=this.endOffset);
this.collapsed=!0},cloneContents:function(f){var a=new CKEDITOR.dom.documentFragment(this.document);this.collapsed||g(this,2,a,!1,"undefined"==typeof f?!0:f);return a},deleteContents:function(f){this.collapsed||g(this,0,null,f)},extractContents:function(f,a){var c=new CKEDITOR.dom.documentFragment(this.document);this.collapsed||g(this,1,c,f,"undefined"==typeof a?!0:a);return c},createBookmark:function(f){var a,c,b,d,e=this.collapsed;a=this.document.createElement("span");a.data("cke-bookmark",1);a.setStyle("display",
"none");a.setHtml("\x26nbsp;");f&&(b="cke_bm_"+CKEDITOR.tools.getNextNumber(),a.setAttribute("id",b+(e?"C":"S")));e||(c=a.clone(),c.setHtml("\x26nbsp;"),f&&c.setAttribute("id",b+"E"),d=this.clone(),d.collapse(),d.insertNode(c));d=this.clone();d.collapse(!0);d.insertNode(a);c?(this.setStartAfter(a),this.setEndBefore(c)):this.moveToPosition(a,CKEDITOR.POSITION_AFTER_END);return{startNode:f?b+(e?"C":"S"):a,endNode:f?b+"E":c,serializable:f,collapsed:e}},createBookmark2:function(){function a(f){var c=
f.container,d=f.offset,e;e=c;var m=d;e=e.type!=CKEDITOR.NODE_ELEMENT||0===m||m==e.getChildCount()?0:e.getChild(m-1).type==CKEDITOR.NODE_TEXT&&e.getChild(m).type==CKEDITOR.NODE_TEXT;e&&(c=c.getChild(d-1),d=c.getLength());if(c.type==CKEDITOR.NODE_ELEMENT&&0<d){a:{for(e=c;d--;)if(m=e.getChild(d).getIndex(!0),0<=m){d=m;break a}d=-1}d+=1}if(c.type==CKEDITOR.NODE_TEXT){e=c;for(m=0;(e=e.getPrevious())&&e.type==CKEDITOR.NODE_TEXT;)m+=e.getText().replace(CKEDITOR.dom.selection.FILLING_CHAR_SEQUENCE,"").length;
e=m;c.getText()?d+=e:(m=c.getPrevious(b),e?(d=e,c=m?m.getNext():c.getParent().getFirst()):(c=c.getParent(),d=m?m.getIndex(!0)+1:0))}f.container=c;f.offset=d}function c(a,f){var b=f.getCustomData("cke-fillingChar");if(b){var d=a.container;b.equals(d)&&(a.offset-=CKEDITOR.dom.selection.FILLING_CHAR_SEQUENCE.length,0>=a.offset&&(a.offset=d.getIndex(),a.container=d.getParent()))}}var b=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_TEXT,!0);return function(b){var d=this.collapsed,e={container:this.startContainer,
offset:this.startOffset},h={container:this.endContainer,offset:this.endOffset};b&&(a(e),c(e,this.root),d||(a(h),c(h,this.root)));return{start:e.container.getAddress(b),end:d?null:h.container.getAddress(b),startOffset:e.offset,endOffset:h.offset,normalized:b,collapsed:d,is2:!0}}}(),moveToBookmark:function(a){if(a.is2){var c=this.document.getByAddress(a.start,a.normalized),b=a.startOffset,d=a.end&&this.document.getByAddress(a.end,a.normalized);a=a.endOffset;this.setStart(c,b);d?this.setEnd(d,a):this.collapse(!0)}else c=
(b=a.serializable)?this.document.getById(a.startNode):a.startNode,a=b?this.document.getById(a.endNode):a.endNode,this.setStartBefore(c),c.remove(),a?(this.setEndBefore(a),a.remove()):this.collapse(!0)},getBoundaryNodes:function(){var a=this.startContainer,c=this.endContainer,b=this.startOffset,d=this.endOffset,e;if(a.type==CKEDITOR.NODE_ELEMENT)if(e=a.getChildCount(),e>b)a=a.getChild(b);else if(1>e)a=a.getPreviousSourceNode();else{for(a=a.$;a.lastChild;)a=a.lastChild;a=new CKEDITOR.dom.node(a);a=
a.getNextSourceNode()||a}if(c.type==CKEDITOR.NODE_ELEMENT)if(e=c.getChildCount(),e>d)c=c.getChild(d).getPreviousSourceNode(!0);else if(1>e)c=c.getPreviousSourceNode();else{for(c=c.$;c.lastChild;)c=c.lastChild;c=new CKEDITOR.dom.node(c)}a.getPosition(c)&CKEDITOR.POSITION_FOLLOWING&&(a=c);return{startNode:a,endNode:c}},getCommonAncestor:function(a,c){var b=this.startContainer,d=this.endContainer,b=b.equals(d)?a&&b.type==CKEDITOR.NODE_ELEMENT&&this.startOffset==this.endOffset-1?b.getChild(this.startOffset):
b:b.getCommonAncestor(d);return c&&!b.is?b.getParent():b},optimize:function(){var a=this.startContainer,c=this.startOffset;a.type!=CKEDITOR.NODE_ELEMENT&&(c?c>=a.getLength()&&this.setStartAfter(a):this.setStartBefore(a));a=this.endContainer;c=this.endOffset;a.type!=CKEDITOR.NODE_ELEMENT&&(c?c>=a.getLength()&&this.setEndAfter(a):this.setEndBefore(a))},optimizeBookmark:function(){var a=this.startContainer,c=this.endContainer;a.is&&a.is("span")&&a.data("cke-bookmark")&&this.setStartAt(a,CKEDITOR.POSITION_BEFORE_START);
c&&c.is&&c.is("span")&&c.data("cke-bookmark")&&this.setEndAt(c,CKEDITOR.POSITION_AFTER_END)},trim:function(a,c){var b=this.startContainer,d=this.startOffset,e=this.collapsed;if((!a||e)&&b&&b.type==CKEDITOR.NODE_TEXT){if(d)if(d>=b.getLength())d=b.getIndex()+1,b=b.getParent();else{var h=b.split(d),d=b.getIndex()+1,b=b.getParent();this.startContainer.equals(this.endContainer)?this.setEnd(h,this.endOffset-this.startOffset):b.equals(this.endContainer)&&(this.endOffset+=1)}else d=b.getIndex(),b=b.getParent();
this.setStart(b,d);if(e){this.collapse(!0);return}}b=this.endContainer;d=this.endOffset;c||e||!b||b.type!=CKEDITOR.NODE_TEXT||(d?(d>=b.getLength()||b.split(d),d=b.getIndex()+1):d=b.getIndex(),b=b.getParent(),this.setEnd(b,d))},enlarge:function(a,c){function b(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 e=1;case CKEDITOR.ENLARGE_ELEMENT:var h=function(a,f){var c=new CKEDITOR.dom.range(k);
c.setStart(a,f);c.setEndAt(k,CKEDITOR.POSITION_BEFORE_END);var c=new CKEDITOR.dom.walker(c),b;for(c.guard=function(a){return!(a.type==CKEDITOR.NODE_ELEMENT&&a.isBlockBoundary())};b=c.next();){if(b.type!=CKEDITOR.NODE_TEXT)return!1;D=b!=a?b.getText():b.substring(f);if(d.test(D))return!1}return!0};if(this.collapsed)break;var g=this.getCommonAncestor(),k=this.root,l,n,p,u,B,w=!1,C,D;C=this.startContainer;var F=this.startOffset;C.type==CKEDITOR.NODE_TEXT?(F&&(C=!CKEDITOR.tools.trim(C.substring(0,F)).length&&
C,w=!!C),C&&((u=C.getPrevious())||(p=C.getParent()))):(F&&(u=C.getChild(F-1)||C.getLast()),u||(p=C));for(p=b(p);p||u;){if(p&&!u){!B&&p.equals(g)&&(B=!0);if(e?p.isBlockBoundary():!k.contains(p))break;w&&"inline"==p.getComputedStyle("display")||(w=!1,B?l=p:this.setStartBefore(p));u=p.getPrevious()}for(;u;)if(C=!1,u.type==CKEDITOR.NODE_COMMENT)u=u.getPrevious();else{if(u.type==CKEDITOR.NODE_TEXT)D=u.getText(),d.test(D)&&(u=null),C=/[\s\ufeff]$/.test(D);else if((u.$.offsetWidth>(CKEDITOR.env.webkit?1:
0)||c&&u.is("br"))&&!u.data("cke-bookmark"))if(w&&CKEDITOR.dtd.$removeEmpty[u.getName()]){D=u.getText();if(d.test(D))u=null;else for(var F=u.$.getElementsByTagName("*"),G=0,L;L=F[G++];)if(!CKEDITOR.dtd.$removeEmpty[L.nodeName.toLowerCase()]){u=null;break}u&&(C=!!D.length)}else u=null;C&&(w?B?l=p:p&&this.setStartBefore(p):w=!0);if(u){C=u.getPrevious();if(!p&&!C){p=u;u=null;break}u=C}else p=null}p&&(p=b(p.getParent()))}C=this.endContainer;F=this.endOffset;p=u=null;B=w=!1;C.type==CKEDITOR.NODE_TEXT?
CKEDITOR.tools.trim(C.substring(F)).length?w=!0:(w=!C.getLength(),F==C.getLength()?(u=C.getNext())||(p=C.getParent()):h(C,F)&&(p=C.getParent())):(u=C.getChild(F))||(p=C);for(;p||u;){if(p&&!u){!B&&p.equals(g)&&(B=!0);if(e?p.isBlockBoundary():!k.contains(p))break;w&&"inline"==p.getComputedStyle("display")||(w=!1,B?n=p:p&&this.setEndAfter(p));u=p.getNext()}for(;u;){C=!1;if(u.type==CKEDITOR.NODE_TEXT)D=u.getText(),h(u,0)||(u=null),C=/^[\s\ufeff]/.test(D);else if(u.type==CKEDITOR.NODE_ELEMENT){if((0<u.$.offsetWidth||
c&&u.is("br"))&&!u.data("cke-bookmark"))if(w&&CKEDITOR.dtd.$removeEmpty[u.getName()]){D=u.getText();if(d.test(D))u=null;else for(F=u.$.getElementsByTagName("*"),G=0;L=F[G++];)if(!CKEDITOR.dtd.$removeEmpty[L.nodeName.toLowerCase()]){u=null;break}u&&(C=!!D.length)}else u=null}else C=1;C&&w&&(B?n=p:this.setEndAfter(p));if(u){C=u.getNext();if(!p&&!C){p=u;u=null;break}u=C}else p=null}p&&(p=b(p.getParent()))}l&&n&&(g=l.contains(n)?n:l,this.setStartBefore(g),this.setEndAfter(g));break;case CKEDITOR.ENLARGE_BLOCK_CONTENTS:case CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS:p=
new CKEDITOR.dom.range(this.root);k=this.root;p.setStartAt(k,CKEDITOR.POSITION_AFTER_START);p.setEnd(this.startContainer,this.startOffset);p=new CKEDITOR.dom.walker(p);var I,P,H=CKEDITOR.dom.walker.blockBoundary(a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS?{br:1}:null),E=null,S=function(a){if(a.type==CKEDITOR.NODE_ELEMENT&&"false"==a.getAttribute("contenteditable"))if(E){if(E.equals(a)){E=null;return}}else E=a;else if(E)return;var f=H(a);f||(I=a);return f},e=function(a){var f=S(a);!f&&a.is&&a.is("br")&&
(P=a);return f};p.guard=S;p=p.lastBackward();I=I||k;this.setStartAt(I,!I.is("br")&&(!p&&this.checkStartOfBlock()||p&&I.contains(p))?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_AFTER_END);if(a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS){p=this.clone();p=new CKEDITOR.dom.walker(p);var O=CKEDITOR.dom.walker.whitespaces(),T=CKEDITOR.dom.walker.bookmark();p.evaluator=function(a){return!O(a)&&!T(a)};if((p=p.previous())&&p.type==CKEDITOR.NODE_ELEMENT&&p.is("br"))break}p=this.clone();p.collapse();p.setEndAt(k,
CKEDITOR.POSITION_BEFORE_END);p=new CKEDITOR.dom.walker(p);p.guard=a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS?e:S;I=E=P=null;p=p.lastForward();I=I||k;this.setEndAt(I,!p&&this.checkEndOfBlock()||p&&I.contains(p)?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_BEFORE_START);P&&this.setEndAfter(P)}},shrink:function(a,c,b){if(!this.collapsed){a=a||CKEDITOR.SHRINK_TEXT;var d=this.clone(),e=this.startContainer,h=this.endContainer,g=this.startOffset,k=this.endOffset,l=1,n=1;e&&e.type==CKEDITOR.NODE_TEXT&&(g?
g>=e.getLength()?d.setStartAfter(e):(d.setStartBefore(e),l=0):d.setStartBefore(e));h&&h.type==CKEDITOR.NODE_TEXT&&(k?k>=h.getLength()?d.setEndAfter(h):(d.setEndAfter(h),n=0):d.setEndBefore(h));var d=new CKEDITOR.dom.walker(d),p=CKEDITOR.dom.walker.bookmark();d.evaluator=function(c){return c.type==(a==CKEDITOR.SHRINK_ELEMENT?CKEDITOR.NODE_ELEMENT:CKEDITOR.NODE_TEXT)};var u;d.guard=function(c,d){if(p(c))return!0;if(a==CKEDITOR.SHRINK_ELEMENT&&c.type==CKEDITOR.NODE_TEXT||d&&c.equals(u)||!1===b&&c.type==
CKEDITOR.NODE_ELEMENT&&c.isBlockBoundary()||c.type==CKEDITOR.NODE_ELEMENT&&c.hasAttribute("contenteditable"))return!1;d||c.type!=CKEDITOR.NODE_ELEMENT||(u=c);return!0};l&&(e=d[a==CKEDITOR.SHRINK_ELEMENT?"lastForward":"next"]())&&this.setStartAt(e,c?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_START);n&&(d.reset(),(d=d[a==CKEDITOR.SHRINK_ELEMENT?"lastBackward":"previous"]())&&this.setEndAt(d,c?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_AFTER_END));return!(!l&&!n)}},insertNode:function(a){this.optimizeBookmark();
this.trim(!1,!0);var c=this.startContainer,b=c.getChild(this.startOffset);b?a.insertBefore(b):c.append(a);a.getParent()&&a.getParent().equals(this.endContainer)&&this.endOffset++;this.setStartBefore(a)},moveToPosition:function(a,c){this.setStartAt(a,c);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(a,c){a.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$empty[a.getName()]&&(c=a.getIndex(),a=a.getParent());this._setStartContainer(a);this.startOffset=c;this.endContainer||(this._setEndContainer(a),this.endOffset=c);b(this)},setEnd:function(a,c){a.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$empty[a.getName()]&&(c=a.getIndex()+1,a=a.getParent());this._setEndContainer(a);this.endOffset=c;this.startContainer||(this._setStartContainer(a),this.startOffset=c);b(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(a,c){switch(c){case CKEDITOR.POSITION_AFTER_START:this.setStart(a,0);break;case CKEDITOR.POSITION_BEFORE_END:a.type==CKEDITOR.NODE_TEXT?this.setStart(a,a.getLength()):this.setStart(a,a.getChildCount());break;case CKEDITOR.POSITION_BEFORE_START:this.setStartBefore(a);
break;case CKEDITOR.POSITION_AFTER_END:this.setStartAfter(a)}b(this)},setEndAt:function(a,c){switch(c){case CKEDITOR.POSITION_AFTER_START:this.setEnd(a,0);break;case CKEDITOR.POSITION_BEFORE_END:a.type==CKEDITOR.NODE_TEXT?this.setEnd(a,a.getLength()):this.setEnd(a,a.getChildCount());break;case CKEDITOR.POSITION_BEFORE_START:this.setEndBefore(a);break;case CKEDITOR.POSITION_AFTER_END:this.setEndAfter(a)}b(this)},fixBlock:function(a,c){var b=this.createBookmark(),d=this.document.createElement(c);this.collapse(a);
this.enlarge(CKEDITOR.ENLARGE_BLOCK_CONTENTS);this.extractContents().appendTo(d);d.trim();this.insertNode(d);var e=d.getBogus();e&&e.remove();d.appendBogus();this.moveToBookmark(b);return d},splitBlock:function(a,c){var b=new CKEDITOR.dom.elementPath(this.startContainer,this.root),d=new CKEDITOR.dom.elementPath(this.endContainer,this.root),e=b.block,h=d.block,g=null;if(!b.blockLimit.equals(d.blockLimit))return null;"br"!=a&&(e||(e=this.fixBlock(!0,a),h=(new CKEDITOR.dom.elementPath(this.endContainer,
this.root)).block),h||(h=this.fixBlock(!1,a)));b=e&&this.checkStartOfBlock();d=h&&this.checkEndOfBlock();this.deleteContents();e&&e.equals(h)&&(d?(g=new CKEDITOR.dom.elementPath(this.startContainer,this.root),this.moveToPosition(h,CKEDITOR.POSITION_AFTER_END),h=null):b?(g=new CKEDITOR.dom.elementPath(this.startContainer,this.root),this.moveToPosition(e,CKEDITOR.POSITION_BEFORE_START),e=null):(h=this.splitElement(e,c||!1),e.is("ul","ol")||e.appendBogus()));return{previousBlock:e,nextBlock:h,wasStartOfBlock:b,
wasEndOfBlock:d,elementPath:g}},splitElement:function(a,c){if(!this.collapsed)return null;this.setEndAt(a,CKEDITOR.POSITION_BEFORE_END);var b=this.extractContents(!1,c||!1),d=a.clone(!1,c||!1);b.appendTo(d);d.insertAfter(a);this.moveToPosition(a,CKEDITOR.POSITION_AFTER_END);return d},removeEmptyBlocksAtEnd:function(){function a(f){return function(a){return c(a)||b(a)||a.type==CKEDITOR.NODE_ELEMENT&&a.isEmptyInlineRemoveable()||f.is("table")&&a.is("caption")?!1:!0}}var c=CKEDITOR.dom.walker.whitespaces(),
b=CKEDITOR.dom.walker.bookmark(!1);return function(c){for(var b=this.createBookmark(),d=this[c?"endPath":"startPath"](),e=d.block||d.blockLimit,m;e&&!e.equals(d.root)&&!e.getFirst(a(e));)m=e.getParent(),this[c?"setEndAt":"setStartAt"](e,CKEDITOR.POSITION_AFTER_END),e.remove(1),e=m;this.moveToBookmark(b)}}(),startPath:function(){return new CKEDITOR.dom.elementPath(this.startContainer,this.root)},endPath:function(){return new CKEDITOR.dom.elementPath(this.endContainer,this.root)},checkBoundaryOfElement:function(c,
b){var d=b==CKEDITOR.START,e=this.clone();e.collapse(d);e[d?"setStartAt":"setEndAt"](c,d?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_END);e=new CKEDITOR.dom.walker(e);e.evaluator=a(d);return e[d?"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)),k.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=e();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)),k.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=e();return a.checkForward()},getPreviousNode:function(a,c,b){var d=this.clone();d.collapse(1);d.setStartAt(b||this.root,CKEDITOR.POSITION_AFTER_START);b=new CKEDITOR.dom.walker(d);b.evaluator=a;b.guard=c;return b.previous()},getNextNode:function(a,c,b){var d=this.clone();d.collapse();d.setEndAt(b||this.root,CKEDITOR.POSITION_BEFORE_END);b=new CKEDITOR.dom.walker(d);b.evaluator=a;b.guard=c;return b.next()},checkReadOnly:function(){function a(c,f){for(;c;){if(c.type==
CKEDITOR.NODE_ELEMENT){if("false"==c.getAttribute("contentEditable")&&!c.data("cke-editable"))return 0;if(c.is("html")||"true"==c.getAttribute("contentEditable")&&(c.contains(f)||c.equals(f)))break}c=c.getParent()}return 1}return function(){var c=this.startContainer,b=this.endContainer;return!(a(c,b)&&a(b,c))}}(),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 d=0;a;){if(a.type==CKEDITOR.NODE_TEXT){b&&this.endContainer&&this.checkEndOfBlock()&&k.test(a.getText())?this.moveToPosition(a,CKEDITOR.POSITION_BEFORE_START):this.moveToPosition(a,b?CKEDITOR.POSITION_AFTER_END:CKEDITOR.POSITION_BEFORE_START);d=1;break}if(a.type==CKEDITOR.NODE_ELEMENT)if(a.isEditable())this.moveToPosition(a,b?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_AFTER_START),d=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 e=a,h=d,g=void 0;e.type==CKEDITOR.NODE_ELEMENT&&e.isEditable(!1)&&(g=e[b?"getLast":"getFirst"](c));h||g||(g=e[b?"getPrevious":"getNext"](c));a=g}return!!d},moveToClosestEditablePosition:function(a,c){var b,d=0,e,h,g=[CKEDITOR.POSITION_AFTER_END,CKEDITOR.POSITION_BEFORE_START];a?(b=new CKEDITOR.dom.range(this.root),b.moveToPosition(a,g[c?0:1])):b=this.clone();if(a&&
!a.is(CKEDITOR.dtd.$block))d=1;else if(e=b[c?"getNextEditableNode":"getPreviousEditableNode"]())d=1,(h=e.type==CKEDITOR.NODE_ELEMENT)&&e.is(CKEDITOR.dtd.$block)&&"false"==e.getAttribute("contenteditable")?(b.setStartAt(e,CKEDITOR.POSITION_BEFORE_START),b.setEndAt(e,CKEDITOR.POSITION_AFTER_END)):!CKEDITOR.env.needsBrFiller&&h&&e.is(CKEDITOR.dom.walker.validEmptyBlockContainers)?(b.setEnd(e,0),b.collapse()):b.moveToPosition(e,g[c?1:0]);d&&this.moveToRange(b);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),c=CKEDITOR.dom.walker.bookmark(!1,!0),b=CKEDITOR.dom.walker.whitespaces(!0);a.evaluator=function(a){return b(a)&&c(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:h(),getPreviousEditableNode:h(1),scrollIntoView:function(){var a=new CKEDITOR.dom.element.createFromHtml("\x3cspan\x3e\x26nbsp;\x3c/span\x3e",this.document),c,b,d,e=this.clone();e.optimize();(d=e.startContainer.type==CKEDITOR.NODE_TEXT)?(b=e.startContainer.getText(),
c=e.startContainer.split(e.startOffset),a.insertAfter(e.startContainer)):e.insertNode(a);a.scrollIntoView();d&&(e.startContainer.setText(b),c.remove());a.remove()},_setStartContainer:function(a){this.startContainer=a},_setEndContainer:function(a){this.endContainer=a},_find:function(a,c){var b=this.getCommonAncestor(),d=this.getBoundaryNodes(),e=[],h,g,k,l;if(b&&b.find)for(g=b.find(a),h=0;h<g.count();h++)if(b=g.getItem(h),c||!b.isReadOnly())k=b.getPosition(d.startNode)&CKEDITOR.POSITION_FOLLOWING||
d.startNode.equals(b),l=b.getPosition(d.endNode)&CKEDITOR.POSITION_PRECEDING+CKEDITOR.POSITION_IS_CONTAINED,k&&l&&e.push(b);return e}}}(),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 b(a){1>
arguments.length||(this.range=a,this.forceBrBreak=0,this.enlargeBr=1,this.enforceRealBlocks=0,this._||(this._={}))}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 e(a,b,d,h){a:{null==h&&(h=g(d));for(var k;k=h.shift();)if(k.getDtd().p){h={element:k,remaining:h};break a}h=null}if(!h)return 0;if((k=CKEDITOR.filter.instances[h.element.data("cke-filter")])&&!k.check(b))return e(a,b,d,h.remaining);
b=new CKEDITOR.dom.range(h.element);b.selectNodeContents(h.element);b=b.createIterator();b.enlargeBr=a.enlargeBr;b.enforceRealBlocks=a.enforceRealBlocks;b.activeFilter=b.filter=k;a._.nestedEditable={element:h.element,container:d,remaining:h.remaining,iterator:b};return 1}function a(a,b,d){if(!b)return!1;a=a.clone();a.collapse(!d);return a.checkBoundaryOfElement(b,d?CKEDITOR.START:CKEDITOR.END)}var h=/^[\r\n\t ]+$/,l=CKEDITOR.dom.walker.bookmark(!1,!0),n=CKEDITOR.dom.walker.whitespaces(!0),k=function(a){return l(a)&&
n(a)},d={dd:1,dt:1,li:1};b.prototype={getNextParagraph:function(c){var b,m,g,n,A;c=c||"p";if(this._.nestedEditable){if(b=this._.nestedEditable.iterator.getNextParagraph(c))return this.activeFilter=this._.nestedEditable.iterator.activeFilter,b;this.activeFilter=this.filter;if(e(this,c,this._.nestedEditable.container,this._.nestedEditable.remaining))return this.activeFilter=this._.nestedEditable.iterator.activeFilter,this._.nestedEditable.iterator.getNextParagraph(c);this._.nestedEditable=null}if(!this.range.root.getDtd()[c])return null;
if(!this._.started){var r=this.range.clone();m=r.startPath();var q=r.endPath(),y=!r.collapsed&&a(r,m.block),v=!r.collapsed&&a(r,q.block,1);r.shrink(CKEDITOR.SHRINK_ELEMENT,!0);y&&r.setStartAt(m.block,CKEDITOR.POSITION_BEFORE_END);v&&r.setEndAt(q.block,CKEDITOR.POSITION_AFTER_START);m=r.endContainer.hasAscendant("pre",!0)||r.startContainer.hasAscendant("pre",!0);r.enlarge(this.forceBrBreak&&!m||!this.enlargeBr?CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS:CKEDITOR.ENLARGE_BLOCK_CONTENTS);r.collapsed||(m=new CKEDITOR.dom.walker(r.clone()),
q=CKEDITOR.dom.walker.bookmark(!0,!0),m.evaluator=q,this._.nextNode=m.next(),m=new CKEDITOR.dom.walker(r.clone()),m.evaluator=q,m=m.previous(),this._.lastNode=m.getNextSourceNode(!0,null,r.root),this._.lastNode&&this._.lastNode.type==CKEDITOR.NODE_TEXT&&!CKEDITOR.tools.trim(this._.lastNode.getText())&&this._.lastNode.getParent().isBlockBoundary()&&(q=this.range.clone(),q.moveToPosition(this._.lastNode,CKEDITOR.POSITION_AFTER_END),q.checkEndOfBlock()&&(q=new CKEDITOR.dom.elementPath(q.endContainer,
q.root),this._.lastNode=(q.block||q.blockLimit).getNextSourceNode(!0))),this._.lastNode&&r.root.contains(this._.lastNode)||(this._.lastNode=this._.docEndMarker=r.document.createText(""),this._.lastNode.insertAfter(m)),r=null);this._.started=1;m=r}q=this._.nextNode;r=this._.lastNode;for(this._.nextNode=null;q;){var y=0,v=q.hasAscendant("pre"),z=q.type!=CKEDITOR.NODE_ELEMENT,p=0;if(z)q.type==CKEDITOR.NODE_TEXT&&h.test(q.getText())&&(z=0);else{var u=q.getName();if(CKEDITOR.dtd.$block[u]&&"false"==q.getAttribute("contenteditable")){b=
q;e(this,c,b);break}else if(q.isBlockBoundary(this.forceBrBreak&&!v&&{br:1})){if("br"==u)z=1;else if(!m&&!q.getChildCount()&&"hr"!=u){b=q;g=q.equals(r);break}m&&(m.setEndAt(q,CKEDITOR.POSITION_BEFORE_START),"br"!=u&&(this._.nextNode=q));y=1}else{if(q.getFirst()){m||(m=this.range.clone(),m.setStartAt(q,CKEDITOR.POSITION_BEFORE_START));q=q.getFirst();continue}z=1}}z&&!m&&(m=this.range.clone(),m.setStartAt(q,CKEDITOR.POSITION_BEFORE_START));g=(!y||z)&&q.equals(r);if(m&&!y)for(;!q.getNext(k)&&!g;){u=
q.getParent();if(u.isBlockBoundary(this.forceBrBreak&&!v&&{br:1})){y=1;z=0;g||u.equals(r);m.setEndAt(u,CKEDITOR.POSITION_BEFORE_END);break}q=u;z=1;g=q.equals(r);p=1}z&&m.setEndAt(q,CKEDITOR.POSITION_AFTER_END);q=this._getNextSourceNode(q,p,r);if((g=!q)||y&&m)break}if(!b){if(!m)return this._.docEndMarker&&this._.docEndMarker.remove(),this._.nextNode=null;b=new CKEDITOR.dom.elementPath(m.startContainer,m.root);q=b.blockLimit;y={div:1,th:1,td:1};b=b.block;!b&&q&&!this.enforceRealBlocks&&y[q.getName()]&&
m.checkStartOfBlock()&&m.checkEndOfBlock()&&!q.equals(m.root)?b=q:!b||this.enforceRealBlocks&&b.is(d)?(b=this.range.document.createElement(c),m.extractContents().appendTo(b),b.trim(),m.insertNode(b),n=A=!0):"li"!=b.getName()?m.checkStartOfBlock()&&m.checkEndOfBlock()||(b=b.clone(!1),m.extractContents().appendTo(b),b.trim(),A=m.splitBlock(),n=!A.wasStartOfBlock,A=!A.wasEndOfBlock,m.insertNode(b)):g||(this._.nextNode=b.equals(r)?null:this._getNextSourceNode(m.getBoundaryNodes().endNode,1,r))}n&&(n=
b.getPrevious())&&n.type==CKEDITOR.NODE_ELEMENT&&("br"==n.getName()?n.remove():n.getLast()&&"br"==n.getLast().$.nodeName.toLowerCase()&&n.getLast().remove());A&&(n=b.getLast())&&n.type==CKEDITOR.NODE_ELEMENT&&"br"==n.getName()&&(!CKEDITOR.env.needsBrFiller||n.getPrevious(l)||n.getNext(l))&&n.remove();this._.nextNode||(this._.nextNode=g||b.equals(r)||!r?null:this._getNextSourceNode(b,1,r));return b},_getNextSourceNode:function(a,b,d){function e(a){return!(a.equals(d)||a.equals(h))}var h=this.range.root;
for(a=a.getNextSourceNode(b,null,e);!l(a);)a=a.getNextSourceNode(b,null,e);return a}};CKEDITOR.dom.range.prototype.createIterator=function(){return new b(this)}}(),CKEDITOR.command=function(b,g){this.uiItems=[];this.exec=function(a){if(this.state==CKEDITOR.TRISTATE_DISABLED||!this.checkAllowed())return!1;this.editorFocus&&b.focus();return!1===this.fire("exec")?!0:!1!==g.exec.call(this,b,a)};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:g.refresh&&!1!==g.refresh.apply(this,arguments)};var e;this.checkAllowed=function(a){return a||"boolean"!=typeof e?e=b.activeFilter.checkFeature(this):e};CKEDITOR.tools.extend(this,g,{modes:{wysiwyg:1},editorFocus:1,contextSensitive:!!g.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(b){if(this.state==b||b!=CKEDITOR.TRISTATE_DISABLED&&!this.checkAllowed())return!1;this.previousState=this.state;this.state=b;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 b(a,c,b,d,f){var e,h;a=[];for(e in c){h=c[e];h="boolean"==typeof h?{}:"function"==typeof h?{match:h}:G(h);"$"!=e.charAt(0)&&(h.elements=e);b&&(h.featureName=b.toLowerCase());var p=h;p.elements=n(p.elements,/\s+/)||null;p.propertiesOnly=p.propertiesOnly||!0===p.elements;var m=/\s*,\s*/,g=void 0;for(g in P){p[g]=n(p[g],
m)||null;var k=p,u=H[g],r=n(p[H[g]],m),E=p[g],B=[],w=!0,l=void 0;r?w=!1:r={};for(l in E)"!"==l.charAt(0)&&(l=l.slice(1),B.push(l),r[l]=!0,w=!1);for(;l=B.pop();)E[l]=E["!"+l],delete E["!"+l];k[u]=(w?!1:r)||null}p.match=p.match||null;d.push(h);a.push(h)}c=f.elements;f=f.generic;var O;b=0;for(d=a.length;b<d;++b){e=G(a[b]);h=!0===e.classes||!0===e.styles||!0===e.attributes;p=e;g=u=m=void 0;for(m in P)p[m]=y(p[m]);k=!0;for(g in H){m=H[g];u=p[m];r=[];E=void 0;for(E in u)-1<E.indexOf("*")?r.push(new RegExp("^"+
E.replace(/\*/g,".*")+"$")):r.push(E);u=r;u.length&&(p[m]=u,k=!1)}p.nothingRequired=k;p.noProperties=!(p.attributes||p.classes||p.styles);if(!0===e.elements||null===e.elements)f[h?"unshift":"push"](e);else for(O in p=e.elements,delete e.elements,p)if(c[O])c[O][h?"unshift":"push"](e);else c[O]=[e]}}function g(a,c,b,d){if(!a.match||a.match(c))if(d||k(a,c))if(a.propertiesOnly||(b.valid=!0),b.allAttributes||(b.allAttributes=e(a.attributes,c.attributes,b.validAttributes)),b.allStyles||(b.allStyles=e(a.styles,
c.styles,b.validStyles)),!b.allClasses){a=a.classes;c=c.classes;d=b.validClasses;if(a)if(!0===a)a=!0;else{for(var f=0,p=c.length,h;f<p;++f)h=c[f],d[h]||(d[h]=a(h));a=!1}else a=!1;b.allClasses=a}}function e(a,c,b){if(!a)return!1;if(!0===a)return!0;for(var d in c)b[d]||(b[d]=a(d));return!1}function a(a,c,b){if(!a.match||a.match(c)){if(a.noProperties)return!1;b.hadInvalidAttribute=h(a.attributes,c.attributes)||b.hadInvalidAttribute;b.hadInvalidStyle=h(a.styles,c.styles)||b.hadInvalidStyle;a=a.classes;
c=c.classes;if(a){for(var d=!1,f=!0===a,e=c.length;e--;)if(f||a(c[e]))c.splice(e,1),d=!0;a=d}else a=!1;b.hadInvalidClass=a||b.hadInvalidClass}}function h(a,c){if(!a)return!1;var b=!1,d=!0===a,f;for(f in c)if(d||a(f))delete c[f],b=!0;return b}function l(a,c,b){if(a.disabled||a.customConfig&&!b||!c)return!1;a._.cachedChecks={};return!0}function n(a,c){if(!a)return!1;if(!0===a)return a;if("string"==typeof a)return a=L(a),"*"==a?!0:CKEDITOR.tools.convertArrayToObject(a.split(c));if(CKEDITOR.tools.isArray(a))return a.length?
CKEDITOR.tools.convertArrayToObject(a):!1;var b={},d=0,f;for(f in a)b[f]=a[f],d++;return d?b:!1}function k(a,c){if(a.nothingRequired)return!0;var b,f,e,p;if(e=a.requiredClasses)for(p=c.classes,b=0;b<e.length;++b)if(f=e[b],"string"==typeof f){if(-1==CKEDITOR.tools.indexOf(p,f))return!1}else if(!CKEDITOR.tools.checkIfAnyArrayItemMatches(p,f))return!1;return d(c.styles,a.requiredStyles)&&d(c.attributes,a.requiredAttributes)}function d(a,c){if(!c)return!0;for(var b=0,d;b<c.length;++b)if(d=c[b],"string"==
typeof d){if(!(d in a))return!1}else if(!CKEDITOR.tools.checkIfAnyObjectPropertyMatches(a,d))return!1;return!0}function c(a){if(!a)return{};a=a.split(/\s*,\s*/).sort();for(var c={};a.length;)c[a.shift()]="cke-test";return c}function f(a){var c,b,d,f,e={},p=1;for(a=L(a);c=a.match(E);)(b=c[2])?(d=m(b,"styles"),f=m(b,"attrs"),b=m(b,"classes")):d=f=b=null,e["$"+p++]={elements:c[1],classes:b,styles:d,attributes:f},a=a.slice(c[0].length);return e}function m(a,c){var b=a.match(S[c]);return b?L(b[1]):null}
function t(a){var c=a.styleBackup=a.attributes.style,b=a.classBackup=a.attributes["class"];a.styles||(a.styles=CKEDITOR.tools.parseCssText(c||"",1));a.classes||(a.classes=b?b.split(/\s+/):[])}function x(c,b,d,f){var e=0,p;f.toHtml&&(b.name=b.name.replace(O,"$1"));if(f.doCallbacks&&c.elementCallbacks){a:{p=c.elementCallbacks;for(var h=0,m=p.length,k;h<m;++h)if(k=p[h](b)){p=k;break a}p=void 0}if(p)return p}if(f.doTransform&&(p=c._.transformations[b.name])){t(b);for(h=0;h<p.length;++h)u(c,b,p[h]);r(b)}if(f.doFilter){a:{h=
b.name;m=c._;c=m.allowedRules.elements[h];p=m.allowedRules.generic;h=m.disallowedRules.elements[h];m=m.disallowedRules.generic;k=f.skipRequired;var E={valid:!1,validAttributes:{},validClasses:{},validStyles:{},allAttributes:!1,allClasses:!1,allStyles:!1,hadInvalidAttribute:!1,hadInvalidClass:!1,hadInvalidStyle:!1},B,w;if(c||p){t(b);if(h)for(B=0,w=h.length;B<w;++B)if(!1===a(h[B],b,E)){c=null;break a}if(m)for(B=0,w=m.length;B<w;++B)a(m[B],b,E);if(c)for(B=0,w=c.length;B<w;++B)g(c[B],b,E,k);if(p)for(B=
0,w=p.length;B<w;++B)g(p[B],b,E,k);c=E}else c=null}if(!c||!c.valid)return d.push(b),1;w=c.validAttributes;var l=c.validStyles;p=c.validClasses;var h=b.attributes,H=b.styles,m=b.classes;k=b.classBackup;var n=b.styleBackup,y,C,D=[],E=[],A=/^data-cke-/;B=!1;delete h.style;delete h["class"];delete b.classBackup;delete b.styleBackup;if(!c.allAttributes)for(y in h)w[y]||(A.test(y)?y==(C=y.replace(/^data-cke-saved-/,""))||w[C]||(delete h[y],B=!0):(delete h[y],B=!0));if(!c.allStyles||c.hadInvalidStyle){for(y in H)c.allStyles||
l[y]?D.push(y+":"+H[y]):B=!0;D.length&&(h.style=D.sort().join("; "))}else n&&(h.style=n);if(!c.allClasses||c.hadInvalidClass){for(y=0;y<m.length;++y)(c.allClasses||p[m[y]])&&E.push(m[y]);E.length&&(h["class"]=E.sort().join(" "));k&&E.length<k.split(/\s+/).length&&(B=!0)}else k&&(h["class"]=k);B&&(e=1);if(!f.skipFinalValidation&&!q(b))return d.push(b),1}f.toHtml&&(b.name=b.name.replace(T,"cke:$1"));return e}function A(a){var c=[],b;for(b in a)-1<b.indexOf("*")&&c.push(b.replace(/\*/g,".*"));return c.length?
new RegExp("^(?:"+c.join("|")+")$"):null}function r(a){var c=a.attributes,b;delete c.style;delete c["class"];if(b=CKEDITOR.tools.writeCssText(a.styles,!0))c.style=b;a.classes.length&&(c["class"]=a.classes.sort().join(" "))}function q(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 y(a){if(!a)return!1;if(!0===a)return!0;var c=A(a);return function(b){return b in a||c&&b.match(c)}}function v(){return new CKEDITOR.htmlParser.element("br")}
function z(a){return a.type==CKEDITOR.NODE_ELEMENT&&("br"==a.name||F.$block[a.name])}function p(a,c,b){var d=a.name;if(F.$empty[d]||!a.children.length)"hr"==d&&"br"==c?a.replaceWith(v()):(a.parent&&b.push({check:"it",el:a.parent}),a.remove());else if(F.$block[d]||"tr"==d)if("br"==c)a.previous&&!z(a.previous)&&(c=v(),c.insertBefore(a)),a.next&&!z(a.next)&&(c=v(),c.insertAfter(a)),a.replaceWithChildren();else{var d=a.children,f;b:{f=F[c];for(var e=0,p=d.length,h;e<p;++e)if(h=d[e],h.type==CKEDITOR.NODE_ELEMENT&&
!f[h.name]){f=!1;break b}f=!0}if(f)a.name=c,a.attributes={},b.push({check:"parent-down",el:a});else{f=a.parent;for(var e=f.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT||"body"==f.name,m,g,p=d.length;0<p;)h=d[--p],e&&(h.type==CKEDITOR.NODE_TEXT||h.type==CKEDITOR.NODE_ELEMENT&&F.$inline[h.name])?(m||(m=new CKEDITOR.htmlParser.element(c),m.insertAfter(a),b.push({check:"parent-down",el:m})),m.add(h,0)):(m=null,g=F[f.name]||F.span,h.insertAfter(a),f.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT||h.type!=CKEDITOR.NODE_ELEMENT||
g[h.name]||b.push({check:"el-up",el:h}));a.remove()}}else d in{style:1,script:1}?a.remove():(a.parent&&b.push({check:"it",el:a.parent}),a.replaceWithChildren())}function u(a,c,b){var d,f;for(d=0;d<b.length;++d)if(f=b[d],!(f.check&&!a.check(f.check,!1)||f.left&&!f.left(c))){f.right(c,Q);break}}function B(a,c){var b=c.getDefinition(),d=b.attributes,f=b.styles,e,h,p,m;if(a.name!=b.element)return!1;for(e in d)if("class"==e)for(b=d[e].split(/\s+/),p=a.classes.join("|");m=b.pop();){if(-1==p.indexOf(m))return!1}else if(a.attributes[e]!=
d[e])return!1;for(h in f)if(a.styles[h]!=f[h])return!1;return!0}function w(a,c){var b,d;"string"==typeof a?b=a:a instanceof CKEDITOR.style?d=a:(b=a[0],d=a[1]);return[{element:b,left:d,right:function(a,b){b.transform(a,c)}}]}function C(a){return function(c){return B(c,a)}}function D(a){return function(c,b){b[a](c)}}var F=CKEDITOR.dtd,G=CKEDITOR.tools.copy,L=CKEDITOR.tools.trim,I=["","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:{}};CKEDITOR.filter.instances[this.id]=this;if(a instanceof CKEDITOR.editor){a=this.editor=a;this.customConfig=!0;var c=a.config.allowedContent;!0===c?this.disabled=!0:(c||(this.customConfig=!1),this.allow(c,"config",1),this.allow(a.config.extraAllowedContent,"extra",1),this.allow(I[a.enterMode]+
" "+I[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(a,c,d){if(!l(this,a,d))return!1;var e,h;if("string"==typeof a)a=f(a);else if(a instanceof CKEDITOR.style){if(a.toAllowedContentRules)return this.allow(a.toAllowedContentRules(this.editor),c,d);e=a.getDefinition();a={};d=e.attributes;a[e.element]=e={styles:e.styles,requiredStyles:e.styles&&CKEDITOR.tools.objectKeys(e.styles)};
d&&(d=G(d),e.classes=d["class"]?d["class"].split(/\s+/):null,e.requiredClasses=e.classes,delete d["class"],e.attributes=d,e.requiredAttributes=d&&CKEDITOR.tools.objectKeys(d))}else if(CKEDITOR.tools.isArray(a)){for(e=0;e<a.length;++e)h=this.allow(a[e],c,d);return h}b(this,a,c,this.allowedContent,this._.allowedRules);return!0},applyTo:function(a,c,b,d){if(this.disabled)return!1;var f=this,e=[],h=this.editor&&this.editor.config.protectedSource,m,g=!1,k={doFilter:!b,doTransform:!0,doCallbacks:!0,toHtml:c};
a.forEach(function(a){if(a.type==CKEDITOR.NODE_ELEMENT){if("off"==a.attributes["data-cke-filter"])return!1;if(!c||"span"!=a.name||!~CKEDITOR.tools.objectKeys(a.attributes).join("|").indexOf("data-cke-"))if(m=x(f,a,e,k),m&1)g=!0;else if(m&2)return!1}else if(a.type==CKEDITOR.NODE_COMMENT&&a.value.match(/^\{cke_protected\}(?!\{C\})/)){var b;a:{var d=decodeURIComponent(a.value.replace(/^\{cke_protected\}/,""));b=[];var p,u,r;if(h)for(u=0;u<h.length;++u)if((r=d.match(h[u]))&&r[0].length==d.length){b=!0;
break a}d=CKEDITOR.htmlParser.fragment.fromHtml(d);1==d.children.length&&(p=d.children[0]).type==CKEDITOR.NODE_ELEMENT&&x(f,p,b,k);b=!b.length}b||e.push(a)}},null,!0);e.length&&(g=!0);var u;a=[];d=I[d||(this.editor?this.editor.enterMode:CKEDITOR.ENTER_P)];for(var r;b=e.pop();)b.type==CKEDITOR.NODE_ELEMENT?p(b,d,a):b.remove();for(;u=a.pop();)if(b=u.el,b.parent)switch(r=F[b.parent.name]||F.span,u.check){case "it":F.$removeEmpty[b.name]&&!b.children.length?p(b,d,a):q(b)||p(b,d,a);break;case "el-up":b.parent.type==
CKEDITOR.NODE_DOCUMENT_FRAGMENT||r[b.name]||p(b,d,a);break;case "parent-down":b.parent.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT||r[b.name]||p(b.parent,d,a)}return g},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(a){if(!l(this,a,!0))return!1;"string"==typeof a&&(a=f(a));b(this,a,null,this.disallowedContent,this._.disallowedRules);return!0},
addContentForms:function(a){if(!this.disabled&&a){var c,b,d=[],f;for(c=0;c<a.length&&!f;++c)b=a[c],("string"==typeof b||b instanceof CKEDITOR.style)&&this.check(b)&&(f=b);if(f){for(c=0;c<a.length;++c)d.push(w(a[c],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 c,b;if(!this.disabled&&a){var d=this._.transformations,f;for(f=0;f<a.length;++f){c=a[f];var e=void 0,h=void 0,p=void 0,m=void 0,g=void 0,k=void 0;b=[];for(h=0;h<c.length;++h)p=c[h],"string"==typeof p?(p=p.split(/\s*:\s*/),m=p[0],g=null,k=p[1]):(m=p.check,g=p.left,k=p.right),e||(e=p,e=e.element?e.element:m?m.match(/^([a-z0-9]+)/i)[0]:
e.left.getDefinition().element),g instanceof CKEDITOR.style&&(g=C(g)),b.push({check:m==e?null:m,left:g,right:"string"==typeof k?D(k):k});c=e;d[c]||(d[c]=[]);d[c].push(b)}}},check:function(a,b,d){if(this.disabled)return!0;if(CKEDITOR.tools.isArray(a)){for(var e=a.length;e--;)if(this.check(a[e],b,d))return!0;return!1}var h,p;if("string"==typeof a){p=a+"\x3c"+(!1===b?"0":"1")+(d?"1":"0")+"\x3e";if(p in this._.cachedChecks)return this._.cachedChecks[p];e=f(a).$1;h=e.styles;var m=e.classes;e.name=e.elements;
e.classes=m=m?m.split(/\s*,\s*/):[];e.styles=c(h);e.attributes=c(e.attributes);e.children=[];m.length&&(e.attributes["class"]=m.join(" "));h&&(e.attributes.style=CKEDITOR.tools.writeCssText(e.styles));h=e}else e=a.getDefinition(),h=e.styles,m=e.attributes||{},h&&!CKEDITOR.tools.isEmpty(h)?(h=G(h),m.style=CKEDITOR.tools.writeCssText(h,!0)):h={},h={name:e.element,attributes:m,classes:m["class"]?m["class"].split(/\s+/):[],styles:h,children:[]};var m=CKEDITOR.tools.clone(h),g=[],k;if(!1!==b&&(k=this._.transformations[h.name])){for(e=
0;e<k.length;++e)u(this,h,k[e]);r(h)}x(this,m,g,{doFilter:!0,doTransform:!1!==b,skipRequired:!d,skipFinalValidation:!d});b=0<g.length?!1:CKEDITOR.tools.objectCompare(h.attributes,m.attributes,!0)?!0:!1;"string"==typeof a&&(this._.cachedChecks[p]=b);return b},getAllowedEnterMode:function(){var a=["p","div","br"],c={p:CKEDITOR.ENTER_P,div:CKEDITOR.ENTER_DIV,br:CKEDITOR.ENTER_BR};return function(b,d){var f=a.slice(),e;if(this.check(I[b]))return b;for(d||(f=f.reverse());e=f.pop();)if(this.check(e))return c[e];
return CKEDITOR.ENTER_BR}}(),destroy:function(){delete CKEDITOR.filter.instances[this.id];delete this._;delete this.allowedContent;delete this.disallowedContent}};var P={styles:1,attributes:1,classes:1},H={styles:"requiredStyles",attributes:"requiredAttributes",classes:"requiredClasses"},E=/^([a-z0-9\-*\s]+)((?:\s*\{[!\w\-,\s\*]+\}\s*|\s*\[[!\w\-,\s\*]+\]\s*|\s*\([!\w\-,\s\*]+\)\s*){0,3})(?:;\s*|$)/i,S={styles:/{([^}]+)}/,attrs:/\[([^\]]+)\]/,classes:/\(([^\)]+)\)/},O=/^cke:(object|embed|param)$/,
T=/^(object|embed|param)$/,Q;Q=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,c,b){b=b||c;if(!(b in a.styles)){var d=a.attributes[c];d&&(/^\d+$/.test(d)&&(d+="px"),a.styles[b]=d)}delete a.attributes[c]},lengthToAttribute:function(a,c,b){b=b||c;if(!(b in a.attributes)){var d=a.styles[c],f=d&&d.match(/^(\d+)(?:\.\d*)?px$/);
f?a.attributes[b]=f[1]:"cke-test"==d&&(a.attributes[b]="cke-test")}delete a.styles[c]},alignmentToStyle:function(a){if(!("float"in a.styles)){var c=a.attributes.align;if("left"==c||"right"==c)a.styles["float"]=c}delete a.attributes.align},alignmentToAttribute:function(a){if(!("align"in a.attributes)){var c=a.styles["float"];if("left"==c||"right"==c)a.attributes.align=c}delete a.styles["float"]},splitBorderShorthand:function(a){function c(d){a.styles["border-top-width"]=b[d[0]];a.styles["border-right-width"]=
b[d[1]];a.styles["border-bottom-width"]=b[d[2]];a.styles["border-left-width"]=b[d[3]]}if(a.styles.border){var b=a.styles.border.match(/([\.\d]+\w+)/g)||["0px"];switch(b.length){case 1:a.styles["border-width"]=b[0];break;case 2:c([0,1,0,1]);break;case 3:c([0,1,2,1]);break;case 4:c([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 c(d){a.styles["margin-top"]=
b[d[0]];a.styles["margin-right"]=b[d[1]];a.styles["margin-bottom"]=b[d[2]];a.styles["margin-left"]=b[d[3]]}if(a.styles.margin){var b=a.styles.margin.match(/(\-?[\.\d]+\w+)/g)||["0px"];switch(b.length){case 1:a.styles.margin=b[0];break;case 2:c([0,1,0,1]);break;case 3:c([0,1,2,1]);break;case 4:c([0,1,2,3])}delete a.styles.margin}},matchesStyle:B,transform:function(a,c){if("string"==typeof c)a.name=c;else{var b=c.getDefinition(),d=b.styles,f=b.attributes,e,h,p,m;a.name=b.element;for(e in f)if("class"==
e)for(b=a.classes.join("|"),p=f[e].split(/\s+/);m=p.pop();)-1==b.indexOf(m)&&a.classes.push(m);else a.attributes[e]=f[e];for(h in d)a.styles[h]=d[h]}}}}(),function(){CKEDITOR.focusManager=function(b){if(b.focusManager)return b.focusManager;this.hasFocus=!1;this.currentActive=null;this._={editor:b};return this};CKEDITOR.focusManager._={blurDelay:200};CKEDITOR.focusManager.prototype={focus:function(b){this._.timer&&clearTimeout(this._.timer);b&&(this.currentActive=b);this.hasFocus||this._.locked||((b=
CKEDITOR.currentInstance)&&b.focusManager.blur(1),this.hasFocus=!0,(b=this._.editor.container)&&b.addClass("cke_focus"),this._.editor.fire("focus"))},lock:function(){this._.locked=1},unlock:function(){delete this._.locked},blur:function(b){function g(){var a=this._.editor;this.hasFocus&&(this.hasFocus=!1,CKEDITOR.env.chrome&&a.editable().isInline()&&a.window.$.getSelection().removeAllRanges(),(a=this._.editor.container)&&a.removeClass("cke_focus"),this._.editor.fire("blur"))}if(!this._.locked){this._.timer&&
clearTimeout(this._.timer);var e=CKEDITOR.focusManager._.blurDelay;b||!e?g.call(this):this._.timer=CKEDITOR.tools.setTimeout(function(){delete this._.timer;g.call(this)},e,this)}},add:function(b,g){var e=b.getCustomData("focusmanager");if(!e||e!=this){e&&e.remove(b);var e="focus",a="blur";g&&(CKEDITOR.env.ie?(e="focusin",a="focusout"):CKEDITOR.event.useCapture=1);var h={blur:function(){b.equals(this.currentActive)&&this.blur()},focus:function(){this.focus(b)}};b.on(e,h.focus,this);b.on(a,h.blur,this);
g&&(CKEDITOR.event.useCapture=0);b.setCustomData("focusmanager",this);b.setCustomData("focusmanager_handlers",h)}},remove:function(b){b.removeCustomData("focusmanager");var g=b.removeCustomData("focusmanager_handlers");b.removeListener("blur",g.blur);b.removeListener("focus",g.focus)}}}(),CKEDITOR.keystrokeHandler=function(b){if(b.keystrokeHandler)return b.keystrokeHandler;this.keystrokes={};this.blockedKeystrokes={};this._={editor:b};return this},function(){var b,g=function(a){a=a.data;var e=a.getKeystroke(),
g=this.keystrokes[e],n=this._.editor;b=!1===n.fire("key",{keyCode:e,domEvent:a});b||(g&&(b=!1!==n.execCommand(g,{from:"keystrokeHandler"})),b||(b=!!this.blockedKeystrokes[e]));b&&a.preventDefault(!0);return!b},e=function(a){b&&(b=!1,a.data.preventDefault(!0))};CKEDITOR.keystrokeHandler.prototype={attach:function(a){a.on("keydown",g,this);if(CKEDITOR.env.gecko&&CKEDITOR.env.mac)a.on("keypress",e,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,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(b,g,e){b&&CKEDITOR.lang.languages[b]||(b=this.detect(g,b));var a=this;g=function(){a[b].dir=a.rtl[b]?"rtl":"ltr";e(b,a[b])};
this[b]?g():CKEDITOR.scriptLoader.load(CKEDITOR.getUrl("lang/"+b+".js"),g,this)},detect:function(b,g){var e=this.languages;g=g||navigator.userLanguage||navigator.language||b;var a=g.toLowerCase().match(/([a-z]+)(?:-([a-z]+))?/),h=a[1],a=a[2];e[h+"-"+a]?h=h+"-"+a:e[h]||(h=null);CKEDITOR.lang.detect=h?function(){return h}:function(a){return a};return h||b}}}(),CKEDITOR.scriptLoader=function(){var b={},g={};return{load:function(e,a,h,l){var n="string"==typeof e;n&&(e=[e]);h||(h=CKEDITOR);var k=e.length,
d=[],c=[],f=function(b){a&&(n?a.call(h,b):a.call(h,d,c))};if(0===k)f(!0);else{var m=function(a,b){(b?d:c).push(a);0>=--k&&(l&&CKEDITOR.document.getDocumentElement().removeStyle("cursor"),f(b))},t=function(a,c){b[a]=1;var d=g[a];delete g[a];for(var f=0;f<d.length;f++)d[f](a,c)},x=function(c){if(b[c])m(c,!0);else{var d=g[c]||(g[c]=[]);d.push(m);if(!(1<d.length)){var f=new CKEDITOR.dom.element("script");f.setAttributes({type:"text/javascript",src:c});a&&(CKEDITOR.env.ie&&(8>=CKEDITOR.env.version||CKEDITOR.env.ie9Compat)?
f.$.onreadystatechange=function(){if("loaded"==f.$.readyState||"complete"==f.$.readyState)f.$.onreadystatechange=null,t(c,!0)}:(f.$.onload=function(){setTimeout(function(){t(c,!0)},0)},f.$.onerror=function(){t(c,!1)}));f.appendTo(CKEDITOR.document.getHead())}}};l&&CKEDITOR.document.getDocumentElement().setStyle("cursor","wait");for(var A=0;A<k;A++)x(e[A])}},queue:function(){function b(){var e;(e=a[0])&&this.load(e.scriptUrl,e.callback,CKEDITOR,0)}var a=[];return function(h,g){var n=this;a.push({scriptUrl:h,
callback:function(){g&&g.apply(this,arguments);a.shift();b.call(n)}});1==a.length&&b.call(this)}}()}}(),CKEDITOR.resourceManager=function(b,g){this.basePath=b;this.fileName=g;this.registered={};this.loaded={};this.externals={};this._={waitingList:{}}},CKEDITOR.resourceManager.prototype={add:function(b,g){if(this.registered[b])throw Error('[CKEDITOR.resourceManager.add] The resource name "'+b+'" is already registered.');var e=this.registered[b]=g||{};e.name=b;e.path=this.getPath(b);CKEDITOR.fire(b+
CKEDITOR.tools.capitalize(this.fileName)+"Ready",e);return this.get(b)},get:function(b){return this.registered[b]||null},getPath:function(b){var g=this.externals[b];return CKEDITOR.getUrl(g&&g.dir||this.basePath+b+"/")},getFilePath:function(b){var g=this.externals[b];return CKEDITOR.getUrl(this.getPath(b)+(g?g.file:this.fileName+".js"))},addExternal:function(b,g,e){b=b.split(",");for(var a=0;a<b.length;a++){var h=b[a];e||(g=g.replace(/[^\/]+$/,function(a){e=a;return""}));this.externals[h]={dir:g,
file:e||this.fileName+".js"}}},load:function(b,g,e){CKEDITOR.tools.isArray(b)||(b=b?[b]:[]);for(var a=this.loaded,h=this.registered,l=[],n={},k={},d=0;d<b.length;d++){var c=b[d];if(c)if(a[c]||h[c])k[c]=this.get(c);else{var f=this.getFilePath(c);l.push(f);f in n||(n[f]=[]);n[f].push(c)}}CKEDITOR.scriptLoader.load(l,function(c,b){if(b.length)throw Error('[CKEDITOR.resourceManager.load] Resource name "'+n[b[0]].join(",")+'" was not found at "'+b[0]+'".');for(var d=0;d<c.length;d++)for(var f=n[c[d]],
h=0;h<f.length;h++){var l=f[h];k[l]=this.get(l);a[l]=1}g.call(e,k)},this)}},CKEDITOR.plugins=new CKEDITOR.resourceManager("plugins/","plugin"),CKEDITOR.plugins.load=CKEDITOR.tools.override(CKEDITOR.plugins.load,function(b){var g={};return function(e,a,h){var l={},n=function(e){b.call(this,e,function(b){CKEDITOR.tools.extend(l,b);var c=[],f;for(f in b){var e=b[f],k=e&&e.requires;if(!g[f]){if(e.icons)for(var x=e.icons.split(","),A=x.length;A--;)CKEDITOR.skin.addIcon(x[A],e.path+"icons/"+(CKEDITOR.env.hidpi&&
e.hidpi?"hidpi/":"")+x[A]+".png");g[f]=1}if(k)for(k.split&&(k=k.split(",")),e=0;e<k.length;e++)l[k[e]]||c.push(k[e])}if(c.length)n.call(this,c);else{for(f in l)e=l[f],e.onLoad&&!e.onLoad._called&&(!1===e.onLoad()&&delete l[f],e.onLoad._called=1);a&&a.call(h||window,l)}},this)};n.call(this,e)}}),CKEDITOR.plugins.setLang=function(b,g,e){var a=this.get(b);b=a.langEntries||(a.langEntries={});a=a.lang||(a.lang=[]);a.split&&(a=a.split(","));-1==CKEDITOR.tools.indexOf(a,g)&&a.push(g);b[g]=e},CKEDITOR.ui=
function(b){if(b.ui)return b.ui;this.items={};this.instances={};this.editor=b;this._={handlers:{}};return this},CKEDITOR.ui.prototype={add:function(b,g,e){e.name=b.toLowerCase();var a=this.items[b]={type:g,command:e.command||null,args:Array.prototype.slice.call(arguments,2)};CKEDITOR.tools.extend(a,e)},get:function(b){return this.instances[b]},create:function(b){var g=this.items[b],e=g&&this._.handlers[g.type],a=g&&g.command&&this.editor.getCommand(g.command),e=e&&e.create.apply(this,g.args);this.instances[b]=
e;a&&a.uiItems.push(e);e&&!e.type&&(e.type=g.type);return e},addHandler:function(b,g){this._.handlers[b]=g},space:function(b){return CKEDITOR.document.getById(this.spaceId(b))},spaceId:function(b){return this.editor.id+"_"+b}},CKEDITOR.event.implementOn(CKEDITOR.ui),function(){function b(c,b,d){CKEDITOR.event.call(this);c=c&&CKEDITOR.tools.clone(c);if(void 0!==b){if(!(b instanceof CKEDITOR.dom.element))throw Error("Expect element of type CKEDITOR.dom.element.");if(!d)throw Error("One of the element modes must be specified.");
if(CKEDITOR.env.ie&&CKEDITOR.env.quirks&&d==CKEDITOR.ELEMENT_MODE_INLINE)throw Error("Inline element mode is not supported on IE quirks.");if(!e(b,d))throw Error('The specified element mode is not supported on element: "'+b.getName()+'".');this.element=b;this.elementMode=d;this.name=this.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO&&(b.getId()||b.getNameAtt())}else this.elementMode=CKEDITOR.ELEMENT_MODE_NONE;this._={};this.commands={};this.templates={};this.name=this.name||g();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",a);this.on("selectionChange",function(a){l(this,a.data.path)});this.on("activeFilterChange",function(){l(this,this.elementPath(),!0)});this.on("mode",a);this.on("instanceReady",function(){this.config.startupFocus&&this.focus()});CKEDITOR.fire("instanceCreated",null,
this);CKEDITOR.add(this);CKEDITOR.tools.setTimeout(function(){"destroyed"!==this.status?k(this,c):CKEDITOR.warn("editor-incorrect-destroy")},0,this)}function g(){do var a="editor"+ ++x;while(CKEDITOR.instances[a]);return a}function e(a,c){return c==CKEDITOR.ELEMENT_MODE_INLINE?a.is(CKEDITOR.dtd.$editable)||a.is("textarea"):c==CKEDITOR.ELEMENT_MODE_REPLACE?!a.is(CKEDITOR.dtd.$nonBodyContent):1}function a(){var a=this.commands,c;for(c in a)h(this,a[c])}function h(a,c){c[c.startDisabled?"disable":a.readOnly&&
!c.readOnly?"disable":c.modes[a.mode]?"enable":"disable"]()}function l(a,c,b){if(c){var d,f,e=a.commands;for(f in e)d=e[f],(b||d.contextSensitive)&&d.refresh(a,c)}}function n(a){var c=a.config.customConfig;if(!c)return!1;var c=CKEDITOR.getUrl(c),b=A[c]||(A[c]={});b.fn?(b.fn.call(a,a.config),CKEDITOR.getUrl(a.config.customConfig)!=c&&n(a)||a.fireOnce("customConfigLoaded")):CKEDITOR.scriptLoader.queue(c,function(){b.fn=CKEDITOR.editorConfig?CKEDITOR.editorConfig:function(){};n(a)});return!0}function k(a,
c){a.on("customConfigLoaded",function(){if(c){if(c.on)for(var b in c.on)a.on(b,c.on[b]);CKEDITOR.tools.extend(a.config,c,!0);delete a.config.on}b=a.config;a.readOnly=b.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=b.tabIndex||a.element&&a.element.getAttribute("tabindex")||0;a.activeEnterMode=a.enterMode=a.blockless?CKEDITOR.ENTER_BR:b.enterMode;a.activeShiftEnterMode=a.shiftEnterMode=a.blockless?CKEDITOR.ENTER_BR:b.shiftEnterMode;b.skin&&(CKEDITOR.skinName=b.skin);a.fireOnce("configLoaded");a.dataProcessor=new CKEDITOR.htmlDataProcessor(a);a.filter=a.activeFilter=new CKEDITOR.filter(a);d(a)});c&&null!=c.customConfig&&(a.config.customConfig=
c.customConfig);n(a)||a.fireOnce("customConfigLoaded")}function d(a){CKEDITOR.skin.loadPart("editor",function(){c(a)})}function c(a){CKEDITOR.lang.load(a.config.language,a.config.defaultLanguage,function(c,b){var d=a.config.title;a.langCode=c;a.lang=CKEDITOR.tools.prototypedCopy(b);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(c){a.once("loaded",function(){a.fire("stylesSet",{styles:c})},null,null,1);m(a)})}function m(a){var c=a.config,b=c.plugins,d=c.extraPlugins,f=c.removePlugins;if(d)var e=new RegExp("(?:^|,)(?:"+d.replace(/\s*,\s*/g,"|")+")(?\x3d,|$)","g"),b=b.replace(e,""),b=b+(","+d);if(f)var h=new RegExp("(?:^|,)(?:"+f.replace(/\s*,\s*/g,"|")+")(?\x3d,|$)","g"),b=b.replace(h,"");CKEDITOR.env.air&&(b+=",adobeair");CKEDITOR.plugins.load(b.split(","),function(b){var d=[],
f=[],e=[];a.plugins=b;for(var p in b){var m=b[p],g=m.lang,k=null,l=m.requires,H;CKEDITOR.tools.isArray(l)&&(l=l.join(","));if(l&&(H=l.match(h)))for(;l=H.pop();)CKEDITOR.error("editor-plugin-required",{plugin:l.replace(",",""),requiredBy:p});g&&!a.lang[p]&&(g.split&&(g=g.split(",")),0<=CKEDITOR.tools.indexOf(g,a.langCode)?k=a.langCode:(k=a.langCode.replace(/-.*/,""),k=k!=a.langCode&&0<=CKEDITOR.tools.indexOf(g,k)?k:0<=CKEDITOR.tools.indexOf(g,"en")?"en":g[0]),m.langEntries&&m.langEntries[k]?(a.lang[p]=
m.langEntries[k],k=null):e.push(CKEDITOR.getUrl(m.path+"lang/"+k+".js")));f.push(k);d.push(m)}CKEDITOR.scriptLoader.load(e,function(){for(var b=["beforeInit","init","afterInit"],e=0;e<b.length;e++)for(var h=0;h<d.length;h++){var p=d[h];0===e&&f[h]&&p.lang&&p.langEntries&&(a.lang[p.name]=p.langEntries[f[h]]);if(p[b[e]])p[b[e]](a)}a.fireOnce("pluginsLoaded");c.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 t(){var a=this.element;if(a&&this.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO){var c=this.getData();this.config.htmlEncodeOutput&&(c=CKEDITOR.tools.htmlEncode(c));a.is("textarea")?a.setValue(c):a.setHtml(c);return!0}return!1}b.prototype=CKEDITOR.editor.prototype;CKEDITOR.editor=b;var x=0,A={};CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{addCommand:function(a,c){c.name=a.toLowerCase();var b=new CKEDITOR.command(this,
c);this.mode&&h(this,b);return this.commands[a]=b},_attachToForm:function(){function a(c){b.updateElement();b._.required&&!d.getValue()&&!1===b.fire("required")&&c.data.preventDefault()}function c(a){return!!(a&&a.call&&a.apply)}var b=this,d=b.element,f=new CKEDITOR.dom.element(d.$.form);d.is("textarea")&&f&&(f.on("submit",a),c(f.$.submit)&&(f.$.submit=CKEDITOR.tools.override(f.$.submit,function(c){return function(){a();c.apply?c.apply(this):c()}})),b.on("destroy",function(){f.removeListener("submit",
a)}))},destroy:function(a){this.fire("beforeDestroy");!a&&t.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,c){var b=this.getCommand(a),d={name:a,commandData:c,command:b};return b&&b.state!=CKEDITOR.TRISTATE_DISABLED&&!1!==this.fire("beforeCommandExec",d)&&(d.returnValue=b.exec(d.commandData),!b.async&&!1!==this.fire("afterCommandExec",d))?d.returnValue:!1},getCommand:function(a){return this.commands[a]},getData:function(a){!a&&this.fire("beforeGetData");var c=this._.data;"string"!=typeof c&&(c=(c=this.element)&&this.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE?
c.is("textarea")?c.getValue():c.getHtml():"");c={dataValue:c};!a&&this.fire("getData",c);return c.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,c,b){var d=!0,f=c;c&&"object"==typeof c&&(b=c.internal,f=c.callback,d=!c.noSnapshot);!b&&d&&this.fire("saveSnapshot");if(f||
!b)this.once("dataReady",function(a){!b&&d&&this.fire("saveSnapshot");f&&f.call(a.editor)});a={dataValue:a};!b&&this.fire("setData",a);this._.data=a.dataValue;!b&&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,c,b){this.fire("insertHtml",{dataValue:a,mode:c,range:b})},insertText:function(a){this.fire("insertText",a)},insertElement:function(a){this.fire("insertElement",
a)},getSelectedHtml:function(a){var c=this.editable(),b=this.getSelection(),b=b&&b.getRanges();if(!c||!b||0===b.length)return null;for(var d=new CKEDITOR.dom.documentFragment,f,e,h,m=0;m<b.length;m++){var g=b[m],k=g.startContainer;k.getName&&"tr"==k.getName()?(f||(f=k.getAscendant("table").clone(),f.append(k.getAscendant("tbody").clone()),d.append(f),f=f.findOne("tbody")),e&&e.equals(k)||(e=k,h=k.clone(),f.append(h)),h.append(g.cloneContents())):d.append(g.cloneContents())}c=f?d:c.getHtmlFromRange(b[0]);
return a?c.getHtml():c},extractSelectedHtml:function(a,c){var b=this.editable(),d=this.getSelection().getRanges();if(!b||0===d.length)return null;d=d[0];b=b.extractHtmlFromRange(d,c);c||this.getSelection().selectRanges([d]);return a?b.getHtml():b},focus:function(){this.fire("beforeFocus")},checkDirty:function(){return"ready"==this.status&&this._.previousValue!==this.getSnapshot()},resetDirty:function(){this._.previousValue=this.getSnapshot()},updateElement:function(){return t.call(this)},setKeystroke:function(){for(var a=
this.keystrokeHandler.keystrokes,c=CKEDITOR.tools.isArray(arguments[0])?arguments[0]:[[].slice.call(arguments,0)],b,d,f=c.length;f--;)b=c[f],d=0,CKEDITOR.tools.isArray(b)&&(d=b[1],b=b[0]),d?a[b]=d:delete a[b]},getCommandKeystroke:function(a){var c=a.name,b=this.keystrokeHandler.keystrokes,d;if(a.fakeKeystroke)return a.fakeKeystroke;for(d in b)if(b.hasOwnProperty(d)&&b[d]==c)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,c){a=a?this.blockless?CKEDITOR.ENTER_BR:a:this.enterMode;c=c?this.blockless?CKEDITOR.ENTER_BR:c:this.shiftEnterMode;if(this.activeEnterMode!=a||this.activeShiftEnterMode!=c)this.activeEnterMode=a,this.activeShiftEnterMode=c,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 b=/([\w\-:.]+)(?:(?:\s*=\s*(?:(?:"([^"]*)")|(?:'([^']*)')|([^\s>]+)))|(?=\s|$))/g,g={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(e){for(var a,h,l=0,n;a=this._.htmlPartsRegex.exec(e);){h=a.index;if(h>l)if(l=e.substring(l,h),n)n.push(l);else this.onText(l);l=this._.htmlPartsRegex.lastIndex;if(h=a[1])if(h=h.toLowerCase(),n&&CKEDITOR.dtd.$cdata[h]&&(this.onCDATA(n.join("")),
n=null),!n){this.onTagClose(h);continue}if(n)n.push(a[0]);else if(h=a[3]){if(h=h.toLowerCase(),!/="/.test(h)){var k={},d,c=a[4];a=!!a[5];if(c)for(;d=b.exec(c);){var f=d[1].toLowerCase();d=d[2]||d[3]||d[4]||"";k[f]=!d&&g[f]?f:CKEDITOR.tools.htmlDecodeAttr(d)}this.onTagOpen(h,k,a);!n&&CKEDITOR.dtd.$cdata[h]&&(n=[])}}else if(h=a[2])this.onComment(h)}if(e.length>l)this.onText(e.substring(l,e.length))}}}(),CKEDITOR.htmlParser.basicWriter=CKEDITOR.tools.createClass({$:function(){this._={output:[]}},proto:{openTag:function(b){this._.output.push("\x3c",
b)},openTagClose:function(b,g){g?this._.output.push(" /\x3e"):this._.output.push("\x3e")},attribute:function(b,g){"string"==typeof g&&(g=CKEDITOR.tools.htmlEncodeAttr(g));this._.output.push(" ",b,'\x3d"',g,'"')},closeTag:function(b){this._.output.push("\x3c/",b,"\x3e")},text:function(b){this._.output.push(b)},comment:function(b){this._.output.push("\x3c!--",b,"--\x3e")},write:function(b){this._.output.push(b)},reset:function(){this._.output=[];this._.indent=!1},getHtml:function(b){var g=this._.output.join("");
b&&this.reset();return g}}}),"use strict",function(){CKEDITOR.htmlParser.node=function(){};CKEDITOR.htmlParser.node.prototype={remove:function(){var b=this.parent.children,g=CKEDITOR.tools.indexOf(b,this),e=this.previous,a=this.next;e&&(e.next=a);a&&(a.previous=e);b.splice(g,1);this.parent=null},replaceWith:function(b){var g=this.parent.children,e=CKEDITOR.tools.indexOf(g,this),a=b.previous=this.previous,h=b.next=this.next;a&&(a.next=b);h&&(h.previous=b);g[e]=b;b.parent=this.parent;this.parent=null},
insertAfter:function(b){var g=b.parent.children,e=CKEDITOR.tools.indexOf(g,b),a=b.next;g.splice(e+1,0,this);this.next=b.next;this.previous=b;b.next=this;a&&(a.previous=this);this.parent=b.parent},insertBefore:function(b){var g=b.parent.children,e=CKEDITOR.tools.indexOf(g,b);g.splice(e,0,this);this.next=b;(this.previous=b.previous)&&(b.previous.next=this);b.previous=this;this.parent=b.parent},getAscendant:function(b){var g="function"==typeof b?b:"string"==typeof b?function(a){return a.name==b}:function(a){return a.name in
b},e=this.parent;for(;e&&e.type==CKEDITOR.NODE_ELEMENT;){if(g(e))return e;e=e.parent}return null},wrapWith:function(b){this.replaceWith(b);b.add(this);return b},getIndex:function(){return CKEDITOR.tools.indexOf(this.parent.children,this)},getFilterContext:function(b){return b||{}}}}(),"use strict",CKEDITOR.htmlParser.comment=function(b){this.value=b;this._={isBlockLike:!1}},CKEDITOR.htmlParser.comment.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_COMMENT,filter:function(b,
g){var e=this.value;if(!(e=b.onComment(g,e,this)))return this.remove(),!1;if("string"!=typeof e)return this.replaceWith(e),!1;this.value=e;return!0},writeHtml:function(b,g){g&&this.filter(g);b.comment(this.value)}}),"use strict",function(){CKEDITOR.htmlParser.text=function(b){this.value=b;this._={isBlockLike:!1}};CKEDITOR.htmlParser.text.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_TEXT,filter:function(b,g){if(!(this.value=b.onText(g,this.value,this)))return this.remove(),
!1},writeHtml:function(b,g){g&&this.filter(g);b.text(this.value)}})}(),"use strict",function(){CKEDITOR.htmlParser.cdata=function(b){this.value=b};CKEDITOR.htmlParser.cdata.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_TEXT,filter:function(){},writeHtml:function(b){b.write(this.value)}})}(),"use strict",CKEDITOR.htmlParser.fragment=function(){this.children=[];this.parent=null;this._={isBlockLike:!0,hasInlineStarted:!1}},function(){function b(a){return a.attributes["data-cke-survive"]?
!1:"a"==a.name&&a.attributes.href||CKEDITOR.dtd.$removeEmpty[a.name]}var g=CKEDITOR.tools.extend({table:1,ul:1,ol:1,dl:1},CKEDITOR.dtd.table,CKEDITOR.dtd.ul,CKEDITOR.dtd.ol,CKEDITOR.dtd.dl),e={ol:1,ul:1},a=CKEDITOR.tools.extend({},{html:1},CKEDITOR.dtd.html,CKEDITOR.dtd.body,CKEDITOR.dtd.head,{style:1,script:1}),h={ul:"li",ol:"li",dl:"dd",table:"tbody",tbody:"tr",thead:"tr",tfoot:"tr",tr:"td"};CKEDITOR.htmlParser.fragment.fromHtml=function(l,n,k){function d(a){var b;if(0<q.length)for(var d=0;d<q.length;d++){var f=
q[d],e=f.name,h=CKEDITOR.dtd[e],p=v.name&&CKEDITOR.dtd[v.name];p&&!p[e]||a&&h&&!h[a]&&CKEDITOR.dtd[a]?e==v.name&&(m(v,v.parent,1),d--):(b||(c(),b=1),f=f.clone(),f.parent=v,v=f,q.splice(d,1),d--)}}function c(){for(;y.length;)m(y.shift(),v)}function f(a){if(a._.isBlockLike&&"pre"!=a.name&&"textarea"!=a.name){var c=a.children.length,b=a.children[c-1],d;b&&b.type==CKEDITOR.NODE_TEXT&&((d=CKEDITOR.tools.rtrim(b.value))?b.value=d:a.children.length=c-1)}}function m(a,c,d){c=c||v||r;var e=v;void 0===a.previous&&
(t(c,a)&&(v=c,A.onTagOpen(k,{}),a.returnPoint=c=v),f(a),b(a)&&!a.children.length||c.add(a),"pre"==a.name&&(p=!1),"textarea"==a.name&&(z=!1));a.returnPoint?(v=a.returnPoint,delete a.returnPoint):v=d?c:e}function t(a,c){if((a==r||"body"==a.name)&&k&&(!a.name||CKEDITOR.dtd[a.name][k])){var b,d;return(b=c.attributes&&(d=c.attributes["data-cke-real-element-type"])?d:c.name)&&b in CKEDITOR.dtd.$inline&&!(b in CKEDITOR.dtd.head)&&!c.isOrphan||c.type==CKEDITOR.NODE_TEXT}}function x(a,c){return a in CKEDITOR.dtd.$listItem||
a in CKEDITOR.dtd.$tableContent?a==c||"dt"==a&&"dd"==c||"dd"==a&&"dt"==c:!1}var A=new CKEDITOR.htmlParser,r=n instanceof CKEDITOR.htmlParser.element?n:"string"==typeof n?new CKEDITOR.htmlParser.element(n):new CKEDITOR.htmlParser.fragment,q=[],y=[],v=r,z="textarea"==r.name,p="pre"==r.name;A.onTagOpen=function(f,h,k,l){h=new CKEDITOR.htmlParser.element(f,h);h.isUnknown&&k&&(h.isEmpty=!0);h.isOptionalClose=l;if(b(h))q.push(h);else{if("pre"==f)p=!0;else{if("br"==f&&p){v.add(new CKEDITOR.htmlParser.text("\n"));
return}"textarea"==f&&(z=!0)}if("br"==f)y.push(h);else{for(;!(l=(k=v.name)?CKEDITOR.dtd[k]||(v._.isBlockLike?CKEDITOR.dtd.div:CKEDITOR.dtd.span):a,h.isUnknown||v.isUnknown||l[f]);)if(v.isOptionalClose)A.onTagClose(k);else if(f in e&&k in e)k=v.children,(k=k[k.length-1])&&"li"==k.name||m(k=new CKEDITOR.htmlParser.element("li"),v),!h.returnPoint&&(h.returnPoint=v),v=k;else if(f in CKEDITOR.dtd.$listItem&&!x(f,k))A.onTagOpen("li"==f?"ul":"dl",{},0,1);else if(k in g&&!x(f,k))!h.returnPoint&&(h.returnPoint=
v),v=v.parent;else if(k in CKEDITOR.dtd.$inline&&q.unshift(v),v.parent)m(v,v.parent,1);else{h.isOrphan=1;break}d(f);c();h.parent=v;h.isEmpty?m(h):v=h}}};A.onTagClose=function(a){for(var b=q.length-1;0<=b;b--)if(a==q[b].name){q.splice(b,1);return}for(var d=[],f=[],e=v;e!=r&&e.name!=a;)e._.isBlockLike||f.unshift(e),d.push(e),e=e.returnPoint||e.parent;if(e!=r){for(b=0;b<d.length;b++){var h=d[b];m(h,h.parent)}v=e;e._.isBlockLike&&c();m(e,e.parent);e==v&&(v=v.parent);q=q.concat(f)}"body"==a&&(k=!1)};A.onText=
function(b){if(!(v._.hasInlineStarted&&!y.length||p||z)&&(b=CKEDITOR.tools.ltrim(b),0===b.length))return;var f=v.name,e=f?CKEDITOR.dtd[f]||(v._.isBlockLike?CKEDITOR.dtd.div:CKEDITOR.dtd.span):a;if(!z&&!e["#"]&&f in g)A.onTagOpen(h[f]||""),A.onText(b);else{c();d();p||z||(b=b.replace(/[\t\r\n ]{2,}|[\t\r\n]/g," "));b=new CKEDITOR.htmlParser.text(b);if(t(v,b))this.onTagOpen(k,{},0,1);v.add(b)}};A.onCDATA=function(a){v.add(new CKEDITOR.htmlParser.cdata(a))};A.onComment=function(a){c();d();v.add(new CKEDITOR.htmlParser.comment(a))};
A.parse(l);for(c();v!=r;)m(v,v.parent,1);f(r);return r};CKEDITOR.htmlParser.fragment.prototype={type:CKEDITOR.NODE_DOCUMENT_FRAGMENT,add:function(a,b){isNaN(b)&&(b=this.children.length);var e=0<b?this.children[b-1]:null;if(e){if(a._.isBlockLike&&e.type==CKEDITOR.NODE_TEXT&&(e.value=CKEDITOR.tools.rtrim(e.value),0===e.value.length)){this.children.pop();this.add(a);return}e.next=a}a.previous=e;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,e){if(this.childrenFilteredBy!=a.id){e=this.getFilterContext(e);if(b&&!this.parent)a.onRoot(e,this);this.childrenFilteredBy=a.id;for(b=0;b<this.children.length;b++)!1===this.children[b].filter(a,e)&&b--}},writeHtml:function(a,b){b&&this.filter(b);this.writeChildrenHtml(a)},writeChildrenHtml:function(a,b,e){var d=this.getFilterContext();
if(e&&!this.parent&&b)b.onRoot(d,this);b&&this.filterChildren(b,!1,d);b=0;e=this.children;for(d=e.length;b<d;b++)e[b].writeHtml(a)},forEach:function(a,b,e){if(!(e||b&&this.type!=b))var d=a(this);if(!1!==d){e=this.children;for(var c=0;c<e.length;c++)d=e[c],d.type==CKEDITOR.NODE_ELEMENT?d.forEach(a,b):b&&d.type!=b||a(d)}},getFilterContext:function(a){return a||{}}}}(),"use strict",function(){function b(){this.rules=[]}function g(e,a,h,g){var n,k;for(n in a)(k=e[n])||(k=e[n]=new b),k.add(a[n],h,g)}CKEDITOR.htmlParser.filter=
CKEDITOR.tools.createClass({$:function(e){this.id=CKEDITOR.tools.getNextNumber();this.elementNameRules=new b;this.attributeNameRules=new b;this.elementsRules={};this.attributesRules={};this.textRules=new b;this.commentRules=new b;this.rootRules=new b;e&&this.addRules(e,10)},proto:{addRules:function(b,a){var h;"number"==typeof a?h=a:a&&"priority"in a&&(h=a.priority);"number"!=typeof h&&(h=10);"object"!=typeof a&&(a={});b.elementNames&&this.elementNameRules.addMany(b.elementNames,h,a);b.attributeNames&&
this.attributeNameRules.addMany(b.attributeNames,h,a);b.elements&&g(this.elementsRules,b.elements,h,a);b.attributes&&g(this.attributesRules,b.attributes,h,a);b.text&&this.textRules.add(b.text,h,a);b.comment&&this.commentRules.add(b.comment,h,a);b.root&&this.rootRules.add(b.root,h,a)},applyTo:function(b){b.filter(this)},onElementName:function(b,a){return this.elementNameRules.execOnName(b,a)},onAttributeName:function(b,a){return this.attributeNameRules.execOnName(b,a)},onText:function(b,a,h){return this.textRules.exec(b,
a,h)},onComment:function(b,a,h){return this.commentRules.exec(b,a,h)},onRoot:function(b,a){return this.rootRules.exec(b,a)},onElement:function(b,a){for(var h=[this.elementsRules["^"],this.elementsRules[a.name],this.elementsRules.$],g,n=0;3>n;n++)if(g=h[n]){g=g.exec(b,a,this);if(!1===g)return null;if(g&&g!=a)return this.onNode(b,g);if(a.parent&&!a.name)break}return a},onNode:function(b,a){var h=a.type;return h==CKEDITOR.NODE_ELEMENT?this.onElement(b,a):h==CKEDITOR.NODE_TEXT?new CKEDITOR.htmlParser.text(this.onText(b,
a.value)):h==CKEDITOR.NODE_COMMENT?new CKEDITOR.htmlParser.comment(this.onComment(b,a.value)):null},onAttribute:function(b,a,h,g){return(h=this.attributesRules[h])?h.exec(b,g,a,this):g}}});CKEDITOR.htmlParser.filterRulesGroup=b;b.prototype={add:function(b,a,h){this.rules.splice(this.findIndex(a),0,{value:b,priority:a,options:h})},addMany:function(b,a,h){for(var g=[this.findIndex(a),0],n=0,k=b.length;n<k;n++)g.push({value:b[n],priority:a,options:h});this.rules.splice.apply(this.rules,g)},findIndex:function(b){for(var a=
this.rules,h=a.length-1;0<=h&&b<a[h].priority;)h--;return h+1},exec:function(b,a){var h=a instanceof CKEDITOR.htmlParser.node||a instanceof CKEDITOR.htmlParser.fragment,g=Array.prototype.slice.call(arguments,1),n=this.rules,k=n.length,d,c,f,m;for(m=0;m<k;m++)if(h&&(d=a.type,c=a.name),f=n[m],!(b.nonEditable&&!f.options.applyToAll||b.nestedEditable&&f.options.excludeNestedEditable)){f=f.value.apply(null,g);if(!1===f||h&&f&&(f.name!=c||f.type!=d))return f;null!=f&&(g[0]=a=f)}return a},execOnName:function(b,
a){for(var h=0,g=this.rules,n=g.length,k;a&&h<n;h++)k=g[h],b.nonEditable&&!k.options.applyToAll||b.nestedEditable&&k.options.excludeNestedEditable||(a=a.replace(k.value[0],k.value[1]));return a}}}(),function(){function b(b,c){function d(a){return a||CKEDITOR.env.needsNbspFiller?new CKEDITOR.htmlParser.text(" "):new CKEDITOR.htmlParser.element("br",{"data-cke-bogus":1})}function f(b,c){return function(f){if(f.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT){var h=[],p=e(f),g,E;if(p)for(m(p,1)&&h.push(p);p;)l(p)&&
(g=a(p))&&m(g)&&((E=a(g))&&!l(E)?h.push(g):(d(k).insertAfter(g),g.remove())),p=p.previous;for(p=0;p<h.length;p++)h[p].remove();if(h=!b||!1!==("function"==typeof c?c(f):c))k||CKEDITOR.env.needsBrFiller||f.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT?k||CKEDITOR.env.needsBrFiller||!(7<document.documentMode||f.name in CKEDITOR.dtd.tr||f.name in CKEDITOR.dtd.$listItem)?(h=e(f),h=!h||"form"==f.name&&"input"==h.name):h=!1:h=!1;h&&f.add(d(b))}}}function m(a,b){if((!k||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(q))&&(c.index&&((new CKEDITOR.htmlParser.text(a.value.substring(0,c.index))).insertBefore(a),a.value=c[0]),!CKEDITOR.env.needsBrFiller&&k&&(!b||a.parent.name in E)||!k&&((c=a.previous)&&"br"==c.name||!c||l(c)))?!0:!1}var g={elements:{}},k="html"==c,E=CKEDITOR.tools.extend({},p),u;for(u in E)"#"in v[u]||delete E[u];for(u in E)g.elements[u]=f(k,b.config.fillEmptyBlocks);g.root=f(k,!1);g.elements.br=
function(b){return function(c){if(c.parent.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT){var f=c.attributes;if("data-cke-bogus"in f||"data-cke-eol"in f)delete f["data-cke-bogus"];else{for(f=c.next;f&&h(f);)f=f.next;var e=a(c);!f&&l(c.parent)?n(c.parent,d(b)):l(f)&&e&&!l(e)&&d(b).insertBefore(f)}}}}(k);return g}function g(a,b){return a!=CKEDITOR.ENTER_BR&&!1!==b?a==CKEDITOR.ENTER_DIV?"div":"p":!1}function e(a){for(a=a.children[a.children.length-1];a&&h(a);)a=a.previous;return a}function a(a){for(a=a.previous;a&&
h(a);)a=a.previous;return a}function h(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 p||a.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT)}function n(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 k(a){a=a.attributes;"false"!=a.contenteditable&&(a["data-cke-editable"]=a.contenteditable?"true":1);
a.contenteditable="false"}function d(a){a=a.attributes;switch(a["data-cke-editable"]){case "true":a.contenteditable="true";break;case "1":delete a.contenteditable}}function c(a){return a.replace(D,function(a,b,c){return"\x3c"+b+c.replace(F,function(a,b){return G.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+x(c).replace(/</g,"\x26lt;").replace(/>/g,
"\x26gt;")+"\x3c/textarea\x3e");return"\x3ccke:encoded\x3e"+encodeURIComponent(a)+"\x3c/cke:encoded\x3e"})}function m(a){return a.replace(P,function(a,b){return decodeURIComponent(b)})}function t(a){return a.replace(/\x3c!--(?!{cke_protected})[\s\S]+?--\x3e/g,function(a){return"\x3c!--"+y+"{C}"+encodeURIComponent(a).replace(/--/g,"%2D%2D")+"--\x3e"})}function x(a){return a.replace(/\x3c!--\{cke_protected\}\{C\}([\s\S]+?)--\x3e/g,function(a,b){return decodeURIComponent(b)})}function A(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 r(a,b){var c=[],d=b.config.protectedSource,f=b._.dataStore||(b._.dataStore={id:1}),e=/<\!--\{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(e,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(e,function(a,b,d){return"\x3c!--"+y+(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"+A(x(f),b)+"\x3c/"+c+"\x3e"})}CKEDITOR.htmlDataProcessor=function(a){var d,e,h=this;this.editor=a;this.dataFilter=d=new CKEDITOR.htmlParser.filter;this.htmlFilter=e=new CKEDITOR.htmlParser.filter;this.writer=new CKEDITOR.htmlParser.basicWriter;d.addRules(u);d.addRules(B,{applyToAll:!0});d.addRules(b(a,"data"),{applyToAll:!0});
e.addRules(w);e.addRules(C,{applyToAll:!0});e.addRules(b(a,"html"),{applyToAll:!0});a.on("toHtml",function(b){b=b.data;var d=b.dataValue,e,d=r(d,a),d=f(d,I),d=c(d),d=f(d,L),d=d.replace(H,"$1cke:$2"),d=d.replace(S,"\x3ccke:$1$2\x3e\x3c/cke:$1\x3e"),d=d.replace(/(<pre\b[^>]*>)(\r\n|\n)/g,"$1$2$2"),d=d.replace(/([^a-z0-9<\-])(on\w{3,})(?!>)/gi,"$1data-cke-"+CKEDITOR.rnd+"-$2");e=b.context||a.editable().getName();var h;CKEDITOR.env.ie&&9>CKEDITOR.env.version&&"pre"==e&&(e="div",d="\x3cpre\x3e"+d+"\x3c/pre\x3e",
h=1);e=a.document.createElement(e);e.setHtml("a"+d);d=e.getHtml().substr(1);d=d.replace(new RegExp("data-cke-"+CKEDITOR.rnd+"-","ig"),"");h&&(d=d.replace(/^<pre>|<\/pre>$/gi,""));d=d.replace(E,"$1$2");d=m(d);d=x(d);e=!1===b.fixForBody?!1:g(b.enterMode,a.config.autoParagraph);d=CKEDITOR.htmlParser.fragment.fromHtml(d,b.context,e);e&&(h=d,!h.children.length&&CKEDITOR.dtd[h.name][e]&&(e=new CKEDITOR.htmlParser.element(e),h.add(e)));b.dataValue=d},null,null,5);a.on("toHtml",function(b){b.data.filter.applyTo(b.data.dataValue,
!0,b.data.dontFilter,b.data.enterMode)&&a.fire("dataFiltered")},null,null,6);a.on("toHtml",function(a){a.data.dataValue.filterChildren(h.dataFilter,!0)},null,null,10);a.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=t(b)},null,null,15);a.on("toDataFormat",function(b){var c=b.data.dataValue;b.data.enterMode!=CKEDITOR.ENTER_BR&&(c=c.replace(/^<br *\/?>/i,""));b.data.dataValue=CKEDITOR.htmlParser.fragment.fromHtml(c,
b.data.context,g(b.data.enterMode,a.config.autoParagraph))},null,null,5);a.on("toDataFormat",function(a){a.data.dataValue.filterChildren(h.htmlFilter,!0)},null,null,10);a.on("toDataFormat",function(a){a.data.filter.applyTo(a.data.dataValue,!1,!0)},null,null,11);a.on("toDataFormat",function(b){var c=b.data.dataValue,d=h.writer;d.reset();c.writeChildrenHtml(d);c=d.getHtml(!0);c=x(c);c=A(c,a);b.data.dataValue=c},null,null,15)};CKEDITOR.htmlDataProcessor.prototype={toHtml:function(a,b,c,d){var f=this.editor,
e,h,p,g;b&&"object"==typeof b?(e=b.context,c=b.fixForBody,d=b.dontFilter,h=b.filter,p=b.enterMode,g=b.protectedWhitespaces):e=b;e||null===e||(e=f.editable().getName());return f.fire("toHtml",{dataValue:a,context:e,fixForBody:c,dontFilter:d,filter:h||f.filter,enterMode:p||f.enterMode,protectedWhitespaces:g}).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 q=/(?:&nbsp;|\xa0)$/,y="{cke_protected}",v=CKEDITOR.dtd,z="caption colgroup col thead tfoot tbody".split(" "),p=CKEDITOR.tools.extend({},v.$blockLimit,v.$block),u={elements:{input:k,textarea:k}},B={attributeNames:[[/^on/,"data-cke-pa-on"],[/^data-cke-expando$/,""]]},w={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}}},C={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(z,a.name),d=CKEDITOR.tools.indexOf(z,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&&n(a,b=new CKEDITOR.htmlParser.text);b.value=a.attributes["data-cke-title"]||""},input:d,textarea:d},attributes:{"class":function(a){return CKEDITOR.tools.ltrim(a.replace(/(?:^|\s+)cke_[^\s]*/g,""))||!1}}};CKEDITOR.env.ie&&(C.attributes.style=function(a){return a.replace(/(^|;)([^\:]+)/g,function(a){return a.toLowerCase()})});
var D=/<(a|area|img|input|source)\b([^>]*)>/gi,F=/([\w-:]+)\s*=\s*(?:(?:"[^"]*")|(?:'[^']*')|(?:[^ "'>]+))/gi,G=/^(href|src|name)$/i,L=/(?:<style(?=[ >])[^>]*>[\s\S]*?<\/style>)|(?:<(:?link|meta|base)[^>]*>)/gi,I=/(<textarea(?=[ >])[^>]*>)([\s\S]*?)(?:<\/textarea>)/gi,P=/<cke:encoded>([^<]*)<\/cke:encoded>/gi,H=/(<\/?)((?:object|embed|param|html|body|head|title)[^>]*>)/gi,E=/(<\/?)cke:((?:html|body|head|title)[^>]*>)/gi,S=/<cke:(param|embed)([^>]*?)\/?>(?!\s*<\/cke:\1)/gi}(),"use strict",CKEDITOR.htmlParser.element=
function(b,g){this.name=b;this.attributes=g||{};this.children=[];var e=b||"",a=e.match(/^cke:(.*)/);a&&(e=a[1]);e=!!(CKEDITOR.dtd.$nonBodyContent[e]||CKEDITOR.dtd.$block[e]||CKEDITOR.dtd.$listItem[e]||CKEDITOR.dtd.$tableContent[e]||CKEDITOR.dtd.$nonEditable[e]||"br"==e);this.isEmpty=!!CKEDITOR.dtd.$empty[b];this.isUnknown=!CKEDITOR.dtd[b];this._={isBlockLike:e,hasInlineStarted:this.isEmpty||!e}},CKEDITOR.htmlParser.cssStyle=function(b){var g={};((b instanceof CKEDITOR.htmlParser.element?b.attributes.style:
b)||"").replace(/&quot;/g,'"').replace(/\s*([^ :;]+)\s*:\s*([^;]+)\s*(?=;|$)/g,function(b,a,h){"font-family"==a&&(h=h.replace(/["']/g,""));g[a.toLowerCase()]=h});return{rules:g,populate:function(b){var a=this.toString();a&&(b instanceof CKEDITOR.dom.element?b.setAttribute("style",a):b instanceof CKEDITOR.htmlParser.element?b.attributes.style=a:b.style=a)},toString:function(){var b=[],a;for(a in g)g[a]&&b.push(a,":",g[a],";");return b.join("")}}},function(){function b(a){return function(b){return b.type==
CKEDITOR.NODE_ELEMENT&&("string"==typeof a?b.name==a:b.name in a)}}var g=function(a,b){a=a[0];b=b[0];return a<b?-1:a>b?1:0},e=CKEDITOR.htmlParser.fragment.prototype;CKEDITOR.htmlParser.element.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_ELEMENT,add:e.add,clone:function(){return new CKEDITOR.htmlParser.element(this.name,this.attributes)},filter:function(a,b){var e=this,g,k;b=e.getFilterContext(b);if(b.off)return!0;if(!e.parent)a.onRoot(b,e);for(;;){g=e.name;if(!(k=
a.onElementName(b,g)))return this.remove(),!1;e.name=k;if(!(e=a.onElement(b,e)))return this.remove(),!1;if(e!==this)return this.replaceWith(e),!1;if(e.name==g)break;if(e.type!=CKEDITOR.NODE_ELEMENT)return this.replaceWith(e),!1;if(!e.name)return this.replaceWithChildren(),!1}g=e.attributes;var d,c;for(d in g){for(k=g[d];;)if(c=a.onAttributeName(b,d))if(c!=d)delete g[d],d=c;else break;else{delete g[d];break}c&&(!1===(k=a.onAttribute(b,e,c,k))?delete g[c]:g[c]=k)}e.isEmpty||this.filterChildren(a,!1,
b);return!0},filterChildren:e.filterChildren,writeHtml:function(a,b){b&&this.filter(b);var e=this.name,n=[],k=this.attributes,d,c;a.openTag(e,k);for(d in k)n.push([d,k[d]]);a.sortAttributes&&n.sort(g);d=0;for(c=n.length;d<c;d++)k=n[d],a.attribute(k[0],k[1]);a.openTagClose(e,this.isEmpty);this.writeChildrenHtml(a);this.isEmpty||a.closeTag(e)},writeChildrenHtml:e.writeChildrenHtml,replaceWithChildren:function(){for(var a=this.children,b=a.length;b;)a[--b].insertAfter(this);this.remove()},forEach:e.forEach,
getFirst:function(a){if(!a)return this.children.length?this.children[0]:null;"function"!=typeof a&&(a=b(a));for(var e=0,g=this.children.length;e<g;++e)if(a(this.children[e]))return this.children[e];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(),g=0;g<b.length;++g)b[g].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=[],g;for(g=0;g<this.children.length;g++){var k=this.children[g];"function"==typeof a&&a(k)?e.push(k):"string"==typeof a&&k.name===a&&e.push(k);b&&k.find&&(e=e.concat(k.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 b={},g=/{([^}]+)}/g,e=/([\\'])/g,a=/\n/g,h=/\r/g;CKEDITOR.template=function(l){if(b[l])this.output=
b[l];else{var n=l.replace(e,"\\$1").replace(a,"\\n").replace(h,"\\r").replace(g,function(a,b){return"',data['"+b+"']\x3d\x3dundefined?'{"+b+"}':data['"+b+"'],'"});this.output=b[l]=Function("data","buffer","return buffer?buffer.push('"+n+"'):['"+n+"'].join('');")}}}(),delete CKEDITOR.loadFullCore,CKEDITOR.instances={},CKEDITOR.document=new CKEDITOR.dom.document(document),CKEDITOR.add=function(b){CKEDITOR.instances[b.name]=b;b.on("focus",function(){CKEDITOR.currentInstance!=b&&(CKEDITOR.currentInstance=
b,CKEDITOR.fire("currentInstance"))});b.on("blur",function(){CKEDITOR.currentInstance==b&&(CKEDITOR.currentInstance=null,CKEDITOR.fire("currentInstance"))});CKEDITOR.fire("instance",null,b)},CKEDITOR.remove=function(b){delete CKEDITOR.instances[b.name]},function(){var b={};CKEDITOR.addTemplate=function(g,e){var a=b[g];if(a)return a;a={name:g,source:e};CKEDITOR.fire("template",a);return b[g]=new CKEDITOR.template(a.source)};CKEDITOR.getTemplate=function(g){return b[g]}}(),function(){var b=[];CKEDITOR.addCss=
function(g){b.push(g)};CKEDITOR.getCss=function(){return b.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(b,g){if(!CKEDITOR.env.isCompatible)return null;b=CKEDITOR.dom.element.get(b);if(b.getEditor())throw'The editor instance "'+b.getEditor().name+'" is already attached to the provided element.';var e=new CKEDITOR.editor(g,
b,CKEDITOR.ELEMENT_MODE_INLINE),a=b.is("textarea")?b:null;a?(e.setData(a.getValue(),null,!0),b=CKEDITOR.dom.element.createFromHtml('\x3cdiv contenteditable\x3d"'+!!e.readOnly+'" class\x3d"cke_textarea_inline"\x3e'+a.getValue()+"\x3c/div\x3e",CKEDITOR.document),b.insertAfter(a),a.hide(),a.$.form&&e._attachToForm()):e.setData(b.getHtml(),null,!0);e.on("loaded",function(){e.fire("uiReady");e.editable(b);e.container=b;e.ui.contentsElement=b;e.setData(e.getData(1));e.resetDirty();e.fire("contentDom");
e.mode="wysiwyg";e.fire("mode");e.status="ready";e.fireOnce("instanceReady");CKEDITOR.fire("instanceReady",null,e)},null,null,1E4);e.on("destroy",function(){a&&(e.container.clearCustomData(),e.container.remove(),a.show());e.element.clearCustomData();delete e.element});return e};CKEDITOR.inlineAll=function(){var b,g,e;for(e in CKEDITOR.dtd.$editable)for(var a=CKEDITOR.document.getElementsByTag(e),h=0,l=a.count();h<l;h++)b=a.getItem(h),"true"==b.getAttribute("contenteditable")&&(g={element:b,config:{}},
!1!==CKEDITOR.fire("inline",g)&&CKEDITOR.inline(b,g.config))};CKEDITOR.domReady(function(){!CKEDITOR.disableAutoInline&&CKEDITOR.inlineAll()})}(),CKEDITOR.replaceClass="ckeditor",function(){function b(a,b,l,n){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 k=new CKEDITOR.editor(b,a,n);n==CKEDITOR.ELEMENT_MODE_REPLACE&&(a.setStyle("visibility","hidden"),k._.required=
a.hasAttribute("required"),a.removeAttribute("required"));l&&k.setData(l,null,!0);k.on("loaded",function(){e(k);n==CKEDITOR.ELEMENT_MODE_REPLACE&&k.config.autoUpdateElement&&a.$.form&&k._attachToForm();k.setMode(k.config.startupMode,function(){k.resetDirty();k.status="ready";k.fireOnce("instanceReady");CKEDITOR.fire("instanceReady",null,k)})});k.on("destroy",g);return k}function g(){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 e(a){var b=a.name,e=a.element,g=a.elementMode,k=a.fire("uiSpace",{space:"top",html:""}).html,d=a.fire("uiSpace",{space:"bottom",html:""}).html,c=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(c.output({id:a.id,name:b,langDir:a.lang.dir,langCode:a.langCode,voiceLabel:a.title,topHtml:k?'\x3cspan id\x3d"'+
a.ui.spaceId("top")+'" class\x3d"cke_top cke_reset_all" role\x3d"presentation" style\x3d"height:auto"\x3e'+k+"\x3c/span\x3e":"",contentId:a.ui.spaceId("contents"),bottomHtml:d?'\x3cspan id\x3d"'+a.ui.spaceId("bottom")+'" class\x3d"cke_bottom cke_reset_all" role\x3d"presentation"\x3e'+d+"\x3c/span\x3e":"",outerEl:CKEDITOR.env.ie?"span":"div"}));g==CKEDITOR.ELEMENT_MODE_REPLACE?(e.hide(),b.insertAfter(e)):e.append(b);a.container=b;a.ui.contentsElement=a.ui.space("contents");k&&a.ui.space("top").unselectable();
d&&a.ui.space("bottom").unselectable();e=a.config.width;g=a.config.height;e&&b.setStyle("width",CKEDITOR.tools.cssLength(e));g&&a.ui.space("contents").setStyle("height",CKEDITOR.tools.cssLength(g));b.disableContextMenu();CKEDITOR.env.webkit&&b.on("focus",function(){a.focus()});a.fireOnce("uiReady")}CKEDITOR.replace=function(a,e){return b(a,e,null,CKEDITOR.ELEMENT_MODE_REPLACE)};CKEDITOR.appendTo=function(a,e,g){return b(a,e,g,CKEDITOR.ELEMENT_MODE_APPENDTO)};CKEDITOR.replaceAll=function(){for(var a=
document.getElementsByTagName("textarea"),b=0;b<a.length;b++){var e=null,g=a[b];if(g.name||g.id){if("string"==typeof arguments[0]){if(!(new RegExp("(?:^|\\s)"+arguments[0]+"(?:$|\\s)")).test(g.className))continue}else if("function"==typeof arguments[0]&&(e={},!1===arguments[0](g,e)))continue;this.replace(g,e)}}};CKEDITOR.editor.prototype.addMode=function(a,b){(this._.modes||(this._.modes={}))[a]=b};CKEDITOR.editor.prototype.setMode=function(a,b){var e=this,g=this._.modes;if(a!=e.mode&&g&&g[a]){e.fire("beforeSetMode",
a);if(e.mode){var k=e.checkDirty(),g=e._.previousModeData,d,c=0;e.fire("beforeModeUnload");e.editable(0);e._.previousMode=e.mode;e._.previousModeData=d=e.getData(1);"source"==e.mode&&g==d&&(e.fire("lockSnapshot",{forceUpdate:!0}),c=1);e.ui.space("contents").setHtml("");e.mode=""}else e._.previousModeData=e.getData(1);this._.modes[a](function(){e.mode=a;void 0!==k&&!k&&e.resetDirty();c?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,g){var k=this.container,d=this.ui.space("contents"),c=CKEDITOR.env.webkit&&this.document&&this.document.getWindow().$.frameElement;g=g?this.container.getFirst(function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasClass("cke_inner")}):k;g.setSize("width",a,!0);c&&(c.style.width="1%");var f=(g.$.offsetHeight||0)-(d.$.clientHeight||0),k=Math.max(b-(e?0:f),0);b=e?b+f:b;d.setStyle("height",k+"px");c&&(c.style.width="100%");this.fire("resize",{outerHeight:b,
contentsHeight:k,outerWidth:a||g.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 b(b){var c=b.editor,d=b.data.path,f=d.blockLimit,e=b.data.selection,h=e.getRanges()[0],m;if(CKEDITOR.env.gecko||CKEDITOR.env.ie&&CKEDITOR.env.needsBrFiller)if(e=g(e,d))e.appendBogus(),m=CKEDITOR.env.ie;
n(c,d.block,f)&&h.collapsed&&!h.getCommonAncestor().isReadOnly()&&(d=h.clone(),d.enlarge(CKEDITOR.ENLARGE_BLOCK_CONTENTS),f=new CKEDITOR.dom.walker(d),f.guard=function(b){return!a(b)||b.type==CKEDITOR.NODE_COMMENT||b.isReadOnly()},!f.checkForward()||d.checkStartOfBlock()&&d.checkEndOfBlock())&&(c=h.fixBlock(!0,c.activeEnterMode==CKEDITOR.ENTER_DIV?"div":"p"),CKEDITOR.env.needsBrFiller||(c=c.getFirst(a))&&c.type==CKEDITOR.NODE_TEXT&&CKEDITOR.tools.trim(c.getText()).match(/^(?:&nbsp;|\xa0)$/)&&c.remove(),
m=1,b.cancel());m&&h.select()}function g(b,c){if(b.isFake)return 0;var d=c.block||c.blockLimit,f=d&&d.getLast(a);if(!(!d||!d.isBlockBoundary()||f&&f.type==CKEDITOR.NODE_ELEMENT&&f.isBlockBoundary()||d.is("pre")||d.getBogus()))return d}function e(a){var b=a.data.getTarget();b.is("input")&&(b=b.getAttribute("type"),"submit"!=b&&"reset"!=b||a.data.preventDefault())}function a(a){return f(a)&&m(a)}function h(a,b){return function(c){var d=c.data.$.toElement||c.data.$.fromElement||c.data.$.relatedTarget;
(d=d&&d.nodeType==CKEDITOR.NODE_ELEMENT?new CKEDITOR.dom.element(d):null)&&(b.equals(d)||b.contains(d))||a.call(this,c)}}function l(b){function c(b){return function(c,f){f&&c.type==CKEDITOR.NODE_ELEMENT&&c.is(e)&&(d=c);if(!(f||!a(c)||b&&x(c)))return!1}}var d,f=b.getRanges()[0];b=b.root;var e={table:1,ul:1,ol:1,dl:1};if(f.startPath().contains(e)){var g=f.clone();g.collapse(1);g.setStartAt(b,CKEDITOR.POSITION_AFTER_START);b=new CKEDITOR.dom.walker(g);b.guard=c();b.checkBackward();if(d)return g=f.clone(),
g.collapse(),g.setEndAt(d,CKEDITOR.POSITION_AFTER_END),b=new CKEDITOR.dom.walker(g),b.guard=c(!0),d=!1,b.checkForward(),d}return null}function n(a,b,c){return!1!==a.config.autoParagraph&&a.activeEnterMode!=CKEDITOR.ENTER_BR&&(a.editable().equals(c)&&!b||b&&"true"==b.getAttribute("contenteditable"))}function k(a){return a.activeEnterMode!=CKEDITOR.ENTER_BR&&!1!==a.config.autoParagraph?a.activeEnterMode==CKEDITOR.ENTER_DIV?"div":"p":!1}function d(a){var b=a.editor;b.getSelection().scrollIntoView();
setTimeout(function(){b.fire("saveSnapshot")},0)}function c(a,b,c){var d=a.getCommonAncestor(b);for(b=a=c?b:a;(a=a.getParent())&&!d.equals(a)&&1==a.getChildCount();)b=a;b.remove()}var f,m,t,x,A,r,q,y,v,z;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{!CKEDITOR.env.ie||CKEDITOR.env.edge&&14<CKEDITOR.env.version||!this.getDocument().equals(CKEDITOR.document)?this.$.focus():this.$.setActive()}catch(b){if(!CKEDITOR.env.ie)throw b;}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=h(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,c){var f=this.editor;f.focus();f.fire("saveSnapshot");c||(c=f.getSelection().getRanges()[0]);r(this,b||"html",a,c);c.select();d(this);this.editor.fire("afterInsertHtml",{})},insertHtmlIntoRange:function(a,b,c){r(this,c||"html",a,b);this.editor.fire("afterInsertHtml",
{intoRange:b})},insertElement:function(b,c){var f=this.editor;f.focus();f.fire("saveSnapshot");var e=f.activeEnterMode,f=f.getSelection(),g=b.getName(),g=CKEDITOR.dtd.$block[g];c||(c=f.getRanges()[0]);this.insertElementIntoRange(b,c)&&(c.moveToPosition(b,CKEDITOR.POSITION_AFTER_END),g&&((g=b.getNext(function(b){return a(b)&&!x(b)}))&&g.type==CKEDITOR.NODE_ELEMENT&&g.is(CKEDITOR.dtd.$block)?g.getDtd()["#"]?c.moveToElementEditStart(g):c.moveToElementEditEnd(b):g||e==CKEDITOR.ENTER_BR||(g=c.fixBlock(!0,
e==CKEDITOR.ENTER_DIV?"div":"p"),c.moveToElementEditStart(g))));f.selectRanges([c]);d(this)},insertElementIntoSelection:function(a){this.insertElement(a)},insertElementIntoRange:function(a,b){var c=this.editor,d=c.config.enterMode,f=a.getName(),e=CKEDITOR.dtd.$block[f];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})?q(b):b.startContainer.is(CKEDITOR.dtd.$list)&&y(b));var g,h;if(e)for(;(g=b.getCommonAncestor(0,
1))&&(h=CKEDITOR.dtd[g.getName()])&&(!h||!h[f]);)g.getName()in CKEDITOR.dtd.span?b.splitElement(g):b.checkStartOfBlock()&&b.checkEndOfBlock()?(b.setStartBefore(g),b.collapse(!0),g.remove()):b.splitBlock(d==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().$,d=b.getSelection(),f;a:if(d.anchorNode&&d.anchorNode==c.$)f=!0;else{if(CKEDITOR.env.webkit&&(f=
c.getDocument().getActive())&&f.equals(c)&&!d.anchorNode){f=!0;break a}f=void 0}f&&(f=new CKEDITOR.dom.range(c),f.moveToElementEditStart(c),b=b.createRange(),b.setStart(f.startContainer.$,f.startOffset),b.collapse(!0),d.removeAllRanges(),d.addRange(b))}function b(){var a=c.getDocument().$,d=a.selection,f=c.getDocument().getActive();"None"==d.type&&f.equals(c)&&(d=new CKEDITOR.dom.range(c),a=a.body.createTextRange(),d.moveToElementEditStart(c),d=d.startContainer,d.type!=CKEDITOR.NODE_ELEMENT&&(d=d.getParent()),
a.moveToElementText(d.$),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()};v.eol.detect(a,this);v.bogus.exclude(a);v.cell.shrink(a);a.fragment=a.range.cloneContents();v.tree.rebuild(a,
this);v.eol.fix(a,this);return new CKEDITOR.dom.documentFragment(a.fragment.$)},extractHtmlFromRange:function(a,b){var c=z,d={range:a,doc:a.document},f=this.getHtmlFromRange(a);if(a.collapsed)return a.optimize(),f;a.enlarge(CKEDITOR.ENLARGE_INLINE,1);c.table.detectPurge(d);d.bookmark=a.createBookmark();delete d.range;var e=this.editor.createRange();e.moveToPosition(d.bookmark.startNode,CKEDITOR.POSITION_BEFORE_START);d.targetBookmark=e.createBookmark();c.list.detectMerge(d,this);c.table.detectRanges(d,
this);c.block.detectMerge(d,this);d.tableContentsRanges?(c.table.deleteRanges(d),a.moveToBookmark(d.bookmark),d.range=a):(a.moveToBookmark(d.bookmark),d.range=a,a.extractContents(c.detectExtractMerge(d)));a.moveToBookmark(d.targetBookmark);a.optimize();c.fixUneditableRangePosition(a);c.list.merge(d,this);c.table.purge(d,this);c.block.merge(d,this);if(b){c=a.startPath();if(d=a.checkStartOfBlock()&&a.checkEndOfBlock()&&c.block&&!a.root.equals(c.block)){a:{var d=c.block.getElementsByTag("span"),e=0,
g;if(d)for(;g=d.getItem(e++);)if(!m(g)){d=!0;break a}d=!1}d=!d}d&&(a.moveToPosition(c.block,CKEDITOR.POSITION_BEFORE_START),c.block.remove())}else c.autoParagraph(this.editor,a),t(a.startContainer)&&a.startContainer.appendBogus();a.startContainer.mergeSiblings();return f},setup:function(){var b=this.editor;this.attachListener(b,"beforeGetData",function(){var a=this.getData();this.is("textarea")||!1!==b.config.ignoreEmptyParagraph&&(a=a.replace(A,function(a,b){return b}));b.setData(a,null,1)},this);
this.attachListener(b,"getSnapshot",function(a){a.data=this.getData(1)},this);this.attachListener(b,"afterSetData",function(){this.setData(b.getData(1))},this);this.attachListener(b,"loadSnapshot",function(a){this.setData(a.data,1)},this);this.attachListener(b,"beforeFocus",function(){var a=b.getSelection();(a=a&&a.getNative())&&"Control"==a.type||this.focus()},this);this.attachListener(b,"insertHtml",function(a){this.insertHtml(a.data.dataValue,a.data.mode,a.data.range)},this);this.attachListener(b,
"insertElement",function(a){this.insertElement(a.data)},this);this.attachListener(b,"insertText",function(a){this.insertText(a.data)},this);this.setReadOnly(b.readOnly);this.attachClass("cke_editable");b.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?this.attachClass("cke_editable_inline"):b.elementMode!=CKEDITOR.ELEMENT_MODE_REPLACE&&b.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO||this.attachClass("cke_editable_themed");this.attachClass("cke_contents_"+b.config.contentsLangDirection);b.keystrokeHandler.blockedKeystrokes[8]=
+b.readOnly;b.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(){b._.previousScrollTop=b.editable().$.scrollTop},null,null,-1);if(CKEDITOR.env.edge&&14<CKEDITOR.env.version){var d=function(){var a=b.editable();null!=b._.previousScrollTop&&a.getDocument().equals(CKEDITOR.document)&&(a.$.scrollTop=b._.previousScrollTop,b._.previousScrollTop=null,this.removeListener("scroll",
d))};this.on("scroll",d)}b.focusManager.add(this);this.equals(CKEDITOR.document.getActive())&&(this.hasFocus=!0,b.once("contentDom",function(){b.focusManager.focus(this)},this));this.isInline()&&this.changeAttr("tabindex",b.tabIndex);if(!this.is("textarea")){b.document=this.getDocument();b.window=this.getWindow();var g=b.document;this.changeAttr("spellcheck",!b.config.disableNativeSpellChecker);var h=b.config.contentsLangDirection;this.getDirection(1)!=h&&this.changeAttr("dir",h);var m=CKEDITOR.getCss();
if(m){var h=g.getHead(),k=h.getCustomData("stylesheet");k?m!=k.getText()&&(CKEDITOR.env.ie&&9>CKEDITOR.env.version?k.$.styleSheet.cssText=m:k.setText(m)):(m=g.appendStyleText(m),m=new CKEDITOR.dom.element(m.ownerNode||m.owningElement),h.setCustomData("stylesheet",m),m.data("cke-temp",1))}h=g.getCustomData("stylesheet_ref")||0;g.setCustomData("stylesheet_ref",h+1);this.setCustomData("cke_includeReadonly",!b.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(b,"key",function(a){if(b.readOnly)return!0;var c=a.data.domEvent.getKey(),d;if(c in n){a=b.getSelection();var e,g=a.getRanges()[0],h=g.startPath(),m,k,u,c=8==c;CKEDITOR.env.ie&&11>CKEDITOR.env.version&&(e=a.getSelectedElement())||(e=l(a))?(b.fire("saveSnapshot"),g.moveToPosition(e,CKEDITOR.POSITION_BEFORE_START),e.remove(),g.select(),b.fire("saveSnapshot"),
d=1):g.collapsed&&((m=h.block)&&(u=m[c?"getPrevious":"getNext"](f))&&u.type==CKEDITOR.NODE_ELEMENT&&u.is("table")&&g[c?"checkStartOfBlock":"checkEndOfBlock"]()?(b.fire("saveSnapshot"),g[c?"checkEndOfBlock":"checkStartOfBlock"]()&&m.remove(),g["moveToElementEdit"+(c?"End":"Start")](u),g.select(),b.fire("saveSnapshot"),d=1):h.blockLimit&&h.blockLimit.is("td")&&(k=h.blockLimit.getAscendant("table"))&&g.checkBoundaryOfElement(k,c?CKEDITOR.START:CKEDITOR.END)&&(u=k[c?"getPrevious":"getNext"](f))?(b.fire("saveSnapshot"),
g["moveToElementEdit"+(c?"End":"Start")](u),g.checkStartOfBlock()&&g.checkEndOfBlock()?u.remove():g.select(),b.fire("saveSnapshot"),d=1):(k=h.contains(["td","th","caption"]))&&g.checkBoundaryOfElement(k,c?CKEDITOR.START:CKEDITOR.END)&&(d=1))}return!d});b.blockless&&CKEDITOR.env.ie&&CKEDITOR.env.needsBrFiller&&this.attachListener(this,"keyup",function(c){c.data.getKeystroke()in n&&!this.getFirst(a)&&(this.appendBogus(),c=b.createRange(),c.moveToPosition(this,CKEDITOR.POSITION_AFTER_START),c.select())});
this.attachListener(this,"dblclick",function(a){if(b.readOnly)return!1;a={element:a.data.getTarget()};b.fire("doubleclick",a)});CKEDITOR.env.ie&&this.attachListener(this,"click",e);CKEDITOR.env.ie&&!CKEDITOR.env.edge||this.attachListener(this,"mousedown",function(a){var c=a.data.getTarget();c.is("img","hr","input","textarea","select")&&!c.isReadOnly()&&(b.getSelection().selectElement(c),c.is("input","textarea","select")&&a.data.preventDefault())});CKEDITOR.env.edge&&this.attachListener(this,"mouseup",
function(a){(a=a.data.getTarget())&&a.is("img")&&b.getSelection().selectElement(a)});CKEDITOR.env.gecko&&this.attachListener(this,"mouseup",function(a){if(2==a.data.$.button&&(a=a.data.getTarget(),!a.getOuterHtml().replace(A,""))){var c=b.createRange();c.moveToElementEditStart(a);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(b,"key",function(a){if(b.readOnly)return!0;a=a.data.domEvent.getKey();if(a in n){var d=8==a,f=b.getSelection().getRanges()[0];a=f.startPath();if(f.collapsed)a:{var e=a.block;if(e&&f[d?"checkStartOfBlock":"checkEndOfBlock"]()&&f.moveToClosestEditablePosition(e,!d)&&f.collapsed){if(f.startContainer.type==CKEDITOR.NODE_ELEMENT){var g=f.startContainer.getChild(f.startOffset-(d?1:0));if(g&&g.type==CKEDITOR.NODE_ELEMENT&&g.is("hr")){b.fire("saveSnapshot");
g.remove();a=!0;break a}}f=f.startPath().block;if(!f||f&&f.contains(e))a=void 0;else{b.fire("saveSnapshot");var h;(h=(d?f:e).getBogus())&&h.remove();h=b.getSelection();g=h.createBookmarks();(d?e:f).moveChildren(d?f:e,!1);a.lastElement.mergeSiblings();c(e,f,!d);h.selectBookmarks(g);a=!0}}else a=!1}else d=f,h=a.block,f=d.endPath().block,h&&f&&!h.equals(f)?(b.fire("saveSnapshot"),(e=h.getBogus())&&e.remove(),d.enlarge(CKEDITOR.ENLARGE_INLINE),d.deleteContents(),f.getParent()&&(f.moveChildren(h,!1),a.lastElement.mergeSiblings(),
c(h,f,!0)),d=b.getSelection().getRanges()[0],d.collapse(1),d.optimize(),""===d.startContainer.getHtml()&&d.startContainer.appendBogus(),d.select(),a=!0):a=!1;if(!a)return;b.getSelection().scrollIntoView();b.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(a){var c=a.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(a){if(!c.readOnly){var d=c.getSelection();d&&!d.isLocked&&(d=c.checkDirty(),c.fire("lockSnapshot"),b(a),c.fire("unlockSnapshot"),!d&&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 d=b.fire("ariaEditorHelpLabel",{}).label;if(d&&(c=this.ui.space(this.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?"top":"contents"))){var f=CKEDITOR.tools.getNextId(),d=CKEDITOR.dom.element.createFromHtml('\x3cspan id\x3d"'+f+'" class\x3d"cke_voice_label"\x3e'+d+"\x3c/span\x3e");c.append(d);a.changeAttr("aria-describedby",
f)}}})});CKEDITOR.addCss(".cke_editable{cursor:text}.cke_editable img,.cke_editable input,.cke_editable textarea{cursor:default}");f=CKEDITOR.dom.walker.whitespaces(!0);m=CKEDITOR.dom.walker.bookmark(!1,!0);t=CKEDITOR.dom.walker.empty();x=CKEDITOR.dom.walker.bogus();A=/(^|<body\b[^>]*>)\s*<(p|div|address|h\d|center|pre)[^>]*>\s*(?:<br[^>]*>|&nbsp;|\u00A0|&#160;)?\s*(:?<\/\2>)?\s*(?=$|<\/body>)/gi;r=function(){function b(a){return a.type==CKEDITOR.NODE_ELEMENT}function c(a,d){var f,e,g,h,k=[],n=d.range.startContainer;
f=d.range.startPath();for(var n=m[n.getName()],B=0,w=a.getChildren(),l=w.count(),J=-1,r=-1,A=0,t=f.contains(m.$list);B<l;++B)f=w.getItem(B),b(f)?(g=f.getName(),t&&g in CKEDITOR.dtd.$list?k=k.concat(c(f,d)):(h=!!n[g],"br"!=g||!f.data("cke-eol")||B&&B!=l-1||(A=(e=B?k[B-1].node:w.getItem(B+1))&&(!b(e)||!e.is("br")),e=e&&b(e)&&m.$block[e.getName()]),-1!=J||h||(J=B),h||(r=B),k.push({isElement:1,isLineBreak:A,isBlock:f.isBlockBoundary(),hasBlockSibling:e,node:f,name:g,allowed:h}),e=A=0)):k.push({isElement:0,
node:f,allowed:1});-1<J&&(k[J].firstNotAllowed=1);-1<r&&(k[r].lastNotAllowed=1);return k}function d(a,c){var f=[],e=a.getChildren(),g=e.count(),h,k=0,u=m[c],n=!a.is(m.$inline)||a.is("br");for(n&&f.push(" ");k<g;k++)h=e.getItem(k),b(h)&&!h.is(u)?f=f.concat(d(h,c)):f.push(h);n&&f.push(" ");return f}function f(a){return b(a.startContainer)&&a.startContainer.getChild(a.startOffset-1)}function e(a){return a&&b(a)&&(a.is(m.$removeEmpty)||a.is("a")&&!a.isBlockBoundary())}function g(a,c,d,f){var e=a.clone(),
h,m;e.setEndAt(c,CKEDITOR.POSITION_BEFORE_END);(h=(new CKEDITOR.dom.walker(e)).next())&&b(h)&&l[h.getName()]&&(m=h.getPrevious())&&b(m)&&!m.getParent().equals(a.startContainer)&&d.contains(m)&&f.contains(h)&&h.isIdentical(m)&&(h.moveChildren(m),h.remove(),g(a,c,d,f))}function h(a,c){function d(a,c){if(c.isBlock&&c.isElement&&!c.node.is("br")&&b(a)&&a.is("br"))return a.remove(),1}var f=c.endContainer.getChild(c.endOffset),e=c.endContainer.getChild(c.endOffset-1);f&&d(f,a[a.length-1]);e&&d(e,a[0])&&
(c.setEnd(c.endContainer,c.endOffset-1),c.collapse())}var m=CKEDITOR.dtd,l={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},A=CKEDITOR.tools.extend({},m.$inline);delete A.br;return function(H,E,l,t){var q=H.editor,y=!1;"unfiltered_html"==E&&(E="html",y=!0);if(!t.checkReadOnly()){var x=(new CKEDITOR.dom.elementPath(t.startContainer,t.root)).blockLimit||t.root;H={type:E,dontFilter:y,editable:H,editor:q,range:t,blockLimit:x,
mergeCandidates:[],zombies:[]};E=H.range;t=H.mergeCandidates;var v,z;"text"==H.type&&E.shrink(CKEDITOR.SHRINK_ELEMENT,!0,!1)&&(v=CKEDITOR.dom.element.createFromHtml("\x3cspan\x3e\x26nbsp;\x3c/span\x3e",E.document),E.insertNode(v),E.setStartAfter(v));y=new CKEDITOR.dom.elementPath(E.startContainer);H.endPath=x=new CKEDITOR.dom.elementPath(E.endContainer);if(!E.collapsed){var q=x.block||x.blockLimit,L=E.getCommonAncestor();q&&!q.equals(L)&&!q.contains(L)&&E.checkEndOfBlock()&&H.zombies.push(q);E.deleteContents()}for(;(z=
f(E))&&b(z)&&z.isBlockBoundary()&&y.contains(z);)E.moveToPosition(z,CKEDITOR.POSITION_BEFORE_END);g(E,H.blockLimit,y,x);v&&(E.setEndBefore(v),E.collapse(),v.remove());v=E.startPath();if(q=v.contains(e,!1,1))E.splitElement(q),H.inlineStylesRoot=q,H.inlineStylesPeak=v.lastElement;v=E.createBookmark();(q=v.startNode.getPrevious(a))&&b(q)&&e(q)&&t.push(q);(q=v.startNode.getNext(a))&&b(q)&&e(q)&&t.push(q);for(q=v.startNode;(q=q.getParent())&&e(q);)t.push(q);E.moveToBookmark(v);if(v=l){v=H.range;if("text"==
H.type&&H.inlineStylesRoot){z=H.inlineStylesPeak;E=z.getDocument().createText("{cke-peak}");for(t=H.inlineStylesRoot.getParent();!z.equals(t);)E=E.appendTo(z.clone()),z=z.getParent();l=E.getOuterHtml().split("{cke-peak}").join(l)}z=H.blockLimit.getName();if(/^\s+|\s+$/.test(l)&&"span"in CKEDITOR.dtd[z]){var N='\x3cspan data-cke-marker\x3d"1"\x3e\x26nbsp;\x3c/span\x3e';l=N+l+N}l=H.editor.dataProcessor.toHtml(l,{context:null,fixForBody:!1,protectedWhitespaces:!!N,dontFilter:H.dontFilter,filter:H.editor.activeFilter,
enterMode:H.editor.activeEnterMode});z=v.document.createElement("body");z.setHtml(l);N&&(z.getFirst().remove(),z.getLast().remove());if((N=v.startPath().block)&&(1!=N.getChildCount()||!N.getBogus()))a:{var J;if(1==z.getChildCount()&&b(J=z.getFirst())&&J.is(r)&&!J.hasAttribute("contenteditable")){N=J.getElementsByTag("*");v=0;for(t=N.count();v<t;v++)if(E=N.getItem(v),!E.is(A))break a;J.moveChildren(J.getParent(1));J.remove()}}H.dataWrapper=z;v=l}if(v){J=H.range;v=J.document;var M;z=H.blockLimit;t=
0;var R,N=[],K,Y;l=q=0;var V,ba;E=J.startContainer;var y=H.endPath.elements[0],ca,x=y.getPosition(E),L=!!y.getCommonAncestor(E)&&x!=CKEDITOR.POSITION_IDENTICAL&&!(x&CKEDITOR.POSITION_CONTAINS+CKEDITOR.POSITION_IS_CONTAINED);E=c(H.dataWrapper,H);for(h(E,J);t<E.length;t++){x=E[t];if(M=x.isLineBreak){M=J;V=z;var X=void 0,da=void 0;x.hasBlockSibling?M=1:(X=M.startContainer.getAscendant(m.$block,1))&&X.is({div:1,p:1})?(da=X.getPosition(V),da==CKEDITOR.POSITION_IDENTICAL||da==CKEDITOR.POSITION_CONTAINS?
M=0:(V=M.splitElement(X),M.moveToPosition(V,CKEDITOR.POSITION_AFTER_START),M=1)):M=0}if(M)l=0<t;else{M=J.startPath();!x.isBlock&&n(H.editor,M.block,M.blockLimit)&&(Y=k(H.editor))&&(Y=v.createElement(Y),Y.appendBogus(),J.insertNode(Y),CKEDITOR.env.needsBrFiller&&(R=Y.getBogus())&&R.remove(),J.moveToPosition(Y,CKEDITOR.POSITION_BEFORE_END));if((M=J.startPath().block)&&!M.equals(K)){if(R=M.getBogus())R.remove(),N.push(M);K=M}x.firstNotAllowed&&(q=1);if(q&&x.isElement){M=J.startContainer;for(V=null;M&&
!m[M.getName()][x.name];){if(M.equals(z)){M=null;break}V=M;M=M.getParent()}if(M)V&&(ba=J.splitElement(V),H.zombies.push(ba),H.zombies.push(V));else{V=z.getName();ca=!t;M=t==E.length-1;V=d(x.node,V);for(var X=[],da=V.length,fa=0,ha=void 0,ia=0,ja=-1;fa<da;fa++)ha=V[fa]," "==ha?(ia||ca&&!fa||(X.push(new CKEDITOR.dom.text(" ")),ja=X.length),ia=1):(X.push(ha),ia=0);M&&ja==X.length&&X.pop();ca=X}}if(ca){for(;M=ca.pop();)J.insertNode(M);ca=0}else J.insertNode(x.node);x.lastNotAllowed&&t<E.length-1&&((ba=
L?y:ba)&&J.setEndAt(ba,CKEDITOR.POSITION_AFTER_START),q=0);J.collapse()}}1!=E.length?R=!1:(R=E[0],R=R.isElement&&"false"==R.node.getAttribute("contenteditable"));R&&(l=!0,M=E[0].node,J.setStartAt(M,CKEDITOR.POSITION_BEFORE_START),J.setEndAt(M,CKEDITOR.POSITION_AFTER_END));H.dontMoveCaret=l;H.bogusNeededBlocks=N}R=H.range;var U;ba=H.bogusNeededBlocks;for(ca=R.createBookmark();K=H.zombies.pop();)K.getParent()&&(Y=R.clone(),Y.moveToElementEditStart(K),Y.removeEmptyBlocksAtEnd());if(ba)for(;K=ba.pop();)CKEDITOR.env.needsBrFiller?
K.appendBogus():K.append(R.document.createText(" "));for(;K=H.mergeCandidates.pop();)K.mergeSiblings();R.moveToBookmark(ca);if(!H.dontMoveCaret){for(K=f(R);K&&b(K)&&!K.is(m.$empty);){if(K.isBlockBoundary())R.moveToPosition(K,CKEDITOR.POSITION_BEFORE_END);else{if(e(K)&&K.getHtml().match(/(\s|&nbsp;)$/g)){U=null;break}U=R.clone();U.moveToPosition(K,CKEDITOR.POSITION_BEFORE_END)}K=K.getLast(a)}U&&R.moveToRange(U)}}}}();q=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,d){c=a.getDocument().createElement(c);a.append(c,d);return c}function c(a){var b=a.count(),d;for(b;0<b--;)d=a.getItem(b),CKEDITOR.tools.trim(d.getHtml())||(d.appendBogus(),CKEDITOR.env.ie&&9>CKEDITOR.env.version&&d.getChildCount()&&d.getFirst().remove())}return function(d){var f=d.startContainer,e=f.getAscendant("table",1),g=!1;c(e.getElementsByTag("td"));
c(e.getElementsByTag("th"));e=d.clone();e.setStart(f,0);e=a(e).lastBackward();e||(e=d.clone(),e.setEndAt(f,CKEDITOR.POSITION_BEFORE_END),e=a(e).lastForward(),g=!0);e||(e=f);e.is("table")?(d.setStartAt(e,CKEDITOR.POSITION_BEFORE_START),d.collapse(!0),e.remove()):(e.is({tbody:1,thead:1,tfoot:1})&&(e=b(e,"tr",g)),e.is("tr")&&(e=b(e,e.getParent().is("thead")?"th":"td",g)),(f=e.getBogus())&&f.remove(),d.moveToPosition(e,g?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_END))}}();y=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,d=!1,f;f=b.clone();f.setStart(c,0);f=a(f).lastBackward();f||(f=b.clone(),f.setEndAt(c,CKEDITOR.POSITION_BEFORE_END),f=a(f).lastForward(),d=!0);f||(f=c);f.is(CKEDITOR.dtd.$list)?(b.setStartAt(f,CKEDITOR.POSITION_BEFORE_START),
b.collapse(!0),f.remove()):((c=f.getBogus())&&c.remove(),b.moveToPosition(f,d?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_END),b.select())}}();v={eol:{detect:function(a,b){var c=a.range,d=c.clone(),f=c.clone(),e=new CKEDITOR.dom.elementPath(c.startContainer,b),g=new CKEDITOR.dom.elementPath(c.endContainer,b);d.collapse(1);f.collapse();e.block&&d.checkBoundaryOfElement(e.block,CKEDITOR.END)&&(c.setStartAfter(e.block),a.prependEolBr=1);g.block&&f.checkBoundaryOfElement(g.block,CKEDITOR.START)&&
(c.setEndBefore(g.block),a.appendEolBr=1)},fix:function(a,b){var c=b.getDocument(),d;a.appendEolBr&&(d=this.createEolBr(c),a.fragment.append(d));!a.prependEolBr||d&&!d.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||!x(b)||c&&c.equals(b)||a.range.setEndBefore(b)}},tree:{rebuild:function(a,b){var c=a.range,d=c.getCommonAncestor(),
f=new CKEDITOR.dom.elementPath(d,b),e=new CKEDITOR.dom.elementPath(c.startContainer,b),c=new CKEDITOR.dom.elementPath(c.endContainer,b),g;d.type==CKEDITOR.NODE_TEXT&&(d=d.getParent());if(f.blockLimit.is({tr:1,table:1})){var h=f.contains("table").getParent();g=function(a){return!a.equals(h)}}else if(f.block&&f.block.is(CKEDITOR.dtd.$listItem)&&(e=e.contains(CKEDITOR.dtd.$list),c=c.contains(CKEDITOR.dtd.$list),!e.equals(c))){var m=f.contains(CKEDITOR.dtd.$list).getParent();g=function(a){return!a.equals(m)}}g||
(g=function(a){return!a.equals(f.block)&&!a.equals(f.blockLimit)});this.rebuildFragment(a,b,d,g)},rebuildFragment:function(a,b,c,d){for(var f;c&&!c.equals(b)&&d(c);)f=c.clone(0,1),a.fragment.appendTo(f),a.fragment=f,c=c.getParent()}},cell:{shrink:function(a){a=a.range;var b=a.startContainer,c=a.endContainer,d=a.startOffset,f=a.endOffset;b.type==CKEDITOR.NODE_ELEMENT&&b.equals(c)&&b.is("tr")&&++d==f&&a.shrink(CKEDITOR.SHRINK_TEXT)}}};z=function(){function a(b,c){var d=b.getParent();if(d.is(CKEDITOR.dtd.$inline))b[c?
"insertBefore":"insertAfter"](d)}function b(c,d,f){a(d);a(f,1);for(var e;e=f.getNext();)e.insertAfter(d),d=e;t(c)&&c.remove()}function c(a,b){var d=new CKEDITOR.dom.range(a);d.setStartAfter(b.startNode);d.setEndBefore(b.endNode);return d}return{list:{detectMerge:function(a,b){var d=c(b,a.bookmark),f=d.startPath(),e=d.endPath(),g=f.contains(CKEDITOR.dtd.$list),h=e.contains(CKEDITOR.dtd.$list);a.mergeList=g&&h&&g.getParent().equals(h.getParent())&&!g.equals(h);a.mergeListItems=f.block&&e.block&&f.block.is(CKEDITOR.dtd.$listItem)&&
e.block.is(CKEDITOR.dtd.$listItem);if(a.mergeList||a.mergeListItems)d=d.clone(),d.setStartBefore(a.bookmark.startNode),d.setEndAfter(a.bookmark.endNode),a.mergeListBookmark=d.createBookmark()},merge:function(a,c){if(a.mergeListBookmark){var d=a.mergeListBookmark.startNode,f=a.mergeListBookmark.endNode,e=new CKEDITOR.dom.elementPath(d,c),g=new CKEDITOR.dom.elementPath(f,c);if(a.mergeList){var h=e.contains(CKEDITOR.dtd.$list),m=g.contains(CKEDITOR.dtd.$list);h.equals(m)||(m.moveChildren(h),m.remove())}a.mergeListItems&&
(e=e.contains(CKEDITOR.dtd.$listItem),g=g.contains(CKEDITOR.dtd.$listItem),e.equals(g)||b(g,d,f));d.remove();f.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 d=a.mergeBlockBookmark.startNode,f=a.mergeBlockBookmark.endNode,e=new CKEDITOR.dom.elementPath(d,
c),g=new CKEDITOR.dom.elementPath(f,c),e=e.block,g=g.block;e&&g&&!e.equals(g)&&b(g,d,f);d.remove();f.remove()}}},table:function(){function a(c){var f=[],e,g=new CKEDITOR.dom.walker(c),h=c.startPath().contains(d),m=c.endPath().contains(d),k={};g.guard=function(a,g){if(a.type==CKEDITOR.NODE_ELEMENT){var p="visited_"+(g?"out":"in");if(a.getCustomData(p))return;CKEDITOR.dom.element.setMarker(k,a,p,1)}if(g&&h&&a.equals(h))e=c.clone(),e.setEndAt(h,CKEDITOR.POSITION_BEFORE_END),f.push(e);else if(!g&&m&&
a.equals(m))e=c.clone(),e.setStartAt(m,CKEDITOR.POSITION_AFTER_START),f.push(e);else{if(p=!g)p=a.type==CKEDITOR.NODE_ELEMENT&&a.is(d)&&(!h||b(a,h))&&(!m||b(a,m));p&&(e=c.clone(),e.selectNodeContents(a),f.push(e))}};g.lastForward();CKEDITOR.dom.element.clearAllMarkers(k);return f}function b(a,c){var d=CKEDITOR.POSITION_CONTAINS+CKEDITOR.POSITION_IS_CONTAINED,f=a.getPosition(c);return f===CKEDITOR.POSITION_IDENTICAL?!1:0===(f&d)}var d={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),f=0;c.evaluator=function(a){a.type==CKEDITOR.NODE_ELEMENT&&a.is(d)&&++f};c.checkForward();if(1<f){var c=b.startPath().contains("table"),e=b.endPath().contains("table");c&&e&&b.checkBoundaryOfElement(c,CKEDITOR.START)&&b.checkBoundaryOfElement(e,CKEDITOR.END)&&(b=a.range.clone(),b.setStartBefore(c),b.setEndAfter(e),a.purgeTableBookmark=b.createBookmark())}},detectRanges:function(f,e){var g=c(e,f.bookmark),h=g.clone(),
m,k,p=g.getCommonAncestor();p.is(CKEDITOR.dtd.$tableContent)&&!p.is(d)&&(p=p.getAscendant("table",!0));k=p;p=new CKEDITOR.dom.elementPath(g.startContainer,k);k=new CKEDITOR.dom.elementPath(g.endContainer,k);p=p.contains("table");k=k.contains("table");if(p||k)p&&k&&b(p,k)?(f.tableSurroundingRange=h,h.setStartAt(p,CKEDITOR.POSITION_AFTER_END),h.setEndAt(k,CKEDITOR.POSITION_BEFORE_START),h=g.clone(),h.setEndAt(p,CKEDITOR.POSITION_AFTER_END),m=g.clone(),m.setStartAt(k,CKEDITOR.POSITION_BEFORE_START),
m=a(h).concat(a(m))):p?k||(f.tableSurroundingRange=h,h.setStartAt(p,CKEDITOR.POSITION_AFTER_END),g.setEndAt(p,CKEDITOR.POSITION_AFTER_END)):(f.tableSurroundingRange=h,h.setEndAt(k,CKEDITOR.POSITION_BEFORE_START),g.setStartAt(k,CKEDITOR.POSITION_AFTER_START)),f.tableContentsRanges=m?m:a(g)},deleteRanges:function(a){for(var b;b=a.tableContentsRanges.pop();)b.extractContents(),t(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(),d;n(a,c.block,c.blockLimit)&&(d=k(a))&&(d=b.document.createElement(d),d.appendBogus(),b.insertNode(d),b.moveToPosition(d,CKEDITOR.POSITION_AFTER_START))}}}()}(),function(){function b(){var a=this._.fakeSelection,b;a&&(b=this.getSelection(1),b&&b.isHidden()||(a.reset(),a=0));if(!a&&(a=b||this.getSelection(1),!a||a.getType()==CKEDITOR.SELECTION_NONE))return;this.fire("selectionCheck",a);b=this.elementPath();if(!b.compare(this._.selectionPreviousPath)){var c=this._.selectionPreviousPath&&
this._.selectionPreviousPath.blockLimit.equals(b.blockLimit);CKEDITOR.env.webkit&&!c&&(this._.previousActive=this.document.getActive());this._.selectionPreviousPath=b;this.fire("selectionChange",{selection:a,path:b})}}function g(){q=!0;r||(e.call(this),r=CKEDITOR.tools.setTimeout(e,200,this))}function e(){r=null;q&&(CKEDITOR.tools.setTimeout(b,0,this),q=!1)}function a(a){return y(a)||a.type==CKEDITOR.NODE_ELEMENT&&!a.is(CKEDITOR.dtd.$empty)?!0:!1}function h(b){function c(a,d){return a&&a.type!=CKEDITOR.NODE_TEXT?
b.clone()["moveToElementEdit"+(d?"End":"Start")](a):!1}if(!(b.root instanceof CKEDITOR.editable))return!1;var d=b.startContainer,f=b.getPreviousNode(a,null,d),e=b.getNextNode(a,null,d);return c(f)||c(e,1)||!(f||e||d.type==CKEDITOR.NODE_ELEMENT&&d.isBlockBoundary()&&d.getBogus())?!0:!1}function l(a){n(a,!1);var b=a.getDocument().createText(x);a.setCustomData("cke-fillingChar",b);return b}function n(a,b){var c=a&&a.removeCustomData("cke-fillingChar");if(c){if(!1!==b){var d=a.getDocument().getSelection().getNative(),
f=d&&"None"!=d.type&&d.getRangeAt(0),e=x.length;if(c.getLength()>e&&f&&f.intersectsNode(c.$)){var g=[{node:d.anchorNode,offset:d.anchorOffset},{node:d.focusNode,offset:d.focusOffset}];d.anchorNode==c.$&&d.anchorOffset>e&&(g[0].offset-=e);d.focusNode==c.$&&d.focusOffset>e&&(g[1].offset-=e)}}c.setText(k(c.getText(),1));g&&(c=a.getDocument().$,d=c.getSelection(),c=c.createRange(),c.setStart(g[0].node,g[0].offset),c.collapse(!0),d.removeAllRanges(),d.addRange(c),d.extend(g[1].node,g[1].offset))}}function k(a,
b){return b?a.replace(A,function(a,b){return b?" ":""}):a.replace(x,"")}function d(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 d=a.getSelection(1),f=a.createRange(),e=d.root.on("selectionchange",function(a){a.cancel()},null,null,0);f.setStartAt(c,
CKEDITOR.POSITION_AFTER_START);f.setEndAt(c,CKEDITOR.POSITION_BEFORE_END);d.selectRanges([f]);e.removeListener();a.fire("unlockSnapshot");a._.hiddenSelectionContainer=c}function c(a){var b={37:1,39:1,8:1,46:1};return function(c){var d=c.data.getKeystroke();if(b[d]){var f=a.getSelection().getRanges(),e=f[0];1==f.length&&e.collapsed&&(d=e[38>d?"getPreviousEditableNode":"getNextEditableNode"]())&&d.type==CKEDITOR.NODE_ELEMENT&&"false"==d.getAttribute("contenteditable")&&(a.getSelection().fake(d),c.data.preventDefault(),
c.cancel())}}}function f(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 d=c.startContainer,f;d&&!((f=d.type==CKEDITOR.NODE_ELEMENT)&&d.is("body")||!d.isReadOnly());)f&&"false"==d.getAttribute("contentEditable")&&c.setStartAfter(d),d=d.getParent();d=c.startContainer;f=c.endContainer;var e=c.startOffset,g=c.endOffset,h=c.clone();d&&d.type==CKEDITOR.NODE_TEXT&&(e>=d.getLength()?h.setStartAfter(d):h.setStartBefore(d));
f&&f.type==CKEDITOR.NODE_TEXT&&(g?h.setEndAfter(f):h.setEndBefore(f));d=new CKEDITOR.dom.walker(h);d.evaluator=function(d){if(d.type==CKEDITOR.NODE_ELEMENT&&d.isReadOnly()){var f=c.clone();c.setEndBefore(d);c.collapsed&&a.splice(b--,1);d.getPosition(h.endContainer)&CKEDITOR.POSITION_CONTAINS||(f.setStartAfter(d),f.collapsed||a.splice(b+1,0,f));return!0}return!1};d.next()}}return a}var m="function"!=typeof window.getSelection,t=1,x=CKEDITOR.tools.repeat("​",7),A=new RegExp(x+"( )?","g"),r,q,y=CKEDITOR.dom.walker.invisible(1),
v=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,d=c.createRange(),f;(f=d.moveToClosestEditablePosition(b.selected,a))||(f=d.moveToClosestEditablePosition(b.selected,!a));f&&c.getSelection().selectRanges([d]);c.fire("saveSnapshot");b.selected.remove();f||(d.moveToElementEditablePosition(c.editable()),c.getSelection().selectRanges([d]));
c.fire("saveSnapshot");return!1}}var c=a(),d=a(1);return{37:c,38:c,39:d,40:d,8:b(),46:b(1)}}();CKEDITOR.on("instanceCreated",function(a){function d(){var a=f.getSelection();a&&a.removeAllRanges()}var f=a.editor;f.on("contentDom",function(){function a(){E=new CKEDITOR.dom.selection(f.getSelection());E.lock()}function d(){h.removeListener("mouseup",d);l.removeListener("mouseup",d);var a=CKEDITOR.document.$.selection,b=a.createRange();"None"!=a.type&&b.parentElement().ownerDocument==e.$&&b.select()}
var e=f.document,h=CKEDITOR.document,k=f.editable(),p=e.getBody(),l=e.getDocumentElement(),r=k.isInline(),H,E;CKEDITOR.env.gecko&&k.attachListener(k,"focus",function(a){a.removeListener();0!==H&&(a=f.getSelection().getNative())&&a.isCollapsed&&a.anchorNode==k.$&&(a=f.createRange(),a.moveToElementEditStart(k),a.select())},null,null,-2);k.attachListener(k,CKEDITOR.env.webkit?"DOMFocusIn":"focus",function(){H&&CKEDITOR.env.webkit&&(H=f._.previousActive&&f._.previousActive.equals(e.getActive()))&&null!=
f._.previousScrollTop&&f._.previousScrollTop!=k.$.scrollTop&&(k.$.scrollTop=f._.previousScrollTop);f.unlockSelection(H);H=0},null,null,-1);k.attachListener(k,"mousedown",function(){H=0});if(CKEDITOR.env.ie||r)m?k.attachListener(k,"beforedeactivate",a,null,null,-1):k.attachListener(f,"selectionCheck",a,null,null,-1),k.attachListener(k,CKEDITOR.env.webkit?"DOMFocusOut":"blur",function(){f.lockSelection(E);H=1},null,null,-1),k.attachListener(k,"mousedown",function(){H=0});if(CKEDITOR.env.ie&&!r){var t;
k.attachListener(k,"mousedown",function(a){2==a.data.$.button&&((a=f.document.getSelection())&&a.getType()!=CKEDITOR.SELECTION_NONE||(t=f.window.getScrollPosition()))});k.attachListener(k,"mouseup",function(a){2==a.data.$.button&&t&&(f.document.$.documentElement.scrollLeft=t.x,f.document.$.documentElement.scrollTop=t.y);t=null});if("BackCompat"!=e.$.compatMode){if(CKEDITOR.env.ie7Compat||CKEDITOR.env.ie6Compat){var q,A;l.on("mousedown",function(a){function b(a){a=a.data.$;if(q){var c=p.$.createTextRange();
try{c.moveToPoint(a.clientX,a.clientY)}catch(d){}q.setEndPoint(0>A.compareEndPoints("StartToStart",c)?"EndToEnd":"StartToStart",c);q.select()}}function c(){l.removeListener("mousemove",b);h.removeListener("mouseup",c);l.removeListener("mouseup",c);q.select()}a=a.data;if(a.getTarget().is("html")&&a.$.y<l.$.clientHeight&&a.$.x<l.$.clientWidth){q=p.$.createTextRange();try{q.moveToPoint(a.$.clientX,a.$.clientY)}catch(d){}A=q.duplicate();l.on("mousemove",b);h.on("mouseup",c);l.on("mouseup",c)}})}if(7<
CKEDITOR.env.version&&11>CKEDITOR.env.version)l.on("mousedown",function(a){a.data.getTarget().is("html")&&(h.on("mouseup",d),l.on("mouseup",d))})}}k.attachListener(k,"selectionchange",b,f);k.attachListener(k,"keyup",g,f);k.attachListener(k,CKEDITOR.env.webkit?"DOMFocusIn":"focus",function(){f.forceNextSelectionCheck();f.selectionChange(1)});if(r&&(CKEDITOR.env.webkit||CKEDITOR.env.gecko)){var u;k.attachListener(k,"mousedown",function(){u=1});k.attachListener(e.getDocumentElement(),"mouseup",function(){u&&
g.call(f);u=0})}else k.attachListener(CKEDITOR.env.ie?k:e.getDocumentElement(),"mouseup",g,f);CKEDITOR.env.webkit&&k.attachListener(e,"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:n(k)}},null,null,-1);k.attachListener(k,"keydown",c(f),null,null,-1)});f.on("setData",function(){f.unlockSelection();CKEDITOR.env.webkit&&d()});f.on("contentDomUnload",function(){f.unlockSelection()});if(CKEDITOR.env.ie9Compat)f.on("beforeDestroy",
d,null,null,9);f.on("dataReady",function(){delete f._.fakeSelection;delete f._.hiddenSelectionContainer;f.selectionChange(1)});f.on("loadSnapshot",function(){var a=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_ELEMENT),b=f.editable().getLast(a);b&&b.hasAttribute("data-cke-hidden-sel")&&(b.remove(),CKEDITOR.env.gecko&&(a=f.editable().getFirst(a))&&a.is("br")&&a.getAttribute("_moz_editor_bogus_node")&&a.remove())},null,null,100);f.on("key",function(a){if("wysiwyg"==f.mode){var b=f.getSelection();if(b.isFake){var c=
v[a.data.keyCode];if(c)return c({editor:f,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):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=k(a.data))},b,null,20);b.on("toDataFormat",
function(a){a.data.dataValue=k(a.data.dataValue)},null,null,0)});CKEDITOR.editor.prototype.selectionChange=function(a){(a?b:g).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 d,f;if(a)if(a.getRangeAt)d=(f=a.rangeCount&&a.getRangeAt(0))&&new CKEDITOR.dom.node(f.commonAncestorContainer);else{try{f=a.createRange()}catch(e){}d=f&&CKEDITOR.dom.element.get(f.item&&f.item(0)||f.parentElement())}if(!d||d.type!=CKEDITOR.NODE_ELEMENT&&d.type!=CKEDITOR.NODE_TEXT||!this.root.equals(d)&&!this.root.contains(d))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 z={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:k,_createFillingCharSequenceNode:l,FILLING_CHAR_SEQUENCE:x});CKEDITOR.dom.selection.prototype={getNative:function(){return void 0!==this._.cache.nativeSel?this._.cache.nativeSel:this._.cache.nativeSel=
m?this.document.$.selection:this.document.getWindow().$.getSelection()},getType:m?function(){var a=this._.cache;if(a.type)return a.type;var b=CKEDITOR.SELECTION_NONE;try{var c=this.getNative(),d=c.type;"Text"==d&&(b=CKEDITOR.SELECTION_TEXT);"Control"==d&&(b=CKEDITOR.SELECTION_ELEMENT);c.createRange().parentElement()&&(b=CKEDITOR.SELECTION_TEXT)}catch(f){}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),d=c.startContainer;d==c.endContainer&&1==d.nodeType&&1==c.endOffset-c.startOffset&&z[d.childNodes[c.startOffset].nodeName.toLowerCase()]&&(b=CKEDITOR.SELECTION_ELEMENT)}return a.type=b},getRanges:function(){var a=m?function(){function a(b){return(new CKEDITOR.dom.node(b)).getIndex()}var b=function(b,c){b=b.duplicate();b.collapse(c);var d=b.parentElement();if(!d.hasChildNodes())return{container:d,offset:0};for(var f=d.children,e,g,h=b.duplicate(),m=0,
k=f.length-1,E=-1,p,n;m<=k;)if(E=Math.floor((m+k)/2),e=f[E],h.moveToElementText(e),p=h.compareEndPoints("StartToStart",b),0<p)k=E-1;else if(0>p)m=E+1;else return{container:d,offset:a(e)};if(-1==E||E==f.length-1&&0>p){h.moveToElementText(d);h.setEndPoint("StartToStart",b);h=h.text.replace(/(\r\n|\r)/g,"\n").length;f=d.childNodes;if(!h)return e=f[f.length-1],e.nodeType!=CKEDITOR.NODE_TEXT?{container:d,offset:f.length}:{container:e,offset:e.nodeValue.length};for(d=f.length;0<h&&0<d;)g=f[--d],g.nodeType==
CKEDITOR.NODE_TEXT&&(n=g,h-=g.nodeValue.length);return{container:n,offset:-h}}h.collapse(0<p?!0:!1);h.setEndPoint(0<p?"StartToStart":"EndToStart",b);h=h.text.replace(/(\r\n|\r)/g,"\n").length;if(!h)return{container:d,offset:a(e)+(0<p?0:1)};for(;0<h;)try{g=e[0<p?"previousSibling":"nextSibling"],g.nodeType==CKEDITOR.NODE_TEXT&&(h-=g.nodeValue.length,n=g),e=g}catch(l){return{container:d,offset:a(e)}}return{container:n,offset:0<p?-h:n.nodeValue.length+h}};return function(){var a=this.getNative(),c=a&&
a.createRange(),d=this.getType();if(!a)return[];if(d==CKEDITOR.SELECTION_TEXT)return a=new CKEDITOR.dom.range(this.root),d=b(c,!0),a.setStart(new CKEDITOR.dom.node(d.container),d.offset),d=b(c),a.setEnd(new CKEDITOR.dom.node(d.container),d.offset),a.endContainer.getPosition(a.startContainer)&CKEDITOR.POSITION_PRECEDING&&a.endOffset<=a.startContainer.getIndex()&&a.collapse(),[a];if(d==CKEDITOR.SELECTION_ELEMENT){for(var d=[],f=0;f<c.length;f++){for(var e=c.item(f),g=e.parentNode,h=0,a=new CKEDITOR.dom.range(this.root);h<
g.childNodes.length&&g.childNodes[h]!=e;h++);a.setStart(new CKEDITOR.dom.node(g),h);a.setEnd(new CKEDITOR.dom.node(g),h+1);d.push(a)}return d}return[]}}():function(){var a=[],b,c=this.getNative();if(!c)return a;for(var d=0;d<c.rangeCount;d++){var f=c.getRangeAt(d);b=new CKEDITOR.dom.range(this.root);b.setStart(new CKEDITOR.dom.node(f.startContainer),f.startOffset);b.setEnd(new CKEDITOR.dom.node(f.endContainer),f.endOffset);a.push(b)}return a};return function(b){var c=this._.cache,d=c.ranges;d||(c.ranges=
d=new CKEDITOR.dom.rangeList(a.call(this)));return b?f(new CKEDITOR.dom.rangeList(d.slice())):d}}(),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,d,f=2;f&&!((c=a.getEnclosedNode())&&c.type==CKEDITOR.NODE_ELEMENT&&z[c.getName()]&&(d=c));f--)a.shrink(CKEDITOR.SHRINK_ELEMENT);return d&&d.$});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=m?"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=!b&&this.getRanges(),d=this.isFake;this.isLocked=0;this.reset();a&&(a=b||c[0]&&c[0].getCommonAncestor())&&a.getAscendant("body",1)&&(d?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,b=b&&b._.hiddenSelectionContainer;this.reset();if(b)for(var b=this.root,c,d=0;d<a.length;++d)c=
a[d],c.endContainer.equals(b)&&(c.endOffset=Math.min(c.endOffset,b.getChildCount()));if(a.length)if(this.isLocked){var f=CKEDITOR.document.getActive();this.unlock();this.selectRanges(a);this.lock();f&&!f.equals(this.root)&&f.focus()}else{var e;a:{var g,k;if(1==a.length&&!(k=a[0]).collapsed&&(e=k.getEnclosedNode())&&e.type==CKEDITOR.NODE_ELEMENT&&(k=k.clone(),k.shrink(CKEDITOR.SHRINK_ELEMENT,!0),(g=k.getEnclosedNode())&&g.type==CKEDITOR.NODE_ELEMENT&&(e=g),"false"==e.getAttribute("contenteditable")))break a;
e=void 0}if(e)this.fake(e);else{if(m){k=CKEDITOR.dom.walker.whitespaces(!0);g=/\ufeff|\u00a0/;b={table:1,tbody:1,tr:1};1<a.length&&(e=a[a.length-1],a[0].setEnd(e.endContainer,e.endOffset));e=a[0];a=e.collapsed;var r,t,q;if((c=e.getEnclosedNode())&&c.type==CKEDITOR.NODE_ELEMENT&&c.getName()in z&&(!c.is("a")||!c.getText()))try{q=c.$.createControlRange();q.addElement(c.$);q.select();return}catch(H){}if(e.startContainer.type==CKEDITOR.NODE_ELEMENT&&e.startContainer.getName()in b||e.endContainer.type==
CKEDITOR.NODE_ELEMENT&&e.endContainer.getName()in b)e.shrink(CKEDITOR.NODE_ELEMENT,!0),a=e.collapsed;q=e.createBookmark();b=q.startNode;a||(f=q.endNode);q=e.document.$.body.createTextRange();q.moveToElementText(b.$);q.moveStart("character",1);f?(g=e.document.$.body.createTextRange(),g.moveToElementText(f.$),q.setEndPoint("EndToEnd",g),q.moveEnd("character",-1)):(r=b.getNext(k),t=b.hasAscendant("pre"),r=!(r&&r.getText&&r.getText().match(g))&&(t||!b.hasPrevious()||b.getPrevious().is&&b.getPrevious().is("br")),
t=e.document.createElement("span"),t.setHtml("\x26#65279;"),t.insertBefore(b),r&&e.document.createText("﻿").insertBefore(b));e.setStartBefore(b);b.remove();a?(r?(q.moveStart("character",-1),q.select(),e.document.$.selection.clear()):q.select(),e.moveToPosition(t,CKEDITOR.POSITION_BEFORE_START),t.remove()):(e.setEndBefore(f),f.remove(),q.select())}else{f=this.getNative();if(!f)return;this.removeAllRanges();for(q=0;q<a.length;q++){if(q<a.length-1&&(r=a[q],t=a[q+1],g=r.clone(),g.setStart(r.endContainer,
r.endOffset),g.setEnd(t.startContainer,t.startOffset),!g.collapsed&&(g.shrink(CKEDITOR.NODE_ELEMENT,!0),e=g.getCommonAncestor(),g=g.getEnclosedNode(),e.isReadOnly()||g&&g.isReadOnly()))){t.setStart(r.startContainer,r.startOffset);a.splice(q--,1);continue}e=a[q];t=this.document.$.createRange();e.collapsed&&CKEDITOR.env.webkit&&h(e)&&(g=l(this.root),e.insertNode(g),(r=g.getNext())&&!g.getPrevious()&&r.type==CKEDITOR.NODE_ELEMENT&&"br"==r.getName()?(n(this.root),e.moveToPosition(r,CKEDITOR.POSITION_BEFORE_START)):
e.moveToPosition(g,CKEDITOR.POSITION_AFTER_END));t.setStart(e.startContainer.$,e.startOffset);try{t.setEnd(e.endContainer.$,e.endOffset)}catch(E){if(0<=E.toString().indexOf("NS_ERROR_ILLEGAL_VALUE"))e.collapse(1),t.setEnd(e.endContainer.$,e.endOffset);else throw E;}f.addRange(t)}}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();d(c,b);var f=this._.cache,e=new CKEDITOR.dom.range(this.root);
e.setStartBefore(a);e.setEndAfter(a);f.ranges=new CKEDITOR.dom.rangeList(e);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"))},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,d=0;d<a.length;d++){var f=new CKEDITOR.dom.range(this.root);f.moveToBookmark(a[d]);b.push(f)}a.isFake&&(c=b[0].getEnclosedNode(),c&&c.type==CKEDITOR.NODE_ELEMENT||(CKEDITOR.warn("selection-not-fake"),a.isFake=0));a.isFake?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[m?"empty":"removeAllRanges"]()}catch(b){}this.reset()}}}}(),"use strict",CKEDITOR.STYLE_BLOCK=1,CKEDITOR.STYLE_INLINE=2,CKEDITOR.STYLE_OBJECT=3,function(){function b(a,b){for(var c,d;(a=a.getParent())&&!a.equals(b);)if(a.getAttribute("data-nostyle"))c=a;else if(!d){var f=a.getAttribute("contentEditable");
"false"==f?c=a:"true"==f&&(d=1)}return c}function g(a,b,c,d){return(a.getPosition(b)|d)==d&&(!c.childRule||c.childRule(a))}function e(a){var c=a.document;if(a.collapsed)c=y(this,c),a.insertNode(c),a.moveToPosition(c,CKEDITOR.POSITION_BEFORE_END);else{var d=this.element,f=this._.definition,m,k=f.ignoreReadonly,n=k||f.includeReadonly;null==n&&(n=a.root.getCustomData("cke_includeReadonly"));var l=CKEDITOR.dtd[d];l||(m=!0,l=CKEDITOR.dtd.span);a.enlarge(CKEDITOR.ENLARGE_INLINE,1);a.trim();var p=a.createBookmark(),
r=p.startNode,J=p.endNode,t=r,q;if(!k){var x=a.getCommonAncestor(),k=b(r,x),x=b(J,x);k&&(t=k.getNextSourceNode(!0));x&&(J=x)}for(t.getPosition(J)==CKEDITOR.POSITION_FOLLOWING&&(t=0);t;){k=!1;if(t.equals(J))t=null,k=!0;else{var v=t.type==CKEDITOR.NODE_ELEMENT?t.getName():null,x=v&&"false"==t.getAttribute("contentEditable"),z=v&&t.getAttribute("data-nostyle");if(v&&t.data("cke-bookmark")){t=t.getNextSourceNode(!0);continue}if(x&&n&&CKEDITOR.dtd.$block[v])for(var u=t,B=h(u),w=void 0,C=B.length,D=0,u=
C&&new CKEDITOR.dom.range(u.getDocument());D<C;++D){var w=B[D],I=CKEDITOR.filter.instances[w.data("cke-filter")];if(I?I.check(this):1)u.selectNodeContents(w),e.call(this,u)}B=v?!l[v]||z?0:x&&!n?0:g(t,J,f,P):1;if(B)if(w=t.getParent(),B=f,C=d,D=m,!w||!(w.getDtd()||CKEDITOR.dtd.span)[C]&&!D||B.parentRule&&!B.parentRule(w))k=!0;else{if(q||v&&CKEDITOR.dtd.$removeEmpty[v]&&(t.getPosition(J)|P)!=P||(q=a.clone(),q.setStartBefore(t)),v=t.type,v==CKEDITOR.NODE_TEXT||x||v==CKEDITOR.NODE_ELEMENT&&!t.getChildCount()){for(var v=
t,F;(k=!v.getNext(L))&&(F=v.getParent(),l[F.getName()])&&g(F,r,f,H);)v=F;q.setEndAfter(v)}}else k=!0;t=t.getNextSourceNode(z||x)}if(k&&q&&!q.collapsed){for(var k=y(this,c),x=k.hasAttributes(),z=q.getCommonAncestor(),v={},B={},w={},C={},G,U,ga;k&&z;){if(z.getName()==d){for(G in f.attributes)!C[G]&&(ga=z.getAttribute(U))&&(k.getAttribute(G)==ga?B[G]=1:C[G]=1);for(U in f.styles)!w[U]&&(ga=z.getStyle(U))&&(k.getStyle(U)==ga?v[U]=1:w[U]=1)}z=z.getParent()}for(G in B)k.removeAttribute(G);for(U in v)k.removeStyle(U);
x&&!k.hasAttributes()&&(k=null);k?(q.extractContents().appendTo(k),q.insertNode(k),A.call(this,k),k.mergeSiblings(),CKEDITOR.env.ie||k.$.normalize()):(k=new CKEDITOR.dom.element("span"),q.extractContents().appendTo(k),q.insertNode(k),A.call(this,k),k.remove(!0));q=null}}a.moveToBookmark(p);a.shrink(CKEDITOR.SHRINK_TEXT);a.shrink(CKEDITOR.NODE_ELEMENT,!0)}}function a(a){function b(){for(var a=new CKEDITOR.dom.elementPath(d.getParent()),c=new CKEDITOR.dom.elementPath(k.getParent()),f=null,e=null,g=
0;g<a.elements.length;g++){var h=a.elements[g];if(h==a.block||h==a.blockLimit)break;n.checkElementRemovable(h,!0)&&(f=h)}for(g=0;g<c.elements.length;g++){h=c.elements[g];if(h==c.block||h==c.blockLimit)break;n.checkElementRemovable(h,!0)&&(e=h)}e&&k.breakParent(e);f&&d.breakParent(f)}a.enlarge(CKEDITOR.ENLARGE_INLINE,1);var c=a.createBookmark(),d=c.startNode;if(a.collapsed){for(var f=new CKEDITOR.dom.elementPath(d.getParent(),a.root),e,g=0,h;g<f.elements.length&&(h=f.elements[g])&&h!=f.block&&h!=f.blockLimit;g++)if(this.checkElementRemovable(h)){var m;
a.collapsed&&(a.checkBoundaryOfElement(h,CKEDITOR.END)||(m=a.checkBoundaryOfElement(h,CKEDITOR.START)))?(e=h,e.match=m?"start":"end"):(h.mergeSiblings(),h.is(this.element)?x.call(this,h):r(h,p(this)[h.getName()]))}if(e){h=d;for(g=0;;g++){m=f.elements[g];if(m.equals(e))break;else if(m.match)continue;else m=m.clone();m.append(h);h=m}h["start"==e.match?"insertBefore":"insertAfter"](e)}}else{var k=c.endNode,n=this;b();for(f=d;!f.equals(k);)e=f.getNextSourceNode(),f.type==CKEDITOR.NODE_ELEMENT&&this.checkElementRemovable(f)&&
(f.getName()==this.element?x.call(this,f):r(f,p(this)[f.getName()]),e.type==CKEDITOR.NODE_ELEMENT&&e.contains(d)&&(b(),e=d.getNext())),f=e}a.moveToBookmark(c);a.shrink(CKEDITOR.NODE_ELEMENT,!0)}function h(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()&&v(a,this)}
function n(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 d in c)a.removeAttribute(d,c[d]);if(b.styles)for(var f in b.styles)b.styles.hasOwnProperty(f)&&a.removeStyle(f)}}function k(a){var b=a.createBookmark(!0),d=a.createIterator();d.enforceRealBlocks=!0;this._.enterMode&&(d.enlargeBr=this._.enterMode!=CKEDITOR.ENTER_BR);for(var f,e=a.document,g;f=d.getNextParagraph();)!f.isReadOnly()&&
(d.activeFilter?d.activeFilter.check(this):1)&&(g=y(this,e,f),c(f,g));a.moveToBookmark(b)}function d(a){var b=a.createBookmark(1),d=a.createIterator();d.enforceRealBlocks=!0;d.enlargeBr=this._.enterMode!=CKEDITOR.ENTER_BR;for(var f,e;f=d.getNextParagraph();)this.checkElementRemovable(f)&&(f.is("pre")?((e=this._.enterMode==CKEDITOR.ENTER_BR?null:a.document.createElement(this._.enterMode==CKEDITOR.ENTER_P?"p":"div"))&&f.copyAttributes(e),c(f,e)):x.call(this,f));a.moveToBookmark(b)}function c(a,b){var c=
!b;c&&(b=a.getDocument().createElement("div"),a.copyAttributes(b));var d=b&&b.is("pre"),e=a.is("pre"),g=!d&&e;if(d&&!e){e=b;(g=a.getBogus())&&g.remove();g=a.getHtml();g=m(g,/(?:^[ \t\n\r]+)|(?:[ \t\n\r]+$)/g,"");g=g.replace(/[ \t\r\n]*(<br[^>]*>)[ \t\r\n]*/gi,"$1");g=g.replace(/([ \t\n\r]+|&nbsp;)/g," ");g=g.replace(/<br\b[^>]*>/gi,"\n");if(CKEDITOR.env.ie){var h=a.getDocument().createElement("div");h.append(e);e.$.outerHTML="\x3cpre\x3e"+g+"\x3c/pre\x3e";e.copyAttributes(h.getFirst());e=h.getFirst().remove()}else e.setHtml(g);
b=e}else g?b=t(c?[a.getHtml()]:f(a),b):a.moveChildren(b);b.replace(a);if(d){var c=b,k;(k=c.getPrevious(I))&&k.type==CKEDITOR.NODE_ELEMENT&&k.is("pre")&&(d=m(k.getHtml(),/\n$/,"")+"\n\n"+m(c.getHtml(),/^\n/,""),CKEDITOR.env.ie?c.$.outerHTML="\x3cpre\x3e"+d+"\x3c/pre\x3e":c.setHtml(d),k.remove())}else c&&q(b)}function f(a){var b=[];m(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 m(a,b,c){var d="",f="";a=a.replace(/(^<span[^>]+data-cke-bookmark.*?\/span>)|(<span[^>]+data-cke-bookmark.*?\/span>$)/gi,function(a,b,c){b&&(d=b);c&&(f=c);return""});return d+a.replace(b,c)+f}function t(a,b){var c;1<a.length&&(c=new CKEDITOR.dom.documentFragment(b.getDocument()));for(var d=0;d<a.length;d++){var f=a[d],f=f.replace(/(\r\n|\r)/g,"\n"),f=m(f,/^[ \t]*\n/,""),f=m(f,/\n$/,""),f=m(f,/^[ \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)+" "}),f=f.replace(/\n/g,"\x3cbr\x3e"),f=f.replace(/[ \t]{2,}/g,function(a){return CKEDITOR.tools.repeat("\x26nbsp;",a.length-1)+" "});if(c){var e=b.clone();e.setHtml(f);c.append(e)}else b.setHtml(f)}return c||b}function x(a,b){var c=this._.definition,d=c.attributes,c=c.styles,f=p(this)[a.getName()],e=CKEDITOR.tools.isEmpty(d)&&CKEDITOR.tools.isEmpty(c),g;for(g in d)if("class"!=g&&!this._.definition.fullMatch||
a.getAttribute(g)==u(g,d[g]))b&&"data-"==g.slice(0,5)||(e=a.hasAttribute(g),a.removeAttribute(g));for(var h in c)this._.definition.fullMatch&&a.getStyle(h)!=u(h,c[h],!0)||(e=e||!!a.getStyle(h),a.removeStyle(h));r(a,f,C[a.getName()]);e&&(this._.definition.alwaysRemoveElement?q(a,1):!CKEDITOR.dtd.$block[a.getName()]||this._.enterMode==CKEDITOR.ENTER_BR&&!a.hasAttributes()?q(a):a.renameNode(this._.enterMode==CKEDITOR.ENTER_P?"p":"div"))}function A(a){for(var b=p(this),c=a.getElementsByTag(this.element),
d,f=c.count();0<=--f;)d=c.getItem(f),d.isReadOnly()||x.call(this,d,!0);for(var e in b)if(e!=this.element)for(c=a.getElementsByTag(e),f=c.count()-1;0<=f;f--)d=c.getItem(f),d.isReadOnly()||r(d,b[e])}function r(a,b,c){if(b=b&&b.attributes)for(var d=0;d<b.length;d++){var f=b[d][0],e;if(e=a.getAttribute(f)){var g=b[d][1];(null===g||g.test&&g.test(e)||"string"==typeof g&&e==g)&&a.removeAttribute(f)}}c||q(a)}function q(a,b){if(!a.hasAttributes()||b)if(CKEDITOR.dtd.$block[a.getName()]){var c=a.getPrevious(I),
d=a.getNext(I);!c||c.type!=CKEDITOR.NODE_TEXT&&c.isBlockBoundary({br:1})||a.append("br",1);!d||d.type!=CKEDITOR.NODE_TEXT&&d.isBlockBoundary({br:1})||a.append("br");a.remove(!0)}else c=a.getFirst(),d=a.getLast(),a.remove(!0),c&&(c.type==CKEDITOR.NODE_ELEMENT&&c.mergeSiblings(),d&&!c.equals(d)&&d.type==CKEDITOR.NODE_ELEMENT&&d.mergeSiblings())}function y(a,b,c){var d;d=a.element;"*"==d&&(d="span");d=new CKEDITOR.dom.element(d,b);c&&c.copyAttributes(d);d=v(d,a);b.getCustomData("doc_processing_style")&&
d.hasAttribute("id")?d.removeAttribute("id"):b.setCustomData("doc_processing_style",1);return d}function v(a,b){var c=b._.definition,d=c.attributes,c=CKEDITOR.style.getStyleText(c);if(d)for(var f in d)a.setAttribute(f,d[f]);c&&a.setAttribute("style",c);return a}function z(a,b){for(var c in a)a[c]=a[c].replace(G,function(a,c){return b[c]})}function p(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 d=0;d<c.length;d++){var f=
c[d],e,g;"string"==typeof f?e=f.toLowerCase():(e=f.element?f.element.toLowerCase():a.element,g=f.attributes);f=b[e]||(b[e]={});if(g){var f=f.attributes=f.attributes||[],h;for(h in g)f.push([h.toLowerCase(),g[h]])}}}return b}function u(a,b,c){var d=new CKEDITOR.dom.element("span");d[c?"setStyle":"setAttribute"](a,b);return d[c?"getStyle":"getAttribute"](a)}function B(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 d in a)if(!(d in b)||c(b[d],d)!=c(a[d],d)&&"inherit"!=a[d]&&"inherit"!=b[d])return!1;return!0}function w(a,b,c){var d=a.document,f=a.getRanges();b=b?this.removeFromRange:this.applyToRange;for(var e,g=f.createIterator();e=g.getNextRange();)b.call(this,e,c);a.selectRanges(f);d.removeCustomData("doc_processing_style")}var C={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},D={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*|$)/,G=/#\((.+?)\)/g,L=CKEDITOR.dom.walker.bookmark(0,1),I=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),z(a.attributes,b),z(a.styles,b));c=this.element=a.element?"string"==typeof a.element?a.element.toLowerCase():a.element:"*";this.type=a.type||(C[c]?CKEDITOR.STYLE_BLOCK:D[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 w.call(this,a.getSelection());
if(this.checkApplicable(a.elementPath(),a)){var b=this._.enterMode;b||(this._.enterMode=a.activeEnterMode);w.call(this,a.getSelection(),0,a);this._.enterMode=b}},remove:function(a){if(a instanceof CKEDITOR.dom.document)return w.call(this,a.getSelection(),1);if(this.checkApplicable(a.elementPath(),a)){var b=this._.enterMode;b||(this._.enterMode=a.activeEnterMode);w.call(this,a.getSelection(),1,a);this._.enterMode=b}},applyToRange:function(a){this.applyToRange=this.type==CKEDITOR.STYLE_INLINE?e:this.type==
CKEDITOR.STYLE_BLOCK?k:this.type==CKEDITOR.STYLE_OBJECT?l:null;return this.applyToRange(a)},removeFromRange:function(b){this.removeFromRange=this.type==CKEDITOR.STYLE_INLINE?a:this.type==CKEDITOR.STYLE_BLOCK?d:this.type==CKEDITOR.STYLE_OBJECT?n:null;return this.removeFromRange(b)},applyToObject:function(a){v(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,d=0,f;d<c.length;d++)if(f=c[d],this.type!=CKEDITOR.STYLE_INLINE||f!=a.block&&f!=a.blockLimit){if(this.type==CKEDITOR.STYLE_OBJECT){var e=f.getName();if(!("string"==typeof this.element?e==this.element:e in this.element))continue}if(this.checkElementRemovable(f,!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 d=a.getName();if("string"==typeof this.element?d==this.element:d in this.element){if(!b&&!a.hasAttributes())return!0;if(d=c._AC)c=d;else{var d={},f=0,e=c.attributes;if(e)for(var g in e)f++,d[g]=e[g];if(g=CKEDITOR.style.getStyleText(c))d.style||f++,d.style=g;d._length=f;c=c._AC=d}if(c._length){for(var h in c)if("_length"!=h)if(d=a.getAttribute(h)||"","style"==h?B(c[h],d):c[h]==d){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=p(this)[a.getName()]){var d;if(!(b=b.attributes))return!0;for(c=0;c<b.length;c++)if(d=b[c][0],d=a.getAttribute(d)){var f=b[c][1];if(null===f)return!0;if("string"==typeof f){if(d==f)return!0}else if(f.test(d))return!0}}return!1},buildPreview:function(a){var b=this._.definition,c=[],d=b.element;"bdo"==d&&(d="span");var c=["\x3c",d],f=b.attributes;if(f)for(var e in f)c.push(" ",
e,'\x3d"',f[e],'"');(f=CKEDITOR.style.getStyleText(b))&&c.push(' style\x3d"',f,'"');c.push("\x3e",a||b.name,"\x3c/",d,"\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||"",d="";c.length&&(c=c.replace(F,";"));for(var f in b){var e=b[f],g=(f+":"+e).replace(F,";");"inherit"==e?d+=g:c+=g}c.length&&(c=CKEDITOR.tools.normalizeCssText(c,!0));return a._ST=c+d};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 P=CKEDITOR.POSITION_PRECEDING|CKEDITOR.POSITION_IDENTICAL|CKEDITOR.POSITION_IS_CONTAINED,H=CKEDITOR.POSITION_FOLLOWING|CKEDITOR.POSITION_IDENTICAL|CKEDITOR.POSITION_IS_CONTAINED}(),CKEDITOR.styleCommand=function(b,
g){this.requiredContent=this.allowedContent=this.style=b;CKEDITOR.tools.extend(this,g,!0)},CKEDITOR.styleCommand.prototype.exec=function(b){b.focus();this.state==CKEDITOR.TRISTATE_OFF?b.applyStyle(this.style):this.state==CKEDITOR.TRISTATE_ON&&b.removeStyle(this.style)},CKEDITOR.stylesSet=new CKEDITOR.resourceManager("","stylesSet"),CKEDITOR.addStylesSet=CKEDITOR.tools.bind(CKEDITOR.stylesSet.add,CKEDITOR.stylesSet),CKEDITOR.loadStylesSet=function(b,g,e){CKEDITOR.stylesSet.addExternal(b,g,"");CKEDITOR.stylesSet.load(b,
e)},CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{attachStyleStateChange:function(b,g){var e=this._.styleStateChangeCallbacks;e||(e=this._.styleStateChangeCallbacks=[],this.on("selectionChange",function(a){for(var b=0;b<e.length;b++){var g=e[b],n=g.style.checkActive(a.data.path,this)?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF;g.fn.call(this,n)}}));e.push({style:b,fn:g})},applyStyle:function(b){b.apply(this)},removeStyle:function(b){b.remove(this)},getStylesSet:function(b){if(this._.stylesDefinitions)b(this._.stylesDefinitions);
else{var g=this,e=g.config.stylesCombo_stylesSet||g.config.stylesSet;if(!1===e)b(null);else if(e instanceof Array)g._.stylesDefinitions=e,b(e);else{e||(e="default");var e=e.split(":"),a=e[0];CKEDITOR.stylesSet.addExternal(a,e[1]?e.slice(1).join(":"):CKEDITOR.getUrl("styles.js"),"");CKEDITOR.stylesSet.load(a,function(e){g._.stylesDefinitions=e[a];b(g._.stylesDefinitions)})}}}}),CKEDITOR.dom.comment=function(b,g){"string"==typeof b&&(b=(g?g.$:document).createComment(b));CKEDITOR.dom.domObject.call(this,
b)},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 b={},g={},e;for(e in CKEDITOR.dtd.$blockLimit)e in CKEDITOR.dtd.$list||(b[e]=1);for(e in CKEDITOR.dtd.$block)e in CKEDITOR.dtd.$blockLimit||e in CKEDITOR.dtd.$empty||(g[e]=1);CKEDITOR.dom.elementPath=function(a,e){var l=null,n=null,k=[],d=a,c;e=e||a.getDocument().getBody();
do if(d.type==CKEDITOR.NODE_ELEMENT){k.push(d);if(!this.lastElement&&(this.lastElement=d,d.is(CKEDITOR.dtd.$object)||"false"==d.getAttribute("contenteditable")))continue;if(d.equals(e))break;if(!n&&(c=d.getName(),"true"==d.getAttribute("contenteditable")?n=d:!l&&g[c]&&(l=d),b[c])){if(c=!l&&"div"==c){a:{c=d.getChildren();for(var f=0,m=c.count();f<m;f++){var t=c.getItem(f);if(t.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$block[t.getName()]){c=!0;break a}}c=!1}c=!c}c?l=d:n=d}}while(d=d.getParent());n||
(n=e);this.block=l;this.blockLimit=n;this.root=e;this.elements=k}}(),CKEDITOR.dom.elementPath.prototype={compare:function(b){var g=this.elements;b=b&&b.elements;if(!b||g.length!=b.length)return!1;for(var e=0;e<g.length;e++)if(!g[e].equals(b[e]))return!1;return!0},contains:function(b,g,e){var a;"string"==typeof b&&(a=function(a){return a.getName()==b});b instanceof CKEDITOR.dom.element?a=function(a){return a.equals(b)}:CKEDITOR.tools.isArray(b)?a=function(a){return-1<CKEDITOR.tools.indexOf(b,a.getName())}:
"function"==typeof b?a=b:"object"==typeof b&&(a=function(a){return a.getName()in b});var h=this.elements,l=h.length;g&&l--;e&&(h=Array.prototype.slice.call(h,0),h.reverse());for(g=0;g<l;g++)if(a(h[g]))return h[g];return null},isContextFor:function(b){var g;return b in CKEDITOR.dtd.$block?(g=this.contains(CKEDITOR.dtd.$intermediate)||this.root.equals(this.block)&&this.block||this.blockLimit,!!g.getDtd()[b]):!0},direction:function(){return(this.block||this.blockLimit||this.root).getDirection(1)}},CKEDITOR.dom.text=
function(b,g){"string"==typeof b&&(b=(g?g.$:document).createTextNode(b));this.$=b},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(b){this.$.nodeValue=b},split:function(b){var g=this.$.parentNode,e=g.childNodes.length,a=this.getLength(),h=this.getDocument(),l=new CKEDITOR.dom.text(this.$.splitText(b),h);g.childNodes.length==
e&&(b>=a?(l=h.createText(""),l.insertAfter(this)):(b=h.createText(""),b.insertAfter(l),b.remove()));return l},substring:function(b,g){return"number"!=typeof g?this.$.nodeValue.substr(b):this.$.nodeValue.substring(b,g)}}),function(){function b(b,a,g){var l=b.serializable,n=a[g?"endContainer":"startContainer"],k=g?"endOffset":"startOffset",d=l?a.document.getById(b.startNode):b.startNode;b=l?a.document.getById(b.endNode):b.endNode;n.equals(d.getPrevious())?(a.startOffset=a.startOffset-n.getLength()-
b.getPrevious().getLength(),n=b.getNext()):n.equals(b.getPrevious())&&(a.startOffset-=n.getLength(),n=b.getNext());n.equals(d.getParent())&&a[k]++;n.equals(b.getParent())&&a[k]++;a[g?"endContainer":"startContainer"]=n;return a}CKEDITOR.dom.rangeList=function(b){if(b instanceof CKEDITOR.dom.rangeList)return b;b?b instanceof CKEDITOR.dom.range&&(b=[b]):b=[];return CKEDITOR.tools.extend(b,g)};var g={createIterator:function(){var b=this,a=CKEDITOR.dom.walker.bookmark(),g=[],l;return{getNextRange:function(n){l=
void 0===l?0:l+1;var k=b[l];if(k&&1<b.length){if(!l)for(var d=b.length-1;0<=d;d--)g.unshift(b[d].createBookmark(!0));if(n)for(var c=0;b[l+c+1];){var f=k.document;n=0;d=f.getById(g[c].endNode);for(f=f.getById(g[c+1].startNode);;){d=d.getNextSourceNode(!1);if(f.equals(d))n=1;else if(a(d)||d.type==CKEDITOR.NODE_ELEMENT&&d.isBlockBoundary())continue;break}if(!n)break;c++}for(k.moveToBookmark(g.shift());c--;)d=b[++l],d.moveToBookmark(g.shift()),k.setEnd(d.endContainer,d.endOffset)}return k}}},createBookmarks:function(e){for(var a=
[],g,l=0;l<this.length;l++){a.push(g=this[l].createBookmark(e,!0));for(var n=l+1;n<this.length;n++)this[n]=b(g,this[n]),this[n]=b(g,this[n],!0)}return a},createBookmarks2:function(b){for(var a=[],g=0;g<this.length;g++)a.push(this[g].createBookmark2(b));return a},moveToBookmarks:function(b){for(var a=0;a<this.length;a++)this[a].moveToBookmark(b[a])}}}(),function(){function b(){return CKEDITOR.getUrl(CKEDITOR.skinName.split(",")[1]||"skins/"+CKEDITOR.skinName.split(",")[0]+"/")}function g(a){var d=
CKEDITOR.skin["ua_"+a],e=CKEDITOR.env;if(d)for(var d=d.split(",").sort(function(a,b){return a>b?-1:1}),g=0,h;g<d.length;g++)if(h=d[g],e.ie&&(h.replace(/^ie/,"")==e.version||e.quirks&&"iequirks"==h)&&(h="ie"),e[h]){a+="_"+d[g];break}return CKEDITOR.getUrl(b()+a+".css")}function e(a,b){l[a]||(CKEDITOR.document.appendStyleSheet(g(a)),l[a]=1);b&&b()}function a(a){var b=a.getById(n);b||(b=a.getHead().append("style"),b.setAttribute("id",n),b.setAttribute("type","text/css"));return b}function h(a,b,d){var e,
g,h;if(CKEDITOR.env.webkit)for(b=b.split("}").slice(0,-1),g=0;g<b.length;g++)b[g]=b[g].split("{");for(var k=0;k<a.length;k++)if(CKEDITOR.env.webkit)for(g=0;g<b.length;g++){h=b[g][1];for(e=0;e<d.length;e++)h=h.replace(d[e][0],d[e][1]);a[k].$.sheet.addRule(b[g][0],h)}else{h=b;for(e=0;e<d.length;e++)h=h.replace(d[e][0],d[e][1]);CKEDITOR.env.ie&&11>CKEDITOR.env.version?a[k].$.styleSheet.cssText+=h:a[k].$.innerHTML+=h}}var l={};CKEDITOR.skin={path:b,loadPart:function(a,d){CKEDITOR.skin.name!=CKEDITOR.skinName.split(",")[0]?
CKEDITOR.scriptLoader.load(CKEDITOR.getUrl(b()+"skin.js"),function(){e(a,d)}):e(a,d)},getPath:function(a){return CKEDITOR.getUrl(g(a))},icons:{},addIcon:function(a,b,d,e){a=a.toLowerCase();this.icons[a]||(this.icons[a]={path:b,offset:d||0,bgsize:e||"16px"})},getIconStyle:function(a,b,d,e,g){var h;a&&(a=a.toLowerCase(),b&&(h=this.icons[a+"-rtl"]),h||(h=this.icons[a]));a=d||h&&h.path||"";e=e||h&&h.offset;g=g||h&&h.bgsize||"16px";a&&(a=a.replace(/'/g,"\\'"));return a&&"background-image:url('"+CKEDITOR.getUrl(a)+
"');background-position:0 "+e+"px;background-size:"+g+";"}};CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{getUiColor:function(){return this.uiColor},setUiColor:function(b){var f=a(CKEDITOR.document);return(this.setUiColor=function(a){this.uiColor=a;var b=CKEDITOR.skin.chameleon,c="",e="";"function"==typeof b&&(c=b(this,"editor"),e=b(this,"panel"));a=[[d,a]];h([f],c,a);h(k,e,a)}).call(this,b)}});var n="cke_ui_color",k=[],d=/\$color/g;CKEDITOR.on("instanceLoaded",function(b){if(!CKEDITOR.env.ie||
!CKEDITOR.env.quirks){var f=b.editor;b=function(b){b=(b.data[0]||b.data).element.getElementsByTag("iframe").getItem(0).getFrameDocument();if(!b.getById("cke_ui_color")){b=a(b);k.push(b);var c=f.getUiColor();c&&h([b],CKEDITOR.skin.chameleon(f,"panel"),[[d,c]])}};f.on("panelShow",b);f.on("menuShow",b);f.config.uiColor&&f.setUiColor(f.config.uiColor)}})}(),function(){if(CKEDITOR.env.webkit)CKEDITOR.env.hc=!1;else{var b=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);b.appendTo(CKEDITOR.document.getHead());try{var g=b.getComputedStyle("border-top-color"),e=b.getComputedStyle("border-right-color");CKEDITOR.env.hc=!(!g||g!=e)}catch(a){CKEDITOR.env.hc=!1}b.remove()}CKEDITOR.env.hc&&(CKEDITOR.env.cssClass+=" cke_hc");CKEDITOR.document.appendStyleText(".cke{visibility:hidden;}");CKEDITOR.status="loaded";CKEDITOR.fireOnce("loaded");if(b=CKEDITOR._.pending)for(delete CKEDITOR._.pending,g=0;g<b.length;g++)CKEDITOR.editor.prototype.constructor.apply(b[g][0],
b[g][1]),CKEDITOR.add(b[g][0])}(),CKEDITOR.skin.name="moono",CKEDITOR.skin.ua_editor="ie,iequirks,ie7,ie8,gecko",CKEDITOR.skin.ua_dialog="ie,iequirks,ie7,ie8",CKEDITOR.skin.chameleon=function(){var b=function(){return function(a,b){for(var e=a.match(/[^#]./g),g=0;3>g;g++){var k=g,d;d=parseInt(e[g],16);d=("0"+(0>b?0|d*(1+b):0|d+(255-d)*b).toString(16)).slice(-2);e[k]=d}return"#"+e.join("")}}(),g=function(){var a=new CKEDITOR.template("background:#{to};background-image:linear-gradient(to bottom,{from},{to});filter:progid:DXImageTransform.Microsoft.gradient(gradientType\x3d0,startColorstr\x3d'{from}',endColorstr\x3d'{to}');");
return function(b,e){return a.output({from:b,to:e})}}(),e={editor:new CKEDITOR.template("{id}.cke_chrome [border-color:{defaultBorder};] {id} .cke_top [ {defaultGradient}border-bottom-color:{defaultBorder};] {id} .cke_bottom [{defaultGradient}border-top-color:{defaultBorder};] {id} .cke_resizer [border-right-color:{ckeResizer}] {id} .cke_dialog_title [{defaultGradient}border-bottom-color:{defaultBorder};] {id} .cke_dialog_footer [{defaultGradient}outline-color:{defaultBorder};border-top-color:{defaultBorder};] {id} .cke_dialog_tab [{lightGradient}border-color:{defaultBorder};] {id} .cke_dialog_tab:hover [{mediumGradient}] {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} .cke_toolgroup [{lightGradient}border-color:{defaultBorder};] {id} a.cke_button_off:hover, {id} a.cke_button_off:focus, {id} a.cke_button_off:active [{mediumGradient}] {id} .cke_button_on [{ckeButtonOn}] {id} .cke_toolbar_separator [background-color: {ckeToolbarSeparator};] {id} .cke_combo_button [border-color:{defaultBorder};{lightGradient}] {id} a.cke_combo_button:hover, {id} a.cke_combo_button:focus, {id} .cke_combo_on a.cke_combo_button [border-color:{defaultBorder};{mediumGradient}] {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:{elementsPathBg};] {id}.cke_panel [border-color:{defaultBorder};] "),
panel:new CKEDITOR.template(".cke_panel_grouptitle [{lightGradient}border-color:{defaultBorder};] .cke_menubutton_icon [background-color:{menubuttonIcon};] .cke_menubutton:hover .cke_menubutton_icon, .cke_menubutton:focus .cke_menubutton_icon, .cke_menubutton:active .cke_menubutton_icon [background-color:{menubuttonIconHover};] .cke_menuseparator [background-color:{menubuttonIcon};] a:hover.cke_colorbox, a:focus.cke_colorbox, a:active.cke_colorbox [border-color:{defaultBorder};] a:hover.cke_colorauto, a:hover.cke_colormore, a:focus.cke_colorauto, a:focus.cke_colormore, a:active.cke_colorauto, a:active.cke_colormore [background-color:{ckeColorauto};border-color:{defaultBorder};] ")};
return function(a,h){var l=a.uiColor,l={id:"."+a.id,defaultBorder:b(l,-.1),defaultGradient:g(b(l,.9),l),lightGradient:g(b(l,1),b(l,.7)),mediumGradient:g(b(l,.8),b(l,.5)),ckeButtonOn:g(b(l,.6),b(l,.7)),ckeResizer:b(l,-.4),ckeToolbarSeparator:b(l,.5),ckeColorauto:b(l,.8),dialogBody:b(l,.7),dialogTabSelected:g("#FFFFFF","#FFFFFF"),dialogTabSelectedBorder:"#FFF",elementsPathColor:b(l,-.6),elementsPathBg:l,menubuttonIcon:b(l,.5),menubuttonIconHover:b(l,.3)};return e[h].output(l).replace(/\[/g,"{").replace(/\]/g,
"}")}}(),CKEDITOR.plugins.add("basicstyles",{init:function(b){var g=0,e=function(e,h,d,c){if(c){c=new CKEDITOR.style(c);var f=a[d];f.unshift(c);b.attachStyleStateChange(c,function(a){!b.readOnly&&b.getCommand(d).setState(a)});b.addCommand(d,new CKEDITOR.styleCommand(c,{contentForms:f}));b.ui.addButton&&b.ui.addButton(e,{label:h,command:d,toolbar:"basicstyles,"+(g+=10)})}},a={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"]},h=b.config,l=b.lang.basicstyles;e("Bold",l.bold,"bold",h.coreStyles_bold);e("Italic",l.italic,"italic",h.coreStyles_italic);e("Underline",l.underline,"underline",h.coreStyles_underline);e("Strike",l.strike,"strike",h.coreStyles_strike);e("Subscript",l.subscript,
"subscript",h.coreStyles_subscript);e("Superscript",l.superscript,"superscript",h.coreStyles_superscript);b.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"},CKEDITOR.plugins.add("dialogui",{onLoad:function(){var b=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._},g={build:function(a,b,f){return new CKEDITOR.ui.dialog.textInput(a,b,f)}},e={build:function(a,b,f){return new CKEDITOR.ui.dialog[b.type](a,
b,f)}},a={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}},h=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+)/,n=function(a){for(var b in a)(l.test(b)||"title"==b||"type"==b)&&delete a[b];return a},k=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(a,c,f,e){if(!(4>arguments.length)){var g=b.call(this,
c);g.labelId=CKEDITOR.tools.getNextId()+"_label";this._.children=[];var h={role:c.role||"presentation"};c.includeLabel&&(h["aria-labelledby"]=g.labelId);CKEDITOR.ui.dialog.uiElement.call(this,a,c,f,"div",null,h,function(){var b=[],f=c.required?" cke_required":"";"horizontal"!=c.labelLayout?b.push('\x3clabel class\x3d"cke_dialog_ui_labeled_label'+f+'" ',' id\x3d"'+g.labelId+'"',g.inputId?' for\x3d"'+g.inputId+'"':"",(c.labelStyle?' style\x3d"'+c.labelStyle+'"':"")+"\x3e",c.label,"\x3c/label\x3e",'\x3cdiv class\x3d"cke_dialog_ui_labeled_content"',
c.controlStyle?' style\x3d"'+c.controlStyle+'"':"",' role\x3d"presentation"\x3e',e.call(this,a,c),"\x3c/div\x3e"):(f={type:"hbox",widths:c.widths,padding:0,children:[{type:"html",html:'\x3clabel class\x3d"cke_dialog_ui_labeled_label'+f+'" id\x3d"'+g.labelId+'" for\x3d"'+g.inputId+'"'+(c.labelStyle?' style\x3d"'+c.labelStyle+'"':"")+"\x3e"+CKEDITOR.tools.htmlEncode(c.label)+"\x3c/label\x3e"},{type:"html",html:'\x3cspan class\x3d"cke_dialog_ui_labeled_content"'+(c.controlStyle?' style\x3d"'+c.controlStyle+
'"':"")+"\x3e"+e.call(this,a,c)+"\x3c/span\x3e"}]},CKEDITOR.dialog._.uiElementBuilders.hbox.build(a,f,b));return b.join("")})}},textInput:function(a,c,f){if(!(3>arguments.length)){b.call(this,c);var e=this._.inputId=CKEDITOR.tools.getNextId()+"_textInput",g={"class":"cke_dialog_ui_input_"+c.type,id:e,type:c.type};c.validate&&(this.validate=c.validate);c.maxLength&&(g.maxlength=c.maxLength);c.size&&(g.size=c.size);c.inputStyle&&(g.style=c.inputStyle);var h=this,l=!1;a.on("load",function(){h.getInputElement().on("keydown",
function(a){13==a.data.getKeystroke()&&(l=!0)});h.getInputElement().on("keyup",function(b){13==b.data.getKeystroke()&&l&&(a.getButton("ok")&&setTimeout(function(){a.getButton("ok").click()},0),l=!1);h.bidi&&k.call(h,b)},null,null,1E3)});CKEDITOR.ui.dialog.labeledElement.call(this,a,c,f,function(){var a=['\x3cdiv class\x3d"cke_dialog_ui_input_',c.type,'" role\x3d"presentation"'];c.width&&a.push('style\x3d"width:'+c.width+'" ');a.push("\x3e\x3cinput ");g["aria-labelledby"]=this._.labelId;this._.required&&
(g["aria-required"]=this._.required);for(var b in g)a.push(b+'\x3d"'+g[b]+'" ');a.push(" /\x3e\x3c/div\x3e");return a.join("")})}},textarea:function(a,c,f){if(!(3>arguments.length)){b.call(this,c);var e=this,g=this._.inputId=CKEDITOR.tools.getNextId()+"_textarea",h={};c.validate&&(this.validate=c.validate);h.rows=c.rows||5;h.cols=c.cols||20;h["class"]="cke_dialog_ui_input_textarea "+(c["class"]||"");"undefined"!=typeof c.inputStyle&&(h.style=c.inputStyle);c.dir&&(h.dir=c.dir);if(e.bidi)a.on("load",
function(){e.getInputElement().on("keyup",k)},e);CKEDITOR.ui.dialog.labeledElement.call(this,a,c,f,function(){h["aria-labelledby"]=this._.labelId;this._.required&&(h["aria-required"]=this._.required);var a=['\x3cdiv class\x3d"cke_dialog_ui_input_textarea" role\x3d"presentation"\x3e\x3ctextarea id\x3d"',g,'" '],b;for(b in h)a.push(b+'\x3d"'+CKEDITOR.tools.htmlEncode(h[b])+'" ');a.push("\x3e",CKEDITOR.tools.htmlEncode(e._["default"]),"\x3c/textarea\x3e\x3c/div\x3e");return a.join("")})}},checkbox:function(a,
c,f){if(!(3>arguments.length)){var e=b.call(this,c,{"default":!!c["default"]});c.validate&&(this.validate=c.validate);CKEDITOR.ui.dialog.uiElement.call(this,a,c,f,"span",null,null,function(){var b=CKEDITOR.tools.extend({},c,{id:c.id?c.id+"_checkbox":CKEDITOR.tools.getNextId()+"_checkbox"},!0),f=[],g=CKEDITOR.tools.getNextId()+"_label",h={"class":"cke_dialog_ui_checkbox_input",type:"checkbox","aria-labelledby":g};n(b);c["default"]&&(h.checked="checked");"undefined"!=typeof b.inputStyle&&(b.style=b.inputStyle);
e.checkbox=new CKEDITOR.ui.dialog.uiElement(a,b,f,"input",null,h);f.push(' \x3clabel id\x3d"',g,'" for\x3d"',h.id,'"'+(c.labelStyle?' style\x3d"'+c.labelStyle+'"':"")+"\x3e",CKEDITOR.tools.htmlEncode(c.label),"\x3c/label\x3e");return f.join("")})}},radio:function(a,c,f){if(!(3>arguments.length)){b.call(this,c);this._["default"]||(this._["default"]=this._.initValue=c.items[0][1]);c.validate&&(this.validate=c.validate);var e=[],g=this;c.role="radiogroup";c.includeLabel=!0;CKEDITOR.ui.dialog.labeledElement.call(this,
a,c,f,function(){for(var b=[],f=[],h=(c.id?c.id:CKEDITOR.tools.getNextId())+"_radio",k=0;k<c.items.length;k++){var l=c.items[k],v=void 0!==l[2]?l[2]:l[0],z=void 0!==l[1]?l[1]:l[0],p=CKEDITOR.tools.getNextId()+"_radio_input",u=p+"_label",p=CKEDITOR.tools.extend({},c,{id:p,title:null,type:null},!0),v=CKEDITOR.tools.extend({},p,{title:v},!0),B={type:"radio","class":"cke_dialog_ui_radio_input",name:h,value:z,"aria-labelledby":u},w=[];g._["default"]==z&&(B.checked="checked");n(p);n(v);"undefined"!=typeof p.inputStyle&&
(p.style=p.inputStyle);p.keyboardFocusable=!0;e.push(new CKEDITOR.ui.dialog.uiElement(a,p,w,"input",null,B));w.push(" ");new CKEDITOR.ui.dialog.uiElement(a,v,w,"label",null,{id:u,"for":B.id},l[0]);b.push(w.join(""))}new CKEDITOR.ui.dialog.hbox(a,e,b,f);return f.join("")});this._.children=e}},button:function(a,c,f){if(arguments.length){"function"==typeof c&&(c=c(a.getParentEditor()));b.call(this,c,{disabled:c.disabled||!1});CKEDITOR.event.implementOn(this);var e=this;a.on("load",function(){var a=this.getElement();
(function(){a.on("click",function(a){e.click();a.data.preventDefault()});a.on("keydown",function(a){a.data.getKeystroke()in{32:1}&&(e.click(),a.data.preventDefault())})})();a.unselectable()},this);var g=CKEDITOR.tools.extend({},c);delete g.style;var h=CKEDITOR.tools.getNextId()+"_label";CKEDITOR.ui.dialog.uiElement.call(this,a,g,f,"a",null,{style:c.style,href:"javascript:void(0)",title:c.label,hidefocus:"true","class":c["class"],role:"button","aria-labelledby":h},'\x3cspan id\x3d"'+h+'" class\x3d"cke_dialog_ui_button"\x3e'+
CKEDITOR.tools.htmlEncode(c.label)+"\x3c/span\x3e")}},select:function(a,c,f){if(!(3>arguments.length)){var e=b.call(this,c);c.validate&&(this.validate=c.validate);e.inputId=CKEDITOR.tools.getNextId()+"_select";CKEDITOR.ui.dialog.labeledElement.call(this,a,c,f,function(){var b=CKEDITOR.tools.extend({},c,{id:c.id?c.id+"_select":CKEDITOR.tools.getNextId()+"_select"},!0),f=[],g=[],h={id:e.inputId,"class":"cke_dialog_ui_input_select","aria-labelledby":this._.labelId};f.push('\x3cdiv class\x3d"cke_dialog_ui_input_',
c.type,'" role\x3d"presentation"');c.width&&f.push('style\x3d"width:'+c.width+'" ');f.push("\x3e");void 0!==c.size&&(h.size=c.size);void 0!==c.multiple&&(h.multiple=c.multiple);n(b);for(var k=0,l;k<c.items.length&&(l=c.items[k]);k++)g.push('\x3coption value\x3d"',CKEDITOR.tools.htmlEncode(void 0!==l[1]?l[1]:l[0]).replace(/"/g,"\x26quot;"),'" /\x3e ',CKEDITOR.tools.htmlEncode(l[0]));"undefined"!=typeof b.inputStyle&&(b.style=b.inputStyle);e.select=new CKEDITOR.ui.dialog.uiElement(a,b,f,"select",null,
h,g.join(""));f.push("\x3c/div\x3e");return f.join("")})}},file:function(a,c,f){if(!(3>arguments.length)){void 0===c["default"]&&(c["default"]="");var e=CKEDITOR.tools.extend(b.call(this,c),{definition:c,buttons:[]});c.validate&&(this.validate=c.validate);a.on("load",function(){CKEDITOR.document.getById(e.frameId).getParent().addClass("cke_dialog_ui_input_file")});CKEDITOR.ui.dialog.labeledElement.call(this,a,c,f,function(){e.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"',
e.frameId,'" title\x3d"',c.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(a,c,f){var e=this;if(!(3>arguments.length)){b.call(this,c);c.validate&&(this.validate=c.validate);var g=CKEDITOR.tools.extend({},c),h=g.onClick;g.className=(g.className?g.className+" ":"")+"cke_dialog_ui_button";g.onClick=function(b){var f=
c["for"];h&&!1===h.call(this,b)||(a.getContentElement(f[0],f[1]).submit(),this.disable())};a.on("load",function(){a.getContentElement(c["for"][0],c["for"][1])._.buttons.push(e)});CKEDITOR.ui.dialog.button.call(this,a,g,f)}},html:function(){var a=/^\s*<[\w:]+\s+([^>]*)?>/,b=/^(\s*<[\w:]+(?:\s+[^>]*)?)((?:.|\r|\n)+)$/,f=/\/$/;return function(e,g,h){if(!(3>arguments.length)){var k=[],l=g.html;"\x3c"!=l.charAt(0)&&(l="\x3cspan\x3e"+l+"\x3c/span\x3e");var n=g.focus;if(n){var y=this.focus;this.focus=function(){("function"==
typeof n?n:y).call(this);this.fire("focus")};g.isFocusable&&(this.isFocusable=this.isFocusable);this.keyboardFocusable=!0}CKEDITOR.ui.dialog.uiElement.call(this,e,g,k,"span",null,null,"");k=k.join("").match(a);l=l.match(b)||["","",""];f.test(l[1])&&(l[1]=l[1].slice(0,-1),l[2]="/"+l[2]);h.push([l[1]," ",k[1]||"",l[2]].join(""))}}}(),fieldset:function(a,b,f,e,g){var h=g.label;this._={children:b};CKEDITOR.ui.dialog.uiElement.call(this,a,g,e,"fieldset",null,null,function(){var a=[];h&&a.push("\x3clegend"+
(g.labelStyle?' style\x3d"'+g.labelStyle+'"':"")+"\x3e"+h+"\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:h},!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},a,!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 e=new CKEDITOR.dom.element("option",this.getDialog().getParentEditor().document),g=this.getInputElement().$;e.$.text=a;e.$.value=void 0===b||null===b?a:b;void 0===f||null===f?CKEDITOR.env.ie?g.add(e.$):g.add(e.$,null):g.add(e.$,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},a,!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 h.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},a,!0);CKEDITOR.ui.dialog.radio.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,{setValue:function(a,b){for(var f=this._.children,e,g=0;g<f.length&&(e=f[g]);g++)e.getElement().$.checked=
e.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 h.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}}},a,!0);CKEDITOR.ui.dialog.file.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.labeledElement,a,{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,e=function(a,b,c,d){a.on("formLoaded",function(){a.getInputElement().on(c,d,a)})},g;for(g in a)if(f=g.match(b))this.eventProcessors[g]?this.eventProcessors[g].call(this,this._.dialog,a[g]):e(this,this._.dialog,f[1].toLowerCase(),a[g]);return this},reset:function(){function a(){f.$.open();
var d="";e.size&&(d=e.size-(CKEDITOR.env.ie?7:0));var v=b.frameId+"_input";f.$.write(['\x3chtml dir\x3d"'+l+'" lang\x3d"'+n+'"\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"'+l+'" lang\x3d"'+n+'" action\x3d"',CKEDITOR.tools.htmlEncode(e.action),'"\x3e\x3clabel id\x3d"',b.labelId,'" for\x3d"',v,'" style\x3d"display:none"\x3e',CKEDITOR.tools.htmlEncode(e.label),
'\x3c/label\x3e\x3cinput style\x3d"width:100%" id\x3d"',v,'" aria-labelledby\x3d"',b.labelId,'" type\x3d"file" name\x3d"',CKEDITOR.tools.htmlEncode(e.id||"cke_upload"),'" size\x3d"',CKEDITOR.tools.htmlEncode(0<d?d:""),'" /\x3e\x3c/form\x3e\x3c/body\x3e\x3c/html\x3e\x3cscript\x3e',CKEDITOR.env.ie?"("+CKEDITOR.tools.fixDomain+")();":"","window.parent.CKEDITOR.tools.callFunction("+h+");","window.onbeforeunload \x3d function() {window.parent.CKEDITOR.tools.callFunction("+k+")}","\x3c/script\x3e"].join(""));
f.$.close();for(d=0;d<g.length;d++)g[d].enable()}var b=this._,f=CKEDITOR.document.getById(b.frameId).getFrameDocument(),e=b.definition,g=b.buttons,h=this.formLoadedNumber,k=this.formUnloadNumber,l=b.dialog._.editor.lang.dir,n=b.dialog._.editor.langCode;h||(h=this.formLoadedNumber=CKEDITOR.tools.addFunction(function(){this.fire("formLoaded")},this),k=this.formUnloadNumber=CKEDITOR.tools.addFunction(function(){this.getInputElement().clearCustomData()},this),this.getDialog()._.editor.on("destroy",function(){CKEDITOR.tools.removeFunction(h);
CKEDITOR.tools.removeFunction(k)}));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",g);CKEDITOR.dialog.addUIElement("password",g);CKEDITOR.dialog.addUIElement("textarea",e);CKEDITOR.dialog.addUIElement("checkbox",e);CKEDITOR.dialog.addUIElement("radio",e);CKEDITOR.dialog.addUIElement("button",e);CKEDITOR.dialog.addUIElement("select",e);CKEDITOR.dialog.addUIElement("file",e);CKEDITOR.dialog.addUIElement("fileButton",e);CKEDITOR.dialog.addUIElement("html",
e);CKEDITOR.dialog.addUIElement("fieldset",{build:function(a,b,f){for(var e=b.children,g,h=[],k=[],l=0;l<e.length&&(g=e[l]);l++){var n=[];h.push(n);k.push(CKEDITOR.dialog._.uiElementBuilders[g.type].build(a,g,n))}return new CKEDITOR.ui.dialog[b.type](a,k,h,f,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 b(){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 g(){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 e(a,b){for(var c=a.$.getElementsByTagName("input"),d=0,f=c.length;d<f;d++){var e=new CKEDITOR.dom.element(c[d]);
"text"==e.getAttribute("type").toLowerCase()&&(b?(e.setAttribute("value",e.getCustomData("fake_value")||""),e.removeCustomData("fake_value")):(e.setCustomData("fake_value",e.getAttribute("value")),e.setAttribute("value","")))}}function a(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 h(){var a=this.getInputElement();a&&a.removeAttribute("aria-invalid")}
function l(a){var b=CKEDITOR.dom.element.createFromHtml(CKEDITOR.addTemplate("dialog",r).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 n(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 k(a){function b(){a.layout()}var c=CKEDITOR.document.getWindow();c.on("resize",b);a.on("hide",function(){c.removeListener("resize",
b)})}function d(a,b){this._={dialog:a};CKEDITOR.tools.extend(this,b)}function c(a){function b(c){var k=a.getSize(),m=CKEDITOR.document.getWindow().getViewPaneSize(),l=c.data.$.screenX,n=c.data.$.screenY,p=l-d.x,q=n-d.y;d={x:l,y:n};f.x+=p;f.y+=q;a.move(f.x+h[3]<g?-h[3]:f.x-h[1]>m.width-k.width-g?m.width-k.width+("rtl"==e.lang.dir?0:h[1]):f.x,f.y+h[0]<g?-h[0]:f.y-h[2]>m.height-k.height-g?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=w.getChild(0).getFrameDocument();a.removeListener("mousemove",b);a.removeListener("mouseup",c)}}var d=null,f=null,e=a.getParentEditor(),g=e.config.dialog_magnetDistance,h=CKEDITOR.skin.margins||[0,0,0,0];"undefined"==typeof g&&(g=20);a.parts.title.on("mousedown",function(e){d={x:e.data.$.screenX,y:e.data.$.screenY};CKEDITOR.document.on("mousemove",b);CKEDITOR.document.on("mouseup",c);f=a.getPosition();if(CKEDITOR.env.ie6Compat){var g=
w.getChild(0).getFrameDocument();g.on("mousemove",b);g.on("mouseup",c)}e.data.preventDefault()},a)}function f(a){function b(c){var n="rtl"==e.lang.dir,J=l.width,p=l.height,q=J+(c.data.$.screenX-m.x)*(n?-1:1)*(a._.moved?1:2),r=p+(c.data.$.screenY-m.y)*(a._.moved?1:2),t=a._.element.getFirst(),t=n&&t.getComputedStyle("right"),M=a.getPosition();M.y+r>k.height&&(r=k.height-M.y);(n?t:M.x)+q>k.width&&(q=k.width-(n?t:M.x));if(f==CKEDITOR.DIALOG_RESIZE_WIDTH||f==CKEDITOR.DIALOG_RESIZE_BOTH)J=Math.max(d.minWidth||
0,q-g);if(f==CKEDITOR.DIALOG_RESIZE_HEIGHT||f==CKEDITOR.DIALOG_RESIZE_BOTH)p=Math.max(d.minHeight||0,r-h);a.resize(J,p);a._.moved||a.layout();c.data.preventDefault()}function c(){CKEDITOR.document.removeListener("mouseup",c);CKEDITOR.document.removeListener("mousemove",b);J&&(J.remove(),J=null);if(CKEDITOR.env.ie6Compat){var a=w.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 e=a.getParentEditor(),
g,h,k,m,l,J,n=CKEDITOR.tools.addFunction(function(d){l=a.getSize();var f=a.parts.contents;f.$.getElementsByTagName("iframe").length&&(J=CKEDITOR.dom.element.createFromHtml('\x3cdiv class\x3d"cke_dialog_resize_cover" style\x3d"height: 100%; position: absolute; width: 100%;"\x3e\x3c/div\x3e'),f.append(J));h=l.height-a.parts.contents.getSize("height",!(CKEDITOR.env.gecko||CKEDITOR.env.ie&&CKEDITOR.env.quirks));g=l.width-a.parts.contents.getSize("width",1);m={x:d.screenX,y:d.screenY};k=CKEDITOR.document.getWindow().getViewPaneSize();
CKEDITOR.document.on("mousemove",b);CKEDITOR.document.on("mouseup",c);CKEDITOR.env.ie6Compat&&(f=w.getChild(0).getFrameDocument(),f.on("mousemove",b),f.on("mouseup",c));d.preventDefault&&d.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_"+e.lang.dir+'" title\x3d"'+CKEDITOR.tools.htmlEncode(e.lang.common.resize)+
'" onmousedown\x3d"CKEDITOR.tools.callFunction('+n+', event )"\x3e'+("ltr"==e.lang.dir?"◢":"◣")+"\x3c/div\x3e");a.parts.footer.append(b,1)});e.on("destroy",function(){CKEDITOR.tools.removeFunction(n)})}}function m(a){a.data.preventDefault(1)}function t(a){var b=CKEDITOR.document.getWindow(),c=a.config,d=CKEDITOR.skinName||a.config.skin,f=c.dialog_backgroundCoverColor||("moono-lisa"==d?"black":"white"),d=c.dialog_backgroundCoverOpacity,e=c.baseFloatZIndex,c=CKEDITOR.tools.genKey(f,d,e),g=B[c];g?g.show():
(e=['\x3cdiv tabIndex\x3d"-1" style\x3d"position: ',CKEDITOR.env.ie6Compat?"absolute":"fixed","; z-index: ",e,"; top: 0px; left: 0px; ",CKEDITOR.env.ie6Compat?"":"background-color: "+f,'" class\x3d"cke_dialog_background_cover"\x3e'],CKEDITOR.env.ie6Compat&&(f="\x3chtml\x3e\x3cbody style\x3d\\'background-color:"+f+";\\'\x3e\x3c/body\x3e\x3c/html\x3e",e.push('\x3ciframe hidefocus\x3d"true" frameborder\x3d"0" id\x3d"cke_dialog_background_iframe" src\x3d"javascript:'),e.push("void((function(){"+encodeURIComponent("document.open();("+
CKEDITOR.tools.fixDomain+")();document.write( '"+f+"' );document.close();")+"})())"),e.push('" style\x3d"position:absolute;left:0;top:0;width:100%;height: 100%;filter: progid:DXImageTransform.Microsoft.Alpha(opacity\x3d0)"\x3e\x3c/iframe\x3e')),e.push("\x3c/div\x3e"),g=CKEDITOR.dom.element.createFromHtml(e.join("")),g.setOpacity(void 0!==d?d:.5),g.on("keydown",m),g.on("keypress",m),g.on("keyup",m),g.appendTo(CKEDITOR.document.getBody()),B[c]=g);a.focusManager.add(g);w=g;a=function(){var a=b.getViewPaneSize();
g.setStyles({width:a.width+"px",height:a.height+"px"})};var h=function(){var a=b.getScrollPosition(),c=CKEDITOR.dialog._.currentTop;g.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||g.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 x(a){w&&(a.focusManager.remove(w),a=CKEDITOR.document.getWindow(),w.hide(),a.removeListener("resize",u),CKEDITOR.env.ie6Compat&&a.$.setTimeout(function(){window.onscroll=window.onscroll&&window.onscroll.prevScrollHandler||null},0),u=null)}var A=CKEDITOR.tools.cssLength,r='\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(d,e){function k(){var a=K._.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 m(a){var b=K._.focusList;a=a||0;if(!(1>b.length)){var c=K._.currentFocusIndex;K._.tabBarMode&&0>a&&(c=0);try{b[c].getInputElement().$.blur()}catch(d){}var f=c,e=1<K._.pageCount;do{f+=a;if(e&&!K._.tabBarMode&&(f==b.length||-1==f)){K._.tabBarMode=!0;K._.tabs[K._.currentTabId][0].focus();
K._.currentFocusIndex=-1;return}f=(f+b.length)%b.length;if(f==c)break}while(a&&!b[f].isFocusable());b[f].focus();"text"==b[f].type&&b[f].select()}}function n(a){if(K==CKEDITOR.dialog._.currentTop){var c=a.data.getKeystroke(),f="rtl"==d.lang.dir,e=[37,38,39,40];J=M=0;if(9==c||c==CKEDITOR.SHIFT+9)m(c==CKEDITOR.SHIFT+9?-1:1),J=1;else if(c==CKEDITOR.ALT+121&&!K._.tabBarMode&&1<K.getPageCount())K._.tabBarMode=!0,K._.tabs[K._.currentTabId][0].focus(),K._.currentFocusIndex=-1,J=1;else if(-1!=CKEDITOR.tools.indexOf(e,
c)&&K._.tabBarMode)c=-1!=CKEDITOR.tools.indexOf([f?39:37,38],c)?b.call(K):g.call(K),K.selectPage(c),K._.tabs[c][0].focus(),J=1;else if(13!=c&&32!=c||!K._.tabBarMode)if(13==c)c=a.data.getTarget(),c.is("a","button","select","textarea")||c.is("input")&&"button"==c.$.type||((c=this.getButton("ok"))&&CKEDITOR.tools.setTimeout(c.click,0,c),J=1),M=1;else if(27==c)(c=this.getButton("cancel"))?CKEDITOR.tools.setTimeout(c.click,0,c):!1!==this.fire("cancel",{hide:!0}).hide&&this.hide(),M=1;else return;else this.selectPage(this._.currentTabId),
this._.tabBarMode=!1,this._.currentFocusIndex=-1,m(1),J=1;r(a)}}function r(a){J?a.data.preventDefault(1):M&&a.data.stopPropagation()}var t=CKEDITOR.dialog._.dialogDefinitions[e],A=CKEDITOR.tools.clone(q),y=d.config.dialog_buttonsOrder||"OS",v=d.lang.dir,z={},J,M;("OS"==y&&CKEDITOR.env.mac||"rtl"==y&&"ltr"==v||"ltr"==y&&"rtl"==v)&&A.buttons.reverse();t=CKEDITOR.tools.extend(t(d),A);t=CKEDITOR.tools.clone(t);t=new p(this,t);A=l(d);this._={editor:d,element:A.element,name:e,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=A.parts;CKEDITOR.tools.setTimeout(function(){d.fire("ariaWidget",this.parts.contents)},0,this);A={position:CKEDITOR.env.ie6Compat?"absolute":"fixed",top:0,visibility:"hidden"};A["rtl"==v?"right":"left"]=0;this.parts.dialog.setStyles(A);CKEDITOR.event.call(this);this.definition=t=CKEDITOR.fire("dialogDefinition",
{name:e,definition:t},d).definition;if(!("removeDialogTabs"in d._)&&d.config.removeDialogTabs){A=d.config.removeDialogTabs.split(";");for(v=0;v<A.length;v++)if(y=A[v].split(":"),2==y.length){var x=y[0];z[x]||(z[x]=[]);z[x].push(y[1])}d._.removeDialogTabs=z}if(d._.removeDialogTabs&&(z=d._.removeDialogTabs[e]))for(v=0;v<z.length;v++)t.removeContents(z[v]);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){d.fire("saveSnapshot");
setTimeout(function(){d.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 K=this,u=function(a){var b=K._.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(b){u(function(c){if(c.validate){var d=c.validate(this),f="string"==typeof d||!1===d;f&&(b.data.hide=!1,b.stop());a.call(c,!f,"string"==typeof d?
d:void 0);return f}})},this,null,0);this.on("cancel",function(a){u(function(b){if(b.isChanged())return d.config.dialog_noConfirmCancel||confirm(d.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=m;var B=this._.element;d.focusManager.add(B,1);this.on("show",function(){B.on("keydown",n,this);if(CKEDITOR.env.gecko)B.on("keypress",r,this)});this.on("hide",
function(){B.removeListener("keydown",n);CKEDITOR.env.gecko&&B.removeListener("keypress",r);u(function(a){h.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(){k();var a=1<K._.pageCount;d.config.dialog_startupFocusTab&&a?(K._.tabBarMode=!0,K._.tabs[K._.currentTabId][0].focus(),K._.currentFocusIndex=-1):this._.hasFocus||(this._.currentFocusIndex=a?-1:this._.focusList.length-1,t.onFocus?
(a=t.onFocus.call(this))&&a.focus():m(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);c(this);f(this);(new CKEDITOR.dom.text(t.title,CKEDITOR.document)).appendTo(this.parts.title);for(v=0;v<t.contents.length;v++)(z=t.contents[v])&&this.addPage(z);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,m(1)),a.data.preventDefault())},this);v=[];z=CKEDITOR.dialog._.uiElementBuilders.hbox.build(this,{type:"hbox",className:"cke_dialog_footer_buttons",widths:[],children:t.buttons},v).getChild();this.parts.footer.setHtml(v.join(""));for(v=0;v<z.length;v++)this._.buttons[z[v].id]=z[v]};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,e="fixed"==d.getComputedStyle("position");CKEDITOR.env.ie&&d.setStyle("zoom","100%");e&&this._.position&&this._.position.x==a&&this._.position.y==b||(this._.position={x:a,y:b},e||(e=CKEDITOR.document.getWindow().getScrollPosition(),a+=e.x,b+=e.y),f&&(e=this.getSize(),a=CKEDITOR.document.getWindow().getViewPaneSize().width-e.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();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,t(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",D);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,e=0;if(d){for(var g in this._.contents[a.id]){var h=this._.contents[a.id][g];"hbox"!=h.type&&"vbox"!=h.type&&h.getInputElement()&&(h.requiredContent&&!this._.editor.activeFilter.check(h.requiredContent)?h.disable():(h.enable(),e++))}!e||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();
k(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(L(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 x(this._.editor);if(CKEDITOR.dialog._.currentTop=this._.parentDialog)CKEDITOR.dialog._.currentZIndex-=10;else{CKEDITOR.dialog._.currentZIndex=null;a.removeListener("keydown",D);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]={},e=d.getChild(),
g=0;d=e.shift();)d.notAllowed||"hbox"==d.type||"vbox"==d.type||g++,f[d.id]=d,"function"==typeof d.getChild&&e.push.apply(e,d.getChild());g||(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&&(G(this,this,"CTRL+"+a.accessKey,P,I),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 b in this._.tabs){var c=this._.tabs[b][0],d=this._.tabs[b][1];b!=a&&(c.removeClass("cke_dialog_tab_selected"),d.hide());d.setAttribute("aria-hidden",b!=a)}var f=this._.tabs[a];f[0].addClass("cke_dialog_tab_selected");CKEDITOR.env.ie6Compat||CKEDITOR.env.ie7Compat?(e(f[1]),f[1].show(),setTimeout(function(){e(f[1],1)},0)):f[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(a){var c=this._.tabs[a]&&this._.tabs[a][0];c&&1!=this._.pageCount&&c.isVisible()&&(a==this._.currentTabId&&this.selectPage(b.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 n(this,a,b));else{this._.focusList.splice(b,0,new n(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 q={resizable:CKEDITOR.DIALOG_RESIZE_BOTH,minWidth:600,minHeight:400,buttons:[CKEDITOR.dialog.okButton,CKEDITOR.dialog.cancelButton]},y=function(a,b,c){for(var d=0,f;f=a[d];d++)if(f.id==b||c&&f[c]&&(f=y(f[c],
b,c)))return f;return null},v=function(a,b,c,d,f){if(c){for(var e=0,g;g=a[e];e++){if(g.id==c)return a.splice(e,0,b),b;if(d&&g[d]&&(g=v(g[d],b,c,d,!0)))return g}if(f)return null}a.push(b);return b},z=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=z(f[c],b,c)))return f}return null},p=function(a,b){this.dialog=a;for(var c=b.contents,f=0,e;e=c[f];f++)c[f]=e&&new d(a,e);CKEDITOR.tools.extend(this,b)};p.prototype={getContents:function(a){return y(this.contents,
a)},getButton:function(a){return y(this.buttons,a)},addContents:function(a,b){return v(this.contents,a,b)},addButton:function(a,b){return v(this.buttons,a,b)},removeContents:function(a){z(this.contents,a)},removeButton:function(a){z(this.buttons,a)}};d.prototype={get:function(a){return y(this.elements,a,"children")},add:function(a,b){return v(this.elements,a,b,"children")},remove:function(a){z(this.elements,a,"children")}};var u,B={},w,C={},D=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=C[(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=C[(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()))},G=function(a,b,c,d,f){(C[c]||(C[c]=[])).push({uiElement:a,dialog:b,key:c,keyup:f||a.accessKeyUp,keydown:d||a.accessKeyDown})},L=function(a){for(var b in C){for(var c=C[b],d=c.length-1;0<=d;d--)c[d].dialog!=a&&c[d].uiElement!=a||c.splice(d,1);0===c.length&&delete C[b]}},I=function(a,b){a._.accessKeyMap[b]&&a.selectPage(a._.accessKeyMap[b])},P=function(){};(function(){CKEDITOR.ui.dialog={uiElement:function(a,b,c,d,f,e,g){if(!(4>arguments.length)){var h=(d.call?d(b):d)||"div",
k=["\x3c",h," "],m=(f&&f.call?f(b):f)||{},l=(e&&e.call?e(b):e)||{},n=(g&&g.call?g.call(this,a,b):g)||"",p=this.domId=l.id||CKEDITOR.tools.getNextId()+"_uiElement";b.requiredContent&&!a.getParentEditor().filter.check(b.requiredContent)&&(m.display="none",this.notAllowed=!0);l.id=p;var q={};b.type&&(q["cke_dialog_ui_"+b.type]=1);b.className&&(q[b.className]=1);b.disabled&&(q.cke_disabled=1);for(var r=l["class"]&&l["class"].split?l["class"].split(" "):[],p=0;p<r.length;p++)r[p]&&(q[r[p]]=1);r=[];for(p in q)r.push(p);
l["class"]=r.join(" ");b.title&&(l.title=b.title);q=(b.style||"").split(";");b.align&&(r=b.align,m["margin-left"]="left"==r?0:"auto",m["margin-right"]="right"==r?0:"auto");for(p in m)q.push(p+":"+m[p]);b.hidden&&q.push("display:none");for(p=q.length-1;0<=p;p--)""===q[p]&&q.splice(p,1);0<q.length&&(l.style=(l.style?l.style+"; ":"")+q.join("; "));for(p in l)k.push(p+'\x3d"'+CKEDITOR.tools.htmlEncode(l[p])+'" ');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&&G(this,a,"CTRL+"+b.accessKey);var t=this;a.on("load",function(){var b=t.getInputElement();if(b){var c=t.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;t.fire("focus");c&&this.addClass(c)});b.on("blur",function(){t.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=t.focusIndex}))}},hbox:function(a,b,c,d,f){if(!(4>arguments.length)){this._||(this._={});var e=this._.children=b,g=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" ');g?g[k]&&d.push("width:"+A(g[k])):d.push("width:"+Math.floor(100/c.length)+"%");h&&d.push("height:"+A(h));f&&void 0!==f.padding&&d.push("padding:"+A(f.padding));CKEDITOR.env.ie&&CKEDITOR.env.quirks&&e[k].align&&d.push("text-align:"+e[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 e=this._.children=b,g=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:"+A(g||"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" ');g&&k.push("width:"+A(g||"100%"));h?k.push("height:"+A(h[d])):f&&f.expand&&k.push("height:"+Math.floor(100/c.length)+"%");f&&void 0!==f.padding&&k.push("padding:"+A(f.padding));CKEDITOR.env.ie&&CKEDITOR.env.quirks&&e[d].align&&k.push("text-align:"+e[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,e=[],g=[],h=0;h<d.length&&(f=d[h]);h++){var k=[];e.push(k);g.push(CKEDITOR.dialog._.uiElementBuilders[f.type].build(a,f,k))}return new CKEDITOR.ui.dialog[b.type](a,g,e,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){a.openDialog(this.dialogName)},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,e=/^(\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=[],e;for(e=0;e<a.length;e++)if("function"==typeof a[e])f.push(a[e]);else break;e<a.length&&"string"==typeof a[e]&&(c=a[e],e++);e<a.length&&"number"==typeof a[e]&&(d=a[e]);var g=d==CKEDITOR.VALIDATE_AND?!0:!1;for(e=0;e<f.length;e++)g=d==CKEDITOR.VALIDATE_AND?g&&f[e](b):g||f[e](b);return g?!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 e.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 B)B[c].remove();B={}}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&&t(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 x(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(b){b.on("doubleclick",function(g){g.data.dialog&&
b.openDialog(g.data.dialog)},null,null,999)}}),"use strict",function(){function b(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 g(a){function c(){var b=a.editable();if(CKEDITOR.plugins.clipboard.isCustomCopyCutSupported){var d=function(b){a.readOnly&&"cut"==b.name||
C.initPasteDataTransfer(b,a);b.data.preventDefault()};b.on("copy",d);b.on("cut",d);b.on("cut",function(){a.readOnly||a.extractSelectedHtml()},null,null,999)}b.on(C.mainPasteEvent,function(a){"beforepaste"==C.mainPasteEvent&&D||u(a)});"beforepaste"==C.mainPasteEvent&&(b.on("paste",function(b){F||(g(),b.data.preventDefault(),u(b),k("paste")||a.openDialog("paste"))}),b.on("contextmenu",h,null,null,0),b.on("beforepaste",function(a){!a.data||a.data.$.ctrlKey||a.data.$.shiftKey||h()},null,null,0));b.on("beforecut",
function(){!D&&l(a)});var e;b.attachListener(CKEDITOR.env.ie?b:a.document.getDocumentElement(),"mouseup",function(){e=setTimeout(function(){B()},0)});a.on("destroy",function(){clearTimeout(e)});b.on("keyup",B)}function d(b){return{type:b,canUndo:"cut"==b,startDisabled:!0,fakeKeystroke:"cut"==b?CKEDITOR.CTRL+88:CKEDITOR.CTRL+67,exec:function(){"cut"==this.type&&l();var b;var c=this.type;if(CKEDITOR.env.ie)b=k(c);else try{b=a.document.$.execCommand(c,!1,null)}catch(d){b=!1}b||a.showNotification(a.lang.clipboard[this.type+
"Error"]);return b}}}function e(){return{canUndo:!1,async:!0,fakeKeystroke:CKEDITOR.CTRL+86,exec:function(a,c){var d=this,f=function(c,f){c&&b(a,c,!!f);a.fire("afterCommandExec",{name:"paste",command:d,returnValue:!!c})};"string"==typeof c?f({dataValue:c,method:"paste",dataTransfer:C.initPasteDataTransfer()},1):a.getClipboardData(f)}}}function g(){F=1;setTimeout(function(){F=0},100)}function h(){D=1;setTimeout(function(){D=0},10)}function k(b){var c=a.document,d=c.getBody(),e=!1,g=function(){e=!0};
d.on(b,g);7<CKEDITOR.env.version?c.$.execCommand(b):c.$.selection.createRange().execCommand(b);d.removeListener(b,g);return e}function l(){if(CKEDITOR.env.ie&&!CKEDITOR.env.quirks){var b=a.getSelection(),c,d,e;b.getType()==CKEDITOR.SELECTION_ELEMENT&&(c=b.getSelectedElement())&&(d=b.getRanges()[0],e=a.document.createText(""),e.insertBefore(c),d.setStartBefore(e),d.setEndAfter(c),b.selectRanges([d]),setTimeout(function(){c.getParent()&&(e.remove(),b.selectElement(c))},0))}}function n(b,c){var d=a.document,
e=a.editable(),g=function(a){a.cancel()},h;if(!d.getById("cke_pastebin")){var k=a.getSelection(),m=k.createBookmarks();CKEDITOR.env.ie&&k.root.fire("selectionchange");var l=new CKEDITOR.dom.element(!CKEDITOR.env.webkit&&!e.is("body")||CKEDITOR.env.ie?"div":"body",d);l.setAttributes({id:"cke_pastebin","data-cke-temp":"1"});var p=0,d=d.getWindow();CKEDITOR.env.webkit?(e.append(l),l.addClass("cke_editable"),e.is("body")||(p="static"!=e.getComputedStyle("position")?e:CKEDITOR.dom.element.get(e.$.offsetParent),
p=p.getDocumentPosition().y)):e.getAscendant(CKEDITOR.env.ie?"body":"html",1).append(l);l.setStyles({position:"absolute",top:d.getScrollPosition().y-p+10+"px",width:"1px",height:Math.max(1,d.getViewPaneSize().height-20)+"px",overflow:"hidden",margin:0,padding:0});CKEDITOR.env.safari&&l.setStyles(CKEDITOR.tools.cssVendorPrefix("user-select","text"));(p=l.getParent().isReadOnly())?(l.setOpacity(0),l.setAttribute("contenteditable",!0)):l.setStyle("ltr"==a.config.contentsLangDirection?"left":"right",
"-10000px");a.on("selectionChange",g,null,null,0);if(CKEDITOR.env.webkit||CKEDITOR.env.gecko)h=e.once("blur",g,null,null,-100);p&&l.focus();p=new CKEDITOR.dom.range(l);p.selectNodeContents(l);var q=p.select();CKEDITOR.env.ie&&(h=e.once("blur",function(){a.lockSelection(q)}));var r=CKEDITOR.document.getWindow().getScrollPosition().y;setTimeout(function(){CKEDITOR.env.webkit&&(CKEDITOR.document.getBody().$.scrollTop=r);h&&h.removeListener();CKEDITOR.env.ie&&e.focus();k.selectBookmarks(m);l.remove();
var b;CKEDITOR.env.webkit&&(b=l.getFirst())&&b.is&&b.hasClass("Apple-style-span")&&(l=b);a.removeListener("selectionChange",g);c(l.getHtml())},0)}}function z(){if("paste"==C.mainPasteEvent)return a.fire("beforePaste",{type:"auto",method:"paste"}),!1;a.focus();g();var b=a.focusManager;b.lock();if(a.editable().fire(C.mainPasteEvent)&&!k("paste"))return b.unlock(),!1;b.unlock();return!0}function p(b){if("wysiwyg"==a.mode)switch(b.data.keyCode){case CKEDITOR.CTRL+86:case CKEDITOR.SHIFT+45:b=a.editable();
g();"paste"==C.mainPasteEvent&&b.fire("beforepaste");break;case CKEDITOR.CTRL+88:case CKEDITOR.SHIFT+46:a.fire("saveSnapshot"),setTimeout(function(){a.fire("saveSnapshot")},50)}}function u(c){var d={type:"auto",method:"paste",dataTransfer:C.initPasteDataTransfer(c)};d.dataTransfer.cacheData();var e=!1!==a.fire("beforePaste",d);e&&C.canClipboardApiBeTrusted(d.dataTransfer,a)?(c.data.preventDefault(),setTimeout(function(){b(a,d)},0)):n(c,function(c){d.dataValue=c.replace(/<span[^>]+data-cke-bookmark[^<]*?<\/span>/ig,
"");e&&b(a,d)})}function B(){if("wysiwyg"==a.mode){var b=w("paste");a.getCommand("cut").setState(w("cut"));a.getCommand("copy").setState(w("copy"));a.getCommand("paste").setState(b);a.fire("pasteState",b)}}function w(b){if(G&&b in{paste:1,cut:1})return CKEDITOR.TRISTATE_DISABLED;if("paste"==b)return CKEDITOR.TRISTATE_OFF;b=a.getSelection();var c=b.getRanges();return b.getType()==CKEDITOR.SELECTION_NONE||1==c.length&&c[0].collapsed?CKEDITOR.TRISTATE_DISABLED:CKEDITOR.TRISTATE_OFF}var C=CKEDITOR.plugins.clipboard,
D=0,F=0,G=0;(function(){a.on("key",p);a.on("contentDom",c);a.on("selectionChange",function(a){G=a.data.selection.getRanges()[0].checkReadOnly();B()});a.contextMenu&&a.contextMenu.addListener(function(a,b){G=b.getRanges()[0].checkReadOnly();return{cut:w("cut"),copy:w("copy"),paste:w("paste")}})})();(function(){function b(c,d,e,g,h){var k=a.lang.clipboard[d];a.addCommand(d,e);a.ui.addButton&&a.ui.addButton(c,{label:k,command:d,toolbar:"clipboard,"+g});a.addMenuItems&&a.addMenuItem(d,{label:k,command:d,
group:"clipboard",order:h})}b("Cut","cut",d("cut"),10,1);b("Copy","copy",d("copy"),20,4);b("Paste","paste",e(),30,8)})();a.getClipboardData=function(b,c){function d(a){a.removeListener();a.cancel();c(a.data)}function e(a){a.removeListener();a.cancel();m=!0;c({type:k,dataValue:a.data.dataValue,dataTransfer:a.data.dataTransfer,method:"paste"})}function g(){this.customTitle=b&&b.title}var h=!1,k="auto",m=!1;c||(c=b,b=null);a.on("paste",d,null,null,0);a.on("beforePaste",function(a){a.removeListener();
h=!0;k=a.data.type},null,null,1E3);!1===z()&&(a.removeListener("paste",d),h&&a.fire("pasteDialog",g)?(a.on("pasteDialogCommit",e),a.on("dialogHide",function(a){a.removeListener();a.data.removeListener("pasteDialogCommit",e);setTimeout(function(){m||c(null)},10)})):c(null))}}function e(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 a(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 n(a,b)}function h(){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 n(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 k(a){a.data.preventDefault();a.data.$.dataTransfer.dropEffect="none"}function d(a){var c=CKEDITOR.plugins.clipboard;a.on("contentDom",function(){function d(c,e,g){e.select();b(a,{dataTransfer:g,
method:"drop"},1);g.sourceEditor.fire("saveSnapshot");g.sourceEditor.editable().extractHtmlFromRange(c);g.sourceEditor.getSelection().selectRanges([c]);g.sourceEditor.fire("saveSnapshot")}function e(d,g){d.select();b(a,{dataTransfer:g,method:"drop"},1);c.resetDragDataTransfer()}function g(b,c,d){var e={$:b.data.$,target:b.data.getTarget()};c&&(e.dragRange=c);d&&(e.dropRange=d);!1===a.fire(b.name,e)&&b.data.preventDefault()}function h(a){a.type!=CKEDITOR.NODE_ELEMENT&&(a=a.getParent());return a.getChildCount()}
var k=a.editable(),l=CKEDITOR.plugins.clipboard.getDropTarget(a),n=a.ui.space("top"),z=a.ui.space("bottom");c.preventDefaultDropOnElement(n);c.preventDefaultDropOnElement(z);k.attachListener(l,"dragstart",g);k.attachListener(a,"dragstart",c.resetDragDataTransfer,c,null,1);k.attachListener(a,"dragstart",function(b){c.initDragDataTransfer(b,a)},null,null,2);k.attachListener(a,"dragstart",function(){var b=c.dragRange=a.getSelection().getRanges()[0];CKEDITOR.env.ie&&10>CKEDITOR.env.version&&(c.dragStartContainerChildCount=
b?h(b.startContainer):null,c.dragEndContainerChildCount=b?h(b.endContainer):null)},null,null,100);k.attachListener(l,"dragend",g);k.attachListener(a,"dragend",c.initDragDataTransfer,c,null,1);k.attachListener(a,"dragend",c.resetDragDataTransfer,c,null,100);k.attachListener(l,"dragover",function(a){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(l,"drop",function(b){if(!b.data.$.defaultPrevented){b.data.preventDefault();var d=b.data.getTarget();if(!d.isReadOnly()||d.type==CKEDITOR.NODE_ELEMENT&&d.is("html")){var d=c.getRangeAtDropPosition(b,a),e=c.dragRange;d&&g(b,e,d)}}},null,null,9999);k.attachListener(a,"drop",c.initDragDataTransfer,c,null,1);k.attachListener(a,"drop",function(b){if(b=b.data){var g=b.dropRange,h=b.dragRange,k=b.dataTransfer;k.getTransferType(a)==CKEDITOR.DATA_TRANSFER_INTERNAL?setTimeout(function(){c.internalDrop(h,
g,k,a)},0):k.getTransferType(a)==CKEDITOR.DATA_TRANSFER_CROSS_EDITORS?d(h,g,k):e(g,k)}},null,null,9999)})}CKEDITOR.plugins.add("clipboard",{requires:"dialog",init:function(b){var c,k=h();b.config.forcePasteAsPlainText?c="plain-text":b.config.pasteFilter?c=b.config.pasteFilter:!CKEDITOR.env.webkit||"pasteFilter"in b.config||(c="semantic-content");b.pasteFilter=k.get(c);g(b);d(b);CKEDITOR.dialog.add("paste",CKEDITOR.getUrl(this.path+"dialogs/paste.js"));if(CKEDITOR.env.gecko){var n=["image/png","image/jpeg",
"image/gif"],A;b.on("paste",function(a){var c=a.data,d=c.dataTransfer;if(!c.dataValue&&"paste"==c.method&&d&&1==d.getFilesCount()&&A!=d.id&&(d=d.getFile(0),-1!=CKEDITOR.tools.indexOf(n,d.type))){var e=new FileReader;e.addEventListener("load",function(){a.data.dataValue='\x3cimg src\x3d"'+e.result+'" /\x3e';b.fire("paste",a.data)},!1);e.addEventListener("abort",function(){b.fire("paste",a.data)},!1);e.addEventListener("error",function(){b.fire("paste",a.data)},!1);e.readAsDataURL(d);A=c.dataTransfer.id;
a.stop()}},null,null,1)}b.on("paste",function(a){a.data.dataTransfer||(a.data.dataTransfer=new CKEDITOR.plugins.clipboard.dataTransfer);if(!a.data.dataValue){var c=a.data.dataTransfer,d=c.getData("text/html");if(d)a.data.dataValue=d,a.data.type="html";else if(d=c.getData("text/plain"))a.data.dataValue=b.editable().transformPlainTextToHtml(d),a.data.type="text"}},null,null,1);b.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,e=new CKEDITOR.dom.element("div");for(e.setHtml(b);1==e.getChildCount()&&
(d=e.getFirst())&&d.type==CKEDITOR.NODE_ELEMENT&&(d.hasClass("cke_editable")||d.hasClass("cke_contents"));)e=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);b.on("paste",function(c){c=c.data;var d=c.type,g=c.dataValue,h,m=b.config.clipboard_defaultContentType||"html",n=c.dataTransfer.getTransferType(b);h="html"==d||"html"==c.preSniffing?"html":e(g);"htmlifiedtext"==h&&(g=a(b.config,g));"text"==d&&"html"==h?g=l(b,g,k.get("plain-text")):n==CKEDITOR.DATA_TRANSFER_EXTERNAL&&b.pasteFilter&&!c.dontFilter&&(g=l(b,g,b.pasteFilter));c.startsWithEOL&&(g='\x3cbr data-cke-eol\x3d"1"\x3e'+g);c.endsWithEOL&&(g+='\x3cbr data-cke-eol\x3d"1"\x3e');"auto"==d&&
(d="html"==h||"html"==m?"html":"text");c.type=d;c.dataValue=g;delete c.preSniffing;delete c.startsWithEOL;delete c.endsWithEOL},null,null,6);b.on("paste",function(a){a=a.data;a.dataValue&&(b.insertHtml(a.dataValue,a.type,a.range),setTimeout(function(){b.fire("afterPaste")},0))},null,null,1E3);b.on("pasteDialog",function(a){setTimeout(function(){b.openDialog("paste",a.data)},0)})}});CKEDITOR.plugins.clipboard={isCustomCopyCutSupported:!CKEDITOR.env.ie&&!CKEDITOR.env.iOS,isCustomDataTypesSupported:!CKEDITOR.env.ie,
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())?!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 e(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 g=b.startContainer;"number"==typeof d&&"number"==typeof c&&g.type==CKEDITOR.NODE_ELEMENT&&(e(a.startContainer,g,c)||e(a.endContainer,g,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(a,c,d,e){var g=CKEDITOR.plugins.clipboard,h=e.editable(),k,l;e.fire("saveSnapshot");e.fire("lockSnapshot",{dontUpdate:1});CKEDITOR.env.ie&&10>CKEDITOR.env.version&&this.fixSplitNodesAfterDrop(a,c,g.dragStartContainerChildCount,g.dragEndContainerChildCount);
(l=this.isDropRangeAffectedByDragRange(a,c))||(k=a.createBookmark(!1));g=c.clone().createBookmark(!1);l&&(k=a.createBookmark(!1));a=k.startNode;c=k.endNode;l=g.startNode;c&&a.getPosition(l)&CKEDITOR.POSITION_PRECEDING&&c.getPosition(l)&CKEDITOR.POSITION_FOLLOWING&&l.insertBefore(a);a=e.createRange();a.moveToBookmark(k);h.extractHtmlFromRange(a,1);c=e.createRange();c.moveToBookmark(g);b(e,{dataTransfer:d,method:"drop",range:c},1);e.fire("unlockSnapshot")},getRangeAtDropPosition:function(a,b){var c=
a.data.$,d=c.clientX,e=c.clientY,g=b.getSelection(!0).getRanges()[0],h=b.createRange();if(a.data.testRange)return a.data.testRange;if(document.caretRangeFromPoint)c=b.document.$.caretRangeFromPoint(d,e),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&&g&&b.editable().hasFocus)return g;if(document.body.createTextRange){b.focus();
c=b.document.getBody().$.createTextRange();try{for(var k=!1,l=0;20>l&&!k;l++){if(!k)try{c.moveToPoint(d,e-l),k=!0}catch(n){}if(!k)try{c.moveToPoint(d,e+l),k=!0}catch(p){}}if(k){var u="cke-temp-"+(new Date).getTime();c.pasteHTML('\x3cspan id\x3d"'+u+'"\x3e​\x3c/span\x3e');var B=b.document.getById(u);h.moveToPosition(B,CKEDITOR.POSITION_BEFORE_START);B.remove()}else{var w=b.document.$.elementFromPoint(d,e),C=new CKEDITOR.dom.element(w),D;if(C.equals(b.editable())||"html"==C.getName())return g&&g.startContainer&&
!g.startContainer.equals(b.editable())?g:null;D=C.getClientRect();d<D.left?h.setStartAt(C,CKEDITOR.POSITION_AFTER_START):h.setStartAt(C,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);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=new this.dataTransfer(a.data.$.clipboardData,b);this.copyCutData&&c.id==this.copyCutData.id?(c=this.copyCutData,c.$=a.data.$.clipboardData):this.copyCutData=c;return c}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",k)}};var c=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:[],normalizeType:function(a){a=a.toLowerCase();return"text"==a||"text/plain"==a?"Text":"url"==a?"URL":a}};this.id=this.getData(c);this.id||(this.id="Text"==c?"":"cke-"+CKEDITOR.tools.getUniqueId());if("Text"!=c)try{this.$.setData(c,this.id)}catch(d){}b&&(this.sourceEditor=
b,this.setData("text/html",b.getSelectedHtml(1)),"Text"==c||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){a=this._.normalizeType(a);var b=this._.data[a];if(void 0===b||null===b||""===b)try{b=this.$.getData(a)}catch(c){}if(void 0===b||null===b||""===b)b="";"text/html"==a?(b=b.replace(this._.metaRegExp,
""),(a=this._.bodyRegExp.exec(b))&&a.length&&(b=a[1],b=b.replace(this._.fragmentRegExp,""))):"Text"==a&&CKEDITOR.env.gecko&&this.getFilesCount()&&"file://"==b.substring(0,7)&&(b="");return b},setData:function(a,b){a=this._.normalizeType(a);this._.data[a]=b;if(CKEDITOR.plugins.clipboard.isCustomDataTypesSupported||"URL"==a||"Text"==a){"Text"==c&&"Text"==a&&(this.id=b);try{this.$.setData(a,b)}catch(d){}}},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);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;for(b in this._.data)a[b]=1;if(this.$)if(CKEDITOR.plugins.clipboard.isCustomDataTypesSupported){if(this.$.types)for(var d=
0;d<this.$.types.length;d++)a[this.$.types[d]]=1}else a.Text=1,a.URL=1;"Text"!=c&&(a[c]=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){}}}}(),function(){var b='\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&&(b+=' onkeypress\x3d"return false;"');CKEDITOR.env.gecko&&(b+=' onblur\x3d"this.style.cssText \x3d this.style.cssText;"');var b=b+(' 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}"'),
b=b+'\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',g=CKEDITOR.addTemplate("buttonArrow",'\x3cspan class\x3d"cke_button_arrow"\x3e'+(CKEDITOR.env.hc?"\x26#9660;":"")+"\x3c/span\x3e"),e=CKEDITOR.addTemplate("button",b);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,b){function l(){var b=a.mode;b&&(b=this.modes[b]?void 0!==y[b]?y[b]:CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,b=a.readOnly&&!this.readOnly?CKEDITOR.TRISTATE_DISABLED:
b,this.setState(b),this.refresh&&this.refresh())}var n=CKEDITOR.env,k=this._.id=CKEDITOR.tools.getNextId(),d="",c=this.command,f,m,t;this._.editor=a;var x={id:k,button:this,editor:a,focus:function(){CKEDITOR.document.getById(k).focus()},execute:function(){this.button.click(a)},attach:function(a){this.button.attach(a)}},A=CKEDITOR.tools.addFunction(function(a){if(x.onkey)return a=new CKEDITOR.dom.event(a),!1!==x.onkey(x,a.getKeystroke())}),r=CKEDITOR.tools.addFunction(function(a){var b;x.onfocus&&
(b=!1!==x.onfocus(x,new CKEDITOR.dom.event(a)));return b}),q=0;x.clickFn=f=CKEDITOR.tools.addFunction(function(){q&&(a.unlockSelection(1),q=0);x.execute();n.iOS&&a.focus()});if(this.modes){var y={};a.on("beforeModeUnload",function(){a.mode&&this._.state!=CKEDITOR.TRISTATE_DISABLED&&(y[a.mode]=this._.state)},this);a.on("activeFilterChange",l,this);a.on("mode",l,this);!this.readOnly&&a.on("readOnly",l,this)}else c&&(c=a.getCommand(c))&&(c.on("state",function(){this.setState(c.state)},this),d+=c.state==
CKEDITOR.TRISTATE_ON?"on":c.state==CKEDITOR.TRISTATE_DISABLED?"disabled":"off");if(this.directional)a.on("contentDirChanged",function(b){var c=CKEDITOR.document.getById(this._.id),d=c.getFirst();b=b.data;b!=a.lang.dir?c.addClass("cke_"+b):c.removeClass("cke_ltr").removeClass("cke_rtl");d.setAttribute("style",CKEDITOR.skin.getIconStyle(v,"rtl"==b,this.icon,this.iconOffset))},this);c?(m=a.getCommandKeystroke(c))&&(t=CKEDITOR.tools.keystrokeToString(a.lang.common.keyboard,m)):d+="off";var v=m=this.name||
this.command;this.icon&&!/\./.test(this.icon)&&(v=this.icon,this.icon=null);d={id:k,name:m,iconName:v,label:this.label,cls:this.className||"",state:d,ariaDisabled:"disabled"==d?"true":"false",title:this.title+(t?" ("+t.display+")":""),ariaShortcut:t?a.lang.common.keyboardShortcut+" "+t.aria:"",titleJs:n.gecko&&!n.hc?"":(this.title||"").replace("'",""),hasArrow:this.hasArrow?"true":"false",keydownFn:A,focusFn:r,clickFn:f,style:CKEDITOR.skin.getIconStyle(v,"rtl"==a.lang.dir,this.icon,this.iconOffset),
arrowHtml:this.hasArrow?g.output():""};e.output(d,b);if(this.onRender)this.onRender();return x},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)}}(),CKEDITOR.plugins.add("panelbutton",{requires:"button",onLoad:function(){function b(b){var e=
this._;e.state!=CKEDITOR.TRISTATE_DISABLED&&(this.createPanel(b),e.on?e.panel.hide():e.panel.showBlock(this._.id,this.document.getById(this._.id),4))}CKEDITOR.ui.panelButton=CKEDITOR.tools.createClass({base:CKEDITOR.ui.button,$:function(g){var e=g.panel||{};delete g.panel;this.base(g);this.document=e.parent&&e.parent.getDocument()||CKEDITOR.document;e.block={attributes:e.attributes};this.hasArrow=e.toolbarRelated=!0;this.click=b;this._={panelDefinition:e}},statics:{handler:{create:function(b){return new CKEDITOR.ui.panelButton(b)}}},
proto:{createPanel:function(b){var e=this._;if(!e.panel){var a=this._.panelDefinition,h=this._.panelDefinition.block,l=a.parent||CKEDITOR.document.getBody(),n=this._.panel=new CKEDITOR.ui.floatPanel(b,l,a),a=n.addBlock(e.id,h),k=this;n.onShow=function(){k.className&&this.element.addClass(k.className+"_panel");k.setState(CKEDITOR.TRISTATE_ON);e.on=1;k.editorFocus&&b.focus();if(k.onOpen)k.onOpen()};n.onHide=function(a){k.className&&this.element.getFirst().removeClass(k.className+"_panel");k.setState(k.modes&&
k.modes[b.mode]?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED);e.on=0;if(!a&&k.onClose)k.onClose()};n.onEscape=function(){n.hide(1);k.document.getById(e.id).focus()};if(this.onBlock)this.onBlock(n,a);a.onHide=function(){e.on=0;k.setState(CKEDITOR.TRISTATE_OFF)}}}}})},beforeInit:function(b){b.ui.addHandler(CKEDITOR.UI_PANELBUTTON,CKEDITOR.ui.panelButton.handler)}}),CKEDITOR.UI_PANELBUTTON="panelbutton",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 b=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'),
g=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'),e=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(a,
h){this.getHolderElement=function(){var a=this._.holder;if(!a){if(this.isFramed){var a=this.document.getById(this.id+"_frame"),b=a.getParent(),a=a.getFrameDocument();CKEDITOR.env.iOS&&b.setStyles({overflow:"scroll","-webkit-overflow-scrolling":"touch"});b=CKEDITOR.tools.addFunction(CKEDITOR.tools.bind(function(){this.isLoaded=!0;if(this.onLoad)this.onLoad()},this));a.write(e.output(CKEDITOR.tools.extend({css:CKEDITOR.tools.buildStyleHtml(this.css),onload:"window.parent.CKEDITOR.tools.callFunction("+
b+");"},l)));a.getWindow().$.CKEDITOR=CKEDITOR;a.on("keydown",function(a){var b=a.data.getKeystroke(),d=this.document.getById(this.id).getAttribute("dir");this._.onKeyDown&&!1===this._.onKeyDown(b)?a.data.preventDefault():(27==b||b==("rtl"==d?39:37))&&this.onEscape&&!1===this.onEscape(b)&&a.data.preventDefault()},this);a=a.getBody();a.unselectable();CKEDITOR.env.air&&CKEDITOR.tools.callFunction(b)}else a=this.document.getById(this.id);this._.holder=a}return a};var l={editorId:a.id,id:this.id,langCode:a.langCode,
dir:a.lang.dir,cls:this.className,frame:"",env:CKEDITOR.env.cssClass,"z-index":a.config.baseFloatZIndex+1};if(this.isFramed){var n=CKEDITOR.env.air?"javascript:void(0)":CKEDITOR.env.ie?"javascript:void(function(){"+encodeURIComponent("document.open();("+CKEDITOR.tools.fixDomain+")();document.close();")+"}())":"";l.frame=g.output({id:this.id+"_frame",src:n})}n=b.output(l);h&&h.push(n);return n},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))}},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 g=this._.focusIndex,e=this.element.getElementsByTag("a"),k;k=e.getItem(++g);)if(k.getAttribute("_cke_focus")&&k.$.offsetWidth){this._.focusIndex=g;k.focus();break}return k||
b?!1:(this._.focusIndex=-1,this.onKeyDown(a,1));case "prev":g=this._.focusIndex;for(e=this.element.getElementsByTag("a");0<g&&(k=e.getItem(--g));){if(k.getAttribute("_cke_focus")&&k.$.offsetWidth){this._.focusIndex=g;k.focus();break}k=null}return k||b?!1:(this._.focusIndex=e.count(),this.onKeyDown(a,1));case "click":case "mouseup":return g=this._.focusIndex,(k=0<=g&&this.element.getElementsByTag("a").getItem(g))&&(k.$[e]?k.$[e]():k.$["on"+e]()),!1}return!0}}})}(),CKEDITOR.plugins.add("floatpanel",
{requires:"panel"}),function(){function b(b,a,h,l,n){n=CKEDITOR.tools.genKey(a.getUniqueId(),h.getUniqueId(),b.lang.dir,b.uiColor||"",l.css||"",n||"");var k=g[n];k||(k=g[n]=new CKEDITOR.ui.panel(a,l),k.element=h.append(CKEDITOR.dom.element.createFromHtml(k.render(b),a)),k.element.setStyles({display:"none",position:"absolute"}));return k}var g={};CKEDITOR.ui.floatPanel=CKEDITOR.tools.createClass({$:function(e,a,g,l){function n(){f.hide()}g.forceIFrame=1;g.toolbarRelated&&e.elementMode==CKEDITOR.ELEMENT_MODE_INLINE&&
(a=CKEDITOR.document.getById("cke_"+e.name));var k=a.getDocument();l=b(e,k,a,g,l||0);var d=l.element,c=d.getFirst(),f=this;d.disableContextMenu();this.element=d;this._={editor:e,panel:l,parentElement:a,definition:g,document:k,iframe:c,children:[],dir:e.lang.dir,showBlockParams:null};e.on("mode",n);e.on("resize",n);k.getWindow().on("resize",function(){this.reposition()},this)},proto:{addBlock:function(b,a){return this._.panel.addBlock(b,a)},addListBlock:function(b,a){return this._.panel.addListBlock(b,
a)},getBlock:function(b){return this._.panel.getBlock(b)},showBlock:function(b,a,g,l,n,k){var d=this._.panel,c=d.showBlock(b);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 m=this.element,f=this._.iframe,f=CKEDITOR.env.ie&&!CKEDITOR.env.edge?f:new CKEDITOR.dom.window(f.$.contentWindow),t=m.getDocument(),x=this._.parentElement.getPositionedAncestor(),
A=a.getDocumentPosition(t),t=x?x.getDocumentPosition(t):{x:0,y:0},r="rtl"==this._.dir,q=A.x+(l||0)-t.x,y=A.y+(n||0)-t.y;!r||1!=g&&4!=g?r||2!=g&&3!=g||(q+=a.$.offsetWidth-1):q+=a.$.offsetWidth;if(3==g||4==g)y+=a.$.offsetHeight-1;this._.panel._.offsetParentId=a.getId();m.setStyles({top:y+"px",left:0,display:""});m.setOpacity(0);m.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);d.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=m;a.removeStyle("width");if(c.autoSize){var b=c.element.getDocument(),b=(CKEDITOR.env.webkit||CKEDITOR.env.edge?c.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=c.element.$.scrollHeight;CKEDITOR.env.ie&&
CKEDITOR.env.quirks&&0<b&&(b+=(a.$.offsetHeight||0)-(a.$.clientHeight||0)+3);a.setStyle("height",b+"px");d._.currentBlock.element.setStyle("display","none").removeStyle("display")}else a.removeStyle("height");r&&(q-=m.$.offsetWidth);m.setStyle("left",q+"px");var b=d.element.getWindow(),a=m.$.getBoundingClientRect(),b=b.getViewPaneSize(),e=a.width||a.right-a.left,f=a.height||a.bottom-a.top,g=r?a.right:b.width-a.left,h=r?b.width-a.right:a.left;r?g<e&&(q=h>e?q+e:b.width>e?q-a.left:q-a.right+b.width):
g<e&&(q=h>e?q-e:b.width>e?q-a.right+b.width:q-a.left);e=a.top;b.height-a.top<f&&(y=e>f?y-f:b.height>f?y-a.bottom+b.height:y-a.top);CKEDITOR.env.ie&&(b=a=new CKEDITOR.dom.element(m.$.offsetParent),"html"==b.getName()&&(b=b.getDocument().getBody()),"rtl"==b.getComputedStyle("direction")&&(q=CKEDITOR.env.ie8Compat?q-2*m.getDocument().getDocumentElement().$.scrollLeft:q-(a.$.scrollWidth-a.$.clientWidth)));var a=m.getFirst(),l;(l=a.getCustomData("activePanel"))&&l.onHide&&l.onHide.call(this,1);a.setCustomData("activePanel",
this);m.setStyles({top:y+"px",left:q+"px"});m.setOpacity(1);k&&k()},this);d.isLoaded?a():d.onLoad=a;CKEDITOR.tools.setTimeout(function(){var a=CKEDITOR.env.webkit&&CKEDITOR.document.getWindow().getScrollPosition().y;this.focus();c.element.focus();CKEDITOR.env.webkit&&(CKEDITOR.document.getBody().$.scrollTop=a);this.allowBlur(!0);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 b=this._.showBlockParams;
this.visible&&this._.showBlockParams&&(this.hide(),this.showBlock.apply(this,b))},focus:function(){if(CKEDITOR.env.webkit){var b=CKEDITOR.document.getActive();b&&!b.equals(this._.iframe)&&b.$.blur()}(this._.lastFocused||this._.iframe.getFrameDocument().getWindow()).focus()},blur:function(){var b=this._.iframe.getFrameDocument().getActive();b&&b.is("a")&&(this._.lastFocused=b)},hide:function(b){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(b=b&&this._.returnFocus)CKEDITOR.env.webkit&&b.type&&b.getWindow().$.focus(),b.focus();delete this._.lastFocused;this._.showBlockParams=null;this._.editor.fire("panelHide",this)}},allowBlur:function(b){var a=this._.panel;void 0!==b&&(a.allowBlur=b);return a.allowBlur},showAsChild:function(b,a,g,l,n,k){if(this._.activeChild!=b||b._.panel._.offsetParentId!=g.getId())this.hideChild(),b.onHide=
CKEDITOR.tools.bind(function(){CKEDITOR.tools.setTimeout(function(){this._.focused||this.hide()},0,this)},this),this._.activeChild=b,this._.focused=!1,b.showBlock(a,g,l,n,k),this.blur(),(CKEDITOR.env.ie7Compat||CKEDITOR.env.ie6Compat)&&setTimeout(function(){b.element.getChild(0).$.style.cssText+=""},100)},hideChild:function(b){var a=this._.activeChild;a&&(delete a.onHide,delete this._.activeChild,a.hide(),b&&this.focus())}}});CKEDITOR.on("instanceDestroyed",function(){var b=CKEDITOR.tools.isEmpty(CKEDITOR.instances),
a;for(a in g){var h=g[a];b?h.destroy():h.element.hide()}b&&(g={})})}(),CKEDITOR.plugins.add("colorbutton",{requires:"panelbutton,floatpanel",init:function(b){function g(a,c,f,g,k){var n=new CKEDITOR.style(h["colorButton_"+c+"Style"]),A=CKEDITOR.tools.getNextId()+"_colorBox";k=k||{};b.ui.add(a,CKEDITOR.UI_PANELBUTTON,{label:f,title:f,modes:{wysiwyg:1},editorFocus:0,toolbar:"colors,"+g,allowedContent:n,requiredContent:n,contentTransformations:k.contentTransformations,panel:{css:CKEDITOR.skin.getPath("editor"),
attributes:{role:"listbox","aria-label":l.panelTitle}},onBlock:function(a,d){d.autoSize=!0;d.element.addClass("cke_colorblock");d.element.setHtml(e(a,c,A));d.element.getDocument().getBody().setStyle("overflow","hidden");CKEDITOR.ui.fire("ready",this);var f=d.keys,g="rtl"==b.lang.dir;f[g?37:39]="next";f[40]="next";f[9]="next";f[g?39:37]="prev";f[38]="prev";f[CKEDITOR.SHIFT+9]="prev";f[32]="click"},refresh:function(){b.activeFilter.check(n)||this.setState(CKEDITOR.TRISTATE_DISABLED)},onOpen:function(){var a=
b.getSelection(),a=a&&a.getStartElement(),a=b.elementPath(a),d;if(a){a=a.block||a.blockLimit||b.document.getBody();do d=a&&a.getComputedStyle("back"==c?"background-color":"color")||"transparent";while("back"==c&&"transparent"==d&&a&&(a=a.getParent()));d&&"transparent"!=d||(d="#ffffff");!1!==h.colorButton_enableAutomatic&&this._.panel._.iframe.getFrameDocument().getById(A).setStyle("background-color",d);return d}}})}function e(d,c,e){var g=[],k=h.colorButton_colors.split(","),n=h.colorButton_colorsPerRow||
6,A=b.plugins.colordialog&&!1!==h.colorButton_enableMore,r=k.length+(A?2:1),q=CKEDITOR.tools.addFunction(function(c,e){function f(a){this.removeListener("ok",f);this.removeListener("cancel",f);"ok"==a.name&&g(this.getContentElement("picker","selectedColor").getValue(),e)}var g=arguments.callee;if("?"==c)b.openDialog("colordialog",function(){this.on("ok",f);this.on("cancel",f)});else{b.focus();d.hide();b.fire("saveSnapshot");b.removeStyle(new CKEDITOR.style(h["colorButton_"+e+"Style"],{color:"inherit"}));
if(c){var k=h["colorButton_"+e+"Style"];k.childRule="back"==e?function(b){return a(b)}:function(b){return!(b.is("a")||b.getElementsByTag("a").count())||a(b)};b.applyStyle(new CKEDITOR.style(k,{color:c}))}b.fire("saveSnapshot")}});!1!==h.colorButton_enableAutomatic&&g.push('\x3ca class\x3d"cke_colorauto" _cke_focus\x3d1 hidefocus\x3dtrue title\x3d"',l.auto,'" onclick\x3d"CKEDITOR.tools.callFunction(',q,",null,'",c,"');return false;\" href\x3d\"javascript:void('",l.auto,'\')" role\x3d"option" aria-posinset\x3d"1" aria-setsize\x3d"',
r,'"\x3e\x3ctable role\x3d"presentation" cellspacing\x3d0 cellpadding\x3d0 width\x3d"100%"\x3e\x3ctr\x3e\x3ctd colspan\x3d"'+n+'" align\x3d"center"\x3e\x3cspan class\x3d"cke_colorbox" id\x3d"',e,'"\x3e\x3c/span\x3e',l.auto,"\x3c/td\x3e\x3c/tr\x3e\x3c/table\x3e\x3c/a\x3e");g.push('\x3ctable role\x3d"presentation" cellspacing\x3d0 cellpadding\x3d0 width\x3d"100%"\x3e');for(e=0;e<k.length;e++){0===e%n&&g.push("\x3c/tr\x3e\x3ctr\x3e");var y=k[e].split("/"),v=y[0],z=y[1]||v;y[1]||(v="#"+v.replace(/^(.)(.)(.)$/,
"$1$1$2$2$3$3"));y=b.lang.colorbutton.colors[z]||z;g.push('\x3ctd\x3e\x3ca class\x3d"cke_colorbox" _cke_focus\x3d1 hidefocus\x3dtrue title\x3d"',y,'" onclick\x3d"CKEDITOR.tools.callFunction(',q,",'",v,"','",c,"'); return false;\" href\x3d\"javascript:void('",y,'\')" role\x3d"option" aria-posinset\x3d"',e+2,'" aria-setsize\x3d"',r,'"\x3e\x3cspan class\x3d"cke_colorbox" style\x3d"background-color:#',z,'"\x3e\x3c/span\x3e\x3c/a\x3e\x3c/td\x3e')}A&&g.push('\x3c/tr\x3e\x3ctr\x3e\x3ctd colspan\x3d"'+n+
'" align\x3d"center"\x3e\x3ca class\x3d"cke_colormore" _cke_focus\x3d1 hidefocus\x3dtrue title\x3d"',l.more,'" onclick\x3d"CKEDITOR.tools.callFunction(',q,",'?','",c,"');return false;\" href\x3d\"javascript:void('",l.more,"')\"",' role\x3d"option" aria-posinset\x3d"',r,'" aria-setsize\x3d"',r,'"\x3e',l.more,"\x3c/a\x3e\x3c/td\x3e");g.push("\x3c/tr\x3e\x3c/table\x3e");return g.join("")}function a(a){return"false"==a.getAttribute("contentEditable")||a.getAttribute("data-nostyle")}var h=b.config,l=b.lang.colorbutton;
if(!CKEDITOR.env.hc){g("TextColor","fore",l.textColorTitle,10,{contentTransformations:[[{element:"font",check:"span{color}",left:function(a){return!!a.attributes.color},right:function(a){a.name="span";a.attributes.color&&(a.styles.color=a.attributes.color);delete a.attributes.color}}]]});var n={},k=b.config.colorButton_normalizeBackground;if(void 0===k||k)n.contentTransformations=[[{element:"span",left:function(a){var b=CKEDITOR.tools;if("span"!=a.name||!a.styles||!a.styles.background)return!1;a=
b.style.parse.background(a.styles.background);return a.color&&1===b.objectKeys(a).length},right:function(a){var c=(new CKEDITOR.style(b.config.colorButton_backStyle,{color:a.styles.background})).getDefinition();a.name=c.element;a.styles=c.styles;a.attributes=c.attributes||{};return a}}]];g("BGColor","back",l.bgColorTitle,20,n)}}}),CKEDITOR.config.colorButton_colors="1ABC9C,2ECC71,3498DB,9B59B6,4E5F70,F1C40F,16A085,27AE60,2980B9,8E44AD,2C3E50,F39C12,E67E22,E74C3C,ECF0F1,95A5A6,DDD,FFF,D35400,C0392B,BDC3C7,7F8C8D,999,000",
CKEDITOR.config.colorButton_foreStyle={element:"span",styles:{color:"#(color)"},overrides:[{element:"font",attributes:{color:null}}]},CKEDITOR.config.colorButton_backStyle={element:"span",styles:{"background-color":"#(color)"}},CKEDITOR.plugins.colordialog={requires:"dialog",init:function(b){var g=new CKEDITOR.dialogCommand("colordialog");g.editorFocus=!1;b.addCommand("colordialog",g);CKEDITOR.dialog.add("colordialog",this.path+"dialogs/colordialog.js");b.getColorFromDialog=function(e,a){var g=function(b){this.removeListener("ok",
g);this.removeListener("cancel",g);b="ok"==b.name?this.getValueOf("picker","selectedColor"):null;e.call(a,b)},l=function(a){a.on("ok",g);a.on("cancel",g)};b.execCommand("colordialog");if(b._.storedDialogs&&b._.storedDialogs.colordialog)l(b._.storedDialogs.colordialog);else CKEDITOR.on("dialogDefinition",function(a){if("colordialog"==a.data.name){var b=a.data.definition;a.removeListener();b.onLoad=CKEDITOR.tools.override(b.onLoad,function(a){return function(){l(this);b.onLoad=a;"function"==typeof a&&
a.call(this)}})}})}}},CKEDITOR.plugins.add("colordialog",CKEDITOR.plugins.colordialog),CKEDITOR.plugins.add("divarea",{afterInit:function(b){b.addMode("wysiwyg",function(g){var e=CKEDITOR.dom.element.createFromHtml('\x3cdiv class\x3d"cke_wysiwyg_div cke_reset cke_enable_context_menu" hidefocus\x3d"true"\x3e\x3c/div\x3e');b.ui.space("contents").append(e);e=b.editable(e);e.detach=CKEDITOR.tools.override(e.detach,function(a){return function(){a.apply(this,arguments);this.remove()}});b.setData(b.getData(1),
g);b.fire("contentDom")})}}),function(){function b(b,e){function n(a){a=f.list[a];var c;a.equals(b.editable())||"true"==a.getAttribute("contenteditable")?(c=b.createRange(),c.selectNodeContents(a),c=c.select()):(c=b.getSelection(),c.selectElement(a));CKEDITOR.env.ie&&b.fire("selectionChange",{selection:c,path:new CKEDITOR.dom.elementPath(a)});b.focus()}function k(){c&&c.setHtml('\x3cspan class\x3d"cke_path_empty"\x3e\x26nbsp;\x3c/span\x3e');delete f.list}var d=b.ui.spaceId("path"),c,f=b._.elementsPath,
m=f.idBase;e.html+='\x3cspan id\x3d"'+d+'_label" class\x3d"cke_voice_label"\x3e'+b.lang.elementspath.eleLabel+'\x3c/span\x3e\x3cspan id\x3d"'+d+'" class\x3d"cke_path" role\x3d"group" aria-labelledby\x3d"'+d+'_label"\x3e\x3cspan class\x3d"cke_path_empty"\x3e\x26nbsp;\x3c/span\x3e\x3c/span\x3e';b.on("uiReady",function(){var a=b.ui.space("path");a&&b.focusManager.add(a,1)});f.onClick=n;var t=CKEDITOR.tools.addFunction(n),x=CKEDITOR.tools.addFunction(function(a,c){var d=f.idBase,e;c=new CKEDITOR.dom.event(c);
e="rtl"==b.lang.dir;switch(c.getKeystroke()){case e?39:37:case 9:return(e=CKEDITOR.document.getById(d+(a+1)))||(e=CKEDITOR.document.getById(d+"0")),e.focus(),!1;case e?37:39:case CKEDITOR.SHIFT+9:return(e=CKEDITOR.document.getById(d+(a-1)))||(e=CKEDITOR.document.getById(d+(f.list.length-1))),e.focus(),!1;case 27:return b.focus(),!1;case 13:case 32:return n(a),!1}return!0});b.on("selectionChange",function(){for(var e=[],g=f.list=[],k=[],l=f.filters,n=!0,z=b.elementPath().elements,p,u=z.length;u--;){var B=
z[u],w=0;p=B.data("cke-display-name")?B.data("cke-display-name"):B.data("cke-real-element-type")?B.data("cke-real-element-type"):B.getName();(n=B.hasAttribute("contenteditable")?"true"==B.getAttribute("contenteditable"):n)||B.hasAttribute("contenteditable")||(w=1);for(var C=0;C<l.length;C++){var D=l[C](B,p);if(!1===D){w=1;break}p=D||p}w||(g.unshift(B),k.unshift(p))}g=g.length;for(l=0;l<g;l++)p=k[l],n=b.lang.elementspath.eleTitle.replace(/%1/,p),p=a.output({id:m+l,label:n,text:p,jsTitle:"javascript:void('"+
p+"')",index:l,keyDownFn:x,clickFn:t}),e.unshift(p);c||(c=CKEDITOR.document.getById(d));k=c;k.setHtml(e.join("")+'\x3cspan class\x3d"cke_path_empty"\x3e\x26nbsp;\x3c/span\x3e');b.fire("elementsPathUpdate",{space:k})});b.on("readOnly",k);b.on("contentDomUnload",k);b.addCommand("elementsPathFocus",g.toolbarFocus);b.setKeystroke(CKEDITOR.ALT+122,"elementsPathFocus")}var g={toolbarFocus:{editorFocus:!1,readOnly:1,exec:function(a){(a=CKEDITOR.document.getById(a._.elementsPath.idBase+"0"))&&a.focus(CKEDITOR.env.ie||
CKEDITOR.env.air)}}},e="";CKEDITOR.env.gecko&&CKEDITOR.env.mac&&(e+=' onkeypress\x3d"return false;"');CKEDITOR.env.gecko&&(e+=' onblur\x3d"this.style.cssText \x3d this.style.cssText;"');var a=CKEDITOR.addTemplate("pathItem",'\x3ca id\x3d"{id}" href\x3d"{jsTitle}" tabindex\x3d"-1" class\x3d"cke_path_item" title\x3d"{label}"'+e+' 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(a){a._.elementsPath={idBase:"cke_elementspath_"+CKEDITOR.tools.getNextNumber()+"_",filters:[]};a.on("uiSpace",function(e){"bottom"==e.data.space&&b(a,e.data)})}})}(),function(){function b(a,b,d){d=a.config.forceEnterMode||d;"wysiwyg"==a.mode&&(b||(b=a.activeEnterMode),a.elementPath().isContextFor("p")||(b=CKEDITOR.ENTER_BR,d=1),a.fire("saveSnapshot"),b==CKEDITOR.ENTER_BR?n(a,b,null,d):k(a,b,null,d),a.fire("saveSnapshot"))}function g(a){a=a.getSelection().getRanges(!0);
for(var b=a.length-1;0<b;b--)a[b].deleteContents();return a[0]}function e(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(a){a.addCommand("enter",{modes:{wysiwyg:1},editorFocus:!1,exec:function(a){b(a)}});a.addCommand("shiftEnter",{modes:{wysiwyg:1},editorFocus:!1,exec:function(a){b(a,
a.activeShiftEnterMode,1)}});a.setKeystroke([[13,"enter"],[CKEDITOR.SHIFT+13,"shiftEnter"]])}});var a=CKEDITOR.dom.walker.whitespaces(),h=CKEDITOR.dom.walker.bookmark();CKEDITOR.plugins.enterkey={enterBlock:function(b,f,k,l){if(k=k||g(b)){k=e(k);var x=k.document,A=k.checkStartOfBlock(),r=k.checkEndOfBlock(),q=b.elementPath(k.startContainer),y=q.block,v=f==CKEDITOR.ENTER_DIV?"div":"p",z;if(A&&r){if(y&&(y.is("li")||y.getParent().is("li"))){y.is("li")||(y=y.getParent());k=y.getParent();z=k.getParent();
l=!y.hasPrevious();var p=!y.hasNext(),v=b.getSelection(),u=v.createBookmarks(),A=y.getDirection(1),r=y.getAttribute("class"),B=y.getAttribute("style"),w=z.getDirection(1)!=A;b=b.enterMode!=CKEDITOR.ENTER_BR||w||B||r;if(z.is("li"))l||p?(l&&p&&k.remove(),y[p?"insertAfter":"insertBefore"](z)):y.breakParent(z);else{if(b)if(q.block.is("li")?(z=x.createElement(f==CKEDITOR.ENTER_P?"p":"div"),w&&z.setAttribute("dir",A),B&&z.setAttribute("style",B),r&&z.setAttribute("class",r),y.moveChildren(z)):z=q.block,
l||p)z[l?"insertBefore":"insertAfter"](k);else y.breakParent(k),z.insertAfter(k);else if(y.appendBogus(!0),l||p)for(;x=y[l?"getFirst":"getLast"]();)x[l?"insertBefore":"insertAfter"](k);else for(y.breakParent(k);x=y.getLast();)x.insertAfter(k);y.remove()}v.selectBookmarks(u);return}if(y&&y.getParent().is("blockquote")){y.breakParent(y.getParent());y.getPrevious().getFirst(CKEDITOR.dom.walker.invisible(1))||y.getPrevious().remove();y.getNext().getFirst(CKEDITOR.dom.walker.invisible(1))||y.getNext().remove();
k.moveToElementEditStart(y);k.select();return}}else if(y&&y.is("pre")&&!r){n(b,f,k,l);return}if(A=k.splitBlock(v)){f=A.previousBlock;y=A.nextBlock;q=A.wasStartOfBlock;b=A.wasEndOfBlock;y?(u=y.getParent(),u.is("li")&&(y.breakParent(u),y.move(y.getNext(),1))):f&&(u=f.getParent())&&u.is("li")&&(f.breakParent(u),u=f.getNext(),k.moveToElementEditStart(u),f.move(f.getPrevious()));if(q||b){if(f){if(f.is("li")||!d.test(f.getName())&&!f.is("pre"))z=f.clone()}else y&&(z=y.clone());z?l&&!z.is("li")&&z.renameNode(v):
u&&u.is("li")?z=u:(z=x.createElement(v),f&&(p=f.getDirection())&&z.setAttribute("dir",p));if(x=A.elementPath)for(l=0,v=x.elements.length;l<v;l++){u=x.elements[l];if(u.equals(x.block)||u.equals(x.blockLimit))break;CKEDITOR.dtd.$removeEmpty[u.getName()]&&(u=u.clone(),z.moveChildren(u),z.append(u))}z.appendBogus();z.getParent()||k.insertNode(z);z.is("li")&&z.removeAttribute("value");!CKEDITOR.env.ie||!q||b&&f.getChildCount()||(k.moveToElementEditStart(b?f:z),k.select());k.moveToElementEditStart(q&&!b?
y:z)}else y.is("li")&&(z=k.clone(),z.selectNodeContents(y),z=new CKEDITOR.dom.walker(z),z.evaluator=function(b){return!(h(b)||a(b)||b.type==CKEDITOR.NODE_ELEMENT&&b.getName()in CKEDITOR.dtd.$inline&&!(b.getName()in CKEDITOR.dtd.$empty))},(u=z.next())&&u.type==CKEDITOR.NODE_ELEMENT&&u.is("ul","ol")&&(CKEDITOR.env.needsBrFiller?x.createElement("br"):x.createText(" ")).insertBefore(u)),y&&k.moveToElementEditStart(y);k.select();k.scrollIntoView()}}},enterBr:function(a,b,e,h){if(e=e||g(a)){var l=e.document,
n=e.checkEndOfBlock(),r=new CKEDITOR.dom.elementPath(a.getSelection().getStartElement()),q=r.block,y=q&&r.block.getName();h||"li"!=y?(!h&&n&&d.test(y)?(n=q.getDirection())?(l=l.createElement("div"),l.setAttribute("dir",n),l.insertAfter(q),e.setStart(l,0)):(l.createElement("br").insertAfter(q),CKEDITOR.env.gecko&&l.createText("").insertAfter(q),e.setStartAt(q.getNext(),CKEDITOR.env.ie?CKEDITOR.POSITION_BEFORE_START:CKEDITOR.POSITION_AFTER_START)):(a="pre"==y&&CKEDITOR.env.ie&&8>CKEDITOR.env.version?
l.createText("\r"):l.createElement("br"),e.deleteContents(),e.insertNode(a),CKEDITOR.env.needsBrFiller?(l.createText("﻿").insertAfter(a),n&&(q||r.blockLimit).appendBogus(),a.getNext().$.nodeValue="",e.setStartAt(a.getNext(),CKEDITOR.POSITION_AFTER_START)):e.setStartAt(a,CKEDITOR.POSITION_AFTER_END)),e.collapse(!0),e.select(),e.scrollIntoView()):k(a,b,e,h)}}};var l=CKEDITOR.plugins.enterkey,n=l.enterBr,k=l.enterBlock,d=/^h[1-6]$/}(),function(){function b(b,e){var a={},h=[],l={nbsp:" ",shy:"­",gt:"\x3e",
lt:"\x3c",amp:"\x26",apos:"'",quot:'"'};b=b.replace(/\b(nbsp|shy|gt|lt|amp|apos|quot)(?:,|$)/g,function(b,d){var g=e?"\x26"+d+";":l[d];a[g]=e?l[d]:"\x26"+d+";";h.push(g);return""});if(!e&&b){b=b.split(",");var n=document.createElement("div"),k;n.innerHTML="\x26"+b.join(";\x26")+";";k=n.innerHTML;n=null;for(n=0;n<k.length;n++){var d=k.charAt(n);a[d]="\x26"+b[n]+";";h.push(d)}}a.regex=h.join(e?"|":"");return a}CKEDITOR.plugins.add("entities",{afterInit:function(g){function e(a){return d[a]}function a(a){return"force"!=
h.entities_processNumerical&&n[a]?n[a]:"\x26#"+a.charCodeAt(0)+";"}var h=g.config;if(g=(g=g.dataProcessor)&&g.htmlFilter){var l=[];!1!==h.basicEntities&&l.push("nbsp,gt,lt,amp");h.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"),
h.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"),h.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"),
h.entities_additional&&l.push(h.entities_additional));var n=b(l.join(",")),k=n.regex?"["+n.regex+"]":"a^";delete n.regex;h.entities&&h.entities_processNumerical&&(k="[^ -~]|"+k);var k=new RegExp(k,"g"),d=b("nbsp,gt,lt,amp,shy",!0),c=new RegExp(d.regex,"g");g.addRules({text:function(b){return b.replace(c,e).replace(k,a)}},{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",function(){function b(a){var b=a.config,l=a.fire("uiSpace",{space:"top",html:""}).html,n=function(){function c(a,b,f){d.setStyle(b,e(f));d.setStyle("position",a)}function f(a){var b=l.getDocumentPosition();switch(a){case "top":c("absolute","top",b.y-v-u);break;case "pin":c("fixed","top",w);break;case "bottom":c("absolute","top",b.y+(q.height||q.bottom-q.top)+u)}k=a}var k,l,r,q,y,v,z,p=b.floatSpaceDockedOffsetX||0,u=b.floatSpaceDockedOffsetY||0,B=b.floatSpacePinnedOffsetX||
0,w=b.floatSpacePinnedOffsetY||0;return function(c){if(l=a.editable()){var m=c&&"focus"==c.name;m&&d.show();a.fire("floatingSpaceLayout",{show:m});d.removeStyle("left");d.removeStyle("right");r=d.getClientRect();q=l.getClientRect();y=g.getViewPaneSize();v=r.height;z="pageXOffset"in g.$?g.$.pageXOffset:CKEDITOR.document.$.documentElement.scrollLeft;k?(v+u<=q.top?f("top"):v+u>y.height-q.bottom?f("pin"):f("bottom"),c=y.width/2,c=b.floatSpacePreferRight?"right":0<q.left&&q.right<y.width&&q.width>r.width?
"rtl"==b.contentsLangDirection?"right":"left":c-q.left>q.right-c?"left":"right",r.width>y.width?(c="left",m=0):(m="left"==c?0<q.left?q.left:0:q.right<y.width?y.width-q.right:0,m+r.width>y.width&&(c="left"==c?"right":"left",m=0)),d.setStyle(c,e(("pin"==k?B:p)+m+("pin"==k?0:"left"==c?z:-z)))):(k="pin",f("pin"),n(c))}}}();if(l){var k=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'),d=CKEDITOR.document.getBody().append(CKEDITOR.dom.element.createFromHtml(k.output({content:l,
id:a.id,langDir:a.lang.dir,langCode:a.langCode,name:a.name,style:"display:none;z-index:"+(b.baseFloatZIndex-1),topId:a.ui.spaceId("top"),voiceLabel:a.title}))),c=CKEDITOR.tools.eventsBuffer(500,n),f=CKEDITOR.tools.eventsBuffer(100,n);d.unselectable();d.on("mousedown",function(a){a=a.data;a.getTarget().hasAscendant("a",1)||a.preventDefault()});a.on("focus",function(b){n(b);a.on("change",c.input);g.on("scroll",f.input);g.on("resize",f.input)});a.on("blur",function(){d.hide();a.removeListener("change",
c.input);g.removeListener("scroll",f.input);g.removeListener("resize",f.input)});a.on("destroy",function(){g.removeListener("scroll",f.input);g.removeListener("resize",f.input);d.clearCustomData();d.remove()});a.focusManager.hasFocus&&d.show();a.focusManager.add(d,1)}}var g=CKEDITOR.document.getWindow(),e=CKEDITOR.tools.cssLength;CKEDITOR.plugins.add("floatingspace",{init:function(a){a.on("loaded",function(){b(this)},null,null,20)}})}(),CKEDITOR.plugins.add("listblock",{requires:"panel",onLoad:function(){var b=
CKEDITOR.addTemplate("panel-list",'\x3cul role\x3d"presentation" class\x3d"cke_panel_list"\x3e{items}\x3c/ul\x3e'),g=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'),e=CKEDITOR.addTemplate("panel-list-group",
'\x3ch1 id\x3d"{id}" class\x3d"cke_panel_grouptitle" role\x3d"presentation" \x3e{label}\x3c/h1\x3e'),a=/\'/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 e=b.attributes||(b.attributes={});(this.multiSelect=!!b.multiSelect)&&(e["aria-multiselectable"]=!0);!e.role&&(e.role="listbox");this.base.apply(this,arguments);
this.element.setAttribute("role",e.role);e=this.keys;e[40]="next";e[9]="next";e[38]="prev";e[CKEDITOR.SHIFT+9]="prev";e[32]=CKEDITOR.env.ie?"mouseup":"click";CKEDITOR.env.ie&&(e[13]="mouseup");this._.pendingHtml=[];this._.pendingList=[];this._.items={};this._.groups={}},_:{close:function(){if(this._.started){var a=b.output({items:this._.pendingList.join("")});this._.pendingList=[];this._.pendingHtml.push(a);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(b,e,n){var k=CKEDITOR.tools.getNextId();this._.started||(this._.started=1,this._.size=this._.size||0);this._.items[b]=k;var d;d=CKEDITOR.tools.htmlEncodeAttr(b).replace(a,"\\'");b={id:k,val:d,onclick:CKEDITOR.env.ie?'onclick\x3d"return false;" onmouseup':"onclick",clickFn:this._.getClick(),title:CKEDITOR.tools.htmlEncodeAttr(n||b),text:e||b};this._.pendingList.push(g.output(b))},startGroup:function(a){this._.close();
var b=CKEDITOR.tools.getNextId();this._.groups[a]=b;this._.pendingHtml.push(e.output({id:b,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,e=this.element.getDocument(),g;for(g in a)e.getById(a[g]).setStyle("display","");for(var d in b)a=e.getById(b[d]),g=a.getNext(),a.setStyle("display",""),g&&"ul"==g.getName()&&g.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)},
unmark:function(a){var b=this.element.getDocument();a=this._.items[a];var e=b.getById(a);e.removeClass("cke_selected");b.getById(a+"_option").removeAttribute("aria-selected");this.onUnmark&&this.onUnmark(e)},unmarkAll:function(){var a=this._.items,b=this.element.getDocument(),e;for(e in a){var g=a[e];b.getById(g).removeClass("cke_selected");b.getById(g+"_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"),e,g=-1;if(a)for(e=this.element.getDocument().getById(this._.items[a]).getFirst();a=b.getItem(++g);){if(a.equals(e)){this._.focusIndex=g;break}}else this.element.focus();e&&setTimeout(function(){e.focus()},0)}}})}}),CKEDITOR.plugins.add("richcombo",{requires:"floatpanel,listblock,button",beforeInit:function(b){b.ui.addHandler(CKEDITOR.UI_RICHCOMBO,CKEDITOR.ui.richCombo.handler)}}),function(){var b='\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&&(b+=' onkeypress\x3d"return false;"');CKEDITOR.env.gecko&&(b+=' onblur\x3d"this.style.cssText \x3d this.style.cssText;"');var b=b+(' 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"),g=CKEDITOR.addTemplate("combo",b);CKEDITOR.UI_RICHCOMBO="richcombo";CKEDITOR.ui.richCombo=
CKEDITOR.tools.createClass({$:function(b){CKEDITOR.tools.extend(this,b,{canGroup:!1,title:b.label,modes:{wysiwyg:1},editorFocus:1});b=this.panel||{};delete this.panel;this.id=CKEDITOR.tools.getNextNumber();this.document=b.parent&&b.parent.getDocument()||CKEDITOR.document;b.className="cke_combopanel";b.block={multiSelect:b.multiSelect,attributes:b.attributes};b.toolbarRelated=!0;this._={panelDefinition:b,items:{}}},proto:{renderHtml:function(b){var a=[];this.render(b,a);return a.join("")},render:function(b,
a){function h(){if(this.getState()!=CKEDITOR.TRISTATE_ON){var a=this.modes[b.mode]?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED;b.readOnly&&!this.readOnly&&(a=CKEDITOR.TRISTATE_DISABLED);this.setState(a);this.setValue("");a!=CKEDITOR.TRISTATE_DISABLED&&this.refresh&&this.refresh()}}var l=CKEDITOR.env,n="cke_"+this.id,k=CKEDITOR.tools.addFunction(function(a){t&&(b.unlockSelection(1),t=0);c.execute(a)},this),d=this,c={id:n,combo:this,focus:function(){CKEDITOR.document.getById(n).getChild(1).focus()},
execute:function(a){var c=d._;if(c.state!=CKEDITOR.TRISTATE_DISABLED)if(d.createPanel(b),c.on)c.panel.hide();else{d.commit();var f=d.getValue();f?c.list.mark(f):c.list.unmarkAll();c.panel.showBlock(d.id,new CKEDITOR.dom.element(a),4)}},clickFn:k};b.on("activeFilterChange",h,this);b.on("mode",h,this);b.on("selectionChange",h,this);!this.readOnly&&b.on("readOnly",h,this);var f=CKEDITOR.tools.addFunction(function(a,d){a=new CKEDITOR.dom.event(a);var f=a.getKeystroke();if(40==f)b.once("panelShow",function(a){a.data._.panel._.currentBlock.onKeyDown(40)});
switch(f){case 13:case 32:case 40:CKEDITOR.tools.callFunction(k,d);break;default:c.onkey(c,f)}a.preventDefault()}),m=CKEDITOR.tools.addFunction(function(){c.onfocus&&c.onfocus()}),t=0;c.keyDownFn=f;l={id:n,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:m,clickFn:k};g.output(l,a);if(this.onRender)this.onRender();return c},createPanel:function(b){if(!this._.panel){var a=this._.panelDefinition,
g=this._.panelDefinition.block,l=a.parent||CKEDITOR.document.getBody(),n="cke_combopanel__"+this.name,k=new CKEDITOR.ui.floatPanel(b,l,a),d=k.addListBlock(this.id,g),c=this;k.onShow=function(){this.element.addClass(n);c.setState(CKEDITOR.TRISTATE_ON);c._.on=1;c.editorFocus&&!b.focusManager.hasFocus&&b.focus();if(c.onOpen)c.onOpen();b.once("panelShow",function(){d.focus(!d.multiSelect&&c.getValue())})};k.onHide=function(a){this.element.removeClass(n);c.setState(c.modes&&c.modes[b.mode]?CKEDITOR.TRISTATE_OFF:
CKEDITOR.TRISTATE_DISABLED);c._.on=0;if(!a&&c.onClose)c.onClose()};k.onEscape=function(){k.hide(1)};d.onClick=function(a,b){c.onClick&&c.onClick.call(c,a,b);k.hide()};this._.panel=k;this._.list=d;k.getBlock(this.id).onHide=function(){c._.on=0;c.setState(CKEDITOR.TRISTATE_OFF)};this.init&&this.init()}},setValue:function(b,a){this._.value=b;var g=this.document.getById("cke_"+this.id+"_text");g&&(b||a?g.removeClass("cke_combo_inlinelabel"):(a=this.label,g.addClass("cke_combo_inlinelabel")),g.setText("undefined"!=
typeof a?a:b))},getValue:function(){return this._.value||""},unmarkAll:function(){this._.list.unmarkAll()},mark:function(b){this._.list.mark(b)},hideItem:function(b){this._.list.hideItem(b)},hideGroup:function(b){this._.list.hideGroup(b)},showAll:function(){this._.list.showAll()},add:function(b,a,g){this._.items[b]=g||b;this._.list.add(b,a,g)},startGroup:function(b){this._.list.startGroup(b)},commit:function(){this._.committed||(this._.list.commit(),this._.committed=1,CKEDITOR.ui.fire("ready",this));
this._.committed=1},setState:function(b){if(this._.state!=b){var a=this.document.getById("cke_"+this.id);a.setState(b,"cke_combo");b==CKEDITOR.TRISTATE_DISABLED?a.setAttribute("aria-disabled",!0):a.removeAttribute("aria-disabled");this._.state=b}},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(b){return new CKEDITOR.ui.richCombo(b)}}}});CKEDITOR.ui.prototype.addRichCombo=function(b,a){this.add(b,CKEDITOR.UI_RICHCOMBO,a)}}(),function(){function b(b,a,h,l,n,k,d,c){var f=b.config,m=new CKEDITOR.style(d),t=n.split(";");n=[];for(var x={},A=0;A<t.length;A++){var r=t[A];if(r){var r=r.split("/"),q={},y=t[A]=r[0];q[h]=n[A]=r[1]||y;x[y]=new CKEDITOR.style(d,q);x[y]._.definition.name=y}else t.splice(A--,1)}b.ui.addRichCombo(a,{label:l.label,title:l.panelTitle,toolbar:"styles,"+
c,allowedContent:m,requiredContent:m,contentTransformations:[[{element:"font",check:"span",left:function(a){return!!a.attributes.size||!!a.attributes.align||!!a.attributes.face},right:function(a){var b=" x-small small medium large x-large xx-large 48px".split(" ");a.name="span";a.attributes.size&&(a.styles["font-size"]=b[a.attributes.size],delete a.attributes.size);a.attributes.align&&(a.styles["text-align"]=a.attributes.align,delete a.attributes.align);a.attributes.face&&(a.styles["font-family"]=
a.attributes.face,delete a.attributes.face)}}]],panel:{css:[CKEDITOR.skin.getPath("editor")].concat(f.contentsCss),multiSelect:!1,attributes:{"aria-label":l.panelTitle}},init:function(){this.startGroup(l.panelTitle);for(var a=0;a<t.length;a++){var b=t[a];this.add(b,x[b].buildPreview(),b)}},onClick:function(a){b.focus();b.fire("saveSnapshot");var c=this.getValue(),d=x[a];if(c&&a!=c){var f=x[c],h=b.getSelection().getRanges()[0];if(h.collapsed){var k=b.elementPath(),m=k.contains(function(a){return f.checkElementRemovable(a)});
if(m){var l=h.checkBoundaryOfElement(m,CKEDITOR.START),n=h.checkBoundaryOfElement(m,CKEDITOR.END);if(l&&n){for(l=h.createBookmark();k=m.getFirst();)k.insertBefore(m);m.remove();h.moveToBookmark(l)}else l||n?h.moveToPosition(m,l?CKEDITOR.POSITION_BEFORE_START:CKEDITOR.POSITION_AFTER_END):(h.splitElement(m),h.moveToPosition(m,CKEDITOR.POSITION_AFTER_END)),g(h,k.elements.slice(),m);b.getSelection().selectRanges([h])}}else b.removeStyle(f)}b[c==a?"removeStyle":"applyStyle"](d);b.fire("saveSnapshot")},
onRender:function(){b.on("selectionChange",function(a){var c=this.getValue();a=a.data.path.elements;for(var d=0,f;d<a.length;d++){f=a[d];for(var g in x)if(x[g].checkElementMatch(f,!0,b)){g!=c&&this.setValue(g);return}}this.setValue("",k)},this)},refresh:function(){b.activeFilter.check(m)||this.setState(CKEDITOR.TRISTATE_DISABLED)}})}function g(b,a,h){var l=a.pop();if(l){if(h)return g(b,a,l.equals(h)?null:h);h=l.clone();b.insertNode(h);b.moveToPosition(h,CKEDITOR.POSITION_AFTER_START);g(b,a)}}CKEDITOR.plugins.add("font",
{requires:"richcombo",init:function(e){var a=e.config;b(e,"Font","family",e.lang.font,a.font_names,a.font_defaultLabel,a.font_style,30);b(e,"FontSize","size",e.lang.font.fontSize,a.fontSize_sizes,a.fontSize_defaultLabel,a.fontSize_style,40)}})}(),CKEDITOR.config.font_names="Arial/Arial, Helvetica, sans-serif;Comic Sans MS/Comic Sans MS, cursive;Courier New/Courier New, Courier, monospace;Georgia/Georgia, serif;Lucida Sans Unicode/Lucida Sans Unicode, Lucida Grande, sans-serif;Tahoma/Tahoma, Geneva, sans-serif;Times New Roman/Times New Roman, Times, serif;Trebuchet MS/Trebuchet MS, Helvetica, sans-serif;Verdana/Verdana, Geneva, sans-serif",
CKEDITOR.config.font_defaultLabel="",CKEDITOR.config.font_style={element:"span",styles:{"font-family":"#(family)"},overrides:[{element:"font",attributes:{face:null}}]},CKEDITOR.config.fontSize_sizes="8/8px;9/9px;10/10px;11/11px;12/12px;14/14px;16/16px;18/18px;20/20px;22/22px;24/24px;26/26px;28/28px;36/36px;48/48px;72/72px",CKEDITOR.config.fontSize_defaultLabel="",CKEDITOR.config.fontSize_style={element:"span",styles:{"font-size":"#(size)"},overrides:[{element:"font",attributes:{size:null}}]},CKEDITOR.plugins.add("htmlwriter",
{init:function(b){var g=new CKEDITOR.htmlWriter;g.forceSimpleAmpersand=b.config.forceSimpleAmpersand;g.indentationChars=b.config.dataIndentationChars||"\t";b.dataProcessor.writer=g}}),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 b=CKEDITOR.dtd,g;for(g in CKEDITOR.tools.extend({},
b.$nonBodyContent,b.$block,b.$listItem,b.$tableContent))this.setRules(g,{indent:!b[g]["#"],breakBeforeOpen:1,breakBeforeClose:!b[g]["#"],breakAfterClose:1,needsSpace:g in b.$block&&!(g 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(b){var g=this._.rules[b];this._.afterCloser&&g&&g.needsSpace&&this._.needsSpace&&
this._.output.push("\n");this._.indent?this.indentation():g&&g.breakBeforeOpen&&(this.lineBreak(),this.indentation());this._.output.push("\x3c",b);this._.afterCloser=0},openTagClose:function(b,g){var e=this._.rules[b];g?(this._.output.push(this.selfClosingEnd),e&&e.breakAfterClose&&(this._.needsSpace=e.needsSpace)):(this._.output.push("\x3e"),e&&e.indent&&(this._.indentation+=this.indentationChars));e&&e.breakAfterOpen&&this.lineBreak();"pre"==b&&(this._.inPre=1)},attribute:function(b,g){"string"==
typeof g&&(this.forceSimpleAmpersand&&(g=g.replace(/&amp;/g,"\x26")),g=CKEDITOR.tools.htmlEncodeAttr(g));this._.output.push(" ",b,'\x3d"',g,'"')},closeTag:function(b){var g=this._.rules[b];g&&g.indent&&(this._.indentation=this._.indentation.substr(this.indentationChars.length));this._.indent?this.indentation():g&&g.breakBeforeClose&&(this.lineBreak(),this.indentation());this._.output.push("\x3c/",b,"\x3e");"pre"==b&&(this._.inPre=0);g&&g.breakAfterClose&&(this.lineBreak(),this._.needsSpace=g.needsSpace);
this._.afterCloser=1},text:function(b){this._.indent&&(this.indentation(),!this._.inPre&&(b=CKEDITOR.tools.ltrim(b)));this._.output.push(b)},comment:function(b){this._.indent&&this.indentation();this._.output.push("\x3c!--",b,"--\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(b,g){var e=this._.rules[b];e?CKEDITOR.tools.extend(e,g,!0):this._.rules[b]=g}}}),function(){function b(a,b){var l,n;b.on("refresh",function(a){var b=[g],c;for(c in a.data.states)b.push(a.data.states[c]);this.setState(CKEDITOR.tools.search(b,e)?e:g)},b,null,100);b.on("exec",function(b){l=a.getSelection();n=l.createBookmarks(1);b.data||(b.data={});b.data.done=!1},b,null,0);b.on("exec",function(){a.forceNextSelectionCheck();
l.selectBookmarks(n)},b,null,100)}var g=CKEDITOR.TRISTATE_DISABLED,e=CKEDITOR.TRISTATE_OFF;CKEDITOR.plugins.add("indent",{init:function(a){var e=CKEDITOR.plugins.indent.genericDefinition;b(a,a.addCommand("indent",new e(!0)));b(a,a.addCommand("outdent",new e));a.ui.addButton&&(a.ui.addButton("Indent",{label:a.lang.indent.indent,command:"indent",directional:!0,toolbar:"indent,20"}),a.ui.addButton("Outdent",{label:a.lang.indent.outdent,command:"outdent",directional:!0,toolbar:"indent,10"}));a.on("dirChanged",
function(b){var e=a.createRange(),g=b.data.node;e.setStartBefore(g);e.setEndAfter(g);for(var d=new CKEDITOR.dom.walker(e),c;c=d.next();)if(c.type==CKEDITOR.NODE_ELEMENT)if(!c.equals(g)&&c.getDirection())e.setStartAfter(c),d=new CKEDITOR.dom.walker(e);else{var f=a.config.indentClasses;if(f)for(var h="ltr"==b.data.dir?["_rtl",""]:["","_rtl"],t=0;t<f.length;t++)c.hasClass(f[t]+h[0])&&(c.removeClass(f[t]+h[0]),c.addClass(f[t]+h[1]));f=c.getStyle("margin-right");h=c.getStyle("margin-left");f?c.setStyle("margin-left",
f):c.removeStyle("margin-left");h?c.setStyle("margin-right",h):c.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 d=a.getCommand(b.relatedGlobal),c;for(c in b.jobs)d.on("exec",function(d){d.data.done||(a.fire("lockSnapshot"),b.execJob(a,c)&&(d.data.done=!0),a.fire("unlockSnapshot"),CKEDITOR.dom.element.clearAllMarkers(b.database))},this,null,c),d.on("refresh",function(d){d.data.states||(d.data.states={});d.data.states[b.name+"@"+c]=b.refreshJob(a,c,d.data.path)},this,null,c);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 e=this.jobs[b];if(e.state!=g)return e.exec.call(this,a)},refreshJob:function(a,b,e){b=this.jobs[b];a.activeFilter.checkFeature(this)?b.state=b.refresh.call(this,a,e):b.state=g;return b.state},getContext:function(a){return a.contains(this.context)}}}(),function(){function b(a,b,d){if(!a.getCustomData("indent_processed")){var c=this.editor,e=this.isIndent;if(b){c=a.$.className.match(this.classNameRegex);d=0;c&&(c=c[1],d=CKEDITOR.tools.indexOf(b,c)+1);if(0>(d+=e?1:-1))return;
d=Math.min(d,b.length);d=Math.max(d,0);a.$.className=CKEDITOR.tools.ltrim(a.$.className.replace(this.classNameRegex,""));0<d&&a.addClass(b[d-1])}else{b=g(a,d);d=parseInt(a.getStyle(b),10);var h=c.config.indentOffset||40;isNaN(d)&&(d=0);d+=(e?1:-1)*h;if(0>d)return;d=Math.max(d,0);d=Math.ceil(d/h)*h;a.setStyle(b,d?d+(c.config.indentUnit||"px"):"");""===a.getAttribute("style")&&a.removeAttribute("style")}CKEDITOR.dom.element.setMarker(this.database,a,"indent_processed",1)}}function g(a,b){return"ltr"==
(b||a.getComputedStyle("direction"))?"margin-left":"margin-right"}var e=CKEDITOR.dtd.$listItem,a=CKEDITOR.dtd.$list,h=CKEDITOR.TRISTATE_DISABLED,l=CKEDITOR.TRISTATE_OFF;CKEDITOR.plugins.add("indentblock",{requires:"indent",init:function(n){function k(){d.specificDefinition.apply(this,arguments);this.allowedContent={"div h1 h2 h3 h4 h5 h6 ol p pre ul":{propertiesOnly:!0,styles:c?null:"margin-left,margin-right",classes:c||null}};this.contentTransformations=[["div: splitMarginShorthand"],["h1: splitMarginShorthand"],
["h2: splitMarginShorthand"],["h3: splitMarginShorthand"],["h4: splitMarginShorthand"],["h5: splitMarginShorthand"],["h6: splitMarginShorthand"],["ol: splitMarginShorthand"],["p: splitMarginShorthand"],["pre: splitMarginShorthand"],["ul: splitMarginShorthand"]];this.enterBr&&(this.allowedContent.div=!0);this.requiredContent=(this.enterBr?"div":"p")+(c?"("+c.join(",")+")":"{margin-left}");this.jobs={20:{refresh:function(a,b){var d=b.block||b.blockLimit;if(!d.is(e))var k=d.getAscendant(e),d=k&&b.contains(k)||
d;d.is(e)&&(d=d.getParent());if(this.enterBr||this.getContext(b)){if(c){var k=c,d=d.$.className.match(this.classNameRegex),n=this.isIndent,k=d?n?d[1]!=k.slice(-1):!0:n;return k?l:h}return this.isIndent?l:d?CKEDITOR[0>=(parseInt(d.getStyle(g(d)),10)||0)?"TRISTATE_DISABLED":"TRISTATE_OFF"]:h}return h},exec:function(d){var e=d.getSelection(),e=e&&e.getRanges()[0],g;if(g=d.elementPath().contains(a))b.call(this,g,c);else for(e=e.createIterator(),d=d.config.enterMode,e.enforceRealBlocks=!0,e.enlargeBr=
d!=CKEDITOR.ENTER_BR;g=e.getNextParagraph(d==CKEDITOR.ENTER_P?"p":"div");)g.isReadOnly()||b.call(this,g,c);return!0}}}}var d=CKEDITOR.plugins.indent,c=n.config.indentClasses;d.registerCommands(n,{indentblock:new k(n,"indentblock",!0),outdentblock:new k(n,"outdentblock")});CKEDITOR.tools.extend(k.prototype,d.specificDefinition.prototype,{context:{div:1,dl:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1,ul:1,ol:1,p:1,pre:1,table:1},classNameRegex:c?new RegExp("(?:^|\\s+)("+c.join("|")+")(?\x3d$|\\s)"):null})}})}(),
function(){function b(a){function b(d){for(var g=n.startContainer,l=n.endContainer;g&&!g.getParent().equals(d);)g=g.getParent();for(;l&&!l.getParent().equals(d);)l=l.getParent();if(!g||!l)return!1;for(var r=g,g=[],p=!1;!p;)r.equals(l)&&(p=!0),g.push(r),r=r.getNext();if(1>g.length)return!1;r=d.getParents(!0);for(l=0;l<r.length;l++)if(r[l].getName&&h[r[l].getName()]){d=r[l];break}for(var r=c.isIndent?1:-1,l=g[0],g=g[g.length-1],p=CKEDITOR.plugins.list.listToArray(d,f),A=p[g.getCustomData("listarray_index")].indent,
l=l.getCustomData("listarray_index");l<=g.getCustomData("listarray_index");l++)if(p[l].indent+=r,0<r){var t=p[l].parent;p[l].parent=new CKEDITOR.dom.element(t.getName(),t.getDocument())}for(l=g.getCustomData("listarray_index")+1;l<p.length&&p[l].indent>A;l++)p[l].indent+=r;g=CKEDITOR.plugins.list.arrayToList(p,f,null,a.config.enterMode,d.getDirection());if(!c.isIndent){var w;if((w=d.getParent())&&w.is("li"))for(var r=g.listNode.getChildren(),C=[],D,l=r.count()-1;0<=l;l--)(D=r.getItem(l))&&D.is&&D.is("li")&&
C.push(D)}g&&g.listNode.replace(d);if(C&&C.length)for(l=0;l<C.length;l++){for(D=d=C[l];(D=D.getNext())&&D.is&&D.getName()in h;)CKEDITOR.env.needsNbspFiller&&!d.getFirst(e)&&d.append(n.document.createText(" ")),d.append(D);d.insertAfter(w)}g&&a.fire("contentDomInvalidated");return!0}for(var c=this,f=this.database,h=this.context,l=a.getSelection(),l=(l&&l.getRanges()).createIterator(),n;n=l.getNextRange();){for(var A=n.getCommonAncestor();A&&(A.type!=CKEDITOR.NODE_ELEMENT||!h[A.getName()]);){if(a.editable().equals(A)){A=
!1;break}A=A.getParent()}A||(A=n.startPath().contains(h))&&n.setEndAt(A,CKEDITOR.POSITION_BEFORE_END);if(!A){var r=n.getEnclosedNode();r&&r.type==CKEDITOR.NODE_ELEMENT&&r.getName()in h&&(n.setStartAt(r,CKEDITOR.POSITION_AFTER_START),n.setEndAt(r,CKEDITOR.POSITION_BEFORE_END),A=r)}A&&n.startContainer.type==CKEDITOR.NODE_ELEMENT&&n.startContainer.getName()in h&&(r=new CKEDITOR.dom.walker(n),r.evaluator=g,n.startContainer=r.next());A&&n.endContainer.type==CKEDITOR.NODE_ELEMENT&&n.endContainer.getName()in
h&&(r=new CKEDITOR.dom.walker(n),r.evaluator=g,n.endContainer=r.previous());if(A)return b(A)}return 0}function g(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.is("li")}function e(b){return a(b)&&h(b)}var a=CKEDITOR.dom.walker.whitespaces(!0),h=CKEDITOR.dom.walker.bookmark(!1,!0),l=CKEDITOR.TRISTATE_DISABLED,n=CKEDITOR.TRISTATE_OFF;CKEDITOR.plugins.add("indentlist",{requires:"indent",init:function(a){function d(a){c.specificDefinition.apply(this,arguments);this.requiredContent=["ul","ol"];a.on("key",
function(b){if("wysiwyg"==a.mode&&b.data.keyCode==this.indentKey){var c=this.getContext(a.elementPath());!c||this.isIndent&&CKEDITOR.plugins.indentList.firstItemInPath(this.context,a.elementPath(),c)||(a.execCommand(this.relatedGlobal),b.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?n:l}:function(a,b){return!this.getContext(b)||this.isIndent?
l:n},exec:CKEDITOR.tools.bind(b,this)}}var c=CKEDITOR.plugins.indent;c.registerCommands(a,{indentlist:new d(a,"indentlist",!0),outdentlist:new d(a,"outdentlist")});CKEDITOR.tools.extend(d.prototype,c.specificDefinition.prototype,{context:{ol:1,ul:1}})}});CKEDITOR.plugins.indentList={};CKEDITOR.plugins.indentList.firstItemInPath=function(a,b,c){var e=b.contains(g);c||(c=b.contains(a));return c&&e&&e.equals(c.getFirst(g))}}(),function(){function b(a,b){b=void 0===b||b;var e;if(b)e=a.getComputedStyle("text-align");
else{for(;!a.hasAttribute||!a.hasAttribute("align")&&!a.getStyle("text-align");){e=a.getParent();if(!e)break;a=e}e=a.getStyle("text-align")||a.getAttribute("align")||""}e&&(e=e.replace(/(?:-(?:moz|webkit)-)?(?:start|auto)/i,""));!e&&b&&(e="rtl"==a.getComputedStyle("direction")?"right":"left");return e}function g(a,b,e){this.editor=a;this.name=b;this.value=e;this.context="p";b=a.config.justifyClasses;var g=a.config.enterMode==CKEDITOR.ENTER_P?"p":"div";if(b){switch(e){case "left":this.cssClassName=
b[0];break;case "center":this.cssClassName=b[1];break;case "right":this.cssClassName=b[2];break;case "justify":this.cssClassName=b[3]}this.cssClassRegex=new RegExp("(?:^|\\s+)(?:"+b.join("|")+")(?\x3d$|\\s)");this.requiredContent=g+"("+this.cssClassName+")"}else this.requiredContent=g+"{text-align}";this.allowedContent={"caption div h1 h2 h3 h4 h5 h6 p pre td th li":{propertiesOnly:!0,styles:this.cssClassName?null:"text-align",classes:this.cssClassName||null}};a.config.enterMode==CKEDITOR.ENTER_BR&&
(this.allowedContent.div=!0)}function e(a){var b=a.editor,e=b.createRange();e.setStartBefore(a.data.node);e.setEndAfter(a.data.node);for(var g=new CKEDITOR.dom.walker(e),k;k=g.next();)if(k.type==CKEDITOR.NODE_ELEMENT)if(!k.equals(a.data.node)&&k.getDirection())e.setStartAfter(k),g=new CKEDITOR.dom.walker(e);else{var d=b.config.justifyClasses;d&&(k.hasClass(d[0])?(k.removeClass(d[0]),k.addClass(d[2])):k.hasClass(d[2])&&(k.removeClass(d[2]),k.addClass(d[0])));d=k.getStyle("text-align");"left"==d?k.setStyle("text-align",
"right"):"right"==d&&k.setStyle("text-align","left")}}g.prototype={exec:function(a){var e=a.getSelection(),g=a.config.enterMode;if(e){for(var n=e.createBookmarks(),k=e.getRanges(),d=this.cssClassName,c,f,m=a.config.useComputedState,m=void 0===m||m,t=k.length-1;0<=t;t--)for(c=k[t].createIterator(),c.enlargeBr=g!=CKEDITOR.ENTER_BR;f=c.getNextParagraph(g==CKEDITOR.ENTER_P?"p":"div");)if(!f.isReadOnly()){f.removeAttribute("align");f.removeStyle("text-align");var x=d&&(f.$.className=CKEDITOR.tools.ltrim(f.$.className.replace(this.cssClassRegex,
""))),A=this.state==CKEDITOR.TRISTATE_OFF&&(!m||b(f,!0)!=this.value);d?A?f.addClass(d):x||f.removeAttribute("class"):A&&f.setStyle("text-align",this.value)}a.focus();a.forceNextSelectionCheck();e.selectBookmarks(n)}},refresh:function(a,e){var g=e.block||e.blockLimit;this.setState("body"!=g.getName()&&b(g,this.editor.config.useComputedState)==this.value?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF)}};CKEDITOR.plugins.add("justify",{init:function(a){if(!a.blockless){var b=new g(a,"justifyleft","left"),
l=new g(a,"justifycenter","center"),n=new g(a,"justifyright","right"),k=new g(a,"justifyblock","justify");a.addCommand("justifyleft",b);a.addCommand("justifycenter",l);a.addCommand("justifyright",n);a.addCommand("justifyblock",k);a.ui.addButton&&(a.ui.addButton("JustifyLeft",{label:a.lang.justify.left,command:"justifyleft",toolbar:"align,10"}),a.ui.addButton("JustifyCenter",{label:a.lang.justify.center,command:"justifycenter",toolbar:"align,20"}),a.ui.addButton("JustifyRight",{label:a.lang.justify.right,
command:"justifyright",toolbar:"align,30"}),a.ui.addButton("JustifyBlock",{label:a.lang.justify.block,command:"justifyblock",toolbar:"align,40"}));a.on("dirChanged",e)}}})}(),function(){function b(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 e=CKEDITOR.plugins.list.listToArray(b.root,
c),f=[],g=0;g<b.contents.length;g++){var h=b.contents[g];(h=h.getAscendant("li",!0))&&!h.getCustomData("list_item_processed")&&(f.push(h),CKEDITOR.dom.element.setMarker(c,h,"list_item_processed",!0))}h=null;for(g=0;g<f.length;g++)h=f[g].getCustomData("listarray_index"),e[h].indent=-1;for(g=h+1;g<e.length;g++)if(e[g].indent>e[g-1].indent+1){f=e[g-1].indent+1-e[g].indent;for(h=e[g].indent;e[g]&&e[g].indent>=h;)e[g].indent+=f,g++;g--}var k=CKEDITOR.plugins.list.arrayToList(e,c,null,a.config.enterMode,
b.root.getAttribute("dir")).listNode,m,l;d(!0);d();k.replace(b.root);a.fire("contentDomInvalidated")}function g(a,b){this.name=a;this.context=this.type=b;this.allowedContent=b+" li";this.requiredContent=b}function e(a,b,c,d){for(var e,f;e=a[d?"getLast":"getFirst"](x);)(f=e.getDirection(1))!==b.getDirection(1)&&e.setAttribute("dir",f),e.remove(),c?e[d?"insertBefore":"insertAfter"](c):b.append(e,d)}function a(a){function b(c){var d=a[c?"getPrevious":"getNext"](f);d&&d.type==CKEDITOR.NODE_ELEMENT&&d.is(a.getName())&&
(e(a,d,null,!c),a.remove(),a=d)}b();b(1)}function h(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(b,c,d){b.fire("saveSnapshot");d.enlarge(CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS);var g=d.extractContents();c.trim(!1,!0);var h=c.createBookmark(),k=new CKEDITOR.dom.elementPath(c.startContainer),l=k.block,k=k.lastElement.getAscendant("li",1)||l,t=new CKEDITOR.dom.elementPath(d.startContainer),B=
t.contains(CKEDITOR.dtd.$listItem),t=t.contains(CKEDITOR.dtd.$list);l?(l=l.getBogus())&&l.remove():t&&(l=t.getPrevious(f))&&m(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);B&&(g=n(B))&&(k.contains(B)?(e(g,B.getParent(),B),g.remove()):k.append(g));for(;d.checkStartOfBlock()&&d.checkEndOfBlock();){t=d.startPath();g=t.block;if(!g)break;g.is("li")&&(k=g.getParent(),g.equals(k.getLast(f))&&
g.equals(k.getFirst(f))&&(g=k));d.moveToPosition(g,CKEDITOR.POSITION_BEFORE_START);g.remove()}d=d.clone();g=b.editable();d.setEndAt(g,CKEDITOR.POSITION_BEFORE_END);d=new CKEDITOR.dom.walker(d);d.evaluator=function(a){return f(a)&&!m(a)};(d=d.next())&&d.type==CKEDITOR.NODE_ELEMENT&&d.getName()in CKEDITOR.dtd.$list&&a(d);c.moveToBookmark(h);c.select();b.fire("saveSnapshot")}function n(a){return(a=a.getLast(f))&&a.type==CKEDITOR.NODE_ELEMENT&&a.getName()in k?a:null}var k={ol:1,ul:1},d=CKEDITOR.dom.walker.whitespaces(),
c=CKEDITOR.dom.walker.bookmark(),f=function(a){return!(d(a)||c(a))},m=CKEDITOR.dom.walker.bogus();CKEDITOR.plugins.list={listToArray:function(a,b,c,d,e){if(!k[a.getName()])return[];d||(d=0);c||(c=[]);for(var f=0,g=a.getChildCount();f<g;f++){var h=a.getChild(f);h.type==CKEDITOR.NODE_ELEMENT&&h.getName()in CKEDITOR.dtd.$list&&CKEDITOR.plugins.list.listToArray(h,b,c,d+1);if("li"==h.$.nodeName.toLowerCase()){var m={parent:a,indent:d,element:h,contents:[]};e?m.grandparent=e:(m.grandparent=a.getParent(),
m.grandparent&&"li"==m.grandparent.$.nodeName.toLowerCase()&&(m.grandparent=m.grandparent.getParent()));b&&CKEDITOR.dom.element.setMarker(b,h,"listarray_index",c.length);c.push(m);for(var l=0,n=h.getChildCount(),t;l<n;l++)t=h.getChild(l),t.type==CKEDITOR.NODE_ELEMENT&&k[t.getName()]?CKEDITOR.plugins.list.listToArray(t,b,c,d+1,m.grandparent):m.contents.push(t)}}return c},arrayToList:function(a,b,d,e,g){d||(d=0);if(!a||a.length<d+1)return null;for(var h,m=a[d].parent.getDocument(),l=new CKEDITOR.dom.documentFragment(m),
n=null,t=d,x=Math.max(a[d].indent,0),D=null,F,G,L=e==CKEDITOR.ENTER_P?"p":"div";;){var I=a[t];h=I.grandparent;F=I.element.getDirection(1);if(I.indent==x){n&&a[t].parent.getName()==n.getName()||(n=a[t].parent.clone(!1,1),g&&n.setAttribute("dir",g),l.append(n));D=n.append(I.element.clone(0,1));F!=n.getDirection(1)&&D.setAttribute("dir",F);for(h=0;h<I.contents.length;h++)D.append(I.contents[h].clone(1,1));t++}else if(I.indent==Math.max(x,0)+1)I=a[t-1].element.getDirection(1),t=CKEDITOR.plugins.list.arrayToList(a,
null,t,e,I!=F?F:null),!D.getChildCount()&&CKEDITOR.env.needsNbspFiller&&7>=m.$.documentMode&&D.append(m.createText(" ")),D.append(t.listNode),t=t.nextIndex;else if(-1==I.indent&&!d&&h){k[h.getName()]?(D=I.element.clone(!1,!0),F!=h.getDirection(1)&&D.setAttribute("dir",F)):D=new CKEDITOR.dom.documentFragment(m);var n=h.getDirection(1)!=F,P=I.element,H=P.getAttribute("class"),E=P.getAttribute("style"),S=D.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT&&(e!=CKEDITOR.ENTER_BR||n||E||H),O,T=I.contents.length,Q;
for(h=0;h<T;h++)if(O=I.contents[h],c(O)&&1<T)S?Q=O.clone(1,1):D.append(O.clone(1,1));else if(O.type==CKEDITOR.NODE_ELEMENT&&O.isBlockBoundary()){n&&!O.getDirection()&&O.setAttribute("dir",F);G=O;var Z=P.getAttribute("style");Z&&G.setAttribute("style",Z.replace(/([^;])$/,"$1;")+(G.getAttribute("style")||""));H&&O.addClass(H);G=null;Q&&(D.append(Q),Q=null);D.append(O.clone(1,1))}else S?(G||(G=m.createElement(L),D.append(G),n&&G.setAttribute("dir",F)),E&&G.setAttribute("style",E),H&&G.setAttribute("class",
H),Q&&(G.append(Q),Q=null),G.append(O.clone(1,1))):D.append(O.clone(1,1));Q&&((G||D).append(Q),Q=null);D.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT&&t!=a.length-1&&(CKEDITOR.env.needsBrFiller&&(F=D.getLast())&&F.type==CKEDITOR.NODE_ELEMENT&&F.is("br")&&F.remove(),(F=D.getLast(f))&&F.type==CKEDITOR.NODE_ELEMENT&&F.is(CKEDITOR.dtd.$block)||D.append(m.createElement("br")));F=D.$.nodeName.toLowerCase();"div"!=F&&"p"!=F||D.appendBogus();l.append(D);n=null;t++}else return null;G=null;if(a.length<=t||Math.max(a[t].indent,
0)<x)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&&(d=a,m=g=e=void 0,e=d.getDirection()))){for(g=d.getParent();g&&!(m=g.getDirection());)g=g.getParent();e==m&&d.removeAttribute("dir")}a=a.getNextSourceNode()}return{listNode:l,nextIndex:t}}};var t=/^h[1-6]$/,x=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_ELEMENT);g.prototype={exec:function(c){this.refresh(c,c.elementPath());var d=c.config,e=c.getSelection(),
g=e&&e.getRanges();if(this.state==CKEDITOR.TRISTATE_OFF){var h=c.editable();if(h.getFirst(f)){var m=1==g.length&&g[0];(d=m&&m.getEnclosedNode())&&d.is&&this.type==d.getName()&&this.setState(CKEDITOR.TRISTATE_ON)}else d.enterMode==CKEDITOR.ENTER_BR?h.appendBogus():g[0].fixBlock(1,d.enterMode==CKEDITOR.ENTER_P?"p":"div"),e.selectRanges(g)}for(var d=e.createBookmarks(!0),h=[],l={},g=g.createIterator(),n=0;(m=g.getNextRange())&&++n;){var x=m.getBoundaryNodes(),w=x.startNode,C=x.endNode;w.type==CKEDITOR.NODE_ELEMENT&&
"td"==w.getName()&&m.setStartAt(x.startNode,CKEDITOR.POSITION_AFTER_START);C.type==CKEDITOR.NODE_ELEMENT&&"td"==C.getName()&&m.setEndAt(x.endNode,CKEDITOR.POSITION_BEFORE_END);m=m.createIterator();for(m.forceBrBreak=this.state==CKEDITOR.TRISTATE_OFF;x=m.getNextParagraph();)if(!x.getCustomData("list_block")){CKEDITOR.dom.element.setMarker(l,x,"list_block",1);for(var D=c.elementPath(x),w=D.elements,C=0,D=D.blockLimit,F,G=w.length-1;0<=G&&(F=w[G]);G--)if(k[F.getName()]&&D.contains(F)){D.removeCustomData("list_group_object_"+
n);(w=F.getCustomData("list_group_object"))?w.contents.push(x):(w={root:F,contents:[x]},h.push(w),CKEDITOR.dom.element.setMarker(l,F,"list_group_object",w));C=1;break}C||(C=D,C.getCustomData("list_group_object_"+n)?C.getCustomData("list_group_object_"+n).contents.push(x):(w={root:C,contents:[x]},CKEDITOR.dom.element.setMarker(l,C,"list_group_object_"+n,w),h.push(w)))}}for(F=[];0<h.length;)if(w=h.shift(),this.state==CKEDITOR.TRISTATE_OFF)if(k[w.root.getName()]){g=c;n=w;w=l;m=F;C=CKEDITOR.plugins.list.listToArray(n.root,
w);D=[];for(x=0;x<n.contents.length;x++)G=n.contents[x],(G=G.getAscendant("li",!0))&&!G.getCustomData("list_item_processed")&&(D.push(G),CKEDITOR.dom.element.setMarker(w,G,"list_item_processed",!0));for(var G=n.root.getDocument(),L=void 0,I=void 0,x=0;x<D.length;x++){var P=D[x].getCustomData("listarray_index"),L=C[P].parent;L.is(this.type)||(I=G.createElement(this.type),L.copyAttributes(I,{start:1,type:1}),I.removeStyle("list-style-type"),C[P].parent=I)}w=CKEDITOR.plugins.list.arrayToList(C,w,null,
g.config.enterMode);C=void 0;D=w.listNode.getChildCount();for(x=0;x<D&&(C=w.listNode.getChild(x));x++)C.getName()==this.type&&m.push(C);w.listNode.replace(n.root);g.fire("contentDomInvalidated")}else{C=c;m=w;x=F;D=m.contents;g=m.root.getDocument();n=[];1==D.length&&D[0].equals(m.root)&&(w=g.createElement("div"),D[0].moveChildren&&D[0].moveChildren(w),D[0].append(w),D[0]=w);m=m.contents[0].getParent();for(G=0;G<D.length;G++)m=m.getCommonAncestor(D[G].getParent());L=C.config.useComputedState;C=w=void 0;
L=void 0===L||L;for(G=0;G<D.length;G++)for(I=D[G];P=I.getParent();){if(P.equals(m)){n.push(I);!C&&I.getDirection()&&(C=1);I=I.getDirection(L);null!==w&&(w=w&&w!=I?null:I);break}I=P}if(!(1>n.length)){D=n[n.length-1].getNext();G=g.createElement(this.type);x.push(G);for(L=x=void 0;n.length;)x=n.shift(),L=g.createElement("li"),I=x,I.is("pre")||t.test(I.getName())||"false"==I.getAttribute("contenteditable")?x.appendTo(L):(x.copyAttributes(L),w&&x.getDirection()&&(L.removeStyle("direction"),L.removeAttribute("dir")),
x.moveChildren(L),x.remove()),L.appendTo(G);w&&C&&G.setAttribute("dir",w);D?G.insertBefore(D):G.appendTo(m)}}else this.state==CKEDITOR.TRISTATE_ON&&k[w.root.getName()]&&b.call(this,c,w,l);for(G=0;G<F.length;G++)a(F[G]);CKEDITOR.dom.element.clearAllMarkers(l);e.selectBookmarks(d);c.focus()},refresh:function(a,b){var c=b.contains(k,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 g("numberedlist","ol")),a.addCommand("bulletedlist",new g("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],g=e&&e.startPath();if(e&&e.collapsed){var p=8==c,t=a.editable(),x=new CKEDITOR.dom.walker(e.clone());x.evaluator=function(a){return f(a)&&!m(a)};x.guard=function(a,b){return!(b&&a.type==CKEDITOR.NODE_ELEMENT&&a.is("table"))};c=e.clone();if(p){var w;(w=g.contains(k))&&e.checkBoundaryOfElement(w,CKEDITOR.START)&&(w=w.getParent())&&w.is("li")&&(w=n(w))?(d=w,w=w.getPrevious(f),c.moveToPosition(w&&m(w)?w:d,CKEDITOR.POSITION_BEFORE_START)):(x.range.setStartAt(t,
CKEDITOR.POSITION_AFTER_START),x.range.setEnd(e.startContainer,e.startOffset),(w=x.previous())&&w.type==CKEDITOR.NODE_ELEMENT&&(w.getName()in k||w.is("li"))&&(w.is("li")||(x.range.selectNodeContents(w),x.reset(),x.evaluator=h,w=x.previous()),d=w,c.moveToElementEditEnd(d),c.moveToPosition(c.endPath().block,CKEDITOR.POSITION_BEFORE_END)));if(d)l(a,c,e),b.cancel();else{var C=g.contains(k);C&&e.checkBoundaryOfElement(C,CKEDITOR.START)&&(d=C.getFirst(f),e.checkBoundaryOfElement(d,CKEDITOR.START)&&(w=C.getPrevious(f),
n(d)?w&&(e.moveToElementEditEnd(w),e.select()):a.execCommand("outdent"),b.cancel()))}}else if(d=g.contains("li")){if(x.range.setEndAt(t,CKEDITOR.POSITION_BEFORE_END),p=(t=d.getLast(f))&&h(t)?t:d,g=0,(w=x.next())&&w.type==CKEDITOR.NODE_ELEMENT&&w.getName()in k&&w.equals(t)?(g=1,w=x.next()):e.checkBoundaryOfElement(p,CKEDITOR.END)&&(g=2),g&&w){e=e.clone();e.moveToElementEditStart(w);if(1==g&&(c.optimize(),!c.startContainer.equals(d))){for(d=c.startContainer;d.is(CKEDITOR.dtd.$inline);)C=d,d=d.getParent();
C&&c.moveToPosition(C,CKEDITOR.POSITION_AFTER_END)}2==g&&(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 x.range.setEndAt(t,CKEDITOR.POSITION_BEFORE_END),(w=x.next())&&w.type==CKEDITOR.NODE_ELEMENT&&w.is(k)&&(w=w.getFirst(f),g.block&&e.checkStartOfBlock()&&e.checkEndOfBlock()?(g.block.remove(),e.moveToElementEditStart(w),e.select()):n(w)?(e.moveToElementEditStart(w),e.select()):
(e=e.clone(),e.moveToElementEditStart(w),l(a,c,e)),b.cancel());setTimeout(function(){a.selectionChange(1)})}}}))}})}(),function(){CKEDITOR.plugins.add("sourcearea",{init:function(g){function e(){var a=h&&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(g.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE){var a=CKEDITOR.plugins.sourcearea;g.addMode("source",
function(a){var h=g.ui.space("contents").getDocument().createElement("textarea");h.setStyles(CKEDITOR.tools.extend({width:CKEDITOR.env.ie7Compat?"99%":"100%",height:"100%",resize:"none",outline:"none","text-align":"left"},CKEDITOR.tools.cssVendorPrefix("tab-size",g.config.sourceAreaTabSize||4)));h.setAttribute("dir","ltr");h.addClass("cke_source").addClass("cke_reset").addClass("cke_enable_context_menu");g.ui.space("contents").append(h);h=g.editable(new b(g,h));h.setData(g.getData(1));CKEDITOR.env.ie&&
(h.attachListener(g,"resize",e,h),h.attachListener(CKEDITOR.document.getWindow(),"resize",e,h),CKEDITOR.tools.setTimeout(e,0,h));g.fire("ariaWidget",this);a()});g.addCommand("source",a.commands.source);g.ui.addButton&&g.ui.addButton("Source",{label:g.lang.sourcearea.toolbar,command:"source",toolbar:"mode,10"});g.on("mode",function(){g.getCommand("source").setState("source"==g.mode?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF)});var h=CKEDITOR.env.ie&&9==CKEDITOR.env.version}}});var b=CKEDITOR.tools.createClass({base:CKEDITOR.editable,
proto:{setData:function(b){this.setValue(b);this.status="ready";this.editor.fire("dataReady")},getData:function(){return this.getValue()},insertHtml:function(){},insertElement:function(){},insertText:function(){},setReadOnly:function(b){this[(b?"set":"remove")+"Attribute"]("readOnly","readonly")},detach:function(){b.baseProto.detach.call(this);this.clearCustomData();this.remove()}}})}(),CKEDITOR.plugins.sourcearea={commands:{source:{modes:{wysiwyg:1,source:1},editorFocus:!1,readOnly:1,exec:function(b){"wysiwyg"==
b.mode&&b.fire("saveSnapshot");b.getCommand("source").setState(CKEDITOR.TRISTATE_DISABLED);b.setMode("source"==b.mode?"wysiwyg":"source")},canUndo:!1}}},function(){function b(a){function b(){for(var c=e(),d=CKEDITOR.tools.clone(a.config.toolbarGroups)||g(a),f=0;f<d.length;f++){var l=d[f];if("/"!=l){"string"==typeof l&&(l=d[f]={name:l});var r,q=l.groups;if(q)for(var y=0;y<q.length;y++)r=q[y],(r=c[r])&&k(l,r);(r=c[l.name])&&k(l,r)}}return d}function e(){var b={},c,d,f;for(c in a.ui.items)d=a.ui.items[c],
f=d.toolbar||"others",f=f.split(","),d=f[0],f=parseInt(f[1]||-1,10),b[d]||(b[d]=[]),b[d].push({name:c,order:f});for(d in b)b[d]=b[d].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 k(b,d){if(d.length){b.items?b.items.push(a.ui.create("-")):b.items=[];for(var e;e=d.shift();)e="string"==typeof e?e:e.name,c&&-1!=CKEDITOR.tools.indexOf(c,e)||(e=a.ui.create(e))&&a.addFeature(e)&&b.items.push(e)}}function d(a){var b=[],c,d,e;for(c=0;c<a.length;++c)d=
a[c],e={},"/"==d?b.push(d):CKEDITOR.tools.isArray(d)?(k(e,CKEDITOR.tools.clone(d)),b.push(e)):d.items&&(k(e,CKEDITOR.tools.clone(d.items)),e.name=d.name,b.push(e));return b}var c=a.config.removeButtons,c=c&&c.split(","),f=a.config.toolbar;"string"==typeof f&&(f=a.config["toolbar_"+f]);return a.toolbar=f?d(f):b()}function g(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 e=function(){this.toolbars=[];this.focusCommandExecuted=!1};e.prototype.focus=function(){for(var a=0,b;b=this.toolbars[a++];)for(var e=0,g;g=b.items[e++];)if(g.focus){g.focus();return}};var a={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 l,n=function(a,b){var c,e="rtl"==g.lang.dir,m=g.config.toolbarGroupCycling,t=e?37:39,e=e?39:37,m=void 0===m||m;switch(b){case 9:case CKEDITOR.SHIFT+9:for(;!c||!c.items.length;)if(c=9==b?(c?c.next:a.toolbar.next)||g.toolbox.toolbars[0]:(c?c.previous:a.toolbar.previous)||
g.toolbox.toolbars[g.toolbox.toolbars.length-1],c.items.length)for(a=c.items[l?c.items.length-1:0];a&&!a.focus;)(a=l?a.previous:a.next)||(c=0);a&&a.focus();return!1;case t:c=a;do c=c.next,!c&&m&&(c=a.toolbar.items[0]);while(c&&!c.focus);c?c.focus():n(a,9);return!1;case 40:return a.button&&a.button.hasArrow?(g.once("panelShow",function(a){a.data._.panel._.currentBlock.onKeyDown(40)}),a.execute()):n(a,40==b?t:e),!1;case e:case 38:c=a;do c=c.previous,!c&&m&&(c=a.toolbar.items[a.toolbar.items.length-
1]);while(c&&!c.focus);c?c.focus():(l=1,n(a,CKEDITOR.SHIFT+9),l=0);return!1;case 27:return g.focus(),!1;case 13:case 32:return a.execute(),!1}return!0};g.on("uiSpace",function(a){if(a.data.space==g.config.toolbarLocation){a.removeListener();g.toolbox=new e;var d=CKEDITOR.tools.getNextId(),c=['\x3cspan id\x3d"',d,'" 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"',d,'" onmousedown\x3d"return false;"\x3e'],
d=!1!==g.config.toolbarStartupExpanded,f,m;g.config.toolbarCanCollapse&&g.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE&&c.push('\x3cspan class\x3d"cke_toolbox_main"'+(d?"\x3e":' style\x3d"display:none"\x3e'));for(var l=g.toolbox.toolbars,x=b(g),A=x.length,r=0;r<A;r++){var q,y=0,v,z=x[r],p="/"!==z&&("/"===x[r+1]||r==A-1),u;if(z)if(f&&(c.push("\x3c/span\x3e"),m=f=0),"/"===z)c.push('\x3cspan class\x3d"cke_toolbar_break"\x3e\x3c/span\x3e');else{u=z.items||z;for(var B=0;B<u.length;B++){var w=u[B],C;if(w){var D=
function(a){a=a.render(g,c);F=y.items.push(a)-1;0<F&&(a.previous=y.items[F-1],a.previous.next=a);a.toolbar=y;a.onkey=n;a.onfocus=function(){g.toolbox.focusCommandExecuted||g.focus()}};if(w.type==CKEDITOR.UI_SEPARATOR)m=f&&w;else{C=!1!==w.canGroup;if(!y){q=CKEDITOR.tools.getNextId();y={id:q,items:[]};v=z.name&&(g.lang.toolbar.toolbarGroups[z.name]||z.name);c.push('\x3cspan id\x3d"',q,'" class\x3d"cke_toolbar'+(p?' cke_toolbar_last"':'"'),v?' aria-labelledby\x3d"'+q+'_label"':"",' role\x3d"toolbar"\x3e');
v&&c.push('\x3cspan id\x3d"',q,'_label" class\x3d"cke_voice_label"\x3e',v,"\x3c/span\x3e");c.push('\x3cspan class\x3d"cke_toolbar_start"\x3e\x3c/span\x3e');var F=l.push(y)-1;0<F&&(y.previous=l[F-1],y.previous.next=y)}C?f||(c.push('\x3cspan class\x3d"cke_toolgroup" role\x3d"presentation"\x3e'),f=1):f&&(c.push("\x3c/span\x3e"),f=0);m&&(D(m),m=0);D(w)}}}f&&(c.push("\x3c/span\x3e"),m=f=0);y&&c.push('\x3cspan class\x3d"cke_toolbar_end"\x3e\x3c/span\x3e\x3c/span\x3e')}}g.config.toolbarCanCollapse&&c.push("\x3c/span\x3e");
if(g.config.toolbarCanCollapse&&g.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE){var G=CKEDITOR.tools.addFunction(function(){g.execCommand("toolbarCollapse")});g.on("destroy",function(){CKEDITOR.tools.removeFunction(G)});g.addCommand("toolbarCollapse",{readOnly:1,exec:function(a){var b=a.ui.space("toolbar_collapser"),c=b.getPrevious(),d=a.ui.space("contents"),e=c.getParent(),f=parseInt(d.$.style.height,10),g=e.$.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",f-(e.$.offsetHeight-g)+"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");c.push('\x3ca title\x3d"'+
(d?g.lang.toolbar.toolbarCollapse:g.lang.toolbar.toolbarExpand)+'" id\x3d"'+g.ui.spaceId("toolbar_collapser")+'" tabIndex\x3d"-1" class\x3d"cke_toolbox_collapser');d||c.push(" cke_toolbox_collapser_min");c.push('" onclick\x3d"CKEDITOR.tools.callFunction('+G+')"\x3e','\x3cspan class\x3d"cke_arrow"\x3e\x26#9650;\x3c/span\x3e',"\x3c/a\x3e")}c.push("\x3c/span\x3e");a.data.html+=c.join("")}});g.on("destroy",function(){if(this.toolbox){var a,b=0,c,e,g;for(a=this.toolbox.toolbars;b<a.length;b++)for(e=a[b].items,
c=0;c<e.length;c++)g=e[c],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",a);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,e){var k=g(this.editor),d=0===b,c={name:a};if(e){if(e=CKEDITOR.tools.search(k,function(a){return a.name==e})){!e.groups&&(e.groups=[]);if(b&&(b=CKEDITOR.tools.indexOf(e.groups,b),0<=b)){e.groups.splice(b+1,0,a);return}d?e.groups.splice(0,0,a):e.groups.push(a);return}b=null}b&&(b=CKEDITOR.tools.indexOf(k,function(a){return a.name==b}));d?k.splice(0,0,a):"number"==typeof b?k.splice(b+1,0,c):k.push(a)}}(),CKEDITOR.UI_SEPARATOR="separator",
CKEDITOR.config.toolbarLocation="top","use strict",function(){var b=[CKEDITOR.CTRL+90,CKEDITOR.CTRL+89,CKEDITOR.CTRL+CKEDITOR.SHIFT+90],g={8:1,46:1};CKEDITOR.plugins.add("undo",{init:function(a){function d(a){f.enabled&&!1!==a.data.command.canUndo&&f.save()}function c(){f.enabled=a.readOnly?!1:"wysiwyg"==a.mode;f.onChange()}var f=a.undoManager=new e(a),g=f.editingHandler=new l(f),h=a.addCommand("undo",{exec:function(){f.undo()&&(a.selectionChange(),this.fire("afterUndo"))},startDisabled:!0,canUndo:!1}),
n=a.addCommand("redo",{exec:function(){f.redo()&&(a.selectionChange(),this.fire("afterRedo"))},startDisabled:!0,canUndo:!1});a.setKeystroke([[b[0],"undo"],[b[1],"redo"],[b[2],"redo"]]);f.onChange=function(){h.setState(f.undoable()?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED);n.setState(f.redoable()?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED)};a.on("beforeCommandExec",d);a.on("afterCommandExec",d);a.on("saveSnapshot",function(a){f.save(a.data&&a.data.contentOnly)});a.on("contentDom",g.attachListeners,
g);a.on("instanceReady",function(){a.fire("saveSnapshot")});a.on("beforeModeUnload",function(){"wysiwyg"==a.mode&&f.save(!0)});a.on("mode",c);a.on("readOnly",c);a.ui.addButton&&(a.ui.addButton("Undo",{label:a.lang.undo.undo,command:"undo",toolbar:"undo,10"}),a.ui.addButton("Redo",{label:a.lang.undo.redo,command:"redo",toolbar:"undo,20"}));a.resetUndo=function(){f.reset();a.fire("saveSnapshot")};a.on("updateSnapshot",function(){f.currentImage&&f.update()});a.on("lockSnapshot",function(a){a=a.data;
f.lock(a&&a.dontUpdate,a&&a.forceUpdate)});a.on("unlockSnapshot",f.unlock,f)}});CKEDITOR.plugins.undo={};var e=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()};e.prototype={type:function(a,b){var c=e.getKeyGroup(a),f=this.strokesRecorded[c]+1;b=b||f>=this.strokesLimit;this.typing||(this.hasUndo=this.typing=!0,this.hasRedo=!1,this.onChange());b?(f=
0,this.editor.fire("saveSnapshot")):this.editor.fire("change");this.strokesRecorded[c]=f;this.previousKeyGroup=c},keyGroupChanged:function(a){return e.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(b,d,c){var e=this.editor;if(this.locked||"ready"!=e.status||"wysiwyg"!=e.mode)return!1;var g=e.editable();if(!g||"ready"!=g.status)return!1;g=this.snapshots;d||(d=new a(e));if(!1===d.contents)return!1;if(this.currentImage)if(d.equalsContent(this.currentImage)){if(b||d.equalsSelection(this.currentImage))return!1}else!1!==c&&e.fire("change");g.splice(this.index+1,g.length-this.index-1);g.length==this.limit&&g.shift();this.index=g.push(d)-1;this.currentImage=
d;!1!==c&&this.refreshState();return!0},restoreImage:function(a){var b=this.editor,c;a.bookmarks&&(b.focus(),c=b.getSelection());this.locked={level:999};this.editor.loadSnapshot(a.contents);a.bookmarks?c.selectBookmarks(a.bookmarks):CKEDITOR.env.ie&&(c=this.editor.document.getBody().$.createTextRange(),c.collapse(!0),c.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,
c=this.currentImage,e;if(c)if(a)for(e=this.index-1;0<=e;e--){if(a=b[e],!c.equalsContent(a))return a.index=e,a}else for(e=this.index+1;e<b.length;e++)if(a=b[e],!c.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(b){if(!this.locked){b||(b=new a(this.editor));for(var d=this.index,c=this.snapshots;0<d&&this.currentImage.equalsContent(c[d-1]);)--d;c.splice(d,this.index-d+1,b);this.index=d;this.currentImage=b}},updateSelection:function(a){if(!this.snapshots.length)return!1;var b=this.snapshots,c=b[b.length-1];return c.equalsContent(a)&&!c.equalsSelection(a)?(this.currentImage=b[b.length-1]=a,!0):!1},lock:function(b,d){if(this.locked)this.locked.level++;
else if(b)this.locked={level:1};else{var c=null;if(d)c=!0;else{var e=new a(this.editor,!0);this.currentImage&&this.currentImage.equalsContent(e)&&(c=e)}this.locked={update:c,level:1}}},unlock:function(){if(this.locked&&!--this.locked.level){var b=this.locked.update;this.locked=null;if(!0===b)this.update();else if(b){var d=new a(this.editor,!0);b.equalsContent(d)||this.update()}}}};e.navigationKeyCodes={37:1,38:1,39:1,40:1,36:1,35:1,33:1,34:1};e.keyGroups={PRINTABLE:0,FUNCTIONAL:1};e.isNavigationKey=
function(a){return!!e.navigationKeyCodes[a]};e.getKeyGroup=function(a){var b=e.keyGroups;return g[a]?b.FUNCTIONAL:b.PRINTABLE};e.getOppositeKeyGroup=function(a){var b=e.keyGroups;return a==b.FUNCTIONAL?b.PRINTABLE:b.FUNCTIONAL};e.ieFunctionalKeysBug=function(a){return CKEDITOR.env.ie&&e.getKeyGroup(a)==e.keyGroups.FUNCTIONAL};var a=CKEDITOR.plugins.undo.Image=function(a,b){this.editor=a;a.fire("beforeUndoImage");var c=a.getSnapshot();CKEDITOR.env.ie&&c&&(c=c.replace(/\s+data-cke-expando=".*?"/g,""));
this.contents=c;b||(this.bookmarks=(c=c&&a.getSelection())&&c.createBookmarks2(!0));a.fire("afterUndoImage")},h=/\b(?:href|src|name)="[^"]*?"/gi;a.prototype={equalsContent:function(a){var b=this.contents;a=a.contents;CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)&&(b=b.replace(h,""),a=a.replace(h,""));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 c=0;c<b.length;c++){var e=b[c],g=a[c];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 n;this.lastKeydownImage=null};l.prototype={onKeydown:function(g){var d=g.data.getKey();if(229!==d)if(-1<CKEDITOR.tools.indexOf(b,g.data.getKeystroke()))g.data.preventDefault();else if(this.keyEventsStack.cleanUp(g),g=this.undoManager,
this.keyEventsStack.getLast(d)||this.keyEventsStack.push(d),this.lastKeydownImage=new a(g.editor),e.isNavigationKey(d)||this.undoManager.keyGroupChanged(d))if(g.strokesRecorded[0]||g.strokesRecorded[1])g.save(!1,this.lastKeydownImage,!1),g.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(b){var d=this.undoManager;b=b.data.getKey();var c=this.keyEventsStack.getTotalInputs();this.keyEventsStack.remove(b);if(!(e.ieFunctionalKeysBug(b)&&this.lastKeydownImage&&this.lastKeydownImage.equalsContent(new a(d.editor,!0))))if(0<c)d.type(b);else if(e.isNavigationKey(b))this.onNavigationKey(!0)},onNavigationKey:function(b){var d=this.undoManager;!b&&d.save(!0,null,!1)||d.updateSelection(new a(d.editor));
d.resetType()},ignoreInputEventListener:function(){this.ignoreInputEvent=!0},attachListeners:function(){var a=this.undoManager.editor,b=a.editable(),c=this;b.attachListener(b,"keydown",function(a){c.onKeydown(a);if(e.ieFunctionalKeysBug(a.data.getKey()))c.onInput()},null,null,999);b.attachListener(b,CKEDITOR.env.ie?"keypress":"input",c.onInput,c,null,999);b.attachListener(b,"keyup",c.onKeyup,c,null,999);b.attachListener(b,"paste",c.ignoreInputEventListener,c,null,999);b.attachListener(b,"drop",c.ignoreInputEventListener,
c,null,999);b.attachListener(b.isInline()?b:a.document.getDocumentElement(),"click",function(){c.onNavigationKey()},null,null,999);b.attachListener(this.undoManager.editor,"blur",function(){c.keyEventsStack.remove(9)},null,null,999)}};var n=CKEDITOR.plugins.undo.KeyEventsStack=function(){this.stack=[]};n.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 b(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 g(a,b){CKEDITOR.tools.extend(this,b,{editor:a},!0)}function e(a,b){var e=a.editable();CKEDITOR.tools.extend(this,{editor:a,editable:e,inline:e.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 g=CKEDITOR.tools.bind(this.queryViewport,this),k=CKEDITOR.tools.bind(this.hideVisible,this),n=CKEDITOR.tools.bind(this.removeAll,this);e.attachListener(this.winTop,"resize",g);e.attachListener(this.winTop,"scroll",g);e.attachListener(this.winTop,"resize",k);e.attachListener(this.win,"scroll",k);e.attachListener(this.inline?
e: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);e.attachListener(a,"resize",g);e.attachListener(a,"mode",n);a.on("destroy",n);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({},h,{left:"0px","border-left-color":"red","border-width":"6px 0 6px 6px"},this.tipCss,this.tipLeftStyle,!0)),tipRightStyle:CKEDITOR.tools.writeCssText(CKEDITOR.tools.extend({},h,{right:"0px","border-right-color":"red","border-width":"6px 6px 6px 0"},this.tipCss,this.tipRightStyle,!0))})}function a(a){var b;if(b=a&&a.type==CKEDITOR.NODE_ELEMENT)b=!(n[a.getComputedStyle("float")]||n[a.getAttribute("align")]);return b&&
!k[a.getComputedStyle("position")]}CKEDITOR.plugins.add("lineutils");CKEDITOR.LINEUTILS_BEFORE=1;CKEDITOR.LINEUTILS_AFTER=2;CKEDITOR.LINEUTILS_INSIDE=4;b.prototype={start:function(a){var b=this,e=this.editor,g=this.doc,h,k,l,n,q=CKEDITOR.tools.eventsBuffer(50,function(){e.readOnly||"wysiwyg"!=e.mode||(b.relations={},(k=g.$.elementFromPoint(l,n))&&k.nodeType&&(h=new CKEDITOR.dom.element(k),b.traverseSearch(h),isNaN(l+n)||b.pixelSearch(h,l,n),a&&a(b.relations,l,n)))});this.listener=this.editable.attachListener(this.target,
"mousemove",function(a){l=a.data.$.clientX;n=a.data.$.clientY;q.input()});this.editable.attachListener(this.inline?this.editable:this.frame,"mouseout",function(){q.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 e=this.editor.createRange();e.moveToPosition(this.relations[b.uid].element,
a[b.type]);return e}}(),store:function(){function b(a,d,e){var g=a.getUniqueId();g in e?e[g].type|=d:e[g]={element:a,type:d}}return function(c,e){var g;e&CKEDITOR.LINEUTILS_AFTER&&a(g=c.getNext())&&g.isVisible()&&(b(g,CKEDITOR.LINEUTILS_BEFORE,this.relations),e^=CKEDITOR.LINEUTILS_AFTER);e&CKEDITOR.LINEUTILS_INSIDE&&a(g=c.getFirst())&&g.isVisible()&&(b(g,CKEDITOR.LINEUTILS_BEFORE,this.relations),e^=CKEDITOR.LINEUTILS_INSIDE);b(c,e,this.relations)}}(),traverseSearch:function(b){var c,e,g;do if(g=b.$["data-cke-expando"],
!(g&&g in this.relations)){if(b.equals(this.editable))break;if(a(b))for(c in this.lookups)(e=this.lookups[c](b))&&this.store(b,e)}while((!b||b.type!=CKEDITOR.NODE_ELEMENT||"true"!=b.getAttribute("contenteditable"))&&(b=b.getParent()))},pixelSearch:function(){function b(d,e,g,h,k){for(var l=0,n;k(g);){g+=h;if(25==++l)break;if(n=this.doc.$.elementFromPoint(e,g))if(n==d)l=0;else if(c(d,n)&&(l=0,a(n=new CKEDITOR.dom.element(n))))return n}}var c=CKEDITOR.env.ie||CKEDITOR.env.webkit?function(a,b){return a.contains(b)}:
function(a,b){return!!(a.compareDocumentPosition(b)&16)};return function(c,e,g){var h=this.win.getViewPaneSize().height,k=b.call(this,c.$,e,g,-1,function(a){return 0<a});e=b.call(this,c.$,e,g,1,function(a){return a<h});if(k)for(this.traverseSearch(k);!k.getParent().equals(c);)k=k.getParent();if(e)for(this.traverseSearch(e);!e.getParent().equals(c);)e=e.getParent();for(;k||e;){k&&(k=k.getNext(a));if(!k||k.equals(e))break;this.traverseSearch(k);e&&(e=e.getPrevious(a));if(!e||e.equals(k))break;this.traverseSearch(e)}}}(),
greedySearch:function(){this.relations={};for(var b=this.editable.getElementsByTag("*"),c=0,e,g,h;e=b.getItem(c++);)if(!e.equals(this.editable)&&e.type==CKEDITOR.NODE_ELEMENT&&(e.hasAttribute("contenteditable")||!e.isReadOnly())&&a(e)&&e.isVisible())for(h in this.lookups)(g=this.lookups[h](e))&&this.store(e,g);return this.relations}};g.prototype={locate:function(){function b(c,d){var e=c.element[d===CKEDITOR.LINEUTILS_BEFORE?"getPrevious":"getNext"]();return e&&a(e)?(c.siblingRect=e.getClientRect(),
d==CKEDITOR.LINEUTILS_BEFORE?(c.siblingRect.bottom+c.elementRect.top)/2:(c.elementRect.bottom+c.siblingRect.top)/2):d==CKEDITOR.LINEUTILS_BEFORE?c.elementRect.top:c.elementRect.bottom}return function(a){var e;this.locations={};for(var g in a)e=a[g],e.elementRect=e.element.getClientRect(),e.type&CKEDITOR.LINEUTILS_BEFORE&&this.store(g,CKEDITOR.LINEUTILS_BEFORE,b(e,CKEDITOR.LINEUTILS_BEFORE)),e.type&CKEDITOR.LINEUTILS_AFTER&&this.store(g,CKEDITOR.LINEUTILS_AFTER,b(e,CKEDITOR.LINEUTILS_AFTER)),e.type&
CKEDITOR.LINEUTILS_INSIDE&&this.store(g,CKEDITOR.LINEUTILS_INSIDE,(e.elementRect.top+e.elementRect.bottom)/2);return this.locations}}(),sort:function(){var a,b,e,g;return function(h,k){a=this.locations;b=[];for(var l in a)for(var n in a[l])if(e=Math.abs(h-a[l][n]),b.length){for(g=0;g<b.length;g++)if(e<b[g].dist){b.splice(g,0,{uid:+l,type:n,dist:e});break}g==b.length&&b.push({uid:+l,type:n,dist:e})}else b.push({uid:+l,type:n,dist:e});return"undefined"!=typeof k?b.slice(0,k):b}}(),store:function(a,
b,e){this.locations[a]||(this.locations[a]={});this.locations[a][b]=e}};var h={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};e.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 e,g,h;if(e=this.getStyle(a.uid,a.type)){for(h in this.visible)if(this.visible[h].getCustomData("hash")!==this.hash){g=this.visible[h];break}if(!g)for(h in this.hidden)if(this.hidden[h].getCustomData("hash")!==this.hash){this.showLine(g=this.hidden[h]);
break}g||this.showLine(g=this.addLine());g.setCustomData("hash",this.hash);this.visible[g.getUniqueId()]=g;g.setStyles(e);b&&b(g)}},getStyle:function(a,b){var e=this.relations[a],g=this.locations[a][b],h={};h.width=e.siblingRect?Math.max(e.siblingRect.width,e.elementRect.width):e.elementRect.width;h.top=this.inline?g+this.winTopScroll.y-this.rect.relativeY:this.rect.top+this.winTopScroll.y+g;if(h.top-this.winTopScroll.y<this.rect.top||h.top-this.winTopScroll.y>this.rect.bottom)return!1;this.inline?
h.left=e.elementRect.left-this.rect.relativeX:(0<e.elementRect.left?h.left=this.rect.left+e.elementRect.left:(h.width+=e.elementRect.left,h.left=this.rect.left),0<(e=h.left+h.width-(this.rect.left+this.winPane.width))&&(h.width-=e));h.left+=this.winTopScroll.x;for(var k in h)h[k]=CKEDITOR.tools.cssLength(h[k]);return h},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(),e=this.container.getComputedStyle("position");a.relativeX=a.relativeY=
0;"static"!=e&&(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 n={left:1,right:1,center:1},k={absolute:1,fixed:1};CKEDITOR.plugins.lineutils={finder:b,locator:g,liner:e}}(),function(){function b(b){return b.getName&&!b.hasAttribute("data-cke-temp")}CKEDITOR.plugins.add("widgetselection",{init:function(b){if(CKEDITOR.env.webkit){var e=CKEDITOR.plugins.widgetselection;b.on("contentDom",function(a){a=a.editor;var b=a.document,
g=a.editable();g.attachListener(b,"keydown",function(a){var b=a.data.$;65==a.data.getKey()&&(CKEDITOR.env.mac&&b.metaKey||!CKEDITOR.env.mac&&b.ctrlKey&&!b.altKey)&&CKEDITOR.tools.setTimeout(function(){e.addFillers(g)||e.removeFillers(g)},0)},null,null,-1);a.on("selectionCheck",function(a){e.removeFillers(a.editor.editable())});a.on("paste",function(a){a.data.dataValue=e.cleanPasteData(a.data.dataValue)});"selectall"in a.plugins&&e.addSelectAllIntegration(a)})}}});CKEDITOR.plugins.widgetselection=
{startFiller:null,endFiller:null,fillerAttribute:"data-cke-filler-webkit",fillerContent:"\x26nbsp;",fillerTagName:"div",addFillers:function(g){var e=g.editor;if(!this.isWholeContentSelected(g)&&0<g.getChildCount()){var a=g.getFirst(b),h=g.getLast(b);a&&a.type==CKEDITOR.NODE_ELEMENT&&!a.isEditable()&&(this.startFiller=this.createFiller(),g.append(this.startFiller,1));h&&h.type==CKEDITOR.NODE_ELEMENT&&!h.isEditable()&&(this.endFiller=this.createFiller(!0),g.append(this.endFiller,0));if(this.hasFiller(g))return e=
e.createRange(),e.selectNodeContents(g),e.select(),!0}return!1},removeFillers:function(b){if(this.hasFiller(b)&&!this.isWholeContentSelected(b)){var e=b.findOne(this.fillerTagName+"["+this.fillerAttribute+"\x3dstart]"),a=b.findOne(this.fillerTagName+"["+this.fillerAttribute+"\x3dend]");this.startFiller&&e&&this.startFiller.equals(e)?this.removeFiller(this.startFiller,b):this.startFiller=e;this.endFiller&&a&&this.endFiller.equals(a)?this.removeFiller(this.endFiller,b):this.endFiller=a}},cleanPasteData:function(b){b&&
b.length&&(b=b.replace(this.createFillerRegex(),"").replace(this.createFillerRegex(!0),""));return b},isWholeContentSelected:function(b){var e=b.editor.getSelection().getRanges()[0];return!e||e&&e.collapsed?!1:(e=e.clone(),e.enlarge(CKEDITOR.ENLARGE_ELEMENT),!!(e&&b&&e.startContainer&&e.endContainer&&0===e.startOffset&&e.endOffset===b.getChildCount()&&e.startContainer.equals(b)&&e.endContainer.equals(b)))},hasFiller:function(b){return 0<b.find(this.fillerTagName+"["+this.fillerAttribute+"]").count()},
createFiller:function(b){var e=new CKEDITOR.dom.element(this.fillerTagName);e.setHtml(this.fillerContent);e.setAttribute(this.fillerAttribute,b?"end":"start");e.setAttribute("data-cke-temp",1);e.setStyles({display:"block",width:0,height:0,padding:0,border:0,margin:0,position:"absolute",top:0,left:"-9999px",opacity:0,overflow:"hidden"});return e},removeFiller:function(b,e){if(b){var a=e.editor,h=e.editor.getSelection().getRanges()[0].startPath(),l=a.createRange(),n,k;h.contains(b)&&(n=b.getHtml(),
k=!0);h="start"==b.getAttribute(this.fillerAttribute);b.remove();n&&0<n.length&&n!=this.fillerContent?(e.insertHtmlIntoRange(n,a.getSelection().getRanges()[0]),l.setStartAt(e.getChild(e.getChildCount()-1),CKEDITOR.POSITION_BEFORE_END),a.getSelection().selectRanges([l])):k&&(h?l.setStartAt(e.getFirst().getNext(),CKEDITOR.POSITION_AFTER_START):l.setEndAt(e.getLast().getPrevious(),CKEDITOR.POSITION_BEFORE_END),e.editor.getSelection().selectRanges([l]))}},createFillerRegex:function(b){var e=this.createFiller(b).getOuterHtml().replace(/style="[^"]*"/gi,
'style\x3d"[^"]*"').replace(/>[^<]*</gi,"\x3e[^\x3c]*\x3c");return new RegExp((b?"":"^")+e+(b?"$":""))},addSelectAllIntegration:function(b){var e=this;b.editable().attachListener(b,"beforeCommandExec",function(a){var h=b.editable();"selectAll"==a.data.name&&h&&e.addFillers(h)},null,null,9999)}}}(),"use strict",function(){function b(a){this.editor=a;this.registered={};this.instances={};this.selected=[];this.widgetHoldingFocusedEditable=this.focused=null;this._={nextId:0,upcasts:[],upcastCallbacks:[],
filters:{}};B(this);u(this);this.on("checkWidgets",n);this.editor.on("contentDomInvalidated",this.checkWidgets,this);p(this);y(this);v(this);q(this);z(this)}function g(a,b,c,d,e){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:g.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);Z(this,d);this.init&&this.init();this.inited=!0;(a=this.element.data("cke-widget-data"))&&this.setData(JSON.parse(decodeURIComponent(a)));e&&this.setData(e);this.data.classes||this.setData("classes",this.getClasses());this.dataReady=!0;W(this);this.fire("data",this.data);this.isInited()&&f.editable().contains(this.wrapper)&&(this.ready=!0,this.fire("ready"))}function e(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 a(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 h(a,b){function c(b,d,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,[b,d,e])}var d=b.upcast,e=b.upcastPriority||10;if(d)if("string"==typeof d)for(d=d.split(",");d.length;)c(b.upcasts[d.pop()],b.name,e);else c(d,
b.name,e)}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 n(a){a=a.data;if("wysiwyg"==this.editor.mode){var b=this.editor.editable(),c=this.instances,d,e,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(e=k.count();d<e;d++){f=k.getItem(d);if(h=!this.getByElement(f,
!0)){a:{h=t;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(g.isDomWidgetElement))))}}a&&a.focusInited&&1==c.length&&c[0].focus()}}}function k(a,b,c){if(!c.allowedContent)return null;var d=this._.filters[a];d||(this._.filters[a]=d={});(a=d[b])||(d[b]=a=new CKEDITOR.filter(c.allowedContent));return a}function d(a){var b=[],c=a._.upcasts,d=a._.upcastCallbacks;return{toBeWrapped:b,iterator:function(a){var e,f,
h,k,l;if("data-cke-widget-wrapper"in a.attributes)return(a=a.getFirst(g.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(e=d.length;k<e;++k)if(!1===d[k](a))return;for(k=0;k<l;++k)if(e=c[k],h={},f=e[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,
e[1]]),!1}}}}function c(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 f(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 f(e,b,c)}}a.add(c,b)}function m(a,b){return"boolean"==typeof a.inline?
a.inline:!!CKEDITOR.dtd.$inline[b]}function t(a){return a.hasAttribute("data-cke-temp")}function x(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 A(a){a.contextMenu&&a.contextMenu.addListener(function(b){if(b=a.widgets.getByElement(b,!0))return b.fire("contextMenu",{})})}function r(a,b){return CKEDITOR.tools.trim(b)}function q(a){var b=a.editor,c=CKEDITOR.plugins.lineutils;b.on("dragstart",function(c){var d=c.data.target;g.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)&&!g.isDomNestedEditable(b)&&!a._.draggedWidget.wrapper.contains(b)){var c=g.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 y(a){var b=a.editor;b.on("contentDom",function(){var c=b.editable(),d=c.isInline()?c:b.document,e,f;c.attachListener(d,"mousedown",function(c){var d=c.data.getTarget();if(!d.type)return!1;e=a.getByElement(d);f=0;e&&(e.inline&&d.type==CKEDITOR.NODE_ELEMENT&&d.hasAttribute("data-cke-widget-drag-handler")?
(f=1,a.focused!=e&&b.getSelection().removeAllRanges()):g.getNestedEditable(e.wrapper,d)?e=null:(c.data.preventDefault(),CKEDITOR.env.ie||e.focus()))});c.attachListener(d,"mouseup",function(){f&&e&&e.wrapper&&(f=0,e.focus())});CKEDITOR.env.ie&&c.attachListener(d,"mouseup",function(){setTimeout(function(){e&&e.wrapper&&c.contains(e.wrapper)&&(e.focus(),e=null)})})});b.on("doubleclick",function(b){var c=a.getByElement(b.data.element);if(c&&!g.getNestedEditable(c.wrapper,b.data.element))return c.fire("doubleclick",
{element:b.data.element})},null,null,1)}function v(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 z(a){function b(c){a.focused&&F(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 p(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=g.getNestedEditable(b.editable(),c.data.selection.getStartElement()))&&a.getByElement(c),e=a.widgetHoldingFocusedEditable;
e?e===d&&e.focusedEditable.equals(c)||(x(a,e,null),d&&c&&x(a,d,c)):d&&c&&x(a,d,c)});b.on("dataReady",function(){w(a).commit()});b.on("blur",function(){var b;(b=a.focused)&&l(a,b);(b=a.widgetHoldingFocusedEditable)&&x(a,b,null)})}function u(a){var b=a.editor,c={};b.on("toDataFormat",function(b){var d=CKEDITOR.tools.getNextNumber(),e=[];b.data.downcastingSessionId=d;c[d]=e;b.data.dataValue.forEach(function(b){var c=b.attributes,d;if("data-cke-widget-id"in c){if(c=a.instances[c["data-cke-widget-id"]])d=
b.getFirst(g.isParserWidgetElement),e.push({wrapper:b,element:d,widget:c,editables:{}}),"1"!=d.attributes["data-cke-widget-keep-attr"]&&delete d.attributes["data-widget"]}else if("data-cke-widget-editable"in c)return e[e.length-1].editables[c["data-cke-widget-editable"]]=b,!1},CKEDITOR.NODE_ELEMENT,!0)},null,null,8);b.on("toDataFormat",function(a){if(a.data.downcastingSessionId){a=c[a.data.downcastingSessionId];for(var b,d,e,g,f,h;b=a.shift();){d=b.widget;e=b.element;g=d._.downcastFn&&d._.downcastFn.call(d,
e);for(h in b.editables)f=b.editables[h],delete f.attributes.contenteditable,f.setHtml(d.editables[h].getData());g||(g=e);b.wrapper.replaceWith(g)}}},null,null,13);b.on("contentDomUnload",function(){a.destroyAll(!0)})}function B(a){var b=a.editor,c,e;b.on("toHtml",function(b){var e=d(a),f;for(b.data.dataValue.forEach(e.iterator,CKEDITOR.NODE_ELEMENT,!0);f=e.toBeWrapped.pop();){var h=f[0],k=h.parent;k.type==CKEDITOR.NODE_ELEMENT&&k.attributes["data-cke-widget-wrapper"]&&k.replaceWith(h);a.wrapElement(f[0],
f[1])}c=b.data.protectedWhitespaces?3==b.data.dataValue.children.length&&g.isParserWidgetWrapper(b.data.dataValue.children[1]):1==b.data.dataValue.children.length&&g.isParserWidgetWrapper(b.data.dataValue.children[0])},null,null,8);b.on("dataReady",function(){if(e)for(var c=b.editable().find(".cke_widget_wrapper"),d,f,h=0,k=c.count();h<k;++h)d=c.getItem(h),f=d.getFirst(g.isDomWidgetElement),f.type==CKEDITOR.NODE_ELEMENT&&f.data("widget")?(f.replace(d),a.wrapElement(f)):d.remove();e=0;a.destroyAll(!0);
a.initOnAll()});b.on("loadSnapshot",function(b){/data-cke-widget/.test(b.data)&&(e=1);a.destroyAll(!0)},null,null,9);b.on("paste",function(a){a=a.data;a.dataValue=a.dataValue.replace(ea,r);a.range&&(a=g.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 w(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 C(a,b,c){var d=0;b=G(b);var e=a.data.classes||{},f;if(b){for(e=CKEDITOR.tools.clone(e);f=b.pop();)c?e[f]||(d=e[f]=1):e[f]&&(delete e[f],d=1);d&&a.setData("classes",e)}}function D(a){a.cancel()}function F(a,b){var c=a.editor,d=c.document;if(!d.getById("cke_copybin")){var e=c.blockless||CKEDITOR.env.ie?"span":"div",f=d.createElement(e),g=d.createElement(e),e=
CKEDITOR.env.ie&&9>CKEDITOR.env.version;g.setAttributes({id:"cke_copybin","data-cke-temp":"1"});f.setStyles({position:"absolute",width:"1px",height:"1px",overflow:"hidden"});f.setStyle("ltr"==c.config.contentsLangDirection?"left":"right","-5000px");var h=c.createRange();h.setStartBefore(a.wrapper);h.setEndAfter(a.wrapper);f.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");g.append(f);c.editable().append(g);var k=c.on("selectionChange",D,null,null,0),l=a.repository.on("checkSelection",D,null,null,0);if(e)var m=d.getDocumentElement().$,n=m.scrollTop;h=c.createRange();h.selectNodeContents(f);h.select();e&&(m.scrollTop=n);setTimeout(function(){b||a.focus();g.remove();k.removeListener();l.removeListener();c.fire("unlockSnapshot");b&&(a.repository.del(a),c.fire("saveSnapshot"))},100)}}function G(a){return(a=(a=a.getDefinition().attributes)&&a["class"])?
a.split(/\s+/):null}function L(){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 I(){CKEDITOR.env.gecko&&this.editor.unlockSelection();CKEDITOR.env.webkit||(this.editor.forceNextSelectionCheck(),this.editor.selectionChange(1))}function P(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 H(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 E(a){if(a.draggable){var b=a.editor,c=a.wrapper.getLast(g.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",S,a),CKEDITOR.env.ie&&9>CKEDITOR.env.version))d.on("dragstart",function(a){a.data.preventDefault(!0)});a.dragHandlerContainer=c}}function S(a){function b(){var c;for(p.reset();c=h.pop();)c.removeListener();var d=k;c=a.sender;var e=this.repository.finder,f=this.repository.liner,g=this.editor,l=this.editor.editable();CKEDITOR.tools.isEmpty(f.visible)||(d=e.getRange(d[0]),this.focus(),g.fire("drop",{dropRange:d,target:d.startContainer}));
l.removeClass("cke_widget_dragging");f.hideVisible();g.fire("dragend",{target:c})}var c=this.repository.finder,d=this.repository.locator,e=this.repository.liner,f=this.editor,g=f.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())});g.addClass("cke_widget_dragging");h.push(g.on("mousemove",function(a){m=a.data.$.clientY;p.input()}));f.fire("dragstart",
{target:a.sender});h.push(f.document.once("mouseup",b,this));g.isInline()||h.push(CKEDITOR.document.once("mouseup",b,this))}function O(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 T(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 Q(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 Z(a,b){aa(a);Q(a);O(a);T(a);E(a);P(a);H(a);if(CKEDITOR.env.ie&&9>CKEDITOR.env.version)a.wrapper.on("dragstart",function(b){var c=b.data.getTarget();g.getNestedEditable(a,c)||a.inline&&g.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){F(a,b==CKEDITOR.CTRL+88);return}if(b in N||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 aa(a){(a.wrapper=a.element.getParent()).setAttribute("data-cke-widget-id",a.id)}function W(a){a.element.data("cke-widget-data",encodeURIComponent(JSON.stringify(a.data)))}CKEDITOR.plugins.add("widget",{requires:"lineutils,clipboard,widgetselection",
onLoad:function(){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}")},
beforeInit:function(a){a.widgets=new b(a)},afterInit:function(a){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"});A(a)}});b.prototype={MIN_SELECTION_CHECK_INTERVAL:500,add:function(b,c){c=CKEDITOR.tools.prototypedCopy(c);c.name=b;c._=c._||{};this.editor.fire("widgetDefinition",c);c.template&&(c.template=new CKEDITOR.template(c.template));a(this.editor,c);h(this,c);return this.registered[b]=
c},addUpcastCallback:function(a){this._.upcastCallbacks.push(a)},checkSelection:function(){var a=this.editor.getSelection(),b=a.getSelectedElement(),c=w(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=g.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&&x(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(),f=0;f<e;++f)(c=this.getByElement(d.getItem(f),
!0))&&this.destroy(c)}else for(d in e)c=e[d],this.destroy(c,a)},finalizeCreation:function(a){(a=a.getFirst())&&g.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 g(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(g.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 d=null,e,g;if(a instanceof CKEDITOR.dom.element){b=b||a.data("widget");e=this.registered[b];if(!e)return null;
if((d=a.getParent())&&d.type==CKEDITOR.NODE_ELEMENT&&d.data("cke-widget-wrapper"))return d;a.hasAttribute("data-cke-widget-keep-attr")||a.data("cke-widget-keep-attr",a.data("widget")?1:0);a.data("widget",b);g=m(e,a.getName());d=new CKEDITOR.dom.element(g?"span":"div");d.setAttributes(c(g,b));d.data("cke-display-name",e.pathName?e.pathName:a.getName());a.getParent(!0)&&d.replace(a);a.appendTo(d)}else if(a instanceof CKEDITOR.htmlParser.element){b=b||a.attributes["data-widget"];e=this.registered[b];
if(!e)return null;if((d=a.parent)&&d.type==CKEDITOR.NODE_ELEMENT&&d.attributes["data-cke-widget-wrapper"])return d;"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);g=m(e,a.name);d=new CKEDITOR.htmlParser.element(g?"span":"div",c(g,b));d.attributes["data-cke-display-name"]=e.pathName?e.pathName:a.name;e=a.parent;var h;e&&(h=a.getIndex(),a.remove());d.add(a);e&&f(e,h,d)}return d},_tests_createEditableFilter:k};
CKEDITOR.event.implementOn(b.prototype);g.prototype={addClass:function(a){this.element.addClass(a);this.wrapper.addClass(g.WRAPPER_CLASS_PREFIX+a)},applyStyle:function(a){C(this,a,1)},checkStyleActive:function(a){a=G(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",I);c.removeListener("blur",L);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,b){var c=this._findOneNotNested(b.selector);return c&&c.is(CKEDITOR.dtd.$editable)?(c=new e(this.editor,c,{filter:k.call(this.repository,this.name,a,b)}),this.editables[a]=c,c.setAttributes({contenteditable:"true","data-cke-widget-editable":a,"data-cke-enter-mode":c.enterMode}),c.filter&&
c.data("cke-filter",c.filter.id),c.addClass("cke_widget_editable"),c.removeClass("cke_widget_editable_focused"),b.pathName&&c.data("cke-display-name",b.pathName),this.editor.focusManager.add(c),c.on("focus",I,this),CKEDITOR.env.ie&&c.on("blur",L,this),c._.initialSetData=!0,c.setData(c.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(g.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(g.WRAPPER_CLASS_PREFIX+a)},removeStyle:function(a){C(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&&(W(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(g.prototype);g.getNestedEditable=function(a,b){return!b||b.equals(a)?null:g.isDomNestedEditable(b)?b:g.getNestedEditable(a,b.getParent())};g.isDomDragHandler=function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasAttribute("data-cke-widget-drag-handler")};g.isDomDragHandlerContainer=function(a){return a.type==
CKEDITOR.NODE_ELEMENT&&a.hasClass("cke_widget_drag_handler_container")};g.isDomNestedEditable=function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasAttribute("data-cke-widget-editable")};g.isDomWidgetElement=function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasAttribute("data-widget")};g.isDomWidgetWrapper=function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasAttribute("data-cke-widget-wrapper")};g.isParserWidgetElement=function(a){return a.type==CKEDITOR.NODE_ELEMENT&&!!a.attributes["data-widget"]};
g.isParserWidgetWrapper=function(a){return a.type==CKEDITOR.NODE_ELEMENT&&!!a.attributes["data-cke-widget-wrapper"]};g.WRAPPER_CLASS_PREFIX="cke_widget_wrapper_";e.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 ea=/^(?:<(?: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,N={37:1,38:1,39:1,40:1,8:1,46:1};(function(){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 f=0,g=this.group.length;f<g;f++){b=c[this.widget][this.group[f]];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 g.isDomWidgetWrapper(a)?(a=a.getFirst(g.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.widget=g;g.repository=b;g.nestedEditable=e}(),
CKEDITOR.config.plugins="basicstyles,dialogui,dialog,clipboard,button,panelbutton,panel,floatpanel,colorbutton,colordialog,divarea,elementspath,enterkey,entities,floatingspace,listblock,richcombo,font,htmlwriter,indent,indentblock,indentlist,justify,list,sourcearea,toolbar,undo,lineutils,widgetselection,widget",CKEDITOR.config.skin="moono",function(){var b=function(b,e){var a=CKEDITOR.getUrl("plugins/"+e);b=b.split(",");for(var h=0;h<b.length;h++)CKEDITOR.skin.icons[b[h]]={path:a,offset:-b[++h],bgsize:b[++h]}};
CKEDITOR.env.hidpi?b("bold,0,,italic,24,,strike,48,,subscript,72,,superscript,96,,underline,120,,copy-rtl,144,,copy,168,,cut-rtl,192,,cut,216,,paste-rtl,240,,paste,264,,bgcolor,288,,textcolor,312,,indent-rtl,336,,indent,360,,outdent-rtl,384,,outdent,408,,ipscode,432,,ipsemoticon,456,,ipsimage,480,,ipslink,504,,unlink,528,,ipspage,1104,auto,pastetext,576,,ipspreview-rtl,600,,ipspreview,624,,ipsquote,648,,ipsspoiler,672,,justifyblock,696,,justifycenter,720,,justifyleft,744,,justifyright,768,,bulletedlist-rtl,792,,bulletedlist,816,,numberedlist-rtl,840,,numberedlist,864,,removeformat,888,,source-rtl,912,,source,936,,redo-rtl,960,,redo,984,,undo-rtl,1008,,undo,1032,,simplebox,2112,auto",
"icons_hidpi.png"):b("bold,0,auto,italic,24,auto,strike,48,auto,subscript,72,auto,superscript,96,auto,underline,120,auto,copy-rtl,144,auto,copy,168,auto,cut-rtl,192,auto,cut,216,auto,paste-rtl,240,auto,paste,264,auto,bgcolor,288,auto,textcolor,312,auto,indent-rtl,336,auto,indent,360,auto,outdent-rtl,384,auto,outdent,408,auto,ipscode,432,auto,ipsemoticon,456,auto,ipsimage,480,auto,ipslink,504,auto,unlink,528,auto,ipspage,552,auto,pastetext,576,auto,ipspreview-rtl,600,auto,ipspreview,624,auto,ipsquote,648,auto,ipsspoiler,672,auto,justifyblock,696,auto,justifycenter,720,auto,justifyleft,744,auto,justifyright,768,auto,bulletedlist-rtl,792,auto,bulletedlist,816,auto,numberedlist-rtl,840,auto,numberedlist,864,auto,removeformat,888,auto,source-rtl,912,auto,source,936,auto,redo-rtl,960,auto,redo,984,auto,undo-rtl,1008,auto,undo,1032,auto,simplebox,1056,auto",
"icons.png")}(),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:1,"en-au":1,"en-ca":1,"en-gb":1,eo:1,es: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,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: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})})();