/*
Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.md or http://ckeditor.com/license
*/
(function(){if(!window.CKEDITOR||!window.CKEDITOR.dom){window.CKEDITOR||(window.CKEDITOR=function(){var a=/(^|.*[\\\/])ckeditor\.js(?:\?.*|;.*)?$/i,f={timestamp:"F6EE",version:"DEV",revision:"0",rnd:Math.floor(900*Math.random())+100,_:{pending:[],basePathSrcPattern:a},status:"unloaded",basePath:function(){var b=window.CKEDITOR_BASEPATH||"";if(!b)for(var g=document.getElementsByTagName("script"),c=0;c<g.length;c++){var e=g[c].src.match(a);if(e){b=e[1];break}}-1==b.indexOf(":/")&&"//"!=b.slice(0,2)&&
(b=0===b.indexOf("/")?location.href.match(/^.*?:\/\/[^\/]*/)[0]+b:location.href.match(/^[^\?]*\/(?:)/)[0]+b);if(!b)throw'The CKEditor installation path could not be automatically detected. Please set the global variable "CKEDITOR_BASEPATH" before creating editor instances.';return b}(),getUrl:function(b){-1==b.indexOf(":/")&&0!==b.indexOf("/")&&(b=this.basePath+b);this.timestamp&&("/"!=b.charAt(b.length-1)&&!/[&?]t=/.test(b))&&(b+=(0<=b.indexOf("?")?"&":"?")+"t="+this.timestamp);return b},domReady:function(){function b(){try{document.addEventListener?
(document.removeEventListener("DOMContentLoaded",b,!1),g()):document.attachEvent&&"complete"===document.readyState&&(document.detachEvent("onreadystatechange",b),g())}catch(a){}}function g(){for(var b;b=a.shift();)b()}var a=[];return function(g){function c(){try{document.documentElement.doScroll("left")}catch(j){setTimeout(c,1);return}b()}a.push(g);"complete"===document.readyState&&setTimeout(b,1);if(1==a.length)if(document.addEventListener)document.addEventListener("DOMContentLoaded",b,!1),window.addEventListener("load",
b,!1);else if(document.attachEvent){document.attachEvent("onreadystatechange",b);window.attachEvent("onload",b);g=!1;try{g=!window.frameElement}catch(d){}document.documentElement.doScroll&&g&&c()}}}()},d=window.CKEDITOR_GETURL;if(d){var c=f.getUrl;f.getUrl=function(b){return d.call(f,b)||c.call(f,b)}}return f}());CKEDITOR.event||(CKEDITOR.event=function(){},CKEDITOR.event.implementOn=function(a){var f=CKEDITOR.event.prototype,d;for(d in f)a[d]==null&&(a[d]=f[d])},CKEDITOR.event.prototype=function(){function a(a){var b=
f(this);return b[a]||(b[a]=new d(a))}var f=function(a){a=a.getPrivate&&a.getPrivate()||a._||(a._={});return a.events||(a.events={})},d=function(a){this.name=a;this.listeners=[]};d.prototype={getListenerIndex:function(a){for(var b=0,g=this.listeners;b<g.length;b++)if(g[b].fn==a)return b;return-1}};return{define:function(c,b){var g=a.call(this,c);CKEDITOR.tools.extend(g,b,true)},on:function(c,b,g,d,e){function h(j,a,e,m){j={name:c,sender:this,editor:j,data:a,listenerData:d,stop:e,cancel:m,removeListener:k};
return b.call(g,j)===false?false:j.data}function k(){m.removeListener(c,b)}var j=a.call(this,c);if(j.getListenerIndex(b)<0){j=j.listeners;g||(g=this);isNaN(e)&&(e=10);var m=this;h.fn=b;h.priority=e;for(var q=j.length-1;q>=0;q--)if(j[q].priority<=e){j.splice(q+1,0,h);return{removeListener:k}}j.unshift(h)}return{removeListener:k}},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},g=0,d=function(){g=1};return function(e,h,k){var j=f(this)[e],e=a,m=g;a=g=0;if(j){var q=j.listeners;if(q.length)for(var q=q.slice(0),l,o=0;o<q.length;o++){if(j.errorProof)try{l=q[o].call(this,k,h,b,d)}catch(p){}else l=q[o].call(this,k,h,b,d);l===false?g=1:typeof l!="undefined"&&(h=l);if(a||g)break}}h=g?false:typeof h=="undefined"?true:h;a=e;g=m;return h}}(),fireOnce:function(a,b,g){b=
this.fire(a,b,g);delete f(this)[a];return b},removeListener:function(a,b){var g=f(this)[a];if(g){var d=g.getListenerIndex(b);d>=0&&g.listeners.splice(d,1)}},removeAllListeners:function(){var a=f(this),b;for(b in a)delete a[b]},hasListeners:function(a){return(a=f(this)[a])&&a.listeners.length>0}}}());CKEDITOR.editor||(CKEDITOR.editor=function(){CKEDITOR._.pending.push([this,arguments]);CKEDITOR.event.call(this)},CKEDITOR.editor.prototype.fire=function(a,f){a in{instanceReady:1,loaded:1}&&(this[a]=
true);return CKEDITOR.event.prototype.fire.call(this,a,f,this)},CKEDITOR.editor.prototype.fireOnce=function(a,f){a in{instanceReady:1,loaded:1}&&(this[a]=true);return CKEDITOR.event.prototype.fireOnce.call(this,a,f,this)},CKEDITOR.event.implementOn(CKEDITOR.editor.prototype));CKEDITOR.env||(CKEDITOR.env=function(){var a=navigator.userAgent.toLowerCase(),f={ie:a.indexOf("trident/")>-1,webkit:a.indexOf(" applewebkit/")>-1,air:a.indexOf(" adobeair/")>-1,mac:a.indexOf("macintosh")>-1,quirks:document.compatMode==
"BackCompat"&&(!document.documentMode||document.documentMode<10),mobile:a.indexOf("mobile")>-1,iOS:/(ipad|iphone|ipod)/.test(a),isCustomDomain:function(){if(!this.ie)return false;var b=document.domain,a=window.location.hostname;return b!=a&&b!="["+a+"]"},secure:location.protocol=="https:"};f.gecko=navigator.product=="Gecko"&&!f.webkit&&!f.ie;if(f.webkit)a.indexOf("chrome")>-1?f.chrome=true:f.safari=true;var d=0;if(f.ie){d=f.quirks||!document.documentMode?parseFloat(a.match(/msie (\d+)/)[1]):document.documentMode;
f.ie9Compat=d==9;f.ie8Compat=d==8;f.ie7Compat=d==7;f.ie6Compat=d<7||f.quirks}if(f.gecko){var c=a.match(/rv:([\d\.]+)/);if(c){c=c[1].split(".");d=c[0]*1E4+(c[1]||0)*100+(c[2]||0)*1}}f.air&&(d=parseFloat(a.match(/ adobeair\/(\d+)/)[1]));f.webkit&&(d=parseFloat(a.match(/ applewebkit\/(\d+)/)[1]));f.version=d;f.isCompatible=f.iOS&&d>=534||f.ie&&d>6||f.gecko&&d>=2E4||f.air&&d>=1||f.webkit&&d>=522||false;f.hidpi=window.devicePixelRatio>=2;f.needsBrFiller=f.gecko||f.webkit||f.ie&&d>10;f.needsNbspFiller=
f.ie&&d<11;f.cssClass="cke_browser_"+(f.ie?"ie":f.gecko?"gecko":f.webkit?"webkit":"unknown");if(f.quirks)f.cssClass=f.cssClass+" cke_browser_quirks";if(f.ie)f.cssClass=f.cssClass+(" cke_browser_ie"+(f.quirks?"6 cke_browser_iequirks":f.version));if(f.air)f.cssClass=f.cssClass+" cke_browser_air";if(f.iOS)f.cssClass=f.cssClass+" cke_browser_ios";if(f.hidpi)f.cssClass=f.cssClass+" cke_hidpi";return f}());"unloaded"==CKEDITOR.status&&function(){CKEDITOR.event.implementOn(CKEDITOR);CKEDITOR.loadFullCore=
function(){if(CKEDITOR.status!="basic_ready")CKEDITOR.loadFullCore._load=1;else{delete CKEDITOR.loadFullCore;var a=document.createElement("script");a.type="text/javascript";a.src=CKEDITOR.basePath+"ckeditor.js";document.getElementsByTagName("head")[0].appendChild(a)}};CKEDITOR.loadFullCoreTimeout=0;CKEDITOR.add=function(a){(this._.pending||(this._.pending=[])).push(a)};(function(){CKEDITOR.domReady(function(){var a=CKEDITOR.loadFullCore,f=CKEDITOR.loadFullCoreTimeout;if(a){CKEDITOR.status="basic_ready";
a&&a._load?a():f&&setTimeout(function(){CKEDITOR.loadFullCore&&CKEDITOR.loadFullCore()},f*1E3)}})})();CKEDITOR.status="basic_loaded"}();CKEDITOR.dom={};(function(){var a=[],f=CKEDITOR.env.gecko?"-moz-":CKEDITOR.env.webkit?"-webkit-":CKEDITOR.env.ie?"-ms-":"",d=/&/g,c=/>/g,b=/</g,g=/"/g,i=/&amp;/g,e=/&gt;/g,h=/&lt;/g,k=/&quot;/g;CKEDITOR.on("reset",function(){a=[]});CKEDITOR.tools={arrayCompare:function(b,a){if(!b&&!a)return true;if(!b||!a||b.length!=a.length)return false;for(var g=0;g<b.length;g++)if(b[g]!=
a[g])return false;return true},clone:function(b){var a;if(b&&b instanceof Array){a=[];for(var g=0;g<b.length;g++)a[g]=CKEDITOR.tools.clone(b[g]);return a}if(b===null||typeof b!="object"||b instanceof String||b instanceof Number||b instanceof Boolean||b instanceof Date||b instanceof RegExp||b.nodeType||b.window===b)return b;a=new b.constructor;for(g in b)a[g]=CKEDITOR.tools.clone(b[g]);return a},capitalize:function(b,a){return b.charAt(0).toUpperCase()+(a?b.slice(1):b.slice(1).toLowerCase())},extend:function(b){var a=
arguments.length,g,e;if(typeof(g=arguments[a-1])=="boolean")a--;else if(typeof(g=arguments[a-2])=="boolean"){e=arguments[a-1];a=a-2}for(var c=1;c<a;c++){var d=arguments[c],i;for(i in d)if(g===true||b[i]==null)if(!e||i in e)b[i]=d[i]}return b},prototypedCopy:function(b){var a=function(){};a.prototype=b;return new a},copy:function(b){var a={},g;for(g in b)a[g]=b[g];return a},isArray:function(b){return Object.prototype.toString.call(b)=="[object Array]"},isEmpty:function(b){for(var a in b)if(b.hasOwnProperty(a))return false;
return true},cssVendorPrefix:function(b,a,g){if(g)return f+b+":"+a+";"+b+":"+a;g={};g[b]=a;g[f+b]=a;return g},cssStyleToDomStyle:function(){var b=document.createElement("div").style,a=typeof b.cssFloat!="undefined"?"cssFloat":typeof b.styleFloat!="undefined"?"styleFloat":"float";return function(b){return b=="float"?a:b.replace(/-./g,function(b){return b.substr(1).toUpperCase()})}}(),buildStyleHtml:function(b){for(var b=[].concat(b),a,g=[],e=0;e<b.length;e++)if(a=b[e])/@import|[{}]/.test(a)?g.push("<style>"+
a+"</style>"):g.push('<link type="text/css" rel=stylesheet href="'+a+'">');return g.join("")},htmlEncode:function(j){return(""+j).replace(d,"&amp;").replace(c,"&gt;").replace(b,"&lt;")},htmlDecode:function(b){return b.replace(i,"&").replace(e,">").replace(h,"<")},htmlEncodeAttr:function(j){return j.replace(g,"&quot;").replace(b,"&lt;").replace(c,"&gt;")},htmlDecodeAttr:function(b){return b.replace(k,'"').replace(h,"<").replace(e,">")},getNextNumber:function(){var b=0;return function(){return++b}}(),
getNextId:function(){return"cke_"+this.getNextNumber()},override:function(b,a){var g=a(b);g.prototype=b.prototype;return g},setTimeout:function(b,a,g,e,c){c||(c=window);g||(g=c);return c.setTimeout(function(){e?b.apply(g,[].concat(e)):b.apply(g)},a||0)},trim:function(){var b=/(?:^[ \t\n\r]+)|(?:[ \t\n\r]+$)/g;return function(a){return a.replace(b,"")}}(),ltrim:function(){var b=/^[ \t\n\r]+/g;return function(a){return a.replace(b,"")}}(),rtrim:function(){var b=/[ \t\n\r]+$/g;return function(a){return a.replace(b,
"")}}(),indexOf:function(b,a){if(typeof a=="function")for(var g=0,e=b.length;g<e;g++){if(a(b[g]))return g}else{if(b.indexOf)return b.indexOf(a);g=0;for(e=b.length;g<e;g++)if(b[g]===a)return g}return-1},search:function(b,a){var g=CKEDITOR.tools.indexOf(b,a);return g>=0?b[g]:null},bind:function(b,a){return function(){return b.apply(a,arguments)}},createClass:function(b){var a=b.$,g=b.base,e=b.privates||b._,c=b.proto,b=b.statics;!a&&(a=function(){g&&this.base.apply(this,arguments)});if(e)var d=a,a=function(){var b=
this._||(this._={}),a;for(a in e){var j=e[a];b[a]=typeof j=="function"?CKEDITOR.tools.bind(j,this):j}d.apply(this,arguments)};if(g){a.prototype=this.prototypedCopy(g.prototype);a.prototype.constructor=a;a.base=g;a.baseProto=g.prototype;a.prototype.base=function(){this.base=g.prototype.base;g.apply(this,arguments);this.base=arguments.callee}}c&&this.extend(a.prototype,c,true);b&&this.extend(a,b,true);return a},addFunction:function(b,g){return a.push(function(){return b.apply(g||this,arguments)})-1},
removeFunction:function(b){a[b]=null},callFunction:function(b){var g=a[b];return g&&g.apply(window,Array.prototype.slice.call(arguments,1))},cssLength:function(){var b=/^-?\d+\.?\d*px$/,a;return function(g){a=CKEDITOR.tools.trim(g+"")+"px";return b.test(a)?a:g||""}}(),convertToPx:function(){var b;return function(a){if(!b){b=CKEDITOR.dom.element.createFromHtml('<div style="position:absolute;left:-9999px;top:-9999px;margin:0px;padding:0px;border:0px;"></div>',CKEDITOR.document);CKEDITOR.document.getBody().append(b)}if(!/%$/.test(a)){b.setStyle("width",
a);return b.$.clientWidth}return a}}(),repeat:function(b,a){return Array(a+1).join(b)},tryThese:function(){for(var b,a=0,g=arguments.length;a<g;a++){var e=arguments[a];try{b=e();break}catch(c){}}return b},genKey:function(){return Array.prototype.slice.call(arguments).join("-")},defer:function(b){return function(){var a=arguments,g=this;window.setTimeout(function(){b.apply(g,a)},0)}},normalizeCssText:function(b,a){var g=[],e,c=CKEDITOR.tools.parseCssText(b,true,a);for(e in c)g.push(e+":"+c[e]);g.sort();
return g.length?g.join(";")+";":""},convertRgbToHex:function(b){return b.replace(/(?:rgb\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*\))/gi,function(b,a,g,j){b=[a,g,j];for(a=0;a<3;a++)b[a]=("0"+parseInt(b[a],10).toString(16)).slice(-2);return"#"+b.join("")})},parseCssText:function(b,a,g){var e={};if(g){g=new CKEDITOR.dom.element("span");g.setAttribute("style",b);b=CKEDITOR.tools.convertRgbToHex(g.getAttribute("style")||"")}if(!b||b==";")return e;b.replace(/&quot;/g,'"').replace(/\s*([^:;\s]+)\s*:\s*([^;]+)\s*(?=;|$)/g,
function(b,g,j){if(a){g=g.toLowerCase();g=="font-family"&&(j=j.toLowerCase().replace(/["']/g,"").replace(/\s*,\s*/g,","));j=CKEDITOR.tools.trim(j)}e[g]=j});return e},writeCssText:function(b,a){var g,e=[];for(g in b)e.push(g+":"+b[g]);a&&e.sort();return e.join("; ")},objectCompare:function(b,a,g){var e;if(!b&&!a)return true;if(!b||!a)return false;for(e in b)if(b[e]!=a[e])return false;if(!g)for(e in a)if(b[e]!=a[e])return false;return true},objectKeys:function(b){var a=[],g;for(g in b)a.push(g);return a},
convertArrayToObject:function(b,a){var g={};arguments.length==1&&(a=true);for(var e=0,c=b.length;e<c;++e)g[b[e]]=a;return g},fixDomain:function(){for(var b;;)try{b=window.parent.document.domain;break}catch(a){b=b?b.replace(/.+?(?:\.|$)/,""):document.domain;if(!b)break;document.domain=b}return!!b},eventsBuffer:function(b,a){function g(){c=(new Date).getTime();e=false;a()}var e,c=0;return{input:function(){if(!e){var a=(new Date).getTime()-c;a<b?e=setTimeout(g,b-a):g()}},reset:function(){e&&clearTimeout(e);
e=c=0}}},enableHtml5Elements:function(b,a){for(var g=["abbr","article","aside","audio","bdi","canvas","data","datalist","details","figcaption","figure","footer","header","hgroup","mark","meter","nav","output","progress","section","summary","time","video"],e=g.length,c;e--;){c=b.createElement(g[e]);a&&b.appendChild(c)}},checkIfAnyArrayItemMatches:function(b,a){for(var g=0,e=b.length;g<e;++g)if(b[g].match(a))return true;return false},checkIfAnyObjectPropertyMatches:function(b,a){for(var g in b)if(g.match(a))return true;
return false},transparentImageData:"data:image/gif;base64,R0lGODlhAQABAPABAP///wAAACH5BAEKAAAALAAAAAABAAEAAAICRAEAOw=="}})();CKEDITOR.dtd=function(){var a=CKEDITOR.tools.extend,f=function(b,a){for(var g=CKEDITOR.tools.clone(b),e=1;e<arguments.length;e++){var a=arguments[e],c;for(c in a)delete g[c]}return g},d={},c={},b={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},g={command:1,link:1,meta:1,noscript:1,script:1,style:1},i={},e={"#":1},h={center:1,dir:1,noframes:1};a(d,{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},e,
{acronym:1,applet:1,basefont:1,big:1,font:1,isindex:1,strike:1,style:1,tt:1});a(c,b,d,h);f={a:f(d,{a:1,button:1}),abbr:d,address:c,area:i,article:c,aside:c,audio:a({source:1,track:1},c),b:d,base:i,bdi:d,bdo:d,blockquote:c,body:c,br:i,button:f(d,{a:1,button:1}),canvas:d,caption:c,cite:d,code:d,col:i,colgroup:{col:1},command:i,datalist:a({option:1},d),dd:c,del:d,details:a({summary:1},c),dfn:d,div:c,dl:{dt:1,dd:1},dt:c,em:d,embed:i,fieldset:a({legend:1},c),figcaption:c,figure:a({figcaption:1},c),footer:c,
form:c,h1:d,h2:d,h3:d,h4:d,h5:d,h6:d,head:a({title:1,base:1},g),header:c,hgroup:{h1:1,h2:1,h3:1,h4:1,h5:1,h6:1},hr:i,html:a({head:1,body:1},c,g),i:d,iframe:e,img:i,input:i,ins:d,kbd:d,keygen:i,label:d,legend:d,li:c,link:i,main:c,map:c,mark:d,menu:a({li:1},c),meta:i,meter:f(d,{meter:1}),nav:c,noscript:a({link:1,meta:1,style:1},d),object:a({param:1},d),ol:{li:1},optgroup:{option:1},option:e,output:d,p:d,param:i,pre:d,progress:f(d,{progress:1}),q:d,rp:d,rt:d,ruby:a({rp:1,rt:1},d),s:d,samp:d,script:e,
section:c,select:{optgroup:1,option:1},small:d,source:i,span:d,strong:d,style:e,sub:d,summary:d,sup:d,table:{caption:1,colgroup:1,thead:1,tfoot:1,tbody:1,tr:1},tbody:{tr:1},td:c,textarea:e,tfoot:{tr:1},th:c,thead:{tr:1},time:f(d,{time:1}),title:e,tr:{th:1,td:1},track:i,u:d,ul:{li:1},"var":d,video:a({source:1,track:1},c),wbr:i,acronym:d,applet:a({param:1},c),basefont:i,big:d,center:c,dialog:i,dir:{li:1},font:d,isindex:i,noframes:c,strike:d,tt:d};a(f,{$block:a({audio:1,dd:1,dt:1,figcaption:1,li:1,video:1},
b,h),$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:d,$list:{dl:1,ol:1,ul:1},$listItem:{dd:1,dt:1,li:1},$nonBodyContent:a({body:1,head:1,html:1},f.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 f}();CKEDITOR.dom.event=function(a){this.$=a};CKEDITOR.dom.event.prototype={getKey:function(){return this.$.keyCode||this.$.which},getKeystroke:function(){var a=this.getKey();if(this.$.ctrlKey||this.$.metaKey)a=a+CKEDITOR.CTRL;this.$.shiftKey&&(a=a+CKEDITOR.SHIFT);this.$.altKey&&(a=a+CKEDITOR.ALT);return a},preventDefault:function(a){var f=this.$;f.preventDefault?f.preventDefault():f.returnValue=false;a&&this.stopPropagation()},stopPropagation:function(){var a=
this.$;a.stopPropagation?a.stopPropagation():a.cancelBubble=true},getTarget:function(){var a=this.$.target||this.$.srcElement;return a?new CKEDITOR.dom.node(a):null},getPhase:function(){return this.$.eventPhase||2},getPageOffset:function(){var a=this.getTarget().getDocument().$;return{x:this.$.pageX||this.$.clientX+(a.documentElement.scrollLeft||a.body.scrollLeft),y:this.$.pageY||this.$.clientY+(a.documentElement.scrollTop||a.body.scrollTop)}}};CKEDITOR.CTRL=1114112;CKEDITOR.SHIFT=2228224;CKEDITOR.ALT=
4456448;CKEDITOR.EVENT_PHASE_CAPTURING=1;CKEDITOR.EVENT_PHASE_AT_TARGET=2;CKEDITOR.EVENT_PHASE_BUBBLING=3;CKEDITOR.dom.domObject=function(a){if(a)this.$=a};CKEDITOR.dom.domObject.prototype=function(){var a=function(a,d){return function(c){typeof CKEDITOR!="undefined"&&a.fire(d,new CKEDITOR.dom.event(c))}};return{getPrivate:function(){var a;if(!(a=this.getCustomData("_")))this.setCustomData("_",a={});return a},on:function(f){var d=this.getCustomData("_cke_nativeListeners");if(!d){d={};this.setCustomData("_cke_nativeListeners",
d)}if(!d[f]){d=d[f]=a(this,f);this.$.addEventListener?this.$.addEventListener(f,d,!!CKEDITOR.event.useCapture):this.$.attachEvent&&this.$.attachEvent("on"+f,d)}return CKEDITOR.event.prototype.on.apply(this,arguments)},removeListener:function(a){CKEDITOR.event.prototype.removeListener.apply(this,arguments);if(!this.hasListeners(a)){var d=this.getCustomData("_cke_nativeListeners"),c=d&&d[a];if(c){this.$.removeEventListener?this.$.removeEventListener(a,c,false):this.$.detachEvent&&this.$.detachEvent("on"+
a,c);delete d[a]}}},removeAllListeners:function(){var a=this.getCustomData("_cke_nativeListeners"),d;for(d in a){var c=a[d];this.$.detachEvent?this.$.detachEvent("on"+d,c):this.$.removeEventListener&&this.$.removeEventListener(d,c,false);delete a[d]}CKEDITOR.event.prototype.removeAllListeners.call(this)}}}();(function(a){var f={};CKEDITOR.on("reset",function(){f={}});a.equals=function(a){try{return a&&a.$===this.$}catch(c){return false}};a.setCustomData=function(a,c){var b=this.getUniqueId();(f[b]||
(f[b]={}))[a]=c;return this};a.getCustomData=function(a){var c=this.$["data-cke-expando"];return(c=c&&f[c])&&a in c?c[a]:null};a.removeCustomData=function(a){var c=this.$["data-cke-expando"],c=c&&f[c],b,g;if(c){b=c[a];g=a in c;delete c[a]}return g?b:null};a.clearCustomData=function(){this.removeAllListeners();var a=this.$["data-cke-expando"];a&&delete f[a]};a.getUniqueId=function(){return this.$["data-cke-expando"]||(this.$["data-cke-expando"]=CKEDITOR.tools.getNextNumber())};CKEDITOR.event.implementOn(a)})(CKEDITOR.dom.domObject.prototype);
CKEDITOR.dom.node=function(a){return a?new CKEDITOR.dom[a.nodeType==CKEDITOR.NODE_DOCUMENT?"document":a.nodeType==CKEDITOR.NODE_ELEMENT?"element":a.nodeType==CKEDITOR.NODE_TEXT?"text":a.nodeType==CKEDITOR.NODE_COMMENT?"comment":a.nodeType==CKEDITOR.NODE_DOCUMENT_FRAGMENT?"documentFragment":"domObject"](a):this};CKEDITOR.dom.node.prototype=new CKEDITOR.dom.domObject;CKEDITOR.NODE_ELEMENT=1;CKEDITOR.NODE_DOCUMENT=9;CKEDITOR.NODE_TEXT=3;CKEDITOR.NODE_COMMENT=8;CKEDITOR.NODE_DOCUMENT_FRAGMENT=11;CKEDITOR.POSITION_IDENTICAL=
0;CKEDITOR.POSITION_DISCONNECTED=1;CKEDITOR.POSITION_FOLLOWING=2;CKEDITOR.POSITION_PRECEDING=4;CKEDITOR.POSITION_IS_CONTAINED=8;CKEDITOR.POSITION_CONTAINS=16;CKEDITOR.tools.extend(CKEDITOR.dom.node.prototype,{appendTo:function(a,f){a.append(this,f);return a},clone:function(a,f){var d=this.$.cloneNode(a),c=function(b){b["data-cke-expando"]&&(b["data-cke-expando"]=false);if(b.nodeType==CKEDITOR.NODE_ELEMENT){f||b.removeAttribute("id",false);if(a)for(var b=b.childNodes,g=0;g<b.length;g++)c(b[g])}};c(d);
return new CKEDITOR.dom.node(d)},hasPrevious:function(){return!!this.$.previousSibling},hasNext:function(){return!!this.$.nextSibling},insertAfter:function(a){a.$.parentNode.insertBefore(this.$,a.$.nextSibling);return a},insertBefore:function(a){a.$.parentNode.insertBefore(this.$,a.$);return a},insertBeforeMe:function(a){this.$.parentNode.insertBefore(a.$,this.$);return a},getAddress:function(a){for(var f=[],d=this.getDocument().$.documentElement,c=this.$;c&&c!=d;){var b=c.parentNode;b&&f.unshift(this.getIndex.call({$:c},
a));c=b}return f},getDocument:function(){return new CKEDITOR.dom.document(this.$.ownerDocument||this.$.parentNode.ownerDocument)},getIndex:function(a){function f(b,a){var e=a?b.nextSibling:b.previousSibling;return!e||e.nodeType!=CKEDITOR.NODE_TEXT?null:e.nodeValue?e:f(e,a)}var d=this.$,c=-1,b;if(!this.$.parentNode||a&&d.nodeType==CKEDITOR.NODE_TEXT&&!d.nodeValue&&!f(d)&&!f(d,true))return-1;do if(!a||!(d!=this.$&&d.nodeType==CKEDITOR.NODE_TEXT&&(b||!d.nodeValue))){c++;b=d.nodeType==CKEDITOR.NODE_TEXT}while(d=
d.previousSibling);return c},getNextSourceNode:function(a,f,d){if(d&&!d.call)var c=d,d=function(b){return!b.equals(c)};var a=!a&&this.getFirst&&this.getFirst(),b;if(!a){if(this.type==CKEDITOR.NODE_ELEMENT&&d&&d(this,true)===false)return null;a=this.getNext()}for(;!a&&(b=(b||this).getParent());){if(d&&d(b,true)===false)return null;a=b.getNext()}return!a||d&&d(a)===false?null:f&&f!=a.type?a.getNextSourceNode(false,f,d):a},getPreviousSourceNode:function(a,f,d){if(d&&!d.call)var c=d,d=function(b){return!b.equals(c)};
var a=!a&&this.getLast&&this.getLast(),b;if(!a){if(this.type==CKEDITOR.NODE_ELEMENT&&d&&d(this,true)===false)return null;a=this.getPrevious()}for(;!a&&(b=(b||this).getParent());){if(d&&d(b,true)===false)return null;a=b.getPrevious()}return!a||d&&d(a)===false?null:f&&a.type!=f?a.getPreviousSourceNode(false,f,d):a},getPrevious:function(a){var f=this.$,d;do d=(f=f.previousSibling)&&f.nodeType!=10&&new CKEDITOR.dom.node(f);while(d&&a&&!a(d));return d},getNext:function(a){var f=this.$,d;do d=(f=f.nextSibling)&&
new CKEDITOR.dom.node(f);while(d&&a&&!a(d));return d},getParent:function(a){var f=this.$.parentNode;return f&&(f.nodeType==CKEDITOR.NODE_ELEMENT||a&&f.nodeType==CKEDITOR.NODE_DOCUMENT_FRAGMENT)?new CKEDITOR.dom.node(f):null},getParents:function(a){var f=this,d=[];do d[a?"push":"unshift"](f);while(f=f.getParent());return d},getCommonAncestor:function(a){if(a.equals(this))return this;if(a.contains&&a.contains(this))return a;var f=this.contains?this:this.getParent();do if(f.contains(a))return f;while(f=
f.getParent());return null},getPosition:function(a){var f=this.$,d=a.$;if(f.compareDocumentPosition)return f.compareDocumentPosition(d);if(f==d)return CKEDITOR.POSITION_IDENTICAL;if(this.type==CKEDITOR.NODE_ELEMENT&&a.type==CKEDITOR.NODE_ELEMENT){if(f.contains){if(f.contains(d))return CKEDITOR.POSITION_CONTAINS+CKEDITOR.POSITION_PRECEDING;if(d.contains(f))return CKEDITOR.POSITION_IS_CONTAINED+CKEDITOR.POSITION_FOLLOWING}if("sourceIndex"in f)return f.sourceIndex<0||d.sourceIndex<0?CKEDITOR.POSITION_DISCONNECTED:
f.sourceIndex<d.sourceIndex?CKEDITOR.POSITION_PRECEDING:CKEDITOR.POSITION_FOLLOWING}for(var f=this.getAddress(),a=a.getAddress(),d=Math.min(f.length,a.length),c=0;c<=d-1;c++)if(f[c]!=a[c]){if(c<d)return f[c]<a[c]?CKEDITOR.POSITION_PRECEDING:CKEDITOR.POSITION_FOLLOWING;break}return f.length<a.length?CKEDITOR.POSITION_CONTAINS+CKEDITOR.POSITION_PRECEDING:CKEDITOR.POSITION_IS_CONTAINED+CKEDITOR.POSITION_FOLLOWING},getAscendant:function(a,f){var d=this.$,c,b;if(!f)d=d.parentNode;if(typeof a=="function"){b=
true;c=a}else{b=false;c=function(b){b=typeof b.nodeName=="string"?b.nodeName.toLowerCase():"";return typeof a=="string"?b==a:b in a}}for(;d;){if(c(b?new CKEDITOR.dom.node(d):d))return new CKEDITOR.dom.node(d);try{d=d.parentNode}catch(g){d=null}}return null},hasAscendant:function(a,f){var d=this.$;if(!f)d=d.parentNode;for(;d;){if(d.nodeName&&d.nodeName.toLowerCase()==a)return true;d=d.parentNode}return false},move:function(a,f){a.append(this.remove(),f)},remove:function(a){var f=this.$,d=f.parentNode;
if(d){if(a)for(;a=f.firstChild;)d.insertBefore(f.removeChild(a),f);d.removeChild(f)}return this},replace:function(a){this.insertBefore(a);a.remove()},trim:function(){this.ltrim();this.rtrim()},ltrim:function(){for(var a;this.getFirst&&(a=this.getFirst());){if(a.type==CKEDITOR.NODE_TEXT){var f=CKEDITOR.tools.ltrim(a.getText()),d=a.getLength();if(f){if(f.length<d){a.split(d-f.length);this.$.removeChild(this.$.firstChild)}}else{a.remove();continue}}break}},rtrim:function(){for(var a;this.getLast&&(a=
this.getLast());){if(a.type==CKEDITOR.NODE_TEXT){var f=CKEDITOR.tools.rtrim(a.getText()),d=a.getLength();if(f){if(f.length<d){a.split(f.length);this.$.lastChild.parentNode.removeChild(this.$.lastChild)}}else{a.remove();continue}}break}if(CKEDITOR.env.needsBrFiller)(a=this.$.lastChild)&&(a.type==1&&a.nodeName.toLowerCase()=="br")&&a.parentNode.removeChild(a)},isReadOnly:function(){var a=this;this.type!=CKEDITOR.NODE_ELEMENT&&(a=this.getParent());if(a&&typeof a.$.isContentEditable!="undefined")return!(a.$.isContentEditable||
a.data("cke-editable"));for(;a;){if(a.data("cke-editable"))break;if(a.getAttribute("contentEditable")=="false")return true;if(a.getAttribute("contentEditable")=="true")break;a=a.getParent()}return!a}});CKEDITOR.dom.window=function(a){CKEDITOR.dom.domObject.call(this,a)};CKEDITOR.dom.window.prototype=new CKEDITOR.dom.domObject;CKEDITOR.tools.extend(CKEDITOR.dom.window.prototype,{focus:function(){this.$.focus()},getViewPaneSize:function(){var a=this.$.document,f=a.compatMode=="CSS1Compat";return{width:(f?
a.documentElement.clientWidth:a.body.clientWidth)||0,height:(f?a.documentElement.clientHeight:a.body.clientHeight)||0}},getScrollPosition:function(){var a=this.$;if("pageXOffset"in a)return{x:a.pageXOffset||0,y:a.pageYOffset||0};a=a.document;return{x:a.documentElement.scrollLeft||a.body.scrollLeft||0,y:a.documentElement.scrollTop||a.body.scrollTop||0}},getFrame:function(){var a=this.$.frameElement;return a?new CKEDITOR.dom.element.get(a):null}});CKEDITOR.dom.document=function(a){CKEDITOR.dom.domObject.call(this,
a)};CKEDITOR.dom.document.prototype=new CKEDITOR.dom.domObject;CKEDITOR.tools.extend(CKEDITOR.dom.document.prototype,{type:CKEDITOR.NODE_DOCUMENT,appendStyleSheet:function(a){if(this.$.createStyleSheet)this.$.createStyleSheet(a);else{var f=new CKEDITOR.dom.element("link");f.setAttributes({rel:"stylesheet",type:"text/css",href:a});this.getHead().append(f)}},appendStyleText:function(a){if(this.$.createStyleSheet){var f=this.$.createStyleSheet("");f.cssText=a}else{var d=new CKEDITOR.dom.element("style",
this);d.append(new CKEDITOR.dom.text(a,this));this.getHead().append(d)}return f||d.$.sheet},createElement:function(a,f){var d=new CKEDITOR.dom.element(a,this);if(f){f.attributes&&d.setAttributes(f.attributes);f.styles&&d.setStyles(f.styles)}return d},createText:function(a){return new CKEDITOR.dom.text(a,this)},focus:function(){this.getWindow().focus()},getActive:function(){var a;try{a=this.$.activeElement}catch(f){return null}return new CKEDITOR.dom.element(a)},getById:function(a){return(a=this.$.getElementById(a))?
new CKEDITOR.dom.element(a):null},getByAddress:function(a,f){for(var d=this.$.documentElement,c=0;d&&c<a.length;c++){var b=a[c];if(f)for(var g=-1,i=0;i<d.childNodes.length;i++){var e=d.childNodes[i];if(!(f===true&&e.nodeType==3&&e.previousSibling&&e.previousSibling.nodeType==3)){g++;if(g==b){d=e;break}}}else d=d.childNodes[b]}return d?new CKEDITOR.dom.node(d):null},getElementsByTag:function(a,f){!(CKEDITOR.env.ie&&document.documentMode<=8)&&f&&(a=f+":"+a);return new CKEDITOR.dom.nodeList(this.$.getElementsByTagName(a))},
getHead:function(){var a=this.$.getElementsByTagName("head")[0];return a=a?new CKEDITOR.dom.element(a):this.getDocumentElement().append(new CKEDITOR.dom.element("head"),true)},getBody:function(){return new CKEDITOR.dom.element(this.$.body)},getDocumentElement:function(){return new CKEDITOR.dom.element(this.$.documentElement)},getWindow:function(){return new CKEDITOR.dom.window(this.$.parentWindow||this.$.defaultView)},write:function(a){this.$.open("text/html","replace");CKEDITOR.env.ie&&(a=a.replace(/(?:^\s*<!DOCTYPE[^>]*?>)|^/i,
'$&\n<script data-cke-temp="1">('+CKEDITOR.tools.fixDomain+")();<\/script>"));this.$.write(a);this.$.close()},find:function(a){return new CKEDITOR.dom.nodeList(this.$.querySelectorAll(a))},findOne:function(a){return(a=this.$.querySelector(a))?new CKEDITOR.dom.element(a):null},_getHtml5ShivFrag:function(){var a=this.getCustomData("html5ShivFrag");if(!a){a=this.$.createDocumentFragment();CKEDITOR.tools.enableHtml5Elements(a,true);this.setCustomData("html5ShivFrag",a)}return a}});CKEDITOR.dom.nodeList=
function(a){this.$=a};CKEDITOR.dom.nodeList.prototype={count:function(){return this.$.length},getItem:function(a){if(a<0||a>=this.$.length)return null;return(a=this.$[a])?new CKEDITOR.dom.node(a):null}};CKEDITOR.dom.element=function(a,f){typeof a=="string"&&(a=(f?f.$:document).createElement(a));CKEDITOR.dom.domObject.call(this,a)};CKEDITOR.dom.element.get=function(a){return(a=typeof a=="string"?document.getElementById(a)||document.getElementsByName(a)[0]:a)&&(a.$?a:new CKEDITOR.dom.element(a))};CKEDITOR.dom.element.prototype=
new CKEDITOR.dom.node;CKEDITOR.dom.element.createFromHtml=function(a,f){var d=new CKEDITOR.dom.element("div",f);d.setHtml(a);return d.getFirst().remove()};CKEDITOR.dom.element.setMarker=function(a,f,d,c){var b=f.getCustomData("list_marker_id")||f.setCustomData("list_marker_id",CKEDITOR.tools.getNextNumber()).getCustomData("list_marker_id"),g=f.getCustomData("list_marker_names")||f.setCustomData("list_marker_names",{}).getCustomData("list_marker_names");a[b]=f;g[d]=1;return f.setCustomData(d,c)};CKEDITOR.dom.element.clearAllMarkers=
function(a){for(var f in a)CKEDITOR.dom.element.clearMarkers(a,a[f],1)};CKEDITOR.dom.element.clearMarkers=function(a,f,d){var c=f.getCustomData("list_marker_names"),b=f.getCustomData("list_marker_id"),g;for(g in c)f.removeCustomData(g);f.removeCustomData("list_marker_names");if(d){f.removeCustomData("list_marker_id");delete a[b]}};(function(){function a(b){var a=true;if(!b.$.id){b.$.id="cke_tmp_"+CKEDITOR.tools.getNextNumber();a=false}return function(){a||b.removeAttribute("id")}}function f(b,a){return"#"+
b.$.id+" "+a.split(/,\s*/).join(", #"+b.$.id+" ")}function d(b){for(var a=0,d=0,e=c[b].length;d<e;d++)a=a+(parseInt(this.getComputedStyle(c[b][d])||0,10)||0);return a}CKEDITOR.tools.extend(CKEDITOR.dom.element.prototype,{type:CKEDITOR.NODE_ELEMENT,addClass:function(b){var a=this.$.className;a&&(RegExp("(?:^|\\s)"+b+"(?:\\s|$)","").test(a)||(a=a+(" "+b)));this.$.className=a||b;return this},removeClass:function(b){var a=this.getAttribute("class");if(a){b=RegExp("(?:^|\\s+)"+b+"(?=\\s|$)","i");if(b.test(a))(a=
a.replace(b,"").replace(/^\s+/,""))?this.setAttribute("class",a):this.removeAttribute("class")}return this},hasClass:function(b){return RegExp("(?:^|\\s+)"+b+"(?=\\s|$)","").test(this.getAttribute("class"))},append:function(b,a){typeof b=="string"&&(b=this.getDocument().createElement(b));a?this.$.insertBefore(b.$,this.$.firstChild):this.$.appendChild(b.$);return b},appendHtml:function(b){if(this.$.childNodes.length){var a=new CKEDITOR.dom.element("div",this.getDocument());a.setHtml(b);a.moveChildren(this)}else this.setHtml(b)},
appendText:function(b){this.$.text!=null?this.$.text=this.$.text+b:this.append(new CKEDITOR.dom.text(b))},appendBogus:function(b){if(b||CKEDITOR.env.needsBrFiller){for(b=this.getLast();b&&b.type==CKEDITOR.NODE_TEXT&&!CKEDITOR.tools.rtrim(b.getText());)b=b.getPrevious();if(!b||!b.is||!b.is("br")){b=this.getDocument().createElement("br");CKEDITOR.env.gecko&&b.setAttribute("type","_moz");this.append(b)}}},breakParent:function(b){var a=new CKEDITOR.dom.range(this.getDocument());a.setStartAfter(this);
a.setEndAfter(b);b=a.extractContents();a.insertNode(this.remove());b.insertAfterNode(this)},contains:CKEDITOR.env.ie||CKEDITOR.env.webkit?function(b){var a=this.$;return b.type!=CKEDITOR.NODE_ELEMENT?a.contains(b.getParent().$):a!=b.$&&a.contains(b.$)}:function(b){return!!(this.$.compareDocumentPosition(b.$)&16)},focus:function(){function b(){try{this.$.focus()}catch(b){}}return function(a){a?CKEDITOR.tools.setTimeout(b,100,this):b.call(this)}}(),getHtml:function(){var b=this.$.innerHTML;return CKEDITOR.env.ie?
b.replace(/<\?[^>]*>/g,""):b},getOuterHtml:function(){if(this.$.outerHTML)return this.$.outerHTML.replace(/<\?[^>]*>/,"");var b=this.$.ownerDocument.createElement("div");b.appendChild(this.$.cloneNode(true));return b.innerHTML},getClientRect:function(){var b=CKEDITOR.tools.extend({},this.$.getBoundingClientRect());!b.width&&(b.width=b.right-b.left);!b.height&&(b.height=b.bottom-b.top);return b},setHtml:CKEDITOR.env.ie&&CKEDITOR.env.version<9?function(b){try{var a=this.$;if(this.getParent())return a.innerHTML=
b;var c=this.getDocument()._getHtml5ShivFrag();c.appendChild(a);a.innerHTML=b;c.removeChild(a);return b}catch(e){this.$.innerHTML="";a=new CKEDITOR.dom.element("body",this.getDocument());a.$.innerHTML=b;for(a=a.getChildren();a.count();)this.append(a.getItem(0));return b}}:function(b){return this.$.innerHTML=b},setText:function(){var b=document.createElement("p");b.innerHTML="x";b=b.textContent;return function(a){this.$[b?"textContent":"innerText"]=a}}(),getAttribute:function(){var b=function(b){return this.$.getAttribute(b,
2)};return CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)?function(b){switch(b){case "class":b="className";break;case "http-equiv":b="httpEquiv";break;case "name":return this.$.name;case "tabindex":b=this.$.getAttribute(b,2);b!==0&&this.$.tabIndex===0&&(b=null);return b;case "checked":b=this.$.attributes.getNamedItem(b);return(b.specified?b.nodeValue:this.$.checked)?"checked":null;case "hspace":case "value":return this.$[b];case "style":return this.$.style.cssText;case "contenteditable":case "contentEditable":return this.$.attributes.getNamedItem("contentEditable").specified?
this.$.getAttribute("contentEditable"):null}return this.$.getAttribute(b,2)}:b}(),getChildren:function(){return new CKEDITOR.dom.nodeList(this.$.childNodes)},getComputedStyle:CKEDITOR.env.ie?function(b){return this.$.currentStyle[CKEDITOR.tools.cssStyleToDomStyle(b)]}:function(b){var a=this.getWindow().$.getComputedStyle(this.$,null);return a?a.getPropertyValue(b):""},getDtd:function(){var b=CKEDITOR.dtd[this.getName()];this.getDtd=function(){return b};return b},getElementsByTag:CKEDITOR.dom.document.prototype.getElementsByTag,
getTabIndex:CKEDITOR.env.ie?function(){var b=this.$.tabIndex;b===0&&(!CKEDITOR.dtd.$tabIndex[this.getName()]&&parseInt(this.getAttribute("tabindex"),10)!==0)&&(b=-1);return b}:CKEDITOR.env.webkit?function(){var b=this.$.tabIndex;if(b===void 0){b=parseInt(this.getAttribute("tabindex"),10);isNaN(b)&&(b=-1)}return b}:function(){return this.$.tabIndex},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 b=this.$.nodeName.toLowerCase();if(CKEDITOR.env.ie&&document.documentMode<=8){var a=this.$.scopeName;a!="HTML"&&(b=a.toLowerCase()+":"+b)}this.getName=function(){return b};return this.getName()},getValue:function(){return this.$.value},getFirst:function(b){var a=this.$.firstChild;(a=a&&new CKEDITOR.dom.node(a))&&(b&&!b(a))&&(a=a.getNext(b));return a},getLast:function(b){var a=this.$.lastChild;(a=a&&new CKEDITOR.dom.node(a))&&
(b&&!b(a))&&(a=a.getPrevious(b));return a},getStyle:function(b){return this.$.style[CKEDITOR.tools.cssStyleToDomStyle(b)]},is:function(){var b=this.getName();if(typeof arguments[0]=="object")return!!arguments[0][b];for(var a=0;a<arguments.length;a++)if(arguments[a]==b)return true;return false},isEditable:function(b){var a=this.getName();if(this.isReadOnly()||this.getComputedStyle("display")=="none"||this.getComputedStyle("visibility")=="hidden"||CKEDITOR.dtd.$nonEditable[a]||CKEDITOR.dtd.$empty[a]||
this.is("a")&&(this.data("cke-saved-name")||this.hasAttribute("name"))&&!this.getChildCount())return false;if(b!==false){b=CKEDITOR.dtd[a]||CKEDITOR.dtd.span;return!(!b||!b["#"])}return true},isIdentical:function(b){var a=this.clone(0,1),b=b.clone(0,1);a.removeAttributes(["_moz_dirty","data-cke-expando","data-cke-saved-href","data-cke-saved-name"]);b.removeAttributes(["_moz_dirty","data-cke-expando","data-cke-saved-href","data-cke-saved-name"]);if(a.$.isEqualNode){a.$.style.cssText=CKEDITOR.tools.normalizeCssText(a.$.style.cssText);
b.$.style.cssText=CKEDITOR.tools.normalizeCssText(b.$.style.cssText);return a.$.isEqualNode(b.$)}a=a.getOuterHtml();b=b.getOuterHtml();if(CKEDITOR.env.ie&&CKEDITOR.env.version<9&&this.is("a")){var c=this.getParent();if(c.type==CKEDITOR.NODE_ELEMENT){c=c.clone();c.setHtml(a);a=c.getHtml();c.setHtml(b);b=c.getHtml()}}return a==b},isVisible:function(){var b=(this.$.offsetHeight||this.$.offsetWidth)&&this.getComputedStyle("visibility")!="hidden",a,c;if(b&&CKEDITOR.env.webkit){a=this.getWindow();if(!a.equals(CKEDITOR.document.getWindow())&&
(c=a.$.frameElement))b=(new CKEDITOR.dom.element(c)).isVisible()}return!!b},isEmptyInlineRemoveable:function(){if(!CKEDITOR.dtd.$removeEmpty[this.getName()])return false;for(var b=this.getChildren(),a=0,c=b.count();a<c;a++){var e=b.getItem(a);if(!(e.type==CKEDITOR.NODE_ELEMENT&&e.data("cke-bookmark"))&&(e.type==CKEDITOR.NODE_ELEMENT&&!e.isEmptyInlineRemoveable()||e.type==CKEDITOR.NODE_TEXT&&CKEDITOR.tools.trim(e.getText())))return false}return true},hasAttributes:CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||
CKEDITOR.env.quirks)?function(){for(var b=this.$.attributes,a=0;a<b.length;a++){var c=b[a];switch(c.nodeName){case "class":if(this.getAttribute("class"))return true;case "data-cke-expando":continue;default:if(c.specified)return true}}return false}:function(){var b=this.$.attributes,a=b.length,c={"data-cke-expando":1,_moz_dirty:1};return a>0&&(a>2||!c[b[0].nodeName]||a==2&&!c[b[1].nodeName])},hasAttribute:function(){function b(b){var a=this.$.attributes.getNamedItem(b);if(this.getName()=="input")switch(b){case "class":return this.$.className.length>
0;case "checked":return!!this.$.checked;case "value":b=this.getAttribute("type");return b=="checkbox"||b=="radio"?this.$.value!="on":!!this.$.value}return!a?false:a.specified}return CKEDITOR.env.ie?CKEDITOR.env.version<8?function(a){return a=="name"?!!this.$.name:b.call(this,a)}:b:function(b){return!!this.$.attributes.getNamedItem(b)}}(),hide:function(){this.setStyle("display","none")},moveChildren:function(b,a){var c=this.$,b=b.$;if(c!=b){var e;if(a)for(;e=c.lastChild;)b.insertBefore(c.removeChild(e),
b.firstChild);else for(;e=c.firstChild;)b.appendChild(c.removeChild(e))}},mergeSiblings:function(){function b(b,a,e){if(a&&a.type==CKEDITOR.NODE_ELEMENT){for(var c=[];a.data("cke-bookmark")||a.isEmptyInlineRemoveable();){c.push(a);a=e?a.getNext():a.getPrevious();if(!a||a.type!=CKEDITOR.NODE_ELEMENT)return}if(b.isIdentical(a)){for(var d=e?b.getLast():b.getFirst();c.length;)c.shift().move(b,!e);a.moveChildren(b,!e);a.remove();d&&d.type==CKEDITOR.NODE_ELEMENT&&d.mergeSiblings()}}}return function(a){if(a===
false||CKEDITOR.dtd.$removeEmpty[this.getName()]||this.is("a")){b(this,this.getNext(),true);b(this,this.getPrevious())}}}(),show:function(){this.setStyles({display:"",visibility:""})},setAttribute:function(){var b=function(b,a){this.$.setAttribute(b,a);return this};return CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)?function(a,c){a=="class"?this.$.className=c:a=="style"?this.$.style.cssText=c:a=="tabindex"?this.$.tabIndex=c:a=="checked"?this.$.checked=c:a=="contenteditable"?b.call(this,
"contentEditable",c):b.apply(this,arguments);return this}:CKEDITOR.env.ie8Compat&&CKEDITOR.env.secure?function(a,c){if(a=="src"&&c.match(/^http:\/\//))try{b.apply(this,arguments)}catch(e){}else b.apply(this,arguments);return this}:b}(),setAttributes:function(b){for(var a in b)this.setAttribute(a,b[a]);return this},setValue:function(b){this.$.value=b;return this},removeAttribute:function(){var b=function(b){this.$.removeAttribute(b)};return CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)?
function(b){b=="class"?b="className":b=="tabindex"?b="tabIndex":b=="contenteditable"&&(b="contentEditable");this.$.removeAttribute(b)}:b}(),removeAttributes:function(b){if(CKEDITOR.tools.isArray(b))for(var a=0;a<b.length;a++)this.removeAttribute(b[a]);else for(a in b)b.hasOwnProperty(a)&&this.removeAttribute(a)},removeStyle:function(b){var a=this.$.style;if(!a.removeProperty&&(b=="border"||b=="margin"||b=="padding")){var c=["top","left","right","bottom"],e;b=="border"&&(e=["color","style","width"]);
for(var a=[],d=0;d<c.length;d++)if(e)for(var k=0;k<e.length;k++)a.push([b,c[d],e[k]].join("-"));else a.push([b,c[d]].join("-"));for(b=0;b<a.length;b++)this.removeStyle(a[b])}else{a.removeProperty?a.removeProperty(b):a.removeAttribute(CKEDITOR.tools.cssStyleToDomStyle(b));this.$.style.cssText||this.removeAttribute("style")}},setStyle:function(b,a){this.$.style[CKEDITOR.tools.cssStyleToDomStyle(b)]=a;return this},setStyles:function(b){for(var a in b)this.setStyle(a,b[a]);return this},setOpacity:function(b){if(CKEDITOR.env.ie&&
CKEDITOR.env.version<9){b=Math.round(b*100);this.setStyle("filter",b>=100?"":"progid:DXImageTransform.Microsoft.Alpha(opacity="+b+")")}else this.setStyle("opacity",b)},unselectable:function(){this.setStyles(CKEDITOR.tools.cssVendorPrefix("user-select","none"));if(CKEDITOR.env.ie){this.setAttribute("unselectable","on");for(var b,a=this.getElementsByTag("*"),c=0,e=a.count();c<e;c++){b=a.getItem(c);b.setAttribute("unselectable","on")}}},getPositionedAncestor:function(){for(var b=this;b.getName()!="html";){if(b.getComputedStyle("position")!=
"static")return b;b=b.getParent()}return null},getDocumentPosition:function(b){var a=0,c=0,e=this.getDocument(),d=e.getBody(),k=CKEDITOR.env.quirks;if(document.documentElement.getBoundingClientRect){var j=this.$.getBoundingClientRect(),m=e.$.documentElement,f=m.clientTop||d.$.clientTop||0,l=m.clientLeft||d.$.clientLeft||0,o=true;if(CKEDITOR.env.ie){o=e.getDocumentElement().contains(this);e=e.getBody().contains(this);o=k&&e||!k&&o}if(o){if(CKEDITOR.env.webkit){a=d.$.scrollLeft||m.scrollLeft;c=d.$.scrollTop||
m.scrollTop}else{c=k?d.$:m;a=c.scrollLeft;c=c.scrollTop}a=j.left+a-l;c=j.top+c-f}}else{f=this;for(l=null;f&&!(f.getName()=="body"||f.getName()=="html");){a=a+(f.$.offsetLeft-f.$.scrollLeft);c=c+(f.$.offsetTop-f.$.scrollTop);if(!f.equals(this)){a=a+(f.$.clientLeft||0);c=c+(f.$.clientTop||0)}for(;l&&!l.equals(f);){a=a-l.$.scrollLeft;c=c-l.$.scrollTop;l=l.getParent()}l=f;f=(j=f.$.offsetParent)?new CKEDITOR.dom.element(j):null}}if(b){j=this.getWindow();f=b.getWindow();if(!j.equals(f)&&j.$.frameElement){b=
(new CKEDITOR.dom.element(j.$.frameElement)).getDocumentPosition(b);a=a+b.x;c=c+b.y}}if(!document.documentElement.getBoundingClientRect&&CKEDITOR.env.gecko&&!k){a=a+(this.$.clientLeft?1:0);c=c+(this.$.clientTop?1:0)}return{x:a,y:c}},scrollIntoView:function(b){var a=this.getParent();if(a){do{(a.$.clientWidth&&a.$.clientWidth<a.$.scrollWidth||a.$.clientHeight&&a.$.clientHeight<a.$.scrollHeight)&&!a.is("body")&&this.scrollIntoParent(a,b,1);if(a.is("html")){var c=a.getWindow();try{var e=c.$.frameElement;
e&&(a=new CKEDITOR.dom.element(e))}catch(d){}}}while(a=a.getParent())}},scrollIntoParent:function(b,a,c){var e,d,k,j;function m(a,e){if(/body|html/.test(b.getName()))b.getWindow().$.scrollBy(a,e);else{b.$.scrollLeft=b.$.scrollLeft+a;b.$.scrollTop=b.$.scrollTop+e}}function f(b,a){var e={x:0,y:0};if(!b.is(o?"body":"html")){var c=b.$.getBoundingClientRect();e.x=c.left;e.y=c.top}c=b.getWindow();if(!c.equals(a)){c=f(CKEDITOR.dom.element.get(c.$.frameElement),a);e.x=e.x+c.x;e.y=e.y+c.y}return e}function l(b,
a){return parseInt(b.getComputedStyle("margin-"+a)||0,10)||0}!b&&(b=this.getWindow());k=b.getDocument();var o=k.$.compatMode=="BackCompat";b instanceof CKEDITOR.dom.window&&(b=o?k.getBody():k.getDocumentElement());k=b.getWindow();d=f(this,k);var p=f(b,k),r=this.$.offsetHeight;e=this.$.offsetWidth;var s=b.$.clientHeight,u=b.$.clientWidth;k=d.x-l(this,"left")-p.x||0;j=d.y-l(this,"top")-p.y||0;e=d.x+e+l(this,"right")-(p.x+u)||0;d=d.y+r+l(this,"bottom")-(p.y+s)||0;if(j<0||d>0)m(0,a===true?j:a===false?
d:j<0?j:d);if(c&&(k<0||e>0))m(k<0?k:e,0)},setState:function(b,a,c){a=a||"cke";switch(b){case CKEDITOR.TRISTATE_ON:this.addClass(a+"_on");this.removeClass(a+"_off");this.removeClass(a+"_disabled");c&&this.setAttribute("aria-pressed",true);c&&this.removeAttribute("aria-disabled");break;case CKEDITOR.TRISTATE_DISABLED:this.addClass(a+"_disabled");this.removeClass(a+"_off");this.removeClass(a+"_on");c&&this.setAttribute("aria-disabled",true);c&&this.removeAttribute("aria-pressed");break;default:this.addClass(a+
"_off");this.removeClass(a+"_on");this.removeClass(a+"_disabled");c&&this.removeAttribute("aria-pressed");c&&this.removeAttribute("aria-disabled")}},getFrameDocument:function(){var b=this.$;try{b.contentWindow.document}catch(a){b.src=b.src}return b&&new CKEDITOR.dom.document(b.contentWindow.document)},copyAttributes:function(b,a){for(var c=this.$.attributes,a=a||{},e=0;e<c.length;e++){var d=c[e],k=d.nodeName.toLowerCase(),j;if(!(k in a))if(k=="checked"&&(j=this.getAttribute(k)))b.setAttribute(k,j);
else if(!CKEDITOR.env.ie||this.hasAttribute(k)){j=this.getAttribute(k);if(j===null)j=d.nodeValue;b.setAttribute(k,j)}}if(this.$.style.cssText!=="")b.$.style.cssText=this.$.style.cssText},renameNode:function(b){if(this.getName()!=b){var a=this.getDocument(),b=new CKEDITOR.dom.element(b,a);this.copyAttributes(b);this.moveChildren(b);this.getParent()&&this.$.parentNode.replaceChild(b.$,this.$);b.$["data-cke-expando"]=this.$["data-cke-expando"];this.$=b.$;delete this.getName}},getChild:function(){function b(b,
a){var e=b.childNodes;if(a>=0&&a<e.length)return e[a]}return function(a){var c=this.$;if(a.slice)for(;a.length>0&&c;)c=b(c,a.shift());else c=b(c,a);return c?new CKEDITOR.dom.node(c):null}}(),getChildCount:function(){return this.$.childNodes.length},disableContextMenu:function(){this.on("contextmenu",function(a){a.data.getTarget().hasClass("cke_enable_context_menu")||a.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,c){a="data-"+a;if(c===void 0)return this.getAttribute(a);c===false?this.removeAttribute(a):this.setAttribute(a,c);return null},getEditor:function(){var a=CKEDITOR.instances,c,d;for(c in a){d=a[c];if(d.element.equals(this)&&d.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO)return d}return null},find:function(b){var c=a(this),b=new CKEDITOR.dom.nodeList(this.$.querySelectorAll(f(this,
b)));c();return b},findOne:function(b){var c=a(this),b=this.$.querySelector(f(this,b));c();return b?new CKEDITOR.dom.element(b):null},forEach:function(a,c,d){if(!d&&(!c||this.type==c))var e=a(this);if(e!==false)for(var d=this.getChildren(),h=0;h<d.count();h++){e=d.getItem(h);e.type==CKEDITOR.NODE_ELEMENT?e.forEach(a,c):(!c||e.type==c)&&a(e)}}});var c={width:["border-left-width","border-right-width","padding-left","padding-right"],height:["border-top-width","border-bottom-width","padding-top","padding-bottom"]};
CKEDITOR.dom.element.prototype.setSize=function(a,c,f){if(typeof c=="number"){if(f&&(!CKEDITOR.env.ie||!CKEDITOR.env.quirks))c=c-d.call(this,a);this.setStyle(a,c+"px")}};CKEDITOR.dom.element.prototype.getSize=function(a,c){var f=Math.max(this.$["offset"+CKEDITOR.tools.capitalize(a)],this.$["client"+CKEDITOR.tools.capitalize(a)])||0;c&&(f=f-d.call(this,a));return f}})();CKEDITOR.dom.documentFragment=function(a){a=a||CKEDITOR.document;this.$=a.type==CKEDITOR.NODE_DOCUMENT?a.$.createDocumentFragment():
a};CKEDITOR.tools.extend(CKEDITOR.dom.documentFragment.prototype,CKEDITOR.dom.element.prototype,{type:CKEDITOR.NODE_DOCUMENT_FRAGMENT,insertAfterNode:function(a){a=a.$;a.parentNode.insertBefore(this.$,a.nextSibling)}},!0,{append:1,appendBogus:1,getFirst:1,getLast:1,getParent:1,getNext:1,getPrevious:1,appendTo:1,moveChildren:1,insertBefore:1,insertAfterNode:1,replace:1,trim:1,type:1,ltrim:1,rtrim:1,getDocument:1,getChildCount:1,getChild:1,getChildren:1});(function(){function a(a,b){var c=this.range;
if(this._.end)return null;if(!this._.start){this._.start=1;if(c.collapsed){this.end();return null}c.optimize()}var e,j=c.startContainer;e=c.endContainer;var d=c.startOffset,g=c.endOffset,h,k=this.guard,f=this.type,i=a?"getPreviousSourceNode":"getNextSourceNode";if(!a&&!this._.guardLTR){var y=e.type==CKEDITOR.NODE_ELEMENT?e:e.getParent(),n=e.type==CKEDITOR.NODE_ELEMENT?e.getChild(g):e.getNext();this._.guardLTR=function(a,b){return(!b||!y.equals(a))&&(!n||!a.equals(n))&&(a.type!=CKEDITOR.NODE_ELEMENT||
!b||!a.equals(c.root))}}if(a&&!this._.guardRTL){var x=j.type==CKEDITOR.NODE_ELEMENT?j:j.getParent(),z=j.type==CKEDITOR.NODE_ELEMENT?d?j.getChild(d-1):null:j.getPrevious();this._.guardRTL=function(a,b){return(!b||!x.equals(a))&&(!z||!a.equals(z))&&(a.type!=CKEDITOR.NODE_ELEMENT||!b||!a.equals(c.root))}}var B=a?this._.guardRTL:this._.guardLTR;h=k?function(a,b){return B(a,b)===false?false:k(a,b)}:B;if(this.current)e=this.current[i](false,f,h);else{if(a)e.type==CKEDITOR.NODE_ELEMENT&&(e=g>0?e.getChild(g-
1):h(e,true)===false?null:e.getPreviousSourceNode(true,f,h));else{e=j;if(e.type==CKEDITOR.NODE_ELEMENT&&!(e=e.getChild(d)))e=h(j,true)===false?null:j.getNextSourceNode(true,f,h)}e&&h(e)===false&&(e=null)}for(;e&&!this._.end;){this.current=e;if(!this.evaluator||this.evaluator(e)!==false){if(!b)return e}else if(b&&this.evaluator)return false;e=e[i](false,f,h)}this.end();return this.current=null}function f(b){for(var c,e=null;c=a.call(this,b);)e=c;return e}function d(a){if(k(a))return false;if(a.type==
CKEDITOR.NODE_TEXT)return true;if(a.type==CKEDITOR.NODE_ELEMENT){if(a.is(CKEDITOR.dtd.$inline)||a.is("hr")||a.getAttribute("contenteditable")=="false")return true;var b;if(b=!CKEDITOR.env.needsBrFiller)if(b=a.is(j))a:{b=0;for(var c=a.getChildCount();b<c;++b)if(!k(a.getChild(b))){b=false;break a}b=true}if(b)return true}return false}CKEDITOR.dom.walker=CKEDITOR.tools.createClass({$:function(a){this.range=a;this._={}},proto:{end:function(){this._.end=1},next:function(){return a.call(this)},previous:function(){return a.call(this,
1)},checkForward:function(){return a.call(this,0,1)!==false},checkBackward:function(){return a.call(this,1,1)!==false},lastForward:function(){return f.call(this)},lastBackward:function(){return f.call(this,1)},reset:function(){delete this.current;this._={}}}});var c={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},b={absolute:1,fixed:1};CKEDITOR.dom.element.prototype.isBlockBoundary=
function(a){return this.getComputedStyle("float")=="none"&&!(this.getComputedStyle("position")in b)&&c[this.getComputedStyle("display")]?true:!!(this.is(CKEDITOR.dtd.$block)||a&&this.is(a))};CKEDITOR.dom.walker.blockBoundary=function(a){return function(b){return!(b.type==CKEDITOR.NODE_ELEMENT&&b.isBlockBoundary(a))}};CKEDITOR.dom.walker.listItemBoundary=function(){return this.blockBoundary({br:1})};CKEDITOR.dom.walker.bookmark=function(a,b){function c(a){return a&&a.getName&&a.getName()=="span"&&
a.data("cke-bookmark")}return function(e){var j,d;j=e&&e.type!=CKEDITOR.NODE_ELEMENT&&(d=e.getParent())&&c(d);j=a?j:j||c(e);return!!(b^j)}};CKEDITOR.dom.walker.whitespaces=function(a){return function(b){var c;b&&b.type==CKEDITOR.NODE_TEXT&&(c=!CKEDITOR.tools.trim(b.getText())||CKEDITOR.env.webkit&&b.getText()=="​");return!!(a^c)}};CKEDITOR.dom.walker.invisible=function(a){var b=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.env.webkit?1:0;return function(e){if(b(e))e=1;else{e.type==CKEDITOR.NODE_TEXT&&
(e=e.getParent());e=e.$.offsetWidth<=c}return!!(a^e)}};CKEDITOR.dom.walker.nodeType=function(a,b){return function(c){return!!(b^c.type==a)}};CKEDITOR.dom.walker.bogus=function(a){function b(a){return!i(a)&&!e(a)}return function(c){var e=CKEDITOR.env.needsBrFiller?c.is&&c.is("br"):c.getText&&g.test(c.getText());if(e){e=c.getParent();c=c.getNext(b);e=e.isBlockBoundary()&&(!c||c.type==CKEDITOR.NODE_ELEMENT&&c.isBlockBoundary())}return!!(a^e)}};CKEDITOR.dom.walker.temp=function(a){return function(b){b.type!=
CKEDITOR.NODE_ELEMENT&&(b=b.getParent());b=b&&b.hasAttribute("data-cke-temp");return!!(a^b)}};var g=/^[\t\r\n ]*(?:&nbsp;|\xa0)$/,i=CKEDITOR.dom.walker.whitespaces(),e=CKEDITOR.dom.walker.bookmark(),h=CKEDITOR.dom.walker.temp();CKEDITOR.dom.walker.ignored=function(a){return function(b){b=i(b)||e(b)||h(b);return!!(a^b)}};var k=CKEDITOR.dom.walker.ignored(),j=function(a){var b={},c;for(c in a)CKEDITOR.dtd[c]["#"]&&(b[c]=1);return b}(CKEDITOR.dtd.$block);CKEDITOR.dom.walker.editable=function(a){return function(b){return!!(a^
d(b))}};CKEDITOR.dom.element.prototype.getBogus=function(){var a=this;do a=a.getPreviousSourceNode();while(e(a)||i(a)||a.type==CKEDITOR.NODE_ELEMENT&&a.is(CKEDITOR.dtd.$inline)&&!a.is(CKEDITOR.dtd.$empty));return a&&(CKEDITOR.env.needsBrFiller?a.is&&a.is("br"):a.getText&&g.test(a.getText()))?a:false}})();CKEDITOR.dom.range=function(a){this.endOffset=this.endContainer=this.startOffset=this.startContainer=null;this.collapsed=true;var f=a instanceof CKEDITOR.dom.document;this.document=f?a:a.getDocument();
this.root=f?a.getBody():a};(function(){function a(){var a=false,b=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.dom.walker.bookmark(true),e=CKEDITOR.dom.walker.bogus();return function(d){if(c(d)||b(d))return true;if(e(d)&&!a)return a=true;return d.type==CKEDITOR.NODE_TEXT&&(d.hasAscendant("pre")||CKEDITOR.tools.trim(d.getText()).length)||d.type==CKEDITOR.NODE_ELEMENT&&!d.is(g)?false:true}}function f(a){var b=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.dom.walker.bookmark(1);return function(e){return c(e)||
b(e)?true:!a&&i(e)||e.type==CKEDITOR.NODE_ELEMENT&&e.is(CKEDITOR.dtd.$removeEmpty)}}function d(a){return function(){var b;return this[a?"getPreviousNode":"getNextNode"](function(a){!b&&k(a)&&(b=a);return h(a)&&!(i(a)&&a.equals(b))})}}var c=function(a){a.collapsed=a.startContainer&&a.endContainer&&a.startContainer.equals(a.endContainer)&&a.startOffset==a.endOffset},b=function(a,b,c,e){a.optimizeBookmark();var d=a.startContainer,g=a.endContainer,h=a.startOffset,k=a.endOffset,f,i;if(g.type==CKEDITOR.NODE_TEXT)g=
g.split(k);else if(g.getChildCount()>0)if(k>=g.getChildCount()){g=g.append(a.document.createText(""));i=true}else g=g.getChild(k);if(d.type==CKEDITOR.NODE_TEXT){d.split(h);d.equals(g)&&(g=d.getNext())}else if(h)if(h>=d.getChildCount()){d=d.append(a.document.createText(""));f=true}else d=d.getChild(h).getPrevious();else{d=d.append(a.document.createText(""),1);f=true}var h=d.getParents(),k=g.getParents(),v,t,y;for(v=0;v<h.length;v++){t=h[v];y=k[v];if(!t.equals(y))break}for(var n=c,x,z,B,C=v;C<h.length;C++){x=
h[C];n&&!x.equals(d)&&(z=n.append(x.clone()));for(x=x.getNext();x;){if(x.equals(k[C])||x.equals(g))break;B=x.getNext();if(b==2)n.append(x.clone(true));else{x.remove();b==1&&n.append(x)}x=B}n&&(n=z)}n=c;for(c=v;c<k.length;c++){x=k[c];b>0&&!x.equals(g)&&(z=n.append(x.clone()));if(!h[c]||x.$.parentNode!=h[c].$.parentNode)for(x=x.getPrevious();x;){if(x.equals(h[c])||x.equals(d))break;B=x.getPrevious();if(b==2)n.$.insertBefore(x.$.cloneNode(true),n.$.firstChild);else{x.remove();b==1&&n.$.insertBefore(x.$,
n.$.firstChild)}x=B}n&&(n=z)}if(b==2){t=a.startContainer;if(t.type==CKEDITOR.NODE_TEXT){t.$.data=t.$.data+t.$.nextSibling.data;t.$.parentNode.removeChild(t.$.nextSibling)}a=a.endContainer;if(a.type==CKEDITOR.NODE_TEXT&&a.$.nextSibling){a.$.data=a.$.data+a.$.nextSibling.data;a.$.parentNode.removeChild(a.$.nextSibling)}}else{if(t&&y&&(d.$.parentNode!=t.$.parentNode||g.$.parentNode!=y.$.parentNode)){b=y.getIndex();f&&y.$.parentNode==d.$.parentNode&&b--;if(e&&t.type==CKEDITOR.NODE_ELEMENT){e=CKEDITOR.dom.element.createFromHtml('<span data-cke-bookmark="1" style="display:none">&nbsp;</span>',
a.document);e.insertAfter(t);t.mergeSiblings(false);a.moveToBookmark({startNode:e})}else a.setStart(y.getParent(),b)}a.collapse(true)}f&&d.remove();i&&g.$.parentNode&&g.remove()},g={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},i=CKEDITOR.dom.walker.bogus(),e=/^[\t\r\n ]*(?:&nbsp;|\xa0)$/,h=CKEDITOR.dom.walker.editable(),k=CKEDITOR.dom.walker.ignored(true);CKEDITOR.dom.range.prototype=
{clone:function(){var a=new CKEDITOR.dom.range(this.root);a._setStartContainer(this.startContainer);a.startOffset=this.startOffset;a._setEndContainer(this.endContainer);a.endOffset=this.endOffset;a.collapsed=this.collapsed;return a},collapse:function(a){if(a){this._setEndContainer(this.startContainer);this.endOffset=this.startOffset}else{this._setStartContainer(this.endContainer);this.startOffset=this.endOffset}this.collapsed=true},cloneContents:function(){var a=new CKEDITOR.dom.documentFragment(this.document);
this.collapsed||b(this,2,a);return a},deleteContents:function(a){this.collapsed||b(this,0,null,a)},extractContents:function(a){var c=new CKEDITOR.dom.documentFragment(this.document);this.collapsed||b(this,1,c,a);return c},createBookmark:function(a){var b,c,e,d,g=this.collapsed;b=this.document.createElement("span");b.data("cke-bookmark",1);b.setStyle("display","none");b.setHtml("&nbsp;");if(a){e="cke_bm_"+CKEDITOR.tools.getNextNumber();b.setAttribute("id",e+(g?"C":"S"))}if(!g){c=b.clone();c.setHtml("&nbsp;");
a&&c.setAttribute("id",e+"E");d=this.clone();d.collapse();d.insertNode(c)}d=this.clone();d.collapse(true);d.insertNode(b);if(c){this.setStartAfter(b);this.setEndBefore(c)}else this.moveToPosition(b,CKEDITOR.POSITION_AFTER_END);return{startNode:a?e+(g?"C":"S"):b,endNode:a?e+"E":c,serializable:a,collapsed:g}},createBookmark2:function(){function a(c){var e=c.container,d=c.offset,j;j=e;var g=d;j=j.type!=CKEDITOR.NODE_ELEMENT||g===0||g==j.getChildCount()?0:j.getChild(g-1).type==CKEDITOR.NODE_TEXT&&j.getChild(g).type==
CKEDITOR.NODE_TEXT;if(j){e=e.getChild(d-1);d=e.getLength()}e.type==CKEDITOR.NODE_ELEMENT&&d>1&&(d=e.getChild(d-1).getIndex(true)+1);if(e.type==CKEDITOR.NODE_TEXT){j=e;for(g=0;(j=j.getPrevious())&&j.type==CKEDITOR.NODE_TEXT;)g=g+j.getLength();j=g;if(e.getText())d=d+j;else{g=e.getPrevious(b);if(j){d=j;e=g?g.getNext():e.getParent().getFirst()}else{e=e.getParent();d=g?g.getIndex(true)+1:0}}}c.container=e;c.offset=d}var b=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_TEXT,true);return function(b){var c=this.collapsed,
e={container:this.startContainer,offset:this.startOffset},d={container:this.endContainer,offset:this.endOffset};if(b){a(e);c||a(d)}return{start:e.container.getAddress(b),end:c?null:d.container.getAddress(b),startOffset:e.offset,endOffset:d.offset,normalized:b,collapsed:c,is2:true}}}(),moveToBookmark:function(a){if(a.is2){var b=this.document.getByAddress(a.start,a.normalized),c=a.startOffset,e=a.end&&this.document.getByAddress(a.end,a.normalized),a=a.endOffset;this.setStart(b,c);e?this.setEnd(e,a):
this.collapse(true)}else{b=(c=a.serializable)?this.document.getById(a.startNode):a.startNode;a=c?this.document.getById(a.endNode):a.endNode;this.setStartBefore(b);b.remove();if(a){this.setEndBefore(a);a.remove()}else this.collapse(true)}},getBoundaryNodes:function(){var a=this.startContainer,b=this.endContainer,c=this.startOffset,e=this.endOffset,d;if(a.type==CKEDITOR.NODE_ELEMENT){d=a.getChildCount();if(d>c)a=a.getChild(c);else if(d<1)a=a.getPreviousSourceNode();else{for(a=a.$;a.lastChild;)a=a.lastChild;
a=new CKEDITOR.dom.node(a);a=a.getNextSourceNode()||a}}if(b.type==CKEDITOR.NODE_ELEMENT){d=b.getChildCount();if(d>e)b=b.getChild(e).getPreviousSourceNode(true);else if(d<1)b=b.getPreviousSourceNode();else{for(b=b.$;b.lastChild;)b=b.lastChild;b=new CKEDITOR.dom.node(b)}}a.getPosition(b)&CKEDITOR.POSITION_FOLLOWING&&(a=b);return{startNode:a,endNode:b}},getCommonAncestor:function(a,b){var c=this.startContainer,e=this.endContainer,c=c.equals(e)?a&&c.type==CKEDITOR.NODE_ELEMENT&&this.startOffset==this.endOffset-
1?c.getChild(this.startOffset):c:c.getCommonAncestor(e);return b&&!c.is?c.getParent():c},optimize:function(){var a=this.startContainer,b=this.startOffset;a.type!=CKEDITOR.NODE_ELEMENT&&(b?b>=a.getLength()&&this.setStartAfter(a):this.setStartBefore(a));a=this.endContainer;b=this.endOffset;a.type!=CKEDITOR.NODE_ELEMENT&&(b?b>=a.getLength()&&this.setEndAfter(a):this.setEndBefore(a))},optimizeBookmark:function(){var a=this.startContainer,b=this.endContainer;a.is&&(a.is("span")&&a.data("cke-bookmark"))&&
this.setStartAt(a,CKEDITOR.POSITION_BEFORE_START);b&&(b.is&&b.is("span")&&b.data("cke-bookmark"))&&this.setEndAt(b,CKEDITOR.POSITION_AFTER_END)},trim:function(a,b){var c=this.startContainer,e=this.startOffset,d=this.collapsed;if((!a||d)&&c&&c.type==CKEDITOR.NODE_TEXT){if(e)if(e>=c.getLength()){e=c.getIndex()+1;c=c.getParent()}else{var g=c.split(e),e=c.getIndex()+1,c=c.getParent();if(this.startContainer.equals(this.endContainer))this.setEnd(g,this.endOffset-this.startOffset);else if(c.equals(this.endContainer))this.endOffset=
this.endOffset+1}else{e=c.getIndex();c=c.getParent()}this.setStart(c,e);if(d){this.collapse(true);return}}c=this.endContainer;e=this.endOffset;if(!b&&!d&&c&&c.type==CKEDITOR.NODE_TEXT){if(e){e>=c.getLength()||c.split(e);e=c.getIndex()+1}else e=c.getIndex();c=c.getParent();this.setEnd(c,e)}},enlarge:function(a,b){function c(a){return a&&a.type==CKEDITOR.NODE_ELEMENT&&a.hasAttribute("contenteditable")?null:a}var e=RegExp(/[^\s\ufeff]/);switch(a){case CKEDITOR.ENLARGE_INLINE:var d=1;case CKEDITOR.ENLARGE_ELEMENT:if(this.collapsed)break;
var g=this.getCommonAncestor(),h=this.root,k,f,i,v,t,y=false,n,x;n=this.startContainer;var z=this.startOffset;if(n.type==CKEDITOR.NODE_TEXT){if(z){n=!CKEDITOR.tools.trim(n.substring(0,z)).length&&n;y=!!n}if(n&&!(v=n.getPrevious()))i=n.getParent()}else{z&&(v=n.getChild(z-1)||n.getLast());v||(i=n)}for(i=c(i);i||v;){if(i&&!v){!t&&i.equals(g)&&(t=true);if(d?i.isBlockBoundary():!h.contains(i))break;if(!y||i.getComputedStyle("display")!="inline"){y=false;t?k=i:this.setStartBefore(i)}v=i.getPrevious()}for(;v;){n=
false;if(v.type==CKEDITOR.NODE_COMMENT)v=v.getPrevious();else{if(v.type==CKEDITOR.NODE_TEXT){x=v.getText();e.test(x)&&(v=null);n=/[\s\ufeff]$/.test(x)}else if((v.$.offsetWidth>(CKEDITOR.env.webkit?1:0)||b&&v.is("br"))&&!v.data("cke-bookmark"))if(y&&CKEDITOR.dtd.$removeEmpty[v.getName()]){x=v.getText();if(e.test(x))v=null;else for(var z=v.$.getElementsByTagName("*"),B=0,C;C=z[B++];)if(!CKEDITOR.dtd.$removeEmpty[C.nodeName.toLowerCase()]){v=null;break}v&&(n=!!x.length)}else v=null;n&&(y?t?k=i:i&&this.setStartBefore(i):
y=true);if(v){n=v.getPrevious();if(!i&&!n){i=v;v=null;break}v=n}else i=null}}i&&(i=c(i.getParent()))}n=this.endContainer;z=this.endOffset;i=v=null;t=y=false;var H=function(a,b){var c=new CKEDITOR.dom.range(h);c.setStart(a,b);c.setEndAt(h,CKEDITOR.POSITION_BEFORE_END);var c=new CKEDITOR.dom.walker(c),d;for(c.guard=function(a){return!(a.type==CKEDITOR.NODE_ELEMENT&&a.isBlockBoundary())};d=c.next();){if(d.type!=CKEDITOR.NODE_TEXT)return false;x=d!=a?d.getText():d.substring(b);if(e.test(x))return false}return true};
if(n.type==CKEDITOR.NODE_TEXT)if(CKEDITOR.tools.trim(n.substring(z)).length)y=true;else{y=!n.getLength();if(z==n.getLength()){if(!(v=n.getNext()))i=n.getParent()}else H(n,z)&&(i=n.getParent())}else(v=n.getChild(z))||(i=n);for(;i||v;){if(i&&!v){!t&&i.equals(g)&&(t=true);if(d?i.isBlockBoundary():!h.contains(i))break;if(!y||i.getComputedStyle("display")!="inline"){y=false;t?f=i:i&&this.setEndAfter(i)}v=i.getNext()}for(;v;){n=false;if(v.type==CKEDITOR.NODE_TEXT){x=v.getText();H(v,0)||(v=null);n=/^[\s\ufeff]/.test(x)}else if(v.type==
CKEDITOR.NODE_ELEMENT){if((v.$.offsetWidth>0||b&&v.is("br"))&&!v.data("cke-bookmark"))if(y&&CKEDITOR.dtd.$removeEmpty[v.getName()]){x=v.getText();if(e.test(x))v=null;else{z=v.$.getElementsByTagName("*");for(B=0;C=z[B++];)if(!CKEDITOR.dtd.$removeEmpty[C.nodeName.toLowerCase()]){v=null;break}}v&&(n=!!x.length)}else v=null}else n=1;n&&y&&(t?f=i:this.setEndAfter(i));if(v){n=v.getNext();if(!i&&!n){i=v;v=null;break}v=n}else i=null}i&&(i=c(i.getParent()))}if(k&&f){g=k.contains(f)?f:k;this.setStartBefore(g);
this.setEndAfter(g)}break;case CKEDITOR.ENLARGE_BLOCK_CONTENTS:case CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS:i=new CKEDITOR.dom.range(this.root);h=this.root;i.setStartAt(h,CKEDITOR.POSITION_AFTER_START);i.setEnd(this.startContainer,this.startOffset);i=new CKEDITOR.dom.walker(i);var F,I,A=CKEDITOR.dom.walker.blockBoundary(a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS?{br:1}:null),D=null,E=function(a){if(a.type==CKEDITOR.NODE_ELEMENT&&a.getAttribute("contenteditable")=="false")if(D){if(D.equals(a)){D=null;return}}else D=
a;else if(D)return;var b=A(a);b||(F=a);return b},d=function(a){var b=E(a);!b&&(a.is&&a.is("br"))&&(I=a);return b};i.guard=E;i=i.lastBackward();F=F||h;this.setStartAt(F,!F.is("br")&&(!i&&this.checkStartOfBlock()||i&&F.contains(i))?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_AFTER_END);if(a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS){i=this.clone();i=new CKEDITOR.dom.walker(i);var G=CKEDITOR.dom.walker.whitespaces(),K=CKEDITOR.dom.walker.bookmark();i.evaluator=function(a){return!G(a)&&!K(a)};if((i=i.previous())&&
i.type==CKEDITOR.NODE_ELEMENT&&i.is("br"))break}i=this.clone();i.collapse();i.setEndAt(h,CKEDITOR.POSITION_BEFORE_END);i=new CKEDITOR.dom.walker(i);i.guard=a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS?d:E;F=D=I=null;i=i.lastForward();F=F||h;this.setEndAt(F,!i&&this.checkEndOfBlock()||i&&F.contains(i)?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_BEFORE_START);I&&this.setEndAfter(I)}},shrink:function(a,b,c){if(!this.collapsed){var a=a||CKEDITOR.SHRINK_TEXT,e=this.clone(),d=this.startContainer,g=this.endContainer,
h=this.startOffset,i=this.endOffset,k=1,f=1;if(d&&d.type==CKEDITOR.NODE_TEXT)if(h)if(h>=d.getLength())e.setStartAfter(d);else{e.setStartBefore(d);k=0}else e.setStartBefore(d);if(g&&g.type==CKEDITOR.NODE_TEXT)if(i)if(i>=g.getLength())e.setEndAfter(g);else{e.setEndAfter(g);f=0}else e.setEndBefore(g);var e=new CKEDITOR.dom.walker(e),v=CKEDITOR.dom.walker.bookmark();e.evaluator=function(b){return b.type==(a==CKEDITOR.SHRINK_ELEMENT?CKEDITOR.NODE_ELEMENT:CKEDITOR.NODE_TEXT)};var t;e.guard=function(b,e){if(v(b))return true;
if(a==CKEDITOR.SHRINK_ELEMENT&&b.type==CKEDITOR.NODE_TEXT||e&&b.equals(t)||c===false&&b.type==CKEDITOR.NODE_ELEMENT&&b.isBlockBoundary()||b.type==CKEDITOR.NODE_ELEMENT&&b.hasAttribute("contenteditable"))return false;!e&&b.type==CKEDITOR.NODE_ELEMENT&&(t=b);return true};if(k)(d=e[a==CKEDITOR.SHRINK_ELEMENT?"lastForward":"next"]())&&this.setStartAt(d,b?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_START);if(f){e.reset();(e=e[a==CKEDITOR.SHRINK_ELEMENT?"lastBackward":"previous"]())&&this.setEndAt(e,
b?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_AFTER_END)}return!(!k&&!f)}},insertNode:function(a){this.optimizeBookmark();this.trim(false,true);var b=this.startContainer,c=b.getChild(this.startOffset);c?a.insertBefore(c):b.append(a);a.getParent()&&a.getParent().equals(this.endContainer)&&this.endOffset++;this.setStartBefore(a)},moveToPosition:function(a,b){this.setStartAt(a,b);this.collapse(true)},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,b){if(a.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$empty[a.getName()]){b=a.getIndex();a=a.getParent()}this._setStartContainer(a);this.startOffset=b;if(!this.endContainer){this._setEndContainer(a);this.endOffset=b}c(this)},setEnd:function(a,b){if(a.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$empty[a.getName()]){b=a.getIndex()+1;a=a.getParent()}this._setEndContainer(a);
this.endOffset=b;if(!this.startContainer){this._setStartContainer(a);this.startOffset=b}c(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,b){switch(b){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)}c(this)},setEndAt:function(a,b){switch(b){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)}c(this)},fixBlock:function(a,b){var c=this.createBookmark(),e=this.document.createElement(b);this.collapse(a);this.enlarge(CKEDITOR.ENLARGE_BLOCK_CONTENTS);this.extractContents().appendTo(e);e.trim();e.appendBogus();this.insertNode(e);this.moveToBookmark(c);return e},splitBlock:function(a){var b=new CKEDITOR.dom.elementPath(this.startContainer,this.root),c=new CKEDITOR.dom.elementPath(this.endContainer,this.root),e=b.block,d=c.block,g=null;if(!b.blockLimit.equals(c.blockLimit))return null;
if(a!="br"){if(!e){e=this.fixBlock(true,a);d=(new CKEDITOR.dom.elementPath(this.endContainer,this.root)).block}d||(d=this.fixBlock(false,a))}a=e&&this.checkStartOfBlock();b=d&&this.checkEndOfBlock();this.deleteContents();if(e&&e.equals(d))if(b){g=new CKEDITOR.dom.elementPath(this.startContainer,this.root);this.moveToPosition(d,CKEDITOR.POSITION_AFTER_END);d=null}else if(a){g=new CKEDITOR.dom.elementPath(this.startContainer,this.root);this.moveToPosition(e,CKEDITOR.POSITION_BEFORE_START);e=null}else{d=
this.splitElement(e);e.is("ul","ol")||e.appendBogus()}return{previousBlock:e,nextBlock:d,wasStartOfBlock:a,wasEndOfBlock:b,elementPath:g}},splitElement:function(a){if(!this.collapsed)return null;this.setEndAt(a,CKEDITOR.POSITION_BEFORE_END);var b=this.extractContents(),c=a.clone(false);b.appendTo(c);c.insertAfter(a);this.moveToPosition(a,CKEDITOR.POSITION_AFTER_END);return c},removeEmptyBlocksAtEnd:function(){function a(e){return function(a){return b(a)||(c(a)||a.type==CKEDITOR.NODE_ELEMENT&&a.isEmptyInlineRemoveable())||
e.is("table")&&a.is("caption")?false:true}}var b=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.dom.walker.bookmark(false);return function(b){for(var c=this.createBookmark(),e=this[b?"endPath":"startPath"](),d=e.block||e.blockLimit,g;d&&!d.equals(e.root)&&!d.getFirst(a(d));){g=d.getParent();this[b?"setEndAt":"setStartAt"](d,CKEDITOR.POSITION_AFTER_END);d.remove(1);d=g}this.moveToBookmark(c)}}(),startPath:function(){return new CKEDITOR.dom.elementPath(this.startContainer,this.root)},endPath:function(){return new CKEDITOR.dom.elementPath(this.endContainer,
this.root)},checkBoundaryOfElement:function(a,b){var c=b==CKEDITOR.START,e=this.clone();e.collapse(c);e[c?"setStartAt":"setEndAt"](a,c?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_END);e=new CKEDITOR.dom.walker(e);e.evaluator=f(c);return e[c?"checkBackward":"checkForward"]()},checkStartOfBlock:function(){var b=this.startContainer,c=this.startOffset;if(CKEDITOR.env.ie&&c&&b.type==CKEDITOR.NODE_TEXT){b=CKEDITOR.tools.ltrim(b.substring(0,c));e.test(b)&&this.trim(0,1)}this.trim();b=new CKEDITOR.dom.elementPath(this.startContainer,
this.root);c=this.clone();c.collapse(true);c.setStartAt(b.block||b.blockLimit,CKEDITOR.POSITION_AFTER_START);b=new CKEDITOR.dom.walker(c);b.evaluator=a();return b.checkBackward()},checkEndOfBlock:function(){var b=this.endContainer,c=this.endOffset;if(CKEDITOR.env.ie&&b.type==CKEDITOR.NODE_TEXT){b=CKEDITOR.tools.rtrim(b.substring(c));e.test(b)&&this.trim(1,0)}this.trim();b=new CKEDITOR.dom.elementPath(this.endContainer,this.root);c=this.clone();c.collapse(false);c.setEndAt(b.block||b.blockLimit,CKEDITOR.POSITION_BEFORE_END);
b=new CKEDITOR.dom.walker(c);b.evaluator=a();return b.checkForward()},getPreviousNode:function(a,b,c){var e=this.clone();e.collapse(1);e.setStartAt(c||this.root,CKEDITOR.POSITION_AFTER_START);c=new CKEDITOR.dom.walker(e);c.evaluator=a;c.guard=b;return c.previous()},getNextNode:function(a,b,c){var e=this.clone();e.collapse();e.setEndAt(c||this.root,CKEDITOR.POSITION_BEFORE_END);c=new CKEDITOR.dom.walker(e);c.evaluator=a;c.guard=b;return c.next()},checkReadOnly:function(){function a(b,c){for(;b;){if(b.type==
CKEDITOR.NODE_ELEMENT){if(b.getAttribute("contentEditable")=="false"&&!b.data("cke-editable"))return 0;if(b.is("html")||b.getAttribute("contentEditable")=="true"&&(b.contains(c)||b.equals(c)))break}b=b.getParent()}return 1}return function(){var b=this.startContainer,c=this.endContainer;return!(a(b,c)&&a(c,b))}}(),moveToElementEditablePosition:function(a,b){if(a.type==CKEDITOR.NODE_ELEMENT&&!a.isEditable(false)){this.moveToPosition(a,b?CKEDITOR.POSITION_AFTER_END:CKEDITOR.POSITION_BEFORE_START);return true}for(var c=
0;a;){if(a.type==CKEDITOR.NODE_TEXT){b&&this.endContainer&&this.checkEndOfBlock()&&e.test(a.getText())?this.moveToPosition(a,CKEDITOR.POSITION_BEFORE_START):this.moveToPosition(a,b?CKEDITOR.POSITION_AFTER_END:CKEDITOR.POSITION_BEFORE_START);c=1;break}if(a.type==CKEDITOR.NODE_ELEMENT)if(a.isEditable()){this.moveToPosition(a,b?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_AFTER_START);c=1}else if(b&&a.is("br")&&this.endContainer&&this.checkEndOfBlock())this.moveToPosition(a,CKEDITOR.POSITION_BEFORE_START);
else if(a.getAttribute("contenteditable")=="false"&&a.is(CKEDITOR.dtd.$block)){this.setStartBefore(a);this.setEndAfter(a);return true}var d=a,g=c,h=void 0;d.type==CKEDITOR.NODE_ELEMENT&&d.isEditable(false)&&(h=d[b?"getLast":"getFirst"](k));!g&&!h&&(h=d[b?"getPrevious":"getNext"](k));a=h}return!!c},moveToClosestEditablePosition:function(a,b){var c=new CKEDITOR.dom.range(this.root),e=0,d,g=[CKEDITOR.POSITION_AFTER_END,CKEDITOR.POSITION_BEFORE_START];c.moveToPosition(a,g[b?0:1]);if(a.is(CKEDITOR.dtd.$block)){if(d=
c[b?"getNextEditableNode":"getPreviousEditableNode"]()){e=1;if(d.type==CKEDITOR.NODE_ELEMENT&&d.is(CKEDITOR.dtd.$block)&&d.getAttribute("contenteditable")=="false"){c.setStartAt(d,CKEDITOR.POSITION_BEFORE_START);c.setEndAt(d,CKEDITOR.POSITION_AFTER_END)}else c.moveToPosition(d,g[b?1:0])}}else e=1;e&&this.moveToRange(c);return!!e},moveToElementEditStart:function(a){return this.moveToElementEditablePosition(a)},moveToElementEditEnd:function(a){return this.moveToElementEditablePosition(a,true)},getEnclosedNode:function(){var a=
this.clone();a.optimize();if(a.startContainer.type!=CKEDITOR.NODE_ELEMENT||a.endContainer.type!=CKEDITOR.NODE_ELEMENT)return null;var a=new CKEDITOR.dom.walker(a),b=CKEDITOR.dom.walker.bookmark(false,true),c=CKEDITOR.dom.walker.whitespaces(true);a.evaluator=function(a){return c(a)&&b(a)};var e=a.next();a.reset();return e&&e.equals(a.previous())?e: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:d(),getPreviousEditableNode:d(1),scrollIntoView:function(){var a=new CKEDITOR.dom.element.createFromHtml("<span>&nbsp;</span>",this.document),b,c,e,d=this.clone();d.optimize();if(e=d.startContainer.type==CKEDITOR.NODE_TEXT){c=d.startContainer.getText();b=d.startContainer.split(d.startOffset);a.insertAfter(d.startContainer)}else d.insertNode(a);a.scrollIntoView();if(e){d.startContainer.setText(c);
b.remove()}a.remove()},_setStartContainer:function(a){this.startContainer=a},_setEndContainer:function(a){this.endContainer=a}}})();CKEDITOR.POSITION_AFTER_START=1;CKEDITOR.POSITION_BEFORE_END=2;CKEDITOR.POSITION_BEFORE_START=3;CKEDITOR.POSITION_AFTER_END=4;CKEDITOR.ENLARGE_ELEMENT=1;CKEDITOR.ENLARGE_BLOCK_CONTENTS=2;CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS=3;CKEDITOR.ENLARGE_INLINE=4;CKEDITOR.START=1;CKEDITOR.END=2;CKEDITOR.SHRINK_ELEMENT=1;CKEDITOR.SHRINK_TEXT=2;"use strict";(function(){function a(a){if(!(arguments.length<
1)){this.range=a;this.forceBrBreak=0;this.enlargeBr=1;this.enforceRealBlocks=0;this._||(this._={})}}function f(a){var b=[];a.forEach(function(a){if(a.getAttribute("contenteditable")=="true"){b.push(a);return false}},CKEDITOR.NODE_ELEMENT,true);return b}function d(a,b,c,e){a:{e==null&&(e=f(c));for(var g;g=e.shift();)if(g.getDtd().p){e={element:g,remaining:e};break a}e=null}if(!e)return 0;if((g=CKEDITOR.filter.instances[e.element.data("cke-filter")])&&!g.check(b))return d(a,b,c,e.remaining);b=new CKEDITOR.dom.range(e.element);
b.selectNodeContents(e.element);b=b.createIterator();b.enlargeBr=a.enlargeBr;b.enforceRealBlocks=a.enforceRealBlocks;b.activeFilter=b.filter=g;a._.nestedEditable={element:e.element,container:c,remaining:e.remaining,iterator:b};return 1}function c(a,b,c){if(!b)return false;a=a.clone();a.collapse(!c);return a.checkBoundaryOfElement(b,c?CKEDITOR.START:CKEDITOR.END)}var b=/^[\r\n\t ]+$/,g=CKEDITOR.dom.walker.bookmark(false,true),i=CKEDITOR.dom.walker.whitespaces(true),e=function(a){return g(a)&&i(a)},
h={dd:1,dt:1,li:1};a.prototype={getNextParagraph:function(a){var i,f,q,l,o,a=a||"p";if(this._.nestedEditable){if(i=this._.nestedEditable.iterator.getNextParagraph(a)){this.activeFilter=this._.nestedEditable.iterator.activeFilter;return i}this.activeFilter=this.filter;if(d(this,a,this._.nestedEditable.container,this._.nestedEditable.remaining)){this.activeFilter=this._.nestedEditable.iterator.activeFilter;return this._.nestedEditable.iterator.getNextParagraph(a)}this._.nestedEditable=null}if(!this.range.root.getDtd()[a])return null;
if(!this._.started){var p=this.range.clone();f=p.startPath();var r=p.endPath(),s=!p.collapsed&&c(p,f.block),u=!p.collapsed&&c(p,r.block,1);p.shrink(CKEDITOR.SHRINK_ELEMENT,true);s&&p.setStartAt(f.block,CKEDITOR.POSITION_BEFORE_END);u&&p.setEndAt(r.block,CKEDITOR.POSITION_AFTER_START);f=p.endContainer.hasAscendant("pre",true)||p.startContainer.hasAscendant("pre",true);p.enlarge(this.forceBrBreak&&!f||!this.enlargeBr?CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS:CKEDITOR.ENLARGE_BLOCK_CONTENTS);if(!p.collapsed){f=
new CKEDITOR.dom.walker(p.clone());r=CKEDITOR.dom.walker.bookmark(true,true);f.evaluator=r;this._.nextNode=f.next();f=new CKEDITOR.dom.walker(p.clone());f.evaluator=r;f=f.previous();this._.lastNode=f.getNextSourceNode(true,null,p.root);if(this._.lastNode&&this._.lastNode.type==CKEDITOR.NODE_TEXT&&!CKEDITOR.tools.trim(this._.lastNode.getText())&&this._.lastNode.getParent().isBlockBoundary()){r=this.range.clone();r.moveToPosition(this._.lastNode,CKEDITOR.POSITION_AFTER_END);if(r.checkEndOfBlock()){r=
new CKEDITOR.dom.elementPath(r.endContainer,r.root);this._.lastNode=(r.block||r.blockLimit).getNextSourceNode(true)}}if(!this._.lastNode||!p.root.contains(this._.lastNode)){this._.lastNode=this._.docEndMarker=p.document.createText("");this._.lastNode.insertAfter(f)}p=null}this._.started=1;f=p}r=this._.nextNode;p=this._.lastNode;for(this._.nextNode=null;r;){var s=0,u=r.hasAscendant("pre"),w=r.type!=CKEDITOR.NODE_ELEMENT,v=0;if(w)r.type==CKEDITOR.NODE_TEXT&&b.test(r.getText())&&(w=0);else{var t=r.getName();
if(CKEDITOR.dtd.$block[t]&&r.getAttribute("contenteditable")=="false"){i=r;d(this,a,i);break}else if(r.isBlockBoundary(this.forceBrBreak&&!u&&{br:1})){if(t=="br")w=1;else if(!f&&!r.getChildCount()&&t!="hr"){i=r;q=r.equals(p);break}if(f){f.setEndAt(r,CKEDITOR.POSITION_BEFORE_START);if(t!="br")this._.nextNode=r}s=1}else{if(r.getFirst()){if(!f){f=this.range.clone();f.setStartAt(r,CKEDITOR.POSITION_BEFORE_START)}r=r.getFirst();continue}w=1}}if(w&&!f){f=this.range.clone();f.setStartAt(r,CKEDITOR.POSITION_BEFORE_START)}q=
(!s||w)&&r.equals(p);if(f&&!s)for(;!r.getNext(e)&&!q;){t=r.getParent();if(t.isBlockBoundary(this.forceBrBreak&&!u&&{br:1})){s=1;w=0;q||t.equals(p);f.setEndAt(t,CKEDITOR.POSITION_BEFORE_END);break}r=t;w=1;q=r.equals(p);v=1}w&&f.setEndAt(r,CKEDITOR.POSITION_AFTER_END);r=this._getNextSourceNode(r,v,p);if((q=!r)||s&&f)break}if(!i){if(!f){this._.docEndMarker&&this._.docEndMarker.remove();return this._.nextNode=null}i=new CKEDITOR.dom.elementPath(f.startContainer,f.root);r=i.blockLimit;s={div:1,th:1,td:1};
i=i.block;if(!i&&r&&!this.enforceRealBlocks&&s[r.getName()]&&f.checkStartOfBlock()&&f.checkEndOfBlock()&&!r.equals(f.root))i=r;else if(!i||this.enforceRealBlocks&&i.is(h)){i=this.range.document.createElement(a);f.extractContents().appendTo(i);i.trim();f.insertNode(i);l=o=true}else if(i.getName()!="li"){if(!f.checkStartOfBlock()||!f.checkEndOfBlock()){i=i.clone(false);f.extractContents().appendTo(i);i.trim();o=f.splitBlock();l=!o.wasStartOfBlock;o=!o.wasEndOfBlock;f.insertNode(i)}}else if(!q)this._.nextNode=
i.equals(p)?null:this._getNextSourceNode(f.getBoundaryNodes().endNode,1,p)}if(l)(l=i.getPrevious())&&l.type==CKEDITOR.NODE_ELEMENT&&(l.getName()=="br"?l.remove():l.getLast()&&l.getLast().$.nodeName.toLowerCase()=="br"&&l.getLast().remove());if(o)(l=i.getLast())&&l.type==CKEDITOR.NODE_ELEMENT&&l.getName()=="br"&&(!CKEDITOR.env.needsBrFiller||l.getPrevious(g)||l.getNext(g))&&l.remove();if(!this._.nextNode)this._.nextNode=q||i.equals(p)||!p?null:this._getNextSourceNode(i,1,p);return i},_getNextSourceNode:function(a,
b,c){function e(a){return!(a.equals(c)||a.equals(d))}for(var d=this.range.root,a=a.getNextSourceNode(b,null,e);!g(a);)a=a.getNextSourceNode(b,null,e);return a}};CKEDITOR.dom.range.prototype.createIterator=function(){return new a(this)}})();CKEDITOR.command=function(a,f){this.uiItems=[];this.exec=function(c){if(this.state==CKEDITOR.TRISTATE_DISABLED||!this.checkAllowed())return false;this.editorFocus&&a.focus();return this.fire("exec")===false?true:f.exec.call(this,a,c)!==false};this.refresh=function(a,
b){if(!this.readOnly&&a.readOnly)return true;if(this.context&&!b.isContextFor(this.context)){this.disable();return true}if(!this.checkAllowed(true)){this.disable();return true}this.startDisabled||this.enable();this.modes&&!this.modes[a.mode]&&this.disable();return this.fire("refresh",{editor:a,path:b})===false?true:f.refresh&&f.refresh.apply(this,arguments)!==false};var d;this.checkAllowed=function(c){return!c&&typeof d=="boolean"?d:d=a.activeFilter.checkFeature(this)};CKEDITOR.tools.extend(this,
f,{modes:{wysiwyg:1},editorFocus:1,contextSensitive:!!f.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||typeof this.previousState=="undefined"?CKEDITOR.TRISTATE_OFF:this.previousState)},disable:function(){this.setState(CKEDITOR.TRISTATE_DISABLED)},setState:function(a){if(this.state==a||a!=CKEDITOR.TRISTATE_DISABLED&&!this.checkAllowed())return false;
this.previousState=this.state;this.state=a;this.fire("state");return true},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:"<!DOCTYPE html>",bodyId:"",bodyClass:"",fullPage:!1,height:200,extraPlugins:"",removePlugins:"",protectedSource:[],tabIndex:0,width:"",baseFloatZIndex:1E4,blockedKeystrokes:[CKEDITOR.CTRL+66,CKEDITOR.CTRL+73,CKEDITOR.CTRL+85]};(function(){function a(a,b,c,e,d){var g,h,a=[];for(g in b){h=b[g];h=typeof h=="boolean"?{}:typeof h=="function"?{match:h}:H(h);if(g.charAt(0)!="$")h.elements=g;if(c)h.featureName=c.toLowerCase();var f=h;f.elements=
i(f.elements,/\s+/)||null;f.propertiesOnly=f.propertiesOnly||f.elements===true;var k=/\s*,\s*/,j=void 0;for(j in D){f[j]=i(f[j],k)||null;var o=f,r=E[j],A=i(f[E[j]],k),t=f[j],v=[],y=true,G=void 0;A?y=false:A={};for(G in t)if(G.charAt(0)=="!"){G=G.slice(1);v.push(G);A[G]=true;y=false}for(;G=v.pop();){t[G]=t["!"+G];delete t["!"+G]}o[r]=(y?false:A)||null}f.match=f.match||null;e.push(h);a.push(h)}for(var b=d.elements,d=d.generic,n,c=0,e=a.length;c<e;++c){g=H(a[c]);h=g.classes===true||g.styles===true||
g.attributes===true;f=g;j=r=k=void 0;for(k in D)f[k]=s(f[k]);o=true;for(j in E){k=E[j];r=f[k];A=[];t=void 0;for(t in r)t.indexOf("*")>-1?A.push(RegExp("^"+t.replace(/\*/g,".*")+"$")):A.push(t);r=A;if(r.length){f[k]=r;o=false}}f.nothingRequired=o;f.noProperties=!(f.attributes||f.classes||f.styles);if(g.elements===true||g.elements===null)d[h?"unshift":"push"](g);else{f=g.elements;delete g.elements;for(n in f)if(b[n])b[n][h?"unshift":"push"](g);else b[n]=[g]}}}function f(a,b,c,g){if(!a.match||a.match(b))if(g||
e(a,b)){if(!a.propertiesOnly)c.valid=true;if(!c.allAttributes)c.allAttributes=d(a.attributes,b.attributes,c.validAttributes);if(!c.allStyles)c.allStyles=d(a.styles,b.styles,c.validStyles);if(!c.allClasses){a=a.classes;b=b.classes;g=c.validClasses;if(a)if(a===true)a=true;else{for(var h=0,i=b.length,f;h<i;++h){f=b[h];g[f]||(g[f]=a(f))}a=false}else a=false;c.allClasses=a}}}function d(a,b,c){if(!a)return false;if(a===true)return true;for(var e in b)c[e]||(c[e]=a(e));return false}function c(a,c,e){if(!a.match||
a.match(c)){if(a.noProperties)return false;e.hadInvalidAttribute=b(a.attributes,c.attributes)||e.hadInvalidAttribute;e.hadInvalidStyle=b(a.styles,c.styles)||e.hadInvalidStyle;a=a.classes;c=c.classes;if(a){for(var d=false,g=a===true,h=c.length;h--;)if(g||a(c[h])){c.splice(h,1);d=true}a=d}else a=false;e.hadInvalidClass=a||e.hadInvalidClass}}function b(a,b){if(!a)return false;var c=false,e=a===true,d;for(d in b)if(e||a(d)){delete b[d];c=true}return c}function g(a,b,c){if(a.disabled||a.customConfig&&
!c||!b)return false;a._.cachedChecks={};return true}function i(a,b){if(!a)return false;if(a===true)return a;if(typeof a=="string"){a=F(a);return a=="*"?true:CKEDITOR.tools.convertArrayToObject(a.split(b))}if(CKEDITOR.tools.isArray(a))return a.length?CKEDITOR.tools.convertArrayToObject(a):false;var c={},e=0,d;for(d in a){c[d]=a[d];e++}return e?c:false}function e(a,b){if(a.nothingRequired)return true;var c,e,d,g;if(d=a.requiredClasses){g=b.classes;for(c=0;c<d.length;++c){e=d[c];if(typeof e=="string"){if(CKEDITOR.tools.indexOf(g,
e)==-1)return false}else if(!CKEDITOR.tools.checkIfAnyArrayItemMatches(g,e))return false}}return h(b.styles,a.requiredStyles)&&h(b.attributes,a.requiredAttributes)}function h(a,b){if(!b)return true;for(var c=0,e;c<b.length;++c){e=b[c];if(typeof e=="string"){if(!(e in a))return false}else if(!CKEDITOR.tools.checkIfAnyObjectPropertyMatches(a,e))return false}return true}function k(a){if(!a)return{};for(var a=a.split(/\s*,\s*/).sort(),b={};a.length;)b[a.shift()]=I;return b}function j(a){for(var b,c,e,
d,g={},h=1,a=F(a);b=a.match(G);){if(c=b[2]){e=m(c,"styles");d=m(c,"attrs");c=m(c,"classes")}else e=d=c=null;g["$"+h++]={elements:b[1],classes:c,styles:e,attributes:d};a=a.slice(b[0].length)}return g}function m(a,b){var c=a.match(K[b]);return c?F(c[1]):null}function q(a){var b=a.styleBackup=a.attributes.style,c=a.classBackup=a.attributes["class"];if(!a.styles)a.styles=CKEDITOR.tools.parseCssText(b||"",1);if(!a.classes)a.classes=c?c.split(/\s+/):[]}function l(a,b,e,d){var g=0,h;if(d.toHtml)b.name=b.name.replace(N,
"$1");if(d.doCallbacks&&a.elementCallbacks){a:for(var i=a.elementCallbacks,k=0,j=i.length,o;k<j;++k)if(o=i[k](b)){h=o;break a}if(h)return h}if(d.doTransform)if(h=a._.transformations[b.name]){q(b);for(i=0;i<h.length;++i)t(a,b,h[i]);p(b)}if(d.doFilter){a:{i=b.name;k=a._;a=k.allowedRules.elements[i];h=k.allowedRules.generic;i=k.disallowedRules.elements[i];k=k.disallowedRules.generic;j=d.skipRequired;o={valid:false,validAttributes:{},validClasses:{},validStyles:{},allAttributes:false,allClasses:false,
allStyles:false,hadInvalidAttribute:false,hadInvalidClass:false,hadInvalidStyle:false};var A,D;if(!a&&!h)a=null;else{q(b);if(i){A=0;for(D=i.length;A<D;++A)if(c(i[A],b,o)===false){a=null;break a}}if(k){A=0;for(D=k.length;A<D;++A)c(k[A],b,o)}if(a){A=0;for(D=a.length;A<D;++A)f(a[A],b,o,j)}if(h){A=0;for(D=h.length;A<D;++A)f(h[A],b,o,j)}a=o}}if(!a){e.push(b);return C}if(!a.valid){e.push(b);return C}D=a.validAttributes;var v=a.validStyles;h=a.validClasses;var i=b.attributes,y=b.styles,k=b.classes,j=b.classBackup,
G=b.styleBackup,n,m,u=[];o=[];var s=/^data-cke-/;A=false;delete i.style;delete i["class"];delete b.classBackup;delete b.styleBackup;if(!a.allAttributes)for(n in i)if(!D[n])if(s.test(n)){if(n!=(m=n.replace(/^data-cke-saved-/,""))&&!D[m]){delete i[n];A=true}}else{delete i[n];A=true}if(!a.allStyles||a.hadInvalidStyle){for(n in y)a.allStyles||v[n]?u.push(n+":"+y[n]):A=true;if(u.length)i.style=u.sort().join("; ")}else if(G)i.style=G;if(!a.allClasses||a.hadInvalidClass){for(n=0;n<k.length;++n)(a.allClasses||
h[k[n]])&&o.push(k[n]);o.length&&(i["class"]=o.sort().join(" "));j&&o.length<j.split(/\s+/).length&&(A=true)}else j&&(i["class"]=j);A&&(g=C);if(!d.skipFinalValidation&&!r(b)){e.push(b);return C}}if(d.toHtml)b.name=b.name.replace(Q,"cke:$1");return g}function o(a){var b=[],c;for(c in a)c.indexOf("*")>-1&&b.push(c.replace(/\*/g,".*"));return b.length?RegExp("^(?:"+b.join("|")+")$"):null}function p(a){var b=a.attributes,c;delete b.style;delete b["class"];if(c=CKEDITOR.tools.writeCssText(a.styles,true))b.style=
c;a.classes.length&&(b["class"]=a.classes.sort().join(" "))}function r(a){switch(a.name){case "a":if(!a.children.length&&!a.attributes.name)return false;break;case "img":if(!a.attributes.src)return false}return true}function s(a){if(!a)return false;if(a===true)return true;var b=o(a);return function(c){return c in a||b&&c.match(b)}}function u(){return new CKEDITOR.htmlParser.element("br")}function w(a){return a.type==CKEDITOR.NODE_ELEMENT&&(a.name=="br"||B.$block[a.name])}function v(a,b,c){var e=a.name;
if(B.$empty[e]||!a.children.length)if(e=="hr"&&b=="br")a.replaceWith(u());else{a.parent&&c.push({check:"it",el:a.parent});a.remove()}else if(B.$block[e]||e=="tr")if(b=="br"){if(a.previous&&!w(a.previous)){b=u();b.insertBefore(a)}if(a.next&&!w(a.next)){b=u();b.insertAfter(a)}a.replaceWithChildren()}else{var e=a.children,d;b:{d=B[b];for(var g=0,h=e.length,i;g<h;++g){i=e[g];if(i.type==CKEDITOR.NODE_ELEMENT&&!d[i.name]){d=false;break b}}d=true}if(d){a.name=b;a.attributes={};c.push({check:"parent-down",
el:a})}else{d=a.parent;for(var g=d.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT||d.name=="body",f,k,h=e.length;h>0;){i=e[--h];if(g&&(i.type==CKEDITOR.NODE_TEXT||i.type==CKEDITOR.NODE_ELEMENT&&B.$inline[i.name])){if(!f){f=new CKEDITOR.htmlParser.element(b);f.insertAfter(a);c.push({check:"parent-down",el:f})}f.add(i,0)}else{f=null;k=B[d.name]||B.span;i.insertAfter(a);d.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT&&(i.type==CKEDITOR.NODE_ELEMENT&&!k[i.name])&&c.push({check:"el-up",el:i})}}a.remove()}}else if(e=="style")a.remove();
else{a.parent&&c.push({check:"it",el:a.parent});a.replaceWithChildren()}}function t(a,b,c){var e,d;for(e=0;e<c.length;++e){d=c[e];if((!d.check||a.check(d.check,false))&&(!d.left||d.left(b))){d.right(b,O);break}}}function y(a,b){var c=b.getDefinition(),e=c.attributes,d=c.styles,g,h,i,f;if(a.name!=c.element)return false;for(g in e)if(g=="class"){c=e[g].split(/\s+/);for(i=a.classes.join("|");f=c.pop();)if(i.indexOf(f)==-1)return false}else if(a.attributes[g]!=e[g])return false;for(h in d)if(a.styles[h]!=
d[h])return false;return true}function n(a,b){var c,e;if(typeof a=="string")c=a;else if(a instanceof CKEDITOR.style)e=a;else{c=a[0];e=a[1]}return[{element:c,left:e,right:function(a,c){c.transform(a,b)}}]}function x(a){return function(b){return y(b,a)}}function z(a){return function(b,c){c[a](b)}}var B=CKEDITOR.dtd,C=1,H=CKEDITOR.tools.copy,F=CKEDITOR.tools.trim,I="cke-test",A=["","p","br","div"];CKEDITOR.FILTER_SKIP_TREE=2;CKEDITOR.filter=function(a){this.allowedContent=[];this.disallowedContent=[];
this.elementCallbacks=null;this.disabled=false;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=true;var b=a.config.allowedContent;if(b===true)this.disabled=true;else{if(!b)this.customConfig=false;this.allow(b,"config",1);this.allow(a.config.extraAllowedContent,"extra",
1);this.allow(A[a.enterMode]+" "+A[a.shiftEnterMode],"default",1);this.disallow(a.config.disallowedContent)}}else{this.customConfig=false;this.allow(a,"default",1)}};CKEDITOR.filter.instances={};CKEDITOR.filter.prototype={allow:function(b,c,e){if(!g(this,b,e))return false;var d,h;if(typeof b=="string")b=j(b);else if(b instanceof CKEDITOR.style){if(b.toAllowedContentRules)return this.allow(b.toAllowedContentRules(this.editor),c,e);d=b.getDefinition();b={};e=d.attributes;b[d.element]=d={styles:d.styles,
requiredStyles:d.styles&&CKEDITOR.tools.objectKeys(d.styles)};if(e){e=H(e);d.classes=e["class"]?e["class"].split(/\s+/):null;d.requiredClasses=d.classes;delete e["class"];d.attributes=e;d.requiredAttributes=e&&CKEDITOR.tools.objectKeys(e)}}else if(CKEDITOR.tools.isArray(b)){for(d=0;d<b.length;++d)h=this.allow(b[d],c,e);return h}a(this,b,c,this.allowedContent,this._.allowedRules);return true},applyTo:function(a,b,c,e){if(this.disabled)return false;var d=this,g=[],h=this.editor&&this.editor.config.protectedSource,
i,f=false,k={doFilter:!c,doTransform:true,doCallbacks:true,toHtml:b};a.forEach(function(a){if(a.type==CKEDITOR.NODE_ELEMENT){if(a.attributes["data-cke-filter"]=="off")return false;if(!b||!(a.name=="span"&&~CKEDITOR.tools.objectKeys(a.attributes).join("|").indexOf("data-cke-"))){i=l(d,a,g,k);if(i&C)f=true;else if(i&2)return false}}else if(a.type==CKEDITOR.NODE_COMMENT&&a.value.match(/^\{cke_protected\}(?!\{C\})/)){var c;a:{var e=decodeURIComponent(a.value.replace(/^\{cke_protected\}/,""));c=[];var j,
o,A;if(h)for(o=0;o<h.length;++o)if((A=e.match(h[o]))&&A[0].length==e.length){c=true;break a}e=CKEDITOR.htmlParser.fragment.fromHtml(e);e.children.length==1&&(j=e.children[0]).type==CKEDITOR.NODE_ELEMENT&&l(d,j,c,k);c=!c.length}c||g.push(a)}},null,true);g.length&&(f=true);for(var j,a=[],e=A[e||(this.editor?this.editor.enterMode:CKEDITOR.ENTER_P)],o;c=g.pop();)c.type==CKEDITOR.NODE_ELEMENT?v(c,e,a):c.remove();for(;j=a.pop();){c=j.el;if(c.parent){o=B[c.parent.name]||B.span;switch(j.check){case "it":B.$removeEmpty[c.name]&&
!c.children.length?v(c,e,a):r(c)||v(c,e,a);break;case "el-up":c.parent.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT&&!o[c.name]&&v(c,e,a);break;case "parent-down":c.parent.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT&&!o[c.name]&&v(c.parent,e,a)}}}return f},checkFeature:function(a){if(this.disabled||!a)return true;a.toFeature&&(a=a.toFeature(this.editor));return!a.requiredContent||this.check(a.requiredContent)},disable:function(){this.disabled=true},disallow:function(b){if(!g(this,b,true))return false;typeof b==
"string"&&(b=j(b));a(this,b,null,this.disallowedContent,this._.disallowedRules);return true},addContentForms:function(a){if(!this.disabled&&a){var b,c,e=[],d;for(b=0;b<a.length&&!d;++b){c=a[b];if((typeof c=="string"||c instanceof CKEDITOR.style)&&this.check(c))d=c}if(d){for(b=0;b<a.length;++b)e.push(n(a[b],d));this.addTransformations(e)}}},addElementCallback:function(a){if(!this.elementCallbacks)this.elementCallbacks=[];this.elementCallbacks.push(a)},addFeature:function(a){if(this.disabled||!a)return true;
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):true},addTransformations:function(a){var b,c;if(!this.disabled&&a){var e=this._.transformations,d;for(d=0;d<a.length;++d){b=a[d];var g=void 0,h=void 0,i=void 0,f=void 0,k=void 0,j=void 0;c=[];for(h=0;h<b.length;++h){i=b[h];if(typeof i==
"string"){i=i.split(/\s*:\s*/);f=i[0];k=null;j=i[1]}else{f=i.check;k=i.left;j=i.right}if(!g){g=i;g=g.element?g.element:f?f.match(/^([a-z0-9]+)/i)[0]:g.left.getDefinition().element}k instanceof CKEDITOR.style&&(k=x(k));c.push({check:f==g?null:f,left:k,right:typeof j=="string"?z(j):j})}b=g;e[b]||(e[b]=[]);e[b].push(c)}}},check:function(a,b,c){if(this.disabled)return true;if(CKEDITOR.tools.isArray(a)){for(var e=a.length;e--;)if(this.check(a[e],b,c))return true;return false}var d,g;if(typeof a=="string"){g=
a+"<"+(b===false?"0":"1")+(c?"1":"0")+">";if(g in this._.cachedChecks)return this._.cachedChecks[g];e=j(a).$1;d=e.styles;var h=e.classes;e.name=e.elements;e.classes=h=h?h.split(/\s*,\s*/):[];e.styles=k(d);e.attributes=k(e.attributes);e.children=[];h.length&&(e.attributes["class"]=h.join(" "));if(d)e.attributes.style=CKEDITOR.tools.writeCssText(e.styles);d=e}else{e=a.getDefinition();d=e.styles;h=e.attributes||{};if(d){d=H(d);h.style=CKEDITOR.tools.writeCssText(d,true)}else d={};d={name:e.element,attributes:h,
classes:h["class"]?h["class"].split(/\s+/):[],styles:d,children:[]}}var h=CKEDITOR.tools.clone(d),i=[],f;if(b!==false&&(f=this._.transformations[d.name])){for(e=0;e<f.length;++e)t(this,d,f[e]);p(d)}l(this,h,i,{doFilter:true,doTransform:b!==false,skipRequired:!c,skipFinalValidation:!c});b=i.length>0?false:CKEDITOR.tools.objectCompare(d.attributes,h.attributes,true)?true:false;typeof a=="string"&&(this._.cachedChecks[g]=b);return b},getAllowedEnterMode:function(){var a=["p","div","br"],b={p:CKEDITOR.ENTER_P,
div:CKEDITOR.ENTER_DIV,br:CKEDITOR.ENTER_BR};return function(c,e){var d=a.slice(),g;if(this.check(A[c]))return c;for(e||(d=d.reverse());g=d.pop();)if(this.check(g))return b[g];return CKEDITOR.ENTER_BR}}(),destroy:function(){delete CKEDITOR.filter.instances[this.id];delete this._;delete this.allowedContent;delete this.disallowedContent}};var D={styles:1,attributes:1,classes:1},E={styles:"requiredStyles",attributes:"requiredAttributes",classes:"requiredClasses"},G=/^([a-z0-9\-*\s]+)((?:\s*\{[!\w\-,\s\*]+\}\s*|\s*\[[!\w\-,\s\*]+\]\s*|\s*\([!\w\-,\s\*]+\)\s*){0,3})(?:;\s*|$)/i,
K={styles:/{([^}]+)}/,attrs:/\[([^\]]+)\]/,classes:/\(([^\)]+)\)/},N=/^cke:(object|embed|param)$/,Q=/^(object|embed|param)$/,O=CKEDITOR.filter.transformationsTools={sizeToStyle:function(a){this.lengthToStyle(a,"width");this.lengthToStyle(a,"height")},sizeToAttribute:function(a){this.lengthToAttribute(a,"width");this.lengthToAttribute(a,"height")},lengthToStyle:function(a,b,c){c=c||b;if(!(c in a.styles)){var e=a.attributes[b];if(e){/^\d+$/.test(e)&&(e=e+"px");a.styles[c]=e}}delete a.attributes[b]},
lengthToAttribute:function(a,b,c){c=c||b;if(!(c in a.attributes)){var e=a.styles[b],d=e&&e.match(/^(\d+)(?:\.\d*)?px$/);d?a.attributes[c]=d[1]:e==I&&(a.attributes[c]=I)}delete a.styles[b]},alignmentToStyle:function(a){if(!("float"in a.styles)){var b=a.attributes.align;if(b=="left"||b=="right")a.styles["float"]=b}delete a.attributes.align},alignmentToAttribute:function(a){if(!("align"in a.attributes)){var b=a.styles["float"];if(b=="left"||b=="right")a.attributes.align=b}delete a.styles["float"]},matchesStyle:y,
transform:function(a,b){if(typeof b=="string")a.name=b;else{var c=b.getDefinition(),e=c.styles,d=c.attributes,g,h,i,f;a.name=c.element;for(g in d)if(g=="class"){c=a.classes.join("|");for(i=d[g].split(/\s+/);f=i.pop();)c.indexOf(f)==-1&&a.classes.push(f)}else a.attributes[g]=d[g];for(h in e)a.styles[h]=e[h]}}}})();(function(){CKEDITOR.focusManager=function(a){if(a.focusManager)return a.focusManager;this.hasFocus=false;this.currentActive=null;this._={editor:a};return this};CKEDITOR.focusManager._={blurDelay:200};
CKEDITOR.focusManager.prototype={focus:function(a){this._.timer&&clearTimeout(this._.timer);if(a)this.currentActive=a;if(!this.hasFocus&&!this._.locked){(a=CKEDITOR.currentInstance)&&a.focusManager.blur(1);this.hasFocus=true;(a=this._.editor.container)&&a.addClass("cke_focus");this._.editor.fire("focus")}},lock:function(){this._.locked=1},unlock:function(){delete this._.locked},blur:function(a){function f(){if(this.hasFocus){this.hasFocus=false;var a=this._.editor.container;a&&a.removeClass("cke_focus");
this._.editor.fire("blur")}}if(!this._.locked){this._.timer&&clearTimeout(this._.timer);var d=CKEDITOR.focusManager._.blurDelay;a||!d?f.call(this):this._.timer=CKEDITOR.tools.setTimeout(function(){delete this._.timer;f.call(this)},d,this)}},add:function(a,f){var d=a.getCustomData("focusmanager");if(!d||d!=this){d&&d.remove(a);var d="focus",c="blur";if(f)if(CKEDITOR.env.ie){d="focusin";c="focusout"}else CKEDITOR.event.useCapture=1;var b={blur:function(){a.equals(this.currentActive)&&this.blur()},focus:function(){this.focus(a)}};
a.on(d,b.focus,this);a.on(c,b.blur,this);if(f)CKEDITOR.event.useCapture=0;a.setCustomData("focusmanager",this);a.setCustomData("focusmanager_handlers",b)}},remove:function(a){a.removeCustomData("focusmanager");var f=a.removeCustomData("focusmanager_handlers");a.removeListener("blur",f.blur);a.removeListener("focus",f.focus)}}})();CKEDITOR.keystrokeHandler=function(a){if(a.keystrokeHandler)return a.keystrokeHandler;this.keystrokes={};this.blockedKeystrokes={};this._={editor:a};return this};(function(){var a,
f=function(c){var c=c.data,b=c.getKeystroke(),d=this.keystrokes[b],i=this._.editor;a=i.fire("key",{keyCode:b,domEvent:c})===false;if(!a){d&&(a=i.execCommand(d,{from:"keystrokeHandler"})!==false);a||(a=!!this.blockedKeystrokes[b])}a&&c.preventDefault(true);return!a},d=function(c){if(a){a=false;c.data.preventDefault(true)}};CKEDITOR.keystrokeHandler.prototype={attach:function(a){a.on("keydown",f,this);if(CKEDITOR.env.gecko&&CKEDITOR.env.mac)a.on("keypress",d,this)}}})();(function(){CKEDITOR.lang={languages:{af:1,
ar:1,bg:1,bn:1,bs:1,ca:1,cs:1,cy:1,da:1,de: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,pl:1,"pt-br":1,pt:1,ro:1,ru:1,si:1,sk:1,sl:1,sq:1,"sr-latn":1,sr:1,sv:1,th:1,tr:1,tt:1,ug:1,uk:1,vi:1,"zh-cn":1,zh:1},rtl:{ar:1,fa:1,he:1,ku:1,ug:1},load:function(a,f,d){if(!a||!CKEDITOR.lang.languages[a])a=this.detect(f,a);var c=this,f=function(){c[a].dir=
c.rtl[a]?"rtl":"ltr";d(a,c[a])};this[a]?f():CKEDITOR.scriptLoader.load(CKEDITOR.getUrl("lang/"+a+".js"),f,this)},detect:function(a,f){var d=this.languages,f=f||navigator.userLanguage||navigator.language||a,c=f.toLowerCase().match(/([a-z]+)(?:-([a-z]+))?/),b=c[1],c=c[2];d[b+"-"+c]?b=b+"-"+c:d[b]||(b=null);CKEDITOR.lang.detect=b?function(){return b}:function(a){return a};return b||a}}})();CKEDITOR.scriptLoader=function(){var a={},f={};return{load:function(d,c,b,g){var i=typeof d=="string";i&&(d=[d]);
b||(b=CKEDITOR);var e=d.length,h=[],k=[],j=function(a){c&&(i?c.call(b,a):c.call(b,h,k))};if(e===0)j(true);else{var m=function(a,b){(b?h:k).push(a);if(--e<=0){g&&CKEDITOR.document.getDocumentElement().removeStyle("cursor");j(b)}},q=function(b,c){a[b]=1;var e=f[b];delete f[b];for(var d=0;d<e.length;d++)e[d](b,c)},l=function(b){if(a[b])m(b,true);else{var e=f[b]||(f[b]=[]);e.push(m);if(!(e.length>1)){var d=new CKEDITOR.dom.element("script");d.setAttributes({type:"text/javascript",src:b});if(c)if(CKEDITOR.env.ie&&
CKEDITOR.env.version<11)d.$.onreadystatechange=function(){if(d.$.readyState=="loaded"||d.$.readyState=="complete"){d.$.onreadystatechange=null;q(b,true)}};else{d.$.onload=function(){setTimeout(function(){q(b,true)},0)};d.$.onerror=function(){q(b,false)}}d.appendTo(CKEDITOR.document.getHead())}}};g&&CKEDITOR.document.getDocumentElement().setStyle("cursor","wait");for(var o=0;o<e;o++)l(d[o])}},queue:function(){function a(){var b;(b=c[0])&&this.load(b.scriptUrl,b.callback,CKEDITOR,0)}var c=[];return function(b,
g){var i=this;c.push({scriptUrl:b,callback:function(){g&&g.apply(this,arguments);c.shift();a.call(i)}});c.length==1&&a.call(this)}}()}}();CKEDITOR.resourceManager=function(a,f){this.basePath=a;this.fileName=f;this.registered={};this.loaded={};this.externals={};this._={waitingList:{}}};CKEDITOR.resourceManager.prototype={add:function(a,f){if(this.registered[a])throw'[CKEDITOR.resourceManager.add] The resource name "'+a+'" is already registered.';var d=this.registered[a]=f||{};d.name=a;d.path=this.getPath(a);
CKEDITOR.fire(a+CKEDITOR.tools.capitalize(this.fileName)+"Ready",d);return this.get(a)},get:function(a){return this.registered[a]||null},getPath:function(a){var f=this.externals[a];return CKEDITOR.getUrl(f&&f.dir||this.basePath+a+"/")},getFilePath:function(a){var f=this.externals[a];return CKEDITOR.getUrl(this.getPath(a)+(f?f.file:this.fileName+".js"))},addExternal:function(a,f,d){for(var a=a.split(","),c=0;c<a.length;c++){var b=a[c];d||(f=f.replace(/[^\/]+$/,function(a){d=a;return""}));this.externals[b]=
{dir:f,file:d||this.fileName+".js"}}},load:function(a,f,d){CKEDITOR.tools.isArray(a)||(a=a?[a]:[]);for(var c=this.loaded,b=this.registered,g=[],i={},e={},h=0;h<a.length;h++){var k=a[h];if(k)if(!c[k]&&!b[k]){var j=this.getFilePath(k);g.push(j);j in i||(i[j]=[]);i[j].push(k)}else e[k]=this.get(k)}CKEDITOR.scriptLoader.load(g,function(a,b){if(b.length)throw'[CKEDITOR.resourceManager.load] Resource name "'+i[b[0]].join(",")+'" was not found at "'+b[0]+'".';for(var g=0;g<a.length;g++)for(var h=i[a[g]],
k=0;k<h.length;k++){var j=h[k];e[j]=this.get(j);c[j]=1}f.call(d,e)},this)}};CKEDITOR.plugins=new CKEDITOR.resourceManager("plugins/","plugin");CKEDITOR.plugins.load=CKEDITOR.tools.override(CKEDITOR.plugins.load,function(a){var f={};return function(d,c,b){var g={},i=function(e){a.call(this,e,function(a){CKEDITOR.tools.extend(g,a);var e=[],d;for(d in a){var m=a[d],q=m&&m.requires;if(!f[d]){if(m.icons)for(var l=m.icons.split(","),o=l.length;o--;)CKEDITOR.skin.addIcon(l[o],m.path+"icons/"+(CKEDITOR.env.hidpi&&
m.hidpi?"hidpi/":"")+l[o]+".png");f[d]=1}if(q){q.split&&(q=q.split(","));for(m=0;m<q.length;m++)g[q[m]]||e.push(q[m])}}if(e.length)i.call(this,e);else{for(d in g){m=g[d];if(m.onLoad&&!m.onLoad._called){m.onLoad()===false&&delete g[d];m.onLoad._called=1}}c&&c.call(b||window,g)}},this)};i.call(this,d)}});CKEDITOR.plugins.setLang=function(a,f,d){var c=this.get(a),a=c.langEntries||(c.langEntries={}),c=c.lang||(c.lang=[]);c.split&&(c=c.split(","));CKEDITOR.tools.indexOf(c,f)==-1&&c.push(f);a[f]=d};CKEDITOR.ui=
function(a){if(a.ui)return a.ui;this.items={};this.instances={};this.editor=a;this._={handlers:{}};return this};CKEDITOR.ui.prototype={add:function(a,f,d){d.name=a.toLowerCase();var c=this.items[a]={type:f,command:d.command||null,args:Array.prototype.slice.call(arguments,2)};CKEDITOR.tools.extend(c,d)},get:function(a){return this.instances[a]},create:function(a){var f=this.items[a],d=f&&this._.handlers[f.type],c=f&&f.command&&this.editor.getCommand(f.command),d=d&&d.create.apply(this,f.args);this.instances[a]=
d;c&&c.uiItems.push(d);if(d&&!d.type)d.type=f.type;return d},addHandler:function(a,f){this._.handlers[a]=f},space:function(a){return CKEDITOR.document.getById(this.spaceId(a))},spaceId:function(a){return this.editor.id+"_"+a}};CKEDITOR.event.implementOn(CKEDITOR.ui);(function(){function a(a,c,e){CKEDITOR.event.call(this);a=a&&CKEDITOR.tools.clone(a);if(c!==void 0){if(c instanceof CKEDITOR.dom.element){if(!e)throw Error("One of the element modes must be specified.");}else throw Error("Expect element of type CKEDITOR.dom.element.");
if(CKEDITOR.env.ie&&CKEDITOR.env.quirks&&e==CKEDITOR.ELEMENT_MODE_INLINE)throw Error("Inline element mode is not supported on IE quirks.");if(!(e==CKEDITOR.ELEMENT_MODE_INLINE?c.is(CKEDITOR.dtd.$editable)||c.is("textarea"):e==CKEDITOR.ELEMENT_MODE_REPLACE?!c.is(CKEDITOR.dtd.$nonBodyContent):1))throw Error('The specified element mode is not supported on element: "'+c.getName()+'".');this.element=c;this.elementMode=e;this.name=this.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO&&(c.getId()||c.getNameAtt())}else this.elementMode=
CKEDITOR.ELEMENT_MODE_NONE;this._={};this.commands={};this.templates={};this.name=this.name||f();this.id=CKEDITOR.tools.getNextId();this.status="unloaded";this.config=CKEDITOR.tools.prototypedCopy(CKEDITOR.config);this.ui=new CKEDITOR.ui(this);this.focusManager=new CKEDITOR.focusManager(this);this.keystrokeHandler=new CKEDITOR.keystrokeHandler(this);this.on("readOnly",d);this.on("selectionChange",function(a){b(this,a.data.path)});this.on("activeFilterChange",function(){b(this,this.elementPath(),true)});
this.on("mode",d);this.on("instanceReady",function(){this.config.startupFocus&&this.focus()});CKEDITOR.fire("instanceCreated",null,this);CKEDITOR.add(this);CKEDITOR.tools.setTimeout(function(){i(this,a)},0,this)}function f(){do var a="editor"+ ++q;while(CKEDITOR.instances[a]);return a}function d(){var a=this.commands,b;for(b in a)c(this,a[b])}function c(a,b){b[b.startDisabled?"disable":a.readOnly&&!b.readOnly?"disable":b.modes[a.mode]?"enable":"disable"]()}function b(a,b,c){if(b){var e,d,g=a.commands;
for(d in g){e=g[d];(c||e.contextSensitive)&&e.refresh(a,b)}}}function g(a){var b=a.config.customConfig;if(!b)return false;var b=CKEDITOR.getUrl(b),c=l[b]||(l[b]={});if(c.fn){c.fn.call(a,a.config);(CKEDITOR.getUrl(a.config.customConfig)==b||!g(a))&&a.fireOnce("customConfigLoaded")}else CKEDITOR.scriptLoader.queue(b,function(){c.fn=CKEDITOR.editorConfig?CKEDITOR.editorConfig:function(){};g(a)});return true}function i(a,b){a.on("customConfigLoaded",function(){if(b){if(b.on)for(var c in b.on)a.on(c,b.on[c]);
CKEDITOR.tools.extend(a.config,b,true);delete a.config.on}c=a.config;a.readOnly=!(!c.readOnly&&!(a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?a.element.is("textarea")?a.element.hasAttribute("disabled"):a.element.isReadOnly():a.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE&&a.element.hasAttribute("disabled")));a.blockless=a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?!(a.element.is("textarea")||CKEDITOR.dtd[a.element.getName()].p):false;a.tabIndex=c.tabIndex||a.element&&a.element.getAttribute("tabindex")||
0;a.activeEnterMode=a.enterMode=a.blockless?CKEDITOR.ENTER_BR:c.enterMode;a.activeShiftEnterMode=a.shiftEnterMode=a.blockless?CKEDITOR.ENTER_BR:c.shiftEnterMode;if(c.skin)CKEDITOR.skinName=c.skin;a.fireOnce("configLoaded");a.dataProcessor=new CKEDITOR.htmlDataProcessor(a);a.filter=a.activeFilter=new CKEDITOR.filter(a);e(a)});if(b&&b.customConfig!=null)a.config.customConfig=b.customConfig;g(a)||a.fireOnce("customConfigLoaded")}function e(a){CKEDITOR.skin.loadPart("editor",function(){h(a)})}function h(a){CKEDITOR.lang.load(a.config.language,
a.config.defaultLanguage,function(b,c){var e=a.config.title;a.langCode=b;a.lang=CKEDITOR.tools.prototypedCopy(c);a.title=typeof e=="string"||e===false?e:[a.lang.editor,a.name].join(", ");if(!a.config.contentsLangDirection)a.config.contentsLangDirection=a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?a.element.getDirection(1):a.lang.dir;a.fire("langLoaded");k(a)})}function k(a){a.getStylesSet(function(b){a.once("loaded",function(){a.fire("stylesSet",{styles:b})},null,null,1);j(a)})}function j(a){var b=
a.config,c=b.plugins,e=b.extraPlugins,d=b.removePlugins;if(e)var g=RegExp("(?:^|,)(?:"+e.replace(/\s*,\s*/g,"|")+")(?=,|$)","g"),c=c.replace(g,""),c=c+(","+e);if(d)var h=RegExp("(?:^|,)(?:"+d.replace(/\s*,\s*/g,"|")+")(?=,|$)","g"),c=c.replace(h,"");CKEDITOR.env.air&&(c=c+",adobeair");CKEDITOR.plugins.load(c.split(","),function(c){var e=[],d=[],g=[];a.plugins=c;for(var i in c){var f=c[i],k=f.lang,j=null,r=f.requires,m;CKEDITOR.tools.isArray(r)&&(r=r.join(","));if(r&&(m=r.match(h)))for(;r=m.pop();)CKEDITOR.tools.setTimeout(function(a,
b){throw Error('Plugin "'+a.replace(",","")+'" cannot be removed from the plugins list, because it\'s required by "'+b+'" plugin.');},0,null,[r,i]);if(k&&!a.lang[i]){k.split&&(k=k.split(","));if(CKEDITOR.tools.indexOf(k,a.langCode)>=0)j=a.langCode;else{j=a.langCode.replace(/-.*/,"");j=j!=a.langCode&&CKEDITOR.tools.indexOf(k,j)>=0?j:CKEDITOR.tools.indexOf(k,"en")>=0?"en":k[0]}if(!f.langEntries||!f.langEntries[j])g.push(CKEDITOR.getUrl(f.path+"lang/"+j+".js"));else{a.lang[i]=f.langEntries[j];j=null}}d.push(j);
e.push(f)}CKEDITOR.scriptLoader.load(g,function(){for(var c=["beforeInit","init","afterInit"],g=0;g<c.length;g++)for(var h=0;h<e.length;h++){var i=e[h];g===0&&(d[h]&&i.lang&&i.langEntries)&&(a.lang[i.name]=i.langEntries[d[h]]);if(i[c[g]])i[c[g]](a)}a.fireOnce("pluginsLoaded");b.keystrokes&&a.setKeystroke(a.config.keystrokes);for(h=0;h<a.config.blockedKeystrokes.length;h++)a.keystrokeHandler.blockedKeystrokes[a.config.blockedKeystrokes[h]]=1;a.status="loaded";a.fireOnce("loaded");CKEDITOR.fire("instanceLoaded",
null,a)})})}function m(){var a=this.element;if(a&&this.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO){var b=this.getData();this.config.htmlEncodeOutput&&(b=CKEDITOR.tools.htmlEncode(b));a.is("textarea")?a.setValue(b):a.setHtml(b);return true}return false}a.prototype=CKEDITOR.editor.prototype;CKEDITOR.editor=a;var q=0,l={};CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{addCommand:function(a,b){b.name=a.toLowerCase();var e=new CKEDITOR.command(this,b);this.mode&&c(this,e);return this.commands[a]=e},
_attachToForm:function(){function a(e){b.updateElement();b._.required&&(!c.getValue()&&b.fire("required")===false)&&e.data.preventDefault()}var b=this,c=b.element,e=new CKEDITOR.dom.element(c.$.form);if(c.is("textarea")&&e){e.on("submit",a);if(e.$.submit&&e.$.submit.call&&e.$.submit.apply)e.$.submit=CKEDITOR.tools.override(e.$.submit,function(b){return function(){a();b.apply?b.apply(this):b()}});b.on("destroy",function(){e.removeListener("submit",a)})}},destroy:function(a){this.fire("beforeDestroy");
!a&&m.call(this);this.editable(null);this.filter.destroy();delete this.filter;delete this.activeFilter;this.status="destroyed";this.fire("destroy");this.removeAllListeners();CKEDITOR.remove(this);CKEDITOR.fire("instanceDestroyed",null,this)},elementPath:function(a){if(!a){a=this.getSelection();if(!a)return null;a=a.getStartElement()}return a?new CKEDITOR.dom.elementPath(a,this.editable()):null},createRange:function(){var a=this.editable();return a?new CKEDITOR.dom.range(a):null},execCommand:function(a,
b){var c=this.getCommand(a),e={name:a,commandData:b,command:c};if(c&&c.state!=CKEDITOR.TRISTATE_DISABLED&&this.fire("beforeCommandExec",e)!==false){e.returnValue=c.exec(e.commandData);if(!c.async&&this.fire("afterCommandExec",e)!==false)return e.returnValue}return false},getCommand:function(a){return this.commands[a]},getData:function(a){!a&&this.fire("beforeGetData");var b=this._.data;if(typeof b!="string")b=(b=this.element)&&this.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE?b.is("textarea")?b.getValue():
b.getHtml():"";b={dataValue:b};!a&&this.fire("getData",b);return b.dataValue},getSnapshot:function(){var a=this.fire("getSnapshot");if(typeof a!="string"){var b=this.element;b&&this.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE&&(a=b.is("textarea")?b.getValue():b.getHtml())}return a},loadSnapshot:function(a){this.fire("loadSnapshot",a)},setData:function(a,b,c){var e=true,d=b;if(b&&typeof b=="object"){c=b.internal;d=b.callback;e=!b.noSnapshot}!c&&e&&this.fire("saveSnapshot");if(d||!c)this.once("dataReady",
function(a){!c&&e&&this.fire("saveSnapshot");d&&d.call(a.editor)});a={dataValue:a};!c&&this.fire("setData",a);this._.data=a.dataValue;!c&&this.fire("afterSetData",a)},setReadOnly:function(a){a=a==null||a;if(this.readOnly!=a){this.readOnly=a;this.keystrokeHandler.blockedKeystrokes[8]=+a;this.editable().setReadOnly(a);this.fire("readOnly")}},insertHtml:function(a,b){this.fire("insertHtml",{dataValue:a,mode:b})},insertText:function(a){this.fire("insertText",a)},insertElement:function(a){this.fire("insertElement",
a)},focus:function(){this.fire("beforeFocus")},checkDirty:function(){return this.status=="ready"&&this._.previousValue!==this.getSnapshot()},resetDirty:function(){this._.previousValue=this.getSnapshot()},updateElement:function(){return m.call(this)},setKeystroke:function(){for(var a=this.keystrokeHandler.keystrokes,b=CKEDITOR.tools.isArray(arguments[0])?arguments[0]:[[].slice.call(arguments,0)],c,e,d=b.length;d--;){c=b[d];e=0;if(CKEDITOR.tools.isArray(c)){e=c[1];c=c[0]}e?a[c]=e:delete a[c]}},addFeature:function(a){return this.filter.addFeature(a)},
setActiveFilter:function(a){if(!a)a=this.filter;if(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,true))}},setActiveEnterMode:function(a,b){a=a?this.blockless?CKEDITOR.ENTER_BR:a:this.enterMode;b=b?this.blockless?CKEDITOR.ENTER_BR:b:this.shiftEnterMode;if(this.activeEnterMode!=a||this.activeShiftEnterMode!=b){this.activeEnterMode=
a;this.activeShiftEnterMode=b;this.fire("activeEnterModeChange")}}})})();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]*?)--\>)|(?:([^\/\s>]+)((?:\s+[\w\-:.]+(?:\s*=\s*?(?:(?:"[^"]*")|(?:'[^']*')|[^\s"'\/>]+))?)*)[\S\s]*?(\/?)>))/g}};(function(){var a=/([\w\-:.]+)(?:(?:\s*=\s*(?:(?:"([^"]*)")|(?:'([^']*)')|([^\s>]+)))|(?=\s|$))/g,f=
{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(d){for(var c,b,g=0,i;c=this._.htmlPartsRegex.exec(d);){b=c.index;if(b>g){g=d.substring(g,b);if(i)i.push(g);else this.onText(g)}g=this._.htmlPartsRegex.lastIndex;if(b=c[1]){b=b.toLowerCase();if(i&&CKEDITOR.dtd.$cdata[b]){this.onCDATA(i.join(""));
i=null}if(!i){this.onTagClose(b);continue}}if(i)i.push(c[0]);else if(b=c[3]){b=b.toLowerCase();if(!/="/.test(b)){var e={},h,k=c[4];c=!!c[5];if(k)for(;h=a.exec(k);){var j=h[1].toLowerCase();h=h[2]||h[3]||h[4]||"";e[j]=!h&&f[j]?j:CKEDITOR.tools.htmlDecodeAttr(h)}this.onTagOpen(b,e,c);!i&&CKEDITOR.dtd.$cdata[b]&&(i=[])}}else if(b=c[2])this.onComment(b)}if(d.length>g)this.onText(d.substring(g,d.length))}}})();CKEDITOR.htmlParser.basicWriter=CKEDITOR.tools.createClass({$:function(){this._={output:[]}},
proto:{openTag:function(a){this._.output.push("<",a)},openTagClose:function(a,f){f?this._.output.push(" />"):this._.output.push(">")},attribute:function(a,f){typeof f=="string"&&(f=CKEDITOR.tools.htmlEncodeAttr(f));this._.output.push(" ",a,'="',f,'"')},closeTag:function(a){this._.output.push("</",a,">")},text:function(a){this._.output.push(a)},comment:function(a){this._.output.push("<\!--",a,"--\>")},write:function(a){this._.output.push(a)},reset:function(){this._.output=[];this._.indent=false},getHtml:function(a){var f=
this._.output.join("");a&&this.reset();return f}}});"use strict";(function(){CKEDITOR.htmlParser.node=function(){};CKEDITOR.htmlParser.node.prototype={remove:function(){var a=this.parent.children,f=CKEDITOR.tools.indexOf(a,this),d=this.previous,c=this.next;d&&(d.next=c);c&&(c.previous=d);a.splice(f,1);this.parent=null},replaceWith:function(a){var f=this.parent.children,d=CKEDITOR.tools.indexOf(f,this),c=a.previous=this.previous,b=a.next=this.next;c&&(c.next=a);b&&(b.previous=a);f[d]=a;a.parent=this.parent;
this.parent=null},insertAfter:function(a){var f=a.parent.children,d=CKEDITOR.tools.indexOf(f,a),c=a.next;f.splice(d+1,0,this);this.next=a.next;this.previous=a;a.next=this;c&&(c.previous=this);this.parent=a.parent},insertBefore:function(a){var f=a.parent.children,d=CKEDITOR.tools.indexOf(f,a);f.splice(d,0,this);this.next=a;(this.previous=a.previous)&&(a.previous.next=this);a.previous=this;this.parent=a.parent},getAscendant:function(a){var f=typeof a=="function"?a:typeof a=="string"?function(c){return c.name==
a}:function(c){return c.name in a},d=this.parent;for(;d&&d.type==CKEDITOR.NODE_ELEMENT;){if(f(d))return d;d=d.parent}return null},wrapWith:function(a){this.replaceWith(a);a.add(this);return a},getIndex:function(){return CKEDITOR.tools.indexOf(this.parent.children,this)},getFilterContext:function(a){return a||{}}}})();"use strict";CKEDITOR.htmlParser.comment=function(a){this.value=a;this._={isBlockLike:false}};CKEDITOR.htmlParser.comment.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,
{type:CKEDITOR.NODE_COMMENT,filter:function(a,f){var d=this.value;if(!(d=a.onComment(f,d,this))){this.remove();return false}if(typeof d!="string"){this.replaceWith(d);return false}this.value=d;return true},writeHtml:function(a,f){f&&this.filter(f);a.comment(this.value)}});"use strict";(function(){CKEDITOR.htmlParser.text=function(a){this.value=a;this._={isBlockLike:false}};CKEDITOR.htmlParser.text.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_TEXT,filter:function(a,
f){if(!(this.value=a.onText(f,this.value,this))){this.remove();return false}},writeHtml:function(a,f){f&&this.filter(f);a.text(this.value)}})})();"use strict";(function(){CKEDITOR.htmlParser.cdata=function(a){this.value=a};CKEDITOR.htmlParser.cdata.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_TEXT,filter:function(){},writeHtml:function(a){a.write(this.value)}})})();"use strict";CKEDITOR.htmlParser.fragment=function(){this.children=[];this.parent=null;this._={isBlockLike:true,
hasInlineStarted:false}};(function(){function a(a){return a.attributes["data-cke-survive"]?false:a.name=="a"&&a.attributes.href||CKEDITOR.dtd.$removeEmpty[a.name]}var f=CKEDITOR.tools.extend({table:1,ul:1,ol:1,dl:1},CKEDITOR.dtd.table,CKEDITOR.dtd.ul,CKEDITOR.dtd.ol,CKEDITOR.dtd.dl),d={ol:1,ul:1},c=CKEDITOR.tools.extend({},{html:1},CKEDITOR.dtd.html,CKEDITOR.dtd.body,CKEDITOR.dtd.head,{style:1,script:1}),b={ul:"li",ol:"li",dl:"dd",table:"tbody",tbody:"tr",thead:"tr",tfoot:"tr",tr:"td"};CKEDITOR.htmlParser.fragment.fromHtml=
function(g,i,e){function h(a){var b;if(r.length>0)for(var c=0;c<r.length;c++){var e=r[c],d=e.name,g=CKEDITOR.dtd[d],h=u.name&&CKEDITOR.dtd[u.name];if((!h||h[d])&&(!a||!g||g[a]||!CKEDITOR.dtd[a])){if(!b){k();b=1}e=e.clone();e.parent=u;u=e;r.splice(c,1);c--}else if(d==u.name){m(u,u.parent,1);c--}}}function k(){for(;s.length;)m(s.shift(),u)}function j(a){if(a._.isBlockLike&&a.name!="pre"&&a.name!="textarea"){var b=a.children.length,c=a.children[b-1],e;if(c&&c.type==CKEDITOR.NODE_TEXT)(e=CKEDITOR.tools.rtrim(c.value))?
c.value=e:a.children.length=b-1}}function m(b,c,d){var c=c||u||p,g=u;if(b.previous===void 0){if(q(c,b)){u=c;o.onTagOpen(e,{});b.returnPoint=c=u}j(b);(!a(b)||b.children.length)&&c.add(b);b.name=="pre"&&(v=false);b.name=="textarea"&&(w=false)}if(b.returnPoint){u=b.returnPoint;delete b.returnPoint}else u=d?c:g}function q(a,b){if((a==p||a.name=="body")&&e&&(!a.name||CKEDITOR.dtd[a.name][e])){var c,d;return(c=b.attributes&&(d=b.attributes["data-cke-real-element-type"])?d:b.name)&&c in CKEDITOR.dtd.$inline&&
!(c in CKEDITOR.dtd.head)&&!b.isOrphan||b.type==CKEDITOR.NODE_TEXT}}function l(a,b){return a in CKEDITOR.dtd.$listItem||a in CKEDITOR.dtd.$tableContent?a==b||a=="dt"&&b=="dd"||a=="dd"&&b=="dt":false}var o=new CKEDITOR.htmlParser,p=i instanceof CKEDITOR.htmlParser.element?i:typeof i=="string"?new CKEDITOR.htmlParser.element(i):new CKEDITOR.htmlParser.fragment,r=[],s=[],u=p,w=p.name=="textarea",v=p.name=="pre";o.onTagOpen=function(b,e,g,i){e=new CKEDITOR.htmlParser.element(b,e);if(e.isUnknown&&g)e.isEmpty=
true;e.isOptionalClose=i;if(a(e))r.push(e);else{if(b=="pre")v=true;else{if(b=="br"&&v){u.add(new CKEDITOR.htmlParser.text("\n"));return}b=="textarea"&&(w=true)}if(b=="br")s.push(e);else{for(;;){i=(g=u.name)?CKEDITOR.dtd[g]||(u._.isBlockLike?CKEDITOR.dtd.div:CKEDITOR.dtd.span):c;if(!e.isUnknown&&!u.isUnknown&&!i[b])if(u.isOptionalClose)o.onTagClose(g);else if(b in d&&g in d){g=u.children;(g=g[g.length-1])&&g.name=="li"||m(g=new CKEDITOR.htmlParser.element("li"),u);!e.returnPoint&&(e.returnPoint=u);
u=g}else if(b in CKEDITOR.dtd.$listItem&&!l(b,g))o.onTagOpen(b=="li"?"ul":"dl",{},0,1);else if(g in f&&!l(b,g)){!e.returnPoint&&(e.returnPoint=u);u=u.parent}else{g in CKEDITOR.dtd.$inline&&r.unshift(u);if(u.parent)m(u,u.parent,1);else{e.isOrphan=1;break}}else break}h(b);k();e.parent=u;e.isEmpty?m(e):u=e}}};o.onTagClose=function(a){for(var b=r.length-1;b>=0;b--)if(a==r[b].name){r.splice(b,1);return}for(var c=[],d=[],g=u;g!=p&&g.name!=a;){g._.isBlockLike||d.unshift(g);c.push(g);g=g.returnPoint||g.parent}if(g!=
p){for(b=0;b<c.length;b++){var h=c[b];m(h,h.parent)}u=g;g._.isBlockLike&&k();m(g,g.parent);if(g==u)u=u.parent;r=r.concat(d)}a=="body"&&(e=false)};o.onText=function(a){if((!u._.hasInlineStarted||s.length)&&!v&&!w){a=CKEDITOR.tools.ltrim(a);if(a.length===0)return}var d=u.name,g=d?CKEDITOR.dtd[d]||(u._.isBlockLike?CKEDITOR.dtd.div:CKEDITOR.dtd.span):c;if(!w&&!g["#"]&&d in f){o.onTagOpen(b[d]||"");o.onText(a)}else{k();h();!v&&!w&&(a=a.replace(/[\t\r\n ]{2,}|[\t\r\n]/g," "));a=new CKEDITOR.htmlParser.text(a);
if(q(u,a))this.onTagOpen(e,{},0,1);u.add(a)}};o.onCDATA=function(a){u.add(new CKEDITOR.htmlParser.cdata(a))};o.onComment=function(a){k();h();u.add(new CKEDITOR.htmlParser.comment(a))};o.parse(g);for(k();u!=p;)m(u,u.parent,1);j(p);return p};CKEDITOR.htmlParser.fragment.prototype={type:CKEDITOR.NODE_DOCUMENT_FRAGMENT,add:function(a,b){isNaN(b)&&(b=this.children.length);var c=b>0?this.children[b-1]:null;if(c){if(a._.isBlockLike&&c.type==CKEDITOR.NODE_TEXT){c.value=CKEDITOR.tools.rtrim(c.value);if(c.value.length===
0){this.children.pop();this.add(a);return}}c.next=a}a.previous=c;a.parent=this;this.children.splice(b,0,a);if(!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,false,b)},filterChildren:function(a,b,c){if(this.childrenFilteredBy!=a.id){c=this.getFilterContext(c);if(b&&!this.parent)a.onRoot(c,this);this.childrenFilteredBy=a.id;for(b=0;b<this.children.length;b++)this.children[b].filter(a,
c)===false&&b--}},writeHtml:function(a,b){b&&this.filter(b);this.writeChildrenHtml(a)},writeChildrenHtml:function(a,b,c){var d=this.getFilterContext();if(c&&!this.parent&&b)b.onRoot(d,this);b&&this.filterChildren(b,false,d);b=0;c=this.children;for(d=c.length;b<d;b++)c[b].writeHtml(a)},forEach:function(a,b,c){if(!c&&(!b||this.type==b))var d=a(this);if(d!==false)for(var c=this.children,f=0;f<c.length;f++){d=c[f];d.type==CKEDITOR.NODE_ELEMENT?d.forEach(a,b):(!b||d.type==b)&&a(d)}},getFilterContext:function(a){return a||
{}}}})();"use strict";(function(){function a(){this.rules=[]}function f(d,c,b,g){var i,e;for(i in c){(e=d[i])||(e=d[i]=new a);e.add(c[i],b,g)}}CKEDITOR.htmlParser.filter=CKEDITOR.tools.createClass({$:function(d){this.id=CKEDITOR.tools.getNextNumber();this.elementNameRules=new a;this.attributeNameRules=new a;this.elementsRules={};this.attributesRules={};this.textRules=new a;this.commentRules=new a;this.rootRules=new a;d&&this.addRules(d,10)},proto:{addRules:function(a,c){var b;if(typeof c=="number")b=
c;else if(c&&"priority"in c)b=c.priority;typeof b!="number"&&(b=10);typeof c!="object"&&(c={});a.elementNames&&this.elementNameRules.addMany(a.elementNames,b,c);a.attributeNames&&this.attributeNameRules.addMany(a.attributeNames,b,c);a.elements&&f(this.elementsRules,a.elements,b,c);a.attributes&&f(this.attributesRules,a.attributes,b,c);a.text&&this.textRules.add(a.text,b,c);a.comment&&this.commentRules.add(a.comment,b,c);a.root&&this.rootRules.add(a.root,b,c)},applyTo:function(a){a.filter(this)},onElementName:function(a,
c){return this.elementNameRules.execOnName(a,c)},onAttributeName:function(a,c){return this.attributeNameRules.execOnName(a,c)},onText:function(a,c,b){return this.textRules.exec(a,c,b)},onComment:function(a,c,b){return this.commentRules.exec(a,c,b)},onRoot:function(a,c){return this.rootRules.exec(a,c)},onElement:function(a,c){for(var b=[this.elementsRules["^"],this.elementsRules[c.name],this.elementsRules.$],g,i=0;i<3;i++)if(g=b[i]){g=g.exec(a,c,this);if(g===false)return null;if(g&&g!=c)return this.onNode(a,
g);if(c.parent&&!c.name)break}return c},onNode:function(a,c){var b=c.type;return b==CKEDITOR.NODE_ELEMENT?this.onElement(a,c):b==CKEDITOR.NODE_TEXT?new CKEDITOR.htmlParser.text(this.onText(a,c.value)):b==CKEDITOR.NODE_COMMENT?new CKEDITOR.htmlParser.comment(this.onComment(a,c.value)):null},onAttribute:function(a,c,b,g){return(b=this.attributesRules[b])?b.exec(a,g,c,this):g}}});CKEDITOR.htmlParser.filterRulesGroup=a;a.prototype={add:function(a,c,b){this.rules.splice(this.findIndex(c),0,{value:a,priority:c,
options:b})},addMany:function(a,c,b){for(var g=[this.findIndex(c),0],i=0,e=a.length;i<e;i++)g.push({value:a[i],priority:c,options:b});this.rules.splice.apply(this.rules,g)},findIndex:function(a){for(var c=this.rules,b=c.length-1;b>=0&&a<c[b].priority;)b--;return b+1},exec:function(a,c){var b=c instanceof CKEDITOR.htmlParser.node||c instanceof CKEDITOR.htmlParser.fragment,g=Array.prototype.slice.call(arguments,1),i=this.rules,e=i.length,h,f,j,m;for(m=0;m<e;m++){if(b){h=c.type;f=c.name}j=i[m];if(!(a.nonEditable&&
!j.options.applyToAll||a.nestedEditable&&j.options.excludeNestedEditable)){j=j.value.apply(null,g);if(j===false||b&&j&&(j.name!=f||j.type!=h))return j;j!=null&&(g[0]=c=j)}}return c},execOnName:function(a,c){for(var b=0,g=this.rules,i=g.length,e;c&&b<i;b++){e=g[b];!(a.nonEditable&&!e.options.applyToAll||a.nestedEditable&&e.options.excludeNestedEditable)&&(c=c.replace(e.value[0],e.value[1]))}return c}}})();(function(){function a(a,e){function h(a){return a||CKEDITOR.env.needsNbspFiller?new CKEDITOR.htmlParser.text(" "):
new CKEDITOR.htmlParser.element("br",{"data-cke-bogus":1})}function f(a,b){return function(e){if(e.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT){var i=[],f=d(e),j,r;if(f)for(k(f,1)&&i.push(f);f;){if(g(f)&&(j=c(f))&&k(j))if((r=c(j))&&!g(r))i.push(j);else{h(A).insertAfter(j);j.remove()}f=f.previous}for(f=0;f<i.length;f++)i[f].remove();if(i=!a||(typeof b=="function"?b(e):b)!==false)if(!A&&!CKEDITOR.env.needsBrFiller&&e.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT)i=false;else if(!A&&!CKEDITOR.env.needsBrFiller&&(document.documentMode>
7||e.name in CKEDITOR.dtd.tr||e.name in CKEDITOR.dtd.$listItem))i=false;else{i=d(e);i=!i||e.name=="form"&&i.name=="input"}i&&e.add(h(a))}}}function k(a,b){if((!A||CKEDITOR.env.needsBrFiller)&&a.type==CKEDITOR.NODE_ELEMENT&&a.name=="br"&&!a.attributes["data-cke-eol"])return true;var c;if(a.type==CKEDITOR.NODE_TEXT&&(c=a.value.match(r))){if(c.index){(new CKEDITOR.htmlParser.text(a.value.substring(0,c.index))).insertBefore(a);a.value=c[0]}if(!CKEDITOR.env.needsBrFiller&&A&&(!b||a.parent.name in D))return true;
if(!A)if((c=a.previous)&&c.name=="br"||!c||g(c))return true}return false}var j={elements:{}},A=e=="html",D=CKEDITOR.tools.extend({},v),t;for(t in D)"#"in u[t]||delete D[t];for(t in D)j.elements[t]=f(A,a.config.fillEmptyBlocks);j.root=f(A,false);j.elements.br=function(a){return function(e){if(e.parent.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT){var d=e.attributes;if("data-cke-bogus"in d||"data-cke-eol"in d)delete d["data-cke-bogus"];else{for(d=e.next;d&&b(d);)d=d.next;var f=c(e);!d&&g(e.parent)?i(e.parent,
h(a)):g(d)&&(f&&!g(f))&&h(a).insertBefore(d)}}}}(A);return j}function f(a,b){return a!=CKEDITOR.ENTER_BR&&b!==false?a==CKEDITOR.ENTER_DIV?"div":"p":false}function d(a){for(a=a.children[a.children.length-1];a&&b(a);)a=a.previous;return a}function c(a){for(a=a.previous;a&&b(a);)a=a.previous;return a}function b(a){return a.type==CKEDITOR.NODE_TEXT&&!CKEDITOR.tools.trim(a.value)||a.type==CKEDITOR.NODE_ELEMENT&&a.attributes["data-cke-bookmark"]}function g(a){return a&&(a.type==CKEDITOR.NODE_ELEMENT&&a.name in
v||a.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT)}function i(a,b){var c=a.children[a.children.length-1];a.children.push(b);b.parent=a;if(c){c.next=b;b.previous=c}}function e(a){a=a.attributes;a.contenteditable!="false"&&(a["data-cke-editable"]=a.contenteditable?"true":1);a.contenteditable="false"}function h(a){a=a.attributes;switch(a["data-cke-editable"]){case "true":a.contenteditable="true";break;case "1":delete a.contenteditable}}function k(a){return a.replace(z,function(a,b,c){return"<"+b+c.replace(B,
function(a,b){return C.test(b)&&c.indexOf("data-cke-saved-"+b)==-1?" data-cke-saved-"+a+" data-cke-"+CKEDITOR.rnd+"-"+a:a})+">"})}function j(a,b){return a.replace(b,function(a,b,c){a.indexOf("<textarea")===0&&(a=b+l(c).replace(/</g,"&lt;").replace(/>/g,"&gt;")+"</textarea>");return"<cke:encoded>"+encodeURIComponent(a)+"</cke:encoded>"})}function m(a){return a.replace(I,function(a,b){return decodeURIComponent(b)})}function q(a){return a.replace(/<\!--(?!{cke_protected})[\s\S]+?--\>/g,function(a){return"<\!--"+
s+"{C}"+encodeURIComponent(a).replace(/--/g,"%2D%2D")+"--\>"})}function l(a){return a.replace(/<\!--\{cke_protected\}\{C\}([\s\S]+?)--\>/g,function(a,b){return decodeURIComponent(b)})}function o(a,b){var c=b._.dataStore;return a.replace(/<\!--\{cke_protected\}([\s\S]+?)--\>/g,function(a,b){return decodeURIComponent(b)}).replace(/\{cke_protected_(\d+)\}/g,function(a,b){return c&&c[b]||""})}function p(a,b){for(var c=[],e=b.config.protectedSource,d=b._.dataStore||(b._.dataStore={id:1}),g=/<\!--\{cke_temp(comment)?\}(\d*?)--\>/g,
e=[/<script[\s\S]*?<\/script>/gi,/<noscript[\s\S]*?<\/noscript>/gi,/<meta[\s\S]*?\/?>/gi].concat(e),a=a.replace(/<\!--[\s\S]*?--\>/g,function(a){return"<\!--{cke_tempcomment}"+(c.push(a)-1)+"--\>"}),h=0;h<e.length;h++)a=a.replace(e[h],function(a){a=a.replace(g,function(a,b,e){return c[e]});return/cke_temp(comment)?/.test(a)?a:"<\!--{cke_temp}"+(c.push(a)-1)+"--\>"});a=a.replace(g,function(a,b,e){return"<\!--"+s+(b?"{C}":"")+encodeURIComponent(c[e]).replace(/--/g,"%2D%2D")+"--\>"});a=a.replace(/<\w+(?:\s+(?:(?:[^\s=>]+\s*=\s*(?:[^'"\s>]+|'[^']*'|"[^"]*"))|[^\s=>]+))+\s*>/g,
function(a){return a.replace(/<\!--\{cke_protected\}([^>]*)--\>/g,function(a,b){d[d.id]=decodeURIComponent(b);return"{cke_protected_"+d.id++ +"}"})});return a=a.replace(/<(title|iframe|textarea)([^>]*)>([\s\S]*?)<\/\1>/g,function(a,c,e,d){return"<"+c+e+">"+o(l(d),b)+"</"+c+">"})}CKEDITOR.htmlDataProcessor=function(b){var c,e,d=this;this.editor=b;this.dataFilter=c=new CKEDITOR.htmlParser.filter;this.htmlFilter=e=new CKEDITOR.htmlParser.filter;this.writer=new CKEDITOR.htmlParser.basicWriter;c.addRules(t);
c.addRules(y,{applyToAll:true});c.addRules(a(b,"data"),{applyToAll:true});e.addRules(n);e.addRules(x,{applyToAll:true});e.addRules(a(b,"html"),{applyToAll:true});b.on("toHtml",function(a){var a=a.data,c=a.dataValue,e,c=p(c,b),c=j(c,F),c=k(c),c=j(c,H),c=c.replace(A,"$1cke:$2"),c=c.replace(E,"<cke:$1$2></cke:$1>"),c=c.replace(/(<pre\b[^>]*>)(\r\n|\n)/g,"$1$2$2"),c=c.replace(/([^a-z0-9<\-])(on\w{3,})(?!>)/gi,"$1data-cke-"+CKEDITOR.rnd+"-$2");e=a.context||b.editable().getName();var d;if(CKEDITOR.env.ie&&
CKEDITOR.env.version<9&&e=="pre"){e="div";c="<pre>"+c+"</pre>";d=1}e=b.document.createElement(e);e.setHtml("a"+c);c=e.getHtml().substr(1);c=c.replace(RegExp("data-cke-"+CKEDITOR.rnd+"-","ig"),"");d&&(c=c.replace(/^<pre>|<\/pre>$/gi,""));c=c.replace(D,"$1$2");c=m(c);c=l(c);e=a.fixForBody===false?false:f(a.enterMode,b.config.autoParagraph);c=CKEDITOR.htmlParser.fragment.fromHtml(c,a.context,e);if(e){d=c;if(!d.children.length&&CKEDITOR.dtd[d.name][e]){e=new CKEDITOR.htmlParser.element(e);d.add(e)}}a.dataValue=
c},null,null,5);b.on("toHtml",function(a){a.data.filter.applyTo(a.data.dataValue,true,a.data.dontFilter,a.data.enterMode)&&b.fire("dataFiltered")},null,null,6);b.on("toHtml",function(a){a.data.dataValue.filterChildren(d.dataFilter,true)},null,null,10);b.on("toHtml",function(a){var a=a.data,b=a.dataValue,c=new CKEDITOR.htmlParser.basicWriter;b.writeChildrenHtml(c);b=c.getHtml(true);a.dataValue=q(b)},null,null,15);b.on("toDataFormat",function(a){var c=a.data.dataValue;a.data.enterMode!=CKEDITOR.ENTER_BR&&
(c=c.replace(/^<br *\/?>/i,""));a.data.dataValue=CKEDITOR.htmlParser.fragment.fromHtml(c,a.data.context,f(a.data.enterMode,b.config.autoParagraph))},null,null,5);b.on("toDataFormat",function(a){a.data.dataValue.filterChildren(d.htmlFilter,true)},null,null,10);b.on("toDataFormat",function(a){a.data.filter.applyTo(a.data.dataValue,false,true)},null,null,11);b.on("toDataFormat",function(a){var c=a.data.dataValue,e=d.writer;e.reset();c.writeChildrenHtml(e);c=e.getHtml(true);c=l(c);c=o(c,b);a.data.dataValue=
c},null,null,15)};CKEDITOR.htmlDataProcessor.prototype={toHtml:function(a,b,c,e){var d=this.editor,g,h,i;if(b&&typeof b=="object"){g=b.context;c=b.fixForBody;e=b.dontFilter;h=b.filter;i=b.enterMode}else g=b;!g&&g!==null&&(g=d.editable().getName());return d.fire("toHtml",{dataValue:a,context:g,fixForBody:c,dontFilter:e,filter:h||d.filter,enterMode:i||d.enterMode}).dataValue},toDataFormat:function(a,b){var c,e,d;if(b){c=b.context;e=b.filter;d=b.enterMode}!c&&c!==null&&(c=this.editor.editable().getName());
return this.editor.fire("toDataFormat",{dataValue:a,filter:e||this.editor.filter,context:c,enterMode:d||this.editor.enterMode}).dataValue}};var r=/(?:&nbsp;|\xa0)$/,s="{cke_protected}",u=CKEDITOR.dtd,w=["caption","colgroup","col","thead","tfoot","tbody"],v=CKEDITOR.tools.extend({},u.$blockLimit,u.$block),t={elements:{input:e,textarea:e}},y={attributeNames:[[/^on/,"data-cke-pa-on"],[/^data-cke-expando$/,""]]},n={elements:{embed:function(a){var b=a.parent;if(b&&b.name=="object"){var c=b.attributes.width,
b=b.attributes.height;if(c)a.attributes.width=c;if(b)a.attributes.height=b}},a:function(a){if(!a.children.length&&!a.attributes.name&&!a.attributes["data-cke-saved-name"])return false}}},x={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 false;for(var c=["name","href","src"],e,d=0;d<c.length;d++){e="data-cke-saved-"+c[d];e in b&&delete b[c[d]]}}return a},
table:function(a){a.children.slice(0).sort(function(a,b){var c,e;if(a.type==CKEDITOR.NODE_ELEMENT&&b.type==a.type){c=CKEDITOR.tools.indexOf(w,a.name);e=CKEDITOR.tools.indexOf(w,b.name)}if(!(c>-1&&e>-1&&c!=e)){c=a.parent?a.getIndex():-1;e=b.parent?b.getIndex():-1}return c>e?1:-1})},param:function(a){a.children=[];a.isEmpty=true;return a},span:function(a){a.attributes["class"]=="Apple-style-span"&&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];if(b&&b.value)b.value=CKEDITOR.tools.trim(b.value);if(!a.attributes.type)a.attributes.type="text/css"},title:function(a){var b=a.children[0];!b&&i(a,b=new CKEDITOR.htmlParser.text);b.value=a.attributes["data-cke-title"]||""},input:h,textarea:h},attributes:{"class":function(a){return CKEDITOR.tools.ltrim(a.replace(/(?:^|\s+)cke_[^\s]*/g,""))||false}}};if(CKEDITOR.env.ie)x.attributes.style=function(a){return a.replace(/(^|;)([^\:]+)/g,
function(a){return a.toLowerCase()})};var z=/<(a|area|img|input|source)\b([^>]*)>/gi,B=/([\w-]+)\s*=\s*(?:(?:"[^"]*")|(?:'[^']*')|(?:[^ "'>]+))/gi,C=/^(href|src|name)$/i,H=/(?:<style(?=[ >])[^>]*>[\s\S]*?<\/style>)|(?:<(:?link|meta|base)[^>]*>)/gi,F=/(<textarea(?=[ >])[^>]*>)([\s\S]*?)(?:<\/textarea>)/gi,I=/<cke:encoded>([^<]*)<\/cke:encoded>/gi,A=/(<\/?)((?:object|embed|param|html|body|head|title)[^>]*>)/gi,D=/(<\/?)cke:((?:html|body|head|title)[^>]*>)/gi,E=/<cke:(param|embed)([^>]*?)\/?>(?!\s*<\/cke:\1)/gi})();
"use strict";CKEDITOR.htmlParser.element=function(a,f){this.name=a;this.attributes=f||{};this.children=[];var d=a||"",c=d.match(/^cke:(.*)/);c&&(d=c[1]);d=!(!CKEDITOR.dtd.$nonBodyContent[d]&&!CKEDITOR.dtd.$block[d]&&!CKEDITOR.dtd.$listItem[d]&&!CKEDITOR.dtd.$tableContent[d]&&!(CKEDITOR.dtd.$nonEditable[d]||d=="br"));this.isEmpty=!!CKEDITOR.dtd.$empty[a];this.isUnknown=!CKEDITOR.dtd[a];this._={isBlockLike:d,hasInlineStarted:this.isEmpty||!d}};CKEDITOR.htmlParser.cssStyle=function(a){var f={};((a instanceof
CKEDITOR.htmlParser.element?a.attributes.style:a)||"").replace(/&quot;/g,'"').replace(/\s*([^ :;]+)\s*:\s*([^;]+)\s*(?=;|$)/g,function(a,c,b){c=="font-family"&&(b=b.replace(/["']/g,""));f[c.toLowerCase()]=b});return{rules:f,populate:function(a){var c=this.toString();if(c)a instanceof CKEDITOR.dom.element?a.setAttribute("style",c):a instanceof CKEDITOR.htmlParser.element?a.attributes.style=c:a.style=c},toString:function(){var a=[],c;for(c in f)f[c]&&a.push(c,":",f[c],";");return a.join("")}}};(function(){function a(a){return function(b){return b.type==
CKEDITOR.NODE_ELEMENT&&(typeof a=="string"?b.name==a:b.name in a)}}var f=function(a,b){a=a[0];b=b[0];return a<b?-1:a>b?1:0},d=CKEDITOR.htmlParser.fragment.prototype;CKEDITOR.htmlParser.element.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_ELEMENT,add:d.add,clone:function(){return new CKEDITOR.htmlParser.element(this.name,this.attributes)},filter:function(a,b){var d=this,i,e,b=d.getFilterContext(b);if(b.off)return true;if(!d.parent)a.onRoot(b,d);for(;;){i=d.name;
if(!(e=a.onElementName(b,i))){this.remove();return false}d.name=e;if(!(d=a.onElement(b,d))){this.remove();return false}if(d!==this){this.replaceWith(d);return false}if(d.name==i)break;if(d.type!=CKEDITOR.NODE_ELEMENT){this.replaceWith(d);return false}if(!d.name){this.replaceWithChildren();return false}}i=d.attributes;var h,f;for(h in i){f=h;for(e=i[h];;)if(f=a.onAttributeName(b,h))if(f!=h){delete i[h];h=f}else break;else{delete i[h];break}f&&((e=a.onAttribute(b,d,f,e))===false?delete i[f]:i[f]=e)}d.isEmpty||
this.filterChildren(a,false,b);return true},filterChildren:d.filterChildren,writeHtml:function(a,b){b&&this.filter(b);var d=this.name,i=[],e=this.attributes,h,k;a.openTag(d,e);for(h in e)i.push([h,e[h]]);a.sortAttributes&&i.sort(f);h=0;for(k=i.length;h<k;h++){e=i[h];a.attribute(e[0],e[1])}a.openTagClose(d,this.isEmpty);this.writeChildrenHtml(a);this.isEmpty||a.closeTag(d)},writeChildrenHtml:d.writeChildrenHtml,replaceWithChildren:function(){for(var a=this.children,b=a.length;b;)a[--b].insertAfter(this);
this.remove()},forEach:d.forEach,getFirst:function(c){if(!c)return this.children.length?this.children[0]:null;typeof c!="function"&&(c=a(c));for(var b=0,d=this.children.length;b<d;++b)if(c(this.children[b]))return this.children[b];return null},getHtml:function(){var a=new CKEDITOR.htmlParser.basicWriter;this.writeChildrenHtml(a);return a.getHtml()},setHtml:function(a){for(var a=this.children=CKEDITOR.htmlParser.fragment.fromHtml(a).children,b=0,d=a.length;b<d;++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),d=this.clone(),f=0;f<b.length;++f)b[f].parent=d;d.children=b;if(b[0])b[0].previous=null;if(a>0)this.children[a-1].next=null;this.parent.add(d,this.getIndex()+1);return d},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"];if(b)(b=
CKEDITOR.tools.trim(b.replace(RegExp("(?:\\s+|^)"+a+"(?:\\s+|$)")," ")))?this.attributes["class"]=b:delete this.attributes["class"]},hasClass:function(a){var b=this.attributes["class"];return!b?false:RegExp("(?:^|\\s)"+a+"(?=\\s|$)").test(b)},getFilterContext:function(a){var b=[];a||(a={off:false,nonEditable:false,nestedEditable:false});!a.off&&this.attributes["data-cke-processor"]=="off"&&b.push("off",true);!a.nonEditable&&this.attributes.contenteditable=="false"?b.push("nonEditable",true):a.nonEditable&&
(!a.nestedEditable&&this.attributes.contenteditable=="true")&&b.push("nestedEditable",true);if(b.length)for(var a=CKEDITOR.tools.copy(a),d=0;d<b.length;d=d+2)a[b[d]]=b[d+1];return a}},true)})();(function(){var a={},f=/{([^}]+)}/g,d=/([\\'])/g,c=/\n/g,b=/\r/g;CKEDITOR.template=function(g){if(a[g])this.output=a[g];else{var i=g.replace(d,"\\$1").replace(c,"\\n").replace(b,"\\r").replace(f,function(a,b){return"',data['"+b+"']==undefined?'{"+b+"}':data['"+b+"'],'"});this.output=a[g]=Function("data","buffer",
"return buffer?buffer.push('"+i+"'):['"+i+"'].join('');")}}})();delete CKEDITOR.loadFullCore;CKEDITOR.instances={};CKEDITOR.document=new CKEDITOR.dom.document(document);CKEDITOR.add=function(a){CKEDITOR.instances[a.name]=a;a.on("focus",function(){if(CKEDITOR.currentInstance!=a){CKEDITOR.currentInstance=a;CKEDITOR.fire("currentInstance")}});a.on("blur",function(){if(CKEDITOR.currentInstance==a){CKEDITOR.currentInstance=null;CKEDITOR.fire("currentInstance")}});CKEDITOR.fire("instance",null,a)};CKEDITOR.remove=
function(a){delete CKEDITOR.instances[a.name]};(function(){var a={};CKEDITOR.addTemplate=function(f,d){var c=a[f];if(c)return c;c={name:f,source:d};CKEDITOR.fire("template",c);return a[f]=new CKEDITOR.template(c.source)};CKEDITOR.getTemplate=function(f){return a[f]}})();(function(){var a=[];CKEDITOR.addCss=function(f){a.push(f)};CKEDITOR.getCss=function(){return a.join("\n")}})();CKEDITOR.on("instanceDestroyed",function(){CKEDITOR.tools.isEmpty(this.instances)&&CKEDITOR.fire("reset")});CKEDITOR.TRISTATE_ON=
1;CKEDITOR.TRISTATE_OFF=2;CKEDITOR.TRISTATE_DISABLED=0;(function(){CKEDITOR.inline=function(a,f){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 d=new CKEDITOR.editor(f,a,CKEDITOR.ELEMENT_MODE_INLINE),c=a.is("textarea")?a:null;if(c){d.setData(c.getValue(),null,true);a=CKEDITOR.dom.element.createFromHtml('<div contenteditable="'+!!d.readOnly+'" class="cke_textarea_inline">'+
c.getValue()+"</div>",CKEDITOR.document);a.insertAfter(c);c.hide();c.$.form&&d._attachToForm()}else d.setData(a.getHtml(),null,true);d.on("loaded",function(){d.fire("uiReady");d.editable(a);d.container=a;d.setData(d.getData(1));d.resetDirty();d.fire("contentDom");d.mode="wysiwyg";d.fire("mode");d.status="ready";d.fireOnce("instanceReady");CKEDITOR.fire("instanceReady",null,d)},null,null,1E4);d.on("destroy",function(){if(c){d.container.clearCustomData();d.container.remove();c.show()}d.element.clearCustomData();
delete d.element});return d};CKEDITOR.inlineAll=function(){var a,f,d;for(d in CKEDITOR.dtd.$editable)for(var c=CKEDITOR.document.getElementsByTag(d),b=0,g=c.count();b<g;b++){a=c.getItem(b);if(a.getAttribute("contenteditable")=="true"){f={element:a,config:{}};CKEDITOR.fire("inline",f)!==false&&CKEDITOR.inline(a,f.config)}}};CKEDITOR.domReady(function(){!CKEDITOR.disableAutoInline&&CKEDITOR.inlineAll()})})();CKEDITOR.replaceClass="ckeditor";(function(){function a(a,b,g,i){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 e=new CKEDITOR.editor(b,a,i);if(i==CKEDITOR.ELEMENT_MODE_REPLACE){a.setStyle("visibility","hidden");e._.required=a.hasAttribute("required");a.removeAttribute("required")}g&&e.setData(g,null,true);e.on("loaded",function(){d(e);i==CKEDITOR.ELEMENT_MODE_REPLACE&&(e.config.autoUpdateElement&&a.$.form)&&e._attachToForm();e.setMode(e.config.startupMode,function(){e.resetDirty();
e.status="ready";e.fireOnce("instanceReady");CKEDITOR.fire("instanceReady",null,e)})});e.on("destroy",f);return e}function f(){var a=this.container,b=this.element;if(a){a.clearCustomData();a.remove()}if(b){b.clearCustomData();if(this.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE){b.show();this._.required&&b.setAttribute("required","required")}delete this.element}}function d(a){var b=a.name,d=a.element,f=a.elementMode,e=a.fire("uiSpace",{space:"top",html:""}).html,h=a.fire("uiSpace",{space:"bottom",html:""}).html,
k=new CKEDITOR.template('<{outerEl} id="cke_{name}" class="{id} cke cke_reset cke_chrome cke_editor_{name} cke_{langDir} '+CKEDITOR.env.cssClass+'"  dir="{langDir}" lang="{langCode}" role="application"'+(a.title?' aria-labelledby="cke_{name}_arialbl"':"")+">"+(a.title?'<span id="cke_{name}_arialbl" class="cke_voice_label">{voiceLabel}</span>':"")+'<{outerEl} class="cke_inner cke_reset" role="presentation">{topHtml}<{outerEl} id="{contentId}" class="cke_contents cke_reset" role="presentation"></{outerEl}>{bottomHtml}</{outerEl}></{outerEl}>'),
b=CKEDITOR.dom.element.createFromHtml(k.output({id:a.id,name:b,langDir:a.lang.dir,langCode:a.langCode,voiceLabel:a.title,topHtml:e?'<span id="'+a.ui.spaceId("top")+'" class="cke_top cke_reset_all" role="presentation" style="height:auto">'+e+"</span>":"",contentId:a.ui.spaceId("contents"),bottomHtml:h?'<span id="'+a.ui.spaceId("bottom")+'" class="cke_bottom cke_reset_all" role="presentation">'+h+"</span>":"",outerEl:CKEDITOR.env.ie?"span":"div"}));if(f==CKEDITOR.ELEMENT_MODE_REPLACE){d.hide();b.insertAfter(d)}else d.append(b);
a.container=b;e&&a.ui.space("top").unselectable();h&&a.ui.space("bottom").unselectable();d=a.config.width;f=a.config.height;d&&b.setStyle("width",CKEDITOR.tools.cssLength(d));f&&a.ui.space("contents").setStyle("height",CKEDITOR.tools.cssLength(f));b.disableContextMenu();CKEDITOR.env.webkit&&b.on("focus",function(){a.focus()});a.fireOnce("uiReady")}CKEDITOR.replace=function(c,b){return a(c,b,null,CKEDITOR.ELEMENT_MODE_REPLACE)};CKEDITOR.appendTo=function(c,b,d){return a(c,b,d,CKEDITOR.ELEMENT_MODE_APPENDTO)};
CKEDITOR.replaceAll=function(){for(var a=document.getElementsByTagName("textarea"),b=0;b<a.length;b++){var d=null,f=a[b];if(f.name||f.id){if(typeof arguments[0]=="string"){if(!RegExp("(?:^|\\s)"+arguments[0]+"(?:$|\\s)").test(f.className))continue}else if(typeof arguments[0]=="function"){d={};if(arguments[0](f,d)===false)continue}this.replace(f,d)}}};CKEDITOR.editor.prototype.addMode=function(a,b){(this._.modes||(this._.modes={}))[a]=b};CKEDITOR.editor.prototype.setMode=function(a,b){var d=this,f=
this._.modes;if(!(a==d.mode||!f||!f[a])){d.fire("beforeSetMode",a);if(d.mode){var e=d.checkDirty(),f=d._.previousModeData,h,k=0;d.fire("beforeModeUnload");d.editable(0);d._.previousMode=d.mode;d._.previousModeData=h=d.getData(1);if(d.mode=="source"&&f==h){d.fire("lockSnapshot",{forceUpdate:true});k=1}d.ui.space("contents").setHtml("");d.mode=""}else d._.previousModeData=d.getData(1);this._.modes[a](function(){d.mode=a;e!==void 0&&!e&&d.resetDirty();k?d.fire("unlockSnapshot"):a=="wysiwyg"&&d.fire("saveSnapshot");
setTimeout(function(){d.fire("mode");b&&b.call(d)},0)})}};CKEDITOR.editor.prototype.resize=function(a,b,d,f){var e=this.container,h=this.ui.space("contents"),k=CKEDITOR.env.webkit&&this.document&&this.document.getWindow().$.frameElement,f=f?this.container.getFirst(function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasClass("cke_inner")}):e;f.setSize("width",a,true);k&&(k.style.width="1%");h.setStyle("height",Math.max(b-(d?0:(f.$.offsetHeight||0)-(h.$.clientHeight||0)),0)+"px");k&&(k.style.width=
"100%");this.fire("resize")};CKEDITOR.editor.prototype.getResizable=function(a){return a?this.ui.space("contents"):this.container};CKEDITOR.domReady(function(){CKEDITOR.replaceClass&&CKEDITOR.replaceAll(CKEDITOR.replaceClass)})})();CKEDITOR.config.startupMode="wysiwyg";(function(){function a(a){var b=a.editor,e=a.data.path,d=e.blockLimit,h=a.data.selection,g=h.getRanges()[0],k;if(CKEDITOR.env.gecko||CKEDITOR.env.ie&&CKEDITOR.env.needsBrFiller)if(h=f(h,e)){h.appendBogus();k=CKEDITOR.env.ie}if(i(b,
e.block,d)&&g.collapsed&&!g.getCommonAncestor().isReadOnly()){e=g.clone();e.enlarge(CKEDITOR.ENLARGE_BLOCK_CONTENTS);d=new CKEDITOR.dom.walker(e);d.guard=function(a){return!c(a)||a.type==CKEDITOR.NODE_COMMENT||a.isReadOnly()};if(!d.checkForward()||e.checkStartOfBlock()&&e.checkEndOfBlock()){b=g.fixBlock(true,b.activeEnterMode==CKEDITOR.ENTER_DIV?"div":"p");if(!CKEDITOR.env.needsBrFiller)(b=b.getFirst(c))&&(b.type==CKEDITOR.NODE_TEXT&&CKEDITOR.tools.trim(b.getText()).match(/^(?:&nbsp;|\xa0)$/))&&b.remove();
k=1;a.cancel()}}k&&g.select()}function f(a,b){if(a.isFake)return 0;var e=b.block||b.blockLimit,d=e&&e.getLast(c);if(e&&e.isBlockBoundary()&&(!d||!(d.type==CKEDITOR.NODE_ELEMENT&&d.isBlockBoundary()))&&!e.is("pre")&&!e.getBogus())return e}function d(a){var b=a.data.getTarget();if(b.is("input")){b=b.getAttribute("type");(b=="submit"||b=="reset")&&a.data.preventDefault()}}function c(a){return q(a)&&l(a)}function b(a,b){return function(c){var e=CKEDITOR.dom.element.get(c.data.$.toElement||c.data.$.fromElement||
c.data.$.relatedTarget);(!e||!b.equals(e)&&!b.contains(e))&&a.call(this,c)}}function g(a){function b(a){return function(b,d){d&&(b.type==CKEDITOR.NODE_ELEMENT&&b.is(h))&&(e=b);if(!d&&c(b)&&(!a||!j(b)))return false}}var e,d=a.getRanges()[0],a=a.root,h={table:1,ul:1,ol:1,dl:1};if(d.startPath().contains(h)){var g=d.clone();g.collapse(1);g.setStartAt(a,CKEDITOR.POSITION_AFTER_START);a=new CKEDITOR.dom.walker(g);a.guard=b();a.checkBackward();if(e){g=d.clone();g.collapse();g.setEndAt(e,CKEDITOR.POSITION_AFTER_END);
a=new CKEDITOR.dom.walker(g);a.guard=b(true);e=false;a.checkForward();return e}}return null}function i(a,b,c){return a.config.autoParagraph!==false&&a.activeEnterMode!=CKEDITOR.ENTER_BR&&a.editable().equals(c)&&!b||b&&b.getAttribute("contenteditable")=="true"}function e(a){a.editor.focus();a.editor.fire("saveSnapshot")}function h(a){var b=a.editor;b.getSelection().scrollIntoView();setTimeout(function(){b.fire("saveSnapshot")},0)}function k(a,b,c){for(var e=a.getCommonAncestor(b),b=a=c?b:a;(a=a.getParent())&&
!e.equals(a)&&a.getChildCount()==1;)b=a;b.remove()}CKEDITOR.editable=CKEDITOR.tools.createClass({base:CKEDITOR.dom.element,$:function(a,b){this.base(b.$||b);this.editor=a;this.status="unloaded";this.hasFocus=false;this.setup()},proto:{focus:function(){var a;if(CKEDITOR.env.webkit&&!this.hasFocus){a=this.editor._.previousActive||this.getDocument().getActive();if(this.contains(a)){a.focus();return}}try{this.$[CKEDITOR.env.ie&&this.getDocument().equals(CKEDITOR.document)?"setActive":"focus"]()}catch(b){if(!CKEDITOR.env.ie)throw b;
}if(CKEDITOR.env.safari&&!this.isInline()){a=CKEDITOR.document.getActive();a.equals(this.getWindow().getFrame())||this.getWindow().focus()}},on:function(a,c){var e=Array.prototype.slice.call(arguments,0);if(CKEDITOR.env.ie&&/^focus|blur$/.exec(a)){a=a=="focus"?"focusin":"focusout";c=b(c,this);e[0]=a;e[1]=c}return CKEDITOR.dom.element.prototype.on.apply(this,e)},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)if(a.hasOwnProperty(c)){b=a[c];b!==null?this.setAttribute(c,b):this.removeAttribute(c)}},attachClass:function(a){var b=this.getCustomData("classes");if(!this.hasClass(a)){!b&&(b=[]);b.push(a);this.setCustomData("classes",b);this.addClass(a)}},changeAttr:function(a,b){var c=this.getAttribute(a);if(b!==c){!this._.attrChanges&&
(this._.attrChanges={});a in this._.attrChanges||(this._.attrChanges[a]=c);this.setAttribute(a,b)}},insertHtml:function(a,b){e(this);o(this,b||"html",a)},insertText:function(a){e(this);var b=this.editor,c=b.getSelection().getStartElement().hasAscendant("pre",true)?CKEDITOR.ENTER_BR:b.activeEnterMode,b=c==CKEDITOR.ENTER_BR,d=CKEDITOR.tools,a=d.htmlEncode(a.replace(/\r\n/g,"\n")),a=a.replace(/\t/g,"&nbsp;&nbsp; &nbsp;"),c=c==CKEDITOR.ENTER_P?"p":"div";if(!b){var g=/\n{2}/g;if(g.test(a))var h="<"+c+
">",f="</"+c+">",a=h+a.replace(g,function(){return f+h})+f}a=a.replace(/\n/g,"<br>");b||(a=a.replace(RegExp("<br>(?=</"+c+">)"),function(a){return d.repeat(a,2)}));a=a.replace(/^ | $/g,"&nbsp;");a=a.replace(/(>|\s) /g,function(a,b){return b+"&nbsp;"}).replace(/ (?=<)/g,"&nbsp;");o(this,"text",a)},insertElement:function(a,b){b?this.insertElementIntoRange(a,b):this.insertElementIntoSelection(a)},insertElementIntoRange:function(a,b){var c=this.editor,e=c.config.enterMode,d=a.getName(),g=CKEDITOR.dtd.$block[d];
if(b.checkReadOnly())return false;b.deleteContents(1);b.startContainer.type==CKEDITOR.NODE_ELEMENT&&b.startContainer.is({tr:1,table:1,tbody:1,thead:1,tfoot:1})&&p(b);var h,f;if(g)for(;(h=b.getCommonAncestor(0,1))&&(f=CKEDITOR.dtd[h.getName()])&&(!f||!f[d]);)if(h.getName()in CKEDITOR.dtd.span)b.splitElement(h);else if(b.checkStartOfBlock()&&b.checkEndOfBlock()){b.setStartBefore(h);b.collapse(true);h.remove()}else b.splitBlock(e==CKEDITOR.ENTER_DIV?"div":"p",c.editable());b.insertNode(a);return true},
insertElementIntoSelection:function(a){e(this);var b=this.editor,d=b.activeEnterMode,b=b.getSelection(),g=b.getRanges()[0],f=a.getName(),f=CKEDITOR.dtd.$block[f];if(this.insertElementIntoRange(a,g)){g.moveToPosition(a,CKEDITOR.POSITION_AFTER_END);if(f)if((f=a.getNext(function(a){return c(a)&&!j(a)}))&&f.type==CKEDITOR.NODE_ELEMENT&&f.is(CKEDITOR.dtd.$block))f.getDtd()["#"]?g.moveToElementEditStart(f):g.moveToElementEditEnd(a);else if(!f&&d!=CKEDITOR.ENTER_BR){f=g.fixBlock(true,d==CKEDITOR.ENTER_DIV?
"div":"p");g.moveToElementEditStart(f)}}b.selectRanges([g]);h(this)},setData:function(a,b){b||(a=this.editor.dataProcessor.toHtml(a));this.setHtml(a);this.fixInitialSelection();if(this.status=="unloaded")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().$,e=b.getSelection(),d;if(e.anchorNode&&e.anchorNode==c.$)d=true;else if(CKEDITOR.env.webkit){var g=c.getDocument().getActive();g&&(g.equals(c)&&!e.anchorNode)&&(d=true)}if(d){d=new CKEDITOR.dom.range(c);d.moveToElementEditStart(c);b=b.createRange();b.setStart(d.startContainer.$,d.startOffset);b.collapse(true);
e.removeAllRanges();e.addRange(b)}}function b(){var a=c.getDocument().$,e=a.selection,d=c.getDocument().getActive();if(e.type=="None"&&d.equals(c)){e=new CKEDITOR.dom.range(c);a=a.body.createTextRange();e.moveToElementEditStart(c);e=e.startContainer;e.type!=CKEDITOR.NODE_ELEMENT&&(e=e.getParent());a.moveToElementText(e.$);a.collapse(true);a.select()}}var c=this;if(CKEDITOR.env.ie&&(CKEDITOR.env.version<9||CKEDITOR.env.quirks)){if(this.hasFocus){this.focus();b()}}else if(this.hasFocus){this.focus();
a()}else this.once("focus",function(){a()},null,null,-999)},setup:function(){var a=this.editor;this.attachListener(a,"beforeGetData",function(){var b=this.getData();this.is("textarea")||a.config.ignoreEmptyParagraph!==false&&(b=b.replace(m,function(a,b){return b}));a.setData(b,null,1)},this);this.attachListener(a,"getSnapshot",function(a){a.data=this.getData(1)},this);this.attachListener(a,"afterSetData",function(){this.setData(a.getData(1))},this);this.attachListener(a,"loadSnapshot",function(a){this.setData(a.data,
1)},this);this.attachListener(a,"beforeFocus",function(){var b=a.getSelection();(b=b&&b.getNative())&&b.type=="Control"||this.focus()},this);this.attachListener(a,"insertHtml",function(a){this.insertHtml(a.data.dataValue,a.data.mode)},this);this.attachListener(a,"insertElement",function(a){this.insertElement(a.data)},this);this.attachListener(a,"insertText",function(a){this.insertText(a.data)},this);this.setReadOnly(a.readOnly);this.attachClass("cke_editable");this.attachClass(a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?
"cke_editable_inline":a.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE||a.elementMode==CKEDITOR.ELEMENT_MODE_APPENDTO?"cke_editable_themed":"");this.attachClass("cke_contents_"+a.config.contentsLangDirection);a.keystrokeHandler.blockedKeystrokes[8]=+a.readOnly;a.keystrokeHandler.attach(this);this.on("blur",function(){this.hasFocus=false},null,null,-1);this.on("focus",function(){this.hasFocus=true},null,null,-1);a.focusManager.add(this);if(this.equals(CKEDITOR.document.getActive())){this.hasFocus=true;
a.once("contentDom",function(){a.focusManager.focus(this)},this)}this.isInline()&&this.changeAttr("tabindex",a.tabIndex);if(!this.is("textarea")){a.document=this.getDocument();a.window=this.getWindow();var b=a.document;this.changeAttr("spellcheck",!a.config.disableNativeSpellChecker);var e=a.config.contentsLangDirection;this.getDirection(1)!=e&&this.changeAttr("dir",e);var h=CKEDITOR.getCss();if(h){e=b.getHead();if(!e.getCustomData("stylesheet")){h=b.appendStyleText(h);h=new CKEDITOR.dom.element(h.ownerNode||
h.owningElement);e.setCustomData("stylesheet",h);h.data("cke-temp",1)}}e=b.getCustomData("stylesheet_ref")||0;b.setCustomData("stylesheet_ref",e+1);this.setCustomData("cke_includeReadonly",!a.config.disableReadonlyStyling);this.attachListener(this,"click",function(a){var a=a.data,b=(new CKEDITOR.dom.elementPath(a.getTarget(),this)).contains("a");b&&(a.$.button!=2&&b.isReadOnly())&&a.preventDefault()});var f={8:1,46:1};this.attachListener(a,"key",function(b){if(a.readOnly)return true;var c=b.data.domEvent.getKey(),
e;if(c in f){var b=a.getSelection(),d,h=b.getRanges()[0],i=h.startPath(),k,j,m,c=c==8;if(CKEDITOR.env.ie&&CKEDITOR.env.version<11&&(d=b.getSelectedElement())||(d=g(b))){a.fire("saveSnapshot");h.moveToPosition(d,CKEDITOR.POSITION_BEFORE_START);d.remove();h.select();a.fire("saveSnapshot");e=1}else if(h.collapsed)if((k=i.block)&&(m=k[c?"getPrevious":"getNext"](q))&&m.type==CKEDITOR.NODE_ELEMENT&&m.is("table")&&h[c?"checkStartOfBlock":"checkEndOfBlock"]()){a.fire("saveSnapshot");h[c?"checkEndOfBlock":
"checkStartOfBlock"]()&&k.remove();h["moveToElementEdit"+(c?"End":"Start")](m);h.select();a.fire("saveSnapshot");e=1}else if(i.blockLimit&&i.blockLimit.is("td")&&(j=i.blockLimit.getAscendant("table"))&&h.checkBoundaryOfElement(j,c?CKEDITOR.START:CKEDITOR.END)&&(m=j[c?"getPrevious":"getNext"](q))){a.fire("saveSnapshot");h["moveToElementEdit"+(c?"End":"Start")](m);h.checkStartOfBlock()&&h.checkEndOfBlock()?m.remove():h.select();a.fire("saveSnapshot");e=1}else if((j=i.contains(["td","th","caption"]))&&
h.checkBoundaryOfElement(j,c?CKEDITOR.START:CKEDITOR.END))e=1}return!e});a.blockless&&(CKEDITOR.env.ie&&CKEDITOR.env.needsBrFiller)&&this.attachListener(this,"keyup",function(b){if(b.data.getKeystroke()in f&&!this.getFirst(c)){this.appendBogus();b=a.createRange();b.moveToPosition(this,CKEDITOR.POSITION_AFTER_START);b.select()}});this.attachListener(this,"dblclick",function(b){if(a.readOnly)return false;b={element:b.data.getTarget()};a.fire("doubleclick",b)});CKEDITOR.env.ie&&this.attachListener(this,
"click",d);CKEDITOR.env.ie||this.attachListener(this,"mousedown",function(b){var c=b.data.getTarget();if(c.is("img","hr","input","textarea","select")&&!c.isReadOnly()){a.getSelection().selectElement(c);c.is("input","textarea","select")&&b.data.preventDefault()}});CKEDITOR.env.gecko&&this.attachListener(this,"mouseup",function(b){if(b.data.$.button==2){b=b.data.getTarget();if(!b.getOuterHtml().replace(m,"")){var c=a.createRange();c.moveToElementEditStart(b);c.select(true)}}});if(CKEDITOR.env.webkit){this.attachListener(this,
"click",function(a){a.data.getTarget().is("input","select")&&a.data.preventDefault()});this.attachListener(this,"mouseup",function(a){a.data.getTarget().is("input","textarea")&&a.data.preventDefault()})}CKEDITOR.env.webkit&&this.attachListener(a,"key",function(b){b=b.data.domEvent.getKey();if(b in f){var c=b==8,e=a.getSelection().getRanges()[0],b=e.startPath();if(e.collapsed){var d;a:{var h=b.block;if(h)if(e[c?"checkStartOfBlock":"checkEndOfBlock"]())if(!e.moveToClosestEditablePosition(h,!c)||!e.collapsed)d=
false;else{if(e.startContainer.type==CKEDITOR.NODE_ELEMENT){var g=e.startContainer.getChild(e.startOffset-(c?1:0));if(g&&g.type==CKEDITOR.NODE_ELEMENT&&g.is("hr")){a.fire("saveSnapshot");g.remove();d=true;break a}}if((e=e.startPath().block)&&(!e||!e.contains(h))){a.fire("saveSnapshot");var i;(i=(c?e:h).getBogus())&&i.remove();d=a.getSelection();i=d.createBookmarks();(c?h:e).moveChildren(c?e:h,false);b.lastElement.mergeSiblings();k(h,e,!c);d.selectBookmarks(i);d=true}}else d=false;else d=false}if(!d)return}else{c=
e;d=b.block;i=c.endPath().block;if(!d||!i||d.equals(i))b=false;else{a.fire("saveSnapshot");(h=d.getBogus())&&h.remove();c.deleteContents();if(i.getParent()){i.moveChildren(d,false);b.lastElement.mergeSiblings();k(d,i,true)}c=a.getSelection().getRanges()[0];c.collapse(1);c.select();b=true}if(!b)return}a.getSelection().scrollIntoView();a.fire("saveSnapshot");return false}},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");if(--c)a.setCustomData("stylesheet_ref",c);else{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;if(arguments.length)b=
this._.editable=a?a instanceof CKEDITOR.editable?a:new CKEDITOR.editable(this,a):(b&&b.detach(),null);return b};var j=CKEDITOR.dom.walker.bogus(),m=/(^|<body\b[^>]*>)\s*<(p|div|address|h\d|center|pre)[^>]*>\s*(?:<br[^>]*>|&nbsp;|\u00A0|&#160;)?\s*(:?<\/\2>)?\s*(?=$|<\/body>)/gi,q=CKEDITOR.dom.walker.whitespaces(true),l=CKEDITOR.dom.walker.bookmark(false,true);CKEDITOR.on("instanceLoaded",function(b){var c=b.editor;c.on("insertElement",function(a){a=a.data;if(a.type==CKEDITOR.NODE_ELEMENT&&(a.is("input")||
a.is("textarea"))){a.getAttribute("contentEditable")!="false"&&a.data("cke-editable",a.hasAttribute("contenteditable")?"true":"1");a.setAttribute("contentEditable",false)}});c.on("selectionChange",function(b){if(!c.readOnly){var e=c.getSelection();if(e&&!e.isLocked){e=c.checkDirty();c.fire("lockSnapshot");a(b);c.fire("unlockSnapshot");!e&&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 e=b.fire("ariaEditorHelpLabel",{}).label;if(e)if(c=this.ui.space(this.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?"top":"contents")){var d=CKEDITOR.tools.getNextId(),e=CKEDITOR.dom.element.createFromHtml('<span id="'+d+'" class="cke_voice_label">'+e+"</span>");c.append(e);a.changeAttr("aria-describedby",d)}}})});CKEDITOR.addCss(".cke_editable{cursor:text}.cke_editable img,.cke_editable input,.cke_editable textarea{cursor:default}");
var o=function(){function a(b){return b.type==CKEDITOR.NODE_ELEMENT}function b(c,e){var d,h,g,f,i=[],j=e.range.startContainer;d=e.range.startPath();for(var j=k[j.getName()],m=0,o=c.getChildren(),v=o.count(),n=-1,t=-1,z=0,q=d.contains(k.$list);m<v;++m){d=o.getItem(m);if(a(d)){g=d.getName();if(q&&g in CKEDITOR.dtd.$list)i=i.concat(b(d,e));else{f=!!j[g];if(g=="br"&&d.data("cke-eol")&&(!m||m==v-1)){z=(h=m?i[m-1].node:o.getItem(m+1))&&(!a(h)||!h.is("br"));h=h&&a(h)&&k.$block[h.getName()]}n==-1&&!f&&(n=
m);f||(t=m);i.push({isElement:1,isLineBreak:z,isBlock:d.isBlockBoundary(),hasBlockSibling:h,node:d,name:g,allowed:f});h=z=0}}else i.push({isElement:0,node:d,allowed:1})}if(n>-1)i[n].firstNotAllowed=1;if(t>-1)i[t].lastNotAllowed=1;return i}function e(b,c){var d=[],h=b.getChildren(),g=h.count(),f,i=0,j=k[c],m=!b.is(k.$inline)||b.is("br");for(m&&d.push(" ");i<g;i++){f=h.getItem(i);a(f)&&!f.is(j)?d=d.concat(e(f,c)):d.push(f)}m&&d.push(" ");return d}function d(b){return b&&a(b)&&(b.is(k.$removeEmpty)||
b.is("a")&&!b.isBlockBoundary())}function g(b,c,e,d){var h=b.clone(),f,i;h.setEndAt(c,CKEDITOR.POSITION_BEFORE_END);if((f=(new CKEDITOR.dom.walker(h)).next())&&a(f)&&j[f.getName()]&&(i=f.getPrevious())&&a(i)&&!i.getParent().equals(b.startContainer)&&e.contains(i)&&d.contains(f)&&f.isIdentical(i)){f.moveChildren(i);f.remove();g(b,c,e,d)}}function f(b,c){function e(b,c){if(c.isBlock&&c.isElement&&!c.node.is("br")&&a(b)&&b.is("br")){b.remove();return 1}}var d=c.endContainer.getChild(c.endOffset),h=c.endContainer.getChild(c.endOffset-
1);d&&e(d,b[b.length-1]);if(h&&e(h,b[0])){c.setEnd(c.endContainer,c.endOffset-1);c.collapse()}}var k=CKEDITOR.dtd,j={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},m={p:1,div:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1},o=CKEDITOR.tools.extend({},k.$inline);delete o.br;return function(j,n,q){var l=j.editor,I=l.getSelection().getRanges()[0],A=false;if(n=="unfiltered_html"){n="html";A=true}if(!I.checkReadOnly()){var D=(new CKEDITOR.dom.elementPath(I.startContainer,I.root)).blockLimit||
I.root,n={type:n,dontFilter:A,editable:j,editor:l,range:I,blockLimit:D,mergeCandidates:[],zombies:[]},l=n.range,A=n.mergeCandidates,E,G,K,p;if(n.type=="text"&&l.shrink(CKEDITOR.SHRINK_ELEMENT,true,false)){E=CKEDITOR.dom.element.createFromHtml("<span>&nbsp;</span>",l.document);l.insertNode(E);l.setStartAfter(E)}G=new CKEDITOR.dom.elementPath(l.startContainer);n.endPath=K=new CKEDITOR.dom.elementPath(l.endContainer);if(!l.collapsed){var D=K.block||K.blockLimit,Q=l.getCommonAncestor();D&&(!D.equals(Q)&&
!D.contains(Q)&&l.checkEndOfBlock())&&n.zombies.push(D);l.deleteContents()}for(;(p=a(l.startContainer)&&l.startContainer.getChild(l.startOffset-1))&&a(p)&&p.isBlockBoundary()&&G.contains(p);)l.moveToPosition(p,CKEDITOR.POSITION_BEFORE_END);g(l,n.blockLimit,G,K);if(E){l.setEndBefore(E);l.collapse();E.remove()}E=l.startPath();if(D=E.contains(d,false,1)){l.splitElement(D);n.inlineStylesRoot=D;n.inlineStylesPeak=E.lastElement}E=l.createBookmark();(D=E.startNode.getPrevious(c))&&a(D)&&d(D)&&A.push(D);
(D=E.startNode.getNext(c))&&a(D)&&d(D)&&A.push(D);for(D=E.startNode;(D=D.getParent())&&d(D);)A.push(D);l.moveToBookmark(E);if(E=q){E=n.range;if(n.type=="text"&&n.inlineStylesRoot){p=n.inlineStylesPeak;l=p.getDocument().createText("{cke-peak}");for(A=n.inlineStylesRoot.getParent();!p.equals(A);){l=l.appendTo(p.clone());p=p.getParent()}q=l.getOuterHtml().split("{cke-peak}").join(q)}p=n.blockLimit.getName();if(/^\s+|\s+$/.test(q)&&"span"in CKEDITOR.dtd[p])var O='<span data-cke-marker="1">&nbsp;</span>',
q=O+q+O;q=n.editor.dataProcessor.toHtml(q,{context:null,fixForBody:false,dontFilter:n.dontFilter,filter:n.editor.activeFilter,enterMode:n.editor.activeEnterMode});p=E.document.createElement("body");p.setHtml(q);if(O){p.getFirst().remove();p.getLast().remove()}if((O=E.startPath().block)&&!(O.getChildCount()==1&&O.getBogus()))a:{var L;if(p.getChildCount()==1&&a(L=p.getFirst())&&L.is(m)){O=L.getElementsByTag("*");E=0;for(A=O.count();E<A;E++){l=O.getItem(E);if(!l.is(o))break a}L.moveChildren(L.getParent(1));
L.remove()}}n.dataWrapper=p;E=q}if(E){L=n.range;var O=L.document,J,q=n.blockLimit;E=0;var R;p=[];var M,T,A=l=0,P,V;G=L.startContainer;var D=n.endPath.elements[0],W;K=D.getPosition(G);Q=!!D.getCommonAncestor(G)&&K!=CKEDITOR.POSITION_IDENTICAL&&!(K&CKEDITOR.POSITION_CONTAINS+CKEDITOR.POSITION_IS_CONTAINED);G=b(n.dataWrapper,n);for(f(G,L);E<G.length;E++){K=G[E];if(J=K.isLineBreak){J=L;P=q;var S=void 0,Y=void 0;if(K.hasBlockSibling)J=1;else{S=J.startContainer.getAscendant(k.$block,1);if(!S||!S.is({div:1,
p:1}))J=0;else{Y=S.getPosition(P);if(Y==CKEDITOR.POSITION_IDENTICAL||Y==CKEDITOR.POSITION_CONTAINS)J=0;else{P=J.splitElement(S);J.moveToPosition(P,CKEDITOR.POSITION_AFTER_START);J=1}}}}if(J)A=E>0;else{J=L.startPath();if(!K.isBlock&&i(n.editor,J.block,J.blockLimit)&&(T=n.editor.activeEnterMode!=CKEDITOR.ENTER_BR&&n.editor.config.autoParagraph!==false?n.editor.activeEnterMode==CKEDITOR.ENTER_DIV?"div":"p":false)){T=O.createElement(T);T.appendBogus();L.insertNode(T);CKEDITOR.env.needsBrFiller&&(R=T.getBogus())&&
R.remove();L.moveToPosition(T,CKEDITOR.POSITION_BEFORE_END)}if((J=L.startPath().block)&&!J.equals(M)){if(R=J.getBogus()){R.remove();p.push(J)}M=J}K.firstNotAllowed&&(l=1);if(l&&K.isElement){J=L.startContainer;for(P=null;J&&!k[J.getName()][K.name];){if(J.equals(q)){J=null;break}P=J;J=J.getParent()}if(J){if(P){V=L.splitElement(P);n.zombies.push(V);n.zombies.push(P)}}else{P=q.getName();W=!E;J=E==G.length-1;P=e(K.node,P);for(var S=[],Y=P.length,Z=0,ba=void 0,X=0,aa=-1;Z<Y;Z++){ba=P[Z];if(ba==" "){if(!X&&
(!W||Z)){S.push(new CKEDITOR.dom.text(" "));aa=S.length}X=1}else{S.push(ba);X=0}}J&&aa==S.length&&S.pop();W=S}}if(W){for(;J=W.pop();)L.insertNode(J);W=0}else L.insertNode(K.node);if(K.lastNotAllowed&&E<G.length-1){(V=Q?D:V)&&L.setEndAt(V,CKEDITOR.POSITION_AFTER_START);l=0}L.collapse()}}n.dontMoveCaret=A;n.bogusNeededBlocks=p}R=n.range;var U;V=n.bogusNeededBlocks;for(W=R.createBookmark();M=n.zombies.pop();)if(M.getParent()){T=R.clone();T.moveToElementEditStart(M);T.removeEmptyBlocksAtEnd()}if(V)for(;M=
V.pop();)CKEDITOR.env.needsBrFiller?M.appendBogus():M.append(R.document.createText(" "));for(;M=n.mergeCandidates.pop();)M.mergeSiblings();R.moveToBookmark(W);if(!n.dontMoveCaret){for(M=a(R.startContainer)&&R.startContainer.getChild(R.startOffset-1);M&&a(M)&&!M.is(k.$empty);){if(M.isBlockBoundary())R.moveToPosition(M,CKEDITOR.POSITION_BEFORE_END);else{if(d(M)&&M.getHtml().match(/(\s|&nbsp;)$/g)){U=null;break}U=R.clone();U.moveToPosition(M,CKEDITOR.POSITION_BEFORE_END)}M=M.getLast(c)}U&&R.moveToRange(U)}I.select();
h(j)}}}(),p=function(){function a(b){b=new CKEDITOR.dom.walker(b);b.guard=function(a,b){if(b)return false;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,e){c=a.getDocument().createElement(c);a.append(c,e);return c}function c(a){var b=a.count(),e;for(b;b-- >0;){e=a.getItem(b);if(!CKEDITOR.tools.trim(e.getHtml())){e.appendBogus();CKEDITOR.env.ie&&(CKEDITOR.env.version<9&&e.getChildCount())&&
e.getFirst().remove()}}}return function(e){var d=e.startContainer,h=d.getAscendant("table",1),g=false;c(h.getElementsByTag("td"));c(h.getElementsByTag("th"));h=e.clone();h.setStart(d,0);h=a(h).lastBackward();if(!h){h=e.clone();h.setEndAt(d,CKEDITOR.POSITION_BEFORE_END);h=a(h).lastForward();g=true}h||(h=d);if(h.is("table")){e.setStartAt(h,CKEDITOR.POSITION_BEFORE_START);e.collapse(true);h.remove()}else{h.is({tbody:1,thead:1,tfoot:1})&&(h=b(h,"tr",g));h.is("tr")&&(h=b(h,h.getParent().is("thead")?"th":
"td",g));(d=h.getBogus())&&d.remove();e.moveToPosition(h,g?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_END)}}}()})();(function(){function a(){var a=this._.fakeSelection,b;if(a){b=this.getSelection(1);if(!b||!b.isHidden()){a.reset();a=0}}if(!a){a=b||this.getSelection(1);if(!a||a.getType()==CKEDITOR.SELECTION_NONE)return}this.fire("selectionCheck",a);b=this.elementPath();if(!b.compare(this._.selectionPreviousPath)){if(CKEDITOR.env.webkit)this._.previousActive=this.document.getActive();this._.selectionPreviousPath=
b;this.fire("selectionChange",{selection:a,path:b})}}function f(){o=true;if(!l){d.call(this);l=CKEDITOR.tools.setTimeout(d,200,this)}}function d(){l=null;if(o){CKEDITOR.tools.setTimeout(a,0,this);o=false}}function c(a){return p(a)||a.type==CKEDITOR.NODE_ELEMENT&&!a.is(CKEDITOR.dtd.$empty)?true:false}function b(a){function b(c,e){return!c||c.type==CKEDITOR.NODE_TEXT?false:a.clone()["moveToElementEdit"+(e?"End":"Start")](c)}if(!(a.root instanceof CKEDITOR.editable))return false;var e=a.startContainer,
d=a.getPreviousNode(c,null,e),h=a.getNextNode(c,null,e);return b(d)||b(h,1)||!d&&!h&&!(e.type==CKEDITOR.NODE_ELEMENT&&e.isBlockBoundary()&&e.getBogus())?true:false}function g(a){return a.getCustomData("cke-fillingChar")}function i(a,b){var c=a&&a.removeCustomData("cke-fillingChar");if(c){if(b!==false){var d,g=a.getDocument().getSelection().getNative(),f=g&&g.type!="None"&&g.getRangeAt(0);if(c.getLength()>1&&f&&f.intersectsNode(c.$)){d=h(g);f=g.focusNode==c.$&&g.focusOffset>0;g.anchorNode==c.$&&g.anchorOffset>
0&&d[0].offset--;f&&d[1].offset--}}c.setText(e(c.getText()));d&&k(a.getDocument().$,d)}}function e(a){return a.replace(/\u200B( )?/g,function(a){return a[1]?" ":""})}function h(a){return[{node:a.anchorNode,offset:a.anchorOffset},{node:a.focusNode,offset:a.focusOffset}]}function k(a,b){var c=a.getSelection(),e=a.createRange();e.setStart(b[0].node,b[0].offset);e.collapse(true);c.removeAllRanges();c.addRange(e);c.extend(b[1].node,b[1].offset)}function j(a){var b=CKEDITOR.dom.element.createFromHtml('<div data-cke-hidden-sel="1" data-cke-temp="1" style="'+
(CKEDITOR.env.ie?"display:none":"position:fixed;top:0;left:-1000px")+'">&nbsp;</div>',a.document);a.fire("lockSnapshot");a.editable().append(b);var c=a.getSelection(1),e=a.createRange(),d=c.root.on("selectionchange",function(a){a.cancel()},null,null,0);e.setStartAt(b,CKEDITOR.POSITION_AFTER_START);e.setEndAt(b,CKEDITOR.POSITION_BEFORE_END);c.selectRanges([e]);d.removeListener();a.fire("unlockSnapshot");a._.hiddenSelectionContainer=b}function m(a){var b={37:1,39:1,8:1,46:1};return function(c){var e=
c.data.getKeystroke();if(b[e]){var d=a.getSelection().getRanges(),h=d[0];if(d.length==1&&h.collapsed)if((e=h[e<38?"getPreviousEditableNode":"getNextEditableNode"]())&&e.type==CKEDITOR.NODE_ELEMENT&&e.getAttribute("contenteditable")=="false"){a.getSelection().fake(e);c.data.preventDefault();c.cancel()}}}}function q(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 e=c.startContainer,d;e;){if((d=e.type==
CKEDITOR.NODE_ELEMENT)&&e.is("body")||!e.isReadOnly())break;d&&e.getAttribute("contentEditable")=="false"&&c.setStartAfter(e);e=e.getParent()}e=c.startContainer;d=c.endContainer;var h=c.startOffset,g=c.endOffset,f=c.clone();e&&e.type==CKEDITOR.NODE_TEXT&&(h>=e.getLength()?f.setStartAfter(e):f.setStartBefore(e));d&&d.type==CKEDITOR.NODE_TEXT&&(g?f.setEndAfter(d):f.setEndBefore(d));e=new CKEDITOR.dom.walker(f);e.evaluator=function(e){if(e.type==CKEDITOR.NODE_ELEMENT&&e.isReadOnly()){var d=c.clone();
c.setEndBefore(e);c.collapsed&&a.splice(b--,1);if(!(e.getPosition(f.endContainer)&CKEDITOR.POSITION_CONTAINS)){d.setStartAfter(e);d.collapsed||a.splice(b+1,0,d)}return true}return false};e.next()}}return a}var l,o,p=CKEDITOR.dom.walker.invisible(1),r=function(){function a(b){return function(a){var c=a.editor.createRange();c.moveToClosestEditablePosition(a.selected,b)&&a.editor.getSelection().selectRanges([c]);return false}}function b(a){return function(b){var c=b.editor,e=c.createRange(),d;if(!(d=
e.moveToClosestEditablePosition(b.selected,a)))d=e.moveToClosestEditablePosition(b.selected,!a);d&&c.getSelection().selectRanges([e]);c.fire("saveSnapshot");b.selected.remove();if(!d){e.moveToElementEditablePosition(c.editable());c.getSelection().selectRanges([e])}c.fire("saveSnapshot");return false}}var c=a(),e=a(1);return{37:c,38:c,39:e,40:e,8:b(),46:b(1)}}();CKEDITOR.on("instanceCreated",function(b){function c(){var a=e.getSelection();a&&a.removeAllRanges()}var e=b.editor;e.on("contentDom",function(){function b(){D=
new CKEDITOR.dom.selection(e.getSelection());D.lock()}function c(){h.removeListener("mouseup",c);j.removeListener("mouseup",c);var a=CKEDITOR.document.$.selection,b=a.createRange();a.type!="None"&&b.parentElement().ownerDocument==d.$&&b.select()}var d=e.document,h=CKEDITOR.document,g=e.editable(),k=d.getBody(),j=d.getDocumentElement(),o=g.isInline(),A,D;CKEDITOR.env.gecko&&g.attachListener(g,"focus",function(a){a.removeListener();if(A!==0)if((a=e.getSelection().getNative())&&a.isCollapsed&&a.anchorNode==
g.$){a=e.createRange();a.moveToElementEditStart(g);a.select()}},null,null,-2);g.attachListener(g,CKEDITOR.env.webkit?"DOMFocusIn":"focus",function(){A&&CKEDITOR.env.webkit&&(A=e._.previousActive&&e._.previousActive.equals(d.getActive()));e.unlockSelection(A);A=0},null,null,-1);g.attachListener(g,"mousedown",function(){A=0});if(CKEDITOR.env.ie||o){s?g.attachListener(g,"beforedeactivate",b,null,null,-1):g.attachListener(e,"selectionCheck",b,null,null,-1);g.attachListener(g,CKEDITOR.env.webkit?"DOMFocusOut":
"blur",function(){e.lockSelection(D);A=1},null,null,-1);g.attachListener(g,"mousedown",function(){A=0})}if(CKEDITOR.env.ie&&!o){var E;g.attachListener(g,"mousedown",function(a){if(a.data.$.button==2){a=e.document.getSelection();if(!a||a.getType()==CKEDITOR.SELECTION_NONE)E=e.window.getScrollPosition()}});g.attachListener(g,"mouseup",function(a){if(a.data.$.button==2&&E){e.document.$.documentElement.scrollLeft=E.x;e.document.$.documentElement.scrollTop=E.y}E=null});if(d.$.compatMode!="BackCompat"){if(CKEDITOR.env.ie7Compat||
CKEDITOR.env.ie6Compat)j.on("mousedown",function(a){function b(a){a=a.data.$;if(c){var e=k.$.createTextRange();try{e.moveToPoint(a.clientX,a.clientY)}catch(d){}c.setEndPoint(g.compareEndPoints("StartToStart",e)<0?"EndToEnd":"StartToStart",e);c.select()}}function e(){j.removeListener("mousemove",b);h.removeListener("mouseup",e);j.removeListener("mouseup",e);c.select()}a=a.data;if(a.getTarget().is("html")&&a.$.y<j.$.clientHeight&&a.$.x<j.$.clientWidth){var c=k.$.createTextRange();try{c.moveToPoint(a.$.clientX,
a.$.clientY)}catch(d){}var g=c.duplicate();j.on("mousemove",b);h.on("mouseup",e);j.on("mouseup",e)}});if(CKEDITOR.env.version>7&&CKEDITOR.env.version<11)j.on("mousedown",function(a){if(a.data.getTarget().is("html")){h.on("mouseup",c);j.on("mouseup",c)}})}}g.attachListener(g,"selectionchange",a,e);g.attachListener(g,"keyup",f,e);g.attachListener(g,CKEDITOR.env.webkit?"DOMFocusIn":"focus",function(){e.forceNextSelectionCheck();e.selectionChange(1)});if(o&&(CKEDITOR.env.webkit||CKEDITOR.env.gecko)){var v;
g.attachListener(g,"mousedown",function(){v=1});g.attachListener(d.getDocumentElement(),"mouseup",function(){v&&f.call(e);v=0})}else g.attachListener(CKEDITOR.env.ie?g:d.getDocumentElement(),"mouseup",f,e);CKEDITOR.env.webkit&&g.attachListener(d,"keydown",function(a){switch(a.data.getKey()){case 13:case 33:case 34:case 35:case 36:case 37:case 39:case 8:case 45:case 46:i(g)}},null,null,-1);g.attachListener(g,"keydown",m(e),null,null,-1)});e.on("setData",function(){e.unlockSelection();CKEDITOR.env.webkit&&
c()});e.on("contentDomUnload",function(){e.unlockSelection()});if(CKEDITOR.env.ie9Compat)e.on("beforeDestroy",c,null,null,9);e.on("dataReady",function(){delete e._.fakeSelection;delete e._.hiddenSelectionContainer;e.selectionChange(1)});e.on("loadSnapshot",function(){var a=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_ELEMENT),b=e.editable().getLast(a);if(b&&b.hasAttribute("data-cke-hidden-sel")){b.remove();if(CKEDITOR.env.gecko)(a=e.editable().getFirst(a))&&(a.is("br")&&a.getAttribute("_moz_editor_bogus_node"))&&
a.remove()}},null,null,100);e.on("key",function(a){if(e.mode=="wysiwyg"){var b=e.getSelection();if(b.isFake){var c=r[a.data.keyCode];if(c)return c({editor:e,selected:b.getSelectedElement(),selection:b,keyEvent:a})}}})});CKEDITOR.on("instanceReady",function(a){function b(){var a=d.editable();if(a)if(a=g(a)){var c=d.document.$.getSelection();if(c.type!="None"&&(c.anchorNode==a.$||c.focusNode==a.$))j=h(c);f=a.getText();a.setText(e(f))}}function c(){var a=d.editable();if(a)if(a=g(a)){a.setText(f);if(j){k(d.document.$,
j);j=null}}}var d=a.editor,f,j;if(CKEDITOR.env.webkit){d.on("selectionChange",function(){var a=d.editable(),b=g(a);b&&(b.getCustomData("ready")?i(a):b.setCustomData("ready",1))},null,null,-1);d.on("beforeSetMode",function(){i(d.editable())},null,null,-1);d.on("beforeUndoImage",b);d.on("afterUndoImage",c);d.on("beforeGetData",b,null,null,0);d.on("getData",c)}});CKEDITOR.editor.prototype.selectionChange=function(b){(b?a:f).call(this)};CKEDITOR.editor.prototype.getSelection=function(a){if((this._.savedSelection||
this._.fakeSelection)&&!a)return this._.savedSelection||this._.fakeSelection;return(a=this.editable())&&this.mode=="wysiwyg"?new CKEDITOR.dom.selection(a):null};CKEDITOR.editor.prototype.lockSelection=function(a){a=a||this.getSelection(1);if(a.getType()!=CKEDITOR.SELECTION_NONE){!a.isLocked&&a.lock();this._.savedSelection=a;return true}return false};CKEDITOR.editor.prototype.unlockSelection=function(a){var b=this._.savedSelection;if(b){b.unlock(a);delete this._.savedSelection;return true}return false};
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;var s=typeof window.getSelection!=
"function",u=1;CKEDITOR.dom.selection=function(a){if(a instanceof CKEDITOR.dom.selection)var b=a,a=a.root;var e=a instanceof CKEDITOR.dom.element;this.rev=b?b.rev:u++;this.document=a instanceof CKEDITOR.dom.document?a:a.getDocument();this.root=e?a:this.document.getBody();this.isLocked=0;this._={cache:{}};if(b){CKEDITOR.tools.extend(this._.cache,b._.cache);this.isFake=b.isFake;this.isLocked=b.isLocked;return this}var a=this.getNative(),c,d;if(a)if(a.getRangeAt)c=(d=a.rangeCount&&a.getRangeAt(0))&&
new CKEDITOR.dom.node(d.commonAncestorContainer);else{try{d=a.createRange()}catch(h){}c=d&&CKEDITOR.dom.element.get(d.item&&d.item(0)||d.parentElement())}if(!c||!(c.type==CKEDITOR.NODE_ELEMENT||c.type==CKEDITOR.NODE_TEXT)||!this.root.equals(c)&&!this.root.contains(c)){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 w={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.dom.selection.prototype={getNative:function(){return this._.cache.nativeSel!==void 0?this._.cache.nativeSel:this._.cache.nativeSel=s?this.document.$.selection:this.document.getWindow().$.getSelection()},getType:s?function(){var a=this._.cache;if(a.type)return a.type;var b=CKEDITOR.SELECTION_NONE;try{var c=this.getNative(),e=c.type;if(e=="Text")b=CKEDITOR.SELECTION_TEXT;if(e=="Control")b=
CKEDITOR.SELECTION_ELEMENT;if(c.createRange().parentElement())b=CKEDITOR.SELECTION_TEXT}catch(d){}return a.type=b}:function(){var a=this._.cache;if(a.type)return a.type;var b=CKEDITOR.SELECTION_TEXT,c=this.getNative();if(!c||!c.rangeCount)b=CKEDITOR.SELECTION_NONE;else if(c.rangeCount==1){var c=c.getRangeAt(0),e=c.startContainer;if(e==c.endContainer&&e.nodeType==1&&c.endOffset-c.startOffset==1&&w[e.childNodes[c.startOffset].nodeName.toLowerCase()])b=CKEDITOR.SELECTION_ELEMENT}return a.type=b},getRanges:function(){var a=
s?function(){function a(b){return(new CKEDITOR.dom.node(b)).getIndex()}var b=function(b,c){b=b.duplicate();b.collapse(c);var e=b.parentElement();if(!e.hasChildNodes())return{container:e,offset:0};for(var d=e.children,h,g,f=b.duplicate(),i=0,k=d.length-1,j=-1,m,o;i<=k;){j=Math.floor((i+k)/2);h=d[j];f.moveToElementText(h);m=f.compareEndPoints("StartToStart",b);if(m>0)k=j-1;else if(m<0)i=j+1;else return{container:e,offset:a(h)}}if(j==-1||j==d.length-1&&m<0){f.moveToElementText(e);f.setEndPoint("StartToStart",
b);f=f.text.replace(/(\r\n|\r)/g,"\n").length;d=e.childNodes;if(!f){h=d[d.length-1];return h.nodeType!=CKEDITOR.NODE_TEXT?{container:e,offset:d.length}:{container:h,offset:h.nodeValue.length}}for(e=d.length;f>0&&e>0;){g=d[--e];if(g.nodeType==CKEDITOR.NODE_TEXT){o=g;f=f-g.nodeValue.length}}return{container:o,offset:-f}}f.collapse(m>0?true:false);f.setEndPoint(m>0?"StartToStart":"EndToStart",b);f=f.text.replace(/(\r\n|\r)/g,"\n").length;if(!f)return{container:e,offset:a(h)+(m>0?0:1)};for(;f>0;)try{g=
h[m>0?"previousSibling":"nextSibling"];if(g.nodeType==CKEDITOR.NODE_TEXT){f=f-g.nodeValue.length;o=g}h=g}catch(l){return{container:e,offset:a(h)}}return{container:o,offset:m>0?-f:o.nodeValue.length+f}};return function(){var a=this.getNative(),c=a&&a.createRange(),e=this.getType();if(!a)return[];if(e==CKEDITOR.SELECTION_TEXT){a=new CKEDITOR.dom.range(this.root);e=b(c,true);a.setStart(new CKEDITOR.dom.node(e.container),e.offset);e=b(c);a.setEnd(new CKEDITOR.dom.node(e.container),e.offset);a.endContainer.getPosition(a.startContainer)&
CKEDITOR.POSITION_PRECEDING&&a.endOffset<=a.startContainer.getIndex()&&a.collapse();return[a]}if(e==CKEDITOR.SELECTION_ELEMENT){for(var e=[],d=0;d<c.length;d++){for(var h=c.item(d),g=h.parentNode,f=0,a=new CKEDITOR.dom.range(this.root);f<g.childNodes.length&&g.childNodes[f]!=h;f++);a.setStart(new CKEDITOR.dom.node(g),f);a.setEnd(new CKEDITOR.dom.node(g),f+1);e.push(a)}return e}return[]}}():function(){var a=[],b,e=this.getNative();if(!e)return a;for(var c=0;c<e.rangeCount;c++){var d=e.getRangeAt(c);
b=new CKEDITOR.dom.range(this.root);b.setStart(new CKEDITOR.dom.node(d.startContainer),d.startOffset);b.setEnd(new CKEDITOR.dom.node(d.endContainer),d.endOffset);a.push(b)}return a};return function(b){var e=this._.cache,c=e.ranges;if(!c)e.ranges=c=new CKEDITOR.dom.rangeList(a.call(this));return!b?c:q(new CKEDITOR.dom.rangeList(c.slice()))}}(),getStartElement:function(){var a=this._.cache;if(a.startElement!==void 0)return a.startElement;var b;switch(this.getType()){case CKEDITOR.SELECTION_ELEMENT:return this.getSelectedElement();
case CKEDITOR.SELECTION_TEXT:var e=this.getRanges()[0];if(e){if(e.collapsed){b=e.startContainer;b.type!=CKEDITOR.NODE_ELEMENT&&(b=b.getParent())}else{for(e.optimize();;){b=e.startContainer;if(e.startOffset==(b.getChildCount?b.getChildCount():b.getLength())&&!b.isBlockBoundary())e.setStartAfter(b);else break}b=e.startContainer;if(b.type!=CKEDITOR.NODE_ELEMENT)return b.getParent();b=b.getChild(e.startOffset);if(!b||b.type!=CKEDITOR.NODE_ELEMENT)b=e.startContainer;else for(e=b.getFirst();e&&e.type==
CKEDITOR.NODE_ELEMENT;){b=e;e=e.getFirst()}}b=b.$}}return a.startElement=b?new CKEDITOR.dom.element(b):null},getSelectedElement:function(){var a=this._.cache;if(a.selectedElement!==void 0)return a.selectedElement;var b=this,e=CKEDITOR.tools.tryThese(function(){return b.getNative().createRange().item(0)},function(){for(var a=b.getRanges()[0].clone(),e,c,d=2;d&&(!(e=a.getEnclosedNode())||!(e.type==CKEDITOR.NODE_ELEMENT&&w[e.getName()]&&(c=e)));d--)a.shrink(CKEDITOR.SHRINK_ELEMENT);return c&&c.$});return a.selectedElement=
e?new CKEDITOR.dom.element(e):null},getSelectedText:function(){var a=this._.cache;if(a.selectedText!==void 0)return a.selectedText;var b=this.getNative(),b=s?b.type=="Control"?"":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(),e=!b&&this.getRanges(),c=this.isFake;this.isLocked=
0;this.reset();if(a)(a=b||e[0]&&e[0].getCommonAncestor())&&a.getAscendant("body",1)&&(c?this.fake(b):b?this.selectElement(b):this.selectRanges(e))}},reset:function(){this._.cache={};this.isFake=0;var a=this.root.editor;if(a&&a._.fakeSelection&&this.rev==a._.fakeSelection.rev){delete a._.fakeSelection;var b=a._.hiddenSelectionContainer;if(b){var e=a.checkDirty();a.fire("lockSnapshot");b.remove();a.fire("unlockSnapshot");!e&&a.resetDirty()}delete a._.hiddenSelectionContainer}this.rev=u++},selectElement:function(a){var b=
new CKEDITOR.dom.range(this.root);b.setStartBefore(a);b.setEndAfter(a);this.selectRanges([b])},selectRanges:function(a){var e=this.root.editor,e=e&&e._.hiddenSelectionContainer;this.reset();if(e)for(var e=this.root,c,d=0;d<a.length;++d){c=a[d];if(c.endContainer.equals(e))c.endOffset=Math.min(c.endOffset,e.getChildCount())}if(a.length)if(this.isLocked){var h=CKEDITOR.document.getActive();this.unlock();this.selectRanges(a);this.lock();h&&!h.equals(this.root)&&h.focus()}else{var g;a:{var f,k;if(a.length==
1&&!(k=a[0]).collapsed&&(g=k.getEnclosedNode())&&g.type==CKEDITOR.NODE_ELEMENT){k=k.clone();k.shrink(CKEDITOR.SHRINK_ELEMENT,true);if((f=k.getEnclosedNode())&&f.type==CKEDITOR.NODE_ELEMENT)g=f;if(g.getAttribute("contenteditable")=="false")break a}g=void 0}if(g)this.fake(g);else{if(s){k=CKEDITOR.dom.walker.whitespaces(true);f=/\ufeff|\u00a0/;e={table:1,tbody:1,tr:1};if(a.length>1){g=a[a.length-1];a[0].setEnd(g.endContainer,g.endOffset)}g=a[0];var a=g.collapsed,j,m,o;if((c=g.getEnclosedNode())&&c.type==
CKEDITOR.NODE_ELEMENT&&c.getName()in w&&(!c.is("a")||!c.getText()))try{o=c.$.createControlRange();o.addElement(c.$);o.select();return}catch(A){}if(g.startContainer.type==CKEDITOR.NODE_ELEMENT&&g.startContainer.getName()in e||g.endContainer.type==CKEDITOR.NODE_ELEMENT&&g.endContainer.getName()in e){g.shrink(CKEDITOR.NODE_ELEMENT,true);a=g.collapsed}o=g.createBookmark();e=o.startNode;if(!a)h=o.endNode;o=g.document.$.body.createTextRange();o.moveToElementText(e.$);o.moveStart("character",1);if(h){f=
g.document.$.body.createTextRange();f.moveToElementText(h.$);o.setEndPoint("EndToEnd",f);o.moveEnd("character",-1)}else{j=e.getNext(k);m=e.hasAscendant("pre");j=!(j&&j.getText&&j.getText().match(f))&&(m||!e.hasPrevious()||e.getPrevious().is&&e.getPrevious().is("br"));m=g.document.createElement("span");m.setHtml("&#65279;");m.insertBefore(e);j&&g.document.createText("﻿").insertBefore(e)}g.setStartBefore(e);e.remove();if(a){if(j){o.moveStart("character",-1);o.select();g.document.$.selection.clear()}else o.select();
g.moveToPosition(m,CKEDITOR.POSITION_BEFORE_START);m.remove()}else{g.setEndBefore(h);h.remove();o.select()}}else{h=this.getNative();if(!h)return;this.removeAllRanges();for(o=0;o<a.length;o++){if(o<a.length-1){j=a[o];m=a[o+1];f=j.clone();f.setStart(j.endContainer,j.endOffset);f.setEnd(m.startContainer,m.startOffset);if(!f.collapsed){f.shrink(CKEDITOR.NODE_ELEMENT,true);g=f.getCommonAncestor();f=f.getEnclosedNode();if(g.isReadOnly()||f&&f.isReadOnly()){m.setStart(j.startContainer,j.startOffset);a.splice(o--,
1);continue}}}g=a[o];m=this.document.$.createRange();if(g.collapsed&&CKEDITOR.env.webkit&&b(g)){j=this.root;i(j,false);f=j.getDocument().createText("​");j.setCustomData("cke-fillingChar",f);g.insertNode(f);if((j=f.getNext())&&!f.getPrevious()&&j.type==CKEDITOR.NODE_ELEMENT&&j.getName()=="br"){i(this.root);g.moveToPosition(j,CKEDITOR.POSITION_BEFORE_START)}else g.moveToPosition(f,CKEDITOR.POSITION_AFTER_END)}m.setStart(g.startContainer.$,g.startOffset);try{m.setEnd(g.endContainer.$,g.endOffset)}catch(D){if(D.toString().indexOf("NS_ERROR_ILLEGAL_VALUE")>=
0){g.collapse(1);m.setEnd(g.endContainer.$,g.endOffset)}else throw D;}h.addRange(m)}}this.reset();this.root.fire("selectionchange")}}},fake:function(a){var b=this.root.editor;this.reset();j(b);var e=this._.cache,c=new CKEDITOR.dom.range(this.root);c.setStartBefore(a);c.setEndAfter(a);e.ranges=new CKEDITOR.dom.rangeList(c);e.selectedElement=e.startElement=a;e.type=CKEDITOR.SELECTION_ELEMENT;e.selectedText=e.nativeSel=null;this.isFake=1;this.rev=u++;b._.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=[],e=0;e<a.length;e++){var c=new CKEDITOR.dom.range(this.root);c.moveToBookmark(a[e]);b.push(c)}a.isFake?this.fake(b[0].getEnclosedNode()):
this.selectRanges(b);return this},getCommonAncestor:function(){var a=this.getRanges();return!a.length?null:a[0].startContainer.getCommonAncestor(a[a.length-1].endContainer)},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[s?"empty":"removeAllRanges"]()}catch(b){}this.reset()}}}})();"use strict";CKEDITOR.STYLE_BLOCK=1;CKEDITOR.STYLE_INLINE=2;CKEDITOR.STYLE_OBJECT=
3;(function(){function a(a,b){for(var e,c;a=a.getParent();){if(a.equals(b))break;if(a.getAttribute("data-nostyle"))e=a;else if(!c){var d=a.getAttribute("contentEditable");d=="false"?e=a:d=="true"&&(c=1)}}return e}function f(b){var e=b.document;if(b.collapsed){e=r(this,e);b.insertNode(e);b.moveToPosition(e,CKEDITOR.POSITION_BEFORE_END)}else{var d=this.element,g=this._.definition,h,i=g.ignoreReadonly,k=i||g.includeReadonly;k==null&&(k=b.root.getCustomData("cke_includeReadonly"));var j=CKEDITOR.dtd[d];
if(!j){h=true;j=CKEDITOR.dtd.span}b.enlarge(CKEDITOR.ENLARGE_INLINE,1);b.trim();var m=b.createBookmark(),o=m.startNode,q=m.endNode,p=o,u;if(!i){var n=b.getCommonAncestor(),i=a(o,n),n=a(q,n);i&&(p=i.getNextSourceNode(true));n&&(q=n)}for(p.getPosition(q)==CKEDITOR.POSITION_FOLLOWING&&(p=0);p;){i=false;if(p.equals(q)){p=null;i=true}else{var s=p.type==CKEDITOR.NODE_ELEMENT?p.getName():null,n=s&&p.getAttribute("contentEditable")=="false",w=s&&p.getAttribute("data-nostyle");if(s&&p.data("cke-bookmark")){p=
p.getNextSourceNode(true);continue}if(n&&k&&CKEDITOR.dtd.$block[s])for(var v=p,z=c(v),t=void 0,y=z.length,x=0,v=y&&new CKEDITOR.dom.range(v.getDocument());x<y;++x){var t=z[x],C=CKEDITOR.filter.instances[t.data("cke-filter")];if(C?C.check(this):1){v.selectNodeContents(t);f.call(this,v)}}z=s?!j[s]||w?0:n&&!k?0:(p.getPosition(q)|H)==H&&(!g.childRule||g.childRule(p)):1;if(z)if((z=p.getParent())&&((z.getDtd()||CKEDITOR.dtd.span)[d]||h)&&(!g.parentRule||g.parentRule(z))){if(!u&&(!s||!CKEDITOR.dtd.$removeEmpty[s]||
(p.getPosition(q)|H)==H)){u=b.clone();u.setStartBefore(p)}s=p.type;if(s==CKEDITOR.NODE_TEXT||n||s==CKEDITOR.NODE_ELEMENT&&!p.getChildCount()){for(var s=p,aa;(i=!s.getNext(B))&&(aa=s.getParent(),j[aa.getName()])&&(aa.getPosition(o)|F)==F&&(!g.childRule||g.childRule(aa));)s=aa;u.setEndAfter(s)}}else i=true;else i=true;p=p.getNextSourceNode(w||n)}if(i&&u&&!u.collapsed){for(var i=r(this,e),n=i.hasAttributes(),w=u.getCommonAncestor(),s={},z={},t={},y={},U,$,ca;i&&w;){if(w.getName()==d){for(U in g.attributes)if(!y[U]&&
(ca=w.getAttribute($)))i.getAttribute(U)==ca?z[U]=1:y[U]=1;for($ in g.styles)if(!t[$]&&(ca=w.getStyle($)))i.getStyle($)==ca?s[$]=1:t[$]=1}w=w.getParent()}for(U in z)i.removeAttribute(U);for($ in s)i.removeStyle($);n&&!i.hasAttributes()&&(i=null);if(i){u.extractContents().appendTo(i);u.insertNode(i);l.call(this,i);i.mergeSiblings();CKEDITOR.env.ie||i.$.normalize()}else{i=new CKEDITOR.dom.element("span");u.extractContents().appendTo(i);u.insertNode(i);l.call(this,i);i.remove(true)}u=null}}b.moveToBookmark(m);
b.shrink(CKEDITOR.SHRINK_TEXT);b.shrink(CKEDITOR.NODE_ELEMENT,true)}}function d(a){function b(){for(var a=new CKEDITOR.dom.elementPath(c.getParent()),e=new CKEDITOR.dom.elementPath(k.getParent()),d=null,g=null,h=0;h<a.elements.length;h++){var f=a.elements[h];if(f==a.block||f==a.blockLimit)break;j.checkElementRemovable(f,true)&&(d=f)}for(h=0;h<e.elements.length;h++){f=e.elements[h];if(f==e.block||f==e.blockLimit)break;j.checkElementRemovable(f,true)&&(g=f)}g&&k.breakParent(g);d&&c.breakParent(d)}a.enlarge(CKEDITOR.ENLARGE_INLINE,
1);var e=a.createBookmark(),c=e.startNode;if(a.collapsed){for(var d=new CKEDITOR.dom.elementPath(c.getParent(),a.root),g,h=0,f;h<d.elements.length&&(f=d.elements[h]);h++){if(f==d.block||f==d.blockLimit)break;if(this.checkElementRemovable(f)){var i;if(a.collapsed&&(a.checkBoundaryOfElement(f,CKEDITOR.END)||(i=a.checkBoundaryOfElement(f,CKEDITOR.START)))){g=f;g.match=i?"start":"end"}else{f.mergeSiblings();f.is(this.element)?q.call(this,f):o(f,w(this)[f.getName()])}}}if(g){f=c;for(h=0;;h++){i=d.elements[h];
if(i.equals(g))break;else if(i.match)continue;else i=i.clone();i.append(f);f=i}f[g.match=="start"?"insertBefore":"insertAfter"](g)}}else{var k=e.endNode,j=this;b();for(d=c;!d.equals(k);){g=d.getNextSourceNode();if(d.type==CKEDITOR.NODE_ELEMENT&&this.checkElementRemovable(d)){d.getName()==this.element?q.call(this,d):o(d,w(this)[d.getName()]);if(g.type==CKEDITOR.NODE_ELEMENT&&g.contains(c)){b();g=c.getNext()}}d=g}}a.moveToBookmark(e);a.shrink(CKEDITOR.NODE_ELEMENT,true)}function c(a){var b=[];a.forEach(function(a){if(a.getAttribute("contenteditable")==
"true"){b.push(a);return false}},CKEDITOR.NODE_ELEMENT,true);return b}function b(a){var b=a.getEnclosedNode()||a.getCommonAncestor(false,true);(a=(new CKEDITOR.dom.elementPath(b,a.root)).contains(this.element,1))&&!a.isReadOnly()&&s(a,this)}function g(a){var b=a.getCommonAncestor(true,true);if(a=(new CKEDITOR.dom.elementPath(b,a.root)).contains(this.element,1)){var b=this._.definition,e=b.attributes;if(e)for(var c in e)a.removeAttribute(c,e[c]);if(b.styles)for(var d in b.styles)b.styles.hasOwnProperty(d)&&
a.removeStyle(d)}}function i(a){var b=a.createBookmark(true),e=a.createIterator();e.enforceRealBlocks=true;if(this._.enterMode)e.enlargeBr=this._.enterMode!=CKEDITOR.ENTER_BR;for(var c,d=a.document,g;c=e.getNextParagraph();)if(!c.isReadOnly()&&(e.activeFilter?e.activeFilter.check(this):1)){g=r(this,d,c);h(c,g)}a.moveToBookmark(b)}function e(a){var b=a.createBookmark(1),e=a.createIterator();e.enforceRealBlocks=true;e.enlargeBr=this._.enterMode!=CKEDITOR.ENTER_BR;for(var c,d;c=e.getNextParagraph();)if(this.checkElementRemovable(c))if(c.is("pre")){(d=
this._.enterMode==CKEDITOR.ENTER_BR?null:a.document.createElement(this._.enterMode==CKEDITOR.ENTER_P?"p":"div"))&&c.copyAttributes(d);h(c,d)}else q.call(this,c);a.moveToBookmark(b)}function h(a,b){var e=!b;if(e){b=a.getDocument().createElement("div");a.copyAttributes(b)}var c=b&&b.is("pre"),d=a.is("pre"),g=!c&&d;if(c&&!d){d=b;(g=a.getBogus())&&g.remove();g=a.getHtml();g=j(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(d);d.$.outerHTML="<pre>"+g+"</pre>";d.copyAttributes(h.getFirst());d=h.getFirst().remove()}else d.setHtml(g);b=d}else g?b=m(e?[a.getHtml()]:k(a),b):a.moveChildren(b);b.replace(a);if(c){var e=b,f;if((f=e.getPrevious(C))&&f.type==CKEDITOR.NODE_ELEMENT&&f.is("pre")){c=j(f.getHtml(),/\n$/,"")+"\n\n"+j(e.getHtml(),/^\n/,"");CKEDITOR.env.ie?e.$.outerHTML="<pre>"+c+"</pre>":e.setHtml(c);f.remove()}}else e&&
p(b)}function k(a){var b=[];j(a.getOuterHtml(),/(\S\s*)\n(?:\s|(<span[^>]+data-cke-bookmark.*?\/span>))*\n(?!$)/gi,function(a,b,e){return b+"</pre>"+e+"<pre>"}).replace(/<pre\b.*?>([\s\S]*?)<\/pre>/gi,function(a,e){b.push(e)});return b}function j(a,b,e){var c="",d="",a=a.replace(/(^<span[^>]+data-cke-bookmark.*?\/span>)|(<span[^>]+data-cke-bookmark.*?\/span>$)/gi,function(a,b,e){b&&(c=b);e&&(d=e);return""});return c+a.replace(b,e)+d}function m(a,b){var e;a.length>1&&(e=new CKEDITOR.dom.documentFragment(b.getDocument()));
for(var c=0;c<a.length;c++){var d=a[c],d=d.replace(/(\r\n|\r)/g,"\n"),d=j(d,/^[ \t]*\n/,""),d=j(d,/\n$/,""),d=j(d,/^[ \t]+|[ \t]+$/g,function(a,b){return a.length==1?"&nbsp;":b?" "+CKEDITOR.tools.repeat("&nbsp;",a.length-1):CKEDITOR.tools.repeat("&nbsp;",a.length-1)+" "}),d=d.replace(/\n/g,"<br>"),d=d.replace(/[ \t]{2,}/g,function(a){return CKEDITOR.tools.repeat("&nbsp;",a.length-1)+" "});if(e){var g=b.clone();g.setHtml(d);e.append(g)}else b.setHtml(d)}return e||b}function q(a,b){var e=this._.definition,
c=e.attributes,e=e.styles,d=w(this)[a.getName()],g=CKEDITOR.tools.isEmpty(c)&&CKEDITOR.tools.isEmpty(e),h;for(h in c)if(!((h=="class"||this._.definition.fullMatch)&&a.getAttribute(h)!=v(h,c[h]))&&!(b&&h.slice(0,5)=="data-")){g=a.hasAttribute(h);a.removeAttribute(h)}for(var f in e)if(!(this._.definition.fullMatch&&a.getStyle(f)!=v(f,e[f],true))){g=g||!!a.getStyle(f);a.removeStyle(f)}o(a,d,y[a.getName()]);g&&(this._.definition.alwaysRemoveElement?p(a,1):!CKEDITOR.dtd.$block[a.getName()]||this._.enterMode==
CKEDITOR.ENTER_BR&&!a.hasAttributes()?p(a):a.renameNode(this._.enterMode==CKEDITOR.ENTER_P?"p":"div"))}function l(a){for(var b=w(this),e=a.getElementsByTag(this.element),c,d=e.count();--d>=0;){c=e.getItem(d);c.isReadOnly()||q.call(this,c,true)}for(var g in b)if(g!=this.element){e=a.getElementsByTag(g);for(d=e.count()-1;d>=0;d--){c=e.getItem(d);c.isReadOnly()||o(c,b[g])}}}function o(a,b,e){if(b=b&&b.attributes)for(var c=0;c<b.length;c++){var d=b[c][0],g;if(g=a.getAttribute(d)){var h=b[c][1];(h===null||
h.test&&h.test(g)||typeof h=="string"&&g==h)&&a.removeAttribute(d)}}e||p(a)}function p(a,b){if(!a.hasAttributes()||b)if(CKEDITOR.dtd.$block[a.getName()]){var e=a.getPrevious(C),c=a.getNext(C);e&&(e.type==CKEDITOR.NODE_TEXT||!e.isBlockBoundary({br:1}))&&a.append("br",1);c&&(c.type==CKEDITOR.NODE_TEXT||!c.isBlockBoundary({br:1}))&&a.append("br");a.remove(true)}else{e=a.getFirst();c=a.getLast();a.remove(true);if(e){e.type==CKEDITOR.NODE_ELEMENT&&e.mergeSiblings();c&&(!e.equals(c)&&c.type==CKEDITOR.NODE_ELEMENT)&&
c.mergeSiblings()}}}function r(a,b,e){var c;c=a.element;c=="*"&&(c="span");c=new CKEDITOR.dom.element(c,b);e&&e.copyAttributes(c);c=s(c,a);b.getCustomData("doc_processing_style")&&c.hasAttribute("id")?c.removeAttribute("id"):b.setCustomData("doc_processing_style",1);return c}function s(a,b){var e=b._.definition,c=e.attributes,e=CKEDITOR.style.getStyleText(e);if(c)for(var d in c)a.setAttribute(d,c[d]);e&&a.setAttribute("style",e);return a}function u(a,b){for(var e in a)a[e]=a[e].replace(z,function(a,
e){return b[e]})}function w(a){if(a._.overrides)return a._.overrides;var b=a._.overrides={},e=a._.definition.overrides;if(e){CKEDITOR.tools.isArray(e)||(e=[e]);for(var c=0;c<e.length;c++){var d=e[c],g,h;if(typeof d=="string")g=d.toLowerCase();else{g=d.element?d.element.toLowerCase():a.element;h=d.attributes}d=b[g]||(b[g]={});if(h){var d=d.attributes=d.attributes||[],f;for(f in h)d.push([f.toLowerCase(),h[f]])}}}return b}function v(a,b,e){var c=new CKEDITOR.dom.element("span");c[e?"setStyle":"setAttribute"](a,
b);return c[e?"getStyle":"getAttribute"](a)}function t(a,b,e){for(var c=a.document,d=a.getRanges(),b=b?this.removeFromRange:this.applyToRange,g,h=d.createIterator();g=h.getNextRange();)b.call(this,g,e);a.selectRanges(d);c.removeCustomData("doc_processing_style")}var y={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},n=
{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},x=/\s*(?:;\s*|$)/,z=/#\((.+?)\)/g,B=CKEDITOR.dom.walker.bookmark(0,1),C=CKEDITOR.dom.walker.whitespaces(1);CKEDITOR.style=function(a,b){if(typeof a.type=="string")return new CKEDITOR.style.customHandlers[a.type](a);var e=a.attributes;if(e&&e.style){a.styles=CKEDITOR.tools.extend({},a.styles,CKEDITOR.tools.parseCssText(e.style));delete e.style}if(b){a=CKEDITOR.tools.clone(a);u(a.attributes,
b);u(a.styles,b)}e=this.element=a.element?typeof a.element=="string"?a.element.toLowerCase():a.element:"*";this.type=a.type||(y[e]?CKEDITOR.STYLE_BLOCK:n[e]?CKEDITOR.STYLE_OBJECT:CKEDITOR.STYLE_INLINE);if(typeof this.element=="object")this.type=CKEDITOR.STYLE_OBJECT;this._={definition:a}};CKEDITOR.style.prototype={apply:function(a){if(a instanceof CKEDITOR.dom.document)return t.call(this,a.getSelection());if(this.checkApplicable(a.elementPath(),a)){var b=this._.enterMode;if(!b)this._.enterMode=a.activeEnterMode;
t.call(this,a.getSelection(),0,a);this._.enterMode=b}},remove:function(a){if(a instanceof CKEDITOR.dom.document)return t.call(this,a.getSelection(),1);if(this.checkApplicable(a.elementPath(),a)){var b=this._.enterMode;if(!b)this._.enterMode=a.activeEnterMode;t.call(this,a.getSelection(),1,a);this._.enterMode=b}},applyToRange:function(a){this.applyToRange=this.type==CKEDITOR.STYLE_INLINE?f:this.type==CKEDITOR.STYLE_BLOCK?i:this.type==CKEDITOR.STYLE_OBJECT?b:null;return this.applyToRange(a)},removeFromRange:function(a){this.removeFromRange=
this.type==CKEDITOR.STYLE_INLINE?d:this.type==CKEDITOR.STYLE_BLOCK?e:this.type==CKEDITOR.STYLE_OBJECT?g:null;return this.removeFromRange(a)},applyToObject:function(a){s(a,this)},checkActive:function(a,b){switch(this.type){case CKEDITOR.STYLE_BLOCK:return this.checkElementRemovable(a.block||a.blockLimit,true,b);case CKEDITOR.STYLE_OBJECT:case CKEDITOR.STYLE_INLINE:for(var e=a.elements,c=0,d;c<e.length;c++){d=e[c];if(!(this.type==CKEDITOR.STYLE_INLINE&&(d==a.block||d==a.blockLimit))){if(this.type==
CKEDITOR.STYLE_OBJECT){var g=d.getName();if(!(typeof this.element=="string"?g==this.element:g in this.element))continue}if(this.checkElementRemovable(d,true,b))return true}}}return false},checkApplicable:function(a,b,e){b&&b instanceof CKEDITOR.filter&&(e=b);if(e&&!e.check(this))return false;switch(this.type){case CKEDITOR.STYLE_OBJECT:return!!a.contains(this.element);case CKEDITOR.STYLE_BLOCK:return!!a.blockLimit.getDtd()[this.element]}return true},checkElementMatch:function(a,b){var e=this._.definition;
if(!a||!e.ignoreReadonly&&a.isReadOnly())return false;var c=a.getName();if(typeof this.element=="string"?c==this.element:c in this.element){if(!b&&!a.hasAttributes())return true;if(c=e._AC)e=c;else{var c={},d=0,g=e.attributes;if(g)for(var h in g){d++;c[h]=g[h]}if(h=CKEDITOR.style.getStyleText(e)){c.style||d++;c.style=h}c._length=d;e=e._AC=c}if(e._length){for(var f in e)if(f!="_length"){d=a.getAttribute(f)||"";if(f=="style")a:{c=e[f];typeof c=="string"&&(c=CKEDITOR.tools.parseCssText(c));typeof d==
"string"&&(d=CKEDITOR.tools.parseCssText(d,true));h=void 0;for(h in c)if(!(h in d&&(d[h]==c[h]||c[h]=="inherit"||d[h]=="inherit"))){c=false;break a}c=true}else c=e[f]==d;if(c){if(!b)return true}else if(b)return false}if(b)return true}else return true}return false},checkElementRemovable:function(a,b,e){if(this.checkElementMatch(a,b,e))return true;if(b=w(this)[a.getName()]){var c;if(!(b=b.attributes))return true;for(e=0;e<b.length;e++){c=b[e][0];if(c=a.getAttribute(c)){var d=b[e][1];if(d===null)return true;
if(typeof d=="string"){if(c==d)return true}else if(d.test(c))return true}}}return false},buildPreview:function(a){var b=this._.definition,e=[],c=b.element;c=="bdo"&&(c="span");var e=["<",c],d=b.attributes;if(d)for(var g in d)e.push(" ",g,'="',d[g],'"');(d=CKEDITOR.style.getStyleText(b))&&e.push(' style="',d,'"');e.push(">",a||b.name,"</",c,">");return e.join("")},getDefinition:function(){return this._.definition}};CKEDITOR.style.getStyleText=function(a){var b=a._ST;if(b)return b;var b=a.styles,e=
a.attributes&&a.attributes.style||"",c="";e.length&&(e=e.replace(x,";"));for(var d in b){var g=b[d],h=(d+":"+g).replace(x,";");g=="inherit"?c=c+h:e=e+h}e.length&&(e=CKEDITOR.tools.normalizeCssText(e,true));return a._ST=e+c};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,true);
return this.customHandlers[a.type]=b};var H=CKEDITOR.POSITION_PRECEDING|CKEDITOR.POSITION_IDENTICAL|CKEDITOR.POSITION_IS_CONTAINED,F=CKEDITOR.POSITION_FOLLOWING|CKEDITOR.POSITION_IDENTICAL|CKEDITOR.POSITION_IS_CONTAINED})();CKEDITOR.styleCommand=function(a,f){this.requiredContent=this.allowedContent=this.style=a;CKEDITOR.tools.extend(this,f,true)};CKEDITOR.styleCommand.prototype.exec=function(a){a.focus();this.state==CKEDITOR.TRISTATE_OFF?a.applyStyle(this.style):this.state==CKEDITOR.TRISTATE_ON&&
a.removeStyle(this.style)};CKEDITOR.stylesSet=new CKEDITOR.resourceManager("","stylesSet");CKEDITOR.addStylesSet=CKEDITOR.tools.bind(CKEDITOR.stylesSet.add,CKEDITOR.stylesSet);CKEDITOR.loadStylesSet=function(a,f,d){CKEDITOR.stylesSet.addExternal(a,f,"");CKEDITOR.stylesSet.load(a,d)};CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{attachStyleStateChange:function(a,f){var d=this._.styleStateChangeCallbacks;if(!d){d=this._.styleStateChangeCallbacks=[];this.on("selectionChange",function(a){for(var b=
0;b<d.length;b++){var g=d[b],f=g.style.checkActive(a.data.path,this)?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF;g.fn.call(this,f)}})}d.push({style:a,fn:f})},applyStyle:function(a){a.apply(this)},removeStyle:function(a){a.remove(this)},getStylesSet:function(a){if(this._.stylesDefinitions)a(this._.stylesDefinitions);else{var f=this,d=f.config.stylesCombo_stylesSet||f.config.stylesSet;if(d===false)a(null);else if(d instanceof Array){f._.stylesDefinitions=d;a(d)}else{d||(d="default");var d=d.split(":"),
c=d[0];CKEDITOR.stylesSet.addExternal(c,d[1]?d.slice(1).join(":"):CKEDITOR.getUrl("styles.js"),"");CKEDITOR.stylesSet.load(c,function(b){f._.stylesDefinitions=b[c];a(f._.stylesDefinitions)})}}}});CKEDITOR.dom.comment=function(a,f){typeof a=="string"&&(a=(f?f.$:document).createComment(a));CKEDITOR.dom.domObject.call(this,a)};CKEDITOR.dom.comment.prototype=new CKEDITOR.dom.node;CKEDITOR.tools.extend(CKEDITOR.dom.comment.prototype,{type:CKEDITOR.NODE_COMMENT,getOuterHtml:function(){return"<\!--"+this.$.nodeValue+
"--\>"}});"use strict";(function(){var a={},f={},d;for(d in CKEDITOR.dtd.$blockLimit)d in CKEDITOR.dtd.$list||(a[d]=1);for(d in CKEDITOR.dtd.$block)d in CKEDITOR.dtd.$blockLimit||d in CKEDITOR.dtd.$empty||(f[d]=1);CKEDITOR.dom.elementPath=function(c,b){var d=null,i=null,e=[],h=c,k,b=b||c.getDocument().getBody();do if(h.type==CKEDITOR.NODE_ELEMENT){e.push(h);if(!this.lastElement){this.lastElement=h;if(h.is(CKEDITOR.dtd.$object)||h.getAttribute("contenteditable")=="false")continue}if(h.equals(b))break;
if(!i){k=h.getName();h.getAttribute("contenteditable")=="true"?i=h:!d&&f[k]&&(d=h);if(a[k]){var j;if(j=!d){if(k=k=="div"){a:{k=h.getChildren();j=0;for(var m=k.count();j<m;j++){var q=k.getItem(j);if(q.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$block[q.getName()]){k=true;break a}}k=false}k=!k}j=k}j?d=h:i=h}}}while(h=h.getParent());i||(i=b);this.block=d;this.blockLimit=i;this.root=b;this.elements=e}})();CKEDITOR.dom.elementPath.prototype={compare:function(a){var f=this.elements,a=a&&a.elements;if(!a||
f.length!=a.length)return false;for(var d=0;d<f.length;d++)if(!f[d].equals(a[d]))return false;return true},contains:function(a,f,d){var c;typeof a=="string"&&(c=function(b){return b.getName()==a});a instanceof CKEDITOR.dom.element?c=function(b){return b.equals(a)}:CKEDITOR.tools.isArray(a)?c=function(b){return CKEDITOR.tools.indexOf(a,b.getName())>-1}:typeof a=="function"?c=a:typeof a=="object"&&(c=function(b){return b.getName()in a});var b=this.elements,g=b.length;f&&g--;if(d){b=Array.prototype.slice.call(b,
0);b.reverse()}for(f=0;f<g;f++)if(c(b[f]))return b[f];return null},isContextFor:function(a){var f;if(a in CKEDITOR.dtd.$block){f=this.contains(CKEDITOR.dtd.$intermediate)||this.root.equals(this.block)&&this.block||this.blockLimit;return!!f.getDtd()[a]}return true},direction:function(){return(this.block||this.blockLimit||this.root).getDirection(1)}};CKEDITOR.dom.text=function(a,f){typeof a=="string"&&(a=(f?f.$:document).createTextNode(a));this.$=a};CKEDITOR.dom.text.prototype=new CKEDITOR.dom.node;
CKEDITOR.tools.extend(CKEDITOR.dom.text.prototype,{type:CKEDITOR.NODE_TEXT,getLength:function(){return this.$.nodeValue.length},getText:function(){return this.$.nodeValue},setText:function(a){this.$.nodeValue=a},split:function(a){var f=this.$.parentNode,d=f.childNodes.length,c=this.getLength(),b=this.getDocument(),g=new CKEDITOR.dom.text(this.$.splitText(a),b);if(f.childNodes.length==d)if(a>=c){g=b.createText("");g.insertAfter(this)}else{a=b.createText("");a.insertAfter(g);a.remove()}return g},substring:function(a,
f){return typeof f!="number"?this.$.nodeValue.substr(a):this.$.nodeValue.substring(a,f)}});(function(){function a(a,c,b){var g=a.serializable,f=c[b?"endContainer":"startContainer"],e=b?"endOffset":"startOffset",h=g?c.document.getById(a.startNode):a.startNode,a=g?c.document.getById(a.endNode):a.endNode;if(f.equals(h.getPrevious())){c.startOffset=c.startOffset-f.getLength()-a.getPrevious().getLength();f=a.getNext()}else if(f.equals(a.getPrevious())){c.startOffset=c.startOffset-f.getLength();f=a.getNext()}f.equals(h.getParent())&&
c[e]++;f.equals(a.getParent())&&c[e]++;c[b?"endContainer":"startContainer"]=f;return c}CKEDITOR.dom.rangeList=function(a){if(a instanceof CKEDITOR.dom.rangeList)return a;a?a instanceof CKEDITOR.dom.range&&(a=[a]):a=[];return CKEDITOR.tools.extend(a,f)};var f={createIterator:function(){var a=this,c=CKEDITOR.dom.walker.bookmark(),b=[],g;return{getNextRange:function(f){g=g===void 0?0:g+1;var e=a[g];if(e&&a.length>1){if(!g)for(var h=a.length-1;h>=0;h--)b.unshift(a[h].createBookmark(true));if(f)for(var k=
0;a[g+k+1];){for(var j=e.document,f=0,h=j.getById(b[k].endNode),j=j.getById(b[k+1].startNode);;){h=h.getNextSourceNode(false);if(j.equals(h))f=1;else if(c(h)||h.type==CKEDITOR.NODE_ELEMENT&&h.isBlockBoundary())continue;break}if(!f)break;k++}for(e.moveToBookmark(b.shift());k--;){h=a[++g];h.moveToBookmark(b.shift());e.setEnd(h.endContainer,h.endOffset)}}return e}}},createBookmarks:function(d){for(var c=[],b,g=0;g<this.length;g++){c.push(b=this[g].createBookmark(d,true));for(var f=g+1;f<this.length;f++){this[f]=
a(b,this[f]);this[f]=a(b,this[f],true)}}return c},createBookmarks2:function(a){for(var c=[],b=0;b<this.length;b++)c.push(this[b].createBookmark2(a));return c},moveToBookmarks:function(a){for(var c=0;c<this.length;c++)this[c].moveToBookmark(a[c])}}})();(function(){function a(){return CKEDITOR.getUrl(CKEDITOR.skinName.split(",")[1]||"skins/"+CKEDITOR.skinName.split(",")[0]+"/")}function f(b){var e=CKEDITOR.skin["ua_"+b],c=CKEDITOR.env;if(e)for(var e=e.split(",").sort(function(a,b){return a>b?-1:1}),
d=0,g;d<e.length;d++){g=e[d];if(c.ie&&(g.replace(/^ie/,"")==c.version||c.quirks&&g=="iequirks"))g="ie";if(c[g]){b=b+("_"+e[d]);break}}return CKEDITOR.getUrl(a()+b+".css")}function d(a,b){if(!g[a]){CKEDITOR.document.appendStyleSheet(f(a));g[a]=1}b&&b()}function c(a){var b=a.getById(i);if(!b){b=a.getHead().append("style");b.setAttribute("id",i);b.setAttribute("type","text/css")}return b}function b(a,b,e){var c,d,g;if(CKEDITOR.env.webkit){b=b.split("}").slice(0,-1);for(d=0;d<b.length;d++)b[d]=b[d].split("{")}for(var h=
0;h<a.length;h++)if(CKEDITOR.env.webkit)for(d=0;d<b.length;d++){g=b[d][1];for(c=0;c<e.length;c++)g=g.replace(e[c][0],e[c][1]);a[h].$.sheet.addRule(b[d][0],g)}else{g=b;for(c=0;c<e.length;c++)g=g.replace(e[c][0],e[c][1]);CKEDITOR.env.ie&&CKEDITOR.env.version<11?a[h].$.styleSheet.cssText=a[h].$.styleSheet.cssText+g:a[h].$.innerHTML=a[h].$.innerHTML+g}}var g={};CKEDITOR.skin={path:a,loadPart:function(b,e){CKEDITOR.skin.name!=CKEDITOR.skinName.split(",")[0]?CKEDITOR.scriptLoader.load(CKEDITOR.getUrl(a()+
"skin.js"),function(){d(b,e)}):d(b,e)},getPath:function(a){return CKEDITOR.getUrl(f(a))},icons:{},addIcon:function(a,b,e,c){a=a.toLowerCase();this.icons[a]||(this.icons[a]={path:b,offset:e||0,bgsize:c||"16px"})},getIconStyle:function(a,b,e,c,d){var g;if(a){a=a.toLowerCase();b&&(g=this.icons[a+"-rtl"]);g||(g=this.icons[a])}a=e||g&&g.path||"";c=c||g&&g.offset;d=d||g&&g.bgsize||"16px";return a&&"background-image:url("+CKEDITOR.getUrl(a)+");background-position:0 "+c+"px;background-size:"+d+";"}};CKEDITOR.tools.extend(CKEDITOR.editor.prototype,
{getUiColor:function(){return this.uiColor},setUiColor:function(a){var d=c(CKEDITOR.document);return(this.setUiColor=function(a){this.uiColor=a;var c=CKEDITOR.skin.chameleon,g="",f="";if(typeof c=="function"){g=c(this,"editor");f=c(this,"panel")}a=[[h,a]];b([d],g,a);b(e,f,a)}).call(this,a)}});var i="cke_ui_color",e=[],h=/\$color/g;CKEDITOR.on("instanceLoaded",function(a){if(!CKEDITOR.env.ie||!CKEDITOR.env.quirks){var d=a.editor,a=function(a){a=(a.data[0]||a.data).element.getElementsByTag("iframe").getItem(0).getFrameDocument();
if(!a.getById("cke_ui_color")){a=c(a);e.push(a);var g=d.getUiColor();g&&b([a],CKEDITOR.skin.chameleon(d,"panel"),[[h,g]])}};d.on("panelShow",a);d.on("menuShow",a);d.config.uiColor&&d.setUiColor(d.config.uiColor)}})})();(function(){if(CKEDITOR.env.webkit)CKEDITOR.env.hc=false;else{var a=CKEDITOR.dom.element.createFromHtml('<div style="width:0;height:0;position:absolute;left:-10000px;border:1px solid;border-color:red blue"></div>',CKEDITOR.document);a.appendTo(CKEDITOR.document.getHead());try{var f=
a.getComputedStyle("border-top-color"),d=a.getComputedStyle("border-right-color");CKEDITOR.env.hc=!!(f&&f==d)}catch(c){CKEDITOR.env.hc=false}a.remove()}if(CKEDITOR.env.hc)CKEDITOR.env.cssClass=CKEDITOR.env.cssClass+" cke_hc";CKEDITOR.document.appendStyleText(".cke{visibility:hidden;}");CKEDITOR.status="loaded";CKEDITOR.fireOnce("loaded");if(a=CKEDITOR._.pending){delete CKEDITOR._.pending;for(f=0;f<a.length;f++){CKEDITOR.editor.prototype.constructor.apply(a[f][0],a[f][1]);CKEDITOR.add(a[f][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 a=function(){return function(a,b){for(var d=a.match(/[^#]./g),f=0;f<3;f++){var e=d,h=f,k;k=parseInt(d[f],16);k=("0"+(b<0?0|k*(1+b):0|k+(255-k)*b).toString(16)).slice(-2);e[h]=k}return"#"+d.join("")}}(),f=function(){var a=new CKEDITOR.template("background:#{to};background-image:-webkit-gradient(linear,lefttop,leftbottom,from({from}),to({to}));background-image:-moz-linear-gradient(top,{from},{to});background-image:-webkit-linear-gradient(top,{from},{to});background-image:-o-linear-gradient(top,{from},{to});background-image:-ms-linear-gradient(top,{from},{to});background-image:linear-gradient(top,{from},{to});filter:progid:DXImageTransform.Microsoft.gradient(gradientType=0,startColorstr='{from}',endColorstr='{to}');");
return function(b,d){return a.output({from:b,to:d})}}(),d={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(c,b){var g=c.uiColor,g={id:"."+c.id,defaultBorder:a(g,-0.1),defaultGradient:f(a(g,0.9),g),lightGradient:f(a(g,1),a(g,0.7)),mediumGradient:f(a(g,0.8),a(g,0.5)),ckeButtonOn:f(a(g,0.6),a(g,0.7)),ckeResizer:a(g,-0.4),ckeToolbarSeparator:a(g,0.5),ckeColorauto:a(g,0.8),dialogBody:a(g,0.7),dialogTabSelected:f("#FFFFFF","#FFFFFF"),dialogTabSelectedBorder:"#FFF",elementsPathColor:a(g,-0.6),elementsPathBg:g,menubuttonIcon:a(g,0.5),menubuttonIconHover:a(g,0.3)};return d[b].output(g).replace(/\[/g,
"{").replace(/\]/g,"}")}}();CKEDITOR.plugins.add("basicstyles",{init:function(a){var f=0,d=function(b,e,d,g){if(g){var g=new CKEDITOR.style(g),j=c[d];j.unshift(g);a.attachStyleStateChange(g,function(b){!a.readOnly&&a.getCommand(d).setState(b)});a.addCommand(d,new CKEDITOR.styleCommand(g,{contentForms:j}));a.ui.addButton&&a.ui.addButton(b,{label:e,command:d,toolbar:"basicstyles,"+(f=f+10)})}},c={bold:["strong","b",["span",function(a){a=a.styles["font-weight"];return a=="bold"||+a>=700}]],italic:["em",
"i",["span",function(a){return a.styles["font-style"]=="italic"}]],underline:["u",["span",function(a){return a.styles["text-decoration"]=="underline"}]],strike:["s","strike",["span",function(a){return a.styles["text-decoration"]=="line-through"}]],subscript:["sub"],superscript:["sup"]},b=a.config,g=a.lang.basicstyles;d("Bold",g.bold,"bold",b.coreStyles_bold);d("Italic",g.italic,"italic",b.coreStyles_italic);d("Underline",g.underline,"underline",b.coreStyles_underline);d("Strike",g.strike,"strike",
b.coreStyles_strike);d("Subscript",g.subscript,"subscript",b.coreStyles_subscript);d("Superscript",g.superscript,"superscript",b.coreStyles_superscript);a.setKeystroke([[CKEDITOR.CTRL+66,"bold"],[CKEDITOR.CTRL+73,"italic"],[CKEDITOR.CTRL+85,"underline"]])}});CKEDITOR.config.coreStyles_bold={element:"strong",overrides:"b"};CKEDITOR.config.coreStyles_italic={element:"em",overrides:"i"};CKEDITOR.config.coreStyles_underline={element:"u"};CKEDITOR.config.coreStyles_strike={element:"s",overrides:"strike"};
CKEDITOR.config.coreStyles_subscript={element:"sub"};CKEDITOR.config.coreStyles_superscript={element:"sup"};(function(){var a='<a id="{id}" class="cke_button cke_button__{name} cke_button_{state} {cls}"'+(CKEDITOR.env.gecko&&!CKEDITOR.env.hc?"":" href=\"javascript:void('{titleJs}')\"")+' title="{title}" tabindex="-1" hidefocus="true" role="button" aria-labelledby="{id}_label" aria-haspopup="{hasArrow}" aria-disabled="{ariaDisabled}"';CKEDITOR.env.gecko&&CKEDITOR.env.mac&&(a=a+' onkeypress="return false;"');
CKEDITOR.env.gecko&&(a=a+' onblur="this.style.cssText = this.style.cssText;"');var a=a+(' onkeydown="return CKEDITOR.tools.callFunction({keydownFn},event);" onfocus="return CKEDITOR.tools.callFunction({focusFn},event);" '+(CKEDITOR.env.ie?'onclick="return false;" onmouseup':"onclick")+'="CKEDITOR.tools.callFunction({clickFn},this);return false;"><span class="cke_button_icon cke_button__{iconName}_icon" style="{style}"'),a=a+'>&nbsp;</span><span id="{id}_label" class="cke_button_label cke_button__{name}_label" aria-hidden="false">{label}</span>{arrowHtml}</a>',
f=CKEDITOR.addTemplate("buttonArrow",'<span class="cke_button_arrow">'+(CKEDITOR.env.hc?"&#9660;":"")+"</span>"),d=CKEDITOR.addTemplate("button",a);CKEDITOR.plugins.add("button",{beforeInit:function(a){a.ui.addHandler(CKEDITOR.UI_BUTTON,CKEDITOR.ui.button.handler)}});CKEDITOR.UI_BUTTON="button";CKEDITOR.ui.button=function(a){CKEDITOR.tools.extend(this,a,{title:a.label,click:a.click||function(b){b.execCommand(a.command)}});this._={}};CKEDITOR.ui.button.handler={create:function(a){return new CKEDITOR.ui.button(a)}};
CKEDITOR.ui.button.prototype={render:function(a,b){function g(){var b=a.mode;if(b){b=this.modes[b]?p[b]!==void 0?p[b]:CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED;b=a.readOnly&&!this.readOnly?CKEDITOR.TRISTATE_DISABLED:b;this.setState(b);this.refresh&&this.refresh()}}var i=CKEDITOR.env,e=this._.id=CKEDITOR.tools.getNextId(),h="",k=this.command,j;this._.editor=a;var m={id:e,button:this,editor:a,focus:function(){CKEDITOR.document.getById(e).focus()},execute:function(){this.button.click(a)},attach:function(a){this.button.attach(a)}},
q=CKEDITOR.tools.addFunction(function(a){if(m.onkey){a=new CKEDITOR.dom.event(a);return m.onkey(m,a.getKeystroke())!==false}}),l=CKEDITOR.tools.addFunction(function(a){var b;m.onfocus&&(b=m.onfocus(m,new CKEDITOR.dom.event(a))!==false);return b}),o=0;m.clickFn=j=CKEDITOR.tools.addFunction(function(){if(o){a.unlockSelection(1);o=0}m.execute();i.iOS&&a.focus()});if(this.modes){var p={};a.on("beforeModeUnload",function(){if(a.mode&&this._.state!=CKEDITOR.TRISTATE_DISABLED)p[a.mode]=this._.state},this);
a.on("activeFilterChange",g,this);a.on("mode",g,this);!this.readOnly&&a.on("readOnly",g,this)}else if(k)if(k=a.getCommand(k)){k.on("state",function(){this.setState(k.state)},this);h=h+(k.state==CKEDITOR.TRISTATE_ON?"on":k.state==CKEDITOR.TRISTATE_DISABLED?"disabled":"off")}if(this.directional)a.on("contentDirChanged",function(b){var e=CKEDITOR.document.getById(this._.id),d=e.getFirst(),b=b.data;b!=a.lang.dir?e.addClass("cke_"+b):e.removeClass("cke_ltr").removeClass("cke_rtl");d.setAttribute("style",
CKEDITOR.skin.getIconStyle(s,b=="rtl",this.icon,this.iconOffset))},this);k||(h=h+"off");var r=this.name||this.command,s=r;if(this.icon&&!/\./.test(this.icon)){s=this.icon;this.icon=null}h={id:e,name:r,iconName:s,label:this.label,cls:this.className||"",state:h,ariaDisabled:h=="disabled"?"true":"false",title:this.title,titleJs:i.gecko&&!i.hc?"":(this.title||"").replace("'",""),hasArrow:this.hasArrow?"true":"false",keydownFn:q,focusFn:l,clickFn:j,style:CKEDITOR.skin.getIconStyle(s,a.lang.dir=="rtl",
this.icon,this.iconOffset),arrowHtml:this.hasArrow?f.output():""};d.output(h,b);if(this.onRender)this.onRender();return m},setState:function(a){if(this._.state==a)return false;this._.state=a;var b=CKEDITOR.document.getById(this._.id);if(b){b.setState(a,"cke_button");a==CKEDITOR.TRISTATE_DISABLED?b.setAttribute("aria-disabled",true):b.removeAttribute("aria-disabled");if(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)}else a==CKEDITOR.TRISTATE_ON?b.setAttribute("aria-pressed",true):b.removeAttribute("aria-pressed");return true}return false},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("dialogui",{onLoad:function(){var a=
function(a){this._||(this._={});this._["default"]=this._.initValue=a["default"]||"";this._.required=a.required||false;for(var b=[this._],c=1;c<arguments.length;c++)b.push(arguments[c]);b.push(true);CKEDITOR.tools.extend.apply(CKEDITOR.tools,b);return this._},f={build:function(a,b,c){return new CKEDITOR.ui.dialog.textInput(a,b,c)}},d={build:function(a,b,c){return new CKEDITOR.ui.dialog[b.type](a,b,c)}},c={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}},b=CKEDITOR.tools.extend({},CKEDITOR.ui.dialog.uiElement.prototype.eventProcessors,{onChange:function(a,b){if(!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=true}this.on("change",
b)}},true),g=/^on([A-Z]\w+)/,i=function(a){for(var b in a)(g.test(b)||b=="title"||b=="type")&&delete a[b];return a};CKEDITOR.tools.extend(CKEDITOR.ui.dialog,{labeledElement:function(b,c,d,g){if(!(arguments.length<4)){var f=a.call(this,c);f.labelId=CKEDITOR.tools.getNextId()+"_label";this._.children=[];var i={role:c.role||"presentation"};if(c.includeLabel)i["aria-labelledby"]=f.labelId;CKEDITOR.ui.dialog.uiElement.call(this,b,c,d,"div",null,i,function(){var a=[],d=c.required?" cke_required":"";if(c.labelLayout!=
"horizontal")a.push('<label class="cke_dialog_ui_labeled_label'+d+'" ',' id="'+f.labelId+'"',f.inputId?' for="'+f.inputId+'"':"",(c.labelStyle?' style="'+c.labelStyle+'"':"")+">",c.label,"</label>",'<div class="cke_dialog_ui_labeled_content"',c.controlStyle?' style="'+c.controlStyle+'"':"",' role="presentation">',g.call(this,b,c),"</div>");else{d={type:"hbox",widths:c.widths,padding:0,children:[{type:"html",html:'<label class="cke_dialog_ui_labeled_label'+d+'" id="'+f.labelId+'" for="'+f.inputId+
'"'+(c.labelStyle?' style="'+c.labelStyle+'"':"")+">"+CKEDITOR.tools.htmlEncode(c.label)+"</span>"},{type:"html",html:'<span class="cke_dialog_ui_labeled_content"'+(c.controlStyle?' style="'+c.controlStyle+'"':"")+">"+g.call(this,b,c)+"</span>"}]};CKEDITOR.dialog._.uiElementBuilders.hbox.build(b,d,a)}return a.join("")})}},textInput:function(b,c,d){if(!(arguments.length<3)){a.call(this,c);var g=this._.inputId=CKEDITOR.tools.getNextId()+"_textInput",f={"class":"cke_dialog_ui_input_"+c.type,id:g,type:c.type};
if(c.validate)this.validate=c.validate;if(c.maxLength)f.maxlength=c.maxLength;if(c.size)f.size=c.size;if(c.inputStyle)f.style=c.inputStyle;var i=this,l=false;b.on("load",function(){i.getInputElement().on("keydown",function(a){a.data.getKeystroke()==13&&(l=true)});i.getInputElement().on("keyup",function(a){if(a.data.getKeystroke()==13&&l){b.getButton("ok")&&setTimeout(function(){b.getButton("ok").click()},0);l=false}},null,null,1E3)});CKEDITOR.ui.dialog.labeledElement.call(this,b,c,d,function(){var a=
['<div class="cke_dialog_ui_input_',c.type,'" role="presentation"'];c.width&&a.push('style="width:'+c.width+'" ');a.push("><input ");f["aria-labelledby"]=this._.labelId;this._.required&&(f["aria-required"]=this._.required);for(var b in f)a.push(b+'="'+f[b]+'" ');a.push(" /></div>");return a.join("")})}},textarea:function(b,c,d){if(!(arguments.length<3)){a.call(this,c);var g=this,f=this._.inputId=CKEDITOR.tools.getNextId()+"_textarea",i={};if(c.validate)this.validate=c.validate;i.rows=c.rows||5;i.cols=
c.cols||20;i["class"]="cke_dialog_ui_input_textarea "+(c["class"]||"");if(typeof c.inputStyle!="undefined")i.style=c.inputStyle;if(c.dir)i.dir=c.dir;CKEDITOR.ui.dialog.labeledElement.call(this,b,c,d,function(){i["aria-labelledby"]=this._.labelId;this._.required&&(i["aria-required"]=this._.required);var a=['<div class="cke_dialog_ui_input_textarea" role="presentation"><textarea id="',f,'" '],b;for(b in i)a.push(b+'="'+CKEDITOR.tools.htmlEncode(i[b])+'" ');a.push(">",CKEDITOR.tools.htmlEncode(g._["default"]),
"</textarea></div>");return a.join("")})}},checkbox:function(b,c,d){if(!(arguments.length<3)){var g=a.call(this,c,{"default":!!c["default"]});if(c.validate)this.validate=c.validate;CKEDITOR.ui.dialog.uiElement.call(this,b,c,d,"span",null,null,function(){var a=CKEDITOR.tools.extend({},c,{id:c.id?c.id+"_checkbox":CKEDITOR.tools.getNextId()+"_checkbox"},true),d=[],f=CKEDITOR.tools.getNextId()+"_label",k={"class":"cke_dialog_ui_checkbox_input",type:"checkbox","aria-labelledby":f};i(a);if(c["default"])k.checked=
"checked";if(typeof a.inputStyle!="undefined")a.style=a.inputStyle;g.checkbox=new CKEDITOR.ui.dialog.uiElement(b,a,d,"input",null,k);d.push(' <label id="',f,'" for="',k.id,'"'+(c.labelStyle?' style="'+c.labelStyle+'"':"")+">",CKEDITOR.tools.htmlEncode(c.label),"</label>");return d.join("")})}},radio:function(b,c,d){if(!(arguments.length<3)){a.call(this,c);if(!this._["default"])this._["default"]=this._.initValue=c.items[0][1];if(c.validate)this.validate=c.valdiate;var g=[],f=this;c.role="radiogroup";
c.includeLabel=true;CKEDITOR.ui.dialog.labeledElement.call(this,b,c,d,function(){for(var a=[],d=[],k=(c.id?c.id:CKEDITOR.tools.getNextId())+"_radio",p=0;p<c.items.length;p++){var r=c.items[p],s=r[2]!==void 0?r[2]:r[0],u=r[1]!==void 0?r[1]:r[0],w=CKEDITOR.tools.getNextId()+"_radio_input",v=w+"_label",w=CKEDITOR.tools.extend({},c,{id:w,title:null,type:null},true),s=CKEDITOR.tools.extend({},w,{title:s},true),t={type:"radio","class":"cke_dialog_ui_radio_input",name:k,value:u,"aria-labelledby":v},y=[];
if(f._["default"]==u)t.checked="checked";i(w);i(s);if(typeof w.inputStyle!="undefined")w.style=w.inputStyle;w.keyboardFocusable=true;g.push(new CKEDITOR.ui.dialog.uiElement(b,w,y,"input",null,t));y.push(" ");new CKEDITOR.ui.dialog.uiElement(b,s,y,"label",null,{id:v,"for":t.id},r[0]);a.push(y.join(""))}new CKEDITOR.ui.dialog.hbox(b,g,a,d);return d.join("")});this._.children=g}},button:function(b,c,d){if(arguments.length){typeof c=="function"&&(c=c(b.getParentEditor()));a.call(this,c,{disabled:c.disabled||
false});CKEDITOR.event.implementOn(this);var g=this;b.on("load",function(){var a=this.getElement();(function(){a.on("click",function(a){g.click();a.data.preventDefault()});a.on("keydown",function(a){if(a.data.getKeystroke()in{32:1}){g.click();a.data.preventDefault()}})})();a.unselectable()},this);var f=CKEDITOR.tools.extend({},c);delete f.style;var i=CKEDITOR.tools.getNextId()+"_label";CKEDITOR.ui.dialog.uiElement.call(this,b,f,d,"a",null,{style:c.style,href:"javascript:void(0)",title:c.label,hidefocus:"true",
"class":c["class"],role:"button","aria-labelledby":i},'<span id="'+i+'" class="cke_dialog_ui_button">'+CKEDITOR.tools.htmlEncode(c.label)+"</span>")}},select:function(b,c,d){if(!(arguments.length<3)){var g=a.call(this,c);if(c.validate)this.validate=c.validate;g.inputId=CKEDITOR.tools.getNextId()+"_select";CKEDITOR.ui.dialog.labeledElement.call(this,b,c,d,function(){var a=CKEDITOR.tools.extend({},c,{id:c.id?c.id+"_select":CKEDITOR.tools.getNextId()+"_select"},true),d=[],f=[],k={id:g.inputId,"class":"cke_dialog_ui_input_select",
"aria-labelledby":this._.labelId};d.push('<div class="cke_dialog_ui_input_',c.type,'" role="presentation"');c.width&&d.push('style="width:'+c.width+'" ');d.push(">");if(c.size!==void 0)k.size=c.size;if(c.multiple!==void 0)k.multiple=c.multiple;i(a);for(var p=0,r;p<c.items.length&&(r=c.items[p]);p++)f.push('<option value="',CKEDITOR.tools.htmlEncode(r[1]!==void 0?r[1]:r[0]).replace(/"/g,"&quot;"),'" /> ',CKEDITOR.tools.htmlEncode(r[0]));if(typeof a.inputStyle!="undefined")a.style=a.inputStyle;g.select=
new CKEDITOR.ui.dialog.uiElement(b,a,d,"select",null,k,f.join(""));d.push("</div>");return d.join("")})}},file:function(b,c,d){if(!(arguments.length<3)){c["default"]===void 0&&(c["default"]="");var g=CKEDITOR.tools.extend(a.call(this,c),{definition:c,buttons:[]});if(c.validate)this.validate=c.validate;b.on("load",function(){CKEDITOR.document.getById(g.frameId).getParent().addClass("cke_dialog_ui_input_file")});CKEDITOR.ui.dialog.labeledElement.call(this,b,c,d,function(){g.frameId=CKEDITOR.tools.getNextId()+
"_fileInput";var a=['<iframe frameborder="0" allowtransparency="0" class="cke_dialog_ui_input_file" role="presentation" id="',g.frameId,'" title="',c.label,'" src="javascript:void('];a.push(CKEDITOR.env.ie?"(function(){"+encodeURIComponent("document.open();("+CKEDITOR.tools.fixDomain+")();document.close();")+"})()":"0");a.push(')"></iframe>');return a.join("")})}},fileButton:function(b,c,d){var g=this;if(!(arguments.length<3)){a.call(this,c);if(c.validate)this.validate=c.validate;var f=CKEDITOR.tools.extend({},
c),i=f.onClick;f.className=(f.className?f.className+" ":"")+"cke_dialog_ui_button";f.onClick=function(a){var d=c["for"];if(!i||i.call(this,a)!==false){b.getContentElement(d[0],d[1]).submit();this.disable()}};b.on("load",function(){b.getContentElement(c["for"][0],c["for"][1])._.buttons.push(g)});CKEDITOR.ui.dialog.button.call(this,b,f,d)}},html:function(){var a=/^\s*<[\w:]+\s+([^>]*)?>/,b=/^(\s*<[\w:]+(?:\s+[^>]*)?)((?:.|\r|\n)+)$/,c=/\/$/;return function(d,g,f){if(!(arguments.length<3)){var i=[],
o=g.html;o.charAt(0)!="<"&&(o="<span>"+o+"</span>");var p=g.focus;if(p){var r=this.focus;this.focus=function(){(typeof p=="function"?p:r).call(this);this.fire("focus")};if(g.isFocusable)this.isFocusable=this.isFocusable;this.keyboardFocusable=true}CKEDITOR.ui.dialog.uiElement.call(this,d,g,i,"span",null,null,"");i=i.join("").match(a);o=o.match(b)||["","",""];if(c.test(o[1])){o[1]=o[1].slice(0,-1);o[2]="/"+o[2]}f.push([o[1]," ",i[1]||"",o[2]].join(""))}}}(),fieldset:function(a,b,c,d,g){var f=g.label;
this._={children:b};CKEDITOR.ui.dialog.uiElement.call(this,a,g,d,"fieldset",null,null,function(){var a=[];f&&a.push("<legend"+(g.labelStyle?' style="'+g.labelStyle+'"':"")+">"+f+"</legend>");for(var b=0;b<c.length;b++)a.push(c[b]);return a.join("")})}},true);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);b.getChildCount()<
1?(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||a.getChildCount()<1?"":a.getChild(0).getText()},eventProcessors:b},true);CKEDITOR.ui.dialog.button.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,{click:function(){return!this._.disabled?this.fire("click",{dialog:this._.dialog}):false},enable:function(){this._.disabled=false;var a=this.getElement();a&&a.removeClass("cke_disabled")},
disable:function(){this._.disabled=true;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)})}},true),accessKeyUp:function(){this.click()},accessKeyDown:function(){this.focus()},keyboardFocusable:true},true);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();if(b){b.$.focus();b.$.select()}},0)},accessKeyUp:function(){this.select()},setValue:function(a){!a&&(a="");return CKEDITOR.ui.dialog.uiElement.prototype.setValue.apply(this,
arguments)},keyboardFocusable:true},c,true);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,c){var d=new CKEDITOR.dom.element("option",this.getDialog().getParentEditor().document),g=this.getInputElement().$;d.$.text=a;d.$.value=b===void 0||b===null?a:b;c===void 0||c===null?CKEDITOR.env.ie?g.add(d.$):g.add(d.$,
null):g.add(d.$,c);return this},remove:function(a){this.getInputElement().$.remove(a);return this},clear:function(){for(var a=this.getInputElement().$;a.length>0;)a.remove(0);return this},keyboardFocusable:true},c,true);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,c){if(!CKEDITOR.env.ie||CKEDITOR.env.version>8)return b.onChange.apply(this,arguments);a.on("load",function(){var a=this._.checkbox.getElement();a.on("propertychange",function(b){b=b.data.$;b.propertyName=="checked"&&this.fire("change",{value:a.$.checked})},this)},this);this.on("change",c);return null}},keyboardFocusable:true},c,true);CKEDITOR.ui.dialog.radio.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,
{setValue:function(a,b){for(var c=this._.children,d,g=0;g<c.length&&(d=c[g]);g++)d.getElement().$.checked=d.getValue()==a;!b&&this.fire("change",{value:a})},getValue:function(){for(var a=this._.children,b=0;b<a.length;b++)if(a[b].getElement().$.checked)return a[b].getValue();return null},accessKeyUp:function(){var a=this._.children,b;for(b=0;b<a.length;b++)if(a[b].getElement().$.checked){a[b].getElement().focus();return}a[0].getElement().focus()},eventProcessors:{onChange:function(a,c){if(CKEDITOR.env.ie){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.$;a.propertyName=="checked"&&this.$.checked&&b.fire("change",{value:this.getAttribute("value")})})},this);this.on("change",c)}else return b.onChange.apply(this,arguments);return null}}},c,true);CKEDITOR.ui.dialog.file.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.labeledElement,c,{getInputElement:function(){var a=CKEDITOR.document.getById(this._.frameId).getFrameDocument();
return a.$.forms.length>0?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+)/,c,d=function(a,b,c,e){a.on("formLoaded",function(){a.getInputElement().on(c,e,a)})},g;for(g in a)if(c=g.match(b))this.eventProcessors[g]?this.eventProcessors[g].call(this,this._.dialog,a[g]):d(this,this._.dialog,
c[1].toLowerCase(),a[g]);return this},reset:function(){function a(){c.$.open();var e="";d.size&&(e=d.size-(CKEDITOR.env.ie?7:0));var s=b.frameId+"_input";c.$.write(['<html dir="'+o+'" lang="'+p+'"><head><title></title></head><body style="margin: 0; overflow: hidden; background: transparent;">','<form enctype="multipart/form-data" method="POST" dir="'+o+'" lang="'+p+'" action="',CKEDITOR.tools.htmlEncode(d.action),'"><label id="',b.labelId,'" for="',s,'" style="display:none">',CKEDITOR.tools.htmlEncode(d.label),
'</label><input style="width:100%" id="',s,'" aria-labelledby="',b.labelId,'" type="file" name="',CKEDITOR.tools.htmlEncode(d.id||"cke_upload"),'" size="',CKEDITOR.tools.htmlEncode(e>0?e:""),'" /></form></body></html><script>',CKEDITOR.env.ie?"("+CKEDITOR.tools.fixDomain+")();":"","window.parent.CKEDITOR.tools.callFunction("+f+");","window.onbeforeunload = function() {window.parent.CKEDITOR.tools.callFunction("+i+")}","<\/script>"].join(""));c.$.close();for(e=0;e<g.length;e++)g[e].enable()}var b=
this._,c=CKEDITOR.document.getById(b.frameId).getFrameDocument(),d=b.definition,g=b.buttons,f=this.formLoadedNumber,i=this.formUnloadNumber,o=b.dialog._.editor.lang.dir,p=b.dialog._.editor.langCode;if(!f){f=this.formLoadedNumber=CKEDITOR.tools.addFunction(function(){this.fire("formLoaded")},this);i=this.formUnloadNumber=CKEDITOR.tools.addFunction(function(){this.getInputElement().clearCustomData()},this);this.getDialog()._.editor.on("destroy",function(){CKEDITOR.tools.removeFunction(f);CKEDITOR.tools.removeFunction(i)})}CKEDITOR.env.gecko?
setTimeout(a,500):a()},getValue:function(){return this.getInputElement().$.value||""},setInitValue:function(){this._.initValue=""},eventProcessors:{onChange:function(a,b){if(!this._.domOnChangeRegistered){this.on("formLoaded",function(){this.getInputElement().on("change",function(){this.fire("change",{value:this.getValue()})},this)},this);this._.domOnChangeRegistered=true}this.on("change",b)}},keyboardFocusable:true},true);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",f);CKEDITOR.dialog.addUIElement("password",f);CKEDITOR.dialog.addUIElement("textarea",d);CKEDITOR.dialog.addUIElement("checkbox",d);CKEDITOR.dialog.addUIElement("radio",d);CKEDITOR.dialog.addUIElement("button",d);CKEDITOR.dialog.addUIElement("select",d);CKEDITOR.dialog.addUIElement("file",d);CKEDITOR.dialog.addUIElement("fileButton",d);CKEDITOR.dialog.addUIElement("html",d);CKEDITOR.dialog.addUIElement("fieldset",
{build:function(a,b,c){for(var d=b.children,g,f=[],i=[],o=0;o<d.length&&(g=d[o]);o++){var p=[];f.push(p);i.push(CKEDITOR.dialog._.uiElementBuilders[g.type].build(a,g,p))}return new CKEDITOR.ui.dialog[b.type](a,i,f,c,b)}})}});CKEDITOR.DIALOG_RESIZE_NONE=0;CKEDITOR.DIALOG_RESIZE_WIDTH=1;CKEDITOR.DIALOG_RESIZE_HEIGHT=2;CKEDITOR.DIALOG_RESIZE_BOTH=3;(function(){function a(){for(var a=this._.tabIdList.length,b=CKEDITOR.tools.indexOf(this._.tabIdList,this._.currentTabId)+a,c=b-1;c>b-a;c--)if(this._.tabs[this._.tabIdList[c%
a]][0].$.offsetHeight)return this._.tabIdList[c%a];return null}function f(){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 d(a,b){for(var c=a.$.getElementsByTagName("input"),e=0,d=c.length;e<d;e++){var g=new CKEDITOR.dom.element(c[e]);if(g.getAttribute("type").toLowerCase()=="text")if(b){g.setAttribute("value",g.getCustomData("fake_value")||
"");g.removeCustomData("fake_value")}else{g.setCustomData("fake_value",g.getAttribute("value"));g.setAttribute("value","")}}}function c(a,b){var c=this.getInputElement();c&&(a?c.removeAttribute("aria-invalid"):c.setAttribute("aria-invalid",true));a||(this.select?this.select():this.focus());b&&alert(b);this.fire("validated",{valid:a,msg:b})}function b(){var a=this.getInputElement();a&&a.removeAttribute("aria-invalid")}function g(a){var a=CKEDITOR.dom.element.createFromHtml(CKEDITOR.addTemplate("dialog",
p).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":""})),b=a.getChild([0,0,0,0,0]),c=b.getChild(0),e=b.getChild(1);if(CKEDITOR.env.ie&&!CKEDITOR.env.quirks){var d="javascript:void(function(){"+encodeURIComponent("document.open();("+CKEDITOR.tools.fixDomain+")();document.close();")+"}())";CKEDITOR.dom.element.createFromHtml('<iframe frameBorder="0" class="cke_iframe_shim" src="'+
d+'" tabIndex="-1"></iframe>').appendTo(b.getParent())}c.unselectable();e.unselectable();return{element:a,parts:{dialog:a.getChild(0),title:c,close:e,tabs:b.getChild(2),contents:b.getChild([3,0,0,0]),footer:b.getChild([3,0,1,0])}}}function i(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 e(a){function b(){a.layout()}var c=CKEDITOR.document.getWindow();c.on("resize",b);a.on("hide",function(){c.removeListener("resize",b)})}function h(a,b){this._={dialog:a};CKEDITOR.tools.extend(this,b)}function k(a){function b(c){var i=a.getSize(),k=CKEDITOR.document.getWindow().getViewPaneSize(),j=c.data.$.screenX,o=c.data.$.screenY,m=j-e.x,p=o-e.y;e={x:j,y:o};
d.x=d.x+m;d.y=d.y+p;a.move(d.x+h[3]<f?-h[3]:d.x-h[1]>k.width-i.width-f?k.width-i.width+(g.lang.dir=="rtl"?0:h[1]):d.x,d.y+h[0]<f?-h[0]:d.y-h[2]>k.height-i.height-f?k.height-i.height+h[2]:d.y,1);c.data.preventDefault()}function c(){CKEDITOR.document.removeListener("mousemove",b);CKEDITOR.document.removeListener("mouseup",c);if(CKEDITOR.env.ie6Compat){var a=n.getChild(0).getFrameDocument();a.removeListener("mousemove",b);a.removeListener("mouseup",c)}}var e=null,d=null,g=a.getParentEditor(),f=g.config.dialog_magnetDistance,
h=CKEDITOR.skin.margins||[0,0,0,0];typeof f=="undefined"&&(f=20);a.parts.title.on("mousedown",function(g){e={x:g.data.$.screenX,y:g.data.$.screenY};CKEDITOR.document.on("mousemove",b);CKEDITOR.document.on("mouseup",c);d=a.getPosition();if(CKEDITOR.env.ie6Compat){var f=n.getChild(0).getFrameDocument();f.on("mousemove",b);f.on("mouseup",c)}g.data.preventDefault()},a)}function j(a){var b,c;function e(d){var m=h.lang.dir=="rtl",p=o.width,n=o.height,r=p+(d.data.$.screenX-b)*(m?-1:1)*(a._.moved?1:2),u=
n+(d.data.$.screenY-c)*(a._.moved?1:2),l=a._.element.getFirst(),l=m&&l.getComputedStyle("right"),s=a.getPosition();s.y+u>j.height&&(u=j.height-s.y);if((m?l:s.x)+r>j.width)r=j.width-(m?l:s.x);if(f==CKEDITOR.DIALOG_RESIZE_WIDTH||f==CKEDITOR.DIALOG_RESIZE_BOTH)p=Math.max(g.minWidth||0,r-i);if(f==CKEDITOR.DIALOG_RESIZE_HEIGHT||f==CKEDITOR.DIALOG_RESIZE_BOTH)n=Math.max(g.minHeight||0,u-k);a.resize(p,n);a._.moved||a.layout();d.data.preventDefault()}function d(){CKEDITOR.document.removeListener("mouseup",
d);CKEDITOR.document.removeListener("mousemove",e);if(m){m.remove();m=null}if(CKEDITOR.env.ie6Compat){var a=n.getChild(0).getFrameDocument();a.removeListener("mouseup",d);a.removeListener("mousemove",e)}}var g=a.definition,f=g.resizable;if(f!=CKEDITOR.DIALOG_RESIZE_NONE){var h=a.getParentEditor(),i,k,j,o,m,p=CKEDITOR.tools.addFunction(function(g){o=a.getSize();var f=a.parts.contents;if(f.$.getElementsByTagName("iframe").length){m=CKEDITOR.dom.element.createFromHtml('<div class="cke_dialog_resize_cover" style="height: 100%; position: absolute; width: 100%;"></div>');
f.append(m)}k=o.height-a.parts.contents.getSize("height",!(CKEDITOR.env.gecko||CKEDITOR.env.ie&&CKEDITOR.env.quirks));i=o.width-a.parts.contents.getSize("width",1);b=g.screenX;c=g.screenY;j=CKEDITOR.document.getWindow().getViewPaneSize();CKEDITOR.document.on("mousemove",e);CKEDITOR.document.on("mouseup",d);if(CKEDITOR.env.ie6Compat){f=n.getChild(0).getFrameDocument();f.on("mousemove",e);f.on("mouseup",d)}g.preventDefault&&g.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('<div class="cke_resizer'+b+" cke_resizer_"+h.lang.dir+'" title="'+CKEDITOR.tools.htmlEncode(h.lang.common.resize)+'" onmousedown="CKEDITOR.tools.callFunction('+p+', event )">'+(h.lang.dir=="ltr"?"◢":"◣")+"</div>");a.parts.footer.append(b,1)});h.on("destroy",function(){CKEDITOR.tools.removeFunction(p)})}}function m(a){a.data.preventDefault(1)}function q(a){var b=CKEDITOR.document.getWindow(),
c=a.config,e=c.dialog_backgroundCoverColor||"white",d=c.dialog_backgroundCoverOpacity,g=c.baseFloatZIndex,c=CKEDITOR.tools.genKey(e,d,g),f=y[c];if(f)f.show();else{g=['<div tabIndex="-1" style="position: ',CKEDITOR.env.ie6Compat?"absolute":"fixed","; z-index: ",g,"; top: 0px; left: 0px; ",!CKEDITOR.env.ie6Compat?"background-color: "+e:"",'" class="cke_dialog_background_cover">'];if(CKEDITOR.env.ie6Compat){e="<html><body style=\\'background-color:"+e+";\\'></body></html>";g.push('<iframe hidefocus="true" frameborder="0" id="cke_dialog_background_iframe" src="javascript:');
g.push("void((function(){"+encodeURIComponent("document.open();("+CKEDITOR.tools.fixDomain+")();document.write( '"+e+"' );document.close();")+"})())");g.push('" style="position:absolute;left:0;top:0;width:100%;height: 100%;filter: progid:DXImageTransform.Microsoft.Alpha(opacity=0)"></iframe>')}g.push("</div>");f=CKEDITOR.dom.element.createFromHtml(g.join(""));f.setOpacity(d!==void 0?d:0.5);f.on("keydown",m);f.on("keypress",m);f.on("keyup",m);f.appendTo(CKEDITOR.document.getBody());y[c]=f}a.focusManager.add(f);
n=f;var a=function(){var a=b.getViewPaneSize();f.setStyles({width:a.width+"px",height:a.height+"px"})},h=function(){var a=b.getScrollPosition(),c=CKEDITOR.dialog._.currentTop;f.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)}};t=a;b.on("resize",a);a();(!CKEDITOR.env.mac||!CKEDITOR.env.webkit)&&f.focus();if(CKEDITOR.env.ie6Compat){var i=function(){h();arguments.callee.prevScrollHandler.apply(this,arguments)};b.$.setTimeout(function(){i.prevScrollHandler=
window.onscroll||function(){};window.onscroll=i},0);h()}}function l(a){if(n){a.focusManager.remove(n);a=CKEDITOR.document.getWindow();n.hide();a.removeListener("resize",t);CKEDITOR.env.ie6Compat&&a.$.setTimeout(function(){window.onscroll=window.onscroll&&window.onscroll.prevScrollHandler||null},0);t=null}}var o=CKEDITOR.tools.cssLength,p='<div class="cke_reset_all {editorId} {editorDialogClass} {hidpi}" dir="{langDir}" lang="{langCode}" role="dialog" aria-labelledby="cke_dialog_title_{id}"><table class="cke_dialog '+
CKEDITOR.env.cssClass+' cke_{langDir}" style="position:absolute" role="presentation"><tr><td role="presentation"><div class="cke_dialog_body" role="presentation"><div id="cke_dialog_title_{id}" class="cke_dialog_title" role="presentation"></div><a id="cke_dialog_close_button_{id}" class="cke_dialog_close_button" href="javascript:void(0)" title="{closeTitle}" role="button"><span class="cke_label">X</span></a><div id="cke_dialog_tabs_{id}" class="cke_dialog_tabs" role="tablist"></div><table class="cke_dialog_contents" role="presentation"><tr><td id="cke_dialog_contents_{id}" class="cke_dialog_contents_body" role="presentation"></td></tr><tr><td id="cke_dialog_footer_{id}" class="cke_dialog_footer" role="presentation"></td></tr></table></div></td></tr></table></div>';
CKEDITOR.dialog=function(e,d){function h(){var a=t._.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 i(a){var b=t._.focusList,a=a||0;if(!(b.length<1)){var c=t._.currentFocusIndex;try{b[c].getInputElement().$.blur()}catch(e){}for(var d=c=(c+a+b.length)%b.length;a&&!b[d].isFocusable();){d=(d+a+b.length)%b.length;if(d==c)break}b[d].focus();b[d].type=="text"&&b[d].select()}}function o(b){if(t==
CKEDITOR.dialog._.currentTop){var c=b.data.getKeystroke(),d=e.lang.dir=="rtl";q=w=0;if(c==9||c==CKEDITOR.SHIFT+9){c=c==CKEDITOR.SHIFT+9;if(t._.tabBarMode){c=c?a.call(t):f.call(t);t.selectPage(c);t._.tabs[c][0].focus()}else i(c?-1:1);q=1}else if(c==CKEDITOR.ALT+121&&!t._.tabBarMode&&t.getPageCount()>1){t._.tabBarMode=true;t._.tabs[t._.currentTabId][0].focus();q=1}else if((c==37||c==39)&&t._.tabBarMode){c=c==(d?39:37)?a.call(t):f.call(t);t.selectPage(c);t._.tabs[c][0].focus();q=1}else if((c==13||c==
32)&&t._.tabBarMode){this.selectPage(this._.currentTabId);this._.tabBarMode=false;this._.currentFocusIndex=-1;i(1);q=1}else if(c==13){c=b.data.getTarget();if(!c.is("a","button","select","textarea")&&(!c.is("input")||c.$.type!="button")){(c=this.getButton("ok"))&&CKEDITOR.tools.setTimeout(c.click,0,c);q=1}w=1}else if(c==27){(c=this.getButton("cancel"))?CKEDITOR.tools.setTimeout(c.click,0,c):this.fire("cancel",{hide:true}).hide!==false&&this.hide();w=1}else return;m(b)}}function m(a){q?a.data.preventDefault(1):
w&&a.data.stopPropagation()}var p=CKEDITOR.dialog._.dialogDefinitions[d],n=CKEDITOR.tools.clone(r),u=e.config.dialog_buttonsOrder||"OS",l=e.lang.dir,s={},q,w;(u=="OS"&&CKEDITOR.env.mac||u=="rtl"&&l=="ltr"||u=="ltr"&&l=="rtl")&&n.buttons.reverse();p=CKEDITOR.tools.extend(p(e),n);p=CKEDITOR.tools.clone(p);p=new v(this,p);n=g(e);this._={editor:e,element:n.element,name:d,contentSize:{width:0,height:0},size:{width:0,height:0},contents:{},buttons:{},accessKeyMap:{},tabs:{},tabIdList:[],currentTabId:null,
currentTabIndex:null,pageCount:0,lastTab:null,tabBarMode:false,focusList:[],currentFocusIndex:0,hasFocus:false};this.parts=n.parts;CKEDITOR.tools.setTimeout(function(){e.fire("ariaWidget",this.parts.contents)},0,this);n={position:CKEDITOR.env.ie6Compat?"absolute":"fixed",top:0,visibility:"hidden"};n[l=="rtl"?"right":"left"]=0;this.parts.dialog.setStyles(n);CKEDITOR.event.call(this);this.definition=p=CKEDITOR.fire("dialogDefinition",{name:d,definition:p},e).definition;if(!("removeDialogTabs"in e._)&&
e.config.removeDialogTabs){n=e.config.removeDialogTabs.split(";");for(l=0;l<n.length;l++){u=n[l].split(":");if(u.length==2){var z=u[0];s[z]||(s[z]=[]);s[z].push(u[1])}}e._.removeDialogTabs=s}if(e._.removeDialogTabs&&(s=e._.removeDialogTabs[d]))for(l=0;l<s.length;l++)p.removeContents(s[l]);if(p.onLoad)this.on("load",p.onLoad);if(p.onShow)this.on("show",p.onShow);if(p.onHide)this.on("hide",p.onHide);if(p.onOk)this.on("ok",function(a){e.fire("saveSnapshot");setTimeout(function(){e.fire("saveSnapshot")},
0);if(p.onOk.call(this,a)===false)a.data.hide=false});if(p.onCancel)this.on("cancel",function(a){if(p.onCancel.call(this,a)===false)a.data.hide=false});var t=this,y=function(a){var b=t._.contents,c=false,e;for(e in b)for(var d in b[e])if(c=a.call(this,b[e][d]))return};this.on("ok",function(a){y(function(b){if(b.validate){var e=b.validate(this),d=typeof e=="string"||e===false;if(d){a.data.hide=false;a.stop()}c.call(b,!d,typeof e=="string"?e:void 0);return d}})},this,null,0);this.on("cancel",function(a){y(function(b){if(b.isChanged()){if(!e.config.dialog_noConfirmCancel&&
!confirm(e.lang.common.confirmCancel))a.data.hide=false;return true}})},this,null,0);this.parts.close.on("click",function(a){this.fire("cancel",{hide:true}).hide!==false&&this.hide();a.data.preventDefault()},this);this.changeFocus=i;var x=this._.element;e.focusManager.add(x,1);this.on("show",function(){x.on("keydown",o,this);if(CKEDITOR.env.gecko)x.on("keypress",m,this)});this.on("hide",function(){x.removeListener("keydown",o);CKEDITOR.env.gecko&&x.removeListener("keypress",m);y(function(a){b.apply(a)})});
this.on("iframeAdded",function(a){(new CKEDITOR.dom.document(a.data.iframe.$.contentWindow.document)).on("keydown",o,this,null,0)});this.on("show",function(){h();if(e.config.dialog_startupFocusTab&&t._.pageCount>1){t._.tabBarMode=true;t._.tabs[t._.currentTabId][0].focus()}else if(!this._.hasFocus){this._.currentFocusIndex=-1;if(p.onFocus){var a=p.onFocus.call(this);a&&a.focus()}else i(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);k(this);j(this);(new CKEDITOR.dom.text(p.title,CKEDITOR.document)).appendTo(this.parts.title);for(l=0;l<p.contents.length;l++)(s=p.contents[l])&&this.addPage(s);this.parts.tabs.on("click",function(a){var b=a.data.getTarget();if(b.hasClass("cke_dialog_tab")){b=b.$.id;this.selectPage(b.substring(4,b.lastIndexOf("_")));if(this._.tabBarMode){this._.tabBarMode=false;this._.currentFocusIndex=-1;i(1)}a.data.preventDefault()}},this);l=[];s=CKEDITOR.dialog._.uiElementBuilders.hbox.build(this,
{type:"hbox",className:"cke_dialog_footer_buttons",widths:[],children:p.buttons},l).getChild();this.parts.footer.setHtml(l.join(""));for(l=0;l<s.length;l++)this._.buttons[s[l].id]=s[l]};CKEDITOR.dialog.prototype={destroy:function(){this.hide();this._.element.remove()},resize:function(){return function(a,b){if(!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"});if(this._.editor.lang.dir=="rtl"&&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 e=this._.element.getFirst(),d=this._.editor.lang.dir==
"rtl",g=e.getComputedStyle("position")=="fixed";CKEDITOR.env.ie&&e.setStyle("zoom","100%");if(!g||!this._.position||!(this._.position.x==a&&this._.position.y==b)){this._.position={x:a,y:b};if(!g){g=CKEDITOR.document.getWindow().getScrollPosition();a=a+g.x;b=b+g.y}if(d){g=this.getSize();a=CKEDITOR.document.getWindow().getViewPaneSize().width-g.width-a}b={top:(b>0?b:0)+"px"};b[d?"right":"left"]=(a>0?a:0)+"px";e.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.appendTo(CKEDITOR.document.getBody()):a.setStyle("display","block");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);if(CKEDITOR.dialog._.currentZIndex===null)CKEDITOR.dialog._.currentZIndex=this._.editor.config.baseFloatZIndex;
this._.element.getFirst().setStyle("z-index",CKEDITOR.dialog._.currentZIndex=CKEDITOR.dialog._.currentZIndex+10);if(CKEDITOR.dialog._.currentTop===null){CKEDITOR.dialog._.currentTop=this;this._.parentDialog=null;q(this._.editor)}else{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",z);a.on("keyup",B);this._.hasFocus=false;for(var c in b.contents)if(b.contents[c]){var a=
b.contents[c],d=this._.tabs[a.id],g=a.requiredContent,f=0;if(d){for(var h in this._.contents[a.id]){var i=this._.contents[a.id][h];if(!(i.type=="hbox"||i.type=="vbox"||!i.getInputElement()))if(i.requiredContent&&!this._.editor.activeFilter.check(i.requiredContent))i.disable();else{i.enable();f++}}!f||g&&!this._.editor.activeFilter.check(g)?d[0].addClass("cke_dialog_tab_disabled"):d[0].removeClass("cke_dialog_tab_disabled")}}CKEDITOR.tools.setTimeout(function(){this.layout();e(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(),e=(c.width-b.width)/2,d=(c.height-b.height)/2;CKEDITOR.env.ie6Compat||(b.height+(d>0?d:0)>c.height||b.width+(e>0?e:0)>c.width?a.setStyle("position",
"absolute"):a.setStyle("position","fixed"));this.move(this._.moved?this._.position.x:e,this._.moved?this._.position.y:d)},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(H(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 l(this._.editor);if(CKEDITOR.dialog._.currentTop=this._.parentDialog)CKEDITOR.dialog._.currentZIndex=CKEDITOR.dialog._.currentZIndex-10;else{CKEDITOR.dialog._.currentZIndex=null;a.removeListener("keydown",z);a.removeListener("keyup",B);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()})}},addPage:function(a){if(!a.requiredContent||this._.editor.filter.check(a.requiredContent)){for(var b=[],c=a.label?' title="'+CKEDITOR.tools.htmlEncode(a.label)+'"':"",e=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),d=this._.contents[a.id]={},g=e.getChild(),f=0;e=g.shift();){!e.notAllowed&&(e.type!="hbox"&&e.type!="vbox")&&f++;d[e.id]=
e;typeof e.getChild=="function"&&g.push.apply(g,e.getChild())}if(!f)a.hidden=true;b=CKEDITOR.dom.element.createFromHtml(b.join(""));b.setAttribute("role","tabpanel");e=CKEDITOR.env;d="cke_"+a.id+"_"+CKEDITOR.tools.getNextNumber();c=CKEDITOR.dom.element.createFromHtml(['<a class="cke_dialog_tab"',this._.pageCount>0?" cke_last":"cke_first",c,a.hidden?' style="display:none"':"",' id="',d,'"',e.gecko&&!e.hc?"":' href="javascript:void(0)"',' tabIndex="-1" hidefocus="true" role="tab">',a.label,"</a>"].join(""));
b.setAttribute("aria-labelledby",d);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);if(a.accessKey){C(this,this,"CTRL+"+a.accessKey,I,F);this._.accessKeyMap["CTRL+"+a.accessKey]=a.id}}},selectPage:function(a){if(this._.currentTabId!=a&&!this._.tabs[a][0].hasClass("cke_dialog_tab_disabled")&&this.fire("selectPage",{page:a,currentPage:this._.currentTabId})!==
false){for(var b in this._.tabs){var c=this._.tabs[b][0],e=this._.tabs[b][1];if(b!=a){c.removeClass("cke_dialog_tab_selected");e.hide()}e.setAttribute("aria-hidden",b!=a)}var g=this._.tabs[a];g[0].addClass("cke_dialog_tab_selected");if(CKEDITOR.env.ie6Compat||CKEDITOR.env.ie7Compat){d(g[1]);g[1].show();setTimeout(function(){d(g[1],1)},0)}else g[1].show();this._.currentTabId=a;this._.currentTabIndex=CKEDITOR.tools.indexOf(this._.tabIdList,a)}},updateStyle:function(){this.parts.dialog[(this._.pageCount===
1?"add":"remove")+"Class"]("cke_single_page")},hidePage:function(b){var c=this._.tabs[b]&&this._.tabs[b][0];if(c&&this._.pageCount!=1&&c.isVisible()){b==this._.currentTabId&&this.selectPage(a.call(this));c.hide();this._.pageCount--;this.updateStyle()}},showPage:function(a){if(a=this._.tabs[a]&&this._.tabs[a][0]){a.show();this._.pageCount++;this.updateStyle()}},getElement:function(){return this._.element},getName:function(){return this._.name},getContentElement:function(a,b){var c=this._.contents[a];
return c&&c[b]},getValueOf:function(a,b){return this.getContentElement(a,b).getValue()},setValueOf:function(a,b,c){return this.getContentElement(a,b).setValue(c)},getButton:function(a){return this._.buttons[a]},click:function(a){return this._.buttons[a].click()},disableButton:function(a){return this._.buttons[a].disable()},enableButton:function(a){return this._.buttons[a].enable()},getPageCount:function(){return this._.pageCount},getParentEditor:function(){return this._.editor},getSelectedElement:function(){return this.getParentEditor().getSelection().getSelectedElement()},
addFocusable:function(a,b){if(typeof b=="undefined"){b=this._.focusList.length;this._.focusList.push(new i(this,a,b))}else{this._.focusList.splice(b,0,new i(this,a,b));for(var c=b+1;c<this._.focusList.length;c++)this._.focusList[c].focusIndex++}}};CKEDITOR.tools.extend(CKEDITOR.dialog,{add:function(a,b){if(!this._.dialogDefinitions[a]||typeof b=="function")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(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;a.fire("ok",{hide:true}).hide!==false&&a.hide()}},b,true)};a.type="button";a.override=function(b){return CKEDITOR.tools.extend(function(c){return a(c,b)},{type:"button"},true)};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;a.fire("cancel",{hide:true}).hide!==false&&a.hide()}},b,true)};a.type="button";a.override=function(b){return CKEDITOR.tools.extend(function(c){return a(c,b)},{type:"button"},true)};return a}(),addUIElement:function(a,b){this._.uiElementBuilders[a]=b}});CKEDITOR.dialog._={uiElementBuilders:{},
dialogDefinitions:{},currentTop:null,currentZIndex:null};CKEDITOR.event.implementOn(CKEDITOR.dialog);CKEDITOR.event.implementOn(CKEDITOR.dialog.prototype);var r={resizable:CKEDITOR.DIALOG_RESIZE_BOTH,minWidth:600,minHeight:400,buttons:[CKEDITOR.dialog.okButton,CKEDITOR.dialog.cancelButton]},s=function(a,b,c){for(var e=0,d;d=a[e];e++){if(d.id==b)return d;if(c&&d[c])if(d=s(d[c],b,c))return d}return null},u=function(a,b,c,e,d){if(c){for(var g=0,f;f=a[g];g++){if(f.id==c){a.splice(g,0,b);return b}if(e&&
f[e])if(f=u(f[e],b,c,e,true))return f}if(d)return null}a.push(b);return b},w=function(a,b,c){for(var e=0,d;d=a[e];e++){if(d.id==b)return a.splice(e,1);if(c&&d[c])if(d=w(d[c],b,c))return d}return null},v=function(a,b){this.dialog=a;for(var c=b.contents,e=0,d;d=c[e];e++)c[e]=d&&new h(a,d);CKEDITOR.tools.extend(this,b)};v.prototype={getContents:function(a){return s(this.contents,a)},getButton:function(a){return s(this.buttons,a)},addContents:function(a,b){return u(this.contents,a,b)},addButton:function(a,
b){return u(this.buttons,a,b)},removeContents:function(a){w(this.contents,a)},removeButton:function(a){w(this.buttons,a)}};h.prototype={get:function(a){return s(this.elements,a,"children")},add:function(a,b){return u(this.elements,a,b,"children")},remove:function(a){w(this.elements,a,"children")}};var t,y={},n,x={},z=function(a){var b=a.data.$.ctrlKey||a.data.$.metaKey,c=a.data.$.altKey,e=a.data.$.shiftKey,d=String.fromCharCode(a.data.$.keyCode);if((b=x[(b?"CTRL+":"")+(c?"ALT+":"")+(e?"SHIFT+":"")+
d])&&b.length){b=b[b.length-1];b.keydown&&b.keydown.call(b.uiElement,b.dialog,b.key);a.data.preventDefault()}},B=function(a){var b=a.data.$.ctrlKey||a.data.$.metaKey,c=a.data.$.altKey,e=a.data.$.shiftKey,d=String.fromCharCode(a.data.$.keyCode);if((b=x[(b?"CTRL+":"")+(c?"ALT+":"")+(e?"SHIFT+":"")+d])&&b.length){b=b[b.length-1];if(b.keyup){b.keyup.call(b.uiElement,b.dialog,b.key);a.data.preventDefault()}}},C=function(a,b,c,e,d){(x[c]||(x[c]=[])).push({uiElement:a,dialog:b,key:c,keyup:d||a.accessKeyUp,
keydown:e||a.accessKeyDown})},H=function(a){for(var b in x){for(var c=x[b],e=c.length-1;e>=0;e--)(c[e].dialog==a||c[e].uiElement==a)&&c.splice(e,1);c.length===0&&delete x[b]}},F=function(a,b){a._.accessKeyMap[b]&&a.selectPage(a._.accessKeyMap[b])},I=function(){};(function(){CKEDITOR.ui.dialog={uiElement:function(a,b,c,e,d,g,f){if(!(arguments.length<4)){var h=(e.call?e(b):e)||"div",i=["<",h," "],k=(d&&d.call?d(b):d)||{},j=(g&&g.call?g(b):g)||{},o=(f&&f.call?f.call(this,a,b):f)||"",m=this.domId=j.id||
CKEDITOR.tools.getNextId()+"_uiElement";if(b.requiredContent&&!a.getParentEditor().filter.check(b.requiredContent)){k.display="none";this.notAllowed=true}j.id=m;var p={};b.type&&(p["cke_dialog_ui_"+b.type]=1);b.className&&(p[b.className]=1);if(b.disabled)p.cke_disabled=1;for(var n=j["class"]&&j["class"].split?j["class"].split(" "):[],m=0;m<n.length;m++)n[m]&&(p[n[m]]=1);n=[];for(m in p)n.push(m);j["class"]=n.join(" ");if(b.title)j.title=b.title;p=(b.style||"").split(";");if(b.align){n=b.align;k["margin-left"]=
n=="left"?0:"auto";k["margin-right"]=n=="right"?0:"auto"}for(m in k)p.push(m+":"+k[m]);b.hidden&&p.push("display:none");for(m=p.length-1;m>=0;m--)p[m]===""&&p.splice(m,1);if(p.length>0)j.style=(j.style?j.style+"; ":"")+p.join("; ");for(m in j)i.push(m+'="'+CKEDITOR.tools.htmlEncode(j[m])+'" ');i.push(">",o,"</",h,">");c.push(i.join(""));(this._||(this._={})).dialog=a;if(typeof b.isChanged=="boolean")this.isChanged=function(){return b.isChanged};if(typeof b.isChanged=="function")this.isChanged=b.isChanged;
if(typeof b.setValue=="function")this.setValue=CKEDITOR.tools.override(this.setValue,function(a){return function(c){a.call(this,b.setValue.call(this,c))}});if(typeof b.getValue=="function")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)&&C(this,a,"CTRL+"+b.accessKey);var l=this;a.on("load",function(){var b=l.getInputElement();
if(b){var c=l.type in{checkbox:1,ratio:1}&&CKEDITOR.env.ie&&CKEDITOR.env.version<8?"cke_dialog_ui_focused":"";b.on("focus",function(){a._.tabBarMode=false;a._.hasFocus=true;l.fire("focus");c&&this.addClass(c)});b.on("blur",function(){l.fire("blur");c&&this.removeClass(c)})}});CKEDITOR.tools.extend(this,b);if(this.keyboardFocusable){this.tabIndex=b.tabIndex||0;this.focusIndex=a._.focusList.push(this)-1;this.on("focus",function(){a._.currentFocusIndex=l.focusIndex})}}},hbox:function(a,b,c,e,d){if(!(arguments.length<
4)){this._||(this._={});var g=this._.children=b,f=d&&d.widths||null,h=d&&d.height||null,i,k={role:"presentation"};d&&d.align&&(k.align=d.align);CKEDITOR.ui.dialog.uiElement.call(this,a,d||{type:"hbox"},e,"table",{},k,function(){var a=['<tbody><tr class="cke_dialog_ui_hbox">'];for(i=0;i<c.length;i++){var b="cke_dialog_ui_hbox_child",e=[];i===0&&(b="cke_dialog_ui_hbox_first");i==c.length-1&&(b="cke_dialog_ui_hbox_last");a.push('<td class="',b,'" role="presentation" ');f?f[i]&&e.push("width:"+o(f[i])):
e.push("width:"+Math.floor(100/c.length)+"%");h&&e.push("height:"+o(h));d&&d.padding!==void 0&&e.push("padding:"+o(d.padding));CKEDITOR.env.ie&&(CKEDITOR.env.quirks&&g[i].align)&&e.push("text-align:"+g[i].align);e.length>0&&a.push('style="'+e.join("; ")+'" ');a.push(">",c[i],"</td>")}a.push("</tr></tbody>");return a.join("")})}},vbox:function(a,b,c,e,d){if(!(arguments.length<3)){this._||(this._={});var g=this._.children=b,f=d&&d.width||null,i=d&&d.heights||null;CKEDITOR.ui.dialog.uiElement.call(this,
a,d||{type:"vbox"},e,"div",null,{role:"presentation"},function(){var b=['<table role="presentation" cellspacing="0" border="0" '];b.push('style="');d&&d.expand&&b.push("height:100%;");b.push("width:"+o(f||"100%"),";");CKEDITOR.env.webkit&&b.push("float:none;");b.push('"');b.push('align="',CKEDITOR.tools.htmlEncode(d&&d.align||(a.getParentEditor().lang.dir=="ltr"?"left":"right")),'" ');b.push("><tbody>");for(var e=0;e<c.length;e++){var h=[];b.push('<tr><td role="presentation" ');f&&h.push("width:"+
o(f||"100%"));i?h.push("height:"+o(i[e])):d&&d.expand&&h.push("height:"+Math.floor(100/c.length)+"%");d&&d.padding!==void 0&&h.push("padding:"+o(d.padding));CKEDITOR.env.ie&&(CKEDITOR.env.quirks&&g[e].align)&&h.push("text-align:"+g[e].align);h.length>0&&b.push('style="',h.join("; "),'" ');b.push(' class="cke_dialog_ui_vbox_child">',c[e],"</td></tr>")}b.push("</tbody></table>");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 false},selectParentTab:function(){for(var a=this.getInputElement();(a=a.getParent())&&a.$.className.search("cke_dialog_page_contents")==-1;);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,e=function(a,b,c,e){b.on("load",function(){a.getInputElement().on(c,e,a)})},d;for(d in a)if(c=d.match(b))this.eventProcessors[d]?this.eventProcessors[d].call(this,this._.dialog,a[d]):e(this,this._.dialog,c[1].toLowerCase(),a[d]);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()?false:true}};CKEDITOR.ui.dialog.hbox.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,{getChild:function(a){if(arguments.length<1)return this._.children.concat();a.splice||(a=[a]);return a.length<2?this._.children[a[0]]:this._.children[a[0]]&&this._.children[a[0]].getChild?this._.children[a[0]].getChild(a.slice(1,a.length)):null}},true);CKEDITOR.ui.dialog.vbox.prototype=new CKEDITOR.ui.dialog.hbox;(function(){var a=
{build:function(a,b,c){for(var e=b.children,d,g=[],f=[],h=0;h<e.length&&(d=e[h]);h++){var i=[];g.push(i);f.push(CKEDITOR.dialog._.uiElementBuilders[d.type].build(a,d,i))}return new CKEDITOR.ui.dialog[b.type](a,f,g,c,b)}};CKEDITOR.dialog.addUIElement("hbox",a);CKEDITOR.dialog.addUIElement("vbox",a)})();CKEDITOR.dialogCommand=function(a,b){this.dialogName=a;CKEDITOR.tools.extend(this,b,true)};CKEDITOR.dialogCommand.prototype={exec:function(a){a.openDialog(this.dialogName)},canUndo:false,editorFocus:1};
(function(){var a=/^([a]|[^a])+$/,b=/^\d*$/,c=/^\d*(?:\.\d+)?$/,e=/^(((\d*(\.\d+))|(\d*))(px|\%)?)?$/,d=/^(((\d*(\.\d+))|(\d*))(px|em|ex|in|cm|mm|pt|pc|\%)?)?$/i,g=/^(\s*[\w-]+\s*:\s*[^:;]+(?:;|$))*$/;CKEDITOR.VALIDATE_OR=1;CKEDITOR.VALIDATE_AND=2;CKEDITOR.dialog.validate={functions:function(){var a=arguments;return function(){var b=this&&this.getValue?this.getValue():a[0],c,e=CKEDITOR.VALIDATE_AND,d=[],g;for(g=0;g<a.length;g++)if(typeof a[g]=="function")d.push(a[g]);else break;if(g<a.length&&typeof a[g]==
"string"){c=a[g];g++}g<a.length&&typeof a[g]=="number"&&(e=a[g]);var f=e==CKEDITOR.VALIDATE_AND?true:false;for(g=0;g<d.length;g++)f=e==CKEDITOR.VALIDATE_AND?f&&d[g](b):f||d[g](b);return!f?c:true}},regex:function(a,b){return function(c){c=this&&this.getValue?this.getValue():c;return!a.test(c)?b:true}},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 d.test(CKEDITOR.tools.trim(a))},
a)},htmlLength:function(a){return this.functions(function(a){return e.test(CKEDITOR.tools.trim(a))},a)},inlineStyle:function(a){return this.functions(function(a){return g.test(CKEDITOR.tools.trim(a))},a)},equals:function(a,b){return this.functions(function(b){return b==a},b)},notEqual:function(a,b){return this.functions(function(b){return b!=a},b)}};CKEDITOR.on("instanceDestroyed",function(a){if(CKEDITOR.tools.isEmpty(CKEDITOR.instances)){for(var b;b=CKEDITOR.dialog._.currentTop;)b.hide();for(var c in y)y[c].remove();
y={}}var a=a.editor._.storedDialogs,e;for(e in a)a[e].destroy()})})();CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{openDialog:function(a,b){var c=null,e=CKEDITOR.dialog._.dialogDefinitions[a];CKEDITOR.dialog._.currentTop===null&&q(this);if(typeof e=="function"){c=this._.storedDialogs||(this._.storedDialogs={});c=c[a]||(c[a]=new CKEDITOR.dialog(this,a));b&&b.call(c,c);c.show()}else{if(e=="failed"){l(this);throw Error('[CKEDITOR.dialog.openDialog] Dialog "'+a+'" failed when loading definition.');
}typeof e=="string"&&CKEDITOR.scriptLoader.load(CKEDITOR.getUrl(e),function(){typeof CKEDITOR.dialog._.dialogDefinitions[a]!="function"&&(CKEDITOR.dialog._.dialogDefinitions[a]="failed");this.openDialog(a,b)},this,0,1)}CKEDITOR.skin.loadPart("dialog");return c}})})();CKEDITOR.plugins.add("dialog",{requires:"dialogui",init:function(a){a.on("doubleclick",function(f){f.data.dialog&&a.openDialog(f.data.dialog)},null,null,999)}});"use strict";(function(){function a(a){function b(){var c=a.editable();c.on(x,
function(a){(!CKEDITOR.env.ie||!t)&&u(a)});CKEDITOR.env.ie&&c.on("paste",function(b){if(!y){g();b.data.preventDefault();u(b);q("paste")||a.openDialog("paste")}});if(CKEDITOR.env.ie){c.on("contextmenu",f,null,null,0);c.on("beforepaste",function(a){a.data&&(!a.data.$.ctrlKey&&!a.data.$.shiftKey)&&f()},null,null,0)}c.on("beforecut",function(){!t&&o(a)});var e;c.attachListener(CKEDITOR.env.ie?c:a.document.getDocumentElement(),"mouseup",function(){e=setTimeout(function(){w()},0)});a.on("destroy",function(){clearTimeout(e)});
c.on("keyup",w)}function c(b){return{type:b,canUndo:b=="cut",startDisabled:true,exec:function(){this.type=="cut"&&o();var b;var c=this.type;if(CKEDITOR.env.ie)b=q(c);else try{b=a.document.$.execCommand(c,false,null)}catch(e){b=false}b||alert(a.lang.clipboard[this.type+"Error"]);return b}}}function d(){return{canUndo:false,async:true,exec:function(a,b){var c=function(b,c){b&&l(b.type,b.dataValue,!!c);a.fire("afterCommandExec",{name:"paste",command:e,returnValue:!!b})},e=this;typeof b=="string"?c({type:"auto",
dataValue:b},1):a.getClipboardData(c)}}}function g(){y=1;setTimeout(function(){y=0},100)}function f(){t=1;setTimeout(function(){t=0},10)}function q(b){var c=a.document,e=c.getBody(),d=false,g=function(){d=true};e.on(b,g);(CKEDITOR.env.version>7?c.$:c.$.selection.createRange()).execCommand(b);e.removeListener(b,g);return d}function l(b,c,e){b={type:b};if(e&&a.fire("beforePaste",b)===false||!c)return false;b.dataValue=c;return a.fire("paste",b)}function o(){if(CKEDITOR.env.ie&&!CKEDITOR.env.quirks){var b=
a.getSelection(),c,e,d;if(b.getType()==CKEDITOR.SELECTION_ELEMENT&&(c=b.getSelectedElement())){e=b.getRanges()[0];d=a.document.createText("");d.insertBefore(c);e.setStartBefore(d);e.setEndAfter(c);b.selectRanges([e]);setTimeout(function(){if(c.getParent()){d.remove();b.selectElement(c)}},0)}}}function p(b,c){var e=a.document,d=a.editable(),g=function(a){a.cancel()},f;if(!e.getById("cke_pastebin")){var h=a.getSelection(),k=h.createBookmarks();CKEDITOR.env.ie&&h.root.fire("selectionchange");var j=new CKEDITOR.dom.element((CKEDITOR.env.webkit||
d.is("body"))&&!CKEDITOR.env.ie?"body":"div",e);j.setAttributes({id:"cke_pastebin","data-cke-temp":"1"});var o=0,e=e.getWindow();if(CKEDITOR.env.webkit){d.append(j);j.addClass("cke_editable");if(!d.is("body")){o=d.getComputedStyle("position")!="static"?d:CKEDITOR.dom.element.get(d.$.offsetParent);o=o.getDocumentPosition().y}}else d.getAscendant(CKEDITOR.env.ie?"body":"html",1).append(j);j.setStyles({position:"absolute",top:e.getScrollPosition().y-o+10+"px",width:"1px",height:Math.max(1,e.getViewPaneSize().height-
20)+"px",overflow:"hidden",margin:0,padding:0});CKEDITOR.env.safari&&j.setStyles(CKEDITOR.tools.cssVendorPrefix("user-select","text"));if(o=j.getParent().isReadOnly()){j.setOpacity(0);j.setAttribute("contenteditable",true)}else j.setStyle(a.config.contentsLangDirection=="ltr"?"left":"right","-1000px");a.on("selectionChange",g,null,null,0);if(CKEDITOR.env.webkit||CKEDITOR.env.gecko)f=d.once("blur",g,null,null,-100);o&&j.focus();o=new CKEDITOR.dom.range(j);o.selectNodeContents(j);var m=o.select();CKEDITOR.env.ie&&
(f=d.once("blur",function(){a.lockSelection(m)}));var p=CKEDITOR.document.getWindow().getScrollPosition().y;setTimeout(function(){if(CKEDITOR.env.webkit)CKEDITOR.document.getBody().$.scrollTop=p;f&&f.removeListener();CKEDITOR.env.ie&&d.focus();h.selectBookmarks(k);j.remove();var b;if(CKEDITOR.env.webkit&&(b=j.getFirst())&&b.is&&b.hasClass("Apple-style-span"))j=b;a.removeListener("selectionChange",g);c(j.getHtml())},0)}}function r(){if(CKEDITOR.env.ie){a.focus();g();var b=a.focusManager;b.lock();if(a.editable().fire(x)&&
!q("paste")){b.unlock();return false}b.unlock()}else try{if(a.editable().fire(x)&&!a.document.$.execCommand("Paste",false,null))throw 0;}catch(c){return false}return true}function s(b){if(a.mode=="wysiwyg")switch(b.data.keyCode){case CKEDITOR.CTRL+86:case CKEDITOR.SHIFT+45:b=a.editable();g();!CKEDITOR.env.ie&&b.fire("beforepaste");break;case CKEDITOR.CTRL+88:case CKEDITOR.SHIFT+46:a.fire("saveSnapshot");setTimeout(function(){a.fire("saveSnapshot")},50)}}function u(b){var c={type:"auto"},e=a.fire("beforePaste",
c);p(b,function(a){a=a.replace(/<span[^>]+data-cke-bookmark[^<]*?<\/span>/ig,"");e&&l(c.type,a,0,1)})}function w(){if(a.mode=="wysiwyg"){var b=v("paste");a.getCommand("cut").setState(v("cut"));a.getCommand("copy").setState(v("copy"));a.getCommand("paste").setState(b);a.fire("pasteState",b)}}function v(b){if(n&&b in{paste:1,cut:1})return CKEDITOR.TRISTATE_DISABLED;if(b=="paste")return CKEDITOR.TRISTATE_OFF;var b=a.getSelection(),c=b.getRanges();return b.getType()==CKEDITOR.SELECTION_NONE||c.length==
1&&c[0].collapsed?CKEDITOR.TRISTATE_DISABLED:CKEDITOR.TRISTATE_OFF}var t=0,y=0,n=0,x=CKEDITOR.env.ie?"beforepaste":"paste";(function(){a.on("key",s);a.on("contentDom",b);a.on("selectionChange",function(a){n=a.data.selection.getRanges()[0].checkReadOnly();w()});a.contextMenu&&a.contextMenu.addListener(function(a,b){n=b.getRanges()[0].checkReadOnly();return{cut:v("cut"),copy:v("copy"),paste:v("paste")}})})();(function(){function b(c,e,d,g,f){var h=a.lang.clipboard[e];a.addCommand(e,d);a.ui.addButton&&
a.ui.addButton(c,{label:h,command:e,toolbar:"clipboard,"+g});a.addMenuItems&&a.addMenuItem(e,{label:h,command:e,group:"clipboard",order:f})}b("Cut","cut",c("cut"),10,1);b("Copy","copy",c("copy"),20,4);b("Paste","paste",d(),30,8)})();a.getClipboardData=function(b,c){function e(a){a.removeListener();a.cancel();c(a.data)}function d(a){a.removeListener();a.cancel();j=true;c({type:h,dataValue:a.data})}function g(){this.customTitle=b&&b.title}var f=false,h="auto",j=false;if(!c){c=b;b=null}a.on("paste",
e,null,null,0);a.on("beforePaste",function(a){a.removeListener();f=true;h=a.data.type},null,null,1E3);if(r()===false){a.removeListener("paste",e);if(f&&a.fire("pasteDialog",g)){a.on("pasteDialogCommit",d);a.on("dialogHide",function(a){a.removeListener();a.data.removeListener("pasteDialogCommit",d);setTimeout(function(){j||c(null)},10)})}else c(null)}}}function f(a){if(CKEDITOR.env.webkit){if(!a.match(/^[^<]*$/g)&&!a.match(/^(<div><br( ?\/)?><\/div>|<div>[^<]*<\/div>)*$/gi))return"html"}else if(CKEDITOR.env.ie){if(!a.match(/^([^<]|<br( ?\/)?>)*$/gi)&&
!a.match(/^(<p>([^<]|<br( ?\/)?>)*<\/p>|(\r\n))*$/gi))return"html"}else if(CKEDITOR.env.gecko){if(!a.match(/^([^<]|<br( ?\/)?>)*$/gi))return"html"}else return"html";return"htmlifiedtext"}function d(a,b){function c(a){return CKEDITOR.tools.repeat("</p><p>",~~(a/2))+(a%2==1?"<br>":"")}b=b.replace(/\s+/g," ").replace(/> +</g,"><").replace(/<br ?\/>/gi,"<br>");b=b.replace(/<\/?[A-Z]+>/g,function(a){return a.toLowerCase()});if(b.match(/^[^<]$/))return b;if(CKEDITOR.env.webkit&&b.indexOf("<div>")>-1){b=
b.replace(/^(<div>(<br>|)<\/div>)(?!$|(<div>(<br>|)<\/div>))/g,"<br>").replace(/^(<div>(<br>|)<\/div>){2}(?!$)/g,"<div></div>");b.match(/<div>(<br>|)<\/div>/)&&(b="<p>"+b.replace(/(<div>(<br>|)<\/div>)+/g,function(a){return c(a.split("</div><div>").length+1)})+"</p>");b=b.replace(/<\/div><div>/g,"<br>");b=b.replace(/<\/?div>/g,"")}if(CKEDITOR.env.gecko&&a.enterMode!=CKEDITOR.ENTER_BR){CKEDITOR.env.gecko&&(b=b.replace(/^<br><br>$/,"<br>"));b.indexOf("<br><br>")>-1&&(b="<p>"+b.replace(/(<br>){2,}/g,
function(a){return c(a.length/4)})+"</p>")}return g(a,b)}function c(){var a=new CKEDITOR.htmlParser.filter,b={blockquote:1,dl:1,fieldset:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1,ol:1,p:1,table:1,ul:1},c=CKEDITOR.tools.extend({br:0},CKEDITOR.dtd.$inline),d={p:1,br:1,"cke:br":1},g=CKEDITOR.dtd,f=CKEDITOR.tools.extend({area:1,basefont:1,embed:1,iframe:1,map:1,object:1,param:1},CKEDITOR.dtd.$nonBodyContent,CKEDITOR.dtd.$cdata),q=function(a){delete a.name;a.add(new CKEDITOR.htmlParser.text(" "))},l=function(a){for(var b=
a,c;(b=b.next)&&b.name&&b.name.match(/^h\d$/);){c=new CKEDITOR.htmlParser.element("cke:br");c.isEmpty=true;for(a.add(c);c=b.children.shift();)a.add(c)}};a.addRules({elements:{h1:l,h2:l,h3:l,h4:l,h5:l,h6:l,img:function(a){var a=CKEDITOR.tools.trim(a.attributes.alt||""),b=" ";a&&!a.match(/(^http|\.(jpe?g|gif|png))/i)&&(b=" ["+a+"] ");return new CKEDITOR.htmlParser.text(b)},td:q,th:q,$:function(a){var i=a.name,l;if(f[i])return false;a.attributes={};if(i=="br")return a;if(b[i])a.name="p";else if(c[i])delete a.name;
else if(g[i]){l=new CKEDITOR.htmlParser.element("cke:br");l.isEmpty=true;if(CKEDITOR.dtd.$empty[i])return l;a.add(l,0);l=l.clone();l.isEmpty=true;a.add(l);delete a.name}d[a.name]||delete a.name;return a}}},{applyToAll:true});return a}function b(a,b,c){var b=new CKEDITOR.htmlParser.fragment.fromHtml(b),d=new CKEDITOR.htmlParser.basicWriter;b.writeHtml(d,c);var b=d.getHtml(),b=b.replace(/\s*(<\/?[a-z:]+ ?\/?>)\s*/g,"$1").replace(/(<cke:br \/>){2,}/g,"<cke:br />").replace(/(<cke:br \/>)(<\/?p>|<br \/>)/g,
"$2").replace(/(<\/?p>|<br \/>)(<cke:br \/>)/g,"$1").replace(/<(cke:)?br( \/)?>/g,"<br>").replace(/<p><\/p>/g,""),f=0,b=b.replace(/<\/?p>/g,function(a){if(a=="<p>"){if(++f>1)return"</p><p>"}else if(--f>0)return"</p><p>";return a}).replace(/<p><\/p>/g,"");return g(a,b)}function g(a,b){a.enterMode==CKEDITOR.ENTER_BR?b=b.replace(/(<\/p><p>)+/g,function(a){return CKEDITOR.tools.repeat("<br>",a.length/7*2)}).replace(/<\/?p>/g,""):a.enterMode==CKEDITOR.ENTER_DIV&&(b=b.replace(/<(\/)?p>/g,"<$1div>"));return b}
CKEDITOR.plugins.add("clipboard",{requires:"dialog",init:function(g){var e;a(g);CKEDITOR.dialog.add("paste",CKEDITOR.getUrl(this.path+"dialogs/paste.js"));g.on("paste",function(a){var b=a.data.dataValue,c=CKEDITOR.dtd.$block;if(b.indexOf("Apple-")>-1){b=b.replace(/<span class="Apple-converted-space">&nbsp;<\/span>/gi," ");a.data.type!="html"&&(b=b.replace(/<span class="Apple-tab-span"[^>]*>([^<]*)<\/span>/gi,function(a,b){return b.replace(/\t/g,"&nbsp;&nbsp; &nbsp;")}));if(b.indexOf('<br class="Apple-interchange-newline">')>
-1){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 e,d,g=new CKEDITOR.dom.element("div");for(g.setHtml(b);g.getChildCount()==1&&(e=g.getFirst())&&e.type==CKEDITOR.NODE_ELEMENT&&(e.hasClass("cke_editable")||e.hasClass("cke_contents"));)g=d=e;d&&(b=d.getHtml().replace(/<br>$/i,""))}CKEDITOR.env.ie?b=b.replace(/^&nbsp;(?: |\r\n)?<(\w+)/g,function(b,
e){if(e.toLowerCase()in c){a.data.preSniffing="html";return"<"+e}return b}):CKEDITOR.env.webkit?b=b.replace(/<\/(\w+)><div><br><\/div>$/,function(b,e){if(e in c){a.data.endsWithEOL=1;return"</"+e+">"}return b}):CKEDITOR.env.gecko&&(b=b.replace(/(\s)<br>$/,"$1"));a.data.dataValue=b},null,null,3);g.on("paste",function(a){var a=a.data,k=a.type,j=a.dataValue,m,q=g.config.clipboard_defaultContentType||"html";m=k=="html"||a.preSniffing=="html"?"html":f(j);m=="htmlifiedtext"?j=d(g.config,j):k=="text"&&m==
"html"&&(j=b(g.config,j,e||(e=c(g))));a.startsWithEOL&&(j='<br data-cke-eol="1">'+j);a.endsWithEOL&&(j=j+'<br data-cke-eol="1">');k=="auto"&&(k=m=="html"||q=="html"?"html":"text");a.type=k;a.dataValue=j;delete a.preSniffing;delete a.startsWithEOL;delete a.endsWithEOL},null,null,6);g.on("paste",function(a){a=a.data;g.insertHtml(a.dataValue,a.type);setTimeout(function(){g.fire("afterPaste")},0)},null,null,1E3);g.on("pasteDialog",function(a){setTimeout(function(){g.openDialog("paste",a.data)},0)})}})})();
CKEDITOR.plugins.add("panelbutton",{requires:"button",onLoad:function(){function a(a){var d=this._;if(d.state!=CKEDITOR.TRISTATE_DISABLED){this.createPanel(a);d.on?d.panel.hide():d.panel.showBlock(this._.id,this.document.getById(this._.id),4)}}CKEDITOR.ui.panelButton=CKEDITOR.tools.createClass({base:CKEDITOR.ui.button,$:function(f){var d=f.panel||{};delete f.panel;this.base(f);this.document=d.parent&&d.parent.getDocument()||CKEDITOR.document;d.block={attributes:d.attributes};this.hasArrow=d.toolbarRelated=
true;this.click=a;this._={panelDefinition:d}},statics:{handler:{create:function(a){return new CKEDITOR.ui.panelButton(a)}}},proto:{createPanel:function(a){var d=this._;if(!d.panel){var c=this._.panelDefinition,b=this._.panelDefinition.block,g=c.parent||CKEDITOR.document.getBody(),i=this._.panel=new CKEDITOR.ui.floatPanel(a,g,c),c=i.addBlock(d.id,b),e=this;i.onShow=function(){e.className&&this.element.addClass(e.className+"_panel");e.setState(CKEDITOR.TRISTATE_ON);d.on=1;e.editorFocus&&a.focus();if(e.onOpen)e.onOpen()};
i.onHide=function(b){e.className&&this.element.getFirst().removeClass(e.className+"_panel");e.setState(e.modes&&e.modes[a.mode]?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED);d.on=0;if(!b&&e.onClose)e.onClose()};i.onEscape=function(){i.hide(1);e.document.getById(d.id).focus()};if(this.onBlock)this.onBlock(i,c);c.onHide=function(){d.on=0;e.setState(CKEDITOR.TRISTATE_OFF)}}}}})},beforeInit:function(a){a.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 a=CKEDITOR.addTemplate("panel",
'<div lang="{langCode}" id="{id}" dir={dir} class="cke cke_reset_all {editorId} cke_panel cke_panel {cls} cke_{dir}" style="z-index:{z-index}" role="presentation">{frame}</div>'),f=CKEDITOR.addTemplate("panel-frame",'<iframe id="{id}" class="cke_panel_frame" role="presentation" frameborder="0" src="{src}"></iframe>'),d=CKEDITOR.addTemplate("panel-frame-inner",'<!DOCTYPE html><html class="cke_panel_container {env}" dir="{dir}" lang="{langCode}"><head>{css}</head><body class="cke_{dir}" style="margin:0;padding:0" onload="{onload}"></body></html>');
CKEDITOR.ui.panel.prototype={render:function(c,b){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=true;if(this.onLoad)this.onLoad()},this));a.write(d.output(CKEDITOR.tools.extend({css:CKEDITOR.tools.buildStyleHtml(this.css),
onload:"window.parent.CKEDITOR.tools.callFunction("+b+");"},g)));a.getWindow().$.CKEDITOR=CKEDITOR;a.on("keydown",function(a){var b=a.data.getKeystroke(),c=this.document.getById(this.id).getAttribute("dir");this._.onKeyDown&&this._.onKeyDown(b)===false?a.data.preventDefault():(b==27||b==(c=="rtl"?39:37))&&this.onEscape&&this.onEscape(b)===false&&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 g={editorId:c.id,id:this.id,langCode:c.langCode,dir:c.lang.dir,cls:this.className,frame:"",env:CKEDITOR.env.cssClass,"z-index":c.config.baseFloatZIndex+1};if(this.isFramed){var i=CKEDITOR.env.air?"javascript:void(0)":CKEDITOR.env.ie?"javascript:void(function(){"+encodeURIComponent("document.open();("+CKEDITOR.tools.fixDomain+")();document.close();")+"}())":"";g.frame=f.output({id:this.id+"_frame",src:i})}i=a.output(g);b&&b.push(i);return i},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){var a=this._.blocks[a],b=this._.currentBlock,d=!this.forceIFrame||CKEDITOR.env.ie?this._.holder:this.document.getById(this.id+"_frame");b&&b.hide();this._.currentBlock=a;CKEDITOR.fire("ariaWidget",d);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){if(a!=-1){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||this.onHide.call(this)!==true)&&this.element.setStyle("display","none")},onKeyDown:function(a,b){var d=this.keys[a];switch(d){case "next":for(var f=this._.focusIndex,d=this.element.getElementsByTag("a"),
e;e=d.getItem(++f);)if(e.getAttribute("_cke_focus")&&e.$.offsetWidth){this._.focusIndex=f;e.focus();break}if(!e&&!b){this._.focusIndex=-1;return this.onKeyDown(a,1)}return false;case "prev":f=this._.focusIndex;for(d=this.element.getElementsByTag("a");f>0&&(e=d.getItem(--f));){if(e.getAttribute("_cke_focus")&&e.$.offsetWidth){this._.focusIndex=f;e.focus();break}e=null}if(!e&&!b){this._.focusIndex=d.count();return this.onKeyDown(a,1)}return false;case "click":case "mouseup":f=this._.focusIndex;(e=f>=
0&&this.element.getElementsByTag("a").getItem(f))&&(e.$[d]?e.$[d]():e.$["on"+d]());return false}return true}}})})();CKEDITOR.plugins.add("floatpanel",{requires:"panel"});(function(){function a(a,c,b,g,i){var i=CKEDITOR.tools.genKey(c.getUniqueId(),b.getUniqueId(),a.lang.dir,a.uiColor||"",g.css||"",i||""),e=f[i];if(!e){e=f[i]=new CKEDITOR.ui.panel(c,g);e.element=b.append(CKEDITOR.dom.element.createFromHtml(e.render(a),c));e.element.setStyles({display:"none",position:"absolute"})}return e}var f={};
CKEDITOR.ui.floatPanel=CKEDITOR.tools.createClass({$:function(d,c,b,g){function f(){j.hide()}b.forceIFrame=1;b.toolbarRelated&&d.elementMode==CKEDITOR.ELEMENT_MODE_INLINE&&(c=CKEDITOR.document.getById("cke_"+d.name));var e=c.getDocument(),g=a(d,e,c,b,g||0),h=g.element,k=h.getFirst(),j=this;h.disableContextMenu();this.element=h;this._={editor:d,panel:g,parentElement:c,definition:b,document:e,iframe:k,children:[],dir:d.lang.dir};d.on("mode",f);d.on("resize",f);if(!CKEDITOR.env.iOS)e.getWindow().on("resize",
f)},proto:{addBlock:function(a,c){return this._.panel.addBlock(a,c)},addListBlock:function(a,c){return this._.panel.addListBlock(a,c)},getBlock:function(a){return this._.panel.getBlock(a)},showBlock:function(a,c,b,g,f,e){var h=this._.panel,k=h.showBlock(a);this.allowBlur(false);a=this._.editor.editable();this._.returnFocus=a.hasFocus?a:new CKEDITOR.dom.element(CKEDITOR.document.$.activeElement);this._.hideTimeout=0;var j=this.element,a=this._.iframe,a=CKEDITOR.env.ie?a:new CKEDITOR.dom.window(a.$.contentWindow),
m=j.getDocument(),q=this._.parentElement.getPositionedAncestor(),l=c.getDocumentPosition(m),m=q?q.getDocumentPosition(m):{x:0,y:0},o=this._.dir=="rtl",p=l.x+(g||0)-m.x,r=l.y+(f||0)-m.y;if(o&&(b==1||b==4))p=p+c.$.offsetWidth;else if(!o&&(b==2||b==3))p=p+(c.$.offsetWidth-1);if(b==3||b==4)r=r+(c.$.offsetHeight-1);this._.panel._.offsetParentId=c.getId();j.setStyles({top:r+"px",left:0,display:""});j.setOpacity(0);j.getFirst().removeStyle("width");this._.editor.focusManager.add(a);if(!this._.blurSet){CKEDITOR.event.useCapture=
true;a.on("blur",function(a){function b(){delete this._.returnFocus;this.hide()}if(this.allowBlur()&&a.data.getPhase()==CKEDITOR.EVENT_PHASE_AT_TARGET&&this.visible&&!this._.activeChild)if(CKEDITOR.env.iOS){if(!this._.hideTimeout)this._.hideTimeout=CKEDITOR.tools.setTimeout(b,0,this)}else b.call(this)},this);a.on("focus",function(){this._.focused=true;this.hideChild();this.allowBlur(true)},this);if(CKEDITOR.env.iOS){a.on("touchstart",function(){clearTimeout(this._.hideTimeout)},this);a.on("touchend",
function(){this._.hideTimeout=0;this.focus()},this)}CKEDITOR.event.useCapture=false;this._.blurSet=1}h.onEscape=CKEDITOR.tools.bind(function(a){if(this.onEscape&&this.onEscape(a)===false)return false},this);CKEDITOR.tools.setTimeout(function(){var a=CKEDITOR.tools.bind(function(){j.removeStyle("width");if(k.autoSize){var a=k.element.getDocument(),a=(CKEDITOR.env.webkit?k.element:a.getBody()).$.scrollWidth;CKEDITOR.env.ie&&(CKEDITOR.env.quirks&&a>0)&&(a=a+((j.$.offsetWidth||0)-(j.$.clientWidth||0)+
3));j.setStyle("width",a+10+"px");a=k.element.$.scrollHeight;CKEDITOR.env.ie&&(CKEDITOR.env.quirks&&a>0)&&(a=a+((j.$.offsetHeight||0)-(j.$.clientHeight||0)+3));j.setStyle("height",a+"px");h._.currentBlock.element.setStyle("display","none").removeStyle("display")}else j.removeStyle("height");o&&(p=p-j.$.offsetWidth);j.setStyle("left",p+"px");var b=h.element.getWindow(),a=j.$.getBoundingClientRect(),b=b.getViewPaneSize(),c=a.width||a.right-a.left,d=a.height||a.bottom-a.top,g=o?a.right:b.width-a.left,
f=o?b.width-a.right:a.left;o?g<c&&(p=f>c?p+c:b.width>c?p-a.left:p-a.right+b.width):g<c&&(p=f>c?p-c:b.width>c?p-a.right+b.width:p-a.left);c=a.top;b.height-a.top<d&&(r=c>d?r-d:b.height>d?r-a.bottom+b.height:r-a.top);if(CKEDITOR.env.ie){b=a=new CKEDITOR.dom.element(j.$.offsetParent);b.getName()=="html"&&(b=b.getDocument().getBody());b.getComputedStyle("direction")=="rtl"&&(p=CKEDITOR.env.ie8Compat?p-j.getDocument().getDocumentElement().$.scrollLeft*2:p-(a.$.scrollWidth-a.$.clientWidth))}var a=j.getFirst(),
i;(i=a.getCustomData("activePanel"))&&i.onHide&&i.onHide.call(this,1);a.setCustomData("activePanel",this);j.setStyles({top:r+"px",left:p+"px"});j.setOpacity(1);e&&e()},this);h.isLoaded?a():h.onLoad=a;CKEDITOR.tools.setTimeout(function(){var a=CKEDITOR.env.webkit&&CKEDITOR.document.getWindow().getScrollPosition().y;this.focus();k.element.focus();if(CKEDITOR.env.webkit)CKEDITOR.document.getBody().$.scrollTop=a;this.allowBlur(true);this._.editor.fire("panelShow",this)},0,this)},CKEDITOR.env.air?200:
0,this);this.visible=1;this.onShow&&this.onShow.call(this)},focus:function(){if(CKEDITOR.env.webkit){var a=CKEDITOR.document.getActive();a&&!a.equals(this._.iframe)&&a.$.blur()}(this._.lastFocused||this._.iframe.getFrameDocument().getWindow()).focus()},blur:function(){var a=this._.iframe.getFrameDocument().getActive();a&&a.is("a")&&(this._.lastFocused=a)},hide:function(a){if(this.visible&&(!this.onHide||this.onHide.call(this)!==true)){this.hideChild();CKEDITOR.env.gecko&&this._.iframe.getFrameDocument().$.activeElement.blur();
this.element.setStyle("display","none");this.visible=0;this.element.getFirst().removeCustomData("activePanel");if(a=a&&this._.returnFocus){CKEDITOR.env.webkit&&a.type&&a.getWindow().$.focus();a.focus()}delete this._.lastFocused;this._.editor.fire("panelHide",this)}},allowBlur:function(a){var c=this._.panel;if(a!==void 0)c.allowBlur=a;return c.allowBlur},showAsChild:function(a,c,b,g,f,e){if(!(this._.activeChild==a&&a._.panel._.offsetParentId==b.getId())){this.hideChild();a.onHide=CKEDITOR.tools.bind(function(){CKEDITOR.tools.setTimeout(function(){this._.focused||
this.hide()},0,this)},this);this._.activeChild=a;this._.focused=false;a.showBlock(c,b,g,f,e);this.blur();(CKEDITOR.env.ie7Compat||CKEDITOR.env.ie6Compat)&&setTimeout(function(){a.element.getChild(0).$.style.cssText+=""},100)}},hideChild:function(a){var c=this._.activeChild;if(c){delete c.onHide;delete this._.activeChild;c.hide();a&&this.focus()}}}});CKEDITOR.on("instanceDestroyed",function(){var a=CKEDITOR.tools.isEmpty(CKEDITOR.instances),c;for(c in f){var b=f[c];a?b.destroy():b.element.hide()}a&&
(f={})})})();CKEDITOR.plugins.add("colorbutton",{requires:"panelbutton,floatpanel",init:function(a){function f(c,e,f,k){var j=new CKEDITOR.style(b["colorButton_"+e+"Style"]),m=CKEDITOR.tools.getNextId()+"_colorBox";a.ui.add(c,CKEDITOR.UI_PANELBUTTON,{label:f,title:f,modes:{wysiwyg:1},editorFocus:0,toolbar:"colors,"+k,allowedContent:j,requiredContent:j,panel:{css:CKEDITOR.skin.getPath("editor"),attributes:{role:"listbox","aria-label":g.panelTitle}},onBlock:function(b,c){c.autoSize=true;c.element.addClass("cke_colorblock");
c.element.setHtml(d(b,e,m));c.element.getDocument().getBody().setStyle("overflow","hidden");CKEDITOR.ui.fire("ready",this);var g=c.keys,f=a.lang.dir=="rtl";g[f?37:39]="next";g[40]="next";g[9]="next";g[f?39:37]="prev";g[38]="prev";g[CKEDITOR.SHIFT+9]="prev";g[32]="click"},refresh:function(){a.activeFilter.check(j)||this.setState(CKEDITOR.TRISTATE_DISABLED)},onOpen:function(){var b=a.getSelection(),b=b&&b.getStartElement(),b=a.elementPath(b),c;if(b){b=b.block||b.blockLimit||a.document.getBody();do c=
b&&b.getComputedStyle(e=="back"?"background-color":"color")||"transparent";while(e=="back"&&c=="transparent"&&b&&(b=b.getParent()));if(!c||c=="transparent")c="#ffffff";this._.panel._.iframe.getFrameDocument().getById(m).setStyle("background-color",c);return c}}})}function d(d,e,f){var k=[],j=b.colorButton_colors.split(","),m=a.plugins.colordialog&&b.colorButton_enableMore!==false,q=j.length+(m?2:1),l=CKEDITOR.tools.addFunction(function(e,g){function f(a){this.removeListener("ok",f);this.removeListener("cancel",
f);a.name=="ok"&&h(this.getContentElement("picker","selectedColor").getValue(),g)}var h=arguments.callee;if(e=="?")a.openDialog("colordialog",function(){this.on("ok",f);this.on("cancel",f)});else{a.focus();d.hide();a.fire("saveSnapshot");a.removeStyle(new CKEDITOR.style(b["colorButton_"+g+"Style"],{color:"inherit"}));if(e){var j=b["colorButton_"+g+"Style"];j.childRule=g=="back"?function(a){return c(a)}:function(a){return!(a.is("a")||a.getElementsByTag("a").count())||c(a)};a.applyStyle(new CKEDITOR.style(j,
{color:e}))}a.fire("saveSnapshot")}});k.push('<a class="cke_colorauto" _cke_focus=1 hidefocus=true title="',g.auto,'" onclick="CKEDITOR.tools.callFunction(',l,",null,'",e,"');return false;\" href=\"javascript:void('",g.auto,'\')" role="option" aria-posinset="1" aria-setsize="',q,'"><table role="presentation" cellspacing=0 cellpadding=0 width="100%"><tr><td><span class="cke_colorbox" id="',f,'"></span></td><td colspan=7 align=center>',g.auto,'</td></tr></table></a><table role="presentation" cellspacing=0 cellpadding=0 width="100%">');
for(f=0;f<j.length;f++){f%8===0&&k.push("</tr><tr>");var o=j[f].split("/"),p=o[0],r=o[1]||p;o[1]||(p="#"+p.replace(/^(.)(.)(.)$/,"$1$1$2$2$3$3"));o=a.lang.colorbutton.colors[r]||r;k.push('<td><a class="cke_colorbox" _cke_focus=1 hidefocus=true title="',o,'" onclick="CKEDITOR.tools.callFunction(',l,",'",p,"','",e,"'); return false;\" href=\"javascript:void('",o,'\')" role="option" aria-posinset="',f+2,'" aria-setsize="',q,'"><span class="cke_colorbox" style="background-color:#',r,'"></span></a></td>')}m&&
k.push('</tr><tr><td colspan=8 align=center><a class="cke_colormore" _cke_focus=1 hidefocus=true title="',g.more,'" onclick="CKEDITOR.tools.callFunction(',l,",'?','",e,"');return false;\" href=\"javascript:void('",g.more,"')\"",' role="option" aria-posinset="',q,'" aria-setsize="',q,'">',g.more,"</a></td>");k.push("</tr></table>");return k.join("")}function c(a){return a.getAttribute("contentEditable")=="false"||a.getAttribute("data-nostyle")}var b=a.config,g=a.lang.colorbutton;if(!CKEDITOR.env.hc){f("TextColor",
"fore",g.textColorTitle,10);f("BGColor","back",g.bgColorTitle,20)}}});CKEDITOR.config.colorButton_colors="000,800000,8B4513,2F4F4F,008080,000080,4B0082,696969,B22222,A52A2A,DAA520,006400,40E0D0,0000CD,800080,808080,F00,FF8C00,FFD700,008000,0FF,00F,EE82EE,A9A9A9,FFA07A,FFA500,FFFF00,00FF00,AFEEEE,ADD8E6,DDA0DD,D3D3D3,FFF0F5,FAEBD7,FFFFE0,F0FFF0,F0FFFF,F0F8FF,E6E6FA,FFF";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)"}};(function(){function a(a,b,c){c=a.config.forceEnterMode||c;if(a.mode=="wysiwyg"){if(!b)b=a.activeEnterMode;if(!a.elementPath().isContextFor("p")){b=CKEDITOR.ENTER_BR;c=1}a.fire("saveSnapshot");b==CKEDITOR.ENTER_BR?i(a,b,null,c):e(a,b,null,c);a.fire("saveSnapshot")}}function f(a){for(var a=a.getSelection().getRanges(true),b=a.length-1;b>0;b--)a[b].deleteContents();return a[0]}function d(a){var b=a.startContainer.getAscendant(function(a){return a.type==
CKEDITOR.NODE_ELEMENT&&a.getAttribute("contenteditable")=="true"},true);if(a.root.equals(b))return a;b=new CKEDITOR.dom.range(b);b.moveToRange(a);return b}CKEDITOR.plugins.add("enterkey",{init:function(b){b.addCommand("enter",{modes:{wysiwyg:1},editorFocus:false,exec:function(b){a(b)}});b.addCommand("shiftEnter",{modes:{wysiwyg:1},editorFocus:false,exec:function(b){a(b,b.activeShiftEnterMode,1)}});b.setKeystroke([[13,"enter"],[CKEDITOR.SHIFT+13,"shiftEnter"]])}});var c=CKEDITOR.dom.walker.whitespaces(),
b=CKEDITOR.dom.walker.bookmark();CKEDITOR.plugins.enterkey={enterBlock:function(a,e,g,q){if(g=g||f(a)){var g=d(g),l=g.document,o=g.checkStartOfBlock(),p=g.checkEndOfBlock(),r=a.elementPath(g.startContainer),s=r.block,u=e==CKEDITOR.ENTER_DIV?"div":"p",w;if(o&&p){if(s&&(s.is("li")||s.getParent().is("li"))){s.is("li")||(s=s.getParent());g=s.getParent();w=g.getParent();var q=!s.hasPrevious(),v=!s.hasNext(),u=a.getSelection(),t=u.createBookmarks(),o=s.getDirection(1),p=s.getAttribute("class"),y=s.getAttribute("style"),
n=w.getDirection(1)!=o,a=a.enterMode!=CKEDITOR.ENTER_BR||n||y||p;if(w.is("li"))if(q||v)s[q?"insertBefore":"insertAfter"](w);else s.breakParent(w);else{if(a){if(r.block.is("li")){w=l.createElement(e==CKEDITOR.ENTER_P?"p":"div");n&&w.setAttribute("dir",o);y&&w.setAttribute("style",y);p&&w.setAttribute("class",p);s.moveChildren(w)}else w=r.block;if(q||v)w[q?"insertBefore":"insertAfter"](g);else{s.breakParent(g);w.insertAfter(g)}}else{s.appendBogus(true);if(q||v)for(;l=s[q?"getFirst":"getLast"]();)l[q?
"insertBefore":"insertAfter"](g);else for(s.breakParent(g);l=s.getLast();)l.insertAfter(g)}s.remove()}u.selectBookmarks(t);return}if(s&&s.getParent().is("blockquote")){s.breakParent(s.getParent());s.getPrevious().getFirst(CKEDITOR.dom.walker.invisible(1))||s.getPrevious().remove();s.getNext().getFirst(CKEDITOR.dom.walker.invisible(1))||s.getNext().remove();g.moveToElementEditStart(s);g.select();return}}else if(s&&s.is("pre")&&!p){i(a,e,g,q);return}if(o=g.splitBlock(u)){e=o.previousBlock;s=o.nextBlock;
r=o.wasStartOfBlock;a=o.wasEndOfBlock;if(s){t=s.getParent();if(t.is("li")){s.breakParent(t);s.move(s.getNext(),1)}}else if(e&&(t=e.getParent())&&t.is("li")){e.breakParent(t);t=e.getNext();g.moveToElementEditStart(t);e.move(e.getPrevious())}if(!r&&!a){if(s.is("li")){w=g.clone();w.selectNodeContents(s);w=new CKEDITOR.dom.walker(w);w.evaluator=function(a){return!(b(a)||c(a)||a.type==CKEDITOR.NODE_ELEMENT&&a.getName()in CKEDITOR.dtd.$inline&&!(a.getName()in CKEDITOR.dtd.$empty))};(t=w.next())&&(t.type==
CKEDITOR.NODE_ELEMENT&&t.is("ul","ol"))&&(CKEDITOR.env.needsBrFiller?l.createElement("br"):l.createText(" ")).insertBefore(t)}s&&g.moveToElementEditStart(s)}else{if(e){if(e.is("li")||!h.test(e.getName())&&!e.is("pre"))w=e.clone()}else s&&(w=s.clone());if(w)q&&!w.is("li")&&w.renameNode(u);else if(t&&t.is("li"))w=t;else{w=l.createElement(u);e&&(v=e.getDirection())&&w.setAttribute("dir",v)}if(l=o.elementPath){q=0;for(u=l.elements.length;q<u;q++){t=l.elements[q];if(t.equals(l.block)||t.equals(l.blockLimit))break;
if(CKEDITOR.dtd.$removeEmpty[t.getName()]){t=t.clone();w.moveChildren(t);w.append(t)}}}w.appendBogus();w.getParent()||g.insertNode(w);w.is("li")&&w.removeAttribute("value");if(CKEDITOR.env.ie&&r&&(!a||!e.getChildCount())){g.moveToElementEditStart(a?e:w);g.select()}g.moveToElementEditStart(r&&!a?s:w)}g.select();g.scrollIntoView()}}},enterBr:function(a,b,c,d){if(c=c||f(a)){var g=c.document,i=c.checkEndOfBlock(),p=new CKEDITOR.dom.elementPath(a.getSelection().getStartElement()),r=p.block,s=r&&p.block.getName();
if(!d&&s=="li")e(a,b,c,d);else{if(!d&&i&&h.test(s))if(i=r.getDirection()){g=g.createElement("div");g.setAttribute("dir",i);g.insertAfter(r);c.setStart(g,0)}else{g.createElement("br").insertAfter(r);CKEDITOR.env.gecko&&g.createText("").insertAfter(r);c.setStartAt(r.getNext(),CKEDITOR.env.ie?CKEDITOR.POSITION_BEFORE_START:CKEDITOR.POSITION_AFTER_START)}else{a=s=="pre"&&CKEDITOR.env.ie&&CKEDITOR.env.version<8?g.createText("\r"):g.createElement("br");c.deleteContents();c.insertNode(a);if(CKEDITOR.env.needsBrFiller){g.createText("﻿").insertAfter(a);
i&&(r||p.blockLimit).appendBogus();a.getNext().$.nodeValue="";c.setStartAt(a.getNext(),CKEDITOR.POSITION_AFTER_START)}else c.setStartAt(a,CKEDITOR.POSITION_AFTER_END)}c.collapse(true);c.select();c.scrollIntoView()}}}};var g=CKEDITOR.plugins.enterkey,i=g.enterBr,e=g.enterBlock,h=/^h[1-6]$/})();(function(){function a(a,d){var c={},b=[],g={nbsp:" ",shy:"­",gt:">",lt:"<",amp:"&",apos:"'",quot:'"'},a=a.replace(/\b(nbsp|shy|gt|lt|amp|apos|quot)(?:,|$)/g,function(a,e){var f=d?"&"+e+";":g[e];c[f]=d?g[e]:
"&"+e+";";b.push(f);return""});if(!d&&a){var a=a.split(","),i=document.createElement("div"),e;i.innerHTML="&"+a.join(";&")+";";e=i.innerHTML;i=null;for(i=0;i<e.length;i++){var h=e.charAt(i);c[h]="&"+a[i]+";";b.push(h)}}c.regex=b.join(d?"|":"");return c}CKEDITOR.plugins.add("entities",{afterInit:function(f){function d(a){return h[a]}function c(a){return b.entities_processNumerical=="force"||!i[a]?"&#"+a.charCodeAt(0)+";":i[a]}var b=f.config;if(f=(f=f.dataProcessor)&&f.htmlFilter){var g=[];b.basicEntities!==
false&&g.push("nbsp,gt,lt,amp");if(b.entities){g.length&&g.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");
b.entities_latin&&g.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");b.entities_greek&&g.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");
b.entities_additional&&g.push(b.entities_additional)}var i=a(g.join(",")),e=i.regex?"["+i.regex+"]":"a^";delete i.regex;b.entities&&b.entities_processNumerical&&(e="[^ -~]|"+e);var e=RegExp(e,"g"),h=a("nbsp,gt,lt,amp,shy",true),k=RegExp(h.regex,"g");f.addRules({text:function(a){return a.replace(k,d).replace(e,c)}},{applyToAll:true,excludeNestedEditable:true})}}})})();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 a(a,b){var e=c.exec(a),d=c.exec(b);if(e){if(!e[2]&&d[2]=="px")return d[1];if(e[2]=="px"&&!d[2])return d[1]+"px"}return b}var f=CKEDITOR.htmlParser.cssStyle,d=CKEDITOR.tools.cssLength,c=/^((?:\d*(?:\.\d+))|(?:\d+))(.*)?$/i,b={elements:{$:function(b){var c=b.attributes;if((c=(c=(c=c&&c["data-cke-realelement"])&&new CKEDITOR.htmlParser.fragment.fromHtml(decodeURIComponent(c)))&&c.children[0])&&b.attributes["data-cke-resizable"]){var e=(new f(b)).rules,b=c.attributes,d=e.width,
e=e.height;d&&(b.width=a(b.width,d));e&&(b.height=a(b.height,e))}return c}}};CKEDITOR.plugins.add("fakeobjects",{init:function(a){a.filter.allow("img[!data-cke-realelement,src,alt,title](*){*}","fakeobjects")},afterInit:function(a){(a=(a=a.dataProcessor)&&a.htmlFilter)&&a.addRules(b,{applyToAll:true})}});CKEDITOR.editor.prototype.createFakeElement=function(a,b,c,h){var k=this.lang.fakeobjects,k=k[c]||k.unknown,b={"class":b,"data-cke-realelement":encodeURIComponent(a.getOuterHtml()),"data-cke-real-node-type":a.type,
alt:k,title:k,align:a.getAttribute("align")||""};if(!CKEDITOR.env.hc)b.src=CKEDITOR.tools.transparentImageData;c&&(b["data-cke-real-element-type"]=c);if(h){b["data-cke-resizable"]=h;c=new f;h=a.getAttribute("width");a=a.getAttribute("height");h&&(c.rules.width=d(h));a&&(c.rules.height=d(a));c.populate(b)}return this.document.createElement("img",{attributes:b})};CKEDITOR.editor.prototype.createFakeParserElement=function(a,b,c,h){var k=this.lang.fakeobjects,k=k[c]||k.unknown,j;j=new CKEDITOR.htmlParser.basicWriter;
a.writeHtml(j);j=j.getHtml();b={"class":b,"data-cke-realelement":encodeURIComponent(j),"data-cke-real-node-type":a.type,alt:k,title:k,align:a.attributes.align||""};if(!CKEDITOR.env.hc)b.src=CKEDITOR.tools.transparentImageData;c&&(b["data-cke-real-element-type"]=c);if(h){b["data-cke-resizable"]=h;h=a.attributes;a=new f;c=h.width;h=h.height;c!==void 0&&(a.rules.width=d(c));h!==void 0&&(a.rules.height=d(h));a.populate(b)}return new CKEDITOR.htmlParser.element("img",b)};CKEDITOR.editor.prototype.restoreRealElement=
function(b){if(b.data("cke-real-node-type")!=CKEDITOR.NODE_ELEMENT)return null;var c=CKEDITOR.dom.element.createFromHtml(decodeURIComponent(b.data("cke-realelement")),this.document);if(b.data("cke-resizable")){var e=b.getStyle("width"),b=b.getStyle("height");e&&c.setAttribute("width",a(c.getAttribute("width"),e));b&&c.setAttribute("height",a(c.getAttribute("height"),b))}return c}})();(function(){function a(a){var b=a.config,g=a.fire("uiSpace",{space:"top",html:""}).html,i=function(){function e(a,
b,c){h.setStyle(b,d(c));h.setStyle("position",a)}function g(a){var b=k.getDocumentPosition();switch(a){case "top":e("absolute","top",b.y-u-t);break;case "pin":e("fixed","top",n);break;case "bottom":e("absolute","top",b.y+(r.height||r.bottom-r.top)+t)}j=a}var j,k,p,r,s,u,w,v=b.floatSpaceDockedOffsetX||0,t=b.floatSpaceDockedOffsetY||0,y=b.floatSpacePinnedOffsetX||0,n=b.floatSpacePinnedOffsetY||0;return function(b){if(k=a.editable()){b&&b.name=="focus"&&h.show();h.removeStyle("left");h.removeStyle("right");
p=h.getClientRect();r=k.getClientRect();s=f.getViewPaneSize();u=p.height;w="pageXOffset"in f.$?f.$.pageXOffset:CKEDITOR.document.$.documentElement.scrollLeft;if(j){u+t<=r.top?g("top"):u+t>s.height-r.bottom?g("pin"):g("bottom");var b=s.width/2,b=r.left>0&&r.right<s.width&&r.width>p.width?a.config.contentsLangDirection=="rtl"?"right":"left":b-r.left>r.right-b?"left":"right",e;if(p.width>s.width){b="left";e=0}else{e=b=="left"?r.left>0?r.left:0:r.right<s.width?s.width-r.right:0;if(e+p.width>s.width){b=
b=="left"?"right":"left";e=0}}h.setStyle(b,d((j=="pin"?y:v)+e+(j=="pin"?0:b=="left"?w:-w)))}else{j="pin";g("pin");i(b)}}}}();if(g){var e=new CKEDITOR.template('<div id="cke_{name}" class="cke {id} cke_reset_all cke_chrome cke_editor_{name} cke_float cke_{langDir} '+CKEDITOR.env.cssClass+'" dir="{langDir}" title="'+(CKEDITOR.env.gecko?" ":"")+'" lang="{langCode}" role="application" style="{style}"'+(a.title?' aria-labelledby="cke_{name}_arialbl"':" ")+">"+(a.title?'<span id="cke_{name}_arialbl" class="cke_voice_label">{voiceLabel}</span>':
" ")+'<div class="cke_inner"><div id="{topId}" class="cke_top" role="presentation">{content}</div></div></div>'),h=CKEDITOR.document.getBody().append(CKEDITOR.dom.element.createFromHtml(e.output({content:g,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}))),k=CKEDITOR.tools.eventsBuffer(500,i),j=CKEDITOR.tools.eventsBuffer(100,i);h.unselectable();h.on("mousedown",function(a){a=a.data;a.getTarget().hasAscendant("a",
1)||a.preventDefault()});a.on("focus",function(b){i(b);a.on("change",k.input);f.on("scroll",j.input);f.on("resize",j.input)});a.on("blur",function(){h.hide();a.removeListener("change",k.input);f.removeListener("scroll",j.input);f.removeListener("resize",j.input)});a.on("destroy",function(){f.removeListener("scroll",j.input);f.removeListener("resize",j.input);h.clearCustomData();h.remove()});a.focusManager.hasFocus&&h.show();a.focusManager.add(h,1)}}var f=CKEDITOR.document.getWindow(),d=CKEDITOR.tools.cssLength;
CKEDITOR.plugins.add("floatingspace",{init:function(c){c.on("loaded",function(){a(this)},null,null,20)}})})();CKEDITOR.plugins.add("listblock",{requires:"panel",onLoad:function(){var a=CKEDITOR.addTemplate("panel-list",'<ul role="presentation" class="cke_panel_list">{items}</ul>'),f=CKEDITOR.addTemplate("panel-list-item",'<li id="{id}" class="cke_panel_listItem" role=presentation><a id="{id}_option" _cke_focus=1 hidefocus=true title="{title}" href="javascript:void(\'{val}\')"  {onclick}="CKEDITOR.tools.callFunction({clickFn},\'{val}\'); return false;" role="option">{text}</a></li>'),
d=CKEDITOR.addTemplate("panel-list-group",'<h1 id="{id}" class="cke_panel_grouptitle" role="presentation" >{label}</h1>'),c=/\'/g;CKEDITOR.ui.panel.prototype.addListBlock=function(a,c){return this.addBlock(a,new CKEDITOR.ui.listBlock(this.getHolderElement(),c))};CKEDITOR.ui.listBlock=CKEDITOR.tools.createClass({base:CKEDITOR.ui.panel.block,$:function(a,c){var c=c||{},d=c.attributes||(c.attributes={});(this.multiSelect=!!c.multiSelect)&&(d["aria-multiselectable"]=true);!d.role&&(d.role="listbox");
this.base.apply(this,arguments);this.element.setAttribute("role",d.role);d=this.keys;d[40]="next";d[9]="next";d[38]="prev";d[CKEDITOR.SHIFT+9]="prev";d[32]=CKEDITOR.env.ie?"mouseup":"click";CKEDITOR.env.ie&&(d[13]="mouseup");this._.pendingHtml=[];this._.pendingList=[];this._.items={};this._.groups={}},_:{close:function(){if(this._.started){var b=a.output({items:this._.pendingList.join("")});this._.pendingList=[];this._.pendingHtml.push(b);delete this._.started}},getClick:function(){if(!this._.click)this._.click=
CKEDITOR.tools.addFunction(function(a){var c=this.toggle(a);if(this.onClick)this.onClick(a,c)},this);return this._.click}},proto:{add:function(a,d,i){var e=CKEDITOR.tools.getNextId();if(!this._.started){this._.started=1;this._.size=this._.size||0}this._.items[a]=e;var h;h=CKEDITOR.tools.htmlEncodeAttr(a).replace(c,"\\'");a={id:e,val:h,onclick:CKEDITOR.env.ie?'onclick="return false;" onmouseup':"onclick",clickFn:this._.getClick(),title:CKEDITOR.tools.htmlEncodeAttr(i||a),text:d||a};this._.pendingList.push(f.output(a))},
startGroup:function(a){this._.close();var c=CKEDITOR.tools.getNextId();this._.groups[a]=c;this._.pendingHtml.push(d.output({id:c,label:a}))},commit:function(){this._.close();this.element.appendHtml(this._.pendingHtml.join(""));delete this._.size;this._.pendingHtml=[]},toggle:function(a){var c=this.isMarked(a);c?this.unmark(a):this.mark(a);return!c},hideGroup:function(a){var c=(a=this.element.getDocument().getById(this._.groups[a]))&&a.getNext();if(a){a.setStyle("display","none");c&&c.getName()=="ul"&&
c.setStyle("display","none")}},hideItem:function(a){this.element.getDocument().getById(this._.items[a]).setStyle("display","none")},showAll:function(){var a=this._.items,c=this._.groups,d=this.element.getDocument(),e;for(e in a)d.getById(a[e]).setStyle("display","");for(var f in c){a=d.getById(c[f]);e=a.getNext();a.setStyle("display","");e&&e.getName()=="ul"&&e.setStyle("display","")}},mark:function(a){this.multiSelect||this.unmarkAll();var a=this._.items[a],c=this.element.getDocument().getById(a);
c.addClass("cke_selected");this.element.getDocument().getById(a+"_option").setAttribute("aria-selected",true);this.onMark&&this.onMark(c)},unmark:function(a){var c=this.element.getDocument(),a=this._.items[a],d=c.getById(a);d.removeClass("cke_selected");c.getById(a+"_option").removeAttribute("aria-selected");this.onUnmark&&this.onUnmark(d)},unmarkAll:function(){var a=this._.items,c=this.element.getDocument(),d;for(d in a){var e=a[d];c.getById(e).removeClass("cke_selected");c.getById(e+"_option").removeAttribute("aria-selected")}this.onUnmark&&
this.onUnmark()},isMarked:function(a){return this.element.getDocument().getById(this._.items[a]).hasClass("cke_selected")},focus:function(a){this._.focusIndex=-1;var c=this.element.getElementsByTag("a"),d,e=-1;if(a)for(d=this.element.getDocument().getById(this._.items[a]).getFirst();a=c.getItem(++e);){if(a.equals(d)){this._.focusIndex=e;break}}else this.element.focus();d&&setTimeout(function(){d.focus()},0)}}})}});CKEDITOR.plugins.add("richcombo",{requires:"floatpanel,listblock,button",beforeInit:function(a){a.ui.addHandler(CKEDITOR.UI_RICHCOMBO,
CKEDITOR.ui.richCombo.handler)}});(function(){var a='<span id="{id}" class="cke_combo cke_combo__{name} {cls}" role="presentation"><span id="{id}_label" class="cke_combo_label">{label}</span><a class="cke_combo_button" title="{title}" tabindex="-1"'+(CKEDITOR.env.gecko&&!CKEDITOR.env.hc?"":" href=\"javascript:void('{titleJs}')\"")+' hidefocus="true" role="button" aria-labelledby="{id}_label" aria-haspopup="true"';CKEDITOR.env.gecko&&CKEDITOR.env.mac&&(a=a+' onkeypress="return false;"');CKEDITOR.env.gecko&&
(a=a+' onblur="this.style.cssText = this.style.cssText;"');var a=a+(' onkeydown="return CKEDITOR.tools.callFunction({keydownFn},event,this);" onfocus="return CKEDITOR.tools.callFunction({focusFn},event);" '+(CKEDITOR.env.ie?'onclick="return false;" onmouseup':"onclick")+'="CKEDITOR.tools.callFunction({clickFn},this);return false;"><span id="{id}_text" class="cke_combo_text cke_combo_inlinelabel">{label}</span><span class="cke_combo_open"><span class="cke_combo_arrow">'+(CKEDITOR.env.hc?"&#9660;":
CKEDITOR.env.air?"&nbsp;":"")+"</span></span></a></span>"),f=CKEDITOR.addTemplate("combo",a);CKEDITOR.UI_RICHCOMBO="richcombo";CKEDITOR.ui.richCombo=CKEDITOR.tools.createClass({$:function(a){CKEDITOR.tools.extend(this,a,{canGroup:false,title:a.label,modes:{wysiwyg:1},editorFocus:1});a=this.panel||{};delete this.panel;this.id=CKEDITOR.tools.getNextNumber();this.document=a.parent&&a.parent.getDocument()||CKEDITOR.document;a.className="cke_combopanel";a.block={multiSelect:a.multiSelect,attributes:a.attributes};
a.toolbarRelated=true;this._={panelDefinition:a,items:{}}},proto:{renderHtml:function(a){var c=[];this.render(a,c);return c.join("")},render:function(a,c){function b(){if(this.getState()!=CKEDITOR.TRISTATE_ON){var b=this.modes[a.mode]?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED;if(a.readOnly&&!this.readOnly)b=CKEDITOR.TRISTATE_DISABLED;this.setState(b);this.setValue("");b!=CKEDITOR.TRISTATE_DISABLED&&this.refresh&&this.refresh()}}var g=CKEDITOR.env,i="cke_"+this.id,e=CKEDITOR.tools.addFunction(function(b){if(q){a.unlockSelection(1);
q=0}k.execute(b)},this),h=this,k={id:i,combo:this,focus:function(){CKEDITOR.document.getById(i).getChild(1).focus()},execute:function(b){var c=h._;if(c.state!=CKEDITOR.TRISTATE_DISABLED){h.createPanel(a);if(c.on)c.panel.hide();else{h.commit();var e=h.getValue();e?c.list.mark(e):c.list.unmarkAll();c.panel.showBlock(h.id,new CKEDITOR.dom.element(b),4)}}},clickFn:e};a.on("activeFilterChange",b,this);a.on("mode",b,this);a.on("selectionChange",b,this);!this.readOnly&&a.on("readOnly",b,this);var j=CKEDITOR.tools.addFunction(function(b,
c){var b=new CKEDITOR.dom.event(b),g=b.getKeystroke();if(g==40)a.once("panelShow",function(a){a.data._.panel._.currentBlock.onKeyDown(40)});switch(g){case 13:case 32:case 40:CKEDITOR.tools.callFunction(e,c);break;default:k.onkey(k,g)}b.preventDefault()}),m=CKEDITOR.tools.addFunction(function(){k.onfocus&&k.onfocus()}),q=0;k.keyDownFn=j;g={id:i,name:this.name||this.command,label:this.label,title:this.title,cls:this.className||"",titleJs:g.gecko&&!g.hc?"":(this.title||"").replace("'",""),keydownFn:j,
focusFn:m,clickFn:e};f.output(g,c);if(this.onRender)this.onRender();return k},createPanel:function(a){if(!this._.panel){var c=this._.panelDefinition,b=this._.panelDefinition.block,g=c.parent||CKEDITOR.document.getBody(),f="cke_combopanel__"+this.name,e=new CKEDITOR.ui.floatPanel(a,g,c),h=e.addListBlock(this.id,b),k=this;e.onShow=function(){this.element.addClass(f);k.setState(CKEDITOR.TRISTATE_ON);k._.on=1;k.editorFocus&&!a.focusManager.hasFocus&&a.focus();if(k.onOpen)k.onOpen();a.once("panelShow",
function(){h.focus(!h.multiSelect&&k.getValue())})};e.onHide=function(b){this.element.removeClass(f);k.setState(k.modes&&k.modes[a.mode]?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED);k._.on=0;if(!b&&k.onClose)k.onClose()};e.onEscape=function(){e.hide(1)};h.onClick=function(a,b){k.onClick&&k.onClick.call(k,a,b);e.hide()};this._.panel=e;this._.list=h;e.getBlock(this.id).onHide=function(){k._.on=0;k.setState(CKEDITOR.TRISTATE_OFF)};this.init&&this.init()}},setValue:function(a,c){this._.value=a;var b=
this.document.getById("cke_"+this.id+"_text");if(b){if(!a&&!c){c=this.label;b.addClass("cke_combo_inlinelabel")}else b.removeClass("cke_combo_inlinelabel");b.setText(typeof c!="undefined"?c:a)}},getValue:function(){return this._.value||""},unmarkAll:function(){this._.list.unmarkAll()},mark:function(a){this._.list.mark(a)},hideItem:function(a){this._.list.hideItem(a)},hideGroup:function(a){this._.list.hideGroup(a)},showAll:function(){this._.list.showAll()},add:function(a,c,b){this._.items[a]=b||a;
this._.list.add(a,c,b)},startGroup:function(a){this._.list.startGroup(a)},commit:function(){if(!this._.committed){this._.list.commit();this._.committed=1;CKEDITOR.ui.fire("ready",this)}this._.committed=1},setState:function(a){if(this._.state!=a){var c=this.document.getById("cke_"+this.id);c.setState(a,"cke_combo");a==CKEDITOR.TRISTATE_DISABLED?c.setAttribute("aria-disabled",true):c.removeAttribute("aria-disabled");this._.state=a}},getState:function(){return this._.state},enable:function(){this._.state==
CKEDITOR.TRISTATE_DISABLED&&this.setState(this._.lastState)},disable:function(){if(this._.state!=CKEDITOR.TRISTATE_DISABLED){this._.lastState=this._.state;this.setState(CKEDITOR.TRISTATE_DISABLED)}}},statics:{handler:{create:function(a){return new CKEDITOR.ui.richCombo(a)}}}});CKEDITOR.ui.prototype.addRichCombo=function(a,c){this.add(a,CKEDITOR.UI_RICHCOMBO,c)}})();(function(){function a(a,c,b,g,i,e,h,k){for(var j=a.config,m=new CKEDITOR.style(h),q=i.split(";"),i=[],l={},o=0;o<q.length;o++){var p=
q[o];if(p){var p=p.split("/"),r={},s=q[o]=p[0];r[b]=i[o]=p[1]||s;l[s]=new CKEDITOR.style(h,r);l[s]._.definition.name=s}else q.splice(o--,1)}a.ui.addRichCombo(c,{label:g.label,title:g.panelTitle,toolbar:"styles,"+k,allowedContent:m,requiredContent:m,panel:{css:[CKEDITOR.skin.getPath("editor")].concat(j.contentsCss),multiSelect:false,attributes:{"aria-label":g.panelTitle}},init:function(){this.startGroup(g.panelTitle);for(var a=0;a<q.length;a++){var b=q[a];this.add(b,l[b].buildPreview(),b)}},onClick:function(b){a.focus();
a.fire("saveSnapshot");var c=this.getValue(),e=l[b];if(c&&b!=c){var g=l[c],h=a.getSelection().getRanges()[0];if(h.collapsed){var i=a.elementPath(),j=i.contains(function(a){return g.checkElementRemovable(a)});if(j){var k=h.checkBoundaryOfElement(j,CKEDITOR.START),o=h.checkBoundaryOfElement(j,CKEDITOR.END);if(k&&o){for(k=h.createBookmark();i=j.getFirst();)i.insertBefore(j);j.remove();h.moveToBookmark(k)}else if(k)h.moveToPosition(j,CKEDITOR.POSITION_BEFORE_START);else if(o)h.moveToPosition(j,CKEDITOR.POSITION_AFTER_END);
else{h.splitElement(j);h.moveToPosition(j,CKEDITOR.POSITION_AFTER_END);f(h,i.elements.slice(),j)}a.getSelection().selectRanges([h])}}else a.removeStyle(g)}a[c==b?"removeStyle":"applyStyle"](e);a.fire("saveSnapshot")},onRender:function(){a.on("selectionChange",function(b){for(var c=this.getValue(),b=b.data.path.elements,g=0,f;g<b.length;g++){f=b[g];for(var h in l)if(l[h].checkElementMatch(f,true,a)){h!=c&&this.setValue(h);return}}this.setValue("",e)},this)},refresh:function(){a.activeFilter.check(m)||
this.setState(CKEDITOR.TRISTATE_DISABLED)}})}function f(a,c,b){var g=c.pop();if(g){if(b)return f(a,c,g.equals(b)?null:b);b=g.clone();a.insertNode(b);a.moveToPosition(b,CKEDITOR.POSITION_AFTER_START);f(a,c)}}CKEDITOR.plugins.add("font",{requires:"richcombo",init:function(d){var c=d.config;a(d,"Font","family",d.lang.font,c.font_names,c.font_defaultLabel,c.font_style,30);a(d,"FontSize","size",d.lang.font.fontSize,c.fontSize_sizes,c.fontSize_defaultLabel,c.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}}]};(function(){function a(a,b){var g,i;b.on("refresh",function(a){var b=[f],c;for(c in a.data.states)b.push(a.data.states[c]);this.setState(CKEDITOR.tools.search(b,
d)?d:f)},b,null,100);b.on("exec",function(b){g=a.getSelection();i=g.createBookmarks(1);if(!b.data)b.data={};b.data.done=false},b,null,0);b.on("exec",function(){a.forceNextSelectionCheck();g.selectBookmarks(i)},b,null,100)}var f=CKEDITOR.TRISTATE_DISABLED,d=CKEDITOR.TRISTATE_OFF;CKEDITOR.plugins.add("indent",{init:function(c){var b=CKEDITOR.plugins.indent.genericDefinition;a(c,c.addCommand("indent",new b(true)));a(c,c.addCommand("outdent",new b));if(c.ui.addButton){c.ui.addButton("Indent",{label:c.lang.indent.indent,
command:"indent",directional:true,toolbar:"indent,20"});c.ui.addButton("Outdent",{label:c.lang.indent.outdent,command:"outdent",directional:true,toolbar:"indent,10"})}c.on("dirChanged",function(a){var b=c.createRange(),e=a.data.node;b.setStartBefore(e);b.setEndAfter(e);for(var d=new CKEDITOR.dom.walker(b),f;f=d.next();)if(f.type==CKEDITOR.NODE_ELEMENT)if(!f.equals(e)&&f.getDirection()){b.setStartAfter(f);d=new CKEDITOR.dom.walker(b)}else{var j=c.config.indentClasses;if(j)for(var m=a.data.dir=="ltr"?
["_rtl",""]:["","_rtl"],q=0;q<j.length;q++)if(f.hasClass(j[q]+m[0])){f.removeClass(j[q]+m[0]);f.addClass(j[q]+m[1])}j=f.getStyle("margin-right");m=f.getStyle("margin-left");j?f.setStyle("margin-left",j):f.removeStyle("margin-left");m?f.setStyle("margin-right",m):f.removeStyle("margin-right")}})}});CKEDITOR.plugins.indent={genericDefinition:function(a){this.isIndent=!!a;this.startDisabled=!this.isIndent},specificDefinition:function(a,b,d){this.name=b;this.editor=a;this.jobs={};this.enterBr=a.config.enterMode==
CKEDITOR.ENTER_BR;this.isIndent=!!d;this.relatedGlobal=d?"indent":"outdent";this.indentKey=d?9:CKEDITOR.SHIFT+9;this.database={}},registerCommands:function(a,b){a.on("pluginsLoaded",function(){for(var a in b)(function(a,b){var c=a.getCommand(b.relatedGlobal),d;for(d in b.jobs){c.on("exec",function(c){if(!c.data.done){a.fire("lockSnapshot");if(b.execJob(a,d))c.data.done=true;a.fire("unlockSnapshot");CKEDITOR.dom.element.clearAllMarkers(b.database)}},this,null,d);c.on("refresh",function(c){if(!c.data.states)c.data.states=
{};c.data.states[b.name+"@"+d]=b.refreshJob(a,d,c.data.path)},this,null,d)}a.addFeature(b)})(this,b[a])})}};CKEDITOR.plugins.indent.genericDefinition.prototype={context:"p",exec:function(){}};CKEDITOR.plugins.indent.specificDefinition.prototype={execJob:function(a,b){var d=this.jobs[b];if(d.state!=f)return d.exec.call(this,a)},refreshJob:function(a,b,d){b=this.jobs[b];b.state=a.activeFilter.checkFeature(this)?b.refresh.call(this,a,d):f;return b.state},getContext:function(a){return a.contains(this.context)}}})();
(function(){function a(a,b,c){if(!a.getCustomData("indent_processed")){var d=this.editor,g=this.isIndent;if(b){d=a.$.className.match(this.classNameRegex);c=0;if(d){d=d[1];c=CKEDITOR.tools.indexOf(b,d)+1}if((c=c+(g?1:-1))<0)return;c=Math.min(c,b.length);c=Math.max(c,0);a.$.className=CKEDITOR.tools.ltrim(a.$.className.replace(this.classNameRegex,""));c>0&&a.addClass(b[c-1])}else{var b=f(a,c),c=parseInt(a.getStyle(b),10),m=d.config.indentOffset||40;isNaN(c)&&(c=0);c=c+(g?1:-1)*m;if(c<0)return;c=Math.max(c,
0);c=Math.ceil(c/m)*m;a.setStyle(b,c?c+(d.config.indentUnit||"px"):"");a.getAttribute("style")===""&&a.removeAttribute("style")}CKEDITOR.dom.element.setMarker(this.database,a,"indent_processed",1)}}function f(a,b){return(b||a.getComputedStyle("direction"))=="ltr"?"margin-left":"margin-right"}var d=CKEDITOR.dtd.$listItem,c=CKEDITOR.dtd.$list,b=CKEDITOR.TRISTATE_DISABLED,g=CKEDITOR.TRISTATE_OFF;CKEDITOR.plugins.add("indentblock",{requires:"indent",init:function(i){function e(){h.specificDefinition.apply(this,
arguments);this.allowedContent={"div h1 h2 h3 h4 h5 h6 ol p pre ul":{propertiesOnly:true,styles:!k?"margin-left,margin-right":null,classes:k||null}};if(this.enterBr)this.allowedContent.div=true;this.requiredContent=(this.enterBr?"div":"p")+(k?"("+k.join(",")+")":"{margin-left}");this.jobs={20:{refresh:function(a,c){var e=c.block||c.blockLimit;e.is(d)||(e=e.getAscendant(d)||e);e.is(d)&&(e=e.getParent());if(!this.enterBr&&!this.getContext(c))return b;if(k){var h;h=k;var e=e.$.className.match(this.classNameRegex),
i=this.isIndent;h=e?i?e[1]!=h.slice(-1):true:i;return h?g:b}return this.isIndent?g:e?CKEDITOR[(parseInt(e.getStyle(f(e)),10)||0)<=0?"TRISTATE_DISABLED":"TRISTATE_OFF"]:b},exec:function(b){var e=b.getSelection(),e=e&&e.getRanges()[0],d;if(d=b.elementPath().contains(c))a.call(this,d,k);else{e=e.createIterator();b=b.config.enterMode;e.enforceRealBlocks=true;for(e.enlargeBr=b!=CKEDITOR.ENTER_BR;d=e.getNextParagraph(b==CKEDITOR.ENTER_P?"p":"div");)d.isReadOnly()||a.call(this,d,k)}return true}}}}var h=
CKEDITOR.plugins.indent,k=i.config.indentClasses;h.registerCommands(i,{indentblock:new e(i,"indentblock",true),outdentblock:new e(i,"outdentblock")});CKEDITOR.tools.extend(e.prototype,h.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:k?RegExp("(?:^|\\s+)("+k.join("|")+")(?=$|\\s)"):null})}})})();(function(){function a(a){function b(f){for(var h=l.startContainer,o=l.endContainer;h&&!h.getParent().equals(f);)h=h.getParent();
for(;o&&!o.getParent().equals(f);)o=o.getParent();if(!h||!o)return false;for(var p=h,h=[],q=false;!q;){p.equals(o)&&(q=true);h.push(p);p=p.getNext()}if(h.length<1)return false;p=f.getParents(true);for(o=0;o<p.length;o++)if(p[o].getName&&i[p[o].getName()]){f=p[o];break}for(var p=c.isIndent?1:-1,o=h[0],h=h[h.length-1],q=CKEDITOR.plugins.list.listToArray(f,g),t=q[h.getCustomData("listarray_index")].indent,o=o.getCustomData("listarray_index");o<=h.getCustomData("listarray_index");o++){q[o].indent=q[o].indent+
p;if(p>0){var y=q[o].parent;q[o].parent=new CKEDITOR.dom.element(y.getName(),y.getDocument())}}for(o=h.getCustomData("listarray_index")+1;o<q.length&&q[o].indent>t;o++)q[o].indent=q[o].indent+p;h=CKEDITOR.plugins.list.arrayToList(q,g,null,a.config.enterMode,f.getDirection());if(!c.isIndent){var n;if((n=f.getParent())&&n.is("li"))for(var p=h.listNode.getChildren(),x=[],z,o=p.count()-1;o>=0;o--)(z=p.getItem(o))&&(z.is&&z.is("li"))&&x.push(z)}h&&h.listNode.replace(f);if(x&&x.length)for(o=0;o<x.length;o++){for(z=
f=x[o];(z=z.getNext())&&z.is&&z.getName()in i;){CKEDITOR.env.needsNbspFiller&&!f.getFirst(d)&&f.append(l.document.createText(" "));f.append(z)}f.insertAfter(n)}h&&a.fire("contentDomInvalidated");return true}for(var c=this,g=this.database,i=this.context,q=a.getSelection(),q=(q&&q.getRanges()).createIterator(),l;l=q.getNextRange();){for(var o=l.getCommonAncestor();o&&!(o.type==CKEDITOR.NODE_ELEMENT&&i[o.getName()]);)o=o.getParent();o||(o=l.startPath().contains(i))&&l.setEndAt(o,CKEDITOR.POSITION_BEFORE_END);
if(!o){var p=l.getEnclosedNode();if(p&&p.type==CKEDITOR.NODE_ELEMENT&&p.getName()in i){l.setStartAt(p,CKEDITOR.POSITION_AFTER_START);l.setEndAt(p,CKEDITOR.POSITION_BEFORE_END);o=p}}if(o&&l.startContainer.type==CKEDITOR.NODE_ELEMENT&&l.startContainer.getName()in i){p=new CKEDITOR.dom.walker(l);p.evaluator=f;l.startContainer=p.next()}if(o&&l.endContainer.type==CKEDITOR.NODE_ELEMENT&&l.endContainer.getName()in i){p=new CKEDITOR.dom.walker(l);p.evaluator=f;l.endContainer=p.previous()}if(o)return b(o)}return 0}
function f(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.is("li")}function d(a){return c(a)&&b(a)}var c=CKEDITOR.dom.walker.whitespaces(true),b=CKEDITOR.dom.walker.bookmark(false,true),g=CKEDITOR.TRISTATE_DISABLED,i=CKEDITOR.TRISTATE_OFF;CKEDITOR.plugins.add("indentlist",{requires:"indent",init:function(b){function c(b){d.specificDefinition.apply(this,arguments);this.requiredContent=["ul","ol"];b.on("key",function(a){if(b.mode=="wysiwyg"&&a.data.keyCode==this.indentKey){var c=this.getContext(b.elementPath());
if(c&&(!this.isIndent||!CKEDITOR.plugins.indentList.firstItemInPath(this.context,b.elementPath(),c))){b.execCommand(this.relatedGlobal);a.cancel()}}},this);this.jobs[this.isIndent?10:30]={refresh:this.isIndent?function(a,b){var c=this.getContext(b),e=CKEDITOR.plugins.indentList.firstItemInPath(this.context,b,c);return!c||!this.isIndent||e?g:i}:function(a,b){return!this.getContext(b)||this.isIndent?g:i},exec:CKEDITOR.tools.bind(a,this)}}var d=CKEDITOR.plugins.indent;d.registerCommands(b,{indentlist:new c(b,
"indentlist",true),outdentlist:new c(b,"outdentlist")});CKEDITOR.tools.extend(c.prototype,d.specificDefinition.prototype,{context:{ol:1,ul:1}})}});CKEDITOR.plugins.indentList={};CKEDITOR.plugins.indentList.firstItemInPath=function(a,b,c){var d=b.contains(f);c||(c=b.contains(a));return c&&d&&d.equals(c.getFirst(f))}})();(function(){function a(a,b){var b=b===void 0||b,d;if(b)d=a.getComputedStyle("text-align");else{for(;!a.hasAttribute||!a.hasAttribute("align")&&!a.getStyle("text-align");){d=a.getParent();
if(!d)break;a=d}d=a.getStyle("text-align")||a.getAttribute("align")||""}d&&(d=d.replace(/(?:-(?:moz|webkit)-)?(?:start|auto)/i,""));!d&&b&&(d=a.getComputedStyle("direction")=="rtl"?"right":"left");return d}function f(a,b,d){this.editor=a;this.name=b;this.value=d;this.context="p";var b=a.config.justifyClasses,f=a.config.enterMode==CKEDITOR.ENTER_P?"p":"div";if(b){switch(d){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=RegExp("(?:^|\\s+)(?:"+b.join("|")+")(?=$|\\s)");this.requiredContent=f+"("+this.cssClassName+")"}else this.requiredContent=f+"{text-align}";this.allowedContent={"caption div h1 h2 h3 h4 h5 h6 p pre td th li":{propertiesOnly:true,styles:this.cssClassName?null:"text-align",classes:this.cssClassName||null}};if(a.config.enterMode==CKEDITOR.ENTER_BR)this.allowedContent.div=true}function d(a){var b=a.editor,d=b.createRange();d.setStartBefore(a.data.node);
d.setEndAfter(a.data.node);for(var f=new CKEDITOR.dom.walker(d),e;e=f.next();)if(e.type==CKEDITOR.NODE_ELEMENT)if(!e.equals(a.data.node)&&e.getDirection()){d.setStartAfter(e);f=new CKEDITOR.dom.walker(d)}else{var h=b.config.justifyClasses;if(h)if(e.hasClass(h[0])){e.removeClass(h[0]);e.addClass(h[2])}else if(e.hasClass(h[2])){e.removeClass(h[2]);e.addClass(h[0])}h=e.getStyle("text-align");h=="left"?e.setStyle("text-align","right"):h=="right"&&e.setStyle("text-align","left")}}f.prototype={exec:function(c){var b=
c.getSelection(),d=c.config.enterMode;if(b){for(var f=b.createBookmarks(),e=b.getRanges(),h=this.cssClassName,k,j,m=c.config.useComputedState,m=m===void 0||m,q=e.length-1;q>=0;q--){k=e[q].createIterator();for(k.enlargeBr=d!=CKEDITOR.ENTER_BR;j=k.getNextParagraph(d==CKEDITOR.ENTER_P?"p":"div");)if(!j.isReadOnly()){j.removeAttribute("align");j.removeStyle("text-align");var l=h&&(j.$.className=CKEDITOR.tools.ltrim(j.$.className.replace(this.cssClassRegex,""))),o=this.state==CKEDITOR.TRISTATE_OFF&&(!m||
a(j,true)!=this.value);h?o?j.addClass(h):l||j.removeAttribute("class"):o&&j.setStyle("text-align",this.value)}}c.focus();c.forceNextSelectionCheck();b.selectBookmarks(f)}},refresh:function(c,b){var d=b.block||b.blockLimit;this.setState(d.getName()!="body"&&a(d,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 f(a,"justifyleft","left"),g=new f(a,"justifycenter","center"),i=new f(a,
"justifyright","right"),e=new f(a,"justifyblock","justify");a.addCommand("justifyleft",b);a.addCommand("justifycenter",g);a.addCommand("justifyright",i);a.addCommand("justifyblock",e);if(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",d)}}})})();(function(){function a(a,b,c){function e(c){if((j=i[c?"getFirst":"getLast"]())&&(!j.is||!j.isBlockBoundary())&&(k=b.root[c?"getPrevious":"getNext"](CKEDITOR.dom.walker.invisible(true)))&&(!k.is||!k.isBlockBoundary({br:1})))a.document.createElement("br")[c?"insertBefore":"insertAfter"](j)}for(var d=CKEDITOR.plugins.list.listToArray(b.root,c),f=[],g=0;g<b.contents.length;g++){var h=
b.contents[g];if((h=h.getAscendant("li",true))&&!h.getCustomData("list_item_processed")){f.push(h);CKEDITOR.dom.element.setMarker(c,h,"list_item_processed",true)}}h=null;for(g=0;g<f.length;g++){h=f[g].getCustomData("listarray_index");d[h].indent=-1}for(g=h+1;g<d.length;g++)if(d[g].indent>d[g-1].indent+1){f=d[g-1].indent+1-d[g].indent;for(h=d[g].indent;d[g]&&d[g].indent>=h;){d[g].indent=d[g].indent+f;g++}g--}var i=CKEDITOR.plugins.list.arrayToList(d,c,null,a.config.enterMode,b.root.getAttribute("dir")).listNode,
j,k;e(true);e();i.replace(b.root);a.fire("contentDomInvalidated")}function f(a,b){this.name=a;this.context=this.type=b;this.allowedContent=b+" li";this.requiredContent=b}function d(a,b,c,e){for(var d,g;d=a[e?"getLast":"getFirst"](l);){(g=d.getDirection(1))!==b.getDirection(1)&&d.setAttribute("dir",g);d.remove();c?d[e?"insertBefore":"insertAfter"](c):b.append(d,e)}}function c(a){function b(c){var e=a[c?"getPrevious":"getNext"](j);if(e&&e.type==CKEDITOR.NODE_ELEMENT&&e.is(a.getName())){d(a,e,null,!c);
a.remove();a=e}}b();b(1)}function b(a){return a.type==CKEDITOR.NODE_ELEMENT&&(a.getName()in CKEDITOR.dtd.$block||a.getName()in CKEDITOR.dtd.$listItem)&&CKEDITOR.dtd[a.getName()]["#"]}function g(a,b,e){a.fire("saveSnapshot");e.enlarge(CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS);var g=e.extractContents();b.trim(false,true);var f=b.createBookmark(),h=new CKEDITOR.dom.elementPath(b.startContainer),k=h.block,h=h.lastElement.getAscendant("li",1)||k,l=new CKEDITOR.dom.elementPath(e.startContainer),q=l.contains(CKEDITOR.dtd.$listItem),
l=l.contains(CKEDITOR.dtd.$list);if(k)(k=k.getBogus())&&k.remove();else if(l)(k=l.getPrevious(j))&&m(k)&&k.remove();(k=g.getLast())&&(k.type==CKEDITOR.NODE_ELEMENT&&k.is("br"))&&k.remove();(k=b.startContainer.getChild(b.startOffset))?g.insertBefore(k):b.startContainer.append(g);if(q)if(g=i(q))if(h.contains(q)){d(g,q.getParent(),q);g.remove()}else h.append(g);for(;e.checkStartOfBlock()&&e.checkEndOfBlock();){l=e.startPath();g=l.block;if(!g)break;if(g.is("li")){h=g.getParent();g.equals(h.getLast(j))&&
g.equals(h.getFirst(j))&&(g=h)}e.moveToPosition(g,CKEDITOR.POSITION_BEFORE_START);g.remove()}e=e.clone();g=a.editable();e.setEndAt(g,CKEDITOR.POSITION_BEFORE_END);e=new CKEDITOR.dom.walker(e);e.evaluator=function(a){return j(a)&&!m(a)};(e=e.next())&&(e.type==CKEDITOR.NODE_ELEMENT&&e.getName()in CKEDITOR.dtd.$list)&&c(e);b.moveToBookmark(f);b.select();a.fire("saveSnapshot")}function i(a){return(a=a.getLast(j))&&a.type==CKEDITOR.NODE_ELEMENT&&a.getName()in e?a:null}var e={ol:1,ul:1},h=CKEDITOR.dom.walker.whitespaces(),
k=CKEDITOR.dom.walker.bookmark(),j=function(a){return!(h(a)||k(a))},m=CKEDITOR.dom.walker.bogus();CKEDITOR.plugins.list={listToArray:function(a,b,c,d,g){if(!e[a.getName()])return[];d||(d=0);c||(c=[]);for(var f=0,h=a.getChildCount();f<h;f++){var i=a.getChild(f);i.type==CKEDITOR.NODE_ELEMENT&&i.getName()in CKEDITOR.dtd.$list&&CKEDITOR.plugins.list.listToArray(i,b,c,d+1);if(i.$.nodeName.toLowerCase()=="li"){var j={parent:a,indent:d,element:i,contents:[]};if(g)j.grandparent=g;else{j.grandparent=a.getParent();
if(j.grandparent&&j.grandparent.$.nodeName.toLowerCase()=="li")j.grandparent=j.grandparent.getParent()}b&&CKEDITOR.dom.element.setMarker(b,i,"listarray_index",c.length);c.push(j);for(var k=0,m=i.getChildCount(),l;k<m;k++){l=i.getChild(k);l.type==CKEDITOR.NODE_ELEMENT&&e[l.getName()]?CKEDITOR.plugins.list.listToArray(l,b,c,d+1,j.grandparent):j.contents.push(l)}}}return c},arrayToList:function(a,b,c,d,g){c||(c=0);if(!a||a.length<c+1)return null;for(var f,h=a[c].parent.getDocument(),i=new CKEDITOR.dom.documentFragment(h),
m=null,n=c,l=Math.max(a[c].indent,0),q=null,B,C,H=d==CKEDITOR.ENTER_P?"p":"div";;){var F=a[n];f=F.grandparent;B=F.element.getDirection(1);if(F.indent==l){if(!m||a[n].parent.getName()!=m.getName()){m=a[n].parent.clone(false,1);g&&m.setAttribute("dir",g);i.append(m)}q=m.append(F.element.clone(0,1));B!=m.getDirection(1)&&q.setAttribute("dir",B);for(f=0;f<F.contents.length;f++)q.append(F.contents[f].clone(1,1));n++}else if(F.indent==Math.max(l,0)+1){F=a[n-1].element.getDirection(1);n=CKEDITOR.plugins.list.arrayToList(a,
null,n,d,F!=B?B:null);!q.getChildCount()&&(CKEDITOR.env.needsNbspFiller&&h.$.documentMode<=7)&&q.append(h.createText(" "));q.append(n.listNode);n=n.nextIndex}else if(F.indent==-1&&!c&&f){if(e[f.getName()]){q=F.element.clone(false,true);B!=f.getDirection(1)&&q.setAttribute("dir",B)}else q=new CKEDITOR.dom.documentFragment(h);var m=f.getDirection(1)!=B,I=F.element,A=I.getAttribute("class"),D=I.getAttribute("style"),E=q.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT&&(d!=CKEDITOR.ENTER_BR||m||D||A),G,K=F.contents.length,
N;for(f=0;f<K;f++){G=F.contents[f];if(k(G)&&K>1)E?N=G.clone(1,1):q.append(G.clone(1,1));else if(G.type==CKEDITOR.NODE_ELEMENT&&G.isBlockBoundary()){m&&!G.getDirection()&&G.setAttribute("dir",B);C=G;var Q=I.getAttribute("style");Q&&C.setAttribute("style",Q.replace(/([^;])$/,"$1;")+(C.getAttribute("style")||""));A&&G.addClass(A);C=null;if(N){q.append(N);N=null}q.append(G.clone(1,1))}else if(E){if(!C){C=h.createElement(H);q.append(C);m&&C.setAttribute("dir",B)}D&&C.setAttribute("style",D);A&&C.setAttribute("class",
A);if(N){C.append(N);N=null}C.append(G.clone(1,1))}else q.append(G.clone(1,1))}if(N){(C||q).append(N);N=null}if(q.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT&&n!=a.length-1){if(CKEDITOR.env.needsBrFiller)(B=q.getLast())&&(B.type==CKEDITOR.NODE_ELEMENT&&B.is("br"))&&B.remove();B=q.getLast(j);(!B||!(B.type==CKEDITOR.NODE_ELEMENT&&B.is(CKEDITOR.dtd.$block)))&&q.append(h.createElement("br"))}B=q.$.nodeName.toLowerCase();(B=="div"||B=="p")&&q.appendBogus();i.append(q);m=null;n++}else return null;C=null;if(a.length<=
n||Math.max(a[n].indent,0)<l)break}if(b)for(a=i.getFirst();a;){if(a.type==CKEDITOR.NODE_ELEMENT){CKEDITOR.dom.element.clearMarkers(b,a);if(a.getName()in CKEDITOR.dtd.$listItem){c=a;h=g=d=void 0;if(d=c.getDirection()){for(g=c.getParent();g&&!(h=g.getDirection());)g=g.getParent();d==h&&c.removeAttribute("dir")}}}a=a.getNextSourceNode()}return{listNode:i,nextIndex:n}}};var q=/^h[1-6]$/,l=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_ELEMENT);f.prototype={exec:function(b){this.refresh(b,b.elementPath());
var d=b.config,g=b.getSelection(),f=g&&g.getRanges();if(this.state==CKEDITOR.TRISTATE_OFF){var h=b.editable();if(h.getFirst(j)){var i=f.length==1&&f[0];(d=i&&i.getEnclosedNode())&&(d.is&&this.type==d.getName())&&this.setState(CKEDITOR.TRISTATE_ON)}else{d.enterMode==CKEDITOR.ENTER_BR?h.appendBogus():f[0].fixBlock(1,d.enterMode==CKEDITOR.ENTER_P?"p":"div");g.selectRanges(f)}}for(var d=g.createBookmarks(true),h=[],k={},f=f.createIterator(),m=0;(i=f.getNextRange())&&++m;){var l=i.getBoundaryNodes(),n=
l.startNode,x=l.endNode;n.type==CKEDITOR.NODE_ELEMENT&&n.getName()=="td"&&i.setStartAt(l.startNode,CKEDITOR.POSITION_AFTER_START);x.type==CKEDITOR.NODE_ELEMENT&&x.getName()=="td"&&i.setEndAt(l.endNode,CKEDITOR.POSITION_BEFORE_END);i=i.createIterator();for(i.forceBrBreak=this.state==CKEDITOR.TRISTATE_OFF;l=i.getNextParagraph();)if(!l.getCustomData("list_block")){CKEDITOR.dom.element.setMarker(k,l,"list_block",1);for(var z=b.elementPath(l),n=z.elements,x=0,z=z.blockLimit,B,C=n.length-1;C>=0&&(B=n[C]);C--)if(e[B.getName()]&&
z.contains(B)){z.removeCustomData("list_group_object_"+m);if(n=B.getCustomData("list_group_object"))n.contents.push(l);else{n={root:B,contents:[l]};h.push(n);CKEDITOR.dom.element.setMarker(k,B,"list_group_object",n)}x=1;break}if(!x){x=z;if(x.getCustomData("list_group_object_"+m))x.getCustomData("list_group_object_"+m).contents.push(l);else{n={root:x,contents:[l]};CKEDITOR.dom.element.setMarker(k,x,"list_group_object_"+m,n);h.push(n)}}}}for(B=[];h.length>0;){n=h.shift();if(this.state==CKEDITOR.TRISTATE_OFF)if(e[n.root.getName()]){f=
b;m=n;n=k;i=B;x=CKEDITOR.plugins.list.listToArray(m.root,n);z=[];for(l=0;l<m.contents.length;l++){C=m.contents[l];if((C=C.getAscendant("li",true))&&!C.getCustomData("list_item_processed")){z.push(C);CKEDITOR.dom.element.setMarker(n,C,"list_item_processed",true)}}for(var C=m.root.getDocument(),H=void 0,F=void 0,l=0;l<z.length;l++){var I=z[l].getCustomData("listarray_index"),H=x[I].parent;if(!H.is(this.type)){F=C.createElement(this.type);H.copyAttributes(F,{start:1,type:1});F.removeStyle("list-style-type");
x[I].parent=F}}n=CKEDITOR.plugins.list.arrayToList(x,n,null,f.config.enterMode);x=void 0;z=n.listNode.getChildCount();for(l=0;l<z&&(x=n.listNode.getChild(l));l++)x.getName()==this.type&&i.push(x);n.listNode.replace(m.root);f.fire("contentDomInvalidated")}else{x=b;l=n;i=B;z=l.contents;f=l.root.getDocument();m=[];if(z.length==1&&z[0].equals(l.root)){n=f.createElement("div");z[0].moveChildren&&z[0].moveChildren(n);z[0].append(n);z[0]=n}l=l.contents[0].getParent();for(C=0;C<z.length;C++)l=l.getCommonAncestor(z[C].getParent());
H=x.config.useComputedState;x=n=void 0;H=H===void 0||H;for(C=0;C<z.length;C++)for(F=z[C];I=F.getParent();){if(I.equals(l)){m.push(F);!x&&F.getDirection()&&(x=1);F=F.getDirection(H);n!==null&&(n=n&&n!=F?null:F);break}F=I}if(!(m.length<1)){z=m[m.length-1].getNext();C=f.createElement(this.type);i.push(C);for(H=i=void 0;m.length;){i=m.shift();H=f.createElement("li");if(i.is("pre")||q.test(i.getName())||i.getAttribute("contenteditable")=="false")i.appendTo(H);else{i.copyAttributes(H);if(n&&i.getDirection()){H.removeStyle("direction");
H.removeAttribute("dir")}i.moveChildren(H);i.remove()}H.appendTo(C)}n&&x&&C.setAttribute("dir",n);z?C.insertBefore(z):C.appendTo(l)}}else this.state==CKEDITOR.TRISTATE_ON&&e[n.root.getName()]&&a.call(this,b,n,k)}for(C=0;C<B.length;C++)c(B[C]);CKEDITOR.dom.element.clearAllMarkers(k);g.selectBookmarks(d);b.focus()},refresh:function(a,b){var c=b.contains(e,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){if(!a.blockless){a.addCommand("numberedlist",new f("numberedlist","ol"));a.addCommand("bulletedlist",new f("bulletedlist","ul"));if(a.ui.addButton){a.ui.addButton("NumberedList",{label:a.lang.list.numberedlist,command:"numberedlist",directional:true,toolbar:"list,10"});a.ui.addButton("BulletedList",{label:a.lang.list.bulletedlist,command:"bulletedlist",directional:true,toolbar:"list,20"})}a.on("key",function(c){var d=c.data.domEvent.getKey(),
f;if(a.mode=="wysiwyg"&&d in{8:1,46:1}){var h=a.getSelection().getRanges()[0],k=h&&h.startPath();if(h&&h.collapsed){var l=d==8,q=a.editable(),y=new CKEDITOR.dom.walker(h.clone());y.evaluator=function(a){return j(a)&&!m(a)};y.guard=function(a,b){return!(b&&a.type==CKEDITOR.NODE_ELEMENT&&a.is("table"))};d=h.clone();if(l){var n;if((n=k.contains(e))&&h.checkBoundaryOfElement(n,CKEDITOR.START)&&(n=n.getParent())&&n.is("li")&&(n=i(n))){f=n;n=n.getPrevious(j);d.moveToPosition(n&&m(n)?n:f,CKEDITOR.POSITION_BEFORE_START)}else{y.range.setStartAt(q,
CKEDITOR.POSITION_AFTER_START);y.range.setEnd(h.startContainer,h.startOffset);if((n=y.previous())&&n.type==CKEDITOR.NODE_ELEMENT&&(n.getName()in e||n.is("li"))){if(!n.is("li")){y.range.selectNodeContents(n);y.reset();y.evaluator=b;n=y.previous()}f=n;d.moveToElementEditEnd(f)}}if(f){g(a,d,h);c.cancel()}else if((d=k.contains(e))&&h.checkBoundaryOfElement(d,CKEDITOR.START)){f=d.getFirst(j);if(h.checkBoundaryOfElement(f,CKEDITOR.START)){n=d.getPrevious(j);if(i(f)){if(n){h.moveToElementEditEnd(n);h.select()}}else a.execCommand("outdent");
c.cancel()}}}else if(f=k.contains("li")){y.range.setEndAt(q,CKEDITOR.POSITION_BEFORE_END);f=(k=f.getLast(j))&&b(k)?k:f;q=0;if((n=y.next())&&n.type==CKEDITOR.NODE_ELEMENT&&n.getName()in e&&n.equals(k)){q=1;n=y.next()}else h.checkBoundaryOfElement(f,CKEDITOR.END)&&(q=1);if(q&&n){h=h.clone();h.moveToElementEditStart(n);g(a,d,h);c.cancel()}}else{y.range.setEndAt(q,CKEDITOR.POSITION_BEFORE_END);if((n=y.next())&&n.type==CKEDITOR.NODE_ELEMENT&&n.is(e)){n=n.getFirst(j);if(k.block&&h.checkStartOfBlock()&&
h.checkEndOfBlock()){k.block.remove();h.moveToElementEditStart(n);h.select()}else if(i(n)){h.moveToElementEditStart(n);h.select()}else{h=h.clone();h.moveToElementEditStart(n);g(a,d,h)}c.cancel()}}setTimeout(function(){a.selectionChange(1)})}}})}}})})();"use strict";(function(){function a(a,b,c){return j(b)&&j(c)&&c.equals(b.getNext(function(a){return!(Y(a)||Z(a)||m(a))}))}function f(a){this.upper=a[0];this.lower=a[1];this.set.apply(this,a.slice(2))}function d(a){var b=a.element;if(b&&j(b))if((b=b.getAscendant(a.triggers,
true))&&a.editable.contains(b)){var c=g(b);if(c.getAttribute("contenteditable")=="true")return b;if(c.is(a.triggers))return c}return null}function c(a,b,c){w(a,b);w(a,c);a=b.size.bottom;c=c.size.top;return a&&c?0|(a+c)/2:a||c}function b(a,b,c){return b=b[c?"getPrevious":"getNext"](function(b){return b&&b.type==CKEDITOR.NODE_TEXT&&!Y(b)||j(b)&&!m(b)&&!k(a,b)})}function g(a,b){if(a.data("cke-editable"))return null;for(b||(a=a.getParent());a;){if(a.data("cke-editable"))break;if(a.hasAttribute("contenteditable"))return a;
a=a.getParent()}return null}function i(a){var b=a.doc,c=z('<span contenteditable="false" style="'+P+"position:absolute;border-top:1px dashed "+a.boxColor+'"></span>',b),d=CKEDITOR.getUrl(this.path+"images/"+(B.hidpi?"hidpi/":"")+"icon"+(a.rtl?"-rtl":"")+".png");n(c,{attach:function(){this.wrap.getParent()||this.wrap.appendTo(a.editable,true);return this},lineChildren:[n(z('<span title="'+a.editor.lang.magicline.title+'" contenteditable="false">&#8629;</span>',b),{base:P+"height:17px;width:17px;"+
(a.rtl?"left":"right")+":17px;background:url("+d+") center no-repeat "+a.boxColor+";cursor:pointer;"+(B.hc?"font-size: 15px;line-height:14px;border:1px solid #fff;text-align:center;":"")+(B.hidpi?"background-size: 9px 10px;":""),looks:["top:-8px;"+CKEDITOR.tools.cssVendorPrefix("border-radius","2px",1),"top:-17px;"+CKEDITOR.tools.cssVendorPrefix("border-radius","2px 2px 0px 0px",1),"top:-1px;"+CKEDITOR.tools.cssVendorPrefix("border-radius","0px 0px 2px 2px",1)]}),n(z(W,b),{base:V+"left:0px;border-left-color:"+
a.boxColor+";",looks:["border-width:8px 0 8px 8px;top:-8px","border-width:8px 0 0 8px;top:-8px","border-width:0 0 8px 8px;top:0px"]}),n(z(W,b),{base:V+"right:0px;border-right-color:"+a.boxColor+";",looks:["border-width:8px 8px 8px 0;top:-8px","border-width:8px 8px 0 0;top:-8px","border-width:0 8px 8px 0;top:0px"]})],detach:function(){this.wrap.getParent()&&this.wrap.remove();return this},mouseNear:function(){w(a,this);var b=a.holdDistance,c=this.size;return c&&a.mouse.y>c.top-b&&a.mouse.y<c.bottom+
b&&a.mouse.x>c.left-b&&a.mouse.x<c.right+b?true:false},place:function(){var b=a.view,c=a.editable,e=a.trigger,d=e.upper,g=e.lower,f=d||g,h=f.getParent(),i={};this.trigger=e;d&&w(a,d,true);g&&w(a,g,true);w(a,h,true);a.inInlineMode&&v(a,true);if(h.equals(c)){i.left=b.scroll.x;i.right=-b.scroll.x;i.width=""}else{i.left=f.size.left-f.size.margin.left+b.scroll.x-(a.inInlineMode?b.editable.left+b.editable.border.left:0);i.width=f.size.outerWidth+f.size.margin.left+f.size.margin.right+b.scroll.x;i.right=
""}if(d&&g)i.top=d.size.margin.bottom===g.size.margin.top?0|d.size.bottom+d.size.margin.bottom/2:d.size.margin.bottom<g.size.margin.top?d.size.bottom+d.size.margin.bottom:d.size.bottom+d.size.margin.bottom-g.size.margin.top;else if(d){if(!g)i.top=d.size.bottom+d.size.margin.bottom}else i.top=g.size.top-g.size.margin.top;if(e.is(K)||i.top>b.scroll.y-15&&i.top<b.scroll.y+5){i.top=a.inInlineMode?0:b.scroll.y;this.look(K)}else if(e.is(N)||i.top>b.pane.bottom-5&&i.top<b.pane.bottom+15){i.top=a.inInlineMode?
b.editable.height+b.editable.padding.top+b.editable.padding.bottom:b.pane.bottom-1;this.look(N)}else{if(a.inInlineMode)i.top=i.top-(b.editable.top+b.editable.border.top);this.look(Q)}if(a.inInlineMode){i.top--;i.top=i.top+b.editable.scroll.top;i.left=i.left+b.editable.scroll.left}for(var j in i)i[j]=CKEDITOR.tools.cssLength(i[j]);this.setStyles(i)},look:function(a){if(this.oldLook!=a){for(var b=this.lineChildren.length,c;b--;)(c=this.lineChildren[b]).setAttribute("style",c.base+c.looks[0|a/2]);this.oldLook=
a}},wrap:new x("span",a.doc)});for(b=c.lineChildren.length;b--;)c.lineChildren[b].appendTo(c);c.look(Q);c.appendTo(c.wrap);c.unselectable();c.lineChildren[0].on("mouseup",function(b){c.detach();e(a,function(b){var c=a.line.trigger;b[c.is(I)?"insertBefore":"insertAfter"](c.is(I)?c.lower:c.upper)},true);a.editor.focus();!B.ie&&a.enterMode!=CKEDITOR.ENTER_BR&&a.hotNode.scrollIntoView();b.data.preventDefault(true)});c.on("mousedown",function(a){a.data.preventDefault(true)});a.line=c}function e(a,b,c){var e=
new CKEDITOR.dom.range(a.doc),d=a.editor,f;if(B.ie&&a.enterMode==CKEDITOR.ENTER_BR)f=a.doc.createText(O);else{f=(f=g(a.element,true))&&f.data("cke-enter-mode")||a.enterMode;f=new x(F[f],a.doc);f.is("br")||a.doc.createText(O).appendTo(f)}c&&d.fire("saveSnapshot");b(f);e.moveToPosition(f,CKEDITOR.POSITION_AFTER_START);d.getSelection().selectRanges([e]);a.hotNode=f;c&&d.fire("saveSnapshot")}function h(a,c){return{canUndo:true,modes:{wysiwyg:1},exec:function(){function f(b){var d=B.ie&&B.version<9?" ":
O,g=a.hotNode&&a.hotNode.getText()==d&&a.element.equals(a.hotNode)&&a.lastCmdDirection===!!c;e(a,function(e){g&&a.hotNode&&a.hotNode.remove();e[c?"insertAfter":"insertBefore"](b);e.setAttributes({"data-cke-magicline-hot":1,"data-cke-magicline-dir":!!c});a.lastCmdDirection=!!c});!B.ie&&a.enterMode!=CKEDITOR.ENTER_BR&&a.hotNode.scrollIntoView();a.line.detach()}return function(e){var e=e.getSelection().getStartElement(),h,e=e.getAscendant(M,1);if(!o(a,e)&&e&&!e.equals(a.editable)&&!e.contains(a.editable)){if((h=
g(e))&&h.getAttribute("contenteditable")=="false")e=h;a.element=e;h=b(a,e,!c);var i;if(j(h)&&h.is(a.triggers)&&h.is(R)&&(!b(a,h,!c)||(i=b(a,h,!c))&&j(i)&&i.is(a.triggers)))f(h);else{i=d(a,e);if(j(i))if(b(a,i,!c))(e=b(a,i,!c))&&(j(e)&&e.is(a.triggers))&&f(i);else f(i)}}}}()}}function k(a,b){if(!b||!(b.type==CKEDITOR.NODE_ELEMENT&&b.$))return false;var c=a.line;return c.wrap.equals(b)||c.wrap.contains(b)}function j(a){return a&&a.type==CKEDITOR.NODE_ELEMENT&&a.$}function m(a){if(!j(a))return false;
var b;if(!(b=q(a)))if(j(a)){b={left:1,right:1,center:1};b=!(!b[a.getComputedStyle("float")]&&!b[a.getAttribute("align")])}else b=false;return b}function q(a){return!!{absolute:1,fixed:1}[a.getComputedStyle("position")]}function l(a,b){return j(b)?b.is(a.triggers):null}function o(a,b){if(!b)return false;for(var c=b.getParents(1),e=c.length;e--;)for(var d=a.tabuList.length;d--;)if(c[e].hasAttribute(a.tabuList[d]))return true;return false}function p(a,b,c){b=b[c?"getLast":"getFirst"](function(b){return a.isRelevant(b)&&
!b.is(J)});if(!b)return false;w(a,b);return c?b.size.top>a.mouse.y:b.size.bottom<a.mouse.y}function r(a){var b=a.editable,c=a.mouse,e=a.view,d=a.triggerOffset;v(a);var g=c.y>(a.inInlineMode?e.editable.top+e.editable.height/2:Math.min(e.editable.height,e.pane.height)/2),b=b[g?"getLast":"getFirst"](function(a){return!(Y(a)||Z(a))});if(!b)return null;k(a,b)&&(b=a.line.wrap[g?"getPrevious":"getNext"](function(a){return!(Y(a)||Z(a))}));if(!j(b)||m(b)||!l(a,b))return null;w(a,b);if(!g&&b.size.top>=0&&c.y>
0&&c.y<b.size.top+d){a=a.inInlineMode||e.scroll.y===0?K:Q;return new f([null,b,I,E,a])}if(g&&b.size.bottom<=e.pane.height&&c.y>b.size.bottom-d&&c.y<e.pane.height){a=a.inInlineMode||b.size.bottom>e.pane.height-d&&b.size.bottom<e.pane.height?N:Q;return new f([b,null,A,E,a])}return null}function s(a){var c=a.mouse,e=a.view,g=a.triggerOffset,h=d(a);if(!h)return null;w(a,h);var g=Math.min(g,0|h.size.outerHeight/2),i=[],k,o;if(c.y>h.size.top-1&&c.y<h.size.top+g)o=false;else if(c.y>h.size.bottom-g&&c.y<
h.size.bottom+1)o=true;else return null;if(m(h)||p(a,h,o)||h.getParent().is(L))return null;var n=b(a,h,!o);if(n){if(n&&n.type==CKEDITOR.NODE_TEXT)return null;if(j(n)){if(m(n)||!l(a,n)||n.getParent().is(L))return null;i=[n,h][o?"reverse":"concat"]().concat([D,E])}}else{if(h.equals(a.editable[o?"getLast":"getFirst"](a.isRelevant))){v(a);o&&c.y>h.size.bottom-g&&c.y<e.pane.height&&h.size.bottom>e.pane.height-g&&h.size.bottom<e.pane.height?k=N:c.y>0&&c.y<h.size.top+g&&(k=K)}else k=Q;i=[null,h][o?"reverse":
"concat"]().concat([o?A:I,E,k,h.equals(a.editable[o?"getLast":"getFirst"](a.isRelevant))?o?N:K:Q])}return 0 in i?new f(i):null}function u(a,b,c,e){for(var d=function(){var c=B.ie?b.$.currentStyle:a.win.$.getComputedStyle(b.$,"");return B.ie?function(a){return c[CKEDITOR.tools.cssStyleToDomStyle(a)]}:function(a){return c.getPropertyValue(a)}}(),g=b.getDocumentPosition(),f={},h={},i={},j={},k=X.length;k--;){f[X[k]]=parseInt(d("border-"+X[k]+"-width"),10)||0;i[X[k]]=parseInt(d("padding-"+X[k]),10)||
0;h[X[k]]=parseInt(d("margin-"+X[k]),10)||0}(!c||e)&&t(a,e);j.top=g.y-(c?0:a.view.scroll.y);j.left=g.x-(c?0:a.view.scroll.x);j.outerWidth=b.$.offsetWidth;j.outerHeight=b.$.offsetHeight;j.height=j.outerHeight-(i.top+i.bottom+f.top+f.bottom);j.width=j.outerWidth-(i.left+i.right+f.left+f.right);j.bottom=j.top+j.outerHeight;j.right=j.left+j.outerWidth;if(a.inInlineMode)j.scroll={top:b.$.scrollTop,left:b.$.scrollLeft};return n({border:f,padding:i,margin:h,ignoreScroll:c},j,true)}function w(a,b,c){if(!j(b))return b.size=
null;if(b.size){if(b.size.ignoreScroll==c&&b.size.date>new Date-T)return null}else b.size={};return n(b.size,u(a,b,c),{date:+new Date},true)}function v(a,b){a.view.editable=u(a,a.editable,b,true)}function t(a,b){if(!a.view)a.view={};var c=a.view;if(b||!(c&&c.date>new Date-T)){var e=a.win,c=e.getScrollPosition(),e=e.getViewPaneSize();n(a.view,{scroll:{x:c.x,y:c.y,width:a.doc.$.documentElement.scrollWidth-e.width,height:a.doc.$.documentElement.scrollHeight-e.height},pane:{width:e.width,height:e.height,
bottom:e.height+c.y},date:+new Date},true)}}function y(a,b,c,e){for(var d=e,g=e,h=0,i=false,j=false,k=a.view.pane.height,m=a.mouse;m.y+h<k&&m.y-h>0;){i||(i=b(d,e));j||(j=b(g,e));!i&&m.y-h>0&&(d=c(a,{x:m.x,y:m.y-h}));!j&&m.y+h<k&&(g=c(a,{x:m.x,y:m.y+h}));if(i&&j)break;h=h+2}return new f([d,g,null,null])}CKEDITOR.plugins.add("magicline",{init:function(a){var c=a.config,g=c.magicline_triggerOffset||30,l={editor:a,enterMode:c.enterMode,triggerOffset:g,holdDistance:0|g*(c.magicline_holdDistance||0.5),
boxColor:c.magicline_color||"#ff0000",rtl:c.contentsLangDirection=="rtl",tabuList:["data-cke-hidden-sel"].concat(c.magicline_tabuList||[]),triggers:c.magicline_everywhere?M:{table:1,hr:1,div:1,ul:1,ol:1,dl:1,form:1,blockquote:1}},p,w,x;l.isRelevant=function(a){return j(a)&&!k(l,a)&&!m(a)};a.on("contentDom",function(){var g=a.editable(),j=a.document,m=a.window;n(l,{editable:g,inInlineMode:g.isInline(),doc:j,win:m,hotNode:null},true);l.boundary=l.inInlineMode?l.editable:l.doc.getDocumentElement();if(!g.is(H.$inline)){l.inInlineMode&&
!q(g)&&g.setStyles({position:"relative",top:null,left:null});i.call(this,l);t(l);g.attachListener(a,"beforeUndoImage",function(){l.line.detach()});g.attachListener(a,"beforeGetData",function(){if(l.line.wrap.getParent()){l.line.detach();a.once("getData",function(){l.line.attach()},null,null,1E3)}},null,null,0);g.attachListener(l.inInlineMode?j:j.getWindow().getFrame(),"mouseout",function(b){if(a.mode=="wysiwyg")if(l.inInlineMode){var c=b.data.$.clientX,b=b.data.$.clientY;t(l);v(l,true);var e=l.view.editable,
d=l.view.scroll;if(!(c>e.left-d.x&&c<e.right-d.x)||!(b>e.top-d.y&&b<e.bottom-d.y)){clearTimeout(x);x=null;l.line.detach()}}else{clearTimeout(x);x=null;l.line.detach()}});g.attachListener(g,"keyup",function(){l.hiddenMode=0});g.attachListener(g,"keydown",function(b){if(a.mode=="wysiwyg")switch(b.data.getKeystroke()){case 2228240:case 16:l.hiddenMode=1;l.line.detach()}});g.attachListener(l.inInlineMode?g:j,"mousemove",function(b){w=true;if(!(a.mode!="wysiwyg"||a.readOnly||x)){var c={x:b.data.$.clientX,
y:b.data.$.clientY};x=setTimeout(function(){l.mouse=c;x=l.trigger=null;t(l);if(w&&!l.hiddenMode&&a.focusManager.hasFocus&&!l.line.mouseNear()&&(l.element=S(l,true))){if((l.trigger=r(l)||s(l)||ba(l))&&!o(l,l.trigger.upper||l.trigger.lower))l.line.attach().place();else{l.trigger=null;l.line.detach()}w=false}},30)}});g.attachListener(m,"scroll",function(){if(a.mode=="wysiwyg"){l.line.detach();if(B.webkit){l.hiddenMode=1;clearTimeout(p);p=setTimeout(function(){if(!l.mouseDown)l.hiddenMode=0},50)}}});
g.attachListener(C?j:m,"mousedown",function(){if(a.mode=="wysiwyg"){l.line.detach();l.hiddenMode=1;l.mouseDown=1}});g.attachListener(C?j:m,"mouseup",function(){l.hiddenMode=0;l.mouseDown=0});a.addCommand("accessPreviousSpace",h(l));a.addCommand("accessNextSpace",h(l,true));a.setKeystroke([[c.magicline_keystrokePrevious,"accessPreviousSpace"],[c.magicline_keystrokeNext,"accessNextSpace"]]);a.on("loadSnapshot",function(){var b,c,e,d;for(d in{p:1,br:1,div:1}){b=a.document.getElementsByTag(d);for(e=b.count();e--;)if((c=
b.getItem(e)).data("cke-magicline-hot")){l.hotNode=c;l.lastCmdDirection=c.data("cke-magicline-dir")==="true"?true:false;return}}});this.backdoor={accessFocusSpace:e,boxTrigger:f,isLine:k,getAscendantTrigger:d,getNonEmptyNeighbour:b,getSize:u,that:l,triggerEdge:s,triggerEditable:r,triggerExpand:ba}}},this)}});var n=CKEDITOR.tools.extend,x=CKEDITOR.dom.element,z=x.createFromHtml,B=CKEDITOR.env,C=CKEDITOR.env.ie&&CKEDITOR.env.version<9,H=CKEDITOR.dtd,F={},I=128,A=64,D=32,E=16,G=8,K=4,N=2,Q=1,O=" ",L=
H.$listItem,J=H.$tableContent,R=n({},H.$nonEditable,H.$empty),M=H.$block,T=100,P="width:0px;height:0px;padding:0px;margin:0px;display:block;z-index:9999;color:#fff;position:absolute;font-size: 0px;line-height:0px;",V=P+"border-color:transparent;display:block;border-style:solid;",W="<span>"+O+"</span>";F[CKEDITOR.ENTER_BR]="br";F[CKEDITOR.ENTER_P]="p";F[CKEDITOR.ENTER_DIV]="div";f.prototype={set:function(a,b,c){this.properties=a+b+(c||Q);return this},is:function(a){return(this.properties&a)==a}};var S=
function(){function a(b,c){var e=b.$.elementFromPoint(c.x,c.y);return e&&e.nodeType?new CKEDITOR.dom.element(e):null}return function(b,c,e){if(!b.mouse)return null;var d=b.doc,g=b.line.wrap,e=e||b.mouse,f=a(d,e);if(c&&k(b,f)){g.hide();f=a(d,e);g.show()}return!f||!(f.type==CKEDITOR.NODE_ELEMENT&&f.$)||B.ie&&B.version<9&&!b.boundary.equals(f)&&!b.boundary.contains(f)?null:f}}(),Y=CKEDITOR.dom.walker.whitespaces(),Z=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_COMMENT),ba=function(){function b(d){var g=
d.element,f,h,i;if(!j(g)||g.contains(d.editable)||g.isReadOnly())return null;i=y(d,function(a,b){return!b.equals(a)},function(a,b){return S(a,true,b)},g);f=i.upper;h=i.lower;if(a(d,f,h))return i.set(D,G);if(f&&g.contains(f))for(;!f.getParent().equals(g);)f=f.getParent();else f=g.getFirst(function(a){return e(d,a)});if(h&&g.contains(h))for(;!h.getParent().equals(g);)h=h.getParent();else h=g.getLast(function(a){return e(d,a)});if(!f||!h)return null;w(d,f);w(d,h);if(!(d.mouse.y>f.size.top&&d.mouse.y<
h.size.bottom))return null;for(var g=Number.MAX_VALUE,k,l,m,o;h&&!h.equals(f);){if(!(l=f.getNext(d.isRelevant)))break;k=Math.abs(c(d,f,l)-d.mouse.y);if(k<g){g=k;m=f;o=l}f=l;w(d,f)}if(!m||!o||!(d.mouse.y>m.size.top&&d.mouse.y<o.size.bottom))return null;i.upper=m;i.lower=o;return i.set(D,G)}function e(a,b){return!(b&&b.type==CKEDITOR.NODE_TEXT||Z(b)||m(b)||k(a,b)||b.type==CKEDITOR.NODE_ELEMENT&&b.$&&b.is("br"))}return function(c){var e=b(c),d;if(d=e){d=e.upper;var g=e.lower;d=!d||!g||m(g)||m(d)||g.equals(d)||
d.equals(g)||g.contains(d)||d.contains(g)?false:l(c,d)&&l(c,g)&&a(c,d,g)?true:false}return d?e:null}}(),X=["top","left","right","bottom"]})();CKEDITOR.config.magicline_keystrokePrevious=CKEDITOR.CTRL+CKEDITOR.SHIFT+51;CKEDITOR.config.magicline_keystrokeNext=CKEDITOR.CTRL+CKEDITOR.SHIFT+52;(function(){var a={canUndo:false,async:true,exec:function(f){f.getClipboardData({title:f.lang.pastetext.title},function(d){d&&f.fire("paste",{type:"text",dataValue:d.dataValue});f.fire("afterCommandExec",{name:"pastetext",
command:a,returnValue:!!d})})}};CKEDITOR.plugins.add("pastetext",{requires:"clipboard",init:function(f){f.addCommand("pastetext",a);f.ui.addButton&&f.ui.addButton("PasteText",{label:f.lang.pastetext.button,command:"pastetext",toolbar:"clipboard,40"});if(f.config.forcePasteAsPlainText)f.on("beforePaste",function(a){if(a.data.type!="html")a.data.type="text"});f.on("pasteState",function(a){f.getCommand("pastetext").setState(a.data)})}})})();var da=CKEDITOR.plugins.getPath("pbckcode")+"dialogs/PBSyntaxHighlighter.js";
CKEDITOR.plugins.add("pbckcode",{icons:"pbckcode",hidpi:!0,lang:["fr","en"],init:function(a){var f=this;if(a.config.pbckcode===void 0)a.config.pbckcode={};a.settings=CKEDITOR.tools.extend({cls:"",modes:[["HTML","html"],["CSS","css"],["PHP","php"],["JS","javascript"]],theme:"textmate",tab_size:4,js:"http://cdn.jsdelivr.net//ace/1.1.4/noconflict///"},a.config.pbckcode,true);a.settings.js=a.settings.js.concat("/").replace(RegExp("([^:]/)/+","g"),"$1");a.on("instanceReady",function(){CKEDITOR.document.appendStyleSheet(f.path+
"dialogs/style.css")});a.ui.addButton("pbckcode",{label:a.lang.pbckcode.addCode,command:"pbckcode",toolbar:"pbckcode"});a.addCommand("pbckcode",new CKEDITOR.dialogCommand("pbckcodeDialog",{allowedContent:"pre[*]{*}(*)"}));a.getCommand("pbckcode").disable();CKEDITOR.dialog.add("pbckcodeDialog",f.path+"dialogs/pbckcode.js");if(a.contextMenu){a.addMenuGroup("pbckcodeGroup");a.addMenuItem("pbckcodeItem",{label:a.lang.pbckcode.editCode,icon:f.path+"icons/pbckcode.png",command:"pbckcode",group:"pbckcodeGroup"});
a.contextMenu.addListener(function(a){if(a.getAscendant("pre",true))return{pbckcodeItem:CKEDITOR.TRISTATE_OFF}})}CKEDITOR.scriptLoader.load([a.settings.js+"ace.js",da],function(){a.getCommand("pbckcode").enable();CKEDITOR.scriptLoader.load([a.settings.js+"ext-whitespace.js"])})}});CKEDITOR.plugins.add("removeformat",{init:function(a){a.addCommand("removeFormat",CKEDITOR.plugins.removeformat.commands.removeformat);a.ui.addButton&&a.ui.addButton("RemoveFormat",{label:a.lang.removeformat.toolbar,command:"removeFormat",
toolbar:"cleanup,10"})}});CKEDITOR.plugins.removeformat={commands:{removeformat:{exec:function(a){for(var f=a._.removeFormatRegex||(a._.removeFormatRegex=RegExp("^(?:"+a.config.removeFormatTags.replace(/,/g,"|")+")$","i")),d=a._.removeAttributes||(a._.removeAttributes=a.config.removeFormatAttributes.split(",")),c=CKEDITOR.plugins.removeformat.filter,b=a.getSelection().getRanges(),g=b.createIterator(),i=function(a){return a.type==CKEDITOR.NODE_ELEMENT},e;e=g.getNextRange();){e.collapsed||e.enlarge(CKEDITOR.ENLARGE_ELEMENT);
var h=e.createBookmark(),k=h.startNode,j=h.endNode,m=function(b){for(var e=a.elementPath(b),d=e.elements,g=1,h;h=d[g];g++){if(h.equals(e.block)||h.equals(e.blockLimit))break;f.test(h.getName())&&c(a,h)&&b.breakParent(h)}};m(k);if(j){m(j);for(k=k.getNextSourceNode(true,CKEDITOR.NODE_ELEMENT);k;){if(k.equals(j))break;if(k.isReadOnly()){if(k.getPosition(j)&CKEDITOR.POSITION_CONTAINS)break;k=k.getNext(i)}else{m=k.getNextSourceNode(false,CKEDITOR.NODE_ELEMENT);if(!(k.getName()=="img"&&k.data("cke-realelement"))&&
c(a,k))if(f.test(k.getName()))k.remove(1);else{k.removeAttributes(d);a.fire("removeFormatCleanup",k)}k=m}}}e.moveToBookmark(h)}a.forceNextSelectionCheck();a.getSelection().selectRanges(b)}}},filter:function(a,f){for(var d=a._.removeFormatFilters||[],c=0;c<d.length;c++)if(d[c](f)===false)return false;return true}};CKEDITOR.editor.prototype.addRemoveFormatFilter=function(a){if(!this._.removeFormatFilters)this._.removeFormatFilters=[];this._.removeFormatFilters.push(a)};CKEDITOR.config.removeFormatTags=
"b,big,cite,code,del,dfn,em,font,i,ins,kbd,q,s,samp,small,span,strike,strong,sub,sup,tt,u,var";CKEDITOR.config.removeFormatAttributes="class,style,lang,width,height,align,hspace,valign";(function(){CKEDITOR.plugins.add("sourcearea",{init:function(f){function d(){var a=b&&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(f.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE){var c=
CKEDITOR.plugins.sourcearea;f.addMode("source",function(b){var c=f.ui.space("contents").getDocument().createElement("textarea");c.setStyles(CKEDITOR.tools.extend({width:CKEDITOR.env.ie7Compat?"99%":"100%",height:"100%",resize:"none",outline:"none","text-align":"left"},CKEDITOR.tools.cssVendorPrefix("tab-size",f.config.sourceAreaTabSize||4)));c.setAttribute("dir","ltr");c.addClass("cke_source cke_reset cke_enable_context_menu");f.ui.space("contents").append(c);c=f.editable(new a(f,c));c.setData(f.getData(1));
if(CKEDITOR.env.ie){c.attachListener(f,"resize",d,c);c.attachListener(CKEDITOR.document.getWindow(),"resize",d,c);CKEDITOR.tools.setTimeout(d,0,c)}f.fire("ariaWidget",this);b()});f.addCommand("source",c.commands.source);f.ui.addButton&&f.ui.addButton("Source",{label:f.lang.sourcearea.toolbar,command:"source",toolbar:"mode,10"});f.on("mode",function(){f.getCommand("source").setState(f.mode=="source"?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF)});var b=CKEDITOR.env.ie&&CKEDITOR.env.version==9}}});var a=
CKEDITOR.tools.createClass({base:CKEDITOR.editable,proto:{setData:function(a){this.setValue(a);this.status="ready";this.editor.fire("dataReady")},getData:function(){return this.getValue()},insertHtml:function(){},insertElement:function(){},insertText:function(){},setReadOnly:function(a){this[(a?"set":"remove")+"Attribute"]("readOnly","readonly")},detach:function(){a.baseProto.detach.call(this);this.clearCustomData();this.remove()}}})})();CKEDITOR.plugins.sourcearea={commands:{source:{modes:{wysiwyg:1,
source:1},editorFocus:!1,readOnly:1,exec:function(a){a.mode=="wysiwyg"&&a.fire("saveSnapshot");a.getCommand("source").setState(CKEDITOR.TRISTATE_DISABLED);a.setMode(a.mode=="source"?"wysiwyg":"source")},canUndo:!1}}};(function(){function a(a){function c(){for(var g=d(),h=CKEDITOR.tools.clone(a.config.toolbarGroups)||f(a),j=0;j<h.length;j++){var k=h[j];if(k!="/"){typeof k=="string"&&(k=h[j]={name:k});var p,r=k.groups;if(r)for(var s=0;s<r.length;s++){p=r[s];(p=g[p])&&e(k,p)}(p=g[k.name])&&e(k,p)}}return h}
function d(){var c={},e,g,f;for(e in a.ui.items){g=a.ui.items[e];f=g.toolbar||"others";f=f.split(",");g=f[0];f=parseInt(f[1]||-1,10);c[g]||(c[g]=[]);c[g].push({name:e,order:f})}for(g in c)c[g]=c[g].sort(function(a,b){return a.order==b.order?0:b.order<0?-1:a.order<0?1:a.order<b.order?-1:1});return c}function e(c,e){if(e.length){c.items?c.items.push(a.ui.create("-")):c.items=[];for(var d;d=e.shift();){d=typeof d=="string"?d:d.name;if(!k||CKEDITOR.tools.indexOf(k,d)==-1)(d=a.ui.create(d))&&a.addFeature(d)&&
c.items.push(d)}}}function h(a){var b=[],c,d,g;for(c=0;c<a.length;++c){d=a[c];g={};if(d=="/")b.push(d);else if(CKEDITOR.tools.isArray(d)){e(g,CKEDITOR.tools.clone(d));b.push(g)}else if(d.items){e(g,CKEDITOR.tools.clone(d.items));g.name=d.name;b.push(g)}}return b}var k=a.config.removeButtons,k=k&&k.split(","),j=a.config.toolbar;typeof j=="string"&&(j=a.config["toolbar_"+j]);return a.toolbar=j?h(j):c()}function f(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 d=function(){this.toolbars=[];this.focusCommandExecuted=false};d.prototype.focus=function(){for(var a=0,c;c=this.toolbars[a++];)for(var d=
0,e;e=c.items[d++];)if(e.focus){e.focus();return}};var c={modes:{wysiwyg:1,source:1},readOnly:1,exec:function(a){if(a.toolbox){a.toolbox.focusCommandExecuted=true;CKEDITOR.env.ie||CKEDITOR.env.air?setTimeout(function(){a.toolbox.focus()},100):a.toolbox.focus()}}};CKEDITOR.plugins.add("toolbar",{requires:"button",init:function(b){var g,f=function(a,c){var d,j=b.lang.dir=="rtl",m=b.config.toolbarGroupCycling,q=j?37:39,j=j?39:37,m=m===void 0||m;switch(c){case 9:case CKEDITOR.SHIFT+9:for(;!d||!d.items.length;){d=
c==9?(d?d.next:a.toolbar.next)||b.toolbox.toolbars[0]:(d?d.previous:a.toolbar.previous)||b.toolbox.toolbars[b.toolbox.toolbars.length-1];if(d.items.length)for(a=d.items[g?d.items.length-1:0];a&&!a.focus;)(a=g?a.previous:a.next)||(d=0)}a&&a.focus();return false;case q:d=a;do{d=d.next;!d&&m&&(d=a.toolbar.items[0])}while(d&&!d.focus);d?d.focus():f(a,9);return false;case 40:if(a.button&&a.button.hasArrow){b.once("panelShow",function(a){a.data._.panel._.currentBlock.onKeyDown(40)});a.execute()}else f(a,
c==40?q:j);return false;case j:case 38:d=a;do{d=d.previous;!d&&m&&(d=a.toolbar.items[a.toolbar.items.length-1])}while(d&&!d.focus);if(d)d.focus();else{g=1;f(a,CKEDITOR.SHIFT+9);g=0}return false;case 27:b.focus();return false;case 13:case 32:a.execute();return false}return true};b.on("uiSpace",function(c){if(c.data.space==b.config.toolbarLocation){c.removeListener();b.toolbox=new d;var g=CKEDITOR.tools.getNextId(),k=['<span id="',g,'" class="cke_voice_label">',b.lang.toolbar.toolbars,"</span>",'<span id="'+
b.ui.spaceId("toolbox")+'" class="cke_toolbox" role="group" aria-labelledby="',g,'" onmousedown="return false;">'],g=b.config.toolbarStartupExpanded!==false,j,m;b.config.toolbarCanCollapse&&b.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE&&k.push('<span class="cke_toolbox_main"'+(g?">":' style="display:none">'));for(var q=b.toolbox.toolbars,l=a(b),o=0;o<l.length;o++){var p,r=0,s,u=l[o],w;if(u){if(j){k.push("</span>");m=j=0}if(u==="/")k.push('<span class="cke_toolbar_break"></span>');else{w=u.items||u;
for(var v=0;v<w.length;v++){var t=w[v],y;if(t)if(t.type==CKEDITOR.UI_SEPARATOR)m=j&&t;else{y=t.canGroup!==false;if(!r){p=CKEDITOR.tools.getNextId();r={id:p,items:[]};s=u.name&&(b.lang.toolbar.toolbarGroups[u.name]||u.name);k.push('<span id="',p,'" class="cke_toolbar"',s?' aria-labelledby="'+p+'_label"':"",' role="toolbar">');s&&k.push('<span id="',p,'_label" class="cke_voice_label">',s,"</span>");k.push('<span class="cke_toolbar_start"></span>');var n=q.push(r)-1;if(n>0){r.previous=q[n-1];r.previous.next=
r}}if(y){if(!j){k.push('<span class="cke_toolgroup" role="presentation">');j=1}}else if(j){k.push("</span>");j=0}p=function(a){a=a.render(b,k);n=r.items.push(a)-1;if(n>0){a.previous=r.items[n-1];a.previous.next=a}a.toolbar=r;a.onkey=f;a.onfocus=function(){b.toolbox.focusCommandExecuted||b.focus()}};if(m){p(m);m=0}p(t)}}if(j){k.push("</span>");m=j=0}r&&k.push('<span class="cke_toolbar_end"></span></span>')}}}b.config.toolbarCanCollapse&&k.push("</span>");if(b.config.toolbarCanCollapse&&b.elementMode!=
CKEDITOR.ELEMENT_MODE_INLINE){var x=CKEDITOR.tools.addFunction(function(){b.execCommand("toolbarCollapse")});b.on("destroy",function(){CKEDITOR.tools.removeFunction(x)});b.addCommand("toolbarCollapse",{readOnly:1,exec:function(a){var b=a.ui.space("toolbar_collapser"),c=b.getPrevious(),e=a.ui.space("contents"),d=c.getParent(),g=parseInt(e.$.style.height,10),f=d.$.offsetHeight,h=b.hasClass("cke_toolbox_collapser_min");if(h){c.show();b.removeClass("cke_toolbox_collapser_min");b.setAttribute("title",
a.lang.toolbar.toolbarCollapse)}else{c.hide();b.addClass("cke_toolbox_collapser_min");b.setAttribute("title",a.lang.toolbar.toolbarExpand)}b.getFirst().setText(h?"▲":"◀");e.setStyle("height",g-(d.$.offsetHeight-f)+"px");a.fire("resize")},modes:{wysiwyg:1,source:1}});b.setKeystroke(CKEDITOR.ALT+(CKEDITOR.env.ie||CKEDITOR.env.webkit?189:109),"toolbarCollapse");k.push('<a title="'+(g?b.lang.toolbar.toolbarCollapse:b.lang.toolbar.toolbarExpand)+'" id="'+b.ui.spaceId("toolbar_collapser")+'" tabIndex="-1" class="cke_toolbox_collapser');
g||k.push(" cke_toolbox_collapser_min");k.push('" onclick="CKEDITOR.tools.callFunction('+x+')">','<span class="cke_arrow">&#9650;</span>',"</a>")}k.push("</span>");c.data.html=c.data.html+k.join("")}});b.on("destroy",function(){if(this.toolbox){var a,b=0,c,d,g;for(a=this.toolbox.toolbars;b<a.length;b++){d=a[b].items;for(c=0;c<d.length;c++){g=d[c];g.clickFn&&CKEDITOR.tools.removeFunction(g.clickFn);g.keyDownFn&&CKEDITOR.tools.removeFunction(g.keyDownFn)}}}});b.on("uiReady",function(){var a=b.ui.space("toolbox");
a&&b.focusManager.add(a,1)});b.addCommand("toolbarFocus",c);b.setKeystroke(CKEDITOR.ALT+121,"toolbarFocus");b.ui.add("-",CKEDITOR.UI_SEPARATOR,{});b.ui.addHandler(CKEDITOR.UI_SEPARATOR,{create:function(){return{render:function(a,b){b.push('<span class="cke_toolbar_separator" role="separator"></span>');return{}}}}})}});CKEDITOR.ui.prototype.addToolbarGroup=function(a,c,d){var e=f(this.editor),h=c===0,k={name:a};if(d){if(d=CKEDITOR.tools.search(e,function(a){return a.name==d})){!d.groups&&(d.groups=
[]);if(c){c=CKEDITOR.tools.indexOf(d.groups,c);if(c>=0){d.groups.splice(c+1,0,a);return}}h?d.groups.splice(0,0,a):d.groups.push(a);return}c=null}c&&(c=CKEDITOR.tools.indexOf(e,function(a){return a.name==c}));h?e.splice(0,0,a):typeof c=="number"?e.splice(c+1,0,k):e.push(a)}})();CKEDITOR.UI_SEPARATOR="separator";CKEDITOR.config.toolbarLocation="top";"use strict";(function(){var a=[CKEDITOR.CTRL+90,CKEDITOR.CTRL+89,CKEDITOR.CTRL+CKEDITOR.SHIFT+90],f={8:1,46:1};CKEDITOR.plugins.add("undo",{init:function(b){function c(a){i.enabled&&
a.data.command.canUndo!==false&&i.save()}function f(){i.enabled=b.readOnly?false:b.mode=="wysiwyg";i.onChange()}var i=b.undoManager=new d(b),m=i.editingHandler=new g(i),q=b.addCommand("undo",{exec:function(){if(i.undo()){b.selectionChange();this.fire("afterUndo")}},startDisabled:true,canUndo:false}),l=b.addCommand("redo",{exec:function(){if(i.redo()){b.selectionChange();this.fire("afterRedo")}},startDisabled:true,canUndo:false});b.setKeystroke([[a[0],"undo"],[a[1],"redo"],[a[2],"redo"]]);i.onChange=
function(){q.setState(i.undoable()?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED);l.setState(i.redoable()?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED)};b.on("beforeCommandExec",c);b.on("afterCommandExec",c);b.on("saveSnapshot",function(a){i.save(a.data&&a.data.contentOnly)});b.on("contentDom",m.attachListeners,m);b.on("instanceReady",function(){b.fire("saveSnapshot")});b.on("beforeModeUnload",function(){b.mode=="wysiwyg"&&i.save(true)});b.on("mode",f);b.on("readOnly",f);if(b.ui.addButton){b.ui.addButton("Undo",
{label:b.lang.undo.undo,command:"undo",toolbar:"undo,10"});b.ui.addButton("Redo",{label:b.lang.undo.redo,command:"redo",toolbar:"undo,20"})}b.resetUndo=function(){i.reset();b.fire("saveSnapshot")};b.on("updateSnapshot",function(){i.currentImage&&i.update()});b.on("lockSnapshot",function(a){a=a.data;i.lock(a&&a.dontUpdate,a&&a.forceUpdate)});b.on("unlockSnapshot",i.unlock,i)}});CKEDITOR.plugins.undo={};var d=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()};d.prototype={type:function(a,b){var c=d.getKeyGroup(a),g=this.strokesRecorded[c]+1,b=b||g>=this.strokesLimit;if(!this.typing){this.hasUndo=this.typing=true;this.hasRedo=false;this.onChange()}if(b){g=0;this.editor.fire("saveSnapshot")}else this.editor.fire("change");this.strokesRecorded[c]=g;this.previousKeyGroup=c},keyGroupChanged:function(a){return d.getKeyGroup(a)!=this.previousKeyGroup},
reset:function(){this.snapshots=[];this.index=-1;this.currentImage=null;this.hasRedo=this.hasUndo=false;this.locked=null;this.resetType()},resetType:function(){this.strokesRecorded=[0,0];this.typing=false;this.previousKeyGroup=-1},refreshState:function(){this.hasUndo=!!this.getNextImage(true);this.hasRedo=!!this.getNextImage(false);this.resetType();this.onChange()},save:function(a,b,d){var g=this.editor;if(this.locked||g.status!="ready"||g.mode!="wysiwyg")return false;var f=g.editable();if(!f||f.status!=
"ready")return false;f=this.snapshots;b||(b=new c(g));if(b.contents===false)return false;if(this.currentImage)if(b.equalsContent(this.currentImage)){if(a||b.equalsSelection(this.currentImage))return false}else d!==false&&g.fire("change");f.splice(this.index+1,f.length-this.index-1);f.length==this.limit&&f.shift();this.index=f.push(b)-1;this.currentImage=b;d!==false&&this.refreshState();return true},restoreImage:function(a){var b=this.editor,c;if(a.bookmarks){b.focus();c=b.getSelection()}this.locked=
{level:999};this.editor.loadSnapshot(a.contents);if(a.bookmarks)c.selectBookmarks(a.bookmarks);else if(CKEDITOR.env.ie){c=this.editor.document.getBody().$.createTextRange();c.collapse(true);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,d;if(c)if(a)for(d=this.index-1;d>=0;d--){a=b[d];if(!c.equalsContent(a)){a.index=d;return a}}else for(d=
this.index+1;d<b.length;d++){a=b[d];if(!c.equalsContent(a)){a.index=d;return a}}return null},redoable:function(){return this.enabled&&this.hasRedo},undoable:function(){return this.enabled&&this.hasUndo},undo:function(){if(this.undoable()){this.save(true);var a=this.getNextImage(true);if(a)return this.restoreImage(a),true}return false},redo:function(){if(this.redoable()){this.save(true);if(this.redoable()){var a=this.getNextImage(false);if(a)return this.restoreImage(a),true}}return false},update:function(a){if(!this.locked){a||
(a=new c(this.editor));for(var b=this.index,d=this.snapshots;b>0&&this.currentImage.equalsContent(d[b-1]);)b=b-1;d.splice(b,this.index-b+1,a);this.index=b;this.currentImage=a}},updateSelection:function(a){if(!this.snapshots.length)return false;var b=this.snapshots,c=b[b.length-1];if(c.equalsContent(a)&&!c.equalsSelection(a)){this.currentImage=b[b.length-1]=a;return true}return false},lock:function(a,b){if(this.locked)this.locked.level++;else if(a)this.locked={level:1};else{var d=null;if(b)d=true;
else{var g=new c(this.editor,true);this.currentImage&&this.currentImage.equalsContent(g)&&(d=g)}this.locked={update:d,level:1}}},unlock:function(){if(this.locked&&!--this.locked.level){var a=this.locked.update;this.locked=null;if(a===true)this.update();else if(a){var b=new c(this.editor,true);a.equalsContent(b)||this.update()}}}};d.navigationKeyCodes={37:1,38:1,39:1,40:1,36:1,35:1,33:1,34:1};d.keyGroups={PRINTABLE:0,FUNCTIONAL:1};d.isNavigationKey=function(a){return!!d.navigationKeyCodes[a]};d.getKeyGroup=
function(a){var b=d.keyGroups;return f[a]?b.FUNCTIONAL:b.PRINTABLE};d.getOppositeKeyGroup=function(a){var b=d.keyGroups;return a==b.FUNCTIONAL?b.PRINTABLE:b.FUNCTIONAL};d.ieFunctionalKeysBug=function(a){return CKEDITOR.env.ie&&d.getKeyGroup(a)==d.keyGroups.FUNCTIONAL};var c=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;if(!b)this.bookmarks=(c=c&&a.getSelection())&&
c.createBookmarks2(true);a.fire("afterUndoImage")},b=/\b(?:href|src|name)="[^"]*?"/gi;c.prototype={equalsContent:function(a){var c=this.contents,a=a.contents;if(CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)){c=c.replace(b,"");a=a.replace(b,"")}return c!=a?false:true},equalsSelection:function(a){var b=this.bookmarks,a=a.bookmarks;if(b||a){if(!b||!a||b.length!=a.length)return false;for(var c=0;c<b.length;c++){var d=b[c],g=a[c];if(d.startOffset!=g.startOffset||d.endOffset!=g.endOffset||
!CKEDITOR.tools.arrayCompare(d.start,g.start)||!CKEDITOR.tools.arrayCompare(d.end,g.end))return false}}return true}};var g=CKEDITOR.plugins.undo.NativeEditingHandler=function(a){this.undoManager=a;this.ignoreInputEvent=false;this.keyEventsStack=new i;this.lastKeydownImage=null};g.prototype={onKeydown:function(b){var g=b.data.getKey();if(g!==229)if(CKEDITOR.tools.indexOf(a,b.data.getKeystroke())>-1)b.data.preventDefault();else{this.keyEventsStack.cleanUp(b);b=this.undoManager;this.keyEventsStack.getLast(g)||
this.keyEventsStack.push(g);this.lastKeydownImage=new c(b.editor);if(d.isNavigationKey(g)||this.undoManager.keyGroupChanged(g))if(b.strokesRecorded[0]||b.strokesRecorded[1]){b.save(false,this.lastKeydownImage,false);b.resetType()}}},onInput:function(){if(this.ignoreInputEvent)this.ignoreInputEvent=false;else{var a=this.keyEventsStack.getLast();a||(a=this.keyEventsStack.push(0));this.keyEventsStack.increment(a.keyCode);if(this.keyEventsStack.getTotalInputs()>=this.undoManager.strokesLimit){this.undoManager.type(a.keyCode,
true);this.keyEventsStack.resetInputs()}}},onKeyup:function(a){var b=this.undoManager,a=a.data.getKey(),g=this.keyEventsStack.getTotalInputs();this.keyEventsStack.remove(a);if(!d.ieFunctionalKeysBug(a)||!this.lastKeydownImage||!this.lastKeydownImage.equalsContent(new c(b.editor,true)))if(g>0)b.type(a);else if(d.isNavigationKey(a))this.onNavigationKey(true)},onNavigationKey:function(a){var b=this.undoManager;(a||!b.save(true,null,false))&&b.updateSelection(new c(b.editor));b.resetType()},ignoreInputEventListener:function(){this.ignoreInputEvent=
true},attachListeners:function(){var a=this.undoManager.editor,b=a.editable(),c=this;b.attachListener(b,"keydown",function(a){c.onKeydown(a);if(d.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 i=CKEDITOR.plugins.undo.KeyEventsStack=function(){this.stack=[]};i.prototype={push:function(a){return this.stack[this.stack.push({keyCode:a,inputs:0})-1]},getLastIndex:function(a){if(typeof a!="number")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 a!=-1?this.stack[a]:null},increment:function(a){this.getLast(a).inputs++},remove:function(a){a=this.getLastIndex(a);a!=-1&&this.stack.splice(a,1)},resetInputs:function(a){if(typeof a=="number")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=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)}}})();
(function(){function a(a){var c=this.editor,d=a.document,e=d.body,h=d.getElementById("cke_actscrpt");h&&h.parentNode.removeChild(h);(h=d.getElementById("cke_shimscrpt"))&&h.parentNode.removeChild(h);(h=d.getElementById("cke_basetagscrpt"))&&h.parentNode.removeChild(h);e.contentEditable=true;if(CKEDITOR.env.ie){e.hideFocus=true;e.disabled=true;e.removeAttribute("disabled")}delete this._.isLoadingData;this.$=e;d=new CKEDITOR.dom.document(d);this.setup();this.fixInitialSelection();if(CKEDITOR.env.ie){d.getDocumentElement().addClass(d.$.compatMode);
c.config.enterMode!=CKEDITOR.ENTER_P&&this.attachListener(d,"selectionchange",function(){var a=d.getBody(),b=c.getSelection(),e=b&&b.getRanges()[0];e&&(a.getHtml().match(/^<p>(?:&nbsp;|<br>)<\/p>$/i)&&e.startContainer.equals(a))&&setTimeout(function(){e=c.getSelection().getRanges()[0];if(!e.startContainer.equals("body")){a.getFirst().remove(1);e.moveToElementEditEnd(a);e.select()}},0)})}if(CKEDITOR.env.webkit||CKEDITOR.env.ie&&CKEDITOR.env.version>10)d.getDocumentElement().on("mousedown",function(a){a.data.getTarget().is("html")&&
setTimeout(function(){c.editable().focus()})});f(c);try{c.document.$.execCommand("2D-position",false,true)}catch(k){}(CKEDITOR.env.gecko||CKEDITOR.env.ie&&c.document.$.compatMode=="CSS1Compat")&&this.attachListener(this,"keydown",function(a){var b=a.data.getKeystroke();if(b==33||b==34)if(CKEDITOR.env.ie)setTimeout(function(){c.getSelection().scrollIntoView()},0);else if(c.window.$.innerHeight>this.$.offsetHeight){var d=c.createRange();d[b==33?"moveToElementEditStart":"moveToElementEditEnd"](this);
d.select();a.data.preventDefault()}});CKEDITOR.env.ie&&this.attachListener(d,"blur",function(){try{d.$.selection.empty()}catch(a){}});CKEDITOR.env.iOS&&this.attachListener(d,"touchend",function(){a.focus()});e=c.document.getElementsByTag("title").getItem(0);e.data("cke-title",e.getText());if(CKEDITOR.env.ie)c.document.$.title=this._.docTitle;CKEDITOR.tools.setTimeout(function(){if(this.status=="unloaded")this.status="ready";c.fire("contentDom");if(this._.isPendingFocus){c.focus();this._.isPendingFocus=
false}setTimeout(function(){c.fire("dataReady")},0);CKEDITOR.env.ie&&setTimeout(function(){if(c.document){var a=c.document.$.body;a.runtimeStyle.marginBottom="0px";a.runtimeStyle.marginBottom=""}},1E3)},0,this)}function f(a){function c(){var e;a.editable().attachListener(a,"selectionChange",function(){var c=a.getSelection().getSelectedElement();if(c){if(e){e.detachEvent("onresizestart",d);e=null}c.$.attachEvent("onresizestart",d);e=c.$}})}function d(a){a.returnValue=false}if(CKEDITOR.env.gecko)try{var e=
a.document.$;e.execCommand("enableObjectResizing",false,!a.config.disableObjectResizing);e.execCommand("enableInlineTableEditing",false,!a.config.disableNativeTableHandles)}catch(f){}else CKEDITOR.env.ie&&(CKEDITOR.env.version<11&&a.config.disableObjectResizing)&&c(a)}function d(){var a=[];if(CKEDITOR.document.$.documentMode>=8){a.push("html.CSS1Compat [contenteditable=false]{min-height:0 !important}");var c=[],d;for(d in CKEDITOR.dtd.$removeEmpty)c.push("html.CSS1Compat "+d+"[contenteditable=false]");
a.push(c.join(",")+"{display:inline-block}")}else if(CKEDITOR.env.gecko){a.push("html{height:100% !important}");a.push("img:-moz-broken{-moz-force-broken-image-icon:1;min-width:24px;min-height:24px}")}a.push("html{cursor:text;*cursor:auto}");a.push("img,input,textarea{cursor:default}");return a.join("\n")}CKEDITOR.plugins.add("wysiwygarea",{init:function(a){a.config.fullPage&&a.addFeature({allowedContent:"html head title; style [media,type]; body (*)[id]; meta link [*]",requiredContent:"body"});a.addMode("wysiwyg",
function(d){function f(e){e&&e.removeListener();a.editable(new c(a,h.$.contentWindow.document.body));a.setData(a.getData(1),d)}var e="document.open();"+(CKEDITOR.env.ie?"("+CKEDITOR.tools.fixDomain+")();":"")+"document.close();",e=CKEDITOR.env.air?"javascript:void(0)":CKEDITOR.env.ie?"javascript:void(function(){"+encodeURIComponent(e)+"}())":"",h=CKEDITOR.dom.element.createFromHtml('<iframe src="'+e+'" frameBorder="0"></iframe>');h.setStyles({width:"100%",height:"100%"});h.addClass("cke_wysiwyg_frame cke_reset");
var k=a.ui.space("contents");k.append(h);if(e=CKEDITOR.env.ie||CKEDITOR.env.gecko)h.on("load",f);var j=a.title,m=a.fire("ariaEditorHelpLabel",{}).label;if(j){CKEDITOR.env.ie&&m&&(j=j+(", "+m));h.setAttribute("title",j)}if(m){var j=CKEDITOR.tools.getNextId(),q=CKEDITOR.dom.element.createFromHtml('<span id="'+j+'" class="cke_voice_label">'+m+"</span>");k.append(q,1);h.setAttribute("aria-describedby",j)}a.on("beforeModeUnload",function(a){a.removeListener();q&&q.remove()});h.setAttributes({tabIndex:a.tabIndex,
allowTransparency:"true"});!e&&f();if(CKEDITOR.env.webkit){e=function(){k.setStyle("width","100%");h.hide();h.setSize("width",k.getSize("width"));k.removeStyle("width");h.show()};h.setCustomData("onResize",e);CKEDITOR.document.getWindow().on("resize",e)}a.fire("ariaWidget",h)})}});CKEDITOR.editor.prototype.addContentsCss=function(a){var c=this.config,d=c.contentsCss;if(!CKEDITOR.tools.isArray(d))c.contentsCss=d?[d]:[];c.contentsCss.push(a)};var c=CKEDITOR.tools.createClass({$:function(){this.base.apply(this,
arguments);this._.frameLoadedHandler=CKEDITOR.tools.addFunction(function(b){CKEDITOR.tools.setTimeout(a,0,this,b)},this);this._.docTitle=this.getWindow().getFrame().getAttribute("title")},base:CKEDITOR.editable,proto:{setData:function(a,c){var f=this.editor;if(c){this.setHtml(a);this.fixInitialSelection();f.fire("dataReady")}else{this._.isLoadingData=true;f._.dataStore={id:1};var e=f.config,h=e.fullPage,k=e.docType,j=CKEDITOR.tools.buildStyleHtml(d()).replace(/<style>/,'<style data-cke-temp="1">');
h||(j=j+CKEDITOR.tools.buildStyleHtml(f.config.contentsCss));var m=e.baseHref?'<base href="'+e.baseHref+'" data-cke-temp="1" />':"";h&&(a=a.replace(/<!DOCTYPE[^>]*>/i,function(a){f.docType=k=a;return""}).replace(/<\?xml\s[^\?]*\?>/i,function(a){f.xmlDeclaration=a;return""}));a=f.dataProcessor.toHtml(a);if(h){/<body[\s|>]/.test(a)||(a="<body>"+a);/<html[\s|>]/.test(a)||(a="<html>"+a+"</html>");/<head[\s|>]/.test(a)?/<title[\s|>]/.test(a)||(a=a.replace(/<head[^>]*>/,"$&<title></title>")):a=a.replace(/<html[^>]*>/,
"$&<head><title></title></head>");m&&(a=a.replace(/<head[^>]*?>/,"$&"+m));a=a.replace(/<\/head\s*>/,j+"$&");a=k+a}else a=e.docType+'<html dir="'+e.contentsLangDirection+'" lang="'+(e.contentsLanguage||f.langCode)+'"><head><title>'+this._.docTitle+"</title>"+m+j+"</head><body"+(e.bodyId?' id="'+e.bodyId+'"':"")+(e.bodyClass?' class="'+e.bodyClass+'"':"")+">"+a+"</body></html>";if(CKEDITOR.env.gecko){a=a.replace(/<body/,'<body contenteditable="true" ');CKEDITOR.env.version<2E4&&(a=a.replace(/<body[^>]*>/,
"$&<\!-- cke-content-start --\>"))}e='<script id="cke_actscrpt" type="text/javascript"'+(CKEDITOR.env.ie?' defer="defer" ':"")+">var wasLoaded=0;function onload(){if(!wasLoaded)window.parent.CKEDITOR.tools.callFunction("+this._.frameLoadedHandler+",window);wasLoaded=1;}"+(CKEDITOR.env.ie?"onload();":'document.addEventListener("DOMContentLoaded", onload, false );')+"<\/script>";CKEDITOR.env.ie&&CKEDITOR.env.version<9&&(e=e+'<script id="cke_shimscrpt">window.parent.CKEDITOR.tools.enableHtml5Elements(document)<\/script>');
m&&(CKEDITOR.env.ie&&CKEDITOR.env.version<10)&&(e=e+'<script id="cke_basetagscrpt">var baseTag = document.querySelector( "base" );baseTag.href = baseTag.href;<\/script>');a=a.replace(/(?=\s*<\/(:?head)>)/,e);this.clearCustomData();this.clearListeners();f.fire("contentDomUnload");var q=this.getDocument();try{q.write(a)}catch(l){setTimeout(function(){q.write(a)},0)}}},getData:function(a){if(a)return this.getHtml();var a=this.editor,c=a.config,d=c.fullPage,e=d&&a.docType,f=d&&a.xmlDeclaration,k=this.getDocument(),
d=d?k.getDocumentElement().getOuterHtml():k.getBody().getHtml();CKEDITOR.env.gecko&&c.enterMode!=CKEDITOR.ENTER_BR&&(d=d.replace(/<br>(?=\s*(:?$|<\/body>))/,""));d=a.dataProcessor.toDataFormat(d);f&&(d=f+"\n"+d);e&&(d=e+"\n"+d);return d},focus:function(){this._.isLoadingData?this._.isPendingFocus=true:c.baseProto.focus.call(this)},detach:function(){var a=this.editor,d=a.document,a=a.window.getFrame();c.baseProto.detach.call(this);this.clearCustomData();d.getDocumentElement().clearCustomData();a.clearCustomData();
CKEDITOR.tools.removeFunction(this._.frameLoadedHandler);(d=a.removeCustomData("onResize"))&&d.removeListener();a.remove()}}})})();CKEDITOR.config.disableObjectResizing=!1;CKEDITOR.config.disableNativeTableHandles=!0;CKEDITOR.config.disableNativeSpellChecker=!0;CKEDITOR.config.contentsCss=CKEDITOR.getUrl("contents.css");CKEDITOR.config.plugins="basicstyles,button,dialogui,dialog,clipboard,panelbutton,panel,floatpanel,colorbutton,enterkey,entities,fakeobjects,floatingspace,listblock,richcombo,font,indent,indentblock,indentlist,justify,list,magicline,pastetext,pbckcode,removeformat,sourcearea,toolbar,undo,wysiwygarea";
CKEDITOR.config.skin="moono";(function(){var a=function(a,d){for(var c=CKEDITOR.getUrl("plugins/"+d),a=a.split(","),b=0;b<a.length;b++)CKEDITOR.skin.icons[a[b]]={path:c,offset:-a[++b],bgsize:a[++b]}};CKEDITOR.env.hidpi?a("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,,ipsemoticon,432,,ipslink,456,,ipspage,960,auto,ipsprefs,504,,ipsquote,528,,ipsspoiler,552,,justifyblock,576,,justifycenter,600,,justifyleft,624,,justifyright,648,,anchor-rtl,1344,auto,anchor,1392,auto,link,1440,auto,unlink,1488,auto,bulletedlist-rtl,768,,bulletedlist,792,,numberedlist-rtl,816,,numberedlist,840,,pastetext-rtl,864,,pastetext,888,,pbckcode,912,,removeformat,936,,source-rtl,960,,source,984,,redo-rtl,1008,,redo,1032,,undo-rtl,1056,,undo,1080,",
"icons_hidpi.png"):a("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,ipsemoticon,432,auto,ipslink,456,auto,ipspage,480,auto,ipsprefs,504,auto,ipsquote,528,auto,ipsspoiler,552,auto,justifyblock,576,auto,justifycenter,600,auto,justifyleft,624,auto,justifyright,648,auto,anchor-rtl,672,auto,anchor,696,auto,link,720,auto,unlink,744,auto,bulletedlist-rtl,768,auto,bulletedlist,792,auto,numberedlist-rtl,816,auto,numberedlist,840,auto,pastetext-rtl,864,auto,pastetext,888,auto,pbckcode,912,auto,removeformat,936,auto,source-rtl,960,auto,source,984,auto,redo-rtl,1008,auto,redo,1032,auto,undo-rtl,1056,auto,undo,1080,auto",
"icons.png")})();CKEDITOR.lang.languages={af:1,ar:1,bg:1,bn:1,bs:1,ca:1,cs:1,cy:1,da:1,de: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,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}}})();