1!function(){if(!window.CKEDITOR||!window.CKEDITOR.dom){window.CKEDITOR||(window.CKEDITOR=function(){var a=/(^|.*[\\\/])ckeditor\.js(?:\?.*|;.*)?$/i,b={timestamp:"G4CD",version:"4.5.9",revision:"a35abfe",rnd:Math.floor(900*Math.random())+100,_:{pending:[],basePathSrcPattern:a},status:"unloaded",basePath:function(){var b=window.CKEDITOR_BASEPATH||"";if(!b)for(var c=document.getElementsByTagName("script"),d=0;d<c.length;d++){var e=c[d].src.match(a);if(e){b=e[1];break}}if(-1==b.indexOf(":/")&&"//"!=b.slice(0,2)&&(b=0===b.indexOf("/")?location.href.match(/^.*?:\/\/[^\/]*/)[0]+b:location.href.match(/^[^\?]*\/(?:)/)[0]+b),!b)throw'The CKEditor installation path could not be automatically detected. Please set the global variable "CKEDITOR_BASEPATH" before creating editor instances.';return b}(),getUrl:function(a){return-1==a.indexOf(":/")&&0!==a.indexOf("/")&&(a=this.basePath+a),this.timestamp&&"/"!=a.charAt(a.length-1)&&!/[&?]t=/.test(a)&&(a+=(0<=a.indexOf("?")?"&":"?")+"t="+this.timestamp),a},domReady:function(){function a(){try{document.addEventListener?(document.removeEventListener("DOMContentLoaded",a,!1),b()):document.attachEvent&&"complete"===document.readyState&&(document.detachEvent("onreadystatechange",a),b())}catch(a){}}function b(){for(var a;a=c.shift();)a()}var c=[];return function(b){function d(){try{document.documentElement.doScroll("left")}catch(a){return void setTimeout(d,1)}a()}if(c.push(b),"complete"===document.readyState&&setTimeout(a,1),1==c.length)if(document.addEventListener)document.addEventListener("DOMContentLoaded",a,!1),window.addEventListener("load",a,!1);else if(document.attachEvent){document.attachEvent("onreadystatechange",a),window.attachEvent("onload",a),b=!1;try{b=!window.frameElement}catch(a){}document.documentElement.doScroll&&b&&d()}}}()},c=window.CKEDITOR_GETURL;if(c){var d=b.getUrl;b.getUrl=function(a){return c.call(b,a)||d.call(b,a)}}return b}()),CKEDITOR.event||(CKEDITOR.event=function(){},CKEDITOR.event.implementOn=function(a){var c,b=CKEDITOR.event.prototype;for(c in b)null==a[c]&&(a[c]=b[c])},CKEDITOR.event.prototype=function(){function a(a){var d=b(this);return d[a]||(d[a]=new c(a))}var b=function(a){return a=a.getPrivate&&a.getPrivate()||a._||(a._={}),a.events||(a.events={})},c=function(a){this.name=a,this.listeners=[]};return c.prototype={getListenerIndex:function(a){for(var b=0,c=this.listeners;b<c.length;b++)if(c[b].fn==a)return b;return-1}},{define:function(b,c){var d=a.call(this,b);CKEDITOR.tools.extend(d,c,!0)},on:function(b,c,d,e,f){function g(a,f,g,i){return a={name:b,sender:this,editor:a,data:f,listenerData:e,stop:g,cancel:i,removeListener:h},!1!==c.call(d,a)&&a.data}function h(){j.removeListener(b,c)}var i=a.call(this,b);if(0>i.getListenerIndex(c)){i=i.listeners,d||(d=this),isNaN(f)&&(f=10);var j=this;g.fn=c,g.priority=f;for(var k=i.length-1;0<=k;k--)if(i[k].priority<=f)return i.splice(k+1,0,g),{removeListener:h};i.unshift(g)}return{removeListener:h}},once:function(){var a=Array.prototype.slice.call(arguments),b=a[1];return a[1]=function(a){return a.removeListener(),b.apply(this,arguments)},this.on.apply(this,a)},capture:function(){CKEDITOR.event.useCapture=1;var a=this.on.apply(this,arguments);return CKEDITOR.event.useCapture=0,a},fire:function(){var a=0,c=function(){a=1},d=0,e=function(){d=1};return function(f,g,h){var i=b(this)[f];f=a;var j=d;if(a=d=0,i){var k=i.listeners;if(k.length)for(var l,k=k.slice(0),m=0;m<k.length;m++){if(i.errorProof)try{l=k[m].call(this,h,g,c,e)}catch(a){}else l=k[m].call(this,h,g,c,e);if(!1===l?d=1:"undefined"!=typeof l&&(g=l),a||d)break}}return g=!d&&("undefined"==typeof g||g),a=f,d=j,g}}(),fireOnce:function(a,c,d){return c=this.fire(a,c,d),delete b(this)[a],c},removeListener:function(a,c){var d=b(this)[a];if(d){var e=d.getListenerIndex(c);0<=e&&d.listeners.splice(e,1)}},removeAllListeners:function(){var c,a=b(this);for(c in a)delete a[c]},hasListeners:function(a){return(a=b(this)[a])&&0<a.listeners.length}}}()),CKEDITOR.editor||(CKEDITOR.editor=function(){CKEDITOR._.pending.push([this,arguments]),CKEDITOR.event.call(this)},CKEDITOR.editor.prototype.fire=function(a,b){return a in{instanceReady:1,loaded:1}&&(this[a]=!0),CKEDITOR.event.prototype.fire.call(this,a,b,this)},CKEDITOR.editor.prototype.fireOnce=function(a,b){return a in{instanceReady:1,loaded:1}&&(this[a]=!0),CKEDITOR.event.prototype.fireOnce.call(this,a,b,this)},CKEDITOR.event.implementOn(CKEDITOR.editor.prototype)),CKEDITOR.env||(CKEDITOR.env=function(){var a=navigator.userAgent.toLowerCase(),b=a.match(/edge[ \/](\d+.?\d*)/),c=-1<a.indexOf("trident/"),c=!(!b&&!c),c={ie:c,edge:!!b,webkit:!c&&-1<a.indexOf(" applewebkit/"),air:-1<a.indexOf(" adobeair/"),mac:-1<a.indexOf("macintosh"),quirks:"BackCompat"==document.compatMode&&(!document.documentMode||10>document.documentMode),mobile:-1<a.indexOf("mobile"),iOS:/(ipad|iphone|ipod)/.test(a),isCustomDomain:function(){if(!this.ie)return!1;var a=document.domain,b=window.location.hostname;return a!=b&&a!="["+b+"]"},secure:"https:"==location.protocol};c.gecko="Gecko"==navigator.product&&!c.webkit&&!c.ie,c.webkit&&(-1<a.indexOf("chrome")?c.chrome=!0:c.safari=!0);var d=0;return c.ie&&(d=b?parseFloat(b[1]):c.quirks||!document.documentMode?parseFloat(a.match(/msie (\d+)/)[1]):document.documentMode,c.ie9Compat=9==d,c.ie8Compat=8==d,c.ie7Compat=7==d,c.ie6Compat=7>
1d||c.quirks),c.gecko&&(b=a.match(/rv:([\d\.]+)/))&&(b=b[1].split("."),d=1e4*b[0]+100*(b[1]||0)+1*(b[2]||0)),c.air&&(d=parseFloat(a.match(/ adobeair\/(\d+)/)[1])),c.webkit&&(d=parseFloat(a.match(/ applewebkit\/(\d+)/)[1])),c.version=d,c.isCompatible=!(c.ie&&7>d||c.gecko&&4e4>d||c.webkit&&534>d),c.hidpi=2<=window.devicePixelRatio,c.needsBrFiller=c.gecko||c.webkit||c.ie&&10<d,c.needsNbspFiller=c.ie&&11>d,c.cssClass="cke_browser_"+(c.ie?"ie":c.gecko?"gecko":c.webkit?"webkit":"unknown"),c.quirks&&(c.cssClass+=" cke_browser_quirks"),c.ie&&(c.cssClass+=" cke_browser_ie"+(c.quirks?"6 cke_browser_iequirks":c.version)),c.air&&(c.cssClass+=" cke_browser_air"),c.iOS&&(c.cssClass+=" cke_browser_ios"),c.hidpi&&(c.cssClass+=" cke_hidpi"),c}()),"unloaded"==CKEDITOR.status&&function(){CKEDITOR.event.implementOn(CKEDITOR),CKEDITOR.loadFullCore=function(){if("basic_ready"!=CKEDITOR.status)CKEDITOR.loadFullCore._load=1;else{delete CKEDITOR.loadFullCore;var a=document.createElement("script");a.type="text/javascript",a.src=CKEDITOR.basePath+"ckeditor.js",document.getElementsByTagName("head")[0].appendChild(a)}},CKEDITOR.loadFullCoreTimeout=0,CKEDITOR.add=function(a){(this._.pending||(this._.pending=[])).push(a)},function(){CKEDITOR.domReady(function(){var a=CKEDITOR.loadFullCore,b=CKEDITOR.loadFullCoreTimeout;a&&(CKEDITOR.status="basic_ready",a&&a._load?a():b&&setTimeout(function(){CKEDITOR.loadFullCore&&CKEDITOR.loadFullCore()},1e3*b))})}(),CKEDITOR.status="basic_loaded"}(),CKEDITOR.VERBOSITY_WARN=1,CKEDITOR.VERBOSITY_ERROR=2,CKEDITOR.verbosity=CKEDITOR.VERBOSITY_WARN|CKEDITOR.VERBOSITY_ERROR,CKEDITOR.warn=function(a,b){CKEDITOR.verbosity&CKEDITOR.VERBOSITY_WARN&&CKEDITOR.fire("log",{type:"warn",errorCode:a,additionalData:b})},CKEDITOR.error=function(a,b){CKEDITOR.verbosity&CKEDITOR.VERBOSITY_ERROR&&CKEDITOR.fire("log",{type:"error",errorCode:a,additionalData:b})},CKEDITOR.on("log",function(a){if(window.console&&window.console.log){var b=console[a.data.type]?a.data.type:"log",c=a.data.errorCode;(a=a.data.additionalData)?console[b]("[CKEDITOR] Error code: "+c+".",a):console[b]("[CKEDITOR] Error code: "+c+"."),console[b]("[CKEDITOR] For more information about this error go to http://docs.ckeditor.com/#!/guide/dev_errors-section-"+c)}},null,null,999),CKEDITOR.dom={},function(){var a=[],b=CKEDITOR.env.gecko?"-moz-":CKEDITOR.env.webkit?"-webkit-":CKEDITOR.env.ie?"-ms-":"",c=/&/g,d=/>/g,e=/</g,f=/"/g,g=/&(lt|gt|amp|quot|nbsp|shy|#\d{1,5});/g,h={lt:"<",gt:">",amp:"&",quot:'"',nbsp:"Â ",shy:"Â"},i=function(a,b){return"#"==b[0]?String.fromCharCode(parseInt(b.slice(1),10)):h[b]};CKEDITOR.on("reset",function(){a=[]}),CKEDITOR.tools={arrayCompare:function(a,b){if(!a&&!b)return!0;if(!a||!b||a.length!=b.length)return!1;for(var c=0;c<a.length;c++)if(a[c]!=b[c])return!1;return!0},getIndex:function(a,b){for(var c=0;c<a.length;++c)if(b(a[c]))return c;return-1},clone:function(a){var b;if(a&&a instanceof Array){b=[];for(var c=0;c<a.length;c++)b[c]=CKEDITOR.tools.clone(a[c]);return b}if(null===a||"object"!=typeof a||a instanceof String||a instanceof Number||a instanceof Boolean||a instanceof Date||a instanceof RegExp||a.nodeType||a.window===a)return a;b=new a.constructor;for(c in a)b[c]=CKEDITOR.tools.clone(a[c]);return b},capitalize:function(a,b){return a.charAt(0).toUpperCase()+(b?a.slice(1):a.slice(1).toLowerCase())},extend:function(a){var c,d,b=arguments.length;"boolean"==typeof(c=arguments[b-1])?b--:"boolean"==typeof(c=arguments[b-2])&&(d=arguments[b-1],b-=2);for(var e=1;e<b;e++){var g,f=arguments[e];for(g in f)!0!==c&&null!=a[g]||(!d||g in d)&&(a[g]=f[g])}return a},prototypedCopy:function(a){var b=function(){};return b.prototype=a,new b},copy:function(a){var c,b={};for(c in a)b[c]=a[c];return b},isArray:function(a){return"[object Array]"==Object.prototype.toString.call(a)},isEmpty:function(a){for(var b in a)if(a.hasOwnProperty(b))return!1;return!0},cssVendorPrefix:function(a,c,d){return d?b+a+":"+c+";"+a+":"+c:(d={},d[a]=c,d[b+a]=c,d)},cssStyleToDomStyle:function(){var a=document.createElement("div").style,b="undefined"!=typeof a.cssFloat?"cssFloat":"undefined"!=typeof a.styleFloat?"styleFloat":"float";return function(a){return"float"==a?b:a.replace(/-./g,function(a){return a.substr(1).toUpperCase()})}}(),buildStyleHtml:function(a){a=[].concat(a);for(var b,c=[],d=0;d<a.length;d++)(b=a[d])&&(/@import|[{}]/.test(b)?c.push("<style>"+b+"</style>"):c.push('<link type="text/css" rel=stylesheet href="'+b+'">'));return c.join("")},htmlEncode:function(a){return void 0===a||null===a?"":String(a).replace(c,"&").replace(d,">").replace(e,"<")},htmlDecode:function(a){return a.replace(g,i)},htmlEncodeAttr:function(a){return CKEDITOR.tools.htmlEncode(a).replace(f,""")},htmlDecodeAttr:function(a){return CKEDITOR.tools.htmlDecode(a)},transformPlainTextToHtml:function(a,b){var c=b==CKEDITOR.ENTER_BR,d=this.htmlEncode(a.replace(/\r\n/g,"\n")),d=d.replace(/\t/g," "),e=b==CKEDITOR.ENTER_P?"p":"div";if(!c){var f=/\n{2}/g;if(f.test(d))var g="<"+e+">",h="</"+e+">",d=g+d.replace(f,function(){return h+g})+h}return d=d.replace(/\n/g,"<br>"),c||(d=d.replace(new RegExp("<br>(?=</"+e+">)"),function(a){return CKEDITOR.tools.repeat(a,2)})),d=d.replace(/^ | $/g," "),d=d.replace(/(>|\s) /g,function(a,b){return b+" "}).replace(/ (?=<)/g," ")},getNextNumber:function(){var a=0;return function(){return++a}}(),getNextId:function(){return"cke_"+this.getNextNumber()},getUniqueId:function(){for(var a="e",b=0;8>b;b++)a+=Math.floor(65536*(1+Math.random())).toString(16).substring(1);return a},override:function(a,b){var c=b(a);return c.prototype=a.prototype,c},setTimeout:function(a,b,c,d,e){return e||(e=window),c||(c=e),e.setTimeout(function(){d?a.apply(c,[].concat(d)):a.apply(c)},b||0)},trim:function(){var a=/(?:^[ \t\n\r]+)|(?:[ \t\n\r]+$)/g;return function(b){return b.replace(a,"")}}(),ltrim:function(){var a=/^[ \t\n\r]+/g;return function(b){return b.replace(a,"")}}(),rtrim:function(){var a=/[ \t\n\r]+$/g;return function(b){return b.replace(a,"")}}(),indexOf:function(a,b){if("function"==typeof b){for(var c=0,d=a.length;c<d;c++)if(b(a[c]))return c}else{if(a.indexOf)return a.indexOf(b);for(c=0,d=a.length;c<d;c++)if(a[c]===b)return c}return-1},search:function(a,b){var c=CKEDITOR.tools.indexOf(a,b);return 0<=c?a[c]:null},bind:function(a,b){return function(){return a.apply(b,arguments)}},createClass:function(a){var b=a.$,c=a.base,d=a.privates||a._,e=a.proto;if(a=a.statics,!b&&(b=function(){c&&this.base.apply(this,arguments)}),d)var f=b,b=function(){var b,a=this._||(this._={});for(b in d){var c=d[b];a[b]="function"==typeof c?CKEDITOR.tools.bind(c,this):c}f.apply(this,arguments)};return c&&(b.prototype=this.prototypedCopy(c.prototype),b.prototype.constructor=b,b.base=c,b.baseProto=c.prototype,b.prototype.base
1=function(){this.base=c.prototype.base,c.apply(this,arguments),this.base=arguments.callee}),e&&this.extend(b.prototype,e,!0),a&&this.extend(b,a,!0),b},addFunction:function(b,c){return a.push(function(){return b.apply(c||this,arguments)})-1},removeFunction:function(b){a[b]=null},callFunction:function(b){var c=a[b];return c&&c.apply(window,Array.prototype.slice.call(arguments,1))},cssLength:function(){var b,a=/^-?\d+\.?\d*px$/;return function(c){return b=CKEDITOR.tools.trim(c+"")+"px",a.test(b)?b:c||""}}(),convertToPx:function(){var a;return function(b){return a||(a=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(a)),/%$/.test(b)?b:(a.setStyle("width",b),a.$.clientWidth)}}(),repeat:function(a,b){return Array(b+1).join(a)},tryThese:function(){for(var a,b=0,c=arguments.length;b<c;b++){var d=arguments[b];try{a=d();break}catch(a){}}return a},genKey:function(){return Array.prototype.slice.call(arguments).join("-")},defer:function(a){return function(){var b=arguments,c=this;window.setTimeout(function(){a.apply(c,b)},0)}},normalizeCssText:function(a,b){var d,c=[],e=CKEDITOR.tools.parseCssText(a,!0,b);for(d in e)c.push(d+":"+e[d]);return c.sort(),c.length?c.join(";")+";":""},convertRgbToHex:function(a){return a.replace(/(?:rgb\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*\))/gi,function(a,b,c,d){for(a=[b,c,d],b=0;3>b;b++)a[b]=("0"+parseInt(a[b],10).toString(16)).slice(-2);return"#"+a.join("")})},parseCssText:function(a,b,c){var d={};return c&&(c=new CKEDITOR.dom.element("span"),c.setAttribute("style",a),a=CKEDITOR.tools.convertRgbToHex(c.getAttribute("style")||"")),a&&";"!=a?(a.replace(/"/g,'"').replace(/\s*([^:;\s]+)\s*:\s*([^;]+)\s*(?=;|$)/g,function(a,c,e){b&&(c=c.toLowerCase(),"font-family"==c&&(e=e.toLowerCase().replace(/["']/g,"").replace(/\s*,\s*/g,",")),e=CKEDITOR.tools.trim(e)),d[c]=e}),d):d},writeCssText:function(a,b){var c,d=[];for(c in a)d.push(c+":"+a[c]);return b&&d.sort(),d.join("; ")},objectCompare:function(a,b,c){var d;if(!a&&!b)return!0;if(!a||!b)return!1;for(d in a)if(a[d]!=b[d])return!1;if(!c)for(d in b)if(a[d]!=b[d])return!1;return!0},objectKeys:function(a){var c,b=[];for(c in a)b.push(c);return b},convertArrayToObject:function(a,b){var c={};1==arguments.length&&(b=!0);for(var d=0,e=a.length;d<e;++d)c[a[d]]=b;return c},fixDomain:function(){for(var a;;)try{a=window.parent.document.domain;break}catch(b){if(a=a?a.replace(/.+?(?:\.|$)/,""):document.domain,!a)break;document.domain=a}return!!a},eventsBuffer:function(a,b,c){function d(){f=(new Date).getTime(),e=!1,c?b.call(c):b()}var e,f=0;return{input:function(){if(!e){var b=(new Date).getTime()-f;b<a?e=setTimeout(d,a-b):d()}},reset:function(){e&&clearTimeout(e),e=f=0}}},enableHtml5Elements:function(a,b){for(var e,c="abbr article aside audio bdi canvas data datalist details figcaption figure footer header hgroup main mark meter nav output progress section summary time video".split(" "),d=c.length;d--;)e=a.createElement(c[d]),b&&a.appendChild(e)},checkIfAnyArrayItemMatches:function(a,b){for(var c=0,d=a.length;c<d;++c)if(a[c].match(b))return!0;return!1},checkIfAnyObjectPropertyMatches:function(a,b){for(var c in a)if(c.match(b))return!0;return!1},transparentImageData:"data:image/gif;base64,R0lGODlhAQABAPABAP///wAAACH5BAEKAAAALAAAAAABAAEAAAICRAEAOw==",getCookie:function(a){a=a.toLowerCase();for(var c,d,b=document.cookie.split(";"),e=0;e<b.length;e++)if(c=b[e].split("="),d=decodeURIComponent(CKEDITOR.tools.trim(c[0]).toLowerCase()),d===a)return decodeURIComponent(1<c.length?c[1]:"");return null},setCookie:function(a,b){document.cookie=encodeURIComponent(a)+"="+encodeURIComponent(b)+";path=/"},getCsrfToken:function(){var a=CKEDITOR.tools.getCookie("ckCsrfToken");if(!a||40!=a.length){var a=[],b="";if(window.crypto&&window.crypto.getRandomValues)a=new Uint8Array(40),window.crypto.getRandomValues(a);else for(var c=0;40>c;c++)a.push(Math.floor(256*Math.random()));for(c=0;c<a.length;c++)var d="abcdefghijklmnopqrstuvwxyz0123456789".charAt(a[c]%36),b=b+(.5<Math.random()?d.toUpperCase():d);
1a=b,CKEDITOR.tools.setCookie("ckCsrfToken",a)}return a}}}(),CKEDITOR.dtd=function(){var a=CKEDITOR.tools.extend,b=function(a,b){for(var c=CKEDITOR.tools.clone(a),d=1;d<arguments.length;d++){b=arguments[d];for(var e in b)delete c[e]}return c},c={},d={},e={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},f={command:1,link:1,meta:1,noscript:1,script:1,style:1},g={},h={"#":1},i={center:1,dir:1,noframes:1};return a(c,{a:1,abbr:1,area:1,audio:1,b:1,bdi:1,bdo:1,br:1,button:1,canvas:1,cite:1,code:1,command:1,datalist:1,del:1,dfn:1,em:1,embed:1,i:1,iframe:1,img:1,input:1,ins:1,kbd:1,keygen:1,label:1,map:1,mark:1,meter:1,noscript:1,object:1,output:1,progress:1,q:1,ruby:1,s:1,samp:1,script:1,select:1,small:1,span:1,strong:1,sub:1,sup:1,textarea:1,time:1,u:1,var:1,video:1,wbr:1},h,{acronym:1,applet:1,basefont:1,big:1,font:1,isindex:1,strike:1,style:1,tt:1}),a(d,e,c,i),b={a:b(c,{a:1,button:1}),abbr:c,address:d,area:g,article:d,aside:d,audio:a({source:1,track:1},d),b:c,base:g,bdi:c,bdo:c,blockquote:d,body:d,br:g,button:b(c,{a:1,button:1}),canvas:c,caption:d,cite:c,code:c,col:g,colgroup:{col:1},command:g,datalist:a({option:1},c),dd:d,del:c,details:a({summary:1},d),dfn:c,div:d,dl:{dt:1,dd:1},dt:d,em:c,embed:g,fieldset:a({legend:1},d),figcaption:d,figure:a({figcaption:1},d),footer:d,form:d,h1:c,h2:c,h3:c,h4:c,h5:c,h6:c,head:a({title:1,base:1},f),header:d,hgroup:{h1:1,h2:1,h3:1,h4:1,h5:1,h6:1},hr:g,html:a({head:1,body:1},d,f),i:c,iframe:h,img:g,input:g,ins:c,kbd:c,keygen:g,label:c,legend:c,li:d,link:g,main:d,map:d,mark:c,menu:a({li:1},d),meta:g,meter:b(c,{meter:1}),nav:d,noscript:a({link:1,meta:1,style:1},c),object:a({param:1},c),ol:{li:1},optgroup:{option:1},option:h,output:c,p:c,param:g,pre:c,progress:b(c,{progress:1}),q:c,rp:c,rt:c,ruby:a({rp:1,rt:1},c),s:c,samp:c,script:h,section:d,select:{optgroup:1,option:1},small:c,source:g,span:c,strong:c,style:h,sub:c,summary:a({h1:1,h2:1,h3:1,h4:1,h5:1,h6:1},c),sup:c,table:{caption:1,colgroup:1,thead:1,tfoot:1,tbody:1,tr:1},tbody:{tr:1},td:d,textarea:h,tfoot:{tr:1},th:d,thead:{tr:1},time:b(c,{time:1}),title:h,tr:{th:1,td:1},track:g,u:c,ul:{li:1},var:c,video:a({source:1,track:1},d),wbr:g,acronym:c,applet:a({param:1},d),basefont:g,big:c,center:d,dialog:g,dir:{li:1},font:c,isindex:g,noframes:d,strike:c,tt:c},a(b,{$block:a({audio:1,dd:1,dt:1,figcaption:1,li:1,video:1},e,i),$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:c,$list:{dl:1,ol:1,ul:1},$listItem:{dd:1,dt:1,li:1},$nonBodyContent:a({body:1,head:1,html:1},b.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}}),b}(),CKEDITOR.dom.event=function(a){this.$=a},CKEDITOR.dom.event.prototype={getKey:function(){return this.$.keyCode||this.$.which},getKeystroke:function(){var a=this.getKey();return(this.$.ctrlKey||this.$.metaKey)&&(a+=CKEDITOR.CTRL),this.$.shiftKey&&(a+=CKEDITOR.SH
1IFT),this.$.altKey&&(a+=CKEDITOR.ALT),a},preventDefault:function(a){var b=this.$;b.preventDefault?b.preventDefault():b.returnValue=!1,a&&this.stopPropagation()},stopPropagation:function(){var a=this.$;a.stopPropagation?a.stopPropagation():a.cancelBubble=!0},getTarget:function(){var a=this.$.target||this.$.srcElement;return a?new CKEDITOR.dom.node(a):null},getPhase:function(){return this.$.eventPhase||2},getPageOffset:function(){var a=this.getTarget().getDocument().$;return{x:this.$.pageX||this.$.clientX+(a.documentElement.scrollLeft||a.body.scrollLeft),y:this.$.pageY||this.$.clientY+(a.documentElement.scrollTop||a.body.scrollTop)}}},CKEDITOR.CTRL=1114112,CKEDITOR.SHIFT=2228224,CKEDITOR.ALT=4456448,CKEDITOR.EVENT_PHASE_CAPTURING=1,CKEDITOR.EVENT_PHASE_AT_TARGET=2,CKEDITOR.EVENT_PHASE_BUBBLING=3,CKEDITOR.dom.domObject=function(a){a&&(this.$=a)},CKEDITOR.dom.domObject.prototype=function(){var a=function(a,b){return function(c){"undefined"!=typeof CKEDITOR&&a.fire(b,new CKEDITOR.dom.event(c))}};return{getPrivate:function(){var a;return(a=this.getCustomData("_"))||this.setCustomData("_",a={}),a},on:function(b){var c=this.getCustomData("_cke_nativeListeners");return c||(c={},this.setCustomData("_cke_nativeListeners",c)),c[b]||(c=c[b]=a(this,b),this.$.addEventListener?this.$.addEventListener(b,c,!!CKEDITOR.event.useCapture):this.$.attachEvent&&this.$.attachEvent("on"+b,c)),CKEDITOR.event.prototype.on.apply(this,arguments)},removeListener:function(a){if(CKEDITOR.event.prototype.removeListener.apply(this,arguments),!this.hasListeners(a)){var b=this.getCustomData("_cke_nativeListeners"),c=b&&b[a];c&&(this.$.removeEventListener?this.$.removeEventListener(a,c,!1):this.$.detachEvent&&this.$.detachEvent("on"+a,c),delete b[a])}},removeAllListeners:function(){var b,a=this.getCustomData("_cke_nativeListeners");for(b in a){var c=a[b];this.$.detachEvent?this.$.detachEvent("on"+b,c):this.$.removeEventListener&&this.$.removeEventListener(b,c,!1),delete a[b]}CKEDITOR.event.prototype.removeAllListeners.call(this)}}}(),function(a){var b={};CKEDITOR.on("reset",function(){b={}}),a.equals=function(a){try{return a&&a.$===this.$}catch(a){return!1}},a.setCustomData=function(a,c){var d=this.getUniqueId();return(b[d]||(b[d]={}))[a]=c,this},a.getCustomData=function(a){var c=this.$["data-cke-expando"];return(c=c&&b[c])&&a in c?c[a]:null},a.removeCustomData=function(a){var d,e,c=this.$["data-cke-expando"],c=c&&b[c];return c&&(d=c[a],e=a in c,delete c[a]),e?d:null},a.clearCustomData=function(){this.removeAllListeners();var a=this.$["data-cke-expando"];a&&delete b[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,b){return a.append(this,b),a},clone:function(a,b){function c(d){if(d["data-cke-expando"]&&(d["data-cke-expando"]=!1),(d.nodeType==CKEDITOR.NODE_ELEMENT||d.nodeType==CKEDITOR.NODE_DOCUMENT_FRAGMENT)&&(b||d.nodeType!=CKEDITOR.NODE_ELEMENT||d.removeAttribute("id",!1),a)){d=d.childNodes;for(var e=0;e<d.length;e++)c(d[e])}}function d(b){if(b.type==CKEDITOR.NODE_ELEMENT||b.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT){if(b.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT){var c=b.getName();":"==c[0]&&b.renameNode(c.substring(1))}if(a)for(c=0;c<b.getChildCount();c++)d(b.getChild(c))}}var e=this.$.cloneNode(a);return c(e),e=new CKEDITOR.dom.node(e),CKEDITOR.env.ie&&9>
1CKEDITOR.env.version&&(this.type==CKEDITOR.NODE_ELEMENT||this.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT)&&d(e),e},hasPrevious:function(){return!!this.$.previousSibling},hasNext:function(){return!!this.$.nextSibling},insertAfter:function(a){return a.$.parentNode.insertBefore(this.$,a.$.nextSibling),a},insertBefore:function(a){return a.$.parentNode.insertBefore(this.$,a.$),a},insertBeforeMe:function(a){return this.$.parentNode.insertBefore(a.$,this.$),a},getAddress:function(a){for(var b=[],c=this.getDocument().$.documentElement,d=this.$;d&&d!=c;){var e=d.parentNode;e&&b.unshift(this.getIndex.call({$:d},a)),d=e}return b},getDocument:function(){return new CKEDITOR.dom.document(this.$.ownerDocument||this.$.parentNode.ownerDocument)},getIndex:function(a){function b(a,d){var e=d?a.nextSibling:a.previousSibling;return e&&e.nodeType==CKEDITOR.NODE_TEXT?c(e)?b(e,d):e:null}function c(a){return!a.nodeValue||a.nodeValue==CKEDITOR.dom.selection.FILLING_CHAR_SEQUENCE}var f,d=this.$,e=-1;if(!this.$.parentNode||a&&d.nodeType==CKEDITOR.NODE_TEXT&&c(d)&&!b(d)&&!b(d,!0))return-1;do a&&d!=this.$&&d.nodeType==CKEDITOR.NODE_TEXT&&(f||c(d))||(e++,f=d.nodeType==CKEDITOR.NODE_TEXT);while(d=d.previousSibling);return e},getNextSourceNode:function(a,b,c){if(c&&!c.call){var d=c;c=function(a){return!a.equals(d)}}a=!a&&this.getFirst&&this.getFirst();var e;if(!a){if(this.type==CKEDITOR.NODE_ELEMENT&&c&&!1===c(this,!0))return null;a=this.getNext()}for(;!a&&(e=(e||this).getParent());){if(c&&!1===c(e,!0))return null;a=e.getNext()}return!a||c&&!1===c(a)?null:b&&b!=a.type?a.getNextSourceNode(!1,b,c):a},getPreviousSourceNode:function(a,b,c){if(c&&!c.call){var d=c;c=function(a){return!a.equals(d)}}a=!a&&this.getLast&&this.getLast();var e;if(!a){if(this.type==CKEDITOR.NODE_ELEMENT&&c&&!1===c(this,!0))return null;a=this.getPrevious()}for(;!a&&(e=(e||this).getParent());){if(c&&!1===c(e,!0))return null;a=e.getPrevious()}return!a||c&&!1===c(a)?null:b&&a.type!=b?a.getPreviousSourceNode(!1,b,c):a},getPrevious:function(a){var c,b=this.$;do c=(b=b.previousSibling)&&10!=b.nodeType&&new CKEDITOR.dom.node(b);while(c&&a&&!a(c));return c},getNext:function(a){var c,b=this.$;do c=(b=b.nextSibling)&&new CKEDITOR.dom.node(b);while(c&&a&&!a(c));return c},getParent:function(a){var b=this.$.parentNode;return b&&(b.nodeType==CKEDITOR.NODE_ELEMENT||a&&b.nodeType==CKEDITOR.NODE_DOCUMENT_FRAGMENT)?new CKEDITOR.dom.node(b):null},getParents:function(a){var b=this,c=[];do c[a?"push":"unshift"](b);while(b=b.getParent());return c},getCommonAncestor:function(a){if(a.equals(this))return this;if(a.contains&&a.contains(this))return a;var b=this.contains?this:this.getParent();do if(b.contains(a))return b;while(b=b.getParent());return null},getPosition:function(a){var b=this.$,c=a.$;if(b.compareDocumentPosition)return b.compareDocumentPosition(c);if(b==c)return CKEDITOR.POSITION_IDENTICAL;if(this.type==CKEDITOR.NODE_ELEMENT&&a.type==CKEDITOR.NODE_ELEMENT){if(b.contains){if(b.contains(c))return CKEDITOR.POSITION_CONTAINS+CKEDITOR.POSITION_PRECEDING;if(c.contains(b))return CKEDITOR.POSITION_IS_CONTAINED+CKEDITOR.POSITION_FOLLOWING}if("sourceIndex"in b)return 0>b.sourceIndex||0>c.sourceIndex?CKEDITOR.POSITION_DISCONNECTED:b.sourceIndex<c.sourceIndex?CKEDITOR.POSITION_PRECEDING:CKEDITOR.POSITION_FOLLOWING}b=this.getAddress(),a=a.getAddress();for(var c=Math.min(b.length,a.length),d=0;d<c;d++)if(b[d]!=a[d])return b[d]<a[d]?CKEDITOR.POSITION_PRECEDING:CKEDITOR.POSITION_FOLLOWING;return b.length<a.length?CKEDITOR.POSITION_CONTAINS+CKEDITOR.POSITION_PRECEDING:CKEDITOR.POSITION_IS_CONTAINED+CKEDITOR.POSITION_FOLLOWING},getAscendant:function(a,b){var d,e,c=this.$;b||(c=c.parentNode),"function"==typeof a?(e=!0,d=a):(e=!1,d=function(b){return b="string"==typeof b.nodeName?b.nodeName.toLowerCase():"","string"==typeof a?b==a:b in a});for(;c;){if(d(e?new CKEDITOR.dom.node(c):c))return new CKEDITOR.dom.node(c);try{c=c.parentNode}catch(a){c=null}}return null},hasAscendant:function(a,b){var c=this.$;for(b||(c=c.parentNode);c;){if(c.nodeName&&c.nodeName.toLowerCase()==a)return!0;c=c.parentNode}return!1},move:function(a,b){a.append(this.remove(),b)},remove:function(a){var b=this.$,c=b.parentNode;if(c){if(a)for(;a=b.firstChild;)c.insertBefore(b.removeChild(a),b);c.removeChild(b)}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 b=CKEDITOR.tools.ltrim(a.getText()),c=a.getLength();if(!b){a.remove();continue}b.length<c&&(a.split(c-b.length),this.$.removeChild(this.$.firstChild))}break}},rtrim:function(){for(var a;this.getLast&&(a=this.getLast());){if(a.type==CKEDITOR.NODE_TEXT){var b=CKEDITOR.tools.rtrim(a.getText()),c=a.getLength();if(!b){a.remove();continue}b.length<c&&(a.split(b.length),this.$.lastChild.parentNode.removeChild(this.$.lastChild))}break}CKEDITOR.env.needsBrFiller&&(a=this.$.lastChild)&&1==a.type&&"br"==a.nodeName.toLowerCase()&&a.parentNode.removeChild(a)},isReadOnly:function(a){var b=this;
1if(this.type!=CKEDITOR.NODE_ELEMENT&&(b=this.getParent()),CKEDITOR.env.edge&&b&&b.is("textarea","input")&&(a=!0),!a&&b&&"undefined"!=typeof b.$.isContentEditable)return!(b.$.isContentEditable||b.data("cke-editable"));for(;b;){if(b.data("cke-editable"))return!1;if(b.hasAttribute("contenteditable"))return"false"==b.getAttribute("contenteditable");b=b.getParent()}return!0}}),CKEDITOR.dom.window=function(a){CKEDITOR.dom.domObject.call(this,a)},CKEDITOR.dom.window.prototype=new CKEDITOR.dom.domObject,CKEDITOR.tools.extend(CKEDITOR.dom.window.prototype,{focus:function(){this.$.focus()},getViewPaneSize:function(){var a=this.$.document,b="CSS1Compat"==a.compatMode;return{width:(b?a.documentElement.clientWidth:a.body.clientWidth)||0,height:(b?a.documentElement.clientHeight:a.body.clientHeight)||0}},getScrollPosition:function(){var a=this.$;return"pageXOffset"in a?{x:a.pageXOffset||0,y:a.pageYOffset||0}:(a=a.document,{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 b=new CKEDITOR.dom.element("link");b.setAttributes({rel:"stylesheet",type:"text/css",href:a}),this.getHead().append(b)}},appendStyleText:function(a){if(this.$.createStyleSheet){var b=this.$.createStyleSheet("");b.cssText=a}else{var c=new CKEDITOR.dom.element("style",this);c.append(new CKEDITOR.dom.text(a,this)),this.getHead().append(c)}return b||c.$.sheet},createElement:function(a,b){var c=new CKEDITOR.dom.element(a,this);return b&&(b.attributes&&c.setAttributes(b.attributes),b.styles&&c.setStyles(b.styles)),c},createText:function(a){return new CKEDITOR.dom.text(a,this)},focus:function(){this.getWindow().focus()},getActive:function(){var a;try{a=this.$.activeElement}catch(a){return null}return new CKEDITOR.dom.element(a)},getById:function(a){return(a=this.$.getElementById(a))?new CKEDITOR.dom.element(a):null; 2},getByAddress:function(a,b){for(var c=this.$.documentElement,d=0;c&&d<a.length;d++){var e=a[d];if(b)for(var f=-1,g=0;g<c.childNodes.length;g++){var h=c.childNodes[g];if((!0!==b||3!=h.nodeType||!h.previousSibling||3!=h.previousSibling.nodeType)&&(f++,f==e)){c=h;break}}else c=c.childNodes[e]}return c?new CKEDITOR.dom.node(c):null},getElementsByTag:function(a,b){return CKEDITOR.env.ie&&8>=document.documentMode||!b||(a=b+":"+a),new CKEDITOR.dom.nodeList(this.$.getElementsByTagName(a))},getHead:function(){var a=this.$.getElementsByTagName("head")[0];return a=a?new CKEDITOR.dom.element(a):this.getDocumentElement().append(new CKEDITOR.dom.element("head"),!0)},getBody:function(){return new CKEDITOR.dom.element(this.$.body)},getDocumentElement:function(){return new CKEDITOR.dom.element(this.$.documentElement)},getWindow:function(){return new CKEDITOR.dom.window(this.$.parentWindow||this.$.defaultView)},write:function(a){this.$.open("text/html","replace"),CKEDITOR.env.ie&&(a=a.replace(/(?:^\s*<!DOCTYPE[^>]*?>)|^/i,'$&\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");return a||(a=this.$.createDocumentFragment(),CKEDITOR.tools.enableHtml5Elements(a,!0),this.setCustomData("html5ShivFrag",a)),a}}),CKEDITOR.dom.nodeList=function(a){this.$=a},CKEDITOR.dom.nodeList.prototype={count:function(){return this.$.length},getItem:function(a){return 0>a||a>=this.$.length?null:(a=this.$[a])?new CKEDITOR.dom.node(a):null}},CKEDITOR.dom.element=function(a,b){"string"==typeof a&&(a=(b?b.$:document).createElement(a)),CKEDITOR.dom.domObject.call(this,a)},CKEDITOR.dom.element.get=function(a){return(a="string"==typeof a?document.getElementById(a)||document.getElementsByName(a)[0]:a)&&(a.$?a:new CKEDITOR.dom.element(a))},CKEDITOR.dom.element.prototype=new CKEDITOR.dom.node,CKEDITOR.dom.element.createFromHtml=function(a,b){var c=new CKEDITOR.dom.element("div",b);return c.setHtml(a),c.getFirst().remove()},CKEDITOR.dom.element.setMarker=function(a,b,c,d){var e=b.getCustomData("list_marker_id")||b.setCustomData("list_marker_id",CKEDITOR.tools.getNextNumber()).getCustomData("list_marker_id"),f=b.getCustomData("list_marker_names")||b.setCustomData("list_marker_names",{}).getCustomData("list_marker_names");return a[e]=b,f[c]=1,b.setCustomData(c,d)},CKEDITOR.dom.element.clearAllMarkers=function(a){for(var b in a)CKEDITOR.dom.element.clearMarkers(a,a[b],
21)},CKEDITOR.dom.element.clearMarkers=function(a,b,c){var f,d=b.getCustomData("list_marker_names"),e=b.getCustomData("list_marker_id");for(f in d)b.removeCustomData(f);b.removeCustomData("list_marker_names"),c&&(b.removeCustomData("list_marker_id"),delete a[e])},function(){function a(a,b){return-1<(" "+a+" ").replace(f," ").indexOf(" "+b+" ")}function b(a){var b=!0;return a.$.id||(a.$.id="cke_tmp_"+CKEDITOR.tools.getNextNumber(),b=!1),function(){b||a.removeAttribute("id")}}function c(a,b){return"#"+a.$.id+" "+b.split(/,\s*/).join(", #"+a.$.id+" ")}function d(a){for(var b=0,c=0,d=g[a].length;c<d;c++)b+=parseInt(this.getComputedStyle(g[a][c])||0,10)||0;return b}var e=document.createElement("_").classList,e="undefined"!=typeof e&&null!==String(e.add).match(/\[Native code\]/gi),f=/[\n\t\r]/g;CKEDITOR.tools.extend(CKEDITOR.dom.element.prototype,{type:CKEDITOR.NODE_ELEMENT,addClass:e?function(a){return this.$.classList.add(a),this}:function(b){var c=this.$.className;return c&&(a(c,b)||(c+=" "+b)),this.$.className=c||b,this},removeClass:e?function(a){var b=this.$;return b.classList.remove(a),b.className||b.removeAttribute("class"),this}:function(b){var c=this.getAttribute("class");return c&&a(c,b)&&((c=c.replace(new RegExp("(?:^|\\s+)"+b+"(?=\\s|$)"),"").replace(/^\s+/,""))?this.setAttribute("class",c):this.removeAttribute("class")),this},hasClass:function(b){return a(this.$.className,b)},append:function(a,b){return"string"==typeof a&&(a=this.getDocument().createElement(a)),b?this.$.insertBefore(a.$,this.$.firstChild):this.$.appendChild(a.$),a},appendHtml:function(a){if(this.$.childNodes.length){var b=new CKEDITOR.dom.element("div",this.getDocument());b.setHtml(a),b.moveChildren(this)}else this.setHtml(a)},appendText:function(a){null!=this.$.text&&CKEDITOR.env.ie&&9>CKEDITOR.env.version?this.$.text+=a:this.append(new CKEDITOR.dom.text(a))},appendBogus:function(a){if(a||CKEDITOR.env.needsBrFiller){for(a=this.getLast();a&&a.type==CKEDITOR.NODE_TEXT&&!CKEDITOR.tools.rtrim(a.getText());)a=a.getPrevious();a&&a.is&&a.is("br")||(a=this.getDocument().createElement("br"),CKEDITOR.env.gecko&&a.setAttribute("type","_moz"),this.append(a))}},breakParent:function(a,b){var c=new CKEDITOR.dom.range(this.getDocument());c.setStartAfter(this),c.setEndAfter(a);var d=c.extractContents(!1,b||!1);c.insertNode(this.remove()),d.insertAfterNode(this)},contains:document.compareDocumentPosition?function(a){return!!(16&this.$.compareDocumentPosition(a.$))}:function(a){var b=this.$;return a.type!=CKEDITOR.NODE_ELEMENT?b.contains(a.getParent().$):b!=a.$&&b.contains(a.$)},focus:function(){function a(){try{this.$.focus()}catch(a){}}return function(b){b?CKEDITOR.tools.setTimeout(a,100,this):a.call(this)}}(),getHtml:function(){var a=this.$.innerHTML;return CKEDITOR.env.ie?a.replace(/<\?[^>]*>/g,""):a},getOuterHtml:function(){if(this.$.outerHTML)return this.$.outerHTML.replace(/<\?[^>]*>/,"");var a=this.$.ownerDocument.createElement("div");return a.appendChild(this.$.cloneNode(!0)),a.innerHTML},getClientRect:function(){var a=CKEDITOR.tools.extend({},this.$.getBoundingClientRect());return!a.width&&(a.width=a.right-a.left),!a.height&&(a.height=a.bottom-a.top),a},setHtml:CKEDITOR.env.ie&&9>CKEDITOR.env.version?function(a){try{var b=this.$;if(this.getParent())return b.innerHTML=a;var c=this.getDocument()._getHtml5ShivFrag();return c.appendChild(b),b.innerHTML=a,c.removeChild(b),a}catch(c){for(this.$.innerHTML="",b=new CKEDITOR.dom.element("body",this.getDocument()),b.$.innerHTML=a,b=b.getChildren();b.count();)this.append(b.getItem(0));return a}}:function(a){return this.$.innerHTML=a},setText:function(){var a=document.createElement("p");return a.innerHTML="x",a=a.textContent,function(b){this.$[a?"textContent":"innerText"]=b}}(),getAttribute:function(){var a=function(a){return this.$.getAttribute(a,2)};return CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)?function(a){switch(a){case"class":a="className";break;case"http-equiv":a="httpEquiv";break;case"name":return this.$.name;case"tabindex":return a=this.$.getAttribute(a,2),0!==a&&0===this.$.tabIndex&&(a=null),a;case"checked":return a=this.$.attributes.getNamedItem(a),(a.specified?a.nodeValue:this.$.checked)?"checked":null;case"hspace":case"value":return this.$[a];case"style":return this.$.style.cssText;case"contenteditable":case"contentEditable":return this.$.attributes.getNamedItem("contentEditable").specified?this.$.getAttribute("contentEditable"):null}return this.$.getAttribute(a,2)}:a}(),getAttributes:function(a){var d,b={},c=this.$.attributes;for(a=CKEDITOR.tools.isArray(a)?a:[],d=0;d<c.length;d++)-1===CKEDITOR.tools.indexOf(a,c[d].name)&&(b[c[d].name]=c[d].value);return b},getChildren:function(){return new CKEDITOR.dom.nodeList(this.$.childNodes)},getComputedStyle:document.defaultView&&document.defaultView.getComputedStyle?function(a){var b=this.getWindow().$.getComputedStyle(this.$,null);return b?b.getPropertyValue(a):""}:function(a){return this.$.currentStyle[CKEDITOR.tools.cssStyleToDomStyle(a)]},getDtd:function(){var a=CKEDITOR.dtd[this.getName()];return this.getDtd=function(){return a},a},getElementsByTag:CKEDITOR.dom.document.prototype.getElementsByTag,getTabIndex:function(){var a=this.$.tabIndex;return 0!==a||CKEDITOR.dtd.$tabIndex[this.getName()]||0===parseInt(this.getAttribute("tabindex"),10)?a:-1},getText:function(){return this.$.textContent||this.$.innerText||""},getWindow:function(){return this.getDocument().getWindow()},getId:function(){return this.$.id||null},getNameAtt:function(){return this.$.name||null},getName:function(){var a=this.$.nodeName.toLowerCase();if(CKEDITOR.env.ie&&8>=document.documentMode){var b=this.$.scopeName;"HTML"!=b&&(a=b.toLowerCase()+":"+a)}return this.getName=function(){return a},this.getName()},getValue:function(){return this.$.value},getFirst:function(a){var b=this.$.firstChild;return(b=b&&new CKEDITOR.dom.node(b))&&a&&!a(b)&&(b=b.getNext(a)),b},getLast:function(a){var b=this.$.lastChild;return(b=b&&new CKEDITOR.dom.node(b))&&a&&!a(b)&&(b=b.getPrevious(a)),b},getStyle:function(a){return this.$.style[CKEDITOR.tools.cssStyleToDomStyle(a)]},is:function(){var a=this.getName();if("object"==typeof arguments[0])return!!arguments[0][a];for(var b=0;b<arguments.length;b++)if(arguments[b]==a)return!0;return!1},isEditable:function(a){var b=this.getName();return!(this.isReadOnly()||"none"==this.getComputedStyle("display")||"hidden"==this.getComputedStyle("visibility")||CKEDITOR.dtd.$nonEditable[b]||CKEDITOR.dtd.$empty[b]||this.is("a")&&(this.data("cke-saved-name")||this.hasAttribute("name"))&&!this.getChildCount())&&(!1===a||(a=CKEDITOR.dtd[b]||CKEDITOR.dtd.span,!(!a||!a["#"])))},isIdentical:function(a){var b=this.clone(0,1);if(a=a.clone(0,1),b.removeAttributes(["_moz_dirty","data-cke-expando","data-cke-saved-href","data-cke-saved-name"]),a.removeAttributes(["_moz_dirty","data-cke-expando","data-cke-saved-href","data-cke-saved-name"]),b.$.isEqualNode)return b.$.style.cssText=CKEDITOR.tools.normalizeCssText(b.$.style.cssText),a.$.style.cssText=CKEDITOR.tools.normalizeCssText(a.$.style.cssText),b.$.isEqualNode(a.$);
2if(b=b.getOuterHtml(),a=a.getOuterHtml(),CKEDITOR.env.ie&&9>CKEDITOR.env.version&&this.is("a")){var c=this.getParent();c.type==CKEDITOR.NODE_ELEMENT&&(c=c.clone(),c.setHtml(b),b=c.getHtml(),c.setHtml(a),a=c.getHtml())}return b==a},isVisible:function(){var b,c,a=(this.$.offsetHeight||this.$.offsetWidth)&&"hidden"!=this.getComputedStyle("visibility");return a&&CKEDITOR.env.webkit&&(b=this.getWindow(),!b.equals(CKEDITOR.document.getWindow())&&(c=b.$.frameElement)&&(a=new CKEDITOR.dom.element(c).isVisible())),!!a},isEmptyInlineRemoveable:function(){if(!CKEDITOR.dtd.$removeEmpty[this.getName()])return!1;for(var a=this.getChildren(),b=0,c=a.count();b<c;b++){var d=a.getItem(b);if((d.type!=CKEDITOR.NODE_ELEMENT||!d.data("cke-bookmark"))&&(d.type==CKEDITOR.NODE_ELEMENT&&!d.isEmptyInlineRemoveable()||d.type==CKEDITOR.NODE_TEXT&&CKEDITOR.tools.trim(d.getText())))return!1}return!0},hasAttributes:CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)?function(){for(var a=this.$.attributes,b=0;b<a.length;b++){var c=a[b];switch(c.nodeName){case"class":if(this.getAttribute("class"))return!0;case"data-cke-expando":continue;default:if(c.specified)return!0}}return!1}:function(){var a=this.$.attributes,b=a.length,c={"data-cke-expando":1,_moz_dirty:1};return 0<b&&(2<b||!c[a[0].nodeName]||2==b&&!c[a[1].nodeName])},hasAttribute:function(){function a(a){var b=this.$.attributes.getNamedItem(a);if("input"==this.getName())switch(a){case"class":return 0<this.$.className.length;case"checked":return!!this.$.checked;case"value":return a=this.getAttribute("type"),"checkbox"==a||"radio"==a?"on"!=this.$.value:!!this.$.value}return!!b&&b.specified}return CKEDITOR.env.ie?8>CKEDITOR.env.version?function(b){return"name"==b?!!this.$.name:a.call(this,b)}:a:function(a){return!!this.$.attributes.getNamedItem(a)}}(),hide:function(){this.setStyle("display","none")},moveChildren:function(a,b){var c=this.$;if(a=a.$,c!=a){var d;if(b)for(;d=c.lastChild;)a.insertBefore(c.removeChild(d),a.firstChild);else for(;d=c.firstChild;)a.appendChild(c.removeChild(d))}},mergeSiblings:function(){function a(a,b,c){if(b&&b.type==CKEDITOR.NODE_ELEMENT){for(var d=[];b.data("cke-bookmark")||b.isEmptyInlineRemoveable();)if(d.push(b),b=c?b.getNext():b.getPrevious(),!b||b.type!=CKEDITOR.NODE_ELEMENT)return;if(a.isIdentical(b)){for(var e=c?a.getLast():a.getFirst();d.length;)d.shift().move(a,!c);b.moveChildren(a,!c),b.remove(),e&&e.type==CKEDITOR.NODE_ELEMENT&&e.mergeSiblings()}}}return function(b){(!1===b||CKEDITOR.dtd.$removeEmpty[this.getName()]||this.is("a"))&&(a(this,this.getNext(),!0),a(this,this.getPrevious()))}}(),show:function(){this.setStyles({display:"",visibility:""})},setAttribute:function(){var a=function(a,b){return this.$.setAttribute(a,b),this};return CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)?function(b,c){return"class"==b?this.$.className=c:"style"==b?this.$.style.cssText=c:"tabindex"==b?this.$.tabIndex=c:"checked"==b?this.$.checked=c:"contenteditable"==b?a.call(this,"contentEditable",c):a.apply(this,arguments),this}:CKEDITOR.env.ie8Compat&&CKEDITOR.env.secure?function(b,c){if("src"==b&&c.match(/^http:\/\//))try{a.apply(this,arguments)}catch(a){}else a.apply(this,arguments);return this}:a}(),setAttributes:function(a){for(var b in a)this.setAttribute(b,a[b]);return this},setValue:function(a){return this.$.value=a,this},removeAttribute:function(){var a=function(a){this.$.removeAttribute(a)};return CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)?function(a){"class"==a?a="className":"tabindex"==a?a="tabIndex":"contenteditable"==a&&(a="contentEditable"),this.$.removeAttribute(a)}:a}(),removeAttributes:function(a){if(CKEDITOR.tools.isArray(a))for(var b=0;b<a.length;b++)this.removeAttribute(a[b]);else for(b in a=a||this.getAttributes())a.hasOwnProperty(b)&&this.removeAttribute(b)},removeStyle:function(a){var b=this.$.style;if(b.removeProperty||"border"!=a&&"margin"!=a&&"padding"!=a)b.removeProperty?b.removeProperty(a):b.removeAttribute(CKEDITOR.tools.cssStyleToDomStyle(a)),this.$.style.cssText||this.removeAttribute("style");else{var d,c=["top","left","right","bottom"];"border"==a&&(d=["color","style","width"]);for(var b=[],e=0;e<c.length;e++)if(d)for(var f=0;f<d.length;f++)b.push([a,c[e],d[f]].join("-"));else b.push([a,c[e]].join("-"));for(a=0;a<b.length;a++)this.removeStyle(b[a])}},setStyle:function(a,b){return this.$.style[CKEDITOR.tools.cssStyleToDomStyle(a)]=b,this},setStyles:function(a){for(var b in a)this.setStyle(b,a[b]);return this},setOpacity:function(a){CKEDITOR.env.ie&&9>CKEDITOR.env.version?(a=Math.round(100*a),this.setStyle("filter",100<=a?"":"progid:DXImageTransform.Microsoft.Alpha(opacity="+a+")")):this.setStyle("opacity",a)},unselectable:function(){if(this.setStyles(CKEDITOR.tools.cssVendorPrefix("user-select","none")),CKEDITOR.env.ie){this.setAttribute("unselectable","on");for(var a,b=this.getElementsByTag("*"),c=0,d=b.count();c<d;c++)a=b.getItem(c),a.setAttribute("unselectable","on")}},getPositionedAncestor:function(){for(var a=this;"html"!=a.getName();){if("static"!=a.getComputedStyle("position"))return a;a=a.getParent()}return null},getDocumentPosition:function(a){var b=0,c=0,d=this.getDocument(),e=d.getBody(),f="BackCompat"==d.$.compatMode;if(document.documentElement.getBoundingClientRect){var g=this.$.getBoundingClientRect(),h=d.$.documentElement,i=h.clientTop||e.$.clientTop||0,j=h.clientLeft||e.$.clientLeft||0,k=!0;CKEDITOR.env.ie&&(k=d.getDocumentElement().contains(this),d=d.getBody().contains(this),k=f&&d||!f&&k),k&&(CKEDITOR.env.webkit||CKEDITOR.env.ie&&12<=CKEDITOR.env.version?(b=e.$.scrollLeft||h.scrollLeft,c=e.$.scrollTop||h.scrollTop):(c=f?e.$:h,b=c.scrollLeft,c=c.scrollTop),b=g.left+b-j,
2c=g.top+c-i)}else for(i=this,j=null;i&&"body"!=i.getName()&&"html"!=i.getName();){for(b+=i.$.offsetLeft-i.$.scrollLeft,c+=i.$.offsetTop-i.$.scrollTop,i.equals(this)||(b+=i.$.clientLeft||0,c+=i.$.clientTop||0);j&&!j.equals(i);)b-=j.$.scrollLeft,c-=j.$.scrollTop,j=j.getParent();j=i,i=(g=i.$.offsetParent)?new CKEDITOR.dom.element(g):null}return a&&(g=this.getWindow(),i=a.getWindow(),!g.equals(i)&&g.$.frameElement&&(a=new CKEDITOR.dom.element(g.$.frameElement).getDocumentPosition(a),b+=a.x,c+=a.y)),document.documentElement.getBoundingClientRect||!CKEDITOR.env.gecko||f||(b+=this.$.clientLeft?1:0,c+=this.$.clientTop?1:0),{x:b,y:c}},scrollIntoView:function(a){var b=this.getParent();if(b)do if((b.$.clientWidth&&b.$.clientWidth<b.$.scrollWidth||b.$.clientHeight&&b.$.clientHeight<b.$.scrollHeight)&&!b.is("body")&&this.scrollIntoParent(b,a,1),b.is("html")){var c=b.getWindow();try{var d=c.$.frameElement;d&&(b=new CKEDITOR.dom.element(d))}catch(a){}}while(b=b.getParent())},scrollIntoParent:function(a,b,c){function h(b,c){/body|html/.test(a.getName())?a.getWindow().$.scrollBy(b,c):(a.$.scrollLeft+=b,a.$.scrollTop+=c)}function i(a,b){var c={x:0,y:0};if(!a.is(k?"body":"html")){var d=a.$.getBoundingClientRect();c.x=d.left,c.y=d.top}return d=a.getWindow(),d.equals(b)||(d=i(CKEDITOR.dom.element.get(d.$.frameElement),b),c.x+=d.x,c.y+=d.y),c}function j(a,b){return parseInt(a.getComputedStyle("margin-"+b)||0,10)||0}var d,e,f,g;!a&&(a=this.getWindow()),f=a.getDocument();var k="BackCompat"==f.$.compatMode;a instanceof CKEDITOR.dom.window&&(a=k?f.getBody():f.getDocumentElement()),f=a.getWindow(),e=i(this,f);var l=i(a,f),m=this.$.offsetHeight;d=this.$.offsetWidth;var n=a.$.clientHeight,o=a.$.clientWidth;f=e.x-j(this,"left")-l.x||0,g=e.y-j(this,"top")-l.y||0,d=e.x+d+j(this,"right")-(l.x+o)||0,e=e.y+m+j(this,"bottom")-(l.y+n)||0,(0>g||0<e)&&h(0,!0===b?g:!1===b?e:0>g?g:e),c&&(0>f||0<d)&&h(0>f?f:d,0)},setState:function(a,b,c){switch(b=b||"cke",a){case CKEDITOR.TRISTATE_ON:this.addClass(b+"_on"),this.removeClass(b+"_off"),this.removeClass(b+"_disabled"),c&&this.setAttribute("aria-pressed",!0),c&&this.removeAttribute("aria-disabled");break;case CKEDITOR.TRISTATE_DISABLED:this.addClass(b+"_disabled"),this.removeClass(b+"_off"),this.removeClass(b+"_on"),c&&this.setAttribute("aria-disabled",!0),c&&this.removeAttribute("aria-pressed");break;default:this.addClass(b+"_off"),this.removeClass(b+"_on"),this.removeClass(b+"_disabled"),c&&this.removeAttribute("aria-pressed"),c&&this.removeAttribute("aria-disabled")}},getFrameDocument:function(){var a=this.$;try{a.contentWindow.document}catch(b){a.src=a.src}return a&&new CKEDITOR.dom.document(a.contentWindow.document)},copyAttributes:function(a,b){var c=this.$.attributes;b=b||{};for(var d=0;d<c.length;d++){var g,e=c[d],f=e.nodeName.toLowerCase();f in b||("checked"==f&&(g=this.getAttribute(f))?a.setAttribute(f,g):CKEDITOR.env.ie&&!this.hasAttribute(f)||(g=this.getAttribute(f),null===g&&(g=e.nodeValue),a.setAttribute(f,g)))}""!==this.$.style.cssText&&(a.$.style.cssText=this.$.style.cssText)},renameNode:function(a){if(this.getName()!=a){var b=this.getDocument();a=new CKEDITOR.dom.element(a,b),this.copyAttributes(a),this.moveChildren(a),this.getParent(!0)&&this.$.parentNode.replaceChild(a.$,this.$),a.$["data-cke-expando"]=this.$["data-cke-expando"],this.$=a.$,delete this.getName}},getChild:function(){function a(a,b){var c=a.childNodes;if(0<=b&&b<c.length)return c[b]}return function(b){var c=this.$;if(b.slice)for(b=b.slice();0<b.length&&c;)c=a(c,b.shift());else c=a(c,b);return c?new CKEDITOR.dom.node(c):null}}(),getChildCount:function(){return this.$.childNodes.length},disableContextMenu:function(){function a(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasClass("cke_enable_context_menu")}this.on("contextmenu",function(b){b.data.getTarget().getAscendant(a,!0)||b.data.preventDefault()})},getDirection:function(a){return a?this.getComputedStyle("direction")||this.getDirection()||this.getParent()&&this.getParent().getDirection(1)||this.getDocument().$.dir||"ltr":this.getStyle("direction")||this.getAttribute("dir")},data:function(a,b){return a="data-"+a,void 0===b?this.getAttribute(a):(!1===b?this.removeAttribute(a):this.setAttribute(a,b),null)},getEditor:function(){var b,c,a=CKEDITOR.instances;for(b in a)if(c=a[b],c.element.equals(this)&&c.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO)return c;return null},find:function(a){var d=b(this);return a=new CKEDITOR.dom.nodeList(this.$.querySelectorAll(c(this,a))),d(),a},findOne:function(a){var d=b(this);return a=this.$.querySelector(c(this,a)),d(),a?new CKEDITOR.dom.element(a):null},forEach:function(a,b,c){if(!(c||b&&this.type!=b))var d=a(this);if(!1!==d){c=this.getChildren();for(var e=0;e<c.count();e++)d=c.getItem(e),d.type==CKEDITOR.NODE_ELEMENT?d.forEach(a,b):b&&d.type!=b||a(d)}}});var g={width:["border-left-width","border-right-width","padding-left","padding-right"],height:["border-top-width","border-bottom-width","padding-top","padding-bottom"]};CKEDITOR.dom.element.prototype.setSize=function(a,b,c){"number"==typeof b&&(!c||CKEDITOR.env.ie&&CKEDITOR.env.quirks||(b-=d.call(this,a)),this.setStyle(a,b+"px"))},CKEDITOR.dom.element.prototype.getSize=function(a,b){var c=Math.max(this.$["offset"+CKEDITOR.tools.capitalize(a)],this.$["client"+CKEDITOR.tools.capitalize(a)])||0;return b&&(c-=d.call(this,a)),c}}(),CKEDITOR.dom.documentFragment=function(a){a=a||CKEDITOR.document,this.$=a.type==CKEDITOR.NODE_DOCUMENT?a.$.createDocumentFragment():a},CKEDITOR.tools.extend(CKEDITOR.dom.documentFragment.prototype,CKEDITOR.dom.element.prototype,{type:CKEDITOR.NODE_DOCUMENT_FRAGMENT,insertAfterNode:function(a){a=a.$,a.parentNode.insertBefore(this.$,a.nextSibling)},getHtml:function(){var a=new CKEDITOR.dom.element("div");return this.clone(1,1).appendTo(a),a.getHtml().replace(/\s*data-cke-expando=".*?"/g,"")}},!0,{append:1,appendBogus:1,clone:1,getFirst:1,getHtml:1,getLast:1,getParent:1,getNext:1,getPrevious:1,appendTo:1,moveChildren:1,insertBefore:1,insertAfterNode:1,replace:1,trim:1,type:1,ltrim:1,rtrim:1,getDocument:1,getChildCount:1,getChild:1,getChildren:1}),function(){function a(a,b){var c=this.range;if(this._.end)return null;if(!this._.start){if(this._.start=1,c.collapsed)return this.end(),null;c.optimize()}var d,e=c.startContainer;d=c.endContainer;var h,f=c.startOffset,g=c.endOffset,i=this.guard,j=this.type,k=a?"getPreviousSourceNode":"getNextSourceNode";if(!a&&!this._.guardLTR){var l=d.type==CKEDITOR.NODE_ELEMENT?d:d.getParent(),m=d.type==CKEDITOR.NODE_ELEMENT?d.getChild(g):d.getNext();this._.guardLTR=function(a,b){return!(b&&l.equals(a)||m&&a.equals(m)||a.type==CKEDITOR.NODE_ELEMENT&&b&&a.equals(c.root))}}if(a&&!this._.guardRTL){var n=e.type==CKEDITOR.NODE_ELEMENT?e:e.getParent(),o=e.type==CKEDITOR.NODE_ELEMENT?f?e.getChild(f-1):null:e.getPrevious();this._.guardRTL=function(a,b){return!(b&&n.equals(a)||o&&a.equals(o)||a.type==CKEDITOR.NODE_ELEMENT&&b&&a.equals(c.root))}}var p=a?this._.guardRTL:this._.guardLTR;for(h=i?function(a,b){return!1!==p(a,b)&&i(a,b)}:p,this.current?d=this.current[k](!1,j,h):(a?d.type==CKEDITOR.NODE_ELEMENT&&(d=0<g?d.getChild(g-1):!1===h(d,!0)?null:d.getPreviousSourceNode(!0,j,h)):(d=e,d.type==CKEDITOR.NODE_ELEMENT&&((d=d.getChild(f))||(d=!1===h(e,!0)?null:e.getNextSourceNode(!0,j,h)))),d&&!1===h(d)&&(d=null));d&&!this._.end;){if(this.current=d,this.evaluator&&!1===this.evaluator(d)){if(b&&this.evaluator)return!1}else if(!b)return d;d=d[k](!1,j,h)}return this.end(),this.current=null}function b(b){for(var c,d=null;c=a.call(this,b);)d=c;return d}CKEDITOR.dom.walker=CKEDITOR.tools.createClass({$:function(a){this.range=a,this._={}},proto:{end:function(){this._.end=1},next:function(){return a.call(this)},previous:function(){return a.call(this,1)},checkForward:function(){return!1!==a.call(this,0,1)},checkBackward:function(){return!1!==a.call(this,1,1)},lastForward:function(){return b.call(this)},lastBackward:function(){return b.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},d={absolute:1,fixed:1};CKEDITOR.dom.element.prototype.isBlockBoundary=function(a){return!("none"!=this.getComputedStyle("float")||this.getComputedStyle("position")in d||!c[this.getComputedStyle("display")])||!!(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&&"span"==a.getName()&&a.data("cke-bookmark")}return function(d){var e,f;return e=d&&d.type!=CKEDITOR.NODE_ELEMENT&&(f=d.getParent())&&c(f),e=a?e:e||c(d),!!(b^e)}}
2,CKEDITOR.dom.walker.whitespaces=function(a){return function(b){var c;return b&&b.type==CKEDITOR.NODE_TEXT&&(c=!CKEDITOR.tools.trim(b.getText())||CKEDITOR.env.webkit&&b.getText()==CKEDITOR.dom.selection.FILLING_CHAR_SEQUENCE),!!(a^c)}},CKEDITOR.dom.walker.invisible=function(a){var b=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.env.webkit?1:0;return function(d){return b(d)?d=1:(d.type==CKEDITOR.NODE_TEXT&&(d=d.getParent()),d=d.$.offsetWidth<=c),!!(a^d)}},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!f(a)&&!g(a)}return function(c){var d=CKEDITOR.env.needsBrFiller?c.is&&c.is("br"):c.getText&&e.test(c.getText());return d&&(d=c.getParent(),c=c.getNext(b),d=d.isBlockBoundary()&&(!c||c.type==CKEDITOR.NODE_ELEMENT&&c.isBlockBoundary())),!!(a^d)}},CKEDITOR.dom.walker.temp=function(a){return function(b){return b.type!=CKEDITOR.NODE_ELEMENT&&(b=b.getParent()),b=b&&b.hasAttribute("data-cke-temp"),!!(a^b)}};var e=/^[\t\r\n ]*(?: |\xa0)$/,f=CKEDITOR.dom.walker.whitespaces(),g=CKEDITOR.dom.walker.bookmark(),h=CKEDITOR.dom.walker.temp(),i=function(a){return g(a)||f(a)||a.type==CKEDITOR.NODE_ELEMENT&&a.is(CKEDITOR.dtd.$inline)&&!a.is(CKEDITOR.dtd.$empty)};CKEDITOR.dom.walker.ignored=function(a){return function(b){return b=f(b)||g(b)||h(b),!!(a^b)}};var j=CKEDITOR.dom.walker.ignored();CKEDITOR.dom.walker.empty=function(a){return function(b){for(var c=0,d=b.getChildCount();c<d;++c)if(!j(b.getChild(c)))return!!a;return!a}};var k=CKEDITOR.dom.walker.empty(),l=CKEDITOR.dom.walker.validEmptyBlockContainers=CKEDITOR.tools.extend(function(a){var c,b={};for(c in a)CKEDITOR.dtd[c]["#"]&&(b[c]=1);return b}(CKEDITOR.dtd.$block),{caption:1,td:1,th:1});CKEDITOR.dom.walker.editable=function(a){return function(b){return b=!j(b)&&!!(b.type==CKEDITOR.NODE_TEXT||b.type==CKEDITOR.NODE_ELEMENT&&(b.is(CKEDITOR.dtd.$inline)||b.is("hr")||"false"==b.getAttribute("contenteditable")||!CKEDITOR.env.needsBrFiller&&b.is(l)&&k(b))),!!(a^b)}},CKEDITOR.dom.element.prototype.getBogus=function(){var a=this;do a=a.getPreviousSourceNode();while(i(a));return!(!a||!(CKEDITOR.env.needsBrFiller?a.is&&a.is("br"):a.getText&&e.test(a.getText())))&&a}}(),CKEDITOR.dom.range=function(a){this.endOffset=this.endContainer=this.startOffset=this.startContainer=null,this.collapsed=!0;var b=a instanceof CKEDITOR.dom.document;this.document=b?a:a.getDocument(),this.root=b?a.getBody():a},function(){function a(a){a.collapsed=a.startContainer&&a.endContainer&&a.startContainer.equals(a.endContainer)&&a.startOffset==a.endOffset}function b(a,b,c,d,e){function f(a,b,c,d){var f=c?a.getPrevious():a.getNext();return d&&i?f:(k||d?b.append(a.clone(!0,e),c):(a.remove(),j&&b.append(a)),f)}function g(){var a,b,c,d=Math.min(v.length,w.length);for(a=0;a<d;a++)if(b=v[a],c=w[a],!b.equals(c))return a;return a-1}function h(){var b=x-1,c=r&&s&&!l.equals(m);b<y-1||b<z-1||c?(c?a.moveToPosition(m,CKEDITOR.POSITION_BEFORE_START):z==b+1&&q?a.moveToPosition(w[b],CKEDITOR.POSITION_BEFORE_END):a.moveToPosition(w[b+1],CKEDITOR.POSITION_BEFORE_START),d&&(b=v[b+1])&&b.type==CKEDITOR.NODE_ELEMENT&&(c=CKEDITOR.dom.element.createFromHtml('<span data-cke-bookmark="1" style="display:none"> </span>',a.document),c.insertAfter(b),b.mergeSiblings(!1),a.moveToBookmark({startNode:c}))):a.collapse(!0)}a.optimizeBookmark();var i=0===b,j=1==b,k=2==b;b=k||j;var p,q,r,s,t,u,l=a.startContainer,m=a.endContainer,n=a.startOffset,o=a.endOffset;if(k&&m.type==CKEDITOR.NODE_TEXT&&l.equals(m))l=a.document.createText(l.substring(n,o)),c.append(l);else{m.type==CKEDITOR.NODE_TEXT?k?u=!0:m=m.split(o):0<m.getChildCount()?o>=m.getChildCount()?(m=m.getChild(o-1),q=!0):m=m.getChild(o):s=q=!0,l.type==CKEDITOR.NODE_TEXT?k?t=!0:l.split(n):0<l.getChildCount()?0===n?(l=l.getChild(n),p=!0):l=l.getChild(n-1):r=p=!0;for(var B,C,D,v=l.getParents(),w=m.getParents(),x=g(),y=v.length-1,z=w.length-1,A=c,E=-1,F=x;F<=y;F++){for(C=v[F],D=C.getNext(),F!=y||C.equals(w[F])&&y<z?b&&(B=A.append(C.clone(0,e))):p?f(C,A,!1,r):t&&A.append(a.document.createText(C.substring(n)));D;){if(D.equals(w[F])){E=F;break}D=f(D,A)}A=B}for(A=c,F=x;F<=z;
2F++)if(c=w[F],D=c.getPrevious(),c.equals(v[F]))b&&(A=A.getChild(0));else{if(F!=z||c.equals(v[F])&&z<y?b&&(B=A.append(c.clone(0,e))):q?f(c,A,!1,s):u&&A.append(a.document.createText(c.substring(0,o))),F>E)for(;D;)D=f(D,A,!0);A=B}k||h()}}function c(){var a=!1,b=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.dom.walker.bookmark(!0),d=CKEDITOR.dom.walker.bogus();return function(e){return!(!c(e)&&!b(e))||(d(e)&&!a?a=!0:!(e.type==CKEDITOR.NODE_TEXT&&(e.hasAscendant("pre")||CKEDITOR.tools.trim(e.getText()).length)||e.type==CKEDITOR.NODE_ELEMENT&&!e.is(f)))}}function d(a){var b=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.dom.walker.bookmark(1);return function(d){return!(!c(d)&&!b(d))||(!a&&g(d)||d.type==CKEDITOR.NODE_ELEMENT&&d.is(CKEDITOR.dtd.$removeEmpty))}}function e(a){return function(){var b;return this[a?"getPreviousNode":"getNextNode"](function(a){return!b&&j(a)&&(b=a),i(a)&&!(g(a)&&a.equals(b))})}}var f={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},g=CKEDITOR.dom.walker.bogus(),h=/^[\t\r\n ]*(?: |\xa0)$/,i=CKEDITOR.dom.walker.editable(),j=CKEDITOR.dom.walker.ignored(!0);CKEDITOR.dom.range.prototype={clone:function(){var a=new CKEDITOR.dom.range(this.root);return a._setStartContainer(this.startContainer),a.startOffset=this.startOffset,a._setEndContainer(this.endContainer),a.endOffset=this.endOffset,a.collapsed=this.collapsed,a},collapse:function(a){a?(this._setEndContainer(this.startContainer),this.endOffset=this.startOffset):(this._setStartContainer(this.endContainer),this.startOffset=this.endOffset),this.collapsed=!0},cloneContents:function(a){var c=new CKEDITOR.dom.documentFragment(this.document);return this.collapsed||b(this,2,c,!1,"undefined"==typeof a||a),c},deleteContents:function(a){this.collapsed||b(this,0,null,a)},extractContents:function(a,c){var d=new CKEDITOR.dom.documentFragment(this.document);return this.collapsed||b(this,1,d,a,"undefined"==typeof c||c),d},createBookmark:function(a){var b,c,d,e,f=this.collapsed;return b=this.document.createElement("span"),b.data("cke-bookmark",1),b.setStyle("display","none"),b.setHtml(" "),a&&(d="cke_bm_"+CKEDITOR.tools.getNextNumber(),b.setAttribute("id",d+(f?"C":"S"))),f||(c=b.clone(),c.setHtml(" "),a&&c.setAttribute("id",d+"E"),e=this.clone(),e.collapse(),e.insertNode(c)),e=this.clone(),e.collapse(!0),e.insertNode(b),c?(this.setStartAfter(b),this.setEndBefore(c)):this.moveToPosition(b,CKEDITOR.POSITION_AFTER_END),{startNode:a?d+(f?"C":"S"):b,endNode:a?d+"E":c,seri
2alizable:a,collapsed:f}},createBookmark2:function(){function a(a){var e,b=a.container,d=a.offset;e=b;var f=d;if(e=e.type!=CKEDITOR.NODE_ELEMENT||0===f||f==e.getChildCount()?0:e.getChild(f-1).type==CKEDITOR.NODE_TEXT&&e.getChild(f).type==CKEDITOR.NODE_TEXT,e&&(b=b.getChild(d-1),d=b.getLength()),b.type==CKEDITOR.NODE_ELEMENT&&0<d){a:{for(e=b;d--;)if(f=e.getChild(d).getIndex(!0),0<=f){d=f;break a}d=-1}d+=1}if(b.type==CKEDITOR.NODE_TEXT){for(e=b,f=0;(e=e.getPrevious())&&e.type==CKEDITOR.NODE_TEXT;)f+=e.getText().replace(CKEDITOR.dom.selection.FILLING_CHAR_SEQUENCE,"").length;e=f,b.getText()?d+=e:(f=b.getPrevious(c),e?(d=e,b=f?f.getNext():b.getParent().getFirst()):(b=b.getParent(),d=f?f.getIndex(!0)+1:0))}a.container=b,a.offset=d}function b(a,b){var c=b.getCustomData("cke-fillingChar");if(c){var d=a.container;c.equals(d)&&(a.offset-=CKEDITOR.dom.selection.FILLING_CHAR_SEQUENCE.length,0>=a.offset&&(a.offset=d.getIndex(), 3a.container=d.getParent()))}}var c=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_TEXT,!0);return function(c){var d=this.collapsed,e={container:this.startContainer,offset:this.startOffset},f={container:this.endContainer,offset:this.endOffset};return c&&(a(e),b(e,this.root),d||(a(f),b(f,this.root))),{start:e.container.getAddress(c),end:d?null:f.container.getAddress(c),startOffset:e.offset,endOffset:f.offset,normalized:c,collapsed:d,is2:!0}}}(),moveToBookmark:function(a){if(a.is2){var b=this.document.getByAddress(a.start,a.normalized),c=a.startOffset,d=a.end&&this.document.getByAddress(a.end,a.normalized);a=a.endOffset,this.setStart(b,c),d?this.setEnd(d,a):this.collapse(!0)}else b=(c=a.serializable)?this.document.getById(a.startNode):a.startNode,a=c?this.document.getById(a.endNode):a.endNode,this.setStartBefore(b),b.remove(),a?(this.setEndBefore(a),a.remove()):this.collapse(!0)},getBoundaryNodes:function(){var e,a=this.startContainer,b=this.endContainer,c=this.startOffset,d=this.endOffset;if(a.type==CKEDITOR.NODE_ELEMENT)if(e=a.getChildCount(),e>c)a=a.getChild(c);else if(1>e)a=a.getPreviousSourceNode();else{for(a=a.$;a.lastChild;)a=a.lastChild;a=new CKEDITOR.dom.node(a),a=a.getNextSourceNode()||a}if(b.type==CKEDITOR.NODE_ELEMENT)if(e=b.getChildCount(),e>d)b=b.getChild(d).getPreviousSourceNode(!0);else if(1>e)b=b.getPreviousSourceNode();else{for(b=b.$;b.lastChild;)b=b.lastChild;b=new CKEDITOR.dom.node(b)}return a.getPosition(b)&CKEDITOR.POSITION_FOLLOWING&&(a=b),{startNode:a,endNode:b}},getCommonAncestor:function(a,b){var c=this.startContainer,d=this.endContainer,c=c.equals(d)?a&&c.type==CKEDITOR.NODE_ELEMENT&&this.startOffset==this.endOffset-1?c.getChild(this.startOffset):c:c.getCommonAncestor(d);return b&&!c.is?c.getParent():c},optimize:function(){var a=this.startContainer,b=this.startOffset;a.type!=CKEDITOR.NODE_ELEMENT&&(b?b>=a.getLength()&&this.setStartAfter(a):this.setStartBefore(a)),a=this.endContainer,b=this.endOffset,a.type!=CKEDITOR.NODE_ELEMENT&&(b?b>=a.getLength()&&this.setEndAfter(a):this.setEndBefore(a))},optimizeBookmark:function(){var a=this.startContainer,b=this.endContainer;a.is&&a.is("span")&&a.data("cke-bookmark")&&this.setStartAt(a,CKEDITOR.POSITION_BEFORE_START),b&&b.is&&b.is("span")&&b.data("cke-bookmark")&&this.setEndAt(b,CKEDITOR.POSITION_AFTER_END)},trim:function(a,b){var c=this.startContainer,d=this.startOffset,e=this.collapsed;if((!a||e)&&c&&c.type==CKEDITOR.NODE_TEXT){if(d)if(d>=c.getLength())d=c.getIndex()+1,c=c.getParent();else{var f=c.split(d),d=c.getIndex()+1,c=c.getParent();this.startContainer.equals(this.endContainer)?this.setEnd(f,this.endOffset-this.startOffset):c.equals(this.endContainer)&&(this.endOffset+=1)}else d=c.getIndex(),c=c.getParent();if(this.setStart(c,d),e)return void this.collapse(!0)}c=this.endContainer,d=this.endOffset,b||e||!c||c.type!=CKEDITOR.NODE_TEXT||(d?(d>=c.getLength()||c.split(d),d=c.getIndex()+1):d=c.getIndex(),c=c.getParent(),this.setEnd(c,d))},enlarge:function(a,b){function c(a){return a&&a.type==CKEDITOR.NODE_ELEMENT&&a.hasAttribute("contenteditable")?null:a}var d=new RegExp(/[^\s\ufeff]/);switch(a){case CKEDITOR.ENLARGE_INLINE:var e=1;case CKEDITOR.ENLARGE_ELEMENT:var f=function(a,b){var c=new CKEDITOR.dom.range(h);c.setStart(a,b),c.setEndAt(h,CKEDITOR.POSITION_BEFORE_END);var e,c=new CKEDITOR.dom.walker(c);for(c.guard=function(a){return!(a.type==CKEDITOR.NODE_ELEMENT&&a.isBlockBoundary())};e=c.next();){if(e.type!=CKEDITOR.NODE_TEXT)return!1;if(p=e!=a?e.getText():e.substring(b),d.test(p))return!1}return!0};if(this.collapsed)break;var i,j,k,l,m,o,p,g=this.getCommonAncestor(),h=this.root,n=!1;o=this.startContainer;var q=this.startOffset;for(o.type==CKEDITOR.NODE_TEXT?(q&&(o=!CKEDITOR.tools.trim(o.substring(0,q)).length&&o,n=!!o),o&&((l=o.getPrevious())||(k=o.getParent()))):(q&&(l=o.getChild(q-1)||o.getLast()),l||(k=o)),k=c(k);k||l;){if(k&&!l){if(!m&&k.equals(g)&&(m=!0),e?k.isBlockBoundary():!h.contains(k))break;n&&"inline"==k.getComputedStyle("display")||(n=!1,m?i=k:this.setStartBefore(k)),l=k.getPrevious()}for(;l;)if(o=!1,l.type==CKEDITOR.NODE_COMMENT)l=l.getPrevious();else{if(l.type==CKEDITOR.NODE_TEXT)p=l.getText(),d.test(p)&&(l=null),o=/[\s\ufeff]$/.test(p);else if((l.$.offsetWidth>(CKEDITOR.env.webkit?1:0)||b&&l.is("br"))&&!l.data("cke-bookmark"))if(n&&CKEDITOR.dtd.$removeEmpty[l.getName()]){if
3(p=l.getText(),d.test(p))l=null;else for(var s,q=l.$.getElementsByTagName("*"),r=0;s=q[r++];)if(!CKEDITOR.dtd.$removeEmpty[s.nodeName.toLowerCase()]){l=null;break}l&&(o=!!p.length)}else l=null;if(o&&(n?m?i=k:k&&this.setStartBefore(k):n=!0),l){if(o=l.getPrevious(),!k&&!o){k=l,l=null;break}l=o}else k=null}k&&(k=c(k.getParent()))}for(o=this.endContainer,q=this.endOffset,k=l=null,m=n=!1,o.type==CKEDITOR.NODE_TEXT?CKEDITOR.tools.trim(o.substring(q)).length?n=!0:(n=!o.getLength(),q==o.getLength()?(l=o.getNext())||(k=o.getParent()):f(o,q)&&(k=o.getParent())):(l=o.getChild(q))||(k=o);k||l;){if(k&&!l){if(!m&&k.equals(g)&&(m=!0),e?k.isBlockBoundary():!h.contains(k))break;n&&"inline"==k.getComputedStyle("display")||(n=!1,m?j=k:k&&this.setEndAfter(k)),l=k.getNext()}for(;l;){if(o=!1,l.type==CKEDITOR.NODE_TEXT)p=l.getText(),f(l,0)||(l=null),o=/^[\s\ufeff]/.test(p);else if(l.type==CKEDITOR.NODE_ELEMENT){if((0<l.$.offsetWidth||b&&l.is("br"))&&!l.data("cke-bookmark"))if(n&&CKEDITOR.dtd.$removeEmpty[l.getName()]){if(p=l.getText(),d.test(p))l=null;else for(q=l.$.getElementsByTagName("*"),r=0;s=q[r++];)if(!CKEDITOR.dtd.$removeEmpty[s.nodeName.toLowerCase()]){l=null;break}l&&(o=!!p.length)}else l=null}else o=1;if(o&&n&&(m?j=k:this.setEndAfter(k)),l){if(o=l.getNext(),!k&&!o){k=l,l=null;break}l=o}else k=null}k&&(k=c(k.getParent()))}i&&j&&(g=i.contains(j)?j:i,this.setStartBefore(g),this.setEndAfter(g));break;case CKEDITOR.ENLARGE_BLOCK_CONTENTS:case CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS:k=new CKEDITOR.dom.range(this.root),h=this.root,k.setStartAt(h,CKEDITOR.POSITION_AFTER_START),k.setEnd(this.startContainer,this.startOffset),k=new CKEDITOR.dom.walker(k);var t,u,v=CKEDITOR.dom.walker.blockBoundary(a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS?{br:1}:null),w=null,x=function(a){if(a.type==CKEDITOR.NODE_ELEMENT&&"false"==a.getAttribute("contenteditable"))if(w){if(w.equals(a))return void(w=null)}else w=a;else if(w)return;var b=v(a);return b||(t=a),b},e=function(a){var b=x(a);return!b&&a.is&&a.is("br")&&(u=a),b};if(k.guard=x,k=k.lastBackward(),t=t||h,this.setStartAt(t,!t.is("br")&&(!k&&this.checkStartOfBlock()||k&&t.contains(k))?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_AFTER_END),a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS){k=this.clone(),k=new CKEDITOR.dom.walker(k);var y=CKEDITOR.dom.walker.whitespaces(),z=CKEDITOR.dom.walker.bookmark();if(k.evaluator=function(a){return!y(a)&&!z(a)},(k=k.previous())&&k.type==CKEDITOR.NODE_ELEMENT&&k.is("br"))break}k=this.clone(),k.collapse(),k.setEndAt(h,CKEDITOR.POSITION_BEFORE_END),k=new CKEDITOR.dom.walker(k),k.guard=a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS?e:x,t=w=u=null,k=k.lastForward(),t=t||h,this.setEndAt(t,!k&&this.checkEndOfBlock()||k&&t.contains(k)?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_BEFORE_START),u&&this.setEndAfter(u)}},shrink:function(a,b,c){if(!this.collapsed){a=a||CKEDITOR.SHRINK_TEXT;var d=this.clone(),e=this.startContainer,f=this.endContainer,g=this.startOffset,h=this.endOffset,i=1,j=1;e&&e.type==CKEDITOR.NODE_TEXT&&(g?g>=e.getLength()?d.setStartAfter(e):(d.setStartBefore(e),i=0):d.setStartBefore(e)),f&&f.type==CKEDITOR.NODE_TEXT&&(h?h>=f.getLength()?d.setEndAfter(f):(d.setEndAfter(f),j=0):d.setEndBefore(f));var d=new CKEDITOR.dom.walker(d),k=CKEDITOR.dom.walker.bookmark();d.evaluator=function(b){return b.type==(a==CKEDITOR.SHRINK_ELEMENT?CKEDITOR.NODE_ELEMENT:CKEDITOR.NODE_TEXT)};var l;return d.guard=function(b,d){return!!k(b)||!(a==CKEDITOR.SHRINK_ELEMENT&&b.type==CKEDITOR.NODE_TEXT||d&&b.equals(l)||!1===c&&b.type==CKEDITOR.NODE_ELEMENT&&b.isBlockBoundary()||b.type==CKEDITOR.NODE_ELEMENT&&b.hasAttribute("contenteditable"))&&(d||b.type!=CKEDITOR.NODE_ELEMENT||(l=b),!0)},i&&(e=d[a==CKEDITOR.SHRINK_ELEMENT?"lastForward":"next"]())&&this.setStartAt(e,b?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_START),j&&(d.reset(),(d=d[a==CKEDITOR.SHRINK_ELEMENT?"lastBackward":"previous"]())&&this.setEndAt(d,b?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_AFTER_END)),!(!i&&!j)}},insertNode:function(a){this.optimizeBookmark(),this.trim(!1,!0);var b=this.startContainer,c=b.getChild(this.startOffset);c?a.insertBefore(c):b.append(a),a.getParent()&&a.getParent().equals(this.endContainer)&&this.endOffset++,this.setStartBefore(a)},moveToPosition:function(a,b){this.setStartAt(a,b),this.collapse(!0)},moveToRange:function(a){this.setStart(a.startContainer,a.startOffset),this.setEnd(a.endContainer,a.endOffset)},selectNodeContents:function(a){this.setStart(a,0),this.setEnd(a,a.type==CKEDITOR.NODE_TEXT?a.getLength():a.getChildCount())},setStart:function(b,c){b.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$empty[b.getName()]&&(c=b.getIndex(),b=b.getParent()),this._setStartContainer(b),this.startOffset=c,this.endContainer||(this._setEndContainer(b),this.endOffset=c),a(this)},setEnd:function(b,c){b.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$empty[b.getName()]&&(c=b.getIndex()+1,b=b.getParent()),this._setEndContainer(b),this.endOffset=c,this.startContainer||(this._setStartContainer(b),this.startOffset=c),a(this)},setStartAfter:function(a){this.setStart(a.getParent(),a.getIndex()+1)},setStartBefore:function(a){this.setStart(a.getParent(),a.getIndex())},setEndAfter:function(a){this.setEnd(a.getParent(),a.getIndex()+1)},setEndBefore:function(a){this.setEnd(a.getParent(),a.getIndex())},setStartAt:function(b,c){switch(c){case CKEDITOR.POSITION_AFTER_START:this.setStart(b,0);break;case CKEDITOR.POSITION_BEFORE_END:b.type==CKEDITOR.NODE_TEXT?this.setStart(b,b.getLength()):this.setStart(b,b.getChildCount());break;case CKEDITOR.POSITION_BEFORE_START:this.setStartBefore(b);break;case CKEDITOR.POSITION_AFTER_END:this.setStartAfter(b)}a(this)},setEndAt:function(b,c){switch(c){case CKEDITOR.POSITION_AFTER_START:this.setEnd(b,0);break;case CKEDITOR.POSITION_BEFORE_END:b.type==CKEDITOR.NODE_TEXT?this.setEnd(b,b.getLength()):this.setEnd(b,b.getChildCount());break;case CKEDITOR.POSITION_BEFORE_START:this.setEndBefore(b);break;case CKEDITOR.POSITION_AFTER_END:this.setEndAfter(b)}a(this)},fixBlock:function(a,b){var c=this.createBookmark(),d=this.document.createElement(b);this.collapse(a),this.enlarge(CKEDITOR.ENLARGE_BLOCK_CONTENTS),this.extractContents().appendTo(d),d.trim(),this.insertNode(d);var e=d.getBogus();return e&&e.remove(),d.appendBogus(),this.moveToBookmark(c),d},splitBlock:function(a,b){var c=new CKEDITOR.dom.elementPath(this.startContainer,this.root),d=new CKEDITOR.dom.elementPath(this.endContainer,this.root),e=c.block,f=d.block,g=null;return c.blockLimit.equals(d.blockLimit)?("br"!=a&&(e||(e=this.fixBlock(!0,a),f=new CKEDITOR.dom.elementPath(this.endContainer,this.root).block),f||(f=this.fixBlock(!1,a))),c=e&&this.checkStartOfBlock(),d=f&&this.checkEndOfBlock(),this.deleteContents(),e&&e.equals(f)&&(d?(g=new CKEDITOR.dom.elementPath(this.startContainer,this.root),this.moveToPosition(f,CKEDITOR.POSITION_AFTER_END),f=null):c?(g=new CKEDITOR.dom.elementPath(this.startContainer,this.root),this.moveToPosition(e,CKEDITOR.POSITION_BEFORE_START),e=null):(f=this.splitElement(e,b||!1),e.is("ul","ol")||e.appendBogus())),{previousBlock:e,nextBlock:f,wasStartOfBlock:c,wasEndOfBlock:d,elementPath:g}):null},splitElement:function(a,b){if(!this.collapsed)return null;this.setEndAt(a,CKEDITOR.POSITION_BEFORE_END);var c=this.extractContents(!1,b||!1),d=a.clone(!1,b||!1);return c.appendTo(d),d.insertAfter(a),this.moveToPosition(a,CKEDITOR.POSITION_AFTER_END),d},removeEmptyBlocksAtEnd:function(){function a(a){return function(d){return!(b(d)||c(d)||d.type==CKEDITOR.NODE_ELEMENT&&d.isEmptyInlineRemoveable()||a.is("table")&&d.is("caption"))}}
3var b=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.dom.walker.bookmark(!1);return function(b){for(var f,c=this.createBookmark(),d=this[b?"endPath":"startPath"](),e=d.block||d.blockLimit;e&&!e.equals(d.root)&&!e.getFirst(a(e));)f=e.getParent(),this[b?"setEndAt":"setStartAt"](e,CKEDITOR.POSITION_AFTER_END),e.remove(1),e=f;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();return 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=d(c),e[c?"checkBackward":"checkForward"]()},checkStartOfBlock:function(){var a=this.startContainer,b=this.startOffset;return CKEDITOR.env.ie&&b&&a.type==CKEDITOR.NODE_TEXT&&(a=CKEDITOR.tools.ltrim(a.substring(0,b)),h.test(a)&&this.trim(0,1)),this.trim(),a=new CKEDITOR.dom.elementPath(this.startContainer,this.root),b=this.clone(),b.collapse(!0),b.setStartAt(a.block||a.blockLimit,CKEDITOR.POSITION_AFTER_START),a=new CKEDITOR.dom.walker(b),a.evaluator=c(),a.checkBackward()},checkEndOfBlock:function(){var a=this.endContainer,b=this.endOffset;return CKEDITOR.env.ie&&a.type==CKEDITOR.NODE_TEXT&&(a=CKEDITOR.tools.rtrim(a.substring(b)),h.test(a)&&this.trim(1,0)),this.trim(),a=new CKEDITOR.dom.elementPath(this.endContainer,this.root),b=this.clone(),b.collapse(!1),b.setEndAt(a.block||a.blockLimit,CKEDITOR.POSITION_BEFORE_END),a=new CKEDITOR.dom.walker(b),a.evaluator=c(),a.checkForward()},getPreviousNode:function(a,b,c){var d=this.clone();return d.collapse(1),d.setStartAt(c||this.root,CKEDITOR.POSITION_AFTER_START),c=new CKEDITOR.dom.walker(d),c.evaluator=a,c.guard=b,c.previous()},getNextNode:function(a,b,c){var d=this.clone();return d.collapse(),d.setEndAt(c||this.root,CKEDITOR.POSITION_BEFORE_END),c=new CKEDITOR.dom.walker(d),c.evaluator=a,c.guard=b,c.next()},checkReadOnly:function(){function a(a,b){for(;a;){if(a.type==CKEDITOR.NODE_ELEMENT){if("false"==a.getAttribute("contentEditable")&&!a.data("cke-editable"))return 0;if(a.is("html")||"true"==a.getAttribute("contentEditable")&&(a.contains(b)||a.equals(b)))break}a=a.getParent()}return 1}return function(){var b=this.startContainer,c=this.endContainer;return!(a(b,c)&&a(c,b))}}(),moveToElementEditablePosition:function(a,b){if(a.type==CKEDITOR.NODE_ELEMENT&&!a.isEditable(!1))return this.moveToPosition(a,b?CKEDITOR.POSITION_AFTER_END:CKEDITOR.POSITION_BEFORE_START),!0;for(var c=0;a;){if(a.type==CKEDITOR.NODE_TEXT){b&&this.endContainer&&this.checkEndOfBlock()&&h.test(a.getText())?this.moveToPosition(a,CKEDITOR.POSITION_BEFORE_START):this.moveToPosition(a,b?CKEDITOR.POSITION_AFTER_END:CKEDITOR.POSITION_BEFORE_START),c=1;break}if(a.type==CKEDITOR.NODE_ELEMENT)if(a.isEditable())this.moveToPosition(a,b?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_AFTER_START),c=1;else if(b&&a.is("br")&&this.endContainer&&this.checkEndOfBlock())this.moveToPosition(a,CKEDITOR.POSITION_BEFORE_START);else if("false"==a.getAttribute("contenteditable")&&a.is(CKEDITOR.dtd.$block))return this.setStartBefore(a),this.setEndAfter(a),!0;var d=a,e=c,f=void 0;d.type==CKEDITOR.NODE_ELEMENT&&d.isEditable(!1)&&(f=d[b?"getLast":"getFirst"](j)),e||f||(f=d[b?"getPrevious":"getNext"](j)),a=f}return!!c},moveToClosestEditablePosition:function(a,b){var c,e,f,d=0,g=[CKEDITOR.POSITION_AFTER_END,CKEDITOR.POSITION_BEFORE_START];return a?(c=new CKEDITOR.dom.range(this.root),c.moveToPosition(a,g[b?0:1])):c=this.clone(),a&&!a.is(CKEDITOR.dtd.$block)?d=1:(e=c[b?"getNextEditableNode":"getPreviousEditableNode"]())&&(d=1,(f=e.type==CKEDITOR.NODE_ELEMENT)&&e.is(CKEDITOR.dtd.$block)&&"false"==e.getAttribute("contenteditable")?(c.setStartAt(e,CKEDITOR.POSITION_BEFORE_START),c.setEndAt(e,CKEDITOR.POSITION_AFTER_END)):!CKEDITOR.env.needsBrFiller&&f&&e.is(CKEDITOR.dom.walker.validEmptyBlockContainers)?(c.setEnd(e,0),c.collapse()):c.moveToPosition(e,g[b?1:0])),d&&this.moveToRange(c),!!d},moveToElementEditStart:function(a){return this.moveToElementEditablePosition(a)},moveToElementEditEnd:function(a){return this.moveToElementEditablePosition(a,!0)},getEnclosedNode:function(){var a=this.clone();if(a.optimize(),a.startContainer.type!=CKEDITOR.NODE_ELEMENT||a.endContainer.type!=CKEDITOR.NODE_ELEMENT)return null;var a=new CKEDITOR.dom.walker(a),b=CKEDITOR.dom.walker.bookmark(!1,!0),c=CKEDITOR.dom.walker.whitespace
3s(!0);a.evaluator=function(a){return c(a)&&b(a)};var d=a.next();return a.reset(),d&&d.equals(a.previous())?d:null},getTouchedStartNode:function(){var a=this.startContainer;return this.collapsed||a.type!=CKEDITOR.NODE_ELEMENT?a:a.getChild(this.startOffset)||a},getTouchedEndNode:function(){var a=this.endContainer;return this.collapsed||a.type!=CKEDITOR.NODE_ELEMENT?a:a.getChild(this.endOffset-1)||a},getNextEditableNode:e(),getPreviousEditableNode:e(1),scrollIntoView:function(){var b,c,d,a=new CKEDITOR.dom.element.createFromHtml("<span> </span>",this.document),e=this.clone();e.optimize(),(d=e.startContainer.type==CKEDITOR.NODE_TEXT)?(c=e.startContainer.getText(),b=e.startContainer.split(e.startOffset),a.insertAfter(e.startContainer)):e.insertNode(a),a.scrollIntoView(),d&&(e.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,function(){function a(a){1>arguments.length||(this.range=a,this.forceBrBreak=0,this.enlargeBr=1,this.enforceRealBlocks=0,this._||(this._={}))}function b(a){var b=[];return a.forEach(function(a){if("true"==a.getAttribute("contenteditable"))return b.push(a),!1},CKEDITOR.NODE_ELEMENT,!0),b}function c(a,d,e,f){a:{null==f&&(f=b(e));for(var g;g=f.shift();)if(g.getDtd().p){f={element:g,remaining:f};break a}f=null}return f?(g=CKEDITOR.filter.instances[f.element.data("cke-filter")])&&!g.check(d)?c(a,d,e,f.remaining):(d=new CKEDITOR.dom.range(f.element),d.selectNodeContents(f.element),d=d.createIterator(),d.enlargeBr=a.enlargeBr,d.enforceRealBlocks=a.enforceRealBlocks,d.activeFilter=d.filter=g,a._.nestedEditable={element:f.element,container:e,remaining:f.remaining,iterator:d},1):0}function d(a,b,c){return!!b&&(a=a.clone(),a.collapse(!c),a.checkBoundaryOfElement(b,c?CKEDITOR.START:CKEDITOR.END))}var e=/^[\r\n\t ]+$/,f=CKEDITOR.dom.walker.bookmark(!1,!0),g=CKEDITOR.dom.walker.whitespaces(!0),h=function(a){return f(a)&&g(a)},i={dd:1,dt:1,li:1};a.prototype={getNextParagraph:function(a){var b,g,j,k,l;if(a=a||"p",this._.nestedEditable){if(b=this._.nestedEditable.iterator.getNextParagraph(a))return this.activeFilter=this._.nestedEditable.iterator.activeFilter,b;if(this.activeFilter=this.filter,c(this,a,this._.nestedEditable.container,this._.nestedEditable.remaining))return this.activeFilter=this._.nestedEditable.iterator.activeFilter,this._.nestedEditable.iterator.getNextParagraph(a);this._.nestedEditable=null}if(!this.range.root.getDtd()[a])return null;if(!this._.started){var m=this.range.clone();g=m.startPath();var n=m.endPath(),o=!m.collapsed&&d(m,g.block),p=!m.collapsed&&d(m,n.block,1);m.shrink(CKEDITOR.SHRINK_ELEMENT,!0),o&&m.setStartAt(g.block,CKEDITOR.POSITION_BEFORE_END),p&&m.setEndAt(n.block,CKEDITOR.POSITION_AFTER_START),g=m.endContainer.hasAscendant("pre",!0)||m.startContainer.hasAscendant("pre",!0),m.enlarge(this.forceBrBreak&&!g||!this.enlargeBr?CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS:CKEDITOR.ENLARGE_BLOCK_CONTENTS),m.collapsed||(g=new CKEDITOR.dom.walker(m.clone()),n=CKEDITOR.dom.walker.bookmark(!0,!0),g.evaluator=n,this._.nextNode=g.next(),g=new CKEDITOR.dom.walker(m.clone()),g.evaluator=n,g=g.previous(),this._.lastNode=g.getNextSourceNode(!0,null,m.root),this._.lastNode&&this._.lastNode.type==CKEDITOR.NODE_TEXT&&!CKEDITOR.tools.trim(this._.lastNode.getText())&&this._.lastNode.getParent().isBlockBoundary()&&(n=this.range.clone(),n.moveToPosition(this._.lastNode,CKEDITOR.POSITION_AFTER_END),n.checkEndOfBlock()&&(n=new CKEDITOR.dom.elementPath(n.endContainer,n.root),this._.lastNode=(n.block||n.blockLimit).getNextSourceNode(!0))),this._.lastNode&&m.root.contains(this._.lastNode)||(this._.lastNode=this._.docEndMarker=m.document.createText(""),this._.lastNode.insertAfter(g)),m=null),this._.started=1,g=m}for(n=this._.nextNode,m=this._.lastNode,this._.nextNode=null;n;){var o=0,p=n.hasAscendant("pre"),q=n.type!=CKEDITOR.NODE_ELEMENT,r=0;if(q)n.type==CKEDITOR.NODE_TEXT&&e.test(n.getText())&&(q=0);else{var s=n.getName();if(CKEDITOR.dtd.$block[s]&&"false"==n.getAttribute("contenteditable")){b=n,c(this,a,b);break}if(n.isBlockBoundary(this.forceBrBreak&&!p&&{br:1})){if("br"==s)q=1;else if(!g&&!n.getChildCount()&&"hr"!=s){b=n,j=n.equals(m);break}g&&(g.setEndAt(n,CKEDITOR.POSITION_BEFORE_START),"br"!=s&&(this._.nextNode=n)),o=1}else{if(n.getFirst()){g||(g=this.range.clone(),g.setStartAt(n,CKEDITOR.POSITION_BEFORE_START)),n=n.getFirst();continue}q=1}}if(q&&!g&&(g=this.range.clone(),g.setStartAt(n,CKEDITOR.POSITION_BEFORE_START)),j=(!o||q)&&n.equals(m),g&&!o)for(;!n.getNext(h)&&!j;){if(s=n.getParent(),s.isBlockBoundary(this.forceBrBreak&&!p&&{br:1})){o=1,q=0,j||s.equals(m),g.setEndAt(s,CKEDITOR.POSITION_BEFORE_END);break}n=s,q=1,j=n.equals(m),r=1}if(q&&g.setEndAt(n,CKEDITOR.POSITION_AFTER_END),n=this._getNextSourceNode(n,r,m),(j=!n)||o&&g)break}if(!b){if(!g)return this._.docEndMarker&&this._.docEndMarker.remove(),this._.nextNode=null;b=new CKEDITOR.dom.elementPath(g.startContainer,g.root),n=b.blockLimit,o={div:1,th:1,td:1},b=b.block,!b&&n&&!this.enforceRealBlocks&&o[n.getName()]&&g.checkStartOfBlock()&&g.checkEndOfBlock()&&!n.equals(g.root)?b=n:!b||this.enforceRealBlocks&&b.is(i)?(b=this.range.document.createElement(a),g.extractContents().appendTo(b),b.trim(),g.insertN
3ode(b),k=l=!0):"li"!=b.getName()?g.checkStartOfBlock()&&g.checkEndOfBlock()||(b=b.clone(!1),g.extractContents().appendTo(b),b.trim(),l=g.splitBlock(),k=!l.wasStartOfBlock,l=!l.wasEndOfBlock,g.insertNode(b)):j||(this._.nextNode=b.equals(m)?null:this._getNextSourceNode(g.getBoundaryNodes().endNode,1,m))}return k&&(k=b.getPrevious())&&k.type==CKEDITOR.NODE_ELEMENT&&("br"==k.getName()?k.remove():k.getLast()&&"br"==k.getLast().$.nodeName.toLowerCase()&&k.getLast().remove()),l&&(k=b.getLast())&&k.type==CKEDITOR.NODE_ELEMENT&&"br"==k.getName()&&(!CKEDITOR.env.needsBrFiller||k.getPrevious(f)||k.getNext(f))&&k.remove(),this._.nextNode||(this._.nextNode=j||b.equals(m)||!m?null:this._getNextSourceNode(b,1,m)),b},_getNextSourceNode:function(a,b,c){function d(a){return!(a.equals(c)||a.equals(e))}var e=this.range.root;for(a=a.getNextSourceNode(b,null,d);!f(a);)a=a.getNextSourceNode(b,null,d);return a}},CKEDITOR.dom.range.prototype.createIterator=function(){return new a(this)}}(),CKEDITOR.command=function(a,b){this.uiItems=[],this.exec=function(c){return!(this.state==CKEDITOR.TRISTATE_DISABLED||!this.checkAllowed())&&(this.editorFocus&&a.focus(),!1===this.fire("exec")||!1!==b.exec.call(this,a,c))},this.refresh=function(a,c){return!(this.readOnly||!a.readOnly)||(this.context&&!c.isContextFor(this.context)||!this.checkAllowed(!0)?(this.disable(),!0):(this.startDisabled||this.enable(),this.modes&&!this.modes[a.mode]&&this.disable(),!1===this.fire("refresh",{editor:a,path:c})||b.refresh&&!1!==b.refresh.apply(this,arguments)))};var c;this.checkAllowed=function(b){return b||"boolean"!=typeof c?c=a.activeFilter.checkFeature(this):c},CKEDITOR.tools.extend(this,b,{modes:{wysiwyg:1},editorFocus:1,contextSensitive:!!b.context,state:CKEDITOR.TRISTATE_DISABLED}),CKEDITOR.event.call(this)},CKEDITOR.command.prototype={enable:function(){this.state==CKEDITOR.TRISTATE_DISABLED&&this.checkAllowed()&&this.setState(this.preserveState&&"undefined"!=typeof this.previousState?this.previousState:CKEDITOR.TRISTATE_OFF)},disable:function(){this.setState(CKEDITOR.TRISTATE_DISABLED)},setState:function(a){return!(this.state==a||a!=CKEDITOR.TRISTATE_DISABLED&&!this.checkAllowed())&&(this.previousState=this.state,this.state=a,this.fire("state"),!0)},toggleState:function(){this.state==CKEDITOR.TRISTATE_OFF?this.setState(CKEDITOR.TRISTATE_ON):this.state==CKEDITOR.TRISTATE_ON&&this.setState(CKEDITOR.TRISTATE_OFF)}},CKEDITOR.event.implementOn(CKEDITOR.command.prototype),CKEDITOR.ENTER_P=1,CKEDITOR.ENTER_BR=2,CKEDITOR.ENTER_DIV=3,CKEDITOR.config={customConfig:"config.js",autoUpdateElement:!0,language:"",defaultLanguage:"en",contentsLangDirection:"",enterMode:CKEDITOR.ENTER_P,forceEnterMode:!1,shiftEnterMode:CKEDITOR.ENTER_BR,docType:"<!DOCTYPE html>",bodyId:"",bodyClass:"",fullPage:!1,height:200,contentsCss:CKEDITOR.getUrl("contents.css"),extraPlugins:"",removePlugins:"",protectedSource:[],tabIndex:0,width:"",baseFloatZIndex:1e4,blockedKeystrokes:[CKEDITOR.CTRL+66,CKEDITOR.CTRL+73,CKEDITOR.CTRL+85]},function(){function a(a,b,c,d,e){var f,h;a=[];for(f in b){h=b[f],h="boolean"==typeof h?{}:"function"==typeof h?{match:h}:B(h),"$"!=f.charAt(0)&&(h.elements=f),c&&(h.featureName=c.toLowerCase());var i=h;i.elements=g(i.elements,/\s+/)||null,i.propertiesOnly=i.propertiesOnly||!0===i.elements;var j=/\s*,\s*/,k=void 0;for(k in E){i[k]=g(i[k],j)||null;var l=i,m=F[k],n=g(i[F[k]],j),o=i[k],p=[],q=!0,s=void 0;n?q=!1:n={};for(s in o)"!"==s.charAt(0)&&(s=s.slice(1),p.push(s),n[s]=!0,q=!1);for(;s=p.pop();)o[s]=o["!"+s],delete o["!"+s];l[m]=!q&&n||null}i.match=i.match||null,d.push(h),a.push(h)}b=e.elements,e=e.generic;var t;for(c=0,d=a.length;c<d;++c){f=B(a[c]),h=!0===f.classes||!0===f.styles||!0===f.attributes,i=f,k=m=j=void 0;for(j in E)i[j]=r(i[j]);l=!0;for(k in F){j=F[k],m=i[j],n=[],o=void 0;for(o in m)-1<o.indexOf("*")?n.push(new RegExp("^"+o.replace(/\*/g,".*")+"$")):n.push(o);m=n,m.length&&(i[j]=m,l=!1)}if(i.nothingRequired=l,i.noProperties=!(i.attributes||i.classes||i.styles),!0===f.elements||null===f.elements)e[h?"unshift":"push"](f);else for(t in i=f.elements,delete f.elements,i)b[t]?b[t][h?"unshift":"push"](f):b[t]=[f]}}function b(a,b,d,e){if((!a.match||a.match(b))&&(e||h(a,b))&&(a.propertiesOnly||(d.valid=!0),d.allAttributes||(d.allAttributes=c(a.attributes,b.attributes,d.validAttributes)),d.allStyles||(d.allStyles=c(a.styles,b.styles,d.validStyles)),!d.allClasses)){if(a=a.classes,b=b.classes,e=d.validClasses,a)if(!0===a)a=!0;else{for(var i,f=0,g=b.length;f<g;++f)i=b[f],e[i]||(e[i]=a(i));a=!1}else a=!1;d.allClasses=a}}function c(a,b,c){if(!a)return!1;if(!0===a)return!0;for(var d in b)c[d]||(c[d]=a(d));return!1}function d(a,b,c){if(!a.match||a.match(b)){if(a.noProperties)return!1;if(c.hadInvalidAttribute=e(a.attributes,b.attributes)||c.hadInvalidAttribute,c.hadInvalidStyle=e(a.styles,b.styles)||c.hadInvalidStyle,a=a.classes,b=b.classes,a){for(var d=!1,f=!0===a,g=b.length;g--;)(f||a(b[g]))&&(b.splice(g,1),d=!0);a=d}else a=!1;c.hadInvalidClass=a||c.hadInvalidClass}}function e(a,b){if(!a)return!1;var e,c=!1,d=!0===a;for(e in b)(d||a(e))&&(delete b[e],c=!0);return c}function f(a,b,c){return!(a.disabled||a.customConfig&&!c||!b)&&(a._.cachedChecks={},!0)}function g(a,b){if(!a)return!1;if(!0===a)return a;
3if("string"==typeof a)return a=C(a),"*"==a||CKEDITOR.tools.convertArrayToObject(a.split(b));if(CKEDITOR.tools.isArray(a))return!!a.length&&CKEDITOR.tools.convertArrayToObject(a);var e,c={},d=0;for(e in a)c[e]=a[e],d++;return!!d&&c}function h(a,b){if(a.nothingRequired)return!0;var c,d,e,f;if(e=a.requiredClasses)for(f=b.classes,c=0;c<e.length;++c)if(d=e[c],"string"==typeof d){if(-1==CKEDITOR.tools.indexOf(f,d))return!1}else if(!CKEDITOR.tools.checkIfAnyArrayItemMatches(f,d))return!1;return i(b.styles,a.requiredStyles)&&i(b.attributes,a.requiredAttributes)}function i(a,b){if(!b)return!0;for(var d,c=0;c<b.length;++c)if(d=b[c],"string"==typeof d){if(!(d in a))return!1}else if(!CKEDITOR.tools.checkIfAnyObjectPropertyMatches(a,d))return!1;return!0}function j(a){if(!a)return{};a=a.split(/\s*,\s*/).sort();for(var b={};a.length;)b[a.shift()]="cke-test";return b}function k(a){var b,c,d,e,f={},g=1;for(a=C(a);b=a.match(G);)(c=b[2])?(d=l(c,"styles"),e=l(c,"attrs"),c=l(c,"classes")):d=e=c=null,f["$"+g++]={elements:b[1],classes:c,styles:d,attributes:e},a=a.slice(b[0].length);return f}function l(a,b){var c=a.match(H[b]);return c?C(c[1]):null}function m(a){var b=a.styleBackup=a.attributes.style,c=a.classBackup=a.attributes.class;a.styles||(a.styles=CKEDITOR.tools.parseCssText(b||"",1)),a.classes||(a.classes=c?c.split(/\s+/):[])}function n(a,c,e,f){var h,g=0;if(f.toHtml&&(c.name=c.name.replace(I,"$1")),f.doCallbacks&&a.elementCallbacks){a:{h=a.elementCallbacks;for(var k,i=0,j=h.length;i<j;++i)if(k=h[i](c)){h=k;break a}h=void 0}if(h)return h}if(f.doTransform&&(h=a._.transformations[c.name])){for(m(c),i=0;i<h.length;++i)v(a,c,h[i]);p(c)}if(f.doFilter){a:{i=c.name,j=a._,a=j.allowedRules.elements[i],h=j.allowedRules.generic,i=j.disallowedRules.elements[i],j=j.disallowedRules.generic,k=f.skipRequired;var n,o,l={valid:!1,validAttributes:{},validClasses:{},validStyles:{},allAttributes:!1,allClasses:!1,allStyles:!1,hadInvalidAttribute:!1,hadInvalidClass:!1,hadInvalidStyle:!1};if(a||h){if(m(c),i)for(n=0,o=i.length;n<o;++n)if(!1===d(i[n],c,l)){a=null;break a}if(j)for(n=0,o=j.length;n<o;++n)d(j[n],c,l);if(a)for(n=0,o=a.length;n<o;++n)b(a[n],c,l,k);if(h)for(n=0,o=h.length;n<o;++n)b(h[n],c,l,k);a=l}else a=null}if(!a||!a.valid)return e.push(c),1;o=a.validAttributes;var r=a.validStyles;h=a.validClasses;var i=c.attributes,s=c.styles,j=c.classes;k=c.classBackup;var u,w,t=c.styleBackup,x=[],l=[],y=/^data-cke-/;if(n=!1,delete i.style,delete i.class,delete c.classBackup,delete c.styleBackup,!a.allAttributes)for(u in i)o[u]||(y.test(u)?u==(w=u.replace(/^data-cke-saved-/,""))||o[w]||(delete i[u],n=!0):(delete i[u],n=!0));if(!a.allStyles||a.hadInvalidStyle){for(u in s)a.allStyles||r[u]?x.push(u+":"+s[u]):n=!0;x.length&&(i.style=x.sort().join("; "))}else t&&(i.style=t);if(!a.allClasses||a.hadInvalidClass){for(u=0;u<j.length;++u)(a.allClasses||h[j[u]])&&l.push(j[u]);l.length&&(i.class=l.sort().join(" ")),k&&l.length<k.split(/\s+/).length&&(n=!0)}else k&&(i.class=k);if(n&&(g=1),!f.skipFinalValidation&&!q(c))return e.push(c),1}return f.toHtml&&(c.name=c.name.replace(J,"cke:$1")),g}function o(a){var c,b=[];for(c in a)-1<c.indexOf("*")&&b.push(c.replace(/\*/g,".*"));return b.length?new RegExp("^(?:"+b.join("|")+")$"):null}function p(a){var c,b=a.attributes;delete b.style,delete b.class,(c=CKEDITOR.tools.writeCssText(a.styles,!0))&&(b.style=c),a.classes.length&&(b.class=a.classes.sort().join(" "))}function q(a){switch(a.name){case"a":if(!(a.children.length||a.attributes.name||a.attributes.id))return!1;break;case"img":if(!a.attributes.src)return!1}return!0}function r(a){if(!a)return!1;if(!0===a)return!0;var b=o(a);return function(c){return c in a||b&&c.match(b)}}function s(){return new CKEDITOR.htmlParser.element("br")}function t(a){return a.type==CKEDITOR.NODE_ELEMENT&&("br"==a.name||A.$block[a.name])}function u(a,b,c){var d=a.name;if(A.$empty[d]||!a.children.length)"hr"==d&&"br"==b?a.replaceWith(s()):(a.parent&&c.push({check:"it",el:a.parent}),a.remove());else if(A.$block[d]||"tr"==d)if("br"==b)a.previous&&!t(a.previous)&&(b=s(),b.insertBefore(a)),a.next&&!t(a.next)&&(b=s(),b.insertAfter(a)),a.replaceWithChildren();else{var e,d=a.children;a:{e=A[b];for(var h,f=0,g=d.length;f<g;++f)if(h=d[f],h.type==CKEDITOR.NODE_ELEMENT&&!e[h.name]){e=!1;break a}e=!0}if(e)a.name=b,a.attributes={},c.push({check:"parent-down",el:a});else{e=a.parent;for(var i,j,f=e.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT||"body"==e.name,g=d.length;0<g;)h=d[--g],f&&(h.type==CKEDITOR.NODE_TEXT||h.type==CKEDITOR.NODE_ELEMENT&&A.$inline[h.name])?(i||(i=new CKEDITOR.htmlParser.element(b),i.insertAfter(a),c.push({check:"parent-down",el:i})),i.add(h,0)):(i=null,j=A[e.name]||A.span,h.insertAfter(a),e.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT||h.type!=CKEDITOR.NODE_ELEMENT||j[h.name]||c.push({ 4check:"el-up",el:h}));a.remove()}}else d in{style:1,script:1}?a.remove():(a.parent&&c.push({check:"it",el:a.parent}),a.replaceWithChildren())}function v(a,b,c){var d,e;for(d=0;d<c.length;++d)if(e=c[d],!(e.check&&!a.check(e.check,!1)||e.left&&!e.left(b))){e.right(b,K);break}}function w(a,b){var f,g,h,i,c=b.getDefinition(),d=c.attributes,e=c.styles;if(a.name!=c.element)return!1;for(f in d)if("class"==f){for(c=d[f].split(/\s+/),h=a.classes.join("|");i=c.pop();)if(-1==h.indexOf(i))return!1}else if(a.attributes[f]!=d[f])return!1;for(g in e)if(a.styles[g]!=e[g])return!1;return!0}function x(a,b){var c,d;return"string"==typeof a?c=a:a instanceof CKEDITOR.style?d=a:(c=a[0],d=a[1]),[{element:c,left:d,right:function(a,c){c.transform(a,b)}}]}function y(a){return function(b){return w(b,a)}}function z(a){return function(b,c){c[a](b)}}var A=CKEDITOR.dtd,B=CKEDITOR.tools.copy,C=CKEDITOR.tools.trim,D=["","p","br","div"];
4CKEDITOR.FILTER_SKIP_TREE=2,CKEDITOR.filter=function(a){if(this.allowedContent=[],this.disallowedContent=[],this.elementCallbacks=null,this.disabled=!1,this.editor=null,this.id=CKEDITOR.tools.getNextNumber(),this._={allowedRules:{elements:{},generic:[]},disallowedRules:{elements:{},generic:[]},transformations:{},cachedTests:{}},CKEDITOR.filter.instances[this.id]=this,a instanceof CKEDITOR.editor){a=this.editor=a,this.customConfig=!0;var b=a.config.allowedContent;!0===b?this.disabled=!0:(b||(this.customConfig=!1),this.allow(b,"config",1),this.allow(a.config.extraAllowedContent,"extra",1),this.allow(D[a.enterMode]+" "+D[a.shiftEnterMode],"default",1),this.disallow(a.config.disallowedContent))}else this.customConfig=!1,this.allow(a,"default",1)},CKEDITOR.filter.instances={},CKEDITOR.filter.prototype={allow:function(b,c,d){if(!f(this,b,d))return!1;var e,g;if("string"==typeof b)b=k(b);else if(b instanceof CKEDITOR.style){if(b.toAllowedContentRules)return this.allow(b.toAllowedContentRules(this.editor),c,d);e=b.getDefinition(),b={},d=e.attributes,b[e.element]=e={styles:e.styles,requiredStyles:e.styles&&CKEDITOR.tools.objectKeys(e.styles)},d&&(d=B(d),e.classes=d.class?d.class.split(/\s+/):null,e.requiredClasses=e.classes,delete d.class,e.attributes=d,e.requiredAttributes=d&&CKEDITOR.tools.objectKeys(d))}else if(CKEDITOR.tools.isArray(b)){for(e=0;e<b.length;++e)g=this.allow(b[e],c,d);return g}return a(this,b,c,this.allowedContent,this._.allowedRules),!0},applyTo:function(a,b,c,d){if(this.disabled)return!1;var h,e=this,f=[],g=this.editor&&this.editor.config.protectedSource,i=!1,j={doFilter:!c,doTransform:!0,doCallbacks:!0,toHtml:b};a.forEach(function(a){if(a.type==CKEDITOR.NODE_ELEMENT){if("off"==a.attributes["data-cke-filter"])return!1;if(!b||"span"!=a.name||!~CKEDITOR.tools.objectKeys(a.attributes).join("|").indexOf("data-cke-"))if(h=n(e,a,f,j),1&h)i=!0;else if(2&h)return!1}else if(a.type==CKEDITOR.NODE_COMMENT&&a.value.match(/^\{cke_protected\}(?!\{C\})/)){var c;a:{var d=decodeURIComponent(a.value.replace(/^\{cke_protected\}/,""));c=[];var k,l,m;if(g)for(l=0;l<g.length;++l)if((m=d.match(g[l]))&&m[0].length==d.length){c=!0;break a}d=CKEDITOR.htmlParser.fragment.fromHtml(d),1==d.children.length&&(k=d.children[0]).type==CKEDITOR.NODE_ELEMENT&&n(e,k,c,j),c=!c.length}c||f.push(a)}},null,!0),f.length&&(i=!0);var k;a=[],d=D[d||(this.editor?this.editor.enterMode:CKEDITOR.ENTER_P)];for(var l;c=f.pop();)c.type==CKEDITOR.NODE_ELEMENT?u(c,d,a):c.remove();for(;k=a.pop();)if(c=k.el,c.parent)switch(l=A[c.parent.name]||A.span,k.check){case"it":A.$removeEmpty[c.name]&&!c.children.length?u(c,d,a):q(c)||u(c,d,a);break;case"el-up":c.parent.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT||l[c.name]||u(c,d,a);break;case"parent-down":c.parent.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT||l[c.name]||u(c.parent,d,a)}return i},checkFeature:function(a){return!(!this.disabled&&a)||(a.toFeature&&(a=a.toFeature(this.editor)),!a.requiredContent||this.check(a.requiredContent))},disable:function(){this.disabled=!0},disallow:function(b){return!!f(this,b,!0)&&("string"==typeof b&&(b=k(b)),a(this,b,null,this.disallowedContent,this._.disallowedRules),!0)},addContentForms:function(a){if(!this.disabled&&a){var b,c,e,d=[];for(b=0;b<a.length&&!e;++b)c=a[b],("string"==typeof c||c instanceof CKEDITOR.style)&&this.check(c)&&(e=c);if(e){for(b=0;b<a.length;++b)d.push(x(a[b],e));this.addTransformations(d)}}},addElementCallback:function(a){this.elementCallbacks||(this.elementCallbacks=[]),this.elementCallbacks.push(a)},addFeature:function(a){return!(!this.disabled&&a)||(a.toFeature&&(a=a.toFeature(this.editor)),this.allow(a.allowedContent,a.name),this.addTransformations(a.contentTransformations),this.addContentForms(a.contentForms),!a.requiredContent||!this.customConfig&&!this.disallowedContent.length||this.check(a.requiredContent))},addTransformations:function(a){var b,c;if(!this.disabled&&a){var e,d=this._.transformations;for(e=0;e<a.length;++e){b=a[e];var f=void 0,g=void 0,h=void 0,i=void 0,j=void 0,k=void 0;for(c=[],g=0;g<b.length;++g)h=b[g],"string"==typeof h?(h=h.split(/\s*:\s*/),i=h[0],j=null,k=h[1]):(i=h.check,j=h.left,k=h.right),f||(f=h,f=f.element?f.element:i?i.match(/^([a-z0-9]+)/i)[0]:f.left.getDefinition().element),j instanceof CKEDITOR.style&&(j=y(j)),c.push({check:i==f?null:i,left:j,right:"string"==typeof k?z(k):k});b=f,d[b]||(d[b]=[]),d[b].push(c)}}},check:function(a,b,c){if(this.disabled)return!0;
4if(CKEDITOR.tools.isArray(a)){for(var d=a.length;d--;)if(this.check(a[d],b,c))return!0;return!1}var e,f;if("string"==typeof a){if(f=a+"<"+(!1===b?"0":"1")+(c?"1":"0")+">",f in this._.cachedChecks)return this._.cachedChecks[f];d=k(a).$1,e=d.styles;var g=d.classes;d.name=d.elements,d.classes=g=g?g.split(/\s*,\s*/):[],d.styles=j(e),d.attributes=j(d.attributes),d.children=[],g.length&&(d.attributes.class=g.join(" ")),e&&(d.attributes.style=CKEDITOR.tools.writeCssText(d.styles)),e=d}else d=a.getDefinition(),e=d.styles,g=d.attributes||{},e&&!CKEDITOR.tools.isEmpty(e)?(e=B(e),g.style=CKEDITOR.tools.writeCssText(e,!0)):e={},e={name:d.element,attributes:g,classes:g.class?g.class.split(/\s+/):[],styles:e,children:[]};var i,g=CKEDITOR.tools.clone(e),h=[];if(!1!==b&&(i=this._.transformations[e.name])){for(d=0;d<i.length;++d)v(this,e,i[d]);p(e)}return n(this,g,h,{doFilter:!0,doTransform:!1!==b,skipRequired:!c,skipFinalValidation:!c}),b=!(0<h.length)&&!!CKEDITOR.tools.objectCompare(e.attributes,g.attributes,!0),"string"==typeof a&&(this._.cachedChecks[f]=b),b},getAllowedEnterMode:function(){var a=["p","div","br"],b={p:CKEDITOR.ENTER_P,div:CKEDITOR.ENTER_DIV,br:CKEDITOR.ENTER_BR};return function(c,d){var f,e=a.slice();if(this.check(D[c]))return c;for(d||(e=e.reverse());f=e.pop();)if(this.check(f))return b[f];return CKEDITOR.ENTER_BR}}(),destroy:function(){delete CKEDITOR.filter.instances[this.id],delete this._,delete this.allowedContent,delete this.disallowedContent}};var K,E={styles:1,attributes:1,classes:1},F={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,H={styles:/{([^}]+)}/,attrs:/\[([^\]]+)\]/,classes:/\(([^\)]+)\)/},I=/^cke:(object|embed|param)$/,J=/^(object|embed|param)$/;K=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){if(c=c||b,!(c in a.styles)){var d=a.attributes[b];d&&(/^\d+$/.test(d)&&(d+="px"),a.styles[c]=d)}delete a.attributes[b]},lengthToAttribute:function(a,b,c){if(c=c||b,!(c in a.attributes)){var d=a.styles[b],e=d&&d.match(/^(\d+)(?:\.\d*)?px$/);e?a.attributes[c]=e[1]:"cke-test"==d&&(a.attributes[c]="cke-test")}delete a.styles[b]},alignmentToStyle:function(a){if(!("float"in a.styles)){var b=a.attributes.align;"left"!=b&&"right"!=b||(a.styles.float=b)}delete a.attributes.align},alignmentToAttribute:function(a){if(!("align"in a.attributes)){var b=a.styles.float;"left"!=b&&"right"!=b||(a.attributes.align=b)}delete a.styles.float},matchesStyle:w,transform:function(a,b){if("string"==typeof b)a.name=b;else{var f,g,h,i,c=b.getDefinition(),d=c.styles,e=c.attributes;a.name=c.element;for(f in e)if("class"==f)for(c=a.classes.join("|"),h=e[f].split(/\s+/);i=h.pop();)-1==c.indexOf(i)&&a.classes.push(i);else a.attributes[f]=e[f];for(g in d)a.styles[g]=d[g]}}}}(),function(){CKEDITOR.focusManager=function(a){return a.focusManager?a.focusManager:(this.hasFocus=!1,this.currentActive=null,this._={editor:a},this)},CKEDITOR.focusManager._={blurDelay:200},CKEDITOR.focusManager.prototype={focus:function(a){this._.timer&&clearTimeout(this._.timer),a&&(this.currentActive=a),this.hasFocus||this._.locked||((a=CKEDITOR.currentInstance)&&a.focusManager.blur(1),this.hasFocus=!0,(a=this._.editor.container)&&a.addClass("cke_focus"),this._.editor.fire("focus"))},lock:function(){this._.locked=1},unlock:function(){delete this._.locked},blur:function(a){function b(){if(this.hasFocus){this.hasFocus=!1;var a=this._.editor.container;a&&a.removeClass("cke_focus"),this._.editor.fire("blur")}}if(!this._.locked){this._.timer&&clearTimeout(this._.timer);var c=CKEDITOR.focusManager._.blurDelay;a||!c?b.call(this):this._.timer=CKEDITOR.tools.setTimeout(function(){delete this._.timer,b.call(this)},c,this)}},add:function(a,b){var c=a.getCustomData("focusmanager");if(!c||c!=this){c&&c.remove(a);var c="focus",d="blur";b&&(CKEDITOR.env.ie?(c="focusin",d="focusout"):CKEDITOR.event.useCapture=1);var e={blur:function(){a.equals(this.currentActive)&&this.blur()},focus:function(){this.focus(a)}};a.on(c,e.focus,this),a.on(d,e.blur,this),b&&(CKEDITOR.event.useCapture=0),a.setCustomData("focusmanager",this),a.setCustomData("focusmanager_handlers",e)}},remove:function(a){a.removeCustomData("focusmanager");var b=a.removeCustomData("focusmanager_handlers");a.removeListener("blur",b.blur),a.removeListener("focus",b.focus)}}}(),CKEDITOR.keystrokeHandler=function(a){return a.keystrokeHandler?a.keystrokeHandler:(this.keystrokes={},this.blockedKeystrokes={},this._={editor:a},this)},function(){var a,b=function(b){b=b.data;var c=b.getKeystroke(),d=this.keystrokes[c],e=this._.editor;return a=!1===e.fire("key",{keyCode:c,domEvent:b}),a||(d&&(a=!1!==e.execCommand(d,{from:"keystrokeHandler"})),a||(a=!!this.blockedKeystrokes[c])),a&&b.preventDefault(!0),!a},c=function(b){a&&(a=!1,b.data.preventDefault(!0))};CKEDITOR.keystrokeHandler.prototype={attach:function(a){a.on("keydown",b,this),CKEDITOR.env.gecko&&CKEDITOR.env.mac&&a.on("keypress",c,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,"de-ch":1,el:1,"en-au":1,"en-ca":1,"en-gb":1,en:1,eo:1,es:1,et:1,eu:1,fa:1,fi:1,fo:1,"fr-ca":1,fr:1,gl:1,gu:1,he:1,hi:1,hr:1,hu:1,id:1,is:1,it:1,ja:1,ka:1,km:1,ko:1,ku:1,lt:1,lv:1,mk:1,mn:1,ms:1,nb:1,nl:1,no:1,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,b,c){a&&CKEDITOR.lang.languages[a]||(a=this.detect(b,a));var d=this;b=function(){d[a].dir=d.rtl[a]?"rtl":"ltr",c(a,d[a])},this[a]?b():CKEDITOR.scriptLoader.load(CKEDITOR.getUrl("lang/"+a+".js"),b,this)},detect:function(a,b){var c=this.languages;b=b||navigator.userLanguage||navigator.language||a;var d=b.toLowerCase().match(/([a-z]+)(?:-([a-z]+))?/),e=d[1],d=d[2];return c[e+"-"+d]?e=e+"-"+d:c[e]||(e=null),CKEDITOR.lang.detect=e?function(){return e}:function(a){return a},e||a}}}(),CKEDITOR.scriptLoader=function(){var a={},b={};return{load:function(c,d,e,f){var g="string"==typeof c;g&&(c=[c]),e||(e=CKEDITOR);var h=c.length,i=[],j=[],k=function(a){d&&(g?d.call(e,a):d.call(e,i,j))};if(0===h)k(!0);else{var l=function(a,b){(b?i:j).push(a),0>
4=--h&&(f&&CKEDITOR.document.getDocumentElement().removeStyle("cursor"),k(b))},m=function(c,d){a[c]=1;var e=b[c];delete b[c];for(var f=0;f<e.length;f++)e[f](c,d)},n=function(c){if(a[c])l(c,!0);else{var e=b[c]||(b[c]=[]);if(e.push(l),!(1<e.length)){var f=new CKEDITOR.dom.element("script");f.setAttributes({type:"text/javascript",src:c}),d&&(CKEDITOR.env.ie&&11>CKEDITOR.env.version?f.$.onreadystatechange=function(){"loaded"!=f.$.readyState&&"complete"!=f.$.readyState||(f.$.onreadystatechange=null,m(c,!0))}:(f.$.onload=function(){setTimeout(function(){m(c,!0)},0)},f.$.onerror=function(){m(c,!1)})),f.appendTo(CKEDITOR.document.getHead())}}};f&&CKEDITOR.document.getDocumentElement().setStyle("cursor","wait");for(var o=0;o<h;o++)n(c[o])}},queue:function(){function a(){var a;(a=b[0])&&this.load(a.scriptUrl,a.callback,CKEDITOR,0)}var b=[];return function(c,d){var e=this;b.push({scriptUrl:c,callback:function(){d&&d.apply(this,arguments),b.shift(),a.call(e)}}),1==b.length&&a.call(this)}}()}}(),CKEDITOR.resourceManager=function(a,b){this.basePath=a,this.fileName=b,this.registered={},this.loaded={},this.externals={},this._={waitingList:{}}},CKEDITOR.resourceManager.prototype={add:function(a,b){if(this.registered[a])throw Error('[CKEDITOR.resourceManager.add] The resource name "'+a+'" is already registered.');var c=this.registered[a]=b||{};return c.name=a,c.path=this.getPath(a),CKEDITOR.fire(a+CKEDITOR.tools.capitalize(this.fileName)+"Ready",c),this.get(a)},get:function(a){return this.registered[a]||null},getPath:function(a){var b=this.externals[a];return CKEDITOR.getUrl(b&&b.dir||this.basePath+a+"/")},getFilePath:function(a){var b=this.externals[a];return CKEDITOR.getUrl(this.getPath(a)+(b?b.file:this.fileName+".js"))},addExternal:function(a,b,c){a=a.split(",");for(var d=0;d<a.length;d++){var e=a[d];c||(b=b.replace(/[^\/]+$/,function(a){return c=a,""})),this.externals[e]={dir:b,file:c||this.fileName+".js"}}},load:function(a,b,c){CKEDITOR.tools.isArray(a)||(a=a?[a]:[]);for(var d=this.loaded,e=this.registered,f=[],g={},h={},i=0;i<a.length;i++){var j=a[i];if(j)if(d[j]||e[j])h[j]=this.get(j);else{var k=this.getFilePath(j);f.push(k),k in g||(g[k]=[]),g[k].push(j)}}CKEDITOR.scriptLoader.load(f,function(a,e){if(e.length)throw Error('[CKEDITOR.resourceManager.load] Resource name "'+g[e[0]].join(",")+'" was not found at "'+e[0]+'".');for(var f=0;f<a.length;f++)for(var i=g[a[f]],j=0;j<i.length;j++){var k=i[j];h[k]=this.get(k),d[k]=1}b.call(c,h)},this)}},CKEDITOR.plugins=new CKEDITOR.resourceManager("plugins/","plugin"),CKEDITOR.plugins.load=CKEDITOR.tools.override(CKEDITOR.plugins.load,function(a){var b={};return function(c,d,e){var f={},g=function(c){a.call(this,c,function(a){CKEDITOR.tools.extend(f,a);var h,c=[];for(h in a){var i=a[h],j=i&&i.requires;if(!b[h]){if(i.icons)for(var k=i.icons.split(","),l=k.length;l--;)CKEDITOR.skin.addIcon(k[l],i.path+"icons/"+(CKEDITOR.env.hidpi&&i.hidpi?"hidpi/":"")+k[l]+".png");b[h]=1}if(j)for(j.split&&(j=j.split(",")),i=0;i<j.length;i++)f[j[i]]||c.push(j[i])}if(c.length)g.call(this,c);else{for(h in f)i=f[h],i.onLoad&&!i.onLoad._called&&(!1===i.onLoad()&&delete f[h],i.onLoad._called=1);d&&d.call(e||window,f)}},this)};g.call(this,c)}}),CKEDITOR.plugins.setLang=function(a,b,c){var d=this.get(a);a=d.langEntries||(d.langEntries={}),d=d.lang||(d.lang=[]),d.split&&(d=d.split(",")),-1==CKEDITOR.tools.indexOf(d,b)&&d.push(b),a[b]=c},CKEDITOR.ui=function(a){return a.ui?a.ui:(this.items={},this.instances={},this.editor=a,this._={handlers:{}},this)},CKEDITOR.ui.prototype={add:function(a,b,c){c.name=a.toLowerCase();var d=this.items[a]={type:b,command:c.command||null,args:Array.prototype.slice.call(arguments,2)};CKEDITOR.tools.extend(d,c)},get:function(a){return this.instances[a]},create:function(a){var b=this.items[a],c=b&&this._.handlers[b.type],d=b&&b.command&&this.editor.getCommand(b.command),c=c&&c.create.apply(this,b.args);return this.instances[a]=c,d&&d.uiItems.push(c),c&&!c.type&&(c.type=b.type),c},addHandler:function(a,b){this._.handlers[a]=b},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,e,g){if(CKEDITOR.event.call(this),a=a&&CKEDITOR.tools.clone(a),void 0!==e){if(!(e instanceof CKEDITOR.dom.element))throw Error("Expect element of type CKEDITOR.dom.element.");if(!g)throw Error("One of the element modes must be specified.");if(CKEDITOR.env.ie&&CKEDITOR.env.quirks&&g==CKEDITOR.ELEMENT_MODE_INLINE)throw Error("Inline element mode is not supported on IE quirks.");
4if(!c(e,g))throw Error('The specified element mode is not supported on element: "'+e.getName()+'".');this.element=e,this.elementMode=g,this.name=this.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO&&(e.getId()||e.getNameAtt())}else this.elementMode=CKEDITOR.ELEMENT_MODE_NONE;this._={},this.commands={},this.templates={},this.name=this.name||b(),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){f(this,a.data.path)}),this.on("activeFilterChange",function(){f(this,this.elementPath(),!0)}),this.on("mode",d),this.on("instanceReady",function(){this.config.startupFocus&&this.focus()}),CKEDITOR.fire("instanceCreated",null,this),CKEDITOR.add(this),CKEDITOR.tools.setTimeout(function(){"destroyed"!==this.status?h(this,a):CKEDITOR.warn("editor-incorrect-destroy")},0,this)}function b(){do var a="editor"+ ++n;while(CKEDITOR.instances[a]);return a}function c(a,b){return b==CKEDITOR.ELEMENT_MODE_INLINE?a.is(CKEDITOR.dtd.$editable)||a.is("textarea"):b==CKEDITOR.ELEMENT_MODE_REPLACE?!a.is(CKEDITOR.dtd.$nonBodyContent):1}function d(){var b,a=this.commands;for(b in a)e(this,a[b])}function e(a,b){b[b.startDisabled?"disable":a.readOnly&&!b.readOnly?"disable":b.modes[a.mode]?"enable":"disable"]()}function f(a,b,c){if(b){var d,e,f=a.commands;for(e in f)d=f[e],(c||d.contextSensitive)&&d.refresh(a,b)}}function g(a){var b=a.config.customConfig;if(!b)return!1;var b=CKEDITOR.getUrl(b),c=o[b]||(o[b]={});return c.fn?(c.fn.call(a,a.config),CKEDITOR.getUrl(a.config.customConfig)!=b&&g(a)||a.fireOnce("customConfigLoaded")):CKEDITOR.scriptLoader.queue(b,function(){c.fn=CKEDITOR.editorConfig?CKEDITOR.editorConfig:function(){},g(a)}),!0}function h(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,!0),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.hasAttribute("readonly"):a.element.isReadOnly():a.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE&&(a.element.hasAttribute("disabled")||a.element.hasAttribute("readonly"))),a.blockless=a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE&&!(a.element.is("textarea")||CKEDITOR.dtd[a.element.getName()].p),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,c.skin&&(CKEDITOR.skinName=c.skin),a.fireOnce("configLoaded"),a.dataProcessor=new CKEDITOR.htmlDataProcessor(a),a.filter=a.activeFilter=new CKEDITOR.filter(a),i(a)}),b&&null!=b.customConfig&&(a.config.customConfig=b.customConfig),g(a)||a.fireOnce("customConfigLoaded")}function i(a){CKEDITOR.skin.loadPart("editor",function(){j(a)})}function j(a){CKEDITOR.lang.load(a.config.language,a.config.defaultLanguage,function(b,c){var d=a.config.title;a.langCode=b,a.lang=CKEDITOR.tools.prototypedCopy(c),a.title="string"==typeof d||!1===d?d:[a.lang.editor,a.name].join(", "),a.config.contentsLangDirection||(a.config.contentsLangDirection=a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?a.element.getDirection(1):a.lang.dir),a.fire("langLoaded"),k(a)})}function k(a){a.getStylesSet(function(b){a.once("loaded",function(){a.fire("stylesSet",{styles:b})},null,null,1),l(a)})}function l(a){var b=a.config,c=b.plugins,d=b.extraPlugins,e=b.removePlugins;if(d)var f=new RegExp("(?:^|,)(?:"+d.replace(/\s*,\s*/g,"|")+")(?=,|$)","g"),c=c.replace(f,""),c=c+(","+d);if(e)var g=new RegExp("(?:^|,)(?:"+e.replace(/\s*,\s*/g,"|")+")(?=,|$)","g"),c=c.replace(g,"");CKEDITOR.env.air&&(c+=",adobeair"),CKEDITOR.plugins.load(c.split(","),function(c){var d=[],e=[],f=[];a.plugins=c;for(var h in c){var m,i=c[h],j=i.lang,k=null,l=i.requires;if(CKEDITOR.tools.isArray(l)&&(l=l.join(",")),l&&(m=l.match(g)))for(;l=m.pop();)CKEDITOR.error("editor-plugin-required",{plugin:l.replace(",",""),requiredBy:h});j&&!a.lang[h]&&(j.split&&(j=j.split(",")),0<=CKEDITOR.tools.indexOf(j,a.langCode)?k=a.langCode:(k=a.langCode.replace(/-.*/,""),k=k!=a.langCode&&0<=CKEDITOR.tools.indexOf(j,k)?k:0<=CKEDITOR.tools.indexOf(j,"en")?"en":j[0]),i.langEntries&&i.langEntries[k]?(a.lang[h]=i.langEntries[k],k=null):f.push(CKEDITOR.getUrl(i.path+"lang/"+k+".js"))),e.push(k),d.push(i)}CKEDITOR.scriptLoader.load(f,function(){for(var c=["beforeInit","init","afterInit"],f=0;f<c.length;f++)for(var g=0;g<d.length;g++){var h=d[g];0===f&&e[g]&&h.lang&&h.langEntries&&(a.lang[h.name]=h.langEntries[e[g]]),h[c[f]]&&h[c[f]](a)}
4for(a.fireOnce("pluginsLoaded"),b.keystrokes&&a.setKeystroke(a.config.keystrokes),g=0;g<a.config.blockedKeystrokes.length;g++)a.keystrokeHandler.blockedKeystrokes[a.config.blockedKeystrokes[g]]=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();return this.config.htmlEncodeOutput&&(b=CKEDITOR.tools.htmlEncode(b)),a.is("textarea")?a.setValue(b):a.setHtml(b),!0}return!1}a.prototype=CKEDITOR.editor.prototype,CKEDITOR.editor=a;var n=0,o={};CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{addCommand:function(a,b){b.name=a.toLowerCase();var c=new CKEDITOR.command(this,b);return this.mode&&e(this,c),this.commands[a]=c},_attachToForm:function(){function a(a){c.updateElement(),c._.required&&!d.getValue()&&!1===c.fire("required")&&a.data.preventDefault()}function b(a){return!!(a&&a.call&&a.apply)}var c=this,d=c.element,e=new CKEDITOR.dom.element(d.$.form);d.is("textarea")&&e&&(e.on("submit",a),b(e.$.submit)&&(e.$.submit=CKEDITOR.tools.override(e.$.submit,function(b){return function(){a(),b.apply?b.apply(this):b()}})),c.on("destroy",function(){e.removeListener("submit",a)}))},destroy:function(a){this.fire("beforeDestroy"),!a&&m.call(this),this.editable(null),this.filter&&(this.filter.destroy(),delete this.filter),delete this.activeFilter,this.status="destroyed",this.fire("destroy"),this.removeAllListeners(),CKEDITOR.remove(this),CKEDITOR.fire("instanceDestroyed",null,this)},elementPath:function(a){if(!a){if(a=this.getSelection(),!a)return null;a=a.getStartElement()}return a?new CKEDITOR.dom.elementPath(a,this.editable()):null},createRange:function(){var a=this.editable();return a?new CKEDITOR.dom.range(a):null},execCommand:function(a,b){var c=this.getCommand(a),d={name:a,commandData:b,command:c};return!(!c||c.state==CKEDITOR.TRISTATE_DISABLED||!1===this.fire("beforeCommandExec",d)||(d.returnValue=c.exec(d.commandData),c.async||!1===this.fire("afterCommandExec",d)))&&d.returnValue},getCommand:function(a){return this.commands[a]},getData:function(a){!a&&this.fire("beforeGetData");var b=this._.data;return"string"!=typeof b&&(b=(b=this.element)&&this.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE?b.is("textarea")?b.getValue():b.getHtml():""),b={dataValue:b},!a&&this.fire("getData",b),b.dataValue},getSnapshot:function(){var a=this.fire("getSnapshot");return"string"!=typeof a&&(a=(a=this.element)&&this.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE?a.is("textarea")?a.getValue():a.getHtml():""),a},loadSnapshot:function(a){this.fire("loadSnapshot",a)},setData:function(a,b,c){var d=!0,e=b;b&&"object"==typeof b&&(c=b.internal,e=b.callback,d=!b.noSnapshot),!c&&d&&this.fire("saveSnapshot"),!e&&c||this.once("dataReady",function(a){!c&&d&&this.fire("saveSnapshot"),e&&e.call(a.editor)}),a={dataValue:a},!c&&this.fire("setData",a),this._.data=a.dataValue,!c&&this.fire("afterSetData",a)},setReadOnly:function(a){a=null==a||a,this.readOnly!=a&&(this.readOnly=a,this.keystrokeHandler.blockedKeystrokes[8]=+a,this.editable().setReadOnly(a),this.fire("readOnly"))},insertHtml:function(a,b,c){this.fire("insertHtml",{dataValue:a,mode:b,range:c})},insertText:function(a){this.fire("insertText",a)},insertElement:function(a){this.fire("insertElement",a)},getSelectedHtml:function(a){var b=this.editable(),c=this.getSelection(),c=c&&c.getRanges();if(!b||!c||0===c.length)return null;for(var e,f,g,d=new CKEDITOR.dom.documentFragment,h=0;h<c.length;h++){var i=c[h],j=i.startContainer;j.getName&&"tr"==j.getName()?(e||(e=j.getAscendant("table").clone(),e.append(j.getAscendant("tbody").clone()),d.append(e),e=e.findOne("tbody")),f&&f.equals(j)||(f=j,g=j.clone(),e.append(g)),g.append(i.cloneContents())):d.append(i.cloneContents())}return b=e?d:b.getHtmlFromRange(c[0]),a?b.getHtml():b},extractSelectedHtml:function(a,b){var c=this.editable(),d=this.getSelection().getRanges();return c&&0!==d.length?(d=d[0],c=c.extractHtmlFromRange(d,b),b||this.getSelection().selectRanges([d]),a?c.getHtml():c):null},focus:function(){this.fire("beforeFocus")},checkDirty:function(){return"ready"==this.status&&this._.previousValue!==this.getSnapshot()},resetDirty:function(){this._.previousValue=this.getSnapshot()},updateElement:function(){return m.call(this)},setKeystroke:function(){for(var c,d,a=this.keystrokeHandler.keystrokes,b=CKEDITOR.tools.isArray(arguments[0])?arguments[0]:[[].slice.call(arguments,0)],e=b.length;e--;)c=b[e],d=0,CKEDITOR.tools.isArray(c)&&(d=c[1],c=c[0]),d?a[c]=d:delete a[c]},addFeature:function(a){return this.filter.addFeature(a)},setActiveFilter:function(a){a||(a=this.filter),this.activeFilter!==a&&(this.activeFilter=a,this.fire("activeFilterChange"),a===this.filter?this.setActiveEnterMode(null,null):this.setActiveEnterMode(a.getAllowedEnterMode(this.enterMode),a.getAllowedEnterMode(this.shiftEnterMode,!0)))},setActiveEnterMode:function(a,b){a=a?this.blockless?CKEDITOR.ENTER_BR:a:this.enterMode,b=b?this.blockless?CKEDITOR.ENTER_BR:b:this.shiftEnterMode,this.activeEnterMode==a&&this.activeShiftEnterMode==b||(this.activeEnterMode=a,this.activeShiftEnterMode=b,this.fire("activeEnterModeChange"))},showNotification:function(a){alert(a)}})}(),CKEDITOR.ELEMENT_MODE_NONE=0,CKEDITOR.ELEMENT_MODE_REPLACE=1,CKEDITOR.ELEMENT_MODE_APPENDTO=2,CKEDITOR.ELEMENT_MODE_INLINE=3,CKEDITOR.htmlParser=function(){this._={htmlPartsRegex:/<(?:(?:\/([^>]+)>)|(?:!--([\S|\s]*?)--\x3e)|(?:([^\/\s>]+)((?:\s+[\w\-:.]+(?:\s*=\s*?(?:(?:"[^"]*")|(?:'[^']*')|[^\s"'\/>]+))?)*)[\S\s]*?(\/?)>))/g}},function(){var a=/([\w\-:.]+)(?:(?:\s*=\s*(?:(?:"([^"]*)")|(?:'([^']*)')|([^\s>]+)))|(?=\s|$))/g,b={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(c){for(var d,e,g,f=0;d=this._.htmlPartsRegex.exec(c);)if(e=d.index,e>f&&(f=c.substring(f,e),g?g.push(f):this.onText(f)),f=this._.htmlPartsRegex.lastIndex,!(e=d[1])||(e=e.toLowerCase(),g&&CKEDITOR.dtd.$cdata[e]&&(this.onCDATA(g.join("")),g=null),g))if(g)g.push(d[0]);
4else if(e=d[3]){if(e=e.toLowerCase(),!/="/.test(e)){var i,h={},j=d[4];if(d=!!d[5],j)for(;i=a.exec(j);){var k=i[1].toLowerCase();i=i[2]||i[3]||i[4]||"",h[k]=!i&&b[k]?k:CKEDITOR.tools.htmlDecodeAttr(i)}this.onTagOpen(e,h,d),!g&&CKEDITOR.dtd.$cdata[e]&&(g=[])}}else(e=d[2])&&this.onComment(e);else this.onTagClose(e);c.length>f&&this.onText(c.substring(f,c.length))}}}(),CKEDITOR.htmlParser.basicWriter=CKEDITOR.tools.createClass({$:function(){this._={output:[]}},proto:{openTag:function(a){this._.output.push("<",a)},openTagClose:function(a,b){b?this._.output.push(" />"):this._.output.push(">")},attribute:function(a,b){"string"==typeof b&&(b=CKEDITOR.tools.htmlEncodeAttr(b)),this._.output.push(" ",a,'="',b,'"')},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=!1},getHtml:function(a){var b=this._.output.join("");return a&&this.reset(),b}}}),function(){CKEDITOR.htmlParser.node=function(){},CKEDITOR.htmlParser.node.prototype={remove:function(){var a=this.parent.children,b=CKEDITOR.tools.indexOf(a,this),c=this.previous,d=this.next;c&&(c.next=d),d&&(d.previous=c),a.splice(b,1),this.parent=null},replaceWith:function(a){var b=this.parent.children,c=CKEDITOR.tools.indexOf(b,this),d=a.previous=this.previous,e=a.next=this.next;d&&(d.next=a),e&&(e.previous=a),b[c]=a,a.parent=this.parent,this.parent=null},insertAfter:function(a){var b=a.parent.children,c=CKEDITOR.tools.indexOf(b,a),d=a.next;b.splice(c+1,0,this),this.next=a.next,this.previous=a,a.next=this,d&&(d.previous=this),this.parent=a.parent},insertBefore:function(a){var b=a.parent.children,c=CKEDITOR.tools.indexOf(b,a);b.splice(c,0,this),this.next=a,(this.previous=a.previous)&&(a.previous.next=this),a.previous=this,this.parent=a.parent},getAscendant:function(a){for(var b=("function"==typeof a?a:"string"==typeof a?function(b){return b.name==a}:function(b){return b.name in a}),c=this.parent;c&&c.type==CKEDITOR.NODE_ELEMENT;){if(b(c))return c;c=c.parent}return null},wrapWith:function(a){return this.replaceWith(a),a.add(this),a},getIndex:function(){return CKEDITOR.tools.indexOf(this.parent.children,this)},getFilterContext:function(a){return a||{}}}}(),CKEDITOR.htmlParser.comment=function(a){this.value=a,this._={isBlockLike:!1}},CKEDITOR.htmlParser.comment.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_COMMENT,filter:function(a,b){var c=this.value;return(c=a.onComment(b,c,this))?"string"!=typeof c?(this.replaceWith(c),!1):(this.value=c,!0):(this.remove(),!1)},writeHtml:function(a,b){b&&this.filter(b),a.comment(this.value)}}),function(){CKEDITOR.htmlParser.text=function(a){this.value=a,this._={isBlockLike:!1}},CKEDITOR.htmlParser.text.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_TEXT,filter:function(a,b){if(!(this.value=a.onText(b,this.value,this)))return this.remove(),!1},writeHtml:function(a,b){b&&this.filter(b),a.text(this.value)}})}(),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)}})}(),CKEDITOR.htmlParser.fragment=function(){this.children=[],this.parent=null,this._={isBlockLike:!0,hasInlineStarted:!1}},function(){function a(a){return!a.attributes["data-cke-survive"]&&("a"==a.name&&a.attributes.href||CKEDITOR.dtd.$removeEmpty[a.name])}var b=CKEDITOR.tools.extend({table:1,ul:1,ol:1,dl:1},CKEDITOR.dtd.table,CKEDITOR.dtd.ul,CKEDITOR.dtd.ol,CKEDITOR.dtd.dl),c={ol:1,ul:1},d=CKEDITOR.tools.extend({},{html:1},CKEDITOR.dtd.html,CKEDITOR.dtd.body,CKEDITOR.dtd.head,{style:1,script:1}),e={ul:"li",ol:"li",dl:"dd",table:"tbody",tbody:"tr",thead:"tr",tfoot:"tr",tr:"td"};CKEDITOR.htmlParser.fragment.fromHtml=function(f,g,h){function i(a){var b;if(0<q.length)for(var c=0;c<q.length;c++){var d=q[c],e=d.name,f=CKEDITOR.dtd[e],g=s.name&&CKEDITOR.dtd[s.name];g&&!g[e]||a&&f&&!f[a]&&CKEDITOR.dtd[a]?e==s.name&&(l(s,s.parent,1),c--):(b||(j(),b=1),d=d.clone(),d.parent=s,s=d,q.splice(c,1),c--)}}function j(){for(;r.length;)l(r.shift(),s)}function k(a){if(a._.isBlockLike&&"pre"!=a.name&&"textarea"!=a.name){var d,b=a.children.length,c=a.children[b-1];c&&c.type==CKEDITOR.NODE_TEXT&&((d=CKEDITOR.tools.rtrim(c.value))?c.value=d:a.children.length=b-1)}}function l(b,c,d){c=c||s||p;var e=s;void 0===b.previous&&(m(c,b)&&(s=c,o.onTagOpen(h,{}),b.returnPoint=c=s),k(b),a(b)&&!b.children.length||c.add(b),"pre"==b.name&&(u=!1),"textarea"==b.name&&(t=!1)), 5b.returnPoint?(s=b.returnPoint,delete b.returnPoint):s=d?c:e}function m(a,b){if((a==p||"body"==a.name)&&h&&(!a.name||CKEDITOR.dtd[a.name][h])){var c,d;return(c=b.attributes&&(d=b.attributes["data-cke-real-element-type"])?d:b.name)&&c in CKEDITOR.dtd.$inline&&!(c in CKEDITOR.dtd.head)&&!b.isOrphan||b.type==CKEDITOR.NODE_TEXT}}function n(a,b){return(a in CKEDITOR.dtd.$listItem||a in CKEDITOR.dtd.$tableContent)&&(a==b||"dt"==a&&"dd"==b||"dd"==a&&"dt"==b)}var o=new CKEDITOR.htmlParser,p=g instanceof CKEDITOR.htmlParser.element?g:"string"==typeof g?new CKEDITOR.htmlParser.element(g):new CKEDITOR.htmlParser.fragment,q=[],r=[],s=p,t="textarea"==p.name,u="pre"==p.name;o.onTagOpen=function(e,f,g,h){if(f=new CKEDITOR.htmlParser.element(e,f),f.isUnknown&&g&&(f.isEmpty=!0),f.isOptionalClose=h,a(f))q.push(f);else{if("pre"==e)u=!0;else{if("br"==e&&u)return void s.add(new CKEDITOR.htmlParser.text("\n"));"textarea"==e&&(t=!0)}if("br"==e)r.push(f);else{for(;h=(g=s.name)?CKEDITOR.dtd[g]||(s._.isBlockLike?CKEDITOR.dtd.div:CKEDITOR.dtd.span):d,!(f.isUnknown||s.isUnknown||h[e]);)if(s.isOptionalClose)o.onTagClose(g);else if(e in c&&g in c)g=s.children,(g=g[g.length-1])&&"li"==g.name||l(g=ne
5w CKEDITOR.htmlParser.element("li"),s),!f.returnPoint&&(f.returnPoint=s),s=g;else if(e in CKEDITOR.dtd.$listItem&&!n(e,g))o.onTagOpen("li"==e?"ul":"dl",{},0,1);else if(g in b&&!n(e,g))!f.returnPoint&&(f.returnPoint=s),s=s.parent;else{if(g in CKEDITOR.dtd.$inline&&q.unshift(s),!s.parent){f.isOrphan=1;break}l(s,s.parent,1)}i(e),j(),f.parent=s,f.isEmpty?l(f):s=f}}},o.onTagClose=function(a){for(var b=q.length-1;0<=b;b--)if(a==q[b].name)return void q.splice(b,1);for(var c=[],d=[],e=s;e!=p&&e.name!=a;)e._.isBlockLike||d.unshift(e),c.push(e),e=e.returnPoint||e.parent;if(e!=p){for(b=0;b<c.length;b++){var f=c[b];l(f,f.parent)}s=e,e._.isBlockLike&&j(),l(e,e.parent),e==s&&(s=s.parent),q=q.concat(d)}"body"==a&&(h=!1)},o.onText=function(a){if(s._.hasInlineStarted&&!r.length||u||t||(a=CKEDITOR.tools.ltrim(a),0!==a.length)){var c=s.name,f=c?CKEDITOR.dtd[c]||(s._.isBlockLike?CKEDITOR.dtd.div:CKEDITOR.dtd.span):d;!t&&!f["#"]&&c in b?(o.onTagOpen(e[c]||""),o.onText(a)):(j(),i(),u||t||(a=a.replace(/[\t\r\n ]{2,}|[\t\r\n]/g," ")),a=new CKEDITOR.htmlParser.text(a),m(s,a)&&this.onTagOpen(h,{},0,1),s.add(a))}},o.onCDATA=function(a){s.add(new CKEDITOR.htmlParser.cdata(a))},o.onComment=function(a){j(),i(),s.add(new CKEDITOR.htmlParser.comment(a))},o.parse(f);for(j();s!=p;)l(s,s.parent,1);return k(p),p},CKEDITOR.htmlParser.fragment.prototype={type:CKEDITOR.NODE_DOCUMENT_FRAGMENT,add:function(a,b){isNaN(b)&&(b=this.children.length);var c=0<b?this.children[b-1]:null;if(c){if(a._.isBlockLike&&c.type==CKEDITOR.NODE_TEXT&&(c.value=CKEDITOR.tools.rtrim(c.value),0===c.value.length))return this.children.pop(),void this.add(a);c.next=a}a.previous=c,a.parent=this,this.children.splice(b,0,a),this._.hasInlineStarted||(this._.hasInlineStarted=a.type==CKEDITOR.NODE_TEXT||a.type==CKEDITOR.NODE_ELEMENT&&!a._.isBlockLike)},filter:function(a,b){b=this.getFilterContext(b),a.onRoot(b,this),this.filterChildren(a,!1,b)},filterChildren:function(a,b,c){if(this.childrenFilteredBy!=a.id)for(c=this.getFilterContext(c),b&&!this.parent&&a.onRoot(c,this),this.childrenFilteredBy=a.id,b=0;b<this.children.length;b++)!1===this.children[b].filter(a,c)&&b--},writeHtml:function(a,b){b&&this.filter(b),this.writeChildrenHtml(a)},writeChildrenHtml:function(a,b,c){var d=this.getFilterContext();for(c&&!this.parent&&b&&b.onRoot(d,this),b&&this.filterChildren(b,!1,d),b=0,c=this.children,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(!1!==d){c=this.children;for(var e=0;e<c.length;e++)d=c[e],d.type==CKEDITOR.NODE_ELEMENT?d.forEach(a,b):b&&d.type!=b||a(d)}},getFilterContext:function(a){return a||{}}}}(),function(){function a(){this.rules=[]}function b(b,c,d,e){var f,g;for(f in c)(g=b[f])||(g=b[f]=new a),g.add(c[f],d,e)}CKEDITOR.htmlParser.filter=CKEDITOR.tools.createClass({$:function(b){this.id=CKEDITOR.tools.getNextNumber(),this.elementNameRules=new a,this.attributeNameRules=new a,this.elementsRules={},this.attributesRules={},this.textRules=new a,this.commentRules=new a,this.rootRules=new a,b&&this.addRules(b,10)},proto:{addRules:function(a,c){var d;"number"==typeof c?d=c:c&&"priority"in c&&(d=c.priority),"number"!=typeof d&&(d=10),"object"!=typeof c&&(c={}),a.elementNames&&this.elementNameRules.addMany(a.elementNames,d,c),a.attributeNames&&this.attributeNameRules.addMany(a.attributeNames,d,c),a.elements&&b(this.elementsRules,a.elements,d,c),a.attributes&&b(this.attributesRules,a.attributes,d,c),a.text&&this.textRules.add(a.text,d,c),a.comment&&this.commentRules.add(a.comment,d,c),a.root&&this.rootRules.add(a.root,d,c)},applyTo:function(a){a.filter(this)},onElementName:function(a,b){return this.elementNameRules.execOnName(a,b)},onAttributeName:function(a,b){return this.attributeNameRules.execOnName(a,b)},onText:function(a,b,c){return this.textRules.exec(a,b,c)},onComment:function(a,b,c){return this.commentRules.exec(a,b,c)},onRoot:function(a,b){return this.rootRules.exec(a,b)},onElement:function(a,b){for(var d,c=[this.elementsRules["^"],this.elementsRules[b.name],this.elementsRules.$],e=0;3>e;e++)if(d=c[e]){if(d=d.exec(a,b,this),!1===d)return null;if(d&&d!=b)return this.onNode(a,d);if(b.parent&&!b.name)break}return b},onNode:function(a,b){var c=b.type;return c==CKEDITOR.NODE_ELEMENT?this.onElement(a,b):c==CKEDITOR.NODE_TEXT?new CKEDITOR.htmlParser.text(this.onText(a,b.value)):c==CKEDITOR.NODE_COMMENT?new CKEDITOR.htmlParser.comment(this.onComment(a,b.value)):null},onAttribute:function(a,b,c,d){return(c=this.attributesRules[c])?c.exec(a,d,b,this):d}}}),CKEDITOR.htmlParser.filterRulesGroup=a,a.prototype={add:function(a,b,c){this.rules.splice(this.findIndex(b),0,{value:a,priority:b,options:c})},addMany:function(a,b,c){for(var d=[this.findIndex(b),0],e=0,f=a.length;e<f;e++)d.push({value:a[e],priority:b,options:c});this.rules.splice.apply(this.rules,d)},findIndex:function(a){for(var b=this.rules,c=b.length-1;0<=c&&a<b[c].priority;)c--;return c+1},exec:function(a,b){var g,h,i,j,c=b instanceof CKEDITOR.htmlParser.node||b instanceof CKEDITOR.htmlParser.fragment,d=Array.prototype.slice.call(arguments,1
5),e=this.rules,f=e.length;for(j=0;j<f;j++)if(c&&(g=b.type,h=b.name),i=e[j],!(a.nonEditable&&!i.options.applyToAll||a.nestedEditable&&i.options.excludeNestedEditable)){if(i=i.value.apply(null,d),!1===i||c&&i&&(i.name!=h||i.type!=g))return i;null!=i&&(d[0]=b=i)}return b},execOnName:function(a,b){for(var f,c=0,d=this.rules,e=d.length;b&&c<e;c++)f=d[c],a.nonEditable&&!f.options.applyToAll||a.nestedEditable&&f.options.excludeNestedEditable||(b=b.replace(f.value[0],f.value[1]));return b}}}(),function(){function a(a,b){function h(a){return a||CKEDITOR.env.needsNbspFiller?new CKEDITOR.htmlParser.text("Â "):new CKEDITOR.htmlParser.element("br",{"data-cke-bogus":1})}function i(a,b){return function(e){if(e.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT){var k,m,g=[],i=c(e);if(i)for(j(i,1)&&g.push(i);i;)f(i)&&(k=d(i))&&j(k)&&((m=d(k))&&!f(m)?g.push(k):(h(l).insertAfter(k),k.remove())),i=i.previous;for(i=0;i<g.length;i++)g[i].remove();(g=!a||!1!==("function"==typeof b?b(e):b))&&((l||CKEDITOR.env.needsBrFiller||e.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT)&&(l||CKEDITOR.env.needsBrFiller||!(7<document.documentMode||e.name in CKEDITOR.dtd.tr||e.name in CKEDITOR.dtd.$listItem))?(g=c(e),g=!g||"form"==e.name&&"input"==g.name):g=!1),g&&e.add(h(a))}}}function j(a,b){if((!l||CKEDITOR.env.needsBrFiller)&&a.type==CKEDITOR.NODE_ELEMENT&&"br"==a.name&&!a.attributes["data-cke-eol"])return!0;var c;return!!(a.type==CKEDITOR.NODE_TEXT&&(c=a.value.match(q))&&(c.index&&(new CKEDITOR.htmlParser.text(a.value.substring(0,c.index)).insertBefore(a),a.value=c[0]),!CKEDITOR.env.needsBrFiller&&l&&(!b||a.parent.name in m)||!l&&((c=a.previous)&&"br"==c.name||!c||f(c))))}var n,k={elements:{}},l="html"==b,m=CKEDITOR.tools.extend({},u);for(n in m)"#"in s[n]||delete m[n];for(n in m)k.elements[n]=i(l,a.config.fillEmptyBlocks);return k.root=i(l,!1),k.elements.br=function(a){return function(b){if(b.parent.type!=CKEDITOR.NODE_DOCUMENT_FRAGMENT){var c=b.attributes;if("data-cke-bogus"in c||"data-cke-eol"in c)delete c["data-cke-bogus"];else{for(c=b.next;c&&e(c);)c=c.next;var i=d(b);!c&&f(b.parent)?g(b.parent,h(a)):f(c)&&i&&!f(i)&&h(a).insertBefore(c)}}}}(l),k}function b(a,b){return a!=CKEDITOR.ENTER_BR&&!1!==b&&(a==CKEDITOR.ENTER_DIV?"div":"p")}function c(a){for(a=a.children[a.children.length-1];a&&e(a);)a=a.previous;return a}function d(a){for(a=a.previous;a&&e(a);)a=a.previous;return a}function e(a){return a.type==CKEDITOR.NODE_TEXT&&!CKEDITOR.tools.trim(a.value)||a.type==CKEDITOR.NODE_ELEMENT&&a.attributes["data-cke-bookmark"]}function f(a){return a&&(a.type==CKEDITOR.NODE_ELEMENT&&a.name in u||a.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT)}function g(a,b){var c=a.children[a.children.length-1];a.children.push(b),b.parent=a,c&&(c.next=b,b.previous=c)}function h(a){a=a.attributes,"false"!=a.contenteditable&&(a["data-cke-editable"]=a.contenteditable?"true":1),a.contenteditable="false"}function i(a){switch(a=a.attributes,a["data-cke-editable"]){case"true":a.contenteditable="true";break;case"1":delete a.contenteditable}}function j(a){return a.replace(z,function(a,b,c){return"<"+b+c.replace(A,function(a,b){return B.test(b)&&-1==c.indexOf("data-cke-saved-"+b)?" data-cke-saved-"+a+" data-cke-"+CKEDITOR.rnd+"-"+a:a})+">"})}function k(a,b){return a.replace(b,function(a,b,c){return 0===a.indexOf("<textarea")&&(a=b+n(c).replace(/</g,"<").replace(/>/g,">")+"</textarea>"),"<cke:encoded>"+encodeURIComponent(a)+"</cke:encoded>"})}function l(a){return a.replace(E,function(a,b){return decodeURIComponent(b)})}function m(a){return a.replace(/\x3c!--(?!{cke_protected})[\s\S]+?--\x3e/g,function(a){return"<!--"+r+"{C}"+encodeURIComponent(a).replace(/--/g,"%2D%2D")+"-->"})}function n(a){return a.replace(/\x3c!--\{cke_protected\}\{C\}([\s\S]+?)--\x3e/g,function(a,b){return decodeURIComponent(b)})}function o(a,b){var c=b._.dataStore;return a.replace(/\x3c!--\{cke_protected\}([\s\S]+?)--\x3e/g,function(a,b){return decodeURIComponent(b)}).replace(/\{cke_protected_(\d+)\}/g,function(a,b){return c&&c[b]||""})}function p(a,b){var c=[],d=b.config.protectedSource,e=b._.dataStore||(b._.dataStore={id:1}),f=/<\!--\{cke_temp(comment)?\}(\d*?)--\x3e/g,d=[/<script[\s\S]*?(<\/script>|$)/gi,/<noscript[\s\S]*?<\/noscript>/gi,/<meta[\s\S]*?\/?>/gi].concat(d);a=a.replace(/\x3c!--[\s\S]*?--\x3e/g,function(a){return"<!--{cke_tempcomment}"+(c.push(a)-1)+"-->"});for(var g=0;g<d.length;g++)a=a.replace(d[g],function(a){return a=a.replace(f,function(a,b,d){return c[d]}),/cke_temp(comment)?/.test(a)?a:"<!--{cke_temp}"+(c.push(a)-1)+"-->"});return a=a.replace(f,function(a,b,d){return"<!--"+r+(b?"{C}":"")+encodeURIComponent(c[d]).replace(/--/g,"%2D%2D")+"-->"}),a=a.replace(/<\w+(?:\s+(?:(?:[^\s=>]+\s*=\s*(?:[^'"\s>]+|'[^']*'|"[^"]*"))|[^\s=\/>]+))+\s*\/?>/g,function(a){return a.replace(/\x3c!--\{cke_protected\}([^>]*)--\x3e/g,function(a,b){return e[e.id]=decodeURIComponent(b),"{cke_protected_"+e.id++ +"}"})}),a=a.replace(/<(title|iframe|textarea)([^>]*)>([\s\S]*?)<\/\1>/g,function(a,c,d,e){return"<"+c+d+">"+o(n(e),b)+"</"+c+">"})}CKEDITOR.htmlDataProcessor=function(c){var d,e,f=this;this.editor=c,this.dataFilter=d=new CKEDITOR.htmlParser.filter,this.htmlFilter=e=new CKEDITOR.htmlParser.filter,this.writer=new CKEDITOR.htmlParser.basicWriter,d.addRules(v),d.addRules(w,{applyToAll:!0}),d.addRules(a(c,"data"),{applyToAll:!0}),e.addRules(x),e.addRules(y,{applyToAll:!0}),e.addRules(a(c,"html"),{applyToAll:!0}),c.on("toHtml",function(a){a=a.data;
5var e,d=a.dataValue,d=p(d,c),d=k(d,D),d=j(d),d=k(d,C),d=d.replace(F,"$1cke:$2"),d=d.replace(H,"<cke:$1$2></cke:$1>"),d=d.replace(/(<pre\b[^>]*>)(\r\n|\n)/g,"$1$2$2"),d=d.replace(/([^a-z0-9<\-])(on\w{3,})(?!>)/gi,"$1data-cke-"+CKEDITOR.rnd+"-$2");e=a.context||c.editable().getName();var f;CKEDITOR.env.ie&&9>CKEDITOR.env.version&&"pre"==e&&(e="div",d="<pre>"+d+"</pre>",f=1),e=c.document.createElement(e),e.setHtml("a"+d),d=e.getHtml().substr(1),d=d.replace(new RegExp("data-cke-"+CKEDITOR.rnd+"-","ig"),""),f&&(d=d.replace(/^<pre>|<\/pre>$/gi,"")),d=d.replace(G,"$1$2"),d=l(d),d=n(d),e=!1!==a.fixForBody&&b(a.enterMode,c.config.autoParagraph),d=CKEDITOR.htmlParser.fragment.fromHtml(d,a.context,e),e&&(f=d,!f.children.length&&CKEDITOR.dtd[f.name][e]&&(e=new CKEDITOR.htmlParser.element(e),f.add(e))),a.dataValue=d},null,null,5),c.on("toHtml",function(a){a.data.filter.applyTo(a.data.dataValue,!0,a.data.dontFilter,a.data.enterMode)&&c.fire("dataFiltered")},null,null,6),c.on("toHtml",function(a){a.data.dataValue.filterChildren(f.dataFilter,!0)},null,null,10),c.on("toHtml",function(a){a=a.data;var b=a.dataValue,c=new CKEDITOR.htmlParser.basicWriter;b.writeChildrenHtml(c),b=c.getHtml(!0),a.dataValue=m(b)},null,null,15),c.on("toDataFormat",function(a){var d=a.data.dataValue;a.data.enterMode!=CKEDITOR.ENTER_BR&&(d=d.replace(/^<br *\/?>/i,"")),a.data.dataValue=CKEDITOR.htmlParser.fragment.fromHtml(d,a.data.context,b(a.data.enterMode,c.config.autoParagraph))},null,null,5),c.on("toDataFormat",function(a){a.data.dataValue.filterChildren(f.htmlFilter,!0)},null,null,10),c.on("toDataFormat",function(a){a.data.filter.applyTo(a.data.dataValue,!1,!0)},null,null,11),c.on("toDataFormat",function(a){var b=a.data.dataValue,d=f.writer;d.reset(),b.writeChildrenHtml(d),b=d.getHtml(!0),b=n(b),b=o(b,c),a.data.dataValue=b},null,null,15)},CKEDITOR.htmlDataProcessor.prototype={toHtml:function(a,b,c,d){var f,g,h,i,e=this.editor;return b&&"object"==typeof b?(f=b.context,c=b.fixForBody,d=b.dontFilter,g=b.filter,h=b.enterMode,i=b.protectedWhitespaces):f=b,f||null===f||(f=e.editable().getName()),e.fire("toHtml",{dataValue:a,context:f,fixForBody:c,dontFilter:d,filter:g||e.filter,enterMode:h||e.enterMode,protectedWhitespaces:i}
5).dataValue},toDataFormat:function(a,b){var c,d,e;return b&&(c=b.context,d=b.filter,e=b.enterMode),c||null===c||(c=this.editor.editable().getName()),this.editor.fire("toDataFormat",{dataValue:a,filter:d||this.editor.filter,context:c,enterMode:e||this.editor.enterMode}).dataValue}};var q=/(?: |\xa0)$/,r="{cke_protected}",s=CKEDITOR.dtd,t="caption colgroup col thead tfoot tbody".split(" "),u=CKEDITOR.tools.extend({},s.$blockLimit,s.$block),v={elements:{input:h,textarea:h}},w={attributeNames:[[/^on/,"data-cke-pa-on"],[/^data-cke-expando$/,""]]},x={elements:{embed:function(a){var b=a.parent;if(b&&"object"==b.name){var c=b.attributes.width,b=b.attributes.height;c&&(a.attributes.width=c),b&&(a.attributes.height=b)}},a:function(a){var b=a.attributes;if(!(a.children.length||b.name||b.id||a.attributes["data-cke-saved-name"]))return!1}}},y={elementNames:[[/^cke:/,""],[/^\?xml:namespace$/,""]],attributeNames:[[/^data-cke-(saved|pa)-/,""],[/^data-cke-.*/,""],["hidefocus",""]],elements:{$:function(a){var b=a.attributes;if(b){if(b["data-cke-temp"])return!1;for(var d,c=["name","href","src"],e=0;e<c.length;e++)d="data-cke-saved-"+c[e],d in b&&delete b[c[e]]}return a},table:function(a){a.children.slice(0).sort(function(a,b){var c,d;return a.type==CKEDITOR.NODE_ELEMENT&&b.type==a.type&&(c=CKEDITOR.tools.indexOf(t,a.name),d=CKEDITOR.tools.indexOf(t,b.name)),-1<c&&-1<d&&c!=d||(c=a.parent?a.getIndex():-1,d=b.parent?b.getIndex():-1),c>d?1:-1})},param:function(a){return a.children=[],a.isEmpty=!0,a},span:function(a){"Apple-style-span"==a.attributes.class&&delete a.name},html:function(a){delete a.attributes.contenteditable,delete a.attributes.class},body:function(a){delete a.attributes.spellcheck,delete a.attributes.contenteditable},style:function(a){var b=a.children[0];b&&b.value&&(b.value=CKEDITOR.tools.trim(b.value)),a.attributes.type||(a.attributes.type="text/css")},title:function(a){var b=a.children[0];!b&&g(a,b=new CKEDITOR.htmlParser.text),b.value=a.attributes["data-cke-title"]||""},input:i,textarea:i},attributes:{class:function(a){return CKEDITOR.tools.ltrim(a.replace(/(?:^|\s+)cke_[^\s]*/g,""))||!1}}};CKEDITOR.env.ie&&(y.attributes.style=function(a){return a.replace(/(^|;)([^\:]+)/g,function(a){return a.toLowerCase()})});var z=/<(a|area|img|input|source)\b([^>]*)>/gi,A=/([\w-:]+)\s*=\s*(?:(?:"[^"]*")|(?:'[^']*')|(?:[^ "'>]+))/gi,B=/^(href|src|name)$/i,C=/(?:<style(?=[ >])[^>]*>[\s\S]*?<\/style>)|(?:<(:?link|meta|base)[^>]*>)/gi,D=/(<textarea(?=[ >])[^>]*>)([\s\S]*?)(?:<\/textarea>)/gi,E=/<cke:encoded>([^<]*)<\/cke:encoded>/gi,F=/(<\/?)((?:object|embed|param|html|body|head|title)[^>]*>)/gi,G=/(<\/?)cke:((?:html|body|head|title)[^>]*>)/gi,H=/<cke:(param|embed)([^>]*?)\/?>(?!\s*<\/cke:\1)/gi}(),CKEDITOR.htmlParser.element=function(a,b){this.name=a,this.attributes=b||{},this.children=[];var c=a||"",d=c.match(/^cke:(.*)/);d&&(c=d[1]),c=!!(CKEDITOR.dtd.$nonBodyContent[c]||CKEDITOR.dtd.$block[c]||CKEDITOR.dtd.$listItem[c]||CKEDITOR.dtd.$tableContent[c]||CKEDITOR.dtd.$nonEditable[c]||"br"==c),this.isEmpty=!!CKEDITOR.dtd.$empty[a],this.isUnknown=!CKEDITOR.dtd[a],this._={isBlockLike:c,hasInlineStarted:this.isEmpty||!c}},CKEDITOR.htmlParser.cssStyle=function(a){var b={};return((a instanceof CKEDITOR.htmlParser.element?a.attributes.style:a)||"").replace(/"/g,'"').replace(/\s*([^ :;]+)\s*:\s*([^;]+)\s*(?=;|$)/g,function(a,c,d){"font-family"==c&&(d=d.replace(/["']/g,"")),b[c.toLowerCase()]=d}),{rules:b,populate:function(a){var b=this.toString();b&&(a instanceof CKEDITOR.dom.element?a.setAttribute("style",b):a instanceof CKEDITOR.htmlParser.element?a.attributes.style=b:a.style=b)},toString:function(){var c,a=[];for(c in b)b[c]&&a.push(c,":",b[c],";");return a.join("")}}},function(){function a(a){return function(b){return b.type==CKEDITOR.NODE_ELEMENT&&("string"==typeof a?b.name==a:b.name in a)}}var b=function(a,b){return a=a[0],b=b[0],a<b?-1:a>b?1:0},c=CKEDITOR.htmlParser.fragment.prototype;CKEDITOR.htmlParser.element.prototype=CKEDITOR.tools.extend(new CKEDITOR.htmlParser.node,{type:CKEDITOR.NODE_ELEMENT,add:c.add,clone:function(){return new CKEDITOR.htmlParser.element(this.name,this.attributes)},filter:function(a,b){var d,e,c=this;if(b=c.getFilterContext(b),b.off)return!0;for(c.parent||a.onRoot(b,c);;){if(d=c.name,!(e=a.onElementName(b,d)))return this.remove(),!1;if(c.name=e,!(c=a.onElement(b,c)))return this.remove(),!1;if(c!==this)return this.replaceWith(c),!1;if(c.name==d)break;if(c.type!=CKEDITOR.NODE_ELEMENT)return this.replaceWith(c),!1;if(!c.name)return this.replaceWithChildren(),!1}d=c.attributes;var f,g;for(f in d){for(e=d[f];;){if(!(g=a.onAttributeName(b,f))){delete d[f];break}if(g==f)break;delete d[f],f=g}g&&(!1===(e=a.onAttribute(b,c,g,e))?delete d[g]:d[g]=e)}return c.isEmpty||this.filterChildren(a,!1,b),!0},filterChildren:c.filterChildren,writeHtml:function(a,c){c&&this.filter(c);var g,h,d=this.name,e=[],f=this.attributes;a.openTag(d,f);for(g in f)e.push([g,f[g]]);for(a.sortAttributes&&e.sort(b),g=0,h=e.length;g<h;g++)f=e[g],a.attribute(f[0],f[1]);a.openTagClose(d,this.isEmpty),this.writeChildrenHtml(a),this.isEmpty||a.closeTag(d)},writeChildrenHtml:c.writeChildrenHtml,replaceWithChildren:function(){for(var a=this.children,b=a.length;b;)a[--b].insertAfter(this);this.remove()}
5,forEach:c.forEach,getFirst:function(b){if(!b)return this.children.length?this.children[0]:null;"function"!=typeof b&&(b=a(b));for(var c=0,d=this.children.length;c<d;++c)if(b(this.children[c]))return this.children[c];return null},getHtml:function(){var a=new CKEDITOR.htmlParser.basicWriter;return this.writeChildrenHtml(a),a.getHtml()},setHtml:function(a){a=this.children=CKEDITOR.htmlParser.fragment.fromHtml(a).children;for(var b=0,c=a.length;b<c;++b)a[b].parent=this},getOuterHtml:function(){var a=new CKEDITOR.htmlParser.basicWriter;return this.writeHtml(a),a.getHtml()},split:function(a){for(var b=this.children.splice(a,this.children.length-a),c=this.clone(),d=0;d<b.length;++d)b[d].parent=c;return c.children=b,b[0]&&(b[0].previous=null),0<a&&(this.children[a-1].next=null),this.parent.add(c,this.getIndex()+1),c},addClass:function(a){if(!this.hasClass(a)){var b=this.attributes.class||"";this.attributes.class=b+(b?" ":"")+a}},removeClass:function(a){var b=this.attributes.class;b&&((b=CKEDITOR.tools.trim(b.replace(new RegExp("(?:\\s+|^)"+a+"(?:\\s+|$)")," ")))?this.attributes.class=b:delete this.attributes.class)},hasClass:function(a){var b=this.attributes.class;return!!b&&new RegExp("(?:^|\\s)"+a+"(?=\\s|$)").test(b)},getFilterContext:function(a){var b=[];if(a||(a={off:!1,nonEditable:!1,nestedEditable:!1}),a.off||"off"!=this.attributes["data-cke-processor"]||b.push("off",!0),a.nonEditable||"false"!=this.attributes.contenteditable?a.nonEditable&&!a.nestedEditable&&"true"==this.attributes.contenteditable&&b.push("nestedEditable",!0):b.push("nonEditable",!0),b.length){a=CKEDITOR.tools.copy(a);for(var c=0;c<b.length;c+=2)a[b[c]]=b[c+1]}return a}},!0)}(),function(){var a={},b=/{([^}]+)}/g,c=/([\\'])/g,d=/\n/g,e=/\r/g;CKEDITOR.template=function(f){if(a[f])this.output=a[f];else{var g=f.replace(c,"\\$1").replace(d,"\\n").replace(e,"\\r").replace(b,function(a,b){return"',data['"+b+"']==undefined?'{"+b+"}':data['"+b+"'],'"});this.output=a[f]=Function("data","buffer","return buffer?buffer.push('"+g+"'):['"+g+"'].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(){CKEDITOR.currentInstance!=a&&(CKEDITOR.currentInstance=a,CKEDITOR.fire("currentInstance"))}),a.on("blur",function(){CKEDITOR.currentInstance==a&&(CKEDITOR.currentInstance=null,CKEDITOR.fire("currentInstance"))}),CKEDITOR.fire("instance",null,a)},CKEDITOR.remove=function(a){delete CKEDITOR.instances[a.name]},function(){var a={};CKEDITOR.addTemplate=function(b,c){var d=a[b];return d?d:(d={name:b,source:c},CKEDITOR.fire("template",d),a[b]=new CKEDITOR.template(d.source))},CKEDITOR.getTemplate=function(b){return a[b]}}(),function(){var a=[];CKEDITOR.addCss=function(b){a.push(b)},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,b){if(!CKEDITOR.env.isCompatible)return null;if(a=CKEDITOR.dom.element.get(a),a.getEditor())throw'The editor instance "'+a.getEditor().name+'" is already attached to the provided element.';var c=new CKEDITOR.editor(b,a,CKEDITOR.ELEMENT_MODE_INLINE),d=a.is("textarea")?a:null;return d?(c.setData(d.getValue(),null,!0),a=CKEDITOR.dom.element.createFromHtml('<div contenteditable="'+!!c.readOnly+'" class="cke_textarea_inline">'+d.getValue()+"</div>",CKEDITOR.document),a.insertAfter(d),d.hide(),d.$.form&&c._attachToForm()):c.setData(a.getHtml(),null,!0),c.on("loaded",function(){c.fire("uiReady"),c.editable(a),c.container=a,c.ui.contentsElement=a,c.setData(c.getData(1)),c.resetDirty(),c.fire("contentDom"),c.mode="wysiwyg",c.fire("mode"),c.status="ready",c.fireOnce("instanceReady"),CKEDITOR.fire("instanceReady",null,c)},null,null,1e4),c.on("destroy",function(){d&&(c.container.clearCustomData(),c.container.remove(),d.show()),c.element.clearCustomData(),delete c.element}),c},CKEDITOR.inlineAll=function(){var a,b,c;for(c in CKEDITOR.dtd.$editable)for(var d=CKEDITOR.document.getElementsByTag(c),e=0,f=d.count();e<f;e++)a=d.getItem(e),"true"==a.getAttribute("contenteditable")&&(b={element:a,config:{}},!1!==CKEDITOR.fire("inline",b)&&CKEDITOR.inline(a,b.config))},CKEDITOR.domReady(function(){!CKEDITOR.disableAutoInline&&CKEDITOR.inlineAll()})}(),CKEDITOR.replaceClass="ckeditor",function(){function a(a,d,e,f){if(!CKEDITOR.env.isCompatible)return null;if(a=CKEDITOR.dom.element.get(a),a.getEditor())throw'The editor instance "'+a.getEditor().name+'" is already attached to the provided element.';var g=new CKEDITOR.editor(d,a,f);return f==CKEDITOR.ELEMENT_MODE_REPLACE&&(a.setStyle("visibility","hidden"),g._.required=a.hasAttribute("required"),a.removeAttribute("required")),e&&g.setData(e,null,!0),g.on("loaded",function(){c(g),f==CKEDITOR.ELEMENT_MODE_REPLACE&&g.config.autoUpdateElement&&a.$.form&&g._attachToForm(),g.setMode(g.config.startupMode,function(){g.resetDirty(),g.status="ready",g.fireOnce("instanceReady"),CKEDITOR.fire("instanceReady",null,g)})}),g.on("destroy",b),g}function b(){var a=this.container,b=this.element;a&&(a.clearCustomData(),a.remove()),b&&(b.clearCustomData(),this.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE&&(b.show(),this._.required&&b.setAttribute("required","required")),delete this.element)}function c(a){var b=a.name,c=a.element,d=a.elementMode,e=a.fire("uiSpace",{space:"top",html:""}).html,f=a.fire("uiSpace",{space:"bottom",html:""}).html,g=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(g.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:f?'<span id="'+a.ui.spaceId("bottom")+'" class="cke_bottom cke_reset_all" role="presentation">'+f+"</span>":"",outerEl:CKEDITOR.env.ie?"span":"div"}));d==CKEDITOR.ELEMENT_MODE_REPLACE?(c.hide(),b.insertAfter(c)):c.append(b),a.container=b,a.ui.contentsElement=a.ui.space("contents"),e&&a.ui.space("top").unselectable(),f&&a.ui.space("bottom").unselectable(),c=a.config.width,d=a.config.height,c&&b.setStyle("width",CKEDITOR.tools.cssLength(c)),d&&a.ui.space("contents").setStyle("height",CKEDITOR.tools.cssLength(d)),b.disableContextMenu(),CKEDITOR.env.webkit&&b.on("focus",function(){a.focus()}),a.fireOnce("uiReady")}CKEDITOR.replace=function(b,c){return a(b,c,null,CKEDITOR.ELEMENT_MODE_REPLACE)},CKEDITOR.appendTo=function(b,c,d){return a(b,c,d,CKEDITOR.ELEMENT_MODE_APPENDTO)},CKEDITOR.replaceAll=function(){for(var a=document.getElementsByTagName("textarea"),b=0;b<a.length;b++){var c=null,d=a[b];
5if(d.name||d.id){if("string"==typeof arguments[0]){if(!new RegExp("(?:^|\\s)"+arguments[0]+"(?:$|\\s)").test(d.className))continue}else if("function"==typeof arguments[0]&&(c={},!1===arguments[0](d,c)))continue;this.replace(d,c)}}},CKEDITOR.editor.prototype.addMode=function(a,b){(this._.modes||(this._.modes={}))[a]=b},CKEDITOR.editor.prototype.setMode=function(a,b){var c=this,d=this._.modes;if(a!=c.mode&&d&&d[a]){if(c.fire("beforeSetMode",a),c.mode){var f,e=c.checkDirty(),d=c._.previousModeData,g=0;c.fire("beforeModeUnload"),c.editable(0),c._.previousMode=c.mode,c._.previousModeData=f=c.getData(1),"source"==c.mode&&d==f&&(c.fire("lockSnapshot",{forceUpdate:!0}),g=1),c.ui.space("contents").setHtml(""),c.mode=""}else c._.previousModeData=c.getData(1);this._.modes[a](function(){c.mode=a,void 0!==e&&!e&&c.resetDirty(),g?c.fire("unlockSnapshot"):"wysiwyg"==a&&c.fire("saveSnapshot"),setTimeout(function(){c.fire("mode"),b&&b.call(c)},0)})}},CKEDITOR.editor.prototype.resize=function(a,b,c,d){var e=this.container,f=this.ui.space("contents"),g=CKEDITOR.env.webkit&&this.document&&this.document.getWindow().$.frameElement;d=d?this.container.getFirst(function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasClass("cke_inner")}):e,d.setSize("width",a,!0),g&&(g.style.width="1%");var h=(d.$.offsetHeight||0)-(f.$.clientHeight||0),e=Math.max(b-(c?0:h),0);b=c?b+h:b,f.setStyle("height",e+"px"),g&&(g.style.width="100%"),this.fire("resize",{outerHeight:b,contentsHeight:e,outerWidth:a||d.getSize("width")})},CKEDITOR.editor.prototype.getResizable=function(a){return a?this.ui.space("contents"):this.container},CKEDITOR.domReady(function(){CKEDITOR.replaceClass&&CKEDITOR.replaceAll(CKEDITOR.replaceClass)})}(),CKEDITOR.config.startupMode="wysiwyg",function(){function a(a){var j,c=a.editor,e=a.data.path,f=e.blockLimit,h=a.data.selection,i=h.getRanges()[0];(CKEDITOR.env.gecko||CKEDITOR.env.ie&&CKEDITOR.env.needsBrFiller)&&(h=b(h,e))&&(h.appendBogus(),j=CKEDITOR.env.ie),g(c,e.block,f)&&i.collapsed&&!i.getCommonAncestor().isReadOnly()&&(e=i.clone(),e.enlarge(CKEDITOR.ENLARGE_BLOCK_CONTENTS),f=new CKEDITOR.dom.walker(e),f.guard=function(a){return!d(a)||a.type==CKEDITOR.NODE_COMMENT||a.isReadOnly()},!f.checkForward()||e.checkStartOfBlock()&&e.checkEndOfBlock())&&(c=i.fixBlock(!0,c.activeEnterMode==CKEDITOR.ENTER_DIV?"div":"p"),CKEDITOR.env.needsBrFiller||(c=c.getFirst(d))&&c.type==CKEDITOR.NODE_TEXT&&CKEDITOR.tools.trim(c.getText()).match(/^(?: |\xa0)$/)&&c.remove(),j=1,a.cancel()),j&&i.select()}function b(a,b){if(a.isFake)return 0;var c=b.block||b.blockLimit,e=c&&c.getLast(d);return!c||!c.isBlockBoundary()||e&&e.type==CKEDITOR.NODE_ELEMENT&&e.isBlockBoundary()||c.is("pre")||c.getBogus()?void 0:c}function c(a){var b=a.data.getTarget();b.is("input")&&(b=b.getAttribute("type"),"submit"!=b&&"reset"!=b||a.data.preventDefault())}function d(a){return k(a)&&l(a)}function e(a,b){return function(c){var d=c.data.$.toElement||c.data.$.fromElement||c.data.$.relatedTarget;(d=d&&d.nodeType==CKEDITOR.NODE_ELEMENT?new CKEDITOR.dom.element(d):null)&&(b.equals(d)||b.contains(d))||a.call(this,c)}}function f(a){function b(a){return function(b,e){if(e&&b.type==CKEDITOR.NODE_ELEMENT&&b.is(f)&&(c=b),!(e||!d(b)||a&&n(b)))return!1}}var c,e=a.getRanges()[0];a=a.root;var f={table:1,ul:1,ol:1,dl:1};if(e.startPath().contains(f)){var g=e.clone();if(g.collapse(1),g.setStartAt(a,CKEDITOR.POSITION_AFTER_START),a=new CKEDITOR.dom.walker(g),a.guard=b(),a.checkBackward(),c)return g=e.clone(),g.collapse(),g.setEndAt(c,CKEDITOR.POSITION_AFTER_END),a=new CKEDITOR.dom.walker(g),a.guard=b(!0),c=!1,a.checkForward(),c}return null}function g(a,b,c){return!1!==a.config.autoParagraph&&a.activeEnterMode!=CKEDITOR.ENTER_BR&&(a.editable().equals(c)&&!b||b&&"true"==b.getAttribute("contenteditable"))}function h(a){return a.activeEnterMode!=CKEDITOR.ENTER_BR&&!1!==a.config.autoParagraph&&(a.activeEnterMode==CKEDITOR.ENTER_DIV?"div":"p")}function i(a){var b=a.editor;b.getSelection().scrollIntoView(),setTimeout(function(){b.fire("saveSnapshot")},0)}function j(a,b,c){var d=a.getCommonAncestor(b);for(b=a=c?b:a;(a=a.getParent())&&!d.equals(a)&&1==a.getChildCount();)b=a;b.remove()}var k,l,m,n,o,p,q,r,s;CKEDITOR.editable=CKEDITOR.tools.createClass({base:CKEDITOR.dom.element,$:function(a,b){this.base(b.$||b),this.editor=a,this.status="unloaded",this.hasFocus=!1,this.setup()},proto:{focus:function(){var a;if(CKEDITOR.env.webkit&&!this.hasFocus&&(a=this.editor._.previousActive||this.getDocument().getActive(),this.contains(a)))return void a.focus();try{this.$[CKEDITOR.env.ie&&this.getDocument().equals(CKEDITOR.document)?"setActive":"focus"]()}catch(a){if(!CKEDITOR.env.ie)throw a}CKEDITOR.env.safari&&!this.isInline()&&(a=CKEDITOR.document.getActive(),a.equals(this.getWindow().getFrame())||this.getWindow().focus())},on:function(a,b){var c=Array.prototype.slice.call(arguments,0);
5return CKEDITOR.env.ie&&/^focus|blur$/.exec(a)&&(a="focus"==a?"focusin":"focusout",b=e(b,this),c[0]=a,c[1]=b),CKEDITOR.dom.element.prototype.on.apply(this,c)},attachListener:function(a){!this._.listeners&&(this._.listeners=[]);var b=Array.prototype.slice.call(arguments,1),b=a.on.apply(a,b);return this._.listeners.push(b),b},clearListeners:function(){var a=this._.listeners;try{for(;a.length;)a.pop().removeListener()}catch(a){}},restoreAttrs:function(){var b,c,a=this._.attrChanges;for(c in a)a.hasOwnProperty(c)&&(b=a[c],null!==b?this.setAttribute(c,b):this.removeAttribute(c))},attachClass:function(a){var b=this.getCustomData("classes"); 6this.hasClass(a)||(!b&&(b=[]),b.push(a),this.setCustomData("classes",b),this.addClass(a))},changeAttr:function(a,b){var c=this.getAttribute(a);b!==c&&(!this._.attrChanges&&(this._.attrChanges={}),a in this._.attrChanges||(this._.attrChanges[a]=c),this.setAttribute(a,b))},insertText:function(a){this.editor.focus(),this.insertHtml(this.transformPlainTextToHtml(a),"text")},transformPlainTextToHtml:function(a){var b=this.editor.getSelection().getStartElement().hasAscendant("pre",!0)?CKEDITOR.ENTER_BR:this.editor.activeEnterMode;return CKEDITOR.tools.transformPlainTextToHtml(a,b)},insertHtml:function(a,b,c){var d=this.editor;d.focus(),d.fire("saveSnapshot"),c||(c=d.getSelection().getRanges()[0]),p(this,b||"html",a,c),c.select(),i(this),this.editor.fire("afterInsertHtml",{})},insertHtmlIntoRange:function(a,b,c){p(this,c||"html",a,b),this.editor.fire("afterInsertHtml",{intoRange:b})},insertElement:function(a,b){var c=this.editor;c.focus(),c.fire("saveSnapshot");var e=c.activeEnterMode,c=c.getSelection(),f=a.getName(),f=CKEDITOR.dtd.$block[f];b||(b=c.getRanges()[0]),this.insertElementIntoRange(a,b)&&(b.moveToPosition(a,CKEDITOR.POSITION_AFTER_END),f&&((f=a.getNext(function(a){return d(a)&&!n(a)}))&&f.type==CKEDITOR.NODE_ELEMENT&&f.is(CKEDITOR.dtd.$block)?f.getDtd()["#"]?b.moveToElementEditStart(f):b.moveToElementEditEnd(a):f||e==CKEDITOR.ENTER_BR||(f=b.fixBlock(!0,e==CKEDITOR.ENTER_DIV?"div":"p"),b.moveToElementEditStart(f)))),c.selectRanges([b]),i(this)},insertElementIntoSelection:function(a){this.insertElement(a)},insertElementIntoRange:function(a,b){var c=this.editor,d=c.config.enterMode,e=a.getName(),f=CKEDITOR.dtd.$block[e];if(b.checkReadOnly())return!1;b.deleteContents(1),b.startContainer.type==CKEDITOR.NODE_ELEMENT&&b.startContainer.is({tr:1,table:1,tbody:1,thead:1,tfoot:1})&&q(b);var g,h;if(f)for(;(g=b.getCommonAncestor(0,1))&&(h=CKEDITOR.dtd[g.getName()])&&(!h||!h[e]);)g.getName()in CKEDITOR.dtd.span?b.splitElement(g):b.checkStartOfBlock()&&b.checkEndOfBlock()?(b.setStartBefore(g),b.collapse(!0),g.remove()):b.splitBlock(d==CKEDITOR.ENTER_DIV?"div":"p",c.editable());return b.insertNode(a),!0},setData:function(a,b){b||(a=this.editor.dataProcessor.toHtml(a)),this.setHtml(a),this.fixInitialSelection(),"unloaded"==this.status&&(this.status="ready"),this.editor.fire("dataReady")},getData:function(a){var b=this.getHtml();return a||(b=this.editor.dataProcessor.toDataFormat(b)),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 d,a=c.getDocument().$,b=a.getSelection();a:if(b.anchorNode&&b.anchorNode==c.$)d=!0;else{if(CKEDITOR.env.webkit&&(d=c.getDocument().getActive())&&d.equals(c)&&!b.anchorNode){d=!0;break a}d=void 0}d&&(d=new CKEDITOR.dom.range(c),d.moveToElementEditStart(c),a=a.createRange(),a.setStart(d.startContainer.$,d.startOffset),a.collapse(!0),b.removeAllRanges(),b.addRange(a))}function b(){var a=c.getDocument().$,b=a.selection,d=c.getDocument().getActive();"None"==b.type&&d.equals(c)&&(b=new CKEDITOR.dom.range(c),a=a.body.createTextRange(),b.moveToElementEditStart(c),b=b.startContainer,b.type!=CKEDITOR.NODE_ELEMENT&&(b=b.getParent()),a.moveToElementText(b.$),a.collapse(!0),a.select())}var c=this;CKEDITOR.env.ie&&(9>CKEDITOR.env.version||CKEDITOR.env.quirks)?this.hasFocus&&(this.focus(),b()):this.hasFocus?(this.focus(),a()):this.once("focus",function(){a()},null,null,-999)},getHtmlFromRange:function(a){return a.collapsed?new CKEDITOR.dom.documentFragment(a.document):(a={doc:this.getDocument(),range:a.clone()},r.eol.detect(a,this),r.bogus.exclude(a),r.cell.shrink(a),a.fragment=a.range.cloneContents(),r.tree.rebuild(a,this),r.eol.f
6ix(a,this),new CKEDITOR.dom.documentFragment(a.fragment.$))},extractHtmlFromRange:function(a,b){var c=s,d={range:a,doc:a.document},e=this.getHtmlFromRange(a);if(a.collapsed)return a.optimize(),e;a.enlarge(CKEDITOR.ENLARGE_INLINE,1),c.table.detectPurge(d),d.bookmark=a.createBookmark(),delete d.range;var f=this.editor.createRange();if(f.moveToPosition(d.bookmark.startNode,CKEDITOR.POSITION_BEFORE_START),d.targetBookmark=f.createBookmark(),c.list.detectMerge(d,this),c.table.detectRanges(d,this),c.block.detectMerge(d,this),d.tableContentsRanges?(c.table.deleteRanges(d),a.moveToBookmark(d.bookmark),d.range=a):(a.moveToBookmark(d.bookmark),d.range=a,a.extractContents(c.detectExtractMerge(d))),a.moveToBookmark(d.targetBookmark),a.optimize(),c.fixUneditableRangePosition(a),c.list.merge(d,this),c.table.purge(d,this),c.block.merge(d,this),b){if(c=a.startPath(),d=a.checkStartOfBlock()&&a.checkEndOfBlock()&&c.block&&!a.root.equals(c.block)){a:{var g,d=c.block.getElementsByTag("span"),f=0;if(d)for(;g=d.getItem(f++);)if(!l(g)){d=!0;break a}d=!1}d=!d}d&&(a.moveToPosition(c.block,CKEDITOR.POSITION_BEFORE_START),c.block.remove())}else c.autoParagraph(this.editor,a),m(a.startContainer)&&a.startContainer.appendBogus();return a.startContainer.mergeSiblings(),e},setup:function(){var a=this.editor;if(this.attachListener(a,"beforeGetData",function(){var b=this.getData();this.is("textarea")||!1!==a.config.ignoreEmptyParagraph&&(b=b.replace(o,function(a,b){return b})),a.setData(b,null,1)},this),this.attachListener(a,"getSnapshot",function(a){a.data=this.getData(1)},this),this.attachListener(a,"afterSetData",function(){this.setData(a.getData(1))},this),this.attachListener(a,"loadSnapshot",function(a){this.setData(a.data,1)},this),this.attachListener(a,"beforeFocus",function(){var b=a.getSelection();(b=b&&b.getNative())&&"Control"==b.type||this.focus()},this),this.attachListener(a,"insertHtml",function(a){this.insertHtml(a.data.dataValue,a.data.mode,a.data.range)},this),this.attachListener(a,"insertElement",function(a){this.insertElement(a.data)},this),this.attachListener(a,"insertText",function(a){this.insertText(a.data)},this),this.setReadOnly(a.readOnly),this.attachClass("cke_editable"),a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?this.attachClass("cke_editable_inline"):a.elementMode!=CKEDITOR.ELEMENT_MODE_REPLACE&&a.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO||this.attachClass("cke_editable_themed"),this.attachClass("cke_contents_"+a.config.contentsLangDirection),a.keystrokeHandler.blockedKeystrokes[8]=+a.readOnly,a.keystrokeHandler.attach(this),this.on("blur",function(){this.hasFocus=!1},null,null,-1),this.on("focus",function(){this.hasFocus=!0},null,null,-1),a.focusManager.add(this),this.equals(CKEDITOR.document.getActive())&&(this.hasFocus=!0,a.once("contentDom",function(){a.focusManager.focus(this)},this)),this.isInline()&&this.changeAttr("tabindex",a.tabIndex),!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 g=CKEDITOR.getCss();if(g){var e=b.getHead(),h=e.getCustomData("stylesheet");h?g!=h.getText()&&(CKEDITOR.env.ie&&9>CKEDITOR.env.version?h.$.styleSheet.cssText=g:h.setText(g)):(g=b.appendStyleText(g),g=new CKEDITOR.dom.element(g.ownerNode||g.owningElement),e.setCustomData("stylesheet",g),g.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){a=a.data;var b=new CKEDITOR.dom.elementPath(a.getTarget(),this).contains("a");b&&2!=a.$.button&&b.isReadOnly()&&a.preventDefault()});var i={8:1,46:1};this.attachListener(a,"key",function(b){if(a.readOnly)return!0;var d,c=b.data.domEvent.getKey();if(c in i){b=a.getSelection();var e,j,l,m,g=b.getRanges()[0],h=g.startPath(),c=8==c;CKEDITOR.env.ie&&11>CKEDITOR.env.version&&(e=b.getSelectedElement())||(e=f(b))?(a.fire("saveSnapshot"),g.moveToPosition(e,CKEDITOR.POSITION_BEFORE_START),e.remove(),g.select(),a.fire("saveSnapshot"),d=1):g.collapsed&&((j=h.block)&&(m=j[c?"getPrevious":"getNext"](k))&&m.type==CKEDITOR.NODE_ELEMENT&&m.is("table")&&g[c?"checkStartOfBlock":"checkEndOfBlock"]()?(a.fire("saveSnapshot"),g[c?"checkEndOfBlock":"checkStartOfBlock"]()&&j.remove(),g["moveToElementEdit"+(c?"End":"Start")](m),g.select(),a.fire("saveSnapshot"),d=1):h.blockLimit&&h.blockLimit.is("td")&&(l=h.blockLimit.getAscendant("table"))&&g.checkBoundaryOfElement(l,c?CKEDITOR.START:CKEDITOR.END)&&(m=l[c?"getPrevious":"getNext"](k))?(a.fire("saveSnapshot"),g["moveToElementEdit"+(c?"End":"Start")](m),g.checkStartOfBlock()&&g.checkEndOfBlock()?m.remove():g.select(),a.fire("saveSnapshot"),d=1):(l=h.contains(["td","th","caption"]))&&g.checkBoundaryOfElement(l,c?CKEDITOR.START:CKEDITOR.END)&&(d=1))}return!d}),a.blockless&&CKEDITOR.env.ie&&CKEDITOR.env.needsBrFiller&&this.attachListener(this,"keyup",function(b){b.data.getKeystroke()in i&&!this.getFirst(d)&&(this.appendBogus(),b=a.createRange(),b.moveToPosition(this,CKEDITOR.POSITION_AFTER_START),b.select())}),this.attachListener(this,"dblclick",function(b){return!a.readOnly&&(b={element:b.data.getTarget()},void a.fire("doubleclick",b))}),CKEDITOR.env.ie&&this.attachListener(this,"click",c),CKEDITOR.env.ie&&!CKEDITOR.env.edge||this.attachListener(this,"mousedown",function(b){var c=b.data.getTarget();
6c.is("img","hr","input","textarea","select")&&!c.isReadOnly()&&(a.getSelection().selectElement(c),c.is("input","textarea","select")&&b.data.preventDefault())}),CKEDITOR.env.edge&&this.attachListener(this,"mouseup",function(b){(b=b.data.getTarget())&&b.is("img")&&a.getSelection().selectElement(b)}),CKEDITOR.env.gecko&&this.attachListener(this,"mouseup",function(b){if(2==b.data.$.button&&(b=b.data.getTarget(),!b.getOuterHtml().replace(o,""))){var c=a.createRange();c.moveToElementEditStart(b),c.select(!0)}}),CKEDITOR.env.webkit&&(this.attachListener(this,"click",function(a){a.data.getTarget().is("input","select")&&a.data.preventDefault()}),this.attachListener(this,"mouseup",function(a){a.data.getTarget().is("input","textarea")&&a.data.preventDefault()})),CKEDITOR.env.webkit&&this.attachListener(a,"key",function(b){if(a.readOnly)return!0;if(b=b.data.domEvent.getKey(),b in i){var c=8==b,d=a.getSelection().getRanges()[0];if(b=d.startPath(),d.collapsed)a:{var e=b.block;if(e&&d[c?"checkStartOfBlock":"checkEndOfBlock"]()&&d.moveToClosestEditablePosition(e,!c)&&d.collapsed){if(d.startContainer.type==CKEDITOR.NODE_ELEMENT){var f=d.startContainer.getChild(d.startOffset-(c?1:0));if(f&&f.type==CKEDITOR.NODE_ELEMENT&&f.is("hr")){a.fire("saveSnapshot"),f.remove(),b=!0;break a}}if(d=d.startPath().block,!d||d&&d.contains(e))b=void 0;else{a.fire("saveSnapshot");var g;(g=(c?d:e).getBogus())&&g.remove(),g=a.getSelection(),f=g.createBookmarks(),(c?e:d).moveChildren(c?d:e,!1),b.lastElement.mergeSiblings(),j(e,d,!c),g.selectBookmarks(f),b=!0}}else b=!1}else c=d,g=b.block,d=c.endPath().block,g&&d&&!g.equals(d)?(a.fire("saveSnapshot"),(e=g.getBogus())&&e.remove(),c.enlarge(CKEDITOR.ENLARGE_INLINE),c.deleteContents(),d.getParent()&&(d.moveChildren(g,!1),b.lastElement.mergeSiblings(),j(g,d,!0)),c=a.getSelection().getRanges()[0],c.collapse(1),c.optimize(),""===c.startContainer.getHtml()&&c.startContainer.appendBogus(),c.select(),b=!0):b=!1;if(!b)return;return a.getSelection().scrollIntoView(),a.fire("saveSnapshot"),!1}},this,null,100)}}},_:{detach:function(){this.editor.setData(this.editor.getData(),0,1),this.clearListeners(),this.restoreAttrs();var a;if(a=this.removeCustomData("classes"))for(;a.length;)this.removeClass(a.pop());if(!this.is("textarea")){a=this.getDocument();var b=a.getHead();if(b.getCustomData("stylesheet")){var c=a.getCustomData("stylesheet_ref");--c?a.setCustomData("stylesheet_ref",c):(a.removeCustomData("stylesheet_ref"),b.removeCustomData("stylesheet").remove())}}this.editor.fire("contentDomUnload"),delete this.editor}}}),CKEDITOR.editor.prototype.editable=function(a){var b=this._.editable;return b&&a?0:(arguments.length&&(b=this._.editable=a?a instanceof CKEDITOR.editable?a:new CKEDITOR.editable(this,a):(b&&b.detach(),null)),b)},CKEDITOR.on("instanceLoaded",function(b){var c=b.editor;c.on("insertElement",function(a){a=a.data,a.type==CKEDITOR.NODE_ELEMENT&&(a.is("input")||a.is("textarea"))&&("false"!=a.getAttribute("contentEditable")&&a.data("cke-editable",a.hasAttribute("contenteditable")?"true":"1"),a.setAttribute("contentEditable",!1))}),c.on("selectionChange",function(b){if(!c.readOnly){var d=c.getSelection();d&&!d.isLocked&&(d=c.checkDirty(),c.fire("lockSnapshot"),a(b),c.fire("unlockSnapshot"),!d&&c.resetDirty())}})}),CKEDITOR.on("instanceCreated",function(a){var b=a.editor;b.on("mode",function(){var a=b.editable();if(a&&a.isInline()){var c=b.title;a.changeAttr("role","textbox"),a.changeAttr("aria-label",c),c&&a.changeAttr("title",c);var d=b.fire("ariaEditorHelpLabel",{}).label;if(d&&(c=this.ui.space(this.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?"top":"contents"))){var e=CKEDITOR.tools.getNextId(),d=CKEDITOR.dom.element.createFromHtml('<span id="'+e+'" class="cke_voice_label">'+d+"</span>");c.append(d),a.changeAttr("aria-describedby",e)}}})}),CKEDITOR.addCss(".cke_editable{cursor:text}.cke_editable img,.cke_editable input,.cke_editable textarea{cursor:default}"),k=CKEDITOR.dom.walker.whitespaces(!0),l=CKEDITOR.dom.walker.bookmark(!1,!0),m=CKEDITOR.dom.walker.empty(),n=CKEDITOR.dom.walker.bogus(),o=/(^|<body\b[^>]*>)\s*<(p|div|address|h\d|center|pre)[^>]*>\s*(?:<br[^>]*>| |\u00A0| )?\s*(:?<\/\2>)?\s*(?=$|<\/body>)/gi,p=function(){function a(a){return a.type==CKEDITOR.NODE_ELEMENT}function b(c,d){var e,f,g,h,i=[],j=d.range.startContainer;e=d.range.startPath();for(var j=k[j.getName()],l=0,m=c.getChildren(),n=m.count(),o=-1,p=-1,q=0,r=e.contains(k.$list);l<n;++l)e=m.getItem(l),a(e)?(g=e.getName(),r&&g in CKEDITOR.dtd.$list?i=i.concat(b(e,d)):(h=!!j[g],"br"!=g||!e.data("cke-eol")||l&&l!=n-1||(q=(f=l?i[l-1].node:m.getItem(l+1))&&(!a(f)||!f.is("br")),f=f&&a(f)&&k.$block[f.getName()]),-1!=o||h||(o=l),h||(p=l),i.push({isElement:1,isLineBreak:q,isBlock:e.isBlockBoundary(),hasBlockSibling:f,node:e,name:g,allowed:h}),f=q=0)):i.push({isElement:0,node:e,allowed:1});return-1<o&&(i[o].firstNotAllowed=1),-1<p&&(i[p].lastNotAllowed=1),i}function c(b,d){var h,e=[],f=b.getChildren(),g=f.count(),i=0,j=k[d],l=!b.is(k.$inline)||b.is("br");for(l&&e.push(" ");i<g;i++)h=f.getItem(i),a(h)&&!h.is(j)?e=e.concat(c(h,d)):e.push(h);return l&&e.push(" "),e}function e(b){return a(b.startContainer)&&b.startContainer.getChild(b.startOffset-1)}function f(b){return b&&a(b)&&(b.is(k.$removeEmpty)||b.is("a")&&!b.isBlockBoundary())}function i(b,c,d,e){var g,h,f=b.clone();f.setEndAt(c,CKEDITOR.POSITION_BEFORE_END),(g=new CKEDITOR.dom.walker(f).next())&&a(g)&&l[g.getName()]&&(h=g.getPrevious())&&a(h)&&!h.getParent().equals(b.startContainer)&&d.contains(h)&&e.contains(g)&&g.isIdentical(h)&&(g.moveChildren(h),g.remove(),i(b,c,d,e))}function j(b,c){function d(b,c){if(c.isBlock&&c.isElement&&!c.node.is("br")&&a(b)&&b.is("br"))return b.remove(),1}var e=c.endContainer.getChild(c.endOffset),f=c.endContainer.getChild(c.endOffset-1);e&&d(e,b[b.length-1]),f&&d(f,b[0])&&(c.setEnd(c.endContainer,c.endOffset-1),c.collapse())}var k=CKEDITOR.dtd,l={p:1,div:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1,ul:1,ol:1,li:1,pre:1,dl:1,blockquote:1},m={p:1,div:1,h1:1,h2:1,h3:1,h4:1,h5:1,h6:1},n=CKEDITOR.tools.extend({},k.$inline);return delete n.br,function(l,o,p,q){var r=l.editor,s=!1;if("unfiltered_html"==o&&(o="html",s=!0),!q.checkReadOnly()){var t=new CKEDITOR.dom.elementPath(q.startContainer,q.root).blockLimit||q.root;l={type:o,dontFilter:s,editable:l,editor:r,range:q,blockLimit:t,mergeCandidates:[],zombies:[]},o=l.range,q=l.mergeCandidates;var u,v;if("text"==l.type&&o.shrink(CKEDITOR.SHRINK_ELEMENT,!0,!1)&&(u=CKEDITOR.dom.element.createFromHtml("<span> </span>",o.document),o.insertNode(u),o.setStartAfter(u)),s=new CKEDITOR.dom.elementPath(o.startContainer),l.endPath=t=new CKEDITOR.dom.elementPath(o.endContainer),!o.collapsed){var r=t.block||t.blockLimit,w=o.getCommonAncestor();r&&!r.equals(w)&&!r.contains(w)&&o.checkEndOfBlock()&&l.zombies.push(r),o.deleteContents()}for(;(v=e(o))&&a(v)&&v.isBlockBoundary()&&s.contains(v);)o.moveToPosition(v,CKEDITOR.POSITION_BEFORE_END);for(i(o,l.blockLimit,s,t),u&&(o.setEndBefore(u),o.collapse(),u.remove()),u=o.startPath(),(r=u.contains(f,!1,1))&&(o.splitElement(r),l.inlineStylesRoot=r,l.inlineStylesPeak=u.lastElement),u=o.createBookmark(),(r=u.startNode.getPrevious(d))&&a(r)&&f(r)&&q.push(r),(r=u.startNode.getNext(d))&&a(r)&&f(r)&&q.push(r),r=u.startNode;(r=r.getParent())&&f(r);)q.push(r);if(o.moveToBookmark(u),u=p){if(u=l.range,"text"==l.type&&l.inlineStylesRoot){for(v=l.inlineStylesPeak,o=v.getDocument().createText("{cke-peak}"),q=l.inlineStylesRoot.getParent();!v.equals(q);)o=o.appendTo(v.clone()),v=v.getParent();p=o.getOuterHtml().split("{cke-peak}").join(p)}if(v=l.blockLimit.getName(),/^\s+|\s+$/.test(p)&&"span"in CKEDITOR.dtd[v]){var x='<span data-cke-marker="1"> </span>';p=x+p+x}if(p=l.editor.dataProcessor.toHtml(p,{context:null,fixForBody:!1,protectedWhitespace
6s:!!x,dontFilter:l.dontFilter,filter:l.editor.activeFilter,enterMode:l.editor.activeEnterMode}),v=u.document.createElement("body"),v.setHtml(p),x&&(v.getFirst().remove(),v.getLast().remove()),(x=u.startPath().block)&&(1!=x.getChildCount()||!x.getBogus()))a:{var y;if(1==v.getChildCount()&&a(y=v.getFirst())&&y.is(m)&&!y.hasAttribute("contenteditable")){for(x=y.getElementsByTag("*"),u=0,q=x.count();u<q;u++)if(o=x.getItem(u),!o.is(n))break a;y.moveChildren(y.getParent(1)),y.remove()}}l.dataWrapper=v,u=p}if(u){y=l.range,u=y.document;var z;v=l.blockLimit,q=0;var A,B,C,x=[];p=r=0;var D,E;o=y.startContainer;var F,s=l.endPath.elements[0],t=s.getPosition(o),w=!(!s.getCommonAncestor(o)||t==CKEDITOR.POSITION_IDENTICAL||t&CKEDITOR.POSITION_CONTAINS+CKEDITOR.POSITION_IS_CONTAINED);for(o=b(l.dataWrapper,l),j(o,y);q<o.length;q++){if(t=o[q],z=t.isLineBreak){z=y,D=v;var G=void 0,H=void 0;t.hasBlockSibling?z=1:(G=z.startContainer.getAscendant(k.$block,1))&&G.is({div:1,p:1})?(H=G.getPosition(D),H==CKEDITOR.POSITION_IDENTICAL||H==CKEDITOR.POSITION_CONTAINS?z=0:(D=z.splitElement(G),z.moveToPosition(D,CKEDITOR.POSITION_AFTER_START),z=1)):z=0}if(z)p=0<q;else{if(z=y.startPath(),!t.isBlock&&g(l.editor,z.block,z.blockLimit)&&(C=h(l.editor))&&(C=u.createElement(C),C.appendBogus(),y.insertNode(C),CKEDITOR.env.needsBrFiller&&(A=C.getBogus())&&A.remove(),y.moveToPosition(C,CKEDITOR.POSITION_BEFORE_END)),(z=y.startPath().block)&&!z.equals(B)&&((A=z.getBogus())&&(A.remove(),x.push(z)),B=z),t.firstNotAllowed&&(r=1),r&&t.isElement){for(z=y.startContainer,D=null;z&&!k[z.getName()][t.name];){if(z.equals(v)){z=null;break}D=z,z=z.getParent()}if(z)D&&(E=y.splitElement(D),l.zombies.push(E),l.zombies.push(D));else{D=v.getName(),F=!q,z=q==o.length-1,D=c(t.node,D);for(var G=[],H=D.length,I=0,J=void 0,K=0,L=-1;I<H;I++)J=D[I]," "==J?(K||F&&!I||(G.push(new CKEDITOR.dom.text(" ")),L=G.length),K=1):(G.push(J),K=0);z&&L==G.length&&G.pop(),F=G}}if(F){for(;z=F.pop();)y.insertNode(z);F=0}else y.insertNode(t.node);t.lastNotAllowed&&q<o.length-1&&((E=w?s:E)&&y.setEndAt(E,CKEDITOR.POSITION_AFTER_START),r=0),y.collapse()}}1!=o.length?A=!1:(A=o[0],A=A.isElement&&"false"==A.node.getAttribute("contenteditable")),A&&(p=!0,z=o[0].node,y.setStartAt(z,CKEDITOR.POSITION_BEFORE_START),y.setEndAt(z,CKEDITOR.POSITION_AFTER_END)),l.dontMoveCaret=p,l.bogusNeededBlocks=x}A=l.range;var M;for(E=l.bogusNeededBlocks,F=A.createBookmark();B=l.zombies.pop();)B.getParent()&&(C=A.clone(),C.moveToElementEditStart(B),C.removeEmptyBlocksAtEnd());if(E)for(;B=E.pop();)CKEDITOR.env.needsBrFiller?B.appendBogus():B.append(A.document.createText("Â "));for(;B=l.mergeCandidates.pop();)B.mergeSiblings();if(A.moveToBookmark(F),!l.dontMoveCaret){for(B=e(A);B&&a(B)&&!B.is(k.$empty);){if(B.isBlockBoundary())A.moveToPosition(B,CKEDITOR.POSITION_BEFORE_END);else{if(f(B)&&B.getHtml().match(/(\s| )$/g)){M=null;break}M=A.clone(),M.moveToPosition(B,CKEDITOR.POSITION_BEFORE_END)}B=B.getLast(d)}M&&A.moveToRange(M)}}}}(),q=function(){function a(a){return a=new CKEDITOR.dom.walker(a),a.guard=function(a,b){return!b&&(a.type==CKEDITOR.NODE_ELEMENT?a.is(CKEDITOR.dtd.$tableContent):void 0)},a.evaluator=function(a){return a.type==CKEDITOR.NODE_ELEMENT},a}function b(a,b,c){return b=a.getDocument().createElement(b),a.append(b,c),b}function c(a){var c,b=a.count();for(b;0<b--;)c=a.getItem(b),CKEDITOR.tools.trim(c.getHtml())||(c.appendBogus(),CKEDITOR.env.ie&&9>CKEDITOR.env.version&&c.getChildCount()&&c.getFirst().remove())}return function(d){var e=d.startContainer,f=e.getAscendant("table",1),g=!1;c(f.getElementsByTag("td")),c(f.getElementsByTag("th")),f=d.clone(),f.setStart(e,0),f=a(f).lastBackward(),f||(f=d.clone(),f.setEndAt(e,CKEDITOR.POSITION_BEFORE_END),f=a(f).lastForward(),g=!0),f||(f=e),f.is("table")?(d.setStartAt(f,CKEDITOR.POSITION_BEFORE_START),d.collapse(!0),f.remove()):(f.is({tbody:1,thead:1,tfoot:1})&&(f=b(f,"tr",g)),f.is("tr")&&(f=b(f,f.getParent().is("thead")?"th":"td",g)),(e=f.getBogus())&&e.remove(),d.moveToPosition(f,g?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_END))}}(),r={eol:{detect:function(a,b){var c=a.range,d=c.clone(),e=c.clone(),f=new CKEDITOR.dom.elementPath(c.startContainer,b),g=new CKEDITOR.dom.elementPath(c.endContainer,b);d.collapse(1),e.collapse(),f.block&&d.checkBoundaryOfElement(f.block,CKEDITOR.END)&&(c.setStartAfter(f.block),a.prependEolBr=1),g.block&&e.checkBoundaryOfElement(g.block,CKEDITOR.START)&&(c.setEndBefore(g.block),a.appendEolBr=1)},fix:function(a,b){var d,c=b.getDocument();a.appendEolBr&&(d=this.createEolBr(c),a.fragment.append(d)),!a.prependEolBr||d&&!d.getPrevious()||a.fragment.append(this.createEolBr(c),1)},createEolBr:function(a){return a.createElement("br",{attributes:{"data-cke-eol":1}})}},bogus:{exclude:function(a){var b=a.range.getBoundaryNodes(),c=b.startNode,b=b.endNode;!b||!n(b)||c&&c.equals(b)||a.range.setEndBefore(b)}},tree:{rebuild:function(a,b){var g,c=a.range,d=c.getCommonAncestor(),e=new CKEDITOR.dom.elementPath(d,b),f=new CKEDITOR.dom.elementPath(c.startContainer,b),c=new CKEDITOR.dom.elementPath(c.endContainer,b);if(d.type==CKEDITOR.NODE_TEXT&&(d=d.getParent()),e.blockLimit.is({tr:1,table:1})){var h=e.contains("table").getParent();g=function(a){return!a.equals(h)}}else if(e.block&&e.block.is(CKEDITOR.dtd.$listItem)&&(f=f.contains(CKEDITOR.dtd.$list),c=c.contains(CKEDITOR.dtd.$list),!f.equals(c))){var i=e.contains(CKEDITOR.dtd.$list).getParent();g=function(a){return!a.equals(i)}}g||(g=function(a){return!a.equals(e.block)&&!a.equals(e.blockLimit)}),this.rebuildFragment(a,b,d,g)},rebuildFragment:function(a,b,c,d){for(var e;c&&!c.equals(b)&&d(c);)e=c.clone(0,1),a.fragment.appendTo(e),a.fragment=e,c=c.getParent()}},cell:{shrink:function(a){a=a.range;var b=a.startContainer,c=a.endContainer,d=a.startOffset,e=a.endOffset;b.type==CKEDITOR.NODE_ELEMENT&&b.equals(c)&&b.is("tr")&&++d==e&&a.shrink(CKEDITOR.SHRINK_TEXT)}}},s=function(){function a(a,b){var c=a.getParent();c.is(CKEDITOR.dtd.$inline)&&a[b?"insertBefore":"insertAfter"](c)}
6function b(b,c,d){a(c),a(d,1);for(var e;e=d.getNext();)e.insertAfter(c),c=e;m(b)&&b.remove()}function c(a,b){var c=new CKEDITOR.dom.range(a);return c.setStartAfter(b.startNode),c.setEndBefore(b.endNode),c}return{list:{detectMerge:function(a,b){var d=c(b,a.bookmark),e=d.startPath(),f=d.endPath(),g=e.contains(CKEDITOR.dtd.$list),h=f.contains(CKEDITOR.dtd.$list);a.mergeList=g&&h&&g.getParent().equals(h.getParent())&&!g.equals(h),a.mergeListItems=e.block&&f.block&&e.block.is(CKEDITOR.dtd.$listItem)&&f.block.is(CKEDITOR.dtd.$listItem),(a.mergeList||a.mergeListItems)&&(d=d.clone(),d.setStartBefore(a.bookmark.startNode),d.setEndAfter(a.bookmark.endNode),a.mergeListBookmark=d.createBookmark())},merge:function(a,c){if(a.mergeListBookmark){var d=a.mergeListBookmark.startNode,e=a.mergeListBookmark.endNode,f=new CKEDITOR.dom.elementPath(d,c),g=new CKEDITOR.dom.elementPath(e,c);if(a.mergeList){var h=f.contains(CKEDITOR.dtd.$list),i=g.contains(CKEDITOR.dtd.$list);h.equals(i)||(i.moveChildren(h),i.remove())}a.mergeListItems&&(f=f.contains(CKEDITOR.dtd.$listItem),g=g.contains(CKEDITOR.dtd.$listItem),f.equals(g)||b(g,d,e)),d.remove(),e.remove()}}},block:{detectMerge:function(a,b){if(!a.tableContentsRanges&&!a.mergeListBookmark){var c=new CKEDITOR.dom.range(b);c.setStartBefore(a.bookmark.startNode),c.setEndAfter(a.bookmark.endNode),a.mergeBlockBookmark=c.createBookmark()}},merge:function(a,c){if(a.mergeBlockBookmark&&!a.purgeTableBookmark){var d=a.mergeBlockBookmark.startNode,e=a.mergeBlockBookmark.endNode,f=new CKEDITOR.dom.elementPath(d,c),g=new CKEDITOR.dom.elementPath(e,c),f=f.block,g=g.block;f&&g&&!f.equals(g)&&b(g,d,e),d.remove(),e.remove()}}},table:function(){function a(a){var e,c=[],f=new CKEDITOR.dom.walker(a),g=a.startPath().contains(d),h=a.endPath().contains(d),i={};return f.guard=function(f,j){if(f.type==CKEDITOR.NODE_ELEMENT){var k="visited_"+(j?"out":"in");if(f.getCustomData(k))return;CKEDITOR.dom.element.setMarker(i,f,k,1)}j&&g&&f.equals(g)?(e=a.clone(),e.setEndAt(g,CKEDITOR.POSITION_BEFORE_END),c.push(e)):!j&&h&&f.equals(h)?(e=a.clone(),e.setStartAt(h,CKEDITOR.POSITION_AFTER_START),c.push(e)):((k=!j)&&(k=f.type==CKEDITOR.NODE_ELEMENT&&f.is(d)&&(!g||b(f,g))&&(!h||b(f,h))),k&&(e=a.clone(),e.selectNodeContents(f),c.push(e)))},f.lastForward(),CKEDITOR.dom.element.clearAllMarkers(i),c}function b(a,b){var c=CKEDITOR.POSITION_CONTAINS+CKEDITOR.POSITION_IS_CONTAINED,d=a.getPosition(b);return d!==CKEDITOR.POSITION_IDENTICAL&&0===(d&c)}var d={td:1,th:1,caption:1};return{detectPurge:function(a){var b=a.range,c=b.clone();c.enlarge(CKEDITOR.ENLARGE_ELEMENT);var c=new CKEDITOR.dom.walker(c),e=0;if(c.evaluator=function(a){a.type==CKEDITOR.NODE_ELEMENT&&a.is(d)&&++e},c.checkForward(),1<e){var c=b.startPath().contains("table"),f=b.endPath().contains("table");c&&f&&b.checkBoundaryOfElement(c,CKEDITOR.START)&&b.checkBoundaryOfElement(f,CKEDITOR.END)&&(b=a.range.clone(),b.setStartBefore(c),b.setEndAfter(f),a.purgeTableBookmark=b.createBookmark())}},detectRanges:function(e,f){var i,j,g=c(f,e.bookmark),h=g.clone(),k=g.getCommonAncestor();k.is(CKEDITOR.dtd.$tableContent)&&!k.is(d)&&(k=k.getAscendant("table",!0)),j=k,k=new CKEDITOR.dom.elementPath(g.startContainer,j),j=new CKEDITOR.dom.elementPath(g.endContainer,j),k=k.contains("table"),j=j.contains("table"),(k||j)&&(k&&j&&b(k,j)?(e.tableSurroundingRange=h,h.setStartAt(k,CKEDITOR.POSITION_AFTER_END),h.setEndAt(j,CKEDITOR.POSITION_BEFORE_START),h=g.clone(),h.setEndAt(k,CKEDITOR.POSITION_AFTER_END),i=g.clone(),i.setStartAt(j,CKEDITOR.POSITION_BEFORE_START),i=a(h).concat(a(i))):k?j||(e.tableSurroundingRange=h,h.setStartAt(k,CKEDITOR.POSITION_AFTER_END),g.setEndAt(k,CKEDITOR.POSITION_AFTER_END)):(e.tableSurroundingRange=h,h.setEndAt(j,CKEDITOR.POSITION_BEFORE_START),g.setStartAt(j,CKEDITOR.POSITION_AFTER_START)),e.tableContentsRanges=i?i:a(g))},deleteRanges:function(a){for(var b;b=a.tableContentsRanges.pop();)b.extractContents(),m(b.startContainer)&&b.startContainer.appendBogus();a.tableSurroundingRange&&a.tableSurroundingRange.extractContents()},purge:function(a){if(a.purgeTableBookmark){var b=a.doc,c=a.range.clone(),b=b.createElement("p");b.insertBefore(a.purgeTableBookmark.startNode),c.moveToBookmark(a.purgeTableBookmark),c.deleteContents(),a.range.moveToPosition(b,CKEDITOR.POSITION_AFTER_START)}}}}(),detectExtractMerge:function(a){return!(a.range.startPath().contains(CKEDITOR.dtd.$listItem)&&a.range.endPath().contains(CKEDITOR.dtd.$listItem))},fixUneditableRangePosition:function(a){a.startContainer.getDtd()["#"]||a.moveToClose
6stEditablePosition(null,!0)},autoParagraph:function(a,b){var d,c=b.startPath();g(a,c.block,c.blockLimit)&&(d=h(a))&&(d=b.document.createElement(d),d.appendBogus(),b.insertNode(d),b.moveToPosition(d,CKEDITOR.POSITION_AFTER_START))}}}()}(),function(){function a(){var b,a=this._.fakeSelection;a&&(b=this.getSelection(1),b&&b.isHidden()||(a.reset(),a=0)),(a||(a=b||this.getSelection(1),a&&a.getType()!=CKEDITOR.SELECTION_NONE))&&(this.fire("selectionCheck",a),b=this.elementPath(),b.compare(this._.selectionPreviousPath)||(CKEDITOR.env.webkit&&(this._.previousActive=this.document.getActive()),this._.selectionPreviousPath=b,this.fire("selectionChange",{selection:a,path:b})))}function b(){m=!0,l||(c.call(this),l=CKEDITOR.tools.setTimeout(c,200,this))}function c(){l=null,m&&(CKEDITOR.tools.setTimeout(a,0,this),m=!1)}function d(a){return!(!n(a)&&(a.type!=CKEDITOR.NODE_ELEMENT||a.is(CKEDITOR.dtd.$empty)))}function e(a){function b(b,c){return!(!b||b.type==CKEDITOR.NODE_TEXT)&&a.clone()["moveToElementEdit"+(c?"End":"Start")](b)}if(!(a.root instanceof CKEDITOR.editable))return!1;var c=a.startContainer,e=a.getPreviousNode(d,null,c),f=a.getNextNode(d,null,c);return!(!b(e)&&!b(f,1)&&(e||f||c.type==CKEDITOR.NODE_ELEMENT&&c.isBlockBoundary()&&c.getBogus()))}function f(a){g(a,!1);var b=a.getDocument().createText(s);return a.setCustomData("cke-fillingChar",b),b}function g(a,b){var c=a&&a.removeCustomData("cke-fillingChar");if(c){if(!1!==b){var d=a.getDocument().getSelection().getNative(),e=d&&"None"!=d.type&&d.getRangeAt(0),f=s.length;if(c.getLength()>f&&e&&e.intersectsNode(c.$)){var g=[{node:d.anchorNode,offset:d.anchorOffset},{node:d.focusNode,offset:d.focusOffset}];d.anchorNode==c.$&&d.anchorOffset>f&&(g[0].offset-=f),d.focusNode==c.$&&d.focusOffset>f&&(g[1].offset-=f)}}c.setText(h(c.getText(),1)),g&&(c=a.getDocument().$,d=c.getSelection(),c=c.createRange(),c.setStart(g[0].node,g[0].offset),c.collapse(!0),d.removeAllRanges(),d.addRange(c),d.extend(g[1].node,g[1].offset))}}function h(a,b){return b?a.replace(t,function(a,b){return b?"Â ":""}):a.replace(s,"")}function i(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")+'"> </div>',a.document);a.fire("lockSnapshot"),a.editable().append(b);var c=a.getSelection(1),d=a.createRange(),e=c.root.on("selectionchange",function(a){a.cancel()},null,null,0);d.setStartAt(b,CKEDITOR.POSITION_AFTER_START),d.setEndAt(b,CKEDITOR.POSITION_BEFORE_END),c.selectRanges([d]),e.removeListener(),a.fire("unlockSnapshot"),a._.hiddenSelectionContainer=b}function j(a){var b={37:1,39:1,8:1,46:1};return function(c){var d=c.data.getKeystroke();if(b[d]){var e=a.getSelection().getRanges(),f=e[0];1==e.length&&f.collapsed&&(d=f[38>d?"getPreviousEditableNode":"getNextEditableNode"]())&&d.type==CKEDITOR.NODE_ELEMENT&&"false"==d.getAttribute("contenteditable")&&(a.getSelection().fake(d),c.data.preventDefault(),c.cancel())}}}function k(a){for(var b=0;b<a.length;b++){var c=a[b];if(c.getCommonAncestor().isReadOnly()&&a.splice(b,1),!c.collapsed){if(c.startContainer.isReadOnly())for(var e,d=c.startContainer;d&&!((e=d.type==CKEDITOR.NODE_ELEMENT)&&d.is("body")||!d.isReadOnly());)e&&"false"==d.getAttribute("contentEditable")&&c.setStartAfter(d),d=d.getParent();d=c.startContainer,e=c.endContainer;var f=c.startOffset,g=c.endOffset,h=c.clone();d&&d.type==CKEDITOR.NODE_TEXT&&(f>=d.getLength()?h.setStartAfter(d):h.setStartBefore(d)),e&&e.type==CKEDITOR.NODE_TEXT&&(g?h.setEndAfter(e):h.setEndBefore(e)),d=new CKEDITOR.dom.walker(h),d.evaluator=function(d){if(d.type==CKEDITOR.NODE_ELEMENT&&d.isReadOnly()){var e=c.clone();return c.setEndBefore(d),c.collapsed&&a.splice(b--,1),d.getPosition(h.endContainer)&CKEDITOR.POSITION_CONTAINS||(e.setStartAfter(d),e.collapsed||a.splice(b+1,0,e)),!0}return!1},d.next()}}return a}var l,m,n=CKEDITOR.dom.walker.invisible(1),o=function(){function a(a){return function(b){var c=b.editor.createRange();return c.moveToClosestEditablePosition(b.selected,a)&&b.editor.getSelection().selectRanges([c]),!1}}function b(a){return function(b){var e,c=b.editor,d=c.createRange();
6return(e=d.moveToClosestEditablePosition(b.selected,a))||(e=d.moveToClosestEditablePosition(b.selected,!a)),e&&c.getSelection().selectRanges([d]), 7c.fire("saveSnapshot"),b.selected.remove(),e||(d.moveToElementEditablePosition(c.editable()),c.getSelection().selectRanges([d])),c.fire("saveSnapshot"),!1}}var c=a(),d=a(1);return{37:c,38:c,39:d,40:d,8:b(),46:b(1)}}();CKEDITOR.on("instanceCreated",function(c){function d(){var a=e.getSelection();a&&a.removeAllRanges()}var e=c.editor;e.on("contentDom",function(){function c(){o=new CKEDITOR.dom.selection(e.getSelection()),o.lock()}function d(){h.removeListener("mouseup",d),l.removeListener("mouseup",d);var a=CKEDITOR.document.$.selection,b=a.createRange();"None"!=a.type&&b.parentElement().ownerDocument==f.$&&b.select()}var n,o,f=e.document,h=CKEDITOR.document,i=e.editable(),k=f.getBody(),l=f.getDocumentElement(),m=i.isInline();if(CKEDITOR.env.gecko&&i.attachListener(i,"focus",function(a){a.removeListener(),0!==n&&(a=e.getSelection().getNative())&&a.isCollapsed&&a.anchorNode==i.$&&(a=e.createRange(),a.moveToElementEditStart(i),a.select())},null,null,-2),i.attachListener(i,CKEDITOR.env.webkit?"DOMFocusIn":"focus",function(){n&&CKEDITOR.env.webkit&&(n=e._.previousActive&&e._.previousActive.equals(f.getActive())),e.unlockSelection(n),n=0},null,null,-1),i.attachListener(i,"mousedown",function(){n=0}),(CKEDITOR.env.ie||m)&&(p?i.attachListener(i,"beforedeactivate",c,null,null,-1):i.attachListener(e,"selectionCheck",c,null,null,-1),i.attachListener(i,CKEDITOR.env.webkit?"DOMFocusOut":"blur",function(){e.lockSelection(o),n=1},null,null,-1),i.attachListener(i,"mousedown",function(){n=0})),CKEDITOR.env.ie&&!m){var q;i.attachListener(i,"mousedown",function(a){2==a.data.$.button&&((a=e.document.getSelection())&&a.getType()!=CKEDITOR.SELECTION_NONE||(q=e.window.getScrollPosition()))}),i.attachListener(i,"mouseup",function(a){2==a.data.$.button&&q&&(e.document.$.documentElement.scrollLeft=q.x,e.document.$.documentElement.scrollTop=q.y),q=null}),"BackCompat"!=f.$.compatMode&&((CKEDITOR.env.ie7Compat||CKEDITOR.env.ie6Compat)&&l.on("mousedown",function(a){function b(a){if(a=a.data.$,d){var b=k.$.createTextRange();try{b.moveToPoint(a.clientX,a.clientY)}catch(a){}d.setEndPoint(0>e.compareEndPoints("StartToStart",b)?"EndToEnd":"StartToStart",b),d.select()}}function c(){l.removeListener("mousemove",b),h.removeListener("mouseup",c),l.removeListener("mouseup",c),d.select()}if(a=a.data,a.getTarget().is("html")&&a.$.y<l.$.clientHeight&&a.$.x<l.$.clientWidth){var d=k.$.createTextRange();try{d.moveToPoint(a.$.clientX,a.$.clientY)}catch(a){}var e=d.duplicate();l.on("mousemove",b),h.on("mouseup",c),l.on("mouseup",c)}}),7<CKEDITOR.env.version&&11>CKEDITOR.env.version&&l.on("mousedown",function(a){a.data.getTarget().is("html")&&(h.on("mouseup",d),l.on("mouseup",d))}))}if(i.attachListener(i,"selectionchange",a,e),i.attachListener(i,"keyup",b,e),i.attachListener(i,CKEDITOR.env.webkit?"DOMFocusIn":"focus",function(){e.forceNextSelectionCheck(),e.selectionChange(1)}),m&&(CKEDITOR.env.webkit||CKEDITOR.env.gecko)){var r;i.attachListener(i,"mousedown",function(){r=1}),i.attachListener(f.getDocumentElement(),"mouseup",function(){r&&b.call(e),r=0})}else i.attachListener(CKEDITOR.env.ie?i:f.getDocumentElement(),"mouseup",b,e);CKEDITOR.env.webkit&&i.attachListener(f,"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:g(i)}},null,null,-1),i.attachListener(i,"keydown",j(e),null,null,-1)}),e.on("setData",function(){e.unlockSelection(),CKEDITOR.env.webkit&&d()}),e.on("contentDomUnload",function(){e.unlockSelection()}),CKEDITOR.env.ie9Compat&&e.on("beforeDestroy",d,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);b&&b.hasAttribute("data-cke-hidden-sel")&&(b.remove(),CKEDITOR.env.gecko&&(a=e.editable().getFirst(a))&&a.is("br")&&a.getAttribute("_moz_editor_bogus_node")&&a.remove())}
7,null,null,100),e.on("key",function(a){if("wysiwyg"==e.mode){var b=e.getSelection();if(b.isFake){var c=o[a.data.keyCode];if(c)return c({editor:e,selected:b.getSelectedElement(),selection:b,keyEvent:a})}}})}),CKEDITOR.env.webkit&&CKEDITOR.on("instanceReady",function(a){var b=a.editor;b.on("selectionChange",function(){var a=b.editable(),c=a.getCustomData("cke-fillingChar");c&&(c.getCustomData("ready")?g(a):c.setCustomData("ready",1))},null,null,-1),b.on("beforeSetMode",function(){g(b.editable())},null,null,-1),b.on("getSnapshot",function(a){a.data&&(a.data=h(a.data))},b,null,20),b.on("toDataFormat",function(a){a.data.dataValue=h(a.data.dataValue)},null,null,0)}),CKEDITOR.editor.prototype.selectionChange=function(c){(c?a:b).call(this)},CKEDITOR.editor.prototype.getSelection=function(a){return!this._.savedSelection&&!this._.fakeSelection||a?(a=this.editable())&&"wysiwyg"==this.mode?new CKEDITOR.dom.selection(a):null:this._.savedSelection||this._.fakeSelection},CKEDITOR.editor.prototype.lockSelection=function(a){return a=a||this.getSelection(1),a.getType()!=CKEDITOR.SELECTION_NONE&&(!a.isLocked&&a.lock(),this._.savedSelection=a,!0)},CKEDITOR.editor.prototype.unlockSelection=function(a){var b=this._.savedSelection;return!!b&&(b.unlock(a),delete this._.savedSelection,!0)},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);return a.selectRanges([this]),a},CKEDITOR.SELECTION_NONE=1,CKEDITOR.SELECTION_TEXT=2,CKEDITOR.SELECTION_ELEMENT=3;var p="function"!=typeof window.getSelection,q=1;CKEDITOR.dom.selection=function(a){if(a instanceof CKEDITOR.dom.selection){var b=a;a=a.root}var c=a instanceof CKEDITOR.dom.element;if(this.rev=b?b.rev:q++,this.document=a instanceof CKEDITOR.dom.document?a:a.getDocument(),this.root=c?a:this.document.getBody(),this.isLocked=0,this._={cache:{}},b)return CKEDITOR.tools.extend(this._.cache,b._.cache),this.isFake=b.isFake,this.isLocked=b.isLocked,this;a=this.getNative();var d,e;if(a)if(a.getRangeAt)d=(e=a.rangeCount&&a.getRangeAt(0))&&new CKEDITOR.dom.node(e.commonAncestorContainer);else{try{e=a.createRange()}catch(a){}d=e&&CKEDITOR.dom.element.get(e.item&&e.item(0)||e.parentElement())}return(!d||d.type!=CKEDITOR.NODE_ELEMENT&&d.type!=CKEDITOR.NODE_TEXT||!this.root.equals(d)&&!this.root.contains(d))&&(this._.cache.type=CKEDITOR.SELECTION_NONE,this._.cache.startElement=null,this._.cache.selectedElement=null,this._.cache.selectedText="",this._.cache.ranges=new CKEDITOR.dom.rangeList),this};var r={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},s=CKEDITOR.tools.repeat("â",7),t=new RegExp(s+"( )?","g");CKEDITOR.tools.extend(CKEDITOR.dom.selection,{_removeFillingCharSequenceString:h,_createFillingCharSequenceNode:f,FILLING_CHAR_SEQUENCE:s}),CKEDITOR.dom.selection.prototype={getNative:function(){return void 0!==this._.cache.nativeSel?this._.cache.nativeSel:this._.cache.nativeSel=p?this.document.$.selection:this.document.getWindow().$.getSelection()},getType:p?function(){var a=this._.cache;if(a.type)return a.type;var b=CKEDITOR.SELECTION_NONE;try{var c=this.getNative(),d=c.type;"Text"==d&&(b=CKEDITOR.SELECTION_TEXT),"Control"==d&&(b=CKEDITOR.SELECTION_ELEMENT),c.createRange().parentElement()&&(b=CKEDITOR.SELECTION_TEXT)}catch(a){}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){if(1==c.rangeCount){var c=c.getRangeAt(0),d=c.startContainer;d==c.endContainer&&1==d.nodeType&&1==c.endOffset-c.startOffset&&r[d.childNodes[c.startOffset].nodeName.toLowerCase()]&&(b=CKEDITOR.SELECTION_ELEMENT)}}else b=CKEDITOR.SELECTION_NONE;return a.type=b},getRanges:function(){var a=p?function(){function a(a){return new CKEDITOR.dom.node(a).getIndex()}
7var b=function(b,c){b=b.duplicate(),b.collapse(c);var d=b.parentElement();if(!d.hasChildNodes())return{container:d,offset:0};for(var f,g,l,m,e=d.children,h=b.duplicate(),i=0,j=e.length-1,k=-1;i<=j;)if(k=Math.floor((i+j)/2),f=e[k],h.moveToElementText(f),l=h.compareEndPoints("StartToStart",b),0<l)j=k-1;else{if(!(0>l))return{container:d,offset:a(f)};i=k+1}if(-1==k||k==e.length-1&&0>l){if(h.moveToElementText(d),h.setEndPoint("StartToStart",b),h=h.text.replace(/(\r\n|\r)/g,"\n").length,e=d.childNodes,!h)return f=e[e.length-1],f.nodeType!=CKEDITOR.NODE_TEXT?{container:d,offset:e.length}:{container:f,offset:f.nodeValue.length};for(d=e.length;0<h&&0<d;)g=e[--d],g.nodeType==CKEDITOR.NODE_TEXT&&(m=g,h-=g.nodeValue.length);return{container:m,offset:-h}}if(h.collapse(0<l),h.setEndPoint(0<l?"StartToStart":"EndToStart",b),h=h.text.replace(/(\r\n|\r)/g,"\n").length,!h)return{container:d,offset:a(f)+(0<l?0:1)};for(;0<h;)try{g=f[0<l?"previousSibling":"nextSibling"],g.nodeType==CKEDITOR.NODE_TEXT&&(h-=g.nodeValue.length,m=g),f=g}catch(b){return{container:d,offset:a(f)}}return{container:m,offset:0<l?-h:m.nodeValue.length+h}};return function(){var a=this.getNative(),c=a&&a.createRange(),d=this.getType();if(!a)return[];if(d==CKEDITOR.SELECTION_TEXT)return a=new CKEDITOR.dom.range(this.root),d=b(c,!0),a.setStart(new CKEDITOR.dom.node(d.container),d.offset),d=b(c),a.setEnd(new CKEDITOR.dom.node(d.container),d.offset),a.endContainer.getPosition(a.startContainer)&CKEDITOR.POSITION_PRECEDING&&a.endOffset<=a.startContainer.getIndex()&&a.collapse(),[a];if(d==CKEDITOR.SELECTION_ELEMENT){for(var d=[],e=0;e<c.length;e++){for(var f=c.item(e),g=f.parentNode,h=0,a=new CKEDITOR.dom.range(this.root);h<g.childNodes.length&&g.childNodes[h]!=f;h++);a.setStart(new CKEDITOR.dom.node(g),h),a.setEnd(new CKEDITOR.dom.node(g),h+1),d.push(a)}return d}return[]}}():function(){var b,a=[],c=this.getNative();if(!c)return a;for(var d=0;d<c.rangeCount;d++){var e=c.getRangeAt(d);b=new CKEDITOR.dom.range(this.root),b.setStart(new CKEDITOR.dom.node(e.startContainer),e.startOffset),b.setEnd(new CKEDITOR.dom.node(e.endContainer),e.endOffset),a.push(b)}return a};return function(b){var c=this._.cache,d=c.ranges;return d||(c.ranges=d=new CKEDITOR.dom.rangeList(a.call(this))),b?k(new CKEDITOR.dom.rangeList(d.slice())):d}}(),getStartElement:function(){var a=this._.cache;if(void 0!==a.startElement)return a.startElement;var b;switch(this.getType()){case CKEDITOR.SELECTION_ELEMENT:return this.getSelectedElement();case CKEDITOR.SELECTION_TEXT:var c=this.getRanges()[0];if(c){if(c.collapsed)b=c.startContainer,b.type!=CKEDITOR.NODE_ELEMENT&&(b=b.getParent());else{for(c.optimize();b=c.startContainer,c.startOffset==(b.getChildCount?b.getChildCount():b.getLength())&&!b.isBlockBoundary();)c.setStartAfter(b);if(b=c.startContainer,b.type!=CKEDITOR.NODE_ELEMENT)return b.getParent();if((b=b.getChild(c.startOffset))&&b.type==CKEDITOR.NODE_ELEMENT)for(c=b.getFirst();c&&c.type==CKEDITOR.NODE_ELEMENT;)b=c,c=c.getFirst();else b=c.startContainer}b=b.$}}return a.startElement=b?new CKEDITOR.dom.element(b):null},getSelectedElement:function(){var a=this._.cache;if(void 0!==a.selectedElement)return a.selectedElement;var b=this,c=CKEDITOR.tools.tryThese(function(){return b.getNative().createRange().item(0)},function(){for(var c,d,a=b.getRanges()[0].clone(),e=2;e&&!((c=a.getEnclosedNode())&&c.type==CKEDITOR.NODE_ELEMENT&&r[c.getName()]&&(d=c));e--)a.shrink(CKEDITOR.SHRINK_ELEMENT);return d&&d.$});return a.selectedElement=c?new CKEDITOR.dom.element(c):null},getSelectedText:function(){var a=this._.cache;if(void 0!==a.selectedText)return a.selectedText;var b=this.getNative(),b=p?"Control"==b.type?"":b.createRange().text:b.toString();return a.selectedText=b},lock:function(){this.getRanges(),this.getStartElement(),this.getSelectedElement(),this.getSelectedText(),this._.cache.nativeSel=null,this.isLocked=1},unlock:function(a){if(this.isLocked){if(a)var b=this.getSelectedElement(),c=!b&&this.getRanges(),d=this.isFake;this.isLocked=0,this.reset(),a&&(a=b||c[0]&&c[0].getCommonAncestor())&&a.getAscendant("body",1)&&(d?this.fake(b):b?this.selectElement(b):this.selectRanges(c))}},reset:function(){this._.cache={},this.isFake=0;var a=this.root.editor;if(a&&a._.fakeSelection)if(this.rev==a._.fakeSelection.rev){delete a._.fakeSelection;var b=a._.hiddenSelectionContainer;if(b){var c=a.checkDirty();a.fire("lockSnapshot"),b.remove(),a.fire("unlockSnapshot"),!c&&a.resetDirty()}delete a._.hiddenSelectionContainer}else CKEDITOR.warn("selection-fake-reset");this.rev=q++},selectElement:function(a){var b=new CKEDITOR.dom.range(this.root);b.setStartBefore(a),b.setEndAfter(a),this.selectRanges([b])},selectRanges:function(a){var b=this.root.editor,b=b&&b._.hiddenSelectionContainer;if(this.reset(),b)for(var c,b=this.root,d=0;d<a.length;++d)c=a[d],c.endContainer.equals(b)&&(c.endOffset=Math.min(c.endOffset,b.getChildCount()));if(a.length)if(this.isLocked){var h=CKEDITOR.document.getActive();this.unlock(),this.selectRanges(a),this.lock(),h&&!h.equals(this.root)&&h.focus()}else{var i,j,k;if(1==a.length&&!(k=a[0]).collapsed&&(i=k.getEnclosedNode())&&i.type==CKEDITOR.NODE_ELEMENT&&(k=k.clone(),k.shrink(CKEDITOR.SHRINK_ELEMENT,!0),(j=k.getEnclosedNode())&&j.type==CKEDITOR.NODE_ELEMENT&&(i=j),"false"==i.getAttribute("contenteditable"))||(i=void 0),i)this.fake(i);
7else{if(p){k=CKEDITOR.dom.walker.whitespaces(!0),j=/\ufeff|\u00a0/,b={table:1,tbody:1,tr:1},1<a.length&&(i=a[a.length-1],a[0].setEnd(i.endContainer,i.endOffset)),i=a[0],a=i.collapsed;var l,m,n;if((c=i.getEnclosedNode())&&c.type==CKEDITOR.NODE_ELEMENT&&c.getName()in r&&(!c.is("a")||!c.getText()))try{return n=c.$.createControlRange(),n.addElement(c.$),void n.select()}catch(a){}(i.startContainer.type==CKEDITOR.NODE_ELEMENT&&i.startContainer.getName()in b||i.endContainer.type==CKEDITOR.NODE_ELEMENT&&i.endContainer.getName()in b)&&(i.shrink(CKEDITOR.NODE_ELEMENT,!0),a=i.collapsed),n=i.createBookmark(),b=n.startNode,a||(h=n.endNode),n=i.document.$.body.createTextRange(),n.moveToElementText(b.$),n.moveStart("character",1),h?(j=i.document.$.body.createTextRange(),j.moveToElementText(h.$),n.setEndPoint("EndToEnd",j),n.moveEnd("character",-1)):(l=b.getNext(k),m=b.hasAscendant("pre"),l=!(l&&l.getText&&l.getText().match(j))&&(m||!b.hasPrevious()||b.getPrevious().is&&b.getPrevious().is("br")),m=i.document.createElement("span"),m.setHtml(""),m.insertBefore(b),l&&i.document.createText("\ufeff").insertBefore(b)),i.setStartBefore(b),b.remove(),a?(l?(n.moveStart("character",-1),n.select(),i.document.$.selection.clear()):n.select(),i.moveToPosition(m,CKEDITOR.POSITION_BEFORE_START),m.remove()):(i.setEndBefore(h),h.remove(),n.select())}else{if(h=this.getNative(),!h)return;for(this.removeAllRanges(),n=0;n<a.length;n++)if(n<a.length-1&&(l=a[n],m=a[n+1],j=l.clone(),j.setStart(l.endContainer,l.endOffset),j.setEnd(m.startContainer,m.startOffset),!j.collapsed&&(j.shrink(CKEDITOR.NODE_ELEMENT,!0),i=j.getCommonAncestor(),j=j.getEnclosedNode(),i.isReadOnly()||j&&j.isReadOnly())))m.setStart(l.startContainer,l.startOffset),a.splice(n--,1);else{i=a[n],m=this.document.$.createRange(),i.collapsed&&CKEDITOR.env.webkit&&e(i)&&(j=f(this.root),i.insertNode(j),(l=j.getNext())&&!j.getPrevious()&&l.type==CKEDITOR.NODE_ELEMENT&&"br"==l.getName()?(g(this.root),i.moveToPosition(l,CKEDITOR.POSITION_BEFORE_START)):i.moveToPosition(j,CKEDITOR.POSITION_AFTER_END)),m.setStart(i.startContainer.$,i.startOffset);try{m.setEnd(i.endContainer.$,i.endOffset)}catch(a){if(!(0<=a.toString().indexOf("NS_ERROR_ILLEGAL_VALUE")))throw a;i.collapse(1),m.setEnd(i.endContainer.$,i.endOffset)}h.addRange(m)}}this.reset(),this.root.fire("selectionchange")}}},fake:function(a){var b=this.root.editor;this.reset(),i(b);var c=this._.cache,d=new CKEDITOR.dom.range(this.root);d.setStartBefore(a),d.setEndAfter(a),c.ranges=new CKEDITOR.dom.rangeList(d),c.selectedElement=c.startElement=a,c.type=CKEDITOR.SELECTION_ELEMENT,c.selectedText=c.nativeSel=null,this.isFake=1,this.rev=q++,b._.fakeSelection=this,this.root.fire("selectionchange")},isHidden:function(){var a=this.getCommonAncestor();return a&&a.type==CKEDITOR.NODE_TEXT&&(a=a.getParent()),!(!a||!a.data("cke-hidden-sel"))},createBookmarks:function(a){return a=this.getRanges().createBookmarks(a),this.isFake&&(a.isFake=1),a},createBookmarks2:function(a){return a=this.getRanges().createBookmarks2(a),this.isFake&&(a.isFake=1),a},selectBookmarks:function(a){for(var c,b=[],d=0;d<a.length;d++){var e=new CKEDITOR.dom.range(this.root);e.moveToBookmark(a[d]),b.push(e)}return a.isFake&&(c=b[0].getEnclosedNode(),c&&c.type==CKEDITOR.NODE_ELEMENT||(CKEDITOR.warn("selection-not-fake"),a.isFake=0)),a.isFake?this.fake(c):this.selectRanges(b),this},getCommonAncestor:function(){var a=this.getRanges();return a.length?a[0].startContainer.getCommonAncestor(a[a.length-1].endContainer):null},scrollIntoView:function(){this.type!=CKEDITOR.SELECTION_NONE&&this.getRanges()[0].scrollIntoView()},removeAllRanges:function(){if(this.getType()!=CKEDITOR.SELECTION_NONE){var a=this.getNative();try{a&&a[p?"empty":"removeAllRanges"]()}catch(a){}this.reset()}}}}(),CKEDITOR.STYLE_BLOCK=1,CKEDITOR.STYLE_INLINE=2,CKEDITOR.STYLE_OBJECT=3,function(){function a(a,b){for(var c,d;(a=a.getParent())&&!a.equals(b);)if(a.getAttribute("data-nostyle"))c=a;else if(!d){var e=a.getAttribute("contentEditable");"false"==e?c=a:"true"==e&&(d=1)}return c}function b(a,b,c,d){return(a.getPosition(b)|d)==d&&(!c.childRule||c.childRule(a))}function c(d){var f=d.document;if(d.collapsed)f=r(this,f),d.insertNode(f),d.moveToPosition(f,CKEDITOR.POSITION_BEFORE_END);else{var i,g=this.element,h=this._.definition,j=h.ignoreReadonly,k=j||h.includeReadonly;null==k&&(k=d.root.getCustomData("cke_includeReadonly"));var l=CKEDITOR.dtd[g];l||(i=!0,l=CKEDITOR.dtd.span),d.enlarge(CKEDITOR.ENLARGE_INLINE,1),d.trim();var s,m=d.createBookmark(),n=m.startNode,p=m.endNode,q=n;if(!j){var t=d.getCommonAncestor(),j=a(n,t),t=a(p,t);
7j&&(q=j.getNextSourceNode(!0)),t&&(p=t)}for(q.getPosition(p)==CKEDITOR.POSITION_FOLLOWING&&(q=0);q;){if(j=!1,q.equals(p))q=null,j=!0;else{var u=q.type==CKEDITOR.NODE_ELEMENT?q.getName():null,t=u&&"false"==q.getAttribute("contentEditable"),v=u&&q.getAttribute("data-nostyle");if(u&&q.data("cke-bookmark")){q=q.getNextSourceNode(!0);continue}if(t&&k&&CKEDITOR.dtd.$block[u])for(var w=q,x=e(w),y=void 0,z=x.length,A=0,w=z&&new CKEDITOR.dom.range(w.getDocument());A<z;++A){var y=x[A],C=CKEDITOR.filter.instances[y.data("cke-filter")];(C?C.check(this):1)&&(w.selectNodeContents(y),c.call(this,w))}if(x=u?!l[u]||v?0:t&&!k?0:b(q,p,h,D):1){if(y=q.getParent(),x=h,z=g,A=i,!y||!(y.getDtd()||CKEDITOR.dtd.span)[z]&&!A||x.parentRule&&!x.parentRule(y))j=!0;else if(s||u&&CKEDITOR.dtd.$removeEmpty[u]&&(q.getPosition(p)|D)!=D||(s=d.clone(),s.setStartBefore(q)),u=q.type,u==CKEDITOR.NODE_TEXT||t||u==CKEDITOR.NODE_ELEMENT&&!q.getChildCount()){for(var F,u=q;(j=!u.getNext(B))&&(F=u.getParent(),l[F.getName()])&&b(F,n,h,E);)u=F;s.setEndAfter(u)}}else j=!0;q=q.getNextSourceNode(v||t)}if(j&&s&&!s.collapsed){for(var G,H,I,j=r(this,f),t=j.hasAttributes(),v=s.getCommonAncestor(),u={},x={},y={},z={};j&&v;){if(v.getName()==g){for(G in h.attributes)!z[G]&&(I=v.getAttribute(H))&&(j.getAttribute(G)==I?x[G]=1:z[G]=1);for(H in h.styles)!y[H]&&(I=v.getStyle(H))&&(j.getStyle(H)==I?u[H]=1:y[H]=1)}v=v.getParent()}for(G in x)j.removeAttribute(G);for(H in u)j.removeStyle(H);t&&!j.hasAttributes()&&(j=null),j?(s.extractContents().appendTo(j),s.insertNode(j),o.call(this,j),j.mergeSiblings(),CKEDITOR.env.ie||j.$.normalize()):(j=new CKEDITOR.dom.element("span"),s.extractContents().appendTo(j),s.insertNode(j),o.call(this,j),j.remove(!0)),s=null}}d.moveToBookmark(m),d.shrink(CKEDITOR.SHRINK_TEXT),d.shrink(CKEDITOR.NODE_ELEMENT,!0)}}function d(a){function b(){for(var a=new CKEDITOR.dom.elementPath(d.getParent()),b=new CKEDITOR.dom.elementPath(j.getParent()),c=null,e=null,f=0;f<a.elements.length;f++){var g=a.elements[f];if(g==a.block||g==a.blockLimit)break;k.checkElementRemovable(g,!0)&&(c=g)}for(f=0;f<b.elements.length&&(g=b.elements[f],g!=b.block&&g!=b.blockLimit);f++)k.checkElementRemovable(g,!0)&&(e=g);e&&j.breakParent(e),c&&d.breakParent(c)}a.enlarge(CKEDITOR.ENLARGE_INLINE,1);var c=a.createBookmark(),d=c.startNode;if(a.collapsed){for(var f,h,e=new CKEDITOR.dom.elementPath(d.getParent(),a.root),g=0;g<e.elements.length&&(h=e.elements[g])&&h!=e.block&&h!=e.blockLimit;g++)if(this.checkElementRemovable(h)){var i;a.collapsed&&(a.checkBoundaryOfElement(h,CKEDITOR.END)||(i=a.checkBoundaryOfElement(h,CKEDITOR.START)))?(f=h,f.match=i?"start":"end"):(h.mergeSiblings(),h.is(this.element)?n.call(this,h):p(h,u(this)[h.getName()]))}if(f){for(h=d,g=0;i=e.elements[g],!i.equals(f);g++)i.match||(i=i.clone(),i.append(h),h=i);h["start"==f.match?"insertBefore":"insertAfter"](f)}}else{var j=c.endNode,k=this;for(b(),e=d;!e.equals(j);)f=e.getNextSourceNode(),e.type==CKEDITOR.NODE_ELEMENT&&this.checkElementRemovable(e)&&(e.getName()==this.element?n.call(this,e):p(e,u(this)[e.getName()]),f.type==CKEDITOR.NODE_ELEMENT&&f.contains(d)&&(b(),f=d.getNext())),e=f}a.moveToBookmark(c),a.shrink(CKEDITOR.NODE_ELEMENT,!0)}function e(a){var b=[];return a.forEach(function(a){if("true"==a.getAttribute("contenteditable"))return b.push(a),!1},CKEDITOR.NODE_ELEMENT,!0),b}function f(a){var b=a.getEnclosedNode()||a.getCommonAncestor(!1,!0);(a=new CKEDITOR.dom.elementPath(b,a.root).contains(this.element,1))&&!a.isReadOnly()&&s(a,this)}function g(a){var b=a.getCommonAncestor(!0,!0);if(a=new CKEDITOR.dom.elementPath(b,a.root).contains(this.element,1)){var b=this._.definition,c=b.attributes;if(c)for(var d in c)a.removeAttribute(d,c[d]);if(b.styles)for(var e in b.styles)b.styles.hasOwnProperty(e)&&a.removeStyle(e)}}function h(a){var b=a.createBookmark(!0),c=a.createIterator();c.enforceRealBlocks=!0,this._.enterMode&&(c.enlargeBr=this._.enterMode!=CKEDITOR.ENTER_BR);for(var d,f,e=a.document;d=c.getNextParagraph();)!d.isReadOnly()&&(c.activeFilter?c.activeFilter.check(this):1)&&(f=r(this,e,d),j(d,f));a.moveToBookmark(b)}function i(a){var b=a.createBookmark(1),c=a.createIterator();c.enforceRealBlocks=!0,c.enlargeBr=this._.enterMode!=CKEDITOR.ENTER_BR;for(var d,e;d=c.getNextParagraph();)this.checkElementRemovable(d)&&(d.is("pre")?((e=this._.enterMode==CKEDITOR.ENTER_BR?null:a.document.createElement(this._.enterMode==CKEDITOR.ENTER_P?"p":"div"))&&d.copyAttributes(e),j(d,e)):n.call(this,d));a.moveToBookmark(b)}function j(a,b){var c=!b;c&&(b=a.getDocument().createElement("div"),a.copyAttributes(b));var d=b&&b.is("pre"),e=a.is("pre"),f=!d&&e;if(d&&!e){if(e=b,(f=a.getBogus())&&f.remove(),f=a.getHtml(),f=l(f,/(?:^[ \t\n\r]+)|(?:[ \t\n\r]+$)/g,""),f=f.replace(/[ \t\r\n]*(<br[^>]*>)[ \t\r\n]*/gi,"$1"),f=f.replace(/([ \t\n\r]+| )/g," "),f=f.replace(/<br\b[^>]*>/gi,"\n"),CKEDITOR.env.ie){var g=a.getDocument().createElement("div");g.append(e),e.$.outerHTML="<pre>"+f+"</pre>",e.copyAttributes(g.getFirst()),e=g.getFirst().remove()}else e.setHtml(f);b=e}else f?b=m(c?[a.getHtml()]:k(a),b):a.moveChildren(b);
7if(b.replace(a),d){var h,c=b;(h=c.getPrevious(C))&&h.type==CKEDITOR.NODE_ELEMENT&&h.is("pre")&&(d=l(h.getHtml(),/\n$/,"")+"\n\n"+l(c.getHtml(),/^\n/,""),CKEDITOR.env.ie?c.$.outerHTML="<pre>"+d+"</pre>":c.setHtml(d),h.remove())}else c&&q(b)}function k(a){var b=[];return l(a.getOuterHtml(),/(\S\s*)\n(?:\s|(<span[^>]+data-cke-bookmark.*?\/span>))*\n(?!$)/gi,function(a,b,c){return b+"</pre>"+c+"<pre>"}).replace(/<pre\b.*?>([\s\S]*?)<\/pre>/gi,function(a,c){b.push(c)}),b}function l(a,b,c){var d="",e="";return a=a.replace(/(^<span[^>]+data-cke-bookmark.*?\/span>)|(<span[^>]+data-cke-bookmark.*?\/span>$)/gi,function(a,b,c){return b&&(d=b),c&&(e=c),""}),d+a.replace(b,c)+e}function m(a,b){var c;1<a.length&&(c=new CKEDITOR.dom.documentFragment(b.getDocument()));for(var d=0;d<a.length;d++){var e=a[d],e=e.replace(/(\r\n|\r)/g,"\n"),e=l(e,/^[ \t]*\n/,""),e=l(e,/\n$/,""),e=l(e,/^[ \t]+|[ \t]+$/g,function(a,b){return 1==a.length?" ":b?" "+CKEDITOR.tools.repeat(" ",a.length-1):CKEDITOR.tools.repeat(" ",a.length-1)+" "}),e=e.replace(/\n/g,"<br>"),e=e.replace(/[ \t]{2,}/g,function(a){return CKEDITOR.tools.repeat(" ",a.length-1)+" "});if(c){var f=b.clone();f.setHtml(e),c.append(f)}else b.setHtml(e)}return c||b}function n(a,b){var g,c=this._.definition,d=c.attributes,c=c.styles,e=u(this)[a.getName()],f=CKEDITOR.tools.isEmpty(d)&&CKEDITOR.tools.isEmpty(c);for(g in d)("class"!=g&&!this._.definition.fullMatch||a.getAttribute(g)==v(g,d[g]))&&(b&&"data-"==g.slice(0,5)||(f=a.hasAttribute(g),a.removeAttribute(g)));for(var h in c)this._.definition.fullMatch&&a.getStyle(h)!=v(h,c[h],!0)||(f=f||!!a.getStyle(h),a.removeStyle(h));p(a,e,x[a.getName()]),f&&(this._.definition.alwaysRemoveElement?q(a,1):!CKEDITOR.dtd.$block[a.getName()]||this._.enterMode==CKEDITOR.ENTER_BR&&!a.hasAttributes()?q(a):a.renameNode(this._.enterMode==CKEDITOR.ENTER_P?"p":"div"))}function o(a){for(var d,b=u(this),c=a.getElementsByTag(this.element),e=c.count();0<=--e;)d=c.getItem(e),d.isReadOnly()||n.call(this,d,!0);for(var f in b)if(f!=this.element)for(c=a.getElementsByTag(f),e=c.count()-1;0<=e;e--)d=c.getItem(e),d.isReadOnly()||p(d,b[f])}function p(a,b,c){if(b=b&&b.attributes)for(var d=0;d<b.length;d++){var f,e=b[d][0];if(f=a.getAttribute(e)){var g=b[d][1];(null===g||g.test&&g.test(f)||"string"==typeof g&&f==g)&&a.removeAttribute(e)}}c||q(a)}function q(a,b){if(!a.hasAttributes()||b)if(CKEDITOR.dtd.$block[a.getName()]){var c=a.getPrevious(C),d=a.getNext(C);!c||c.type!=CKEDITOR.NODE_TEXT&&c.isBlockBoundary({br:1})||a.append("br",1),!d||d.type!=CKEDITOR.NODE_TEXT&&d.isBlockBoundary({br:1})||a.append("br"),a.remove(!0)}else c=a.getFirst(),d=a.getLast(),a.remove(!0),c&&(c.type==CKEDITOR.NODE_ELEMENT&&c.mergeSiblings(),d&&!c.equals(d)&&d.type==CKEDITOR.NODE_ELEMENT&&d.mergeSiblings())}function r(a,b,c){var d;return d=a.element,"*"==d&&(d="span"),d=new CKEDITOR.dom.element(d,b),c&&c.copyAttributes(d),d=s(d,a),b.getCustomData("doc_processing_style")&&d.hasAttribute("id")?d.removeAttribute("id"):b.setCustomData("doc_processing_style",1),d}function s(a,b){var c=b._.definition,d=c.attributes,c=CKEDITOR.style.getStyleText(c);if(d)for(var e in d)a.setAttribute(e,d[e]);return c&&a.setAttribute("style",c),a}function t(a,b){for(var c in a)a[c]=a[c].replace(A,function(a,c){return b[c]})}function u(a){if(a._.overrides)return a._.overrides;var b=a._.overrides={},c=a._.definition.overrides;if(c){CKEDITOR.tools.isArray(c)||(c=[c]);for(var d=0;d<c.length;d++){var f,g,e=c[d];if("string"==typeof e?f=e.toLowerCase():(f=e.element?e.element.toLowerCase():a.element,g=e.attributes),e=b[f]||(b[f]={}),g){var h,e=e.attributes=e.attributes||[];for(h in g)e.push([h.toLowerCase(),g[h]])}}}return b}function v(a,b,c){var d=new CKEDITOR.dom.element("span");return d[c?"setStyle":"setAttribute"](a,b),d[c?"getStyle":"getAttribute"](a)}function w(a,b,c){var d=a.document,e=a.getRanges();b=b?this.removeFromRange:this.applyToRange;for(var f,g=e.createIterator();f=g.getNextRange();)b.call(this,f,c);a.selectRanges(e),d.removeCustomData("doc_processing_style")}var x={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},y={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},z=/\s*(?:;\s*|$)/,A=/#\((.+?)\)/g,B=CKEDITOR.dom.walker.bookmark(0,1),C=CKEDITOR.dom.walker.whitespace
7s(1);CKEDITOR.style=function(a,b){if("string"==typeof a.type)return new CKEDITOR.style.customHandlers[a.type](a);var c=a.attributes;c&&c.style&&(a.styles=CKEDITOR.tools.extend({},a.styles,CKEDITOR.tools.parseCssText(c.style)),delete c.style),b&&(a=CKEDITOR.tools.clone(a),t(a.attributes,b),t(a.styles,b)),c=this.element=a.element?"string"==typeof a.element?a.element.toLowerCase():a.element:"*",this.type=a.type||(x[c]?CKEDITOR.STYLE_BLOCK:y[c]?CKEDITOR.STYLE_OBJECT:CKEDITOR.STYLE_INLINE),"object"==typeof this.element&&(this.type=CKEDITOR.STYLE_OBJECT),this._={definition:a}},CKEDITOR.style.prototype={apply:function(a){if(a instanceof CKEDITOR.dom.document)return w.call(this,a.getSelection());if(this.checkApplicable(a.elementPath(),a)){var b=this._.enterMode;b||(this._.enterMode=a.activeEnterMode),w.call(this,a.getSelection(),0,a),this._.enterMode=b}},remove:function(a){if(a instanceof CKEDITOR.dom.document)return w.call(this,a.getSelection(),1);if(this.checkApplicable(a.elementPath(),a)){var b=this._.enterMode;b||(this._.enterMode=a.activeEnterMode),w.call(this,a.getSelection(),1,a),this._.enterMode=b}},applyToRange:function(a){return this.applyToRange=this.type==CKEDITOR.STYLE_INLINE?c:this.type==CKEDITOR.STYLE_BLOCK?h:this.type==CKEDITOR.STYLE_OBJECT?f:null,this.applyToRange(a)},removeFromRange:function(a){return this.removeFromRange=this.type==CKEDITOR.STYLE_INLINE?d:this.type==CKEDITOR.STYLE_BLOCK?i:this.type==CKEDITOR.STYLE_OBJECT?g:null,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,!0,b);case CKEDITOR.STYLE_OBJECT:case CKEDITOR.STYLE_INLINE:for(var e,c=a.elements,d=0;d<c.length;d++)if(e=c[d],this.type!=CKEDITOR.STYLE_INLINE||e!=a.block&&e!=a.blockLimit){if(this.type==CKEDITOR.STYLE_OBJECT){var f=e.getName();if(!("string"==typeof this.element?f==this.element:f in this.element))continue}if(this.checkElementRemovable(e,!0,b))return!0}}return!1},checkApplicable:function(a,b,c){if(b&&b instanceof CKEDITOR.filter&&(c=b),c&&!c.check(this))return!1;switch(this.type){case CKEDITOR.STYLE_OBJECT:return!!a.contains(this.element);case CKEDITOR.STYLE_BLOCK:return!!a.blockLimit.getDtd()[this.element]}return!0},checkElementMatch:function(a,b){var c=this._.definition;if(!a||!c.ignoreReadonly&&a.isReadOnly())return!1;var d=a.getName();if("string"==typeof this.element?d==this.element:d in this.element){if(!b&&!a.hasAttributes())return!0;if(d=c._AC)c=d;else{var d={},e=0,f=c.attributes;if(f)for(var g in f)e++,d[g]=f[g];(g=CKEDITOR.style.getStyleText(c))&&(d.style||e++,d.style=g),d._length=e,c=c._AC=d}if(!c._length)return!0;for(var h in c)if("_length"!=h){if(e=a.getAttribute(h)||"","style"==h)a:{d=c[h],"string"==typeof d&&(d=CKEDITOR.tools.parseCssText(d)),"string"==typeof e&&(e=CKEDITOR.tools.parseCssText(e,!0)),g=void 0;for(g in d)if(!(g in e)||e[g]!=d[g]&&"inherit"!=d[g]&&"inherit"!=e[g]){d=!1;break a}d=!0}else d=c[h]==e;if(d){if(!b)return!0}else if(b)return!1}if(b)return!0}return!1},checkElementRemovable:function(a,b,c){if(this.checkElementMatch(a,b,c))return!0;if(b=u(this)[a.getName()]){var d;if(!(b=b.attributes))return!0;for(c=0;c<b.length;c++)if(d=b[c][0],d=a.getAttribute(d)){var e=b[c][1];if(null===e)return!0;if("string"==typeof e){if(d==e)return!0}else if(e.test(d))return!0}}return!1},buildPreview:function(a){var b=this._.definition,c=[],d=b.element;"bdo"==d&&(d="span");var c=["<",d],e=b.attributes;if(e)for(var f in e)c.push(" ",f,'="',e[f],'"');return(e=CKEDITOR.style.getStyleText(b))&&c.push(' style="',e,'"'),c.push(">",a||b.name,"</",d,">"),c.join("")},getDefinition:function(){return this._.definition}},CKEDITOR.style.getStyleText=function(a){var b=a._ST;if(b)return b;var b=a.styles,c=a.attributes&&a.attributes.style||"",d="";c.length&&(c=c.replace(z,";"));for(var e in b){var f=b[e],g=(e+":"+f).replace(z,";");"inherit"==f?d+=g:c+=g}return c.length&&(c=CKEDITOR.tools.normalizeCssText(c,!0)),a._ST=c+d},CKEDITOR.style.customHandlers={},CKEDITOR.style.addCustomHandler=function(a){var b=function(a){this._={definition:a},this.setup&&this.setup(a)};return b.prototype=CKEDITOR.tools.extend(CKEDITOR.tools.prototypedCopy(CKEDITOR.style.prototype),{assignedTo:CKEDITOR.STYLE_OBJECT},a,!0),this.customHandlers[a.type]=b};var D=CKEDITOR.POSITION_PRECEDING|CKEDITOR.POSITION_IDENTICAL|CKEDITOR.POSITION_IS_CONTAINED,E=CKEDITOR.POSITION_FOLLOWING|CKEDITOR.POSITION_IDENTICAL|CKEDITOR.POSITION_IS_CONTAINED; 8}(),CKEDITOR.styleCommand=function(a,b){this.requiredContent=this.allowedContent=this.style=a,CKEDITOR.tools.extend(this,b,!0)},CKEDITOR.styleCommand.prototype.exec=function(a){a.focus(),this.state==CKEDITOR.TRISTATE_OFF?a.applyStyle(this.style):this.state==CKEDITOR.TRISTATE_ON&&a.removeStyle(this.style)},CKEDITOR.stylesSet=new CKEDITOR.resourceManager("","stylesSet"),CKEDITOR.addStylesSet=CKEDITOR.tools.bind(CKEDITOR.stylesSet.add,CKEDITOR.stylesSet),CKEDITOR.loadStylesSet=function(a,b,c){CKEDITOR.stylesSet.addExternal(a,b,""),CKEDITOR.stylesSet.load(a,c)},CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{attachStyleStateChange:function(a,b){var c=this._.styleStateChangeCallbacks;c||(c=this._.styleStateChangeCallbacks=[],this.on("selectionChange",function(a){for(var b=0;b<c.length;b++){var d=c[b],e=d.style.checkActive(a.data.path,this)?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF;d.fn.call(this,e)}})),c.push({style:a,fn:b})},applyStyle:function(a){a.apply(this)},removeStyle:function(a){a.remove(this)}
8,getStylesSet:function(a){if(this._.stylesDefinitions)a(this._.stylesDefinitions);else{var b=this,c=b.config.stylesCombo_stylesSet||b.config.stylesSet;if(!1===c)a(null);else if(c instanceof Array)b._.stylesDefinitions=c,a(c);else{c||(c="default");var c=c.split(":"),d=c[0];CKEDITOR.stylesSet.addExternal(d,c[1]?c.slice(1).join(":"):CKEDITOR.getUrl("styles.js"),""),CKEDITOR.stylesSet.load(d,function(c){b._.stylesDefinitions=c[d],a(b._.stylesDefinitions)})}}}}),CKEDITOR.dom.comment=function(a,b){"string"==typeof a&&(a=(b?b.$: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+"-->"}}),function(){var c,a={},b={};for(c in CKEDITOR.dtd.$blockLimit)c in CKEDITOR.dtd.$list||(a[c]=1);for(c in CKEDITOR.dtd.$block)c in CKEDITOR.dtd.$blockLimit||c in CKEDITOR.dtd.$empty||(b[c]=1);CKEDITOR.dom.elementPath=function(c,d){var i,e=null,f=null,g=[],h=c;d=d||c.getDocument().getBody();do if(h.type==CKEDITOR.NODE_ELEMENT){if(g.push(h),!this.lastElement&&(this.lastElement=h,h.is(CKEDITOR.dtd.$object)||"false"==h.getAttribute("contenteditable")))continue;if(h.equals(d))break;if(!f&&(i=h.getName(),"true"==h.getAttribute("contenteditable")?f=h:!e&&b[i]&&(e=h),a[i])){if(i=!e&&"div"==i){a:{i=h.getChildren();for(var j=0,k=i.count();j<k;j++){var l=i.getItem(j);if(l.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$block[l.getName()]){i=!0;break a}}i=!1}i=!i}i?e=h:f=h}}while(h=h.getParent());f||(f=d),this.block=e,this.blockLimit=f,this.root=d,this.elements=g}}(),CKEDITOR.dom.elementPath.prototype={compare:function(a){var b=this.elements;if(a=a&&a.elements,!a||b.length!=a.length)return!1;for(var c=0;c<b.length;c++)if(!b[c].equals(a[c]))return!1;return!0},contains:function(a,b,c){var d;"string"==typeof a&&(d=function(b){return b.getName()==a}),a instanceof CKEDITOR.dom.element?d=function(b){return b.equals(a)}:CKEDITOR.tools.isArray(a)?d=function(b){return-1<CKEDITOR.tools.indexOf(a,b.getName())}:"function"==typeof a?d=a:"object"==typeof a&&(d=function(b){return b.getName()in a});var e=this.elements,f=e.length;for(b&&f--,c&&(e=Array.prototype.slice.call(e,0),e.reverse()),b=0;b<f;b++)if(d(e[b]))return e[b];return null},isContextFor:function(a){var b;return!(a in CKEDITOR.dtd.$block)||(b=this.contains(CKEDITOR.dtd.$intermediate)||this.root.equals(this.block)&&this.block||this.blockLimit,!!b.getDtd()[a])},direction:function(){return(this.block||this.blockLimit||this.root).getDirection(1)}},CKEDITOR.dom.text=function(a,b){"string"==typeof a&&(a=(b?b.$: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 b=this.$.parentNode,c=b.childNodes.length,d=this.getLength(),e=this.getDocument(),f=new CKEDITOR.dom.text(this.$.splitText(a),e);return b.childNodes.length==c&&(a>=d?(f=e.createText(""),f.insertAfter(this)):(a=e.createText(""),a.insertAfter(f),a.remove())),f},substring:function(a,b){return"number"!=typeof b?this.$.nodeValue.substr(a):this.$.nodeValue.substring(a,b)}}),function(){function a(a,b,c){var d=a.serializable,e=b[c?"endContainer":"startContainer"],f=c?"endOffset":"startOffset",g=d?b.document.getById(a.startNode):a.startNode;return a=d?b.document.getById(a.endNode):a.endNode,e.equals(g.getPrevious())?(b.startOffset=b.startOffset-e.getLength()-a.getPrevious().getLength(),e=a.getNext()):e.equals(a.getPrevious())&&(b.startOffset-=e.getLength(),e=a.getNext()),e.equals(g.getParent())&&b[f]++,e.equals(a.getParent())&&b[f]++,b[c?"endContainer":"startContainer"]=e,b}CKEDITOR.dom.rangeList=function(a){return a instanceof CKEDITOR.dom.rangeList?a:(a?a instanceof CKEDITOR.dom.range&&(a=[a]):a=[],CKEDITOR.tools.extend(a,b))};var b={createIterator:function(){var d,a=this,b=CKEDITOR.dom.walker.bookmark(),c=[];return{getNextRange:function(e){d=void 0===d?0:d+1;var f=a[d];if(f&&1<a.length){if(!d)for(var g=a.length-1;0<=g;g--)c.unshift(a[g].createBookmark(!0));if(e)for(var h=0;a[d+h+1];){var i=f.document;for(e=0,g=i.getById(c[h].endNode),i=i.getById(c[h+1].startNode);;){if(g=g.getNextSourceNode(!1),i.equals(g))e=1;else if(b(g)||g.type==CKEDITOR.NODE_ELEMENT&&g.isBlockBoundary())continue;break}if(!e)break;h++}for(f.moveToBookmark(c.shift());h--;)g=a[++d],g.moveToBookmark(c.shift()),f.setEnd(g.endContainer,g.endOffset)}return f}}},createBookmarks:function(b){for(var d,c=[],e=0;e<this.length;e++){c.push(d=this[e].createBookmark(b,!0));for(var f=e+1;f<this.length;f++)this[f]=a(d,this[f]),this[f]=a(d,this[f],!0)}return c},createBookmarks2:function(a){for(var b=[],c=0;c<this.length;c++)b.push(this[c].createBookmark2(a));return b},moveToBookmarks:function(a){for(var b=0;b<this.length;b++)this[b].moveToBookmark(a[b])}}}(),function(){function a(){return CKEDITOR.getUrl(CKEDITOR.skinName.split(",")[1]||"skins/"+CKEDITOR.skinName.split(",")[0]+"/")}function b(b){var c=CKEDITOR.skin["ua_"+b],d=CKEDITOR.env;if(c)for(var f,c=c.split(",").sort(function(a,b){return a>b?-1:1}),e=0;e<c.length;e++)if(f=c[e],d.ie&&(f.replace(/^ie/,"")==d.version||d.quirks&&"iequirks"==f)&&(f="ie"),d[f]){b+="_"+c[e];break}return CKEDITOR.getUrl(a()+b+".css")}function c(a,c){f[a]||(CKEDITOR.document.appendStyleSheet(b(a)),f[a]=1),c&&c()}function d(a){var b=a.getById(g);return b||(b=a.getHead().append("style"),b.setAttribute("id",g),b.setAttribute("type","text/css")),b}function e(a,b,c){var d,e,f;if(CKEDITOR.env.webkit)for(b=b.split("}").slice(0,-1),e=0;e<b.length;e++)b[e]=b[e].split("{");for(var g=0;g<a.length;g++)if(CKEDITOR.env.webkit)for(e=0;e<b.length;e++){for(f=b[e][1],d=0;d<c.length;d++)f=f.replace(c[d][0],c[d][1]);a[g].$.sheet.addRule(b[e][0],f)}else{for(f=b,d=0;d<c.length;d++)f=f.replace(c[d][0],c[d][1]);CKEDITOR.env.ie&&11>CKEDITOR.env.version?a[g].$.styleSheet.cssText+=f:a[g].$.innerHTML+=f}}var f={};CKEDITOR.skin={path:a,loadPart:function(b,d){CKEDITOR.skin.name!=CKEDITOR.skinName.split(",")[0]?CKEDITOR.scriptLoader.load(CKEDITOR.getUrl(a()+"skin.js"),function(){c(b,d)}):c(b,d)},getPath:function(a){return CKEDITOR.getUrl(b(a))},icons:{},addIcon:function(a,b,c,d){a=a.toLowerCase(),this.icons[a]||(this.icons[a]={path:b,offset:c||0,bgsize:d||"16px"})},getIconStyle:function(a,b,c,d,e){var f;return a&&(a=a.toLowerCase(),b&&(f=this.icons[a+"-rtl"]),f||(f=this.icons[a])),a=c||f&&f.path||"",d=d||f&&f.offset,e=e||f&&f.bgsize||"16px",a&&(a=a.replace(/'/g,"\\'")),a&&"background-image:url('"+CKEDITOR.getUrl(a)+"');background-position:0 "+d+"px;background-size:"+e+";"}},CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{getUiColor:function(){return this.uiColor},setUiColor:function(a){var b=d(CKEDITOR.document);return(this.setUiColor=function(a){this.uiColor=a;var c=CKEDITOR.skin.chameleon,d="",f="";"function"==typeof c&&(d=c(this,"editor"),f=c(this,"panel")),a=[[i,a]],e([b],d,a),e(h,f,a)}).call(this,a)}});var g="cke_ui_color",h=[],i=/\$color/g;
8CKEDITOR.on("instanceLoaded",function(a){if(!CKEDITOR.env.ie||!CKEDITOR.env.quirks){var b=a.editor;a=function(a){if(a=(a.data[0]||a.data).element.getElementsByTag("iframe").getItem(0).getFrameDocument(),!a.getById("cke_ui_color")){a=d(a),h.push(a);var c=b.getUiColor();c&&e([a],CKEDITOR.skin.chameleon(b,"panel"),[[i,c]])}},b.on("panelShow",a),b.on("menuShow",a),b.config.uiColor&&b.setUiColor(b.config.uiColor)}})}(),function(){if(CKEDITOR.env.webkit)CKEDITOR.env.hc=!1;else{var a=CKEDITOR.dom.element.createFromHtml('<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 b=a.getComputedStyle("border-top-color"),c=a.getComputedStyle("border-right-color");CKEDITOR.env.hc=!(!b||b!=c)}catch(a){CKEDITOR.env.hc=!1}a.remove()}if(CKEDITOR.env.hc&&(CKEDITOR.env.cssClass+=" cke_hc"),CKEDITOR.document.appendStyleText(".cke{visibility:hidden;}"),CKEDITOR.status="loaded",CKEDITOR.fireOnce("loaded"),a=CKEDITOR._.pending)for(delete CKEDITOR._.pending,b=0;b<a.length;b++)CKEDITOR.editor.prototype.constructor.apply(a[b][0],a[b][1]),CKEDITOR.add(a[b][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 c=a.match(/[^#]./g),d=0;3>d;d++){var f,e=d;f=parseInt(c[d],16),f=("0"+(0>b?0|f*(1+b):0|f+(255-f)*b).toString(16)).slice(-2),c[e]=f}return"#"+c.join("")}}(),b=function(){var a=new CKEDITOR.template("background:#{to};background-image:linear-gradient(to bottom,{from},{to});filter:progid:DXImageTransform.Microsoft.gradient(gradientType=0,startColorstr='{from}',endColorstr='{to}');");return function(b,c){return a.output({from:b,to:c})}}(),c={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(d,e){var f=d.uiColor,f={id:"."+d.id,defaultBorder:a(f,-.1),defaultGradient:b(a(f,.9),f),lightGradient:b(a(f,1),a(f,.7)),mediumGradient:b(a(f,.8),a(f,.5)),ckeButtonOn:b(a(f,.6),a(f,.7)),ckeResizer:a(f,-.4),ckeToolbarSeparator:a(f,.5),ckeColorauto:a(f,.8),dialogBody:a(f,.7),dialogTabSelected:b("#FFFFFF","#FFFFFF"),dialogTabSelectedBorder:"#FFF",elementsPathColor:a(f,-.6),elementsPathBg:f,menubuttonIcon:a(f,.5),menubuttonIconHover:a(f,.3)};return c[e].output(f).replace(/\[/g,"{").replace(/\]/g,"}")}}(),CKEDITOR.plugins.add("dialogui",{onLoad:function(){var a=function(a){this._||(this._={}),this._.default=this._.initValue=a.default||"",this._.required=a.required||!1;for(var b=[this._],c=1;c<arguments.length;c++)b.push(arguments[c]);return b.push(!0),CKEDITOR.tools.extend.apply(CKEDITOR.tools,b),this._},b={build:function(a,b,c){return new CKEDITOR.ui.dialog.textInput(a,b,c)}},c={build:function(a,b,c){return new CKEDITOR.ui.dialog[b.type](a,b,c)}},d={isChanged:function(){return this.getValue()!=this.getInitValue()},reset:function(a){this.setValue(this.getInitValue(),a)},setInitValue:function(){this._.initValue=this.getValue()},resetInitValue:function(){this._.initValue=this._.default},getInitValue:function(){return this._.initValue}},e=CKEDITOR.tools.extend({},CKEDITOR.ui.dialog.uiElement.prototype.eventProcessors,{onChange:function(a,b){this._.domOnChangeRegistered||(a.on("load",function(){this.getInputElement().on("change",function(){a.parts.dialog.isVisible()&&this.fire("change",{value:this.getValue()})},this)},this),this._.domOnChangeRegistered=!0),this.on("change",b)}},!0),f=/^on([A-Z]\w+)/,g=function(a){for(var b in a)(f.test(b)||"title"==b||"type"==b)&&delete a[b];return a}
8,h=function(a){a=a.data.getKeystroke(),a==CKEDITOR.SHIFT+CKEDITOR.ALT+36?this.setDirectionMarker("ltr"):a==CKEDITOR.SHIFT+CKEDITOR.ALT+35&&this.setDirectionMarker("rtl")};CKEDITOR.tools.extend(CKEDITOR.ui.dialog,{labeledElement:function(b,c,d,e){if(!(4>arguments.length)){var f=a.call(this,c);f.labelId=CKEDITOR.tools.getNextId()+"_label",this._.children=[];var g={role:c.role||"presentation"};c.includeLabel&&(g["aria-labelledby"]=f.labelId),CKEDITOR.ui.dialog.uiElement.call(this,b,c,d,"div",null,g,function(){var a=[],d=c.required?" cke_required":"";return"horizontal"!=c.labelLayout?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">',e.call(this,b,c),"</div>"):(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)+"</label>"},{type:"html",html:'<span class="cke_dialog_ui_labeled_content"'+(c.controlStyle?' style="'+c.controlStyle+'"':"")+">"+e.call(this,b,c)+"</span>"}]},CKEDITOR.dialog._.uiElementBuilders.hbox.build(b,d,a)),a.join("")})}},textInput:function(b,c,d){if(!(3>arguments.length)){a.call(this,c);var e=this._.inputId=CKEDITOR.tools.getNextId()+"_textInput",f={class:"cke_dialog_ui_input_"+c.type,id:e,type:c.type};c.validate&&(this.validate=c.validate),c.maxLength&&(f.maxlength=c.maxLength),c.size&&(f.size=c.size),c.inputStyle&&(f.style=c.inputStyle);var g=this,i=!1;b.on("load",function(){g.getInputElement().on("keydown",function(a){13==a.data.getKeystroke()&&(i=!0)}),g.getInputElement().on("keyup",function(a){13==a.data.getKeystroke()&&i&&(b.getButton("ok")&&setTimeout(function(){b.getButton("ok").click()},0),i=!1),g.bidi&&h.call(g,a)},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]+'" ');return a.push(" /></div>"),a.join("")})}},textarea:function(b,c,d){if(!(3>arguments.length)){a.call(this,c);var e=this,f=this._.inputId=CKEDITOR.tools.getNextId()+"_textarea",g={};c.validate&&(this.validate=c.validate),g.rows=c.rows||5,g.cols=c.cols||20,g.class="cke_dialog_ui_input_textarea "+(c.class||""),"undefined"!=typeof c.inputStyle&&(g.style=c.inputStyle),c.dir&&(g.dir=c.dir),e.bidi&&b.on("load",function(){e.getInputElement().on("keyup",h)},e),CKEDITOR.ui.dialog.labeledElement.call(this,b,c,d,function(){g["aria-labelledby"]=this._.labelId,this._.required&&(g["aria-required"]=this._.required);var b,a=['<div class="cke_dialog_ui_input_textarea" role="presentation"><textarea id="',f,'" '];for(b in g)a.push(b+'="'+CKEDITOR.tools.htmlEncode(g[b])+'" ');return a.push(">",CKEDITOR.tools.htmlEncode(e._.default),"</textarea></div>"),a.join("")})}},checkbox:function(b,c,d){if(!(3>arguments.length)){var e=a.call(this,c,{default:!!c.default});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"},!0),d=[],f=CKEDITOR.tools.getNextId()+"_label",h={class:"cke_dialog_ui_checkbox_input",type:"checkbox","aria-labelledby":f};return g(a),c.default&&(h.checked="checked"),"undefined"!=typeof a.inputStyle&&(a.style=a.inputStyle),e.checkbox=new CKEDITOR.ui.dialog.uiElement(b,a,d,"input",null,h),d.push(' <label id="',f,'" for="',h.id,'"'+(c.labelStyle?' style="'+c.labelStyle+'"':"")+">",CKEDITOR.tools.htmlEncode(c.label),"</label>"),d.join("")})}},radio:function(b,c,d){if(!(3>arguments.length)){a.call(this,c),this._.default||(this._.default=this._.initValue=c.items[0][1]),c.validate&&(this.validate=c.validate);var e=[],f=this;c.role="radiogroup",c.includeLabel=!0,CKEDITOR.ui.dialog.labeledElement.call(this,b,c,d,function(){for(var a=[],d=[],h=(c.id?c.id:CKEDITOR.tools.getNextId())+"_radio",i=0;i<c.items.length;i++){var j=c.items[i],k=void 0!==j[2]?j[2]:j[0],l=void 0!==j[1]?j[1]:j[0],m=CKEDITOR.tools.getNextId()+"_radio_input",n=m+"_label",m=CKEDITOR.tools.extend({},c,{id:m,title:null,type:null},!0),k=CKEDITOR.tools.extend({},m,{title:k},!0),o={type:"radio",class:"cke_dialog_ui_radio_input",name:h,value:l,"aria-labelledby":n},p=[];f._.default==l&&(o.checked="checked"),g(m),g(k),"undefined"!=typeof m.inputStyle&&(m.style=m.inputStyle),m.keyboardFocusable=!0,e.push(new CKEDITOR.ui.dialog.uiElement(b,m,p,"input",null,o)),p.push(" "),new CKEDITOR.ui.dialog.uiElement(b,k,p,"label",null,{id:n,for:o.id},j[0]),a.push(p.join(""))}return new CKEDITOR.ui.dialog.hbox(b,e,a,d),d.join("")}),this._.children=e}},button:function(b,c,d){if(arguments.length){"function"==typeof c&&(c=c(b.getParentEditor())),a.call(this,c,{disabled:c.disabled||!1}),CKEDITOR.event.implementOn(this);var e=this;b.on("load",function(){var a=this.getElement();!function(){a.on("click",function(a){e.click(),a.data.preventDefault()}),a.on("keydown",function(a){a.data.getKeystroke()in{32:1}&&(e.click(),a.data.preventDefault())})}(),a.unselectable()},this);var f=CKEDITOR.tools.extend({},c);delete f.style;var g=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":g},'<span id="'+g+'" class="cke_dialog_ui_button">'+CKEDITOR.tools.htmlEncode(c.label)+"</span>")}},select:function(b,c,d){if(!(3>arguments.length)){var e=a.call(this,c);c.validate&&(this.validate=c.validate),e.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"},!0),d=[],f=[],h={id:e.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(">"),void 0!==c.size&&(h.size=c.size),void 0!==c.multiple&&(h.multiple=c.multiple),g(a);for(var j,i=0;i<c.items.length&&(j=c.items[i]);i++)f.push('<option value="',CKEDITOR.tools.htmlEncode(void 0!==j[1]?j[1]:j[0]).replace(/"/g,"""),'" /> ',CKEDITOR.tools.htmlEncode(j[0]));return"undefined"!=typeof a.inputStyle&&(a.style=a.inputStyle),e.select=new CKEDITOR.ui.dialog.uiElement(b,a,d,"select",null,h,f.join("")),d.push("</div>"),d.join("")})}},file:function(b,c,d){if(!(3>arguments.length)){void 0===c.default&&(c.default="");var e=CKEDITOR.tools.extend(a.call(this,c),{definition:c,buttons:[]});c.validate&&(this.validate=c.validate),b.on("load",function(){CKEDITOR.document.getById(e.frameId).getParent().addClass("cke_dialog_ui_input_file")}),CKEDITOR.ui.dialog.labeledElement.call(this,b,c,d,function(){e.frameId=CKEDITOR.tools.getNextId()+"_fileInput";var a=['<iframe frameborder="0" allowtransparency="0" class="cke_dialog_ui_input_file" role="presentation" id="',e.frameId,'" title="',c.label,'" src="javascript:void('];return a.push(CKEDITOR.env.ie?"(function(){"+encodeURIComponent("document.open();("+CKEDITOR.tools.fixDomain+")();document.close();")+"})()":"0"),a.push(')"></iframe>'),a.join("")})}},fileButton:function(b,c,d){var e=this;if(!(3>arguments.length)){a.call(this,c),c.validate&&(this.validate=c.validate);var f=CKEDITOR.tools.extend({},c),g=f.onClick;f.className=(f.className?f.className+" ":"")+"cke_dialog_ui_button",f.onClick=function(a){var d=c.for;g&&!1===g.call(this,a)||(b.getContentElement(d[0],d[1]).submit(),this.disable())},b.on("load",function(){b.getContentElement(c.for[0],c.for[1])._.buttons.push(e)}),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,e,f){if(!(3>arguments.length)){var g=[],h=e.html;"<"!=h.charAt(0)&&(h="<span>"+h+"</span>");var i=e.focus;if(i){var j=this.focus;this.focus=function(){("function"==typeof i?i:j).call(this),this.fire("focus")},e.isFocusable&&(this.isFocusable=this.isFocusable),this.keyboardFocusable=!0}CKEDITOR.ui.dialog.uiElement.call(this,d,e,g,"span",null,null,""),g=g.join("").match(a),h=h.match(b)||["","",""],c.test(h[1])&&(h[1]=h[1].slice(0,-1),h[2]="/"+h[2]),f.push([h[1]," ",g[1]||"",h[2]].join(""))}}}(),fieldset:function(a,b,c,d,e){var f=e.label;this._={children:b},CKEDITOR.ui.dialog.uiElement.call(this,a,e,d,"fieldset",null,null,function(){var a=[];f&&a.push("<legend"+(e.labelStyle?' style="'+e.labelStyle+'"':"")+">"+f+"</legend>");for(var b=0;b<c.length;b++)a.push(c[b]);return a.join("")})}},!0),CKEDITOR.ui.dialog.html.prototype=new CKEDITOR.ui.dialog.uiElement,CKEDITOR.ui.dialog.labeledElement.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,{set
8Label:function(a){var b=CKEDITOR.document.getById(this._.labelId);return 1>b.getChildCount()?new CKEDITOR.dom.text(a,CKEDITOR.document).appendTo(b):b.getChild(0).$.nodeValue=a,this},getLabel:function(){var a=CKEDITOR.document.getById(this._.labelId);return!a||1>a.getChildCount()?"":a.getChild(0).getText()},eventProcessors:e},!0),CKEDITOR.ui.dialog.button.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,{click:function(){return!this._.disabled&&this.fire("click",{dialog:this._.dialog})},enable:function(){this._.disabled=!1;var a=this.getElement();a&&a.removeClass("cke_disabled")},disable:function(){this._.disabled=!0,this.getElement().addClass("cke_disabled")},isVisible:function(){return this.getElement().getFirst().isVisible()},isEnabled:function(){return!this._.disabled},eventProcessors:CKEDITOR.tools.extend({},CKEDITOR.ui.dialog.uiElement.prototype.eventProcessors,{onClick:function(a,b){this.on("click",function(){b.apply(this,arguments)})}},!0),accessKeyUp:function(){this.click()},accessKeyDown:function(){this.focus()},keyboardFocusable:!0},!0),CKEDITOR.ui.dialog.textInput.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.labeledElement,{getInputElement:function(){return CKEDITOR.document.getById(this._.inputId)},focus:function(){var a=this.selectParentTab();setTimeout(function(){var b=a.getInputElement();b&&b.$.focus()},0)},select:function(){var a=this.selectParentTab();setTimeout(function(){var b=a.getInputElement();b&&(b.$.focus(),b.$.select())},0)},accessKeyUp:function(){this.select()},setValue:function(a){if(this.bidi){var b=a&&a.charAt(0);(b="âª"==b?"ltr":"â«"==b?"rtl":null)&&(a=a.slice(1)),this.setDirectionMarker(b)}return a||(a=""),CKEDITOR.ui.dialog.uiElement.prototype.setValue.apply(this,arguments)},getValue:function(){var a=CKEDITOR.ui.dialog.uiElement.prototype.getValue.call(this);if(this.bidi&&a){var b=this.getDirectionMarker();b&&(a=("ltr"==b?"âª":"â«")+a)}return a},setDirectionMarker:function(a){var b=this.getInputElement();a?b.setAttributes({dir:a,"data-cke-dir-marker":a}):this.getDirectionMarker()&&b.removeAttributes(["dir","data-cke-dir-marker"])},getDirectionMarker:function(){return this.getInputElement().data("cke-dir-marker")},keyboardFocusable:!0},d,!0),CKEDITOR.ui.dialog.textarea.prototype=new CKEDITOR.ui.dialog.textInput,CKEDITOR.ui.dialog.select.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.labeledElement,{getInputElement:function(){return this._.select.getElement()},add:function(a,b,c){var d=new CKEDITOR.dom.element("option",this.getDialog().getParentEditor().document),e=this.getInputElement().$;return d.$.text=a,d.$.value=void 0===b||null===b?a:b,void 0===c||null===c?CKEDITOR.env.ie?e.add(d.$):e.add(d.$,null):e.add(d.$,c),this},remove:function(a){return this.getInputElement().$.remove(a),this},clear:function(){for(var a=this.getInputElement().$;0<a.length;)a.remove(0);return this},keyboardFocusable:!0},d,!0),CKEDITOR.ui.dialog.checkbox.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,{getInputElement:function(){return this._.checkbox.getElement()},setValue:function(a,b){this.getInputElement().$.checked=a,!b&&this.fire("change",{value:a})},getValue:function(){return this.getInputElement().$.checked},accessKeyUp:function(){this.setValue(!this.getValue())},eventProcessors:{onChange:function(a,b){return!CKEDITOR.env.ie||8<CKEDITOR.env.version?e.onChange.apply(this,arguments):(a.on("load",function(){var a=this._.checkbox.getElement();a.on("propertychange",function(b){b=b.data.$,"checked"==b.propertyName&&this.fire("change",{value:a.$.checked})},this)},this),this.on("change",b),null)}},keyboardFocusable:!0},d,!0),CKEDITOR.ui.dialog.radio.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,{setValue:function(a,b){for(var d,c=this._.children,e=0;e<c.length&&(d=c[e]);e++)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 b,a=this._.children;for(b=0;b<a.length;b++)if(a[b].getElement().$.checked)return void a[b].getElement().focus();a[0].getElement().focus()},eventProcessors:{onChange:function(a,b){return!CKEDITOR.env.ie||8<CKEDITOR.env.version?e.onChange.apply(this,arguments):(a.on("load",function(){for(var a=this._.children,b=this,c=0;c<a.length;c++)a[c].getElement().on("propertychange",function(a){a=a.data.$,"checked"==a.propertyName&&this.$.checked&&b.fire("change",{value:this.getAttribute("value")})})},this),this.on("change",b),null)}}},d,!0),CKEDITOR.ui.dialog.file.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.labeledElement,d,{getInputElement:function(){var a=CKEDITOR.document.getById(this._.frameId).getFrameDocument();return 0<a.$.forms.length?new CKEDITOR.dom.element(a.$.forms[0].elements[0]):this.getElement()},submit:function(){return this.getInputElement().getParent().$.submit(),this},getAction:function(){return this.getInputElement().getParent().$.action},registerEvents:function(a){var c,e,b=/^on([A-Z]\w+)/,d=function(a,b,c,d){a.on("formLoaded",function(){a.getInputElement().on(c,d,a)})};for(e in a)(c=e.match(b))&&(this.eventProcessors[e]?this.eventProcessors[e].call(this,this._.dialog,a[e]):d(this,this._.dialog,c[1].toLowerCase(),a[e]));return this},reset:function(){function a(){c.$.open();var a="";d.size&&(a=d.size-(CKEDITOR.env.ie?7:0));var j=b.frameId+"_input";for(c.$.write(['<html dir="'+h+'" lang="'+i+'"><head><title></title></head><body style="margin: 0; overflow: hidden; background: transparent;">','<form enctype="multipart/form-data" method="POST" dir="'+h+'" lang="'+i+'" action="',CKEDITOR.tools.htmlEncode(d.action),'"><label id="',b.labelId,'" for="',j,'" style="display:none">',CKEDITOR.tools.htmlEncode(d.label),'</label><input style="width:100%" id="',j,'" aria-labelledby="',b.labelId,'" type="file" name="',CKEDITOR.tools.htmlEncode(d.id||"cke_upload"),'" size="',CKEDITOR.tools.htmlEncode(0<a?a:""),'" /></form></body></html><script>',CKEDITOR.env.ie?"("+CKEDITOR.tools.fixDomain+")();":"","window.parent.CKEDITOR.tools.callFunction("+f+");","window.onbeforeunload = function() {window.parent.CKEDITOR.tools.callFunction("+g+")}","</script>"].join("")),c.$.close(),a=0;a<e.length;a++)e[a].enable()}var b=this._,c=CKEDITOR.document.getById(b.frameId).getFrameDocument(),d=b.definition,e=b.buttons,f=this.formLoadedNumber,g=this.formUnloadNumber,h=b.dialog._.editor.lang.dir,i=b.dialog._.editor.langCode;f||(f=this.formLoadedNumber=CKEDITOR.tools.addFunction(function(){this.fire("formLoaded")},this),g=this.formUnloadNumber=CKEDITOR.tools.addFunction(function(){this.getInputElement().clearCustomData()},this),this.getDialog()._.editor.on("destroy",function(){CKEDITOR.tools.removeFunction(f),CKEDITOR.tools.removeFunction(g)})),CKEDITOR.env.gecko?setTimeout(a,500):a()},getValue:function(){return this.getInputElement().$.value||""},setInitValue:function(){this._.initValue=""},eventProcessors:{onChange:function(a,b){this._.domOnChangeRegistered||(this.on("formLoaded",function(){this.getInputElement().on("change",function(){this.fire("change",{value:this.getValue()})},this)},this),this._.domOnChangeRegistered=!0),this.on("change",b)}}
8,keyboardFocusable:!0},!0),CKEDITOR.ui.dialog.fileButton.prototype=new CKEDITOR.ui.dialog.button,CKEDITOR.ui.dialog.fieldset.prototype=CKEDITOR.tools.clone(CKEDITOR.ui.dialog.hbox.prototype),CKEDITOR.dialog.addUIElement("text",b),CKEDITOR.dialog.addUIElement("password",b),CKEDITOR.dialog.addUIElement("textarea",c),CKEDITOR.dialog.addUIElement("checkbox",c),CKEDITOR.dialog.addUIElement("radio",c),CKEDITOR.dialog.addUIElement("button",c),CKEDITOR.dialog.addUIElement("select",c),CKEDITOR.dialog.addUIElement("file",c),CKEDITOR.dialog.addUIElement("fileButton",c),CKEDITOR.dialog.addUIElement("html",c),CKEDITOR.dialog.addUIElement("fieldset",{build:function(a,b,c){for(var e,d=b.children,f=[],g=[],h=0;h<d.length&&(e=d[h]);h++){var i=[];f.push(i),g.push(CKEDITOR.dialog._.uiElementBuilders[e.type].build(a,e,i))}return new CKEDITOR.ui.dialog[b.type](a,g,f,c,b)}})}}),CKEDITOR.DIALOG_RESIZE_NONE=0,CKEDITOR.DIALOG_RESIZE_WIDTH=1,CKEDITOR.DIALOG_RESIZE_HEIGHT=2,CKEDITOR.DIALOG_RESIZE_BOTH=3,CKEDITOR.DIALOG_STATE_IDLE=1,CKEDITOR.DIALOG_STATE_BUSY=2,function(){function a(){for(var a=this._.tabIdList.length,b=CKEDITOR.tools.indexOf(this._.tabIdList,this._.currentTabId)+a,c=b-1;c>b-a;c--)if(this._.tabs[this._.tabIdList[c%a]][0].$.offsetHeight)return this._.tabIdList[c%a];return null}function b(){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 c(a,b){for(var c=a.$.getElementsByTagName("input"),d=0,e=c.length;d<e;d++){var f=new CKEDITOR.dom.element(c[d]);"text"==f.getAttribute("type").toLowerCase()&&(b?(f.setAttribute("value",f.getCustomData("fake_value")||""), 9f.removeCustomData("fake_value")):(f.setCustomData("fake_value",f.getAttribute("value")),f.setAttribute("value","")))}}function d(a,b){var c=this.getInputElement();c&&(a?c.removeAttribute("aria-invalid"):c.setAttribute("aria-invalid",!0)),a||(this.select?this.select():this.focus()),b&&alert(b),this.fire("validated",{valid:a,msg:b})}function e(){var a=this.getInputElement();a&&a.removeAttribute("aria-invalid")}function f(a){var b=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":""})),c=b.getChild([0,0,0,0,0]),d=c.getChild(0),e=c.getChild(1);return a.plugins.clipboard&&CKEDITOR.plugins.clipboard.preventDefaultDropOnElement(c),!CKEDITOR.env.ie||CKEDITOR.env.quirks||CKEDITOR.env.edge||(a="javascript:void(function(){"+encodeURIComponent("document.open();("+CKEDITOR.tools.fixDomain+")();document.close();")+"}())",CKEDITOR.dom.element.createFromHtml('<iframe frameBorder="0" class="cke_iframe_shim" src="'+a+'" tabIndex="-1"></iframe>').appendTo(c.getParent())),d.unselectable(),e.unselectable(),{element:b,parts:{dialog:b.getChild(0),title:d,close:e,tabs:c.getChild(2),contents:c.getChild([3,0,0,0]),footer:c.getChild([3,0,1,0])}}}function g(a,b,c){this.element=b,this.focusIndex=c,this.tabIndex=0,this.isFocusable=function(){return!b.getAttribute("disabled")&&b.isVisible()},this.focus=function(){a._.currentFocusIndex=this.focusIndex,this.element.focus()},b.on("keydown",function(a){a.data.getKeystroke()in{32:1,13:1}&&this.fire("click")}),b.on("focus",function(){this.fire("mouseover")}),b.on("blur",function(){this.fire("mouseout")})}function h(a){function b(){a.layout()}var c=CKEDITOR.document.getWindow();c.on("resize",b),a.on("hide",function(){c.removeListener("resize",b)})}function i(a,b){this._={dialog:a},CKEDITOR.tools.extend(this,b)}function j(a){function b(b){var c=a.getSize(),i=CKEDITOR.document.getWindow().getViewPaneSize(),j=b.data.$.screenX,k=b.data.$.screenY,l=j-d.x,m=k-d.y;d={x:j,y:k},e.x+=l,e.y+=m,a.move(e.x+h[3]<g?-h[3]:e.x-h[1]>i.width-c.width-g?i.width-c.width+("rtl"==f.lang.dir?0:h[1]):e.x,e.y+h[0]<g?-h[0]:e.y-h[2]>i.height-c.height-g?i.height-c.height+h[2]:e.y,1),b.data.preventDefault()}function c(){if(CKEDITOR.document.removeListener("mousemove",b),CKEDITOR.document.removeListener("mouseup",c),CKEDITOR.env.ie6Compat){var a=x.getChild(0).getFrameDocument();a.removeListener("mousemove",b),a.removeListener("mouseup",c)}}var d=null,e=null,f=a.getParentEditor(),g=f.config.dialog_magnetDistance,h=CKEDITOR.skin.margins||[0,0,0,0];"undefined"==typeof g&&(g=20),a.parts.title.on("mousedown",function(f){if(d={x:f.data.$.screenX,y:f.data.$.screenY},CKEDITOR.document.on("mousemove",b),CKEDITOR.document.on("mouseup",c),e=a.getPosition(),CKEDITOR.env.ie6Compat){var g=x.getChild(0).getFrameDocument();g.on("mousemove",b),g.on("mouseup",c)}f.data.preventDefault()},a)}function k(a){function b(b){var c="rtl"==f.lang.dir,l=k.width,m=k.height,n=l+(b.data.$.screenX-j.x)*(c?-1:1)*(a._.moved?1:2),o=m+(b.data.$.screenY-j.y)*(a._.moved?1:2),p=a._.element.getFirst(),p=c&&p.getComputedStyle("right"),q=a.getPosition();q.y+o>i.height&&(o=i.height-q.y),(c?p:q.x)+n>i.width&&(n=i.width-(c?p:q.x)),e!=CKEDITOR.DIALOG_RESIZE_WIDTH&&e!=CKEDITOR.DIALOG_RESIZE_BOTH||(l=Math.max(d.minWidth||0,n-g)),e!=CKEDITOR.DIALOG_RESIZE_HEIGHT&&e!=CKEDITOR.DIALOG_RESIZE_BOTH||(m=Math.max(d.minHeight||0,o-h)),a.resize(l,m),a._.moved||a.layout(),b.data.preventDefault()}function c(){if(CKEDITOR.document.removeListener("mouseup",c),CKEDITOR.document.removeListener("mousemove",b),l&&(l.remove(),l=null),CKEDITOR.env.ie6Compat){var a=x.getChild(0).getFrameDocument();a.removeListener("mouseup",c),a.removeListener("mousemove",b)}}var d=a.definition,e=d.resizable;
9if(e!=CKEDITOR.DIALOG_RESIZE_NONE){var g,h,i,j,k,l,f=a.getParentEditor(),m=CKEDITOR.tools.addFunction(function(d){k=a.getSize();var e=a.parts.contents;e.$.getElementsByTagName("iframe").length&&(l=CKEDITOR.dom.element.createFromHtml('<div class="cke_dialog_resize_cover" style="height: 100%; position: absolute; width: 100%;"></div>'),e.append(l)),h=k.height-a.parts.contents.getSize("height",!(CKEDITOR.env.gecko||CKEDITOR.env.ie&&CKEDITOR.env.quirks)),g=k.width-a.parts.contents.getSize("width",1),j={x:d.screenX,y:d.screenY},i=CKEDITOR.document.getWindow().getViewPaneSize(),CKEDITOR.document.on("mousemove",b),CKEDITOR.document.on("mouseup",c),CKEDITOR.env.ie6Compat&&(e=x.getChild(0).getFrameDocument(),e.on("mousemove",b),e.on("mouseup",c)),d.preventDefault&&d.preventDefault()});a.on("load",function(){var b="";e==CKEDITOR.DIALOG_RESIZE_WIDTH?b=" cke_resizer_horizontal":e==CKEDITOR.DIALOG_RESIZE_HEIGHT&&(b=" cke_resizer_vertical"),b=CKEDITOR.dom.element.createFromHtml('<div class="cke_resizer'+b+" cke_resizer_"+f.lang.dir+'" title="'+CKEDITOR.tools.htmlEncode(f.lang.common.resize)+'" onmousedown="CKEDITOR.tools.callFunction('+m+', event )">'+("ltr"==f.lang.dir?"â¢":"â£")+"</div>"),a.parts.footer.append(b,1)}),f.on("destroy",function(){CKEDITOR.tools.removeFunction(m)})}}function l(a){a.data.preventDefault(1)}function m(a){var b=CKEDITOR.document.getWindow(),c=a.config,d=c.dialog_backgroundCoverColor||"white",e=c.dialog_backgroundCoverOpacity,f=c.baseFloatZIndex,c=CKEDITOR.tools.genKey(d,e,f),g=w[c];g?g.show():(f=['<div tabIndex="-1" style="position: ',CKEDITOR.env.ie6Compat?"absolute":"fixed","; z-index: ",f,"; top: 0px; left: 0px; ",CKEDITOR.env.ie6Compat?"":"background-color: "+d,'" class="cke_dialog_background_cover">'],CKEDITOR.env.ie6Compat&&(d="<html><body style=\\'background-color:"+d+";\\'></body></html>",f.push('<iframe hidefocus="true" frameborder="0" id="cke_dialog_background_iframe" src="javascript:'),f.push("void((function(){"+encodeURIComponent("document.open();("+CKEDITOR.tools.fixDomain+")();document.write( '"+d+"' );document.close();")+"})())"),f.push('" style="position:absolute;left:0;top:0;width:100%;height: 100%;filter: progid:DXImageTransform.Microsoft.Alpha(opacity=0)"></iframe>')),f.push("</div>"),g=CKEDITOR.dom.element.createFromHtml(f.join("")),g.setOpacity(void 0!==e?e:.5),g.on("keydown",l),g.on("keypress",l),g.on("keyup",l),g.appendTo(CKEDITOR.document.getBody()),w[c]=g),a.focusManager.add(g),x=g,a=function(){var a=b.getViewPaneSize();g.setStyles({width:a.width+"px",height:a.height+"px"})};var h=function(){var a=b.getScrollPosition(),c=CKEDITOR.dialog._.currentTop;if(g.setStyles({left:a.x+"px",top:a.y+"px"}),c)do a=c.getPosition(),c.move(a.x,a.y);while(c=c._.parentDialog)};if(v=a,b.on("resize",a),a(),CKEDITOR.env.mac&&CKEDITOR.env.webkit||g.focus(),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 n(a){x&&(a.focusManager.remove(x),a=CKEDITOR.document.getWindow(),x.hide(),a.removeListener("resize",v),CKEDITOR.env.ie6Compat&&a.$.setTimeout(function(){window.onscroll=window.onscroll&&window.onscroll.prevScrollHandler||null},0),v=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(c,g){function h(){var a=x._.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=x._.focusList;if(a=a||0,!(1>b.length)){var c=x._.currentFocusIndex;x._.tabBarMode&&0>a&&(c=0);try{b[c].getInputElement().$.blur()}catch(a){}var d=c,e=1<x._.pageCount;do{if(d+=a,e&&!x._.tabBarMode&&(d==b.length||-1==d))return x._.tabBarMode=!0,x._.tabs[x._.currentTabId][0].focus(),void(x._.currentFocusIndex=-1);if(d=(d+b.length)%b.length,d==c)break}while(a&&!b[d].isFocusable());b[d].focus(),"text"==b[d].type&&b[d].select()}}function l(d){if(x==CKEDITOR.dialog._.currentTop){var e=d.data.getKeystroke(),f="rtl"==c.lang.dir,g=[37,38,39,40];
9if(t=v=0,9==e||e==CKEDITOR.SHIFT+9)i(e==CKEDITOR.SHIFT+9?-1:1),t=1;else if(e==CKEDITOR.ALT+121&&!x._.tabBarMode&&1<x.getPageCount())x._.tabBarMode=!0,x._.tabs[x._.currentTabId][0].focus(),x._.currentFocusIndex=-1,t=1;else if(-1!=CKEDITOR.tools.indexOf(g,e)&&x._.tabBarMode)e=-1!=CKEDITOR.tools.indexOf([f?39:37,38],e)?a.call(x):b.call(x),x.selectPage(e),x._.tabs[e][0].focus(),t=1;else if(13!=e&&32!=e||!x._.tabBarMode)if(13==e)e=d.data.getTarget(),e.is("a","button","select","textarea")||e.is("input")&&"button"==e.$.type||((e=this.getButton("ok"))&&CKEDITOR.tools.setTimeout(e.click,0,e),t=1),v=1;else{if(27!=e)return;(e=this.getButton("cancel"))?CKEDITOR.tools.setTimeout(e.click,0,e):!1!==this.fire("cancel",{hide:!0}).hide&&this.hide(),v=1}else this.selectPage(this._.currentTabId),this._.tabBarMode=!1,this._.currentFocusIndex=-1,i(1),t=1;m(d)}}function m(a){t?a.data.preventDefault(1):v&&a.data.stopPropagation()}var t,v,n=CKEDITOR.dialog._.dialogDefinitions[g],o=CKEDITOR.tools.clone(q),p=c.config.dialog_buttonsOrder||"OS",r=c.lang.dir,s={};if(("OS"==p&&CKEDITOR.env.mac||"rtl"==p&&"ltr"==r||"ltr"==p&&"rtl"==r)&&o.buttons.reverse(),n=CKEDITOR.tools.extend(n(c),o),n=CKEDITOR.tools.clone(n),n=new u(this,n),o=f(c),this._={editor:c,element:o.element,name:g,contentSize:{width:0,height:0}
9,size:{width:0,height:0},contents:{},buttons:{},accessKeyMap:{},tabs:{},tabIdList:[],currentTabId:null,currentTabIndex:null,pageCount:0,lastTab:null,tabBarMode:!1,focusList:[],currentFocusIndex:0,hasFocus:!1},this.parts=o.parts,CKEDITOR.tools.setTimeout(function(){c.fire("ariaWidget",this.parts.contents)},0,this),o={position:CKEDITOR.env.ie6Compat?"absolute":"fixed",top:0,visibility:"hidden"},o["rtl"==r?"right":"left"]=0,this.parts.dialog.setStyles(o),CKEDITOR.event.call(this),this.definition=n=CKEDITOR.fire("dialogDefinition",{name:g,definition:n},c).definition,!("removeDialogTabs"in c._)&&c.config.removeDialogTabs){for(o=c.config.removeDialogTabs.split(";"),r=0;r<o.length;r++)if(p=o[r].split(":"),2==p.length){var w=p[0];s[w]||(s[w]=[]),s[w].push(p[1])}c._.removeDialogTabs=s}if(c._.removeDialogTabs&&(s=c._.removeDialogTabs[g]))for(r=0;r<s.length;r++)n.removeContents(s[r]);n.onLoad&&this.on("load",n.onLoad),n.onShow&&this.on("show",n.onShow),n.onHide&&this.on("hide",n.onHide),n.onOk&&this.on("ok",function(a){c.fire("saveSnapshot"),setTimeout(function(){c.fire("saveSnapshot")},0),!1===n.onOk.call(this,a)&&(a.data.hide=!1)}),this.state=CKEDITOR.DIALOG_STATE_IDLE,n.onCancel&&this.on("cancel",function(a){!1===n.onCancel.call(this,a)&&(a.data.hide=!1)});var x=this,y=function(a){var d,b=x._.contents,c=!1;for(d in b)for(var e in b[d])if(c=a.call(this,b[d][e]))return};this.on("ok",function(a){y(function(b){if(b.validate){var c=b.validate(this),e="string"==typeof c||!1===c;return e&&(a.data.hide=!1,a.stop()),d.call(b,!e,"string"==typeof c?c:void 0),e}})},this,null,0),this.on("cancel",function(a){y(function(b){if(b.isChanged())return c.config.dialog_noConfirmCancel||confirm(c.lang.common.confirmCancel)||(a.data.hide=!1),!0})},this,null,0),this.parts.close.on("click",function(a){!1!==this.fire("cancel",{hide:!0}).hide&&this.hide(),a.data.preventDefault()},this),this.changeFocus=i;var z=this._.element;
9for(c.focusManager.add(z,1),this.on("show",function(){z.on("keydown",l,this),CKEDITOR.env.gecko&&z.on("keypress",m,this)}),this.on("hide",function(){z.removeListener("keydown",l),CKEDITOR.env.gecko&&z.removeListener("keypress",m),y(function(a){e.apply(a)})}),this.on("iframeAdded",function(a){new CKEDITOR.dom.document(a.data.iframe.$.contentWindow.document).on("keydown",l,this,null,0)}),this.on("show",function(){h();var a=1<x._.pageCount;c.config.dialog_startupFocusTab&&a?(x._.tabBarMode=!0,x._.tabs[x._.currentTabId][0].focus(),x._.currentFocusIndex=-1):this._.hasFocus||(this._.currentFocusIndex=a?-1:this._.focusList.length-1,n.onFocus?(a=n.onFocus.call(this))&&a.focus():i(1))},this,null,4294967295),CKEDITOR.env.ie6Compat&&this.on("load",function(){var a=this.getElement(),b=a.getFirst();b.remove(),b.appendTo(a)},this),j(this),k(this),new CKEDITOR.dom.text(n.title,CKEDITOR.document).appendTo(this.parts.title),r=0;r<n.contents.length;r++)(s=n.contents[r])&&this.addPage(s);for(this.parts.tabs.on("click",function(a){var b=a.data.getTarget();b.hasClass("cke_dialog_tab")&&(b=b.$.id,this.selectPage(b.substring(4,b.lastIndexOf("_"))),this._.tabBarMode&&(this._.tabBarMode=!1,this._.currentFocusIndex=-1,i(1)),a.data.preventDefault())},this),r=[],s=CKEDITOR.dialog._.uiElementBuilders.hbox.build(this,{type:"hbox",className:"cke_dialog_footer_buttons",widths:[],children:n.buttons},r).getChild(),this.parts.footer.setHtml(r.join("")),r=0;r<s.length;r++)this._.buttons[s[r].id]=s[r]},CKEDITOR.dialog.prototype={destroy:function(){this.hide(),this._.element.remove()},resize:function(){return function(a,b){this._.contentSize&&this._.contentSize.width==a&&this._.contentSize.height==b||(CKEDITOR.dialog.fire("resize",{dialog:this,width:a,height:b},this._.editor),this.fire("resize",{width:a,height:b},this._.editor),this.parts.contents.setStyles({width:a+"px",height:b+"px"}),"rtl"==this._.editor.lang.dir&&this._.position&&(this._.position.x=CKEDITOR.document.getWindow().getViewPaneSize().width-this._.contentSize.width-parseInt(this._.element.getFirst().getStyle("right"),10)),this._.contentSize={width:a,height:b})}}(),getSize:function(){var a=this._.element.getFirst();return{width:a.$.offsetWidth||0,height:a.$.offsetHeight||0}},move:function(a,b,c){var d=this._.element.getFirst(),e="rtl"==this._.editor.lang.dir,f="fixed"==d.getComputedStyle("position");CKEDITOR.env.ie&&d.setStyle("zoom","100%"),f&&this._.position&&this._.position.x==a&&this._.position.y==b||(this._.position={x:a,y:b},f||(f=CKEDITOR.document.getWindow().getScrollPosition(),a+=f.x,b+=f.y),e&&(f=this.getSize(),a=CKEDITOR.document.getWindow().getViewPaneSize().width-f.width-a),b={top:(0<b?b:0)+"px"},b[e?"right":"left"]=(0<a?a:0)+"px",d.setStyles(b),c&&(this._.moved=1))},getPosition:function(){return CKEDITOR.tools.extend({},this._.position)},show:function(){var a=this._.element,b=this.definition;a.getParent()&&a.getParent().equals(CKEDITOR.document.getBody())?a.setStyle("display","block"):a.appendTo(CKEDITOR.document.getBody()),this.resize(this._.contentSize&&this._.contentSize.width||b.width||b.minWidth,this._.contentSize&&this._.contentSize.height||b.height||b.minHeight),this.reset(),this.selectPage(this.definition.contents[0].id),null===CKEDITOR.dialog._.currentZIndex&&(CKEDITOR.dialog._.currentZIndex=this._.editor.config.baseFloatZIndex),this._.element.getFirst().setStyle("z-index",CKEDITOR.dialog._.currentZIndex+=10),null===CKEDITOR.dialog._.currentTop?(CKEDITOR.dialog._.currentTop=this,this._.parentDialog=null,m(this._.editor)):(this._.parentDialog=CKEDITOR.dialog._.currentTop,this._.parentDialog.getElement().getFirst().$.style.zIndex-=Math.floor(this._.editor.config.baseFloatZIndex/2),CKEDITOR.dialog._.currentTop=this),a.on("keydown",z),a.on("keyup",A),this._.hasFocus=!1;for(var c in b.contents)if(b.contents[c]){var a=b.contents[c],d=this._.tabs[a.id],e=a.requiredContent,f=0;if(d){for(var g in this._.contents[a.id]){var i=this._.contents[a.id][g];"hbox"!=i.type&&"vbox"!=i.type&&i.getInputElement()&&(i.requiredContent&&!this._.editor.activeFilter.check(i.requiredContent)?i.disable():(i.enable(),f++))}!f||e&&!this._.editor.activeFilter.check(e)?d[0].addClass("cke_dialog_tab_disabled"):d[0].removeClass("cke_dialog_tab_disabled")}}CKEDITOR.tools.setTimeout(function(){this.layout(),h(this),this.parts.dialog.setStyle("visibility",""),this.fireOnce("load",{}),CKEDITOR.ui.fire("ready",this),this.fire("show",{}),this._.editor.fire("dialogShow",this),this._.parentDialog||this._.editor.focusManager.lock(),this.foreach(function(a){a.setInitValue&&a.setInitValue()})},100,this)},layout:function(){var a=this.parts.dialog,b=this.getSize(),c=CKEDITOR.document.getWindow().getViewPaneSize(),d=(c.width-b.width)/2,e=(c.height-b.height)/2;CKEDITOR.env.ie6Compat||(b.height+(0<e?e:0)>c.height||b.width+(0<d?d:0)>c.width?a.setStyle("position","absolute"):a.setStyle("position","fixed")),this.move(this._.moved?this._.position.x:d,this._.moved?this._.position.y:e)},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(){return this.foreach(a),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;for(a.setStyle("display","none"),this.parts.dialog.setStyle("visibility","hidden"),C(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 n(this._.editor);if(CKEDITOR.dialog._.currentTop=this._.parentDialog)CKEDITOR.dialog._.currentZIndex-=10;
9else{CKEDITOR.dialog._.currentZIndex=null,a.removeListener("keydown",z),a.removeListener("keyup",A);var c=this._.editor;c.focus(),setTimeout(function(){c.focusManager.unlock(),CKEDITOR.env.iOS&&c.window.focus()},0)}delete this._.parentDialog,this.foreach(function(a){a.resetInitValue&&a.resetInitValue()}),this.setState(CKEDITOR.DIALOG_STATE_IDLE)}},addPage:function(a){if(!a.requiredContent||this._.editor.filter.check(a.requiredContent)){for(var b=[],c=a.label?' title="'+CKEDITOR.tools.htmlEncode(a.label)+'"':"",d=CKEDITOR.dialog._.uiElementBuilders.vbox.build(this,{type:"vbox",className:"cke_dialog_page_contents",children:a.elements,expand:!!a.expand,padding:a.padding,style:a.style||"width: 100%;"},b),e=this._.contents[a.id]={},f=d.getChild(),g=0;d=f.shift();)d.notAllowed||"hbox"==d.type||"vbox"==d.type||g++,e[d.id]=d,"function"==typeof d.getChild&&f.push.apply(f,d.getChild());g||(a.hidden=!0),b=CKEDITOR.dom.element.createFromHtml(b.join("")),b.setAttribute("role","tabpanel"),d=CKEDITOR.env,e="cke_"+a.id+"_"+CKEDITOR.tools.getNextNumber(),c=CKEDITOR.dom.element.createFromHtml(['<a class="cke_dialog_tab"',0<this._.pageCount?" cke_last":"cke_first",c,a.hidden?' style="display:none"':"",' id="',e,'"',d.gecko&&!d.hc?"":' href="javascript:void(0)"',' tabIndex="-1" hidefocus="true" role="tab">',a.label,"</a>"].join("")),b.setAttribute("aria-labelledby",e),this._.tabs[a.id]=[c,b],this._.tabIdList.push(a.id),!a.hidden&&this._.pageCount++,this._.lastTab=c,this.updateStyle(),b.setAttribute("name",a.id),b.appendTo(this.parts.contents),c.unselectable(),this.parts.tabs.append(c),a.accessKey&&(B(this,this,"CTRL+"+a.accessKey,E,D),this._.accessKeyMap["CTRL+"+a.accessKey]=a.id)}},selectPage:function(a){if(this._.currentTabId!=a&&!this._.tabs[a][0].hasClass("cke_dialog_tab_disabled")&&!1!==this.fire("selectPage",{page:a,currentPage:this._.currentTabId})){for(var b in this._.tabs){var d=this._.tabs[b][0],e=this._.tabs[b][1];b!=a&&(d.removeClass("cke_dialog_tab_selected"),e.hide()),e.setAttribute("aria-hidden",b!=a)}var f=this._.tabs[a];f[0].addClass("cke_dialog_tab_selected"),CKEDITOR.env.ie6Compat||CKEDITOR.env.ie7Compat?(c(f[1]),f[1].show(),setTimeout(function(){c(f[1],1)},0)):f[1].show(),this._.currentTabId=a,this._.currentTabIndex=CKEDITOR.tools.indexOf(this._.tabIdList,a)}},updateStyle:function(){this.parts.dialog[(1===this._.pageCount?"add":"remove")+"Class"]("cke_single_page")},hidePage:function(b){var c=this._.tabs[b]&&this._.tabs[b][0];c&&1!=this._.pageCount&&c.isVisible()&&(b==this._.currentTabId&&this.selectPage(a.call(this)),c.hide(),this._.pageCount--,this.updateStyle())},showPage:function(a){(a=this._.tabs[a]&&this._.tabs[a][0])&&(a.show(),this._.pageCount++,this.updateStyle())},getElement:function(){return this._.element},getName:function(){return this._.name},getContentElement:function(a,b){var c=this._.contents[a];return c&&c[b]},getValueOf:function(a,b){return this.getContentElement(a,b).getValue()},setValueOf:function(a,b,c){return this.getContentElement(a,b).setValue(c)},getButton:function(a){return this._.buttons[a]},click:function(a){return this._.buttons[a].click()},disableButton:function(a){return this._.buttons[a].disable()},enableButton:function(a){return this._.buttons[a].enable()},getPageCount:function(){return this._.pageCount},getParentEditor:function(){return this._.editor},getSelectedElement:function(){return this.getParentEditor().getSelection().getSelectedElement()},addFocusable:function(a,b){if("undefined"==typeof b)b=this._.focusList.length,this._.focusList.push(new g(this,a,b));else{this._.focusList.splice(b,0,new g(this,a,b));for(var c=b+1;c<this._.focusList.length;c++)this._.focusList[c].focusIndex++}},setState:function(a){if(this.state!=a){if(this.state=a,a==CKEDITOR.DIALOG_STATE_BUSY){if(!this.parts.spinner){var b=this.getParentEditor().lang.dir,c={attributes:{class:"cke_dialog_spinner"},styles:{float:"rtl"==b?"right":"left"}};c.styles["margin-"+("rtl"==b?"left":"right")]="8px",this.parts.spinner=CKEDITOR.document.createElement("div",c),this.parts.spinner.setHtml("⌛"),this.parts.spinner.appendTo(this.parts.title,1)}this.parts.spinner.show(),this.getButton("ok").disable()}else a==CKEDITOR.DIALOG_STATE_IDLE&&(this.parts.spinner&&this.parts.spinner.hide(),this.getButton("ok").enable());this.fire("state",a)}}},CKEDITOR.tools.extend(CKEDITOR.dialog,{add:function(a,b){this._.dialogDefinitions[a]&&"function"!=typeof b||(this._.dialogDefinitions[a]=b)},exists:function(a){return!!this._.dialogDefinitions[a]},getCurrent:function(){return CKEDITOR.dialog._.currentTop},isTabEnabled:function(a,b,c){return a=a.config.removeDialogTabs,!(a&&a.match(new RegExp("(?:^|;)"+b+":"+c+"(?:$|;)","i")))},okButton:function(){var a=function(a,b){return b=b||{},CKEDITOR.tools.extend({id:"ok",type:"button",label:a.lang.common.ok,class:"cke_dialog_ui_button_ok",onClick:function(a){a=a.data.dialog,!1!==a.fire("ok",{hide:!0}).hide&&a.hide()}},b,!0)};return a.type="button",a.override=function(b){return CKEDITOR.tools.extend(function(c){return a(c,b)},{type:"button"},!0)},a}(),cancelButton:function(){var a=function(a,b){return b=b||{},CKEDITOR.tools.extend({id:"cancel",type:"button",label:a.lang.common.cancel,class:"cke_dialog_ui_button_cancel",onClick:function(a){a=a.data.dialog,!1!==a.fire("cancel",{hide:!0}).hide&&a.hide()}},b,!0)};return a.type="button",a.override=function(b){return CKEDITOR.tools.extend(function(c){return a(c,b)},{type:"button"},!0)},a}(),addUIElement:function(a,b){this._.uiElementBuilders[a]=b}}),CKEDITOR.dialog._={uiElementBuilders:{},dialogDefinitions:{},currentTop:null,currentZIndex:null},CKEDITOR.event.implementOn(CKEDITOR.dialog),CKEDITOR.event.implementOn(CKEDITOR.dialog.prototype);var q={resizable:CKEDITOR.DIALOG_RESIZE_BOTH,minWidth:600,minHeight:400,buttons:[CKEDITOR.dialog.okButton,CKEDITOR.dialog.cancelButton]},r=function(a,b,c){for(var e,d=0;e=a[d];d++)if(e.id==b||c&&e[c]&&(e=r(e[c],b,c)))return e;return null},s=function(a,b,c,d,e){if(c){for(var g,f=0;g=a[f];
9f++){if(g.id==c)return a.splice(f,0,b),b;if(d&&g[d]&&(g=s(g[d],b,c,d,!0)))return g}if(e)return null}return a.push(b),b},t=function(a,b,c){for(var e,d=0;e=a[d];d++){if(e.id==b)return a.splice(d,1);if(c&&e[c]&&(e=t(e[c],b,c)))return e}return null},u=function(a,b){this.dialog=a;for(var e,c=b.contents,d=0;e=c[d];d++)c[d]=e&&new i(a,e);CKEDITOR.tools.extend(this,b)};u.prototype={getContents:function(a){return r(this.contents,a)},getButton:function(a){return r(this.buttons,a)},addContents:function(a,b){return s(this.contents,a,b)},addButton:function(a,b){return s(this.buttons,a,b)},removeContents:function(a){t(this.contents,a)},removeButton:function(a){t(this.buttons,a)}},i.prototype={get:function(a){return r(this.elements,a,"children")},add:function(a,b){return s(this.elements,a,b,"children")},remove:function(a){t(this.elements,a,"children")}};var v,x,w={},y={},z=function(a){var b=a.data.$.ctrlKey||a.data.$.metaKey,c=a.data.$.altKey,d=a.data.$.shiftKey,e=String.fromCharCode(a.data.$.keyCode);(b=y[(b?"CTRL+":"")+(c?"ALT+":"")+(d?"SHIFT+":"")+e])&&b.length&&(b=b[b.length-1],b.keydown&&b.keydown.call(b.uiElement,b.dialog,b.key),a.data.preventDefault())},A=function(a){var b=a.data.$.ctrlKey||a.data.$.metaKey,c=a.data.$.altKey,d=a.data.$.shiftKey,e=String.fromCharCode(a.data.$.keyCode);(b=y[(b?"CTRL+":"")+(c?"ALT+":"")+(d?"SHIFT+":"")+e])&&b.length&&(b=b[b.length-1],b.keyup&&(b.keyup.call(b.uiElement,b.dialog,b.key),a.data.preventDefault()))},B=function(a,b,c,d,e){(y[c]||(y[c]=[])).push({uiElement:a,dialog:b,key:c,keyup:e||a.accessKeyUp,keydown:d||a.accessKeyDown})},C=function(a){for(var b in y){for(var c=y[b],d=c.length-1;0<=d;d--)c[d].dialog!=a&&c[d].uiElement!=a||c.splice(d,1);0===c.length&&delete y[b]}},D=function(a,b){a._.accessKeyMap[b]&&a.selectPage(a._.accessKeyMap[b])},E=function(){};!function(){CKEDITOR.ui.dialog={uiElement:function(a,b,c,d,e,f,g){if(!(4>arguments.length)){var h=(d.call?d(b):d)||"div",i=["<",h," "],j=(e&&e.call?e(b):e)||{},k=(f&&f.call?f(b):f)||{},l=(g&&g.call?g.call(this,a,b):g)||"",m=this.domId=k.id||CKEDITOR.tools.getNextId()+"_uiElement";b.requiredContent&&!a.getParentEditor().filter.check(b.requiredContent)&&(j.display="none",this.notAllowed=!0),k.id=m;var n={};b.type&&(n["cke_dialog_ui_"+b.type]=1),b.className&&(n[b.className]=1),b.disabled&&(n.cke_disabled=1);for(var o=k.class&&k.class.split?k.class.split(" "):[],m=0;m<o.length;m++)o[m]&&(n[o[m]]=1);o=[];for(m in n)o.push(m);k.class=o.join(" "),b.title&&(k.title=b.title),n=(b.style||"").split(";"),b.align&&(o=b.align,j["margin-left"]="left"==o?0:"auto",j["margin-right"]="right"==o?0:"auto");for(m in j)n.push(m+":"+j[m]);for(b.hidden&&n.push("display:none"),m=n.length-1;0<=m;m--)""===n[m]&&n.splice(m,1);0<n.length&&(k.style=(k.style?k.style+"; ":"")+n.join("; "));for(m in k)i.push(m+'="'+CKEDITOR.tools.htmlEncode(k[m])+'" ');i.push(">",l,"</",h,">"),c.push(i.join("")),(this._||(this._={})).dialog=a,"boolean"==typeof b.isChanged&&(this.isChanged=function(){return b.isChanged}),"function"==typeof b.isChanged&&(this.isChanged=b.isChanged),"function"==typeof b.setValue&&(this.setValue=CKEDITOR.tools.override(this.setValue,function(a){return function(c){a.call(this,b.setValue.call(this,c))}})),"function"==typeof b.getValue&&(this.getValue=CKEDITOR.tools.override(this.getValue,function(a){return function(){return b.getValue.call(this,a.call(this))}})),CKEDITOR.event.implementOn(this),this.registerEvents(b),this.accessKeyUp&&this.accessKeyDown&&b.accessKey&&B(this,a,"CTRL+"+b.accessKey);var p=this;a.on("load",function(){var b=p.getInputElement();if(b){var c=p.type in{checkbox:1,ratio:1}&&CKEDITOR.env.ie&&8>CKEDITOR.env.version?"cke_dialog_ui_focused":"";b.on("focus",function(){a._.tabBarMode=!1,a._.hasFocus=!0,p.fire("focus"),c&&this.addClass(c)}),b.on("blur",function(){p.fire("blur"),c&&this.removeClass(c)})}}),CKEDITOR.tools.extend(this,b),this.keyboardFocusable&&(this.tabIndex=b.tabIndex||0,this.focusIndex=a._.focusList.push(this)-1,this.on("focus",function(){a._.currentFocusIndex=p.focusIndex}))}},hbox:function(a,b,c,d,e){if(!(4>arguments.length)){this._||(this._={});
9var i,f=this._.children=b,g=e&&e.widths||null,h=e&&e.height||null,j={role:"presentation"};e&&e.align&&(j.align=e.align),CKEDITOR.ui.dialog.uiElement.call(this,a,e||{type:"hbox"},d,"table",{},j,function(){var a=['<tbody><tr class="cke_dialog_ui_hbox">'];for(i=0;i<c.length;i++){var b="cke_dialog_ui_hbox_child",d=[];0===i&&(b="cke_dialog_ui_hbox_first"),i==c.length-1&&(b="cke_dialog_ui_hbox_last"),a.push('<td class="',b,'" role="presentation" '),g?g[i]&&d.push("width:"+o(g[i])):d.push("width:"+Math.floor(100/c.length)+"%"),h&&d.push("height:"+o(h)),e&&void 0!==e.padding&&d.push("padding:"+o(e.padding)),CKEDITOR.env.ie&&CKEDITOR.env.quirks&&f[i].align&&d.push("text-align:"+f[i].align),0<d.length&&a.push('style="'+d.join("; ")+'" '),a.push(">",c[i],"</td>")}return a.push("</tr></tbody>"),a.join("")})}},vbox:function(a,b,c,d,e){if(!(3>arguments.length)){this._||(this._={});var f=this._.children=b,g=e&&e.width||null,h=e&&e.heights||null;CKEDITOR.ui.dialog.uiElement.call(this,a,e||{type:"vbox"},d,"div",null,{role:"presentation"},function(){var b=['<table role="presentation" cellspacing="0" border="0" '];b.push('style="'),e&&e.expand&&b.push("height:100%;"),b.push("width:"+o(g||"100%"),";"),CKEDITOR.env.webkit&&b.push("float:none;"),b.push('"'),b.push('align="',CKEDITOR.tools.htmlEncode(e&&e.align||("ltr"==a.getParentEditor().lang.dir?"left":"right")),'" '),b.push("><tbody>");for(var d=0;d<c.length;d++){var i=[];b.push('<tr><td role="presentation" '),g&&i.push("width:"+o(g||"100%")),h?i.push("height:"+o(h[d])):e&&e.expand&&i.push("height:"+Math.floor(100/c.length)+"%"),e&&void 0!==e.padding&&i.push("padding:"+o(e.padding)),CKEDITOR.env.ie&&CKEDITOR.env.quirks&&f[d].align&&i.push("text-align:"+f[d].align),0<i.length&&b.push('style="',i.join("; "),'" '),b.push(' class="cke_dialog_ui_vbox_child">',c[d],"</td></tr>")}return b.push("</tbody></table>"),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){return this.getInputElement().setValue(a),!b&&this.fire("change",{value:a}),this},getValue:function(){return this.getInputElement().getValue()},isChanged:function(){return!1},selectParentTab:function(){for(var a=this.getInputElement();(a=a.getParent())&&-1==a.$.className.search("cke_dialog_page_contents"););return a?(a=a.getAttribute("name"),this._.dialog._.currentTabId!=a&&this._.dialog.selectPage(a),this):this},focus:function(){return this.selectParentTab().getInputElement().focus(),this},registerEvents:function(a){var c,e,b=/^on([A-Z]\w+)/,d=function(a,b,c,d){b.on("load",function(){a.getInputElement().on(c,d,a)})};for(e in a)(c=e.match(b))&&(this.eventProcessors[e]?this.eventProcessors[e].call(this,this._.dialog,a[e]):d(this,this._.dialog,c[1].toLowerCase(),a[e]));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())}},CKEDITOR.ui.dialog.hbox.prototype=CKEDITOR.tools.extend(new CKEDITOR.ui.dialog.uiElement,{ 10getChild:function(a){return 1>arguments.length?this._.children.concat():(a.splice||(a=[a]),2>a.length?this._.children[a[0]]:this._.children[a[0]]&&this._.children[a[0]].getChild?this._.children[a[0]].getChild(a.slice(1,a.length)):null)}},!0),CKEDITOR.ui.dialog.vbox.prototype=new CKEDITOR.ui.dialog.hbox,function(){var a={build:function(a,b,c){for(var e,d=b.children,f=[],g=[],h=0;h<d.length&&(e=d[h]);h++){var i=[];f.push(i),g.push(CKEDITOR.dialog._.uiElementBuilders[e.type].build(a,e,i))}return new CKEDITOR.ui.dialog[b.type](a,g,f,c,b)}};CKEDITOR.dialog.addUIElement("hbox",a),CKEDITOR.dialog.addUIElement("vbox",a)}(),CKEDITOR.dialogCommand=function(a,b){this.dialogName=a,CKEDITOR.tools.extend(this,b,!0)},CKEDITOR.dialogCommand.prototype={exec:function(a){a.openDialog(this.dialogName)},canUndo:!1,editorFocus:1},function(){var a=/^([a]|[^a])+$/,b=/^\d*$/,c=/^\d*(?:\.\d+)?$/,d=/^(((\d*(\.\d+))|(\d*))(px|\%)?)?$/,e=/^(((\d*(\.\d+))|(\d*))(px|em|ex|in|cm|mm|pt|pc|\%)?)?$/i,f=/^(\s*[\w-]+\s*:\s*[^:;]+(?:;|$))*$/;CKEDITOR.VALIDATE_OR=1,CKEDITOR.VALIDATE_AND=2,CKEDITOR.dialog.validate={functions:function(){var a=arguments;return function(){var c,f,b=this&&this.getValue?this.getValue():a[0],d=CKEDITOR.VALIDATE_AND,e=[];for(f=0;f<a.length&&"function"==typeof a[f];f++)e.push(a[f]);f<a.length&&"string"==typeof a[f]&&(c=a[f],f++),f<a.length&&"number"==typeof a[f]&&(
10d=a[f]);var g=d==CKEDITOR.VALIDATE_AND;for(f=0;f<e.length;f++)g=d==CKEDITOR.VALIDATE_AND?g&&e[f](b):g||e[f](b);return!!g||c}},regex:function(a,b){return function(c){return c=this&&this.getValue?this.getValue():c,!!a.test(c)||b}},notEmpty:function(b){return this.regex(a,b)},integer:function(a){return this.regex(b,a)},number:function(a){return this.regex(c,a)},cssLength:function(a){return this.functions(function(a){return e.test(CKEDITOR.tools.trim(a))},a)},htmlLength:function(a){return this.functions(function(a){return d.test(CKEDITOR.tools.trim(a))},a)},inlineStyle:function(a){return this.functions(function(a){return f.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 w)w[c].remove();w={}}a=a.editor._.storedDialogs;for(var d in a)a[d].destroy()})}(),CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{openDialog:function(a,b){var c=null,d=CKEDITOR.dialog._.dialogDefinitions[a];if(null===CKEDITOR.dialog._.currentTop&&m(this),"function"==typeof d)c=this._.storedDialogs||(this._.storedDialogs={}),c=c[a]||(c[a]=new CKEDITOR.dialog(this,a)),b&&b.call(c,c),c.show();else{if("failed"==d)throw n(this),Error('[CKEDITOR.dialog.openDialog] Dialog "'+a+'" failed when loading definition.');"string"==typeof d&&CKEDITOR.scriptLoader.load(CKEDITOR.getUrl(d),function(){"function"!=typeof CKEDITOR.dialog._.dialogDefinitions[a]&&(CKEDITOR.dialog._.dialogDefinitions[a]="failed"),this.openDialog(a,b)},this,0,1)}return CKEDITOR.skin.loadPart("dialog"),c}})}(),CKEDITOR.plugins.add("dialog",{requires:"dialogui",init:function(a){a.on("doubleclick",function(b){b.data.dialog&&a.openDialog(b.data.dialog)},null,null,999)}}),CKEDITOR.plugins.add("about",{requires:"dialog",init:function(a){var b=a.addCommand("about",new CKEDITOR.dialogCommand("about"));b.modes={wysiwyg:1,source:1},b.canUndo=!1,b.readOnly=1,a.ui.addButton&&a.ui.addButton("About",{label:a.lang.about.title,command:"about",toolbar:"about"}),CKEDITOR.dialog.add("about",this.path+"dialogs/about.js")}}),function(){CKEDITOR.plugins.add("a11yhelp",{requires:"dialog",availableLangs:{af:1,ar:1,bg:1,ca:1,cs:1,cy:1,da:1,de:1,"de-ch":1,el:1,en: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,it:1,ja:1,km:1,ko:1,ku:1,lt:1,lv:1,mk:1,mn: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},init:function(a){var b=this;a.addCommand("a11yHelp",{exec:function(){var c=a.langCode,c=b.availableLangs[c]?c:b.availableLangs[c.replace(/-.*/,"")]?c.replace(/-.*/,""):"en";CKEDITOR.scriptLoader.load(CKEDITOR.getUrl(b.path+"dialogs/lang/"+c+".js"),function(){a.lang.a11yhelp=b.langEntries[c],a.openDialog("a11yHelp")})},modes:{wysiwyg:1,source:1},readOnly:1,canUndo:!1}),a.setKeystroke(CKEDITOR.ALT+48,"a11yHelp"),CKEDITOR.dialog.add("a11yHelp",this.path+"dialogs/a11yhelp.js"),a.on("ariaEditorHelpLabel",function(b){b.data.label=a.lang.common.editorHelp})}})}(),function(){function a(a){var b=this.att;a=a&&a.hasAttribute(b)&&a.getAttribute(b)||"",void 0!==a&&this.setValue(a)}function b(){for(var a,b=0;b<arguments.length;b++)if(arguments[b]instanceof CKEDITOR.dom.element){a=arguments[b];break}if(a){var b=this.att,c=this.getValue();c?a.setAttribute(b,c):a.removeAttribute(b,c)}}var c={id:1,dir:1,classes:1,styles:1};CKEDITOR.plugins.add("dialogadvtab",{requires:"dialog",allowedContent:function(a){a||(a=c);var b=[];a.id&&b.push("id"),a.dir&&b.push("dir");var d="";return b.length&&(d+="["+b.join(",")+"]"),a.classes&&(d+="(*)"),a.styles&&(d+="{*}"),d},createAdvancedTab:function(d,e,f){e||(e=c);var g=d.lang.common,h={id:"advanced",label:g.advancedTab,title:g.advancedTab,elements:[{type:"vbox",padding:1,children:[]}]},i=[];return(e.id||e.dir)&&(e.id&&i.push({id:"advId",att:"id",type:"text",requiredContent:f?f+"[id]":null,label:g.id,setup:a,commit:b}),e.dir&&i.push({id:"advLangDir",att:"dir",type:"select",requiredContent:f?f+"[dir]":null,label:g.langDir,default:"",style:"width:100%",items:[[g.notSet,""],[g.langDirLTR,"ltr"],[g.langDirRTL,"rtl"]],setup:a,commit:b}),h.elements[0].children.push({type:"hbox",widths:["50%","50%"],children:[].concat(i)}
10)),(e.styles||e.classes)&&(i=[],e.styles&&i.push({id:"advStyles",att:"style",type:"text",requiredContent:f?f+"{cke-xyz}":null,label:g.styles,default:"",validate:CKEDITOR.dialog.validate.inlineStyle(g.invalidInlineStyle),onChange:function(){},getStyle:function(a,b){var c=this.getValue().match(new RegExp("(?:^|;)\\s*"+a+"\\s*:\\s*([^;]*)","i"));return c?c[1]:b},updateStyle:function(a,b){var c=this.getValue(),e=d.document.createElement("span");e.setAttribute("style",c),e.setStyle(a,b),c=CKEDITOR.tools.normalizeCssText(e.getAttribute("style")),this.setValue(c,1)},setup:a,commit:b}),e.classes&&i.push({type:"hbox",widths:["45%","55%"],children:[{id:"advCSSClasses",att:"class",type:"text",requiredContent:f?f+"(cke-xyz)":null,label:g.cssClasses,default:"",setup:a,commit:b}]}),h.elements[0].children.push({type:"hbox",widths:["50%","50%"],children:[].concat(i)})),h}})}(),CKEDITOR.plugins.add("basicstyles",{init:function(a){var b=0,c=function(c,e,f,g){if(g){g=new CKEDITOR.style(g);var h=d[f];h.unshift(g),a.attachStyleStateChange(g,function(b){!a.readOnly&&a.getCommand(f).setState(b)}),a.addCommand(f,new CKEDITOR.styleCommand(g,{contentForms:h})),a.ui.addButton&&a.ui.addButton(c,{label:e,command:f,toolbar:"basicstyles,"+(b+=10)})}},d={bold:["strong","b",["span",function(a){return a=a.styles["font-weight"],"bold"==a||700<=+a}]],italic:["em","i",["span",function(a){return"italic"==a.styles["font-style"]}]],underline:["u",["span",function(a){return"underline"==a.styles["text-decoration"]}]],strike:["s","strike",["span",function(a){return"line-through"==a.styles["text-decoration"]}]],subscript:["sub"],superscript:["sup"]},e=a.config,f=a.lang.basicstyles;c("Bold",f.bold,"bold",e.coreStyles_bold),c("Italic",f.italic,"italic",e.coreStyles_italic),c("Underline",f.underline,"underline",e.coreStyles_underline),c("Strike",f.strike,"strike",e.coreStyles_strike),c("Subscript",f.subscript,"subscript",e.coreStyles_subscript),c("Superscript",f.superscript,"superscript",e.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(){function a(a,b,c,d){if(!a.isReadOnly()&&!a.equals(c.editable())){CKEDITOR.dom.element.setMarker(d,a,"bidi_processed",1),d=a;for(var e=c.editable();(d=d.getParent())&&!d.equals(e);)if(d.getCustomData("bidi_processed"))return a.removeStyle("direction"),void a.removeAttribute("dir");d="useComputedState"in c.config?c.config.useComputedState:1,(d?a.getComputedStyle("direction"):a.getStyle("direction")||a.hasAttribute("dir"))!=b&&(a.removeStyle("direction"),d?(a.removeAttribute("dir"),b!=a.getComputedStyle("direction")&&a.setAttribute("dir",b)):a.setAttribute("dir",b),c.forceNextSelectionCheck())}}function b(a,b,c){var d=a.getCommonAncestor(!1,!0);if(a=a.clone(),a.enlarge(c==CKEDITOR.ENTER_BR?CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS:CKEDITOR.ENLARGE_BLOCK_CONTENTS),a.checkBoundaryOfElement(d,CKEDITOR.START)&&a.checkBoundaryOfElement(d,CKEDITOR.END)){for(var e;d&&d.type==CKEDITOR.NODE_ELEMENT&&(e=d.getParent())&&1==e.getChildCount()&&!(d.getName()in b);)d=e;return d.type==CKEDITOR.NODE_ELEMENT&&d.getName()in b&&d}}function c(c){return{context:"p",allowedContent:{"h1 h2 h3 h4 h5 h6 table ul ol blockquote div tr p div li td":{propertiesOnly:!0,attributes:"dir"}},requiredContent:"p[dir]",refresh:function(a,b){var d,c=a.config.useComputedState,c=void 0===c||c;if(!c){d=b.lastElement;for(var e=a.editable();d&&!(d.getName()in g||d.equals(e));){var f=d.getParent();if(!f)break;d=f}}d=d||b.block||b.blockLimit,d.equals(a.editable())&&(e=a.getSelection().getRanges()[0].getEnclosedNode())&&e.type==CKEDITOR.NODE_ELEMENT&&(d=e),d&&(c=c?d.getComputedStyle("direction"):d.getStyle("direction")||d.getAttribute("dir"),a.getCommand("bidirtl").setState("rtl"==c?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF),a.getCommand("bidiltr").setState("ltr"==c?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF)),c=(b.block||b.blockLimit||a.editable()).getDirection(1),c!=(a._.selDir||a.lang.dir)&&(a._.selDir=c,a.fire("contentDirChanged",c))},exec:function(d){var g=d.getSelection(),h=d.config.enterMode,i=g.getRanges();if(i&&i.length){for(var l,j={},k=g.createBookmarks(),i=i.createIterator(),m=0;l=i.getNextRange(1);){var n=l.getEnclosedNode();n&&(!n||n.type==CKEDITOR.NODE_ELEMENT&&n.getName()in f)||(n=b(l,e,h)),n&&a(n,c,d,j);var o=new CKEDITOR.dom.walker(l),p=k[m].startNode,q=k[m++].endNode;o.evaluator=function(a){var c,b=h==CKEDITOR.ENTER_P?"p":"div";return(c=!!a&&a.type==CKEDITOR.NODE_ELEMENT&&a.getName()in e)&&((b=a.is(b))&&(b=!!(b=a.getParent())&&b.type==CKEDITOR.NODE_ELEMENT),c=!(b&&a.getParent().is("blockquote"))),!!(c&&a.getPosition(p)&CKEDITOR.POSITION_FOLLOWING&&(
10a.getPosition(q)&CKEDITOR.POSITION_PRECEDING+CKEDITOR.POSITION_CONTAINS)==CKEDITOR.POSITION_PRECEDING)};for(;n=o.next();)a(n,c,d,j);for(l=l.createIterator(),l.enlargeBr=h!=CKEDITOR.ENTER_BR;n=l.getNextParagraph(h==CKEDITOR.ENTER_P?"p":"div");)a(n,c,d,j)}CKEDITOR.dom.element.clearAllMarkers(j),d.forceNextSelectionCheck(),g.selectBookmarks(k),d.focus()}}}}function d(a){var b=a==h.setAttribute,c=a==h.removeAttribute,d=/\bdirection\s*:\s*(.*?)\s*(:?$|;)/;return function(e,f){if(!this.isReadOnly()){var g;if(g=e==(b||c?"dir":"direction")||"style"==e&&(c||d.test(f))){a:{g=this;for(var h=g.getDocument().getBody().getParent();g;){if(g.equals(h)){g=!1;break a}g=g.getParent()}g=!0}g=!g}if(g&&(g=this.getDirection(1),h=a.apply(this,arguments),g!=this.getDirection(1)))return this.getDocument().fire("dirChanged",this),h}return a.apply(this,arguments)}}var e={table:1,ul:1,ol:1,blockquote:1,div:1},f={},g={};CKEDITOR.tools.extend(f,e,{tr:1,p:1,div:1,li:1}),CKEDITOR.tools.extend(g,f,{td:1}),CKEDITOR.plugins.add("bidi",{init:function(a){function b(b,c,d,e,f){a.addCommand(d,new CKEDITOR.command(a,e)),a.ui.addButton&&a.ui.addButton(b,{label:c,command:d,toolbar:"bidi,"+f})}if(!a.blockless){var d=a.lang.bidi;b("BidiLtr",d.ltr,"bidiltr",c("ltr"),10),b("BidiRtl",d.rtl,"bidirtl",c("rtl"),20),a.on("contentDom",function(){a.document.on("dirChanged",function(b){a.fire("dirChanged",{node:b.data,dir:b.data.getDirection(1)})})}),a.on("contentDirChanged",function(b){b=(a.lang.dir!=b.data?"add":"remove")+"Class";var c=a.ui.space(a.config.toolbarLocation);c&&c[b]("cke_mixed_dir_content")})}}});for(var h=CKEDITOR.dom.element.prototype,i=["setStyle","removeStyle","setAttribute","removeAttribute"],j=0;j<i.length;j++)h[i[j]]=CKEDITOR.tools.override(h[i[j]],d)}(),function(){var a={exec:function(a){var b=a.getCommand("blockquote").state,c=a.getSelection(),d=c&&c.getRanges()[0];if(d){var e=c.createBookmarks();if(CKEDITOR.env.ie){var h,f=e[0].startNode,g=e[0].endNode;if(f&&"blockquote"==f.getParent().getName())for(h=f;h=h.getNext();)if(h.type==CKEDITOR.NODE_ELEMENT&&h.isBlockBoundary()){f.move(h,!0);break}if(g&&"blockquote"==g.getParent().getName())for(h=g;h=h.getPrevious();)if(h.type==CKEDITOR.NODE_ELEMENT&&h.isBlockBoundary()){g.move(h);break}}var i=d.createIterator();if(i.enlargeBr=a.config.enterMode!=CKEDITOR.ENTER_BR,b==CKEDITOR.TRISTATE_OFF){for(f=[];b=i.getNextParagraph();)f.push(b);for(1>f.length&&(b=a.document.createElement(a.config.enterMode==CKEDITOR.ENTER_P?"p":"div"),g=e.shift(),d.insertNode(b),b.append(new CKEDITOR.dom.text("\ufeff",a.document)),d.moveToBookmark(g),d.selectNodeContents(b),d.collapse(!0),g=d.createBookmark(),f.push(b),e.unshift(g)),h=f[0].getParent(),d=[],g=0;g<f.length;g++)b=f[g],h=h.getCommonAncestor(b.getParent());for(b={table:1,tbody:1,tr:1,ol:1,ul:1};b[h.getName()];)h=h.getParent();for(g=null;0<f.length;){for(b=f.shift();!b.getParent().equals(h);)b=b.getParent();b.equals(g)||d.push(b),g=b}for(;0<d.length;)if(b=d.shift(),"blockquote"==b.getName()){for(g=new CKEDITOR.dom.documentFragment(a.document);b.getFirst();)g.append(b.getFirst().remove()),f.push(g.getLast());g.replace(b)}else f.push(b);for(d=a.document.createElement("blockquote"),d.insertBefore(f[0]);0<f.length;)b=f.shift(),d.append(b)}else if(b==CKEDITOR.TRISTATE_ON){for(g=[],h={};b=i.getNextParagraph();){for(f=d=null;b.getParent();){if("blockquote"==b.getParent().getName()){d=b.getParent(),f=b;break}b=b.getParent()}d&&f&&!f.getCustomData("blockquote_moveout")&&(g.push(f),CKEDITOR.dom.element.setMarker(h,f,"blockquote_moveout",!0))}for(CKEDITOR.dom.element.clearAllMarkers(h),b=[],f=[],h={};0<g.length;)i=g.shift(),d=i.getParent(),i.getPrevious()?i.getNext()?(i.breakParent(i.getParent()),f.push(i.getNext())):i.remove().insertAfter(d):i.remove().insertBefore(d),d.getCustomData("blockquote_processed")||(f.push(d),CKEDITOR.dom.element.setMarker(h,d,"blockquote_processed",!0)),b.push(i);for(CKEDITOR.dom.element.clearAllMarkers(h),g=f.length-1;0<=g;g--){d=f[g];a:{h=d;for(var i=0,j=h.getChildCount(),k=void 0;i<j&&(k=h.getChild(i));i++)if(k.type==CKEDITOR.NODE_ELEMENT&&k.isBlockBoundary()){h=!1;break a}h=!0}h&&d.remove()}if(a.config.enterMode==CKEDITOR.ENTER_BR)for(d=!0;b.length;)if(i=b.shift(),"div"==i.getName()){for(g=new CKEDITOR.dom.documentFragment(a.document),!d||!i.getPrevious()||i.getPrevious().type==CKEDITOR.NODE_ELEMENT&&i.getPrevious().isBlockBoundary()||g.append(a.document.createElement("br")),d=i.getNext()&&!(i.getNext().type==CKEDITOR.NODE_ELEMENT&&i.getNext().isBlockBoundary());i.getFirst();)i.getFirst().remove().appendTo(g);d&&g.append(a.document.createElement("br")),g.replace(i),d=!1}}c.selectBookmarks(e),a.focus()}},refresh:function(a,b){this.setState(a.elementPath(b.block||b.blockLimit).contains("blockquote",1)?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF)},context:"blockquote",allowedContent:"blockquote",requiredContent:"blockquote"};CKEDITOR.plugins.add("blockquote",{init:function(b){b.blockless||(b.addCommand("blockquote",a),b.ui.addButton&&b.ui.addButton("Blockquote",{label:b.lang.blockquote.toolbar,command:"blockquote",toolbar:"blocks,10"}))}})}(),function(){function a(a,b,c){return b.type||(b.type="auto"),!(c&&!1===a.fire("beforePaste",b)||!b.dataValue&&b.dataTransfer.isEmpty())&&(b.dataValue||(b.dataValue=""),CKEDITOR.env.gecko&&"drop"==b.method&&a.toolbox&&a.once("afterPaste",function(){a.toolbox.focus()}),a.fire("paste",b))}function b(b){function c(){var a=b.editable();if(CKEDITOR.plugins.clipboard.isCustomCopyCutSupported){var c=function(a){b.readOnly&&"cut"==a.name||p.initPasteDataTransfer(a,b),a.data.preventDefault()};a.on("copy",c),a.on("cut",c),a.on("cut",function(){b.readOnly||b.extractSelectedHtml()},null,null,999)}a.on(p.mainPasteEvent,function(a){"beforepaste"==p.mainPasteEvent&&q||m(a)}),"beforepaste"==p.mainPasteEvent&&(a.on("paste",function(a){r||(f(),a.data.preventDefault(),m(a),h("paste")||b.openDialog("paste"))}),a.on("contextmenu",g,null,null,0),a.on("beforepaste",function(a){!a.data||a.data.$.ctrlKey||a.data.$.shiftKey||g()},null,null,0)),a.on("beforecut",function(){!q&&i(b)});var d;a.attachListener(CKEDITOR.env.ie?a:b.document.getDocumentElement(),"mouseup",function(){d=setTimeout(function(){n()},0)}),b.on("destroy",function(){clearTimeout(d)}),a.on("keyup",n)}function d(a){return{type:a,canUndo:"cut"==a,startDisabled:!0,exec:function(){"cut"==this.type&&i();var a,c=this.type;if(CKEDITOR.env.ie)a=h(c);else try{a=b.document.$.execCommand(c,!1,null)}catch(b){a=!1}return a||b.showNotification(b.lang.clipboard[this.type+"Error"]),a}}}function e(){return{canUndo:!1,async:!0,exec:function(b,c){var d=this,e=function(c,e){c&&a(b,c,!!e),b.fire("afterCommandExec",{name:"paste",command:d,returnValue:!!c})};"string"==typeof c?e({dataValue:c,method:"paste",dataTransfer:p.initPasteDataTransfer()},1):b.getClipboardData(e)}}}function f(){r=1,setTimeout(function(){r=0},100)}function g(){q=1,setTimeout(function(){q=0},10)}function h(a){var c=b.document,d=c.getBody(),e=!1,f=function(){e=!0};return d.on(a,f),7<CKEDITOR.env.version?c.$.execCommand(a):c.$.selection.createRange().execCommand(a),d.removeListener(a,f),e}function i(){if(CKEDITOR.env.ie&&!CKEDITOR.env.quirks){var c,d,e,a=b.getSelection();a.getType()==CKEDITOR.SELECTION_ELEMENT&&(c=a.getSelectedElement())&&(d=a.getRanges()[0],e=b.document.createText(""),e.insertBefore(c),d.setStartBefore(e),d.setEndAfter(c),a.selectRanges([d]
10),setTimeout(function(){c.getParent()&&(e.remove(),a.selectElement(c))},0))}}function j(a,c){var g,d=b.document,e=b.editable(),f=function(a){a.cancel()};if(!d.getById("cke_pastebin")){var h=b.getSelection(),i=h.createBookmarks();CKEDITOR.env.ie&&h.root.fire("selectionchange");var j=new CKEDITOR.dom.element(!CKEDITOR.env.webkit&&!e.is("body")||CKEDITOR.env.ie?"div":"body",d);j.setAttributes({id:"cke_pastebin","data-cke-temp":"1"});var k=0,d=d.getWindow();CKEDITOR.env.webkit?(e.append(j),j.addClass("cke_editable"),e.is("body")||(k="static"!=e.getComputedStyle("position")?e:CKEDITOR.dom.element.get(e.$.offsetParent),k=k.getDocumentPosition().y)):e.getAscendant(CKEDITOR.env.ie?"body":"html",1).append(j),j.setStyles({position:"absolute",top:d.getScrollPosition().y-k+10+"px",width:"1px",height:Math.max(1,d.getViewPaneSize().height-20)+"px",overflow:"hidden",margin:0,padding:0}),CKEDITOR.env.safari&&j.setStyles(CKEDITOR.tools.cssVendorPrefix("user-select","text")),(k=j.getParent().isReadOnly())?(j.setOpacity(0),j.setAttribute("contenteditable",!0)):j.setStyle("ltr"==b.config.contentsLangDirection?"left":"right","-10000px"),b.on("selectionChange",f,null,null,0),(CKEDITOR.env.webkit||CKEDITOR.env.gecko)&&(g=e.once("blur",f,null,null,-100)),k&&j.focus(),k=new CKEDITOR.dom.range(j),k.selectNodeContents(j);var l=k.select();CKEDITOR.env.ie&&(g=e.once("blur",function(){b.lockSelection(l)}));var m=CKEDITOR.document.getWindow().getScrollPosition().y;setTimeout(function(){CKEDITOR.env.webkit&&(CKEDITOR.document.getBody().$.scrollTop=m),g&&g.removeListener(),CKEDITOR.env.ie&&e.focus(),h.selectBookmarks(i),j.remove();var a;CKEDITOR.env.webkit&&(a=j.getFirst())&&a.is&&a.hasClass("Apple-style-span")&&(j=a),b.removeListener("selectionChange",f),c(j.getHtml())},0)}}function k(){if("paste"==p.mainPasteEvent)return b.fire("beforePaste",{type:"auto",method:"paste"}),!1;b.focus(),f();var a=b.focusManager;return a.lock(),b.editable().fire(p.mainPasteEvent)&&!h("paste")?(a.unlock(),!1):(a.unlock(),!0)}function l(a){if("wysiwyg"==b.mode)switch(a.data.keyCode){case CKEDITOR.CTRL+86:case CKEDITOR.SHIFT+45:a=b.editable(),f(),"paste"==p.mainPasteEvent&&a.fire("beforepaste");break;case CKEDITOR.CTRL+88:case CKEDITOR.SHIFT+46:b.fire("saveSnapshot"),setTimeout(function(){b.fire("saveSnapshot")},50)}}function m(c){var d={type:"auto",method:"paste",dataTransfer:p.initPasteDataTransfer(c)};d.dataTransfer.cacheData();var e=!1!==b.fire("beforePaste",d);e&&p.canClipboardApiBeTrusted(d.dataTransfer,b)?(c.data.preventDefault(),setTimeout(function(){a(b,d)},0)):j(c,function(c){d.dataValue=c.replace(/<span[^>]+data-cke-bookmark[^<]*?<\/span>/gi,""),e&&a(b,d)})}function n(){if("wysiwyg"==b.mode){var a=o("paste");b.getCommand("cut").setState(o("cut")),b.getCommand("copy").setState(o("copy")),b.getCommand("paste").setState(a),b.fire("pasteState",a)}}function o(a){if(s&&a in{paste:1,cut:1})return CKEDITOR.TRISTATE_DISABLED;if("paste"==a)return CKEDITOR.TRISTATE_OFF;a=b.getSelection();var c=a.getRanges();return a.getType()==CKEDITOR.SELECTION_NONE||1==c.length&&c[0].collapsed?CKEDITOR.TRISTATE_DISABLED:CKEDITOR.TRISTATE_OFF}var p=CKEDITOR.plugins.clipboard,q=0,r=0,s=0;!function(){b.on("key",l),b.on("contentDom",c),b.on("selectionChange",function(a){s=a.data.selection.getRanges()[0].checkReadOnly(),n()}),b.contextMenu&&b.contextMenu.addListener(function(a,b){return s=b.getRanges()[0].checkReadOnly(),{cut:o("cut"),copy:o("copy"),paste:o("paste")}})}(),function(){function a(a,c,d,e,f){var g=b.lang.clipboard[c];b.addCommand(c,d),b.ui.addButton&&b.ui.addButton(a,{label:g,command:c,toolbar:"clipboard,"+e}),b.addMenuItems&&b.addMenuItem(c,{label:g,command:c,group:"clipboard",order:f})}a("Cut","cut",d("cut"),10,1),a("Copy","copy",d("copy"),20,4),a("Paste","paste",e(),30,8)}(),b.getClipboardData=function(a,c){function d(a){a.removeListener(),a.cancel(),c(a.data)}function e(a){a.removeListener(),a.cancel(),i=!0,c({type:h,dataValue:a.data.dataValue,dataTransfer:a.data.dataTransfer,method:"paste"})}function f(){this.customTitle=a&&a.title}var g=!1,h="auto",i=!1;c||(c=a,a=null),b.on("paste",d,null,null,0),b.on("beforePaste",function(a){a.removeListener(),g=!0,h=a.data.type}
10,null,null,1e3),!1===k()&&(b.removeListener("paste",d),g&&b.fire("pasteDialog",f)?(b.on("pasteDialogCommit",e),b.on("dialogHide",function(a){a.removeListener(),a.data.removeListener("pasteDialogCommit",e),setTimeout(function(){i||c(null)},10)})):c(null))}}function c(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)return"html";if(!a.match(/^([^<]|<br( ?\/)?>)*$/gi))return"html"}return"htmlifiedtext"}function d(a,b){function c(a){return CKEDITOR.tools.repeat("</p><p>",~~(a/2))+(1==a%2?"<br>":"")}return b=b.replace(/\s+/g," ").replace(/> +</g,"><").replace(/<br ?\/>/gi,"<br>"),b=b.replace(/<\/?[A-Z]+>/g,function(a){return a.toLowerCase()}),b.match(/^[^<]$/)?b:(CKEDITOR.env.webkit&&-1<b.indexOf("<div>")&&(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,"")),CKEDITOR.env.gecko&&a.enterMode!=CKEDITOR.ENTER_BR&&(CKEDITOR.env.gecko&&(b=b.replace(/^<br><br>$/,"<br>")),-1<b.indexOf("<br><br>")&&(b="<p>"+b.replace(/(<br>){2,}/g,function(a){return c(a.length/4)})+"</p>")),g(a,b))}function e(){function a(){var b,a={};for(b in CKEDITOR.dtd)"$"!=b.charAt(0)&&"div"!=b&&"span"!=b&&(a[b]=1);return a}var b={};return{get:function(c){return"plain-text"==c?b.plainText||(b.plainText=new CKEDITOR.filter("br")):"semantic-content"==c?((c=b.semanticContent)||(c=new CKEDITOR.filter,c.allow({$1:{elements:a(),attributes:!0,styles:!1,classes:!1}}),c=b.semanticContent=c),c):c?new CKEDITOR.filter(c):null}}}function f(a,b,c){b=CKEDITOR.htmlParser.fragment.fromHtml(b);var d=new CKEDITOR.htmlParser.basicWriter;return c.applyTo(b,!0,!1,a.activeEnterMode),b.writeHtml(d),d.getHtml()}function g(a,b){return 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>")),b}function h(a){a.data.preventDefault(),a.data.$.dataTransfer.dropEffect="none"}function i(b){var c=CKEDITOR.plugins.clipboard;b.on("contentDom",function(){function d(c,d,e){d.select(),a(b,{dataTransfer:e,method:"drop"},1),e.sourceEditor.fire("saveSnapshot"),e.sourceEditor.editable().extractHtmlFromRange(c),e.sourceEditor.getSelection().selectRanges([c]),e.sourceEditor.fire("saveSnapshot")}function e(d,e){d.select(),a(b,{dataTransfer:e,method:"drop"},1),c.resetDragDataTransfer()}function f(a,c,d){var e={$:a.data.$,target:a.data.getTarget()};c&&(e.dragRange=c),d&&(e.dropRange=d),!1===b.fire(a.name,e)&&a.data.preventDefault()}function g(a){return a.type!=CKEDITOR.NODE_ELEMENT&&(a=a.getParent()),a.getChildCount()}var h=b.editable(),i=CKEDITOR.plugins.clipboard.getDropTarget(b),j=b.ui.space("top"),k=b.ui.space("bottom");c.preventDefaultDropOnElement(j),c.preventDefaultDropOnElement(k),h.attachListener(i,"dragstart",f),h.attachListener(b,"dragstart",c.resetDragDataTransfer,c,null,1),h.attachListener(b,"dragstart",function(a){c.initDragDataTransfer(a,b)},null,null,2),h.attachListener(b,"dragstart",function(){var a=c.dragRange=b.getSelection().getRanges()[0];CKEDITOR.env.ie&&10>CKEDITOR.env.version&&(c.dragStartContainerChildCount=a?g(a.startContainer):null,c.dragEndContainerChildCount=a?g(a.endContainer):null)},null,null,100),h.attachListener(i,"dragend",f),h.attachListener(b,"dragend",c.initDragDataTransfer,c,null,1),h.attachListener(b,"dragend",c.resetDragDataTransfer,c,null,100),h.attachListener(i,"dragover",function(a){var b=a.data.getTarget();b&&b.is&&b.is("html")?a.data.preventDefault():CKEDITOR.env.ie&&CKEDITOR.plugins.clipboard.isFileApiSupported&&a.data.$.dataTransfer.types.contains("Files")&&a.data.preventDefault()}
10),h.attachListener(i,"drop",function(a){if(!a.data.$.defaultPrevented){a.data.preventDefault();var d=a.data.getTarget();if(!d.isReadOnly()||d.type==CKEDITOR.NODE_ELEMENT&&d.is("html")){var d=c.getRangeAtDropPosition(a,b),e=c.dragRange;d&&f(a,e,d)}}},null,null,9999),h.attachListener(b,"drop",c.initDragDataTransfer,c,null,1),h.attachListener(b,"drop",function(a){if(a=a.data){var f=a.dropRange,g=a.dragRange,h=a.dataTransfer;h.getTransferType(b)==CKEDITOR.DATA_TRANSFER_INTERNAL?setTimeout(function(){c.internalDrop(g,f,h,b)},0):h.getTransferType(b)==CKEDITOR.DATA_TRANSFER_CROSS_EDITORS?d(g,f,h):e(f,h)}},null,null,9999)})}CKEDITOR.plugins.add("clipboard",{requires:"dialog",init:function(a){var g,h=e();a.config.forcePasteAsPlainText?g="plain-text":a.config.pasteFilter?g=a.config.pasteFilter:!CKEDITOR.env.webkit||"pasteFilter"in a.config||(g="semantic-content"),a.pasteFilter=h.get(g),b(a),i(a),CKEDITOR.dialog.add("paste",CKEDITOR.getUrl(this.path+"dialogs/paste.js")),a.on("paste",function(b){if(b.data.dataTransfer||(b.data.dataTransfer=new CKEDITOR.plugins.clipboard.dataTransfer),!b.data.dataValue){var c=b.data.dataTransfer,d=c.getData("text/html");d?(b.data.dataValue=d,b.data.type="html"):(d=c.getData("text/plain"))&&(b.data.dataValue=a.editable().transformPlainTextToHtml(d),b.data.type="text")}},null,null,1),a.on("paste",function(a){var b=a.data.dataValue,c=CKEDITOR.dtd.$block;if(-1<b.indexOf("Apple-")&&(b=b.replace(/<span class="Apple-converted-space"> <\/span>/gi," "),"html"!=a.data.type&&(b=b.replace(/<span class="Apple-tab-span"[^>]*>([^<]*)<\/span>/gi,function(a,b){return b.replace(/\t/g," ")})),-1<b.indexOf('<br class="Apple-interchange-newline">')&&(a.data.startsWithEOL=1,a.data.preSniffing="html",b=b.replace(/<br class="Apple-interchange-newline">/,"")),b=b.replace(/(<[^>]+) class="Apple-[^"]*"/gi,"$1")),b.match(/^<[^<]+cke_(editable|contents)/i)){var d,e,f=new CKEDITOR.dom.element("div");for(f.setHtml(b);1==f.getChildCount()&&(d=f.getFirst())&&d.type==CKEDITOR.NODE_ELEMENT&&(d.hasClass("cke_editable")||d.hasClass("cke_contents"));)f=e=d;e&&(b=e.getHtml().replace(/<br>$/i,""))}CKEDITOR.env.ie?b=b.replace(/^ (?: |\r\n)?<(\w+)/g,function(b,d){return d.toLowerCase()in c?(a.data.preSniffing="html","<"+d):b}):CKEDITOR.env.webkit?b=b.replace(/<\/(\w+)><div><br><\/div>$/,function(b,d){return d in c?(a.data.endsWithEOL=1,"</"+d+">"):b}):CKEDITOR.env.gecko&&(b=b.replace(/(\s)<br>$/,"$1")),a.data.dataValue=b},null,null,3),a.on("paste",function(b){b=b.data;var i,e=b.type,g=b.dataValue,j=a.config.clipboard_defaultContentType||"html",k=b.dataTransfer.getTransferType(a);i="html"==e||"html"==b.preSniffing?"html":c(g),"htmlifiedtext"==i&&(g=d(a.config,g)),"text"==e&&"html"==i?g=f(a,g,h.get("plain-text")):k==CKEDITOR.DATA_TRANSFER_EXTERNAL&&a.pasteFilter&&!b.dontFilter&&(g=f(a,g,a.pasteFilter)),b.startsWithEOL&&(g='<br data-cke-eol="1">'+g),b.endsWithEOL&&(g+='<br data-cke-eol="1">'),"auto"==e&&(e="html"==i||"html"==j?"html":"text"),b.type=e,b.dataValue=g,delete b.preSniffing,delete b.startsWithEOL,delete b.endsWithEOL},null,null,6),a.on("paste",function(b){b=b.data,b.dataValue&&(a.insertHtml(b.dataValue,b.type,b.range),setTimeout(function(){a.fire("afterPaste")},0))},null,null,1e3),a.on("pasteDialog",function(b){setTimeout(function(){a.openDialog("paste",b.data)},0)})}}),CKEDITOR.plugins.clipboard={isCustomCopyCutSupported:!CKEDITOR.env.ie&&!CKEDITOR.env.iOS,isCustomDataTypesSupported:!CKEDITOR.env.ie,isFileApiSupported:!CKEDITOR.env.ie||9<CKEDITOR.env.version,mainPasteEvent:CKEDITOR.env.ie&&!CKEDITOR.env.edge?"beforepaste":"paste",canClipboardApiBeTrusted:function(a,b){return!!(a.getTransferType(b)!=CKEDITOR.DATA_TRANSFER_EXTERNAL||CKEDITOR.env.chrome&&!a.isEmpty()||CKEDITOR.env.gecko&&(a.getData("text/html")||a.getFilesCount()))},getDropTarget:function(a){var b=a.editable();return CKEDITOR.env.ie&&9>CKEDITOR.env.version||b.isInline()?b:a.document},fixSplitNodesAfterDrop:function(a,b,c,d){function e(a,c,d){var e=a;if(e.type==CKEDITOR.NODE_TEXT&&(e=a.getParent()),e.equals(c)&&d!=c.getChildCount())return a=b.startContainer.getChild(b.startOffset-1),c=b.startContainer.getChild(b.startOffset),a&&a.type==CKEDITOR.NODE_TEXT&&c&&c.type==CKEDITOR.NODE_TEXT&&(d=a.getLength(),a.setText(a.getText()+c.getText()),c.remove(),b.setStart(a,d),b.collapse(!0)),!0}var f=b.startContainer;"number"==typeof d&&"number"==typeof c&&f.type==CKEDITOR.NODE_ELEMENT&&(e(a.startContainer,f,c)||e(a.endContainer,f,d))},isDropRangeAffectedByDragRange:function(a,b){var c=b.startContainer,d=b.endOffset;return!!(a.endContainer.equals(c)&&a.endOffset<=d||a.startContainer.getParent().equals(c)&&a.startContainer.getIndex()<d||a.endContainer.getParent().equals(c)&&a.endContainer.getIndex()<d)},internalDrop:function(b,c,d,e){var h,i,f=CKEDITOR.plugins.clipboard,g=e.editable();e.fire("saveSnapshot"),e.fire("lockSnapshot",{dontUpdate:1}),CKEDITOR.env.ie&&10>CKEDITOR.env.version&&this.fixSplitNodesAfterDrop(b,c,f.dragStartContainerChildCount,f.dragEndContainerChildCount),(i=this.isDropRangeAffectedByDragRange(b,c)
10)||(h=b.createBookmark(!1)),f=c.clone().createBookmark(!1),i&&(h=b.createBookmark(!1)),b=h.startNode,c=h.endNode,i=f.startNode,c&&b.getPosition(i)&CKEDITOR.POSITION_PRECEDING&&c.getPosition(i)&CKEDITOR.POSITION_FOLLOWING&&i.insertBefore(b),b=e.createRange(),b.moveToBookmark(h),g.extractHtmlFromRange(b,1),c=e.createRange(),c.moveToBookmark(f),a(e,{dataTransfer:d,method:"drop",range:c},1),e.fire("unlockSnapshot")},getRangeAtDropPosition:function(a,b){ 11var c=a.data.$,d=c.clientX,e=c.clientY,f=b.getSelection(!0).getRanges()[0],g=b.createRange();if(a.data.testRange)return a.data.testRange;if(document.caretRangeFromPoint)c=b.document.$.caretRangeFromPoint(d,e),g.setStart(CKEDITOR.dom.node(c.startContainer),c.startOffset),g.collapse(!0);else if(c.rangeParent)g.setStart(CKEDITOR.dom.node(c.rangeParent),c.rangeOffset),g.collapse(!0);else{if(CKEDITOR.env.ie&&8<CKEDITOR.env.version&&f&&b.editable().hasFocus)return f;if(!document.body.createTextRange)return null;b.focus(),c=b.document.getBody().$.createTextRange();try{for(var h=!1,i=0;20>i&&!h;i++){if(!h)try{c.moveToPoint(d,e-i),h=!0}catch(a){}if(!h)try{c.moveToPoint(d,e+i),h=!0}catch(a){}}if(h){var j="cke-temp-"+(new Date).getTime();c.pasteHTML('<span id="'+j+'">â</span>');var k=b.document.getById(j);g.moveToPosition(k,CKEDITOR.POSITION_BEFORE_START),k.remove()}else{var n,l=b.document.$.elementFromPoint(d,e),m=new CKEDITOR.dom.element(l);if(m.equals(b.editable())||"html"==m.getName())return f&&f.startContainer&&!f.startContainer.equals(b.editable())?f:null;n=m.getClientRect(),d<n.left?g.setStartAt(m,CKEDITOR.POSITION_AFTER_START):g.setStartAt(m,CKEDITOR.POSITION_BEFORE_END),g.collapse(!0)}}catch(a){return null}}return g},initDragDataTransfer:function(a,b){var c=a.data.$?a.data.$.dataTransfer:null,d=new this.dataTransfer(c,b);c?this.dragData&&d.id==this.dragData.id?d=this.dragData:this.dragData=d:this.dragData?d=this.dragData:this.dragData=d,a.data.dataTransfer=d},resetDragDataTransfer:function(){this.dragData=null},initPasteDataTransfer:function(a,b){if(this.isCustomCopyCutSupported&&a&&a.data&&a.data.$){var c=new this.dataTransfer(a.data.$.clipboardData,b);return this.copyCutData&&c.id==this.copyCutData.id?(c=this.copyCutData,c.$=a.data.$.clipboardData):this.copyCutData=c,c}return new this.dataTransfer(null,b)},preventDefaultDropOnElement:function(a){a&&a.on("dragover",h)}};var j=CKEDITOR.plugins.clipboard.isCustomDataTypesSupported?"cke/id":"Text";CKEDITOR.plugins.clipboard.dataTransfer=function(a,b){if(a&&(this.$=a),this._={metaRegExp:/^<meta.*?>/i,bodyRegExp:/<body(?:[\s\S]*?)>([\s\S]*)<\/body>/i,fragmentRegExp:/\x3c!--(?:Start|End)Fragment--\x3e/g,data:{},files:[],normalizeType:function(a){return a=a.toLowerCase(),"text"==a||"text/plain"==a?"Text":"url"==a?"URL":a}},this.id=this.getData(j),this.id||(this.id="Text"==j?"":"cke-"+CKEDITOR.tools.getUniqueId()),"Text"!=j)try{this.$.setData(j,this.id)}catch(a){}b&&(this.sourceEditor=b,this.setData("text/html",b.getSelectedHtml(1)),"Text"==j||this.getData("text/plain")||this.setData("text/plain",b.getSelection().getSelectedText()))},CKEDITOR.DATA_TRANSFER_INTERNAL=1,CKEDITOR.DATA_TRANSFER_CROSS_EDITORS=2,CKEDITOR.DATA_TRANSFER_EXTERNAL=3,CKEDITOR.plugins.clipboard.dataTransfer.prototype={getData:function(a){a=this._.normalizeType(a);var b=this._.data[a];if(void 0===b||null===b||""===b)try{b=this.$.getData(a)}catch(a){}return void 0!==b&&null!==b&&""!==b||(b=""),"text/html"==a?(b=b.replace(this._.metaRegExp,""),(a=this._.bodyRegExp.exec(b))&&a.length&&(b=a[1],b=b.replace(this._.fragmentRegExp,""))):"Text"==a&&CKEDITOR.env.gecko&&this.getFilesCount()&&"file://"==b.substring(0,7)&&(b=""),b},setData:function(a,b){if(a=this._.normalizeType(a),this._.data[a]=b,CKEDITOR.plugins.clipboard.isCustomDataTypesSupported||"URL"==a||"Text"==a){"Text"==j&&"Text"==a&&(this.id=b);try{this.$.setData(a,b)}catch(a){}}},getTransferType:function(a){return this.sourceEditor?this.sourceEditor==a?CKEDITOR.DATA_TRANSFER_INTERNAL:CKEDITOR.DATA_TRANSFER_CROSS_EDITORS:CKEDITOR.DATA_TRANSFER_EXTERNAL},cacheData:function(){function a(a){a=b._.normalizeType(a);var c=b.getData(a);c&&(b._.data[a]=c)}if(this.$){var c,d,b=this;if(CKEDITOR.plugins.clipboard.isCustomDataTypesSupported){if(this.$.types)for(c=0;c<this.$.types.length;c++)a(this.$.types[c])}else a("Text"),a("URL");if(d=this._getImageFromClipboard(),this.$&&this.$.files||d){for(this._.files=[],c=0;c<this.$.files.length;c++)this._.files.push(this.$.files[c]);0===this._.files.length&&d&&this._.files.push(d)}}},getFilesCount:function(){return this._.files.length?this._.files.length:this.$&&this.$.files&&this.$.files.length?this.$.files.length:this._getImageFromClipboard()?1:0},getFile:function(a){return this._.files.length?this._.files[a]:this.$&&this.$.files&&this.$.files.length?this.$.files[a]:0===a?this._getImageFromClipboard():void 0},isEmpty:function(){var b,a={};if(this.getFilesCount())return!1;for(b in this._.data)a[b]=1;if(this.$)if(CKEDITOR.plugins.clipboard.isCustomDataTypesSupported){if(this.$.types)for(var c=0;c<this.$.types.length;c++)a[this.$.types[c]]=1}else a.Text=1,a.URL=1;"Text"!=j&&(a[j]=0);for(b in a)if(a[b]&&""!==this.getData(b))return!1;return!0},_getImageFromClipboard:function(){var a;
11if(this.$&&this.$.items&&this.$.items[0])try{if((a=this.$.items[0].getAsFile())&&a.type)return a}catch(a){}}}}(),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+=' onkeypress="return false;"'),CKEDITOR.env.gecko&&(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+'> </span><span id="{id}_label" class="cke_button_label cke_button__{name}_label" aria-hidden="false">{label}</span>{arrowHtml}</a>',b=CKEDITOR.addTemplate("buttonArrow",'<span class="cke_button_arrow">'+(CKEDITOR.env.hc?"▼":"")+"</span>"),c=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,d){function e(){var b=a.mode;b&&(b=this.modes[b]?void 0!==o[b]?o[b]:CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,b=a.readOnly&&!this.readOnly?CKEDITOR.TRISTATE_DISABLED:b,this.setState(b),this.refresh&&this.refresh())}var j,f=CKEDITOR.env,g=this._.id=CKEDITOR.tools.getNextId(),h="",i=this.command;this._.editor=a;var k={id:g,button:this,editor:a,focus:function(){CKEDITOR.document.getById(g).focus()},execute:function(){this.button.click(a)},attach:function(a){this.button.attach(a)}},l=CKEDITOR.tools.addFunction(function(a){if(k.onkey)return a=new CKEDITOR.dom.event(a),!1!==k.onkey(k,a.getKeystroke())}),m=CKEDITOR.tools.addFunction(function(a){var b;return k.onfocus&&(b=!1!==k.onfocus(k,new CKEDITOR.dom.event(a))),b}),n=0;if(k.clickFn=j=CKEDITOR.tools.addFunction(function(){n&&(a.unlockSelection(1),n=0),k.execute(),f.iOS&&a.focus()}),this.modes){var o={};a.on("beforeModeUnload",function(){a.mode&&this._.state!=CKEDITOR.TRISTATE_DISABLED&&(o[a.mode]=this._.state)},this),a.on("activeFilterChange",e,this),a.on("mode",e,this),!this.readOnly&&a.on("readOnly",e,this)}else i&&(i=a.getCommand(i))&&(i.on("state",function(){this.setState(i.state)},this),h+=i.state==CKEDITOR.TRISTATE_ON?"on":i.state==CKEDITOR.TRISTATE_DISABLED?"disabled":"off");this.directional&&a.on("contentDirChanged",function(b){var c=CKEDITOR.document.getById(this._.id),d=c.getFirst();b=b.data,b!=a.lang.dir?c.addClass("cke_"+b):c.removeClass("cke_ltr").removeClass("cke_rtl"),d.setAttribute("style",CKEDITOR.skin.getIconStyle(q,"rtl"==b,this.icon,this.iconOffset))},this),i||(h+="off");var p=this.name||this.command,q=p;return this.icon&&!/\./.test(this.icon)&&(q=this.icon,this.icon=null),h={id:g,name:p,iconName:q,label:this.label,cls:this.className||"",state:h,ariaDisabled:"disabled"==h?"true":"false",title:this.title,titleJs:f.gecko&&!f.hc?"":(this.title||"").replace("'",""),hasArrow:this.hasArrow?"true":"false",keydownFn:l,focusFn:m,clickFn:j,style:CKEDITOR.skin.getIconStyle(q,"rtl"==a.lang.dir,this.icon,this.iconOffset),arrowHtml:this.hasArrow?b.output():""},c.output(h,d),this.onRender&&this.onRender(),k},setState:function(a){if(this._.state==a)return!1;this._.state=a;var b=CKEDITOR.document.getById(this._.id);return!!b&&(b.setState(a,"cke_button"),a==CKEDITOR.TRISTATE_DISABLED?b.setAttribute("aria-disabled",!0):b.removeAttribute("aria-disabled"),this.hasArrow?(a=a==CKEDITOR.TRISTATE_ON?this._.editor.lang.button.selectedLabel.replace(/%1/g,this.label):this.label,CKEDITOR.document.getById(this._.id+"_label").setText(a)):a==CKEDITOR.TRISTATE_ON?b.setAttribute("aria-pressed",!0):b.removeAttribute("aria-pressed"),!0)},getState:function(){return this._.state}
11,toFeature:function(a){if(this._.feature)return this._.feature;var b=this;return this.allowedContent||this.requiredContent||!this.command||(b=a.getCommand(this.command)||b),this._.feature=b}},CKEDITOR.ui.prototype.addButton=function(a,b){this.add(a,CKEDITOR.UI_BUTTON,b)}}(),CKEDITOR.plugins.add("panelbutton",{requires:"button",onLoad:function(){function a(a){var b=this._;b.state!=CKEDITOR.TRISTATE_DISABLED&&(this.createPanel(a),b.on?b.panel.hide():b.panel.showBlock(this._.id,this.document.getById(this._.id),4))}CKEDITOR.ui.panelButton=CKEDITOR.tools.createClass({base:CKEDITOR.ui.button,$:function(b){var c=b.panel||{};delete b.panel,this.base(b),this.document=c.parent&&c.parent.getDocument()||CKEDITOR.document,c.block={attributes:c.attributes},this.hasArrow=c.toolbarRelated=!0,this.click=a,this._={panelDefinition:c}},statics:{handler:{create:function(a){return new CKEDITOR.ui.panelButton(a)}}},proto:{createPanel:function(a){var b=this._;if(!b.panel){var c=this._.panelDefinition,d=this._.panelDefinition.block,e=c.parent||CKEDITOR.document.getBody(),f=this._.panel=new CKEDITOR.ui.floatPanel(a,e,c),c=f.addBlock(b.id,d),g=this;f.onShow=function(){g.className&&this.element.addClass(g.className+"_panel"),g.setState(CKEDITOR.TRISTATE_ON),b.on=1,g.editorFocus&&a.focus(),g.onOpen&&g.onOpen()},f.onHide=function(c){g.className&&this.element.getFirst().removeClass(g.className+"_panel"),g.setState(g.modes&&g.modes[a.mode]?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED),b.on=0,!c&&g.onClose&&g.onClose()},f.onEscape=function(){f.hide(1),g.document.getById(b.id).focus()},this.onBlock&&this.onBlock(f,c),c.onHide=function(){b.on=0,g.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>'),b=CKEDITOR.addTemplate("panel-frame",'<iframe id="{id}" class="cke_panel_frame" role="presentation" frameborder="0" src="{src}"></iframe>'),c=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(d,e){this.getHolderElement=function(){var a=this._.holder;if(!a){if(this.isFramed){var a=this.document.getById(this.id+"_frame"),b=a.getParent(),a=a.getFrameDocument();CKEDITOR.env.iOS&&b.setStyles({overflow:"scroll","-webkit-overflow-scrolling":"touch"}),b=CKEDITOR.tools.addFunction(CKEDITOR.tools.bind(function(){this.isLoaded=!0,this.onLoad&&this.onLoad()},this)),a.write(c.output(CKEDITOR.tools.extend({css:CKEDITOR.tools.buildStyleHtml(this.css),onload:"window.parent.CKEDITOR.tools.callFunction("+b+");"},f))),a.getWindow().$.CKEDITOR=CKEDITOR,a.on("keydown",function(a){var b=a.data.getKeystroke(),c=this.document.getById(this.id).getAttribute("dir");this._.onKeyDown&&!1===this._.onKeyDown(b)?a.data.preventDefault():(27==b||b==("rtl"==c?39:37))&&this.onEscape&&!1===this.onEscape(b)&&a.data.preventDefault()},this),a=a.getBody(),a.unselectable(),CKEDITOR.env.air&&CKEDITOR.tools.callFunction(b)}else a=this.document.getById(this.id);this._.holder=a}return a};var f={editorId:d.id,id:this.id,langCode:d.langCode,dir:d.lang.dir,cls:this.className,frame:"",env:CKEDITOR.env.cssClass,"z-index":d.config.baseFloatZIndex+1};if(this.isFramed){var g=CKEDITOR.env.air?"javascript:void(0)":CKEDITOR.env.ie?"javascript:void(function(){"+encodeURIComponent("document.open();("+CKEDITOR.tools.fixDomain+")();document.close();")+"}())":"";f.frame=b.output({id:this.id+"_frame",src:g})}return g=a.output(f),e&&e.push(g),g},addBlock:function(a,b){return b=this._.blocks[a]=b instanceof CKEDITOR.ui.panel.block?b:new CKEDITOR.ui.panel.block(this.getHolderElement(),b),this._.currentBlock||this.showBlock(a),b},getBlock:function(a){return this._.blocks[a]},showBlock:function(a){a=this._.blocks[a];var b=this._.currentBlock,c=!this.forceIFrame||CKEDITOR.env.ie?this._.holder:this.document.getById(this.id+"_frame");return b&&b.hide(),this._.currentBlock=a,CKEDITOR.fire("ariaWidget",c),a._.focusIndex=-1,this._.onKeyDown=a.onKeyDown&&CKEDITOR.tools.bind(a.onKeyDown,a),a.show(),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,
11class:"cke_panel_block"},styles:{display:"none"}})),b&&CKEDITOR.tools.extend(this,b),this.element.setAttributes({role:this.attributes.role||"presentation","aria-label":this.attributes["aria-label"],title:this.attributes.title||this.attributes["aria-label"]}),this.keys={},this._.focusIndex=-1,this.element.disableContextMenu()},_:{markItem:function(a){-1!=a&&(a=this.element.getElementsByTag("a").getItem(this._.focusIndex=a),CKEDITOR.env.webkit&&a.getDocument().getWindow().focus(),a.focus(),this.onMark&&this.onMark(a))}},proto:{show:function(){this.element.setStyle("display","")},hide:function(){this.onHide&&!0===this.onHide.call(this)||this.element.setStyle("display","none")},onKeyDown:function(a,b){var c=this.keys[a];switch(c){case"next":for(var e,d=this._.focusIndex,c=this.element.getElementsByTag("a");e=c.getItem(++d);)if(e.getAttribute("_cke_focus")&&e.$.offsetWidth){this._.focusIndex=d,e.focus();break}return!e&&!b&&(this._.focusIndex=-1,this.onKeyDown(a,1));case"prev":for(d=this._.focusIndex,c=this.element.getElementsByTag("a");0<d&&(e=c.getItem(--d));){if(e.getAttribute("_cke_focus")&&e.$.offsetWidth){this._.focusIndex=d,e.focus();break}e=null}return!e&&!b&&(this._.focusIndex=c.count(),this.onKeyDown(a,1));case"click":case"mouseup":return d=this._.focusIndex,(e=0<=d&&this.element.getElementsByTag("a").getItem(d))&&(e.$[c]?e.$[c]():e.$["on"+c]()),!1}return!0}}})}(),CKEDITOR.plugins.add("floatpanel",{requires:"panel"}),function(){function a(a,c,d,e,f){f=CKEDITOR.tools.genKey(c.getUniqueId(),d.getUniqueId(),a.lang.dir,a.uiColor||"",e.css||"",f||"");var g=b[f];return g||(g=b[f]=new CKEDITOR.ui.panel(c,e),g.element=d.append(CKEDITOR.dom.element.createFromHtml(g.render(a),c)),g.element.setStyles({display:"none",position:"absolute"})),g}var b={};CKEDITOR.ui.floatPanel=CKEDITOR.tools.createClass({$:function(b,c,d,e){function f(){j.hide()}d.forceIFrame=1,d.toolbarRelated&&b.elementMode==CKEDITOR.ELEMENT_MODE_INLINE&&(c=CKEDITOR.document.getById("cke_"+b.name));var g=c.getDocument();e=a(b,g,c,d,e||0);var h=e.element,i=h.getFirst(),j=this;h.disableContextMenu(),this.element=h,this._={editor:b,panel:e,parentElement:c,definition:d,document:g,iframe:i,children:[],dir:b.lang.dir,showBlockParams:null},b.on("mode",f),b.on("resize",f),g.getWindow().on("resize",function(){this.reposition()},this)},proto:{addBlock:function(a,b){return this._.panel.addBlock(a,b)},addListBlock:function(a,b){return this._.panel.addListBlock(a,b)},getBlock:function(a){return this._.panel.getBlock(a)},showBlock:function(a,b,c,d,e,f){var g=this._.panel,h=g.showBlock(a);this._.showBlockParams=[].slice.call(arguments),this.allowBlur(!1);var i=this._.editor.editable();this._.returnFocus=i.hasFocus?i:new CKEDITOR.dom.element(CKEDITOR.document.$.activeElement),this._.hideTimeout=0;var j=this.element,i=this._.iframe,i=CKEDITOR.env.ie&&!CKEDITOR.env.edge?i:new CKEDITOR.dom.window(i.$.contentWindow),k=j.getDocument(),l=this._.parentElement.getPositionedAncestor(),m=b.getDocumentPosition(k),k=l?l.getDocumentPosition(k):{x:0,y:0},n="rtl"==this._.dir,o=m.x+(d||0)-k.x,p=m.y+(e||0)-k.y;!n||1!=c&&4!=c?n||2!=c&&3!=c||(o+=b.$.offsetWidth-1):o+=b.$.offsetWidth,3!=c&&4!=c||(p+=b.$.offsetHeight-1),this._.panel._.offsetParentId=b.getId(),j.setStyles({top:p+"px",left:0,display:""}),j.setOpacity(0),j.getFirst().removeStyle("width"),this._.editor.focusManager.add(i),this._.blurSet||(CKEDITOR.event.useCapture=!0,i.on("blur",function(a){function b(){delete this._.returnFocus,this.hide()}this.allowBlur()&&a.data.getPhase()==CKEDITOR.EVENT_PHASE_AT_TARGET&&this.visible&&!this._.activeChild&&(CKEDITOR.env.iOS?this._.hideTimeout||(this._.hideTimeout=CKEDITOR.tools.setTimeout(b,0,this)):b.call(this))},this),i.on("focus",function(){this._.focused=!0,this.hideChild(),this.allowBlur(!0)},this),CKEDITOR.env.iOS&&(i.on("touchstart",function(){clearTimeout(this._.hideTimeout)},this),i.on("touchend",function(){this._.hideTimeout=0,this.focus()},this)),CKEDITOR.event.useCapture=!1,this._.blurSet=1),g.onEscape=CKEDITOR.tools.bind(function(a){if(this.onEscape&&!1===this.onEscape(a))return!1},this),CKEDITOR.tools.setTimeout(function(){var a=CKEDITOR.tools.bind(function(){var a=j;if(a.removeStyle("width"),h.autoSize){var b=h.element.getDocument(),b=(CKEDITOR.env.webkit||CKEDITOR.env.edge?h.element:b.getBody()).$.scrollWidth;CKEDITOR.env.ie&&CKEDITOR.env.quirks&&0<b&&(b+=(a.$.offsetWidth||0)-(a.$.clientWidth||0)+3),a.setStyle("width",b+10+"px"),b=h.element.$.scrollHeight,CKEDITOR.env.ie&&CKEDITOR.env.quirks&&0<b&&(b+=(a.$.offsetHeight||0)-(a.$.clientHeight||0)+3),a.setStyle("height",b+"px"),g._.currentBlock.element.setStyle("display","none").removeStyle("display")}else a.removeStyle("height");n&&(o-=j.$.offsetWidth),j.setStyle("left",o+"px");var b=g.element.getWindow(),a=j.$.getBoundingClientRect(),b=b.getViewPaneSize(),c=a.width||a.right-a.left,d=a.height||a.bottom-a.top,e=n?a.right:b.width-a.left,i=n?b.width-a.right:a.left;n?e<c&&(o=i>c?o+c:b.width>
11c?o-a.left:o-a.right+b.width):e<c&&(o=i>c?o-c:b.width>c?o-a.right+b.width:o-a.left),c=a.top,b.height-a.top<d&&(p=c>d?p-d:b.height>d?p-a.bottom+b.height:p-a.top),CKEDITOR.env.ie&&(b=a=new CKEDITOR.dom.element(j.$.offsetParent),"html"==b.getName()&&(b=b.getDocument().getBody()),"rtl"==b.getComputedStyle("direction")&&(o=CKEDITOR.env.ie8Compat?o-2*j.getDocument().getDocumentElement().$.scrollLeft:o-(a.$.scrollWidth-a.$.clientWidth)));var k,a=j.getFirst();(k=a.getCustomData("activePanel"))&&k.onHide&&k.onHide.call(this,1),a.setCustomData("activePanel",this),j.setStyles({top:p+"px",left:o+"px"}),j.setOpacity(1),f&&f()},this);g.isLoaded?a():g.onLoad=a,CKEDITOR.tools.setTimeout(function(){var a=CKEDITOR.env.webkit&&CKEDITOR.document.getWindow().getScrollPosition().y;this.focus(),h.element.focus(),CKEDITOR.env.webkit&&(CKEDITOR.document.getBody().$.scrollTop=a),this.allowBlur(!0),this._.editor.fire("panelShow",this)},0,this)},CKEDITOR.env.air?200:0,this),this.visible=1,this.onShow&&this.onShow.call(this)},reposition:function(){var a=this._.showBlockParams;this.visible&&this._.showBlockParams&&(this.hide(),this.showBlock.apply(this,a))},focus:function(){if(CKEDITOR.env.webkit){var a=CKEDITOR.document.getActive();a&&!a.equals(this._.iframe)&&a.$.blur()}(this._.lastFocused||this._.iframe.getFrameDocument().getWindow()).focus()},blur:function(){var a=this._.iframe.getFrameDocument().getActive();a&&a.is("a")&&(this._.lastFocused=a)},hide:function(a){!this.visible||this.onHide&&!0===this.onHide.call(this)||(this.hideChild(),CKEDITOR.env.gecko&&this._.iframe.getFrameDocument().$.activeElement.blur(),this.element.setStyle("display","none"),this.visible=0,this.element.getFirst().removeCustomData("activePanel"),(a=a&&this._.returnFocus)&&(CKEDITOR.env.webkit&&a.type&&a.getWindow().$.focus(),a.focus()),delete this._.lastFocused,this._.showBlockParams=null,this._.editor.fire("panelHide",this))},allowBlur:function(a){var b=this._.panel;return void 0!==a&&(b.allowBlur=a),b.allowBlur},showAsChild:function(a,b,c,d,e,f){this._.activeChild==a&&a._.panel._.offsetParentId==c.getId()||(this.hideChild(),a.onHide=CKEDITOR.tools.bind(function(){CKEDITOR.tools.setTimeout(function(){this._.focused||this.hide()},0,this)},this),this._.activeChild=a,this._.focused=!1,a.showBlock(b,c,d,e,f),this.blur(),(CKEDITOR.env.ie7Compat||CKEDITOR.env.ie6Compat)&&setTimeout(function(){a.element.getChild(0).$.style.cssText+=""},100))},hideChild:function(a){var b=this._.activeChild;b&&(delete b.onHide,delete this._.activeChild,b.hide(),a&&this.focus())}}}),CKEDITOR.on("instanceDestroyed",function(){var c,a=CKEDITOR.tools.isEmpty(CKEDITOR.instances);for(c in b){var d=b[c];a?d.destroy():d.element.hide()}a&&(b={})})}(),CKEDITOR.plugins.add("colorbutton",{requires:"panelbutton,floatpanel",init:function(a){function b(b,d,g,h){var i=new CKEDITOR.style(e["colorButton_"+d+"Style"]),j=CKEDITOR.tools.getNextId()+"_colorBox";a.ui.add(b,CKEDITOR.UI_PANELBUTTON,{label:g,title:g,modes:{wysiwyg:1},editorFocus:0,toolbar:"colors,"+h,allowedContent:i,requiredContent:i,panel:{css:CKEDITOR.skin.getPath("editor"),attributes:{role:"listbox","aria-label":f.panelTitle}},onBlock:function(b,e){e.autoSize=!0,e.element.addClass("cke_colorblock"),e.element.setHtml(c(b,d,j)),e.element.getDocument().getBody().setStyle("overflow","hidden"),CKEDITOR.ui.fire("ready",this);var f=e.keys,g="rtl"==a.lang.dir;f[g?37:39]="next",f[40]="next",f[9]="next",f[g?39:37]="prev",f[38]="prev",f[CKEDITOR.SH
11IFT+9]="prev",f[32]="click"},refresh:function(){a.activeFilter.check(i)||this.setState(CKEDITOR.TRISTATE_DISABLED)},onOpen:function(){var c,b=a.getSelection(),b=b&&b.getStartElement(),b=a.elementPath(b);if(b){b=b.block||b.blockLimit||a.document.getBody();do c=b&&b.getComputedStyle("back"==d?"background-color":"color")||"transparent";while("back"==d&&"transparent"==c&&b&&(b=b.getParent()));return c&&"transparent"!=c||(c="#ffffff"),!1!==e.colorButton_enableAutomatic&&this._.panel._.iframe.getFrameDocument().getById(j).setStyle("background-color",c),c}}})}function c(b,c,g){var h=[],i=e.colorButton_colors.split(","),j=a.plugins.colordialog&&!1!==e.colorButton_enableMore,k=i.length+(j?2:1),l=CKEDITOR.tools.addFunction(function(c,f){function g(a){this.removeListener("ok",g),this.removeListener("cancel",g),"ok"==a.name&&h(this.getContentElement("picker","selectedColor").getValue(),f)}var h=arguments.callee;if("?"==c)a.openDialog("colordialog",function(){this.on("ok",g),this.on("cancel",g)});else{if(a.focus(),b.hide(),a.fire("saveSnapshot"),a.removeStyle(new CKEDITOR.style(e["colorButton_"+f+"Style"],{color:"inherit"})),c){var i=e["colorButton_"+f+"Style"];i.childRule="back"==f?function(a){return d(a)}:function(a){return!(a.is("a")||a.getElementsByTag("a").count())||d(a)},a.applyStyle(new CKEDITOR.style(i,{color:c}))}a.fire("saveSnapshot")}});for(!1!==e.colorButton_enableAutomatic&&h.push('<a class="cke_colorauto" _cke_focus=1 hidefocus=true title="',f.auto,'" onclick="CKEDITOR.tools.callFunction(',l,",null,'",c,"');return false;\" href=\"javascript:void('",f.auto,'\')" role="option" aria-posinset="1" aria-setsize="',k,'"><table role="presentation" cellspacing=0 cellpadding=0 width="100%"><tr><td><span class="cke_colorbox" id="',g,'"></span></td><td colspan=7 align=center>',f.auto,"</td></tr></table></a>"),h.push('<table role="presentation" cellspacing=0 cellpadding=0 width="100%">'),g=0;g<i.length;g++){0===g%8&&h.push("</tr><tr>");var m=i[g].split("/"),n=m[0],o=m[1]||n;m[1]||(n="#"+n.replace(/^(.)(.)(.)$/,"$1$1$2$2$3$3")),m=a.lang.colorbutton.colors[o]||o,h.push('<td><a class="cke_colorbox" _cke_focus=1 hidefocus=true title="',m,'" onclick="CKEDITOR.tools.callFunction(',l,",'",n,"','",c,"'); return false;\" href=\"javascript:void('",m,'\')" role="option" aria-posinset="',g+2,'" aria-setsize="',k,'"><span class="cke_colorbox" style="background-color:#',o,'"></span></a></td>')}return j&&h.push('</tr><tr><td colspan=8 align=center><a class="cke_colormore" _cke_focus=1 hidefocus=true title="',f.more,'" onclick="CKEDITOR.tools.callFunction(',l,",'?','",c,"');return false;\" href=\"javascript:void('",f.more,"')\"",' role="option" aria-posinset="',k,'" aria-setsize="',k,'">',f.more,"</a></td>"),h.push("</tr></table>"),h.join("")}function d(a){return"false"==a.getAttribute("contentEditable")||a.getAttribute("data-nostyle")}var e=a.config,f=a.lang.colorbutton;CKEDITOR.env.hc||(b("TextColor","fore",f.textColorTitle,10),b("BGColor","back",f.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)"}},CKEDITOR.plugins.colordialog={requires:"dialog",init:function(a){var b=new CKEDITOR.dialogCommand("colordialog");b.editorFocus=!1,a.addCommand("colordialog",b),CKEDITOR.dialog.add("colordialog",this.path+"dialogs/colordialog.js"),a.getColorFromDialog=function(b,c){var d=function(a){this.removeListener("ok",d),this.removeListener("cancel",d),a="ok"==a.name?this.getValueOf("picker","selectedColor"):null,b.call(c,a)},e=function(a){a.on("ok",d),a.on("cancel",d)};a.execCommand("colordialog"),a._.storedDialogs&&a._.storedDialogs.colordialog?e(a._.storedDialogs.colordialog):CKEDITOR.on("dialogDefinition",function(a){if
11("colordialog"==a.data.name){var b=a.data.definition;a.removeListener(),b.onLoad=CKEDITOR.tools.override(b.onLoad,function(a){return function(){e(this),b.onLoad=a,"function"==typeof a&&a.call(this)}})}})}}},CKEDITOR.plugins.add("colordialog",CKEDITOR.plugins.colordialog),function(){CKEDITOR.plugins.add("templates",{requires:"dialog",init:function(a){CKEDITOR.dialog.add("templates",CKEDITOR.getUrl(this.path+"dialogs/templates.js")),a.addCommand("templates",new CKEDITOR.dialogCommand("templates")),a.ui.addButton&&a.ui.addButton("Templates",{label:a.lang.templates.button,command:"templates",toolbar:"doctools,10"})}});var a={},b={};CKEDITOR.addTemplates=function(b,c){a[b]=c},CKEDITOR.getTemplates=function(b){return a[b]},CKEDITOR.loadTemplates=function(a,c){for(var d=[],e=0,f=a.length;e<f;e++)b[a[e]]||(d.push(a[e]),b[a[e]]=1);d.length?CKEDITOR.scriptLoader.load(d,c):setTimeout(c,0)}}(),CKEDITOR.config.templates_files=[CKEDITOR.getUrl("plugins/templates/templates/default.js")],CKEDITOR.config.templates_replaceContent=!0,CKEDITOR.plugins.add("menu",{requires:"floatpanel",beforeInit:function(a){for(var b=a.config.menu_groups.split(","),c=a._.menuGroups={},d=a._.menuItems={},e=0;e<b.length;e++)c[b[e]]=e+1;a.addMenuGroup=function(a,b){c[a]=b||100},a.addMenuItem=function(a,b){c[b.group]&&(d[a]=new CKEDITOR.menuItem(this,a,b))},a.addMenuItems=function(a){for(var b in a)this.addMenuItem(b,a[b])},a.getMenuItem=function(a){return d[a]},a.removeMenuItem=function(a){delete d[a]}}}),function(){function a(a){a.sort(function(a,b){return a.group<b.group?-1:a.group>b.group?1:a.order<b.order?-1:a.order>b.order?1:0})}var b='<span class="cke_menuitem"><a id="{id}" class="cke_menubutton cke_menubutton__{name} cke_menubutton_{state} {cls}" href="{href}" title="{title}" tabindex="-1"_cke_focus=1 hidefocus="true" role="{role}" aria-haspopup="{hasPopup}" aria-disabled="{disabled}" {ariaChecked}';CKEDITOR.env.gecko&&CKEDITOR.env.mac&&(b+=' onkeypress="return false;"'),CKEDITOR.env.gecko&&(b+=' onblur="this.style.cssText = this.style.cssText;"');var b=b+(' onmouseover="CKEDITOR.tools.callFunction({hoverFn},{index});" onmouseout="CKEDITOR.tools.callFunction({moveOutFn},{index});" '+(CKEDITOR.env.ie?'onclick="return false;" onmouseup':"onclick")+'="CKEDITOR.tools.callFunction({clickFn},{index}); return false;">'),c=CKEDITOR.addTemplate("menuItem",b+'<span class="cke_menubutton_inner"><span class="cke_menubutton_icon"><span class="cke_button_icon cke_button__{iconName}_icon" style="{iconStyle}"></span></span><span class="cke_menubutton_label">{label}</span>{arrowHtml}</span></a></span>'),d=CKEDITOR.addTemplate("menuArrow",'<span class="cke_menuarrow"><span>{label}</span></span>');CKEDITOR.menu=CKEDITOR.tools.createClass({$:function(a,b){b=this._.definition=b||{},this.id=CKEDITOR.tools.getNextId(),this.editor=a,this.items=[],this._.listeners=[],this._.level=b.level||1;var c=CKEDITOR.tools.extend({},b.panel,{css:[CKEDITOR.skin.getPath("editor")],level:this._.level-1,block:{}}),d=c.block.attributes=c.attributes||{};!d.role&&(d.role="menu"),this._.panelDefinition=c},_:{onShow:function(){var a=this.editor.getSelection(),b=a&&a.getStartElement(),c=this.editor.elementPath(),d=this._.listeners;this.removeAll();for(var e=0;e<d.length;e++){var f=d[e](b,a,c);if(f)for(var g in f){var h=this.editor.getMenuItem(g);!h||h.command&&!this.editor.getCommand(h.command).state||(h.state=f[g],this.add(h))}}},onClick:function(a){this.hide(),a.onClick?a.onClick():a.command&&this.editor.execCommand(a.command)},onEscape:function(a){var b=this.parent;return b?b._.panel.hideChild(1):27==a&&this.hide(1),!1},onHide:function(){this.onHide&&this.onHide()},showSubMenu:function(a){var b=this._.subMenu,c=this.items[a];if(c=c.getItems&&c.getItems()){b?b.removeAll():(b=this._.subMenu=new CKEDITOR.menu(this.editor,CKEDITOR.tools.extend({},this._.definition,{level:this._.level+1},!0)),b.parent=this,b._.onClick=CKEDITOR.tools.bind(this._.onClick,this));for(var d in c){var e=this.editor.getMenuItem(d);e&&(e.state=c[d],b.add(e))}var f=this._.panel.getBlock(this.id).element.getDocument().getById(this.id+String(a));setTimeout(function(){b.show(f,2)},0)}else this._.panel.hideChild(1)}},proto:{add:function(a){a.order||(a.order=this.items.length),this.items.push(a)},removeAll:function(){this.items=[]},show:function(b,c,d,e){if(this.parent||(this._.onShow(),this.items.length)){c=c||("rtl"==this.editor.lang.dir?2:1);var f=this.items,g=this.editor,h=this._.panel,i=this._.element;if(!h){h=this._.panel=new CKEDITOR.ui.floatPanel(this.editor,CKEDITOR.document.getBody(),this._.panelDefinition,this._.level),h.onEscape=CKEDITOR.tools.bind(function(a){if
11(!1===this._.onEscape(a))return!1},this),h.onShow=function(){h._.panel.getHolderElement().getParent().addClass("cke").addClass("cke_reset_all")},h.onHide=CKEDITOR.tools.bind(function(){this._.onHide&&this._.onHide()},this),i=h.addBlock(this.id,this._.panelDefinition.block),i.autoSize=!0;var j=i.keys;j[40]="next",j[9]="next",j[38]="prev",j[CKEDITOR.SHIFT+9]="prev",j["rtl"==g.lang.dir?37:39]=CKEDITOR.env.ie?"mouseup":"click",j[32]=CKEDITOR.env.ie?"mouseup":"click",CKEDITOR.env.ie&&(j[13]="mouseup"),i=this._.element=i.element,j=i.getDocument(),j.getBody().setStyle("overflow","hidden"),j.getElementsByTag("html").getItem(0).setStyle("overflow","hidden"), 12this._.itemOverFn=CKEDITOR.tools.addFunction(function(a){clearTimeout(this._.showSubTimeout),this._.showSubTimeout=CKEDITOR.tools.setTimeout(this._.showSubMenu,g.config.menu_subMenuDelay||400,this,[a])},this),this._.itemOutFn=CKEDITOR.tools.addFunction(function(){clearTimeout(this._.showSubTimeout)},this),this._.itemClickFn=CKEDITOR.tools.addFunction(function(a){var b=this.items[a];b.state==CKEDITOR.TRISTATE_DISABLED?this.hide(1):b.getItems?this._.showSubMenu(a):this._.onClick(b)},this)}a(f);for(var j=g.elementPath(),j=['<div class="cke_menu'+(j&&j.direction()!=g.lang.dir?" cke_mixed_dir_content":"")+'" role="presentation">'],k=f.length,l=k&&f[0].group,m=0;m<k;m++){var n=f[m];l!=n.group&&(j.push('<div class="cke_menuseparator" role="separator"></div>'),l=n.group),n.render(this,m,j)}j.push("</div>"),i.setHtml(j.join("")),CKEDITOR.ui.fire("ready",this),this.parent?this.parent._.panel.showAsChild(h,this.id,b,c,d,e):h.showBlock(this.id,b,c,d,e),g.fire("menuShow",[h])}},addListener:function(a){this._.listeners.push(a)},hide:function(a){this._.onHide&&this._.onHide(),this._.panel&&this._.panel.hide(a)}}}),CKEDITOR.menuItem=CKEDITOR.tools.createClass({$:function(a,b,c){CKEDITOR.tools.extend(this,c,{order:0,className:"cke_menubutton__"+b}),this.group=a._.menuGroups[this.group],this.editor=a,this.name=b},proto:{render:function(a,b,e){var f=a.id+String(b),g="undefined"==typeof this.state?CKEDITOR.TRISTATE_OFF:this.state,h="",i=g==CKEDITOR.TRISTATE_ON?"on":g==CKEDITOR.TRISTATE_DISABLED?"disabled":"off";this.role in{menuitemcheckbox:1,menuitemradio:1}&&(h=' aria-checked="'+(g==CKEDITOR.TRISTATE_ON?"true":"false")+'"');var j=this.getItems,k="&#"+("rtl"==this.editor.lang.dir?"9668":"9658")+";",l=this.name;this.icon&&!/\./.test(this.icon)&&(l=this.icon),a={id:f,name:this.name,iconName:l,label:this.label,cls:this.className||"",state:i,hasPopup:j?"true":"false",disabled:g==CKEDITOR.TRISTATE_DISABLED,title:this.label,href:"javascript:void('"+(this.label||"").replace("'")+"')",hoverFn:a._.itemOverFn,moveOutFn:a._.itemOutFn,clickFn:a._.itemClickFn,index:b,iconStyle:CKEDITOR.skin.getIconStyle(l,"rtl"==this.editor.lang.dir,l==this.icon?null:this.icon,this.iconOffset),arrowHtml:j?d.output({label:k}):"",role:this.role?this.role:"menuitem",ariaChecked:h},c.output(a,e)}}})}(),CKEDITOR.config.menu_groups="clipboard,form,tablecell,tablecellproperties,tablerow,tablecolumn,table,anchor,link,image,flash,checkbox,radio,textfield,hiddenfield,imagebutton,button,select,textarea,div",CKEDITOR.plugins.add("contextmenu",{requires:"menu",onLoad:function(){CKEDITOR.plugins.contextMenu=CKEDITOR.tools.createClass({base:CKEDITOR.menu,$:function(a){this.base.call(this,a,{panel:{className:"cke_menu_panel",attributes:{"aria-label":a.lang.contextmenu.options}}})},proto:{addTarget:function(a,b){if(a.on("contextmenu",function(a){a=a.data;var d=CKEDITOR.env.webkit?c:CKEDITOR.env.mac?a.$.metaKey:a.$.ctrlKey;if(!b||!d){if(a.preventDefault(),CKEDITOR.env.mac&&CKEDITOR.env.webkit){var d=this.editor,e=new CKEDITOR.dom.elementPath(a.getTarget(),d.editable()).contains(function(a){return a.hasAttribute("contenteditable")},!0);e&&"false"==e.getAttribute("contenteditable")&&d.getSelection().fake(e)}var e=a.getTarget().getDocument(),f=a.getTarget().getDocument().getDocumentElement(),d=!e.equals(CKEDITOR.document),e=e.getWindow().getScrollPosition(),g=d?a.$.clientX:a.$.pageX||e.x+a.$.clientX,h=d?a.$.clientY:a.$.pageY||e.y+a.$.clientY;CKEDITOR.tools.setTimeout(function(){this.open(f,null,g,h)},CKEDITOR.env.ie?200:0,this)}},this),CKEDITOR.env.webkit){var c,d=function(){c=0};a.on("keydown",function(a){c=CKEDITOR.env.mac?a.data.$.metaKey:a.data.$.ctrlKey}),a.on("keyup",d),a.on("contextmenu",d)}},open:function(a,b,c,d){this.editor.focus(),a=a||CKEDITOR.document.getDocumentElement(),this.editor.selectionChange(1),this.show(a,b,c,d)}}})},beforeInit:function(a){var b=a.contextMenu=new CKEDITOR.plugins.contextMenu(a);a.on("contentDom",function(){b.addTarget(a.editable(),!1!==a.config.browserContextMenuOnCtrl)}),a.addCommand("contextMenu",{exec:function(){a.contextMenu.open(a.document.getBody())}}
12),a.setKeystroke(CKEDITOR.SHIFT+121,"contextMenu"),a.setKeystroke(CKEDITOR.CTRL+CKEDITOR.SHIFT+121,"contextMenu")}}),function(){CKEDITOR.plugins.add("div",{requires:"dialog",init:function(a){if(!a.blockless){var b=a.lang.div,c="div(*)";CKEDITOR.dialog.isTabEnabled(a,"editdiv","advanced")&&(c+=";div[dir,id,lang,title]{*}"),a.addCommand("creatediv",new CKEDITOR.dialogCommand("creatediv",{allowedContent:c,requiredContent:"div",contextSensitive:!0,refresh:function(a,b){this.setState("div"in(a.config.div_wrapTable?b.root:b.blockLimit).getDtd()?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED)}})),a.addCommand("editdiv",new CKEDITOR.dialogCommand("editdiv",{requiredContent:"div"})),a.addCommand("removediv",{requiredContent:"div",exec:function(a){function b(b){(b=CKEDITOR.plugins.div.getSurroundDiv(a,b))&&!b.data("cke-div-added")&&(g.push(b),b.data("cke-div-added"))}for(var e,c=a.getSelection(),d=c&&c.getRanges(),f=c.createBookmarks(),g=[],h=0;h<d.length;h++)e=d[h],e.collapsed?b(c.getStartElement()):(e=new CKEDITOR.dom.walker(e),e.evaluator=b,e.lastForward());for(h=0;h<g.length;h++)g[h].remove(!0);c.selectBookmarks(f)}}),a.ui.addButton&&a.ui.addButton("CreateDiv",{label:b.toolbar,command:"creatediv",toolbar:"blocks,50"}),a.addMenuItems&&(a.addMenuItems({editdiv:{label:b.edit,command:"editdiv",group:"div",order:1},removediv:{label:b.remove,command:"removediv",group:"div",order:5}}),a.contextMenu&&a.contextMenu.addListener(function(b){return!b||b.isReadOnly()?null:CKEDITOR.plugins.div.getSurroundDiv(a)?{editdiv:CKEDITOR.TRISTATE_OFF,removediv:CKEDITOR.TRISTATE_OFF}:null})),CKEDITOR.dialog.add("creatediv",this.path+"dialogs/div.js"),CKEDITOR.dialog.add("editdiv",this.path+"dialogs/div.js")}}}),CKEDITOR.plugins.div={getSurroundDiv:function(a,b){var c=a.elementPath(b);return a.elementPath(c.blockLimit).contains(function(a){return a.is("div")&&!a.isReadOnly()},1)}}}(),CKEDITOR.plugins.add("resize",{init:function(a){function b(b){var c=i.width,e=i.height,g=c+(b.data.$.screenX-h.x)*("rtl"==f?-1:1);b=e+(b.data.$.screenY-h.y),j&&(c=Math.max(d.resize_minWidth,Math.min(g,d.resize_maxWidth))),k&&(e=Math.max(d.resize_minHeight,Math.min(b,d.resize_maxHeight))),a.resize(j?c:null,e)}function c(){CKEDITOR.document.removeListener("mousemove",b),CKEDITOR.document.removeListener("mouseup",c),a.document&&(a.document.removeListener("mousemove",b),a.document.removeListener("mouseup",c))}var d=a.config,e=a.ui.spaceId("resizer"),f=a.element?a.element.getDirection(1):"ltr";if(!d.resize_dir&&(d.resize_dir="vertical"),void 0===d.resize_maxWidth&&(d.resize_maxWidth=3e3),void 0===d.resize_maxHeight&&(d.resize_maxHeight=3e3),void 0===d.resize_minWidth&&(d.resize_minWidth=750),void 0===d.resize_minHeight&&(d.resize_minHeight=250),!1!==d.resize_enabled){var h,i,g=null,j=("both"==d.resize_dir||"horizontal"==d.resize_dir)&&d.resize_minWidth!=d.resize_maxWidth,k=("both"==d.resize_dir||"vertical"==d.resize_dir)&&d.resize_minHeight!=d.resize_maxHeight,l=CKEDITOR.tools.addFunction(function(e){g||(g=a.getResizable()),i={width:g.$.offsetWidth||0,height:g.$.offsetHeight||0},h={x:e.screenX,y:e.screenY},d.resize_minWidth>i.width&&(d.resize_minWidth=i.width),d.resize_minHeight>i.height&&(d.resize_minHeight=i.height),CKEDITOR.document.on("mousemove",b),CKEDITOR.document.on("mouseup",c),a.document&&(a.document.on("mousemove",b),a.document.on("mouseup",c)),e.preventDefault&&e.preventDefault()});a.on("destroy",function(){CKEDITOR.tools.removeFunction(l)}),a.on("uiSpace",function(b){if("bottom"==b.data.space){var c="";j&&!k&&(c=" cke_resizer_horizontal"),!j&&k&&(c=" cke_resizer_vertical");var d='<span id="'+e+'" class="cke_resizer'+c+" cke_resizer_"+f+'" title="'+CKEDITOR.tools.htmlEncode(a.lang.common.resize)+'" onmousedown="CKEDITOR.tools.callFunction('+l+', event)">'+("ltr"==f?"â¢":"â£")+"</span>";"ltr"==f&&"ltr"==c?b.data.html+=d:b.data.html=d+b.data.html}},a,null,100),a.on("maximize",function(b){a.ui.space("resizer")[b.data==CKEDITOR.TRISTATE_ON?"hide":"show"]()})}}});!function(){function a(a){function c(){for(var c=d(),f=CKEDITOR.tools.clone(a.config.toolbarGroups)||b(a),g=0;g<f.length;g++){var h=f[g];
12if("/"!=h){"string"==typeof h&&(h=f[g]={name:h});var i,j=h.groups;if(j)for(var k=0;k<j.length;k++)i=j[k],(i=c[i])&&e(h,i);(i=c[h.name])&&e(h,i)}}return f}function d(){var c,d,e,b={};for(c in a.ui.items)d=a.ui.items[c],e=d.toolbar||"others",e=e.split(","),d=e[0],e=parseInt(e[1]||-1,10),b[d]||(b[d]=[]),b[d].push({name:c,order:e});for(d in b)b[d]=b[d].sort(function(a,b){return a.order==b.order?0:0>b.order?-1:0>a.order?1:a.order<b.order?-1:1});return b}function e(b,c){if(c.length){b.items?b.items.push(a.ui.create("-")):b.items=[];for(var d;d=c.shift();)d="string"==typeof d?d:d.name,g&&-1!=CKEDITOR.tools.indexOf(g,d)||(d=a.ui.create(d))&&a.addFeature(d)&&b.items.push(d)}}function f(a){var c,d,f,b=[];for(c=0;c<a.length;++c)d=a[c],f={},"/"==d?b.push(d):CKEDITOR.tools.isArray(d)?(e(f,CKEDITOR.tools.clone(d)),b.push(f)):d.items&&(e(f,CKEDITOR.tools.clone(d.items)),f.name=d.name,b.push(f));return b}var g=a.config.removeButtons,g=g&&g.split(","),h=a.config.toolbar;return"string"==typeof h&&(h=a.config["toolbar_"+h]),a.toolbar=h?f(h):c()}function b(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 c=function(){this.toolbars=[],this.focusCommandExecuted=!1};c.prototype.focus=function(){for(var b,a=0;b=this.toolbars[a++];)for(var d,c=0;d=b.items[c++];)if(d.focus)return void d.focus()};var d={modes:{wysiwyg:1,source:1},readOnly:1,exec:function(a){a.toolbox&&(a.toolbox.focusCommandExecuted=!0,CKEDITOR.env.ie||CKEDITOR.env.air?setTimeout(function(){a.toolbox.focus()},100):a.toolbox.focus())}};CKEDITOR.plugins.add("toolbar",{requires:"button",init:function(b){var e,f=function(a,c){var d,g="rtl"==b.lang.dir,h=b.config.toolbarGroupCycling,i=g?37:39,g=g?39:37,h=void 0===h||h;switch(c){case 9:case CKEDITOR.SHIFT+9:for(;!d||!d.items.length;)if(d=9==c?(d?d.next:a.toolbar.next)||b.toolbox.toolbars[0]:(d?d.previous:a.toolbar.previous)||b.toolbox.toolbars[b.toolbox.toolbars.length-1],d.items.length)for(a=d.items[e?d.items.length-1:0];a&&!a.focus;)(a=e?a.previous:a.next)||(d=0);return a&&a.focus(),!1;case i:d=a;do d=d.next,!d&&h&&(d=a.toolbar.items[0]);while(d&&!d.focus);return d?d.focus():f(a,9),!1;case 40:return a.button&&a.button.hasArrow?(b.once("panelShow",function(a){a.data._.panel._.currentBlock.onKeyDown(40)}),a.execute()):f(a,40==c?i:g),!1;case g:case 38:d=a;do d=d.previous,!d&&h&&(d=a.toolbar.items[a.toolbar.items.length-1]);while(d&&!d.focus);return d?d.focus():(e=1,f(a,CKEDITOR.SHIFT+9),e=0),!1;case 27:return b.focus(),!1;case 13:case 32:return a.execute(),!1}return!0};b.on("uiSpace",function(d){if(d.data.space==b.config.toolbarLocation){d.removeListener(),b.toolbox=new c;var h,i,e=CKEDITOR.tools.getNextId(),g=['<span id="',e,'" class="cke_voice_label">',b.lang.toolbar.toolbars,"</span>",'<span id="'+b.ui.spaceId("toolbox")+'" class="cke_toolbox" role="group" aria-labelledby="',e,'" onmousedown="return false;">'],e=!1!==b.config.toolbarStartupExpanded;b.config.toolbarCanCollapse&&b.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE&&g.push('<span class="cke_toolbox_main"'+(e?">":' style="display:none">'));for(var j=b.toolbox.toolbars,k=a(b),l=0;l<k.length;l++){var m,o,q,n=0,p=k[l];if(p)if(h&&(g.push("</span>"),i=h=0),"/"===p)g.push('<span class="cke_toolbar_break"></span>');else{q=p.items||p;for(var r=0;r<q.length;r++){var t,s=q[r];if(s){var u=function(a){a=a.render(b,g),v=n.items.push(a)-1,0<v&&(a.previous=n.items[v-1],a.previous.next=a),a.toolbar=n,a.onkey=f,a.onfocus=function(){b.toolbox.focusCommandExecuted||b.focus()}};if(s.type==CKEDITOR.UI_SEPARATOR)i=h&&s;else{if(t=!1!==s.canGroup,!n){m=CKEDITOR.tools.getNextId(),n={id:m,items:[]},o=p.name&&(b.lang.toolbar.toolbarGroups[p.name]||p.name),g.push('<span id="',m,'" class="cke_toolbar"',o?' aria-labelledby="'+m+'_label"':"",' role="toolbar">'),o&&g.push('<span id="',m,'_label" class="cke_voice_label">
12',o,"</span>"),g.push('<span class="cke_toolbar_start"></span>');var v=j.push(n)-1;0<v&&(n.previous=j[v-1],n.previous.next=n)}t?h||(g.push('<span class="cke_toolgroup" role="presentation">'),h=1):h&&(g.push("</span>"),h=0),i&&(u(i),i=0),u(s)}}}h&&(g.push("</span>"),i=h=0),n&&g.push('<span class="cke_toolbar_end"></span></span>')}}if(b.config.toolbarCanCollapse&&g.push("</span>"),b.config.toolbarCanCollapse&&b.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE){var w=CKEDITOR.tools.addFunction(function(){b.execCommand("toolbarCollapse")});b.on("destroy",function(){CKEDITOR.tools.removeFunction(w)}),b.addCommand("toolbarCollapse",{readOnly:1,exec:function(a){var b=a.ui.space("toolbar_collapser"),c=b.getPrevious(),d=a.ui.space("contents"),e=c.getParent(),f=parseInt(d.$.style.height,10),g=e.$.offsetHeight,h=b.hasClass("cke_toolbox_collapser_min");h?(c.show(),b.removeClass("cke_toolbox_collapser_min"),b.setAttribute("title",a.lang.toolbar.toolbarCollapse)):(c.hide(),b.addClass("cke_toolbox_collapser_min"),b.setAttribute("title",a.lang.toolbar.toolbarExpand)),b.getFirst().setText(h?"â²":"â"),d.setStyle("height",f-(e.$.offsetHeight-g)+"px"),a.fire("resize",{outerHeight:a.container.$.offsetHeight,contentsHeight:d.$.offsetHeight,outerWidth:a.container.$.offsetWidth})},modes:{wysiwyg:1,source:1}}),b.setKeystroke(CKEDITOR.ALT+(CKEDITOR.env.ie||CKEDITOR.env.webkit?189:109),"toolbarCollapse"),g.push('<a title="'+(e?b.lang.toolbar.toolbarCollapse:b.lang.toolbar.toolbarExpand)+'" id="'+b.ui.spaceId("toolbar_collapser")+'" tabIndex="-1" class="cke_toolbox_collapser'),e||g.push(" cke_toolbox_collapser_min"),g.push('" onclick="CKEDITOR.tools.callFunction('+w+')">','<span class="cke_arrow">▲</span>',"</a>")}g.push("</span>"),d.data.html+=g.join("")}}),b.on("destroy",function(){if(this.toolbox){var a,c,d,e,b=0;for(a=this.toolbox.toolbars;b<a.length;b++)for(d=a[b].items,c=0;c<d.length;c++)e=d[c],e.clickFn&&CKEDITOR.tools.removeFunction(e.clickFn),e.keyDownFn&&CKEDITOR.tools.removeFunction(e.keyDownFn)}}),b.on("uiReady",function(){var a=b.ui.space("toolbox");a&&b.focusManager.add(a,1)}),b.addCommand("toolbarFocus",d),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){return b.push('<span class="cke_toolbar_separator" role="separator"></span>'),{}}}}})}}),CKEDITOR.ui.prototype.addToolbarGroup=function(a,c,d){var e=b(this.editor),f=0===c,g={name:a};if(d){if(d=CKEDITOR.tools.search(e,function(a){return a.name==d}))return!d.groups&&(d.groups=[]),c&&(c=CKEDITOR.tools.indexOf(d.groups,c),0<=c)?void d.groups.splice(c+1,0,a):void(f?d.groups.splice(0,0,a):d.groups.push(a));c=null}c&&(c=CKEDITOR.tools.indexOf(e,function(a){return a.name==c})),f?e.splice(0,0,a):"number"==typeof c?e.splice(c+1,0,g):e.push(a)}}();CKEDITOR.UI_SEPARATOR="separator",CKEDITOR.config.toolbarLocation="top",function(){function a(a,c){function e(b){if(b=i.list[b],b.equals(a.editable())||"true"==b.getAttribute("contenteditable")){var c=a.createRange();c.selectNodeContents(b),c.select()}else a.getSelection().selectElement(b);a.focus()}function f(){h&&h.setHtml('<span class="cke_path_empty"> </span>'),delete i.list}var h,g=a.ui.spaceId("path"),i=a._.elementsPath,j=i.idBase;c.html+='<span id="'+g+'_label" class="cke_voice_label">'+a.lang.elementspath.eleLabel+'</span><span id="'+g+'" class="cke_path" role="group" aria-labelledby="'+g+'_label"><span class="cke_path_empty"> </span></span>',a.on("uiReady",function(){var b=a.ui.space("path");b&&a.focusManager.add(b,1)}),i.onClick=e;var k=CKEDITOR.tools.addFunction(e),l=CKEDITOR.tools.addFunction(function(b,c){var f,d=i.idBase;switch(c=new CKEDITOR.dom.event(c),f="rtl"==a.lang.dir,c.getKeystroke()){case f?39:37:case 9:return(f=CKEDITOR.document.getById(d+(b+1)))||(f=CKEDITOR.document.getById(d+"0")),f.focus(),!1;case f?37:39:case CKEDITOR.SHIFT+9:return(f=CKEDITOR.document.getById(d+(b-1)))||(f=CKEDITOR.document.getById(d+(i.list.length-1))),f.focus(),!1;case 27:return a.focus(),!1;case 13:case 32:return e(b),!1}return!0});a.on("selectionChange",function(){for(var o,b=[],c=i.list=[],e=[],f=i.filters,m=!0,n=a.elementPath().elements,p=n.length;p--;){var q=n[p],r=0;o=q.data("cke-display-name")?q.data("cke-display-name"):q.data("cke-real-element-type")?q.data("cke-real-element-type"):q.getName(),(m=q.hasAttribute("contenteditable")?"true"==q.getAttribute("contenteditable"):m)||q.hasAttribute("contenteditable")||(r=1);for(var s=0;s<f.length;s++){var t=f[s](q,o);if(!1===t){r=1;break}o=t||o}r||(c.unshift(q),e.unshift(o))}for(c=c.length,f=0;f<c;f++)o=e[f],m=a.lang.elementspath.eleTitle.replace(/%1/,o),o=d.output({id:j+f,label:m,text:o,jsTitle:"javascript:void('"+o+"')",index:f,keyDownFn:l,clickFn:k}),b.unshift(o);h||(h=CKEDITOR.document.getById(g)),e=h,e.setHtml(b.join("")+'<span class="cke_path_empty"> </span>'),a.fire("elementsPathUpdate",{space:e})}),a.on("readOnly",f),a.on("contentDomUnload",f),a.addCommand("elementsPathFocus",b.toolbarFocus),a.setKeystroke(CKEDITOR.ALT+122,"elementsPathFocus")}var b={toolbarFocus:{editorFocus:!1,readOnly:1,exec:function(a){(a=CKEDITOR.document.getById(a._.elementsPath.idBase+"0"))&&a.focus(CKEDITOR.env.ie||CKEDITOR.env.air)}}},c="";CKEDITOR.env.gecko&&CKEDITOR.env.mac&&(c+=' onkeypress="return false;"'),CKEDITOR.env.gecko&&(c+=' onblur="this.style.cssText = this.style.cssText;"');var d=CKEDITOR.addTemplate("pathItem",'<a id="{id}" href="{jsTitle}" tabindex="-1" class="cke_path_item" title="{label}"'+c+' hidefocus="true" onkeydown="return CKEDITOR.tools.callFunction({keyDownFn},{index}, event );" onclick="CKEDITOR.tools.callFunction({clickFn},{index}); return false;" role="button" aria-label="{label}">{text}</a>');CKEDITOR.plugins.add("elementspath",{init:function(b){b._.elementsPath={idBase:"cke_elementspath_"+CKEDITOR.tools.getNextNumber()+"_",f
12ilters:[]},b.on("uiSpace",function(c){"bottom"==c.data.space&&a(b,c.data)})}})}(),function(){function a(a,b,c){c=a.config.forceEnterMode||c,"wysiwyg"==a.mode&&(b||(b=a.activeEnterMode),a.elementPath().isContextFor("p")||(b=CKEDITOR.ENTER_BR,c=1),a.fire("saveSnapshot"),b==CKEDITOR.ENTER_BR?g(a,b,null,c):h(a,b,null,c),a.fire("saveSnapshot"))}function b(a){a=a.getSelection().getRanges(!0);for(var b=a.length-1;0<b;b--)a[b].deleteContents();return a[0]}function c(a){var b=a.startContainer.getAscendant(function(a){return a.type==CKEDITOR.NODE_ELEMENT&&"true"==a.getAttribute("contenteditable")},!0);return a.root.equals(b)?a:(b=new CKEDITOR.dom.range(b),b.moveToRange(a),b)}CKEDITOR.plugins.add("enterkey",{init:function(b){b.addCommand("enter",{modes:{wysiwyg:1},editorFocus:!1,exec:function(b){a(b)}}),b.addCommand("shiftEnter",{modes:{wysiwyg:1},editorFocus:!1,exec:function(b){a(b,b.activeShiftEnterMode,1)}}),b.setKeystroke([[13,"enter"],[CKEDITOR.SHIFT+13,"shiftEnter"]])}});var d=CKEDITOR.dom.walker.whitespaces(),e=CKEDITOR.dom.walker.bookmark();CKEDITOR.plugins.enterkey={enterBlock:function(a,f,h,j){if(h=h||b(a)){h=c(h);var q,k=h.document,l=h.checkStartOfBlock(),m=h.checkEndOfBlock(),n=a.elementPath(h.startContainer),o=n.block,p=f==CKEDITOR.ENTER_DIV?"div":"p";if(l&&m){if(o&&(o.is("li")||o.getParent().is("li"))){o.is("li")||(o=o.getParent()),h=o.getParent(),q=h.getParent(),j=!o.hasPrevious();var r=!o.hasNext(),p=a.getSelection(),s=p.createBookmarks(),l=o.getDirection(1),m=o.getAttribute("class"),t=o.getAttribute("style"),u=q.getDirection(1)!=l;if(a=a.enterMode!=CKEDITOR.ENTER_BR||u||t||m,q.is("li"))j||r?(j&&r&&h.remove(),o[r?"insertAfter":"insertBefore"](q)):o.breakParent(q);else{if(a)n.block.is("li")?(q=k.createElement(f==CKEDITOR.ENTER_P?"p":"div"),u&&q.setAttribute("dir",l),t&&q.setAttribute("style",t),m&&q.setAttribute("class",m),o.moveChildren(q)):q=n.block,j||r?q[j?"insertBefore":"insertAfter"](h):(o.breakParent(h),q.insertAfter(h));else if(o.appendBogus(!0),j||r)for(;k=o[j?"getFirst":"getLast"]();)k[j?"insertBefore":"insertAfter"](h);else for(o.breakParent(h);k=o.getLast();)k.insertAfter(h);o.remove()}return void p.selectBookmarks(s)}if(o&&o.getParent().is("blockquote"))return o.breakParent(o.getParent()),o.getPrevious().getFirst(CKEDITOR.dom.walker.invisible(1))||o.getPrevious().remove(),o.getNext().getFirst(CKEDITOR.dom.walker.invisible(1))||o.getNext().remove(),h.moveToElementEditStart(o),void h.select()}else if(o&&o.is("pre")&&!m)return void g(a,f,h,j);if(l=h.splitBlock(p)){if(f=l.previousBlock,o=l.nextBlock,n=l.wasStartOfBlock,a=l.wasEndOfBlock,o?(s=o.getParent(),s.is("li")&&(o.breakParent(s),o.move(o.getNext(),1))):f&&(s=f.getParent())&&s.is("li")&&(f.breakParent(s),s=f.getNext(),h.moveToElementEditStart(s),f.move(f.getPrevious())),n||a){if(f?(f.is("li")||!i.test(f.getName())&&!f.is("pre"))&&(q=f.clone()):o&&(q=o.clone()),q?j&&!q.is("li")&&q.renameNode(p):s&&s.is("li")?q=s:(q=k.createElement(p),f&&(r=f.getDirection())&&q.setAttribute("dir",r)),k=l.elementPath)for(j=0,p=k.elements.length;j<p&&(s=k.elements[j],!s.equals(k.block)&&!s.equals(k.blockLimit));j++)CKEDITOR.dtd.$removeEmpty[s.getName()]&&(s=s.clone(),q.moveChildren(s),q.append(s));q.appendBogus(),q.getParent()||h.insertNode(q),q.is("li")&&q.removeAttribute("value"),!CKEDITOR.env.ie||!n||a&&f.getChildCount()||(h.moveToElementEditStart(a?f:q),h.select()),h.moveToElementEditStart(n&&!a?o:q)}else o.is("li")&&(q=h.clone(),q.selectNodeContents(o),q=new CKEDITOR.dom.walker(q),q.evaluator=function(a){return!(e(a)||d(a)||a.type==CKEDITOR.NODE_ELEMENT&&a.getName()in CKEDITOR.dtd.$inline&&!(a.getName()in CKEDITOR.dtd.$empty))},(s=q.next())&&s.type==CKEDITOR.NODE_ELEMENT&&s.is("ul","ol")&&(CKEDITOR.env.needsBrFiller?k.createElement("br"):k.createText("Â ")).insertBefore(s)),o&&h.moveToElementEditStart(o);h.select(),h.scrollIntoView()}}},enterBr:function(a,c,d,e){if(d=d||b(a)){var f=d.document,g=d.checkEndOfBlock(),j=new CKEDITOR.dom.elementPath(a.getSelection().getStartElement()),k=j.block,l=k&&j.block.getName();e||"li"!=l?(!e&&g&&i.test(l)?(g=k.getDirection())?(f=f.createElement("div"),f.setAttribute("dir",g),f.insertAfter(k),d.setStart(f,0)):(f.createElement("br").insertAfter(k),CKEDITOR.env.gecko&&f.createText("").insertAfter(k),d.setStartAt(k.getNext(),CKEDITOR.env.ie?CKEDITOR.POSITION_BEFORE_START:CKEDITOR.POSITION_AFTER_START)):(a="pre"==l&&CKEDITOR.env.ie&&8>CKEDITOR.env.version?f.createText("\r"):f.createElement("br"),d.deleteContents(),d.insertNode(a),CKEDITOR.env.needsBrFiller?(f.createText("\ufeff").insertAfter(a),g&&(k||j.blockLimit).appendBogus(),a.getNext().$.nodeValue="",d.setStartAt(a.getNext(),CKEDITOR.POSITION_AFTER_START)):d.setStartAt(a,CKEDITOR.POSITION_AFTER_END)),d.collapse(!0),d.select(),d.scrollIntoView()):h(a,c,d,e)}}};var f=CKEDITOR.plugins.enterkey,g=f.enterBr,h=f.enterBlock,i=/^h[1-6]$/}(),function(){function a(a,b){var c={},d=[],e={nbsp:"Â ",shy:"Â",gt:">",lt:"<",amp:"&",apos:"'",quot:'"'};if(a=a.replace(/\b(nbsp|shy|gt|lt|amp|apos|quot)(?:,|$)/g,function(a,f){var g=b?"&"+f+";":e[f];return c[g]=b?e[f]:"&"+f+";",d.push(g),""}),!b&&a){a=a.split(",");var g,f=document.createElement("div");for(f.innerHTML="&"+a.join(";&")+";",g=f.innerHTML,f=null,f=0;f<g.length;f++){var h=g.charAt(f);c[h]="&"+a[f]+";",d.push(h)}}return c.regex=d.join(b?"|":""),c}CKEDITOR.plugins.add("entities",{afterInit:function(b){function c(a){return i[a]}function d(a){return"force"!=e.entities_processNumerical&&g[a]?g[a]:"&#"+a.charCo
12deAt(0)+";"}var e=b.config;if(b=(b=b.dataProcessor)&&b.htmlFilter){var f=[];!1!==e.basicEntities&&f.push("nbsp,gt,lt,amp"),e.entities&&(f.length&&f.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"),e.entities_latin&&f.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"),e.entities_greek&&f.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"),e.entities_additional&&f.push(e.entities_additional));var g=a(f.join(",")),h=g.regex?"["+g.regex+"]":"a^";delete g.regex,e.entities&&e.entities_processNumerical&&(h="[^ -~]|"+h);var h=new RegExp(h,"g"),i=a("nbsp,gt,lt,amp,shy",!0),j=new RegExp(i.regex,"g");b.addRules({text:function(a){return a.replace(j,c).replace(h,d)}},{applyToAll:!0,excludeNestedEditable:!0})}}})}(),CKEDITOR.config.basicEntities=!0,CKEDITOR.config.entities=!0,CKEDITOR.config.entities_latin=!0,CKEDITOR.config.entities_greek=!0,CKEDITOR.config.entities_additional="#39",CKEDITOR.plugins.add("popup"),CKEDITOR.tools.extend(CKEDITOR.editor.prototype,{popup:function(a,b,c,d){b=b||"80%",c=c||"70%","string"==typeof b&&1<b.length&&"%"==b.substr(b.length-1,1)&&(b=parseInt(window.screen.width*parseInt(b,10)/100,10)),"string"==typeof c&&1<c.length&&"%"==c.substr(c.length-1,1)&&(c=parseInt(window.screen.height*parseInt(c,10)/100,10)),640>b&&(b=640),420>c&&(c=420);var e=parseInt((window.screen.height-c)/2,10),f=parseInt((window.screen.width-b)/2,10);d=(d||"location=no,menubar=no,toolbar=no,dependent=yes,minimizable=no,modal=yes,alwaysRaised=yes,resizable=yes,scrollbars=yes")+",width="+b+",height="+c+",top="+e+",left="+f;var g=window.open("",null,d,!0);if(!g)return!1;try{-1==navigator.userAgent.toLowerCase().indexOf(" chrome/")&&(g.moveTo(f,e),g.resizeTo(b,c)),g.focus(),g.location.href=a}catch(b){window.open(a,null,d,!0)}return!0}}),function(){function a(a,b){var c=[];if(!b)return a;for(var d in b)c.push(d+"="+encodeURIComponent(b[d]));return a+(-1!=a.indexOf("?")?"&":"?")+c.join("&")}function b(a){return a+="",a.charAt(0).toUpperCase()+a.substr(1)}function c(){var c=this.getDialog(),d=c.getParentEditor();d._.filebrowserSe=this;var e=d.config["filebrowser"+b(c.getName())+"WindowWidth"]||d.config.filebrowserWindowWidth||"80%",c=d.config["filebrowser"+b(c.getName())+"WindowHeight"]||d.config.filebrowserWindowHeight||"70%",f=this.filebrowser.params||{};f.CKEditor=d.name,f.CKEditorFuncNum=d._.filebrowserFn,f.langCode||(f.langCode=d.langCode),f=a(this.filebrowser.url,f),d.popup(f,e,c,d.config.filebrowserWindowFeatures||d.config.fileBrowserWindowFeatures)}function d(){var a=this.getDialog();return a.getParentEditor()._.filebrowserSe=this,!(!a.getContentElement(this.for[0],this.for[1]).getInputElement().$.value||!a.getContentElement(this.for[0],this.for[1]).getAction())}function e(b,c,d){var e=d.params||{};e.CKEditor=b.name,e.CKEditorFuncNum=b._.filebrowserFn,e.langCode||(e.langCode=b.langCode),c.action=a(d.url,e),c.filebrowser=d}function f(a,g,h,i){if(i&&i.length)for(var j,k=i.length;k--;)if(j=i[k],"hbox"!=j.type&&"vbox"!=j.type&&"fieldset"!=j.type||f(a,g,h,j.children),j.filebrowser)if("string"==typeof j.filebrowser&&(j.filebrowser={action:"fileButton"==j.type?"QuickUpload":"Browse",target:j.filebrowser}),"Browse"==j.filebrowser.action){var l=j.filebrowser.url;
12void 0===l&&(l=a.config["filebrowser"+b(g)+"BrowseUrl"],void 0===l&&(l=a.config.filebrowserBrowseUrl)),l&&(j.onClick=c,j.filebrowser.url=l,j.hidden=!1)}else if("QuickUpload"==j.filebrowser.action&&j.for&&(l=j.filebrowser.url,void 0===l&&(l=a.config["filebrowser"+b(g)+"UploadUrl"],void 0===l&&(l=a.config.filebrowserUploadUrl)),l)){var m=j.onClick;j.onClick=function(a){var b=a.sender;return(!m||!1!==m.call(b,a))&&(!!d.call(b,a)&&(a=b.getDialog().getContentElement(this.for[0],this.for[1]).getInputElement(),(b=new CKEDITOR.dom.element(a.$.form))&&((a=b.$.elements.ckCsrfToken)?a=new CKEDITOR.dom.element(a):(a=new CKEDITOR.dom.element("input"),a.setAttributes({name:"ckCsrfToken",type:"hidden"}),b.append(a)),a.setAttribute("value",CKEDITOR.tools.getCsrfToken())),!0))},j.filebrowser.url=l,j.hidden=!1,e(a,h.getContents(j.for[0]).get(j.for[1]),j.filebrowser)}}function g(a,b,c){if(-1!==c.indexOf(";")){c=c.split(";");for(var d=0;d<c.length;d++)if(g(a,b,c[d]))return!0;return!1}return(a=a.getContents(b).get(c).filebrowser)&&a.url}function h(a,b){var c=this._.filebrowserSe.getDialog(),d=this._.filebrowserSe.for,e=this._.filebrowserSe.filebrowser.onSelect;
12d&&c.getContentElement(d[0],d[1]).reset(),"function"==typeof b&&!1===b.call(this._.filebrowserSe)||e&&!1===e.call(this._.filebrowserSe,a,b)||("string"==typeof b&&b&&alert(b),a&&(d=this._.filebrowserSe,c=d.getDialog(),d=d.filebrowser.target||null)&&(d=d.split(":"),(e=c.getContentElement(d[0],d[1]))&&(e.setValue(a),c.selectPage(d[0]))))}CKEDITOR.plugins.add("filebrowser",{requires:"popup",init:function(a){a._.filebrowserFn=CKEDITOR.tools.addFunction(h,a),a.on("destroy",function(){CKEDITOR.tools.removeFunction(this._.filebrowserFn)})}}),CKEDITOR.on("dialogDefinition",function(a){if(a.editor.plugins.filebrowser)for(var c,b=a.data.definition,d=0;d<b.contents.length;++d)(c=b.contents[d])&&(f(a.editor,a.data.name,b,c.elements),c.hidden&&c.filebrowser&&(c.hidden=!g(b,c.id,c.filebrowser)))})}(),CKEDITOR.plugins.add("find",{requires:"dialog",init:function(a){var b=a.addCommand("find",new CKEDITOR.dialogCommand("find"));b.canUndo=!1,b.readOnly=1,a.addCommand("replace",new CKEDITOR.dialogCommand("replace")).canUndo=!1,a.ui.addButton&&(a.ui.addButton("Find",{label:a.lang.find.find,command:"find",toolbar:"find,10"}),a.ui.addButton("Replace",{label:a.lang.find.replace,command:"replace",toolbar:"find,20"})),CKEDITOR.dialog.add("find",this.path+"dialogs/find.js"),CKEDITOR.dialog.add("replace",this.path+"dialogs/find.js")}}),CKEDITOR.config.find_highlight={element:"span",styles:{"background-color":"#004",color:"#fff"}},function(){function a(a,b){var c=d.exec(a),e=d.exec(b);if(c){if(!c[2]&&"px"==e[2])return e[1];if("px"==c[2]&&!e[2])return e[1]+"px"}return b}var b=CKEDITOR.htmlParser.cssStyle,c=CKEDITOR.tools.cssLength,d=/^((?:\d*(?:\.\d+))|(?:\d+))(.*)?$/i,e={elements:{$:function(c){var d=c.attributes;if((d=(d=(d=d&&d["data-cke-realelement"])&&new CKEDITOR.htmlParser.fragment.fromHtml(decodeURIComponent(d)))&&d.children[0])&&c.attributes["data-cke-resizable"]){var e=new b(c).rules;c=d.attributes;var f=e.width,e=e.height;f&&(c.width=a(c.width,f)),e&&(c.height=a(c.height,e))}return d}}};CKEDITOR.plugins.add("fakeobjects",{init:function(a){a.filter.allow("img[!data-cke-realelement,src,alt,title](*){*}","fakeobjects")},afterInit:function(a){(a=(a=a.dataProcessor)&&a.htmlFilter)&&a.addRules(e,{applyToAll:!0})}}),CKEDITOR.editor.prototype.createFakeElement=function(a,d,e,f){var g=this.lang.fakeobjects,g=g[e]||g.unknown;return d={class:d,"data-cke-realelement":encodeURIComponent(a.getOuterHtml()),"data-cke-real-node-type":a.type,alt:g,title:g,align:a.getAttribute("align")||""},CKEDITOR.env.hc||(d.src=CKEDITOR.tools.transparentImageData), 13e&&(d["data-cke-real-element-type"]=e),f&&(d["data-cke-resizable"]=f,e=new b,f=a.getAttribute("width"),a=a.getAttribute("height"),f&&(e.rules.width=c(f)),a&&(e.rules.height=c(a)),e.populate(d)),this.document.createElement("img",{attributes:d})},CKEDITOR.editor.prototype.createFakeParserElement=function(a,d,e,f){var h,g=this.lang.fakeobjects,g=g[e]||g.unknown;return h=new CKEDITOR.htmlParser.basicWriter,a.writeHtml(h),h=h.getHtml(),d={class:d,"data-cke-realelement":encodeURIComponent(h),"data-cke-real-node-type":a.type,alt:g,title:g,align:a.attributes.align||""},CKEDITOR.env.hc||(d.src=CKEDITOR.tools.transparentImageData),e&&(d["data-cke-real-element-type"]=e),f&&(d["data-cke-resizable"]=f,f=a.attributes,a=new b,e=f.width,f=f.height,void 0!==e&&(a.rules.width=c(e)),void 0!==f&&(a.rules.height=c(f)),a.populate(d)),new CKEDITOR.htmlParser.element("img",d)},CKEDITOR.editor.prototype.restoreRealElement=function(b){if(b.data("cke-real-node-type")!=CKEDITOR.NODE_ELEMENT)return null;var c=CKEDITOR.dom.element.createFromHtml(decodeURIComponent(b.data("cke-realelement")),this.document);if(b.data("cke-resizable")){var d=b.getStyle("width");b=b.getStyle("height"),d&&c.setAttribute("width",a(c.getAttribute("width"),d)),b&&c.setAttribute("height",a(c.getAttribute("height"),b))}return c}}(),function(){function a(a){return a=a.attributes,"application/x-shockwave-flash"==a.type||c.test(a.src||"")}function b(a,b){return a.createFakeParserElement(b,"cke_flash","flash",!0)}var c=/\.swf(?:$|\?)/i;CKEDITOR.plugins.add("flash",{requires:"dialog,fakeobjects",onLoad:function(){CKEDITOR.addCss("img.cke_flash{background-image: url("+CKEDITOR.getUrl(this.path+"images/placeholder.png")+");background-position: center center;background-repeat: no-repeat;border: 1px solid #a9a9a9;width: 80px;height: 80px;}")},init:function(a){var b="object[classid,codebase,height,hspace,vspace,width];param[name,value];embed[height,hspace,pluginspage,src,type,vspace,width]";CKEDITOR.dialog.isTabEnabled(a,"flash","properties")&&(b+=";object[align];
13 embed[allowscriptaccess,quality,scale,wmode]"),CKEDITOR.dialog.isTabEnabled(a,"flash","advanced")&&(b+=";object[id]{*}; embed[bgcolor]{*}(*)"),a.addCommand("flash",new CKEDITOR.dialogCommand("flash",{allowedContent:b,requiredContent:"embed"})),a.ui.addButton&&a.ui.addButton("Flash",{label:a.lang.common.flash,command:"flash",toolbar:"insert,20"}),CKEDITOR.dialog.add("flash",this.path+"dialogs/flash.js"),a.addMenuItems&&a.addMenuItems({flash:{label:a.lang.flash.properties,command:"flash",group:"flash"}}),a.on("doubleclick",function(a){var b=a.data.element;b.is("img")&&"flash"==b.data("cke-real-element-type")&&(a.data.dialog="flash")}),a.contextMenu&&a.contextMenu.addListener(function(a){if(a&&a.is("img")&&!a.isReadOnly()&&"flash"==a.data("cke-real-element-type"))return{flash:CKEDITOR.TRISTATE_OFF}})},afterInit:function(c){var d=c.dataProcessor;(d=d&&d.dataFilter)&&d.addRules({elements:{"cke:object":function(d){var e=d.attributes;if(!(e.classid&&String(e.classid).toLowerCase()||a(d))){for(e=0;e<d.children.length;e++)if("cke:embed"==d.children[e].name){if(!a(d.children[e]))break;return b(c,d)}return null}return b(c,d)},"cke:embed":function(d){return a(d)?b(c,d):null}}},5)}})}(),CKEDITOR.tools.extend(CKEDITOR.config,{flashEmbedTagOnly:!1,flashAddEmbedTag:!0,flashConvertOnEdit:!1}),function(){function a(a){var d=a.config,e=a.fire("uiSpace",{space:"top",html:""}).html,f=function(){function e(a,b,d){h.setStyle(b,c(d)),h.setStyle("position",a)}function g(a){var b=j.getDocumentPosition();switch(a){case"top":e("absolute","top",b.y-n-q);break;case"pin":e("fixed","top",s);break;case"bottom":e("absolute","top",b.y+(l.height||l.bottom-l.top)+q)}i=a}var i,j,k,l,m,n,o,p=d.floatSpaceDockedOffsetX||0,q=d.floatSpaceDockedOffsetY||0,r=d.floatSpacePinnedOffsetX||0,s=d.floatSpacePinnedOffsetY||0;return function(e){if(j=a.editable()){var s=e&&"focus"==e.name;s&&h.show(),a.fire("floatingSpaceLayout",{show:s}),h.removeStyle("left"),h.removeStyle("right"),k=h.getClientRect(),l=j.getClientRect(),m=b.getViewPaneSize(),n=k.height,o="pageXOffset"in b.$?b.$.pageXOffset:CKEDITOR.document.$.documentElement.scrollLeft,i?(g(n+q<=l.top?"top":n+q>m.height-l.bottom?"pin":"bottom"),e=m.width/2,e=d.floatSpacePreferRight?"right":0<l.left&&l.right<m.width&&l.width>k.width?"rtl"==d.contentsLangDirection?"right":"left":e-l.left>l.right-e?"left":"right",k.width>m.width?(e="left",s=0):(s="left"==e?0<l.left?l.left:0:l.right<m.width?m.width-l.right:0,s+k.width>m.width&&(e="left"==e?"right":"left",s=0)),h.setStyle(e,c(("pin"==i?r:p)+s+("pin"==i?0:"left"==e?o:-o)))):(i="pin",g("pin"),f(e))}}}();if(e){var g=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(g.output({content:e,id:a.id,langDir:a.lang.dir,langCode:a.langCode,name:a.name,style:"display:none;z-index:"+(d.baseFloatZIndex-1),topId:a.ui.spaceId("top"),voiceLabel:a.title}))),i=CKEDITOR.tools.eventsBuffer(500,f),j=CKEDITOR.tools.eventsBuffer(100,f);h.unselectable(),h.on("mousedown",function(a){a=a.data,a.getTarget().hasAscendant("a",1)||a.preventDefault()}),a.on("focus",function(c){f(c),a.on("change",i.input),b.on("scroll",j.input),b.on("resize",j.input)}),a.on("blur",function(){h.hide(),a.removeListener("change",i.input),b.removeListener("scroll",j.input),b.removeListener("resize",j.input)}),a.on("destroy",function(){b.removeListener("scroll",j.input),b.removeListener("resize",j.input),h.clearCustomData(),h.remove()}),a.focusManager.hasFocus&&h.show(),a.focusManager.add(h,1)}}var b=CKEDITOR.document.getWindow(),c=CKEDITOR.tools.cssLength;CKEDITOR.plugins.add("floatingspace",{init:function(b){b.on("loaded",function(){a(this)},null,null,20)}})}(),CKEDITOR.plugins.add("listblock",{requires:"panel",onLoad:function(){var a=CKEDITOR.addTemplate("panel-list",'<ul role="presentation" class="cke_panel_list">{items}</ul>'),b=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>'),c=CKEDITOR.addTemplate("panel-list-group",'<h1 id="{id}" class="cke_panel_grouptitle" role="presentation" >{label}</h1>'),d=/\'/g;CKEDITOR.ui.panel.prototype.addListBlock=function(a,b){return this.addBlock(a,new CKEDITOR.ui.listBlock(this.getHolderElement(),b))},CKEDITOR.ui.listBlock=CKEDITOR.tools.createClass({base:CKEDITOR.ui.panel.block,$:function(a,b){b=b||{};var c=b.attributes||(b.attributes={});(this.multiSelect=!!b.multiSelect)&&(c["aria-multiselectable"]=!0),!c.role&&(c.role="listbox"),this.base.apply(this,arguments),this.element.setAttribute("role",c.role),c=this.keys,c[40]="next",c[9]="next",c[38]="prev",c[CKEDITOR.SH
13IFT+9]="prev",c[32]=CKEDITOR.env.ie?"mouseup":"click",CKEDITOR.env.ie&&(c[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(){return this._.click||(this._.click=CKEDITOR.tools.addFunction(function(a){var b=this.toggle(a);this.onClick&&this.onClick(a,b)},this)),this._.click}},proto:{add:function(a,c,e){var f=CKEDITOR.tools.getNextId();this._.started||(this._.started=1,this._.size=this._.size||0),this._.items[a]=f;var g;g=CKEDITOR.tools.htmlEncodeAttr(a).replace(d,"\\'"),a={id:f,val:g,onclick:CKEDITOR.env.ie?'onclick="return false;" onmouseup':"onclick",clickFn:this._.getClick(),title:CKEDITOR.tools.htmlEncodeAttr(e||a),text:c||a},this._.pendingList.push(b.output(a))},startGroup:function(a){this._.close();var b=CKEDITOR.tools.getNextId();this._.groups[a]=b,this._.pendingHtml.push(c.output({id:b,label:a}))},commit:function(){this._.close(),this.element.appendHtml(this._.pendingHtml.join("")),delete this._.size,this._.pendingHtml=[]},toggle:function(a){var b=this.isMarked(a);return b?this.unmark(a):this.mark(a),!b},hideGroup:function(a){var b=(a=this.element.getDocument().getById(this._.groups[a]))&&a.getNext();a&&(a.setStyle("display","none"),b&&"ul"==b.getName()&&b.setStyle("display","none"))},hideItem:function(a){this.element.getDocument().getById(this._.items[a]).setStyle("display","none")},showAll:function(){var d,a=this._.items,b=this._.groups,c=this.element.getDocument();for(d in a)c.getById(a[d]).setStyle("display","");for(var e in b)a=c.getById(b[e]),d=a.getNext(),a.setStyle("display",""),d&&"ul"==d.getName()&&d.setStyle("display","")},mark:function(a){this.multiSelect||this.unmarkAll(),a=this._.items[a];var b=this.element.getDocument().getById(a);b.addClass("cke_selected"),this.element.getDocument().getById(a+"_option").setAttribute("aria-selected",!0),this.onMark&&this.onMark(b)},unmark:function(a){var b=this.element.getDocument();a=this._.items[a];var c=b.getById(a);c.removeClass("cke_selected"),b.getById(a+"_option").removeAttribute("aria-selected"),this.onUnmark&&this.onUnmark(c)},unmarkAll:function(){var c,a=this._.items,b=this.element.getDocument();for(c in a){var d=a[c];b.getById(d).removeClass("cke_selected"),b.getById(d+"_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,b=this.element.getElementsByTag("a"),d=-1;if(a){for(c=this.element.getDocument().getById(this._.items[a]).getFirst();a=b.getItem(++d);)if(a.equals(c)){this._.focusIndex=d;break}}else this.element.focus();c&&setTimeout(function(){c.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+=' onkeypress="return false;"'),CKEDITOR.env.gecko&&(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?"▼":CKEDITOR.env.air?" ":"")+"</span></span></a></span>"),b=CKEDITOR.addTemplate("combo",a);CKEDITOR.UI_RICHCOMBO="richcombo",CKEDITOR.ui.richCombo=CKEDITOR.tools.createClass({$:function(a){CKEDITOR.tools.extend(this,a,{canGroup:!1,title:a.label,modes:{wysiwyg:1},editorFocus:1}),a=this.panel||{},delete this.panel,this.id=CKEDITOR.tools.getNextNumber(),this.document=a.parent&&a.parent.getDocument()||CKEDITOR.document,a.className="
13cke_combopanel",a.block={multiSelect:a.multiSelect,attributes:a.attributes},a.toolbarRelated=!0,this._={panelDefinition:a,items:{}}},proto:{renderHtml:function(a){var b=[];return this.render(a,b),b.join("")},render:function(a,c){function d(){if(this.getState()!=CKEDITOR.TRISTATE_ON){var b=this.modes[a.mode]?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED;a.readOnly&&!this.readOnly&&(b=CKEDITOR.TRISTATE_DISABLED),this.setState(b),this.setValue(""),b!=CKEDITOR.TRISTATE_DISABLED&&this.refresh&&this.refresh()}}var e=CKEDITOR.env,f="cke_"+this.id,g=CKEDITOR.tools.addFunction(function(b){l&&(a.unlockSelection(1),l=0),i.execute(b)},this),h=this,i={id:f,combo:this,focus:function(){CKEDITOR.document.getById(f).getChild(1).focus()},execute:function(b){var c=h._;if(c.state!=CKEDITOR.TRISTATE_DISABLED)if(h.createPanel(a),c.on)c.panel.hide();else{h.commit();var d=h.getValue();d?c.list.mark(d):c.list.unmarkAll(),c.panel.showBlock(h.id,new CKEDITOR.dom.element(b),4)}},clickFn:g};a.on("activeFilterChange",d,this),a.on("mode",d,this),a.on("selectionChange",d,this),!this.readOnly&&a.on("readOnly",d,this);var j=CKEDITOR.tools.addFunction(function(b,c){b=new CKEDITOR.dom.event(b);var d=b.getKeystroke();switch(40==d&&a.once("panelShow",function(a){a.data._.panel._.currentBlock.onKeyDown(40)}),d){case 13:case 32:case 40:CKEDITOR.tools.callFunction(g,c);break;default:i.onkey(i,d)}b.preventDefault()}),k=CKEDITOR.tools.addFunction(function(){i.onfocus&&i.onfocus()}),l=0;return i.keyDownFn=j,e={id:f,name:this.name||this.command,label:this.label,title:this.title,cls:this.className||"",titleJs:e.gecko&&!e.hc?"":(this.title||"").replace("'",""),keydownFn:j,focusFn:k,clickFn:g},b.output(e,c),this.onRender&&this.onRender(),i},createPanel:function(a){if(!this._.panel){var b=this._.panelDefinition,c=this._.panelDefinition.block,d=b.parent||CKEDITOR.document.getBody(),e="cke_combopanel__"+this.name,f=new CKEDITOR.ui.floatPanel(a,d,b),g=f.addListBlock(this.id,c),h=this;f.onShow=function(){this.element.addClass(e),h.setState(CKEDITOR.TRISTATE_ON),h._.on=1,h.editorFocus&&!a.focusManager.hasFocus&&a.focus(),h.onOpen&&h.onOpen(),a.once("panelShow",function(){g.focus(!g.multiSelect&&h.getValue())})},f.onHide=function(b){this.element.removeClass(e),h.setState(h.modes&&h.modes[a.mode]?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED),h._.on=0,!b&&h.onClose&&h.onClose()},f.onEscape=function(){f.hide(1)},g.onClick=function(a,b){h.onClick&&h.onClick.call(h,a,b),f.hide()},this._.panel=f,this._.list=g,f.getBlock(this.id).onHide=function(){h._.on=0,h.setState(CKEDITOR.TRISTATE_OFF)},this.init&&this.init()}},setValue:function(a,b){this._.value=a;var c=this.document.getById("cke_"+this.id+"_text");c&&(a||b?c.removeClass("cke_combo_inlinelabel"):(b=this.label,c.addClass("cke_combo_inlinelabel")),c.setText("undefined"!=typeof b?b: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,b,c){this._.items[a]=c||a,this._.list.add(a,b,c)},startGroup:function(a){this._.list.startGroup(a)},commit:function(){this._.committed||(this._.list.commit(),this._.committed=1,CKEDITOR.ui.fire("ready",this)),this._.committed=1},setState:function(a){if(this._.state!=a){var b=this.document.getById("cke_"+this.id);b.setState(a,"cke_combo"),a==CKEDITOR.TRISTATE_DISABLED?b.setAttribute("aria-disabled",!0):b.removeAttribute("aria-disabled"),this._.state=a}},getState:function(){return this._.state},enable:function(){this._.state==CKEDITOR.TRISTATE_DISABLED&&this.setState(this._.lastState)},disable:function(){this._.state!=CKEDITOR.TRISTATE_DISABLED&&(this._.lastState=this._.state,this.setState(CKEDITOR.TRISTATE_DISABLED))}},statics:{handler:{create:function(a){return new CKEDITOR.ui.richCombo(a)}}}}),CKEDITOR.ui.prototype.addRichCombo=function(a,b){this.add(a,CKEDITOR.UI_RICHCOMBO,b)}}(),function(){function a(a,c,d,e,f,g,h,i){var j=a.config,k=new CKEDITOR.style(h),l=f.split(";");f=[];for(var m={},n=0;n<l.length;n++){var o=l[n];if(o){var o=o.split("/"),p={},q=l[n]=o[0];p[d]=f[n]=o[1]||q,m[q]=new CKEDITOR.style(h,p),m[q]._.definition.name=q}else l.splice(n--,1)}a.ui.addRichCombo(c,{label:e.label,title:e.panelTitle,toolbar:"styles,"+i,allowedContent:k,requiredContent:k,panel:{css:[CKEDITOR.skin.getPath("editor")].concat(j.contentsCss),multiSelect:!1,attributes:{"aria-label":e.panelTitle}},init:function(){this.startGroup(e.panelTitle);for(var a=0;a<l.length;a++){var b=l[a];this.add(b,m[b].buildPreview(),b)}},onClick:function(c){a.focus(),a.fire("saveSnapshot");var d=this.getValue(),e=m[c];if(d&&c!=d){var f=m[d],g=a.getSelection().getRanges()[0];if(g.collapsed){var h=a.elementPath(),i=h.contains(function(a){return f.checkElementRemovable(a)});if(i){var j=g.checkBoundaryOfElement(i,CKEDITOR.START),k=g.checkBoundaryOfElement(i,CKEDITOR.END);if(j&&k){for(j=g.createBookmark();h=i.getFirst();)h.insertBefore(i);i.remove(),g.moveToBookmark(j)}else j?g.moveToPosition(i,CKEDITOR.POSITION_BEFORE_START):k?g.moveToPosition(i,CKEDITOR.POSITION_AFTER_END):(g.splitElement(i),g.moveToPosition(i,CKEDITOR.POSITION_AFTER_END),b(g,h.elements.slice(),i));a.getSelection().selectRanges([g])}}else a.removeStyle(f)}a[d==c?"removeStyle":"applyStyle"](e),a.fire("saveSnapshot")},onRender:function(){a.on("selectionChange",function(b){var c=this.getValue();b=b.data.path.elements;for(var e,d=0;d<b.length;d++){e=b[d];for(var f in m)if(m[f].checkElementMatch(e,!0,a))return void(f!=c&&this.setValue(f))}this.setValue("",g)},this)},refresh:function(){a.activeFilter.check(k)||this.setState(CKEDITOR.TRISTATE_DISABLED)}})}function b(a,c,d){var e=c.pop();if(e){if(d)return b(a,c,e.equals(d)?null:d);d=e.clone(),a.insertNode(d),a.moveToPosition(d,CKEDITOR.POSITION_AFTER_START),b(a,c)}}CKEDITOR.plugins.add("font",{requires:"richcombo",init:function(b){var c=b.config;a(b,"Font","family",b.lang.font,c.font_names,c.font_defaultLabel,c.font_style,30),a(b,"FontSize","size",b.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}}]},CKEDITOR.plugins.add("forms",{requires:"dialog,fakeobjects",onLoad:function(){CKEDITOR.addCss(".cke_editable form{border: 1px dotted #FF0000;padding: 2px;}\n"),CKEDITOR.addCss("img.cke_hidden{background-image: url("+CKEDITOR.getUrl(this.path+"images/hiddenfield.gif")+");background-position: center center;background-repeat: no-repeat;border: 1px solid #a9a9a9;width: 16px !important;height: 16px !important;}")},init:function(a){var b=a.lang,c=0,d={email:1,password:1,search:1,tel:1,text:1,url:1},e={checkbox:"input[type,name,checked,required]",radio:"input[type,name,checked,required]",textfield:"input[type,name,value,size,maxlength,required]",textarea:"textarea[cols,rows,name,required]",select:"select[name,size,multiple,required]; option[value,selected]",button:"input[type,name,value]",form:"form[action,name,id,enctype,target,method]",hiddenfield:"input[type,name,value]",imagebutton:"input[type,alt,src]{width,height,border,border-width,border-style,margin,float}"},f={checkbox:"input",radio:"input",textfield:"input",textarea:"textarea",select:"select",button:"input",form:"form",hiddenfield:"input",imagebutton:"input"},g=function(d,g,h){var i={allowedContent:e[g],requiredContent:f[g]};"form"==g&&(i.context="form"),a.addCommand(g,new CKEDITOR.dialogCommand(g,i)),a.ui.addButton&&a.ui.addButton(d,{label:b.common[d.charAt(0).toLowerCase()+d.slice(1)],command:g,toolbar:"forms,"+(c+=10)}),CKEDITOR.dialog.add(g,h)},h=this.path+"dialogs/";!a.blockless&&g("Form","form",h+"form.js"),g("Checkbox","checkbox",h+"checkbox.js"),g("Radio","radio",h+"radio.js"),g("TextField","textfield",h+"textfield.js"),g("Textarea","textarea",h+"textarea.js"),g("Select","select",h+"select.js"),g("Button","button",h+"button.js");var i=a.plugins.image;i&&!a.plugins.image2&&g("ImageButton","imagebutton",CKEDITOR.plugins.getPath("image")+"dialogs/image.js"),g("HiddenField","hiddenfield",h+"hiddenfield.js"),a.addMenuItems&&(g={checkbox:{label:b.forms.checkboxAndRadio.checkboxTitle,command:"checkbox",group:"checkbox"},radio:{label:b.forms.checkboxAndRadio.radioTitle,command:"radio",group:"radio"},textfield:{label:b.forms.textfield.title,command:"textfield",group:"textfield"},hiddenfield:{label:b.forms.hidden.title,command:"hiddenfield",group:"hiddenfield"},button:{label:b.forms.button.title,command:"button",group:"button"},select:{label:b.forms.select.title,command:"select",group:"select"},textarea:{label:b.forms.textarea.title,command:"textarea",group:"textarea"}}
13,i&&(g.imagebutton={label:b.image.titleButton,command:"imagebutton",group:"imagebutton"}),!a.blockless&&(g.form={label:b.forms.form.menu,command:"form",group:"form"}),a.addMenuItems(g)),a.contextMenu&&(!a.blockless&&a.contextMenu.addListener(function(a,b,c){if((a=c.contains("form",1))&&!a.isReadOnly())return{form:CKEDITOR.TRISTATE_OFF}}),a.contextMenu.addListener(function(a){if(a&&!a.isReadOnly()){var b=a.getName();if("select"==b)return{select:CKEDITOR.TRISTATE_OFF};if("textarea"==b)return{textarea:CKEDITOR.TRISTATE_OFF};if("input"==b){var c=a.getAttribute("type")||"text";switch(c){case"button":case"submit":case"reset":return{button:CKEDITOR.TRISTATE_OFF};case"checkbox":return{checkbox:CKEDITOR.TRISTATE_OFF};case"radio":return{radio:CKEDITOR.TRISTATE_OFF};case"image":return i?{imagebutton:CKEDITOR.TRISTATE_OFF}:null}if(d[c])return{textfield:CKEDITOR.TRISTATE_OFF}}if("img"==b&&"hiddenfield"==a.data("cke-real-element-type"))return{hiddenfield:CKEDITOR.TRISTATE_OFF}}})),a.on("doubleclick",function(b){var c=b.data.element;if(!a.blockless&&c.is("form"))b.data.dialog="form";else if(c.is("select"))b.data.dialog="select";else if(c.is("textarea"))b.data.dialog="textarea";else if(c.is("img")&&"hiddenfield"==c.data("cke-real-element-type"))b.data.dialog="hiddenfield";else if(c.is("input")){switch(c=c.getAttribute("type")||"text"){case"button":case"submit":case"reset":b.data.dialog="button";break;case"checkbox":b.data.dialog="checkbox";break;case"radio":b.data.dialog="radio";break;case"image":b.data.dialog="imagebutton"}d[c]&&(b.data.dialog="textfield")}})},afterInit:function(a){var b=a.dataProcessor,c=b&&b.htmlFilter,b=b&&b.dataFilter;CKEDITOR.env.ie&&c&&c.addRules({elements:{input:function(a){a=a.attributes;var b=a.type;b||(a.type="text"),"checkbox"!=b&&"radio"!=b||"on"!=a.value||delete a.value}}},{applyToAll:!0}),b&&b.addRules({elements:{input:function(b){if("hidden"==b.attributes.type)return a.createFakeParserElement(b,"cke_hidden","hiddenfield")}}},{applyToAll:!0})}}),CKEDITOR.plugins.add("format",{requires:"richcombo",init:function(a){if(!a.blockless){for(var b=a.config,c=a.lang.format,d=b.format_tags.split(";"),e={},f=0,g=[],h=0;h<d.length;h++){var i=d[h],j=new CKEDITOR.style(b["format_"+i]);a.filter.customConfig&&!a.filter.check(j)||(f++,e[i]=j,e[i]._.enterMode=a.config.enterMode,g.push(j))}0!==f&&a.ui.addRichCombo("Format",{label:c.label,title:c.panelTitle,toolbar:"styles,20",allowedContent:g,panel:{css:[CKEDITOR.skin.getPath("editor")].concat(b.contentsCss),multiSelect:!1,attributes:{"aria-label":c.panelTitle}},init:function(){this.startGroup(c.panelTitle);for(var a in e){var b=c["tag_"+a];this.add(a,e[a].buildPreview(b),b)}},onClick:function(b){a.focus(),a.fire("saveSnapshot"),b=e[b];var c=a.elementPath();a[b.checkActive(c,a)?"removeStyle":"applyStyle"](b),setTimeout(function(){a.fire("saveSnapshot")},0)},onRender:function(){a.on("selectionChange",function(b){var c=this.getValue();b=b.data.path,this.refresh();for(var d in e)if(e[d].checkActive(b,a))return void(d!=c&&this.setValue(d,a.lang.format["tag_"+d]));this.setValue("")},this)},onOpen:function(){this.showAll();for(var b in e)a.activeFilter.check(e[b])||this.hideItem(b)},refresh:function(){var b=a.elementPath();if(b){if(b.isContextFor("p"))for(var c in e)if(a.activeFilter.check(e[c]))return;this.setState(CKEDITOR.TRISTATE_DISABLED)}}})}}}),CKEDITOR.config.format_tags="p;h1;h2;h3;h4;h5;h6;pre;address;div",CKEDITOR.config.format_p={element:"p"},CKEDITOR.config.format_div={element:"div"},CKEDITOR.config.format_pre={element:"pre"},CKEDITOR.config.format_address={element:"address"},CKEDITOR.config.format_h1={element:"h1"},CKEDITOR.config.format_h2={element:"h2"},CKEDITOR.config.format_h3={element:"h3"},CKEDITOR.config.format_h4={element:"h4"},CKEDITOR.config.format_h5={element:"h5"},CKEDITOR.config.format_h6={element:"h6"},function(){var a={canUndo:!1,exec:function(a){var b=a.document.createElement("hr");a.insertElement(b)},allowedContent:"hr",requiredContent:"hr"};CKEDITOR.plugins.add("horizontalrule",{init:function(b){b.blockless||(b.addCommand("horizontalrule",a),b.ui.addButton&&b.ui.addButton("HorizontalRule",{label:b.lang.horizontalrule.toolbar,command:"horizontalrule",toolbar:"insert,40"}))}})}(),CKEDITOR.plugins.add("htmlwriter",{init:function(a){var b=new CKEDITOR.htmlWriter;b.forceSimpleAmpersand=a.config.forceSimpleAmpersand,b.indentationChars=a.config.dataIndentationChars||"\t",a.dataProcessor.writer=b}}),CKEDITOR.htmlWriter=CKEDITOR.tools.createClass({base:CKEDITOR.htmlParser.basicWriter,$:function(){this.base(),this.indentationChars="\t",this.selfClosingEnd=" />",this.lineBreakChars="\n",this.sortAttributes=1,this._.indent=0,this._.indentation="",this._.inPre=0,this._.rules={};var b,a=CKEDITOR.dtd;for(b in CKEDITOR.tools.extend({},a.$nonBodyContent,a.$block,a.$listItem,a.$tableContent))this.setRules(b,{indent:!a[b]["#"],breakBeforeOpen:1,breakBeforeClose:!a[b]["#"],breakAfterClose:1,needsSpace:b in a.$block&&!(b in{li:1,dt:1,dd:1})});this.setRules("br",{breakAfterOpen:1}),this.setRules("title",{indent:0,breakAfterOpen:0}),this.setRules("style",{indent:0,breakBeforeClose:1}),this.setRules("pre",{breakAfterOpen:1,indent:0})},proto:{openTag:function(a){var b=this._.rules[a];this._.afterCloser&&b&&b.needsSpace&&this._.needsSpace&&this._.output.push("\n"),this._.indent?this.indentation():b&&b.breakBeforeOpen&&(this.lineBreak(),this.indentation()),this._.output.push("<",a),this._.afterCloser=0},openTagClose:function(a,b){var c=this._.rules[a];b?(this._.output.push(this.selfClosingEnd),c&&c.breakAfterClose&&(this._.needsSpace=c.needsSpace)):(this._.output.push(">"),c&&c.indent&&(this._.indentation+=this.indentationChars)),c&&c.breakAfterOpen&&this.lineBreak(),"pre"==a&&(this._.inPre=1)},attribute:function(a,b){"string"==typeof b&&(this.forceSimpleAmpersand&&(b=b.replace(/&/g,"&")),b=CKEDITOR.tools.htmlEncodeAttr(b)),this._.output.push(" ",a,'="',b,'"')},closeTag:function(a){var b=this._.rules[a];b&&b.indent&&(this._.indentation=this._.indentation.substr(this.indentationChars.length)),this._.indent?this.indentation():b&&b.breakBeforeClose&&(this.lineBreak(),this.indentation()),this._.output.push("</",a,">"),"pre"==a&&(this._.inPre=0),b&&b.breakAfterClose&&(this.lineBreak(),this._.needsSpace=b.needsSpace),this._.afterCloser=1},text:function(a){this._.indent&&(this.indentation(),!this._.inPre&&(a=CKEDITOR.tools.ltrim(a))),this._.output.push(a)},comment:function(a){this._.indent&&this.indentation(),this._.output.push("<!--",a,"-->")},lineBreak:function(){!this._.inPre&&0<this._.output.length&&this._.output.push(this.lineBreakChars),this._.indent=1},indentation:function(){!this._.inPre&&this._.indentation&&this._.output.push(this._.indentation),this._.indent=0},reset:function(){this._.output=[],this._.indent=0,this._.indentation="",this._.afterCloser=0,this._.inPre=0},setRules:function(a,b){var c=this._.rules[a];c?CKEDITOR.tools.extend(c,b,!0):this._.rules[a]=b}}}),function(){CKEDITOR.plugins.add("iframe",{requires:"dialog,fakeobjects",onLoad:function(){CKEDITOR.addCss("img.cke_iframe{background-image: url("+CKEDITOR.getUrl(this.path+"images/placeholder.png")+");background-position: center center;background-repeat: no-repeat;border: 1px solid #a9a9a9;width: 80px;height: 80px;}")},init:function(a){var b=a.lang.iframe,c="iframe[align,longdesc,frameborder,height,name,scrolling,src,title,width]";a.plugins.dialogadvtab&&(c+=";iframe"+a.plugins.dialogadvtab.allowedContent({id:1,classes:1,styles:1})),CKEDITOR.dialog.add("iframe",this.path+"dialogs/iframe.js"),a.addCommand("iframe",new CKEDITOR.dialogCommand("iframe",{allowedContent:c,requiredContent:"iframe"})),a.ui.addButton&&a.ui.addButton("Iframe",{label:b.toolbar,command:"iframe",toolbar:"insert,80"}),a.on("doubleclick",function(a){var b=a.data.element;b.is("img")&&"iframe"==b.data("cke-real-element-type")&&(a.data.dialog="iframe")}),a.addMenuItems&&a.addMenuItems({iframe:{label:b.title,command:"iframe",group:"image"}}
13),a.contextMenu&&a.contextMenu.addListener(function(a){if(a&&a.is("img")&&"iframe"==a.data("cke-real-element-type"))return{iframe:CKEDITOR.TRISTATE_OFF}})},afterInit:function(a){var b=a.dataProcessor;(b=b&&b.dataFilter)&&b.addRules({elements:{iframe:function(b){return a.createFakeParserElement(b,"cke_iframe","iframe",!0)}}})}})}(),function(){function a(a){function c(a){var b=!1;h.attachListener(h,"keydown",function(){var c=e.getBody().getElementsByTag(a);if(!b){for(var d=0;d<c.count();d++)c.getItem(d).setCustomData("retain",!0);b=!0}},null,null,1),h.attachListener(h,"keyup",function(){var c=e.getElementsByTag(a);b&&(1!=c.count()||c.getItem(0).getCustomData("retain")||c.getItem(0).remove(1),b=!1)})}var d=this.editor,e=a.document,f=e.body,g=e.getElementById("cke_actscrpt");g&&g.parentNode.removeChild(g),(g=e.getElementById("cke_shimscrpt"))&&g.parentNode.removeChild(g),(g=e.getElementById("cke_basetagscrpt"))&&g.parentNode.removeChild(g),f.contentEditable=!0,CKEDITOR.env.ie&&(f.hideFocus=!0,f.disabled=!0,f.removeAttribute("disabled")),delete this._.isLoadingData,this.$=f,e=new CKEDITOR.dom.document(e),this.setup(),this.fixInitialSelection();var h=this;CKEDITOR.env.ie&&!CKEDITOR.env.edge&&e.getDocumentElement().addClass(e.$.compatMode),CKEDITOR.env.ie&&!CKEDITOR.env.edge&&d.enterMode!=CKEDITOR.ENTER_P?c("p"):CKEDITOR.env.edge&&d.enterMode!=CKEDITOR.ENTER_DIV&&c("div"),(CKEDITOR.env.webkit||CKEDITOR.env.ie&&10<CKEDITOR.env.version)&&e.getDocumentElement().on("mousedown",function(a){a.data.getTarget().is("html")&&setTimeout(function(){d.editable().focus()})}),b(d);try{d.document.$.execCommand("2D-position",!1,!0)}catch(a){}(CKEDITOR.env.gecko||CKEDITOR.env.ie&&"CSS1Compat"==d.document.$.compatMode)&&this.attachListener(this,"keydown",function(a){var b=a.data.getKeystroke();if(33==b||34==b)if(CKEDITOR.env.ie)setTimeout(function(){d.getSelection().scrollIntoView()},0);else if(d.window.$.innerHeight>this.$.offsetHeight){var c=d.createRange();c[33==b?"moveToElementEditStart":"moveToElementEditEnd"](this),c.select(),a.data.preventDefault()}}),CKEDITOR.env.ie&&this.attachListener(e,"blur",function(){try{e.$.selection.empty()}catch(a){}}),CKEDITOR.env.iOS&&this.attachListener(e,"touchend",function(){a.focus()}),f=d.document.getElementsByTag("title").getItem(0),f.data("cke-title",f.getText()),CKEDITOR.env.ie&&(d.document.$.title=this._.docTitle),CKEDITOR.tools.setTimeout(function(){"unloaded"==this.status&&(this.status="ready"),d.fire("contentDom"),this._.isPendingFocus&&(d.focus(),this._.isPendingFocus=!1),setTimeout(function(){d.fire("dataReady")},0)},0,this)}function b(a){function b(){var b;a.editable().attachListener(a,"selectionChange",function(){var d=a.getSelection().getSelectedElement();d&&(b&&(b.detachEvent("onresizestart",c), 14b=null),d.$.attachEvent("onresizestart",c),b=d.$)})}function c(a){a.returnValue=!1}if(CKEDITOR.env.gecko)try{var d=a.document.$;d.execCommand("enableObjectResizing",!1,!a.config.disableObjectResizing),d.execCommand("enableInlineTableEditing",!1,!a.config.disableNativeTableHandles)}catch(a){}else CKEDITOR.env.ie&&11>CKEDITOR.env.version&&a.config.disableObjectResizing&&b(a)}function c(){var a=[];if(8<=CKEDITOR.document.$.documentMode){a.push("html.CSS1Compat [contenteditable=false]{min-height:0 !important}");var c,b=[];for(c in CKEDITOR.dtd.$removeEmpty)b.push("html.CSS1Compat "+c+"[contenteditable=false]");a.push(b.join(",")+"{display:inline-block}")}else CKEDITOR.env.gecko&&(a.push("html{height:100% !important}"),a.push("img:-moz-broken{-moz-force-broken-image-icon:1;min-width:24px;min-height:24px}"));return a.push("html{cursor:text;*cursor:auto}"),a.push("img,input,textarea{cursor:default}"),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(b){function c(c){c&&c.removeListener(),a.editable(new d(a,f.$.contentWindow.document.body)),a.setData(a.getData(1),b)}var e="document.open();"+(CKEDITOR.env.ie?"("+CKEDITOR.tools.fixDomain+")();":"")+"document.close();",e=CKEDITOR.env.air?"javascript:void(0)":CKEDITOR.env.ie&&!CKEDITOR.env.edge?"javascript:void(function(){"+encodeURIComponent(e)+"}())":"",f=CKEDITOR.dom.element.createFromHtml('<iframe src="'+e+'" frameBorder="0"></iframe>');f.setStyles({width:"100%",height:"100%"}),f.addClass("cke_wysiwyg_frame").addClass("cke_reset"),e=a.ui.space("contents"),e.a
14ppend(f);var g=CKEDITOR.env.ie&&!CKEDITOR.env.edge||CKEDITOR.env.gecko;g&&f.on("load",c);var h=a.title,i=a.fire("ariaEditorHelpLabel",{}).label;if(h&&(CKEDITOR.env.ie&&i&&(h+=", "+i),f.setAttribute("title",h)),i){var h=CKEDITOR.tools.getNextId(),j=CKEDITOR.dom.element.createFromHtml('<span id="'+h+'" class="cke_voice_label">'+i+"</span>");e.append(j,1),f.setAttribute("aria-describedby",h)}a.on("beforeModeUnload",function(a){a.removeListener(),j&&j.remove()}),f.setAttributes({tabIndex:a.tabIndex,allowTransparency:"true"}),!g&&c(),a.fire("ariaWidget",f)})}}),CKEDITOR.editor.prototype.addContentsCss=function(a){var b=this.config,c=b.contentsCss;CKEDITOR.tools.isArray(c)||(b.contentsCss=c?[c]:[]),b.contentsCss.push(a)};var d=CKEDITOR.tools.createClass({$:function(){this.base.apply(this,arguments),this._.frameLoadedHandler=CKEDITOR.tools.addFunction(function(b){CKEDITOR.tools.setTimeout(a,0,this,b)},this),this._.docTitle=this.getWindow().getFrame().getAttribute("title")},base:CKEDITOR.editable,proto:{setData:function(a,b){var d=this.editor;if(b)this.setHtml(a),this.fixInitialSelection(),d.fire("dataReady");else{this._.isLoadingData=!0,d._.dataStore={id:1};var e=d.config,f=e.fullPage,g=e.docType,h=CKEDITOR.tools.buildStyleHtml(c()).replace(/<style>/,'<style data-cke-temp="1">');f||(h+=CKEDITOR.tools.buildStyleHtml(d.config.contentsCss));var i=e.baseHref?'<base href="'+e.baseHref+'" data-cke-temp="1" />':"";f&&(a=a.replace(/<!DOCTYPE[^>]*>/i,function(a){return d.docType=g=a,""}).replace(/<\?xml\s[^\?]*\?>/i,function(a){return d.xmlDeclaration=a,""})),a=d.dataProcessor.toHtml(a),f?(/<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>"),i&&(a=a.replace(/<head[^>]*?>/,"$&"+i)),a=a.replace(/<\/head\s*>/,h+"$&"),a=g+a):a=e.docType+'<html dir="'+e.contentsLangDirection+'" lang="'+(e.contentsLanguage||d.langCode)+'"><head><title>'+this._.docTitle+"</title>"+i+h+"</head><body"+(e.bodyId?' id="'+e.bodyId+'"':"")+(e.bodyClass?' class="'+e.bodyClass+'"':"")+">"+a+"</body></html>",CKEDITOR.env.gecko&&(a=a.replace(/<body/,'<body contenteditable="true" '),2e4>CKEDITOR.env.version&&(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&&9>CKEDITOR.env.version&&(e+='<script id="cke_shimscrpt">window.parent.CKEDITOR.tools.enableHtml5Elements(document)</script>'),i&&CKEDITOR.env.ie&&10>CKEDITOR.env.version&&(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(),d.fire("contentDomUnload");var j=this.getDocument();try{j.write(a)}catch(b){setTimeout(function(){j.write(a)},0)}}},getData:function(a){if(a)return this.getHtml();a=this.editor;var b=a.config,c=b.fullPage,d=c&&a.docType,e=c&&a.xmlDeclaration,f=this.getDocument(),c=c?f.getDocumentElement().getOuterHtml():f.getBody().getHtml();return CKEDITOR.env.gecko&&b.enterMode!=CKEDITOR.ENTER_BR&&(c=c.replace(/<br>(?=\s*(:?$|<\/body>))/,"")),c=a.dataProcessor.toDataFormat(c),e&&(c=e+"\n"+c),d&&(c=d+"\n"+c),c},focus:function(){this._.isLoadingData?this._.isPendingFocus=!0:d.baseProto.focus.call(this)},detach:function(){var c,a=this.editor,b=a.document;try{c=a.window.getFrame()}catch(a){}d.baseProto.detach.call(this),this.clearCustomData(),b.getDocumentElement().clearCustomData(),CKEDITOR.tools.removeFunction(this._.frameLoadedHandler),c&&c.getParent()?(c.clearCustomData(),(a=c.removeCustomData("onResize"))&&a.removeListener(),c.remove()):CKEDITOR.warn("editor-destroy-iframe")}}})}(),CKEDITOR.config.disableObjectResizing=!1,CKEDITOR.config.disableNativeTableHandles=!0,CKEDITOR.config.disableNativeSpellChecker=!0,function(){function a(a,b){if(b||(b=a.getSelection().getSelectedElement()),b&&b.is("img")&&!b.data("cke-realelement")&&!b.isReadOnly())return b}function b(a){var b=a.getStyle("float");return"inherit"!=b&&"none"!=b||(b=0),b||(b=a.getAttribute("align")),b}CKEDITOR.plugins.add("image",{requires:"dialog",init:function(b){if(!b.plugins.image2){CKEDITOR.dialog.add("image",this.path+"dialogs/image.js");var c="img[alt,!src]{border-style,border-width,float,height,margin,margin-bottom,margin-left,margin-right,margin-top,width}";CKEDITOR.dialog.isTabEnabled(b,"image","advanced")&&(c="img[alt,dir,id,lang,longdesc,!src,title]{*}(*)"),b.addCommand("image",new CKEDITOR.dialogCommand("image",{allowedContent:c,requiredContent:"img[alt,src]",contentTransformations:[["img{width}
14: sizeToStyle","img[width]: sizeToAttribute"],["img{float}: alignmentToStyle","img[align]: alignmentToAttribute"]]})),b.ui.addButton&&b.ui.addButton("Image",{label:b.lang.common.image,command:"image",toolbar:"insert,10"}),b.on("doubleclick",function(a){var b=a.data.element;!b.is("img")||b.data("cke-realelement")||b.isReadOnly()||(a.data.dialog="image")}),b.addMenuItems&&b.addMenuItems({image:{label:b.lang.image.menu,command:"image",group:"image"}}),b.contextMenu&&b.contextMenu.addListener(function(c){if(a(b,c))return{image:CKEDITOR.TRISTATE_OFF}})}},afterInit:function(c){function d(d){var e=c.getCommand("justify"+d);e&&("left"!=d&&"right"!=d||e.on("exec",function(e){var g,f=a(c);f&&(g=b(f),g==d?(f.removeStyle("float"),d==b(f)&&f.removeAttribute("align")):f.setStyle("float",d),e.cancel())}),e.on("refresh",function(e){var f=a(c);f&&(f=b(f),this.setState(f==d?CKEDITOR.TRISTATE_ON:"right"==d||"left"==d?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED),e.cancel())}))}c.plugins.image2||(d("left"),d("right"),d("center"),d("block"))}})}(),CKEDITOR.config.image_removeLinkByEmptyURL=!0,function(){function a(a,d){var e,f;d.on("refresh",function(a){var e,d=[b];for(e in a.data.states)d.push(a.data.states[e]);this.setState(CKEDITOR.tools.search(d,c)?c:b)},d,null,100),d.on("exec",function(b){e=a.getSelection(),f=e.createBookmarks(1),b.data||(b.data={}),b.data.done=!1},d,null,0),d.on("exec",function(){a.forceNextSelectionCheck(),e.selectBookmarks(f)},d,null,100)}var b=CKEDITOR.TRISTATE_DISABLED,c=CKEDITOR.TRISTATE_OFF;CKEDITOR.plugins.add("indent",{init:function(b){var c=CKEDITOR.plugins.indent.genericDefinition;a(b,b.addCommand("indent",new c((!0)))),a(b,b.addCommand("outdent",new c)),b.ui.addButton&&(b.ui.addButton("Indent",{label:b.lang.indent.indent,command:"indent",directional:!0,toolbar:"indent,20"}),b.ui.addButton("Outdent",{label:b.lang.indent.outdent,command:"outdent",directional:!0,toolbar:"indent,10"})),b.on("dirChanged",function(a){var c=b.createRange(),d=a.data.node;c.setStartBefore(d),c.setEndAfter(d);for(var f,e=new CKEDITOR.dom.walker(c);f=e.next();)if(f.type==CKEDITOR.NODE_ELEMENT)if(!f.equals(d)&&f.getDirection())c.setStartAfter(f),e=new CKEDITOR.dom.walker(c);else{var g=b.config.indentClasses;if(g)for(var h="ltr"==a.data.dir?["_rtl",""]:["","_rtl"],i=0;i<g.length;i++)f.hasClass(g[i]+h[0])&&(f.removeClass(g[i]+h[0]),f.addClass(g[i]+h[1]));g=f.getStyle("margin-right"),h=f.getStyle("margin-left"),g?f.setStyle("margin-left",g):f.removeStyle("margin-left"),h?f.setStyle("margin-right",h):f.removeStyle("margin-right")}})}}),CKEDITOR.plugins.indent={genericDefinition:function(a){this.isIndent=!!a,this.startDisabled=!this.isIndent},specificDefinition:function(a,b,c){this.name=b,this.editor=a,this.jobs={},this.enterBr=a.config.enterMode==CKEDITOR.ENTER_BR,this.isIndent=!!c,this.relatedGlobal=c?"indent":"outdent",this.indentKey=c?9:CKEDITOR.SHIFT+9,this.database={}},registerCommands:function(a,b){a.on("pluginsLoaded",function(){for(var a in b)(function(a,b){var d,c=a.getCommand(b.relatedGlobal);for(d in b.jobs)c.on("exec",function(c){c.data.done||(a.fire("lockSnapshot"),b.execJob(a,d)&&(c.data.done=!0),a.fire("unlockSnapshot"),CKEDITOR.dom.element.clearAllMarkers(b.database))},this,null,d),c.on("refresh",function(c){c.data.states||(c.data.states={}),c.data.states[b.name+"@"+d]=b.refreshJob(a,d,c.data.path)},this,null,d);a.addFeature(b)})(this,b[a])})}},CKEDITOR.plugins.indent.genericDefinition.prototype={context:"p",exec:function(){}},CKEDITOR.plugins.indent.specificDefinition.prototype={execJob:function(a,c){var d=this.jobs[c];if(d.state!=b)return d.exec.call(this,a)},refreshJob:function(a,c,d){return c=this.jobs[c],a.activeFilter.checkFeature(this)?c.state=c.refresh.call(this,a,d):c.state=b,c.state},getContext:function(a){return a.contains(this.context)}}}(),function(){function a(a,c,d){if(!a.getCustomData("indent_processed")){var e=this.editor,f=this.isIndent;if(c){if(e=a.$.className.match(this.classNameRegex),d=0,e&&(e=e[1],d=CKEDITOR.tools.indexOf(c,e)+1),0>(d+=f?1:-1))return;d=Math.min(d,c.length),d=Math.max(d,0),a.$.className=CKEDITOR.tools.ltrim(a.$.className.replace(this.classNameRegex,"")),0<d&&a.addClass(c[d-1])}else{c=b(a,d),d=parseInt(a.getStyle(c),10);var g=e.config.indentOffset||40;if(isNaN(d)&&(d=0),d+=(f?1:-1)*g,0>d)return;d=Math.max(d,0),d=Math.ceil(d/g)*g,a.setStyle(c,d?d+(e.config.indentUnit||"px"):""),""===a.getAttribute("style")&&a.removeAttribute("style")}CKEDITOR.dom.element.setMarker(this.database,a,"indent_processed",1)}}function b(a,b){return"ltr"==(b||a.getComputedStyle("direction"))?"margin-left":"margin-right"}var c=CKEDITOR.dtd.$listItem,d=CKEDITOR.dtd.$list,e=CKEDITOR.TRISTATE_DISABLED,f=CKEDITOR.TRISTATE_OFF;CKEDITOR.plugins.add("indentblock",{requires:"indent",init:function(g){function h(){i.specificDefinition.apply(this,arguments),this.allowedContent={"div h1 h2 h3 h4 h5 h6 ol p pre ul":{propertiesOnly:!0,styles:j?null:"margin-left,margin-right",classes:j||null}},this.enterBr&&(this.allowedContent.div=!0),this.requiredContent=(this.enterBr?"div":"p")+(j?"("+j.join(",")+")":"{margin-left}"),this.jobs={20:{refresh:function(a,d){var g=d.block||d.blockLimit;if(!g.is(c))var h=g.getAscendant(c),g=h&&d.contains(h)||g;if(g.is(c)&&(g=g.getParent()),this.enterBr||this.getContext(d)){if(j){var h=j,g=g.$.className.match(this.classNameRegex),i=this.isIndent,h=g?!i||g[1]!=h.slice(-1):i;return h?f:e}return this.isIndent?f:g?CKEDITOR[0>=(parseInt(g.getStyle(b(g)),10)||0)?"TRISTATE_DISABLED":"TRISTATE_OFF"]:e}return e},exec:function(b){var e,c=b.getSelection(),c=c&&c.getRanges()[0];if(e=b.elementPath().contains(d))a.call(this,e,j);else for(c=c.createIterator(),b=b.config.enterMode,c.enforceRealBlocks=!0,c.enlargeBr=b!=CKEDITOR.ENTER_BR;e=c.getNextParagraph(b==CKEDITOR.ENTER_P?"p":"div");)e.isReadOnly()||a.call(this,e,j);return!0}}}}var i=CKEDITOR.plugins.indent,j=g.config.indentClasses;i.registerCommands(g,{indentblock:new h(g,"indentblock",(!0)),outdentblock:new h(g,"outdentblock")}
14),CKEDITOR.tools.extend(h.prototype,i.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:j?new RegExp("(?:^|\\s+)("+j.join("|")+")(?=$|\\s)"):null})}})}(),function(){function a(a){function d(b){for(var d=i.startContainer,h=i.endContainer;d&&!d.getParent().equals(b);)d=d.getParent();for(;h&&!h.getParent().equals(b);)h=h.getParent();if(!d||!h)return!1;for(var j=d,d=[],k=!1;!k;)j.equals(h)&&(k=!0),d.push(j),j=j.getNext();if(1>d.length)return!1;for(j=b.getParents(!0),h=0;h<j.length;h++)if(j[h].getName&&g[j[h].getName()]){b=j[h];break}for(var j=e.isIndent?1:-1,h=d[0],d=d[d.length-1],k=CKEDITOR.plugins.list.listToArray(b,f),l=k[d.getCustomData("listarray_index")].indent,h=h.getCustomData("listarray_index");h<=d.getCustomData("listarray_index");h++)if(k[h].indent+=j,0<j){var m=k[h].parent;k[h].parent=new CKEDITOR.dom.element(m.getName(),m.getDocument())}for(h=d.getCustomData("listarray_index")+1;h<k.length&&k[h].indent>l;h++)k[h].indent+=j;if(d=CKEDITOR.plugins.list.arrayToList(k,f,null,a.config.enterMode,b.getDirection()),!e.isIndent){var n;if((n=b.getParent())&&n.is("li"))for(var p,j=d.listNode.getChildren(),o=[],h=j.count()-1;0<=h;h--)(p=j.getItem(h))&&p.is&&p.is("li")&&o.push(p)}if(d&&d.listNode.replace(b),o&&o.length)for(h=0;h<o.length;h++){for(p=b=o[h];(p=p.getNext())&&p.is&&p.getName()in g;)CKEDITOR.env.needsNbspFiller&&!b.getFirst(c)&&b.append(i.document.createText("Â ")),b.append(p);b.insertAfter(n)}return d&&a.fire("contentDomInvalidated"),!0}for(var i,e=this,f=this.database,g=this.context,h=a.getSelection(),h=(h&&h.getRanges()).createIterator();i=h.getNextRange();){for(var j=i.getCommonAncestor();j&&(j.type!=CKEDITOR.NODE_ELEMENT||!g[j.getName()]);){if(a.editable().equals(j)){j=!1;break}j=j.getParent()}if(j||(j=i.startPath().contains(g))&&i.setEndAt(j,CKEDITOR.POSITION_BEFORE_END),!j){var k=i.getEnclosedNode();k&&k.type==CKEDITOR.NODE_ELEMENT&&k.getName()in g&&(i.setStartAt(k,CKEDITOR.POSITION_AFTER_START),i.setEndAt(k,CKEDITOR.POSITION_BEFORE_END),j=k)}if(j&&i.startContainer.type==CKEDITOR.NODE_ELEMENT&&i.startContainer.getName()in g&&(k=new CKEDITOR.dom.walker(i),k.evaluator=b,i.startContainer=k.next()),j&&i.endContainer.type==CKEDITOR.NODE_ELEMENT&&i.endContainer.getName()in g&&(k=new CKEDITOR.dom.walker(i),k.evaluator=b,i.endContainer=k.previous()),j)return d(j)}return 0}function b(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.is("li")}function c(a){return d(a)&&e(a)}var d=CKEDITOR.dom.walker.whitespaces(!0),e=CKEDITOR.dom.walker.bookmark(!1,!0),f=CKEDITOR.TRISTATE_DISABLED,g=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("wysiwyg"==b.mode&&a.data.keyCode==this.indentKey){var c=this.getContext(b.elementPath());!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),d=CKEDITOR.plugins.indentList.firstItemInPath(this.context,b,c);return c&&this.isIndent&&!d?g:f}:function(a,b){return!this.getContext(b)||this.isIndent?f:g},exec:CKEDITOR.tools.bind(a,this)}}var d=CKEDITOR.plugins.indent;d.registerCommands(b,{indentlist:new c(b,"indentlist",(!0)),outdentlist:new c(b,"outdentlist")}),CKEDITOR.tools.extend(c.prototype,d.specificDefinition.prototype,{context:{ol:1,ul:1}})}}),CKEDITOR.plugins.indentList={},CKEDITOR.plugins.indentList.firstItemInPath=function(a,c,d){var e=c.contains(b);return d||(d=c.contains(a)),d&&e&&e.equals(d.getFirst(b))}}(),CKEDITOR.plugins.add("smiley",{requires:"dialog",init:function(a){a.config.smiley_path=a.config.smiley_path||this.path+"images/",a.addCommand("smiley",new CKEDITOR.dialogCommand("smiley",{allowedContent:"img[alt,height,!src,title,width]",requiredContent:"img"})),a.ui.addButton&&a.ui.addButton("Smiley",{label:a.lang.smiley.toolbar,command:"smiley",toolbar:"insert,50"}),CKEDITOR.dialog.add("smiley",this.path+"dialogs/smiley.js")}}),CKEDITOR.config.smiley_images="regular_smile.png sad_smile.png wink_smile.png teeth_smile.png confused_smile.png tongue_smile.png embarrassed_smile.png omg_smile.png whatchutalkingabout_smile.png angry_smile.png angel_smile.png shades_smile.png devil_smile.png cry_smile.png lightbulb.png thumbs_down.png thumbs_up.png heart.png broken_heart.png kiss.png envelope.png".split(" "),CKEDITOR.config.smiley_descriptions="smiley;sad;wink;laugh;frown;cheeky;blush;surprise;indecision;angry;angel;cool;devil;crying;enlightened;no;yes;heart;broken heart;kiss;mail".split(";"),function(){function a(a,b){b=void 0===b||b;var c;if(b)c=a.getComputedStyle("text-align");else{for(;(!a.hasAttribute||!a.hasAttribute("align")&&!a.getStyle("text-align"))&&(c=a.getParent(),c);)a=c;c=a.getStyle("text-align")||a.getAttribute("align")||""}return c&&(c=c.replace(/(?:-(?:moz|webkit)-)?(?:start|auto)/i,"")),!c&&b&&(c="rtl"==a.getComputedStyle("direction")?"right":"left"),c}function b(a,b,c){this.editor=a,this.name=b,this.value=c,this.context="p",b=a.config.justifyClasses;var d=a.config.enterMode==CKEDITOR.ENTER_P?"p":"div";if(b){switch(c){case"left":this.cssClassName=b[0];break;case"center":this.cssClassName=b[1];break;case"right":this.cssClassName=b[2];break;case"justify":this.cssClassName=b[3]}this.cssClassRegex=new RegExp("(?:^|\\s+)(?:"+b.join("|")+")(?=$|\\s)"),this.requiredContent=d+"("+this.cssClassName+")"}else this.requiredContent=d+"{text-align}";this.allowedContent={"caption div h1 h2 h3 h4 h5 h6 p pre td th li":{propertiesOnly:!0,styles:this.cssClassName?null:"text-align",classes:this.cssClassName||null}},a.config.enterMode==CKEDITOR.ENTER_BR&&(this.allowedContent.div=!0)}function c(a){var b=a.editor,c=b.createRange();c.setStartBefore(a.data.node),c.setEndAfter(a.data.node);for(var e,d=new CKEDITOR.dom.walker(c);e=d.next();)if(e.type==CKEDITOR.NODE_ELEMENT)if(!e.equals(a.data.node)&&e.getDirection())c.setStartAfter(e),d=new CKEDITOR.dom.walker(c);else{var f=b.config.justifyClasses;f&&(e.hasClass(f[0])?(e.removeClass(f[0]),e.addClass(f[2])):e.hasClass(f[2])&&(e.removeClass(f[2]),e.addClass(f[0]))),f=e.getStyle("text-align"),"left"==f?e.setStyle("text-align","right"):"right"==f&&e.setStyle("text-align","left")}}b.prototype={exec:function(b){var c=b.getSelection(),d=b.config.enterMode;if(c){for(var h,i,e=c.createBookmarks(),f=c.getRanges(),g=this.cssClassName,j=b.config.useComputedState,j=void 0===j||j,k=f.length-1;0<=k;k--)for(h=f[k].createIterator(),h.enlargeBr=d!=CKEDITOR.ENTER_BR;i=h.getNextParagraph(d==CKEDITOR.ENTER_P?"p":"div");)if(!i.isReadOnly()){i.removeAttribute("align"),i.removeStyle("text-align");var l=g&&(i.$.className=CKEDITOR.tools.ltrim(i.$.className.replace(this.cssClassRegex,""))),m=this.state==CKEDITOR.TRISTATE_OFF&&(!j||a(i,!0)!=this.value);g?m?i.addClass(g):l||i.removeAttribute("class"):m&&i.setStyle("text-align",this.value)}b.focus(),b.forceNextSelectionCheck(),c.selectBookmarks(e)}},refresh:function(b,c){var d=c.block||c.blockLimit;this.setState("body"!=d.getName()&&a(d,this.editor.config.useComputedState)==this.value?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF)}}
14,CKEDITOR.plugins.add("justify",{init:function(a){if(!a.blockless){var d=new b(a,"justifyleft","left"),e=new b(a,"justifycenter","center"),f=new b(a,"justifyright","right"),g=new b(a,"justifyblock","justify");a.addCommand("justifyleft",d),a.addCommand("justifycenter",e),a.addCommand("justifyright",f),a.addCommand("justifyblock",g),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",c)}}})}(),CKEDITOR.plugins.add("menubutton",{requires:"button,menu",onLoad:function(){var a=function(a){var b=this._,c=b.menu;b.state!==CKEDITOR.TRISTATE_DISABLED&&(b.on&&c?c.hide():(b.previousState=b.state,c||(c=b.menu=new CKEDITOR.menu(a,{panel:{className:"cke_menu_panel",attributes:{"aria-label":a.lang.common.options}}}),c.onHide=CKEDITOR.tools.bind(function(){var c=this.command?a.getCommand(this.command).modes:this.modes;this.setState(!c||c[a.mode]?b.previousState:CKEDITOR.TRISTATE_DISABLED),b.on=0},this),this.onMenu&&c.addListener(this.onMenu)),this.setState(CKEDITOR.TRISTATE_ON),b.on=1,setTimeout(function(){c.show(CKEDITOR.document.getById(b.id),4)},0)))};CKEDITOR.ui.menuButton=CKEDITOR.tools.createClass({base:CKEDITOR.ui.button,$:function(b){delete b.panel,this.base(b),this.hasArrow=!0,this.click=a},statics:{handler:{create:function(a){return new CKEDITOR.ui.menuButton(a)}}}})},beforeInit:function(a){a.ui.addHandler(CKEDITOR.UI_MENUBUTTON,CKEDITOR.ui.menuButton.handler)}}),CKEDITOR.UI_MENUBUTTON="menubutton",function(){CKEDITOR.plugins.add("language",{requires:"menubutton",init:function(a){var f,g,h,i,b=a.config.language_list||["ar:Arabic:rtl","fr:French","es:Spanish"],c=this,d=a.lang.language,e={};for(a.addCommand("language",{allowedContent:"span[!lang,!dir]",requiredContent:"span[lang,dir]",contextSensitive:!0,exec:function(a,b){var c=e["language_"+b];c&&a[c.style.checkActive(a.elementPath(),a)?"removeStyle":"applyStyle"](c.style)},refresh:function(a){this.setState(c.getCurrentLangElement(a)?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF)}}),i=0;i<b.length;i++)f=b[i].split(":"),g=f[0],h="language_"+g,e[h]={label:f[1],langId:g,group:"language",order:i,ltr:"rtl"!=(""+f[2]).toLowerCase(),onClick:function(){a.execCommand("language",this.langId)},role:"menuitemcheckbox"},e[h].style=new CKEDITOR.style({element:"span",attributes:{lang:g,dir:e[h].ltr?"ltr":"rtl"}});e.language_remove={label:d.remove,group:"language_remove",state:CKEDITOR.TRISTATE_DISABLED,order:e.length,onClick:function(){var b=c.getCurrentLangElement(a);b&&a.execCommand("language",b.getAttribute("lang"))}},a.addMenuGroup("language",1),a.addMenuGroup("language_remove"),a.addMenuItems(e),a.ui.add("Language",CKEDITOR.UI_MENUBUTTON,{label:d.button,allowedContent:"span[!lang,!dir]",requiredContent:"span[lang,dir]",toolbar:"bidi,30",command:"language",onMenu:function(){var f,b={},d=c.getCurrentLangElement(a);for(f in e)b[f]=CKEDITOR.TRISTATE_OFF;return b.language_remove=d?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,d&&(b["language_"+d.getAttribute("lang")]=CKEDITOR.TRISTATE_ON),b}})},getCurrentLangElement:function(a){var b=a.elementPath();a=b&&b.elements;var c;if(b)for(var d=0;d<a.length;d++)b=a[d],!c&&"span"==b.getName()&&b.hasAttribute("dir")&&b.hasAttribute("lang")&&(c=b);return c}})}(),function(){function a(a){return a.replace(/'/g,"\\$&")}function b(a){for(var b,c=a.length,d=[],e=0;e<c;e++)b=a.charCodeAt(e),d.push(b);return"String.fromCharCode("+d.join(",")+")"}function c(b,c){var f,g,d=b.plugins.link,e=d.compiledProtectionFunction.params;g=[d.compiledProtectionFunction.name,"("];for(var h=0;h<e.length;h++)d=e[h].toLowerCase(),f=c[d],0<h&&g.push(","),g.push("'",f?a(encodeURIComponent(c[d])):"","'");return g.push(")"),g.join("")}function d(a){a=a.config.emailProtection||"";var b;return a&&"encode"!=a&&(b={},a.replace(/^([^(]+)\(([^)]+)\)$/,function(a,c,d){b.name=c,b.params=[],d.replace(/[^,\s]+/g,function(a){b.params.push(a)})})),b}CKEDITOR.plugins.add("link",{requires:"dialog,fakeobjects",onLoad:function(){function a(a){return c.replace(/%1/g,"rtl"==a?"right":"left").replace(/%2/g,"cke_contents_"+a)}var b="background:url("+CKEDITOR.getUrl(this.path+"images"+(CKEDITOR.env.hidpi?"/
14hidpi":"")+"/anchor.png")+") no-repeat %1 center;border:1px dotted #00f;background-size:16px;",c=".%2 a.cke_anchor,.%2 a.cke_anchor_empty,.cke_editable.%2 a[name],.cke_editable.%2 a[data-cke-saved-name]{"+b+"padding-%1:18px;cursor:auto;}.%2 img.cke_anchor{"+b+"width:16px;min-height:15px;height:1.15em;vertical-align:text-bottom;}";CKEDITOR.addCss(a("ltr")+a("rtl"))},init:function(a){var b="a[!href]";CKEDITOR.dialog.isTabEnabled(a,"link","advanced")&&(b=b.replace("]",",accesskey,charset,dir,id,lang,name,rel,tabindex,title,type]{*}(*)")),CKEDITOR.dialog.isTabEnabled(a,"link","target")&&(b=b.replace("]",",target,onclick]")),a.addCommand("link",new CKEDITOR.dialogCommand("link",{allowedContent:b,requiredContent:"a[href]"})),a.addCommand("anchor",new CKEDITOR.dialogCommand("anchor",{allowedContent:"a[!name,id]",requiredContent:"a[name]"})),a.addCommand("unlink",new CKEDITOR.unlinkCommand),a.addCommand("removeAnchor",new CKEDITOR.removeAnchorCommand),a.setKeystroke(CKEDITOR.CTRL+76,"link"),a.ui.addButton&&(a.ui.addButton("Link",{label:a.lang.link.toolbar,command:"link",toolbar:"links,10"}),a.ui.addButton("Unlink",{label:a.lang.link.unlink,command:"unlink",toolbar:"links,20"}),a.ui.addButton("Anchor",{label:a.lang.link.anchor.toolbar,command:"anchor",toolbar:"links,30"})),CKEDITOR.dialog.add("link",this.path+"dialogs/link.js"),CKEDITOR.dialog.add("anchor",this.path+"dialogs/anchor.js"),a.on("doubleclick",function(b){var c=CKEDITOR.plugins.link.getSelectedLink(a)||b.data.element;c.isReadOnly()||(c.is("a")?(b.data.dialog=!c.getAttribute("name")||c.getAttribute("href")&&c.getChildCount()?"link":"anchor",b.data.link=c):CKEDITOR.plugins.link.tryRestoreFakeAnchor(a,c)&&(b.data.dialog="anchor"))},null,null,0),a.on("doubleclick",function(b){b.data.dialog in{link:1,anchor:1}&&b.data.link&&a.getSelection().selectElement(b.data.link)},null,null,20),a.addMenuItems&&a.addMenuItems({anchor:{label:a.lang.link.anchor.menu,command:"anchor",group:"anchor",order:1},removeAnchor:{label:a.lang.link.anchor.remove,command:"removeAnchor",group:"anchor",order:5},link:{label:a.lang.link.menu,command:"link",group:"link",order:1},unlink:{label:a.lang.link.unlink,command:"unlink",group:"link",order:5}}),a.contextMenu&&a.contextMenu.addListener(function(b){if(!b||b.isReadOnly())return null;if(b=CKEDITOR.plugins.link.tryRestoreFakeAnchor(a,b),!b&&!(b=CKEDITOR.plugins.link.getSelectedLink(a)))return null;var c={};return b.getAttribute("href")&&b.getChildCount()&&(c={link:CKEDITOR.TRISTATE_OFF,unlink:CKEDITOR.TRISTATE_OFF}),b&&b.hasAttribute("name")&&(c.anchor=c.removeAnchor=CKEDITOR.TRISTATE_OFF),c}),this.compiledProtectionFunction=d(a)},afterInit:function(a){a.dataProcessor.dataFilter.addRules({elements:{a:function(b){return b.attributes.name?b.children.length?null:a.createFakeParserElement(b,"cke_anchor","anchor"):null}}});var b=a._.elementsPath&&a._.elementsPath.filters;b&&b.push(function(b,c){if("a"==c&&(CKEDITOR.plugins.link.tryRestoreFakeAnchor(a,b)||b.getAttribute("name")&&(!b.getAttribute("href")||!b.getChildCount())))return"anchor"})}});var e=/^javascript:/,f=/^mailto:([^?]+)(?:\?(.+))?$/,g=/subject=([^;?:@&=$,\/]*)/i,h=/body=([^;?:@&=$,\/]*)/i,i=/^#(.*)$/,j=/^((?:http|https|ftp|news):\/\/)?(.*)$/,k=/^(_(?:self|top|parent|blank))$/,l=/^javascript:void\(location\.href='mailto:'\+String\.fromCharCode\(([^)]+)\)(?:\+'(.*)')?\)$/,m=/^javascript:([^(]+)\(([^)]+)\)$/,n=/\s*window.open\(\s*this\.href\s*,\s*(?:'([^']*)'|null)\s*,\s*'([^']*)'\s*\)\s*;\s*return\s*false;*\s*/,o=/(?:^|,)([^=]+)=(\d+|yes|no)/gi,p={id:"advId",dir:"advLangDir",accessKey:"advAccessKey",name:"advName",lang:"advLangCode",tabindex:"advTabIndex",title:"advTitle",type:"advContentType",class:"advCSSClasses",charset:"advCharset",style:"advStyles",rel:"advRel"};CKEDITOR.plugins.link={getSelectedLink:function(a){var b=a.getSelection(),c=b.getSelectedElement();return c&&c.is("a")?c:(b=b.getRanges()[0])?(b.shrink(CKEDITOR.SHRINK_TEXT),a.elementPath(b.getCommonAncestor()).contains("a",1)):null},getEditorAnchors:function(a){for(var f,b=a.editable(),c=b.isInline()&&!a.plugins.divarea?a.document:b,b=c.getElementsByTag("a"),c=c.getElementsByTag("img"),d=[],e=0;f=b.getItem(e++);)(f.data("cke-saved-name")||f.hasAttribute("name"))&&d.push({name:f.data("cke-saved-name")||f.getAttribute("name"),id:f.getAttribute("id")});for(e=0;f=c.getItem(e++);)(f=this.tryRestoreFakeAnchor(a,f))&&d.push({name:f.getAttribute("name"),id:f.getAttribute("id")});return d},fakeAnchor:!0,tryRestoreFakeAnchor:function(a,b){if(b&&b.data("cke-real-element-type")&&"anchor"==b.data("cke-real-element-type")){var c=a.restoreRealElement(b);if(c.data("cke-saved-name"))return c}},parseLinkAttributes:function(a,b){var r,c=b&&(b.data("cke-saved-href")||b.getAttribute("href"))||"",d=a.plugins.link.compiledProtectionFunction,q=a.config.emailProtection,s={};if(c.match(e)&&("encode"==q?c=c.replace(l,function(a,b,c){return c=c||"","mailto:"+String.fromCharCode.apply(String,b.split(","))+c.replace(/\\'/g,"'")}):q&&c.replace(m,function(a,b,c){if(b==d.name){s.type="email",a=s.email={},b=/(^')|('$)/g,c=c.match(/[^,\s]+/g);for(var f,g,e=c.length,h=0;h<e;h++)f=decodeURIComponent,g=c[h].replace(b,"").replace(/\\'/g,"'"),g=f(g),f=d.params[h].toLowerCase(),a[f]=g;a.address=[a.name,a.domain].join("@")}}
14)),!s.type)if(q=c.match(i))s.type="anchor",s.anchor={},s.anchor.name=s.anchor.id=q[1];else if(q=c.match(f)){r=c.match(g),c=c.match(h),s.type="email";var t=s.email={};t.address=q[1],r&&(t.subject=decodeURIComponent(r[1])),c&&(t.body=decodeURIComponent(c[1]))}else c&&(r=c.match(j))&&(s.type="url",s.url={},s.url.protocol=r[1],s.url.url=r[2]);if(b){if(c=b.getAttribute("target"))s.target={type:c.match(k)?c:"frame",name:c};else if(c=(c=b.data("cke-pa-onclick")||b.getAttribute("onclick"))&&c.match(n))for(s.target={type:"popup",name:c[1]};q=o.exec(c[2]);)"yes"!=q[2]&&"1"!=q[2]||q[1]in{height:1,width:1,top:1,left:1}?isFinite(q[2])&&(s.target[q[1]]=q[2]):s.target[q[1]]=!0;var u,c={};for(u in p)(q=b.getAttribute(u))&&(c[p[u]]=q);(u=b.data("cke-saved-name")||c.advName)&&(c.advName=u),CKEDITOR.tools.isEmpty(c)||(s.advanced=c)}return s},getLinkAttributes:function(d,e){var f=d.config.emailProtection||"",g={};switch(e.type){case"url":var f=e.url&&void 0!==e.url.protocol?e.url.protocol:"http://",h=e.url&&CKEDITOR.tools.trim(e.url.url)||"";g["data-cke-saved-href"]=0===h.indexOf("/")?h:f+h;break;case"anchor":f=e.anchor&&e.anchor.id,g["data-cke-saved-href"]="#"+(e.anchor&&e.anchor.name||f||"");break;case"email":var i=e.email,h=i.address;switch(f){case"":case"encode":var j=encodeURIComponent(i.subject||""),k=encodeURIComponent(i.body||""),i=[];j&&i.push("subject="+j),k&&i.push("body="+k),i=i.length?"?"+i.join("&"):"","encode"==f?(f=["javascript:void(location.href='mailto:'+",b(h)],i&&f.push("+'",a(i),"'"),f.push(")")):f=["mailto:",h,i];break;default:f=h.split("@",2),i.name=f[0],i.domain=f[1],f=["javascript:",c(d,i)]}g["data-cke-saved-href"]=f.join("")}if(e.target)if("popup"==e.target.type){for(var f=["window.open(this.href, '",e.target.name||"","', '"],l="resizable status location toolbar menubar fullscreen scrollbars dependent".split(" "),h=l.length,j=function(a){e.target[a]&&l.push(a+"="+e.target[a])},i=0;i<h;i++)l[i]+=e.target[l[i]]?"=yes":"=no";j("width"),j("left"),j("height"),j("top"),f.push(l.join(","),"'); return false;"),g["data-cke-pa-onclick"]=f.join("")}else"notSet"!=e.target.type&&e.target.name&&(g.target=e.target.name);if(e.advanced){for(var m in p)(f=e.advanced[p[m]])&&(g[m]=f);g.name&&(g["data-cke-saved-name"]=g.name)}g["data-cke-saved-href"]&&(g.href=g["data-cke-saved-href"]), 15m={target:1,onclick:1,"data-cke-pa-onclick":1,"data-cke-saved-name":1},e.advanced&&CKEDITOR.tools.extend(m,p);for(var n in g)delete m[n];return{set:g,removed:CKEDITOR.tools.objectKeys(m)}}},CKEDITOR.unlinkCommand=function(){},CKEDITOR.unlinkCommand.prototype={exec:function(a){var b=new CKEDITOR.style({element:"a",type:CKEDITOR.STYLE_INLINE,alwaysRemoveElement:1});a.removeStyle(b)},refresh:function(a,b){var c=b.lastElement&&b.lastElement.getAscendant("a",!0);c&&"a"==c.getName()&&c.getAttribute("href")&&c.getChildCount()?this.setState(CKEDITOR.TRISTATE_OFF):this.setState(CKEDITOR.TRISTATE_DISABLED)},contextSensitive:1,startDisabled:1,requiredContent:"a[href]"},CKEDITOR.removeAnchorCommand=function(){},CKEDITOR.removeAnchorCommand.prototype={exec:function(a){var d,b=a.getSelection(),c=b.createBookmarks();b&&(d=b.getSelectedElement())&&(d.getChildCount()?d.is("a"):CKEDITOR.plugins.link.tryRestoreFakeAnchor(a,d))?d.remove(1):(d=CKEDITOR.plugins.link.getSelectedLink(a))&&(d.hasAttribute("href")?(d.removeAttributes({name:1,"data-cke-saved-name":1}),d.removeClass("cke_anchor")):d.remove(1)),b.selectBookmarks(c)},requiredContent:"a[name]"},CKEDITOR.tools.extend(CKEDITOR.config,{linkShowAdvancedTab:!0,linkShowTargetTab:!0})}(),function(){function a(a,b,c){function d(c){!(j=i[c?"getFirst":"getLast"]())||j.is&&j.isBlockBoundary()||!(k=b.root[c?"getPrevious":"getNext"](CKEDITOR.dom.walker.invisible(!0)))||k.is&&k.isBlockBoundary({br:1})||a.document.createElement("br")[c?"insertBefore":"insertAfter"](j)}for(var e=CKEDITOR.plugins.list.listToArray(b.root,c),f=[],g=0;g<b.contents.length;g++){var h=b.contents[g];(h=h.getAscendant("li",!0))&&!h.getCustomData("list_item_processed")&&(f.push(h),CKEDITOR.dom.element.setMarker(c,h,"list_item_processed",!0))}for(h=null,g=0;g<f.length;g++)h=f[g].getCustomData("listarray_index"),e[h].indent=-1;for(g=h+1;g<e.length;g++)if(e[g].indent>e[g-1].indent+1){for(f=e[g-1].indent+1-e[g].indent,h=e[g].indent;e[g]&&e[g].indent>=h;)e[g].indent+=f,g++;g--}var j,k,i=CKEDITOR.plugins.list.arrayToList(e,c,null,a.config.enterMode,b.root.getAttribute("dir")).listNode;d(!0),d(),i.replace(b.root),a.fire("contentDomInvalidated")}function b(a,b){this.name=a,this.context=this.type=b,this.allowedContent=b+" li",this.requiredContent=b}function c(a,b,c,d){for(var e,f;e=a[d?"getLast":"getFirst"](n);)(f=e.getDirection(1))!==b.getDirection(1)&&e.setAttribute("dir",f),e.remove(),c?e[d?"insertBefore":"insertAfter"](c):b.a
15ppend(e,d)}function d(a){function b(b){var d=a[b?"getPrevious":"getNext"](k);d&&d.type==CKEDITOR.NODE_ELEMENT&&d.is(a.getName())&&(c(a,d,null,!b),a.remove(),a=d)}b(),b(1)}function e(a){return a.type==CKEDITOR.NODE_ELEMENT&&(a.getName()in CKEDITOR.dtd.$block||a.getName()in CKEDITOR.dtd.$listItem)&&CKEDITOR.dtd[a.getName()]["#"]}function f(a,b,e){a.fire("saveSnapshot"),e.enlarge(CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS);var f=e.extractContents();b.trim(!1,!0);var h=b.createBookmark(),i=new CKEDITOR.dom.elementPath(b.startContainer),j=i.block,i=i.lastElement.getAscendant("li",1)||j,m=new CKEDITOR.dom.elementPath(e.startContainer),n=m.contains(CKEDITOR.dtd.$listItem),m=m.contains(CKEDITOR.dtd.$list);for(j?(j=j.getBogus())&&j.remove():m&&(j=m.getPrevious(k))&&l(j)&&j.remove(),(j=f.getLast())&&j.type==CKEDITOR.NODE_ELEMENT&&j.is("br")&&j.remove(),(j=b.startContainer.getChild(b.startOffset))?f.insertBefore(j):b.startContainer.append(f),n&&(f=g(n))&&(i.contains(n)?(c(f,n.getParent(),n),f.remove()):i.append(f));e.checkStartOfBlock()&&e.checkEndOfBlock()&&(m=e.startPath(),f=m.block,f);)f.is("li")&&(i=f.getParent(),f.equals(i.getLast(k))&&f.equals(i.getFirst(k))&&(f=i)),e.moveToPosition(f,CKEDITOR.POSITION_BEFORE_START),f.remove();e=e.clone(),f=a.editable(),e.setEndAt(f,CKEDITOR.POSITION_BEFORE_END),e=new CKEDITOR.dom.walker(e),e.evaluator=function(a){return k(a)&&!l(a)},(e=e.next())&&e.type==CKEDITOR.NODE_ELEMENT&&e.getName()in CKEDITOR.dtd.$list&&d(e),b.moveToBookmark(h),b.select(),a.fire("saveSnapshot")}function g(a){return(a=a.getLast(k))&&a.type==CKEDITOR.NODE_ELEMENT&&a.getName()in h?a:null}var h={ol:1,ul:1},i=CKEDITOR.dom.walker.whitespaces(),j=CKEDITOR.dom.walker.bookmark(),k=function(a){return!(i(a)||j(a))},l=CKEDITOR.dom.walker.bogus();CKEDITOR.plugins.list={listToArray:function(a,b,c,d,e){if(!h[a.getName()])return[];d||(d=0),c||(c=[]);for(var f=0,g=a.getChildCount();f<g;f++){var i=a.getChild(f);if(i.type==CKEDITOR.NODE_ELEMENT&&i.getName()in CKEDITOR.dtd.$list&&CKEDITOR.plugins.list.listToArray(i,b,c,d+1),"li"==i.$.nodeName.toLowerCase()){var j={parent:a,indent:d,element:i,contents:[]};e?j.grandparent=e:(j.grandparent=a.getParent(),j.grandparent&&"li"==j.grandparent.$.nodeName.toLowerCase()&&(j.grandparent=j.grandparent.getParent())),b&&CKEDITOR.dom.element.setMarker(b,i,"listarray_index",c.length),c.push(j);for(var m,k=0,l=i.getChildCount();k<l;k++)m=i.getChild(k),m.type==CKEDITOR.NODE_ELEMENT&&h[m.getName()]?CKEDITOR.plugins.list.listToArray(m,b,c,d+1,j.grandparent):j.contents.push(m)}}return c},arrayToList:function(a,b,c,d,e){if(c||(c=0),!a||a.length<c+1)return null;for(var f,p,q,g=a[c].parent.getDocument(),i=new CKEDITOR.dom.documentFragment(g),l=null,m=c,n=Math.max(a[c].indent,0),o=null,r=d==CKEDITOR.ENTER_P?"p":"div";;){var s=a[m];if(f=s.grandparent,p=s.element.getDirection(1),s.indent==n){for(l&&a[m].parent.getName()==l.getName()||(l=a[m].parent.clone(!1,1),e&&l.setAttribute("dir",e),i.append(l)),o=l.append(s.element.clone(0,1)),p!=l.getDirection(1)&&o.setAttribute("dir",p),f=0;f<s.contents.length;f++)o.append(s.contents[f].clone(1,1));m++}else if(s.indent==Math.max(n,0)+1)s=a[m-1].element.getDirection(1),m=CKEDITOR.plugins.list.arrayToList(a,null,m,d,s!=p?p:null),!o.getChildCount()&&CKEDITOR.env.needsNbspFiller&&7>=g.$.documentMode&&o.append(g.createText("Â ")),o.append(m.listNode),m=m.nextIndex;else{if(-1!=s.indent||c||!f)return null;h[f.getName()]?(o=s.element.clone(!1,!0),p!=f.getDirection(1)&&o.setAttribute("dir",p)):o=new CKEDITOR.dom.documentFragment(g);var x,z,l=f.getDirection(1)!=p,t=s.element,u=t.getAttribute("class"),v=t.getAttribute("style"),w=o.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT&&(d!=CKEDITOR.ENTER_BR||l||v||u),y=s.contents.length;for(f=0;f<y;f++)if(x=s.contents[f],j(x)&&1<y)w?z=x.clone(1,1):o.append(x.clone(1,1));else if(x.type==CKEDITOR.NODE_ELEMENT&&x.isBlockBoundary()){l&&!x.getDirection()&&x.setAttribute("dir",p),q=x;var A=t.getAttribute("style");A&&q.setAttribute("style",A.replace(/([^;])$/,"$1;")+(q.getAttribute("style")||"")),u&&x.addClass(u),q=null,z&&(o.append(z),z=null),o.append(x.clone(1,1))}else w?(q||(q=g.createElement(r),o.append(q),l&&q.setAttribute("dir",p)),v&&q.setAttribute("style",v),u&&q.setAttribute("class",u),z&&(q.append(z),z=null),q.append(x.clone(1,1))):o.append(x.clone(1,1));z&&((q||o).append(z),z=null),o.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT&&m!=a.length-1&&(CKEDITOR.env.needsBrFiller&&(p=o.getLast())&&p.type==CKEDITOR.NODE_ELEMENT&&p.is("br")&&p.remove(),(p=o.getLast(k))&&p.type==CKEDITOR.NODE_ELEMENT&&p.is(CKEDITOR.dtd.$block)||o.append(g.createElement("br"))),p=o.$.nodeName.toLowerCase(),"div"!=p&&"p"!=p||o.appendBogus(),i.append(o),l=null,m++}if(q=null,a.length<=m||Math.max(a[m].indent,0)<n)break}if(b)for(a=i.getFirst();a;){if(a.type==CKEDITOR.NODE_ELEMENT&&(CKEDITOR.dom.element.clearMarkers(b,a),a.getName()in CKEDITOR.dtd.$listItem&&(c=a,g=e=d=void 0,d=c.getDirection()))){for(e=c.getParent();e&&!(g=e.getDirection());)e=e.getParent();d==g&&c.removeAttribute("dir")}
15a=a.getNextSourceNode()}return{listNode:i,nextIndex:m}}};var m=/^h[1-6]$/,n=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_ELEMENT);b.prototype={exec:function(b){this.refresh(b,b.elementPath());var c=b.config,e=b.getSelection(),f=e&&e.getRanges();if(this.state==CKEDITOR.TRISTATE_OFF){var g=b.editable();if(g.getFirst(k)){var i=1==f.length&&f[0];(c=i&&i.getEnclosedNode())&&c.is&&this.type==c.getName()&&this.setState(CKEDITOR.TRISTATE_ON)}else c.enterMode==CKEDITOR.ENTER_BR?g.appendBogus():f[0].fixBlock(1,c.enterMode==CKEDITOR.ENTER_P?"p":"div"),e.selectRanges(f)}for(var c=e.createBookmarks(!0),g=[],j={},f=f.createIterator(),l=0;(i=f.getNextRange())&&++l;){var n=i.getBoundaryNodes(),o=n.startNode,p=n.endNode;for(o.type==CKEDITOR.NODE_ELEMENT&&"td"==o.getName()&&i.setStartAt(n.startNode,CKEDITOR.POSITION_AFTER_START),p.type==CKEDITOR.NODE_ELEMENT&&"td"==p.getName()&&i.setEndAt(n.endNode,CKEDITOR.POSITION_BEFORE_END),i=i.createIterator(),i.forceBrBreak=this.state==CKEDITOR.TRISTATE_OFF;n=i.getNextParagraph();)if(!n.getCustomData("list_block")){CKEDITOR.dom.element.setMarker(j,n,"list_block",1);for(var r,q=b.elementPath(n),o=q.elements,p=0,q=q.blockLimit,s=o.length-1;0<=s&&(r=o[s]);s--)if(h[r.getName()]&&q.contains(r)){q.removeCustomData("list_group_object_"+l),(o=r.getCustomData("list_group_object"))?o.contents.push(n):(o={root:r,contents:[n]},g.push(o),CKEDITOR.dom.element.setMarker(j,r,"list_group_object",o)),p=1;break}p||(p=q,p.getCustomData("list_group_object_"+l)?p.getCustomData("list_group_object_"+l).contents.push(n):(o={root:p,contents:[n]},CKEDITOR.dom.element.setMarker(j,p,"list_group_object_"+l,o),g.push(o)))}}for(r=[];0<g.length;)if(o=g.shift(),this.state==CKEDITOR.TRISTATE_OFF)if(h[o.root.getName()]){for(f=b,l=o,o=j,i=r,p=CKEDITOR.plugins.list.listToArray(l.root,o),q=[],n=0;n<l.contents.length;n++)s=l.contents[n],(s=s.getAscendant("li",!0))&&!s.getCustomData("list_item_processed")&&(q.push(s),CKEDITOR.dom.element.setMarker(o,s,"list_item_processed",!0));for(var s=l.root.getDocument(),t=void 0,u=void 0,n=0;n<q.length;n++){var v=q[n].getCustomData("listarray_index"),t=p[v].parent;t.is(this.type)||(u=s.createElement(this.type),t.copyAttributes(u,{start:1,type:1}),u.removeStyle("list-style-type"),p[v].parent=u)}for(o=CKEDITOR.plugins.list.arrayToList(p,o,null,f.config.enterMode),p=void 0,q=o.listNode.getChildCount(),n=0;n<q&&(p=o.listNode.getChild(n));n++)p.getName()==this.type&&i.push(p);o.listNode.replace(l.root),f.fire("contentDomInvalidated")}else{for(p=b,i=o,n=r,q=i.contents,f=i.root.getDocument(),l=[],1==q.length&&q[0].equals(i.root)&&(o=f.createElement("div"),q[0].moveChildren&&q[0].moveChildren(o),q[0].append(o),q[0]=o),i=i.contents[0].getParent(),s=0;s<q.length;s++)i=i.getCommonAncestor(q[s].getParent());for(t=p.config.useComputedState,p=o=void 0,t=void 0===t||t,s=0;s<q.length;s++)for(u=q[s];v=u.getParent();){if(v.equals(i)){l.push(u),!p&&u.getDirection()&&(p=1),u=u.getDirection(t),null!==o&&(o=o&&o!=u?null:u);break}u=v}if(!(1>l.length)){for(q=l[l.length-1].getNext(),s=f.createElement(this.type),n.push(s),t=n=void 0;l.length;)n=l.shift(),t=f.createElement("li"),u=n,u.is("pre")||m.test(u.getName())||"false"==u.getAttribute("contenteditable")?n.appendTo(t):(n.copyAttributes(t),o&&n.getDirection()&&(t.removeStyle("direction"),t.removeAttribute("dir")),n.moveChildren(t),n.remove()),t.appendTo(s);o&&p&&s.setAttribute("dir",o),q?s.insertBefore(q):s.appendTo(i)}}else this.state==CKEDITOR.TRISTATE_ON&&h[o.root.getName()]&&a.call(this,b,o,j);for(s=0;s<r.length;s++)d(r[s]);CKEDITOR.dom.element.clearAllMarkers(j),e.selectBookmarks(c),b.focus()},refresh:function(a,b){var c=b.contains(h,1),d=b.blockLimit||b.root;c&&d.contains(c)?this.setState(c.is(this.type)?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF):this.setState(CKEDITOR.TRISTATE_OFF)}},CKEDITOR.plugins.add("list",{requires:"indentlist",init:function(a){a.blockless||(a.addCommand("numberedlist",new b("numberedlist","ol")),a.addCommand("bulletedlist",new b("bulletedlist","ul")),a.ui.addButton&&(a.ui.addButton("NumberedList",{label:a.lang.list.numberedlist,command:"numberedlist",directional:!0,toolbar:"list,10"}),a.ui.addButton("BulletedList",{label:a.lang.list.bulletedlist,command:"bulletedlist",directional:!0,toolbar:"list,20"})),a.on("key",function(b){var d,c=b.data.domEvent.getKey();if("wysiwyg"==a.mode&&c in{8:1,46:1}){var i=a.getSelection().getRanges()[0],j=i&&i.startPath();if(i&&i.collapsed){var m=8==c,n=a.editable(),o=new CKEDITOR.dom.walker(i.clone());if(o.evaluator=function(a){return k(a)&&!l(a)},o.guard=function(a,b){return!(b&&a.type==CKEDITOR.NODE_ELEMENT&&a.is("table"))},c=i.clone(),m){var p;if((p=j.contains(h))&&i.checkBoundaryOfElement(p,CKEDITOR.START)&&(p=p.getParent())&&p.is("li")&&(p=g(p))?(d=p,p=p.getPrevious(k),c.moveToPosition(p&&l(p)?p:d,CKEDITOR.POSITION_BEFORE_START)):(o.range.setStartAt(n,CKEDITOR.POSITION_AFTER_START),o.range.setEnd(i.startContainer,i.startOffset),(p=o.previous())&&p.type==CKEDITOR.NODE_ELEMENT&&(p.getName()in h||p.is("li"))&&(p.is("li")||(o.range.selectNodeContents(p),o.reset(),o.evaluator=e,p=o.previous()),d=p,c.moveToElementEditEnd(d),c.moveToPosition(c.endPath().block,CKEDITOR.POSITION_BEFORE_END))),d)f(a,c,i),b.cancel();else{var q=j.contains(h);q&&i.checkBoundaryOfElement(q,CKEDITOR.START)&&(d=q.getFirst(k),i.checkBoundaryOfElement(d,CKEDITOR.START)&&(p=q.getPrevious(k),g(d)?p&&(i.moveToElementEditEnd(p),i.select()):a.execCommand("outde
15nt"),b.cancel()))}}else if(d=j.contains("li")){if(o.range.setEndAt(n,CKEDITOR.POSITION_BEFORE_END),m=(n=d.getLast(k))&&e(n)?n:d,j=0,(p=o.next())&&p.type==CKEDITOR.NODE_ELEMENT&&p.getName()in h&&p.equals(n)?(j=1,p=o.next()):i.checkBoundaryOfElement(m,CKEDITOR.END)&&(j=2),j&&p){if(i=i.clone(),i.moveToElementEditStart(p),1==j&&(c.optimize(),!c.startContainer.equals(d))){for(d=c.startContainer;d.is(CKEDITOR.dtd.$inline);)q=d,d=d.getParent();q&&c.moveToPosition(q,CKEDITOR.POSITION_AFTER_END)}2==j&&(c.moveToPosition(c.endPath().block,CKEDITOR.POSITION_BEFORE_END),i.endPath().block&&i.moveToPosition(i.endPath().block,CKEDITOR.POSITION_AFTER_START)),f(a,c,i),b.cancel()}}else o.range.setEndAt(n,CKEDITOR.POSITION_BEFORE_END),(p=o.next())&&p.type==CKEDITOR.NODE_ELEMENT&&p.is(h)&&(p=p.getFirst(k),j.block&&i.checkStartOfBlock()&&i.checkEndOfBlock()?(j.block.remove(),i.moveToElementEditStart(p),i.select()):g(p)?(i.moveToElementEditStart(p),i.select()):(i=i.clone(),i.moveToElementEditStart(p),f(a,c,i)),b.cancel());setTimeout(function(){a.selectionChange(1)})}}}))}})}(),function(){CKEDITOR.plugins.liststyle={requires:"dialog,contextmenu",init:function(a){if(!a.blockless){var b;b=new CKEDITOR.dialogCommand("numberedListStyle",{requiredContent:"ol",allowedContent:"ol{list-style-type}[start]"}),b=a.addCommand("numberedListStyle",b),a.addFeature(b),CKEDITOR.dialog.add("numberedListStyle",this.path+"dialogs/liststyle.js"),b=new CKEDITOR.dialogCommand("bulletedListStyle",{requiredContent:"ul",allowedContent:"ul{list-style-type}"}),b=a.addCommand("bulletedListStyle",b),a.addFeature(b),CKEDITOR.dialog.add("bulletedListStyle",this.path+"dialogs/liststyle.js"),a.addMenuGroup("list",108),a.addMenuItems({numberedlist:{label:a.lang.liststyle.numberedTitle,group:"list",command:"numberedListStyle"},bulletedlist:{label:a.lang.liststyle.bulletedTitle,group:"list",command:"bulletedListStyle"}}),a.contextMenu.addListener(function(a){if(!a||a.isReadOnly())return null;for(;a;){var b=a.getName();if("ol"==b)return{numberedlist:CKEDITOR.TRISTATE_OFF};if("ul"==b)return{bulletedlist:CKEDITOR.TRISTATE_OFF};a=a.getParent()}return null})}}},CKEDITOR.plugins.add("liststyle",CKEDITOR.plugins.liststyle)}(),function(){function a(a,b,c){return l(b)&&l(c)&&c.equals(b.getNext(function(a){return!(W(a)||X(a)||m(a))}))}function b(a){this.upper=a[0],this.lower=a[1],this.set.apply(this,a.slice(2))}function c(a){var b=a.element;if(b&&l(b)&&(b=b.getAscendant(a.triggers,!0))&&a.editable.contains(b)){var c=g(b);if("true"==c.getAttribute("contenteditable"))return b;if(c.is(a.triggers))return c}return null}function d(a,b,c){return u(a,b),u(a,c),a=b.size.bottom,c=c.size.top,a&&c?0|(a+c)/2:a||c}function e(a,b,c){return b=b[c?"getPrevious":"getNext"](function(b){return b&&b.type==CKEDITOR.NODE_TEXT&&!W(b)||l(b)&&!m(b)&&!k(a,b)})}function f(a,b,c){return a>b&&a<c}function g(a,b){if(a.data("cke-editable"))return null;for(b||(a=a.getParent());a&&!a.data("cke-editable");){if(a.hasAttribute("contenteditable"))return a;a=a.getParent()}return null}function h(a){var b=a.doc,c=A('<span contenteditable="false" style="'+S+"position:absolute;border-top:1px dashed "+a.boxColor+'"></span>',b),d=CKEDITOR.getUrl(this.path+"images/"+(B.hidpi?"hidpi/":"")+"icon"+(a.rtl?"-rtl":"")+".png");for(y(c,{attach:function(){return this.wrap.getParent()||this.wrap.appendTo(a.editable,!0),this},lineChildren:[y(A('<span title="'+a.editor.lang.magicline.title+'" contenteditable="false">↵</span>',b),{base:S+"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; border-radius: 2px;","top:-17px; border-radius: 2px 2px 0px 0px;","top:-1px; border-radius: 0px 0px 2px 2px;"]}),y(A(U,b),{base:T+"left:0px;border-left-color:"+a.boxColor+";",looks:["border-width:8px 0 8px 8px;top:-8px","border-width:8px 0 0 8px;top:-8px","border-width:0 0 8px 8px;top:0px"]}),y(A(U,b),{base:T+"right:0px;border-right-color:"+a.boxColor+";",looks:["border-width:8px 8px 8px 0;top:-8px","border-width:8px 8px 0 0;top:-8px","border-width:0 8px 8px 0;top:0px"]})],detach:function(){return this.wrap.getParent()&&this.wrap.remove(),this},mouseNear:function(){u(a,this);var b=a.holdDistance,c=this.size;return!!(c&&f(a.mouse.y,c.top-b,c.bottom+b)&&f(a.mouse.x,c.left-b,c.right+b))},place:function(){var b=a.view,c=a.editable,d=a.trigger,e=d.upper,g=d.lower,h=e||g,i=h.getParent(),j={};this.trigger=d,e&&u(a,e,!0),g&&u(a,g,!0),u(a,i,!0),a.inInlineMode&&v(a,!0),i.equals(c)?(j.left=b.scroll.x,j.right=-b.scroll.x,j.width=""):(j.left=h.size.left-h.size.margin.left+b.scroll.x-(a.inInlineMode?b.editable.left+b.editable.border.left:0),j.width=h.size.outerWidth+h.size.margin.left+h.size.margin.right+b.scroll.x,j.right=""),e&&g?j.top=e.size.margin.bottom===g.size.margin.top?0|e.size.bottom+e.size.margin.bottom/2:e.size.margin.bottom<g.size.margin.top?e.size.bottom+e.size.margin.bottom:e.size.bottom+e.size.margin.bottom-g.size.margin.top:e?g||(j.top=e.size.bottom+e.size.margin.bottom):j.top=g.size.top-g.size.margin.top,d.is(J)||f(j.top,b.scroll.y-15,b.scroll.y+5)?(j.top=a.inInlineMode?0:b.scroll.y,this.look(J)):d.is(K)||f(j.top,b.pane.bottom-5,b.pane.bottom+15)?(j.top=a.inInlineMode?b.editable.height+b.editable.padding.top+b.editable.padding.bottom:b.pane.bottom-1,this.look(K)):(a.inInlineMode&&(j.top-=b.editable.top+b.editable.border.top),this.look(L)),a.inInlineMode&&(j.top--,j.top+=b.editable.scroll.top,j.left+=b.editable.scroll.left);for(var k in j)j[k]=CKEDITOR.tools.cssLength(j[k]);this.setStyles(j)}
15,look:function(a){if(this.oldLook!=a){for(var c,b=this.lineChildren.length;b--;)(c=this.lineChildren[b]).setAttribute("style",c.base+c.looks[0|a/2]);this.oldLook=a}},wrap:new z("span",a.doc)}),b=c.lineChildren.length;b--;)c.lineChildren[b].appendTo(c);c.look(L),c.appendTo(c.wrap),c.unselectable(),c.lineChildren[0].on("mouseup",function(b){c.detach(),i(a,function(b){var c=a.line.trigger;b[c.is(F)?"insertBefore":"insertAfter"](c.is(F)?c.lower:c.upper)},!0),a.editor.focus(),B.ie||a.enterMode==CKEDITOR.ENTER_BR||a.hotNode.scrollIntoView(),b.data.preventDefault(!0)}),c.on("mousedown",function(a){a.data.preventDefault(!0)}),a.line=c}function i(a,b,c){var f,d=new CKEDITOR.dom.range(a.doc),e=a.editor;B.ie&&a.enterMode==CKEDITOR.ENTER_BR?f=a.doc.createText(M):(f=(f=g(a.element,!0))&&f.data("cke-enter-mode")||a.enterMode,f=new z(E[f],a.doc),f.is("br")||a.doc.createText(M).appendTo(f)),c&&e.fire("saveSnapshot"),b(f),d.moveToPosition(f,CKEDITOR.POSITION_AFTER_START),e.getSelection().selectRanges([d]),a.hotNode=f,c&&e.fire("saveSnapshot")}function j(a,b){return{canUndo:!0,modes:{wysiwyg:1},exec:function(){function d(c){var d=B.ie&&9>B.version?" ":M,e=a.hotNode&&a.hotNode.getText()==d&&a.element.equals(a.hotNode)&&a.lastCmdDirection===!!b;i(a,function(d){e&&a.hotNode&&a.hotNode.remove(),d[b?"insertAfter":"insertBefore"](c),d.setAttributes({"data-cke-magicline-hot":1,"data-cke-magicline-dir":!!b}),a.lastCmdDirection=!!b}),B.ie||a.enterMode==CKEDITOR.ENTER_BR||a.hotNode.scrollIntoView(),a.line.detach()}return function(f){f=f.getSelection().getStartElement();var h;if(f=f.getAscendant(Q,1),!p(a,f)&&f&&!f.equals(a.editable)&&!f.contains(a.editable)){(h=g(f))&&"false"==h.getAttribute("contenteditable")&&(f=h),a.element=f,h=e(a,f,!b);var i;l(h)&&h.is(a.triggers)&&h.is(P)&&(!e(a,h,!b)||(i=e(a,h,!b))&&l(i)&&i.is(a.triggers))?d(h):(i=c(a,f),l(i)&&(e(a,i,!b)?(f=e(a,i,!b))&&l(f)&&f.is(a.triggers)&&d(i):d(i)))}}}()}}function k(a,b){if(!b||b.type!=CKEDITOR.NODE_ELEMENT||!b.$)return!1;var c=a.line;return c.wrap.equals(b)||c.wrap.contains(b)}function l(a){return a&&a.type==CKEDITOR.NODE_ELEMENT&&a.$}function m(a){if(!l(a))return!1;var b;return(b=n(a))||(l(a)?(b={left:1,right:1,center:1},b=!(!b[a.getComputedStyle("float")]&&!b[a.getAttribute("align")])):b=!1),b}function n(a){return!!{absolute:1,fixed:1}[a.getComputedStyle("position")]}function o(a,b){return l(b)?b.is(a.triggers):null}function p(a,b){if(!b)return!1;for(var c=b.getParents(1),d=c.length;d--;)for(var e=a.tabuList.length;e--;)if(c[d].hasAttribute(a.tabuList[e]))return!0;return!1}function q(a,b,c){return!!(b=b[c?"getLast":"getFirst"](function(b){return a.isRelevant(b)&&!b.is(O)}))&&(u(a,b),c?b.size.top>a.mouse.y:b.size.bottom<a.mouse.y)}function r(a){var c=a.editable,d=a.mouse,e=a.view,g=a.triggerOffset;v(a);var h=d.y>(a.inInlineMode?e.editable.top+e.editable.height/2:Math.min(e.editable.height,e.pane.height)/2),c=c[h?"getLast":"getFirst"](function(a){return!(W(a)||X(a))});return c?(k(a,c)&&(c=a.line.wrap[h?"getPrevious":"getNext"](function(a){return!(W(a)||X(a))})),l(c)&&!m(c)&&o(a,c)?(u(a,c),!h&&0<=c.size.top&&f(d.y,0,c.size.top+g)?(a=a.inInlineMode||0===e.scroll.y?J:L,new b([null,c,F,I,a])):h&&c.size.bottom<=e.pane.height&&f(d.y,c.size.bottom-g,e.pane.height)?(a=a.inInlineMode||f(c.size.bottom,e.pane.height-g,e.pane.height)?K:L,new b([c,null,G,I,a])):null):null):null}function s(a){var d=a.mouse,g=a.view,h=a.triggerOffset,i=c(a);if(!i)return null;u(a,i);var k,n,h=Math.min(h,0|i.size.outerHeight/2),j=[];if(f(d.y,i.size.top-1,i.size.top+h))n=!1;else{if(!f(d.y,i.size.bottom-h,i.size.bottom+1))return null;n=!0}if(m(i)||q(a,i,n)||i.getParent().is(N))return null;var p=e(a,i,!n);if(p){if(p&&p.type==CKEDITOR.NODE_TEXT)return null;if(l(p)){if(m(p)||!o(a,p)||p.getParent().is(N))return null;j=[p,i][n?"reverse":"concat"]().concat([H,I])}}else i.equals(a.editable[n?"getLast":"getFirst"](a.isRelevant))?(v(a),n&&f(d.y,i.size.bottom-h,g.pane.height)&&f(i.size.bottom,g.pane.height-h,g.pane.height)?k=K:f(d.y,0,i.size.top+h)&&(k=J)):k=L,j=[null,i][n?"reverse":"concat"]().concat([n?G:F,I,k,i.equals(a.editable[n?"getLast":"getFirst"](a.isRelevant))?n?K:J:L]);return 0 in j?new b(j):null}function t(a,b,c,d){for(var e=b.getDocumentPosition(),f={},g={},h={},i={},j=Z.length;j--;)f[Z[j]]=parseInt(b.getComputedStyle.call(b,"border-"+Z[j]+"-width"),10)||0,h[Z[j]]=parseInt(b.getComputedStyle.call(b,"padding-"+Z[j]),10)||0,g[Z[j]]=parseInt(b.getComputedStyle.call(b,"margin-"+Z[j]),10)||0;return c&&!d||w(a,d),i.top=e.y-(c?0:a.view.scroll.y),i.left=e.x-(c?0:a.view.scroll.x),i.outerWidth=b.$.offsetWidth,i.outerHeight=b.$.offsetHeight,i.height=i.outerHeight-(h.top+h.bottom+f.top+f.bottom),i.width=i.outerWidth-(h.left+h.right+f.left+f.right),i.bottom=i.top+i.outerHeight,i.right=i.left+i.outerWidth,a.inInlineMode&&(i.scroll={top:b.$.scrollTop,left:b.$.scrollLeft}),y({border:f,padding:h,margin:g,ignoreScroll:c},i,!0)}function u(a,b,c){if(!l(b))return b.size=null;if(b.size){if(b.size.ignoreScroll==c&&b.size.date>new Date-R)return null}else b.size={};return y(b.size,t(a,b,c),{date:+new Date},!0)}function v(a,b){a.view.editable=t(a,a.editable,b,!0)}function w(a,b){a.view||(a.view={});var c=a.view;if(!(!b&&c&&c.date>new Date-R)){var d=a.win,c=d.getScrollPosition(),d=d.getViewPaneSize();y(a.view,{scroll:{x:c.x,y:c.y,width:a.doc.$.documentElement.scrollWidth-d.width,height:a.doc.$.documentElement.scrollHeight-d.height},pane:{width:d.width,height:d.height,bottom:d.height+c.y},date:+new Date},!0)}}function x(a,c,d,e){for(var f=e,g=e,h=0,i=!1,j=!1,k=a.view.pane.height,l=a.mouse;l.y+h<k&&0<l.y-h&&(i||(i=c(f,e)),j||(j=c(g,e)),!i&&0<l.y-h&&(f=d(a,{x:l.x,y:l.y-h})),!j&&l.y+h<k&&(g=d(a,{x:l.x,y:l.y+h})),!i||!j);)h+=2;return new b([f,g,null,null])}CKEDITOR.plugins.add("magicline",{init:function(a){var o,q,u,d=a.config,f=d.magicline_triggerOffset||30,g={editor:a,enterMode:d.enterMode,triggerOffset:f,holdDistance:0|f*(d.magicline_holdDistance||.5),boxColor:d.magicline_color||"#ff0000",rtl:"rtl"==d.contentsLangDirection,tabuList:["data-cke-hidden-sel"].concat(d.magicline_tabuList||[]),triggers:d.magicline_everywhere?Q:{table:1,hr:1,div:1,ul:1,ol:1,dl:1,form:1,blockquote:1}};g.isRelevant=function(a){return l(a)&&!k(g,a)&&!m(a)},a.on("contentDom",function(){var f=a.editable(),l=a.document,m=a.window;y(g,{editable:f,inInlineMode:f.isInline(),doc:l,win:m,hotNode:null},!0),g.boundary=g.inInlineMode?g.editable:g.doc.getDocumentElement(),f.is(D.$inline)||(g.inInlineMode&&!n(f)&&f.setStyles({position:"relative",top:null,left:null}),h.call(this,g),w(g),f.attachListener(a,"beforeUndoImage",function(){g.line.detach()}),f.attachListener(a,"beforeGetData",function(){g.line.wrap.getParent()&&
15(g.line.detach(),a.once("getData",function(){g.line.attach()},null,null,1e3))},null,null,0),f.attachListener(g.inInlineMode?l:l.getWindow().getFrame(),"mouseout",function(b){if("wysiwyg"==a.mode)if(g.inInlineMode){var c=b.data.$.clientX;b=b.data.$.clientY,w(g),v(g,!0);var d=g.view.editable,e=g.view.scroll;c>d.left-e.x&&c<d.right-e.x&&b>d.top-e.y&&b<d.bottom-e.y||(clearTimeout(u),u=null,g.line.detach())}else clearTimeout(u),u=null,g.line.detach()}),f.attachListener(f,"keyup",function(){g.hiddenMode=0}),f.attachListener(f,"keydown",function(b){if("wysiwyg"==a.mode)switch(b.data.getKeystroke()){case 2228240:case 16:g.hiddenMode=1,g.line.detach()}}),f.attachListener(g.inInlineMode?f:l,"mousemove",function(b){if(q=!0,"wysiwyg"==a.mode&&!a.readOnly&&!u){var c={x:b.data.$.clientX,y:b.data.$.clientY};u=setTimeout(function(){g.mouse=c,u=g.trigger=null,w(g),q&&!g.hiddenMode&&a.focusManager.hasFocus&&!g.line.mouseNear()&&(g.element=V(g,!0))&&((g.trigger=r(g)||s(g)||Y(g))&&!p(g,g.trigger.upper||g.trigger.lower)?g.line.attach().place():(g.trigger=null,g.line.detach()),q=!1)},30)}}),f.attachListener(m,"scroll",function(){"wysiwyg"==a.mode&&(g.line.detach(),B.webkit&&(g.hiddenMode=1,clearTimeout(o),o=setTimeout(function(){g.mouseDown||(g.hiddenMode=0)},50)))}),f.attachListener(C?l:m,"mousedown",function(){"wysiwyg"==a.mode&&(g.line.detach(),g.hiddenMode=1,g.mouseDown=1)}),f.attachListener(C?l:m,"mouseup",function(){g.hiddenMode=0,g.mouseDown=0}),a.addCommand("accessPreviousSpace",j(g)),a.addCommand("accessNextSpace",j(g,!0)),a.setKeystroke([[d.magicline_keystrokePrevious,"accessPreviousSpace"],[d.magicline_keystrokeNext,"accessNextSpace"]]),a.on("loadSnapshot",function(){var b,c,d,e;for(e in{p:1,br:1,div:1})for(b=a.document.getElementsByTag(e),d=b.count();d--;)if((c=b.getItem(d)).data("cke-magicline-hot"))return g.hotNode=c,void(g.lastCmdDirection="true"===c.data("cke-magicline-dir"))}),this.backdoor={accessFocusSpace:i,boxTrigger:b,isLine:k,getAscendantTrigger:c,getNonEmptyNeighbour:e,getSize:t,that:g,triggerEdge:s,triggerEditable:r,triggerExpand:Y})},this)}});var y=CKEDITOR.tools.extend,z=CKEDITOR.dom.element,A=z.createFromHtml,B=CKEDITOR.env,C=CKEDITOR.env.ie&&9>CKEDITOR.env.version,D=CKEDITOR.dtd,E={},F=128,G=64,H=32,I=16,J=4,K=2,L=1,M="Â ",N=D.$listItem,O=D.$tableContent,P=y({},D.$nonEditable,D.$empty),Q=D.$block,R=100,S="width:0px;height:0px;padding:0px;margin:0px;display:block;z-index:9999;color:#fff;position:absolute;font-size: 0px;line-height:0px;",T=S+"border-color:transparent;display:block;border-style:solid;",U="<span>"+M+"</span>";E[CKEDITOR.ENTER_BR]="br",E[CKEDITOR.ENTER_P]="p",E[CKEDITOR.ENTER_DIV]="div",b.prototype={set:function(a,b,c){return this.properties=a+b+(c||L),this},is:function(a){return(this.properties&a)==a}};var V=function(){function a(a,b){var c=a.$.elementFromPoint(b.x,b.y);return c&&c.nodeType?new CKEDITOR.dom.element(c):null}return function(b,c,d){if(!b.mouse)return null;var e=b.doc,f=b.line.wrap;d=d||b.mouse;var g=a(e,d);return c&&k(b,g)&&(f.hide(),g=a(e,d),f.show()),!g||g.type!=CKEDITOR.NODE_ELEMENT||!g.$||B.ie&&9>B.version&&!b.boundary.equals(g)&&!b.boundary.contains(g)?null:g}}(),W=CKEDITOR.dom.walker.whitespaces(),X=CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_COMMENT),Y=function(){function b(b){var g,h,i,e=b.element;if(!l(e)||e.contains(b.editable)||e.isReadOnly())return null;if(i=x(b,function(a,b){return!b.equals(a)},function(a,b){return V(a,!0,b)},e),g=i.upper,h=i.lower,a(b,g,h))return i.set(H,8);if(g&&e.contains(g))for(;!g.getParent().equals(e);)g=g.getParent();else g=e.getFirst(function(a){return c(b,a)});if(h&&e.contains(h))for(;!h.getParent().equals(e);)h=h.getParent();else h=e.getLast(function(a){return c(b,a)});if(!g||!h)return null;if(u(b,g),u(b,h),!f(b.mouse.y,g.size.top,h.size.bottom))return null;for(var j,k,m,n,e=Number.MAX_VALUE;h&&!h.equals(g)&&(k=g.getNext(b.isRelevant));)j=Math.abs(d(b,g,k)-b.mouse.y),j<e&&(e=j,m=g,n=k),g=k,u(b,g);return m&&n&&f(b.mouse.y,m.size.top,n.size.bottom)?(i.upper=m,i.lower=n,i.set(H,8)):null}function c(a,b){return!(b&&b.type==CKEDITOR.NODE_TEXT||X(b)||m(b)||k(a,b)||b.type==CKEDITOR.NODE_ELEMENT&&b.$&&b.is("br"))}return function(c){var e,d=b(c);if(e=d){e=d.upper;var f=d.lower;e=!(!e||!f||m(f)||m(e)||f.equals(e)||e.equals(f)||f.contains(e)||e.contains(f))&&!!(o(c,e)&&o(c,f)&&a(c,e,f))}return e?d:null}}(),Z=["top","left","right","bottom"]}(),CKEDITOR.config.magicline_keystrokePrevious=CKEDITOR.CTRL+CKEDITOR.SH
15IFT+51,CKEDITOR.config.magicline_keystrokeNext=CKEDITOR.CTRL+CKEDITOR.SHIFT+52,function(){function a(a){if(!a||a.type!=CKEDITOR.NODE_ELEMENT||"form"!=a.getName())return[];for(var b=[],c=["style","className"],d=0;d<c.length;d++){var e=a.$.elements.namedItem(c[d]);e&&(e=new CKEDITOR.dom.element(e),b.push([e,e.nextSibling]),e.remove())}return b}function b(a,b){if(a&&a.type==CKEDITOR.NODE_ELEMENT&&"form"==a.getName()&&0<b.length)for(var c=b.length-1;0<=c;c--){var d=b[c][0],e=b[c][1];e?d.insertBefore(e):d.appendTo(a)}}function c(c,d){var e=a(c),f={},g=c.$;return d||(f.class=g.className||"",g.className=""),f.inline=g.style.cssText||"",d||(g.style.cssText="position: static; overflow: visible"),b(e),f}function d(c,d){var e=a(c),f=c.$;"class"in d&&(f.className=d.class),"inline"in d&&(f.style.cssText=d.inline),b(e)}function e(a){if(!a.editable().isInline()){var c,b=CKEDITOR.instances;for(c in b){var d=b[c];"wysiwyg"!=d.mode||d.readOnly||(d=d.document.getBody(),d.setAttribute("contentEditable",!1),d.setAttribute("contentEditable",!0))}a.editable().hasFocus&&(a.toolbox.focus(),a.focus())}}CKEDITOR.plugins.add("maximize",{init:function(a){function b(){var b=h.getViewPaneSize();a.resize(b.width,b.height,null,!0)}if(a.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE){var i,j,k,f=a.lang,g=CKEDITOR.document,h=g.getWindow(),l=CKEDITOR.TRISTATE_OFF;a.addCommand("maximize",{modes:{wysiwyg:!CKEDITOR.env.iOS,source:!CKEDITOR.env.iOS},readOnly:1,editorFocus:!1,exec:function(){var m=a.container.getFirst(function(a){return a.type==CKEDITOR.NODE_ELEMENT&&a.hasClass("cke_inner")}),n=a.ui.space("contents");if("wysiwyg"==a.mode){var o=a.getSelection();i=o&&o.getRanges(),j=h.getScrollPosition()}else{var p=a.editable().$;i=!CKEDITOR.env.ie&&[p.selectionStart,p.selectionEnd],j=[p.scrollLeft,p.scrollTop]}if(this.state==CKEDITOR.TRISTATE_OFF){for(h.on("resize",b),k=h.getScrollPosition(),o=a.container;o=o.getParent();)o.setCustomData("maximize_saved_styles",c(o)),o.setStyle("z-index",a.config.baseFloatZIndex-5);n.setCustomData("maximize_saved_styles",c(n,!0)),m.setCustomData("maximize_saved_styles",c(m,!0)),n={overflow:CKEDITOR.env.webkit?"":"hidden",width:0,height:0},g.getDocumentElement().setStyles(n),!CKEDITOR.env.gecko&&g.getDocumentElement().setStyle("position","fixed"),CKEDITOR.env.gecko&&CKEDITOR.env.quirks||g.getBody().setStyles(n), 16CKEDITOR.env.ie?setTimeout(function(){h.$.scrollTo(0,0)},0):h.$.scrollTo(0,0),m.setStyle("position",CKEDITOR.env.gecko&&CKEDITOR.env.quirks?"fixed":"absolute"),m.$.offsetLeft,m.setStyles({"z-index":a.config.baseFloatZIndex-5,left:"0px",top:"0px"}),m.addClass("cke_maximized"),b(),n=m.getDocumentPosition(),m.setStyles({left:-1*n.x+"px",top:-1*n.y+"px"}),CKEDITOR.env.gecko&&e(a)}else if(this.state==CKEDITOR.TRISTATE_ON){h.removeListener("resize",b);for(var o=[n,m],q=0;q<o.length;q++)d(o[q],o[q].getCustomData("maximize_saved_styles")),o[q].removeCustomData("maximize_saved_styles");for(o=a.container;o=o.getParent();)d(o,o.getCustomData("maximize_saved_styles")),o.removeCustomData("maximize_saved_styles");CKEDITOR.env.ie?setTimeout(function(){h.$.scrollTo(k.x,k.y)},0):h.$.scrollTo(k.x,k.y),m.removeClass("cke_maximized"),CKEDITOR.env.webkit&&(m.setStyle("display","inline"),setTimeout(function(){m.setStyle("display","block")},0)),a.fire("resize",{outerHeight:a.container.$.offsetHeight,contentsHeight:n.$.offsetHeight,outerWidth:a.container.$.offsetWidth})}this.toggleState(),(o=this.uiItems[0])&&(n=this.state==CKEDITOR.TRISTATE_OFF?f.maximize.maximize:f.maximize.minimize,o=CKEDITOR.document.getById(o._.id),o.getChild(1).setHtml(n),o.setAttribute("title",n),o.setAttribute("href",'javascript:void("'+n+'");')),"wysiwyg"==a.mode?i?(CKEDITOR.env.gecko&&e(a),a.getSelection().selectRanges(i),(p=a.getSelection().getStartElement())&&p.scrollIntoView(!0)):h.$.scrollTo(j.x,j.y):(i&&(p.selectionStart=i[0],p.selectionEnd=i[1]),p.scrollLeft=j[0],p.scrollTop=j[1]),i=j=null,l=this.state,a.fire("maximize",this.state)},canUndo:!1}),a.ui.addButton&&a.ui.addButton("Maximize",{label:f.maximize.maximize,command:"maximize",toolbar:"tools,10"}),a.on("mode",function(){var b=a.getCommand("maximize");b.setState(b.state==CKEDITOR.TRISTATE_DISABLED?CKEDITOR.TRISTATE_DISABLED:l)},null,null,100)}}})}(),CKEDITOR.plugins.add("newpage",{init:function(a){a.addCommand("newpage",{modes:{wysiwyg:1,source:1},exec:function(a){var b=this;a.setData(a.config.newpage_html||"",function(){a.focus(),setTimeout(function(){a.fire("afterCommandExec",{name:"newpage",command:b}),a.selectionChange()},200)})},async:!0}),a.ui.addButton&&a.ui.addButton("NewPage",{label:a.lang.newpage.toolbar,command:"newpage",toolbar:"document,20"})}}),function(){function a(a){return{"aria-label":a,class:"cke_pagebreak",contenteditable:"false","data-cke-display-name":"pagebreak","data-cke-pagebreak":1,style:"page-break-after: always",title:a}}CKEDITOR.plugins.add("pagebreak",{requires:"fakeobjects",onLoad:function(){var a=("background:url("+CKEDITOR.getUrl(this.path+"images/pagebreak.gif")+") no-repeat center center;clear:both;width:100%;border-top:#999 1px dotted;border-bottom:#999 1px dotted;padding:0;height:7px;cursor:default;").replace(/;/g," !important;");CKEDITOR.addCss("div.cke_pagebreak{"+a+"}")},init:function(a){a.blockless||(a.addCommand("pagebreak",CKEDITOR.plugins.pagebreakCmd),a.ui.addButton&&a.ui.addButton("PageBreak",{label:a.lang.pagebreak.toolbar,command:"pagebreak",toolbar:"insert,70"}),CKEDITOR.env.webkit&&a.on("contentDom",function(){a.document.on("click",function(b){b=b.data.getTarget(),b.is("div")&&b.hasClass("cke_pagebreak")&&a.getSelection().selectElement(b)})}))},afterInit:function(b){function c(c){CKEDITOR.tools.extend(c.attributes,a(b.lang.pagebreak.alt),!0),c.children.length=0}var d=b.dataProcessor,e=d&&d.dataFilter,d=d&&d.htmlFilter,f=/page-break-after\s*:\s*always/i,g=/display\s*:\s*none/i;d&&d.addRules({attributes:{class:function(a,b){var c=a.replace("cke_pagebreak","");if(c!=a){var d=CKEDITOR.htmlParser.fragment.fromHtml('<span style="display: none;"> </span>').children[0];b.children.length=0,b.add(d),d=b.attributes,delete d["aria-label"],delete d.contenteditable,delete d.title}return c}}},{applyToAll:!0,priority:5}
16),e&&e.addRules({elements:{div:function(a){if(a.attributes["data-cke-pagebreak"])c(a);else if(f.test(a.attributes.style)){var b=a.children[0];b&&"span"==b.name&&g.test(b.attributes.style)&&c(a)}}}})}}),CKEDITOR.plugins.pagebreakCmd={exec:function(b){var c=b.document.createElement("div",{attributes:a(b.lang.pagebreak.alt)});b.insertElement(c)},context:"div",allowedContent:{div:{styles:"!page-break-after"},span:{match:function(a){return(a=a.parent)&&"div"==a.name&&a.styles&&a.styles["page-break-after"]},styles:"display"}},requiredContent:"div{page-break-after}"}}(),function(){var a={canUndo:!1,async:!0,exec:function(b){b.getClipboardData({title:b.lang.pastetext.title},function(c){c&&b.fire("paste",{type:"text",dataValue:c.dataValue,method:"paste",dataTransfer:CKEDITOR.plugins.clipboard.initPasteDataTransfer()}),b.fire("afterCommandExec",{name:"pastetext",command:a,returnValue:!!c})})}};CKEDITOR.plugins.add("pastetext",{requires:"clipboard",init:function(b){b.addCommand("pastetext",a),b.ui.addButton&&b.ui.addButton("PasteText",{label:b.lang.pastetext.button,command:"pastetext",toolbar:"clipboard,40"}),b.config.forcePasteAsPlainText&&b.on("beforePaste",function(a){"html"!=a.data.type&&(a.data.type="text")}),b.on("pasteState",function(a){b.getCommand("pastetext").setState(a.data)})}})}(),function(){function a(a,b,c){var d=CKEDITOR.cleanWord;return d?c():(a=CKEDITOR.getUrl(a.config.pasteFromWordCleanupFile||b+"filter/default.js"),CKEDITOR.scriptLoader.load(a,c,null,!0)),!d}function b(a){a.data.type="html"}CKEDITOR.plugins.add("pastefromword",{requires:"clipboard",init:function(c){var d=0,e=this.path;c.addCommand("pastefromword",{canUndo:!1,async:!0,exec:function(a){var c=this;d=1,a.once("beforePaste",b),a.getClipboardData({title:a.lang.pastefromword.title},function(b){b&&a.fire("paste",{type:"html",dataValue:b.dataValue,method:"paste",dataTransfer:CKEDITOR.plugins.clipboard.initPasteDataTransfer()}),a.fire("afterCommandExec",{name:"pastefromword",command:c,returnValue:!!b})})}}),c.ui.addButton&&c.ui.addButton("PasteFromWord",{label:c.lang.pastefromword.toolbar,command:"pastefromword",toolbar:"clipboard,50"}),c.on("pasteState",function(a){c.getCommand("pastefromword").setState(a.data)}),c.on("paste",function(b){var f=b.data,g=f.dataValue;if(g&&(d||/(class=\"?Mso|style=\"[^\"]*\bmso\-|w:WordDocument)/.test(g))){f.dontFilter=!0;var h=a(c,e,function(){h?c.fire("paste",f):(!c.config.pasteFromWordPromptCleanup||d||confirm(c.lang.pastefromword.confirmCleanup))&&(f.dataValue=CKEDITOR.cleanWord(g,c)),d=0});h&&b.cancel()}},null,null,3)}})}(),function(){var a,b={modes:{wysiwyg:1,source:1},canUndo:!1,readOnly:1,exec:function(b){var c,d=b.config,e=d.baseHref?'<base href="'+d.baseHref+'"/>':"";if(d.fullPage)c=b.getData().replace(/<head>/,"$&"+e).replace(/[^>]*(?=<\/title>)/,"$& — "+b.lang.preview.preview);else{var d="<body ",f=b.document&&b.document.getBody();f&&(f.getAttribute("id")&&(d+='id="'+f.getAttribute("id")+'" '),f.getAttribute("class")&&(d+='class="'+f.getAttribute("class")+'" ')),d+=">",c=b.config.docType+'<html dir="'+b.config.contentsLangDirection+'"><head>'+e+"<title>"+b.lang.preview.preview+"</title>"+CKEDITOR.tools.buildStyleHtml(b.config.contentsCss)+"</head>"+d+b.getData()+"</body></html>"}e=640,d=420,f=80;try{var g=window.screen,e=Math.round(.8*g.width),d=Math.round(.7*g.height),f=Math.round(.1*g.width)}catch(a){}if(!1===b.fire("contentPreview",b={dataValue:c}))return!1;var h,g="";return CKEDITOR.env.ie&&(window._cke_htmlToLoad=b.dataValue,h="javascript:void( (function(){document.open();"+("("+CKEDITOR.tools.fixDomain+")();").replace(/\/\/.*?\n/g,"").replace(/parent\./g,"window.opener.")+"document.write( window.opener._cke_htmlToLoad );document.close();window.opener._cke_htmlToLoad = null;})() )",g=""),CKEDITOR.env.gecko&&(window._cke_htmlToLoad=b.dataValue,g=CKEDITOR.getUrl(a+"preview.html")),g=window.open(g,null,"toolbar=yes,location=no,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width="+e+",height="+d+",left="+f),CKEDITOR.env.ie&&g&&(g.location=h),CKEDITOR.env.ie||CKEDITOR.env.gecko||(h=g.document,h.open(),h.write(b.dataValue),h.close()),!0}};CKEDITOR.plugins.add("preview",{init:function(c){c.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE&&(a=this.path,c.addCommand("preview",b),c.ui.addButton&&c.ui.addButton("Preview",{label:c.lang.preview.preview,command:"preview",toolbar:"document,40"}))}})}(),CKEDITOR.plugins.add("print",{init:function(a){a.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE&&(a.addCommand("print",CKEDITOR.plugins.print),a.ui.addButton&&a.ui.addButton("Print",{label:a.lang.print.toolbar,command:"print",toolbar:"document,50"}))}}),CKEDITOR.plugins.print={exec:function(a){CKEDITOR.env.gecko?a.window.$.print():a.document.$.execCommand("Print")},canUndo:!1,readOnly:1,modes:{wysiwyg:1}},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 h,b=a._.removeFormatRegex||(a._.removeFormatRegex=new RegExp("^(?:"+a.config.removeFormatTags.replace(/,/g,"|")+")$","i")),c=a._.removeAttributes||(a._.removeAttributes=a.config.removeFormatAttributes.split(",")),d=CKEDITOR.plugins.removeformat.filter,e=a.getSelection().getRanges(),f=e.createIterator(),g=function(a){return a.type==CKEDITOR.NODE_ELEMENT};h=f.getNextRange();){h.collapsed||h.enlarge(CKEDITOR.ENLARGE_ELEMENT);var i=h.createBookmark(),j=i.startNode,k=i.endNode,l=function(c){for(var h,e=a.elementPath(c),f=e.elements,g=1;
16(h=f[g])&&!h.equals(e.block)&&!h.equals(e.blockLimit);g++)b.test(h.getName())&&d(a,h)&&c.breakParent(h)};if(l(j),k)for(l(k),j=j.getNextSourceNode(!0,CKEDITOR.NODE_ELEMENT);j&&!j.equals(k);)if(j.isReadOnly()){if(j.getPosition(k)&CKEDITOR.POSITION_CONTAINS)break;j=j.getNext(g)}else l=j.getNextSourceNode(!1,CKEDITOR.NODE_ELEMENT),"img"==j.getName()&&j.data("cke-realelement")||!d(a,j)||(b.test(j.getName())?j.remove(1):(j.removeAttributes(c),a.fire("removeFormatCleanup",j))),j=l;h.moveToBookmark(i)}a.forceNextSelectionCheck(),a.getSelection().selectRanges(e)}}},filter:function(a,b){for(var c=a._.removeFormatFilters||[],d=0;d<c.length;d++)if(!1===c[d](b))return!1;return!0}},CKEDITOR.editor.prototype.addRemoveFormatFilter=function(a){this._.removeFormatFilters||(this._.removeFormatFilters=[]),this._.removeFormatFilters.push(a)},CKEDITOR.config.removeFormatTags="b,big,cite,code,del,dfn,em,font,i,ins,kbd,q,s,samp,small,span,strike,strong,sub,sup,tt,u,var",CKEDITOR.config.removeFormatAttributes="class,style,lang,width,height,align,hspace,valign",function(){var a={readOnly:1,exec:function(a){if(a.fire("save")&&(a=a.element.$.form))try{a.submit()}catch(b){a.submit.click&&a.submit.click()}}};CKEDITOR.plugins.add("save",{init:function(b){b.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE&&(b.addCommand("save",a).modes={wysiwyg:!!b.element.$.form},b.ui.addButton&&b.ui.addButton("Save",{label:b.lang.save.toolbar,command:"save",toolbar:"document,10"}))}})}(),function(){CKEDITOR.plugins.add("selectall",{init:function(a){a.addCommand("selectAll",{modes:{wysiwyg:1,source:1},exec:function(a){var b=a.editable();if(b.is("textarea"))a=b.$,CKEDITOR.env.ie?a.createTextRange().execCommand("SelectAll"):(a.selectionStart=0,a.selectionEnd=a.value.length),a.focus();else{if(b.is("body"))a.document.$.execCommand("SelectAll",!1,null);else{var c=a.createRange();c.selectNodeContents(b),c.select()}a.forceNextSelectionCheck(),a.selectionChange()}},canUndo:!1}),a.ui.addButton&&a.ui.addButton("SelectAll",{label:a.lang.selectall.toolbar,command:"selectAll",toolbar:"selection,10"})}})}(),function(){var a={readOnly:1,preserveState:!0,editorFocus:!1,exec:function(a){this.toggleState(),this.refresh(a)},refresh:function(a){if(a.document){var b=this.state!=CKEDITOR.TRISTATE_ON||a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE&&!a.focusManager.hasFocus?"removeClass":"attachClass";a.editable()[b]("cke_show_blocks")}}};CKEDITOR.plugins.add("showblocks",{onLoad:function(){var b,c,d,e,i,j,a="p div pre address blockquote h1 h2 h3 h4 h5 h6".split(" "),f=CKEDITOR.getUrl(this.path),g=!(CKEDITOR.env.ie&&9>CKEDITOR.env.version),h=g?":not([contenteditable=false]):not(.cke_show_blocks_off)":"";for(b=c=d=e="";i=a.pop();)j=a.length?",":"",b+=".cke_show_blocks "+i+h+j,d+=".cke_show_blocks.cke_contents_ltr "+i+h+j,e+=".cke_show_blocks.cke_contents_rtl "+i+h+j,c+=".cke_show_blocks "+i+h+"{background-image:url("+CKEDITOR.getUrl(f+"images/block_"+i+".png")+")}";CKEDITOR.addCss((b+"{background-repeat:no-repeat;border:1px dotted gray;padding-top:8px}").concat(c,d+"{background-position:top left;padding-left:8px}",e+"{background-position:top right;padding-right:8px}")),g||CKEDITOR.addCss(".cke_show_blocks [contenteditable=false],.cke_show_blocks .cke_show_blocks_off{border:none;padding-top:0;background-image:none}.cke_show_blocks.cke_contents_rtl [contenteditable=false],.cke_show_blocks.cke_contents_rtl .cke_show_blocks_off{padding-right:0}.cke_show_blocks.cke_contents_ltr [contenteditable=false],.cke_show_blocks.cke_contents_ltr .cke_show_blocks_off{padding-left:0}")},init:function(b){function c(){d.refresh(b)}if(!b.blockless){var d=b.addCommand("showblocks",a);d.canUndo=!1,b.config.startupOutlineBlocks&&d.setState(CKEDITOR.TRISTATE_ON),b.ui.addButton&&b.ui.addButton("ShowBlocks",{label:b.lang.showblocks.toolbar,command:"showblocks",toolbar:"tools,20"}),b.on("mode",function(){d.state!=CKEDITOR.TRISTATE_DISABLED&&d.refresh(b)}),b.elementMode==CKEDITOR.ELEMENT_MODE_INLINE&&(b.on("focus",c),b.on("blur",c)),b.on("contentDom",function(){d.state!=CKEDITOR.TRISTATE_DISABLED&&d.refresh(b)})}}})}(),function(){var a={preserveState:!0,editorFocus:!1,readOnly:1,exec:function(a){this.toggleState(),this.refresh(a)}
16,refresh:function(a){if(a.document){var b=this.state==CKEDITOR.TRISTATE_ON?"attachClass":"removeClass";a.editable()[b]("cke_show_borders")}}};CKEDITOR.plugins.add("showborders",{modes:{wysiwyg:1},onLoad:function(){var a;a=(CKEDITOR.env.ie6Compat?[".%1 table.%2,",".%1 table.%2 td, .%1 table.%2 th","{","border : #d3d3d3 1px dotted","}"]:".%1 table.%2,;.%1 table.%2 > tr > td, .%1 table.%2 > tr > th,;.%1 table.%2 > tbody > tr > td, .%1 table.%2 > tbody > tr > th,;.%1 table.%2 > thead > tr > td, .%1 table.%2 > thead > tr > th,;.%1 table.%2 > tfoot > tr > td, .%1 table.%2 > tfoot > tr > th;{;border : #d3d3d3 1px dotted;}".split(";")).join("").replace(/%2/g,"cke_show_border").replace(/%1/g,"cke_show_borders "),CKEDITOR.addCss(a)},init:function(b){var c=b.addCommand("showborders",a);c.canUndo=!1,!1!==b.config.startupShowBorders&&c.setState(CKEDITOR.TRISTATE_ON),b.on("mode",function(){c.state!=CKEDITOR.TRISTATE_DISABLED&&c.refresh(b)},null,null,100),b.on("contentDom",function(){c.state!=CKEDITOR.TRISTATE_DISABLED&&c.refresh(b)}),b.on("removeFormatCleanup",function(a){a=a.data,b.getCommand("showborders").state==CKEDITOR.TRISTATE_ON&&a.is("table")&&(!a.hasAttribute("border")||0>=parseInt(a.getAttribute("border"),10))&&a.addClass("cke_show_border")})},afterInit:function(a){var b=a.dataProcessor;a=b&&b.dataFilter,b=b&&b.htmlFilter,a&&a.addRules({elements:{table:function(a){a=a.attributes;var b=a.class,c=parseInt(a.border,10);c&&!(0>=c)||b&&-1!=b.indexOf("cke_show_border")||(a.class=(b||"")+" cke_show_border")}}}),b&&b.addRules({elements:{table:function(a){a=a.attributes;var b=a.class;b&&(a.class=b.replace("cke_show_border","").replace(/\s{2}/," ").replace(/^\s+|\s+$/,""))}}})}}),CKEDITOR.on("dialogDefinition",function(a){var b=a.data.name;"table"!=b&&"tableProperties"!=b||(a=a.data.definition,b=a.getContents("info").get("txtBorder"),b.commit=CKEDITOR.tools.override(b.commit,function(a){return function(b,c){a.apply(this,arguments);var d=parseInt(this.getValue(),10);c[!d||0>=d?"addClass":"removeClass"]("cke_show_border")}}),(a=(a=a.getContents("advanced"))&&a.get("advCSSClasses"))&&(a.setup=CKEDITOR.tools.override(a.setup,function(a){return function(){a.apply(this,arguments),this.setValue(this.getValue().replace(/cke_show_border/,""))}}),a.commit=CKEDITOR.tools.override(a.commit,function(a){return function(b,c){a.apply(this,arguments),parseInt(c.getAttribute("border"),10)||c.addClass("cke_show_border")}})))})}(),function(){CKEDITOR.plugins.add("sourcearea",{init:function(b){function c(){var a=e&&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(b.elementMode!=CKEDITOR.ELEMENT_MODE_INLINE){var d=CKEDITOR.plugins.sourcearea;b.addMode("source",function(d){var e=b.ui.space("contents").getDocument().createElement("textarea");
16e.setStyles(CKEDITOR.tools.extend({width:CKEDITOR.env.ie7Compat?"99%":"100%",height:"100%",resize:"none",outline:"none","text-align":"left"},CKEDITOR.tools.cssVendorPrefix("tab-size",b.config.sourceAreaTabSize||4))),e.setAttribute("dir","ltr"),e.addClass("cke_source").addClass("cke_reset").addClass("cke_enable_context_menu"),b.ui.space("contents").append(e),e=b.editable(new a(b,e)),e.setData(b.getData(1)),CKEDITOR.env.ie&&(e.attachListener(b,"resize",c,e),e.attachListener(CKEDITOR.document.getWindow(),"resize",c,e),CKEDITOR.tools.setTimeout(c,0,e)),b.fire("ariaWidget",this),d()}),b.addCommand("source",d.commands.source),b.ui.addButton&&b.ui.addButton("Source",{label:b.lang.sourcearea.toolbar,command:"source",toolbar:"mode,10"}),b.on("mode",function(){b.getCommand("source").setState("source"==b.mode?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF)});var e=CKEDITOR.env.ie&&9==CKEDITOR.env.version}}});var a=CKEDITOR.tools.createClass({base:CKEDITOR.editable,proto:{setData:function(a){this.setValue(a),this.status="ready",this.editor.fire("dataReady")},getData:function(){return this.getValue()},insertHtml:function(){},insertElement:function(){},insertText:function(){},setReadOnly:function(a){this[(a?"set":"remove")+"Attribute"]("readOnly","readonly")},detach:function(){a.baseProto.detach.call(this),this.clearCustomData(),this.remove()}}})}(),CKEDITOR.plugins.sourcearea={commands:{source:{modes:{wysiwyg:1,source:1},editorFocus:!1,readOnly:1,exec:function(a){"wysiwyg"==a.mode&&a.fire("saveSnapshot"),a.getCommand("source").setState(CKEDITOR.TRISTATE_DISABLED),a.setMode("source"==a.mode?"wysiwyg":"source")},canUndo:!1}}},CKEDITOR.plugins.add("specialchar",{availableLangs:{af:1,ar:1,bg:1,ca:1,cs:1,cy:1,da:1,de:1,"de-ch":1,el:1,en:1,"en-gb":1,eo:1,es:1,et:1,eu:1,fa:1,fi:1,fr:1,"fr-ca":1,gl:1,he:1,hr:1,hu:1,id:1,it:1,ja:1,km:1,ko:1,ku:1,lt:1,lv:1,nb:1,nl:1,no:1,pl:1,pt:1,"pt-br":1,ru:1,si:1,sk:1,sl:1,sq:1,sv:1,th:1,tr:1,tt:1,ug:1,uk:1,vi:1,zh:1,"zh-cn":1},requires:"dialog",init:function(a){var b=this;CKEDITOR.dialog.add("specialchar",this.path+"dialogs/specialchar.js"),a.addCommand("specialchar",{exec:function(){var c=a.langCode,c=b.availableLangs[c]?c:b.availableLangs[c.replace(/-.*/,"")]?c.replace(/-.*/,""):"en";CKEDITOR.scriptLoader.load(CKEDITOR.getUrl(b.path+"dialogs/lang/"+c+".js"),function(){CKEDITOR.tools.extend(a.lang.specialchar,b.langEntries[c]),a.openDialog("specialchar")})},modes:{wysiwyg:1},canUndo:!1}),a.ui.addButton&&a.ui.addButton("SpecialChar",{label:a.lang.specialchar.toolbar,command:"specialchar",toolbar:"insert,50"})}}),CKEDITOR.config.specialChars="! " # $ % & ' ( ) * + - . / 0 1 2 3 4 5 6 7 8 9 : ; < = > ? @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z [ ] ^ _ ` a b c d e f g h i j k l m n o p q r s t u v w x y z { | } ~ € ‘ ’ “ ” – — ¡ ¢ £ ¤ ¥ ¦ § ¨ © ª « ¬ ® ¯ ° ² ³ ´ µ ¶ · ¸ ¹ º » ¼ ½ ¾ ¿ À Á Â Ã Ä Å Æ Ç È É Ê Ë Ì Í Î Ï Ð Ñ Ò Ó Ô Õ Ö × Ø Ù Ú Û Ü Ý Þ ß à á â ã ä å æ ç è é ê ë ì í î ï ð ñ ò ó ô õ ö ÷ ø ù ú û ü ý þ ÿ Œ œ Ŵ Ŷ ŵ ŷ ‚ ‛ „ … ™ ► • → ⇒ ⇔ ♦ ≈".split(" "),CKEDITOR.plugins.add("scayt",{requires:"menubutton,dialog",tabToOpen:null,dialogName:"scaytDialog",init:function(a){var b=this,c=CKEDITOR.plugins.scayt;this.bindEvents(a),this.parseConfig(a),this.addRule(a),CKEDITOR.dialog.add(this.dialogName,CKEDITOR.getUrl(this.path+"dialogs/options.js")),this.addMenuItems(a);var d=a.lang.scayt,e=CKEDITOR.env;a.ui.add("Scayt",CKEDITOR.UI_MENUBUTTON,{label:d.text_title,title:a.plugins.wsc?a.lang.wsc.title:d.text_title,modes:{wysiwyg:!(e.ie&&(8>e.version||e.quirks))},toolbar:"spellchecker,20",refresh:function(){var b=a.ui.instances.Scayt.getState();a.scayt&&(b=c.state.scayt[a.name]?CKEDITOR.TRISTATE_ON:CKEDITOR.TRISTATE_OFF),a.fire("scaytButtonState",b)},onRender:function(){var b=this;a.on("scaytButtonState",function(a){void 0!==typeof a.data&&b.setState(a.data)})},onMenu:function(){var b=a.scayt;return a.getMenuItem("scaytToggle").label=a.lang.scayt[b&&c.state.scayt[a.name]?"btn_disable":"btn_enable"],b={scaytToggle:CKEDITOR.TRISTATE_OFF,scaytOptions:b?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,scaytLangs:b?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,scaytDict:b?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,scaytAbout:b?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,WSC:a.plugins.wsc?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED},a.config.scayt_uiTabs[0]||delete b.scaytOptions,a.config.scayt_uiTabs[1]||delete b.scaytLangs,a.config.scayt_uiTabs[2]||delete b.scaytDict,b}}),a.contextMenu&&a.addMenuItems&&(a.contextMenu.addListener(function(c,d){var f,g,e=a.scayt;return e&&(g=e.getSelectionNode())&&(f=b.menuGenerator(a,g),e.showBanner("."+a.contextMenu._.definition.panel.className.split(" ").join(" ."))),f}),a.contextMenu._.onHide=CKEDITOR.tools.override(a.contextMenu._.onHide,function(b){return function(){var c=a.scayt;return c&&c.hideBanner(),b.apply(this)}}))},addMenuItems:function(a){var b=this,c=CKEDITOR.plugins.scayt;a.addMenuGroup("scaytButton");for(var d=a.config.scayt_contextMenuItemsOrder.split("|"),e=0;e<d.length;e++)d[e]="scayt_"+d[e];if((d=["grayt_description","grayt_suggest","grayt_control"].concat(d))&&d.length)for(e=0;e<d.length;e++)a.addMenuGroup(d[e],e-10);a.addCommand("scaytToggle",{exec:function(a){var b=a.scayt;c.state.scayt[a.name]=!c.state.scayt[a.name],!0===c.state.scayt[a.name]?b||c.createScayt(a):b&&c.destroy(a)}}),a.addCommand("scaytAbout",{exec:function(a){a.scayt.tabToOpen="about",a.lockSelection(),a.openDialog(b.dialogName)}}),a.addCommand("scaytOptions",{exec:function(a){a.scayt.tabToOpen="options",a.lockSelection(),a.openDialog(b.dialogName)}}),a.addCommand("scaytLangs",{exec:function(a){a.scayt.tabToOpen="langs",a.lockSelection(),a.openDialog(b.dialogName)}}),a.addCommand("scaytDict",{exec:function(a){a.scayt.tabToOpen="dictionaries",a.lockSelection(),a.openDialog(b.dialogName)}}),d={scaytToggle:{label:a.lang.scayt.btn_enable,group:"scaytButton",command:"scaytToggle"},scaytAbout:{label:a.lang.scayt.btn_about,group:"scaytButton",command:"scaytAbout"},scaytOptions:{label:a.lang.scayt.btn_options,group:"scaytButton",command:"scaytOptions"},scaytLangs:{label:a.lang.scayt.btn_langs,group:"scaytButton",command:"scaytLangs"},scaytDict:{label:a.lang.scayt.btn_dictionaries,group:"scaytButton",command:"scaytDict"}},a.plugins.wsc&&(d.WSC={label:a.lang.wsc.toolbar,group:"scaytButton",onClick:function(){var b=CKEDITOR.plugins.scayt,c=a.scayt,d=a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?a.container.getText():a.document.getBody().getText();(d=d.replace(/\s/g,""))?(c&&b.state.scayt[a.name]&&c.setMarkupPaused&&c.setMarkupPaused(!0),a.lockSelection(),a.execCommand("checkspell")):alert("Nothing to check!")}}),a.addMenuItems(d)},bindEvents:function(a){var b=CKEDITOR.plugins.scayt,c=a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE,d=function(){b.destroy(a)},e=function(){!b.state.scayt[a.name]||a.readOnly||a.scayt||b.createScayt(a)},f=function(){var b=a.editable();b.attachListener(b,"focus",function(b){CKEDITOR.plugins.scayt&&!a.scayt&&setTimeout(e,0),b=CKEDITOR.plugins.scayt&&CKEDITOR.plugins.scayt.state.scayt[a.name]&&a.scayt;var d,f;if((c||b)&&a._.savedSelection){b=a._.savedSelection.getSelectedElement(),b=!b&&a._.savedSelection.getRanges();for(var g=0;g<b.length;g++)f=b[g],"string"==typeof f.startContainer.$.nodeValue&&(d=f.startContainer.getText().length,(d<f.startOffset||d<f.endOffset)&&a.unlockSelection(!1))}},this,null,-10)},g=function(){c?a.config.scayt_inlineModeImmediateMarkup?e():(a.on("blur",function(){setTimeout(d,0)}),a.on("focus",e),a.focusManager.hasFocus&&e()):e(),f();var b=a.editable();b.attachListener(b,"mousedown",function(b){b=b.data.getTarget();var c=a.widgets&&a.widgets.getByElement(b);c&&(c.wrapper=b.getAscendant(function(a){return a.hasAttribute("data-cke-widget-wrapper")},!0))},this,null,-10)};a.on("contentDom",g),a.on("beforeCommandExec",function(c){var d=a.scayt,e=null,f=!1,g=!0;c.data.name in b.options.disablingCommandExec&&"wysiwyg"==a.mode?d&&(b.destroy(a),a.fire("scaytButtonState",CKEDITOR.TRISTATE_DISABLED)):"bold"!==c.data.name&&"italic"!==c.data.name&&"underline"!==c.data.name&&"strike"!==c.data.name&&"subscript"!==c.data.name&&"superscript"!==c.data.name&&"enter"!==c.data.name&&"cut"!==c.data.name&&"language"!==c.data.name||!d||("cut"===c.data.name&&(g=!1,f=!0),"language"===c.data.name&&(e=(e=a.plugins.language.getCurrentLangElement(a))&&e.$,f=!0),a.fire("reloadMarkupScayt",{removeOptions:{removeInside:g,forceBookmark:f,selectionNode:e},timeout:0}))}),a.on("beforeSetMode",function(c){"source"==c.data&&((c=a.scayt)&&(b.destroy(a),a.fire("scaytButtonState",CKEDITOR.TRISTATE_DISABLED)),a.document&&a.document.getBody().removeAttribute("_jquid"))}),a.on("afterCommandExec",function(b){"wysiwyg"!=a.mode||"undo"!=b.data.name&&"redo"!=b.data.name||setTimeout(function(){var b=a.scayt,c=b&&b.getScaytLangList();c&&c.ltr&&c.rtl&&b.fire("startSpellCheck, startGrammarCheck")},250)}),a.on("readOnly",function(c){var d;c&&(d=a.scayt,!0===c.editor.readOnly?d&&d.fire("removeMarkupInDocument",{}):d?d.fire("startSpellCheck, startGrammarCheck"):"wysiwyg"==c.editor.mode&&!0===b.state.scayt[c.editor.name]&&(b.createScayt(a),c.editor.fire("scaytButtonState",CKEDITOR.TRISTATE_ON)))}),a.on("beforeDestroy",d),a.on("setData",function(){d(),(a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE||a.plugins.divarea)&&g()},this,null,50),a.on("reloadMarkupScayt",function(b){var c=b.data&&b.data.removeOptions;setTimeout(function(){var b=a.scayt,d=b&&b.getScaytLangList();d&&d.ltr&&d.rtl&&(a.document.fire("keydown",new CKEDITOR.dom.event({keyCode:37})),b.removeMarkupInSelectionNode(c),b.fire("startSpellCheck, startGrammarCheck"))},b.data&&b.data.timeout||0)}),a.on("insertElement",function(){a.fire("reloadMarkupScayt",{removeOptions:{forceBookmark:!0}})},this,null,50),a.on("insertHtml",function(){a.fire("reloadMarkupScayt")},this,null,50),a.on("insertText",function(){a.fire("reloadMarkupScayt")},this,null,50),a.on("scaytDialogShown",function(b){b.data.selectPage(a.scayt.tabToOpen)})},parseConfig:function(a){var b=CKEDITOR.plugins.scayt;if(b.replaceOldOptionsNames(a.config),"boolean"!=typeof a.config.scayt_autoStartup&&(a.config.scayt_autoStartup=!1),b.state.scayt[a.name]=a.config.scayt_autoStartup,"boolean"!=typeof a.config.grayt_autoStartup&&(a.config.grayt_autoStartup=!1),"boolean"!=typeof a.config.scayt_inlineModeImmediateMarkup&&(a.config.scayt_inlineModeImmediateMarkup=!1),b.state.grayt[a.name]=a.config.grayt_autoStartup,a.config.scayt_contextCommands||(a.config.scayt_contextCommands="ignore|ignoreall|add"),a.config.scayt_contextMenuItemsOrder||(a.config.scayt_contextMenuItemsOrder="suggest|moresuggest|control"),a.config.scayt_sLang||(a.config.scayt_sLang="en_US"),(void 0===a.config.scayt_maxSuggestions||"number"!=typeof a.config.scayt_maxSuggestions||0>a.config.scayt_maxSuggestions)&&(a.config.scayt_maxSuggestions=5),(void 0===a.config.scayt_minWordLength||"number"!=typeof a.config.scayt_minWordLength||1>a.config.scayt_minWordLength)&&(a.config.scayt_minWordLength=4),void 0!==a.config.scayt_customDictionaryIds&&"string"==typeof a.config.scayt_customDictionaryIds||(a.config.scayt_customDictionaryIds=""),void 0!==a.config.scayt_userDictionaryName&&"string"==typeof a.config.scayt_userDictionaryName||(a.config.scayt_userDictionaryName=null),"string"==typeof a.config.scayt_uiTabs&&3===a.config.scayt_uiTabs.split(",").length){var c=[],d=[];a.config.scayt_uiTabs=a.config.scayt_uiTabs.split(","),CKEDITOR.tools.search(a.config.scayt_uiTabs,function(a){1===Number(a)||0===Number(a)?(d.push(!0),c.push(Number(a))):d.push(!1)}),null===CKEDITOR.tools.search(d,!1)?a.config.scayt_uiTabs=c:a.config.scayt_uiTabs=[1,1,1]}else a.config.scayt_uiTabs=[1,1,1];if("string"!=typeof a.config.scayt_serviceProtocol&&(a.config.scayt_serviceProtocol=null),"string"!=typeof a.config.scayt_serviceHost&&(a.config.scayt_serviceHost=null),"string"!=typeof a.config.scayt_servicePort&&(a.config.scayt_servicePort=null),"string"!=typeof a.config.scayt_servicePath&&(a.config.scayt_servicePath=null),a.config.scayt_moreSuggestions||(a.config.scayt_moreSuggestions="on"),"string"!=typeof a.config.scayt_customerId&&(a.config.scayt_customerId="1:WvF0D4-UtPqN1-43nkD4-NKvUm2-daQqk3-LmNiI-z7Ysb4-mwry24-T8YrS3-Q2tpq2"),"string"!=typeof a.config.scayt_srcUrl&&(b=document.location.protocol,b=-1!=b.search(/https?:/)?b:"http:",a.config.scayt_srcUrl=b+"//svc.webspellchecker.net/spellcheck31/lf/scayt3/ckscayt/ckscayt.js"),"boolean"!=typeof CKEDITOR.config.scayt_handleCheckDirty&&(CKEDITOR.config.scayt_handleCheckDirty=!0),"boolean"!=typeof CKEDITOR.config.scayt_handleUndoRedo&&(CKEDITOR.config.scayt_handleUndoRedo=!0),CKEDITOR.config.scayt_handleUndoRedo=!!CKEDITOR.plugins.undo&&CKEDITOR.config.scayt_handleUndoRedo,"boolean"!=typeof a.config.scayt_multiLanguageMode&&(a.config.scayt_multiLanguageMode=!1),"object"!=typeof a.config.scayt_multiLanguageStyles&&(a.config.scayt_multiLanguageStyles={}),a.config.scayt_ignoreAllCapsWords&&"boolean"!=typeof a.config.scayt_ignoreAllCapsWords&&(a.config.scayt_ignoreAllCapsWords=!1),a.config.scayt_ignoreDomainNames&&"boolean"!=typeof a.config.scayt_ignoreDomainNames&&(a.config.scayt_ignoreDomainNames=!1),a.config.scayt_ignoreWordsWithMixedCases&&"boolean"!=typeof a.config.scayt_ignoreWordsWithMixedCases&&
16(a.config.scayt_ignoreWordsWithMixedCases=!1),a.config.scayt_ignoreWordsWithNumbers&&"boolean"!=typeof a.config.scayt_ignoreWordsWithNumbers&&(a.config.scayt_ignoreWordsWithNumbers=!1),a.config.scayt_disableOptionsStorage){var b=CKEDITOR.tools.isArray(a.config.scayt_disableOptionsStorage)?a.config.scayt_disableOptionsStorage:"string"==typeof a.config.scayt_disableOptionsStorage?[a.config.scayt_disableOptionsStorage]:void 0,e="all options lang ignore-all-caps-words ignore-domain-names ignore-words-with-mixed-cases ignore-words-with-numbers".split(" "),f=["lang","ignore-all-caps-words","ignore-domain-names","ignore-words-with-mixed-cases","ignore-words-with-numbers"],g=CKEDITOR.tools.search,h=CKEDITOR.tools.indexOf;a.config.scayt_disableOptionsStorage=function(a){for(var b=[],c=0;c<a.length;c++){var d=a[c],i=!!g(a,"options");if(!g(e,d)||i&&g(f,function(a){if("lang"===a)return!1}))return;if(g(f,d)&&f.splice(h(f,d),1),"all"===d||i&&g(a,"lang"))return[];"options"===d&&(f=["lang"])}return b=b.concat(f)}(b)}},addRule:function(a){var b=CKEDITOR.plugins.scayt,c=a.dataProcessor,d=c&&c.htmlFilter,e=a._.elementsPath&&a._.elementsPath.filters,c=c&&c.dataFilter,f=a.addRemoveFormatFilter,g=function(c){if(a.scayt&&(c.hasAttribute(b.options.data_attribute_name)||c.hasAttribute(b.options.problem_grammar_data_attribute)))return!1},h=function(c){var d=!0;return a.scayt&&(c.hasAttribute(b.options.data_attribute_name)||c.hasAttribute(b.options.problem_grammar_data_attribute))&&(d=!1), 17d};e&&e.push(g),c&&c.addRules({elements:{span:function(a){var c=a.hasClass(b.options.misspelled_word_class)&&a.attributes[b.options.data_attribute_name],d=a.hasClass(b.options.problem_grammar_class)&&a.attributes[b.options.problem_grammar_data_attribute];return b&&(c||d)&&delete a.name,a}}}),d&&d.addRules({elements:{span:function(a){var c=a.hasClass(b.options.misspelled_word_class)&&a.attributes[b.options.data_attribute_name],d=a.hasClass(b.options.problem_grammar_class)&&a.attributes[b.options.problem_grammar_data_attribute];return b&&(c||d)&&delete a.name,a}}}),f&&f.call(a,h)},scaytMenuDefinition:function(a){var b=this;return a=a.scayt,{scayt:{scayt_ignore:{label:a.getLocal("btn_ignore"),group:"scayt_control",order:1,exec:function(a){a.scayt.ignoreWord()}},scayt_ignoreall:{label:a.getLocal("btn_ignoreAll"),group:"scayt_control",order:2,exec:function(a){a.scayt.ignoreAllWords()}},scayt_add:{label:a.getLocal("btn_addWord"),group:"scayt_control",order:3,exec:function(a){var b=a.scayt;setTimeout(function(){b.addWordToUserDictionary()},10)}},scayt_option:{label:a.getLocal("btn_options"),group:"scayt_control",order:4,exec:function(a){a.scayt.tabToOpen="options",a.lockSelection(),a.openDialog(b.dialogName)},verification:function(a){return 1==a.config.scayt_uiTabs[0]}},scayt_language:{label:a.getLocal("btn_langs"),group:"scayt_control",order:5,exec:function(a){a.scayt.tabToOpen="langs",a.lockSelection(),a.openDialog(b.dialogName)},verification:function(a){return 1==a.config.scayt_uiTabs[1]}},scayt_dictionary:{label:a.getLocal("btn_dictionaries"),group:"scayt_control",order:6,exec:function(a){a.scayt.tabToOpen="dictionaries",a.lockSelection(),a.openDialog(b.dialogName)},verification:function(a){return 1==a.config.scayt_uiTabs[2]}},scayt_about:{label:a.getLocal("btn_about"),group:"scayt_control",order:7,exec:function(a){a.scayt.tabToOpen="about",a.lockSelection(),a.openDialog(b.dialogName)}}},grayt:{grayt_problemdescription:{label:"Grammar problem description",group:"grayt_description",order:1,state:CKEDITOR.TRISTATE_DISABLED,exec:function(a){}},grayt_ignore:{label:a.getLocal("btn_ignore"),group:"grayt_control",order:2,exec:function(a){a.scayt.ignorePhrase()}}}}},buildSuggestionMenuItems:function(a,b,c){var d={},e={},f=c?"word":"phrase",g=c?"startGrammarCheck":"startSpellCheck",h=a.scayt;if(0<b.length&&"no_any_suggestions"!==b[0])if(c)for(c=0;c<b.length;c++){var i="scayt_suggest_"+CKEDITOR.plugins.scayt.suggestions[c].replace(" ","_");a.addCommand(i,this.createCommand(CKEDITOR.plugins.scayt.suggestions[c],f,g)),c<a.config.scayt_maxSuggestions?(a.addMenuItem(i,{label:b[c],command:i,group:"scayt_suggest",order:c+1}),d[i]=CKEDITOR.TRISTATE_OFF):(a.addMenuItem(i,{label:b[c],command:i,group:"scayt_moresuggest",order:c+1}),e[i]=CKEDITOR.TRISTATE_OFF,"on"===a.config.scayt_moreSuggestions&&(a.addMenuItem("scayt_moresuggest",{label:h.getLocal("btn_moreSuggestions"),group:"scayt_moresuggest",order:10,getItems:function(){return e}}),d.scayt_moresuggest=CKEDITOR.TRISTATE_OFF))}else for(c=0;c<b.length;c++)i="grayt_suggest_"+CKEDITOR.plugins.scayt.suggestions[c].replace(" ","_"),a.addCommand(i,this.createCommand(CKEDITOR.plugins.scayt.suggestions[c],f,g)),a.addMenuItem(i,{label:b[c],command:i,group:"grayt_suggest",order:c+1}),d[i]=CKEDITOR.TRISTATE_OFF;else d.no_scayt_suggest=CKEDITOR.TRISTATE_DISABLED,a.addCommand("no_scayt_suggest",{exec:function(){}}),a.addMenuItem("no_scayt_suggest",{label:h.getLocal("btn_noSuggestions")||"no_scayt_suggest",command:"no_scayt_suggest",group:"scayt_suggest",order:0});return d},menuGenerator:function(a,b){var h,i,c=a.scayt,d=this.scaytMenuDefinition(a),e={},f=a.config.scayt_contextCommands.split("|"),g=b.getAttribute(c.getLangAttribute())||c.getLang();if(h=c.isScaytNode(b),i=c.isGraytNode(b),h?(d=d.scayt,e=b.getAttribute(c.get
17ScaytNodeAttributeName()),c.fire("getSuggestionsList",{lang:g,word:e}),e=this.buildSuggestionMenuItems(a,CKEDITOR.plugins.scayt.suggestions,h)):i&&(d=d.grayt,e=b.getAttribute(c.getGraytNodeAttributeName()),i=c.getProblemDescriptionText(e,g),d.grayt_problemdescription&&i&&(d.grayt_problemdescription.label=i),c.fire("getGrammarSuggestionsList",{lang:g,phrase:e}),e=this.buildSuggestionMenuItems(a,CKEDITOR.plugins.scayt.suggestions,h)),h&&"off"==a.config.scayt_contextCommands)return e;for(var j in d)h&&-1==CKEDITOR.tools.indexOf(f,j.replace("scayt_",""))&&"all"!=a.config.scayt_contextCommands||(e[j]="undefined"!=typeof d[j].state?d[j].state:CKEDITOR.TRISTATE_OFF,"function"!=typeof d[j].verification||d[j].verification(a)||delete e[j],a.addCommand(j,{exec:d[j].exec}),a.addMenuItem(j,{label:a.lang.scayt[d[j].label]||d[j].label,command:j,group:d[j].group,order:d[j].order}));return e},createCommand:function(a,b,c){return{exec:function(d){d=d.scayt;var e={};e[b]=a,d.replaceSelectionNode(e),"startGrammarCheck"===c&&d.removeMarkupInSelectionNode({grammarOnly:!0}),d.fire(c)}}}}),CKEDITOR.plugins.scayt={state:{scayt:{},grayt:{}},suggestions:[],loadingHelper:{loadOrder:[]},isLoading:!1,options:{disablingCommandExec:{source:!0,newpage:!0,templates:!0},data_attribute_name:"data-scayt-word",misspelled_word_class:"scayt-misspell-word",problem_grammar_data_attribute:"data-grayt-phrase",problem_grammar_class:"gramm-problem"},backCompatibilityMap:{scayt_service_protocol:"scayt_serviceProtocol",scayt_service_host:"scayt_serviceHost",scayt_service_port:"scayt_servicePort",scayt_service_path:"scayt_servicePath",scayt_customerid:"scayt_customerId"},replaceOldOptionsNames:function(a){for(var b in a)b in this.backCompatibilityMap&&(a[this.backCompatibilityMap[b]]=a[b],delete a[b])},createScayt:function(a){var b=this,c=CKEDITOR.plugins.scayt;this.loadScaytLibrary(a,function(a){var d=a.window&&a.window.getFrame()||a.editable();d?(d={lang:a.config.scayt_sLang,container:d.$,customDictionary:a.config.scayt_customDictionaryIds,userDictionaryName:a.config.scayt_userDictionaryName,localization:a.langCode,customer_id:a.config.scayt_customerId,debug:a.config.scayt_debug,data_attribute_name:b.options.data_attribute_name,misspelled_word_class:b.options.misspelled_word_class,problem_grammar_data_attribute:b.options.problem_grammar_data_attribute,problem_grammar_class:b.options.problem_grammar_class,"options-to-restore":a.config.scayt_disableOptionsStorage,focused:a.editable().hasFocus,ignoreElementsRegex:a.config.scayt_elementsToIgnore,minWordLength:a.config.scayt_minWordLength,multiLanguageMode:a.config.scayt_multiLanguageMode,multiLanguageStyles:a.config.scayt_multiLanguageStyles,graytAutoStartup:c.state.grayt[a.name]},a.config.scayt_serviceProtocol&&(d.service_protocol=a.config.scayt_serviceProtocol),a.config.scayt_serviceHost&&(d.service_host=a.config.scayt_serviceHost),a.config.scayt_servicePort&&(d.service_port=a.config.scayt_servicePort),a.config.scayt_servicePath&&(d.service_path=a.config.scayt_servicePath),"boolean"==typeof a.config.scayt_ignoreAllCapsWords&&(d["ignore-all-caps-words"]=a.config.scayt_ignoreAllCapsWords),"boolean"==typeof a.config.scayt_ignoreDomainNames&&(d["ignore-domain-names"]=a.config.scayt_ignoreDomainNames),"boolean"==typeof a.config.scayt_ignoreWordsWithMixedCases&&(d["ignore-words-with-mixed-cases"]=a.config.scayt_ignoreWordsWithMixedCases),"boolean"==typeof a.config.scayt_ignoreWordsWithNumbers&&(d["ignore-words-with-numbers"]=a.config.scayt_ignoreWordsWithNumbers),d=new SCAYT.CKSCAYT(d,function(){},function(){}),d.subscribe("suggestionListSend",function(a){for(var b={},c=[],d=0;d<a.suggestionList.length;d++)b["word_"+a.suggestionList[d]]||(b["word_"+a.suggestionList[d]]=a.suggestionList[d],c.push(a.suggestionList[d]));CKEDITOR.plugins.scayt.suggestions=c}),d.subscribe("selectionIsChanged",function(b){a.getSelection().isLocked&&a.lockSelection()}),d.subscribe("graytStateChanged",function(b){c.state.grayt[a.name]=b.state}),a.scayt=d,a.fire("scaytButtonState",a.readOnly?CKEDITOR.TRISTATE_DISABLED:CKEDITOR.TRISTATE_ON)):c.state.scayt[a.name]=!1})},destroy:function(a){a.scayt&&a.scayt.destroy(),delete a.scayt,a.fire("scaytButtonState",CKEDITOR.TRISTATE_OFF)},loadScaytLibrary:function(a,b){var d,e,c=this;this.loadingHelper[a.name]||("undefined"==typeof window.SCAYT||"function"!=typeof window.SCAYT.CKSCAYT?(this.loadingHelper[a.name]=b,this.loadingHelper.loadOrder.push(a.name),d=new Date,d=d.getTime(),e=a.config.scayt_srcUrl,e+=0<=e.indexOf("?")?"":"?"+d,this.loadingHelper.ckscaytLoading||(CKEDITOR.scriptLoader.load(e,function(a){if
17(a){CKEDITOR.fireOnce("scaytReady");for(var b=0;b<c.loadingHelper.loadOrder.length;b++)a=c.loadingHelper.loadOrder[b],"function"==typeof c.loadingHelper[a]&&c.loadingHelper[a](CKEDITOR.instances[a]),delete c.loadingHelper[a];c.loadingHelper.loadOrder=[]}}),this.loadingHelper.ckscaytLoading=!0)):window.SCAYT&&"function"==typeof window.SCAYT.CKSCAYT&&(CKEDITOR.fireOnce("scaytReady"),a.scayt||"function"==typeof b&&b(a)))}},CKEDITOR.on("dialogDefinition",function(a){var b=a.data.name;a=a.data.definition.dialog,"scaytDialog"===b&&a.on("cancel",function(a){return!1},this,null,-1),"checkspell"===b&&a.on("cancel",function(a){a=a.sender&&a.sender.getParentEditor();var b=CKEDITOR.plugins.scayt,c=a.scayt;c&&b.state.scayt[a.name]&&c.setMarkupPaused&&c.setMarkupPaused(!1),a.unlockSelection()},this,null,-2),"link"===b&&a.on("ok",function(a){var b=a.sender&&a.sender.getParentEditor();b&&setTimeout(function(){b.fire("reloadMarkupScayt",{removeOptions:{removeInside:!0,forceBookmark:!0},timeout:0})},0)})}),CKEDITOR.on("scaytReady",function(){if(!0===CKEDITOR.config.scayt_handleCheckDirty){var a=CKEDITOR.editor.prototype;a.checkDirty=CKEDITOR.tools.override(a.checkDirty,function(a){return function(){var b=null,c=this.scayt;if(CKEDITOR.plugins.scayt&&CKEDITOR.plugins.scayt.state.scayt[this.name]&&this.scayt){if(b="ready"==this.status)var d=c.removeMarkupFromString(this.getSnapshot()),c=c.removeMarkupFromString(this._.previousValue),b=b&&c!==d}else b=a.call(this);return b}}),a.resetDirty=CKEDITOR.tools.override(a.resetDirty,function(a){return function(){var b=this.scayt;CKEDITOR.plugins.scayt&&CKEDITOR.plugins.scayt.state.scayt[this.name]&&this.scayt?this._.previousValue=b.removeMarkupFromString(this.getSnapshot()):a.call(this)}})}if(!0===CKEDITOR.config.scayt_handleUndoRedo){var a=CKEDITOR.plugins.undo.Image.prototype,b="function"==typeof a.equalsContent?"equalsContent":"equals";a[b]=CKEDITOR.tools.override(a[b],function(a){return function(b){var c=b.editor.scayt,d=this.contents,e=b.contents,f=null;return CKEDITOR.plugins.scayt&&CKEDITOR.plugins.scayt.state.scayt[b.editor.name]&&b.editor.scayt&&(this.contents=c.removeMarkupFromString(d)||"",b.contents=c.removeMarkupFromString(e)||""),f=a.apply(this,arguments),this.contents=d,b.contents=e,f}})}}),function(){CKEDITOR.plugins.add("stylescombo",{requires:"richcombo",init:function(a){var b=a.config,c=a.lang.stylescombo,d={},e=[],f=[];a.on("stylesSet",function(c){if(c=c.data.styles){for(var g,h,i,j=0,k=c.length;j<k;j++)g=c[j],a.blockless&&g.element in CKEDITOR.dtd.$block||(h=g.name,g=new CKEDITOR.style(g),a.filter.customConfig&&!a.filter.check(g))||(g._name=h,g._.enterMode=b.enterMode,g._.type=i=g.assignedTo||g.type,g._.weight=j+1e3*(i==CKEDITOR.STYLE_OBJECT?1:i==CKEDITOR.STYLE_BLOCK?2:3),d[h]=g,e.push(g),f.push(g));e.sort(function(a,b){return a._.weight-b._.weight})}}),a.ui.addRichCombo("Styles",{label:c.label,title:c.panelTitle,toolbar:"styles,10",allowedContent:f,panel:{css:[CKEDITOR.skin.getPath("editor")].concat(b.contentsCss),multiSelect:!0,attributes:{"aria-label":c.panelTitle}},init:function(){var a,b,d,f,g,h;for(g=0,h=e.length;g<h;g++)a=e[g],b=a._name,f=a._.type,f!=d&&(this.startGroup(c["panelTitle"+String(f)]),d=f),this.add(b,a.type==CKEDITOR.STYLE_OBJECT?b:a.buildPreview(),b);this.commit()},onClick:function(b){a.focus(),a.fire("saveSnapshot"),b=d[b];var c=a.elementPath();a[b.checkActive(c,a)?"removeStyle":"applyStyle"](b),a.fire("saveSnapshot")},onRender:function(){a.on("selectionChange",function(b){var c=this.getValue();b=b.data.path.elements;for(var g,e=0,f=b.length;e<f;e++){g=b[e];for(var h in d)if(d[h].checkElementRemovable(g,!0,a))return void(h!=c&&this.setValue(h))}this.setValue("")},this)},onOpen:function(){var b=a.getSelection().getSelectedElement(),b=a.elementPath(b),e=[0,0,0,0];this.showAll(),this.unmarkAll();for(var f in d){var g=d[f],h=g._.type;g.checkApplicable(b,a,a.activeFilter)?e[h]++:this.hideItem(f),g.checkActive(b,a)&&this.mark(f)}e[CKEDITOR.STYLE_BLOCK]||this.hideGroup(c["panelTitle"+String(CKEDITOR.STYLE_BLOCK)]),e[CKEDITOR.STYLE_INLINE]||this.hideGroup(c["panelTitle"+String(CKEDITOR.STYLE_INLINE)]),e[CKEDITOR.STYLE_OBJECT]||this.hideGroup(c["panelTitle"+String(CKEDITOR.STYLE_OBJECT)])},refresh:function(){var b=a.elementPath();if(b){for(var c in d)if(d[c].checkApplicable(b,a,a.activeFilter))return;this.setState(CKEDITOR.TRISTATE_DISABLED)}},reset:function(){d={},e=[]}})}})}(),function(){function a(a){return{editorFocus:!1,canUndo:!1,modes:{wysiwyg:1},exec:function(b){if(b.editable().hasFocus){var d,c=b.getSelection();if(d=new CKEDITOR.dom.elementPath(c.getCommonAncestor(),c.root).contains({td:1,th:1},1)){var c=b.createRange(),e=CKEDITOR.tools.tryThese(function(){var b=d.getParent().$.cells[d.$.cellIndex+(a?-1:1)];return b.parentNode.parentNode,b},function(){var b=d.getParent(),b=b.getAscendant("table").$.rows[b.$.rowIndex+(a?-1:1)];return b.cells[a?b.cells.length-1:0]});if(e||a){if(!e)return!0;
17e=new CKEDITOR.dom.element(e),c.moveToElementEditStart(e),c.checkStartOfBlock()&&c.checkEndOfBlock()||c.selectNodeContents(e)}else{for(var f=d.getAscendant("table").$,e=d.getParent().$.cells,f=new CKEDITOR.dom.element(f.insertRow(-1),b.document),g=0,h=e.length;g<h;g++)f.append(new CKEDITOR.dom.element(e[g],b.document).clone(!1,!1)).appendBogus();c.moveToElementEditStart(f)}return c.select(!0),!0}}return!1}}}var b={editorFocus:!1,modes:{wysiwyg:1,source:1}},c={exec:function(a){a.container.focusNext(!0,a.tabIndex)}},d={exec:function(a){a.container.focusPrevious(!0,a.tabIndex)}};CKEDITOR.plugins.add("tab",{init:function(e){for(var f=!1!==e.config.enableTabKeyTools,g=e.config.tabSpaces||0,h="";g--;)h+="Â ";h&&e.on("key",function(a){9==a.data.keyCode&&(e.insertText(h),a.cancel())}),f&&e.on("key",function(a){(9==a.data.keyCode&&e.execCommand("selectNextCell")||a.data.keyCode==CKEDITOR.SHIFT+9&&e.execCommand("selectPreviousCell"))&&a.cancel()}),e.addCommand("blur",CKEDITOR.tools.extend(c,b)),e.addCommand("blurBack",CKEDITOR.tools.extend(d,b)),e.addCommand("selectNextCell",a()),e.addCommand("selectPreviousCell",a(!0))}})}(),CKEDITOR.dom.element.prototype.focusNext=function(a,b){var d,e,f,g,h,i,c=void 0===b?this.getTabIndex():b;if(0>=c)for(h=this.getNextSourceNode(a,CKEDITOR.NODE_ELEMENT);h;){if(h.isVisible()&&0===h.getTabIndex()){f=h;break}h=h.getNextSourceNode(!1,CKEDITOR.NODE_ELEMENT)}else for(h=this.getDocument().getBody().getFirst();h=h.getNextSourceNode(!1,CKEDITOR.NODE_ELEMENT);){if(!d)if(!e&&h.equals(this)){if(e=!0,a){if(!(h=h.getNextSourceNode(!0,CKEDITOR.NODE_ELEMENT)))break;d=1}}else e&&!this.contains(h)&&(d=1);if(h.isVisible()&&!(0>(i=h.getTabIndex()))){if(d&&i==c){f=h;break}i>c&&(!f||!g||i<g)?(f=h,g=i):f||0!==i||(f=h,g=i)}}f&&f.focus()},CKEDITOR.dom.element.prototype.focusPrevious=function(a,b){for(var d,e,f,h,c=void 0===b?this.getTabIndex():b,g=0,i=this.getDocument().getBody().getLast();i=i.getPreviousSourceNode(!1,CKEDITOR.NODE_ELEMENT);){if(!d)if(!e&&i.equals(this)){if(e=!0,a){if(!(i=i.getPreviousSourceNode(!0,CKEDITOR.NODE_ELEMENT)))break;d=1}}else e&&!this.contains(i)&&(d=1);if(i.isVisible()&&!(0>(h=i.getTabIndex())))if(0>=c){if(d&&0===h){f=i;break}h>g&&(f=i,g=h)}else{if(d&&h==c){f=i;break}h<c&&(!f||h>g)&&(f=i,g=h)}}f&&f.focus()},CKEDITOR.plugins.add("table",{requires:"dialog",init:function(a){function b(a){return CKEDITOR.tools.extend(a||{},{contextSensitive:1,refresh:function(a,b){this.setState(b.contains("table",1)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED)}})}if(!a.blockless){var c=a.lang.table;a.addCommand("table",new CKEDITOR.dialogCommand("table",{context:"table",allowedContent:"table{width,height}[align,border,cellpadding,cellspacing,summary];caption tbody thead tfoot;th td tr[scope];"+(a.plugins.dialogadvtab?"table"+a.plugins.dialogadvtab.allowedContent():""),requiredContent:"table",contentTransformations:[["table{width}: sizeToStyle","table[width]: sizeToAttribute"]]})),a.addCommand("tableProperties",new CKEDITOR.dialogCommand("tableProperties",b())),a.addCommand("tableDelete",b({exec:function(a){var b=a.elementPath().contains("table",1);if(b){var c=b.getParent(),d=a.editable();1!=c.getChildCount()||c.is("td","th")||c.equals(d)||(b=c),a=a.createRange(),a.moveToPosition(b,CKEDITOR.POSITION_BEFORE_START),b.remove(),a.select()}}})),a.ui.addButton&&a.ui.addButton("Table",{label:c.toolbar,command:"table",toolbar:"insert,30"}),CKEDITOR.dialog.add("table",this.path+"dialogs/table.js"),CKEDITOR.dialog.add("tableProperties",this.path+"dialogs/table.js"),a.addMenuItems&&a.addMenuItems({table:{label:c.menu,command:"tableProperties",group:"table",order:5},tabledelete:{label:c.deleteTable,command:"tableDelete",group:"table",order:1}}),a.on("doubleclick",function(a){a.data.element.is("table")&&(a.data.dialog="tableProperties")}),a.contextMenu&&a.contextMenu.addListener(function(){return{tabledelete:CKEDITOR.TRISTATE_OFF,table:CKEDITOR.TRISTATE_OFF}})}}}),function(){function a(a){function b(a){0<c.length||a.type!=CKEDITOR.NODE_ELEMENT||!m.test(a.getName())||a.getCustomData("selected_cell")||(CKEDITOR.dom.element.setMarker(d,a,"selected_cell",!0),c.push(a))}a=a.getRanges();for(var c=[],d={},e=0;e<a.length;e++){var f=a[e];if(f.collapsed)f=f.getCommonAncestor(),(f=f.getAscendant("td",!0)||f.getAscendant("th",!0))&&c.push(f);else{var g,f=new CKEDITOR.dom.walker(f);for(f.guard=b;g=f.next();)g.type==CKEDITOR.NODE_ELEMENT&&g.is(CKEDITOR.dtd.table)||(g=g.getAscendant("td",!0)||g.getAscendant("th",!0))&&!g.getCustomData("selected_cell")&&(CKEDITOR.dom.element.setMarker(d,g,"selected_cell",!0),c.push(g))}}return CKEDITOR.dom.element.clearAllMarkers(d),c}function b(b,c){for(var d=a(b),e=d[0],f=e.getAscendant("table"),e=e.getDocument(),g=d[0].getParent(),h=g.$.rowIndex,d=d[d.length-1],i=d.getParent().$.rowIndex+d.$.rowSpan-1,d=new CKEDITOR.dom.element(f.$.rows[i]),h=c?h:i,g=c?g
17:d,d=CKEDITOR.tools.buildTableMap(f),f=d[h],h=c?d[h-1]:d[h+1],d=d[0].length,e=e.createElement("tr"),i=0;f[i]&&i<d;i++){var j;1<f[i].rowSpan&&h&&f[i]==h[i]?(j=f[i],j.rowSpan+=1):(j=new CKEDITOR.dom.element(f[i]).clone(),j.removeAttribute("rowSpan"),j.appendBogus(),e.append(j),j=j.$),i+=j.colSpan-1}c?e.insertBefore(g):e.insertAfter(g)}function c(b){if(b instanceof CKEDITOR.dom.selection){var d=a(b),e=d[0].getAscendant("table"),f=CKEDITOR.tools.buildTableMap(e);b=d[0].getParent().$.rowIndex;for(var d=d[d.length-1],g=d.getParent().$.rowIndex+d.$.rowSpan-1,d=[],h=b;h<=g;h++){for(var i=f[h],j=new CKEDITOR.dom.element(e.$.rows[h]),k=0;k<i.length;k++){var l=new CKEDITOR.dom.element(i[k]),m=l.getParent().$.rowIndex;1==l.$.rowSpan?l.remove():(--l.$.rowSpan,m==h&&(m=f[h+1],m[k-1]?l.insertAfter(new CKEDITOR.dom.element(m[k-1])):new CKEDITOR.dom.element(e.$.rows[h+1]).append(l,1))),k+=l.$.colSpan-1}d.push(j)}for(f=e.$.rows,e=new CKEDITOR.dom.element(f[g+1]||(0<b?f[b-1]:null)||e.$.parentNode),h=d.length;0<=h;h--)c(d[h]);return e}return b instanceof CKEDITOR.dom.element&&(e=b.getAscendant("table"),1==e.$.rows.length?e.remove():b.remove()),null}function d(a,b){for(var c=b?1/0:0,d=0;d<a.length;d++){var e;e=a[d];for(var f=b,g=e.getParent().$.cells,h=0,i=0;i<g.length;i++){var j=g[i],h=h+(f?1:j.colSpan);if(j==e.$)break}e=h-1,(b?e<c:e>c)&&(c=e)}return c}function e(b,c){for(var e=a(b),f=e[0].getAscendant("table"),g=d(e,1),e=d(e),g=c?g:e,h=CKEDITOR.tools.buildTableMap(f),f=[],e=[],i=h.length,j=0;j<i;j++)f.push(h[j][g]),e.push(c?h[j][g-1]:h[j][g+1]);for(j=0;j<i;j++)f[j]&&(1<f[j].colSpan&&e[j]==f[j]?(g=f[j],g.colSpan+=1):(g=new CKEDITOR.dom.element(f[j]).clone(),g.removeAttribute("colSpan"),g.appendBogus(),g[c?"insertBefore":"insertAfter"].call(g,new CKEDITOR.dom.element(f[j])),g=g.$),j+=g.rowSpan-1)}function f(a,b){var c=a.getStartElement();if(c=c.getAscendant("td",1)||c.getAscendant("th",1)){var d=c.clone();d.appendBogus(),b?d.insertBefore(c):d.insertAfter(c)}}function g(b){if(b instanceof CKEDITOR.dom.selection){b=a(b);var d,c=b[0]&&b[0].getAscendant("table");a:{var e=0;d=b.length-1;for(var i,j,f={};i=b[e++];)CKEDITOR.dom.element.setMarker(f,i,"delete_cell",!0);for(e=0;i=b[e++];)if((j=i.getPrevious())&&!j.getCustomData("delete_cell")||(j=i.getNext())&&!j.getCustomData("delete_cell")){CKEDITOR.dom.element.clearAllMarkers(f),d=j;break a}CKEDITOR.dom.element.clearAllMarkers(f),j=b[0].getParent(),(j=j.getPrevious())?d=j.getLast():(j=b[d].getParent(),d=(j=j.getNext())?j.getChild(0):null)}for(j=b.length-1;0<=j;j--)g(b[j]);d?h(d,!0):c&&c.remove()}else b instanceof CKEDITOR.dom.element&&(c=b.getParent(),1==c.getChildCount()?c.remove():b.remove())}function h(a,b){var c=a.getDocument(),d=CKEDITOR.document;CKEDITOR.env.ie&&10==CKEDITOR.env.version&&(d.focus(),c.focus()),c=new CKEDITOR.dom.range(c),c["moveToElementEdit"+(b?"End":"Start")](a)||(c.selectNodeContents(a),c.collapse(!b)),c.select(!0)}function i(a,b,c){if(a=a[b],"undefined"==typeof c)return a;for(b=0;a&&b<a.length;b++){if(c.is&&a[b]==c.$)return b;if(b==c)return new CKEDITOR.dom.element(a[b])}return c.is?-1:null}function j(b,c,d){var f,e=a(b);if((c?1!=e.length:2>e.length)||(f=b.getCommonAncestor())&&f.type==CKEDITOR.NODE_ELEMENT&&f.is("table"))return!1;var g;b=e[0],f=b.getAscendant("table");var h=CKEDITOR.tools.buildTableMap(f),j=h.length,k=h[0].length,l=b.getParent().$.rowIndex,m=i(h,l,b);if(c){var n;try{var o=parseInt(b.getAttribute("rowspan"),10)||1;g=parseInt(b.getAttribute("colspan"),10)||1,n=h["up"==c?l-o:"down"==c?l+o:l]["left"==c?m-g:"right"==c?m+g:m]}catch(a){return!1}if(!n||b.$==n)return!1;e["up"==c||"left"==c?"unshift":"push"](new CKEDITOR.dom.element(n))}c=b.getDocument();var p=l,o=n=0,q=!d&&new CKEDITOR.dom.documentFragment(c),r=0;for(c=0;c<e.length;c++){g=e[c];var s=g.getParent(),t=g.getFirst(),u=g.$.colSpan,v=g.$.rowSpan,s=s.$.rowIndex,w=i(h,s,g),r=r+u*v,o=Math.max(o,w-m+u);n=Math.max(n,s-l+v),d||(u=g,(v=u.getBogus())&&v.remove(),u.trim(),g.getChildren().count()&&(s==p||!t||t.isBlockBoundary&&t.isBlockBoundary({br:1})||(p=q.getLast(CKEDITOR.dom.walker.whitespaces(!0)),!p||p.is&&p.is("br")||q.append("br")),g.moveChildren(q)),c?g.remove():g.setHtml("")),p=s}if(d)return n*o==r;for(q.moveChildren(b),b.appendBogus(),o>=k?b.removeAttribute("rowSpan"):b.$.rowSpan=n,n>=j?b.removeAttribute("colSpan"):b.$.colSpan=o,d=new CKEDITOR.dom.nodeList(f.$.rows),e=d.count(),c=e-1;0<=c;c--)f=d.getItem(c),f.$.cells.length||(f.remove(),e++);return b}function k(b,c){var d=a(b);if(1<d.length)return!1;if(c)return!0;var l,d=d[0],e=d.getParent(),f=e.getAscendant("table"),g=CKEDITOR.tools.buildTableMap(f),h=e.$.rowIndex,j=i(g,h,d),k=d.$.rowSpan;if(1<k){l=Math.ceil(k/2);for(var m,k=Math.floor(k/2),e=h+l,f=new CKEDITOR.dom.element(f.$.rows[e]),g=i(g,e),e=d.clone(),h=0;h<g.length;h++){if(m=g[h],m.parentNode==f.$&&h>j){e.insertBefore(new CKEDITOR.dom.element(m));break}m=null}m||f.append(e)}else for(k=l=1,f=e.clone(),f.insertAfter(e),f.append(e=d.clone()),m=i(g,h),j=0;j<m.length;j++)m[j].rowSpan++;return e.appendBogus(),d.$.rowSpan=l,e.$.rowSpan=k,1==l&&d.removeAttribute("rowSpan"),1==k&&e.removeAttribute("rowSpan"),e}function l(b,c){var d=a(b);if(1<d.length)return!1;if(c)return!0;var d=d[0],e=d.getParent(),f=e.getAscendant("table"),f=CKEDITOR.tools.buildTableMap(f),g=i(f,e.$.rowIndex,d),h=d.$.colSpan;if(1<h)e=Math.ceil(h/2),h=Math.floor(h/2);else{for(var h=e=1,j=[],k=0;k<f.length;k++){var l=f[k];j.push(l[g]),1<l[g].rowSpan&&(k+=l[g].rowSpan-1)}for(f=0;f<j.length;f++)j[f].colSpan++}return f=d.clone(),f.insertAfter(d),f.appendBogus(),d.$.colSpan=e,f.$.colSpan=h,1==e&&d.removeAttribute("colSpan"),1==h&&f.removeAttribute("colSpan"),f}var m=/^(?:td|th)$/;CKEDITOR.plugins.tabletools={requires:"table,dialog,contextmenu",init:function(d){function i(a){return CKEDITOR.tools.extend(a||{},{contextSensitive:1,refresh:function(a,b){this.setState(b.contains({td:1,th:1},1)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED)}})}function m(a,b){var c=d.addCommand(a,b);d.addFeature(c)}var n=d.lang.table;m("cellProperties",new CKEDITOR.dialogCommand("cellProperties",i({allowedContent:"td th{width,height,border-color,background-color,white-space,vertical-align,text-align}[colspan,rowspan]",requiredContent:"table"}))),CKEDITOR.dialog.add("cellProperties",this.path+"dialogs/tableCell.js"),m("rowDelete",i({requiredContent:"table",exec:function(a){a=a.getSelection(),h(c(a))}})),m("rowInsertBefore",i({requiredContent:"table",exec:function(a){a=a.getSelection(),b(a,!0)}})),m("rowInsertAfter",i({requiredContent:"table",exec:function(a){a=a.getSelection(),b(a)}})),m("columnDelete",i({requiredContent:"table",exec:function(b){b=b.getSelection(),b=a(b);var c=b[0],d=b[b.length-1];b=c.getAscendant("table");for(var f,g,e=CKEDITOR.tools.buildTableMap(b),i=[],j=0,k=e.length;j<k;j++)for(var l=0,m=e[j].length;l<m;l++)e[j][l]==c.$&&(f=l),e[j][l]==d.$&&(g=l);for(j=f;j<=g;j++)for(l=0;l<e.length;l++)d=e[l],c=new CKEDITOR.dom.element(b.$.rows[l]),d=new CKEDITOR.dom.element(d[j]),d.$&&(1==d.$.colSpan?d.remove():--d.$.colSpan,l+=d.$.rowSpan-1,c.$.cells.length||i.push(c));g=b.$.rows[0]&&b.$.rows[0].cells,f=new CKEDITOR.dom.element(g[f]||(f?g[f-1]:b.$.parentNode)),i.length==k&&b.remove(),f&&h(f,!0)}})),m("columnInsertBefore",i({requiredContent:"table",exec:function(a){a=a.getSelection(),e(a,!0)}})),m("columnInsertAfter",i({requiredContent:"table",exec:function(a){a=a.getSelection(),e(a)}})),m("cellDelete",i({requiredContent:"table",exec:function(a){a=a.getSelection(),g(a)}})),m("cellMerge",i({allowedContent:"td[colspan,rowspan]",requiredContent:"td[colspan,rowspan]",exec:function(a){h(j(a.getSelection()),!0)}})),m("cellMergeRight",i({allowedContent:"td[colspan]",requiredContent:"td[colspan]",exec:function(a){h(j(a.getSelection(),"right"),!0)}})),m("cellMergeDown",i({allowedContent:"td[rowspan]",requiredContent:"td[rowspan]",exec:function(a){h(j(a.getSelection(),"down"),!0)}})),m("cellVerticalSplit",i({allowedContent:"td[rowspan]",requiredContent:"td[rowspan]",exec:function(a){h(l(a.getSelection()))}})),m("cellHorizontalSplit",i({allowedContent:"td[colspan]",requiredContent:"td[colspan]",exec:function(a){h(k(a.getSelection()))}})),m("cellInsertBefore",i({requiredContent:"table",exec:function(a){a=a.getSelection(),f(a,!0)}})),m("cellInsertAfter",i({requiredContent:"table",exec:function(a){a=a.getSelection(),f(a)}})),d.addMenuItems&&d.addMenuItems({tablecell:{label:n.cell.menu,group:"tablecell",order:1,getItems:function(){var b=d.getSelection(),c=a(b);return{tablecell_insertBefore:CKEDITOR.TRISTATE_OFF,tablecell_insertAfter:CKEDITOR.TRISTATE_OFF,tablecell_delete:CKEDITOR.TRISTATE_OFF,tablecell_merge:j(b,null,!0)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,tablecell_merge_right:j(b,"right",!0)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,tablecell_merge_down:j(b,"down",!0)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,tablecell_split_vertical:l(b,!0)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,tablecell_split_horizontal:k(b,!0)?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED,tablecell_properties:0<c.length?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED}}},tablecell_insertBefore:{label:n.cell.insertBefore,group:"tablecell",command:"cellInsertBefore",order:5},tablecell_insertAfter:{label:n.cell.insertAfter,group:"tablecell",command:"cellInsertAfter",order:10},tablecell_delete:{label:n.cell.deleteCell,group:"tablecell",command:"cellDelete",order:15},tablecell_merge:{label:n.cell.merge,group:"tablecell",command:"cellMerge",order:16},tablecell_merge_right:{label:n.cell.mergeRight,group:"tablecell",command:"cellMergeRight",order:17},tablecell_merge_down:{label:n.cell.mergeDown,group:"tablecell",command:"cellMergeDown",order:18},tablecell_split_horizontal:{label:n.cell.splitHorizontal,group:"tablecell",command:"cellHorizontalSplit",order:19},tablecell_split_vertical:{label:n.cell.splitVertical,group:"tablecell",command:"cellVerticalSplit",order:20},tablecell_properties:{label:n.cell.title,group:"tablecellproperties",command:"cellProperties",order:21},tablerow:{label:n.row.menu,group:"tablerow",order:1,getItems:function(){return{tablerow_insertBefore:CKEDITOR.TRISTATE_OFF,tablerow_insertAfter:CKEDITOR.TRISTATE_OFF,tablerow_delete:CKEDITOR.TRISTATE_OFF}}},tablerow_insertBefore:{label:n.row.insertBefore,group:"tablerow",command:"rowInsertBefore",order:5},tablerow_insertAfter:{label:n.row.insertAfter,group:"tablerow",command:"rowInsertAfter",order:10},tablerow_delete:{label:n.row.deleteRow,group:"tablerow",command:"rowDelete",order:15},tablecolumn:{label:n.column.menu,group:"tablecolumn",order:1,getItems:function(){return{tablecolumn_insertBefore:CKEDITOR.TRISTATE_OFF,tablecolumn_insertAfter:CKEDITOR.TRISTATE_OFF,tablecolumn_delete:CKEDITOR.TRISTATE_OFF}}},tablecolumn_insertBefore:{label:n.column.insertBefore,group:"tablecolumn",command:"columnInsertBefore",order:5},tablecolumn_insertAfter:{label:n.column.insertAfter,group:"tablecolumn",command:"columnInsertAfter",order:10},tablecolumn_delete:{label:n.column.deleteColumn,group:"tablecolumn",command:"columnDelete",order:15}}),d.contextMenu&&d.contextMenu.addListener(function(a,b,c){return(a=c.contains({td:1,th:1},1))&&!a.isReadOnly()?{tablecell:CKEDITOR.TRISTATE_OFF,tablerow:CKEDITOR.TRISTATE_OFF,tablecolumn:CKEDITOR.TRISTATE_OFF}:null})},getSelectedCells:a},CKEDITOR.plugins.add("tabletools",CKEDITOR.plugins.tabletools)}(),CKEDITOR.tools.buildTableMap=function(a){a=a.$.rows;for(var b=-1,c=[],d=0;d<a.length;d++){b++,!c[b]&&(c[b]=[]);for(var e=-1,f=0;f<a[d].cells.length;f++){var g=a[d].cells[f];for(e++;c[b][e];)e++;for(var h=isNaN(g.colSpan)?1:g.colSpan,g=isNaN(g.rowSpan)?1:g.rowSpan,i=0;i<g;i++){c[b+i]||(c[b+i]=[]);for(var j=0;j<h;j++)c[b+i][e+j]=a[d].cells[f]}e+=h-1}}return c},function(){var a=[CKEDITOR.CTRL+90,CKEDITOR.CTRL+89,CKEDITOR.CTRL+CKEDITOR.SH
17IFT+90],b={8:1,46:1};CKEDITOR.plugins.add("undo",{init:function(b){function d(a){g.enabled&&!1!==a.data.command.canUndo&&g.save()}function e(){g.enabled=!b.readOnly&&"wysiwyg"==b.mode,g.onChange()}var g=b.undoManager=new c(b),h=g.editingHandler=new f(g),i=b.addCommand("undo",{exec:function(){g.undo()&&(b.selectionChange(),this.fire("afterUndo"))},startDisabled:!0,canUndo:!1}),j=b.addCommand("redo",{exec:function(){g.redo()&&(b.selectionChange(),this.fire("afterRedo"))},startDisabled:!0,canUndo:!1});b.setKeystroke([[a[0],"undo"],[a[1],"redo"],[a[2],"redo"]]),g.onChange=function(){i.setState(g.undoable()?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED),j.setState(g.redoable()?CKEDITOR.TRISTATE_OFF:CKEDITOR.TRISTATE_DISABLED)},b.on("beforeCommandExec",d),b.on("afterCommandExec",d),b.on("saveSnapshot",function(a){g.save(a.data&&a.data.contentOnly)}),b.on("contentDom",h.attachListeners,h),b.on("instanceReady",function(){b.fire("saveSnapshot")}),b.on("beforeModeUnload",function(){"wysiwyg"==b.mode&&g.save(!0)}),b.on("mode",e),b.on("readOnly",e),b.ui.addButton&&(b.ui.addButton("Undo",{label:b.lang.undo.undo,command:"und
17o",toolbar:"undo,10"}),b.ui.addButton("Redo",{label:b.lang.undo.redo,command:"redo",toolbar:"undo,20"})),b.resetUndo=function(){g.reset(),b.fire("saveSnapshot")},b.on("updateSnapshot",function(){g.currentImage&&g.update()}),b.on("lockSnapshot",function(a){a=a.data,g.lock(a&&a.dontUpdate,a&&a.forceUpdate)}),b.on("unlockSnapshot",g.unlock,g)}}),CKEDITOR.plugins.undo={};var c=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()};c.prototype={type:function(a,b){var d=c.getKeyGroup(a),e=this.strokesRecorded[d]+1;b=b||e>=this.strokesLimit,this.typing||(this.hasUndo=this.typing=!0,this.hasRedo=!1,this.onChange()),b?(e=0,this.editor.fire("saveSnapshot")):this.editor.fire("change"),this.strokesRecorded[d]=e, 18this.previousKeyGroup=d},keyGroupChanged:function(a){return c.getKeyGroup(a)!=this.previousKeyGroup},reset:function(){this.snapshots=[],this.index=-1,this.currentImage=null,this.hasRedo=this.hasUndo=!1,this.locked=null,this.resetType()},resetType:function(){this.strokesRecorded=[0,0],this.typing=!1,this.previousKeyGroup=-1},refreshState:function(){this.hasUndo=!!this.getNextImage(!0),this.hasRedo=!!this.getNextImage(!1),this.resetType(),this.onChange()},save:function(a,b,c){var e=this.editor;if(this.locked||"ready"!=e.status||"wysiwyg"!=e.mode)return!1;var f=e.editable();if(!f||"ready"!=f.status)return!1;if(f=this.snapshots,b||(b=new d(e)),!1===b.contents)return!1;if(this.currentImage)if(b.equalsContent(this.currentImage)){if(a||b.equalsSelection(this.currentImage))return!1}else!1!==c&&e.fire("change");return 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,!1!==c&&this.refreshState(),!0},restoreImage:function(a){var c,b=this.editor;a.bookmarks&&(b.focus(),c=b.getSelection()),this.locked={level:999},this.editor.loadSnapshot(a.contents),a.bookmarks?c.selectBookmarks(a.bookmarks):CKEDITOR.env.ie&&(c=this.editor.document.getBody().$.createTextRange(),c.collapse(!0),c.select()),this.locked=null,this.index=a.index,this.currentImage=this.snapshots[this.index],this.update(),this.refreshState(),b.fire("change")},getNextImage:function(a){var d,b=this.snapshots,c=this.currentImage;if(c)if(a){for(d=this.index-1;0<=d;d--)if(a=b[d],!c.equalsContent(a))return a.index=d,a}else for(d=this.index+1;d<b.length;d++)if(a=b[d],!c.equalsContent(a))return a.index=d,a;return null},redoable:function(){return this.enabled&&this.hasRedo},undoable:function(){return this.enabled&&this.hasUndo},undo:function(){if(this.undoable()){this.save(!0);var a=this.getNextImage(!0);if(a)return this.restoreImage(a),!0}return!1},redo:function(){if(this.redoable()&&(this.save(!0),this.redoable())){var a=this.getNextImage(!1);if(a)return this.restoreImage(a),!0}return!1},update:function(a){if(!this.locked){a||(a=new d(this.editor));for(var b=this.index,c=this.snapshots;0<b&&this.currentImage.equalsContent(c[b-1]);)--b;c.splice(b,this.index-b+1,a),this.index=b,this.currentImage=a}},updateSelection:function(a){if(!this.snapshots.length)return!1;var b=this.snapshots,c=b[b.length-1];return!(!c.equalsContent(a)||c.equalsSelection(a))&&(this.currentImage=b[b.length-1]=a,!0)},lock:function(a,b){if(this.locked)this.locked.level++;else if(a)this.locked={level:1};else{var c=null;if(b)c=!0;else{var e=new d(this.editor,(!0));this.currentImage&&this.currentImage.equalsContent(e)&&(c=e)}this.locked={update:c,level:1}}},unlock:function(){if(this.locked&&!--this.locked.level){var a=this.locked.update;if(this.locked=null,!0===a)this.update();else if(a){var b=new d(this.editor,(!0));a.equalsContent(b)||this.update()}}}},c.navigationKeyCodes={37:1,38:1,39:1,40:1,36:1,35:1,33:1,34:1},c.keyGroups={PRINTABLE:0,FUNCTIONAL:1},c.isNavigationKey=function(a){return!!c.navigationKeyCodes[a]},c.getKeyGroup=function(a){var d=c.keyGroups;return b[a]?d.FUNCTIONAL:d.PRINTABLE},c.getOppositeKeyGroup=function(a){var b=c.keyGroups;return a==b.FUNCTIONAL?b.PRINTABLE:b.FUNCTIONAL},c.ieFunctionalKeysBug=function(a){return CKEDITOR.env.ie&&c.getKeyGroup(a)==c.keyGroups.FUNCTIONAL};var d=CKEDITOR.plugins.undo.Image=function(a,b){this.editor=a,a.fire("beforeUndoImage");var c=a.getSnapshot();CKEDITOR.env.ie&&c&&(c=c.replace(/\s+data-cke-expando=".*?"/g,"")),this.contents=c,b||(this.bookmarks=(c=c&&a.getSelection())&&c.createBookmarks2(!0)),a.fire("afterUndoImage")},e=/\b(?:href|src|name)="[^"]*?"/gi;d.prototype={equalsContent:function(a){var b=this.contents;return a=a.contents,CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)&&(b=b.replace(e,""),a=a.replace(e,"")),b==a},equalsSelection:function(a){var b=this.bookmarks;if(a=a.bookmarks,b||a){if(!b||!a||b.length!=a.length)return!1;for(var c=0;c<b.length;c++){var d=b[c],e=a[c];if(d.startOffset!=e.startOffset||d.endOffset!=e.endOffset||!CKEDITOR.tools.arrayCompare(d.start,e.start)||!CKEDITOR.tools.arrayCompare(d.end,e.end))return!1}}return!0}};var f=CKEDITOR.plugins.undo.NativeEditingHandler=function(a){this.undoManager=a,this.ignoreInputEvent=!1,this.keyEventsStack=new g,this.lastKeydownImage=null};f.prototype={onKeydown:function(b){var e=b.data.getKey();229!==e&&(-1<CKEDITOR.tools.indexOf(a,b.data.getKeystroke())?b.data.preventDefault():(this.keyEventsStack.cleanUp(b),b=this.undoManager,this.keyEventsStack.getLast(e)||this.keyEventsStack.push(e),this.lastKeydownImage=new d(b.editor),(c.isNavigationKey(e)||this.undoManager.keyGroupChanged(e))&&(b.strokesRecorded[0]||b.strokesRecorded[1])&&(b.save(!1,this.lastKeydownImage,!1),b.resetType())))},onInput:function(){if(this.ignoreInputEvent)this.ignoreInputEvent=!1;else{var a=this.keyEventsStack.getLast();a||(a=this.keyEventsStack.push(0)),this.keyEventsStack.increment(a.keyCode),this.keyEventsStack.getTotalInputs()>=this.undoManager.strokesLimit&&(this.undoManager.type(a.keyCode,!0),this.keyEventsStack.resetInputs())}},onKeyup:function(a){var b=this.undoManager;a=a.data.getKey();var e=this.keyEventsStack.getTotalInputs();this.keyEventsStack.remove(a),c.ieFunctionalKeysBug(a)&&this.lastKeydownImage&&this.lastKeydownImage.equalsContent(new d(b.editor,(!0)))||(0<e?b.type(a):c.isNavigationKey(a)&&this.onNavigationKey(!0))},onNavigationKey:function(a){var b=this.undoManager;!a&&b.save(!0,null,!1)||b.updateSelection(new d(b.editor)),b.resetType()},ignoreInputEventListener:function(){this.ignoreInputEvent=!0},attachListeners:function(){var a=this.undoManager.editor,b=a.editable(),d=this;b.attachListener(b,"keydown",function(a){d.onKeydown(a),c.ieFunctionalKeysBug(a.data.getKey())&&d.onInput()},null,null,999),b.attachListener(b,CKEDITOR.env.ie?"keypress":"input",d.onInput,d,null,999),b.attachListener(b,"keyup",d.onKeyup,d,null,999),b.attachListener(b,"paste",d.ignoreInputEventListener,d,null,999),b.attachListener(b,"drop",d.ignoreInputEventListener,d,null,999),b.attachListener(b.isInline()?b:a.document.getDocumentElement(),"click",function(){d.onNavigationKey()},null,null,999),b.attachListener(this.undoManager.editor,"blur",function(){d.keyEventsStack.remove(9)},null,null,999)}};var g=CKEDITOR.plugins.undo.KeyEventsStack=function(){this.stack=[]};g.prototype={push:function(a){return a=this.stack.push({keyCode:a,inputs:0}),this.stack[a-1]}
18,getLastIndex:function(a){if("number"!=typeof a)return this.stack.length-1;for(var b=this.stack.length;b--;)if(this.stack[b].keyCode==a)return b;return-1},getLast:function(a){return a=this.getLastIndex(a),-1!=a?this.stack[a]:null},increment:function(a){this.getLast(a).inputs++},remove:function(a){a=this.getLastIndex(a),-1!=a&&this.stack.splice(a,1)},resetInputs:function(a){if("number"==typeof a)this.getLast(a).inputs=0;else for(a=this.stack.length;a--;)this.stack[a].inputs=0},getTotalInputs:function(){for(var a=this.stack.length,b=0;a--;)b+=this.stack[a].inputs;return b},cleanUp:function(a){a=a.data.$,a.ctrlKey||a.metaKey||this.remove(17),a.shiftKey||this.remove(16),a.altKey||this.remove(18)}}}(),CKEDITOR.plugins.add("wsc",{requires:"dialog",parseApi:function(a){a.config.wsc_onFinish="function"==typeof a.config.wsc_onFinish?a.config.wsc_onFinish:function(){},a.config.wsc_onClose="function"==typeof a.config.wsc_onClose?a.config.wsc_onClose:function(){}},parseConfig:function(a){a.config.wsc_customerId=a.config.wsc_customerId||CKEDITOR.config.wsc_customerId||"1:ua3xw1-2XyGJ3-GWruD3-6OFNT1-oXcuB1-nR6Bp4-hgQHc-EcYng3-sdRXG3-NOfFk",a.config.wsc_customDictionaryIds=a.config.wsc_customDictionaryIds||CKEDITOR.config.wsc_customDictionaryIds||"",a.config.wsc_userDictionaryName=a.config.wsc_userDictionaryName||CKEDITOR.config.wsc_userDictionaryName||"",a.config.wsc_customLoaderScript=a.config.wsc_customLoaderScript||CKEDITOR.config.wsc_customLoaderScript,CKEDITOR.config.wsc_cmd=a.config.wsc_cmd||CKEDITOR.config.wsc_cmd||"spell",CKEDITOR.config.wsc_version="v4.3.0-master-d769233",CKEDITOR.config.wsc_removeGlobalVariable=!0},init:function(a){var b=CKEDITOR.env;this.parseConfig(a),this.parseApi(a),a.addCommand("checkspell",new CKEDITOR.dialogCommand("checkspell")).modes={wysiwyg:!(CKEDITOR.env.opera||CKEDITOR.env.air||document.domain!=window.location.hostname||b.ie&&(8>b.version||b.quirks))},"undefined"==typeof a.plugins.scayt&&a.ui.addButton&&a.ui.addButton("SpellChecker",{label:a.lang.wsc.toolbar,click:function(a){var b=a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?a.container.getText():a.document.getBody().getText();(b=b.replace(/\s/g,""))?a.execCommand("checkspell"):alert("Nothing to check!")},toolbar:"spellchecker,10"}),CKEDITOR.dialog.add("checkspell",this.path+(CKEDITOR.env.ie&&7>
18=CKEDITOR.env.version?"dialogs/wsc_ie.js":window.postMessage?"dialogs/wsc.js":"dialogs/wsc_ie.js"))}}),CKEDITOR.config.plugins="dialogui,dialog,about,a11yhelp,dialogadvtab,basicstyles,bidi,blockquote,clipboard,button,panelbutton,panel,floatpanel,colorbutton,colordialog,templates,menu,contextmenu,div,resize,toolbar,elementspath,enterkey,entities,popup,filebrowser,find,fakeobjects,flash,floatingspace,listblock,richcombo,font,forms,format,horizontalrule,htmlwriter,iframe,wysiwygarea,image,indent,indentblock,indentlist,smiley,justify,menubutton,language,link,list,liststyle,magicline,maximize,newpage,pagebreak,pastetext,pastefromword,preview,print,removeformat,save,selectall,showblocks,showborders,sourcearea,specialchar,scayt,stylescombo,tab,table,tabletools,undo,wsc",CKEDITOR.config.skin="moono",function(){var a=function(a,b){var c=CKEDITOR.getUrl("plugins/"+b);a=a.split(",");for(var d=0;d<a.length;d++)CKEDITOR.skin.icons[a[d]]={path:c,offset:-a[++d],bgsize:a[++d]}};CKEDITOR.env.hidpi?a("about,0,,bold,24,,italic,48,,strike,72,,subscript,96,,superscript,120,,underline,144,,bidiltr,168,,bidirtl,192,,blockquote,216,,copy-rtl,240,,copy,264,,cut-rtl,288,,cut,312,,paste-rtl,336,,paste,360,,bgcolor,384,,textcolor,408,,templates-rtl,432,,templates,456,,creatediv,480,,find-rtl,504,,find,528,,replace,552,,flash,576,,button,600,,checkbox,624,,form,648,,hiddenfield,672,,imagebutton,696,,radio,720,,select-rtl,744,,select,768,,textarea-rtl,792,,textarea,816,,textfield-rtl,840,,textfield,864,,horizontalrule,888,,iframe,912,,image,936,,indent-rtl,960,,indent,984,,outdent-rtl,1008,,outdent,1032,,smiley,1056,,justifyblock,1080,,justifycenter,1104,,justifyleft,1128,,justifyright,1152,,language,1176,,anchor-rtl,1200,,anchor,1224,,link,1248,,unlink,1272,,bulletedlist-rtl,1296,,bulletedlist,1320,,numberedlist-rtl,1344,,numberedlist,1368,,maximize,1392,,newpage-rtl,1416,,newpage,1440,,pagebreak-rtl,1464,,pagebreak,1488,,pastetext-rtl,1512,,pastetext,1536,,pastefromword-rtl,1560,,pastefromword,1584,,preview-rtl,1608,,preview,1632,,print,1656,,removeformat,1680,,save,1704,,selectall,1728,,showblocks-rtl,1752,,showblocks,1776,,source-rtl,1800,,source,1824,,specialchar,1848,,scayt,1872,,table,1896,,redo-rtl,1920,,redo,1944,,undo-rtl,1968,,undo,1992,,spellchecker,2016,","icons_hidpi.png"):a("about,0,auto,bold,24,auto,italic,48,auto,strike,72,auto,subscript,96,auto,superscript,120,auto,underline,144,auto,bidiltr,168,auto,bidirtl,192,auto,blockquote,216,auto,copy-rtl,240,auto,copy,264,auto,cut-rtl,288,auto,cut,312,auto,paste-rtl,336,auto,paste,360,auto,bgcolor,384,auto,textcolor,408,auto,templates-rtl,432,auto,templates,456,auto,creatediv,480,auto,find-rtl,504,auto,find,528,auto,replace,552,auto,flash,576,auto,button,600,auto,checkbox,624,auto,form,648,auto,hiddenfield,672,auto,imagebutton,696,auto,radio,720,auto,select-rtl,744,auto,select,768,auto,textarea-rtl,792,auto,textarea,816,auto,textfield-rtl,840,auto,textfield,864,auto,horizontalrule,888,auto,iframe,912,auto,image,936,auto,indent-rtl,960,auto,indent,984,auto,outdent-rtl,1008,auto,outdent,1032,auto,smiley,1056,auto,justifyblock,1080,auto,justifycenter,1104,auto,justifyleft,1128,auto,justifyright,1152,auto,language,1176,auto,anchor-rtl,1200,auto,anchor,1224,auto,link,1248,auto,unlink,1272,auto,bulletedlist-rtl,1296,auto,bulletedlist,1320,auto,numberedlist-rtl,1344,auto,numberedlist,1368,auto,maximize,1392,auto,newpage-rtl,1416,auto,newpage,1440,auto,pagebreak-rtl,1464,auto,pagebreak,1488,auto,pastetext-rtl,1512,auto,pastetext,1536,auto,pastefromword-rtl,1560,auto,pastefromword,1584,auto,preview-rtl,1608,auto,preview,1632,auto,print,1656,auto,removeformat,1680,auto,save,1704,auto,selectall,1728,auto,showblocks-rtl,1752,auto,showblocks,1776,auto,source-rtl,1800,auto,source,1824,auto,specialchar,1848,auto,scayt,1872,auto,table,1896,auto,redo-rtl,1920,auto,redo,1944,auto,undo-rtl,1968,auto,undo,1992,auto,spellchecker,2016,auto","icons.png")}(),CKEDITOR.lang.languages={af:1,sq:1,ar:1,eu:1,bn:1,bs:1,bg:1,ca:1,"zh-cn":1,zh:1,hr:1,cs:1,da:1,nl:1,en:1,"en-au":1,"en-ca":1,"en-gb":1,eo:1,et:1,fo:1,fi:1,fr:1,"fr-ca":1,gl:1,ka:1,de:1,"de-ch":1,el:1,gu:1,he:1,hi:1,hu:1,is:1,id:1,it:1,ja:1,km:1,ko:1,ku:1,lv:1,lt:1,mk:1,ms:1,mn:1,no:1,nb:1,fa:1,pl:1,"pt-br":1,pt:1,ro:1,ru:1,sr:1,"sr-latn":1,si:1,sk:1,sl:1,es:1,sv:1,tt:1,th:1,tr:1,ug:1,uk:1,vi:1,cy:1}}}();
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.