!function(e){"use strict";function t(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];var o=t.concat(n);return e.apply(null,o)}}function n(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function r(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;for(var r=Array(e),o=0,t=0;t<n;t++)for(var i=arguments[t],a=0,u=i.length;a<u;a++,o++)r[o]=i[a];return r}function o(e){var t={},n={},r=[],o={},i={},a=function(t,n,r){var o=e[t];return o?o=ra(o,/[, ]/,ra(o.toUpperCase(),/[, ]/)):(o=ta[t],o||(o=ra(n," ",ra(n.toUpperCase()," ")),o=ia(o,r),ta[t]=o)),o};e=e||{};var u=sa(e.schema);e.verify_html===!1&&(e.valid_elements="*[*]");var c=fa(e.valid_styles),s=fa(e.invalid_styles,"map"),f=fa(e.valid_classes,"map"),l=a("whitespace_elements","pre script noscript style textarea video audio iframe object code"),d=a("self_closing_elements","colgroup dd dt li option p td tfoot th thead tr"),m=a("short_ended_elements","area base basefont br col frame hr img input isindex link meta param embed source wbr track"),p=a("boolean_attributes","checked compact declare defer disabled ismap multiple nohref noresize noshade nowrap readonly selected autoplay loop controls"),g=a("non_empty_elements","td th iframe video audio object script pre code",m),h=a("move_caret_before_on_enter_elements","table",g),v=a("text_block_elements","h1 h2 h3 h4 h5 h6 p div address pre form blockquote center dir fieldset header footer article section hgroup aside main nav figure"),y=a("block_elements","hr table tbody thead tfoot th tr td li ol ul caption dl dt dd noscript menu isindex option datalist select optgroup figcaption details summary",v),b=a("text_inline_elements","span strong b em i font strike u var cite dfn code mark q sup sub samp");oa((e.special||"script noscript iframe noframes noembed title style textarea xmp").split(" "),function(e){i[e]=new RegExp("</"+e+"[^>]*>","gi")});var C=function(e){return new RegExp("^"+e.replace(/([?+*])/g,".$1")+"$")},w=function(e){var n,o,i,a,u,c,s,f,l,d,m,p,g,h,v,y,b,w,x=/^([#+\-])?([^\[!\/]+)(?:\/([^\[!]+))?(?:(!?)\[([^\]]+)\])?$/,S=/^([!\-])?(\w+[\\:]:\w+|[^=:<]+)?(?:([=:<])(.*))?$/,N=/[*?+]/;if(e)for(e=ca(e,","),t["@"]&&(y=t["@"].attributes,b=t["@"].attributesOrder),n=0,o=e.length;n<o;n++)if(u=x.exec(e[n])){if(h=u[1],l=u[2],v=u[3],f=u[5],p={},g=[],c={attributes:p,attributesOrder:g},"#"===h&&(c.paddEmpty=!0),"-"===h&&(c.removeEmpty=!0),"!"===u[4]&&(c.removeEmptyAttrs=!0),y&&(gt(y,function(e,t){p[t]=e}),g.push.apply(g,b)),f)for(f=ca(f,"|"),i=0,a=f.length;i<a;i++)if(u=S.exec(f[i])){if(s={},m=u[1],d=u[2].replace(/[\\:]:/g,":"),h=u[3],w=u[4],"!"===m&&(c.attributesRequired=c.attributesRequired||[],c.attributesRequired.push(d),s.required=!0),"-"===m){delete p[d],g.splice(ua(g,d),1);continue}h&&("="===h&&(c.attributesDefault=c.attributesDefault||[],c.attributesDefault.push({name:d,value:w}),s.defaultValue=w),":"===h&&(c.attributesForced=c.attributesForced||[],c.attributesForced.push({name:d,value:w}),s.forcedValue=w),"<"===h&&(s.validValues=ra(w,"?"))),N.test(d)?(c.attributePatterns=c.attributePatterns||[],s.pattern=C(d),c.attributePatterns.push(s)):(p[d]||g.push(d),p[d]=s)}y||"@"!==l||(y=p,b=g),v&&(c.outputName=l,t[v]=c),N.test(l)?(c.pattern=C(l),r.push(c)):t[l]=c}},x=function(e){t={},r=[],w(e),oa(u,function(e,t){n[t]=e.children})},S=function(e){var r=/^(~)?(.+)$/;e&&(ta.text_block_elements=ta.block_elements=null,oa(ca(e,","),function(e){var i=r.exec(e),a="~"===i[1],u=a?"span":"div",c=i[2];if(n[c]=n[u],o[c]=u,a||(y[c.toUpperCase()]={},y[c]={}),!t[c]){var s=t[u];s=ia({},s),delete s.removeEmptyAttrs,delete s.removeEmpty,t[c]=s}oa(n,function(e,t){e[u]&&(n[t]=e=ia({},n[t]),e[c]=e[u])})}))},N=function(t){var r=/^([+\-]?)([A-Za-z0-9_\-\.\u00b7\u00c0-\u00d6\u00d8-\u00f6\u00f8-\u037d\u037f-\u1fff\u200c-\u200d\u203f-\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]+)\[([^\]]+)\]$/;ta[e.schema]=null,t&&oa(ca(t,","),function(e){var t,o,i=r.exec(e);i&&(o=i[1],t=o?n[i[2]]:n[i[2]]={"#comment":{}},t=n[i[2]],oa(ca(i[3],"|"),function(e){"-"===o?delete t[e]:t[e]={}}))})},E=function(e){var n,o=t[e];if(o)return o;for(n=r.length;n--;)if(o=r[n],o.pattern.test(e))return o};e.valid_elements?x(e.valid_elements):(oa(u,function(e,r){t[r]={attributes:e.attributes,attributesOrder:e.attributesOrder},n[r]=e.children}),"html5"!==e.schema&&oa(ca("strong/b em/i"),function(e){e=ca(e,"/"),t[e[1]].outputName=e[0]}),oa(ca("ol ul sub sup blockquote span font a table tbody tr strong em b i"),function(e){t[e]&&(t[e].removeEmpty=!0)}),oa(ca("p h1 h2 h3 h4 h5 h6 th td pre div address caption li"),function(e){t[e].paddEmpty=!0}),oa(ca("span"),function(e){t[e].removeEmptyAttrs=!0})),S(e.custom_elements),N(e.valid_children),w(e.extended_valid_elements),N("+ol[ul|ol],+ul[ul|ol]"),oa({dd:"dl",dt:"dl",li:"ul ol",td:"tr",th:"tr",tr:"tbody thead tfoot",tbody:"table",thead:"table",tfoot:"table",legend:"fieldset",area:"map",param:"video audio object"},function(e,n){t[n]&&(t[n].parentsRequired=ca(e))}),e.invalid_elements&&oa(aa(e.invalid_elements),function(e){t[e]&&delete t[e]}),E("span")||w("span[!data-mce-type|*]");var k=function(){return c},_=function(){return s},T=function(){return f},R=function(){return p},A=function(){return y},D=function(){return v},O=function(){return b},B=function(){return m},P=function(){return d},L=function(){return g},I=function(){return h},M=function(){return l},F=function(){return i},U=function(e,t){var r=n[e.toLowerCase()];return!(!r||!r[t.toLowerCase()])},z=function(e,t){var n,r,o=E(e);if(o){if(!t)return!0;if(o.attributes[t])return!0;if(n=o.attributePatterns)for(r=n.length;r--;)if(n[r].pattern.test(e))return!0}return!1},j=function(){return o};return{children:n,elements:t,getValidStyles:k,getValidClasses:T,getBlockElements:A,getInvalidStyles:_,getShortEndedElements:B,getTextBlockElements:D,getTextInlineElements:O,getBoolAttrs:R,getElementRule:E,getSelfClosingElements:P,getNonEmptyElements:L,getMoveCaretBeforeOnEnterElements:I,getWhiteSpaceElements:M,getSpecialElements:F,isValidChild:U,isValid:z,getCustomElements:j,addValidElements:w,setValidElements:x,addCustomElements:S,addValidChildren:N}}function i(){function e(n,r){return t.push(n+" ")>z.cacheLength&&delete e[t.shift()],e[n+" "]=r}var t=[];return e}function a(e){return e[Ra]=!0,e}function u(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||Fa)-(~e.sourceIndex||Fa);if(r)return r;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function c(e){return function(t){var n=t.nodeName.toLowerCase();return"input"===n&&t.type===e}}function s(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function f(e){return a(function(t){return t=+t,a(function(n,r){for(var o,i=e([],n.length,t),a=i.length;a--;)n[o=i[a]]&&(n[o]=!(r[o]=n[o]))})})}function l(e){return e&&typeof e.getElementsByTagName!==Ma&&e}function d(){}function m(e){for(var t=0,n=e.length,r="";t<n;t++)r+=e[t].value;return r}function p(e,t,n){var r=t.dir,o=n&&"parentNode"===r,i=Oa++;return t.first?function(t,n,i){for(;t=t[r];)if(1===t.nodeType||o)return e(t,n,i)}:function(t,n,a){var u,c,s=[Da,i];if(a){for(;t=t[r];)if((1===t.nodeType||o)&&e(t,n,a))return!0}else for(;t=t[r];)if(1===t.nodeType||o){if(c=t[Ra]||(t[Ra]={}),(u=c[r])&&u[0]===Da&&u[1]===i)return s[2]=u[2];if(c[r]=s,s[2]=e(t,n,a))return!0}}}function g(e){return e.length>1?function(t,n,r){for(var o=e.length;o--;)if(!e[o](t,n,r))return!1;return!0}:e[0]}function h(e,t,n){for(var r=0,o=t.length;r<o;r++)mu(e,t[r],n);return n}function v(e,t,n,r,o){for(var i,a=[],u=0,c=e.length,s=null!=t;u<c;u++)(i=e[u])&&(n&&!n(i,r,o)||(a.push(i),s&&t.push(u)));return a}function y(e,t,n,r,o,i){return r&&!r[Ra]&&(r=y(r)),o&&!o[Ra]&&(o=y(o,i)),a(function(i,a,u,c){var s,f,l,d=[],m=[],p=a.length,g=i||h(t||"*",u.nodeType?[u]:u,[]),y=!e||!i&&t?g:v(g,d,e,u,c),b=n?o||(i?e:p||r)?[]:a:y;if(n&&n(y,b,u,c),r)for(s=v(b,m),r(s,[],u,c),f=s.length;f--;)(l=s[f])&&(b[m[f]]=!(y[m[f]]=l));if(i){if(o||e){if(o){for(s=[],f=b.length;f--;)(l=b[f])&&s.push(y[f]=l);o(null,b=[],s,c)}for(f=b.length;f--;)(l=b[f])&&(s=o?$a.call(i,l):d[f])>-1&&(i[s]=!(a[s]=l))}}else b=v(b===a?b.splice(p,b.length):b),o?o(null,a,b,c):Va.apply(a,b)})}function b(e){for(var t,n,r,o=e.length,i=z.relative[e[0].type],a=i||z.relative[" "],u=i?1:0,c=p(function(e){return e===t},a,!0),s=p(function(e){return $a.call(t,e)>-1},a,!0),f=[function(e,n,r){return!i&&(r||n!==W)||((t=n).nodeType?c(e,n,r):s(e,n,r))}];u<o;u++)if(n=z.relative[e[u].type])f=[p(g(f),n)];else{if(n=z.filter[e[u].type].apply(null,e[u].matches),n[Ra]){for(r=++u;r<o&&!z.relative[e[r].type];r++);return y(u>1&&g(f),u>1&&m(e.slice(0,u-1).concat({value:" "===e[u-2].type?"*":""})).replace(Ja,"$1"),n,u<r&&b(e.slice(u,r)),r<o&&b(e=e.slice(r)),r<o&&m(e))}f.push(n)}return g(f)}function C(e,t){var n=t.length>0,r=e.length>0,o=function(o,i,a,u,c){var s,f,l,d=0,m="0",p=o&&[],g=[],h=W,y=o||r&&z.find.TAG("*",c),b=Da+=null==h?1:Math.random()||.1,C=y.length;for(c&&(W=i!==G&&i);m!==C&&null!=(s=y[m]);m++){if(r&&s){for(f=0;l=e[f++];)if(l(s,i,a)){u.push(s);break}c&&(Da=b)}n&&((s=!l&&s)&&d--,o&&p.push(s))}if(d+=m,n&&m!==d){for(f=0;l=t[f++];)l(p,g,i,a);if(o){if(d>0)for(;m--;)p[m]||g[m]||(g[m]=ja.call(u));g=v(g)}Va.apply(u,g),c&&!o&&g.length>0&&d+t.length>1&&mu.uniqueSort(u)}return c&&(Da=b,W=h),p};return n?a(o):o}function w(t,n){void 0===n&&(n={});var r=0,o={},i=ar.fromDom(t),a=Br(i),u=n.maxLoadTime||5e3,c=function(e){n.referrerPolicy=e},s=function(e){ro(Jr(i),e)},f=function(i,c,f){var l,d,m,p=function(e){m.status=e,m.passed=[],m.failed=[],l&&(l.onload=null,l.onerror=null,l=null)},g=function(){for(var e=m.passed,t=e.length;t--;)e[t]();p(2)},h=function(){for(var e=m.failed,t=e.length;t--;)e[t]();p(3)},v=function(){var t=e.navigator.userAgent.match(/WebKit\/(\d*)/);return!!(t&&parseInt(t[1],10)<536)},y=function(e,t){e()||((new Date).getTime()-w<u?Cc.setTimeout(t):h())},b=function(){y(function(){for(var e,n,r=t.styleSheets,o=r.length;o--;)if(e=r[o],n=e.ownerNode?e.ownerNode:e.owningElement,n&&n.id===l.id)return g(),!0},b)},C=function(){y(function(){try{var e=d.sheet.cssRules;return g(),!!e}catch(t){}},C)};if(i=er._addCacheSuffix(i),o[i]?m=o[i]:(m={passed:[],failed:[]},o[i]=m),c&&m.passed.push(c),f&&m.failed.push(f),1!==m.status){if(2===m.status)return void g();if(3===m.status)return void h();m.status=1,l=a.dom().createElement("link"),l.rel="stylesheet",l.type="text/css",l.id="u"+r++,l.async=!1,l.defer=!1;var w=(new Date).getTime();if(n.contentCssCors&&(l.crossOrigin="anonymous"),n.referrerPolicy&&$o(ar.fromDom(l),"referrerpolicy",n.referrerPolicy),"onload"in l&&!v())l.onload=b,l.onerror=h;else{if(e.navigator.userAgent.indexOf("Firefox")>0)return d=a.dom().createElement("style"),d.textContent='@import "'+i+'"',C(),void s(ar.fromDom(d));b()}s(ar.fromDom(l)),l.href=i}},l=function(e){return nc.nu(function(t){f(e,ge(t,ve(cc.value(e))),ge(t,ve(cc.error(e))))})},d=function(e,t,n){oc(Ke(e,l)).get(function(e){var r=Ge(e,function(e){return e.isValue()});r.fail.length>0?n(r.fail.map(lc)):t(r.pass.map(lc))})};return{load:f,loadAll:d,_setReferrerPolicy:c}}function x(t,n){var r=this;void 0===n&&(n={});var i={},a=e.window,u={},c=0,s=!0,f=!0,l=xc.forElement(ar.fromDom(t),{contentCssCors:n.contentCssCors,referrerPolicy:n.referrerPolicy}),d=[],m=n.schema?n.schema:o({}),p=ha({url_converter:n.url_converter,url_converter_scope:n.url_converter_scope},n.schema),g=n.ownEvents?new Ta:Ta.Event,h=m.getBlockElements(),v=Vu.overrideDefaults(function(){return{context:t,element:Re.getRoot()}}),y=function(e){if("string"==typeof e)return!!h[e];if(e){var t=e.nodeType;if(t)return!(1!==t||!h[e.nodeName])}return!1},b=function(e){return e&&t&&Oe(e)?t.getElementById(e):e},C=function(e){return v("string"==typeof e?b(e):e)},w=function(e,t,n){var r,o,i=C(e);return i.length&&(r=Ae[t],o=r&&r.get?r.get(i,t):i.attr(t)),"undefined"==typeof o&&(o=n||""),o},S=function(e){var t=b(e);return t?t.attributes:[]},N=function(e,t,r){""===r&&(r=null);var o=C(e),i=o.attr(t);if(o.length){var a=Ae[t];a&&a.set?a.set(o,r,t):o.attr(t,r),i!==r&&n.onSetAttrib&&n.onSetAttrib({attrElm:o,attrName:t,attrValue:r})}},E=function(e,n){if(!Ec||1!==e.nodeType||n)return e.cloneNode(n);var r=t.createElement(e.nodeName);return Sc(S(e),function(t){N(r,t.nodeName,w(e,t.nodeName))}),r},k=function(){return n.root_element||t.body},_=function(e){var t=So(e);return{x:t.x,y:t.y,w:t.width,h:t.height}},T=function(e,n){return si(t.body,b(e),n)},R=function(e,t,r){var o=Oe(t)?C(e).css(t,r):C(e).css(t);n.update_styles&&Tc(p,o)},A=function(e,t){var r=C(e).css(t);n.update_styles&&Tc(p,r)},D=function(e,t,n){var r=C(e);return n?r.css(t):(t=t.replace(/-(\D)/g,function(e,t){return t.toUpperCase()}),"float"===t&&(t=jn.browser.isIE()?"styleFloat":"cssFloat"),r[0]&&r[0].style?r[0].style[t]:void 0)},O=function(e){var t,n;return e=b(e),t=D(e,"width"),n=D(e,"height"),t.indexOf("px")===-1&&(t=0),n.indexOf("px")===-1&&(n=0),{w:parseInt(t,10)||e.offsetWidth||e.clientWidth,h:parseInt(n,10)||e.offsetHeight||e.clientHeight}},B=function(e){e=b(e);var t=T(e),n=O(e);return{x:t.x,y:t.y,w:n.w,h:n.h}},P=function(e,t){var n;if(!e)return!1;if(!Array.isArray(e)){if("*"===t)return 1===e.nodeType;if(kc.test(t)){var r=t.toLowerCase().split(/,/),o=e.nodeName.toLowerCase();for(n=r.length-1;n>=0;n--)if(r[n]===o)return!0;return!1}if(e.nodeType&&1!==e.nodeType)return!1}var i=Array.isArray(e)?e:[e];return mu(t,i[0].ownerDocument||i[0],null,i).length>0},L=function(e,t,n,r){var o,i=[],a=b(e);for(r=void 0===r,n=n||("BODY"!==k().nodeName?k().parentNode:null),er.is(t,"string")&&(o=t,t="*"===t?function(e){return 1===e.nodeType}:function(e){return P(e,o)});a&&a!==n&&a.nodeType&&9!==a.nodeType;){if(!t||"function"==typeof t&&t(a)){if(!r)return[a];i.push(a)}a=a.parentNode}return r?i:null},I=function(e,t,n){var r=L(e,t,n,!1);return r&&r.length>0?r[0]:null},M=function(e,t,n){var r=t;if(e)for("string"==typeof t&&(r=function(e){return P(e,t)}),e=e[n];e;e=e[n])if("function"==typeof r&&r(e))return e;return null},F=function(e,t){return M(e,t,"nextSibling")},U=function(e,t){return M(e,t,"previousSibling")},z=function(e,r){return mu(e,b(r)||n.root_element||t,[])},j=function(e,t,n){var o,i="string"==typeof e?b(e):e;if(!i)return!1;if(er.isArray(i)&&(i.length||0===i.length))return o=[],Sc(i,function(e,r){e&&("string"==typeof e&&(e=b(e)),o.push(t.call(n,e,r)))}),o;var a=n?n:r;return t.call(a,i)},H=function(e,t){C(e).each(function(e,n){Sc(t,function(e,t){N(n,t,e)})})},V=function(e,t){var n=C(e);Ec?n.each(function(e,n){if(n.canHaveHTML!==!1){for(;n.firstChild;)n.removeChild(n.firstChild);try{n.innerHTML="<br>"+t,n.removeChild(n.firstChild)}catch(r){Vu("<div></div>").html("<br>"+t).contents().slice(1).appendTo(n)}return t}}):n.html(t)},q=function(e,n,r,o,i){return j(e,function(e){var a="string"==typeof n?t.createElement(n):n;return H(a,r),o&&("string"!=typeof o&&o.nodeType?a.appendChild(o):"string"==typeof o&&V(a,o)),i?a:e.appendChild(a)})},$=function(e,n,r){return q(t.createElement(e),e,n,r,!0)},W=ea.decode,K=ea.encodeAllRaw,X=function(e,t,n){var r,o="";o+="<"+e;for(r in t)t.hasOwnProperty(r)&&null!==t[r]&&"undefined"!=typeof t[r]&&(o+=" "+r+'="'+K(t[r])+'"');return"undefined"!=typeof n?o+">"+n+"</"+e+">":o+" />"},Y=function(e){var n,r=t.createElement("div"),o=t.createDocumentFragment();for(o.appendChild(r),e&&(r.innerHTML=e);n=r.firstChild;)o.appendChild(n);return o.removeChild(r),o},G=function(e,t){var n=C(e);return t?n.each(function(){for(var e;e=this.firstChild;)3===e.nodeType&&0===e.data.length?this.removeChild(e):this.parentNode.insertBefore(e,this)}).remove():n.remove(),n.length>1?n.toArray():n[0]},J=function(e){return j(e,function(e){var t,n=e.attributes;for(t=n.length-1;t>=0;t--)e.removeAttributeNode(n.item(t))})},Q=function(e){return p.parse(e)},Z=function(e,t){return p.serialize(e,t)},ee=function(n){var r,o;if(Re!==x.DOM&&t===e.document){if(i[n])return;i[n]=!0}o=t.getElementById("mceDefaultStyles"),o||(o=t.createElement("style"),o.id="mceDefaultStyles",o.type="text/css",r=t.getElementsByTagName("head")[0],r.firstChild?r.insertBefore(o,r.firstChild):r.appendChild(o)),o.styleSheet?o.styleSheet.cssText+=n:o.appendChild(t.createTextNode(n))},te=function(r){if(Re!==x.DOM&&t===e.document)return void x.DOM.loadCSS(r);r||(r="");var o=t.getElementsByTagName("head")[0];Sc(r.split(","),function(e){if(e=er._addCacheSuffix(e),!u[e]){u[e]=!0;var t=$("link",It(It({rel:"stylesheet",type:"text/css",href:e},n.contentCssCors?{crossOrigin:"anonymous"}:{}),n.referrerPolicy?{referrerPolicy:n.referrerPolicy}:{}));o.appendChild(t)}})},ne=function(e,t,n){C(e).toggleClass(t,n).each(function(){""===this.className&&Vu(this).attr("class",null)})},re=function(e,t){C(e).addClass(t)},oe=function(e,t){ne(e,t,!1)},ie=function(e,t){return C(e).hasClass(t)},ae=function(e){C(e).show()},ue=function(e){C(e).hide()},ce=function(e){return"none"===C(e).css("display")},se=function(e){return(e?e:"mce_")+c++},fe=function(e){var t="string"==typeof e?b(e):e;return ko(t)?t.outerHTML:Vu("<div></div>").append(Vu(t).clone()).html()},le=function(e,t){C(e).each(function(){try{if("outerHTML"in this)return void(this.outerHTML=t)}catch(e){}G(Vu(this).html(t),!0)})},de=function(e,t){var n=b(t);return j(e,function(e){var t=n.parentNode,r=n.nextSibling;return r?t.insertBefore(e,r):t.appendChild(e),e})},me=function(e,t,n){return j(t,function(t){return er.is(t,"array")&&(e=e.cloneNode(!0)),n&&Sc(Nc(t.childNodes),function(t){e.appendChild(t)}),t.parentNode.replaceChild(e,t)})},pe=function(e,t){var n;return e.nodeName!==t.toUpperCase()&&(n=$(t),Sc(S(e),function(t){N(n,t.nodeName,w(e,t.nodeName))}),me(n,e,!0)),n||e},ge=function(e,t){for(var n,r=e;r;){for(n=t;n&&r!==n;)n=n.parentNode;if(r===n)break;r=r.parentNode}return!r&&e.ownerDocument?e.ownerDocument.documentElement:r},he=function(e){return p.toHex(er.trim(e))},ve=function(e){if(ko(e)){var t="a"===e.nodeName.toLowerCase()&&!w(e,"href")&&w(e,"id");if(w(e,"name")||w(e,"data-mce-bookmark")||t)return!0}return!1},ye=function(e,t){var n,r,o=0;if(ve(e))return!1;if(e=e.firstChild){var i=new qu(e,e.parentNode),a=m?m.getWhiteSpaceElements():{};t=t||(m?m.getNonEmptyElements():null);do{if(n=e.nodeType,ko(e)){var u=e.getAttribute("data-mce-bogus");if(u){e=i.next("all"===u);continue}if(r=e.nodeName.toLowerCase(),t&&t[r]){if("br"===r){o++,e=i.next();continue}return!1}if(ve(e))return!1}if(8===n)return!1;if(3===n&&!Bi(e.nodeValue))return!1;if(3===n&&e.parentNode&&a[e.parentNode.nodeName]&&Bi(e.nodeValue))return!1;e=i.next()}while(e)}return o<=1},be=function(){return t.createRange()},Ce=function(e,t,n){var r,o,i,a=be();if(e&&t)return a.setStart(e.parentNode,Rc(e)),a.setEnd(t.parentNode,Rc(t)),r=a.extractContents(),a=be(),a.setStart(t.parentNode,Rc(t)+1),a.setEnd(e.parentNode,Rc(e)+1),o=a.extractContents(),i=e.parentNode,i.insertBefore(Ii(Re,r),e),n?i.insertBefore(n,e):i.insertBefore(t,e),i.insertBefore(Ii(Re,o),e),G(e),n||t},we=function(e,r,o,i){if(er.isArray(e)){for(var u=e.length,c=[];u--;)c[u]=we(e[u],r,o,i);return c}return!n.collect||e!==t&&e!==a||d.push([e,r,o,i]),g.bind(e,r,o,i||Re)},xe=function(e,n,r){var o;if(er.isArray(e)){o=e.length;for(var i=[];o--;)i[o]=xe(e[o],n,r);return i}if(d.length>0&&(e===t||e===a))for(o=d.length;o--;){var u=d[o];e!==u[0]||n&&n!==u[1]||r&&r!==u[2]||g.unbind(u[0],u[1],u[2])}return g.unbind(e,n,r)},Se=function(e,t,n){return g.fire(e,t,n)},Ne=function(e){if(e&&ko(e)){var t=e.getAttribute("data-mce-contenteditable");return t&&"inherit"!==t?t:"inherit"!==e.contentEditable?e.contentEditable:null}return null},Ee=function(e){for(var t=k(),n=null;e&&e!==t&&(n=Ne(e),null===n);e=e.parentNode);return n},ke=function(){if(d.length>0)for(var e=d.length;e--;){var t=d[e];g.unbind(t[0],t[1],t[2])}mu.setDocument&&mu.setDocument()},_e=function(e,t){for(;e;){if(t===e)return!0;e=e.parentNode}return!1},Te=function(e){return"startContainer: "+e.startContainer.nodeName+", startOffset: "+e.startOffset+", endContainer: "+e.endContainer.nodeName+", endOffset: "+e.endOffset},Re={doc:t,settings:n,win:a,files:u,stdMode:s,boxModel:f,styleSheetLoader:l,boundEvents:d,styles:p,schema:m,events:g,isBlock:y,$:v,$$:C,root:null,clone:E,getRoot:k,getViewPort:_,getRect:B,getSize:O,getParent:I,getParents:L,get:b,getNext:F,getPrev:U,select:z,is:P,add:q,create:$,createHTML:X,createFragment:Y,remove:G,setStyle:R,getStyle:D,setStyles:A,removeAllAttribs:J,setAttrib:N,setAttribs:H,getAttrib:w,getPos:T,parseStyle:Q,serializeStyle:Z,addStyle:ee,loadCSS:te,addClass:re,removeClass:oe,hasClass:ie,toggleClass:ne,show:ae,hide:ue,isHidden:ce,uniqueId:se,setHTML:V,getOuterHTML:fe,setOuterHTML:le,decode:W,encode:K,insertAfter:de,replace:me,rename:pe,findCommonAncestor:ge,toHex:he,run:j,getAttribs:S,isEmpty:ye,createRng:be,nodeIndex:Rc,split:Ce,bind:we,unbind:xe,fire:Se,getContentEditable:Ne,getContentEditableParent:Ee,destroy:ke,isChildOf:_e,dumpRng:Te},Ae=_c(p,n,function(){return Re});return Re}function S(){var e=this,t=[],n={},r={},o=[],i=function(e,t){var n=Je(o,function(n){return n.name===e&&n.state===t});Xe(n,function(e){return e.callback()})},a=function(e){if(r[e])return r[e].instance},u=function(e){var t;return r[e]&&(t=r[e].dependencies),t||[]},c=function(e,t){S.languageLoad!==!1&&g(e,function(){var r=Qc.getCode(),o=","+(t||"")+",";!r||t&&o.indexOf(","+r+",")===-1||Fc.ScriptLoader.add(n[e]+"/langs/"+r+".js")},"loaded")},s=function(e,n,o){var a=n;return t.push(a),r[e]={instance:a,dependencies:o},i(e,"added"),a},f=function(e){delete n[e],delete r[e]},l=function(e,t){return"object"==typeof t?t:"string"==typeof e?{prefix:"",resource:t,suffix:""}:{prefix:e.prefix,resource:t,suffix:e.suffix}},d=function(t,n){var r=e.urls[t];Xe(n,function(e){Fc.ScriptLoader.add(r+"/"+e)})},m=function(e,t,n,r){var o=u(e);Xe(o,function(e){var n=l(t,e);p(n.resource,n,void 0,void 0)}),n&&(r?n.call(r):n.call(Fc))},p=function(e,t,o,a,u){if(!n[e]){var c="string"==typeof t?t:t.prefix+t.resource+t.suffix;0!==c.indexOf("/")&&c.indexOf("://")===-1&&(c=S.baseURL+"/"+c),n[e]=c.substring(0,c.lastIndexOf("/"));var s=function(){i(e,"loaded"),m(e,t,o,a)};r[e]?s():Fc.ScriptLoader.add(c,s,a,u)}},g=function(e,t,i){void 0===i&&(i="added"),Et(r,e)&&"added"===i?t():Et(n,e)&&"loaded"===i?t():o.push({name:e,state:i,callback:t})};return{items:t,urls:n,lookup:r,_listeners:o,get:a,dependencies:u,requireLangPack:c,add:s,remove:f,createUrl:l,addComponents:d,load:p,waitFor:g}}function N(e,t,n,r,o){return e(n,r)?_e.some(n):Fe(o)&&o(n)?_e.none():t(n,r,o)}function E(e,t,n){var r=function(){return Wf(e)?0===t:0===t},o=function(){return Wf(e)?t>=e.data.length:t>=e.childNodes.length},i=function(){var n=Gf(e.ownerDocument);return n.setStart(e,t),n.setEnd(e,t),n},a=function(){return n||(n=il(E(e,t))),n},u=function(){return a().length>0},c=function(n){return n&&e===n.container()&&t===n.offset()},s=function(n){return Yf(e,n?t-1:t)};return{container:ve(e),offset:ve(t),toRange:i,getClientRects:a,isVisible:u,isAtStart:r,isAtEnd:o,isEqual:c,getNode:s}}function k(e,t){var n=function(n){if(!e(n))throw new Error("Can only get "+t+" value of a "+t+" node");return r(n).getOr("")},r=function(t){return e(t)?_e.from(t.dom().nodeValue):_e.none()},o=function(n,r){if(!e(n))throw new Error("Can only set raw "+t+" value of a "+t+" node");n.dom().nodeValue=r};return{get:n,getOption:r,set:o}}function _(e,t){void 0===t&&(t=o());var n=function(){};e=e||{},e.fix_self_closing!==!1&&(e.fix_self_closing=!0);var r=e.comment?e.comment:n,i=e.cdata?e.cdata:n,a=e.text?e.text:n,u=e.start?e.start:n,c=e.end?e.end:n,s=e.pi?e.pi:n,f=e.doctype?e.doctype:n,l=function(n,o){void 0===o&&(o="html");for(var l,d,m,p,g,h,v,y,b,C,w,x,S,N,E,k,_,T,R,A,D=n.html,O=0,B=[],P=0,L=ea.decode,I=er.makeMap("src,href,data,background,formaction,poster,xlink:href"),M=/((java|vb)script|mhtml):/i,F="html"===o?0:1,U=function(e){var t,n;for(t=B.length;t--&&B[t].name!==e;);if(t>=0){for(n=B.length-1;n>=t;n--)e=B[n],e.valid&&c(e.name);B.length=t}},z=function(e,t){return a(oh(e,n),t)},j=function(t){""!==t&&(">"===t.charAt(0)&&(t=" "+t),e.allow_conditional_comments||"[if"!==t.substr(0,3).toLowerCase()||(t=" "+t),r(oh(t,n)))},H=function(e){return Nt(n.uris,e).getOr(e)},V=function(e,t){var n=e||"",r=!yn(n,"--"),o=fh(D,r,t);return e=D.substr(t,o-t),j(r?n+e:e),o+1},q=(function(t,n,r,o,i){var a,u,c=/[\s\u0000-\u001F]+/g;if(n=n.toLowerCase(),r=H(n in Y?n:L(r||o||i||"")),G&&!y&&ah(n)===!1){if(a=N[n],!a&&E){for(u=E.length;u--&&(a=E[u],!a.pattern.test(n)););u===-1&&(a=null)}if(!a)return;if(a.validValues&&!(r in a.validValues))return}if(I[n]&&!e.allow_script_urls){var s=r.replace(c,"");try{s=decodeURIComponent(s)}catch(f){s=unescape(s)}if(M.test(s))return;if(uh(e,s))return}y&&(n in I||0===n.indexOf("on"))||(p.map[n]=r,p.push({name:n,value:r}))}),$=new RegExp("<(?:(?:!--([\\w\\W]*?)--!?>)|(?:!\\[CDATA\\[([\\w\\W]*?)\\]\\]>)|(?:![Dd][Oo][Cc][Tt][Yy][Pp][Ee]([\\w\\W]*?)>)|(?:!(--)?)|(?:\\?([^\\s\\/<>]+) ?([\\w\\W]*?)[?/]>)|(?:\\/([A-Za-z][A-Za-z0-9\\-_\\:\\.]*)>)|(?:([A-Za-z][A-Za-z0-9\\-_\\:\\.]*)((?:\\s+[^\"'>]+(?:(?:\"[^\"]*\")|(?:'[^']*')|[^>]*))*|\\/|\\s+)>))","g"),W=/([\w:\-]+)(?:\s*=\s*(?:(?:\"((?:[^\"])*)\")|(?:\'((?:[^\'])*)\')|([^>\s]+)))?/g,K=t.getShortEndedElements(),X=e.self_closing_elements||t.getSelfClosingElements(),Y=t.getBoolAttrs(),G=e.validate,J=e.remove_internals,Q=e.fix_self_closing,Z=t.getSpecialElements(),ee=D+">";l=$.exec(ee);){var te=l[0];if(O<l.index&&z(L(D.substr(O,l.index-O))),d=l[7])d=d.toLowerCase(),":"===d.charAt(0)&&(d=d.substr(1)),U(d);else if(d=l[8]){if(l.index+te.length>D.length){z(L(D.substr(l.index))),O=l.index+te.length;continue}d=d.toLowerCase(),":"===d.charAt(0)&&(d=d.substr(1)),b=d in K,Q&&X[d]&&B.length>0&&B[B.length-1].name===d&&U(d);var ne=lh(W,l[9]);if(null!==ne){if("all"===ne){O=ch(t,D,$.lastIndex),$.lastIndex=O;continue}w=!1}if(!G||(C=t.getElementRule(d))){if(w=!0,G&&(N=C.attributes,E=C.attributePatterns),(S=l[9])?(y=S.indexOf("data-mce-type")!==-1,y&&J&&(w=!1),p=[],p.map={},S.replace(W,q)):(p=[],p.map={}),G&&!y){if(k=C.attributesRequired,_=C.attributesDefault,T=C.attributesForced,R=C.removeEmptyAttrs,R&&!p.length&&(w=!1),T)for(g=T.length;g--;)x=T[g],v=x.name,A=x.value,"{$uid}"===A&&(A="mce_"+P++),p.map[v]=A,p.push({name:v,value:A});if(_)for(g=_.length;g--;)x=_[g],v=x.name,v in p.map||(A=x.value,"{$uid}"===A&&(A="mce_"+P++),p.map[v]=A,p.push({name:v,value:A}));if(k){for(g=k.length;g--&&!(k[g]in p.map););g===-1&&(w=!1)}if(x=p.map["data-mce-bogus"]){if("all"===x){O=ch(t,D,$.lastIndex),$.lastIndex=O;continue}w=!1}}w&&u(d,p,b)}else w=!1;if(m=Z[d]){m.lastIndex=O=l.index+te.length,(l=m.exec(D))?(w&&(h=D.substr(O,l.index-O)),O=l.index+l[0].length):(h=D.substr(O),O=D.length),w&&(h.length>0&&z(h,!0),c(d)),$.lastIndex=O;continue}b||(S&&S.indexOf("/")===S.length-1?w&&c(d):B.push({name:d,valid:w}))}else if(d=l[1])j(d);else if(d=l[2]){var re=1===F||e.preserve_cdata||B.length>0&&t.isValidChild(B[B.length-1].name,"#cdata");if(!re){O=V("",l.index+2),$.lastIndex=O;continue}i(d)}else if(d=l[3])f(d);else{if((d=l[4])||"<!"===te){O=V(d,l.index+te.length),$.lastIndex=O;continue}if(d=l[5]){if(1!==F){O=V("?",l.index+2),$.lastIndex=O;continue}s(d,l[6])}}O=l.index+te.length}for(O<D.length&&z(L(D.substr(O))),g=B.length-1;g>=0;g--)d=B[g],d.valid&&c(d.name)},d=function(e,t){void 0===t&&(t="html"),l(rh(e),t)};return{parse:d}}function T(){var e=function(){throw new Error("Theme did not provide a NotificationManager implementation.")};return{open:e,close:e,reposition:e,getArgs:e}}function R(e){var t=[],n=function(){var t=e.theme;return t&&t.getNotificationManagerImpl?t.getNotificationManagerImpl():T()},r=function(){return _e.from(t[0])},o=function(e,t){return!(e.type!==t.type||e.text!==t.text||e.progressBar||e.timeout||t.progressBar||t.timeout)},i=function(){t.length>0&&n().reposition(t)},a=function(e){t.push(e)},u=function(e){nt(t,function(t){return t===e}).each(function(e){t.splice(e,1)})},c=function(c){if(!e.removed&&GN(e))return tt(t,function(e){return o(n().getArgs(e),c)}).getOrThunk(function(){e.editorManager.setActive(e);var t=n().open(c,function(){u(t),i(),r().fold(function(){return e.focus()},function(e){return Zy(ar.fromDom(e.getEl()))})});return a(t),i(),t})},s=function(){r().each(function(e){n().close(e),u(e),i()})},f=function(){return t},l=function(e){e.on("SkinLoaded",function(){var t=Rd(e);t&&c({text:t,type:"warning",timeout:0})}),e.on("ResizeEditor ResizeWindow NodeChange",function(){Cc.requestAnimationFrame(i)}),e.on("remove",function(){Xe(t.slice(),function(e){n().close(e)})})};return l(e),{open:c,close:s,getNotifications:f}}function A(){var e=function(){throw new Error("Theme did not provide a WindowManager implementation.")};return{open:e,openUrl:e,alert:e,confirm:e,close:e,getParams:e,setParams:e}}function D(e,t){var n=function(t,n){if(!Ue(n)&&!n.match(/^[0-9]+$/))throw new Error(e+".set accepts only positive integer values. Value was "+n);var r=t.dom();Vo(r)&&(r.style[e]=n+"px")},r=function(n){var r=t(n);if(r<=0||null===r){var o=ei(n,e);return parseFloat(o)||0}return r},o=r,i=function(e,t){return Ze(t,function(t,n){var r=ei(e,n),o=void 0===r?0:parseInt(r,10);return isNaN(o)?t:t+o},0)},a=function(e,t,n){var r=i(e,n),o=t>r?t-r:0;return o};return{set:n,get:r,getOuter:o,aggregate:i,max:a}}function O(e){return{getBookmark:t(Fp,e),moveToBookmark:t(Up,e)}}function B(e,t){var n,r;return{selectorChangedWithUnbind:function(o,i){return n||(n={},r={},t.on("NodeChange",function(t){var o=t.element,i=e.getParents(o,null,e.getRoot()),a={};er.each(n,function(t,n){er.each(i,function(o){if(e.is(o,n))return r[n]||(er.each(t,function(e){e(!0,{node:o,selector:n,parents:i})}),r[n]=t),a[n]=t,!1})}),er.each(r,function(e,t){a[t]||(delete r[t],er.each(e,function(e){e(!1,{node:o,selector:t,parents:i})}))})})),n[o]||(n[o]=[]),n[o].push(i),{unbind:function(){Rk(n,o,i),Rk(r,o,i)}}}}}function P(e,t){var n={},r=function(r,o){o||(o=ve(!0));var i=Je(Xk(r),function(t){var n=t.src;return!!jn.fileApi&&(!t.hasAttribute("data-mce-bogus")&&(!t.hasAttribute("data-mce-placeholder")&&(!(!n||n===jn.transparentSrc)&&(0===n.indexOf("blob:")?!e.isUploaded(n)&&o(t):0===n.indexOf("data:")&&o(t)))))}),a=Ke(i,function(e){if(void 0!==n[e.src])return new mc(function(t){n[e.src].then(function(n){return"string"==typeof n?n:void t({image:e,blobInfo:n.blobInfo})})});var r=new mc(function(n,r){Kk(t,e,n,r)}).then(function(e){return delete n[e.image.src],e})["catch"](function(t){return delete n[e.src],t});return n[e.src]=r,r});return mc.all(a)};return{findAll:r}}function L(t,n){var r={},o=function(e,t){return e?e.replace(/\/$/,"")+"/"+t.replace(/^\//,""):t},i=function(t,r,i,a){var u=new e.XMLHttpRequest;u.open("POST",n.url),u.withCredentials=n.credentials,u.upload.onprogress=function(e){a(e.loaded/e.total*100)},u.onerror=function(){i("Image upload failed due to a XHR Transport error. Code: "+u.status)},u.onload=function(){if(u.status<200||u.status>=300)return void i("HTTP Error: "+u.status);var e=JSON.parse(u.responseText);return e&&"string"==typeof e.location?void r(o(n.basePath,e.location)):void i("Invalid JSON: "+u.responseText)};var c=new e.FormData;c.append("file",t.blob(),t.filename()),u.send(c)},a=function(){return new mc(function(e){e([])})},u=function(e,t){return{url:t,blobInfo:e,status:!0}},c=function(e,t){return{url:"",blobInfo:e,status:!1,error:t}},s=function(e,t){er.each(r[e],function(e){e(t)}),delete r[e]},f=function(e,n,r){return t.markPending(e.blobUri()),new mc(function(o){var i,a,f=function(){};try{var l=function(){i&&(i.close(),a=f)},d=function(n){l(),t.markUploaded(e.blobUri(),n),s(e.blobUri(),u(e,n)),o(u(e,n))},m=function(n){l(),t.removeFailed(e.blobUri()),s(e.blobUri(),c(e,n)),o(c(e,n))};a=function(e){e<0||e>100||(i||(i=r()),i.progressBar.value(e))},n(e,d,m,a)}catch(p){o(c(e,p.message))}})},l=function(e){return e===i},d=function(e){var t=e.blobUri();return new mc(function(e){
r[t]=r[t]||[],r[t].push(e)})},m=function(e,r){return e=er.grep(e,function(e){return!t.isUploaded(e.blobUri())}),mc.all(er.map(e,function(e){return t.isPending(e.blobUri())?d(e):f(e,n.handler,r)}))},p=function(e,t){return!n.url&&l(n.handler)?a():m(e,t)};return Fe(n.handler)===!1&&(n.handler=i),{upload:p}}function I(){var e=1,t=2,n={},r=function(e,t){return{status:e,resultUri:t}},o=function(e){return e in n},i=function(e){var t=n[e];return t?t.resultUri:null},a=function(t){return!!o(t)&&n[t].status===e},u=function(e){return!!o(e)&&n[e].status===t},c=function(t){n[t]=r(e,null)},s=function(e,o){n[e]=r(t,o)},f=function(e){delete n[e]},l=function(){n={}};return{hasBlobUri:o,getResultUri:i,isPending:a,isUploaded:u,markPending:c,markUploaded:s,removeFailed:f,destroy:l}}function M(e){var t={},n=function(e){return e?t[e]:t},r=function(e){return Et(t,e)},o=function(e,n){e&&("string"!=typeof e?er.each(e,function(e,t){o(t,e)}):(Pe(n)||(n=[n]),er.each(n,function(e){"undefined"==typeof e.deep&&(e.deep=!e.selector),"undefined"==typeof e.split&&(e.split=!e.selector||e.inline),"undefined"==typeof e.remove&&e.selector&&!e.inline&&(e.remove="none"),e.selector&&e.inline&&(e.mixed=!0,e.block_expand=!0),"string"==typeof e.classes&&(e.classes=e.classes.split(/\s+/))}),t[e]=n))},i=function(e){return e&&t[e]&&delete t[e],t};return o(L_(e.dom)),o(Bd(e)),{get:n,has:r,register:o,unregister:i}}function F(e){var t=function(t,n){return Sg(e,t,n)},n=SC,r=function(t){return pk(e,t).fold(ve(!1),function(e){return t.setStart(e.startContainer,e.startOffset),t.setEnd(e.endContainer,e.endOffset),!0})};return{walk:t,split:n,normalize:r}}var U,z,j,H,V,q,$,W,K,X,Y,G,J,Q,Z,ee,te,ne,re=function(e){if(null===e)return"null";if(void 0===e)return"undefined";var t=typeof e;return"object"===t&&(Array.prototype.isPrototypeOf(e)||e.constructor&&"Array"===e.constructor.name)?"array":"object"===t&&(String.prototype.isPrototypeOf(e)||e.constructor&&"String"===e.constructor.name)?"string":t},oe=function(e){return["undefined","boolean","number","string","function","xml","null"].indexOf(e)!==-1},ie=function(e,t){var n=Array.prototype.slice.call(e);return n.sort(t)},ae=function(e,t){return ue(function(n,r){return e.eq(t(n),t(r))})},ue=function(e){return{eq:e}},ce=ue(function(e,t){return e===t}),se=ce,fe=function(e){return ue(function(t,n){if(t.length!==n.length)return!1;for(var r=t.length,o=0;o<r;o++)if(!e.eq(t[o],n[o]))return!1;return!0})},le=function(e,t){return ae(fe(e),function(e){return ie(e,t)})},de=function(e){return ue(function(t,n){var r=Object.keys(t),o=Object.keys(n);if(!le(se).eq(r,o))return!1;for(var i=r.length,a=0;a<i;a++){var u=r[a];if(!e.eq(t[u],n[u]))return!1}return!0})},me=ue(function(e,t){if(e===t)return!0;var n=re(e),r=re(t);return n===r&&(oe(n)?e===t:"array"===n?fe(me).eq(e,t):"object"===n&&de(me).eq(e,t))}),pe=function(){},ge=function(e,t){return function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return e(t.apply(null,n))}},he=function(e,t){return function(n){return e(t(n))}},ve=function(e){return function(){return e}},ye=function(e){return e},be=function(e){return function(t){return!e(t)}},Ce=function(e){return function(){throw new Error(e)}},we=ve(!1),xe=ve(!0),Se=function(){return Ne},Ne=function(){var e=function(e){return e.isNone()},t=function(e){return e()},n=function(e){return e},r={fold:function(e,t){return e()},is:we,isSome:we,isNone:xe,getOr:n,getOrThunk:t,getOrDie:function(e){throw new Error(e||"error: getOrDie called on none.")},getOrNull:ve(null),getOrUndefined:ve(void 0),or:n,orThunk:t,map:Se,each:pe,bind:Se,exists:we,forall:xe,filter:Se,equals:e,equals_:e,toArray:function(){return[]},toString:ve("none()")};return r}(),Ee=function(e){var t=ve(e),n=function(){return o},r=function(t){return t(e)},o={fold:function(t,n){return n(e)},is:function(t){return e===t},isSome:xe,isNone:we,getOr:t,getOrThunk:t,getOrDie:t,getOrNull:t,getOrUndefined:t,or:n,orThunk:n,map:function(t){return Ee(t(e))},each:function(t){t(e)},bind:r,exists:r,forall:r,filter:function(t){return t(e)?o:Ne},toArray:function(){return[e]},toString:function(){return"some("+e+")"},equals:function(t){return t.is(e)},equals_:function(t,n){return t.fold(we,function(t){return n(e,t)})}};return o},ke=function(e){return null===e||void 0===e?Ne:Ee(e)},_e={some:Ee,none:Se,from:ke},Te=function(e){var t=typeof e;return null===e?"null":"object"===t&&(Array.prototype.isPrototypeOf(e)||e.constructor&&"Array"===e.constructor.name)?"array":"object"===t&&(String.prototype.isPrototypeOf(e)||e.constructor&&"String"===e.constructor.name)?"string":t},Re=function(e){return function(t){return Te(t)===e}},Ae=function(e){return function(t){return typeof t===e}},De=function(e){return function(t){return e===t}},Oe=Re("string"),Be=Re("object"),Pe=Re("array"),Le=De(null),Ie=Ae("boolean"),Me=De(void 0),Fe=Ae("function"),Ue=Ae("number"),ze=Array.prototype.slice,je=Array.prototype.indexOf,He=Array.prototype.push,Ve=function(e,t){return je.call(e,t)},qe=function(e,t){var n=Ve(e,t);return n===-1?_e.none():_e.some(n)},$e=function(e,t){return Ve(e,t)>-1},We=function(e,t){for(var n=0,r=e.length;n<r;n++){var o=e[n];if(t(o,n))return!0}return!1},Ke=function(e,t){for(var n=e.length,r=new Array(n),o=0;o<n;o++){var i=e[o];r[o]=t(i,o)}return r},Xe=function(e,t){for(var n=0,r=e.length;n<r;n++){var o=e[n];t(o,n)}},Ye=function(e,t){for(var n=e.length-1;n>=0;n--){var r=e[n];t(r,n)}},Ge=function(e,t){for(var n=[],r=[],o=0,i=e.length;o<i;o++){var a=e[o],u=t(a,o)?n:r;u.push(a)}return{pass:n,fail:r}},Je=function(e,t){for(var n=[],r=0,o=e.length;r<o;r++){var i=e[r];t(i,r)&&n.push(i)}return n},Qe=function(e,t,n){return Ye(e,function(e){n=t(n,e)}),n},Ze=function(e,t,n){return Xe(e,function(e){n=t(n,e)}),n},et=function(e,t,n){for(var r=0,o=e.length;r<o;r++){var i=e[r];if(t(i,r))return _e.some(i);if(n(i,r))break}return _e.none()},tt=function(e,t){return et(e,t,we)},nt=function(e,t){for(var n=0,r=e.length;n<r;n++){var o=e[n];if(t(o,n))return _e.some(n)}return _e.none()},rt=function(e){for(var t=[],n=0,r=e.length;n<r;++n){if(!Pe(e[n]))throw new Error("Arr.flatten item "+n+" was not an array, input: "+e);He.apply(t,e[n])}return t},ot=function(e,t){return rt(Ke(e,t))},it=function(e,t){for(var n=0,r=e.length;n<r;++n){var o=e[n];if(t(o,n)!==!0)return!1}return!0},at=function(e){var t=ze.call(e,0);return t.reverse(),t},ut=function(e,t){return Je(e,function(e){return!$e(t,e)})},ct=function(e,t){for(var n={},r=0,o=e.length;r<o;r++){var i=e[r];n[String(i)]=t(i,r)}return n},st=function(e,t){var n=ze.call(e,0);return n.sort(t),n},ft=function(e){return 0===e.length?_e.none():_e.some(e[0])},lt=function(e){return 0===e.length?_e.none():_e.some(e[e.length-1])},dt=Fe(Array.from)?Array.from:function(e){return ze.call(e)},mt=Object.keys,pt=Object.hasOwnProperty,gt=function(e,t){for(var n=mt(e),r=0,o=n.length;r<o;r++){var i=n[r],a=e[i];t(a,i)}},ht=function(e,t){return vt(e,function(e,n){return{k:n,v:t(e,n)}})},vt=function(e,t){var n={};return gt(e,function(e,r){var o=t(e,r);n[o.k]=o.v}),n},yt=function(e){return function(t,n){e[n]=t}},bt=function(e,t,n,r){var o={};return gt(e,function(e,o){(t(e,o)?n:r)(e,o)}),o},Ct=function(e,t){var n={},r={};return bt(e,t,yt(n),yt(r)),{t:n,f:r}},wt=function(e,t){var n={};return bt(e,t,yt(n),pe),n},xt=function(e,t){var n=[];return gt(e,function(e,r){n.push(t(e,r))}),n},St=function(e){return xt(e,function(e){return e})},Nt=function(e,t){return Et(e,t)?_e.from(e[t]):_e.none()},Et=function(e,t){return pt.call(e,t)},kt=function(e,t,n){return void 0===n&&(n=me),de(n).eq(e,t)},_t=Array.isArray,Tt=function(e){var t,n,r=e;if(!_t(e))for(r=[],t=0,n=e.length;t<n;t++)r[t]=e[t];return r},Rt=function(e,t,n){var r,o;if(!e)return 0;if(n=n||e,void 0!==e.length){for(r=0,o=e.length;r<o;r++)if(t.call(n,e[r],r,e)===!1)return 0}else for(r in e)if(e.hasOwnProperty(r)&&t.call(n,e[r],r,e)===!1)return 0;return 1},At=function(e,t){var n=[];return Rt(e,function(r,o){n.push(t(r,o,e))}),n},Dt=function(e,t){var n=[];return Rt(e,function(r,o){t&&!t(r,o,e)||n.push(r)}),n},Ot=function(e,t){var n,r;if(e)for(n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},Bt=function(e,t,n,r){var o=0;for(arguments.length<3&&(n=e[0]);o<e.length;o++)n=t.call(r,n,e[o],o);return n},Pt=function(e,t,n){var r,o;for(r=0,o=e.length;r<o;r++)if(t.call(n,e[r],r,e))return r;return-1},Lt=function(e){return e[e.length-1]},It=function(){return It=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++){t=arguments[n];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},It.apply(this,arguments)},Mt=function(e){var t,n=!1;return function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return n||(n=!0,t=e.apply(null,r)),t}},Ft=function(e,t){for(var n=0;n<e.length;n++){var r=e[n];if(r.test(t))return r}},Ut=function(e,t){var n=Ft(e,t);if(!n)return{major:0,minor:0};var r=function(e){return Number(t.replace(n,"$"+e))};return Ht(r(1),r(2))},zt=function(e,t){var n=String(t).toLowerCase();return 0===e.length?jt():Ut(e,n)},jt=function(){return Ht(0,0)},Ht=function(e,t){return{major:e,minor:t}},Vt={nu:Ht,detect:zt,unknown:jt},qt="Edge",$t="Chrome",Wt="IE",Kt="Opera",Xt="Firefox",Yt="Safari",Gt=function(){return Jt({current:void 0,version:Vt.unknown()})},Jt=function(e){var t=e.current,n=e.version,r=function(e){return function(){return t===e}};return{current:t,version:n,isEdge:r(qt),isChrome:r($t),isIE:r(Wt),isOpera:r(Kt),isFirefox:r(Xt),isSafari:r(Yt)}},Qt={unknown:Gt,nu:Jt,edge:ve(qt),chrome:ve($t),ie:ve(Wt),opera:ve(Kt),firefox:ve(Xt),safari:ve(Yt)},Zt="Windows",en="iOS",tn="Android",nn="Linux",rn="OSX",on="Solaris",an="FreeBSD",un="ChromeOS",cn=function(){return sn({current:void 0,version:Vt.unknown()})},sn=function(e){var t=e.current,n=e.version,r=function(e){return function(){return t===e}};return{current:t,version:n,isWindows:r(Zt),isiOS:r(en),isAndroid:r(tn),isOSX:r(rn),isLinux:r(nn),isSolaris:r(on),isFreeBSD:r(an),isChromeOS:r(un)}},fn={unknown:cn,nu:sn,windows:ve(Zt),ios:ve(en),android:ve(tn),linux:ve(nn),osx:ve(rn),solaris:ve(on),freebsd:ve(an),chromeos:ve(un)},ln=function(e,t,n,r){var o=e.isiOS()&&/ipad/i.test(n)===!0,i=e.isiOS()&&!o,a=e.isiOS()||e.isAndroid(),u=a||r("(pointer:coarse)"),c=o||!i&&a&&r("(min-device-width:768px)"),s=i||a&&!c,f=t.isSafari()&&e.isiOS()&&/safari/i.test(n)===!1,l=!s&&!c&&!f;return{isiPad:ve(o),isiPhone:ve(i),isTablet:ve(c),isPhone:ve(s),isTouch:ve(u),isAndroid:e.isAndroid,isiOS:e.isiOS,isWebView:ve(f),isDesktop:ve(l)}},dn=function(e,t){var n=String(t).toLowerCase();return tt(e,function(e){return e.search(n)})},mn=function(e,t){return dn(e,t).map(function(e){var n=Vt.detect(e.versionRegexes,t);return{current:e.name,version:n}})},pn=function(e,t){return dn(e,t).map(function(e){var n=Vt.detect(e.versionRegexes,t);return{current:e.name,version:n}})},gn={detectBrowser:mn,detectOs:pn},hn=function(e,t,n){return""===t||e.length>=t.length&&e.substr(n,n+t.length)===t},vn=function(e,t){return e.indexOf(t)!==-1},yn=function(e,t){return hn(e,t,0)},bn=function(e){return function(t){return t.replace(e,"")}},Cn=bn(/^\s+|\s+$/g),wn=bn(/^\s+/g),xn=bn(/\s+$/g),Sn=/.*?version\/\ ?([0-9]+)\.([0-9]+).*/,Nn=function(e){return function(t){return vn(t,e)}},En=[{name:"Edge",versionRegexes:[/.*?edge\/ ?([0-9]+)\.([0-9]+)$/],search:function(e){return vn(e,"edge/")&&vn(e,"chrome")&&vn(e,"safari")&&vn(e,"applewebkit")}},{name:"Chrome",versionRegexes:[/.*?chrome\/([0-9]+)\.([0-9]+).*/,Sn],search:function(e){return vn(e,"chrome")&&!vn(e,"chromeframe")}},{name:"IE",versionRegexes:[/.*?msie\ ?([0-9]+)\.([0-9]+).*/,/.*?rv:([0-9]+)\.([0-9]+).*/],search:function(e){return vn(e,"msie")||vn(e,"trident")}},{name:"Opera",versionRegexes:[Sn,/.*?opera\/([0-9]+)\.([0-9]+).*/],search:Nn("opera")},{name:"Firefox",versionRegexes:[/.*?firefox\/\ ?([0-9]+)\.([0-9]+).*/],search:Nn("firefox")},{name:"Safari",versionRegexes:[Sn,/.*?cpu os ([0-9]+)_([0-9]+).*/],search:function(e){return(vn(e,"safari")||vn(e,"mobile/"))&&vn(e,"applewebkit")}}],kn=[{name:"Windows",search:Nn("win"),versionRegexes:[/.*?windows\ nt\ ?([0-9]+)\.([0-9]+).*/]},{name:"iOS",search:function(e){return vn(e,"iphone")||vn(e,"ipad")},versionRegexes:[/.*?version\/\ ?([0-9]+)\.([0-9]+).*/,/.*cpu os ([0-9]+)_([0-9]+).*/,/.*cpu iphone os ([0-9]+)_([0-9]+).*/]},{name:"Android",search:Nn("android"),versionRegexes:[/.*?android\ ?([0-9]+)\.([0-9]+).*/]},{name:"OSX",search:Nn("mac os x"),versionRegexes:[/.*?mac\ os\ x\ ?([0-9]+)_([0-9]+).*/]},{name:"Linux",search:Nn("linux"),versionRegexes:[]},{name:"Solaris",search:Nn("sunos"),versionRegexes:[]},{name:"FreeBSD",search:Nn("freebsd"),versionRegexes:[]},{name:"ChromeOS",search:Nn("cros"),versionRegexes:[/.*?chrome\/([0-9]+)\.([0-9]+).*/]}],_n={browsers:ve(En),oses:ve(kn)},Tn=function(e,t){var n=_n.browsers(),r=_n.oses(),o=gn.detectBrowser(n,e).fold(Qt.unknown,Qt.nu),i=gn.detectOs(r,e).fold(fn.unknown,fn.nu),a=ln(i,o,e,t);return{browser:o,os:i,deviceType:a}},Rn={detect:Tn},An=function(t){return e.window.matchMedia(t).matches},Dn=Mt(function(){return Rn.detect(e.navigator.userAgent,An)}),On=function(){return Dn()},Bn=e.navigator.userAgent,Pn=On(),Ln=Pn.browser,In=Pn.os,Mn=Pn.deviceType,Fn=/WebKit/.test(Bn)&&!Ln.isEdge(),Un="FormData"in e.window&&"FileReader"in e.window&&"URL"in e.window&&!!e.URL.createObjectURL,zn=Bn.indexOf("Windows Phone")!==-1,jn={opera:Ln.isOpera(),webkit:Fn,ie:!(!Ln.isIE()&&!Ln.isEdge())&&Ln.version.major,gecko:Ln.isFirefox(),mac:In.isOSX()||In.isiOS(),iOS:Mn.isiPad()||Mn.isiPhone(),android:In.isAndroid(),contentEditable:!0,transparentSrc:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",caretAfter:!0,range:e.window.getSelection&&"Range"in e.window,documentMode:Ln.isIE()?e.document.documentMode||7:10,fileApi:Un,ceFalse:!0,cacheSuffix:null,container:null,experimentalShadowDom:!1,canHaveCSP:!Ln.isIE(),desktop:Mn.isDesktop(),windowsPhone:zn,browser:{current:Ln.current,version:Ln.version,isChrome:Ln.isChrome,isEdge:Ln.isEdge,isFirefox:Ln.isFirefox,isIE:Ln.isIE,isOpera:Ln.isOpera,isSafari:Ln.isSafari},os:{current:In.current,version:In.version,isAndroid:In.isAndroid,isChromeOS:In.isChromeOS,isFreeBSD:In.isFreeBSD,isiOS:In.isiOS,isLinux:In.isLinux,isOSX:In.isOSX,isSolaris:In.isSolaris,isWindows:In.isWindows},deviceType:{isDesktop:Mn.isDesktop,isiPad:Mn.isiPad,isiPhone:Mn.isiPhone,isPhone:Mn.isPhone,isTablet:Mn.isTablet,isTouch:Mn.isTouch,isWebView:Mn.isWebView}},Hn=/^\s*|\s*$/g,Vn=function(e){return null===e||void 0===e?"":(""+e).replace(Hn,"")},qn=function(e,t){return t?!("array"!==t||!_t(e))||typeof e===t:void 0!==e},$n=function(e,t,n){var r;for(e=e||[],t=t||",","string"==typeof e&&(e=e.split(t)),n=n||{},r=e.length;r--;)n[e[r]]={};return n},Wn=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},Kn=function(e,t,n){var r,o,i,a=this,u=0;e=/^((static) )?([\w.]+)(:([\w.]+))?/.exec(e);var c=e[3].match(/(^|\.)(\w+)$/i)[2],s=a.createNS(e[3].replace(/\.\w+$/,""),n);if(!s[c]){if("static"===e[2])return s[c]=t,void(this.onCreate&&this.onCreate(e[2],e[3],s[c]));t[c]||(t[c]=function(){},u=1),s[c]=t[c],a.extend(s[c].prototype,t),e[5]&&(r=a.resolve(e[5]).prototype,o=e[5].match(/\.(\w+)$/i)[1],i=s[c],u?s[c]=function(){return r[o].apply(this,arguments)}:s[c]=function(){return this.parent=r[o],i.apply(this,arguments)},s[c].prototype[c]=s[c],a.each(r,function(e,t){s[c].prototype[t]=r[t]}),a.each(t,function(e,t){r[t]?s[c].prototype[t]=function(){return this.parent=r[t],e.apply(this,arguments)}:t!==c&&(s[c].prototype[t]=e)})),a.each(t["static"],function(e,t){s[c][t]=e})}},Xn=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];for(var r=0;r<t.length;r++){var o=t[r];for(var i in o)if(o.hasOwnProperty(i)){var a=o[i];void 0!==a&&(e[i]=a)}}return e},Yn=function(e,t,n,r){r=r||this,e&&(n&&(e=e[n]),Rt(e,function(e,o){return t.call(r,e,o,n)!==!1&&void Yn(e,t,n,r)}))},Gn=function(t,n){var r,o;for(n=n||e.window,t=t.split("."),r=0;r<t.length;r++)o=t[r],n[o]||(n[o]={}),n=n[o];return n},Jn=function(t,n){var r,o;for(n=n||e.window,t=t.split("."),r=0,o=t.length;r<o&&(n=n[t[r]],n);r++);return n},Qn=function(e,t){return!e||qn(e,"array")?e:At(e.split(t||","),Vn)},Zn=function(e){var t=jn.cacheSuffix;return t&&(e+=(e.indexOf("?")===-1?"?":"&")+t),e},er={trim:Vn,isArray:_t,is:qn,toArray:Tt,makeMap:$n,each:Rt,map:At,grep:Dt,inArray:Ot,hasOwn:Wn,extend:Xn,create:Kn,walk:Yn,createNS:Gn,resolve:Jn,explode:Qn,_addCacheSuffix:Zn},tr=function(t,n){var r=n||e.document,o=r.createElement("div");if(o.innerHTML=t,!o.hasChildNodes()||o.childNodes.length>1)throw e.console.error("HTML does not have a single root node",t),new Error("HTML must have a single root node");return or(o.childNodes[0])},nr=function(t,n){var r=n||e.document,o=r.createElement(t);return or(o)},rr=function(t,n){var r=n||e.document,o=r.createTextNode(t);return or(o)},or=function(e){if(null===e||void 0===e)throw new Error("Node cannot be null or undefined");return{dom:ve(e)}},ir=function(e,t,n){var r=e.dom();return _e.from(r.elementFromPoint(t,n)).map(or)},ar={fromHtml:tr,fromTag:nr,fromText:rr,fromDom:or,fromPoint:ir},ur=("undefined"!=typeof e.window?e.window:Function("return this;")(),8),cr=9,sr=11,fr=1,lr=3,dr=function(e){var t=e.dom().nodeName;return t.toLowerCase()},mr=function(e){return e.dom().nodeType},pr=function(e){return function(t){return mr(t)===e}},gr=function(e){return mr(e)===ur||"#comment"===dr(e)},hr=pr(fr),vr=pr(lr),yr=pr(cr),br=pr(sr),Cr=function(e){var t=e.dom().head;if(null===t||void 0===t)throw new Error("Head is not available yet");return ar.fromDom(t)},wr=function(e,t){var n=[],r=function(e){return n.push(e),t(e)},o=t(e);do o=o.bind(r);while(o.isSome());return n},xr=function(e,t,n){return 0!==(e.compareDocumentPosition(t)&n)},Sr=function(t,n){return xr(t,n,e.Node.DOCUMENT_POSITION_CONTAINED_BY)},Nr=function(e,t){var n=e.dom();if(n.nodeType!==fr)return!1;var r=n;if(void 0!==r.matches)return r.matches(t);if(void 0!==r.msMatchesSelector)return r.msMatchesSelector(t);if(void 0!==r.webkitMatchesSelector)return r.webkitMatchesSelector(t);if(void 0!==r.mozMatchesSelector)return r.mozMatchesSelector(t);throw new Error("Browser lacks native selectors")},Er=function(e){return e.nodeType!==fr&&e.nodeType!==cr&&e.nodeType!==sr||0===e.childElementCount},kr=function(t,n){var r=void 0===n?e.document:n.dom();return Er(r)?[]:Ke(r.querySelectorAll(t),ar.fromDom)},_r=function(t,n){var r=void 0===n?e.document:n.dom();return Er(r)?_e.none():_e.from(r.querySelector(t)).map(ar.fromDom)},Tr=function(e,t){return e.dom()===t.dom()},Rr=function(e,t){var n=e.dom(),r=t.dom();return n!==r&&n.contains(r)},Ar=function(e,t){return Sr(e.dom(),t.dom())},Dr=function(e,t){return On().browser.isIE()?Ar(e,t):Rr(e,t)},Or=function(e){return ar.fromDom(e.dom().ownerDocument)},Br=function(e){return yr(e)?e:Or(e)},Pr=function(e){return ar.fromDom(e.dom().ownerDocument.documentElement)},Lr=function(e){return ar.fromDom(e.dom().ownerDocument.defaultView)},Ir=function(e){return _e.from(e.dom().parentNode).map(ar.fromDom)},Mr=function(e,t){for(var n=Fe(t)?t:we,r=e.dom(),o=[];null!==r.parentNode&&void 0!==r.parentNode;){var i=r.parentNode,a=ar.fromDom(i);if(o.push(a),n(a)===!0)break;r=i}return o},Fr=function(e){var t=function(t){return Je(t,function(t){return!Tr(e,t)})};return Ir(e).map(Vr).map(t).getOr([])},Ur=function(e){return _e.from(e.dom().previousSibling).map(ar.fromDom)},zr=function(e){return _e.from(e.dom().nextSibling).map(ar.fromDom)},jr=function(e){return at(wr(e,Ur))},Hr=function(e){return wr(e,zr)},Vr=function(e){return Ke(e.dom().childNodes,ar.fromDom)},qr=function(e,t){var n=e.dom().childNodes;return _e.from(n[t]).map(ar.fromDom)},$r=function(e){return qr(e,0)},Wr=function(e){return qr(e,e.dom().childNodes.length-1)},Kr=function(e){return e.dom().childNodes.length},Xr=function(e){return br(e)},Yr=Fe(e.Element.prototype.attachShadow)&&Fe(e.Node.prototype.getRootNode),Gr=Yr?function(e){return ar.fromDom(e.dom().getRootNode())}:Br,Jr=function(e){return Xr(e)?e:Cr(Br(e))},Qr=function(e){var t=Gr(e);return Xr(t)?_e.some(t):_e.none()},Zr=function(e){return ar.fromDom(e.dom().host)},eo=function(e,t){var n=Ir(e);n.each(function(n){n.dom().insertBefore(t.dom(),e.dom())})},to=function(e,t){var n=zr(e);n.fold(function(){var n=Ir(e);n.each(function(e){ro(e,t)})},function(e){eo(e,t)})},no=function(e,t){var n=$r(e);n.fold(function(){ro(e,t)},function(n){e.dom().insertBefore(t.dom(),n.dom())})},ro=function(e,t){e.dom().appendChild(t.dom())},oo=function(e,t){eo(e,t),ro(t,e)},io=function(e,t){Xe(t,function(t){eo(e,t)})},ao=function(e,t){Xe(t,function(t){ro(e,t)})},uo=function(e){e.dom().textContent="",Xe(Vr(e),function(e){co(e)})},co=function(e){var t=e.dom();null!==t.parentNode&&t.parentNode.removeChild(t)},so=function(e){var t=Vr(e);t.length>0&&io(e,t),co(e)},fo=function(e){var t=vr(e)?e.dom().parentNode:e.dom();return void 0!==t&&null!==t&&null!==t.ownerDocument&&Qr(ar.fromDom(t)).fold(function(){return t.ownerDocument.body.contains(t)},he(fo,Zr))},lo=function(e,t){var n=function(n,r){return lo(e+n,t+r)};return{left:ve(e),top:ve(t),translate:n}},mo=lo,po=function(e){var t=e.getBoundingClientRect();return mo(t.left,t.top)},go=function(e,t){return void 0!==e?e:void 0!==t?t:0},ho=function(e){var t=e.dom().ownerDocument,n=t.body,r=t.defaultView,o=t.documentElement;if(n===e.dom())return mo(n.offsetLeft,n.offsetTop);var i=go(r.pageYOffset,o.scrollTop),a=go(r.pageXOffset,o.scrollLeft),u=go(o.clientTop,n.clientTop),c=go(o.clientLeft,n.clientLeft);return vo(e).translate(a-c,i-u)},vo=function(e){var t=e.dom(),n=t.ownerDocument,r=n.body;return r===t?mo(r.offsetLeft,r.offsetTop):fo(e)?po(t):mo(0,0)},yo=function(t){var n=void 0!==t?t.dom():e.document,r=n.body.scrollLeft||n.documentElement.scrollLeft,o=n.body.scrollTop||n.documentElement.scrollTop;return mo(r,o)},bo=function(t,n,r){var o=void 0!==r?r.dom():e.document,i=o.defaultView;i.scrollTo(t,n)},Co=function(e,t){var n=On().browser.isSafari();n&&Fe(e.dom().scrollIntoViewIfNeeded)?e.dom().scrollIntoViewIfNeeded(!1):e.dom().scrollIntoView(t)},wo=function(t){var n=void 0===t?e.window:t;return _e.from(n.visualViewport)},xo=function(e,t,n,r){return{x:e,y:t,width:n,height:r,right:e+n,bottom:t+r}},So=function(t){var n=void 0===t?e.window:t,r=n.document,o=yo(ar.fromDom(r));return wo(n).fold(function(){var e=n.document.documentElement,t=e.clientWidth,r=e.clientHeight;return xo(o.left(),o.top(),t,r)},function(e){return xo(Math.max(e.pageLeft,o.left()),Math.max(e.pageTop,o.top()),e.width,e.height)})},No=function(e){return function(t){return!!t&&t.nodeType===e}},Eo=function(e){return!!e&&!Object.getPrototypeOf(e)},ko=No(1),_o=function(e){var t=e.map(function(e){return e.toLowerCase()});return function(e){if(e&&e.nodeName){var n=e.nodeName.toLowerCase();return $e(t,n)}return!1}},To=function(e,t){var n=t.toLowerCase().split(" ");return function(t){var r,o;if(ko(t))for(r=0;r<n.length;r++){var i=t.ownerDocument.defaultView.getComputedStyle(t,null);if(o=i?i.getPropertyValue(e):null,o===n[r])return!0}return!1}},Ro=function(e){return function(t){return ko(t)&&t.hasAttribute(e)}},Ao=function(e,t){return function(n){return ko(n)&&n.getAttribute(e)===t}},Do=function(e){return ko(e)&&e.hasAttribute("data-mce-bogus")},Oo=function(e){return ko(e)&&"all"===e.getAttribute("data-mce-bogus")},Bo=function(e){return ko(e)&&"TABLE"===e.tagName},Po=function(e){return function(t){if(ko(t)){if(t.contentEditable===e)return!0;if(t.getAttribute("data-mce-contenteditable")===e)return!0}return!1}},Lo=_o(["textarea","input"]),Io=No(3),Mo=No(8),Fo=No(9),Uo=No(11),zo=_o(["br"]),jo=Po("true"),Ho=Po("false"),Vo=function(e){return void 0!==e.style&&Fe(e.style.getPropertyValue)},qo=function(t,n,r){if(!(Oe(r)||Ie(r)||Ue(r)))throw e.console.error("Invalid call to Attr.set. Key ",n,":: Value ",r,":: Element ",t),new Error("Attribute value was not simple");t.setAttribute(n,r+"")},$o=function(e,t,n){qo(e.dom(),t,n)},Wo=function(e,t){var n=e.dom();gt(t,function(e,t){qo(n,t,e)})},Ko=function(e,t){var n=e.dom().getAttribute(t);return null===n?void 0:n},Xo=function(e,t){return _e.from(Ko(e,t))},Yo=function(e,t){var n=e.dom();return!(!n||!n.hasAttribute)&&n.hasAttribute(t)},Go=function(e,t){e.dom().removeAttribute(t)},Jo=function(e){return Ze(e.dom().attributes,function(e,t){return e[t.name]=t.value,e},{})},Qo=function(t,n,r){if(!Oe(r))throw e.console.error("Invalid call to CSS.set. Property ",n,":: Value ",r,":: Element ",t),new Error("CSS value must be a string: "+r);Vo(t)&&t.style.setProperty(n,r)},Zo=function(e,t){var n=e.dom();gt(t,function(e,t){Qo(n,t,e)})},ei=function(t,n){var r=t.dom(),o=e.window.getComputedStyle(r),i=o.getPropertyValue(n);return""!==i||fo(t)?i:ti(r,n)},ti=function(e,t){return Vo(e)?e.style.getPropertyValue(t):""},ni=function(e,t){var n=e.dom(),r=ti(n,t);return _e.from(r).filter(function(e){return e.length>0})},ri=function(e){var t={},n=e.dom();if(Vo(n))for(var r=0;r<n.style.length;r++){var o=n.style.item(r);t[o]=n.style[o]}return t},oi=function(e){return e.dom().offsetWidth},ii=On().browser,ai=function(e){return tt(e,hr)},ui=function(e){return ii.isFirefox()&&"table"===dr(e)?ai(Vr(e)).filter(function(e){return"caption"===dr(e)}).bind(function(e){return ai(Hr(e)).map(function(t){var n=t.dom().offsetTop,r=e.dom().offsetTop,o=e.dom().offsetHeight;return n<=r?-o:0})}).getOr(0):0},ci=function(e,t){return e.children&&$e(e.children,t)},si=function(e,t,n){var r,o,i=0,a=0,u=e.ownerDocument;if(n=n?n:e,t){if(n===e&&t.getBoundingClientRect&&"static"===ei(ar.fromDom(e),"position"))return o=t.getBoundingClientRect(),i=o.left+(u.documentElement.scrollLeft||e.scrollLeft)-u.documentElement.clientLeft,a=o.top+(u.documentElement.scrollTop||e.scrollTop)-u.documentElement.clientTop,{x:i,y:a};for(r=t;r&&r!==n&&r.nodeType&&!ci(r,n);)i+=r.offsetLeft||0,a+=r.offsetTop||0,r=r.offsetParent;for(r=t.parentNode;r&&r!==n&&r.nodeType&&!ci(r,n);)i-=r.scrollLeft||0,a-=r.scrollTop||0,r=r.parentNode;a+=ui(ar.fromDom(t))}return{x:i,y:a}},fi=["article","aside","details","div","dt","figcaption","footer","form","fieldset","header","hgroup","html","main","nav","section","summary","body","p","dl","multicol","dd","figure","address","center","blockquote","h1","h2","h3","h4","h5","h6","listing","xmp","pre","plaintext","menu","dir","ul","ol","li","hr","table","tbody","thead","tfoot","th","tr","td","caption"],li=["area","base","basefont","br","col","frame","hr","img","input","isindex","link","meta","param","embed","source","wbr","track"],di=["td","th"],mi=["thead","tbody","tfoot"],pi=["h1","h2","h3","h4","h5","h6","p","div","address","pre","form","blockquote","center","dir","fieldset","header","footer","article","section","hgroup","aside","nav","figure"],gi=["h1","h2","h3","h4","h5","h6"],hi=["li","dd","dt"],vi=["ul","ol","dl"],yi=["pre","script","textarea","style"],bi=function(e){var t;return function(n){return t=t?t:ct(e,ve(!0)),t.hasOwnProperty(dr(n))}},Ci=bi(gi),wi=bi(fi),xi=function(e){return"table"===dr(e)},Si=function(e){return hr(e)&&!wi(e)},Ni=function(e){return hr(e)&&"br"===dr(e)},Ei=bi(pi),ki=bi(vi),_i=bi(hi),Ti=bi(li),Ri=bi(mi),Ai=bi(di),Di=bi(yi),Oi=/^[ \t\r\n]*$/,Bi=function(e){return Oi.test(e)},Pi=function(e){var t=e.previousSibling&&"SPAN"===e.previousSibling.nodeName,n=e.nextSibling&&"SPAN"===e.nextSibling.nodeName;return t&&n},Li=function(e){return e&&"SPAN"===e.tagName&&"bookmark"===e.getAttribute("data-mce-type")},Ii=function(e,t){var n,r=t.childNodes;if(!ko(t)||!Li(t)){for(n=r.length-1;n>=0;n--)Ii(e,r[n]);if(Fo(t)===!1){if(Io(t)&&t.nodeValue.length>0){var o=Bi(t.nodeValue);if(e.isBlock(t.parentNode)||!o)return;if(Pi(t))return}else if(ko(t)&&(r=t.childNodes,1===r.length&&Li(r[0])&&t.parentNode.insertBefore(r[0],t),r.length||Ti(ar.fromDom(t))))return;e.remove(t)}return t}},Mi=er.makeMap,Fi=/[&<>\"\u0060\u007E-\uD7FF\uE000-\uFFEF]|[\uD800-\uDBFF][\uDC00-\uDFFF]/g,Ui=/[<>&\u007E-\uD7FF\uE000-\uFFEF]|[\uD800-\uDBFF][\uDC00-\uDFFF]/g,zi=/[<>&\"\']/g,ji=/&#([a-z0-9]+);?|&([a-z0-9]+);/gi,Hi={128:"€",130:"‚",131:"ƒ",132:"„",133:"…",134:"†",135:"‡",136:"ˆ",137:"‰",138:"Š",139:"‹",140:"Œ",142:"Ž",145:"‘",146:"’",147:"“",148:"”",149:"•",150:"–",151:"—",152:"˜",153:"™",154:"š",155:"›",156:"œ",158:"ž",159:"Ÿ"},Vi={'"':"&quot;","'":"&#39;","<":"&lt;",">":"&gt;","&":"&amp;","`":"&#96;"},qi={"&lt;":"<","&gt;":">","&amp;":"&","&quot;":'"',"&apos;":"'"},$i=function(e){var t=ar.fromTag("div").dom();return t.innerHTML=e,t.textContent||t.innerText||e},Wi=function(e,t){var n,r,o,i={};if(e){for(e=e.split(","),t=t||10,n=0;n<e.length;n+=2)r=String.fromCharCode(parseInt(e[n],t)),Vi[r]||(o="&"+e[n+1]+";",i[r]=o,i[o]=r);return i}},Ki=Wi("50,nbsp,51,iexcl,52,cent,53,pound,54,curren,55,yen,56,brvbar,57,sect,58,uml,59,copy,5a,ordf,5b,laquo,5c,not,5d,shy,5e,reg,5f,macr,5g,deg,5h,plusmn,5i,sup2,5j,sup3,5k,acute,5l,micro,5m,para,5n,middot,5o,cedil,5p,sup1,5q,ordm,5r,raquo,5s,frac14,5t,frac12,5u,frac34,5v,iquest,60,Agrave,61,Aacute,62,Acirc,63,Atilde,64,Auml,65,Aring,66,AElig,67,Ccedil,68,Egrave,69,Eacute,6a,Ecirc,6b,Euml,6c,Igrave,6d,Iacute,6e,Icirc,6f,Iuml,6g,ETH,6h,Ntilde,6i,Ograve,6j,Oacute,6k,Ocirc,6l,Otilde,6m,Ouml,6n,times,6o,Oslash,6p,Ugrave,6q,Uacute,6r,Ucirc,6s,Uuml,6t,Yacute,6u,THORN,6v,szlig,70,agrave,71,aacute,72,acirc,73,atilde,74,auml,75,aring,76,aelig,77,ccedil,78,egrave,79,eacute,7a,ecirc,7b,euml,7c,igrave,7d,iacute,7e,icirc,7f,iuml,7g,eth,7h,ntilde,7i,ograve,7j,oacute,7k,ocirc,7l,otilde,7m,ouml,7n,divide,7o,oslash,7p,ugrave,7q,uacute,7r,ucirc,7s,uuml,7t,yacute,7u,thorn,7v,yuml,ci,fnof,sh,Alpha,si,Beta,sj,Gamma,sk,Delta,sl,Epsilon,sm,Zeta,sn,Eta,so,Theta,sp,Iota,sq,Kappa,sr,Lambda,ss,Mu,st,Nu,su,Xi,sv,Omicron,t0,Pi,t1,Rho,t3,Sigma,t4,Tau,t5,Upsilon,t6,Phi,t7,Chi,t8,Psi,t9,Omega,th,alpha,ti,beta,tj,gamma,tk,delta,tl,epsilon,tm,zeta,tn,eta,to,theta,tp,iota,tq,kappa,tr,lambda,ts,mu,tt,nu,tu,xi,tv,omicron,u0,pi,u1,rho,u2,sigmaf,u3,sigma,u4,tau,u5,upsilon,u6,phi,u7,chi,u8,psi,u9,omega,uh,thetasym,ui,upsih,um,piv,812,bull,816,hellip,81i,prime,81j,Prime,81u,oline,824,frasl,88o,weierp,88h,image,88s,real,892,trade,89l,alefsym,8cg,larr,8ch,uarr,8ci,rarr,8cj,darr,8ck,harr,8dl,crarr,8eg,lArr,8eh,uArr,8ei,rArr,8ej,dArr,8ek,hArr,8g0,forall,8g2,part,8g3,exist,8g5,empty,8g7,nabla,8g8,isin,8g9,notin,8gb,ni,8gf,prod,8gh,sum,8gi,minus,8gn,lowast,8gq,radic,8gt,prop,8gu,infin,8h0,ang,8h7,and,8h8,or,8h9,cap,8ha,cup,8hb,int,8hk,there4,8hs,sim,8i5,cong,8i8,asymp,8j0,ne,8j1,equiv,8j4,le,8j5,ge,8k2,sub,8k3,sup,8k4,nsub,8k6,sube,8k7,supe,8kl,oplus,8kn,otimes,8l5,perp,8m5,sdot,8o8,lceil,8o9,rceil,8oa,lfloor,8ob,rfloor,8p9,lang,8pa,rang,9ea,loz,9j0,spades,9j3,clubs,9j5,hearts,9j6,diams,ai,OElig,aj,oelig,b0,Scaron,b1,scaron,bo,Yuml,m6,circ,ms,tilde,802,ensp,803,emsp,809,thinsp,80c,zwnj,80d,zwj,80e,lrm,80f,rlm,80j,ndash,80k,mdash,80o,lsquo,80p,rsquo,80q,sbquo,80s,ldquo,80t,rdquo,80u,bdquo,810,dagger,811,Dagger,81g,permil,81p,lsaquo,81q,rsaquo,85c,euro",32),Xi=function(e,t){return e.replace(t?Fi:Ui,function(e){return Vi[e]||e})},Yi=function(e){return(""+e).replace(zi,function(e){return Vi[e]||e})},Gi=function(e,t){return e.replace(t?Fi:Ui,function(e){return e.length>1?"&#"+(1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320)+65536)+";":Vi[e]||"&#"+e.charCodeAt(0)+";"})},Ji=function(e,t,n){return n=n||Ki,e.replace(t?Fi:Ui,function(e){return Vi[e]||n[e]||e})},Qi=function(e,t){var n=Wi(t)||Ki,r=function(e,t){return e.replace(t?Fi:Ui,function(e){return void 0!==Vi[e]?Vi[e]:void 0!==n[e]?n[e]:e.length>1?"&#"+(1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320)+65536)+";":"&#"+e.charCodeAt(0)+";"})},o=function(e,t){return Ji(e,t,n)},i=Mi(e.replace(/\+/g,","));return i.named&&i.numeric?r:i.named?t?o:Ji:i.numeric?Gi:Xi},Zi=function(e){return e.replace(ji,function(e,t){return t?(t="x"===t.charAt(0).toLowerCase()?parseInt(t.substr(1),16):parseInt(t,10),t>65535?(t-=65536,String.fromCharCode(55296+(t>>10),56320+(1023&t))):Hi[t]||String.fromCharCode(t)):qi[e]||Ki[e]||$i(e)})},ea={encodeRaw:Xi,encodeAllRaw:Yi,encodeNumeric:Gi,encodeNamed:Ji,getEncodeFunc:Qi,decode:Zi},ta={},na={},ra=er.makeMap,oa=er.each,ia=er.extend,aa=er.explode,ua=er.inArray,ca=function(e,t){return e=er.trim(e),e?e.split(t||" "):[]},sa=function(e){
var t,n,r,o,i,a,u={},c=function(e,n,r){var o,i,a,c=function(e,t){var n,r,o={};for(n=0,r=e.length;n<r;n++)o[e[n]]=t||{};return o};for(r=r||[],n=n||"","string"==typeof r&&(r=ca(r)),e=ca(e),o=e.length;o--;)i=ca([t,n].join(" ")),a={attributes:c(i),attributesOrder:i,children:c(r,na)},u[e[o]]=a},s=function(e,t){var n,r,o,i;for(e=ca(e),n=e.length,t=ca(t);n--;)for(r=u[e[n]],o=0,i=t.length;o<i;o++)r.attributes[t[o]]={},r.attributesOrder.push(t[o])};return ta[e]?ta[e]:(t="id accesskey class dir lang style tabindex title role",n="address blockquote div dl fieldset form h1 h2 h3 h4 h5 h6 hr menu ol p pre table ul",r="a abbr b bdo br button cite code del dfn em embed i iframe img input ins kbd label map noscript object q s samp script select small span strong sub sup textarea u var #text #comment","html4"!==e&&(t+=" contenteditable contextmenu draggable dropzone hidden spellcheck translate",n+=" article aside details dialog figure main header footer hgroup section nav",r+=" audio canvas command datalist mark meter output picture progress time wbr video ruby bdi keygen"),"html5-strict"!==e&&(t+=" xml:lang",a="acronym applet basefont big font strike tt",r=[r,a].join(" "),oa(ca(a),function(e){c(e,"",r)}),i="center dir isindex noframes",n=[n,i].join(" "),o=[n,r].join(" "),oa(ca(i),function(e){c(e,"",o)})),o=o||[n,r].join(" "),c("html","manifest","head body"),c("head","","base command link meta noscript script style title"),c("title hr noscript br"),c("base","href target"),c("link","href rel media hreflang type sizes hreflang"),c("meta","name http-equiv content charset"),c("style","media type scoped"),c("script","src async defer type charset"),c("body","onafterprint onbeforeprint onbeforeunload onblur onerror onfocus onhashchange onload onmessage onoffline ononline onpagehide onpageshow onpopstate onresize onscroll onstorage onunload",o),c("address dt dd div caption","",o),c("h1 h2 h3 h4 h5 h6 pre p abbr code var samp kbd sub sup i b u bdo span legend em strong small s cite dfn","",r),c("blockquote","cite",o),c("ol","reversed start type","li"),c("ul","","li"),c("li","value",o),c("dl","","dt dd"),c("a","href target rel media hreflang type",r),c("q","cite",r),c("ins del","cite datetime",o),c("img","src sizes srcset alt usemap ismap width height"),c("iframe","src name width height",o),c("embed","src type width height"),c("object","data type typemustmatch name usemap form width height",[o,"param"].join(" ")),c("param","name value"),c("map","name",[o,"area"].join(" ")),c("area","alt coords shape href target rel media hreflang type"),c("table","border","caption colgroup thead tfoot tbody tr"+("html4"===e?" col":"")),c("colgroup","span","col"),c("col","span"),c("tbody thead tfoot","","tr"),c("tr","","td th"),c("td","colspan rowspan headers",o),c("th","colspan rowspan headers scope abbr",o),c("form","accept-charset action autocomplete enctype method name novalidate target",o),c("fieldset","disabled form name",[o,"legend"].join(" ")),c("label","form for",r),c("input","accept alt autocomplete checked dirname disabled form formaction formenctype formmethod formnovalidate formtarget height list max maxlength min multiple name pattern readonly required size src step type value width"),c("button","disabled form formaction formenctype formmethod formnovalidate formtarget name type value","html4"===e?o:r),c("select","disabled form multiple name required size","option optgroup"),c("optgroup","disabled label","option"),c("option","disabled label selected value"),c("textarea","cols dirname disabled form maxlength name readonly required rows wrap"),c("menu","type label",[o,"li"].join(" ")),c("noscript","",o),"html4"!==e&&(c("wbr"),c("ruby","",[r,"rt rp"].join(" ")),c("figcaption","",o),c("mark rt rp summary bdi","",r),c("canvas","width height",o),c("video","src crossorigin poster preload autoplay mediagroup loop muted controls width height buffered",[o,"track source"].join(" ")),c("audio","src crossorigin preload autoplay mediagroup loop muted controls buffered volume",[o,"track source"].join(" ")),c("picture","","img source"),c("source","src srcset type media sizes"),c("track","kind src srclang label default"),c("datalist","",[r,"option"].join(" ")),c("article section nav aside main header footer","",o),c("hgroup","","h1 h2 h3 h4 h5 h6"),c("figure","",[o,"figcaption"].join(" ")),c("time","datetime",r),c("dialog","open",o),c("command","type label icon disabled checked radiogroup command"),c("output","for form name",r),c("progress","value max",r),c("meter","value min max low high optimum",r),c("details","open",[o,"summary"].join(" ")),c("keygen","autofocus challenge disabled form keytype name")),"html5-strict"!==e&&(s("script","language xml:space"),s("style","xml:space"),s("object","declare classid code codebase codetype archive standby align border hspace vspace"),s("embed","align name hspace vspace"),s("param","valuetype type"),s("a","charset name rev shape coords"),s("br","clear"),s("applet","codebase archive code object alt name width height align hspace vspace"),s("img","name longdesc align border hspace vspace"),s("iframe","longdesc frameborder marginwidth marginheight scrolling align"),s("font basefont","size color face"),s("input","usemap align"),s("select"),s("textarea"),s("h1 h2 h3 h4 h5 h6 div p legend caption","align"),s("ul","type compact"),s("li","type"),s("ol dl menu dir","compact"),s("pre","width xml:space"),s("hr","align noshade size width"),s("isindex","prompt"),s("table","summary width frame rules cellspacing cellpadding align bgcolor"),s("col","width align char charoff valign"),s("colgroup","width align char charoff valign"),s("thead","align char charoff valign"),s("tr","align char charoff valign bgcolor"),s("th","axis align char charoff valign nowrap bgcolor width height"),s("form","accept"),s("td","abbr axis scope align char charoff valign nowrap bgcolor width height"),s("tfoot","align char charoff valign"),s("tbody","align char charoff valign"),s("area","nohref"),s("body","background bgcolor text link vlink alink")),"html4"!==e&&(s("input button select textarea","autofocus"),s("input textarea","placeholder"),s("a","download"),s("link script img","crossorigin"),s("img","loading"),s("iframe","sandbox seamless allowfullscreen loading")),oa(ca("a form meter progress dfn"),function(e){u[e]&&delete u[e].children[e]}),delete u.caption.children.table,delete u.script,ta[e]=u,u)},fa=function(e,t){var n;return e&&(n={},"string"==typeof e&&(e={"*":e}),oa(e,function(e,r){n[r]=n[r.toUpperCase()]="map"===t?ra(e,/[, ]/):aa(e,/[, ]/)})),n},la="\ufeff",da=" ",ma=function(e){return e===la},pa=function(e){return e.replace(/\uFEFF/g,"")},ga=function(e,t,n,r){var o=function(e){return e=parseInt(e,10).toString(16),e.length>1?e:"0"+e};return"#"+o(t)+o(n)+o(r)},ha=function(e,t){var n,r,o,i=/rgb\s*\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*\)/gi,a=/(?:url(?:(?:\(\s*\"([^\"]+)\"\s*\))|(?:\(\s*\'([^\']+)\'\s*\))|(?:\(\s*([^)\s]+)\s*\))))|(?:\'([^\']+)\')|(?:\"([^\"]+)\")/gi,u=/\s*([^:]+):\s*([^;]+);?/g,c=/\s+$/,s={},f=la;e=e||{},t&&(r=t.getValidStyles(),o=t.getInvalidStyles());var l=("\\\" \\' \\; \\: ; : "+f).split(" ");for(n=0;n<l.length;n++)s[l[n]]=f+n,s[f+n]=l[n];return{toHex:function(e){return e.replace(i,ga)},parse:function(t){var r,o,l,d,m={},p=e.url_converter,g=e.url_converter_scope||this,h=function(e,t,r){var o=m[e+"-top"+t];if(o){var i=m[e+"-right"+t];if(i){var a=m[e+"-bottom"+t];if(a){var u=m[e+"-left"+t];if(u){var c=[o,i,a,u];for(n=c.length-1;n--&&c[n]===c[n+1];);n>-1&&r||(m[e+t]=n===-1?c[0]:c.join(" "),delete m[e+"-top"+t],delete m[e+"-right"+t],delete m[e+"-bottom"+t],delete m[e+"-left"+t])}}}}},v=function(e){var t,n=m[e];if(n){for(n=n.split(" "),t=n.length;t--;)if(n[t]!==n[0])return!1;return m[e]=n[0],!0}},y=function(e,t,n,r){v(t)&&v(n)&&v(r)&&(m[e]=m[t]+" "+m[n]+" "+m[r],delete m[t],delete m[n],delete m[r])},b=function(e){return d=!0,s[e]},C=function(e,t){return d&&(e=e.replace(/\uFEFF[0-9]/g,function(e){return s[e]})),t||(e=e.replace(/\\([\'\";:])/g,"$1")),e},w=function(e){return String.fromCharCode(parseInt(e.slice(1),16))},x=function(e){return e.replace(/\\[0-9a-f]+/gi,w)},S=function(t,n,r,o,i,a){if(i=i||a)return i=C(i),"'"+i.replace(/\'/g,"\\'")+"'";if(n=C(n||r||o),!e.allow_script_urls){var u=n.replace(/[\s\r\n]+/g,"");if(/(java|vb)script:/i.test(u))return"";if(!e.allow_svg_data_urls&&/^data:image\/svg/i.test(u))return""}return p&&(n=p.call(g,n,"style")),"url('"+n.replace(/\'/g,"\\'")+"')"};if(t){for(t=t.replace(/[\u0000-\u001F]/g,""),t=t.replace(/\\[\"\';:\uFEFF]/g,b).replace(/\"[^\"]+\"|\'[^\']+\'/g,function(e){return e.replace(/[;:]/g,b)});r=u.exec(t);)if(u.lastIndex=r.index+r[0].length,o=r[1].replace(c,"").toLowerCase(),l=r[2].replace(c,""),o&&l){if(o=x(o),l=x(l),o.indexOf(f)!==-1||o.indexOf('"')!==-1)continue;if(!e.allow_script_urls&&("behavior"===o||/expression\s*\(|\/\*|\*\//.test(l)))continue;"font-weight"===o&&"700"===l?l="bold":"color"!==o&&"background-color"!==o||(l=l.toLowerCase()),l=l.replace(i,ga),l=l.replace(a,S),m[o]=d?C(l,!0):l}h("border","",!0),h("border","-width"),h("border","-color"),h("border","-style"),h("padding",""),h("margin",""),y("border","border-width","border-style","border-color"),"medium none"===m.border&&delete m.border,"none"===m["border-image"]&&delete m["border-image"]}return m},serialize:function(e,t){var n="",i=function(t){var o,i=r[t];if(i)for(var a=0,u=i.length;a<u;a++)t=i[a],o=e[t],o&&(n+=(n.length>0?" ":"")+t+": "+o+";")},a=function(e,t){var n=o["*"];return(!n||!n[e])&&(n=o[t],!(n&&n[e]))};return t&&r?(i("*"),i(t)):gt(e,function(e,r){!e||o&&!a(r,t)||(n+=(n.length>0?" ":"")+r+": "+e+";")}),n}}},va="mce-data-",ya=/^(?:mouse|contextmenu)|click/,ba={keyLocation:1,layerX:1,layerY:1,returnValue:1,webkitMovementX:1,webkitMovementY:1,keyIdentifier:1,mozPressure:1},Ca=function(e){return e.isDefaultPrevented===xa||e.isDefaultPrevented===wa},wa=function(){return!1},xa=function(){return!0},Sa=function(e,t,n,r){e.addEventListener?e.addEventListener(t,n,r||!1):e.attachEvent&&e.attachEvent("on"+t,n)},Na=function(e,t,n,r){e.removeEventListener?e.removeEventListener(t,n,r||!1):e.detachEvent&&e.detachEvent("on"+t,n)},Ea=function(e,t){if(e.composedPath){var n=e.composedPath();if(n&&n.length>0)return n[0]}return t},ka=function(t,n){var r,o=n||{};for(r in t)ba[r]||(o[r]=t[r]);if(o.target||(o.target=o.srcElement||e.document),jn.experimentalShadowDom&&(o.target=Ea(t,o.target)),t&&ya.test(t.type)&&void 0===t.pageX&&void 0!==t.clientX){var i=o.target.ownerDocument||e.document,a=i.documentElement,u=i.body;o.pageX=t.clientX+(a&&a.scrollLeft||u&&u.scrollLeft||0)-(a&&a.clientLeft||u&&u.clientLeft||0),o.pageY=t.clientY+(a&&a.scrollTop||u&&u.scrollTop||0)-(a&&a.clientTop||u&&u.clientTop||0)}return o.preventDefault=function(){o.isDefaultPrevented=xa,t&&(t.preventDefault?t.preventDefault():t.returnValue=!1)},o.stopPropagation=function(){o.isPropagationStopped=xa,t&&(t.stopPropagation?t.stopPropagation():t.cancelBubble=!0)},o.stopImmediatePropagation=function(){o.isImmediatePropagationStopped=xa,o.stopPropagation()},Ca(o)===!1&&(o.isDefaultPrevented=wa,o.isPropagationStopped=wa,o.isImmediatePropagationStopped=wa),"undefined"==typeof o.metaKey&&(o.metaKey=!1),o},_a=function(e,t,n){var r=e.document,o={type:"ready"};if(n.domLoaded)return void t(o);var i=function(){return"complete"===r.readyState||"interactive"===r.readyState&&r.body},a=function(){Na(e,"DOMContentLoaded",a),Na(e,"load",a),n.domLoaded||(n.domLoaded=!0,t(o))};i()?a():Sa(e,"DOMContentLoaded",a),Sa(e,"load",a)},Ta=function(){function t(){this.domLoaded=!1,this.events={},this.count=1,this.expando=va+(+new Date).toString(32),this.hasMouseEnterLeave="onmouseenter"in e.document.documentElement,this.hasFocusIn="onfocusin"in e.document.documentElement,this.count=1}return t.prototype.bind=function(t,n,r,o){var i,a,u,c,s,f,l,d=this,m=e.window,p=function(e){d.executeHandlers(ka(e||m.event),i)};if(t&&3!==t.nodeType&&8!==t.nodeType){t[d.expando]?i=t[d.expando]:(i=d.count++,t[d.expando]=i,d.events[i]={}),o=o||t;var g=n.split(" ");for(u=g.length;u--;)c=g[u],f=p,s=l=!1,"DOMContentLoaded"===c&&(c="ready"),d.domLoaded&&"ready"===c&&"complete"===t.readyState?r.call(o,ka({type:c})):(d.hasMouseEnterLeave||(s=d.mouseEnterLeave[c],s&&(f=function(e){var t=e.currentTarget,n=e.relatedTarget;if(n&&t.contains)n=t.contains(n);else for(;n&&n!==t;)n=n.parentNode;n||(e=ka(e||m.event),e.type="mouseout"===e.type?"mouseleave":"mouseenter",e.target=t,d.executeHandlers(e,i))})),d.hasFocusIn||"focusin"!==c&&"focusout"!==c||(l=!0,s="focusin"===c?"focus":"blur",f=function(e){e=ka(e||m.event),e.type="focus"===e.type?"focusin":"focusout",d.executeHandlers(e,i)}),a=d.events[i][c],a?"ready"===c&&d.domLoaded?r(ka({type:c})):a.push({func:r,scope:o}):(d.events[i][c]=a=[{func:r,scope:o}],a.fakeName=s,a.capture=l,a.nativeHandler=f,"ready"===c?_a(t,f,d):Sa(t,s||c,f,l)));return t=a=0,r}},t.prototype.unbind=function(e,t,n){var r,o,i,a,u;if(!e||3===e.nodeType||8===e.nodeType)return this;var c=e[this.expando];if(c){if(u=this.events[c],t){var s=t.split(" ");for(o=s.length;o--;)if(a=s[o],r=u[a]){if(n)for(i=r.length;i--;)if(r[i].func===n){var f=r.nativeHandler,l=r.fakeName,d=r.capture;r=r.slice(0,i).concat(r.slice(i+1)),r.nativeHandler=f,r.fakeName=l,r.capture=d,u[a]=r}n&&0!==r.length||(delete u[a],Na(e,r.fakeName||a,r.nativeHandler,r.capture))}}else gt(u,function(t,n){Na(e,t.fakeName||n,t.nativeHandler,t.capture)}),u={};for(a in u)if(Et(u,a))return this;delete this.events[c];try{delete e[this.expando]}catch(m){e[this.expando]=null}}return this},t.prototype.fire=function(e,t,n){var r;if(!e||3===e.nodeType||8===e.nodeType)return this;var o=ka(null,n);o.type=t,o.target=e;do r=e[this.expando],r&&this.executeHandlers(o,r),e=e.parentNode||e.ownerDocument||e.defaultView||e.parentWindow;while(e&&!o.isPropagationStopped());return this},t.prototype.clean=function(e){var t,n;if(!e||3===e.nodeType||8===e.nodeType)return this;if(e[this.expando]&&this.unbind(e),e.getElementsByTagName||(e=e.document),e&&e.getElementsByTagName)for(this.unbind(e),n=e.getElementsByTagName("*"),t=n.length;t--;)e=n[t],e[this.expando]&&this.unbind(e);return this},t.prototype.destroy=function(){this.events={}},t.prototype.cancel=function(e){return e&&(e.preventDefault(),e.stopImmediatePropagation()),!1},t.prototype.executeHandlers=function(e,t){var n=this.events[t],r=n&&n[e.type];if(r)for(var o=0,i=r.length;o<i;o++){var a=r[o];if(a&&a.func.call(a.scope,e)===!1&&e.preventDefault(),e.isImmediatePropagationStopped())return}},t.Event=new t,t}(),Ra="sizzle"+-new Date,Aa=e.window.document,Da=0,Oa=0,Ba=i(),Pa=i(),La=i(),Ia=function(e,t){return e===t&&(X=!0),0},Ma="undefined",Fa=1<<31,Ua={}.hasOwnProperty,za=[],ja=za.pop,Ha=za.push,Va=za.push,qa=za.slice,$a=za.indexOf||function(e){for(var t=0,n=this.length;t<n;t++)if(this[t]===e)return t;return-1},Wa="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",Ka="[\\x20\\t\\r\\n\\f]",Xa="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",Ya="\\["+Ka+"*("+Xa+")(?:"+Ka+"*([*^$|!~]?=)"+Ka+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+Xa+"))|)"+Ka+"*\\]",Ga=":("+Xa+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+Ya+")*)|.*)\\)|)",Ja=new RegExp("^"+Ka+"+|((?:^|[^\\\\])(?:\\\\.)*)"+Ka+"+$","g"),Qa=new RegExp("^"+Ka+"*,"+Ka+"*"),Za=new RegExp("^"+Ka+"*([>+~]|"+Ka+")"+Ka+"*"),eu=new RegExp("="+Ka+"*([^\\]'\"]*?)"+Ka+"*\\]","g"),tu=new RegExp(Ga),nu=new RegExp("^"+Xa+"$"),ru={ID:new RegExp("^#("+Xa+")"),CLASS:new RegExp("^\\.("+Xa+")"),TAG:new RegExp("^("+Xa+"|[*])"),ATTR:new RegExp("^"+Ya),PSEUDO:new RegExp("^"+Ga),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+Ka+"*(even|odd|(([+-]|)(\\d*)n|)"+Ka+"*(?:([+-]|)"+Ka+"*(\\d+)|))"+Ka+"*\\)|)","i"),bool:new RegExp("^(?:"+Wa+")$","i"),needsContext:new RegExp("^"+Ka+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+Ka+"*((?:-\\d)?\\d*)"+Ka+"*\\)|)(?=[^-]|$)","i")},ou=/^(?:input|select|textarea|button)$/i,iu=/^h\d$/i,au=/^[^{]+\{\s*\[native \w/,uu=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,cu=/[+~]/,su=/'|\\/g,fu=new RegExp("\\\\([\\da-f]{1,6}"+Ka+"?|("+Ka+")|.)","ig"),lu=function(e,t,n){var r="0x"+t-65536;return r!==r||n?t:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)};try{Va.apply(za=qa.call(Aa.childNodes),Aa.childNodes),za[Aa.childNodes.length].nodeType}catch(du){Va={apply:za.length?function(e,t){Ha.apply(e,qa.call(t))}:function(e,t){for(var n=e.length,r=0;e[n++]=t[r++];);e.length=n-1}}}var mu=function(e,t,n,r){var o,i,a,u,c,s,f,d,p,g;if((t?t.ownerDocument||t:Aa)!==G&&Y(t),t=t||G,n=n||[],!e||"string"!=typeof e)return n;if(1!==(u=t.nodeType)&&9!==u)return[];if(Q&&!r){if(o=uu.exec(e))if(a=o[1]){if(9===u){if(i=t.getElementById(a),!i||!i.parentNode)return n;if(i.id===a)return n.push(i),n}else if(t.ownerDocument&&(i=t.ownerDocument.getElementById(a))&&ne(t,i)&&i.id===a)return n.push(i),n}else{if(o[2])return Va.apply(n,t.getElementsByTagName(e)),n;if((a=o[3])&&U.getElementsByClassName)return Va.apply(n,t.getElementsByClassName(a)),n}if(U.qsa&&(!Z||!Z.test(e))){if(d=f=Ra,p=t,g=9===u&&e,1===u&&"object"!==t.nodeName.toLowerCase()){for(s=V(e),(f=t.getAttribute("id"))?d=f.replace(su,"\\$&"):t.setAttribute("id",d),d="[id='"+d+"'] ",c=s.length;c--;)s[c]=d+m(s[c]);p=cu.test(e)&&l(t.parentNode)||t,g=s.join(",")}if(g)try{return Va.apply(n,p.querySelectorAll(g)),n}catch(h){}finally{f||t.removeAttribute("id")}}}return $(e.replace(Ja,"$1"),t,n,r)};U=mu.support={},H=mu.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return!!t&&"HTML"!==t.nodeName},Y=mu.setDocument=function(e){function t(e){try{return e.top}catch(t){}return null}var n,r=e?e.ownerDocument||e:Aa,o=r.defaultView;return r!==G&&9===r.nodeType&&r.documentElement?(G=r,J=r.documentElement,Q=!H(r),o&&o!==t(o)&&(o.addEventListener?o.addEventListener("unload",function(){Y()},!1):o.attachEvent&&o.attachEvent("onunload",function(){Y()})),U.attributes=!0,U.getElementsByTagName=!0,U.getElementsByClassName=au.test(r.getElementsByClassName),U.getById=!0,z.find.ID=function(e,t){if(typeof t.getElementById!==Ma&&Q){var n=t.getElementById(e);return n&&n.parentNode?[n]:[]}},z.filter.ID=function(e){var t=e.replace(fu,lu);return function(e){return e.getAttribute("id")===t}},z.find.TAG=U.getElementsByTagName?function(e,t){if(typeof t.getElementsByTagName!==Ma)return t.getElementsByTagName(e)}:function(e,t){var n,r=[],o=0,i=t.getElementsByTagName(e);if("*"===e){for(;n=i[o++];)1===n.nodeType&&r.push(n);return r}return i},z.find.CLASS=U.getElementsByClassName&&function(e,t){if(Q)return t.getElementsByClassName(e)},ee=[],Z=[],U.disconnectedMatch=!0,Z=Z.length&&new RegExp(Z.join("|")),ee=ee.length&&new RegExp(ee.join("|")),n=au.test(J.compareDocumentPosition),ne=n||au.test(J.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},Ia=n?function(e,t){if(e===t)return X=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n?n:(n=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1,1&n||!U.sortDetached&&t.compareDocumentPosition(e)===n?e===r||e.ownerDocument===Aa&&ne(Aa,e)?-1:t===r||t.ownerDocument===Aa&&ne(Aa,t)?1:K?$a.call(K,e)-$a.call(K,t):0:4&n?-1:1)}:function(e,t){if(e===t)return X=!0,0;var n,o=0,i=e.parentNode,a=t.parentNode,c=[e],s=[t];if(!i||!a)return e===r?-1:t===r?1:i?-1:a?1:K?$a.call(K,e)-$a.call(K,t):0;if(i===a)return u(e,t);for(n=e;n=n.parentNode;)c.unshift(n);for(n=t;n=n.parentNode;)s.unshift(n);for(;c[o]===s[o];)o++;return o?u(c[o],s[o]):c[o]===Aa?-1:s[o]===Aa?1:0},r):G},mu.matches=function(e,t){return mu(e,null,null,t)},mu.matchesSelector=function(e,t){if((e.ownerDocument||e)!==G&&Y(e),t=t.replace(eu,"='$1']"),U.matchesSelector&&Q&&(!ee||!ee.test(t))&&(!Z||!Z.test(t)))try{var n=te.call(e,t);if(n||U.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(r){}return mu(t,G,null,[e]).length>0},mu.contains=function(e,t){return(e.ownerDocument||e)!==G&&Y(e),ne(e,t)},mu.attr=function(e,t){(e.ownerDocument||e)!==G&&Y(e);var n=z.attrHandle[t.toLowerCase()],r=n&&Ua.call(z.attrHandle,t.toLowerCase())?n(e,t,!Q):void 0;return void 0!==r?r:U.attributes||!Q?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},mu.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},mu.uniqueSort=function(e){var t,n=[],r=0,o=0;if(X=!U.detectDuplicates,K=!U.sortStable&&e.slice(0),e.sort(Ia),X){for(;t=e[o++];)t===e[o]&&(r=n.push(o));for(;r--;)e.splice(n[r],1)}return K=null,e},j=mu.getText=function(e){var t,n="",r=0,o=e.nodeType;if(o){if(1===o||9===o||11===o){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=j(e)}else if(3===o||4===o)return e.nodeValue}else for(;t=e[r++];)n+=j(t);return n},z=mu.selectors={cacheLength:50,createPseudo:a,match:ru,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(fu,lu),e[3]=(e[3]||e[4]||e[5]||"").replace(fu,lu),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||mu.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&mu.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return ru.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&tu.test(n)&&(t=V(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(fu,lu).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=Ba[e+" "];return t||(t=new RegExp("(^|"+Ka+")"+e+"("+Ka+"|$)"))&&Ba(e,function(e){return t.test("string"==typeof e.className&&e.className||typeof e.getAttribute!==Ma&&e.getAttribute("class")||"")})},ATTR:function(e,t,n){return function(r){var o=mu.attr(r,e);return null==o?"!="===t:!t||(o+="","="===t?o===n:"!="===t?o!==n:"^="===t?n&&0===o.indexOf(n):"*="===t?n&&o.indexOf(n)>-1:"$="===t?n&&o.slice(-n.length)===n:"~="===t?(" "+o+" ").indexOf(n)>-1:"|="===t&&(o===n||o.slice(0,n.length+1)===n+"-"))}},CHILD:function(e,t,n,r,o){var i="nth"!==e.slice(0,3),a="last"!==e.slice(-4),u="of-type"===t;return 1===r&&0===o?function(e){return!!e.parentNode}:function(t,n,c){var s,f,l,d,m,p,g=i!==a?"nextSibling":"previousSibling",h=t.parentNode,v=u&&t.nodeName.toLowerCase(),y=!c&&!u;if(h){if(i){for(;g;){for(l=t;l=l[g];)if(u?l.nodeName.toLowerCase()===v:1===l.nodeType)return!1;p=g="only"===e&&!p&&"nextSibling"}return!0}if(p=[a?h.firstChild:h.lastChild],a&&y){for(f=h[Ra]||(h[Ra]={}),s=f[e]||[],m=s[0]===Da&&s[1],d=s[0]===Da&&s[2],l=m&&h.childNodes[m];l=++m&&l&&l[g]||(d=m=0)||p.pop();)if(1===l.nodeType&&++d&&l===t){f[e]=[Da,m,d];break}}else if(y&&(s=(t[Ra]||(t[Ra]={}))[e])&&s[0]===Da)d=s[1];else for(;(l=++m&&l&&l[g]||(d=m=0)||p.pop())&&((u?l.nodeName.toLowerCase()!==v:1!==l.nodeType)||!++d||(y&&((l[Ra]||(l[Ra]={}))[e]=[Da,d]),l!==t)););return d-=o,d===r||d%r===0&&d/r>=0}}},PSEUDO:function(e,t){var n,r=z.pseudos[e]||z.setFilters[e.toLowerCase()]||mu.error("unsupported pseudo: "+e);return r[Ra]?r(t):r.length>1?(n=[e,e,"",t],z.setFilters.hasOwnProperty(e.toLowerCase())?a(function(e,n){for(var o,i=r(e,t),a=i.length;a--;)o=$a.call(e,i[a]),e[o]=!(n[o]=i[a])}):function(e){return r(e,0,n)}):r}},pseudos:{not:a(function(e){var t=[],n=[],r=q(e.replace(Ja,"$1"));return r[Ra]?a(function(e,t,n,o){for(var i,a=r(e,null,o,[]),u=e.length;u--;)(i=a[u])&&(e[u]=!(t[u]=i))}):function(e,o,i){return t[0]=e,r(t,null,i,n),!n.pop()}}),has:a(function(e){return function(t){return mu(e,t).length>0}}),contains:a(function(e){return e=e.replace(fu,lu),function(t){return(t.textContent||t.innerText||j(t)).indexOf(e)>-1}}),lang:a(function(e){return nu.test(e||"")||mu.error("unsupported lang: "+e),e=e.replace(fu,lu).toLowerCase(),function(t){var n;do if(n=Q?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return n=n.toLowerCase(),n===e||0===n.indexOf(e+"-");while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.window.location&&e.window.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===J},focus:function(e){return e===G.activeElement&&(!G.hasFocus||G.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:function(e){return e.disabled===!1},disabled:function(e){return e.disabled===!0},checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,e.selected===!0},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!z.pseudos.empty(e)},header:function(e){return iu.test(e.nodeName)},input:function(e){return ou.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:f(function(){return[0]}),last:f(function(e,t){return[t-1]}),eq:f(function(e,t,n){return[n<0?n+t:n]}),even:f(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:f(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:f(function(e,t,n){for(var r=n<0?n+t:n;--r>=0;)e.push(r);return e}),gt:f(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}},z.pseudos.nth=z.pseudos.eq,Xe(["radio","checkbox","file","password","image"],function(e){z.pseudos[e]=c(e)}),Xe(["submit","reset"],function(e){z.pseudos[e]=s(e)}),d.prototype=z.filters=z.pseudos,z.setFilters=new d,V=mu.tokenize=function(e,t){var n,r,o,i,a,u,c,s=Pa[e+" "];if(s)return t?0:s.slice(0);for(a=e,u=[],c=z.preFilter;a;){n&&!(r=Qa.exec(a))||(r&&(a=a.slice(r[0].length)||a),u.push(o=[])),n=!1,(r=Za.exec(a))&&(n=r.shift(),o.push({value:n,type:r[0].replace(Ja," ")}),a=a.slice(n.length));for(i in z.filter)z.filter.hasOwnProperty(i)&&(!(r=ru[i].exec(a))||c[i]&&!(r=c[i](r))||(n=r.shift(),o.push({value:n,type:i,matches:r}),a=a.slice(n.length)));if(!n)break}return t?a.length:a?mu.error(e):Pa(e,u).slice(0)},q=mu.compile=function(e,t){var n,r=[],o=[],i=La[e+" "];if(!i){for(t||(t=V(e)),n=t.length;n--;)i=b(t[n]),i[Ra]?r.push(i):o.push(i);i=La(e,C(o,r)),i.selector=e}return i},$=mu.select=function(e,t,n,r){var o,i,a,u,c,s="function"==typeof e&&e,f=!r&&V(e=s.selector||e);if(n=n||[],1===f.length){if(i=f[0]=f[0].slice(0),i.length>2&&"ID"===(a=i[0]).type&&U.getById&&9===t.nodeType&&Q&&z.relative[i[1].type]){if(t=(z.find.ID(a.matches[0].replace(fu,lu),t)||[])[0],!t)return n;s&&(t=t.parentNode),e=e.slice(i.shift().value.length)}for(o=ru.needsContext.test(e)?0:i.length;o--&&(a=i[o],!z.relative[u=a.type]);)if((c=z.find[u])&&(r=c(a.matches[0].replace(fu,lu),cu.test(i[0].type)&&l(t.parentNode)||t))){if(i.splice(o,1),e=r.length&&m(i),!e)return Va.apply(n,r),n;break}}return(s||q(e,f))(r,t,!Q,n,cu.test(e)&&l(t.parentNode)||t),n},U.sortStable=Ra.split("").sort(Ia).join("")===Ra,U.detectDuplicates=!!X,Y(),U.sortDetached=!0;var pu=e.document,gu=Array.prototype.push,hu=Array.prototype.slice,vu=/^(?:[^#<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,yu=Ta.Event,bu=er.makeMap("children,contents,next,prev"),Cu=function(e){return"undefined"!=typeof e},wu=function(e){return"string"==typeof e},xu=function(e){return e&&e===e.window},Su=function(e,t){t=t||pu;var n=t.createElement("div"),r=t.createDocumentFragment();n.innerHTML=e;for(var o;o=n.firstChild;)r.appendChild(o);return r},Nu=function(e,t,n,r){var o;if(wu(t))t=Su(t,Uu(e[0]));else if(t.length&&!t.nodeType){if(t=Vu.makeArray(t),r)for(o=t.length-1;o>=0;o--)Nu(e,t[o],n,r);else for(o=0;o<t.length;o++)Nu(e,t[o],n,r);return e}if(t.nodeType)for(o=e.length;o--;)n.call(e[o],t);return e},Eu=function(e,t){return e&&t&&(" "+e.className+" ").indexOf(" "+t+" ")!==-1},ku=function(e,t,n){var r,o;return t=Vu(t)[0],e.each(function(){var e=this;n&&r===e.parentNode?o.appendChild(e):(r=e.parentNode,o=t.cloneNode(!1),e.parentNode.insertBefore(o,e),o.appendChild(e))}),e},_u=er.makeMap("fillOpacity fontWeight lineHeight opacity orphans widows zIndex zoom"," "),Tu=er.makeMap("checked compact declare defer disabled ismap multiple nohref noshade nowrap readonly selected"," "),Ru={"for":"htmlFor","class":"className",readonly:"readOnly"},Au={"float":"cssFloat"},Du={},Ou={},Bu=function(e,t){return new Vu.fn.init(e,t)},Pu=function(e,t){var n;if(t.indexOf)return t.indexOf(e);for(n=t.length;n--;)if(t[n]===e)return n;return-1},Lu=/^\s*|\s*$/g,Iu=function(e){return null===e||void 0===e?"":(""+e).replace(Lu,"")},Mu=function(e,t){var n,r,o,i;if(e)if(n=e.length,void 0===n){for(r in e)if(e.hasOwnProperty(r)&&(i=e[r],t.call(i,r,i)===!1))break}else for(o=0;o<n&&(i=e[o],t.call(i,o,i)!==!1);o++);return e},Fu=function(e,t){var n=[];return Mu(e,function(e,r){t(r,e)&&n.push(r)}),n},Uu=function(e){return e?9===e.nodeType?e:e.ownerDocument:pu};Bu.fn=Bu.prototype={constructor:Bu,selector:"",context:null,length:0,init:function(t,n){var r,o,i=this;if(!t)return i;if(t.nodeType)return i.context=i[0]=t,i.length=1,i;if(n&&n.nodeType)i.context=n;else{if(n)return Vu(t).attr(n);i.context=n=e.document}if(wu(t)){if(i.selector=t,r="<"===t.charAt(0)&&">"===t.charAt(t.length-1)&&t.length>=3?[null,t,null]:vu.exec(t),!r)return Vu(n).find(t);if(r[1])for(o=Su(t,Uu(n)).firstChild;o;)gu.call(i,o),o=o.nextSibling;else{if(o=Uu(n).getElementById(r[2]),!o)return i;if(o.id!==r[2])return i.find(t);i.length=1,i[0]=o}}else this.add(t,!1);return i},toArray:function(){return er.toArray(this)},add:function(e,t){var n,r,o=this;if(wu(e))return o.add(Vu(e));if(t!==!1)for(n=Vu.unique(o.toArray().concat(Vu.makeArray(e))),o.length=n.length,r=0;r<n.length;r++)o[r]=n[r];else gu.apply(o,Vu.makeArray(e));return o},attr:function(e,t){var n,r=this;if("object"==typeof e)Mu(e,function(e,t){r.attr(e,t)});else{if(!Cu(t)){if(r[0]&&1===r[0].nodeType){if(n=Du[e],n&&n.get)return n.get(r[0],e);if(Tu[e])return r.prop(e)?e:void 0;t=r[0].getAttribute(e,2),null===t&&(t=void 0)}return t}this.each(function(){var n;if(1===this.nodeType){if(n=Du[e],n&&n.set)return void n.set(this,t);null===t?this.removeAttribute(e,2):this.setAttribute(e,t,2)}})}return r},removeAttr:function(e){return this.attr(e,null)},prop:function(e,t){var n=this;if(e=Ru[e]||e,"object"==typeof e)Mu(e,function(e,t){n.prop(e,t)});else{if(!Cu(t))return n[0]&&n[0].nodeType&&e in n[0]?n[0][e]:t;this.each(function(){1===this.nodeType&&(this[e]=t)})}return n},css:function(e,t){var n,r,o=this,i=function(e){return e.replace(/-(\D)/g,function(e,t){return t.toUpperCase()})},a=function(e){return e.replace(/[A-Z]/g,function(e){return"-"+e})};if("object"==typeof e)Mu(e,function(e,t){o.css(e,t)});else if(Cu(t))e=i(e),"number"!=typeof t||_u[e]||(t=t.toString()+"px"),o.each(function(){var n=this.style;if(r=Ou[e],r&&r.set)return void r.set(this,t);try{this.style[Au[e]||e]=t}catch(o){}null!==t&&""!==t||(n.removeProperty?n.removeProperty(a(e)):n.removeAttribute(e))});else{if(n=o[0],r=Ou[e],r&&r.get)return r.get(n);if(!n.ownerDocument.defaultView)return n.currentStyle?n.currentStyle[i(e)]:"";try{return n.ownerDocument.defaultView.getComputedStyle(n,null).getPropertyValue(a(e))}catch(u){return}}return o},remove:function(){for(var e,t=this,n=this.length;n--;)e=t[n],yu.clean(e),e.parentNode&&e.parentNode.removeChild(e);return this},empty:function(){for(var e,t=this,n=this.length;n--;)for(e=t[n];e.firstChild;)e.removeChild(e.firstChild);return this},html:function(e){var t,n=this;if(Cu(e)){t=n.length;try{for(;t--;)n[t].innerHTML=e}catch(r){Vu(n[t]).empty().append(e)}return n}return n[0]?n[0].innerHTML:""},text:function(e){var t,n=this;if(Cu(e)){for(t=n.length;t--;)"innerText"in n[t]?n[t].innerText=e:n[0].textContent=e;return n}return n[0]?n[0].innerText||n[0].textContent:"";
},append:function(){return Nu(this,arguments,function(e){(1===this.nodeType||this.host&&1===this.host.nodeType)&&this.appendChild(e)})},prepend:function(){return Nu(this,arguments,function(e){(1===this.nodeType||this.host&&1===this.host.nodeType)&&this.insertBefore(e,this.firstChild)},!0)},before:function(){var e=this;return e[0]&&e[0].parentNode?Nu(e,arguments,function(e){this.parentNode.insertBefore(e,this)}):e},after:function(){var e=this;return e[0]&&e[0].parentNode?Nu(e,arguments,function(e){this.parentNode.insertBefore(e,this.nextSibling)},!0):e},appendTo:function(e){return Vu(e).append(this),this},prependTo:function(e){return Vu(e).prepend(this),this},replaceWith:function(e){return this.before(e).remove()},wrap:function(e){return ku(this,e)},wrapAll:function(e){return ku(this,e,!0)},wrapInner:function(e){return this.each(function(){Vu(this).contents().wrapAll(e)}),this},unwrap:function(){return this.parent().each(function(){Vu(this).replaceWith(this.childNodes)})},clone:function(){var e=[];return this.each(function(){e.push(this.cloneNode(!0))}),Vu(e)},addClass:function(e){return this.toggleClass(e,!0)},removeClass:function(e){return this.toggleClass(e,!1)},toggleClass:function(e,t){var n=this;return"string"!=typeof e?n:(e.indexOf(" ")!==-1?Mu(e.split(" "),function(){n.toggleClass(this,t)}):n.each(function(n,r){var o=Eu(r,e);if(o!==t){var i=r.className;o?r.className=Iu((" "+i+" ").replace(" "+e+" "," ")):r.className+=i?" "+e:e}}),n)},hasClass:function(e){return Eu(this[0],e)},each:function(e){return Mu(this,e)},on:function(e,t){return this.each(function(){yu.bind(this,e,t)})},off:function(e,t){return this.each(function(){yu.unbind(this,e,t)})},trigger:function(e){return this.each(function(){"object"==typeof e?yu.fire(this,e.type,e):yu.fire(this,e)})},show:function(){return this.css("display","")},hide:function(){return this.css("display","none")},slice:function(){return new Vu(hu.apply(this,arguments))},eq:function(e){return e===-1?this.slice(e):this.slice(e,+e+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},find:function(e){var t,n,r=[];for(t=0,n=this.length;t<n;t++)Vu.find(e,this[t],r);return Vu(r)},filter:function(e){return Vu("function"==typeof e?Fu(this.toArray(),function(t,n){return e(n,t)}):Vu.filter(e,this.toArray()))},closest:function(e){var t=[];return e instanceof Vu&&(e=e[0]),this.each(function(n,r){for(;r;){if("string"==typeof e&&Vu(r).is(e)){t.push(r);break}if(r===e){t.push(r);break}r=r.parentNode}}),Vu(t)},offset:function(e){var t,n,r,o,i=0,a=0;return e?this.css(e):(t=this[0],t&&(n=t.ownerDocument,r=n.documentElement,t.getBoundingClientRect&&(o=t.getBoundingClientRect(),i=o.left+(r.scrollLeft||n.body.scrollLeft)-r.clientLeft,a=o.top+(r.scrollTop||n.body.scrollTop)-r.clientTop)),{left:i,top:a})},push:gu,sort:Array.prototype.sort,splice:Array.prototype.splice},er.extend(Bu,{extend:er.extend,makeArray:function(e){return xu(e)||e.nodeType?[e]:er.toArray(e)},inArray:Pu,isArray:er.isArray,each:Mu,trim:Iu,grep:Fu,find:mu,expr:mu.selectors,unique:mu.uniqueSort,text:mu.getText,contains:mu.contains,filter:function(e,t,n){var r=t.length;for(n&&(e=":not("+e+")");r--;)1!==t[r].nodeType&&t.splice(r,1);return t=1===t.length?Vu.find.matchesSelector(t[0],e)?[t[0]]:[]:Vu.find.matches(e,t)}});var zu=function(e,t,n){var r=[],o=e[t];for("string"!=typeof n&&n instanceof Vu&&(n=n[0]);o&&9!==o.nodeType;){if(void 0!==n){if(o===n)break;if("string"==typeof n&&Vu(o).is(n))break}1===o.nodeType&&r.push(o),o=o[t]}return r},ju=function(e,t,n,r){var o=[];for(r instanceof Vu&&(r=r[0]);e;e=e[t])if(!n||e.nodeType===n){if(void 0!==r){if(e===r)break;if("string"==typeof r&&Vu(e).is(r))break}o.push(e)}return o},Hu=function(e,t,n){for(e=e[t];e;e=e[t])if(e.nodeType===n)return e;return null};Mu({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return zu(e,"parentNode")},next:function(e){return Hu(e,"nextSibling",1)},prev:function(e){return Hu(e,"previousSibling",1)},children:function(e){return ju(e.firstChild,"nextSibling",1)},contents:function(e){return er.toArray(("iframe"===e.nodeName?e.contentDocument||e.contentWindow.document:e).childNodes)}},function(e,t){Bu.fn[e]=function(n){var r=this,o=[];r.each(function(){var e=t.call(o,this,n,o);e&&(Vu.isArray(e)?o.push.apply(o,e):o.push(e))}),this.length>1&&(bu[e]||(o=Vu.unique(o)),0===e.indexOf("parents")&&(o=o.reverse()));var i=Vu(o);return n?i.filter(n):i}}),Mu({parentsUntil:function(e,t){return zu(e,"parentNode",t)},nextUntil:function(e,t){return ju(e,"nextSibling",1,t).slice(1)},prevUntil:function(e,t){return ju(e,"previousSibling",1,t).slice(1)}},function(e,t){Bu.fn[e]=function(n,r){var o=this,i=[];o.each(function(){var e=t.call(i,this,n,i);e&&(Vu.isArray(e)?i.push.apply(i,e):i.push(e))}),this.length>1&&(i=Vu.unique(i),0!==e.indexOf("parents")&&"prevUntil"!==e||(i=i.reverse()));var a=Vu(i);return r?a.filter(r):a}}),Bu.fn.is=function(e){return!!e&&this.filter(e).length>0},Bu.fn.init.prototype=Bu.fn,Bu.overrideDefaults=function(e){var t,n=function(r,o){return t=t||e(),0===arguments.length&&(r=t.element),o||(o=t.context),new n.fn.init(r,o)};return Vu.extend(n,this),n},Bu.attrHooks=Du,Bu.cssHooks=Ou;var Vu=Bu,qu=function(){function e(e,t){this.node=e,this.rootNode=t,this.current=this.current.bind(this),this.next=this.next.bind(this),this.prev=this.prev.bind(this),this.prev2=this.prev2.bind(this)}return e.prototype.current=function(){return this.node},e.prototype.next=function(e){return this.node=this.findSibling(this.node,"firstChild","nextSibling",e),this.node},e.prototype.prev=function(e){return this.node=this.findSibling(this.node,"lastChild","previousSibling",e),this.node},e.prototype.prev2=function(e){return this.node=this.findPreviousNode(this.node,"lastChild","previousSibling",e),this.node},e.prototype.findSibling=function(e,t,n,r){var o,i;if(e){if(!r&&e[t])return e[t];if(e!==this.rootNode){if(o=e[n])return o;for(i=e.parentNode;i&&i!==this.rootNode;i=i.parentNode)if(o=i[n])return o}}},e.prototype.findPreviousNode=function(e,t,n,r){var o,i,a;if(e){if(o=e[n],this.rootNode&&o===this.rootNode)return;if(o){if(!r)for(a=o[t];a;a=a[t])if(!a[t])return a;return o}if(i=e.parentNode,i&&i!==this.rootNode)return i}},e}(),$u={},Wu={exports:$u};!function(e,t,n,r){!function(r){if("object"==typeof t&&"undefined"!=typeof n)n.exports=r();else if("function"==typeof e&&e.amd)e([],r);else{var o;o="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,o.EphoxContactWrapper=r()}}(function(){return function(){function e(t,n,o){function i(u,c){if(!n[u]){if(!t[u]){var s="function"==typeof r&&r;if(!c&&s)return s(u,!0);if(a)return a(u,!0);var f=new Error("Cannot find module '"+u+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[u]={exports:{}};t[u][0].call(l.exports,function(e){var n=t[u][1][e];return i(n||e)},l,l.exports,e,t,n,o)}return n[u].exports}for(var a="function"==typeof r&&r,u=0;u<o.length;u++)i(o[u]);return i}return e}()({1:[function(e,t,n){function r(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function i(e){if(l===setTimeout)return setTimeout(e,0);if((l===r||!l)&&setTimeout)return l=setTimeout,setTimeout(e,0);try{return l(e,0)}catch(t){try{return l.call(null,e,0)}catch(t){return l.call(this,e,0)}}}function a(e){if(d===clearTimeout)return clearTimeout(e);if((d===o||!d)&&clearTimeout)return d=clearTimeout,clearTimeout(e);try{return d(e)}catch(t){try{return d.call(null,e)}catch(t){return d.call(this,e)}}}function u(){h&&p&&(h=!1,p.length?g=p.concat(g):v=-1,g.length&&c())}function c(){if(!h){var e=i(u);h=!0;for(var t=g.length;t;){for(p=g,g=[];++v<t;)p&&p[v].run();v=-1,t=g.length}p=null,h=!1,a(e)}}function s(e,t){this.fun=e,this.array=t}function f(){}var l,d,m=t.exports={};!function(){try{l="function"==typeof setTimeout?setTimeout:r}catch(e){l=r}try{d="function"==typeof clearTimeout?clearTimeout:o}catch(e){d=o}}();var p,g=[],h=!1,v=-1;m.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];g.push(new s(e,t)),1!==g.length||h||i(c)},s.prototype.run=function(){this.fun.apply(null,this.array)},m.title="browser",m.browser=!0,m.env={},m.argv=[],m.version="",m.versions={},m.on=f,m.addListener=f,m.once=f,m.off=f,m.removeListener=f,m.removeAllListeners=f,m.emit=f,m.prependListener=f,m.prependOnceListener=f,m.listeners=function(e){return[]},m.binding=function(e){throw new Error("process.binding is not supported")},m.cwd=function(){return"/"},m.chdir=function(e){throw new Error("process.chdir is not supported")},m.umask=function(){return 0}},{}],2:[function(e,t,n){(function(e){!function(n){function r(){}function o(e,t){return function(){e.apply(t,arguments)}}function i(e){if("object"!=typeof this)throw new TypeError("Promises must be constructed via new");if("function"!=typeof e)throw new TypeError("not a function");this._state=0,this._handled=!1,this._value=void 0,this._deferreds=[],l(e,this)}function a(e,t){for(;3===e._state;)e=e._value;return 0===e._state?void e._deferreds.push(t):(e._handled=!0,void i._immediateFn(function(){var n=1===e._state?t.onFulfilled:t.onRejected;if(null===n)return void(1===e._state?u:c)(t.promise,e._value);var r;try{r=n(e._value)}catch(o){return void c(t.promise,o)}u(t.promise,r)}))}function u(e,t){try{if(t===e)throw new TypeError("A promise cannot be resolved with itself.");if(t&&("object"==typeof t||"function"==typeof t)){var n=t.then;if(t instanceof i)return e._state=3,e._value=t,void s(e);if("function"==typeof n)return void l(o(n,t),e)}e._state=1,e._value=t,s(e)}catch(r){c(e,r)}}function c(e,t){e._state=2,e._value=t,s(e)}function s(e){2===e._state&&0===e._deferreds.length&&i._immediateFn(function(){e._handled||i._unhandledRejectionFn(e._value)});for(var t=0,n=e._deferreds.length;t<n;t++)a(e,e._deferreds[t]);e._deferreds=null}function f(e,t,n){this.onFulfilled="function"==typeof e?e:null,this.onRejected="function"==typeof t?t:null,this.promise=n}function l(e,t){var n=!1;try{e(function(e){n||(n=!0,u(t,e))},function(e){n||(n=!0,c(t,e))})}catch(r){if(n)return;n=!0,c(t,r)}}var d=setTimeout;i.prototype["catch"]=function(e){return this.then(null,e)},i.prototype.then=function(e,t){var n=new this.constructor(r);return a(this,new f(e,t,n)),n},i.all=function(e){var t=Array.prototype.slice.call(e);return new i(function(e,n){function r(i,a){try{if(a&&("object"==typeof a||"function"==typeof a)){var u=a.then;if("function"==typeof u)return void u.call(a,function(e){r(i,e)},n)}t[i]=a,0===--o&&e(t)}catch(c){n(c)}}if(0===t.length)return e([]);for(var o=t.length,i=0;i<t.length;i++)r(i,t[i])})},i.resolve=function(e){return e&&"object"==typeof e&&e.constructor===i?e:new i(function(t){t(e)})},i.reject=function(e){return new i(function(t,n){n(e)})},i.race=function(e){return new i(function(t,n){for(var r=0,o=e.length;r<o;r++)e[r].then(t,n)})},i._immediateFn="function"==typeof e?function(t){e(t)}:function(e){d(e,0)},i._unhandledRejectionFn=function(e){"undefined"!=typeof console&&console&&console.warn("Possible Unhandled Promise Rejection:",e)},i._setImmediateFn=function(e){i._immediateFn=e},i._setUnhandledRejectionFn=function(e){i._unhandledRejectionFn=e},"undefined"!=typeof t&&t.exports?t.exports=i:n.Promise||(n.Promise=i)}(this)}).call(this,e("timers").setImmediate)},{timers:3}],3:[function(e,t,n){(function(t,r){function o(e,t){this._id=e,this._clearFn=t}var i=e("process/browser.js").nextTick,a=Function.prototype.apply,u=Array.prototype.slice,c={},s=0;n.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},n.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},n.clearTimeout=n.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},n.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},n.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},n._unrefActive=n.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},n.setImmediate="function"==typeof t?t:function(e){var t=s++,r=!(arguments.length<2)&&u.call(arguments,1);return c[t]=!0,i(function(){c[t]&&(r?e.apply(null,r):e.call(null),n.clearImmediate(t))}),t},n.clearImmediate="function"==typeof r?r:function(e){delete c[e]}}).call(this,e("timers").setImmediate,e("timers").clearImmediate)},{"process/browser.js":1,timers:3}],4:[function(e,t,n){var r=e("promise-polyfill"),o=function(){return"undefined"!=typeof window?window:Function("return this;")()}();t.exports={boltExport:o.Promise||r}},{"promise-polyfill":2}]},{},[4])(4)})}(void 0,$u,Wu,void 0);var Ku,Xu=Wu.exports.boltExport,Yu=function(t){var n=_e.none(),r=[],o=function(e){return Yu(function(t){i(function(n){t(e(n))})})},i=function(e){u()?s(e):r.push(e)},a=function(e){u()||(n=_e.some(e),c(r),r=[])},u=function(){return n.isSome()},c=function(e){Xe(e,s)},s=function(t){n.each(function(n){e.setTimeout(function(){t(n)},0)})};return t(a),{get:i,map:o,isReady:u}},Gu=function(e){return Yu(function(t){t(e)})},Ju={nu:Yu,pure:Gu},Qu=function(t){e.setTimeout(function(){throw t},0)},Zu=function(e){var t=function(t){e().then(t,Qu)},n=function(t){return Zu(function(){return e().then(t)})},r=function(t){return Zu(function(){return e().then(function(e){return t(e).toPromise()})})},o=function(t){return Zu(function(){return e().then(function(){return t.toPromise()})})},i=function(){return Ju.nu(t)},a=function(){var t=null;return Zu(function(){return null===t&&(t=e()),t})},u=e;return{map:n,bind:r,anonBind:o,toLazy:i,toCached:a,toPromise:u,get:t}},ec=function(e){return Zu(function(){return new Xu(e)})},tc=function(e){return Zu(function(){return Xu.resolve(e)})},nc={nu:ec,pure:tc},rc=function(e,t){return t(function(t){var n=[],r=0,o=function(o){return function(i){n[o]=i,r++,r>=e.length&&t(n)}};0===e.length?t([]):Xe(e,function(e,t){e.get(o(t))})})},oc=function(e){return rc(e,nc.nu)},ic=function(e){var t=function(t){return e===t},n=function(t){return ic(e)},r=function(t){return ic(e)},o=function(t){return ic(t(e))},i=function(t){return ic(e)},a=function(t){t(e)},u=function(t){return t(e)},c=function(t,n){return n(e)},s=function(t){return t(e)},f=function(t){return t(e)},l=function(){return _e.some(e)};return{is:t,isValue:xe,isError:we,getOr:ve(e),getOrThunk:ve(e),getOrDie:ve(e),or:n,orThunk:r,fold:c,map:o,mapError:i,each:a,bind:u,exists:s,forall:f,toOption:l}},ac=function(e){var t=function(e){return e()},n=function(){return Ce(String(e))()},r=function(e){return e},o=function(e){return e()},i=function(t){return ac(e)},a=function(t){return ac(t(e))},u=function(t){return ac(e)},c=function(t,n){return t(e)};return{is:we,isValue:we,isError:xe,getOr:ye,getOrThunk:t,getOrDie:n,or:r,orThunk:o,fold:c,map:i,mapError:a,each:pe,bind:u,exists:we,forall:xe,toOption:_e.none}},uc=function(e,t){return e.fold(function(){return ac(t)},ic)},cc={value:ic,error:ac,fromOption:uc},sc=function(t){if(!Pe(t))throw new Error("cases must be an array");if(0===t.length)throw new Error("there must be at least one case");var n=[],r={};return Xe(t,function(o,i){var a=mt(o);if(1!==a.length)throw new Error("one and only one name per case");var u=a[0],c=o[u];if(void 0!==r[u])throw new Error("duplicate key detected:"+u);if("cata"===u)throw new Error("cannot have a case named cata (sorry)");if(!Pe(c))throw new Error("case arguments must be an array");n.push(u),r[u]=function(){var r=arguments.length;if(r!==c.length)throw new Error("Wrong number of arguments to case "+u+". Expected "+c.length+" ("+c+"), got "+r);for(var o=new Array(r),a=0;a<o.length;a++)o[a]=arguments[a];var s=function(e){var t=mt(e);if(n.length!==t.length)throw new Error("Wrong number of arguments to match. Expected: "+n.join(",")+"\nActual: "+t.join(","));var r=it(n,function(e){return $e(t,e)});if(!r)throw new Error("Not all branches were specified when using match. Specified: "+t.join(", ")+"\nRequired: "+n.join(", "));return e[u].apply(null,o)};return{fold:function(){if(arguments.length!==t.length)throw new Error("Wrong number of arguments to fold. Expected "+t.length+", got "+arguments.length);var e=arguments[i];return e.apply(null,o)},match:s,log:function(t){e.console.log(t,{constructors:n,constructor:u,params:o})}}}}),r},fc={generate:sc},lc=(fc.generate([{bothErrors:["error1","error2"]},{firstError:["error1","value2"]},{secondError:["value1","error2"]},{bothValues:["value1","value2"]}]),function(e){return e.fold(ye,ye)}),dc=function(){function t(e,t){return function(){e.apply(t,arguments)}}function n(e){var t=this;return null===this._state?void this._deferreds.push(e):void f(function(){var n=t._state?e.onFulfilled:e.onRejected;if(null===n)return void(t._state?e.resolve:e.reject)(t._value);var r;try{r=n(t._value)}catch(o){return void e.reject(o)}e.resolve(r)})}function r(e){try{if(e===this)throw new TypeError("A promise cannot be resolved with itself.");if(e&&("object"==typeof e||"function"==typeof e)){var n=e.then;if("function"==typeof n)return void u(t(n,e),t(r,this),t(o,this))}this._state=!0,this._value=e,i.call(this)}catch(a){o.call(this,a)}}function o(e){this._state=!1,this._value=e,i.call(this)}function i(){for(var e=0,t=this._deferreds.length;e<t;e++)n.call(this,this._deferreds[e]);this._deferreds=null}function a(e,t,n,r){this.onFulfilled="function"==typeof e?e:null,this.onRejected="function"==typeof t?t:null,this.resolve=n,this.reject=r}function u(e,t,n){var r=!1;try{e(function(e){r||(r=!0,t(e))},function(e){r||(r=!0,n(e))})}catch(o){if(r)return;r=!0,n(o)}}var c=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},s=function(e){if("object"!=typeof this)throw new TypeError("Promises must be constructed via new");if("function"!=typeof e)throw new TypeError("not a function");this._state=null,this._value=null,this._deferreds=[],u(e,t(r,this),t(o,this))},f=s.immediateFn||"function"==typeof e.setImmediate&&e.setImmediate||function(t){e.setTimeout(t,1)};return s.prototype["catch"]=function(e){return this.then(null,e)},s.prototype.then=function(e,t){var r=this;return new s(function(o,i){n.call(r,new a(e,t,o,i))})},s.all=function(){var e=Array.prototype.slice.call(1===arguments.length&&c(arguments[0])?arguments[0]:arguments);return new s(function(t,n){function r(i,a){try{if(a&&("object"==typeof a||"function"==typeof a)){var u=a.then;if("function"==typeof u)return void u.call(a,function(e){r(i,e)},n)}e[i]=a,0===--o&&t(e)}catch(c){n(c)}}if(0===e.length)return t([]);for(var o=e.length,i=0;i<e.length;i++)r(i,e[i])})},s.resolve=function(e){return e&&"object"==typeof e&&e.constructor===s?e:new s(function(t){t(e)})},s.reject=function(e){return new s(function(t,n){n(e)})},s.race=function(e){return new s(function(t,n){for(var r=0,o=e.length;r<o;r++)e[r].then(t,n)})},s},mc=window.Promise?window.Promise:dc(),pc=function(t,n){var r,o=e.window.requestAnimationFrame,i=["ms","moz","webkit"],a=function(t){e.window.setTimeout(t,0)};for(r=0;r<i.length&&!o;r++)o=e.window[i[r]+"RequestAnimationFrame"];o||(o=a),o(t,n)},gc=function(t,n){return"number"!=typeof n&&(n=0),e.setTimeout(t,n)},hc=function(t,n){return"number"!=typeof n&&(n=1),e.setInterval(t,n)},vc=function(t){return e.clearTimeout(t)},yc=function(t){return e.clearInterval(t)},bc=function(t,n){var r,o=function(){for(var o=[],i=0;i<arguments.length;i++)o[i]=arguments[i];e.clearTimeout(r),r=gc(function(){t.apply(this,o)},n)};return o.stop=function(){e.clearTimeout(r)},o},Cc={requestAnimationFrame:function(t,n){return Ku?void Ku.then(t):void(Ku=new mc(function(t){n||(n=e.document.body),pc(t,n)}).then(t))},setTimeout:gc,setInterval:hc,setEditorTimeout:function(e,t,n){return gc(function(){e.removed||t()},n)},setEditorInterval:function(t,n,r){var o=hc(function(){t.removed?e.clearInterval(o):n()},r);return o},debounce:bc,throttle:bc,clearInterval:yc,clearTimeout:vc},wc=function(){var e=new WeakMap,t=function(t,n){var r=Gr(t),o=r.dom();return _e.from(e.get(o)).getOrThunk(function(){var t=w(o,n);return e.set(o,t),t})};return{forElement:t}},xc=wc(),Sc=er.each,Nc=er.grep,Ec=jn.ie,kc=/^([a-z0-9],?)+$/i,_c=function(e,t,n){var r=t.keep_values,o={set:function(e,r,o){t.url_converter&&(r=t.url_converter.call(t.url_converter_scope||n(),r,o,e[0])),e.attr("data-mce-"+o,r).attr(o,r)},get:function(e,t){return e.attr("data-mce-"+t)||e.attr(t)}},i={style:{set:function(t,n){return null!==n&&"object"==typeof n?void t.css(n):(r&&t.attr("data-mce-style",n),void(null!==n&&"string"==typeof n?(t.removeAttr("style"),t.css(e.parse(n))):t.attr("style",n)))},get:function(t){var n=t.attr("data-mce-style")||t.attr("style");return n=e.serialize(e.parse(n),t[0].nodeName)}}};return r&&(i.href=i.src=o),i},Tc=function(e,t){var n=t.attr("style"),r=e.serialize(e.parse(n),t[0].nodeName);r||(r=null),t.attr("data-mce-style",r)},Rc=function(e,t){var n,r,o=0;if(e)for(n=e.nodeType,e=e.previousSibling;e;e=e.previousSibling)r=e.nodeType,(!t||3!==r||r!==n&&e.nodeValue.length)&&(o++,n=r);return o};!function(t){t.DOM=t(e.document),t.nodeIndex=Rc}(x||(x={}));var Ac=x,Dc=Ac.DOM,Oc=er.each,Bc=er.grep,Pc=0,Lc=1,Ic=2,Mc=3,Fc=function(){function t(e){void 0===e&&(e={}),this.states={},this.queue=[],this.scriptLoadedCallbacks={},this.queueLoadedCallbacks=[],this.loading=0,this.settings=e}return t.prototype._setReferrerPolicy=function(e){this.settings.referrerPolicy=e},t.prototype.loadScript=function(t,n,r){var o,i=Dc,a=function(){i.remove(c),o&&(o.onreadystatechange=o.onload=o=null),n()},u=function(){Fe(r)?r():"undefined"!=typeof e.console&&e.console.log&&e.console.log("Failed to load script: "+t)},c=i.uniqueId();o=e.document.createElement("script"),o.id=c,o.type="text/javascript",o.src=er._addCacheSuffix(t),this.settings.referrerPolicy&&i.setAttrib(o,"referrerpolicy",this.settings.referrerPolicy),o.onload=a,o.onerror=u,(e.document.getElementsByTagName("head")[0]||e.document.body).appendChild(o)},t.prototype.isDone=function(e){return this.states[e]===Ic},t.prototype.markDone=function(e){this.states[e]=Ic},t.prototype.add=function(e,t,n,r){var o=this.states[e];void 0===o&&(this.queue.push(e),this.states[e]=Pc),t&&(this.scriptLoadedCallbacks[e]||(this.scriptLoadedCallbacks[e]=[]),this.scriptLoadedCallbacks[e].push({success:t,failure:r,scope:n||this}))},t.prototype.load=function(e,t,n,r){return this.add(e,t,n,r)},t.prototype.remove=function(e){delete this.states[e],delete this.scriptLoadedCallbacks[e]},t.prototype.loadQueue=function(e,t,n){this.loadScripts(this.queue,e,t,n)},t.prototype.loadScripts=function(e,t,n,r){var o=this,i=[],a=function(e,t){Oc(o.scriptLoadedCallbacks[t],function(t){Fe(t[e])&&t[e].call(t.scope)}),o.scriptLoadedCallbacks[t]=void 0};o.queueLoadedCallbacks.push({success:t,failure:r,scope:n||this});var u=function(){var t=Bc(e);if(e.length=0,Oc(t,function(e){return o.states[e]===Ic?void a("success",e):o.states[e]===Mc?void a("failure",e):void(o.states[e]!==Lc&&(o.states[e]=Lc,o.loading++,o.loadScript(e,function(){o.states[e]=Ic,o.loading--,a("success",e),u()},function(){o.states[e]=Mc,o.loading--,i.push(e),a("failure",e),u()})))}),!o.loading){var n=o.queueLoadedCallbacks.slice(0);o.queueLoadedCallbacks.length=0,Oc(n,function(e){0===i.length?Fe(e.success)&&e.success.call(e.scope):Fe(e.failure)&&e.failure.call(e.scope,i)})}};u()},t.ScriptLoader=new t,t}(),Uc=function(e){var t=e,n=function(){return t},r=function(e){t=e};return{get:n,set:r}},zc=function(e){return Be(e)&&Et(e,"raw")},jc=function(e){return Pe(e)&&e.length>1},Hc={},Vc=Uc("en"),qc=function(){return Nt(Hc,Vc.get())},$c=function(){return ht(Hc,function(e){return It({},e)})},Wc=function(e){e&&Vc.set(e)},Kc=function(){return Vc.get()},Xc=function(e,t){var n=Hc[e];n||(Hc[e]=n={}),gt(t,function(e,t){n[t.toLowerCase()]=e})},Yc=function(e){var t=qc().getOr({}),n=function(e){return Fe(e)?Object.prototype.toString.call(e):r(e)?"":""+e},r=function(e){return""===e||null===e||void 0===e},o=function(e){var r=n(e);return Nt(t,r.toLowerCase()).map(n).getOr(r)},i=function(e){return e.replace(/{context:\w+}$/,"")},a=function(e){return e};if(r(e))return a("");if(zc(e))return a(n(e.raw));if(jc(e)){var u=e.slice(1),c=o(e[0]).replace(/\{([0-9]+)\}/g,function(e,t){return Et(u,t)?n(u[t]):e});return a(i(c))}return a(i(o(e)))},Gc=function(){return qc().bind(function(e){return Nt(e,"_dir")}).exists(function(e){return"rtl"===e})},Jc=function(e){return Et(Hc,e)},Qc={getData:$c,setCode:Wc,getCode:Kc,add:Xc,translate:Yc,isRtl:Gc,hasCode:Jc};!function(e){e.PluginManager=e(),e.ThemeManager=e()}(S||(S={}));var Zc=S,es=function(t,n){var r=null,o=function(){null!==r&&(e.clearTimeout(r),r=null)},i=function(){for(var o=[],i=0;i<arguments.length;i++)o[i]=arguments[i];null===r&&(r=e.setTimeout(function(){t.apply(null,o),r=null},n))};return{cancel:o,throttle:i}},ts=function(t,n){var r=null,o=function(){null!==r&&(e.clearTimeout(r),r=null)},i=function(){for(var o=[],i=0;i<arguments.length;i++)o[i]=arguments[i];null!==r&&e.clearTimeout(r),r=e.setTimeout(function(){t.apply(null,o),r=null},n)};return{cancel:o,throttle:i}},ns=function(e,t){var n=Ko(e,t);return void 0===n||""===n?[]:n.split(" ")},rs=function(e,t,n){var r=ns(e,t),o=r.concat([n]);return $o(e,t,o.join(" ")),!0},os=function(e,t,n){var r=Je(ns(e,t),function(e){return e!==n});return r.length>0?$o(e,t,r.join(" ")):Go(e,t),!1},is=function(e){return void 0!==e.dom().classList},as=function(e){return ns(e,"class")},us=function(e,t){return rs(e,"class",t)},cs=function(e,t){return os(e,"class",t)},ss=function(e,t){is(e)?e.dom().classList.add(t):us(e,t)},fs=function(e){var t=is(e)?e.dom().classList:as(e);0===t.length&&Go(e,"class")},ls=function(e,t){if(is(e)){var n=e.dom().classList;n.remove(t)}else cs(e,t);fs(e)},ds=function(e,t){return is(e)&&e.dom().classList.contains(t)},ms=function(e,t){var n=[];return Xe(Vr(e),function(e){t(e)&&(n=n.concat([e])),n=n.concat(ms(e,t))}),n},ps=function(e,t){return kr(t,e)},gs=function(e,t,n){for(var r=e.dom(),o=Fe(n)?n:ve(!1);r.parentNode;){r=r.parentNode;var i=ar.fromDom(r);if(t(i))return _e.some(i);if(o(i))break}return _e.none()},hs=function(e,t,n){var r=function(e,t){return t(e)};return N(r,gs,e,t,n)},vs=function(e,t,n){return gs(e,function(e){return Nr(e,t)},n)},ys=function(e,t){return _r(t,e)},bs=function(e,t,n){var r=function(e,t){return Nr(e,t)};return N(r,vs,e,t,n)},Cs=ve("mce-annotation"),ws=ve("data-mce-annotation"),xs=ve("data-mce-annotation-uid"),Ss=function(e,t){var n=e.selection.getRng(),r=ar.fromDom(n.startContainer),o=ar.fromDom(e.getBody()),i=t.fold(function(){return"."+Cs()},function(e){return"["+ws()+'="'+e+'"]'}),a=qr(r,n.startOffset).getOr(r),u=bs(a,i,function(e){return Tr(e,o)}),c=function(e,t){return Yo(e,t)?_e.some(Ko(e,t)):_e.none()};return u.bind(function(t){return c(t,""+xs()).bind(function(n){return c(t,""+ws()).map(function(t){var r=Es(e,n);return{uid:n,name:t,elements:r}})})})},Ns=function(e){return hr(e)&&ds(e,Cs())},Es=function(e,t){var n=ar.fromDom(e.getBody());return ps(n,"["+xs()+'="'+t+'"]')},ks=function(e,t){var n=ar.fromDom(e.getBody()),r=ps(n,"["+ws()+'="'+t+'"]'),o={};return Xe(r,function(e){var t=Ko(e,xs()),n=o.hasOwnProperty(t)?o[t]:[];o[t]=n.concat([e])}),o},_s=function(e,t){var n=Uc({}),r=function(){return{listeners:[],previous:Uc(_e.none())}},o=function(e,t){i(e,function(e){return t(e),e})},i=function(e,t){var o=n.get(),i=o.hasOwnProperty(e)?o[e]:r(),a=t(i);o[e]=a,n.set(o)},a=function(e,t,n){o(e,function(r){Xe(r.listeners,function(r){return r(!0,e,{uid:t,nodes:Ke(n,function(e){return e.dom()})})})})},u=function(e){o(e,function(t){Xe(t.listeners,function(t){return t(!1,e)})})},c=ts(function(){var t=n.get(),r=st(mt(t));Xe(r,function(t){i(t,function(n){var r=n.previous.get();return Ss(e,_e.some(t)).fold(function(){r.isSome()&&(u(t),n.previous.set(_e.none()))},function(e){var t=e.uid,o=e.name,i=e.elements;r.is(t)||(a(o,t,i),n.previous.set(_e.some(t)))}),{previous:n.previous,listeners:n.listeners}})})},30);e.on("remove",function(){c.cancel()}),e.on("NodeChange",function(){c.throttle()});var s=function(e,t){i(e,function(e){return{previous:e.previous,listeners:e.listeners.concat([t])}})};return{addListener:s}},Ts=function(e,t){var n=function(e){return _e.from(e.attr(ws())).bind(t.lookup)};e.on("init",function(){e.serializer.addNodeFilter("span",function(e){Xe(e,function(e){n(e).each(function(t){t.persistent===!1&&e.unwrap()})})})})},Rs=function(){var e={},t=function(t,n){e[t]={name:t,settings:n}},n=function(t){return e.hasOwnProperty(t)?_e.from(e[t]).map(function(e){return e.settings}):_e.none()};return{register:t,lookup:n}},As=0,Ds=function(e){var t=new Date,n=t.getTime(),r=Math.floor(1e9*Math.random());return As++,e+"_"+r+As+String(n)},Os=function(e,t){Xe(t,function(t){ss(e,t)})},Bs=function(t,n){var r=n||e.document,o=r.createElement("div");return o.innerHTML=t,Vr(ar.fromDom(o))},Ps=function(e){return e.dom().innerHTML},Ls=function(e,t){var n=Or(e),r=n.dom(),o=ar.fromDom(r.createDocumentFragment()),i=Bs(t,r);ao(o,i),uo(e),ro(e,o)},Is=function(e,t){return ar.fromDom(e.dom().cloneNode(t))},Ms=function(e){return Is(e,!1)},Fs=function(e){return Is(e,!0)},Us=function(e,t,n){void 0===n&&(n=we);var r=new qu(e,t),o=function(e){var t;do t=r[e]();while(t&&!Io(t)&&!n(t));return _e.from(t).filter(Io)};return{current:function(){return _e.from(r.current()).filter(Io)},next:function(){return o("next")},prev:function(){return o("prev")},prev2:function(){return o("prev2")}}},zs=function(e,t){var n=t?t:function(t){return e.isBlock(t)||zo(t)||Ho(t)},r=function(e,t,n,o){if(Io(e)){var i=o(e,t,e.data);if(i!==-1)return _e.some({container:e,offset:i})}return n().bind(function(e){return r(e.container,e.offset,n,o)})},o=function(e,t,o,i){var a=Us(e,i,n);return r(e,t,function(){return a.prev().map(function(e){return{container:e,offset:e.length}})},o).getOrNull()},i=function(e,t,o,i){var a=Us(e,i,n);return r(e,t,function(){return a.next().map(function(e){return{container:e,offset:0}})},o).getOrNull()};return{backwards:o,forwards:i}},js=la,Hs=ma,Vs=pa,qs=ko,$s=Io,Ws=function(e){return $s(e)&&(e=e.parentNode),qs(e)&&e.hasAttribute("data-mce-caret")},Ks=function(e){return $s(e)&&Hs(e.data)},Xs=function(e){return Ws(e)||Ks(e)},Ys=function(e){return e.firstChild!==e.lastChild||!zo(e.firstChild)},Gs=function(e,t){var n,r=e.ownerDocument,o=r.createTextNode(js),i=e.parentNode;if(t){if(n=e.previousSibling,$s(n)){if(Xs(n))return n;if(nf(n))return n.splitText(n.data.length-1)}i.insertBefore(o,e)}else{if(n=e.nextSibling,$s(n)){if(Xs(n))return n;if(tf(n))return n.splitText(1),n}e.nextSibling?i.insertBefore(o,e.nextSibling):i.appendChild(o)}return o},Js=function(e){var t=e.container();return!(!e||!Io(t))&&(t.data.charAt(e.offset())===js||e.isAtStart()&&Ks(t.previousSibling))},Qs=function(e){var t=e.container();return!(!e||!Io(t))&&(t.data.charAt(e.offset()-1)===js||e.isAtEnd()&&Ks(t.nextSibling))},Zs=function(){var t=e.document.createElement("br");return t.setAttribute("data-mce-bogus","1"),t},ef=function(e,t,n){var r=t.ownerDocument,o=r.createElement(e);o.setAttribute("data-mce-caret",n?"before":"after"),o.setAttribute("data-mce-bogus","all"),o.appendChild(Zs());var i=t.parentNode;return n?i.insertBefore(o,t):t.nextSibling?i.insertBefore(o,t.nextSibling):i.appendChild(o),o},tf=function(e){return $s(e)&&e.data[0]===js},nf=function(e){return $s(e)&&e.data[e.data.length-1]===js},rf=function(e){var t=e.getElementsByTagName("br"),n=t[t.length-1];Do(n)&&n.parentNode.removeChild(n)},of=function(e){return e&&e.hasAttribute("data-mce-caret")?(rf(e),e.removeAttribute("data-mce-caret"),e.removeAttribute("data-mce-bogus"),e.removeAttribute("style"),e.removeAttribute("_moz_abspos"),e):null},af=function(e){return Ws(e.startContainer)},uf=function(e){for(var t=[],n=function(e){t.push(e)},r=0;r<e.length;r++)e[r].each(n);return t},cf=function(e,t,n){return e.isSome()&&t.isSome()?_e.some(n(e.getOrDie(),t.getOrDie())):_e.none()},sf=function(e,t,n,r){return e.isSome()&&t.isSome()&&n.isSome()?_e.some(r(e.getOrDie(),t.getOrDie(),n.getOrDie())):_e.none();
},ff=function(e,t){return e?_e.some(t):_e.none()},lf=Math.round,df=function(e){return e?{left:lf(e.left),top:lf(e.top),bottom:lf(e.bottom),right:lf(e.right),width:lf(e.width),height:lf(e.height)}:{left:0,top:0,bottom:0,right:0,width:0,height:0}},mf=function(e,t){return e=df(e),t?e.right=e.left:(e.left=e.left+e.width,e.right=e.left),e.width=0,e},pf=function(e,t){return e.left===t.left&&e.top===t.top&&e.bottom===t.bottom&&e.right===t.right},gf=function(e,t,n){return e>=0&&e<=Math.min(t.height,n.height)/2},hf=function(e,t){return e.bottom-e.height/2<t.top||!(e.top>t.bottom)&&gf(t.top-e.bottom,e,t)},vf=function(e,t){return e.top>t.bottom||!(e.bottom<t.top)&&gf(t.bottom-e.top,e,t)},yf=function(e,t,n){return t>=e.left&&t<=e.right&&n>=e.top&&n<=e.bottom},bf=function(e){var t=e.startContainer,n=e.startOffset;return t.hasChildNodes()&&e.endOffset===n+1?t.childNodes[n]:null},Cf=function(e,t){return 1===e.nodeType&&e.hasChildNodes()&&(t>=e.childNodes.length&&(t=e.childNodes.length-1),e=e.childNodes[t]),e},wf=new RegExp("[̀-ͯ҃-҇҈-҉֑-ֽֿׁ-ׂׄ-ׇׅؐ-ًؚ-ٰٟۖ-ۜ۟-ۤۧ-۪ۨ-ܑۭܰ-݊ަ-ް߫-߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛ࣣ-ंऺ़ु-ै्॑-ॗॢ-ॣঁ়াু-ৄ্ৗৢ-ৣਁ-ਂ਼ੁ-ੂੇ-ੈੋ-੍ੑੰ-ੱੵઁ-ં઼ુ-ૅે-ૈ્ૢ-ૣଁ଼ାିୁ-ୄ୍ୖୗୢ-ୣஂாீ்ௗఀా-ీె-ైొ-్ౕ-ౖౢ-ౣಁ಼ಿೂೆೌ-್ೕ-ೖೢ-ೣഁാു-ൄ്ൗൢ-ൣ්ාි-ුූෟัิ-ฺ็-๎ັິ-ູົ-ຼ່-ໍ༘-ཱ༹༙༵༷-ཾྀ-྄྆-྇ྍ-ྗྙ-ྼ࿆ိ-ူဲ-့္-်ွ-ှၘ-ၙၞ-ၠၱ-ၴႂႅ-ႆႍႝ፝-፟ᜒ-᜔ᜲ-᜴ᝒ-ᝓᝲ-ᝳ឴-឵ិ-ួំ៉-៓៝᠋-᠍ᢩᤠ-ᤢᤧ-ᤨᤲ᤹-᤻ᨗ-ᨘᨛᩖᩘ-ᩞ᩠ᩢᩥ-ᩬᩳ-᩿᩼᪰-᪽᪾ᬀ-ᬃ᬴ᬶ-ᬺᬼᭂ᭫-᭳ᮀ-ᮁᮢ-ᮥᮨ-ᮩ᮫-ᮭ᯦ᯨ-ᯩᯭᯯ-ᯱᰬ-ᰳᰶ-᰷᳐-᳔᳒-᳢᳠-᳨᳭᳴᳸-᳹᷀-᷵᷼-᷿‌-‍⃐-⃜⃝-⃠⃡⃢-⃤⃥-⃰⳯-⵿⳱ⷠ-〪ⷿ-〭〮-゙〯-゚꙯꙰-꙲ꙴ-꙽ꚞ-ꚟ꛰-꛱ꠂ꠆ꠋꠥ-ꠦ꣄꣠-꣱ꤦ-꤭ꥇ-ꥑꦀ-ꦂ꦳ꦶ-ꦹꦼꧥꨩ-ꨮꨱ-ꨲꨵ-ꨶꩃꩌꩼꪰꪲ-ꪴꪷ-ꪸꪾ-꪿꫁ꫬ-ꫭ꫶ꯥꯨ꯭ﬞ︀-️︠-︯ﾞ-ﾟ]"),xf=function(e){return"string"==typeof e&&e.charCodeAt(0)>=768&&wf.test(e)},Sf=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return function(t){for(var n=0;n<e.length;n++)if(e[n](t))return!0;return!1}},Nf=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return function(t){for(var n=0;n<e.length;n++)if(!e[n](t))return!1;return!0}},Ef=jo,kf=Ho,_f=zo,Tf=Io,Rf=_o(["script","style","textarea"]),Af=_o(["img","input","textarea","hr","iframe","video","audio","object"]),Df=_o(["table"]),Of=Xs,Bf=function(e){return!Of(e)&&(Tf(e)?!Rf(e.parentNode):Af(e)||_f(e)||Df(e)||Lf(e))},Pf=function(e){return ko(e)&&"true"===e.getAttribute("unselectable")},Lf=function(e){return Pf(e)===!1&&kf(e)},If=function(e,t){for(e=e.parentNode;e&&e!==t;e=e.parentNode){if(Lf(e))return!1;if(Ef(e))return!0}return!0},Mf=function(e){return!!Lf(e)&&Ze(dt(e.getElementsByTagName("*")),function(e,t){return e||Ef(t)},!1)!==!0},Ff=function(e){return Af(e)||Mf(e)},Uf=function(e,t){return Bf(e)&&If(e,t)},zf=ko,jf=Bf,Hf=To("display","block table"),Vf=To("float","left right"),qf=Nf(zf,jf,be(Vf)),$f=be(To("white-space","pre pre-line pre-wrap")),Wf=Io,Kf=zo,Xf=Ac.nodeIndex,Yf=Cf,Gf=function(e){return"createRange"in e?e.createRange():Ac.DOM.createRng()},Jf=function(e){return e&&/[\r\n\t ]/.test(e)},Qf=function(e){return!!e.setStart&&!!e.setEnd},Zf=function(e){var t,n=e.startContainer,r=e.startOffset;return!!(Jf(e.toString())&&$f(n.parentNode)&&Io(n)&&(t=n.data,Jf(t[r-1])||Jf(t[r+1])))},el=function(e){var t=e.ownerDocument,n=Gf(t),r=t.createTextNode(da),o=e.parentNode;o.insertBefore(r,e),n.setStart(r,0),n.setEnd(r,1);var i=df(n.getBoundingClientRect());return o.removeChild(r),i},tl=function(e){var t=e.startContainer,n=e.endContainer,r=e.startOffset,o=e.endOffset;if(t===n&&Io(n)&&0===r&&1===o){var i=e.cloneRange();return i.setEndAfter(n),rl(i)}return null},nl=function(e){return 0===e.left&&0===e.right&&0===e.top&&0===e.bottom},rl=function(e){var t,n=e.getClientRects();return t=df(n.length>0?n[0]:e.getBoundingClientRect()),!Qf(e)&&Kf(e)&&nl(t)?el(e):nl(t)&&Qf(e)?tl(e):t},ol=function(e,t){var n=mf(e,t);return n.width=1,n.right=n.left+1,n},il=function(e){var t,n,r=[],o=function(e){0!==e.height&&(r.length>0&&pf(e,r[r.length-1])||r.push(e))},i=function(e,t){var n=Gf(e.ownerDocument);if(t<e.data.length){if(xf(e.data[t]))return r;if(xf(e.data[t-1])&&(n.setStart(e,t),n.setEnd(e,t+1),!Zf(n)))return o(ol(rl(n),!1)),r}t>0&&(n.setStart(e,t-1),n.setEnd(e,t),Zf(n)||o(ol(rl(n),!1))),t<e.data.length&&(n.setStart(e,t),n.setEnd(e,t+1),Zf(n)||o(ol(rl(n),!0)))};if(Wf(e.container()))return i(e.container(),e.offset()),r;if(zf(e.container()))if(e.isAtEnd())n=Yf(e.container(),e.offset()),Wf(n)&&i(n,n.data.length),qf(n)&&!Kf(n)&&o(ol(rl(n),!1));else{if(n=Yf(e.container(),e.offset()),Wf(n)&&i(n,0),qf(n)&&e.isAtEnd())return o(ol(rl(n),!1)),r;t=Yf(e.container(),e.offset()-1),qf(t)&&!Kf(t)&&(Hf(t)||Hf(n)||!qf(n))&&o(ol(rl(t),!1)),qf(n)&&o(ol(rl(n),!0))}return r};!function(e){e.fromRangeStart=function(t){return e(t.startContainer,t.startOffset)},e.fromRangeEnd=function(t){return e(t.endContainer,t.endOffset)},e.after=function(t){return e(t.parentNode,Xf(t)+1)},e.before=function(t){return e(t.parentNode,Xf(t))},e.isAbove=function(e,t){return cf(ft(t.getClientRects()),lt(e.getClientRects()),hf).getOr(!1)},e.isBelow=function(e,t){return cf(lt(t.getClientRects()),ft(e.getClientRects()),vf).getOr(!1)},e.isAtStart=function(e){return!!e&&e.isAtStart()},e.isAtEnd=function(e){return!!e&&e.isAtEnd()},e.isTextPosition=function(e){return!!e&&Io(e.container())},e.isElementPosition=function(t){return e.isTextPosition(t)===!1}}(E||(E={}));var al,ul=E,cl=function(e,t){Io(t)&&0===t.data.length&&e.remove(t)},sl=function(e,t,n){t.insertNode(n),cl(e,n.previousSibling),cl(e,n.nextSibling)},fl=function(e,t,n){var r=_e.from(n.firstChild),o=_e.from(n.lastChild);t.insertNode(n),r.each(function(t){return cl(e,t.previousSibling)}),o.each(function(t){return cl(e,t.nextSibling)})},ll=function(e,t,n){Uo(n)?fl(e,t,n):sl(e,t,n)},dl=Io,ml=Do,pl=Ac.nodeIndex,gl=function(e){var t=e.parentNode;return ml(t)?gl(t):t},hl=function(e){return e?Bt(e.childNodes,function(e,t){return ml(t)&&"BR"!==t.nodeName?e=e.concat(hl(t)):e.push(t),e},[]):[]},vl=function(e,t){for(;(e=e.previousSibling)&&dl(e);)t+=e.data.length;return t},yl=function(e){return function(t){return e===t}},bl=function(e){var t,n;t=hl(gl(e)),n=Pt(t,yl(e),e),t=t.slice(0,n+1);var r=Bt(t,function(e,n,r){return dl(n)&&dl(t[r-1])&&e++,e},0);return t=Dt(t,_o([e.nodeName])),n=Pt(t,yl(e),e),n-r},Cl=function(e){var t;return t=dl(e)?"text()":e.nodeName.toLowerCase(),t+"["+bl(e)+"]"},wl=function(e,t,n){var r=[];for(t=t.parentNode;t!==e&&(!n||!n(t));t=t.parentNode)r.push(t);return r},xl=function(e,t){var n,r,o,i,a,u=[];return n=t.container(),r=t.offset(),dl(n)?o=vl(n,r):(i=n.childNodes,r>=i.length?(o="after",r=i.length-1):o="before",n=i[r]),u.push(Cl(n)),a=wl(e,n),a=Dt(a,be(Do)),u=u.concat(At(a,function(e){return Cl(e)})),u.reverse().join("/")+","+o},Sl=function(e,t,n){var r=hl(e);return r=Dt(r,function(e,t){return!dl(e)||!dl(r[t-1])}),r=Dt(r,_o([t])),r[n]},Nl=function(e,t){for(var n,r=e,o=0;dl(r);){if(n=r.data.length,t>=o&&t<=o+n){e=r,t-=o;break}if(!dl(r.nextSibling)){e=r,t=n;break}o+=n,r=r.nextSibling}return dl(e)&&t>e.data.length&&(t=e.data.length),ul(e,t)},El=function(e,t){var n;if(!t)return null;var r=t.split(","),o=r[0].split("/");n=r.length>1?r[1]:"before";var i=Bt(o,function(e,t){return(t=/([\w\-\(\)]+)\[([0-9]+)\]/.exec(t))?("text()"===t[1]&&(t[1]="#text"),Sl(e,t[1],parseInt(t[2],10))):null},e);return i?dl(i)?Nl(i,parseInt(n,10)):(n="after"===n?pl(i)+1:pl(i),ul(i.parentNode,n)):null},kl=Ho,_l=function(e,t,n){var r,o;for(o=e(t.data.slice(0,n)).length,r=t.previousSibling;r&&Io(r);r=r.previousSibling)o+=e(r.data).length;return o},Tl=function(e,t,n,r,o){var i,a=r[o?"startContainer":"endContainer"],u=r[o?"startOffset":"endOffset"],c=[],s=0,f=e.getRoot();for(Io(a)?c.push(n?_l(t,a,u):u):(i=a.childNodes,u>=i.length&&i.length&&(s=1,u=Math.max(0,i.length-1)),c.push(e.nodeIndex(i[u],n)+s));a&&a!==f;a=a.parentNode)c.push(e.nodeIndex(a,n));return c},Rl=function(e,t,n,r){var o=t.dom,i={};return i.start=Tl(o,e,n,r,!0),t.isCollapsed()||(i.end=Tl(o,e,n,r,!1)),i},Al=function(e,t,n){var r=0;return er.each(e.select(t),function(e){if("all"!==e.getAttribute("data-mce-bogus"))return e!==n&&void r++}),r},Dl=function(e,t){var n,r,o,i=t?"start":"end";n=e[i+"Container"],r=e[i+"Offset"],ko(n)&&"TR"===n.nodeName&&(o=n.childNodes,n=o[Math.min(t?r:r-1,o.length-1)],n&&(r=t?0:n.childNodes.length,e["set"+(t?"Start":"End")](n,r)))},Ol=function(e){return Dl(e,!0),Dl(e,!1),e},Bl=function(e,t){var n;if(ko(e)&&(e=Cf(e,t),kl(e)))return e;if(Xs(e)){if(Io(e)&&Ws(e)&&(e=e.parentNode),n=e.previousSibling,kl(n))return n;if(n=e.nextSibling,kl(n))return n}},Pl=function(e){return Bl(e.startContainer,e.startOffset)||Bl(e.endContainer,e.endOffset)},Ll=function(e,t,n){var r=n.getNode(),o=r?r.nodeName:null,i=n.getRng();if(kl(r)||"IMG"===o)return{name:o,index:Al(n.dom,o,r)};var a=Pl(i);return a?(o=a.tagName,{name:o,index:Al(n.dom,o,a)}):Rl(e,n,t,i)},Il=function(e){var t=e.getRng();return{start:xl(e.dom.getRoot(),ul.fromRangeStart(t)),end:xl(e.dom.getRoot(),ul.fromRangeEnd(t))}},Ml=function(e){return{rng:e.getRng()}},Fl=function(e,t,n){var r={"data-mce-type":"bookmark",id:t,style:"overflow:hidden;line-height:0px"};return n?e.create("span",r,"&#xFEFF;"):e.create("span",r)},Ul=function(e,t){var n=e.dom,r=e.getRng(),o=n.uniqueId(),i=e.isCollapsed(),a=e.getNode(),u=a.nodeName;if("IMG"===u)return{name:u,index:Al(n,u,a)};var c=Ol(r.cloneRange());if(!i){c.collapse(!1);var s=Fl(n,o+"_end",t);ll(n,c,s)}r=Ol(r),r.collapse(!0);var f=Fl(n,o+"_start",t);return ll(n,r,f),e.moveToBookmark({id:o,keep:!0}),{id:o}},zl=function(e,t,n){return 2===t?Ll(Vs,n,e):3===t?Il(e):t?Ml(e):Ul(e,!1)},jl=t(Ll,ye,!0),Hl=Ac.DOM,Vl="font-family font-size font-weight font-style text-decoration text-transform color background-color border border-radius outline text-shadow",ql=function(e,t,n){var r=e.getParam(t,n);if(r.indexOf("=")!==-1){var o=e.getParam(t,"","hash");return o.hasOwnProperty(e.id)?o[e.id]:n}return r},$l=function(e){return e.getParam("iframe_attrs",{})},Wl=function(e){return e.getParam("doctype","<!DOCTYPE html>")},Kl=function(e){return e.getParam("document_base_url","")},Xl=function(e){return ql(e,"body_id","tinymce")},Yl=function(e){return ql(e,"body_class","")},Gl=function(e){return e.getParam("content_security_policy","")},Jl=function(e){return e.getParam("br_in_pre",!0)},Ql=function(e){if(e.getParam("force_p_newlines",!1))return"p";var t=e.getParam("forced_root_block","p");return t===!1?"":t===!0?"p":t},Zl=function(e){return e.getParam("forced_root_block_attrs",{})},ed=function(e){return e.getParam("br_newline_selector",".mce-toc h2,figcaption,caption")},td=function(e){return e.getParam("no_newline_selector","")},nd=function(e){return e.getParam("keep_styles",!0)},rd=function(e){return e.getParam("end_container_on_empty_block",!1)},od=function(e){return er.explode(e.getParam("font_size_style_values","xx-small,x-small,small,medium,large,x-large,xx-large"))},id=function(e){return er.explode(e.getParam("font_size_classes",""))},ad=function(e){return e.getParam("images_dataimg_filter",ve(!0),"function")},ud=function(e){return e.getParam("automatic_uploads",!0,"boolean")},cd=function(e){return e.getParam("images_reuse_filename",!1,"boolean")},sd=function(e){return e.getParam("images_replace_blob_uris",!0,"boolean")},fd=function(e){return e.getParam("icons","","string")},ld=function(e){return e.getParam("icons_url","","string")},dd=function(e){return e.getParam("images_upload_url","","string")},md=function(e){return e.getParam("images_upload_base_path","","string")},pd=function(e){return e.getParam("images_upload_credentials",!1,"boolean")},gd=function(e){return e.getParam("images_upload_handler",null,"function")},hd=function(e){return e.getParam("content_css_cors",!1,"boolean")},vd=function(e){return e.getParam("referrer_policy","","string")},yd=function(e){return e.getParam("language","en","string")},bd=function(e){return e.getParam("language_url","","string")},Cd=function(e){return e.getParam("indent_use_margin",!1)},wd=function(e){return e.getParam("indentation","40px","string")},xd=function(e){var t=e.getParam("content_css");return Oe(t)?Ke(t.split(","),Cn):Pe(t)?t:t===!1||e.inline?[]:["default"]},Sd=function(e){return e.getParam("directionality",Qc.isRtl()?"rtl":void 0)},Nd=function(e){return e.getParam("inline_boundaries_selector","a[href],code,.mce-annotation","string")},Ed=function(e){return e.getParam("object_resizing")},kd=function(e){return e.getParam("resize_img_proportional",!0,"boolean")},_d=function(e){return e.getParam("placeholder",Hl.getAttrib(e.getElement(),"placeholder"),"string")},Td=function(e){return e.getParam("event_root")},Rd=function(e){return e.getParam("service_message")},Ad=function(e){return e.getParam("theme")},Dd=function(e){return e.getParam("validate")},Od=function(e){return e.getParam("inline_boundaries")!==!1},Bd=function(e){return e.getParam("formats")},Pd=function(e){var t=e.getParam("preview_styles",Vl);return Oe(t)?t:""},Ld=function(e){return e.getParam("custom_ui_selector","","string")},Id=function(e){return e.getParam("theme_url")},Md=function(e){return e.getParam("inline")},Fd=function(e){return e.getParam("hidden_input")},Ud=function(e){return e.getParam("submit_patch")},zd=function(e){return"xml"===e.getParam("encoding")},jd=function(e){return e.getParam("add_form_submit_trigger")},Hd=function(e){return e.getParam("add_unload_trigger")},Vd=function(e){return""!==Ql(e)},qd=function(e){return e.getParam("custom_undo_redo_levels",0,"number")},$d=function(e){return e.getParam("disable_nodechange")},Wd=function(e){return e.getParam("readonly")},Kd=function(e){return e.getParam("content_css_cors")},Xd=function(e){return e.getParam("plugins")},Yd=function(e){return e.getParam("external_plugins")},Gd=function(e){return e.getParam("block_unsupported_drop",!0,"boolean")},Jd=ko,Qd=Io,Zd=function(e){var t=e.parentNode;t&&t.removeChild(e)},em=function(e){try{return e.nodeValue}catch(t){return""}},tm=function(e,t){0===t.length?Zd(e):e.nodeValue=t},nm=function(e){var t=Vs(e);return{count:e.length-t.length,text:t}},rm=function(e,t){return sm(e),t},om=function(e,t){var n=nm(e.data.substr(0,t.offset())),r=nm(e.data.substr(t.offset())),o=n.text+r.text;return o.length>0?(tm(e,o),ul(e,t.offset()-n.count)):t},im=function(e,t){var n=t.container(),r=qe(dt(n.childNodes),e).map(function(e){return e<t.offset()?ul(n,t.offset()-1):t}).getOr(t);return sm(e),r},am=function(e,t){return Qd(e)&&t.container()===e?om(e,t):rm(e,t)},um=function(e,t){return t.container()===e.parentNode?im(e,t):rm(e,t)},cm=function(e,t){return ul.isTextPosition(t)?am(e,t):um(e,t)},sm=function(e){if(Jd(e)&&Xs(e)&&(Ys(e)?e.removeAttribute("data-mce-caret"):Zd(e)),Qd(e)){var t=Vs(em(e));tm(e,t)}},fm=On().browser,lm=Ho,dm=function(e){return ko(e)&&/^(TD|TH)$/i.test(e.tagName)},mm=function(e,t,n){var r,o,i,a,u,c=mf(t.getBoundingClientRect(),n);return"BODY"===e.tagName?(r=e.ownerDocument.documentElement,o=e.scrollLeft||r.scrollLeft,i=e.scrollTop||r.scrollTop):(u=e.getBoundingClientRect(),o=e.scrollLeft-u.left,i=e.scrollTop-u.top),c.left+=o,c.right+=o,c.top+=i,c.bottom+=i,c.width=1,a=t.offsetWidth-t.clientWidth,a>0&&(n&&(a*=-1),c.left+=a,c.right+=a),c},pm=function(e){var t,n,r,o,i=ps(ar.fromDom(e),"*[contentEditable=false]");for(r=0;r<i.length;r++)t=i[r].dom(),n=t.previousSibling,nf(n)&&(o=n.data,1===o.length?n.parentNode.removeChild(n):n.deleteData(o.length-1,1)),n=t.nextSibling,tf(n)&&(o=n.data,1===o.length?n.parentNode.removeChild(n):n.deleteData(0,1))},gm=function(e,t,n,r){var o,i,a=Uc(_e.none()),u=Ql(e),c=u.length>0?u:"p",s=function(e,r){var o,u;if(f(),dm(r))return null;if(!n(r))return i=Gs(r,e),u=r.ownerDocument.createRange(),lm(i.nextSibling)?(u.setStart(i,0),u.setEnd(i,0)):(u.setStart(i,1),u.setEnd(i,1)),u;i=ef(c,r,e),o=mm(t,r,e),Vu(i).css("top",o.top);var s=Vu('<div class="mce-visual-caret" data-mce-bogus="all"></div>').css(o).appendTo(t)[0];return a.set(_e.some({caret:s,element:r,before:e})),a.get().each(function(t){e&&Vu(t.caret).addClass("mce-visual-caret-before")}),l(),u=r.ownerDocument.createRange(),u.setStart(i,0),u.setEnd(i,0),u},f=function(){pm(t),i&&(sm(i),i=null),a.get().each(function(e){Vu(e.caret).remove(),a.set(_e.none())}),o&&(Cc.clearInterval(o),o=null)},l=function(){o=Cc.setInterval(function(){r()?Vu("div.mce-visual-caret",t).toggleClass("mce-visual-caret-hidden"):Vu("div.mce-visual-caret",t).addClass("mce-visual-caret-hidden")},500)},d=function(){a.get().each(function(e){var n=mm(t,e.element,e.before);Vu(e.caret).css(It({},n))})},m=function(){return Cc.clearInterval(o)},p=function(){return".mce-visual-caret {position: absolute;background-color: black;background-color: currentcolor;}.mce-visual-caret-hidden {display: none;}*[data-mce-caret] {position: absolute;left: -1000px;right: auto;top: 0;margin: 0;padding: 0;}"};return{show:s,hide:f,getCss:p,reposition:d,destroy:m}},hm=function(){return fm.isIE()||fm.isEdge()||fm.isFirefox()},vm=function(e){return lm(e)||Bo(e)&&hm()},ym=Ho,bm=To("display","block table table-cell table-caption list-item"),Cm=Xs,wm=Ws,xm=ko,Sm=Bf,Nm=function(e){return e>0},Em=function(e){return e<0},km=function(e,t){for(var n;n=e(t);)if(!wm(n))return n;return null},_m=function(e,t,n,r,o){var i=new qu(e,r);if(Em(t)){if((ym(e)||wm(e))&&(e=km(i.prev,!0),n(e)))return e;for(;e=km(i.prev,o);)if(n(e))return e}if(Nm(t)){if((ym(e)||wm(e))&&(e=km(i.next,!0),n(e)))return e;for(;e=km(i.next,o);)if(n(e))return e}return null},Tm=function(e,t){for(;e&&e!==t;){if(bm(e))return e;e=e.parentNode}return null},Rm=function(e,t,n){return Tm(e.container(),n)===Tm(t.container(),n)},Am=function(e,t){if(!t)return null;var n=t.container(),r=t.offset();return xm(n)?n.childNodes[r+e]:null},Dm=function(e,t){var n=t.ownerDocument.createRange();return e?(n.setStartBefore(t),n.setEndBefore(t)):(n.setStartAfter(t),n.setEndAfter(t)),n},Om=function(e,t,n){return Tm(t,e)===Tm(n,e)},Bm=function(e,t,n){var r,o;for(o=e?"previousSibling":"nextSibling";n&&n!==t;){if(r=n[o],Cm(r)&&(r=r[o]),ym(r)){if(Om(t,r,n))return r;break}if(Sm(r))break;n=n.parentNode}return null},Pm=t(Dm,!0),Lm=t(Dm,!1),Im=function(e,n,r){var o,i,a,u=t(Bm,!0,n),c=t(Bm,!1,n);i=r.startContainer;var s=r.startOffset;if(Ws(i)){if(xm(i)||(i=i.parentNode),a=i.getAttribute("data-mce-caret"),"before"===a&&(o=i.nextSibling,vm(o)))return Pm(o);if("after"===a&&(o=i.previousSibling,vm(o)))return Lm(o)}if(!r.collapsed)return r;if(Io(i)){if(Cm(i)){if(1===e){if(o=c(i))return Pm(o);if(o=u(i))return Lm(o)}if(e===-1){if(o=u(i))return Lm(o);if(o=c(i))return Pm(o)}return r}if(nf(i)&&s>=i.data.length-1)return 1===e&&(o=c(i))?Pm(o):r;if(tf(i)&&s<=1)return e===-1&&(o=u(i))?Lm(o):r;if(s===i.data.length)return o=c(i),o?Pm(o):r;if(0===s)return o=u(i),o?Lm(o):r}return r},Mm=function(e,t){return _e.from(Am(e?0:-1,t)).filter(ym)},Fm=function(e,t,n){var r=Im(e,t,n);return e===-1?E.fromRangeStart(r):E.fromRangeEnd(r)},Um=function(e){return _e.from(e.getNode()).map(ar.fromDom)},zm=function(e){return _e.from(e.getNode(!0)).map(ar.fromDom)},jm=function(e,t){for(;t=e(t);)if(t.isVisible())return t;return t},Hm=function(e,t){var n=Rm(e,t);return!(n||!zo(e.getNode()))||n};!function(e){e[e.Backwards=-1]="Backwards",e[e.Forwards=1]="Forwards"}(al||(al={}));var Vm=Ho,qm=Io,$m=ko,Wm=zo,Km=Bf,Xm=Ff,Ym=Uf,Gm=function(e,t){for(var n=[];e&&e!==t;)n.push(e),e=e.parentNode;return n},Jm=function(e,t){return e.hasChildNodes()&&t<e.childNodes.length?e.childNodes[t]:null},Qm=function(e,t){if(Nm(e)){if(Km(t.previousSibling)&&!qm(t.previousSibling))return ul.before(t);if(qm(t))return ul(t,0)}if(Em(e)){if(Km(t.nextSibling)&&!qm(t.nextSibling))return ul.after(t);if(qm(t))return ul(t,t.data.length)}return Em(e)?Wm(t)?ul.before(t):ul.after(t):ul.before(t)},Zm=function(e,t){var n=t.nextSibling;return n&&Km(n)?qm(n)?ul(n,0):ul.before(n):ep(al.Forwards,ul.after(t),e)},ep=function(e,t,n){var r,o,i,a;if(!$m(n)||!t)return null;if(t.isEqual(ul.after(n))&&n.lastChild){if(a=ul.after(n.lastChild),Em(e)&&Km(n.lastChild)&&$m(n.lastChild))return Wm(n.lastChild)?ul.before(n.lastChild):a}else a=t;var u=a.container(),c=a.offset();if(qm(u)){if(Em(e)&&c>0)return ul(u,--c);if(Nm(e)&&c<u.length)return ul(u,++c);r=u}else{if(Em(e)&&c>0&&(o=Jm(u,c-1),Km(o)))return!Xm(o)&&(i=_m(o,e,Ym,o))?qm(i)?ul(i,i.data.length):ul.after(i):qm(o)?ul(o,o.data.length):ul.before(o);if(Nm(e)&&c<u.childNodes.length&&(o=Jm(u,c),Km(o)))return Wm(o)?Zm(n,o):!Xm(o)&&(i=_m(o,e,Ym,o))?qm(i)?ul(i,0):ul.before(i):qm(o)?ul(o,0):ul.after(o);r=o?o:a.getNode()}if((Nm(e)&&a.isAtEnd()||Em(e)&&a.isAtStart())&&(r=_m(r,e,ve(!0),n,!0),Ym(r,n)))return Qm(e,r);o=_m(r,e,Ym,n);var s=Lt(Je(Gm(u,n),Vm));return!s||o&&s.contains(o)?o?Qm(e,o):null:a=Nm(e)?ul.after(s):ul.before(s)},tp=function(e){return{next:function(t){return ep(al.Forwards,t,e)},prev:function(t){return ep(al.Backwards,t,e)}}},np=function(e,t,n){var r=e?ul.before(n):ul.after(n);return sp(e,t,r)},rp=function(e){return zo(e)?ul.before(e):ul.after(e)},op=function(e){return ul.isTextPosition(e)?0===e.offset():Bf(e.getNode())},ip=function(e){if(ul.isTextPosition(e)){var t=e.container();return e.offset()===t.data.length}return Bf(e.getNode(!0))},ap=function(e,t){return!ul.isTextPosition(e)&&!ul.isTextPosition(t)&&e.getNode()===t.getNode(!0)},up=function(e){return!ul.isTextPosition(e)&&zo(e.getNode())},cp=function(e,t,n){return e?!ap(t,n)&&!up(t)&&ip(t)&&op(n):!ap(n,t)&&op(t)&&ip(n)},sp=function(e,t,n){var r=tp(t);return _e.from(e?r.next(n):r.prev(n))},fp=function(e,t,n){return sp(e,t,n).bind(function(r){return Rm(n,r,t)&&cp(e,n,r)?sp(e,t,r):_e.some(r)})},lp=function(e,t,n,r){return fp(e,t,n).bind(function(n){return r(n)?lp(e,t,n,r):_e.some(n)})},dp=function(e,t){var n=e?t.firstChild:t.lastChild;return Io(n)?_e.some(ul(n,e?0:n.data.length)):n?Bf(n)?_e.some(e?ul.before(n):rp(n)):np(e,t,n):_e.none()},mp=t(sp,!0),pp=t(sp,!1),gp=t(dp,!0),hp=t(dp,!1),vp="_mce_caret",yp=function(e){return ko(e)&&e.id===vp},bp=function(e,t){for(;t&&t!==e;){if(t.id===vp)return t;t=t.parentNode}return null},Cp=function(e){return"string"==typeof e.start},wp=function(e){return e.hasOwnProperty("rng")},xp=function(e){return e.hasOwnProperty("id")},Sp=function(e){return e.hasOwnProperty("name")},Np=function(e){return er.isArray(e.start)},Ep=function(e,t){return ko(t)&&e.isBlock(t)&&!t.innerHTML&&!jn.ie&&(t.innerHTML='<br data-mce-bogus="1" />'),t},kp=function(e,t){var n,r=e.createRng();return n=El(e.getRoot(),t.start),r.setStart(n.container(),n.offset()),n=El(e.getRoot(),t.end),r.setEnd(n.container(),n.offset()),r},_p=function(e,t){var n=e.ownerDocument.createTextNode(js);e.appendChild(n),t.setStart(n,0),t.setEnd(n,0)},Tp=function(e){return e.hasChildNodes()===!1},Rp=function(e,t){return hp(e).fold(function(){return!1},function(e){return t.setStart(e.container(),e.offset()),t.setEnd(e.container(),e.offset()),!0})},Ap=function(e,t,n){return!(!Tp(t)||!bp(e,t))&&(_p(t,n),!0)},Dp=function(e,t,n,r){var o,i,a,u,c=n[t?"start":"end"],s=e.getRoot();if(c){for(a=c[0],i=s,o=c.length-1;o>=1;o--){if(u=i.childNodes,Ap(s,i,r))return!0;if(c[o]>u.length-1)return!!Ap(s,i,r)||Rp(i,r);i=u[c[o]]}3===i.nodeType&&(a=Math.min(c[0],i.nodeValue.length)),1===i.nodeType&&(a=Math.min(c[0],i.childNodes.length)),t?r.setStart(i,a):r.setEnd(i,a)}return!0},Op=function(e){return Io(e)&&e.data.length>0},Bp=function(e,t,n){var r,o,i,a,u,c,s=e.get(n.id+"_"+t),f=n.keep;if(s){if(r=s.parentNode,"start"===t?(f?s.hasChildNodes()?(r=s.firstChild,o=1):Op(s.nextSibling)?(r=s.nextSibling,o=0):Op(s.previousSibling)?(r=s.previousSibling,o=s.previousSibling.data.length):(r=s.parentNode,o=e.nodeIndex(s)+1):o=e.nodeIndex(s),u=r,c=o):(f?s.hasChildNodes()?(r=s.firstChild,o=1):Op(s.previousSibling)?(r=s.previousSibling,o=s.previousSibling.data.length):(r=s.parentNode,o=e.nodeIndex(s)):o=e.nodeIndex(s),u=r,c=o),!f){for(a=s.previousSibling,i=s.nextSibling,er.each(er.grep(s.childNodes),function(e){Io(e)&&(e.nodeValue=e.nodeValue.replace(/\uFEFF/g,""))});s=e.get(n.id+"_"+t);)e.remove(s,!0);a&&i&&a.nodeType===i.nodeType&&Io(a)&&!jn.opera&&(o=a.nodeValue.length,a.appendData(i.nodeValue),e.remove(i),"start"===t?(u=a,c=o):(u=a,c=o))}return _e.some(ul(u,c))}return _e.none()},Pp=function(e,t){var n=e.createRng();return Dp(e,!0,t,n)&&Dp(e,!1,t,n)?_e.some(n):_e.none()},Lp=function(e,t){var n=Bp(e,"start",t),r=Bp(e,"end",t);return cf(n,r.or(n),function(t,n){var r=e.createRng();return r.setStart(Ep(e,t.container()),t.offset()),r.setEnd(Ep(e,n.container()),n.offset()),r})},Ip=function(e,t){return _e.from(e.select(t.name)[t.index]).map(function(t){var n=e.createRng();return n.selectNode(t),n})},Mp=function(e,t){var n=e.dom;if(t){if(Np(t))return Pp(n,t);if(Cp(t))return _e.some(kp(n,t));if(xp(t))return Lp(n,t);if(Sp(t))return Ip(n,t);if(wp(t))return _e.some(t.rng)}return _e.none()},Fp=function(e,t,n){return zl(e,t,n)},Up=function(e,t){Mp(e,t).each(function(t){e.setRng(t)})},zp=function(e){return ko(e)&&"SPAN"===e.tagName&&"bookmark"===e.getAttribute("data-mce-type")},jp=function(e){return function(t){return e===t}},Hp=jp(da),Vp=function(e){return""!==e&&" \f\n\r\t\x0B".indexOf(e)!==-1},qp=function(e){return!Vp(e)&&!Hp(e)},$p=function(e){return!!e.nodeType},Wp=function(e){return e&&/^(IMG)$/.test(e.nodeName)},Kp=function(e,t,n){var r,o,i,a=n.startOffset,u=n.startContainer;if((n.startContainer!==n.endContainer||!Wp(n.startContainer.childNodes[n.startOffset]))&&1===u.nodeType)for(i=u.childNodes,a<i.length?(u=i[a],r=new qu(u,e.getParent(u,e.isBlock))):(u=i[i.length-1],r=new qu(u,e.getParent(u,e.isBlock)),r.next(!0)),o=r.current();o;o=r.next())if(3===o.nodeType&&!Jp(o))return n.setStart(o,0),void t.setRng(n)},Xp=function(e,t,n){if(e){var r=t?"nextSibling":"previousSibling";for(e=n?e:e[r];e;e=e[r])if(1===e.nodeType||!Jp(e))return e}},Yp=function(e,t){return $p(t)&&(t=t.nodeName),!!e.schema.getTextBlockElements()[t.toLowerCase()]},Gp=function(e,t,n){return e.schema.isValidChild(t,n)},Jp=function(e){return e&&Io(e)&&/^([\t \r\n]+|)$/.test(e.nodeValue)},Qp=function(e){return e&&Io(e)&&0===e.length},Zp=function(e,t){return"string"!=typeof e?e=e(t):t&&(e=e.replace(/%(\w+)/g,function(e,n){return t[n]||e})),e},eg=function(e,t){return e=e||"",t=t||"",e=""+(e.nodeName||e),t=""+(t.nodeName||t),e.toLowerCase()===t.toLowerCase()},tg=function(e,t,n){return"color"!==n&&"backgroundColor"!==n||(t=e.toHex(t)),"fontWeight"===n&&700===t&&(t="bold"),"fontFamily"===n&&(t=t.replace(/[\'\"]/g,"").replace(/,\s+/g,",")),""+t},ng=function(e,t,n){return tg(e,e.getStyle(t,n),n)},rg=function(e,t){var n;return e.getParent(t,function(t){return n=e.getStyle(t,"text-decoration"),n&&"none"!==n}),n},og=function(e,t,n){return e.getParents(t,n,e.getRoot())},ig=function(e,t){var n=function(e){var t=function(e){return e.length>1&&"%"===e.charAt(0)};return We(["styles","attributes"],function(n){return Nt(e,n).exists(function(e){var n=Pe(e)?e:St(e);return We(n,t)})})};return We(e.formatter.get(t),n)},ag=function(e,t,n){var r=["inline","block","selector","attributes","styles","classes"],o=function(e){return wt(e,function(e,t){return We(r,function(e){return e===t})})};return We(e.formatter.get(t),function(t){var r=o(t);return We(e.formatter.get(n),function(e){var t=o(e);return kt(r,t)})})},ug=zp,cg=og,sg=Jp,fg=Yp,lg=function(e){return"BR"===e.nodeName&&e.getAttribute("data-mce-bogus")&&!e.nextSibling},dg=function(e,t){for(var n=t;n;){if(ko(n)&&e.getContentEditable(n))return"false"===e.getContentEditable(n)?n:t;n=n.parentNode}return t},mg=function(e,t,n,r){for(var o=t.data,i=n;e?i>=0:i<o.length;e?i--:i++)if(r(o.charAt(i)))return e?i+1:i;return-1},pg=function(e,t,n){return mg(e,t,n,function(e){return Hp(e)||Vp(e)})},gg=function(e,t,n){return mg(e,t,n,qp)},hg=function(e,t,n,r,o,i){var a,u=e.getParent(n,e.isBlock)||t,c=function(t,n,r){var i=zs(e),c=o?i.backwards:i.forwards;return _e.from(c(t,n,function(e,t){return ug(e.parentNode)?-1:(a=e,r(o,e,t))},u))},s=c(n,r,pg);return s.bind(function(e){return i?c(e.container,e.offset+(o?-1:0),gg):_e.some(e)}).orThunk(function(){return a?_e.some({container:a,offset:o?0:a.length}):_e.none()})},vg=function(e,t,n,r,o){Io(r)&&0===r.nodeValue.length&&r[o]&&(r=r[o]);for(var i=cg(e,r),a=0;a<i.length;a++)for(var u=0;u<t.length;u++){var c=t[u];if(!("collapsed"in c&&c.collapsed!==n.collapsed)&&e.is(i[a],c.selector))return i[a]}return r},yg=function(e,t,n,r){var o,i=e.dom,a=i.getRoot();if(t[0].wrapper||(o=i.getParent(n,t[0].block,a)),!o){var u=i.getParent(n,"LI,TD,TH");o=i.getParent(Io(n)?n.parentNode:n,function(t){return t!==a&&fg(e,t)},u)}if(o&&t[0].wrapper&&(o=cg(i,o,"ul,ol").reverse()[0]||o),!o)for(o=n;o[r]&&!i.isBlock(o[r])&&(o=o[r],!eg(o,"br")););return o||n},bg=function(e,t,n,r,o,i,a){var u,c,s;u=c=a?n:o;var f=a?"previousSibling":"nextSibling",l=e.getRoot();if(Io(u)&&!sg(u)&&(a?r>0:i<u.nodeValue.length))return u;for(;;){if(!t[0].block_expand&&e.isBlock(c))return c;for(s=c[f];s;s=s[f])if(!ug(s)&&!sg(s)&&!lg(s))return c;if(c===l||c.parentNode===l){u=c;break}c=c.parentNode}return u},Cg=function(e,t,n,r){void 0===r&&(r=!1);var o=t.startContainer,i=t.startOffset,a=t.endContainer,u=t.endOffset,c=e.dom;if(ko(o)&&o.hasChildNodes()&&(o=Cf(o,i),Io(o)&&(i=0)),ko(a)&&a.hasChildNodes()&&(a=Cf(a,t.collapsed?u:u-1),Io(a)&&(u=a.nodeValue.length)),o=dg(c,o),a=dg(c,a),(ug(o.parentNode)||ug(o))&&(o=ug(o)?o:o.parentNode,o=t.collapsed?o.previousSibling||o:o.nextSibling||o,Io(o)&&(i=t.collapsed?o.length:0)),(ug(a.parentNode)||ug(a))&&(a=ug(a)?a:a.parentNode,a=t.collapsed?a.nextSibling||a:a.previousSibling||a,Io(a)&&(u=t.collapsed?0:a.length)),t.collapsed){var s=hg(c,e.getBody(),o,i,!0,r);s.each(function(e){var t=e.container,n=e.offset;o=t,i=n});var f=hg(c,e.getBody(),a,u,!1,r);f.each(function(e){var t=e.container,n=e.offset;a=t,u=n})}return(n[0].inline||n[0].block_expand)&&(n[0].inline&&Io(o)&&0!==i||(o=bg(c,n,o,i,a,u,!0)),n[0].inline&&Io(a)&&u!==a.nodeValue.length||(a=bg(c,n,o,i,a,u,!1))),n[0].selector&&n[0].expand!==!1&&!n[0].inline&&(o=vg(c,n,t,o,"previousSibling"),a=vg(c,n,t,a,"nextSibling")),(n[0].block||n[0].selector)&&(o=yg(e,n,o,"previousSibling"),a=yg(e,n,a,"nextSibling"),n[0].block&&(c.isBlock(o)||(o=bg(c,n,o,i,a,u,!0)),c.isBlock(a)||(a=bg(c,n,o,i,a,u,!1)))),ko(o)&&(i=c.nodeIndex(o),o=o.parentNode),ko(a)&&(u=c.nodeIndex(a)+1,a=a.parentNode),{startContainer:o,startOffset:i,endContainer:a,endOffset:u}},wg=function(e,t){var n=e.childNodes;return t>=n.length?t=n.length-1:t<0&&(t=0),n[t]||e},xg=function(e,t){return wg(e,t-1)},Sg=function(e,t,n){var r=t.startContainer,o=t.startOffset,i=t.endContainer,a=t.endOffset,u=function(e){var t;return t=e[0],3===t.nodeType&&t===r&&o>=t.nodeValue.length&&e.splice(0,1),t=e[e.length-1],0===a&&e.length>0&&t===i&&3===t.nodeType&&e.splice(e.length-1,1),e},c=function(e,t,n){for(var r=[];e&&e!==n;e=e[t])r.push(e);return r},s=function(e,t){do{if(e.parentNode===t)return e;e=e.parentNode}while(e)},f=function(e,t,r){for(var o=r?"nextSibling":"previousSibling",i=e,a=i.parentNode;i&&i!==t;i=a){a=i.parentNode;var s=c(i===e?i:i[o],o);s.length&&(r||s.reverse(),n(u(s)))}};if(1===r.nodeType&&r.hasChildNodes()&&(r=wg(r,o)),1===i.nodeType&&i.hasChildNodes()&&(i=xg(i,a)),r===i)return n(u([r]));for(var l=e.findCommonAncestor(r,i),d=r;d;d=d.parentNode){if(d===i)return f(r,l,!0);if(d===l)break}for(var d=i;d;d=d.parentNode){if(d===r)return f(i,l);if(d===l)break}var m=s(r,l)||r,p=s(i,l)||i;f(r,m,!0);var g=c(m===r?m:m.nextSibling,"nextSibling",p===i?p.nextSibling:p);g.length&&n(u(g)),f(i,p)},Ng=function(e){var t=[];if(e)for(var n=0;n<e.rangeCount;n++)t.push(e.getRangeAt(n));return t},Eg=function(e){return ot(e,function(e){var t=bf(e);return t?[ar.fromDom(t)]:[]})},kg=function(e){return Ng(e).length>1},_g=function(e){return Je(Eg(e),Ai)},Tg=function(e){return ps(e,"td[data-mce-selected],th[data-mce-selected]")},Rg=function(e,t){var n=Tg(t);return n.length>0?n:_g(e)},Ag=function(e){return Rg(Ng(e.selection.getSel()),ar.fromDom(e.getBody()))},Dg=function(e){var t=e.startContainer,n=e.startOffset;return Io(t)?0===n?_e.some(ar.fromDom(t)):_e.none():_e.from(t.childNodes[n]).map(ar.fromDom)},Og=function(e){var t=e.endContainer,n=e.endOffset;return Io(t)?n===t.data.length?_e.some(ar.fromDom(t)):_e.none():_e.from(t.childNodes[n-1]).map(ar.fromDom)},Bg=function(e){return $r(e).fold(ve([e]),function(t){return[e].concat(Bg(t))})},Pg=function(e){return Wr(e).fold(ve([e]),function(t){return"br"===dr(t)?Ur(t).map(function(t){return[e].concat(Pg(t))}).getOr([]):[e].concat(Pg(t));
})},Lg=function(e,n){return cf(Dg(n),Og(n),function(n,r){var o=tt(Bg(e),t(Tr,n)),i=tt(Pg(e),t(Tr,r));return o.isSome()&&i.isSome()}).getOr(!1)},Ig=function(e,t,n,r){var o=n,i=new qu(n,o),a=e.schema.getNonEmptyElements();do{if(3===n.nodeType&&0!==er.trim(n.nodeValue).length)return void(r?t.setStart(n,0):t.setEnd(n,n.nodeValue.length));if(a[n.nodeName]&&!/^(TD|TH)$/.test(n.nodeName))return void(r?t.setStartBefore(n):"BR"===n.nodeName?t.setEndBefore(n):t.setEndAfter(n))}while(n=r?i.next():i.prev());"BODY"===o.nodeName&&(r?t.setStart(o,0):t.setEnd(o,o.childNodes.length))},Mg=function(e){var t=e.selection.getSel();return t&&t.rangeCount>0},Fg=function(e,t){var n=Ag(e);n.length>0?Xe(n,function(n){var r=n.dom(),o=e.dom.createRng();o.setStartBefore(r),o.setEndAfter(r),t(o,!0)}):t(e.selection.getRng(),!1)},Ug=function(e,t,n){var r=Ul(e,t);n(r),e.moveToBookmark(r)},zg=k(vr,"text"),jg=function(e){return zg.get(e)},Hg=function(e){return vr(e)&&jg(e)===la},Vg=function(e,t,n,r){return Ir(t).fold(function(){return"skipping"},function(o){return"br"===r||Hg(t)?"valid":Ns(t)?"existing":yp(t)?"caret":Gp(e,n,r)&&Gp(e,dr(o),n)?"valid":"invalid-child"})},qg=function(e,t){var n=Cg(e,t,[{inline:!0}]);t.setStart(n.startContainer,n.startOffset),t.setEnd(n.endContainer,n.endOffset),e.selection.setRng(t)},$g=function(e,t,r,o){var i=t.uid,a=void 0===i?Ds("mce-annotation"):i,u=n(t,["uid"]),c=ar.fromTag("span",e);ss(c,Cs()),$o(c,""+xs(),a),$o(c,""+ws(),r);var s=o(a,u),f=s.attributes,l=void 0===f?{}:f,d=s.classes,m=void 0===d?[]:d;return Wo(c,l),Os(c,m),c},Wg=function(e,t,n,r,o){var i=[],a=$g(e.getDoc(),o,n,r),u=Uc(_e.none()),c=function(){u.set(_e.none())},s=function(){return u.get().getOrThunk(function(){var e=Ms(a);return i.push(e),u.set(_e.some(e)),e})},f=function(e){Xe(e,l)},l=function(t){var n=Vg(e,t,"span",dr(t));switch(n){case"invalid-child":c();var r=Vr(t);f(r),c();break;case"valid":var o=s();oo(t,o)}},d=function(e){var t=Ke(e,ar.fromDom);f(t)};return Sg(e.dom,t,function(e){c(),d(e)}),i},Kg=function(e,t,n,r){e.undoManager.transact(function(){var o=e.selection,i=o.getRng(),a=Ag(e).length>0;if(i.collapsed&&!a&&qg(e,i),o.getRng().collapsed&&!a){var u=$g(e.getDoc(),r,t,n.decorate);Ls(u,da),o.getRng().insertNode(u.dom()),o.select(u.dom())}else Ug(o,!1,function(){Fg(e,function(o){Wg(e,o,t,n.decorate,r)})})})},Xg=function(e){var t=Rs();Ts(e,t);var n=_s(e);return{register:function(e,n){t.register(e,n)},annotate:function(n,r){t.lookup(n).each(function(t){Kg(e,n,t,r)})},annotationChanged:function(e,t){n.addListener(e,t)},remove:function(t){Ss(e,_e.some(t)).each(function(e){var t=e.elements;Xe(t,so)})},getAll:function(t){var n=ks(e,t);return ht(n,function(e){return Ke(e,function(e){return e.dom()})})}}},Yg={"#text":3,"#comment":8,"#cdata":4,"#pi":7,"#doctype":10,"#document-fragment":11},Gg=function(e,t,n){var r=n?"lastChild":"firstChild",o=n?"prev":"next";if(e[r])return e[r];if(e!==t){var i=e[o];if(i)return i;for(var a=e.parent;a&&a!==t;a=a.parent)if(i=a[o])return i}},Jg=function(e){if(!Bi(e.value))return!1;var t=e.parent;return!t||"span"===t.name&&!t.attr("style")||!/^[ ]+$/.test(e.value)},Qg=function(e){var t="a"===e.name&&!e.attr("href")&&e.attr("id");return e.attr("name")||e.attr("id")&&!e.firstChild||e.attr("data-mce-bookmark")||t},Zg=function(){function e(e,t){this.name=e,this.type=t,1===t&&(this.attributes=[],this.attributes.map={})}return e.create=function(t,n){var r=new e(t,Yg[t]||1);return n&&gt(n,function(e,t){r.attr(t,e)}),r},e.prototype.replace=function(e){var t=this;return e.parent&&e.remove(),t.insert(e,t),t.remove(),t},e.prototype.attr=function(e,t){var n,r=this;if("string"!=typeof e)return void 0!==e&&null!==e&&gt(e,function(e,t){r.attr(t,e)}),r;if(n=r.attributes){if(void 0!==t){if(null===t){if(e in n.map){delete n.map[e];for(var o=n.length;o--;)if(n[o].name===e)return n.splice(o,1),r}return r}if(e in n.map){for(var o=n.length;o--;)if(n[o].name===e){n[o].value=t;break}}else n.push({name:e,value:t});return n.map[e]=t,r}return n.map[e]}},e.prototype.clone=function(){var t,n=this,r=new e(n.name,n.type);if(t=n.attributes){var o=[];o.map={};for(var i=0,a=t.length;i<a;i++){var u=t[i];"id"!==u.name&&(o[o.length]={name:u.name,value:u.value},o.map[u.name]=u.value)}r.attributes=o}return r.value=n.value,r.shortEnded=n.shortEnded,r},e.prototype.wrap=function(e){var t=this;return t.parent.insert(e,t),e.append(t),t},e.prototype.unwrap=function(){for(var e=this,t=e.firstChild;t;){var n=t.next;e.insert(t,e,!0),t=n}e.remove()},e.prototype.remove=function(){var e=this,t=e.parent,n=e.next,r=e.prev;return t&&(t.firstChild===e?(t.firstChild=n,n&&(n.prev=null)):r.next=n,t.lastChild===e?(t.lastChild=r,r&&(r.next=null)):n.prev=r,e.parent=e.next=e.prev=null),e},e.prototype.append=function(e){var t=this;e.parent&&e.remove();var n=t.lastChild;return n?(n.next=e,e.prev=n,t.lastChild=e):t.lastChild=t.firstChild=e,e.parent=t,e},e.prototype.insert=function(e,t,n){e.parent&&e.remove();var r=t.parent||this;return n?(t===r.firstChild?r.firstChild=e:t.prev.next=e,e.prev=t.prev,e.next=t,t.prev=e):(t===r.lastChild?r.lastChild=e:t.next.prev=e,e.next=t.next,e.prev=t,t.next=e),e.parent=r,e},e.prototype.getAll=function(e){for(var t=this,n=[],r=t.firstChild;r;r=Gg(r,t))r.name===e&&n.push(r);return n},e.prototype.empty=function(){var e=this;if(e.firstChild){for(var t=[],n=e.firstChild;n;n=Gg(n,e))t.push(n);for(var r=t.length;r--;){var n=t[r];n.parent=n.firstChild=n.lastChild=n.next=n.prev=null}}return e.firstChild=e.lastChild=null,e},e.prototype.isEmpty=function(e,t,n){void 0===t&&(t={});var r=this,o=r.firstChild;if(Qg(r))return!1;if(o)do{if(1===o.type){if(o.attr("data-mce-bogus"))continue;if(e[o.name])return!1;if(Qg(o))return!1}if(8===o.type)return!1;if(3===o.type&&!Jg(o))return!1;if(3===o.type&&o.parent&&t[o.parent.name]&&Bi(o.value))return!1;if(n&&n(o))return!1}while(o=Gg(o,r));return!0},e.prototype.walk=function(e){return Gg(this,null,e)},e}(),eh=er.makeMap,th=function(e){var t=[];e=e||{};var n=e.indent,r=eh(e.indent_before||""),o=eh(e.indent_after||""),i=ea.getEncodeFunc(e.entity_encoding||"raw",e.entities),a="html"===e.element_format;return{start:function(e,u,c){var s,f,l,d;if(n&&r[e]&&t.length>0&&(d=t[t.length-1],d.length>0&&"\n"!==d&&t.push("\n")),t.push("<",e),u)for(s=0,f=u.length;s<f;s++)l=u[s],t.push(" ",l.name,'="',i(l.value,!0),'"');!c||a?t[t.length]=">":t[t.length]=" />",c&&n&&o[e]&&t.length>0&&(d=t[t.length-1],d.length>0&&"\n"!==d&&t.push("\n"))},end:function(e){var r;t.push("</",e,">"),n&&o[e]&&t.length>0&&(r=t[t.length-1],r.length>0&&"\n"!==r&&t.push("\n"))},text:function(e,n){e.length>0&&(t[t.length]=n?e:i(e))},cdata:function(e){t.push("<![CDATA[",e,"]]>")},comment:function(e){t.push("<!--",e,"-->")},pi:function(e,r){r?t.push("<?",e," ",i(r),"?>"):t.push("<?",e,"?>"),n&&t.push("\n")},doctype:function(e){t.push("<!DOCTYPE",e,">",n?"\n":"")},reset:function(){t.length=0},getContent:function(){return t.join("").replace(/\n$/,"")}}},nh=function(e,t){void 0===t&&(t=o());var n=th(e);e=e||{},e.validate=!("validate"in e)||e.validate;var r=function(r){var o=e.validate,i={3:function(e){n.text(e.value,e.raw)},8:function(e){n.comment(e.value)},7:function(e){n.pi(e.name,e.value)},10:function(e){n.doctype(e.value)},4:function(e){n.cdata(e.value)},11:function(e){if(e=e.firstChild)do a(e);while(e=e.next)}};n.reset();var a=function(e){var r,u,c,s,f,l,d,m,p,g=i[e.type];if(g)g(e);else{if(r=e.name,u=e.shortEnded,c=e.attributes,o&&c&&c.length>1&&(l=[],l.map={},p=t.getElementRule(e.name))){for(d=0,m=p.attributesOrder.length;d<m;d++)s=p.attributesOrder[d],s in c.map&&(f=c.map[s],l.map[s]=f,l.push({name:s,value:f}));for(d=0,m=c.length;d<m;d++)s=c[d].name,s in l.map||(f=c.map[s],l.map[s]=f,l.push({name:s,value:f}));c=l}if(n.start(e.name,c,u),!u){if(e=e.firstChild)do a(e);while(e=e.next);n.end(r)}}};return 1!==r.type||e.inner?i[11](r):a(r),n.getContent()};return{serialize:r}},rh=function(e){for(var t,n=/data:[^;]+;base64,([a-z0-9\+\/=]+)/gi,r=[],o={},i=Ds("img"),a=0,u=0;t=n.exec(e);){var c=t[0],s=i+"_"+u++;o[s]=c,a<t.index&&r.push(e.substr(a,t.index-a)),r.push(s),a=t.index+c.length}return 0===a?{prefix:i,uris:o,html:e}:(a<e.length&&r.push(e.substr(a)),{prefix:i,uris:o,html:r.join("")})},oh=function(e,t){return e.replace(new RegExp(t.prefix+"_[0-9]+","g"),function(e){return Nt(t.uris,e).getOr(e)})},ih=function(e){var t=/data:([^;]+);base64,([a-z0-9\+\/=]+)/i.exec(e);return t?_e.some({type:t[1],data:decodeURIComponent(t[2])}):_e.none()},ah=function(e){return 0===e.indexOf("data-")||0===e.indexOf("aria-")},uh=function(e,t){return!e.allow_html_data_urls&&(/^data:image\//i.test(t)?e.allow_svg_data_urls===!1&&/^data:image\/svg\+xml/i.test(t):/^data:/i.test(t))},ch=function(e,t,n){var r,o,i=1,a=e.getShortEndedElements(),u=/<([!?\/])?([A-Za-z0-9\-_\:\.]+)((?:\s+[^"\'>]+(?:(?:"[^"]*")|(?:\'[^\']*\')|[^>]*))*|\/|\s+)>/g;for(u.lastIndex=r=n;o=u.exec(t);){if(r=u.lastIndex,"/"===o[1])i--;else if(!o[1]){if(o[2]in a)continue;i++}if(0===i)break}return r},sh=function(e,t){return/^\s*\[if [\w\W]+\]>.*<!\[endif\](--!?)?>/.test(e.substr(t))},fh=function(e,t,n){void 0===n&&(n=0);var r=e.toLowerCase();if(r.indexOf("[if ",n)!==-1&&sh(r,n)){var o=r.indexOf("[endif]",n);return r.indexOf(">",o)}if(t){var i=r.indexOf(">",n);return i!==-1?i:r.length}var a=/--!?>/;a.lastIndex=n;var u=a.exec(e);return u?u.index+u[0].length:r.length},lh=function(e,t){var n=e.exec(t);if(n){var r=n[1],o=n[2];return"string"==typeof r&&"data-mce-bogus"===r.toLowerCase()?o:null}return null};!function(e){e.findEndTag=ch}(_||(_={}));var dh,mh=_,ph=function(e,t){var n=new RegExp(["\\s?("+e.join("|")+')="[^"]+"'].join("|"),"gi");return t.replace(n,"")},gh=function(e,t){var n,r,o,i,a=t,u=/<(\w+) [^>]*data-mce-bogus="all"[^>]*>/g,c=e.schema;a=ph(e.getTempAttrs(),a);for(var s=c.getShortEndedElements();i=u.exec(a);)r=u.lastIndex,o=i[0].length,n=s[i[1]]?r:mh.findEndTag(c,a,r),a=a.substring(0,r-o)+a.substring(n),u.lastIndex=r-o;return Vs(a)},hh=gh,vh=function(e,t){var n=Ql(e),r=new RegExp("^(<"+n+"[^>]*>(&nbsp;|&#160;|\\s| |<br \\/>|)<\\/"+n+">[\r\n]*|<br \\/>[\r\n]*)$");return t.replace(r,"")},yh=function(e,t,n,r){var o;if(t.format=n,t.get=!0,t.getInner=!0,t.no_events||e.fire("BeforeGetContent",t),"raw"===t.format)o=er.trim(hh(e.serializer,r.innerHTML));else if("text"===t.format)o=Vs(r.innerText||r.textContent);else{if("tree"===t.format)return e.serializer.serialize(r,t);o=vh(e,e.serializer.serialize(r,t))}return"text"===t.format||Di(ar.fromDom(r))?t.content=o:t.content=er.trim(o),t.no_events||e.fire("GetContent",t),t.content},bh=function(e,t,n){return _e.from(e.getBody()).fold(ve("tree"===t.format?new Zg("body",11):""),function(r){return yh(e,t,n,r)})},Ch=er.each,wh=function(e){this.compare=function(t,n){if(t.nodeName!==n.nodeName)return!1;var r=function(t){var n={};return Ch(e.getAttribs(t),function(r){var o=r.nodeName.toLowerCase();0!==o.indexOf("_")&&"style"!==o&&0!==o.indexOf("data-")&&(n[o]=e.getAttrib(t,o))}),n},o=function(e,t){var n,r;for(r in e)if(e.hasOwnProperty(r)){if(n=t[r],"undefined"==typeof n)return!1;if(e[r]!==n)return!1;delete t[r]}for(r in t)if(t.hasOwnProperty(r))return!1;return!0};return!!o(r(t),r(n))&&(!!o(e.parseStyle(e.getAttrib(t,"style")),e.parseStyle(e.getAttrib(n,"style")))&&(!zp(t)&&!zp(n)))}},xh=function(e,t,n){return _e.from(n.container()).filter(Io).exists(function(r){var o=e?0:-1;return t(r.data.charAt(n.offset()+o))})},Sh=t(xh,!0,Vp),Nh=t(xh,!1,Vp),Eh=function(e){var t=e.container();return Io(t)&&0===t.data.length},kh=function(e,t){return function(n){return _e.from(Am(e?0:-1,n)).filter(t).isSome()}},_h=function(e){return"IMG"===e.nodeName&&"block"===ei(ar.fromDom(e),"display")},Th=function(e){return Ho(e)&&!Oo(e)},Rh=kh(!0,_h),Ah=kh(!1,_h),Dh=kh(!0,Bo),Oh=kh(!1,Bo),Bh=kh(!0,Th),Ph=kh(!1,Th),Lh=function(e,t,n){return vs(e,t,n).isSome()},Ih=function(e,n){var r=ar.fromDom(e),o=ar.fromDom(n);return Lh(o,"pre,code",t(Tr,r))},Mh=function(e,t){return Io(t)&&Bi(t.data)&&Ih(e,t)===!1},Fh=function(e){return ko(e)&&"A"===e.nodeName&&e.hasAttribute("name")},Uh=function(e,t){return Bf(t)&&Mh(e,t)===!1||Fh(t)||zh(t)},zh=Ro("data-mce-bookmark"),jh=Ro("data-mce-bogus"),Hh=Ao("data-mce-bogus","all"),Vh=function(e,t){var n,r=0;if(Uh(e,e))return!1;if(n=e.firstChild,!n)return!0;var o=new qu(n,e);do{if(t){if(Hh(n)){n=o.next(!0);continue}if(jh(n)){n=o.next();continue}}if(zo(n))r++,n=o.next();else{if(Uh(e,n))return!1;n=o.next()}}while(n);return r<=1},qh=function(e,t){return void 0===t&&(t=!0),Vh(e.dom(),t)},$h=function(e){for(var t=[],n=e.dom();n;)t.push(ar.fromDom(n)),n=n.lastChild;return t},Wh=function(e){var t=ps(e,"br"),n=Je($h(e).slice(-1),Ni);t.length===n.length&&Xe(n,co)},Kh=function(e){uo(e),ro(e,ar.fromHtml('<br data-mce-bogus="1">'))},Xh=function(e){Wr(e).each(function(t){Ur(t).each(function(n){wi(e)&&Ni(t)&&wi(n)&&co(t)})})},Yh=function(e){return e.slice(0,-1)},Gh=function(e,t,n){return Dr(t,e)?Yh(Mr(e,function(e){return n(e)||Tr(e,t)})):[]},Jh=function(e,t){return Gh(e,t,ve(!1))},Qh=function(e,t){return[e].concat(Jh(e,t))},Zh=function(e,t,n){var r=Ze(e,function(r,o){return Vp(o)||Hp(o)?r.previousCharIsSpace||""===r.str&&t||r.str.length===e.length-1&&n?{previousCharIsSpace:!1,str:r.str+da}:{previousCharIsSpace:!0,str:r.str+" "}:{previousCharIsSpace:!1,str:r.str+o}},{previousCharIsSpace:!1,str:""});return r.str},ev=function(e,t,n){if(0!==n){var r=e.data.slice(t,t+n),o=t+n>=e.data.length,i=0===t;e.replaceData(t,n,Zh(r,i,o))}},tv=function(e,t){var n=e.data.slice(t),r=n.length-wn(n).length;return ev(e,t,r)},nv=function(e,t){var n=e.data.slice(0,t),r=n.length-xn(n).length;return ev(e,t-r,r)},rv=function(e,t,n){var r=xn(e.data).length;return e.appendData(t.data),co(ar.fromDom(t)),n&&tv(e,r),e},ov=function(e,t){var n=e.container(),r=e.offset();return ul.isTextPosition(e)===!1&&n===t.parentNode&&r>ul.before(t).offset()},iv=function(e,t){return ov(t,e)?ul(t.container(),t.offset()-1):t},av=function(e){return Io(e)?ul(e,0):ul.before(e)},uv=function(e){return Io(e)?ul(e,e.data.length):ul.after(e)},cv=function(e){return Bf(e.previousSibling)?_e.some(uv(e.previousSibling)):e.previousSibling?hp(e.previousSibling):_e.none()},sv=function(e){return Bf(e.nextSibling)?_e.some(av(e.nextSibling)):e.nextSibling?gp(e.nextSibling):_e.none()},fv=function(e,t){var n=ul.before(t.previousSibling?t.previousSibling:t.parentNode);return pp(e,n).fold(function(){return mp(e,ul.after(t))},_e.some)},lv=function(e,t){return mp(e,ul.after(t)).fold(function(){return pp(e,ul.before(t))},_e.some)},dv=function(e,t){return cv(t).orThunk(function(){return sv(t)}).orThunk(function(){return fv(e,t)})},mv=function(e,t){return sv(t).orThunk(function(){return cv(t)}).orThunk(function(){return lv(e,t)})},pv=function(e,t,n){return e?mv(t,n):dv(t,n)},gv=function(e,n,r){return pv(e,n,r).map(t(iv,r))},hv=function(e,t,n){n.fold(function(){e.focus()},function(n){e.selection.setRng(n.toRange(),t)})},vv=function(e){return function(t){return t.dom()===e}},yv=function(e,t){return t&&e.schema.getBlockElements().hasOwnProperty(dr(t))},bv=function(e){if(qh(e)){var t=ar.fromHtml('<br data-mce-bogus="1">');return uo(e),ro(e,t),_e.some(ul.before(t.dom()))}return _e.none()},Cv=function(e,t,n){var r=Ur(e).filter(vr),o=zr(e).filter(vr);return co(e),sf(r,o,t,function(e,t,r){var o=e.dom(),i=t.dom(),a=o.data.length;return rv(o,i,n),r.container()===i?ul(o,a):r}).orThunk(function(){return n&&(r.each(function(e){return nv(e.dom(),e.dom().length)}),o.each(function(e){return tv(e.dom(),0)})),t})},wv=function(e,t){return Et(e.schema.getTextInlineElements(),dr(t))},xv=function(e,n,r,o){void 0===o&&(o=!0);var i=gv(n,e.getBody(),r.dom()),a=gs(r,t(yv,e),vv(e.getBody())),u=Cv(r,i,wv(e,r));e.dom.isEmpty(e.getBody())?(e.setContent(""),e.selection.setCursorLocation()):a.bind(bv).fold(function(){o&&hv(e,n,u)},function(t){o&&hv(e,n,_e.some(t))})},Sv=function(e,t){return{start:e,end:t}},Nv=function(e,t,n){return{rng:e,table:t,cells:n}},Ev=fc.generate([{removeTable:["element"]},{emptyCells:["cells"]},{deleteCellSelection:["rng","cell"]}]),kv=function(e){return function(t){return Tr(e,t)}},_v=function(e,t){return bs(ar.fromDom(e),"td,th",t)},Tv=function(e,t){return vs(e,"table",t)},Rv=function(e){return!Tr(e.start,e.end)},Av=function(e,t){return Tv(e.start,t).bind(function(n){return Tv(e.end,t).bind(function(e){return ff(Tr(n,e),n)})})},Dv=function(e,t){return!Rv(e)&&Av(e,t).exists(function(e){var t=e.dom().rows;return 1===t.length&&1===t[0].cells.length})},Ov=function(e){return ps(e,"td,th")},Bv=function(e,t){var n=_v(e.startContainer,t),r=_v(e.endContainer,t);return cf(n,r,Sv)},Pv=function(e,t){return Tv(e.start,t).bind(function(t){return lt(Ov(t)).map(function(t){return Sv(e.start,t)})})},Lv=function(e,t){var n=_v(t.startContainer,e),r=_v(t.endContainer,e);return t.collapsed?_e.none():cf(n,r,Sv).fold(function(){return n.fold(function(){return r.bind(function(t){return Tv(t,e).bind(function(e){return ft(Ov(e)).map(function(e){return Sv(e,t)})})})},function(t){return Tv(t,e).bind(function(e){return lt(Ov(e)).map(function(e){return Sv(t,e)})})})},function(t){return Iv(e,t)?_e.none():Pv(t,e)})},Iv=function(e,t){return Av(t,e).isSome()},Mv=function(e,t){return Av(e,t).map(function(t){return Nv(e,t,Ov(t))})},Fv=function(e,t,n){return e.filter(function(e){return Rv(e)&&Iv(n,e)}).orThunk(function(){return Lv(n,t)}).bind(function(e){return Mv(e,n)})},Uv=function(e,t){return nt(e,function(e){return Tr(e,t)})},zv=function(e){return cf(Uv(e.cells,e.rng.start),Uv(e.cells,e.rng.end),function(t,n){return e.cells.slice(t,n+1)})},jv=function(e,t,n){return e.filter(function(e){return Dv(e,n)&&Lg(e.start,t)}).map(function(e){return e.start})},Hv=function(e){return zv(e).map(function(t){var n=e.cells;return t.length===n.length?Ev.removeTable(e.table):Ev.emptyCells(t)})},Vv=function(e,t){var n=kv(e),r=Bv(t,n);return jv(r,t,n).map(function(e){return Ev.deleteCellSelection(t,e)}).orThunk(function(){return Fv(r,t,n).bind(Hv)})},qv=function(e){var t=gr(e)?Ur(e):Wr(e);return t.bind(qv).orThunk(function(){return _e.some(e)})},$v=function(e,t){return Xe(t,Kh),e.selection.setCursorLocation(t[0].dom(),0),!0},Wv=function(e,t,n){t.deleteContents();var r=qv(n).getOr(n),o=ar.fromDom(e.dom.getParent(r.dom(),e.dom.isBlock));if(qh(o)&&(Kh(o),e.selection.setCursorLocation(o.dom(),0)),!Tr(n,o)){var i=Ir(o).is(n)?[]:Fr(o);Xe(i.concat(Vr(n)),function(e){Tr(e,o)||Dr(e,o)||co(e)})}return!0},Kv=function(e,t){return xv(e,!1,t),!0},Xv=function(e,n,r){return Vv(n,r).map(function(n){return n.fold(t(Kv,e),t($v,e),t(Wv,e))})},Yv=function(e,t){return ty(e,t)},Gv=function(e,t,n,r){return Zv(t,r).fold(function(){return Xv(e,t,n)},function(t){return Yv(e,t)}).getOr(!1)},Jv=function(e,t){var n=ar.fromDom(e.getBody()),r=e.selection.getRng(),o=Ag(e);return 0!==o.length?$v(e,o):Gv(e,n,r,t)},Qv=function(e,t){return tt(Qh(t,e),Ai)},Zv=function(e,t){return tt(Qh(t,e),function(e){return"caption"===dr(e)})},ey=function(e,t,n,r,o){return fp(n,e.getBody(),o).bind(function(e){return Qv(t,ar.fromDom(e.getNode())).map(function(e){return Tr(e,r)===!1})})},ty=function(e,t){return Kh(t),e.selection.setCursorLocation(t.dom(),0),_e.some(!0)},ny=function(e,t,n,r){return gp(e.dom()).bind(function(o){return hp(e.dom()).map(function(e){return t?n.isEqual(o)&&r.isEqual(e):n.isEqual(e)&&r.isEqual(o)})}).getOr(!0)},ry=function(e,t){return ty(e,t)},oy=function(e,t,n){return Zv(e,ar.fromDom(n.getNode())).map(function(e){return Tr(e,t)===!1})},iy=function(e,t,n,r,o){return fp(n,e.getBody(),o).bind(function(i){return ny(r,n,o,i)?ry(e,r):oy(t,r,i)}).or(_e.some(!0))},ay=function(e,t,n,r){var o=ul.fromRangeStart(e.selection.getRng());return Qv(n,r).bind(function(r){return qh(r)?ty(e,r):ey(e,n,t,r,o)}).getOr(!1)},uy=function(e,t,n,r){var o=ul.fromRangeStart(e.selection.getRng());return qh(r)?ty(e,r):iy(e,n,t,r,o)},cy=function(e,t){return e?Dh(t):Oh(t)},sy=function(e,t){var n=ul.fromRangeStart(e.selection.getRng());return cy(t,n)||sp(t,e.getBody(),n).map(function(e){return cy(t,e)}).getOr(!1)},fy=function(e,t,n){var r=ar.fromDom(e.getBody());return Zv(r,n).fold(function(){return ay(e,t,r,n)||sy(e,t)},function(n){return uy(e,t,r,n).getOr(!1)})},ly=function(e,t){var n=ar.fromDom(e.selection.getStart(!0)),r=Ag(e);return e.selection.isCollapsed()&&0===r.length?fy(e,t,n):Jv(e,n)},dy=function(t,n,r,o){var i=e.document.createRange();return i.setStart(t,n),i.setEnd(r,o),i},my=function(e){var t=ul.fromRangeStart(e),n=ul.fromRangeEnd(e),r=e.commonAncestorContainer;return sp(!1,r,n).map(function(o){return!Rm(t,n,r)&&Rm(t,o,r)?dy(t.container(),t.offset(),o.container(),o.offset()):e}).getOr(e)},py=function(e){return e.collapsed?e:my(e)},gy=function(e){return e.firstChild&&e.firstChild===e.lastChild},hy=function(e){return"br"===e.name||e.value===da},vy=function(e,t){var n=e.getBlockElements();return n[t.name]&&gy(t)&&hy(t.firstChild)},yy=function(e,t){var n=e.getNonEmptyElements();return t&&(t.isEmpty(n)||vy(e,t))},by=function(e,t){var n=t.firstChild,r=t.lastChild;return n&&"meta"===n.name&&(n=n.next),r&&"mce_marker"===r.attr("id")&&(r=r.prev),yy(e,r)&&(r=r.prev),!(!n||n!==r)&&("ul"===n.name||"ol"===n.name)},Cy=function(e){var t=e.firstChild,n=e.lastChild;return t&&"META"===t.nodeName&&t.parentNode.removeChild(t),n&&"mce_marker"===n.id&&n.parentNode.removeChild(n),e},wy=function(e,t,n){var r=t.serialize(n),o=e.createFragment(r);return Cy(o)},xy=function(e){return er.grep(e.childNodes,function(e){return"LI"===e.nodeName})},Sy=function(e){return e.data===da||zo(e)},Ny=function(e){return e&&e.firstChild&&e.firstChild===e.lastChild&&Sy(e.firstChild)},Ey=function(e){return!e.firstChild||Ny(e)},ky=function(e){return e.length>0&&Ey(e[e.length-1])?e.slice(0,-1):e},_y=function(e,t){var n=e.getParent(t,e.isBlock);return n&&"LI"===n.nodeName?n:null},Ty=function(e,t){return!!_y(e,t)},Ry=function(e,t){var n=t.cloneRange(),r=t.cloneRange();return n.setStartBefore(e),r.setEndAfter(e),[n.cloneContents(),r.cloneContents()]},Ay=function(e,t){var n=ul.before(e),r=tp(t),o=r.next(n);return o?o.toRange():null},Dy=function(e,t){var n=ul.after(e),r=tp(t),o=r.prev(n);return o?o.toRange():null},Oy=function(e,t,n,r){var o=Ry(e,r),i=e.parentNode;return i.insertBefore(o[0],e),er.each(t,function(t){i.insertBefore(t,e)}),i.insertBefore(o[1],e),i.removeChild(e),Dy(t[t.length-1],n)},By=function(e,t,n){var r=e.parentNode;return er.each(t,function(t){r.insertBefore(t,e)}),Ay(e,n)},Py=function(e,t,n,r){return r.insertAfter(t.reverse(),e),Dy(t[0],n)},Ly=function(e,t,n,r){var o=wy(t,e,r),i=_y(t,n.startContainer),a=ky(xy(o.firstChild)),u=1,c=2,s=t.getRoot(),f=function(e){var r=ul.fromRangeStart(n),o=tp(t.getRoot()),a=e===u?o.prev(r):o.next(r);return!a||_y(t,a.getNode())!==i};return f(u)?By(i,a,s):f(c)?Py(i,a,s,t):Oy(i,a,s,n)},Iy=function(e,t){return Io(e)&&e.nodeValue[t-1]===da},My=function(e,t){var n=e.startContainer,r=e.startOffset,o=function(e){return n[e]&&3===n[e].nodeType};return Io(n)&&(r>0?t=t.replace(/^&nbsp;/," "):o("previousSibling")||(t=t.replace(/^ /,"&nbsp;")),r<n.length?t=t.replace(/&nbsp;(<br>|)$/," "):o("nextSibling")||(t=t.replace(/(&nbsp;| )(<br>|)$/,"&nbsp;"))),t},Fy=function(e,t){var n=e.startContainer,r=e.startOffset;return Io(n)&&e.collapsed&&(n.data[r]===da?(n.deleteData(r,1),/[\u00a0| ]$/.test(t)||(t+=" ")):n.data[r-1]===da&&(n.deleteData(r-1,1),/[\u00a0| ]$/.test(t)||(t=" "+t))),t},Uy=_o(["td","th"]),zy=function(e,t,n){if(null!==n){var r=e.getParent(t.endContainer,Uy);return n===r&&Lg(ar.fromDom(n),t)}return!1},jy=function(e,t){var n=e.selection.getRng(),r=n.startContainer,o=n.startOffset;n.collapsed&&Iy(r,o)&&Io(r)&&(r.insertData(o-1," "),r.deleteData(o,1),n.setStart(r,o),n.setEnd(r,o),e.selection.setRng(n)),e.selection.setContent(t)},Hy=function(e,t,n){if("all"===n.getAttribute("data-mce-bogus"))n.parentNode.insertBefore(e.dom.createFragment(t),n);else{var r=n.firstChild,o=n.lastChild;!r||r===o&&"BR"===r.nodeName?e.dom.setHTML(n,t):jy(e,t)}},Vy=function(e,t){_e.from(e.getParent(t,"td,th")).map(ar.fromDom).each(Xh)},qy=function(e,t){var n=e.schema.getTextInlineElements(),r=e.dom;if(t){var o=e.getBody(),i=new wh(r);er.each(r.select("*[data-mce-fragment]"),function(e){for(var t=e.parentNode;t&&t!==o;t=t.parentNode)n[e.nodeName.toLowerCase()]&&i.compare(t,e)&&r.remove(e,!0)})}},$y=function(e){for(var t=e;t=t.walk();)1===t.type&&t.attr("data-mce-fragment","1")},Wy=function(e){er.each(e.getElementsByTagName("*"),function(e){e.removeAttribute("data-mce-fragment")})},Ky=function(e){return!!e.getAttribute("data-mce-fragment")},Xy=function(e,t){return t&&!e.schema.getShortEndedElements()[t.nodeName]},Yy=function(e,t){var n,r,o=e.dom,i=e.selection,a=function(t){for(var n=e.getBody();t&&t!==n;t=t.parentNode)if("false"===e.dom.getContentEditable(t))return t;return null};if(t){e.selection.scrollIntoView(t);var u=a(t);if(u)return o.remove(t),void i.select(u);var c=o.createRng(),s=t.previousSibling;s&&3===s.nodeType?(c.setStart(s,s.nodeValue.length),jn.ie||(r=t.nextSibling,r&&3===r.nodeType&&(s.appendData(r.data),r.parentNode.removeChild(r)))):(c.setStartBefore(t),c.setEndBefore(t));var f=function(t){var n=ul.fromRangeStart(t),r=tp(e.getBody());if(n=r.next(n))return n.toRange()},l=o.getParent(t,o.isBlock);o.remove(t),l&&o.isEmpty(l)&&(e.$(l).empty(),c.setStart(l,0),c.setEnd(l,0),Uy(l)||Ky(l)||!(n=f(c))?o.add(l,o.create("br",{"data-mce-bogus":"1"})):(c=n,o.remove(l))),i.setRng(c)}},Gy=function(e){var t=e.dom,n=py(e.selection.getRng());e.selection.setRng(n);var r=t.getParent(n.startContainer,Uy);zy(t,n,r)?Wv(e,n,ar.fromDom(r)):e.getDoc().execCommand("Delete",!1,null)},Jy=function(e,t,n){var r,o,i,a,u,c,s=e.selection,f=e.dom;/^ | $/.test(t)&&(t=My(s.getRng(),t));var l=e.parser,d=n.merge,m=nh({validate:Dd(e)},e.schema),p='<span id="mce_marker" data-mce-type="bookmark">&#xFEFF;&#x200B;</span>';if(i={content:t,format:"html",selection:!0,paste:n.paste},i=e.fire("BeforeSetContent",i),i.isDefaultPrevented())return void e.fire("SetContent",{content:i.content,format:"html",selection:!0,paste:n.paste});t=i.content,t.indexOf("{$caret}")===-1&&(t+="{$caret}"),t=t.replace(/\{\$caret\}/,p),u=s.getRng();var g=u.startContainer||(u.parentElement?u.parentElement():null),h=e.getBody();g===h&&s.isCollapsed()&&f.isBlock(h.firstChild)&&Xy(e,h.firstChild)&&f.isEmpty(h.firstChild)&&(u=f.createRng(),u.setStart(h.firstChild,0),u.setEnd(h.firstChild,0),s.setRng(u)),s.isCollapsed()||(Gy(e),t=Fy(e.selection.getRng(),t)),r=s.getNode();var v={context:r.nodeName.toLowerCase(),data:n.data,insert:!0},y=l.parse(t,v);if(n.paste===!0&&by(e.schema,y)&&Ty(f,r))return u=Ly(m,f,e.selection.getRng(),y),e.selection.setRng(u),void e.fire("SetContent",i);if($y(y),c=y.lastChild,"mce_marker"===c.attr("id"))for(a=c,c=c.prev;c;c=c.walk(!0))if(3===c.type||!f.isBlock(c.name)){e.schema.isValidChild(c.parent.name,"span")&&c.parent.insert(a,c,"br"===c.name);break}if(e._selectionOverrides.showBlockCaretContainer(r),v.invalid){for(jy(e,p),r=s.getNode(),o=e.getBody(),9===r.nodeType?r=c=o:c=r;c!==o;)r=c,c=c.parentNode;t=r===o?o.innerHTML:f.getOuterHTML(r),t=m.serialize(l.parse(t.replace(/<span (id="mce_marker"|id=mce_marker).+?<\/span>/i,function(){return m.serialize(y)}))),r===o?f.setHTML(o,t):f.setOuterHTML(r,t)}else t=m.serialize(y),Hy(e,t,r);qy(e,d),Yy(e,f.get("mce_marker")),Wy(e.getBody()),Vy(e.dom,e.selection.getStart()),e.fire("SetContent",i),e.addVisual()},Qy=function(){return ar.fromDom(e.document)},Zy=function(e){return e.dom().focus()},eb=function(e){var t=Gr(e).dom();return e.dom()===t.activeElement},tb=function(e){return void 0===e&&(e=Qy()),_e.from(e.dom().activeElement).map(ar.fromDom)},nb=function(e){return tb(Gr(e)).filter(function(t){return e.dom().contains(t.dom())})},rb=function(e,t,n,r){return{start:ve(e),soffset:ve(t),finish:ve(n),foffset:ve(r)}},ob={create:rb},ib=fc.generate([{before:["element"]},{on:["element","offset"]},{after:["element"]}]),ab=function(e,t,n,r){return e.fold(t,n,r)},ub=function(e){return e.fold(ye,ye,ye)},cb=ib.before,sb=ib.on,fb=ib.after,lb={before:cb,on:sb,after:fb,cata:ab,getStart:ub},db=fc.generate([{domRange:["rng"]},{relative:["startSitu","finishSitu"]},{exact:["start","soffset","finish","foffset"]}]),mb=function(e){return db.exact(e.start(),e.soffset(),e.finish(),e.foffset())},pb=function(e){return e.match({domRange:function(e){return ar.fromDom(e.startContainer)},relative:function(e,t){return lb.getStart(e)},exact:function(e,t,n,r){return e}})},gb=db.domRange,hb=db.relative,vb=db.exact,yb=function(e){var t=pb(e);return Lr(t)},bb=ob.create,Cb={domRange:gb,relative:hb,exact:vb,exactFromRange:mb,getWin:yb,range:bb},wb=On().browser,xb=function(e,t){var n=vr(t)?jg(t).length:Vr(t).length+1;return e>n?n:e<0?0:e},Sb=function(e){return Cb.range(e.start(),xb(e.soffset(),e.start()),e.finish(),xb(e.foffset(),e.finish()))},Nb=function(e,t){return!Eo(t.dom())&&(Dr(e,t)||Tr(e,t))},Eb=function(e){return function(t){return Nb(e,t.start())&&Nb(e,t.finish())}},kb=function(e){return e.inline===!0||wb.isIE()},_b=function(e){return Cb.range(ar.fromDom(e.startContainer),e.startOffset,ar.fromDom(e.endContainer),e.endOffset)},Tb=function(e){var t=e.getSelection(),n=t&&0!==t.rangeCount?_e.from(t.getRangeAt(0)):_e.none();return n.map(_b)},Rb=function(e){var t=Lr(e);return Tb(t.dom()).filter(Eb(e))},Ab=function(e,t){return _e.from(t).filter(Eb(e)).map(Sb)},Db=function(t){var n=e.document.createRange();try{return n.setStart(t.start().dom(),t.soffset()),n.setEnd(t.finish().dom(),t.foffset()),_e.some(n)}catch(r){return _e.none()}},Ob=function(e){var t=kb(e)?Rb(ar.fromDom(e.getBody())):_e.none();e.bookmark=t.isSome()?t:e.bookmark},Bb=function(e,t){var n=ar.fromDom(e.getBody()),r=kb(e)?_e.from(t):_e.none(),o=r.map(_b).filter(Eb(n));e.bookmark=o.isSome()?o:e.bookmark},Pb=function(e){var t=e.bookmark?e.bookmark:_e.none();return t.bind(function(t){return Ab(ar.fromDom(e.getBody()),t)}).bind(Db)},Lb=function(e){Pb(e).each(function(t){e.selection.setRng(t)})},Ib=function(e){var t=e.className.toString();return t.indexOf("tox-")!==-1||t.indexOf("mce-")!==-1},Mb={isEditorUIElement:Ib},Fb=function(e){return"nodechange"===e.type&&e.selectionChange},Ub=function(t,n){var r=function(){n.throttle()};Ac.DOM.bind(e.document,"mouseup",r),t.on("remove",function(){Ac.DOM.unbind(e.document,"mouseup",r)})},zb=function(e){e.on("focusout",function(){Ob(e)})},jb=function(e,t){e.on("mouseup touchend",function(e){t.throttle()})},Hb=function(e,t){var n=On().browser;n.isIE()?zb(e):jb(e,t),e.on("keyup NodeChange",function(t){Fb(t)||Ob(e)})},Vb=function(e){var t=es(function(){Ob(e)},0);e.on("init",function(){e.inline&&Ub(e,t),Hb(e,t)}),e.on("remove",function(){t.cancel()})},qb=Ac.DOM,$b=function(e){return Mb.isEditorUIElement(e)},Wb=function(e){var t=e.classList;return void 0!==t&&(t.contains("tox-edit-area")||t.contains("tox-edit-area__iframe")||t.contains("mce-content-body"))},Kb=function(e,t){var n=Ld(e),r=qb.getParent(t,function(t){return $b(t)||!!n&&e.dom.is(t,n)});return null!==r},Xb=function(){try{return e.document.activeElement}catch(t){return e.document.body}},Yb=function(t,n){var r=n.editor;Vb(r),r.on("focusin",function(){var e=this,n=t.focusedEditor;n!==e&&(n&&n.fire("blur",{focusedEditor:e}),t.setActive(e),t.focusedEditor=e,e.fire("focus",{blurredEditor:n}),e.focus(!0))}),r.on("focusout",function(){var e=this;Cc.setEditorTimeout(e,function(){var n=t.focusedEditor;Kb(e,Xb())||n!==e||(e.fire("blur",{focusedEditor:null}),t.focusedEditor=null)})}),dh||(dh=function(n){var r=t.activeEditor,o=n.target;r&&o.ownerDocument===e.document&&(o===e.document.body||Kb(r,o)||t.focusedEditor!==r||(r.fire("blur",{focusedEditor:null}),t.focusedEditor=null))},qb.bind(e.document,"focusin",dh))},Gb=function(t,n){t.focusedEditor===n.editor&&(t.focusedEditor=null),t.activeEditor||(qb.unbind(e.document,"focusin",dh),dh=null)},Jb=function(e){e.on("AddEditor",t(Yb,e)),e.on("RemoveEditor",t(Gb,e))},Qb=function(e,t){return e.dom.getParent(t,function(t){return"true"===e.dom.getContentEditable(t)})},Zb=function(e){return e.collapsed?_e.from(Cf(e.startContainer,e.startOffset)).map(ar.fromDom):_e.none()},eC=function(e,t){return Zb(t).bind(function(t){return Ri(t)?_e.some(t):Dr(e,t)===!1?_e.some(e):_e.none();
})},tC=function(e,t){eC(ar.fromDom(e.getBody()),t).bind(function(e){return gp(e.dom())}).fold(function(){e.selection.normalize()},function(t){return e.selection.setRng(t.toRange())})},nC=function(e){if(e.setActive)try{e.setActive()}catch(t){e.focus()}else e.focus()},rC=function(e){return eb(e)||nb(e).isSome()},oC=function(e){return e.iframeElement&&eb(ar.fromDom(e.iframeElement))},iC=function(e){var t=e.getBody();return t&&rC(ar.fromDom(t))},aC=function(e){return tb().filter(function(t){return!Wb(t.dom())&&Kb(e,t.dom())}).isSome()},uC=function(e){return e.inline?iC(e):oC(e)},cC=function(e){return uC(e)||aC(e)},sC=function(e){var t=e.selection,n=e.getBody(),r=t.getRng();e.quirks.refreshContentEditable(),void 0!==e.bookmark&&uC(e)===!1&&Pb(e).each(function(t){e.selection.setRng(t),r=t});var o=Qb(e,t.getNode());return e.$.contains(n,o)?(nC(o),tC(e,r),void fC(e)):(e.inline||(jn.opera||nC(n),e.getWin().focus()),(jn.gecko||e.inline)&&(nC(n),tC(e,r)),void fC(e))},fC=function(e){return e.editorManager.setActive(e)},lC=function(e,t){e.removed||(t?fC(e):sC(e))},dC=function(e,t){t(e),e.firstChild&&dC(e.firstChild,t),e.next&&dC(e.next,t)},mC=function(e,t,n){var r={},o={},i=[];n.firstChild&&dC(n.firstChild,function(n){Xe(e,function(e){e.name===n.name&&(r[e.name]?r[e.name].nodes.push(n):r[e.name]={filter:e,nodes:[n]})}),Xe(t,function(e){"string"==typeof n.attr(e.name)&&(o[e.name]?o[e.name].nodes.push(n):o[e.name]={filter:e,nodes:[n]})})});for(var a in r)r.hasOwnProperty(a)&&i.push(r[a]);for(var u in o)o.hasOwnProperty(u)&&i.push(o[u]);return i},pC=function(e,t,n){var r=mC(e,t,n);Xe(r,function(e){Xe(e.filter.callbacks,function(t){t(e.nodes,e.filter.name,{})})})},gC="html",hC=function(e){return e instanceof Zg},vC=function(e){uC(e)&&gp(e.getBody()).each(function(t){var n=t.getNode(),r=Bo(n)?gp(n).getOr(t):t;e.selection.setRng(r.toRange())})},yC=function(e,t){e.dom.setHTML(e.getBody(),t),vC(e)},bC=function(e,t,n,r){var o,i;return 0===n.length||/^\s+$/.test(n)?(i='<br data-mce-bogus="1">',"TABLE"===t.nodeName?n="<tr><td>"+i+"</td></tr>":/^(UL|OL)$/.test(t.nodeName)&&(n="<li>"+i+"</li>"),o=Ql(e),o&&e.schema.isValidChild(t.nodeName.toLowerCase(),o.toLowerCase())?(n=i,n=e.dom.createHTML(o,Zl(e),n)):n||(n='<br data-mce-bogus="1">'),yC(e,n),e.fire("SetContent",r)):("raw"!==r.format&&(n=nh({validate:e.validate},e.schema).serialize(e.parser.parse(n,{isRootContent:!0,insert:!0}))),r.content=Di(ar.fromDom(t))?n:er.trim(n),yC(e,r.content),r.no_events||e.fire("SetContent",r)),r.content},CC=function(e,t,n,r){pC(e.parser.getNodeFilters(),e.parser.getAttributeFilters(),n);var o=nh({validate:e.validate},e.schema).serialize(n);return r.content=Di(ar.fromDom(t))?o:er.trim(o),yC(e,r.content),r.no_events||e.fire("SetContent",r),n},wC=function(e,t,n){return n.format=n.format?n.format:gC,n.set=!0,n.content=hC(t)?"":t,hC(t)||n.no_events||(e.fire("BeforeSetContent",n),t=n.content),_e.from(e.getBody()).fold(ve(t),function(r){return hC(t)?CC(e,r,t,n):bC(e,r,t,n)})},xC=function(e,t){return e.splitText(t)},SC=function(e){var t=e.startContainer,n=e.startOffset,r=e.endContainer,o=e.endOffset;return t===r&&Io(t)?n>0&&n<t.nodeValue.length&&(r=xC(t,n),t=r.previousSibling,o>n?(o-=n,t=r=xC(r,o).previousSibling,o=r.nodeValue.length,n=0):o=0):(Io(t)&&n>0&&n<t.nodeValue.length&&(t=xC(t,n),n=0),Io(r)&&o>0&&o<r.nodeValue.length&&(r=xC(r,o).previousSibling,o=r.nodeValue.length)),{startContainer:t,startOffset:n,endContainer:r,endOffset:o}},NC=eg,EC=function(e,t,n){var r=e.formatter.get(n);if(r)for(var o=0;o<r.length;o++)if(r[o].inherit===!1&&e.dom.is(t,r[o].selector))return!0;return!1},kC=function(e,t,n,r){var o=e.dom.getRoot();return t!==o&&(t=e.dom.getParent(t,function(t){return!!EC(e,t,n)||(t.parentNode===o||!!RC(e,t,n,r,!0))}),RC(e,t,n,r))},_C=function(e,t,n){return!!NC(t,n.inline)||(!!NC(t,n.block)||(n.selector?1===t.nodeType&&e.is(t,n.selector):void 0))},TC=function(e,t,n,r,o,i){var a,u,c,s=n[r];if(n.onmatch)return n.onmatch(t,n,r);if(s)if("undefined"==typeof s.length){for(a in s)if(s.hasOwnProperty(a)){if(u="attributes"===r?e.getAttrib(t,a):ng(e,t,a),o&&!u&&!n.exact)return;if((!o||n.exact)&&!NC(u,tg(e,Zp(s[a],i),a)))return}}else for(c=0;c<s.length;c++)if("attributes"===r?e.getAttrib(t,s[c]):ng(e,t,s[c]))return n;return n},RC=function(e,t,n,r,o){var i,a,u,c,s=e.formatter.get(n),f=e.dom;if(s&&t)for(a=0;a<s.length;a++)if(i=s[a],_C(e.dom,t,i)&&TC(f,t,i,"attributes",o,r)&&TC(f,t,i,"styles",o,r)){if(c=i.classes)for(u=0;u<c.length;u++)if(!e.dom.hasClass(t,c[u]))return;return i}},AC=function(e,t,n,r){if(r)return kC(e,r,t,n);if(r=e.selection.getNode(),kC(e,r,t,n))return!0;var o=e.selection.getStart();return!(o===r||!kC(e,o,t,n))},DC=function(e,t,n){var r=[],o={},i=e.selection.getStart();return e.dom.getParent(i,function(i){for(var a=0;a<t.length;a++){var u=t[a];!o[u]&&RC(e,i,u,n)&&(o[u]=!0,r.push(u))}},e.dom.getRoot()),r},OC=function(e,t){var n,r,o,i,a,u=e.formatter.get(t),c=e.dom;if(u)for(n=e.selection.getStart(),r=og(c,n),i=u.length-1;i>=0;i--){if(a=u[i].selector,!a||u[i].defaultBlock)return!0;for(o=r.length-1;o>=0;o--)if(c.is(r[o],a))return!0}return!1},BC=function(e,t,n){return Ze(n,function(n,r){var o=ig(e,r);return e.formatter.matchNode(t,r,{},o)?n.concat([r]):n},[])},PC=js,LC="_mce_caret",IC=function(e,t){return e.importNode(t,!0)},MC=function(e){for(var t=[];e;){if(3===e.nodeType&&e.nodeValue!==PC||e.childNodes.length>1)return[];1===e.nodeType&&t.push(e),e=e.firstChild}return t},FC=function(e){return MC(e).length>0},UC=function(e){if(e){var t=new qu(e,e);for(e=t.current();e;e=t.next())if(Io(e))return e}return null},zC=function(e){var t=ar.fromTag("span");return Wo(t,{id:LC,"data-mce-bogus":"1","data-mce-type":"format-caret"}),e&&ro(t,ar.fromText(PC)),t},jC=function(e){var t=UC(e);return t&&t.nodeValue.charAt(0)===PC&&t.deleteData(0,1),t},HC=function(e,t,n){void 0===n&&(n=!0);var r=e.dom,o=e.selection;if(FC(t))xv(e,!1,ar.fromDom(t),n);else{var i=o.getRng(),a=r.getParent(t,r.isBlock),u=i.startContainer,c=i.startOffset,s=i.endContainer,f=i.endOffset,l=jC(t);r.remove(t,!0),u===l&&c>0&&i.setStart(l,c-1),s===l&&f>0&&i.setEnd(l,f-1),a&&r.isEmpty(a)&&Kh(ar.fromDom(a)),o.setRng(i)}},VC=function(e,t,n){void 0===n&&(n=!0);var r=e.dom,o=e.selection;if(t)HC(e,t,n);else if(t=bp(e.getBody(),o.getStart()),!t)for(;t=r.get(LC);)HC(e,t,!1)},qC=function(e,n,r){var o=e.dom,i=o.getParent(r,t(Yp,e));i&&o.isEmpty(i)?r.parentNode.replaceChild(n,r):(Wh(ar.fromDom(r)),o.isEmpty(r)?r.parentNode.replaceChild(n,r):o.insertAfter(n,r))},$C=function(e,t){return e.appendChild(t),t},WC=function(e,t){var n=Qe(e,function(e,t){return $C(e,t.cloneNode(!1))},t);return $C(n,n.ownerDocument.createTextNode(PC))},KC=function(e,t,n,r,o,i){var a=e.formatter,u=e.dom,c=Je(mt(a.get()),function(e){return e!==r&&!vn(e,"removeformat")}),s=BC(e,n,c),f=Je(s,function(t){return!ag(e,t,r)});if(f.length>0){var l=n.cloneNode(!1);return u.add(t,l),a.remove(r,o,l,i),u.remove(l),_e.some(l)}return _e.none()},XC=function(e,t,n){var r,o,i=e.selection,a=i.getRng(),u=a.startOffset,c=a.startContainer,s=c.nodeValue;r=bp(e.getBody(),i.getStart()),r&&(o=UC(r));var f=/[^\s\u00a0\u00ad\u200b\ufeff]/;if(s&&u>0&&u<s.length&&f.test(s.charAt(u))&&f.test(s.charAt(u-1))){var l=i.getBookmark();a.collapse(!0);var d=Cg(e,a,e.formatter.get(t));d=SC(d),e.formatter.apply(t,n,d),i.moveToBookmark(l)}else r&&o.nodeValue===PC?e.formatter.apply(t,n,r):(r=IC(e.getDoc(),zC(!0).dom()),o=r.firstChild,a.insertNode(r),u=1,e.formatter.apply(t,n,r)),i.setCursorLocation(o,u)},YC=function(e,t,n,r){var o,i,a,u=e.dom,c=e.selection,s=[],f=c.getRng(),l=f.startContainer,d=f.startOffset;for(i=l,3===l.nodeType&&(d!==l.nodeValue.length&&(o=!0),i=i.parentNode);i;){if(RC(e,i,t,n,r)){a=i;break}i.nextSibling&&(o=!0),s.push(i),i=i.parentNode}if(a)if(o){var m=c.getBookmark();f.collapse(!0);var p=Cg(e,f,e.formatter.get(t),!0);p=SC(p),e.formatter.remove(t,n,p,r),c.moveToBookmark(m)}else{var g=bp(e.getBody(),a),h=zC(!1).dom();qC(e,h,null!==g?g:a);var v=KC(e,h,a,t,n,r),y=WC(s.concat(v.toArray()),h);HC(e,g,!1),c.setCursorLocation(y,1),u.isEmpty(a)&&u.remove(a)}},GC=function(e,t){var n=e.selection,r=e.getBody();VC(e,null,!1),8!==t&&46!==t||!n.isCollapsed()||n.getStart().innerHTML!==PC||VC(e,bp(r,n.getStart())),37!==t&&39!==t||VC(e,bp(r,n.getStart()))},JC=function(e){e.on("mouseup keydown",function(t){GC(e,t.keyCode)})},QC=function(e,t){var n=zC(!1),r=WC(t,n.dom());return eo(ar.fromDom(e),n),co(ar.fromDom(e)),ul(r,0)},ZC=function(e,t){var n=e.schema.getTextInlineElements();return n.hasOwnProperty(dr(t))&&!yp(t.dom())&&!Do(t.dom())},ew=function(e){return yp(e.dom())&&FC(e.dom())},tw={},nw=Dt,rw=Rt,ow=function(e,t){var n=tw[e];n||(tw[e]=[]),tw[e].push(t)},iw=function(e,t){rw(tw[e],function(e){e(t)})};ow("pre",function(e){var t,n=e.selection.getRng(),r=function(e){return i(e.previousSibling)&&Ot(t,e.previousSibling)!==-1},o=function(e,t){Vu(t).remove(),Vu(e).append("<br><br>").append(t.childNodes)},i=_o(["pre"]);n.collapsed||(t=e.selection.getSelectedBlocks(),rw(nw(nw(t,i),r),function(e){o(e.previousSibling,e)}))});var aw=er.each,uw=function(e){return ko(e)&&!zp(e)&&!yp(e)&&!Do(e)},cw=function(e,t){var n;for(n=e;n;n=n[t]){if(Io(n)&&0!==n.nodeValue.length)return e;if(ko(n)&&!zp(n))return n}return e},sw=function(e,t,n){var r,o,i=new wh(e);if(t&&n&&(t=cw(t,"previousSibling"),n=cw(n,"nextSibling"),i.compare(t,n))){for(r=t.nextSibling;r&&r!==n;)o=r,r=r.nextSibling,t.appendChild(o);return e.remove(n),er.each(er.grep(n.childNodes),function(e){t.appendChild(e)}),t}return n},fw=function(e,t,n,r){if(r&&t.merge_siblings!==!1){var o=sw(e,Xp(r),r);sw(e,o,Xp(o,!0))}},lw=function(e,t,n){if(t.clear_child_styles){var r=t.links?"*:not(a)":"*";aw(e.select(r,n),function(n){uw(n)&&aw(t.styles,function(t,r){e.setStyle(n,r,"")})})}},dw=function(e,t,n){aw(e.childNodes,function(e){uw(e)&&(t(e)&&n(e),e.hasChildNodes()&&dw(e,t,n))})},mw=function(e,t){"SPAN"===t.nodeName&&0===e.getAttribs(t).length&&e.remove(t,!0)},pw=function(e,t){return function(n){return!(!n||!ng(e,n,t))}},gw=function(e,t,n){return function(r){e.setStyle(r,t,n),""===r.getAttribute("style")&&r.removeAttribute("style"),mw(e,r)}},hw=fc.generate([{keep:[]},{rename:["name"]},{removed:[]}]),vw=/^(src|href|style)$/,yw=er.each,bw=eg,Cw=function(e){return/^(TR|TH|TD)$/.test(e.nodeName)},ww=function(e,t,n){return e.isChildOf(t,n)&&t!==n&&!e.isBlock(n)},xw=function(e,t,n){var r,o;if(r=t[n?"startContainer":"endContainer"],o=t[n?"startOffset":"endOffset"],ko(r)){var i=r.childNodes.length-1;!n&&o&&o--,r=r.childNodes[o>i?i:o]}return Io(r)&&n&&o>=r.nodeValue.length&&(r=new qu(r,e.getBody()).next()||r),Io(r)&&!n&&0===o&&(r=new qu(r,e.getBody()).prev()||r),r},Sw=function(e,t){var n=t?"firstChild":"lastChild";if(Cw(e)&&e[n]){var r=e[n];return"TR"===e.nodeName?r[n]||r:r}return e},Nw=function(e,t,n,r){var o=e.create(n,r);return t.parentNode.insertBefore(o,t),o.appendChild(t),o},Ew=function(e,t,n,r,o){var i=ar.fromDom(t),a=ar.fromDom(e.create(r,o)),u=n?Hr(i):jr(i);return ao(a,u),n?(eo(i,a),no(a,i)):(to(i,a),ro(a,i)),a.dom()},kw=function(e,t,n){return!!bw(t,n.inline)||(!!bw(t,n.block)||(n.selector?ko(t)&&e.is(t,n.selector):void 0))},_w=function(e,t){return t.links&&"A"===e.nodeName},Tw=function(e,t,n,r){return t=Xp(t,n,r),!t||"BR"===t.nodeName||e.isBlock(t)},Rw=function(e,t,n){var r,o=t.parentNode,i=e.dom,a=Ql(e);n.block&&(a?o===i.getRoot()&&(n.list_block&&bw(t,n.list_block)||Xe(dt(t.childNodes),function(t){Gp(e,a,t.nodeName.toLowerCase())?r?r.appendChild(t):(r=Nw(i,t,a),i.setAttribs(r,e.settings.forced_root_block_attrs)):r=0})):i.isBlock(t)&&!i.isBlock(o)&&(Tw(i,t,!1)||Tw(i,t.firstChild,!0,!0)||t.insertBefore(i.create("br"),t.firstChild),Tw(i,t,!0)||Tw(i,t.lastChild,!1,!0)||t.appendChild(i.create("br")))),n.selector&&n.inline&&!bw(n.inline,t)||i.remove(t,!0)},Aw=function(e,t,n,r,o){var i,a=e.dom;if(!kw(a,r,t)&&!_w(r,t))return hw.keep();var u=r;if(t.inline&&"all"===t.remove&&Pe(t.preserve_attributes)){var c=Je(a.getAttribs(u),function(e){return $e(t.preserve_attributes,e.name.toLowerCase())});if(a.removeAllAttribs(u),Xe(c,function(e){return a.setAttrib(u,e.name,e.value)}),c.length>0)return hw.rename("span")}if("all"!==t.remove){yw(t.styles,function(e,r){e=tg(a,Zp(e,n),r),"number"==typeof r&&(r=e,o=null),(t.remove_similar||!o||bw(ng(a,o,r),e))&&a.setStyle(u,r,""),i=!0}),i&&""===a.getAttrib(u,"style")&&(u.removeAttribute("style"),u.removeAttribute("data-mce-style")),yw(t.attributes,function(e,r){var i;if(e=Zp(e,n),"number"==typeof r&&(r=e,o=null),t.remove_similar||!o||bw(a.getAttrib(o,r),e)){if("class"===r&&(e=a.getAttrib(u,r),e&&(i="",Xe(e.split(/\s+/),function(e){/mce\-\w+/.test(e)&&(i+=(i?" ":"")+e)}),i)))return void a.setAttrib(u,r,i);"class"===r&&u.removeAttribute("className"),vw.test(r)&&u.removeAttribute("data-mce-"+r),u.removeAttribute(r)}}),yw(t.classes,function(e){e=Zp(e,n),o&&!a.hasClass(o,e)||a.removeClass(u,e)});for(var s=a.getAttribs(u),f=0;f<s.length;f++){var l=s[f].nodeName;if(0!==l.indexOf("_")&&0!==l.indexOf("data-"))return hw.keep()}}return"none"!==t.remove?(Rw(e,u,t),hw.removed()):hw.keep()},Dw=function(e,t,n,r,o){return Aw(e,t,n,r,o).fold(we,function(t){return e.dom.rename(r,t),!0},xe)},Ow=function(e,t,n,r,o){var i;return Xe(og(e.dom,t.parentNode).reverse(),function(t){if(!i&&"_start"!==t.id&&"_end"!==t.id){var a=RC(e,t,n,r,o);a&&a.split!==!1&&(i=t)}}),i},Bw=function(e,t,n,r){return Aw(e,t,n,r,r).fold(ve(r),function(t){var n=e.dom.createFragment();return n.appendChild(r),e.dom.rename(r,t)},ve(null))},Pw=function(e,t,n,r,o,i,a,u){var c,s,f,l=e.dom;if(n){for(var d=n.parentNode,m=r.parentNode;m&&m!==d;m=m.parentNode){c=l.clone(m,!1);for(var p=0;p<t.length&&(c=Bw(e,t[p],u,c),null!==c);p++);c&&(s&&c.appendChild(s),f||(f=c),s=c)}!i||a.mixed&&l.isBlock(n)||(r=l.split(n,r)),s&&(o.parentNode.insertBefore(s,o),f.appendChild(o),a.inline&&fw(l,a,u,s))}return r},Lw=function(e,t,n,r,o){var i=e.formatter.get(t),a=i[0],u=!0,c=e.dom,s=e.selection,f=function(r){var u=Ow(e,r,t,n,o);return Pw(e,i,u,r,r,!0,a,n)},l=function(e){return zp(e)&&ko(e)&&("_start"===e.id||"_end"===e.id)},d=function(t){var r,o;ko(t)&&c.getContentEditable(t)&&(r=u,u="true"===c.getContentEditable(t),o=!0);var s=dt(t.childNodes);if(u&&!o)for(var f=0;f<i.length&&!Dw(e,i[f],n,t,t);f++);if(a.deep&&s.length){for(var f=0;f<s.length;f++)d(s[f]);o&&(u=r)}},m=function(e){var t=c.get(e?"_start":"_end"),n=t[e?"firstChild":"lastChild"];return l(n)&&(n=n[e?"firstChild":"lastChild"]),Io(n)&&0===n.data.length&&(n=e?t.previousSibling||t.nextSibling:t.nextSibling||t.previousSibling),c.remove(t,!0),n},p=function(t){var n,r,o=Cg(e,t,i,!0);if(a.split){if(o=SC(o),n=xw(e,o,!0),r=xw(e,o),n!==r){if(n=Sw(n,!0),r=Sw(r,!1),ww(c,n,r)){var u=_e.from(n.firstChild).getOr(n);return f(Ew(c,u,!0,"span",{id:"_start","data-mce-type":"bookmark"})),void m(!0)}if(ww(c,r,n)){var u=_e.from(r.lastChild).getOr(r);return f(Ew(c,u,!1,"span",{id:"_end","data-mce-type":"bookmark"})),void m(!1)}n=Nw(c,n,"span",{id:"_start","data-mce-type":"bookmark"}),r=Nw(c,r,"span",{id:"_end","data-mce-type":"bookmark"});var s=c.createRng();s.setStartAfter(n),s.setEndBefore(r),Sg(c,s,function(e){Xe(e,function(e){zp(e)||zp(e.parentNode)||f(e)})}),f(n),f(r),n=m(!0),r=m()}else n=r=f(n);o.startContainer=n.parentNode?n.parentNode:n,o.startOffset=c.nodeIndex(n),o.endContainer=r.parentNode?r.parentNode:r,o.endOffset=c.nodeIndex(r)+1}Sg(c,o,function(t){Xe(t,function(t){d(t);var n=["underline","line-through","overline"];Xe(n,function(n){ko(t)&&e.dom.getStyle(t,"text-decoration")===n&&t.parentNode&&rg(c,t.parentNode)===n&&Dw(e,{deep:!1,exact:!0,inline:"span",styles:{textDecoration:n}},null,t)})})})};if(r)if($p(r)){var g=c.createRng();g.setStartBefore(r),g.setEndAfter(r),p(g)}else p(r);else if("false"!==c.getContentEditable(s.getNode()))s.isCollapsed()&&a.inline&&!Ag(e).length?YC(e,t,n,o):(Ug(s,!0,function(){Fg(e,p)}),a.inline&&AC(e,t,n,s.getStart())&&Kp(c,s,s.getRng()),e.nodeChanged());else{r=s.getNode();for(var h=0;h<i.length&&(!i[h].ceFalseOverride||!Dw(e,i[h],n,r,r));h++);}},Iw=er.each,Mw=function(e,t,n,r){var o=function(t){if(1===t.nodeType&&t.parentNode&&1===t.parentNode.nodeType){var n=rg(e,t.parentNode);e.getStyle(t,"color")&&n?e.setStyle(t,"text-decoration",n):e.getStyle(t,"text-decoration")===n&&e.setStyle(t,"text-decoration",null)}};t.styles&&(t.styles.color||t.styles.textDecoration)&&(er.walk(r,o,"childNodes"),o(r))},Fw=function(e,t,n,r){t.styles&&t.styles.backgroundColor&&dw(r,pw(e,"fontSize"),gw(e,"backgroundColor",Zp(t.styles.backgroundColor,n)))},Uw=function(e,t,n,r){"sub"!==t.inline&&"sup"!==t.inline||(dw(r,pw(e,"fontSize"),gw(e,"fontSize","")),e.remove(e.select("sup"===t.inline?"sub":"sup",r),!0))},zw=function(e,t,n,r){Iw(t,function(t){Iw(e.dom.select(t.inline,r),function(r){uw(r)&&Dw(e,t,n,r,t.exact?r:null)}),lw(e.dom,t,r)})},jw=function(e,t,n,r,o){RC(e,o.parentNode,n,r)&&Dw(e,t,r,o)||t.merge_with_parents&&e.dom.getParent(o.parentNode,function(i){if(RC(e,i,n,r))return Dw(e,t,r,o),!0})},Hw=er.each,Vw=function(e){return e&&1===e.nodeType&&!zp(e)&&!yp(e)&&!Do(e)},qw=function(e,t,n,r){var o,i=e.formatter.get(t),a=i[0],u=!r&&e.selection.isCollapsed(),c=e.dom,s=e.selection,f=function(e,t){if(t=t||a,e){if(t.onformat&&t.onformat(e,t,n,r),Hw(t.styles,function(t,r){c.setStyle(e,r,Zp(t,n))}),t.styles){var o=c.getAttrib(e,"style");o&&c.setAttrib(e,"data-mce-style",o)}Hw(t.attributes,function(t,r){c.setAttrib(e,r,Zp(t,n))}),Hw(t.classes,function(t){t=Zp(t,n),c.hasClass(e,t)||c.addClass(e,t)})}},l=function(e,t){var n=!1;return!!a.selector&&(Hw(e,function(e){if(!("collapsed"in e&&e.collapsed!==u))return c.is(t,e.selector)&&!yp(t)?(f(t,e),n=!0,!1):void 0}),n)},d=function(r,o,u,c){var s=[],d=!0,m=a.inline||a.block,p=r.create(m);f(p),Sg(r,o,function(o){var u,g=function(o){var h=!1,v=d,y=o.nodeName.toLowerCase(),b=o.parentNode.nodeName.toLowerCase();if(ko(o)&&r.getContentEditable(o)&&(v=d,d="true"===r.getContentEditable(o),h=!0),eg(y,"br"))return u=0,void(a.block&&r.remove(o));if(a.wrapper&&RC(e,o,t,n))return void(u=0);if(d&&!h&&a.block&&!a.wrapper&&Yp(e,y)&&Gp(e,b,m))return o=r.rename(o,m),f(o),s.push(o),void(u=0);if(a.selector){var C=l(i,o);if(!a.inline||C)return void(u=0)}!d||h||!Gp(e,m,y)||!Gp(e,b,m)||!c&&3===o.nodeType&&1===o.nodeValue.length&&65279===o.nodeValue.charCodeAt(0)||yp(o)||a.inline&&r.isBlock(o)?(u=0,Hw(er.grep(o.childNodes),g),h&&(d=v),u=0):(u||(u=r.clone(p,!1),o.parentNode.insertBefore(u,o),s.push(u)),u.appendChild(o))};Hw(o,g)}),a.links===!0&&Hw(s,function(e){var t=function(e){"A"===e.nodeName&&f(e,a),Hw(er.grep(e.childNodes),t)};t(e)}),Hw(s,function(o){var u=function(e){var t=0;return Hw(e.childNodes,function(e){Qp(e)||zp(e)||t++}),t},c=function(e){var t=!1;return Hw(e.childNodes,function(e){if(Vw(e))return t=e,!1}),t},l=function(e){var t,n=c(e);return n&&!zp(n)&&_C(r,n,a)&&(t=r.clone(n,!1),f(t),r.replace(t,e,!0),r.remove(n,!0)),t||e},d=u(o);return(s.length>1||!r.isBlock(o))&&0===d?void r.remove(o,!0):void((a.inline||a.wrapper)&&(a.exact||1!==d||(o=l(o)),zw(e,i,n,o),jw(e,a,t,n,o),Fw(r,a,n,o),Mw(r,a,n,o),Uw(r,a,n,o),fw(r,a,n,o)))})};if("false"!==c.getContentEditable(s.getNode())){if(a){if(r)$p(r)?l(i,r)||(o=c.createRng(),o.setStartBefore(r),o.setEndAfter(r),d(c,Cg(e,o,i),null,!0)):d(c,r,null,!0);else if(u&&a.inline&&!Ag(e).length)XC(e,t,n);else{var m=s.getNode();e.settings.forced_root_block||!i[0].defaultBlock||c.getParent(m,c.isBlock)||qw(e,i[0].defaultBlock),s.setRng(py(s.getRng())),Ug(s,!0,function(t){Fg(e,function(t,n){var r=n?t:Cg(e,t,i);d(c,r)})}),Kp(c,s,s.getRng()),e.nodeChanged()}iw(t,e)}}else{r=s.getNode();for(var p=0,g=i.length;p<g;p++)if(i[p].ceFalseOverride&&c.is(r,i[p].selector))return void f(r,i[p])}},$w=function(e,t,n,r){var o=e.formatter.get(t);!AC(e,t,n,r)||"toggle"in o[0]&&!o[0].toggle?qw(e,t,n,r):Lw(e,t,n,r)},Ww=function(e,t){return Ke(t,function(t){var n=e.fire("GetSelectionRange",{range:t});return n.range!==t?n.range:t})},Kw=function(t,n){var r=n||e.document,o=r.createDocumentFragment();return Xe(t,function(e){o.appendChild(e.dom())}),ar.fromDom(o)},Xw=function(e,t,n){return{element:ve(e),width:ve(t),rows:ve(n)}},Yw=function(e,t){return{element:ve(e),cells:ve(t)}},Gw=function(e,t){return{x:ve(e),y:ve(t)}},Jw=function(e,t){var n=parseInt(Ko(e,t),10);return isNaN(n)?1:n},Qw=function(e,t,n,r,o){for(var i=Jw(o,"rowspan"),a=Jw(o,"colspan"),u=e.rows(),c=n;c<n+i;c++){u[c]||(u[c]=Yw(Fs(r),[]));for(var s=t;s<t+a;s++){var f=u[c].cells();f[s]=c===n&&s===t?o:Ms(o)}}},Zw=function(e,t,n){var r=e.rows(),o=r[n]?r[n].cells():[];return!!o[t]},ex=function(e,t,n){for(;Zw(e,t,n);)t++;return t},tx=function(e){return Ze(e,function(e,t){return t.cells().length>e?t.cells().length:e},0)},nx=function(e,t){for(var n=e.rows(),r=0;r<n.length;r++)for(var o=n[r].cells(),i=0;i<o.length;i++)if(Tr(o[i],t))return _e.some(Gw(i,r));return _e.none()},rx=function(e,t,n,r,o){for(var i=[],a=e.rows(),u=n;u<=o;u++){var c=a[u].cells(),s=t<r?c.slice(t,r+1):c.slice(r,t+1);i.push(Yw(a[u].element(),s))}return i},ox=function(e,t,n){var r=t.x(),o=t.y(),i=n.x(),a=n.y(),u=o<a?rx(e,r,o,i,a):rx(e,r,a,i,o);return Xw(e.element(),tx(u),u)},ix=function(e,t){var n=Ms(e.element()),r=ar.fromTag("tbody");return ao(r,t),ro(n,r),n},ax=function(e){return Ke(e.rows(),function(e){var t=Ke(e.cells(),function(e){var t=Fs(e);return Go(t,"colspan"),Go(t,"rowspan"),t}),n=Ms(e.element());return ao(n,t),n})},ux=function(e){var t=Xw(Ms(e),0,[]);return Xe(ps(e,"tr"),function(e,n){Xe(ps(e,"td,th"),function(r,o){Qw(t,ex(t,o,n),n,e,r)})}),Xw(t.element(),tx(t.rows()),t.rows())},cx=function(e){return ix(e,ax(e))},sx=function(e,t,n){return nx(e,t).bind(function(t){return nx(e,n).map(function(n){return ox(e,t,n)})})},fx=function(e){return tt(e,function(e){return"ul"===dr(e)||"ol"===dr(e)})},lx=function(e,t){return tt(e,function(e){return"li"===dr(e)&&Lg(e,t)}).fold(ve([]),function(t){return fx(e).map(function(e){var t=ar.fromTag(dr(e)),n=wt(ri(e),function(e,t){return yn(t,"list-style")});return Zo(t,n),[ar.fromTag("li"),t]}).getOr([])})},dx=function(e,t){var n=Ze(t,function(e,t){return ro(t,e),t},e);return t.length>0?Kw([n]):n},mx=function(e){return _i(e)?Ir(e).filter(ki).fold(ve([]),function(t){return[e,t]}):ki(e)?[e]:[]},px=function(e,t){var n=ar.fromDom(t.commonAncestorContainer),r=Qh(n,e),o=Je(r,function(e){return Si(e)||Ci(e)}),i=lx(r,t),a=o.concat(i.length?i:mx(n));return Ke(a,Ms)},gx=function(){return Kw([])},hx=function(e,t){return dx(ar.fromDom(t.cloneContents()),px(e,t))},vx=function(e,n){return vs(n,"table",t(Tr,e))},yx=function(e,t){return vx(e,t[0]).bind(function(e){var n=t[0],r=t[t.length-1],o=ux(e);return sx(o,n,r).map(function(e){return Kw([cx(e)])})}).getOrThunk(gx)},bx=function(e,t){return t.length>0&&t[0].collapsed?gx():hx(e,t[0])},Cx=function(e,t){var n=Rg(t,e);return n.length>0?yx(e,n):bx(e,t)},wx=function(e){return e.replace(/^[ \f\n\r\t\v]+/,"")},xx=function(e,t){return t>=0&&t<e.length&&Vp(e.charAt(t))},Sx=function(e){var t=Vs(e.innerText);return jn.browser.isIE()?wx(t):t},Nx=function(e){return _e.from(e.selection.getRng()).map(function(t){var n=e.dom.add(e.getBody(),"div",{"data-mce-bogus":"all",style:"overflow: hidden; opacity: 0;"},t.cloneContents()),r=Sx(n),o=Vs(n.textContent);if(e.dom.remove(n),xx(o,0)||xx(o,o.length-1)){var i=e.dom.getParent(t.commonAncestorContainer,e.dom.isBlock),a=Sx(i),u=a.indexOf(r);if(u!==-1){var c=xx(a,u-1),s=xx(a,u+r.length);return(c?" ":"")+r+(s?" ":"")}return r}return r}).getOr("")},Ex=function(e,t){var n=e.selection.getRng(),r=e.dom.create("body"),o=e.selection.getSel(),i=Ww(e,Ng(o)),a=t.contextual?Cx(ar.fromDom(e.getBody()),i).dom():n.cloneContents();return a&&r.appendChild(a),e.selection.serializer.serialize(r,t)},kx=function(e,t,n){if(void 0===n&&(n={}),n.get=!0,n.format=t,n.selection=!0,n=e.fire("BeforeGetContent",n),n.isDefaultPrevented())return e.fire("GetContent",n),n.content;if("text"===n.format)return Nx(e);n.getInner=!0;var r=Ex(e,n);return"tree"===n.format?r:(n.content=e.selection.isCollapsed()?"":r,e.fire("GetContent",n),n.content)},_x=0,Tx=1,Rx=2,Ax=function(e,t){var n=e.length+t.length+2,r=new Array(n),o=new Array(n),i=function(e,t,n){return{start:e,end:t,diag:n}},a=function(n,r,o,i,u){var s=c(n,r,o,i);if(null===s||s.start===r&&s.diag===r-i||s.end===n&&s.diag===n-o)for(var f=n,l=o;f<r||l<i;)f<r&&l<i&&e[f]===t[l]?(u.push([_x,e[f]]),++f,++l):r-n>i-o?(u.push([Rx,e[f]]),++f):(u.push([Tx,t[l]]),++l);else{a(n,s.start,o,s.start-s.diag,u);for(var d=s.start;d<s.end;++d)u.push([_x,e[d]]);a(s.end,r,s.end-s.diag,i,u)}},u=function(n,r,o,a){for(var u=n;u-r<a&&u<o&&e[u]===t[u-r];)++u;return i(n,u,r)},c=function(n,i,a,c){var s=i-n,f=c-a;if(0===s||0===f)return null;var l=s-f,d=f+s,m=(d%2===0?d:d+1)/2;r[1+m]=n,o[1+m]=i+1;var p,g,h,v,y;for(p=0;p<=m;++p){for(g=-p;g<=p;g+=2){for(h=g+m,g===-p||g!==p&&r[h-1]<r[h+1]?r[h]=r[h+1]:r[h]=r[h-1]+1,v=r[h],y=v-n+a-g;v<i&&y<c&&e[v]===t[y];)r[h]=++v,++y;if(l%2!==0&&l-p<=g&&g<=l+p&&o[h-l]<=r[h])return u(o[h-l],g+n-a,i,c)}for(g=l-p;g<=l+p;g+=2){for(h=g+m-l,g===l-p||g!==l+p&&o[h+1]<=o[h-1]?o[h]=o[h+1]-1:o[h]=o[h-1],v=o[h]-1,y=v-n+a-g;v>=n&&y>=a&&e[v]===t[y];)o[h]=v--,y--;if(l%2===0&&-p<=g&&g<=p&&o[h]<=r[h+l])return u(o[h],g+n-a,i,c)}}},s=[];return a(0,e.length,0,t.length,s),s},Dx=function(e){return ko(e)?e.outerHTML:Io(e)?ea.encodeRaw(e.data,!1):Mo(e)?"<!--"+e.data+"-->":""},Ox=function(t){var n,r=e.document.createElement("div"),o=e.document.createDocumentFragment();for(t&&(r.innerHTML=t);n=r.firstChild;)o.appendChild(n);return o},Bx=function(e,t,n){var r=Ox(t);if(e.hasChildNodes()&&n<e.childNodes.length){var o=e.childNodes[n];o.parentNode.insertBefore(r,o)}else e.appendChild(r)},Px=function(e,t){if(e.hasChildNodes()&&t<e.childNodes.length){var n=e.childNodes[t];n.parentNode.removeChild(n)}},Lx=function(e,t){var n=0;Xe(e,function(e){e[0]===_x?n++:e[0]===Tx?(Bx(t,e[1],n),n++):e[0]===Rx&&Px(t,n)})},Ix=function(e){return Je(Ke(dt(e.childNodes),Dx),function(e){return e.length>0})},Mx=function(e,t){var n=Ke(dt(t.childNodes),Dx);return Lx(Ax(n,e),t),t},Fx=Uc(_e.none()),Ux=function(){return Fx.get().getOrThunk(function(){var t=e.document.implementation.createHTMLDocument("undo");return Fx.set(_e.some(t)),t})},zx=function(e){return e.indexOf("</iframe>")!==-1},jx=function(e){return{type:"fragmented",fragments:e,content:"",bookmark:null,beforeBookmark:null}},Hx=function(e){return{type:"complete",fragments:null,content:e,bookmark:null,beforeBookmark:null}},Vx=function(e){var t=Ix(e.getBody()),n=ot(t,function(t){var n=gh(e.serializer,t);return n.length>0?[n]:[]}),r=n.join("");return zx(r)?jx(n):Hx(r)},qx=function(e,t,n){"fragmented"===t.type?Mx(t.fragments,e.getBody()):e.setContent(t.content,{format:"raw"}),e.selection.moveToBookmark(n?t.beforeBookmark:t.bookmark)},$x=function(e){return"fragmented"===e.type?e.fragments.join(""):e.content},Wx=function(e){var t=ar.fromTag("body",Ux());return Ls(t,$x(e)),Xe(ps(t,"*[data-mce-bogus]"),so),Ps(t)},Kx=function(e,t){return $x(e)===$x(t)},Xx=function(e,t){return Wx(e)===Wx(t)},Yx=function(e,t){return!(!e||!t)&&(!!Kx(e,t)||Xx(e,t))},Gx=function(e){return 0===e.get()},Jx=function(e,t,n){Gx(n)&&(e.typing=t)},Qx=function(e,t){e.typing&&(Jx(e,!1,t),e.add())},Zx=function(e){e.typing&&(e.typing=!1,e.add())},eS=function(e,t,n){Gx(t)&&n.set(_e.some(jl(e.selection)))},tS=function(e,t,n,r,o,i,a){var u=Vx(e);if(i=i||{},i=er.extend(i,u),Gx(r)===!1||e.removed)return null;var c=t.data[n.get()];if(e.fire("BeforeAddUndo",{level:i,lastLevel:c,originalEvent:a}).isDefaultPrevented())return null;if(c&&Yx(c,i))return null;t.data[n.get()]&&o.get().each(function(e){t.data[n.get()].beforeBookmark=e});var s=qd(e);if(s&&t.data.length>s){for(var f=0;f<t.data.length-1;f++)t.data[f]=t.data[f+1];t.data.length--,n.set(t.data.length)}i.bookmark=jl(e.selection),n.get()<t.data.length-1&&(t.data.length=n.get()+1),t.data.push(i),n.set(t.data.length-1);var l={level:i,lastLevel:c,originalEvent:a};return e.fire("AddUndo",l),n.get()>0&&(e.setDirty(!0),e.fire("change",l)),i},nS=function(e,t,n){t.data=[],n.set(0),t.typing=!1,e.fire("ClearUndos")},rS=function(e,t,n,r,o){if(t.transact(r)){var i=t.data[n.get()].bookmark,a=t.data[n.get()-1];qx(e,a,!0),t.transact(o)&&(t.data[n.get()-1].beforeBookmark=i)}},oS=function(e,t,n){var r;return t.get()<n.length-1&&(t.set(t.get()+1),r=n[t.get()],qx(e,r,!1),e.setDirty(!0),e.fire("Redo",{level:r})),r},iS=function(e,t,n,r){var o;return t.typing&&(t.add(),t.typing=!1,Jx(t,!1,n)),r.get()>0&&(r.set(r.get()-1),o=t.data[r.get()],qx(e,o,!0),e.setDirty(!0),e.fire("Undo",{level:o})),o},aS=function(e){e.clear(),e.add()},uS=function(e,t,n){return n.get()>0||t.typing&&t.data[0]&&!Yx(Vx(e),t.data[0])},cS=function(e,t){return t.get()<e.data.length-1&&!e.typing},sS=function(e,t,n){return Qx(e,t),e.beforeChange(),e.ignore(n),e.add()},fS=function(e,t){try{e.set(e.get()+1),t()}finally{e.set(e.get()-1)}},lS=function(e){return e instanceof Zg},dS=function(e,t){pC(e.serializer.getNodeFilters(),e.serializer.getAttributeFilters(),t)},mS=function(){return{type:"complete",fragments:[],content:"",bookmark:null,beforeBookmark:null}},pS=function(e){return{undoManager:{beforeChange:function(t,n){return eS(e,t,n)},addUndoLevel:function(t,n,r,o,i,a){return tS(e,t,n,r,o,i,a)},undo:function(t,n,r){return iS(e,t,n,r)},redo:function(t,n){return oS(e,t,n)},clear:function(t,n){return nS(e,t,n)},reset:function(e){return aS(e)},hasUndo:function(t,n){return uS(e,t,n)},hasRedo:function(e,t){return cS(e,t)},transact:function(e,t,n){return sS(e,t,n)},ignore:function(e,t){return fS(e,t)},extra:function(t,n,r,o){return rS(e,t,n,r,o)}},formatter:{apply:function(t,n,r){return qw(e,t,n,r)},remove:function(t,n,r,o){return Lw(e,t,n,r,o)},toggle:function(t,n,r){return $w(e,t,n,r)}},editor:{getContent:function(t,n){return bh(e,t,n)},setContent:function(t,n){return wC(e,t,n)},insertContent:function(t,n){return Jy(e,t,n)}},selection:{getContent:function(t,n){return kx(e,t,n)}},raw:{getModel:function(){return _e.none()}}}},gS=function(e,t){var n=function(e){return Be(e)?e:{}},r=Ce("Unimplemented feature for rtc"),o=pe;return{undoManager:{beforeChange:o,addUndoLevel:r,undo:function(){return t.undo(),mS()},redo:function(){return t.redo(),mS()},clear:r,reset:r,hasUndo:function(){return t.hasUndo()},hasRedo:function(){return t.hasRedo()},transact:function(e,n,r){return t.transact(r),mS()},ignore:r,extra:r},formatter:{apply:function(e,r,o){return t.applyFormat(e,n(r))},remove:function(e,r,o,i){return t.removeFormat(e,n(r))},toggle:function(e,r,o){return t.toggleFormat(e,n(r))}},editor:{getContent:function(n,r){if("html"===r||"tree"===r){var o=t.getContent(),i=nh({inner:!0});return dS(e,o),"tree"===r?o:i.serialize(o)}return pS(e).editor.getContent(n,r)},setContent:function(n,r){var o=lS(n)?n:e.parser.parse(n,{isRootContent:!0,insert:!0});return t.setContent(o),n},insertContent:function(n,r){var o=lS(n)?n:e.parser.parse(n,{insert:!0});t.insertContent(o)}},selection:{getContent:function(n,r){if("html"===n||"tree"===n){var o=t.getSelectedContent(),i=nh({});return dS(e,o),"tree"===n?o:i.serialize(o)}return pS(e).selection.getContent(n,r)}},raw:{getModel:function(){return _e.some(t.getRawModel())}}}},hS=function(e){return Et(e.plugins,"rtc")},vS=function(e){var t=e;return Nt(e.plugins,"rtc").fold(function(){return t.rtcInstance=pS(e),_e.none()},function(n){return _e.some(n.setup().then(function(n){return t.rtcInstance=gS(e,n),n.isRemote}))})},yS=function(e){return e.rtcInstance?e.rtcInstance:pS(e)},bS=function(e){var t=e.rtcInstance;if(t)return t;throw new Error("Failed to get RTC instance not yet initialized.")},CS=function(e,t,n){bS(e).undoManager.beforeChange(t,n)},wS=function(e,t,n,r,o,i,a){return bS(e).undoManager.addUndoLevel(t,n,r,o,i,a)},xS=function(e,t,n,r){return bS(e).undoManager.undo(t,n,r)},SS=function(e,t,n){return bS(e).undoManager.redo(t,n)},NS=function(e,t,n){bS(e).undoManager.clear(t,n)},ES=function(e,t){bS(e).undoManager.reset(t)},kS=function(e,t,n){return bS(e).undoManager.hasUndo(t,n)},_S=function(e,t,n){return bS(e).undoManager.hasRedo(t,n)},TS=function(e,t,n,r){return bS(e).undoManager.transact(t,n,r)},RS=function(e,t,n){bS(e).undoManager.ignore(t,n)},AS=function(e,t,n,r,o){bS(e).undoManager.extra(t,n,r,o)},DS=function(e,t,n,r){
bS(e).formatter.apply(t,n,r)},OS=function(e,t,n,r,o){bS(e).formatter.remove(t,n,r,o)},BS=function(e,t,n,r){bS(e).formatter.toggle(t,n,r)},PS=function(e,t,n){return yS(e).editor.getContent(t,n)},LS=function(e,t,n){return yS(e).editor.setContent(t,n)},IS=function(e,t,n){return yS(e).editor.insertContent(t,n)},MS=function(e,t,n){return bS(e).selection.getContent(t,n)},FS="html",US=function(e,t){void 0===t&&(t={});var n=t.format?t.format:FS;return PS(e,t,n)},zS=function(e,t,n){return void 0===n&&(n={}),LS(e,t,n)},jS=function(e,t){return e.fire("PreProcess",t)},HS=function(e,t){return e.fire("PostProcess",t)},VS=function(e){return e.fire("remove")},qS=function(e){return e.fire("detach")},$S=function(e,t){return e.fire("SwitchMode",{mode:t})},WS=function(e,t,n,r){e.fire("ObjectResizeStart",{target:t,width:n,height:r})},KS=function(e,t,n,r){e.fire("ObjectResized",{target:t,width:n,height:r})},XS=function(e){return e.fire("PreInit")},YS=function(e){return e.fire("PostRender")},GS=function(e){return e.fire("Init")},JS=function(e,t){return e.fire("PlaceholderToggle",{state:t})},QS=function(e,t,n){return e.fire(t,n)},ZS=Ac.DOM,eN=function(e){ZS.setStyle(e.id,"display",e.orgDisplay)},tN=function(e){return _e.from(e).each(function(e){return e.destroy()})},nN=function(e){e.contentAreaContainer=e.formElement=e.container=e.editorContainer=null,e.bodyElement=e.contentDocument=e.contentWindow=null,e.iframeElement=e.targetElm=null,e.selection&&(e.selection=e.selection.win=e.selection.dom=e.selection.dom.doc=null)},rN=function(e){var t=e.formElement;t&&(t._mceOldSubmit&&(t.submit=t._mceOldSubmit,t._mceOldSubmit=null),ZS.unbind(t,"submit reset",e.formEventDelegate))},oN=function(e){if(!e.removed){var t=e._selectionOverrides,n=e.editorUpload,r=e.getBody(),o=e.getElement();r&&e.save({is_removing:!0}),e.removed=!0,e.unbindAllNativeEvents(),e.hasHiddenInput&&o&&ZS.remove(o.nextSibling),VS(e),e.editorManager.remove(e),!e.inline&&r&&eN(e),qS(e),ZS.remove(e.getContainer()),tN(t),tN(n),e.destroy()}},iN=function(e,t){var n=e.selection,r=e.dom;if(!e.destroyed){if(!t&&!e.removed)return void e.remove();t||(e.editorManager.off("beforeunload",e._beforeUnload),e.theme&&e.theme.destroy&&e.theme.destroy(),tN(n),tN(r)),rN(e),nN(e),e.destroyed=!0}},aN=Object.prototype.hasOwnProperty,uN=function(e,t){var n=Be(e)&&Be(t);return n?sN(e,t):t},cN=function(e){return function(){for(var t=new Array(arguments.length),n=0;n<t.length;n++)t[n]=arguments[n];if(0===t.length)throw new Error("Can't merge zero objects");for(var r={},o=0;o<t.length;o++){var i=t[o];for(var a in i)aN.call(i,a)&&(r[a]=e(r[a],i[a]))}return r}},sN=cN(uN),fN=function(e,t){return{sections:ve(e),settings:ve(t)}},lN=On().deviceType,dN=lN.isTouch(),mN=lN.isPhone(),pN=lN.isTablet(),gN=["lists","autolink","autosave"],hN={table_grid:!1,object_resizing:!1,resize:!1},vN=function(e){var t=Pe(e)?e.join(" "):e,n=Ke(Oe(t)?t.split(" "):[],Cn);return Je(n,function(e){return e.length>0})},yN=function(e){return Je(e,t($e,gN))},bN=function(e,t){var n=Ct(t,function(t,n){return $e(e,n)});return fN(n.t,n.f)},CN=function(e,t,n){void 0===n&&(n={});var r=e.sections(),o=r.hasOwnProperty(t)?r[t]:{};return er.extend({},n,o)},wN=function(e,t){return e.sections().hasOwnProperty(t)},xN=function(e,t,n){var r=e.sections();return wN(e,t)&&r[t].theme===n},SN=function(e,t){return wN(e,t)?e.sections()[t]:{}},NN=function(e,t){return Nt(e,"toolbar_mode").orThunk(function(){return Nt(e,"toolbar_drawer").map(function(e){return e===!1?"wrap":e})}).getOr(t)},EN=function(e,t,n,r,o){var i={id:t,theme:"silver",toolbar_mode:NN(e,"floating"),plugins:"",document_base_url:n,add_form_submit_trigger:!0,submit_patch:!0,add_unload_trigger:!0,convert_urls:!0,relative_urls:!0,remove_script_host:!0,object_resizing:!0,doctype:"<!DOCTYPE html>",visual:!0,font_size_legacy_values:"xx-small,small,medium,large,x-large,xx-large,300%",forced_root_block:"p",hidden_input:!0,inline_styles:!0,convert_fonts_to_spans:!0,indent:!0,indent_before:"p,h1,h2,h3,h4,h5,h6,blockquote,div,title,style,pre,script,td,th,ul,ol,li,dl,dt,dd,area,table,thead,tfoot,tbody,tr,section,summary,article,hgroup,aside,figure,figcaption,option,optgroup,datalist",indent_after:"p,h1,h2,h3,h4,h5,h6,blockquote,div,title,style,pre,script,td,th,ul,ol,li,dl,dt,dd,area,table,thead,tfoot,tbody,tr,section,summary,article,hgroup,aside,figure,figcaption,option,optgroup,datalist",entity_encoding:"named",url_converter:o.convertURL,url_converter_scope:o};return It(It({},i),r?hN:{})},kN=function(e,t){var n={resize:!1,toolbar_mode:NN(e,"scrolling"),toolbar_sticky:!1},r={menubar:!1};return It(It(It({},hN),n),t?r:{})},_N=function(e,t){var n=t.external_plugins?t.external_plugins:{};return e&&e.external_plugins?er.extend({},e.external_plugins,n):n},TN=function(e,t){return[].concat(vN(e)).concat(vN(t))},RN=function(e,t,n,r){var o=vN(n.forced_plugins),i=vN(r.plugins),a=SN(t,"mobile"),u=a.plugins?vN(a.plugins):i,c=e&&xN(t,"mobile","mobile")?yN(u):e&&wN(t,"mobile")?u:i,s=TN(o,c);return er.extend(r,{plugins:s.join(" ")})},AN=function(e,t){return e&&wN(t,"mobile")},DN=function(e,t,n,r,o){var i=e?{mobile:kN(o.mobile||{},t)}:{},a=bN(["mobile"],sN(i,o)),u=er.extend(n,r,a.settings(),AN(e,a)?CN(a,"mobile"):{},{validate:!0,external_plugins:_N(r,a.settings())});return RN(e,a,r,u)},ON=function(e,t,n,r,o){var i=EN(o,t,n,dN,e);return DN(mN||pN,mN,i,r,o)},BN=function(e,t,n){return _e.from(t.settings[n]).filter(e)},PN=function(e){var t={};return"string"==typeof e?Xe(e.indexOf("=")>0?e.split(/[;,](?![^=;,]*(?:[;,]|$))/):e.split(","),function(e){var n=e.split("=");n.length>1?t[er.trim(n[0])]=er.trim(n[1]):t[er.trim(n[0])]=er.trim(n[0])}):t=e,t},LN=function(e){return function(t){return Pe(t)&&it(t,e)}},IN=function(e,t,n,r){var o=t in e.settings?e.settings[t]:n;return"hash"===r?PN(o):"string"===r?BN(Oe,e,t).getOr(n):"number"===r?BN(Ue,e,t).getOr(n):"boolean"===r?BN(Ie,e,t).getOr(n):"object"===r?BN(Be,e,t).getOr(n):"array"===r?BN(Pe,e,t).getOr(n):"string[]"===r?BN(LN(Oe),e,t).getOr(n):"function"===r?BN(Fe,e,t).getOr(n):o},MN=function(){var e={},t=function(t,n){e[t]=n},n=function(t){return e[t]?e[t]:{icons:{}}},r=function(t){return Et(e,t)};return{add:t,get:n,has:r}},FN=MN(),UN=function(e,t){var n=t.dom();return n[e]},zN=function(e,t){return parseInt(ei(t,e),10)},jN=t(UN,"clientWidth"),HN=t(UN,"clientHeight"),VN=t(zN,"margin-top"),qN=t(zN,"margin-left"),$N=function(e){return e.dom().getBoundingClientRect()},WN=function(e,t,n){var r=jN(e),o=HN(e);return t>=0&&n>=0&&t<=r&&n<=o},KN=function(e,t,n,r){var o=$N(t),i=e?o.left+t.dom().clientLeft+qN(t):0,a=e?o.top+t.dom().clientTop+VN(t):0,u=n-i,c=r-a;return{x:u,y:c}},XN=function(e,t,n){var r=ar.fromDom(e.getBody()),o=e.inline?r:Pr(r),i=KN(e.inline,o,t,n);return WN(o,i.x,i.y)},YN=function(e){return _e.from(e).map(ar.fromDom)},GN=function(e){var t=e.inline?e.getBody():e.getContentAreaContainer();return YN(t).map(function(e){return Dr(Or(e),e)}).getOr(!1)},JN=Zc.PluginManager,QN=Zc.ThemeManager,ZN=function(e){var t=[],n=function(){var t=e.theme;return t&&t.getWindowManagerImpl?t.getWindowManagerImpl():A()},r=function(e,t){return function(){return t?t.apply(e,arguments):void 0}},o=function(t){e.fire("OpenWindow",{dialog:t})},i=function(t){e.fire("CloseWindow",{dialog:t})},a=function(e){t.push(e),o(e)},u=function(n){i(n),t=Je(t,function(e){return e!==n}),0===t.length&&e.focus()},c=function(){return _e.from(t[t.length-1])},s=function(t){e.editorManager.setActive(e),Ob(e);var n=t();return a(n),n},f=function(e,t){return s(function(){return n().open(e,t,u)})},l=function(e){return s(function(){return n().openUrl(e,u)})},d=function(e,t,o){n().alert(e,r(o?o:this,t))},m=function(e,t,o){n().confirm(e,r(o?o:this,t))},p=function(){c().each(function(e){n().close(e),u(e)})};return e.on("remove",function(){Xe(t,function(e){n().close(e)})}),{open:f,openUrl:l,alert:d,confirm:m,close:p}},eE=function(e,t){e.notificationManager.open({type:"error",text:t})},tE=function(e,t){e._skinLoaded?eE(e,t):e.on("SkinLoaded",function(){eE(e,t)})},nE=function(e,t){tE(e,Qc.translate(["Failed to upload image: {0}",t]))},rE=function(t,n,r){QS(t,n,{message:r}),e.console.error(r)},oE=function(e,t,n){return n?"Failed to load "+e+": "+n+" from url "+t:"Failed to load "+e+" url: "+t},iE=function(e,t,n){rE(e,"PluginLoadError",oE("plugin",t,n))},aE=function(e,t,n){rE(e,"IconsLoadError",oE("icons",t,n))},uE=function(e,t,n){rE(e,"LanguageLoadError",oE("language",t,n))},cE=function(e,t,n){var r=Qc.translate(["Failed to initialize plugin: {0}",t]);sE(r,n),tE(e,r)},sE=function(t){for(var n=[],o=1;o<arguments.length;o++)n[o-1]=arguments[o];var i=e.window.console;i&&(i.error?i.error.apply(i,r([t],n)):i.log.apply(i,r([t],n)))},fE=function(e){return/^[a-z0-9\-]+$/i.test(e)},lE=function(e){var t=xd(e),n=e.editorManager.baseURL+"/skins/content",r=e.editorManager.suffix,o="content"+r+".css",i=e.inline===!0;return Ke(t,function(t){return fE(t)&&!i?n+"/"+t+"/"+o:e.documentBaseURI.toAbsolute(t)})},dE=function(e){e.contentCSS=e.contentCSS.concat(lE(e))},mE=D("height",function(e){var t=e.dom();return fo(e)?t.getBoundingClientRect().height:t.offsetHeight}),pE=function(e){return mE.get(e)},gE=function(e,t){var n=e.view(t);return n.fold(ve([]),function(t){var n=e.owner(t),r=gE(e,n);return[t].concat(r)})},hE=function(e,t){var n=t.owner(e);return gE(t,n)},vE=function(t){var n=t.dom()===e.document?_e.none():_e.from(t.dom().defaultView.frameElement);return n.map(ar.fromDom)},yE=function(e){return Or(e)},bE=Object.freeze({__proto__:null,view:vE,owner:yE}),CE=function(t){var n=ar.fromDom(e.document),r=yo(n),o=hE(t,bE),i=vo(t),a=Qe(o,function(e,t){var n=vo(t);return{left:e.left+n.left(),top:e.top+n.top()}},{left:0,top:0});return mo(a.left+i.left()+r.left(),a.top+i.top()+r.top())},wE=function(e){return"textarea"===dr(e)},xE=function(e,t){var n=e.fire("ScrollIntoView",t);return n.isDefaultPrevented()},SE=function(e,t){e.fire("AfterScrollIntoView",t)},NE=function(e,t){var n=Vr(e);if(0===n.length||wE(e))return{element:e,offset:t};if(t<n.length&&!wE(n[t]))return{element:n[t],offset:0};var r=n[n.length-1];return wE(r)?{element:e,offset:t}:"img"===dr(r)?{element:r,offset:1}:vr(r)?{element:r,offset:jg(r).length}:{element:r,offset:Vr(r).length}},EE=function(e,t){var n=ho(e),r=pE(e);return{element:e,bottom:n.top()+r,height:r,pos:n,cleanup:t}},kE=function(e,t){var n=NE(e,t),r=ar.fromHtml('<span data-mce-bogus="all">'+js+"</span>");return eo(n.element,r),EE(r,function(){return co(r)})},_E=function(e){return EE(ar.fromDom(e),pe)},TE=function(e,t,n,r){OE(e,function(o,i){return AE(e,t,n,r)},n)},RE=function(e,t,n,r,o){var i={elm:r.element.dom(),alignToTop:o};if(!xE(e,i)){var a=yo(t).top();n(t,a,r,o),SE(e,i)}},AE=function(e,t,n,r){var o=ar.fromDom(e.getBody()),i=ar.fromDom(e.getDoc());oi(o);var a=kE(ar.fromDom(n.startContainer),n.startOffset);RE(e,i,t,a,r),a.cleanup()},DE=function(e,t,n,r){var o=ar.fromDom(e.getDoc());RE(e,o,n,_E(t),r)},OE=function(e,t,n){var r=n.startContainer,o=n.startOffset,i=n.endContainer,a=n.endOffset;t(ar.fromDom(r),ar.fromDom(i));var u=e.dom.createRng();u.setStart(r,o),u.setEnd(i,a),e.selection.setRng(n)},BE=function(e,t,n,r){var o=e.pos;if(n)bo(o.left(),o.top(),r);else{var i=o.top()-t+e.height;bo(o.left(),i,r)}},PE=function(e,t,n,r,o){var i=n+t,a=r.pos.top(),u=r.bottom,c=u-a>=n;if(a<t)BE(r,n,o!==!1,e);else if(a>i){var s=c?o!==!1:o===!0;BE(r,n,s,e)}else u>i&&!c&&BE(r,n,o===!0,e)},LE=function(e,t,n,r){var o=e.dom().defaultView.innerHeight;PE(e,t,o,n,r)},IE=function(t,n,r,o){var i=t.dom().defaultView.innerHeight;PE(t,n,i,r,o);var a=CE(r.element),u=So(e.window);a.top()<u.y?Co(r.element,o!==!1):a.top()>u.bottom&&Co(r.element,o===!0)},ME=function(e,t,n){return TE(e,LE,t,n)},FE=function(e,t,n){return DE(e,t,LE,n)},UE=function(e,t,n){return TE(e,IE,t,n)},zE=function(e,t,n){return DE(e,t,IE,n)},jE=function(e,t,n){var r=e.inline?FE:zE;r(e,t,n)},HE=function(e,t,n){var r=e.inline?ME:UE;r(e,t,n)},VE=function(e){return jo(e)||Ho(e)},qE=function(e,t,n){for(;e&&e!==t;){if(n(e))return e;e=e.parentNode}return null},$E=function(e,t,n){var r,o=n.elementFromPoint(e,t),i=n.body.createTextRange();if(o&&"HTML"!==o.tagName||(o=n.body),i.moveToElementText(o),r=er.toArray(i.getClientRects()),r=r.sort(function(e,n){return e=Math.abs(Math.max(e.top-t,e.bottom-t)),n=Math.abs(Math.max(n.top-t,n.bottom-t)),e-n}),r.length>0){t=(r[0].bottom+r[0].top)/2;try{return i.moveToPoint(e,t),i.collapse(!0),i}catch(a){}}return null},WE=function(e,t){var n=e&&e.parentElement?e.parentElement():null;return Ho(qE(n,t,VE))?null:e},KE=function(e,t,n){var r,o,i=n;if(i.caretPositionFromPoint)o=i.caretPositionFromPoint(e,t),o&&(r=n.createRange(),r.setStart(o.offsetNode,o.offset),r.collapse(!0));else if(n.caretRangeFromPoint)r=n.caretRangeFromPoint(e,t);else if(i.body.createTextRange){r=i.body.createTextRange();try{r.moveToPoint(e,t),r.collapse(!0)}catch(a){r=$E(e,t,n)}return WE(r,n.body)}return r},XE=function(e,t,n,r,o){var i=n?t.startContainer:t.endContainer,a=n?t.startOffset:t.endOffset;return _e.from(i).map(ar.fromDom).map(function(e){return r&&t.collapsed?e:qr(e,o(e,a)).getOr(e)}).bind(function(e){return hr(e)?_e.some(e):Ir(e).filter(hr)}).map(function(e){return e.dom()}).getOr(e)},YE=function(e,t,n){return XE(e,t,!0,n,function(e,t){return Math.min(Kr(e),t)})},GE=function(e,t,n){return XE(e,t,!1,n,function(e,t){return t>0?t-1:t})},JE=function(e,t){for(var n=e;e&&Io(e)&&0===e.length;)e=t?e.nextSibling:e.previousSibling;return e||n},QE=function(e,t){var n,r,o;if(!t)return e;r=t.startContainer,o=t.endContainer;var i=t.startOffset,a=t.endOffset;return n=t.commonAncestorContainer,!t.collapsed&&(r===o&&a-i<2&&r.hasChildNodes()&&(n=r.childNodes[i]),3===r.nodeType&&3===o.nodeType&&(r=r.length===i?JE(r.nextSibling,!0):r.parentNode,o=0===a?JE(o.previousSibling,!1):o.parentNode,r&&r===o))?r:n&&3===n.nodeType?n.parentNode:n},ZE=function(e,t,n,r){var o,i=[],a=e.getRoot();if(n=e.getParent(n||YE(a,t,t.collapsed),e.isBlock),r=e.getParent(r||GE(a,t,t.collapsed),e.isBlock),n&&n!==a&&i.push(n),n&&r&&n!==r){o=n;for(var u=new qu(n,a);(o=u.next())&&o!==r;)e.isBlock(o)&&i.push(o)}return r&&n!==r&&r!==a&&i.push(r),i},ek=function(e,t,n){return _e.from(t).map(function(t){var r=e.nodeIndex(t),o=e.createRng();return o.setStart(t.parentNode,r),o.setEnd(t.parentNode,r+1),n&&(Ig(e,o,t,!0),Ig(e,o,t,!1)),o})},tk=function(e,t){void 0===t&&(t={});var n=t.format?t.format:"html";return MS(e,n,t)},nk=function(e,t){return e&&t&&e.startContainer===t.startContainer&&e.startOffset===t.startOffset&&e.endContainer===t.endContainer&&e.endOffset===t.endOffset},rk=function(e,t,n){for(;e&&e!==t;){if(n(e))return e;e=e.parentNode}return null},ok=function(e,t,n){return null!==rk(e,t,n)},ik=function(e,t,n){return ok(e,t,function(e){return e.nodeName===n})},ak=function(e){return e&&"TABLE"===e.nodeName},uk=function(e){return e&&/^(TD|TH|CAPTION)$/.test(e.nodeName)},ck=function(e,t){return Xs(e)&&ok(e,t,yp)===!1},sk=function(e,t,n){for(var r=new qu(t,e.getParent(t.parentNode,e.isBlock)||e.getRoot());t=r[n?"prev":"next"]();)if(zo(t))return!0},fk=function(e,t){return e.previousSibling&&e.previousSibling.nodeName===t},lk=function(e,t){for(;t&&t!==e;){if(Ho(t))return!0;t=t.parentNode}return!1},dk=function(e,t,n,r,o){var i,a,u=e.getRoot(),c=e.schema.getNonEmptyElements(),s=e.getParent(o.parentNode,e.isBlock)||u;if(r&&zo(o)&&t&&e.isEmpty(s))return _e.some(E(o.parentNode,e.nodeIndex(o)));for(var f=new qu(o,s);a=f[r?"prev":"next"]();){if("false"===e.getContentEditableParent(a)||ck(a,u))return _e.none();if(Io(a)&&a.nodeValue.length>0)return ik(a,u,"A")===!1?_e.some(E(a,r?a.nodeValue.length:0)):_e.none();if(e.isBlock(a)||c[a.nodeName.toLowerCase()])return _e.none();i=a}return n&&i?_e.some(E(i,0)):_e.none()},mk=function(e,t,n,r){var o,i,a,u,c=e.getRoot(),s=!1;o=r[(n?"start":"end")+"Container"],i=r[(n?"start":"end")+"Offset"];var f=ko(o)&&i===o.childNodes.length,l=e.schema.getNonEmptyElements();if(u=n,Xs(o))return _e.none();if(ko(o)&&i>o.childNodes.length-1&&(u=!1),Fo(o)&&(o=c,i=0),o===c){if(u&&(a=o.childNodes[i>0?i-1:0])){if(Xs(a))return _e.none();if(l[a.nodeName]||ak(a))return _e.none()}if(o.hasChildNodes()){if(i=Math.min(!u&&i>0?i-1:i,o.childNodes.length-1),o=o.childNodes[i],i=Io(o)&&f?o.data.length:0,!t&&o===c.lastChild&&ak(o))return _e.none();if(lk(c,o)||Xs(o))return _e.none();if(o.hasChildNodes()&&ak(o)===!1){a=o;var d=new qu(o,c);do{if(Ho(a)||Xs(a)){s=!1;break}if(Io(a)&&a.nodeValue.length>0){i=u?0:a.nodeValue.length,o=a,s=!0;break}if(l[a.nodeName.toLowerCase()]&&!uk(a)){i=e.nodeIndex(a),o=a.parentNode,u||i++,s=!0;break}}while(a=u?d.next():d.prev())}}}return t&&(Io(o)&&0===i&&dk(e,f,t,!0,o).each(function(e){o=e.container(),i=e.offset(),s=!0}),ko(o)&&(a=o.childNodes[i],a||(a=o.childNodes[i-1]),!a||!zo(a)||fk(a,"A")||sk(e,a,!1)||sk(e,a,!0)||dk(e,f,t,!0,a).each(function(e){o=e.container(),i=e.offset(),s=!0}))),u&&!t&&Io(o)&&i===o.nodeValue.length&&dk(e,f,t,!1,o).each(function(e){o=e.container(),i=e.offset(),s=!0}),s?_e.some(E(o,i)):_e.none()},pk=function(e,t){var n=t.collapsed,r=t.cloneRange(),o=E.fromRangeStart(t);return mk(e,n,!0,r).each(function(e){n&&E.isAbove(o,e)||r.setStart(e.container(),e.offset())}),n||mk(e,n,!1,r).each(function(e){r.setEnd(e.container(),e.offset())}),n&&r.collapse(!0),nk(t,r)?_e.none():_e.some(r)},gk=function(e,t){e.insertData(0,t)},hk=function(e){return 0===e.dom().length?(co(e),_e.none()):_e.some(e)},vk=function(e,t){var n=_e.from(t.firstChild).map(ar.fromDom),r=_e.from(t.lastChild).map(ar.fromDom);e.deleteContents(),e.insertNode(t);var o=n.bind(Ur).filter(vr).bind(hk),i=r.bind(zr).filter(vr).bind(hk);cf(o,n.filter(vr),function(e,t){gk(t.dom(),e.dom().data),co(e)}),cf(i,r.filter(vr),function(t,n){var r=n.dom().length;n.dom().appendData(t.dom().data),e.setEnd(n.dom(),r),co(t)}),e.collapse(!1)},yk=function(e,t){return It(It({format:"html"},e),{set:!0,selection:!0,content:t})},bk=function(e,t){if("raw"!==t.format){var n=e.parser.parse(t.content,It({isRootContent:!0,forced_root_block:!1},t));return nh({validate:e.validate},e.schema).serialize(n)}return t.content},Ck=function(e,t,n){void 0===n&&(n={});var r=yk(n,t);if(!r.no_events&&(r=e.fire("BeforeSetContent",r),r.isDefaultPrevented()))return void e.fire("SetContent",r);n.content=bk(e,r);var o=e.selection.getRng();vk(o,o.createContextualFragment(n.content)),e.selection.setRng(o),HE(e,o),r.no_events||e.fire("SetContent",r)};!function(e){e.isBookmarkNode=zp}(O||(O={}));var wk,xk=O,Sk=function(e,t,n){if(n.collapsed)return!1;if(jn.browser.isIE()&&n.startOffset===n.endOffset-1&&n.startContainer===n.endContainer){var r=n.startContainer.childNodes[n.startOffset];if(ko(r))return We(r.getClientRects(),function(n){return yf(n,e,t)})}return We(n.getClientRects(),function(n){return yf(n,e,t)})},Nk={BACKSPACE:8,DELETE:46,DOWN:40,ENTER:13,LEFT:37,RIGHT:39,SPACEBAR:32,TAB:9,UP:38,END:35,HOME:36,modifierPressed:function(e){return e.shiftKey||e.ctrlKey||e.altKey||this.metaKeyPressed(e)},metaKeyPressed:function(e){return jn.mac?e.metaKey:e.ctrlKey&&!e.altKey}},Ek=Ho,kk=jo,_k=function(e,t){for(;t&&t!==e;){if(kk(t)||Ek(t))return t;t=t.parentNode}return null},Tk=function(t,n){var r,o,i,a,u,c,s,f,l,d,m,p,g,h,v,y,b=n.dom,C=er.each,w=n.getDoc(),x=e.document,S=Math.abs,N=Math.round,E=n.getBody(),k={nw:[0,0,-1,-1],ne:[1,0,1,-1],se:[1,1,1,1],sw:[0,1,-1,1]},_=function(e){return e&&("IMG"===e.nodeName||n.dom.is(e,"figure.image"))},T=function(e,t){if("longpress"===e.type||0===e.type.indexOf("touch")){var n=e.touches[0];return _(e.target)&&!Sk(n.clientX,n.clientY,t)}return _(e.target)&&!Sk(e.clientX,e.clientY,t)},R=function(e){var t=e.target;T(e,n.selection.getRng())&&!e.isDefaultPrevented()&&n.selection.select(t)},A=function(e){return n.dom.is(e,"figure.image")?e.querySelector("img"):e},D=function(e){var t=Ed(n);return t!==!1&&!jn.iOS&&("string"!=typeof t&&(t="table,img,figure.image,div"),"false"!==e.getAttribute("data-mce-resize")&&(e!==n.getBody()&&Nr(ar.fromDom(e),t)))},O=function(e,t,n){b.setStyles(A(e),{width:t,height:n})},B=function(e){var t,C,w,x,k;t=e.screenX-u,C=e.screenY-c,g=t*a[2]+l,h=C*a[3]+d,g=g<5?5:g,h=h<5?5:h,w=_(r)&&kd(n)!==!1?!Nk.modifierPressed(e):Nk.modifierPressed(e),w&&(S(t)>S(C)?(h=N(g*m),g=N(h/m)):(g=N(h/m),h=N(g*m))),O(o,g,h),x=a.startPos.x+t,k=a.startPos.y+C,x=x>0?x:0,k=k>0?k:0,b.setStyles(i,{left:x,top:k,display:"block"}),i.innerHTML=g+" &times; "+h,a[2]<0&&o.clientWidth<=g&&b.setStyle(o,"left",s+(l-g)),a[3]<0&&o.clientHeight<=h&&b.setStyle(o,"top",f+(d-h)),t=E.scrollWidth-v,C=E.scrollHeight-y,t+C!==0&&b.setStyles(i,{left:x-t,top:k-C}),p||(WS(n,r,l,d),p=!0)},P=function(){var e=p;p=!1;var t=function(e,t){t&&(r.style[e]||!n.schema.isValid(r.nodeName.toLowerCase(),e)?b.setStyle(A(r),e,t):b.setAttrib(A(r),e,""+t))};e&&(t("width",g),t("height",h)),b.unbind(w,"mousemove",B),b.unbind(w,"mouseup",P),x!==w&&(b.unbind(x,"mousemove",B),b.unbind(x,"mouseup",P)),b.remove(o),b.remove(i),L(r),e&&(KS(n,r,g,h),b.setAttrib(r,"style",b.getAttrib(r,"style"))),n.nodeChanged()},L=function(e){I(),U();var t=b.getPos(e,E),s=t.x,f=t.y,p=e.getBoundingClientRect(),S=p.width||p.right-p.left,N=p.height||p.bottom-p.top;r!==e&&(r=e,g=h=0);var _=n.fire("ObjectSelected",{target:e});D(e)&&!_.isDefaultPrevented()?C(k,function(e,t){var n,p=function(t){u=t.screenX,c=t.screenY,l=A(r).clientWidth,d=A(r).clientHeight,m=d/l,a=e,e.startPos={x:S*e[0]+s,y:N*e[1]+f},v=E.scrollWidth,y=E.scrollHeight,o=r.cloneNode(!0),b.addClass(o,"mce-clonedresizable"),b.setAttrib(o,"data-mce-bogus","all"),o.contentEditable=!1,o.unSelectabe=!0,b.setStyles(o,{left:s,top:f,margin:0}),O(o,S,N),o.removeAttribute("data-mce-selected"),E.appendChild(o),b.bind(w,"mousemove",B),b.bind(w,"mouseup",P),x!==w&&(b.bind(x,"mousemove",B),b.bind(x,"mouseup",P)),i=b.add(E,"div",{"class":"mce-resize-helper","data-mce-bogus":"all"},l+" &times; "+d)};n=b.get("mceResizeHandle"+t),n&&b.remove(n),n=b.add(E,"div",{id:"mceResizeHandle"+t,"data-mce-bogus":"all","class":"mce-resizehandle",unselectable:!0,style:"cursor:"+t+"-resize; margin:0; padding:0"}),11===jn.ie&&(n.contentEditable=!1),b.bind(n,"mousedown",function(e){e.stopImmediatePropagation(),e.preventDefault(),p(e)}),e.elm=n,b.setStyles(n,{left:S*e[0]+s-n.offsetWidth/2,top:N*e[1]+f-n.offsetHeight/2})}):I(),r.setAttribute("data-mce-selected","1")},I=function(){U(),r&&r.removeAttribute("data-mce-selected"),gt(k,function(e,t){var n=b.get("mceResizeHandle"+t);n&&(b.unbind(n),b.remove(n))})},M=function(e){var r,o,i=function(e,t){if(e)do if(e===t)return!0;while(e=e.parentNode)};if(!p&&!n.removed)return C(b.select("img[data-mce-selected],hr[data-mce-selected]"),function(e){e.removeAttribute("data-mce-selected")}),o="mousedown"===e.type?e.target:t.getNode(),o=b.$(o).closest("table,img,figure.image,hr")[0],i(o,E)&&(z(),r=t.getStart(!0),i(r,o)&&i(t.getEnd(!0),o))?void L(o):void I()},F=function(e){return Ek(_k(n.getBody(),e))},U=function(){gt(k,function(e){e.elm&&(b.unbind(e.elm),delete e.elm)})},z=function(){try{n.getDoc().execCommand("enableObjectResizing",!1,!1)}catch(e){}};n.on("init",function(){if(z(),jn.browser.isIE()||jn.browser.isEdge()){n.on("mousedown click",function(e){var t=e.target,r=t.nodeName;p||!/^(TABLE|IMG|HR)$/.test(r)||F(t)||(2!==e.button&&n.selection.select(t,"TABLE"===r),"mousedown"===e.type&&n.nodeChanged())});var e=function(e){var t=function(e){Cc.setEditorTimeout(n,function(){return n.selection.select(e)})};return F(e.target)?(e.preventDefault(),void t(e.target)):void(/^(TABLE|IMG|HR)$/.test(e.target.nodeName)&&(e.preventDefault(),"IMG"===e.target.tagName&&t(e.target)))};b.bind(E,"mscontrolselect",e),n.on("remove",function(){return b.unbind(E,"mscontrolselect",e)})}var t=Cc.throttle(function(e){n.composing||M(e)});n.on("nodechange ResizeEditor ResizeWindow ResizeContent drop FullscreenStateChanged",t),n.on("keyup compositionend",function(e){r&&"TABLE"===r.nodeName&&t(e)}),n.on("hide blur",I),n.on("contextmenu longpress",R,!0)}),n.on("remove",U);var j=function(){r=o=null};return{isResizable:D,showResizeRect:L,hideResizeRect:I,updateResizeRect:M,destroy:j}},Rk=function(e,t,n){if(e&&e.hasOwnProperty(t)){var r=Je(e[t],function(e){return e!==n});0===r.length?delete e[t]:e[t]=r}},Ak=function(e){return!!e.select},Dk=function(e){return!(!e||!e.ownerDocument)&&Dr(ar.fromDom(e.ownerDocument),ar.fromDom(e))},Ok=function(e){return!!e&&(!!Ak(e)||Dk(e.startContainer)&&Dk(e.endContainer))},Bk=function(e,t,n,r){var o,i,a=B(e,r).selectorChangedWithUnbind,u=function(t,n){var o=e.createRng();t?(o.setStart(t,n),o.setEnd(t,n),b(o),h(!1)):(Ig(e,o,r.getBody(),!0),b(o))},c=function(e){return tk(r,e)},s=function(e,t){return Ck(r,e,t)},f=function(e){return YE(r.getBody(),y(),e)},l=function(e){return GE(r.getBody(),y(),e)},d=function(e,t){return O.getBookmark(e,t)},m=function(e){return O.moveToBookmark(e)},p=function(t,n){return ek(e,t,n).each(b),t},g=function(){var e=y(),t=v();return!(!e||e.item)&&(e.compareEndPoints?0===e.compareEndPoints("StartToEnd",e):!t||e.collapsed)},h=function(e){var t=y();t.collapse(!!e),b(t)},v=function(){return t.getSelection?t.getSelection():t.document.selection},y=function(){var n,a,u,c=function(e,t,n){try{return t.compareBoundaryPoints(e,n)}catch(r){return-1}};if(!t)return null;var s=t.document;if("undefined"==typeof s||null===s)return null;if(void 0!==r.bookmark&&uC(r)===!1){var f=Pb(r);if(f.isSome())return f.map(function(e){return Ww(r,[e])[0]}).getOr(s.createRange())}try{(n=v())&&!Eo(n.anchorNode)&&(a=n.rangeCount>0?n.getRangeAt(0):n.createRange?n.createRange():s.createRange())}catch(l){}return a=Ww(r,[a])[0],a||(a=s.createRange?s.createRange():s.body.createTextRange()),a.setStart&&9===a.startContainer.nodeType&&a.collapsed&&(u=e.getRoot(),a.setStart(u,0),a.setEnd(u,0)),o&&i&&(0===c(a.START_TO_START,a,o)&&0===c(a.END_TO_END,a,o)?a=i:(o=null,i=null)),a},b=function(e,t){var n;if(Ok(e)){var a=Ak(e)?e:null;if(a){i=null;try{a.select()}catch(u){}}else{var c=v(),s=r.fire("SetSelectionRange",{range:e,forward:t});if(e=s.range,c){i=e;try{c.removeAllRanges(),c.addRange(e)}catch(u){}t===!1&&c.extend&&(c.collapse(e.endContainer,e.endOffset),c.extend(e.startContainer,e.startOffset)),o=c.rangeCount>0?c.getRangeAt(0):null}e.collapsed||e.startContainer!==e.endContainer||!c.setBaseAndExtent||jn.ie||e.endOffset-e.startOffset<2&&e.startContainer.hasChildNodes()&&(n=e.startContainer.childNodes[e.startOffset],n&&"IMG"===n.tagName&&(c.setBaseAndExtent(e.startContainer,e.startOffset,e.endContainer,e.endOffset),c.anchorNode===e.startContainer&&c.focusNode===e.endContainer||c.setBaseAndExtent(n,0,n,1))),r.fire("AfterSetSelectionRange",{range:e,forward:t})}}},C=function(t){return s(e.getOuterHTML(t)),t},w=function(){return QE(r.getBody(),y())},x=function(t,n){return ZE(e,y(),t,n)},S=function(){var t=v();if(!t||!t.anchorNode||!t.focusNode)return!0;var n=e.createRng();n.setStart(t.anchorNode,t.anchorOffset),n.collapse(!0);var r=e.createRng();return r.setStart(t.focusNode,t.focusOffset),r.collapse(!0),n.compareBoundaryPoints(n.START_TO_START,r)<=0},N=function(){var t=y(),n=v();if(!kg(n)&&Mg(r)){var o=pk(e,t);return o.each(function(e){b(e,S())}),o.getOr(t)}return t},E=function(e,t){return a(e,t),D},k=function(){for(var t,n=e.getRoot();n&&"BODY"!==n.nodeName;){if(n.scrollHeight>n.clientHeight){t=n;break}n=n.parentNode}return t},_=function(e,t){return jE(r,e,t)},T=function(e,t){return b(KE(e,t,r.getDoc()))},R=function(){var e=y();return e.collapsed?ul.fromRangeStart(e).getClientRects()[0]:e.getBoundingClientRect()},A=function(){t=o=i=null,P.destroy()},D={bookmarkManager:null,controlSelection:null,dom:e,win:t,serializer:n,editor:r,collapse:h,setCursorLocation:u,getContent:c,setContent:s,getBookmark:d,moveToBookmark:m,select:p,isCollapsed:g,isForward:S,setNode:C,getNode:w,getSel:v,setRng:b,getRng:y,getStart:f,getEnd:l,getSelectedBlocks:x,normalize:N,selectorChanged:E,selectorChangedWithUnbind:a,getScrollContainer:k,scrollIntoView:_,placeCaretAt:T,getBoundingClientRect:R,destroy:A},O=xk(D),P=Tk(D,r);return D.bookmarkManager=O,D.controlSelection=P,D},Pk=function(e,t){Xe(t,function(t){e.attr(t,null)})},Lk=function(e,t,n){e.addNodeFilter("font",function(e){Xe(e,function(e){var r=t.parse(e.attr("style")),o=e.attr("color"),i=e.attr("face"),a=e.attr("size");o&&(r.color=o),i&&(r["font-family"]=i),a&&(r["font-size"]=n[parseInt(e.attr("size"),10)-1]),e.name="span",e.attr("style",t.serialize(r)),Pk(e,["color","face","size"])})})},Ik=function(e,t){e.addNodeFilter("strike",function(e){Xe(e,function(e){var n=t.parse(e.attr("style"));n["text-decoration"]="line-through",e.name="span",e.attr("style",t.serialize(n))})})},Mk=function(e,t){var n=ha();t.convert_fonts_to_spans&&Lk(e,n,er.explode(t.font_size_legacy_values)),Ik(e,n)},Fk=function(e,t){t.inline_styles&&Mk(e,t)},Uk=function(t){return new mc(function(n,r){var o=function(){r("Cannot convert "+t+" to Blob. Resource might not exist or is inaccessible.")};try{var i=new e.XMLHttpRequest;i.open("GET",t,!0),i.responseType="blob",i.onload=function(){200===this.status?n(this.response):o()},i.onerror=o,i.send()}catch(a){o()}})},zk=function(e){var t,n=decodeURIComponent(e).split(","),r=/data:([^;]+)/.exec(n[0]);return r&&(t=r[1]),{type:t,data:n[1]}},jk=function(t,n){var r;try{r=e.atob(n)}catch(o){return _e.none()}for(var i=new Uint8Array(r.length),a=0;a<i.length;a++)i[a]=r.charCodeAt(a);return _e.some(new e.Blob([i],{type:t}))},Hk=function(t){return new mc(function(n){var r=zk(t),o=r.type,i=r.data;jk(o,i).fold(function(){return n(new e.Blob([]))},n)})},Vk=function(e){return 0===e.indexOf("blob:")?Uk(e):0===e.indexOf("data:")?Hk(e):null},qk=function(t){return new mc(function(n){var r=new e.FileReader;r.onloadend=function(){n(r.result)},r.readAsDataURL(t)})},$k=0,Wk=function(e){return(e||"blobid")+$k++},Kk=function(e,t,n,r){var o,i;if(0===t.src.indexOf("blob:"))return i=e.getByUri(t.src),void(i?n({image:t,blobInfo:i}):Vk(t.src).then(function(r){qk(r).then(function(a){o=zk(a).data,i=e.create(Wk(),r,o),e.add(i),n({image:t,blobInfo:i})})},function(e){r(e)}));var a=zk(t.src),u=a.data,c=a.type;o=u,i=e.getByData(o,c),i?n({image:t,blobInfo:i}):Vk(t.src).then(function(r){i=e.create(Wk(),r,o),e.add(i),n({image:t,blobInfo:i})},function(e){r(e)})},Xk=function(e){return e?dt(e.getElementsByTagName("img")):[]},Yk=function(e,t,n,r){var o=e.padd_empty_with_br||t.insert;o&&n[r.name]?r.empty().append(new Zg("br",1)).shortEnded=!0:r.empty().append(new Zg("#text",3)).value=da},Gk=function(e){return Jk(e,"#text")&&e.firstChild.value===da},Jk=function(e,t){return e&&e.firstChild&&e.firstChild===e.lastChild&&e.firstChild.name===t},Qk=function(e,t){var n=e.getElementRule(t.name);return n&&n.paddEmpty},Zk=function(e,t,n,r){return r.isEmpty(t,n,function(t){return Qk(e,t)})},e_=function(e,t){return e&&(t[e.name]||"br"===e.name)},t_=function(e){return e.attr("data-mce-bogus")},n_=function(e){return e.attr("src")===jn.transparentSrc||e.attr("data-mce-placeholder")},r_=function(t,n){if(n.images_dataimg_filter){var r=new e.Image;return r.src=t.attr("src"),gt(t.attributes.map,function(e,t){r.setAttribute(t,e)}),n.images_dataimg_filter(r)}return!0},o_=function(e,t){var n=t.blob_cache,r=function(e){var r=e.attr("src");n_(e)||t_(e)||ih(r).filter(function(){return r_(e,t)}).bind(function(e){var t=e.type,r=e.data;return _e.from(n.getByData(r,t)).orThunk(function(){return jk(t,r).map(function(e){var t=n.create(Wk(),e,r);return n.add(t),t})})}).each(function(t){e.attr("src",t.blobUri())})};n&&e.addAttributeFilter("src",function(e){return Xe(e,r)})},i_=function(e,t){var n=e.schema;t.remove_trailing_brs&&e.addNodeFilter("br",function(e,r,o){var i,a,u,c,s,f,l,d,m=e.length,p=er.extend({},n.getBlockElements()),g=n.getNonEmptyElements(),h=n.getWhiteSpaceElements();for(p.body=1,i=0;i<m;i++)if(a=e[i],u=a.parent,p[a.parent.name]&&a===u.lastChild){for(s=a.prev;s;){if(f=s.name,"span"!==f||"bookmark"!==s.attr("data-mce-type")){if("br"!==f)break;if("br"===f){a=null;break}}s=s.prev}a&&(a.remove(),Zk(n,g,h,u)&&(l=n.getElementRule(u.name),l&&(l.removeEmpty?u.remove():l.paddEmpty&&Yk(t,o,p,u))))}else{for(c=a;u&&u.firstChild===c&&u.lastChild===c&&(c=u,!p[u.name]);)u=u.parent;c===u&&t.padd_empty_with_br!==!0&&(d=new Zg("#text",3),d.value=da,
a.replace(d))}}),e.addAttributeFilter("href",function(e){var n=e.length,r=function(e){var t=e.split(" ").filter(function(e){return e.length>0});return t.concat(["noopener"]).sort().join(" ")},o=function(e){var t=e?er.trim(e):"";return/\b(noopener)\b/g.test(t)?t:r(t)};if(!t.allow_unsafe_link_target)for(;n--;){var i=e[n];"a"===i.name&&"_blank"===i.attr("target")&&i.attr("rel",o(i.attr("rel")))}}),t.allow_html_in_named_anchor||e.addAttributeFilter("id,name",function(e){for(var t,n,r,o,i=e.length;i--;)if(o=e[i],"a"===o.name&&o.firstChild&&!o.attr("href")){r=o.parent,t=o.lastChild;do n=t.prev,r.insert(t,o),t=n;while(t)}}),t.fix_list_elements&&e.addNodeFilter("ul,ol",function(e){for(var t,n,r=e.length;r--;)if(t=e[r],n=t.parent,"ul"===n.name||"ol"===n.name)if(t.prev&&"li"===t.prev.name)t.prev.append(t);else{var o=new Zg("li",1);o.attr("style","list-style-type: none"),t.wrap(o)}}),t.validate&&n.getValidClasses()&&e.addAttributeFilter("class",function(e){for(var t,r,o,i,a,u,c,s=e.length,f=n.getValidClasses();s--;){for(t=e[s],r=t.attr("class").split(" "),a="",o=0;o<r.length;o++)i=r[o],c=!1,u=f["*"],u&&u[i]&&(c=!0),u=f[t.name],!c&&u&&u[i]&&(c=!0),c&&(a&&(a+=" "),a+=i);a.length||(a=null),t.attr("class",a)}}),o_(e,t)},a_=er.makeMap,u_=er.each,c_=er.explode,s_=er.extend,f_=function(e,t){void 0===t&&(t=o());var n={},r=[],i={},a={};e=e||{},e.validate=!("validate"in e)||e.validate,e.root_name=e.root_name||"body";var u=function(e){var n,r,o,i,a,u,s,f,l,d,m,p=a_("tr,td,th,tbody,thead,tfoot,table"),g=t.getNonEmptyElements(),h=t.getWhiteSpaceElements(),v=t.getTextBlockElements(),y=t.getSpecialElements();for(n=0;n<e.length;n++)if(r=e[n],r.parent&&!r.fixed)if(v[r.name]&&"li"===r.parent.name){for(d=r.next;d&&v[d.name];)d.name="li",d.fixed=!0,r.parent.insert(d,r.parent),d=d.next;r.unwrap(r)}else{for(i=[r],o=r.parent;o&&!t.isValidChild(o.name,r.name)&&!p[o.name];o=o.parent)i.push(o);if(o&&i.length>1){for(i.reverse(),a=u=c(i[0].clone()),l=0;l<i.length-1;l++){for(t.isValidChild(u.name,i[l].name)?(s=c(i[l].clone()),u.append(s)):s=u,f=i[l].firstChild;f&&f!==i[l+1];)m=f.next,s.append(f),f=m;u=s}Zk(t,g,h,a)?o.insert(r,i[0],!0):(o.insert(a,i[0],!0),o.insert(r,a)),o=i[0],(Zk(t,g,h,o)||Jk(o,"br"))&&o.empty().remove()}else if(r.parent){if("li"===r.name){if(d=r.prev,d&&("ul"===d.name||"ul"===d.name)){d.append(r);continue}if(d=r.next,d&&("ul"===d.name||"ul"===d.name)){d.insert(r,d.firstChild,!0);continue}r.wrap(c(new Zg("ul",1)));continue}t.isValidChild(r.parent.name,"div")&&t.isValidChild("div",r.name)?r.wrap(c(new Zg("div",1))):y[r.name]?r.empty().remove():r.unwrap()}}},c=function(e){var t,o,u;o=e.name,o in n&&(u=i[o],u?u.push(e):i[o]=[e]),t=r.length;for(;t--;)o=r[t].name,o in e.attributes.map&&(u=a[o],u?u.push(e):a[o]=[e]);return e},s=function(e,t){u_(c_(e),function(e){var r=n[e];r||(n[e]=r=[]),r.push(t)})},f=function(){var e=[];for(var t in n)n.hasOwnProperty(t)&&e.push({name:t,callbacks:n[t]});return e},l=function(e,t){u_(c_(e),function(e){var n;for(n=0;n<r.length;n++)if(r[n].name===e)return void r[n].callbacks.push(t);r.push({name:e,callbacks:[t]})})},d=function(){return[].concat(r)},m=function(o,c){var s,f,l,d,m,p,g,h,v,y=[],b=function(e){return e===!1?"":e===!0?"p":e};c=c||{},i={},a={};var C=s_(a_("script,style,head,html,body,title,meta,param"),t.getBlockElements()),w=t.getNonEmptyElements(),x=t.children,S=e.validate,N="forced_root_block"in c?c.forced_root_block:e.forced_root_block,E=b(N),k=t.getWhiteSpaceElements(),_=/^[ \t\r\n]+/,T=/[ \t\r\n]+$/,R=/[ \t\r\n]+/g,A=/^[ \t\r\n]+$/;h=k.hasOwnProperty(c.context)||k.hasOwnProperty(e.root_name);var D=function(){var n,r,o=I.firstChild,i=function(e){e&&(o=e.firstChild,o&&3===o.type&&(o.value=o.value.replace(_,"")),o=e.lastChild,o&&3===o.type&&(o.value=o.value.replace(T,"")))};if(t.isValidChild(I.name,E.toLowerCase())){for(;o;)n=o.next,3===o.type||1===o.type&&"p"!==o.name&&!C[o.name]&&!o.attr("data-mce-type")?r?r.append(o):(r=O(E,1),r.attr(e.forced_root_block_attrs),I.insert(r,o),r.append(o)):(i(r),r=null),o=n;i(r)}},O=function(e,t){var r,o=new Zg(e,t);return e in n&&(r=i[e],r?r.push(o):i[e]=[o]),o},B=function(e){var n,r,o,i,a=t.getBlockElements();for(n=e.prev;n&&3===n.type;){if(o=n.value.replace(T,""),o.length>0)return void(n.value=o);if(r=n.next){if(3===r.type&&r.value.length){n=n.prev;continue}if(!a[r.name]&&"script"!==r.name&&"style"!==r.name){n=n.prev;continue}}i=n.prev,n.remove(),n=i}},P=function(e){var t,n={};for(t in e)"li"!==t&&"p"!==t&&(n[t]=e[t]);return n},L=mh({validate:S,allow_html_data_urls:e.allow_html_data_urls,allow_script_urls:e.allow_script_urls,allow_conditional_comments:e.allow_conditional_comments,preserve_cdata:e.preserve_cdata,self_closing_elements:P(t.getSelfClosingElements()),cdata:function(e){v.append(O("#cdata",4)).value=e},text:function(e,t){var n;h||(e=e.replace(R," "),e_(v.lastChild,C)&&(e=e.replace(_,""))),0!==e.length&&(n=O("#text",3),n.raw=!!t,v.append(n).value=e)},comment:function(e){v.append(O("#comment",8)).value=e},pi:function(e,t){v.append(O(e,7)).value=t,B(v)},doctype:function(e){var t=v.append(O("#doctype",10));t.value=e,B(v)},start:function(e,n,o){var i,u,c,s,f=S?t.getElementRule(e):{};if(f){for(i=O(f.outputName||e,1),i.attributes=n,i.shortEnded=o,v.append(i),s=x[v.name],s&&x[i.name]&&!s[i.name]&&y.push(i),u=r.length;u--;)c=r[u].name,c in n.map&&(p=a[c],p?p.push(i):a[c]=[i]);C[e]&&B(i),o||(v=i),!h&&k[e]&&(h=!0)}},end:function(n){var r,o,i,a,u=S?t.getElementRule(n):{};if(u){if(C[n]&&!h){if(r=v.firstChild,r&&3===r.type)if(o=r.value.replace(_,""),o.length>0)r.value=o,r=r.next;else for(i=r.next,r.remove(),r=i;r&&3===r.type;)o=r.value,i=r.next,(0===o.length||A.test(o))&&(r.remove(),r=i),r=i;if(r=v.lastChild,r&&3===r.type)if(o=r.value.replace(T,""),o.length>0)r.value=o,r=r.prev;else for(i=r.prev,r.remove(),r=i;r&&3===r.type;)o=r.value,i=r.prev,(0===o.length||A.test(o))&&(r.remove(),r=i),r=i}if(h&&k[n]&&(h=!1),u.removeEmpty&&Zk(t,w,k,v))return a=v.parent,C[v.name]?v.empty().remove():v.unwrap(),void(v=a);u.paddEmpty&&(Gk(v)||Zk(t,w,k,v))&&Yk(e,c,C,v),v=v.parent}}},t),I=v=new Zg(c.context||e.root_name,11);if(L.parse(o,c.format),S&&y.length&&(c.context?c.invalid=!0:u(y)),E&&("body"===I.name||c.isRootContent)&&D(),!c.invalid){for(g in i)if(i.hasOwnProperty(g)){for(p=n[g],s=i[g],d=s.length;d--;)s[d].parent||s.splice(d,1);for(f=0,l=p.length;f<l;f++)p[f](s,g,c)}for(f=0,l=r.length;f<l;f++)if(p=r[f],p.name in a){for(s=a[p.name],d=s.length;d--;)s[d].parent||s.splice(d,1);for(d=0,m=p.callbacks.length;d<m;d++)p.callbacks[d](s,p.name,c)}}return I},p={schema:t,addAttributeFilter:l,getAttributeFilters:d,addNodeFilter:s,getNodeFilters:f,filterNode:c,parse:m};return i_(p,e),Fk(p,e),p},l_=function(e,t,n){e.addAttributeFilter("data-mce-tabindex",function(e,t){for(var n,r=e.length;r--;)n=e[r],n.attr("tabindex",n.attr("data-mce-tabindex")),n.attr(t,null)}),e.addAttributeFilter("src,href,style",function(e,r){for(var o,i,a=e.length,u="data-mce-"+r,c=t.url_converter,s=t.url_converter_scope;a--;)o=e[a],i=o.attr(u),void 0!==i?(o.attr(r,i.length>0?i:null),o.attr(u,null)):(i=o.attr(r),"style"===r?i=n.serializeStyle(n.parseStyle(i),o.name):c&&(i=c.call(s,i,r,o.name)),o.attr(r,i.length>0?i:null))}),e.addAttributeFilter("class",function(e){for(var t,n,r=e.length;r--;)t=e[r],n=t.attr("class"),n&&(n=t.attr("class").replace(/(?:^|\s)mce-item-\w+(?!\S)/g,""),t.attr("class",n.length>0?n:null))}),e.addAttributeFilter("data-mce-type",function(e,t,n){for(var r,o=e.length;o--;)if(r=e[o],"bookmark"===r.attr("data-mce-type")&&!n.cleanup){var i=_e.from(r.firstChild).exists(function(e){return!Hs(e.value)});i?r.unwrap():r.remove()}}),e.addNodeFilter("noscript",function(e){for(var t,n=e.length;n--;)t=e[n].firstChild,t&&(t.value=ea.decode(t.value))}),e.addNodeFilter("script,style",function(e,n){for(var r,o,i,a=e.length,u=function(e){return e.replace(/(<!--\[CDATA\[|\]\]-->)/g,"\n").replace(/^[\r\n]*|[\r\n]*$/g,"").replace(/^\s*((<!--)?(\s*\/\/)?\s*<!\[CDATA\[|(<!--\s*)?\/\*\s*<!\[CDATA\[\s*\*\/|(\/\/)?\s*<!--|\/\*\s*<!--\s*\*\/)\s*[\r\n]*/gi,"").replace(/\s*(\/\*\s*\]\]>\s*\*\/(-->)?|\s*\/\/\s*\]\]>(-->)?|\/\/\s*(-->)?|\]\]>|\/\*\s*-->\s*\*\/|\s*-->\s*)\s*$/g,"")};a--;)r=e[a],o=r.firstChild?r.firstChild.value:"","script"===n?(i=r.attr("type"),i&&r.attr("type","mce-no/type"===i?null:i.replace(/^mce\-/,"")),"xhtml"===t.element_format&&o.length>0&&(r.firstChild.value="// <![CDATA[\n"+u(o)+"\n// ]]>")):"xhtml"===t.element_format&&o.length>0&&(r.firstChild.value="<!--\n"+u(o)+"\n-->")}),e.addNodeFilter("#comment",function(e){for(var r,o=e.length;o--;)r=e[o],t.preserve_cdata&&0===r.value.indexOf("[CDATA[")?(r.name="#cdata",r.type=4,r.value=n.decode(r.value.replace(/^\[CDATA\[|\]\]$/g,""))):0===r.value.indexOf("mce:protected ")&&(r.name="#text",r.type=3,r.raw=!0,r.value=unescape(r.value).substr(14))}),e.addNodeFilter("xml:namespace,input",function(e,t){for(var n,r=e.length;r--;)n=e[r],7===n.type?n.remove():1===n.type&&("input"!==t||n.attr("type")||n.attr("type","text"))}),e.addAttributeFilter("data-mce-type",function(t){Xe(t,function(t){"format-caret"===t.attr("data-mce-type")&&(t.isEmpty(e.schema.getNonEmptyElements())?t.remove():t.unwrap())})}),e.addAttributeFilter("data-mce-src,data-mce-href,data-mce-style,data-mce-selected,data-mce-expando,data-mce-type,data-mce-resize,data-mce-placeholder",function(e,t){for(var n=e.length;n--;)e[n].attr(t,null)})},d_=function(e){var t=function(e){return e&&"br"===e.name},n=e.lastChild;if(t(n)){var r=n.prev;t(r)&&(n.remove(),r.remove())}},m_=function(t,n,r){var o,i,a=t.dom;n=n.cloneNode(!0);var u=e.document.implementation;return u.createHTMLDocument&&(o=u.createHTMLDocument(""),er.each("BODY"===n.nodeName?n.childNodes:[n],function(e){o.body.appendChild(o.importNode(e,!0))}),n="BODY"!==n.nodeName?o.body.firstChild:o.body,i=a.doc,a.doc=o),jS(t,It(It({},r),{node:n})),i&&(a.doc=i),n},p_=function(e,t){return e&&e.hasEventListeners("PreProcess")&&!t.no_events},g_=function(e,t,n){return p_(e,n)?m_(e,t,n):t},h_=function(e,t,n){er.inArray(t,n)===-1&&(e.addAttributeFilter(n,function(e,t){for(var n=e.length;n--;)e[n].attr(t,null)}),t.push(n))},v_=function(e,t,n){if(!t.no_events&&e){var r=HS(e,It(It({},t),{content:n}));return r.content}return n},y_=function(e,t,n){var r=Vs(n.getInner?t.innerHTML:e.getOuterHTML(t));return n.selection||Di(ar.fromDom(t))?r:er.trim(r)},b_=function(e,t,n){var r=n.selection?It({forced_root_block:!1},n):n,o=e.parse(t,r);return d_(o),o},C_=function(e,t,n){var r=nh(e,t);return r.serialize(n)},w_=function(e,t,n,r,o){var i=C_(t,n,r);return v_(e,o,i)},x_=function(e,n){var r=["data-mce-selected"],i=n&&n.dom?n.dom:Ac.DOM,a=n&&n.schema?n.schema:o(e);e.entity_encoding=e.entity_encoding||"named",e.remove_trailing_brs=!("remove_trailing_brs"in e)||e.remove_trailing_brs;var u=f_(e,a);l_(u,e,i);var c=function(t,r){void 0===r&&(r={});var o=It({format:"html"},r),c=g_(n,t,o),s=y_(i,c,o),f=b_(u,s,o);return"tree"===o.format?f:w_(n,e,a,f,o)};return{schema:a,addNodeFilter:u.addNodeFilter,addAttributeFilter:u.addAttributeFilter,serialize:c,addRules:function(e){a.addValidElements(e)},setRules:function(e){a.setValidElements(e)},addTempAttr:t(h_,u,r),getTempAttrs:function(){return r},getNodeFilters:u.getNodeFilters,getAttributeFilters:u.getAttributeFilters}},S_=function(e,t){var n=x_(e,t);return{schema:n.schema,addNodeFilter:n.addNodeFilter,addAttributeFilter:n.addAttributeFilter,serialize:n.serialize,addRules:n.addRules,setRules:n.setRules,addTempAttr:n.addTempAttr,getTempAttrs:n.getTempAttrs,getNodeFilters:n.getNodeFilters,getAttributeFilters:n.getAttributeFilters}},N_=0,E_=function(){var e=function(){return Math.round(4294967295*Math.random()).toString(36)},t=(new Date).getTime();return"s"+t.toString(36)+e()+e()+e()},k_=function(e){return e+N_++ +E_()},__=function(){var t=[],n=function(e){var t={"image/jpeg":"jpg","image/jpg":"jpg","image/gif":"gif","image/png":"png"};return t[e.toLowerCase()]||"dat"},r=function(e,t,n,r){if(Oe(e)){var i=e;return o({id:i,name:r,blob:t,base64:n})}if(Be(e))return o(e);throw new Error("Unknown input type")},o=function(t){if(!t.blob||!t.base64)throw new Error("blob and base64 representations of the image are required for BlobInfo to be created");var r=t.id||k_("blobid"),o=t.name||r;return{id:ve(r),name:ve(o),filename:ve(o+"."+n(t.blob.type)),blob:ve(t.blob),base64:ve(t.base64),blobUri:ve(t.blobUri||e.URL.createObjectURL(t.blob)),uri:ve(t.uri)}},i=function(e){u(e.id())||t.push(e)},a=function(e){return tt(t,e).getOrUndefined()},u=function(e){return a(function(t){return t.id()===e})},c=function(e){return a(function(t){return t.blobUri()===e})},s=function(e,t){return a(function(n){return n.base64()===e&&n.blob().type===t})},f=function(n){t=Je(t,function(t){return t.blobUri()!==n||(e.URL.revokeObjectURL(t.blobUri()),!1)})},l=function(){Xe(t,function(t){e.URL.revokeObjectURL(t.blobUri())}),t=[]};return{create:r,add:i,get:u,getByUri:c,getByData:s,findFirst:a,removeByUri:f,destroy:l}},T_=function(e){var t,n,r=__(),o=I(),i=[],a=function(t){return function(n){return e.selection?t(n):[]}},u=function(e){return e+(e.indexOf("?")===-1?"?":"&")+(new Date).getTime()},c=function(e,t,n){var r=0;do r=e.indexOf(t,r),r!==-1&&(e=e.substring(0,r)+n+e.substr(r+t.length),r+=n.length-t.length+1);while(r!==-1);return e},s=function(e,t,n){return e=c(e,'src="'+t+'"','src="'+n+'"'),e=c(e,'data-mce-src="'+t+'"','data-mce-src="'+n+'"')},f=function(t,n){Xe(e.undoManager.data,function(e){"fragmented"===e.type?e.fragments=Ke(e.fragments,function(e){return s(e,t,n)}):e.content=s(e.content,t,n)})},l=function(){return e.notificationManager.open({text:e.translate("Image uploading..."),type:"info",timeout:-1,progressBar:!0})},d=function(t,n){var r=e.convertURL(n,"src");f(t.src,n),e.$(t).attr({src:cd(e)?u(n):n,"data-mce-src":r})},m=function(n){return t||(t=L(o,{url:dd(e),basePath:md(e),credentials:pd(e),handler:gd(e)})),v().then(a(function(o){var i=Ke(o,function(e){return e.blobInfo});return t.upload(i,l).then(a(function(t){var i=Ke(t,function(t,n){var i=o[n].blobInfo,a=o[n].image;return t.status&&sd(e)?(r.removeByUri(a.src),d(a,t.url)):t.error&&nE(e,t.error),{element:a,status:t.status,uploadUri:t.url,blobInfo:i}});return n&&n(i),i}))}))},p=function(t){if(ud(e))return m(t)},g=function(t){if(it(i,function(e){return e(t)})===!1)return!1;if(0===t.getAttribute("src").indexOf("data:")){var n=ad(e);return n(t)}return!0},h=function(e){i.push(e)},v=function(){return n||(n=P(o,r)),n.findAll(e.getBody(),g).then(a(function(t){return t=Je(t,function(t){return"string"!=typeof t||(tE(e,t),!1)}),Xe(t,function(e){f(e.image.src,e.blobInfo.blobUri()),e.image.src=e.blobInfo.blobUri(),e.image.removeAttribute("data-mce-src")}),t}))},y=function(){r.destroy(),o.destroy(),n=t=null},b=function(t){return t.replace(/src="(blob:[^"]+)"/g,function(t,n){var i=o.getResultUri(n);if(i)return'src="'+i+'"';var a=r.getByUri(n);if(a||(a=Ze(e.editorManager.get(),function(e,t){return e||t.editorUpload&&t.editorUpload.blobCache.getByUri(n)},null)),a){var u=a.blob();return'src="data:'+u.type+";base64,"+a.base64()+'"'}return t})};return e.on("SetContent",function(){ud(e)?p():v()}),e.on("RawSaveContent",function(e){e.content=b(e.content)}),e.on("GetContent",function(e){e.source_view||"raw"===e.format||(e.content=b(e.content))}),e.on("PostRender",function(){e.parser.addNodeFilter("img",function(e){Xe(e,function(e){var t=e.attr("src");if(!r.getByUri(t)){var n=o.getResultUri(t);n&&e.attr("src",n)}})})}),{blobCache:r,addFilter:h,uploadImages:m,uploadImagesAuto:p,scanForImages:v,destroy:y}},R_=function(e,t){var n=Uc({});e.set({}),t.on("NodeChange",function(r){A_(t,r.element,n,e.get())})},A_=function(e,t,n,r){var o=mt(n.get()),i={},a={},u=Je(og(e.dom,t),function(e){return 1===e.nodeType&&!e.getAttribute("data-mce-bogus")});gt(r,function(t,n){er.each(u,function(r){return e.formatter.matchNode(r,n,{},t.similar)?(o.indexOf(n)===-1&&(Xe(t.callbacks,function(e){e(!0,{node:r,format:n,parents:u})}),i[n]=t.callbacks),a[n]=t.callbacks,!1):!EC(e,r,n)&&void 0})});var c=D_(n.get(),a,t,u);n.set(It(It({},i),c))},D_=function(e,t,n,r){return Ct(e,function(e,o){return!!Et(t,o)||(Xe(e,function(e){e(!1,{node:n,format:o,parents:r})}),!1)}).t},O_=function(e,t,n,r){var o=e.get();Xe(t.split(","),function(e){o[e]||(o[e]={similar:r,callbacks:[]}),o[e].callbacks.push(n)}),e.set(o)},B_=function(e,t,n){var r=e.get();Xe(t.split(","),function(e){r[e].callbacks=Je(r[e].callbacks,function(e){return e!==n}),0===r[e].callbacks.length&&delete r[e]}),e.set(r)},P_=function(e,t,n,r,o){return null===t.get()&&R_(t,e),O_(t,n,r,o),{unbind:function(){return B_(t,n,r)}}},L_=function(e){var t={valigntop:[{selector:"td,th",styles:{verticalAlign:"top"}}],valignmiddle:[{selector:"td,th",styles:{verticalAlign:"middle"}}],valignbottom:[{selector:"td,th",styles:{verticalAlign:"bottom"}}],alignleft:[{selector:"figure.image",collapsed:!1,classes:"align-left",ceFalseOverride:!0,preview:"font-family font-size"},{selector:"figure,p,h1,h2,h3,h4,h5,h6,td,th,tr,div,ul,ol,li",styles:{textAlign:"left"},inherit:!1,preview:!1,defaultBlock:"div"},{selector:"img,table",collapsed:!1,styles:{"float":"left"},preview:"font-family font-size"}],aligncenter:[{selector:"figure,p,h1,h2,h3,h4,h5,h6,td,th,tr,div,ul,ol,li",styles:{textAlign:"center"},inherit:!1,preview:"font-family font-size",defaultBlock:"div"},{selector:"figure.image",collapsed:!1,classes:"align-center",ceFalseOverride:!0,preview:"font-family font-size"},{selector:"img",collapsed:!1,styles:{display:"block",marginLeft:"auto",marginRight:"auto"},preview:!1},{selector:"table",collapsed:!1,styles:{marginLeft:"auto",marginRight:"auto"},preview:"font-family font-size"}],alignright:[{selector:"figure.image",collapsed:!1,classes:"align-right",ceFalseOverride:!0,preview:"font-family font-size"},{selector:"figure,p,h1,h2,h3,h4,h5,h6,td,th,tr,div,ul,ol,li",styles:{textAlign:"right"},inherit:!1,preview:"font-family font-size",defaultBlock:"div"},{selector:"img,table",collapsed:!1,styles:{"float":"right"},preview:"font-family font-size"}],alignjustify:[{selector:"figure,p,h1,h2,h3,h4,h5,h6,td,th,tr,div,ul,ol,li",styles:{textAlign:"justify"},inherit:!1,defaultBlock:"div",preview:"font-family font-size"}],bold:[{inline:"strong",remove:"all",preserve_attributes:["class","style"]},{inline:"span",styles:{fontWeight:"bold"}},{inline:"b",remove:"all",preserve_attributes:["class","style"]}],italic:[{inline:"em",remove:"all",preserve_attributes:["class","style"]},{inline:"span",styles:{fontStyle:"italic"}},{inline:"i",remove:"all",preserve_attributes:["class","style"]}],underline:[{inline:"span",styles:{textDecoration:"underline"},exact:!0},{inline:"u",remove:"all",preserve_attributes:["class","style"]}],strikethrough:[{inline:"span",styles:{textDecoration:"line-through"},exact:!0},{inline:"strike",remove:"all",preserve_attributes:["class","style"]}],forecolor:{inline:"span",styles:{color:"%value"},links:!0,remove_similar:!0,clear_child_styles:!0},hilitecolor:{inline:"span",styles:{backgroundColor:"%value"},links:!0,remove_similar:!0,clear_child_styles:!0},fontname:{inline:"span",toggle:!1,styles:{fontFamily:"%value"},clear_child_styles:!0},fontsize:{inline:"span",toggle:!1,styles:{fontSize:"%value"},clear_child_styles:!0},fontsize_class:{inline:"span",attributes:{"class":"%value"}},blockquote:{block:"blockquote",wrapper:!0,remove:"all"},subscript:{inline:"sub"},superscript:{inline:"sup"},code:{inline:"code"},link:{inline:"a",selector:"a",remove:"all",split:!0,deep:!0,onmatch:function(e,t,n){return ko(e)&&e.hasAttribute("href")},onformat:function(t,n,r){er.each(r,function(n,r){e.setAttrib(t,r,n)})}},removeformat:[{selector:"b,strong,em,i,font,u,strike,sub,sup,dfn,code,samp,kbd,var,cite,mark,q,del,ins",remove:"all",split:!0,expand:!1,block_expand:!0,deep:!0},{selector:"span",attributes:["style","class"],remove:"empty",split:!0,expand:!1,deep:!0},{selector:"*",attributes:["style","class"],split:!1,expand:!1,deep:!0}]};return er.each("p h1 h2 h3 h4 h5 h6 div address pre div dt dd samp".split(/\s/),function(e){t[e]={block:e,remove:"all"}}),t},I_=er.each,M_=Ac.DOM,F_=function(e,t){var n,r,i,a=t&&t.schema||o({}),u=function(e,t){t.classes.length&&M_.addClass(e,t.classes.join(" ")),M_.setAttribs(e,t.attrs)},c=function(e){r="string"==typeof e?{name:e,classes:[],attrs:{}}:e;var t=M_.create(r.name);return u(t,r),t},s=function(e,t){var n="string"!=typeof e?e.nodeName.toLowerCase():e,r=a.getElementRule(n),o=r&&r.parentsRequired;return!(!o||!o.length)&&(t&&er.inArray(o,t)!==-1?t:o[0])},f=function(e,t,n){var r,o,i=t.length>0&&t[0],a=i&&i.name,u=s(e,a);if(u)a===u?(o=t[0],t=t.slice(1)):o=u;else if(i)o=t[0],t=t.slice(1);else if(!n)return e;return o&&(r=c(o),r.appendChild(e)),n&&(r||(r=M_.create("div"),r.appendChild(e)),er.each(n,function(t){var n=c(t);r.insertBefore(n,e)})),f(r,t,o&&o.siblings)};return e&&e.length?(r=e[0],n=c(r),i=M_.create("div"),i.appendChild(f(n,e.slice(1),r.siblings)),i):""},U_=function(e){var t,n={classes:[],attrs:{}};return e=n.selector=er.trim(e),"*"!==e&&(t=e.replace(/(?:([#\.]|::?)([\w\-]+)|(\[)([^\]]+)\]?)/g,function(e,t,r,o,i){switch(t){case"#":n.attrs.id=r;break;case".":n.classes.push(r);break;case":":er.inArray("checked disabled enabled read-only required".split(" "),r)!==-1&&(n.attrs[r]=r)}if("["===o){var a=i.match(/([\w\-]+)(?:\=\"([^\"]+))?/);a&&(n.attrs[a[1]]=a[2])}return""})),n.name=t||"div",n},z_=function(e){return e&&"string"==typeof e?(e=e.split(/\s*,\s*/)[0],e=e.replace(/\s*(~\+|~|\+|>)\s*/g,"$1"),er.map(e.split(/(?:>|\s+(?![^\[\]]+\]))/),function(e){var t=er.map(e.split(/(?:~\+|~|\+)/),U_),n=t.pop();return t.length&&(n.siblings=t),n}).reverse()):[]},j_=function(e,t){var n,r,o,i="",a=Pd(e);if(""===a)return"";var u=function(e){return e.replace(/%(\w+)/g,"")};if("string"==typeof t){if(t=e.formatter.get(t),!t)return;t=t[0]}if("preview"in t){var c=Nt(t,"preview");if(c.is(!1))return"";a=c.getOr(a)}n=t.block||t.inline||"span";var s=z_(t.selector);s.length?(s[0].name||(s[0].name=n),n=t.selector,r=F_(s,e)):r=F_([n],e);var f=M_.select(n,r)[0]||r.firstChild;return I_(t.styles,function(e,t){e=u(e),e&&M_.setStyle(f,t,e)}),I_(t.attributes,function(e,t){e=u(e),e&&M_.setAttrib(f,t,e)}),I_(t.classes,function(e){e=u(e),M_.hasClass(f,e)||M_.addClass(f,e)}),e.fire("PreviewFormats"),M_.setStyles(r,{position:"absolute",left:-65535}),e.getBody().appendChild(r),o=M_.getStyle(e.getBody(),"fontSize",!0),o=/px$/.test(o)?parseInt(o,10):0,I_(a.split(" "),function(t){var n=M_.getStyle(f,t,!0);if(!("background-color"===t&&/transparent|rgba\s*\([^)]+,\s*0\)/.test(n)&&(n=M_.getStyle(e.getBody(),t,!0),"#ffffff"===M_.toHex(n).toLowerCase())||"color"===t&&"#000000"===M_.toHex(n).toLowerCase())){if("font-size"===t&&/em|%$/.test(n)){if(0===o)return;var r=parseFloat(n)/(/%$/.test(n)?100:1);n=r*o+"px"}"border"===t&&n&&(i+="padding:0 2px;"),i+=t+":"+n+";"}}),e.fire("AfterPreviewFormats"),M_.remove(r),i},H_=function(e){e.addShortcut("meta+b","","Bold"),e.addShortcut("meta+i","","Italic"),e.addShortcut("meta+u","","Underline");for(var t=1;t<=6;t++)e.addShortcut("access+"+t,"",["FormatBlock",!1,"h"+t]);e.addShortcut("access+7","",["FormatBlock",!1,"p"]),e.addShortcut("access+8","",["FormatBlock",!1,"div"]),e.addShortcut("access+9","",["FormatBlock",!1,"address"])},V_=function(e){var n=M(e),r=Uc(null);return H_(e),JC(e),{get:n.get,has:n.has,register:n.register,unregister:n.unregister,apply:function(t,n,r){DS(e,t,n,r)},remove:function(t,n,r,o){OS(e,t,n,r,o)},toggle:function(t,n,r){BS(e,t,n,r)},match:t(AC,e),matchAll:t(DC,e),matchNode:t(RC,e),canApply:t(OC,e),formatChanged:t(P_,e,r),getCssText:t(j_,e)}},q_=function(e,t,n){var r=Uc(!1),o=function(e){Jx(t,!1,n),t.add({},e)};e.on("init",function(){t.add()}),e.on("BeforeExecCommand",function(e){var r=e.command.toLowerCase();"undo"!==r&&"redo"!==r&&"mcerepaint"!==r&&(Qx(t,n),t.beforeChange())}),e.on("ExecCommand",function(e){var t=e.command.toLowerCase();"undo"!==t&&"redo"!==t&&"mcerepaint"!==t&&o(e)}),e.on("ObjectResizeStart cut",function(){t.beforeChange()}),e.on("SaveContent ObjectResized blur",o),e.on("dragend",o),e.on("keyup",function(n){var i=n.keyCode;n.isDefaultPrevented()||((i>=33&&i<=36||i>=37&&i<=40||45===i||n.ctrlKey)&&(o(),e.nodeChanged()),46!==i&&8!==i||e.nodeChanged(),r.get()&&t.typing&&Yx(Vx(e),t.data[0])===!1&&(e.isDirty()===!1&&(e.setDirty(!0),e.fire("change",{level:t.data[0],lastLevel:null})),e.fire("TypingUndo"),r.set(!1),e.nodeChanged()))}),e.on("keydown",function(e){var i=e.keyCode;if(!e.isDefaultPrevented()){if(i>=33&&i<=36||i>=37&&i<=40||45===i)return void(t.typing&&o(e));var a=e.ctrlKey&&!e.altKey||e.metaKey;!(i<16||i>20)||224===i||91===i||t.typing||a||(t.beforeChange(),Jx(t,!0,n),t.add({},e),r.set(!0))}}),e.on("mousedown",function(e){t.typing&&o(e)});var i=function(e){return"insertReplacementText"===e.inputType},a=function(e){return"insertText"===e.inputType&&null===e.data},u=function(e){return"insertFromPaste"===e.inputType||"insertFromDrop"===e.inputType};e.on("input",function(e){e.inputType&&(i(e)||a(e)||u(e))&&o(e)}),e.on("AddUndo Undo Redo ClearUndos",function(t){t.isDefaultPrevented()||e.nodeChanged()})},$_=function(e){e.addShortcut("meta+z","","Undo"),e.addShortcut("meta+y,meta+shift+z","","Redo")},W_=function(e){var t=Uc(_e.none()),n=Uc(0),r=Uc(0),o={data:[],typing:!1,beforeChange:function(){CS(e,n,t)},add:function(i,a){return wS(e,o,r,n,t,i,a)},undo:function(){return xS(e,o,n,r)},redo:function(){return SS(e,r,o.data)},clear:function(){NS(e,o,r)},reset:function(){ES(e,o)},hasUndo:function(){return kS(e,o,r)},hasRedo:function(){return _S(e,o,r)},transact:function(t){return TS(e,o,n,t)},ignore:function(t){RS(e,n,t)},extra:function(t,n){AS(e,o,r,t,n)}};return hS(e)||q_(e,o,n),$_(e),o},K_=[9,27,Nk.HOME,Nk.END,19,20,44,144,145,33,34,45,16,17,18,91,92,93,Nk.DOWN,Nk.UP,Nk.LEFT,Nk.RIGHT].concat(jn.browser.isFirefox()?[224]:[]),X_="data-mce-placeholder",Y_=function(e){return"keydown"===e.type||"keyup"===e.type},G_=function(e){var t=e.keyCode;return t===Nk.BACKSPACE||t===Nk.DELETE},J_=function(e){if(Y_(e)){var t=e.keyCode;return!G_(e)&&(Nk.metaKeyPressed(e)||e.altKey||t>=112&&t<=123||$e(K_,t))}return!1},Q_=function(e){return Y_(e)&&!(G_(e)||"keyup"===e.type&&229===e.keyCode)},Z_=function(e,t,n){if(qh(ar.fromDom(t),!1)){var r=""===n,o=t.firstElementChild;return!o||!e.getStyle(t.firstElementChild,"padding-left")&&!e.getStyle(t.firstElementChild,"padding-right")&&(r?!e.isBlock(o):n===o.nodeName.toLowerCase())}return!1},eT=function(e){var t=e.dom,n=Ql(e),r=_d(e),o=function(i,a){if(!J_(i)){var u=e.getBody(),c=!Q_(i)&&Z_(t,u,n),s=""!==t.getAttrib(u,X_);(s!==c||a)&&(t.setAttrib(u,X_,c?r:null),t.setAttrib(u,"aria-placeholder",c?r:null),JS(e,c),e.on(c?"keydown":"keyup",o),e.off(c?"keyup":"keydown",o))}};r&&e.on("init",function(t){o(t,!0),e.on("change SetContent ExecCommand",o),e.on("paste",function(t){return Cc.setEditorTimeout(e,function(){return o(t)})})})},tT=5,nT=400,rT=function(e){return void 0===e.touches||1!==e.touches.length?_e.none():_e.some(e.touches[0])},oT=function(e,t){var n=Math.abs(e.clientX-t.x()),r=Math.abs(e.clientY-t.y());return n>tT||r>tT},iT=function(e){var t=Uc(_e.none()),n=Uc(!1),r=ts(function(t){e.fire("longpress",It(It({},t),{type:"longpress"})),n.set(!0)},nT);e.on("touchstart",function(e){rT(e).each(function(o){r.cancel();var i={x:ve(o.clientX),y:ve(o.clientY),target:ve(e.target)};r.throttle(e),n.set(!1),t.set(_e.some(i))})},!0),e.on("touchmove",function(o){r.cancel(),rT(o).each(function(r){t.get().each(function(o){oT(r,o)&&(t.set(_e.none()),n.set(!1),e.fire("longpresscancel"))})})},!0),e.on("touchend touchcancel",function(o){r.cancel(),"touchcancel"!==o.type&&t.get().filter(function(e){return e.target().isEqualNode(o.target)}).each(function(){n.get()?o.preventDefault():e.fire("tap",It(It({},o),{type:"tap"}))})},!0)},aT=function(e,t){return e.hasOwnProperty(t.nodeName)},uT=function(e,t){return!!Io(t)||!!ko(t)&&(!aT(e,t)&&!zp(t))},cT=function(e,t,n){return We(Jh(ar.fromDom(n),ar.fromDom(t)),function(t){return aT(e,t.dom())})},sT=function(e,t){if(Io(t)){if(0===t.nodeValue.length)return!0;if(/^\s+$/.test(t.nodeValue)&&(!t.nextSibling||aT(e,t.nextSibling)))return!0}return!1},fT=function(e){var t,n,r,o=e.dom,i=e.selection,a=e.schema,u=a.getBlockElements(),c=i.getStart(),s=e.getBody(),f=Ql(e);if(c&&ko(c)&&f){var l=s.nodeName.toLowerCase();if(a.isValidChild(l,f.toLowerCase())&&!cT(u,s,c)){var d=i.getRng(),m=d.startContainer,p=d.startOffset,g=d.endContainer,h=d.endOffset,v=uC(e);for(c=s.firstChild;c;)if(uT(u,c)){if(sT(u,c)){n=c,c=c.nextSibling,o.remove(n);continue}t||(t=o.create(f,Zl(e)),c.parentNode.insertBefore(t,c),r=!0),n=c,c=c.nextSibling,t.appendChild(n)}else t=null,c=c.nextSibling;r&&v&&(d.setStart(m,p),d.setEnd(g,h),i.setRng(d),e.nodeChanged())}}},lT=function(e){Ql(e)&&e.on("NodeChange",t(fT,e))},dT=function(e){return Fe(e.selection.getSel().modify)},mT=function(e,t,n){var r=e?1:-1;return t.setRng(ul(n.container(),n.offset()+r).toRange()),t.getSel().modify("move",e?"forward":"backward","word"),!0},pT=function(e,t){var n=t.selection.getRng(),r=e?ul.fromRangeEnd(n):ul.fromRangeStart(n);return!!dT(t)&&(e&&Js(r)?mT(!0,t.selection,r):!(e||!Qs(r))&&mT(!1,t.selection,r))},gT=Io,hT=function(e){return gT(e)&&e.data[0]===js},vT=function(e){return gT(e)&&e.data[e.data.length-1]===js},yT=function(e){return e.ownerDocument.createTextNode(js)},bT=function(e){if(gT(e.previousSibling))return vT(e.previousSibling)?e.previousSibling:(e.previousSibling.appendData(js),e.previousSibling);if(gT(e))return hT(e)?e:(e.insertData(0,js),e);var t=yT(e);return e.parentNode.insertBefore(t,e),t},CT=function(e){if(gT(e.nextSibling))return hT(e.nextSibling)?e.nextSibling:(e.nextSibling.insertData(0,js),e.nextSibling);if(gT(e))return vT(e)?e:(e.appendData(js),e);var t=yT(e);return e.nextSibling?e.parentNode.insertBefore(t,e.nextSibling):e.parentNode.appendChild(t),t},wT=function(e,t){return e?bT(t):CT(t)},xT=t(wT,!0),ST=t(wT,!1),NT=function(e,t){return Io(e.container())?wT(t,e.container()):wT(t,e.getNode())},ET=function(e,t){var n=t.get();return n&&e.container()===n&&Ks(n)},kT=function(e,t){return t.fold(function(t){sm(e.get());var n=xT(t);return e.set(n),_e.some(ul(n,n.length-1))},function(t){return gp(t).map(function(t){if(ET(t,e))return ul(e.get(),1);sm(e.get());var n=NT(t,!0);return e.set(n),ul(n,1)})},function(t){return hp(t).map(function(t){if(ET(t,e))return ul(e.get(),e.get().length-1);sm(e.get());var n=NT(t,!1);return e.set(n),ul(n,n.length-1)})},function(t){sm(e.get());var n=ST(t);return e.set(n),_e.some(ul(n,1))})},_T=/[\u0591-\u07FF\uFB1D-\uFDFF\uFE70-\uFEFC]/,TT=function(e){return _T.test(e)},RT=function(e,t){return Nr(ar.fromDom(t),Nd(e))},AT=function(e){return"rtl"===Ac.DOM.getStyle(e,"direction",!0)||TT(e.textContent)},DT=function(e,t,n){return Je(Ac.DOM.getParents(n.container(),"*",t),e)},OT=function(e,t,n){var r=DT(e,t,n);return _e.from(r[r.length-1])},BT=function(e,t,n){var r=Tm(t,e),o=Tm(n,e);return r&&r===o},PT=function(e){return Js(e)||Qs(e)},LT=function(e,t){if(!t)return t;var n=t.container(),r=t.offset();return e?Ks(n)?Io(n.nextSibling)?ul(n.nextSibling,0):ul.after(n):Js(t)?ul(n,r+1):t:Ks(n)?Io(n.previousSibling)?ul(n.previousSibling,n.previousSibling.data.length):ul.before(n):Qs(t)?ul(n,r-1):t},IT=t(LT,!0),MT=t(LT,!1),FT=function(e,t){for(var n=0;n<e.length;n++){var r=e[n].apply(null,t);if(r.isSome())return r}return _e.none()},UT=fc.generate([{before:["element"]},{start:["element"]},{end:["element"]},{after:["element"]}]),zT=function(e,t){var n=Tm(t,e);return n?n:e},jT=function(e,n,r){var o=IT(r),i=zT(n,o.container());return OT(e,i,o).fold(function(){return mp(i,o).bind(t(OT,e,i)).map(function(e){return UT.before(e)})},_e.none)},HT=function(e,t){return null===bp(e,t)},VT=function(e,n,r){return OT(e,n,r).filter(t(HT,n))},qT=function(e,t,n){var r=MT(n);return VT(e,t,r).bind(function(e){var t=pp(e,r);return t.isNone()?_e.some(UT.start(e)):_e.none()})},$T=function(e,t,n){var r=IT(n);return VT(e,t,r).bind(function(e){var t=mp(e,r);return t.isNone()?_e.some(UT.end(e)):_e.none()})},WT=function(e,n,r){var o=MT(r),i=zT(n,o.container());return OT(e,i,o).fold(function(){return pp(i,o).bind(t(OT,e,i)).map(function(e){
return UT.after(e)})},_e.none)},KT=function(e){return AT(YT(e))===!1},XT=function(e,t,n){var r=FT([jT,qT,$T,WT],[e,t,n]);return r.filter(KT)},YT=function(e){return e.fold(ye,ye,ye,ye)},GT=function(e){return e.fold(ve("before"),ve("start"),ve("end"),ve("after"))},JT=function(e){return e.fold(UT.before,UT.before,UT.after,UT.after)},QT=function(e){return e.fold(UT.start,UT.start,UT.end,UT.end)},ZT=function(e,t){return GT(e)===GT(t)&&YT(e)===YT(t)},eR=function(e,t,n,r,o,i){return cf(OT(t,n,r),OT(t,n,o),function(t,r){return t!==r&&BT(n,t,r)?UT.after(e?t:r):i}).getOr(i)},tR=function(e,t){return e.fold(ve(!0),function(e){return!ZT(e,t)})},nR=function(e,n,r,o,i){var a=LT(e,i),u=sp(e,r,a).map(t(LT,e)),c=u.fold(function(){return o.map(JT)},function(i){return XT(n,r,i).map(t(eR,e,n,r,a,i)).filter(t(tR,o))});return c.filter(KT)},rR=function(e,t){return e?t.fold(ge(_e.some,UT.start),_e.none,ge(_e.some,UT.after),_e.none):t.fold(_e.none,ge(_e.some,UT.before),_e.none,ge(_e.some,UT.end))},oR=function(e,n,r,o){var i=LT(e,o),a=XT(n,r,i);return XT(n,r,i).bind(t(rR,e)).orThunk(function(){return nR(e,n,r,a,o)})},iR=(t(oR,!1),t(oR,!0),function(e,t){var n=e.dom.createRng();n.setStart(t.container(),t.offset()),n.setEnd(t.container(),t.offset()),e.selection.setRng(n)}),aR=function(e,t){e?t.setAttribute("data-mce-selected","inline-boundary"):t.removeAttribute("data-mce-selected")},uR=function(e,t,n){return kT(t,n).map(function(t){return iR(e,t),n})},cR=function(e,n,r){var o=e.getBody(),i=ul.fromRangeStart(e.selection.getRng()),a=t(RT,e),u=oR(r,a,o,i);return u.bind(function(t){return uR(e,n,t)})},sR=function(e,n,r){var o=Ke(ps(ar.fromDom(n.getRoot()),'*[data-mce-selected="inline-boundary"]'),function(e){return e.dom()}),i=Je(o,e),a=Je(r,e);Xe(ut(i,a),t(aR,!1)),Xe(ut(a,i),t(aR,!0))},fR=function(e,t){if(e.selection.isCollapsed()&&e.composing!==!0&&t.get()){var n=ul.fromRangeStart(e.selection.getRng());ul.isTextPosition(n)&&PT(n)===!1&&(iR(e,cm(t.get(),n)),t.set(null))}},lR=function(e,t,n,r){if(t.selection.isCollapsed()){var o=Je(r,e);Xe(o,function(r){var o=ul.fromRangeStart(t.selection.getRng());XT(e,t.getBody(),o).bind(function(e){return uR(t,n,e)})})}},dR=function(e,t,n){return function(){return!!Od(e)&&cR(e,t,n).isSome()}},mR=function(e,t,n){return function(){return!!Od(t)&&pT(e,t)}},pR=function(e){var n=Uc(null),r=t(RT,e);return e.on("NodeChange",function(t){!Od(e)||jn.browser.isIE()&&t.initial||(sR(r,e.dom,t.parents),fR(e,n),lR(r,e,n,t.parents))}),n},gR=t(mR,!0),hR=t(mR,!1);!function(e){e[e.Br=0]="Br",e[e.Block=1]="Block",e[e.Wrap=2]="Wrap",e[e.Eol=3]="Eol"}(wk||(wk={}));var vR,yR=function(e,t){return e===al.Backwards?at(t):t},bR=function(e,t,n){return e===al.Forwards?t.next(n):t.prev(n)},CR=function(e,t,n,r){return zo(r.getNode(t===al.Forwards))?wk.Br:Rm(n,r)===!1?wk.Block:wk.Wrap},wR=function(e,t,n,r){for(var o,i=tp(n),a=r,u=[];a&&(o=bR(t,i,a));){if(zo(o.getNode(!1)))return t===al.Forwards?{positions:yR(t,u).concat([o]),breakType:wk.Br,breakAt:_e.some(o)}:{positions:yR(t,u),breakType:wk.Br,breakAt:_e.some(o)};if(o.isVisible()){if(e(a,o)){var c=CR(n,t,a,o);return{positions:yR(t,u),breakType:c,breakAt:_e.some(o)}}u.push(o),a=o}else a=o}return{positions:yR(t,u),breakType:wk.Eol,breakAt:_e.none()}},xR=function(e,t,n,r){return t(n,r).breakAt.map(function(r){var o=t(n,r).positions;return e===al.Backwards?o.concat(r):[r].concat(o)}).getOr([])},SR=function(e,t){return Ze(e,function(e,n){return e.fold(function(){return _e.some(n)},function(r){return cf(ft(r.getClientRects()),ft(n.getClientRects()),function(e,o){var i=Math.abs(t-e.left),a=Math.abs(t-o.left);return a<=i?n:r}).or(e)})},_e.none())},NR=function(e,t){return ft(t.getClientRects()).bind(function(t){return SR(e,t.left)})},ER=t(wR,E.isAbove,-1),kR=t(wR,E.isBelow,1),_R=function(e,t){return ER(e,t).breakAt.isNone()},TR=function(e,t){return kR(e,t).breakAt.isNone()},RR=t(xR,-1,ER),AR=t(xR,1,kR),DR=function(e){return gp(e).map(function(t){return[t].concat(kR(e,t).positions)}).getOr([])},OR=function(e){return hp(e).map(function(t){return ER(e,t).positions.concat(t)}).getOr([])},BR=function(e){var t=function(t){return Ke(t,function(t){return t=df(t),t.node=e,t})};if(ko(e))return t(e.getClientRects());if(Io(e)){var n=e.ownerDocument.createRange();return n.setStart(e,0),n.setEnd(e,e.data.length),t(n.getClientRects())}},PR=function(e){return ot(e,BR)};!function(e){e[e.Up=-1]="Up",e[e.Down=1]="Down"}(vR||(vR={}));var LR,IR,MR=function(e,t,n,r){for(;r=_m(r,e,Uf,t);)if(n(r))return},FR=function(e,t,n,r,o,i){var a=0,u=[],c=function(r){var i,c,f;for(f=PR([r]),e===-1&&(f=f.reverse()),i=0;i<f.length;i++)if(c=f[i],!n(c,s)){if(u.length>0&&t(c,Lt(u))&&a++,c.line=a,o(c))return!0;u.push(c)}},s=Lt(i.getClientRects());if(!s)return u;var f=i.getNode();return c(f),MR(e,r,c,f),u},UR=function(e,t){return t.line>e},zR=function(e,t){return t.line===e},jR=t(FR,vR.Up,hf,vf),HR=t(FR,vR.Down,vf,hf),VR=function(e,t,n,r){var o,i,a,u,c,s=tp(t),f=[],l=0,d=function(t){return Lt(1===e?t.getClientRects():t.getClientRects())};1===e?(o=s.next,i=vf,a=hf,u=ul.after(r)):(o=s.prev,i=hf,a=vf,u=ul.before(r));var m=d(u);do if(u.isVisible()&&(c=d(u),!a(c,m))){if(f.length>0&&i(c,Lt(f))&&l++,c=df(c),c.position=u,c.line=l,n(c))return f;f.push(c)}while(u=o(u));return f},qR=function(e){return function(t){return UR(e,t)}},$R=function(e){return function(t){return zR(e,t)}},WR=Ho,KR=_m,XR=function(e,t){return Math.abs(e.left-t)},YR=function(e,t){return Math.abs(e.right-t)},GR=function(e,t){return e>=t.left&&e<=t.right},JR=function(e,t){return e>=t.top&&e<=t.bottom},QR=function(e,t){return Bt(e,function(e,n){var r=Math.min(XR(e,t),YR(e,t)),o=Math.min(XR(n,t),YR(n,t));return GR(t,n)?n:GR(t,e)?e:o===r&&WR(n.node)?n:o<r?n:e})},ZR=function(e,t,n,r,o){var i=KR(r,e,Uf,t,!o);do if(!i||n(i))return;while(i=KR(i,e,Uf,t))},eA=function(e,n,r){void 0===r&&(r=!0);var o=[],i=function(e,t){var r=Je(PR([t]),function(t){return!e(t,n)});return o=o.concat(r),0===r.length};return o.push(n),ZR(vR.Up,e,t(i,hf),n.node,r),ZR(vR.Down,e,t(i,vf),n.node,r),o},tA=function(e){return Je(dt(e.getElementsByTagName("*")),vm)},nA=function(e,t){return{node:e.node,before:XR(e,t)<YR(e,t)}},rA=function(e,n,r){var o=PR(tA(e)),i=Je(o,t(JR,r)),a=QR(i,n);if(a){var u=!Bo(a.node);if(a=QR(eA(e,a,u),n),a&&vm(a.node))return nA(a,n)}return null},oA=jo,iA=Ho,aA=function(e,t,n,r,o){return t._selectionOverrides.showCaret(e,n,r,o)},uA=function(e){var t=e.ownerDocument.createRange();return t.selectNode(e),t},cA=function(e,t){var n=e.fire("BeforeObjectSelected",{target:t});return n.isDefaultPrevented()?null:uA(t)},sA=function(e,t,n){var r=Im(1,e.getBody(),t),o=ul.fromRangeStart(r),i=o.getNode();if(iA(i))return aA(1,e,i,!o.isAtEnd(),!1);var a=o.getNode(!0);if(iA(a))return aA(1,e,a,!1,!1);var u=e.dom.getParent(o.getNode(),function(e){return iA(e)||oA(e)});return iA(u)?aA(1,e,u,!1,n):null},fA=function(e,t,n){if(!t||!t.collapsed)return t;var r=sA(e,t,n);return r?r:t},lA=Ho,dA=bf,mA=function(e,t,n,r){var o=e===al.Forwards,i=o?Bh:Ph;if(!r.collapsed){var a=dA(r);if(lA(a))return aA(e,t,a,e===al.Backwards,!0)}var u=af(r),c=Fm(e,t.getBody(),r);if(i(c))return cA(t,c.getNode(!o));var s=LT(o,n(c));if(!s)return u?r:null;if(i(s))return aA(e,t,s.getNode(!o),o,!0);var f=n(s);return f&&i(f)&&Hm(s,f)?aA(e,t,f.getNode(!o),o,!0):u?fA(t,s.toRange(),!0):null},pA=function(e,t,n,r){var o,i,a,u;u=dA(r);var c=Fm(e,t.getBody(),r),s=n(t.getBody(),qR(1),c),f=Je(s,$R(1)),l=Lt(c.getClientRects());if((Bh(c)||Dh(c))&&(u=c.getNode()),(Ph(c)||Oh(c))&&(u=c.getNode(!0)),!l)return null;var d=l.left;if(o=QR(f,d),o&&lA(o.node))return i=Math.abs(d-o.left),a=Math.abs(d-o.right),aA(e,t,o.node,i<a,!0);if(u){var m=VR(e,t.getBody(),qR(1),u);if(o=QR(Je(m,$R(1)),d))return fA(t,o.position.toRange(),!0);if(o=Lt(Je(m,$R(0))))return fA(t,o.position.toRange(),!0)}},gA=function(e){var t=e.dom.create(Ql(e));return(!jn.ie||jn.ie>=11)&&(t.innerHTML='<br data-mce-bogus="1">'),t},hA=function(e,n,r){var o,i,a,u=tp(e.getBody()),c=t(jm,u.next),s=t(jm,u.prev);if(r.collapsed&&Vd(e)){if(o=e.dom.getParent(r.startContainer,"PRE"),!o)return;i=1===n?c(ul.fromRangeStart(r)):s(ul.fromRangeStart(r)),i||(a=gA(e),1===n?e.$(o).after(a):e.$(o).before(a),e.selection.select(a,!0),e.selection.collapse())}},vA=function(e,n){var r,o=tp(e.getBody()),i=t(jm,o.next),a=t(jm,o.prev),u=n?al.Forwards:al.Backwards,c=n?i:a,s=e.selection.getRng();return(r=mA(u,e,c,s))?r:(r=hA(e,u,s),r?r:null)},yA=function(e,t){var n,r=t?1:-1,o=t?HR:jR,i=e.selection.getRng();return(n=pA(r,e,o,i))?n:(n=hA(e,r,i),n?n:null)},bA=function(e,t){return function(){var n=vA(e,t);return!!n&&(e.selection.setRng(n),!0)}},CA=function(e,t){return function(){var n=yA(e,t);return!!n&&(e.selection.setRng(n),!0)}},wA=function(e){return function(t){return e?Ph(t):Bh(t)}},xA=function(e,t){return function(){var n=t?ul.fromRangeEnd(e.selection.getRng()):ul.fromRangeStart(e.selection.getRng()),r=t?kR(e.getBody(),n):ER(e.getBody(),n),o=t?lt(r.positions):ft(r.positions);return o.filter(wA(t)).fold(ve(!1),function(t){return e.selection.setRng(t.toRange()),!0})}},SA=function(e,t){return{left:e.left-t,top:e.top-t,right:e.right+2*t,bottom:e.bottom+2*t,width:e.width+t,height:e.height+t}},NA=function(e,t){return ot(t,function(t){var n=SA(df(t.getBoundingClientRect()),-1);return[{x:n.left,y:e(n),cell:t},{x:n.right,y:e(n),cell:t}]})},EA=function(e,t,n){return Ze(e,function(e,r){return e.fold(function(){return _e.some(r)},function(e){var o=Math.sqrt(Math.abs(e.x-t)+Math.abs(e.y-n)),i=Math.sqrt(Math.abs(r.x-t)+Math.abs(r.y-n));return _e.some(i<o?r:e)})},_e.none())},kA=function(e,t,n,r,o){var i=ps(ar.fromDom(n),"td,th,caption").map(function(e){return e.dom()}),a=Je(NA(e,i),function(e){return t(e,o)});return EA(a,r,o).map(function(e){return e.cell})},_A=function(e){return e.bottom},TA=function(e){return e.top},RA=function(e,t){return e.y<t},AA=function(e,t){return e.y>t},DA=t(kA,_A,RA),OA=t(kA,TA,AA),BA=function(e,t){return ft(t.getClientRects()).bind(function(t){return DA(e,t.left,t.top)}).bind(function(e){return NR(OR(e),t)})},PA=function(e,t){return lt(t.getClientRects()).bind(function(t){return OA(e,t.left,t.top)}).bind(function(e){return NR(DR(e),t)})},LA=function(e,t){e.selection.setRng(t),HE(e,t)},IA=function(e,t,n){return n.breakAt.map(function(n){return e(t,n).breakAt.isSome()}).getOr(!1)},MA=function(e){return e.breakType===wk.Wrap&&0===e.positions.length},FA=function(e){return e.breakType===wk.Br&&1===e.positions.length},UA=function(e,t,n){var r=e(t,n);return MA(r)||!zo(n.getNode())&&FA(r)?!IA(e,t,r):r.breakAt.isNone()},zA=t(UA,ER),jA=t(UA,kR),HA=function(e,t,n){var r=ul.fromRangeStart(t);return dp(!e,n).map(function(e){return e.isEqual(r)}).getOr(!1)},VA=function(e,t,n,r){var o=e.selection.getRng(),i=t?1:-1;if(hm()&&HA(t,o,n)){var a=aA(i,e,n,!t,!0);return LA(e,a),!0}return!1},qA=function(e,t,n){return BA(t,n).orThunk(function(){return ft(n.getClientRects()).bind(function(n){return SR(RR(e,ul.before(t)),n.left)})}).getOr(ul.before(t))},$A=function(e,t,n){return PA(t,n).orThunk(function(){return ft(n.getClientRects()).bind(function(n){return SR(AR(e,ul.after(t)),n.left)})}).getOr(ul.after(t))},WA=function(e,t){var n=t.getNode(e);return ko(n)&&"TABLE"===n.nodeName?_e.some(n):_e.none()},KA=function(e,t,n,r){var o=Ql(t);o?t.undoManager.transact(function(){var r=ar.fromTag(o);Wo(r,Zl(t)),ro(r,ar.fromTag("br")),e?to(ar.fromDom(n),r):eo(ar.fromDom(n),r);var i=t.dom.createRng();i.setStart(r.dom(),0),i.setEnd(r.dom(),0),LA(t,i)}):LA(t,r.toRange())},XA=function(e,t,n){var r=t?WA(!0,n):WA(!1,n),o=t===!1;r.fold(function(){return LA(e,n.toRange())},function(r){return dp(o,e.getBody()).filter(function(e){return e.isEqual(n)}).fold(function(){return LA(e,n.toRange())},function(o){return KA(t,e,r,n)})})},YA=function(e,t,n,r){var o=e.selection.getRng(),i=ul.fromRangeStart(o),a=e.getBody();if(!t&&zA(r,i)){var u=qA(a,n,i);return XA(e,t,u),!0}if(t&&jA(r,i)){var u=$A(a,n,i);return XA(e,t,u),!0}return!1},GA=function(e,t){return function(){return _e.from(e.dom.getParent(e.selection.getNode(),"td,th")).bind(function(n){return _e.from(e.dom.getParent(n,"table")).map(function(n){return VA(e,t,n)})}).getOr(!1)}},JA=function(e,t){return function(){return _e.from(e.dom.getParent(e.selection.getNode(),"td,th")).bind(function(n){return _e.from(e.dom.getParent(n,"table")).map(function(r){return YA(e,t,r,n)})}).getOr(!1)}},QA=function(e){return $e(["figcaption"],dr(e))},ZA=function(t){var n=e.document.createRange();return n.setStartBefore(t.dom()),n.setEndBefore(t.dom()),n},eD=function(e,t,n){n?ro(e,t):no(e,t)},tD=function(e,t){var n=ar.fromTag("br");return eD(e,n,t),ZA(n)},nD=function(e,t,n,r){var o=ar.fromTag(n),i=ar.fromTag("br");return Wo(o,r),ro(o,i),eD(e,o,t),ZA(i)},rD=function(e,t,n,r){return""===t?tD(e,r):nD(e,r,t,n)},oD=function(e,n){var r=t(Tr,n);return hs(ar.fromDom(e.container()),wi,r).filter(QA)},iD=function(e,t,n){return t?TR(e.dom(),n):_R(e.dom(),n)},aD=function(e,t){var n=ar.fromDom(e.getBody()),r=ul.fromRangeStart(e.selection.getRng()),o=Ql(e),i=Zl(e);return oD(r,n).exists(function(){if(iD(n,t,r)){var a=rD(n,o,i,t);return e.selection.setRng(a),!0}return!1})},uD=function(e,t){return function(){return!!e.selection.isCollapsed()&&aD(e,t)}},cD=function(e){return Ke(e,function(e){return It({shiftKey:!1,altKey:!1,ctrlKey:!1,metaKey:!1,keyCode:0,action:pe},e)})},sD=function(e,t){return t.keyCode===e.keyCode&&t.shiftKey===e.shiftKey&&t.altKey===e.altKey&&t.ctrlKey===e.ctrlKey&&t.metaKey===e.metaKey},fD=function(e,t){return ot(cD(e),function(e){return sD(e,t)?[e]:[]})},lD=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return function(){return e.apply(null,t)}},dD=function(e,t){return tt(fD(e,t),function(e){return e.action()})},mD=function(e,t,n){var r=On().os;dD([{keyCode:Nk.RIGHT,action:bA(e,!0)},{keyCode:Nk.LEFT,action:bA(e,!1)},{keyCode:Nk.UP,action:CA(e,!1)},{keyCode:Nk.DOWN,action:CA(e,!0)},{keyCode:Nk.RIGHT,action:GA(e,!0)},{keyCode:Nk.LEFT,action:GA(e,!1)},{keyCode:Nk.UP,action:JA(e,!1)},{keyCode:Nk.DOWN,action:JA(e,!0)},{keyCode:Nk.RIGHT,action:dR(e,t,!0)},{keyCode:Nk.LEFT,action:dR(e,t,!1)},{keyCode:Nk.RIGHT,ctrlKey:!r.isOSX(),altKey:r.isOSX(),action:gR(e,t)},{keyCode:Nk.LEFT,ctrlKey:!r.isOSX(),altKey:r.isOSX(),action:hR(e,t)},{keyCode:Nk.UP,action:uD(e,!1)},{keyCode:Nk.DOWN,action:uD(e,!0)}],n).each(function(e){n.preventDefault()})},pD=function(e,t){e.on("keydown",function(n){n.isDefaultPrevented()===!1&&mD(e,t,n)})},gD=function(e){return function(t){return Tr(e,ar.fromDom(t.dom().parentNode))}},hD=function(e,t){return Dr(e,t)?hs(t,function(e){return Ei(e)||_i(e)},gD(e)):_e.none()},vD=function(e){var t=e.getBody(),n=t.firstChild&&e.dom.isBlock(t.firstChild)?t.firstChild:t;e.selection.setCursorLocation(n,0)},yD=function(e){e.dom.isEmpty(e.getBody())&&(e.setContent(""),vD(e))},bD=function(e,t,n){return cf(gp(n),hp(n),function(r,o){var i=LT(!0,r),a=LT(!1,o),u=LT(!1,t);return e?mp(n,u).map(function(e){return e.isEqual(a)&&t.isEqual(i)}).getOr(!1):pp(n,u).map(function(e){return e.isEqual(i)&&t.isEqual(a)}).getOr(!1)}).getOr(!0)},CD=function(e,t){return{block:e,position:t}},wD=function(e,t){return{from:e,to:t}},xD=function(e,t){var n=ar.fromDom(e),r=ar.fromDom(t.container());return hD(n,r).map(function(e){return CD(e,t)})},SD=function(e){return Tr(e.from.block,e.to.block)===!1},ND=function(e){return Ir(e.from.block).bind(function(t){return Ir(e.to.block).filter(function(e){return Tr(t,e)})}).isSome()},ED=function(e){return Ho(e.from.block.dom())===!1&&Ho(e.to.block.dom())===!1},kD=function(e,t,n){return zo(n.position.getNode())&&qh(n.block)===!1?dp(!1,n.block.dom()).bind(function(r){return r.isEqual(n.position)?sp(t,e,r).bind(function(t){return xD(e,t)}):_e.some(n)}).getOr(n):n},_D=function(e,t,n){var r=xD(e,ul.fromRangeStart(n)),o=r.bind(function(n){return sp(t,e,n.position).bind(function(n){return xD(e,n).map(function(n){return kD(e,t,n)})})});return cf(r,o,wD).filter(function(e){return SD(e)&&ND(e)&&ED(e)})},TD=function(e,t,n){return n.collapsed?_D(e,t,n):_e.none()},RD=function(e){var t=Vr(e);return nt(t,wi).fold(function(){return t},function(e){return t.slice(0,e)})},AD=function(e){var t=RD(e);return Xe(t,co),t},DD=function(e,t){var n=Qh(t,e);return tt(n.reverse(),function(e){return qh(e)}).each(co)},OD=function(e){return 0===Je(jr(e),function(e){return!qh(e)}).length},BD=function(e,t,n,r){if(qh(n))return Kh(n),gp(n.dom());OD(r)&&qh(t)&&eo(r,ar.fromTag("br"));var o=pp(n.dom(),ul.before(r.dom()));return Xe(AD(t),function(e){eo(r,e)}),DD(e,t),o},PD=function(e,t,n){if(qh(n))return co(n),qh(t)&&Kh(t),gp(t.dom());var r=hp(n.dom());return Xe(AD(t),function(e){ro(n,e)}),DD(e,t),r},LD=function(e,t){var n=Qh(t,e);return _e.from(n[n.length-1])},ID=function(e,t){return Dr(t,e)?LD(t,e):_e.none()},MD=function(e,t){dp(e,t.dom()).map(function(e){return e.getNode()}).map(ar.fromDom).filter(Ni).each(co)},FD=function(e,n,r){return MD(!0,n),MD(!1,r),ID(n,r).fold(t(PD,e,n,r),t(BD,e,n,r))},UD=function(e,t,n,r){return t?FD(e,r,n):FD(e,n,r)},zD=function(e,t){var n=ar.fromDom(e.getBody()),r=TD(n.dom(),t,e.selection.getRng()).bind(function(e){return UD(n,t,e.from.block,e.to.block)});return r.each(function(t){e.selection.setRng(t.toRange())}),r.isSome()},jD=function(e,t){var n=t.getRng();return cf(hD(e,ar.fromDom(n.startContainer)),hD(e,ar.fromDom(n.endContainer)),function(r,o){return Tr(r,o)===!1&&(n.deleteContents(),UD(e,!0,r,o).each(function(e){t.setRng(e.toRange())}),!0)}).getOr(!1)},HD=function(e,n){var r=ar.fromDom(n),o=t(Tr,e);return gs(r,Ai,o).isSome()},VD=function(e,t){return HD(e,t.startContainer)||HD(e,t.endContainer)},qD=function(e,t){var n=pp(e.dom(),ul.fromRangeStart(t)).isNone(),r=mp(e.dom(),ul.fromRangeEnd(t)).isNone();return!VD(e,t)&&n&&r},$D=function(e){return e.setContent(""),e.selection.setCursorLocation(),!0},WD=function(e){var t=ar.fromDom(e.getBody()),n=e.selection.getRng();return qD(t,n)?$D(e):jD(t,e.selection)},KD=function(e,t){return!e.selection.isCollapsed()&&WD(e)},XD=function(e){return Um(e).exists(Ni)},YD=function(e,t,n){var r=Je(Qh(ar.fromDom(n.container()),t),wi),o=ft(r).getOr(t);return sp(e,o.dom(),n).filter(XD)},GD=function(e,t){return Um(t).exists(Ni)||YD(!0,e,t).isSome()},JD=function(e,t){return zm(t).exists(Ni)||YD(!1,e,t).isSome()},QD=t(YD,!1),ZD=t(YD,!0),eO=function(e){return Ai(ar.fromDom(e))||_i(ar.fromDom(e))},tO=fc.generate([{remove:["element"]},{moveToElement:["element"]},{moveToPosition:["position"]}]),nO=function(e,t){var n=t.getNode(e===!1),r=e?"after":"before";return ko(n)&&n.getAttribute("data-mce-caret")===r},rO=function(e,t,n,r){var o=function(t){return Si(ar.fromDom(t))&&!Rm(n,r,e)};return Mm(!t,n).fold(function(){return Mm(t,r).fold(ve(!1),o)},o)},oO=function(e,t,n,r){var o=r.getNode(t===!1);return hD(ar.fromDom(e),ar.fromDom(n.getNode())).map(function(e){return qh(e)?tO.remove(e.dom()):tO.moveToElement(o)}).orThunk(function(){return _e.some(tO.moveToElement(o))})},iO=function(e,t,n){return sp(t,e,n).bind(function(r){return eO(r.getNode())?_e.none():rO(e,t,n,r)?_e.none():t&&Ho(r.getNode())?oO(e,t,n,r):t===!1&&Ho(r.getNode(!0))?oO(e,t,n,r):t&&Ph(n)?_e.some(tO.moveToPosition(r)):t===!1&&Bh(n)?_e.some(tO.moveToPosition(r)):_e.none()})},aO=function(e,t){return e&&Ho(t.nextSibling)?_e.some(tO.moveToElement(t.nextSibling)):e===!1&&Ho(t.previousSibling)?_e.some(tO.moveToElement(t.previousSibling)):_e.none()},uO=function(e,t,n){return n.fold(function(e){return _e.some(tO.remove(e))},function(e){return _e.some(tO.moveToElement(e))},function(n){return Rm(t,n,e)?_e.none():_e.some(tO.moveToPosition(n))})},cO=function(e,t,n){return nO(t,n)?aO(t,n.getNode(t===!1)).fold(function(){return iO(e,t,n)},_e.some):iO(e,t,n).bind(function(t){return uO(e,n,t)})},sO=function(e,t,n){var r=Im(t?1:-1,e,n),o=ul.fromRangeStart(r),i=ar.fromDom(e);return t===!1&&Ph(o)?_e.some(tO.remove(o.getNode(!0))):t&&Bh(o)?_e.some(tO.remove(o.getNode())):t===!1&&Bh(o)&&JD(i,o)?QD(i,o).map(function(e){return tO.remove(e.getNode())}):t&&Ph(o)&&GD(i,o)?ZD(i,o).map(function(e){return tO.remove(e.getNode())}):cO(e,t,o)},fO=function(e,t){return function(n){return e._selectionOverrides.hideFakeCaret(),xv(e,t,ar.fromDom(n)),!0}},lO=function(e,t){return function(n){var r=t?ul.before(n):ul.after(n);return e.selection.setRng(r.toRange()),!0}},dO=function(e){return function(t){return e.selection.setRng(t.toRange()),!0}},mO=function(e,t){return _e.from(vO(e.getBody(),t))},pO=function(e,t){var n=e.selection.getNode();return mO(e,n).filter(Ho).fold(function(){var n=sO(e.getBody(),t,e.selection.getRng()).map(function(n){return n.fold(fO(e,t),lO(e,t),dO(e))});return n.getOr(!1)},function(){return!0})},gO=function(e){Xe(ps(e,".mce-offscreen-selection"),co)},hO=function(e,t){var n=e.selection.getNode();if(Ho(n)){var r=mO(e,n.parentNode).filter(Ho);return r.fold(function(){return gO(ar.fromDom(e.getBody())),xv(e,t,ar.fromDom(e.selection.getNode())),yD(e),!0},function(){return!0})}return!1},vO=function(e,t){for(;t&&t!==e;){if(jo(t)||Ho(t))return t;t=t.parentNode}return null},yO=function(e){var t,n=vO(e.getBody(),e.selection.getNode());return jo(n)&&e.dom.isBlock(n)&&e.dom.isEmpty(n)&&(t=e.dom.create("br",{"data-mce-bogus":"1"}),e.dom.setHTML(n,""),n.appendChild(t),e.selection.setRng(ul.before(t).toRange())),!0},bO=function(e,t){return e.selection.isCollapsed()?pO(e,t):hO(e,t)},CO=function(e,t){Io(t)&&0===t.data.length&&e.remove(t)},wO=function(e,t,n,r,o,i){var a=aA(r,e,i.getNode(!o),o,!0);if(t.collapsed){var u=t.cloneRange();o?u.setEnd(a.startContainer,a.startOffset):u.setStart(a.endContainer,a.endOffset),u.deleteContents()}else t.deleteContents();return e.selection.setRng(a),CO(e.dom,n),!0},xO=function(e,n){var r=e.selection.getRng();if(!Io(r.commonAncestorContainer))return!1;var o=n?al.Forwards:al.Backwards,i=tp(e.getBody()),a=t(jm,i.next),u=t(jm,i.prev),c=n?a:u,s=n?Bh:Ph,f=Fm(o,e.getBody(),r),l=LT(n,c(f));if(!l||!Hm(f,l))return!1;if(s(l))return wO(e,r,f.getNode(),o,n,l);var d=c(l);return!!(d&&s(d)&&Hm(l,d))&&wO(e,r,f.getNode(),o,n,d)},SO=function(e,t){return xO(e,t)},NO=function(t,n){var r=e.document.createRange();return r.setStart(t.container(),t.offset()),r.setEnd(n.container(),n.offset()),r},EO=function(e){return cf(gp(e),hp(e),function(t,n){var r=LT(!0,t),o=LT(!1,n);return mp(e,r).map(function(e){return e.isEqual(o)}).getOr(!0)}).getOr(!0)},kO=function(e,t){return function(n){return kT(t,n).map(function(t){return iR(e,t),!0}).getOr(!1)}},_O=function(e,n,r,o){var i=e.getBody(),a=t(RT,e);e.undoManager.ignore(function(){e.selection.setRng(NO(r,o)),e.execCommand("Delete"),XT(a,i,ul.fromRangeStart(e.selection.getRng())).map(QT).map(kO(e,n))}),e.nodeChanged()},TO=function(e,t){var n=Tm(t,e);return n?n:e},RO=function(e,n,r,o){var i=TO(e.getBody(),o.container()),a=t(RT,e),u=XT(a,i,o);return u.bind(function(e){return r?e.fold(ve(_e.some(QT(e))),_e.none,ve(_e.some(JT(e))),_e.none):e.fold(_e.none,ve(_e.some(JT(e))),_e.none,ve(_e.some(QT(e))))}).map(kO(e,n)).getOrThunk(function(){var t=fp(r,i,o),c=t.bind(function(e){return XT(a,i,e)});return u.isSome()&&c.isSome()?OT(a,i,o).map(function(t){return!!EO(t)&&(xv(e,r,ar.fromDom(t)),!0)}).getOr(!1):c.bind(function(i){return t.map(function(t){return r?_O(e,n,o,t):_O(e,n,t,o),!0})}).getOr(!1)})},AO=function(e,t,n){if(e.selection.isCollapsed()&&Od(e)){var r=ul.fromRangeStart(e.selection.getRng());return RO(e,t,n,r)}return!1},DO=function(e,t){var n=Qh(t,e);return nt(n,wi).fold(ve(n),function(e){return n.slice(0,e)})},OO=function(e){return 1===Vr(e).length},BO=function(e,n,r,o){var i=t(ZC,n),a=Ke(Je(o,i),function(e){return e.dom()});if(0===a.length)xv(n,e,r);else{var u=QC(r.dom(),a);n.selection.setRng(u.toRange())}},PO=function(e,t){var n=ar.fromDom(e.getBody()),r=ar.fromDom(e.selection.getStart()),o=Je(DO(n,r),OO);return lt(o).map(function(n){var r=ul.fromRangeStart(e.selection.getRng());return!(!bD(t,r,n.dom())||ew(n))&&(BO(t,e,n,o),!0)}).getOr(!1)},LO=function(e,t){return!!e.selection.isCollapsed()&&PO(e,t)},IO=function(e,t){var n=ul.fromRangeStart(e.selection.getRng());return sp(t,e.getBody(),n).filter(function(e){return t?Rh(e):Ah(e)}).bind(function(e){return _e.from(Am(t?0:-1,e))}).map(function(t){return e.selection.select(t),!0}).getOr(!1)},MO=function(e,t){return!!e.selection.isCollapsed()&&IO(e,t)},FO=function(e){return hs(e,function(e){return jo(e.dom())||Ho(e.dom())}).exists(function(e){return jo(e.dom())})},UO=function(e){var t=parseInt(e,10);return isNaN(t)?0:t},zO=function(e,t){var n=e||xi(t)?"margin":"padding",r="rtl"===ei(t,"direction")?"-right":"-left";return n+r},jO=function(e,t,n,r,o,i){var a=zO(n,ar.fromDom(i));if("outdent"===t){var u=Math.max(0,UO(i.style[a])-r);e.setStyle(i,a,u?u+o:"")}else{var u=UO(i.style[a])+r+o;e.setStyle(i,a,u)}},HO=function(e,t){return it(t,function(t){var n=zO(Cd(e),t),r=ni(t,n).map(UO).getOr(0),o=e.dom.getContentEditable(t.dom());return"false"!==o&&r>0})},VO=function(e){var t=WO(e);return!e.mode.isReadOnly()&&(t.length>1||HO(e,t))},qO=function(e){return ki(e)||_i(e)},$O=function(e){return Ir(e).map(qO).getOr(!1)},WO=function(e){return Je(Ke(e.selection.getSelectedBlocks(),ar.fromDom),function(e){return!qO(e)&&!$O(e)&&FO(e)})},KO=function(e,t){var n=e.dom,r=e.selection,o=e.formatter,i=wd(e),a=/[a-z%]+$/i.exec(i)[0],u=parseInt(i,10),c=Cd(e),s=Ql(e);e.queryCommandState("InsertUnorderedList")||e.queryCommandState("InsertOrderedList")||""!==s||n.getParent(r.getNode(),n.isBlock)||o.apply("div"),Xe(WO(e),function(e){jO(n,t,c,u,a,e.dom())})},XO=function(e,t,n){return lp(e,t,n,Eh)},YO=function(e,t){return tt(Qh(ar.fromDom(t.container()),e),wi)},GO=function(e,t,n){return XO(e,t.dom(),n).forall(function(e){return YO(t,n).fold(function(){return Rm(e,n,t.dom())===!1},function(r){return Rm(e,n,t.dom())===!1&&Dr(r,ar.fromDom(e.container()))})})},JO=function(e,t,n){return YO(t,n).fold(function(){return XO(e,t.dom(),n).forall(function(e){return Rm(e,n,t.dom())===!1})},function(t){return XO(e,t.dom(),n).isNone()})},QO=t(JO,!1),ZO=t(JO,!0),eB=t(GO,!1),tB=t(GO,!0),nB=function(e,t,n){if(e.selection.isCollapsed()&&VO(e)){var r=e.dom,o=e.selection.getRng(),i=ul.fromRangeStart(o),a=r.getParent(o.startContainer,r.isBlock);if(null!==a&&QO(ar.fromDom(a),i))return KO(e,"outdent"),!0}return!1},rB=function(e,t,n){dD([{keyCode:Nk.BACKSPACE,action:lD(nB,e,!1)},{keyCode:Nk.BACKSPACE,action:lD(bO,e,!1)},{keyCode:Nk.DELETE,action:lD(bO,e,!0)},{keyCode:Nk.BACKSPACE,action:lD(SO,e,!1)},{keyCode:Nk.DELETE,action:lD(SO,e,!0)},{keyCode:Nk.BACKSPACE,action:lD(AO,e,t,!1)},{keyCode:Nk.DELETE,action:lD(AO,e,t,!0)},{keyCode:Nk.BACKSPACE,action:lD(ly,e,!1)},{keyCode:Nk.DELETE,action:lD(ly,e,!0)},{keyCode:Nk.BACKSPACE,action:lD(MO,e,!1)},{keyCode:Nk.DELETE,action:lD(MO,e,!0)},{keyCode:Nk.BACKSPACE,action:lD(KD,e,!1)},{keyCode:Nk.DELETE,action:lD(KD,e,!0)},{keyCode:Nk.BACKSPACE,action:lD(zD,e,!1)},{keyCode:Nk.DELETE,action:lD(zD,e,!0)},{keyCode:Nk.BACKSPACE,action:lD(LO,e,!1)},{keyCode:Nk.DELETE,action:lD(LO,e,!0)}],n).each(function(e){n.preventDefault()})},oB=function(e,t){dD([{keyCode:Nk.BACKSPACE,action:lD(yO,e)},{keyCode:Nk.DELETE,action:lD(yO,e)}],t)},iB=function(e,t){e.on("keydown",function(n){n.isDefaultPrevented()===!1&&rB(e,t,n)}),e.on("keyup",function(t){t.isDefaultPrevented()===!1&&oB(e,t)})},aB=function(e){for(;e;){if(1===e.nodeType||3===e.nodeType&&e.data&&/[\r\n\s]/.test(e.data))return e;e=e.nextSibling}},uB=function(e,t){var n,r=t,o=e.dom,i=e.schema.getMoveCaretBeforeOnEnterElements();if(t){if(/^(LI|DT|DD)$/.test(t.nodeName)){var a=aB(t.firstChild);a&&/^(UL|OL|DL)$/.test(a.nodeName)&&t.insertBefore(o.doc.createTextNode(da),t.firstChild)}var u=o.createRng();if(t.normalize(),t.hasChildNodes()){for(var c=new qu(t,t);n=c.current();){if(Io(n)){u.setStart(n,0),u.setEnd(n,0);break}if(i[n.nodeName.toLowerCase()]){u.setStartBefore(n),u.setEndBefore(n);break}r=n,n=c.next()}n||(u.setStart(r,0),u.setEnd(r,0))}else zo(t)?t.nextSibling&&o.isBlock(t.nextSibling)?(u.setStartBefore(t),u.setEndBefore(t)):(u.setStartAfter(t),u.setEndAfter(t)):(u.setStart(t,0),u.setEnd(t,0));e.selection.setRng(u),HE(e,u)}},cB=function(e,t){var n,r,o=e.getRoot();for(n=t;n!==o&&"false"!==e.getContentEditable(n);)"true"===e.getContentEditable(n)&&(r=n),n=n.parentNode;return n!==o?r:o},sB=function(e){return _e.from(e.dom.getParent(e.selection.getStart(!0),e.dom.isBlock))},fB=function(e){return sB(e).fold(ve(""),function(e){return e.nodeName.toUpperCase()})},lB=function(e){return sB(e).filter(function(e){return _i(ar.fromDom(e))}).isSome()},dB=function(e,t){return e.firstChild&&e.firstChild.nodeName===t},mB=function(e,t){return e&&e.parentNode&&e.parentNode.nodeName===t},pB=function(e){return e&&/^(OL|UL|LI)$/.test(e.nodeName)},gB=function(e){return pB(e)&&pB(e.parentNode)},hB=function(e){var t=e.parentNode;return/^(LI|DT|DD)$/.test(t.nodeName)?t:e},vB=function(e,t,n){for(var r=e[n?"firstChild":"lastChild"];r&&!ko(r);)r=r[n?"nextSibling":"previousSibling"];return r===t},yB=function(e,t,n,r,o){var i=e.dom,a=e.selection.getRng();if(n!==e.getBody()){gB(n)&&(o="LI");var u=o?t(o):i.create("BR");if(vB(n,r,!0)&&vB(n,r,!1))mB(n,"LI")?i.insertAfter(u,hB(n)):i.replace(u,n);else if(vB(n,r,!0))mB(n,"LI")?(i.insertAfter(u,hB(n)),u.appendChild(i.doc.createTextNode(" ")),u.appendChild(n)):n.parentNode.insertBefore(u,n);else if(vB(n,r,!1))i.insertAfter(u,hB(n));else{n=hB(n);var c=a.cloneRange();c.setStartAfter(r),c.setEndAfter(n);var s=c.extractContents();"LI"===o&&dB(s,"LI")?(u=s.firstChild,i.insertAfter(s,n)):(i.insertAfter(s,n),i.insertAfter(u,n))}i.remove(r),uB(e,u)}},bB=function(e){Xe(ms(ar.fromDom(e),vr),function(e){var t=e.dom();t.nodeValue=Vs(t.nodeValue)})},CB=function(e,t){return t&&"A"===t.nodeName&&e.isEmpty(t)},wB=function(e){return e&&/^(TD|TH|CAPTION)$/.test(e.nodeName)},xB=function(e){e.innerHTML='<br data-mce-bogus="1">'},SB=function(e,t){return e.nodeName===t||e.previousSibling&&e.previousSibling.nodeName===t},NB=function(e,t){return t&&e.isBlock(t)&&!/^(TD|TH|CAPTION|FORM)$/.test(t.nodeName)&&!/^(fixed|absolute)/i.test(t.style.position)&&"true"!==e.getContentEditable(t)},EB=function(e,t,n){var r,o=n,i=[];if(o){for(;o=o.firstChild;){if(e.isBlock(o))return;ko(o)&&!t[o.nodeName.toLowerCase()]&&i.push(o)}for(r=i.length;r--;)o=i[r],!o.hasChildNodes()||o.firstChild===o.lastChild&&""===o.firstChild.nodeValue?e.remove(o):CB(e,o)&&e.remove(o)}},kB=function(e,t,n){return Io(t)===!1?n:e?1===n&&t.data.charAt(n-1)===js?0:n:n===t.data.length-1&&t.data.charAt(n)===js?t.data.length:n},_B=function(e){var t=e.cloneRange();return t.setStart(e.startContainer,kB(!0,e.startContainer,e.startOffset)),t.setEnd(e.endContainer,kB(!1,e.endContainer,e.endOffset)),t},TB=function(e){do Io(e)&&(e.nodeValue=e.nodeValue.replace(/^[\r\n]+/,"")),e=e.firstChild;while(e)},RB=function(e,t){var n,r,o=e.getRoot();for(n=t;n!==o&&"false"!==e.getContentEditable(n);)"true"===e.getContentEditable(n)&&(r=n),n=n.parentNode;return n!==o?r:o},AB=function(e,t,n){_e.from(n.style).map(e.dom.parseStyle).each(function(n){var r=ri(ar.fromDom(t)),o=It(It({},r),n);e.dom.setStyles(t,o)});var o=_e.from(n["class"]).map(function(e){return e.split(/\s+/)}),i=_e.from(t.className).map(function(e){return Je(e.split(/\s+/),function(e){return""!==e})});cf(o,i,function(n,o){var i=Je(o,function(e){return!$e(n,e)}),a=r(n,i);e.dom.setAttrib(t,"class",a.join(" "))});var a=["style","class"],u=wt(n,function(e,t){return!$e(a,t)});e.dom.setAttribs(t,u)},DB=function(e,t){var n=Ql(e);if(n&&n.toLowerCase()===t.tagName.toLowerCase()){var r=Zl(e);AB(e,t,r)}},OB=function(e,t,n,r,o){var i,a,u,c,s,f,l=t||"P",d=e.dom,m=RB(d,r);if(a=d.getParent(r,d.isBlock),!a||!NB(d,a)){if(a=a||m,f=a===e.getBody()||wB(a)?a.nodeName.toLowerCase():a.parentNode.nodeName.toLowerCase(),!a.hasChildNodes())return i=d.create(l),DB(e,i),a.appendChild(i),n.setStart(i,0),n.setEnd(i,0),i;for(c=r;c.parentNode!==a;)c=c.parentNode;for(;c&&!d.isBlock(c);)u=c,c=c.previousSibling;if(u&&e.schema.isValidChild(f,l.toLowerCase())){for(i=d.create(l),DB(e,i),u.parentNode.insertBefore(i,u),c=u;c&&!d.isBlock(c);)s=c.nextSibling,i.appendChild(c),c=s;n.setStart(r,o),n.setEnd(r,o)}}return r},BB=function(e,t){t.normalize();var n=t.lastChild;n&&!/^(left|right)$/gi.test(e.getStyle(n,"float",!0))||e.add(t,"br");
},PB=function(e,t){var n,r,o,i,a,u,c,s,f,l,d=e.dom,m=e.schema,p=m.getNonEmptyElements(),g=e.selection.getRng(),h=function(t){var n,o,a,u=r,c=m.getTextInlineElements();if(n=t||"TABLE"===s||"HR"===s?d.create(t||f):i.cloneNode(!1),a=n,nd(e)===!1)d.setAttrib(n,"style",null),d.setAttrib(n,"class",null);else do if(c[u.nodeName]){if(yp(u)||zp(u))continue;o=u.cloneNode(!1),d.setAttrib(o,"id",""),n.hasChildNodes()?(o.appendChild(n.firstChild),n.appendChild(o)):(a=o,n.appendChild(o))}while((u=u.parentNode)&&u!==w);return DB(e,n),xB(a),n},v=function(e){var t,n,a=kB(e,r,o);if(Io(r)&&(e?a>0:a<r.nodeValue.length))return!1;if(r.parentNode===i&&l&&!e)return!0;if(e&&ko(r)&&r===i.firstChild)return!0;if(SB(r,"TABLE")||SB(r,"HR"))return l&&!e||!l&&e;var u=new qu(r,i);for(Io(r)&&(e&&0===a?u.prev():e||a!==r.nodeValue.length||u.next());t=u.current();){if(ko(t)){if(!t.getAttribute("data-mce-bogus")&&(n=t.nodeName.toLowerCase(),p[n]&&"br"!==n))return!1}else if(Io(t)&&!Bi(t.nodeValue))return!1;e?u.prev():u.next()}return!0},y=function(){a=/^(H[1-6]|PRE|FIGURE)$/.test(s)&&"HGROUP"!==x?h(f):h(),rd(e)&&NB(d,c)&&d.isEmpty(i)?a=d.split(c,i):d.insertAfter(a,i),uB(e,a)};pk(d,g).each(function(e){g.setStart(e.startContainer,e.startOffset),g.setEnd(e.endContainer,e.endOffset)}),r=g.startContainer,o=g.startOffset,f=Ql(e);var b=!(!t||!t.shiftKey),C=!(!t||!t.ctrlKey);ko(r)&&r.hasChildNodes()&&(l=o>r.childNodes.length-1,r=r.childNodes[Math.min(o,r.childNodes.length-1)]||r,o=l&&Io(r)?r.nodeValue.length:0);var w=RB(d,r);if(w){(f&&!b||!f&&b)&&(r=OB(e,f,g,r,o)),i=d.getParent(r,d.isBlock),c=i?d.getParent(i.parentNode,d.isBlock):null,s=i?i.nodeName.toUpperCase():"";var x=c?c.nodeName.toUpperCase():"";return"LI"!==x||C||(i=c,c=c.parentNode,s=x),/^(LI|DT|DD)$/.test(s)&&d.isEmpty(i)?void yB(e,h,c,i,f):void(f&&i===e.getBody()||(f=f||"P",Ws(i)?(a=of(i),d.isEmpty(i)&&xB(i),DB(e,a),uB(e,a)):v()?y():v(!0)?(a=i.parentNode.insertBefore(h(),i),uB(e,SB(i,"HR")?a:i)):(n=_B(g).cloneRange(),n.setEndAfter(i),u=n.extractContents(),bB(u),TB(u),a=u.firstChild,d.insertAfter(u,i),EB(d,p,a),BB(d,i),d.isEmpty(i)&&xB(i),a.normalize(),d.isEmpty(a)?(d.remove(a),y()):(DB(e,a),uB(e,a))),d.setAttrib(a,"id",""),e.fire("NewBlock",{newBlock:a})))}},LB=function(e,t,n){for(var r,o=new qu(t,n),i=e.getNonEmptyElements();r=o.next();)if(i[r.nodeName.toLowerCase()]||r.length>0)return!0},IB=function(e,t,n){var r=e.create("span",{},"&nbsp;");n.parentNode.insertBefore(r,n),t.scrollIntoView(r),e.remove(r)},MB=function(e,t,n,r){var o=e.createRng();r?(o.setStartBefore(n),o.setEndBefore(n)):(o.setStartAfter(n),o.setEndAfter(n)),t.setRng(o)},FB=function(e,t){var n,r,o=e.selection,i=e.dom,a=o.getRng();pk(i,a).each(function(e){a.setStart(e.startContainer,e.startOffset),a.setEnd(e.endContainer,e.endOffset)});var u=a.startOffset,c=a.startContainer;if(1===c.nodeType&&c.hasChildNodes()){var s=u>c.childNodes.length-1;c=c.childNodes[Math.min(u,c.childNodes.length-1)]||c,u=s&&3===c.nodeType?c.nodeValue.length:0}var f=i.getParent(c,i.isBlock),l=f?i.getParent(f.parentNode,i.isBlock):null,d=l?l.nodeName.toUpperCase():"",m=!(!t||!t.ctrlKey);"LI"!==d||m||(f=l),c&&3===c.nodeType&&u>=c.nodeValue.length&&(LB(e.schema,c,f)||(n=i.create("br"),a.insertNode(n),a.setStartAfter(n),a.setEndAfter(n),r=!0)),n=i.create("br"),ll(i,a,n),IB(i,o,n),MB(i,o,n,r),e.undoManager.add()},UB=function(e,t){var n=ar.fromTag("br");eo(ar.fromDom(t),n),e.undoManager.add()},zB=function(e,t){HB(e.getBody(),t)||to(ar.fromDom(t),ar.fromTag("br"));var n=ar.fromTag("br");to(ar.fromDom(t),n),IB(e.dom,e.selection,n.dom()),MB(e.dom,e.selection,n.dom(),!1),e.undoManager.add()},jB=function(e){return zo(e.getNode())},HB=function(e,t){return!!jB(ul.after(t))||mp(e,ul.after(t)).map(function(e){return zo(e.getNode())}).getOr(!1)},VB=function(e){return e&&"A"===e.nodeName&&"href"in e},qB=function(e){return e.fold(ve(!1),VB,VB,ve(!1))},$B=function(e){var n=t(RT,e),r=ul.fromRangeStart(e.selection.getRng());return XT(n,e.getBody(),r).filter(qB)},WB=function(e,n){n.fold(pe,t(UB,e),t(zB,e),pe)},KB=function(e,n){var r=$B(e);r.isSome()?r.each(t(WB,e)):FB(e,n)},XB=function(e,t){return sB(e).filter(function(e){return t.length>0&&Nr(ar.fromDom(e),t)}).isSome()},YB=function(e){return XB(e,ed(e))},GB=function(e){return XB(e,td(e))},JB=fc.generate([{br:[]},{block:[]},{none:[]}]),QB=function(e,t){return GB(e)},ZB=function(e){return function(t,n){var r=""===Ql(t);return r===e}},eP=function(e){return function(t,n){return lB(t)===e}},tP=function(e,t){return function(n,r){var o=fB(n)===e.toUpperCase();return o===t}},nP=function(e){return tP("pre",e)},rP=function(){return tP("summary",!0)},oP=function(e){return function(t,n){return Jl(t)===e}},iP=function(e,t){return YB(e)},aP=function(e,t){return t},uP=function(e){var t=Ql(e),n=cB(e.dom,e.selection.getStart());return n&&e.schema.isValidChild(n.nodeName,t?t:"P")},cP=function(e,t){return function(n,r){var o=Ze(e,function(e,t){return e&&t(n,r)},!0);return o?_e.some(t):_e.none()}},sP=function(e,t){return FT([cP([QB],JB.none()),cP([rP()],JB.br()),cP([nP(!0),oP(!1),aP],JB.br()),cP([nP(!0),oP(!1)],JB.block()),cP([nP(!0),oP(!0),aP],JB.block()),cP([nP(!0),oP(!0)],JB.br()),cP([eP(!0),aP],JB.br()),cP([eP(!0)],JB.block()),cP([ZB(!0),aP,uP],JB.block()),cP([ZB(!0)],JB.br()),cP([iP],JB.br()),cP([ZB(!1),aP],JB.br()),cP([uP],JB.block())],[e,!(!t||!t.shiftKey)]).getOr(JB.none())},fP=function(e,t){sP(e,t).fold(function(){KB(e,t)},function(){PB(e,t)},pe)},lP=function(e,t){t.isDefaultPrevented()||(t.preventDefault(),Zx(e.undoManager),e.undoManager.transact(function(){e.selection.isCollapsed()===!1&&e.execCommand("Delete"),fP(e,t)}))},dP=function(e){e.on("keydown",function(t){t.keyCode===Nk.ENTER&&lP(e,t)})},mP=function(e,t){var n=t.container(),r=t.offset();return Io(n)?(n.insertData(r,e),_e.some(E(n,r+e.length))):Um(t).map(function(n){var r=ar.fromText(e);return t.isAtEnd()?to(n,r):eo(n,r),E(r.dom(),e.length)})},pP=t(mP,da),gP=t(mP," "),hP=function(e){return E.isTextPosition(e)&&!e.isAtStart()&&!e.isAtEnd()},vP=function(e,t){var n=Je(Qh(ar.fromDom(t.container()),e),wi);return ft(n).getOr(e)},yP=function(e,t){return hP(t)?Nh(t):Nh(t)||pp(vP(e,t).dom(),t).exists(Nh)},bP=function(e,t){return hP(t)?Sh(t):Sh(t)||mp(vP(e,t).dom(),t).exists(Sh)},CP=function(e){return $e(["pre","pre-wrap"],e)},wP=function(e){return Um(e).bind(function(e){return hs(e,hr)}).exists(function(e){return CP(ei(e,"white-space"))})},xP=function(e,t){return pp(e.dom(),t).isNone()},SP=function(e,t){return mp(e.dom(),t).isNone()},NP=function(e,t){return xP(e,t)||SP(e,t)||QO(e,t)||ZO(e,t)||JD(e,t)||GD(e,t)},EP=function(e,t){return!wP(t)&&(NP(e,t)||yP(e,t)||bP(e,t))},kP=function(e,t){return!wP(t)&&(QO(e,t)||eB(e,t)||JD(e,t)||yP(e,t))},_P=function(e){var t=e.container(),n=e.offset();return Io(t)&&n<t.data.length?E(t,n+1):e},TP=function(e,t){var n=_P(t);return!wP(n)&&(ZO(e,n)||tB(e,n)||GD(e,n)||bP(e,n))},RP=function(e,t){return kP(e,t)||TP(e,t)},AP=function(e,t){return Hp(e.charAt(t))},DP=function(e){var t=e.container();return Io(t)&&vn(t.data,da)},OP=function(e){var t=e.split("");return Ke(t,function(e,n){return Hp(e)&&n>0&&n<t.length-1&&qp(t[n-1])&&qp(t[n+1])?" ":e}).join("")},BP=function(e,t){var n=t.data,r=E(t,0);return!(!AP(n,0)||RP(e,r))&&(t.data=" "+n.slice(1),!0)},PP=function(e){var t=e.data,n=OP(t);return n!==t&&(e.data=n,!0)},LP=function(e,t){var n=t.data,r=E(t,n.length-1);return!(!AP(n,n.length-1)||RP(e,r))&&(t.data=n.slice(0,-1)+" ",!0)},IP=function(e,t){return _e.some(t).filter(DP).bind(function(t){var n=t.container(),r=BP(e,n)||PP(n)||LP(e,n);return r?_e.some(t):_e.none()})},MP=function(e){var t=ar.fromDom(e.getBody());e.selection.isCollapsed()&&IP(t,E.fromRangeStart(e.selection.getRng())).each(function(t){e.selection.setRng(t.toRange())})},FP=function(e){return function(t){return t.fold(function(t){return pp(e.dom(),ul.before(t))},function(e){return gp(e)},function(e){return hp(e)},function(t){return mp(e.dom(),ul.after(t))})}},UP=function(e,t){return function(n){return EP(e,n)?pP(t):gP(t)}},zP=function(e){return function(t){return e.selection.setRng(t.toRange()),e.nodeChanged(),!0}},jP=function(e){var n=ul.fromRangeStart(e.selection.getRng()),r=ar.fromDom(e.getBody());if(e.selection.isCollapsed()){var o=t(RT,e),i=ul.fromRangeStart(e.selection.getRng());return XT(o,e.getBody(),i).bind(FP(r)).bind(UP(r,n)).exists(zP(e))}return!1},HP=function(e,t){dD([{keyCode:Nk.SPACEBAR,action:lD(jP,e)}],t).each(function(e){t.preventDefault()})},VP=function(e){e.on("keydown",function(t){t.isDefaultPrevented()===!1&&HP(e,t)})},qP=function(e){return ys(ar.fromDom(e.getBody()),"*[data-mce-caret]").fold(ve(null),function(e){return e.dom()})},$P=function(e){e.selection.setRng(e.selection.getRng())},WP=function(e,t){t.hasAttribute("data-mce-caret")&&(of(t),$P(e),e.selection.scrollIntoView(t))},KP=function(e,t){var n=qP(e);if(n)return"compositionstart"===t.type?(t.preventDefault(),t.stopPropagation(),void WP(e,n)):void(Ys(n)&&(WP(e,n),e.undoManager.add()))},XP=function(e){e.on("keyup compositionstart",t(KP,e))},YP=On().browser,GP=function(e){var t=es(function(){e.composing||MP(e)},0);YP.isIE()&&(e.on("keypress",function(e){t.throttle()}),e.on("remove",function(e){t.cancel()}))},JP=function(e){GP(e),e.on("input",function(t){t.isComposing===!1&&MP(e)})},QP=function(e,t){dD([{keyCode:Nk.END,action:xA(e,!0)},{keyCode:Nk.HOME,action:xA(e,!1)}],t).each(function(e){t.preventDefault()})},ZP=function(e){e.on("keydown",function(t){t.isDefaultPrevented()===!1&&QP(e,t)})},eL=function(e){var t=pR(e);XP(e),pD(e,t),iB(e,t),dP(e),VP(e),JP(e),ZP(e)},tL=function(e){hS(e)||eL(e)},nL=function(){function e(e){this.lastPath=[],this.editor=e;var t,n=this;"onselectionchange"in e.getDoc()||e.on("NodeChange click mouseup keyup focus",function(n){var r=e.selection.getRng(),o={startContainer:r.startContainer,startOffset:r.startOffset,endContainer:r.endContainer,endOffset:r.endOffset};"nodechange"!==n.type&&nk(o,t)||e.fire("SelectionChange"),t=o}),e.on("contextmenu",function(){e.fire("SelectionChange")}),e.on("SelectionChange",function(){var t=e.selection.getStart(!0);!t||!jn.range&&e.selection.isCollapsed()||Mg(e)&&!n.isSameElementPath(t)&&e.dom.isChildOf(t,e.getBody())&&e.nodeChanged({selectionChange:!0})}),e.on("mouseup",function(t){!t.isDefaultPrevented()&&Mg(e)&&("IMG"===e.selection.getNode().nodeName?Cc.setEditorTimeout(e,function(){e.nodeChanged()}):e.nodeChanged())})}return e.prototype.nodeChanged=function(e){var t,n,r,o=this.editor.selection;this.editor.initialized&&o&&!$d(this.editor)&&!this.editor.mode.isReadOnly()&&(r=this.editor.getBody(),t=o.getStart(!0)||r,t.ownerDocument===this.editor.getDoc()&&this.editor.dom.isChildOf(t,r)||(t=r),n=[],this.editor.dom.getParent(t,function(e){return e===r||void n.push(e)}),e=e||{},e.element=t,e.parents=n,this.editor.fire("NodeChange",e))},e.prototype.isSameElementPath=function(e){var t,n=this.editor.$(e).parentsUntil(this.editor.getBody()).add(e);if(n.length===this.lastPath.length){for(t=n.length;t>=0&&n[t]===this.lastPath[t];t--);if(t===-1)return this.lastPath=n,!0}return this.lastPath=n,!1},e}(),rL=function(e){e.on("click",function(t){e.dom.getParent(t.target,"details")&&t.preventDefault()})},oL=function(e){e.parser.addNodeFilter("details",function(e){Xe(e,function(e){e.attr("data-mce-open",e.attr("open")),e.attr("open","open")})}),e.serializer.addNodeFilter("details",function(e){Xe(e,function(e){var t=e.attr("data-mce-open");e.attr("open",Oe(t)?t:null),e.attr("data-mce-open",null)})})},iL=function(e){rL(e),oL(e)},aL=function(e){return ko(e)&&Ei(ar.fromDom(e))},uL=function(e){var t=e.selection.getRng(),n=E.fromRangeStart(t),r=E.fromRangeEnd(t);if(E.isElementPosition(n)){var o=n.container();aL(o)&&gp(o).each(function(e){return t.setStart(e.container(),e.offset())})}if(E.isElementPosition(r)){var o=n.container();aL(o)&&hp(o).each(function(e){return t.setEnd(e.container(),e.offset())})}e.selection.setRng(py(t))},cL=function(e){e.on("click",function(t){t.detail>=3&&uL(e)})},sL=function(e){var t=e.getBoundingClientRect(),n=e.ownerDocument,r=n.documentElement,o=n.defaultView;return{top:t.top+o.pageYOffset-r.clientTop,left:t.left+o.pageXOffset-r.clientLeft}},fL=function(e){return e.inline?sL(e.getBody()):{left:0,top:0}},lL=function(e){var t=e.getBody();return e.inline?{left:t.scrollLeft,top:t.scrollTop}:{left:0,top:0}},dL=function(e){var t=e.getBody(),n=e.getDoc().documentElement,r={left:t.scrollLeft,top:t.scrollTop},o={left:t.scrollLeft||n.scrollLeft,top:t.scrollTop||n.scrollTop};return e.inline?r:o},mL=function(e,t){if(t.target.ownerDocument!==e.getDoc()){var n=sL(e.getContentAreaContainer()),r=dL(e);return{left:t.pageX-n.left+r.left,top:t.pageY-n.top+r.top}}return{left:t.pageX,top:t.pageY}},pL=function(e,t,n){return{pageX:n.left-e.left+t.left,pageY:n.top-e.top+t.top}},gL=function(e,t){return pL(fL(e),lL(e),mL(e,t))},hL=Ho,vL=jo,yL=function(e,t){return hL(t)&&t!==e},bL=function(e,t,n){return t!==n&&!e.dom.isChildOf(t,n)&&!hL(t)},CL=function(e){var t=e.cloneNode(!0);return t.removeAttribute("data-mce-selected"),t},wL=function(e,t,n,r){var o=t.cloneNode(!0);e.dom.setStyles(o,{width:n,height:r}),e.dom.setAttrib(o,"data-mce-selected",null);var i=e.dom.create("div",{"class":"mce-drag-container","data-mce-bogus":"all",unselectable:"on",contenteditable:"false"});return e.dom.setStyles(i,{position:"absolute",opacity:.5,overflow:"hidden",border:0,padding:0,margin:0,width:n,height:r}),e.dom.setStyles(o,{margin:0,boxSizing:"border-box"}),i.appendChild(o),i},xL=function(e,t){e.parentNode!==t&&t.appendChild(e)},SL=function(e,t,n,r,o,i){var a=0,u=0;e.style.left=t.pageX+"px",e.style.top=t.pageY+"px",t.pageX+n>o&&(a=t.pageX+n-o),t.pageY+r>i&&(u=t.pageY+r-i),e.style.width=n-a+"px",e.style.height=r-u+"px"},NL=function(e){e&&e.parentNode&&e.parentNode.removeChild(e)},EL=function(e){return 0===e.button},kL=function(e){return e.element},_L=function(e,t){return{pageX:t.pageX-e.relX,pageY:t.pageY+5}},TL=function(e,t){return function(n){if(EL(n)){var r=tt(t.dom.getParents(n.target),Sf(hL,vL)).getOr(null);if(yL(t.getBody(),r)){var o=t.dom.getPos(r),i=t.getBody(),a=t.getDoc().documentElement;e.element=r,e.screenX=n.screenX,e.screenY=n.screenY,e.maxX=(t.inline?i.scrollWidth:a.offsetWidth)-2,e.maxY=(t.inline?i.scrollHeight:a.offsetHeight)-2,e.relX=n.pageX-o.x,e.relY=n.pageY-o.y,e.width=r.offsetWidth,e.height=r.offsetHeight,e.ghost=wL(t,r,e.width,e.height)}}}},RL=function(e,t){var n=Cc.throttle(function(e,n){t._selectionOverrides.hideFakeCaret(),t.selection.placeCaretAt(e,n)},0);return function(r){var o=Math.max(Math.abs(r.screenX-e.screenX),Math.abs(r.screenY-e.screenY));if(kL(e)&&!e.dragging&&o>10){var i=t.fire("dragstart",{target:e.element});if(i.isDefaultPrevented())return;e.dragging=!0,t.focus()}if(e.dragging){var a=_L(e,gL(t,r));xL(e.ghost,t.getBody()),SL(e.ghost,a,e.width,e.height,e.maxX,e.maxY),n(r.clientX,r.clientY)}}},AL=function(e){var t=e.getSel().getRangeAt(0),n=t.startContainer;return 3===n.nodeType?n.parentNode:n},DL=function(e,t){return function(n){if(e.dragging&&bL(t,AL(t.selection),e.element)){var r=CL(e.element),o=t.fire("drop",{targetClone:r,clientX:n.clientX,clientY:n.clientY});o.isDefaultPrevented()||(r=o.targetClone,t.undoManager.transact(function(){NL(e.element),t.insertContent(t.dom.getOuterHTML(r)),t._selectionOverrides.hideFakeCaret()}))}BL(e)}},OL=function(e,t){return function(){e.dragging&&t.fire("dragend"),BL(e)}},BL=function(e){e.dragging=!1,e.element=null,NL(e.ghost)},PL=function(t){var n={},r=Ac.DOM,o=e.document,i=TL(n,t),a=RL(n,t),u=DL(n,t),c=OL(n,t);t.on("mousedown",i),t.on("mousemove",a),t.on("mouseup",u),r.bind(o,"mousemove",a),r.bind(o,"mouseup",c),t.on("remove",function(){r.unbind(o,"mousemove",a),r.unbind(o,"mouseup",c)})},LL=function(e){e.on("drop",function(t){var n="undefined"!=typeof t.clientX?e.getDoc().elementFromPoint(t.clientX,t.clientY):null;(hL(n)||hL(e.dom.getContentEditableParent(n)))&&t.preventDefault()})},IL=function(t){var n=function(e){if(!e.defaultPrevented){var t=e.dataTransfer;t&&($e(t.types,"Files")||t.files.length>0)&&e.preventDefault()}},r=function(e){Kb(t,e.target)&&n(e)},o=function(){var o=Ac.DOM,i=t.dom,a=e.document,u=t.inline?t.getBody():t.getDoc(),c=["drop","dragover"];Xe(c,function(e){o.bind(a,e,r),i.bind(u,e,n)}),t.on("remove",function(){Xe(c,function(e){o.unbind(a,e,r),i.unbind(u,e,n)})})};t.on("init",function(){Cc.setEditorTimeout(t,o,0)})},ML=function(e){PL(e),LL(e),Gd(e)&&IL(e)},FL=function(t){var n=es(function(){if(!t.removed&&t.getBody().contains(e.document.activeElement)){var n=t.selection.getRng();if(n.collapsed){var r=fA(t,t.selection.getRng(),!1);t.selection.setRng(r)}}},0);t.on("focus",function(){n.throttle()}),t.on("blur",function(){n.cancel()})},UL=jo,zL=Ho,jL=function(e,t){for(var n=e.getBody();t&&t!==n;){if(UL(t)||zL(t))return t;t=t.parentNode}return null},HL=function(e){var t,n=function(t){return e.dom.isBlock(t)},r=e.getBody(),o=gm(e,r,n,function(){return uC(e)}),i="sel-"+e.dom.uniqueId(),a=function(t){return e.dom.hasClass(t,"mce-offscreen-selection")},u=function(){var t=e.dom.get(i);return t?t.getElementsByTagName("*")[0]:t},c=function(t){t&&e.selection.setRng(t)},s=function(){return e.selection.getRng()},f=function(t,n,r,i){void 0===i&&(i=!0);var a=e.fire("ShowCaret",{target:n,direction:t,before:r});return a.isDefaultPrevented()?null:(i&&e.selection.scrollIntoView(n,t===-1),o.show(r,n))},l=function(t){t.hasAttribute("data-mce-caret")&&(of(t),c(s()),e.selection.scrollIntoView(t))},d=function(){e.on("mouseup",function(t){var n=s();n.collapsed&&XN(e,t.clientX,t.clientY)&&c(sA(e,n,!1))}),e.on("click",function(t){var n=jL(e,t.target);n&&(zL(n)&&(t.preventDefault(),e.focus()),UL(n)&&e.dom.isChildOf(n,e.selection.getNode())&&v())}),e.on("blur NewBlock",function(){v()}),e.on("ResizeWindow FullscreenStateChanged",function(){return o.reposition()});var n=function(e){e.on("tap",function(t){var n=jL(e,t.target);zL(n)&&(t.preventDefault(),h(cA(e,n)))},!0)},i=function(e){var t=tp(e);if(!e.firstChild)return!1;var n=ul.before(e.firstChild),r=t.next(n);return r&&!Bh(r)&&!Ph(r)},l=function(t,n){var r=e.dom.getParent(t,e.dom.isBlock),o=e.dom.getParent(n,e.dom.isBlock);return r===o},d=function(t,n){var r=e.dom.getParent(t,e.dom.isBlock),o=e.dom.getParent(n,e.dom.isBlock);return!(!r||!e.dom.isChildOf(r,o)||zL(jL(e,r))!==!1)||r&&!l(r,o)&&i(r)};n(e),e.on("mousedown",function(t){var n=t.target;if((n===r||"HTML"===n.nodeName||e.dom.isChildOf(n,r))&&XN(e,t.clientX,t.clientY)!==!1){var o=jL(e,n);if(o)zL(o)?(t.preventDefault(),h(cA(e,o))):(v(),UL(o)&&t.shiftKey||Sk(t.clientX,t.clientY,e.selection.getRng())||(b(),e.selection.placeCaretAt(t.clientX,t.clientY)));else if(vm(n)===!1){v(),b();var i=rA(r,t.clientX,t.clientY);if(i&&!d(t.target,i.node)){t.preventDefault();var a=f(1,i.node,i.before,!1);e.getBody().focus(),c(a)}}}}),e.on("keypress",function(t){if(!Nk.modifierPressed(t))switch(t.keyCode){default:zL(e.selection.getNode())&&t.preventDefault()}}),e.on("GetSelectionRange",function(e){var n=e.range;if(t){if(!t.parentNode)return void(t=null);n=n.cloneRange(),n.selectNode(t),e.range=n}}),e.on("SetSelectionRange",function(e){e.range=g(e.range);var t=h(e.range,e.forward);t&&(e.range=t)});var m=function(e){return"mcepastebin"===e.id};e.on("AfterSetSelectionRange",function(e){var t=e.range;p(t)||m(t.startContainer.parentNode)||b(),a(t.startContainer.parentNode)||v()}),e.on("copy",function(e){var t=e.clipboardData;if(!e.isDefaultPrevented()&&e.clipboardData&&!jn.ie){var n=u();n&&(e.preventDefault(),t.clearData(),t.setData("text/html",n.outerHTML),t.setData("text/plain",n.outerText))}}),ML(e),FL(e)},m=function(e){return Xs(e)||tf(e)||nf(e)},p=function(e){return m(e.startContainer)||m(e.endContainer)},g=function(t){var n=e.schema.getShortEndedElements(),r=e.dom.createRng(),o=t.startContainer,i=t.startOffset,a=t.endContainer,u=t.endOffset;return Et(n,o.nodeName.toLowerCase())?0===i?r.setStartBefore(o):r.setStartAfter(o):r.setStart(o,i),Et(n,a.nodeName.toLowerCase())?0===u?r.setEndBefore(a):r.setEndAfter(a):r.setEnd(a,u),r},h=function(n,o){var a,u,c,s,l,d,m,g=e.$,h=e.dom;if(!n)return null;if(n.collapsed){if(!p(n))if(o===!1){if(l=Fm(-1,r,n),vm(l.getNode(!0)))return f(-1,l.getNode(!0),!1,!1);if(vm(l.getNode()))return f(-1,l.getNode(),!l.isAtEnd(),!1)}else{if(l=Fm(1,r,n),vm(l.getNode()))return f(1,l.getNode(),!l.isAtEnd(),!1);if(vm(l.getNode(!0)))return f(1,l.getNode(!0),!1,!1)}return null}c=n.startContainer,s=n.startOffset;var v=n.endOffset;if(3===c.nodeType&&0===s&&zL(c.parentNode)&&(c=c.parentNode,s=h.nodeIndex(c),c=c.parentNode),1!==c.nodeType)return null;if(v===s+1&&c===n.endContainer&&(a=c.childNodes[s]),!zL(a))return null;d=m=a.cloneNode(!0);var y=e.fire("ObjectSelected",{target:a,targetClone:d});if(y.isDefaultPrevented())return null;u=ys(ar.fromDom(e.getBody()),"#"+i).fold(function(){return g([])},function(e){return g([e.dom()])}),d=y.targetClone,0===u.length&&(u=g('<div data-mce-bogus="all" class="mce-offscreen-selection"></div>').attr("id",i),u.appendTo(e.getBody())),n=e.dom.createRng(),d===m&&jn.ie?(u.empty().append('<p style="font-size: 0" data-mce-bogus="all"> </p>').append(d),n.setStartAfter(u[0].firstChild.firstChild),n.setEndAfter(d)):(u.empty().append(da).append(d).append(da),n.setStart(u[0].firstChild,1),n.setEnd(u[0].lastChild,0)),u.css({top:h.getPos(a,e.getBody()).y}),u[0].focus();var C=e.selection.getSel();C.removeAllRanges(),C.addRange(n);var w=ar.fromDom(a);return Xe(ps(ar.fromDom(e.getBody()),"*[data-mce-selected]"),function(e){Tr(w,e)||Go(e,"data-mce-selected")}),e.dom.getAttrib(a,"data-mce-selected")||a.setAttribute("data-mce-selected","1"),t=a,b(),n},v=function(){t&&(t.removeAttribute("data-mce-selected"),ys(ar.fromDom(e.getBody()),"#"+i).each(co),t=null),ys(ar.fromDom(e.getBody()),"#"+i).each(co),t=null},y=function(){o.destroy(),t=null},b=function(){o.hide()};return jn.ceFalse&&d(),{showCaret:f,showBlockCaretContainer:l,hideFakeCaret:b,destroy:y}},VL=function(t){var n=er.each,r=Nk.BACKSPACE,o=Nk.DELETE,i=t.dom,a=t.selection,u=t.parser,c=jn.gecko,s=jn.ie,f=jn.webkit,l="data:text/mce-internal,",d=s?"Text":"URL",m=function(e,n){try{t.getDoc().execCommand(e,!1,n)}catch(r){}},p=function(e){return e.isDefaultPrevented()},g=function(e){var n,r;e.dataTransfer&&(t.selection.isCollapsed()&&"IMG"===e.target.tagName&&a.select(e.target),n=t.selection.getContent(),n.length>0&&(r=l+escape(t.id)+","+escape(n),e.dataTransfer.setData(d,r)))},h=function(e){var t;return e.dataTransfer&&(t=e.dataTransfer.getData(d),t&&t.indexOf(l)>=0)?(t=t.substr(l.length).split(","),{id:unescape(t[0]),html:unescape(t[1])}):null},v=function(e,n){t.queryCommandSupported("mceInsertClipboardContent")?t.execCommand("mceInsertClipboardContent",!1,{content:e,internal:n}):t.execCommand("mceInsertContent",!1,e)},y=function(){var e=function(e){var t=i.create("body"),n=e.cloneContents();return t.appendChild(n),a.serializer.serialize(t,{format:"html"})},n=function(n){var r=e(n),o=i.createRng();o.selectNode(t.getBody());var a=e(o);return r===a};t.on("keydown",function(e){var a,u,c=e.keyCode;if(!p(e)&&(c===o||c===r)){if(a=t.selection.isCollapsed(),u=t.getBody(),a&&!i.isEmpty(u))return;if(!a&&!n(t.selection.getRng()))return;e.preventDefault(),t.setContent(""),u.firstChild&&i.isBlock(u.firstChild)?t.selection.setCursorLocation(u.firstChild,0):t.selection.setCursorLocation(u,0),t.nodeChanged()}})},b=function(){t.shortcuts.add("meta+a",null,"SelectAll")},C=function(){t.inline||i.bind(t.getDoc(),"mousedown mouseup",function(e){var n;if(e.target===t.getDoc().documentElement)if(n=a.getRng(),t.getBody().focus(),"mousedown"===e.type){if(Xs(n.startContainer))return;a.placeCaretAt(e.clientX,e.clientY)}else a.setRng(n)})},w=function(){t.on("keydown",function(e){if(!p(e)&&e.keyCode===r){if(!t.getBody().getElementsByTagName("hr").length)return;if(a.isCollapsed()&&0===a.getRng().startOffset){var n=a.getNode(),o=n.previousSibling;if("HR"===n.nodeName)return i.remove(n),void e.preventDefault();o&&o.nodeName&&"hr"===o.nodeName.toLowerCase()&&(i.remove(o),e.preventDefault())}}})},x=function(){e.Range.prototype.getClientRects||t.on("mousedown",function(e){if(!p(e)&&"HTML"===e.target.nodeName){var n=t.getBody();n.blur(),Cc.setEditorTimeout(t,function(){n.focus()})}})},S=function(){t.on("click",function(e){var n=e.target;/^(IMG|HR)$/.test(n.nodeName)&&"false"!==i.getContentEditableParent(n)&&(e.preventDefault(),t.selection.select(n),t.nodeChanged()),"A"===n.nodeName&&i.hasClass(n,"mce-item-anchor")&&(e.preventDefault(),a.select(n))})},N=function(){var e=function(){var e=i.getAttribs(a.getStart().cloneNode(!1));return function(){var r=a.getStart();r!==t.getBody()&&(i.setAttrib(r,"style",null),n(e,function(e){r.setAttributeNode(e.cloneNode(!0))}))}},r=function(){return!a.isCollapsed()&&i.getParent(a.getStart(),i.isBlock)!==i.getParent(a.getEnd(),i.isBlock)};t.on("keypress",function(n){var o;if(!p(n)&&(8===n.keyCode||46===n.keyCode)&&r())return o=e(),t.getDoc().execCommand("delete",!1,null),o(),n.preventDefault(),!1}),i.bind(t.getDoc(),"cut",function(n){var o;!p(n)&&r()&&(o=e(),Cc.setEditorTimeout(t,function(){o()}))})},E=function(){t.on("keydown",function(e){if(!p(e)&&e.keyCode===r&&a.isCollapsed()&&0===a.getRng().startOffset){var t=a.getNode().previousSibling;if(t&&t.nodeName&&"table"===t.nodeName.toLowerCase())return e.preventDefault(),!1}})},k=function(){t.on("keydown",function(e){var n,r;if(!p(e)&&e.keyCode===Nk.BACKSPACE){n=a.getRng();var o=n.startContainer,u=n.startOffset,c=i.getRoot();if(r=o,n.collapsed&&0===u){for(;r&&r.parentNode&&r.parentNode.firstChild===r&&r.parentNode!==c;)r=r.parentNode;"BLOCKQUOTE"===r.tagName&&(t.formatter.toggle("blockquote",null,r),n=i.createRng(),n.setStart(o,0),n.setEnd(o,0),a.setRng(n))}}})},_=function(){var e=function(){m("StyleWithCSS",!1),m("enableInlineTableEditing",!1),Ed(t)||m("enableObjectResizing",!1)};Wd(t)||t.on("BeforeExecCommand mousedown",e)},T=function(){var e=function(){n(i.select("a"),function(e){var t=e.parentNode,n=i.getRoot();if(t.lastChild===e){for(;t&&!i.isBlock(t);){if(t.parentNode.lastChild!==t||t===n)return;t=t.parentNode}i.add(t,"br",{"data-mce-bogus":1})}})};t.on("SetContent ExecCommand",function(t){"setcontent"!==t.type&&"mceInsertLink"!==t.command||e()})},R=function(){Ql(t)&&t.on("init",function(){m("DefaultParagraphSeparator",Ql(t))})},A=function(){t.on("keyup focusin mouseup",function(e){Nk.modifierPressed(e)||a.normalize()},!0)},D=function(){t.contentStyles.push("img:-moz-broken {-moz-force-broken-image-icon:1;min-width:24px;min-height:24px}")},O=function(){t.inline||t.on("keydown",function(){e.document.activeElement===e.document.body&&t.getWin().focus()})},B=function(){t.inline||(t.contentStyles.push("body {min-height: 150px}"),t.on("click",function(e){var n;if("HTML"===e.target.nodeName){if(jn.ie>11)return void t.getBody().focus();n=t.selection.getRng(),t.getBody().focus(),t.selection.setRng(n),t.selection.normalize(),t.nodeChanged()}}))},P=function(){jn.mac&&t.on("keydown",function(e){if(Nk.metaKeyPressed(e)&&!e.shiftKey&&(37===e.keyCode||39===e.keyCode)){e.preventDefault();var n=t.selection.getSel();n.modify("move",37===e.keyCode?"backward":"forward","lineboundary")}})},L=function(){m("AutoUrlDetect",!1)},I=function(){t.on("click",function(e){var t=e.target;do if("A"===t.tagName)return void e.preventDefault();while(t=t.parentNode)}),t.contentStyles.push(".mce-content-body {-webkit-touch-callout: none}")},M=function(){t.on("init",function(){t.dom.bind(t.getBody(),"submit",function(e){e.preventDefault()})})},F=function(){u.addNodeFilter("br",function(e){for(var t=e.length;t--;)"Apple-interchange-newline"===e[t].attr("class")&&e[t].remove()})},U=function(){t.on("dragstart",function(e){g(e)}),t.on("drop",function(e){if(!p(e)){var n=h(e);if(n&&n.id!==t.id){e.preventDefault();var r=KE(e.x,e.y,t.getDoc());a.setRng(r),v(n.html,!0)}}})},z=function(){},j=function(){if(!c||t.removed)return!1;var e=t.selection.getSel();return!e||!e.rangeCount||0===e.rangeCount};return k(),y(),jn.windowsPhone||A(),f&&(C(),S(),R(),M(),E(),F(),jn.iOS?(O(),B(),I()):b()),jn.ie>=11&&(B(),E()),jn.ie&&(b(),L(),U()),c&&(w(),x(),N(),_(),T(),D(),P(),E()),{refreshContentEditable:z,isHidden:j}},qL=Ac.DOM,$L=function(e,t){var n=ar.fromDom(e.getDoc().head),r=ar.fromTag("style");$o(r,"type","text/css"),ro(r,ar.fromText(t)),ro(n,r)},WL=function(e){return e.inline?e.getElement().nodeName.toLowerCase():void 0},KL=function(e){return wt(e,function(e){return Me(e)===!1})},XL=function(e){var t=e.settings,n=e.editorUpload.blobCache;return KL({allow_conditional_comments:t.allow_conditional_comments,allow_html_data_urls:t.allow_html_data_urls,allow_html_in_named_anchor:t.allow_html_in_named_anchor,allow_script_urls:t.allow_script_urls,allow_unsafe_link_target:t.allow_unsafe_link_target,convert_fonts_to_spans:t.convert_fonts_to_spans,fix_list_elements:t.fix_list_elements,font_size_legacy_values:t.font_size_legacy_values,forced_root_block:t.forced_root_block,forced_root_block_attrs:t.forced_root_block_attrs,padd_empty_with_br:t.padd_empty_with_br,preserve_cdata:t.preserve_cdata,remove_trailing_brs:t.remove_trailing_brs,inline_styles:t.inline_styles,root_name:WL(e),validate:!0,blob_cache:n,images_dataimg_filter:t.images_dataimg_filter})},YL=function(e){var t=e.settings;return It(It({},XL(e)),KL({url_converter:t.url_converter,url_converter_scope:t.url_converter_scope,element_format:t.element_format,entities:t.entities,entity_encoding:t.entity_encoding,indent:t.indent,indent_after:t.indent_after,indent_before:t.indent_before,block_elements:t.block_elements,boolean_attributes:t.boolean_attributes,custom_elements:t.custom_elements,extended_valid_elements:t.extended_valid_elements,invalid_elements:t.invalid_elements,invalid_styles:t.invalid_styles,move_caret_before_on_enter_elements:t.move_caret_before_on_enter_elements,non_empty_elements:t.non_empty_elements,schema:t.schema,self_closing_elements:t.self_closing_elements,short_ended_elements:t.short_ended_elements,special:t.special,text_block_elements:t.text_block_elements,text_inline_elements:t.text_inline_elements,valid_children:t.valid_children,valid_classes:t.valid_classes,valid_elements:t.valid_elements,valid_styles:t.valid_styles,verify_html:t.verify_html,whitespace_elements:t.whitespace_elements}))},GL=function(e){var t=f_(XL(e),e.schema);return t.addAttributeFilter("src,href,style,tabindex",function(t,n){for(var r,o,i=t.length,a=e.dom,u="data-mce-"+n;i--;)if(r=t[i],o=r.attr(n),o&&!r.attr(u)){if(0===o.indexOf("data:")||0===o.indexOf("blob:"))continue;"style"===n?(o=a.serializeStyle(a.parseStyle(o),r.name),o.length||(o=null),r.attr(u,o),r.attr(n,o)):"tabindex"===n?(r.attr(u,o),r.attr(n,null)):r.attr(u,e.convertURL(o,n,r.name))}}),t.addNodeFilter("script",function(e){for(var t=e.length;t--;){var n=e[t],r=n.attr("type")||"no/type";0!==r.indexOf("mce-")&&n.attr("type","mce-"+r)}}),e.settings.preserve_cdata&&t.addNodeFilter("#cdata",function(t){for(var n=t.length;n--;){var r=t[n];r.type=8,r.name="#comment",r.value="[CDATA["+e.dom.encode(r.value)+"]]"}}),t.addNodeFilter("p,h1,h2,h3,h4,h5,h6,div",function(t){for(var n=t.length,r=e.schema.getNonEmptyElements();n--;){var o=t[n];o.isEmpty(r)&&0===o.getAll("br").length&&(o.append(new Zg("br",1)).shortEnded=!0)}}),t},JL=function(e){e.settings.auto_focus&&Cc.setEditorTimeout(e,function(){var t;t=e.settings.auto_focus===!0?e:e.editorManager.get(e.settings.auto_focus),t.destroyed||t.focus()},100)},QL=function(e){var t=e.dom.getRoot();e.inline||Mg(e)&&e.selection.getStart(!0)!==t||gp(t).each(function(t){var n=t.getNode(),r=Bo(n)?gp(n).getOr(t):t;jn.browser.isIE()?Bb(e,r.toRange()):e.selection.setRng(r.toRange())})},ZL=function(e){e.bindPendingEventDelegates(),e.initialized=!0,GS(e),e.focus(!0),QL(e),e.nodeChanged({initial:!0}),e.execCallback("init_instance_callback",e),JL(e)},eI=function(e){return e.inline?qL.styleSheetLoader:e.dom.styleSheetLoader},tI=function(e,t){var n=e.settings,r=e.getDoc(),o=e.getBody();n.browser_spellcheck||n.gecko_spellcheck||(r.body.spellcheck=!1,qL.setAttrib(o,"spellcheck","false")),e.quirks=VL(e),YS(e);var i=Sd(e);if(void 0!==i&&(o.dir=i),n.protect&&e.on("BeforeSetContent",function(e){
er.each(n.protect,function(t){e.content=e.content.replace(t,function(e){return"<!--mce:protected "+escape(e)+"-->"})})}),e.on("SetContent",function(){e.addVisual(e.getBody())}),t===!1&&e.load({initial:!0,format:"html"}),e.startContent=e.getContent({format:"raw"}),e.on("compositionstart compositionend",function(t){e.composing="compositionstart"===t.type}),e.contentStyles.length>0){var a="";er.each(e.contentStyles,function(e){a+=e+"\r\n"}),e.dom.addStyle(a)}eI(e).loadAll(e.contentCSS,function(t){ZL(e)},function(t){ZL(e)}),n.content_style&&$L(e,n.content_style)},nI=function(t,n){var r=t.settings,i=t.getElement(),a=t.getDoc();r.inline||(t.getElement().style.visibility=t.orgVisibility),n||t.inline||(a.open(),a.write(t.iframeHTML),a.close()),t.inline&&(qL.addClass(i,"mce-content-body"),t.contentDocument=a=e.document,t.contentWindow=e.window,t.bodyElement=i,t.contentAreaContainer=i);var u=t.getBody();u.disabled=!0,t.readonly=!!r.readonly,t.readonly||(t.inline&&"static"===qL.getStyle(u,"position",!0)&&(u.style.position="relative"),u.contentEditable=t.getParam("content_editable_state",!0)),u.disabled=!1,t.editorUpload=T_(t),t.schema=o(r),t.dom=Ac(a,{keep_values:!0,url_converter:t.convertURL,url_converter_scope:t,hex_colors:r.force_hex_style_colors,update_styles:!0,root_element:t.inline?t.getBody():null,collect:function(){return t.inline},schema:t.schema,contentCssCors:hd(t),referrerPolicy:vd(t),onSetAttrib:function(e){t.fire("SetAttrib",e)}}),t.parser=GL(t),t.serializer=S_(YL(t),t),t.selection=Bk(t.dom,t.getWin(),t.serializer,t),t.annotator=Xg(t),t.formatter=V_(t),t.undoManager=W_(t),t._nodeChangeDispatcher=new nL(t),t._selectionOverrides=HL(t),iT(t),iL(t),hS(t)||cL(t),tL(t),lT(t),eT(t),XS(t),vS(t).fold(function(){tI(t,!1)},function(e){t.setProgressState(!0),e.then(function(e){t.setProgressState(!1),tI(t,e)})})},rI=Ac.DOM,oI=function(t,n){if(e.document.domain!==e.window.location.hostname&&jn.browser.isIE()){var r=k_("mce");t[r]=function(){nI(t)};var o='javascript:(function(){document.open();document.domain="'+e.document.domain+'";var ed = window.parent.tinymce.get("'+t.id+'");document.write(ed.iframeHTML);document.close();ed.'+r+"(true);})()";return rI.setAttrib(n,"src",o),!0}return!1},iI=function(e,t,n,r){var o=ar.fromTag("iframe");return Wo(o,r),Wo(o,{id:e+"_ifr",frameBorder:"0",allowTransparency:"true",title:t}),ss(o,"tox-edit-area__iframe"),o},aI=function(e){var t=Wl(e)+"<html><head>";Kl(e)!==e.documentBaseUrl&&(t+='<base href="'+e.documentBaseURI.getURI()+'" />'),t+='<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />';var n=Xl(e),r=Yl(e);return Gl(e)&&(t+='<meta http-equiv="Content-Security-Policy" content="'+Gl(e)+'" />'),t+='</head><body id="'+n+'" class="mce-content-body '+r+'" data-id="'+e.id+'"><br></body></html>'},uI=function(e,t){var n=e.editorManager.translate("Rich Text Area. Press ALT-0 for help."),r=iI(e.id,n,t.height,$l(e)).dom();r.onload=function(){r.onload=null,e.fire("load")};var o=oI(e,r);return e.contentAreaContainer=t.iframeContainer,e.iframeElement=r,e.iframeHTML=aI(e),rI.add(t.iframeContainer,r),o},cI=function(e,t){var n=uI(e,t);t.editorContainer&&(rI.get(t.editorContainer).style.display=e.orgDisplay,e.hidden=rI.isHidden(t.editorContainer)),e.getElement().style.display="none",rI.setAttrib(e.id,"aria-hidden","true"),n||nI(e)},sI=Ac.DOM,fI=function(e,t,n){var r=JN.get(n),o=JN.urls[n]||e.documentBaseUrl.replace(/\/$/,"");if(n=er.trim(n),r&&er.inArray(t,n)===-1){if(er.each(JN.dependencies(n),function(n){fI(e,t,n)}),e.plugins[n])return;try{var i=new r(e,o,e.$);e.plugins[n]=i,i.init&&(i.init(e,o),t.push(n))}catch(a){cE(e,n,a)}}},lI=function(e){return e.replace(/^\-/,"")},dI=function(e){var t=[];er.each(Xd(e).split(/[ ,]/),function(n){fI(e,t,lI(n))})},mI=function(e){var t=er.trim(fd(e)),n=e.ui.registry.getAll().icons,r=It(It({},FN.get("default").icons),FN.get(t).icons);gt(r,function(t,r){Et(n,r)||e.ui.registry.addIcon(r,t)})},pI=function(e){var t=Ad(e);if(Oe(t)){e.settings.theme=lI(t);var n=QN.get(t);e.theme=new n(e,QN.urls[t]),e.theme.init&&e.theme.init(e,QN.urls[t]||e.documentBaseUrl.replace(/\/$/,""),e.$)}else e.theme={}},gI=function(e){return e.theme.renderUI()},hI=function(e){var t=e.getElement(),n=Ad(e),r=n(e,t);return r.editorContainer.nodeType&&(r.editorContainer.id=r.editorContainer.id||e.id+"_parent"),r.iframeContainer&&r.iframeContainer.nodeType&&(r.iframeContainer.id=r.iframeContainer.id||e.id+"_iframecontainer"),r.height=r.iframeHeight?r.iframeHeight:t.offsetHeight,r},vI=function(e){return{editorContainer:e,iframeContainer:e}},yI=function(e){var t=sI.create("div");return sI.insertAfter(t,e),vI(t)},bI=function(e){var t=e.getElement();return e.inline?vI(null):yI(t)},CI=function(e){var t=e.getElement();return e.orgDisplay=t.style.display,Oe(Ad(e))?gI(e):Fe(Ad(e))?hI(e):bI(e)},wI=function(e){e.fire("ScriptsLoaded"),mI(e),pI(e),dI(e);var t=CI(e);return e.editorContainer=t.editorContainer?t.editorContainer:null,dE(e),e.inline?nI(e):cI(e,t)},xI=Ac.DOM,SI=function(e){return"-"===e.charAt(0)},NI=function(e,t){var n=yd(t),r=bd(t);if(Qc.hasCode(n)===!1&&"en"!==n){var o=""!==r?r:t.editorManager.baseURL+"/langs/"+n+".js";e.add(o,pe,void 0,function(){uE(t,o,n)})}},EI=function(e,t,n,r){var o=Ad(t);if(Oe(o)){if(!SI(o)&&!QN.urls.hasOwnProperty(o)){var i=Id(t);i?QN.load(o,t.documentBaseURI.toAbsolute(i)):QN.load(o,"themes/"+o+"/theme"+n+".js")}e.loadQueue(function(){QN.waitFor(o,r)})}else r()},kI=function(e){return _e.from(ld(e)).filter(function(e){return e.length>0}).map(function(e){return{url:e,name:_e.none()}})},_I=function(e,t,n){return _e.from(t).filter(function(e){return e.length>0&&!FN.has(e)}).map(function(t){return{url:e.editorManager.baseURL+"/icons/"+t+"/icons"+n+".js",name:_e.some(t)}})},TI=function(e,t,n){var r=_I(t,"default",n),o=kI(t).orThunk(function(){return _I(t,fd(t),"")});Xe(uf([r,o]),function(n){e.add(n.url,pe,void 0,function(){aE(t,n.url,n.name.getOrUndefined())})})},RI=function(e,t){er.each(Yd(e),function(t,n){JN.load(n,t,pe,void 0,function(){iE(e,t,n)}),e.settings.plugins+=" "+n}),er.each(Xd(e).split(/[ ,]/),function(n){if(n=er.trim(n),n&&!JN.urls[n])if(SI(n)){n=n.substr(1,n.length);var r=JN.dependencies(n);er.each(r,function(n){var r={prefix:"plugins/",resource:n,suffix:"/plugin"+t+".js"},o=JN.createUrl(r,n);JN.load(o.resource,o,pe,void 0,function(){iE(e,o.prefix+o.resource+o.suffix,o.resource)})})}else{var o={prefix:"plugins/",resource:n,suffix:"/plugin"+t+".js"};JN.load(n,o,pe,void 0,function(){iE(e,o.prefix+o.resource+o.suffix,n)})}})},AI=function(e,t){var n=Fc.ScriptLoader;EI(n,e,t,function(){NI(n,e),TI(n,e,t),RI(e,t),n.loadQueue(function(){e.removed||wI(e)},e,function(){e.removed||wI(e)})})},DI=function(e,t){return xc.forElement(e,{contentCssCors:Kd(t),referrerPolicy:vd(t)})},OI=function(t){var n=t.id;Qc.setCode(yd(t));var r=function(){xI.unbind(e.window,"ready",r),t.render()};if(!Ta.Event.domLoaded)return void xI.bind(e.window,"ready",r);if(t.getElement()&&jn.contentEditable){var o=ar.fromDom(t.getElement()),i=Jo(o);t.on("remove",function(){Ye(o.dom().attributes,function(e){return Go(o,e.name)}),Wo(o,i)}),t.ui.styleSheetLoader=DI(o,t),Md(t)?t.inline=!0:(t.orgVisibility=t.getElement().style.visibility,t.getElement().style.visibility="hidden");var a=t.getElement().form||xI.getParent(n,"form");a&&(t.formElement=a,Fd(t)&&!Lo(t.getElement())&&(xI.insertAfter(xI.create("input",{type:"hidden",name:n}),n),t.hasHiddenInput=!0),t.formEventDelegate=function(e){t.fire(e.type,e)},xI.bind(a,"submit reset",t.formEventDelegate),t.on("reset",function(){t.resetContent()}),!Ud(t)||a.submit.nodeType||a.submit.length||a._mceOldSubmit||(a._mceOldSubmit=a.submit,a.submit=function(){return t.editorManager.triggerSave(),t.setDirty(!1),a._mceOldSubmit(a)})),t.windowManager=ZN(t),t.notificationManager=R(t),zd(t)&&t.on("GetContent",function(e){e.save&&(e.content=xI.encode(e.content))}),jd(t)&&t.on("submit",function(){t.initialized&&t.save()}),Hd(t)&&(t._beforeUnload=function(){!t.initialized||t.destroyed||t.isHidden()||t.save({format:"raw",no_events:!0,set_dirty:!1})},t.editorManager.on("BeforeUnload",t._beforeUnload)),t.editorManager.add(t),AI(t,t.suffix)}},BI=function(e){return Fe(e)?e:ve(!1)},PI=function(e,t,n){for(var r=e.dom(),o=BI(n);r.parentNode;){r=r.parentNode;var i=ar.fromDom(r),a=t(i);if(a.isSome())return a;if(o(i))break}return _e.none()},LI=function(e,t,n){var r=t(e),o=BI(n);return r.orThunk(function(){return o(e)?_e.none():PI(e,t,o)})},II={"font-size":"size","font-family":"face"},MI=function(e,t,n){var r=function(t){return ni(t,e).orThunk(function(){return"font"===dr(t)?Nt(II,e).bind(function(e){return Xo(t,e)}):_e.none()})},o=function(e){return Tr(ar.fromDom(t),e)};return LI(ar.fromDom(n),function(e){return r(e)},o)},FI=function(e){return e.replace(/[\'\"\\]/g,"").replace(/,\s+/g,",")},UI=function(e,t){return _e.from(Ac.DOM.getStyle(t,e,!0))},zI=function(e){return function(t,n){return _e.from(n).map(ar.fromDom).filter(hr).bind(function(n){return MI(e,t,n.dom()).or(UI(e,n.dom()))}).getOr("")}},jI=zI("font-size"),HI=ge(FI,zI("font-family")),VI=function(e){return gp(e.getBody()).map(function(e){var t=e.container();return Io(t)?t.parentNode:t})},qI=function(e,t){return e.startContainer===t&&0===e.startOffset},$I=function(e){return _e.from(e.selection.getRng()).bind(function(t){var n=e.getBody();return qI(t,n)?_e.none():_e.from(e.selection.getStart(!0))})},WI=function(e,t){if(/^[0-9\.]+$/.test(t)){var n=parseInt(t,10);if(n>=1&&n<=7){var r=od(e),o=id(e);return o?o[n-1]||t:r[n-1]||t}return t}return t},KI=function(e){var t=e.split(/\s*,\s*/);return Ke(t,function(e){return e.indexOf(" ")===-1||yn(e,'"')||yn(e,"'")?e:"'"+e+"'"}).join(",")},XI=function(e,t){var n=WI(e,t);e.formatter.toggle("fontname",{value:KI(n)}),e.nodeChanged()},YI=function(e){return $I(e).fold(function(){return VI(e).map(function(t){return HI(e.getBody(),t)}).getOr("")},function(t){return HI(e.getBody(),t)})},GI=function(e,t){e.formatter.toggle("fontsize",{value:WI(e,t)}),e.nodeChanged()},JI=function(e){return $I(e).fold(function(){return VI(e).map(function(t){return jI(e.getBody(),t)}).getOr("")},function(t){return jI(e.getBody(),t)})},QI=function(e){var t;return"string"!=typeof e?(t=er.extend({paste:e.paste,data:{paste:e.paste}},e),{content:e.content,details:t}):{content:e,details:{}}},ZI=function(e,t){var n=QI(t);IS(e,n.content,n.details)},eM=function(e,t){e.getDoc().execCommand(t,!1,null)},tM=function(e){nB(e)||bO(e,!1)||SO(e,!1)||AO(e,!1)||zD(e,!1)||ly(e)||KD(e)||LO(e,!1)||(eM(e,"Delete"),yD(e))},nM=function(e){bO(e,!0)||SO(e,!0)||AO(e,!0)||zD(e,!0)||ly(e)||KD(e)||LO(e,!0)||eM(e,"ForwardDelete")},rM=er.each,oM=er.map,iM=er.inArray,aM=function(){function e(e){this.commands={state:{},exec:{},value:{}},this.editor=e,this.setupCommands(e)}return e.prototype.execCommand=function(e,t,n,r){var o,i=!1,a=this;if(!a.editor.removed){if(/^(mceAddUndoLevel|mceEndUndoLevel|mceBeginUndoLevel|mceRepaint)$/.test(e)||r&&r.skip_focus?Lb(a.editor):a.editor.focus(),r=a.editor.fire("BeforeExecCommand",{command:e,ui:t,value:n}),r.isDefaultPrevented())return!1;var u=e.toLowerCase();if(o=a.commands.exec[u])return o(u,t,n),a.editor.fire("ExecCommand",{command:e,ui:t,value:n}),!0;if(rM(this.editor.plugins,function(r){if(r.execCommand&&r.execCommand(e,t,n))return a.editor.fire("ExecCommand",{command:e,ui:t,value:n}),i=!0,!1}),i)return i;if(a.editor.theme&&a.editor.theme.execCommand&&a.editor.theme.execCommand(e,t,n))return a.editor.fire("ExecCommand",{command:e,ui:t,value:n}),!0;try{i=a.editor.getDoc().execCommand(e,t,n)}catch(c){}return!!i&&(a.editor.fire("ExecCommand",{command:e,ui:t,value:n}),!0)}},e.prototype.queryCommandState=function(e){var t;if(!this.editor.quirks.isHidden()&&!this.editor.removed){if(e=e.toLowerCase(),t=this.commands.state[e])return t(e);try{return this.editor.getDoc().queryCommandState(e)}catch(n){}return!1}},e.prototype.queryCommandValue=function(e){var t;if(!this.editor.quirks.isHidden()&&!this.editor.removed){if(e=e.toLowerCase(),t=this.commands.value[e])return t(e);try{return this.editor.getDoc().queryCommandValue(e)}catch(n){}}},e.prototype.addCommands=function(e,t){var n=this;t=t||"exec",rM(e,function(e,r){rM(r.toLowerCase().split(","),function(r){n.commands[t][r]=e})})},e.prototype.addCommand=function(e,t,n){var r=this;e=e.toLowerCase(),this.commands.exec[e]=function(e,o,i,a){return t.call(n||r.editor,o,i,a)}},e.prototype.queryCommandSupported=function(e){if(e=e.toLowerCase(),this.commands.exec[e])return!0;try{return this.editor.getDoc().queryCommandSupported(e)}catch(t){}return!1},e.prototype.addQueryStateHandler=function(e,t,n){var r=this;e=e.toLowerCase(),this.commands.state[e]=function(){return t.call(n||r.editor)}},e.prototype.addQueryValueHandler=function(e,t,n){var r=this;e=e.toLowerCase(),this.commands.value[e]=function(){return t.call(n||r.editor)}},e.prototype.hasCustomCommand=function(e){return e=e.toLowerCase(),!!this.commands.exec[e]},e.prototype.execNativeCommand=function(e,t,n){return void 0===t&&(t=!1),void 0===n&&(n=null),this.editor.getDoc().execCommand(e,t,n)},e.prototype.isFormatMatch=function(e){return this.editor.formatter.match(e)},e.prototype.toggleFormat=function(e,t){this.editor.formatter.toggle(e,t?{value:t}:void 0),this.editor.nodeChanged()},e.prototype.storeSelection=function(e){this.selectionBookmark=this.editor.selection.getBookmark(e)},e.prototype.restoreSelection=function(){this.editor.selection.moveToBookmark(this.selectionBookmark)},e.prototype.setupCommands=function(e){var t=this;this.addCommands({"mceResetDesignMode,mceBeginUndoLevel":function(){},"mceEndUndoLevel,mceAddUndoLevel":function(){e.undoManager.add()},"Cut,Copy,Paste":function(n){var r,o=e.getDoc();try{t.execNativeCommand(n)}catch(i){r=!0}if("paste"!==n||o.queryCommandEnabled(n)||(r=!0),r||!o.queryCommandSupported(n)){var a=e.translate("Your browser doesn't support direct access to the clipboard. Please use the Ctrl+X/C/V keyboard shortcuts instead.");jn.mac&&(a=a.replace(/Ctrl\+/g,"⌘+")),e.notificationManager.open({text:a,type:"error"})}},unlink:function(){if(e.selection.isCollapsed()){var t=e.dom.getParent(e.selection.getStart(),"a");return void(t&&e.dom.remove(t,!0))}e.formatter.remove("link")},"JustifyLeft,JustifyCenter,JustifyRight,JustifyFull,JustifyNone":function(n){var r=n.substring(7);"full"===r&&(r="justify"),rM("left,center,right,justify".split(","),function(t){r!==t&&e.formatter.remove("align"+t)}),"none"!==r&&t.toggleFormat("align"+r)},"InsertUnorderedList,InsertOrderedList":function(n){var r;t.execNativeCommand(n);var o=e.dom.getParent(e.selection.getNode(),"ol,ul");o&&(r=o.parentNode,/^(H[1-6]|P|ADDRESS|PRE)$/.test(r.nodeName)&&(t.storeSelection(),e.dom.split(r,o),t.restoreSelection()))},"Bold,Italic,Underline,Strikethrough,Superscript,Subscript":function(e){t.toggleFormat(e)},"ForeColor,HiliteColor":function(e,n,r){t.toggleFormat(e,r)},FontName:function(t,n,r){XI(e,r)},FontSize:function(t,n,r){GI(e,r)},RemoveFormat:function(t){e.formatter.remove(t)},mceBlockQuote:function(){t.toggleFormat("blockquote")},FormatBlock:function(e,n,r){return t.toggleFormat(r||"p")},mceCleanup:function(){var t=e.selection.getBookmark();e.setContent(e.getContent()),e.selection.moveToBookmark(t)},mceRemoveNode:function(n,r,o){var i=o||e.selection.getNode();i!==e.getBody()&&(t.storeSelection(),e.dom.remove(i,!0),t.restoreSelection())},mceSelectNodeDepth:function(t,n,r){var o=0;e.dom.getParent(e.selection.getNode(),function(t){if(1===t.nodeType&&o++===r)return e.selection.select(t),!1},e.getBody())},mceSelectNode:function(t,n,r){e.selection.select(r)},mceInsertContent:function(t,n,r){ZI(e,r)},mceInsertRawHTML:function(t,n,r){e.selection.setContent("tiny_mce_marker");var o=e.getContent();e.setContent(o.replace(/tiny_mce_marker/g,function(){return r}))},mceInsertNewLine:function(t,n,r){fP(e,r)},mceToggleFormat:function(e,n,r){t.toggleFormat(r)},mceSetContent:function(t,n,r){e.setContent(r)},"Indent,Outdent":function(t){KO(e,t)},mceRepaint:function(){},InsertHorizontalRule:function(){e.execCommand("mceInsertContent",!1,"<hr />")},mceToggleVisualAid:function(){e.hasVisual=!e.hasVisual,e.addVisual()},mceReplaceContent:function(t,n,r){e.execCommand("mceInsertContent",!1,r.replace(/\{\$selection\}/g,e.selection.getContent({format:"text"})))},mceInsertLink:function(t,n,r){"string"==typeof r&&(r={href:r});var o=e.dom.getParent(e.selection.getNode(),"a");r.href=r.href.replace(/ /g,"%20"),o&&r.href||e.formatter.remove("link"),r.href&&e.formatter.apply("link",r,o)},selectAll:function(){var t=e.dom.getParent(e.selection.getStart(),jo);if(t){var n=e.dom.createRng();n.selectNodeContents(t),e.selection.setRng(n)}},"delete":function(){tM(e)},forwardDelete:function(){nM(e)},mceNewDocument:function(){e.setContent("")},InsertLineBreak:function(t,n,r){return KB(e,r),!0}});var n=function(t){return function(){var n=e.selection.isCollapsed()?[e.dom.getParent(e.selection.getNode(),e.dom.isBlock)]:e.selection.getSelectedBlocks(),r=oM(n,function(n){return!!e.formatter.matchNode(n,t)});return iM(r,!0)!==-1}};t.addCommands({JustifyLeft:n("alignleft"),JustifyCenter:n("aligncenter"),JustifyRight:n("alignright"),JustifyFull:n("alignjustify"),"Bold,Italic,Underline,Strikethrough,Superscript,Subscript":function(e){return t.isFormatMatch(e)},mceBlockQuote:function(){return t.isFormatMatch("blockquote")},Outdent:function(){return VO(e)},"InsertUnorderedList,InsertOrderedList":function(t){var n=e.dom.getParent(e.selection.getNode(),"ul,ol");return n&&("insertunorderedlist"===t&&"UL"===n.tagName||"insertorderedlist"===t&&"OL"===n.tagName)}},"state"),t.addCommands({Undo:function(){e.undoManager.undo()},Redo:function(){e.undoManager.redo()}}),t.addQueryValueHandler("FontName",function(){return YI(e)},this),t.addQueryValueHandler("FontSize",function(){return JI(e)},this)},e}(),uM="data-mce-contenteditable",cM=function(e,t,n){ds(e,t)&&n===!1?ls(e,t):n&&ss(e,t)},sM=function(e,t,n){try{e.getDoc().execCommand(t,!1,n)}catch(r){}},fM=function(e,t){e.dom().contentEditable=t?"true":"false"},lM=function(e){Xe(ps(e,'*[contenteditable="true"]'),function(e){$o(e,uM,"true"),fM(e,!1)})},dM=function(e){Xe(ps(e,"*["+uM+'="true"]'),function(e){Go(e,uM),fM(e,!0)})},mM=function(e){_e.from(e.selection.getNode()).each(function(e){e.removeAttribute("data-mce-selected")})},pM=function(e){e.selection.setRng(e.selection.getRng())},gM=function(e,t){var n=ar.fromDom(e.getBody());cM(n,"mce-content-readonly",t),t?(e.selection.controlSelection.hideResizeRect(),e._selectionOverrides.hideFakeCaret(),mM(e),e.readonly=!0,fM(n,!1),lM(n)):(e.readonly=!1,fM(n,!0),dM(n),sM(e,"StyleWithCSS",!1),sM(e,"enableInlineTableEditing",!1),sM(e,"enableObjectResizing",!1),cC(e)&&e.focus(),pM(e),e.nodeChanged())},hM=function(e){return e.readonly},vM=function(e){e.parser.addAttributeFilter("contenteditable",function(t){hM(e)&&Xe(t,function(e){e.attr(uM,e.attr("contenteditable")),e.attr("contenteditable","false")})}),e.serializer.addAttributeFilter(uM,function(t){hM(e)&&Xe(t,function(e){e.attr("contenteditable",e.attr(uM))})}),e.serializer.addTempAttr(uM)},yM=function(e){e.serializer?vM(e):e.on("PreInit",function(){vM(e)})},bM=function(e){return"click"===e.type},CM=function(e,t){return null!==e.dom.getParent(t,"a")},wM=function(e,t){var n=t.target;bM(t)&&!Nk.metaKeyPressed(t)&&CM(e,n)&&t.preventDefault()},xM=function(e){e.on("ShowCaret",function(t){hM(e)&&t.preventDefault()}),e.on("ObjectSelected",function(t){hM(e)&&t.preventDefault()})},SM=er.makeMap("focus blur focusin focusout click dblclick mousedown mouseup mousemove mouseover beforepaste paste cut copy selectionchange mouseout mouseenter mouseleave wheel keydown keypress keyup input beforeinput contextmenu dragstart dragend dragover draggesture dragdrop drop drag submit compositionstart compositionend compositionupdate touchstart touchmove touchend touchcancel"," "),NM=function(){function e(e){this.bindings={},this.settings=e||{},this.scope=this.settings.scope||this,this.toggleEvent=this.settings.toggleEvent||we}return e.isNative=function(e){return!!SM[e.toLowerCase()]},e.prototype.fire=function(e,t){e=e.toLowerCase(),t=t||{},t.type=e,t.target||(t.target=this.scope),t.preventDefault||(t.preventDefault=function(){t.isDefaultPrevented=xe},t.stopPropagation=function(){t.isPropagationStopped=xe},t.stopImmediatePropagation=function(){t.isImmediatePropagationStopped=xe},t.isDefaultPrevented=we,t.isPropagationStopped=we,t.isImmediatePropagationStopped=we),this.settings.beforeFire&&this.settings.beforeFire(t);var n=this.bindings[e];if(n)for(var r=0,o=n.length;r<o;r++){var i=n[r];if(i.once&&this.off(e,i.func),t.isImmediatePropagationStopped())return t.stopPropagation(),t;if(i.func.call(this.scope,t)===!1)return t.preventDefault(),t}return t},e.prototype.on=function(e,t,n,r){var o,i,a;if(t===!1&&(t=we),t){var u={func:t};for(r&&er.extend(u,r),i=e.toLowerCase().split(" "),a=i.length;a--;)e=i[a],o=this.bindings[e],o||(o=this.bindings[e]=[],this.toggleEvent(e,!0)),n?o.unshift(u):o.push(u)}return this},e.prototype.off=function(e,t){var n,r,o,i,a=this;if(e)for(o=e.toLowerCase().split(" "),n=o.length;n--;){if(e=o[n],r=this.bindings[e],!e)return gt(this.bindings,function(e,t){a.toggleEvent(t,!1),delete a.bindings[t]}),this;if(r){if(t)for(i=r.length;i--;)r[i].func===t&&(r=r.slice(0,i).concat(r.slice(i+1)),this.bindings[e]=r);else r.length=0;r.length||(this.toggleEvent(e,!1),delete this.bindings[e])}}else gt(this.bindings,function(e,t){a.toggleEvent(t,!1)}),this.bindings={};return this},e.prototype.once=function(e,t,n){return this.on(e,t,n,{once:!0})},e.prototype.has=function(e){return e=e.toLowerCase(),!(!this.bindings[e]||0===this.bindings[e].length)},e}(),EM=function(e){return e._eventDispatcher||(e._eventDispatcher=new NM({scope:e,toggleEvent:function(t,n){NM.isNative(t)&&e.toggleNativeEvent&&e.toggleNativeEvent(t,n)}})),e._eventDispatcher},kM={fire:function(e,t,n){var r=this;if(r.removed&&"remove"!==e&&"detach"!==e)return t;var o=EM(r).fire(e,t);if(n!==!1&&r.parent)for(var i=r.parent();i&&!o.isPropagationStopped();)i.fire(e,o,!1),i=i.parent();return o},on:function(e,t,n){return EM(this).on(e,t,n)},off:function(e,t){return EM(this).off(e,t)},once:function(e,t){return EM(this).once(e,t)},hasEventListeners:function(e){return EM(this).has(e)}},_M=Ac.DOM,TM=function(e,t){if("selectionchange"===t)return e.getDoc();if(!e.inline&&/^mouse|touch|click|contextmenu|drop|dragover|dragend/.test(t))return e.getDoc().documentElement;var n=Td(e);return n?(e.eventRoot||(e.eventRoot=_M.select(n)[0]),e.eventRoot):e.getBody()},RM=function(e){return!e.hidden&&!hM(e)},AM=function(e,t,n){RM(e)?e.fire(t,n):hM(e)&&wM(e,n)},DM=function(e,t){var n;if(e.delegates||(e.delegates={}),!e.delegates[t]&&!e.removed){var r=TM(e,t);if(Td(e)){if(LR||(LR={},e.editorManager.on("removeEditor",function(){e.editorManager.activeEditor||LR&&(gt(LR,function(t,n){e.dom.unbind(TM(e,n))}),LR=null)})),LR[t])return;n=function(n){for(var r=n.target,o=e.editorManager.get(),i=o.length;i--;){var a=o[i].getBody();(a===r||_M.isChildOf(r,a))&&AM(o[i],t,n)}},LR[t]=n,_M.bind(r,t,n)}else n=function(n){AM(e,t,n)},_M.bind(r,t,n),e.delegates[t]=n}},OM=It(It({},kM),{bindPendingEventDelegates:function(){var e=this;er.each(e._pendingNativeEvents,function(t){DM(e,t)})},toggleNativeEvent:function(e,t){var n=this;"focus"!==e&&"blur"!==e&&(t?n.initialized?DM(n,e):n._pendingNativeEvents?n._pendingNativeEvents.push(e):n._pendingNativeEvents=[e]:n.initialized&&(n.dom.unbind(TM(n,e),e,n.delegates[e]),delete n.delegates[e]))},unbindAllNativeEvents:function(){var e=this,t=e.getBody(),n=e.dom;e.delegates&&(gt(e.delegates,function(t,n){e.dom.unbind(TM(e,n),n,t)}),delete e.delegates),!e.inline&&t&&n&&(t.onload=null,n.unbind(e.getWin()),n.unbind(e.getDoc())),n&&(n.unbind(t),n.unbind(e.getContainer()))}}),BM=["design","readonly"],PM=function(t,n,r,o){var i=r[n.get()],a=r[o];try{a.activate()}catch(u){return void e.console.error("problem while activating editor mode "+o+":",u)}i.deactivate(),i.editorReadOnly!==a.editorReadOnly&&gM(t,a.editorReadOnly),n.set(o),$S(t,o)},LM=function(e,t,n,r){if(r!==n.get()){if(!Et(t,r))throw new Error("Editor mode '"+r+"' is invalid");e.initialized?PM(e,n,t,r):e.on("init",function(){return PM(e,n,t,r)})}},IM=function(t,n,r){var o;if($e(BM,n))throw new Error("Cannot override default mode "+n);return It(It({},t),(o={},o[n]=It(It({},r),{deactivate:function(){try{r.deactivate()}catch(t){e.console.error("problem while deactivating editor mode "+n+":",t)}}}),o))},MM=function(e){var t=Uc("design"),n=Uc({design:{activate:pe,deactivate:pe,editorReadOnly:!1},readonly:{activate:pe,deactivate:pe,editorReadOnly:!0}});return yM(e),xM(e),{isReadOnly:function(){return hM(e)},set:function(r){return LM(e,n.get(),t,r)},get:function(){return t.get()},register:function(e,t){n.set(IM(n.get(),e,t))}}},FM=er.each,UM=er.explode,zM={f1:112,f2:113,f3:114,f4:115,f5:116,f6:117,f7:118,f8:119,f9:120,f10:121,f11:122,f12:123},jM=er.makeMap("alt,ctrl,shift,meta,access"),HM=function(){function e(e){this.shortcuts={},this.pendingPatterns=[],this.editor=e;var t=this;e.on("keyup keypress keydown",function(e){!t.hasModifier(e)&&!t.isFunctionKey(e)||e.isDefaultPrevented()||(FM(t.shortcuts,function(n){if(t.matchShortcut(e,n))return t.pendingPatterns=n.subpatterns.slice(0),"keydown"===e.type&&t.executeShortcutAction(n),!0}),t.matchShortcut(e,t.pendingPatterns[0])&&(1===t.pendingPatterns.length&&"keydown"===e.type&&t.executeShortcutAction(t.pendingPatterns[0]),t.pendingPatterns.shift()))})}return e.prototype.add=function(e,t,n,r){var o=this,i=n;return"string"==typeof i?n=function(){o.editor.execCommand(i,!1,null)}:er.isArray(i)&&(n=function(){o.editor.execCommand(i[0],i[1],i[2])}),FM(UM(er.trim(e)),function(e){var i=o.createShortcut(e,t,n,r);o.shortcuts[i.id]=i}),!0},e.prototype.remove=function(e){var t=this.createShortcut(e);return!!this.shortcuts[t.id]&&(delete this.shortcuts[t.id],!0)},e.prototype.parseShortcut=function(e){var t,n={};FM(UM(e.toLowerCase(),"+"),function(e){e in jM?n[e]=!0:/^[0-9]{2,}$/.test(e)?n.keyCode=parseInt(e,10):(n.charCode=e.charCodeAt(0),n.keyCode=zM[e]||e.toUpperCase().charCodeAt(0))});var r=[n.keyCode];for(t in jM)n[t]?r.push(t):n[t]=!1;return n.id=r.join(","),n.access&&(n.alt=!0,jn.mac?n.ctrl=!0:n.shift=!0),n.meta&&(jn.mac?n.meta=!0:(n.ctrl=!0,n.meta=!1)),n},e.prototype.createShortcut=function(e,t,n,r){var o=er.map(UM(e,">"),this.parseShortcut);return o[o.length-1]=er.extend(o[o.length-1],{func:n,scope:r||this.editor}),er.extend(o[0],{desc:this.editor.translate(t),subpatterns:o.slice(1)})},e.prototype.hasModifier=function(e){return e.altKey||e.ctrlKey||e.metaKey},e.prototype.isFunctionKey=function(e){return"keydown"===e.type&&e.keyCode>=112&&e.keyCode<=123},e.prototype.matchShortcut=function(e,t){return!!t&&(t.ctrl===e.ctrlKey&&t.meta===e.metaKey&&(t.alt===e.altKey&&t.shift===e.shiftKey&&(!!(e.keyCode===t.keyCode||e.charCode&&e.charCode===t.charCode)&&(e.preventDefault(),!0))))},e.prototype.executeShortcutAction=function(e){return e.func?e.func.call(e.scope):null},e}(),VM=function(){var e={},t={},n={},r={},o={},i={},a={},u=function(e,t){return function(n,r){return e[n.toLowerCase()]=It(It({},r),{type:t})}},c=function(e,t){return r[e.toLowerCase()]=t};return{addButton:u(e,"button"),addGroupToolbarButton:u(e,"grouptoolbarbutton"),addToggleButton:u(e,"togglebutton"),addMenuButton:u(e,"menubutton"),addSplitButton:u(e,"splitbutton"),addMenuItem:u(t,"menuitem"),addNestedMenuItem:u(t,"nestedmenuitem"),addToggleMenuItem:u(t,"togglemenuitem"),addAutocompleter:u(n,"autocompleter"),addContextMenu:u(o,"contextmenu"),addContextToolbar:u(i,"contexttoolbar"),addContextForm:u(i,"contextform"),addSidebar:u(a,"sidebar"),addIcon:c,getAll:function(){return{buttons:e,menuItems:t,icons:r,popups:n,contextMenus:o,contextToolbars:i,sidebars:a}}}},qM=function(){var e=VM();return{addAutocompleter:e.addAutocompleter,addButton:e.addButton,addContextForm:e.addContextForm,addContextMenu:e.addContextMenu,addContextToolbar:e.addContextToolbar,addIcon:e.addIcon,addMenuButton:e.addMenuButton,addMenuItem:e.addMenuItem,addNestedMenuItem:e.addNestedMenuItem,addSidebar:e.addSidebar,addSplitButton:e.addSplitButton,addToggleButton:e.addToggleButton,addGroupToolbarButton:e.addGroupToolbarButton,addToggleMenuItem:e.addToggleMenuItem,getAll:e.getAll}},$M=er.each,WM=er.trim,KM="source protocol authority userInfo user password host port relative path directory file query anchor".split(" "),XM={ftp:21,http:80,https:443,mailto:25},YM=function(){function t(n,r){n=WM(n),this.settings=r||{};var o=this.settings.base_uri,i=this;if(/^([\w\-]+):([^\/]{2})/i.test(n)||/^\s*#/.test(n))return void(i.source=n);var a=0===n.indexOf("//");if(0!==n.indexOf("/")||a||(n=(o?o.protocol||"http":"http")+"://mce_host"+n),!/^[\w\-]*:?\/\//.test(n)){var u=this.settings.base_uri?this.settings.base_uri.path:new t(e.document.location.href).directory;if(this.settings.base_uri&&""==this.settings.base_uri.protocol)n="//mce_host"+i.toAbsPath(u,n);else{var c=/([^#?]*)([#?]?.*)/.exec(n);n=(o&&o.protocol||"http")+"://mce_host"+i.toAbsPath(u,c[1])+c[2]}}n=n.replace(/@@/g,"(mce_at)");var s=/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@\/]*):?([^:@\/]*))?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/.exec(n);$M(KM,function(e,t){var n=s[t];n&&(n=n.replace(/\(mce_at\)/g,"@@")),i[e]=n}),o&&(i.protocol||(i.protocol=o.protocol),i.userInfo||(i.userInfo=o.userInfo),i.port||"mce_host"!==i.host||(i.port=o.port),i.host&&"mce_host"!==i.host||(i.host=o.host),i.source=""),a&&(i.protocol="")}return t.parseDataUri=function(e){var t,n=decodeURIComponent(e).split(","),r=/data:([^;]+)/.exec(n[0]);return r&&(t=r[1]),{type:t,data:n[1]}},t.getDocumentBaseUrl=function(e){var t;return t=0!==e.protocol.indexOf("http")&&"file:"!==e.protocol?e.href:e.protocol+"//"+e.host+e.pathname,/^[^:]+:\/\/\/?[^\/]+\//.test(t)&&(t=t.replace(/[\?#].*$/,"").replace(/[\/\\][^\/]+$/,""),/[\/\\]$/.test(t)||(t+="/")),t},t.prototype.setPath=function(e){var t=/^(.*?)\/?(\w+)?$/.exec(e);this.path=t[0],this.directory=t[1],this.file=t[2],this.source="",this.getURI()},t.prototype.toRelative=function(e){var n;if("./"===e)return e;var r=new t(e,{base_uri:this});if("mce_host"!==r.host&&this.host!==r.host&&r.host||this.port!==r.port||this.protocol!==r.protocol&&""!==r.protocol)return r.getURI();var o=this.getURI(),i=r.getURI();return o===i||"/"===o.charAt(o.length-1)&&o.substr(0,o.length-1)===i?o:(n=this.toRelPath(this.path,r.path),r.query&&(n+="?"+r.query),r.anchor&&(n+="#"+r.anchor),n)},t.prototype.toAbsolute=function(e,n){var r=new t(e,{base_uri:this});return r.getURI(n&&this.isSameOrigin(r))},t.prototype.isSameOrigin=function(e){if(this.host==e.host&&this.protocol==e.protocol){if(this.port==e.port)return!0;var t=XM[this.protocol];if(t&&(this.port||t)==(e.port||t))return!0}return!1},t.prototype.toRelPath=function(e,t){var n,r,o=0,i="",a=e.substring(0,e.lastIndexOf("/")).split("/"),u=t.split("/");if(a.length>=u.length)for(n=0,r=a.length;n<r;n++)if(n>=u.length||a[n]!==u[n]){o=n+1;break}if(a.length<u.length)for(n=0,r=u.length;n<r;n++)if(n>=a.length||a[n]!==u[n]){o=n+1;break}if(1===o)return t;for(n=0,r=a.length-(o-1);n<r;n++)i+="../";for(n=o-1,r=u.length;n<r;n++)i+=n!==o-1?"/"+u[n]:u[n];return i},t.prototype.toAbsPath=function(e,t){var n,r,o=0,i=[],a=/\/$/.test(t)?"/":"",u=e.split("/"),c=t.split("/");for($M(u,function(e){e&&i.push(e)}),u=i,n=c.length-1,i=[];n>=0;n--)0!==c[n].length&&"."!==c[n]&&(".."!==c[n]?o>0?o--:i.push(c[n]):o++);return n=u.length-o,r=n<=0?at(i).join("/"):u.slice(0,n).join("/")+"/"+at(i).join("/"),0!==r.indexOf("/")&&(r="/"+r),a&&r.lastIndexOf("/")!==r.length-1&&(r+=a),r},t.prototype.getURI=function(e){void 0===e&&(e=!1);var t;return this.source&&!e||(t="",e||(t+=this.protocol?this.protocol+"://":"//",this.userInfo&&(t+=this.userInfo+"@"),this.host&&(t+=this.host),this.port&&(t+=":"+this.port)),this.path&&(t+=this.path),this.query&&(t+="?"+this.query),this.anchor&&(t+="#"+this.anchor),this.source=t),this.source},t}(),GM=Ac.DOM,JM=er.extend,QM=er.each,ZM=er.resolve,eF=jn.ie,tF=function(){
function e(e,t,n){var r=this;this.plugins={},this.contentCSS=[],this.contentStyles=[],this.loadedCSS={},this.isNotDirty=!1,this.editorManager=n,this.documentBaseUrl=n.documentBaseURL,JM(this,OM),this.settings=ON(this,e,this.documentBaseUrl,n.defaultSettings,t),this.settings.suffix&&(n.suffix=this.settings.suffix),this.suffix=n.suffix,this.settings.base_url&&n._setBaseUrl(this.settings.base_url),this.baseUri=n.baseURI,this.settings.referrer_policy&&(Fc.ScriptLoader._setReferrerPolicy(this.settings.referrer_policy),Ac.DOM.styleSheetLoader._setReferrerPolicy(this.settings.referrer_policy)),Zc.languageLoad=this.settings.language_load,Zc.baseURL=n.baseURL,this.id=e,this.setDirty(!1),this.documentBaseURI=new YM(this.settings.document_base_url,{base_uri:this.baseUri}),this.baseURI=this.baseUri,this.inline=!!this.settings.inline,this.shortcuts=new HM(this),this.editorCommands=new aM(this),this.settings.cache_suffix&&(jn.cacheSuffix=this.settings.cache_suffix.replace(/^[\?\&]+/,"")),this.ui={registry:qM(),styleSheetLoader:void 0};var o=this,i=MM(o);this.mode=i,this.setMode=i.set,n.fire("SetupEditor",{editor:this}),this.execCallback("setup",this),this.$=Vu.overrideDefaults(function(){return{context:r.inline?r.getBody():r.getDoc(),element:r.getBody()}})}return e.prototype.render=function(){OI(this)},e.prototype.focus=function(e){lC(this,e)},e.prototype.hasFocus=function(){return uC(this)},e.prototype.execCallback=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r,o=this,i=o.settings[e];if(i)return o.callbackLookup&&(r=o.callbackLookup[e])&&(i=r.func,r=r.scope),"string"==typeof i&&(r=i.replace(/\.\w+$/,""),r=r?ZM(r):0,i=ZM(i),o.callbackLookup=o.callbackLookup||{},o.callbackLookup[e]={func:i,scope:r}),i.apply(r||o,t)},e.prototype.translate=function(e){return Qc.translate(e)},e.prototype.getParam=function(e,t,n){return IN(this,e,t,n)},e.prototype.nodeChanged=function(e){this._nodeChangeDispatcher.nodeChanged(e)},e.prototype.addCommand=function(e,t,n){this.editorCommands.addCommand(e,t,n)},e.prototype.addQueryStateHandler=function(e,t,n){this.editorCommands.addQueryStateHandler(e,t,n)},e.prototype.addQueryValueHandler=function(e,t,n){this.editorCommands.addQueryValueHandler(e,t,n)},e.prototype.addShortcut=function(e,t,n,r){this.shortcuts.add(e,t,n,r)},e.prototype.execCommand=function(e,t,n,r){return this.editorCommands.execCommand(e,t,n,r)},e.prototype.queryCommandState=function(e){return this.editorCommands.queryCommandState(e)},e.prototype.queryCommandValue=function(e){return this.editorCommands.queryCommandValue(e)},e.prototype.queryCommandSupported=function(e){return this.editorCommands.queryCommandSupported(e)},e.prototype.show=function(){var e=this;e.hidden&&(e.hidden=!1,e.inline?e.getBody().contentEditable="true":(GM.show(e.getContainer()),GM.hide(e.id)),e.load(),e.fire("show"))},e.prototype.hide=function(){var e=this,t=e.getDoc();e.hidden||(eF&&t&&!e.inline&&t.execCommand("SelectAll"),e.save(),e.inline?(e.getBody().contentEditable="false",e===e.editorManager.focusedEditor&&(e.editorManager.focusedEditor=null)):(GM.hide(e.getContainer()),GM.setStyle(e.id,"display",e.orgDisplay)),e.hidden=!0,e.fire("hide"))},e.prototype.isHidden=function(){return!!this.hidden},e.prototype.setProgressState=function(e,t){this.fire("ProgressState",{state:e,time:t})},e.prototype.load=function(e){var t,n=this,r=n.getElement();if(n.removed)return"";if(r){e=e||{},e.load=!0;var o=Lo(r)?r.value:r.innerHTML;return t=n.setContent(o,e),e.element=r,e.no_events||n.fire("LoadContent",e),e.element=r=null,t}},e.prototype.save=function(e){var t,n,r=this,o=r.getElement();if(o&&r.initialized&&!r.removed)return e=e||{},e.save=!0,e.element=o,t=e.content=r.getContent(e),e.no_events||r.fire("SaveContent",e),"raw"===e.format&&r.fire("RawSaveContent",e),t=e.content,Lo(o)?o.value=t:(!e.is_removing&&r.inline||(o.innerHTML=t),(n=GM.getParent(r.id,"form"))&&QM(n.elements,function(e){if(e.name===r.id)return e.value=t,!1})),e.element=o=null,e.set_dirty!==!1&&r.setDirty(!1),t},e.prototype.setContent=function(e,t){return zS(this,e,t)},e.prototype.getContent=function(e){return US(this,e)},e.prototype.insertContent=function(e,t){t&&(e=JM({content:e},t)),this.execCommand("mceInsertContent",!1,e)},e.prototype.resetContent=function(e){void 0===e?zS(this,this.startContent,{format:"raw"}):zS(this,e),this.undoManager.reset(),this.setDirty(!1),this.nodeChanged()},e.prototype.isDirty=function(){return!this.isNotDirty},e.prototype.setDirty=function(e){var t=!this.isNotDirty;this.isNotDirty=!e,e&&e!==t&&this.fire("dirty")},e.prototype.getContainer=function(){var e=this;return e.container||(e.container=GM.get(e.editorContainer||e.id+"_parent")),e.container},e.prototype.getContentAreaContainer=function(){return this.contentAreaContainer},e.prototype.getElement=function(){return this.targetElm||(this.targetElm=GM.get(this.id)),this.targetElm},e.prototype.getWin=function(){var e,t=this;return t.contentWindow||(e=t.iframeElement,e&&(t.contentWindow=e.contentWindow)),t.contentWindow},e.prototype.getDoc=function(){var e,t=this;return t.contentDocument||(e=t.getWin(),e&&(t.contentDocument=e.document)),t.contentDocument},e.prototype.getBody=function(){var e=this.getDoc();return this.bodyElement||(e?e.body:null)},e.prototype.convertURL=function(e,t,n){var r=this,o=r.settings;return o.urlconverter_callback?r.execCallback("urlconverter_callback",e,n,!0,t):!o.convert_urls||n&&"LINK"===n.nodeName||0===e.indexOf("file:")||0===e.length?e:o.relative_urls?r.documentBaseURI.toRelative(e):e=r.documentBaseURI.toAbsolute(e,o.remove_script_host)},e.prototype.addVisual=function(e){var t,n=this,r=n.settings,o=n.dom;e=e||n.getBody(),void 0===n.hasVisual&&(n.hasVisual=r.visual),QM(o.select("table,a",e),function(e){var i;switch(e.nodeName){case"TABLE":return t=r.visual_table_class||"mce-item-table",i=o.getAttrib(e,"border"),void(i&&"0"!==i||!n.hasVisual?o.removeClass(e,t):o.addClass(e,t));case"A":return void(o.getAttrib(e,"href")||(i=o.getAttrib(e,"name")||e.id,t=r.visual_anchor_class||"mce-item-anchor",i&&n.hasVisual?o.addClass(e,t):o.removeClass(e,t)))}}),n.fire("VisualAid",{element:e,hasVisual:n.hasVisual})},e.prototype.remove=function(){oN(this)},e.prototype.destroy=function(e){iN(this,e)},e.prototype.uploadImages=function(e){return this.editorUpload.uploadImages(e)},e.prototype._scanForImages=function(){return this.editorUpload.scanForImages()},e.prototype.addButton=function(){throw new Error("editor.addButton has been removed in tinymce 5x, use editor.ui.registry.addButton or editor.ui.registry.addToggleButton or editor.ui.registry.addSplitButton instead")},e.prototype.addSidebar=function(){throw new Error("editor.addSidebar has been removed in tinymce 5x, use editor.ui.registry.addSidebar instead")},e.prototype.addMenuItem=function(){throw new Error("editor.addMenuItem has been removed in tinymce 5x, use editor.ui.registry.addMenuItem instead")},e.prototype.addContextToolbar=function(){throw new Error("editor.addContextToolbar has been removed in tinymce 5x, use editor.ui.registry.addContextToolbar instead")},e}(),nF=Ac.DOM,rF=er.explode,oF=er.each,iF=er.extend,aF=0,uF=!1,cF=[],sF=[],fF=function(e){return"length"!==e},lF=function(e){var t=e.type;oF(hF.get(),function(n){switch(t){case"scroll":n.fire("ScrollWindow",e);break;case"resize":n.fire("ResizeWindow",e)}})},dF=function(e){e!==uF&&(e?Vu(window).on("resize scroll",lF):Vu(window).off("resize scroll",lF),uF=e)},mF=function(e){var t=sF;delete cF[e.id];for(var n=0;n<cF.length;n++)if(cF[n]===e){cF.splice(n,1);break}return sF=Je(sF,function(t){return e!==t}),hF.activeEditor===e&&(hF.activeEditor=sF.length>0?sF[0]:null),hF.focusedEditor===e&&(hF.focusedEditor=null),t.length!==sF.length},pF=function(e){return e&&e.initialized&&!(e.getContainer()||e.getBody()).parentNode&&(mF(e),e.unbindAllNativeEvents(),e.destroy(!0),e.removed=!0,e=null),e},gF="CSS1Compat"!==e.document.compatMode,hF=It(It({},kM),{baseURI:null,baseURL:null,defaultSettings:{},documentBaseURL:null,suffix:null,$:Vu,majorVersion:"5",minorVersion:"4.2",releaseDate:"2020-08-17",editors:cF,i18n:Qc,activeEditor:null,focusedEditor:null,settings:{},setup:function(){var t,n,r=this,o="";n=YM.getDocumentBaseUrl(e.document.location),/^[^:]+:\/\/\/?[^\/]+\//.test(n)&&(n=n.replace(/[\?#].*$/,"").replace(/[\/\\][^\/]+$/,""),/[\/\\]$/.test(n)||(n+="/"));var i=window.tinymce||window.tinyMCEPreInit;if(i)t=i.base||i.baseURL,o=i.suffix;else{for(var a=e.document.getElementsByTagName("script"),u=0;u<a.length;u++){var c=a[u].src||"";if(""!==c){var s=c.substring(c.lastIndexOf("/"));if(/tinymce(\.full|\.jquery|)(\.min|\.dev|)\.js/.test(c)){s.indexOf(".min")!==-1&&(o=".min"),t=c.substring(0,c.lastIndexOf("/"));break}}}if(!t&&e.document.currentScript){var c=e.document.currentScript.src;c.indexOf(".min")!==-1&&(o=".min"),t=c.substring(0,c.lastIndexOf("/"))}}r.baseURL=new YM(n).toAbsolute(t),r.documentBaseURL=n,r.baseURI=new YM(r.baseURL),r.suffix=o,Jb(r)},overrideDefaults:function(e){var t=e.base_url;t&&this._setBaseUrl(t);var n=e.suffix;e.suffix&&(this.suffix=n),this.defaultSettings=e;var r=e.plugin_base_urls;void 0!==r&&gt(r,function(e,t){Zc.PluginManager.urls[t]=e})},init:function(t){var n,r=this,o=er.makeMap("area base basefont br col frame hr img input isindex link meta param embed source wbr track colgroup option table tbody tfoot thead tr th td script noscript style textarea video audio iframe object menu"," "),i=function(e,t){return e.inline&&t.tagName.toLowerCase()in o},a=function(e){var t=e.id;return t||(t=Nt(e,"name").filter(function(e){return!nF.get(e)}).getOrThunk(nF.uniqueId),e.setAttribute("id",t)),t},u=function(e){var n=t[e];if(n)return n.apply(r,Array.prototype.slice.call(arguments,2))},c=function(e,t){return t.constructor===RegExp?t.test(e.className):nF.hasClass(e,t)},s=function(t){var n=[];if(jn.browser.isIE()&&jn.browser.version.major<11)return sE("TinyMCE does not support the browser you are using. For a list of supported browsers please see: https://www.tinymce.com/docs/get-started/system-requirements/"),[];if(gF)return sE("Failed to initialize the editor as the document is not in standards mode. TinyMCE requires standards mode."),[];if(t.types)return oF(t.types,function(e){n=n.concat(nF.select(e.selector))}),n;if(t.selector)return nF.select(t.selector);if(t.target)return[t.target];switch(t.mode){case"exact":var r=t.elements||"";r.length>0&&oF(rF(r),function(t){var r=nF.get(t);r?n.push(r):oF(e.document.forms,function(e){oF(e.elements,function(e){e.name===t&&(t="mce_editor_"+aF++,nF.setAttrib(e,"id",t),n.push(e))})})});break;case"textareas":case"specific_textareas":oF(nF.select("textarea"),function(e){t.editor_deselector&&c(e,t.editor_deselector)||t.editor_selector&&!c(e,t.editor_selector)||n.push(e)})}return n},f=function(e){n=e},l=function(){var e,n=0,o=[],c=function(t,i,a){var u=new tF(t,i,r);o.push(u),u.on("init",function(){++n===e.length&&f(o)}),u.targetElm=u.targetElm||a,u.render()};return nF.unbind(window,"ready",l),u("onpageload"),e=Vu.unique(s(t)),t.types?void oF(t.types,function(n){er.each(e,function(e){return!nF.is(e,n.selector)||(c(a(e),iF({},t,n),e),!1)})}):(er.each(e,function(e){pF(r.get(e.id))}),e=er.grep(e,function(e){return!r.get(e.id)}),void(0===e.length?f([]):oF(e,function(e){i(t,e)?sE("Could not initialize inline editor on invalid inline target element",e):c(a(e),t,e)})))};return r.settings=t,nF.bind(window,"ready",l),new mc(function(e){n?e(n):f=function(t){e(t)}})},get:function(e){return 0===arguments.length?sF.slice(0):Oe(e)?tt(sF,function(t){return t.id===e}).getOr(null):Ue(e)&&sF[e]?sF[e]:null},add:function(e){var t=this,n=cF[e.id];return n===e?e:(null===t.get(e.id)&&(fF(e.id)&&(cF[e.id]=e),cF.push(e),sF.push(e)),dF(!0),t.activeEditor=e,t.fire("AddEditor",{editor:e}),IR||(IR=function(e){var n=t.fire("BeforeUnload");if(n.returnValue)return e.preventDefault(),e.returnValue=n.returnValue,n.returnValue},window.addEventListener("beforeunload",IR)),e)},createEditor:function(e,t){return this.add(new tF(e,t,this))},remove:function(e){var t,n,r=this;if(e)return Oe(e)?void oF(nF.select(e),function(e){n=r.get(e.id),n&&r.remove(n)}):(n=e,Le(r.get(n.id))?null:(mF(n)&&r.fire("RemoveEditor",{editor:n}),0===sF.length&&window.removeEventListener("beforeunload",IR),n.remove(),dF(sF.length>0),n));for(t=sF.length-1;t>=0;t--)r.remove(sF[t])},execCommand:function(e,t,n){var r=this,o=r.get(n);switch(e){case"mceAddEditor":return r.get(n)||new tF(n,r.settings,r).render(),!0;case"mceRemoveEditor":return o&&o.remove(),!0;case"mceToggleEditor":return o?(o.isHidden()?o.show():o.hide(),!0):(r.execCommand("mceAddEditor",0,n),!0)}return!!r.activeEditor&&r.activeEditor.execCommand(e,t,n)},triggerSave:function(){oF(sF,function(e){e.save()})},addI18n:function(e,t){Qc.add(e,t)},translate:function(e){return Qc.translate(e)},setActive:function(e){var t=this.activeEditor;this.activeEditor!==e&&(t&&t.fire("deactivate",{relatedTarget:e}),e.fire("activate",{relatedTarget:t})),this.activeEditor=e},_setBaseUrl:function(e){this.baseURL=new YM(this.documentBaseURL).toAbsolute(e.replace(/\/+$/,"")),this.baseURI=new YM(this.baseURL)}});hF.setup(),function(e){e.compareRanges=nk,e.getCaretRangeFromPoint=KE,e.getSelectedNode=bf,e.getNode=Cf}(F||(F={}));var vF,yF,bF=F,CF=function(t,n,r){void 0===r&&(r=1e3);var o=!1,i=null,a=function(t){return function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];o||(o=!0,null!==i&&(e.clearTimeout(i),i=null),t.apply(null,n))}},u=a(t),c=a(n),s=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];o||null!==i||(i=e.setTimeout(function(){return c.apply(null,t)},r))};return{start:s,resolve:u,reject:c}},wF=function(){var e={},t={},n=function(n,r){var o='Script at URL "'+r+'" failed to load',i='Script at URL "'+r+"\" did not call `tinymce.Resource.add('"+n+"', data)` within 1 second";if(void 0!==e[n])return e[n];var a=new mc(function(e,a){var u=CF(e,a);t[n]=u.resolve,Fc.ScriptLoader.loadScript(r,function(){return u.start(i)},function(){return u.reject(o)})});return e[n]=a,a},r=function(n,r){void 0!==t[n]&&(t[n](r),delete t[n]),e[n]=mc.resolve(r)};return{load:n,add:r}},xF=wF(),SF=Math.min,NF=Math.max,EF=Math.round,kF=function(e,t,n){var r=t.x,o=t.y,i=e.w,a=e.h,u=t.w,c=t.h;return n=(n||"").split(""),"b"===n[0]&&(o+=c),"r"===n[1]&&(r+=u),"c"===n[0]&&(o+=EF(c/2)),"c"===n[1]&&(r+=EF(u/2)),"b"===n[3]&&(o-=a),"r"===n[4]&&(r-=i),"c"===n[3]&&(o-=EF(a/2)),"c"===n[4]&&(r-=EF(i/2)),DF(r,o,i,a)},_F=function(e,t,n,r){var o,i;for(i=0;i<r.length;i++)if(o=kF(e,t,r[i]),o.x>=n.x&&o.x+o.w<=n.w+n.x&&o.y>=n.y&&o.y+o.h<=n.h+n.y)return r[i];return null},TF=function(e,t,n){return DF(e.x-t,e.y-n,e.w+2*t,e.h+2*n)},RF=function(e,t){var n=NF(e.x,t.x),r=NF(e.y,t.y),o=SF(e.x+e.w,t.x+t.w),i=SF(e.y+e.h,t.y+t.h);return o-n<0||i-r<0?null:DF(n,r,o-n,i-r)},AF=function(e,t,n){var r=e.x,o=e.y,i=e.x+e.w,a=e.y+e.h,u=t.x+t.w,c=t.y+t.h,s=NF(0,t.x-r),f=NF(0,t.y-o),l=NF(0,i-u),d=NF(0,a-c);return r+=s,o+=f,n&&(i+=s,a+=f,r-=l,o-=d),i-=l,a-=d,DF(r,o,i-r,a-o)},DF=function(e,t,n,r){return{x:e,y:t,w:n,h:r}},OF=function(e){return DF(e.left,e.top,e.width,e.height)},BF={inflate:TF,relativePosition:kF,findBestRelativePosition:_F,intersect:RF,clamp:AF,create:DF,fromClientRect:OF},PF=er.each,LF=er.extend,IF=function(){};IF.extend=vF=function(e){var t=this,n=t.prototype,r=function(){var e,t,n,r=this;if(!yF&&(r.init&&r.init.apply(r,arguments),t=r.Mixins))for(e=t.length;e--;)n=t[e],n.init&&n.init.apply(r,arguments)},o=function(){return this},i=function(e,t){return function(){var r=this,o=r._super;r._super=n[e];var i=t.apply(r,arguments);return r._super=o,i}};yF=!0;var a=new t;return yF=!1,e.Mixins&&(PF(e.Mixins,function(t){for(var n in t)"init"!==n&&(e[n]=t[n])}),n.Mixins&&(e.Mixins=n.Mixins.concat(e.Mixins))),e.Methods&&PF(e.Methods.split(","),function(t){e[t]=o}),e.Properties&&PF(e.Properties.split(","),function(t){var n="_"+t;e[t]=function(e){var t=this;return void 0!==e?(t[n]=e,t):t[n]}}),e.Statics&&PF(e.Statics,function(e,t){r[t]=e}),e.Defaults&&n.Defaults&&(e.Defaults=LF({},n.Defaults,e.Defaults)),gt(e,function(e,t){"function"==typeof e&&n[t]?a[t]=i(t,e):a[t]=e}),r.prototype=a,r.constructor=r,r.extend=vF,r};var MF,FF=Math.min,UF=Math.max,zF=Math.round,jF=function(e){var t={},n=0,r=0,o=0,i=function(e,t,n){var r,o,i;r=0,o=0,i=0,e/=255,t/=255,n/=255;var a=FF(e,FF(t,n)),u=UF(e,UF(t,n));if(a===u)return i=a,{h:0,s:0,v:100*i};var c=e===a?t-n:n===a?e-t:n-e;return r=e===a?3:n===a?1:5,r=60*(r-c/(u-a)),o=(u-a)/u,i=u,{h:zF(r),s:zF(100*o),v:zF(100*i)}},a=function(e,t,i){if(e=(parseInt(e,10)||0)%360,t=parseInt(t,10)/100,i=parseInt(i,10)/100,t=UF(0,FF(t,1)),i=UF(0,FF(i,1)),0===t)return void(n=r=o=zF(255*i));var a=e/60,u=i*t,c=u*(1-Math.abs(a%2-1)),s=i-u;switch(Math.floor(a)){case 0:n=u,r=c,o=0;break;case 1:n=c,r=u,o=0;break;case 2:n=0,r=u,o=c;break;case 3:n=0,r=c,o=u;break;case 4:n=c,r=0,o=u;break;case 5:n=u,r=0,o=c;break;default:n=r=o=0}n=zF(255*(n+s)),r=zF(255*(r+s)),o=zF(255*(o+s))},u=function(){var e=function(e){return e=parseInt(e,10).toString(16),e.length>1?e:"0"+e};return"#"+e(n)+e(r)+e(o)},c=function(){return{r:n,g:r,b:o}},s=function(){return i(n,r,o)},f=function(e){var i;return"object"==typeof e?"r"in e?(n=e.r,r=e.g,o=e.b):"v"in e&&a(e.h,e.s,e.v):(i=/rgb\s*\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)[^\)]*\)/gi.exec(e))?(n=parseInt(i[1],10),r=parseInt(i[2],10),o=parseInt(i[3],10)):(i=/#([0-F]{2})([0-F]{2})([0-F]{2})/gi.exec(e))?(n=parseInt(i[1],16),r=parseInt(i[2],16),o=parseInt(i[3],16)):(i=/#([0-F])([0-F])([0-F])/gi.exec(e))&&(n=parseInt(i[1]+i[1],16),r=parseInt(i[2]+i[2],16),o=parseInt(i[3]+i[3],16)),n=n<0?0:n>255?255:n,r=r<0?0:r>255?255:r,o=o<0?0:o>255?255:o,t};return e&&f(e),t.toRgb=c,t.toHsv=s,t.toHex=u,t.parse=f,t},HF=function(e){var t=JSON.stringify(e);return Oe(t)?t.replace(/[\u0080-\uFFFF]/g,function(e){var t=e.charCodeAt(0).toString(16);return"\\u"+"0000".substring(t.length)+t}):t},VF={serialize:HF,parse:function(e){try{return JSON.parse(e)}catch(t){}}},qF={callbacks:{},count:0,send:function(e){var t=this,n=Ac.DOM,r=void 0!==e.count?e.count:t.count,o="tinymce_jsonp_"+r;t.callbacks[r]=function(i){n.remove(o),delete t.callbacks[r],e.callback(i)},n.add(n.doc.body,"script",{id:o,src:e.url,type:"text/javascript"}),t.count++}},$F=It(It({},kM),{send:function(t){var n,r=0,o=function(){!t.async||4===n.readyState||r++>1e4?(t.success&&r<1e4&&200===n.status?t.success.call(t.success_scope,""+n.responseText,n,t):t.error&&t.error.call(t.error_scope,r>1e4?"TIMED_OUT":"GENERAL",n,t),n=null):Cc.setTimeout(o,10)};if(t.scope=t.scope||this,t.success_scope=t.success_scope||t.scope,t.error_scope=t.error_scope||t.scope,t.async=t.async!==!1,t.data=t.data||"",$F.fire("beforeInitialize",{settings:t}),n=new e.XMLHttpRequest){if(n.overrideMimeType&&n.overrideMimeType(t.content_type),n.open(t.type||(t.data?"POST":"GET"),t.url,t.async),t.crossDomain&&(n.withCredentials=!0),t.content_type&&n.setRequestHeader("Content-Type",t.content_type),t.requestheaders&&er.each(t.requestheaders,function(e){n.setRequestHeader(e.key,e.value)}),n.setRequestHeader("X-Requested-With","XMLHttpRequest"),n=$F.fire("beforeSend",{xhr:n,settings:t}).xhr,n.send(t.data),!t.async)return o();Cc.setTimeout(o,10)}}}),WF=er.extend,KF=function(){function e(e){this.settings=WF({},e),this.count=0}return e.sendRPC=function(t){return(new e).send(t)},e.prototype.send=function(e){var t=e.error,n=e.success,r=WF(this.settings,e);r.success=function(e,o){e=VF.parse(e),"undefined"==typeof e&&(e={error:"JSON Parse error."}),e.error?t.call(r.error_scope||r.scope,e.error,o):n.call(r.success_scope||r.scope,e.result)},r.error=function(e,n){t&&t.call(r.error_scope||r.scope,e,n)},r.data=VF.serialize({id:e.id||"c"+this.count++,method:e.method,params:e.params}),r.content_type="application/json",$F.send(r)},e}(),XF=function(){return function(){var e={},t=[],n={getItem:function(t){var n=e[t];return n?n:null},setItem:function(n,r){t.push(n),e[n]=String(r)},key:function(e){return t[e]},removeItem:function(n){t=t.filter(function(e){return e===n}),delete e[n]},clear:function(){t=[],e={}},length:0};return Object.defineProperty(n,"length",{get:function(){return t.length},configurable:!1,enumerable:!1}),n}()};try{var YF="__storage_test__";MF=e.window.localStorage,MF.setItem(YF,YF),MF.removeItem(YF)}catch(du){MF=XF()}var GF=MF,JF={geom:{Rect:BF},util:{Promise:mc,Delay:Cc,Tools:er,VK:Nk,URI:YM,Class:IF,EventDispatcher:NM,Observable:kM,I18n:Qc,XHR:$F,JSON:VF,JSONRequest:KF,JSONP:qF,LocalStorage:GF,Color:jF},dom:{EventUtils:Ta,Sizzle:mu,DomQuery:Vu,TreeWalker:qu,TextSeeker:zs,DOMUtils:Ac,ScriptLoader:Fc,RangeUtils:bF,Serializer:S_,StyleSheetLoader:w,ControlSelection:Tk,BookmarkManager:xk,Selection:Bk,Event:Ta.Event},html:{Styles:ha,Entities:ea,Node:Zg,Schema:o,SaxParser:mh,DomParser:f_,Writer:th,Serializer:nh},Env:jn,AddOnManager:Zc,Annotator:Xg,Formatter:V_,UndoManager:W_,EditorCommands:aM,WindowManager:ZN,NotificationManager:R,EditorObservable:OM,Shortcuts:HM,Editor:tF,FocusManager:Mb,EditorManager:hF,DOM:Ac.DOM,ScriptLoader:Fc.ScriptLoader,PluginManager:Zc.PluginManager,ThemeManager:Zc.ThemeManager,IconManager:FN,Resource:xF,trim:er.trim,isArray:er.isArray,is:er.is,toArray:er.toArray,makeMap:er.makeMap,each:er.each,map:er.map,grep:er.grep,inArray:er.inArray,extend:er.extend,create:er.create,walk:er.walk,createNS:er.createNS,resolve:er.resolve,explode:er.explode,_addCacheSuffix:er._addCacheSuffix,isOpera:jn.opera,isWebKit:jn.webkit,isIE:jn.ie,isGecko:jn.gecko,isMac:jn.mac},QF=er.extend(hF,JF),ZF=function(e){if("object"==typeof module)try{module.exports=e}catch(t){}},eU=function(e){window.tinymce=e,window.tinyMCE=e};eU(QF),ZF(QF)}(window);